diff --git a/app/components/navbar.jsx b/app/components/navbar.jsx index 4af1cfe..cdb990f 100644 --- a/app/components/navbar.jsx +++ b/app/components/navbar.jsx @@ -22,7 +22,7 @@ export default class ZNavbar extends React.Component { - myzenwallet.io +  myzenwallet.io @@ -875,7 +914,21 @@ class ZWalletTabs extends React.Component { settings={this.props.settings} publicAddresses={this.props.publicAddresses} /> - + + + + + + + + + + + + ) @@ -956,8 +1009,7 @@ export default class ZWallet extends React.Component { publicAddresses[c_addr] = { privateKey: c_pk, - privateKeyWIF: c_pk_wif, - transactionURL: zenwalletutils.urlAppend(this.state.settings.explorerURL, 'address/') + c_addr, + privateKeyWIF: c_pk_wif, confirmedBalance: 'loading...', unconfirmedBalance: 'loading...', } @@ -979,7 +1031,7 @@ export default class ZWallet extends React.Component { privateKeys : '', publicAddresses: null, }) - } + } // Only used for bip32 gen wallet because // of the async nature diff --git a/app/faq.js b/app/faq.js index 72d8b72..059e233 100644 --- a/app/faq.js +++ b/app/faq.js @@ -1,9 +1,9 @@ import 'bootstrap/dist/css/bootstrap.css'; -import 'react-bootstrap-table/dist/react-bootstrap-table-all.min.css'; +import 'react-table/react-table.css' import React from 'react'; import ReactDOM from 'react-dom'; import ZNavbar from './components/navbar.jsx' -import ZFaq from './components/faq.jsx' +import ZWallet from './components/wallet.jsx' import ZFooter from './components/footer.jsx' ReactDOM.render(, document.getElementById('navbar')); diff --git a/app/guide.js b/app/guide.js index 743820f..6b57d39 100644 --- a/app/guide.js +++ b/app/guide.js @@ -1,9 +1,9 @@ import 'bootstrap/dist/css/bootstrap.css'; -import 'react-bootstrap-table/dist/react-bootstrap-table-all.min.css'; +import 'react-table/react-table.css' import React from 'react'; import ReactDOM from 'react-dom'; import ZNavbar from './components/navbar.jsx' -import ZGuide from './components/guide.jsx' +import ZWallet from './components/wallet.jsx' import ZFooter from './components/footer.jsx' ReactDOM.render(, document.getElementById('navbar')); diff --git a/app/index.js b/app/index.js index 6fef119..2e7d8ce 100644 --- a/app/index.js +++ b/app/index.js @@ -1,5 +1,5 @@ import 'bootstrap/dist/css/bootstrap.css'; -import 'react-bootstrap-table/dist/react-bootstrap-table-all.min.css'; +import 'react-table/react-table.css' import React from 'react'; import ReactDOM from 'react-dom'; import ZNavbar from './components/navbar.jsx' diff --git a/dist/js/faq.js b/dist/js/faq.js index d1db5c1..881a7cc 100644 --- a/dist/js/faq.js +++ b/dist/js/faq.js @@ -60,7 +60,7 @@ /******/ __webpack_require__.p = ""; /******/ /******/ // Load entry module and return exports -/******/ return __webpack_require__(__webpack_require__.s = 562); +/******/ return __webpack_require__(__webpack_require__.s = 510); /******/ }) /************************************************************************/ /******/ ([ @@ -258,1325 +258,1805 @@ process.umask = function() { return 0; }; /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +/* WEBPACK VAR INJECTION */(function(global) {/*! + * The buffer module from node.js, for the browser. * + * @author Feross Aboukhadijeh + * @license MIT */ +/* eslint-disable no-proto */ + +var base64 = __webpack_require__(333) +var ieee754 = __webpack_require__(334) +var isArray = __webpack_require__(154) + +exports.Buffer = Buffer +exports.SlowBuffer = SlowBuffer +exports.INSPECT_MAX_BYTES = 50 /** - * Use invariant() to assert state which your program assumes to be true. + * If `Buffer.TYPED_ARRAY_SUPPORT`: + * === true Use Uint8Array implementation (fastest) + * === false Use Object implementation (most compatible, even IE6) * - * Provide sprintf-style format (only %s is supported) and arguments - * to provide information about what broke and what you were - * expecting. + * Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+, + * Opera 11.6+, iOS 4.2+. * - * The invariant message will be stripped in production, but the invariant - * will remain to ensure logic does not differ in production. + * Due to various browser bugs, sometimes the Object implementation will be used even + * when the browser supports typed arrays. + * + * Note: + * + * - Firefox 4-29 lacks support for adding new properties to `Uint8Array` instances, + * See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438. + * + * - Chrome 9-10 is missing the `TypedArray.prototype.subarray` function. + * + * - IE10 has a broken `TypedArray.prototype.subarray` function which returns arrays of + * incorrect length in some situations. + + * We detect these buggy browsers and set `Buffer.TYPED_ARRAY_SUPPORT` to `false` so they + * get the Object implementation, which is slower but behaves correctly. */ +Buffer.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== undefined + ? global.TYPED_ARRAY_SUPPORT + : typedArraySupport() -var validateFormat = function validateFormat(format) {}; +/* + * Export kMaxLength after typed array support is determined. + */ +exports.kMaxLength = kMaxLength() -if (process.env.NODE_ENV !== 'production') { - validateFormat = function validateFormat(format) { - if (format === undefined) { - throw new Error('invariant requires an error message argument'); - } - }; +function typedArraySupport () { + try { + var arr = new Uint8Array(1) + arr.__proto__ = {__proto__: Uint8Array.prototype, foo: function () { return 42 }} + return arr.foo() === 42 && // typed array instances can be augmented + typeof arr.subarray === 'function' && // chrome 9-10 lack `subarray` + arr.subarray(1, 1).byteLength === 0 // ie10 has broken `subarray` + } catch (e) { + return false + } } -function invariant(condition, format, a, b, c, d, e, f) { - validateFormat(format); +function kMaxLength () { + return Buffer.TYPED_ARRAY_SUPPORT + ? 0x7fffffff + : 0x3fffffff +} - if (!condition) { - var error; - if (format === undefined) { - error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); - } else { - var args = [a, b, c, d, e, f]; - var argIndex = 0; - error = new Error(format.replace(/%s/g, function () { - return args[argIndex++]; - })); - error.name = 'Invariant Violation'; +function createBuffer (that, length) { + if (kMaxLength() < length) { + throw new RangeError('Invalid typed array length') + } + if (Buffer.TYPED_ARRAY_SUPPORT) { + // Return an augmented `Uint8Array` instance, for best performance + that = new Uint8Array(length) + that.__proto__ = Buffer.prototype + } else { + // Fallback: Return an object instance of the Buffer class + if (that === null) { + that = new Buffer(length) } - - error.framesToPop = 1; // we don't care about invariant's own frame - throw error; + that.length = length } -} -module.exports = invariant; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 2 */ -/***/ (function(module, exports, __webpack_require__) { + return that +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +/** + * The Buffer constructor returns instances of `Uint8Array` that have their + * prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of + * `Uint8Array`, so the returned instances will have all the node `Buffer` methods + * and the `Uint8Array` methods. Square bracket notation works as expected -- it + * returns a single octet. * + * The `Uint8Array` prototype remains unmodified. */ +function Buffer (arg, encodingOrOffset, length) { + if (!Buffer.TYPED_ARRAY_SUPPORT && !(this instanceof Buffer)) { + return new Buffer(arg, encodingOrOffset, length) + } + // Common case. + if (typeof arg === 'number') { + if (typeof encodingOrOffset === 'string') { + throw new Error( + 'If encoding is specified then the first argument must be a string' + ) + } + return allocUnsafe(this, arg) + } + return from(this, arg, encodingOrOffset, length) +} -var emptyFunction = __webpack_require__(12); - -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ +Buffer.poolSize = 8192 // not used by this implementation -var warning = emptyFunction; +// TODO: Legacy, not needed anymore. Remove in next major version. +Buffer._augment = function (arr) { + arr.__proto__ = Buffer.prototype + return arr +} -if (process.env.NODE_ENV !== 'production') { - (function () { - var printWarning = function printWarning(format) { - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; - } +function from (that, value, encodingOrOffset, length) { + if (typeof value === 'number') { + throw new TypeError('"value" argument must not be a number') + } - var argIndex = 0; - var message = 'Warning: ' + format.replace(/%s/g, function () { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // --- Welcome to debugging React --- - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch (x) {} - }; + if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) { + return fromArrayBuffer(that, value, encodingOrOffset, length) + } - warning = function warning(condition, format) { - if (format === undefined) { - throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); - } + if (typeof value === 'string') { + return fromString(that, value, encodingOrOffset) + } - if (format.indexOf('Failed Composite propType: ') === 0) { - return; // Ignore CompositeComponent proptype check. - } + return fromObject(that, value) +} - if (!condition) { - for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { - args[_key2 - 2] = arguments[_key2]; - } +/** + * Functionally equivalent to Buffer(arg, encoding) but throws a TypeError + * if value is a number. + * Buffer.from(str[, encoding]) + * Buffer.from(array) + * Buffer.from(buffer) + * Buffer.from(arrayBuffer[, byteOffset[, length]]) + **/ +Buffer.from = function (value, encodingOrOffset, length) { + return from(null, value, encodingOrOffset, length) +} - printWarning.apply(undefined, [format].concat(args)); - } - }; - })(); +if (Buffer.TYPED_ARRAY_SUPPORT) { + Buffer.prototype.__proto__ = Uint8Array.prototype + Buffer.__proto__ = Uint8Array + if (typeof Symbol !== 'undefined' && Symbol.species && + Buffer[Symbol.species] === Buffer) { + // Fix subarray() in ES2016. See: https://github.com/feross/buffer/pull/97 + Object.defineProperty(Buffer, Symbol.species, { + value: null, + configurable: true + }) + } } -module.exports = warning; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function assertSize (size) { + if (typeof size !== 'number') { + throw new TypeError('"size" argument must be a number') + } else if (size < 0) { + throw new RangeError('"size" argument must not be negative') + } +} -/***/ }), -/* 3 */ -/***/ (function(module, exports, __webpack_require__) { +function alloc (that, size, fill, encoding) { + assertSize(size) + if (size <= 0) { + return createBuffer(that, size) + } + if (fill !== undefined) { + // Only pay attention to encoding if it's a string. This + // prevents accidentally sending in a number that would + // be interpretted as a start offset. + return typeof encoding === 'string' + ? createBuffer(that, size).fill(fill, encoding) + : createBuffer(that, size).fill(fill) + } + return createBuffer(that, size) +} -"use strict"; /** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + * Creates a new filled Buffer instance. + * alloc(size[, fill[, encoding]]) + **/ +Buffer.alloc = function (size, fill, encoding) { + return alloc(null, size, fill, encoding) +} +function allocUnsafe (that, size) { + assertSize(size) + that = createBuffer(that, size < 0 ? 0 : checked(size) | 0) + if (!Buffer.TYPED_ARRAY_SUPPORT) { + for (var i = 0; i < size; ++i) { + that[i] = 0 + } + } + return that +} /** - * WARNING: DO NOT manually require this module. - * This is a replacement for `invariant(...)` used by the error code system - * and will _only_ be required by the corresponding babel pass. - * It always throws. + * Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance. + * */ +Buffer.allocUnsafe = function (size) { + return allocUnsafe(null, size) +} +/** + * Equivalent to SlowBuffer(num), by default creates a non-zero-filled Buffer instance. */ +Buffer.allocUnsafeSlow = function (size) { + return allocUnsafe(null, size) +} -function reactProdInvariant(code) { - var argCount = arguments.length - 1; +function fromString (that, string, encoding) { + if (typeof encoding !== 'string' || encoding === '') { + encoding = 'utf8' + } - var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; + if (!Buffer.isEncoding(encoding)) { + throw new TypeError('"encoding" must be a valid string encoding') + } - for (var argIdx = 0; argIdx < argCount; argIdx++) { - message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); + var length = byteLength(string, encoding) | 0 + that = createBuffer(that, length) + + var actual = that.write(string, encoding) + + if (actual !== length) { + // Writing a hex string, for example, that contains invalid characters will + // cause everything after the first invalid character to be ignored. (e.g. + // 'abxxcd' will be treated as 'ab') + that = that.slice(0, actual) } - message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; + return that +} - var error = new Error(message); - error.name = 'Invariant Violation'; - error.framesToPop = 1; // we don't care about reactProdInvariant's own frame +function fromArrayLike (that, array) { + var length = array.length < 0 ? 0 : checked(array.length) | 0 + that = createBuffer(that, length) + for (var i = 0; i < length; i += 1) { + that[i] = array[i] & 255 + } + return that +} - throw error; +function fromArrayBuffer (that, array, byteOffset, length) { + array.byteLength // this throws if `array` is not a valid ArrayBuffer + + if (byteOffset < 0 || array.byteLength < byteOffset) { + throw new RangeError('\'offset\' is out of bounds') + } + + if (array.byteLength < byteOffset + (length || 0)) { + throw new RangeError('\'length\' is out of bounds') + } + + if (byteOffset === undefined && length === undefined) { + array = new Uint8Array(array) + } else if (length === undefined) { + array = new Uint8Array(array, byteOffset) + } else { + array = new Uint8Array(array, byteOffset, length) + } + + if (Buffer.TYPED_ARRAY_SUPPORT) { + // Return an augmented `Uint8Array` instance, for best performance + that = array + that.__proto__ = Buffer.prototype + } else { + // Fallback: Return an object instance of the Buffer class + that = fromArrayLike(that, array) + } + return that } -module.exports = reactProdInvariant; +function fromObject (that, obj) { + if (Buffer.isBuffer(obj)) { + var len = checked(obj.length) | 0 + that = createBuffer(that, len) -/***/ }), -/* 4 */ -/***/ (function(module, exports, __webpack_require__) { + if (that.length === 0) { + return that + } -"use strict"; + obj.copy(that, 0, 0, len) + return that + } + if (obj) { + if ((typeof ArrayBuffer !== 'undefined' && + obj.buffer instanceof ArrayBuffer) || 'length' in obj) { + if (typeof obj.length !== 'number' || isnan(obj.length)) { + return createBuffer(that, 0) + } + return fromArrayLike(that, obj) + } -module.exports = __webpack_require__(24); + if (obj.type === 'Buffer' && isArray(obj.data)) { + return fromArrayLike(that, obj.data) + } + } + throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.') +} -/***/ }), -/* 5 */ -/***/ (function(module, exports, __webpack_require__) { +function checked (length) { + // Note: cannot use `length < kMaxLength()` here because that fails when + // length is NaN (which is otherwise coerced to zero.) + if (length >= kMaxLength()) { + throw new RangeError('Attempt to allocate Buffer larger than maximum ' + + 'size: 0x' + kMaxLength().toString(16) + ' bytes') + } + return length | 0 +} -"use strict"; -/* -object-assign -(c) Sindre Sorhus -@license MIT -*/ +function SlowBuffer (length) { + if (+length != length) { // eslint-disable-line eqeqeq + length = 0 + } + return Buffer.alloc(+length) +} +Buffer.isBuffer = function isBuffer (b) { + return !!(b != null && b._isBuffer) +} -/* eslint-disable no-unused-vars */ -var getOwnPropertySymbols = Object.getOwnPropertySymbols; -var hasOwnProperty = Object.prototype.hasOwnProperty; -var propIsEnumerable = Object.prototype.propertyIsEnumerable; +Buffer.compare = function compare (a, b) { + if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) { + throw new TypeError('Arguments must be Buffers') + } -function toObject(val) { - if (val === null || val === undefined) { - throw new TypeError('Object.assign cannot be called with null or undefined'); - } + if (a === b) return 0 - return Object(val); + var x = a.length + var y = b.length + + for (var i = 0, len = Math.min(x, y); i < len; ++i) { + if (a[i] !== b[i]) { + x = a[i] + y = b[i] + break + } + } + + if (x < y) return -1 + if (y < x) return 1 + return 0 } -function shouldUseNative() { - try { - if (!Object.assign) { - return false; - } +Buffer.isEncoding = function isEncoding (encoding) { + switch (String(encoding).toLowerCase()) { + case 'hex': + case 'utf8': + case 'utf-8': + case 'ascii': + case 'latin1': + case 'binary': + case 'base64': + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return true + default: + return false + } +} - // Detect buggy property enumeration order in older V8 versions. +Buffer.concat = function concat (list, length) { + if (!isArray(list)) { + throw new TypeError('"list" argument must be an Array of Buffers') + } - // https://bugs.chromium.org/p/v8/issues/detail?id=4118 - var test1 = new String('abc'); // eslint-disable-line no-new-wrappers - test1[5] = 'de'; - if (Object.getOwnPropertyNames(test1)[0] === '5') { - return false; - } + if (list.length === 0) { + return Buffer.alloc(0) + } - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test2 = {}; - for (var i = 0; i < 10; i++) { - test2['_' + String.fromCharCode(i)] = i; - } - var order2 = Object.getOwnPropertyNames(test2).map(function (n) { - return test2[n]; - }); - if (order2.join('') !== '0123456789') { - return false; - } + var i + if (length === undefined) { + length = 0 + for (i = 0; i < list.length; ++i) { + length += list[i].length + } + } - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test3 = {}; - 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { - test3[letter] = letter; - }); - if (Object.keys(Object.assign({}, test3)).join('') !== - 'abcdefghijklmnopqrst') { - return false; - } + var buffer = Buffer.allocUnsafe(length) + var pos = 0 + for (i = 0; i < list.length; ++i) { + var buf = list[i] + if (!Buffer.isBuffer(buf)) { + throw new TypeError('"list" argument must be an Array of Buffers') + } + buf.copy(buffer, pos) + pos += buf.length + } + return buffer +} - return true; - } catch (err) { - // We don't expect any of the above to throw, but better to be safe. - return false; - } +function byteLength (string, encoding) { + if (Buffer.isBuffer(string)) { + return string.length + } + if (typeof ArrayBuffer !== 'undefined' && typeof ArrayBuffer.isView === 'function' && + (ArrayBuffer.isView(string) || string instanceof ArrayBuffer)) { + return string.byteLength + } + if (typeof string !== 'string') { + string = '' + string + } + + var len = string.length + if (len === 0) return 0 + + // Use a for loop to avoid recursion + var loweredCase = false + for (;;) { + switch (encoding) { + case 'ascii': + case 'latin1': + case 'binary': + return len + case 'utf8': + case 'utf-8': + case undefined: + return utf8ToBytes(string).length + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return len * 2 + case 'hex': + return len >>> 1 + case 'base64': + return base64ToBytes(string).length + default: + if (loweredCase) return utf8ToBytes(string).length // assume utf8 + encoding = ('' + encoding).toLowerCase() + loweredCase = true + } + } } +Buffer.byteLength = byteLength -module.exports = shouldUseNative() ? Object.assign : function (target, source) { - var from; - var to = toObject(target); - var symbols; +function slowToString (encoding, start, end) { + var loweredCase = false - for (var s = 1; s < arguments.length; s++) { - from = Object(arguments[s]); + // No need to verify that "this.length <= MAX_UINT32" since it's a read-only + // property of a typed array. - for (var key in from) { - if (hasOwnProperty.call(from, key)) { - to[key] = from[key]; - } - } + // This behaves neither like String nor Uint8Array in that we set start/end + // to their upper/lower bounds if the value passed is out of range. + // undefined is handled specially as per ECMA-262 6th Edition, + // Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization. + if (start === undefined || start < 0) { + start = 0 + } + // Return early if start > this.length. Done here to prevent potential uint32 + // coercion fail below. + if (start > this.length) { + return '' + } - if (getOwnPropertySymbols) { - symbols = getOwnPropertySymbols(from); - for (var i = 0; i < symbols.length; i++) { - if (propIsEnumerable.call(from, symbols[i])) { - to[symbols[i]] = from[symbols[i]]; - } - } - } - } + if (end === undefined || end > this.length) { + end = this.length + } - return to; -}; + if (end <= 0) { + return '' + } + // Force coersion to uint32. This will also coerce falsey/NaN values to 0. + end >>>= 0 + start >>>= 0 -/***/ }), -/* 6 */ -/***/ (function(module, exports, __webpack_require__) { + if (end <= start) { + return '' + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + if (!encoding) encoding = 'utf8' + while (true) { + switch (encoding) { + case 'hex': + return hexSlice(this, start, end) + case 'utf8': + case 'utf-8': + return utf8Slice(this, start, end) -var _prodInvariant = __webpack_require__(3); + case 'ascii': + return asciiSlice(this, start, end) -var DOMProperty = __webpack_require__(17); -var ReactDOMComponentFlags = __webpack_require__(81); + case 'latin1': + case 'binary': + return latin1Slice(this, start, end) -var invariant = __webpack_require__(1); + case 'base64': + return base64Slice(this, start, end) -var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; -var Flags = ReactDOMComponentFlags; + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return utf16leSlice(this, start, end) -var internalInstanceKey = '__reactInternalInstance$' + Math.random().toString(36).slice(2); + default: + if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding) + encoding = (encoding + '').toLowerCase() + loweredCase = true + } + } +} -/** - * Check if a given node should be cached. - */ -function shouldPrecacheNode(node, nodeID) { - return node.nodeType === 1 && node.getAttribute(ATTR_NAME) === String(nodeID) || node.nodeType === 8 && node.nodeValue === ' react-text: ' + nodeID + ' ' || node.nodeType === 8 && node.nodeValue === ' react-empty: ' + nodeID + ' '; +// The property is used by `Buffer.isBuffer` and `is-buffer` (in Safari 5-7) to detect +// Buffer instances. +Buffer.prototype._isBuffer = true + +function swap (b, n, m) { + var i = b[n] + b[n] = b[m] + b[m] = i } -/** - * Drill down (through composites and empty components) until we get a host or - * host text component. - * - * This is pretty polymorphic but unavoidable with the current structure we have - * for `_renderedChildren`. - */ -function getRenderedHostOrTextFromComponent(component) { - var rendered; - while (rendered = component._renderedComponent) { - component = rendered; +Buffer.prototype.swap16 = function swap16 () { + var len = this.length + if (len % 2 !== 0) { + throw new RangeError('Buffer size must be a multiple of 16-bits') } - return component; + for (var i = 0; i < len; i += 2) { + swap(this, i, i + 1) + } + return this } -/** - * Populate `_hostNode` on the rendered host/text component with the given - * DOM node. The passed `inst` can be a composite. - */ -function precacheNode(inst, node) { - var hostInst = getRenderedHostOrTextFromComponent(inst); - hostInst._hostNode = node; - node[internalInstanceKey] = hostInst; +Buffer.prototype.swap32 = function swap32 () { + var len = this.length + if (len % 4 !== 0) { + throw new RangeError('Buffer size must be a multiple of 32-bits') + } + for (var i = 0; i < len; i += 4) { + swap(this, i, i + 3) + swap(this, i + 1, i + 2) + } + return this } -function uncacheNode(inst) { - var node = inst._hostNode; - if (node) { - delete node[internalInstanceKey]; - inst._hostNode = null; +Buffer.prototype.swap64 = function swap64 () { + var len = this.length + if (len % 8 !== 0) { + throw new RangeError('Buffer size must be a multiple of 64-bits') + } + for (var i = 0; i < len; i += 8) { + swap(this, i, i + 7) + swap(this, i + 1, i + 6) + swap(this, i + 2, i + 5) + swap(this, i + 3, i + 4) } + return this } -/** - * Populate `_hostNode` on each child of `inst`, assuming that the children - * match up with the DOM (element) children of `node`. - * - * We cache entire levels at once to avoid an n^2 problem where we access the - * children of a node sequentially and have to walk from the start to our target - * node every time. - * - * Since we update `_renderedChildren` and the actual DOM at (slightly) - * different times, we could race here and see a newer `_renderedChildren` than - * the DOM nodes we see. To avoid this, ReactMultiChild calls - * `prepareToManageChildren` before we change `_renderedChildren`, at which - * time the container's child nodes are always cached (until it unmounts). - */ -function precacheChildNodes(inst, node) { - if (inst._flags & Flags.hasCachedChildNodes) { - return; +Buffer.prototype.toString = function toString () { + var length = this.length | 0 + if (length === 0) return '' + if (arguments.length === 0) return utf8Slice(this, 0, length) + return slowToString.apply(this, arguments) +} + +Buffer.prototype.equals = function equals (b) { + if (!Buffer.isBuffer(b)) throw new TypeError('Argument must be a Buffer') + if (this === b) return true + return Buffer.compare(this, b) === 0 +} + +Buffer.prototype.inspect = function inspect () { + var str = '' + var max = exports.INSPECT_MAX_BYTES + if (this.length > 0) { + str = this.toString('hex', 0, max).match(/.{2}/g).join(' ') + if (this.length > max) str += ' ... ' } - var children = inst._renderedChildren; - var childNode = node.firstChild; - outer: for (var name in children) { - if (!children.hasOwnProperty(name)) { - continue; - } - var childInst = children[name]; - var childID = getRenderedHostOrTextFromComponent(childInst)._domID; - if (childID === 0) { - // We're currently unmounting this child in ReactMultiChild; skip it. - continue; + return '' +} + +Buffer.prototype.compare = function compare (target, start, end, thisStart, thisEnd) { + if (!Buffer.isBuffer(target)) { + throw new TypeError('Argument must be a Buffer') + } + + if (start === undefined) { + start = 0 + } + if (end === undefined) { + end = target ? target.length : 0 + } + if (thisStart === undefined) { + thisStart = 0 + } + if (thisEnd === undefined) { + thisEnd = this.length + } + + if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) { + throw new RangeError('out of range index') + } + + if (thisStart >= thisEnd && start >= end) { + return 0 + } + if (thisStart >= thisEnd) { + return -1 + } + if (start >= end) { + return 1 + } + + start >>>= 0 + end >>>= 0 + thisStart >>>= 0 + thisEnd >>>= 0 + + if (this === target) return 0 + + var x = thisEnd - thisStart + var y = end - start + var len = Math.min(x, y) + + var thisCopy = this.slice(thisStart, thisEnd) + var targetCopy = target.slice(start, end) + + for (var i = 0; i < len; ++i) { + if (thisCopy[i] !== targetCopy[i]) { + x = thisCopy[i] + y = targetCopy[i] + break } - // We assume the child nodes are in the same order as the child instances. - for (; childNode !== null; childNode = childNode.nextSibling) { - if (shouldPrecacheNode(childNode, childID)) { - precacheNode(childInst, childNode); - continue outer; + } + + if (x < y) return -1 + if (y < x) return 1 + return 0 +} + +// Finds either the first index of `val` in `buffer` at offset >= `byteOffset`, +// OR the last index of `val` in `buffer` at offset <= `byteOffset`. +// +// Arguments: +// - buffer - a Buffer to search +// - val - a string, Buffer, or number +// - byteOffset - an index into `buffer`; will be clamped to an int32 +// - encoding - an optional encoding, relevant is val is a string +// - dir - true for indexOf, false for lastIndexOf +function bidirectionalIndexOf (buffer, val, byteOffset, encoding, dir) { + // Empty buffer means no match + if (buffer.length === 0) return -1 + + // Normalize byteOffset + if (typeof byteOffset === 'string') { + encoding = byteOffset + byteOffset = 0 + } else if (byteOffset > 0x7fffffff) { + byteOffset = 0x7fffffff + } else if (byteOffset < -0x80000000) { + byteOffset = -0x80000000 + } + byteOffset = +byteOffset // Coerce to Number. + if (isNaN(byteOffset)) { + // byteOffset: it it's undefined, null, NaN, "foo", etc, search whole buffer + byteOffset = dir ? 0 : (buffer.length - 1) + } + + // Normalize byteOffset: negative offsets start from the end of the buffer + if (byteOffset < 0) byteOffset = buffer.length + byteOffset + if (byteOffset >= buffer.length) { + if (dir) return -1 + else byteOffset = buffer.length - 1 + } else if (byteOffset < 0) { + if (dir) byteOffset = 0 + else return -1 + } + + // Normalize val + if (typeof val === 'string') { + val = Buffer.from(val, encoding) + } + + // Finally, search either indexOf (if dir is true) or lastIndexOf + if (Buffer.isBuffer(val)) { + // Special case: looking for empty string/buffer always fails + if (val.length === 0) { + return -1 + } + return arrayIndexOf(buffer, val, byteOffset, encoding, dir) + } else if (typeof val === 'number') { + val = val & 0xFF // Search for a byte value [0-255] + if (Buffer.TYPED_ARRAY_SUPPORT && + typeof Uint8Array.prototype.indexOf === 'function') { + if (dir) { + return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset) + } else { + return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset) } } - // We reached the end of the DOM children without finding an ID match. - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unable to find element with ID %s.', childID) : _prodInvariant('32', childID) : void 0; + return arrayIndexOf(buffer, [ val ], byteOffset, encoding, dir) } - inst._flags |= Flags.hasCachedChildNodes; + + throw new TypeError('val must be string, number or Buffer') } -/** - * Given a DOM node, return the closest ReactDOMComponent or - * ReactDOMTextComponent instance ancestor. - */ -function getClosestInstanceFromNode(node) { - if (node[internalInstanceKey]) { - return node[internalInstanceKey]; +function arrayIndexOf (arr, val, byteOffset, encoding, dir) { + var indexSize = 1 + var arrLength = arr.length + var valLength = val.length + + if (encoding !== undefined) { + encoding = String(encoding).toLowerCase() + if (encoding === 'ucs2' || encoding === 'ucs-2' || + encoding === 'utf16le' || encoding === 'utf-16le') { + if (arr.length < 2 || val.length < 2) { + return -1 + } + indexSize = 2 + arrLength /= 2 + valLength /= 2 + byteOffset /= 2 + } } - // Walk up the tree until we find an ancestor whose instance we have cached. - var parents = []; - while (!node[internalInstanceKey]) { - parents.push(node); - if (node.parentNode) { - node = node.parentNode; + function read (buf, i) { + if (indexSize === 1) { + return buf[i] } else { - // Top of the tree. This node must not be part of a React tree (or is - // unmounted, potentially). - return null; + return buf.readUInt16BE(i * indexSize) } } - var closest; - var inst; - for (; node && (inst = node[internalInstanceKey]); node = parents.pop()) { - closest = inst; - if (parents.length) { - precacheChildNodes(inst, node); + var i + if (dir) { + var foundIndex = -1 + for (i = byteOffset; i < arrLength; i++) { + if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) { + if (foundIndex === -1) foundIndex = i + if (i - foundIndex + 1 === valLength) return foundIndex * indexSize + } else { + if (foundIndex !== -1) i -= i - foundIndex + foundIndex = -1 + } + } + } else { + if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength + for (i = byteOffset; i >= 0; i--) { + var found = true + for (var j = 0; j < valLength; j++) { + if (read(arr, i + j) !== read(val, j)) { + found = false + break + } + } + if (found) return i } } - return closest; + return -1 } -/** - * Given a DOM node, return the ReactDOMComponent or ReactDOMTextComponent - * instance, or null if the node was not rendered by this React. - */ -function getInstanceFromNode(node) { - var inst = getClosestInstanceFromNode(node); - if (inst != null && inst._hostNode === node) { - return inst; - } else { - return null; - } +Buffer.prototype.includes = function includes (val, byteOffset, encoding) { + return this.indexOf(val, byteOffset, encoding) !== -1 } -/** - * Given a ReactDOMComponent or ReactDOMTextComponent, return the corresponding - * DOM node. - */ -function getNodeFromInstance(inst) { - // Without this first invariant, passing a non-DOM-component triggers the next - // invariant for a missing parent, which is super confusing. - !(inst._hostNode !== undefined) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; +Buffer.prototype.indexOf = function indexOf (val, byteOffset, encoding) { + return bidirectionalIndexOf(this, val, byteOffset, encoding, true) +} - if (inst._hostNode) { - return inst._hostNode; - } +Buffer.prototype.lastIndexOf = function lastIndexOf (val, byteOffset, encoding) { + return bidirectionalIndexOf(this, val, byteOffset, encoding, false) +} - // Walk up the tree until we find an ancestor whose DOM node we have cached. - var parents = []; - while (!inst._hostNode) { - parents.push(inst); - !inst._hostParent ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React DOM tree root should always have a node reference.') : _prodInvariant('34') : void 0; - inst = inst._hostParent; +function hexWrite (buf, string, offset, length) { + offset = Number(offset) || 0 + var remaining = buf.length - offset + if (!length) { + length = remaining + } else { + length = Number(length) + if (length > remaining) { + length = remaining + } } - // Now parents contains each ancestor that does *not* have a cached native - // node, and `inst` is the deepest ancestor that does. - for (; parents.length; inst = parents.pop()) { - precacheChildNodes(inst, inst._hostNode); + // must be an even number of digits + var strLen = string.length + if (strLen % 2 !== 0) throw new TypeError('Invalid hex string') + + if (length > strLen / 2) { + length = strLen / 2 + } + for (var i = 0; i < length; ++i) { + var parsed = parseInt(string.substr(i * 2, 2), 16) + if (isNaN(parsed)) return i + buf[offset + i] = parsed } + return i +} - return inst._hostNode; +function utf8Write (buf, string, offset, length) { + return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length) } -var ReactDOMComponentTree = { - getClosestInstanceFromNode: getClosestInstanceFromNode, - getInstanceFromNode: getInstanceFromNode, - getNodeFromInstance: getNodeFromInstance, - precacheChildNodes: precacheChildNodes, - precacheNode: precacheNode, - uncacheNode: uncacheNode -}; +function asciiWrite (buf, string, offset, length) { + return blitBuffer(asciiToBytes(string), buf, offset, length) +} -module.exports = ReactDOMComponentTree; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function latin1Write (buf, string, offset, length) { + return asciiWrite(buf, string, offset, length) +} -/***/ }), -/* 7 */, -/* 8 */ -/***/ (function(module, exports, __webpack_require__) { +function base64Write (buf, string, offset, length) { + return blitBuffer(base64ToBytes(string), buf, offset, length) +} -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function ucs2Write (buf, string, offset, length) { + return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length) +} +Buffer.prototype.write = function write (string, offset, length, encoding) { + // Buffer#write(string) + if (offset === undefined) { + encoding = 'utf8' + length = this.length + offset = 0 + // Buffer#write(string, encoding) + } else if (length === undefined && typeof offset === 'string') { + encoding = offset + length = this.length + offset = 0 + // Buffer#write(string, offset[, length][, encoding]) + } else if (isFinite(offset)) { + offset = offset | 0 + if (isFinite(length)) { + length = length | 0 + if (encoding === undefined) encoding = 'utf8' + } else { + encoding = length + length = undefined + } + // legacy write(string, encoding, offset, length) - remove in v0.13 + } else { + throw new Error( + 'Buffer.write(string, encoding, offset[, length]) is no longer supported' + ) + } + var remaining = this.length - offset + if (length === undefined || length > remaining) length = remaining -var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); + if ((string.length > 0 && (length < 0 || offset < 0)) || offset > this.length) { + throw new RangeError('Attempt to write outside buffer bounds') + } -/** - * Simple, lightweight module assisting with the detection and context of - * Worker. Helps avoid circular dependencies and allows code to reason about - * whether or not they are in a Worker, even if they never include the main - * `ReactWorker` dependency. - */ -var ExecutionEnvironment = { + if (!encoding) encoding = 'utf8' - canUseDOM: canUseDOM, + var loweredCase = false + for (;;) { + switch (encoding) { + case 'hex': + return hexWrite(this, string, offset, length) - canUseWorkers: typeof Worker !== 'undefined', + case 'utf8': + case 'utf-8': + return utf8Write(this, string, offset, length) - canUseEventListeners: canUseDOM && !!(window.addEventListener || window.attachEvent), + case 'ascii': + return asciiWrite(this, string, offset, length) - canUseViewport: canUseDOM && !!window.screen, + case 'latin1': + case 'binary': + return latin1Write(this, string, offset, length) - isInWorker: !canUseDOM // For now, this is true - might change in the future. + case 'base64': + // Warning: maxLength not taken into account in base64Write + return base64Write(this, string, offset, length) -}; + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return ucs2Write(this, string, offset, length) -module.exports = ExecutionEnvironment; + default: + if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding) + encoding = ('' + encoding).toLowerCase() + loweredCase = true + } + } +} -/***/ }), -/* 9 */ -/***/ (function(module, exports, __webpack_require__) { +Buffer.prototype.toJSON = function toJSON () { + return { + type: 'Buffer', + data: Array.prototype.slice.call(this._arr || this, 0) + } +} -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +function base64Slice (buf, start, end) { + if (start === 0 && end === buf.length) { + return base64.fromByteArray(buf) + } else { + return base64.fromByteArray(buf.slice(start, end)) + } +} -if (process.env.NODE_ENV !== 'production') { - var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && - Symbol.for && - Symbol.for('react.element')) || - 0xeac7; +function utf8Slice (buf, start, end) { + end = Math.min(buf.length, end) + var res = [] + + var i = start + while (i < end) { + var firstByte = buf[i] + var codePoint = null + var bytesPerSequence = (firstByte > 0xEF) ? 4 + : (firstByte > 0xDF) ? 3 + : (firstByte > 0xBF) ? 2 + : 1 + + if (i + bytesPerSequence <= end) { + var secondByte, thirdByte, fourthByte, tempCodePoint + + switch (bytesPerSequence) { + case 1: + if (firstByte < 0x80) { + codePoint = firstByte + } + break + case 2: + secondByte = buf[i + 1] + if ((secondByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0x1F) << 0x6 | (secondByte & 0x3F) + if (tempCodePoint > 0x7F) { + codePoint = tempCodePoint + } + } + break + case 3: + secondByte = buf[i + 1] + thirdByte = buf[i + 2] + if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | (thirdByte & 0x3F) + if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) { + codePoint = tempCodePoint + } + } + break + case 4: + secondByte = buf[i + 1] + thirdByte = buf[i + 2] + fourthByte = buf[i + 3] + if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | (fourthByte & 0x3F) + if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) { + codePoint = tempCodePoint + } + } + } + } - var isValidElement = function(object) { - return typeof object === 'object' && - object !== null && - object.$$typeof === REACT_ELEMENT_TYPE; - }; + if (codePoint === null) { + // we did not generate a valid codePoint so insert a + // replacement char (U+FFFD) and advance only 1 byte + codePoint = 0xFFFD + bytesPerSequence = 1 + } else if (codePoint > 0xFFFF) { + // encode to utf16 (surrogate pair dance) + codePoint -= 0x10000 + res.push(codePoint >>> 10 & 0x3FF | 0xD800) + codePoint = 0xDC00 | codePoint & 0x3FF + } - // By explicitly using `prop-types` you are opting into new development behavior. - // http://fb.me/prop-types-in-prod - var throwOnDirectAccess = true; - module.exports = __webpack_require__(80)(isValidElement, throwOnDirectAccess); -} else { - // By explicitly using `prop-types` you are opting into new production behavior. - // http://fb.me/prop-types-in-prod - module.exports = __webpack_require__(221)(); + res.push(codePoint) + i += bytesPerSequence + } + + return decodeCodePointsArray(res) } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +// Based on http://stackoverflow.com/a/22747272/680742, the browser with +// the lowest limit is Chrome, with 0x10000 args. +// We go 1 magnitude less, for safety +var MAX_ARGUMENTS_LENGTH = 0x1000 -/***/ }), -/* 10 */ -/***/ (function(module, exports, __webpack_require__) { +function decodeCodePointsArray (codePoints) { + var len = codePoints.length + if (len <= MAX_ARGUMENTS_LENGTH) { + return String.fromCharCode.apply(String, codePoints) // avoid extra slice() + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + // Decode in chunks to avoid "call stack size exceeded". + var res = '' + var i = 0 + while (i < len) { + res += String.fromCharCode.apply( + String, + codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH) + ) + } + return res +} +function asciiSlice (buf, start, end) { + var ret = '' + end = Math.min(buf.length, end) + for (var i = start; i < end; ++i) { + ret += String.fromCharCode(buf[i] & 0x7F) + } + return ret +} -var _prodInvariant = __webpack_require__(25); +function latin1Slice (buf, start, end) { + var ret = '' + end = Math.min(buf.length, end) -var ReactCurrentOwner = __webpack_require__(14); + for (var i = start; i < end; ++i) { + ret += String.fromCharCode(buf[i]) + } + return ret +} -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +function hexSlice (buf, start, end) { + var len = buf.length -function isNative(fn) { - // Based on isNative() from Lodash - var funcToString = Function.prototype.toString; - var hasOwnProperty = Object.prototype.hasOwnProperty; - var reIsNative = RegExp('^' + funcToString - // Take an example native function source for comparison - .call(hasOwnProperty - // Strip regex characters so we can use it for regex - ).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&' - // Remove hasOwnProperty from the template to make it generic - ).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'); - try { - var source = funcToString.call(fn); - return reIsNative.test(source); - } catch (err) { - return false; + if (!start || start < 0) start = 0 + if (!end || end < 0 || end > len) end = len + + var out = '' + for (var i = start; i < end; ++i) { + out += toHex(buf[i]) } + return out } -var canUseCollections = -// Array.from -typeof Array.from === 'function' && -// Map -typeof Map === 'function' && isNative(Map) && -// Map.prototype.keys -Map.prototype != null && typeof Map.prototype.keys === 'function' && isNative(Map.prototype.keys) && -// Set -typeof Set === 'function' && isNative(Set) && -// Set.prototype.keys -Set.prototype != null && typeof Set.prototype.keys === 'function' && isNative(Set.prototype.keys); - -var setItem; -var getItem; -var removeItem; -var getItemIDs; -var addRoot; -var removeRoot; -var getRootIDs; +function utf16leSlice (buf, start, end) { + var bytes = buf.slice(start, end) + var res = '' + for (var i = 0; i < bytes.length; i += 2) { + res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256) + } + return res +} -if (canUseCollections) { - var itemMap = new Map(); - var rootIDSet = new Set(); +Buffer.prototype.slice = function slice (start, end) { + var len = this.length + start = ~~start + end = end === undefined ? len : ~~end - setItem = function (id, item) { - itemMap.set(id, item); - }; - getItem = function (id) { - return itemMap.get(id); - }; - removeItem = function (id) { - itemMap['delete'](id); - }; - getItemIDs = function () { - return Array.from(itemMap.keys()); - }; + if (start < 0) { + start += len + if (start < 0) start = 0 + } else if (start > len) { + start = len + } - addRoot = function (id) { - rootIDSet.add(id); - }; - removeRoot = function (id) { - rootIDSet['delete'](id); - }; - getRootIDs = function () { - return Array.from(rootIDSet.keys()); - }; -} else { - var itemByKey = {}; - var rootByKey = {}; + if (end < 0) { + end += len + if (end < 0) end = 0 + } else if (end > len) { + end = len + } - // Use non-numeric keys to prevent V8 performance issues: - // https://github.com/facebook/react/pull/7232 - var getKeyFromID = function (id) { - return '.' + id; - }; - var getIDFromKey = function (key) { - return parseInt(key.substr(1), 10); - }; + if (end < start) end = start - setItem = function (id, item) { - var key = getKeyFromID(id); - itemByKey[key] = item; - }; - getItem = function (id) { - var key = getKeyFromID(id); - return itemByKey[key]; - }; - removeItem = function (id) { - var key = getKeyFromID(id); - delete itemByKey[key]; - }; - getItemIDs = function () { - return Object.keys(itemByKey).map(getIDFromKey); - }; + var newBuf + if (Buffer.TYPED_ARRAY_SUPPORT) { + newBuf = this.subarray(start, end) + newBuf.__proto__ = Buffer.prototype + } else { + var sliceLen = end - start + newBuf = new Buffer(sliceLen, undefined) + for (var i = 0; i < sliceLen; ++i) { + newBuf[i] = this[i + start] + } + } - addRoot = function (id) { - var key = getKeyFromID(id); - rootByKey[key] = true; - }; - removeRoot = function (id) { - var key = getKeyFromID(id); - delete rootByKey[key]; - }; - getRootIDs = function () { - return Object.keys(rootByKey).map(getIDFromKey); - }; + return newBuf } -var unmountedIDs = []; +/* + * Need to make sure that buffer isn't trying to write out of bounds. + */ +function checkOffset (offset, ext, length) { + if ((offset % 1) !== 0 || offset < 0) throw new RangeError('offset is not uint') + if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length') +} -function purgeDeep(id) { - var item = getItem(id); - if (item) { - var childIDs = item.childIDs; +Buffer.prototype.readUIntLE = function readUIntLE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) - removeItem(id); - childIDs.forEach(purgeDeep); + var val = this[offset] + var mul = 1 + var i = 0 + while (++i < byteLength && (mul *= 0x100)) { + val += this[offset + i] * mul } -} -function describeComponentFrame(name, source, ownerName) { - return '\n in ' + (name || 'Unknown') + (source ? ' (at ' + source.fileName.replace(/^.*[\\\/]/, '') + ':' + source.lineNumber + ')' : ownerName ? ' (created by ' + ownerName + ')' : ''); + return val } -function getDisplayName(element) { - if (element == null) { - return '#empty'; - } else if (typeof element === 'string' || typeof element === 'number') { - return '#text'; - } else if (typeof element.type === 'string') { - return element.type; - } else { - return element.type.displayName || element.type.name || 'Unknown'; +Buffer.prototype.readUIntBE = function readUIntBE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + checkOffset(offset, byteLength, this.length) } -} -function describeID(id) { - var name = ReactComponentTreeHook.getDisplayName(id); - var element = ReactComponentTreeHook.getElement(id); - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var ownerName; - if (ownerID) { - ownerName = ReactComponentTreeHook.getDisplayName(ownerID); + var val = this[offset + --byteLength] + var mul = 1 + while (byteLength > 0 && (mul *= 0x100)) { + val += this[offset + --byteLength] * mul } - process.env.NODE_ENV !== 'production' ? warning(element, 'ReactComponentTreeHook: Missing React element for debugID %s when ' + 'building stack', id) : void 0; - return describeComponentFrame(name, element && element._source, ownerName); + + return val } -var ReactComponentTreeHook = { - onSetChildren: function (id, nextChildIDs) { - var item = getItem(id); - !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; - item.childIDs = nextChildIDs; +Buffer.prototype.readUInt8 = function readUInt8 (offset, noAssert) { + if (!noAssert) checkOffset(offset, 1, this.length) + return this[offset] +} - for (var i = 0; i < nextChildIDs.length; i++) { - var nextChildID = nextChildIDs[i]; - var nextChild = getItem(nextChildID); - !nextChild ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected hook events to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('140') : void 0; - !(nextChild.childIDs != null || typeof nextChild.element !== 'object' || nextChild.element == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onSetChildren() to fire for a container child before its parent includes it in onSetChildren().') : _prodInvariant('141') : void 0; - !nextChild.isMounted ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onMountComponent() to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('71') : void 0; - if (nextChild.parentID == null) { - nextChild.parentID = id; - // TODO: This shouldn't be necessary but mounting a new root during in - // componentWillMount currently causes not-yet-mounted components to - // be purged from our tree data so their parent id is missing. - } - !(nextChild.parentID === id) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onBeforeMountComponent() parent and onSetChildren() to be consistent (%s has parents %s and %s).', nextChildID, nextChild.parentID, id) : _prodInvariant('142', nextChildID, nextChild.parentID, id) : void 0; - } - }, - onBeforeMountComponent: function (id, element, parentID) { - var item = { - element: element, - parentID: parentID, - text: null, - childIDs: [], - isMounted: false, - updateCount: 0 - }; - setItem(id, item); - }, - onBeforeUpdateComponent: function (id, element) { - var item = getItem(id); - if (!item || !item.isMounted) { - // We may end up here as a result of setState() in componentWillUnmount(). - // In this case, ignore the element. - return; - } - item.element = element; - }, - onMountComponent: function (id) { - var item = getItem(id); - !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; - item.isMounted = true; - var isRoot = item.parentID === 0; - if (isRoot) { - addRoot(id); - } - }, - onUpdateComponent: function (id) { - var item = getItem(id); - if (!item || !item.isMounted) { - // We may end up here as a result of setState() in componentWillUnmount(). - // In this case, ignore the element. - return; - } - item.updateCount++; - }, - onUnmountComponent: function (id) { - var item = getItem(id); - if (item) { - // We need to check if it exists. - // `item` might not exist if it is inside an error boundary, and a sibling - // error boundary child threw while mounting. Then this instance never - // got a chance to mount, but it still gets an unmounting event during - // the error boundary cleanup. - item.isMounted = false; - var isRoot = item.parentID === 0; - if (isRoot) { - removeRoot(id); - } - } - unmountedIDs.push(id); - }, - purgeUnmountedComponents: function () { - if (ReactComponentTreeHook._preventPurging) { - // Should only be used for testing. - return; - } +Buffer.prototype.readUInt16LE = function readUInt16LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + return this[offset] | (this[offset + 1] << 8) +} - for (var i = 0; i < unmountedIDs.length; i++) { - var id = unmountedIDs[i]; - purgeDeep(id); - } - unmountedIDs.length = 0; - }, - isMounted: function (id) { - var item = getItem(id); - return item ? item.isMounted : false; - }, - getCurrentStackAddendum: function (topElement) { - var info = ''; - if (topElement) { - var name = getDisplayName(topElement); - var owner = topElement._owner; - info += describeComponentFrame(name, topElement._source, owner && owner.getName()); - } +Buffer.prototype.readUInt16BE = function readUInt16BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + return (this[offset] << 8) | this[offset + 1] +} - var currentOwner = ReactCurrentOwner.current; - var id = currentOwner && currentOwner._debugID; +Buffer.prototype.readUInt32LE = function readUInt32LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) - info += ReactComponentTreeHook.getStackAddendumByID(id); - return info; - }, - getStackAddendumByID: function (id) { - var info = ''; - while (id) { - info += describeID(id); - id = ReactComponentTreeHook.getParentID(id); - } - return info; - }, - getChildIDs: function (id) { - var item = getItem(id); - return item ? item.childIDs : []; - }, - getDisplayName: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (!element) { - return null; - } - return getDisplayName(element); - }, - getElement: function (id) { - var item = getItem(id); - return item ? item.element : null; - }, - getOwnerID: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (!element || !element._owner) { - return null; - } - return element._owner._debugID; - }, - getParentID: function (id) { - var item = getItem(id); - return item ? item.parentID : null; - }, - getSource: function (id) { - var item = getItem(id); - var element = item ? item.element : null; - var source = element != null ? element._source : null; - return source; - }, - getText: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (typeof element === 'string') { - return element; - } else if (typeof element === 'number') { - return '' + element; - } else { - return null; - } - }, - getUpdateCount: function (id) { - var item = getItem(id); - return item ? item.updateCount : 0; - }, + return ((this[offset]) | + (this[offset + 1] << 8) | + (this[offset + 2] << 16)) + + (this[offset + 3] * 0x1000000) +} +Buffer.prototype.readUInt32BE = function readUInt32BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) - getRootIDs: getRootIDs, - getRegisteredIDs: getItemIDs, + return (this[offset] * 0x1000000) + + ((this[offset + 1] << 16) | + (this[offset + 2] << 8) | + this[offset + 3]) +} - pushNonStandardWarningStack: function (isCreatingElement, currentSource) { - if (typeof console.reactStack !== 'function') { - return; - } +Buffer.prototype.readIntLE = function readIntLE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) - var stack = []; - var currentOwner = ReactCurrentOwner.current; - var id = currentOwner && currentOwner._debugID; + var val = this[offset] + var mul = 1 + var i = 0 + while (++i < byteLength && (mul *= 0x100)) { + val += this[offset + i] * mul + } + mul *= 0x80 - try { - if (isCreatingElement) { - stack.push({ - name: id ? ReactComponentTreeHook.getDisplayName(id) : null, - fileName: currentSource ? currentSource.fileName : null, - lineNumber: currentSource ? currentSource.lineNumber : null - }); - } + if (val >= mul) val -= Math.pow(2, 8 * byteLength) - while (id) { - var element = ReactComponentTreeHook.getElement(id); - var parentID = ReactComponentTreeHook.getParentID(id); - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var ownerName = ownerID ? ReactComponentTreeHook.getDisplayName(ownerID) : null; - var source = element && element._source; - stack.push({ - name: ownerName, - fileName: source ? source.fileName : null, - lineNumber: source ? source.lineNumber : null - }); - id = parentID; - } - } catch (err) { - // Internal state is messed up. - // Stop building the stack (it's just a nice to have). - } + return val +} - console.reactStack(stack); - }, - popNonStandardWarningStack: function () { - if (typeof console.reactStackEnd !== 'function') { - return; - } - console.reactStackEnd(); +Buffer.prototype.readIntBE = function readIntBE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) + + var i = byteLength + var mul = 1 + var val = this[offset + --i] + while (i > 0 && (mul *= 0x100)) { + val += this[offset + --i] * mul } -}; + mul *= 0x80 -module.exports = ReactComponentTreeHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + if (val >= mul) val -= Math.pow(2, 8 * byteLength) -/***/ }), -/* 11 */, -/* 12 */ -/***/ (function(module, exports, __webpack_require__) { + return val +} -"use strict"; +Buffer.prototype.readInt8 = function readInt8 (offset, noAssert) { + if (!noAssert) checkOffset(offset, 1, this.length) + if (!(this[offset] & 0x80)) return (this[offset]) + return ((0xff - this[offset] + 1) * -1) +} +Buffer.prototype.readInt16LE = function readInt16LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + var val = this[offset] | (this[offset + 1] << 8) + return (val & 0x8000) ? val | 0xFFFF0000 : val +} -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Buffer.prototype.readInt16BE = function readInt16BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + var val = this[offset + 1] | (this[offset] << 8) + return (val & 0x8000) ? val | 0xFFFF0000 : val +} -function makeEmptyFunction(arg) { - return function () { - return arg; - }; +Buffer.prototype.readInt32LE = function readInt32LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + + return (this[offset]) | + (this[offset + 1] << 8) | + (this[offset + 2] << 16) | + (this[offset + 3] << 24) } -/** - * This function accepts and discards inputs; it has no side effects. This is - * primarily useful idiomatically for overridable function endpoints which - * always need to be callable, since JS lacks a null-call idiom ala Cocoa. - */ -var emptyFunction = function emptyFunction() {}; +Buffer.prototype.readInt32BE = function readInt32BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) -emptyFunction.thatReturns = makeEmptyFunction; -emptyFunction.thatReturnsFalse = makeEmptyFunction(false); -emptyFunction.thatReturnsTrue = makeEmptyFunction(true); -emptyFunction.thatReturnsNull = makeEmptyFunction(null); -emptyFunction.thatReturnsThis = function () { - return this; -}; -emptyFunction.thatReturnsArgument = function (arg) { - return arg; -}; + return (this[offset] << 24) | + (this[offset + 1] << 16) | + (this[offset + 2] << 8) | + (this[offset + 3]) +} -module.exports = emptyFunction; +Buffer.prototype.readFloatLE = function readFloatLE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + return ieee754.read(this, offset, true, 23, 4) +} -/***/ }), -/* 13 */ -/***/ (function(module, exports, __webpack_require__) { +Buffer.prototype.readFloatBE = function readFloatBE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + return ieee754.read(this, offset, false, 23, 4) +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Buffer.prototype.readDoubleLE = function readDoubleLE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 8, this.length) + return ieee754.read(this, offset, true, 52, 8) +} +Buffer.prototype.readDoubleBE = function readDoubleBE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 8, this.length) + return ieee754.read(this, offset, false, 52, 8) +} +function checkInt (buf, value, offset, ext, max, min) { + if (!Buffer.isBuffer(buf)) throw new TypeError('"buffer" argument must be a Buffer instance') + if (value > max || value < min) throw new RangeError('"value" argument is out of bounds') + if (offset + ext > buf.length) throw new RangeError('Index out of range') +} -// Trust the developer to only use ReactInstrumentation with a __DEV__ check +Buffer.prototype.writeUIntLE = function writeUIntLE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + var maxBytes = Math.pow(2, 8 * byteLength) - 1 + checkInt(this, value, offset, byteLength, maxBytes, 0) + } -var debugTool = null; + var mul = 1 + var i = 0 + this[offset] = value & 0xFF + while (++i < byteLength && (mul *= 0x100)) { + this[offset + i] = (value / mul) & 0xFF + } -if (process.env.NODE_ENV !== 'production') { - var ReactDebugTool = __webpack_require__(145); - debugTool = ReactDebugTool; + return offset + byteLength } -module.exports = { debugTool: debugTool }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 14 */ -/***/ (function(module, exports, __webpack_require__) { +Buffer.prototype.writeUIntBE = function writeUIntBE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + var maxBytes = Math.pow(2, 8 * byteLength) - 1 + checkInt(this, value, offset, byteLength, maxBytes, 0) + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var i = byteLength - 1 + var mul = 1 + this[offset + i] = value & 0xFF + while (--i >= 0 && (mul *= 0x100)) { + this[offset + i] = (value / mul) & 0xFF + } + return offset + byteLength +} +Buffer.prototype.writeUInt8 = function writeUInt8 (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0) + if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value) + this[offset] = (value & 0xff) + return offset + 1 +} -/** - * Keeps track of the current owner. - * - * The current owner is the component who should own any components that are - * currently being constructed. - */ -var ReactCurrentOwner = { - /** - * @internal - * @type {ReactComponent} - */ - current: null -}; +function objectWriteUInt16 (buf, value, offset, littleEndian) { + if (value < 0) value = 0xffff + value + 1 + for (var i = 0, j = Math.min(buf.length - offset, 2); i < j; ++i) { + buf[offset + i] = (value & (0xff << (8 * (littleEndian ? i : 1 - i)))) >>> + (littleEndian ? i : 1 - i) * 8 + } +} -module.exports = ReactCurrentOwner; +Buffer.prototype.writeUInt16LE = function writeUInt16LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + } else { + objectWriteUInt16(this, value, offset, true) + } + return offset + 2 +} -/***/ }), -/* 15 */ -/***/ (function(module, exports, __webpack_require__) { +Buffer.prototype.writeUInt16BE = function writeUInt16BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 8) + this[offset + 1] = (value & 0xff) + } else { + objectWriteUInt16(this, value, offset, false) + } + return offset + 2 +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function objectWriteUInt32 (buf, value, offset, littleEndian) { + if (value < 0) value = 0xffffffff + value + 1 + for (var i = 0, j = Math.min(buf.length - offset, 4); i < j; ++i) { + buf[offset + i] = (value >>> (littleEndian ? i : 3 - i) * 8) & 0xff + } +} +Buffer.prototype.writeUInt32LE = function writeUInt32LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset + 3] = (value >>> 24) + this[offset + 2] = (value >>> 16) + this[offset + 1] = (value >>> 8) + this[offset] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, true) + } + return offset + 4 +} +Buffer.prototype.writeUInt32BE = function writeUInt32BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 24) + this[offset + 1] = (value >>> 16) + this[offset + 2] = (value >>> 8) + this[offset + 3] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, false) + } + return offset + 4 +} -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +Buffer.prototype.writeIntLE = function writeIntLE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) { + var limit = Math.pow(2, 8 * byteLength - 1) -var CallbackQueue = __webpack_require__(85); -var PooledClass = __webpack_require__(20); -var ReactFeatureFlags = __webpack_require__(86); -var ReactReconciler = __webpack_require__(26); -var Transaction = __webpack_require__(41); + checkInt(this, value, offset, byteLength, limit - 1, -limit) + } -var invariant = __webpack_require__(1); + var i = 0 + var mul = 1 + var sub = 0 + this[offset] = value & 0xFF + while (++i < byteLength && (mul *= 0x100)) { + if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) { + sub = 1 + } + this[offset + i] = ((value / mul) >> 0) - sub & 0xFF + } -var dirtyComponents = []; -var updateBatchNumber = 0; -var asapCallbackQueue = CallbackQueue.getPooled(); -var asapEnqueued = false; + return offset + byteLength +} -var batchingStrategy = null; +Buffer.prototype.writeIntBE = function writeIntBE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) { + var limit = Math.pow(2, 8 * byteLength - 1) -function ensureInjected() { - !(ReactUpdates.ReactReconcileTransaction && batchingStrategy) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must inject a reconcile transaction class and batching strategy') : _prodInvariant('123') : void 0; -} + checkInt(this, value, offset, byteLength, limit - 1, -limit) + } -var NESTED_UPDATES = { - initialize: function () { - this.dirtyComponentsLength = dirtyComponents.length; - }, - close: function () { - if (this.dirtyComponentsLength !== dirtyComponents.length) { - // Additional updates were enqueued by componentDidUpdate handlers or - // similar; before our own UPDATE_QUEUEING wrapper closes, we want to run - // these new updates so that if A's componentDidUpdate calls setState on - // B, B will update before the callback A's updater provided when calling - // setState. - dirtyComponents.splice(0, this.dirtyComponentsLength); - flushBatchedUpdates(); - } else { - dirtyComponents.length = 0; + var i = byteLength - 1 + var mul = 1 + var sub = 0 + this[offset + i] = value & 0xFF + while (--i >= 0 && (mul *= 0x100)) { + if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) { + sub = 1 } + this[offset + i] = ((value / mul) >> 0) - sub & 0xFF } -}; -var UPDATE_QUEUEING = { - initialize: function () { - this.callbackQueue.reset(); - }, - close: function () { - this.callbackQueue.notifyAll(); + return offset + byteLength +} + +Buffer.prototype.writeInt8 = function writeInt8 (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80) + if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value) + if (value < 0) value = 0xff + value + 1 + this[offset] = (value & 0xff) + return offset + 1 +} + +Buffer.prototype.writeInt16LE = function writeInt16LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + } else { + objectWriteUInt16(this, value, offset, true) } -}; + return offset + 2 +} -var TRANSACTION_WRAPPERS = [NESTED_UPDATES, UPDATE_QUEUEING]; +Buffer.prototype.writeInt16BE = function writeInt16BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 8) + this[offset + 1] = (value & 0xff) + } else { + objectWriteUInt16(this, value, offset, false) + } + return offset + 2 +} -function ReactUpdatesFlushTransaction() { - this.reinitializeTransaction(); - this.dirtyComponentsLength = null; - this.callbackQueue = CallbackQueue.getPooled(); - this.reconcileTransaction = ReactUpdates.ReactReconcileTransaction.getPooled( - /* useCreateElement */true); +Buffer.prototype.writeInt32LE = function writeInt32LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + this[offset + 2] = (value >>> 16) + this[offset + 3] = (value >>> 24) + } else { + objectWriteUInt32(this, value, offset, true) + } + return offset + 4 } -_assign(ReactUpdatesFlushTransaction.prototype, Transaction, { - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, +Buffer.prototype.writeInt32BE = function writeInt32BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000) + if (value < 0) value = 0xffffffff + value + 1 + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 24) + this[offset + 1] = (value >>> 16) + this[offset + 2] = (value >>> 8) + this[offset + 3] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, false) + } + return offset + 4 +} - destructor: function () { - this.dirtyComponentsLength = null; - CallbackQueue.release(this.callbackQueue); - this.callbackQueue = null; - ReactUpdates.ReactReconcileTransaction.release(this.reconcileTransaction); - this.reconcileTransaction = null; - }, +function checkIEEE754 (buf, value, offset, ext, max, min) { + if (offset + ext > buf.length) throw new RangeError('Index out of range') + if (offset < 0) throw new RangeError('Index out of range') +} - perform: function (method, scope, a) { - // Essentially calls `this.reconcileTransaction.perform(method, scope, a)` - // with this transaction's wrappers around it. - return Transaction.perform.call(this, this.reconcileTransaction.perform, this.reconcileTransaction, method, scope, a); +function writeFloat (buf, value, offset, littleEndian, noAssert) { + if (!noAssert) { + checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38) } -}); + ieee754.write(buf, value, offset, littleEndian, 23, 4) + return offset + 4 +} -PooledClass.addPoolingTo(ReactUpdatesFlushTransaction); +Buffer.prototype.writeFloatLE = function writeFloatLE (value, offset, noAssert) { + return writeFloat(this, value, offset, true, noAssert) +} -function batchedUpdates(callback, a, b, c, d, e) { - ensureInjected(); - return batchingStrategy.batchedUpdates(callback, a, b, c, d, e); +Buffer.prototype.writeFloatBE = function writeFloatBE (value, offset, noAssert) { + return writeFloat(this, value, offset, false, noAssert) } -/** - * Array comparator for ReactComponents by mount ordering. - * - * @param {ReactComponent} c1 first component you're comparing - * @param {ReactComponent} c2 second component you're comparing - * @return {number} Return value usable by Array.prototype.sort(). - */ -function mountOrderComparator(c1, c2) { - return c1._mountOrder - c2._mountOrder; +function writeDouble (buf, value, offset, littleEndian, noAssert) { + if (!noAssert) { + checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308) + } + ieee754.write(buf, value, offset, littleEndian, 52, 8) + return offset + 8 } -function runBatchedUpdates(transaction) { - var len = transaction.dirtyComponentsLength; - !(len === dirtyComponents.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected flush transaction\'s stored dirty-components length (%s) to match dirty-components array length (%s).', len, dirtyComponents.length) : _prodInvariant('124', len, dirtyComponents.length) : void 0; +Buffer.prototype.writeDoubleLE = function writeDoubleLE (value, offset, noAssert) { + return writeDouble(this, value, offset, true, noAssert) +} - // Since reconciling a component higher in the owner hierarchy usually (not - // always -- see shouldComponentUpdate()) will reconcile children, reconcile - // them before their children by sorting the array. - dirtyComponents.sort(mountOrderComparator); +Buffer.prototype.writeDoubleBE = function writeDoubleBE (value, offset, noAssert) { + return writeDouble(this, value, offset, false, noAssert) +} - // Any updates enqueued while reconciling must be performed after this entire - // batch. Otherwise, if dirtyComponents is [A, B] where A has children B and - // C, B could update twice in a single batch if C's render enqueues an update - // to B (since B would have already updated, we should skip it, and the only - // way we can know to do so is by checking the batch counter). - updateBatchNumber++; +// copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length) +Buffer.prototype.copy = function copy (target, targetStart, start, end) { + if (!start) start = 0 + if (!end && end !== 0) end = this.length + if (targetStart >= target.length) targetStart = target.length + if (!targetStart) targetStart = 0 + if (end > 0 && end < start) end = start - for (var i = 0; i < len; i++) { - // If a component is unmounted before pending changes apply, it will still - // be here, but we assume that it has cleared its _pendingCallbacks and - // that performUpdateIfNecessary is a noop. - var component = dirtyComponents[i]; + // Copy 0 bytes; we're done + if (end === start) return 0 + if (target.length === 0 || this.length === 0) return 0 - // If performUpdateIfNecessary happens to enqueue any new updates, we - // shouldn't execute the callbacks until the next render happens, so - // stash the callbacks first - var callbacks = component._pendingCallbacks; - component._pendingCallbacks = null; + // Fatal error conditions + if (targetStart < 0) { + throw new RangeError('targetStart out of bounds') + } + if (start < 0 || start >= this.length) throw new RangeError('sourceStart out of bounds') + if (end < 0) throw new RangeError('sourceEnd out of bounds') - var markerName; - if (ReactFeatureFlags.logTopLevelRenders) { - var namedComponent = component; - // Duck type TopLevelWrapper. This is probably always true. - if (component._currentElement.type.isReactTopLevelWrapper) { - namedComponent = component._renderedComponent; - } - markerName = 'React update: ' + namedComponent.getName(); - console.time(markerName); - } + // Are we oob? + if (end > this.length) end = this.length + if (target.length - targetStart < end - start) { + end = target.length - targetStart + start + } - ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction, updateBatchNumber); + var len = end - start + var i - if (markerName) { - console.timeEnd(markerName); + if (this === target && start < targetStart && targetStart < end) { + // descending copy from end + for (i = len - 1; i >= 0; --i) { + target[i + targetStart] = this[i + start] } - - if (callbacks) { - for (var j = 0; j < callbacks.length; j++) { - transaction.callbackQueue.enqueue(callbacks[j], component.getPublicInstance()); - } + } else if (len < 1000 || !Buffer.TYPED_ARRAY_SUPPORT) { + // ascending copy from start + for (i = 0; i < len; ++i) { + target[i + targetStart] = this[i + start] } + } else { + Uint8Array.prototype.set.call( + target, + this.subarray(start, start + len), + targetStart + ) } + + return len } -var flushBatchedUpdates = function () { - // ReactUpdatesFlushTransaction's wrappers will clear the dirtyComponents - // array and perform any updates enqueued by mount-ready handlers (i.e., - // componentDidUpdate) but we need to check here too in order to catch - // updates enqueued by setState callbacks and asap calls. - while (dirtyComponents.length || asapEnqueued) { - if (dirtyComponents.length) { - var transaction = ReactUpdatesFlushTransaction.getPooled(); - transaction.perform(runBatchedUpdates, null, transaction); - ReactUpdatesFlushTransaction.release(transaction); +// Usage: +// buffer.fill(number[, offset[, end]]) +// buffer.fill(buffer[, offset[, end]]) +// buffer.fill(string[, offset[, end]][, encoding]) +Buffer.prototype.fill = function fill (val, start, end, encoding) { + // Handle string cases: + if (typeof val === 'string') { + if (typeof start === 'string') { + encoding = start + start = 0 + end = this.length + } else if (typeof end === 'string') { + encoding = end + end = this.length + } + if (val.length === 1) { + var code = val.charCodeAt(0) + if (code < 256) { + val = code + } + } + if (encoding !== undefined && typeof encoding !== 'string') { + throw new TypeError('encoding must be a string') + } + if (typeof encoding === 'string' && !Buffer.isEncoding(encoding)) { + throw new TypeError('Unknown encoding: ' + encoding) } + } else if (typeof val === 'number') { + val = val & 255 + } - if (asapEnqueued) { - asapEnqueued = false; - var queue = asapCallbackQueue; - asapCallbackQueue = CallbackQueue.getPooled(); - queue.notifyAll(); - CallbackQueue.release(queue); + // Invalid ranges are not set to a default, so can range check early. + if (start < 0 || this.length < start || this.length < end) { + throw new RangeError('Out of range index') + } + + if (end <= start) { + return this + } + + start = start >>> 0 + end = end === undefined ? this.length : end >>> 0 + + if (!val) val = 0 + + var i + if (typeof val === 'number') { + for (i = start; i < end; ++i) { + this[i] = val + } + } else { + var bytes = Buffer.isBuffer(val) + ? val + : utf8ToBytes(new Buffer(val, encoding).toString()) + var len = bytes.length + for (i = 0; i < end - start; ++i) { + this[i + start] = bytes[i % len] } } -}; -/** - * Mark a component as needing a rerender, adding an optional callback to a - * list of functions which will be executed once the rerender occurs. - */ -function enqueueUpdate(component) { - ensureInjected(); + return this +} - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. (This is called by each top-level update - // function, like setState, forceUpdate, etc.; creation and - // destruction of top-level components is guarded in ReactMount.) +// HELPER FUNCTIONS +// ================ - if (!batchingStrategy.isBatchingUpdates) { - batchingStrategy.batchedUpdates(enqueueUpdate, component); - return; +var INVALID_BASE64_RE = /[^+\/0-9A-Za-z-_]/g + +function base64clean (str) { + // Node strips out invalid characters like \n and \t from the string, base64-js does not + str = stringtrim(str).replace(INVALID_BASE64_RE, '') + // Node converts strings with length < 2 to '' + if (str.length < 2) return '' + // Node allows for non-padded base64 strings (missing trailing ===), base64-js does not + while (str.length % 4 !== 0) { + str = str + '=' } + return str +} - dirtyComponents.push(component); - if (component._updateBatchNumber == null) { - component._updateBatchNumber = updateBatchNumber + 1; +function stringtrim (str) { + if (str.trim) return str.trim() + return str.replace(/^\s+|\s+$/g, '') +} + +function toHex (n) { + if (n < 16) return '0' + n.toString(16) + return n.toString(16) +} + +function utf8ToBytes (string, units) { + units = units || Infinity + var codePoint + var length = string.length + var leadSurrogate = null + var bytes = [] + + for (var i = 0; i < length; ++i) { + codePoint = string.charCodeAt(i) + + // is surrogate component + if (codePoint > 0xD7FF && codePoint < 0xE000) { + // last char was a lead + if (!leadSurrogate) { + // no lead yet + if (codePoint > 0xDBFF) { + // unexpected trail + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + continue + } else if (i + 1 === length) { + // unpaired lead + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + continue + } + + // valid lead + leadSurrogate = codePoint + + continue + } + + // 2 leads in a row + if (codePoint < 0xDC00) { + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + leadSurrogate = codePoint + continue + } + + // valid surrogate pair + codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000 + } else if (leadSurrogate) { + // valid bmp char, but last char was a lead + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + } + + leadSurrogate = null + + // encode utf8 + if (codePoint < 0x80) { + if ((units -= 1) < 0) break + bytes.push(codePoint) + } else if (codePoint < 0x800) { + if ((units -= 2) < 0) break + bytes.push( + codePoint >> 0x6 | 0xC0, + codePoint & 0x3F | 0x80 + ) + } else if (codePoint < 0x10000) { + if ((units -= 3) < 0) break + bytes.push( + codePoint >> 0xC | 0xE0, + codePoint >> 0x6 & 0x3F | 0x80, + codePoint & 0x3F | 0x80 + ) + } else if (codePoint < 0x110000) { + if ((units -= 4) < 0) break + bytes.push( + codePoint >> 0x12 | 0xF0, + codePoint >> 0xC & 0x3F | 0x80, + codePoint >> 0x6 & 0x3F | 0x80, + codePoint & 0x3F | 0x80 + ) + } else { + throw new Error('Invalid code point') + } } + + return bytes } -/** - * Enqueue a callback to be run at the end of the current batching cycle. Throws - * if no updates are currently being performed. - */ -function asap(callback, context) { - !batchingStrategy.isBatchingUpdates ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates.asap: Can\'t enqueue an asap callback in a context whereupdates are not being batched.') : _prodInvariant('125') : void 0; - asapCallbackQueue.enqueue(callback, context); - asapEnqueued = true; +function asciiToBytes (str) { + var byteArray = [] + for (var i = 0; i < str.length; ++i) { + // Node's code seems to be doing this and not & 0x7F.. + byteArray.push(str.charCodeAt(i) & 0xFF) + } + return byteArray } -var ReactUpdatesInjection = { - injectReconcileTransaction: function (ReconcileTransaction) { - !ReconcileTransaction ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a reconcile transaction class') : _prodInvariant('126') : void 0; - ReactUpdates.ReactReconcileTransaction = ReconcileTransaction; - }, +function utf16leToBytes (str, units) { + var c, hi, lo + var byteArray = [] + for (var i = 0; i < str.length; ++i) { + if ((units -= 2) < 0) break - injectBatchingStrategy: function (_batchingStrategy) { - !_batchingStrategy ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batching strategy') : _prodInvariant('127') : void 0; - !(typeof _batchingStrategy.batchedUpdates === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batchedUpdates() function') : _prodInvariant('128') : void 0; - !(typeof _batchingStrategy.isBatchingUpdates === 'boolean') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide an isBatchingUpdates boolean attribute') : _prodInvariant('129') : void 0; - batchingStrategy = _batchingStrategy; + c = str.charCodeAt(i) + hi = c >> 8 + lo = c % 256 + byteArray.push(lo) + byteArray.push(hi) } -}; -var ReactUpdates = { - /** - * React references `ReactReconcileTransaction` using this property in order - * to allow dependency injection. - * - * @internal - */ - ReactReconcileTransaction: null, + return byteArray +} - batchedUpdates: batchedUpdates, - enqueueUpdate: enqueueUpdate, - flushBatchedUpdates: flushBatchedUpdates, - injection: ReactUpdatesInjection, - asap: asap -}; +function base64ToBytes (str) { + return base64.toByteArray(base64clean(str)) +} -module.exports = ReactUpdates; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function blitBuffer (src, dst, offset, length) { + for (var i = 0; i < length; ++i) { + if ((i + offset >= dst.length) || (i >= src.length)) break + dst[i + offset] = src[i] + } + return i +} + +function isnan (val) { + return val !== val // eslint-disable-line no-self-compare +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) /***/ }), -/* 16 */ +/* 2 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -1587,826 +2067,613 @@ module.exports = ReactUpdates; -var _assign = __webpack_require__(5); - -var PooledClass = __webpack_require__(20); - -var emptyFunction = __webpack_require__(12); -var warning = __webpack_require__(2); - -var didWarnForAddedNewProperty = false; -var isProxySupported = typeof Proxy === 'function'; - -var shouldBeReleasedProperties = ['dispatchConfig', '_targetInst', 'nativeEvent', 'isDefaultPrevented', 'isPropagationStopped', '_dispatchListeners', '_dispatchInstances']; - -/** - * @interface Event - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var EventInterface = { - type: null, - target: null, - // currentTarget is set when dispatching; no use in copying it here - currentTarget: emptyFunction.thatReturnsNull, - eventPhase: null, - bubbles: null, - cancelable: null, - timeStamp: function (event) { - return event.timeStamp || Date.now(); - }, - defaultPrevented: null, - isTrusted: null -}; - /** - * Synthetic events are dispatched by event plugins, typically in response to a - * top-level event delegation handler. - * - * These systems should generally use pooling to reduce the frequency of garbage - * collection. The system should check `isPersistent` to determine whether the - * event should be released into the pool after being dispatched. Users that - * need a persisted event should invoke `persist`. + * Use invariant() to assert state which your program assumes to be true. * - * Synthetic events (and subclasses) implement the DOM Level 3 Events API by - * normalizing browser quirks. Subclasses do not necessarily have to implement a - * DOM interface; custom application-specific events can also subclass this. + * Provide sprintf-style format (only %s is supported) and arguments + * to provide information about what broke and what you were + * expecting. * - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {*} targetInst Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @param {DOMEventTarget} nativeEventTarget Target node. + * The invariant message will be stripped in production, but the invariant + * will remain to ensure logic does not differ in production. */ -function SyntheticEvent(dispatchConfig, targetInst, nativeEvent, nativeEventTarget) { - if (process.env.NODE_ENV !== 'production') { - // these have a getter/setter for warnings - delete this.nativeEvent; - delete this.preventDefault; - delete this.stopPropagation; - } - this.dispatchConfig = dispatchConfig; - this._targetInst = targetInst; - this.nativeEvent = nativeEvent; +var validateFormat = function validateFormat(format) {}; - var Interface = this.constructor.Interface; - for (var propName in Interface) { - if (!Interface.hasOwnProperty(propName)) { - continue; - } - if (process.env.NODE_ENV !== 'production') { - delete this[propName]; // this has a getter/setter for warnings +if (process.env.NODE_ENV !== 'production') { + validateFormat = function validateFormat(format) { + if (format === undefined) { + throw new Error('invariant requires an error message argument'); } - var normalize = Interface[propName]; - if (normalize) { - this[propName] = normalize(nativeEvent); + }; +} + +function invariant(condition, format, a, b, c, d, e, f) { + validateFormat(format); + + if (!condition) { + var error; + if (format === undefined) { + error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); } else { - if (propName === 'target') { - this.target = nativeEventTarget; - } else { - this[propName] = nativeEvent[propName]; - } + var args = [a, b, c, d, e, f]; + var argIndex = 0; + error = new Error(format.replace(/%s/g, function () { + return args[argIndex++]; + })); + error.name = 'Invariant Violation'; } - } - var defaultPrevented = nativeEvent.defaultPrevented != null ? nativeEvent.defaultPrevented : nativeEvent.returnValue === false; - if (defaultPrevented) { - this.isDefaultPrevented = emptyFunction.thatReturnsTrue; - } else { - this.isDefaultPrevented = emptyFunction.thatReturnsFalse; + error.framesToPop = 1; // we don't care about invariant's own frame + throw error; } - this.isPropagationStopped = emptyFunction.thatReturnsFalse; - return this; } -_assign(SyntheticEvent.prototype, { - preventDefault: function () { - this.defaultPrevented = true; - var event = this.nativeEvent; - if (!event) { - return; - } - - if (event.preventDefault) { - event.preventDefault(); - // eslint-disable-next-line valid-typeof - } else if (typeof event.returnValue !== 'unknown') { - event.returnValue = false; - } - this.isDefaultPrevented = emptyFunction.thatReturnsTrue; - }, +module.exports = invariant; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - stopPropagation: function () { - var event = this.nativeEvent; - if (!event) { - return; - } +/***/ }), +/* 3 */ +/***/ (function(module, exports, __webpack_require__) { - if (event.stopPropagation) { - event.stopPropagation(); - // eslint-disable-next-line valid-typeof - } else if (typeof event.cancelBubble !== 'unknown') { - // The ChangeEventPlugin registers a "propertychange" event for - // IE. This event does not support bubbling or cancelling, and - // any references to cancelBubble throw "Member not found". A - // typeof check of "unknown" circumvents this issue (and is also - // IE specific). - event.cancelBubble = true; - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - this.isPropagationStopped = emptyFunction.thatReturnsTrue; - }, - /** - * We release all dispatched `SyntheticEvent`s after each event loop, adding - * them back into the pool. This allows a way to hold onto a reference that - * won't be added back into the pool. - */ - persist: function () { - this.isPersistent = emptyFunction.thatReturnsTrue; - }, - /** - * Checks if this event should be released back into the pool. - * - * @return {boolean} True if this should not be released, false otherwise. - */ - isPersistent: emptyFunction.thatReturnsFalse, +var emptyFunction = __webpack_require__(18); - /** - * `PooledClass` looks for `destructor` on each instance it releases. - */ - destructor: function () { - var Interface = this.constructor.Interface; - for (var propName in Interface) { - if (process.env.NODE_ENV !== 'production') { - Object.defineProperty(this, propName, getPooledWarningPropertyDefinition(propName, Interface[propName])); - } else { - this[propName] = null; - } - } - for (var i = 0; i < shouldBeReleasedProperties.length; i++) { - this[shouldBeReleasedProperties[i]] = null; - } - if (process.env.NODE_ENV !== 'production') { - Object.defineProperty(this, 'nativeEvent', getPooledWarningPropertyDefinition('nativeEvent', null)); - Object.defineProperty(this, 'preventDefault', getPooledWarningPropertyDefinition('preventDefault', emptyFunction)); - Object.defineProperty(this, 'stopPropagation', getPooledWarningPropertyDefinition('stopPropagation', emptyFunction)); - } - } -}); +/** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ -SyntheticEvent.Interface = EventInterface; +var warning = emptyFunction; if (process.env.NODE_ENV !== 'production') { - if (isProxySupported) { - /*eslint-disable no-func-assign */ - SyntheticEvent = new Proxy(SyntheticEvent, { - construct: function (target, args) { - return this.apply(target, Object.create(target.prototype), args); - }, - apply: function (constructor, that, args) { - return new Proxy(constructor.apply(that, args), { - set: function (target, prop, value) { - if (prop !== 'isPersistent' && !target.constructor.Interface.hasOwnProperty(prop) && shouldBeReleasedProperties.indexOf(prop) === -1) { - process.env.NODE_ENV !== 'production' ? warning(didWarnForAddedNewProperty || target.isPersistent(), "This synthetic event is reused for performance reasons. If you're " + "seeing this, you're adding a new property in the synthetic event object. " + 'The property is never released. See ' + 'https://fb.me/react-event-pooling for more information.') : void 0; - didWarnForAddedNewProperty = true; - } - target[prop] = value; - return true; - } - }); + (function () { + var printWarning = function printWarning(format) { + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; } - }); - /*eslint-enable no-func-assign */ - } -} -/** - * Helper to reduce boilerplate when creating subclasses. - * - * @param {function} Class - * @param {?object} Interface - */ -SyntheticEvent.augmentClass = function (Class, Interface) { - var Super = this; - var E = function () {}; - E.prototype = Super.prototype; - var prototype = new E(); - - _assign(prototype, Class.prototype); - Class.prototype = prototype; - Class.prototype.constructor = Class; - - Class.Interface = _assign({}, Super.Interface, Interface); - Class.augmentClass = Super.augmentClass; + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.error(message); + } + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} + }; - PooledClass.addPoolingTo(Class, PooledClass.fourArgumentPooler); -}; + warning = function warning(condition, format) { + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + } -PooledClass.addPoolingTo(SyntheticEvent, PooledClass.fourArgumentPooler); + if (format.indexOf('Failed Composite propType: ') === 0) { + return; // Ignore CompositeComponent proptype check. + } -module.exports = SyntheticEvent; + if (!condition) { + for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { + args[_key2 - 2] = arguments[_key2]; + } -/** - * Helper to nullify syntheticEvent instance properties when destructing - * - * @param {object} SyntheticEvent - * @param {String} propName - * @return {object} defineProperty object - */ -function getPooledWarningPropertyDefinition(propName, getVal) { - var isFunction = typeof getVal === 'function'; - return { - configurable: true, - set: set, - get: get - }; + printWarning.apply(undefined, [format].concat(args)); + } + }; + })(); +} - function set(val) { - var action = isFunction ? 'setting the method' : 'setting the property'; - warn(action, 'This is effectively a no-op'); - return val; - } +module.exports = warning; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - function get() { - var action = isFunction ? 'accessing the method' : 'accessing the property'; - var result = isFunction ? 'This is a no-op function' : 'This is set to null'; - warn(action, result); - return getVal; - } +/***/ }), +/* 4 */ +/***/ (function(module, exports) { - function warn(action, result) { - var warningCondition = false; - process.env.NODE_ENV !== 'production' ? warning(warningCondition, "This synthetic event is reused for performance reasons. If you're seeing this, " + "you're %s `%s` on a released/nullified synthetic event. %s. " + 'If you must keep the original synthetic event around, use event.persist(). ' + 'See https://fb.me/react-event-pooling for more information.', action, propName, result) : void 0; +if (typeof Object.create === 'function') { + // implementation from standard node.js 'util' module + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + ctor.prototype = Object.create(superCtor.prototype, { + constructor: { + value: ctor, + enumerable: false, + writable: true, + configurable: true + } + }); + }; +} else { + // old school shim for old browsers + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + var TempCtor = function () {} + TempCtor.prototype = superCtor.prototype + ctor.prototype = new TempCtor() + ctor.prototype.constructor = ctor } } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + /***/ }), -/* 17 */ +/* 5 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. +/** + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * + */ + + +/** + * WARNING: DO NOT manually require this module. + * This is a replacement for `invariant(...)` used by the error code system + * and will _only_ be required by the corresponding babel pass. + * It always throws. */ +function reactProdInvariant(code) { + var argCount = arguments.length - 1; + var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; -var _prodInvariant = __webpack_require__(3); + for (var argIdx = 0; argIdx < argCount; argIdx++) { + message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); + } -var invariant = __webpack_require__(1); + message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; -function checkMask(value, bitmask) { - return (value & bitmask) === bitmask; + var error = new Error(message); + error.name = 'Invariant Violation'; + error.framesToPop = 1; // we don't care about reactProdInvariant's own frame + + throw error; } -var DOMPropertyInjection = { - /** - * Mapping from normalized, camelcased property names to a configuration that - * specifies how the associated DOM property should be accessed or rendered. - */ - MUST_USE_PROPERTY: 0x1, - HAS_BOOLEAN_VALUE: 0x4, - HAS_NUMERIC_VALUE: 0x8, - HAS_POSITIVE_NUMERIC_VALUE: 0x10 | 0x8, - HAS_OVERLOADED_BOOLEAN_VALUE: 0x20, +module.exports = reactProdInvariant; - /** - * Inject some specialized knowledge about the DOM. This takes a config object - * with the following properties: - * - * isCustomAttribute: function that given an attribute name will return true - * if it can be inserted into the DOM verbatim. Useful for data-* or aria-* - * attributes where it's impossible to enumerate all of the possible - * attribute names, - * - * Properties: object mapping DOM property name to one of the - * DOMPropertyInjection constants or null. If your attribute isn't in here, - * it won't get written to the DOM. - * - * DOMAttributeNames: object mapping React attribute name to the DOM - * attribute name. Attribute names not specified use the **lowercase** - * normalized name. - * - * DOMAttributeNamespaces: object mapping React attribute name to the DOM - * attribute namespace URL. (Attribute names not specified use no namespace.) - * - * DOMPropertyNames: similar to DOMAttributeNames but for DOM properties. - * Property names not specified use the normalized name. - * - * DOMMutationMethods: Properties that require special mutation methods. If - * `value` is undefined, the mutation method should unset the property. - * - * @param {object} domPropertyConfig the config as described above. - */ - injectDOMPropertyConfig: function (domPropertyConfig) { - var Injection = DOMPropertyInjection; - var Properties = domPropertyConfig.Properties || {}; - var DOMAttributeNamespaces = domPropertyConfig.DOMAttributeNamespaces || {}; - var DOMAttributeNames = domPropertyConfig.DOMAttributeNames || {}; - var DOMPropertyNames = domPropertyConfig.DOMPropertyNames || {}; - var DOMMutationMethods = domPropertyConfig.DOMMutationMethods || {}; +/***/ }), +/* 6 */ +/***/ (function(module, exports, __webpack_require__) { - if (domPropertyConfig.isCustomAttribute) { - DOMProperty._isCustomAttributeFunctions.push(domPropertyConfig.isCustomAttribute); - } +"use strict"; - for (var propName in Properties) { - !!DOMProperty.properties.hasOwnProperty(propName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'injectDOMPropertyConfig(...): You\'re trying to inject DOM property \'%s\' which has already been injected. You may be accidentally injecting the same DOM property config twice, or you may be injecting two configs that have conflicting property names.', propName) : _prodInvariant('48', propName) : void 0; - var lowerCased = propName.toLowerCase(); - var propConfig = Properties[propName]; +module.exports = __webpack_require__(36); - var propertyInfo = { - attributeName: lowerCased, - attributeNamespace: null, - propertyName: propName, - mutationMethod: null, - mustUseProperty: checkMask(propConfig, Injection.MUST_USE_PROPERTY), - hasBooleanValue: checkMask(propConfig, Injection.HAS_BOOLEAN_VALUE), - hasNumericValue: checkMask(propConfig, Injection.HAS_NUMERIC_VALUE), - hasPositiveNumericValue: checkMask(propConfig, Injection.HAS_POSITIVE_NUMERIC_VALUE), - hasOverloadedBooleanValue: checkMask(propConfig, Injection.HAS_OVERLOADED_BOOLEAN_VALUE) - }; - !(propertyInfo.hasBooleanValue + propertyInfo.hasNumericValue + propertyInfo.hasOverloadedBooleanValue <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'DOMProperty: Value can be one of boolean, overloaded boolean, or numeric value, but not a combination: %s', propName) : _prodInvariant('50', propName) : void 0; +/***/ }), +/* 7 */ +/***/ (function(module, exports, __webpack_require__) { - if (process.env.NODE_ENV !== 'production') { - DOMProperty.getPossibleStandardName[lowerCased] = propName; - } +/* eslint-disable node/no-deprecated-api */ +var buffer = __webpack_require__(1) +var Buffer = buffer.Buffer - if (DOMAttributeNames.hasOwnProperty(propName)) { - var attributeName = DOMAttributeNames[propName]; - propertyInfo.attributeName = attributeName; - if (process.env.NODE_ENV !== 'production') { - DOMProperty.getPossibleStandardName[attributeName] = propName; - } - } +// alternative to using Object.keys for old browsers +function copyProps (src, dst) { + for (var key in src) { + dst[key] = src[key] + } +} +if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { + module.exports = buffer +} else { + // Copy properties from require('buffer') + copyProps(buffer, exports) + exports.Buffer = SafeBuffer +} - if (DOMAttributeNamespaces.hasOwnProperty(propName)) { - propertyInfo.attributeNamespace = DOMAttributeNamespaces[propName]; - } +function SafeBuffer (arg, encodingOrOffset, length) { + return Buffer(arg, encodingOrOffset, length) +} - if (DOMPropertyNames.hasOwnProperty(propName)) { - propertyInfo.propertyName = DOMPropertyNames[propName]; - } +// Copy static methods from Buffer +copyProps(Buffer, SafeBuffer) - if (DOMMutationMethods.hasOwnProperty(propName)) { - propertyInfo.mutationMethod = DOMMutationMethods[propName]; - } +SafeBuffer.from = function (arg, encodingOrOffset, length) { + if (typeof arg === 'number') { + throw new TypeError('Argument must not be a number') + } + return Buffer(arg, encodingOrOffset, length) +} - DOMProperty.properties[propName] = propertyInfo; +SafeBuffer.alloc = function (size, fill, encoding) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + var buf = Buffer(size) + if (fill !== undefined) { + if (typeof encoding === 'string') { + buf.fill(fill, encoding) + } else { + buf.fill(fill) } + } else { + buf.fill(0) } -}; + return buf +} -/* eslint-disable max-len */ -var ATTRIBUTE_NAME_START_CHAR = ':A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD'; -/* eslint-enable max-len */ +SafeBuffer.allocUnsafe = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return Buffer(size) +} -/** - * DOMProperty exports lookup objects that can be used like functions: - * - * > DOMProperty.isValid['id'] - * true - * > DOMProperty.isValid['foobar'] - * undefined - * - * Although this may be confusing, it performs better in general. - * - * @see http://jsperf.com/key-exists - * @see http://jsperf.com/key-missing - */ -var DOMProperty = { - ID_ATTRIBUTE_NAME: 'data-reactid', - ROOT_ATTRIBUTE_NAME: 'data-reactroot', +SafeBuffer.allocUnsafeSlow = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return buffer.SlowBuffer(size) +} - ATTRIBUTE_NAME_START_CHAR: ATTRIBUTE_NAME_START_CHAR, - ATTRIBUTE_NAME_CHAR: ATTRIBUTE_NAME_START_CHAR + '\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040', - /** - * Map from property "standard name" to an object with info about how to set - * the property in the DOM. Each object contains: - * - * attributeName: - * Used when rendering markup or with `*Attribute()`. - * attributeNamespace - * propertyName: - * Used on DOM node instances. (This includes properties that mutate due to - * external factors.) - * mutationMethod: - * If non-null, used instead of the property or `setAttribute()` after - * initial render. - * mustUseProperty: - * Whether the property must be accessed and mutated as an object property. - * hasBooleanValue: - * Whether the property should be removed when set to a falsey value. - * hasNumericValue: - * Whether the property must be numeric or parse as a numeric and should be - * removed when set to a falsey value. - * hasPositiveNumericValue: - * Whether the property must be positive numeric or parse as a positive - * numeric and should be removed when set to a falsey value. - * hasOverloadedBooleanValue: - * Whether the property can be used as a flag as well as with a value. - * Removed when strictly equal to false; present without a value when - * strictly equal to true; present with a value otherwise. - */ - properties: {}, +/***/ }), +/* 8 */ +/***/ (function(module, exports, __webpack_require__) { - /** - * Mapping from lowercase property names to the properly cased version, used - * to warn in the case of missing properties. Available only in __DEV__. - * - * autofocus is predefined, because adding it to the property whitelist - * causes unintended side effects. - * - * @type {Object} - */ - getPossibleStandardName: process.env.NODE_ENV !== 'production' ? { autofocus: 'autoFocus' } : null, +"use strict"; +/* +object-assign +(c) Sindre Sorhus +@license MIT +*/ - /** - * All of the isCustomAttribute() functions that have been injected. - */ - _isCustomAttributeFunctions: [], - /** - * Checks whether a property name is a custom attribute. - * @method - */ - isCustomAttribute: function (attributeName) { - for (var i = 0; i < DOMProperty._isCustomAttributeFunctions.length; i++) { - var isCustomAttributeFn = DOMProperty._isCustomAttributeFunctions[i]; - if (isCustomAttributeFn(attributeName)) { - return true; - } - } - return false; - }, +/* eslint-disable no-unused-vars */ +var getOwnPropertySymbols = Object.getOwnPropertySymbols; +var hasOwnProperty = Object.prototype.hasOwnProperty; +var propIsEnumerable = Object.prototype.propertyIsEnumerable; - injection: DOMPropertyInjection +function toObject(val) { + if (val === null || val === undefined) { + throw new TypeError('Object.assign cannot be called with null or undefined'); + } + + return Object(val); +} + +function shouldUseNative() { + try { + if (!Object.assign) { + return false; + } + + // Detect buggy property enumeration order in older V8 versions. + + // https://bugs.chromium.org/p/v8/issues/detail?id=4118 + var test1 = new String('abc'); // eslint-disable-line no-new-wrappers + test1[5] = 'de'; + if (Object.getOwnPropertyNames(test1)[0] === '5') { + return false; + } + + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test2 = {}; + for (var i = 0; i < 10; i++) { + test2['_' + String.fromCharCode(i)] = i; + } + var order2 = Object.getOwnPropertyNames(test2).map(function (n) { + return test2[n]; + }); + if (order2.join('') !== '0123456789') { + return false; + } + + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test3 = {}; + 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { + test3[letter] = letter; + }); + if (Object.keys(Object.assign({}, test3)).join('') !== + 'abcdefghijklmnopqrst') { + return false; + } + + return true; + } catch (err) { + // We don't expect any of the above to throw, but better to be safe. + return false; + } +} + +module.exports = shouldUseNative() ? Object.assign : function (target, source) { + var from; + var to = toObject(target); + var symbols; + + for (var s = 1; s < arguments.length; s++) { + from = Object(arguments[s]); + + for (var key in from) { + if (hasOwnProperty.call(from, key)) { + to[key] = from[key]; + } + } + + if (getOwnPropertySymbols) { + symbols = getOwnPropertySymbols(from); + for (var i = 0; i < symbols.length; i++) { + if (propIsEnumerable.call(from, symbols[i])) { + to[symbols[i]] = from[symbols[i]]; + } + } + } + } + + return to; }; -module.exports = DOMProperty; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 18 */, -/* 19 */ +/* 9 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var ERRORS = __webpack_require__(201) +var NATIVE = __webpack_require__(111) +// short-hand +var tfJSON = ERRORS.tfJSON +var TfTypeError = ERRORS.TfTypeError +var TfPropertyTypeError = ERRORS.TfPropertyTypeError +var tfSubError = ERRORS.tfSubError +var getValueTypeName = ERRORS.getValueTypeName +var TYPES = { + arrayOf: function arrayOf (type) { + type = compile(type) -var _assign = __webpack_require__(5); + function _arrayOf (array, strict) { + if (!NATIVE.Array(array)) return false -var ReactCurrentOwner = __webpack_require__(14); + return array.every(function (value, i) { + try { + return typeforce(type, value, strict) + } catch (e) { + throw tfSubError(e, i) + } + }) + } + _arrayOf.toJSON = function () { return '[' + tfJSON(type) + ']' } -var warning = __webpack_require__(2); -var canDefineProperty = __webpack_require__(38); -var hasOwnProperty = Object.prototype.hasOwnProperty; + return _arrayOf + }, -var REACT_ELEMENT_TYPE = __webpack_require__(76); + maybe: function maybe (type) { + type = compile(type) -var RESERVED_PROPS = { - key: true, - ref: true, - __self: true, - __source: true -}; + function _maybe (value, strict) { + return NATIVE.Nil(value) || type(value, strict, maybe) + } + _maybe.toJSON = function () { return '?' + tfJSON(type) } -var specialPropKeyWarningShown, specialPropRefWarningShown; + return _maybe + }, -function hasValidRef(config) { - if (process.env.NODE_ENV !== 'production') { - if (hasOwnProperty.call(config, 'ref')) { - var getter = Object.getOwnPropertyDescriptor(config, 'ref').get; - if (getter && getter.isReactWarning) { - return false; + map: function map (propertyType, propertyKeyType) { + propertyType = compile(propertyType) + if (propertyKeyType) propertyKeyType = compile(propertyKeyType) + + function _map (value, strict) { + if (!NATIVE.Object(value, strict)) return false + if (NATIVE.Nil(value, strict)) return false + + for (var propertyName in value) { + try { + if (propertyKeyType) { + typeforce(propertyKeyType, propertyName, strict) + } + } catch (e) { + throw tfSubError(e, propertyName, 'key') + } + + try { + var propertyValue = value[propertyName] + typeforce(propertyType, propertyValue, strict) + } catch (e) { + throw tfSubError(e, propertyName) + } } + + return true } - } - return config.ref !== undefined; -} -function hasValidKey(config) { - if (process.env.NODE_ENV !== 'production') { - if (hasOwnProperty.call(config, 'key')) { - var getter = Object.getOwnPropertyDescriptor(config, 'key').get; - if (getter && getter.isReactWarning) { - return false; + if (propertyKeyType) { + _map.toJSON = function () { + return '{' + tfJSON(propertyKeyType) + ': ' + tfJSON(propertyType) + '}' } + } else { + _map.toJSON = function () { return '{' + tfJSON(propertyType) + '}' } } - } - return config.key !== undefined; -} -function defineKeyPropWarningGetter(props, displayName) { - var warnAboutAccessingKey = function () { - if (!specialPropKeyWarningShown) { - specialPropKeyWarningShown = true; - process.env.NODE_ENV !== 'production' ? warning(false, '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; - } - }; - warnAboutAccessingKey.isReactWarning = true; - Object.defineProperty(props, 'key', { - get: warnAboutAccessingKey, - configurable: true - }); -} + return _map + }, -function defineRefPropWarningGetter(props, displayName) { - var warnAboutAccessingRef = function () { - if (!specialPropRefWarningShown) { - specialPropRefWarningShown = true; - process.env.NODE_ENV !== 'production' ? warning(false, '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + object: function object (uncompiled) { + var type = {} + + for (var typePropertyName in uncompiled) { + type[typePropertyName] = compile(uncompiled[typePropertyName]) } - }; - warnAboutAccessingRef.isReactWarning = true; - Object.defineProperty(props, 'ref', { - get: warnAboutAccessingRef, - configurable: true - }); -} -/** - * Factory method to create a new React element. This no longer adheres to - * the class pattern, so do not use new to call it. Also, no instanceof check - * will work. Instead test $$typeof field against Symbol.for('react.element') to check - * if something is a React Element. - * - * @param {*} type - * @param {*} key - * @param {string|object} ref - * @param {*} self A *temporary* helper to detect places where `this` is - * different from the `owner` when React.createElement is called, so that we - * can warn. We want to get rid of owner and replace string `ref`s with arrow - * functions, and as long as `this` and owner are the same, there will be no - * change in behavior. - * @param {*} source An annotation object (added by a transpiler or otherwise) - * indicating filename, line number, and/or other information. - * @param {*} owner - * @param {*} props - * @internal - */ -var ReactElement = function (type, key, ref, self, source, owner, props) { - var element = { - // This tag allow us to uniquely identify this as a React Element - $$typeof: REACT_ELEMENT_TYPE, + function _object (value, strict) { + if (!NATIVE.Object(value)) return false + if (NATIVE.Nil(value)) return false - // Built-in properties that belong on the element - type: type, - key: key, - ref: ref, - props: props, + var propertyName - // Record the component responsible for creating this element. - _owner: owner - }; + try { + for (propertyName in type) { + var propertyType = type[propertyName] + var propertyValue = value[propertyName] - if (process.env.NODE_ENV !== 'production') { - // The validation flag is currently mutative. We put it on - // an external backing store so that we can freeze the whole object. - // This can be replaced with a WeakMap once they are implemented in - // commonly used development environments. - element._store = {}; + typeforce(propertyType, propertyValue, strict) + } + } catch (e) { + throw tfSubError(e, propertyName) + } - // To make comparing ReactElements easier for testing purposes, we make - // the validation flag non-enumerable (where possible, which should - // include every environment we run tests in), so the test framework - // ignores it. - if (canDefineProperty) { - Object.defineProperty(element._store, 'validated', { - configurable: false, - enumerable: false, - writable: true, - value: false - }); - // self and source are DEV only properties. - Object.defineProperty(element, '_self', { - configurable: false, - enumerable: false, - writable: false, - value: self - }); - // Two elements created in two different places should be considered - // equal for testing purposes and therefore we hide it from enumeration. - Object.defineProperty(element, '_source', { - configurable: false, - enumerable: false, - writable: false, - value: source - }); - } else { - element._store.validated = false; - element._self = self; - element._source = source; - } - if (Object.freeze) { - Object.freeze(element.props); - Object.freeze(element); - } - } + if (strict) { + for (propertyName in value) { + if (type[propertyName]) continue - return element; -}; + throw new TfPropertyTypeError(undefined, propertyName) + } + } -/** - * Create and return a new ReactElement of the given type. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createelement - */ -ReactElement.createElement = function (type, config, children) { - var propName; + return true + } + _object.toJSON = function () { return tfJSON(type) } - // Reserved names are extracted - var props = {}; + return _object + }, - var key = null; - var ref = null; - var self = null; - var source = null; + oneOf: function oneOf () { + var types = [].slice.call(arguments).map(compile) - if (config != null) { - if (hasValidRef(config)) { - ref = config.ref; - } - if (hasValidKey(config)) { - key = '' + config.key; + function _oneOf (value, strict) { + return types.some(function (type) { + try { + return typeforce(type, value, strict) + } catch (e) { + return false + } + }) } + _oneOf.toJSON = function () { return types.map(tfJSON).join('|') } - self = config.__self === undefined ? null : config.__self; - source = config.__source === undefined ? null : config.__source; - // Remaining properties are added to a new props object - for (propName in config) { - if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { - props[propName] = config[propName]; - } - } - } + return _oneOf + }, - // Children can be more than one argument, and those are transferred onto - // the newly allocated props object. - var childrenLength = arguments.length - 2; - if (childrenLength === 1) { - props.children = children; - } else if (childrenLength > 1) { - var childArray = Array(childrenLength); - for (var i = 0; i < childrenLength; i++) { - childArray[i] = arguments[i + 2]; + quacksLike: function quacksLike (type) { + function _quacksLike (value) { + return type === getValueTypeName(value) } - if (process.env.NODE_ENV !== 'production') { - if (Object.freeze) { - Object.freeze(childArray); - } + _quacksLike.toJSON = function () { return type } + + return _quacksLike + }, + + tuple: function tuple () { + var types = [].slice.call(arguments).map(compile) + + function _tuple (values, strict) { + return types.every(function (type, i) { + try { + return typeforce(type, values[i], strict) + } catch (e) { + throw tfSubError(e, i) + } + }) && (!strict || values.length === arguments.length) } - props.children = childArray; - } + _tuple.toJSON = function () { return '(' + types.map(tfJSON).join(', ') + ')' } - // Resolve default props - if (type && type.defaultProps) { - var defaultProps = type.defaultProps; - for (propName in defaultProps) { - if (props[propName] === undefined) { - props[propName] = defaultProps[propName]; - } + return _tuple + }, + + value: function value (expected) { + function _value (actual) { + return actual === expected } + _value.toJSON = function () { return expected } + + return _value } - if (process.env.NODE_ENV !== 'production') { - if (key || ref) { - if (typeof props.$$typeof === 'undefined' || props.$$typeof !== REACT_ELEMENT_TYPE) { - var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type; - if (key) { - defineKeyPropWarningGetter(props, displayName); - } - if (ref) { - defineRefPropWarningGetter(props, displayName); - } - } - } +} + +function compile (type) { + if (NATIVE.String(type)) { + if (type[0] === '?') return TYPES.maybe(compile(type.slice(1))) + + return NATIVE[type] || TYPES.quacksLike(type) + } else if (type && NATIVE.Object(type)) { + if (NATIVE.Array(type)) return TYPES.arrayOf(compile(type[0])) + + return TYPES.object(type) + } else if (NATIVE.Function(type)) { + return type } - return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props); -}; -/** - * Return a function that produces ReactElements of a given type. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createfactory - */ -ReactElement.createFactory = function (type) { - var factory = ReactElement.createElement.bind(null, type); - // Expose the type on the factory and the prototype so that it can be - // easily accessed on elements. E.g. `.type === Foo`. - // This should not be named `constructor` since this may not be the function - // that created the element, and it may not even be a constructor. - // Legacy hook TODO: Warn if this is accessed - factory.type = type; - return factory; -}; + return TYPES.value(type) +} -ReactElement.cloneAndReplaceKey = function (oldElement, newKey) { - var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props); +function typeforce (type, value, strict, surrogate) { + if (NATIVE.Function(type)) { + if (type(value, strict)) return true - return newElement; -}; + throw new TfTypeError(surrogate || type, value) + } -/** - * Clone and return a new ReactElement using element as the starting point. - * See https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement - */ -ReactElement.cloneElement = function (element, config, children) { - var propName; + // JIT + return typeforce(compile(type), value, strict) +} - // Original props are copied - var props = _assign({}, element.props); +// assign types to typeforce function +for (var typeName in NATIVE) { + typeforce[typeName] = NATIVE[typeName] +} - // Reserved names are extracted - var key = element.key; - var ref = element.ref; - // Self is preserved since the owner is preserved. - var self = element._self; - // Source is preserved since cloneElement is unlikely to be targeted by a - // transpiler, and the original source is probably a better indicator of the - // true owner. - var source = element._source; +for (typeName in TYPES) { + typeforce[typeName] = TYPES[typeName] +} - // Owner will be preserved, unless ref is overridden - var owner = element._owner; +var EXTRA = __webpack_require__(467) +for (typeName in EXTRA) { + typeforce[typeName] = EXTRA[typeName] +} - if (config != null) { - if (hasValidRef(config)) { - // Silently steal the ref from the parent. - ref = config.ref; - owner = ReactCurrentOwner.current; - } - if (hasValidKey(config)) { - key = '' + config.key; - } +// async wrapper +function __async (type, value, strict, callback) { + // default to falsy strict if using shorthand overload + if (typeof strict === 'function') return __async(type, value, false, strict) - // Remaining properties override existing props - var defaultProps; - if (element.type && element.type.defaultProps) { - defaultProps = element.type.defaultProps; - } - for (propName in config) { - if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { - if (config[propName] === undefined && defaultProps !== undefined) { - // Resolve default props - props[propName] = defaultProps[propName]; - } else { - props[propName] = config[propName]; - } - } - } + try { + typeforce(type, value, strict) + } catch (e) { + return callback(e) } - // Children can be more than one argument, and those are transferred onto - // the newly allocated props object. - var childrenLength = arguments.length - 2; - if (childrenLength === 1) { - props.children = children; - } else if (childrenLength > 1) { - var childArray = Array(childrenLength); - for (var i = 0; i < childrenLength; i++) { - childArray[i] = arguments[i + 2]; - } - props.children = childArray; - } + callback() +} - return ReactElement(element.type, key, ref, self, source, owner, props); -}; +typeforce.async = __async +typeforce.compile = compile +typeforce.TfTypeError = TfTypeError +typeforce.TfPropertyTypeError = TfPropertyTypeError -/** - * Verifies the object is a ReactElement. - * See https://facebook.github.io/react/docs/top-level-api.html#react.isvalidelement - * @param {?object} object - * @return {boolean} True if `object` is a valid component. - * @final - */ -ReactElement.isValidElement = function (object) { - return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE; -}; +module.exports = typeforce -module.exports = ReactElement; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 20 */ +/* 10 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -2418,2483 +2685,3695 @@ module.exports = ReactElement; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -var _prodInvariant = __webpack_require__(3); +var _prodInvariant = __webpack_require__(5); + +var DOMProperty = __webpack_require__(28); +var ReactDOMComponentFlags = __webpack_require__(126); + +var invariant = __webpack_require__(2); + +var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; +var Flags = ReactDOMComponentFlags; -var invariant = __webpack_require__(1); +var internalInstanceKey = '__reactInternalInstance$' + Math.random().toString(36).slice(2); /** - * Static poolers. Several custom versions for each potential number of - * arguments. A completely generic pooler is easy to implement, but would - * require accessing the `arguments` object. In each of these, `this` refers to - * the Class itself, not an instance. If any others are needed, simply add them - * here, or in their own files. + * Check if a given node should be cached. */ -var oneArgumentPooler = function (copyFieldsFrom) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, copyFieldsFrom); - return instance; - } else { - return new Klass(copyFieldsFrom); +function shouldPrecacheNode(node, nodeID) { + return node.nodeType === 1 && node.getAttribute(ATTR_NAME) === String(nodeID) || node.nodeType === 8 && node.nodeValue === ' react-text: ' + nodeID + ' ' || node.nodeType === 8 && node.nodeValue === ' react-empty: ' + nodeID + ' '; +} + +/** + * Drill down (through composites and empty components) until we get a host or + * host text component. + * + * This is pretty polymorphic but unavoidable with the current structure we have + * for `_renderedChildren`. + */ +function getRenderedHostOrTextFromComponent(component) { + var rendered; + while (rendered = component._renderedComponent) { + component = rendered; } -}; + return component; +} -var twoArgumentPooler = function (a1, a2) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2); - return instance; - } else { - return new Klass(a1, a2); +/** + * Populate `_hostNode` on the rendered host/text component with the given + * DOM node. The passed `inst` can be a composite. + */ +function precacheNode(inst, node) { + var hostInst = getRenderedHostOrTextFromComponent(inst); + hostInst._hostNode = node; + node[internalInstanceKey] = hostInst; +} + +function uncacheNode(inst) { + var node = inst._hostNode; + if (node) { + delete node[internalInstanceKey]; + inst._hostNode = null; } -}; +} -var threeArgumentPooler = function (a1, a2, a3) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3); - return instance; - } else { - return new Klass(a1, a2, a3); +/** + * Populate `_hostNode` on each child of `inst`, assuming that the children + * match up with the DOM (element) children of `node`. + * + * We cache entire levels at once to avoid an n^2 problem where we access the + * children of a node sequentially and have to walk from the start to our target + * node every time. + * + * Since we update `_renderedChildren` and the actual DOM at (slightly) + * different times, we could race here and see a newer `_renderedChildren` than + * the DOM nodes we see. To avoid this, ReactMultiChild calls + * `prepareToManageChildren` before we change `_renderedChildren`, at which + * time the container's child nodes are always cached (until it unmounts). + */ +function precacheChildNodes(inst, node) { + if (inst._flags & Flags.hasCachedChildNodes) { + return; } -}; + var children = inst._renderedChildren; + var childNode = node.firstChild; + outer: for (var name in children) { + if (!children.hasOwnProperty(name)) { + continue; + } + var childInst = children[name]; + var childID = getRenderedHostOrTextFromComponent(childInst)._domID; + if (childID === 0) { + // We're currently unmounting this child in ReactMultiChild; skip it. + continue; + } + // We assume the child nodes are in the same order as the child instances. + for (; childNode !== null; childNode = childNode.nextSibling) { + if (shouldPrecacheNode(childNode, childID)) { + precacheNode(childInst, childNode); + continue outer; + } + } + // We reached the end of the DOM children without finding an ID match. + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unable to find element with ID %s.', childID) : _prodInvariant('32', childID) : void 0; + } + inst._flags |= Flags.hasCachedChildNodes; +} -var fourArgumentPooler = function (a1, a2, a3, a4) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3, a4); - return instance; - } else { - return new Klass(a1, a2, a3, a4); +/** + * Given a DOM node, return the closest ReactDOMComponent or + * ReactDOMTextComponent instance ancestor. + */ +function getClosestInstanceFromNode(node) { + if (node[internalInstanceKey]) { + return node[internalInstanceKey]; } -}; -var standardReleaser = function (instance) { - var Klass = this; - !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; - instance.destructor(); - if (Klass.instancePool.length < Klass.poolSize) { - Klass.instancePool.push(instance); + // Walk up the tree until we find an ancestor whose instance we have cached. + var parents = []; + while (!node[internalInstanceKey]) { + parents.push(node); + if (node.parentNode) { + node = node.parentNode; + } else { + // Top of the tree. This node must not be part of a React tree (or is + // unmounted, potentially). + return null; + } } -}; -var DEFAULT_POOL_SIZE = 10; -var DEFAULT_POOLER = oneArgumentPooler; + var closest; + var inst; + for (; node && (inst = node[internalInstanceKey]); node = parents.pop()) { + closest = inst; + if (parents.length) { + precacheChildNodes(inst, node); + } + } + + return closest; +} /** - * Augments `CopyConstructor` to be a poolable class, augmenting only the class - * itself (statically) not adding any prototypical fields. Any CopyConstructor - * you give this may have a `poolSize` property, and will look for a - * prototypical `destructor` on instances. - * - * @param {Function} CopyConstructor Constructor that can be used to reset. - * @param {Function} pooler Customizable pooler. + * Given a DOM node, return the ReactDOMComponent or ReactDOMTextComponent + * instance, or null if the node was not rendered by this React. */ -var addPoolingTo = function (CopyConstructor, pooler) { - // Casting as any so that flow ignores the actual implementation and trusts - // it to match the type we declared - var NewKlass = CopyConstructor; - NewKlass.instancePool = []; - NewKlass.getPooled = pooler || DEFAULT_POOLER; - if (!NewKlass.poolSize) { - NewKlass.poolSize = DEFAULT_POOL_SIZE; +function getInstanceFromNode(node) { + var inst = getClosestInstanceFromNode(node); + if (inst != null && inst._hostNode === node) { + return inst; + } else { + return null; } - NewKlass.release = standardReleaser; - return NewKlass; -}; +} -var PooledClass = { - addPoolingTo: addPoolingTo, - oneArgumentPooler: oneArgumentPooler, - twoArgumentPooler: twoArgumentPooler, - threeArgumentPooler: threeArgumentPooler, - fourArgumentPooler: fourArgumentPooler +/** + * Given a ReactDOMComponent or ReactDOMTextComponent, return the corresponding + * DOM node. + */ +function getNodeFromInstance(inst) { + // Without this first invariant, passing a non-DOM-component triggers the next + // invariant for a missing parent, which is super confusing. + !(inst._hostNode !== undefined) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; + + if (inst._hostNode) { + return inst._hostNode; + } + + // Walk up the tree until we find an ancestor whose DOM node we have cached. + var parents = []; + while (!inst._hostNode) { + parents.push(inst); + !inst._hostParent ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React DOM tree root should always have a node reference.') : _prodInvariant('34') : void 0; + inst = inst._hostParent; + } + + // Now parents contains each ancestor that does *not* have a cached native + // node, and `inst` is the deepest ancestor that does. + for (; parents.length; inst = parents.pop()) { + precacheChildNodes(inst, inst._hostNode); + } + + return inst._hostNode; +} + +var ReactDOMComponentTree = { + getClosestInstanceFromNode: getClosestInstanceFromNode, + getInstanceFromNode: getInstanceFromNode, + getNodeFromInstance: getNodeFromInstance, + precacheChildNodes: precacheChildNodes, + precacheNode: precacheNode, + uncacheNode: uncacheNode }; -module.exports = PooledClass; +module.exports = ReactDOMComponentTree; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 21 */, -/* 22 */, -/* 23 */, -/* 24 */ +/* 11 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(module) {(function (module, exports) { + 'use strict'; + // Utils + function assert (val, msg) { + if (!val) throw new Error(msg || 'Assertion failed'); + } + // Could use `inherits` module, but don't want to move from single file + // architecture yet. + function inherits (ctor, superCtor) { + ctor.super_ = superCtor; + var TempCtor = function () {}; + TempCtor.prototype = superCtor.prototype; + ctor.prototype = new TempCtor(); + ctor.prototype.constructor = ctor; + } -var _assign = __webpack_require__(5); + // BN -var ReactBaseClasses = __webpack_require__(74); -var ReactChildren = __webpack_require__(122); -var ReactDOMFactories = __webpack_require__(126); -var ReactElement = __webpack_require__(19); -var ReactPropTypes = __webpack_require__(130); -var ReactVersion = __webpack_require__(132); + function BN (number, base, endian) { + if (BN.isBN(number)) { + return number; + } -var createReactClass = __webpack_require__(133); -var onlyChild = __webpack_require__(134); + this.negative = 0; + this.words = null; + this.length = 0; -var createElement = ReactElement.createElement; -var createFactory = ReactElement.createFactory; -var cloneElement = ReactElement.cloneElement; + // Reduction context + this.red = null; -if (process.env.NODE_ENV !== 'production') { - var lowPriorityWarning = __webpack_require__(48); - var canDefineProperty = __webpack_require__(38); - var ReactElementValidator = __webpack_require__(78); - var didWarnPropTypesDeprecated = false; - createElement = ReactElementValidator.createElement; - createFactory = ReactElementValidator.createFactory; - cloneElement = ReactElementValidator.cloneElement; -} + if (number !== null) { + if (base === 'le' || base === 'be') { + endian = base; + base = 10; + } -var __spread = _assign; -var createMixin = function (mixin) { - return mixin; -}; + this._init(number || 0, base || 10, endian || 'be'); + } + } + if (typeof module === 'object') { + module.exports = BN; + } else { + exports.BN = BN; + } -if (process.env.NODE_ENV !== 'production') { - var warnedForSpread = false; - var warnedForCreateMixin = false; - __spread = function () { - lowPriorityWarning(warnedForSpread, 'React.__spread is deprecated and should not be used. Use ' + 'Object.assign directly or another helper function with similar ' + 'semantics. You may be seeing this warning due to your compiler. ' + 'See https://fb.me/react-spread-deprecation for more details.'); - warnedForSpread = true; - return _assign.apply(null, arguments); - }; + BN.BN = BN; + BN.wordSize = 26; - createMixin = function (mixin) { - lowPriorityWarning(warnedForCreateMixin, 'React.createMixin is deprecated and should not be used. ' + 'In React v16.0, it will be removed. ' + 'You can use this mixin directly instead. ' + 'See https://fb.me/createmixin-was-never-implemented for more info.'); - warnedForCreateMixin = true; - return mixin; - }; -} + var Buffer; + try { + // Obfuscate that we require Buffer, to reduce size + Buffer = __webpack_require__(1).Buffer; + } catch (e) { + } -var React = { - // Modern + BN.isBN = function isBN (num) { + if (num instanceof BN) { + return true; + } - Children: { - map: ReactChildren.map, - forEach: ReactChildren.forEach, - count: ReactChildren.count, - toArray: ReactChildren.toArray, - only: onlyChild - }, + return num !== null && typeof num === 'object' && + num.constructor.wordSize === BN.wordSize && Array.isArray(num.words); + }; - Component: ReactBaseClasses.Component, - PureComponent: ReactBaseClasses.PureComponent, + BN.max = function max (left, right) { + if (left.cmp(right) > 0) return left; + return right; + }; - createElement: createElement, - cloneElement: cloneElement, - isValidElement: ReactElement.isValidElement, + BN.min = function min (left, right) { + if (left.cmp(right) < 0) return left; + return right; + }; - // Classic + BN.prototype._init = function init (number, base, endian) { + if (typeof number === 'number') { + return this._initNumber(number, base, endian); + } - PropTypes: ReactPropTypes, - createClass: createReactClass, - createFactory: createFactory, - createMixin: createMixin, + if (typeof number === 'object') { + return this._initArray(number, base, endian); + } - // This looks DOM specific but these are actually isomorphic helpers - // since they are just generating DOM strings. - DOM: ReactDOMFactories, + if (base === 'hex') { + base = 16; + } + assert(base === (base | 0) && base >= 2 && base <= 36); - version: ReactVersion, + number = number.toString().replace(/\s+/g, ''); + var start = 0; + if (number[0] === '-') { + start++; + } - // Deprecated hook for JSX spread, don't use this for anything. - __spread: __spread -}; + if (base === 16) { + this._parseHex(number, start); + } else { + this._parseBase(number, base, start); + } -if (process.env.NODE_ENV !== 'production') { - var warnedForCreateClass = false; - if (canDefineProperty) { - Object.defineProperty(React, 'PropTypes', { - get: function () { - lowPriorityWarning(didWarnPropTypesDeprecated, 'Accessing PropTypes via the main React package is deprecated,' + ' and will be removed in React v16.0.' + ' Use the latest available v15.* prop-types package from npm instead.' + ' For info on usage, compatibility, migration and more, see ' + 'https://fb.me/prop-types-docs'); - didWarnPropTypesDeprecated = true; - return ReactPropTypes; - } - }); + if (number[0] === '-') { + this.negative = 1; + } - Object.defineProperty(React, 'createClass', { - get: function () { - lowPriorityWarning(warnedForCreateClass, 'Accessing createClass via the main React package is deprecated,' + ' and will be removed in React v16.0.' + " Use a plain JavaScript class instead. If you're not yet " + 'ready to migrate, create-react-class v15.* is available ' + 'on npm as a temporary, drop-in replacement. ' + 'For more info see https://fb.me/react-create-class'); - warnedForCreateClass = true; - return createReactClass; - } - }); - } + this.strip(); - // React.DOM factories are deprecated. Wrap these methods so that - // invocations of the React.DOM namespace and alert users to switch - // to the `react-dom-factories` package. - React.DOM = {}; - var warnedForFactories = false; - Object.keys(ReactDOMFactories).forEach(function (factory) { - React.DOM[factory] = function () { - if (!warnedForFactories) { - lowPriorityWarning(false, 'Accessing factories like React.DOM.%s has been deprecated ' + 'and will be removed in v16.0+. Use the ' + 'react-dom-factories package instead. ' + ' Version 1.0 provides a drop-in replacement.' + ' For more info, see https://fb.me/react-dom-factories', factory); - warnedForFactories = true; - } - return ReactDOMFactories[factory].apply(ReactDOMFactories, arguments); - }; - }); -} + if (endian !== 'le') return; -module.exports = React; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + this._initArray(this.toArray(), base, endian); + }; -/***/ }), -/* 25 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype._initNumber = function _initNumber (number, base, endian) { + if (number < 0) { + this.negative = 1; + number = -number; + } + if (number < 0x4000000) { + this.words = [ number & 0x3ffffff ]; + this.length = 1; + } else if (number < 0x10000000000000) { + this.words = [ + number & 0x3ffffff, + (number / 0x4000000) & 0x3ffffff + ]; + this.length = 2; + } else { + assert(number < 0x20000000000000); // 2 ^ 53 (unsafe) + this.words = [ + number & 0x3ffffff, + (number / 0x4000000) & 0x3ffffff, + 1 + ]; + this.length = 3; + } -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + if (endian !== 'le') return; + // Reverse the bytes + this._initArray(this.toArray(), base, endian); + }; -/** - * WARNING: DO NOT manually require this module. - * This is a replacement for `invariant(...)` used by the error code system - * and will _only_ be required by the corresponding babel pass. - * It always throws. - */ + BN.prototype._initArray = function _initArray (number, base, endian) { + // Perhaps a Uint8Array + assert(typeof number.length === 'number'); + if (number.length <= 0) { + this.words = [ 0 ]; + this.length = 1; + return this; + } + + this.length = Math.ceil(number.length / 3); + this.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + this.words[i] = 0; + } + + var j, w; + var off = 0; + if (endian === 'be') { + for (i = number.length - 1, j = 0; i >= 0; i -= 3) { + w = number[i] | (number[i - 1] << 8) | (number[i - 2] << 16); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] = (w >>> (26 - off)) & 0x3ffffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } + } + } else if (endian === 'le') { + for (i = 0, j = 0; i < number.length; i += 3) { + w = number[i] | (number[i + 1] << 8) | (number[i + 2] << 16); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] = (w >>> (26 - off)) & 0x3ffffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } + } + } + return this.strip(); + }; -function reactProdInvariant(code) { - var argCount = arguments.length - 1; + function parseHex (str, start, end) { + var r = 0; + var len = Math.min(str.length, end); + for (var i = start; i < len; i++) { + var c = str.charCodeAt(i) - 48; - var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; + r <<= 4; - for (var argIdx = 0; argIdx < argCount; argIdx++) { - message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); - } + // 'a' - 'f' + if (c >= 49 && c <= 54) { + r |= c - 49 + 0xa; - message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; + // 'A' - 'F' + } else if (c >= 17 && c <= 22) { + r |= c - 17 + 0xa; - var error = new Error(message); - error.name = 'Invariant Violation'; - error.framesToPop = 1; // we don't care about reactProdInvariant's own frame + // '0' - '9' + } else { + r |= c & 0xf; + } + } + return r; + } + + BN.prototype._parseHex = function _parseHex (number, start) { + // Create possibly bigger array to ensure that it fits the number + this.length = Math.ceil((number.length - start) / 6); + this.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + this.words[i] = 0; + } + + var j, w; + // Scan 24-bit chunks and add them to the number + var off = 0; + for (i = number.length - 6, j = 0; i >= start; i -= 6) { + w = parseHex(number, i, i + 6); + this.words[j] |= (w << off) & 0x3ffffff; + // NOTE: `0x3fffff` is intentional here, 26bits max shift + 24bit hex limb + this.words[j + 1] |= w >>> (26 - off) & 0x3fffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } + } + if (i + 6 !== start) { + w = parseHex(number, start, i + 6); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] |= w >>> (26 - off) & 0x3fffff; + } + this.strip(); + }; - throw error; -} + function parseBase (str, start, end, mul) { + var r = 0; + var len = Math.min(str.length, end); + for (var i = start; i < len; i++) { + var c = str.charCodeAt(i) - 48; -module.exports = reactProdInvariant; + r *= mul; -/***/ }), -/* 26 */ -/***/ (function(module, exports, __webpack_require__) { + // 'a' + if (c >= 49) { + r += c - 49 + 0xa; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // 'A' + } else if (c >= 17) { + r += c - 17 + 0xa; + // '0' - '9' + } else { + r += c; + } + } + return r; + } + BN.prototype._parseBase = function _parseBase (number, base, start) { + // Initialize as zero + this.words = [ 0 ]; + this.length = 1; -var ReactRef = __webpack_require__(143); -var ReactInstrumentation = __webpack_require__(13); + // Find length of limb in base + for (var limbLen = 0, limbPow = 1; limbPow <= 0x3ffffff; limbPow *= base) { + limbLen++; + } + limbLen--; + limbPow = (limbPow / base) | 0; -var warning = __webpack_require__(2); + var total = number.length - start; + var mod = total % limbLen; + var end = Math.min(total, total - mod) + start; -/** - * Helper to call ReactRef.attachRefs with this composite component, split out - * to avoid allocations in the transaction mount-ready queue. - */ -function attachRefs() { - ReactRef.attachRefs(this, this._currentElement); -} + var word = 0; + for (var i = start; i < end; i += limbLen) { + word = parseBase(number, i, i + limbLen, base); -var ReactReconciler = { - /** - * Initializes the component, renders markup, and registers event listeners. - * - * @param {ReactComponent} internalInstance - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?object} the containing host component instance - * @param {?object} info about the host container - * @return {?string} Rendered markup to be inserted into the DOM. - * @final - * @internal - */ - mountComponent: function (internalInstance, transaction, hostParent, hostContainerInfo, context, parentDebugID) // 0 in production and for roots - { - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeMountComponent(internalInstance._debugID, internalInstance._currentElement, parentDebugID); - } - } - var markup = internalInstance.mountComponent(transaction, hostParent, hostContainerInfo, context, parentDebugID); - if (internalInstance._currentElement && internalInstance._currentElement.ref != null) { - transaction.getReactMountReady().enqueue(attachRefs, internalInstance); - } - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onMountComponent(internalInstance._debugID); + this.imuln(limbPow); + if (this.words[0] + word < 0x4000000) { + this.words[0] += word; + } else { + this._iaddn(word); } } - return markup; - }, - /** - * Returns a value that can be passed to - * ReactComponentEnvironment.replaceNodeWithMarkup. - */ - getHostNode: function (internalInstance) { - return internalInstance.getHostNode(); - }, + if (mod !== 0) { + var pow = 1; + word = parseBase(number, i, number.length, base); - /** - * Releases any resources allocated by `mountComponent`. - * - * @final - * @internal - */ - unmountComponent: function (internalInstance, safely) { - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUnmountComponent(internalInstance._debugID); + for (i = 0; i < mod; i++) { + pow *= base; } - } - ReactRef.detachRefs(internalInstance, internalInstance._currentElement); - internalInstance.unmountComponent(safely); - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUnmountComponent(internalInstance._debugID); + + this.imuln(pow); + if (this.words[0] + word < 0x4000000) { + this.words[0] += word; + } else { + this._iaddn(word); } } - }, + }; - /** - * Update a component using a new element. - * - * @param {ReactComponent} internalInstance - * @param {ReactElement} nextElement - * @param {ReactReconcileTransaction} transaction - * @param {object} context - * @internal - */ - receiveComponent: function (internalInstance, nextElement, transaction, context) { - var prevElement = internalInstance._currentElement; + BN.prototype.copy = function copy (dest) { + dest.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + dest.words[i] = this.words[i]; + } + dest.length = this.length; + dest.negative = this.negative; + dest.red = this.red; + }; - if (nextElement === prevElement && context === internalInstance._context) { - // Since elements are immutable after the owner is rendered, - // we can do a cheap identity compare here to determine if this is a - // superfluous reconcile. It's possible for state to be mutable but such - // change should trigger an update of the owner which would recreate - // the element. We explicitly check for the existence of an owner since - // it's possible for an element created outside a composite to be - // deeply mutated and reused. + BN.prototype.clone = function clone () { + var r = new BN(null); + this.copy(r); + return r; + }; - // TODO: Bailing out early is just a perf optimization right? - // TODO: Removing the return statement should affect correctness? - return; + BN.prototype._expand = function _expand (size) { + while (this.length < size) { + this.words[this.length++] = 0; } + return this; + }; - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, nextElement); - } + // Remove leading `0` from `this` + BN.prototype.strip = function strip () { + while (this.length > 1 && this.words[this.length - 1] === 0) { + this.length--; } + return this._normSign(); + }; - var refsChanged = ReactRef.shouldUpdateRefs(prevElement, nextElement); - - if (refsChanged) { - ReactRef.detachRefs(internalInstance, prevElement); + BN.prototype._normSign = function _normSign () { + // -0 = 0 + if (this.length === 1 && this.words[0] === 0) { + this.negative = 0; } + return this; + }; - internalInstance.receiveComponent(nextElement, transaction, context); + BN.prototype.inspect = function inspect () { + return (this.red ? ''; + }; - if (refsChanged && internalInstance._currentElement && internalInstance._currentElement.ref != null) { - transaction.getReactMountReady().enqueue(attachRefs, internalInstance); - } + /* - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); - } - } - }, + var zeros = []; + var groupSizes = []; + var groupBases = []; - /** - * Flush any dirty changes in a component. - * - * @param {ReactComponent} internalInstance - * @param {ReactReconcileTransaction} transaction - * @internal - */ - performUpdateIfNecessary: function (internalInstance, transaction, updateBatchNumber) { - if (internalInstance._updateBatchNumber !== updateBatchNumber) { - // The component's enqueued batch number should always be the current - // batch or the following one. - process.env.NODE_ENV !== 'production' ? warning(internalInstance._updateBatchNumber == null || internalInstance._updateBatchNumber === updateBatchNumber + 1, 'performUpdateIfNecessary: Unexpected batch number (current %s, ' + 'pending %s)', updateBatchNumber, internalInstance._updateBatchNumber) : void 0; - return; + var s = ''; + var i = -1; + while (++i < BN.wordSize) { + zeros[i] = s; + s += '0'; + } + groupSizes[0] = 0; + groupSizes[1] = 0; + groupBases[0] = 0; + groupBases[1] = 0; + var base = 2 - 1; + while (++base < 36 + 1) { + var groupSize = 0; + var groupBase = 1; + while (groupBase < (1 << BN.wordSize) / base) { + groupBase *= base; + groupSize += 1; } - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, internalInstance._currentElement); + groupSizes[base] = groupSize; + groupBases[base] = groupBase; + } + + */ + + var zeros = [ + '', + '0', + '00', + '000', + '0000', + '00000', + '000000', + '0000000', + '00000000', + '000000000', + '0000000000', + '00000000000', + '000000000000', + '0000000000000', + '00000000000000', + '000000000000000', + '0000000000000000', + '00000000000000000', + '000000000000000000', + '0000000000000000000', + '00000000000000000000', + '000000000000000000000', + '0000000000000000000000', + '00000000000000000000000', + '000000000000000000000000', + '0000000000000000000000000' + ]; + + var groupSizes = [ + 0, 0, + 25, 16, 12, 11, 10, 9, 8, + 8, 7, 7, 7, 7, 6, 6, + 6, 6, 6, 6, 6, 5, 5, + 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5 + ]; + + var groupBases = [ + 0, 0, + 33554432, 43046721, 16777216, 48828125, 60466176, 40353607, 16777216, + 43046721, 10000000, 19487171, 35831808, 62748517, 7529536, 11390625, + 16777216, 24137569, 34012224, 47045881, 64000000, 4084101, 5153632, + 6436343, 7962624, 9765625, 11881376, 14348907, 17210368, 20511149, + 24300000, 28629151, 33554432, 39135393, 45435424, 52521875, 60466176 + ]; + + BN.prototype.toString = function toString (base, padding) { + base = base || 10; + padding = padding | 0 || 1; + + var out; + if (base === 16 || base === 'hex') { + out = ''; + var off = 0; + var carry = 0; + for (var i = 0; i < this.length; i++) { + var w = this.words[i]; + var word = (((w << off) | carry) & 0xffffff).toString(16); + carry = (w >>> (24 - off)) & 0xffffff; + if (carry !== 0 || i !== this.length - 1) { + out = zeros[6 - word.length] + word + out; + } else { + out = word + out; + } + off += 2; + if (off >= 26) { + off -= 26; + i--; + } } - } - internalInstance.performUpdateIfNecessary(transaction); - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); + if (carry !== 0) { + out = carry.toString(16) + out; + } + while (out.length % padding !== 0) { + out = '0' + out; + } + if (this.negative !== 0) { + out = '-' + out; } + return out; + } + + if (base === (base | 0) && base >= 2 && base <= 36) { + // var groupSize = Math.floor(BN.wordSize * Math.LN2 / Math.log(base)); + var groupSize = groupSizes[base]; + // var groupBase = Math.pow(base, groupSize); + var groupBase = groupBases[base]; + out = ''; + var c = this.clone(); + c.negative = 0; + while (!c.isZero()) { + var r = c.modn(groupBase).toString(base); + c = c.idivn(groupBase); + + if (!c.isZero()) { + out = zeros[groupSize - r.length] + r + out; + } else { + out = r + out; + } + } + if (this.isZero()) { + out = '0' + out; + } + while (out.length % padding !== 0) { + out = '0' + out; + } + if (this.negative !== 0) { + out = '-' + out; + } + return out; } - } -}; -module.exports = ReactReconciler; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + assert(false, 'Base should be between 2 and 36'); + }; -/***/ }), -/* 27 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.toNumber = function toNumber () { + var ret = this.words[0]; + if (this.length === 2) { + ret += this.words[1] * 0x4000000; + } else if (this.length === 3 && this.words[2] === 0x01) { + // NOTE: at this stage it is known that the top bit is set + ret += 0x10000000000000 + (this.words[1] * 0x4000000); + } else if (this.length > 2) { + assert(false, 'Number can only safely store up to 53 bits'); + } + return (this.negative !== 0) ? -ret : ret; + }; -"use strict"; -/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.toJSON = function toJSON () { + return this.toString(16); + }; + BN.prototype.toBuffer = function toBuffer (endian, length) { + assert(typeof Buffer !== 'undefined'); + return this.toArrayLike(Buffer, endian, length); + }; + BN.prototype.toArray = function toArray (endian, length) { + return this.toArrayLike(Array, endian, length); + }; -var DOMNamespaces = __webpack_require__(56); -var setInnerHTML = __webpack_require__(43); + BN.prototype.toArrayLike = function toArrayLike (ArrayType, endian, length) { + var byteLength = this.byteLength(); + var reqLength = length || Math.max(1, byteLength); + assert(byteLength <= reqLength, 'byte array longer than desired length'); + assert(reqLength > 0, 'Requested array length <= 0'); + + this.strip(); + var littleEndian = endian === 'le'; + var res = new ArrayType(reqLength); + + var b, i; + var q = this.clone(); + if (!littleEndian) { + // Assume big-endian + for (i = 0; i < reqLength - byteLength; i++) { + res[i] = 0; + } -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); -var setTextContent = __webpack_require__(90); + for (i = 0; !q.isZero(); i++) { + b = q.andln(0xff); + q.iushrn(8); -var ELEMENT_NODE_TYPE = 1; -var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + res[reqLength - i - 1] = b; + } + } else { + for (i = 0; !q.isZero(); i++) { + b = q.andln(0xff); + q.iushrn(8); -/** - * In IE (8-11) and Edge, appending nodes with no children is dramatically - * faster than appending a full subtree, so we essentially queue up the - * .appendChild calls here and apply them so each node is added to its parent - * before any children are added. - * - * In other browsers, doing so is slower or neutral compared to the other order - * (in Firefox, twice as slow) so we only do this inversion in IE. - * - * See https://github.com/spicyj/innerhtml-vs-createelement-vs-clonenode. - */ -var enableLazy = typeof document !== 'undefined' && typeof document.documentMode === 'number' || typeof navigator !== 'undefined' && typeof navigator.userAgent === 'string' && /\bEdge\/\d/.test(navigator.userAgent); + res[i] = b; + } -function insertTreeChildren(tree) { - if (!enableLazy) { - return; - } - var node = tree.node; - var children = tree.children; - if (children.length) { - for (var i = 0; i < children.length; i++) { - insertTreeBefore(node, children[i], null); + for (; i < reqLength; i++) { + res[i] = 0; + } } - } else if (tree.html != null) { - setInnerHTML(node, tree.html); - } else if (tree.text != null) { - setTextContent(node, tree.text); - } -} -var insertTreeBefore = createMicrosoftUnsafeLocalFunction(function (parentNode, tree, referenceNode) { - // DocumentFragments aren't actually part of the DOM after insertion so - // appending children won't update the DOM. We need to ensure the fragment - // is properly populated first, breaking out of our lazy approach for just - // this level. Also, some plugins (like Flash Player) will read - // nodes immediately upon insertion into the DOM, so - // must also be populated prior to insertion into the DOM. - if (tree.node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE || tree.node.nodeType === ELEMENT_NODE_TYPE && tree.node.nodeName.toLowerCase() === 'object' && (tree.node.namespaceURI == null || tree.node.namespaceURI === DOMNamespaces.html)) { - insertTreeChildren(tree); - parentNode.insertBefore(tree.node, referenceNode); + return res; + }; + + if (Math.clz32) { + BN.prototype._countBits = function _countBits (w) { + return 32 - Math.clz32(w); + }; } else { - parentNode.insertBefore(tree.node, referenceNode); - insertTreeChildren(tree); + BN.prototype._countBits = function _countBits (w) { + var t = w; + var r = 0; + if (t >= 0x1000) { + r += 13; + t >>>= 13; + } + if (t >= 0x40) { + r += 7; + t >>>= 7; + } + if (t >= 0x8) { + r += 4; + t >>>= 4; + } + if (t >= 0x02) { + r += 2; + t >>>= 2; + } + return r + t; + }; } -}); -function replaceChildWithTree(oldNode, newTree) { - oldNode.parentNode.replaceChild(newTree.node, oldNode); - insertTreeChildren(newTree); -} + BN.prototype._zeroBits = function _zeroBits (w) { + // Short-cut + if (w === 0) return 26; -function queueChild(parentTree, childTree) { - if (enableLazy) { - parentTree.children.push(childTree); - } else { - parentTree.node.appendChild(childTree.node); - } -} + var t = w; + var r = 0; + if ((t & 0x1fff) === 0) { + r += 13; + t >>>= 13; + } + if ((t & 0x7f) === 0) { + r += 7; + t >>>= 7; + } + if ((t & 0xf) === 0) { + r += 4; + t >>>= 4; + } + if ((t & 0x3) === 0) { + r += 2; + t >>>= 2; + } + if ((t & 0x1) === 0) { + r++; + } + return r; + }; -function queueHTML(tree, html) { - if (enableLazy) { - tree.html = html; - } else { - setInnerHTML(tree.node, html); - } -} + // Return number of used bits in a BN + BN.prototype.bitLength = function bitLength () { + var w = this.words[this.length - 1]; + var hi = this._countBits(w); + return (this.length - 1) * 26 + hi; + }; -function queueText(tree, text) { - if (enableLazy) { - tree.text = text; - } else { - setTextContent(tree.node, text); + function toBitArray (num) { + var w = new Array(num.bitLength()); + + for (var bit = 0; bit < w.length; bit++) { + var off = (bit / 26) | 0; + var wbit = bit % 26; + + w[bit] = (num.words[off] & (1 << wbit)) >>> wbit; + } + + return w; } -} -function toString() { - return this.node.nodeName; -} + // Number of trailing zero bits + BN.prototype.zeroBits = function zeroBits () { + if (this.isZero()) return 0; -function DOMLazyTree(node) { - return { - node: node, - children: [], - html: null, - text: null, - toString: toString + var r = 0; + for (var i = 0; i < this.length; i++) { + var b = this._zeroBits(this.words[i]); + r += b; + if (b !== 26) break; + } + return r; }; -} -DOMLazyTree.insertTreeBefore = insertTreeBefore; -DOMLazyTree.replaceChildWithTree = replaceChildWithTree; -DOMLazyTree.queueChild = queueChild; -DOMLazyTree.queueHTML = queueHTML; -DOMLazyTree.queueText = queueText; + BN.prototype.byteLength = function byteLength () { + return Math.ceil(this.bitLength() / 8); + }; -module.exports = DOMLazyTree; + BN.prototype.toTwos = function toTwos (width) { + if (this.negative !== 0) { + return this.abs().inotn(width).iaddn(1); + } + return this.clone(); + }; -/***/ }), -/* 28 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.fromTwos = function fromTwos (width) { + if (this.testn(width - 1)) { + return this.notn(width).iaddn(1).ineg(); + } + return this.clone(); + }; -"use strict"; + BN.prototype.isNeg = function isNeg () { + return this.negative !== 0; + }; + // Return negative clone of `this` + BN.prototype.neg = function neg () { + return this.clone().ineg(); + }; -module.exports = __webpack_require__(135); + BN.prototype.ineg = function ineg () { + if (!this.isZero()) { + this.negative ^= 1; + } + return this; + }; -/***/ }), -/* 29 */ -/***/ (function(module, exports, __webpack_require__) { + // Or `num` with `this` in-place + BN.prototype.iuor = function iuor (num) { + while (this.length < num.length) { + this.words[this.length++] = 0; + } -var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! - Copyright (c) 2016 Jed Watson. - Licensed under the MIT License (MIT), see - http://jedwatson.github.io/classnames -*/ -/* global define */ + for (var i = 0; i < num.length; i++) { + this.words[i] = this.words[i] | num.words[i]; + } -(function () { - 'use strict'; + return this.strip(); + }; - var hasOwn = {}.hasOwnProperty; + BN.prototype.ior = function ior (num) { + assert((this.negative | num.negative) === 0); + return this.iuor(num); + }; - function classNames () { - var classes = []; + // Or `num` with `this` + BN.prototype.or = function or (num) { + if (this.length > num.length) return this.clone().ior(num); + return num.clone().ior(this); + }; - for (var i = 0; i < arguments.length; i++) { - var arg = arguments[i]; - if (!arg) continue; + BN.prototype.uor = function uor (num) { + if (this.length > num.length) return this.clone().iuor(num); + return num.clone().iuor(this); + }; - var argType = typeof arg; + // And `num` with `this` in-place + BN.prototype.iuand = function iuand (num) { + // b = min-length(num, this) + var b; + if (this.length > num.length) { + b = num; + } else { + b = this; + } - if (argType === 'string' || argType === 'number') { - classes.push(arg); - } else if (Array.isArray(arg)) { - classes.push(classNames.apply(null, arg)); - } else if (argType === 'object') { - for (var key in arg) { - if (hasOwn.call(arg, key) && arg[key]) { - classes.push(key); - } - } - } - } + for (var i = 0; i < b.length; i++) { + this.words[i] = this.words[i] & num.words[i]; + } - return classes.join(' '); - } + this.length = b.length; - if (typeof module !== 'undefined' && module.exports) { - module.exports = classNames; - } else if (true) { - // register as 'classnames', consistent with npm package name - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function () { - return classNames; - }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else { - window.classNames = classNames; - } -}()); + return this.strip(); + }; + BN.prototype.iand = function iand (num) { + assert((this.negative | num.negative) === 0); + return this.iuand(num); + }; -/***/ }), -/* 30 */, -/* 31 */ -/***/ (function(module, exports, __webpack_require__) { + // And `num` with `this` + BN.prototype.and = function and (num) { + if (this.length > num.length) return this.clone().iand(num); + return num.clone().iand(this); + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.uand = function uand (num) { + if (this.length > num.length) return this.clone().iuand(num); + return num.clone().iuand(this); + }; + // Xor `num` with `this` in-place + BN.prototype.iuxor = function iuxor (num) { + // a.length > b.length + var a; + var b; + if (this.length > num.length) { + a = this; + b = num; + } else { + a = num; + b = this; + } + for (var i = 0; i < b.length; i++) { + this.words[i] = a.words[i] ^ b.words[i]; + } -var EventPluginHub = __webpack_require__(32); -var EventPluginUtils = __webpack_require__(50); + if (this !== a) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; + } + } -var accumulateInto = __webpack_require__(82); -var forEachAccumulated = __webpack_require__(83); -var warning = __webpack_require__(2); + this.length = a.length; -var getListener = EventPluginHub.getListener; + return this.strip(); + }; -/** - * Some event types have a notion of different registration names for different - * "phases" of propagation. This finds listeners by a given phase. - */ -function listenerAtPhase(inst, event, propagationPhase) { - var registrationName = event.dispatchConfig.phasedRegistrationNames[propagationPhase]; - return getListener(inst, registrationName); -} + BN.prototype.ixor = function ixor (num) { + assert((this.negative | num.negative) === 0); + return this.iuxor(num); + }; -/** - * Tags a `SyntheticEvent` with dispatched listeners. Creating this function - * here, allows us to not have to bind or create functions for each event. - * Mutating the event's members allows us to not have to create a wrapping - * "dispatch" object that pairs the event with the listener. - */ -function accumulateDirectionalDispatches(inst, phase, event) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(inst, 'Dispatching inst must not be null') : void 0; - } - var listener = listenerAtPhase(inst, event, phase); - if (listener) { - event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); - event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); - } -} + // Xor `num` with `this` + BN.prototype.xor = function xor (num) { + if (this.length > num.length) return this.clone().ixor(num); + return num.clone().ixor(this); + }; -/** - * Collect dispatches (must be entirely collected before dispatching - see unit - * tests). Lazily allocate the array to conserve memory. We must loop through - * each event and perform the traversal for each one. We cannot perform a - * single traversal for the entire collection of events because each event may - * have a different target. - */ -function accumulateTwoPhaseDispatchesSingle(event) { - if (event && event.dispatchConfig.phasedRegistrationNames) { - EventPluginUtils.traverseTwoPhase(event._targetInst, accumulateDirectionalDispatches, event); - } -} + BN.prototype.uxor = function uxor (num) { + if (this.length > num.length) return this.clone().iuxor(num); + return num.clone().iuxor(this); + }; -/** - * Same as `accumulateTwoPhaseDispatchesSingle`, but skips over the targetID. - */ -function accumulateTwoPhaseDispatchesSingleSkipTarget(event) { - if (event && event.dispatchConfig.phasedRegistrationNames) { - var targetInst = event._targetInst; - var parentInst = targetInst ? EventPluginUtils.getParentInstance(targetInst) : null; - EventPluginUtils.traverseTwoPhase(parentInst, accumulateDirectionalDispatches, event); - } -} + // Not ``this`` with ``width`` bitwidth + BN.prototype.inotn = function inotn (width) { + assert(typeof width === 'number' && width >= 0); -/** - * Accumulates without regard to direction, does not look for phased - * registration names. Same as `accumulateDirectDispatchesSingle` but without - * requiring that the `dispatchMarker` be the same as the dispatched ID. - */ -function accumulateDispatches(inst, ignoredDirection, event) { - if (event && event.dispatchConfig.registrationName) { - var registrationName = event.dispatchConfig.registrationName; - var listener = getListener(inst, registrationName); - if (listener) { - event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); - event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); + var bytesNeeded = Math.ceil(width / 26) | 0; + var bitsLeft = width % 26; + + // Extend the buffer with leading zeroes + this._expand(bytesNeeded); + + if (bitsLeft > 0) { + bytesNeeded--; } - } -} -/** - * Accumulates dispatches on an `SyntheticEvent`, but only for the - * `dispatchMarker`. - * @param {SyntheticEvent} event - */ -function accumulateDirectDispatchesSingle(event) { - if (event && event.dispatchConfig.registrationName) { - accumulateDispatches(event._targetInst, null, event); - } -} + // Handle complete words + for (var i = 0; i < bytesNeeded; i++) { + this.words[i] = ~this.words[i] & 0x3ffffff; + } -function accumulateTwoPhaseDispatches(events) { - forEachAccumulated(events, accumulateTwoPhaseDispatchesSingle); -} + // Handle the residue + if (bitsLeft > 0) { + this.words[i] = ~this.words[i] & (0x3ffffff >> (26 - bitsLeft)); + } -function accumulateTwoPhaseDispatchesSkipTarget(events) { - forEachAccumulated(events, accumulateTwoPhaseDispatchesSingleSkipTarget); -} + // And remove leading zeroes + return this.strip(); + }; -function accumulateEnterLeaveDispatches(leave, enter, from, to) { - EventPluginUtils.traverseEnterLeave(from, to, accumulateDispatches, leave, enter); -} + BN.prototype.notn = function notn (width) { + return this.clone().inotn(width); + }; -function accumulateDirectDispatches(events) { - forEachAccumulated(events, accumulateDirectDispatchesSingle); -} + // Set `bit` of `this` + BN.prototype.setn = function setn (bit, val) { + assert(typeof bit === 'number' && bit >= 0); -/** - * A small set of propagation patterns, each of which will accept a small amount - * of information, and generate a set of "dispatch ready event objects" - which - * are sets of events that have already been annotated with a set of dispatched - * listener functions/ids. The API is designed this way to discourage these - * propagation strategies from actually executing the dispatches, since we - * always want to collect the entire set of dispatches before executing event a - * single one. - * - * @constructor EventPropagators - */ -var EventPropagators = { - accumulateTwoPhaseDispatches: accumulateTwoPhaseDispatches, - accumulateTwoPhaseDispatchesSkipTarget: accumulateTwoPhaseDispatchesSkipTarget, - accumulateDirectDispatches: accumulateDirectDispatches, - accumulateEnterLeaveDispatches: accumulateEnterLeaveDispatches -}; + var off = (bit / 26) | 0; + var wbit = bit % 26; -module.exports = EventPropagators; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + this._expand(off + 1); -/***/ }), -/* 32 */ -/***/ (function(module, exports, __webpack_require__) { + if (val) { + this.words[off] = this.words[off] | (1 << wbit); + } else { + this.words[off] = this.words[off] & ~(1 << wbit); + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return this.strip(); + }; + // Add `num` to `this` in-place + BN.prototype.iadd = function iadd (num) { + var r; + + // negative + positive + if (this.negative !== 0 && num.negative === 0) { + this.negative = 0; + r = this.isub(num); + this.negative ^= 1; + return this._normSign(); + + // positive + negative + } else if (this.negative === 0 && num.negative !== 0) { + num.negative = 0; + r = this.isub(num); + num.negative = 1; + return r._normSign(); + } + + // a.length > b.length + var a, b; + if (this.length > num.length) { + a = this; + b = num; + } else { + a = num; + b = this; + } + + var carry = 0; + for (var i = 0; i < b.length; i++) { + r = (a.words[i] | 0) + (b.words[i] | 0) + carry; + this.words[i] = r & 0x3ffffff; + carry = r >>> 26; + } + for (; carry !== 0 && i < a.length; i++) { + r = (a.words[i] | 0) + carry; + this.words[i] = r & 0x3ffffff; + carry = r >>> 26; + } + + this.length = a.length; + if (carry !== 0) { + this.words[this.length] = carry; + this.length++; + // Copy the rest of the words + } else if (a !== this) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; + } + } + return this; + }; -var _prodInvariant = __webpack_require__(3); + // Add `num` to `this` + BN.prototype.add = function add (num) { + var res; + if (num.negative !== 0 && this.negative === 0) { + num.negative = 0; + res = this.sub(num); + num.negative ^= 1; + return res; + } else if (num.negative === 0 && this.negative !== 0) { + this.negative = 0; + res = num.sub(this); + this.negative = 1; + return res; + } -var EventPluginRegistry = __webpack_require__(40); -var EventPluginUtils = __webpack_require__(50); -var ReactErrorUtils = __webpack_require__(51); + if (this.length > num.length) return this.clone().iadd(num); -var accumulateInto = __webpack_require__(82); -var forEachAccumulated = __webpack_require__(83); -var invariant = __webpack_require__(1); + return num.clone().iadd(this); + }; -/** - * Internal store for event listeners - */ -var listenerBank = {}; + // Subtract `num` from `this` in-place + BN.prototype.isub = function isub (num) { + // this - (-num) = this + num + if (num.negative !== 0) { + num.negative = 0; + var r = this.iadd(num); + num.negative = 1; + return r._normSign(); + + // -this - num = -(this + num) + } else if (this.negative !== 0) { + this.negative = 0; + this.iadd(num); + this.negative = 1; + return this._normSign(); + } + + // At this point both numbers are positive + var cmp = this.cmp(num); + + // Optimization - zeroify + if (cmp === 0) { + this.negative = 0; + this.length = 1; + this.words[0] = 0; + return this; + } + + // a > b + var a, b; + if (cmp > 0) { + a = this; + b = num; + } else { + a = num; + b = this; + } -/** - * Internal queue of events that have accumulated their dispatches and are - * waiting to have their dispatches executed. - */ -var eventQueue = null; + var carry = 0; + for (var i = 0; i < b.length; i++) { + r = (a.words[i] | 0) - (b.words[i] | 0) + carry; + carry = r >> 26; + this.words[i] = r & 0x3ffffff; + } + for (; carry !== 0 && i < a.length; i++) { + r = (a.words[i] | 0) + carry; + carry = r >> 26; + this.words[i] = r & 0x3ffffff; + } -/** - * Dispatches an event and releases it back into the pool, unless persistent. - * - * @param {?object} event Synthetic event to be dispatched. - * @param {boolean} simulated If the event is simulated (changes exn behavior) - * @private - */ -var executeDispatchesAndRelease = function (event, simulated) { - if (event) { - EventPluginUtils.executeDispatchesInOrder(event, simulated); + // Copy rest of the words + if (carry === 0 && i < a.length && a !== this) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; + } + } - if (!event.isPersistent()) { - event.constructor.release(event); + this.length = Math.max(this.length, i); + + if (a !== this) { + this.negative = 1; } - } -}; -var executeDispatchesAndReleaseSimulated = function (e) { - return executeDispatchesAndRelease(e, true); -}; -var executeDispatchesAndReleaseTopLevel = function (e) { - return executeDispatchesAndRelease(e, false); -}; -var getDictionaryKey = function (inst) { - // Prevents V8 performance issue: - // https://github.com/facebook/react/pull/7232 - return '.' + inst._rootNodeID; -}; + return this.strip(); + }; -function isInteractive(tag) { - return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; -} + // Subtract `num` from `this` + BN.prototype.sub = function sub (num) { + return this.clone().isub(num); + }; -function shouldPreventMouseEvent(name, type, props) { - switch (name) { - case 'onClick': - case 'onClickCapture': - case 'onDoubleClick': - case 'onDoubleClickCapture': - case 'onMouseDown': - case 'onMouseDownCapture': - case 'onMouseMove': - case 'onMouseMoveCapture': - case 'onMouseUp': - case 'onMouseUpCapture': - return !!(props.disabled && isInteractive(type)); - default: - return false; + function smallMulTo (self, num, out) { + out.negative = num.negative ^ self.negative; + var len = (self.length + num.length) | 0; + out.length = len; + len = (len - 1) | 0; + + // Peel one iteration (compiler can't do it, because of code complexity) + var a = self.words[0] | 0; + var b = num.words[0] | 0; + var r = a * b; + + var lo = r & 0x3ffffff; + var carry = (r / 0x4000000) | 0; + out.words[0] = lo; + + for (var k = 1; k < len; k++) { + // Sum all words with the same `i + j = k` and accumulate `ncarry`, + // note that ncarry could be >= 0x3ffffff + var ncarry = carry >>> 26; + var rword = carry & 0x3ffffff; + var maxJ = Math.min(k, num.length - 1); + for (var j = Math.max(0, k - self.length + 1); j <= maxJ; j++) { + var i = (k - j) | 0; + a = self.words[i] | 0; + b = num.words[j] | 0; + r = a * b + rword; + ncarry += (r / 0x4000000) | 0; + rword = r & 0x3ffffff; + } + out.words[k] = rword | 0; + carry = ncarry | 0; + } + if (carry !== 0) { + out.words[k] = carry | 0; + } else { + out.length--; + } + + return out.strip(); + } + + // TODO(indutny): it may be reasonable to omit it for users who don't need + // to work with 256-bit numbers, otherwise it gives 20% improvement for 256-bit + // multiplication (like elliptic secp256k1). + var comb10MulTo = function comb10MulTo (self, num, out) { + var a = self.words; + var b = num.words; + var o = out.words; + var c = 0; + var lo; + var mid; + var hi; + var a0 = a[0] | 0; + var al0 = a0 & 0x1fff; + var ah0 = a0 >>> 13; + var a1 = a[1] | 0; + var al1 = a1 & 0x1fff; + var ah1 = a1 >>> 13; + var a2 = a[2] | 0; + var al2 = a2 & 0x1fff; + var ah2 = a2 >>> 13; + var a3 = a[3] | 0; + var al3 = a3 & 0x1fff; + var ah3 = a3 >>> 13; + var a4 = a[4] | 0; + var al4 = a4 & 0x1fff; + var ah4 = a4 >>> 13; + var a5 = a[5] | 0; + var al5 = a5 & 0x1fff; + var ah5 = a5 >>> 13; + var a6 = a[6] | 0; + var al6 = a6 & 0x1fff; + var ah6 = a6 >>> 13; + var a7 = a[7] | 0; + var al7 = a7 & 0x1fff; + var ah7 = a7 >>> 13; + var a8 = a[8] | 0; + var al8 = a8 & 0x1fff; + var ah8 = a8 >>> 13; + var a9 = a[9] | 0; + var al9 = a9 & 0x1fff; + var ah9 = a9 >>> 13; + var b0 = b[0] | 0; + var bl0 = b0 & 0x1fff; + var bh0 = b0 >>> 13; + var b1 = b[1] | 0; + var bl1 = b1 & 0x1fff; + var bh1 = b1 >>> 13; + var b2 = b[2] | 0; + var bl2 = b2 & 0x1fff; + var bh2 = b2 >>> 13; + var b3 = b[3] | 0; + var bl3 = b3 & 0x1fff; + var bh3 = b3 >>> 13; + var b4 = b[4] | 0; + var bl4 = b4 & 0x1fff; + var bh4 = b4 >>> 13; + var b5 = b[5] | 0; + var bl5 = b5 & 0x1fff; + var bh5 = b5 >>> 13; + var b6 = b[6] | 0; + var bl6 = b6 & 0x1fff; + var bh6 = b6 >>> 13; + var b7 = b[7] | 0; + var bl7 = b7 & 0x1fff; + var bh7 = b7 >>> 13; + var b8 = b[8] | 0; + var bl8 = b8 & 0x1fff; + var bh8 = b8 >>> 13; + var b9 = b[9] | 0; + var bl9 = b9 & 0x1fff; + var bh9 = b9 >>> 13; + + out.negative = self.negative ^ num.negative; + out.length = 19; + /* k = 0 */ + lo = Math.imul(al0, bl0); + mid = Math.imul(al0, bh0); + mid = (mid + Math.imul(ah0, bl0)) | 0; + hi = Math.imul(ah0, bh0); + var w0 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w0 >>> 26)) | 0; + w0 &= 0x3ffffff; + /* k = 1 */ + lo = Math.imul(al1, bl0); + mid = Math.imul(al1, bh0); + mid = (mid + Math.imul(ah1, bl0)) | 0; + hi = Math.imul(ah1, bh0); + lo = (lo + Math.imul(al0, bl1)) | 0; + mid = (mid + Math.imul(al0, bh1)) | 0; + mid = (mid + Math.imul(ah0, bl1)) | 0; + hi = (hi + Math.imul(ah0, bh1)) | 0; + var w1 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w1 >>> 26)) | 0; + w1 &= 0x3ffffff; + /* k = 2 */ + lo = Math.imul(al2, bl0); + mid = Math.imul(al2, bh0); + mid = (mid + Math.imul(ah2, bl0)) | 0; + hi = Math.imul(ah2, bh0); + lo = (lo + Math.imul(al1, bl1)) | 0; + mid = (mid + Math.imul(al1, bh1)) | 0; + mid = (mid + Math.imul(ah1, bl1)) | 0; + hi = (hi + Math.imul(ah1, bh1)) | 0; + lo = (lo + Math.imul(al0, bl2)) | 0; + mid = (mid + Math.imul(al0, bh2)) | 0; + mid = (mid + Math.imul(ah0, bl2)) | 0; + hi = (hi + Math.imul(ah0, bh2)) | 0; + var w2 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w2 >>> 26)) | 0; + w2 &= 0x3ffffff; + /* k = 3 */ + lo = Math.imul(al3, bl0); + mid = Math.imul(al3, bh0); + mid = (mid + Math.imul(ah3, bl0)) | 0; + hi = Math.imul(ah3, bh0); + lo = (lo + Math.imul(al2, bl1)) | 0; + mid = (mid + Math.imul(al2, bh1)) | 0; + mid = (mid + Math.imul(ah2, bl1)) | 0; + hi = (hi + Math.imul(ah2, bh1)) | 0; + lo = (lo + Math.imul(al1, bl2)) | 0; + mid = (mid + Math.imul(al1, bh2)) | 0; + mid = (mid + Math.imul(ah1, bl2)) | 0; + hi = (hi + Math.imul(ah1, bh2)) | 0; + lo = (lo + Math.imul(al0, bl3)) | 0; + mid = (mid + Math.imul(al0, bh3)) | 0; + mid = (mid + Math.imul(ah0, bl3)) | 0; + hi = (hi + Math.imul(ah0, bh3)) | 0; + var w3 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w3 >>> 26)) | 0; + w3 &= 0x3ffffff; + /* k = 4 */ + lo = Math.imul(al4, bl0); + mid = Math.imul(al4, bh0); + mid = (mid + Math.imul(ah4, bl0)) | 0; + hi = Math.imul(ah4, bh0); + lo = (lo + Math.imul(al3, bl1)) | 0; + mid = (mid + Math.imul(al3, bh1)) | 0; + mid = (mid + Math.imul(ah3, bl1)) | 0; + hi = (hi + Math.imul(ah3, bh1)) | 0; + lo = (lo + Math.imul(al2, bl2)) | 0; + mid = (mid + Math.imul(al2, bh2)) | 0; + mid = (mid + Math.imul(ah2, bl2)) | 0; + hi = (hi + Math.imul(ah2, bh2)) | 0; + lo = (lo + Math.imul(al1, bl3)) | 0; + mid = (mid + Math.imul(al1, bh3)) | 0; + mid = (mid + Math.imul(ah1, bl3)) | 0; + hi = (hi + Math.imul(ah1, bh3)) | 0; + lo = (lo + Math.imul(al0, bl4)) | 0; + mid = (mid + Math.imul(al0, bh4)) | 0; + mid = (mid + Math.imul(ah0, bl4)) | 0; + hi = (hi + Math.imul(ah0, bh4)) | 0; + var w4 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w4 >>> 26)) | 0; + w4 &= 0x3ffffff; + /* k = 5 */ + lo = Math.imul(al5, bl0); + mid = Math.imul(al5, bh0); + mid = (mid + Math.imul(ah5, bl0)) | 0; + hi = Math.imul(ah5, bh0); + lo = (lo + Math.imul(al4, bl1)) | 0; + mid = (mid + Math.imul(al4, bh1)) | 0; + mid = (mid + Math.imul(ah4, bl1)) | 0; + hi = (hi + Math.imul(ah4, bh1)) | 0; + lo = (lo + Math.imul(al3, bl2)) | 0; + mid = (mid + Math.imul(al3, bh2)) | 0; + mid = (mid + Math.imul(ah3, bl2)) | 0; + hi = (hi + Math.imul(ah3, bh2)) | 0; + lo = (lo + Math.imul(al2, bl3)) | 0; + mid = (mid + Math.imul(al2, bh3)) | 0; + mid = (mid + Math.imul(ah2, bl3)) | 0; + hi = (hi + Math.imul(ah2, bh3)) | 0; + lo = (lo + Math.imul(al1, bl4)) | 0; + mid = (mid + Math.imul(al1, bh4)) | 0; + mid = (mid + Math.imul(ah1, bl4)) | 0; + hi = (hi + Math.imul(ah1, bh4)) | 0; + lo = (lo + Math.imul(al0, bl5)) | 0; + mid = (mid + Math.imul(al0, bh5)) | 0; + mid = (mid + Math.imul(ah0, bl5)) | 0; + hi = (hi + Math.imul(ah0, bh5)) | 0; + var w5 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w5 >>> 26)) | 0; + w5 &= 0x3ffffff; + /* k = 6 */ + lo = Math.imul(al6, bl0); + mid = Math.imul(al6, bh0); + mid = (mid + Math.imul(ah6, bl0)) | 0; + hi = Math.imul(ah6, bh0); + lo = (lo + Math.imul(al5, bl1)) | 0; + mid = (mid + Math.imul(al5, bh1)) | 0; + mid = (mid + Math.imul(ah5, bl1)) | 0; + hi = (hi + Math.imul(ah5, bh1)) | 0; + lo = (lo + Math.imul(al4, bl2)) | 0; + mid = (mid + Math.imul(al4, bh2)) | 0; + mid = (mid + Math.imul(ah4, bl2)) | 0; + hi = (hi + Math.imul(ah4, bh2)) | 0; + lo = (lo + Math.imul(al3, bl3)) | 0; + mid = (mid + Math.imul(al3, bh3)) | 0; + mid = (mid + Math.imul(ah3, bl3)) | 0; + hi = (hi + Math.imul(ah3, bh3)) | 0; + lo = (lo + Math.imul(al2, bl4)) | 0; + mid = (mid + Math.imul(al2, bh4)) | 0; + mid = (mid + Math.imul(ah2, bl4)) | 0; + hi = (hi + Math.imul(ah2, bh4)) | 0; + lo = (lo + Math.imul(al1, bl5)) | 0; + mid = (mid + Math.imul(al1, bh5)) | 0; + mid = (mid + Math.imul(ah1, bl5)) | 0; + hi = (hi + Math.imul(ah1, bh5)) | 0; + lo = (lo + Math.imul(al0, bl6)) | 0; + mid = (mid + Math.imul(al0, bh6)) | 0; + mid = (mid + Math.imul(ah0, bl6)) | 0; + hi = (hi + Math.imul(ah0, bh6)) | 0; + var w6 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w6 >>> 26)) | 0; + w6 &= 0x3ffffff; + /* k = 7 */ + lo = Math.imul(al7, bl0); + mid = Math.imul(al7, bh0); + mid = (mid + Math.imul(ah7, bl0)) | 0; + hi = Math.imul(ah7, bh0); + lo = (lo + Math.imul(al6, bl1)) | 0; + mid = (mid + Math.imul(al6, bh1)) | 0; + mid = (mid + Math.imul(ah6, bl1)) | 0; + hi = (hi + Math.imul(ah6, bh1)) | 0; + lo = (lo + Math.imul(al5, bl2)) | 0; + mid = (mid + Math.imul(al5, bh2)) | 0; + mid = (mid + Math.imul(ah5, bl2)) | 0; + hi = (hi + Math.imul(ah5, bh2)) | 0; + lo = (lo + Math.imul(al4, bl3)) | 0; + mid = (mid + Math.imul(al4, bh3)) | 0; + mid = (mid + Math.imul(ah4, bl3)) | 0; + hi = (hi + Math.imul(ah4, bh3)) | 0; + lo = (lo + Math.imul(al3, bl4)) | 0; + mid = (mid + Math.imul(al3, bh4)) | 0; + mid = (mid + Math.imul(ah3, bl4)) | 0; + hi = (hi + Math.imul(ah3, bh4)) | 0; + lo = (lo + Math.imul(al2, bl5)) | 0; + mid = (mid + Math.imul(al2, bh5)) | 0; + mid = (mid + Math.imul(ah2, bl5)) | 0; + hi = (hi + Math.imul(ah2, bh5)) | 0; + lo = (lo + Math.imul(al1, bl6)) | 0; + mid = (mid + Math.imul(al1, bh6)) | 0; + mid = (mid + Math.imul(ah1, bl6)) | 0; + hi = (hi + Math.imul(ah1, bh6)) | 0; + lo = (lo + Math.imul(al0, bl7)) | 0; + mid = (mid + Math.imul(al0, bh7)) | 0; + mid = (mid + Math.imul(ah0, bl7)) | 0; + hi = (hi + Math.imul(ah0, bh7)) | 0; + var w7 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w7 >>> 26)) | 0; + w7 &= 0x3ffffff; + /* k = 8 */ + lo = Math.imul(al8, bl0); + mid = Math.imul(al8, bh0); + mid = (mid + Math.imul(ah8, bl0)) | 0; + hi = Math.imul(ah8, bh0); + lo = (lo + Math.imul(al7, bl1)) | 0; + mid = (mid + Math.imul(al7, bh1)) | 0; + mid = (mid + Math.imul(ah7, bl1)) | 0; + hi = (hi + Math.imul(ah7, bh1)) | 0; + lo = (lo + Math.imul(al6, bl2)) | 0; + mid = (mid + Math.imul(al6, bh2)) | 0; + mid = (mid + Math.imul(ah6, bl2)) | 0; + hi = (hi + Math.imul(ah6, bh2)) | 0; + lo = (lo + Math.imul(al5, bl3)) | 0; + mid = (mid + Math.imul(al5, bh3)) | 0; + mid = (mid + Math.imul(ah5, bl3)) | 0; + hi = (hi + Math.imul(ah5, bh3)) | 0; + lo = (lo + Math.imul(al4, bl4)) | 0; + mid = (mid + Math.imul(al4, bh4)) | 0; + mid = (mid + Math.imul(ah4, bl4)) | 0; + hi = (hi + Math.imul(ah4, bh4)) | 0; + lo = (lo + Math.imul(al3, bl5)) | 0; + mid = (mid + Math.imul(al3, bh5)) | 0; + mid = (mid + Math.imul(ah3, bl5)) | 0; + hi = (hi + Math.imul(ah3, bh5)) | 0; + lo = (lo + Math.imul(al2, bl6)) | 0; + mid = (mid + Math.imul(al2, bh6)) | 0; + mid = (mid + Math.imul(ah2, bl6)) | 0; + hi = (hi + Math.imul(ah2, bh6)) | 0; + lo = (lo + Math.imul(al1, bl7)) | 0; + mid = (mid + Math.imul(al1, bh7)) | 0; + mid = (mid + Math.imul(ah1, bl7)) | 0; + hi = (hi + Math.imul(ah1, bh7)) | 0; + lo = (lo + Math.imul(al0, bl8)) | 0; + mid = (mid + Math.imul(al0, bh8)) | 0; + mid = (mid + Math.imul(ah0, bl8)) | 0; + hi = (hi + Math.imul(ah0, bh8)) | 0; + var w8 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w8 >>> 26)) | 0; + w8 &= 0x3ffffff; + /* k = 9 */ + lo = Math.imul(al9, bl0); + mid = Math.imul(al9, bh0); + mid = (mid + Math.imul(ah9, bl0)) | 0; + hi = Math.imul(ah9, bh0); + lo = (lo + Math.imul(al8, bl1)) | 0; + mid = (mid + Math.imul(al8, bh1)) | 0; + mid = (mid + Math.imul(ah8, bl1)) | 0; + hi = (hi + Math.imul(ah8, bh1)) | 0; + lo = (lo + Math.imul(al7, bl2)) | 0; + mid = (mid + Math.imul(al7, bh2)) | 0; + mid = (mid + Math.imul(ah7, bl2)) | 0; + hi = (hi + Math.imul(ah7, bh2)) | 0; + lo = (lo + Math.imul(al6, bl3)) | 0; + mid = (mid + Math.imul(al6, bh3)) | 0; + mid = (mid + Math.imul(ah6, bl3)) | 0; + hi = (hi + Math.imul(ah6, bh3)) | 0; + lo = (lo + Math.imul(al5, bl4)) | 0; + mid = (mid + Math.imul(al5, bh4)) | 0; + mid = (mid + Math.imul(ah5, bl4)) | 0; + hi = (hi + Math.imul(ah5, bh4)) | 0; + lo = (lo + Math.imul(al4, bl5)) | 0; + mid = (mid + Math.imul(al4, bh5)) | 0; + mid = (mid + Math.imul(ah4, bl5)) | 0; + hi = (hi + Math.imul(ah4, bh5)) | 0; + lo = (lo + Math.imul(al3, bl6)) | 0; + mid = (mid + Math.imul(al3, bh6)) | 0; + mid = (mid + Math.imul(ah3, bl6)) | 0; + hi = (hi + Math.imul(ah3, bh6)) | 0; + lo = (lo + Math.imul(al2, bl7)) | 0; + mid = (mid + Math.imul(al2, bh7)) | 0; + mid = (mid + Math.imul(ah2, bl7)) | 0; + hi = (hi + Math.imul(ah2, bh7)) | 0; + lo = (lo + Math.imul(al1, bl8)) | 0; + mid = (mid + Math.imul(al1, bh8)) | 0; + mid = (mid + Math.imul(ah1, bl8)) | 0; + hi = (hi + Math.imul(ah1, bh8)) | 0; + lo = (lo + Math.imul(al0, bl9)) | 0; + mid = (mid + Math.imul(al0, bh9)) | 0; + mid = (mid + Math.imul(ah0, bl9)) | 0; + hi = (hi + Math.imul(ah0, bh9)) | 0; + var w9 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w9 >>> 26)) | 0; + w9 &= 0x3ffffff; + /* k = 10 */ + lo = Math.imul(al9, bl1); + mid = Math.imul(al9, bh1); + mid = (mid + Math.imul(ah9, bl1)) | 0; + hi = Math.imul(ah9, bh1); + lo = (lo + Math.imul(al8, bl2)) | 0; + mid = (mid + Math.imul(al8, bh2)) | 0; + mid = (mid + Math.imul(ah8, bl2)) | 0; + hi = (hi + Math.imul(ah8, bh2)) | 0; + lo = (lo + Math.imul(al7, bl3)) | 0; + mid = (mid + Math.imul(al7, bh3)) | 0; + mid = (mid + Math.imul(ah7, bl3)) | 0; + hi = (hi + Math.imul(ah7, bh3)) | 0; + lo = (lo + Math.imul(al6, bl4)) | 0; + mid = (mid + Math.imul(al6, bh4)) | 0; + mid = (mid + Math.imul(ah6, bl4)) | 0; + hi = (hi + Math.imul(ah6, bh4)) | 0; + lo = (lo + Math.imul(al5, bl5)) | 0; + mid = (mid + Math.imul(al5, bh5)) | 0; + mid = (mid + Math.imul(ah5, bl5)) | 0; + hi = (hi + Math.imul(ah5, bh5)) | 0; + lo = (lo + Math.imul(al4, bl6)) | 0; + mid = (mid + Math.imul(al4, bh6)) | 0; + mid = (mid + Math.imul(ah4, bl6)) | 0; + hi = (hi + Math.imul(ah4, bh6)) | 0; + lo = (lo + Math.imul(al3, bl7)) | 0; + mid = (mid + Math.imul(al3, bh7)) | 0; + mid = (mid + Math.imul(ah3, bl7)) | 0; + hi = (hi + Math.imul(ah3, bh7)) | 0; + lo = (lo + Math.imul(al2, bl8)) | 0; + mid = (mid + Math.imul(al2, bh8)) | 0; + mid = (mid + Math.imul(ah2, bl8)) | 0; + hi = (hi + Math.imul(ah2, bh8)) | 0; + lo = (lo + Math.imul(al1, bl9)) | 0; + mid = (mid + Math.imul(al1, bh9)) | 0; + mid = (mid + Math.imul(ah1, bl9)) | 0; + hi = (hi + Math.imul(ah1, bh9)) | 0; + var w10 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w10 >>> 26)) | 0; + w10 &= 0x3ffffff; + /* k = 11 */ + lo = Math.imul(al9, bl2); + mid = Math.imul(al9, bh2); + mid = (mid + Math.imul(ah9, bl2)) | 0; + hi = Math.imul(ah9, bh2); + lo = (lo + Math.imul(al8, bl3)) | 0; + mid = (mid + Math.imul(al8, bh3)) | 0; + mid = (mid + Math.imul(ah8, bl3)) | 0; + hi = (hi + Math.imul(ah8, bh3)) | 0; + lo = (lo + Math.imul(al7, bl4)) | 0; + mid = (mid + Math.imul(al7, bh4)) | 0; + mid = (mid + Math.imul(ah7, bl4)) | 0; + hi = (hi + Math.imul(ah7, bh4)) | 0; + lo = (lo + Math.imul(al6, bl5)) | 0; + mid = (mid + Math.imul(al6, bh5)) | 0; + mid = (mid + Math.imul(ah6, bl5)) | 0; + hi = (hi + Math.imul(ah6, bh5)) | 0; + lo = (lo + Math.imul(al5, bl6)) | 0; + mid = (mid + Math.imul(al5, bh6)) | 0; + mid = (mid + Math.imul(ah5, bl6)) | 0; + hi = (hi + Math.imul(ah5, bh6)) | 0; + lo = (lo + Math.imul(al4, bl7)) | 0; + mid = (mid + Math.imul(al4, bh7)) | 0; + mid = (mid + Math.imul(ah4, bl7)) | 0; + hi = (hi + Math.imul(ah4, bh7)) | 0; + lo = (lo + Math.imul(al3, bl8)) | 0; + mid = (mid + Math.imul(al3, bh8)) | 0; + mid = (mid + Math.imul(ah3, bl8)) | 0; + hi = (hi + Math.imul(ah3, bh8)) | 0; + lo = (lo + Math.imul(al2, bl9)) | 0; + mid = (mid + Math.imul(al2, bh9)) | 0; + mid = (mid + Math.imul(ah2, bl9)) | 0; + hi = (hi + Math.imul(ah2, bh9)) | 0; + var w11 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w11 >>> 26)) | 0; + w11 &= 0x3ffffff; + /* k = 12 */ + lo = Math.imul(al9, bl3); + mid = Math.imul(al9, bh3); + mid = (mid + Math.imul(ah9, bl3)) | 0; + hi = Math.imul(ah9, bh3); + lo = (lo + Math.imul(al8, bl4)) | 0; + mid = (mid + Math.imul(al8, bh4)) | 0; + mid = (mid + Math.imul(ah8, bl4)) | 0; + hi = (hi + Math.imul(ah8, bh4)) | 0; + lo = (lo + Math.imul(al7, bl5)) | 0; + mid = (mid + Math.imul(al7, bh5)) | 0; + mid = (mid + Math.imul(ah7, bl5)) | 0; + hi = (hi + Math.imul(ah7, bh5)) | 0; + lo = (lo + Math.imul(al6, bl6)) | 0; + mid = (mid + Math.imul(al6, bh6)) | 0; + mid = (mid + Math.imul(ah6, bl6)) | 0; + hi = (hi + Math.imul(ah6, bh6)) | 0; + lo = (lo + Math.imul(al5, bl7)) | 0; + mid = (mid + Math.imul(al5, bh7)) | 0; + mid = (mid + Math.imul(ah5, bl7)) | 0; + hi = (hi + Math.imul(ah5, bh7)) | 0; + lo = (lo + Math.imul(al4, bl8)) | 0; + mid = (mid + Math.imul(al4, bh8)) | 0; + mid = (mid + Math.imul(ah4, bl8)) | 0; + hi = (hi + Math.imul(ah4, bh8)) | 0; + lo = (lo + Math.imul(al3, bl9)) | 0; + mid = (mid + Math.imul(al3, bh9)) | 0; + mid = (mid + Math.imul(ah3, bl9)) | 0; + hi = (hi + Math.imul(ah3, bh9)) | 0; + var w12 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w12 >>> 26)) | 0; + w12 &= 0x3ffffff; + /* k = 13 */ + lo = Math.imul(al9, bl4); + mid = Math.imul(al9, bh4); + mid = (mid + Math.imul(ah9, bl4)) | 0; + hi = Math.imul(ah9, bh4); + lo = (lo + Math.imul(al8, bl5)) | 0; + mid = (mid + Math.imul(al8, bh5)) | 0; + mid = (mid + Math.imul(ah8, bl5)) | 0; + hi = (hi + Math.imul(ah8, bh5)) | 0; + lo = (lo + Math.imul(al7, bl6)) | 0; + mid = (mid + Math.imul(al7, bh6)) | 0; + mid = (mid + Math.imul(ah7, bl6)) | 0; + hi = (hi + Math.imul(ah7, bh6)) | 0; + lo = (lo + Math.imul(al6, bl7)) | 0; + mid = (mid + Math.imul(al6, bh7)) | 0; + mid = (mid + Math.imul(ah6, bl7)) | 0; + hi = (hi + Math.imul(ah6, bh7)) | 0; + lo = (lo + Math.imul(al5, bl8)) | 0; + mid = (mid + Math.imul(al5, bh8)) | 0; + mid = (mid + Math.imul(ah5, bl8)) | 0; + hi = (hi + Math.imul(ah5, bh8)) | 0; + lo = (lo + Math.imul(al4, bl9)) | 0; + mid = (mid + Math.imul(al4, bh9)) | 0; + mid = (mid + Math.imul(ah4, bl9)) | 0; + hi = (hi + Math.imul(ah4, bh9)) | 0; + var w13 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w13 >>> 26)) | 0; + w13 &= 0x3ffffff; + /* k = 14 */ + lo = Math.imul(al9, bl5); + mid = Math.imul(al9, bh5); + mid = (mid + Math.imul(ah9, bl5)) | 0; + hi = Math.imul(ah9, bh5); + lo = (lo + Math.imul(al8, bl6)) | 0; + mid = (mid + Math.imul(al8, bh6)) | 0; + mid = (mid + Math.imul(ah8, bl6)) | 0; + hi = (hi + Math.imul(ah8, bh6)) | 0; + lo = (lo + Math.imul(al7, bl7)) | 0; + mid = (mid + Math.imul(al7, bh7)) | 0; + mid = (mid + Math.imul(ah7, bl7)) | 0; + hi = (hi + Math.imul(ah7, bh7)) | 0; + lo = (lo + Math.imul(al6, bl8)) | 0; + mid = (mid + Math.imul(al6, bh8)) | 0; + mid = (mid + Math.imul(ah6, bl8)) | 0; + hi = (hi + Math.imul(ah6, bh8)) | 0; + lo = (lo + Math.imul(al5, bl9)) | 0; + mid = (mid + Math.imul(al5, bh9)) | 0; + mid = (mid + Math.imul(ah5, bl9)) | 0; + hi = (hi + Math.imul(ah5, bh9)) | 0; + var w14 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w14 >>> 26)) | 0; + w14 &= 0x3ffffff; + /* k = 15 */ + lo = Math.imul(al9, bl6); + mid = Math.imul(al9, bh6); + mid = (mid + Math.imul(ah9, bl6)) | 0; + hi = Math.imul(ah9, bh6); + lo = (lo + Math.imul(al8, bl7)) | 0; + mid = (mid + Math.imul(al8, bh7)) | 0; + mid = (mid + Math.imul(ah8, bl7)) | 0; + hi = (hi + Math.imul(ah8, bh7)) | 0; + lo = (lo + Math.imul(al7, bl8)) | 0; + mid = (mid + Math.imul(al7, bh8)) | 0; + mid = (mid + Math.imul(ah7, bl8)) | 0; + hi = (hi + Math.imul(ah7, bh8)) | 0; + lo = (lo + Math.imul(al6, bl9)) | 0; + mid = (mid + Math.imul(al6, bh9)) | 0; + mid = (mid + Math.imul(ah6, bl9)) | 0; + hi = (hi + Math.imul(ah6, bh9)) | 0; + var w15 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w15 >>> 26)) | 0; + w15 &= 0x3ffffff; + /* k = 16 */ + lo = Math.imul(al9, bl7); + mid = Math.imul(al9, bh7); + mid = (mid + Math.imul(ah9, bl7)) | 0; + hi = Math.imul(ah9, bh7); + lo = (lo + Math.imul(al8, bl8)) | 0; + mid = (mid + Math.imul(al8, bh8)) | 0; + mid = (mid + Math.imul(ah8, bl8)) | 0; + hi = (hi + Math.imul(ah8, bh8)) | 0; + lo = (lo + Math.imul(al7, bl9)) | 0; + mid = (mid + Math.imul(al7, bh9)) | 0; + mid = (mid + Math.imul(ah7, bl9)) | 0; + hi = (hi + Math.imul(ah7, bh9)) | 0; + var w16 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w16 >>> 26)) | 0; + w16 &= 0x3ffffff; + /* k = 17 */ + lo = Math.imul(al9, bl8); + mid = Math.imul(al9, bh8); + mid = (mid + Math.imul(ah9, bl8)) | 0; + hi = Math.imul(ah9, bh8); + lo = (lo + Math.imul(al8, bl9)) | 0; + mid = (mid + Math.imul(al8, bh9)) | 0; + mid = (mid + Math.imul(ah8, bl9)) | 0; + hi = (hi + Math.imul(ah8, bh9)) | 0; + var w17 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w17 >>> 26)) | 0; + w17 &= 0x3ffffff; + /* k = 18 */ + lo = Math.imul(al9, bl9); + mid = Math.imul(al9, bh9); + mid = (mid + Math.imul(ah9, bl9)) | 0; + hi = Math.imul(ah9, bh9); + var w18 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w18 >>> 26)) | 0; + w18 &= 0x3ffffff; + o[0] = w0; + o[1] = w1; + o[2] = w2; + o[3] = w3; + o[4] = w4; + o[5] = w5; + o[6] = w6; + o[7] = w7; + o[8] = w8; + o[9] = w9; + o[10] = w10; + o[11] = w11; + o[12] = w12; + o[13] = w13; + o[14] = w14; + o[15] = w15; + o[16] = w16; + o[17] = w17; + o[18] = w18; + if (c !== 0) { + o[19] = c; + out.length++; + } + return out; + }; + + // Polyfill comb + if (!Math.imul) { + comb10MulTo = smallMulTo; + } + + function bigMulTo (self, num, out) { + out.negative = num.negative ^ self.negative; + out.length = self.length + num.length; + + var carry = 0; + var hncarry = 0; + for (var k = 0; k < out.length - 1; k++) { + // Sum all words with the same `i + j = k` and accumulate `ncarry`, + // note that ncarry could be >= 0x3ffffff + var ncarry = hncarry; + hncarry = 0; + var rword = carry & 0x3ffffff; + var maxJ = Math.min(k, num.length - 1); + for (var j = Math.max(0, k - self.length + 1); j <= maxJ; j++) { + var i = k - j; + var a = self.words[i] | 0; + var b = num.words[j] | 0; + var r = a * b; + + var lo = r & 0x3ffffff; + ncarry = (ncarry + ((r / 0x4000000) | 0)) | 0; + lo = (lo + rword) | 0; + rword = lo & 0x3ffffff; + ncarry = (ncarry + (lo >>> 26)) | 0; + + hncarry += ncarry >>> 26; + ncarry &= 0x3ffffff; + } + out.words[k] = rword; + carry = ncarry; + ncarry = hncarry; + } + if (carry !== 0) { + out.words[k] = carry; + } else { + out.length--; + } + + return out.strip(); } -} -/** - * This is a unified interface for event plugins to be installed and configured. - * - * Event plugins can implement the following properties: - * - * `extractEvents` {function(string, DOMEventTarget, string, object): *} - * Required. When a top-level event is fired, this method is expected to - * extract synthetic events that will in turn be queued and dispatched. - * - * `eventTypes` {object} - * Optional, plugins that fire events must publish a mapping of registration - * names that are used to register listeners. Values of this mapping must - * be objects that contain `registrationName` or `phasedRegistrationNames`. - * - * `executeDispatch` {function(object, function, string)} - * Optional, allows plugins to override how an event gets dispatched. By - * default, the listener is simply invoked. - * - * Each plugin that is injected into `EventsPluginHub` is immediately operable. - * - * @public - */ -var EventPluginHub = { - /** - * Methods for injecting dependencies. - */ - injection: { - /** - * @param {array} InjectedEventPluginOrder - * @public - */ - injectEventPluginOrder: EventPluginRegistry.injectEventPluginOrder, + function jumboMulTo (self, num, out) { + var fftm = new FFTM(); + return fftm.mulp(self, num, out); + } - /** - * @param {object} injectedNamesToPlugins Map from names to plugin modules. - */ - injectEventPluginsByName: EventPluginRegistry.injectEventPluginsByName - }, + BN.prototype.mulTo = function mulTo (num, out) { + var res; + var len = this.length + num.length; + if (this.length === 10 && num.length === 10) { + res = comb10MulTo(this, num, out); + } else if (len < 63) { + res = smallMulTo(this, num, out); + } else if (len < 1024) { + res = bigMulTo(this, num, out); + } else { + res = jumboMulTo(this, num, out); + } - /** - * Stores `listener` at `listenerBank[registrationName][key]`. Is idempotent. - * - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @param {function} listener The callback to store. - */ - putListener: function (inst, registrationName, listener) { - !(typeof listener === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected %s listener to be a function, instead got type %s', registrationName, typeof listener) : _prodInvariant('94', registrationName, typeof listener) : void 0; + return res; + }; - var key = getDictionaryKey(inst); - var bankForRegistrationName = listenerBank[registrationName] || (listenerBank[registrationName] = {}); - bankForRegistrationName[key] = listener; + // Cooley-Tukey algorithm for FFT + // slightly revisited to rely on looping instead of recursion - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.didPutListener) { - PluginModule.didPutListener(inst, registrationName, listener); - } - }, + function FFTM (x, y) { + this.x = x; + this.y = y; + } - /** - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @return {?function} The stored callback. - */ - getListener: function (inst, registrationName) { - // TODO: shouldPreventMouseEvent is DOM-specific and definitely should not - // live here; needs to be moved to a better place soon - var bankForRegistrationName = listenerBank[registrationName]; - if (shouldPreventMouseEvent(registrationName, inst._currentElement.type, inst._currentElement.props)) { - return null; + FFTM.prototype.makeRBT = function makeRBT (N) { + var t = new Array(N); + var l = BN.prototype._countBits(N) - 1; + for (var i = 0; i < N; i++) { + t[i] = this.revBin(i, l, N); } - var key = getDictionaryKey(inst); - return bankForRegistrationName && bankForRegistrationName[key]; - }, - /** - * Deletes a listener from the registration bank. - * - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - */ - deleteListener: function (inst, registrationName) { - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.willDeleteListener) { - PluginModule.willDeleteListener(inst, registrationName); + return t; + }; + + // Returns binary-reversed representation of `x` + FFTM.prototype.revBin = function revBin (x, l, N) { + if (x === 0 || x === N - 1) return x; + + var rb = 0; + for (var i = 0; i < l; i++) { + rb |= (x & 1) << (l - i - 1); + x >>= 1; } - var bankForRegistrationName = listenerBank[registrationName]; - // TODO: This should never be null -- when is it? - if (bankForRegistrationName) { - var key = getDictionaryKey(inst); - delete bankForRegistrationName[key]; + return rb; + }; + + // Performs "tweedling" phase, therefore 'emulating' + // behaviour of the recursive algorithm + FFTM.prototype.permute = function permute (rbt, rws, iws, rtws, itws, N) { + for (var i = 0; i < N; i++) { + rtws[i] = rws[rbt[i]]; + itws[i] = iws[rbt[i]]; } - }, + }; - /** - * Deletes all listeners for the DOM element with the supplied ID. - * - * @param {object} inst The instance, which is the source of events. - */ - deleteAllListeners: function (inst) { - var key = getDictionaryKey(inst); - for (var registrationName in listenerBank) { - if (!listenerBank.hasOwnProperty(registrationName)) { - continue; - } + FFTM.prototype.transform = function transform (rws, iws, rtws, itws, N, rbt) { + this.permute(rbt, rws, iws, rtws, itws, N); - if (!listenerBank[registrationName][key]) { - continue; - } + for (var s = 1; s < N; s <<= 1) { + var l = s << 1; - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.willDeleteListener) { - PluginModule.willDeleteListener(inst, registrationName); - } + var rtwdf = Math.cos(2 * Math.PI / l); + var itwdf = Math.sin(2 * Math.PI / l); - delete listenerBank[registrationName][key]; - } - }, + for (var p = 0; p < N; p += l) { + var rtwdf_ = rtwdf; + var itwdf_ = itwdf; - /** - * Allows registered plugins an opportunity to extract events from top-level - * native browser events. - * - * @return {*} An accumulation of synthetic events. - * @internal - */ - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var events; - var plugins = EventPluginRegistry.plugins; - for (var i = 0; i < plugins.length; i++) { - // Not every plugin in the ordering may be loaded at runtime. - var possiblePlugin = plugins[i]; - if (possiblePlugin) { - var extractedEvents = possiblePlugin.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); - if (extractedEvents) { - events = accumulateInto(events, extractedEvents); + for (var j = 0; j < s; j++) { + var re = rtws[p + j]; + var ie = itws[p + j]; + + var ro = rtws[p + j + s]; + var io = itws[p + j + s]; + + var rx = rtwdf_ * ro - itwdf_ * io; + + io = rtwdf_ * io + itwdf_ * ro; + ro = rx; + + rtws[p + j] = re + ro; + itws[p + j] = ie + io; + + rtws[p + j + s] = re - ro; + itws[p + j + s] = ie - io; + + /* jshint maxdepth : false */ + if (j !== l) { + rx = rtwdf * rtwdf_ - itwdf * itwdf_; + + itwdf_ = rtwdf * itwdf_ + itwdf * rtwdf_; + rtwdf_ = rx; + } } } } - return events; - }, + }; - /** - * Enqueues a synthetic event that should be dispatched when - * `processEventQueue` is invoked. - * - * @param {*} events An accumulation of synthetic events. - * @internal - */ - enqueueEvents: function (events) { - if (events) { - eventQueue = accumulateInto(eventQueue, events); + FFTM.prototype.guessLen13b = function guessLen13b (n, m) { + var N = Math.max(m, n) | 1; + var odd = N & 1; + var i = 0; + for (N = N / 2 | 0; N; N = N >>> 1) { + i++; } - }, - /** - * Dispatches all synthetic events on the event queue. - * - * @internal - */ - processEventQueue: function (simulated) { - // Set `eventQueue` to null before processing it so that we can tell if more - // events get enqueued while processing. - var processingEventQueue = eventQueue; - eventQueue = null; - if (simulated) { - forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseSimulated); - } else { - forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseTopLevel); - } - !!eventQueue ? process.env.NODE_ENV !== 'production' ? invariant(false, 'processEventQueue(): Additional events were enqueued while processing an event queue. Support for this has not yet been implemented.') : _prodInvariant('95') : void 0; - // This would be a good time to rethrow if any of the event handlers threw. - ReactErrorUtils.rethrowCaughtError(); - }, + return 1 << i + 1 + odd; + }; - /** - * These are needed for tests only. Do not use! - */ - __purge: function () { - listenerBank = {}; - }, + FFTM.prototype.conjugate = function conjugate (rws, iws, N) { + if (N <= 1) return; - __getListenerBank: function () { - return listenerBank; - } -}; + for (var i = 0; i < N / 2; i++) { + var t = rws[i]; -module.exports = EventPluginHub; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + rws[i] = rws[N - i - 1]; + rws[N - i - 1] = t; -/***/ }), -/* 33 */ -/***/ (function(module, exports, __webpack_require__) { + t = iws[i]; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + iws[i] = -iws[N - i - 1]; + iws[N - i - 1] = -t; + } + }; + FFTM.prototype.normalize13b = function normalize13b (ws, N) { + var carry = 0; + for (var i = 0; i < N / 2; i++) { + var w = Math.round(ws[2 * i + 1] / N) * 0x2000 + + Math.round(ws[2 * i] / N) + + carry; + ws[i] = w & 0x3ffffff; -var SyntheticEvent = __webpack_require__(16); + if (w < 0x4000000) { + carry = 0; + } else { + carry = w / 0x4000000 | 0; + } + } -var getEventTarget = __webpack_require__(52); + return ws; + }; -/** - * @interface UIEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var UIEventInterface = { - view: function (event) { - if (event.view) { - return event.view; - } + FFTM.prototype.convert13b = function convert13b (ws, len, rws, N) { + var carry = 0; + for (var i = 0; i < len; i++) { + carry = carry + (ws[i] | 0); - var target = getEventTarget(event); - if (target.window === target) { - // target is a window object - return target; + rws[2 * i] = carry & 0x1fff; carry = carry >>> 13; + rws[2 * i + 1] = carry & 0x1fff; carry = carry >>> 13; } - var doc = target.ownerDocument; - // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. - if (doc) { - return doc.defaultView || doc.parentWindow; - } else { - return window; + // Pad with zeroes + for (i = 2 * len; i < N; ++i) { + rws[i] = 0; } - }, - detail: function (event) { - return event.detail || 0; - } -}; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticUIEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} + assert(carry === 0); + assert((carry & ~0x1fff) === 0); + }; -SyntheticEvent.augmentClass(SyntheticUIEvent, UIEventInterface); + FFTM.prototype.stub = function stub (N) { + var ph = new Array(N); + for (var i = 0; i < N; i++) { + ph[i] = 0; + } -module.exports = SyntheticUIEvent; + return ph; + }; -/***/ }), -/* 34 */ -/***/ (function(module, exports, __webpack_require__) { + FFTM.prototype.mulp = function mulp (x, y, out) { + var N = 2 * this.guessLen13b(x.length, y.length); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var rbt = this.makeRBT(N); + var _ = this.stub(N); + var rws = new Array(N); + var rwst = new Array(N); + var iwst = new Array(N); -/** - * `ReactInstanceMap` maintains a mapping from a public facing stateful - * instance (key) and the internal representation (value). This allows public - * methods to accept the user facing instance as an argument and map them back - * to internal methods. - */ + var nrws = new Array(N); + var nrwst = new Array(N); + var niwst = new Array(N); -// TODO: Replace this with ES6: var ReactInstanceMap = new Map(); + var rmws = out.words; + rmws.length = N; -var ReactInstanceMap = { - /** - * This API should be called `delete` but we'd have to make sure to always - * transform these to strings for IE support. When this transform is fully - * supported we can rename it. - */ - remove: function (key) { - key._reactInternalInstance = undefined; - }, + this.convert13b(x.words, x.length, rws, N); + this.convert13b(y.words, y.length, nrws, N); - get: function (key) { - return key._reactInternalInstance; - }, + this.transform(rws, _, rwst, iwst, N, rbt); + this.transform(nrws, _, nrwst, niwst, N, rbt); - has: function (key) { - return key._reactInternalInstance !== undefined; - }, + for (var i = 0; i < N; i++) { + var rx = rwst[i] * nrwst[i] - iwst[i] * niwst[i]; + iwst[i] = rwst[i] * niwst[i] + iwst[i] * nrwst[i]; + rwst[i] = rx; + } - set: function (key, value) { - key._reactInternalInstance = value; - } -}; + this.conjugate(rwst, iwst, N); + this.transform(rwst, iwst, rmws, _, N, rbt); + this.conjugate(rmws, _, N); + this.normalize13b(rmws, N); -module.exports = ReactInstanceMap; + out.negative = x.negative ^ y.negative; + out.length = x.length + y.length; + return out.strip(); + }; -/***/ }), -/* 35 */, -/* 36 */, -/* 37 */, -/* 38 */ -/***/ (function(module, exports, __webpack_require__) { + // Multiply `this` by `num` + BN.prototype.mul = function mul (num) { + var out = new BN(null); + out.words = new Array(this.length + num.length); + return this.mulTo(num, out); + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + // Multiply employing FFT + BN.prototype.mulf = function mulf (num) { + var out = new BN(null); + out.words = new Array(this.length + num.length); + return jumboMulTo(this, num, out); + }; + // In-place Multiplication + BN.prototype.imul = function imul (num) { + return this.clone().mulTo(num, this); + }; + BN.prototype.imuln = function imuln (num) { + assert(typeof num === 'number'); + assert(num < 0x4000000); -var canDefineProperty = false; -if (process.env.NODE_ENV !== 'production') { - try { - // $FlowFixMe https://github.com/facebook/flow/issues/285 - Object.defineProperty({}, 'x', { get: function () {} }); - canDefineProperty = true; - } catch (x) { - // IE will fail on defineProperty - } -} + // Carry + var carry = 0; + for (var i = 0; i < this.length; i++) { + var w = (this.words[i] | 0) * num; + var lo = (w & 0x3ffffff) + (carry & 0x3ffffff); + carry >>= 26; + carry += (w / 0x4000000) | 0; + // NOTE: lo is 27bit maximum + carry += lo >>> 26; + this.words[i] = lo & 0x3ffffff; + } -module.exports = canDefineProperty; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + if (carry !== 0) { + this.words[i] = carry; + this.length++; + } -/***/ }), -/* 39 */ -/***/ (function(module, exports, __webpack_require__) { + return this; + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.muln = function muln (num) { + return this.clone().imuln(num); + }; + // `this` * `this` + BN.prototype.sqr = function sqr () { + return this.mul(this); + }; + // `this` * `this` in-place + BN.prototype.isqr = function isqr () { + return this.imul(this.clone()); + }; -var emptyObject = {}; + // Math.pow(`this`, `num`) + BN.prototype.pow = function pow (num) { + var w = toBitArray(num); + if (w.length === 0) return new BN(1); -if (process.env.NODE_ENV !== 'production') { - Object.freeze(emptyObject); -} + // Skip leading zeroes + var res = this; + for (var i = 0; i < w.length; i++, res = res.sqr()) { + if (w[i] !== 0) break; + } -module.exports = emptyObject; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + if (++i < w.length) { + for (var q = res.sqr(); i < w.length; i++, q = q.sqr()) { + if (w[i] === 0) continue; -/***/ }), -/* 40 */ -/***/ (function(module, exports, __webpack_require__) { + res = res.mul(q); + } + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + return res; + }; + // Shift-left in-place + BN.prototype.iushln = function iushln (bits) { + assert(typeof bits === 'number' && bits >= 0); + var r = bits % 26; + var s = (bits - r) / 26; + var carryMask = (0x3ffffff >>> (26 - r)) << (26 - r); + var i; + + if (r !== 0) { + var carry = 0; + + for (i = 0; i < this.length; i++) { + var newCarry = this.words[i] & carryMask; + var c = ((this.words[i] | 0) - newCarry) << r; + this.words[i] = c | carry; + carry = newCarry >>> (26 - r); + } + if (carry) { + this.words[i] = carry; + this.length++; + } + } -var _prodInvariant = __webpack_require__(3); + if (s !== 0) { + for (i = this.length - 1; i >= 0; i--) { + this.words[i + s] = this.words[i]; + } -var invariant = __webpack_require__(1); + for (i = 0; i < s; i++) { + this.words[i] = 0; + } -/** - * Injectable ordering of event plugins. - */ -var eventPluginOrder = null; + this.length += s; + } -/** - * Injectable mapping from names to event plugin modules. - */ -var namesToPlugins = {}; + return this.strip(); + }; -/** - * Recomputes the plugin list using the injected plugins and plugin ordering. - * - * @private - */ -function recomputePluginOrdering() { - if (!eventPluginOrder) { - // Wait until an `eventPluginOrder` is injected. - return; - } - for (var pluginName in namesToPlugins) { - var pluginModule = namesToPlugins[pluginName]; - var pluginIndex = eventPluginOrder.indexOf(pluginName); - !(pluginIndex > -1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugins that do not exist in the plugin ordering, `%s`.', pluginName) : _prodInvariant('96', pluginName) : void 0; - if (EventPluginRegistry.plugins[pluginIndex]) { - continue; - } - !pluginModule.extractEvents ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Event plugins must implement an `extractEvents` method, but `%s` does not.', pluginName) : _prodInvariant('97', pluginName) : void 0; - EventPluginRegistry.plugins[pluginIndex] = pluginModule; - var publishedEvents = pluginModule.eventTypes; - for (var eventName in publishedEvents) { - !publishEventForPlugin(publishedEvents[eventName], pluginModule, eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Failed to publish event `%s` for plugin `%s`.', eventName, pluginName) : _prodInvariant('98', eventName, pluginName) : void 0; + BN.prototype.ishln = function ishln (bits) { + // TODO(indutny): implement me + assert(this.negative === 0); + return this.iushln(bits); + }; + + // Shift-right in-place + // NOTE: `hint` is a lowest bit before trailing zeroes + // NOTE: if `extended` is present - it will be filled with destroyed bits + BN.prototype.iushrn = function iushrn (bits, hint, extended) { + assert(typeof bits === 'number' && bits >= 0); + var h; + if (hint) { + h = (hint - (hint % 26)) / 26; + } else { + h = 0; } - } -} -/** - * Publishes an event so that it can be dispatched by the supplied plugin. - * - * @param {object} dispatchConfig Dispatch configuration for the event. - * @param {object} PluginModule Plugin publishing the event. - * @return {boolean} True if the event was successfully published. - * @private - */ -function publishEventForPlugin(dispatchConfig, pluginModule, eventName) { - !!EventPluginRegistry.eventNameDispatchConfigs.hasOwnProperty(eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same event name, `%s`.', eventName) : _prodInvariant('99', eventName) : void 0; - EventPluginRegistry.eventNameDispatchConfigs[eventName] = dispatchConfig; + var r = bits % 26; + var s = Math.min((bits - r) / 26, this.length); + var mask = 0x3ffffff ^ ((0x3ffffff >>> r) << r); + var maskedWords = extended; - var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; - if (phasedRegistrationNames) { - for (var phaseName in phasedRegistrationNames) { - if (phasedRegistrationNames.hasOwnProperty(phaseName)) { - var phasedRegistrationName = phasedRegistrationNames[phaseName]; - publishRegistrationName(phasedRegistrationName, pluginModule, eventName); + h -= s; + h = Math.max(0, h); + + // Extended mode, copy masked part + if (maskedWords) { + for (var i = 0; i < s; i++) { + maskedWords.words[i] = this.words[i]; } + maskedWords.length = s; } - return true; - } else if (dispatchConfig.registrationName) { - publishRegistrationName(dispatchConfig.registrationName, pluginModule, eventName); - return true; - } - return false; -} -/** - * Publishes a registration name that is used to identify dispatched events and - * can be used with `EventPluginHub.putListener` to register listeners. - * - * @param {string} registrationName Registration name to add. - * @param {object} PluginModule Plugin publishing the event. - * @private - */ -function publishRegistrationName(registrationName, pluginModule, eventName) { - !!EventPluginRegistry.registrationNameModules[registrationName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same registration name, `%s`.', registrationName) : _prodInvariant('100', registrationName) : void 0; - EventPluginRegistry.registrationNameModules[registrationName] = pluginModule; - EventPluginRegistry.registrationNameDependencies[registrationName] = pluginModule.eventTypes[eventName].dependencies; + if (s === 0) { + // No-op, we should not move anything at all + } else if (this.length > s) { + this.length -= s; + for (i = 0; i < this.length; i++) { + this.words[i] = this.words[i + s]; + } + } else { + this.words[0] = 0; + this.length = 1; + } - if (process.env.NODE_ENV !== 'production') { - var lowerCasedName = registrationName.toLowerCase(); - EventPluginRegistry.possibleRegistrationNames[lowerCasedName] = registrationName; + var carry = 0; + for (i = this.length - 1; i >= 0 && (carry !== 0 || i >= h); i--) { + var word = this.words[i] | 0; + this.words[i] = (carry << (26 - r)) | (word >>> r); + carry = word & mask; + } - if (registrationName === 'onDoubleClick') { - EventPluginRegistry.possibleRegistrationNames.ondblclick = registrationName; + // Push carried bits as a mask + if (maskedWords && carry !== 0) { + maskedWords.words[maskedWords.length++] = carry; } - } -} -/** - * Registers plugins so that they can extract and dispatch events. - * - * @see {EventPluginHub} - */ -var EventPluginRegistry = { - /** - * Ordered list of injected plugins. - */ - plugins: [], + if (this.length === 0) { + this.words[0] = 0; + this.length = 1; + } - /** - * Mapping from event name to dispatch config - */ - eventNameDispatchConfigs: {}, + return this.strip(); + }; - /** - * Mapping from registration name to plugin module - */ - registrationNameModules: {}, + BN.prototype.ishrn = function ishrn (bits, hint, extended) { + // TODO(indutny): implement me + assert(this.negative === 0); + return this.iushrn(bits, hint, extended); + }; - /** - * Mapping from registration name to event name - */ - registrationNameDependencies: {}, + // Shift-left + BN.prototype.shln = function shln (bits) { + return this.clone().ishln(bits); + }; - /** - * Mapping from lowercase registration names to the properly cased version, - * used to warn in the case of missing event handlers. Available - * only in __DEV__. - * @type {Object} - */ - possibleRegistrationNames: process.env.NODE_ENV !== 'production' ? {} : null, - // Trust the developer to only use possibleRegistrationNames in __DEV__ + BN.prototype.ushln = function ushln (bits) { + return this.clone().iushln(bits); + }; - /** - * Injects an ordering of plugins (by plugin name). This allows the ordering - * to be decoupled from injection of the actual plugins so that ordering is - * always deterministic regardless of packaging, on-the-fly injection, etc. - * - * @param {array} InjectedEventPluginOrder - * @internal - * @see {EventPluginHub.injection.injectEventPluginOrder} - */ - injectEventPluginOrder: function (injectedEventPluginOrder) { - !!eventPluginOrder ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugin ordering more than once. You are likely trying to load more than one copy of React.') : _prodInvariant('101') : void 0; - // Clone the ordering so it cannot be dynamically mutated. - eventPluginOrder = Array.prototype.slice.call(injectedEventPluginOrder); - recomputePluginOrdering(); - }, + // Shift-right + BN.prototype.shrn = function shrn (bits) { + return this.clone().ishrn(bits); + }; - /** - * Injects plugins to be used by `EventPluginHub`. The plugin names must be - * in the ordering injected by `injectEventPluginOrder`. - * - * Plugins can be injected as part of page initialization or on-the-fly. - * - * @param {object} injectedNamesToPlugins Map from names to plugin modules. - * @internal - * @see {EventPluginHub.injection.injectEventPluginsByName} - */ - injectEventPluginsByName: function (injectedNamesToPlugins) { - var isOrderingDirty = false; - for (var pluginName in injectedNamesToPlugins) { - if (!injectedNamesToPlugins.hasOwnProperty(pluginName)) { - continue; - } - var pluginModule = injectedNamesToPlugins[pluginName]; - if (!namesToPlugins.hasOwnProperty(pluginName) || namesToPlugins[pluginName] !== pluginModule) { - !!namesToPlugins[pluginName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject two different event plugins using the same name, `%s`.', pluginName) : _prodInvariant('102', pluginName) : void 0; - namesToPlugins[pluginName] = pluginModule; - isOrderingDirty = true; - } - } - if (isOrderingDirty) { - recomputePluginOrdering(); + BN.prototype.ushrn = function ushrn (bits) { + return this.clone().iushrn(bits); + }; + + // Test if n bit is set + BN.prototype.testn = function testn (bit) { + assert(typeof bit === 'number' && bit >= 0); + var r = bit % 26; + var s = (bit - r) / 26; + var q = 1 << r; + + // Fast case: bit is much higher than all existing words + if (this.length <= s) return false; + + // Check bit and return + var w = this.words[s]; + + return !!(w & q); + }; + + // Return only lowers bits of number (in-place) + BN.prototype.imaskn = function imaskn (bits) { + assert(typeof bits === 'number' && bits >= 0); + var r = bits % 26; + var s = (bits - r) / 26; + + assert(this.negative === 0, 'imaskn works only with positive numbers'); + + if (this.length <= s) { + return this; } - }, - /** - * Looks up the plugin for the supplied event. - * - * @param {object} event A synthetic event. - * @return {?object} The plugin that created the supplied event. - * @internal - */ - getPluginModuleForEvent: function (event) { - var dispatchConfig = event.dispatchConfig; - if (dispatchConfig.registrationName) { - return EventPluginRegistry.registrationNameModules[dispatchConfig.registrationName] || null; + if (r !== 0) { + s++; } - if (dispatchConfig.phasedRegistrationNames !== undefined) { - // pulling phasedRegistrationNames out of dispatchConfig helps Flow see - // that it is not undefined. - var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; + this.length = Math.min(s, this.length); - for (var phase in phasedRegistrationNames) { - if (!phasedRegistrationNames.hasOwnProperty(phase)) { - continue; - } - var pluginModule = EventPluginRegistry.registrationNameModules[phasedRegistrationNames[phase]]; - if (pluginModule) { - return pluginModule; - } - } + if (r !== 0) { + var mask = 0x3ffffff ^ ((0x3ffffff >>> r) << r); + this.words[this.length - 1] &= mask; } - return null; - }, - /** - * Exposed for unit testing. - * @private - */ - _resetEventPlugins: function () { - eventPluginOrder = null; - for (var pluginName in namesToPlugins) { - if (namesToPlugins.hasOwnProperty(pluginName)) { - delete namesToPlugins[pluginName]; + return this.strip(); + }; + + // Return only lowers bits of number + BN.prototype.maskn = function maskn (bits) { + return this.clone().imaskn(bits); + }; + + // Add plain number `num` to `this` + BN.prototype.iaddn = function iaddn (num) { + assert(typeof num === 'number'); + assert(num < 0x4000000); + if (num < 0) return this.isubn(-num); + + // Possible sign change + if (this.negative !== 0) { + if (this.length === 1 && (this.words[0] | 0) < num) { + this.words[0] = num - (this.words[0] | 0); + this.negative = 0; + return this; } + + this.negative = 0; + this.isubn(num); + this.negative = 1; + return this; } - EventPluginRegistry.plugins.length = 0; - var eventNameDispatchConfigs = EventPluginRegistry.eventNameDispatchConfigs; - for (var eventName in eventNameDispatchConfigs) { - if (eventNameDispatchConfigs.hasOwnProperty(eventName)) { - delete eventNameDispatchConfigs[eventName]; + // Add without checks + return this._iaddn(num); + }; + + BN.prototype._iaddn = function _iaddn (num) { + this.words[0] += num; + + // Carry + for (var i = 0; i < this.length && this.words[i] >= 0x4000000; i++) { + this.words[i] -= 0x4000000; + if (i === this.length - 1) { + this.words[i + 1] = 1; + } else { + this.words[i + 1]++; } } + this.length = Math.max(this.length, i + 1); - var registrationNameModules = EventPluginRegistry.registrationNameModules; - for (var registrationName in registrationNameModules) { - if (registrationNameModules.hasOwnProperty(registrationName)) { - delete registrationNameModules[registrationName]; - } + return this; + }; + + // Subtract plain number `num` from `this` + BN.prototype.isubn = function isubn (num) { + assert(typeof num === 'number'); + assert(num < 0x4000000); + if (num < 0) return this.iaddn(-num); + + if (this.negative !== 0) { + this.negative = 0; + this.iaddn(num); + this.negative = 1; + return this; } - if (process.env.NODE_ENV !== 'production') { - var possibleRegistrationNames = EventPluginRegistry.possibleRegistrationNames; - for (var lowerCasedName in possibleRegistrationNames) { - if (possibleRegistrationNames.hasOwnProperty(lowerCasedName)) { - delete possibleRegistrationNames[lowerCasedName]; - } + this.words[0] -= num; + + if (this.length === 1 && this.words[0] < 0) { + this.words[0] = -this.words[0]; + this.negative = 1; + } else { + // Carry + for (var i = 0; i < this.length && this.words[i] < 0; i++) { + this.words[i] += 0x4000000; + this.words[i + 1] -= 1; } } - } -}; -module.exports = EventPluginRegistry; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return this.strip(); + }; -/***/ }), -/* 41 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.addn = function addn (num) { + return this.clone().iaddn(num); + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + BN.prototype.subn = function subn (num) { + return this.clone().isubn(num); + }; + BN.prototype.iabs = function iabs () { + this.negative = 0; + return this; + }; -var _prodInvariant = __webpack_require__(3); + BN.prototype.abs = function abs () { + return this.clone().iabs(); + }; -var invariant = __webpack_require__(1); + BN.prototype._ishlnsubmul = function _ishlnsubmul (num, mul, shift) { + var len = num.length + shift; + var i; -var OBSERVED_ERROR = {}; + this._expand(len); -/** - * `Transaction` creates a black box that is able to wrap any method such that - * certain invariants are maintained before and after the method is invoked - * (Even if an exception is thrown while invoking the wrapped method). Whoever - * instantiates a transaction can provide enforcers of the invariants at - * creation time. The `Transaction` class itself will supply one additional - * automatic invariant for you - the invariant that any transaction instance - * should not be run while it is already being run. You would typically create a - * single instance of a `Transaction` for reuse multiple times, that potentially - * is used to wrap several different methods. Wrappers are extremely simple - - * they only require implementing two methods. - * - *
- *                       wrappers (injected at creation time)
- *                                      +        +
- *                                      |        |
- *                    +-----------------|--------|--------------+
- *                    |                 v        |              |
- *                    |      +---------------+   |              |
- *                    |   +--|    wrapper1   |---|----+         |
- *                    |   |  +---------------+   v    |         |
- *                    |   |          +-------------+  |         |
- *                    |   |     +----|   wrapper2  |--------+   |
- *                    |   |     |    +-------------+  |     |   |
- *                    |   |     |                     |     |   |
- *                    |   v     v                     v     v   | wrapper
- *                    | +---+ +---+   +---------+   +---+ +---+ | invariants
- * perform(anyMethod) | |   | |   |   |         |   |   | |   | | maintained
- * +----------------->|-|---|-|---|-->|anyMethod|---|---|-|---|-|-------->
- *                    | |   | |   |   |         |   |   | |   | |
- *                    | |   | |   |   |         |   |   | |   | |
- *                    | |   | |   |   |         |   |   | |   | |
- *                    | +---+ +---+   +---------+   +---+ +---+ |
- *                    |  initialize                    close    |
- *                    +-----------------------------------------+
- * 
- * - * Use cases: - * - Preserving the input selection ranges before/after reconciliation. - * Restoring selection even in the event of an unexpected error. - * - Deactivating events while rearranging the DOM, preventing blurs/focuses, - * while guaranteeing that afterwards, the event system is reactivated. - * - Flushing a queue of collected DOM mutations to the main UI thread after a - * reconciliation takes place in a worker thread. - * - Invoking any collected `componentDidUpdate` callbacks after rendering new - * content. - * - (Future use case): Wrapping particular flushes of the `ReactWorker` queue - * to preserve the `scrollTop` (an automatic scroll aware DOM). - * - (Future use case): Layout calculations before and after DOM updates. - * - * Transactional plugin API: - * - A module that has an `initialize` method that returns any precomputation. - * - and a `close` method that accepts the precomputation. `close` is invoked - * when the wrapped process is completed, or has failed. - * - * @param {Array} transactionWrapper Wrapper modules - * that implement `initialize` and `close`. - * @return {Transaction} Single transaction for reuse in thread. - * - * @class Transaction - */ -var TransactionImpl = { - /** - * Sets up this instance so that it is prepared for collecting metrics. Does - * so such that this setup method may be used on an instance that is already - * initialized, in a way that does not consume additional memory upon reuse. - * That can be useful if you decide to make your subclass of this mixin a - * "PooledClass". - */ - reinitializeTransaction: function () { - this.transactionWrappers = this.getTransactionWrappers(); - if (this.wrapperInitData) { - this.wrapperInitData.length = 0; - } else { - this.wrapperInitData = []; + var w; + var carry = 0; + for (i = 0; i < num.length; i++) { + w = (this.words[i + shift] | 0) + carry; + var right = (num.words[i] | 0) * mul; + w -= right & 0x3ffffff; + carry = (w >> 26) - ((right / 0x4000000) | 0); + this.words[i + shift] = w & 0x3ffffff; + } + for (; i < this.length - shift; i++) { + w = (this.words[i + shift] | 0) + carry; + carry = w >> 26; + this.words[i + shift] = w & 0x3ffffff; } - this._isInTransaction = false; - }, - _isInTransaction: false, + if (carry === 0) return this.strip(); - /** - * @abstract - * @return {Array} Array of transaction wrappers. - */ - getTransactionWrappers: null, + // Subtraction overflow + assert(carry === -1); + carry = 0; + for (i = 0; i < this.length; i++) { + w = -(this.words[i] | 0) + carry; + carry = w >> 26; + this.words[i] = w & 0x3ffffff; + } + this.negative = 1; - isInTransaction: function () { - return !!this._isInTransaction; - }, + return this.strip(); + }; - /* eslint-disable space-before-function-paren */ + BN.prototype._wordDiv = function _wordDiv (num, mode) { + var shift = this.length - num.length; - /** - * Executes the function within a safety window. Use this for the top level - * methods that result in large amounts of computation/mutations that would - * need to be safety checked. The optional arguments helps prevent the need - * to bind in many cases. - * - * @param {function} method Member of scope to call. - * @param {Object} scope Scope to invoke from. - * @param {Object?=} a Argument to pass to the method. - * @param {Object?=} b Argument to pass to the method. - * @param {Object?=} c Argument to pass to the method. - * @param {Object?=} d Argument to pass to the method. - * @param {Object?=} e Argument to pass to the method. - * @param {Object?=} f Argument to pass to the method. - * - * @return {*} Return value from `method`. - */ - perform: function (method, scope, a, b, c, d, e, f) { - /* eslint-enable space-before-function-paren */ - !!this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.perform(...): Cannot initialize a transaction when there is already an outstanding transaction.') : _prodInvariant('27') : void 0; - var errorThrown; - var ret; - try { - this._isInTransaction = true; - // Catching errors makes debugging more difficult, so we start with - // errorThrown set to true before setting it to false after calling - // close -- if it's still set to true in the finally block, it means - // one of these calls threw. - errorThrown = true; - this.initializeAll(0); - ret = method.call(scope, a, b, c, d, e, f); - errorThrown = false; - } finally { - try { - if (errorThrown) { - // If `method` throws, prefer to show that stack trace over any thrown - // by invoking `closeAll`. - try { - this.closeAll(0); - } catch (err) {} - } else { - // Since `method` didn't throw, we don't want to silence the exception - // here. - this.closeAll(0); - } - } finally { - this._isInTransaction = false; + var a = this.clone(); + var b = num; + + // Normalize + var bhi = b.words[b.length - 1] | 0; + var bhiBits = this._countBits(bhi); + shift = 26 - bhiBits; + if (shift !== 0) { + b = b.ushln(shift); + a.iushln(shift); + bhi = b.words[b.length - 1] | 0; + } + + // Initialize quotient + var m = a.length - b.length; + var q; + + if (mode !== 'mod') { + q = new BN(null); + q.length = m + 1; + q.words = new Array(q.length); + for (var i = 0; i < q.length; i++) { + q.words[i] = 0; } } - return ret; - }, - initializeAll: function (startIndex) { - var transactionWrappers = this.transactionWrappers; - for (var i = startIndex; i < transactionWrappers.length; i++) { - var wrapper = transactionWrappers[i]; - try { - // Catching errors makes debugging more difficult, so we start with the - // OBSERVED_ERROR state before overwriting it with the real return value - // of initialize -- if it's still set to OBSERVED_ERROR in the finally - // block, it means wrapper.initialize threw. - this.wrapperInitData[i] = OBSERVED_ERROR; - this.wrapperInitData[i] = wrapper.initialize ? wrapper.initialize.call(this) : null; - } finally { - if (this.wrapperInitData[i] === OBSERVED_ERROR) { - // The initializer for wrapper i threw an error; initialize the - // remaining wrappers but silence any exceptions from them to ensure - // that the first error is the one to bubble up. - try { - this.initializeAll(i + 1); - } catch (err) {} + var diff = a.clone()._ishlnsubmul(b, 1, m); + if (diff.negative === 0) { + a = diff; + if (q) { + q.words[m] = 1; + } + } + + for (var j = m - 1; j >= 0; j--) { + var qj = (a.words[b.length + j] | 0) * 0x4000000 + + (a.words[b.length + j - 1] | 0); + + // NOTE: (qj / bhi) is (0x3ffffff * 0x4000000 + 0x3ffffff) / 0x2000000 max + // (0x7ffffff) + qj = Math.min((qj / bhi) | 0, 0x3ffffff); + + a._ishlnsubmul(b, qj, j); + while (a.negative !== 0) { + qj--; + a.negative = 0; + a._ishlnsubmul(b, 1, j); + if (!a.isZero()) { + a.negative ^= 1; } } + if (q) { + q.words[j] = qj; + } } - }, + if (q) { + q.strip(); + } + a.strip(); - /** - * Invokes each of `this.transactionWrappers.close[i]` functions, passing into - * them the respective return values of `this.transactionWrappers.init[i]` - * (`close`rs that correspond to initializers that failed will not be - * invoked). - */ - closeAll: function (startIndex) { - !this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.closeAll(): Cannot close transaction when none are open.') : _prodInvariant('28') : void 0; - var transactionWrappers = this.transactionWrappers; - for (var i = startIndex; i < transactionWrappers.length; i++) { - var wrapper = transactionWrappers[i]; - var initData = this.wrapperInitData[i]; - var errorThrown; - try { - // Catching errors makes debugging more difficult, so we start with - // errorThrown set to true before setting it to false after calling - // close -- if it's still set to true in the finally block, it means - // wrapper.close threw. - errorThrown = true; - if (initData !== OBSERVED_ERROR && wrapper.close) { - wrapper.close.call(this, initData); + // Denormalize + if (mode !== 'div' && shift !== 0) { + a.iushrn(shift); + } + + return { + div: q || null, + mod: a + }; + }; + + // NOTE: 1) `mode` can be set to `mod` to request mod only, + // to `div` to request div only, or be absent to + // request both div & mod + // 2) `positive` is true if unsigned mod is requested + BN.prototype.divmod = function divmod (num, mode, positive) { + assert(!num.isZero()); + + if (this.isZero()) { + return { + div: new BN(0), + mod: new BN(0) + }; + } + + var div, mod, res; + if (this.negative !== 0 && num.negative === 0) { + res = this.neg().divmod(num, mode); + + if (mode !== 'mod') { + div = res.div.neg(); + } + + if (mode !== 'div') { + mod = res.mod.neg(); + if (positive && mod.negative !== 0) { + mod.iadd(num); } - errorThrown = false; - } finally { - if (errorThrown) { - // The closer for wrapper i threw an error; close the remaining - // wrappers but silence any exceptions from them to ensure that the - // first error is the one to bubble up. - try { - this.closeAll(i + 1); - } catch (e) {} + } + + return { + div: div, + mod: mod + }; + } + + if (this.negative === 0 && num.negative !== 0) { + res = this.divmod(num.neg(), mode); + + if (mode !== 'mod') { + div = res.div.neg(); + } + + return { + div: div, + mod: res.mod + }; + } + + if ((this.negative & num.negative) !== 0) { + res = this.neg().divmod(num.neg(), mode); + + if (mode !== 'div') { + mod = res.mod.neg(); + if (positive && mod.negative !== 0) { + mod.isub(num); } } + + return { + div: res.div, + mod: mod + }; } - this.wrapperInitData.length = 0; - } -}; -module.exports = TransactionImpl; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // Both numbers are positive at this point -/***/ }), -/* 42 */ -/***/ (function(module, exports, __webpack_require__) { + // Strip both numbers to approximate shift value + if (num.length > this.length || this.cmp(num) < 0) { + return { + div: new BN(0), + mod: this + }; + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // Very short reduction + if (num.length === 1) { + if (mode === 'div') { + return { + div: this.divn(num.words[0]), + mod: null + }; + } + if (mode === 'mod') { + return { + div: null, + mod: new BN(this.modn(num.words[0])) + }; + } + return { + div: this.divn(num.words[0]), + mod: new BN(this.modn(num.words[0])) + }; + } -var SyntheticUIEvent = __webpack_require__(33); -var ViewportMetrics = __webpack_require__(89); + return this._wordDiv(num, mode); + }; -var getEventModifierState = __webpack_require__(54); + // Find `this` / `num` + BN.prototype.div = function div (num) { + return this.divmod(num, 'div', false).div; + }; -/** - * @interface MouseEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var MouseEventInterface = { - screenX: null, - screenY: null, - clientX: null, - clientY: null, - ctrlKey: null, - shiftKey: null, - altKey: null, - metaKey: null, - getModifierState: getEventModifierState, - button: function (event) { - // Webkit, Firefox, IE9+ - // which: 1 2 3 - // button: 0 1 2 (standard) - var button = event.button; - if ('which' in event) { - return button; + // Find `this` % `num` + BN.prototype.mod = function mod (num) { + return this.divmod(num, 'mod', false).mod; + }; + + BN.prototype.umod = function umod (num) { + return this.divmod(num, 'mod', true).mod; + }; + + // Find Round(`this` / `num`) + BN.prototype.divRound = function divRound (num) { + var dm = this.divmod(num); + + // Fast case - exact division + if (dm.mod.isZero()) return dm.div; + + var mod = dm.div.negative !== 0 ? dm.mod.isub(num) : dm.mod; + + var half = num.ushrn(1); + var r2 = num.andln(1); + var cmp = mod.cmp(half); + + // Round down + if (cmp < 0 || r2 === 1 && cmp === 0) return dm.div; + + // Round up + return dm.div.negative !== 0 ? dm.div.isubn(1) : dm.div.iaddn(1); + }; + + BN.prototype.modn = function modn (num) { + assert(num <= 0x3ffffff); + var p = (1 << 26) % num; + + var acc = 0; + for (var i = this.length - 1; i >= 0; i--) { + acc = (p * acc + (this.words[i] | 0)) % num; } - // IE<9 - // which: undefined - // button: 0 0 0 - // button: 1 4 2 (onmouseup) - return button === 2 ? 2 : button === 4 ? 1 : 0; - }, - buttons: null, - relatedTarget: function (event) { - return event.relatedTarget || (event.fromElement === event.srcElement ? event.toElement : event.fromElement); - }, - // "Proprietary" Interface. - pageX: function (event) { - return 'pageX' in event ? event.pageX : event.clientX + ViewportMetrics.currentScrollLeft; - }, - pageY: function (event) { - return 'pageY' in event ? event.pageY : event.clientY + ViewportMetrics.currentScrollTop; - } -}; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticMouseEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} + return acc; + }; -SyntheticUIEvent.augmentClass(SyntheticMouseEvent, MouseEventInterface); + // In-place division by number + BN.prototype.idivn = function idivn (num) { + assert(num <= 0x3ffffff); -module.exports = SyntheticMouseEvent; + var carry = 0; + for (var i = this.length - 1; i >= 0; i--) { + var w = (this.words[i] | 0) + carry * 0x4000000; + this.words[i] = (w / num) | 0; + carry = w % num; + } -/***/ }), -/* 43 */ -/***/ (function(module, exports, __webpack_require__) { + return this.strip(); + }; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.divn = function divn (num) { + return this.clone().idivn(num); + }; + BN.prototype.egcd = function egcd (p) { + assert(p.negative === 0); + assert(!p.isZero()); + var x = this; + var y = p.clone(); -var ExecutionEnvironment = __webpack_require__(8); -var DOMNamespaces = __webpack_require__(56); + if (x.negative !== 0) { + x = x.umod(p); + } else { + x = x.clone(); + } -var WHITESPACE_TEST = /^[ \r\n\t\f]/; -var NONVISIBLE_TEST = /<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/; + // A * x + B * y = x + var A = new BN(1); + var B = new BN(0); -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); + // C * x + D * y = y + var C = new BN(0); + var D = new BN(1); -// SVG temp container for IE lacking innerHTML -var reusableSVGContainer; + var g = 0; -/** - * Set the innerHTML property of a node, ensuring that whitespace is preserved - * even in IE8. - * - * @param {DOMElement} node - * @param {string} html - * @internal - */ -var setInnerHTML = createMicrosoftUnsafeLocalFunction(function (node, html) { - // IE does not have innerHTML for SVG nodes, so instead we inject the - // new markup in a temp node and then move the child nodes across into - // the target node - if (node.namespaceURI === DOMNamespaces.svg && !('innerHTML' in node)) { - reusableSVGContainer = reusableSVGContainer || document.createElement('div'); - reusableSVGContainer.innerHTML = '' + html + ''; - var svgNode = reusableSVGContainer.firstChild; - while (svgNode.firstChild) { - node.appendChild(svgNode.firstChild); + while (x.isEven() && y.isEven()) { + x.iushrn(1); + y.iushrn(1); + ++g; } - } else { - node.innerHTML = html; - } -}); -if (ExecutionEnvironment.canUseDOM) { - // IE8: When updating a just created node with innerHTML only leading - // whitespace is removed. When updating an existing node with innerHTML - // whitespace in root TextNodes is also collapsed. - // @see quirksmode.org/bugreports/archives/2004/11/innerhtml_and_t.html + var yp = y.clone(); + var xp = x.clone(); - // Feature detection; only IE8 is known to behave improperly like this. - var testElement = document.createElement('div'); - testElement.innerHTML = ' '; - if (testElement.innerHTML === '') { - setInnerHTML = function (node, html) { - // Magic theory: IE8 supposedly differentiates between added and updated - // nodes when processing innerHTML, innerHTML on updated nodes suffers - // from worse whitespace behavior. Re-adding a node like this triggers - // the initial and more favorable whitespace behavior. - // TODO: What to do on a detached node? - if (node.parentNode) { - node.parentNode.replaceChild(node, node); + while (!x.isZero()) { + for (var i = 0, im = 1; (x.words[0] & im) === 0 && i < 26; ++i, im <<= 1); + if (i > 0) { + x.iushrn(i); + while (i-- > 0) { + if (A.isOdd() || B.isOdd()) { + A.iadd(yp); + B.isub(xp); + } + + A.iushrn(1); + B.iushrn(1); + } } - // We also implement a workaround for non-visible tags disappearing into - // thin air on IE8, this only happens if there is no visible text - // in-front of the non-visible tags. Piggyback on the whitespace fix - // and simply check if any non-visible tags appear in the source. - if (WHITESPACE_TEST.test(html) || html[0] === '<' && NONVISIBLE_TEST.test(html)) { - // Recover leading whitespace by temporarily prepending any character. - // \uFEFF has the potential advantage of being zero-width/invisible. - // UglifyJS drops U+FEFF chars when parsing, so use String.fromCharCode - // in hopes that this is preserved even if "\uFEFF" is transformed to - // the actual Unicode character (by Babel, for example). - // https://github.com/mishoo/UglifyJS2/blob/v2.4.20/lib/parse.js#L216 - node.innerHTML = String.fromCharCode(0xfeff) + html; + for (var j = 0, jm = 1; (y.words[0] & jm) === 0 && j < 26; ++j, jm <<= 1); + if (j > 0) { + y.iushrn(j); + while (j-- > 0) { + if (C.isOdd() || D.isOdd()) { + C.iadd(yp); + D.isub(xp); + } - // deleteData leaves an empty `TextNode` which offsets the index of all - // children. Definitely want to avoid this. - var textNode = node.firstChild; - if (textNode.data.length === 1) { - node.removeChild(textNode); - } else { - textNode.deleteData(0, 1); + C.iushrn(1); + D.iushrn(1); } + } + + if (x.cmp(y) >= 0) { + x.isub(y); + A.isub(C); + B.isub(D); } else { - node.innerHTML = html; + y.isub(x); + C.isub(A); + D.isub(B); } + } + + return { + a: C, + b: D, + gcd: y.iushln(g) }; - } - testElement = null; -} + }; -module.exports = setInnerHTML; + // This is reduced incarnation of the binary EEA + // above, designated to invert members of the + // _prime_ fields F(p) at a maximal speed + BN.prototype._invmp = function _invmp (p) { + assert(p.negative === 0); + assert(!p.isZero()); -/***/ }), -/* 44 */ -/***/ (function(module, exports, __webpack_require__) { + var a = this; + var b = p.clone(); -"use strict"; -/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * Based on the escape-html library, which is used under the MIT License below: - * - * Copyright (c) 2012-2013 TJ Holowaychuk - * Copyright (c) 2015 Andreas Lubbe - * Copyright (c) 2015 Tiancheng "Timothy" Gu - * - * Permission is hereby granted, free of charge, to any person obtaining - * a copy of this software and associated documentation files (the - * 'Software'), to deal in the Software without restriction, including - * without limitation the rights to use, copy, modify, merge, publish, - * distribute, sublicense, and/or sell copies of the Software, and to - * permit persons to whom the Software is furnished to do so, subject to - * the following conditions: - * - * The above copyright notice and this permission notice shall be - * included in all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, - * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. - * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY - * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, - * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE - * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - * - */ + if (a.negative !== 0) { + a = a.umod(p); + } else { + a = a.clone(); + } + var x1 = new BN(1); + var x2 = new BN(0); + var delta = b.clone(); -// code copied and modified from escape-html -/** - * Module variables. - * @private - */ + while (a.cmpn(1) > 0 && b.cmpn(1) > 0) { + for (var i = 0, im = 1; (a.words[0] & im) === 0 && i < 26; ++i, im <<= 1); + if (i > 0) { + a.iushrn(i); + while (i-- > 0) { + if (x1.isOdd()) { + x1.iadd(delta); + } -var matchHtmlRegExp = /["'&<>]/; + x1.iushrn(1); + } + } -/** - * Escape special characters in the given string of html. - * - * @param {string} string The string to escape for inserting into HTML - * @return {string} - * @public - */ + for (var j = 0, jm = 1; (b.words[0] & jm) === 0 && j < 26; ++j, jm <<= 1); + if (j > 0) { + b.iushrn(j); + while (j-- > 0) { + if (x2.isOdd()) { + x2.iadd(delta); + } -function escapeHtml(string) { - var str = '' + string; - var match = matchHtmlRegExp.exec(str); + x2.iushrn(1); + } + } - if (!match) { - return str; - } + if (a.cmp(b) >= 0) { + a.isub(b); + x1.isub(x2); + } else { + b.isub(a); + x2.isub(x1); + } + } - var escape; - var html = ''; - var index = 0; - var lastIndex = 0; + var res; + if (a.cmpn(1) === 0) { + res = x1; + } else { + res = x2; + } - for (index = match.index; index < str.length; index++) { - switch (str.charCodeAt(index)) { - case 34: - // " - escape = '"'; - break; - case 38: - // & - escape = '&'; - break; - case 39: - // ' - escape = '''; // modified from escape-html; used to be ''' - break; - case 60: - // < - escape = '<'; - break; - case 62: - // > - escape = '>'; + if (res.cmpn(0) < 0) { + res.iadd(p); + } + + return res; + }; + + BN.prototype.gcd = function gcd (num) { + if (this.isZero()) return num.abs(); + if (num.isZero()) return this.abs(); + + var a = this.clone(); + var b = num.clone(); + a.negative = 0; + b.negative = 0; + + // Remove common factor of two + for (var shift = 0; a.isEven() && b.isEven(); shift++) { + a.iushrn(1); + b.iushrn(1); + } + + do { + while (a.isEven()) { + a.iushrn(1); + } + while (b.isEven()) { + b.iushrn(1); + } + + var r = a.cmp(b); + if (r < 0) { + // Swap `a` and `b` to make `a` always bigger than `b` + var t = a; + a = b; + b = t; + } else if (r === 0 || b.cmpn(1) === 0) { break; - default: - continue; + } + + a.isub(b); + } while (true); + + return b.iushln(shift); + }; + + // Invert number in the field F(num) + BN.prototype.invm = function invm (num) { + return this.egcd(num).a.umod(num); + }; + + BN.prototype.isEven = function isEven () { + return (this.words[0] & 1) === 0; + }; + + BN.prototype.isOdd = function isOdd () { + return (this.words[0] & 1) === 1; + }; + + // And first word and num + BN.prototype.andln = function andln (num) { + return this.words[0] & num; + }; + + // Increment at the bit position in-line + BN.prototype.bincn = function bincn (bit) { + assert(typeof bit === 'number'); + var r = bit % 26; + var s = (bit - r) / 26; + var q = 1 << r; + + // Fast case: bit is much higher than all existing words + if (this.length <= s) { + this._expand(s + 1); + this.words[s] |= q; + return this; + } + + // Add bit and propagate, if needed + var carry = q; + for (var i = s; carry !== 0 && i < this.length; i++) { + var w = this.words[i] | 0; + w += carry; + carry = w >>> 26; + w &= 0x3ffffff; + this.words[i] = w; + } + if (carry !== 0) { + this.words[i] = carry; + this.length++; + } + return this; + }; + + BN.prototype.isZero = function isZero () { + return this.length === 1 && this.words[0] === 0; + }; + + BN.prototype.cmpn = function cmpn (num) { + var negative = num < 0; + + if (this.negative !== 0 && !negative) return -1; + if (this.negative === 0 && negative) return 1; + + this.strip(); + + var res; + if (this.length > 1) { + res = 1; + } else { + if (negative) { + num = -num; + } + + assert(num <= 0x3ffffff, 'Number is too big'); + + var w = this.words[0] | 0; + res = w === num ? 0 : w < num ? -1 : 1; } + if (this.negative !== 0) return -res | 0; + return res; + }; - if (lastIndex !== index) { - html += str.substring(lastIndex, index); + // Compare two numbers and return: + // 1 - if `this` > `num` + // 0 - if `this` == `num` + // -1 - if `this` < `num` + BN.prototype.cmp = function cmp (num) { + if (this.negative !== 0 && num.negative === 0) return -1; + if (this.negative === 0 && num.negative !== 0) return 1; + + var res = this.ucmp(num); + if (this.negative !== 0) return -res | 0; + return res; + }; + + // Unsigned comparison + BN.prototype.ucmp = function ucmp (num) { + // At this point both numbers have the same sign + if (this.length > num.length) return 1; + if (this.length < num.length) return -1; + + var res = 0; + for (var i = this.length - 1; i >= 0; i--) { + var a = this.words[i] | 0; + var b = num.words[i] | 0; + + if (a === b) continue; + if (a < b) { + res = -1; + } else if (a > b) { + res = 1; + } + break; } + return res; + }; - lastIndex = index + 1; - html += escape; - } + BN.prototype.gtn = function gtn (num) { + return this.cmpn(num) === 1; + }; - return lastIndex !== index ? html + str.substring(lastIndex, index) : html; -} -// end code copied and modified from escape-html + BN.prototype.gt = function gt (num) { + return this.cmp(num) === 1; + }; -/** - * Escapes text to prevent scripting attacks. - * - * @param {*} text Text value to escape. - * @return {string} An escaped string. - */ -function escapeTextContentForBrowser(text) { - if (typeof text === 'boolean' || typeof text === 'number') { - // this shortcircuit helps perf for types that we know will never have - // special characters, especially given that this function is used often - // for numeric dom ids. - return '' + text; - } - return escapeHtml(text); -} + BN.prototype.gten = function gten (num) { + return this.cmpn(num) >= 0; + }; -module.exports = escapeTextContentForBrowser; + BN.prototype.gte = function gte (num) { + return this.cmp(num) >= 0; + }; -/***/ }), -/* 45 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.ltn = function ltn (num) { + return this.cmpn(num) === -1; + }; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.lt = function lt (num) { + return this.cmp(num) === -1; + }; + BN.prototype.lten = function lten (num) { + return this.cmpn(num) <= 0; + }; + BN.prototype.lte = function lte (num) { + return this.cmp(num) <= 0; + }; -var _assign = __webpack_require__(5); + BN.prototype.eqn = function eqn (num) { + return this.cmpn(num) === 0; + }; -var EventPluginRegistry = __webpack_require__(40); -var ReactEventEmitterMixin = __webpack_require__(169); -var ViewportMetrics = __webpack_require__(89); + BN.prototype.eq = function eq (num) { + return this.cmp(num) === 0; + }; -var getVendorPrefixedEventName = __webpack_require__(170); -var isEventSupported = __webpack_require__(53); + // + // A reduce context, could be using montgomery or something better, depending + // on the `m` itself. + // + BN.red = function red (num) { + return new Red(num); + }; -/** - * Summary of `ReactBrowserEventEmitter` event handling: - * - * - Top-level delegation is used to trap most native browser events. This - * may only occur in the main thread and is the responsibility of - * ReactEventListener, which is injected and can therefore support pluggable - * event sources. This is the only work that occurs in the main thread. - * - * - We normalize and de-duplicate events to account for browser quirks. This - * may be done in the worker thread. - * - * - Forward these native events (with the associated top-level type used to - * trap it) to `EventPluginHub`, which in turn will ask plugins if they want - * to extract any synthetic events. - * - * - The `EventPluginHub` will then process each event by annotating them with - * "dispatches", a sequence of listeners and IDs that care about that event. - * - * - The `EventPluginHub` then dispatches the events. - * - * Overview of React and the event system: - * - * +------------+ . - * | DOM | . - * +------------+ . - * | . - * v . - * +------------+ . - * | ReactEvent | . - * | Listener | . - * +------------+ . +-----------+ - * | . +--------+|SimpleEvent| - * | . | |Plugin | - * +-----|------+ . v +-----------+ - * | | | . +--------------+ +------------+ - * | +-----------.--->|EventPluginHub| | Event | - * | | . | | +-----------+ | Propagators| - * | ReactEvent | . | | |TapEvent | |------------| - * | Emitter | . | |<---+|Plugin | |other plugin| - * | | . | | +-----------+ | utilities | - * | +-----------.--->| | +------------+ - * | | | . +--------------+ - * +-----|------+ . ^ +-----------+ - * | . | |Enter/Leave| - * + . +-------+|Plugin | - * +-------------+ . +-----------+ - * | application | . - * |-------------| . - * | | . - * | | . - * +-------------+ . - * . - * React Core . General Purpose Event Plugin System - */ + BN.prototype.toRed = function toRed (ctx) { + assert(!this.red, 'Already a number in reduction context'); + assert(this.negative === 0, 'red works only with positives'); + return ctx.convertTo(this)._forceRed(ctx); + }; -var hasEventPageXY; -var alreadyListeningTo = {}; -var isMonitoringScrollValue = false; -var reactTopListenersCounter = 0; + BN.prototype.fromRed = function fromRed () { + assert(this.red, 'fromRed works only with numbers in reduction context'); + return this.red.convertFrom(this); + }; -// For events like 'submit' which don't consistently bubble (which we trap at a -// lower node than `document`), binding at `document` would cause duplicate -// events so we don't include them here -var topEventMapping = { - topAbort: 'abort', - topAnimationEnd: getVendorPrefixedEventName('animationend') || 'animationend', - topAnimationIteration: getVendorPrefixedEventName('animationiteration') || 'animationiteration', - topAnimationStart: getVendorPrefixedEventName('animationstart') || 'animationstart', - topBlur: 'blur', - topCanPlay: 'canplay', - topCanPlayThrough: 'canplaythrough', - topChange: 'change', - topClick: 'click', - topCompositionEnd: 'compositionend', - topCompositionStart: 'compositionstart', - topCompositionUpdate: 'compositionupdate', - topContextMenu: 'contextmenu', - topCopy: 'copy', - topCut: 'cut', - topDoubleClick: 'dblclick', - topDrag: 'drag', - topDragEnd: 'dragend', - topDragEnter: 'dragenter', - topDragExit: 'dragexit', - topDragLeave: 'dragleave', - topDragOver: 'dragover', - topDragStart: 'dragstart', - topDrop: 'drop', - topDurationChange: 'durationchange', - topEmptied: 'emptied', - topEncrypted: 'encrypted', - topEnded: 'ended', - topError: 'error', - topFocus: 'focus', - topInput: 'input', - topKeyDown: 'keydown', - topKeyPress: 'keypress', - topKeyUp: 'keyup', - topLoadedData: 'loadeddata', - topLoadedMetadata: 'loadedmetadata', - topLoadStart: 'loadstart', - topMouseDown: 'mousedown', - topMouseMove: 'mousemove', - topMouseOut: 'mouseout', - topMouseOver: 'mouseover', - topMouseUp: 'mouseup', - topPaste: 'paste', - topPause: 'pause', - topPlay: 'play', - topPlaying: 'playing', - topProgress: 'progress', - topRateChange: 'ratechange', - topScroll: 'scroll', - topSeeked: 'seeked', - topSeeking: 'seeking', - topSelectionChange: 'selectionchange', - topStalled: 'stalled', - topSuspend: 'suspend', - topTextInput: 'textInput', - topTimeUpdate: 'timeupdate', - topTouchCancel: 'touchcancel', - topTouchEnd: 'touchend', - topTouchMove: 'touchmove', - topTouchStart: 'touchstart', - topTransitionEnd: getVendorPrefixedEventName('transitionend') || 'transitionend', - topVolumeChange: 'volumechange', - topWaiting: 'waiting', - topWheel: 'wheel' -}; + BN.prototype._forceRed = function _forceRed (ctx) { + this.red = ctx; + return this; + }; -/** - * To ensure no conflicts with other potential React instances on the page - */ -var topListenersIDKey = '_reactListenersID' + String(Math.random()).slice(2); + BN.prototype.forceRed = function forceRed (ctx) { + assert(!this.red, 'Already a number in reduction context'); + return this._forceRed(ctx); + }; -function getListeningForDocument(mountAt) { - // In IE8, `mountAt` is a host object and doesn't have `hasOwnProperty` - // directly. - if (!Object.prototype.hasOwnProperty.call(mountAt, topListenersIDKey)) { - mountAt[topListenersIDKey] = reactTopListenersCounter++; - alreadyListeningTo[mountAt[topListenersIDKey]] = {}; + BN.prototype.redAdd = function redAdd (num) { + assert(this.red, 'redAdd works only with red numbers'); + return this.red.add(this, num); + }; + + BN.prototype.redIAdd = function redIAdd (num) { + assert(this.red, 'redIAdd works only with red numbers'); + return this.red.iadd(this, num); + }; + + BN.prototype.redSub = function redSub (num) { + assert(this.red, 'redSub works only with red numbers'); + return this.red.sub(this, num); + }; + + BN.prototype.redISub = function redISub (num) { + assert(this.red, 'redISub works only with red numbers'); + return this.red.isub(this, num); + }; + + BN.prototype.redShl = function redShl (num) { + assert(this.red, 'redShl works only with red numbers'); + return this.red.shl(this, num); + }; + + BN.prototype.redMul = function redMul (num) { + assert(this.red, 'redMul works only with red numbers'); + this.red._verify2(this, num); + return this.red.mul(this, num); + }; + + BN.prototype.redIMul = function redIMul (num) { + assert(this.red, 'redMul works only with red numbers'); + this.red._verify2(this, num); + return this.red.imul(this, num); + }; + + BN.prototype.redSqr = function redSqr () { + assert(this.red, 'redSqr works only with red numbers'); + this.red._verify1(this); + return this.red.sqr(this); + }; + + BN.prototype.redISqr = function redISqr () { + assert(this.red, 'redISqr works only with red numbers'); + this.red._verify1(this); + return this.red.isqr(this); + }; + + // Square root over p + BN.prototype.redSqrt = function redSqrt () { + assert(this.red, 'redSqrt works only with red numbers'); + this.red._verify1(this); + return this.red.sqrt(this); + }; + + BN.prototype.redInvm = function redInvm () { + assert(this.red, 'redInvm works only with red numbers'); + this.red._verify1(this); + return this.red.invm(this); + }; + + // Return negative clone of `this` % `red modulo` + BN.prototype.redNeg = function redNeg () { + assert(this.red, 'redNeg works only with red numbers'); + this.red._verify1(this); + return this.red.neg(this); + }; + + BN.prototype.redPow = function redPow (num) { + assert(this.red && !num.red, 'redPow(normalNum)'); + this.red._verify1(this); + return this.red.pow(this, num); + }; + + // Prime numbers with efficient reduction + var primes = { + k256: null, + p224: null, + p192: null, + p25519: null + }; + + // Pseudo-Mersenne prime + function MPrime (name, p) { + // P = 2 ^ N - K + this.name = name; + this.p = new BN(p, 16); + this.n = this.p.bitLength(); + this.k = new BN(1).iushln(this.n).isub(this.p); + + this.tmp = this._tmp(); } - return alreadyListeningTo[mountAt[topListenersIDKey]]; -} -/** - * `ReactBrowserEventEmitter` is used to attach top-level event listeners. For - * example: - * - * EventPluginHub.putListener('myID', 'onClick', myFunction); - * - * This would allocate a "registration" of `('onClick', myFunction)` on 'myID'. - * - * @internal - */ -var ReactBrowserEventEmitter = _assign({}, ReactEventEmitterMixin, { - /** - * Injectable event backend - */ - ReactEventListener: null, + MPrime.prototype._tmp = function _tmp () { + var tmp = new BN(null); + tmp.words = new Array(Math.ceil(this.n / 13)); + return tmp; + }; - injection: { - /** - * @param {object} ReactEventListener - */ - injectReactEventListener: function (ReactEventListener) { - ReactEventListener.setHandleTopLevel(ReactBrowserEventEmitter.handleTopLevel); - ReactBrowserEventEmitter.ReactEventListener = ReactEventListener; - } - }, + MPrime.prototype.ireduce = function ireduce (num) { + // Assumes that `num` is less than `P^2` + // num = HI * (2 ^ N - K) + HI * K + LO = HI * K + LO (mod P) + var r = num; + var rlen; - /** - * Sets whether or not any created callbacks should be enabled. - * - * @param {boolean} enabled True if callbacks should be enabled. - */ - setEnabled: function (enabled) { - if (ReactBrowserEventEmitter.ReactEventListener) { - ReactBrowserEventEmitter.ReactEventListener.setEnabled(enabled); + do { + this.split(r, this.tmp); + r = this.imulK(r); + r = r.iadd(this.tmp); + rlen = r.bitLength(); + } while (rlen > this.n); + + var cmp = rlen < this.n ? -1 : r.ucmp(this.p); + if (cmp === 0) { + r.words[0] = 0; + r.length = 1; + } else if (cmp > 0) { + r.isub(this.p); + } else { + r.strip(); } - }, - /** - * @return {boolean} True if callbacks are enabled. - */ - isEnabled: function () { - return !!(ReactBrowserEventEmitter.ReactEventListener && ReactBrowserEventEmitter.ReactEventListener.isEnabled()); - }, + return r; + }; - /** - * We listen for bubbled touch events on the document object. - * - * Firefox v8.01 (and possibly others) exhibited strange behavior when - * mounting `onmousemove` events at some node that was not the document - * element. The symptoms were that if your mouse is not moving over something - * contained within that mount point (for example on the background) the - * top-level listeners for `onmousemove` won't be called. However, if you - * register the `mousemove` on the document object, then it will of course - * catch all `mousemove`s. This along with iOS quirks, justifies restricting - * top-level listeners to the document object only, at least for these - * movement types of events and possibly all events. - * - * @see http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html - * - * Also, `keyup`/`keypress`/`keydown` do not bubble to the window on IE, but - * they bubble to document. - * - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @param {object} contentDocumentHandle Document which owns the container - */ - listenTo: function (registrationName, contentDocumentHandle) { - var mountAt = contentDocumentHandle; - var isListening = getListeningForDocument(mountAt); - var dependencies = EventPluginRegistry.registrationNameDependencies[registrationName]; + MPrime.prototype.split = function split (input, out) { + input.iushrn(this.n, 0, out); + }; - for (var i = 0; i < dependencies.length; i++) { - var dependency = dependencies[i]; - if (!(isListening.hasOwnProperty(dependency) && isListening[dependency])) { - if (dependency === 'topWheel') { - if (isEventSupported('wheel')) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'wheel', mountAt); - } else if (isEventSupported('mousewheel')) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'mousewheel', mountAt); - } else { - // Firefox needs to capture a different mouse scroll event. - // @see http://www.quirksmode.org/dom/events/tests/scroll.html - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'DOMMouseScroll', mountAt); - } - } else if (dependency === 'topScroll') { - if (isEventSupported('scroll', true)) { - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topScroll', 'scroll', mountAt); - } else { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topScroll', 'scroll', ReactBrowserEventEmitter.ReactEventListener.WINDOW_HANDLE); - } - } else if (dependency === 'topFocus' || dependency === 'topBlur') { - if (isEventSupported('focus', true)) { - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topFocus', 'focus', mountAt); - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topBlur', 'blur', mountAt); - } else if (isEventSupported('focusin')) { - // IE has `focusin` and `focusout` events which bubble. - // @see http://www.quirksmode.org/blog/archives/2008/04/delegating_the.html - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topFocus', 'focusin', mountAt); - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topBlur', 'focusout', mountAt); - } + MPrime.prototype.imulK = function imulK (num) { + return num.imul(this.k); + }; - // to make sure blur and focus event listeners are only attached once - isListening.topBlur = true; - isListening.topFocus = true; - } else if (topEventMapping.hasOwnProperty(dependency)) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(dependency, topEventMapping[dependency], mountAt); - } + function K256 () { + MPrime.call( + this, + 'k256', + 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f'); + } + inherits(K256, MPrime); - isListening[dependency] = true; + K256.prototype.split = function split (input, output) { + // 256 = 9 * 26 + 22 + var mask = 0x3fffff; + + var outLen = Math.min(input.length, 9); + for (var i = 0; i < outLen; i++) { + output.words[i] = input.words[i]; + } + output.length = outLen; + + if (input.length <= 9) { + input.words[0] = 0; + input.length = 1; + return; + } + + // Shift by 9 limbs + var prev = input.words[9]; + output.words[output.length++] = prev & mask; + + for (i = 10; i < input.length; i++) { + var next = input.words[i] | 0; + input.words[i - 10] = ((next & mask) << 4) | (prev >>> 22); + prev = next; + } + prev >>>= 22; + input.words[i - 10] = prev; + if (prev === 0 && input.length > 10) { + input.length -= 10; + } else { + input.length -= 9; + } + }; + + K256.prototype.imulK = function imulK (num) { + // K = 0x1000003d1 = [ 0x40, 0x3d1 ] + num.words[num.length] = 0; + num.words[num.length + 1] = 0; + num.length += 2; + + // bounded at: 0x40 * 0x3ffffff + 0x3d0 = 0x100000390 + var lo = 0; + for (var i = 0; i < num.length; i++) { + var w = num.words[i] | 0; + lo += w * 0x3d1; + num.words[i] = lo & 0x3ffffff; + lo = w * 0x40 + ((lo / 0x4000000) | 0); + } + + // Fast length reduction + if (num.words[num.length - 1] === 0) { + num.length--; + if (num.words[num.length - 1] === 0) { + num.length--; } } - }, + return num; + }; - trapBubbledEvent: function (topLevelType, handlerBaseName, handle) { - return ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(topLevelType, handlerBaseName, handle); - }, + function P224 () { + MPrime.call( + this, + 'p224', + 'ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001'); + } + inherits(P224, MPrime); - trapCapturedEvent: function (topLevelType, handlerBaseName, handle) { - return ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent(topLevelType, handlerBaseName, handle); - }, + function P192 () { + MPrime.call( + this, + 'p192', + 'ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff'); + } + inherits(P192, MPrime); - /** - * Protect against document.createEvent() returning null - * Some popup blocker extensions appear to do this: - * https://github.com/facebook/react/issues/6887 - */ - supportsEventPageXY: function () { - if (!document.createEvent) { - return false; + function P25519 () { + // 2 ^ 255 - 19 + MPrime.call( + this, + '25519', + '7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed'); + } + inherits(P25519, MPrime); + + P25519.prototype.imulK = function imulK (num) { + // K = 0x13 + var carry = 0; + for (var i = 0; i < num.length; i++) { + var hi = (num.words[i] | 0) * 0x13 + carry; + var lo = hi & 0x3ffffff; + hi >>>= 26; + + num.words[i] = lo; + carry = hi; } - var ev = document.createEvent('MouseEvent'); - return ev != null && 'pageX' in ev; - }, + if (carry !== 0) { + num.words[num.length++] = carry; + } + return num; + }; - /** - * Listens to window scroll and resize events. We cache scroll values so that - * application code can access them without triggering reflows. - * - * ViewportMetrics is only used by SyntheticMouse/TouchEvent and only when - * pageX/pageY isn't supported (legacy browsers). - * - * NOTE: Scroll events do not bubble. - * - * @see http://www.quirksmode.org/dom/events/scroll.html - */ - ensureScrollValueMonitoring: function () { - if (hasEventPageXY === undefined) { - hasEventPageXY = ReactBrowserEventEmitter.supportsEventPageXY(); + // Exported mostly for testing purposes, use plain name instead + BN._prime = function prime (name) { + // Cached version of prime + if (primes[name]) return primes[name]; + + var prime; + if (name === 'k256') { + prime = new K256(); + } else if (name === 'p224') { + prime = new P224(); + } else if (name === 'p192') { + prime = new P192(); + } else if (name === 'p25519') { + prime = new P25519(); + } else { + throw new Error('Unknown prime ' + name); } - if (!hasEventPageXY && !isMonitoringScrollValue) { - var refresh = ViewportMetrics.refreshScrollValues; - ReactBrowserEventEmitter.ReactEventListener.monitorScrollValue(refresh); - isMonitoringScrollValue = true; + primes[name] = prime; + + return prime; + }; + + // + // Base reduction engine + // + function Red (m) { + if (typeof m === 'string') { + var prime = BN._prime(m); + this.m = prime.p; + this.prime = prime; + } else { + assert(m.gtn(1), 'modulus must be greater than 1'); + this.m = m; + this.prime = null; } } -}); -module.exports = ReactBrowserEventEmitter; + Red.prototype._verify1 = function _verify1 (a) { + assert(a.negative === 0, 'red works only with positives'); + assert(a.red, 'red works only with red numbers'); + }; -/***/ }), -/* 46 */, -/* 47 */, -/* 48 */ -/***/ (function(module, exports, __webpack_require__) { + Red.prototype._verify2 = function _verify2 (a, b) { + assert((a.negative | b.negative) === 0, 'red works only with positives'); + assert(a.red && a.red === b.red, + 'red works only with red numbers'); + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + Red.prototype.imod = function imod (a) { + if (this.prime) return this.prime.ireduce(a)._forceRed(this); + return a.umod(this.m)._forceRed(this); + }; + Red.prototype.neg = function neg (a) { + if (a.isZero()) { + return a.clone(); + } + return this.m.sub(a)._forceRed(this); + }; -/** - * Forked from fbjs/warning: - * https://github.com/facebook/fbjs/blob/e66ba20ad5be433eb54423f2b097d829324d9de6/packages/fbjs/src/__forks__/warning.js - * - * Only change is we use console.warn instead of console.error, - * and do nothing when 'console' is not supported. - * This really simplifies the code. - * --- - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ + Red.prototype.add = function add (a, b) { + this._verify2(a, b); -var lowPriorityWarning = function () {}; + var res = a.add(b); + if (res.cmp(this.m) >= 0) { + res.isub(this.m); + } + return res._forceRed(this); + }; -if (process.env.NODE_ENV !== 'production') { - var printWarning = function (format) { - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; + Red.prototype.iadd = function iadd (a, b) { + this._verify2(a, b); + + var res = a.iadd(b); + if (res.cmp(this.m) >= 0) { + res.isub(this.m); } + return res; + }; - var argIndex = 0; - var message = 'Warning: ' + format.replace(/%s/g, function () { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.warn(message); + Red.prototype.sub = function sub (a, b) { + this._verify2(a, b); + + var res = a.sub(b); + if (res.cmpn(0) < 0) { + res.iadd(this.m); } - try { - // --- Welcome to debugging React --- - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch (x) {} + return res._forceRed(this); }; - lowPriorityWarning = function (condition, format) { - if (format === undefined) { - throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + Red.prototype.isub = function isub (a, b) { + this._verify2(a, b); + + var res = a.isub(b); + if (res.cmpn(0) < 0) { + res.iadd(this.m); } - if (!condition) { - for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { - args[_key2 - 2] = arguments[_key2]; + return res; + }; + + Red.prototype.shl = function shl (a, num) { + this._verify1(a); + return this.imod(a.ushln(num)); + }; + + Red.prototype.imul = function imul (a, b) { + this._verify2(a, b); + return this.imod(a.imul(b)); + }; + + Red.prototype.mul = function mul (a, b) { + this._verify2(a, b); + return this.imod(a.mul(b)); + }; + + Red.prototype.isqr = function isqr (a) { + return this.imul(a, a.clone()); + }; + + Red.prototype.sqr = function sqr (a) { + return this.mul(a, a); + }; + + Red.prototype.sqrt = function sqrt (a) { + if (a.isZero()) return a.clone(); + + var mod3 = this.m.andln(3); + assert(mod3 % 2 === 1); + + // Fast case + if (mod3 === 3) { + var pow = this.m.add(new BN(1)).iushrn(2); + return this.pow(a, pow); + } + + // Tonelli-Shanks algorithm (Totally unoptimized and slow) + // + // Find Q and S, that Q * 2 ^ S = (P - 1) + var q = this.m.subn(1); + var s = 0; + while (!q.isZero() && q.andln(1) === 0) { + s++; + q.iushrn(1); + } + assert(!q.isZero()); + + var one = new BN(1).toRed(this); + var nOne = one.redNeg(); + + // Find quadratic non-residue + // NOTE: Max is such because of generalized Riemann hypothesis. + var lpow = this.m.subn(1).iushrn(1); + var z = this.m.bitLength(); + z = new BN(2 * z * z).toRed(this); + + while (this.pow(z, lpow).cmp(nOne) !== 0) { + z.redIAdd(nOne); + } + + var c = this.pow(z, q); + var r = this.pow(a, q.addn(1).iushrn(1)); + var t = this.pow(a, q); + var m = s; + while (t.cmp(one) !== 0) { + var tmp = t; + for (var i = 0; tmp.cmp(one) !== 0; i++) { + tmp = tmp.redSqr(); } + assert(i < m); + var b = this.pow(c, new BN(1).iushln(m - i - 1)); - printWarning.apply(undefined, [format].concat(args)); + r = r.redMul(b); + c = b.redSqr(); + t = t.redMul(c); + m = i; } + + return r; }; -} -module.exports = lowPriorityWarning; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + Red.prototype.invm = function invm (a) { + var inv = a._invmp(this.m); + if (inv.negative !== 0) { + inv.negative = 0; + return this.imod(inv).redNeg(); + } else { + return this.imod(inv); + } + }; + + Red.prototype.pow = function pow (a, num) { + if (num.isZero()) return new BN(1).toRed(this); + if (num.cmpn(1) === 0) return a.clone(); + + var windowSize = 4; + var wnd = new Array(1 << windowSize); + wnd[0] = new BN(1).toRed(this); + wnd[1] = a; + for (var i = 2; i < wnd.length; i++) { + wnd[i] = this.mul(wnd[i - 1], a); + } + + var res = wnd[0]; + var current = 0; + var currentLen = 0; + var start = num.bitLength() % 26; + if (start === 0) { + start = 26; + } + + for (i = num.length - 1; i >= 0; i--) { + var word = num.words[i]; + for (var j = start - 1; j >= 0; j--) { + var bit = (word >> j) & 1; + if (res !== wnd[0]) { + res = this.sqr(res); + } + + if (bit === 0 && current === 0) { + currentLen = 0; + continue; + } + + current <<= 1; + current |= bit; + currentLen++; + if (currentLen !== windowSize && (i !== 0 || j !== 0)) continue; + + res = this.mul(res, wnd[current]); + currentLen = 0; + current = 0; + } + start = 26; + } + + return res; + }; + + Red.prototype.convertTo = function convertTo (num) { + var r = num.umod(this.m); + + return r === num ? r.clone() : r; + }; + + Red.prototype.convertFrom = function convertFrom (num) { + var res = num.clone(); + res.red = null; + return res; + }; + + // + // Montgomery method engine + // + + BN.mont = function mont (num) { + return new Mont(num); + }; + + function Mont (m) { + Red.call(this, m); + + this.shift = this.m.bitLength(); + if (this.shift % 26 !== 0) { + this.shift += 26 - (this.shift % 26); + } + + this.r = new BN(1).iushln(this.shift); + this.r2 = this.imod(this.r.sqr()); + this.rinv = this.r._invmp(this.m); + + this.minv = this.rinv.mul(this.r).isubn(1).div(this.m); + this.minv = this.minv.umod(this.r); + this.minv = this.r.sub(this.minv); + } + inherits(Mont, Red); + + Mont.prototype.convertTo = function convertTo (num) { + return this.imod(num.ushln(this.shift)); + }; + + Mont.prototype.convertFrom = function convertFrom (num) { + var r = this.imod(num.mul(this.rinv)); + r.red = null; + return r; + }; + + Mont.prototype.imul = function imul (a, b) { + if (a.isZero() || b.isZero()) { + a.words[0] = 0; + a.length = 1; + return a; + } + + var t = a.imul(b); + var c = t.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m); + var u = t.isub(c).iushrn(this.shift); + var res = u; + + if (u.cmp(this.m) >= 0) { + res = u.isub(this.m); + } else if (u.cmpn(0) < 0) { + res = u.iadd(this.m); + } + + return res._forceRed(this); + }; + + Mont.prototype.mul = function mul (a, b) { + if (a.isZero() || b.isZero()) return new BN(0)._forceRed(this); + + var t = a.mul(b); + var c = t.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m); + var u = t.isub(c).iushrn(this.shift); + var res = u; + if (u.cmp(this.m) >= 0) { + res = u.isub(this.m); + } else if (u.cmpn(0) < 0) { + res = u.iadd(this.m); + } + + return res._forceRed(this); + }; + + Mont.prototype.invm = function invm (a) { + // (AR)^-1 * R^2 = (A^-1 * R^-1) * R^2 = A^-1 * R + var res = this.imod(a._invmp(this.m).mul(this.r2)); + return res._forceRed(this); + }; +})(typeof module === 'undefined' || module, this); + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(384)(module))) /***/ }), -/* 49 */ +/* 12 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +var typeforce = __webpack_require__(9) +var UINT31_MAX = Math.pow(2, 31) - 1 +function UInt31 (value) { + return typeforce.UInt32(value) && value <= UINT31_MAX +} +function BIP32Path (value) { + return typeforce.String(value) && value.match(/^(m\/)?(\d+'?\/)*\d+'?$/) +} +BIP32Path.toJSON = function () { return 'BIP32 derivation path' } -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; +var SATOSHI_MAX = 21 * 1e14 +function Satoshi (value) { + return typeforce.UInt53(value) && value <= SATOSHI_MAX +} -module.exports = ReactPropTypesSecret; +// external dependent types +var BigInt = typeforce.quacksLike('BigInteger') +var ECPoint = typeforce.quacksLike('Point') + +// exposed, external API +var ECSignature = typeforce.compile({ r: BigInt, s: BigInt }) +var Network = typeforce.compile({ + messagePrefix: typeforce.oneOf(typeforce.Buffer, typeforce.String), + bip32: { + public: typeforce.UInt32, + private: typeforce.UInt32 + }, + pubKeyHash: typeforce.UInt8, + scriptHash: typeforce.UInt8, + wif: typeforce.UInt8 +}) + +// extend typeforce types with ours +var types = { + BigInt: BigInt, + BIP32Path: BIP32Path, + Buffer256bit: typeforce.BufferN(32), + ECPoint: ECPoint, + ECSignature: ECSignature, + Hash160bit: typeforce.BufferN(20), + Hash256bit: typeforce.BufferN(32), + Network: Network, + Satoshi: Satoshi, + UInt31: UInt31 +} + +for (var typeName in typeforce) { + types[typeName] = typeforce[typeName] +} + +module.exports = types /***/ }), -/* 50 */ +/* 13 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. +/** + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -4905,1019 +6384,1177 @@ module.exports = ReactPropTypesSecret; -var _prodInvariant = __webpack_require__(3); - -var ReactErrorUtils = __webpack_require__(51); - -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); /** - * Injected dependencies: + * Simple, lightweight module assisting with the detection and context of + * Worker. Helps avoid circular dependencies and allows code to reason about + * whether or not they are in a Worker, even if they never include the main + * `ReactWorker` dependency. */ +var ExecutionEnvironment = { + + canUseDOM: canUseDOM, + + canUseWorkers: typeof Worker !== 'undefined', + + canUseEventListeners: canUseDOM && !!(window.addEventListener || window.attachEvent), + + canUseViewport: canUseDOM && !!window.screen, + + isInWorker: !canUseDOM // For now, this is true - might change in the future. -/** - * - `ComponentTree`: [required] Module that can convert between React instances - * and actual node references. - */ -var ComponentTree; -var TreeTraversal; -var injection = { - injectComponentTree: function (Injected) { - ComponentTree = Injected; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.getNodeFromInstance && Injected.getInstanceFromNode, 'EventPluginUtils.injection.injectComponentTree(...): Injected ' + 'module is missing getNodeFromInstance or getInstanceFromNode.') : void 0; - } - }, - injectTreeTraversal: function (Injected) { - TreeTraversal = Injected; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.isAncestor && Injected.getLowestCommonAncestor, 'EventPluginUtils.injection.injectTreeTraversal(...): Injected ' + 'module is missing isAncestor or getLowestCommonAncestor.') : void 0; - } - } }; -function isEndish(topLevelType) { - return topLevelType === 'topMouseUp' || topLevelType === 'topTouchEnd' || topLevelType === 'topTouchCancel'; +module.exports = ExecutionEnvironment; + +/***/ }), +/* 14 */ +/***/ (function(module, exports, __webpack_require__) { + +var Buffer = __webpack_require__(7).Buffer +var bip66 = __webpack_require__(104) +var pushdata = __webpack_require__(202) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var scriptNumber = __webpack_require__(203) + +var OPS = __webpack_require__(16) +var REVERSE_OPS = __webpack_require__(468) +var OP_INT_BASE = OPS.OP_RESERVED // OP_1 - 1 + +function isOPInt (value) { + return types.Number(value) && + ((value === OPS.OP_0) || + (value >= OPS.OP_1 && value <= OPS.OP_16) || + (value === OPS.OP_1NEGATE)) } -function isMoveish(topLevelType) { - return topLevelType === 'topMouseMove' || topLevelType === 'topTouchMove'; +function isPushOnlyChunk (value) { + return types.Buffer(value) || isOPInt(value) } -function isStartish(topLevelType) { - return topLevelType === 'topMouseDown' || topLevelType === 'topTouchStart'; + +function isPushOnly (value) { + return types.Array(value) && value.every(isPushOnlyChunk) } -var validateEventDispatches; -if (process.env.NODE_ENV !== 'production') { - validateEventDispatches = function (event) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; +function compile (chunks) { + // TODO: remove me + if (Buffer.isBuffer(chunks)) return chunks - var listenersIsArr = Array.isArray(dispatchListeners); - var listenersLen = listenersIsArr ? dispatchListeners.length : dispatchListeners ? 1 : 0; + typeforce(types.Array, chunks) - var instancesIsArr = Array.isArray(dispatchInstances); - var instancesLen = instancesIsArr ? dispatchInstances.length : dispatchInstances ? 1 : 0; + var bufferSize = chunks.reduce(function (accum, chunk) { + // data chunk + if (Buffer.isBuffer(chunk)) { + // adhere to BIP62.3, minimal push policy + if (chunk.length === 1 && (chunk[0] === 0x81 || (chunk[0] >= 1 && chunk[0] <= 16))) { + return accum + 1 + } - process.env.NODE_ENV !== 'production' ? warning(instancesIsArr === listenersIsArr && instancesLen === listenersLen, 'EventPluginUtils: Invalid `event`.') : void 0; - }; -} + return accum + pushdata.encodingLength(chunk.length) + chunk.length + } -/** - * Dispatch the event to the listener. - * @param {SyntheticEvent} event SyntheticEvent to handle - * @param {boolean} simulated If the event is simulated (changes exn behavior) - * @param {function} listener Application-level callback - * @param {*} inst Internal component instance - */ -function executeDispatch(event, simulated, listener, inst) { - var type = event.type || 'unknown-event'; - event.currentTarget = EventPluginUtils.getNodeFromInstance(inst); - if (simulated) { - ReactErrorUtils.invokeGuardedCallbackWithCatch(type, listener, event); - } else { - ReactErrorUtils.invokeGuardedCallback(type, listener, event); - } - event.currentTarget = null; -} + // opcode + return accum + 1 + }, 0.0) -/** - * Standard/simple iteration through an event's collected dispatches. - */ -function executeDispatchesInOrder(event, simulated) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; - if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - if (Array.isArray(dispatchListeners)) { - for (var i = 0; i < dispatchListeners.length; i++) { - if (event.isPropagationStopped()) { - break; - } - // Listeners and Instances are two parallel arrays that are always in sync. - executeDispatch(event, simulated, dispatchListeners[i], dispatchInstances[i]); - } - } else if (dispatchListeners) { - executeDispatch(event, simulated, dispatchListeners, dispatchInstances); - } - event._dispatchListeners = null; - event._dispatchInstances = null; -} + var buffer = Buffer.allocUnsafe(bufferSize) + var offset = 0 -/** - * Standard/simple iteration through an event's collected dispatches, but stops - * at the first dispatch execution returning true, and returns that id. - * - * @return {?string} id of the first dispatch execution who's listener returns - * true, or null if no listener returned true. - */ -function executeDispatchesInOrderStopAtTrueImpl(event) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; - if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - if (Array.isArray(dispatchListeners)) { - for (var i = 0; i < dispatchListeners.length; i++) { - if (event.isPropagationStopped()) { - break; + chunks.forEach(function (chunk) { + // data chunk + if (Buffer.isBuffer(chunk)) { + // adhere to BIP62.3, minimal push policy + if (chunk.length === 1 && chunk[0] >= 1 && chunk[0] <= 16) { + var opcode = OP_INT_BASE + chunk[0] + buffer.writeUInt8(opcode, offset) + offset += 1 + return } - // Listeners and Instances are two parallel arrays that are always in sync. - if (dispatchListeners[i](event, dispatchInstances[i])) { - return dispatchInstances[i]; + + if (chunk.length === 1 && chunk[0] === 0x81) { + buffer.writeUInt8(OPS.OP_1NEGATE, offset) + offset += 1 + return } - } - } else if (dispatchListeners) { - if (dispatchListeners(event, dispatchInstances)) { - return dispatchInstances; - } - } - return null; -} -/** - * @see executeDispatchesInOrderStopAtTrueImpl - */ -function executeDispatchesInOrderStopAtTrue(event) { - var ret = executeDispatchesInOrderStopAtTrueImpl(event); - event._dispatchInstances = null; - event._dispatchListeners = null; - return ret; -} + offset += pushdata.encode(buffer, chunk.length, offset) -/** - * Execution of a "direct" dispatch - there must be at most one dispatch - * accumulated on the event or it is considered an error. It doesn't really make - * sense for an event with multiple dispatches (bubbled) to keep track of the - * return values at each dispatch execution, but it does tend to make sense when - * dealing with "direct" dispatches. - * - * @return {*} The return value of executing the single dispatch. - */ -function executeDirectDispatch(event) { - if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - var dispatchListener = event._dispatchListeners; - var dispatchInstance = event._dispatchInstances; - !!Array.isArray(dispatchListener) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'executeDirectDispatch(...): Invalid `event`.') : _prodInvariant('103') : void 0; - event.currentTarget = dispatchListener ? EventPluginUtils.getNodeFromInstance(dispatchInstance) : null; - var res = dispatchListener ? dispatchListener(event) : null; - event.currentTarget = null; - event._dispatchListeners = null; - event._dispatchInstances = null; - return res; -} + chunk.copy(buffer, offset) + offset += chunk.length -/** - * @param {SyntheticEvent} event - * @return {boolean} True iff number of dispatches accumulated is greater than 0. - */ -function hasDispatches(event) { - return !!event._dispatchListeners; + // opcode + } else { + buffer.writeUInt8(chunk, offset) + offset += 1 + } + }) + + if (offset !== buffer.length) throw new Error('Could not decode chunks') + return buffer } -/** - * General utilities that are useful in creating custom Event Plugins. - */ -var EventPluginUtils = { - isEndish: isEndish, - isMoveish: isMoveish, - isStartish: isStartish, +function decompile (buffer) { + // TODO: remove me + if (types.Array(buffer)) return buffer - executeDirectDispatch: executeDirectDispatch, - executeDispatchesInOrder: executeDispatchesInOrder, - executeDispatchesInOrderStopAtTrue: executeDispatchesInOrderStopAtTrue, - hasDispatches: hasDispatches, + typeforce(types.Buffer, buffer) - getInstanceFromNode: function (node) { - return ComponentTree.getInstanceFromNode(node); - }, - getNodeFromInstance: function (node) { - return ComponentTree.getNodeFromInstance(node); - }, - isAncestor: function (a, b) { - return TreeTraversal.isAncestor(a, b); - }, - getLowestCommonAncestor: function (a, b) { - return TreeTraversal.getLowestCommonAncestor(a, b); - }, - getParentInstance: function (inst) { - return TreeTraversal.getParentInstance(inst); - }, - traverseTwoPhase: function (target, fn, arg) { - return TreeTraversal.traverseTwoPhase(target, fn, arg); - }, - traverseEnterLeave: function (from, to, fn, argFrom, argTo) { - return TreeTraversal.traverseEnterLeave(from, to, fn, argFrom, argTo); - }, + var chunks = [] + var i = 0 - injection: injection -}; + while (i < buffer.length) { + var opcode = buffer[i] -module.exports = EventPluginUtils; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // data chunk + if ((opcode > OPS.OP_0) && (opcode <= OPS.OP_PUSHDATA4)) { + var d = pushdata.decode(buffer, i) -/***/ }), -/* 51 */ -/***/ (function(module, exports, __webpack_require__) { + // did reading a pushDataInt fail? empty script + if (d === null) return [] + i += d.size -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + // attempt to read too much data? empty script + if (i + d.number > buffer.length) return [] + var data = buffer.slice(i, i + d.number) + i += d.number + chunks.push(data) -var caughtError = null; + // opcode + } else { + chunks.push(opcode) -/** - * Call a function while guarding against errors that happens within it. - * - * @param {String} name of the guard to use for logging or debugging - * @param {Function} func The function to invoke - * @param {*} a First argument - * @param {*} b Second argument - */ -function invokeGuardedCallback(name, func, a) { - try { - func(a); - } catch (x) { - if (caughtError === null) { - caughtError = x; + i += 1 } } -} -var ReactErrorUtils = { - invokeGuardedCallback: invokeGuardedCallback, - - /** - * Invoked by ReactTestUtils.Simulate so that any errors thrown by the event - * handler are sure to be rethrown by rethrowCaughtError. - */ - invokeGuardedCallbackWithCatch: invokeGuardedCallback, + return chunks +} - /** - * During execution of guarded functions we will capture the first error which - * we will rethrow to be handled by the top level error handler. - */ - rethrowCaughtError: function () { - if (caughtError) { - var error = caughtError; - caughtError = null; - throw error; - } +function toASM (chunks) { + if (Buffer.isBuffer(chunks)) { + chunks = decompile(chunks) } -}; -if (process.env.NODE_ENV !== 'production') { - /** - * To help development we can get better devtools integration by simulating a - * real browser event. - */ - if (typeof window !== 'undefined' && typeof window.dispatchEvent === 'function' && typeof document !== 'undefined' && typeof document.createEvent === 'function') { - var fakeNode = document.createElement('react'); - ReactErrorUtils.invokeGuardedCallback = function (name, func, a) { - var boundFunc = func.bind(null, a); - var evtType = 'react-' + name; - fakeNode.addEventListener(evtType, boundFunc, false); - var evt = document.createEvent('Event'); - evt.initEvent(evtType, false, false); - fakeNode.dispatchEvent(evt); - fakeNode.removeEventListener(evtType, boundFunc, false); - }; - } + return chunks.map(function (chunk) { + // data? + if (Buffer.isBuffer(chunk)) return chunk.toString('hex') + + // opcode! + return REVERSE_OPS[chunk] + }).join(' ') } -module.exports = ReactErrorUtils; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function fromASM (asm) { + typeforce(types.String, asm) -/***/ }), -/* 52 */ -/***/ (function(module, exports, __webpack_require__) { + return compile(asm.split(' ').map(function (chunkStr) { + // opcode? + if (OPS[chunkStr] !== undefined) return OPS[chunkStr] + typeforce(types.Hex, chunkStr) -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // data! + return Buffer.from(chunkStr, 'hex') + })) +} +function toStack (chunks) { + chunks = decompile(chunks) + typeforce(isPushOnly, chunks) + return chunks.map(function (op) { + if (Buffer.isBuffer(op)) return op + if (op === OPS.OP_0) return Buffer.allocUnsafe(0) -/** - * Gets the target node from a native browser event by accounting for - * inconsistencies in browser DOM APIs. - * - * @param {object} nativeEvent Native browser event. - * @return {DOMEventTarget} Target node. - */ + return scriptNumber.encode(op - OP_INT_BASE) + }) +} -function getEventTarget(nativeEvent) { - var target = nativeEvent.target || nativeEvent.srcElement || window; +function isCanonicalPubKey (buffer) { + if (!Buffer.isBuffer(buffer)) return false + if (buffer.length < 33) return false - // Normalize SVG element events #4963 - if (target.correspondingUseElement) { - target = target.correspondingUseElement; + switch (buffer[0]) { + case 0x02: + case 0x03: + return buffer.length === 33 + case 0x04: + return buffer.length === 65 } - // Safari may fire events on text nodes (Node.TEXT_NODE is 3). - // @see http://www.quirksmode.org/js/events_properties.html - return target.nodeType === 3 ? target.parentNode : target; + return false } -module.exports = getEventTarget; - -/***/ }), -/* 53 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - +function isDefinedHashType (hashType) { + var hashTypeMod = hashType & ~0x80 -var ExecutionEnvironment = __webpack_require__(8); - -var useHasFeature; -if (ExecutionEnvironment.canUseDOM) { - useHasFeature = document.implementation && document.implementation.hasFeature && - // always returns true in newer browsers as per the standard. - // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature - document.implementation.hasFeature('', '') !== true; +// return hashTypeMod > SIGHASH_ALL && hashTypeMod < SIGHASH_SINGLE + return hashTypeMod > 0x00 && hashTypeMod < 0x04 } -/** - * Checks if an event is supported in the current execution environment. - * - * NOTE: This will not work correctly for non-generic events such as `change`, - * `reset`, `load`, `error`, and `select`. - * - * Borrows from Modernizr. - * - * @param {string} eventNameSuffix Event name, e.g. "click". - * @param {?boolean} capture Check if the capture phase is supported. - * @return {boolean} True if the event is supported. - * @internal - * @license Modernizr 3.0.0pre (Custom Build) | MIT - */ -function isEventSupported(eventNameSuffix, capture) { - if (!ExecutionEnvironment.canUseDOM || capture && !('addEventListener' in document)) { - return false; - } - - var eventName = 'on' + eventNameSuffix; - var isSupported = eventName in document; +function isCanonicalSignature (buffer) { + if (!Buffer.isBuffer(buffer)) return false + if (!isDefinedHashType(buffer[buffer.length - 1])) return false - if (!isSupported) { - var element = document.createElement('div'); - element.setAttribute(eventName, 'return;'); - isSupported = typeof element[eventName] === 'function'; - } + return bip66.check(buffer.slice(0, -1)) +} - if (!isSupported && useHasFeature && eventNameSuffix === 'wheel') { - // This is the only way to test support for the `wheel` event in IE9+. - isSupported = document.implementation.hasFeature('Events.wheel', '3.0'); - } +module.exports = { + compile: compile, + decompile: decompile, + fromASM: fromASM, + toASM: toASM, + toStack: toStack, + + number: __webpack_require__(203), + + isCanonicalPubKey: isCanonicalPubKey, + isCanonicalSignature: isCanonicalSignature, + isPushOnly: isPushOnly, + isDefinedHashType: isDefinedHashType +} - return isSupported; +var templates = __webpack_require__(469) +for (var key in templates) { + module.exports[key] = templates[key] } -module.exports = isEventSupported; /***/ }), -/* 54 */ +/* 15 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var elliptic = exports; -/** - * Translation from modifier key to the associated property in the event. - * @see http://www.w3.org/TR/DOM-Level-3-Events/#keys-Modifiers - */ +elliptic.version = __webpack_require__(385).version; +elliptic.utils = __webpack_require__(386); +elliptic.rand = __webpack_require__(171); +elliptic.curve = __webpack_require__(65); +elliptic.curves = __webpack_require__(392); -var modifierKeyToProp = { - Alt: 'altKey', - Control: 'ctrlKey', - Meta: 'metaKey', - Shift: 'shiftKey' -}; +// Protocols +elliptic.ec = __webpack_require__(400); +elliptic.eddsa = __webpack_require__(404); -// IE8 does not implement getModifierState so we simply map it to the only -// modifier keys exposed by the event itself, does not support Lock-keys. -// Currently, all major browsers except Chrome seems to support Lock-keys. -function modifierStateGetter(keyArg) { - var syntheticEvent = this; - var nativeEvent = syntheticEvent.nativeEvent; - if (nativeEvent.getModifierState) { - return nativeEvent.getModifierState(keyArg); - } - var keyProp = modifierKeyToProp[keyArg]; - return keyProp ? !!nativeEvent[keyProp] : false; -} -function getEventModifierState(nativeEvent) { - return modifierStateGetter; -} +/***/ }), +/* 16 */ +/***/ (function(module, exports) { -module.exports = getEventModifierState; +module.exports = { + "OP_FALSE": 0, + "OP_0": 0, + "OP_PUSHDATA1": 76, + "OP_PUSHDATA2": 77, + "OP_PUSHDATA4": 78, + "OP_1NEGATE": 79, + "OP_RESERVED": 80, + "OP_1": 81, + "OP_TRUE": 81, + "OP_2": 82, + "OP_3": 83, + "OP_4": 84, + "OP_5": 85, + "OP_6": 86, + "OP_7": 87, + "OP_8": 88, + "OP_9": 89, + "OP_10": 90, + "OP_11": 91, + "OP_12": 92, + "OP_13": 93, + "OP_14": 94, + "OP_15": 95, + "OP_16": 96, + "OP_NOP": 97, + "OP_VER": 98, + "OP_IF": 99, + "OP_NOTIF": 100, + "OP_VERIF": 101, + "OP_VERNOTIF": 102, + "OP_ELSE": 103, + "OP_ENDIF": 104, + "OP_VERIFY": 105, + "OP_RETURN": 106, + "OP_TOALTSTACK": 107, + "OP_FROMALTSTACK": 108, + "OP_2DROP": 109, + "OP_2DUP": 110, + "OP_3DUP": 111, + "OP_2OVER": 112, + "OP_2ROT": 113, + "OP_2SWAP": 114, + "OP_IFDUP": 115, + "OP_DEPTH": 116, + "OP_DROP": 117, + "OP_DUP": 118, + "OP_NIP": 119, + "OP_OVER": 120, + "OP_PICK": 121, + "OP_ROLL": 122, + "OP_ROT": 123, + "OP_SWAP": 124, + "OP_TUCK": 125, + "OP_CAT": 126, + "OP_SUBSTR": 127, + "OP_LEFT": 128, + "OP_RIGHT": 129, + "OP_SIZE": 130, + "OP_INVERT": 131, + "OP_AND": 132, + "OP_OR": 133, + "OP_XOR": 134, + "OP_EQUAL": 135, + "OP_EQUALVERIFY": 136, + "OP_RESERVED1": 137, + "OP_RESERVED2": 138, + "OP_1ADD": 139, + "OP_1SUB": 140, + "OP_2MUL": 141, + "OP_2DIV": 142, + "OP_NEGATE": 143, + "OP_ABS": 144, + "OP_NOT": 145, + "OP_0NOTEQUAL": 146, + "OP_ADD": 147, + "OP_SUB": 148, + "OP_MUL": 149, + "OP_DIV": 150, + "OP_MOD": 151, + "OP_LSHIFT": 152, + "OP_RSHIFT": 153, + "OP_BOOLAND": 154, + "OP_BOOLOR": 155, + "OP_NUMEQUAL": 156, + "OP_NUMEQUALVERIFY": 157, + "OP_NUMNOTEQUAL": 158, + "OP_LESSTHAN": 159, + "OP_GREATERTHAN": 160, + "OP_LESSTHANOREQUAL": 161, + "OP_GREATERTHANOREQUAL": 162, + "OP_MIN": 163, + "OP_MAX": 164, + "OP_WITHIN": 165, + "OP_RIPEMD160": 166, + "OP_SHA1": 167, + "OP_SHA256": 168, + "OP_HASH160": 169, + "OP_HASH256": 170, + "OP_CODESEPARATOR": 171, + "OP_CHECKSIG": 172, + "OP_CHECKSIGVERIFY": 173, + "OP_CHECKMULTISIG": 174, + "OP_CHECKMULTISIGVERIFY": 175, + "OP_NOP1": 176, + "OP_NOP2": 177, + "OP_CHECKLOCKTIMEVERIFY": 177, + "OP_NOP3": 178, + "OP_NOP4": 179, + "OP_NOP5": 180, + "OP_NOP6": 181, + "OP_NOP7": 182, + "OP_NOP8": 183, + "OP_NOP9": 184, + "OP_NOP10": 185, + "OP_PUBKEYHASH": 253, + "OP_PUBKEY": 254, + "OP_INVALIDOPCODE": 255 +}; /***/ }), -/* 55 */ +/* 17 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. + * Copyright 2016-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -var DOMLazyTree = __webpack_require__(27); -var Danger = __webpack_require__(154); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstrumentation = __webpack_require__(13); +var _prodInvariant = __webpack_require__(37); -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); -var setInnerHTML = __webpack_require__(43); -var setTextContent = __webpack_require__(90); +var ReactCurrentOwner = __webpack_require__(22); -function getNodeAfter(parentNode, node) { - // Special case for text components, which return [open, close] comments - // from getHostNode. - if (Array.isArray(node)) { - node = node[1]; +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +function isNative(fn) { + // Based on isNative() from Lodash + var funcToString = Function.prototype.toString; + var hasOwnProperty = Object.prototype.hasOwnProperty; + var reIsNative = RegExp('^' + funcToString + // Take an example native function source for comparison + .call(hasOwnProperty + // Strip regex characters so we can use it for regex + ).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&' + // Remove hasOwnProperty from the template to make it generic + ).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'); + try { + var source = funcToString.call(fn); + return reIsNative.test(source); + } catch (err) { + return false; } - return node ? node.nextSibling : parentNode.firstChild; } -/** - * Inserts `childNode` as a child of `parentNode` at the `index`. - * - * @param {DOMElement} parentNode Parent node in which to insert. - * @param {DOMElement} childNode Child node to insert. - * @param {number} index Index at which to insert the child. - * @internal - */ -var insertChildAt = createMicrosoftUnsafeLocalFunction(function (parentNode, childNode, referenceNode) { - // We rely exclusively on `insertBefore(node, null)` instead of also using - // `appendChild(node)`. (Using `undefined` is not allowed by all browsers so - // we are careful to use `null`.) - parentNode.insertBefore(childNode, referenceNode); -}); +var canUseCollections = +// Array.from +typeof Array.from === 'function' && +// Map +typeof Map === 'function' && isNative(Map) && +// Map.prototype.keys +Map.prototype != null && typeof Map.prototype.keys === 'function' && isNative(Map.prototype.keys) && +// Set +typeof Set === 'function' && isNative(Set) && +// Set.prototype.keys +Set.prototype != null && typeof Set.prototype.keys === 'function' && isNative(Set.prototype.keys); -function insertLazyTreeChildAt(parentNode, childTree, referenceNode) { - DOMLazyTree.insertTreeBefore(parentNode, childTree, referenceNode); -} +var setItem; +var getItem; +var removeItem; +var getItemIDs; +var addRoot; +var removeRoot; +var getRootIDs; -function moveChild(parentNode, childNode, referenceNode) { - if (Array.isArray(childNode)) { - moveDelimitedText(parentNode, childNode[0], childNode[1], referenceNode); - } else { - insertChildAt(parentNode, childNode, referenceNode); - } +if (canUseCollections) { + var itemMap = new Map(); + var rootIDSet = new Set(); + + setItem = function (id, item) { + itemMap.set(id, item); + }; + getItem = function (id) { + return itemMap.get(id); + }; + removeItem = function (id) { + itemMap['delete'](id); + }; + getItemIDs = function () { + return Array.from(itemMap.keys()); + }; + + addRoot = function (id) { + rootIDSet.add(id); + }; + removeRoot = function (id) { + rootIDSet['delete'](id); + }; + getRootIDs = function () { + return Array.from(rootIDSet.keys()); + }; +} else { + var itemByKey = {}; + var rootByKey = {}; + + // Use non-numeric keys to prevent V8 performance issues: + // https://github.com/facebook/react/pull/7232 + var getKeyFromID = function (id) { + return '.' + id; + }; + var getIDFromKey = function (key) { + return parseInt(key.substr(1), 10); + }; + + setItem = function (id, item) { + var key = getKeyFromID(id); + itemByKey[key] = item; + }; + getItem = function (id) { + var key = getKeyFromID(id); + return itemByKey[key]; + }; + removeItem = function (id) { + var key = getKeyFromID(id); + delete itemByKey[key]; + }; + getItemIDs = function () { + return Object.keys(itemByKey).map(getIDFromKey); + }; + + addRoot = function (id) { + var key = getKeyFromID(id); + rootByKey[key] = true; + }; + removeRoot = function (id) { + var key = getKeyFromID(id); + delete rootByKey[key]; + }; + getRootIDs = function () { + return Object.keys(rootByKey).map(getIDFromKey); + }; } -function removeChild(parentNode, childNode) { - if (Array.isArray(childNode)) { - var closingComment = childNode[1]; - childNode = childNode[0]; - removeDelimitedText(parentNode, childNode, closingComment); - parentNode.removeChild(closingComment); +var unmountedIDs = []; + +function purgeDeep(id) { + var item = getItem(id); + if (item) { + var childIDs = item.childIDs; + + removeItem(id); + childIDs.forEach(purgeDeep); } - parentNode.removeChild(childNode); } -function moveDelimitedText(parentNode, openingComment, closingComment, referenceNode) { - var node = openingComment; - while (true) { - var nextNode = node.nextSibling; - insertChildAt(parentNode, node, referenceNode); - if (node === closingComment) { - break; - } - node = nextNode; - } +function describeComponentFrame(name, source, ownerName) { + return '\n in ' + (name || 'Unknown') + (source ? ' (at ' + source.fileName.replace(/^.*[\\\/]/, '') + ':' + source.lineNumber + ')' : ownerName ? ' (created by ' + ownerName + ')' : ''); } -function removeDelimitedText(parentNode, startNode, closingComment) { - while (true) { - var node = startNode.nextSibling; - if (node === closingComment) { - // The closing comment is removed by ReactMultiChild. - break; - } else { - parentNode.removeChild(node); - } +function getDisplayName(element) { + if (element == null) { + return '#empty'; + } else if (typeof element === 'string' || typeof element === 'number') { + return '#text'; + } else if (typeof element.type === 'string') { + return element.type; + } else { + return element.type.displayName || element.type.name || 'Unknown'; } } -function replaceDelimitedText(openingComment, closingComment, stringText) { - var parentNode = openingComment.parentNode; - var nodeAfterComment = openingComment.nextSibling; - if (nodeAfterComment === closingComment) { - // There are no text nodes between the opening and closing comments; insert - // a new one if stringText isn't empty. - if (stringText) { - insertChildAt(parentNode, document.createTextNode(stringText), nodeAfterComment); +function describeID(id) { + var name = ReactComponentTreeHook.getDisplayName(id); + var element = ReactComponentTreeHook.getElement(id); + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var ownerName; + if (ownerID) { + ownerName = ReactComponentTreeHook.getDisplayName(ownerID); + } + process.env.NODE_ENV !== 'production' ? warning(element, 'ReactComponentTreeHook: Missing React element for debugID %s when ' + 'building stack', id) : void 0; + return describeComponentFrame(name, element && element._source, ownerName); +} + +var ReactComponentTreeHook = { + onSetChildren: function (id, nextChildIDs) { + var item = getItem(id); + !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; + item.childIDs = nextChildIDs; + + for (var i = 0; i < nextChildIDs.length; i++) { + var nextChildID = nextChildIDs[i]; + var nextChild = getItem(nextChildID); + !nextChild ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected hook events to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('140') : void 0; + !(nextChild.childIDs != null || typeof nextChild.element !== 'object' || nextChild.element == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onSetChildren() to fire for a container child before its parent includes it in onSetChildren().') : _prodInvariant('141') : void 0; + !nextChild.isMounted ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onMountComponent() to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('71') : void 0; + if (nextChild.parentID == null) { + nextChild.parentID = id; + // TODO: This shouldn't be necessary but mounting a new root during in + // componentWillMount currently causes not-yet-mounted components to + // be purged from our tree data so their parent id is missing. + } + !(nextChild.parentID === id) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onBeforeMountComponent() parent and onSetChildren() to be consistent (%s has parents %s and %s).', nextChildID, nextChild.parentID, id) : _prodInvariant('142', nextChildID, nextChild.parentID, id) : void 0; } - } else { - if (stringText) { - // Set the text content of the first node after the opening comment, and - // remove all following nodes up until the closing comment. - setTextContent(nodeAfterComment, stringText); - removeDelimitedText(parentNode, nodeAfterComment, closingComment); - } else { - removeDelimitedText(parentNode, openingComment, closingComment); + }, + onBeforeMountComponent: function (id, element, parentID) { + var item = { + element: element, + parentID: parentID, + text: null, + childIDs: [], + isMounted: false, + updateCount: 0 + }; + setItem(id, item); + }, + onBeforeUpdateComponent: function (id, element) { + var item = getItem(id); + if (!item || !item.isMounted) { + // We may end up here as a result of setState() in componentWillUnmount(). + // In this case, ignore the element. + return; + } + item.element = element; + }, + onMountComponent: function (id) { + var item = getItem(id); + !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; + item.isMounted = true; + var isRoot = item.parentID === 0; + if (isRoot) { + addRoot(id); + } + }, + onUpdateComponent: function (id) { + var item = getItem(id); + if (!item || !item.isMounted) { + // We may end up here as a result of setState() in componentWillUnmount(). + // In this case, ignore the element. + return; + } + item.updateCount++; + }, + onUnmountComponent: function (id) { + var item = getItem(id); + if (item) { + // We need to check if it exists. + // `item` might not exist if it is inside an error boundary, and a sibling + // error boundary child threw while mounting. Then this instance never + // got a chance to mount, but it still gets an unmounting event during + // the error boundary cleanup. + item.isMounted = false; + var isRoot = item.parentID === 0; + if (isRoot) { + removeRoot(id); + } + } + unmountedIDs.push(id); + }, + purgeUnmountedComponents: function () { + if (ReactComponentTreeHook._preventPurging) { + // Should only be used for testing. + return; } - } - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(openingComment)._debugID, - type: 'replace text', - payload: stringText - }); - } -} + for (var i = 0; i < unmountedIDs.length; i++) { + var id = unmountedIDs[i]; + purgeDeep(id); + } + unmountedIDs.length = 0; + }, + isMounted: function (id) { + var item = getItem(id); + return item ? item.isMounted : false; + }, + getCurrentStackAddendum: function (topElement) { + var info = ''; + if (topElement) { + var name = getDisplayName(topElement); + var owner = topElement._owner; + info += describeComponentFrame(name, topElement._source, owner && owner.getName()); + } -var dangerouslyReplaceNodeWithMarkup = Danger.dangerouslyReplaceNodeWithMarkup; -if (process.env.NODE_ENV !== 'production') { - dangerouslyReplaceNodeWithMarkup = function (oldChild, markup, prevInstance) { - Danger.dangerouslyReplaceNodeWithMarkup(oldChild, markup); - if (prevInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: prevInstance._debugID, - type: 'replace with', - payload: markup.toString() - }); + var currentOwner = ReactCurrentOwner.current; + var id = currentOwner && currentOwner._debugID; + + info += ReactComponentTreeHook.getStackAddendumByID(id); + return info; + }, + getStackAddendumByID: function (id) { + var info = ''; + while (id) { + info += describeID(id); + id = ReactComponentTreeHook.getParentID(id); + } + return info; + }, + getChildIDs: function (id) { + var item = getItem(id); + return item ? item.childIDs : []; + }, + getDisplayName: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (!element) { + return null; + } + return getDisplayName(element); + }, + getElement: function (id) { + var item = getItem(id); + return item ? item.element : null; + }, + getOwnerID: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (!element || !element._owner) { + return null; + } + return element._owner._debugID; + }, + getParentID: function (id) { + var item = getItem(id); + return item ? item.parentID : null; + }, + getSource: function (id) { + var item = getItem(id); + var element = item ? item.element : null; + var source = element != null ? element._source : null; + return source; + }, + getText: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (typeof element === 'string') { + return element; + } else if (typeof element === 'number') { + return '' + element; } else { - var nextInstance = ReactDOMComponentTree.getInstanceFromNode(markup.node); - if (nextInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: nextInstance._debugID, - type: 'mount', - payload: markup.toString() - }); - } + return null; } - }; -} + }, + getUpdateCount: function (id) { + var item = getItem(id); + return item ? item.updateCount : 0; + }, -/** - * Operations for updating with DOM children. - */ -var DOMChildrenOperations = { - dangerouslyReplaceNodeWithMarkup: dangerouslyReplaceNodeWithMarkup, - replaceDelimitedText: replaceDelimitedText, + getRootIDs: getRootIDs, + getRegisteredIDs: getItemIDs, - /** - * Updates a component's children by processing a series of updates. The - * update configurations are each expected to have a `parentNode` property. - * - * @param {array} updates List of update configurations. - * @internal - */ - processUpdates: function (parentNode, updates) { - if (process.env.NODE_ENV !== 'production') { - var parentNodeDebugID = ReactDOMComponentTree.getInstanceFromNode(parentNode)._debugID; + pushNonStandardWarningStack: function (isCreatingElement, currentSource) { + if (typeof console.reactStack !== 'function') { + return; } - for (var k = 0; k < updates.length; k++) { - var update = updates[k]; - switch (update.type) { - case 'INSERT_MARKUP': - insertLazyTreeChildAt(parentNode, update.content, getNodeAfter(parentNode, update.afterNode)); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'insert child', - payload: { - toIndex: update.toIndex, - content: update.content.toString() - } - }); - } - break; - case 'MOVE_EXISTING': - moveChild(parentNode, update.fromNode, getNodeAfter(parentNode, update.afterNode)); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'move child', - payload: { fromIndex: update.fromIndex, toIndex: update.toIndex } - }); - } - break; - case 'SET_MARKUP': - setInnerHTML(parentNode, update.content); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'replace children', - payload: update.content.toString() - }); - } - break; - case 'TEXT_CONTENT': - setTextContent(parentNode, update.content); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'replace text', - payload: update.content.toString() - }); - } - break; - case 'REMOVE_NODE': - removeChild(parentNode, update.fromNode); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'remove child', - payload: { fromIndex: update.fromIndex } - }); - } - break; + var stack = []; + var currentOwner = ReactCurrentOwner.current; + var id = currentOwner && currentOwner._debugID; + + try { + if (isCreatingElement) { + stack.push({ + name: id ? ReactComponentTreeHook.getDisplayName(id) : null, + fileName: currentSource ? currentSource.fileName : null, + lineNumber: currentSource ? currentSource.lineNumber : null + }); + } + + while (id) { + var element = ReactComponentTreeHook.getElement(id); + var parentID = ReactComponentTreeHook.getParentID(id); + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var ownerName = ownerID ? ReactComponentTreeHook.getDisplayName(ownerID) : null; + var source = element && element._source; + stack.push({ + name: ownerName, + fileName: source ? source.fileName : null, + lineNumber: source ? source.lineNumber : null + }); + id = parentID; } + } catch (err) { + // Internal state is messed up. + // Stop building the stack (it's just a nice to have). } + + console.reactStack(stack); + }, + popNonStandardWarningStack: function () { + if (typeof console.reactStackEnd !== 'function') { + return; + } + console.reactStackEnd(); } }; -module.exports = DOMChildrenOperations; +module.exports = ReactComponentTreeHook; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 56 */ +/* 18 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; + + /** - * Copyright 2013-present, Facebook, Inc. + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ +function makeEmptyFunction(arg) { + return function () { + return arg; + }; +} +/** + * This function accepts and discards inputs; it has no side effects. This is + * primarily useful idiomatically for overridable function endpoints which + * always need to be callable, since JS lacks a null-call idiom ala Cocoa. + */ +var emptyFunction = function emptyFunction() {}; -var DOMNamespaces = { - html: 'http://www.w3.org/1999/xhtml', - mathml: 'http://www.w3.org/1998/Math/MathML', - svg: 'http://www.w3.org/2000/svg' +emptyFunction.thatReturns = makeEmptyFunction; +emptyFunction.thatReturnsFalse = makeEmptyFunction(false); +emptyFunction.thatReturnsTrue = makeEmptyFunction(true); +emptyFunction.thatReturnsNull = makeEmptyFunction(null); +emptyFunction.thatReturnsThis = function () { + return this; +}; +emptyFunction.thatReturnsArgument = function (arg) { + return arg; }; -module.exports = DOMNamespaces; +module.exports = emptyFunction; /***/ }), -/* 57 */ +/* 19 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -/* globals MSApp */ +// Trust the developer to only use ReactInstrumentation with a __DEV__ check -/** - * Create a function which has 'unsafe' privileges (required by windows8 apps) - */ +var debugTool = null; -var createMicrosoftUnsafeLocalFunction = function (func) { - if (typeof MSApp !== 'undefined' && MSApp.execUnsafeLocalFunction) { - return function (arg0, arg1, arg2, arg3) { - MSApp.execUnsafeLocalFunction(function () { - return func(arg0, arg1, arg2, arg3); - }); - }; - } else { - return func; - } -}; +if (process.env.NODE_ENV !== 'production') { + var ReactDebugTool = __webpack_require__(240); + debugTool = ReactDebugTool; +} -module.exports = createMicrosoftUnsafeLocalFunction; +module.exports = { debugTool: debugTool }; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 58 */ +/* 20 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. + + +var bind = __webpack_require__(155); +var isBuffer = __webpack_require__(337); + +/*global toString:true*/ + +// utils is a library of generic helper functions non-specific to axios + +var toString = Object.prototype.toString; + +/** + * Determine if a value is an Array * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * @param {Object} val The value to test + * @returns {boolean} True if value is an Array, otherwise false + */ +function isArray(val) { + return toString.call(val) === '[object Array]'; +} + +/** + * Determine if a value is an ArrayBuffer * + * @param {Object} val The value to test + * @returns {boolean} True if value is an ArrayBuffer, otherwise false */ +function isArrayBuffer(val) { + return toString.call(val) === '[object ArrayBuffer]'; +} +/** + * Determine if a value is a FormData + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an FormData, otherwise false + */ +function isFormData(val) { + return (typeof FormData !== 'undefined') && (val instanceof FormData); +} +/** + * Determine if a value is a view on an ArrayBuffer + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false + */ +function isArrayBufferView(val) { + var result; + if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) { + result = ArrayBuffer.isView(val); + } else { + result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer); + } + return result; +} -var _prodInvariant = __webpack_require__(3); +/** + * Determine if a value is a String + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a String, otherwise false + */ +function isString(val) { + return typeof val === 'string'; +} -var ReactPropTypesSecret = __webpack_require__(94); -var propTypesFactory = __webpack_require__(79); +/** + * Determine if a value is a Number + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Number, otherwise false + */ +function isNumber(val) { + return typeof val === 'number'; +} -var React = __webpack_require__(24); -var PropTypes = propTypesFactory(React.isValidElement); +/** + * Determine if a value is undefined + * + * @param {Object} val The value to test + * @returns {boolean} True if the value is undefined, otherwise false + */ +function isUndefined(val) { + return typeof val === 'undefined'; +} -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +/** + * Determine if a value is an Object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an Object, otherwise false + */ +function isObject(val) { + return val !== null && typeof val === 'object'; +} -var hasReadOnlyValue = { - button: true, - checkbox: true, - image: true, - hidden: true, - radio: true, - reset: true, - submit: true -}; +/** + * Determine if a value is a Date + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Date, otherwise false + */ +function isDate(val) { + return toString.call(val) === '[object Date]'; +} -function _assertSingleLink(inputProps) { - !(inputProps.checkedLink == null || inputProps.valueLink == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a valueLink. If you want to use checkedLink, you probably don\'t want to use valueLink and vice versa.') : _prodInvariant('87') : void 0; +/** + * Determine if a value is a File + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a File, otherwise false + */ +function isFile(val) { + return toString.call(val) === '[object File]'; } -function _assertValueLink(inputProps) { - _assertSingleLink(inputProps); - !(inputProps.value == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a valueLink and a value or onChange event. If you want to use value or onChange, you probably don\'t want to use valueLink.') : _prodInvariant('88') : void 0; + +/** + * Determine if a value is a Blob + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Blob, otherwise false + */ +function isBlob(val) { + return toString.call(val) === '[object Blob]'; } -function _assertCheckedLink(inputProps) { - _assertSingleLink(inputProps); - !(inputProps.checked == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a checked property or onChange event. If you want to use checked or onChange, you probably don\'t want to use checkedLink') : _prodInvariant('89') : void 0; +/** + * Determine if a value is a Function + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Function, otherwise false + */ +function isFunction(val) { + return toString.call(val) === '[object Function]'; } -var propTypes = { - value: function (props, propName, componentName) { - if (!props[propName] || hasReadOnlyValue[props.type] || props.onChange || props.readOnly || props.disabled) { - return null; - } - return new Error('You provided a `value` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultValue`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); - }, - checked: function (props, propName, componentName) { - if (!props[propName] || props.onChange || props.readOnly || props.disabled) { - return null; - } - return new Error('You provided a `checked` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultChecked`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); - }, - onChange: PropTypes.func -}; +/** + * Determine if a value is a Stream + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Stream, otherwise false + */ +function isStream(val) { + return isObject(val) && isFunction(val.pipe); +} -var loggedTypeFailures = {}; -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; +/** + * Determine if a value is a URLSearchParams object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a URLSearchParams object, otherwise false + */ +function isURLSearchParams(val) { + return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams; } /** - * Provide a linked `value` attribute for controlled forms. You should not use - * this outside of the ReactDOM controlled form components. + * Trim excess whitespace off the beginning and end of a string + * + * @param {String} str The String to trim + * @returns {String} The String freed of excess whitespace */ -var LinkedValueUtils = { - checkPropTypes: function (tagName, props, owner) { - for (var propName in propTypes) { - if (propTypes.hasOwnProperty(propName)) { - var error = propTypes[propName](props, propName, tagName, 'prop', null, ReactPropTypesSecret); - } - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; +function trim(str) { + return str.replace(/^\s*/, '').replace(/\s*$/, ''); +} - var addendum = getDeclarationErrorAddendum(owner); - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed form propType: %s%s', error.message, addendum) : void 0; - } - } - }, - - /** - * @param {object} inputProps Props for form component - * @return {*} current value of the input either from value prop or link. - */ - getValue: function (inputProps) { - if (inputProps.valueLink) { - _assertValueLink(inputProps); - return inputProps.valueLink.value; - } - return inputProps.value; - }, - - /** - * @param {object} inputProps Props for form component - * @return {*} current checked status of the input either from checked prop - * or link. - */ - getChecked: function (inputProps) { - if (inputProps.checkedLink) { - _assertCheckedLink(inputProps); - return inputProps.checkedLink.value; - } - return inputProps.checked; - }, - - /** - * @param {object} inputProps Props for form component - * @param {SyntheticEvent} event change event to handle - */ - executeOnChange: function (inputProps, event) { - if (inputProps.valueLink) { - _assertValueLink(inputProps); - return inputProps.valueLink.requestChange(event.target.value); - } else if (inputProps.checkedLink) { - _assertCheckedLink(inputProps); - return inputProps.checkedLink.requestChange(event.target.checked); - } else if (inputProps.onChange) { - return inputProps.onChange.call(undefined, event); - } +/** + * Determine if we're running in a standard browser environment + * + * This allows axios to run in a web worker, and react-native. + * Both environments support XMLHttpRequest, but not fully standard globals. + * + * web workers: + * typeof window -> undefined + * typeof document -> undefined + * + * react-native: + * navigator.product -> 'ReactNative' + */ +function isStandardBrowserEnv() { + if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') { + return false; } -}; - -module.exports = LinkedValueUtils; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 59 */ -/***/ (function(module, exports, __webpack_require__) { + return ( + typeof window !== 'undefined' && + typeof document !== 'undefined' + ); +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. +/** + * Iterate over an Array or an Object invoking a function for each item. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * If `obj` is an Array callback will be called passing + * the value, index, and complete array for each item. * - * + * If 'obj' is an Object callback will be called passing + * the value, key, and complete object for each property. + * + * @param {Object|Array} obj The object to iterate + * @param {Function} fn The callback to invoke for each item */ +function forEach(obj, fn) { + // Don't bother if no value provided + if (obj === null || typeof obj === 'undefined') { + return; + } + // Force an array if not already something iterable + if (typeof obj !== 'object' && !isArray(obj)) { + /*eslint no-param-reassign:0*/ + obj = [obj]; + } - -var _prodInvariant = __webpack_require__(3); - -var invariant = __webpack_require__(1); - -var injected = false; - -var ReactComponentEnvironment = { - /** - * Optionally injectable hook for swapping out mount images in the middle of - * the tree. - */ - replaceNodeWithMarkup: null, - - /** - * Optionally injectable hook for processing a queue of child updates. Will - * later move into MultiChildComponents. - */ - processChildrenUpdates: null, - - injection: { - injectEnvironment: function (environment) { - !!injected ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactCompositeComponent: injectEnvironment() can only be called once.') : _prodInvariant('104') : void 0; - ReactComponentEnvironment.replaceNodeWithMarkup = environment.replaceNodeWithMarkup; - ReactComponentEnvironment.processChildrenUpdates = environment.processChildrenUpdates; - injected = true; + if (isArray(obj)) { + // Iterate over array values + for (var i = 0, l = obj.length; i < l; i++) { + fn.call(null, obj[i], i, obj); + } + } else { + // Iterate over object keys + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key)) { + fn.call(null, obj[key], key, obj); + } } } -}; - -module.exports = ReactComponentEnvironment; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 60 */ -/***/ (function(module, exports, __webpack_require__) { +} -"use strict"; /** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. + * Accepts varargs expecting each argument to be an object, then + * immutably merges the properties of each object and returns result. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * When multiple objects contain the same key the later object in + * the arguments list will take precedence. * - * @typechecks - * + * Example: + * + * ```js + * var result = merge({foo: 123}, {foo: 456}); + * console.log(result.foo); // outputs 456 + * ``` + * + * @param {Object} obj1 Object to merge + * @returns {Object} Result of all merge properties */ +function merge(/* obj1, obj2, obj3, ... */) { + var result = {}; + function assignValue(val, key) { + if (typeof result[key] === 'object' && typeof val === 'object') { + result[key] = merge(result[key], val); + } else { + result[key] = val; + } + } -/*eslint-disable no-self-compare */ - - - -var hasOwnProperty = Object.prototype.hasOwnProperty; - -/** - * inlined Object.is polyfill to avoid requiring consumers ship their own - * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is - */ -function is(x, y) { - // SameValue algorithm - if (x === y) { - // Steps 1-5, 7-10 - // Steps 6.b-6.e: +0 != -0 - // Added the nonzero y check to make Flow happy, but it is redundant - return x !== 0 || y !== 0 || 1 / x === 1 / y; - } else { - // Step 6.a: NaN == NaN - return x !== x && y !== y; + for (var i = 0, l = arguments.length; i < l; i++) { + forEach(arguments[i], assignValue); } + return result; } /** - * Performs equality by iterating through keys on an object and returning false - * when any key has values which are not strictly equal between the arguments. - * Returns true when the values of all keys are strictly equal. + * Extends object a by mutably adding to it the properties of object b. + * + * @param {Object} a The object to be extended + * @param {Object} b The object to copy properties from + * @param {Object} thisArg The object to bind function to + * @return {Object} The resulting value of object a */ -function shallowEqual(objA, objB) { - if (is(objA, objB)) { - return true; - } +function extend(a, b, thisArg) { + forEach(b, function assignValue(val, key) { + if (thisArg && typeof val === 'function') { + a[key] = bind(val, thisArg); + } else { + a[key] = val; + } + }); + return a; +} - if (typeof objA !== 'object' || objA === null || typeof objB !== 'object' || objB === null) { - return false; - } +module.exports = { + isArray: isArray, + isArrayBuffer: isArrayBuffer, + isBuffer: isBuffer, + isFormData: isFormData, + isArrayBufferView: isArrayBufferView, + isString: isString, + isNumber: isNumber, + isObject: isObject, + isUndefined: isUndefined, + isDate: isDate, + isFile: isFile, + isBlob: isBlob, + isFunction: isFunction, + isStream: isStream, + isURLSearchParams: isURLSearchParams, + isStandardBrowserEnv: isStandardBrowserEnv, + forEach: forEach, + merge: merge, + extend: extend, + trim: trim +}; - var keysA = Object.keys(objA); - var keysB = Object.keys(objB); - if (keysA.length !== keysB.length) { - return false; - } +/***/ }), +/* 21 */ +/***/ (function(module, exports) { - // Test for A's keys different from B. - for (var i = 0; i < keysA.length; i++) { - if (!hasOwnProperty.call(objB, keysA[i]) || !is(objA[keysA[i]], objB[keysA[i]])) { - return false; - } - } +module.exports = assert; - return true; +function assert(val, msg) { + if (!val) + throw new Error(msg || 'Assertion failed'); } -module.exports = shallowEqual; +assert.equal = function assertEqual(l, r, msg) { + if (l != r) + throw new Error(msg || ('Assertion failed: ' + l + ' != ' + r)); +}; + /***/ }), -/* 61 */ +/* 22 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -5929,46 +7566,33 @@ module.exports = shallowEqual; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ /** - * Given a `prevElement` and `nextElement`, determines if the existing - * instance should be updated as opposed to being destroyed or replaced by a new - * instance. Both arguments are elements. This ensures that this logic can - * operate on stateless trees without any backing instance. + * Keeps track of the current owner. * - * @param {?object} prevElement - * @param {?object} nextElement - * @return {boolean} True if the existing instance should be updated. - * @protected + * The current owner is the component who should own any components that are + * currently being constructed. */ +var ReactCurrentOwner = { + /** + * @internal + * @type {ReactComponent} + */ + current: null +}; -function shouldUpdateReactComponent(prevElement, nextElement) { - var prevEmpty = prevElement === null || prevElement === false; - var nextEmpty = nextElement === null || nextElement === false; - if (prevEmpty || nextEmpty) { - return prevEmpty === nextEmpty; - } - - var prevType = typeof prevElement; - var nextType = typeof nextElement; - if (prevType === 'string' || prevType === 'number') { - return nextType === 'string' || nextType === 'number'; - } else { - return nextType === 'object' && prevElement.type === nextElement.type && prevElement.key === nextElement.key; - } -} - -module.exports = shouldUpdateReactComponent; +module.exports = ReactCurrentOwner; /***/ }), -/* 62 */ +/* 23 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** +/* WEBPACK VAR INJECTION */(function(process) {/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -5976,304 +7600,544 @@ module.exports = shouldUpdateReactComponent; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -/** - * Escape and wrap key so it is safe to use as a reactid - * - * @param {string} key to be escaped. - * @return {string} the escaped key. - */ +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); -function escape(key) { - var escapeRegex = /[=:]/g; - var escaperLookup = { - '=': '=0', - ':': '=2' - }; - var escapedString = ('' + key).replace(escapeRegex, function (match) { - return escaperLookup[match]; - }); +var CallbackQueue = __webpack_require__(130); +var PooledClass = __webpack_require__(32); +var ReactFeatureFlags = __webpack_require__(131); +var ReactReconciler = __webpack_require__(38); +var Transaction = __webpack_require__(58); - return '$' + escapedString; -} +var invariant = __webpack_require__(2); -/** - * Unescape and unwrap key for human-readable display - * - * @param {string} key to unescape. - * @return {string} the unescaped key. - */ -function unescape(key) { - var unescapeRegex = /(=0|=2)/g; - var unescaperLookup = { - '=0': '=', - '=2': ':' - }; - var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); +var dirtyComponents = []; +var updateBatchNumber = 0; +var asapCallbackQueue = CallbackQueue.getPooled(); +var asapEnqueued = false; - return ('' + keySubstring).replace(unescapeRegex, function (match) { - return unescaperLookup[match]; - }); +var batchingStrategy = null; + +function ensureInjected() { + !(ReactUpdates.ReactReconcileTransaction && batchingStrategy) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must inject a reconcile transaction class and batching strategy') : _prodInvariant('123') : void 0; } -var KeyEscapeUtils = { - escape: escape, - unescape: unescape +var NESTED_UPDATES = { + initialize: function () { + this.dirtyComponentsLength = dirtyComponents.length; + }, + close: function () { + if (this.dirtyComponentsLength !== dirtyComponents.length) { + // Additional updates were enqueued by componentDidUpdate handlers or + // similar; before our own UPDATE_QUEUEING wrapper closes, we want to run + // these new updates so that if A's componentDidUpdate calls setState on + // B, B will update before the callback A's updater provided when calling + // setState. + dirtyComponents.splice(0, this.dirtyComponentsLength); + flushBatchedUpdates(); + } else { + dirtyComponents.length = 0; + } + } }; -module.exports = KeyEscapeUtils; +var UPDATE_QUEUEING = { + initialize: function () { + this.callbackQueue.reset(); + }, + close: function () { + this.callbackQueue.notifyAll(); + } +}; -/***/ }), -/* 63 */ -/***/ (function(module, exports, __webpack_require__) { +var TRANSACTION_WRAPPERS = [NESTED_UPDATES, UPDATE_QUEUEING]; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +function ReactUpdatesFlushTransaction() { + this.reinitializeTransaction(); + this.dirtyComponentsLength = null; + this.callbackQueue = CallbackQueue.getPooled(); + this.reconcileTransaction = ReactUpdates.ReactReconcileTransaction.getPooled( + /* useCreateElement */true); +} + +_assign(ReactUpdatesFlushTransaction.prototype, Transaction, { + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, + + destructor: function () { + this.dirtyComponentsLength = null; + CallbackQueue.release(this.callbackQueue); + this.callbackQueue = null; + ReactUpdates.ReactReconcileTransaction.release(this.reconcileTransaction); + this.reconcileTransaction = null; + }, + + perform: function (method, scope, a) { + // Essentially calls `this.reconcileTransaction.perform(method, scope, a)` + // with this transaction's wrappers around it. + return Transaction.perform.call(this, this.reconcileTransaction.perform, this.reconcileTransaction, method, scope, a); + } +}); + +PooledClass.addPoolingTo(ReactUpdatesFlushTransaction); + +function batchedUpdates(callback, a, b, c, d, e) { + ensureInjected(); + return batchingStrategy.batchedUpdates(callback, a, b, c, d, e); +} + +/** + * Array comparator for ReactComponents by mount ordering. * + * @param {ReactComponent} c1 first component you're comparing + * @param {ReactComponent} c2 second component you're comparing + * @return {number} Return value usable by Array.prototype.sort(). */ +function mountOrderComparator(c1, c2) { + return c1._mountOrder - c2._mountOrder; +} +function runBatchedUpdates(transaction) { + var len = transaction.dirtyComponentsLength; + !(len === dirtyComponents.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected flush transaction\'s stored dirty-components length (%s) to match dirty-components array length (%s).', len, dirtyComponents.length) : _prodInvariant('124', len, dirtyComponents.length) : void 0; + // Since reconciling a component higher in the owner hierarchy usually (not + // always -- see shouldComponentUpdate()) will reconcile children, reconcile + // them before their children by sorting the array. + dirtyComponents.sort(mountOrderComparator); -var _prodInvariant = __webpack_require__(3); + // Any updates enqueued while reconciling must be performed after this entire + // batch. Otherwise, if dirtyComponents is [A, B] where A has children B and + // C, B could update twice in a single batch if C's render enqueues an update + // to B (since B would have already updated, we should skip it, and the only + // way we can know to do so is by checking the batch counter). + updateBatchNumber++; -var ReactCurrentOwner = __webpack_require__(14); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactUpdates = __webpack_require__(15); + for (var i = 0; i < len; i++) { + // If a component is unmounted before pending changes apply, it will still + // be here, but we assume that it has cleared its _pendingCallbacks and + // that performUpdateIfNecessary is a noop. + var component = dirtyComponents[i]; -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); + // If performUpdateIfNecessary happens to enqueue any new updates, we + // shouldn't execute the callbacks until the next render happens, so + // stash the callbacks first + var callbacks = component._pendingCallbacks; + component._pendingCallbacks = null; -function enqueueUpdate(internalInstance) { - ReactUpdates.enqueueUpdate(internalInstance); -} + var markerName; + if (ReactFeatureFlags.logTopLevelRenders) { + var namedComponent = component; + // Duck type TopLevelWrapper. This is probably always true. + if (component._currentElement.type.isReactTopLevelWrapper) { + namedComponent = component._renderedComponent; + } + markerName = 'React update: ' + namedComponent.getName(); + console.time(markerName); + } -function formatUnexpectedArgument(arg) { - var type = typeof arg; - if (type !== 'object') { - return type; - } - var displayName = arg.constructor && arg.constructor.name || type; - var keys = Object.keys(arg); - if (keys.length > 0 && keys.length < 20) { - return displayName + ' (keys: ' + keys.join(', ') + ')'; + ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction, updateBatchNumber); + + if (markerName) { + console.timeEnd(markerName); + } + + if (callbacks) { + for (var j = 0; j < callbacks.length; j++) { + transaction.callbackQueue.enqueue(callbacks[j], component.getPublicInstance()); + } + } } - return displayName; } -function getInternalInstanceReadyForUpdate(publicInstance, callerName) { - var internalInstance = ReactInstanceMap.get(publicInstance); - if (!internalInstance) { - if (process.env.NODE_ENV !== 'production') { - var ctor = publicInstance.constructor; - // Only warn when we have a callerName. Otherwise we should be silent. - // We're probably calling from enqueueCallback. We don't want to warn - // there because we already warned for the corresponding lifecycle method. - process.env.NODE_ENV !== 'production' ? warning(!callerName, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, ctor && (ctor.displayName || ctor.name) || 'ReactClass') : void 0; +var flushBatchedUpdates = function () { + // ReactUpdatesFlushTransaction's wrappers will clear the dirtyComponents + // array and perform any updates enqueued by mount-ready handlers (i.e., + // componentDidUpdate) but we need to check here too in order to catch + // updates enqueued by setState callbacks and asap calls. + while (dirtyComponents.length || asapEnqueued) { + if (dirtyComponents.length) { + var transaction = ReactUpdatesFlushTransaction.getPooled(); + transaction.perform(runBatchedUpdates, null, transaction); + ReactUpdatesFlushTransaction.release(transaction); + } + + if (asapEnqueued) { + asapEnqueued = false; + var queue = asapCallbackQueue; + asapCallbackQueue = CallbackQueue.getPooled(); + queue.notifyAll(); + CallbackQueue.release(queue); } - return null; } +}; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '%s(...): Cannot update during an existing state transition (such as ' + "within `render` or another component's constructor). Render methods " + 'should be a pure function of props and state; constructor ' + 'side-effects are an anti-pattern, but can be moved to ' + '`componentWillMount`.', callerName) : void 0; +/** + * Mark a component as needing a rerender, adding an optional callback to a + * list of functions which will be executed once the rerender occurs. + */ +function enqueueUpdate(component) { + ensureInjected(); + + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. (This is called by each top-level update + // function, like setState, forceUpdate, etc.; creation and + // destruction of top-level components is guarded in ReactMount.) + + if (!batchingStrategy.isBatchingUpdates) { + batchingStrategy.batchedUpdates(enqueueUpdate, component); + return; } - return internalInstance; + dirtyComponents.push(component); + if (component._updateBatchNumber == null) { + component._updateBatchNumber = updateBatchNumber + 1; + } } /** - * ReactUpdateQueue allows for state updates to be scheduled into a later - * reconciliation step. + * Enqueue a callback to be run at the end of the current batching cycle. Throws + * if no updates are currently being performed. */ -var ReactUpdateQueue = { - /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function (publicInstance) { - if (process.env.NODE_ENV !== 'production') { - var owner = ReactCurrentOwner.current; - if (owner !== null) { - process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing isMounted inside its render() function. ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; - owner._warnedAboutRefsInRender = true; - } - } - var internalInstance = ReactInstanceMap.get(publicInstance); - if (internalInstance) { - // During componentWillMount and render this will still be null but after - // that will always render to something. At least for now. So we can use - // this hack. - return !!internalInstance._renderedComponent; - } else { - return false; - } +function asap(callback, context) { + !batchingStrategy.isBatchingUpdates ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates.asap: Can\'t enqueue an asap callback in a context whereupdates are not being batched.') : _prodInvariant('125') : void 0; + asapCallbackQueue.enqueue(callback, context); + asapEnqueued = true; +} + +var ReactUpdatesInjection = { + injectReconcileTransaction: function (ReconcileTransaction) { + !ReconcileTransaction ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a reconcile transaction class') : _prodInvariant('126') : void 0; + ReactUpdates.ReactReconcileTransaction = ReconcileTransaction; }, + injectBatchingStrategy: function (_batchingStrategy) { + !_batchingStrategy ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batching strategy') : _prodInvariant('127') : void 0; + !(typeof _batchingStrategy.batchedUpdates === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batchedUpdates() function') : _prodInvariant('128') : void 0; + !(typeof _batchingStrategy.isBatchingUpdates === 'boolean') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide an isBatchingUpdates boolean attribute') : _prodInvariant('129') : void 0; + batchingStrategy = _batchingStrategy; + } +}; + +var ReactUpdates = { /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. + * React references `ReactReconcileTransaction` using this property in order + * to allow dependency injection. * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @param {string} callerName Name of the calling function in the public API. * @internal */ - enqueueCallback: function (publicInstance, callback, callerName) { - ReactUpdateQueue.validateCallback(callback, callerName); - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance); + ReactReconcileTransaction: null, - // Previously we would throw an error if we didn't have an internal - // instance. Since we want to make it a no-op instead, we mirror the same - // behavior we have in other enqueue* methods. - // We also need to ignore callbacks in componentWillMount. See - // enqueueUpdates. - if (!internalInstance) { - return null; - } + batchedUpdates: batchedUpdates, + enqueueUpdate: enqueueUpdate, + flushBatchedUpdates: flushBatchedUpdates, + injection: ReactUpdatesInjection, + asap: asap +}; - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); - } else { - internalInstance._pendingCallbacks = [callback]; +module.exports = ReactUpdates; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 24 */ +/***/ (function(module, exports) { + +var g; + +// This works in non-strict mode +g = (function() { + return this; +})(); + +try { + // This works if eval is allowed (see CSP) + g = g || Function("return this")() || (1,eval)("this"); +} catch(e) { + // This works if the window reference is available + if(typeof window === "object") + g = window; +} + +// g can still be undefined, but nothing to do about it... +// We return undefined, instead of nothing here, so it's +// easier to handle this case. if(!global) { ...} + +module.exports = g; + + +/***/ }), +/* 25 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); + +exports.inherits = inherits; + +function toArray(msg, enc) { + if (Array.isArray(msg)) + return msg.slice(); + if (!msg) + return []; + var res = []; + if (typeof msg === 'string') { + if (!enc) { + for (var i = 0; i < msg.length; i++) { + var c = msg.charCodeAt(i); + var hi = c >> 8; + var lo = c & 0xff; + if (hi) + res.push(hi, lo); + else + res.push(lo); + } + } else if (enc === 'hex') { + msg = msg.replace(/[^a-z0-9]+/ig, ''); + if (msg.length % 2 !== 0) + msg = '0' + msg; + for (i = 0; i < msg.length; i += 2) + res.push(parseInt(msg[i] + msg[i + 1], 16)); } - // TODO: The callback here is ignored when setState is called from - // componentWillMount. Either fix it or disallow doing so completely in - // favor of getInitialState. Alternatively, we can disallow - // componentWillMount during server-side rendering. - enqueueUpdate(internalInstance); - }, + } else { + for (i = 0; i < msg.length; i++) + res[i] = msg[i] | 0; + } + return res; +} +exports.toArray = toArray; - enqueueCallbackInternal: function (internalInstance, callback) { - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); +function toHex(msg) { + var res = ''; + for (var i = 0; i < msg.length; i++) + res += zero2(msg[i].toString(16)); + return res; +} +exports.toHex = toHex; + +function htonl(w) { + var res = (w >>> 24) | + ((w >>> 8) & 0xff00) | + ((w << 8) & 0xff0000) | + ((w & 0xff) << 24); + return res >>> 0; +} +exports.htonl = htonl; + +function toHex32(msg, endian) { + var res = ''; + for (var i = 0; i < msg.length; i++) { + var w = msg[i]; + if (endian === 'little') + w = htonl(w); + res += zero8(w.toString(16)); + } + return res; +} +exports.toHex32 = toHex32; + +function zero2(word) { + if (word.length === 1) + return '0' + word; + else + return word; +} +exports.zero2 = zero2; + +function zero8(word) { + if (word.length === 7) + return '0' + word; + else if (word.length === 6) + return '00' + word; + else if (word.length === 5) + return '000' + word; + else if (word.length === 4) + return '0000' + word; + else if (word.length === 3) + return '00000' + word; + else if (word.length === 2) + return '000000' + word; + else if (word.length === 1) + return '0000000' + word; + else + return word; +} +exports.zero8 = zero8; + +function join32(msg, start, end, endian) { + var len = end - start; + assert(len % 4 === 0); + var res = new Array(len / 4); + for (var i = 0, k = start; i < res.length; i++, k += 4) { + var w; + if (endian === 'big') + w = (msg[k] << 24) | (msg[k + 1] << 16) | (msg[k + 2] << 8) | msg[k + 3]; + else + w = (msg[k + 3] << 24) | (msg[k + 2] << 16) | (msg[k + 1] << 8) | msg[k]; + res[i] = w >>> 0; + } + return res; +} +exports.join32 = join32; + +function split32(msg, endian) { + var res = new Array(msg.length * 4); + for (var i = 0, k = 0; i < msg.length; i++, k += 4) { + var m = msg[i]; + if (endian === 'big') { + res[k] = m >>> 24; + res[k + 1] = (m >>> 16) & 0xff; + res[k + 2] = (m >>> 8) & 0xff; + res[k + 3] = m & 0xff; } else { - internalInstance._pendingCallbacks = [callback]; + res[k + 3] = m >>> 24; + res[k + 2] = (m >>> 16) & 0xff; + res[k + 1] = (m >>> 8) & 0xff; + res[k] = m & 0xff; } - enqueueUpdate(internalInstance); - }, + } + return res; +} +exports.split32 = split32; - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal - */ - enqueueForceUpdate: function (publicInstance) { - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'forceUpdate'); +function rotr32(w, b) { + return (w >>> b) | (w << (32 - b)); +} +exports.rotr32 = rotr32; - if (!internalInstance) { - return; - } +function rotl32(w, b) { + return (w << b) | (w >>> (32 - b)); +} +exports.rotl32 = rotl32; - internalInstance._pendingForceUpdate = true; +function sum32(a, b) { + return (a + b) >>> 0; +} +exports.sum32 = sum32; - enqueueUpdate(internalInstance); - }, +function sum32_3(a, b, c) { + return (a + b + c) >>> 0; +} +exports.sum32_3 = sum32_3; - /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} completeState Next state. - * @internal - */ - enqueueReplaceState: function (publicInstance, completeState, callback) { - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'replaceState'); +function sum32_4(a, b, c, d) { + return (a + b + c + d) >>> 0; +} +exports.sum32_4 = sum32_4; - if (!internalInstance) { - return; - } +function sum32_5(a, b, c, d, e) { + return (a + b + c + d + e) >>> 0; +} +exports.sum32_5 = sum32_5; - internalInstance._pendingStateQueue = [completeState]; - internalInstance._pendingReplaceState = true; +function sum64(buf, pos, ah, al) { + var bh = buf[pos]; + var bl = buf[pos + 1]; - // Future-proof 15.5 - if (callback !== undefined && callback !== null) { - ReactUpdateQueue.validateCallback(callback, 'replaceState'); - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); - } else { - internalInstance._pendingCallbacks = [callback]; - } - } + var lo = (al + bl) >>> 0; + var hi = (lo < al ? 1 : 0) + ah + bh; + buf[pos] = hi >>> 0; + buf[pos + 1] = lo; +} +exports.sum64 = sum64; - enqueueUpdate(internalInstance); - }, +function sum64_hi(ah, al, bh, bl) { + var lo = (al + bl) >>> 0; + var hi = (lo < al ? 1 : 0) + ah + bh; + return hi >>> 0; +} +exports.sum64_hi = sum64_hi; - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} partialState Next partial state to be merged with state. - * @internal - */ - enqueueSetState: function (publicInstance, partialState) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetState(); - process.env.NODE_ENV !== 'production' ? warning(partialState != null, 'setState(...): You passed an undefined or null state object; ' + 'instead, use forceUpdate().') : void 0; - } +function sum64_lo(ah, al, bh, bl) { + var lo = al + bl; + return lo >>> 0; +} +exports.sum64_lo = sum64_lo; + +function sum64_4_hi(ah, al, bh, bl, ch, cl, dh, dl) { + var carry = 0; + var lo = al; + lo = (lo + bl) >>> 0; + carry += lo < al ? 1 : 0; + lo = (lo + cl) >>> 0; + carry += lo < cl ? 1 : 0; + lo = (lo + dl) >>> 0; + carry += lo < dl ? 1 : 0; + + var hi = ah + bh + ch + dh + carry; + return hi >>> 0; +} +exports.sum64_4_hi = sum64_4_hi; - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'setState'); +function sum64_4_lo(ah, al, bh, bl, ch, cl, dh, dl) { + var lo = al + bl + cl + dl; + return lo >>> 0; +} +exports.sum64_4_lo = sum64_4_lo; + +function sum64_5_hi(ah, al, bh, bl, ch, cl, dh, dl, eh, el) { + var carry = 0; + var lo = al; + lo = (lo + bl) >>> 0; + carry += lo < al ? 1 : 0; + lo = (lo + cl) >>> 0; + carry += lo < cl ? 1 : 0; + lo = (lo + dl) >>> 0; + carry += lo < dl ? 1 : 0; + lo = (lo + el) >>> 0; + carry += lo < el ? 1 : 0; + + var hi = ah + bh + ch + dh + eh + carry; + return hi >>> 0; +} +exports.sum64_5_hi = sum64_5_hi; - if (!internalInstance) { - return; - } +function sum64_5_lo(ah, al, bh, bl, ch, cl, dh, dl, eh, el) { + var lo = al + bl + cl + dl + el; - var queue = internalInstance._pendingStateQueue || (internalInstance._pendingStateQueue = []); - queue.push(partialState); + return lo >>> 0; +} +exports.sum64_5_lo = sum64_5_lo; - enqueueUpdate(internalInstance); - }, +function rotr64_hi(ah, al, num) { + var r = (al << (32 - num)) | (ah >>> num); + return r >>> 0; +} +exports.rotr64_hi = rotr64_hi; - enqueueElementInternal: function (internalInstance, nextElement, nextContext) { - internalInstance._pendingElement = nextElement; - // TODO: introduce _pendingContext instead of setting it directly. - internalInstance._context = nextContext; - enqueueUpdate(internalInstance); - }, +function rotr64_lo(ah, al, num) { + var r = (ah << (32 - num)) | (al >>> num); + return r >>> 0; +} +exports.rotr64_lo = rotr64_lo; - validateCallback: function (callback, callerName) { - !(!callback || typeof callback === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.', callerName, formatUnexpectedArgument(callback)) : _prodInvariant('122', callerName, formatUnexpectedArgument(callback)) : void 0; - } -}; +function shr64_hi(ah, al, num) { + return ah >>> num; +} +exports.shr64_hi = shr64_hi; + +function shr64_lo(ah, al, num) { + var r = (ah << (32 - num)) | (al >>> num); + return r >>> 0; +} +exports.shr64_lo = shr64_lo; -module.exports = ReactUpdateQueue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 64 */ +/* 26 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -6284,372 +8148,327 @@ module.exports = ReactUpdateQueue; -var _assign = __webpack_require__(5); - -var emptyFunction = __webpack_require__(12); -var warning = __webpack_require__(2); - -var validateDOMNesting = emptyFunction; - -if (process.env.NODE_ENV !== 'production') { - // This validation code was written based on the HTML5 parsing spec: - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope - // - // Note: this does not catch all invalid nesting, nor does it try to (as it's - // not clear what practical benefit doing so provides); instead, we warn only - // for cases where the parser will give a parse tree differing from what React - // intended. For example,
is invalid but we don't warn - // because it still parses correctly; we do warn for other cases like nested - //

tags where the beginning of the second element implicitly closes the - // first, causing a confusing mess. - - // https://html.spec.whatwg.org/multipage/syntax.html#special - var specialTags = ['address', 'applet', 'area', 'article', 'aside', 'base', 'basefont', 'bgsound', 'blockquote', 'body', 'br', 'button', 'caption', 'center', 'col', 'colgroup', 'dd', 'details', 'dir', 'div', 'dl', 'dt', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'frame', 'frameset', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'iframe', 'img', 'input', 'isindex', 'li', 'link', 'listing', 'main', 'marquee', 'menu', 'menuitem', 'meta', 'nav', 'noembed', 'noframes', 'noscript', 'object', 'ol', 'p', 'param', 'plaintext', 'pre', 'script', 'section', 'select', 'source', 'style', 'summary', 'table', 'tbody', 'td', 'template', 'textarea', 'tfoot', 'th', 'thead', 'title', 'tr', 'track', 'ul', 'wbr', 'xmp']; - - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope - var inScopeTags = ['applet', 'caption', 'html', 'table', 'td', 'th', 'marquee', 'object', 'template', +var _assign = __webpack_require__(8); - // https://html.spec.whatwg.org/multipage/syntax.html#html-integration-point - // TODO: Distinguish by namespace here -- for , including it here - // errs on the side of fewer warnings - 'foreignObject', 'desc', 'title']; +var PooledClass = __webpack_require__(32); - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-button-scope - var buttonScopeTags = inScopeTags.concat(['button']); +var emptyFunction = __webpack_require__(18); +var warning = __webpack_require__(3); - // https://html.spec.whatwg.org/multipage/syntax.html#generate-implied-end-tags - var impliedEndTags = ['dd', 'dt', 'li', 'option', 'optgroup', 'p', 'rp', 'rt']; +var didWarnForAddedNewProperty = false; +var isProxySupported = typeof Proxy === 'function'; - var emptyAncestorInfo = { - current: null, +var shouldBeReleasedProperties = ['dispatchConfig', '_targetInst', 'nativeEvent', 'isDefaultPrevented', 'isPropagationStopped', '_dispatchListeners', '_dispatchInstances']; - formTag: null, - aTagInScope: null, - buttonTagInScope: null, - nobrTagInScope: null, - pTagInButtonScope: null, +/** + * @interface Event + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var EventInterface = { + type: null, + target: null, + // currentTarget is set when dispatching; no use in copying it here + currentTarget: emptyFunction.thatReturnsNull, + eventPhase: null, + bubbles: null, + cancelable: null, + timeStamp: function (event) { + return event.timeStamp || Date.now(); + }, + defaultPrevented: null, + isTrusted: null +}; - listItemTagAutoclosing: null, - dlItemTagAutoclosing: null - }; +/** + * Synthetic events are dispatched by event plugins, typically in response to a + * top-level event delegation handler. + * + * These systems should generally use pooling to reduce the frequency of garbage + * collection. The system should check `isPersistent` to determine whether the + * event should be released into the pool after being dispatched. Users that + * need a persisted event should invoke `persist`. + * + * Synthetic events (and subclasses) implement the DOM Level 3 Events API by + * normalizing browser quirks. Subclasses do not necessarily have to implement a + * DOM interface; custom application-specific events can also subclass this. + * + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {*} targetInst Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @param {DOMEventTarget} nativeEventTarget Target node. + */ +function SyntheticEvent(dispatchConfig, targetInst, nativeEvent, nativeEventTarget) { + if (process.env.NODE_ENV !== 'production') { + // these have a getter/setter for warnings + delete this.nativeEvent; + delete this.preventDefault; + delete this.stopPropagation; + } - var updatedAncestorInfo = function (oldInfo, tag, instance) { - var ancestorInfo = _assign({}, oldInfo || emptyAncestorInfo); - var info = { tag: tag, instance: instance }; + this.dispatchConfig = dispatchConfig; + this._targetInst = targetInst; + this.nativeEvent = nativeEvent; - if (inScopeTags.indexOf(tag) !== -1) { - ancestorInfo.aTagInScope = null; - ancestorInfo.buttonTagInScope = null; - ancestorInfo.nobrTagInScope = null; + var Interface = this.constructor.Interface; + for (var propName in Interface) { + if (!Interface.hasOwnProperty(propName)) { + continue; } - if (buttonScopeTags.indexOf(tag) !== -1) { - ancestorInfo.pTagInButtonScope = null; + if (process.env.NODE_ENV !== 'production') { + delete this[propName]; // this has a getter/setter for warnings } - - // See rules for 'li', 'dd', 'dt' start tags in - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody - if (specialTags.indexOf(tag) !== -1 && tag !== 'address' && tag !== 'div' && tag !== 'p') { - ancestorInfo.listItemTagAutoclosing = null; - ancestorInfo.dlItemTagAutoclosing = null; + var normalize = Interface[propName]; + if (normalize) { + this[propName] = normalize(nativeEvent); + } else { + if (propName === 'target') { + this.target = nativeEventTarget; + } else { + this[propName] = nativeEvent[propName]; + } } + } - ancestorInfo.current = info; + var defaultPrevented = nativeEvent.defaultPrevented != null ? nativeEvent.defaultPrevented : nativeEvent.returnValue === false; + if (defaultPrevented) { + this.isDefaultPrevented = emptyFunction.thatReturnsTrue; + } else { + this.isDefaultPrevented = emptyFunction.thatReturnsFalse; + } + this.isPropagationStopped = emptyFunction.thatReturnsFalse; + return this; +} - if (tag === 'form') { - ancestorInfo.formTag = info; - } - if (tag === 'a') { - ancestorInfo.aTagInScope = info; - } - if (tag === 'button') { - ancestorInfo.buttonTagInScope = info; - } - if (tag === 'nobr') { - ancestorInfo.nobrTagInScope = info; +_assign(SyntheticEvent.prototype, { + preventDefault: function () { + this.defaultPrevented = true; + var event = this.nativeEvent; + if (!event) { + return; } - if (tag === 'p') { - ancestorInfo.pTagInButtonScope = info; + + if (event.preventDefault) { + event.preventDefault(); + // eslint-disable-next-line valid-typeof + } else if (typeof event.returnValue !== 'unknown') { + event.returnValue = false; } - if (tag === 'li') { - ancestorInfo.listItemTagAutoclosing = info; + this.isDefaultPrevented = emptyFunction.thatReturnsTrue; + }, + + stopPropagation: function () { + var event = this.nativeEvent; + if (!event) { + return; } - if (tag === 'dd' || tag === 'dt') { - ancestorInfo.dlItemTagAutoclosing = info; + + if (event.stopPropagation) { + event.stopPropagation(); + // eslint-disable-next-line valid-typeof + } else if (typeof event.cancelBubble !== 'unknown') { + // The ChangeEventPlugin registers a "propertychange" event for + // IE. This event does not support bubbling or cancelling, and + // any references to cancelBubble throw "Member not found". A + // typeof check of "unknown" circumvents this issue (and is also + // IE specific). + event.cancelBubble = true; } - return ancestorInfo; - }; + this.isPropagationStopped = emptyFunction.thatReturnsTrue; + }, /** - * Returns whether + * We release all dispatched `SyntheticEvent`s after each event loop, adding + * them back into the pool. This allows a way to hold onto a reference that + * won't be added back into the pool. */ - var isTagValidWithParent = function (tag, parentTag) { - // First, let's check if we're in an unusual parsing mode... - switch (parentTag) { - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inselect - case 'select': - return tag === 'option' || tag === 'optgroup' || tag === '#text'; - case 'optgroup': - return tag === 'option' || tag === '#text'; - // Strictly speaking, seeing an <option> doesn't mean we're in a <select> - // but - case 'option': - return tag === '#text'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intd - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incaption - // No special behavior since these rules fall back to "in body" mode for - // all except special table nodes which cause bad parsing behavior anyway. + persist: function () { + this.isPersistent = emptyFunction.thatReturnsTrue; + }, - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intr - case 'tr': - return tag === 'th' || tag === 'td' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intbody - case 'tbody': - case 'thead': - case 'tfoot': - return tag === 'tr' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incolgroup - case 'colgroup': - return tag === 'col' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intable - case 'table': - return tag === 'caption' || tag === 'colgroup' || tag === 'tbody' || tag === 'tfoot' || tag === 'thead' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inhead - case 'head': - return tag === 'base' || tag === 'basefont' || tag === 'bgsound' || tag === 'link' || tag === 'meta' || tag === 'title' || tag === 'noscript' || tag === 'noframes' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/semantics.html#the-html-element - case 'html': - return tag === 'head' || tag === 'body'; - case '#document': - return tag === 'html'; + /** + * Checks if this event should be released back into the pool. + * + * @return {boolean} True if this should not be released, false otherwise. + */ + isPersistent: emptyFunction.thatReturnsFalse, + + /** + * `PooledClass` looks for `destructor` on each instance it releases. + */ + destructor: function () { + var Interface = this.constructor.Interface; + for (var propName in Interface) { + if (process.env.NODE_ENV !== 'production') { + Object.defineProperty(this, propName, getPooledWarningPropertyDefinition(propName, Interface[propName])); + } else { + this[propName] = null; + } + } + for (var i = 0; i < shouldBeReleasedProperties.length; i++) { + this[shouldBeReleasedProperties[i]] = null; + } + if (process.env.NODE_ENV !== 'production') { + Object.defineProperty(this, 'nativeEvent', getPooledWarningPropertyDefinition('nativeEvent', null)); + Object.defineProperty(this, 'preventDefault', getPooledWarningPropertyDefinition('preventDefault', emptyFunction)); + Object.defineProperty(this, 'stopPropagation', getPooledWarningPropertyDefinition('stopPropagation', emptyFunction)); } + } +}); - // Probably in the "in body" parsing mode, so we outlaw only tag combos - // where the parsing rules cause implicit opens or closes to be added. - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody - switch (tag) { - case 'h1': - case 'h2': - case 'h3': - case 'h4': - case 'h5': - case 'h6': - return parentTag !== 'h1' && parentTag !== 'h2' && parentTag !== 'h3' && parentTag !== 'h4' && parentTag !== 'h5' && parentTag !== 'h6'; +SyntheticEvent.Interface = EventInterface; - case 'rp': - case 'rt': - return impliedEndTags.indexOf(parentTag) === -1; +if (process.env.NODE_ENV !== 'production') { + if (isProxySupported) { + /*eslint-disable no-func-assign */ + SyntheticEvent = new Proxy(SyntheticEvent, { + construct: function (target, args) { + return this.apply(target, Object.create(target.prototype), args); + }, + apply: function (constructor, that, args) { + return new Proxy(constructor.apply(that, args), { + set: function (target, prop, value) { + if (prop !== 'isPersistent' && !target.constructor.Interface.hasOwnProperty(prop) && shouldBeReleasedProperties.indexOf(prop) === -1) { + process.env.NODE_ENV !== 'production' ? warning(didWarnForAddedNewProperty || target.isPersistent(), "This synthetic event is reused for performance reasons. If you're " + "seeing this, you're adding a new property in the synthetic event object. " + 'The property is never released. See ' + 'https://fb.me/react-event-pooling for more information.') : void 0; + didWarnForAddedNewProperty = true; + } + target[prop] = value; + return true; + } + }); + } + }); + /*eslint-enable no-func-assign */ + } +} +/** + * Helper to reduce boilerplate when creating subclasses. + * + * @param {function} Class + * @param {?object} Interface + */ +SyntheticEvent.augmentClass = function (Class, Interface) { + var Super = this; - case 'body': - case 'caption': - case 'col': - case 'colgroup': - case 'frame': - case 'head': - case 'html': - case 'tbody': - case 'td': - case 'tfoot': - case 'th': - case 'thead': - case 'tr': - // These tags are only valid with a few parents that have special child - // parsing rules -- if we're down here, then none of those matched and - // so we allow it only if we don't know what the parent is, as all other - // cases are invalid. - return parentTag == null; - } + var E = function () {}; + E.prototype = Super.prototype; + var prototype = new E(); - return true; - }; + _assign(prototype, Class.prototype); + Class.prototype = prototype; + Class.prototype.constructor = Class; - /** - * Returns whether - */ - var findInvalidAncestorForTag = function (tag, ancestorInfo) { - switch (tag) { - case 'address': - case 'article': - case 'aside': - case 'blockquote': - case 'center': - case 'details': - case 'dialog': - case 'dir': - case 'div': - case 'dl': - case 'fieldset': - case 'figcaption': - case 'figure': - case 'footer': - case 'header': - case 'hgroup': - case 'main': - case 'menu': - case 'nav': - case 'ol': - case 'p': - case 'section': - case 'summary': - case 'ul': - case 'pre': - case 'listing': - case 'table': - case 'hr': - case 'xmp': - case 'h1': - case 'h2': - case 'h3': - case 'h4': - case 'h5': - case 'h6': - return ancestorInfo.pTagInButtonScope; - - case 'form': - return ancestorInfo.formTag || ancestorInfo.pTagInButtonScope; + Class.Interface = _assign({}, Super.Interface, Interface); + Class.augmentClass = Super.augmentClass; - case 'li': - return ancestorInfo.listItemTagAutoclosing; + PooledClass.addPoolingTo(Class, PooledClass.fourArgumentPooler); +}; - case 'dd': - case 'dt': - return ancestorInfo.dlItemTagAutoclosing; +PooledClass.addPoolingTo(SyntheticEvent, PooledClass.fourArgumentPooler); - case 'button': - return ancestorInfo.buttonTagInScope; +module.exports = SyntheticEvent; - case 'a': - // Spec says something about storing a list of markers, but it sounds - // equivalent to this check. - return ancestorInfo.aTagInScope; +/** + * Helper to nullify syntheticEvent instance properties when destructing + * + * @param {object} SyntheticEvent + * @param {String} propName + * @return {object} defineProperty object + */ +function getPooledWarningPropertyDefinition(propName, getVal) { + var isFunction = typeof getVal === 'function'; + return { + configurable: true, + set: set, + get: get + }; - case 'nobr': - return ancestorInfo.nobrTagInScope; - } + function set(val) { + var action = isFunction ? 'setting the method' : 'setting the property'; + warn(action, 'This is effectively a no-op'); + return val; + } - return null; - }; + function get() { + var action = isFunction ? 'accessing the method' : 'accessing the property'; + var result = isFunction ? 'This is a no-op function' : 'This is set to null'; + warn(action, result); + return getVal; + } - /** - * Given a ReactCompositeComponent instance, return a list of its recursive - * owners, starting at the root and ending with the instance itself. - */ - var findOwnerStack = function (instance) { - if (!instance) { - return []; - } + function warn(action, result) { + var warningCondition = false; + process.env.NODE_ENV !== 'production' ? warning(warningCondition, "This synthetic event is reused for performance reasons. If you're seeing this, " + "you're %s `%s` on a released/nullified synthetic event. %s. " + 'If you must keep the original synthetic event around, use event.persist(). ' + 'See https://fb.me/react-event-pooling for more information.', action, propName, result) : void 0; + } +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var stack = []; - do { - stack.push(instance); - } while (instance = instance._currentElement._owner); - stack.reverse(); - return stack; - }; +/***/ }), +/* 27 */ +/***/ (function(module, exports, __webpack_require__) { - var didWarn = {}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var inherits = __webpack_require__(4) +var md5 = __webpack_require__(63) +var RIPEMD160 = __webpack_require__(97) +var sha = __webpack_require__(103) - validateDOMNesting = function (childTag, childText, childInstance, ancestorInfo) { - ancestorInfo = ancestorInfo || emptyAncestorInfo; - var parentInfo = ancestorInfo.current; - var parentTag = parentInfo && parentInfo.tag; +var Base = __webpack_require__(29) - if (childText != null) { - process.env.NODE_ENV !== 'production' ? warning(childTag == null, 'validateDOMNesting: when childText is passed, childTag should be null') : void 0; - childTag = '#text'; - } +function HashNoConstructor (hash) { + Base.call(this, 'digest') - var invalidParent = isTagValidWithParent(childTag, parentTag) ? null : parentInfo; - var invalidAncestor = invalidParent ? null : findInvalidAncestorForTag(childTag, ancestorInfo); - var problematic = invalidParent || invalidAncestor; + this._hash = hash + this.buffers = [] +} - if (problematic) { - var ancestorTag = problematic.tag; - var ancestorInstance = problematic.instance; +inherits(HashNoConstructor, Base) - var childOwner = childInstance && childInstance._currentElement._owner; - var ancestorOwner = ancestorInstance && ancestorInstance._currentElement._owner; +HashNoConstructor.prototype._update = function (data) { + this.buffers.push(data) +} - var childOwners = findOwnerStack(childOwner); - var ancestorOwners = findOwnerStack(ancestorOwner); +HashNoConstructor.prototype._final = function () { + var buf = Buffer.concat(this.buffers) + var r = this._hash(buf) + this.buffers = null - var minStackLen = Math.min(childOwners.length, ancestorOwners.length); - var i; + return r +} - var deepestCommon = -1; - for (i = 0; i < minStackLen; i++) { - if (childOwners[i] === ancestorOwners[i]) { - deepestCommon = i; - } else { - break; - } - } +function Hash (hash) { + Base.call(this, 'digest') - var UNKNOWN = '(unknown)'; - var childOwnerNames = childOwners.slice(deepestCommon + 1).map(function (inst) { - return inst.getName() || UNKNOWN; - }); - var ancestorOwnerNames = ancestorOwners.slice(deepestCommon + 1).map(function (inst) { - return inst.getName() || UNKNOWN; - }); - var ownerInfo = [].concat( - // If the parent and child instances have a common owner ancestor, start - // with that -- otherwise we just start with the parent's owners. - deepestCommon !== -1 ? childOwners[deepestCommon].getName() || UNKNOWN : [], ancestorOwnerNames, ancestorTag, - // If we're warning about an invalid (non-parent) ancestry, add '...' - invalidAncestor ? ['...'] : [], childOwnerNames, childTag).join(' > '); + this._hash = hash +} - var warnKey = !!invalidParent + '|' + childTag + '|' + ancestorTag + '|' + ownerInfo; - if (didWarn[warnKey]) { - return; - } - didWarn[warnKey] = true; +inherits(Hash, Base) - var tagDisplayName = childTag; - var whitespaceInfo = ''; - if (childTag === '#text') { - if (/\S/.test(childText)) { - tagDisplayName = 'Text nodes'; - } else { - tagDisplayName = 'Whitespace text nodes'; - whitespaceInfo = " Make sure you don't have any extra whitespace between tags on " + 'each line of your source code.'; - } - } else { - tagDisplayName = '<' + childTag + '>'; - } +Hash.prototype._update = function (data) { + this._hash.update(data) +} - if (invalidParent) { - var info = ''; - if (ancestorTag === 'table' && childTag === 'tr') { - info += ' Add a <tbody> to your code to match the DOM tree generated by ' + 'the browser.'; - } - process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a child of <%s>.%s ' + 'See %s.%s', tagDisplayName, ancestorTag, whitespaceInfo, ownerInfo, info) : void 0; - } else { - process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a descendant of ' + '<%s>. See %s.', tagDisplayName, ancestorTag, ownerInfo) : void 0; - } - } - }; +Hash.prototype._final = function () { + return this._hash.digest() +} - validateDOMNesting.updatedAncestorInfo = updatedAncestorInfo; +module.exports = function createHash (alg) { + alg = alg.toLowerCase() + if (alg === 'md5') return new HashNoConstructor(md5) + if (alg === 'rmd160' || alg === 'ripemd160') return new Hash(new RIPEMD160()) - // For testing - validateDOMNesting.isTagValidInContext = function (tag, ancestorInfo) { - ancestorInfo = ancestorInfo || emptyAncestorInfo; - var parentInfo = ancestorInfo.current; - var parentTag = parentInfo && parentInfo.tag; - return isTagValidWithParent(tag, parentTag) && !findInvalidAncestorForTag(tag, ancestorInfo); - }; + return new Hash(sha(alg)) } -module.exports = validateDOMNesting; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 65 */ +/* 28 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** +/* WEBPACK VAR INJECTION */(function(process) {/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -6661,4586 +8480,5656 @@ module.exports = validateDOMNesting; +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +function checkMask(value, bitmask) { + return (value & bitmask) === bitmask; +} + +var DOMPropertyInjection = { + /** + * Mapping from normalized, camelcased property names to a configuration that + * specifies how the associated DOM property should be accessed or rendered. + */ + MUST_USE_PROPERTY: 0x1, + HAS_BOOLEAN_VALUE: 0x4, + HAS_NUMERIC_VALUE: 0x8, + HAS_POSITIVE_NUMERIC_VALUE: 0x10 | 0x8, + HAS_OVERLOADED_BOOLEAN_VALUE: 0x20, + + /** + * Inject some specialized knowledge about the DOM. This takes a config object + * with the following properties: + * + * isCustomAttribute: function that given an attribute name will return true + * if it can be inserted into the DOM verbatim. Useful for data-* or aria-* + * attributes where it's impossible to enumerate all of the possible + * attribute names, + * + * Properties: object mapping DOM property name to one of the + * DOMPropertyInjection constants or null. If your attribute isn't in here, + * it won't get written to the DOM. + * + * DOMAttributeNames: object mapping React attribute name to the DOM + * attribute name. Attribute names not specified use the **lowercase** + * normalized name. + * + * DOMAttributeNamespaces: object mapping React attribute name to the DOM + * attribute namespace URL. (Attribute names not specified use no namespace.) + * + * DOMPropertyNames: similar to DOMAttributeNames but for DOM properties. + * Property names not specified use the normalized name. + * + * DOMMutationMethods: Properties that require special mutation methods. If + * `value` is undefined, the mutation method should unset the property. + * + * @param {object} domPropertyConfig the config as described above. + */ + injectDOMPropertyConfig: function (domPropertyConfig) { + var Injection = DOMPropertyInjection; + var Properties = domPropertyConfig.Properties || {}; + var DOMAttributeNamespaces = domPropertyConfig.DOMAttributeNamespaces || {}; + var DOMAttributeNames = domPropertyConfig.DOMAttributeNames || {}; + var DOMPropertyNames = domPropertyConfig.DOMPropertyNames || {}; + var DOMMutationMethods = domPropertyConfig.DOMMutationMethods || {}; + + if (domPropertyConfig.isCustomAttribute) { + DOMProperty._isCustomAttributeFunctions.push(domPropertyConfig.isCustomAttribute); + } + + for (var propName in Properties) { + !!DOMProperty.properties.hasOwnProperty(propName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'injectDOMPropertyConfig(...): You\'re trying to inject DOM property \'%s\' which has already been injected. You may be accidentally injecting the same DOM property config twice, or you may be injecting two configs that have conflicting property names.', propName) : _prodInvariant('48', propName) : void 0; + + var lowerCased = propName.toLowerCase(); + var propConfig = Properties[propName]; + + var propertyInfo = { + attributeName: lowerCased, + attributeNamespace: null, + propertyName: propName, + mutationMethod: null, + + mustUseProperty: checkMask(propConfig, Injection.MUST_USE_PROPERTY), + hasBooleanValue: checkMask(propConfig, Injection.HAS_BOOLEAN_VALUE), + hasNumericValue: checkMask(propConfig, Injection.HAS_NUMERIC_VALUE), + hasPositiveNumericValue: checkMask(propConfig, Injection.HAS_POSITIVE_NUMERIC_VALUE), + hasOverloadedBooleanValue: checkMask(propConfig, Injection.HAS_OVERLOADED_BOOLEAN_VALUE) + }; + !(propertyInfo.hasBooleanValue + propertyInfo.hasNumericValue + propertyInfo.hasOverloadedBooleanValue <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'DOMProperty: Value can be one of boolean, overloaded boolean, or numeric value, but not a combination: %s', propName) : _prodInvariant('50', propName) : void 0; + + if (process.env.NODE_ENV !== 'production') { + DOMProperty.getPossibleStandardName[lowerCased] = propName; + } + + if (DOMAttributeNames.hasOwnProperty(propName)) { + var attributeName = DOMAttributeNames[propName]; + propertyInfo.attributeName = attributeName; + if (process.env.NODE_ENV !== 'production') { + DOMProperty.getPossibleStandardName[attributeName] = propName; + } + } + + if (DOMAttributeNamespaces.hasOwnProperty(propName)) { + propertyInfo.attributeNamespace = DOMAttributeNamespaces[propName]; + } + + if (DOMPropertyNames.hasOwnProperty(propName)) { + propertyInfo.propertyName = DOMPropertyNames[propName]; + } + + if (DOMMutationMethods.hasOwnProperty(propName)) { + propertyInfo.mutationMethod = DOMMutationMethods[propName]; + } + + DOMProperty.properties[propName] = propertyInfo; + } + } +}; + +/* eslint-disable max-len */ +var ATTRIBUTE_NAME_START_CHAR = ':A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD'; +/* eslint-enable max-len */ + /** - * `charCode` represents the actual "character code" and is safe to use with - * `String.fromCharCode`. As such, only keys that correspond to printable - * characters produce a valid `charCode`, the only exception to this is Enter. - * The Tab-key is considered non-printable and does not have a `charCode`, - * presumably because it does not produce a tab-character in browsers. + * DOMProperty exports lookup objects that can be used like functions: * - * @param {object} nativeEvent Native browser event. - * @return {number} Normalized `charCode` property. + * > DOMProperty.isValid['id'] + * true + * > DOMProperty.isValid['foobar'] + * undefined + * + * Although this may be confusing, it performs better in general. + * + * @see http://jsperf.com/key-exists + * @see http://jsperf.com/key-missing */ +var DOMProperty = { + ID_ATTRIBUTE_NAME: 'data-reactid', + ROOT_ATTRIBUTE_NAME: 'data-reactroot', -function getEventCharCode(nativeEvent) { - var charCode; - var keyCode = nativeEvent.keyCode; + ATTRIBUTE_NAME_START_CHAR: ATTRIBUTE_NAME_START_CHAR, + ATTRIBUTE_NAME_CHAR: ATTRIBUTE_NAME_START_CHAR + '\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040', - if ('charCode' in nativeEvent) { - charCode = nativeEvent.charCode; + /** + * Map from property "standard name" to an object with info about how to set + * the property in the DOM. Each object contains: + * + * attributeName: + * Used when rendering markup or with `*Attribute()`. + * attributeNamespace + * propertyName: + * Used on DOM node instances. (This includes properties that mutate due to + * external factors.) + * mutationMethod: + * If non-null, used instead of the property or `setAttribute()` after + * initial render. + * mustUseProperty: + * Whether the property must be accessed and mutated as an object property. + * hasBooleanValue: + * Whether the property should be removed when set to a falsey value. + * hasNumericValue: + * Whether the property must be numeric or parse as a numeric and should be + * removed when set to a falsey value. + * hasPositiveNumericValue: + * Whether the property must be positive numeric or parse as a positive + * numeric and should be removed when set to a falsey value. + * hasOverloadedBooleanValue: + * Whether the property can be used as a flag as well as with a value. + * Removed when strictly equal to false; present without a value when + * strictly equal to true; present with a value otherwise. + */ + properties: {}, - // FF does not set `charCode` for the Enter-key, check against `keyCode`. - if (charCode === 0 && keyCode === 13) { - charCode = 13; - } - } else { - // IE8 does not implement `charCode`, but `keyCode` has the correct value. - charCode = keyCode; - } + /** + * Mapping from lowercase property names to the properly cased version, used + * to warn in the case of missing properties. Available only in __DEV__. + * + * autofocus is predefined, because adding it to the property whitelist + * causes unintended side effects. + * + * @type {Object} + */ + getPossibleStandardName: process.env.NODE_ENV !== 'production' ? { autofocus: 'autoFocus' } : null, - // Some non-printable keys are reported in `charCode`/`keyCode`, discard them. - // Must not discard the (non-)printable Enter-key. - if (charCode >= 32 || charCode === 13) { - return charCode; - } + /** + * All of the isCustomAttribute() functions that have been injected. + */ + _isCustomAttributeFunctions: [], - return 0; -} + /** + * Checks whether a property name is a custom attribute. + * @method + */ + isCustomAttribute: function (attributeName) { + for (var i = 0; i < DOMProperty._isCustomAttributeFunctions.length; i++) { + var isCustomAttributeFn = DOMProperty._isCustomAttributeFunctions[i]; + if (isCustomAttributeFn(attributeName)) { + return true; + } + } + return false; + }, -module.exports = getEventCharCode; + injection: DOMPropertyInjection +}; -/***/ }), -/* 66 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +module.exports = DOMProperty; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -"use strict"; -Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Alert", function() { return Alert; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Container", function() { return Container; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Row", function() { return Row; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Col", function() { return Col; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Navbar", function() { return Navbar; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarBrand", function() { return NavbarBrand; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarToggler", function() { return NavbarToggler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Nav", function() { return Nav; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavItem", function() { return NavItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavDropdown", function() { return NavDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavLink", function() { return NavLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Breadcrumb", function() { return Breadcrumb; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BreadcrumbItem", function() { return BreadcrumbItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Button", function() { return Button; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonDropdown", function() { return ButtonDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonGroup", function() { return ButtonGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonToolbar", function() { return ButtonToolbar; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Dropdown", function() { return Dropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownItem", function() { return DropdownItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownMenu", function() { return DropdownMenu; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownToggle", function() { return DropdownToggle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Fade", function() { return Fade; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Badge", function() { return Badge; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Card", function() { return Card; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardLink", function() { return CardLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardGroup", function() { return CardGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardDeck", function() { return CardDeck; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardColumns", function() { return CardColumns; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardBlock", function() { return CardBlock; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardFooter", function() { return CardFooter; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardHeader", function() { return CardHeader; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImg", function() { return CardImg; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImgOverlay", function() { return CardImgOverlay; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardSubtitle", function() { return CardSubtitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardText", function() { return CardText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardTitle", function() { return CardTitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Popover", function() { return Popover; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverContent", function() { return PopoverContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverTitle", function() { return PopoverTitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Progress", function() { return Progress; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Modal", function() { return Modal; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalHeader", function() { return ModalHeader; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalBody", function() { return ModalBody; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalFooter", function() { return ModalFooter; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TetherContent", function() { return TetherContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Tooltip", function() { return Tooltip; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Table", function() { return Table; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroup", function() { return ListGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Form", function() { return Form; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormFeedback", function() { return FormFeedback; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormGroup", function() { return FormGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormText", function() { return FormText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Input", function() { return Input; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroup", function() { return InputGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupAddon", function() { return InputGroupAddon; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupButton", function() { return InputGroupButton; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Label", function() { return Label; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Media", function() { return Media; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Pagination", function() { return Pagination; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationItem", function() { return PaginationItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationLink", function() { return PaginationLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabContent", function() { return TabContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabPane", function() { return TabPane; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Jumbotron", function() { return Jumbotron; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Collapse", function() { return Collapse; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItem", function() { return ListGroupItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemText", function() { return ListGroupItemText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemHeading", function() { return ListGroupItemHeading; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledAlert", function() { return UncontrolledAlert; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledButtonDropdown", function() { return UncontrolledButtonDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledDropdown", function() { return UncontrolledDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledNavDropdown", function() { return UncontrolledNavDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledTooltip", function() { return UncontrolledTooltip; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_classnames__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject__ = __webpack_require__(222); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_lodash_isobject__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom__ = __webpack_require__(28); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_react_dom__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__ = __webpack_require__(223); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__ = __webpack_require__(224); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__ = __webpack_require__(225); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group__ = __webpack_require__(226); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8_react_transition_group__); +/***/ }), +/* 29 */ +/***/ (function(module, exports, __webpack_require__) { +var Buffer = __webpack_require__(7).Buffer +var Transform = __webpack_require__(98).Transform +var StringDecoder = __webpack_require__(102).StringDecoder +var inherits = __webpack_require__(4) +function CipherBase (hashMode) { + Transform.call(this) + this.hashMode = typeof hashMode === 'string' + if (this.hashMode) { + this[hashMode] = this._finalOrDigest + } else { + this.final = this._finalOrDigest + } + if (this._final) { + this.__final = this._final + this._final = null + } + this._decoder = null + this._encoding = null +} +inherits(CipherBase, Transform) +CipherBase.prototype.update = function (data, inputEnc, outputEnc) { + if (typeof data === 'string') { + data = Buffer.from(data, inputEnc) + } + var outData = this._update(data) + if (this.hashMode) return this + if (outputEnc) { + outData = this._toString(outData, outputEnc) + } + return outData +} +CipherBase.prototype.setAutoPadding = function () {} +CipherBase.prototype.getAuthTag = function () { + throw new Error('trying to get auth tag in unsupported state') +} +CipherBase.prototype.setAuthTag = function () { + throw new Error('trying to set auth tag in unsupported state') +} +CipherBase.prototype.setAAD = function () { + throw new Error('trying to set aad in unsupported state') +} -function getTetherAttachments(placement) { - var attachments = {}; - switch (placement) { - case 'top': - case 'top center': - attachments = { - attachment: 'bottom center', - targetAttachment: 'top center' - }; - break; - case 'bottom': - case 'bottom center': - attachments = { - attachment: 'top center', - targetAttachment: 'bottom center' - }; - break; - case 'left': - case 'left center': - attachments = { - attachment: 'middle right', - targetAttachment: 'middle left' - }; - break; - case 'right': - case 'right center': - attachments = { - attachment: 'middle left', - targetAttachment: 'middle right' - }; - break; - case 'top left': - attachments = { - attachment: 'bottom left', - targetAttachment: 'top left' - }; - break; - case 'top right': - attachments = { - attachment: 'bottom right', - targetAttachment: 'top right' - }; - break; - case 'bottom left': - attachments = { - attachment: 'top left', - targetAttachment: 'bottom left' - }; - break; - case 'bottom right': - attachments = { - attachment: 'top right', - targetAttachment: 'bottom right' - }; - break; - case 'right top': - attachments = { - attachment: 'top left', - targetAttachment: 'top right' - }; - break; - case 'right bottom': - attachments = { - attachment: 'bottom left', - targetAttachment: 'bottom right' - }; - break; - case 'left top': - attachments = { - attachment: 'top right', - targetAttachment: 'top left' - }; - break; - case 'left bottom': - attachments = { - attachment: 'bottom right', - targetAttachment: 'bottom left' - }; - break; - default: - attachments = { - attachment: 'top center', - targetAttachment: 'bottom center' - }; +CipherBase.prototype._transform = function (data, _, next) { + var err + try { + if (this.hashMode) { + this._update(data) + } else { + this.push(this._update(data)) + } + } catch (e) { + err = e + } finally { + next(err) + } +} +CipherBase.prototype._flush = function (done) { + var err + try { + this.push(this.__final()) + } catch (e) { + err = e } - return attachments; + done(err) +} +CipherBase.prototype._finalOrDigest = function (outputEnc) { + var outData = this.__final() || Buffer.alloc(0) + if (outputEnc) { + outData = this._toString(outData, outputEnc, true) + } + return outData } -var tetherAttachements = ['top', 'bottom', 'left', 'right', 'top left', 'top center', 'top right', 'right top', 'right middle', 'right bottom', 'bottom right', 'bottom center', 'bottom left', 'left top', 'left middle', 'left bottom']; +CipherBase.prototype._toString = function (value, enc, fin) { + if (!this._decoder) { + this._decoder = new StringDecoder(enc) + this._encoding = enc + } -// https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L436-L443 -function getScrollbarWidth() { - var scrollDiv = document.createElement('div'); - // .modal-scrollbar-measure styles // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/scss/_modal.scss#L106-L113 - scrollDiv.style.position = 'absolute'; - scrollDiv.style.top = '-9999px'; - scrollDiv.style.width = '50px'; - scrollDiv.style.height = '50px'; - scrollDiv.style.overflow = 'scroll'; - document.body.appendChild(scrollDiv); - var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth; - document.body.removeChild(scrollDiv); - return scrollbarWidth; -} + if (this._encoding !== enc) throw new Error('can\'t switch encodings') -function setScrollbarWidth(padding) { - document.body.style.paddingRight = padding > 0 ? padding + 'px' : null; -} + var out = this._decoder.write(value) + if (fin) { + out += this._decoder.end() + } -function isBodyOverflowing() { - return document.body.clientWidth < window.innerWidth; + return out } -function getOriginalBodyPadding() { - return parseInt(window.getComputedStyle(document.body, null).getPropertyValue('padding-right') || 0, 10); -} +module.exports = CipherBase -function conditionallyUpdateScrollbar() { - var scrollbarWidth = getScrollbarWidth(); - // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L420 - var fixedContent = document.querySelectorAll('.navbar-fixed-top, .navbar-fixed-bottom, .is-fixed')[0]; - var bodyPadding = fixedContent ? parseInt(fixedContent.style.paddingRight || 0, 10) : 0; - if (isBodyOverflowing()) { - setScrollbarWidth(bodyPadding + scrollbarWidth); - } -} +/***/ }), +/* 30 */ +/***/ (function(module, exports, __webpack_require__) { -function mapToCssModules(className, cssModule) { - if (!cssModule) return className; - return className.split(' ').map(function (c) { - return cssModule[c] || c; - }).join(' '); -} +var BigInteger = __webpack_require__(175) -/** - * Returns a new object with the key/value pairs from `obj` that are not in the array `omitKeys`. - */ -function omit(obj, omitKeys) { - var result = {}; - Object.keys(obj).forEach(function (key) { - if (omitKeys.indexOf(key) === -1) { - result[key] = obj[key]; - } - }); - return result; -} +//addons +__webpack_require__(408) -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { - return typeof obj; -} : function (obj) { - return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; -}; +module.exports = BigInteger +/***/ }), +/* 31 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ +var _assign = __webpack_require__(8); +var ReactCurrentOwner = __webpack_require__(22); +var warning = __webpack_require__(3); +var canDefineProperty = __webpack_require__(55); +var hasOwnProperty = Object.prototype.hasOwnProperty; +var REACT_ELEMENT_TYPE = __webpack_require__(121); +var RESERVED_PROPS = { + key: true, + ref: true, + __self: true, + __source: true +}; +var specialPropKeyWarningShown, specialPropRefWarningShown; -var classCallCheck = function (instance, Constructor) { - if (!(instance instanceof Constructor)) { - throw new TypeError("Cannot call a class as a function"); +function hasValidRef(config) { + if (process.env.NODE_ENV !== 'production') { + if (hasOwnProperty.call(config, 'ref')) { + var getter = Object.getOwnPropertyDescriptor(config, 'ref').get; + if (getter && getter.isReactWarning) { + return false; + } + } } -}; + return config.ref !== undefined; +} -var createClass = function () { - function defineProperties(target, props) { - for (var i = 0; i < props.length; i++) { - var descriptor = props[i]; - descriptor.enumerable = descriptor.enumerable || false; - descriptor.configurable = true; - if ("value" in descriptor) descriptor.writable = true; - Object.defineProperty(target, descriptor.key, descriptor); +function hasValidKey(config) { + if (process.env.NODE_ENV !== 'production') { + if (hasOwnProperty.call(config, 'key')) { + var getter = Object.getOwnPropertyDescriptor(config, 'key').get; + if (getter && getter.isReactWarning) { + return false; + } } } + return config.key !== undefined; +} - return function (Constructor, protoProps, staticProps) { - if (protoProps) defineProperties(Constructor.prototype, protoProps); - if (staticProps) defineProperties(Constructor, staticProps); - return Constructor; +function defineKeyPropWarningGetter(props, displayName) { + var warnAboutAccessingKey = function () { + if (!specialPropKeyWarningShown) { + specialPropKeyWarningShown = true; + process.env.NODE_ENV !== 'production' ? warning(false, '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + } }; -}(); + warnAboutAccessingKey.isReactWarning = true; + Object.defineProperty(props, 'key', { + get: warnAboutAccessingKey, + configurable: true + }); +} +function defineRefPropWarningGetter(props, displayName) { + var warnAboutAccessingRef = function () { + if (!specialPropRefWarningShown) { + specialPropRefWarningShown = true; + process.env.NODE_ENV !== 'production' ? warning(false, '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + } + }; + warnAboutAccessingRef.isReactWarning = true; + Object.defineProperty(props, 'ref', { + get: warnAboutAccessingRef, + configurable: true + }); +} + +/** + * Factory method to create a new React element. This no longer adheres to + * the class pattern, so do not use new to call it. Also, no instanceof check + * will work. Instead test $$typeof field against Symbol.for('react.element') to check + * if something is a React Element. + * + * @param {*} type + * @param {*} key + * @param {string|object} ref + * @param {*} self A *temporary* helper to detect places where `this` is + * different from the `owner` when React.createElement is called, so that we + * can warn. We want to get rid of owner and replace string `ref`s with arrow + * functions, and as long as `this` and owner are the same, there will be no + * change in behavior. + * @param {*} source An annotation object (added by a transpiler or otherwise) + * indicating filename, line number, and/or other information. + * @param {*} owner + * @param {*} props + * @internal + */ +var ReactElement = function (type, key, ref, self, source, owner, props) { + var element = { + // This tag allow us to uniquely identify this as a React Element + $$typeof: REACT_ELEMENT_TYPE, + // Built-in properties that belong on the element + type: type, + key: key, + ref: ref, + props: props, + // Record the component responsible for creating this element. + _owner: owner + }; + if (process.env.NODE_ENV !== 'production') { + // The validation flag is currently mutative. We put it on + // an external backing store so that we can freeze the whole object. + // This can be replaced with a WeakMap once they are implemented in + // commonly used development environments. + element._store = {}; -var defineProperty = function (obj, key, value) { - if (key in obj) { - Object.defineProperty(obj, key, { - value: value, - enumerable: true, - configurable: true, - writable: true - }); - } else { - obj[key] = value; + // To make comparing ReactElements easier for testing purposes, we make + // the validation flag non-enumerable (where possible, which should + // include every environment we run tests in), so the test framework + // ignores it. + if (canDefineProperty) { + Object.defineProperty(element._store, 'validated', { + configurable: false, + enumerable: false, + writable: true, + value: false + }); + // self and source are DEV only properties. + Object.defineProperty(element, '_self', { + configurable: false, + enumerable: false, + writable: false, + value: self + }); + // Two elements created in two different places should be considered + // equal for testing purposes and therefore we hide it from enumeration. + Object.defineProperty(element, '_source', { + configurable: false, + enumerable: false, + writable: false, + value: source + }); + } else { + element._store.validated = false; + element._self = self; + element._source = source; + } + if (Object.freeze) { + Object.freeze(element.props); + Object.freeze(element); + } } - return obj; + return element; }; -var _extends = Object.assign || function (target) { - for (var i = 1; i < arguments.length; i++) { - var source = arguments[i]; +/** + * Create and return a new ReactElement of the given type. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createelement + */ +ReactElement.createElement = function (type, config, children) { + var propName; - for (var key in source) { - if (Object.prototype.hasOwnProperty.call(source, key)) { - target[key] = source[key]; - } - } - } + // Reserved names are extracted + var props = {}; - return target; -}; + var key = null; + var ref = null; + var self = null; + var source = null; + if (config != null) { + if (hasValidRef(config)) { + ref = config.ref; + } + if (hasValidKey(config)) { + key = '' + config.key; + } + self = config.__self === undefined ? null : config.__self; + source = config.__source === undefined ? null : config.__source; + // Remaining properties are added to a new props object + for (propName in config) { + if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { + props[propName] = config[propName]; + } + } + } -var inherits = function (subClass, superClass) { - if (typeof superClass !== "function" && superClass !== null) { - throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); + // Children can be more than one argument, and those are transferred onto + // the newly allocated props object. + var childrenLength = arguments.length - 2; + if (childrenLength === 1) { + props.children = children; + } else if (childrenLength > 1) { + var childArray = Array(childrenLength); + for (var i = 0; i < childrenLength; i++) { + childArray[i] = arguments[i + 2]; + } + if (process.env.NODE_ENV !== 'production') { + if (Object.freeze) { + Object.freeze(childArray); + } + } + props.children = childArray; } - subClass.prototype = Object.create(superClass && superClass.prototype, { - constructor: { - value: subClass, - enumerable: false, - writable: true, - configurable: true + // Resolve default props + if (type && type.defaultProps) { + var defaultProps = type.defaultProps; + for (propName in defaultProps) { + if (props[propName] === undefined) { + props[propName] = defaultProps[propName]; + } } - }); - if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; + } + if (process.env.NODE_ENV !== 'production') { + if (key || ref) { + if (typeof props.$$typeof === 'undefined' || props.$$typeof !== REACT_ELEMENT_TYPE) { + var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type; + if (key) { + defineKeyPropWarningGetter(props, displayName); + } + if (ref) { + defineRefPropWarningGetter(props, displayName); + } + } + } + } + return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props); }; +/** + * Return a function that produces ReactElements of a given type. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createfactory + */ +ReactElement.createFactory = function (type) { + var factory = ReactElement.createElement.bind(null, type); + // Expose the type on the factory and the prototype so that it can be + // easily accessed on elements. E.g. `<Foo />.type === Foo`. + // This should not be named `constructor` since this may not be the function + // that created the element, and it may not even be a constructor. + // Legacy hook TODO: Warn if this is accessed + factory.type = type; + return factory; +}; +ReactElement.cloneAndReplaceKey = function (oldElement, newKey) { + var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props); + return newElement; +}; +/** + * Clone and return a new ReactElement using element as the starting point. + * See https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement + */ +ReactElement.cloneElement = function (element, config, children) { + var propName; + // Original props are copied + var props = _assign({}, element.props); + // Reserved names are extracted + var key = element.key; + var ref = element.ref; + // Self is preserved since the owner is preserved. + var self = element._self; + // Source is preserved since cloneElement is unlikely to be targeted by a + // transpiler, and the original source is probably a better indicator of the + // true owner. + var source = element._source; + // Owner will be preserved, unless ref is overridden + var owner = element._owner; + if (config != null) { + if (hasValidRef(config)) { + // Silently steal the ref from the parent. + ref = config.ref; + owner = ReactCurrentOwner.current; + } + if (hasValidKey(config)) { + key = '' + config.key; + } -var objectWithoutProperties = function (obj, keys) { - var target = {}; - - for (var i in obj) { - if (keys.indexOf(i) >= 0) continue; - if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; - target[i] = obj[i]; + // Remaining properties override existing props + var defaultProps; + if (element.type && element.type.defaultProps) { + defaultProps = element.type.defaultProps; + } + for (propName in config) { + if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { + if (config[propName] === undefined && defaultProps !== undefined) { + // Resolve default props + props[propName] = defaultProps[propName]; + } else { + props[propName] = config[propName]; + } + } + } } - return target; -}; - -var possibleConstructorReturn = function (self, call) { - if (!self) { - throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); + // Children can be more than one argument, and those are transferred onto + // the newly allocated props object. + var childrenLength = arguments.length - 2; + if (childrenLength === 1) { + props.children = children; + } else if (childrenLength > 1) { + var childArray = Array(childrenLength); + for (var i = 0; i < childrenLength; i++) { + childArray[i] = arguments[i + 2]; + } + props.children = childArray; } - return call && (typeof call === "object" || typeof call === "function") ? call : self; + return ReactElement(element.type, key, ref, self, source, owner, props); }; -var propTypes = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +/** + * Verifies the object is a ReactElement. + * See https://facebook.github.io/react/docs/top-level-api.html#react.isvalidelement + * @param {?object} object + * @return {boolean} True if `object` is a valid component. + * @final + */ +ReactElement.isValidElement = function (object) { + return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE; }; -var defaultProps = { - tag: 'div' -}; +module.exports = ReactElement; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var Container = function Container(props) { - var className = props.className, - cssModule = props.cssModule, - fluid = props.fluid, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'fluid', 'tag']); +/***/ }), +/* 32 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, fluid ? 'container-fluid' : 'container'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +/** + * Static poolers. Several custom versions for each potential number of + * arguments. A completely generic pooler is easy to implement, but would + * require accessing the `arguments` object. In each of these, `this` refers to + * the Class itself, not an instance. If any others are needed, simply add them + * here, or in their own files. + */ +var oneArgumentPooler = function (copyFieldsFrom) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, copyFieldsFrom); + return instance; + } else { + return new Klass(copyFieldsFrom); + } }; -Container.propTypes = propTypes; -Container.defaultProps = defaultProps; +var twoArgumentPooler = function (a1, a2) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2); + return instance; + } else { + return new Klass(a1, a2); + } +}; -var propTypes$1 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - noGutters: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +var threeArgumentPooler = function (a1, a2, a3) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3); + return instance; + } else { + return new Klass(a1, a2, a3); + } }; -var defaultProps$1 = { - tag: 'div' +var fourArgumentPooler = function (a1, a2, a3, a4) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3, a4); + return instance; + } else { + return new Klass(a1, a2, a3, a4); + } }; -var Row = function Row(props) { - var className = props.className, - cssModule = props.cssModule, - noGutters = props.noGutters, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'noGutters', 'tag']); +var standardReleaser = function (instance) { + var Klass = this; + !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; + instance.destructor(); + if (Klass.instancePool.length < Klass.poolSize) { + Klass.instancePool.push(instance); + } +}; +var DEFAULT_POOL_SIZE = 10; +var DEFAULT_POOLER = oneArgumentPooler; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, noGutters ? 'no-gutters' : null, 'row'), cssModule); +/** + * Augments `CopyConstructor` to be a poolable class, augmenting only the class + * itself (statically) not adding any prototypical fields. Any CopyConstructor + * you give this may have a `poolSize` property, and will look for a + * prototypical `destructor` on instances. + * + * @param {Function} CopyConstructor Constructor that can be used to reset. + * @param {Function} pooler Customizable pooler. + */ +var addPoolingTo = function (CopyConstructor, pooler) { + // Casting as any so that flow ignores the actual implementation and trusts + // it to match the type we declared + var NewKlass = CopyConstructor; + NewKlass.instancePool = []; + NewKlass.getPooled = pooler || DEFAULT_POOLER; + if (!NewKlass.poolSize) { + NewKlass.poolSize = DEFAULT_POOL_SIZE; + } + NewKlass.release = standardReleaser; + return NewKlass; +}; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +var PooledClass = { + addPoolingTo: addPoolingTo, + oneArgumentPooler: oneArgumentPooler, + twoArgumentPooler: twoArgumentPooler, + threeArgumentPooler: threeArgumentPooler, + fourArgumentPooler: fourArgumentPooler }; -Row.propTypes = propTypes$1; -Row.defaultProps = defaultProps$1; +module.exports = PooledClass; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var colWidths = ['xs', 'sm', 'md', 'lg', 'xl']; -var stringOrNumberProp = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); +/***/ }), +/* 33 */ +/***/ (function(module, exports, __webpack_require__) { -var columnProps = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - push: stringOrNumberProp, - pull: stringOrNumberProp, - offset: stringOrNumberProp -})]); +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { -var propTypes$2 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - xs: columnProps, - sm: columnProps, - md: columnProps, - lg: columnProps, - xl: columnProps, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - widths: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.array -}; +var base58 = __webpack_require__(363) +var createHash = __webpack_require__(27) -var defaultProps$2 = { - tag: 'div', - widths: colWidths -}; +// SHA256(SHA256(buffer)) +function sha256x2 (buffer) { + var tmp = createHash('sha256').update(buffer).digest() + return createHash('sha256').update(tmp).digest() +} -var getColumnSizeClass = function getColumnSizeClass(isXs, colWidth, colSize) { - if (colSize === true || colSize === '') { - return isXs ? 'col' : 'col-' + colWidth; - } else if (colSize === 'auto') { - return isXs ? 'col-auto' : 'col-' + colWidth + '-auto'; - } +// Encode a buffer as a base58-check encoded string +function encode (payload) { + var checksum = sha256x2(payload) - return isXs ? 'col-' + colSize : 'col-' + colWidth + '-' + colSize; -}; + return base58.encode(Buffer.concat([ + payload, + checksum + ], payload.length + 4)) +} -var Col = function Col(props) { - var className = props.className, - cssModule = props.cssModule, - widths = props.widths, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'widths', 'tag']); +function decodeRaw (buffer) { + var payload = buffer.slice(0, -4) + var checksum = buffer.slice(-4) + var newChecksum = sha256x2(payload) - var colClasses = []; + if (checksum[0] ^ newChecksum[0] | + checksum[1] ^ newChecksum[1] | + checksum[2] ^ newChecksum[2] | + checksum[3] ^ newChecksum[3]) return - widths.forEach(function (colWidth, i) { - var columnProp = props[colWidth]; + return payload +} - if (!i && columnProp === undefined) { - columnProp = true; - } +// Decode a base58-check encoded string to a buffer, no result if checksum is wrong +function decodeUnsafe (string) { + var buffer = base58.decodeUnsafe(string) + if (!buffer) return - delete attributes[colWidth]; + return decodeRaw(buffer) +} - if (!columnProp) { - return; - } +function decode (string) { + var buffer = base58.decode(string) + var payload = decodeRaw(buffer) + if (!payload) throw new Error('Invalid checksum') + return payload +} - var isXs = !i; - var colClass = void 0; +module.exports = { + encode: encode, + decode: decode, + decodeUnsafe: decodeUnsafe +} - if (__WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default()(columnProp)) { - var _classNames; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - var colSizeInterfix = isXs ? '-' : '-' + colWidth + '-'; - colClass = getColumnSizeClass(isXs, colWidth, columnProp.size); +/***/ }), +/* 34 */ +/***/ (function(module, exports, __webpack_require__) { - colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, colClass, columnProp.size || columnProp.size === ''), defineProperty(_classNames, 'push' + colSizeInterfix + columnProp.push, columnProp.push || columnProp.push === 0), defineProperty(_classNames, 'pull' + colSizeInterfix + columnProp.pull, columnProp.pull || columnProp.pull === 0), defineProperty(_classNames, 'offset' + colSizeInterfix + columnProp.offset, columnProp.offset || columnProp.offset === 0), _classNames))), cssModule); - } else { - colClass = getColumnSizeClass(isXs, colWidth, columnProp); - colClasses.push(colClass); - } - }); +"use strict"; +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a duplex stream is just a stream that is both readable and writable. +// Since JS doesn't have multiple prototypal inheritance, this class +// prototypally inherits from Readable, and then parasitically from +// Writable. + + + +/*<replacement>*/ + +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +/*<replacement>*/ +var objectKeys = Object.keys || function (obj) { + var keys = []; + for (var key in obj) { + keys.push(key); + }return keys; +}; +/*</replacement>*/ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, colClasses), cssModule); +module.exports = Duplex; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ -Col.propTypes = propTypes$2; -Col.defaultProps = defaultProps$2; +var Readable = __webpack_require__(161); +var Writable = __webpack_require__(101); -var propTypes$3 = { - light: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - full: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - fixed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - sticky: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggleable: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; +util.inherits(Duplex, Readable); -var defaultProps$3 = { - tag: 'nav', - toggleable: false -}; +var keys = objectKeys(Writable.prototype); +for (var v = 0; v < keys.length; v++) { + var method = keys[v]; + if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method]; +} -var getToggleableClass = function getToggleableClass(toggleable) { - if (toggleable === false) { - return false; - } else if (toggleable === true || toggleable === 'xs') { - return 'navbar-toggleable'; - } +function Duplex(options) { + if (!(this instanceof Duplex)) return new Duplex(options); - return 'navbar-toggleable-' + toggleable; -}; + Readable.call(this, options); + Writable.call(this, options); -var Navbar = function Navbar(props) { - var _classNames; + if (options && options.readable === false) this.readable = false; - var toggleable = props.toggleable, - className = props.className, - cssModule = props.cssModule, - light = props.light, - inverse = props.inverse, - full = props.full, - fixed = props.fixed, - sticky = props.sticky, - color = props.color, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['toggleable', 'className', 'cssModule', 'light', 'inverse', 'full', 'fixed', 'sticky', 'color', 'tag']); + if (options && options.writable === false) this.writable = false; + this.allowHalfOpen = true; + if (options && options.allowHalfOpen === false) this.allowHalfOpen = false; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar', getToggleableClass(toggleable), (_classNames = { - 'navbar-light': light, - 'navbar-inverse': inverse - }, defineProperty(_classNames, 'bg-' + color, color), defineProperty(_classNames, 'navbar-full', full), defineProperty(_classNames, 'fixed-' + fixed, fixed), defineProperty(_classNames, 'sticky-' + sticky, sticky), _classNames)), cssModule); + this.once('end', onend); +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +// the no-half-open enforcer +function onend() { + // if we allow half-open state, or if the writable side ended, + // then we're ok. + if (this.allowHalfOpen || this._writableState.ended) return; -Navbar.propTypes = propTypes$3; -Navbar.defaultProps = defaultProps$3; + // no more data can be written. + // But allow more writes to happen in this tick. + processNextTick(onEndNT, this); +} -var propTypes$4 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function onEndNT(self) { + self.end(); +} -var defaultProps$4 = { - tag: 'a' +Object.defineProperty(Duplex.prototype, 'destroyed', { + get: function () { + if (this._readableState === undefined || this._writableState === undefined) { + return false; + } + return this._readableState.destroyed && this._writableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (this._readableState === undefined || this._writableState === undefined) { + return; + } + + // backward compatibility, the user is explicitly + // managing destroyed + this._readableState.destroyed = value; + this._writableState.destroyed = value; + } +}); + +Duplex.prototype._destroy = function (err, cb) { + this.push(null); + this.end(); + + processNextTick(cb, err); }; -var NavbarBrand = function NavbarBrand(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +function forEach(xs, f) { + for (var i = 0, l = xs.length; i < l; i++) { + f(xs[i], i); + } +} +/***/ }), +/* 35 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-brand'), cssModule); +"use strict"; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -NavbarBrand.propTypes = propTypes$4; -NavbarBrand.defaultProps = defaultProps$4; +Object.defineProperty(exports, "__esModule", { + value: true +}); -var propTypes$5 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var defaultProps$5 = { - tag: 'button', - type: 'button' -}; +var _react = __webpack_require__(6); -var navbarToggleIcon = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('span', { className: 'navbar-toggler-icon' }); +var _react2 = _interopRequireDefault(_react); -var NavbarToggler = function NavbarToggler(props) { - var className = props.className, - cssModule = props.cssModule, - children = props.children, - right = props.right, - left = props.left, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'right', 'left', 'tag']); +var _propTypes = __webpack_require__(40); +var _propTypes2 = _interopRequireDefault(_propTypes); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-toggler', right && 'navbar-toggler-right', left && 'navbar-toggler-left'), cssModule); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { className: classes }), - children || navbarToggleIcon - ); -}; +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } -NavbarToggler.propTypes = propTypes$5; -NavbarToggler.defaultProps = defaultProps$5; +var IconBase = function IconBase(_ref, _ref2) { + var children = _ref.children; + var color = _ref.color; + var size = _ref.size; + var style = _ref.style; + + var props = _objectWithoutProperties(_ref, ['children', 'color', 'size', 'style']); + + var _ref2$reactIconBase = _ref2.reactIconBase; + var reactIconBase = _ref2$reactIconBase === undefined ? {} : _ref2$reactIconBase; + + var computedSize = size || reactIconBase.size || '1em'; + return _react2.default.createElement('svg', _extends({ + children: children, + fill: 'currentColor', + preserveAspectRatio: 'xMidYMid meet', + height: computedSize, + width: computedSize + }, reactIconBase, props, { + style: _extends({ + verticalAlign: 'middle', + color: color || reactIconBase.color + }, reactIconBase.style || {}, style) + })); +}; -var propTypes$6 = { - tabs: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - pills: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +IconBase.propTypes = { + color: _propTypes2.default.string, + size: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.number]), + style: _propTypes2.default.object }; -var defaultProps$6 = { - tag: 'ul' +IconBase.contextTypes = { + reactIconBase: _propTypes2.default.shape(IconBase.propTypes) }; -var Nav = function Nav(props) { - var className = props.className, - cssModule = props.cssModule, - tabs = props.tabs, - pills = props.pills, - vertical = props.vertical, - navbar = props.navbar, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabs', 'pills', 'vertical', 'navbar', 'tag']); +exports.default = IconBase; +module.exports = exports['default']; +/***/ }), +/* 36 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, navbar ? 'navbar-nav' : 'nav', { - 'nav-tabs': tabs, - 'nav-pills': pills, - 'flex-column': vertical - }), cssModule); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -Nav.propTypes = propTypes$6; -Nav.defaultProps = defaultProps$6; -var propTypes$7 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var _assign = __webpack_require__(8); -var defaultProps$7 = { - tag: 'li' -}; +var ReactBaseClasses = __webpack_require__(119); +var ReactChildren = __webpack_require__(216); +var ReactDOMFactories = __webpack_require__(220); +var ReactElement = __webpack_require__(31); +var ReactPropTypes = __webpack_require__(224); +var ReactVersion = __webpack_require__(226); -var NavItem = function NavItem(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +var createReactClass = __webpack_require__(227); +var onlyChild = __webpack_require__(229); +var createElement = ReactElement.createElement; +var createFactory = ReactElement.createFactory; +var cloneElement = ReactElement.cloneElement; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); +if (process.env.NODE_ENV !== 'production') { + var lowPriorityWarning = __webpack_require__(74); + var canDefineProperty = __webpack_require__(55); + var ReactElementValidator = __webpack_require__(123); + var didWarnPropTypesDeprecated = false; + createElement = ReactElementValidator.createElement; + createFactory = ReactElementValidator.createFactory; + cloneElement = ReactElementValidator.cloneElement; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +var __spread = _assign; +var createMixin = function (mixin) { + return mixin; }; -NavItem.propTypes = propTypes$7; -NavItem.defaultProps = defaultProps$7; +if (process.env.NODE_ENV !== 'production') { + var warnedForSpread = false; + var warnedForCreateMixin = false; + __spread = function () { + lowPriorityWarning(warnedForSpread, 'React.__spread is deprecated and should not be used. Use ' + 'Object.assign directly or another helper function with similar ' + 'semantics. You may be seeing this warning due to your compiler. ' + 'See https://fb.me/react-spread-deprecation for more details.'); + warnedForSpread = true; + return _assign.apply(null, arguments); + }; -var propTypes$10 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - arrow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object.isRequired, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - style: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + createMixin = function (mixin) { + lowPriorityWarning(warnedForCreateMixin, 'React.createMixin is deprecated and should not be used. ' + 'In React v16.0, it will be removed. ' + 'You can use this mixin directly instead. ' + 'See https://fb.me/createmixin-was-never-implemented for more info.'); + warnedForCreateMixin = true; + return mixin; + }; +} -var defaultProps$10 = { - isOpen: false, - tetherRef: function tetherRef() {} -}; +var React = { + // Modern -var TetherContent = function (_React$Component) { - inherits(TetherContent, _React$Component); + Children: { + map: ReactChildren.map, + forEach: ReactChildren.forEach, + count: ReactChildren.count, + toArray: ReactChildren.toArray, + only: onlyChild + }, - function TetherContent(props) { - classCallCheck(this, TetherContent); + Component: ReactBaseClasses.Component, + PureComponent: ReactBaseClasses.PureComponent, - var _this = possibleConstructorReturn(this, (TetherContent.__proto__ || Object.getPrototypeOf(TetherContent)).call(this, props)); + createElement: createElement, + cloneElement: cloneElement, + isValidElement: ReactElement.isValidElement, - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.toggle = _this.toggle.bind(_this); - return _this; - } + // Classic - createClass(TetherContent, [{ - key: 'componentDidMount', - value: function componentDidMount() { - this.handleProps(); - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - this.handleProps(); - } else if (this._element) { - // rerender - this.renderIntoSubtree(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.hide(); - } - }, { - key: 'getTarget', - value: function getTarget() { - var target = this.props.tether.target; + PropTypes: ReactPropTypes, + createClass: createReactClass, + createFactory: createFactory, + createMixin: createMixin, - if (__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default()(target)) { - return target(); - } + // This looks DOM specific but these are actually isomorphic helpers + // since they are just generating DOM strings. + DOM: ReactDOMFactories, - return target; - } - }, { - key: 'getTetherConfig', - value: function getTetherConfig() { - var config = _extends({}, this.props.tether); + version: ReactVersion, - config.element = this._element; - config.target = this.getTarget(); - return config; - } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - var container = this._element; - if (e.target === container || !container.contains(e.target)) { - this.toggle(); - } - } - }, { - key: 'handleProps', - value: function handleProps() { - if (this.props.isOpen) { - this.show(); - } else { - this.hide(); - } - } - }, { - key: 'hide', - value: function hide() { - document.removeEventListener('click', this.handleDocumentClick, true); + // Deprecated hook for JSX spread, don't use this for anything. + __spread: __spread +}; - if (this._element) { - document.body.removeChild(this._element); - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); - this._element = null; +if (process.env.NODE_ENV !== 'production') { + var warnedForCreateClass = false; + if (canDefineProperty) { + Object.defineProperty(React, 'PropTypes', { + get: function () { + lowPriorityWarning(didWarnPropTypesDeprecated, 'Accessing PropTypes via the main React package is deprecated,' + ' and will be removed in React v16.0.' + ' Use the latest available v15.* prop-types package from npm instead.' + ' For info on usage, compatibility, migration and more, see ' + 'https://fb.me/prop-types-docs'); + didWarnPropTypesDeprecated = true; + return ReactPropTypes; } + }); - if (this._tether) { - this._tether.destroy(); - this._tether = null; - this.props.tetherRef(this._tether); + Object.defineProperty(React, 'createClass', { + get: function () { + lowPriorityWarning(warnedForCreateClass, 'Accessing createClass via the main React package is deprecated,' + ' and will be removed in React v16.0.' + " Use a plain JavaScript class instead. If you're not yet " + 'ready to migrate, create-react-class v15.* is available ' + 'on npm as a temporary, drop-in replacement. ' + 'For more info see https://fb.me/react-create-class'); + warnedForCreateClass = true; + return createReactClass; } - } - }, { - key: 'show', - value: function show() { - document.addEventListener('click', this.handleDocumentClick, true); + }); + } - this._element = document.createElement('div'); - this._element.className = this.props.className; - document.body.appendChild(this._element); - this.renderIntoSubtree(); - this._tether = new __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default.a(this.getTetherConfig()); - this.props.tetherRef(this._tether); - this._tether.position(); - this._element.childNodes[0].focus(); - } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); + // React.DOM factories are deprecated. Wrap these methods so that + // invocations of the React.DOM namespace and alert users to switch + // to the `react-dom-factories` package. + React.DOM = {}; + var warnedForFactories = false; + Object.keys(ReactDOMFactories).forEach(function (factory) { + React.DOM[factory] = function () { + if (!warnedForFactories) { + lowPriorityWarning(false, 'Accessing factories like React.DOM.%s has been deprecated ' + 'and will be removed in v16.0+. Use the ' + 'react-dom-factories package instead. ' + ' Version 1.0 provides a drop-in replacement.' + ' For more info, see https://fb.me/react-dom-factories', factory); + warnedForFactories = true; } + return ReactDOMFactories[factory].apply(ReactDOMFactories, arguments); + }; + }); +} - return this.props.toggle(); - } - }, { - key: 'renderIntoSubtree', - value: function renderIntoSubtree() { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); - } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _props = this.props, - children = _props.children, - style = _props.style; +module.exports = React; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(children, { style: style }); - } - }, { - key: 'render', - value: function render() { - return null; - } - }]); - return TetherContent; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +/***/ }), +/* 37 */ +/***/ (function(module, exports, __webpack_require__) { -TetherContent.propTypes = propTypes$10; -TetherContent.defaultProps = defaultProps$10; +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var propTypes$11 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$11 = { - tag: 'div' -}; +/** + * WARNING: DO NOT manually require this module. + * This is a replacement for `invariant(...)` used by the error code system + * and will _only_ be required by the corresponding babel pass. + * It always throws. + */ -var contextTypes = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired -}; +function reactProdInvariant(code) { + var argCount = arguments.length - 1; -var DropdownMenu = function DropdownMenu(props, context) { - var className = props.className, - cssModule = props.cssModule, - right = props.right, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'right', 'tag']); + var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'dropdown-menu', { 'dropdown-menu-right': right }), cssModule); + for (var argIdx = 0; argIdx < argCount; argIdx++) { + message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { tabIndex: '-1', 'aria-hidden': !context.isOpen, role: 'menu', className: classes })); -}; + message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; -DropdownMenu.propTypes = propTypes$11; -DropdownMenu.defaultProps = defaultProps$11; -DropdownMenu.contextTypes = contextTypes; + var error = new Error(message); + error.name = 'Invariant Violation'; + error.framesToPop = 1; // we don't care about reactProdInvariant's own frame -/* eslint react/no-find-dom-node: 0 */ -// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-find-dom-node.md + throw error; +} -var propTypes$9 = { - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - dropup: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - group: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool]), - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +module.exports = reactProdInvariant; -var defaultProps$9 = { - isOpen: false, - tag: 'div' -}; +/***/ }), +/* 38 */ +/***/ (function(module, exports, __webpack_require__) { -var childContextTypes = { - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var defaultTetherConfig = { - classPrefix: 'bs-tether', - classes: { element: 'dropdown', enabled: 'show' }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; -var Dropdown = function (_React$Component) { - inherits(Dropdown, _React$Component); - function Dropdown(props) { - classCallCheck(this, Dropdown); +var ReactRef = __webpack_require__(238); +var ReactInstrumentation = __webpack_require__(19); - var _this = possibleConstructorReturn(this, (Dropdown.__proto__ || Object.getPrototypeOf(Dropdown)).call(this, props)); +var warning = __webpack_require__(3); - _this.addEvents = _this.addEvents.bind(_this); - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.removeEvents = _this.removeEvents.bind(_this); - _this.toggle = _this.toggle.bind(_this); - return _this; - } +/** + * Helper to call ReactRef.attachRefs with this composite component, split out + * to avoid allocations in the transaction mount-ready queue. + */ +function attachRefs() { + ReactRef.attachRefs(this, this._currentElement); +} - createClass(Dropdown, [{ - key: 'getChildContext', - value: function getChildContext() { - return { - toggle: this.props.toggle, - isOpen: this.props.isOpen - }; - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - this.handleProps(); - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - this.handleProps(); +var ReactReconciler = { + /** + * Initializes the component, renders markup, and registers event listeners. + * + * @param {ReactComponent} internalInstance + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?object} the containing host component instance + * @param {?object} info about the host container + * @return {?string} Rendered markup to be inserted into the DOM. + * @final + * @internal + */ + mountComponent: function (internalInstance, transaction, hostParent, hostContainerInfo, context, parentDebugID) // 0 in production and for roots + { + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeMountComponent(internalInstance._debugID, internalInstance._currentElement, parentDebugID); } } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.removeEvents(); + var markup = internalInstance.mountComponent(transaction, hostParent, hostContainerInfo, context, parentDebugID); + if (internalInstance._currentElement && internalInstance._currentElement.ref != null) { + transaction.getReactMountReady().enqueue(attachRefs, internalInstance); } - }, { - key: 'getTetherTarget', - value: function getTetherTarget() { - var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); - - return container.querySelector('[data-toggle="dropdown"]'); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onMountComponent(internalInstance._debugID); + } } - }, { - key: 'getTetherConfig', - value: function getTetherConfig(childProps) { - var _this2 = this; - - var target = function target() { - return _this2.getTetherTarget(); - }; - var vElementAttach = 'top'; - var hElementAttach = 'left'; - var vTargetAttach = 'bottom'; - var hTargetAttach = 'left'; + return markup; + }, - if (childProps.right) { - hElementAttach = 'right'; - hTargetAttach = 'right'; - } + /** + * Returns a value that can be passed to + * ReactComponentEnvironment.replaceNodeWithMarkup. + */ + getHostNode: function (internalInstance) { + return internalInstance.getHostNode(); + }, - if (this.props.dropup) { - vElementAttach = 'bottom'; - vTargetAttach = 'top'; + /** + * Releases any resources allocated by `mountComponent`. + * + * @final + * @internal + */ + unmountComponent: function (internalInstance, safely) { + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUnmountComponent(internalInstance._debugID); } - - return _extends({}, defaultTetherConfig, { - attachment: vElementAttach + ' ' + hElementAttach, - targetAttachment: vTargetAttach + ' ' + hTargetAttach, - target: target - }, this.props.tether); } - }, { - key: 'addEvents', - value: function addEvents() { - document.addEventListener('click', this.handleDocumentClick, true); - } - }, { - key: 'removeEvents', - value: function removeEvents() { - document.removeEventListener('click', this.handleDocumentClick, true); + ReactRef.detachRefs(internalInstance, internalInstance._currentElement); + internalInstance.unmountComponent(safely); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUnmountComponent(internalInstance._debugID); + } } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); + }, - if (container.contains(e.target) && container !== e.target) { - return; - } + /** + * Update a component using a new element. + * + * @param {ReactComponent} internalInstance + * @param {ReactElement} nextElement + * @param {ReactReconcileTransaction} transaction + * @param {object} context + * @internal + */ + receiveComponent: function (internalInstance, nextElement, transaction, context) { + var prevElement = internalInstance._currentElement; - this.toggle(); - } - }, { - key: 'handleProps', - value: function handleProps() { - if (this.props.tether) { - return; - } + if (nextElement === prevElement && context === internalInstance._context) { + // Since elements are immutable after the owner is rendered, + // we can do a cheap identity compare here to determine if this is a + // superfluous reconcile. It's possible for state to be mutable but such + // change should trigger an update of the owner which would recreate + // the element. We explicitly check for the existence of an owner since + // it's possible for an element created outside a composite to be + // deeply mutated and reused. - if (this.props.isOpen) { - this.addEvents(); - } else { - this.removeEvents(); - } + // TODO: Bailing out early is just a perf optimization right? + // TODO: Removing the return statement should affect correctness? + return; } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); - } - return this.props.toggle(); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, nextElement); + } } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _this3 = this; - var _props = this.props, - tether = _props.tether, - children = _props.children, - attrs = objectWithoutProperties(_props, ['tether', 'children']); + var refsChanged = ReactRef.shouldUpdateRefs(prevElement, nextElement); - attrs.toggle = this.toggle; + if (refsChanged) { + ReactRef.detachRefs(internalInstance, prevElement); + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.map(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children), function (child) { - if (tether && child.type === DropdownMenu) { - var tetherConfig = _this3.getTetherConfig(child.props); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - _extends({}, attrs, { tether: tetherConfig }), - child - ); - } + internalInstance.receiveComponent(nextElement, transaction, context); - return child; - }); + if (refsChanged && internalInstance._currentElement && internalInstance._currentElement.ref != null) { + transaction.getReactMountReady().enqueue(attachRefs, internalInstance); } - }, { - key: 'render', - value: function render() { - var _classNames; - - var _omit = omit(this.props, ['toggle', 'tether']), - className = _omit.className, - cssModule = _omit.cssModule, - dropup = _omit.dropup, - group = _omit.group, - size = _omit.size, - Tag = _omit.tag, - isOpen = _omit.isOpen, - attributes = objectWithoutProperties(_omit, ['className', 'cssModule', 'dropup', 'group', 'size', 'tag', 'isOpen']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, (_classNames = { - 'btn-group': group - }, defineProperty(_classNames, 'btn-group-' + size, !!size), defineProperty(_classNames, 'dropdown', !group), defineProperty(_classNames, 'show', isOpen), defineProperty(_classNames, 'dropup', dropup), _classNames)), cssModule); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); + } + } + }, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { - className: classes - }), - this.renderChildren() - ); + /** + * Flush any dirty changes in a component. + * + * @param {ReactComponent} internalInstance + * @param {ReactReconcileTransaction} transaction + * @internal + */ + performUpdateIfNecessary: function (internalInstance, transaction, updateBatchNumber) { + if (internalInstance._updateBatchNumber !== updateBatchNumber) { + // The component's enqueued batch number should always be the current + // batch or the following one. + process.env.NODE_ENV !== 'production' ? warning(internalInstance._updateBatchNumber == null || internalInstance._updateBatchNumber === updateBatchNumber + 1, 'performUpdateIfNecessary: Unexpected batch number (current %s, ' + 'pending %s)', updateBatchNumber, internalInstance._updateBatchNumber) : void 0; + return; } - }]); - return Dropdown; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, internalInstance._currentElement); + } + } + internalInstance.performUpdateIfNecessary(transaction); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); + } + } + } +}; -Dropdown.propTypes = propTypes$9; -Dropdown.defaultProps = defaultProps$9; -Dropdown.childContextTypes = childContextTypes; +module.exports = ReactReconciler; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var propTypes$8 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 39 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$8 = { - tag: 'li' -}; +"use strict"; +/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var NavDropdown = function NavDropdown(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); +var DOMNamespaces = __webpack_require__(83); +var setInnerHTML = __webpack_require__(60); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({}, attributes, { tag: Tag, className: classes })); -}; +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); +var setTextContent = __webpack_require__(135); -NavDropdown.propTypes = propTypes$8; -NavDropdown.defaultProps = defaultProps$8; +var ELEMENT_NODE_TYPE = 1; +var DOCUMENT_FRAGMENT_NODE_TYPE = 11; -var propTypes$12 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - href: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; +/** + * In IE (8-11) and Edge, appending nodes with no children is dramatically + * faster than appending a full subtree, so we essentially queue up the + * .appendChild calls here and apply them so each node is added to its parent + * before any children are added. + * + * In other browsers, doing so is slower or neutral compared to the other order + * (in Firefox, twice as slow) so we only do this inversion in IE. + * + * See https://github.com/spicyj/innerhtml-vs-createelement-vs-clonenode. + */ +var enableLazy = typeof document !== 'undefined' && typeof document.documentMode === 'number' || typeof navigator !== 'undefined' && typeof navigator.userAgent === 'string' && /\bEdge\/\d/.test(navigator.userAgent); -var defaultProps$12 = { - tag: 'a' -}; +function insertTreeChildren(tree) { + if (!enableLazy) { + return; + } + var node = tree.node; + var children = tree.children; + if (children.length) { + for (var i = 0; i < children.length; i++) { + insertTreeBefore(node, children[i], null); + } + } else if (tree.html != null) { + setInnerHTML(node, tree.html); + } else if (tree.text != null) { + setTextContent(node, tree.text); + } +} -var NavLink = function (_React$Component) { - inherits(NavLink, _React$Component); +var insertTreeBefore = createMicrosoftUnsafeLocalFunction(function (parentNode, tree, referenceNode) { + // DocumentFragments aren't actually part of the DOM after insertion so + // appending children won't update the DOM. We need to ensure the fragment + // is properly populated first, breaking out of our lazy approach for just + // this level. Also, some <object> plugins (like Flash Player) will read + // <param> nodes immediately upon insertion into the DOM, so <object> + // must also be populated prior to insertion into the DOM. + if (tree.node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE || tree.node.nodeType === ELEMENT_NODE_TYPE && tree.node.nodeName.toLowerCase() === 'object' && (tree.node.namespaceURI == null || tree.node.namespaceURI === DOMNamespaces.html)) { + insertTreeChildren(tree); + parentNode.insertBefore(tree.node, referenceNode); + } else { + parentNode.insertBefore(tree.node, referenceNode); + insertTreeChildren(tree); + } +}); - function NavLink(props) { - classCallCheck(this, NavLink); +function replaceChildWithTree(oldNode, newTree) { + oldNode.parentNode.replaceChild(newTree.node, oldNode); + insertTreeChildren(newTree); +} - var _this = possibleConstructorReturn(this, (NavLink.__proto__ || Object.getPrototypeOf(NavLink)).call(this, props)); +function queueChild(parentTree, childTree) { + if (enableLazy) { + parentTree.children.push(childTree); + } else { + parentTree.node.appendChild(childTree.node); + } +} - _this.onClick = _this.onClick.bind(_this); - return _this; +function queueHTML(tree, html) { + if (enableLazy) { + tree.html = html; + } else { + setInnerHTML(tree.node, html); } +} - createClass(NavLink, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } +function queueText(tree, text) { + if (enableLazy) { + tree.text = text; + } else { + setTextContent(tree.node, text); + } +} - if (this.props.href === '#') { - e.preventDefault(); - } +function toString() { + return this.node.nodeName; +} - if (this.props.onClick) { - this.props.onClick(e); - } - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - active = _props.active, - Tag = _props.tag, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'active', 'tag', 'getRef']); +function DOMLazyTree(node) { + return { + node: node, + children: [], + html: null, + text: null, + toString: toString + }; +} +DOMLazyTree.insertTreeBefore = insertTreeBefore; +DOMLazyTree.replaceChildWithTree = replaceChildWithTree; +DOMLazyTree.queueChild = queueChild; +DOMLazyTree.queueHTML = queueHTML; +DOMLazyTree.queueText = queueText; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-link', { - disabled: attributes.disabled, - active: active - }), cssModule); +module.exports = DOMLazyTree; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, onClick: this.onClick, className: classes })); - } - }]); - return NavLink; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +/***/ }), +/* 40 */ +/***/ (function(module, exports, __webpack_require__) { -NavLink.propTypes = propTypes$12; -NavLink.defaultProps = defaultProps$12; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ -var propTypes$13 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +if (process.env.NODE_ENV !== 'production') { + var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && + Symbol.for && + Symbol.for('react.element')) || + 0xeac7; -var defaultProps$13 = { - tag: 'ol' -}; + var isValidElement = function(object) { + return typeof object === 'object' && + object !== null && + object.$$typeof === REACT_ELEMENT_TYPE; + }; -var Breadcrumb = function Breadcrumb(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + // By explicitly using `prop-types` you are opting into new development behavior. + // http://fb.me/prop-types-in-prod + var throwOnDirectAccess = true; + module.exports = __webpack_require__(125)(isValidElement, throwOnDirectAccess); +} else { + // By explicitly using `prop-types` you are opting into new production behavior. + // http://fb.me/prop-types-in-prod + module.exports = __webpack_require__(316)(); +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'breadcrumb'), cssModule); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 41 */ +/***/ (function(module, exports, __webpack_require__) { -Breadcrumb.propTypes = propTypes$13; -Breadcrumb.defaultProps = defaultProps$13; +var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! + Copyright (c) 2016 Jed Watson. + Licensed under the MIT License (MIT), see + http://jedwatson.github.io/classnames +*/ +/* global define */ -var propTypes$14 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +(function () { + 'use strict'; -var defaultProps$14 = { - tag: 'li' -}; + var hasOwn = {}.hasOwnProperty; -var BreadcrumbItem = function BreadcrumbItem(props) { - var className = props.className, - cssModule = props.cssModule, - active = props.active, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'active', 'tag']); + function classNames () { + var classes = []; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, 'breadcrumb-item'), cssModule); + for (var i = 0; i < arguments.length; i++) { + var arg = arguments[i]; + if (!arg) continue; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + var argType = typeof arg; -BreadcrumbItem.propTypes = propTypes$14; -BreadcrumbItem.defaultProps = defaultProps$14; + if (argType === 'string' || argType === 'number') { + classes.push(arg); + } else if (Array.isArray(arg)) { + classes.push(classNames.apply(null, arg)); + } else if (argType === 'object') { + for (var key in arg) { + if (hasOwn.call(arg, key) && arg[key]) { + classes.push(key); + } + } + } + } -var propTypes$15 = { - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + return classes.join(' '); + } -var defaultProps$15 = { - color: 'secondary', - tag: 'button' -}; + if (typeof module !== 'undefined' && module.exports) { + module.exports = classNames; + } else if (true) { + // register as 'classnames', consistent with npm package name + !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function () { + return classNames; + }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); + } else { + window.classNames = classNames; + } +}()); -var Button = function (_React$Component) { - inherits(Button, _React$Component); - function Button(props) { - classCallCheck(this, Button); +/***/ }), +/* 42 */ +/***/ (function(module, exports, __webpack_require__) { - var _this = possibleConstructorReturn(this, (Button.__proto__ || Object.getPrototypeOf(Button)).call(this, props)); +/* WEBPACK VAR INJECTION */(function(Buffer) {// prototype class for hash functions +function Hash (blockSize, finalSize) { + this._block = new Buffer(blockSize) + this._finalSize = finalSize + this._blockSize = blockSize + this._len = 0 + this._s = 0 +} - _this.onClick = _this.onClick.bind(_this); - return _this; +Hash.prototype.update = function (data, enc) { + if (typeof data === 'string') { + enc = enc || 'utf8' + data = new Buffer(data, enc) } - createClass(Button, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } + var l = this._len += data.length + var s = this._s || 0 + var f = 0 + var buffer = this._block - if (this.props.onClick) { - this.props.onClick(e); - } + while (s < l) { + var t = Math.min(data.length, f + this._blockSize - (s % this._blockSize)) + var ch = (t - f) + + for (var i = 0; i < ch; i++) { + buffer[(s % this._blockSize) + i] = data[i + f] } - }, { - key: 'render', - value: function render() { - var _props = this.props, - active = _props.active, - block = _props.block, - className = _props.className, - cssModule = _props.cssModule, - color = _props.color, - outline = _props.outline, - size = _props.size, - Tag = _props.tag, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['active', 'block', 'className', 'cssModule', 'color', 'outline', 'size', 'tag', 'getRef']); + s += ch + f += ch - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn', 'btn' + (outline ? '-outline' : '') + '-' + color, size ? 'btn-' + size : false, block ? 'btn-block' : false, { active: active, disabled: this.props.disabled }), cssModule); + if ((s % this._blockSize) === 0) { + this._update(buffer) + } + } + this._s = s - if (attributes.href && Tag === 'button') { - Tag = 'a'; - } + return this +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ - type: Tag === 'button' && attributes.onClick ? 'button' : undefined - }, attributes, { - className: classes, - ref: getRef, - onClick: this.onClick - })); - } - }]); - return Button; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +Hash.prototype.digest = function (enc) { + // Suppose the length of the message M, in bits, is l + var l = this._len * 8 -Button.propTypes = propTypes$15; -Button.defaultProps = defaultProps$15; + // Append the bit 1 to the end of the message + this._block[this._len % this._blockSize] = 0x80 -var propTypes$16 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node -}; + // and then k zero bits, where k is the smallest non-negative solution to the equation (l + 1 + k) === finalSize mod blockSize + this._block.fill(0, this._len % this._blockSize + 1) -var ButtonDropdown = function ButtonDropdown(props) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({ group: true }, props)); -}; + if (l % (this._blockSize * 8) >= this._finalSize * 8) { + this._update(this._block) + this._block.fill(0) + } -ButtonDropdown.propTypes = propTypes$16; + // to this append the block which is equal to the number l written in binary + // TODO: handle case where l is > Math.pow(2, 29) + this._block.writeInt32BE(l, this._blockSize - 4) -var propTypes$17 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; + var hash = this._update(this._block) || this._hash() -var defaultProps$16 = { - tag: 'div', - role: 'group' -}; + return enc ? hash.toString(enc) : hash +} -var ButtonGroup = function ButtonGroup(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - vertical = props.vertical, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'vertical', 'tag']); +Hash.prototype._update = function () { + throw new Error('_update must be implemented by subclass') +} +module.exports = Hash - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, size ? 'btn-group-' + size : false, vertical ? 'btn-group-vertical' : 'btn-group'), cssModule); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 43 */ +/***/ (function(module, exports, __webpack_require__) { -ButtonGroup.propTypes = propTypes$17; -ButtonGroup.defaultProps = defaultProps$16; +"use strict"; +/* WEBPACK VAR INJECTION */(function(global, process) { -var propTypes$18 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string -}; +function oldBrowser () { + throw new Error('secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11') +} -var defaultProps$17 = { - tag: 'div', - role: 'toolbar' -}; +var Buffer = __webpack_require__(7).Buffer +var crypto = global.crypto || global.msCrypto -var ButtonToolbar = function ButtonToolbar(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +if (crypto && crypto.getRandomValues) { + module.exports = randomBytes +} else { + module.exports = oldBrowser +} +function randomBytes (size, cb) { + // phantomjs needs to throw + if (size > 65536) throw new Error('requested too many random bytes') + // in case browserify isn't using the Uint8Array version + var rawBytes = new global.Uint8Array(size) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn-toolbar'), cssModule); + // This will not work in older browsers. + // See https://developer.mozilla.org/en-US/docs/Web/API/window.crypto.getRandomValues + if (size > 0) { // getRandomValues fails on IE if size == 0 + crypto.getRandomValues(rawBytes) + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + // XXX: phantomjs doesn't like a buffer being passed here + var bytes = Buffer.from(rawBytes.buffer) -ButtonToolbar.propTypes = propTypes$18; -ButtonToolbar.defaultProps = defaultProps$17; + if (typeof cb === 'function') { + return process.nextTick(function () { + cb(null, bytes) + }) + } -var propTypes$19 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - divider: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - header: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; + return bytes +} -var contextTypes$1 = { - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) -var defaultProps$18 = { - tag: 'button', - toggle: true -}; +/***/ }), +/* 44 */ +/***/ (function(module, exports, __webpack_require__) { -var DropdownItem = function (_React$Component) { - inherits(DropdownItem, _React$Component); +var createHash = __webpack_require__(27) - function DropdownItem(props) { - classCallCheck(this, DropdownItem); +function ripemd160 (buffer) { + return createHash('rmd160').update(buffer).digest() +} - var _this = possibleConstructorReturn(this, (DropdownItem.__proto__ || Object.getPrototypeOf(DropdownItem)).call(this, props)); +function sha1 (buffer) { + return createHash('sha1').update(buffer).digest() +} - _this.onClick = _this.onClick.bind(_this); - _this.getTabIndex = _this.getTabIndex.bind(_this); - return _this; - } +function sha256 (buffer) { + return createHash('sha256').update(buffer).digest() +} - createClass(DropdownItem, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled || this.props.header || this.props.divider) { - e.preventDefault(); - return; - } +function hash160 (buffer) { + return ripemd160(sha256(buffer)) +} - if (this.props.onClick) { - this.props.onClick(e); - } +function hash256 (buffer) { + return sha256(sha256(buffer)) +} - if (this.props.toggle) { - this.context.toggle(); - } - } - }, { - key: 'getTabIndex', - value: function getTabIndex() { - if (this.props.disabled || this.props.header || this.props.divider) { - return '-1'; - } +module.exports = { + hash160: hash160, + hash256: hash256, + ripemd160: ripemd160, + sha1: sha1, + sha256: sha256 +} - return '0'; - } - }, { - key: 'render', - value: function render() { - var tabIndex = this.getTabIndex(); - var _omit = omit(this.props, ['toggle']), - className = _omit.className, - cssModule = _omit.cssModule, - divider = _omit.divider, - Tag = _omit.tag, - header = _omit.header, - active = _omit.active, - props = objectWithoutProperties(_omit, ['className', 'cssModule', 'divider', 'tag', 'header', 'active']); +/***/ }), +/* 45 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - disabled: props.disabled, - 'dropdown-item': !divider && !header, - active: active, - 'dropdown-header': header, - 'dropdown-divider': divider - }), cssModule); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if (Tag === 'button') { - if (header) { - Tag = 'h6'; - } else if (divider) { - Tag = 'div'; - } else if (props.href) { - Tag = 'a'; - } - } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ - type: Tag === 'button' && (props.onClick || this.props.toggle) ? 'button' : undefined - }, props, { - tabIndex: tabIndex, - className: classes, - onClick: this.onClick - })); - } - }]); - return DropdownItem; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -DropdownItem.propTypes = propTypes$19; -DropdownItem.defaultProps = defaultProps$18; -DropdownItem.contextTypes = contextTypes$1; +var EventPluginHub = __webpack_require__(46); +var EventPluginUtils = __webpack_require__(77); -var propTypes$20 = { - caret: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - 'data-toggle': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - 'aria-haspopup': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - split: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - nav: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +var accumulateInto = __webpack_require__(127); +var forEachAccumulated = __webpack_require__(128); +var warning = __webpack_require__(3); -var defaultProps$19 = { - 'data-toggle': 'dropdown', - 'aria-haspopup': true, - color: 'secondary' -}; +var getListener = EventPluginHub.getListener; -var contextTypes$2 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired -}; +/** + * Some event types have a notion of different registration names for different + * "phases" of propagation. This finds listeners by a given phase. + */ +function listenerAtPhase(inst, event, propagationPhase) { + var registrationName = event.dispatchConfig.phasedRegistrationNames[propagationPhase]; + return getListener(inst, registrationName); +} -var DropdownToggle = function (_React$Component) { - inherits(DropdownToggle, _React$Component); +/** + * Tags a `SyntheticEvent` with dispatched listeners. Creating this function + * here, allows us to not have to bind or create functions for each event. + * Mutating the event's members allows us to not have to create a wrapping + * "dispatch" object that pairs the event with the listener. + */ +function accumulateDirectionalDispatches(inst, phase, event) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(inst, 'Dispatching inst must not be null') : void 0; + } + var listener = listenerAtPhase(inst, event, phase); + if (listener) { + event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); + event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); + } +} - function DropdownToggle(props) { - classCallCheck(this, DropdownToggle); +/** + * Collect dispatches (must be entirely collected before dispatching - see unit + * tests). Lazily allocate the array to conserve memory. We must loop through + * each event and perform the traversal for each one. We cannot perform a + * single traversal for the entire collection of events because each event may + * have a different target. + */ +function accumulateTwoPhaseDispatchesSingle(event) { + if (event && event.dispatchConfig.phasedRegistrationNames) { + EventPluginUtils.traverseTwoPhase(event._targetInst, accumulateDirectionalDispatches, event); + } +} - var _this = possibleConstructorReturn(this, (DropdownToggle.__proto__ || Object.getPrototypeOf(DropdownToggle)).call(this, props)); +/** + * Same as `accumulateTwoPhaseDispatchesSingle`, but skips over the targetID. + */ +function accumulateTwoPhaseDispatchesSingleSkipTarget(event) { + if (event && event.dispatchConfig.phasedRegistrationNames) { + var targetInst = event._targetInst; + var parentInst = targetInst ? EventPluginUtils.getParentInstance(targetInst) : null; + EventPluginUtils.traverseTwoPhase(parentInst, accumulateDirectionalDispatches, event); + } +} - _this.onClick = _this.onClick.bind(_this); - return _this; +/** + * Accumulates without regard to direction, does not look for phased + * registration names. Same as `accumulateDirectDispatchesSingle` but without + * requiring that the `dispatchMarker` be the same as the dispatched ID. + */ +function accumulateDispatches(inst, ignoredDirection, event) { + if (event && event.dispatchConfig.registrationName) { + var registrationName = event.dispatchConfig.registrationName; + var listener = getListener(inst, registrationName); + if (listener) { + event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); + event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); + } } +} - createClass(DropdownToggle, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } +/** + * Accumulates dispatches on an `SyntheticEvent`, but only for the + * `dispatchMarker`. + * @param {SyntheticEvent} event + */ +function accumulateDirectDispatchesSingle(event) { + if (event && event.dispatchConfig.registrationName) { + accumulateDispatches(event._targetInst, null, event); + } +} - if (this.props.nav && !this.props.tag) { - e.preventDefault(); - } +function accumulateTwoPhaseDispatches(events) { + forEachAccumulated(events, accumulateTwoPhaseDispatchesSingle); +} - if (this.props.onClick) { - this.props.onClick(e); - } +function accumulateTwoPhaseDispatchesSkipTarget(events) { + forEachAccumulated(events, accumulateTwoPhaseDispatchesSingleSkipTarget); +} - this.context.toggle(); - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - color = _props.color, - cssModule = _props.cssModule, - caret = _props.caret, - split = _props.split, - nav = _props.nav, - tag = _props.tag, - props = objectWithoutProperties(_props, ['className', 'color', 'cssModule', 'caret', 'split', 'nav', 'tag']); +function accumulateEnterLeaveDispatches(leave, enter, from, to) { + EventPluginUtils.traverseEnterLeave(from, to, accumulateDispatches, leave, enter); +} - var ariaLabel = props['aria-label'] || 'Toggle Dropdown'; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - 'dropdown-toggle': caret || split, - 'dropdown-toggle-split': split, - active: this.context.isOpen, - 'nav-link': nav - }), cssModule); - var children = props.children || __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { className: 'sr-only' }, - ariaLabel - ); +function accumulateDirectDispatches(events) { + forEachAccumulated(events, accumulateDirectDispatchesSingle); +} - var Tag = void 0; +/** + * A small set of propagation patterns, each of which will accept a small amount + * of information, and generate a set of "dispatch ready event objects" - which + * are sets of events that have already been annotated with a set of dispatched + * listener functions/ids. The API is designed this way to discourage these + * propagation strategies from actually executing the dispatches, since we + * always want to collect the entire set of dispatches before executing event a + * single one. + * + * @constructor EventPropagators + */ +var EventPropagators = { + accumulateTwoPhaseDispatches: accumulateTwoPhaseDispatches, + accumulateTwoPhaseDispatchesSkipTarget: accumulateTwoPhaseDispatchesSkipTarget, + accumulateDirectDispatches: accumulateDirectDispatches, + accumulateEnterLeaveDispatches: accumulateEnterLeaveDispatches +}; - if (nav && !tag) { - Tag = 'a'; - props.href = '#'; - } else if (!tag) { - Tag = Button; - props.color = color; - } else { - Tag = tag; - } +module.exports = EventPropagators; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, props, { - className: classes, - onClick: this.onClick, - 'aria-haspopup': 'true', - 'aria-expanded': this.context.isOpen, - children: children - })); - } - }]); - return DropdownToggle; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +/***/ }), +/* 46 */ +/***/ (function(module, exports, __webpack_require__) { -DropdownToggle.propTypes = propTypes$20; -DropdownToggle.defaultProps = defaultProps$19; -DropdownToggle.contextTypes = contextTypes$2; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var propTypes$21 = { - baseClass: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - baseClassIn: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionAppear: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - transitionEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - transitionLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; -var defaultProps$20 = { - tag: 'div', - baseClass: 'fade', - baseClassIn: 'show', - transitionAppearTimeout: 0, - transitionEnterTimeout: 0, - transitionLeaveTimeout: 0, - transitionAppear: true, - transitionEnter: true, - transitionLeave: true -}; -var Fade = function (_React$Component) { - inherits(Fade, _React$Component); +var _prodInvariant = __webpack_require__(5); - function Fade(props) { - classCallCheck(this, Fade); +var EventPluginRegistry = __webpack_require__(57); +var EventPluginUtils = __webpack_require__(77); +var ReactErrorUtils = __webpack_require__(78); - var _this = possibleConstructorReturn(this, (Fade.__proto__ || Object.getPrototypeOf(Fade)).call(this, props)); +var accumulateInto = __webpack_require__(127); +var forEachAccumulated = __webpack_require__(128); +var invariant = __webpack_require__(2); - _this.state = { - mounted: !props.transitionAppear - }; +/** + * Internal store for event listeners + */ +var listenerBank = {}; - _this.onLeave = _this.onLeave.bind(_this); - _this.onEnter = _this.onEnter.bind(_this); - _this.timers = []; - return _this; - } +/** + * Internal queue of events that have accumulated their dispatches and are + * waiting to have their dispatches executed. + */ +var eventQueue = null; - createClass(Fade, [{ - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.timers.forEach(function (timer) { - return clearTimeout(timer); - }); - } - }, { - key: 'onEnter', - value: function onEnter(cb) { - var _this2 = this; +/** + * Dispatches an event and releases it back into the pool, unless persistent. + * + * @param {?object} event Synthetic event to be dispatched. + * @param {boolean} simulated If the event is simulated (changes exn behavior) + * @private + */ +var executeDispatchesAndRelease = function (event, simulated) { + if (event) { + EventPluginUtils.executeDispatchesInOrder(event, simulated); - return function () { - cb(); - if (_this2.props.onEnter) { - _this2.props.onEnter(); - } - }; + if (!event.isPersistent()) { + event.constructor.release(event); } - }, { - key: 'onLeave', - value: function onLeave(cb) { - var _this3 = this; + } +}; +var executeDispatchesAndReleaseSimulated = function (e) { + return executeDispatchesAndRelease(e, true); +}; +var executeDispatchesAndReleaseTopLevel = function (e) { + return executeDispatchesAndRelease(e, false); +}; - return function () { - cb(); - if (_this3.props.onLeave) { - _this3.props.onLeave(); - } - }; - } - }, { - key: 'componentWillAppear', - value: function componentWillAppear(cb) { - if (!this.props.transitionAppear) { - this.onEnter(cb)(); - } +var getDictionaryKey = function (inst) { + // Prevents V8 performance issue: + // https://github.com/facebook/react/pull/7232 + return '.' + inst._rootNodeID; +}; - this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionAppearTimeout)); - } - }, { - key: 'componentDidAppear', - value: function componentDidAppear() { - this.setState({ - mounted: true - }); - } - }, { - key: 'componentWillEnter', - value: function componentWillEnter(cb) { - if (!this.props.transitionEnter) { - this.onEnter(cb)(); - } +function isInteractive(tag) { + return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; +} - this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionEnterTimeout)); - } - }, { - key: 'componentDidEnter', - value: function componentDidEnter() { - this.setState({ - mounted: true - }); - } - }, { - key: 'componentWillLeave', - value: function componentWillLeave(cb) { - this.setState({ - mounted: false - }); +function shouldPreventMouseEvent(name, type, props) { + switch (name) { + case 'onClick': + case 'onClickCapture': + case 'onDoubleClick': + case 'onDoubleClickCapture': + case 'onMouseDown': + case 'onMouseDownCapture': + case 'onMouseMove': + case 'onMouseMoveCapture': + case 'onMouseUp': + case 'onMouseUpCapture': + return !!(props.disabled && isInteractive(type)); + default: + return false; + } +} - if (!this.props.transitionLeave) { - this.onLeave(cb)(); - } +/** + * This is a unified interface for event plugins to be installed and configured. + * + * Event plugins can implement the following properties: + * + * `extractEvents` {function(string, DOMEventTarget, string, object): *} + * Required. When a top-level event is fired, this method is expected to + * extract synthetic events that will in turn be queued and dispatched. + * + * `eventTypes` {object} + * Optional, plugins that fire events must publish a mapping of registration + * names that are used to register listeners. Values of this mapping must + * be objects that contain `registrationName` or `phasedRegistrationNames`. + * + * `executeDispatch` {function(object, function, string)} + * Optional, allows plugins to override how an event gets dispatched. By + * default, the listener is simply invoked. + * + * Each plugin that is injected into `EventsPluginHub` is immediately operable. + * + * @public + */ +var EventPluginHub = { + /** + * Methods for injecting dependencies. + */ + injection: { + /** + * @param {array} InjectedEventPluginOrder + * @public + */ + injectEventPluginOrder: EventPluginRegistry.injectEventPluginOrder, - this.timers.push(setTimeout(this.onLeave(cb), this.props.transitionLeaveTimeout)); - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - baseClass = _props.baseClass, - baseClassIn = _props.baseClassIn, - className = _props.className, - cssModule = _props.cssModule, - Tag = _props.tag; + /** + * @param {object} injectedNamesToPlugins Map from names to plugin modules. + */ + injectEventPluginsByName: EventPluginRegistry.injectEventPluginsByName + }, - var attributes = omit(this.props, Object.keys(propTypes$21)); + /** + * Stores `listener` at `listenerBank[registrationName][key]`. Is idempotent. + * + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @param {function} listener The callback to store. + */ + putListener: function (inst, registrationName, listener) { + !(typeof listener === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected %s listener to be a function, instead got type %s', registrationName, typeof listener) : _prodInvariant('94', registrationName, typeof listener) : void 0; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, baseClass, this.state.mounted ? baseClassIn : false), cssModule); + var key = getDictionaryKey(inst); + var bankForRegistrationName = listenerBank[registrationName] || (listenerBank[registrationName] = {}); + bankForRegistrationName[key] = listener; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.didPutListener) { + PluginModule.didPutListener(inst, registrationName, listener); } - }]); - return Fade; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - -Fade.propTypes = propTypes$21; -Fade.defaultProps = defaultProps$20; + }, -var propTypes$22 = { - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - pill: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @return {?function} The stored callback. + */ + getListener: function (inst, registrationName) { + // TODO: shouldPreventMouseEvent is DOM-specific and definitely should not + // live here; needs to be moved to a better place soon + var bankForRegistrationName = listenerBank[registrationName]; + if (shouldPreventMouseEvent(registrationName, inst._currentElement.type, inst._currentElement.props)) { + return null; + } + var key = getDictionaryKey(inst); + return bankForRegistrationName && bankForRegistrationName[key]; + }, -var defaultProps$21 = { - color: 'default', - pill: false, - tag: 'span' -}; + /** + * Deletes a listener from the registration bank. + * + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + */ + deleteListener: function (inst, registrationName) { + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.willDeleteListener) { + PluginModule.willDeleteListener(inst, registrationName); + } -var Badge = function Badge(props) { - var className = props.className, - cssModule = props.cssModule, - color = props.color, - pill = props.pill, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'pill', 'tag']); + var bankForRegistrationName = listenerBank[registrationName]; + // TODO: This should never be null -- when is it? + if (bankForRegistrationName) { + var key = getDictionaryKey(inst); + delete bankForRegistrationName[key]; + } + }, + /** + * Deletes all listeners for the DOM element with the supplied ID. + * + * @param {object} inst The instance, which is the source of events. + */ + deleteAllListeners: function (inst) { + var key = getDictionaryKey(inst); + for (var registrationName in listenerBank) { + if (!listenerBank.hasOwnProperty(registrationName)) { + continue; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'badge', 'badge-' + color, pill ? 'badge-pill' : false), cssModule); + if (!listenerBank[registrationName][key]) { + continue; + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.willDeleteListener) { + PluginModule.willDeleteListener(inst, registrationName); + } -Badge.propTypes = propTypes$22; -Badge.defaultProps = defaultProps$21; + delete listenerBank[registrationName][key]; + } + }, -var propTypes$23 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * Allows registered plugins an opportunity to extract events from top-level + * native browser events. + * + * @return {*} An accumulation of synthetic events. + * @internal + */ + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var events; + var plugins = EventPluginRegistry.plugins; + for (var i = 0; i < plugins.length; i++) { + // Not every plugin in the ordering may be loaded at runtime. + var possiblePlugin = plugins[i]; + if (possiblePlugin) { + var extractedEvents = possiblePlugin.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); + if (extractedEvents) { + events = accumulateInto(events, extractedEvents); + } + } + } + return events; + }, -var defaultProps$22 = { - tag: 'div' -}; + /** + * Enqueues a synthetic event that should be dispatched when + * `processEventQueue` is invoked. + * + * @param {*} events An accumulation of synthetic events. + * @internal + */ + enqueueEvents: function (events) { + if (events) { + eventQueue = accumulateInto(eventQueue, events); + } + }, -var Card = function Card(props) { - var className = props.className, - cssModule = props.cssModule, - color = props.color, - block = props.block, - inverse = props.inverse, - outline = props.outline, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'block', 'inverse', 'outline', 'tag']); + /** + * Dispatches all synthetic events on the event queue. + * + * @internal + */ + processEventQueue: function (simulated) { + // Set `eventQueue` to null before processing it so that we can tell if more + // events get enqueued while processing. + var processingEventQueue = eventQueue; + eventQueue = null; + if (simulated) { + forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseSimulated); + } else { + forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseTopLevel); + } + !!eventQueue ? process.env.NODE_ENV !== 'production' ? invariant(false, 'processEventQueue(): Additional events were enqueued while processing an event queue. Support for this has not yet been implemented.') : _prodInvariant('95') : void 0; + // This would be a good time to rethrow if any of the event handlers threw. + ReactErrorUtils.rethrowCaughtError(); + }, - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card', inverse ? 'card-inverse' : false, block ? 'card-block' : false, color ? 'card' + (outline ? '-outline' : '') + '-' + color : false), cssModule); + /** + * These are needed for tests only. Do not use! + */ + __purge: function () { + listenerBank = {}; + }, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + __getListenerBank: function () { + return listenerBank; + } }; -Card.propTypes = propTypes$23; -Card.defaultProps = defaultProps$22; +module.exports = EventPluginHub; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var propTypes$24 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 47 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$23 = { - tag: 'div' -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var CardGroup = function CardGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-group'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var SyntheticEvent = __webpack_require__(26); -CardGroup.propTypes = propTypes$24; -CardGroup.defaultProps = defaultProps$23; +var getEventTarget = __webpack_require__(79); -var propTypes$25 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/** + * @interface UIEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var UIEventInterface = { + view: function (event) { + if (event.view) { + return event.view; + } -var defaultProps$24 = { - tag: 'div' + var target = getEventTarget(event); + if (target.window === target) { + // target is a window object + return target; + } + + var doc = target.ownerDocument; + // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. + if (doc) { + return doc.defaultView || doc.parentWindow; + } else { + return window; + } + }, + detail: function (event) { + return event.detail || 0; + } }; -var CardDeck = function CardDeck(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticUIEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-deck'), cssModule); +SyntheticEvent.augmentClass(SyntheticUIEvent, UIEventInterface); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +module.exports = SyntheticUIEvent; -CardDeck.propTypes = propTypes$25; -CardDeck.defaultProps = defaultProps$24; +/***/ }), +/* 48 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$26 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var defaultProps$25 = { - tag: 'div' -}; -var CardColumns = function CardColumns(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-columns'), cssModule); +/** + * `ReactInstanceMap` maintains a mapping from a public facing stateful + * instance (key) and the internal representation (value). This allows public + * methods to accept the user facing instance as an argument and map them back + * to internal methods. + */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +// TODO: Replace this with ES6: var ReactInstanceMap = new Map(); -CardColumns.propTypes = propTypes$26; -CardColumns.defaultProps = defaultProps$25; +var ReactInstanceMap = { + /** + * This API should be called `delete` but we'd have to make sure to always + * transform these to strings for IE support. When this transform is fully + * supported we can rename it. + */ + remove: function (key) { + key._reactInternalInstance = undefined; + }, -var propTypes$27 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + get: function (key) { + return key._reactInternalInstance; + }, -var defaultProps$26 = { - tag: 'div' + has: function (key) { + return key._reactInternalInstance !== undefined; + }, + + set: function (key, value) { + key._reactInternalInstance = value; + } }; -var CardBlock = function CardBlock(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +module.exports = ReactInstanceMap; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-block'), cssModule); +/***/ }), +/* 49 */ +/***/ (function(module, exports, __webpack_require__) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/* WEBPACK VAR INJECTION */(function(Buffer) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// NOTE: These type checking functions intentionally don't use `instanceof` +// because it is fragile and can be easily faked with `Object.create()`. + +function isArray(arg) { + if (Array.isArray) { + return Array.isArray(arg); + } + return objectToString(arg) === '[object Array]'; +} +exports.isArray = isArray; -CardBlock.propTypes = propTypes$27; -CardBlock.defaultProps = defaultProps$26; +function isBoolean(arg) { + return typeof arg === 'boolean'; +} +exports.isBoolean = isBoolean; -var propTypes$28 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function isNull(arg) { + return arg === null; +} +exports.isNull = isNull; -var defaultProps$27 = { - tag: 'a' -}; +function isNullOrUndefined(arg) { + return arg == null; +} +exports.isNullOrUndefined = isNullOrUndefined; -var CardLink = function CardLink(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - getRef = props.getRef, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'getRef']); +function isNumber(arg) { + return typeof arg === 'number'; +} +exports.isNumber = isNumber; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-link'), cssModule); +function isString(arg) { + return typeof arg === 'string'; +} +exports.isString = isString; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); -}; +function isSymbol(arg) { + return typeof arg === 'symbol'; +} +exports.isSymbol = isSymbol; -CardLink.propTypes = propTypes$28; -CardLink.defaultProps = defaultProps$27; +function isUndefined(arg) { + return arg === void 0; +} +exports.isUndefined = isUndefined; -var propTypes$29 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function isRegExp(re) { + return objectToString(re) === '[object RegExp]'; +} +exports.isRegExp = isRegExp; -var defaultProps$28 = { - tag: 'div' -}; +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} +exports.isObject = isObject; -var CardFooter = function CardFooter(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +function isDate(d) { + return objectToString(d) === '[object Date]'; +} +exports.isDate = isDate; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-footer'), cssModule); +function isError(e) { + return (objectToString(e) === '[object Error]' || e instanceof Error); +} +exports.isError = isError; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +function isFunction(arg) { + return typeof arg === 'function'; +} +exports.isFunction = isFunction; + +function isPrimitive(arg) { + return arg === null || + typeof arg === 'boolean' || + typeof arg === 'number' || + typeof arg === 'string' || + typeof arg === 'symbol' || // ES6 symbol + typeof arg === 'undefined'; +} +exports.isPrimitive = isPrimitive; -CardFooter.propTypes = propTypes$29; -CardFooter.defaultProps = defaultProps$28; +exports.isBuffer = Buffer.isBuffer; -var propTypes$30 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function objectToString(o) { + return Object.prototype.toString.call(o); +} -var defaultProps$29 = { - tag: 'div' -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var CardHeader = function CardHeader(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/***/ }), +/* 50 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-header'), cssModule); +"use strict"; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -CardHeader.propTypes = propTypes$30; -CardHeader.defaultProps = defaultProps$29; +var utils = __webpack_require__(25); +var assert = __webpack_require__(21); -var propTypes$31 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function BlockHash() { + this.pending = null; + this.pendingTotal = 0; + this.blockSize = this.constructor.blockSize; + this.outSize = this.constructor.outSize; + this.hmacStrength = this.constructor.hmacStrength; + this.padLength = this.constructor.padLength / 8; + this.endian = 'big'; -var defaultProps$30 = { - tag: 'img' -}; + this._delta8 = this.blockSize / 8; + this._delta32 = this.blockSize / 32; +} +exports.BlockHash = BlockHash; -var CardImg = function CardImg(props) { - var className = props.className, - cssModule = props.cssModule, - top = props.top, - bottom = props.bottom, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'top', 'bottom', 'tag']); +BlockHash.prototype.update = function update(msg, enc) { + // Convert message to array, pad it, and join into 32bit blocks + msg = utils.toArray(msg, enc); + if (!this.pending) + this.pending = msg; + else + this.pending = this.pending.concat(msg); + this.pendingTotal += msg.length; + // Enough data, try updating + if (this.pending.length >= this._delta8) { + msg = this.pending; - var cardImgClassName = 'card-img'; - if (top) { - cardImgClassName = 'card-img-top'; - } - if (bottom) { - cardImgClassName = 'card-img-bottom'; - } + // Process pending data in blocks + var r = msg.length % this._delta8; + this.pending = msg.slice(msg.length - r, msg.length); + if (this.pending.length === 0) + this.pending = null; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, cardImgClassName), cssModule); + msg = utils.join32(msg, 0, msg.length - r, this.endian); + for (var i = 0; i < msg.length; i += this._delta32) + this._update(msg, i, i + this._delta32); + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + return this; }; -CardImg.propTypes = propTypes$31; -CardImg.defaultProps = defaultProps$30; - -var propTypes$32 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +BlockHash.prototype.digest = function digest(enc) { + this.update(this._pad()); + assert(this.pending === null); -var defaultProps$31 = { - tag: 'div' + return this._digest(enc); }; -var CardImgOverlay = function CardImgOverlay(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +BlockHash.prototype._pad = function pad() { + var len = this.pendingTotal; + var bytes = this._delta8; + var k = bytes - ((len + this.padLength) % bytes); + var res = new Array(k + this.padLength); + res[0] = 0x80; + for (var i = 1; i < k; i++) + res[i] = 0; + + // Append length + len <<= 3; + if (this.endian === 'big') { + for (var t = 8; t < this.padLength; t++) + res[i++] = 0; + + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = (len >>> 24) & 0xff; + res[i++] = (len >>> 16) & 0xff; + res[i++] = (len >>> 8) & 0xff; + res[i++] = len & 0xff; + } else { + res[i++] = len & 0xff; + res[i++] = (len >>> 8) & 0xff; + res[i++] = (len >>> 16) & 0xff; + res[i++] = (len >>> 24) & 0xff; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-img-overlay'), cssModule); + for (t = 8; t < this.padLength; t++) + res[i++] = 0; + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + return res; }; -CardImgOverlay.propTypes = propTypes$32; -CardImgOverlay.defaultProps = defaultProps$31; -var propTypes$33 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 51 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$32 = { - tag: 'h6' -}; +/* WEBPACK VAR INJECTION */(function(Buffer) {module.exports = function xor (a, b) { + var length = Math.min(a.length, b.length) + var buffer = new Buffer(length) -var CardSubtitle = function CardSubtitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + for (var i = 0; i < length; ++i) { + buffer[i] = a[i] ^ b[i] + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-subtitle'), cssModule); + return buffer +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -CardSubtitle.propTypes = propTypes$33; -CardSubtitle.defaultProps = defaultProps$32; +/***/ }), +/* 52 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$34 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var asn1 = exports; -var defaultProps$33 = { - tag: 'p' -}; +asn1.bignum = __webpack_require__(11); -var CardText = function CardText(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +asn1.define = __webpack_require__(440).define; +asn1.base = __webpack_require__(53); +asn1.constants = __webpack_require__(192); +asn1.decoders = __webpack_require__(446); +asn1.encoders = __webpack_require__(448); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-text'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 53 */ +/***/ (function(module, exports, __webpack_require__) { -CardText.propTypes = propTypes$34; -CardText.defaultProps = defaultProps$33; +var base = exports; -var propTypes$35 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +base.Reporter = __webpack_require__(443).Reporter; +base.DecoderBuffer = __webpack_require__(191).DecoderBuffer; +base.EncoderBuffer = __webpack_require__(191).EncoderBuffer; +base.Node = __webpack_require__(444); -var defaultProps$34 = { - tag: 'h4' -}; -var CardTitle = function CardTitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/***/ }), +/* 54 */ +/***/ (function(module, exports) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-title'), cssModule); +// https://en.bitcoin.it/wiki/List_of_address_prefixes +// Dogecoin BIP32 is a proposed standard: https://bitcointalk.org/index.php?topic=409731 - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +module.exports = { + bitcoin: { + messagePrefix: '\x18Bitcoin Signed Message:\n', + bip32: { + public: 0x0488b21e, + private: 0x0488ade4 + }, + pubKeyHash: 0x00, + scriptHash: 0x05, + wif: 0x80 + }, + testnet: { + messagePrefix: '\x18Bitcoin Signed Message:\n', + bip32: { + public: 0x043587cf, + private: 0x04358394 + }, + pubKeyHash: 0x6f, + scriptHash: 0xc4, + wif: 0xef + }, + litecoin: { + messagePrefix: '\x19Litecoin Signed Message:\n', + bip32: { + public: 0x019da462, + private: 0x019d9cfe + }, + pubKeyHash: 0x30, + scriptHash: 0x32, + wif: 0xb0 + } +} -CardTitle.propTypes = propTypes$35; -CardTitle.defaultProps = defaultProps$34; -var propTypes$36 = { - placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), - target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string.isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; +/***/ }), +/* 55 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$35 = { - isOpen: false, - placement: 'bottom', - toggle: function toggle() {} -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var defaultTetherConfig$1 = { - classPrefix: 'bs-tether', - classes: { - element: false, - enabled: 'show' - }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; -var Popover = function (_React$Component) { - inherits(Popover, _React$Component); - function Popover(props) { - classCallCheck(this, Popover); +var canDefineProperty = false; +if (process.env.NODE_ENV !== 'production') { + try { + // $FlowFixMe https://github.com/facebook/flow/issues/285 + Object.defineProperty({}, 'x', { get: function () {} }); + canDefineProperty = true; + } catch (x) { + // IE will fail on defineProperty + } +} - var _this = possibleConstructorReturn(this, (Popover.__proto__ || Object.getPrototypeOf(Popover)).call(this, props)); +module.exports = canDefineProperty; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - return _this; - } +/***/ }), +/* 56 */ +/***/ (function(module, exports, __webpack_require__) { - createClass(Popover, [{ - key: 'getTetherConfig', - value: function getTetherConfig() { - var attachments = getTetherAttachments(this.props.placement); - return _extends({}, defaultTetherConfig$1, attachments, { - target: '#' + this.props.target - }, this.props.tether); - } - }, { - key: 'render', - value: function render() { - if (!this.props.isOpen) { - return null; - } - - var tetherConfig = this.getTetherConfig(); - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('popover-inner', this.props.className), this.props.cssModule); - - var attributes = omit(this.props, Object.keys(propTypes$36)); - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - { - className: mapToCssModules('popover', this.props.cssModule), - tether: tetherConfig, - tetherRef: this.props.tetherRef, - isOpen: this.props.isOpen, - toggle: this.props.toggle - }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { className: classes })) - ); - } - }]); - return Popover; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - -Popover.propTypes = propTypes$36; -Popover.defaultProps = defaultProps$35; - -var propTypes$37 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; - -var defaultProps$36 = { - tag: 'h3' -}; - -var PopoverTitle = function PopoverTitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-title'), cssModule); - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; - -PopoverTitle.propTypes = propTypes$37; -PopoverTitle.defaultProps = defaultProps$36; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var propTypes$38 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$37 = { - tag: 'div' -}; -var PopoverContent = function PopoverContent(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +var emptyObject = {}; +if (process.env.NODE_ENV !== 'production') { + Object.freeze(emptyObject); +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-content'), cssModule); +module.exports = emptyObject; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 57 */ +/***/ (function(module, exports, __webpack_require__) { -PopoverContent.propTypes = propTypes$38; -PopoverContent.defaultProps = defaultProps$37; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var propTypes$39 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - bar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - multi: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - value: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - max: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - animated: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - barClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$38 = { - tag: 'div', - value: 0, - max: 100 -}; -var Progress = function Progress(props) { - var children = props.children, - className = props.className, - barClassName = props.barClassName, - cssModule = props.cssModule, - value = props.value, - max = props.max, - animated = props.animated, - striped = props.striped, - color = props.color, - bar = props.bar, - multi = props.multi, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['children', 'className', 'barClassName', 'cssModule', 'value', 'max', 'animated', 'striped', 'color', 'bar', 'multi', 'tag']); +var _prodInvariant = __webpack_require__(5); +var invariant = __webpack_require__(2); - var percent = __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(value) / __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(max) * 100; +/** + * Injectable ordering of event plugins. + */ +var eventPluginOrder = null; - var progressClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'progress'), cssModule); +/** + * Injectable mapping from names to event plugin modules. + */ +var namesToPlugins = {}; - var progressBarClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('progress-bar', bar ? className || barClassName : barClassName, animated ? 'progress-bar-animated' : null, color ? 'bg-' + color : null, striped || animated ? 'progress-bar-striped' : null), cssModule); +/** + * Recomputes the plugin list using the injected plugins and plugin ordering. + * + * @private + */ +function recomputePluginOrdering() { + if (!eventPluginOrder) { + // Wait until an `eventPluginOrder` is injected. + return; + } + for (var pluginName in namesToPlugins) { + var pluginModule = namesToPlugins[pluginName]; + var pluginIndex = eventPluginOrder.indexOf(pluginName); + !(pluginIndex > -1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugins that do not exist in the plugin ordering, `%s`.', pluginName) : _prodInvariant('96', pluginName) : void 0; + if (EventPluginRegistry.plugins[pluginIndex]) { + continue; + } + !pluginModule.extractEvents ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Event plugins must implement an `extractEvents` method, but `%s` does not.', pluginName) : _prodInvariant('97', pluginName) : void 0; + EventPluginRegistry.plugins[pluginIndex] = pluginModule; + var publishedEvents = pluginModule.eventTypes; + for (var eventName in publishedEvents) { + !publishEventForPlugin(publishedEvents[eventName], pluginModule, eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Failed to publish event `%s` for plugin `%s`.', eventName, pluginName) : _prodInvariant('98', eventName, pluginName) : void 0; + } + } +} - var ProgressBar = multi ? children : __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { - className: progressBarClasses, - style: { width: percent + '%' }, - role: 'progressbar', - 'aria-valuenow': value, - 'aria-valuemin': '0', - 'aria-valuemax': max, - children: children - }); +/** + * Publishes an event so that it can be dispatched by the supplied plugin. + * + * @param {object} dispatchConfig Dispatch configuration for the event. + * @param {object} PluginModule Plugin publishing the event. + * @return {boolean} True if the event was successfully published. + * @private + */ +function publishEventForPlugin(dispatchConfig, pluginModule, eventName) { + !!EventPluginRegistry.eventNameDispatchConfigs.hasOwnProperty(eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same event name, `%s`.', eventName) : _prodInvariant('99', eventName) : void 0; + EventPluginRegistry.eventNameDispatchConfigs[eventName] = dispatchConfig; - if (bar) { - return ProgressBar; + var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; + if (phasedRegistrationNames) { + for (var phaseName in phasedRegistrationNames) { + if (phasedRegistrationNames.hasOwnProperty(phaseName)) { + var phasedRegistrationName = phasedRegistrationNames[phaseName]; + publishRegistrationName(phasedRegistrationName, pluginModule, eventName); + } + } + return true; + } else if (dispatchConfig.registrationName) { + publishRegistrationName(dispatchConfig.registrationName, pluginModule, eventName); + return true; } + return false; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: progressClasses, children: ProgressBar })); -}; +/** + * Publishes a registration name that is used to identify dispatched events and + * can be used with `EventPluginHub.putListener` to register listeners. + * + * @param {string} registrationName Registration name to add. + * @param {object} PluginModule Plugin publishing the event. + * @private + */ +function publishRegistrationName(registrationName, pluginModule, eventName) { + !!EventPluginRegistry.registrationNameModules[registrationName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same registration name, `%s`.', registrationName) : _prodInvariant('100', registrationName) : void 0; + EventPluginRegistry.registrationNameModules[registrationName] = pluginModule; + EventPluginRegistry.registrationNameDependencies[registrationName] = pluginModule.eventTypes[eventName].dependencies; -Progress.propTypes = propTypes$39; -Progress.defaultProps = defaultProps$38; + if (process.env.NODE_ENV !== 'production') { + var lowerCasedName = registrationName.toLowerCase(); + EventPluginRegistry.possibleRegistrationNames[lowerCasedName] = registrationName; -var propTypes$40 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - autoFocus: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - keyboard: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - backdrop: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(['static'])]), - onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onExit: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - wrapClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - modalClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - backdropClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - contentClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - fade: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - zIndex: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - backdropTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number -}; + if (registrationName === 'onDoubleClick') { + EventPluginRegistry.possibleRegistrationNames.ondblclick = registrationName; + } + } +} -var propsToOmit = Object.keys(propTypes$40); +/** + * Registers plugins so that they can extract and dispatch events. + * + * @see {EventPluginHub} + */ +var EventPluginRegistry = { + /** + * Ordered list of injected plugins. + */ + plugins: [], -var defaultProps$39 = { - isOpen: false, - autoFocus: true, - backdrop: true, - keyboard: true, - zIndex: 1050, - fade: true, - modalTransitionTimeout: 300, - backdropTransitionTimeout: 150 -}; + /** + * Mapping from event name to dispatch config + */ + eventNameDispatchConfigs: {}, -var Modal = function (_React$Component) { - inherits(Modal, _React$Component); + /** + * Mapping from registration name to plugin module + */ + registrationNameModules: {}, - function Modal(props) { - classCallCheck(this, Modal); + /** + * Mapping from registration name to event name + */ + registrationNameDependencies: {}, - var _this = possibleConstructorReturn(this, (Modal.__proto__ || Object.getPrototypeOf(Modal)).call(this, props)); + /** + * Mapping from lowercase registration names to the properly cased version, + * used to warn in the case of missing event handlers. Available + * only in __DEV__. + * @type {Object} + */ + possibleRegistrationNames: process.env.NODE_ENV !== 'production' ? {} : null, + // Trust the developer to only use possibleRegistrationNames in __DEV__ - _this.originalBodyPadding = null; - _this.isBodyOverflowing = false; - _this.togglePortal = _this.togglePortal.bind(_this); - _this.handleBackdropClick = _this.handleBackdropClick.bind(_this); - _this.handleEscape = _this.handleEscape.bind(_this); - _this.destroy = _this.destroy.bind(_this); - _this.onEnter = _this.onEnter.bind(_this); - _this.onExit = _this.onExit.bind(_this); - return _this; - } + /** + * Injects an ordering of plugins (by plugin name). This allows the ordering + * to be decoupled from injection of the actual plugins so that ordering is + * always deterministic regardless of packaging, on-the-fly injection, etc. + * + * @param {array} InjectedEventPluginOrder + * @internal + * @see {EventPluginHub.injection.injectEventPluginOrder} + */ + injectEventPluginOrder: function (injectedEventPluginOrder) { + !!eventPluginOrder ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugin ordering more than once. You are likely trying to load more than one copy of React.') : _prodInvariant('101') : void 0; + // Clone the ordering so it cannot be dynamically mutated. + eventPluginOrder = Array.prototype.slice.call(injectedEventPluginOrder); + recomputePluginOrdering(); + }, - createClass(Modal, [{ - key: 'componentDidMount', - value: function componentDidMount() { - if (this.props.isOpen) { - this.togglePortal(); + /** + * Injects plugins to be used by `EventPluginHub`. The plugin names must be + * in the ordering injected by `injectEventPluginOrder`. + * + * Plugins can be injected as part of page initialization or on-the-fly. + * + * @param {object} injectedNamesToPlugins Map from names to plugin modules. + * @internal + * @see {EventPluginHub.injection.injectEventPluginsByName} + */ + injectEventPluginsByName: function (injectedNamesToPlugins) { + var isOrderingDirty = false; + for (var pluginName in injectedNamesToPlugins) { + if (!injectedNamesToPlugins.hasOwnProperty(pluginName)) { + continue; } - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - // handle portal events/dom updates - this.togglePortal(); - } else if (this._element) { - // rerender portal - this.renderIntoSubtree(); + var pluginModule = injectedNamesToPlugins[pluginName]; + if (!namesToPlugins.hasOwnProperty(pluginName) || namesToPlugins[pluginName] !== pluginModule) { + !!namesToPlugins[pluginName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject two different event plugins using the same name, `%s`.', pluginName) : _prodInvariant('102', pluginName) : void 0; + namesToPlugins[pluginName] = pluginModule; + isOrderingDirty = true; } } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.onExit(); + if (isOrderingDirty) { + recomputePluginOrdering(); } - }, { - key: 'onEnter', - value: function onEnter() { - if (this.props.onEnter) { - this.props.onEnter(); - } + }, + + /** + * Looks up the plugin for the supplied event. + * + * @param {object} event A synthetic event. + * @return {?object} The plugin that created the supplied event. + * @internal + */ + getPluginModuleForEvent: function (event) { + var dispatchConfig = event.dispatchConfig; + if (dispatchConfig.registrationName) { + return EventPluginRegistry.registrationNameModules[dispatchConfig.registrationName] || null; } - }, { - key: 'onExit', - value: function onExit() { - this.destroy(); - if (this.props.onExit) { - this.props.onExit(); + if (dispatchConfig.phasedRegistrationNames !== undefined) { + // pulling phasedRegistrationNames out of dispatchConfig helps Flow see + // that it is not undefined. + var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; + + for (var phase in phasedRegistrationNames) { + if (!phasedRegistrationNames.hasOwnProperty(phase)) { + continue; + } + var pluginModule = EventPluginRegistry.registrationNameModules[phasedRegistrationNames[phase]]; + if (pluginModule) { + return pluginModule; + } } } - }, { - key: 'handleEscape', - value: function handleEscape(e) { - if (this.props.keyboard && e.keyCode === 27 && this.props.toggle) { - this.props.toggle(); + return null; + }, + + /** + * Exposed for unit testing. + * @private + */ + _resetEventPlugins: function () { + eventPluginOrder = null; + for (var pluginName in namesToPlugins) { + if (namesToPlugins.hasOwnProperty(pluginName)) { + delete namesToPlugins[pluginName]; } } - }, { - key: 'handleBackdropClick', - value: function handleBackdropClick(e) { - if (this.props.backdrop !== true) return; - - var container = this._dialog; + EventPluginRegistry.plugins.length = 0; - if (e.target && !container.contains(e.target) && this.props.toggle) { - this.props.toggle(); + var eventNameDispatchConfigs = EventPluginRegistry.eventNameDispatchConfigs; + for (var eventName in eventNameDispatchConfigs) { + if (eventNameDispatchConfigs.hasOwnProperty(eventName)) { + delete eventNameDispatchConfigs[eventName]; } } - }, { - key: 'hasTransition', - value: function hasTransition() { - if (this.props.fade === false) { - return false; - } - return this.props.modalTransitionTimeout > 0; + var registrationNameModules = EventPluginRegistry.registrationNameModules; + for (var registrationName in registrationNameModules) { + if (registrationNameModules.hasOwnProperty(registrationName)) { + delete registrationNameModules[registrationName]; + } } - }, { - key: 'togglePortal', - value: function togglePortal() { - if (this.props.isOpen) { - if (this.props.autoFocus) { - this._focus = true; - } - this.show(); - if (!this.hasTransition()) { - this.onEnter(); - } - } else { - this.hide(); - if (!this.hasTransition()) { - this.onExit(); + + if (process.env.NODE_ENV !== 'production') { + var possibleRegistrationNames = EventPluginRegistry.possibleRegistrationNames; + for (var lowerCasedName in possibleRegistrationNames) { + if (possibleRegistrationNames.hasOwnProperty(lowerCasedName)) { + delete possibleRegistrationNames[lowerCasedName]; } } } - }, { - key: 'destroy', - value: function destroy() { - if (this._element) { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); - document.body.removeChild(this._element); - this._element = null; - } + } +}; - // Use regex to prevent matching `modal-open` as part of a different class, e.g. `my-modal-opened` - var classes = document.body.className.replace(/(^| )modal-open( |$)/, ' '); - document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes).trim(), this.props.cssModule); - setScrollbarWidth(this.originalBodyPadding); - } - }, { - key: 'hide', - value: function hide() { - this.renderIntoSubtree(); - } - }, { - key: 'show', - value: function show() { - var classes = document.body.className; - this._element = document.createElement('div'); - this._element.setAttribute('tabindex', '-1'); - this._element.style.position = 'relative'; - this._element.style.zIndex = this.props.zIndex; - this.originalBodyPadding = getOriginalBodyPadding(); +module.exports = EventPluginRegistry; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - conditionallyUpdateScrollbar(); +/***/ }), +/* 58 */ +/***/ (function(module, exports, __webpack_require__) { - document.body.appendChild(this._element); - - document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes, 'modal-open'), this.props.cssModule); - - this.renderIntoSubtree(); - } - }, { - key: 'renderModalDialog', - value: function renderModalDialog() { - var _this2 = this; - - var attributes = omit(this.props, propsToOmit); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - _extends({ - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-dialog', this.props.className, defineProperty({}, 'modal-' + this.props.size, this.props.size)), this.props.cssModule), - role: 'document', - ref: function ref(c) { - return _this2._dialog = c; - } - }, attributes), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - { - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-content', this.props.contentClassName), this.props.cssModule) - }, - this.props.children - ) - ); - } - }, { - key: 'renderIntoSubtree', - value: function renderIntoSubtree() { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); - // check if modal should receive focus - if (this._focus) { - this._dialog.parentNode.focus(); - this._focus = false; - } - } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _props = this.props, - wrapClassName = _props.wrapClassName, - modalClassName = _props.modalClassName, - backdropClassName = _props.backdropClassName, - cssModule = _props.cssModule, - isOpen = _props.isOpen, - backdrop = _props.backdrop, - modalTransitionTimeout = _props.modalTransitionTimeout, - backdropTransitionTimeout = _props.backdropTransitionTimeout; +var _prodInvariant = __webpack_require__(5); - var modalAttributes = { - onClickCapture: this.handleBackdropClick, - onKeyUp: this.handleEscape, - style: { display: 'block' }, - tabIndex: '-1' - }; +var invariant = __webpack_require__(2); - if (this.hasTransition()) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["TransitionGroup"], - { component: 'div', className: mapToCssModules(wrapClassName) }, - isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Fade, - _extends({ - key: 'modal-dialog', - onEnter: this.onEnter, - onLeave: this.onExit, - transitionAppearTimeout: typeof this.props.modalTransitionAppearTimeout === 'number' ? this.props.modalTransitionAppearTimeout : modalTransitionTimeout, - transitionEnterTimeout: typeof this.props.modalTransitionEnterTimeout === 'number' ? this.props.modalTransitionEnterTimeout : modalTransitionTimeout, - transitionLeaveTimeout: typeof this.props.modalTransitionLeaveTimeout === 'number' ? this.props.modalTransitionLeaveTimeout : modalTransitionTimeout, - cssModule: cssModule, - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', modalClassName), cssModule) - }, modalAttributes), - this.renderModalDialog() - ), - isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Fade, { - key: 'modal-backdrop', - transitionAppearTimeout: typeof this.props.backdropTransitionAppearTimeout === 'number' ? this.props.backdropTransitionAppearTimeout : backdropTransitionTimeout, - transitionEnterTimeout: typeof this.props.backdropTransitionEnterTimeout === 'number' ? this.props.backdropTransitionEnterTimeout : backdropTransitionTimeout, - transitionLeaveTimeout: typeof this.props.backdropTransitionLeaveTimeout === 'number' ? this.props.backdropTransitionLeaveTimeout : backdropTransitionTimeout, - cssModule: cssModule, - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', backdropClassName), cssModule) - }) - ); - } +var OBSERVED_ERROR = {}; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - { className: mapToCssModules(wrapClassName) }, - isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - _extends({ - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', 'show', modalClassName), cssModule) - }, modalAttributes), - this.renderModalDialog() - ), - isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', 'show', backdropClassName), cssModule) - }) - ); - } - }, { - key: 'render', - value: function render() { - return null; +/** + * `Transaction` creates a black box that is able to wrap any method such that + * certain invariants are maintained before and after the method is invoked + * (Even if an exception is thrown while invoking the wrapped method). Whoever + * instantiates a transaction can provide enforcers of the invariants at + * creation time. The `Transaction` class itself will supply one additional + * automatic invariant for you - the invariant that any transaction instance + * should not be run while it is already being run. You would typically create a + * single instance of a `Transaction` for reuse multiple times, that potentially + * is used to wrap several different methods. Wrappers are extremely simple - + * they only require implementing two methods. + * + * <pre> + * wrappers (injected at creation time) + * + + + * | | + * +-----------------|--------|--------------+ + * | v | | + * | +---------------+ | | + * | +--| wrapper1 |---|----+ | + * | | +---------------+ v | | + * | | +-------------+ | | + * | | +----| wrapper2 |--------+ | + * | | | +-------------+ | | | + * | | | | | | + * | v v v v | wrapper + * | +---+ +---+ +---------+ +---+ +---+ | invariants + * perform(anyMethod) | | | | | | | | | | | | maintained + * +----------------->|-|---|-|---|-->|anyMethod|---|---|-|---|-|--------> + * | | | | | | | | | | | | + * | | | | | | | | | | | | + * | | | | | | | | | | | | + * | +---+ +---+ +---------+ +---+ +---+ | + * | initialize close | + * +-----------------------------------------+ + * </pre> + * + * Use cases: + * - Preserving the input selection ranges before/after reconciliation. + * Restoring selection even in the event of an unexpected error. + * - Deactivating events while rearranging the DOM, preventing blurs/focuses, + * while guaranteeing that afterwards, the event system is reactivated. + * - Flushing a queue of collected DOM mutations to the main UI thread after a + * reconciliation takes place in a worker thread. + * - Invoking any collected `componentDidUpdate` callbacks after rendering new + * content. + * - (Future use case): Wrapping particular flushes of the `ReactWorker` queue + * to preserve the `scrollTop` (an automatic scroll aware DOM). + * - (Future use case): Layout calculations before and after DOM updates. + * + * Transactional plugin API: + * - A module that has an `initialize` method that returns any precomputation. + * - and a `close` method that accepts the precomputation. `close` is invoked + * when the wrapped process is completed, or has failed. + * + * @param {Array<TransactionalWrapper>} transactionWrapper Wrapper modules + * that implement `initialize` and `close`. + * @return {Transaction} Single transaction for reuse in thread. + * + * @class Transaction + */ +var TransactionImpl = { + /** + * Sets up this instance so that it is prepared for collecting metrics. Does + * so such that this setup method may be used on an instance that is already + * initialized, in a way that does not consume additional memory upon reuse. + * That can be useful if you decide to make your subclass of this mixin a + * "PooledClass". + */ + reinitializeTransaction: function () { + this.transactionWrappers = this.getTransactionWrappers(); + if (this.wrapperInitData) { + this.wrapperInitData.length = 0; + } else { + this.wrapperInitData = []; } - }]); - return Modal; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + this._isInTransaction = false; + }, -Modal.propTypes = propTypes$40; -Modal.defaultProps = defaultProps$39; + _isInTransaction: false, -var propTypes$41 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - wrapTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node -}; + /** + * @abstract + * @return {Array<TransactionWrapper>} Array of transaction wrappers. + */ + getTransactionWrappers: null, -var defaultProps$40 = { - tag: 'h4', - wrapTag: 'div' -}; + isInTransaction: function () { + return !!this._isInTransaction; + }, -var ModalHeader = function ModalHeader(props) { - var closeButton = void 0; - var className = props.className, - cssModule = props.cssModule, - children = props.children, - toggle = props.toggle, - Tag = props.tag, - WrapTag = props.wrapTag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'toggle', 'tag', 'wrapTag']); + /* eslint-disable space-before-function-paren */ + /** + * Executes the function within a safety window. Use this for the top level + * methods that result in large amounts of computation/mutations that would + * need to be safety checked. The optional arguments helps prevent the need + * to bind in many cases. + * + * @param {function} method Member of scope to call. + * @param {Object} scope Scope to invoke from. + * @param {Object?=} a Argument to pass to the method. + * @param {Object?=} b Argument to pass to the method. + * @param {Object?=} c Argument to pass to the method. + * @param {Object?=} d Argument to pass to the method. + * @param {Object?=} e Argument to pass to the method. + * @param {Object?=} f Argument to pass to the method. + * + * @return {*} Return value from `method`. + */ + perform: function (method, scope, a, b, c, d, e, f) { + /* eslint-enable space-before-function-paren */ + !!this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.perform(...): Cannot initialize a transaction when there is already an outstanding transaction.') : _prodInvariant('27') : void 0; + var errorThrown; + var ret; + try { + this._isInTransaction = true; + // Catching errors makes debugging more difficult, so we start with + // errorThrown set to true before setting it to false after calling + // close -- if it's still set to true in the finally block, it means + // one of these calls threw. + errorThrown = true; + this.initializeAll(0); + ret = method.call(scope, a, b, c, d, e, f); + errorThrown = false; + } finally { + try { + if (errorThrown) { + // If `method` throws, prefer to show that stack trace over any thrown + // by invoking `closeAll`. + try { + this.closeAll(0); + } catch (err) {} + } else { + // Since `method` didn't throw, we don't want to silence the exception + // here. + this.closeAll(0); + } + } finally { + this._isInTransaction = false; + } + } + return ret; + }, - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-header'), cssModule); + initializeAll: function (startIndex) { + var transactionWrappers = this.transactionWrappers; + for (var i = startIndex; i < transactionWrappers.length; i++) { + var wrapper = transactionWrappers[i]; + try { + // Catching errors makes debugging more difficult, so we start with the + // OBSERVED_ERROR state before overwriting it with the real return value + // of initialize -- if it's still set to OBSERVED_ERROR in the finally + // block, it means wrapper.initialize threw. + this.wrapperInitData[i] = OBSERVED_ERROR; + this.wrapperInitData[i] = wrapper.initialize ? wrapper.initialize.call(this) : null; + } finally { + if (this.wrapperInitData[i] === OBSERVED_ERROR) { + // The initializer for wrapper i threw an error; initialize the + // remaining wrappers but silence any exceptions from them to ensure + // that the first error is the one to bubble up. + try { + this.initializeAll(i + 1); + } catch (err) {} + } + } + } + }, - if (toggle) { - closeButton = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'button', - { type: 'button', onClick: toggle, className: 'close', 'aria-label': 'Close' }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { 'aria-hidden': 'true' }, - String.fromCharCode(215) - ) - ); + /** + * Invokes each of `this.transactionWrappers.close[i]` functions, passing into + * them the respective return values of `this.transactionWrappers.init[i]` + * (`close`rs that correspond to initializers that failed will not be + * invoked). + */ + closeAll: function (startIndex) { + !this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.closeAll(): Cannot close transaction when none are open.') : _prodInvariant('28') : void 0; + var transactionWrappers = this.transactionWrappers; + for (var i = startIndex; i < transactionWrappers.length; i++) { + var wrapper = transactionWrappers[i]; + var initData = this.wrapperInitData[i]; + var errorThrown; + try { + // Catching errors makes debugging more difficult, so we start with + // errorThrown set to true before setting it to false after calling + // close -- if it's still set to true in the finally block, it means + // wrapper.close threw. + errorThrown = true; + if (initData !== OBSERVED_ERROR && wrapper.close) { + wrapper.close.call(this, initData); + } + errorThrown = false; + } finally { + if (errorThrown) { + // The closer for wrapper i threw an error; close the remaining + // wrappers but silence any exceptions from them to ensure that the + // first error is the one to bubble up. + try { + this.closeAll(i + 1); + } catch (e) {} + } + } + } + this.wrapperInitData.length = 0; } - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - WrapTag, - _extends({}, attributes, { className: classes }), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - { className: mapToCssModules('modal-title', cssModule) }, - children - ), - closeButton - ); }; -ModalHeader.propTypes = propTypes$41; -ModalHeader.defaultProps = defaultProps$40; +module.exports = TransactionImpl; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var propTypes$42 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 59 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$41 = { - tag: 'div' -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var ModalBody = function ModalBody(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-body'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var SyntheticUIEvent = __webpack_require__(47); +var ViewportMetrics = __webpack_require__(134); -ModalBody.propTypes = propTypes$42; -ModalBody.defaultProps = defaultProps$41; +var getEventModifierState = __webpack_require__(81); -var propTypes$43 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +/** + * @interface MouseEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var MouseEventInterface = { + screenX: null, + screenY: null, + clientX: null, + clientY: null, + ctrlKey: null, + shiftKey: null, + altKey: null, + metaKey: null, + getModifierState: getEventModifierState, + button: function (event) { + // Webkit, Firefox, IE9+ + // which: 1 2 3 + // button: 0 1 2 (standard) + var button = event.button; + if ('which' in event) { + return button; + } + // IE<9 + // which: undefined + // button: 0 0 0 + // button: 1 4 2 (onmouseup) + return button === 2 ? 2 : button === 4 ? 1 : 0; + }, + buttons: null, + relatedTarget: function (event) { + return event.relatedTarget || (event.fromElement === event.srcElement ? event.toElement : event.fromElement); + }, + // "Proprietary" Interface. + pageX: function (event) { + return 'pageX' in event ? event.pageX : event.clientX + ViewportMetrics.currentScrollLeft; + }, + pageY: function (event) { + return 'pageY' in event ? event.pageY : event.clientY + ViewportMetrics.currentScrollTop; + } }; -var defaultProps$42 = { - tag: 'div' -}; +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticMouseEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} -var ModalFooter = function ModalFooter(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +SyntheticUIEvent.augmentClass(SyntheticMouseEvent, MouseEventInterface); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-footer'), cssModule); +module.exports = SyntheticMouseEvent; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 60 */ +/***/ (function(module, exports, __webpack_require__) { -ModalFooter.propTypes = propTypes$43; -ModalFooter.defaultProps = defaultProps$42; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var propTypes$44 = { - placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), - target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - autohide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]) -}; -var DEFAULT_DELAYS = { - show: 0, - hide: 250 -}; -var defaultProps$43 = { - isOpen: false, - placement: 'bottom', - delay: DEFAULT_DELAYS, - autohide: true, - toggle: function toggle() {} -}; +var ExecutionEnvironment = __webpack_require__(13); +var DOMNamespaces = __webpack_require__(83); -var defaultTetherConfig$2 = { - classPrefix: 'bs-tether', - classes: { - element: false, - enabled: 'show' - }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; +var WHITESPACE_TEST = /^[ \r\n\t\f]/; +var NONVISIBLE_TEST = /<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/; -var Tooltip = function (_React$Component) { - inherits(Tooltip, _React$Component); +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); - function Tooltip(props) { - classCallCheck(this, Tooltip); - - var _this = possibleConstructorReturn(this, (Tooltip.__proto__ || Object.getPrototypeOf(Tooltip)).call(this, props)); +// SVG temp container for IE lacking innerHTML +var reusableSVGContainer; - _this.addTargetEvents = _this.addTargetEvents.bind(_this); - _this.getTarget = _this.getTarget.bind(_this); - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.removeTargetEvents = _this.removeTargetEvents.bind(_this); - _this.toggle = _this.toggle.bind(_this); - _this.onMouseOverTooltip = _this.onMouseOverTooltip.bind(_this); - _this.onMouseLeaveTooltip = _this.onMouseLeaveTooltip.bind(_this); - _this.onMouseOverTooltipContent = _this.onMouseOverTooltipContent.bind(_this); - _this.onMouseLeaveTooltipContent = _this.onMouseLeaveTooltipContent.bind(_this); - _this.show = _this.show.bind(_this); - _this.hide = _this.hide.bind(_this); - return _this; +/** + * Set the innerHTML property of a node, ensuring that whitespace is preserved + * even in IE8. + * + * @param {DOMElement} node + * @param {string} html + * @internal + */ +var setInnerHTML = createMicrosoftUnsafeLocalFunction(function (node, html) { + // IE does not have innerHTML for SVG nodes, so instead we inject the + // new markup in a temp node and then move the child nodes across into + // the target node + if (node.namespaceURI === DOMNamespaces.svg && !('innerHTML' in node)) { + reusableSVGContainer = reusableSVGContainer || document.createElement('div'); + reusableSVGContainer.innerHTML = '<svg>' + html + '</svg>'; + var svgNode = reusableSVGContainer.firstChild; + while (svgNode.firstChild) { + node.appendChild(svgNode.firstChild); + } + } else { + node.innerHTML = html; } +}); - createClass(Tooltip, [{ - key: 'componentDidMount', - value: function componentDidMount() { - this._target = this.getTarget(); - this.addTargetEvents(); - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.removeTargetEvents(); - } - }, { - key: 'onMouseOverTooltip', - value: function onMouseOverTooltip() { - if (this._hideTimeout) { - this.clearHideTimeout(); - } - this._showTimeout = setTimeout(this.show, this.getDelay('show')); - } - }, { - key: 'onMouseLeaveTooltip', - value: function onMouseLeaveTooltip() { - if (this._showTimeout) { - this.clearShowTimeout(); - } - this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); - } - }, { - key: 'onMouseOverTooltipContent', - value: function onMouseOverTooltipContent() { - if (this.props.autohide) { - return; - } - if (this._hideTimeout) { - this.clearHideTimeout(); - } - } - }, { - key: 'onMouseLeaveTooltipContent', - value: function onMouseLeaveTooltipContent() { - if (this.props.autohide) { - return; - } - if (this._showTimeout) { - this.clearShowTimeout(); - } - this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); - } - }, { - key: 'getDelay', - value: function getDelay(key) { - var delay = this.props.delay; +if (ExecutionEnvironment.canUseDOM) { + // IE8: When updating a just created node with innerHTML only leading + // whitespace is removed. When updating an existing node with innerHTML + // whitespace in root TextNodes is also collapsed. + // @see quirksmode.org/bugreports/archives/2004/11/innerhtml_and_t.html - if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { - return isNaN(delay[key]) ? DEFAULT_DELAYS[key] : delay[key]; + // Feature detection; only IE8 is known to behave improperly like this. + var testElement = document.createElement('div'); + testElement.innerHTML = ' '; + if (testElement.innerHTML === '') { + setInnerHTML = function (node, html) { + // Magic theory: IE8 supposedly differentiates between added and updated + // nodes when processing innerHTML, innerHTML on updated nodes suffers + // from worse whitespace behavior. Re-adding a node like this triggers + // the initial and more favorable whitespace behavior. + // TODO: What to do on a detached node? + if (node.parentNode) { + node.parentNode.replaceChild(node, node); } - return delay; - } - }, { - key: 'getTarget', - value: function getTarget() { - var target = this.props.target; - if ((typeof target === 'undefined' ? 'undefined' : _typeof(target)) === 'object') { - return target; - } - return document.getElementById(target); - } - }, { - key: 'getTetherConfig', - value: function getTetherConfig() { - var attachments = getTetherAttachments(this.props.placement); - return _extends({}, defaultTetherConfig$2, attachments, { - target: this.getTarget - }, this.props.tether); - } - }, { - key: 'show', - value: function show() { - if (!this.props.isOpen) { - this.clearShowTimeout(); - this.toggle(); - } - } - }, { - key: 'hide', - value: function hide() { - if (this.props.isOpen) { - this.clearHideTimeout(); - this.toggle(); - } - } - }, { - key: 'clearShowTimeout', - value: function clearShowTimeout() { - clearTimeout(this._showTimeout); - this._showTimeout = undefined; - } - }, { - key: 'clearHideTimeout', - value: function clearHideTimeout() { - clearTimeout(this._hideTimeout); - this._hideTimeout = undefined; - } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - if (e.target === this._target || this._target.contains(e.target)) { - if (this._hideTimeout) { - this.clearHideTimeout(); - } + // We also implement a workaround for non-visible tags disappearing into + // thin air on IE8, this only happens if there is no visible text + // in-front of the non-visible tags. Piggyback on the whitespace fix + // and simply check if any non-visible tags appear in the source. + if (WHITESPACE_TEST.test(html) || html[0] === '<' && NONVISIBLE_TEST.test(html)) { + // Recover leading whitespace by temporarily prepending any character. + // \uFEFF has the potential advantage of being zero-width/invisible. + // UglifyJS drops U+FEFF chars when parsing, so use String.fromCharCode + // in hopes that this is preserved even if "\uFEFF" is transformed to + // the actual Unicode character (by Babel, for example). + // https://github.com/mishoo/UglifyJS2/blob/v2.4.20/lib/parse.js#L216 + node.innerHTML = String.fromCharCode(0xfeff) + html; - if (!this.props.isOpen) { - this.toggle(); + // deleteData leaves an empty `TextNode` which offsets the index of all + // children. Definitely want to avoid this. + var textNode = node.firstChild; + if (textNode.data.length === 1) { + node.removeChild(textNode); + } else { + textNode.deleteData(0, 1); } + } else { + node.innerHTML = html; } - } - }, { - key: 'addTargetEvents', - value: function addTargetEvents() { - this._target.addEventListener('mouseover', this.onMouseOverTooltip, true); - this._target.addEventListener('mouseout', this.onMouseLeaveTooltip, true); - document.addEventListener('click', this.handleDocumentClick, true); - } - }, { - key: 'removeTargetEvents', - value: function removeTargetEvents() { - this._target.removeEventListener('mouseover', this.onMouseOverTooltip, true); - this._target.removeEventListener('mouseout', this.onMouseLeaveTooltip, true); - document.removeEventListener('click', this.handleDocumentClick, true); - } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); - } - - return this.props.toggle(); - } - }, { - key: 'render', - value: function render() { - if (!this.props.isOpen) { - return null; - } - - var attributes = omit(this.props, Object.keys(propTypes$44)); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tooltip-inner', this.props.className), this.props.cssModule); + }; + } + testElement = null; +} - var tetherConfig = this.getTetherConfig(); +module.exports = setInnerHTML; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - { - className: 'tooltip', - tether: tetherConfig, - tetherRef: this.props.tetherRef, - isOpen: this.props.isOpen, - toggle: this.toggle - }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { - className: classes, - onMouseOver: this.onMouseOverTooltipContent, - onMouseLeave: this.onMouseLeaveTooltipContent - })) - ); - } - }]); - return Tooltip; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +/***/ }), +/* 61 */ +/***/ (function(module, exports, __webpack_require__) { -Tooltip.propTypes = propTypes$44; -Tooltip.defaultProps = defaultProps$43; +"use strict"; +/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * Based on the escape-html library, which is used under the MIT License below: + * + * Copyright (c) 2012-2013 TJ Holowaychuk + * Copyright (c) 2015 Andreas Lubbe + * Copyright (c) 2015 Tiancheng "Timothy" Gu + * + * Permission is hereby granted, free of charge, to any person obtaining + * a copy of this software and associated documentation files (the + * 'Software'), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sublicense, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice shall be + * included in all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. + * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY + * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + */ -var propTypes$45 = { - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - bordered: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - hover: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - reflow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - responsive: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - responsiveTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; -var defaultProps$44 = { - tag: 'table', - responsiveTag: 'div' -}; -var Table = function Table(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - bordered = props.bordered, - striped = props.striped, - inverse = props.inverse, - hover = props.hover, - reflow = props.reflow, - responsive = props.responsive, - Tag = props.tag, - ResponsiveTag = props.responsiveTag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'bordered', 'striped', 'inverse', 'hover', 'reflow', 'responsive', 'tag', 'responsiveTag']); +// code copied and modified from escape-html +/** + * Module variables. + * @private + */ +var matchHtmlRegExp = /["'&<>]/; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'table', size ? 'table-' + size : false, bordered ? 'table-bordered' : false, striped ? 'table-striped' : false, inverse ? 'table-inverse' : false, hover ? 'table-hover' : false, reflow ? 'table-reflow' : false), cssModule); +/** + * Escape special characters in the given string of html. + * + * @param {string} string The string to escape for inserting into HTML + * @return {string} + * @public + */ - var table = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +function escapeHtml(string) { + var str = '' + string; + var match = matchHtmlRegExp.exec(str); - if (responsive) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - ResponsiveTag, - { className: 'table-responsive' }, - table - ); + if (!match) { + return str; } - return table; -}; + var escape; + var html = ''; + var index = 0; + var lastIndex = 0; -Table.propTypes = propTypes$45; -Table.defaultProps = defaultProps$44; + for (index = match.index; index < str.length; index++) { + switch (str.charCodeAt(index)) { + case 34: + // " + escape = '"'; + break; + case 38: + // & + escape = '&'; + break; + case 39: + // ' + escape = '''; // modified from escape-html; used to be ''' + break; + case 60: + // < + escape = '<'; + break; + case 62: + // > + escape = '>'; + break; + default: + continue; + } -var propTypes$46 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - flush: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + if (lastIndex !== index) { + html += str.substring(lastIndex, index); + } -var defaultProps$45 = { - tag: 'ul' -}; + lastIndex = index + 1; + html += escape; + } -var ListGroup = function ListGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - flush = props.flush, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'flush']); + return lastIndex !== index ? html + str.substring(lastIndex, index) : html; +} +// end code copied and modified from escape-html - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group', flush ? 'list-group-flush' : false), cssModule); +/** + * Escapes text to prevent scripting attacks. + * + * @param {*} text Text value to escape. + * @return {string} An escaped string. + */ +function escapeTextContentForBrowser(text) { + if (typeof text === 'boolean' || typeof text === 'number') { + // this shortcircuit helps perf for types that we know will never have + // special characters, especially given that this function is used often + // for numeric dom ids. + return '' + text; + } + return escapeHtml(text); +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +module.exports = escapeTextContentForBrowser; -ListGroup.propTypes = propTypes$46; -ListGroup.defaultProps = defaultProps$45; +/***/ }), +/* 62 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$47 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var defaultProps$46 = { - tag: 'form' -}; -var Form = function Form(props) { - var className = props.className, - cssModule = props.cssModule, - inline = props.inline, - Tag = props.tag, - getRef = props.getRef, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'tag', 'getRef']); +var _assign = __webpack_require__(8); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, inline ? 'form-inline' : false), cssModule); +var EventPluginRegistry = __webpack_require__(57); +var ReactEventEmitterMixin = __webpack_require__(264); +var ViewportMetrics = __webpack_require__(134); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); -}; +var getVendorPrefixedEventName = __webpack_require__(265); +var isEventSupported = __webpack_require__(80); -Form.propTypes = propTypes$47; -Form.defaultProps = defaultProps$46; +/** + * Summary of `ReactBrowserEventEmitter` event handling: + * + * - Top-level delegation is used to trap most native browser events. This + * may only occur in the main thread and is the responsibility of + * ReactEventListener, which is injected and can therefore support pluggable + * event sources. This is the only work that occurs in the main thread. + * + * - We normalize and de-duplicate events to account for browser quirks. This + * may be done in the worker thread. + * + * - Forward these native events (with the associated top-level type used to + * trap it) to `EventPluginHub`, which in turn will ask plugins if they want + * to extract any synthetic events. + * + * - The `EventPluginHub` will then process each event by annotating them with + * "dispatches", a sequence of listeners and IDs that care about that event. + * + * - The `EventPluginHub` then dispatches the events. + * + * Overview of React and the event system: + * + * +------------+ . + * | DOM | . + * +------------+ . + * | . + * v . + * +------------+ . + * | ReactEvent | . + * | Listener | . + * +------------+ . +-----------+ + * | . +--------+|SimpleEvent| + * | . | |Plugin | + * +-----|------+ . v +-----------+ + * | | | . +--------------+ +------------+ + * | +-----------.--->|EventPluginHub| | Event | + * | | . | | +-----------+ | Propagators| + * | ReactEvent | . | | |TapEvent | |------------| + * | Emitter | . | |<---+|Plugin | |other plugin| + * | | . | | +-----------+ | utilities | + * | +-----------.--->| | +------------+ + * | | | . +--------------+ + * +-----|------+ . ^ +-----------+ + * | . | |Enter/Leave| + * + . +-------+|Plugin | + * +-------------+ . +-----------+ + * | application | . + * |-------------| . + * | | . + * | | . + * +-------------+ . + * . + * React Core . General Purpose Event Plugin System + */ -var propTypes$48 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var hasEventPageXY; +var alreadyListeningTo = {}; +var isMonitoringScrollValue = false; +var reactTopListenersCounter = 0; -var defaultProps$47 = { - tag: 'div' +// For events like 'submit' which don't consistently bubble (which we trap at a +// lower node than `document`), binding at `document` would cause duplicate +// events so we don't include them here +var topEventMapping = { + topAbort: 'abort', + topAnimationEnd: getVendorPrefixedEventName('animationend') || 'animationend', + topAnimationIteration: getVendorPrefixedEventName('animationiteration') || 'animationiteration', + topAnimationStart: getVendorPrefixedEventName('animationstart') || 'animationstart', + topBlur: 'blur', + topCanPlay: 'canplay', + topCanPlayThrough: 'canplaythrough', + topChange: 'change', + topClick: 'click', + topCompositionEnd: 'compositionend', + topCompositionStart: 'compositionstart', + topCompositionUpdate: 'compositionupdate', + topContextMenu: 'contextmenu', + topCopy: 'copy', + topCut: 'cut', + topDoubleClick: 'dblclick', + topDrag: 'drag', + topDragEnd: 'dragend', + topDragEnter: 'dragenter', + topDragExit: 'dragexit', + topDragLeave: 'dragleave', + topDragOver: 'dragover', + topDragStart: 'dragstart', + topDrop: 'drop', + topDurationChange: 'durationchange', + topEmptied: 'emptied', + topEncrypted: 'encrypted', + topEnded: 'ended', + topError: 'error', + topFocus: 'focus', + topInput: 'input', + topKeyDown: 'keydown', + topKeyPress: 'keypress', + topKeyUp: 'keyup', + topLoadedData: 'loadeddata', + topLoadedMetadata: 'loadedmetadata', + topLoadStart: 'loadstart', + topMouseDown: 'mousedown', + topMouseMove: 'mousemove', + topMouseOut: 'mouseout', + topMouseOver: 'mouseover', + topMouseUp: 'mouseup', + topPaste: 'paste', + topPause: 'pause', + topPlay: 'play', + topPlaying: 'playing', + topProgress: 'progress', + topRateChange: 'ratechange', + topScroll: 'scroll', + topSeeked: 'seeked', + topSeeking: 'seeking', + topSelectionChange: 'selectionchange', + topStalled: 'stalled', + topSuspend: 'suspend', + topTextInput: 'textInput', + topTimeUpdate: 'timeupdate', + topTouchCancel: 'touchcancel', + topTouchEnd: 'touchend', + topTouchMove: 'touchmove', + topTouchStart: 'touchstart', + topTransitionEnd: getVendorPrefixedEventName('transitionend') || 'transitionend', + topVolumeChange: 'volumechange', + topWaiting: 'waiting', + topWheel: 'wheel' }; -var FormFeedback = function FormFeedback(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/** + * To ensure no conflicts with other potential React instances on the page + */ +var topListenersIDKey = '_reactListenersID' + String(Math.random()).slice(2); +function getListeningForDocument(mountAt) { + // In IE8, `mountAt` is a host object and doesn't have `hasOwnProperty` + // directly. + if (!Object.prototype.hasOwnProperty.call(mountAt, topListenersIDKey)) { + mountAt[topListenersIDKey] = reactTopListenersCounter++; + alreadyListeningTo[mountAt[topListenersIDKey]] = {}; + } + return alreadyListeningTo[mountAt[topListenersIDKey]]; +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'form-control-feedback'), cssModule); +/** + * `ReactBrowserEventEmitter` is used to attach top-level event listeners. For + * example: + * + * EventPluginHub.putListener('myID', 'onClick', myFunction); + * + * This would allocate a "registration" of `('onClick', myFunction)` on 'myID'. + * + * @internal + */ +var ReactBrowserEventEmitter = _assign({}, ReactEventEmitterMixin, { + /** + * Injectable event backend + */ + ReactEventListener: null, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + injection: { + /** + * @param {object} ReactEventListener + */ + injectReactEventListener: function (ReactEventListener) { + ReactEventListener.setHandleTopLevel(ReactBrowserEventEmitter.handleTopLevel); + ReactBrowserEventEmitter.ReactEventListener = ReactEventListener; + } + }, -FormFeedback.propTypes = propTypes$48; -FormFeedback.defaultProps = defaultProps$47; + /** + * Sets whether or not any created callbacks should be enabled. + * + * @param {boolean} enabled True if callbacks should be enabled. + */ + setEnabled: function (enabled) { + if (ReactBrowserEventEmitter.ReactEventListener) { + ReactBrowserEventEmitter.ReactEventListener.setEnabled(enabled); + } + }, -var propTypes$49 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - row: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * @return {boolean} True if callbacks are enabled. + */ + isEnabled: function () { + return !!(ReactBrowserEventEmitter.ReactEventListener && ReactBrowserEventEmitter.ReactEventListener.isEnabled()); + }, -var defaultProps$48 = { - tag: 'div' -}; + /** + * We listen for bubbled touch events on the document object. + * + * Firefox v8.01 (and possibly others) exhibited strange behavior when + * mounting `onmousemove` events at some node that was not the document + * element. The symptoms were that if your mouse is not moving over something + * contained within that mount point (for example on the background) the + * top-level listeners for `onmousemove` won't be called. However, if you + * register the `mousemove` on the document object, then it will of course + * catch all `mousemove`s. This along with iOS quirks, justifies restricting + * top-level listeners to the document object only, at least for these + * movement types of events and possibly all events. + * + * @see http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html + * + * Also, `keyup`/`keypress`/`keydown` do not bubble to the window on IE, but + * they bubble to document. + * + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @param {object} contentDocumentHandle Document which owns the container + */ + listenTo: function (registrationName, contentDocumentHandle) { + var mountAt = contentDocumentHandle; + var isListening = getListeningForDocument(mountAt); + var dependencies = EventPluginRegistry.registrationNameDependencies[registrationName]; -var FormGroup = function FormGroup(props) { - var className = props.className, - cssModule = props.cssModule, - row = props.row, - disabled = props.disabled, - color = props.color, - check = props.check, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'row', 'disabled', 'color', 'check', 'tag']); + for (var i = 0; i < dependencies.length; i++) { + var dependency = dependencies[i]; + if (!(isListening.hasOwnProperty(dependency) && isListening[dependency])) { + if (dependency === 'topWheel') { + if (isEventSupported('wheel')) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'wheel', mountAt); + } else if (isEventSupported('mousewheel')) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'mousewheel', mountAt); + } else { + // Firefox needs to capture a different mouse scroll event. + // @see http://www.quirksmode.org/dom/events/tests/scroll.html + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'DOMMouseScroll', mountAt); + } + } else if (dependency === 'topScroll') { + if (isEventSupported('scroll', true)) { + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topScroll', 'scroll', mountAt); + } else { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topScroll', 'scroll', ReactBrowserEventEmitter.ReactEventListener.WINDOW_HANDLE); + } + } else if (dependency === 'topFocus' || dependency === 'topBlur') { + if (isEventSupported('focus', true)) { + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topFocus', 'focus', mountAt); + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topBlur', 'blur', mountAt); + } else if (isEventSupported('focusin')) { + // IE has `focusin` and `focusout` events which bubble. + // @see http://www.quirksmode.org/blog/archives/2008/04/delegating_the.html + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topFocus', 'focusin', mountAt); + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topBlur', 'focusout', mountAt); + } + // to make sure blur and focus event listeners are only attached once + isListening.topBlur = true; + isListening.topFocus = true; + } else if (topEventMapping.hasOwnProperty(dependency)) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(dependency, topEventMapping[dependency], mountAt); + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, color ? 'has-' + color : false, row ? 'row' : false, check ? 'form-check' : 'form-group', check && disabled ? 'disabled' : false), cssModule); + isListening[dependency] = true; + } + } + }, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + trapBubbledEvent: function (topLevelType, handlerBaseName, handle) { + return ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(topLevelType, handlerBaseName, handle); + }, -FormGroup.propTypes = propTypes$49; -FormGroup.defaultProps = defaultProps$48; + trapCapturedEvent: function (topLevelType, handlerBaseName, handle) { + return ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent(topLevelType, handlerBaseName, handle); + }, -var propTypes$50 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * Protect against document.createEvent() returning null + * Some popup blocker extensions appear to do this: + * https://github.com/facebook/react/issues/6887 + */ + supportsEventPageXY: function () { + if (!document.createEvent) { + return false; + } + var ev = document.createEvent('MouseEvent'); + return ev != null && 'pageX' in ev; + }, -var defaultProps$49 = { - tag: 'small' -}; + /** + * Listens to window scroll and resize events. We cache scroll values so that + * application code can access them without triggering reflows. + * + * ViewportMetrics is only used by SyntheticMouse/TouchEvent and only when + * pageX/pageY isn't supported (legacy browsers). + * + * NOTE: Scroll events do not bubble. + * + * @see http://www.quirksmode.org/dom/events/scroll.html + */ + ensureScrollValueMonitoring: function () { + if (hasEventPageXY === undefined) { + hasEventPageXY = ReactBrowserEventEmitter.supportsEventPageXY(); + } + if (!hasEventPageXY && !isMonitoringScrollValue) { + var refresh = ViewportMetrics.refreshScrollValues; + ReactBrowserEventEmitter.ReactEventListener.monitorScrollValue(refresh); + isMonitoringScrollValue = true; + } + } +}); -var FormText = function FormText(props) { - var className = props.className, - cssModule = props.cssModule, - inline = props.inline, - color = props.color, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'color', 'tag']); +module.exports = ReactBrowserEventEmitter; +/***/ }), +/* 63 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, !inline ? 'form-text' : false, color ? 'text-' + color : false), cssModule); +"use strict"; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/* + * A JavaScript implementation of the RSA Data Security, Inc. MD5 Message + * Digest Algorithm, as defined in RFC 1321. + * Version 2.1 Copyright (C) Paul Johnston 1999 - 2002. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * Distributed under the BSD License + * See http://pajhome.org.uk/crypt/md5 for more info. + */ -FormText.propTypes = propTypes$50; -FormText.defaultProps = defaultProps$49; +var makeHash = __webpack_require__(365) -/* eslint react/prefer-stateless-function: 0 */ +/* + * Calculate the MD5 of an array of little-endian words, and a bit length + */ +function core_md5 (x, len) { + /* append padding */ + x[len >> 5] |= 0x80 << ((len) % 32) + x[(((len + 64) >>> 9) << 4) + 14] = len + + var a = 1732584193 + var b = -271733879 + var c = -1732584194 + var d = 271733878 + + for (var i = 0; i < x.length; i += 16) { + var olda = a + var oldb = b + var oldc = c + var oldd = d + + a = md5_ff(a, b, c, d, x[i + 0], 7, -680876936) + d = md5_ff(d, a, b, c, x[i + 1], 12, -389564586) + c = md5_ff(c, d, a, b, x[i + 2], 17, 606105819) + b = md5_ff(b, c, d, a, x[i + 3], 22, -1044525330) + a = md5_ff(a, b, c, d, x[i + 4], 7, -176418897) + d = md5_ff(d, a, b, c, x[i + 5], 12, 1200080426) + c = md5_ff(c, d, a, b, x[i + 6], 17, -1473231341) + b = md5_ff(b, c, d, a, x[i + 7], 22, -45705983) + a = md5_ff(a, b, c, d, x[i + 8], 7, 1770035416) + d = md5_ff(d, a, b, c, x[i + 9], 12, -1958414417) + c = md5_ff(c, d, a, b, x[i + 10], 17, -42063) + b = md5_ff(b, c, d, a, x[i + 11], 22, -1990404162) + a = md5_ff(a, b, c, d, x[i + 12], 7, 1804603682) + d = md5_ff(d, a, b, c, x[i + 13], 12, -40341101) + c = md5_ff(c, d, a, b, x[i + 14], 17, -1502002290) + b = md5_ff(b, c, d, a, x[i + 15], 22, 1236535329) + + a = md5_gg(a, b, c, d, x[i + 1], 5, -165796510) + d = md5_gg(d, a, b, c, x[i + 6], 9, -1069501632) + c = md5_gg(c, d, a, b, x[i + 11], 14, 643717713) + b = md5_gg(b, c, d, a, x[i + 0], 20, -373897302) + a = md5_gg(a, b, c, d, x[i + 5], 5, -701558691) + d = md5_gg(d, a, b, c, x[i + 10], 9, 38016083) + c = md5_gg(c, d, a, b, x[i + 15], 14, -660478335) + b = md5_gg(b, c, d, a, x[i + 4], 20, -405537848) + a = md5_gg(a, b, c, d, x[i + 9], 5, 568446438) + d = md5_gg(d, a, b, c, x[i + 14], 9, -1019803690) + c = md5_gg(c, d, a, b, x[i + 3], 14, -187363961) + b = md5_gg(b, c, d, a, x[i + 8], 20, 1163531501) + a = md5_gg(a, b, c, d, x[i + 13], 5, -1444681467) + d = md5_gg(d, a, b, c, x[i + 2], 9, -51403784) + c = md5_gg(c, d, a, b, x[i + 7], 14, 1735328473) + b = md5_gg(b, c, d, a, x[i + 12], 20, -1926607734) + + a = md5_hh(a, b, c, d, x[i + 5], 4, -378558) + d = md5_hh(d, a, b, c, x[i + 8], 11, -2022574463) + c = md5_hh(c, d, a, b, x[i + 11], 16, 1839030562) + b = md5_hh(b, c, d, a, x[i + 14], 23, -35309556) + a = md5_hh(a, b, c, d, x[i + 1], 4, -1530992060) + d = md5_hh(d, a, b, c, x[i + 4], 11, 1272893353) + c = md5_hh(c, d, a, b, x[i + 7], 16, -155497632) + b = md5_hh(b, c, d, a, x[i + 10], 23, -1094730640) + a = md5_hh(a, b, c, d, x[i + 13], 4, 681279174) + d = md5_hh(d, a, b, c, x[i + 0], 11, -358537222) + c = md5_hh(c, d, a, b, x[i + 3], 16, -722521979) + b = md5_hh(b, c, d, a, x[i + 6], 23, 76029189) + a = md5_hh(a, b, c, d, x[i + 9], 4, -640364487) + d = md5_hh(d, a, b, c, x[i + 12], 11, -421815835) + c = md5_hh(c, d, a, b, x[i + 15], 16, 530742520) + b = md5_hh(b, c, d, a, x[i + 2], 23, -995338651) + + a = md5_ii(a, b, c, d, x[i + 0], 6, -198630844) + d = md5_ii(d, a, b, c, x[i + 7], 10, 1126891415) + c = md5_ii(c, d, a, b, x[i + 14], 15, -1416354905) + b = md5_ii(b, c, d, a, x[i + 5], 21, -57434055) + a = md5_ii(a, b, c, d, x[i + 12], 6, 1700485571) + d = md5_ii(d, a, b, c, x[i + 3], 10, -1894986606) + c = md5_ii(c, d, a, b, x[i + 10], 15, -1051523) + b = md5_ii(b, c, d, a, x[i + 1], 21, -2054922799) + a = md5_ii(a, b, c, d, x[i + 8], 6, 1873313359) + d = md5_ii(d, a, b, c, x[i + 15], 10, -30611744) + c = md5_ii(c, d, a, b, x[i + 6], 15, -1560198380) + b = md5_ii(b, c, d, a, x[i + 13], 21, 1309151649) + a = md5_ii(a, b, c, d, x[i + 4], 6, -145523070) + d = md5_ii(d, a, b, c, x[i + 11], 10, -1120210379) + c = md5_ii(c, d, a, b, x[i + 2], 15, 718787259) + b = md5_ii(b, c, d, a, x[i + 9], 21, -343485551) + + a = safe_add(a, olda) + b = safe_add(b, oldb) + c = safe_add(c, oldc) + d = safe_add(d, oldd) + } + + return [a, b, c, d] +} -var propTypes$51 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - state: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - static: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - addon: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/* + * These functions implement the four basic operations the algorithm uses. + */ +function md5_cmn (q, a, b, x, s, t) { + return safe_add(bit_rol(safe_add(safe_add(a, q), safe_add(x, t)), s), b) +} -var defaultProps$50 = { - tag: 'p', - type: 'text' -}; +function md5_ff (a, b, c, d, x, s, t) { + return md5_cmn((b & c) | ((~b) & d), a, b, x, s, t) +} -var Input = function (_React$Component) { - inherits(Input, _React$Component); +function md5_gg (a, b, c, d, x, s, t) { + return md5_cmn((b & d) | (c & (~d)), a, b, x, s, t) +} - function Input() { - classCallCheck(this, Input); - return possibleConstructorReturn(this, (Input.__proto__ || Object.getPrototypeOf(Input)).apply(this, arguments)); - } +function md5_hh (a, b, c, d, x, s, t) { + return md5_cmn(b ^ c ^ d, a, b, x, s, t) +} - createClass(Input, [{ - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - type = _props.type, - size = _props.size, - state = _props.state, - tag = _props.tag, - addon = _props.addon, - staticInput = _props.static, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'type', 'size', 'state', 'tag', 'addon', 'static', 'getRef']); +function md5_ii (a, b, c, d, x, s, t) { + return md5_cmn(c ^ (b | (~d)), a, b, x, s, t) +} +/* + * Add integers, wrapping at 2^32. This uses 16-bit operations internally + * to work around bugs in some JS interpreters. + */ +function safe_add (x, y) { + var lsw = (x & 0xFFFF) + (y & 0xFFFF) + var msw = (x >> 16) + (y >> 16) + (lsw >> 16) + return (msw << 16) | (lsw & 0xFFFF) +} - var checkInput = ['radio', 'checkbox'].indexOf(type) > -1; +/* + * Bitwise rotate a 32-bit number to the left. + */ +function bit_rol (num, cnt) { + return (num << cnt) | (num >>> (32 - cnt)) +} - var fileInput = type === 'file'; - var textareaInput = type === 'textarea'; - var selectInput = type === 'select'; - var Tag = selectInput || textareaInput ? type : 'input'; +module.exports = function md5 (buf) { + return makeHash(buf, core_md5) +} - var formControlClass = 'form-control'; - if (staticInput) { - formControlClass = formControlClass + '-static'; - Tag = tag; - } else if (fileInput) { - formControlClass = formControlClass + '-file'; - } else if (checkInput) { - if (addon) { - formControlClass = null; - } else { - formControlClass = 'form-check-input'; - } - } +/***/ }), +/* 64 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, state ? 'form-control-' + state : false, size ? 'form-control-' + size : false, formControlClass), cssModule); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { - if (Tag === 'input') { - attributes.type = type; - } +if (!process.version || + process.version.indexOf('v0.') === 0 || + process.version.indexOf('v1.') === 0 && process.version.indexOf('v1.8.') !== 0) { + module.exports = nextTick; +} else { + module.exports = process.nextTick; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); - } - }]); - return Input; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +function nextTick(fn, arg1, arg2, arg3) { + if (typeof fn !== 'function') { + throw new TypeError('"callback" argument must be a function'); + } + var len = arguments.length; + var args, i; + switch (len) { + case 0: + case 1: + return process.nextTick(fn); + case 2: + return process.nextTick(function afterTickOne() { + fn.call(null, arg1); + }); + case 3: + return process.nextTick(function afterTickTwo() { + fn.call(null, arg1, arg2); + }); + case 4: + return process.nextTick(function afterTickThree() { + fn.call(null, arg1, arg2, arg3); + }); + default: + args = new Array(len - 1); + i = 0; + while (i < args.length) { + args[i++] = arguments[i]; + } + return process.nextTick(function afterTick() { + fn.apply(null, args); + }); + } +} -Input.propTypes = propTypes$51; -Input.defaultProps = defaultProps$50; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var propTypes$52 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 65 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$51 = { - tag: 'div' -}; +"use strict"; -var InputGroup = function InputGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - size = props.size, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'size']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group', size ? 'input-group-' + size : null), cssModule); +var curve = exports; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +curve.base = __webpack_require__(388); +curve.short = __webpack_require__(389); +curve.mont = __webpack_require__(390); +curve.edwards = __webpack_require__(391); -InputGroup.propTypes = propTypes$52; -InputGroup.defaultProps = defaultProps$51; -var propTypes$53 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 66 */ +/***/ (function(module, exports) { -var defaultProps$52 = { - tag: 'div' +/* +config.js - Configuration for ZENCash Coin +*/ + +module.exports = { + mainnet: { + messagePrefix: 'ZENCash main net', + bip32: { + public: '0488b21e', + private: '0488ade4' + }, + pubKeyHash: '2089', + scriptHash: '2096', + zcPaymentAddressHash: '169a', // Private z-address + zcSpendingKeyHash: 'ab36', // Spending key + wif: '80' + }, + testnet: { + wif: 'ef', + pubKeyHash: '2098' + } }; -var InputGroupAddon = function InputGroupAddon(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/***/ }), +/* 67 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-addon'), cssModule); +"use strict"; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var inherits = __webpack_require__(4) +var Legacy = __webpack_require__(420) +var Base = __webpack_require__(29) +var Buffer = __webpack_require__(7).Buffer +var md5 = __webpack_require__(63) +var RIPEMD160 = __webpack_require__(97) -InputGroupAddon.propTypes = propTypes$53; -InputGroupAddon.defaultProps = defaultProps$52; +var sha = __webpack_require__(103) -var propTypes$54 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - groupClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - groupAttributes: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var ZEROS = Buffer.alloc(128) -var defaultProps$53 = { - tag: 'div' -}; +function Hmac (alg, key) { + Base.call(this, 'digest') + if (typeof key === 'string') { + key = Buffer.from(key) + } -var InputGroupButton = function InputGroupButton(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - children = props.children, - groupClassName = props.groupClassName, - groupAttributes = props.groupAttributes, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'children', 'groupClassName', 'groupAttributes']); + var blocksize = (alg === 'sha512' || alg === 'sha384') ? 128 : 64 + this._alg = alg + this._key = key + if (key.length > blocksize) { + var hash = alg === 'rmd160' ? new RIPEMD160() : sha(alg) + key = hash.update(key).digest() + } else if (key.length < blocksize) { + key = Buffer.concat([key, ZEROS], blocksize) + } - if (typeof children === 'string') { - var groupClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(groupClassName, 'input-group-btn'), cssModule); + var ipad = this._ipad = Buffer.allocUnsafe(blocksize) + var opad = this._opad = Buffer.allocUnsafe(blocksize) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, groupAttributes, { className: groupClasses }), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Button, _extends({}, attributes, { className: className, children: children })) - ); + for (var i = 0; i < blocksize; i++) { + ipad[i] = key[i] ^ 0x36 + opad[i] = key[i] ^ 0x5C } + this._hash = alg === 'rmd160' ? new RIPEMD160() : sha(alg) + this._hash.update(ipad) +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-btn'), cssModule); +inherits(Hmac, Base) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes, children: children })); -}; +Hmac.prototype._update = function (data) { + this._hash.update(data) +} -InputGroupButton.propTypes = propTypes$54; -InputGroupButton.defaultProps = defaultProps$53; +Hmac.prototype._final = function () { + var h = this._hash.digest() + var hash = this._alg === 'rmd160' ? new RIPEMD160() : sha(this._alg) + return hash.update(this._opad).update(h).digest() +} -var colSizes = ['xs', 'sm', 'md', 'lg', 'xl']; +module.exports = function createHmac (alg, key) { + alg = alg.toLowerCase() + if (alg === 'rmd160' || alg === 'ripemd160') { + return new Hmac('rmd160', key) + } + if (alg === 'md5') { + return new Legacy(md5, key) + } + return new Hmac(alg, key) +} -var stringOrNumberProp$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); -var columnProps$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ - size: stringOrNumberProp$1, - push: stringOrNumberProp$1, - pull: stringOrNumberProp$1, - offset: stringOrNumberProp$1 -})]); +/***/ }), +/* 68 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$55 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - hidden: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - for: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - xs: columnProps$1, - sm: columnProps$1, - md: columnProps$1, - lg: columnProps$1, - xl: columnProps$1 -}; +/* WEBPACK VAR INJECTION */(function(Buffer) {var md5 = __webpack_require__(63) +module.exports = EVP_BytesToKey +function EVP_BytesToKey (password, salt, keyLen, ivLen) { + if (!Buffer.isBuffer(password)) { + password = new Buffer(password, 'binary') + } + if (salt && !Buffer.isBuffer(salt)) { + salt = new Buffer(salt, 'binary') + } + keyLen = keyLen / 8 + ivLen = ivLen || 0 + var ki = 0 + var ii = 0 + var key = new Buffer(keyLen) + var iv = new Buffer(ivLen) + var addmd = 0 + var md_buf + var i + var bufs = [] + while (true) { + if (addmd++ > 0) { + bufs.push(md_buf) + } + bufs.push(password) + if (salt) { + bufs.push(salt) + } + md_buf = md5(Buffer.concat(bufs)) + bufs = [] + i = 0 + if (keyLen > 0) { + while (true) { + if (keyLen === 0) { + break + } + if (i === md_buf.length) { + break + } + key[ki++] = md_buf[i] + keyLen-- + i++ + } + } + if (ivLen > 0 && i !== md_buf.length) { + while (true) { + if (ivLen === 0) { + break + } + if (i === md_buf.length) { + break + } + iv[ii++] = md_buf[i] + ivLen-- + i++ + } + } + if (keyLen === 0 && ivLen === 0) { + break + } + } + for (i = 0; i < md_buf.length; i++) { + md_buf[i] = 0 + } + return { + key: key, + iv: iv + } +} -var defaultProps$54 = { - tag: 'label' -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var Label = function Label(props) { - var className = props.className, - cssModule = props.cssModule, - hidden = props.hidden, - Tag = props.tag, - check = props.check, - inline = props.inline, - disabled = props.disabled, - size = props.size, - htmlFor = props.for, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'hidden', 'tag', 'check', 'inline', 'disabled', 'size', 'for']); +/***/ }), +/* 69 */ +/***/ (function(module, exports, __webpack_require__) { +/* WEBPACK VAR INJECTION */(function(Buffer) {// based on the aes implimentation in triple sec +// https://github.com/keybase/triplesec - var colClasses = []; +// which is in turn based on the one from crypto-js +// https://code.google.com/p/crypto-js/ - colSizes.forEach(function (colSize) { - var columnProp = props[colSize]; - delete attributes[colSize]; +var uint_max = Math.pow(2, 32) +function fixup_uint32 (x) { + var ret, x_pos + ret = x > uint_max || x < 0 ? (x_pos = Math.abs(x) % uint_max, x < 0 ? uint_max - x_pos : x_pos) : x + return ret +} +function scrub_vec (v) { + for (var i = 0; i < v.length; v++) { + v[i] = 0 + } + return false +} - if (columnProp && columnProp.size) { - var _classNames; +function Global () { + this.SBOX = [] + this.INV_SBOX = [] + this.SUB_MIX = [[], [], [], []] + this.INV_SUB_MIX = [[], [], [], []] + this.init() + this.RCON = [0x00, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x1b, 0x36] +} - colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, 'col-' + colSize + '-' + columnProp.size, columnProp.size), defineProperty(_classNames, 'push-' + colSize + '-' + columnProp.push, columnProp.push), defineProperty(_classNames, 'pull-' + colSize + '-' + columnProp.pull, columnProp.pull), defineProperty(_classNames, 'offset-' + colSize + '-' + columnProp.offset, columnProp.offset), _classNames))), cssModule); - } else if (columnProp) { - colClasses.push('col-' + colSize + '-' + columnProp); +Global.prototype.init = function () { + var d, i, sx, t, x, x2, x4, x8, xi, _i + d = (function () { + var _i, _results + _results = [] + for (i = _i = 0; _i < 256; i = ++_i) { + if (i < 128) { + _results.push(i << 1) + } else { + _results.push((i << 1) ^ 0x11b) + } } - }); - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, hidden ? 'sr-only' : false, check ? 'form-check-' + (inline ? 'inline' : 'label') : false, check && inline && disabled ? 'disabled' : false, size ? 'col-form-label-' + size : false, colClasses, colClasses.length ? 'col-form-label' : false, !check && !colClasses.length ? 'form-control-label' : false), cssModule); + return _results + })() + x = 0 + xi = 0 + for (i = _i = 0; _i < 256; i = ++_i) { + sx = xi ^ (xi << 1) ^ (xi << 2) ^ (xi << 3) ^ (xi << 4) + sx = (sx >>> 8) ^ (sx & 0xff) ^ 0x63 + this.SBOX[x] = sx + this.INV_SBOX[sx] = x + x2 = d[x] + x4 = d[x2] + x8 = d[x4] + t = (d[sx] * 0x101) ^ (sx * 0x1010100) + this.SUB_MIX[0][x] = (t << 24) | (t >>> 8) + this.SUB_MIX[1][x] = (t << 16) | (t >>> 16) + this.SUB_MIX[2][x] = (t << 8) | (t >>> 24) + this.SUB_MIX[3][x] = t + t = (x8 * 0x1010101) ^ (x4 * 0x10001) ^ (x2 * 0x101) ^ (x * 0x1010100) + this.INV_SUB_MIX[0][sx] = (t << 24) | (t >>> 8) + this.INV_SUB_MIX[1][sx] = (t << 16) | (t >>> 16) + this.INV_SUB_MIX[2][sx] = (t << 8) | (t >>> 24) + this.INV_SUB_MIX[3][sx] = t + if (x === 0) { + x = xi = 1 + } else { + x = x2 ^ d[d[d[x8 ^ x2]]] + xi ^= d[d[xi]] + } + } + return true +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ htmlFor: htmlFor }, attributes, { className: classes })); -}; +var G = new Global() -Label.propTypes = propTypes$55; -Label.defaultProps = defaultProps$54; +AES.blockSize = 4 * 4 -var propTypes$56 = { - body: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - heading: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - list: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - middle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - object: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +AES.prototype.blockSize = AES.blockSize -var Media = function Media(props) { - var body = props.body, - bottom = props.bottom, - className = props.className, - cssModule = props.cssModule, - heading = props.heading, - left = props.left, - list = props.list, - middle = props.middle, - object = props.object, - right = props.right, - tag = props.tag, - top = props.top, - attributes = objectWithoutProperties(props, ['body', 'bottom', 'className', 'cssModule', 'heading', 'left', 'list', 'middle', 'object', 'right', 'tag', 'top']); +AES.keySize = 256 / 8 +AES.prototype.keySize = AES.keySize - var defaultTag = void 0; - if (heading) { - defaultTag = 'h4'; - } else if (left || right) { - defaultTag = 'a'; - } else if (object) { - defaultTag = 'img'; - } else if (list) { - defaultTag = 'ul'; - } else { - defaultTag = 'div'; +function bufferToArray (buf) { + var len = buf.length / 4 + var out = new Array(len) + var i = -1 + while (++i < len) { + out[i] = buf.readUInt32BE(i * 4) } - var Tag = tag || defaultTag; - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - 'media-body': body, - 'media-heading': heading, - 'media-left': left, - 'media-right': right, - 'media-top': top, - 'media-bottom': bottom, - 'media-middle': middle, - 'media-object': object, - 'media-list': list, - media: !body && !heading && !left && !right && !top && !bottom && !middle && !object && !list - }), cssModule); - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + return out +} +function AES (key) { + this._key = bufferToArray(key) + this._doReset() +} -Media.propTypes = propTypes$56; +AES.prototype._doReset = function () { + var invKsRow, keySize, keyWords, ksRow, ksRows, t + keyWords = this._key + keySize = keyWords.length + this._nRounds = keySize + 6 + ksRows = (this._nRounds + 1) * 4 + this._keySchedule = [] + for (ksRow = 0; ksRow < ksRows; ksRow++) { + this._keySchedule[ksRow] = ksRow < keySize ? keyWords[ksRow] : (t = this._keySchedule[ksRow - 1], (ksRow % keySize) === 0 ? (t = (t << 8) | (t >>> 24), t = (G.SBOX[t >>> 24] << 24) | (G.SBOX[(t >>> 16) & 0xff] << 16) | (G.SBOX[(t >>> 8) & 0xff] << 8) | G.SBOX[t & 0xff], t ^= G.RCON[(ksRow / keySize) | 0] << 24) : keySize > 6 && ksRow % keySize === 4 ? t = (G.SBOX[t >>> 24] << 24) | (G.SBOX[(t >>> 16) & 0xff] << 16) | (G.SBOX[(t >>> 8) & 0xff] << 8) | G.SBOX[t & 0xff] : void 0, this._keySchedule[ksRow - keySize] ^ t) + } + this._invKeySchedule = [] + for (invKsRow = 0; invKsRow < ksRows; invKsRow++) { + ksRow = ksRows - invKsRow + t = this._keySchedule[ksRow - (invKsRow % 4 ? 0 : 4)] + this._invKeySchedule[invKsRow] = invKsRow < 4 || ksRow <= 4 ? t : G.INV_SUB_MIX[0][G.SBOX[t >>> 24]] ^ G.INV_SUB_MIX[1][G.SBOX[(t >>> 16) & 0xff]] ^ G.INV_SUB_MIX[2][G.SBOX[(t >>> 8) & 0xff]] ^ G.INV_SUB_MIX[3][G.SBOX[t & 0xff]] + } + return true +} -var propTypes$57 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; +AES.prototype.encryptBlock = function (M) { + M = bufferToArray(new Buffer(M)) + var out = this._doCryptBlock(M, this._keySchedule, G.SUB_MIX, G.SBOX) + var buf = new Buffer(16) + buf.writeUInt32BE(out[0], 0) + buf.writeUInt32BE(out[1], 4) + buf.writeUInt32BE(out[2], 8) + buf.writeUInt32BE(out[3], 12) + return buf +} -var defaultProps$55 = { - tag: 'ul' -}; +AES.prototype.decryptBlock = function (M) { + M = bufferToArray(new Buffer(M)) + var temp = [M[3], M[1]] + M[1] = temp[0] + M[3] = temp[1] + var out = this._doCryptBlock(M, this._invKeySchedule, G.INV_SUB_MIX, G.INV_SBOX) + var buf = new Buffer(16) + buf.writeUInt32BE(out[0], 0) + buf.writeUInt32BE(out[3], 4) + buf.writeUInt32BE(out[2], 8) + buf.writeUInt32BE(out[1], 12) + return buf +} -var Pagination = function Pagination(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'tag']); +AES.prototype.scrub = function () { + scrub_vec(this._keySchedule) + scrub_vec(this._invKeySchedule) + scrub_vec(this._key) +} +AES.prototype._doCryptBlock = function (M, keySchedule, SUB_MIX, SBOX) { + var ksRow, s0, s1, s2, s3, t0, t1, t2, t3 + + s0 = M[0] ^ keySchedule[0] + s1 = M[1] ^ keySchedule[1] + s2 = M[2] ^ keySchedule[2] + s3 = M[3] ^ keySchedule[3] + ksRow = 4 + for (var round = 1; round < this._nRounds; round++) { + t0 = SUB_MIX[0][s0 >>> 24] ^ SUB_MIX[1][(s1 >>> 16) & 0xff] ^ SUB_MIX[2][(s2 >>> 8) & 0xff] ^ SUB_MIX[3][s3 & 0xff] ^ keySchedule[ksRow++] + t1 = SUB_MIX[0][s1 >>> 24] ^ SUB_MIX[1][(s2 >>> 16) & 0xff] ^ SUB_MIX[2][(s3 >>> 8) & 0xff] ^ SUB_MIX[3][s0 & 0xff] ^ keySchedule[ksRow++] + t2 = SUB_MIX[0][s2 >>> 24] ^ SUB_MIX[1][(s3 >>> 16) & 0xff] ^ SUB_MIX[2][(s0 >>> 8) & 0xff] ^ SUB_MIX[3][s1 & 0xff] ^ keySchedule[ksRow++] + t3 = SUB_MIX[0][s3 >>> 24] ^ SUB_MIX[1][(s0 >>> 16) & 0xff] ^ SUB_MIX[2][(s1 >>> 8) & 0xff] ^ SUB_MIX[3][s2 & 0xff] ^ keySchedule[ksRow++] + s0 = t0 + s1 = t1 + s2 = t2 + s3 = t3 + } + t0 = ((SBOX[s0 >>> 24] << 24) | (SBOX[(s1 >>> 16) & 0xff] << 16) | (SBOX[(s2 >>> 8) & 0xff] << 8) | SBOX[s3 & 0xff]) ^ keySchedule[ksRow++] + t1 = ((SBOX[s1 >>> 24] << 24) | (SBOX[(s2 >>> 16) & 0xff] << 16) | (SBOX[(s3 >>> 8) & 0xff] << 8) | SBOX[s0 & 0xff]) ^ keySchedule[ksRow++] + t2 = ((SBOX[s2 >>> 24] << 24) | (SBOX[(s3 >>> 16) & 0xff] << 16) | (SBOX[(s0 >>> 8) & 0xff] << 8) | SBOX[s1 & 0xff]) ^ keySchedule[ksRow++] + t3 = ((SBOX[s3 >>> 24] << 24) | (SBOX[(s0 >>> 16) & 0xff] << 16) | (SBOX[(s1 >>> 8) & 0xff] << 8) | SBOX[s2 & 0xff]) ^ keySchedule[ksRow++] + return [ + fixup_uint32(t0), + fixup_uint32(t1), + fixup_uint32(t2), + fixup_uint32(t3) + ] +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'pagination', defineProperty({}, 'pagination-' + size, !!size)), cssModule); +exports.AES = AES - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -Pagination.propTypes = propTypes$57; -Pagination.defaultProps = defaultProps$55; +/***/ }), +/* 70 */ +/***/ (function(module, exports) { -var propTypes$58 = { - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; +exports['aes-128-ecb'] = { + cipher: 'AES', + key: 128, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-192-ecb'] = { + cipher: 'AES', + key: 192, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-256-ecb'] = { + cipher: 'AES', + key: 256, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-128-cbc'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes-192-cbc'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes-256-cbc'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes128'] = exports['aes-128-cbc'] +exports['aes192'] = exports['aes-192-cbc'] +exports['aes256'] = exports['aes-256-cbc'] +exports['aes-128-cfb'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-192-cfb'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-256-cfb'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-128-cfb8'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-192-cfb8'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-256-cfb8'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-128-cfb1'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-192-cfb1'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-256-cfb1'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-128-ofb'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-192-ofb'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-256-ofb'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-128-ctr'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-192-ctr'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-256-ctr'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-128-gcm'] = { + cipher: 'AES', + key: 128, + iv: 12, + mode: 'GCM', + type: 'auth' +} +exports['aes-192-gcm'] = { + cipher: 'AES', + key: 192, + iv: 12, + mode: 'GCM', + type: 'auth' +} +exports['aes-256-gcm'] = { + cipher: 'AES', + key: 256, + iv: 12, + mode: 'GCM', + type: 'auth' +} -var defaultProps$56 = { - tag: 'li' -}; -var PaginationItem = function PaginationItem(props) { - var active = props.active, - className = props.className, - cssModule = props.cssModule, - disabled = props.disabled, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['active', 'className', 'cssModule', 'disabled', 'tag']); +/***/ }), +/* 71 */ +/***/ (function(module, exports, __webpack_require__) { +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-item', { - active: active, - disabled: disabled - }), cssModule); +function incr32 (iv) { + var len = iv.length + var item + while (len--) { + item = iv.readUInt8(len) + if (item === 255) { + iv.writeUInt8(0, len) + } else { + item++ + iv.writeUInt8(item, len) + break + } + } +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +function getBlock (self) { + var out = self._cipher.encryptBlock(self._prev) + incr32(self._prev) + return out +} -PaginationItem.propTypes = propTypes$58; -PaginationItem.defaultProps = defaultProps$56; +exports.encrypt = function (self, chunk) { + while (self._cache.length < chunk.length) { + self._cache = Buffer.concat([self._cache, getBlock(self)]) + } + var pad = self._cache.slice(0, chunk.length) + self._cache = self._cache.slice(chunk.length) + return xor(chunk, pad) +} -var propTypes$59 = { - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - next: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - previous: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var defaultProps$57 = { - tag: 'a' -}; +/***/ }), +/* 72 */ +/***/ (function(module, exports, __webpack_require__) { -var PaginationLink = function PaginationLink(props) { - var className = props.className, - cssModule = props.cssModule, - next = props.next, - previous = props.previous, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'next', 'previous', 'tag']); +/* WEBPACK VAR INJECTION */(function(Buffer) {var asn1 = __webpack_require__(439) +var aesid = __webpack_require__(451) +var fixProc = __webpack_require__(452) +var ciphers = __webpack_require__(108) +var compat = __webpack_require__(177) +module.exports = parseKeys +function parseKeys (buffer) { + var password + if (typeof buffer === 'object' && !Buffer.isBuffer(buffer)) { + password = buffer.passphrase + buffer = buffer.key + } + if (typeof buffer === 'string') { + buffer = new Buffer(buffer) + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-link'), cssModule); + var stripped = fixProc(buffer, password) - var defaultAriaLabel = void 0; - if (previous) { - defaultAriaLabel = 'Previous'; - } else if (next) { - defaultAriaLabel = 'Next'; + var type = stripped.tag + var data = stripped.data + var subtype, ndata + switch (type) { + case 'CERTIFICATE': + ndata = asn1.certificate.decode(data, 'der').tbsCertificate.subjectPublicKeyInfo + // falls through + case 'PUBLIC KEY': + if (!ndata) { + ndata = asn1.PublicKey.decode(data, 'der') + } + subtype = ndata.algorithm.algorithm.join('.') + switch (subtype) { + case '1.2.840.113549.1.1.1': + return asn1.RSAPublicKey.decode(ndata.subjectPublicKey.data, 'der') + case '1.2.840.10045.2.1': + ndata.subjectPrivateKey = ndata.subjectPublicKey + return { + type: 'ec', + data: ndata + } + case '1.2.840.10040.4.1': + ndata.algorithm.params.pub_key = asn1.DSAparam.decode(ndata.subjectPublicKey.data, 'der') + return { + type: 'dsa', + data: ndata.algorithm.params + } + default: throw new Error('unknown key id ' + subtype) + } + throw new Error('unknown key type ' + type) + case 'ENCRYPTED PRIVATE KEY': + data = asn1.EncryptedPrivateKey.decode(data, 'der') + data = decrypt(data, password) + // falls through + case 'PRIVATE KEY': + ndata = asn1.PrivateKey.decode(data, 'der') + subtype = ndata.algorithm.algorithm.join('.') + switch (subtype) { + case '1.2.840.113549.1.1.1': + return asn1.RSAPrivateKey.decode(ndata.subjectPrivateKey, 'der') + case '1.2.840.10045.2.1': + return { + curve: ndata.algorithm.curve, + privateKey: asn1.ECPrivateKey.decode(ndata.subjectPrivateKey, 'der').privateKey + } + case '1.2.840.10040.4.1': + ndata.algorithm.params.priv_key = asn1.DSAparam.decode(ndata.subjectPrivateKey, 'der') + return { + type: 'dsa', + params: ndata.algorithm.params + } + default: throw new Error('unknown key id ' + subtype) + } + throw new Error('unknown key type ' + type) + case 'RSA PUBLIC KEY': + return asn1.RSAPublicKey.decode(data, 'der') + case 'RSA PRIVATE KEY': + return asn1.RSAPrivateKey.decode(data, 'der') + case 'DSA PRIVATE KEY': + return { + type: 'dsa', + params: asn1.DSAPrivateKey.decode(data, 'der') + } + case 'EC PRIVATE KEY': + data = asn1.ECPrivateKey.decode(data, 'der') + return { + curve: data.parameters.value, + privateKey: data.privateKey + } + default: throw new Error('unknown key type ' + type) } - var ariaLabel = props['aria-label'] || defaultAriaLabel; +} +parseKeys.signature = asn1.signature +function decrypt (data, password) { + var salt = data.algorithm.decrypt.kde.kdeparams.salt + var iters = parseInt(data.algorithm.decrypt.kde.kdeparams.iters.toString(), 10) + var algo = aesid[data.algorithm.decrypt.cipher.algo.join('.')] + var iv = data.algorithm.decrypt.cipher.iv + var cipherText = data.subjectPrivateKey + var keylen = parseInt(algo.split('-')[1], 10) / 8 + var key = compat.pbkdf2Sync(password, salt, iters, keylen) + var cipher = ciphers.createDecipheriv(algo, key, iv) + var out = [] + out.push(cipher.update(cipherText)) + out.push(cipher.final()) + return Buffer.concat(out) +} - var defaultCaret = void 0; - if (previous) { - defaultCaret = '\xAB'; - } else if (next) { - defaultCaret = '\xBB'; - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - var children = props.children; - if (previous || next) { - children = [__WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { - 'aria-hidden': 'true', - key: 'caret' - }, - children || defaultCaret - ), __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { - className: 'sr-only', - key: 'sr' - }, - ariaLabel - )]; - } +/***/ }), +/* 73 */ +/***/ (function(module, exports, __webpack_require__) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { - className: classes, - 'aria-label': ariaLabel - }), - children - ); -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { -PaginationLink.propTypes = propTypes$59; -PaginationLink.defaultProps = defaultProps$57; +// Number.MAX_SAFE_INTEGER +var MAX_SAFE_INTEGER = 9007199254740991 -var propTypes$60 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - activeTab: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function checkUInt53 (n) { + if (n < 0 || n > MAX_SAFE_INTEGER || n % 1 !== 0) throw new RangeError('value out of range') +} -var defaultProps$58 = { - tag: 'div' -}; +function encode (number, buffer, offset) { + checkUInt53(number) -var childContextTypes$1 = { - activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + if (!buffer) buffer = new Buffer(encodingLength(number)) + if (!Buffer.isBuffer(buffer)) throw new TypeError('buffer must be a Buffer instance') + if (!offset) offset = 0 -var TabContent = function (_Component) { - inherits(TabContent, _Component); + // 8 bit + if (number < 0xfd) { + buffer.writeUInt8(number, offset) + encode.bytes = 1 - function TabContent(props) { - classCallCheck(this, TabContent); + // 16 bit + } else if (number <= 0xffff) { + buffer.writeUInt8(0xfd, offset) + buffer.writeUInt16LE(number, offset + 1) + encode.bytes = 3 - var _this = possibleConstructorReturn(this, (TabContent.__proto__ || Object.getPrototypeOf(TabContent)).call(this, props)); + // 32 bit + } else if (number <= 0xffffffff) { + buffer.writeUInt8(0xfe, offset) + buffer.writeUInt32LE(number, offset + 1) + encode.bytes = 5 - _this.state = { - activeTab: _this.props.activeTab - }; - return _this; + // 64 bit + } else { + buffer.writeUInt8(0xff, offset) + buffer.writeUInt32LE(number >>> 0, offset + 1) + buffer.writeUInt32LE((number / 0x100000000) | 0, offset + 5) + encode.bytes = 9 } - createClass(TabContent, [{ - key: 'getChildContext', - value: function getChildContext() { - return { - activeTabId: this.state.activeTab - }; - } - }, { - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - if (this.state.activeTab !== nextProps.activeTab) { - this.setState({ - activeTab: nextProps.activeTab - }); - } - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - Tag = _props.tag; - + return buffer +} - var attributes = omit(this.props, Object.keys(propTypes$60)); +function decode (buffer, offset) { + if (!Buffer.isBuffer(buffer)) throw new TypeError('buffer must be a Buffer instance') + if (!offset) offset = 0 - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-content', className), cssModule); + var first = buffer.readUInt8(offset) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); - } - }]); - return TabContent; -}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); + // 8 bit + if (first < 0xfd) { + decode.bytes = 1 + return first -TabContent.propTypes = propTypes$60; -TabContent.defaultProps = defaultProps$58; -TabContent.childContextTypes = childContextTypes$1; + // 16 bit + } else if (first === 0xfd) { + decode.bytes = 3 + return buffer.readUInt16LE(offset + 1) -var propTypes$61 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + // 32 bit + } else if (first === 0xfe) { + decode.bytes = 5 + return buffer.readUInt32LE(offset + 1) -var defaultProps$59 = { - tag: 'div' -}; + // 64 bit + } else { + decode.bytes = 9 + var lo = buffer.readUInt32LE(offset + 1) + var hi = buffer.readUInt32LE(offset + 5) + var number = hi * 0x0100000000 + lo + checkUInt53(number) -var contextTypes$3 = { - activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + return number + } +} -function TabPane(props, context) { - var className = props.className, - cssModule = props.cssModule, - tabId = props.tabId, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabId', 'tag']); +function encodingLength (number) { + checkUInt53(number) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-pane', className, { active: tabId === context.activeTabId }), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + return ( + number < 0xfd ? 1 + : number <= 0xffff ? 3 + : number <= 0xffffffff ? 5 + : 9 + ) } -TabPane.propTypes = propTypes$61; -TabPane.defaultProps = defaultProps$59; -TabPane.contextTypes = contextTypes$3; -var propTypes$62 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +module.exports = { encode: encode, decode: decode, encodingLength: encodingLength } -var defaultProps$60 = { - tag: 'div' -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var Jumbotron = function Jumbotron(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - fluid = props.fluid, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'fluid']); +/***/ }), +/* 74 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'jumbotron', fluid ? 'jumbotron-fluid' : false), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -Jumbotron.propTypes = propTypes$62; -Jumbotron.defaultProps = defaultProps$60; +/** + * Forked from fbjs/warning: + * https://github.com/facebook/fbjs/blob/e66ba20ad5be433eb54423f2b097d829324d9de6/packages/fbjs/src/__forks__/warning.js + * + * Only change is we use console.warn instead of console.error, + * and do nothing when 'console' is not supported. + * This really simplifies the code. + * --- + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ -var FirstChild = function FirstChild(_ref) { - var children = _ref.children; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children)[0] || null; -}; +var lowPriorityWarning = function () {}; -var propTypes$63 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - closeClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number -}; +if (process.env.NODE_ENV !== 'production') { + var printWarning = function (format) { + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } -var defaultProps$61 = { - color: 'success', - isOpen: true, - tag: 'div', - transitionAppearTimeout: 150, - transitionEnterTimeout: 150, - transitionLeaveTimeout: 150 -}; + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.warn(message); + } + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} + }; -var Alert = function Alert(props) { - var className = props.className, - closeClassName = props.closeClassName, - cssModule = props.cssModule, - Tag = props.tag, - color = props.color, - isOpen = props.isOpen, - toggle = props.toggle, - children = props.children, - transitionAppearTimeout = props.transitionAppearTimeout, - transitionEnterTimeout = props.transitionEnterTimeout, - transitionLeaveTimeout = props.transitionLeaveTimeout, - attributes = objectWithoutProperties(props, ['className', 'closeClassName', 'cssModule', 'tag', 'color', 'isOpen', 'toggle', 'children', 'transitionAppearTimeout', 'transitionEnterTimeout', 'transitionLeaveTimeout']); + lowPriorityWarning = function (condition, format) { + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + } + if (!condition) { + for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { + args[_key2 - 2] = arguments[_key2]; + } + printWarning.apply(undefined, [format].concat(args)); + } + }; +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'alert', 'alert-' + color, { 'alert-dismissible': toggle }), cssModule); +module.exports = lowPriorityWarning; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var closeClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('close', closeClassName), cssModule); +/***/ }), +/* 75 */ +/***/ (function(module, exports, __webpack_require__) { - var alert = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { className: classes, role: 'alert' }), - toggle ? __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'button', - { type: 'button', className: closeClasses, 'aria-label': 'Close', onClick: toggle }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { 'aria-hidden': 'true' }, - '\xD7' - ) - ) : null, - children - ); - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["CSSTransitionGroup"], - { - component: FirstChild, - transitionName: { - appear: 'fade', - appearActive: 'show', - enter: 'fade', - enterActive: 'show', - leave: 'fade', - leaveActive: 'out' - }, - transitionAppear: transitionAppearTimeout > 0, - transitionAppearTimeout: transitionAppearTimeout, - transitionEnter: transitionEnterTimeout > 0, - transitionEnterTimeout: transitionEnterTimeout, - transitionLeave: transitionLeaveTimeout > 0, - transitionLeaveTimeout: transitionLeaveTimeout - }, - isOpen ? alert : null - ); -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ -Alert.propTypes = propTypes$63; -Alert.defaultProps = defaultProps$61; -var SHOW = 'SHOW'; -var SHOWN = 'SHOWN'; -var HIDE = 'HIDE'; -var HIDDEN = 'HIDDEN'; -var propTypes$64 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - onOpened: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onClosed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; -var DEFAULT_DELAYS$1 = { - show: 350, - hide: 350 -}; +module.exports = ReactPropTypesSecret; -var defaultProps$62 = { - isOpen: false, - tag: 'div', - delay: DEFAULT_DELAYS$1, - onOpened: function onOpened() {}, - onClosed: function onClosed() {} -}; -var Collapse = function (_Component) { - inherits(Collapse, _Component); +/***/ }), +/* 76 */ +/***/ (function(module, exports, __webpack_require__) { - function Collapse(props) { - classCallCheck(this, Collapse); +"use strict"; - var _this = possibleConstructorReturn(this, (Collapse.__proto__ || Object.getPrototypeOf(Collapse)).call(this, props)); - _this.state = { - collapse: props.isOpen ? SHOWN : HIDDEN, - height: null - }; - _this.element = null; - return _this; - } +module.exports = __webpack_require__(230); - createClass(Collapse, [{ - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - var _this2 = this; - var willOpen = nextProps.isOpen; - var collapse = this.state.collapse; +/***/ }), +/* 77 */ +/***/ (function(module, exports, __webpack_require__) { - if (willOpen && collapse === HIDDEN) { - // will open - this.setState({ collapse: SHOW }, function () { - // the height transition will work after class "collapsing" applied - _this2.setState({ height: _this2.getHeight() }); - _this2.transitionTag = setTimeout(function () { - _this2.setState({ - collapse: SHOWN, - height: null - }); - }, _this2.getDelay('show')); - }); - } else if (!willOpen && collapse === SHOWN) { - // will hide - this.setState({ height: this.getHeight() }, function () { - _this2.setState({ - collapse: HIDE, - height: _this2.getHeight() - }, function () { - _this2.setState({ height: 0 }); - }); - }); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - this.transitionTag = setTimeout(function () { - _this2.setState({ - collapse: HIDDEN, - height: null - }); - }, this.getDelay('hide')); - } - // else: do nothing. - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps, prevState) { - if (this.state.collapse === SHOWN && prevState && prevState.collapse !== SHOWN) { - this.props.onOpened(); - } - if (this.state.collapse === HIDDEN && prevState && prevState.collapse !== HIDDEN) { - this.props.onClosed(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - clearTimeout(this.transitionTag); - } - }, { - key: 'getDelay', - value: function getDelay(key) { - var delay = this.props.delay; - if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { - return isNaN(delay[key]) ? DEFAULT_DELAYS$1[key] : delay[key]; - } - return delay; - } - }, { - key: 'getHeight', - value: function getHeight() { - return this.element.scrollHeight; - } - }, { - key: 'render', - value: function render() { - var _this3 = this; +var _prodInvariant = __webpack_require__(5); - var _omit = omit(this.props, ['isOpen', 'delay', 'onOpened', 'onClosed']), - navbar = _omit.navbar, - className = _omit.className, - cssModule = _omit.cssModule, - Tag = _omit.tag, - attributes = objectWithoutProperties(_omit, ['navbar', 'className', 'cssModule', 'tag']); +var ReactErrorUtils = __webpack_require__(78); - var _state = this.state, - collapse = _state.collapse, - height = _state.height; +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); - var collapseClass = void 0; - switch (collapse) { - case SHOW: - collapseClass = 'collapsing'; - break; - case SHOWN: - collapseClass = 'collapse show'; - break; - case HIDE: - collapseClass = 'collapsing'; - break; - case HIDDEN: - collapseClass = 'collapse'; - break; - default: - // HIDDEN - collapseClass = 'collapse'; - } +/** + * Injected dependencies: + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, collapseClass, navbar && 'navbar-collapse'), cssModule); - var style = height === null ? null : { height: height }; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { - style: _extends({}, attributes.style, style), - className: classes, - ref: function ref(c) { - _this3.element = c; - } - })); +/** + * - `ComponentTree`: [required] Module that can convert between React instances + * and actual node references. + */ +var ComponentTree; +var TreeTraversal; +var injection = { + injectComponentTree: function (Injected) { + ComponentTree = Injected; + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.getNodeFromInstance && Injected.getInstanceFromNode, 'EventPluginUtils.injection.injectComponentTree(...): Injected ' + 'module is missing getNodeFromInstance or getInstanceFromNode.') : void 0; } - }]); - return Collapse; -}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); + }, + injectTreeTraversal: function (Injected) { + TreeTraversal = Injected; + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.isAncestor && Injected.getLowestCommonAncestor, 'EventPluginUtils.injection.injectTreeTraversal(...): Injected ' + 'module is missing isAncestor or getLowestCommonAncestor.') : void 0; + } + } +}; -Collapse.propTypes = propTypes$64; -Collapse.defaultProps = defaultProps$62; +function isEndish(topLevelType) { + return topLevelType === 'topMouseUp' || topLevelType === 'topTouchEnd' || topLevelType === 'topTouchCancel'; +} -var propTypes$65 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - action: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; +function isMoveish(topLevelType) { + return topLevelType === 'topMouseMove' || topLevelType === 'topTouchMove'; +} +function isStartish(topLevelType) { + return topLevelType === 'topMouseDown' || topLevelType === 'topTouchStart'; +} -var defaultProps$63 = { - tag: 'li' -}; +var validateEventDispatches; +if (process.env.NODE_ENV !== 'production') { + validateEventDispatches = function (event) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; -var handleDisabledOnClick = function handleDisabledOnClick(e) { - e.preventDefault(); -}; + var listenersIsArr = Array.isArray(dispatchListeners); + var listenersLen = listenersIsArr ? dispatchListeners.length : dispatchListeners ? 1 : 0; -var ListGroupItem = function ListGroupItem(props) { - var className = props.className, - Tag = props.tag, - active = props.active, - disabled = props.disabled, - action = props.action, - color = props.color, - attributes = objectWithoutProperties(props, ['className', 'tag', 'active', 'disabled', 'action', 'color']); + var instancesIsArr = Array.isArray(dispatchInstances); + var instancesLen = instancesIsArr ? dispatchInstances.length : dispatchInstances ? 1 : 0; - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, disabled ? 'disabled' : false, action ? 'list-group-item-action' : false, color ? 'list-group-item-' + color : false, 'list-group-item'); + process.env.NODE_ENV !== 'production' ? warning(instancesIsArr === listenersIsArr && instancesLen === listenersLen, 'EventPluginUtils: Invalid `event`.') : void 0; + }; +} - // Prevent click event when disabled. - if (disabled) { - attributes.onClick = handleDisabledOnClick; +/** + * Dispatch the event to the listener. + * @param {SyntheticEvent} event SyntheticEvent to handle + * @param {boolean} simulated If the event is simulated (changes exn behavior) + * @param {function} listener Application-level callback + * @param {*} inst Internal component instance + */ +function executeDispatch(event, simulated, listener, inst) { + var type = event.type || 'unknown-event'; + event.currentTarget = EventPluginUtils.getNodeFromInstance(inst); + if (simulated) { + ReactErrorUtils.invokeGuardedCallbackWithCatch(type, listener, event); + } else { + ReactErrorUtils.invokeGuardedCallback(type, listener, event); } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + event.currentTarget = null; +} -ListGroupItem.propTypes = propTypes$65; -ListGroupItem.defaultProps = defaultProps$63; +/** + * Standard/simple iteration through an event's collected dispatches. + */ +function executeDispatchesInOrder(event, simulated) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + if (Array.isArray(dispatchListeners)) { + for (var i = 0; i < dispatchListeners.length; i++) { + if (event.isPropagationStopped()) { + break; + } + // Listeners and Instances are two parallel arrays that are always in sync. + executeDispatch(event, simulated, dispatchListeners[i], dispatchInstances[i]); + } + } else if (dispatchListeners) { + executeDispatch(event, simulated, dispatchListeners, dispatchInstances); + } + event._dispatchListeners = null; + event._dispatchInstances = null; +} -var propTypes$66 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; +/** + * Standard/simple iteration through an event's collected dispatches, but stops + * at the first dispatch execution returning true, and returns that id. + * + * @return {?string} id of the first dispatch execution who's listener returns + * true, or null if no listener returned true. + */ +function executeDispatchesInOrderStopAtTrueImpl(event) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + if (Array.isArray(dispatchListeners)) { + for (var i = 0; i < dispatchListeners.length; i++) { + if (event.isPropagationStopped()) { + break; + } + // Listeners and Instances are two parallel arrays that are always in sync. + if (dispatchListeners[i](event, dispatchInstances[i])) { + return dispatchInstances[i]; + } + } + } else if (dispatchListeners) { + if (dispatchListeners(event, dispatchInstances)) { + return dispatchInstances; + } + } + return null; +} -var defaultProps$64 = { - tag: 'h5' -}; +/** + * @see executeDispatchesInOrderStopAtTrueImpl + */ +function executeDispatchesInOrderStopAtTrue(event) { + var ret = executeDispatchesInOrderStopAtTrueImpl(event); + event._dispatchInstances = null; + event._dispatchListeners = null; + return ret; +} -var ListGroupItemHeading = function ListGroupItemHeading(props) { - var className = props.className, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'tag']); +/** + * Execution of a "direct" dispatch - there must be at most one dispatch + * accumulated on the event or it is considered an error. It doesn't really make + * sense for an event with multiple dispatches (bubbled) to keep track of the + * return values at each dispatch execution, but it does tend to make sense when + * dealing with "direct" dispatches. + * + * @return {*} The return value of executing the single dispatch. + */ +function executeDirectDispatch(event) { + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + var dispatchListener = event._dispatchListeners; + var dispatchInstance = event._dispatchInstances; + !!Array.isArray(dispatchListener) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'executeDirectDispatch(...): Invalid `event`.') : _prodInvariant('103') : void 0; + event.currentTarget = dispatchListener ? EventPluginUtils.getNodeFromInstance(dispatchInstance) : null; + var res = dispatchListener ? dispatchListener(event) : null; + event.currentTarget = null; + event._dispatchListeners = null; + event._dispatchInstances = null; + return res; +} - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-heading'); +/** + * @param {SyntheticEvent} event + * @return {boolean} True iff number of dispatches accumulated is greater than 0. + */ +function hasDispatches(event) { + return !!event._dispatchListeners; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/** + * General utilities that are useful in creating custom Event Plugins. + */ +var EventPluginUtils = { + isEndish: isEndish, + isMoveish: isMoveish, + isStartish: isStartish, -ListGroupItemHeading.propTypes = propTypes$66; -ListGroupItemHeading.defaultProps = defaultProps$64; + executeDirectDispatch: executeDirectDispatch, + executeDispatchesInOrder: executeDispatchesInOrder, + executeDispatchesInOrderStopAtTrue: executeDispatchesInOrderStopAtTrue, + hasDispatches: hasDispatches, -var propTypes$67 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + getInstanceFromNode: function (node) { + return ComponentTree.getInstanceFromNode(node); + }, + getNodeFromInstance: function (node) { + return ComponentTree.getNodeFromInstance(node); + }, + isAncestor: function (a, b) { + return TreeTraversal.isAncestor(a, b); + }, + getLowestCommonAncestor: function (a, b) { + return TreeTraversal.getLowestCommonAncestor(a, b); + }, + getParentInstance: function (inst) { + return TreeTraversal.getParentInstance(inst); + }, + traverseTwoPhase: function (target, fn, arg) { + return TreeTraversal.traverseTwoPhase(target, fn, arg); + }, + traverseEnterLeave: function (from, to, fn, argFrom, argTo) { + return TreeTraversal.traverseEnterLeave(from, to, fn, argFrom, argTo); + }, -var defaultProps$65 = { - tag: 'p' + injection: injection }; -var ListGroupItemText = function ListGroupItemText(props) { - var className = props.className, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'tag']); - - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-text'); - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +module.exports = EventPluginUtils; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -ListGroupItemText.propTypes = propTypes$67; -ListGroupItemText.defaultProps = defaultProps$65; +/***/ }), +/* 78 */ +/***/ (function(module, exports, __webpack_require__) { -var Component$1 = __WEBPACK_IMPORTED_MODULE_0_react___default.a.Component; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var components = { - UncontrolledAlert: Alert, - UncontrolledButtonDropdown: ButtonDropdown, - UncontrolledDropdown: Dropdown, - UncontrolledNavDropdown: NavDropdown, - UncontrolledTooltip: Tooltip -}; -Object.keys(components).forEach(function (key) { - var Tag = components[key]; - var defaultValue = Tag === Alert; - var Uncontrolled = function (_Component) { - inherits(Uncontrolled, _Component); +var caughtError = null; - function Uncontrolled(props) { - classCallCheck(this, Uncontrolled); +/** + * Call a function while guarding against errors that happens within it. + * + * @param {String} name of the guard to use for logging or debugging + * @param {Function} func The function to invoke + * @param {*} a First argument + * @param {*} b Second argument + */ +function invokeGuardedCallback(name, func, a) { + try { + func(a); + } catch (x) { + if (caughtError === null) { + caughtError = x; + } + } +} - var _this = possibleConstructorReturn(this, (Uncontrolled.__proto__ || Object.getPrototypeOf(Uncontrolled)).call(this, props)); +var ReactErrorUtils = { + invokeGuardedCallback: invokeGuardedCallback, - _this.state = { isOpen: defaultValue }; + /** + * Invoked by ReactTestUtils.Simulate so that any errors thrown by the event + * handler are sure to be rethrown by rethrowCaughtError. + */ + invokeGuardedCallbackWithCatch: invokeGuardedCallback, - _this.toggle = _this.toggle.bind(_this); - return _this; + /** + * During execution of guarded functions we will capture the first error which + * we will rethrow to be handled by the top level error handler. + */ + rethrowCaughtError: function () { + if (caughtError) { + var error = caughtError; + caughtError = null; + throw error; } + } +}; - createClass(Uncontrolled, [{ - key: 'toggle', - value: function toggle() { - this.setState({ isOpen: !this.state.isOpen }); - } - }, { - key: 'render', - value: function render() { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ isOpen: this.state.isOpen, toggle: this.toggle }, this.props)); - } - }]); - return Uncontrolled; - }(Component$1); - - Uncontrolled.displayName = key; - - components[key] = Uncontrolled; -}); - -var UncontrolledAlert = components.UncontrolledAlert; -var UncontrolledButtonDropdown = components.UncontrolledButtonDropdown; -var UncontrolledDropdown = components.UncontrolledDropdown; -var UncontrolledNavDropdown = components.UncontrolledNavDropdown; -var UncontrolledTooltip = components.UncontrolledTooltip; - - -//# sourceMappingURL=reactstrap.es.js.map +if (process.env.NODE_ENV !== 'production') { + /** + * To help development we can get better devtools integration by simulating a + * real browser event. + */ + if (typeof window !== 'undefined' && typeof window.dispatchEvent === 'function' && typeof document !== 'undefined' && typeof document.createEvent === 'function') { + var fakeNode = document.createElement('react'); + ReactErrorUtils.invokeGuardedCallback = function (name, func, a) { + var boundFunc = func.bind(null, a); + var evtType = 'react-' + name; + fakeNode.addEventListener(evtType, boundFunc, false); + var evt = document.createEvent('Event'); + evt.initEvent(evtType, false, false); + fakeNode.dispatchEvent(evt); + fakeNode.removeEventListener(evtType, boundFunc, false); + }; + } +} +module.exports = ReactErrorUtils; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 67 */, -/* 68 */, -/* 69 */, -/* 70 */, -/* 71 */, -/* 72 */ -/***/ (function(module, exports) { - -/* - MIT License http://www.opensource.org/licenses/mit-license.php - Author Tobias Koppers @sokra -*/ -// css base code, injected by the css-loader -module.exports = function(useSourceMap) { - var list = []; - - // return the list of modules as css string - list.toString = function toString() { - return this.map(function (item) { - var content = cssWithMappingToString(item, useSourceMap); - if(item[2]) { - return "@media " + item[2] + "{" + content + "}"; - } else { - return content; - } - }).join(""); - }; +/* 79 */ +/***/ (function(module, exports, __webpack_require__) { - // import a list of modules into the list - list.i = function(modules, mediaQuery) { - if(typeof modules === "string") - modules = [[null, modules, ""]]; - var alreadyImportedModules = {}; - for(var i = 0; i < this.length; i++) { - var id = this[i][0]; - if(typeof id === "number") - alreadyImportedModules[id] = true; - } - for(i = 0; i < modules.length; i++) { - var item = modules[i]; - // skip already imported module - // this implementation is not 100% perfect for weird media query combinations - // when a module is imported multiple times with different media queries. - // I hope this will never occur (Hey this way we have smaller bundles) - if(typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) { - if(mediaQuery && !item[2]) { - item[2] = mediaQuery; - } else if(mediaQuery) { - item[2] = "(" + item[2] + ") and (" + mediaQuery + ")"; - } - list.push(item); - } - } - }; - return list; -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -function cssWithMappingToString(item, useSourceMap) { - var content = item[1] || ''; - var cssMapping = item[3]; - if (!cssMapping) { - return content; - } - if (useSourceMap && typeof btoa === 'function') { - var sourceMapping = toComment(cssMapping); - var sourceURLs = cssMapping.sources.map(function (source) { - return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */' - }); - return [content].concat(sourceURLs).concat([sourceMapping]).join('\n'); - } +/** + * Gets the target node from a native browser event by accounting for + * inconsistencies in browser DOM APIs. + * + * @param {object} nativeEvent Native browser event. + * @return {DOMEventTarget} Target node. + */ - return [content].join('\n'); -} +function getEventTarget(nativeEvent) { + var target = nativeEvent.target || nativeEvent.srcElement || window; -// Adapted from convert-source-map (MIT) -function toComment(sourceMap) { - // eslint-disable-next-line no-undef - var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))); - var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64; + // Normalize SVG <use> element events #4963 + if (target.correspondingUseElement) { + target = target.correspondingUseElement; + } - return '/*# ' + data + ' */'; + // Safari may fire events on text nodes (Node.TEXT_NODE is 3). + // @see http://www.quirksmode.org/js/events_properties.html + return target.nodeType === 3 ? target.parentNode : target; } +module.exports = getEventTarget; /***/ }), -/* 73 */ +/* 80 */ /***/ (function(module, exports, __webpack_require__) { -/* - MIT License http://www.opensource.org/licenses/mit-license.php - Author Tobias Koppers @sokra -*/ - -var stylesInDom = {}; - -var memoize = function (fn) { - var memo; - - return function () { - if (typeof memo === "undefined") memo = fn.apply(this, arguments); - return memo; - }; -}; - -var isOldIE = memoize(function () { - // Test for IE <= 9 as proposed by Browserhacks - // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805 - // Tests for existence of standard globals is to allow style-loader - // to operate correctly into non-standard environments - // @see https://github.com/webpack-contrib/style-loader/issues/177 - return window && document && document.all && !window.atob; -}); - -var getElement = (function (fn) { - var memo = {}; - - return function(selector) { - if (typeof memo[selector] === "undefined") { - memo[selector] = fn.call(this, selector); - } - - return memo[selector] - }; -})(function (target) { - return document.querySelector(target) -}); - -var singleton = null; -var singletonCounter = 0; -var stylesInsertedAtTop = []; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var fixUrls = __webpack_require__(119); -module.exports = function(list, options) { - if (typeof DEBUG !== "undefined" && DEBUG) { - if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment"); - } - options = options || {}; +var ExecutionEnvironment = __webpack_require__(13); - options.attrs = typeof options.attrs === "object" ? options.attrs : {}; +var useHasFeature; +if (ExecutionEnvironment.canUseDOM) { + useHasFeature = document.implementation && document.implementation.hasFeature && + // always returns true in newer browsers as per the standard. + // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature + document.implementation.hasFeature('', '') !== true; +} - // Force single-tag solution on IE6-9, which has a hard limit on the # of <style> - // tags it will allow on a page - if (!options.singleton) options.singleton = isOldIE(); +/** + * Checks if an event is supported in the current execution environment. + * + * NOTE: This will not work correctly for non-generic events such as `change`, + * `reset`, `load`, `error`, and `select`. + * + * Borrows from Modernizr. + * + * @param {string} eventNameSuffix Event name, e.g. "click". + * @param {?boolean} capture Check if the capture phase is supported. + * @return {boolean} True if the event is supported. + * @internal + * @license Modernizr 3.0.0pre (Custom Build) | MIT + */ +function isEventSupported(eventNameSuffix, capture) { + if (!ExecutionEnvironment.canUseDOM || capture && !('addEventListener' in document)) { + return false; + } - // By default, add <style> tags to the <head> element - if (!options.insertInto) options.insertInto = "head"; + var eventName = 'on' + eventNameSuffix; + var isSupported = eventName in document; - // By default, add <style> tags to the bottom of the target - if (!options.insertAt) options.insertAt = "bottom"; + if (!isSupported) { + var element = document.createElement('div'); + element.setAttribute(eventName, 'return;'); + isSupported = typeof element[eventName] === 'function'; + } - var styles = listToStyles(list, options); + if (!isSupported && useHasFeature && eventNameSuffix === 'wheel') { + // This is the only way to test support for the `wheel` event in IE9+. + isSupported = document.implementation.hasFeature('Events.wheel', '3.0'); + } - addStylesToDom(styles, options); + return isSupported; +} - return function update (newList) { - var mayRemove = []; +module.exports = isEventSupported; - for (var i = 0; i < styles.length; i++) { - var item = styles[i]; - var domStyle = stylesInDom[item.id]; +/***/ }), +/* 81 */ +/***/ (function(module, exports, __webpack_require__) { - domStyle.refs--; - mayRemove.push(domStyle); - } +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if(newList) { - var newStyles = listToStyles(newList, options); - addStylesToDom(newStyles, options); - } - for (var i = 0; i < mayRemove.length; i++) { - var domStyle = mayRemove[i]; - if(domStyle.refs === 0) { - for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](); +/** + * Translation from modifier key to the associated property in the event. + * @see http://www.w3.org/TR/DOM-Level-3-Events/#keys-Modifiers + */ - delete stylesInDom[domStyle.id]; - } - } - }; +var modifierKeyToProp = { + Alt: 'altKey', + Control: 'ctrlKey', + Meta: 'metaKey', + Shift: 'shiftKey' }; -function addStylesToDom (styles, options) { - for (var i = 0; i < styles.length; i++) { - var item = styles[i]; - var domStyle = stylesInDom[item.id]; - - if(domStyle) { - domStyle.refs++; - - for(var j = 0; j < domStyle.parts.length; j++) { - domStyle.parts[j](item.parts[j]); - } - - for(; j < item.parts.length; j++) { - domStyle.parts.push(addStyle(item.parts[j], options)); - } - } else { - var parts = []; - - for(var j = 0; j < item.parts.length; j++) { - parts.push(addStyle(item.parts[j], options)); - } +// IE8 does not implement getModifierState so we simply map it to the only +// modifier keys exposed by the event itself, does not support Lock-keys. +// Currently, all major browsers except Chrome seems to support Lock-keys. +function modifierStateGetter(keyArg) { + var syntheticEvent = this; + var nativeEvent = syntheticEvent.nativeEvent; + if (nativeEvent.getModifierState) { + return nativeEvent.getModifierState(keyArg); + } + var keyProp = modifierKeyToProp[keyArg]; + return keyProp ? !!nativeEvent[keyProp] : false; +} - stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts}; - } - } +function getEventModifierState(nativeEvent) { + return modifierStateGetter; } -function listToStyles (list, options) { - var styles = []; - var newStyles = {}; +module.exports = getEventModifierState; - for (var i = 0; i < list.length; i++) { - var item = list[i]; - var id = options.base ? item[0] + options.base : item[0]; - var css = item[1]; - var media = item[2]; - var sourceMap = item[3]; - var part = {css: css, media: media, sourceMap: sourceMap}; +/***/ }), +/* 82 */ +/***/ (function(module, exports, __webpack_require__) { - if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]}); - else newStyles[id].parts.push(part); - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - return styles; -} -function insertStyleElement (options, style) { - var target = getElement(options.insertInto) - if (!target) { - throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid."); - } +var DOMLazyTree = __webpack_require__(39); +var Danger = __webpack_require__(249); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstrumentation = __webpack_require__(19); - var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1]; +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); +var setInnerHTML = __webpack_require__(60); +var setTextContent = __webpack_require__(135); - if (options.insertAt === "top") { - if (!lastStyleElementInsertedAtTop) { - target.insertBefore(style, target.firstChild); - } else if (lastStyleElementInsertedAtTop.nextSibling) { - target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling); - } else { - target.appendChild(style); - } - stylesInsertedAtTop.push(style); - } else if (options.insertAt === "bottom") { - target.appendChild(style); - } else { - throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'."); - } +function getNodeAfter(parentNode, node) { + // Special case for text components, which return [open, close] comments + // from getHostNode. + if (Array.isArray(node)) { + node = node[1]; + } + return node ? node.nextSibling : parentNode.firstChild; } -function removeStyleElement (style) { - if (style.parentNode === null) return false; - style.parentNode.removeChild(style); +/** + * Inserts `childNode` as a child of `parentNode` at the `index`. + * + * @param {DOMElement} parentNode Parent node in which to insert. + * @param {DOMElement} childNode Child node to insert. + * @param {number} index Index at which to insert the child. + * @internal + */ +var insertChildAt = createMicrosoftUnsafeLocalFunction(function (parentNode, childNode, referenceNode) { + // We rely exclusively on `insertBefore(node, null)` instead of also using + // `appendChild(node)`. (Using `undefined` is not allowed by all browsers so + // we are careful to use `null`.) + parentNode.insertBefore(childNode, referenceNode); +}); - var idx = stylesInsertedAtTop.indexOf(style); - if(idx >= 0) { - stylesInsertedAtTop.splice(idx, 1); - } +function insertLazyTreeChildAt(parentNode, childTree, referenceNode) { + DOMLazyTree.insertTreeBefore(parentNode, childTree, referenceNode); } -function createStyleElement (options) { - var style = document.createElement("style"); - - options.attrs.type = "text/css"; - - addAttrs(style, options.attrs); - insertStyleElement(options, style); - - return style; +function moveChild(parentNode, childNode, referenceNode) { + if (Array.isArray(childNode)) { + moveDelimitedText(parentNode, childNode[0], childNode[1], referenceNode); + } else { + insertChildAt(parentNode, childNode, referenceNode); + } } -function createLinkElement (options) { - var link = document.createElement("link"); - - options.attrs.type = "text/css"; - options.attrs.rel = "stylesheet"; - - addAttrs(link, options.attrs); - insertStyleElement(options, link); +function removeChild(parentNode, childNode) { + if (Array.isArray(childNode)) { + var closingComment = childNode[1]; + childNode = childNode[0]; + removeDelimitedText(parentNode, childNode, closingComment); + parentNode.removeChild(closingComment); + } + parentNode.removeChild(childNode); +} - return link; +function moveDelimitedText(parentNode, openingComment, closingComment, referenceNode) { + var node = openingComment; + while (true) { + var nextNode = node.nextSibling; + insertChildAt(parentNode, node, referenceNode); + if (node === closingComment) { + break; + } + node = nextNode; + } } -function addAttrs (el, attrs) { - Object.keys(attrs).forEach(function (key) { - el.setAttribute(key, attrs[key]); - }); +function removeDelimitedText(parentNode, startNode, closingComment) { + while (true) { + var node = startNode.nextSibling; + if (node === closingComment) { + // The closing comment is removed by ReactMultiChild. + break; + } else { + parentNode.removeChild(node); + } + } } -function addStyle (obj, options) { - var style, update, remove, result; +function replaceDelimitedText(openingComment, closingComment, stringText) { + var parentNode = openingComment.parentNode; + var nodeAfterComment = openingComment.nextSibling; + if (nodeAfterComment === closingComment) { + // There are no text nodes between the opening and closing comments; insert + // a new one if stringText isn't empty. + if (stringText) { + insertChildAt(parentNode, document.createTextNode(stringText), nodeAfterComment); + } + } else { + if (stringText) { + // Set the text content of the first node after the opening comment, and + // remove all following nodes up until the closing comment. + setTextContent(nodeAfterComment, stringText); + removeDelimitedText(parentNode, nodeAfterComment, closingComment); + } else { + removeDelimitedText(parentNode, openingComment, closingComment); + } + } - // If a transform function was defined, run it on the css - if (options.transform && obj.css) { - result = options.transform(obj.css); - - if (result) { - // If transform returns a value, use that instead of the original css. - // This allows running runtime transformations on the css. - obj.css = result; - } else { - // If the transform function returns a falsy value, don't add this css. - // This allows conditional loading of css - return function() { - // noop - }; - } - } - - if (options.singleton) { - var styleIndex = singletonCounter++; - - style = singleton || (singleton = createStyleElement(options)); - - update = applyToSingletonTag.bind(null, style, styleIndex, false); - remove = applyToSingletonTag.bind(null, style, styleIndex, true); - - } else if ( - obj.sourceMap && - typeof URL === "function" && - typeof URL.createObjectURL === "function" && - typeof URL.revokeObjectURL === "function" && - typeof Blob === "function" && - typeof btoa === "function" - ) { - style = createLinkElement(options); - update = updateLink.bind(null, style, options); - remove = function () { - removeStyleElement(style); - - if(style.href) URL.revokeObjectURL(style.href); - }; - } else { - style = createStyleElement(options); - update = applyToTag.bind(null, style); - remove = function () { - removeStyleElement(style); - }; - } - - update(obj); - - return function updateStyle (newObj) { - if (newObj) { - if ( - newObj.css === obj.css && - newObj.media === obj.media && - newObj.sourceMap === obj.sourceMap - ) { - return; - } - - update(obj = newObj); - } else { - remove(); - } - }; + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(openingComment)._debugID, + type: 'replace text', + payload: stringText + }); + } } -var replaceText = (function () { - var textStore = []; +var dangerouslyReplaceNodeWithMarkup = Danger.dangerouslyReplaceNodeWithMarkup; +if (process.env.NODE_ENV !== 'production') { + dangerouslyReplaceNodeWithMarkup = function (oldChild, markup, prevInstance) { + Danger.dangerouslyReplaceNodeWithMarkup(oldChild, markup); + if (prevInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: prevInstance._debugID, + type: 'replace with', + payload: markup.toString() + }); + } else { + var nextInstance = ReactDOMComponentTree.getInstanceFromNode(markup.node); + if (nextInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: nextInstance._debugID, + type: 'mount', + payload: markup.toString() + }); + } + } + }; +} - return function (index, replacement) { - textStore[index] = replacement; +/** + * Operations for updating with DOM children. + */ +var DOMChildrenOperations = { + dangerouslyReplaceNodeWithMarkup: dangerouslyReplaceNodeWithMarkup, - return textStore.filter(Boolean).join('\n'); - }; -})(); + replaceDelimitedText: replaceDelimitedText, -function applyToSingletonTag (style, index, remove, obj) { - var css = remove ? "" : obj.css; + /** + * Updates a component's children by processing a series of updates. The + * update configurations are each expected to have a `parentNode` property. + * + * @param {array<object>} updates List of update configurations. + * @internal + */ + processUpdates: function (parentNode, updates) { + if (process.env.NODE_ENV !== 'production') { + var parentNodeDebugID = ReactDOMComponentTree.getInstanceFromNode(parentNode)._debugID; + } - if (style.styleSheet) { - style.styleSheet.cssText = replaceText(index, css); - } else { - var cssNode = document.createTextNode(css); - var childNodes = style.childNodes; + for (var k = 0; k < updates.length; k++) { + var update = updates[k]; + switch (update.type) { + case 'INSERT_MARKUP': + insertLazyTreeChildAt(parentNode, update.content, getNodeAfter(parentNode, update.afterNode)); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'insert child', + payload: { + toIndex: update.toIndex, + content: update.content.toString() + } + }); + } + break; + case 'MOVE_EXISTING': + moveChild(parentNode, update.fromNode, getNodeAfter(parentNode, update.afterNode)); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'move child', + payload: { fromIndex: update.fromIndex, toIndex: update.toIndex } + }); + } + break; + case 'SET_MARKUP': + setInnerHTML(parentNode, update.content); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'replace children', + payload: update.content.toString() + }); + } + break; + case 'TEXT_CONTENT': + setTextContent(parentNode, update.content); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'replace text', + payload: update.content.toString() + }); + } + break; + case 'REMOVE_NODE': + removeChild(parentNode, update.fromNode); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'remove child', + payload: { fromIndex: update.fromIndex } + }); + } + break; + } + } + } +}; - if (childNodes[index]) style.removeChild(childNodes[index]); +module.exports = DOMChildrenOperations; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - if (childNodes.length) { - style.insertBefore(cssNode, childNodes[index]); - } else { - style.appendChild(cssNode); - } - } -} +/***/ }), +/* 83 */ +/***/ (function(module, exports, __webpack_require__) { -function applyToTag (style, obj) { - var css = obj.css; - var media = obj.media; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if(media) { - style.setAttribute("media", media) - } - if(style.styleSheet) { - style.styleSheet.cssText = css; - } else { - while(style.firstChild) { - style.removeChild(style.firstChild); - } - style.appendChild(document.createTextNode(css)); - } -} +var DOMNamespaces = { + html: 'http://www.w3.org/1999/xhtml', + mathml: 'http://www.w3.org/1998/Math/MathML', + svg: 'http://www.w3.org/2000/svg' +}; -function updateLink (link, options, obj) { - var css = obj.css; - var sourceMap = obj.sourceMap; +module.exports = DOMNamespaces; - /* - If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled - and there is no publicPath defined then lets turn convertToAbsoluteUrls - on by default. Otherwise default to the convertToAbsoluteUrls option - directly - */ - var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap; +/***/ }), +/* 84 */ +/***/ (function(module, exports, __webpack_require__) { - if (options.convertToAbsoluteUrls || autoFixUrls) { - css = fixUrls(css); - } +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if (sourceMap) { - // http://stackoverflow.com/a/26603875 - css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */"; - } +/* globals MSApp */ - var blob = new Blob([css], { type: "text/css" }); - var oldSrc = link.href; - link.href = URL.createObjectURL(blob); +/** + * Create a function which has 'unsafe' privileges (required by windows8 apps) + */ - if(oldSrc) URL.revokeObjectURL(oldSrc); -} +var createMicrosoftUnsafeLocalFunction = function (func) { + if (typeof MSApp !== 'undefined' && MSApp.execUnsafeLocalFunction) { + return function (arg0, arg1, arg2, arg3) { + MSApp.execUnsafeLocalFunction(function () { + return func(arg0, arg1, arg2, arg3); + }); + }; + } else { + return func; + } +}; +module.exports = createMicrosoftUnsafeLocalFunction; /***/ }), -/* 74 */ +/* 85 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -11256,266 +14145,258 @@ function updateLink (link, options, obj) { -var _prodInvariant = __webpack_require__(25), - _assign = __webpack_require__(5); - -var ReactNoopUpdateQueue = __webpack_require__(75); +var _prodInvariant = __webpack_require__(5); -var canDefineProperty = __webpack_require__(38); -var emptyObject = __webpack_require__(39); -var invariant = __webpack_require__(1); -var lowPriorityWarning = __webpack_require__(48); +var ReactPropTypesSecret = __webpack_require__(139); +var propTypesFactory = __webpack_require__(124); -/** - * Base class helpers for the updating state of a component. - */ -function ReactComponent(props, context, updater) { - this.props = props; - this.context = context; - this.refs = emptyObject; - // We initialize the default updater but the real one gets injected by the - // renderer. - this.updater = updater || ReactNoopUpdateQueue; -} +var React = __webpack_require__(36); +var PropTypes = propTypesFactory(React.isValidElement); -ReactComponent.prototype.isReactComponent = {}; +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); -/** - * Sets a subset of the state. Always use this to mutate - * state. You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * There is no guarantee that calls to `setState` will run synchronously, - * as they may eventually be batched together. You can provide an optional - * callback that will be executed when the call to setState is actually - * completed. - * - * When a function is provided to setState, it will be called at some point in - * the future (not synchronously). It will be called with the up to date - * component arguments (state, props, context). These values can be different - * from this.* because your function may be called after receiveProps but before - * shouldComponentUpdate, and this new state, props, and context will not yet be - * assigned to this. - * - * @param {object|function} partialState Next partial state or function to - * produce next partial state to be merged with current state. - * @param {?function} callback Called after state is updated. - * @final - * @protected - */ -ReactComponent.prototype.setState = function (partialState, callback) { - !(typeof partialState === 'object' || typeof partialState === 'function' || partialState == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.') : _prodInvariant('85') : void 0; - this.updater.enqueueSetState(this, partialState); - if (callback) { - this.updater.enqueueCallback(this, callback, 'setState'); - } +var hasReadOnlyValue = { + button: true, + checkbox: true, + image: true, + hidden: true, + radio: true, + reset: true, + submit: true }; -/** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {?function} callback Called after update is complete. - * @final - * @protected - */ -ReactComponent.prototype.forceUpdate = function (callback) { - this.updater.enqueueForceUpdate(this); - if (callback) { - this.updater.enqueueCallback(this, callback, 'forceUpdate'); - } -}; +function _assertSingleLink(inputProps) { + !(inputProps.checkedLink == null || inputProps.valueLink == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a valueLink. If you want to use checkedLink, you probably don\'t want to use valueLink and vice versa.') : _prodInvariant('87') : void 0; +} +function _assertValueLink(inputProps) { + _assertSingleLink(inputProps); + !(inputProps.value == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a valueLink and a value or onChange event. If you want to use value or onChange, you probably don\'t want to use valueLink.') : _prodInvariant('88') : void 0; +} -/** - * Deprecated APIs. These APIs used to exist on classic React classes but since - * we would like to deprecate them, we're not going to move them over to this - * modern base class. Instead, we define a getter that warns if it's accessed. - */ -if (process.env.NODE_ENV !== 'production') { - var deprecatedAPIs = { - isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'], - replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).'] - }; - var defineDeprecationWarning = function (methodName, info) { - if (canDefineProperty) { - Object.defineProperty(ReactComponent.prototype, methodName, { - get: function () { - lowPriorityWarning(false, '%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]); - return undefined; - } - }); +function _assertCheckedLink(inputProps) { + _assertSingleLink(inputProps); + !(inputProps.checked == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a checked property or onChange event. If you want to use checked or onChange, you probably don\'t want to use checkedLink') : _prodInvariant('89') : void 0; +} + +var propTypes = { + value: function (props, propName, componentName) { + if (!props[propName] || hasReadOnlyValue[props.type] || props.onChange || props.readOnly || props.disabled) { + return null; } - }; - for (var fnName in deprecatedAPIs) { - if (deprecatedAPIs.hasOwnProperty(fnName)) { - defineDeprecationWarning(fnName, deprecatedAPIs[fnName]); + return new Error('You provided a `value` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultValue`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); + }, + checked: function (props, propName, componentName) { + if (!props[propName] || props.onChange || props.readOnly || props.disabled) { + return null; + } + return new Error('You provided a `checked` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultChecked`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); + }, + onChange: PropTypes.func +}; + +var loggedTypeFailures = {}; +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; } } + return ''; } /** - * Base class helpers for the updating state of a component. + * Provide a linked `value` attribute for controlled forms. You should not use + * this outside of the ReactDOM controlled form components. */ -function ReactPureComponent(props, context, updater) { - // Duplicated from ReactComponent. - this.props = props; - this.context = context; - this.refs = emptyObject; - // We initialize the default updater but the real one gets injected by the - // renderer. - this.updater = updater || ReactNoopUpdateQueue; -} +var LinkedValueUtils = { + checkPropTypes: function (tagName, props, owner) { + for (var propName in propTypes) { + if (propTypes.hasOwnProperty(propName)) { + var error = propTypes[propName](props, propName, tagName, 'prop', null, ReactPropTypesSecret); + } + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; -function ComponentDummy() {} -ComponentDummy.prototype = ReactComponent.prototype; -ReactPureComponent.prototype = new ComponentDummy(); -ReactPureComponent.prototype.constructor = ReactPureComponent; -// Avoid an extra prototype jump for these methods. -_assign(ReactPureComponent.prototype, ReactComponent.prototype); -ReactPureComponent.prototype.isPureReactComponent = true; + var addendum = getDeclarationErrorAddendum(owner); + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed form propType: %s%s', error.message, addendum) : void 0; + } + } + }, -module.exports = { - Component: ReactComponent, - PureComponent: ReactPureComponent + /** + * @param {object} inputProps Props for form component + * @return {*} current value of the input either from value prop or link. + */ + getValue: function (inputProps) { + if (inputProps.valueLink) { + _assertValueLink(inputProps); + return inputProps.valueLink.value; + } + return inputProps.value; + }, + + /** + * @param {object} inputProps Props for form component + * @return {*} current checked status of the input either from checked prop + * or link. + */ + getChecked: function (inputProps) { + if (inputProps.checkedLink) { + _assertCheckedLink(inputProps); + return inputProps.checkedLink.value; + } + return inputProps.checked; + }, + + /** + * @param {object} inputProps Props for form component + * @param {SyntheticEvent} event change event to handle + */ + executeOnChange: function (inputProps, event) { + if (inputProps.valueLink) { + _assertValueLink(inputProps); + return inputProps.valueLink.requestChange(event.target.value); + } else if (inputProps.checkedLink) { + _assertCheckedLink(inputProps); + return inputProps.checkedLink.requestChange(event.target.checked); + } else if (inputProps.onChange) { + return inputProps.onChange.call(undefined, event); + } + } }; + +module.exports = LinkedValueUtils; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 75 */ +/* 86 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. + * Copyright 2014-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -var warning = __webpack_require__(2); +var _prodInvariant = __webpack_require__(5); -function warnNoop(publicInstance, callerName) { - if (process.env.NODE_ENV !== 'production') { - var constructor = publicInstance.constructor; - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; - } -} +var invariant = __webpack_require__(2); -/** - * This is the abstract API for an update queue. - */ -var ReactNoopUpdateQueue = { +var injected = false; + +var ReactComponentEnvironment = { /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function (publicInstance) { - return false; - }, - - /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. - * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @internal - */ - enqueueCallback: function (publicInstance, callback) {}, - - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal + * Optionally injectable hook for swapping out mount images in the middle of + * the tree. */ - enqueueForceUpdate: function (publicInstance) { - warnNoop(publicInstance, 'forceUpdate'); - }, + replaceNodeWithMarkup: null, /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} completeState Next state. - * @internal + * Optionally injectable hook for processing a queue of child updates. Will + * later move into MultiChildComponents. */ - enqueueReplaceState: function (publicInstance, completeState) { - warnNoop(publicInstance, 'replaceState'); - }, + processChildrenUpdates: null, - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} partialState Next partial state to be merged with state. - * @internal - */ - enqueueSetState: function (publicInstance, partialState) { - warnNoop(publicInstance, 'setState'); + injection: { + injectEnvironment: function (environment) { + !!injected ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactCompositeComponent: injectEnvironment() can only be called once.') : _prodInvariant('104') : void 0; + ReactComponentEnvironment.replaceNodeWithMarkup = environment.replaceNodeWithMarkup; + ReactComponentEnvironment.processChildrenUpdates = environment.processChildrenUpdates; + injected = true; + } } }; -module.exports = ReactNoopUpdateQueue; +module.exports = ReactComponentEnvironment; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 76 */ +/* 87 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /** - * Copyright 2014-present, Facebook, Inc. + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * @typechecks * */ +/*eslint-disable no-self-compare */ -// The Symbol used to tag the ReactElement type. If there is no native Symbol -// nor polyfill, then a plain number is used for performance. -var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; +var hasOwnProperty = Object.prototype.hasOwnProperty; -module.exports = REACT_ELEMENT_TYPE; +/** + * inlined Object.is polyfill to avoid requiring consumers ship their own + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is + */ +function is(x, y) { + // SameValue algorithm + if (x === y) { + // Steps 1-5, 7-10 + // Steps 6.b-6.e: +0 != -0 + // Added the nonzero y check to make Flow happy, but it is redundant + return x !== 0 || y !== 0 || 1 / x === 1 / y; + } else { + // Step 6.a: NaN == NaN + return x !== x && y !== y; + } +} + +/** + * Performs equality by iterating through keys on an object and returning false + * when any key has values which are not strictly equal between the arguments. + * Returns true when the values of all keys are strictly equal. + */ +function shallowEqual(objA, objB) { + if (is(objA, objB)) { + return true; + } + + if (typeof objA !== 'object' || objA === null || typeof objB !== 'object' || objB === null) { + return false; + } + + var keysA = Object.keys(objA); + var keysB = Object.keys(objB); + + if (keysA.length !== keysB.length) { + return false; + } + + // Test for A's keys different from B. + for (var i = 0; i < keysA.length; i++) { + if (!hasOwnProperty.call(objB, keysA[i]) || !is(objA[keysA[i]], objB[keysA[i]])) { + return false; + } + } + + return true; +} + +module.exports = shallowEqual; /***/ }), -/* 77 */ +/* 88 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -11527,973 +14408,723 @@ module.exports = REACT_ELEMENT_TYPE; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -/* global Symbol */ - -var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; -var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. - /** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } + * Given a `prevElement` and `nextElement`, determines if the existing + * instance should be updated as opposed to being destroyed or replaced by a new + * instance. Both arguments are elements. This ensures that this logic can + * operate on stateless trees without any backing instance. * - * @param {?object} maybeIterable - * @return {?function} + * @param {?object} prevElement + * @param {?object} nextElement + * @return {boolean} True if the existing instance should be updated. + * @protected */ -function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; + +function shouldUpdateReactComponent(prevElement, nextElement) { + var prevEmpty = prevElement === null || prevElement === false; + var nextEmpty = nextElement === null || nextElement === false; + if (prevEmpty || nextEmpty) { + return prevEmpty === nextEmpty; + } + + var prevType = typeof prevElement; + var nextType = typeof nextElement; + if (prevType === 'string' || prevType === 'number') { + return nextType === 'string' || nextType === 'number'; + } else { + return nextType === 'object' && prevElement.type === nextElement.type && prevElement.key === nextElement.key; } } -module.exports = getIteratorFn; +module.exports = shouldUpdateReactComponent; /***/ }), -/* 78 */ +/* 89 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. +/** + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -/** - * ReactElementValidator provides a wrapper around a element factory - * which validates the props passed to the element. This is intended to be - * used only in DEV and could be replaced by a static type checker for languages - * that support it. - */ - - - -var ReactCurrentOwner = __webpack_require__(14); -var ReactComponentTreeHook = __webpack_require__(10); -var ReactElement = __webpack_require__(19); - -var checkReactTypeSpec = __webpack_require__(127); - -var canDefineProperty = __webpack_require__(38); -var getIteratorFn = __webpack_require__(77); -var warning = __webpack_require__(2); -var lowPriorityWarning = __webpack_require__(48); - -function getDeclarationErrorAddendum() { - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; -} - -function getSourceInfoErrorAddendum(elementProps) { - if (elementProps !== null && elementProps !== undefined && elementProps.__source !== undefined) { - var source = elementProps.__source; - var fileName = source.fileName.replace(/^.*[\\\/]/, ''); - var lineNumber = source.lineNumber; - return ' Check your code at ' + fileName + ':' + lineNumber + '.'; - } - return ''; -} - -/** - * Warn if there's no key explicitly set on dynamic arrays of children or - * object keys are not valid. This allows us to keep track of children between - * updates. - */ -var ownerHasKeyUseWarning = {}; - -function getCurrentComponentErrorInfo(parentType) { - var info = getDeclarationErrorAddendum(); - if (!info) { - var parentName = typeof parentType === 'string' ? parentType : parentType.displayName || parentType.name; - if (parentName) { - info = ' Check the top-level render call using <' + parentName + '>.'; - } - } - return info; -} /** - * Warn if the element doesn't have an explicit key assigned to it. - * This element is in an array. The array could grow and shrink or be - * reordered. All children that haven't already been validated are required to - * have a "key" property assigned to it. Error statuses are cached so a warning - * will only be shown once. + * Escape and wrap key so it is safe to use as a reactid * - * @internal - * @param {ReactElement} element Element that requires a key. - * @param {*} parentType element's parent's type. + * @param {string} key to be escaped. + * @return {string} the escaped key. */ -function validateExplicitKey(element, parentType) { - if (!element._store || element._store.validated || element.key != null) { - return; - } - element._store.validated = true; - - var memoizer = ownerHasKeyUseWarning.uniqueKey || (ownerHasKeyUseWarning.uniqueKey = {}); - - var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType); - if (memoizer[currentComponentErrorInfo]) { - return; - } - memoizer[currentComponentErrorInfo] = true; - // Usually the current owner is the offender, but if it accepts children as a - // property, it may be the creator of the child that's responsible for - // assigning it a key. - var childOwner = ''; - if (element && element._owner && element._owner !== ReactCurrentOwner.current) { - // Give the component that originally created this child. - childOwner = ' It was passed a child from ' + element._owner.getName() + '.'; - } +function escape(key) { + var escapeRegex = /[=:]/g; + var escaperLookup = { + '=': '=0', + ':': '=2' + }; + var escapedString = ('' + key).replace(escapeRegex, function (match) { + return escaperLookup[match]; + }); - process.env.NODE_ENV !== 'production' ? warning(false, 'Each child in an array or iterator should have a unique "key" prop.' + '%s%s See https://fb.me/react-warning-keys for more information.%s', currentComponentErrorInfo, childOwner, ReactComponentTreeHook.getCurrentStackAddendum(element)) : void 0; + return '$' + escapedString; } /** - * Ensure that every element either is passed in a static location, in an - * array with an explicit keys property defined, or in an object literal - * with valid key property. + * Unescape and unwrap key for human-readable display * - * @internal - * @param {ReactNode} node Statically passed child of any type. - * @param {*} parentType node's parent's type. + * @param {string} key to unescape. + * @return {string} the unescaped key. */ -function validateChildKeys(node, parentType) { - if (typeof node !== 'object') { - return; - } - if (Array.isArray(node)) { - for (var i = 0; i < node.length; i++) { - var child = node[i]; - if (ReactElement.isValidElement(child)) { - validateExplicitKey(child, parentType); - } - } - } else if (ReactElement.isValidElement(node)) { - // This element was passed in a valid location. - if (node._store) { - node._store.validated = true; - } - } else if (node) { - var iteratorFn = getIteratorFn(node); - // Entry iterators provide implicit keys. - if (iteratorFn) { - if (iteratorFn !== node.entries) { - var iterator = iteratorFn.call(node); - var step; - while (!(step = iterator.next()).done) { - if (ReactElement.isValidElement(step.value)) { - validateExplicitKey(step.value, parentType); - } - } - } - } - } -} +function unescape(key) { + var unescapeRegex = /(=0|=2)/g; + var unescaperLookup = { + '=0': '=', + '=2': ':' + }; + var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); -/** - * Given an element, validate that its props follow the propTypes definition, - * provided by the type. - * - * @param {ReactElement} element - */ -function validatePropTypes(element) { - var componentClass = element.type; - if (typeof componentClass !== 'function') { - return; - } - var name = componentClass.displayName || componentClass.name; - if (componentClass.propTypes) { - checkReactTypeSpec(componentClass.propTypes, element.props, 'prop', name, element, null); - } - if (typeof componentClass.getDefaultProps === 'function') { - process.env.NODE_ENV !== 'production' ? warning(componentClass.getDefaultProps.isReactClassApproved, 'getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.') : void 0; - } + return ('' + keySubstring).replace(unescapeRegex, function (match) { + return unescaperLookup[match]; + }); } -var ReactElementValidator = { - createElement: function (type, props, children) { - var validType = typeof type === 'string' || typeof type === 'function'; - // We warn in this case but don't throw. We expect the element creation to - // succeed and there will likely be errors in render. - if (!validType) { - if (typeof type !== 'function' && typeof type !== 'string') { - var info = ''; - if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { - info += ' You likely forgot to export your component from the file ' + "it's defined in."; - } - - var sourceInfo = getSourceInfoErrorAddendum(props); - if (sourceInfo) { - info += sourceInfo; - } else { - info += getDeclarationErrorAddendum(); - } - - info += ReactComponentTreeHook.getCurrentStackAddendum(); - - var currentSource = props !== null && props !== undefined && props.__source !== undefined ? props.__source : null; - ReactComponentTreeHook.pushNonStandardWarningStack(true, currentSource); - process.env.NODE_ENV !== 'production' ? warning(false, 'React.createElement: type is invalid -- expected a string (for ' + 'built-in components) or a class/function (for composite ' + 'components) but got: %s.%s', type == null ? type : typeof type, info) : void 0; - ReactComponentTreeHook.popNonStandardWarningStack(); - } - } - - var element = ReactElement.createElement.apply(this, arguments); - - // The result can be nullish if a mock or a custom function is used. - // TODO: Drop this when these are no longer allowed as the type argument. - if (element == null) { - return element; - } - - // Skip key warning if the type isn't valid since our key validation logic - // doesn't expect a non-string/function type and can throw confusing errors. - // We don't want exception behavior to differ between dev and prod. - // (Rendering will throw with a helpful message and as soon as the type is - // fixed, the key warnings will appear.) - if (validType) { - for (var i = 2; i < arguments.length; i++) { - validateChildKeys(arguments[i], type); - } - } - - validatePropTypes(element); - - return element; - }, - - createFactory: function (type) { - var validatedFactory = ReactElementValidator.createElement.bind(null, type); - // Legacy hook TODO: Warn if this is accessed - validatedFactory.type = type; - - if (process.env.NODE_ENV !== 'production') { - if (canDefineProperty) { - Object.defineProperty(validatedFactory, 'type', { - enumerable: false, - get: function () { - lowPriorityWarning(false, 'Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.'); - Object.defineProperty(this, 'type', { - value: type - }); - return type; - } - }); - } - } - - return validatedFactory; - }, - - cloneElement: function (element, props, children) { - var newElement = ReactElement.cloneElement.apply(this, arguments); - for (var i = 2; i < arguments.length; i++) { - validateChildKeys(arguments[i], newElement.type); - } - validatePropTypes(newElement); - return newElement; - } +var KeyEscapeUtils = { + escape: escape, + unescape: unescape }; -module.exports = ReactElementValidator; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = KeyEscapeUtils; /***/ }), -/* 79 */ +/* 90 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. + * */ -// React 15.5 references this module, and assumes PropTypes are still callable in production. -// Therefore we re-export development-only version with all the PropTypes checks here. -// However if one is migrating to the `prop-types` npm library, they will go through the -// `index.js` entry point, and it will branch depending on the environment. -var factory = __webpack_require__(80); -module.exports = function(isValidElement) { - // It is still allowed in 15.5. - var throwOnDirectAccess = false; - return factory(isValidElement, throwOnDirectAccess); -}; - +var _prodInvariant = __webpack_require__(5); -/***/ }), -/* 80 */ -/***/ (function(module, exports, __webpack_require__) { +var ReactCurrentOwner = __webpack_require__(22); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactUpdates = __webpack_require__(23); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); +function enqueueUpdate(internalInstance) { + ReactUpdates.enqueueUpdate(internalInstance); +} +function formatUnexpectedArgument(arg) { + var type = typeof arg; + if (type !== 'object') { + return type; + } + var displayName = arg.constructor && arg.constructor.name || type; + var keys = Object.keys(arg); + if (keys.length > 0 && keys.length < 20) { + return displayName + ' (keys: ' + keys.join(', ') + ')'; + } + return displayName; +} -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +function getInternalInstanceReadyForUpdate(publicInstance, callerName) { + var internalInstance = ReactInstanceMap.get(publicInstance); + if (!internalInstance) { + if (process.env.NODE_ENV !== 'production') { + var ctor = publicInstance.constructor; + // Only warn when we have a callerName. Otherwise we should be silent. + // We're probably calling from enqueueCallback. We don't want to warn + // there because we already warned for the corresponding lifecycle method. + process.env.NODE_ENV !== 'production' ? warning(!callerName, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, ctor && (ctor.displayName || ctor.name) || 'ReactClass') : void 0; + } + return null; + } -var ReactPropTypesSecret = __webpack_require__(49); -var checkPropTypes = __webpack_require__(131); + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '%s(...): Cannot update during an existing state transition (such as ' + "within `render` or another component's constructor). Render methods " + 'should be a pure function of props and state; constructor ' + 'side-effects are an anti-pattern, but can be moved to ' + '`componentWillMount`.', callerName) : void 0; + } -module.exports = function(isValidElement, throwOnDirectAccess) { - /* global Symbol */ - var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; - var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. + return internalInstance; +} +/** + * ReactUpdateQueue allows for state updates to be scheduled into a later + * reconciliation step. + */ +var ReactUpdateQueue = { /** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } - * - * @param {?object} maybeIterable - * @return {?function} + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final */ - function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; + isMounted: function (publicInstance) { + if (process.env.NODE_ENV !== 'production') { + var owner = ReactCurrentOwner.current; + if (owner !== null) { + process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing isMounted inside its render() function. ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; + owner._warnedAboutRefsInRender = true; + } } - } + var internalInstance = ReactInstanceMap.get(publicInstance); + if (internalInstance) { + // During componentWillMount and render this will still be null but after + // that will always render to something. At least for now. So we can use + // this hack. + return !!internalInstance._renderedComponent; + } else { + return false; + } + }, /** - * Collection of methods that allow declaration and validation of props that are - * supplied to React components. Example usage: - * - * var Props = require('ReactPropTypes'); - * var MyArticle = React.createClass({ - * propTypes: { - * // An optional string prop named "description". - * description: Props.string, - * - * // A required enum prop named "category". - * category: Props.oneOf(['News','Photos']).isRequired, - * - * // A prop named "dialog" that requires an instance of Dialog. - * dialog: Props.instanceOf(Dialog).isRequired - * }, - * render: function() { ... } - * }); - * - * A more formal specification of how these methods are used: - * - * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...) - * decl := ReactPropTypes.{type}(.isRequired)? - * - * Each and every declaration produces a function with the same signature. This - * allows the creation of custom validation functions. For example: - * - * var MyLink = React.createClass({ - * propTypes: { - * // An optional string or URI prop named "href". - * href: function(props, propName, componentName) { - * var propValue = props[propName]; - * if (propValue != null && typeof propValue !== 'string' && - * !(propValue instanceof URI)) { - * return new Error( - * 'Expected a string or an URI for ' + propName + ' in ' + - * componentName - * ); - * } - * } - * }, - * render: function() {...} - * }); + * Enqueue a callback that will be executed after all the pending updates + * have processed. * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @param {string} callerName Name of the calling function in the public API. * @internal */ + enqueueCallback: function (publicInstance, callback, callerName) { + ReactUpdateQueue.validateCallback(callback, callerName); + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance); - var ANONYMOUS = '<<anonymous>>'; - - // Important! - // Keep this list in sync with production version in `./factoryWithThrowingShims.js`. - var ReactPropTypes = { - array: createPrimitiveTypeChecker('array'), - bool: createPrimitiveTypeChecker('boolean'), - func: createPrimitiveTypeChecker('function'), - number: createPrimitiveTypeChecker('number'), - object: createPrimitiveTypeChecker('object'), - string: createPrimitiveTypeChecker('string'), - symbol: createPrimitiveTypeChecker('symbol'), + // Previously we would throw an error if we didn't have an internal + // instance. Since we want to make it a no-op instead, we mirror the same + // behavior we have in other enqueue* methods. + // We also need to ignore callbacks in componentWillMount. See + // enqueueUpdates. + if (!internalInstance) { + return null; + } - any: createAnyTypeChecker(), - arrayOf: createArrayOfTypeChecker, - element: createElementTypeChecker(), - instanceOf: createInstanceTypeChecker, - node: createNodeChecker(), - objectOf: createObjectOfTypeChecker, - oneOf: createEnumTypeChecker, - oneOfType: createUnionTypeChecker, - shape: createShapeTypeChecker - }; + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); + } else { + internalInstance._pendingCallbacks = [callback]; + } + // TODO: The callback here is ignored when setState is called from + // componentWillMount. Either fix it or disallow doing so completely in + // favor of getInitialState. Alternatively, we can disallow + // componentWillMount during server-side rendering. + enqueueUpdate(internalInstance); + }, - /** - * inlined Object.is polyfill to avoid requiring consumers ship their own - * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is - */ - /*eslint-disable no-self-compare*/ - function is(x, y) { - // SameValue algorithm - if (x === y) { - // Steps 1-5, 7-10 - // Steps 6.b-6.e: +0 != -0 - return x !== 0 || 1 / x === 1 / y; + enqueueCallbackInternal: function (internalInstance, callback) { + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); } else { - // Step 6.a: NaN == NaN - return x !== x && y !== y; + internalInstance._pendingCallbacks = [callback]; } - } - /*eslint-enable no-self-compare*/ + enqueueUpdate(internalInstance); + }, /** - * We use an Error-like object for backward compatibility as people may call - * PropTypes directly and inspect their output. However, we don't use real - * Errors anymore. We don't inspect their stack anyway, and creating them - * is prohibitively expensive if they are created too often, such as what - * happens in oneOfType() for any type before the one that matched. + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal */ - function PropTypeError(message) { - this.message = message; - this.stack = ''; - } - // Make `instanceof Error` still work for returned errors. - PropTypeError.prototype = Error.prototype; - - function createChainableTypeChecker(validate) { - if (process.env.NODE_ENV !== 'production') { - var manualPropTypeCallCache = {}; - var manualPropTypeWarningCount = 0; - } - function checkType(isRequired, props, propName, componentName, location, propFullName, secret) { - componentName = componentName || ANONYMOUS; - propFullName = propFullName || propName; + enqueueForceUpdate: function (publicInstance) { + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'forceUpdate'); - if (secret !== ReactPropTypesSecret) { - if (throwOnDirectAccess) { - // New behavior only for users of `prop-types` package - invariant( - false, - 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + - 'Use `PropTypes.checkPropTypes()` to call them. ' + - 'Read more at http://fb.me/use-check-prop-types' - ); - } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') { - // Old behavior for people using React.PropTypes - var cacheKey = componentName + ':' + propName; - if ( - !manualPropTypeCallCache[cacheKey] && - // Avoid spamming the console because they are often not actionable except for lib authors - manualPropTypeWarningCount < 3 - ) { - warning( - false, - 'You are manually calling a React.PropTypes validation ' + - 'function for the `%s` prop on `%s`. This is deprecated ' + - 'and will throw in the standalone `prop-types` package. ' + - 'You may be seeing this warning due to a third-party PropTypes ' + - 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.', - propFullName, - componentName - ); - manualPropTypeCallCache[cacheKey] = true; - manualPropTypeWarningCount++; - } - } - } - if (props[propName] == null) { - if (isRequired) { - if (props[propName] === null) { - return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.')); - } - return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.')); - } - return null; - } else { - return validate(props, propName, componentName, location, propFullName); - } + if (!internalInstance) { + return; } - var chainedCheckType = checkType.bind(null, false); - chainedCheckType.isRequired = checkType.bind(null, true); + internalInstance._pendingForceUpdate = true; - return chainedCheckType; - } + enqueueUpdate(internalInstance); + }, - function createPrimitiveTypeChecker(expectedType) { - function validate(props, propName, componentName, location, propFullName, secret) { - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== expectedType) { - // `propValue` being instance of, say, date/regexp, pass the 'object' - // check, but we can offer a more precise error message here rather than - // 'of type `object`'. - var preciseType = getPreciseType(propValue); + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} completeState Next state. + * @internal + */ + enqueueReplaceState: function (publicInstance, completeState, callback) { + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'replaceState'); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.')); - } - return null; + if (!internalInstance) { + return; } - return createChainableTypeChecker(validate); - } - function createAnyTypeChecker() { - return createChainableTypeChecker(emptyFunction.thatReturnsNull); - } - - function createArrayOfTypeChecker(typeChecker) { - function validate(props, propName, componentName, location, propFullName) { - if (typeof typeChecker !== 'function') { - return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.'); - } - var propValue = props[propName]; - if (!Array.isArray(propValue)) { - var propType = getPropType(propValue); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.')); - } - for (var i = 0; i < propValue.length; i++) { - var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret); - if (error instanceof Error) { - return error; - } - } - return null; - } - return createChainableTypeChecker(validate); - } + internalInstance._pendingStateQueue = [completeState]; + internalInstance._pendingReplaceState = true; - function createElementTypeChecker() { - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - if (!isValidElement(propValue)) { - var propType = getPropType(propValue); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.')); + // Future-proof 15.5 + if (callback !== undefined && callback !== null) { + ReactUpdateQueue.validateCallback(callback, 'replaceState'); + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); + } else { + internalInstance._pendingCallbacks = [callback]; } - return null; } - return createChainableTypeChecker(validate); - } - function createInstanceTypeChecker(expectedClass) { - function validate(props, propName, componentName, location, propFullName) { - if (!(props[propName] instanceof expectedClass)) { - var expectedClassName = expectedClass.name || ANONYMOUS; - var actualClassName = getClassName(props[propName]); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.')); - } - return null; - } - return createChainableTypeChecker(validate); - } + enqueueUpdate(internalInstance); + }, - function createEnumTypeChecker(expectedValues) { - if (!Array.isArray(expectedValues)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOf, expected an instance of array.') : void 0; - return emptyFunction.thatReturnsNull; + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} partialState Next partial state to be merged with state. + * @internal + */ + enqueueSetState: function (publicInstance, partialState) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetState(); + process.env.NODE_ENV !== 'production' ? warning(partialState != null, 'setState(...): You passed an undefined or null state object; ' + 'instead, use forceUpdate().') : void 0; } - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - for (var i = 0; i < expectedValues.length; i++) { - if (is(propValue, expectedValues[i])) { - return null; - } - } - - var valuesString = JSON.stringify(expectedValues); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + propValue + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.')); - } - return createChainableTypeChecker(validate); - } + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'setState'); - function createObjectOfTypeChecker(typeChecker) { - function validate(props, propName, componentName, location, propFullName) { - if (typeof typeChecker !== 'function') { - return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.'); - } - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== 'object') { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.')); - } - for (var key in propValue) { - if (propValue.hasOwnProperty(key)) { - var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); - if (error instanceof Error) { - return error; - } - } - } - return null; + if (!internalInstance) { + return; } - return createChainableTypeChecker(validate); - } - function createUnionTypeChecker(arrayOfTypeCheckers) { - if (!Array.isArray(arrayOfTypeCheckers)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOfType, expected an instance of array.') : void 0; - return emptyFunction.thatReturnsNull; - } + var queue = internalInstance._pendingStateQueue || (internalInstance._pendingStateQueue = []); + queue.push(partialState); - for (var i = 0; i < arrayOfTypeCheckers.length; i++) { - var checker = arrayOfTypeCheckers[i]; - if (typeof checker !== 'function') { - warning( - false, - 'Invalid argument supplid to oneOfType. Expected an array of check functions, but ' + - 'received %s at index %s.', - getPostfixForTypeWarning(checker), - i - ); - return emptyFunction.thatReturnsNull; - } - } + enqueueUpdate(internalInstance); + }, - function validate(props, propName, componentName, location, propFullName) { - for (var i = 0; i < arrayOfTypeCheckers.length; i++) { - var checker = arrayOfTypeCheckers[i]; - if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) { - return null; - } - } + enqueueElementInternal: function (internalInstance, nextElement, nextContext) { + internalInstance._pendingElement = nextElement; + // TODO: introduce _pendingContext instead of setting it directly. + internalInstance._context = nextContext; + enqueueUpdate(internalInstance); + }, - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.')); - } - return createChainableTypeChecker(validate); + validateCallback: function (callback, callerName) { + !(!callback || typeof callback === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.', callerName, formatUnexpectedArgument(callback)) : _prodInvariant('122', callerName, formatUnexpectedArgument(callback)) : void 0; } +}; - function createNodeChecker() { - function validate(props, propName, componentName, location, propFullName) { - if (!isNode(props[propName])) { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.')); - } - return null; - } - return createChainableTypeChecker(validate); - } +module.exports = ReactUpdateQueue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - function createShapeTypeChecker(shapeTypes) { - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== 'object') { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.')); - } - for (var key in shapeTypes) { - var checker = shapeTypes[key]; - if (!checker) { - continue; - } - var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); - if (error) { - return error; - } - } - return null; - } - return createChainableTypeChecker(validate); - } +/***/ }), +/* 91 */ +/***/ (function(module, exports, __webpack_require__) { - function isNode(propValue) { - switch (typeof propValue) { - case 'number': - case 'string': - case 'undefined': - return true; - case 'boolean': - return !propValue; - case 'object': - if (Array.isArray(propValue)) { - return propValue.every(isNode); - } - if (propValue === null || isValidElement(propValue)) { - return true; - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var iteratorFn = getIteratorFn(propValue); - if (iteratorFn) { - var iterator = iteratorFn.call(propValue); - var step; - if (iteratorFn !== propValue.entries) { - while (!(step = iterator.next()).done) { - if (!isNode(step.value)) { - return false; - } - } - } else { - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - if (!isNode(entry[1])) { - return false; - } - } - } - } - } else { - return false; - } - return true; - default: - return false; - } - } - function isSymbol(propType, propValue) { - // Native Symbol. - if (propType === 'symbol') { - return true; - } +var _assign = __webpack_require__(8); - // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol' - if (propValue['@@toStringTag'] === 'Symbol') { - return true; - } +var emptyFunction = __webpack_require__(18); +var warning = __webpack_require__(3); - // Fallback for non-spec compliant Symbols which are polyfilled. - if (typeof Symbol === 'function' && propValue instanceof Symbol) { - return true; - } +var validateDOMNesting = emptyFunction; - return false; - } +if (process.env.NODE_ENV !== 'production') { + // This validation code was written based on the HTML5 parsing spec: + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope + // + // Note: this does not catch all invalid nesting, nor does it try to (as it's + // not clear what practical benefit doing so provides); instead, we warn only + // for cases where the parser will give a parse tree differing from what React + // intended. For example, <b><div></div></b> is invalid but we don't warn + // because it still parses correctly; we do warn for other cases like nested + // <p> tags where the beginning of the second element implicitly closes the + // first, causing a confusing mess. - // Equivalent of `typeof` but with special handling for array and regexp. - function getPropType(propValue) { - var propType = typeof propValue; - if (Array.isArray(propValue)) { - return 'array'; + // https://html.spec.whatwg.org/multipage/syntax.html#special + var specialTags = ['address', 'applet', 'area', 'article', 'aside', 'base', 'basefont', 'bgsound', 'blockquote', 'body', 'br', 'button', 'caption', 'center', 'col', 'colgroup', 'dd', 'details', 'dir', 'div', 'dl', 'dt', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'frame', 'frameset', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'iframe', 'img', 'input', 'isindex', 'li', 'link', 'listing', 'main', 'marquee', 'menu', 'menuitem', 'meta', 'nav', 'noembed', 'noframes', 'noscript', 'object', 'ol', 'p', 'param', 'plaintext', 'pre', 'script', 'section', 'select', 'source', 'style', 'summary', 'table', 'tbody', 'td', 'template', 'textarea', 'tfoot', 'th', 'thead', 'title', 'tr', 'track', 'ul', 'wbr', 'xmp']; + + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope + var inScopeTags = ['applet', 'caption', 'html', 'table', 'td', 'th', 'marquee', 'object', 'template', + + // https://html.spec.whatwg.org/multipage/syntax.html#html-integration-point + // TODO: Distinguish by namespace here -- for <title>, including it here + // errs on the side of fewer warnings + 'foreignObject', 'desc', 'title']; + + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-button-scope + var buttonScopeTags = inScopeTags.concat(['button']); + + // https://html.spec.whatwg.org/multipage/syntax.html#generate-implied-end-tags + var impliedEndTags = ['dd', 'dt', 'li', 'option', 'optgroup', 'p', 'rp', 'rt']; + + var emptyAncestorInfo = { + current: null, + + formTag: null, + aTagInScope: null, + buttonTagInScope: null, + nobrTagInScope: null, + pTagInButtonScope: null, + + listItemTagAutoclosing: null, + dlItemTagAutoclosing: null + }; + + var updatedAncestorInfo = function (oldInfo, tag, instance) { + var ancestorInfo = _assign({}, oldInfo || emptyAncestorInfo); + var info = { tag: tag, instance: instance }; + + if (inScopeTags.indexOf(tag) !== -1) { + ancestorInfo.aTagInScope = null; + ancestorInfo.buttonTagInScope = null; + ancestorInfo.nobrTagInScope = null; } - if (propValue instanceof RegExp) { - // Old webkits (at least until Android 4.0) return 'function' rather than - // 'object' for typeof a RegExp. We'll normalize this here so that /bla/ - // passes PropTypes.object. - return 'object'; + if (buttonScopeTags.indexOf(tag) !== -1) { + ancestorInfo.pTagInButtonScope = null; } - if (isSymbol(propType, propValue)) { - return 'symbol'; + + // See rules for 'li', 'dd', 'dt' start tags in + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody + if (specialTags.indexOf(tag) !== -1 && tag !== 'address' && tag !== 'div' && tag !== 'p') { + ancestorInfo.listItemTagAutoclosing = null; + ancestorInfo.dlItemTagAutoclosing = null; } - return propType; - } - // This handles more types than `getPropType`. Only used for error messages. - // See `createPrimitiveTypeChecker`. - function getPreciseType(propValue) { - if (typeof propValue === 'undefined' || propValue === null) { - return '' + propValue; + ancestorInfo.current = info; + + if (tag === 'form') { + ancestorInfo.formTag = info; } - var propType = getPropType(propValue); - if (propType === 'object') { - if (propValue instanceof Date) { - return 'date'; - } else if (propValue instanceof RegExp) { - return 'regexp'; - } + if (tag === 'a') { + ancestorInfo.aTagInScope = info; } - return propType; - } - - // Returns a string that is postfixed to a warning about an invalid type. - // For example, "undefined" or "of type array" - function getPostfixForTypeWarning(value) { - var type = getPreciseType(value); - switch (type) { - case 'array': - case 'object': - return 'an ' + type; - case 'boolean': - case 'date': - case 'regexp': - return 'a ' + type; - default: - return type; + if (tag === 'button') { + ancestorInfo.buttonTagInScope = info; } - } - - // Returns class name of the object, if any. - function getClassName(propValue) { - if (!propValue.constructor || !propValue.constructor.name) { - return ANONYMOUS; + if (tag === 'nobr') { + ancestorInfo.nobrTagInScope = info; + } + if (tag === 'p') { + ancestorInfo.pTagInButtonScope = info; + } + if (tag === 'li') { + ancestorInfo.listItemTagAutoclosing = info; + } + if (tag === 'dd' || tag === 'dt') { + ancestorInfo.dlItemTagAutoclosing = info; } - return propValue.constructor.name; - } - ReactPropTypes.checkPropTypes = checkPropTypes; - ReactPropTypes.PropTypes = ReactPropTypes; + return ancestorInfo; + }; - return ReactPropTypes; -}; + /** + * Returns whether + */ + var isTagValidWithParent = function (tag, parentTag) { + // First, let's check if we're in an unusual parsing mode... + switch (parentTag) { + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inselect + case 'select': + return tag === 'option' || tag === 'optgroup' || tag === '#text'; + case 'optgroup': + return tag === 'option' || tag === '#text'; + // Strictly speaking, seeing an <option> doesn't mean we're in a <select> + // but + case 'option': + return tag === '#text'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intd + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incaption + // No special behavior since these rules fall back to "in body" mode for + // all except special table nodes which cause bad parsing behavior anyway. -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intr + case 'tr': + return tag === 'th' || tag === 'td' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intbody + case 'tbody': + case 'thead': + case 'tfoot': + return tag === 'tr' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incolgroup + case 'colgroup': + return tag === 'col' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intable + case 'table': + return tag === 'caption' || tag === 'colgroup' || tag === 'tbody' || tag === 'tfoot' || tag === 'thead' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inhead + case 'head': + return tag === 'base' || tag === 'basefont' || tag === 'bgsound' || tag === 'link' || tag === 'meta' || tag === 'title' || tag === 'noscript' || tag === 'noframes' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/semantics.html#the-html-element + case 'html': + return tag === 'head' || tag === 'body'; + case '#document': + return tag === 'html'; + } -/***/ }), -/* 81 */ -/***/ (function(module, exports, __webpack_require__) { + // Probably in the "in body" parsing mode, so we outlaw only tag combos + // where the parsing rules cause implicit opens or closes to be added. + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody + switch (tag) { + case 'h1': + case 'h2': + case 'h3': + case 'h4': + case 'h5': + case 'h6': + return parentTag !== 'h1' && parentTag !== 'h2' && parentTag !== 'h3' && parentTag !== 'h4' && parentTag !== 'h5' && parentTag !== 'h6'; -"use strict"; -/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + case 'rp': + case 'rt': + return impliedEndTags.indexOf(parentTag) === -1; + case 'body': + case 'caption': + case 'col': + case 'colgroup': + case 'frame': + case 'head': + case 'html': + case 'tbody': + case 'td': + case 'tfoot': + case 'th': + case 'thead': + case 'tr': + // These tags are only valid with a few parents that have special child + // parsing rules -- if we're down here, then none of those matched and + // so we allow it only if we don't know what the parent is, as all other + // cases are invalid. + return parentTag == null; + } + return true; + }; -var ReactDOMComponentFlags = { - hasCachedChildNodes: 1 << 0 -}; + /** + * Returns whether + */ + var findInvalidAncestorForTag = function (tag, ancestorInfo) { + switch (tag) { + case 'address': + case 'article': + case 'aside': + case 'blockquote': + case 'center': + case 'details': + case 'dialog': + case 'dir': + case 'div': + case 'dl': + case 'fieldset': + case 'figcaption': + case 'figure': + case 'footer': + case 'header': + case 'hgroup': + case 'main': + case 'menu': + case 'nav': + case 'ol': + case 'p': + case 'section': + case 'summary': + case 'ul': + case 'pre': + case 'listing': + case 'table': + case 'hr': + case 'xmp': + case 'h1': + case 'h2': + case 'h3': + case 'h4': + case 'h5': + case 'h6': + return ancestorInfo.pTagInButtonScope; -module.exports = ReactDOMComponentFlags; + case 'form': + return ancestorInfo.formTag || ancestorInfo.pTagInButtonScope; -/***/ }), -/* 82 */ -/***/ (function(module, exports, __webpack_require__) { + case 'li': + return ancestorInfo.listItemTagAutoclosing; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + case 'dd': + case 'dt': + return ancestorInfo.dlItemTagAutoclosing; + case 'button': + return ancestorInfo.buttonTagInScope; + case 'a': + // Spec says something about storing a list of markers, but it sounds + // equivalent to this check. + return ancestorInfo.aTagInScope; -var _prodInvariant = __webpack_require__(3); + case 'nobr': + return ancestorInfo.nobrTagInScope; + } -var invariant = __webpack_require__(1); + return null; + }; -/** - * Accumulates items that must not be null or undefined into the first one. This - * is used to conserve memory by avoiding array allocations, and thus sacrifices - * API cleanness. Since `current` can be null before being passed in and not - * null after this function, make sure to assign it back to `current`: - * - * `a = accumulateInto(a, b);` - * - * This API should be sparingly used. Try `accumulate` for something cleaner. - * - * @return {*|array<*>} An accumulation of items. - */ + /** + * Given a ReactCompositeComponent instance, return a list of its recursive + * owners, starting at the root and ending with the instance itself. + */ + var findOwnerStack = function (instance) { + if (!instance) { + return []; + } -function accumulateInto(current, next) { - !(next != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'accumulateInto(...): Accumulated items must not be null or undefined.') : _prodInvariant('30') : void 0; + var stack = []; + do { + stack.push(instance); + } while (instance = instance._currentElement._owner); + stack.reverse(); + return stack; + }; - if (current == null) { - return next; - } + var didWarn = {}; - // Both are not empty. Warning: Never call x.concat(y) when you are not - // certain that x is an Array (x could be a string with concat method). - if (Array.isArray(current)) { - if (Array.isArray(next)) { - current.push.apply(current, next); - return current; + validateDOMNesting = function (childTag, childText, childInstance, ancestorInfo) { + ancestorInfo = ancestorInfo || emptyAncestorInfo; + var parentInfo = ancestorInfo.current; + var parentTag = parentInfo && parentInfo.tag; + + if (childText != null) { + process.env.NODE_ENV !== 'production' ? warning(childTag == null, 'validateDOMNesting: when childText is passed, childTag should be null') : void 0; + childTag = '#text'; } - current.push(next); - return current; - } - if (Array.isArray(next)) { - // A bit too dangerous to mutate `next`. - return [current].concat(next); - } + var invalidParent = isTagValidWithParent(childTag, parentTag) ? null : parentInfo; + var invalidAncestor = invalidParent ? null : findInvalidAncestorForTag(childTag, ancestorInfo); + var problematic = invalidParent || invalidAncestor; - return [current, next]; -} + if (problematic) { + var ancestorTag = problematic.tag; + var ancestorInstance = problematic.instance; -module.exports = accumulateInto; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var childOwner = childInstance && childInstance._currentElement._owner; + var ancestorOwner = ancestorInstance && ancestorInstance._currentElement._owner; -/***/ }), -/* 83 */ -/***/ (function(module, exports, __webpack_require__) { + var childOwners = findOwnerStack(childOwner); + var ancestorOwners = findOwnerStack(ancestorOwner); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var minStackLen = Math.min(childOwners.length, ancestorOwners.length); + var i; + var deepestCommon = -1; + for (i = 0; i < minStackLen; i++) { + if (childOwners[i] === ancestorOwners[i]) { + deepestCommon = i; + } else { + break; + } + } + var UNKNOWN = '(unknown)'; + var childOwnerNames = childOwners.slice(deepestCommon + 1).map(function (inst) { + return inst.getName() || UNKNOWN; + }); + var ancestorOwnerNames = ancestorOwners.slice(deepestCommon + 1).map(function (inst) { + return inst.getName() || UNKNOWN; + }); + var ownerInfo = [].concat( + // If the parent and child instances have a common owner ancestor, start + // with that -- otherwise we just start with the parent's owners. + deepestCommon !== -1 ? childOwners[deepestCommon].getName() || UNKNOWN : [], ancestorOwnerNames, ancestorTag, + // If we're warning about an invalid (non-parent) ancestry, add '...' + invalidAncestor ? ['...'] : [], childOwnerNames, childTag).join(' > '); -/** - * @param {array} arr an "accumulation" of items which is either an Array or - * a single item. Useful when paired with the `accumulate` module. This is a - * simple utility that allows us to reason about a collection of items, but - * handling the case when there is exactly one item (and we do not need to - * allocate an array). - */ + var warnKey = !!invalidParent + '|' + childTag + '|' + ancestorTag + '|' + ownerInfo; + if (didWarn[warnKey]) { + return; + } + didWarn[warnKey] = true; -function forEachAccumulated(arr, cb, scope) { - if (Array.isArray(arr)) { - arr.forEach(cb, scope); - } else if (arr) { - cb.call(scope, arr); - } + var tagDisplayName = childTag; + var whitespaceInfo = ''; + if (childTag === '#text') { + if (/\S/.test(childText)) { + tagDisplayName = 'Text nodes'; + } else { + tagDisplayName = 'Whitespace text nodes'; + whitespaceInfo = " Make sure you don't have any extra whitespace between tags on " + 'each line of your source code.'; + } + } else { + tagDisplayName = '<' + childTag + '>'; + } + + if (invalidParent) { + var info = ''; + if (ancestorTag === 'table' && childTag === 'tr') { + info += ' Add a <tbody> to your code to match the DOM tree generated by ' + 'the browser.'; + } + process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a child of <%s>.%s ' + 'See %s.%s', tagDisplayName, ancestorTag, whitespaceInfo, ownerInfo, info) : void 0; + } else { + process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a descendant of ' + '<%s>. See %s.', tagDisplayName, ancestorTag, ownerInfo) : void 0; + } + } + }; + + validateDOMNesting.updatedAncestorInfo = updatedAncestorInfo; + + // For testing + validateDOMNesting.isTagValidInContext = function (tag, ancestorInfo) { + ancestorInfo = ancestorInfo || emptyAncestorInfo; + var parentInfo = ancestorInfo.current; + var parentTag = parentInfo && parentInfo.tag; + return isTagValidWithParent(tag, parentTag) && !findInvalidAncestorForTag(tag, ancestorInfo); + }; } -module.exports = forEachAccumulated; +module.exports = validateDOMNesting; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 84 */ +/* 92 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -12509,18132 +15140,65347 @@ module.exports = forEachAccumulated; -var ExecutionEnvironment = __webpack_require__(8); - -var contentKey = null; - /** - * Gets the key used to access text content on a DOM node. + * `charCode` represents the actual "character code" and is safe to use with + * `String.fromCharCode`. As such, only keys that correspond to printable + * characters produce a valid `charCode`, the only exception to this is Enter. + * The Tab-key is considered non-printable and does not have a `charCode`, + * presumably because it does not produce a tab-character in browsers. * - * @return {?string} Key used to access text content. - * @internal + * @param {object} nativeEvent Native browser event. + * @return {number} Normalized `charCode` property. */ -function getTextContentAccessor() { - if (!contentKey && ExecutionEnvironment.canUseDOM) { - // Prefer textContent to innerText because many browsers support both but - // SVG <text> elements don't support innerText even when <div> does. - contentKey = 'textContent' in document.documentElement ? 'textContent' : 'innerText'; + +function getEventCharCode(nativeEvent) { + var charCode; + var keyCode = nativeEvent.keyCode; + + if ('charCode' in nativeEvent) { + charCode = nativeEvent.charCode; + + // FF does not set `charCode` for the Enter-key, check against `keyCode`. + if (charCode === 0 && keyCode === 13) { + charCode = 13; + } + } else { + // IE8 does not implement `charCode`, but `keyCode` has the correct value. + charCode = keyCode; } - return contentKey; + + // Some non-printable keys are reported in `charCode`/`keyCode`, discard them. + // Must not discard the (non-)printable Enter-key. + if (charCode >= 32 || charCode === 13) { + return charCode; + } + + return 0; } -module.exports = getTextContentAccessor; +module.exports = getEventCharCode; /***/ }), -/* 85 */ -/***/ (function(module, exports, __webpack_require__) { +/* 93 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Alert", function() { return Alert; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Container", function() { return Container; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Row", function() { return Row; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Col", function() { return Col; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Navbar", function() { return Navbar; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarBrand", function() { return NavbarBrand; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarToggler", function() { return NavbarToggler; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Nav", function() { return Nav; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavItem", function() { return NavItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavDropdown", function() { return NavDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavLink", function() { return NavLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Breadcrumb", function() { return Breadcrumb; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BreadcrumbItem", function() { return BreadcrumbItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Button", function() { return Button; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonDropdown", function() { return ButtonDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonGroup", function() { return ButtonGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonToolbar", function() { return ButtonToolbar; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Dropdown", function() { return Dropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownItem", function() { return DropdownItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownMenu", function() { return DropdownMenu; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownToggle", function() { return DropdownToggle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Fade", function() { return Fade; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Badge", function() { return Badge; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Card", function() { return Card; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardLink", function() { return CardLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardGroup", function() { return CardGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardDeck", function() { return CardDeck; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardColumns", function() { return CardColumns; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardBlock", function() { return CardBlock; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardFooter", function() { return CardFooter; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardHeader", function() { return CardHeader; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImg", function() { return CardImg; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImgOverlay", function() { return CardImgOverlay; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardSubtitle", function() { return CardSubtitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardText", function() { return CardText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardTitle", function() { return CardTitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Popover", function() { return Popover; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverContent", function() { return PopoverContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverTitle", function() { return PopoverTitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Progress", function() { return Progress; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Modal", function() { return Modal; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalHeader", function() { return ModalHeader; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalBody", function() { return ModalBody; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalFooter", function() { return ModalFooter; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TetherContent", function() { return TetherContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Tooltip", function() { return Tooltip; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Table", function() { return Table; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroup", function() { return ListGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Form", function() { return Form; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormFeedback", function() { return FormFeedback; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormGroup", function() { return FormGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormText", function() { return FormText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Input", function() { return Input; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroup", function() { return InputGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupAddon", function() { return InputGroupAddon; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupButton", function() { return InputGroupButton; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Label", function() { return Label; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Media", function() { return Media; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Pagination", function() { return Pagination; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationItem", function() { return PaginationItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationLink", function() { return PaginationLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabContent", function() { return TabContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabPane", function() { return TabPane; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Jumbotron", function() { return Jumbotron; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Collapse", function() { return Collapse; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItem", function() { return ListGroupItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemText", function() { return ListGroupItemText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemHeading", function() { return ListGroupItemHeading; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledAlert", function() { return UncontrolledAlert; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledButtonDropdown", function() { return UncontrolledButtonDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledDropdown", function() { return UncontrolledDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledNavDropdown", function() { return UncontrolledNavDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledTooltip", function() { return UncontrolledTooltip; }); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(6); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(40); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames__ = __webpack_require__(41); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_classnames__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject__ = __webpack_require__(317); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_lodash_isobject__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom__ = __webpack_require__(76); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_react_dom__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__ = __webpack_require__(318); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__ = __webpack_require__(319); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__ = __webpack_require__(320); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group__ = __webpack_require__(321); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8_react_transition_group__); -var _prodInvariant = __webpack_require__(3); -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -var PooledClass = __webpack_require__(20); -var invariant = __webpack_require__(1); -/** - * A specialized pseudo-event module to help keep track of components waiting to - * be notified when their DOM representations are available for use. - * - * This implements `PooledClass`, so you should never need to instantiate this. - * Instead, use `CallbackQueue.getPooled()`. - * - * @class ReactMountReady - * @implements PooledClass - * @internal - */ -var CallbackQueue = function () { - function CallbackQueue(arg) { - _classCallCheck(this, CallbackQueue); - this._callbacks = null; - this._contexts = null; - this._arg = arg; + +function getTetherAttachments(placement) { + var attachments = {}; + switch (placement) { + case 'top': + case 'top center': + attachments = { + attachment: 'bottom center', + targetAttachment: 'top center' + }; + break; + case 'bottom': + case 'bottom center': + attachments = { + attachment: 'top center', + targetAttachment: 'bottom center' + }; + break; + case 'left': + case 'left center': + attachments = { + attachment: 'middle right', + targetAttachment: 'middle left' + }; + break; + case 'right': + case 'right center': + attachments = { + attachment: 'middle left', + targetAttachment: 'middle right' + }; + break; + case 'top left': + attachments = { + attachment: 'bottom left', + targetAttachment: 'top left' + }; + break; + case 'top right': + attachments = { + attachment: 'bottom right', + targetAttachment: 'top right' + }; + break; + case 'bottom left': + attachments = { + attachment: 'top left', + targetAttachment: 'bottom left' + }; + break; + case 'bottom right': + attachments = { + attachment: 'top right', + targetAttachment: 'bottom right' + }; + break; + case 'right top': + attachments = { + attachment: 'top left', + targetAttachment: 'top right' + }; + break; + case 'right bottom': + attachments = { + attachment: 'bottom left', + targetAttachment: 'bottom right' + }; + break; + case 'left top': + attachments = { + attachment: 'top right', + targetAttachment: 'top left' + }; + break; + case 'left bottom': + attachments = { + attachment: 'bottom right', + targetAttachment: 'bottom left' + }; + break; + default: + attachments = { + attachment: 'top center', + targetAttachment: 'bottom center' + }; } - /** - * Enqueues a callback to be invoked when `notifyAll` is invoked. - * - * @param {function} callback Invoked when `notifyAll` is invoked. - * @param {?object} context Context to call `callback` with. - * @internal - */ + return attachments; +} +var tetherAttachements = ['top', 'bottom', 'left', 'right', 'top left', 'top center', 'top right', 'right top', 'right middle', 'right bottom', 'bottom right', 'bottom center', 'bottom left', 'left top', 'left middle', 'left bottom']; - CallbackQueue.prototype.enqueue = function enqueue(callback, context) { - this._callbacks = this._callbacks || []; - this._callbacks.push(callback); - this._contexts = this._contexts || []; - this._contexts.push(context); - }; +// https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L436-L443 +function getScrollbarWidth() { + var scrollDiv = document.createElement('div'); + // .modal-scrollbar-measure styles // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/scss/_modal.scss#L106-L113 + scrollDiv.style.position = 'absolute'; + scrollDiv.style.top = '-9999px'; + scrollDiv.style.width = '50px'; + scrollDiv.style.height = '50px'; + scrollDiv.style.overflow = 'scroll'; + document.body.appendChild(scrollDiv); + var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth; + document.body.removeChild(scrollDiv); + return scrollbarWidth; +} - /** - * Invokes all enqueued callbacks and clears the queue. This is invoked after - * the DOM representation of a component has been created or updated. - * - * @internal - */ +function setScrollbarWidth(padding) { + document.body.style.paddingRight = padding > 0 ? padding + 'px' : null; +} +function isBodyOverflowing() { + return document.body.clientWidth < window.innerWidth; +} - CallbackQueue.prototype.notifyAll = function notifyAll() { - var callbacks = this._callbacks; - var contexts = this._contexts; - var arg = this._arg; - if (callbacks && contexts) { - !(callbacks.length === contexts.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Mismatched list of contexts in callback queue') : _prodInvariant('24') : void 0; - this._callbacks = null; - this._contexts = null; - for (var i = 0; i < callbacks.length; i++) { - callbacks[i].call(contexts[i], arg); - } - callbacks.length = 0; - contexts.length = 0; - } - }; +function getOriginalBodyPadding() { + return parseInt(window.getComputedStyle(document.body, null).getPropertyValue('padding-right') || 0, 10); +} - CallbackQueue.prototype.checkpoint = function checkpoint() { - return this._callbacks ? this._callbacks.length : 0; - }; +function conditionallyUpdateScrollbar() { + var scrollbarWidth = getScrollbarWidth(); + // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L420 + var fixedContent = document.querySelectorAll('.navbar-fixed-top, .navbar-fixed-bottom, .is-fixed')[0]; + var bodyPadding = fixedContent ? parseInt(fixedContent.style.paddingRight || 0, 10) : 0; - CallbackQueue.prototype.rollback = function rollback(len) { - if (this._callbacks && this._contexts) { - this._callbacks.length = len; - this._contexts.length = len; - } - }; + if (isBodyOverflowing()) { + setScrollbarWidth(bodyPadding + scrollbarWidth); + } +} - /** - * Resets the internal queue. - * - * @internal - */ +function mapToCssModules(className, cssModule) { + if (!cssModule) return className; + return className.split(' ').map(function (c) { + return cssModule[c] || c; + }).join(' '); +} +/** + * Returns a new object with the key/value pairs from `obj` that are not in the array `omitKeys`. + */ +function omit(obj, omitKeys) { + var result = {}; + Object.keys(obj).forEach(function (key) { + if (omitKeys.indexOf(key) === -1) { + result[key] = obj[key]; + } + }); + return result; +} - CallbackQueue.prototype.reset = function reset() { - this._callbacks = null; - this._contexts = null; - }; +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { + return typeof obj; +} : function (obj) { + return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; +}; - /** - * `PooledClass` looks for this. - */ - CallbackQueue.prototype.destructor = function destructor() { - this.reset(); - }; - return CallbackQueue; -}(); -module.exports = PooledClass.addPoolingTo(CallbackQueue); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -/***/ }), -/* 86 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ -var ReactFeatureFlags = { - // When true, call console.time() before and .timeEnd() after each top-level - // render (both initial renders and updates). Useful when looking at prod-mode - // timeline profiles in Chrome, for example. - logTopLevelRenders: false -}; -module.exports = ReactFeatureFlags; +var classCallCheck = function (instance, Constructor) { + if (!(instance instanceof Constructor)) { + throw new TypeError("Cannot call a class as a function"); + } +}; -/***/ }), -/* 87 */ -/***/ (function(module, exports, __webpack_require__) { +var createClass = function () { + function defineProperties(target, props) { + for (var i = 0; i < props.length; i++) { + var descriptor = props[i]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return function (Constructor, protoProps, staticProps) { + if (protoProps) defineProperties(Constructor.prototype, protoProps); + if (staticProps) defineProperties(Constructor, staticProps); + return Constructor; + }; +}(); -var ReactDOMComponentTree = __webpack_require__(6); -function isCheckable(elem) { - var type = elem.type; - var nodeName = elem.nodeName; - return nodeName && nodeName.toLowerCase() === 'input' && (type === 'checkbox' || type === 'radio'); -} -function getTracker(inst) { - return inst._wrapperState.valueTracker; -} +var defineProperty = function (obj, key, value) { + if (key in obj) { + Object.defineProperty(obj, key, { + value: value, + enumerable: true, + configurable: true, + writable: true + }); + } else { + obj[key] = value; + } -function attachTracker(inst, tracker) { - inst._wrapperState.valueTracker = tracker; -} + return obj; +}; -function detachTracker(inst) { - delete inst._wrapperState.valueTracker; -} +var _extends = Object.assign || function (target) { + for (var i = 1; i < arguments.length; i++) { + var source = arguments[i]; -function getValueFromNode(node) { - var value; - if (node) { - value = isCheckable(node) ? '' + node.checked : node.value; + for (var key in source) { + if (Object.prototype.hasOwnProperty.call(source, key)) { + target[key] = source[key]; + } + } } - return value; -} -var inputValueTracking = { - // exposed for testing - _getTrackerFromNode: function (node) { - return getTracker(ReactDOMComponentTree.getInstanceFromNode(node)); - }, + return target; +}; - track: function (inst) { - if (getTracker(inst)) { - return; + +var inherits = function (subClass, superClass) { + if (typeof superClass !== "function" && superClass !== null) { + throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); + } + + subClass.prototype = Object.create(superClass && superClass.prototype, { + constructor: { + value: subClass, + enumerable: false, + writable: true, + configurable: true } + }); + if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; +}; - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var valueField = isCheckable(node) ? 'checked' : 'value'; - var descriptor = Object.getOwnPropertyDescriptor(node.constructor.prototype, valueField); - var currentValue = '' + node[valueField]; - // if someone has already defined a value or Safari, then bail - // and don't track value will cause over reporting of changes, - // but it's better then a hard failure - // (needed for certain tests that spyOn input values and Safari) - if (node.hasOwnProperty(valueField) || typeof descriptor.get !== 'function' || typeof descriptor.set !== 'function') { - return; - } - Object.defineProperty(node, valueField, { - enumerable: descriptor.enumerable, - configurable: true, - get: function () { - return descriptor.get.call(this); - }, - set: function (value) { - currentValue = '' + value; - descriptor.set.call(this, value); - } - }); - attachTracker(inst, { - getValue: function () { - return currentValue; - }, - setValue: function (value) { - currentValue = '' + value; - }, - stopTracking: function () { - detachTracker(inst); - delete node[valueField]; - } - }); - }, - updateValueIfChanged: function (inst) { - if (!inst) { - return false; - } - var tracker = getTracker(inst); - if (!tracker) { - inputValueTracking.track(inst); - return true; - } - var lastValue = tracker.getValue(); - var nextValue = getValueFromNode(ReactDOMComponentTree.getNodeFromInstance(inst)); - if (nextValue !== lastValue) { - tracker.setValue(nextValue); - return true; - } +var objectWithoutProperties = function (obj, keys) { + var target = {}; - return false; - }, - stopTracking: function (inst) { - var tracker = getTracker(inst); - if (tracker) { - tracker.stopTracking(); - } + for (var i in obj) { + if (keys.indexOf(i) >= 0) continue; + if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; + target[i] = obj[i]; } + + return target; }; -module.exports = inputValueTracking; +var possibleConstructorReturn = function (self, call) { + if (!self) { + throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); + } -/***/ }), -/* 88 */ -/***/ (function(module, exports, __webpack_require__) { + return call && (typeof call === "object" || typeof call === "function") ? call : self; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var propTypes = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; +var defaultProps = { + tag: 'div' +}; +var Container = function Container(props) { + var className = props.className, + cssModule = props.cssModule, + fluid = props.fluid, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'fluid', 'tag']); -/** - * @see http://www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#input-type-attr-summary - */ -var supportedInputTypes = { - color: true, - date: true, - datetime: true, - 'datetime-local': true, - email: true, - month: true, - number: true, - password: true, - range: true, - search: true, - tel: true, - text: true, - time: true, - url: true, - week: true + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, fluid ? 'container-fluid' : 'container'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -function isTextInputElement(elem) { - var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); +Container.propTypes = propTypes; +Container.defaultProps = defaultProps; - if (nodeName === 'input') { - return !!supportedInputTypes[elem.type]; - } +var propTypes$1 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + noGutters: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - if (nodeName === 'textarea') { - return true; - } +var defaultProps$1 = { + tag: 'div' +}; - return false; -} +var Row = function Row(props) { + var className = props.className, + cssModule = props.cssModule, + noGutters = props.noGutters, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'noGutters', 'tag']); -module.exports = isTextInputElement; -/***/ }), -/* 89 */ -/***/ (function(module, exports, __webpack_require__) { + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, noGutters ? 'no-gutters' : null, 'row'), cssModule); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +Row.propTypes = propTypes$1; +Row.defaultProps = defaultProps$1; +var colWidths = ['xs', 'sm', 'md', 'lg', 'xl']; +var stringOrNumberProp = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); -var ViewportMetrics = { - currentScrollLeft: 0, +var columnProps = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + push: stringOrNumberProp, + pull: stringOrNumberProp, + offset: stringOrNumberProp +})]); - currentScrollTop: 0, +var propTypes$2 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + xs: columnProps, + sm: columnProps, + md: columnProps, + lg: columnProps, + xl: columnProps, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + widths: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.array +}; - refreshScrollValues: function (scrollPosition) { - ViewportMetrics.currentScrollLeft = scrollPosition.x; - ViewportMetrics.currentScrollTop = scrollPosition.y; - } +var defaultProps$2 = { + tag: 'div', + widths: colWidths }; -module.exports = ViewportMetrics; +var getColumnSizeClass = function getColumnSizeClass(isXs, colWidth, colSize) { + if (colSize === true || colSize === '') { + return isXs ? 'col' : 'col-' + colWidth; + } else if (colSize === 'auto') { + return isXs ? 'col-auto' : 'col-' + colWidth + '-auto'; + } -/***/ }), -/* 90 */ -/***/ (function(module, exports, __webpack_require__) { + return isXs ? 'col-' + colSize : 'col-' + colWidth + '-' + colSize; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Col = function Col(props) { + var className = props.className, + cssModule = props.cssModule, + widths = props.widths, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'widths', 'tag']); + var colClasses = []; + widths.forEach(function (colWidth, i) { + var columnProp = props[colWidth]; -var ExecutionEnvironment = __webpack_require__(8); -var escapeTextContentForBrowser = __webpack_require__(44); -var setInnerHTML = __webpack_require__(43); + if (!i && columnProp === undefined) { + columnProp = true; + } -/** - * Set the textContent property of a node, ensuring that whitespace is preserved - * even in IE8. innerText is a poor substitute for textContent and, among many - * issues, inserts <br> instead of the literal newline chars. innerHTML behaves - * as it should. - * - * @param {DOMElement} node - * @param {string} text - * @internal - */ -var setTextContent = function (node, text) { - if (text) { - var firstChild = node.firstChild; + delete attributes[colWidth]; - if (firstChild && firstChild === node.lastChild && firstChild.nodeType === 3) { - firstChild.nodeValue = text; + if (!columnProp) { return; } - } - node.textContent = text; -}; -if (ExecutionEnvironment.canUseDOM) { - if (!('textContent' in document.documentElement)) { - setTextContent = function (node, text) { - if (node.nodeType === 3) { - node.nodeValue = text; - return; - } - setInnerHTML(node, escapeTextContentForBrowser(text)); - }; - } -} + var isXs = !i; + var colClass = void 0; -module.exports = setTextContent; + if (__WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default()(columnProp)) { + var _classNames; -/***/ }), -/* 91 */ -/***/ (function(module, exports, __webpack_require__) { + var colSizeInterfix = isXs ? '-' : '-' + colWidth + '-'; + colClass = getColumnSizeClass(isXs, colWidth, columnProp.size); -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, colClass, columnProp.size || columnProp.size === ''), defineProperty(_classNames, 'push' + colSizeInterfix + columnProp.push, columnProp.push || columnProp.push === 0), defineProperty(_classNames, 'pull' + colSizeInterfix + columnProp.pull, columnProp.pull || columnProp.pull === 0), defineProperty(_classNames, 'offset' + colSizeInterfix + columnProp.offset, columnProp.offset || columnProp.offset === 0), _classNames))), cssModule); + } else { + colClass = getColumnSizeClass(isXs, colWidth, columnProp); + colClasses.push(colClass); + } + }); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, colClasses), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -/** - * @param {DOMElement} node input/textarea to focus - */ +Col.propTypes = propTypes$2; +Col.defaultProps = defaultProps$2; -function focusNode(node) { - // IE8 can throw "Can't move focus to the control because it is invisible, - // not enabled, or of a type that does not accept the focus." for all kinds of - // reasons that are too expensive and fragile to test. - try { - node.focus(); - } catch (e) {} -} +var propTypes$3 = { + light: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + full: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + fixed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + sticky: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggleable: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; -module.exports = focusNode; +var defaultProps$3 = { + tag: 'nav', + toggleable: false +}; -/***/ }), -/* 92 */ -/***/ (function(module, exports, __webpack_require__) { +var getToggleableClass = function getToggleableClass(toggleable) { + if (toggleable === false) { + return false; + } else if (toggleable === true || toggleable === 'xs') { + return 'navbar-toggleable'; + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return 'navbar-toggleable-' + toggleable; +}; +var Navbar = function Navbar(props) { + var _classNames; + var toggleable = props.toggleable, + className = props.className, + cssModule = props.cssModule, + light = props.light, + inverse = props.inverse, + full = props.full, + fixed = props.fixed, + sticky = props.sticky, + color = props.color, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['toggleable', 'className', 'cssModule', 'light', 'inverse', 'full', 'fixed', 'sticky', 'color', 'tag']); -/** - * CSS properties which accept numbers but are not in units of "px". - */ -var isUnitlessNumber = { - animationIterationCount: true, - borderImageOutset: true, - borderImageSlice: true, - borderImageWidth: true, - boxFlex: true, - boxFlexGroup: true, - boxOrdinalGroup: true, - columnCount: true, - flex: true, - flexGrow: true, - flexPositive: true, - flexShrink: true, - flexNegative: true, - flexOrder: true, - gridRow: true, - gridRowEnd: true, - gridRowSpan: true, - gridRowStart: true, - gridColumn: true, - gridColumnEnd: true, - gridColumnSpan: true, - gridColumnStart: true, - fontWeight: true, - lineClamp: true, - lineHeight: true, - opacity: true, - order: true, - orphans: true, - tabSize: true, - widows: true, - zIndex: true, - zoom: true, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar', getToggleableClass(toggleable), (_classNames = { + 'navbar-light': light, + 'navbar-inverse': inverse + }, defineProperty(_classNames, 'bg-' + color, color), defineProperty(_classNames, 'navbar-full', full), defineProperty(_classNames, 'fixed-' + fixed, fixed), defineProperty(_classNames, 'sticky-' + sticky, sticky), _classNames)), cssModule); - // SVG-related properties - fillOpacity: true, - floodOpacity: true, - stopOpacity: true, - strokeDasharray: true, - strokeDashoffset: true, - strokeMiterlimit: true, - strokeOpacity: true, - strokeWidth: true + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -/** - * @param {string} prefix vendor-specific prefix, eg: Webkit - * @param {string} key style name, eg: transitionDuration - * @return {string} style name prefixed with `prefix`, properly camelCased, eg: - * WebkitTransitionDuration - */ -function prefixKey(prefix, key) { - return prefix + key.charAt(0).toUpperCase() + key.substring(1); -} - -/** - * Support style names that may come passed in prefixed by adding permutations - * of vendor prefixes. - */ -var prefixes = ['Webkit', 'ms', 'Moz', 'O']; - -// Using Object.keys here, or else the vanilla for-in loop makes IE8 go into an -// infinite loop, because it iterates over the newly added props too. -Object.keys(isUnitlessNumber).forEach(function (prop) { - prefixes.forEach(function (prefix) { - isUnitlessNumber[prefixKey(prefix, prop)] = isUnitlessNumber[prop]; - }); -}); +Navbar.propTypes = propTypes$3; +Navbar.defaultProps = defaultProps$3; -/** - * Most style properties can be unset by doing .style[prop] = '' but IE8 - * doesn't like doing that with shorthand properties so for the properties that - * IE8 breaks on, which are listed here, we instead unset each of the - * individual properties. See http://bugs.jquery.com/ticket/12385. - * The 4-value 'clock' properties like margin, padding, border-width seem to - * behave without any problems. Curiously, list-style works too without any - * special prodding. - */ -var shorthandPropertyExpansions = { - background: { - backgroundAttachment: true, - backgroundColor: true, - backgroundImage: true, - backgroundPositionX: true, - backgroundPositionY: true, - backgroundRepeat: true - }, - backgroundPosition: { - backgroundPositionX: true, - backgroundPositionY: true - }, - border: { - borderWidth: true, - borderStyle: true, - borderColor: true - }, - borderBottom: { - borderBottomWidth: true, - borderBottomStyle: true, - borderBottomColor: true - }, - borderLeft: { - borderLeftWidth: true, - borderLeftStyle: true, - borderLeftColor: true - }, - borderRight: { - borderRightWidth: true, - borderRightStyle: true, - borderRightColor: true - }, - borderTop: { - borderTopWidth: true, - borderTopStyle: true, - borderTopColor: true - }, - font: { - fontStyle: true, - fontVariant: true, - fontWeight: true, - fontSize: true, - lineHeight: true, - fontFamily: true - }, - outline: { - outlineWidth: true, - outlineStyle: true, - outlineColor: true - } +var propTypes$4 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -var CSSProperty = { - isUnitlessNumber: isUnitlessNumber, - shorthandPropertyExpansions: shorthandPropertyExpansions +var defaultProps$4 = { + tag: 'a' }; -module.exports = CSSProperty; - -/***/ }), -/* 93 */ -/***/ (function(module, exports, __webpack_require__) { +var NavbarBrand = function NavbarBrand(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-brand'), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var DOMProperty = __webpack_require__(17); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstrumentation = __webpack_require__(13); +NavbarBrand.propTypes = propTypes$4; +NavbarBrand.defaultProps = defaultProps$4; -var quoteAttributeValueForBrowser = __webpack_require__(168); -var warning = __webpack_require__(2); +var propTypes$5 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; -var VALID_ATTRIBUTE_NAME_REGEX = new RegExp('^[' + DOMProperty.ATTRIBUTE_NAME_START_CHAR + '][' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); -var illegalAttributeNameCache = {}; -var validatedAttributeNameCache = {}; +var defaultProps$5 = { + tag: 'button', + type: 'button' +}; -function isAttributeNameSafe(attributeName) { - if (validatedAttributeNameCache.hasOwnProperty(attributeName)) { - return true; - } - if (illegalAttributeNameCache.hasOwnProperty(attributeName)) { - return false; - } - if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) { - validatedAttributeNameCache[attributeName] = true; - return true; - } - illegalAttributeNameCache[attributeName] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid attribute name: `%s`', attributeName) : void 0; - return false; -} +var navbarToggleIcon = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('span', { className: 'navbar-toggler-icon' }); -function shouldIgnoreValue(propertyInfo, value) { - return value == null || propertyInfo.hasBooleanValue && !value || propertyInfo.hasNumericValue && isNaN(value) || propertyInfo.hasPositiveNumericValue && value < 1 || propertyInfo.hasOverloadedBooleanValue && value === false; -} +var NavbarToggler = function NavbarToggler(props) { + var className = props.className, + cssModule = props.cssModule, + children = props.children, + right = props.right, + left = props.left, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'right', 'left', 'tag']); -/** - * Operations for dealing with DOM properties. - */ -var DOMPropertyOperations = { - /** - * Creates markup for the ID property. - * - * @param {string} id Unescaped ID. - * @return {string} Markup string. - */ - createMarkupForID: function (id) { - return DOMProperty.ID_ATTRIBUTE_NAME + '=' + quoteAttributeValueForBrowser(id); - }, - setAttributeForID: function (node, id) { - node.setAttribute(DOMProperty.ID_ATTRIBUTE_NAME, id); - }, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-toggler', right && 'navbar-toggler-right', left && 'navbar-toggler-left'), cssModule); - createMarkupForRoot: function () { - return DOMProperty.ROOT_ATTRIBUTE_NAME + '=""'; - }, - - setAttributeForRoot: function (node) { - node.setAttribute(DOMProperty.ROOT_ATTRIBUTE_NAME, ''); - }, - - /** - * Creates markup for a property. - * - * @param {string} name - * @param {*} value - * @return {?string} Markup string, or null if the property was invalid. - */ - createMarkupForProperty: function (name, value) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - if (shouldIgnoreValue(propertyInfo, value)) { - return ''; - } - var attributeName = propertyInfo.attributeName; - if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { - return attributeName + '=""'; - } - return attributeName + '=' + quoteAttributeValueForBrowser(value); - } else if (DOMProperty.isCustomAttribute(name)) { - if (value == null) { - return ''; - } - return name + '=' + quoteAttributeValueForBrowser(value); - } - return null; - }, - - /** - * Creates markup for a custom property. - * - * @param {string} name - * @param {*} value - * @return {string} Markup string, or empty string if the property was invalid. - */ - createMarkupForCustomAttribute: function (name, value) { - if (!isAttributeNameSafe(name) || value == null) { - return ''; - } - return name + '=' + quoteAttributeValueForBrowser(value); - }, - - /** - * Sets the value for a property on a node. - * - * @param {DOMElement} node - * @param {string} name - * @param {*} value - */ - setValueForProperty: function (node, name, value) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - var mutationMethod = propertyInfo.mutationMethod; - if (mutationMethod) { - mutationMethod(node, value); - } else if (shouldIgnoreValue(propertyInfo, value)) { - this.deleteValueForProperty(node, name); - return; - } else if (propertyInfo.mustUseProperty) { - // Contrary to `setAttribute`, object properties are properly - // `toString`ed by IE8/9. - node[propertyInfo.propertyName] = value; - } else { - var attributeName = propertyInfo.attributeName; - var namespace = propertyInfo.attributeNamespace; - // `setAttribute` with objects becomes only `[object]` in IE8/9, - // ('' + value) makes it output the correct toString()-value. - if (namespace) { - node.setAttributeNS(namespace, attributeName, '' + value); - } else if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { - node.setAttribute(attributeName, ''); - } else { - node.setAttribute(attributeName, '' + value); - } - } - } else if (DOMProperty.isCustomAttribute(name)) { - DOMPropertyOperations.setValueForAttribute(node, name, value); - return; - } - - if (process.env.NODE_ENV !== 'production') { - var payload = {}; - payload[name] = value; - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'update attribute', - payload: payload - }); - } - }, - - setValueForAttribute: function (node, name, value) { - if (!isAttributeNameSafe(name)) { - return; - } - if (value == null) { - node.removeAttribute(name); - } else { - node.setAttribute(name, '' + value); - } - - if (process.env.NODE_ENV !== 'production') { - var payload = {}; - payload[name] = value; - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'update attribute', - payload: payload - }); - } - }, + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { className: classes }), + children || navbarToggleIcon + ); +}; - /** - * Deletes an attributes from a node. - * - * @param {DOMElement} node - * @param {string} name - */ - deleteValueForAttribute: function (node, name) { - node.removeAttribute(name); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'remove attribute', - payload: name - }); - } - }, +NavbarToggler.propTypes = propTypes$5; +NavbarToggler.defaultProps = defaultProps$5; - /** - * Deletes the value for a property on a node. - * - * @param {DOMElement} node - * @param {string} name - */ - deleteValueForProperty: function (node, name) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - var mutationMethod = propertyInfo.mutationMethod; - if (mutationMethod) { - mutationMethod(node, undefined); - } else if (propertyInfo.mustUseProperty) { - var propName = propertyInfo.propertyName; - if (propertyInfo.hasBooleanValue) { - node[propName] = false; - } else { - node[propName] = ''; - } - } else { - node.removeAttribute(propertyInfo.attributeName); - } - } else if (DOMProperty.isCustomAttribute(name)) { - node.removeAttribute(name); - } +var propTypes$6 = { + tabs: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + pills: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'remove attribute', - payload: name - }); - } - } +var defaultProps$6 = { + tag: 'ul' }; -module.exports = DOMPropertyOperations; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var Nav = function Nav(props) { + var className = props.className, + cssModule = props.cssModule, + tabs = props.tabs, + pills = props.pills, + vertical = props.vertical, + navbar = props.navbar, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabs', 'pills', 'vertical', 'navbar', 'tag']); -/***/ }), -/* 94 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, navbar ? 'navbar-nav' : 'nav', { + 'nav-tabs': tabs, + 'nav-pills': pills, + 'flex-column': vertical + }), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +Nav.propTypes = propTypes$6; +Nav.defaultProps = defaultProps$6; -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; +var propTypes$7 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -module.exports = ReactPropTypesSecret; +var defaultProps$7 = { + tag: 'li' +}; -/***/ }), -/* 95 */ -/***/ (function(module, exports, __webpack_require__) { +var NavItem = function NavItem(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var _assign = __webpack_require__(5); +NavItem.propTypes = propTypes$7; +NavItem.defaultProps = defaultProps$7; -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); +var propTypes$10 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + arrow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object.isRequired, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + style: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var warning = __webpack_require__(2); +var defaultProps$10 = { + isOpen: false, + tetherRef: function tetherRef() {} +}; -var didWarnValueLink = false; -var didWarnValueDefaultValue = false; +var TetherContent = function (_React$Component) { + inherits(TetherContent, _React$Component); -function updateOptionsIfPendingUpdateAndMounted() { - if (this._rootNodeID && this._wrapperState.pendingUpdate) { - this._wrapperState.pendingUpdate = false; + function TetherContent(props) { + classCallCheck(this, TetherContent); - var props = this._currentElement.props; - var value = LinkedValueUtils.getValue(props); + var _this = possibleConstructorReturn(this, (TetherContent.__proto__ || Object.getPrototypeOf(TetherContent)).call(this, props)); - if (value != null) { - updateOptions(this, Boolean(props.multiple), value); - } + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.toggle = _this.toggle.bind(_this); + return _this; } -} -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; + createClass(TetherContent, [{ + key: 'componentDidMount', + value: function componentDidMount() { + this.handleProps(); } - } - return ''; -} - -var valuePropNames = ['value', 'defaultValue']; - -/** - * Validation function for `value` and `defaultValue`. - * @private - */ -function checkSelectPropTypes(inst, props) { - var owner = inst._currentElement._owner; - LinkedValueUtils.checkPropTypes('select', props, owner); - - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `select` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } - - for (var i = 0; i < valuePropNames.length; i++) { - var propName = valuePropNames[i]; - if (props[propName] == null) { - continue; + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + this.handleProps(); + } else if (this._element) { + // rerender + this.renderIntoSubtree(); + } } - var isArray = Array.isArray(props[propName]); - if (props.multiple && !isArray) { - process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be an array if ' + '`multiple` is true.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; - } else if (!props.multiple && isArray) { - process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be a scalar ' + 'value if `multiple` is false.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.hide(); } - } -} + }, { + key: 'getTarget', + value: function getTarget() { + var target = this.props.tether.target; -/** - * @param {ReactDOMComponent} inst - * @param {boolean} multiple - * @param {*} propValue A stringable (with `multiple`, a list of stringables). - * @private - */ -function updateOptions(inst, multiple, propValue) { - var selectedValue, i; - var options = ReactDOMComponentTree.getNodeFromInstance(inst).options; + if (__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default()(target)) { + return target(); + } - if (multiple) { - selectedValue = {}; - for (i = 0; i < propValue.length; i++) { - selectedValue['' + propValue[i]] = true; + return target; } - for (i = 0; i < options.length; i++) { - var selected = selectedValue.hasOwnProperty(options[i].value); - if (options[i].selected !== selected) { - options[i].selected = selected; - } + }, { + key: 'getTetherConfig', + value: function getTetherConfig() { + var config = _extends({}, this.props.tether); + + config.element = this._element; + config.target = this.getTarget(); + return config; } - } else { - // Do not set `select.value` as exact behavior isn't consistent across all - // browsers for all cases. - selectedValue = '' + propValue; - for (i = 0; i < options.length; i++) { - if (options[i].value === selectedValue) { - options[i].selected = true; - return; + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + var container = this._element; + if (e.target === container || !container.contains(e.target)) { + this.toggle(); } } - if (options.length) { - options[0].selected = true; + }, { + key: 'handleProps', + value: function handleProps() { + if (this.props.isOpen) { + this.show(); + } else { + this.hide(); + } } - } -} + }, { + key: 'hide', + value: function hide() { + document.removeEventListener('click', this.handleDocumentClick, true); -/** - * Implements a <select> host component that allows optionally setting the - * props `value` and `defaultValue`. If `multiple` is false, the prop must be a - * stringable. If `multiple` is true, the prop must be an array of stringables. - * - * If `value` is not supplied (or null/undefined), user actions that change the - * selected option will trigger updates to the rendered options. - * - * If it is supplied (and not null/undefined), the rendered options will not - * update in response to user actions. Instead, the `value` prop must change in - * order for the rendered options to update. - * - * If `defaultValue` is provided, any options with the supplied values will be - * selected. - */ -var ReactDOMSelect = { - getHostProps: function (inst, props) { - return _assign({}, props, { - onChange: inst._wrapperState.onChange, - value: undefined - }); - }, + if (this._element) { + document.body.removeChild(this._element); + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); + this._element = null; + } - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - checkSelectPropTypes(inst, props); + if (this._tether) { + this._tether.destroy(); + this._tether = null; + this.props.tetherRef(this._tether); + } } + }, { + key: 'show', + value: function show() { + document.addEventListener('click', this.handleDocumentClick, true); - var value = LinkedValueUtils.getValue(props); - inst._wrapperState = { - pendingUpdate: false, - initialValue: value != null ? value : props.defaultValue, - listeners: null, - onChange: _handleChange.bind(inst), - wasMultiple: Boolean(props.multiple) - }; - - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Select elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; - didWarnValueDefaultValue = true; + this._element = document.createElement('div'); + this._element.className = this.props.className; + document.body.appendChild(this._element); + this.renderIntoSubtree(); + this._tether = new __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default.a(this.getTetherConfig()); + this.props.tetherRef(this._tether); + this._tether.position(); + this._element.childNodes[0].focus(); } - }, + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } - getSelectValueContext: function (inst) { - // ReactDOMOption looks at this initial value so the initial generated - // markup has correct `selected` attributes - return inst._wrapperState.initialValue; - }, + return this.props.toggle(); + } + }, { + key: 'renderIntoSubtree', + value: function renderIntoSubtree() { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _props = this.props, + children = _props.children, + style = _props.style; - postUpdateWrapper: function (inst) { - var props = inst._currentElement.props; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(children, { style: style }); + } + }, { + key: 'render', + value: function render() { + return null; + } + }]); + return TetherContent; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - // After the initial mount, we control selected-ness manually so don't pass - // this value down - inst._wrapperState.initialValue = undefined; +TetherContent.propTypes = propTypes$10; +TetherContent.defaultProps = defaultProps$10; - var wasMultiple = inst._wrapperState.wasMultiple; - inst._wrapperState.wasMultiple = Boolean(props.multiple); +var propTypes$11 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - var value = LinkedValueUtils.getValue(props); - if (value != null) { - inst._wrapperState.pendingUpdate = false; - updateOptions(inst, Boolean(props.multiple), value); - } else if (wasMultiple !== Boolean(props.multiple)) { - // For simplicity, reapply `defaultValue` if `multiple` is toggled. - if (props.defaultValue != null) { - updateOptions(inst, Boolean(props.multiple), props.defaultValue); - } else { - // Revert the select back to its default unselected state. - updateOptions(inst, Boolean(props.multiple), props.multiple ? [] : ''); - } - } - } +var defaultProps$11 = { + tag: 'div' }; -function _handleChange(event) { - var props = this._currentElement.props; - var returnValue = LinkedValueUtils.executeOnChange(props, event); - - if (this._rootNodeID) { - this._wrapperState.pendingUpdate = true; - } - ReactUpdates.asap(updateOptionsIfPendingUpdateAndMounted, this); - return returnValue; -} +var contextTypes = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired +}; -module.exports = ReactDOMSelect; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var DropdownMenu = function DropdownMenu(props, context) { + var className = props.className, + cssModule = props.cssModule, + right = props.right, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'right', 'tag']); -/***/ }), -/* 96 */ -/***/ (function(module, exports, __webpack_require__) { + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'dropdown-menu', { 'dropdown-menu-right': right }), cssModule); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { tabIndex: '-1', 'aria-hidden': !context.isOpen, role: 'menu', className: classes })); +}; +DropdownMenu.propTypes = propTypes$11; +DropdownMenu.defaultProps = defaultProps$11; +DropdownMenu.contextTypes = contextTypes; +/* eslint react/no-find-dom-node: 0 */ +// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-find-dom-node.md -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +var propTypes$9 = { + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + dropup: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + group: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool]), + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var ReactCompositeComponent = __webpack_require__(176); -var ReactEmptyComponent = __webpack_require__(98); -var ReactHostComponent = __webpack_require__(99); +var defaultProps$9 = { + isOpen: false, + tag: 'div' +}; -var getNextDebugID = __webpack_require__(179); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +var childContextTypes = { + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired +}; -// To avoid a cyclic dependency, we create the final class in this module -var ReactCompositeComponentWrapper = function (element) { - this.construct(element); +var defaultTetherConfig = { + classPrefix: 'bs-tether', + classes: { element: 'dropdown', enabled: 'show' }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] }; -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; -} +var Dropdown = function (_React$Component) { + inherits(Dropdown, _React$Component); -/** - * Check if the type reference is a known internal type. I.e. not a user - * provided composite type. - * - * @param {function} type - * @return {boolean} Returns true if this is a valid internal type. - */ -function isInternalComponentType(type) { - return typeof type === 'function' && typeof type.prototype !== 'undefined' && typeof type.prototype.mountComponent === 'function' && typeof type.prototype.receiveComponent === 'function'; -} + function Dropdown(props) { + classCallCheck(this, Dropdown); -/** - * Given a ReactNode, create an instance that will actually be mounted. - * - * @param {ReactNode} node - * @param {boolean} shouldHaveDebugID - * @return {object} A new instance of the element's constructor. - * @protected - */ -function instantiateReactComponent(node, shouldHaveDebugID) { - var instance; + var _this = possibleConstructorReturn(this, (Dropdown.__proto__ || Object.getPrototypeOf(Dropdown)).call(this, props)); - if (node === null || node === false) { - instance = ReactEmptyComponent.create(instantiateReactComponent); - } else if (typeof node === 'object') { - var element = node; - var type = element.type; - if (typeof type !== 'function' && typeof type !== 'string') { - var info = ''; - if (process.env.NODE_ENV !== 'production') { - if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { - info += ' You likely forgot to export your component from the file ' + "it's defined in."; - } + _this.addEvents = _this.addEvents.bind(_this); + _this.getTetherConfig = _this.getTetherConfig.bind(_this); + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.removeEvents = _this.removeEvents.bind(_this); + _this.toggle = _this.toggle.bind(_this); + return _this; + } + + createClass(Dropdown, [{ + key: 'getChildContext', + value: function getChildContext() { + return { + toggle: this.props.toggle, + isOpen: this.props.isOpen + }; + } + }, { + key: 'componentDidMount', + value: function componentDidMount() { + this.handleProps(); + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + this.handleProps(); } - info += getDeclarationErrorAddendum(element._owner); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s', type == null ? type : typeof type, info) : _prodInvariant('130', type == null ? type : typeof type, info) : void 0; } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.removeEvents(); + } + }, { + key: 'getTetherTarget', + value: function getTetherTarget() { + var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); - // Special case string values - if (typeof element.type === 'string') { - instance = ReactHostComponent.createInternalComponent(element); - } else if (isInternalComponentType(element.type)) { - // This is temporarily available for custom components that are not string - // representations. I.e. ART. Once those are updated to use the string - // representation, we can drop this code path. - instance = new element.type(element); - - // We renamed this. Allow the old name for compat. :( - if (!instance.getHostNode) { - instance.getHostNode = instance.getNativeNode; - } - } else { - instance = new ReactCompositeComponentWrapper(element); + return container.querySelector('[data-toggle="dropdown"]'); } - } else if (typeof node === 'string' || typeof node === 'number') { - instance = ReactHostComponent.createInstanceForText(node); - } else { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Encountered invalid React node of type %s', typeof node) : _prodInvariant('131', typeof node) : void 0; - } + }, { + key: 'getTetherConfig', + value: function getTetherConfig(childProps) { + var _this2 = this; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(typeof instance.mountComponent === 'function' && typeof instance.receiveComponent === 'function' && typeof instance.getHostNode === 'function' && typeof instance.unmountComponent === 'function', 'Only React Components can be mounted.') : void 0; - } + var target = function target() { + return _this2.getTetherTarget(); + }; + var vElementAttach = 'top'; + var hElementAttach = 'left'; + var vTargetAttach = 'bottom'; + var hTargetAttach = 'left'; - // These two fields are used by the DOM and ART diffing algorithms - // respectively. Instead of using expandos on components, we should be - // storing the state needed by the diffing algorithms elsewhere. - instance._mountIndex = 0; - instance._mountImage = null; + if (childProps.right) { + hElementAttach = 'right'; + hTargetAttach = 'right'; + } - if (process.env.NODE_ENV !== 'production') { - instance._debugID = shouldHaveDebugID ? getNextDebugID() : 0; - } + if (this.props.dropup) { + vElementAttach = 'bottom'; + vTargetAttach = 'top'; + } - // Internal instances should fully constructed at this point, so they should - // not get any new fields added to them at this point. - if (process.env.NODE_ENV !== 'production') { - if (Object.preventExtensions) { - Object.preventExtensions(instance); + return _extends({}, defaultTetherConfig, { + attachment: vElementAttach + ' ' + hElementAttach, + targetAttachment: vTargetAttach + ' ' + hTargetAttach, + target: target + }, this.props.tether); } - } - - return instance; -} + }, { + key: 'addEvents', + value: function addEvents() { + document.addEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'removeEvents', + value: function removeEvents() { + document.removeEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); -_assign(ReactCompositeComponentWrapper.prototype, ReactCompositeComponent, { - _instantiateReactComponent: instantiateReactComponent -}); + if (container.contains(e.target) && container !== e.target) { + return; + } -module.exports = instantiateReactComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + this.toggle(); + } + }, { + key: 'handleProps', + value: function handleProps() { + if (this.props.tether) { + return; + } -/***/ }), -/* 97 */ -/***/ (function(module, exports, __webpack_require__) { + if (this.props.isOpen) { + this.addEvents(); + } else { + this.removeEvents(); + } + } + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + return this.props.toggle(); + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _this3 = this; + var _props = this.props, + tether = _props.tether, + children = _props.children, + attrs = objectWithoutProperties(_props, ['tether', 'children']); + attrs.toggle = this.toggle; -var _prodInvariant = __webpack_require__(3); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.map(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children), function (child) { + if (tether && child.type === DropdownMenu) { + var tetherConfig = _this3.getTetherConfig(child.props); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + _extends({}, attrs, { tether: tetherConfig }), + child + ); + } -var React = __webpack_require__(24); + return child; + }); + } + }, { + key: 'render', + value: function render() { + var _classNames; -var invariant = __webpack_require__(1); + var _omit = omit(this.props, ['toggle', 'tether']), + className = _omit.className, + cssModule = _omit.cssModule, + dropup = _omit.dropup, + group = _omit.group, + size = _omit.size, + Tag = _omit.tag, + isOpen = _omit.isOpen, + attributes = objectWithoutProperties(_omit, ['className', 'cssModule', 'dropup', 'group', 'size', 'tag', 'isOpen']); -var ReactNodeTypes = { - HOST: 0, - COMPOSITE: 1, - EMPTY: 2, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, (_classNames = { + 'btn-group': group + }, defineProperty(_classNames, 'btn-group-' + size, !!size), defineProperty(_classNames, 'dropdown', !group), defineProperty(_classNames, 'show', isOpen), defineProperty(_classNames, 'dropup', dropup), _classNames)), cssModule); - getType: function (node) { - if (node === null || node === false) { - return ReactNodeTypes.EMPTY; - } else if (React.isValidElement(node)) { - if (typeof node.type === 'function') { - return ReactNodeTypes.COMPOSITE; - } else { - return ReactNodeTypes.HOST; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { + className: classes + }), + this.renderChildren() + ); } - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unexpected node: %s', node) : _prodInvariant('26', node) : void 0; - } + }]); + return Dropdown; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Dropdown.propTypes = propTypes$9; +Dropdown.defaultProps = defaultProps$9; +Dropdown.childContextTypes = childContextTypes; + +var propTypes$8 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -module.exports = ReactNodeTypes; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var defaultProps$8 = { + tag: 'li' +}; -/***/ }), -/* 98 */ -/***/ (function(module, exports, __webpack_require__) { +var NavDropdown = function NavDropdown(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -"use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({}, attributes, { tag: Tag, className: classes })); +}; -var emptyComponentFactory; +NavDropdown.propTypes = propTypes$8; +NavDropdown.defaultProps = defaultProps$8; -var ReactEmptyComponentInjection = { - injectEmptyComponentFactory: function (factory) { - emptyComponentFactory = factory; - } +var propTypes$12 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + href: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any }; -var ReactEmptyComponent = { - create: function (instantiate) { - return emptyComponentFactory(instantiate); - } +var defaultProps$12 = { + tag: 'a' }; -ReactEmptyComponent.injection = ReactEmptyComponentInjection; +var NavLink = function (_React$Component) { + inherits(NavLink, _React$Component); -module.exports = ReactEmptyComponent; + function NavLink(props) { + classCallCheck(this, NavLink); -/***/ }), -/* 99 */ -/***/ (function(module, exports, __webpack_require__) { + var _this = possibleConstructorReturn(this, (NavLink.__proto__ || Object.getPrototypeOf(NavLink)).call(this, props)); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + _this.onClick = _this.onClick.bind(_this); + return _this; + } + createClass(NavLink, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } + if (this.props.href === '#') { + e.preventDefault(); + } -var _prodInvariant = __webpack_require__(3); + if (this.props.onClick) { + this.props.onClick(e); + } + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + active = _props.active, + Tag = _props.tag, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'active', 'tag', 'getRef']); -var invariant = __webpack_require__(1); -var genericComponentClass = null; -var textComponentClass = null; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-link', { + disabled: attributes.disabled, + active: active + }), cssModule); -var ReactHostComponentInjection = { - // This accepts a class that receives the tag string. This is a catch all - // that can render any kind of tag. - injectGenericComponentClass: function (componentClass) { - genericComponentClass = componentClass; - }, - // This accepts a text component class that takes the text string to be - // rendered as props. - injectTextComponentClass: function (componentClass) { - textComponentClass = componentClass; - } -}; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, onClick: this.onClick, className: classes })); + } + }]); + return NavLink; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -/** - * Get a host internal component class for a specific tag. - * - * @param {ReactElement} element The element to create. - * @return {function} The internal class constructor function. - */ -function createInternalComponent(element) { - !genericComponentClass ? process.env.NODE_ENV !== 'production' ? invariant(false, 'There is no registered component for the tag %s', element.type) : _prodInvariant('111', element.type) : void 0; - return new genericComponentClass(element); -} +NavLink.propTypes = propTypes$12; +NavLink.defaultProps = defaultProps$12; -/** - * @param {ReactText} text - * @return {ReactComponent} - */ -function createInstanceForText(text) { - return new textComponentClass(text); -} +var propTypes$13 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -/** - * @param {ReactComponent} component - * @return {boolean} - */ -function isTextComponent(component) { - return component instanceof textComponentClass; -} - -var ReactHostComponent = { - createInternalComponent: createInternalComponent, - createInstanceForText: createInstanceForText, - isTextComponent: isTextComponent, - injection: ReactHostComponentInjection +var defaultProps$13 = { + tag: 'ol' }; -module.exports = ReactHostComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var Breadcrumb = function Breadcrumb(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -/***/ }), -/* 100 */ -/***/ (function(module, exports, __webpack_require__) { + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'breadcrumb'), cssModule); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +Breadcrumb.propTypes = propTypes$13; +Breadcrumb.defaultProps = defaultProps$13; +var propTypes$14 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var _prodInvariant = __webpack_require__(3); +var defaultProps$14 = { + tag: 'li' +}; -var ReactCurrentOwner = __webpack_require__(14); -var REACT_ELEMENT_TYPE = __webpack_require__(180); +var BreadcrumbItem = function BreadcrumbItem(props) { + var className = props.className, + cssModule = props.cssModule, + active = props.active, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'active', 'tag']); -var getIteratorFn = __webpack_require__(181); -var invariant = __webpack_require__(1); -var KeyEscapeUtils = __webpack_require__(62); -var warning = __webpack_require__(2); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, 'breadcrumb-item'), cssModule); -var SEPARATOR = '.'; -var SUBSEPARATOR = ':'; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -/** - * This is inlined from ReactElement since this file is shared between - * isomorphic and renderers. We could extract this to a - * - */ +BreadcrumbItem.propTypes = propTypes$14; +BreadcrumbItem.defaultProps = defaultProps$14; -/** - * TODO: Test that a single child and an array with one item have the same key - * pattern. - */ +var propTypes$15 = { + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var didWarnAboutMaps = false; +var defaultProps$15 = { + color: 'secondary', + tag: 'button' +}; -/** - * Generate a key string that identifies a component within a set. - * - * @param {*} component A component that could contain a manual key. - * @param {number} index Index that is used if a manual key is not provided. - * @return {string} - */ -function getComponentKey(component, index) { - // Do some typechecking here since we call this blindly. We want to ensure - // that we don't block potential future ES APIs. - if (component && typeof component === 'object' && component.key != null) { - // Explicit key - return KeyEscapeUtils.escape(component.key); - } - // Implicit key determined by the index in the set - return index.toString(36); -} +var Button = function (_React$Component) { + inherits(Button, _React$Component); -/** - * @param {?*} children Children tree container. - * @param {!string} nameSoFar Name of the key path so far. - * @param {!function} callback Callback to invoke with each child found. - * @param {?*} traverseContext Used to pass information throughout the traversal - * process. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { - var type = typeof children; + function Button(props) { + classCallCheck(this, Button); - if (type === 'undefined' || type === 'boolean') { - // All of the above are perceived as null. - children = null; - } + var _this = possibleConstructorReturn(this, (Button.__proto__ || Object.getPrototypeOf(Button)).call(this, props)); - if (children === null || type === 'string' || type === 'number' || - // The following is inlined from ReactElement. This means we can optimize - // some checks. React Fiber also inlines this logic for similar purposes. - type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { - callback(traverseContext, children, - // If it's the only child, treat the name as if it was wrapped in an array - // so that it's consistent if the number of children grows. - nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); - return 1; + _this.onClick = _this.onClick.bind(_this); + return _this; } - var child; - var nextName; - var subtreeCount = 0; // Count of children found in the current subtree. - var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; + createClass(Button, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } - if (Array.isArray(children)) { - for (var i = 0; i < children.length; i++) { - child = children[i]; - nextName = nextNamePrefix + getComponentKey(child, i); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - var iteratorFn = getIteratorFn(children); - if (iteratorFn) { - var iterator = iteratorFn.call(children); - var step; - if (iteratorFn !== children.entries) { - var ii = 0; - while (!(step = iterator.next()).done) { - child = step.value; - nextName = nextNamePrefix + getComponentKey(child, ii++); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - if (process.env.NODE_ENV !== 'production') { - var mapsAsChildrenAddendum = ''; - if (ReactCurrentOwner.current) { - var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); - if (mapsAsChildrenOwnerName) { - mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; - } - } - process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; - didWarnAboutMaps = true; - } - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - child = entry[1]; - nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } + if (this.props.onClick) { + this.props.onClick(e); } - } else if (type === 'object') { - var addendum = ''; - if (process.env.NODE_ENV !== 'production') { - addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; - if (children._isReactElement) { - addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; - } - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - addendum += ' Check the render method of `' + name + '`.'; - } - } + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + active = _props.active, + block = _props.block, + className = _props.className, + cssModule = _props.cssModule, + color = _props.color, + outline = _props.outline, + size = _props.size, + Tag = _props.tag, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['active', 'block', 'className', 'cssModule', 'color', 'outline', 'size', 'tag', 'getRef']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn', 'btn' + (outline ? '-outline' : '') + '-' + color, size ? 'btn-' + size : false, block ? 'btn-block' : false, { active: active, disabled: this.props.disabled }), cssModule); + + if (attributes.href && Tag === 'button') { + Tag = 'a'; } - var childrenString = String(children); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ + type: Tag === 'button' && attributes.onClick ? 'button' : undefined + }, attributes, { + className: classes, + ref: getRef, + onClick: this.onClick + })); } - } + }]); + return Button; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - return subtreeCount; -} +Button.propTypes = propTypes$15; +Button.defaultProps = defaultProps$15; -/** - * Traverses children that are typically specified as `props.children`, but - * might also be specified through attributes: - * - * - `traverseAllChildren(this.props.children, ...)` - * - `traverseAllChildren(this.props.leftPanelChildren, ...)` - * - * The `traverseContext` is an optional argument that is passed through the - * entire traversal. It can be used to store accumulations or anything else that - * the callback might find relevant. - * - * @param {?*} children Children tree object. - * @param {!function} callback To invoke upon traversing each child. - * @param {?*} traverseContext Context for traversal. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildren(children, callback, traverseContext) { - if (children == null) { - return 0; - } +var propTypes$16 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node +}; - return traverseAllChildrenImpl(children, '', callback, traverseContext); -} +var ButtonDropdown = function ButtonDropdown(props) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({ group: true }, props)); +}; -module.exports = traverseAllChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +ButtonDropdown.propTypes = propTypes$16; -/***/ }), -/* 101 */ -/***/ (function(module, exports, __webpack_require__) { +var propTypes$17 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +var defaultProps$16 = { + tag: 'div', + role: 'group' +}; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * @typechecks - */ +var ButtonGroup = function ButtonGroup(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + vertical = props.vertical, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'vertical', 'tag']); -var emptyFunction = __webpack_require__(12); -/** - * Upstream version of event listener. Does not take into account specific - * nature of platform. - */ -var EventListener = { - /** - * Listen to DOM events during the bubble phase. - * - * @param {DOMEventTarget} target DOM element to register listener on. - * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. - * @param {function} callback Callback function. - * @return {object} Object with a `remove` method. - */ - listen: function listen(target, eventType, callback) { - if (target.addEventListener) { - target.addEventListener(eventType, callback, false); - return { - remove: function remove() { - target.removeEventListener(eventType, callback, false); - } - }; - } else if (target.attachEvent) { - target.attachEvent('on' + eventType, callback); - return { - remove: function remove() { - target.detachEvent('on' + eventType, callback); - } - }; - } - }, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, size ? 'btn-group-' + size : false, vertical ? 'btn-group-vertical' : 'btn-group'), cssModule); - /** - * Listen to DOM events during the capture phase. - * - * @param {DOMEventTarget} target DOM element to register listener on. - * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. - * @param {function} callback Callback function. - * @return {object} Object with a `remove` method. - */ - capture: function capture(target, eventType, callback) { - if (target.addEventListener) { - target.addEventListener(eventType, callback, true); - return { - remove: function remove() { - target.removeEventListener(eventType, callback, true); - } - }; - } else { - if (process.env.NODE_ENV !== 'production') { - console.error('Attempted to listen to events during the capture phase on a ' + 'browser that does not support the capture phase. Your application ' + 'will not receive some events.'); - } - return { - remove: emptyFunction - }; - } - }, + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - registerDefault: function registerDefault() {} +ButtonGroup.propTypes = propTypes$17; +ButtonGroup.defaultProps = defaultProps$16; + +var propTypes$18 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string }; -module.exports = EventListener; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var defaultProps$17 = { + tag: 'div', + role: 'toolbar' +}; -/***/ }), -/* 102 */ -/***/ (function(module, exports, __webpack_require__) { +var ButtonToolbar = function ButtonToolbar(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn-toolbar'), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var ReactDOMSelection = __webpack_require__(193); +ButtonToolbar.propTypes = propTypes$18; +ButtonToolbar.defaultProps = defaultProps$17; -var containsNode = __webpack_require__(195); -var focusNode = __webpack_require__(91); -var getActiveElement = __webpack_require__(103); +var propTypes$19 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + divider: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + header: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; -function isInDocument(node) { - return containsNode(document.documentElement, node); -} +var contextTypes$1 = { + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; -/** - * @ReactInputSelection: React input selection module. Based on Selection.js, - * but modified to be suitable for react and has a couple of bug fixes (doesn't - * assume buttons have range selections allowed). - * Input selection module for React. - */ -var ReactInputSelection = { - hasSelectionCapabilities: function (elem) { - var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); - return nodeName && (nodeName === 'input' && elem.type === 'text' || nodeName === 'textarea' || elem.contentEditable === 'true'); - }, +var defaultProps$18 = { + tag: 'button', + toggle: true +}; - getSelectionInformation: function () { - var focusedElem = getActiveElement(); - return { - focusedElem: focusedElem, - selectionRange: ReactInputSelection.hasSelectionCapabilities(focusedElem) ? ReactInputSelection.getSelection(focusedElem) : null - }; - }, +var DropdownItem = function (_React$Component) { + inherits(DropdownItem, _React$Component); - /** - * @restoreSelection: If any selection information was potentially lost, - * restore it. This is useful when performing operations that could remove dom - * nodes and place them back in, resulting in focus being lost. - */ - restoreSelection: function (priorSelectionInformation) { - var curFocusedElem = getActiveElement(); - var priorFocusedElem = priorSelectionInformation.focusedElem; - var priorSelectionRange = priorSelectionInformation.selectionRange; - if (curFocusedElem !== priorFocusedElem && isInDocument(priorFocusedElem)) { - if (ReactInputSelection.hasSelectionCapabilities(priorFocusedElem)) { - ReactInputSelection.setSelection(priorFocusedElem, priorSelectionRange); - } - focusNode(priorFocusedElem); - } - }, + function DropdownItem(props) { + classCallCheck(this, DropdownItem); - /** - * @getSelection: Gets the selection bounds of a focused textarea, input or - * contentEditable node. - * -@input: Look up selection bounds of this input - * -@return {start: selectionStart, end: selectionEnd} - */ - getSelection: function (input) { - var selection; + var _this = possibleConstructorReturn(this, (DropdownItem.__proto__ || Object.getPrototypeOf(DropdownItem)).call(this, props)); - if ('selectionStart' in input) { - // Modern browser with input or textarea. - selection = { - start: input.selectionStart, - end: input.selectionEnd - }; - } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { - // IE8 input. - var range = document.selection.createRange(); - // There can only be one selection per document in IE, so it must - // be in our element. - if (range.parentElement() === input) { - selection = { - start: -range.moveStart('character', -input.value.length), - end: -range.moveEnd('character', -input.value.length) - }; + _this.onClick = _this.onClick.bind(_this); + _this.getTabIndex = _this.getTabIndex.bind(_this); + return _this; + } + + createClass(DropdownItem, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled || this.props.header || this.props.divider) { + e.preventDefault(); + return; } - } else { - // Content editable or old IE textarea. - selection = ReactDOMSelection.getOffsets(input); - } - return selection || { start: 0, end: 0 }; - }, + if (this.props.onClick) { + this.props.onClick(e); + } - /** - * @setSelection: Sets the selection bounds of a textarea or input and focuses - * the input. - * -@input Set selection bounds of this input or textarea - * -@offsets Object of same form that is returned from get* - */ - setSelection: function (input, offsets) { - var start = offsets.start; - var end = offsets.end; - if (end === undefined) { - end = start; + if (this.props.toggle) { + this.context.toggle(); + } } + }, { + key: 'getTabIndex', + value: function getTabIndex() { + if (this.props.disabled || this.props.header || this.props.divider) { + return '-1'; + } - if ('selectionStart' in input) { - input.selectionStart = start; - input.selectionEnd = Math.min(end, input.value.length); - } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { - var range = input.createTextRange(); - range.collapse(true); - range.moveStart('character', start); - range.moveEnd('character', end - start); - range.select(); - } else { - ReactDOMSelection.setOffsets(input, offsets); + return '0'; } - } -}; + }, { + key: 'render', + value: function render() { + var tabIndex = this.getTabIndex(); -module.exports = ReactInputSelection; + var _omit = omit(this.props, ['toggle']), + className = _omit.className, + cssModule = _omit.cssModule, + divider = _omit.divider, + Tag = _omit.tag, + header = _omit.header, + active = _omit.active, + props = objectWithoutProperties(_omit, ['className', 'cssModule', 'divider', 'tag', 'header', 'active']); -/***/ }), -/* 103 */ -/***/ (function(module, exports, __webpack_require__) { + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + disabled: props.disabled, + 'dropdown-item': !divider && !header, + active: active, + 'dropdown-header': header, + 'dropdown-divider': divider + }), cssModule); -"use strict"; + if (Tag === 'button') { + if (header) { + Tag = 'h6'; + } else if (divider) { + Tag = 'div'; + } else if (props.href) { + Tag = 'a'; + } + } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ + type: Tag === 'button' && (props.onClick || this.props.toggle) ? 'button' : undefined + }, props, { + tabIndex: tabIndex, + className: classes, + onClick: this.onClick + })); + } + }]); + return DropdownItem; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +DropdownItem.propTypes = propTypes$19; +DropdownItem.defaultProps = defaultProps$18; +DropdownItem.contextTypes = contextTypes$1; -/* eslint-disable fb-www/typeof-undefined */ +var propTypes$20 = { + caret: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + 'data-toggle': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + 'aria-haspopup': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + split: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + nav: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; -/** - * Same as document.activeElement but wraps in a try-catch block. In IE it is - * not safe to call document.activeElement if there is nothing focused. - * - * The activeElement will be null only if the document or document body is not - * yet defined. - * - * @param {?DOMDocument} doc Defaults to current document. - * @return {?DOMElement} - */ -function getActiveElement(doc) /*?DOMElement*/{ - doc = doc || (typeof document !== 'undefined' ? document : undefined); - if (typeof doc === 'undefined') { - return null; - } - try { - return doc.activeElement || doc.body; - } catch (e) { - return doc.body; - } -} +var defaultProps$19 = { + 'data-toggle': 'dropdown', + 'aria-haspopup': true, + color: 'secondary' +}; -module.exports = getActiveElement; +var contextTypes$2 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired +}; -/***/ }), -/* 104 */ -/***/ (function(module, exports, __webpack_require__) { +var DropdownToggle = function (_React$Component) { + inherits(DropdownToggle, _React$Component); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + function DropdownToggle(props) { + classCallCheck(this, DropdownToggle); + var _this = possibleConstructorReturn(this, (DropdownToggle.__proto__ || Object.getPrototypeOf(DropdownToggle)).call(this, props)); + _this.onClick = _this.onClick.bind(_this); + return _this; + } -var _prodInvariant = __webpack_require__(3); + createClass(DropdownToggle, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } -var DOMLazyTree = __webpack_require__(27); -var DOMProperty = __webpack_require__(17); -var React = __webpack_require__(24); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactCurrentOwner = __webpack_require__(14); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMContainerInfo = __webpack_require__(210); -var ReactDOMFeatureFlags = __webpack_require__(211); -var ReactFeatureFlags = __webpack_require__(86); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactMarkupChecksum = __webpack_require__(212); -var ReactReconciler = __webpack_require__(26); -var ReactUpdateQueue = __webpack_require__(63); -var ReactUpdates = __webpack_require__(15); + if (this.props.nav && !this.props.tag) { + e.preventDefault(); + } -var emptyObject = __webpack_require__(39); -var instantiateReactComponent = __webpack_require__(96); -var invariant = __webpack_require__(1); -var setInnerHTML = __webpack_require__(43); -var shouldUpdateReactComponent = __webpack_require__(61); -var warning = __webpack_require__(2); + if (this.props.onClick) { + this.props.onClick(e); + } -var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; -var ROOT_ATTR_NAME = DOMProperty.ROOT_ATTRIBUTE_NAME; + this.context.toggle(); + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + color = _props.color, + cssModule = _props.cssModule, + caret = _props.caret, + split = _props.split, + nav = _props.nav, + tag = _props.tag, + props = objectWithoutProperties(_props, ['className', 'color', 'cssModule', 'caret', 'split', 'nav', 'tag']); -var ELEMENT_NODE_TYPE = 1; -var DOC_NODE_TYPE = 9; -var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + var ariaLabel = props['aria-label'] || 'Toggle Dropdown'; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + 'dropdown-toggle': caret || split, + 'dropdown-toggle-split': split, + active: this.context.isOpen, + 'nav-link': nav + }), cssModule); + var children = props.children || __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { className: 'sr-only' }, + ariaLabel + ); -var instancesByReactRootID = {}; + var Tag = void 0; -/** - * Finds the index of the first character - * that's not common between the two given strings. - * - * @return {number} the index of the character where the strings diverge - */ -function firstDifferenceIndex(string1, string2) { - var minLen = Math.min(string1.length, string2.length); - for (var i = 0; i < minLen; i++) { - if (string1.charAt(i) !== string2.charAt(i)) { - return i; + if (nav && !tag) { + Tag = 'a'; + props.href = '#'; + } else if (!tag) { + Tag = Button; + props.color = color; + } else { + Tag = tag; + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, props, { + className: classes, + onClick: this.onClick, + 'aria-haspopup': 'true', + 'aria-expanded': this.context.isOpen, + children: children + })); } - } - return string1.length === string2.length ? -1 : minLen; -} + }]); + return DropdownToggle; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -/** - * @param {DOMElement|DOMDocument} container DOM element that may contain - * a React component - * @return {?*} DOM element that may have the reactRoot ID, or null. - */ -function getReactRootElementInContainer(container) { - if (!container) { - return null; - } +DropdownToggle.propTypes = propTypes$20; +DropdownToggle.defaultProps = defaultProps$19; +DropdownToggle.contextTypes = contextTypes$2; - if (container.nodeType === DOC_NODE_TYPE) { - return container.documentElement; - } else { - return container.firstChild; - } -} +var propTypes$21 = { + baseClass: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + baseClassIn: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionAppear: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + transitionEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + transitionLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; -function internalGetID(node) { - // If node is something like a window, document, or text node, none of - // which support attributes or a .getAttribute method, gracefully return - // the empty string, as if the attribute were missing. - return node.getAttribute && node.getAttribute(ATTR_NAME) || ''; -} +var defaultProps$20 = { + tag: 'div', + baseClass: 'fade', + baseClassIn: 'show', + transitionAppearTimeout: 0, + transitionEnterTimeout: 0, + transitionLeaveTimeout: 0, + transitionAppear: true, + transitionEnter: true, + transitionLeave: true +}; -/** - * Mounts this component and inserts it into the DOM. - * - * @param {ReactComponent} componentInstance The instance to mount. - * @param {DOMElement} container DOM element to mount into. - * @param {ReactReconcileTransaction} transaction - * @param {boolean} shouldReuseMarkup If true, do not insert markup - */ -function mountComponentIntoNode(wrapperInstance, container, transaction, shouldReuseMarkup, context) { - var markerName; - if (ReactFeatureFlags.logTopLevelRenders) { - var wrappedElement = wrapperInstance._currentElement.props.child; - var type = wrappedElement.type; - markerName = 'React mount: ' + (typeof type === 'string' ? type : type.displayName || type.name); - console.time(markerName); - } +var Fade = function (_React$Component) { + inherits(Fade, _React$Component); - var markup = ReactReconciler.mountComponent(wrapperInstance, transaction, null, ReactDOMContainerInfo(wrapperInstance, container), context, 0 /* parentDebugID */ - ); + function Fade(props) { + classCallCheck(this, Fade); - if (markerName) { - console.timeEnd(markerName); + var _this = possibleConstructorReturn(this, (Fade.__proto__ || Object.getPrototypeOf(Fade)).call(this, props)); + + _this.state = { + mounted: !props.transitionAppear + }; + + _this.onLeave = _this.onLeave.bind(_this); + _this.onEnter = _this.onEnter.bind(_this); + _this.timers = []; + return _this; } - wrapperInstance._renderedComponent._topLevelWrapper = wrapperInstance; - ReactMount._mountImageIntoNode(markup, container, wrapperInstance, shouldReuseMarkup, transaction); -} + createClass(Fade, [{ + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.timers.forEach(function (timer) { + return clearTimeout(timer); + }); + } + }, { + key: 'onEnter', + value: function onEnter(cb) { + var _this2 = this; -/** - * Batched mount. - * - * @param {ReactComponent} componentInstance The instance to mount. - * @param {DOMElement} container DOM element to mount into. - * @param {boolean} shouldReuseMarkup If true, do not insert markup - */ -function batchedMountComponentIntoNode(componentInstance, container, shouldReuseMarkup, context) { - var transaction = ReactUpdates.ReactReconcileTransaction.getPooled( - /* useCreateElement */ - !shouldReuseMarkup && ReactDOMFeatureFlags.useCreateElement); - transaction.perform(mountComponentIntoNode, null, componentInstance, container, transaction, shouldReuseMarkup, context); - ReactUpdates.ReactReconcileTransaction.release(transaction); -} + return function () { + cb(); + if (_this2.props.onEnter) { + _this2.props.onEnter(); + } + }; + } + }, { + key: 'onLeave', + value: function onLeave(cb) { + var _this3 = this; -/** - * Unmounts a component and removes it from the DOM. - * - * @param {ReactComponent} instance React component instance. - * @param {DOMElement} container DOM element to unmount from. - * @final - * @internal - * @see {ReactMount.unmountComponentAtNode} - */ -function unmountComponentFromNode(instance, container, safely) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onBeginFlush(); - } - ReactReconciler.unmountComponent(instance, safely); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onEndFlush(); - } + return function () { + cb(); + if (_this3.props.onLeave) { + _this3.props.onLeave(); + } + }; + } + }, { + key: 'componentWillAppear', + value: function componentWillAppear(cb) { + if (!this.props.transitionAppear) { + this.onEnter(cb)(); + } - if (container.nodeType === DOC_NODE_TYPE) { - container = container.documentElement; - } + this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionAppearTimeout)); + } + }, { + key: 'componentDidAppear', + value: function componentDidAppear() { + this.setState({ + mounted: true + }); + } + }, { + key: 'componentWillEnter', + value: function componentWillEnter(cb) { + if (!this.props.transitionEnter) { + this.onEnter(cb)(); + } - // http://jsperf.com/emptying-a-node - while (container.lastChild) { - container.removeChild(container.lastChild); - } -} + this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionEnterTimeout)); + } + }, { + key: 'componentDidEnter', + value: function componentDidEnter() { + this.setState({ + mounted: true + }); + } + }, { + key: 'componentWillLeave', + value: function componentWillLeave(cb) { + this.setState({ + mounted: false + }); -/** - * True if the supplied DOM node has a direct React-rendered child that is - * not a React root element. Useful for warning in `render`, - * `unmountComponentAtNode`, etc. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM element contains a direct child that was - * rendered by React but is not a root element. - * @internal - */ -function hasNonRootReactChild(container) { - var rootEl = getReactRootElementInContainer(container); - if (rootEl) { - var inst = ReactDOMComponentTree.getInstanceFromNode(rootEl); - return !!(inst && inst._hostParent); - } -} + if (!this.props.transitionLeave) { + this.onLeave(cb)(); + } -/** - * True if the supplied DOM node is a React DOM element and - * it has been rendered by another copy of React. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM has been rendered by another copy of React - * @internal - */ -function nodeIsRenderedByOtherInstance(container) { - var rootEl = getReactRootElementInContainer(container); - return !!(rootEl && isReactNode(rootEl) && !ReactDOMComponentTree.getInstanceFromNode(rootEl)); -} + this.timers.push(setTimeout(this.onLeave(cb), this.props.transitionLeaveTimeout)); + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + baseClass = _props.baseClass, + baseClassIn = _props.baseClassIn, + className = _props.className, + cssModule = _props.cssModule, + Tag = _props.tag; -/** - * True if the supplied DOM node is a valid node element. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM is a valid DOM node. - * @internal - */ -function isValidContainer(node) { - return !!(node && (node.nodeType === ELEMENT_NODE_TYPE || node.nodeType === DOC_NODE_TYPE || node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE)); -} + var attributes = omit(this.props, Object.keys(propTypes$21)); -/** - * True if the supplied DOM node is a valid React node element. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM is a valid React DOM node. - * @internal - */ -function isReactNode(node) { - return isValidContainer(node) && (node.hasAttribute(ROOT_ATTR_NAME) || node.hasAttribute(ATTR_NAME)); -} + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, baseClass, this.state.mounted ? baseClassIn : false), cssModule); -function getHostRootInstanceInContainer(container) { - var rootEl = getReactRootElementInContainer(container); - var prevHostInstance = rootEl && ReactDOMComponentTree.getInstanceFromNode(rootEl); - return prevHostInstance && !prevHostInstance._hostParent ? prevHostInstance : null; -} + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + } + }]); + return Fade; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -function getTopLevelWrapperInContainer(container) { - var root = getHostRootInstanceInContainer(container); - return root ? root._hostContainerInfo._topLevelWrapper : null; -} +Fade.propTypes = propTypes$21; +Fade.defaultProps = defaultProps$20; -/** - * Temporary (?) hack so that we can store all top-level pending updates on - * composites instead of having to worry about different types of components - * here. - */ -var topLevelRootCounter = 1; -var TopLevelWrapper = function () { - this.rootID = topLevelRootCounter++; -}; -TopLevelWrapper.prototype.isReactComponent = {}; -if (process.env.NODE_ENV !== 'production') { - TopLevelWrapper.displayName = 'TopLevelWrapper'; -} -TopLevelWrapper.prototype.render = function () { - return this.props.child; +var propTypes$22 = { + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + pill: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -TopLevelWrapper.isReactTopLevelWrapper = true; -/** - * Mounting is the process of initializing a React component by creating its - * representative DOM elements and inserting them into a supplied `container`. - * Any prior content inside `container` is destroyed in the process. - * - * ReactMount.render( - * component, - * document.getElementById('container') - * ); - * - * <div id="container"> <-- Supplied `container`. - * <div data-reactid=".3"> <-- Rendered reactRoot of React - * // ... component. - * </div> - * </div> - * - * Inside of `container`, the first element rendered is the "reactRoot". - */ -var ReactMount = { - TopLevelWrapper: TopLevelWrapper, +var defaultProps$21 = { + color: 'default', + pill: false, + tag: 'span' +}; - /** - * Used by devtools. The keys are not important. - */ - _instancesByReactRootID: instancesByReactRootID, +var Badge = function Badge(props) { + var className = props.className, + cssModule = props.cssModule, + color = props.color, + pill = props.pill, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'pill', 'tag']); - /** - * This is a hook provided to support rendering React components while - * ensuring that the apparent scroll position of its `container` does not - * change. - * - * @param {DOMElement} container The `container` being rendered into. - * @param {function} renderCallback This must be called once to do the render. - */ - scrollMonitor: function (container, renderCallback) { - renderCallback(); - }, - /** - * Take a component that's already mounted into the DOM and replace its props - * @param {ReactComponent} prevComponent component instance already in the DOM - * @param {ReactElement} nextElement component instance to render - * @param {DOMElement} container container to render into - * @param {?function} callback function triggered on completion - */ - _updateRootComponent: function (prevComponent, nextElement, nextContext, container, callback) { - ReactMount.scrollMonitor(container, function () { - ReactUpdateQueue.enqueueElementInternal(prevComponent, nextElement, nextContext); - if (callback) { - ReactUpdateQueue.enqueueCallbackInternal(prevComponent, callback); - } - }); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'badge', 'badge-' + color, pill ? 'badge-pill' : false), cssModule); - return prevComponent; - }, + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - /** - * Render a new component into the DOM. Hooked by hooks! - * - * @param {ReactElement} nextElement element to render - * @param {DOMElement} container container to render into - * @param {boolean} shouldReuseMarkup if we should skip the markup insertion - * @return {ReactComponent} nextComponent - */ - _renderNewRootComponent: function (nextElement, container, shouldReuseMarkup, context) { - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '_renderNewRootComponent(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from ' + 'render is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; +Badge.propTypes = propTypes$22; +Badge.defaultProps = defaultProps$21; - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, '_registerComponent(...): Target container is not a DOM element.') : _prodInvariant('37') : void 0; +var propTypes$23 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - ReactBrowserEventEmitter.ensureScrollValueMonitoring(); - var componentInstance = instantiateReactComponent(nextElement, false); +var defaultProps$22 = { + tag: 'div' +}; - // The initial render is synchronous but any updates that happen during - // rendering, in componentWillMount or componentDidMount, will be batched - // according to the current batching strategy. +var Card = function Card(props) { + var className = props.className, + cssModule = props.cssModule, + color = props.color, + block = props.block, + inverse = props.inverse, + outline = props.outline, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'block', 'inverse', 'outline', 'tag']); - ReactUpdates.batchedUpdates(batchedMountComponentIntoNode, componentInstance, container, shouldReuseMarkup, context); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card', inverse ? 'card-inverse' : false, block ? 'card-block' : false, color ? 'card' + (outline ? '-outline' : '') + '-' + color : false), cssModule); - var wrapperID = componentInstance._instance.rootID; - instancesByReactRootID[wrapperID] = componentInstance; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - return componentInstance; - }, +Card.propTypes = propTypes$23; +Card.defaultProps = defaultProps$22; - /** - * Renders a React component into the DOM in the supplied `container`. - * - * If the React component was previously rendered into `container`, this will - * perform an update on it and only mutate the DOM as necessary to reflect the - * latest React component. - * - * @param {ReactComponent} parentComponent The conceptual parent of this render tree. - * @param {ReactElement} nextElement Component element to render. - * @param {DOMElement} container DOM element to render into. - * @param {?function} callback function triggered on completion - * @return {ReactComponent} Component instance rendered in `container`. - */ - renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { - !(parentComponent != null && ReactInstanceMap.has(parentComponent)) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'parentComponent must be a valid React Component') : _prodInvariant('38') : void 0; - return ReactMount._renderSubtreeIntoContainer(parentComponent, nextElement, container, callback); - }, +var propTypes$24 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - _renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { - ReactUpdateQueue.validateCallback(callback, 'ReactDOM.render'); - !React.isValidElement(nextElement) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOM.render(): Invalid component element.%s', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : // Check if it quacks like an element - nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : _prodInvariant('39', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : void 0; +var defaultProps$23 = { + tag: 'div' +}; - process.env.NODE_ENV !== 'production' ? warning(!container || !container.tagName || container.tagName.toUpperCase() !== 'BODY', 'render(): Rendering components directly into document.body is ' + 'discouraged, since its children are often manipulated by third-party ' + 'scripts and browser extensions. This may lead to subtle ' + 'reconciliation issues. Try rendering into a container element created ' + 'for your app.') : void 0; +var CardGroup = function CardGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var nextWrappedElement = React.createElement(TopLevelWrapper, { - child: nextElement - }); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-group'), cssModule); - var nextContext; - if (parentComponent) { - var parentInst = ReactInstanceMap.get(parentComponent); - nextContext = parentInst._processChildContext(parentInst._context); - } else { - nextContext = emptyObject; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - var prevComponent = getTopLevelWrapperInContainer(container); +CardGroup.propTypes = propTypes$24; +CardGroup.defaultProps = defaultProps$23; - if (prevComponent) { - var prevWrappedElement = prevComponent._currentElement; - var prevElement = prevWrappedElement.props.child; - if (shouldUpdateReactComponent(prevElement, nextElement)) { - var publicInst = prevComponent._renderedComponent.getPublicInstance(); - var updatedCallback = callback && function () { - callback.call(publicInst); - }; - ReactMount._updateRootComponent(prevComponent, nextWrappedElement, nextContext, container, updatedCallback); - return publicInst; - } else { - ReactMount.unmountComponentAtNode(container); - } - } +var propTypes$25 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - var reactRootElement = getReactRootElementInContainer(container); - var containerHasReactMarkup = reactRootElement && !!internalGetID(reactRootElement); - var containerHasNonRootReactChild = hasNonRootReactChild(container); +var defaultProps$24 = { + tag: 'div' +}; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, 'render(...): Replacing React-rendered children with a new root ' + 'component. If you intended to update the children of this node, ' + 'you should instead have the existing children update their state ' + 'and render the new components instead of calling ReactDOM.render.') : void 0; +var CardDeck = function CardDeck(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - if (!containerHasReactMarkup || reactRootElement.nextSibling) { - var rootElementSibling = reactRootElement; - while (rootElementSibling) { - if (internalGetID(rootElementSibling)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'render(): Target node has markup rendered by React, but there ' + 'are unrelated nodes as well. This is most commonly caused by ' + 'white-space inserted around server-rendered markup.') : void 0; - break; - } - rootElementSibling = rootElementSibling.nextSibling; - } - } - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-deck'), cssModule); - var shouldReuseMarkup = containerHasReactMarkup && !prevComponent && !containerHasNonRootReactChild; - var component = ReactMount._renderNewRootComponent(nextWrappedElement, container, shouldReuseMarkup, nextContext)._renderedComponent.getPublicInstance(); - if (callback) { - callback.call(component); - } - return component; - }, + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - /** - * Renders a React component into the DOM in the supplied `container`. - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.render - * - * If the React component was previously rendered into `container`, this will - * perform an update on it and only mutate the DOM as necessary to reflect the - * latest React component. - * - * @param {ReactElement} nextElement Component element to render. - * @param {DOMElement} container DOM element to render into. - * @param {?function} callback function triggered on completion - * @return {ReactComponent} Component instance rendered in `container`. - */ - render: function (nextElement, container, callback) { - return ReactMount._renderSubtreeIntoContainer(null, nextElement, container, callback); - }, +CardDeck.propTypes = propTypes$25; +CardDeck.defaultProps = defaultProps$24; - /** - * Unmounts and destroys the React component rendered in the `container`. - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.unmountcomponentatnode - * - * @param {DOMElement} container DOM element containing a React component. - * @return {boolean} True if a component was found in and unmounted from - * `container` - */ - unmountComponentAtNode: function (container) { - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. (Strictly speaking, unmounting won't cause a - // render but we still don't expect to be in a render call here.) - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, 'unmountComponentAtNode(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from render ' + 'is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; +var propTypes$26 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'unmountComponentAtNode(...): Target container is not a DOM element.') : _prodInvariant('40') : void 0; +var defaultProps$25 = { + tag: 'div' +}; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!nodeIsRenderedByOtherInstance(container), "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by another copy of React.') : void 0; - } +var CardColumns = function CardColumns(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var prevComponent = getTopLevelWrapperInContainer(container); - if (!prevComponent) { - // Check if the node being unmounted was rendered by React, but isn't a - // root node. - var containerHasNonRootReactChild = hasNonRootReactChild(container); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-columns'), cssModule); - // Check if the container itself is a React root node. - var isContainerReactRoot = container.nodeType === 1 && container.hasAttribute(ROOT_ATTR_NAME); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by React and is not a top-level container. %s', isContainerReactRoot ? 'You may have accidentally passed in a React root node instead ' + 'of its container.' : 'Instead, have the parent component update its state and ' + 'rerender in order to remove this component.') : void 0; - } +CardColumns.propTypes = propTypes$26; +CardColumns.defaultProps = defaultProps$25; - return false; - } - delete instancesByReactRootID[prevComponent._instance.rootID]; - ReactUpdates.batchedUpdates(unmountComponentFromNode, prevComponent, container, false); - return true; - }, +var propTypes$27 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - _mountImageIntoNode: function (markup, container, instance, shouldReuseMarkup, transaction) { - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'mountComponentIntoNode(...): Target container is not valid.') : _prodInvariant('41') : void 0; +var defaultProps$26 = { + tag: 'div' +}; - if (shouldReuseMarkup) { - var rootElement = getReactRootElementInContainer(container); - if (ReactMarkupChecksum.canReuseMarkup(markup, rootElement)) { - ReactDOMComponentTree.precacheNode(instance, rootElement); - return; - } else { - var checksum = rootElement.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); - rootElement.removeAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); +var CardBlock = function CardBlock(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var rootMarkup = rootElement.outerHTML; - rootElement.setAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME, checksum); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-block'), cssModule); - var normalizedMarkup = markup; - if (process.env.NODE_ENV !== 'production') { - // because rootMarkup is retrieved from the DOM, various normalizations - // will have occurred which will not be present in `markup`. Here, - // insert markup into a <div> or <iframe> depending on the container - // type to perform the same normalizations before comparing. - var normalizer; - if (container.nodeType === ELEMENT_NODE_TYPE) { - normalizer = document.createElement('div'); - normalizer.innerHTML = markup; - normalizedMarkup = normalizer.innerHTML; - } else { - normalizer = document.createElement('iframe'); - document.body.appendChild(normalizer); - normalizer.contentDocument.write(markup); - normalizedMarkup = normalizer.contentDocument.documentElement.outerHTML; - document.body.removeChild(normalizer); - } - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - var diffIndex = firstDifferenceIndex(normalizedMarkup, rootMarkup); - var difference = ' (client) ' + normalizedMarkup.substring(diffIndex - 20, diffIndex + 20) + '\n (server) ' + rootMarkup.substring(diffIndex - 20, diffIndex + 20); +CardBlock.propTypes = propTypes$27; +CardBlock.defaultProps = defaultProps$26; - !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document using server rendering but the checksum was invalid. This usually means you rendered a different component type or props on the client from the one on the server, or your render() methods are impure. React cannot handle this case due to cross-browser quirks by rendering at the document root. You should look for environment dependent code in your components and ensure the props are the same client and server side:\n%s', difference) : _prodInvariant('42', difference) : void 0; +var propTypes$28 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(false, 'React attempted to reuse markup in a container but the ' + 'checksum was invalid. This generally means that you are ' + 'using server rendering and the markup generated on the ' + 'server was not what the client was expecting. React injected ' + 'new markup to compensate which works but you have lost many ' + 'of the benefits of server rendering. Instead, figure out ' + 'why the markup being generated is different on the client ' + 'or server:\n%s', difference) : void 0; - } - } - } +var defaultProps$27 = { + tag: 'a' +}; - !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document but you didn\'t use server rendering. We can\'t do this without using server rendering due to cross-browser quirks. See ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('43') : void 0; +var CardLink = function CardLink(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + getRef = props.getRef, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'getRef']); - if (transaction.useCreateElement) { - while (container.lastChild) { - container.removeChild(container.lastChild); - } - DOMLazyTree.insertTreeBefore(container, markup, null); - } else { - setInnerHTML(container, markup); - ReactDOMComponentTree.precacheNode(instance, container.firstChild); - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-link'), cssModule); - if (process.env.NODE_ENV !== 'production') { - var hostNode = ReactDOMComponentTree.getInstanceFromNode(container.firstChild); - if (hostNode._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: hostNode._debugID, - type: 'mount', - payload: markup.toString() - }); - } - } - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); }; -module.exports = ReactMount; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 105 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +CardLink.propTypes = propTypes$28; +CardLink.defaultProps = defaultProps$27; +var propTypes$29 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; +var defaultProps$28 = { + tag: 'div' +}; -var ReactNodeTypes = __webpack_require__(97); +var CardFooter = function CardFooter(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -function getHostComponentFromComposite(inst) { - var type; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-footer'), cssModule); - while ((type = inst._renderedNodeType) === ReactNodeTypes.COMPOSITE) { - inst = inst._renderedComponent; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (type === ReactNodeTypes.HOST) { - return inst._renderedComponent; - } else if (type === ReactNodeTypes.EMPTY) { - return null; - } -} +CardFooter.propTypes = propTypes$29; +CardFooter.defaultProps = defaultProps$28; -module.exports = getHostComponentFromComposite; +var propTypes$30 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -/***/ }), -/* 106 */ -/***/ (function(module, exports, __webpack_require__) { +var defaultProps$29 = { + tag: 'div' +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +var CardHeader = function CardHeader(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -exports.__esModule = true; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-header'), cssModule); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var _chainFunction = __webpack_require__(228); +CardHeader.propTypes = propTypes$30; +CardHeader.defaultProps = defaultProps$29; -var _chainFunction2 = _interopRequireDefault(_chainFunction); +var propTypes$31 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var _react = __webpack_require__(4); +var defaultProps$30 = { + tag: 'img' +}; -var _react2 = _interopRequireDefault(_react); +var CardImg = function CardImg(props) { + var className = props.className, + cssModule = props.cssModule, + top = props.top, + bottom = props.bottom, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'top', 'bottom', 'tag']); -var _propTypes = __webpack_require__(9); -var _propTypes2 = _interopRequireDefault(_propTypes); + var cardImgClassName = 'card-img'; + if (top) { + cardImgClassName = 'card-img-top'; + } + if (bottom) { + cardImgClassName = 'card-img-bottom'; + } -var _warning = __webpack_require__(229); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, cardImgClassName), cssModule); -var _warning2 = _interopRequireDefault(_warning); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var _ChildMapping = __webpack_require__(230); +CardImg.propTypes = propTypes$31; +CardImg.defaultProps = defaultProps$30; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var propTypes$32 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +var defaultProps$31 = { + tag: 'div' +}; -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +var CardImgOverlay = function CardImgOverlay(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-img-overlay'), cssModule); -var propTypes = { - component: _propTypes2.default.any, - childFactory: _propTypes2.default.func, - children: _propTypes2.default.node + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -var defaultProps = { - component: 'span', - childFactory: function childFactory(child) { - return child; - } +CardImgOverlay.propTypes = propTypes$32; +CardImgOverlay.defaultProps = defaultProps$31; + +var propTypes$33 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -var TransitionGroup = function (_React$Component) { - _inherits(TransitionGroup, _React$Component); +var defaultProps$32 = { + tag: 'h6' +}; - function TransitionGroup(props, context) { - _classCallCheck(this, TransitionGroup); +var CardSubtitle = function CardSubtitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var _this = _possibleConstructorReturn(this, _React$Component.call(this, props, context)); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-subtitle'), cssModule); - _this.performAppear = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (component.componentWillAppear) { - component.componentWillAppear(_this._handleDoneAppearing.bind(_this, key, component)); - } else { - _this._handleDoneAppearing(key, component); - } - }; +CardSubtitle.propTypes = propTypes$33; +CardSubtitle.defaultProps = defaultProps$32; - _this._handleDoneAppearing = function (key, component) { - if (component.componentDidAppear) { - component.componentDidAppear(); - } +var propTypes$34 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - delete _this.currentlyTransitioningKeys[key]; +var defaultProps$33 = { + tag: 'p' +}; - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); +var CardText = function CardText(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { - // This was removed before it had fully appeared. Remove it. - _this.performLeave(key, component); - } - }; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-text'), cssModule); - _this.performEnter = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (component.componentWillEnter) { - component.componentWillEnter(_this._handleDoneEntering.bind(_this, key, component)); - } else { - _this._handleDoneEntering(key, component); - } - }; +CardText.propTypes = propTypes$34; +CardText.defaultProps = defaultProps$33; - _this._handleDoneEntering = function (key, component) { - if (component.componentDidEnter) { - component.componentDidEnter(); - } +var propTypes$35 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - delete _this.currentlyTransitioningKeys[key]; +var defaultProps$34 = { + tag: 'h4' +}; - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); +var CardTitle = function CardTitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { - // This was removed before it had fully entered. Remove it. - _this.performLeave(key, component); - } - }; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-title'), cssModule); - _this.performLeave = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (component.componentWillLeave) { - component.componentWillLeave(_this._handleDoneLeaving.bind(_this, key, component)); - } else { - // Note that this is somewhat dangerous b/c it calls setState() - // again, effectively mutating the component before all the work - // is done. - _this._handleDoneLeaving(key, component); - } - }; +CardTitle.propTypes = propTypes$35; +CardTitle.defaultProps = defaultProps$34; - _this._handleDoneLeaving = function (key, component) { - if (component.componentDidLeave) { - component.componentDidLeave(); - } +var propTypes$36 = { + placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), + target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string.isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; - delete _this.currentlyTransitioningKeys[key]; +var defaultProps$35 = { + isOpen: false, + placement: 'bottom', + toggle: function toggle() {} +}; - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); +var defaultTetherConfig$1 = { + classPrefix: 'bs-tether', + classes: { + element: false, + enabled: 'show' + }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] +}; - if (currentChildMapping && currentChildMapping.hasOwnProperty(key)) { - // This entered again before it fully left. Add it again. - _this.keysToEnter.push(key); - } else { - _this.setState(function (state) { - var newChildren = _extends({}, state.children); - delete newChildren[key]; - return { children: newChildren }; - }); - } - }; +var Popover = function (_React$Component) { + inherits(Popover, _React$Component); - _this.childRefs = Object.create(null); + function Popover(props) { + classCallCheck(this, Popover); - _this.state = { - children: (0, _ChildMapping.getChildMapping)(props.children) - }; + var _this = possibleConstructorReturn(this, (Popover.__proto__ || Object.getPrototypeOf(Popover)).call(this, props)); + + _this.getTetherConfig = _this.getTetherConfig.bind(_this); return _this; } - TransitionGroup.prototype.componentWillMount = function componentWillMount() { - this.currentlyTransitioningKeys = {}; - this.keysToEnter = []; - this.keysToLeave = []; - }; - - TransitionGroup.prototype.componentDidMount = function componentDidMount() { - var initialChildMapping = this.state.children; - for (var key in initialChildMapping) { - if (initialChildMapping[key]) { - this.performAppear(key, this.childRefs[key]); - } + createClass(Popover, [{ + key: 'getTetherConfig', + value: function getTetherConfig() { + var attachments = getTetherAttachments(this.props.placement); + return _extends({}, defaultTetherConfig$1, attachments, { + target: '#' + this.props.target + }, this.props.tether); } - }; + }, { + key: 'render', + value: function render() { + if (!this.props.isOpen) { + return null; + } - TransitionGroup.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { - var nextChildMapping = (0, _ChildMapping.getChildMapping)(nextProps.children); - var prevChildMapping = this.state.children; + var tetherConfig = this.getTetherConfig(); - this.setState({ - children: (0, _ChildMapping.mergeChildMappings)(prevChildMapping, nextChildMapping) - }); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('popover-inner', this.props.className), this.props.cssModule); - for (var key in nextChildMapping) { - var hasPrev = prevChildMapping && prevChildMapping.hasOwnProperty(key); - if (nextChildMapping[key] && !hasPrev && !this.currentlyTransitioningKeys[key]) { - this.keysToEnter.push(key); - } - } + var attributes = omit(this.props, Object.keys(propTypes$36)); - for (var _key in prevChildMapping) { - var hasNext = nextChildMapping && nextChildMapping.hasOwnProperty(_key); - if (prevChildMapping[_key] && !hasNext && !this.currentlyTransitioningKeys[_key]) { - this.keysToLeave.push(_key); - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + { + className: mapToCssModules('popover', this.props.cssModule), + tether: tetherConfig, + tetherRef: this.props.tetherRef, + isOpen: this.props.isOpen, + toggle: this.props.toggle + }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { className: classes })) + ); } + }]); + return Popover; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - // If we want to someday check for reordering, we could do it here. - }; +Popover.propTypes = propTypes$36; +Popover.defaultProps = defaultProps$35; - TransitionGroup.prototype.componentDidUpdate = function componentDidUpdate() { - var _this2 = this; +var propTypes$37 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - var keysToEnter = this.keysToEnter; - this.keysToEnter = []; - keysToEnter.forEach(function (key) { - return _this2.performEnter(key, _this2.childRefs[key]); - }); +var defaultProps$36 = { + tag: 'h3' +}; - var keysToLeave = this.keysToLeave; - this.keysToLeave = []; - keysToLeave.forEach(function (key) { - return _this2.performLeave(key, _this2.childRefs[key]); - }); - }; +var PopoverTitle = function PopoverTitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - TransitionGroup.prototype.render = function render() { - var _this3 = this; - // TODO: we could get rid of the need for the wrapper node - // by cloning a single child - var childrenToRender = []; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-title'), cssModule); - var _loop = function _loop(key) { - var child = _this3.state.children[key]; - if (child) { - var isCallbackRef = typeof child.ref !== 'string'; - var factoryChild = _this3.props.childFactory(child); - var ref = function ref(r) { - _this3.childRefs[key] = r; - }; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - process.env.NODE_ENV !== 'production' ? (0, _warning2.default)(isCallbackRef, 'string refs are not supported on children of TransitionGroup and will be ignored. ' + 'Please use a callback ref instead: https://facebook.github.io/react/docs/refs-and-the-dom.html#the-ref-callback-attribute') : void 0; +PopoverTitle.propTypes = propTypes$37; +PopoverTitle.defaultProps = defaultProps$36; - // Always chaining the refs leads to problems when the childFactory - // wraps the child. The child ref callback gets called twice with the - // wrapper and the child. So we only need to chain the ref if the - // factoryChild is not different from child. - if (factoryChild === child && isCallbackRef) { - ref = (0, _chainFunction2.default)(child.ref, ref); - } +var propTypes$38 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - // You may need to apply reactive updates to a child as it is leaving. - // The normal React way to do it won't work since the child will have - // already been removed. In case you need this behavior you can provide - // a childFactory function to wrap every child, even the ones that are - // leaving. - childrenToRender.push(_react2.default.cloneElement(factoryChild, { - key: key, - ref: ref - })); - } - }; +var defaultProps$37 = { + tag: 'div' +}; - for (var key in this.state.children) { - _loop(key); - } +var PopoverContent = function PopoverContent(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - // Do not forward TransitionGroup props to primitive DOM nodes - var props = _extends({}, this.props); - delete props.transitionLeave; - delete props.transitionName; - delete props.transitionAppear; - delete props.transitionEnter; - delete props.childFactory; - delete props.transitionLeaveTimeout; - delete props.transitionEnterTimeout; - delete props.transitionAppearTimeout; - delete props.component; - return _react2.default.createElement(this.props.component, props, childrenToRender); - }; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-content'), cssModule); - return TransitionGroup; -}(_react2.default.Component); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -TransitionGroup.displayName = 'TransitionGroup'; +PopoverContent.propTypes = propTypes$38; +PopoverContent.defaultProps = defaultProps$37; +var propTypes$39 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + bar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + multi: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + value: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + max: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + animated: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + barClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -TransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; -TransitionGroup.defaultProps = defaultProps; +var defaultProps$38 = { + tag: 'div', + value: 0, + max: 100 +}; -exports.default = TransitionGroup; -module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var Progress = function Progress(props) { + var children = props.children, + className = props.className, + barClassName = props.barClassName, + cssModule = props.cssModule, + value = props.value, + max = props.max, + animated = props.animated, + striped = props.striped, + color = props.color, + bar = props.bar, + multi = props.multi, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['children', 'className', 'barClassName', 'cssModule', 'value', 'max', 'animated', 'striped', 'color', 'bar', 'multi', 'tag']); -/***/ }), -/* 107 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; + var percent = __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(value) / __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(max) * 100; + var progressClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'progress'), cssModule); -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.default = !!(typeof window !== 'undefined' && window.document && window.document.createElement); -module.exports = exports['default']; + var progressBarClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('progress-bar', bar ? className || barClassName : barClassName, animated ? 'progress-bar-animated' : null, color ? 'bg-' + color : null, striped || animated ? 'progress-bar-striped' : null), cssModule); -/***/ }), -/* 108 */ -/***/ (function(module, exports, __webpack_require__) { + var ProgressBar = multi ? children : __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { + className: progressBarClasses, + style: { width: percent + '%' }, + role: 'progressbar', + 'aria-valuenow': value, + 'aria-valuemin': '0', + 'aria-valuemax': max, + children: children + }); -"use strict"; + if (bar) { + return ProgressBar; + } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: progressClasses, children: ProgressBar })); +}; -exports.__esModule = true; -exports.nameShape = undefined; -exports.transitionTimeout = transitionTimeout; +Progress.propTypes = propTypes$39; +Progress.defaultProps = defaultProps$38; -var _react = __webpack_require__(4); +var propTypes$40 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + autoFocus: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + keyboard: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + backdrop: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(['static'])]), + onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onExit: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + wrapClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + modalClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + backdropClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + contentClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + fade: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + zIndex: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + backdropTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number +}; -var _react2 = _interopRequireDefault(_react); +var propsToOmit = Object.keys(propTypes$40); -var _propTypes = __webpack_require__(9); +var defaultProps$39 = { + isOpen: false, + autoFocus: true, + backdrop: true, + keyboard: true, + zIndex: 1050, + fade: true, + modalTransitionTimeout: 300, + backdropTransitionTimeout: 150 +}; -var _propTypes2 = _interopRequireDefault(_propTypes); +var Modal = function (_React$Component) { + inherits(Modal, _React$Component); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + function Modal(props) { + classCallCheck(this, Modal); -function transitionTimeout(transitionType) { - var timeoutPropName = 'transition' + transitionType + 'Timeout'; - var enabledPropName = 'transition' + transitionType; + var _this = possibleConstructorReturn(this, (Modal.__proto__ || Object.getPrototypeOf(Modal)).call(this, props)); - return function (props) { - // If the transition is enabled - if (props[enabledPropName]) { - // If no timeout duration is provided - if (props[timeoutPropName] == null) { - return new Error(timeoutPropName + ' wasn\'t supplied to CSSTransitionGroup: ' + 'this can cause unreliable animations and won\'t be supported in ' + 'a future version of React. See ' + 'https://fb.me/react-animation-transition-group-timeout for more ' + 'information.'); + _this.originalBodyPadding = null; + _this.isBodyOverflowing = false; + _this.togglePortal = _this.togglePortal.bind(_this); + _this.handleBackdropClick = _this.handleBackdropClick.bind(_this); + _this.handleEscape = _this.handleEscape.bind(_this); + _this.destroy = _this.destroy.bind(_this); + _this.onEnter = _this.onEnter.bind(_this); + _this.onExit = _this.onExit.bind(_this); + return _this; + } - // If the duration isn't a number - } else if (typeof props[timeoutPropName] !== 'number') { - return new Error(timeoutPropName + ' must be a number (in milliseconds)'); + createClass(Modal, [{ + key: 'componentDidMount', + value: function componentDidMount() { + if (this.props.isOpen) { + this.togglePortal(); } } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + // handle portal events/dom updates + this.togglePortal(); + } else if (this._element) { + // rerender portal + this.renderIntoSubtree(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.onExit(); + } + }, { + key: 'onEnter', + value: function onEnter() { + if (this.props.onEnter) { + this.props.onEnter(); + } + } + }, { + key: 'onExit', + value: function onExit() { + this.destroy(); + if (this.props.onExit) { + this.props.onExit(); + } + } + }, { + key: 'handleEscape', + value: function handleEscape(e) { + if (this.props.keyboard && e.keyCode === 27 && this.props.toggle) { + this.props.toggle(); + } + } + }, { + key: 'handleBackdropClick', + value: function handleBackdropClick(e) { + if (this.props.backdrop !== true) return; - return null; - }; -} - -var nameShape = exports.nameShape = _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.shape({ - enter: _propTypes2.default.string, - leave: _propTypes2.default.string, - active: _propTypes2.default.string -}), _propTypes2.default.shape({ - enter: _propTypes2.default.string, - enterActive: _propTypes2.default.string, - leave: _propTypes2.default.string, - leaveActive: _propTypes2.default.string, - appear: _propTypes2.default.string, - appearActive: _propTypes2.default.string -})]); - -/***/ }), -/* 109 */, -/* 110 */, -/* 111 */, -/* 112 */, -/* 113 */ -/***/ (function(module, exports, __webpack_require__) { + var container = this._dialog; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + if (e.target && !container.contains(e.target) && this.props.toggle) { + this.props.toggle(); + } + } + }, { + key: 'hasTransition', + value: function hasTransition() { + if (this.props.fade === false) { + return false; + } + return this.props.modalTransitionTimeout > 0; + } + }, { + key: 'togglePortal', + value: function togglePortal() { + if (this.props.isOpen) { + if (this.props.autoFocus) { + this._focus = true; + } + this.show(); + if (!this.hasTransition()) { + this.onEnter(); + } + } else { + this.hide(); + if (!this.hasTransition()) { + this.onExit(); + } + } + } + }, { + key: 'destroy', + value: function destroy() { + if (this._element) { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); + document.body.removeChild(this._element); + this._element = null; + } + // Use regex to prevent matching `modal-open` as part of a different class, e.g. `my-modal-opened` + var classes = document.body.className.replace(/(^| )modal-open( |$)/, ' '); + document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes).trim(), this.props.cssModule); + setScrollbarWidth(this.originalBodyPadding); + } + }, { + key: 'hide', + value: function hide() { + this.renderIntoSubtree(); + } + }, { + key: 'show', + value: function show() { + var classes = document.body.className; + this._element = document.createElement('div'); + this._element.setAttribute('tabindex', '-1'); + this._element.style.position = 'relative'; + this._element.style.zIndex = this.props.zIndex; + this.originalBodyPadding = getOriginalBodyPadding(); -var _assign = __webpack_require__(5); + conditionallyUpdateScrollbar(); -var emptyObject = __webpack_require__(39); -var _invariant = __webpack_require__(1); + document.body.appendChild(this._element); -if (process.env.NODE_ENV !== 'production') { - var warning = __webpack_require__(2); -} + document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes, 'modal-open'), this.props.cssModule); -var MIXINS_KEY = 'mixins'; + this.renderIntoSubtree(); + } + }, { + key: 'renderModalDialog', + value: function renderModalDialog() { + var _this2 = this; -// Helper function to allow the creation of anonymous functions which do not -// have .name set to the name of the variable being assigned to. -function identity(fn) { - return fn; -} + var attributes = omit(this.props, propsToOmit); -var ReactPropTypeLocationNames; -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' - }; -} else { - ReactPropTypeLocationNames = {}; -} + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + _extends({ + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-dialog', this.props.className, defineProperty({}, 'modal-' + this.props.size, this.props.size)), this.props.cssModule), + role: 'document', + ref: function ref(c) { + return _this2._dialog = c; + } + }, attributes), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + { + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-content', this.props.contentClassName), this.props.cssModule) + }, + this.props.children + ) + ); + } + }, { + key: 'renderIntoSubtree', + value: function renderIntoSubtree() { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); -function factory(ReactComponent, isValidElement, ReactNoopUpdateQueue) { - /** - * Policies that describe methods in `ReactClassInterface`. - */ + // check if modal should receive focus + if (this._focus) { + this._dialog.parentNode.focus(); + this._focus = false; + } + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _props = this.props, + wrapClassName = _props.wrapClassName, + modalClassName = _props.modalClassName, + backdropClassName = _props.backdropClassName, + cssModule = _props.cssModule, + isOpen = _props.isOpen, + backdrop = _props.backdrop, + modalTransitionTimeout = _props.modalTransitionTimeout, + backdropTransitionTimeout = _props.backdropTransitionTimeout; - var injectedMixins = []; - /** - * Composite components are higher-level components that compose other composite - * or host components. - * - * To create a new type of `ReactClass`, pass a specification of - * your new class to `React.createClass`. The only requirement of your class - * specification is that you implement a `render` method. - * - * var MyComponent = React.createClass({ - * render: function() { - * return <div>Hello World</div>; - * } - * }); - * - * The class specification supports a specific protocol of methods that have - * special meaning (e.g. `render`). See `ReactClassInterface` for - * more the comprehensive protocol. Any other properties and methods in the - * class specification will be available on the prototype. - * - * @interface ReactClassInterface - * @internal - */ - var ReactClassInterface = { - /** - * An array of Mixin objects to include when defining your component. - * - * @type {array} - * @optional - */ - mixins: 'DEFINE_MANY', + var modalAttributes = { + onClickCapture: this.handleBackdropClick, + onKeyUp: this.handleEscape, + style: { display: 'block' }, + tabIndex: '-1' + }; - /** - * An object containing properties and methods that should be defined on - * the component's constructor instead of its prototype (static methods). - * - * @type {object} - * @optional - */ - statics: 'DEFINE_MANY', + if (this.hasTransition()) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["TransitionGroup"], + { component: 'div', className: mapToCssModules(wrapClassName) }, + isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Fade, + _extends({ + key: 'modal-dialog', + onEnter: this.onEnter, + onLeave: this.onExit, + transitionAppearTimeout: typeof this.props.modalTransitionAppearTimeout === 'number' ? this.props.modalTransitionAppearTimeout : modalTransitionTimeout, + transitionEnterTimeout: typeof this.props.modalTransitionEnterTimeout === 'number' ? this.props.modalTransitionEnterTimeout : modalTransitionTimeout, + transitionLeaveTimeout: typeof this.props.modalTransitionLeaveTimeout === 'number' ? this.props.modalTransitionLeaveTimeout : modalTransitionTimeout, + cssModule: cssModule, + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', modalClassName), cssModule) + }, modalAttributes), + this.renderModalDialog() + ), + isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Fade, { + key: 'modal-backdrop', + transitionAppearTimeout: typeof this.props.backdropTransitionAppearTimeout === 'number' ? this.props.backdropTransitionAppearTimeout : backdropTransitionTimeout, + transitionEnterTimeout: typeof this.props.backdropTransitionEnterTimeout === 'number' ? this.props.backdropTransitionEnterTimeout : backdropTransitionTimeout, + transitionLeaveTimeout: typeof this.props.backdropTransitionLeaveTimeout === 'number' ? this.props.backdropTransitionLeaveTimeout : backdropTransitionTimeout, + cssModule: cssModule, + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', backdropClassName), cssModule) + }) + ); + } - /** - * Definition of prop types for this component. - * - * @type {object} - * @optional - */ - propTypes: 'DEFINE_MANY', + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + { className: mapToCssModules(wrapClassName) }, + isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + _extends({ + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', 'show', modalClassName), cssModule) + }, modalAttributes), + this.renderModalDialog() + ), + isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', 'show', backdropClassName), cssModule) + }) + ); + } + }, { + key: 'render', + value: function render() { + return null; + } + }]); + return Modal; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - /** - * Definition of context types for this component. - * - * @type {object} - * @optional - */ - contextTypes: 'DEFINE_MANY', +Modal.propTypes = propTypes$40; +Modal.defaultProps = defaultProps$39; - /** - * Definition of context types this component sets for its children. - * - * @type {object} - * @optional - */ - childContextTypes: 'DEFINE_MANY', +var propTypes$41 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + wrapTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node +}; - // ==== Definition methods ==== +var defaultProps$40 = { + tag: 'h4', + wrapTag: 'div' +}; - /** - * Invoked when the component is mounted. Values in the mapping will be set on - * `this.props` if that prop is not specified (i.e. using an `in` check). - * - * This method is invoked before `getInitialState` and therefore cannot rely - * on `this.state` or use `this.setState`. - * - * @return {object} - * @optional - */ - getDefaultProps: 'DEFINE_MANY_MERGED', +var ModalHeader = function ModalHeader(props) { + var closeButton = void 0; + var className = props.className, + cssModule = props.cssModule, + children = props.children, + toggle = props.toggle, + Tag = props.tag, + WrapTag = props.wrapTag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'toggle', 'tag', 'wrapTag']); - /** - * Invoked once before the component is mounted. The return value will be used - * as the initial value of `this.state`. - * - * getInitialState: function() { - * return { - * isOn: false, - * fooBaz: new BazFoo() - * } - * } - * - * @return {object} - * @optional - */ - getInitialState: 'DEFINE_MANY_MERGED', - /** - * @return {object} - * @optional - */ - getChildContext: 'DEFINE_MANY_MERGED', + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-header'), cssModule); - /** - * Uses props from `this.props` and state from `this.state` to render the - * structure of the component. - * - * No guarantees are made about when or how often this method is invoked, so - * it must not have side effects. - * - * render: function() { - * var name = this.props.name; - * return <div>Hello, {name}!</div>; - * } - * - * @return {ReactComponent} - * @required - */ - render: 'DEFINE_ONCE', + if (toggle) { + closeButton = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'button', + { type: 'button', onClick: toggle, className: 'close', 'aria-label': 'Close' }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { 'aria-hidden': 'true' }, + String.fromCharCode(215) + ) + ); + } - // ==== Delegate methods ==== + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + WrapTag, + _extends({}, attributes, { className: classes }), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + { className: mapToCssModules('modal-title', cssModule) }, + children + ), + closeButton + ); +}; - /** - * Invoked when the component is initially created and about to be mounted. - * This may have side effects, but any external subscriptions or data created - * by this method must be cleaned up in `componentWillUnmount`. - * - * @optional - */ - componentWillMount: 'DEFINE_MANY', +ModalHeader.propTypes = propTypes$41; +ModalHeader.defaultProps = defaultProps$40; - /** - * Invoked when the component has been mounted and has a DOM representation. - * However, there is no guarantee that the DOM node is in the document. - * - * Use this as an opportunity to operate on the DOM when the component has - * been mounted (initialized and rendered) for the first time. - * - * @param {DOMElement} rootNode DOM element representing the component. - * @optional - */ - componentDidMount: 'DEFINE_MANY', +var propTypes$42 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - /** - * Invoked before the component receives new props. - * - * Use this as an opportunity to react to a prop transition by updating the - * state using `this.setState`. Current props are accessed via `this.props`. - * - * componentWillReceiveProps: function(nextProps, nextContext) { - * this.setState({ - * likesIncreasing: nextProps.likeCount > this.props.likeCount - * }); - * } - * - * NOTE: There is no equivalent `componentWillReceiveState`. An incoming prop - * transition may cause a state change, but the opposite is not true. If you - * need it, you are probably looking for `componentWillUpdate`. - * - * @param {object} nextProps - * @optional - */ - componentWillReceiveProps: 'DEFINE_MANY', +var defaultProps$41 = { + tag: 'div' +}; - /** - * Invoked while deciding if the component should be updated as a result of - * receiving new props, state and/or context. - * - * Use this as an opportunity to `return false` when you're certain that the - * transition to the new props/state/context will not require a component - * update. - * - * shouldComponentUpdate: function(nextProps, nextState, nextContext) { - * return !equal(nextProps, this.props) || - * !equal(nextState, this.state) || - * !equal(nextContext, this.context); - * } - * - * @param {object} nextProps - * @param {?object} nextState - * @param {?object} nextContext - * @return {boolean} True if the component should update. - * @optional - */ - shouldComponentUpdate: 'DEFINE_ONCE', +var ModalBody = function ModalBody(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - /** - * Invoked when the component is about to update due to a transition from - * `this.props`, `this.state` and `this.context` to `nextProps`, `nextState` - * and `nextContext`. - * - * Use this as an opportunity to perform preparation before an update occurs. - * - * NOTE: You **cannot** use `this.setState()` in this method. - * - * @param {object} nextProps - * @param {?object} nextState - * @param {?object} nextContext - * @param {ReactReconcileTransaction} transaction - * @optional - */ - componentWillUpdate: 'DEFINE_MANY', + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-body'), cssModule); - /** - * Invoked when the component's DOM representation has been updated. - * - * Use this as an opportunity to operate on the DOM when the component has - * been updated. - * - * @param {object} prevProps - * @param {?object} prevState - * @param {?object} prevContext - * @param {DOMElement} rootNode DOM element representing the component. - * @optional - */ - componentDidUpdate: 'DEFINE_MANY', + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - /** - * Invoked when the component is about to be removed from its parent and have - * its DOM representation destroyed. - * - * Use this as an opportunity to deallocate any external resources. - * - * NOTE: There is no `componentDidUnmount` since your component will have been - * destroyed by that point. - * - * @optional - */ - componentWillUnmount: 'DEFINE_MANY', +ModalBody.propTypes = propTypes$42; +ModalBody.defaultProps = defaultProps$41; - // ==== Advanced methods ==== +var propTypes$43 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - /** - * Updates the component's currently mounted DOM representation. - * - * By default, this implements React's rendering and reconciliation algorithm. - * Sophisticated clients may wish to override this. - * - * @param {ReactReconcileTransaction} transaction - * @internal - * @overridable - */ - updateComponent: 'OVERRIDE_BASE' - }; +var defaultProps$42 = { + tag: 'div' +}; - /** - * Mapping from class specification keys to special processing functions. - * - * Although these are declared like instance properties in the specification - * when defining classes using `React.createClass`, they are actually static - * and are accessible on the constructor instead of the prototype. Despite - * being static, they must be defined outside of the "statics" key under - * which all other static methods are defined. - */ - var RESERVED_SPEC_KEYS = { - displayName: function(Constructor, displayName) { - Constructor.displayName = displayName; - }, - mixins: function(Constructor, mixins) { - if (mixins) { - for (var i = 0; i < mixins.length; i++) { - mixSpecIntoComponent(Constructor, mixins[i]); - } +var ModalFooter = function ModalFooter(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-footer'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ModalFooter.propTypes = propTypes$43; +ModalFooter.defaultProps = defaultProps$42; + +var propTypes$44 = { + placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), + target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + autohide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]) +}; + +var DEFAULT_DELAYS = { + show: 0, + hide: 250 +}; + +var defaultProps$43 = { + isOpen: false, + placement: 'bottom', + delay: DEFAULT_DELAYS, + autohide: true, + toggle: function toggle() {} +}; + +var defaultTetherConfig$2 = { + classPrefix: 'bs-tether', + classes: { + element: false, + enabled: 'show' + }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] +}; + +var Tooltip = function (_React$Component) { + inherits(Tooltip, _React$Component); + + function Tooltip(props) { + classCallCheck(this, Tooltip); + + var _this = possibleConstructorReturn(this, (Tooltip.__proto__ || Object.getPrototypeOf(Tooltip)).call(this, props)); + + _this.addTargetEvents = _this.addTargetEvents.bind(_this); + _this.getTarget = _this.getTarget.bind(_this); + _this.getTetherConfig = _this.getTetherConfig.bind(_this); + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.removeTargetEvents = _this.removeTargetEvents.bind(_this); + _this.toggle = _this.toggle.bind(_this); + _this.onMouseOverTooltip = _this.onMouseOverTooltip.bind(_this); + _this.onMouseLeaveTooltip = _this.onMouseLeaveTooltip.bind(_this); + _this.onMouseOverTooltipContent = _this.onMouseOverTooltipContent.bind(_this); + _this.onMouseLeaveTooltipContent = _this.onMouseLeaveTooltipContent.bind(_this); + _this.show = _this.show.bind(_this); + _this.hide = _this.hide.bind(_this); + return _this; + } + + createClass(Tooltip, [{ + key: 'componentDidMount', + value: function componentDidMount() { + this._target = this.getTarget(); + this.addTargetEvents(); + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.removeTargetEvents(); + } + }, { + key: 'onMouseOverTooltip', + value: function onMouseOverTooltip() { + if (this._hideTimeout) { + this.clearHideTimeout(); } - }, - childContextTypes: function(Constructor, childContextTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, childContextTypes, 'childContext'); + this._showTimeout = setTimeout(this.show, this.getDelay('show')); + } + }, { + key: 'onMouseLeaveTooltip', + value: function onMouseLeaveTooltip() { + if (this._showTimeout) { + this.clearShowTimeout(); } - Constructor.childContextTypes = _assign( - {}, - Constructor.childContextTypes, - childContextTypes - ); - }, - contextTypes: function(Constructor, contextTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, contextTypes, 'context'); + this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); + } + }, { + key: 'onMouseOverTooltipContent', + value: function onMouseOverTooltipContent() { + if (this.props.autohide) { + return; } - Constructor.contextTypes = _assign( - {}, - Constructor.contextTypes, - contextTypes - ); - }, - /** - * Special case getDefaultProps which should move into statics but requires - * automatic merging. - */ - getDefaultProps: function(Constructor, getDefaultProps) { - if (Constructor.getDefaultProps) { - Constructor.getDefaultProps = createMergedResultFunction( - Constructor.getDefaultProps, - getDefaultProps - ); - } else { - Constructor.getDefaultProps = getDefaultProps; + if (this._hideTimeout) { + this.clearHideTimeout(); } - }, - propTypes: function(Constructor, propTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, propTypes, 'prop'); + } + }, { + key: 'onMouseLeaveTooltipContent', + value: function onMouseLeaveTooltipContent() { + if (this.props.autohide) { + return; } - Constructor.propTypes = _assign({}, Constructor.propTypes, propTypes); - }, - statics: function(Constructor, statics) { - mixStaticSpecIntoComponent(Constructor, statics); - }, - autobind: function() {} - }; - - function validateTypeDef(Constructor, typeDef, location) { - for (var propName in typeDef) { - if (typeDef.hasOwnProperty(propName)) { - // use a warning instead of an _invariant so components - // don't show up in prod but only in __DEV__ - if (process.env.NODE_ENV !== 'production') { - warning( - typeof typeDef[propName] === 'function', - '%s: %s type `%s` is invalid; it must be a function, usually from ' + - 'React.PropTypes.', - Constructor.displayName || 'ReactClass', - ReactPropTypeLocationNames[location], - propName - ); - } + if (this._showTimeout) { + this.clearShowTimeout(); } + this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); } - } - - function validateMethodOverride(isAlreadyDefined, name) { - var specPolicy = ReactClassInterface.hasOwnProperty(name) - ? ReactClassInterface[name] - : null; + }, { + key: 'getDelay', + value: function getDelay(key) { + var delay = this.props.delay; - // Disallow overriding of base class methods unless explicitly allowed. - if (ReactClassMixin.hasOwnProperty(name)) { - _invariant( - specPolicy === 'OVERRIDE_BASE', - 'ReactClassInterface: You are attempting to override ' + - '`%s` from your class specification. Ensure that your method names ' + - 'do not overlap with React methods.', - name - ); + if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { + return isNaN(delay[key]) ? DEFAULT_DELAYS[key] : delay[key]; + } + return delay; } + }, { + key: 'getTarget', + value: function getTarget() { + var target = this.props.target; - // Disallow defining methods more than once unless explicitly allowed. - if (isAlreadyDefined) { - _invariant( - specPolicy === 'DEFINE_MANY' || specPolicy === 'DEFINE_MANY_MERGED', - 'ReactClassInterface: You are attempting to define ' + - '`%s` on your component more than once. This conflict may be due ' + - 'to a mixin.', - name - ); + if ((typeof target === 'undefined' ? 'undefined' : _typeof(target)) === 'object') { + return target; + } + return document.getElementById(target); } - } - - /** - * Mixin helper which handles policy validation and reserved - * specification keys when building React classes. - */ - function mixSpecIntoComponent(Constructor, spec) { - if (!spec) { - if (process.env.NODE_ENV !== 'production') { - var typeofSpec = typeof spec; - var isMixinValid = typeofSpec === 'object' && spec !== null; + }, { + key: 'getTetherConfig', + value: function getTetherConfig() { + var attachments = getTetherAttachments(this.props.placement); + return _extends({}, defaultTetherConfig$2, attachments, { + target: this.getTarget + }, this.props.tether); + } + }, { + key: 'show', + value: function show() { + if (!this.props.isOpen) { + this.clearShowTimeout(); + this.toggle(); + } + } + }, { + key: 'hide', + value: function hide() { + if (this.props.isOpen) { + this.clearHideTimeout(); + this.toggle(); + } + } + }, { + key: 'clearShowTimeout', + value: function clearShowTimeout() { + clearTimeout(this._showTimeout); + this._showTimeout = undefined; + } + }, { + key: 'clearHideTimeout', + value: function clearHideTimeout() { + clearTimeout(this._hideTimeout); + this._hideTimeout = undefined; + } + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + if (e.target === this._target || this._target.contains(e.target)) { + if (this._hideTimeout) { + this.clearHideTimeout(); + } - if (process.env.NODE_ENV !== 'production') { - warning( - isMixinValid, - "%s: You're attempting to include a mixin that is either null " + - 'or not an object. Check the mixins included by the component, ' + - 'as well as any mixins they include themselves. ' + - 'Expected object but got %s.', - Constructor.displayName || 'ReactClass', - spec === null ? null : typeofSpec - ); + if (!this.props.isOpen) { + this.toggle(); } } + } + }, { + key: 'addTargetEvents', + value: function addTargetEvents() { + this._target.addEventListener('mouseover', this.onMouseOverTooltip, true); + this._target.addEventListener('mouseout', this.onMouseLeaveTooltip, true); + document.addEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'removeTargetEvents', + value: function removeTargetEvents() { + this._target.removeEventListener('mouseover', this.onMouseOverTooltip, true); + this._target.removeEventListener('mouseout', this.onMouseLeaveTooltip, true); + document.removeEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } - return; + return this.props.toggle(); } + }, { + key: 'render', + value: function render() { + if (!this.props.isOpen) { + return null; + } - _invariant( - typeof spec !== 'function', - "ReactClass: You're attempting to " + - 'use a component class or function as a mixin. Instead, just use a ' + - 'regular object.' - ); - _invariant( - !isValidElement(spec), - "ReactClass: You're attempting to " + - 'use a component as a mixin. Instead, just use a regular object.' - ); + var attributes = omit(this.props, Object.keys(propTypes$44)); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tooltip-inner', this.props.className), this.props.cssModule); - var proto = Constructor.prototype; - var autoBindPairs = proto.__reactAutoBindPairs; + var tetherConfig = this.getTetherConfig(); - // By handling mixins before any other properties, we ensure the same - // chaining order is applied to methods with DEFINE_MANY policy, whether - // mixins are listed before or after these methods in the spec. - if (spec.hasOwnProperty(MIXINS_KEY)) { - RESERVED_SPEC_KEYS.mixins(Constructor, spec.mixins); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + { + className: 'tooltip', + tether: tetherConfig, + tetherRef: this.props.tetherRef, + isOpen: this.props.isOpen, + toggle: this.toggle + }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { + className: classes, + onMouseOver: this.onMouseOverTooltipContent, + onMouseLeave: this.onMouseLeaveTooltipContent + })) + ); } + }]); + return Tooltip; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - for (var name in spec) { - if (!spec.hasOwnProperty(name)) { - continue; - } +Tooltip.propTypes = propTypes$44; +Tooltip.defaultProps = defaultProps$43; - if (name === MIXINS_KEY) { - // We have already handled mixins in a special case above. - continue; - } +var propTypes$45 = { + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + bordered: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + hover: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + reflow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + responsive: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + responsiveTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; - var property = spec[name]; - var isAlreadyDefined = proto.hasOwnProperty(name); - validateMethodOverride(isAlreadyDefined, name); +var defaultProps$44 = { + tag: 'table', + responsiveTag: 'div' +}; - if (RESERVED_SPEC_KEYS.hasOwnProperty(name)) { - RESERVED_SPEC_KEYS[name](Constructor, property); - } else { - // Setup methods on prototype: - // The following member methods should not be automatically bound: - // 1. Expected ReactClass methods (in the "interface"). - // 2. Overridden methods (that were mixed in). - var isReactClassMethod = ReactClassInterface.hasOwnProperty(name); - var isFunction = typeof property === 'function'; - var shouldAutoBind = - isFunction && - !isReactClassMethod && - !isAlreadyDefined && - spec.autobind !== false; +var Table = function Table(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + bordered = props.bordered, + striped = props.striped, + inverse = props.inverse, + hover = props.hover, + reflow = props.reflow, + responsive = props.responsive, + Tag = props.tag, + ResponsiveTag = props.responsiveTag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'bordered', 'striped', 'inverse', 'hover', 'reflow', 'responsive', 'tag', 'responsiveTag']); - if (shouldAutoBind) { - autoBindPairs.push(name, property); - proto[name] = property; - } else { - if (isAlreadyDefined) { - var specPolicy = ReactClassInterface[name]; - // These cases should already be caught by validateMethodOverride. - _invariant( - isReactClassMethod && - (specPolicy === 'DEFINE_MANY_MERGED' || - specPolicy === 'DEFINE_MANY'), - 'ReactClass: Unexpected spec policy %s for key %s ' + - 'when mixing in component specs.', - specPolicy, - name - ); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'table', size ? 'table-' + size : false, bordered ? 'table-bordered' : false, striped ? 'table-striped' : false, inverse ? 'table-inverse' : false, hover ? 'table-hover' : false, reflow ? 'table-reflow' : false), cssModule); - // For methods which are defined more than once, call the existing - // methods before calling the new property, merging if appropriate. - if (specPolicy === 'DEFINE_MANY_MERGED') { - proto[name] = createMergedResultFunction(proto[name], property); - } else if (specPolicy === 'DEFINE_MANY') { - proto[name] = createChainedFunction(proto[name], property); - } - } else { - proto[name] = property; - if (process.env.NODE_ENV !== 'production') { - // Add verbose displayName to the function, which helps when looking - // at profiling tools. - if (typeof property === 'function' && spec.displayName) { - proto[name].displayName = spec.displayName + '_' + name; - } - } - } - } - } - } + var table = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + + if (responsive) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + ResponsiveTag, + { className: 'table-responsive' }, + table + ); } - function mixStaticSpecIntoComponent(Constructor, statics) { - if (!statics) { - return; - } - for (var name in statics) { - var property = statics[name]; - if (!statics.hasOwnProperty(name)) { - continue; - } + return table; +}; - var isReserved = name in RESERVED_SPEC_KEYS; - _invariant( - !isReserved, - 'ReactClass: You are attempting to define a reserved ' + - 'property, `%s`, that shouldn\'t be on the "statics" key. Define it ' + - 'as an instance property instead; it will still be accessible on the ' + - 'constructor.', - name - ); +Table.propTypes = propTypes$45; +Table.defaultProps = defaultProps$44; - var isInherited = name in Constructor; - _invariant( - !isInherited, - 'ReactClass: You are attempting to define ' + - '`%s` on your component more than once. This conflict may be ' + - 'due to a mixin.', - name - ); - Constructor[name] = property; - } - } +var propTypes$46 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + flush: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - /** - * Merge two objects, but throw if both contain the same key. - * - * @param {object} one The first object, which is mutated. - * @param {object} two The second object - * @return {object} one after it has been mutated to contain everything in two. - */ - function mergeIntoWithNoDuplicateKeys(one, two) { - _invariant( - one && two && typeof one === 'object' && typeof two === 'object', - 'mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.' - ); +var defaultProps$45 = { + tag: 'ul' +}; - for (var key in two) { - if (two.hasOwnProperty(key)) { - _invariant( - one[key] === undefined, - 'mergeIntoWithNoDuplicateKeys(): ' + - 'Tried to merge two objects with the same key: `%s`. This conflict ' + - 'may be due to a mixin; in particular, this may be caused by two ' + - 'getInitialState() or getDefaultProps() methods returning objects ' + - 'with clashing keys.', - key - ); - one[key] = two[key]; - } - } - return one; - } +var ListGroup = function ListGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + flush = props.flush, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'flush']); - /** - * Creates a function that invokes two functions and merges their return values. - * - * @param {function} one Function to invoke first. - * @param {function} two Function to invoke second. - * @return {function} Function that invokes the two argument functions. - * @private - */ - function createMergedResultFunction(one, two) { - return function mergedResult() { - var a = one.apply(this, arguments); - var b = two.apply(this, arguments); - if (a == null) { - return b; - } else if (b == null) { - return a; - } - var c = {}; - mergeIntoWithNoDuplicateKeys(c, a); - mergeIntoWithNoDuplicateKeys(c, b); - return c; - }; - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group', flush ? 'list-group-flush' : false), cssModule); - /** - * Creates a function that invokes two functions and ignores their return vales. - * - * @param {function} one Function to invoke first. - * @param {function} two Function to invoke second. - * @return {function} Function that invokes the two argument functions. - * @private - */ - function createChainedFunction(one, two) { - return function chainedFunction() { - one.apply(this, arguments); - two.apply(this, arguments); - }; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - /** - * Binds a method to the component. - * - * @param {object} component Component whose method is going to be bound. - * @param {function} method Method to be bound. - * @return {function} The bound method. - */ - function bindAutoBindMethod(component, method) { - var boundMethod = method.bind(component); - if (process.env.NODE_ENV !== 'production') { - boundMethod.__reactBoundContext = component; - boundMethod.__reactBoundMethod = method; - boundMethod.__reactBoundArguments = null; - var componentName = component.constructor.displayName; - var _bind = boundMethod.bind; - boundMethod.bind = function(newThis) { - for ( - var _len = arguments.length, - args = Array(_len > 1 ? _len - 1 : 0), - _key = 1; - _key < _len; - _key++ - ) { - args[_key - 1] = arguments[_key]; - } +ListGroup.propTypes = propTypes$46; +ListGroup.defaultProps = defaultProps$45; - // User is trying to bind() an autobound method; we effectively will - // ignore the value of "this" that the user is trying to use, so - // let's warn. - if (newThis !== component && newThis !== null) { - if (process.env.NODE_ENV !== 'production') { - warning( - false, - 'bind(): React component methods may only be bound to the ' + - 'component instance. See %s', - componentName - ); - } - } else if (!args.length) { - if (process.env.NODE_ENV !== 'production') { - warning( - false, - 'bind(): You are binding a component method to the component. ' + - 'React does this for you automatically in a high-performance ' + - 'way, so you can safely remove this call. See %s', - componentName - ); - } - return boundMethod; - } - var reboundMethod = _bind.apply(boundMethod, arguments); - reboundMethod.__reactBoundContext = component; - reboundMethod.__reactBoundMethod = method; - reboundMethod.__reactBoundArguments = args; - return reboundMethod; - }; - } - return boundMethod; - } +var propTypes$47 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - /** - * Binds all auto-bound methods in a component. - * - * @param {object} component Component whose method is going to be bound. - */ - function bindAutoBindMethods(component) { - var pairs = component.__reactAutoBindPairs; - for (var i = 0; i < pairs.length; i += 2) { - var autoBindKey = pairs[i]; - var method = pairs[i + 1]; - component[autoBindKey] = bindAutoBindMethod(component, method); - } - } +var defaultProps$46 = { + tag: 'form' +}; - var IsMountedPreMixin = { - componentDidMount: function() { - this.__isMounted = true; - } - }; +var Form = function Form(props) { + var className = props.className, + cssModule = props.cssModule, + inline = props.inline, + Tag = props.tag, + getRef = props.getRef, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'tag', 'getRef']); - var IsMountedPostMixin = { - componentWillUnmount: function() { - this.__isMounted = false; - } - }; - /** - * Add more to the ReactClass base class. These are all legacy features and - * therefore not already part of the modern ReactComponent. - */ - var ReactClassMixin = { - /** - * TODO: This will be deprecated because state should always keep a consistent - * type signature and the only use case for this, is to avoid that. - */ - replaceState: function(newState, callback) { - this.updater.enqueueReplaceState(this, newState, callback); - }, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, inline ? 'form-inline' : false), cssModule); - /** - * Checks whether or not this composite component is mounted. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function() { - if (process.env.NODE_ENV !== 'production') { - warning( - this.__didWarnIsMounted, - '%s: isMounted is deprecated. Instead, make sure to clean up ' + - 'subscriptions and pending requests in componentWillUnmount to ' + - 'prevent memory leaks.', - (this.constructor && this.constructor.displayName) || - this.name || - 'Component' - ); - this.__didWarnIsMounted = true; - } - return !!this.__isMounted; - } - }; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); +}; - var ReactClassComponent = function() {}; - _assign( - ReactClassComponent.prototype, - ReactComponent.prototype, - ReactClassMixin - ); +Form.propTypes = propTypes$47; +Form.defaultProps = defaultProps$46; - /** - * Creates a composite component class given a class specification. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createclass - * - * @param {object} spec Class specification (which must define `render`). - * @return {function} Component constructor function. - * @public - */ - function createClass(spec) { - // To keep our warnings more understandable, we'll use a little hack here to - // ensure that Constructor.name !== 'Constructor'. This makes sure we don't - // unnecessarily identify a class without displayName as 'Constructor'. - var Constructor = identity(function(props, context, updater) { - // This constructor gets overridden by mocks. The argument is used - // by mocks to assert on what gets mounted. +var propTypes$48 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - if (process.env.NODE_ENV !== 'production') { - warning( - this instanceof Constructor, - 'Something is calling a React component directly. Use a factory or ' + - 'JSX instead. See: https://fb.me/react-legacyfactory' - ); - } +var defaultProps$47 = { + tag: 'div' +}; - // Wire up auto-binding - if (this.__reactAutoBindPairs.length) { - bindAutoBindMethods(this); - } +var FormFeedback = function FormFeedback(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - this.props = props; - this.context = context; - this.refs = emptyObject; - this.updater = updater || ReactNoopUpdateQueue; - this.state = null; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'form-control-feedback'), cssModule); - // ReactClasses doesn't have constructors. Instead, they use the - // getInitialState and componentWillMount methods for initialization. + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - var initialState = this.getInitialState ? this.getInitialState() : null; - if (process.env.NODE_ENV !== 'production') { - // We allow auto-mocks to proceed as if they're returning null. - if ( - initialState === undefined && - this.getInitialState._isMockFunction - ) { - // This is probably bad practice. Consider warning here and - // deprecating this convenience. - initialState = null; - } - } - _invariant( - typeof initialState === 'object' && !Array.isArray(initialState), - '%s.getInitialState(): must return an object or null', - Constructor.displayName || 'ReactCompositeComponent' - ); +FormFeedback.propTypes = propTypes$48; +FormFeedback.defaultProps = defaultProps$47; - this.state = initialState; - }); - Constructor.prototype = new ReactClassComponent(); - Constructor.prototype.constructor = Constructor; - Constructor.prototype.__reactAutoBindPairs = []; +var propTypes$49 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + row: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - injectedMixins.forEach(mixSpecIntoComponent.bind(null, Constructor)); +var defaultProps$48 = { + tag: 'div' +}; - mixSpecIntoComponent(Constructor, IsMountedPreMixin); - mixSpecIntoComponent(Constructor, spec); - mixSpecIntoComponent(Constructor, IsMountedPostMixin); +var FormGroup = function FormGroup(props) { + var className = props.className, + cssModule = props.cssModule, + row = props.row, + disabled = props.disabled, + color = props.color, + check = props.check, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'row', 'disabled', 'color', 'check', 'tag']); - // Initialize the defaultProps property after all mixins have been merged. - if (Constructor.getDefaultProps) { - Constructor.defaultProps = Constructor.getDefaultProps(); - } - if (process.env.NODE_ENV !== 'production') { - // This is a tag to indicate that the use of these method names is ok, - // since it's used with createClass. If it's not, then it's likely a - // mistake so we'll warn you to use the static property, property - // initializer or constructor respectively. - if (Constructor.getDefaultProps) { - Constructor.getDefaultProps.isReactClassApproved = {}; - } - if (Constructor.prototype.getInitialState) { - Constructor.prototype.getInitialState.isReactClassApproved = {}; - } - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, color ? 'has-' + color : false, row ? 'row' : false, check ? 'form-check' : 'form-group', check && disabled ? 'disabled' : false), cssModule); - _invariant( - Constructor.prototype.render, - 'createClass(...): Class specification must implement a `render` method.' - ); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (process.env.NODE_ENV !== 'production') { - warning( - !Constructor.prototype.componentShouldUpdate, - '%s has a method called ' + - 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + - 'The name is phrased as a question because the function is ' + - 'expected to return a value.', - spec.displayName || 'A component' - ); - warning( - !Constructor.prototype.componentWillRecieveProps, - '%s has a method called ' + - 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', - spec.displayName || 'A component' - ); - } +FormGroup.propTypes = propTypes$49; +FormGroup.defaultProps = defaultProps$48; - // Reduce time spent doing lookups by setting these on the prototype. - for (var methodName in ReactClassInterface) { - if (!Constructor.prototype[methodName]) { - Constructor.prototype[methodName] = null; - } - } +var propTypes$50 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - return Constructor; - } +var defaultProps$49 = { + tag: 'small' +}; - return createClass; -} +var FormText = function FormText(props) { + var className = props.className, + cssModule = props.cssModule, + inline = props.inline, + color = props.color, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'color', 'tag']); -module.exports = factory; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, !inline ? 'form-text' : false, color ? 'text-' + color : false), cssModule); -/***/ }), -/* 114 */, -/* 115 */, -/* 116 */, -/* 117 */ -/***/ (function(module, exports, __webpack_require__) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -// style-loader: Adds some css to the DOM by adding a <style> tag +FormText.propTypes = propTypes$50; +FormText.defaultProps = defaultProps$49; -// load the styles -var content = __webpack_require__(118); -if(typeof content === 'string') content = [[module.i, content, '']]; -// Prepare cssTransformation -var transform; +/* eslint react/prefer-stateless-function: 0 */ -var options = {} -options.transform = transform -// add the styles to the DOM -var update = __webpack_require__(73)(content, options); -if(content.locals) module.exports = content.locals; -// Hot Module Replacement -if(false) { - // When the styles change, update the <style> tags - if(!content.locals) { - module.hot.accept("!!../../../css-loader/index.js!./bootstrap.css", function() { - var newContent = require("!!../../../css-loader/index.js!./bootstrap.css"); - if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; - update(newContent); - }); - } - // When the module is disposed, remove the <style> tags - module.hot.dispose(function() { update(); }); -} +var propTypes$51 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + state: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + static: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + addon: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -/***/ }), -/* 118 */ -/***/ (function(module, exports, __webpack_require__) { +var defaultProps$50 = { + tag: 'p', + type: 'text' +}; -exports = module.exports = __webpack_require__(72)(undefined); -// imports +var Input = function (_React$Component) { + inherits(Input, _React$Component); + function Input() { + classCallCheck(this, Input); + return possibleConstructorReturn(this, (Input.__proto__ || Object.getPrototypeOf(Input)).apply(this, arguments)); + } -// module -exports.push([module.i, "/*!\n * Bootstrap v4.0.0-alpha.6 (https://getbootstrap.com)\n * Copyright 2011-2017 The Bootstrap Authors\n * Copyright 2011-2017 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n */\n/*! normalize.css v5.0.0 | MIT License | github.com/necolas/normalize.css */\nhtml {\n font-family: sans-serif;\n line-height: 1.15;\n -ms-text-size-adjust: 100%;\n -webkit-text-size-adjust: 100%;\n}\n\nbody {\n margin: 0;\n}\n\narticle,\naside,\nfooter,\nheader,\nnav,\nsection {\n display: block;\n}\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\nfigcaption,\nfigure,\nmain {\n display: block;\n}\n\nfigure {\n margin: 1em 40px;\n}\n\nhr {\n -webkit-box-sizing: content-box;\n box-sizing: content-box;\n height: 0;\n overflow: visible;\n}\n\npre {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\na {\n background-color: transparent;\n -webkit-text-decoration-skip: objects;\n}\n\na:active,\na:hover {\n outline-width: 0;\n}\n\nabbr[title] {\n border-bottom: none;\n text-decoration: underline;\n text-decoration: underline dotted;\n}\n\nb,\nstrong {\n font-weight: inherit;\n}\n\nb,\nstrong {\n font-weight: bolder;\n}\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\ndfn {\n font-style: italic;\n}\n\nmark {\n background-color: #ff0;\n color: #000;\n}\n\nsmall {\n font-size: 80%;\n}\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\naudio,\nvideo {\n display: inline-block;\n}\n\naudio:not([controls]) {\n display: none;\n height: 0;\n}\n\nimg {\n border-style: none;\n}\n\nsvg:not(:root) {\n overflow: hidden;\n}\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: sans-serif;\n font-size: 100%;\n line-height: 1.15;\n margin: 0;\n}\n\nbutton,\ninput {\n overflow: visible;\n}\n\nbutton,\nselect {\n text-transform: none;\n}\n\nbutton,\nhtml [type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\nfieldset {\n border: 1px solid #c0c0c0;\n margin: 0 2px;\n padding: 0.35em 0.625em 0.75em;\n}\n\nlegend {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: inherit;\n display: table;\n max-width: 100%;\n padding: 0;\n white-space: normal;\n}\n\nprogress {\n display: inline-block;\n vertical-align: baseline;\n}\n\ntextarea {\n overflow: auto;\n}\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n padding: 0;\n}\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n[type=\"search\"] {\n -webkit-appearance: textfield;\n outline-offset: -2px;\n}\n\n[type=\"search\"]::-webkit-search-cancel-button,\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n::-webkit-file-upload-button {\n -webkit-appearance: button;\n font: inherit;\n}\n\ndetails,\nmenu {\n display: block;\n}\n\nsummary {\n display: list-item;\n}\n\ncanvas {\n display: inline-block;\n}\n\ntemplate {\n display: none;\n}\n\n[hidden] {\n display: none;\n}\n\n@media print {\n *,\n *::before,\n *::after,\n p::first-letter,\n div::first-letter,\n blockquote::first-letter,\n li::first-letter,\n p::first-line,\n div::first-line,\n blockquote::first-line,\n li::first-line {\n text-shadow: none !important;\n -webkit-box-shadow: none !important;\n box-shadow: none !important;\n }\n a,\n a:visited {\n text-decoration: underline;\n }\n abbr[title]::after {\n content: \" (\" attr(title) \")\";\n }\n pre {\n white-space: pre-wrap !important;\n }\n pre,\n blockquote {\n border: 1px solid #999;\n page-break-inside: avoid;\n }\n thead {\n display: table-header-group;\n }\n tr,\n img {\n page-break-inside: avoid;\n }\n p,\n h2,\n h3 {\n orphans: 3;\n widows: 3;\n }\n h2,\n h3 {\n page-break-after: avoid;\n }\n .navbar {\n display: none;\n }\n .badge {\n border: 1px solid #000;\n }\n .table {\n border-collapse: collapse !important;\n }\n .table td,\n .table th {\n background-color: #fff !important;\n }\n .table-bordered th,\n .table-bordered td {\n border: 1px solid #ddd !important;\n }\n}\n\nhtml {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n}\n\n*,\n*::before,\n*::after {\n -webkit-box-sizing: inherit;\n box-sizing: inherit;\n}\n\n@-ms-viewport {\n width: device-width;\n}\n\nhtml {\n -ms-overflow-style: scrollbar;\n -webkit-tap-highlight-color: transparent;\n}\n\nbody {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.5;\n color: #292b2c;\n background-color: #fff;\n}\n\n[tabindex=\"-1\"]:focus {\n outline: none !important;\n}\n\nh1, h2, h3, h4, h5, h6 {\n margin-top: 0;\n margin-bottom: .5rem;\n}\n\np {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nabbr[title],\nabbr[data-original-title] {\n cursor: help;\n}\n\naddress {\n margin-bottom: 1rem;\n font-style: normal;\n line-height: inherit;\n}\n\nol,\nul,\ndl {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nol ol,\nul ul,\nol ul,\nul ol {\n margin-bottom: 0;\n}\n\ndt {\n font-weight: bold;\n}\n\ndd {\n margin-bottom: .5rem;\n margin-left: 0;\n}\n\nblockquote {\n margin: 0 0 1rem;\n}\n\na {\n color: #0275d8;\n text-decoration: none;\n}\n\na:focus, a:hover {\n color: #014c8c;\n text-decoration: underline;\n}\n\na:not([href]):not([tabindex]) {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus, a:not([href]):not([tabindex]):hover {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus {\n outline: 0;\n}\n\npre {\n margin-top: 0;\n margin-bottom: 1rem;\n overflow: auto;\n}\n\nfigure {\n margin: 0 0 1rem;\n}\n\nimg {\n vertical-align: middle;\n}\n\n[role=\"button\"] {\n cursor: pointer;\n}\n\na,\narea,\nbutton,\n[role=\"button\"],\ninput,\nlabel,\nselect,\nsummary,\ntextarea {\n -ms-touch-action: manipulation;\n touch-action: manipulation;\n}\n\ntable {\n border-collapse: collapse;\n background-color: transparent;\n}\n\ncaption {\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n color: #636c72;\n text-align: left;\n caption-side: bottom;\n}\n\nth {\n text-align: left;\n}\n\nlabel {\n display: inline-block;\n margin-bottom: .5rem;\n}\n\nbutton:focus {\n outline: 1px dotted;\n outline: 5px auto -webkit-focus-ring-color;\n}\n\ninput,\nbutton,\nselect,\ntextarea {\n line-height: inherit;\n}\n\ninput[type=\"radio\"]:disabled,\ninput[type=\"checkbox\"]:disabled {\n cursor: not-allowed;\n}\n\ninput[type=\"date\"],\ninput[type=\"time\"],\ninput[type=\"datetime-local\"],\ninput[type=\"month\"] {\n -webkit-appearance: listbox;\n}\n\ntextarea {\n resize: vertical;\n}\n\nfieldset {\n min-width: 0;\n padding: 0;\n margin: 0;\n border: 0;\n}\n\nlegend {\n display: block;\n width: 100%;\n padding: 0;\n margin-bottom: .5rem;\n font-size: 1.5rem;\n line-height: inherit;\n}\n\ninput[type=\"search\"] {\n -webkit-appearance: none;\n}\n\noutput {\n display: inline-block;\n}\n\n[hidden] {\n display: none !important;\n}\n\nh1, h2, h3, h4, h5, h6,\n.h1, .h2, .h3, .h4, .h5, .h6 {\n margin-bottom: 0.5rem;\n font-family: inherit;\n font-weight: 500;\n line-height: 1.1;\n color: inherit;\n}\n\nh1, .h1 {\n font-size: 2.5rem;\n}\n\nh2, .h2 {\n font-size: 2rem;\n}\n\nh3, .h3 {\n font-size: 1.75rem;\n}\n\nh4, .h4 {\n font-size: 1.5rem;\n}\n\nh5, .h5 {\n font-size: 1.25rem;\n}\n\nh6, .h6 {\n font-size: 1rem;\n}\n\n.lead {\n font-size: 1.25rem;\n font-weight: 300;\n}\n\n.display-1 {\n font-size: 6rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-2 {\n font-size: 5.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-3 {\n font-size: 4.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-4 {\n font-size: 3.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\nhr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n border: 0;\n border-top: 1px solid rgba(0, 0, 0, 0.1);\n}\n\nsmall,\n.small {\n font-size: 80%;\n font-weight: normal;\n}\n\nmark,\n.mark {\n padding: 0.2em;\n background-color: #fcf8e3;\n}\n\n.list-unstyled {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline-item {\n display: inline-block;\n}\n\n.list-inline-item:not(:last-child) {\n margin-right: 5px;\n}\n\n.initialism {\n font-size: 90%;\n text-transform: uppercase;\n}\n\n.blockquote {\n padding: 0.5rem 1rem;\n margin-bottom: 1rem;\n font-size: 1.25rem;\n border-left: 0.25rem solid #eceeef;\n}\n\n.blockquote-footer {\n display: block;\n font-size: 80%;\n color: #636c72;\n}\n\n.blockquote-footer::before {\n content: \"\\2014 \\A0\";\n}\n\n.blockquote-reverse {\n padding-right: 1rem;\n padding-left: 0;\n text-align: right;\n border-right: 0.25rem solid #eceeef;\n border-left: 0;\n}\n\n.blockquote-reverse .blockquote-footer::before {\n content: \"\";\n}\n\n.blockquote-reverse .blockquote-footer::after {\n content: \"\\A0 \\2014\";\n}\n\n.img-fluid {\n max-width: 100%;\n height: auto;\n}\n\n.img-thumbnail {\n padding: 0.25rem;\n background-color: #fff;\n border: 1px solid #ddd;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n max-width: 100%;\n height: auto;\n}\n\n.figure {\n display: inline-block;\n}\n\n.figure-img {\n margin-bottom: 0.5rem;\n line-height: 1;\n}\n\n.figure-caption {\n font-size: 90%;\n color: #636c72;\n}\n\ncode,\nkbd,\npre,\nsamp {\n font-family: Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;\n}\n\ncode {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #bd4147;\n background-color: #f7f7f9;\n border-radius: 0.25rem;\n}\n\na > code {\n padding: 0;\n color: inherit;\n background-color: inherit;\n}\n\nkbd {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #fff;\n background-color: #292b2c;\n border-radius: 0.2rem;\n}\n\nkbd kbd {\n padding: 0;\n font-size: 100%;\n font-weight: bold;\n}\n\npre {\n display: block;\n margin-top: 0;\n margin-bottom: 1rem;\n font-size: 90%;\n color: #292b2c;\n}\n\npre code {\n padding: 0;\n font-size: inherit;\n color: inherit;\n background-color: transparent;\n border-radius: 0;\n}\n\n.pre-scrollable {\n max-height: 340px;\n overflow-y: scroll;\n}\n\n.container {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .container {\n width: 540px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n width: 720px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n width: 960px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n width: 1140px;\n max-width: 100%;\n }\n}\n\n.container-fluid {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.row {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: wrap;\n -ms-flex-wrap: wrap;\n flex-wrap: wrap;\n margin-right: -15px;\n margin-left: -15px;\n}\n\n@media (min-width: 576px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 768px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 992px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 1200px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n.no-gutters {\n margin-right: 0;\n margin-left: 0;\n}\n\n.no-gutters > .col,\n.no-gutters > [class*=\"col-\"] {\n padding-right: 0;\n padding-left: 0;\n}\n\n.col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n position: relative;\n width: 100%;\n min-height: 1px;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.col {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n}\n\n.col-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n}\n\n.col-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n}\n\n.col-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n}\n\n.col-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n}\n\n.col-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n}\n\n.col-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n}\n\n.col-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n}\n\n.col-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n}\n\n.col-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n}\n\n.col-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n}\n\n.col-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n}\n\n.col-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n}\n\n.col-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n}\n\n.pull-0 {\n right: auto;\n}\n\n.pull-1 {\n right: 8.333333%;\n}\n\n.pull-2 {\n right: 16.666667%;\n}\n\n.pull-3 {\n right: 25%;\n}\n\n.pull-4 {\n right: 33.333333%;\n}\n\n.pull-5 {\n right: 41.666667%;\n}\n\n.pull-6 {\n right: 50%;\n}\n\n.pull-7 {\n right: 58.333333%;\n}\n\n.pull-8 {\n right: 66.666667%;\n}\n\n.pull-9 {\n right: 75%;\n}\n\n.pull-10 {\n right: 83.333333%;\n}\n\n.pull-11 {\n right: 91.666667%;\n}\n\n.pull-12 {\n right: 100%;\n}\n\n.push-0 {\n left: auto;\n}\n\n.push-1 {\n left: 8.333333%;\n}\n\n.push-2 {\n left: 16.666667%;\n}\n\n.push-3 {\n left: 25%;\n}\n\n.push-4 {\n left: 33.333333%;\n}\n\n.push-5 {\n left: 41.666667%;\n}\n\n.push-6 {\n left: 50%;\n}\n\n.push-7 {\n left: 58.333333%;\n}\n\n.push-8 {\n left: 66.666667%;\n}\n\n.push-9 {\n left: 75%;\n}\n\n.push-10 {\n left: 83.333333%;\n}\n\n.push-11 {\n left: 91.666667%;\n}\n\n.push-12 {\n left: 100%;\n}\n\n.offset-1 {\n margin-left: 8.333333%;\n}\n\n.offset-2 {\n margin-left: 16.666667%;\n}\n\n.offset-3 {\n margin-left: 25%;\n}\n\n.offset-4 {\n margin-left: 33.333333%;\n}\n\n.offset-5 {\n margin-left: 41.666667%;\n}\n\n.offset-6 {\n margin-left: 50%;\n}\n\n.offset-7 {\n margin-left: 58.333333%;\n}\n\n.offset-8 {\n margin-left: 66.666667%;\n}\n\n.offset-9 {\n margin-left: 75%;\n}\n\n.offset-10 {\n margin-left: 83.333333%;\n}\n\n.offset-11 {\n margin-left: 91.666667%;\n}\n\n@media (min-width: 576px) {\n .col-sm {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-sm-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-sm-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-sm-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-sm-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-sm-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-sm-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-sm-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-sm-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-sm-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-sm-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-sm-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-sm-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-sm-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-sm-0 {\n right: auto;\n }\n .pull-sm-1 {\n right: 8.333333%;\n }\n .pull-sm-2 {\n right: 16.666667%;\n }\n .pull-sm-3 {\n right: 25%;\n }\n .pull-sm-4 {\n right: 33.333333%;\n }\n .pull-sm-5 {\n right: 41.666667%;\n }\n .pull-sm-6 {\n right: 50%;\n }\n .pull-sm-7 {\n right: 58.333333%;\n }\n .pull-sm-8 {\n right: 66.666667%;\n }\n .pull-sm-9 {\n right: 75%;\n }\n .pull-sm-10 {\n right: 83.333333%;\n }\n .pull-sm-11 {\n right: 91.666667%;\n }\n .pull-sm-12 {\n right: 100%;\n }\n .push-sm-0 {\n left: auto;\n }\n .push-sm-1 {\n left: 8.333333%;\n }\n .push-sm-2 {\n left: 16.666667%;\n }\n .push-sm-3 {\n left: 25%;\n }\n .push-sm-4 {\n left: 33.333333%;\n }\n .push-sm-5 {\n left: 41.666667%;\n }\n .push-sm-6 {\n left: 50%;\n }\n .push-sm-7 {\n left: 58.333333%;\n }\n .push-sm-8 {\n left: 66.666667%;\n }\n .push-sm-9 {\n left: 75%;\n }\n .push-sm-10 {\n left: 83.333333%;\n }\n .push-sm-11 {\n left: 91.666667%;\n }\n .push-sm-12 {\n left: 100%;\n }\n .offset-sm-0 {\n margin-left: 0%;\n }\n .offset-sm-1 {\n margin-left: 8.333333%;\n }\n .offset-sm-2 {\n margin-left: 16.666667%;\n }\n .offset-sm-3 {\n margin-left: 25%;\n }\n .offset-sm-4 {\n margin-left: 33.333333%;\n }\n .offset-sm-5 {\n margin-left: 41.666667%;\n }\n .offset-sm-6 {\n margin-left: 50%;\n }\n .offset-sm-7 {\n margin-left: 58.333333%;\n }\n .offset-sm-8 {\n margin-left: 66.666667%;\n }\n .offset-sm-9 {\n margin-left: 75%;\n }\n .offset-sm-10 {\n margin-left: 83.333333%;\n }\n .offset-sm-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 768px) {\n .col-md {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-md-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-md-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-md-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-md-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-md-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-md-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-md-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-md-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-md-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-md-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-md-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-md-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-md-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-md-0 {\n right: auto;\n }\n .pull-md-1 {\n right: 8.333333%;\n }\n .pull-md-2 {\n right: 16.666667%;\n }\n .pull-md-3 {\n right: 25%;\n }\n .pull-md-4 {\n right: 33.333333%;\n }\n .pull-md-5 {\n right: 41.666667%;\n }\n .pull-md-6 {\n right: 50%;\n }\n .pull-md-7 {\n right: 58.333333%;\n }\n .pull-md-8 {\n right: 66.666667%;\n }\n .pull-md-9 {\n right: 75%;\n }\n .pull-md-10 {\n right: 83.333333%;\n }\n .pull-md-11 {\n right: 91.666667%;\n }\n .pull-md-12 {\n right: 100%;\n }\n .push-md-0 {\n left: auto;\n }\n .push-md-1 {\n left: 8.333333%;\n }\n .push-md-2 {\n left: 16.666667%;\n }\n .push-md-3 {\n left: 25%;\n }\n .push-md-4 {\n left: 33.333333%;\n }\n .push-md-5 {\n left: 41.666667%;\n }\n .push-md-6 {\n left: 50%;\n }\n .push-md-7 {\n left: 58.333333%;\n }\n .push-md-8 {\n left: 66.666667%;\n }\n .push-md-9 {\n left: 75%;\n }\n .push-md-10 {\n left: 83.333333%;\n }\n .push-md-11 {\n left: 91.666667%;\n }\n .push-md-12 {\n left: 100%;\n }\n .offset-md-0 {\n margin-left: 0%;\n }\n .offset-md-1 {\n margin-left: 8.333333%;\n }\n .offset-md-2 {\n margin-left: 16.666667%;\n }\n .offset-md-3 {\n margin-left: 25%;\n }\n .offset-md-4 {\n margin-left: 33.333333%;\n }\n .offset-md-5 {\n margin-left: 41.666667%;\n }\n .offset-md-6 {\n margin-left: 50%;\n }\n .offset-md-7 {\n margin-left: 58.333333%;\n }\n .offset-md-8 {\n margin-left: 66.666667%;\n }\n .offset-md-9 {\n margin-left: 75%;\n }\n .offset-md-10 {\n margin-left: 83.333333%;\n }\n .offset-md-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 992px) {\n .col-lg {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-lg-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-lg-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-lg-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-lg-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-lg-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-lg-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-lg-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-lg-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-lg-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-lg-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-lg-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-lg-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-lg-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-lg-0 {\n right: auto;\n }\n .pull-lg-1 {\n right: 8.333333%;\n }\n .pull-lg-2 {\n right: 16.666667%;\n }\n .pull-lg-3 {\n right: 25%;\n }\n .pull-lg-4 {\n right: 33.333333%;\n }\n .pull-lg-5 {\n right: 41.666667%;\n }\n .pull-lg-6 {\n right: 50%;\n }\n .pull-lg-7 {\n right: 58.333333%;\n }\n .pull-lg-8 {\n right: 66.666667%;\n }\n .pull-lg-9 {\n right: 75%;\n }\n .pull-lg-10 {\n right: 83.333333%;\n }\n .pull-lg-11 {\n right: 91.666667%;\n }\n .pull-lg-12 {\n right: 100%;\n }\n .push-lg-0 {\n left: auto;\n }\n .push-lg-1 {\n left: 8.333333%;\n }\n .push-lg-2 {\n left: 16.666667%;\n }\n .push-lg-3 {\n left: 25%;\n }\n .push-lg-4 {\n left: 33.333333%;\n }\n .push-lg-5 {\n left: 41.666667%;\n }\n .push-lg-6 {\n left: 50%;\n }\n .push-lg-7 {\n left: 58.333333%;\n }\n .push-lg-8 {\n left: 66.666667%;\n }\n .push-lg-9 {\n left: 75%;\n }\n .push-lg-10 {\n left: 83.333333%;\n }\n .push-lg-11 {\n left: 91.666667%;\n }\n .push-lg-12 {\n left: 100%;\n }\n .offset-lg-0 {\n margin-left: 0%;\n }\n .offset-lg-1 {\n margin-left: 8.333333%;\n }\n .offset-lg-2 {\n margin-left: 16.666667%;\n }\n .offset-lg-3 {\n margin-left: 25%;\n }\n .offset-lg-4 {\n margin-left: 33.333333%;\n }\n .offset-lg-5 {\n margin-left: 41.666667%;\n }\n .offset-lg-6 {\n margin-left: 50%;\n }\n .offset-lg-7 {\n margin-left: 58.333333%;\n }\n .offset-lg-8 {\n margin-left: 66.666667%;\n }\n .offset-lg-9 {\n margin-left: 75%;\n }\n .offset-lg-10 {\n margin-left: 83.333333%;\n }\n .offset-lg-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 1200px) {\n .col-xl {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-xl-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-xl-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-xl-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-xl-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-xl-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-xl-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-xl-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-xl-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-xl-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-xl-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-xl-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-xl-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-xl-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-xl-0 {\n right: auto;\n }\n .pull-xl-1 {\n right: 8.333333%;\n }\n .pull-xl-2 {\n right: 16.666667%;\n }\n .pull-xl-3 {\n right: 25%;\n }\n .pull-xl-4 {\n right: 33.333333%;\n }\n .pull-xl-5 {\n right: 41.666667%;\n }\n .pull-xl-6 {\n right: 50%;\n }\n .pull-xl-7 {\n right: 58.333333%;\n }\n .pull-xl-8 {\n right: 66.666667%;\n }\n .pull-xl-9 {\n right: 75%;\n }\n .pull-xl-10 {\n right: 83.333333%;\n }\n .pull-xl-11 {\n right: 91.666667%;\n }\n .pull-xl-12 {\n right: 100%;\n }\n .push-xl-0 {\n left: auto;\n }\n .push-xl-1 {\n left: 8.333333%;\n }\n .push-xl-2 {\n left: 16.666667%;\n }\n .push-xl-3 {\n left: 25%;\n }\n .push-xl-4 {\n left: 33.333333%;\n }\n .push-xl-5 {\n left: 41.666667%;\n }\n .push-xl-6 {\n left: 50%;\n }\n .push-xl-7 {\n left: 58.333333%;\n }\n .push-xl-8 {\n left: 66.666667%;\n }\n .push-xl-9 {\n left: 75%;\n }\n .push-xl-10 {\n left: 83.333333%;\n }\n .push-xl-11 {\n left: 91.666667%;\n }\n .push-xl-12 {\n left: 100%;\n }\n .offset-xl-0 {\n margin-left: 0%;\n }\n .offset-xl-1 {\n margin-left: 8.333333%;\n }\n .offset-xl-2 {\n margin-left: 16.666667%;\n }\n .offset-xl-3 {\n margin-left: 25%;\n }\n .offset-xl-4 {\n margin-left: 33.333333%;\n }\n .offset-xl-5 {\n margin-left: 41.666667%;\n }\n .offset-xl-6 {\n margin-left: 50%;\n }\n .offset-xl-7 {\n margin-left: 58.333333%;\n }\n .offset-xl-8 {\n margin-left: 66.666667%;\n }\n .offset-xl-9 {\n margin-left: 75%;\n }\n .offset-xl-10 {\n margin-left: 83.333333%;\n }\n .offset-xl-11 {\n margin-left: 91.666667%;\n }\n}\n\n.table {\n width: 100%;\n max-width: 100%;\n margin-bottom: 1rem;\n}\n\n.table th,\n.table td {\n padding: 0.75rem;\n vertical-align: top;\n border-top: 1px solid #eceeef;\n}\n\n.table thead th {\n vertical-align: bottom;\n border-bottom: 2px solid #eceeef;\n}\n\n.table tbody + tbody {\n border-top: 2px solid #eceeef;\n}\n\n.table .table {\n background-color: #fff;\n}\n\n.table-sm th,\n.table-sm td {\n padding: 0.3rem;\n}\n\n.table-bordered {\n border: 1px solid #eceeef;\n}\n\n.table-bordered th,\n.table-bordered td {\n border: 1px solid #eceeef;\n}\n\n.table-bordered thead th,\n.table-bordered thead td {\n border-bottom-width: 2px;\n}\n\n.table-striped tbody tr:nth-of-type(odd) {\n background-color: rgba(0, 0, 0, 0.05);\n}\n\n.table-hover tbody tr:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-active,\n.table-active > th,\n.table-active > td {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover > td,\n.table-hover .table-active:hover > th {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-success,\n.table-success > th,\n.table-success > td {\n background-color: #dff0d8;\n}\n\n.table-hover .table-success:hover {\n background-color: #d0e9c6;\n}\n\n.table-hover .table-success:hover > td,\n.table-hover .table-success:hover > th {\n background-color: #d0e9c6;\n}\n\n.table-info,\n.table-info > th,\n.table-info > td {\n background-color: #d9edf7;\n}\n\n.table-hover .table-info:hover {\n background-color: #c4e3f3;\n}\n\n.table-hover .table-info:hover > td,\n.table-hover .table-info:hover > th {\n background-color: #c4e3f3;\n}\n\n.table-warning,\n.table-warning > th,\n.table-warning > td {\n background-color: #fcf8e3;\n}\n\n.table-hover .table-warning:hover {\n background-color: #faf2cc;\n}\n\n.table-hover .table-warning:hover > td,\n.table-hover .table-warning:hover > th {\n background-color: #faf2cc;\n}\n\n.table-danger,\n.table-danger > th,\n.table-danger > td {\n background-color: #f2dede;\n}\n\n.table-hover .table-danger:hover {\n background-color: #ebcccc;\n}\n\n.table-hover .table-danger:hover > td,\n.table-hover .table-danger:hover > th {\n background-color: #ebcccc;\n}\n\n.thead-inverse th {\n color: #fff;\n background-color: #292b2c;\n}\n\n.thead-default th {\n color: #464a4c;\n background-color: #eceeef;\n}\n\n.table-inverse {\n color: #fff;\n background-color: #292b2c;\n}\n\n.table-inverse th,\n.table-inverse td,\n.table-inverse thead th {\n border-color: #fff;\n}\n\n.table-inverse.table-bordered {\n border: 0;\n}\n\n.table-responsive {\n display: block;\n width: 100%;\n overflow-x: auto;\n -ms-overflow-style: -ms-autohiding-scrollbar;\n}\n\n.table-responsive.table-bordered {\n border: 0;\n}\n\n.form-control {\n display: block;\n width: 100%;\n padding: 0.5rem 0.75rem;\n font-size: 1rem;\n line-height: 1.25;\n color: #464a4c;\n background-color: #fff;\n background-image: none;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -webkit-transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n -o-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n}\n\n.form-control::-ms-expand {\n background-color: transparent;\n border: 0;\n}\n\n.form-control:focus {\n color: #464a4c;\n background-color: #fff;\n border-color: #5cb3fd;\n outline: none;\n}\n\n.form-control::-webkit-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::-moz-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:-ms-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:disabled, .form-control[readonly] {\n background-color: #eceeef;\n opacity: 1;\n}\n\n.form-control:disabled {\n cursor: not-allowed;\n}\n\nselect.form-control:not([size]):not([multiple]) {\n height: calc(2.25rem + 2px);\n}\n\nselect.form-control:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.form-control-file,\n.form-control-range {\n display: block;\n}\n\n.col-form-label {\n padding-top: calc(0.5rem - 1px * 2);\n padding-bottom: calc(0.5rem - 1px * 2);\n margin-bottom: 0;\n}\n\n.col-form-label-lg {\n padding-top: calc(0.75rem - 1px * 2);\n padding-bottom: calc(0.75rem - 1px * 2);\n font-size: 1.25rem;\n}\n\n.col-form-label-sm {\n padding-top: calc(0.25rem - 1px * 2);\n padding-bottom: calc(0.25rem - 1px * 2);\n font-size: 0.875rem;\n}\n\n.col-form-legend {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n font-size: 1rem;\n}\n\n.form-control-static {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n line-height: 1.25;\n border: solid transparent;\n border-width: 1px 0;\n}\n\n.form-control-static.form-control-sm, .input-group-sm > .form-control-static.form-control,\n.input-group-sm > .form-control-static.input-group-addon,\n.input-group-sm > .input-group-btn > .form-control-static.btn, .form-control-static.form-control-lg, .input-group-lg > .form-control-static.form-control,\n.input-group-lg > .form-control-static.input-group-addon,\n.input-group-lg > .input-group-btn > .form-control-static.btn {\n padding-right: 0;\n padding-left: 0;\n}\n\n.form-control-sm, .input-group-sm > .form-control,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\nselect.form-control-sm:not([size]):not([multiple]), .input-group-sm > select.form-control:not([size]):not([multiple]),\n.input-group-sm > select.input-group-addon:not([size]):not([multiple]),\n.input-group-sm > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 1.8125rem;\n}\n\n.form-control-lg, .input-group-lg > .form-control,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\nselect.form-control-lg:not([size]):not([multiple]), .input-group-lg > select.form-control:not([size]):not([multiple]),\n.input-group-lg > select.input-group-addon:not([size]):not([multiple]),\n.input-group-lg > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 3.166667rem;\n}\n\n.form-group {\n margin-bottom: 1rem;\n}\n\n.form-text {\n display: block;\n margin-top: 0.25rem;\n}\n\n.form-check {\n position: relative;\n display: block;\n margin-bottom: 0.5rem;\n}\n\n.form-check.disabled .form-check-label {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.form-check-label {\n padding-left: 1.25rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.form-check-input {\n position: absolute;\n margin-top: 0.25rem;\n margin-left: -1.25rem;\n}\n\n.form-check-input:only-child {\n position: static;\n}\n\n.form-check-inline {\n display: inline-block;\n}\n\n.form-check-inline .form-check-label {\n vertical-align: middle;\n}\n\n.form-check-inline + .form-check-inline {\n margin-left: 0.75rem;\n}\n\n.form-control-feedback {\n margin-top: 0.25rem;\n}\n\n.form-control-success,\n.form-control-warning,\n.form-control-danger {\n padding-right: 2.25rem;\n background-repeat: no-repeat;\n background-position: center right 0.5625rem;\n -webkit-background-size: 1.125rem 1.125rem;\n background-size: 1.125rem 1.125rem;\n}\n\n.has-success .form-control-feedback,\n.has-success .form-control-label,\n.has-success .col-form-label,\n.has-success .form-check-label,\n.has-success .custom-control {\n color: #5cb85c;\n}\n\n.has-success .form-control {\n border-color: #5cb85c;\n}\n\n.has-success .input-group-addon {\n color: #5cb85c;\n border-color: #5cb85c;\n background-color: #eaf6ea;\n}\n\n.has-success .form-control-success {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%235cb85c' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3E%3C/svg%3E\");\n}\n\n.has-warning .form-control-feedback,\n.has-warning .form-control-label,\n.has-warning .col-form-label,\n.has-warning .form-check-label,\n.has-warning .custom-control {\n color: #f0ad4e;\n}\n\n.has-warning .form-control {\n border-color: #f0ad4e;\n}\n\n.has-warning .input-group-addon {\n color: #f0ad4e;\n border-color: #f0ad4e;\n background-color: white;\n}\n\n.has-warning .form-control-warning {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23f0ad4e' d='M4.4 5.324h-.8v-2.46h.8zm0 1.42h-.8V5.89h.8zM3.76.63L.04 7.075c-.115.2.016.425.26.426h7.397c.242 0 .372-.226.258-.426C6.726 4.924 5.47 2.79 4.253.63c-.113-.174-.39-.174-.494 0z'/%3E%3C/svg%3E\");\n}\n\n.has-danger .form-control-feedback,\n.has-danger .form-control-label,\n.has-danger .col-form-label,\n.has-danger .form-check-label,\n.has-danger .custom-control {\n color: #d9534f;\n}\n\n.has-danger .form-control {\n border-color: #d9534f;\n}\n\n.has-danger .input-group-addon {\n color: #d9534f;\n border-color: #d9534f;\n background-color: #fdf7f7;\n}\n\n.has-danger .form-control-danger {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23d9534f' viewBox='-2 -2 7 7'%3E%3Cpath stroke='%23d9534f' d='M0 0l3 3m0-3L0 3'/%3E%3Ccircle r='.5'/%3E%3Ccircle cx='3' r='.5'/%3E%3Ccircle cy='3' r='.5'/%3E%3Ccircle cx='3' cy='3' r='.5'/%3E%3C/svg%3E\");\n}\n\n.form-inline {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.form-inline .form-check {\n width: 100%;\n}\n\n@media (min-width: 576px) {\n .form-inline label {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n margin-bottom: 0;\n }\n .form-inline .form-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n margin-bottom: 0;\n }\n .form-inline .form-control {\n display: inline-block;\n width: auto;\n vertical-align: middle;\n }\n .form-inline .form-control-static {\n display: inline-block;\n }\n .form-inline .input-group {\n width: auto;\n }\n .form-inline .form-control-label {\n margin-bottom: 0;\n vertical-align: middle;\n }\n .form-inline .form-check {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: auto;\n margin-top: 0;\n margin-bottom: 0;\n }\n .form-inline .form-check-label {\n padding-left: 0;\n }\n .form-inline .form-check-input {\n position: relative;\n margin-top: 0;\n margin-right: 0.25rem;\n margin-left: 0;\n }\n .form-inline .custom-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n }\n .form-inline .custom-control-indicator {\n position: static;\n display: inline-block;\n margin-right: 0.25rem;\n vertical-align: text-bottom;\n }\n .form-inline .has-feedback .form-control-feedback {\n top: 0;\n }\n}\n\n.btn {\n display: inline-block;\n font-weight: normal;\n line-height: 1.25;\n text-align: center;\n white-space: nowrap;\n vertical-align: middle;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n border: 1px solid transparent;\n padding: 0.5rem 1rem;\n font-size: 1rem;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n}\n\n.btn:focus, .btn:hover {\n text-decoration: none;\n}\n\n.btn:focus, .btn.focus {\n outline: 0;\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n}\n\n.btn.disabled, .btn:disabled {\n cursor: not-allowed;\n opacity: .65;\n}\n\n.btn:active, .btn.active {\n background-image: none;\n}\n\na.btn.disabled,\nfieldset[disabled] a.btn {\n pointer-events: none;\n}\n\n.btn-primary {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:hover {\n color: #fff;\n background-color: #025aa5;\n border-color: #01549b;\n}\n\n.btn-primary:focus, .btn-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-primary.disabled, .btn-primary:disabled {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:active, .btn-primary.active,\n.show > .btn-primary.dropdown-toggle {\n color: #fff;\n background-color: #025aa5;\n background-image: none;\n border-color: #01549b;\n}\n\n.btn-secondary {\n color: #292b2c;\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:hover {\n color: #292b2c;\n background-color: #e6e6e6;\n border-color: #adadad;\n}\n\n.btn-secondary:focus, .btn-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-secondary.disabled, .btn-secondary:disabled {\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:active, .btn-secondary.active,\n.show > .btn-secondary.dropdown-toggle {\n color: #292b2c;\n background-color: #e6e6e6;\n background-image: none;\n border-color: #adadad;\n}\n\n.btn-info {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:hover {\n color: #fff;\n background-color: #31b0d5;\n border-color: #2aabd2;\n}\n\n.btn-info:focus, .btn-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-info.disabled, .btn-info:disabled {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:active, .btn-info.active,\n.show > .btn-info.dropdown-toggle {\n color: #fff;\n background-color: #31b0d5;\n background-image: none;\n border-color: #2aabd2;\n}\n\n.btn-success {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:hover {\n color: #fff;\n background-color: #449d44;\n border-color: #419641;\n}\n\n.btn-success:focus, .btn-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-success.disabled, .btn-success:disabled {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:active, .btn-success.active,\n.show > .btn-success.dropdown-toggle {\n color: #fff;\n background-color: #449d44;\n background-image: none;\n border-color: #419641;\n}\n\n.btn-warning {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:hover {\n color: #fff;\n background-color: #ec971f;\n border-color: #eb9316;\n}\n\n.btn-warning:focus, .btn-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-warning.disabled, .btn-warning:disabled {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:active, .btn-warning.active,\n.show > .btn-warning.dropdown-toggle {\n color: #fff;\n background-color: #ec971f;\n background-image: none;\n border-color: #eb9316;\n}\n\n.btn-danger {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:hover {\n color: #fff;\n background-color: #c9302c;\n border-color: #c12e2a;\n}\n\n.btn-danger:focus, .btn-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-danger.disabled, .btn-danger:disabled {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:active, .btn-danger.active,\n.show > .btn-danger.dropdown-toggle {\n color: #fff;\n background-color: #c9302c;\n background-image: none;\n border-color: #c12e2a;\n}\n\n.btn-outline-primary {\n color: #0275d8;\n background-image: none;\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:hover {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:focus, .btn-outline-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-outline-primary.disabled, .btn-outline-primary:disabled {\n color: #0275d8;\n background-color: transparent;\n}\n\n.btn-outline-primary:active, .btn-outline-primary.active,\n.show > .btn-outline-primary.dropdown-toggle {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-secondary {\n color: #ccc;\n background-image: none;\n background-color: transparent;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:hover {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:focus, .btn-outline-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-outline-secondary.disabled, .btn-outline-secondary:disabled {\n color: #ccc;\n background-color: transparent;\n}\n\n.btn-outline-secondary:active, .btn-outline-secondary.active,\n.show > .btn-outline-secondary.dropdown-toggle {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-info {\n color: #5bc0de;\n background-image: none;\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:hover {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:focus, .btn-outline-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-outline-info.disabled, .btn-outline-info:disabled {\n color: #5bc0de;\n background-color: transparent;\n}\n\n.btn-outline-info:active, .btn-outline-info.active,\n.show > .btn-outline-info.dropdown-toggle {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-success {\n color: #5cb85c;\n background-image: none;\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:hover {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:focus, .btn-outline-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-outline-success.disabled, .btn-outline-success:disabled {\n color: #5cb85c;\n background-color: transparent;\n}\n\n.btn-outline-success:active, .btn-outline-success.active,\n.show > .btn-outline-success.dropdown-toggle {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-warning {\n color: #f0ad4e;\n background-image: none;\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:hover {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:focus, .btn-outline-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-outline-warning.disabled, .btn-outline-warning:disabled {\n color: #f0ad4e;\n background-color: transparent;\n}\n\n.btn-outline-warning:active, .btn-outline-warning.active,\n.show > .btn-outline-warning.dropdown-toggle {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-danger {\n color: #d9534f;\n background-image: none;\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:hover {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:focus, .btn-outline-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-outline-danger.disabled, .btn-outline-danger:disabled {\n color: #d9534f;\n background-color: transparent;\n}\n\n.btn-outline-danger:active, .btn-outline-danger.active,\n.show > .btn-outline-danger.dropdown-toggle {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-link {\n font-weight: normal;\n color: #0275d8;\n border-radius: 0;\n}\n\n.btn-link, .btn-link:active, .btn-link.active, .btn-link:disabled {\n background-color: transparent;\n}\n\n.btn-link, .btn-link:focus, .btn-link:active {\n border-color: transparent;\n}\n\n.btn-link:hover {\n border-color: transparent;\n}\n\n.btn-link:focus, .btn-link:hover {\n color: #014c8c;\n text-decoration: underline;\n background-color: transparent;\n}\n\n.btn-link:disabled {\n color: #636c72;\n}\n\n.btn-link:disabled:focus, .btn-link:disabled:hover {\n text-decoration: none;\n}\n\n.btn-lg, .btn-group-lg > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.btn-sm, .btn-group-sm > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.btn-block {\n display: block;\n width: 100%;\n}\n\n.btn-block + .btn-block {\n margin-top: 0.5rem;\n}\n\ninput[type=\"submit\"].btn-block,\ninput[type=\"reset\"].btn-block,\ninput[type=\"button\"].btn-block {\n width: 100%;\n}\n\n.fade {\n opacity: 0;\n -webkit-transition: opacity 0.15s linear;\n -o-transition: opacity 0.15s linear;\n transition: opacity 0.15s linear;\n}\n\n.fade.show {\n opacity: 1;\n}\n\n.collapse {\n display: none;\n}\n\n.collapse.show {\n display: block;\n}\n\ntr.collapse.show {\n display: table-row;\n}\n\ntbody.collapse.show {\n display: table-row-group;\n}\n\n.collapsing {\n position: relative;\n height: 0;\n overflow: hidden;\n -webkit-transition: height 0.35s ease;\n -o-transition: height 0.35s ease;\n transition: height 0.35s ease;\n}\n\n.dropup,\n.dropdown {\n position: relative;\n}\n\n.dropdown-toggle::after {\n display: inline-block;\n width: 0;\n height: 0;\n margin-left: 0.3em;\n vertical-align: middle;\n content: \"\";\n border-top: 0.3em solid;\n border-right: 0.3em solid transparent;\n border-left: 0.3em solid transparent;\n}\n\n.dropdown-toggle:focus {\n outline: 0;\n}\n\n.dropup .dropdown-toggle::after {\n border-top: 0;\n border-bottom: 0.3em solid;\n}\n\n.dropdown-menu {\n position: absolute;\n top: 100%;\n left: 0;\n z-index: 1000;\n display: none;\n float: left;\n min-width: 10rem;\n padding: 0.5rem 0;\n margin: 0.125rem 0 0;\n font-size: 1rem;\n color: #292b2c;\n text-align: left;\n list-style: none;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.dropdown-divider {\n height: 1px;\n margin: 0.5rem 0;\n overflow: hidden;\n background-color: #eceeef;\n}\n\n.dropdown-item {\n display: block;\n width: 100%;\n padding: 3px 1.5rem;\n clear: both;\n font-weight: normal;\n color: #292b2c;\n text-align: inherit;\n white-space: nowrap;\n background: none;\n border: 0;\n}\n\n.dropdown-item:focus, .dropdown-item:hover {\n color: #1d1e1f;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.dropdown-item.active, .dropdown-item:active {\n color: #fff;\n text-decoration: none;\n background-color: #0275d8;\n}\n\n.dropdown-item.disabled, .dropdown-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: transparent;\n}\n\n.show > .dropdown-menu {\n display: block;\n}\n\n.show > a {\n outline: 0;\n}\n\n.dropdown-menu-right {\n right: 0;\n left: auto;\n}\n\n.dropdown-menu-left {\n right: auto;\n left: 0;\n}\n\n.dropdown-header {\n display: block;\n padding: 0.5rem 1.5rem;\n margin-bottom: 0;\n font-size: 0.875rem;\n color: #636c72;\n white-space: nowrap;\n}\n\n.dropdown-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 990;\n}\n\n.dropup .dropdown-menu {\n top: auto;\n bottom: 100%;\n margin-bottom: 0.125rem;\n}\n\n.btn-group,\n.btn-group-vertical {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n vertical-align: middle;\n}\n\n.btn-group > .btn,\n.btn-group-vertical > .btn {\n position: relative;\n -webkit-box-flex: 0;\n -webkit-flex: 0 1 auto;\n -ms-flex: 0 1 auto;\n flex: 0 1 auto;\n}\n\n.btn-group > .btn:hover,\n.btn-group-vertical > .btn:hover {\n z-index: 2;\n}\n\n.btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active,\n.btn-group-vertical > .btn:focus,\n.btn-group-vertical > .btn:active,\n.btn-group-vertical > .btn.active {\n z-index: 2;\n}\n\n.btn-group .btn + .btn,\n.btn-group .btn + .btn-group,\n.btn-group .btn-group + .btn,\n.btn-group .btn-group + .btn-group,\n.btn-group-vertical .btn + .btn,\n.btn-group-vertical .btn + .btn-group,\n.btn-group-vertical .btn-group + .btn,\n.btn-group-vertical .btn-group + .btn-group {\n margin-left: -1px;\n}\n\n.btn-toolbar {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: start;\n -webkit-justify-content: flex-start;\n -ms-flex-pack: start;\n justify-content: flex-start;\n}\n\n.btn-toolbar .input-group {\n width: auto;\n}\n\n.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {\n border-radius: 0;\n}\n\n.btn-group > .btn:first-child {\n margin-left: 0;\n}\n\n.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn:last-child:not(:first-child),\n.btn-group > .dropdown-toggle:not(:first-child) {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group > .btn-group {\n float: left;\n}\n\n.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group .dropdown-toggle:active,\n.btn-group.open .dropdown-toggle {\n outline: 0;\n}\n\n.btn + .dropdown-toggle-split {\n padding-right: 0.75rem;\n padding-left: 0.75rem;\n}\n\n.btn + .dropdown-toggle-split::after {\n margin-left: 0;\n}\n\n.btn-sm + .dropdown-toggle-split, .btn-group-sm > .btn + .dropdown-toggle-split {\n padding-right: 0.375rem;\n padding-left: 0.375rem;\n}\n\n.btn-lg + .dropdown-toggle-split, .btn-group-lg > .btn + .dropdown-toggle-split {\n padding-right: 1.125rem;\n padding-left: 1.125rem;\n}\n\n.btn-group-vertical {\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.btn-group-vertical .btn,\n.btn-group-vertical .btn-group {\n width: 100%;\n}\n\n.btn-group-vertical > .btn + .btn,\n.btn-group-vertical > .btn + .btn-group,\n.btn-group-vertical > .btn-group + .btn,\n.btn-group-vertical > .btn-group + .btn-group {\n margin-top: -1px;\n margin-left: 0;\n}\n\n.btn-group-vertical > .btn:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn:first-child:not(:last-child) {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn:last-child:not(:first-child) {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n[data-toggle=\"buttons\"] > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn input[type=\"checkbox\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"checkbox\"] {\n position: absolute;\n clip: rect(0, 0, 0, 0);\n pointer-events: none;\n}\n\n.input-group {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n width: 100%;\n}\n\n.input-group .form-control {\n position: relative;\n z-index: 2;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n width: 1%;\n margin-bottom: 0;\n}\n\n.input-group .form-control:focus, .input-group .form-control:active, .input-group .form-control:hover {\n z-index: 3;\n}\n\n.input-group-addon,\n.input-group-btn,\n.input-group .form-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.input-group-addon:not(:first-child):not(:last-child),\n.input-group-btn:not(:first-child):not(:last-child),\n.input-group .form-control:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.input-group-addon,\n.input-group-btn {\n white-space: nowrap;\n vertical-align: middle;\n}\n\n.input-group-addon {\n padding: 0.5rem 0.75rem;\n margin-bottom: 0;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.25;\n color: #464a4c;\n text-align: center;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.input-group-addon.form-control-sm,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .input-group-addon.btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.input-group-addon.form-control-lg,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .input-group-addon.btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.input-group-addon input[type=\"radio\"],\n.input-group-addon input[type=\"checkbox\"] {\n margin-top: 0;\n}\n\n.input-group .form-control:not(:last-child),\n.input-group-addon:not(:last-child),\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group > .btn,\n.input-group-btn:not(:last-child) > .dropdown-toggle,\n.input-group-btn:not(:first-child) > .btn:not(:last-child):not(.dropdown-toggle),\n.input-group-btn:not(:first-child) > .btn-group:not(:last-child) > .btn {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.input-group-addon:not(:last-child) {\n border-right: 0;\n}\n\n.input-group .form-control:not(:first-child),\n.input-group-addon:not(:first-child),\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group > .btn,\n.input-group-btn:not(:first-child) > .dropdown-toggle,\n.input-group-btn:not(:last-child) > .btn:not(:first-child),\n.input-group-btn:not(:last-child) > .btn-group:not(:first-child) > .btn {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.form-control + .input-group-addon:not(:first-child) {\n border-left: 0;\n}\n\n.input-group-btn {\n position: relative;\n font-size: 0;\n white-space: nowrap;\n}\n\n.input-group-btn > .btn {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.input-group-btn > .btn + .btn {\n margin-left: -1px;\n}\n\n.input-group-btn > .btn:focus, .input-group-btn > .btn:active, .input-group-btn > .btn:hover {\n z-index: 3;\n}\n\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group {\n margin-right: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group {\n z-index: 2;\n margin-left: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn:focus, .input-group-btn:not(:first-child) > .btn:active, .input-group-btn:not(:first-child) > .btn:hover,\n.input-group-btn:not(:first-child) > .btn-group:focus,\n.input-group-btn:not(:first-child) > .btn-group:active,\n.input-group-btn:not(:first-child) > .btn-group:hover {\n z-index: 3;\n}\n\n.custom-control {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n min-height: 1.5rem;\n padding-left: 1.5rem;\n margin-right: 1rem;\n cursor: pointer;\n}\n\n.custom-control-input {\n position: absolute;\n z-index: -1;\n opacity: 0;\n}\n\n.custom-control-input:checked ~ .custom-control-indicator {\n color: #fff;\n background-color: #0275d8;\n}\n\n.custom-control-input:focus ~ .custom-control-indicator {\n -webkit-box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n}\n\n.custom-control-input:active ~ .custom-control-indicator {\n color: #fff;\n background-color: #8fcafe;\n}\n\n.custom-control-input:disabled ~ .custom-control-indicator {\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-control-input:disabled ~ .custom-control-description {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.custom-control-indicator {\n position: absolute;\n top: 0.25rem;\n left: 0;\n display: block;\n width: 1rem;\n height: 1rem;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #ddd;\n background-repeat: no-repeat;\n background-position: center center;\n -webkit-background-size: 50% 50%;\n background-size: 50% 50%;\n}\n\n.custom-checkbox .custom-control-indicator {\n border-radius: 0.25rem;\n}\n\n.custom-checkbox .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26 2.974 7.25 8 2.193z'/%3E%3C/svg%3E\");\n}\n\n.custom-checkbox .custom-control-input:indeterminate ~ .custom-control-indicator {\n background-color: #0275d8;\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 4'%3E%3Cpath stroke='%23fff' d='M0 2h4'/%3E%3C/svg%3E\");\n}\n\n.custom-radio .custom-control-indicator {\n border-radius: 50%;\n}\n\n.custom-radio .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3E%3Ccircle r='3' fill='%23fff'/%3E%3C/svg%3E\");\n}\n\n.custom-controls-stacked {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n\n.custom-controls-stacked .custom-control {\n margin-bottom: 0.25rem;\n}\n\n.custom-controls-stacked .custom-control + .custom-control {\n margin-left: 0;\n}\n\n.custom-select {\n display: inline-block;\n max-width: 100%;\n height: calc(2.25rem + 2px);\n padding: 0.375rem 1.75rem 0.375rem 0.75rem;\n line-height: 1.25;\n color: #464a4c;\n vertical-align: middle;\n background: #fff url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23333' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E\") no-repeat right 0.75rem center;\n -webkit-background-size: 8px 10px;\n background-size: 8px 10px;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -moz-appearance: none;\n -webkit-appearance: none;\n}\n\n.custom-select:focus {\n border-color: #5cb3fd;\n outline: none;\n}\n\n.custom-select:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.custom-select:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-select::-ms-expand {\n opacity: 0;\n}\n\n.custom-select-sm {\n padding-top: 0.375rem;\n padding-bottom: 0.375rem;\n font-size: 75%;\n}\n\n.custom-file {\n position: relative;\n display: inline-block;\n max-width: 100%;\n height: 2.5rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.custom-file-input {\n min-width: 14rem;\n max-width: 100%;\n height: 2.5rem;\n margin: 0;\n filter: alpha(opacity=0);\n opacity: 0;\n}\n\n.custom-file-control {\n position: absolute;\n top: 0;\n right: 0;\n left: 0;\n z-index: 5;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.custom-file-control:lang(en)::after {\n content: \"Choose file...\";\n}\n\n.custom-file-control::before {\n position: absolute;\n top: -1px;\n right: -1px;\n bottom: -1px;\n z-index: 6;\n display: block;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0 0.25rem 0.25rem 0;\n}\n\n.custom-file-control:lang(en)::before {\n content: \"Browse\";\n}\n\n.nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.nav-link {\n display: block;\n padding: 0.5em 1em;\n}\n\n.nav-link:focus, .nav-link:hover {\n text-decoration: none;\n}\n\n.nav-link.disabled {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.nav-tabs {\n border-bottom: 1px solid #ddd;\n}\n\n.nav-tabs .nav-item {\n margin-bottom: -1px;\n}\n\n.nav-tabs .nav-link {\n border: 1px solid transparent;\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.nav-tabs .nav-link:focus, .nav-tabs .nav-link:hover {\n border-color: #eceeef #eceeef #ddd;\n}\n\n.nav-tabs .nav-link.disabled {\n color: #636c72;\n background-color: transparent;\n border-color: transparent;\n}\n\n.nav-tabs .nav-link.active,\n.nav-tabs .nav-item.show .nav-link {\n color: #464a4c;\n background-color: #fff;\n border-color: #ddd #ddd #fff;\n}\n\n.nav-tabs .dropdown-menu {\n margin-top: -1px;\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.nav-pills .nav-link {\n border-radius: 0.25rem;\n}\n\n.nav-pills .nav-link.active,\n.nav-pills .nav-item.show .nav-link {\n color: #fff;\n cursor: default;\n background-color: #0275d8;\n}\n\n.nav-fill .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n text-align: center;\n}\n\n.nav-justified .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 100%;\n -ms-flex: 1 1 100%;\n flex: 1 1 100%;\n text-align: center;\n}\n\n.tab-content > .tab-pane {\n display: none;\n}\n\n.tab-content > .active {\n display: block;\n}\n\n.navbar {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding: 0.5rem 1rem;\n}\n\n.navbar-brand {\n display: inline-block;\n padding-top: .25rem;\n padding-bottom: .25rem;\n margin-right: 1rem;\n font-size: 1.25rem;\n line-height: inherit;\n white-space: nowrap;\n}\n\n.navbar-brand:focus, .navbar-brand:hover {\n text-decoration: none;\n}\n\n.navbar-nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.navbar-nav .nav-link {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-text {\n display: inline-block;\n padding-top: .425rem;\n padding-bottom: .425rem;\n}\n\n.navbar-toggler {\n -webkit-align-self: flex-start;\n -ms-flex-item-align: start;\n align-self: flex-start;\n padding: 0.25rem 0.75rem;\n font-size: 1.25rem;\n line-height: 1;\n background: transparent;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.navbar-toggler:focus, .navbar-toggler:hover {\n text-decoration: none;\n}\n\n.navbar-toggler-icon {\n display: inline-block;\n width: 1.5em;\n height: 1.5em;\n vertical-align: middle;\n content: \"\";\n background: no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.navbar-toggler-left {\n position: absolute;\n left: 1rem;\n}\n\n.navbar-toggler-right {\n position: absolute;\n right: 1rem;\n}\n\n@media (max-width: 575px) {\n .navbar-toggleable .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 576px) {\n .navbar-toggleable {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 767px) {\n .navbar-toggleable-sm .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-sm > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 768px) {\n .navbar-toggleable-sm {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-sm .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-sm > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-sm .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 991px) {\n .navbar-toggleable-md .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-md > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 992px) {\n .navbar-toggleable-md {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-md .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-md > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-md .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 1199px) {\n .navbar-toggleable-lg .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-lg > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 1200px) {\n .navbar-toggleable-lg {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-lg .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-lg > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-lg .navbar-toggler {\n display: none;\n }\n}\n\n.navbar-toggleable-xl {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n}\n\n.navbar-toggleable-xl > .container {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-toggleable-xl .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n\n.navbar-toggleable-xl .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n}\n\n.navbar-toggleable-xl > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n}\n\n.navbar-toggleable-xl .navbar-toggler {\n display: none;\n}\n\n.navbar-light .navbar-brand,\n.navbar-light .navbar-toggler {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-brand:focus, .navbar-light .navbar-brand:hover,\n.navbar-light .navbar-toggler:focus,\n.navbar-light .navbar-toggler:hover {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-nav .nav-link {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-light .navbar-nav .nav-link:focus, .navbar-light .navbar-nav .nav-link:hover {\n color: rgba(0, 0, 0, 0.7);\n}\n\n.navbar-light .navbar-nav .nav-link.disabled {\n color: rgba(0, 0, 0, 0.3);\n}\n\n.navbar-light .navbar-nav .open > .nav-link,\n.navbar-light .navbar-nav .active > .nav-link,\n.navbar-light .navbar-nav .nav-link.open,\n.navbar-light .navbar-nav .nav-link.active {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-toggler {\n border-color: rgba(0, 0, 0, 0.1);\n}\n\n.navbar-light .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(0, 0, 0, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-light .navbar-text {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-inverse .navbar-brand,\n.navbar-inverse .navbar-toggler {\n color: white;\n}\n\n.navbar-inverse .navbar-brand:focus, .navbar-inverse .navbar-brand:hover,\n.navbar-inverse .navbar-toggler:focus,\n.navbar-inverse .navbar-toggler:hover {\n color: white;\n}\n\n.navbar-inverse .navbar-nav .nav-link {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.navbar-inverse .navbar-nav .nav-link:focus, .navbar-inverse .navbar-nav .nav-link:hover {\n color: rgba(255, 255, 255, 0.75);\n}\n\n.navbar-inverse .navbar-nav .nav-link.disabled {\n color: rgba(255, 255, 255, 0.25);\n}\n\n.navbar-inverse .navbar-nav .open > .nav-link,\n.navbar-inverse .navbar-nav .active > .nav-link,\n.navbar-inverse .navbar-nav .nav-link.open,\n.navbar-inverse .navbar-nav .nav-link.active {\n color: white;\n}\n\n.navbar-inverse .navbar-toggler {\n border-color: rgba(255, 255, 255, 0.1);\n}\n\n.navbar-inverse .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255, 255, 255, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-inverse .navbar-text {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.card {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n border-radius: 0.25rem;\n}\n\n.card-block {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 1.25rem;\n}\n\n.card-title {\n margin-bottom: 0.75rem;\n}\n\n.card-subtitle {\n margin-top: -0.375rem;\n margin-bottom: 0;\n}\n\n.card-text:last-child {\n margin-bottom: 0;\n}\n\n.card-link:hover {\n text-decoration: none;\n}\n\n.card-link + .card-link {\n margin-left: 1.25rem;\n}\n\n.card > .list-group:first-child .list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.card > .list-group:last-child .list-group-item:last-child {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.card-header {\n padding: 0.75rem 1.25rem;\n margin-bottom: 0;\n background-color: #f7f7f9;\n border-bottom: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-header:first-child {\n border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;\n}\n\n.card-footer {\n padding: 0.75rem 1.25rem;\n background-color: #f7f7f9;\n border-top: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-footer:last-child {\n border-radius: 0 0 calc(0.25rem - 1px) calc(0.25rem - 1px);\n}\n\n.card-header-tabs {\n margin-right: -0.625rem;\n margin-bottom: -0.75rem;\n margin-left: -0.625rem;\n border-bottom: 0;\n}\n\n.card-header-pills {\n margin-right: -0.625rem;\n margin-left: -0.625rem;\n}\n\n.card-primary {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.card-primary .card-header,\n.card-primary .card-footer {\n background-color: transparent;\n}\n\n.card-success {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.card-success .card-header,\n.card-success .card-footer {\n background-color: transparent;\n}\n\n.card-info {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.card-info .card-header,\n.card-info .card-footer {\n background-color: transparent;\n}\n\n.card-warning {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.card-warning .card-header,\n.card-warning .card-footer {\n background-color: transparent;\n}\n\n.card-danger {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.card-danger .card-header,\n.card-danger .card-footer {\n background-color: transparent;\n}\n\n.card-outline-primary {\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.card-outline-secondary {\n background-color: transparent;\n border-color: #ccc;\n}\n\n.card-outline-info {\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.card-outline-success {\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.card-outline-warning {\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.card-outline-danger {\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.card-inverse {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer {\n background-color: transparent;\n border-color: rgba(255, 255, 255, 0.2);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer,\n.card-inverse .card-title,\n.card-inverse .card-blockquote {\n color: #fff;\n}\n\n.card-inverse .card-link,\n.card-inverse .card-text,\n.card-inverse .card-subtitle,\n.card-inverse .card-blockquote .blockquote-footer {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-link:focus, .card-inverse .card-link:hover {\n color: #fff;\n}\n\n.card-blockquote {\n padding: 0;\n margin-bottom: 0;\n border-left: 0;\n}\n\n.card-img {\n border-radius: calc(0.25rem - 1px);\n}\n\n.card-img-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n padding: 1.25rem;\n}\n\n.card-img-top {\n border-top-right-radius: calc(0.25rem - 1px);\n border-top-left-radius: calc(0.25rem - 1px);\n}\n\n.card-img-bottom {\n border-bottom-right-radius: calc(0.25rem - 1px);\n border-bottom-left-radius: calc(0.25rem - 1px);\n}\n\n@media (min-width: 576px) {\n .card-deck {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-deck .card {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n }\n .card-deck .card:not(:first-child) {\n margin-left: 15px;\n }\n .card-deck .card:not(:last-child) {\n margin-right: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .card-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-group .card {\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n }\n .card-group .card + .card {\n margin-left: 0;\n border-left: 0;\n }\n .card-group .card:first-child {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-top {\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-bottom {\n border-bottom-right-radius: 0;\n }\n .card-group .card:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-top {\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-bottom {\n border-bottom-left-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) {\n border-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) .card-img-top,\n .card-group .card:not(:first-child):not(:last-child) .card-img-bottom {\n border-radius: 0;\n }\n}\n\n@media (min-width: 576px) {\n .card-columns {\n -webkit-column-count: 3;\n -moz-column-count: 3;\n column-count: 3;\n -webkit-column-gap: 1.25rem;\n -moz-column-gap: 1.25rem;\n column-gap: 1.25rem;\n }\n .card-columns .card {\n display: inline-block;\n width: 100%;\n margin-bottom: 0.75rem;\n }\n}\n\n.breadcrumb {\n padding: 0.75rem 1rem;\n margin-bottom: 1rem;\n list-style: none;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.breadcrumb::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.breadcrumb-item {\n float: left;\n}\n\n.breadcrumb-item + .breadcrumb-item::before {\n display: inline-block;\n padding-right: 0.5rem;\n padding-left: 0.5rem;\n color: #636c72;\n content: \"/\";\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: underline;\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: none;\n}\n\n.breadcrumb-item.active {\n color: #636c72;\n}\n\n.pagination {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n list-style: none;\n border-radius: 0.25rem;\n}\n\n.page-item:first-child .page-link {\n margin-left: 0;\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.page-item:last-child .page-link {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.page-item.active .page-link {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.page-item.disabled .page-link {\n color: #636c72;\n pointer-events: none;\n cursor: not-allowed;\n background-color: #fff;\n border-color: #ddd;\n}\n\n.page-link {\n position: relative;\n display: block;\n padding: 0.5rem 0.75rem;\n margin-left: -1px;\n line-height: 1.25;\n color: #0275d8;\n background-color: #fff;\n border: 1px solid #ddd;\n}\n\n.page-link:focus, .page-link:hover {\n color: #014c8c;\n text-decoration: none;\n background-color: #eceeef;\n border-color: #ddd;\n}\n\n.pagination-lg .page-link {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n}\n\n.pagination-lg .page-item:first-child .page-link {\n border-bottom-left-radius: 0.3rem;\n border-top-left-radius: 0.3rem;\n}\n\n.pagination-lg .page-item:last-child .page-link {\n border-bottom-right-radius: 0.3rem;\n border-top-right-radius: 0.3rem;\n}\n\n.pagination-sm .page-link {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n}\n\n.pagination-sm .page-item:first-child .page-link {\n border-bottom-left-radius: 0.2rem;\n border-top-left-radius: 0.2rem;\n}\n\n.pagination-sm .page-item:last-child .page-link {\n border-bottom-right-radius: 0.2rem;\n border-top-right-radius: 0.2rem;\n}\n\n.badge {\n display: inline-block;\n padding: 0.25em 0.4em;\n font-size: 75%;\n font-weight: bold;\n line-height: 1;\n color: #fff;\n text-align: center;\n white-space: nowrap;\n vertical-align: baseline;\n border-radius: 0.25rem;\n}\n\n.badge:empty {\n display: none;\n}\n\n.btn .badge {\n position: relative;\n top: -1px;\n}\n\na.badge:focus, a.badge:hover {\n color: #fff;\n text-decoration: none;\n cursor: pointer;\n}\n\n.badge-pill {\n padding-right: 0.6em;\n padding-left: 0.6em;\n border-radius: 10rem;\n}\n\n.badge-default {\n background-color: #636c72;\n}\n\n.badge-default[href]:focus, .badge-default[href]:hover {\n background-color: #4b5257;\n}\n\n.badge-primary {\n background-color: #0275d8;\n}\n\n.badge-primary[href]:focus, .badge-primary[href]:hover {\n background-color: #025aa5;\n}\n\n.badge-success {\n background-color: #5cb85c;\n}\n\n.badge-success[href]:focus, .badge-success[href]:hover {\n background-color: #449d44;\n}\n\n.badge-info {\n background-color: #5bc0de;\n}\n\n.badge-info[href]:focus, .badge-info[href]:hover {\n background-color: #31b0d5;\n}\n\n.badge-warning {\n background-color: #f0ad4e;\n}\n\n.badge-warning[href]:focus, .badge-warning[href]:hover {\n background-color: #ec971f;\n}\n\n.badge-danger {\n background-color: #d9534f;\n}\n\n.badge-danger[href]:focus, .badge-danger[href]:hover {\n background-color: #c9302c;\n}\n\n.jumbotron {\n padding: 2rem 1rem;\n margin-bottom: 2rem;\n background-color: #eceeef;\n border-radius: 0.3rem;\n}\n\n@media (min-width: 576px) {\n .jumbotron {\n padding: 4rem 2rem;\n }\n}\n\n.jumbotron-hr {\n border-top-color: #d0d5d8;\n}\n\n.jumbotron-fluid {\n padding-right: 0;\n padding-left: 0;\n border-radius: 0;\n}\n\n.alert {\n padding: 0.75rem 1.25rem;\n margin-bottom: 1rem;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.alert-heading {\n color: inherit;\n}\n\n.alert-link {\n font-weight: bold;\n}\n\n.alert-dismissible .close {\n position: relative;\n top: -0.75rem;\n right: -1.25rem;\n padding: 0.75rem 1.25rem;\n color: inherit;\n}\n\n.alert-success {\n background-color: #dff0d8;\n border-color: #d0e9c6;\n color: #3c763d;\n}\n\n.alert-success hr {\n border-top-color: #c1e2b3;\n}\n\n.alert-success .alert-link {\n color: #2b542c;\n}\n\n.alert-info {\n background-color: #d9edf7;\n border-color: #bcdff1;\n color: #31708f;\n}\n\n.alert-info hr {\n border-top-color: #a6d5ec;\n}\n\n.alert-info .alert-link {\n color: #245269;\n}\n\n.alert-warning {\n background-color: #fcf8e3;\n border-color: #faf2cc;\n color: #8a6d3b;\n}\n\n.alert-warning hr {\n border-top-color: #f7ecb5;\n}\n\n.alert-warning .alert-link {\n color: #66512c;\n}\n\n.alert-danger {\n background-color: #f2dede;\n border-color: #ebcccc;\n color: #a94442;\n}\n\n.alert-danger hr {\n border-top-color: #e4b9b9;\n}\n\n.alert-danger .alert-link {\n color: #843534;\n}\n\n@-webkit-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@-o-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n.progress {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n overflow: hidden;\n font-size: 0.75rem;\n line-height: 1rem;\n text-align: center;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.progress-bar {\n height: 1rem;\n color: #fff;\n background-color: #0275d8;\n}\n\n.progress-bar-striped {\n background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n -webkit-background-size: 1rem 1rem;\n background-size: 1rem 1rem;\n}\n\n.progress-bar-animated {\n -webkit-animation: progress-bar-stripes 1s linear infinite;\n -o-animation: progress-bar-stripes 1s linear infinite;\n animation: progress-bar-stripes 1s linear infinite;\n}\n\n.media {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n}\n\n.media-body {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.list-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n}\n\n.list-group-item-action {\n width: 100%;\n color: #464a4c;\n text-align: inherit;\n}\n\n.list-group-item-action .list-group-item-heading {\n color: #292b2c;\n}\n\n.list-group-item-action:focus, .list-group-item-action:hover {\n color: #464a4c;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.list-group-item-action:active {\n color: #292b2c;\n background-color: #eceeef;\n}\n\n.list-group-item {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n padding: 0.75rem 1.25rem;\n margin-bottom: -1px;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.list-group-item:last-child {\n margin-bottom: 0;\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.list-group-item:focus, .list-group-item:hover {\n text-decoration: none;\n}\n\n.list-group-item.disabled, .list-group-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #fff;\n}\n\n.list-group-item.disabled .list-group-item-heading, .list-group-item:disabled .list-group-item-heading {\n color: inherit;\n}\n\n.list-group-item.disabled .list-group-item-text, .list-group-item:disabled .list-group-item-text {\n color: #636c72;\n}\n\n.list-group-item.active {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.list-group-item.active .list-group-item-heading,\n.list-group-item.active .list-group-item-heading > small,\n.list-group-item.active .list-group-item-heading > .small {\n color: inherit;\n}\n\n.list-group-item.active .list-group-item-text {\n color: #daeeff;\n}\n\n.list-group-flush .list-group-item {\n border-right: 0;\n border-left: 0;\n border-radius: 0;\n}\n\n.list-group-flush:first-child .list-group-item:first-child {\n border-top: 0;\n}\n\n.list-group-flush:last-child .list-group-item:last-child {\n border-bottom: 0;\n}\n\n.list-group-item-success {\n color: #3c763d;\n background-color: #dff0d8;\n}\n\na.list-group-item-success,\nbutton.list-group-item-success {\n color: #3c763d;\n}\n\na.list-group-item-success .list-group-item-heading,\nbutton.list-group-item-success .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-success:focus, a.list-group-item-success:hover,\nbutton.list-group-item-success:focus,\nbutton.list-group-item-success:hover {\n color: #3c763d;\n background-color: #d0e9c6;\n}\n\na.list-group-item-success.active,\nbutton.list-group-item-success.active {\n color: #fff;\n background-color: #3c763d;\n border-color: #3c763d;\n}\n\n.list-group-item-info {\n color: #31708f;\n background-color: #d9edf7;\n}\n\na.list-group-item-info,\nbutton.list-group-item-info {\n color: #31708f;\n}\n\na.list-group-item-info .list-group-item-heading,\nbutton.list-group-item-info .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-info:focus, a.list-group-item-info:hover,\nbutton.list-group-item-info:focus,\nbutton.list-group-item-info:hover {\n color: #31708f;\n background-color: #c4e3f3;\n}\n\na.list-group-item-info.active,\nbutton.list-group-item-info.active {\n color: #fff;\n background-color: #31708f;\n border-color: #31708f;\n}\n\n.list-group-item-warning {\n color: #8a6d3b;\n background-color: #fcf8e3;\n}\n\na.list-group-item-warning,\nbutton.list-group-item-warning {\n color: #8a6d3b;\n}\n\na.list-group-item-warning .list-group-item-heading,\nbutton.list-group-item-warning .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-warning:focus, a.list-group-item-warning:hover,\nbutton.list-group-item-warning:focus,\nbutton.list-group-item-warning:hover {\n color: #8a6d3b;\n background-color: #faf2cc;\n}\n\na.list-group-item-warning.active,\nbutton.list-group-item-warning.active {\n color: #fff;\n background-color: #8a6d3b;\n border-color: #8a6d3b;\n}\n\n.list-group-item-danger {\n color: #a94442;\n background-color: #f2dede;\n}\n\na.list-group-item-danger,\nbutton.list-group-item-danger {\n color: #a94442;\n}\n\na.list-group-item-danger .list-group-item-heading,\nbutton.list-group-item-danger .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-danger:focus, a.list-group-item-danger:hover,\nbutton.list-group-item-danger:focus,\nbutton.list-group-item-danger:hover {\n color: #a94442;\n background-color: #ebcccc;\n}\n\na.list-group-item-danger.active,\nbutton.list-group-item-danger.active {\n color: #fff;\n background-color: #a94442;\n border-color: #a94442;\n}\n\n.embed-responsive {\n position: relative;\n display: block;\n width: 100%;\n padding: 0;\n overflow: hidden;\n}\n\n.embed-responsive::before {\n display: block;\n content: \"\";\n}\n\n.embed-responsive .embed-responsive-item,\n.embed-responsive iframe,\n.embed-responsive embed,\n.embed-responsive object,\n.embed-responsive video {\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 100%;\n border: 0;\n}\n\n.embed-responsive-21by9::before {\n padding-top: 42.857143%;\n}\n\n.embed-responsive-16by9::before {\n padding-top: 56.25%;\n}\n\n.embed-responsive-4by3::before {\n padding-top: 75%;\n}\n\n.embed-responsive-1by1::before {\n padding-top: 100%;\n}\n\n.close {\n float: right;\n font-size: 1.5rem;\n font-weight: bold;\n line-height: 1;\n color: #000;\n text-shadow: 0 1px 0 #fff;\n opacity: .5;\n}\n\n.close:focus, .close:hover {\n color: #000;\n text-decoration: none;\n cursor: pointer;\n opacity: .75;\n}\n\nbutton.close {\n padding: 0;\n cursor: pointer;\n background: transparent;\n border: 0;\n -webkit-appearance: none;\n}\n\n.modal-open {\n overflow: hidden;\n}\n\n.modal {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1050;\n display: none;\n overflow: hidden;\n outline: 0;\n}\n\n.modal.fade .modal-dialog {\n -webkit-transition: -webkit-transform 0.3s ease-out;\n transition: -webkit-transform 0.3s ease-out;\n -o-transition: -o-transform 0.3s ease-out;\n transition: transform 0.3s ease-out;\n transition: transform 0.3s ease-out, -webkit-transform 0.3s ease-out, -o-transform 0.3s ease-out;\n -webkit-transform: translate(0, -25%);\n -o-transform: translate(0, -25%);\n transform: translate(0, -25%);\n}\n\n.modal.show .modal-dialog {\n -webkit-transform: translate(0, 0);\n -o-transform: translate(0, 0);\n transform: translate(0, 0);\n}\n\n.modal-open .modal {\n overflow-x: hidden;\n overflow-y: auto;\n}\n\n.modal-dialog {\n position: relative;\n width: auto;\n margin: 10px;\n}\n\n.modal-content {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n outline: 0;\n}\n\n.modal-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1040;\n background-color: #000;\n}\n\n.modal-backdrop.fade {\n opacity: 0;\n}\n\n.modal-backdrop.show {\n opacity: 0.5;\n}\n\n.modal-header {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n padding: 15px;\n border-bottom: 1px solid #eceeef;\n}\n\n.modal-title {\n margin-bottom: 0;\n line-height: 1.5;\n}\n\n.modal-body {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 15px;\n}\n\n.modal-footer {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: end;\n -webkit-justify-content: flex-end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n padding: 15px;\n border-top: 1px solid #eceeef;\n}\n\n.modal-footer > :not(:first-child) {\n margin-left: .25rem;\n}\n\n.modal-footer > :not(:last-child) {\n margin-right: .25rem;\n}\n\n.modal-scrollbar-measure {\n position: absolute;\n top: -9999px;\n width: 50px;\n height: 50px;\n overflow: scroll;\n}\n\n@media (min-width: 576px) {\n .modal-dialog {\n max-width: 500px;\n margin: 30px auto;\n }\n .modal-sm {\n max-width: 300px;\n }\n}\n\n@media (min-width: 992px) {\n .modal-lg {\n max-width: 800px;\n }\n}\n\n.tooltip {\n position: absolute;\n z-index: 1070;\n display: block;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n opacity: 0;\n}\n\n.tooltip.show {\n opacity: 0.9;\n}\n\n.tooltip.tooltip-top, .tooltip.bs-tether-element-attached-bottom {\n padding: 5px 0;\n margin-top: -3px;\n}\n\n.tooltip.tooltip-top .tooltip-inner::before, .tooltip.bs-tether-element-attached-bottom .tooltip-inner::before {\n bottom: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 5px 5px 0;\n border-top-color: #000;\n}\n\n.tooltip.tooltip-right, .tooltip.bs-tether-element-attached-left {\n padding: 0 5px;\n margin-left: 3px;\n}\n\n.tooltip.tooltip-right .tooltip-inner::before, .tooltip.bs-tether-element-attached-left .tooltip-inner::before {\n top: 50%;\n left: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 5px 5px 0;\n border-right-color: #000;\n}\n\n.tooltip.tooltip-bottom, .tooltip.bs-tether-element-attached-top {\n padding: 5px 0;\n margin-top: 3px;\n}\n\n.tooltip.tooltip-bottom .tooltip-inner::before, .tooltip.bs-tether-element-attached-top .tooltip-inner::before {\n top: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 0 5px 5px;\n border-bottom-color: #000;\n}\n\n.tooltip.tooltip-left, .tooltip.bs-tether-element-attached-right {\n padding: 0 5px;\n margin-left: -3px;\n}\n\n.tooltip.tooltip-left .tooltip-inner::before, .tooltip.bs-tether-element-attached-right .tooltip-inner::before {\n top: 50%;\n right: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 0 5px 5px;\n border-left-color: #000;\n}\n\n.tooltip-inner {\n max-width: 200px;\n padding: 3px 8px;\n color: #fff;\n text-align: center;\n background-color: #000;\n border-radius: 0.25rem;\n}\n\n.tooltip-inner::before {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1060;\n display: block;\n max-width: 276px;\n padding: 1px;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n}\n\n.popover.popover-top, .popover.bs-tether-element-attached-bottom {\n margin-top: -10px;\n}\n\n.popover.popover-top::before, .popover.popover-top::after, .popover.bs-tether-element-attached-bottom::before, .popover.bs-tether-element-attached-bottom::after {\n left: 50%;\n border-bottom-width: 0;\n}\n\n.popover.popover-top::before, .popover.bs-tether-element-attached-bottom::before {\n bottom: -11px;\n margin-left: -11px;\n border-top-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-top::after, .popover.bs-tether-element-attached-bottom::after {\n bottom: -10px;\n margin-left: -10px;\n border-top-color: #fff;\n}\n\n.popover.popover-right, .popover.bs-tether-element-attached-left {\n margin-left: 10px;\n}\n\n.popover.popover-right::before, .popover.popover-right::after, .popover.bs-tether-element-attached-left::before, .popover.bs-tether-element-attached-left::after {\n top: 50%;\n border-left-width: 0;\n}\n\n.popover.popover-right::before, .popover.bs-tether-element-attached-left::before {\n left: -11px;\n margin-top: -11px;\n border-right-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-right::after, .popover.bs-tether-element-attached-left::after {\n left: -10px;\n margin-top: -10px;\n border-right-color: #fff;\n}\n\n.popover.popover-bottom, .popover.bs-tether-element-attached-top {\n margin-top: 10px;\n}\n\n.popover.popover-bottom::before, .popover.popover-bottom::after, .popover.bs-tether-element-attached-top::before, .popover.bs-tether-element-attached-top::after {\n left: 50%;\n border-top-width: 0;\n}\n\n.popover.popover-bottom::before, .popover.bs-tether-element-attached-top::before {\n top: -11px;\n margin-left: -11px;\n border-bottom-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-bottom::after, .popover.bs-tether-element-attached-top::after {\n top: -10px;\n margin-left: -10px;\n border-bottom-color: #f7f7f7;\n}\n\n.popover.popover-bottom .popover-title::before, .popover.bs-tether-element-attached-top .popover-title::before {\n position: absolute;\n top: 0;\n left: 50%;\n display: block;\n width: 20px;\n margin-left: -10px;\n content: \"\";\n border-bottom: 1px solid #f7f7f7;\n}\n\n.popover.popover-left, .popover.bs-tether-element-attached-right {\n margin-left: -10px;\n}\n\n.popover.popover-left::before, .popover.popover-left::after, .popover.bs-tether-element-attached-right::before, .popover.bs-tether-element-attached-right::after {\n top: 50%;\n border-right-width: 0;\n}\n\n.popover.popover-left::before, .popover.bs-tether-element-attached-right::before {\n right: -11px;\n margin-top: -11px;\n border-left-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-left::after, .popover.bs-tether-element-attached-right::after {\n right: -10px;\n margin-top: -10px;\n border-left-color: #fff;\n}\n\n.popover-title {\n padding: 8px 14px;\n margin-bottom: 0;\n font-size: 1rem;\n background-color: #f7f7f7;\n border-bottom: 1px solid #ebebeb;\n border-top-right-radius: calc(0.3rem - 1px);\n border-top-left-radius: calc(0.3rem - 1px);\n}\n\n.popover-title:empty {\n display: none;\n}\n\n.popover-content {\n padding: 9px 14px;\n}\n\n.popover::before,\n.popover::after {\n position: absolute;\n display: block;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover::before {\n content: \"\";\n border-width: 11px;\n}\n\n.popover::after {\n content: \"\";\n border-width: 10px;\n}\n\n.carousel {\n position: relative;\n}\n\n.carousel-inner {\n position: relative;\n width: 100%;\n overflow: hidden;\n}\n\n.carousel-item {\n position: relative;\n display: none;\n width: 100%;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n.carousel-item.active,\n.carousel-item-next,\n.carousel-item-prev {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n}\n\n.carousel-item-next,\n.carousel-item-prev {\n position: absolute;\n top: 0;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n.carousel-control-prev,\n.carousel-control-next {\n position: absolute;\n top: 0;\n bottom: 0;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: 15%;\n color: #fff;\n text-align: center;\n opacity: 0.5;\n}\n\n.carousel-control-prev:focus, .carousel-control-prev:hover,\n.carousel-control-next:focus,\n.carousel-control-next:hover {\n color: #fff;\n text-decoration: none;\n outline: 0;\n opacity: .9;\n}\n\n.carousel-control-prev {\n left: 0;\n}\n\n.carousel-control-next {\n right: 0;\n}\n\n.carousel-control-prev-icon,\n.carousel-control-next-icon {\n display: inline-block;\n width: 20px;\n height: 20px;\n background: transparent no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.carousel-control-prev-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M4 0l-4 4 4 4 1.5-1.5-2.5-2.5 2.5-2.5-1.5-1.5z'/%3E%3C/svg%3E\");\n}\n\n.carousel-control-next-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M1.5 0l-1.5 1.5 2.5 2.5-2.5 2.5 1.5 1.5 4-4-4-4z'/%3E%3C/svg%3E\");\n}\n\n.carousel-indicators {\n position: absolute;\n right: 0;\n bottom: 10px;\n left: 0;\n z-index: 15;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n margin-right: 15%;\n margin-left: 15%;\n list-style: none;\n}\n\n.carousel-indicators li {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 auto;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n max-width: 30px;\n height: 3px;\n margin-right: 3px;\n margin-left: 3px;\n text-indent: -999px;\n cursor: pointer;\n background-color: rgba(255, 255, 255, 0.5);\n}\n\n.carousel-indicators li::before {\n position: absolute;\n top: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators li::after {\n position: absolute;\n bottom: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators .active {\n background-color: #fff;\n}\n\n.carousel-caption {\n position: absolute;\n right: 15%;\n bottom: 20px;\n left: 15%;\n z-index: 10;\n padding-top: 20px;\n padding-bottom: 20px;\n color: #fff;\n text-align: center;\n}\n\n.align-baseline {\n vertical-align: baseline !important;\n}\n\n.align-top {\n vertical-align: top !important;\n}\n\n.align-middle {\n vertical-align: middle !important;\n}\n\n.align-bottom {\n vertical-align: bottom !important;\n}\n\n.align-text-bottom {\n vertical-align: text-bottom !important;\n}\n\n.align-text-top {\n vertical-align: text-top !important;\n}\n\n.bg-faded {\n background-color: #f7f7f7;\n}\n\n.bg-primary {\n background-color: #0275d8 !important;\n}\n\na.bg-primary:focus, a.bg-primary:hover {\n background-color: #025aa5 !important;\n}\n\n.bg-success {\n background-color: #5cb85c !important;\n}\n\na.bg-success:focus, a.bg-success:hover {\n background-color: #449d44 !important;\n}\n\n.bg-info {\n background-color: #5bc0de !important;\n}\n\na.bg-info:focus, a.bg-info:hover {\n background-color: #31b0d5 !important;\n}\n\n.bg-warning {\n background-color: #f0ad4e !important;\n}\n\na.bg-warning:focus, a.bg-warning:hover {\n background-color: #ec971f !important;\n}\n\n.bg-danger {\n background-color: #d9534f !important;\n}\n\na.bg-danger:focus, a.bg-danger:hover {\n background-color: #c9302c !important;\n}\n\n.bg-inverse {\n background-color: #292b2c !important;\n}\n\na.bg-inverse:focus, a.bg-inverse:hover {\n background-color: #101112 !important;\n}\n\n.border-0 {\n border: 0 !important;\n}\n\n.border-top-0 {\n border-top: 0 !important;\n}\n\n.border-right-0 {\n border-right: 0 !important;\n}\n\n.border-bottom-0 {\n border-bottom: 0 !important;\n}\n\n.border-left-0 {\n border-left: 0 !important;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.rounded-top {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-right {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.rounded-bottom {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.rounded-left {\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-circle {\n border-radius: 50%;\n}\n\n.rounded-0 {\n border-radius: 0;\n}\n\n.clearfix::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.d-none {\n display: none !important;\n}\n\n.d-inline {\n display: inline !important;\n}\n\n.d-inline-block {\n display: inline-block !important;\n}\n\n.d-block {\n display: block !important;\n}\n\n.d-table {\n display: table !important;\n}\n\n.d-table-cell {\n display: table-cell !important;\n}\n\n.d-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n}\n\n.d-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n}\n\n@media (min-width: 576px) {\n .d-sm-none {\n display: none !important;\n }\n .d-sm-inline {\n display: inline !important;\n }\n .d-sm-inline-block {\n display: inline-block !important;\n }\n .d-sm-block {\n display: block !important;\n }\n .d-sm-table {\n display: table !important;\n }\n .d-sm-table-cell {\n display: table-cell !important;\n }\n .d-sm-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-sm-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 768px) {\n .d-md-none {\n display: none !important;\n }\n .d-md-inline {\n display: inline !important;\n }\n .d-md-inline-block {\n display: inline-block !important;\n }\n .d-md-block {\n display: block !important;\n }\n .d-md-table {\n display: table !important;\n }\n .d-md-table-cell {\n display: table-cell !important;\n }\n .d-md-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-md-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 992px) {\n .d-lg-none {\n display: none !important;\n }\n .d-lg-inline {\n display: inline !important;\n }\n .d-lg-inline-block {\n display: inline-block !important;\n }\n .d-lg-block {\n display: block !important;\n }\n .d-lg-table {\n display: table !important;\n }\n .d-lg-table-cell {\n display: table-cell !important;\n }\n .d-lg-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-lg-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 1200px) {\n .d-xl-none {\n display: none !important;\n }\n .d-xl-inline {\n display: inline !important;\n }\n .d-xl-inline-block {\n display: inline-block !important;\n }\n .d-xl-block {\n display: block !important;\n }\n .d-xl-table {\n display: table !important;\n }\n .d-xl-table-cell {\n display: table-cell !important;\n }\n .d-xl-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-xl-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n.flex-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n}\n\n.flex-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n}\n\n.flex-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n}\n\n.flex-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n}\n\n.flex-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n}\n\n.flex-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n}\n\n.flex-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n}\n\n.flex-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n}\n\n.flex-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n}\n\n.flex-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n}\n\n.justify-content-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n}\n\n.justify-content-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n}\n\n.justify-content-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n}\n\n.justify-content-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n}\n\n.justify-content-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n}\n\n.align-items-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n}\n\n.align-items-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n}\n\n.align-items-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n}\n\n.align-items-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n}\n\n.align-items-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n}\n\n.align-content-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n}\n\n.align-content-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n}\n\n.align-content-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n}\n\n.align-content-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n}\n\n.align-content-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n}\n\n.align-content-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n}\n\n.align-self-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n}\n\n.align-self-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n}\n\n.align-self-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n}\n\n.align-self-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n}\n\n.align-self-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n}\n\n.align-self-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n}\n\n@media (min-width: 576px) {\n .flex-sm-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-sm-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-sm-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-sm-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-sm-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-sm-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-sm-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-sm-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-sm-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-sm-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-sm-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-sm-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-sm-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-sm-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-sm-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-sm-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-sm-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-sm-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-sm-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-sm-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-sm-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-sm-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-sm-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-sm-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-sm-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-sm-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-sm-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-sm-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-sm-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-sm-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-sm-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-sm-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 768px) {\n .flex-md-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-md-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-md-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-md-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-md-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-md-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-md-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-md-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-md-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-md-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-md-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-md-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-md-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-md-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-md-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-md-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-md-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-md-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-md-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-md-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-md-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-md-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-md-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-md-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-md-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-md-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-md-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-md-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-md-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-md-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-md-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-md-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 992px) {\n .flex-lg-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-lg-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-lg-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-lg-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-lg-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-lg-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-lg-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-lg-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-lg-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-lg-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-lg-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-lg-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-lg-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-lg-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-lg-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-lg-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-lg-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-lg-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-lg-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-lg-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-lg-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-lg-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-lg-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-lg-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-lg-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-lg-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-lg-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-lg-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-lg-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-lg-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-lg-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-lg-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 1200px) {\n .flex-xl-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-xl-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-xl-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-xl-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-xl-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-xl-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-xl-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-xl-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-xl-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-xl-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-xl-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-xl-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-xl-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-xl-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-xl-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-xl-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-xl-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-xl-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-xl-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-xl-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-xl-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-xl-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-xl-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-xl-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-xl-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-xl-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-xl-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-xl-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-xl-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-xl-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-xl-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-xl-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n.float-left {\n float: left !important;\n}\n\n.float-right {\n float: right !important;\n}\n\n.float-none {\n float: none !important;\n}\n\n@media (min-width: 576px) {\n .float-sm-left {\n float: left !important;\n }\n .float-sm-right {\n float: right !important;\n }\n .float-sm-none {\n float: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .float-md-left {\n float: left !important;\n }\n .float-md-right {\n float: right !important;\n }\n .float-md-none {\n float: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .float-lg-left {\n float: left !important;\n }\n .float-lg-right {\n float: right !important;\n }\n .float-lg-none {\n float: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .float-xl-left {\n float: left !important;\n }\n .float-xl-right {\n float: right !important;\n }\n .float-xl-none {\n float: none !important;\n }\n}\n\n.fixed-top {\n position: fixed;\n top: 0;\n right: 0;\n left: 0;\n z-index: 1030;\n}\n\n.fixed-bottom {\n position: fixed;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1030;\n}\n\n.sticky-top {\n position: -webkit-sticky;\n position: sticky;\n top: 0;\n z-index: 1030;\n}\n\n.sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n border: 0;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n position: static;\n width: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n clip: auto;\n}\n\n.w-25 {\n width: 25% !important;\n}\n\n.w-50 {\n width: 50% !important;\n}\n\n.w-75 {\n width: 75% !important;\n}\n\n.w-100 {\n width: 100% !important;\n}\n\n.h-25 {\n height: 25% !important;\n}\n\n.h-50 {\n height: 50% !important;\n}\n\n.h-75 {\n height: 75% !important;\n}\n\n.h-100 {\n height: 100% !important;\n}\n\n.mw-100 {\n max-width: 100% !important;\n}\n\n.mh-100 {\n max-height: 100% !important;\n}\n\n.m-0 {\n margin: 0 0 !important;\n}\n\n.mt-0 {\n margin-top: 0 !important;\n}\n\n.mr-0 {\n margin-right: 0 !important;\n}\n\n.mb-0 {\n margin-bottom: 0 !important;\n}\n\n.ml-0 {\n margin-left: 0 !important;\n}\n\n.mx-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n}\n\n.my-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n}\n\n.m-1 {\n margin: 0.25rem 0.25rem !important;\n}\n\n.mt-1 {\n margin-top: 0.25rem !important;\n}\n\n.mr-1 {\n margin-right: 0.25rem !important;\n}\n\n.mb-1 {\n margin-bottom: 0.25rem !important;\n}\n\n.ml-1 {\n margin-left: 0.25rem !important;\n}\n\n.mx-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n}\n\n.my-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n}\n\n.m-2 {\n margin: 0.5rem 0.5rem !important;\n}\n\n.mt-2 {\n margin-top: 0.5rem !important;\n}\n\n.mr-2 {\n margin-right: 0.5rem !important;\n}\n\n.mb-2 {\n margin-bottom: 0.5rem !important;\n}\n\n.ml-2 {\n margin-left: 0.5rem !important;\n}\n\n.mx-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n}\n\n.my-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n}\n\n.m-3 {\n margin: 1rem 1rem !important;\n}\n\n.mt-3 {\n margin-top: 1rem !important;\n}\n\n.mr-3 {\n margin-right: 1rem !important;\n}\n\n.mb-3 {\n margin-bottom: 1rem !important;\n}\n\n.ml-3 {\n margin-left: 1rem !important;\n}\n\n.mx-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n}\n\n.my-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n}\n\n.m-4 {\n margin: 1.5rem 1.5rem !important;\n}\n\n.mt-4 {\n margin-top: 1.5rem !important;\n}\n\n.mr-4 {\n margin-right: 1.5rem !important;\n}\n\n.mb-4 {\n margin-bottom: 1.5rem !important;\n}\n\n.ml-4 {\n margin-left: 1.5rem !important;\n}\n\n.mx-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n}\n\n.my-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n}\n\n.m-5 {\n margin: 3rem 3rem !important;\n}\n\n.mt-5 {\n margin-top: 3rem !important;\n}\n\n.mr-5 {\n margin-right: 3rem !important;\n}\n\n.mb-5 {\n margin-bottom: 3rem !important;\n}\n\n.ml-5 {\n margin-left: 3rem !important;\n}\n\n.mx-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n}\n\n.my-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n}\n\n.p-0 {\n padding: 0 0 !important;\n}\n\n.pt-0 {\n padding-top: 0 !important;\n}\n\n.pr-0 {\n padding-right: 0 !important;\n}\n\n.pb-0 {\n padding-bottom: 0 !important;\n}\n\n.pl-0 {\n padding-left: 0 !important;\n}\n\n.px-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n}\n\n.py-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n}\n\n.p-1 {\n padding: 0.25rem 0.25rem !important;\n}\n\n.pt-1 {\n padding-top: 0.25rem !important;\n}\n\n.pr-1 {\n padding-right: 0.25rem !important;\n}\n\n.pb-1 {\n padding-bottom: 0.25rem !important;\n}\n\n.pl-1 {\n padding-left: 0.25rem !important;\n}\n\n.px-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n}\n\n.py-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n}\n\n.p-2 {\n padding: 0.5rem 0.5rem !important;\n}\n\n.pt-2 {\n padding-top: 0.5rem !important;\n}\n\n.pr-2 {\n padding-right: 0.5rem !important;\n}\n\n.pb-2 {\n padding-bottom: 0.5rem !important;\n}\n\n.pl-2 {\n padding-left: 0.5rem !important;\n}\n\n.px-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n}\n\n.py-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n}\n\n.p-3 {\n padding: 1rem 1rem !important;\n}\n\n.pt-3 {\n padding-top: 1rem !important;\n}\n\n.pr-3 {\n padding-right: 1rem !important;\n}\n\n.pb-3 {\n padding-bottom: 1rem !important;\n}\n\n.pl-3 {\n padding-left: 1rem !important;\n}\n\n.px-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n}\n\n.py-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n}\n\n.p-4 {\n padding: 1.5rem 1.5rem !important;\n}\n\n.pt-4 {\n padding-top: 1.5rem !important;\n}\n\n.pr-4 {\n padding-right: 1.5rem !important;\n}\n\n.pb-4 {\n padding-bottom: 1.5rem !important;\n}\n\n.pl-4 {\n padding-left: 1.5rem !important;\n}\n\n.px-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n}\n\n.py-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n}\n\n.p-5 {\n padding: 3rem 3rem !important;\n}\n\n.pt-5 {\n padding-top: 3rem !important;\n}\n\n.pr-5 {\n padding-right: 3rem !important;\n}\n\n.pb-5 {\n padding-bottom: 3rem !important;\n}\n\n.pl-5 {\n padding-left: 3rem !important;\n}\n\n.px-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n}\n\n.py-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n}\n\n.m-auto {\n margin: auto !important;\n}\n\n.mt-auto {\n margin-top: auto !important;\n}\n\n.mr-auto {\n margin-right: auto !important;\n}\n\n.mb-auto {\n margin-bottom: auto !important;\n}\n\n.ml-auto {\n margin-left: auto !important;\n}\n\n.mx-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n}\n\n.my-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n}\n\n@media (min-width: 576px) {\n .m-sm-0 {\n margin: 0 0 !important;\n }\n .mt-sm-0 {\n margin-top: 0 !important;\n }\n .mr-sm-0 {\n margin-right: 0 !important;\n }\n .mb-sm-0 {\n margin-bottom: 0 !important;\n }\n .ml-sm-0 {\n margin-left: 0 !important;\n }\n .mx-sm-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-sm-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-sm-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-sm-1 {\n margin-top: 0.25rem !important;\n }\n .mr-sm-1 {\n margin-right: 0.25rem !important;\n }\n .mb-sm-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-sm-1 {\n margin-left: 0.25rem !important;\n }\n .mx-sm-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-sm-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-sm-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-sm-2 {\n margin-top: 0.5rem !important;\n }\n .mr-sm-2 {\n margin-right: 0.5rem !important;\n }\n .mb-sm-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-sm-2 {\n margin-left: 0.5rem !important;\n }\n .mx-sm-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-sm-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-sm-3 {\n margin: 1rem 1rem !important;\n }\n .mt-sm-3 {\n margin-top: 1rem !important;\n }\n .mr-sm-3 {\n margin-right: 1rem !important;\n }\n .mb-sm-3 {\n margin-bottom: 1rem !important;\n }\n .ml-sm-3 {\n margin-left: 1rem !important;\n }\n .mx-sm-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-sm-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-sm-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-sm-4 {\n margin-top: 1.5rem !important;\n }\n .mr-sm-4 {\n margin-right: 1.5rem !important;\n }\n .mb-sm-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-sm-4 {\n margin-left: 1.5rem !important;\n }\n .mx-sm-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-sm-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-sm-5 {\n margin: 3rem 3rem !important;\n }\n .mt-sm-5 {\n margin-top: 3rem !important;\n }\n .mr-sm-5 {\n margin-right: 3rem !important;\n }\n .mb-sm-5 {\n margin-bottom: 3rem !important;\n }\n .ml-sm-5 {\n margin-left: 3rem !important;\n }\n .mx-sm-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-sm-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-sm-0 {\n padding: 0 0 !important;\n }\n .pt-sm-0 {\n padding-top: 0 !important;\n }\n .pr-sm-0 {\n padding-right: 0 !important;\n }\n .pb-sm-0 {\n padding-bottom: 0 !important;\n }\n .pl-sm-0 {\n padding-left: 0 !important;\n }\n .px-sm-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-sm-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-sm-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-sm-1 {\n padding-top: 0.25rem !important;\n }\n .pr-sm-1 {\n padding-right: 0.25rem !important;\n }\n .pb-sm-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-sm-1 {\n padding-left: 0.25rem !important;\n }\n .px-sm-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-sm-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-sm-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-sm-2 {\n padding-top: 0.5rem !important;\n }\n .pr-sm-2 {\n padding-right: 0.5rem !important;\n }\n .pb-sm-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-sm-2 {\n padding-left: 0.5rem !important;\n }\n .px-sm-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-sm-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-sm-3 {\n padding: 1rem 1rem !important;\n }\n .pt-sm-3 {\n padding-top: 1rem !important;\n }\n .pr-sm-3 {\n padding-right: 1rem !important;\n }\n .pb-sm-3 {\n padding-bottom: 1rem !important;\n }\n .pl-sm-3 {\n padding-left: 1rem !important;\n }\n .px-sm-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-sm-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-sm-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-sm-4 {\n padding-top: 1.5rem !important;\n }\n .pr-sm-4 {\n padding-right: 1.5rem !important;\n }\n .pb-sm-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-sm-4 {\n padding-left: 1.5rem !important;\n }\n .px-sm-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-sm-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-sm-5 {\n padding: 3rem 3rem !important;\n }\n .pt-sm-5 {\n padding-top: 3rem !important;\n }\n .pr-sm-5 {\n padding-right: 3rem !important;\n }\n .pb-sm-5 {\n padding-bottom: 3rem !important;\n }\n .pl-sm-5 {\n padding-left: 3rem !important;\n }\n .px-sm-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-sm-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-sm-auto {\n margin: auto !important;\n }\n .mt-sm-auto {\n margin-top: auto !important;\n }\n .mr-sm-auto {\n margin-right: auto !important;\n }\n .mb-sm-auto {\n margin-bottom: auto !important;\n }\n .ml-sm-auto {\n margin-left: auto !important;\n }\n .mx-sm-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-sm-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 768px) {\n .m-md-0 {\n margin: 0 0 !important;\n }\n .mt-md-0 {\n margin-top: 0 !important;\n }\n .mr-md-0 {\n margin-right: 0 !important;\n }\n .mb-md-0 {\n margin-bottom: 0 !important;\n }\n .ml-md-0 {\n margin-left: 0 !important;\n }\n .mx-md-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-md-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-md-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-md-1 {\n margin-top: 0.25rem !important;\n }\n .mr-md-1 {\n margin-right: 0.25rem !important;\n }\n .mb-md-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-md-1 {\n margin-left: 0.25rem !important;\n }\n .mx-md-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-md-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-md-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-md-2 {\n margin-top: 0.5rem !important;\n }\n .mr-md-2 {\n margin-right: 0.5rem !important;\n }\n .mb-md-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-md-2 {\n margin-left: 0.5rem !important;\n }\n .mx-md-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-md-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-md-3 {\n margin: 1rem 1rem !important;\n }\n .mt-md-3 {\n margin-top: 1rem !important;\n }\n .mr-md-3 {\n margin-right: 1rem !important;\n }\n .mb-md-3 {\n margin-bottom: 1rem !important;\n }\n .ml-md-3 {\n margin-left: 1rem !important;\n }\n .mx-md-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-md-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-md-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-md-4 {\n margin-top: 1.5rem !important;\n }\n .mr-md-4 {\n margin-right: 1.5rem !important;\n }\n .mb-md-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-md-4 {\n margin-left: 1.5rem !important;\n }\n .mx-md-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-md-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-md-5 {\n margin: 3rem 3rem !important;\n }\n .mt-md-5 {\n margin-top: 3rem !important;\n }\n .mr-md-5 {\n margin-right: 3rem !important;\n }\n .mb-md-5 {\n margin-bottom: 3rem !important;\n }\n .ml-md-5 {\n margin-left: 3rem !important;\n }\n .mx-md-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-md-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-md-0 {\n padding: 0 0 !important;\n }\n .pt-md-0 {\n padding-top: 0 !important;\n }\n .pr-md-0 {\n padding-right: 0 !important;\n }\n .pb-md-0 {\n padding-bottom: 0 !important;\n }\n .pl-md-0 {\n padding-left: 0 !important;\n }\n .px-md-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-md-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-md-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-md-1 {\n padding-top: 0.25rem !important;\n }\n .pr-md-1 {\n padding-right: 0.25rem !important;\n }\n .pb-md-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-md-1 {\n padding-left: 0.25rem !important;\n }\n .px-md-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-md-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-md-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-md-2 {\n padding-top: 0.5rem !important;\n }\n .pr-md-2 {\n padding-right: 0.5rem !important;\n }\n .pb-md-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-md-2 {\n padding-left: 0.5rem !important;\n }\n .px-md-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-md-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-md-3 {\n padding: 1rem 1rem !important;\n }\n .pt-md-3 {\n padding-top: 1rem !important;\n }\n .pr-md-3 {\n padding-right: 1rem !important;\n }\n .pb-md-3 {\n padding-bottom: 1rem !important;\n }\n .pl-md-3 {\n padding-left: 1rem !important;\n }\n .px-md-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-md-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-md-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-md-4 {\n padding-top: 1.5rem !important;\n }\n .pr-md-4 {\n padding-right: 1.5rem !important;\n }\n .pb-md-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-md-4 {\n padding-left: 1.5rem !important;\n }\n .px-md-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-md-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-md-5 {\n padding: 3rem 3rem !important;\n }\n .pt-md-5 {\n padding-top: 3rem !important;\n }\n .pr-md-5 {\n padding-right: 3rem !important;\n }\n .pb-md-5 {\n padding-bottom: 3rem !important;\n }\n .pl-md-5 {\n padding-left: 3rem !important;\n }\n .px-md-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-md-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-md-auto {\n margin: auto !important;\n }\n .mt-md-auto {\n margin-top: auto !important;\n }\n .mr-md-auto {\n margin-right: auto !important;\n }\n .mb-md-auto {\n margin-bottom: auto !important;\n }\n .ml-md-auto {\n margin-left: auto !important;\n }\n .mx-md-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-md-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 992px) {\n .m-lg-0 {\n margin: 0 0 !important;\n }\n .mt-lg-0 {\n margin-top: 0 !important;\n }\n .mr-lg-0 {\n margin-right: 0 !important;\n }\n .mb-lg-0 {\n margin-bottom: 0 !important;\n }\n .ml-lg-0 {\n margin-left: 0 !important;\n }\n .mx-lg-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-lg-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-lg-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-lg-1 {\n margin-top: 0.25rem !important;\n }\n .mr-lg-1 {\n margin-right: 0.25rem !important;\n }\n .mb-lg-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-lg-1 {\n margin-left: 0.25rem !important;\n }\n .mx-lg-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-lg-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-lg-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-lg-2 {\n margin-top: 0.5rem !important;\n }\n .mr-lg-2 {\n margin-right: 0.5rem !important;\n }\n .mb-lg-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-lg-2 {\n margin-left: 0.5rem !important;\n }\n .mx-lg-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-lg-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-lg-3 {\n margin: 1rem 1rem !important;\n }\n .mt-lg-3 {\n margin-top: 1rem !important;\n }\n .mr-lg-3 {\n margin-right: 1rem !important;\n }\n .mb-lg-3 {\n margin-bottom: 1rem !important;\n }\n .ml-lg-3 {\n margin-left: 1rem !important;\n }\n .mx-lg-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-lg-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-lg-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-lg-4 {\n margin-top: 1.5rem !important;\n }\n .mr-lg-4 {\n margin-right: 1.5rem !important;\n }\n .mb-lg-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-lg-4 {\n margin-left: 1.5rem !important;\n }\n .mx-lg-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-lg-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-lg-5 {\n margin: 3rem 3rem !important;\n }\n .mt-lg-5 {\n margin-top: 3rem !important;\n }\n .mr-lg-5 {\n margin-right: 3rem !important;\n }\n .mb-lg-5 {\n margin-bottom: 3rem !important;\n }\n .ml-lg-5 {\n margin-left: 3rem !important;\n }\n .mx-lg-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-lg-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-lg-0 {\n padding: 0 0 !important;\n }\n .pt-lg-0 {\n padding-top: 0 !important;\n }\n .pr-lg-0 {\n padding-right: 0 !important;\n }\n .pb-lg-0 {\n padding-bottom: 0 !important;\n }\n .pl-lg-0 {\n padding-left: 0 !important;\n }\n .px-lg-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-lg-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-lg-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-lg-1 {\n padding-top: 0.25rem !important;\n }\n .pr-lg-1 {\n padding-right: 0.25rem !important;\n }\n .pb-lg-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-lg-1 {\n padding-left: 0.25rem !important;\n }\n .px-lg-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-lg-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-lg-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-lg-2 {\n padding-top: 0.5rem !important;\n }\n .pr-lg-2 {\n padding-right: 0.5rem !important;\n }\n .pb-lg-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-lg-2 {\n padding-left: 0.5rem !important;\n }\n .px-lg-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-lg-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-lg-3 {\n padding: 1rem 1rem !important;\n }\n .pt-lg-3 {\n padding-top: 1rem !important;\n }\n .pr-lg-3 {\n padding-right: 1rem !important;\n }\n .pb-lg-3 {\n padding-bottom: 1rem !important;\n }\n .pl-lg-3 {\n padding-left: 1rem !important;\n }\n .px-lg-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-lg-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-lg-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-lg-4 {\n padding-top: 1.5rem !important;\n }\n .pr-lg-4 {\n padding-right: 1.5rem !important;\n }\n .pb-lg-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-lg-4 {\n padding-left: 1.5rem !important;\n }\n .px-lg-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-lg-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-lg-5 {\n padding: 3rem 3rem !important;\n }\n .pt-lg-5 {\n padding-top: 3rem !important;\n }\n .pr-lg-5 {\n padding-right: 3rem !important;\n }\n .pb-lg-5 {\n padding-bottom: 3rem !important;\n }\n .pl-lg-5 {\n padding-left: 3rem !important;\n }\n .px-lg-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-lg-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-lg-auto {\n margin: auto !important;\n }\n .mt-lg-auto {\n margin-top: auto !important;\n }\n .mr-lg-auto {\n margin-right: auto !important;\n }\n .mb-lg-auto {\n margin-bottom: auto !important;\n }\n .ml-lg-auto {\n margin-left: auto !important;\n }\n .mx-lg-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-lg-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 1200px) {\n .m-xl-0 {\n margin: 0 0 !important;\n }\n .mt-xl-0 {\n margin-top: 0 !important;\n }\n .mr-xl-0 {\n margin-right: 0 !important;\n }\n .mb-xl-0 {\n margin-bottom: 0 !important;\n }\n .ml-xl-0 {\n margin-left: 0 !important;\n }\n .mx-xl-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-xl-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-xl-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-xl-1 {\n margin-top: 0.25rem !important;\n }\n .mr-xl-1 {\n margin-right: 0.25rem !important;\n }\n .mb-xl-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-xl-1 {\n margin-left: 0.25rem !important;\n }\n .mx-xl-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-xl-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-xl-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-xl-2 {\n margin-top: 0.5rem !important;\n }\n .mr-xl-2 {\n margin-right: 0.5rem !important;\n }\n .mb-xl-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-xl-2 {\n margin-left: 0.5rem !important;\n }\n .mx-xl-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-xl-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-xl-3 {\n margin: 1rem 1rem !important;\n }\n .mt-xl-3 {\n margin-top: 1rem !important;\n }\n .mr-xl-3 {\n margin-right: 1rem !important;\n }\n .mb-xl-3 {\n margin-bottom: 1rem !important;\n }\n .ml-xl-3 {\n margin-left: 1rem !important;\n }\n .mx-xl-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-xl-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-xl-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-xl-4 {\n margin-top: 1.5rem !important;\n }\n .mr-xl-4 {\n margin-right: 1.5rem !important;\n }\n .mb-xl-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-xl-4 {\n margin-left: 1.5rem !important;\n }\n .mx-xl-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-xl-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-xl-5 {\n margin: 3rem 3rem !important;\n }\n .mt-xl-5 {\n margin-top: 3rem !important;\n }\n .mr-xl-5 {\n margin-right: 3rem !important;\n }\n .mb-xl-5 {\n margin-bottom: 3rem !important;\n }\n .ml-xl-5 {\n margin-left: 3rem !important;\n }\n .mx-xl-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-xl-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-xl-0 {\n padding: 0 0 !important;\n }\n .pt-xl-0 {\n padding-top: 0 !important;\n }\n .pr-xl-0 {\n padding-right: 0 !important;\n }\n .pb-xl-0 {\n padding-bottom: 0 !important;\n }\n .pl-xl-0 {\n padding-left: 0 !important;\n }\n .px-xl-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-xl-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-xl-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-xl-1 {\n padding-top: 0.25rem !important;\n }\n .pr-xl-1 {\n padding-right: 0.25rem !important;\n }\n .pb-xl-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-xl-1 {\n padding-left: 0.25rem !important;\n }\n .px-xl-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-xl-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-xl-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-xl-2 {\n padding-top: 0.5rem !important;\n }\n .pr-xl-2 {\n padding-right: 0.5rem !important;\n }\n .pb-xl-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-xl-2 {\n padding-left: 0.5rem !important;\n }\n .px-xl-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-xl-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-xl-3 {\n padding: 1rem 1rem !important;\n }\n .pt-xl-3 {\n padding-top: 1rem !important;\n }\n .pr-xl-3 {\n padding-right: 1rem !important;\n }\n .pb-xl-3 {\n padding-bottom: 1rem !important;\n }\n .pl-xl-3 {\n padding-left: 1rem !important;\n }\n .px-xl-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-xl-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-xl-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-xl-4 {\n padding-top: 1.5rem !important;\n }\n .pr-xl-4 {\n padding-right: 1.5rem !important;\n }\n .pb-xl-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-xl-4 {\n padding-left: 1.5rem !important;\n }\n .px-xl-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-xl-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-xl-5 {\n padding: 3rem 3rem !important;\n }\n .pt-xl-5 {\n padding-top: 3rem !important;\n }\n .pr-xl-5 {\n padding-right: 3rem !important;\n }\n .pb-xl-5 {\n padding-bottom: 3rem !important;\n }\n .pl-xl-5 {\n padding-left: 3rem !important;\n }\n .px-xl-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-xl-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-xl-auto {\n margin: auto !important;\n }\n .mt-xl-auto {\n margin-top: auto !important;\n }\n .mr-xl-auto {\n margin-right: auto !important;\n }\n .mb-xl-auto {\n margin-bottom: auto !important;\n }\n .ml-xl-auto {\n margin-left: auto !important;\n }\n .mx-xl-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-xl-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n.text-justify {\n text-align: justify !important;\n}\n\n.text-nowrap {\n white-space: nowrap !important;\n}\n\n.text-truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.text-left {\n text-align: left !important;\n}\n\n.text-right {\n text-align: right !important;\n}\n\n.text-center {\n text-align: center !important;\n}\n\n@media (min-width: 576px) {\n .text-sm-left {\n text-align: left !important;\n }\n .text-sm-right {\n text-align: right !important;\n }\n .text-sm-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 768px) {\n .text-md-left {\n text-align: left !important;\n }\n .text-md-right {\n text-align: right !important;\n }\n .text-md-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 992px) {\n .text-lg-left {\n text-align: left !important;\n }\n .text-lg-right {\n text-align: right !important;\n }\n .text-lg-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 1200px) {\n .text-xl-left {\n text-align: left !important;\n }\n .text-xl-right {\n text-align: right !important;\n }\n .text-xl-center {\n text-align: center !important;\n }\n}\n\n.text-lowercase {\n text-transform: lowercase !important;\n}\n\n.text-uppercase {\n text-transform: uppercase !important;\n}\n\n.text-capitalize {\n text-transform: capitalize !important;\n}\n\n.font-weight-normal {\n font-weight: normal;\n}\n\n.font-weight-bold {\n font-weight: bold;\n}\n\n.font-italic {\n font-style: italic;\n}\n\n.text-white {\n color: #fff !important;\n}\n\n.text-muted {\n color: #636c72 !important;\n}\n\na.text-muted:focus, a.text-muted:hover {\n color: #4b5257 !important;\n}\n\n.text-primary {\n color: #0275d8 !important;\n}\n\na.text-primary:focus, a.text-primary:hover {\n color: #025aa5 !important;\n}\n\n.text-success {\n color: #5cb85c !important;\n}\n\na.text-success:focus, a.text-success:hover {\n color: #449d44 !important;\n}\n\n.text-info {\n color: #5bc0de !important;\n}\n\na.text-info:focus, a.text-info:hover {\n color: #31b0d5 !important;\n}\n\n.text-warning {\n color: #f0ad4e !important;\n}\n\na.text-warning:focus, a.text-warning:hover {\n color: #ec971f !important;\n}\n\n.text-danger {\n color: #d9534f !important;\n}\n\na.text-danger:focus, a.text-danger:hover {\n color: #c9302c !important;\n}\n\n.text-gray-dark {\n color: #292b2c !important;\n}\n\na.text-gray-dark:focus, a.text-gray-dark:hover {\n color: #101112 !important;\n}\n\n.text-hide {\n font: 0/0 a;\n color: transparent;\n text-shadow: none;\n background-color: transparent;\n border: 0;\n}\n\n.invisible {\n visibility: hidden !important;\n}\n\n.hidden-xs-up {\n display: none !important;\n}\n\n@media (max-width: 575px) {\n .hidden-xs-down {\n display: none !important;\n }\n}\n\n@media (min-width: 576px) {\n .hidden-sm-up {\n display: none !important;\n }\n}\n\n@media (max-width: 767px) {\n .hidden-sm-down {\n display: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .hidden-md-up {\n display: none !important;\n }\n}\n\n@media (max-width: 991px) {\n .hidden-md-down {\n display: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .hidden-lg-up {\n display: none !important;\n }\n}\n\n@media (max-width: 1199px) {\n .hidden-lg-down {\n display: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .hidden-xl-up {\n display: none !important;\n }\n}\n\n.hidden-xl-down {\n display: none !important;\n}\n\n.visible-print-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-block {\n display: block !important;\n }\n}\n\n.visible-print-inline {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline {\n display: inline !important;\n }\n}\n\n.visible-print-inline-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline-block {\n display: inline-block !important;\n }\n}\n\n@media print {\n .hidden-print {\n display: none !important;\n }\n}", ""]); + createClass(Input, [{ + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + type = _props.type, + size = _props.size, + state = _props.state, + tag = _props.tag, + addon = _props.addon, + staticInput = _props.static, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'type', 'size', 'state', 'tag', 'addon', 'static', 'getRef']); -// exports + var checkInput = ['radio', 'checkbox'].indexOf(type) > -1; -/***/ }), -/* 119 */ -/***/ (function(module, exports) { + var fileInput = type === 'file'; + var textareaInput = type === 'textarea'; + var selectInput = type === 'select'; + var Tag = selectInput || textareaInput ? type : 'input'; + var formControlClass = 'form-control'; -/** - * When source maps are enabled, `style-loader` uses a link element with a data-uri to - * embed the css on the page. This breaks all relative urls because now they are relative to a - * bundle instead of the current page. - * - * One solution is to only use full urls, but that may be impossible. - * - * Instead, this function "fixes" the relative urls to be absolute according to the current page location. - * - * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command. - * - */ + if (staticInput) { + formControlClass = formControlClass + '-static'; + Tag = tag; + } else if (fileInput) { + formControlClass = formControlClass + '-file'; + } else if (checkInput) { + if (addon) { + formControlClass = null; + } else { + formControlClass = 'form-check-input'; + } + } -module.exports = function (css) { - // get current location - var location = typeof window !== "undefined" && window.location; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, state ? 'form-control-' + state : false, size ? 'form-control-' + size : false, formControlClass), cssModule); - if (!location) { - throw new Error("fixUrls requires window.location"); - } + if (Tag === 'input') { + attributes.type = type; + } - // blank or null? - if (!css || typeof css !== "string") { - return css; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); + } + }]); + return Input; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - var baseUrl = location.protocol + "//" + location.host; - var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/"); +Input.propTypes = propTypes$51; +Input.defaultProps = defaultProps$50; - // convert each url(...) - /* - This regular expression is just a way to recursively match brackets within - a string. +var propTypes$52 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - /url\s*\( = Match on the word "url" with any whitespace after it and then a parens - ( = Start a capturing group - (?: = Start a non-capturing group - [^)(] = Match anything that isn't a parentheses - | = OR - \( = Match a start parentheses - (?: = Start another non-capturing groups - [^)(]+ = Match anything that isn't a parentheses - | = OR - \( = Match a start parentheses - [^)(]* = Match anything that isn't a parentheses - \) = Match a end parentheses - ) = End Group - *\) = Match anything and then a close parens - ) = Close non-capturing group - * = Match anything - ) = Close capturing group - \) = Match a close parens +var defaultProps$51 = { + tag: 'div' +}; - /gi = Get all matches, not the first. Be case insensitive. - */ - var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) { - // strip quotes (if they exist) - var unquotedOrigUrl = origUrl - .trim() - .replace(/^"(.*)"$/, function(o, $1){ return $1; }) - .replace(/^'(.*)'$/, function(o, $1){ return $1; }); +var InputGroup = function InputGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + size = props.size, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'size']); - // already a full url? no change - if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(unquotedOrigUrl)) { - return fullMatch; - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group', size ? 'input-group-' + size : null), cssModule); - // convert the url to a full url - var newUrl; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (unquotedOrigUrl.indexOf("//") === 0) { - //TODO: should we add protocol? - newUrl = unquotedOrigUrl; - } else if (unquotedOrigUrl.indexOf("/") === 0) { - // path should be relative to the base url - newUrl = baseUrl + unquotedOrigUrl; // already starts with '/' - } else { - // path should be relative to current directory - newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './' - } +InputGroup.propTypes = propTypes$52; +InputGroup.defaultProps = defaultProps$51; - // send back the fixed url(...) - return "url(" + JSON.stringify(newUrl) + ")"; - }); +var propTypes$53 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - // send back the fixed css - return fixedCss; +var defaultProps$52 = { + tag: 'div' }; +var InputGroupAddon = function InputGroupAddon(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -/***/ }), -/* 120 */ -/***/ (function(module, exports, __webpack_require__) { + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-addon'), cssModule); -// style-loader: Adds some css to the DOM by adding a <style> tag + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -// load the styles -var content = __webpack_require__(121); -if(typeof content === 'string') content = [[module.i, content, '']]; -// Prepare cssTransformation -var transform; +InputGroupAddon.propTypes = propTypes$53; +InputGroupAddon.defaultProps = defaultProps$52; -var options = {} -options.transform = transform -// add the styles to the DOM -var update = __webpack_require__(73)(content, options); -if(content.locals) module.exports = content.locals; -// Hot Module Replacement -if(false) { - // When the styles change, update the <style> tags - if(!content.locals) { - module.hot.accept("!!../../css-loader/index.js!./react-bootstrap-table-all.min.css", function() { - var newContent = require("!!../../css-loader/index.js!./react-bootstrap-table-all.min.css"); - if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; - update(newContent); - }); - } - // When the module is disposed, remove the <style> tags - module.hot.dispose(function() { update(); }); -} +var propTypes$54 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + groupClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + groupAttributes: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -/***/ }), -/* 121 */ -/***/ (function(module, exports, __webpack_require__) { +var defaultProps$53 = { + tag: 'div' +}; -exports = module.exports = __webpack_require__(72)(undefined); -// imports +var InputGroupButton = function InputGroupButton(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + children = props.children, + groupClassName = props.groupClassName, + groupAttributes = props.groupAttributes, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'children', 'groupClassName', 'groupAttributes']); -// module -exports.push([module.i, ".react-bs-table .react-bs-container-header .sort-column,.s-alert-close,td.react-bs-table-expand-cell{cursor:pointer}.react-bs-table-container .react-bs-table-search-form{margin-bottom:0}.react-bs-table-bordered{border:1px solid #ddd;border-radius:5px}.react-bs-table table{margin-bottom:0;table-layout:fixed}.react-bs-table table td,.react-bs-table table th{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.react-bs-table-pagination{margin-top:10px}.react-bs-table-tool-bar{margin-bottom:5px}.react-bs-container-header{overflow:hidden;width:100%}.react-bs-container-body{overflow:auto;width:100%}.react-bootstrap-table-page-btns-ul{float:right;margin-top:0}.react-bs-table .table-bordered{border:0;outline:0!important}.react-bs-table .table-bordered>thead>tr>td,.react-bs-table .table-bordered>thead>tr>th{border-bottom-width:2px}.react-bs-table .table-bordered>tbody>tr>td{outline:0!important}.react-bs-table .table-bordered>tbody>tr>td.default-focus-cell{outline:#6495ed solid 3px!important;outline-offset:-1px}.react-bs-table .table-bordered>tfoot>tr>td,.react-bs-table .table-bordered>tfoot>tr>th{border-top-width:2px;border-bottom-width:0}.react-bs-table .table-bordered>tbody>tr>td:first-child,.react-bs-table .table-bordered>tbody>tr>th:first-child,.react-bs-table .table-bordered>tfoot>tr>td:first-child,.react-bs-table .table-bordered>tfoot>tr>th:first-child,.react-bs-table .table-bordered>thead>tr>td:first-child,.react-bs-table .table-bordered>thead>tr>th:first-child{border-left-width:0}.react-bs-table .table-bordered>tbody>tr>td:last-child,.react-bs-table .table-bordered>tbody>tr>th:last-child,.react-bs-table .table-bordered>tfoot>tr>td:last-child,.react-bs-table .table-bordered>tfoot>tr>th:last-child,.react-bs-table .table-bordered>thead>tr>td:last-child,.react-bs-table .table-bordered>thead>tr>th:last-child{border-right-width:0}.react-bs-table .table-bordered>thead>tr:first-child>td,.react-bs-table .table-bordered>thead>tr:first-child>th{border-top-width:0}.react-bs-table .table-bordered>tfoot>tr:last-child>td,.react-bs-table .table-bordered>tfoot>tr:last-child>th{border-bottom-width:0}.react-bs-table .react-bs-container-header>table>thead>tr>th{vertical-align:middle}.react-bs-table .react-bs-container-header>table>thead>tr>th .filter{font-weight:400}.react-bs-table .react-bs-container-header>table>thead>tr>th .filter::-webkit-input-placeholder,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-input::-webkit-input-placeholder,.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter option[value=''],.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter.placeholder-selected{color:#d3d3d3;font-style:italic}.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter.placeholder-selected option:not([value='']){color:initial;font-style:initial}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter{display:flex}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter-input,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-input{margin-left:5px;float:left;width:calc(100% - 67px - 5px)}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter-comparator,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-comparator{width:67px;float:left}.react-bs-container .textarea-save-btn{position:absolute;z-index:100;right:0;top:-21px}.react-bs-table-no-data{text-align:center}.ReactModal__Overlay{-webkit-perspective:600;perspective:600;opacity:0;overflow-x:hidden;overflow-y:auto;background-color:rgba(0,0,0,.5);z-index:101}.ReactModal__Overlay--after-open{opacity:1;transition:opacity 150ms ease-out}.ReactModal__Content{-webkit-transform:scale(.5) rotateX(-30deg);transform:scale(.5) rotateX(-30deg)}.ReactModal__Content--after-open{-webkit-transform:scale(1) rotateX(0);transform:scale(1) rotateX(0);transition:all 150ms ease-in}.ReactModal__Overlay--before-close{opacity:0}.ReactModal__Content--before-close{-webkit-transform:scale(.5) rotateX(30deg);transform:scale(.5) rotateX(30deg);transition:all 150ms ease-in}.ReactModal__Content.modal-dialog{border:none;background-color:transparent}.animated{animation-fill-mode:both}.animated.bounceIn,.animated.bounceOut{animation-duration:.75s}.animated.shake{animation-duration:.3s}@keyframes shake{from,to{transform:translate3d(0,0,0)}10%,50%,90%{transform:translate3d(-10px,0,0)}30%,70%{transform:translate3d(10px,0,0)}}.shake{animation-name:shake}@keyframes bounceIn{20%,40%,60%,80%,from,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:scale3d(.3,.3,.3)}20%{transform:scale3d(1.1,1.1,1.1)}40%{transform:scale3d(.9,.9,.9)}60%{opacity:1;transform:scale3d(1.03,1.03,1.03)}80%{transform:scale3d(.97,.97,.97)}to{opacity:1;transform:scale3d(1,1,1)}}.bounceIn{animation-name:bounceIn}@keyframes bounceOut{20%{transform:scale3d(.9,.9,.9)}50%,55%{opacity:1;transform:scale3d(1.1,1.1,1.1)}to{opacity:0;transform:scale3d(.3,.3,.3)}}.bounceOut{animation-name:bounceOut}.s-alert-box,.s-alert-box *{box-sizing:border-box}.s-alert-box{position:fixed;background:rgba(42,45,50,.85);padding:22px;line-height:1.4;z-index:1000;pointer-events:none;color:rgba(250,251,255,.95);font-size:100%;font-family:'Helvetica Neue','Segoe UI',Helvetica,Arial,sans-serif;max-width:300px;-webkit-transition:top .4s,bottom .4s;transition:top .4s,bottom .4s}.s-alert-box.s-alert-show,.s-alert-box.s-alert-visible{pointer-events:auto}.s-alert-box a{color:inherit;opacity:.7;font-weight:700}.s-alert-box a:focus,.s-alert-box a:hover{opacity:1}.s-alert-box p{margin:0}.s-alert-close{width:20px;height:20px;position:absolute;right:4px;top:4px;overflow:hidden;text-indent:100%;-webkit-backface-visibility:hidden;backface-visibility:hidden}.s-alert-close:focus,.s-alert-close:hover{outline:0}.s-alert-close::after,.s-alert-close::before{content:'';position:absolute;width:3px;height:60%;top:50%;left:50%;background:#fff}.s-alert-close:hover::after,.s-alert-close:hover::before{background:#fff}.s-alert-close::before{-webkit-transform:translate(-50%,-50%) rotate(45deg);transform:translate(-50%,-50%) rotate(45deg)}.s-alert-close::after{-webkit-transform:translate(-50%,-50%) rotate(-45deg);transform:translate(-50%,-50%) rotate(-45deg)}.s-alert-bottom-left{top:auto;right:auto;bottom:30px;left:30px}.s-alert-top-left{top:30px;right:auto;bottom:auto;left:30px}.s-alert-top-right{top:30px;right:30px;bottom:auto;left:auto}.s-alert-bottom-right{top:auto;right:30px;bottom:30px;left:auto}.s-alert-bottom,.s-alert-top{width:100%;max-width:100%;left:0;right:0}.s-alert-bottom{bottom:0;top:auto}.s-alert-top{top:0;bottom:auto}.s-alert-info{background:#00A2D3;color:#fff}.s-alert-success{background:#27AE60;color:#fff}.s-alert-warning{background:#F1C40F;color:#fff}.s-alert-error{background:#E74C3C;color:#fff}[class*=\" s-alert-effect-\"].s-alert-hide,[class^=s-alert-effect-].s-alert-hide{-webkit-animation-direction:reverse;animation-direction:reverse}.s-alert-box-height{visibility:hidden;position:fixed}.s-alert-effect-scale a,.s-alert-effect-scale a:focus,.s-alert-effect-scale a:hover{color:#fff}.s-alert-effect-scale .s-alert-close::after,.s-alert-effect-scale .s-alert-close::before,.s-alert-effect-scale .s-alert-close:hover::after,.s-alert-effect-scale .s-alert-close:hover::before{background:#fff}.s-alert-effect-scale.s-alert-hide,.s-alert-effect-scale.s-alert-show{-webkit-animation-name:animScale;animation-name:animScale;-webkit-animation-duration:.25s;animation-duration:.25s}@-webkit-keyframes animScale{0%{opacity:0;-webkit-transform:translate3d(0,40px,0) scale3d(.1,.6,1)}100%{opacity:1;-webkit-transform:translate3d(0,0,0) scale3d(1,1,1)}}@keyframes animScale{0%{opacity:0;-webkit-transform:translate3d(0,40px,0) scale3d(.1,.6,1);transform:translate3d(0,40px,0) scale3d(.1,.6,1)}100%{opacity:1;-webkit-transform:translate3d(0,0,0) scale3d(1,1,1);transform:translate3d(0,0,0) scale3d(1,1,1)}}", ""]); + if (typeof children === 'string') { + var groupClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(groupClassName, 'input-group-btn'), cssModule); -// exports + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, groupAttributes, { className: groupClasses }), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Button, _extends({}, attributes, { className: className, children: children })) + ); + } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-btn'), cssModule); -/***/ }), -/* 122 */ -/***/ (function(module, exports, __webpack_require__) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes, children: children })); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +InputGroupButton.propTypes = propTypes$54; +InputGroupButton.defaultProps = defaultProps$53; +var colSizes = ['xs', 'sm', 'md', 'lg', 'xl']; +var stringOrNumberProp$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); -var PooledClass = __webpack_require__(123); -var ReactElement = __webpack_require__(19); +var columnProps$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + size: stringOrNumberProp$1, + push: stringOrNumberProp$1, + pull: stringOrNumberProp$1, + offset: stringOrNumberProp$1 +})]); -var emptyFunction = __webpack_require__(12); -var traverseAllChildren = __webpack_require__(124); +var propTypes$55 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + hidden: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + for: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + xs: columnProps$1, + sm: columnProps$1, + md: columnProps$1, + lg: columnProps$1, + xl: columnProps$1 +}; -var twoArgumentPooler = PooledClass.twoArgumentPooler; -var fourArgumentPooler = PooledClass.fourArgumentPooler; +var defaultProps$54 = { + tag: 'label' +}; -var userProvidedKeyEscapeRegex = /\/+/g; -function escapeUserProvidedKey(text) { - return ('' + text).replace(userProvidedKeyEscapeRegex, '$&/'); -} +var Label = function Label(props) { + var className = props.className, + cssModule = props.cssModule, + hidden = props.hidden, + Tag = props.tag, + check = props.check, + inline = props.inline, + disabled = props.disabled, + size = props.size, + htmlFor = props.for, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'hidden', 'tag', 'check', 'inline', 'disabled', 'size', 'for']); -/** - * PooledClass representing the bookkeeping associated with performing a child - * traversal. Allows avoiding binding callbacks. - * - * @constructor ForEachBookKeeping - * @param {!function} forEachFunction Function to perform traversal with. - * @param {?*} forEachContext Context to perform context with. - */ -function ForEachBookKeeping(forEachFunction, forEachContext) { - this.func = forEachFunction; - this.context = forEachContext; - this.count = 0; -} -ForEachBookKeeping.prototype.destructor = function () { - this.func = null; - this.context = null; - this.count = 0; -}; -PooledClass.addPoolingTo(ForEachBookKeeping, twoArgumentPooler); -function forEachSingleChild(bookKeeping, child, name) { - var func = bookKeeping.func, - context = bookKeeping.context; + var colClasses = []; - func.call(context, child, bookKeeping.count++); -} + colSizes.forEach(function (colSize) { + var columnProp = props[colSize]; + delete attributes[colSize]; -/** - * Iterates through children that are typically specified as `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.foreach - * - * The provided forEachFunc(child, index) will be called for each - * leaf child. - * - * @param {?*} children Children tree container. - * @param {function(*, int)} forEachFunc - * @param {*} forEachContext Context for forEachContext. - */ -function forEachChildren(children, forEachFunc, forEachContext) { - if (children == null) { - return children; - } - var traverseContext = ForEachBookKeeping.getPooled(forEachFunc, forEachContext); - traverseAllChildren(children, forEachSingleChild, traverseContext); - ForEachBookKeeping.release(traverseContext); -} + if (columnProp && columnProp.size) { + var _classNames; -/** - * PooledClass representing the bookkeeping associated with performing a child - * mapping. Allows avoiding binding callbacks. - * - * @constructor MapBookKeeping - * @param {!*} mapResult Object containing the ordered map of results. - * @param {!function} mapFunction Function to perform mapping with. - * @param {?*} mapContext Context to perform mapping with. - */ -function MapBookKeeping(mapResult, keyPrefix, mapFunction, mapContext) { - this.result = mapResult; - this.keyPrefix = keyPrefix; - this.func = mapFunction; - this.context = mapContext; - this.count = 0; -} -MapBookKeeping.prototype.destructor = function () { - this.result = null; - this.keyPrefix = null; - this.func = null; - this.context = null; - this.count = 0; + colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, 'col-' + colSize + '-' + columnProp.size, columnProp.size), defineProperty(_classNames, 'push-' + colSize + '-' + columnProp.push, columnProp.push), defineProperty(_classNames, 'pull-' + colSize + '-' + columnProp.pull, columnProp.pull), defineProperty(_classNames, 'offset-' + colSize + '-' + columnProp.offset, columnProp.offset), _classNames))), cssModule); + } else if (columnProp) { + colClasses.push('col-' + colSize + '-' + columnProp); + } + }); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, hidden ? 'sr-only' : false, check ? 'form-check-' + (inline ? 'inline' : 'label') : false, check && inline && disabled ? 'disabled' : false, size ? 'col-form-label-' + size : false, colClasses, colClasses.length ? 'col-form-label' : false, !check && !colClasses.length ? 'form-control-label' : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ htmlFor: htmlFor }, attributes, { className: classes })); }; -PooledClass.addPoolingTo(MapBookKeeping, fourArgumentPooler); -function mapSingleChildIntoContext(bookKeeping, child, childKey) { - var result = bookKeeping.result, - keyPrefix = bookKeeping.keyPrefix, - func = bookKeeping.func, - context = bookKeeping.context; +Label.propTypes = propTypes$55; +Label.defaultProps = defaultProps$54; +var propTypes$56 = { + body: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + heading: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + list: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + middle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + object: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; - var mappedChild = func.call(context, child, bookKeeping.count++); - if (Array.isArray(mappedChild)) { - mapIntoWithKeyPrefixInternal(mappedChild, result, childKey, emptyFunction.thatReturnsArgument); - } else if (mappedChild != null) { - if (ReactElement.isValidElement(mappedChild)) { - mappedChild = ReactElement.cloneAndReplaceKey(mappedChild, - // Keep both the (mapped) and old keys if they differ, just as - // traverseAllChildren used to do for objects as children - keyPrefix + (mappedChild.key && (!child || child.key !== mappedChild.key) ? escapeUserProvidedKey(mappedChild.key) + '/' : '') + childKey); - } - result.push(mappedChild); - } -} +var Media = function Media(props) { + var body = props.body, + bottom = props.bottom, + className = props.className, + cssModule = props.cssModule, + heading = props.heading, + left = props.left, + list = props.list, + middle = props.middle, + object = props.object, + right = props.right, + tag = props.tag, + top = props.top, + attributes = objectWithoutProperties(props, ['body', 'bottom', 'className', 'cssModule', 'heading', 'left', 'list', 'middle', 'object', 'right', 'tag', 'top']); -function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) { - var escapedPrefix = ''; - if (prefix != null) { - escapedPrefix = escapeUserProvidedKey(prefix) + '/'; - } - var traverseContext = MapBookKeeping.getPooled(array, escapedPrefix, func, context); - traverseAllChildren(children, mapSingleChildIntoContext, traverseContext); - MapBookKeeping.release(traverseContext); -} -/** - * Maps children that are typically specified as `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.map - * - * The provided mapFunction(child, key, index) will be called for each - * leaf child. - * - * @param {?*} children Children tree container. - * @param {function(*, int)} func The map function. - * @param {*} context Context for mapFunction. - * @return {object} Object containing the ordered map of results. - */ -function mapChildren(children, func, context) { - if (children == null) { - return children; + var defaultTag = void 0; + if (heading) { + defaultTag = 'h4'; + } else if (left || right) { + defaultTag = 'a'; + } else if (object) { + defaultTag = 'img'; + } else if (list) { + defaultTag = 'ul'; + } else { + defaultTag = 'div'; } - var result = []; - mapIntoWithKeyPrefixInternal(children, result, null, func, context); - return result; -} + var Tag = tag || defaultTag; -function forEachSingleChildDummy(traverseContext, child, name) { - return null; -} + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + 'media-body': body, + 'media-heading': heading, + 'media-left': left, + 'media-right': right, + 'media-top': top, + 'media-bottom': bottom, + 'media-middle': middle, + 'media-object': object, + 'media-list': list, + media: !body && !heading && !left && !right && !top && !bottom && !middle && !object && !list + }), cssModule); -/** - * Count the number of children that are typically specified as - * `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.count - * - * @param {?*} children Children tree container. - * @return {number} The number of children. - */ -function countChildren(children, context) { - return traverseAllChildren(children, forEachSingleChildDummy, null); -} + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -/** - * Flatten a children object (typically specified as `props.children`) and - * return an array with appropriately re-keyed children. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.toarray - */ -function toArray(children) { - var result = []; - mapIntoWithKeyPrefixInternal(children, result, null, emptyFunction.thatReturnsArgument); - return result; -} +Media.propTypes = propTypes$56; -var ReactChildren = { - forEach: forEachChildren, - map: mapChildren, - mapIntoWithKeyPrefixInternal: mapIntoWithKeyPrefixInternal, - count: countChildren, - toArray: toArray +var propTypes$57 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) }; -module.exports = ReactChildren; +var defaultProps$55 = { + tag: 'ul' +}; -/***/ }), -/* 123 */ -/***/ (function(module, exports, __webpack_require__) { +var Pagination = function Pagination(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'tag']); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'pagination', defineProperty({}, 'pagination-' + size, !!size)), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var _prodInvariant = __webpack_require__(25); +Pagination.propTypes = propTypes$57; +Pagination.defaultProps = defaultProps$55; -var invariant = __webpack_require__(1); +var propTypes$58 = { + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; -/** - * Static poolers. Several custom versions for each potential number of - * arguments. A completely generic pooler is easy to implement, but would - * require accessing the `arguments` object. In each of these, `this` refers to - * the Class itself, not an instance. If any others are needed, simply add them - * here, or in their own files. - */ -var oneArgumentPooler = function (copyFieldsFrom) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, copyFieldsFrom); - return instance; - } else { - return new Klass(copyFieldsFrom); - } +var defaultProps$56 = { + tag: 'li' }; -var twoArgumentPooler = function (a1, a2) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2); - return instance; - } else { - return new Klass(a1, a2); - } -}; +var PaginationItem = function PaginationItem(props) { + var active = props.active, + className = props.className, + cssModule = props.cssModule, + disabled = props.disabled, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['active', 'className', 'cssModule', 'disabled', 'tag']); -var threeArgumentPooler = function (a1, a2, a3) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3); - return instance; - } else { - return new Klass(a1, a2, a3); - } -}; -var fourArgumentPooler = function (a1, a2, a3, a4) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3, a4); - return instance; - } else { - return new Klass(a1, a2, a3, a4); - } -}; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-item', { + active: active, + disabled: disabled + }), cssModule); -var standardReleaser = function (instance) { - var Klass = this; - !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; - instance.destructor(); - if (Klass.instancePool.length < Klass.poolSize) { - Klass.instancePool.push(instance); - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -var DEFAULT_POOL_SIZE = 10; -var DEFAULT_POOLER = oneArgumentPooler; +PaginationItem.propTypes = propTypes$58; +PaginationItem.defaultProps = defaultProps$56; -/** - * Augments `CopyConstructor` to be a poolable class, augmenting only the class - * itself (statically) not adding any prototypical fields. Any CopyConstructor - * you give this may have a `poolSize` property, and will look for a - * prototypical `destructor` on instances. - * - * @param {Function} CopyConstructor Constructor that can be used to reset. - * @param {Function} pooler Customizable pooler. - */ -var addPoolingTo = function (CopyConstructor, pooler) { - // Casting as any so that flow ignores the actual implementation and trusts - // it to match the type we declared - var NewKlass = CopyConstructor; - NewKlass.instancePool = []; - NewKlass.getPooled = pooler || DEFAULT_POOLER; - if (!NewKlass.poolSize) { - NewKlass.poolSize = DEFAULT_POOL_SIZE; - } - NewKlass.release = standardReleaser; - return NewKlass; +var propTypes$59 = { + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + next: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + previous: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) }; -var PooledClass = { - addPoolingTo: addPoolingTo, - oneArgumentPooler: oneArgumentPooler, - twoArgumentPooler: twoArgumentPooler, - threeArgumentPooler: threeArgumentPooler, - fourArgumentPooler: fourArgumentPooler +var defaultProps$57 = { + tag: 'a' }; -module.exports = PooledClass; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 124 */ -/***/ (function(module, exports, __webpack_require__) { +var PaginationLink = function PaginationLink(props) { + var className = props.className, + cssModule = props.cssModule, + next = props.next, + previous = props.previous, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'next', 'previous', 'tag']); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-link'), cssModule); + var defaultAriaLabel = void 0; + if (previous) { + defaultAriaLabel = 'Previous'; + } else if (next) { + defaultAriaLabel = 'Next'; + } + var ariaLabel = props['aria-label'] || defaultAriaLabel; -var _prodInvariant = __webpack_require__(25); + var defaultCaret = void 0; + if (previous) { + defaultCaret = '\xAB'; + } else if (next) { + defaultCaret = '\xBB'; + } -var ReactCurrentOwner = __webpack_require__(14); -var REACT_ELEMENT_TYPE = __webpack_require__(76); + var children = props.children; + if (previous || next) { + children = [__WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { + 'aria-hidden': 'true', + key: 'caret' + }, + children || defaultCaret + ), __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { + className: 'sr-only', + key: 'sr' + }, + ariaLabel + )]; + } -var getIteratorFn = __webpack_require__(77); -var invariant = __webpack_require__(1); -var KeyEscapeUtils = __webpack_require__(125); -var warning = __webpack_require__(2); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { + className: classes, + 'aria-label': ariaLabel + }), + children + ); +}; -var SEPARATOR = '.'; -var SUBSEPARATOR = ':'; +PaginationLink.propTypes = propTypes$59; +PaginationLink.defaultProps = defaultProps$57; -/** - * This is inlined from ReactElement since this file is shared between - * isomorphic and renderers. We could extract this to a - * - */ +var propTypes$60 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + activeTab: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -/** - * TODO: Test that a single child and an array with one item have the same key - * pattern. - */ +var defaultProps$58 = { + tag: 'div' +}; -var didWarnAboutMaps = false; +var childContextTypes$1 = { + activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -/** - * Generate a key string that identifies a component within a set. - * - * @param {*} component A component that could contain a manual key. - * @param {number} index Index that is used if a manual key is not provided. - * @return {string} - */ -function getComponentKey(component, index) { - // Do some typechecking here since we call this blindly. We want to ensure - // that we don't block potential future ES APIs. - if (component && typeof component === 'object' && component.key != null) { - // Explicit key - return KeyEscapeUtils.escape(component.key); - } - // Implicit key determined by the index in the set - return index.toString(36); -} +var TabContent = function (_Component) { + inherits(TabContent, _Component); -/** - * @param {?*} children Children tree container. - * @param {!string} nameSoFar Name of the key path so far. - * @param {!function} callback Callback to invoke with each child found. - * @param {?*} traverseContext Used to pass information throughout the traversal - * process. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { - var type = typeof children; + function TabContent(props) { + classCallCheck(this, TabContent); - if (type === 'undefined' || type === 'boolean') { - // All of the above are perceived as null. - children = null; - } + var _this = possibleConstructorReturn(this, (TabContent.__proto__ || Object.getPrototypeOf(TabContent)).call(this, props)); - if (children === null || type === 'string' || type === 'number' || - // The following is inlined from ReactElement. This means we can optimize - // some checks. React Fiber also inlines this logic for similar purposes. - type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { - callback(traverseContext, children, - // If it's the only child, treat the name as if it was wrapped in an array - // so that it's consistent if the number of children grows. - nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); - return 1; + _this.state = { + activeTab: _this.props.activeTab + }; + return _this; } - var child; - var nextName; - var subtreeCount = 0; // Count of children found in the current subtree. - var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; - - if (Array.isArray(children)) { - for (var i = 0; i < children.length; i++) { - child = children[i]; - nextName = nextNamePrefix + getComponentKey(child, i); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + createClass(TabContent, [{ + key: 'getChildContext', + value: function getChildContext() { + return { + activeTabId: this.state.activeTab + }; } - } else { - var iteratorFn = getIteratorFn(children); - if (iteratorFn) { - var iterator = iteratorFn.call(children); - var step; - if (iteratorFn !== children.entries) { - var ii = 0; - while (!(step = iterator.next()).done) { - child = step.value; - nextName = nextNamePrefix + getComponentKey(child, ii++); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - if (process.env.NODE_ENV !== 'production') { - var mapsAsChildrenAddendum = ''; - if (ReactCurrentOwner.current) { - var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); - if (mapsAsChildrenOwnerName) { - mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; - } - } - process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; - didWarnAboutMaps = true; - } - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - child = entry[1]; - nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } - } - } else if (type === 'object') { - var addendum = ''; - if (process.env.NODE_ENV !== 'production') { - addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; - if (children._isReactElement) { - addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; - } - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - addendum += ' Check the render method of `' + name + '`.'; - } - } + }, { + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + if (this.state.activeTab !== nextProps.activeTab) { + this.setState({ + activeTab: nextProps.activeTab + }); } - var childrenString = String(children); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; } - } - - return subtreeCount; -} + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + Tag = _props.tag; -/** - * Traverses children that are typically specified as `props.children`, but - * might also be specified through attributes: - * - * - `traverseAllChildren(this.props.children, ...)` - * - `traverseAllChildren(this.props.leftPanelChildren, ...)` - * - * The `traverseContext` is an optional argument that is passed through the - * entire traversal. It can be used to store accumulations or anything else that - * the callback might find relevant. - * - * @param {?*} children Children tree object. - * @param {!function} callback To invoke upon traversing each child. - * @param {?*} traverseContext Context for traversal. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildren(children, callback, traverseContext) { - if (children == null) { - return 0; - } - return traverseAllChildrenImpl(children, '', callback, traverseContext); -} + var attributes = omit(this.props, Object.keys(propTypes$60)); -module.exports = traverseAllChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-content', className), cssModule); -/***/ }), -/* 125 */ -/***/ (function(module, exports, __webpack_require__) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + } + }]); + return TabContent; +}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +TabContent.propTypes = propTypes$60; +TabContent.defaultProps = defaultProps$58; +TabContent.childContextTypes = childContextTypes$1; +var propTypes$61 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; +var defaultProps$59 = { + tag: 'div' +}; -/** - * Escape and wrap key so it is safe to use as a reactid - * - * @param {string} key to be escaped. - * @return {string} the escaped key. - */ +var contextTypes$3 = { + activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -function escape(key) { - var escapeRegex = /[=:]/g; - var escaperLookup = { - '=': '=0', - ':': '=2' - }; - var escapedString = ('' + key).replace(escapeRegex, function (match) { - return escaperLookup[match]; - }); +function TabPane(props, context) { + var className = props.className, + cssModule = props.cssModule, + tabId = props.tabId, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabId', 'tag']); - return '$' + escapedString; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-pane', className, { active: tabId === context.activeTabId }), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); } +TabPane.propTypes = propTypes$61; +TabPane.defaultProps = defaultProps$59; +TabPane.contextTypes = contextTypes$3; -/** - * Unescape and unwrap key for human-readable display - * - * @param {string} key to unescape. - * @return {string} the unescaped key. - */ -function unescape(key) { - var unescapeRegex = /(=0|=2)/g; - var unescaperLookup = { - '=0': '=', - '=2': ':' - }; - var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); - - return ('' + keySubstring).replace(unescapeRegex, function (match) { - return unescaperLookup[match]; - }); -} +var propTypes$62 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var KeyEscapeUtils = { - escape: escape, - unescape: unescape +var defaultProps$60 = { + tag: 'div' }; -module.exports = KeyEscapeUtils; +var Jumbotron = function Jumbotron(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + fluid = props.fluid, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'fluid']); -/***/ }), -/* 126 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'jumbotron', fluid ? 'jumbotron-fluid' : false), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +Jumbotron.propTypes = propTypes$62; +Jumbotron.defaultProps = defaultProps$60; -var ReactElement = __webpack_require__(19); +var FirstChild = function FirstChild(_ref) { + var children = _ref.children; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children)[0] || null; +}; -/** - * Create a factory that creates HTML tag elements. - * - * @private - */ -var createDOMFactory = ReactElement.createFactory; -if (process.env.NODE_ENV !== 'production') { - var ReactElementValidator = __webpack_require__(78); - createDOMFactory = ReactElementValidator.createFactory; -} +var propTypes$63 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + closeClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number +}; -/** - * Creates a mapping from supported HTML tags to `ReactDOMComponent` classes. - * - * @public - */ -var ReactDOMFactories = { - a: createDOMFactory('a'), - abbr: createDOMFactory('abbr'), - address: createDOMFactory('address'), - area: createDOMFactory('area'), - article: createDOMFactory('article'), - aside: createDOMFactory('aside'), - audio: createDOMFactory('audio'), - b: createDOMFactory('b'), - base: createDOMFactory('base'), - bdi: createDOMFactory('bdi'), - bdo: createDOMFactory('bdo'), - big: createDOMFactory('big'), - blockquote: createDOMFactory('blockquote'), - body: createDOMFactory('body'), - br: createDOMFactory('br'), - button: createDOMFactory('button'), - canvas: createDOMFactory('canvas'), - caption: createDOMFactory('caption'), - cite: createDOMFactory('cite'), - code: createDOMFactory('code'), - col: createDOMFactory('col'), - colgroup: createDOMFactory('colgroup'), - data: createDOMFactory('data'), - datalist: createDOMFactory('datalist'), - dd: createDOMFactory('dd'), - del: createDOMFactory('del'), - details: createDOMFactory('details'), - dfn: createDOMFactory('dfn'), - dialog: createDOMFactory('dialog'), - div: createDOMFactory('div'), - dl: createDOMFactory('dl'), - dt: createDOMFactory('dt'), - em: createDOMFactory('em'), - embed: createDOMFactory('embed'), - fieldset: createDOMFactory('fieldset'), - figcaption: createDOMFactory('figcaption'), - figure: createDOMFactory('figure'), - footer: createDOMFactory('footer'), - form: createDOMFactory('form'), - h1: createDOMFactory('h1'), - h2: createDOMFactory('h2'), - h3: createDOMFactory('h3'), - h4: createDOMFactory('h4'), - h5: createDOMFactory('h5'), - h6: createDOMFactory('h6'), - head: createDOMFactory('head'), - header: createDOMFactory('header'), - hgroup: createDOMFactory('hgroup'), - hr: createDOMFactory('hr'), - html: createDOMFactory('html'), - i: createDOMFactory('i'), - iframe: createDOMFactory('iframe'), - img: createDOMFactory('img'), - input: createDOMFactory('input'), - ins: createDOMFactory('ins'), - kbd: createDOMFactory('kbd'), - keygen: createDOMFactory('keygen'), - label: createDOMFactory('label'), - legend: createDOMFactory('legend'), - li: createDOMFactory('li'), - link: createDOMFactory('link'), - main: createDOMFactory('main'), - map: createDOMFactory('map'), - mark: createDOMFactory('mark'), - menu: createDOMFactory('menu'), - menuitem: createDOMFactory('menuitem'), - meta: createDOMFactory('meta'), - meter: createDOMFactory('meter'), - nav: createDOMFactory('nav'), - noscript: createDOMFactory('noscript'), - object: createDOMFactory('object'), - ol: createDOMFactory('ol'), - optgroup: createDOMFactory('optgroup'), - option: createDOMFactory('option'), - output: createDOMFactory('output'), - p: createDOMFactory('p'), - param: createDOMFactory('param'), - picture: createDOMFactory('picture'), - pre: createDOMFactory('pre'), - progress: createDOMFactory('progress'), - q: createDOMFactory('q'), - rp: createDOMFactory('rp'), - rt: createDOMFactory('rt'), - ruby: createDOMFactory('ruby'), - s: createDOMFactory('s'), - samp: createDOMFactory('samp'), - script: createDOMFactory('script'), - section: createDOMFactory('section'), - select: createDOMFactory('select'), - small: createDOMFactory('small'), - source: createDOMFactory('source'), - span: createDOMFactory('span'), - strong: createDOMFactory('strong'), - style: createDOMFactory('style'), - sub: createDOMFactory('sub'), - summary: createDOMFactory('summary'), - sup: createDOMFactory('sup'), - table: createDOMFactory('table'), - tbody: createDOMFactory('tbody'), - td: createDOMFactory('td'), - textarea: createDOMFactory('textarea'), - tfoot: createDOMFactory('tfoot'), - th: createDOMFactory('th'), - thead: createDOMFactory('thead'), - time: createDOMFactory('time'), - title: createDOMFactory('title'), - tr: createDOMFactory('tr'), - track: createDOMFactory('track'), - u: createDOMFactory('u'), - ul: createDOMFactory('ul'), - 'var': createDOMFactory('var'), - video: createDOMFactory('video'), - wbr: createDOMFactory('wbr'), - - // SVG - circle: createDOMFactory('circle'), - clipPath: createDOMFactory('clipPath'), - defs: createDOMFactory('defs'), - ellipse: createDOMFactory('ellipse'), - g: createDOMFactory('g'), - image: createDOMFactory('image'), - line: createDOMFactory('line'), - linearGradient: createDOMFactory('linearGradient'), - mask: createDOMFactory('mask'), - path: createDOMFactory('path'), - pattern: createDOMFactory('pattern'), - polygon: createDOMFactory('polygon'), - polyline: createDOMFactory('polyline'), - radialGradient: createDOMFactory('radialGradient'), - rect: createDOMFactory('rect'), - stop: createDOMFactory('stop'), - svg: createDOMFactory('svg'), - text: createDOMFactory('text'), - tspan: createDOMFactory('tspan') +var defaultProps$61 = { + color: 'success', + isOpen: true, + tag: 'div', + transitionAppearTimeout: 150, + transitionEnterTimeout: 150, + transitionLeaveTimeout: 150 }; -module.exports = ReactDOMFactories; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var Alert = function Alert(props) { + var className = props.className, + closeClassName = props.closeClassName, + cssModule = props.cssModule, + Tag = props.tag, + color = props.color, + isOpen = props.isOpen, + toggle = props.toggle, + children = props.children, + transitionAppearTimeout = props.transitionAppearTimeout, + transitionEnterTimeout = props.transitionEnterTimeout, + transitionLeaveTimeout = props.transitionLeaveTimeout, + attributes = objectWithoutProperties(props, ['className', 'closeClassName', 'cssModule', 'tag', 'color', 'isOpen', 'toggle', 'children', 'transitionAppearTimeout', 'transitionEnterTimeout', 'transitionLeaveTimeout']); -/***/ }), -/* 127 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'alert', 'alert-' + color, { 'alert-dismissible': toggle }), cssModule); + var closeClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('close', closeClassName), cssModule); + var alert = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { className: classes, role: 'alert' }), + toggle ? __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'button', + { type: 'button', className: closeClasses, 'aria-label': 'Close', onClick: toggle }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { 'aria-hidden': 'true' }, + '\xD7' + ) + ) : null, + children + ); -var _prodInvariant = __webpack_require__(25); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["CSSTransitionGroup"], + { + component: FirstChild, + transitionName: { + appear: 'fade', + appearActive: 'show', + enter: 'fade', + enterActive: 'show', + leave: 'fade', + leaveActive: 'out' + }, + transitionAppear: transitionAppearTimeout > 0, + transitionAppearTimeout: transitionAppearTimeout, + transitionEnter: transitionEnterTimeout > 0, + transitionEnterTimeout: transitionEnterTimeout, + transitionLeave: transitionLeaveTimeout > 0, + transitionLeaveTimeout: transitionLeaveTimeout + }, + isOpen ? alert : null + ); +}; -var ReactPropTypeLocationNames = __webpack_require__(128); -var ReactPropTypesSecret = __webpack_require__(129); +Alert.propTypes = propTypes$63; +Alert.defaultProps = defaultProps$61; -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +var SHOW = 'SHOW'; +var SHOWN = 'SHOWN'; +var HIDE = 'HIDE'; +var HIDDEN = 'HIDDEN'; -var ReactComponentTreeHook; +var propTypes$64 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + onOpened: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onClosed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} +var DEFAULT_DELAYS$1 = { + show: 350, + hide: 350 +}; -var loggedTypeFailures = {}; +var defaultProps$62 = { + isOpen: false, + tag: 'div', + delay: DEFAULT_DELAYS$1, + onOpened: function onOpened() {}, + onClosed: function onClosed() {} +}; -/** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. - * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?object} element The React element that is being type-checked - * @param {?number} debugID The React component instance that is being type-checked - * @private - */ -function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; +var Collapse = function (_Component) { + inherits(Collapse, _Component); - var componentStackInfo = ''; + function Collapse(props) { + classCallCheck(this, Collapse); - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (debugID !== null) { - componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); - } else if (element !== null) { - componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); - } - } + var _this = possibleConstructorReturn(this, (Collapse.__proto__ || Object.getPrototypeOf(Collapse)).call(this, props)); - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; - } - } + _this.state = { + collapse: props.isOpen ? SHOWN : HIDDEN, + height: null + }; + _this.element = null; + return _this; } -} - -module.exports = checkReactTypeSpec; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -/***/ }), -/* 128 */ -/***/ (function(module, exports, __webpack_require__) { + createClass(Collapse, [{ + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + var _this2 = this; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var willOpen = nextProps.isOpen; + var collapse = this.state.collapse; + if (willOpen && collapse === HIDDEN) { + // will open + this.setState({ collapse: SHOW }, function () { + // the height transition will work after class "collapsing" applied + _this2.setState({ height: _this2.getHeight() }); + _this2.transitionTag = setTimeout(function () { + _this2.setState({ + collapse: SHOWN, + height: null + }); + }, _this2.getDelay('show')); + }); + } else if (!willOpen && collapse === SHOWN) { + // will hide + this.setState({ height: this.getHeight() }, function () { + _this2.setState({ + collapse: HIDE, + height: _this2.getHeight() + }, function () { + _this2.setState({ height: 0 }); + }); + }); + this.transitionTag = setTimeout(function () { + _this2.setState({ + collapse: HIDDEN, + height: null + }); + }, this.getDelay('hide')); + } + // else: do nothing. + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps, prevState) { + if (this.state.collapse === SHOWN && prevState && prevState.collapse !== SHOWN) { + this.props.onOpened(); + } -var ReactPropTypeLocationNames = {}; + if (this.state.collapse === HIDDEN && prevState && prevState.collapse !== HIDDEN) { + this.props.onClosed(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + clearTimeout(this.transitionTag); + } + }, { + key: 'getDelay', + value: function getDelay(key) { + var delay = this.props.delay; -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' - }; -} + if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { + return isNaN(delay[key]) ? DEFAULT_DELAYS$1[key] : delay[key]; + } + return delay; + } + }, { + key: 'getHeight', + value: function getHeight() { + return this.element.scrollHeight; + } + }, { + key: 'render', + value: function render() { + var _this3 = this; -module.exports = ReactPropTypeLocationNames; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var _omit = omit(this.props, ['isOpen', 'delay', 'onOpened', 'onClosed']), + navbar = _omit.navbar, + className = _omit.className, + cssModule = _omit.cssModule, + Tag = _omit.tag, + attributes = objectWithoutProperties(_omit, ['navbar', 'className', 'cssModule', 'tag']); -/***/ }), -/* 129 */ -/***/ (function(module, exports, __webpack_require__) { + var _state = this.state, + collapse = _state.collapse, + height = _state.height; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var collapseClass = void 0; + switch (collapse) { + case SHOW: + collapseClass = 'collapsing'; + break; + case SHOWN: + collapseClass = 'collapse show'; + break; + case HIDE: + collapseClass = 'collapsing'; + break; + case HIDDEN: + collapseClass = 'collapse'; + break; + default: + // HIDDEN + collapseClass = 'collapse'; + } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, collapseClass, navbar && 'navbar-collapse'), cssModule); + var style = height === null ? null : { height: height }; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { + style: _extends({}, attributes.style, style), + className: classes, + ref: function ref(c) { + _this3.element = c; + } + })); + } + }]); + return Collapse; +}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); +Collapse.propTypes = propTypes$64; +Collapse.defaultProps = defaultProps$62; -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; +var propTypes$65 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + action: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -module.exports = ReactPropTypesSecret; +var defaultProps$63 = { + tag: 'li' +}; -/***/ }), -/* 130 */ -/***/ (function(module, exports, __webpack_require__) { +var handleDisabledOnClick = function handleDisabledOnClick(e) { + e.preventDefault(); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var ListGroupItem = function ListGroupItem(props) { + var className = props.className, + Tag = props.tag, + active = props.active, + disabled = props.disabled, + action = props.action, + color = props.color, + attributes = objectWithoutProperties(props, ['className', 'tag', 'active', 'disabled', 'action', 'color']); + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, disabled ? 'disabled' : false, action ? 'list-group-item-action' : false, color ? 'list-group-item-' + color : false, 'list-group-item'); + // Prevent click event when disabled. + if (disabled) { + attributes.onClick = handleDisabledOnClick; + } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var _require = __webpack_require__(19), - isValidElement = _require.isValidElement; +ListGroupItem.propTypes = propTypes$65; +ListGroupItem.defaultProps = defaultProps$63; -var factory = __webpack_require__(79); +var propTypes$66 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -module.exports = factory(isValidElement); +var defaultProps$64 = { + tag: 'h5' +}; -/***/ }), -/* 131 */ -/***/ (function(module, exports, __webpack_require__) { +var ListGroupItemHeading = function ListGroupItemHeading(props) { + var className = props.className, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'tag']); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-heading'); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +ListGroupItemHeading.propTypes = propTypes$66; +ListGroupItemHeading.defaultProps = defaultProps$64; -if (process.env.NODE_ENV !== 'production') { - var invariant = __webpack_require__(1); - var warning = __webpack_require__(2); - var ReactPropTypesSecret = __webpack_require__(49); - var loggedTypeFailures = {}; -} +var propTypes$67 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -/** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. - * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?Function} getStack Returns the component stack. - * @private - */ -function checkPropTypes(typeSpecs, values, location, componentName, getStack) { - if (process.env.NODE_ENV !== 'production') { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - invariant(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', componentName || 'React class', location, typeSpecName); - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error); - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; +var defaultProps$65 = { + tag: 'p' +}; - var stack = getStack ? getStack() : ''; +var ListGroupItemText = function ListGroupItemText(props) { + var className = props.className, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'tag']); - warning(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : ''); - } - } + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-text'); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ListGroupItemText.propTypes = propTypes$67; +ListGroupItemText.defaultProps = defaultProps$65; + +var Component$1 = __WEBPACK_IMPORTED_MODULE_0_react___default.a.Component; + +var components = { + UncontrolledAlert: Alert, + UncontrolledButtonDropdown: ButtonDropdown, + UncontrolledDropdown: Dropdown, + UncontrolledNavDropdown: NavDropdown, + UncontrolledTooltip: Tooltip +}; + +Object.keys(components).forEach(function (key) { + var Tag = components[key]; + var defaultValue = Tag === Alert; + + var Uncontrolled = function (_Component) { + inherits(Uncontrolled, _Component); + + function Uncontrolled(props) { + classCallCheck(this, Uncontrolled); + + var _this = possibleConstructorReturn(this, (Uncontrolled.__proto__ || Object.getPrototypeOf(Uncontrolled)).call(this, props)); + + _this.state = { isOpen: defaultValue }; + + _this.toggle = _this.toggle.bind(_this); + return _this; } - } -} -module.exports = checkPropTypes; + createClass(Uncontrolled, [{ + key: 'toggle', + value: function toggle() { + this.setState({ isOpen: !this.state.isOpen }); + } + }, { + key: 'render', + value: function render() { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ isOpen: this.state.isOpen, toggle: this.toggle }, this.props)); + } + }]); + return Uncontrolled; + }(Component$1); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + Uncontrolled.displayName = key; -/***/ }), -/* 132 */ -/***/ (function(module, exports, __webpack_require__) { + components[key] = Uncontrolled; +}); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var UncontrolledAlert = components.UncontrolledAlert; +var UncontrolledButtonDropdown = components.UncontrolledButtonDropdown; +var UncontrolledDropdown = components.UncontrolledDropdown; +var UncontrolledNavDropdown = components.UncontrolledNavDropdown; +var UncontrolledTooltip = components.UncontrolledTooltip; +//# sourceMappingURL=reactstrap.es.js.map -module.exports = '15.6.1'; /***/ }), -/* 133 */ +/* 94 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(process) { +var utils = __webpack_require__(20); +var normalizeHeaderName = __webpack_require__(339); +var DEFAULT_CONTENT_TYPE = { + 'Content-Type': 'application/x-www-form-urlencoded' +}; -var _require = __webpack_require__(74), - Component = _require.Component; +function setContentTypeIfUnset(headers, value) { + if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) { + headers['Content-Type'] = value; + } +} -var _require2 = __webpack_require__(19), - isValidElement = _require2.isValidElement; +function getDefaultAdapter() { + var adapter; + if (typeof XMLHttpRequest !== 'undefined') { + // For browsers use XHR adapter + adapter = __webpack_require__(156); + } else if (typeof process !== 'undefined') { + // For node use HTTP adapter + adapter = __webpack_require__(156); + } + return adapter; +} -var ReactNoopUpdateQueue = __webpack_require__(75); -var factory = __webpack_require__(113); +var defaults = { + adapter: getDefaultAdapter(), + + transformRequest: [function transformRequest(data, headers) { + normalizeHeaderName(headers, 'Content-Type'); + if (utils.isFormData(data) || + utils.isArrayBuffer(data) || + utils.isBuffer(data) || + utils.isStream(data) || + utils.isFile(data) || + utils.isBlob(data) + ) { + return data; + } + if (utils.isArrayBufferView(data)) { + return data.buffer; + } + if (utils.isURLSearchParams(data)) { + setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8'); + return data.toString(); + } + if (utils.isObject(data)) { + setContentTypeIfUnset(headers, 'application/json;charset=utf-8'); + return JSON.stringify(data); + } + return data; + }], + + transformResponse: [function transformResponse(data) { + /*eslint no-param-reassign:0*/ + if (typeof data === 'string') { + try { + data = JSON.parse(data); + } catch (e) { /* Ignore */ } + } + return data; + }], -module.exports = factory(Component, isValidElement, ReactNoopUpdateQueue); + timeout: 0, -/***/ }), -/* 134 */ -/***/ (function(module, exports, __webpack_require__) { + xsrfCookieName: 'XSRF-TOKEN', + xsrfHeaderName: 'X-XSRF-TOKEN', -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + maxContentLength: -1, + validateStatus: function validateStatus(status) { + return status >= 200 && status < 300; + } +}; -var _prodInvariant = __webpack_require__(25); +defaults.headers = { + common: { + 'Accept': 'application/json, text/plain, */*' + } +}; -var ReactElement = __webpack_require__(19); +utils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) { + defaults.headers[method] = {}; +}); -var invariant = __webpack_require__(1); +utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE); +}); -/** - * Returns the first child in a collection of children and verifies that there - * is only one child in the collection. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.only - * - * The current implementation of this function assumes that a single child gets - * passed without a wrapper, but the purpose of this helper function is to - * abstract away the particular structure of children. - * - * @param {?object} children Child collection structure. - * @return {ReactElement} The first and only `ReactElement` contained in the - * structure. - */ -function onlyChild(children) { - !ReactElement.isValidElement(children) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React.Children.only expected to receive a single React element child.') : _prodInvariant('143') : void 0; - return children; -} +module.exports = defaults; -module.exports = onlyChild; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 135 */ +/* 95 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ -/* globals __REACT_DEVTOOLS_GLOBAL_HOOK__*/ +Object.defineProperty(exports, "__esModule", { + value: true +}); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDefaultInjection = __webpack_require__(136); -var ReactMount = __webpack_require__(104); -var ReactReconciler = __webpack_require__(26); -var ReactUpdates = __webpack_require__(15); -var ReactVersion = __webpack_require__(214); +var _react = __webpack_require__(6); -var findDOMNode = __webpack_require__(215); -var getHostComponentFromComposite = __webpack_require__(105); -var renderSubtreeIntoContainer = __webpack_require__(216); -var warning = __webpack_require__(2); +var _react2 = _interopRequireDefault(_react); -ReactDefaultInjection.inject(); +var _classnames = __webpack_require__(41); -var ReactDOM = { - findDOMNode: findDOMNode, - render: ReactMount.render, - unmountComponentAtNode: ReactMount.unmountComponentAtNode, - version: ReactVersion, +var _classnames2 = _interopRequireDefault(_classnames); - /* eslint-disable camelcase */ - unstable_batchedUpdates: ReactUpdates.batchedUpdates, - unstable_renderSubtreeIntoContainer: renderSubtreeIntoContainer - /* eslint-enable camelcase */ +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } + +// +exports.default = { + get: get, + set: set, + takeRight: takeRight, + last: last, + orderBy: orderBy, + range: range, + remove: remove, + clone: clone, + getFirstDefined: getFirstDefined, + sum: sum, + makeTemplateComponent: makeTemplateComponent, + groupBy: groupBy, + isArray: isArray, + splitProps: splitProps, + compactObject: compactObject, + isSortingDesc: isSortingDesc, + normalizeComponent: normalizeComponent, + asPx: asPx }; -// Inject the runtime into a devtools global hook regardless of browser. -// Allows for debugging when the hook is injected on the page. -if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject === 'function') { - __REACT_DEVTOOLS_GLOBAL_HOOK__.inject({ - ComponentTree: { - getClosestInstanceFromNode: ReactDOMComponentTree.getClosestInstanceFromNode, - getNodeFromInstance: function (inst) { - // inst is an internal instance (but could be a composite) - if (inst._renderedComponent) { - inst = getHostComponentFromComposite(inst); - } - if (inst) { - return ReactDOMComponentTree.getNodeFromInstance(inst); - } else { - return null; - } - } - }, - Mount: ReactMount, - Reconciler: ReactReconciler - }); + +function get(obj, path, def) { + if (!path) { + return obj; + } + var pathObj = makePathArray(path); + var val = void 0; + try { + val = pathObj.reduce(function (current, pathPart) { + return current[pathPart]; + }, obj); + } catch (e) {} + return typeof val !== 'undefined' ? val : def; } -if (process.env.NODE_ENV !== 'production') { - var ExecutionEnvironment = __webpack_require__(8); - if (ExecutionEnvironment.canUseDOM && window.top === window.self) { - // First check if devtools is not installed - if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined') { - // If we're in Chrome or Firefox, provide a download link if not installed. - if (navigator.userAgent.indexOf('Chrome') > -1 && navigator.userAgent.indexOf('Edge') === -1 || navigator.userAgent.indexOf('Firefox') > -1) { - // Firefox does not have the issue with devtools loaded over file:// - var showFileUrlMessage = window.location.protocol.indexOf('http') === -1 && navigator.userAgent.indexOf('Firefox') === -1; - console.debug('Download the React DevTools ' + (showFileUrlMessage ? 'and use an HTTP server (instead of a file: URL) ' : '') + 'for a better development experience: ' + 'https://fb.me/react-devtools'); - } +function set() { + var obj = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + var path = arguments[1]; + var value = arguments[2]; + + var keys = makePathArray(path); + var keyPart = void 0; + var cursor = obj; + while ((keyPart = keys.shift()) && keys.length) { + if (!cursor[keyPart]) { + cursor[keyPart] = {}; } + cursor = cursor[keyPart]; + } + cursor[keyPart] = value; + return obj; +} - var testFunc = function testFn() {}; - process.env.NODE_ENV !== 'production' ? warning((testFunc.name || testFunc.toString()).indexOf('testFn') !== -1, "It looks like you're using a minified copy of the development build " + 'of React. When deploying React apps to production, make sure to use ' + 'the production build which skips development warnings and is faster. ' + 'See https://fb.me/react-minification for more details.') : void 0; +function takeRight(arr, n) { + var start = n > arr.length ? 0 : arr.length - n; + return arr.slice(start); +} - // If we're in IE8, check to see if we are in compatibility mode and provide - // information on preventing compatibility mode - var ieCompatibilityMode = document.documentMode && document.documentMode < 8; +function last(arr) { + return arr[arr.length - 1]; +} - process.env.NODE_ENV !== 'production' ? warning(!ieCompatibilityMode, 'Internet Explorer is running in compatibility mode; please add the ' + 'following tag to your HTML to prevent this from happening: ' + '<meta http-equiv="X-UA-Compatible" content="IE=edge" />') : void 0; +function range(n) { + var arr = []; + for (var i = 0; i < n; i++) { + arr.push(n); + } + return arr; +} - var expectedFeatures = [ - // shims - Array.isArray, Array.prototype.every, Array.prototype.forEach, Array.prototype.indexOf, Array.prototype.map, Date.now, Function.prototype.bind, Object.keys, String.prototype.trim]; +function orderBy(arr, funcs, dirs, indexKey) { + return arr.sort(function (rowA, rowB) { + for (var i = 0; i < funcs.length; i++) { + var comp = funcs[i]; + var desc = dirs[i] === false || dirs[i] === 'desc'; + var sortInt = comp(rowA, rowB); + if (sortInt) { + return desc ? -sortInt : sortInt; + } + } + // Use the row index for tie breakers + return dirs[0] ? rowA[indexKey] - rowB[indexKey] : rowB[indexKey] - rowA[indexKey]; + }); +} - for (var i = 0; i < expectedFeatures.length; i++) { - if (!expectedFeatures[i]) { - process.env.NODE_ENV !== 'production' ? warning(false, 'One or more ES5 shims expected by React are not available: ' + 'https://fb.me/react-warning-polyfills') : void 0; - break; +function remove(a, b) { + return a.filter(function (o, i) { + var r = b(o); + if (r) { + a.splice(i, 1); + return true; + } + return false; + }); +} + +function clone(a) { + try { + return JSON.parse(JSON.stringify(a, function (key, value) { + if (typeof value === 'function') { + return value.toString(); } + return value; + })); + } catch (e) { + return a; + } +} + +function getFirstDefined() { + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + for (var i = 0; i < args.length; i++) { + if (typeof args[i] !== 'undefined') { + return args[i]; } } } -if (process.env.NODE_ENV !== 'production') { - var ReactInstrumentation = __webpack_require__(13); - var ReactDOMUnknownPropertyHook = __webpack_require__(217); - var ReactDOMNullInputValuePropHook = __webpack_require__(218); - var ReactDOMInvalidARIAHook = __webpack_require__(219); +function sum(arr) { + return arr.reduce(function (a, b) { + return a + b; + }, 0); +} - ReactInstrumentation.debugTool.addHook(ReactDOMUnknownPropertyHook); - ReactInstrumentation.debugTool.addHook(ReactDOMNullInputValuePropHook); - ReactInstrumentation.debugTool.addHook(ReactDOMInvalidARIAHook); +function makeTemplateComponent(compClass, displayName) { + if (!displayName) { + throw new Error('No displayName found for template component:', compClass); + } + var cmp = function cmp(_ref) { + var children = _ref.children, + className = _ref.className, + rest = _objectWithoutProperties(_ref, ['children', 'className']); + + return _react2.default.createElement( + 'div', + _extends({ className: (0, _classnames2.default)(compClass, className) }, rest), + children + ); + }; + cmp.displayName = displayName; + return cmp; } -module.exports = ReactDOM; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function groupBy(xs, key) { + return xs.reduce(function (rv, x, i) { + var resKey = typeof key === 'function' ? key(x, i) : x[key]; + rv[resKey] = isArray(rv[resKey]) ? rv[resKey] : []; + rv[resKey].push(x); + return rv; + }, {}); +} -/***/ }), -/* 136 */ -/***/ (function(module, exports, __webpack_require__) { +function asPx(value) { + value = Number(value); + return Number.isNaN(value) ? null : value + 'px'; +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function isArray(a) { + return Array.isArray(a); +} +// ######################################################################## +// Non-exported Helpers +// ######################################################################## +function makePathArray(obj) { + return flattenDeep(obj).join('.').replace(/\[/g, '.').replace(/\]/g, '').split('.'); +} -var ARIADOMPropertyConfig = __webpack_require__(137); -var BeforeInputEventPlugin = __webpack_require__(138); -var ChangeEventPlugin = __webpack_require__(142); -var DefaultEventPluginOrder = __webpack_require__(150); -var EnterLeaveEventPlugin = __webpack_require__(151); -var HTMLDOMPropertyConfig = __webpack_require__(152); -var ReactComponentBrowserEnvironment = __webpack_require__(153); -var ReactDOMComponent = __webpack_require__(159); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMEmptyComponent = __webpack_require__(185); -var ReactDOMTreeTraversal = __webpack_require__(186); -var ReactDOMTextComponent = __webpack_require__(187); -var ReactDefaultBatchingStrategy = __webpack_require__(188); -var ReactEventListener = __webpack_require__(189); -var ReactInjection = __webpack_require__(191); -var ReactReconcileTransaction = __webpack_require__(192); -var SVGDOMPropertyConfig = __webpack_require__(198); -var SelectEventPlugin = __webpack_require__(199); -var SimpleEventPlugin = __webpack_require__(200); +function flattenDeep(arr) { + var newArr = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : []; -var alreadyInjected = false; + if (!isArray(arr)) { + newArr.push(arr); + } else { + for (var i = 0; i < arr.length; i++) { + flattenDeep(arr[i], newArr); + } + } + return newArr; +} -function inject() { - if (alreadyInjected) { - // TODO: This is currently true because these injections are shared between - // the client and the server package. They should be built independently - // and not share any injection state. Then this problem will be solved. - return; +function splitProps(_ref2) { + var className = _ref2.className, + style = _ref2.style, + rest = _objectWithoutProperties(_ref2, ['className', 'style']); + + return { + className: className, + style: style, + rest: rest || {} + }; +} + +function compactObject(obj) { + var newObj = {}; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key] !== undefined && typeof obj[key] !== 'undefined') { + newObj[key] = obj[key]; + } } - alreadyInjected = true; + return newObj; +} - ReactInjection.EventEmitter.injectReactEventListener(ReactEventListener); +function isSortingDesc(d) { + return !!(d.sort === 'desc' || d.desc === true || d.asc === false); +} - /** - * Inject modules for resolving DOM hierarchy and plugin ordering. - */ - ReactInjection.EventPluginHub.injectEventPluginOrder(DefaultEventPluginOrder); - ReactInjection.EventPluginUtils.injectComponentTree(ReactDOMComponentTree); - ReactInjection.EventPluginUtils.injectTreeTraversal(ReactDOMTreeTraversal); +function normalizeComponent(Comp) { + var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; + var fallback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Comp; - /** - * Some important event plugins included by default (without having to require - * them). - */ - ReactInjection.EventPluginHub.injectEventPluginsByName({ - SimpleEventPlugin: SimpleEventPlugin, - EnterLeaveEventPlugin: EnterLeaveEventPlugin, - ChangeEventPlugin: ChangeEventPlugin, - SelectEventPlugin: SelectEventPlugin, - BeforeInputEventPlugin: BeforeInputEventPlugin - }); + return typeof Comp === 'function' ? Object.getPrototypeOf(Comp).isReactComponent ? _react2.default.createElement(Comp, params) : Comp(params) : fallback; +} +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy91dGlscy5qcyJdLCJuYW1lcyI6WyJnZXQiLCJzZXQiLCJ0YWtlUmlnaHQiLCJsYXN0Iiwib3JkZXJCeSIsInJhbmdlIiwicmVtb3ZlIiwiY2xvbmUiLCJnZXRGaXJzdERlZmluZWQiLCJzdW0iLCJtYWtlVGVtcGxhdGVDb21wb25lbnQiLCJncm91cEJ5IiwiaXNBcnJheSIsInNwbGl0UHJvcHMiLCJjb21wYWN0T2JqZWN0IiwiaXNTb3J0aW5nRGVzYyIsIm5vcm1hbGl6ZUNvbXBvbmVudCIsImFzUHgiLCJvYmoiLCJwYXRoIiwiZGVmIiwicGF0aE9iaiIsIm1ha2VQYXRoQXJyYXkiLCJ2YWwiLCJyZWR1Y2UiLCJjdXJyZW50IiwicGF0aFBhcnQiLCJlIiwidmFsdWUiLCJrZXlzIiwia2V5UGFydCIsImN1cnNvciIsInNoaWZ0IiwibGVuZ3RoIiwiYXJyIiwibiIsInN0YXJ0Iiwic2xpY2UiLCJpIiwicHVzaCIsImZ1bmNzIiwiZGlycyIsImluZGV4S2V5Iiwic29ydCIsInJvd0EiLCJyb3dCIiwiY29tcCIsImRlc2MiLCJzb3J0SW50IiwiYSIsImIiLCJmaWx0ZXIiLCJvIiwiciIsInNwbGljZSIsIkpTT04iLCJwYXJzZSIsInN0cmluZ2lmeSIsImtleSIsInRvU3RyaW5nIiwiYXJncyIsImNvbXBDbGFzcyIsImRpc3BsYXlOYW1lIiwiRXJyb3IiLCJjbXAiLCJjaGlsZHJlbiIsImNsYXNzTmFtZSIsInJlc3QiLCJ4cyIsInJ2IiwieCIsInJlc0tleSIsIk51bWJlciIsImlzTmFOIiwiQXJyYXkiLCJmbGF0dGVuRGVlcCIsImpvaW4iLCJyZXBsYWNlIiwic3BsaXQiLCJuZXdBcnIiLCJzdHlsZSIsIm5ld09iaiIsImhhc093blByb3BlcnR5IiwidW5kZWZpbmVkIiwiZCIsImFzYyIsIkNvbXAiLCJwYXJhbXMiLCJmYWxsYmFjayIsIk9iamVjdCIsImdldFByb3RvdHlwZU9mIiwiaXNSZWFjdENvbXBvbmVudCJdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7Ozs7OztBQUNBO2tCQUNlO0FBQ2JBLFVBRGE7QUFFYkMsVUFGYTtBQUdiQyxzQkFIYTtBQUliQyxZQUphO0FBS2JDLGtCQUxhO0FBTWJDLGNBTmE7QUFPYkMsZ0JBUGE7QUFRYkMsY0FSYTtBQVNiQyxrQ0FUYTtBQVViQyxVQVZhO0FBV2JDLDhDQVhhO0FBWWJDLGtCQVphO0FBYWJDLGtCQWJhO0FBY2JDLHdCQWRhO0FBZWJDLDhCQWZhO0FBZ0JiQyw4QkFoQmE7QUFpQmJDLHdDQWpCYTtBQWtCYkM7QUFsQmEsQzs7O0FBcUJmLFNBQVNqQixHQUFULENBQWNrQixHQUFkLEVBQW1CQyxJQUFuQixFQUF5QkMsR0FBekIsRUFBOEI7QUFDNUIsTUFBSSxDQUFDRCxJQUFMLEVBQVc7QUFDVCxXQUFPRCxHQUFQO0FBQ0Q7QUFDRCxNQUFNRyxVQUFVQyxjQUFjSCxJQUFkLENBQWhCO0FBQ0EsTUFBSUksWUFBSjtBQUNBLE1BQUk7QUFDRkEsVUFBTUYsUUFBUUcsTUFBUixDQUFlLFVBQUNDLE9BQUQsRUFBVUMsUUFBVjtBQUFBLGFBQXVCRCxRQUFRQyxRQUFSLENBQXZCO0FBQUEsS0FBZixFQUF5RFIsR0FBekQsQ0FBTjtBQUNELEdBRkQsQ0FFRSxPQUFPUyxDQUFQLEVBQVUsQ0FBRTtBQUNkLFNBQU8sT0FBT0osR0FBUCxLQUFlLFdBQWYsR0FBNkJBLEdBQTdCLEdBQW1DSCxHQUExQztBQUNEOztBQUVELFNBQVNuQixHQUFULEdBQXFDO0FBQUEsTUFBdkJpQixHQUF1Qix1RUFBakIsRUFBaUI7QUFBQSxNQUFiQyxJQUFhO0FBQUEsTUFBUFMsS0FBTzs7QUFDbkMsTUFBTUMsT0FBT1AsY0FBY0gsSUFBZCxDQUFiO0FBQ0EsTUFBSVcsZ0JBQUo7QUFDQSxNQUFJQyxTQUFTYixHQUFiO0FBQ0EsU0FBTyxDQUFDWSxVQUFVRCxLQUFLRyxLQUFMLEVBQVgsS0FBNEJILEtBQUtJLE1BQXhDLEVBQWdEO0FBQzlDLFFBQUksQ0FBQ0YsT0FBT0QsT0FBUCxDQUFMLEVBQXNCO0FBQ3BCQyxhQUFPRCxPQUFQLElBQWtCLEVBQWxCO0FBQ0Q7QUFDREMsYUFBU0EsT0FBT0QsT0FBUCxDQUFUO0FBQ0Q7QUFDREMsU0FBT0QsT0FBUCxJQUFrQkYsS0FBbEI7QUFDQSxTQUFPVixHQUFQO0FBQ0Q7O0FBRUQsU0FBU2hCLFNBQVQsQ0FBb0JnQyxHQUFwQixFQUF5QkMsQ0FBekIsRUFBNEI7QUFDMUIsTUFBTUMsUUFBUUQsSUFBSUQsSUFBSUQsTUFBUixHQUFpQixDQUFqQixHQUFxQkMsSUFBSUQsTUFBSixHQUFhRSxDQUFoRDtBQUNBLFNBQU9ELElBQUlHLEtBQUosQ0FBVUQsS0FBVixDQUFQO0FBQ0Q7O0FBRUQsU0FBU2pDLElBQVQsQ0FBZStCLEdBQWYsRUFBb0I7QUFDbEIsU0FBT0EsSUFBSUEsSUFBSUQsTUFBSixHQUFhLENBQWpCLENBQVA7QUFDRDs7QUFFRCxTQUFTNUIsS0FBVCxDQUFnQjhCLENBQWhCLEVBQW1CO0FBQ2pCLE1BQU1ELE1BQU0sRUFBWjtBQUNBLE9BQUssSUFBSUksSUFBSSxDQUFiLEVBQWdCQSxJQUFJSCxDQUFwQixFQUF1QkcsR0FBdkIsRUFBNEI7QUFDMUJKLFFBQUlLLElBQUosQ0FBU0osQ0FBVDtBQUNEO0FBQ0QsU0FBT0QsR0FBUDtBQUNEOztBQUVELFNBQVM5QixPQUFULENBQWtCOEIsR0FBbEIsRUFBdUJNLEtBQXZCLEVBQThCQyxJQUE5QixFQUFvQ0MsUUFBcEMsRUFBOEM7QUFDNUMsU0FBT1IsSUFBSVMsSUFBSixDQUFTLFVBQUNDLElBQUQsRUFBT0MsSUFBUCxFQUFnQjtBQUM5QixTQUFLLElBQUlQLElBQUksQ0FBYixFQUFnQkEsSUFBSUUsTUFBTVAsTUFBMUIsRUFBa0NLLEdBQWxDLEVBQXVDO0FBQ3JDLFVBQU1RLE9BQU9OLE1BQU1GLENBQU4sQ0FBYjtBQUNBLFVBQU1TLE9BQU9OLEtBQUtILENBQUwsTUFBWSxLQUFaLElBQXFCRyxLQUFLSCxDQUFMLE1BQVksTUFBOUM7QUFDQSxVQUFNVSxVQUFVRixLQUFLRixJQUFMLEVBQVdDLElBQVgsQ0FBaEI7QUFDQSxVQUFJRyxPQUFKLEVBQWE7QUFDWCxlQUFPRCxPQUFPLENBQUNDLE9BQVIsR0FBa0JBLE9BQXpCO0FBQ0Q7QUFDRjtBQUNEO0FBQ0EsV0FBT1AsS0FBSyxDQUFMLElBQ0hHLEtBQUtGLFFBQUwsSUFBaUJHLEtBQUtILFFBQUwsQ0FEZCxHQUVIRyxLQUFLSCxRQUFMLElBQWlCRSxLQUFLRixRQUFMLENBRnJCO0FBR0QsR0FiTSxDQUFQO0FBY0Q7O0FBRUQsU0FBU3BDLE1BQVQsQ0FBaUIyQyxDQUFqQixFQUFvQkMsQ0FBcEIsRUFBdUI7QUFDckIsU0FBT0QsRUFBRUUsTUFBRixDQUFTLFVBQVVDLENBQVYsRUFBYWQsQ0FBYixFQUFnQjtBQUM5QixRQUFJZSxJQUFJSCxFQUFFRSxDQUFGLENBQVI7QUFDQSxRQUFJQyxDQUFKLEVBQU87QUFDTEosUUFBRUssTUFBRixDQUFTaEIsQ0FBVCxFQUFZLENBQVo7QUFDQSxhQUFPLElBQVA7QUFDRDtBQUNELFdBQU8sS0FBUDtBQUNELEdBUE0sQ0FBUDtBQVFEOztBQUVELFNBQVMvQixLQUFULENBQWdCMEMsQ0FBaEIsRUFBbUI7QUFDakIsTUFBSTtBQUNGLFdBQU9NLEtBQUtDLEtBQUwsQ0FDTEQsS0FBS0UsU0FBTCxDQUFlUixDQUFmLEVBQWtCLFVBQUNTLEdBQUQsRUFBTTlCLEtBQU4sRUFBZ0I7QUFDaEMsVUFBSSxPQUFPQSxLQUFQLEtBQWlCLFVBQXJCLEVBQWlDO0FBQy9CLGVBQU9BLE1BQU0rQixRQUFOLEVBQVA7QUFDRDtBQUNELGFBQU8vQixLQUFQO0FBQ0QsS0FMRCxDQURLLENBQVA7QUFRRCxHQVRELENBU0UsT0FBT0QsQ0FBUCxFQUFVO0FBQ1YsV0FBT3NCLENBQVA7QUFDRDtBQUNGOztBQUVELFNBQVN6QyxlQUFULEdBQW1DO0FBQUEsb0NBQU5vRCxJQUFNO0FBQU5BLFFBQU07QUFBQTs7QUFDakMsT0FBSyxJQUFJdEIsSUFBSSxDQUFiLEVBQWdCQSxJQUFJc0IsS0FBSzNCLE1BQXpCLEVBQWlDSyxHQUFqQyxFQUFzQztBQUNwQyxRQUFJLE9BQU9zQixLQUFLdEIsQ0FBTCxDQUFQLEtBQW1CLFdBQXZCLEVBQW9DO0FBQ2xDLGFBQU9zQixLQUFLdEIsQ0FBTCxDQUFQO0FBQ0Q7QUFDRjtBQUNGOztBQUVELFNBQVM3QixHQUFULENBQWN5QixHQUFkLEVBQW1CO0FBQ2pCLFNBQU9BLElBQUlWLE1BQUosQ0FBVyxVQUFDeUIsQ0FBRCxFQUFJQyxDQUFKLEVBQVU7QUFDMUIsV0FBT0QsSUFBSUMsQ0FBWDtBQUNELEdBRk0sRUFFSixDQUZJLENBQVA7QUFHRDs7QUFFRCxTQUFTeEMscUJBQVQsQ0FBZ0NtRCxTQUFoQyxFQUEyQ0MsV0FBM0MsRUFBd0Q7QUFDdEQsTUFBSSxDQUFDQSxXQUFMLEVBQWtCO0FBQ2hCLFVBQU0sSUFBSUMsS0FBSixDQUFVLDhDQUFWLEVBQTBERixTQUExRCxDQUFOO0FBQ0Q7QUFDRCxNQUFNRyxNQUFNLFNBQU5BLEdBQU07QUFBQSxRQUFHQyxRQUFILFFBQUdBLFFBQUg7QUFBQSxRQUFhQyxTQUFiLFFBQWFBLFNBQWI7QUFBQSxRQUEyQkMsSUFBM0I7O0FBQUEsV0FDVjtBQUFBO0FBQUEsaUJBQUssV0FBVywwQkFBV04sU0FBWCxFQUFzQkssU0FBdEIsQ0FBaEIsSUFBc0RDLElBQXREO0FBQ0dGO0FBREgsS0FEVTtBQUFBLEdBQVo7QUFJQUQsTUFBSUYsV0FBSixHQUFrQkEsV0FBbEI7QUFDQSxTQUFPRSxHQUFQO0FBQ0Q7O0FBRUQsU0FBU3JELE9BQVQsQ0FBa0J5RCxFQUFsQixFQUFzQlYsR0FBdEIsRUFBMkI7QUFDekIsU0FBT1UsR0FBRzVDLE1BQUgsQ0FBVSxVQUFDNkMsRUFBRCxFQUFLQyxDQUFMLEVBQVFoQyxDQUFSLEVBQWM7QUFDN0IsUUFBTWlDLFNBQVMsT0FBT2IsR0FBUCxLQUFlLFVBQWYsR0FBNEJBLElBQUlZLENBQUosRUFBT2hDLENBQVAsQ0FBNUIsR0FBd0NnQyxFQUFFWixHQUFGLENBQXZEO0FBQ0FXLE9BQUdFLE1BQUgsSUFBYTNELFFBQVF5RCxHQUFHRSxNQUFILENBQVIsSUFBc0JGLEdBQUdFLE1BQUgsQ0FBdEIsR0FBbUMsRUFBaEQ7QUFDQUYsT0FBR0UsTUFBSCxFQUFXaEMsSUFBWCxDQUFnQitCLENBQWhCO0FBQ0EsV0FBT0QsRUFBUDtBQUNELEdBTE0sRUFLSixFQUxJLENBQVA7QUFNRDs7QUFFRCxTQUFTcEQsSUFBVCxDQUFlVyxLQUFmLEVBQXNCO0FBQ3BCQSxVQUFRNEMsT0FBTzVDLEtBQVAsQ0FBUjtBQUNBLFNBQU80QyxPQUFPQyxLQUFQLENBQWE3QyxLQUFiLElBQXNCLElBQXRCLEdBQTZCQSxRQUFRLElBQTVDO0FBQ0Q7O0FBRUQsU0FBU2hCLE9BQVQsQ0FBa0JxQyxDQUFsQixFQUFxQjtBQUNuQixTQUFPeUIsTUFBTTlELE9BQU4sQ0FBY3FDLENBQWQsQ0FBUDtBQUNEOztBQUVEO0FBQ0E7QUFDQTs7QUFFQSxTQUFTM0IsYUFBVCxDQUF3QkosR0FBeEIsRUFBNkI7QUFDM0IsU0FBT3lELFlBQVl6RCxHQUFaLEVBQ0owRCxJQURJLENBQ0MsR0FERCxFQUVKQyxPQUZJLENBRUksS0FGSixFQUVXLEdBRlgsRUFHSkEsT0FISSxDQUdJLEtBSEosRUFHVyxFQUhYLEVBSUpDLEtBSkksQ0FJRSxHQUpGLENBQVA7QUFLRDs7QUFFRCxTQUFTSCxXQUFULENBQXNCekMsR0FBdEIsRUFBd0M7QUFBQSxNQUFiNkMsTUFBYSx1RUFBSixFQUFJOztBQUN0QyxNQUFJLENBQUNuRSxRQUFRc0IsR0FBUixDQUFMLEVBQW1CO0FBQ2pCNkMsV0FBT3hDLElBQVAsQ0FBWUwsR0FBWjtBQUNELEdBRkQsTUFFTztBQUNMLFNBQUssSUFBSUksSUFBSSxDQUFiLEVBQWdCQSxJQUFJSixJQUFJRCxNQUF4QixFQUFnQ0ssR0FBaEMsRUFBcUM7QUFDbkNxQyxrQkFBWXpDLElBQUlJLENBQUosQ0FBWixFQUFvQnlDLE1BQXBCO0FBQ0Q7QUFDRjtBQUNELFNBQU9BLE1BQVA7QUFDRDs7QUFFRCxTQUFTbEUsVUFBVCxRQUFvRDtBQUFBLE1BQTdCcUQsU0FBNkIsU0FBN0JBLFNBQTZCO0FBQUEsTUFBbEJjLEtBQWtCLFNBQWxCQSxLQUFrQjtBQUFBLE1BQVJiLElBQVE7O0FBQ2xELFNBQU87QUFDTEQsd0JBREs7QUFFTGMsZ0JBRks7QUFHTGIsVUFBTUEsUUFBUTtBQUhULEdBQVA7QUFLRDs7QUFFRCxTQUFTckQsYUFBVCxDQUF3QkksR0FBeEIsRUFBNkI7QUFDM0IsTUFBTStELFNBQVMsRUFBZjtBQUNBLE9BQUssSUFBSXZCLEdBQVQsSUFBZ0J4QyxHQUFoQixFQUFxQjtBQUNuQixRQUNFQSxJQUFJZ0UsY0FBSixDQUFtQnhCLEdBQW5CLEtBQ0F4QyxJQUFJd0MsR0FBSixNQUFheUIsU0FEYixJQUVBLE9BQU9qRSxJQUFJd0MsR0FBSixDQUFQLEtBQW9CLFdBSHRCLEVBSUU7QUFDQXVCLGFBQU92QixHQUFQLElBQWN4QyxJQUFJd0MsR0FBSixDQUFkO0FBQ0Q7QUFDRjtBQUNELFNBQU91QixNQUFQO0FBQ0Q7O0FBRUQsU0FBU2xFLGFBQVQsQ0FBd0JxRSxDQUF4QixFQUEyQjtBQUN6QixTQUFPLENBQUMsRUFBRUEsRUFBRXpDLElBQUYsS0FBVyxNQUFYLElBQXFCeUMsRUFBRXJDLElBQUYsS0FBVyxJQUFoQyxJQUF3Q3FDLEVBQUVDLEdBQUYsS0FBVSxLQUFwRCxDQUFSO0FBQ0Q7O0FBRUQsU0FBU3JFLGtCQUFULENBQTZCc0UsSUFBN0IsRUFBaUU7QUFBQSxNQUE5QkMsTUFBOEIsdUVBQXJCLEVBQXFCO0FBQUEsTUFBakJDLFFBQWlCLHVFQUFORixJQUFNOztBQUMvRCxTQUFPLE9BQU9BLElBQVAsS0FBZ0IsVUFBaEIsR0FDSEcsT0FBT0MsY0FBUCxDQUFzQkosSUFBdEIsRUFBNEJLLGdCQUE1QixHQUNFLDhCQUFDLElBQUQsRUFBVUosTUFBVixDQURGLEdBRUVELEtBQUtDLE1BQUwsQ0FIQyxHQUlIQyxRQUpKO0FBS0QiLCJmaWxlIjoidXRpbHMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgUmVhY3QgZnJvbSAncmVhY3QnXG5pbXBvcnQgY2xhc3NuYW1lcyBmcm9tICdjbGFzc25hbWVzJ1xuLy9cbmV4cG9ydCBkZWZhdWx0IHtcbiAgZ2V0LFxuICBzZXQsXG4gIHRha2VSaWdodCxcbiAgbGFzdCxcbiAgb3JkZXJCeSxcbiAgcmFuZ2UsXG4gIHJlbW92ZSxcbiAgY2xvbmUsXG4gIGdldEZpcnN0RGVmaW5lZCxcbiAgc3VtLFxuICBtYWtlVGVtcGxhdGVDb21wb25lbnQsXG4gIGdyb3VwQnksXG4gIGlzQXJyYXksXG4gIHNwbGl0UHJvcHMsXG4gIGNvbXBhY3RPYmplY3QsXG4gIGlzU29ydGluZ0Rlc2MsXG4gIG5vcm1hbGl6ZUNvbXBvbmVudCxcbiAgYXNQeCxcbn1cblxuZnVuY3Rpb24gZ2V0IChvYmosIHBhdGgsIGRlZikge1xuICBpZiAoIXBhdGgpIHtcbiAgICByZXR1cm4gb2JqXG4gIH1cbiAgY29uc3QgcGF0aE9iaiA9IG1ha2VQYXRoQXJyYXkocGF0aClcbiAgbGV0IHZhbFxuICB0cnkge1xuICAgIHZhbCA9IHBhdGhPYmoucmVkdWNlKChjdXJyZW50LCBwYXRoUGFydCkgPT4gY3VycmVudFtwYXRoUGFydF0sIG9iailcbiAgfSBjYXRjaCAoZSkge31cbiAgcmV0dXJuIHR5cGVvZiB2YWwgIT09ICd1bmRlZmluZWQnID8gdmFsIDogZGVmXG59XG5cbmZ1bmN0aW9uIHNldCAob2JqID0ge30sIHBhdGgsIHZhbHVlKSB7XG4gIGNvbnN0IGtleXMgPSBtYWtlUGF0aEFycmF5KHBhdGgpXG4gIGxldCBrZXlQYXJ0XG4gIGxldCBjdXJzb3IgPSBvYmpcbiAgd2hpbGUgKChrZXlQYXJ0ID0ga2V5cy5zaGlmdCgpKSAmJiBrZXlzLmxlbmd0aCkge1xuICAgIGlmICghY3Vyc29yW2tleVBhcnRdKSB7XG4gICAgICBjdXJzb3Jba2V5UGFydF0gPSB7fVxuICAgIH1cbiAgICBjdXJzb3IgPSBjdXJzb3Jba2V5UGFydF1cbiAgfVxuICBjdXJzb3Jba2V5UGFydF0gPSB2YWx1ZVxuICByZXR1cm4gb2JqXG59XG5cbmZ1bmN0aW9uIHRha2VSaWdodCAoYXJyLCBuKSB7XG4gIGNvbnN0IHN0YXJ0ID0gbiA+IGFyci5sZW5ndGggPyAwIDogYXJyLmxlbmd0aCAtIG5cbiAgcmV0dXJuIGFyci5zbGljZShzdGFydClcbn1cblxuZnVuY3Rpb24gbGFzdCAoYXJyKSB7XG4gIHJldHVybiBhcnJbYXJyLmxlbmd0aCAtIDFdXG59XG5cbmZ1bmN0aW9uIHJhbmdlIChuKSB7XG4gIGNvbnN0IGFyciA9IFtdXG4gIGZvciAobGV0IGkgPSAwOyBpIDwgbjsgaSsrKSB7XG4gICAgYXJyLnB1c2gobilcbiAgfVxuICByZXR1cm4gYXJyXG59XG5cbmZ1bmN0aW9uIG9yZGVyQnkgKGFyciwgZnVuY3MsIGRpcnMsIGluZGV4S2V5KSB7XG4gIHJldHVybiBhcnIuc29ydCgocm93QSwgcm93QikgPT4ge1xuICAgIGZvciAobGV0IGkgPSAwOyBpIDwgZnVuY3MubGVuZ3RoOyBpKyspIHtcbiAgICAgIGNvbnN0IGNvbXAgPSBmdW5jc1tpXVxuICAgICAgY29uc3QgZGVzYyA9IGRpcnNbaV0gPT09IGZhbHNlIHx8IGRpcnNbaV0gPT09ICdkZXNjJ1xuICAgICAgY29uc3Qgc29ydEludCA9IGNvbXAocm93QSwgcm93QilcbiAgICAgIGlmIChzb3J0SW50KSB7XG4gICAgICAgIHJldHVybiBkZXNjID8gLXNvcnRJbnQgOiBzb3J0SW50XG4gICAgICB9XG4gICAgfVxuICAgIC8vIFVzZSB0aGUgcm93IGluZGV4IGZvciB0aWUgYnJlYWtlcnNcbiAgICByZXR1cm4gZGlyc1swXVxuICAgICAgPyByb3dBW2luZGV4S2V5XSAtIHJvd0JbaW5kZXhLZXldXG4gICAgICA6IHJvd0JbaW5kZXhLZXldIC0gcm93QVtpbmRleEtleV1cbiAgfSlcbn1cblxuZnVuY3Rpb24gcmVtb3ZlIChhLCBiKSB7XG4gIHJldHVybiBhLmZpbHRlcihmdW5jdGlvbiAobywgaSkge1xuICAgIHZhciByID0gYihvKVxuICAgIGlmIChyKSB7XG4gICAgICBhLnNwbGljZShpLCAxKVxuICAgICAgcmV0dXJuIHRydWVcbiAgICB9XG4gICAgcmV0dXJuIGZhbHNlXG4gIH0pXG59XG5cbmZ1bmN0aW9uIGNsb25lIChhKSB7XG4gIHRyeSB7XG4gICAgcmV0dXJuIEpTT04ucGFyc2UoXG4gICAgICBKU09OLnN0cmluZ2lmeShhLCAoa2V5LCB2YWx1ZSkgPT4ge1xuICAgICAgICBpZiAodHlwZW9mIHZhbHVlID09PSAnZnVuY3Rpb24nKSB7XG4gICAgICAgICAgcmV0dXJuIHZhbHVlLnRvU3RyaW5nKClcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gdmFsdWVcbiAgICAgIH0pXG4gICAgKVxuICB9IGNhdGNoIChlKSB7XG4gICAgcmV0dXJuIGFcbiAgfVxufVxuXG5mdW5jdGlvbiBnZXRGaXJzdERlZmluZWQgKC4uLmFyZ3MpIHtcbiAgZm9yICh2YXIgaSA9IDA7IGkgPCBhcmdzLmxlbmd0aDsgaSsrKSB7XG4gICAgaWYgKHR5cGVvZiBhcmdzW2ldICE9PSAndW5kZWZpbmVkJykge1xuICAgICAgcmV0dXJuIGFyZ3NbaV1cbiAgICB9XG4gIH1cbn1cblxuZnVuY3Rpb24gc3VtIChhcnIpIHtcbiAgcmV0dXJuIGFyci5yZWR1Y2UoKGEsIGIpID0+IHtcbiAgICByZXR1cm4gYSArIGJcbiAgfSwgMClcbn1cblxuZnVuY3Rpb24gbWFrZVRlbXBsYXRlQ29tcG9uZW50IChjb21wQ2xhc3MsIGRpc3BsYXlOYW1lKSB7XG4gIGlmICghZGlzcGxheU5hbWUpIHtcbiAgICB0aHJvdyBuZXcgRXJyb3IoJ05vIGRpc3BsYXlOYW1lIGZvdW5kIGZvciB0ZW1wbGF0ZSBjb21wb25lbnQ6JywgY29tcENsYXNzKVxuICB9XG4gIGNvbnN0IGNtcCA9ICh7IGNoaWxkcmVuLCBjbGFzc05hbWUsIC4uLnJlc3QgfSkgPT5cbiAgICA8ZGl2IGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhjb21wQ2xhc3MsIGNsYXNzTmFtZSl9IHsuLi5yZXN0fT5cbiAgICAgIHtjaGlsZHJlbn1cbiAgICA8L2Rpdj5cbiAgY21wLmRpc3BsYXlOYW1lID0gZGlzcGxheU5hbWVcbiAgcmV0dXJuIGNtcFxufVxuXG5mdW5jdGlvbiBncm91cEJ5ICh4cywga2V5KSB7XG4gIHJldHVybiB4cy5yZWR1Y2UoKHJ2LCB4LCBpKSA9PiB7XG4gICAgY29uc3QgcmVzS2V5ID0gdHlwZW9mIGtleSA9PT0gJ2Z1bmN0aW9uJyA/IGtleSh4LCBpKSA6IHhba2V5XVxuICAgIHJ2W3Jlc0tleV0gPSBpc0FycmF5KHJ2W3Jlc0tleV0pID8gcnZbcmVzS2V5XSA6IFtdXG4gICAgcnZbcmVzS2V5XS5wdXNoKHgpXG4gICAgcmV0dXJuIHJ2XG4gIH0sIHt9KVxufVxuXG5mdW5jdGlvbiBhc1B4ICh2YWx1ZSkge1xuICB2YWx1ZSA9IE51bWJlcih2YWx1ZSlcbiAgcmV0dXJuIE51bWJlci5pc05hTih2YWx1ZSkgPyBudWxsIDogdmFsdWUgKyAncHgnXG59XG5cbmZ1bmN0aW9uIGlzQXJyYXkgKGEpIHtcbiAgcmV0dXJuIEFycmF5LmlzQXJyYXkoYSlcbn1cblxuLy8gIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjXG4vLyBOb24tZXhwb3J0ZWQgSGVscGVyc1xuLy8gIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjXG5cbmZ1bmN0aW9uIG1ha2VQYXRoQXJyYXkgKG9iaikge1xuICByZXR1cm4gZmxhdHRlbkRlZXAob2JqKVxuICAgIC5qb2luKCcuJylcbiAgICAucmVwbGFjZSgvXFxbL2csICcuJylcbiAgICAucmVwbGFjZSgvXFxdL2csICcnKVxuICAgIC5zcGxpdCgnLicpXG59XG5cbmZ1bmN0aW9uIGZsYXR0ZW5EZWVwIChhcnIsIG5ld0FyciA9IFtdKSB7XG4gIGlmICghaXNBcnJheShhcnIpKSB7XG4gICAgbmV3QXJyLnB1c2goYXJyKVxuICB9IGVsc2Uge1xuICAgIGZvciAodmFyIGkgPSAwOyBpIDwgYXJyLmxlbmd0aDsgaSsrKSB7XG4gICAgICBmbGF0dGVuRGVlcChhcnJbaV0sIG5ld0FycilcbiAgICB9XG4gIH1cbiAgcmV0dXJuIG5ld0FyclxufVxuXG5mdW5jdGlvbiBzcGxpdFByb3BzICh7IGNsYXNzTmFtZSwgc3R5bGUsIC4uLnJlc3QgfSkge1xuICByZXR1cm4ge1xuICAgIGNsYXNzTmFtZSxcbiAgICBzdHlsZSxcbiAgICByZXN0OiByZXN0IHx8IHt9LFxuICB9XG59XG5cbmZ1bmN0aW9uIGNvbXBhY3RPYmplY3QgKG9iaikge1xuICBjb25zdCBuZXdPYmogPSB7fVxuICBmb3IgKHZhciBrZXkgaW4gb2JqKSB7XG4gICAgaWYgKFxuICAgICAgb2JqLmhhc093blByb3BlcnR5KGtleSkgJiZcbiAgICAgIG9ialtrZXldICE9PSB1bmRlZmluZWQgJiZcbiAgICAgIHR5cGVvZiBvYmpba2V5XSAhPT0gJ3VuZGVmaW5lZCdcbiAgICApIHtcbiAgICAgIG5ld09ialtrZXldID0gb2JqW2tleV1cbiAgICB9XG4gIH1cbiAgcmV0dXJuIG5ld09ialxufVxuXG5mdW5jdGlvbiBpc1NvcnRpbmdEZXNjIChkKSB7XG4gIHJldHVybiAhIShkLnNvcnQgPT09ICdkZXNjJyB8fCBkLmRlc2MgPT09IHRydWUgfHwgZC5hc2MgPT09IGZhbHNlKVxufVxuXG5mdW5jdGlvbiBub3JtYWxpemVDb21wb25lbnQgKENvbXAsIHBhcmFtcyA9IHt9LCBmYWxsYmFjayA9IENvbXApIHtcbiAgcmV0dXJuIHR5cGVvZiBDb21wID09PSAnZnVuY3Rpb24nXG4gICAgPyBPYmplY3QuZ2V0UHJvdG90eXBlT2YoQ29tcCkuaXNSZWFjdENvbXBvbmVudFxuICAgICAgPyA8Q29tcCB7Li4ucGFyYW1zfSAvPlxuICAgICAgOiBDb21wKHBhcmFtcylcbiAgICA6IGZhbGxiYWNrXG59XG4iXX0= - ReactInjection.HostComponent.injectGenericComponentClass(ReactDOMComponent); +/***/ }), +/* 96 */ +/***/ (function(module, exports, __webpack_require__) { - ReactInjection.HostComponent.injectTextComponentClass(ReactDOMTextComponent); +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33); +var secp256k1 = __webpack_require__(168); +var bigi = __webpack_require__(30); +var zcrypto = __webpack_require__(107); +var zconfig = __webpack_require__(66); - ReactInjection.DOMProperty.injectDOMPropertyConfig(ARIADOMPropertyConfig); - ReactInjection.DOMProperty.injectDOMPropertyConfig(HTMLDOMPropertyConfig); - ReactInjection.DOMProperty.injectDOMPropertyConfig(SVGDOMPropertyConfig); +/* + * Makes a private key + * @param {String} phrase (Password phrase) + * @return {Sting} Private key + */ +function mkPrivKey(phrase) { + return zcrypto.sha256(Buffer.from(phrase, 'utf-8')); +} - ReactInjection.EmptyComponent.injectEmptyComponentFactory(function (instantiate) { - return new ReactDOMEmptyComponent(instantiate); - }); +/* + * Converts a private key to WIF format + * @param {String} privKey (private key) + * @param {boolean} toCompressed (Convert to WIF compressed key or nah) + * @param {string} wif (wif hashing bytes (default: 0x80)) + * @return {Sting} WIF format (uncompressed) + */ +function privKeyToWIF(privKey, toCompressed, wif) { + toCompressed = toCompressed || false; + wif = wif || zconfig.mainnet.wif; - ReactInjection.Updates.injectReconcileTransaction(ReactReconcileTransaction); - ReactInjection.Updates.injectBatchingStrategy(ReactDefaultBatchingStrategy); + if (toCompressed) privKey = privKey + '01'; - ReactInjection.Component.injectEnvironment(ReactComponentBrowserEnvironment); + return bs58check.encode(Buffer.from(wif + privKey, 'hex')); } -module.exports = { - inject: inject -}; +/* + * Returns private key's public Key + * @param {String} privKey (private key) + * @param {boolean} toCompressed (Convert to public key compressed key or nah) + * @return {Sting} Public Key (default: uncompressed) + */ +function privKeyToPubKey(privKey, toCompressed) { + toCompressed = toCompressed || false; -/***/ }), -/* 137 */ -/***/ (function(module, exports, __webpack_require__) { + const pkBuffer = Buffer.from(privKey, 'hex'); + var publicKey = secp256k1.publicKeyCreate(pkBuffer, toCompressed); + return publicKey.toString('hex'); +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * +/* + * Given a WIF format pk, convert it back to the original pk + * @param {String} privKey (private key) + * @return {Sting} Public Key (uncompressed) */ +function WIFToPrivKey(wifPk) { + var og = bs58check.decode(wifPk, 'hex').toString('hex'); + og = og.substr(2, og.length); // remove WIF format ('80') + // remove the '01' at the end to 'compress it' during WIF conversion + if (og.length > 64) { + og = og.substr(0, 64); + } + return og; +} -var ARIADOMPropertyConfig = { - Properties: { - // Global States and Properties - 'aria-current': 0, // state - 'aria-details': 0, - 'aria-disabled': 0, // state - 'aria-hidden': 0, // state - 'aria-invalid': 0, // state - 'aria-keyshortcuts': 0, - 'aria-label': 0, - 'aria-roledescription': 0, - // Widget Attributes - 'aria-autocomplete': 0, - 'aria-checked': 0, - 'aria-expanded': 0, - 'aria-haspopup': 0, - 'aria-level': 0, - 'aria-modal': 0, - 'aria-multiline': 0, - 'aria-multiselectable': 0, - 'aria-orientation': 0, - 'aria-placeholder': 0, - 'aria-pressed': 0, - 'aria-readonly': 0, - 'aria-required': 0, - 'aria-selected': 0, - 'aria-sort': 0, - 'aria-valuemax': 0, - 'aria-valuemin': 0, - 'aria-valuenow': 0, - 'aria-valuetext': 0, - // Live Region Attributes - 'aria-atomic': 0, - 'aria-busy': 0, - 'aria-live': 0, - 'aria-relevant': 0, - // Drag-and-Drop Attributes - 'aria-dropeffect': 0, - 'aria-grabbed': 0, - // Relationship Attributes - 'aria-activedescendant': 0, - 'aria-colcount': 0, - 'aria-colindex': 0, - 'aria-colspan': 0, - 'aria-controls': 0, - 'aria-describedby': 0, - 'aria-errormessage': 0, - 'aria-flowto': 0, - 'aria-labelledby': 0, - 'aria-owns': 0, - 'aria-posinset': 0, - 'aria-rowcount': 0, - 'aria-rowindex': 0, - 'aria-rowspan': 0, - 'aria-setsize': 0 - }, - DOMAttributeNames: {}, - DOMPropertyNames: {} -}; +/* + * Converts public key to zencash address + * @param {String} pubKey (public key) + * @param {String} pubKeyHash (public key hash (optional, else use defaul)) + * @return {Sting} zencash address + */ +function pubKeyToAddr(pubKey, pubKeyHash) { + pubKeyHash = pubKeyHash || zconfig.mainnet.pubKeyHash; -module.exports = ARIADOMPropertyConfig; + const hash160 = zcrypto.hash160(Buffer.from(pubKey, 'hex')); + return bs58check.encode(Buffer.from(pubKeyHash + hash160, 'hex')).toString('hex'); +} + +module.exports = { + mkPrivKey: mkPrivKey, + privKeyToWIF: privKeyToWIF, + privKeyToPubKey: privKeyToPubKey, + pubKeyToAddr: pubKeyToAddr, + WIFToPrivKey: WIFToPrivKey +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 138 */ +/* 97 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) { +var inherits = __webpack_require__(4) +var HashBase = __webpack_require__(366) + +function RIPEMD160 () { + HashBase.call(this, 64) + + // state + this._a = 0x67452301 + this._b = 0xefcdab89 + this._c = 0x98badcfe + this._d = 0x10325476 + this._e = 0xc3d2e1f0 +} +inherits(RIPEMD160, HashBase) + +RIPEMD160.prototype._update = function () { + var m = new Array(16) + for (var i = 0; i < 16; ++i) m[i] = this._block.readInt32LE(i * 4) + + var al = this._a + var bl = this._b + var cl = this._c + var dl = this._d + var el = this._e + + // Mj = 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 + // K = 0x00000000 + // Sj = 11, 14, 15, 12, 5, 8, 7, 9, 11, 13, 14, 15, 6, 7, 9, 8 + al = fn1(al, bl, cl, dl, el, m[0], 0x00000000, 11); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[1], 0x00000000, 14); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[2], 0x00000000, 15); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[3], 0x00000000, 12); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[4], 0x00000000, 5); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[5], 0x00000000, 8); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[6], 0x00000000, 7); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[7], 0x00000000, 9); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[8], 0x00000000, 11); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[9], 0x00000000, 13); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[10], 0x00000000, 14); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[11], 0x00000000, 15); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[12], 0x00000000, 6); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[13], 0x00000000, 7); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[14], 0x00000000, 9); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[15], 0x00000000, 8); cl = rotl(cl, 10) + + // Mj = 7, 4, 13, 1, 10, 6, 15, 3, 12, 0, 9, 5, 2, 14, 11, 8 + // K = 0x5a827999 + // Sj = 7, 6, 8, 13, 11, 9, 7, 15, 7, 12, 15, 9, 11, 7, 13, 12 + el = fn2(el, al, bl, cl, dl, m[7], 0x5a827999, 7); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[4], 0x5a827999, 6); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[13], 0x5a827999, 8); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[1], 0x5a827999, 13); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[10], 0x5a827999, 11); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[6], 0x5a827999, 9); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[15], 0x5a827999, 7); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[3], 0x5a827999, 15); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[12], 0x5a827999, 7); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[0], 0x5a827999, 12); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[9], 0x5a827999, 15); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[5], 0x5a827999, 9); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[2], 0x5a827999, 11); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[14], 0x5a827999, 7); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[11], 0x5a827999, 13); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[8], 0x5a827999, 12); bl = rotl(bl, 10) + + // Mj = 3, 10, 14, 4, 9, 15, 8, 1, 2, 7, 0, 6, 13, 11, 5, 12 + // K = 0x6ed9eba1 + // Sj = 11, 13, 6, 7, 14, 9, 13, 15, 14, 8, 13, 6, 5, 12, 7, 5 + dl = fn3(dl, el, al, bl, cl, m[3], 0x6ed9eba1, 11); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[10], 0x6ed9eba1, 13); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[14], 0x6ed9eba1, 6); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[4], 0x6ed9eba1, 7); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[9], 0x6ed9eba1, 14); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[15], 0x6ed9eba1, 9); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[8], 0x6ed9eba1, 13); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[1], 0x6ed9eba1, 15); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[2], 0x6ed9eba1, 14); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[7], 0x6ed9eba1, 8); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[0], 0x6ed9eba1, 13); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[6], 0x6ed9eba1, 6); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[13], 0x6ed9eba1, 5); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[11], 0x6ed9eba1, 12); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[5], 0x6ed9eba1, 7); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[12], 0x6ed9eba1, 5); al = rotl(al, 10) + + // Mj = 1, 9, 11, 10, 0, 8, 12, 4, 13, 3, 7, 15, 14, 5, 6, 2 + // K = 0x8f1bbcdc + // Sj = 11, 12, 14, 15, 14, 15, 9, 8, 9, 14, 5, 6, 8, 6, 5, 12 + cl = fn4(cl, dl, el, al, bl, m[1], 0x8f1bbcdc, 11); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[9], 0x8f1bbcdc, 12); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[11], 0x8f1bbcdc, 14); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[10], 0x8f1bbcdc, 15); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[0], 0x8f1bbcdc, 14); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[8], 0x8f1bbcdc, 15); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[12], 0x8f1bbcdc, 9); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[4], 0x8f1bbcdc, 8); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[13], 0x8f1bbcdc, 9); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[3], 0x8f1bbcdc, 14); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[7], 0x8f1bbcdc, 5); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[15], 0x8f1bbcdc, 6); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[14], 0x8f1bbcdc, 8); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[5], 0x8f1bbcdc, 6); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[6], 0x8f1bbcdc, 5); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[2], 0x8f1bbcdc, 12); el = rotl(el, 10) + + // Mj = 4, 0, 5, 9, 7, 12, 2, 10, 14, 1, 3, 8, 11, 6, 15, 13 + // K = 0xa953fd4e + // Sj = 9, 15, 5, 11, 6, 8, 13, 12, 5, 12, 13, 14, 11, 8, 5, 6 + bl = fn5(bl, cl, dl, el, al, m[4], 0xa953fd4e, 9); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[0], 0xa953fd4e, 15); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[5], 0xa953fd4e, 5); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[9], 0xa953fd4e, 11); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[7], 0xa953fd4e, 6); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[12], 0xa953fd4e, 8); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[2], 0xa953fd4e, 13); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[10], 0xa953fd4e, 12); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[14], 0xa953fd4e, 5); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[1], 0xa953fd4e, 12); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[3], 0xa953fd4e, 13); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[8], 0xa953fd4e, 14); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[11], 0xa953fd4e, 11); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[6], 0xa953fd4e, 8); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[15], 0xa953fd4e, 5); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[13], 0xa953fd4e, 6); dl = rotl(dl, 10) + + var ar = this._a + var br = this._b + var cr = this._c + var dr = this._d + var er = this._e + + // M'j = 5, 14, 7, 0, 9, 2, 11, 4, 13, 6, 15, 8, 1, 10, 3, 12 + // K' = 0x50a28be6 + // S'j = 8, 9, 9, 11, 13, 15, 15, 5, 7, 7, 8, 11, 14, 14, 12, 6 + ar = fn5(ar, br, cr, dr, er, m[5], 0x50a28be6, 8); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[14], 0x50a28be6, 9); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[7], 0x50a28be6, 9); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[0], 0x50a28be6, 11); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[9], 0x50a28be6, 13); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[2], 0x50a28be6, 15); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[11], 0x50a28be6, 15); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[4], 0x50a28be6, 5); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[13], 0x50a28be6, 7); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[6], 0x50a28be6, 7); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[15], 0x50a28be6, 8); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[8], 0x50a28be6, 11); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[1], 0x50a28be6, 14); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[10], 0x50a28be6, 14); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[3], 0x50a28be6, 12); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[12], 0x50a28be6, 6); cr = rotl(cr, 10) + + // M'j = 6, 11, 3, 7, 0, 13, 5, 10, 14, 15, 8, 12, 4, 9, 1, 2 + // K' = 0x5c4dd124 + // S'j = 9, 13, 15, 7, 12, 8, 9, 11, 7, 7, 12, 7, 6, 15, 13, 11 + er = fn4(er, ar, br, cr, dr, m[6], 0x5c4dd124, 9); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[11], 0x5c4dd124, 13); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[3], 0x5c4dd124, 15); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[7], 0x5c4dd124, 7); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[0], 0x5c4dd124, 12); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[13], 0x5c4dd124, 8); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[5], 0x5c4dd124, 9); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[10], 0x5c4dd124, 11); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[14], 0x5c4dd124, 7); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[15], 0x5c4dd124, 7); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[8], 0x5c4dd124, 12); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[12], 0x5c4dd124, 7); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[4], 0x5c4dd124, 6); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[9], 0x5c4dd124, 15); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[1], 0x5c4dd124, 13); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[2], 0x5c4dd124, 11); br = rotl(br, 10) + + // M'j = 15, 5, 1, 3, 7, 14, 6, 9, 11, 8, 12, 2, 10, 0, 4, 13 + // K' = 0x6d703ef3 + // S'j = 9, 7, 15, 11, 8, 6, 6, 14, 12, 13, 5, 14, 13, 13, 7, 5 + dr = fn3(dr, er, ar, br, cr, m[15], 0x6d703ef3, 9); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[5], 0x6d703ef3, 7); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[1], 0x6d703ef3, 15); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[3], 0x6d703ef3, 11); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[7], 0x6d703ef3, 8); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[14], 0x6d703ef3, 6); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[6], 0x6d703ef3, 6); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[9], 0x6d703ef3, 14); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[11], 0x6d703ef3, 12); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[8], 0x6d703ef3, 13); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[12], 0x6d703ef3, 5); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[2], 0x6d703ef3, 14); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[10], 0x6d703ef3, 13); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[0], 0x6d703ef3, 13); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[4], 0x6d703ef3, 7); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[13], 0x6d703ef3, 5); ar = rotl(ar, 10) + + // M'j = 8, 6, 4, 1, 3, 11, 15, 0, 5, 12, 2, 13, 9, 7, 10, 14 + // K' = 0x7a6d76e9 + // S'j = 15, 5, 8, 11, 14, 14, 6, 14, 6, 9, 12, 9, 12, 5, 15, 8 + cr = fn2(cr, dr, er, ar, br, m[8], 0x7a6d76e9, 15); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[6], 0x7a6d76e9, 5); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[4], 0x7a6d76e9, 8); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[1], 0x7a6d76e9, 11); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[3], 0x7a6d76e9, 14); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[11], 0x7a6d76e9, 14); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[15], 0x7a6d76e9, 6); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[0], 0x7a6d76e9, 14); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[5], 0x7a6d76e9, 6); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[12], 0x7a6d76e9, 9); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[2], 0x7a6d76e9, 12); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[13], 0x7a6d76e9, 9); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[9], 0x7a6d76e9, 12); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[7], 0x7a6d76e9, 5); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[10], 0x7a6d76e9, 15); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[14], 0x7a6d76e9, 8); er = rotl(er, 10) + + // M'j = 12, 15, 10, 4, 1, 5, 8, 7, 6, 2, 13, 14, 0, 3, 9, 11 + // K' = 0x00000000 + // S'j = 8, 5, 12, 9, 12, 5, 14, 6, 8, 13, 6, 5, 15, 13, 11, 11 + br = fn1(br, cr, dr, er, ar, m[12], 0x00000000, 8); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[15], 0x00000000, 5); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[10], 0x00000000, 12); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[4], 0x00000000, 9); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[1], 0x00000000, 12); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[5], 0x00000000, 5); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[8], 0x00000000, 14); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[7], 0x00000000, 6); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[6], 0x00000000, 8); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[2], 0x00000000, 13); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[13], 0x00000000, 6); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[14], 0x00000000, 5); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[0], 0x00000000, 15); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[3], 0x00000000, 13); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[9], 0x00000000, 11); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[11], 0x00000000, 11); dr = rotl(dr, 10) + + // change state + var t = (this._b + cl + dr) | 0 + this._b = (this._c + dl + er) | 0 + this._c = (this._d + el + ar) | 0 + this._d = (this._e + al + br) | 0 + this._e = (this._a + bl + cr) | 0 + this._a = t +} +RIPEMD160.prototype._digest = function () { + // create padding and handle blocks + this._block[this._blockOffset++] = 0x80 + if (this._blockOffset > 56) { + this._block.fill(0, this._blockOffset, 64) + this._update() + this._blockOffset = 0 + } + + this._block.fill(0, this._blockOffset, 56) + this._block.writeUInt32LE(this._length[0], 56) + this._block.writeUInt32LE(this._length[1], 60) + this._update() + + // produce result + var buffer = new Buffer(20) + buffer.writeInt32LE(this._a, 0) + buffer.writeInt32LE(this._b, 4) + buffer.writeInt32LE(this._c, 8) + buffer.writeInt32LE(this._d, 12) + buffer.writeInt32LE(this._e, 16) + return buffer +} -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var FallbackCompositionState = __webpack_require__(139); -var SyntheticCompositionEvent = __webpack_require__(140); -var SyntheticInputEvent = __webpack_require__(141); +function rotl (x, n) { + return (x << n) | (x >>> (32 - n)) +} -var END_KEYCODES = [9, 13, 27, 32]; // Tab, Return, Esc, Space -var START_KEYCODE = 229; +function fn1 (a, b, c, d, e, m, k, s) { + return (rotl((a + (b ^ c ^ d) + m + k) | 0, s) + e) | 0 +} -var canUseCompositionEvent = ExecutionEnvironment.canUseDOM && 'CompositionEvent' in window; +function fn2 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b & c) | ((~b) & d)) + m + k) | 0, s) + e) | 0 +} -var documentMode = null; -if (ExecutionEnvironment.canUseDOM && 'documentMode' in document) { - documentMode = document.documentMode; +function fn3 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b | (~c)) ^ d) + m + k) | 0, s) + e) | 0 } -// Webkit offers a very useful `textInput` event that can be used to -// directly represent `beforeInput`. The IE `textinput` event is not as -// useful, so we don't use it. -var canUseTextInputEvent = ExecutionEnvironment.canUseDOM && 'TextEvent' in window && !documentMode && !isPresto(); +function fn4 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b & d) | (c & (~d))) + m + k) | 0, s) + e) | 0 +} -// In IE9+, we have access to composition events, but the data supplied -// by the native compositionend event may be incorrect. Japanese ideographic -// spaces, for instance (\u3000) are not recorded correctly. -var useFallbackCompositionData = ExecutionEnvironment.canUseDOM && (!canUseCompositionEvent || documentMode && documentMode > 8 && documentMode <= 11); +function fn5 (a, b, c, d, e, m, k, s) { + return (rotl((a + (b ^ (c | (~d))) + m + k) | 0, s) + e) | 0 +} -/** - * Opera <= 12 includes TextEvent in window, but does not fire - * text input events. Rely on keypress instead. - */ -function isPresto() { - var opera = window.opera; - return typeof opera === 'object' && typeof opera.version === 'function' && parseInt(opera.version(), 10) <= 12; +module.exports = RIPEMD160 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 98 */ +/***/ (function(module, exports, __webpack_require__) { + +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +module.exports = Stream; + +var EE = __webpack_require__(99).EventEmitter; +var inherits = __webpack_require__(4); + +inherits(Stream, EE); +Stream.Readable = __webpack_require__(100); +Stream.Writable = __webpack_require__(372); +Stream.Duplex = __webpack_require__(373); +Stream.Transform = __webpack_require__(374); +Stream.PassThrough = __webpack_require__(375); + +// Backwards-compat with node 0.4.x +Stream.Stream = Stream; + + + +// old-style streams. Note that the pipe method (the only relevant +// part of this class) is overridden in the Readable class. + +function Stream() { + EE.call(this); } -var SPACEBAR_CODE = 32; -var SPACEBAR_CHAR = String.fromCharCode(SPACEBAR_CODE); +Stream.prototype.pipe = function(dest, options) { + var source = this; -// Events and their corresponding property names. -var eventTypes = { - beforeInput: { - phasedRegistrationNames: { - bubbled: 'onBeforeInput', - captured: 'onBeforeInputCapture' - }, - dependencies: ['topCompositionEnd', 'topKeyPress', 'topTextInput', 'topPaste'] - }, - compositionEnd: { - phasedRegistrationNames: { - bubbled: 'onCompositionEnd', - captured: 'onCompositionEndCapture' - }, - dependencies: ['topBlur', 'topCompositionEnd', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] - }, - compositionStart: { - phasedRegistrationNames: { - bubbled: 'onCompositionStart', - captured: 'onCompositionStartCapture' - }, - dependencies: ['topBlur', 'topCompositionStart', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] - }, - compositionUpdate: { - phasedRegistrationNames: { - bubbled: 'onCompositionUpdate', - captured: 'onCompositionUpdateCapture' - }, - dependencies: ['topBlur', 'topCompositionUpdate', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + function ondata(chunk) { + if (dest.writable) { + if (false === dest.write(chunk) && source.pause) { + source.pause(); + } + } } -}; - -// Track whether we've ever handled a keypress on the space key. -var hasSpaceKeypress = false; -/** - * Return whether a native keypress event is assumed to be a command. - * This is required because Firefox fires `keypress` events for key commands - * (cut, copy, select-all, etc.) even though no character is inserted. - */ -function isKeypressCommand(nativeEvent) { - return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) && - // ctrlKey && altKey is equivalent to AltGr, and is not a command. - !(nativeEvent.ctrlKey && nativeEvent.altKey); -} + source.on('data', ondata); -/** - * Translate native top level events into event types. - * - * @param {string} topLevelType - * @return {object} - */ -function getCompositionEventType(topLevelType) { - switch (topLevelType) { - case 'topCompositionStart': - return eventTypes.compositionStart; - case 'topCompositionEnd': - return eventTypes.compositionEnd; - case 'topCompositionUpdate': - return eventTypes.compositionUpdate; + function ondrain() { + if (source.readable && source.resume) { + source.resume(); + } } -} -/** - * Does our fallback best-guess model think this event signifies that - * composition has begun? - * - * @param {string} topLevelType - * @param {object} nativeEvent - * @return {boolean} - */ -function isFallbackCompositionStart(topLevelType, nativeEvent) { - return topLevelType === 'topKeyDown' && nativeEvent.keyCode === START_KEYCODE; -} + dest.on('drain', ondrain); -/** - * Does our fallback mode think that this event is the end of composition? - * - * @param {string} topLevelType - * @param {object} nativeEvent - * @return {boolean} - */ -function isFallbackCompositionEnd(topLevelType, nativeEvent) { - switch (topLevelType) { - case 'topKeyUp': - // Command keys insert or clear IME input. - return END_KEYCODES.indexOf(nativeEvent.keyCode) !== -1; - case 'topKeyDown': - // Expect IME keyCode on each keydown. If we get any other - // code we must have exited earlier. - return nativeEvent.keyCode !== START_KEYCODE; - case 'topKeyPress': - case 'topMouseDown': - case 'topBlur': - // Events are not possible without cancelling IME. - return true; - default: - return false; + // If the 'end' option is not supplied, dest.end() will be called when + // source gets the 'end' or 'close' events. Only dest.end() once. + if (!dest._isStdio && (!options || options.end !== false)) { + source.on('end', onend); + source.on('close', onclose); } -} -/** - * Google Input Tools provides composition data via a CustomEvent, - * with the `data` property populated in the `detail` object. If this - * is available on the event object, use it. If not, this is a plain - * composition event and we have nothing special to extract. - * - * @param {object} nativeEvent - * @return {?string} - */ -function getDataFromCustomEvent(nativeEvent) { - var detail = nativeEvent.detail; - if (typeof detail === 'object' && 'data' in detail) { - return detail.data; - } - return null; -} + var didOnEnd = false; + function onend() { + if (didOnEnd) return; + didOnEnd = true; -// Track the current IME composition fallback object, if any. -var currentComposition = null; + dest.end(); + } -/** - * @return {?object} A SyntheticCompositionEvent. - */ -function extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var eventType; - var fallbackData; - if (canUseCompositionEvent) { - eventType = getCompositionEventType(topLevelType); - } else if (!currentComposition) { - if (isFallbackCompositionStart(topLevelType, nativeEvent)) { - eventType = eventTypes.compositionStart; - } - } else if (isFallbackCompositionEnd(topLevelType, nativeEvent)) { - eventType = eventTypes.compositionEnd; - } + function onclose() { + if (didOnEnd) return; + didOnEnd = true; - if (!eventType) { - return null; + if (typeof dest.destroy === 'function') dest.destroy(); } - if (useFallbackCompositionData) { - // The current composition is stored statically and must not be - // overwritten while composition continues. - if (!currentComposition && eventType === eventTypes.compositionStart) { - currentComposition = FallbackCompositionState.getPooled(nativeEventTarget); - } else if (eventType === eventTypes.compositionEnd) { - if (currentComposition) { - fallbackData = currentComposition.getData(); - } + // don't leave dangling pipes when there are errors. + function onerror(er) { + cleanup(); + if (EE.listenerCount(this, 'error') === 0) { + throw er; // Unhandled stream error in pipe. } } - var event = SyntheticCompositionEvent.getPooled(eventType, targetInst, nativeEvent, nativeEventTarget); + source.on('error', onerror); + dest.on('error', onerror); - if (fallbackData) { - // Inject data generated from fallback path into the synthetic event. - // This matches the property of native CompositionEventInterface. - event.data = fallbackData; - } else { - var customData = getDataFromCustomEvent(nativeEvent); - if (customData !== null) { - event.data = customData; - } + // remove all the event listeners that were added. + function cleanup() { + source.removeListener('data', ondata); + dest.removeListener('drain', ondrain); + + source.removeListener('end', onend); + source.removeListener('close', onclose); + + source.removeListener('error', onerror); + dest.removeListener('error', onerror); + + source.removeListener('end', cleanup); + source.removeListener('close', cleanup); + + dest.removeListener('close', cleanup); } - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; -} + source.on('end', cleanup); + source.on('close', cleanup); -/** - * @param {string} topLevelType Record from `EventConstants`. - * @param {object} nativeEvent Native browser event. - * @return {?string} The string corresponding to this `beforeInput` event. - */ -function getNativeBeforeInputChars(topLevelType, nativeEvent) { - switch (topLevelType) { - case 'topCompositionEnd': - return getDataFromCustomEvent(nativeEvent); - case 'topKeyPress': - /** - * If native `textInput` events are available, our goal is to make - * use of them. However, there is a special case: the spacebar key. - * In Webkit, preventing default on a spacebar `textInput` event - * cancels character insertion, but it *also* causes the browser - * to fall back to its default spacebar behavior of scrolling the - * page. - * - * Tracking at: - * https://code.google.com/p/chromium/issues/detail?id=355103 - * - * To avoid this issue, use the keypress event as if no `textInput` - * event is available. - */ - var which = nativeEvent.which; - if (which !== SPACEBAR_CODE) { - return null; - } + dest.on('close', cleanup); - hasSpaceKeypress = true; - return SPACEBAR_CHAR; + dest.emit('pipe', source); - case 'topTextInput': - // Record the characters to be added to the DOM. - var chars = nativeEvent.data; + // Allow for unix-like usage: A.pipe(B).pipe(C) + return dest; +}; - // If it's a spacebar character, assume that we have already handled - // it at the keypress level and bail immediately. Android Chrome - // doesn't give us keycodes, so we need to blacklist it. - if (chars === SPACEBAR_CHAR && hasSpaceKeypress) { - return null; - } - return chars; +/***/ }), +/* 99 */ +/***/ (function(module, exports) { - default: - // For other native event types, do nothing. - return null; - } +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +function EventEmitter() { + this._events = this._events || {}; + this._maxListeners = this._maxListeners || undefined; } +module.exports = EventEmitter; -/** - * For browsers that do not provide the `textInput` event, extract the - * appropriate string to use for SyntheticInputEvent. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {object} nativeEvent Native browser event. - * @return {?string} The fallback string for this `beforeInput` event. - */ -function getFallbackBeforeInputChars(topLevelType, nativeEvent) { - // If we are currently composing (IME) and using a fallback to do so, - // try to extract the composed characters from the fallback object. - // If composition event is available, we extract a string only at - // compositionevent, otherwise extract it at fallback events. - if (currentComposition) { - if (topLevelType === 'topCompositionEnd' || !canUseCompositionEvent && isFallbackCompositionEnd(topLevelType, nativeEvent)) { - var chars = currentComposition.getData(); - FallbackCompositionState.release(currentComposition); - currentComposition = null; - return chars; - } - return null; - } +// Backwards-compat with node 0.10.x +EventEmitter.EventEmitter = EventEmitter; - switch (topLevelType) { - case 'topPaste': - // If a paste event occurs after a keypress, throw out the input - // chars. Paste events should not lead to BeforeInput events. - return null; - case 'topKeyPress': - /** - * As of v27, Firefox may fire keypress events even when no character - * will be inserted. A few possibilities: - * - * - `which` is `0`. Arrow keys, Esc key, etc. - * - * - `which` is the pressed key code, but no char is available. - * Ex: 'AltGr + d` in Polish. There is no modified character for - * this key combination and no character is inserted into the - * document, but FF fires the keypress for char code `100` anyway. - * No `input` event will occur. - * - * - `which` is the pressed key code, but a command combination is - * being used. Ex: `Cmd+C`. No character is inserted, and no - * `input` event will occur. - */ - if (nativeEvent.which && !isKeypressCommand(nativeEvent)) { - return String.fromCharCode(nativeEvent.which); - } - return null; - case 'topCompositionEnd': - return useFallbackCompositionData ? null : nativeEvent.data; - default: - return null; - } -} +EventEmitter.prototype._events = undefined; +EventEmitter.prototype._maxListeners = undefined; -/** - * Extract a SyntheticInputEvent for `beforeInput`, based on either native - * `textInput` or fallback behavior. - * - * @return {?object} A SyntheticInputEvent. - */ -function extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var chars; +// By default EventEmitters will print a warning if more than 10 listeners are +// added to it. This is a useful default which helps finding memory leaks. +EventEmitter.defaultMaxListeners = 10; - if (canUseTextInputEvent) { - chars = getNativeBeforeInputChars(topLevelType, nativeEvent); - } else { - chars = getFallbackBeforeInputChars(topLevelType, nativeEvent); - } +// Obviously not all Emitters should be limited to 10. This function allows +// that to be increased. Set to zero for unlimited. +EventEmitter.prototype.setMaxListeners = function(n) { + if (!isNumber(n) || n < 0 || isNaN(n)) + throw TypeError('n must be a positive number'); + this._maxListeners = n; + return this; +}; - // If no characters are being inserted, no BeforeInput event should - // be fired. - if (!chars) { - return null; - } +EventEmitter.prototype.emit = function(type) { + var er, handler, len, args, i, listeners; - var event = SyntheticInputEvent.getPooled(eventTypes.beforeInput, targetInst, nativeEvent, nativeEventTarget); + if (!this._events) + this._events = {}; - event.data = chars; - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; -} + // If there is no 'error' event listener then throw. + if (type === 'error') { + if (!this._events.error || + (isObject(this._events.error) && !this._events.error.length)) { + er = arguments[1]; + if (er instanceof Error) { + throw er; // Unhandled 'error' event + } else { + // At least give some kind of context to the user + var err = new Error('Uncaught, unspecified "error" event. (' + er + ')'); + err.context = er; + throw err; + } + } + } -/** - * Create an `onBeforeInput` event to match - * http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105/#events-inputevents. - * - * This event plugin is based on the native `textInput` event - * available in Chrome, Safari, Opera, and IE. This event fires after - * `onKeyPress` and `onCompositionEnd`, but before `onInput`. - * - * `beforeInput` is spec'd but not implemented in any browsers, and - * the `input` event does not provide any useful information about what has - * actually been added, contrary to the spec. Thus, `textInput` is the best - * available event to identify the characters that have actually been inserted - * into the target node. - * - * This plugin is also responsible for emitting `composition` events, thus - * allowing us to share composition fallback code for both `beforeInput` and - * `composition` event types. - */ -var BeforeInputEventPlugin = { - eventTypes: eventTypes, + handler = this._events[type]; - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - return [extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget), extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget)]; + if (isUndefined(handler)) + return false; + + if (isFunction(handler)) { + switch (arguments.length) { + // fast cases + case 1: + handler.call(this); + break; + case 2: + handler.call(this, arguments[1]); + break; + case 3: + handler.call(this, arguments[1], arguments[2]); + break; + // slower + default: + args = Array.prototype.slice.call(arguments, 1); + handler.apply(this, args); + } + } else if (isObject(handler)) { + args = Array.prototype.slice.call(arguments, 1); + listeners = handler.slice(); + len = listeners.length; + for (i = 0; i < len; i++) + listeners[i].apply(this, args); } + + return true; }; -module.exports = BeforeInputEventPlugin; +EventEmitter.prototype.addListener = function(type, listener) { + var m; + + if (!isFunction(listener)) + throw TypeError('listener must be a function'); + + if (!this._events) + this._events = {}; + + // To avoid recursion in the case that type === "newListener"! Before + // adding it to the listeners, first emit "newListener". + if (this._events.newListener) + this.emit('newListener', type, + isFunction(listener.listener) ? + listener.listener : listener); + + if (!this._events[type]) + // Optimize the case of one listener. Don't need the extra array object. + this._events[type] = listener; + else if (isObject(this._events[type])) + // If we've already got an array, just append. + this._events[type].push(listener); + else + // Adding the second element, need to change to array. + this._events[type] = [this._events[type], listener]; + + // Check for listener leak + if (isObject(this._events[type]) && !this._events[type].warned) { + if (!isUndefined(this._maxListeners)) { + m = this._maxListeners; + } else { + m = EventEmitter.defaultMaxListeners; + } + + if (m && m > 0 && this._events[type].length > m) { + this._events[type].warned = true; + console.error('(node) warning: possible EventEmitter memory ' + + 'leak detected. %d listeners added. ' + + 'Use emitter.setMaxListeners() to increase limit.', + this._events[type].length); + if (typeof console.trace === 'function') { + // not supported in IE 10 + console.trace(); + } + } + } -/***/ }), -/* 139 */ -/***/ (function(module, exports, __webpack_require__) { + return this; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +EventEmitter.prototype.on = EventEmitter.prototype.addListener; +EventEmitter.prototype.once = function(type, listener) { + if (!isFunction(listener)) + throw TypeError('listener must be a function'); + var fired = false; -var _assign = __webpack_require__(5); + function g() { + this.removeListener(type, g); -var PooledClass = __webpack_require__(20); + if (!fired) { + fired = true; + listener.apply(this, arguments); + } + } -var getTextContentAccessor = __webpack_require__(84); + g.listener = listener; + this.on(type, g); -/** - * This helper class stores information about text content of a target node, - * allowing comparison of content before and after a given event. - * - * Identify the node where selection currently begins, then observe - * both its text content and its current position in the DOM. Since the - * browser may natively replace the target node during composition, we can - * use its position to find its replacement. - * - * @param {DOMEventTarget} root - */ -function FallbackCompositionState(root) { - this._root = root; - this._startText = this.getText(); - this._fallbackText = null; -} + return this; +}; -_assign(FallbackCompositionState.prototype, { - destructor: function () { - this._root = null; - this._startText = null; - this._fallbackText = null; - }, +// emits a 'removeListener' event iff the listener was removed +EventEmitter.prototype.removeListener = function(type, listener) { + var list, position, length, i; - /** - * Get current text of input. - * - * @return {string} - */ - getText: function () { - if ('value' in this._root) { - return this._root.value; - } - return this._root[getTextContentAccessor()]; - }, + if (!isFunction(listener)) + throw TypeError('listener must be a function'); - /** - * Determine the differing substring between the initially stored - * text content and the current content. - * - * @return {string} - */ - getData: function () { - if (this._fallbackText) { - return this._fallbackText; - } + if (!this._events || !this._events[type]) + return this; - var start; - var startValue = this._startText; - var startLength = startValue.length; - var end; - var endValue = this.getText(); - var endLength = endValue.length; + list = this._events[type]; + length = list.length; + position = -1; - for (start = 0; start < startLength; start++) { - if (startValue[start] !== endValue[start]) { + if (list === listener || + (isFunction(list.listener) && list.listener === listener)) { + delete this._events[type]; + if (this._events.removeListener) + this.emit('removeListener', type, listener); + + } else if (isObject(list)) { + for (i = length; i-- > 0;) { + if (list[i] === listener || + (list[i].listener && list[i].listener === listener)) { + position = i; break; } } - var minEnd = startLength - start; - for (end = 1; end <= minEnd; end++) { - if (startValue[startLength - end] !== endValue[endLength - end]) { - break; - } + if (position < 0) + return this; + + if (list.length === 1) { + list.length = 0; + delete this._events[type]; + } else { + list.splice(position, 1); } - var sliceTail = end > 1 ? 1 - end : undefined; - this._fallbackText = endValue.slice(start, sliceTail); - return this._fallbackText; + if (this._events.removeListener) + this.emit('removeListener', type, listener); } -}); -PooledClass.addPoolingTo(FallbackCompositionState); + return this; +}; -module.exports = FallbackCompositionState; +EventEmitter.prototype.removeAllListeners = function(type) { + var key, listeners; -/***/ }), -/* 140 */ -/***/ (function(module, exports, __webpack_require__) { + if (!this._events) + return this; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // not listening for removeListener, no need to emit + if (!this._events.removeListener) { + if (arguments.length === 0) + this._events = {}; + else if (this._events[type]) + delete this._events[type]; + return this; + } + // emit removeListener for all listeners on all events + if (arguments.length === 0) { + for (key in this._events) { + if (key === 'removeListener') continue; + this.removeAllListeners(key); + } + this.removeAllListeners('removeListener'); + this._events = {}; + return this; + } + listeners = this._events[type]; -var SyntheticEvent = __webpack_require__(16); + if (isFunction(listeners)) { + this.removeListener(type, listeners); + } else if (listeners) { + // LIFO order + while (listeners.length) + this.removeListener(type, listeners[listeners.length - 1]); + } + delete this._events[type]; -/** - * @interface Event - * @see http://www.w3.org/TR/DOM-Level-3-Events/#events-compositionevents - */ -var CompositionEventInterface = { - data: null + return this; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticCompositionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +EventEmitter.prototype.listeners = function(type) { + var ret; + if (!this._events || !this._events[type]) + ret = []; + else if (isFunction(this._events[type])) + ret = [this._events[type]]; + else + ret = this._events[type].slice(); + return ret; +}; + +EventEmitter.prototype.listenerCount = function(type) { + if (this._events) { + var evlistener = this._events[type]; + + if (isFunction(evlistener)) + return 1; + else if (evlistener) + return evlistener.length; + } + return 0; +}; + +EventEmitter.listenerCount = function(emitter, type) { + return emitter.listenerCount(type); +}; + +function isFunction(arg) { + return typeof arg === 'function'; } -SyntheticEvent.augmentClass(SyntheticCompositionEvent, CompositionEventInterface); +function isNumber(arg) { + return typeof arg === 'number'; +} + +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} + +function isUndefined(arg) { + return arg === void 0; +} -module.exports = SyntheticCompositionEvent; /***/ }), -/* 141 */ +/* 100 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +exports = module.exports = __webpack_require__(161); +exports.Stream = exports; +exports.Readable = exports; +exports.Writable = __webpack_require__(101); +exports.Duplex = __webpack_require__(34); +exports.Transform = __webpack_require__(165); +exports.PassThrough = __webpack_require__(371); +/***/ }), +/* 101 */ +/***/ (function(module, exports, __webpack_require__) { -var SyntheticEvent = __webpack_require__(16); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process, setImmediate, global) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// A bit simpler than readable streams. +// Implement an async ._write(chunk, encoding, cb), and it'll handle all +// the drain event emission and buffering. + + + +/*<replacement>*/ + +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +module.exports = Writable; + +/* <replacement> */ +function WriteReq(chunk, encoding, cb) { + this.chunk = chunk; + this.encoding = encoding; + this.callback = cb; + this.next = null; +} -/** - * @interface Event - * @see http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105 - * /#events-inputevents - */ -var InputEventInterface = { - data: null -}; +// It seems a linked list but it is not +// there will be only 2 of these for each stream +function CorkedRequest(state) { + var _this = this; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticInputEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); + this.next = null; + this.entry = null; + this.finish = function () { + onCorkedFinish(_this, state); + }; } +/* </replacement> */ -SyntheticEvent.augmentClass(SyntheticInputEvent, InputEventInterface); +/*<replacement>*/ +var asyncWrite = !process.browser && ['v0.10', 'v0.9.'].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : processNextTick; +/*</replacement>*/ -module.exports = SyntheticInputEvent; +/*<replacement>*/ +var Duplex; +/*</replacement>*/ -/***/ }), -/* 142 */ -/***/ (function(module, exports, __webpack_require__) { +Writable.WritableState = WritableState; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ +/*<replacement>*/ +var internalUtil = { + deprecate: __webpack_require__(370) +}; +/*</replacement>*/ +/*<replacement>*/ +var Stream = __webpack_require__(162); +/*</replacement>*/ -var EventPluginHub = __webpack_require__(32); -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); -var SyntheticEvent = __webpack_require__(16); +/*<replacement>*/ +var Buffer = __webpack_require__(7).Buffer; +var OurUint8Array = global.Uint8Array || function () {}; +function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk); +} +function _isUint8Array(obj) { + return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; +} +/*</replacement>*/ -var inputValueTracking = __webpack_require__(87); -var getEventTarget = __webpack_require__(52); -var isEventSupported = __webpack_require__(53); -var isTextInputElement = __webpack_require__(88); +var destroyImpl = __webpack_require__(163); -var eventTypes = { - change: { - phasedRegistrationNames: { - bubbled: 'onChange', - captured: 'onChangeCapture' - }, - dependencies: ['topBlur', 'topChange', 'topClick', 'topFocus', 'topInput', 'topKeyDown', 'topKeyUp', 'topSelectionChange'] +util.inherits(Writable, Stream); + +function nop() {} + +function WritableState(options, stream) { + Duplex = Duplex || __webpack_require__(34); + + options = options || {}; + + // object stream flag to indicate whether or not this stream + // contains buffers or objects. + this.objectMode = !!options.objectMode; + + if (stream instanceof Duplex) this.objectMode = this.objectMode || !!options.writableObjectMode; + + // the point at which write() starts returning false + // Note: 0 is a valid value, means that we always return false if + // the entire buffer is not flushed immediately on write() + var hwm = options.highWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; + this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm; + + // cast to ints. + this.highWaterMark = Math.floor(this.highWaterMark); + + // if _final has been called + this.finalCalled = false; + + // drain event flag. + this.needDrain = false; + // at the start of calling end() + this.ending = false; + // when end() has been called, and returned + this.ended = false; + // when 'finish' is emitted + this.finished = false; + + // has it been destroyed + this.destroyed = false; + + // should we decode strings into buffers before passing to _write? + // this is here so that some node-core streams can optimize string + // handling at a lower level. + var noDecode = options.decodeStrings === false; + this.decodeStrings = !noDecode; + + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; + + // not an actual buffer we keep track of, but a measurement + // of how much we're waiting to get pushed to some underlying + // socket or file. + this.length = 0; + + // a flag to see when we're in the middle of a write. + this.writing = false; + + // when true all writes will be buffered until .uncork() call + this.corked = 0; + + // a flag to be able to tell if the onwrite cb is called immediately, + // or on a later tick. We set this to true at first, because any + // actions that shouldn't happen until "later" should generally also + // not happen before the first write call. + this.sync = true; + + // a flag to know if we're processing previously buffered items, which + // may call the _write() callback in the same tick, so that we don't + // end up in an overlapped onwrite situation. + this.bufferProcessing = false; + + // the callback that's passed to _write(chunk,cb) + this.onwrite = function (er) { + onwrite(stream, er); + }; + + // the callback that the user supplies to write(chunk,encoding,cb) + this.writecb = null; + + // the amount that is being written when _write is called. + this.writelen = 0; + + this.bufferedRequest = null; + this.lastBufferedRequest = null; + + // number of pending user-supplied write callbacks + // this must be 0 before 'finish' can be emitted + this.pendingcb = 0; + + // emit prefinish if the only thing we're waiting for is _write cbs + // This is relevant for synchronous Transform streams + this.prefinished = false; + + // True if the error was already emitted and should not be thrown again + this.errorEmitted = false; + + // count buffered requests + this.bufferedRequestCount = 0; + + // allocate the first CorkedRequest, there is always + // one allocated and free to use, and we maintain at most two + this.corkedRequestsFree = new CorkedRequest(this); +} + +WritableState.prototype.getBuffer = function getBuffer() { + var current = this.bufferedRequest; + var out = []; + while (current) { + out.push(current); + current = current.next; } + return out; }; -function createAndAccumulateChangeEvent(inst, nativeEvent, target) { - var event = SyntheticEvent.getPooled(eventTypes.change, inst, nativeEvent, target); - event.type = 'change'; - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; -} -/** - * For IE shims - */ -var activeElement = null; -var activeElementInst = null; +(function () { + try { + Object.defineProperty(WritableState.prototype, 'buffer', { + get: internalUtil.deprecate(function () { + return this.getBuffer(); + }, '_writableState.buffer is deprecated. Use _writableState.getBuffer ' + 'instead.', 'DEP0003') + }); + } catch (_) {} +})(); -/** - * SECTION: handle `change` event - */ -function shouldUseChangeEvent(elem) { - var nodeName = elem.nodeName && elem.nodeName.toLowerCase(); - return nodeName === 'select' || nodeName === 'input' && elem.type === 'file'; -} +// Test _writableState for inheritance to account for Duplex streams, +// whose prototype chain only points to Readable. +var realHasInstance; +if (typeof Symbol === 'function' && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] === 'function') { + realHasInstance = Function.prototype[Symbol.hasInstance]; + Object.defineProperty(Writable, Symbol.hasInstance, { + value: function (object) { + if (realHasInstance.call(this, object)) return true; -var doesChangeEventBubble = false; -if (ExecutionEnvironment.canUseDOM) { - // See `handleChange` comment below - doesChangeEventBubble = isEventSupported('change') && (!document.documentMode || document.documentMode > 8); + return object && object._writableState instanceof WritableState; + } + }); +} else { + realHasInstance = function (object) { + return object instanceof this; + }; } -function manualDispatchChangeEvent(nativeEvent) { - var event = createAndAccumulateChangeEvent(activeElementInst, nativeEvent, getEventTarget(nativeEvent)); +function Writable(options) { + Duplex = Duplex || __webpack_require__(34); - // If change and propertychange bubbled, we'd just bind to it like all the - // other events and have it go through ReactBrowserEventEmitter. Since it - // doesn't, we manually listen for the events and so we have to enqueue and - // process the abstract event manually. - // - // Batching is necessary here in order to ensure that all event handlers run - // before the next rerender (including event handlers attached to ancestor - // elements instead of directly on the input). Without this, controlled - // components don't work properly in conjunction with event bubbling because - // the component is rerendered and the value reverted before all the event - // handlers can run. See https://github.com/facebook/react/issues/708. - ReactUpdates.batchedUpdates(runEventInBatch, event); -} + // Writable ctor is applied to Duplexes, too. + // `realHasInstance` is necessary because using plain `instanceof` + // would return false, as no `_writableState` property is attached. -function runEventInBatch(event) { - EventPluginHub.enqueueEvents(event); - EventPluginHub.processEventQueue(false); + // Trying to use the custom `instanceof` for Writable here will also break the + // Node.js LazyTransform implementation, which has a non-trivial getter for + // `_writableState` that would lead to infinite recursion. + if (!realHasInstance.call(Writable, this) && !(this instanceof Duplex)) { + return new Writable(options); + } + + this._writableState = new WritableState(options, this); + + // legacy. + this.writable = true; + + if (options) { + if (typeof options.write === 'function') this._write = options.write; + + if (typeof options.writev === 'function') this._writev = options.writev; + + if (typeof options.destroy === 'function') this._destroy = options.destroy; + + if (typeof options.final === 'function') this._final = options.final; + } + + Stream.call(this); } -function startWatchingForChangeEventIE8(target, targetInst) { - activeElement = target; - activeElementInst = targetInst; - activeElement.attachEvent('onchange', manualDispatchChangeEvent); +// Otherwise people can pipe Writable streams, which is just wrong. +Writable.prototype.pipe = function () { + this.emit('error', new Error('Cannot pipe, not readable')); +}; + +function writeAfterEnd(stream, cb) { + var er = new Error('write after end'); + // TODO: defer error events consistently everywhere, not just the cb + stream.emit('error', er); + processNextTick(cb, er); } -function stopWatchingForChangeEventIE8() { - if (!activeElement) { - return; +// Checks that a user-supplied chunk is valid, especially for the particular +// mode the stream is in. Currently this means that `null` is never accepted +// and undefined/non-string values are only allowed in object mode. +function validChunk(stream, state, chunk, cb) { + var valid = true; + var er = false; + + if (chunk === null) { + er = new TypeError('May not write null values to stream'); + } else if (typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); } - activeElement.detachEvent('onchange', manualDispatchChangeEvent); - activeElement = null; - activeElementInst = null; + if (er) { + stream.emit('error', er); + processNextTick(cb, er); + valid = false; + } + return valid; } -function getInstIfValueChanged(targetInst, nativeEvent) { - var updated = inputValueTracking.updateValueIfChanged(targetInst); - var simulated = nativeEvent.simulated === true && ChangeEventPlugin._allowSimulatedPassThrough; +Writable.prototype.write = function (chunk, encoding, cb) { + var state = this._writableState; + var ret = false; + var isBuf = _isUint8Array(chunk) && !state.objectMode; - if (updated || simulated) { - return targetInst; + if (isBuf && !Buffer.isBuffer(chunk)) { + chunk = _uint8ArrayToBuffer(chunk); } -} -function getTargetInstForChangeEvent(topLevelType, targetInst) { - if (topLevelType === 'topChange') { - return targetInst; + if (typeof encoding === 'function') { + cb = encoding; + encoding = null; } -} -function handleEventsForChangeEventIE8(topLevelType, target, targetInst) { - if (topLevelType === 'topFocus') { - // stopWatching() should be a noop here but we call it just in case we - // missed a blur event somehow. - stopWatchingForChangeEventIE8(); - startWatchingForChangeEventIE8(target, targetInst); - } else if (topLevelType === 'topBlur') { - stopWatchingForChangeEventIE8(); + if (isBuf) encoding = 'buffer';else if (!encoding) encoding = state.defaultEncoding; + + if (typeof cb !== 'function') cb = nop; + + if (state.ended) writeAfterEnd(this, cb);else if (isBuf || validChunk(this, state, chunk, cb)) { + state.pendingcb++; + ret = writeOrBuffer(this, state, isBuf, chunk, encoding, cb); + } + + return ret; +}; + +Writable.prototype.cork = function () { + var state = this._writableState; + + state.corked++; +}; + +Writable.prototype.uncork = function () { + var state = this._writableState; + + if (state.corked) { + state.corked--; + + if (!state.writing && !state.corked && !state.finished && !state.bufferProcessing && state.bufferedRequest) clearBuffer(this, state); + } +}; + +Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) { + // node::ParseEncoding() requires lower case. + if (typeof encoding === 'string') encoding = encoding.toLowerCase(); + if (!(['hex', 'utf8', 'utf-8', 'ascii', 'binary', 'base64', 'ucs2', 'ucs-2', 'utf16le', 'utf-16le', 'raw'].indexOf((encoding + '').toLowerCase()) > -1)) throw new TypeError('Unknown encoding: ' + encoding); + this._writableState.defaultEncoding = encoding; + return this; +}; + +function decodeChunk(state, chunk, encoding) { + if (!state.objectMode && state.decodeStrings !== false && typeof chunk === 'string') { + chunk = Buffer.from(chunk, encoding); } + return chunk; } -/** - * SECTION: handle `input` event - */ -var isInputEventSupported = false; -if (ExecutionEnvironment.canUseDOM) { - // IE9 claims to support the input event but fails to trigger it when - // deleting text, so we ignore its input events. +// if we're already writing something, then just put this +// in the queue, and wait our turn. Otherwise, call _write +// If we return false, then we need a drain event, so set that flag. +function writeOrBuffer(stream, state, isBuf, chunk, encoding, cb) { + if (!isBuf) { + var newChunk = decodeChunk(state, chunk, encoding); + if (chunk !== newChunk) { + isBuf = true; + encoding = 'buffer'; + chunk = newChunk; + } + } + var len = state.objectMode ? 1 : chunk.length; + + state.length += len; + + var ret = state.length < state.highWaterMark; + // we must ensure that previous needDrain will not be reset to false. + if (!ret) state.needDrain = true; + + if (state.writing || state.corked) { + var last = state.lastBufferedRequest; + state.lastBufferedRequest = { + chunk: chunk, + encoding: encoding, + isBuf: isBuf, + callback: cb, + next: null + }; + if (last) { + last.next = state.lastBufferedRequest; + } else { + state.bufferedRequest = state.lastBufferedRequest; + } + state.bufferedRequestCount += 1; + } else { + doWrite(stream, state, false, len, chunk, encoding, cb); + } - isInputEventSupported = isEventSupported('input') && (!('documentMode' in document) || document.documentMode > 9); + return ret; } -/** - * (For IE <=9) Starts tracking propertychange events on the passed-in element - * and override the value property so that we can distinguish user events from - * value changes in JS. - */ -function startWatchingForValueChange(target, targetInst) { - activeElement = target; - activeElementInst = targetInst; - activeElement.attachEvent('onpropertychange', handlePropertyChange); +function doWrite(stream, state, writev, len, chunk, encoding, cb) { + state.writelen = len; + state.writecb = cb; + state.writing = true; + state.sync = true; + if (writev) stream._writev(chunk, state.onwrite);else stream._write(chunk, encoding, state.onwrite); + state.sync = false; } -/** - * (For IE <=9) Removes the event listeners from the currently-tracked element, - * if any exists. - */ -function stopWatchingForValueChange() { - if (!activeElement) { - return; +function onwriteError(stream, state, sync, er, cb) { + --state.pendingcb; + + if (sync) { + // defer the callback if we are being called synchronously + // to avoid piling up things on the stack + processNextTick(cb, er); + // this can emit finish, and it will always happen + // after error + processNextTick(finishMaybe, stream, state); + stream._writableState.errorEmitted = true; + stream.emit('error', er); + } else { + // the caller expect this to happen before if + // it is async + cb(er); + stream._writableState.errorEmitted = true; + stream.emit('error', er); + // this can emit finish, but finish must + // always follow error + finishMaybe(stream, state); } - activeElement.detachEvent('onpropertychange', handlePropertyChange); +} - activeElement = null; - activeElementInst = null; +function onwriteStateUpdate(state) { + state.writing = false; + state.writecb = null; + state.length -= state.writelen; + state.writelen = 0; } -/** - * (For IE <=9) Handles a propertychange event, sending a `change` event if - * the value of the active element has changed. - */ -function handlePropertyChange(nativeEvent) { - if (nativeEvent.propertyName !== 'value') { - return; - } - if (getInstIfValueChanged(activeElementInst, nativeEvent)) { - manualDispatchChangeEvent(nativeEvent); +function onwrite(stream, er) { + var state = stream._writableState; + var sync = state.sync; + var cb = state.writecb; + + onwriteStateUpdate(state); + + if (er) onwriteError(stream, state, sync, er, cb);else { + // Check if we're actually ready to finish, but don't emit yet + var finished = needFinish(state); + + if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) { + clearBuffer(stream, state); + } + + if (sync) { + /*<replacement>*/ + asyncWrite(afterWrite, stream, state, finished, cb); + /*</replacement>*/ + } else { + afterWrite(stream, state, finished, cb); + } } } -function handleEventsForInputEventPolyfill(topLevelType, target, targetInst) { - if (topLevelType === 'topFocus') { - // In IE8, we can capture almost all .value changes by adding a - // propertychange handler and looking for events with propertyName - // equal to 'value' - // In IE9, propertychange fires for most input events but is buggy and - // doesn't fire when text is deleted, but conveniently, selectionchange - // appears to fire in all of the remaining cases so we catch those and - // forward the event if the value has changed - // In either case, we don't want to call the event handler if the value - // is changed from JS so we redefine a setter for `.value` that updates - // our activeElementValue variable, allowing us to ignore those changes - // - // stopWatching() should be a noop here but we call it just in case we - // missed a blur event somehow. - stopWatchingForValueChange(); - startWatchingForValueChange(target, targetInst); - } else if (topLevelType === 'topBlur') { - stopWatchingForValueChange(); +function afterWrite(stream, state, finished, cb) { + if (!finished) onwriteDrain(stream, state); + state.pendingcb--; + cb(); + finishMaybe(stream, state); +} + +// Must force callback to be called on nextTick, so that we don't +// emit 'drain' before the write() consumer gets the 'false' return +// value, and has a chance to attach a 'drain' listener. +function onwriteDrain(stream, state) { + if (state.length === 0 && state.needDrain) { + state.needDrain = false; + stream.emit('drain'); } } -// For IE8 and IE9. -function getTargetInstForInputEventPolyfill(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topSelectionChange' || topLevelType === 'topKeyUp' || topLevelType === 'topKeyDown') { - // On the selectionchange event, the target is just document which isn't - // helpful for us so just check activeElement instead. - // - // 99% of the time, keydown and keyup aren't necessary. IE8 fails to fire - // propertychange on the first input event after setting `value` from a - // script and fires only keydown, keypress, keyup. Catching keyup usually - // gets it and catching keydown lets us fire an event for the first - // keystroke if user does a key repeat (it'll be a little delayed: right - // before the second keystroke). Other input methods (e.g., paste) seem to - // fire selectionchange normally. - return getInstIfValueChanged(activeElementInst, nativeEvent); +// if there's something in the buffer waiting, then process it +function clearBuffer(stream, state) { + state.bufferProcessing = true; + var entry = state.bufferedRequest; + + if (stream._writev && entry && entry.next) { + // Fast case, write everything using _writev() + var l = state.bufferedRequestCount; + var buffer = new Array(l); + var holder = state.corkedRequestsFree; + holder.entry = entry; + + var count = 0; + var allBuffers = true; + while (entry) { + buffer[count] = entry; + if (!entry.isBuf) allBuffers = false; + entry = entry.next; + count += 1; + } + buffer.allBuffers = allBuffers; + + doWrite(stream, state, true, state.length, buffer, '', holder.finish); + + // doWrite is almost always async, defer these to save a bit of time + // as the hot path ends with doWrite + state.pendingcb++; + state.lastBufferedRequest = null; + if (holder.next) { + state.corkedRequestsFree = holder.next; + holder.next = null; + } else { + state.corkedRequestsFree = new CorkedRequest(state); + } + } else { + // Slow case, write chunks one-by-one + while (entry) { + var chunk = entry.chunk; + var encoding = entry.encoding; + var cb = entry.callback; + var len = state.objectMode ? 1 : chunk.length; + + doWrite(stream, state, false, len, chunk, encoding, cb); + entry = entry.next; + // if we didn't call the onwrite immediately, then + // it means that we need to wait until it does. + // also, that means that the chunk and cb are currently + // being processed, so move the buffer counter past them. + if (state.writing) { + break; + } + } + + if (entry === null) state.lastBufferedRequest = null; } + + state.bufferedRequestCount = 0; + state.bufferedRequest = entry; + state.bufferProcessing = false; } -/** - * SECTION: handle `click` event - */ -function shouldUseClickEvent(elem) { - // Use the `click` event to detect changes to checkbox and radio inputs. - // This approach works across all browsers, whereas `change` does not fire - // until `blur` in IE8. - var nodeName = elem.nodeName; - return nodeName && nodeName.toLowerCase() === 'input' && (elem.type === 'checkbox' || elem.type === 'radio'); +Writable.prototype._write = function (chunk, encoding, cb) { + cb(new Error('_write() is not implemented')); +}; + +Writable.prototype._writev = null; + +Writable.prototype.end = function (chunk, encoding, cb) { + var state = this._writableState; + + if (typeof chunk === 'function') { + cb = chunk; + chunk = null; + encoding = null; + } else if (typeof encoding === 'function') { + cb = encoding; + encoding = null; + } + + if (chunk !== null && chunk !== undefined) this.write(chunk, encoding); + + // .end() fully uncorks + if (state.corked) { + state.corked = 1; + this.uncork(); + } + + // ignore unnecessary end() calls. + if (!state.ending && !state.finished) endWritable(this, state, cb); +}; + +function needFinish(state) { + return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing; +} +function callFinal(stream, state) { + stream._final(function (err) { + state.pendingcb--; + if (err) { + stream.emit('error', err); + } + state.prefinished = true; + stream.emit('prefinish'); + finishMaybe(stream, state); + }); +} +function prefinish(stream, state) { + if (!state.prefinished && !state.finalCalled) { + if (typeof stream._final === 'function') { + state.pendingcb++; + state.finalCalled = true; + processNextTick(callFinal, stream, state); + } else { + state.prefinished = true; + stream.emit('prefinish'); + } + } } -function getTargetInstForClickEvent(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topClick') { - return getInstIfValueChanged(targetInst, nativeEvent); +function finishMaybe(stream, state) { + var need = needFinish(state); + if (need) { + prefinish(stream, state); + if (state.pendingcb === 0) { + state.finished = true; + stream.emit('finish'); + } } + return need; } -function getTargetInstForInputOrChangeEvent(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topInput' || topLevelType === 'topChange') { - return getInstIfValueChanged(targetInst, nativeEvent); +function endWritable(stream, state, cb) { + state.ending = true; + finishMaybe(stream, state); + if (cb) { + if (state.finished) processNextTick(cb);else stream.once('finish', cb); } + state.ended = true; + stream.writable = false; } -function handleControlledInputBlur(inst, node) { - // TODO: In IE, inst is occasionally null. Why? - if (inst == null) { - return; +function onCorkedFinish(corkReq, state, err) { + var entry = corkReq.entry; + corkReq.entry = null; + while (entry) { + var cb = entry.callback; + state.pendingcb--; + cb(err); + entry = entry.next; + } + if (state.corkedRequestsFree) { + state.corkedRequestsFree.next = corkReq; + } else { + state.corkedRequestsFree = corkReq; } +} - // Fiber and ReactDOM keep wrapper state in separate places - var state = inst._wrapperState || node._wrapperState; +Object.defineProperty(Writable.prototype, 'destroyed', { + get: function () { + if (this._writableState === undefined) { + return false; + } + return this._writableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (!this._writableState) { + return; + } - if (!state || !state.controlled || node.type !== 'number') { - return; + // backward compatibility, the user is explicitly + // managing destroyed + this._writableState.destroyed = value; } +}); - // If controlled, assign the value attribute to the current value on blur - var value = '' + node.value; - if (node.getAttribute('value') !== value) { - node.setAttribute('value', value); +Writable.prototype.destroy = destroyImpl.destroy; +Writable.prototype._undestroy = destroyImpl.undestroy; +Writable.prototype._destroy = function (err, cb) { + this.end(); + cb(err); +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0), __webpack_require__(164).setImmediate, __webpack_require__(24))) + +/***/ }), +/* 102 */ +/***/ (function(module, exports, __webpack_require__) { + +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +var Buffer = __webpack_require__(1).Buffer; + +var isBufferEncoding = Buffer.isEncoding + || function(encoding) { + switch (encoding && encoding.toLowerCase()) { + case 'hex': case 'utf8': case 'utf-8': case 'ascii': case 'binary': case 'base64': case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': case 'raw': return true; + default: return false; + } + } + + +function assertEncoding(encoding) { + if (encoding && !isBufferEncoding(encoding)) { + throw new Error('Unknown encoding: ' + encoding); } } -/** - * This plugin creates an `onChange` event that normalizes change events - * across form elements. This event fires at a time when it's possible to - * change the element's value without seeing a flicker. - * - * Supported elements are: - * - input (see `isTextInputElement`) - * - textarea - * - select - */ -var ChangeEventPlugin = { - eventTypes: eventTypes, +// StringDecoder provides an interface for efficiently splitting a series of +// buffers into a series of JS strings without breaking apart multi-byte +// characters. CESU-8 is handled as part of the UTF-8 encoding. +// +// @TODO Handling all encodings inside a single object makes it very difficult +// to reason about this code, so it should be split up in the future. +// @TODO There should be a utf8-strict encoding that rejects invalid UTF-8 code +// points as used by CESU-8. +var StringDecoder = exports.StringDecoder = function(encoding) { + this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, ''); + assertEncoding(encoding); + switch (this.encoding) { + case 'utf8': + // CESU-8 represents each of Surrogate Pair by 3-bytes + this.surrogateSize = 3; + break; + case 'ucs2': + case 'utf16le': + // UTF-16 represents each of Surrogate Pair by 2-bytes + this.surrogateSize = 2; + this.detectIncompleteChar = utf16DetectIncompleteChar; + break; + case 'base64': + // Base-64 stores 3 bytes in 4 chars, and pads the remainder. + this.surrogateSize = 3; + this.detectIncompleteChar = base64DetectIncompleteChar; + break; + default: + this.write = passThroughWrite; + return; + } - _allowSimulatedPassThrough: true, - _isInputEventSupported: isInputEventSupported, + // Enough space to store all bytes of a single character. UTF-8 needs 4 + // bytes, but CESU-8 may require up to 6 (3 bytes per surrogate). + this.charBuffer = new Buffer(6); + // Number of bytes received for the current incomplete multi-byte character. + this.charReceived = 0; + // Number of bytes expected for the current incomplete multi-byte character. + this.charLength = 0; +}; - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; - var getTargetInstFunc, handleEventFunc; - if (shouldUseChangeEvent(targetNode)) { - if (doesChangeEventBubble) { - getTargetInstFunc = getTargetInstForChangeEvent; - } else { - handleEventFunc = handleEventsForChangeEventIE8; - } - } else if (isTextInputElement(targetNode)) { - if (isInputEventSupported) { - getTargetInstFunc = getTargetInstForInputOrChangeEvent; - } else { - getTargetInstFunc = getTargetInstForInputEventPolyfill; - handleEventFunc = handleEventsForInputEventPolyfill; - } - } else if (shouldUseClickEvent(targetNode)) { - getTargetInstFunc = getTargetInstForClickEvent; +// write decodes the given buffer and returns it as JS string that is +// guaranteed to not contain any partial multi-byte characters. Any partial +// character found at the end of the buffer is buffered up, and will be +// returned when calling write again with the remaining bytes. +// +// Note: Converting a Buffer containing an orphan surrogate to a String +// currently works, but converting a String to a Buffer (via `new Buffer`, or +// Buffer#write) will replace incomplete surrogates with the unicode +// replacement character. See https://codereview.chromium.org/121173009/ . +StringDecoder.prototype.write = function(buffer) { + var charStr = ''; + // if our last write ended with an incomplete multibyte character + while (this.charLength) { + // determine how many remaining bytes this buffer has to offer for this char + var available = (buffer.length >= this.charLength - this.charReceived) ? + this.charLength - this.charReceived : + buffer.length; + + // add the new bytes to the char buffer + buffer.copy(this.charBuffer, this.charReceived, 0, available); + this.charReceived += available; + + if (this.charReceived < this.charLength) { + // still not enough chars in this buffer? wait for more ... + return ''; } - if (getTargetInstFunc) { - var inst = getTargetInstFunc(topLevelType, targetInst, nativeEvent); - if (inst) { - var event = createAndAccumulateChangeEvent(inst, nativeEvent, nativeEventTarget); - return event; - } + // remove bytes belonging to the current character from the buffer + buffer = buffer.slice(available, buffer.length); + + // get the character that was split + charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding); + + // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character + var charCode = charStr.charCodeAt(charStr.length - 1); + if (charCode >= 0xD800 && charCode <= 0xDBFF) { + this.charLength += this.surrogateSize; + charStr = ''; + continue; } + this.charReceived = this.charLength = 0; - if (handleEventFunc) { - handleEventFunc(topLevelType, targetNode, targetInst); + // if there are no more bytes in this buffer, just emit our char + if (buffer.length === 0) { + return charStr; } + break; + } - // When blurring, set the value attribute for number inputs - if (topLevelType === 'topBlur') { - handleControlledInputBlur(targetInst, targetNode); + // determine and set charLength / charReceived + this.detectIncompleteChar(buffer); + + var end = buffer.length; + if (this.charLength) { + // buffer the incomplete character bytes we got + buffer.copy(this.charBuffer, 0, buffer.length - this.charReceived, end); + end -= this.charReceived; + } + + charStr += buffer.toString(this.encoding, 0, end); + + var end = charStr.length - 1; + var charCode = charStr.charCodeAt(end); + // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character + if (charCode >= 0xD800 && charCode <= 0xDBFF) { + var size = this.surrogateSize; + this.charLength += size; + this.charReceived += size; + this.charBuffer.copy(this.charBuffer, size, 0, size); + buffer.copy(this.charBuffer, 0, 0, size); + return charStr.substring(0, end); + } + + // or just emit the charStr + return charStr; +}; + +// detectIncompleteChar determines if there is an incomplete UTF-8 character at +// the end of the given buffer. If so, it sets this.charLength to the byte +// length that character, and sets this.charReceived to the number of bytes +// that are available for this character. +StringDecoder.prototype.detectIncompleteChar = function(buffer) { + // determine how many bytes we have to check at the end of this buffer + var i = (buffer.length >= 3) ? 3 : buffer.length; + + // Figure out if one of the last i bytes of our buffer announces an + // incomplete char. + for (; i > 0; i--) { + var c = buffer[buffer.length - i]; + + // See http://en.wikipedia.org/wiki/UTF-8#Description + + // 110XXXXX + if (i == 1 && c >> 5 == 0x06) { + this.charLength = 2; + break; + } + + // 1110XXXX + if (i <= 2 && c >> 4 == 0x0E) { + this.charLength = 3; + break; + } + + // 11110XXX + if (i <= 3 && c >> 3 == 0x1E) { + this.charLength = 4; + break; } } + this.charReceived = i; }; -module.exports = ChangeEventPlugin; +StringDecoder.prototype.end = function(buffer) { + var res = ''; + if (buffer && buffer.length) + res = this.write(buffer); + + if (this.charReceived) { + var cr = this.charReceived; + var buf = this.charBuffer; + var enc = this.encoding; + res += buf.slice(0, cr).toString(enc); + } + + return res; +}; + +function passThroughWrite(buffer) { + return buffer.toString(this.encoding); +} + +function utf16DetectIncompleteChar(buffer) { + this.charReceived = buffer.length % 2; + this.charLength = this.charReceived ? 2 : 0; +} + +function base64DetectIncompleteChar(buffer) { + this.charReceived = buffer.length % 3; + this.charLength = this.charReceived ? 3 : 0; +} + /***/ }), -/* 143 */ +/* 103 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var exports = module.exports = function SHA (algorithm) { + algorithm = algorithm.toLowerCase() + var Algorithm = exports[algorithm] + if (!Algorithm) throw new Error(algorithm + ' is not supported (we accept pull requests)') + return new Algorithm() +} -var ReactOwner = __webpack_require__(144); +exports.sha = __webpack_require__(376) +exports.sha1 = __webpack_require__(377) +exports.sha224 = __webpack_require__(378) +exports.sha256 = __webpack_require__(166) +exports.sha384 = __webpack_require__(379) +exports.sha512 = __webpack_require__(167) -var ReactRef = {}; -function attachRef(ref, component, owner) { - if (typeof ref === 'function') { - ref(component.getPublicInstance()); - } else { - // Legacy ref - ReactOwner.addComponentAsRefTo(component, ref, owner); - } +/***/ }), +/* 104 */ +/***/ (function(module, exports, __webpack_require__) { + +// Reference https://github.com/bitcoin/bips/blob/master/bip-0066.mediawiki +// Format: 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S] +// NOTE: SIGHASH byte ignored AND restricted, truncate before use + +var Buffer = __webpack_require__(7).Buffer + +function check (buffer) { + if (buffer.length < 8) return false + if (buffer.length > 72) return false + if (buffer[0] !== 0x30) return false + if (buffer[1] !== buffer.length - 2) return false + if (buffer[2] !== 0x02) return false + + var lenR = buffer[3] + if (lenR === 0) return false + if (5 + lenR >= buffer.length) return false + if (buffer[4 + lenR] !== 0x02) return false + + var lenS = buffer[5 + lenR] + if (lenS === 0) return false + if ((6 + lenR + lenS) !== buffer.length) return false + + if (buffer[4] & 0x80) return false + if (lenR > 1 && (buffer[4] === 0x00) && !(buffer[5] & 0x80)) return false + + if (buffer[lenR + 6] & 0x80) return false + if (lenS > 1 && (buffer[lenR + 6] === 0x00) && !(buffer[lenR + 7] & 0x80)) return false + return true } -function detachRef(ref, component, owner) { - if (typeof ref === 'function') { - ref(null); - } else { - // Legacy ref - ReactOwner.removeComponentAsRefFrom(component, ref, owner); +function decode (buffer) { + if (buffer.length < 8) throw new Error('DER sequence length is too short') + if (buffer.length > 72) throw new Error('DER sequence length is too long') + if (buffer[0] !== 0x30) throw new Error('Expected DER sequence') + if (buffer[1] !== buffer.length - 2) throw new Error('DER sequence length is invalid') + if (buffer[2] !== 0x02) throw new Error('Expected DER integer') + + var lenR = buffer[3] + if (lenR === 0) throw new Error('R length is zero') + if (5 + lenR >= buffer.length) throw new Error('R length is too long') + if (buffer[4 + lenR] !== 0x02) throw new Error('Expected DER integer (2)') + + var lenS = buffer[5 + lenR] + if (lenS === 0) throw new Error('S length is zero') + if ((6 + lenR + lenS) !== buffer.length) throw new Error('S length is invalid') + + if (buffer[4] & 0x80) throw new Error('R value is negative') + if (lenR > 1 && (buffer[4] === 0x00) && !(buffer[5] & 0x80)) throw new Error('R value excessively padded') + + if (buffer[lenR + 6] & 0x80) throw new Error('S value is negative') + if (lenS > 1 && (buffer[lenR + 6] === 0x00) && !(buffer[lenR + 7] & 0x80)) throw new Error('S value excessively padded') + + // non-BIP66 - extract R, S values + return { + r: buffer.slice(4, 4 + lenR), + s: buffer.slice(6 + lenR) } } -ReactRef.attachRefs = function (instance, element) { - if (element === null || typeof element !== 'object') { - return; - } - var ref = element.ref; - if (ref != null) { - attachRef(ref, instance, element._owner); - } -}; +/* + * Expects r and s to be positive DER integers. + * + * The DER format uses the most significant bit as a sign bit (& 0x80). + * If the significant bit is set AND the integer is positive, a 0x00 is prepended. + * + * Examples: + * + * 0 => 0x00 + * 1 => 0x01 + * -1 => 0xff + * 127 => 0x7f + * -127 => 0x81 + * 128 => 0x0080 + * -128 => 0x80 + * 255 => 0x00ff + * -255 => 0xff01 + * 16300 => 0x3fac + * -16300 => 0xc054 + * 62300 => 0x00f35c + * -62300 => 0xff0ca4 +*/ +function encode (r, s) { + var lenR = r.length + var lenS = s.length + if (lenR === 0) throw new Error('R length is zero') + if (lenS === 0) throw new Error('S length is zero') + if (lenR > 33) throw new Error('R length is too long') + if (lenS > 33) throw new Error('S length is too long') + if (r[0] & 0x80) throw new Error('R value is negative') + if (s[0] & 0x80) throw new Error('S value is negative') + if (lenR > 1 && (r[0] === 0x00) && !(r[1] & 0x80)) throw new Error('R value excessively padded') + if (lenS > 1 && (s[0] === 0x00) && !(s[1] & 0x80)) throw new Error('S value excessively padded') + + var signature = Buffer.allocUnsafe(6 + lenR + lenS) + + // 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S] + signature[0] = 0x30 + signature[1] = signature.length - 2 + signature[2] = 0x02 + signature[3] = r.length + r.copy(signature, 4) + signature[4 + lenR] = 0x02 + signature[5 + lenR] = s.length + s.copy(signature, 6 + lenR) + + return signature +} -ReactRef.shouldUpdateRefs = function (prevElement, nextElement) { - // If either the owner or a `ref` has changed, make sure the newest owner - // has stored a reference to `this`, and the previous owner (if different) - // has forgotten the reference to `this`. We use the element instead - // of the public this.props because the post processing cannot determine - // a ref. The ref conceptually lives on the element. +module.exports = { + check: check, + decode: decode, + encode: encode +} - // TODO: Should this even be possible? The owner cannot change because - // it's forbidden by shouldUpdateReactComponent. The ref can change - // if you swap the keys of but not the refs. Reconsider where this check - // is made. It probably belongs where the key checking and - // instantiateReactComponent is done. - var prevRef = null; - var prevOwner = null; - if (prevElement !== null && typeof prevElement === 'object') { - prevRef = prevElement.ref; - prevOwner = prevElement._owner; - } +/***/ }), +/* 105 */ +/***/ (function(module, exports, __webpack_require__) { - var nextRef = null; - var nextOwner = null; - if (nextElement !== null && typeof nextElement === 'object') { - nextRef = nextElement.ref; - nextOwner = nextElement._owner; - } +var hash = exports; - return prevRef !== nextRef || - // If owner changes but we have an unchanged function ref, don't update refs - typeof nextRef === 'string' && nextOwner !== prevOwner; -}; +hash.utils = __webpack_require__(25); +hash.common = __webpack_require__(50); +hash.sha = __webpack_require__(393); +hash.ripemd = __webpack_require__(397); +hash.hmac = __webpack_require__(398); -ReactRef.detachRefs = function (instance, element) { - if (element === null || typeof element !== 'object') { - return; - } - var ref = element.ref; - if (ref != null) { - detachRef(ref, instance, element._owner); - } -}; +// Proxy hash functions to the main object +hash.sha1 = hash.sha.sha1; +hash.sha256 = hash.sha.sha256; +hash.sha224 = hash.sha.sha224; +hash.sha384 = hash.sha.sha384; +hash.sha512 = hash.sha.sha512; +hash.ripemd160 = hash.ripemd.ripemd160; -module.exports = ReactRef; /***/ }), -/* 144 */ +/* 106 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +/* WEBPACK VAR INJECTION */(function(global) { +// compare and isBuffer taken from https://github.com/feross/buffer/blob/680e9e5e488f22aac27599a57dc844a6315928dd/index.js +// original notice: +/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> + * @license MIT + */ +function compare(a, b) { + if (a === b) { + return 0; + } -var _prodInvariant = __webpack_require__(3); + var x = a.length; + var y = b.length; -var invariant = __webpack_require__(1); + for (var i = 0, len = Math.min(x, y); i < len; ++i) { + if (a[i] !== b[i]) { + x = a[i]; + y = b[i]; + break; + } + } -/** - * @param {?object} object - * @return {boolean} True if `object` is a valid owner. - * @final - */ -function isValidOwner(object) { - return !!(object && typeof object.attachRef === 'function' && typeof object.detachRef === 'function'); + if (x < y) { + return -1; + } + if (y < x) { + return 1; + } + return 0; } - -/** - * ReactOwners are capable of storing references to owned components. - * - * All components are capable of //being// referenced by owner components, but - * only ReactOwner components are capable of //referencing// owned components. - * The named reference is known as a "ref". - * - * Refs are available when mounted and updated during reconciliation. - * - * var MyComponent = React.createClass({ - * render: function() { - * return ( - * <div onClick={this.handleClick}> - * <CustomComponent ref="custom" /> - * </div> - * ); - * }, - * handleClick: function() { - * this.refs.custom.handleClick(); - * }, - * componentDidMount: function() { - * this.refs.custom.initialize(); - * } - * }); - * - * Refs should rarely be used. When refs are used, they should only be done to - * control data that is not handled by React's data flow. - * - * @class ReactOwner - */ -var ReactOwner = { - /** - * Adds a component by ref to an owner component. - * - * @param {ReactComponent} component Component to reference. - * @param {string} ref Name by which to refer to the component. - * @param {ReactOwner} owner Component on which to record the ref. - * @final - * @internal - */ - addComponentAsRefTo: function (component, ref, owner) { - !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('119') : void 0; - owner.attachRef(ref, component); - }, - - /** - * Removes a component by ref from an owner component. - * - * @param {ReactComponent} component Component to dereference. - * @param {string} ref Name of the ref to remove. - * @param {ReactOwner} owner Component on which the ref is recorded. - * @final - * @internal - */ - removeComponentAsRefFrom: function (component, ref, owner) { - !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'removeComponentAsRefFrom(...): Only a ReactOwner can have refs. You might be removing a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('120') : void 0; - var ownerPublicInstance = owner.getPublicInstance(); - // Check that `component`'s owner is still alive and that `component` is still the current ref - // because we do not want to detach the ref if another component stole it. - if (ownerPublicInstance && ownerPublicInstance.refs[ref] === component.getPublicInstance()) { - owner.detachRef(ref); - } +function isBuffer(b) { + if (global.Buffer && typeof global.Buffer.isBuffer === 'function') { + return global.Buffer.isBuffer(b); } -}; - -module.exports = ReactOwner; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 145 */ -/***/ (function(module, exports, __webpack_require__) { + return !!(b != null && b._isBuffer); +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +// based on node assert, original notice: + +// http://wiki.commonjs.org/wiki/Unit_Testing/1.0 +// +// THIS IS NOT TESTED NOR LIKELY TO WORK OUTSIDE V8! +// +// Originally from narwhal.js (http://narwhaljs.org) +// Copyright (c) 2009 Thomas Robinson <280north.com> +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the 'Software'), to +// deal in the Software without restriction, including without limitation the +// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +// sell copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN +// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +var util = __webpack_require__(409); +var hasOwn = Object.prototype.hasOwnProperty; +var pSlice = Array.prototype.slice; +var functionsHaveNames = (function () { + return function foo() {}.name === 'foo'; +}()); +function pToString (obj) { + return Object.prototype.toString.call(obj); +} +function isView(arrbuf) { + if (isBuffer(arrbuf)) { + return false; + } + if (typeof global.ArrayBuffer !== 'function') { + return false; + } + if (typeof ArrayBuffer.isView === 'function') { + return ArrayBuffer.isView(arrbuf); + } + if (!arrbuf) { + return false; + } + if (arrbuf instanceof DataView) { + return true; + } + if (arrbuf.buffer && arrbuf.buffer instanceof ArrayBuffer) { + return true; + } + return false; +} +// 1. The assert module provides functions that throw +// AssertionError's when particular conditions are not met. The +// assert module must conform to the following interface. +var assert = module.exports = ok; +// 2. The AssertionError is defined in assert. +// new assert.AssertionError({ message: message, +// actual: actual, +// expected: expected }) -var ReactInvalidSetStateWarningHook = __webpack_require__(146); -var ReactHostOperationHistoryHook = __webpack_require__(147); -var ReactComponentTreeHook = __webpack_require__(10); -var ExecutionEnvironment = __webpack_require__(8); +var regex = /\s*function\s+([^\(\s]*)\s*/; +// based on https://github.com/ljharb/function.prototype.name/blob/adeeeec8bfcc6068b187d7d9fb3d5bb1d3a30899/implementation.js +function getName(func) { + if (!util.isFunction(func)) { + return; + } + if (functionsHaveNames) { + return func.name; + } + var str = func.toString(); + var match = str.match(regex); + return match && match[1]; +} +assert.AssertionError = function AssertionError(options) { + this.name = 'AssertionError'; + this.actual = options.actual; + this.expected = options.expected; + this.operator = options.operator; + if (options.message) { + this.message = options.message; + this.generatedMessage = false; + } else { + this.message = getMessage(this); + this.generatedMessage = true; + } + var stackStartFunction = options.stackStartFunction || fail; + if (Error.captureStackTrace) { + Error.captureStackTrace(this, stackStartFunction); + } else { + // non v8 browsers so we can have a stacktrace + var err = new Error(); + if (err.stack) { + var out = err.stack; + + // try to strip useless frames + var fn_name = getName(stackStartFunction); + var idx = out.indexOf('\n' + fn_name); + if (idx >= 0) { + // once we have located the function frame + // we need to strip out everything before it (and its line) + var next_line = out.indexOf('\n', idx + 1); + out = out.substring(next_line + 1); + } -var performanceNow = __webpack_require__(148); -var warning = __webpack_require__(2); + this.stack = out; + } + } +}; -var hooks = []; -var didHookThrowForEvent = {}; +// assert.AssertionError instanceof Error +util.inherits(assert.AssertionError, Error); -function callHook(event, fn, context, arg1, arg2, arg3, arg4, arg5) { - try { - fn.call(context, arg1, arg2, arg3, arg4, arg5); - } catch (e) { - process.env.NODE_ENV !== 'production' ? warning(didHookThrowForEvent[event], 'Exception thrown by hook while handling %s: %s', event, e + '\n' + e.stack) : void 0; - didHookThrowForEvent[event] = true; +function truncate(s, n) { + if (typeof s === 'string') { + return s.length < n ? s : s.slice(0, n); + } else { + return s; } } - -function emitEvent(event, arg1, arg2, arg3, arg4, arg5) { - for (var i = 0; i < hooks.length; i++) { - var hook = hooks[i]; - var fn = hook[event]; - if (fn) { - callHook(event, fn, hook, arg1, arg2, arg3, arg4, arg5); - } +function inspect(something) { + if (functionsHaveNames || !util.isFunction(something)) { + return util.inspect(something); } + var rawname = getName(something); + var name = rawname ? ': ' + rawname : ''; + return '[Function' + name + ']'; +} +function getMessage(self) { + return truncate(inspect(self.actual), 128) + ' ' + + self.operator + ' ' + + truncate(inspect(self.expected), 128); } -var isProfiling = false; -var flushHistory = []; -var lifeCycleTimerStack = []; -var currentFlushNesting = 0; -var currentFlushMeasurements = []; -var currentFlushStartTime = 0; -var currentTimerDebugID = null; -var currentTimerStartTime = 0; -var currentTimerNestedFlushDuration = 0; -var currentTimerType = null; +// At present only the three keys mentioned above are used and +// understood by the spec. Implementations or sub modules can pass +// other keys to the AssertionError's constructor - they will be +// ignored. + +// 3. All of the following functions must throw an AssertionError +// when a corresponding condition is not met, with a message that +// may be undefined if not provided. All assertion methods provide +// both the actual and expected values to the assertion error for +// display purposes. + +function fail(actual, expected, message, operator, stackStartFunction) { + throw new assert.AssertionError({ + message: message, + actual: actual, + expected: expected, + operator: operator, + stackStartFunction: stackStartFunction + }); +} -var lifeCycleTimerHasWarned = false; +// EXTENSION! allows for well behaved errors defined elsewhere. +assert.fail = fail; -function clearHistory() { - ReactComponentTreeHook.purgeUnmountedComponents(); - ReactHostOperationHistoryHook.clearHistory(); -} +// 4. Pure assertion tests whether a value is truthy, as determined +// by !!guard. +// assert.ok(guard, message_opt); +// This statement is equivalent to assert.equal(true, !!guard, +// message_opt);. To test strictly for the value true, use +// assert.strictEqual(true, guard, message_opt);. -function getTreeSnapshot(registeredIDs) { - return registeredIDs.reduce(function (tree, id) { - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var parentID = ReactComponentTreeHook.getParentID(id); - tree[id] = { - displayName: ReactComponentTreeHook.getDisplayName(id), - text: ReactComponentTreeHook.getText(id), - updateCount: ReactComponentTreeHook.getUpdateCount(id), - childIDs: ReactComponentTreeHook.getChildIDs(id), - // Text nodes don't have owners but this is close enough. - ownerID: ownerID || parentID && ReactComponentTreeHook.getOwnerID(parentID) || 0, - parentID: parentID - }; - return tree; - }, {}); +function ok(value, message) { + if (!value) fail(value, true, message, '==', assert.ok); } +assert.ok = ok; -function resetMeasurements() { - var previousStartTime = currentFlushStartTime; - var previousMeasurements = currentFlushMeasurements; - var previousOperations = ReactHostOperationHistoryHook.getHistory(); +// 5. The equality assertion tests shallow, coercive equality with +// ==. +// assert.equal(actual, expected, message_opt); - if (currentFlushNesting === 0) { - currentFlushStartTime = 0; - currentFlushMeasurements = []; - clearHistory(); - return; - } +assert.equal = function equal(actual, expected, message) { + if (actual != expected) fail(actual, expected, message, '==', assert.equal); +}; - if (previousMeasurements.length || previousOperations.length) { - var registeredIDs = ReactComponentTreeHook.getRegisteredIDs(); - flushHistory.push({ - duration: performanceNow() - previousStartTime, - measurements: previousMeasurements || [], - operations: previousOperations || [], - treeSnapshot: getTreeSnapshot(registeredIDs) - }); +// 6. The non-equality assertion tests for whether two objects are not equal +// with != assert.notEqual(actual, expected, message_opt); + +assert.notEqual = function notEqual(actual, expected, message) { + if (actual == expected) { + fail(actual, expected, message, '!=', assert.notEqual); } +}; - clearHistory(); - currentFlushStartTime = performanceNow(); - currentFlushMeasurements = []; -} +// 7. The equivalence assertion tests a deep equality relation. +// assert.deepEqual(actual, expected, message_opt); -function checkDebugID(debugID) { - var allowRoot = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; +assert.deepEqual = function deepEqual(actual, expected, message) { + if (!_deepEqual(actual, expected, false)) { + fail(actual, expected, message, 'deepEqual', assert.deepEqual); + } +}; - if (allowRoot && debugID === 0) { - return; +assert.deepStrictEqual = function deepStrictEqual(actual, expected, message) { + if (!_deepEqual(actual, expected, true)) { + fail(actual, expected, message, 'deepStrictEqual', assert.deepStrictEqual); } - if (!debugID) { - process.env.NODE_ENV !== 'production' ? warning(false, 'ReactDebugTool: debugID may not be empty.') : void 0; +}; + +function _deepEqual(actual, expected, strict, memos) { + // 7.1. All identical values are equivalent, as determined by ===. + if (actual === expected) { + return true; + } else if (isBuffer(actual) && isBuffer(expected)) { + return compare(actual, expected) === 0; + + // 7.2. If the expected value is a Date object, the actual value is + // equivalent if it is also a Date object that refers to the same time. + } else if (util.isDate(actual) && util.isDate(expected)) { + return actual.getTime() === expected.getTime(); + + // 7.3 If the expected value is a RegExp object, the actual value is + // equivalent if it is also a RegExp object with the same source and + // properties (`global`, `multiline`, `lastIndex`, `ignoreCase`). + } else if (util.isRegExp(actual) && util.isRegExp(expected)) { + return actual.source === expected.source && + actual.global === expected.global && + actual.multiline === expected.multiline && + actual.lastIndex === expected.lastIndex && + actual.ignoreCase === expected.ignoreCase; + + // 7.4. Other pairs that do not both pass typeof value == 'object', + // equivalence is determined by ==. + } else if ((actual === null || typeof actual !== 'object') && + (expected === null || typeof expected !== 'object')) { + return strict ? actual === expected : actual == expected; + + // If both values are instances of typed arrays, wrap their underlying + // ArrayBuffers in a Buffer each to increase performance + // This optimization requires the arrays to have the same type as checked by + // Object.prototype.toString (aka pToString). Never perform binary + // comparisons for Float*Arrays, though, since e.g. +0 === -0 but their + // bit patterns are not identical. + } else if (isView(actual) && isView(expected) && + pToString(actual) === pToString(expected) && + !(actual instanceof Float32Array || + actual instanceof Float64Array)) { + return compare(new Uint8Array(actual.buffer), + new Uint8Array(expected.buffer)) === 0; + + // 7.5 For all other Object pairs, including Array objects, equivalence is + // determined by having the same number of owned properties (as verified + // with Object.prototype.hasOwnProperty.call), the same set of keys + // (although not necessarily the same order), equivalent values for every + // corresponding key, and an identical 'prototype' property. Note: this + // accounts for both named and indexed properties on Arrays. + } else if (isBuffer(actual) !== isBuffer(expected)) { + return false; + } else { + memos = memos || {actual: [], expected: []}; + + var actualIndex = memos.actual.indexOf(actual); + if (actualIndex !== -1) { + if (actualIndex === memos.expected.indexOf(expected)) { + return true; + } + } + + memos.actual.push(actual); + memos.expected.push(expected); + + return objEquiv(actual, expected, strict, memos); } } -function beginLifeCycleTimer(debugID, timerType) { - if (currentFlushNesting === 0) { - return; +function isArguments(object) { + return Object.prototype.toString.call(object) == '[object Arguments]'; +} + +function objEquiv(a, b, strict, actualVisitedObjects) { + if (a === null || a === undefined || b === null || b === undefined) + return false; + // if one is a primitive, the other must be same + if (util.isPrimitive(a) || util.isPrimitive(b)) + return a === b; + if (strict && Object.getPrototypeOf(a) !== Object.getPrototypeOf(b)) + return false; + var aIsArgs = isArguments(a); + var bIsArgs = isArguments(b); + if ((aIsArgs && !bIsArgs) || (!aIsArgs && bIsArgs)) + return false; + if (aIsArgs) { + a = pSlice.call(a); + b = pSlice.call(b); + return _deepEqual(a, b, strict); + } + var ka = objectKeys(a); + var kb = objectKeys(b); + var key, i; + // having the same number of owned properties (keys incorporates + // hasOwnProperty) + if (ka.length !== kb.length) + return false; + //the same set of keys (although not necessarily the same order), + ka.sort(); + kb.sort(); + //~~~cheap key test + for (i = ka.length - 1; i >= 0; i--) { + if (ka[i] !== kb[i]) + return false; } - if (currentTimerType && !lifeCycleTimerHasWarned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'Did not expect %s timer to start while %s timer is still in ' + 'progress for %s instance.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; - lifeCycleTimerHasWarned = true; + //equivalent values for every corresponding key, and + //~~~possibly expensive deep test + for (i = ka.length - 1; i >= 0; i--) { + key = ka[i]; + if (!_deepEqual(a[key], b[key], strict, actualVisitedObjects)) + return false; } - currentTimerStartTime = performanceNow(); - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = debugID; - currentTimerType = timerType; + return true; } -function endLifeCycleTimer(debugID, timerType) { - if (currentFlushNesting === 0) { - return; - } - if (currentTimerType !== timerType && !lifeCycleTimerHasWarned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'We did not expect %s timer to stop while %s timer is still in ' + 'progress for %s instance. Please report this as a bug in React.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; - lifeCycleTimerHasWarned = true; +// 8. The non-equivalence assertion tests for any deep inequality. +// assert.notDeepEqual(actual, expected, message_opt); + +assert.notDeepEqual = function notDeepEqual(actual, expected, message) { + if (_deepEqual(actual, expected, false)) { + fail(actual, expected, message, 'notDeepEqual', assert.notDeepEqual); } - if (isProfiling) { - currentFlushMeasurements.push({ - timerType: timerType, - instanceID: debugID, - duration: performanceNow() - currentTimerStartTime - currentTimerNestedFlushDuration - }); +}; + +assert.notDeepStrictEqual = notDeepStrictEqual; +function notDeepStrictEqual(actual, expected, message) { + if (_deepEqual(actual, expected, true)) { + fail(actual, expected, message, 'notDeepStrictEqual', notDeepStrictEqual); } - currentTimerStartTime = 0; - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = null; - currentTimerType = null; } -function pauseCurrentLifeCycleTimer() { - var currentTimer = { - startTime: currentTimerStartTime, - nestedFlushStartTime: performanceNow(), - debugID: currentTimerDebugID, - timerType: currentTimerType - }; - lifeCycleTimerStack.push(currentTimer); - currentTimerStartTime = 0; - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = null; - currentTimerType = null; -} -function resumeCurrentLifeCycleTimer() { - var _lifeCycleTimerStack$ = lifeCycleTimerStack.pop(), - startTime = _lifeCycleTimerStack$.startTime, - nestedFlushStartTime = _lifeCycleTimerStack$.nestedFlushStartTime, - debugID = _lifeCycleTimerStack$.debugID, - timerType = _lifeCycleTimerStack$.timerType; +// 9. The strict equality assertion tests strict equality, as determined by ===. +// assert.strictEqual(actual, expected, message_opt); - var nestedFlushDuration = performanceNow() - nestedFlushStartTime; - currentTimerStartTime = startTime; - currentTimerNestedFlushDuration += nestedFlushDuration; - currentTimerDebugID = debugID; - currentTimerType = timerType; -} +assert.strictEqual = function strictEqual(actual, expected, message) { + if (actual !== expected) { + fail(actual, expected, message, '===', assert.strictEqual); + } +}; -var lastMarkTimeStamp = 0; -var canUsePerformanceMeasure = typeof performance !== 'undefined' && typeof performance.mark === 'function' && typeof performance.clearMarks === 'function' && typeof performance.measure === 'function' && typeof performance.clearMeasures === 'function'; +// 10. The strict non-equality assertion tests for strict inequality, as +// determined by !==. assert.notStrictEqual(actual, expected, message_opt); -function shouldMark(debugID) { - if (!isProfiling || !canUsePerformanceMeasure) { - return false; +assert.notStrictEqual = function notStrictEqual(actual, expected, message) { + if (actual === expected) { + fail(actual, expected, message, '!==', assert.notStrictEqual); } - var element = ReactComponentTreeHook.getElement(debugID); - if (element == null || typeof element !== 'object') { +}; + +function expectedException(actual, expected) { + if (!actual || !expected) { return false; } - var isHostElement = typeof element.type === 'string'; - if (isHostElement) { + + if (Object.prototype.toString.call(expected) == '[object RegExp]') { + return expected.test(actual); + } + + try { + if (actual instanceof expected) { + return true; + } + } catch (e) { + // Ignore. The instanceof check doesn't work for arrow functions. + } + + if (Error.isPrototypeOf(expected)) { return false; } - return true; + + return expected.call({}, actual) === true; } -function markBegin(debugID, markType) { - if (!shouldMark(debugID)) { - return; +function _tryBlock(block) { + var error; + try { + block(); + } catch (e) { + error = e; } - - var markName = debugID + '::' + markType; - lastMarkTimeStamp = performanceNow(); - performance.mark(markName); + return error; } -function markEnd(debugID, markType) { - if (!shouldMark(debugID)) { - return; +function _throws(shouldThrow, block, expected, message) { + var actual; + + if (typeof block !== 'function') { + throw new TypeError('"block" argument must be a function'); } - var markName = debugID + '::' + markType; - var displayName = ReactComponentTreeHook.getDisplayName(debugID) || 'Unknown'; + if (typeof expected === 'string') { + message = expected; + expected = null; + } - // Chrome has an issue of dropping markers recorded too fast: - // https://bugs.chromium.org/p/chromium/issues/detail?id=640652 - // To work around this, we will not report very small measurements. - // I determined the magic number by tweaking it back and forth. - // 0.05ms was enough to prevent the issue, but I set it to 0.1ms to be safe. - // When the bug is fixed, we can `measure()` unconditionally if we want to. - var timeStamp = performanceNow(); - if (timeStamp - lastMarkTimeStamp > 0.1) { - var measurementName = displayName + ' [' + markType + ']'; - performance.measure(measurementName, markName); + actual = _tryBlock(block); + + message = (expected && expected.name ? ' (' + expected.name + ').' : '.') + + (message ? ' ' + message : '.'); + + if (shouldThrow && !actual) { + fail(actual, expected, 'Missing expected exception' + message); } - performance.clearMarks(markName); - if (measurementName) { - performance.clearMeasures(measurementName); + var userProvidedMessage = typeof message === 'string'; + var isUnwantedException = !shouldThrow && util.isError(actual); + var isUnexpectedException = !shouldThrow && actual && !expected; + + if ((isUnwantedException && + userProvidedMessage && + expectedException(actual, expected)) || + isUnexpectedException) { + fail(actual, expected, 'Got unwanted exception' + message); + } + + if ((shouldThrow && actual && expected && + !expectedException(actual, expected)) || (!shouldThrow && actual)) { + throw actual; } } -var ReactDebugTool = { - addHook: function (hook) { - hooks.push(hook); - }, - removeHook: function (hook) { - for (var i = 0; i < hooks.length; i++) { - if (hooks[i] === hook) { - hooks.splice(i, 1); - i--; - } - } - }, - isProfiling: function () { - return isProfiling; - }, - beginProfiling: function () { - if (isProfiling) { - return; - } +// 11. Expected to throw an error: +// assert.throws(block, Error_opt, message_opt); - isProfiling = true; - flushHistory.length = 0; - resetMeasurements(); - ReactDebugTool.addHook(ReactHostOperationHistoryHook); - }, - endProfiling: function () { - if (!isProfiling) { - return; - } +assert.throws = function(block, /*optional*/error, /*optional*/message) { + _throws(true, block, error, message); +}; - isProfiling = false; - resetMeasurements(); - ReactDebugTool.removeHook(ReactHostOperationHistoryHook); - }, - getFlushHistory: function () { - return flushHistory; - }, - onBeginFlush: function () { - currentFlushNesting++; - resetMeasurements(); - pauseCurrentLifeCycleTimer(); - emitEvent('onBeginFlush'); - }, - onEndFlush: function () { - resetMeasurements(); - currentFlushNesting--; - resumeCurrentLifeCycleTimer(); - emitEvent('onEndFlush'); - }, - onBeginLifeCycleTimer: function (debugID, timerType) { - checkDebugID(debugID); - emitEvent('onBeginLifeCycleTimer', debugID, timerType); - markBegin(debugID, timerType); - beginLifeCycleTimer(debugID, timerType); - }, - onEndLifeCycleTimer: function (debugID, timerType) { - checkDebugID(debugID); - endLifeCycleTimer(debugID, timerType); - markEnd(debugID, timerType); - emitEvent('onEndLifeCycleTimer', debugID, timerType); - }, - onBeginProcessingChildContext: function () { - emitEvent('onBeginProcessingChildContext'); - }, - onEndProcessingChildContext: function () { - emitEvent('onEndProcessingChildContext'); - }, - onHostOperation: function (operation) { - checkDebugID(operation.instanceID); - emitEvent('onHostOperation', operation); - }, - onSetState: function () { - emitEvent('onSetState'); - }, - onSetChildren: function (debugID, childDebugIDs) { - checkDebugID(debugID); - childDebugIDs.forEach(checkDebugID); - emitEvent('onSetChildren', debugID, childDebugIDs); - }, - onBeforeMountComponent: function (debugID, element, parentDebugID) { - checkDebugID(debugID); - checkDebugID(parentDebugID, true); - emitEvent('onBeforeMountComponent', debugID, element, parentDebugID); - markBegin(debugID, 'mount'); - }, - onMountComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'mount'); - emitEvent('onMountComponent', debugID); - }, - onBeforeUpdateComponent: function (debugID, element) { - checkDebugID(debugID); - emitEvent('onBeforeUpdateComponent', debugID, element); - markBegin(debugID, 'update'); - }, - onUpdateComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'update'); - emitEvent('onUpdateComponent', debugID); - }, - onBeforeUnmountComponent: function (debugID) { - checkDebugID(debugID); - emitEvent('onBeforeUnmountComponent', debugID); - markBegin(debugID, 'unmount'); - }, - onUnmountComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'unmount'); - emitEvent('onUnmountComponent', debugID); - }, - onTestEvent: function () { - emitEvent('onTestEvent'); - } +// EXTENSION! This is annoying to write outside this module. +assert.doesNotThrow = function(block, /*optional*/error, /*optional*/message) { + _throws(false, block, error, message); }; -// TODO remove these when RN/www gets updated -ReactDebugTool.addDevtool = ReactDebugTool.addHook; -ReactDebugTool.removeDevtool = ReactDebugTool.removeHook; +assert.ifError = function(err) { if (err) throw err; }; -ReactDebugTool.addHook(ReactInvalidSetStateWarningHook); -ReactDebugTool.addHook(ReactComponentTreeHook); -var url = ExecutionEnvironment.canUseDOM && window.location.href || ''; -if (/[?&]react_perf\b/.test(url)) { - ReactDebugTool.beginProfiling(); -} +var objectKeys = Object.keys || function (obj) { + var keys = []; + for (var key in obj) { + if (hasOwn.call(obj, key)) keys.push(key); + } + return keys; +}; -module.exports = ReactDebugTool; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) /***/ }), -/* 146 */ +/* 107 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * +/* WEBPACK VAR INJECTION */(function(Buffer) {/* + * Obtained from https://github.com/bitcoinjs/bitcoinjs-lib/blob/master/src/crypto.js + * 2017/07/25: No ripemd160 in SJCL, so resorted to this */ +var createHash = __webpack_require__(27); +function ripemd160(buffer) { + return createHash('rmd160').update(buffer).digest('hex'); +} -var warning = __webpack_require__(2); +function sha1(buffer) { + return createHash('sha1').update(buffer).digest('hex'); +} -if (process.env.NODE_ENV !== 'production') { - var processingChildContext = false; +function sha256(buffer) { + return createHash('sha256').update(buffer).digest('hex'); +} - var warnInvalidSetState = function () { - process.env.NODE_ENV !== 'production' ? warning(!processingChildContext, 'setState(...): Cannot call setState() inside getChildContext()') : void 0; - }; +function sha256x2(buffer) { + return sha256(Buffer.from(sha256(buffer), 'hex')); } -var ReactInvalidSetStateWarningHook = { - onBeginProcessingChildContext: function () { - processingChildContext = true; - }, - onEndProcessingChildContext: function () { - processingChildContext = false; - }, - onSetState: function () { - warnInvalidSetState(); - } +function hash160(buffer) { + const sha = sha256(buffer); + const hash160 = ripemd160(Buffer.from(sha, 'hex')); + return hash160; +} + +module.exports = { + hash160: hash160, + ripemd160: ripemd160, + sha1: sha1, + sha256: sha256, + sha256x2: sha256x2 }; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 108 */ +/***/ (function(module, exports, __webpack_require__) { + +var ciphers = __webpack_require__(424) +exports.createCipher = exports.Cipher = ciphers.createCipher +exports.createCipheriv = exports.Cipheriv = ciphers.createCipheriv +var deciphers = __webpack_require__(426) +exports.createDecipher = exports.Decipher = deciphers.createDecipher +exports.createDecipheriv = exports.Decipheriv = deciphers.createDecipheriv +var modes = __webpack_require__(70) +function getCiphers () { + return Object.keys(modes) +} +exports.listCiphers = exports.getCiphers = getCiphers -module.exports = ReactInvalidSetStateWarningHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 147 */ +/* 109 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ - -var history = []; +exports.utils = __webpack_require__(428); +exports.Cipher = __webpack_require__(429); +exports.DES = __webpack_require__(430); +exports.CBC = __webpack_require__(431); +exports.EDE = __webpack_require__(432); -var ReactHostOperationHistoryHook = { - onHostOperation: function (operation) { - history.push(operation); - }, - clearHistory: function () { - if (ReactHostOperationHistoryHook._preventClearing) { - // Should only be used for tests. - return; - } - - history = []; - }, - getHistory: function () { - return history; - } -}; - -module.exports = ReactHostOperationHistoryHook; /***/ }), -/* 148 */ +/* 110 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) {var bn = __webpack_require__(11); +var randomBytes = __webpack_require__(43); +module.exports = crt; +function blind(priv) { + var r = getr(priv); + var blinder = r.toRed(bn.mont(priv.modulus)) + .redPow(new bn(priv.publicExponent)).fromRed(); + return { + blinder: blinder, + unblinder:r.invm(priv.modulus) + }; +} +function crt(msg, priv) { + var blinds = blind(priv); + var len = priv.modulus.byteLength(); + var mod = bn.mont(priv.modulus); + var blinded = new bn(msg).mul(blinds.blinder).umod(priv.modulus); + var c1 = blinded.toRed(bn.mont(priv.prime1)); + var c2 = blinded.toRed(bn.mont(priv.prime2)); + var qinv = priv.coefficient; + var p = priv.prime1; + var q = priv.prime2; + var m1 = c1.redPow(priv.exponent1); + var m2 = c2.redPow(priv.exponent2); + m1 = m1.fromRed(); + m2 = m2.fromRed(); + var h = m1.isub(m2).imul(qinv).umod(p); + h.imul(q); + m2.iadd(h); + return new Buffer(m2.imul(blinds.unblinder).umod(priv.modulus).toArray(false, len)); +} +crt.getr = getr; +function getr(priv) { + var len = priv.modulus.byteLength(); + var r = new bn(randomBytes(len)); + while (r.cmp(priv.modulus) >= 0 || !r.umod(priv.prime1) || !r.umod(priv.prime2)) { + r = new bn(randomBytes(len)); + } + return r; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +/***/ }), +/* 111 */ +/***/ (function(module, exports) { -var performance = __webpack_require__(149); +var types = { + Array: function (value) { return value !== null && value !== undefined && value.constructor === Array }, + Boolean: function (value) { return typeof value === 'boolean' }, + Function: function (value) { return typeof value === 'function' }, + Nil: function (value) { return value === undefined || value === null }, + Number: function (value) { return typeof value === 'number' }, + Object: function (value) { return typeof value === 'object' }, + String: function (value) { return typeof value === 'string' }, + '': function () { return true } +} -var performanceNow; +// TODO: deprecate +types.Null = types.Nil -/** - * Detect if we can use `window.performance.now()` and gracefully fallback to - * `Date.now()` if it doesn't exist. We need to support Firefox < 15 for now - * because of Facebook's testing infrastructure. - */ -if (performance.now) { - performanceNow = function performanceNow() { - return performance.now(); - }; -} else { - performanceNow = function performanceNow() { - return Date.now(); - }; +for (var typeName in types) { + types[typeName].toJSON = function (t) { + return t + }.bind(null, typeName) } -module.exports = performanceNow; +module.exports = types + /***/ }), -/* 149 */ +/* 112 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ - - - -var ExecutionEnvironment = __webpack_require__(8); +var Buffer = __webpack_require__(7).Buffer +var bcrypto = __webpack_require__(44) +var bscript = __webpack_require__(14) +var bufferutils = __webpack_require__(206) +var opcodes = __webpack_require__(16) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var varuint = __webpack_require__(73) -var performance; +function varSliceSize (someScript) { + var length = someScript.length -if (ExecutionEnvironment.canUseDOM) { - performance = window.performance || window.msPerformance || window.webkitPerformance; + return varuint.encodingLength(length) + length } -module.exports = performance || {}; +function vectorSize (someVector) { + var length = someVector.length -/***/ }), -/* 150 */ -/***/ (function(module, exports, __webpack_require__) { + return varuint.encodingLength(length) + someVector.reduce(function (sum, witness) { + return sum + varSliceSize(witness) + }, 0) +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function Transaction () { + this.version = 1 + this.locktime = 0 + this.ins = [] + this.outs = [] +} +Transaction.DEFAULT_SEQUENCE = 0xffffffff +Transaction.SIGHASH_ALL = 0x01 +Transaction.SIGHASH_NONE = 0x02 +Transaction.SIGHASH_SINGLE = 0x03 +Transaction.SIGHASH_ANYONECANPAY = 0x80 +Transaction.ADVANCED_TRANSACTION_MARKER = 0x00 +Transaction.ADVANCED_TRANSACTION_FLAG = 0x01 + +var EMPTY_SCRIPT = Buffer.allocUnsafe(0) +var EMPTY_WITNESS = [] +var ZERO = Buffer.from('0000000000000000000000000000000000000000000000000000000000000000', 'hex') +var ONE = Buffer.from('0000000000000000000000000000000000000000000000000000000000000001', 'hex') +var VALUE_UINT64_MAX = Buffer.from('ffffffffffffffff', 'hex') +var BLANK_OUTPUT = { + script: EMPTY_SCRIPT, + valueBuffer: VALUE_UINT64_MAX +} +Transaction.fromBuffer = function (buffer, __noStrict) { + var offset = 0 + function readSlice (n) { + offset += n + return buffer.slice(offset - n, offset) + } -/** - * Module that is injectable into `EventPluginHub`, that specifies a - * deterministic ordering of `EventPlugin`s. A convenient way to reason about - * plugins, without having to package every one of them. This is better than - * having plugins be ordered in the same order that they are injected because - * that ordering would be influenced by the packaging order. - * `ResponderEventPlugin` must occur before `SimpleEventPlugin` so that - * preventing default on events is convenient in `SimpleEventPlugin` handlers. - */ + function readUInt32 () { + var i = buffer.readUInt32LE(offset) + offset += 4 + return i + } -var DefaultEventPluginOrder = ['ResponderEventPlugin', 'SimpleEventPlugin', 'TapEventPlugin', 'EnterLeaveEventPlugin', 'ChangeEventPlugin', 'SelectEventPlugin', 'BeforeInputEventPlugin']; + function readInt32 () { + var i = buffer.readInt32LE(offset) + offset += 4 + return i + } -module.exports = DefaultEventPluginOrder; + function readUInt64 () { + var i = bufferutils.readUInt64LE(buffer, offset) + offset += 8 + return i + } -/***/ }), -/* 151 */ -/***/ (function(module, exports, __webpack_require__) { + function readVarInt () { + var vi = varuint.decode(buffer, offset) + offset += varuint.decode.bytes + return vi + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + function readVarSlice () { + return readSlice(readVarInt()) + } + function readVector () { + var count = readVarInt() + var vector = [] + for (var i = 0; i < count; i++) vector.push(readVarSlice()) + return vector + } + var tx = new Transaction() + tx.version = readInt32() -var EventPropagators = __webpack_require__(31); -var ReactDOMComponentTree = __webpack_require__(6); -var SyntheticMouseEvent = __webpack_require__(42); + var marker = buffer.readUInt8(offset) + var flag = buffer.readUInt8(offset + 1) -var eventTypes = { - mouseEnter: { - registrationName: 'onMouseEnter', - dependencies: ['topMouseOut', 'topMouseOver'] - }, - mouseLeave: { - registrationName: 'onMouseLeave', - dependencies: ['topMouseOut', 'topMouseOver'] + var hasWitnesses = false + if (marker === Transaction.ADVANCED_TRANSACTION_MARKER && + flag === Transaction.ADVANCED_TRANSACTION_FLAG) { + offset += 2 + hasWitnesses = true } -}; -var EnterLeaveEventPlugin = { - eventTypes: eventTypes, - - /** - * For almost every interaction we care about, there will be both a top-level - * `mouseover` and `mouseout` event that occurs. Only use `mouseout` so that - * we do not extract duplicate events. However, moving the mouse into the - * browser from outside will not fire a `mouseout` event. In this case, we use - * the `mouseover` top-level event. - */ - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - if (topLevelType === 'topMouseOver' && (nativeEvent.relatedTarget || nativeEvent.fromElement)) { - return null; - } - if (topLevelType !== 'topMouseOut' && topLevelType !== 'topMouseOver') { - // Must not be a mouse in or mouse out - ignoring. - return null; - } + var vinLen = readVarInt() + for (var i = 0; i < vinLen; ++i) { + tx.ins.push({ + hash: readSlice(32), + index: readUInt32(), + script: readVarSlice(), + sequence: readUInt32(), + witness: EMPTY_WITNESS + }) + } - var win; - if (nativeEventTarget.window === nativeEventTarget) { - // `nativeEventTarget` is probably a window object. - win = nativeEventTarget; - } else { - // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. - var doc = nativeEventTarget.ownerDocument; - if (doc) { - win = doc.defaultView || doc.parentWindow; - } else { - win = window; - } - } + var voutLen = readVarInt() + for (i = 0; i < voutLen; ++i) { + tx.outs.push({ + value: readUInt64(), + script: readVarSlice() + }) + } - var from; - var to; - if (topLevelType === 'topMouseOut') { - from = targetInst; - var related = nativeEvent.relatedTarget || nativeEvent.toElement; - to = related ? ReactDOMComponentTree.getClosestInstanceFromNode(related) : null; - } else { - // Moving to a node from outside the window. - from = null; - to = targetInst; + if (hasWitnesses) { + for (i = 0; i < vinLen; ++i) { + tx.ins[i].witness = readVector() } - if (from === to) { - // Nothing pertains to our managed components. - return null; - } + // was this pointless? + if (!tx.hasWitnesses()) throw new Error('Transaction has superfluous witness data') + } - var fromNode = from == null ? win : ReactDOMComponentTree.getNodeFromInstance(from); - var toNode = to == null ? win : ReactDOMComponentTree.getNodeFromInstance(to); + tx.locktime = readUInt32() - var leave = SyntheticMouseEvent.getPooled(eventTypes.mouseLeave, from, nativeEvent, nativeEventTarget); - leave.type = 'mouseleave'; - leave.target = fromNode; - leave.relatedTarget = toNode; + if (__noStrict) return tx + if (offset !== buffer.length) throw new Error('Transaction has unexpected data') - var enter = SyntheticMouseEvent.getPooled(eventTypes.mouseEnter, to, nativeEvent, nativeEventTarget); - enter.type = 'mouseenter'; - enter.target = toNode; - enter.relatedTarget = fromNode; + return tx +} - EventPropagators.accumulateEnterLeaveDispatches(leave, enter, from, to); +Transaction.fromHex = function (hex) { + return Transaction.fromBuffer(Buffer.from(hex, 'hex')) +} - return [leave, enter]; +Transaction.isCoinbaseHash = function (buffer) { + typeforce(types.Hash256bit, buffer) + for (var i = 0; i < 32; ++i) { + if (buffer[i] !== 0) return false } -}; + return true +} -module.exports = EnterLeaveEventPlugin; +Transaction.prototype.isCoinbase = function () { + return this.ins.length === 1 && Transaction.isCoinbaseHash(this.ins[0].hash) +} -/***/ }), -/* 152 */ -/***/ (function(module, exports, __webpack_require__) { +Transaction.prototype.addInput = function (hash, index, sequence, scriptSig) { + typeforce(types.tuple( + types.Hash256bit, + types.UInt32, + types.maybe(types.UInt32), + types.maybe(types.Buffer) + ), arguments) + + if (types.Null(sequence)) { + sequence = Transaction.DEFAULT_SEQUENCE + } + + // Add the input and return the input's index + return (this.ins.push({ + hash: hash, + index: index, + script: scriptSig || EMPTY_SCRIPT, + sequence: sequence, + witness: EMPTY_WITNESS + }) - 1) +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Transaction.prototype.addOutput = function (scriptPubKey, value) { + typeforce(types.tuple(types.Buffer, types.Satoshi), arguments) + // Add the output and return the output's index + return (this.outs.push({ + script: scriptPubKey, + value: value + }) - 1) +} +Transaction.prototype.hasWitnesses = function () { + return this.ins.some(function (x) { + return x.witness.length !== 0 + }) +} -var DOMProperty = __webpack_require__(17); +Transaction.prototype.weight = function () { + var base = this.__byteLength(false) + var total = this.__byteLength(true) + return base * 3 + total +} -var MUST_USE_PROPERTY = DOMProperty.injection.MUST_USE_PROPERTY; -var HAS_BOOLEAN_VALUE = DOMProperty.injection.HAS_BOOLEAN_VALUE; -var HAS_NUMERIC_VALUE = DOMProperty.injection.HAS_NUMERIC_VALUE; -var HAS_POSITIVE_NUMERIC_VALUE = DOMProperty.injection.HAS_POSITIVE_NUMERIC_VALUE; -var HAS_OVERLOADED_BOOLEAN_VALUE = DOMProperty.injection.HAS_OVERLOADED_BOOLEAN_VALUE; +Transaction.prototype.virtualSize = function () { + return Math.ceil(this.weight() / 4) +} -var HTMLDOMPropertyConfig = { - isCustomAttribute: RegExp.prototype.test.bind(new RegExp('^(data|aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$')), - Properties: { - /** - * Standard Properties - */ - accept: 0, - acceptCharset: 0, - accessKey: 0, - action: 0, - allowFullScreen: HAS_BOOLEAN_VALUE, - allowTransparency: 0, - alt: 0, - // specifies target context for links with `preload` type - as: 0, - async: HAS_BOOLEAN_VALUE, - autoComplete: 0, - // autoFocus is polyfilled/normalized by AutoFocusUtils - // autoFocus: HAS_BOOLEAN_VALUE, - autoPlay: HAS_BOOLEAN_VALUE, - capture: HAS_BOOLEAN_VALUE, - cellPadding: 0, - cellSpacing: 0, - charSet: 0, - challenge: 0, - checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - cite: 0, - classID: 0, - className: 0, - cols: HAS_POSITIVE_NUMERIC_VALUE, - colSpan: 0, - content: 0, - contentEditable: 0, - contextMenu: 0, - controls: HAS_BOOLEAN_VALUE, - coords: 0, - crossOrigin: 0, - data: 0, // For `<object />` acts as `src`. - dateTime: 0, - 'default': HAS_BOOLEAN_VALUE, - defer: HAS_BOOLEAN_VALUE, - dir: 0, - disabled: HAS_BOOLEAN_VALUE, - download: HAS_OVERLOADED_BOOLEAN_VALUE, - draggable: 0, - encType: 0, - form: 0, - formAction: 0, - formEncType: 0, - formMethod: 0, - formNoValidate: HAS_BOOLEAN_VALUE, - formTarget: 0, - frameBorder: 0, - headers: 0, - height: 0, - hidden: HAS_BOOLEAN_VALUE, - high: 0, - href: 0, - hrefLang: 0, - htmlFor: 0, - httpEquiv: 0, - icon: 0, - id: 0, - inputMode: 0, - integrity: 0, - is: 0, - keyParams: 0, - keyType: 0, - kind: 0, - label: 0, - lang: 0, - list: 0, - loop: HAS_BOOLEAN_VALUE, - low: 0, - manifest: 0, - marginHeight: 0, - marginWidth: 0, - max: 0, - maxLength: 0, - media: 0, - mediaGroup: 0, - method: 0, - min: 0, - minLength: 0, - // Caution; `option.selected` is not updated if `select.multiple` is - // disabled with `removeAttribute`. - multiple: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - muted: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - name: 0, - nonce: 0, - noValidate: HAS_BOOLEAN_VALUE, - open: HAS_BOOLEAN_VALUE, - optimum: 0, - pattern: 0, - placeholder: 0, - playsInline: HAS_BOOLEAN_VALUE, - poster: 0, - preload: 0, - profile: 0, - radioGroup: 0, - readOnly: HAS_BOOLEAN_VALUE, - referrerPolicy: 0, - rel: 0, - required: HAS_BOOLEAN_VALUE, - reversed: HAS_BOOLEAN_VALUE, - role: 0, - rows: HAS_POSITIVE_NUMERIC_VALUE, - rowSpan: HAS_NUMERIC_VALUE, - sandbox: 0, - scope: 0, - scoped: HAS_BOOLEAN_VALUE, - scrolling: 0, - seamless: HAS_BOOLEAN_VALUE, - selected: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - shape: 0, - size: HAS_POSITIVE_NUMERIC_VALUE, - sizes: 0, - span: HAS_POSITIVE_NUMERIC_VALUE, - spellCheck: 0, - src: 0, - srcDoc: 0, - srcLang: 0, - srcSet: 0, - start: HAS_NUMERIC_VALUE, - step: 0, - style: 0, - summary: 0, - tabIndex: 0, - target: 0, - title: 0, - // Setting .type throws on non-<input> tags - type: 0, - useMap: 0, - value: 0, - width: 0, - wmode: 0, - wrap: 0, +Transaction.prototype.byteLength = function () { + return this.__byteLength(true) +} - /** - * RDFa Properties - */ - about: 0, - datatype: 0, - inlist: 0, - prefix: 0, - // property is also supported for OpenGraph in meta tags. - property: 0, - resource: 0, - 'typeof': 0, - vocab: 0, +Transaction.prototype.__byteLength = function (__allowWitness) { + var hasWitnesses = __allowWitness && this.hasWitnesses() - /** - * Non-standard Properties - */ - // autoCapitalize and autoCorrect are supported in Mobile Safari for - // keyboard hints. - autoCapitalize: 0, - autoCorrect: 0, - // autoSave allows WebKit/Blink to persist values of input fields on page reloads - autoSave: 0, - // color is for Safari mask-icon link - color: 0, - // itemProp, itemScope, itemType are for - // Microdata support. See http://schema.org/docs/gs.html - itemProp: 0, - itemScope: HAS_BOOLEAN_VALUE, - itemType: 0, - // itemID and itemRef are for Microdata support as well but - // only specified in the WHATWG spec document. See - // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api - itemID: 0, - itemRef: 0, - // results show looking glass icon and recent searches on input - // search fields in WebKit/Blink - results: 0, - // IE-only attribute that specifies security restrictions on an iframe - // as an alternative to the sandbox attribute on IE<10 - security: 0, - // IE-only attribute that controls focus behavior - unselectable: 0 - }, - DOMAttributeNames: { - acceptCharset: 'accept-charset', - className: 'class', - htmlFor: 'for', - httpEquiv: 'http-equiv' - }, - DOMPropertyNames: {}, - DOMMutationMethods: { - value: function (node, value) { - if (value == null) { - return node.removeAttribute('value'); - } + return ( + (hasWitnesses ? 10 : 8) + + varuint.encodingLength(this.ins.length) + + varuint.encodingLength(this.outs.length) + + this.ins.reduce(function (sum, input) { return sum + 40 + varSliceSize(input.script) }, 0) + + this.outs.reduce(function (sum, output) { return sum + 8 + varSliceSize(output.script) }, 0) + + (hasWitnesses ? this.ins.reduce(function (sum, input) { return sum + vectorSize(input.witness) }, 0) : 0) + ) +} - // Number inputs get special treatment due to some edge cases in - // Chrome. Let everything else assign the value attribute as normal. - // https://github.com/facebook/react/issues/7253#issuecomment-236074326 - if (node.type !== 'number' || node.hasAttribute('value') === false) { - node.setAttribute('value', '' + value); - } else if (node.validity && !node.validity.badInput && node.ownerDocument.activeElement !== node) { - // Don't assign an attribute if validation reports bad - // input. Chrome will clear the value. Additionally, don't - // operate on inputs that have focus, otherwise Chrome might - // strip off trailing decimal places and cause the user's - // cursor position to jump to the beginning of the input. - // - // In ReactDOMInput, we have an onBlur event that will trigger - // this function again when focus is lost. - node.setAttribute('value', '' + value); - } +Transaction.prototype.clone = function () { + var newTx = new Transaction() + newTx.version = this.version + newTx.locktime = this.locktime + + newTx.ins = this.ins.map(function (txIn) { + return { + hash: txIn.hash, + index: txIn.index, + script: txIn.script, + sequence: txIn.sequence, + witness: txIn.witness } - } -}; + }) -module.exports = HTMLDOMPropertyConfig; + newTx.outs = this.outs.map(function (txOut) { + return { + script: txOut.script, + value: txOut.value + } + }) -/***/ }), -/* 153 */ -/***/ (function(module, exports, __webpack_require__) { + return newTx +} -"use strict"; /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Hash transaction for signing a specific input. * + * Bitcoin uses a different hash for each signed transaction input. + * This method copies the transaction, makes the necessary changes based on the + * hashType, and then hashes the result. + * This hash can then be used to sign the provided transaction input. */ +Transaction.prototype.hashForSignature = function (inIndex, prevOutScript, hashType) { + typeforce(types.tuple(types.UInt32, types.Buffer, /* types.UInt8 */ types.Number), arguments) + // https://github.com/bitcoin/bitcoin/blob/master/src/test/sighash_tests.cpp#L29 + if (inIndex >= this.ins.length) return ONE + // ignore OP_CODESEPARATOR + var ourScript = bscript.compile(bscript.decompile(prevOutScript).filter(function (x) { + return x !== opcodes.OP_CODESEPARATOR + })) -var DOMChildrenOperations = __webpack_require__(55); -var ReactDOMIDOperations = __webpack_require__(158); + var txTmp = this.clone() -/** - * Abstracts away all functionality of the reconciler that requires knowledge of - * the browser context. TODO: These callers should be refactored to avoid the - * need for this injection. - */ -var ReactComponentBrowserEnvironment = { - processChildrenUpdates: ReactDOMIDOperations.dangerouslyProcessChildrenUpdates, + // SIGHASH_NONE: ignore all outputs? (wildcard payee) + if ((hashType & 0x1f) === Transaction.SIGHASH_NONE) { + txTmp.outs = [] - replaceNodeWithMarkup: DOMChildrenOperations.dangerouslyReplaceNodeWithMarkup -}; + // ignore sequence numbers (except at inIndex) + txTmp.ins.forEach(function (input, i) { + if (i === inIndex) return -module.exports = ReactComponentBrowserEnvironment; + input.sequence = 0 + }) -/***/ }), -/* 154 */ -/***/ (function(module, exports, __webpack_require__) { + // SIGHASH_SINGLE: ignore all outputs, except at the same index? + } else if ((hashType & 0x1f) === Transaction.SIGHASH_SINGLE) { + // https://github.com/bitcoin/bitcoin/blob/master/src/test/sighash_tests.cpp#L60 + if (inIndex >= this.outs.length) return ONE -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // truncate outputs after + txTmp.outs.length = inIndex + 1 + // "blank" outputs before + for (var i = 0; i < inIndex; i++) { + txTmp.outs[i] = BLANK_OUTPUT + } + // ignore sequence numbers (except at inIndex) + txTmp.ins.forEach(function (input, y) { + if (y === inIndex) return -var _prodInvariant = __webpack_require__(3); + input.sequence = 0 + }) + } -var DOMLazyTree = __webpack_require__(27); -var ExecutionEnvironment = __webpack_require__(8); + // SIGHASH_ANYONECANPAY: ignore inputs entirely? + if (hashType & Transaction.SIGHASH_ANYONECANPAY) { + txTmp.ins = [txTmp.ins[inIndex]] + txTmp.ins[0].script = ourScript -var createNodesFromMarkup = __webpack_require__(155); -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); + // SIGHASH_ALL: only ignore input scripts + } else { + // "blank" others input scripts + txTmp.ins.forEach(function (input) { input.script = EMPTY_SCRIPT }) + txTmp.ins[inIndex].script = ourScript + } -var Danger = { - /** - * Replaces a node with a string of markup at its current position within its - * parent. The markup must render into a single root node. - * - * @param {DOMElement} oldChild Child node to replace. - * @param {string} markup Markup to render in place of the child node. - * @internal - */ - dangerouslyReplaceNodeWithMarkup: function (oldChild, markup) { - !ExecutionEnvironment.canUseDOM ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot render markup in a worker thread. Make sure `window` and `document` are available globally before requiring React when unit testing or use ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('56') : void 0; - !markup ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Missing markup.') : _prodInvariant('57') : void 0; - !(oldChild.nodeName !== 'HTML') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot replace markup of the <html> node. This is because browser quirks make this unreliable and/or slow. If you want to render to the root you must use server rendering. See ReactDOMServer.renderToString().') : _prodInvariant('58') : void 0; + // serialize and hash + var buffer = Buffer.allocUnsafe(txTmp.__byteLength(false) + 4) + buffer.writeInt32LE(hashType, buffer.length - 4) + txTmp.__toBuffer(buffer, 0, false) - if (typeof markup === 'string') { - var newChild = createNodesFromMarkup(markup, emptyFunction)[0]; - oldChild.parentNode.replaceChild(newChild, oldChild); - } else { - DOMLazyTree.replaceChildWithTree(oldChild, markup); - } + return bcrypto.hash256(buffer) +} + +Transaction.prototype.hashForWitnessV0 = function (inIndex, prevOutScript, value, hashType) { + typeforce(types.tuple(types.UInt32, types.Buffer, types.Satoshi, types.UInt32), arguments) + + var tbuffer, toffset + function writeSlice (slice) { toffset += slice.copy(tbuffer, toffset) } + function writeUInt32 (i) { toffset = tbuffer.writeUInt32LE(i, toffset) } + function writeUInt64 (i) { toffset = bufferutils.writeUInt64LE(tbuffer, i, toffset) } + function writeVarInt (i) { + varuint.encode(i, tbuffer, toffset) + toffset += varuint.encode.bytes } -}; + function writeVarSlice (slice) { writeVarInt(slice.length); writeSlice(slice) } -module.exports = Danger; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var hashOutputs = ZERO + var hashPrevouts = ZERO + var hashSequence = ZERO -/***/ }), -/* 155 */ -/***/ (function(module, exports, __webpack_require__) { + if (!(hashType & Transaction.SIGHASH_ANYONECANPAY)) { + tbuffer = Buffer.allocUnsafe(36 * this.ins.length) + toffset = 0 -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { + this.ins.forEach(function (txIn) { + writeSlice(txIn.hash) + writeUInt32(txIn.index) + }) -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + hashPrevouts = bcrypto.hash256(tbuffer) + } -/*eslint-disable fb-www/unsafe-html*/ + if (!(hashType & Transaction.SIGHASH_ANYONECANPAY) && + (hashType & 0x1f) !== Transaction.SIGHASH_SINGLE && + (hashType & 0x1f) !== Transaction.SIGHASH_NONE) { + tbuffer = Buffer.allocUnsafe(4 * this.ins.length) + toffset = 0 -var ExecutionEnvironment = __webpack_require__(8); + this.ins.forEach(function (txIn) { + writeUInt32(txIn.sequence) + }) -var createArrayFromMixed = __webpack_require__(156); -var getMarkupWrap = __webpack_require__(157); -var invariant = __webpack_require__(1); + hashSequence = bcrypto.hash256(tbuffer) + } -/** - * Dummy container used to render all markup. - */ -var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; + if ((hashType & 0x1f) !== Transaction.SIGHASH_SINGLE && + (hashType & 0x1f) !== Transaction.SIGHASH_NONE) { + var txOutsSize = this.outs.reduce(function (sum, output) { + return sum + 8 + varSliceSize(output.script) + }, 0) -/** - * Pattern used by `getNodeName`. - */ -var nodeNamePattern = /^\s*<(\w+)/; + tbuffer = Buffer.allocUnsafe(txOutsSize) + toffset = 0 -/** - * Extracts the `nodeName` of the first element in a string of markup. - * - * @param {string} markup String of markup. - * @return {?string} Node name of the supplied markup. - */ -function getNodeName(markup) { - var nodeNameMatch = markup.match(nodeNamePattern); - return nodeNameMatch && nodeNameMatch[1].toLowerCase(); -} + this.outs.forEach(function (out) { + writeUInt64(out.value) + writeVarSlice(out.script) + }) -/** - * Creates an array containing the nodes rendered from the supplied markup. The - * optionally supplied `handleScript` function will be invoked once for each - * <script> element that is rendered. If no `handleScript` function is supplied, - * an exception is thrown if any <script> elements are rendered. - * - * @param {string} markup A string of valid HTML markup. - * @param {?function} handleScript Invoked once for each rendered <script>. - * @return {array<DOMElement|DOMTextNode>} An array of rendered nodes. - */ -function createNodesFromMarkup(markup, handleScript) { - var node = dummyNode; - !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup dummy not initialized') : invariant(false) : void 0; - var nodeName = getNodeName(markup); + hashOutputs = bcrypto.hash256(tbuffer) + } else if ((hashType & 0x1f) === Transaction.SIGHASH_SINGLE && inIndex < this.outs.length) { + var output = this.outs[inIndex] - var wrap = nodeName && getMarkupWrap(nodeName); - if (wrap) { - node.innerHTML = wrap[1] + markup + wrap[2]; + tbuffer = Buffer.allocUnsafe(8 + varSliceSize(output.script)) + toffset = 0 + writeUInt64(output.value) + writeVarSlice(output.script) - var wrapDepth = wrap[0]; - while (wrapDepth--) { - node = node.lastChild; - } - } else { - node.innerHTML = markup; + hashOutputs = bcrypto.hash256(tbuffer) } - var scripts = node.getElementsByTagName('script'); - if (scripts.length) { - !handleScript ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup(...): Unexpected <script> element rendered.') : invariant(false) : void 0; - createArrayFromMixed(scripts).forEach(handleScript); - } + tbuffer = Buffer.allocUnsafe(156 + varSliceSize(prevOutScript)) + toffset = 0 - var nodes = Array.from(node.childNodes); - while (node.lastChild) { - node.removeChild(node.lastChild); - } - return nodes; + var input = this.ins[inIndex] + writeUInt32(this.version) + writeSlice(hashPrevouts) + writeSlice(hashSequence) + writeSlice(input.hash) + writeUInt32(input.index) + writeVarSlice(prevOutScript) + writeUInt64(value) + writeUInt32(input.sequence) + writeSlice(hashOutputs) + writeUInt32(this.locktime) + writeUInt32(hashType) + return bcrypto.hash256(tbuffer) } -module.exports = createNodesFromMarkup; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Transaction.prototype.getHash = function () { + return bcrypto.hash256(this.__toBuffer(undefined, undefined, false)) +} -/***/ }), -/* 156 */ -/***/ (function(module, exports, __webpack_require__) { +Transaction.prototype.getId = function () { + // transaction hash's are displayed in reverse order + return this.getHash().reverse().toString('hex') +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +Transaction.prototype.toBuffer = function (buffer, initialOffset) { + return this.__toBuffer(buffer, initialOffset, true) +} -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +Transaction.prototype.__toBuffer = function (buffer, initialOffset, __allowWitness) { + if (!buffer) buffer = Buffer.allocUnsafe(this.__byteLength(__allowWitness)) -var invariant = __webpack_require__(1); + var offset = initialOffset || 0 + function writeSlice (slice) { offset += slice.copy(buffer, offset) } + function writeUInt8 (i) { offset = buffer.writeUInt8(i, offset) } + function writeUInt32 (i) { offset = buffer.writeUInt32LE(i, offset) } + function writeInt32 (i) { offset = buffer.writeInt32LE(i, offset) } + function writeUInt64 (i) { offset = bufferutils.writeUInt64LE(buffer, i, offset) } + function writeVarInt (i) { + varuint.encode(i, buffer, offset) + offset += varuint.encode.bytes + } + function writeVarSlice (slice) { writeVarInt(slice.length); writeSlice(slice) } + function writeVector (vector) { writeVarInt(vector.length); vector.forEach(writeVarSlice) } -/** - * Convert array-like objects to arrays. - * - * This API assumes the caller knows the contents of the data type. For less - * well defined inputs use createArrayFromMixed. - * - * @param {object|function|filelist} obj - * @return {array} - */ -function toArray(obj) { - var length = obj.length; + writeInt32(this.version) - // Some browsers builtin objects can report typeof 'function' (e.g. NodeList - // in old versions of Safari). - !(!Array.isArray(obj) && (typeof obj === 'object' || typeof obj === 'function')) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Array-like object expected') : invariant(false) : void 0; + var hasWitnesses = __allowWitness && this.hasWitnesses() - !(typeof length === 'number') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object needs a length property') : invariant(false) : void 0; + if (hasWitnesses) { + writeUInt8(Transaction.ADVANCED_TRANSACTION_MARKER) + writeUInt8(Transaction.ADVANCED_TRANSACTION_FLAG) + } - !(length === 0 || length - 1 in obj) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object should have keys for indices') : invariant(false) : void 0; + writeVarInt(this.ins.length) - !(typeof obj.callee !== 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object can\'t be `arguments`. Use rest params ' + '(function(...args) {}) or Array.from() instead.') : invariant(false) : void 0; + this.ins.forEach(function (txIn) { + writeSlice(txIn.hash) + writeUInt32(txIn.index) + writeVarSlice(txIn.script) + writeUInt32(txIn.sequence) + }) - // Old IE doesn't give collections access to hasOwnProperty. Assume inputs - // without method will throw during the slice call and skip straight to the - // fallback. - if (obj.hasOwnProperty) { - try { - return Array.prototype.slice.call(obj); - } catch (e) { - // IE < 9 does not support Array#slice on collections objects + writeVarInt(this.outs.length) + this.outs.forEach(function (txOut) { + if (!txOut.valueBuffer) { + writeUInt64(txOut.value) + } else { + writeSlice(txOut.valueBuffer) } - } - // Fall back to copying key by key. This assumes all keys have a value, - // so will not preserve sparsely populated inputs. - var ret = Array(length); - for (var ii = 0; ii < length; ii++) { - ret[ii] = obj[ii]; + writeVarSlice(txOut.script) + }) + + if (hasWitnesses) { + this.ins.forEach(function (input) { + writeVector(input.witness) + }) } - return ret; + + writeUInt32(this.locktime) + + // avoid slicing unless necessary + if (initialOffset !== undefined) return buffer.slice(initialOffset, offset) + return buffer } -/** - * Perform a heuristic test to determine if an object is "array-like". - * - * A monk asked Joshu, a Zen master, "Has a dog Buddha nature?" - * Joshu replied: "Mu." - * - * This function determines if its argument has "array nature": it returns - * true if the argument is an actual array, an `arguments' object, or an - * HTMLCollection (e.g. node.childNodes or node.getElementsByTagName()). - * - * It will return false for other array-like objects like Filelist. - * - * @param {*} obj - * @return {boolean} - */ -function hasArrayNature(obj) { - return ( - // not null/false - !!obj && ( - // arrays are objects, NodeLists are functions in Safari - typeof obj == 'object' || typeof obj == 'function') && - // quacks like an array - 'length' in obj && - // not window - !('setInterval' in obj) && - // no DOM node should be considered an array-like - // a 'select' element has 'length' and 'item' properties on IE8 - typeof obj.nodeType != 'number' && ( - // a real array - Array.isArray(obj) || - // arguments - 'callee' in obj || - // HTMLCollection/NodeList - 'item' in obj) - ); +Transaction.prototype.toHex = function () { + return this.toBuffer().toString('hex') } -/** - * Ensure that the argument is an array by wrapping it in an array if it is not. - * Creates a copy of the argument if it is already an array. - * - * This is mostly useful idiomatically: - * - * var createArrayFromMixed = require('createArrayFromMixed'); - * - * function takesOneOrMoreThings(things) { - * things = createArrayFromMixed(things); - * ... - * } - * - * This allows you to treat `things' as an array, but accept scalars in the API. - * - * If you need to convert an array-like object, like `arguments`, into an array - * use toArray instead. - * - * @param {*} obj - * @return {array} - */ -function createArrayFromMixed(obj) { - if (!hasArrayNature(obj)) { - return [obj]; - } else if (Array.isArray(obj)) { - return obj.slice(); - } else { - return toArray(obj); - } +Transaction.prototype.setInputScript = function (index, scriptSig) { + typeforce(types.tuple(types.Number, types.Buffer), arguments) + + this.ins[index].script = scriptSig } -module.exports = createArrayFromMixed; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Transaction.prototype.setWitness = function (index, witness) { + typeforce(types.tuple(types.Number, [types.Buffer]), arguments) + + this.ins[index].witness = witness +} + +module.exports = Transaction + /***/ }), -/* 157 */ +/* 113 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +var baddress = __webpack_require__(114) +var bcrypto = __webpack_require__(44) +var ecdsa = __webpack_require__(489) +var randomBytes = __webpack_require__(43) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var wif = __webpack_require__(492) -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var NETWORKS = __webpack_require__(54) +var BigInteger = __webpack_require__(30) -/*eslint-disable fb-www/unsafe-html */ +var ecurve = __webpack_require__(116) +var secp256k1 = ecdsa.__curve -var ExecutionEnvironment = __webpack_require__(8); +function ECPair (d, Q, options) { + if (options) { + typeforce({ + compressed: types.maybe(types.Boolean), + network: types.maybe(types.Network) + }, options) + } -var invariant = __webpack_require__(1); + options = options || {} -/** - * Dummy container used to detect which wraps are necessary. - */ -var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; + if (d) { + if (d.signum() <= 0) throw new Error('Private key must be greater than 0') + if (d.compareTo(secp256k1.n) >= 0) throw new Error('Private key must be less than the curve order') + if (Q) throw new TypeError('Unexpected publicKey parameter') -/** - * Some browsers cannot use `innerHTML` to render certain elements standalone, - * so we wrap them, render the wrapped nodes, then extract the desired node. - * - * In IE8, certain elements cannot render alone, so wrap all elements ('*'). - */ + this.d = d + } else { + typeforce(types.ECPoint, Q) -var shouldWrap = {}; + this.__Q = Q + } -var selectWrap = [1, '<select multiple="true">', '</select>']; -var tableWrap = [1, '<table>', '</table>']; -var trWrap = [3, '<table><tbody><tr>', '</tr></tbody></table>']; + this.compressed = options.compressed === undefined ? true : options.compressed + this.network = options.network || NETWORKS.bitcoin +} -var svgWrap = [1, '<svg xmlns="http://www.w3.org/2000/svg">', '</svg>']; +Object.defineProperty(ECPair.prototype, 'Q', { + get: function () { + if (!this.__Q && this.d) { + this.__Q = secp256k1.G.multiply(this.d) + } -var markupWrap = { - '*': [1, '?<div>', '</div>'], + return this.__Q + } +}) - 'area': [1, '<map>', '</map>'], - 'col': [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>'], - 'legend': [1, '<fieldset>', '</fieldset>'], - 'param': [1, '<object>', '</object>'], - 'tr': [2, '<table><tbody>', '</tbody></table>'], +ECPair.fromPublicKeyBuffer = function (buffer, network) { + var Q = ecurve.Point.decodeFrom(secp256k1, buffer) - 'optgroup': selectWrap, - 'option': selectWrap, + return new ECPair(null, Q, { + compressed: Q.compressed, + network: network + }) +} - 'caption': tableWrap, - 'colgroup': tableWrap, - 'tbody': tableWrap, - 'tfoot': tableWrap, - 'thead': tableWrap, +ECPair.fromWIF = function (string, network) { + var decoded = wif.decode(string) + var version = decoded.version - 'td': trWrap, - 'th': trWrap -}; + // list of networks? + if (types.Array(network)) { + network = network.filter(function (x) { + return version === x.wif + }).pop() -// Initialize the SVG elements since we know they'll always need to be wrapped -// consistently. If they are created inside a <div> they will be initialized in -// the wrong namespace (and will not display). -var svgElements = ['circle', 'clipPath', 'defs', 'ellipse', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'text', 'tspan']; -svgElements.forEach(function (nodeName) { - markupWrap[nodeName] = svgWrap; - shouldWrap[nodeName] = true; -}); + if (!network) throw new Error('Unknown network version') -/** - * Gets the markup wrap configuration for the supplied `nodeName`. - * - * NOTE: This lazily detects which wraps are necessary for the current browser. - * - * @param {string} nodeName Lowercase `nodeName`. - * @return {?array} Markup wrap configuration, if applicable. - */ -function getMarkupWrap(nodeName) { - !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Markup wrapping node not initialized') : invariant(false) : void 0; - if (!markupWrap.hasOwnProperty(nodeName)) { - nodeName = '*'; - } - if (!shouldWrap.hasOwnProperty(nodeName)) { - if (nodeName === '*') { - dummyNode.innerHTML = '<link />'; - } else { - dummyNode.innerHTML = '<' + nodeName + '></' + nodeName + '>'; - } - shouldWrap[nodeName] = !dummyNode.firstChild; + // otherwise, assume a network object (or default to bitcoin) + } else { + network = network || NETWORKS.bitcoin + + if (version !== network.wif) throw new Error('Invalid network version') } - return shouldWrap[nodeName] ? markupWrap[nodeName] : null; + + var d = BigInteger.fromBuffer(decoded.privateKey) + + return new ECPair(d, null, { + compressed: decoded.compressed, + network: network + }) } -module.exports = getMarkupWrap; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +ECPair.makeRandom = function (options) { + options = options || {} -/***/ }), -/* 158 */ -/***/ (function(module, exports, __webpack_require__) { + var rng = options.rng || randomBytes -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var d + do { + var buffer = rng(32) + typeforce(types.Buffer256bit, buffer) + d = BigInteger.fromBuffer(buffer) + } while (d.signum() <= 0 || d.compareTo(secp256k1.n) >= 0) + return new ECPair(d, null, options) +} -var DOMChildrenOperations = __webpack_require__(55); -var ReactDOMComponentTree = __webpack_require__(6); +ECPair.prototype.getAddress = function () { + return baddress.toBase58Check(bcrypto.hash160(this.getPublicKeyBuffer()), this.getNetwork().pubKeyHash) +} -/** - * Operations used to process updates to DOM nodes. - */ -var ReactDOMIDOperations = { - /** - * Updates a component's children by processing a series of updates. - * - * @param {array<object>} updates List of update configurations. - * @internal - */ - dangerouslyProcessChildrenUpdates: function (parentInst, updates) { - var node = ReactDOMComponentTree.getNodeFromInstance(parentInst); - DOMChildrenOperations.processUpdates(node, updates); - } -}; +ECPair.prototype.getNetwork = function () { + return this.network +} + +ECPair.prototype.getPublicKeyBuffer = function () { + return this.Q.getEncoded(this.compressed) +} + +ECPair.prototype.sign = function (hash) { + if (!this.d) throw new Error('Missing private key') + + return ecdsa.sign(hash, this.d) +} + +ECPair.prototype.toWIF = function () { + if (!this.d) throw new Error('Missing private key') + + return wif.encode(this.network.wif, this.d.toBuffer(32), this.compressed) +} + +ECPair.prototype.verify = function (hash, signature) { + return ecdsa.verify(hash, signature, this.Q) +} + +module.exports = ECPair -module.exports = ReactDOMIDOperations; /***/ }), -/* 159 */ +/* 114 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Buffer = __webpack_require__(7).Buffer +var bs58check = __webpack_require__(33) +var bscript = __webpack_require__(14) +var networks = __webpack_require__(54) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) -/* global hasOwnProperty:true */ +function fromBase58Check (address) { + var payload = bs58check.decode(address) + if (payload.length < 21) throw new TypeError(address + ' is too short') + if (payload.length > 21) throw new TypeError(address + ' is too long') + var version = payload.readUInt8(0) + var hash = payload.slice(1) + return { hash: hash, version: version } +} -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); - -var AutoFocusUtils = __webpack_require__(160); -var CSSPropertyOperations = __webpack_require__(161); -var DOMLazyTree = __webpack_require__(27); -var DOMNamespaces = __webpack_require__(56); -var DOMProperty = __webpack_require__(17); -var DOMPropertyOperations = __webpack_require__(93); -var EventPluginHub = __webpack_require__(32); -var EventPluginRegistry = __webpack_require__(40); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactDOMComponentFlags = __webpack_require__(81); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMInput = __webpack_require__(171); -var ReactDOMOption = __webpack_require__(172); -var ReactDOMSelect = __webpack_require__(95); -var ReactDOMTextarea = __webpack_require__(173); -var ReactInstrumentation = __webpack_require__(13); -var ReactMultiChild = __webpack_require__(174); -var ReactServerRenderingTransaction = __webpack_require__(183); - -var emptyFunction = __webpack_require__(12); -var escapeTextContentForBrowser = __webpack_require__(44); -var invariant = __webpack_require__(1); -var isEventSupported = __webpack_require__(53); -var shallowEqual = __webpack_require__(60); -var inputValueTracking = __webpack_require__(87); -var validateDOMNesting = __webpack_require__(64); -var warning = __webpack_require__(2); +function toBase58Check (hash, version) { + typeforce(types.tuple(types.Hash160bit, types.UInt8), arguments) -var Flags = ReactDOMComponentFlags; -var deleteListener = EventPluginHub.deleteListener; -var getNode = ReactDOMComponentTree.getNodeFromInstance; -var listenTo = ReactBrowserEventEmitter.listenTo; -var registrationNameModules = EventPluginRegistry.registrationNameModules; + var payload = Buffer.allocUnsafe(21) + payload.writeUInt8(version, 0) + hash.copy(payload, 1) -// For quickly matching children type, to test if can be treated as content. -var CONTENT_TYPES = { string: true, number: true }; + return bs58check.encode(payload) +} -var STYLE = 'style'; -var HTML = '__html'; -var RESERVED_PROPS = { - children: null, - dangerouslySetInnerHTML: null, - suppressContentEditableWarning: null -}; +function fromOutputScript (outputScript, network) { + network = network || networks.bitcoin -// Node type for document fragments (Node.DOCUMENT_FRAGMENT_NODE). -var DOC_FRAGMENT_TYPE = 11; + if (bscript.pubKeyHash.output.check(outputScript)) return toBase58Check(bscript.compile(outputScript).slice(3, 23), network.pubKeyHash) + if (bscript.scriptHash.output.check(outputScript)) return toBase58Check(bscript.compile(outputScript).slice(2, 22), network.scriptHash) -function getDeclarationErrorAddendum(internalInstance) { - if (internalInstance) { - var owner = internalInstance._currentElement._owner || null; - if (owner) { - var name = owner.getName(); - if (name) { - return ' This DOM node was rendered by `' + name + '`.'; - } - } - } - return ''; + throw new Error(bscript.toASM(outputScript) + ' has no matching Address') } -function friendlyStringify(obj) { - if (typeof obj === 'object') { - if (Array.isArray(obj)) { - return '[' + obj.map(friendlyStringify).join(', ') + ']'; - } else { - var pairs = []; - for (var key in obj) { - if (Object.prototype.hasOwnProperty.call(obj, key)) { - var keyEscaped = /^[a-z$_][\w$_]*$/i.test(key) ? key : JSON.stringify(key); - pairs.push(keyEscaped + ': ' + friendlyStringify(obj[key])); - } - } - return '{' + pairs.join(', ') + '}'; - } - } else if (typeof obj === 'string') { - return JSON.stringify(obj); - } else if (typeof obj === 'function') { - return '[function object]'; - } - // Differs from JSON.stringify in that undefined because undefined and that - // inf and nan don't become null - return String(obj); +function toOutputScript (address, network) { + network = network || networks.bitcoin + + var decode = fromBase58Check(address) + if (decode.version === network.pubKeyHash) return bscript.pubKeyHash.output.encode(decode.hash) + if (decode.version === network.scriptHash) return bscript.scriptHash.output.encode(decode.hash) + + throw new Error(address + ' has no matching Script') } -var styleMutationWarning = {}; +module.exports = { + fromBase58Check: fromBase58Check, + fromOutputScript: fromOutputScript, + toBase58Check: toBase58Check, + toOutputScript: toOutputScript +} -function checkAndWarnForMutatedStyle(style1, style2, component) { - if (style1 == null || style2 == null) { - return; - } - if (shallowEqual(style1, style2)) { - return; - } - var componentName = component._tag; - var owner = component._currentElement._owner; - var ownerName; - if (owner) { - ownerName = owner.getName(); - } +/***/ }), +/* 115 */ +/***/ (function(module, exports, __webpack_require__) { - var hash = ownerName + '|' + componentName; +/* WEBPACK VAR INJECTION */(function(Buffer) {var bip66 = __webpack_require__(104) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) - if (styleMutationWarning.hasOwnProperty(hash)) { - return; - } +var BigInteger = __webpack_require__(30) - styleMutationWarning[hash] = true; +function ECSignature (r, s) { + typeforce(types.tuple(types.BigInt, types.BigInt), arguments) - process.env.NODE_ENV !== 'production' ? warning(false, '`%s` was passed a style object that has previously been mutated. ' + 'Mutating `style` is deprecated. Consider cloning it beforehand. Check ' + 'the `render` %s. Previous style: %s. Mutated style: %s.', componentName, owner ? 'of `' + ownerName + '`' : 'using <' + componentName + '>', friendlyStringify(style1), friendlyStringify(style2)) : void 0; + this.r = r + this.s = s } -/** - * @param {object} component - * @param {?object} props - */ -function assertValidProps(component, props) { - if (!props) { - return; - } - // Note the use of `==` which checks for null or undefined. - if (voidElementTags[component._tag]) { - !(props.children == null && props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.%s', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : _prodInvariant('137', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : void 0; - } - if (props.dangerouslySetInnerHTML != null) { - !(props.children == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Can only set one of `children` or `props.dangerouslySetInnerHTML`.') : _prodInvariant('60') : void 0; - !(typeof props.dangerouslySetInnerHTML === 'object' && HTML in props.dangerouslySetInnerHTML) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.') : _prodInvariant('61') : void 0; - } - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(props.innerHTML == null, 'Directly setting property `innerHTML` is not permitted. ' + 'For more information, lookup documentation on `dangerouslySetInnerHTML`.') : void 0; - process.env.NODE_ENV !== 'production' ? warning(props.suppressContentEditableWarning || !props.contentEditable || props.children == null, 'A component is `contentEditable` and contains `children` managed by ' + 'React. It is now your responsibility to guarantee that none of ' + 'those nodes are unexpectedly modified or duplicated. This is ' + 'probably not intentional.') : void 0; - process.env.NODE_ENV !== 'production' ? warning(props.onFocusIn == null && props.onFocusOut == null, 'React uses onFocus and onBlur instead of onFocusIn and onFocusOut. ' + 'All React events are normalized to bubble, so onFocusIn and onFocusOut ' + 'are not needed/supported by React.') : void 0; +ECSignature.parseCompact = function (buffer) { + if (buffer.length !== 65) throw new Error('Invalid signature length') + + var flagByte = buffer.readUInt8(0) - 27 + if (flagByte !== (flagByte & 7)) throw new Error('Invalid signature parameter') + + var compressed = !!(flagByte & 4) + var recoveryParam = flagByte & 3 + + var r = BigInteger.fromBuffer(buffer.slice(1, 33)) + var s = BigInteger.fromBuffer(buffer.slice(33)) + + return { + compressed: compressed, + i: recoveryParam, + signature: new ECSignature(r, s) } - !(props.style == null || typeof props.style === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + \'em\'}} when using JSX.%s', getDeclarationErrorAddendum(component)) : _prodInvariant('62', getDeclarationErrorAddendum(component)) : void 0; } -function enqueuePutListener(inst, registrationName, listener, transaction) { - if (transaction instanceof ReactServerRenderingTransaction) { - return; - } - if (process.env.NODE_ENV !== 'production') { - // IE8 has no API for event capturing and the `onScroll` event doesn't - // bubble. - process.env.NODE_ENV !== 'production' ? warning(registrationName !== 'onScroll' || isEventSupported('scroll', true), "This browser doesn't support the `onScroll` event") : void 0; - } - var containerInfo = inst._hostContainerInfo; - var isDocumentFragment = containerInfo._node && containerInfo._node.nodeType === DOC_FRAGMENT_TYPE; - var doc = isDocumentFragment ? containerInfo._node : containerInfo._ownerDocument; - listenTo(registrationName, doc); - transaction.getReactMountReady().enqueue(putListener, { - inst: inst, - registrationName: registrationName, - listener: listener - }); +ECSignature.fromDER = function (buffer) { + var decode = bip66.decode(buffer) + var r = BigInteger.fromDERInteger(decode.r) + var s = BigInteger.fromDERInteger(decode.s) + + return new ECSignature(r, s) } -function putListener() { - var listenerToPut = this; - EventPluginHub.putListener(listenerToPut.inst, listenerToPut.registrationName, listenerToPut.listener); +// BIP62: 1 byte hashType flag (only 0x01, 0x02, 0x03, 0x81, 0x82 and 0x83 are allowed) +ECSignature.parseScriptSignature = function (buffer) { + var hashType = buffer.readUInt8(buffer.length - 1) + var hashTypeMod = hashType & ~0x80 + + if (hashTypeMod <= 0x00 || hashTypeMod >= 0x04) throw new Error('Invalid hashType ' + hashType) + + return { + signature: ECSignature.fromDER(buffer.slice(0, -1)), + hashType: hashType + } } -function inputPostMount() { - var inst = this; - ReactDOMInput.postMountWrapper(inst); +ECSignature.prototype.toCompact = function (i, compressed) { + if (compressed) { + i += 4 + } + + i += 27 + + var buffer = Buffer.alloc(65) + buffer.writeUInt8(i, 0) + this.r.toBuffer(32).copy(buffer, 1) + this.s.toBuffer(32).copy(buffer, 33) + + return buffer } -function textareaPostMount() { - var inst = this; - ReactDOMTextarea.postMountWrapper(inst); +ECSignature.prototype.toDER = function () { + var r = Buffer.from(this.r.toDERInteger()) + var s = Buffer.from(this.s.toDERInteger()) + + return bip66.encode(r, s) } -function optionPostMount() { - var inst = this; - ReactDOMOption.postMountWrapper(inst); +ECSignature.prototype.toScriptSignature = function (hashType) { + var hashTypeMod = hashType & ~0x80 + if (hashTypeMod <= 0 || hashTypeMod >= 4) throw new Error('Invalid hashType ' + hashType) + + var hashTypeBuffer = Buffer.alloc(1) + hashTypeBuffer.writeUInt8(hashType, 0) + + return Buffer.concat([this.toDER(), hashTypeBuffer]) } -var setAndValidateContentChildDev = emptyFunction; -if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev = function (content) { - var hasExistingContent = this._contentDebugID != null; - var debugID = this._debugID; - // This ID represents the inlined child that has no backing instance: - var contentDebugID = -debugID; +module.exports = ECSignature - if (content == null) { - if (hasExistingContent) { - ReactInstrumentation.debugTool.onUnmountComponent(this._contentDebugID); - } - this._contentDebugID = null; - return; - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - validateDOMNesting(null, String(content), this, this._ancestorInfo); - this._contentDebugID = contentDebugID; - if (hasExistingContent) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(contentDebugID, content); - ReactInstrumentation.debugTool.onUpdateComponent(contentDebugID); - } else { - ReactInstrumentation.debugTool.onBeforeMountComponent(contentDebugID, content, debugID); - ReactInstrumentation.debugTool.onMountComponent(contentDebugID); - ReactInstrumentation.debugTool.onSetChildren(debugID, [contentDebugID]); - } - }; +/***/ }), +/* 116 */ +/***/ (function(module, exports, __webpack_require__) { + +var Point = __webpack_require__(207) +var Curve = __webpack_require__(208) + +var getCurveByName = __webpack_require__(490) + +module.exports = { + Curve: Curve, + Point: Point, + getCurveByName: getCurveByName } -// There are so many media events, it makes sense to just -// maintain a list rather than create a `trapBubbledEvent` for each -var mediaEvents = { - topAbort: 'abort', - topCanPlay: 'canplay', - topCanPlayThrough: 'canplaythrough', - topDurationChange: 'durationchange', - topEmptied: 'emptied', - topEncrypted: 'encrypted', - topEnded: 'ended', - topError: 'error', - topLoadedData: 'loadeddata', - topLoadedMetadata: 'loadedmetadata', - topLoadStart: 'loadstart', - topPause: 'pause', - topPlay: 'play', - topPlaying: 'playing', - topProgress: 'progress', - topRateChange: 'ratechange', - topSeeked: 'seeked', - topSeeking: 'seeking', - topStalled: 'stalled', - topSuspend: 'suspend', - topTimeUpdate: 'timeupdate', - topVolumeChange: 'volumechange', - topWaiting: 'waiting' + +/***/ }), +/* 117 */ +/***/ (function(module, exports) { + +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ +// css base code, injected by the css-loader +module.exports = function(useSourceMap) { + var list = []; + + // return the list of modules as css string + list.toString = function toString() { + return this.map(function (item) { + var content = cssWithMappingToString(item, useSourceMap); + if(item[2]) { + return "@media " + item[2] + "{" + content + "}"; + } else { + return content; + } + }).join(""); + }; + + // import a list of modules into the list + list.i = function(modules, mediaQuery) { + if(typeof modules === "string") + modules = [[null, modules, ""]]; + var alreadyImportedModules = {}; + for(var i = 0; i < this.length; i++) { + var id = this[i][0]; + if(typeof id === "number") + alreadyImportedModules[id] = true; + } + for(i = 0; i < modules.length; i++) { + var item = modules[i]; + // skip already imported module + // this implementation is not 100% perfect for weird media query combinations + // when a module is imported multiple times with different media queries. + // I hope this will never occur (Hey this way we have smaller bundles) + if(typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) { + if(mediaQuery && !item[2]) { + item[2] = mediaQuery; + } else if(mediaQuery) { + item[2] = "(" + item[2] + ") and (" + mediaQuery + ")"; + } + list.push(item); + } + } + }; + return list; }; -function trackInputValue() { - inputValueTracking.track(this); -} +function cssWithMappingToString(item, useSourceMap) { + var content = item[1] || ''; + var cssMapping = item[3]; + if (!cssMapping) { + return content; + } -function trapBubbledEventsLocal() { - var inst = this; - // If a component renders to null or if another component fatals and causes - // the state of the tree to be corrupted, `node` here can be null. - !inst._rootNodeID ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Must be mounted to trap events') : _prodInvariant('63') : void 0; - var node = getNode(inst); - !node ? process.env.NODE_ENV !== 'production' ? invariant(false, 'trapBubbledEvent(...): Requires node to be rendered.') : _prodInvariant('64') : void 0; + if (useSourceMap && typeof btoa === 'function') { + var sourceMapping = toComment(cssMapping); + var sourceURLs = cssMapping.sources.map(function (source) { + return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */' + }); - switch (inst._tag) { - case 'iframe': - case 'object': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; - break; - case 'video': - case 'audio': - inst._wrapperState.listeners = []; - // Create listener for each media event - for (var event in mediaEvents) { - if (mediaEvents.hasOwnProperty(event)) { - inst._wrapperState.listeners.push(ReactBrowserEventEmitter.trapBubbledEvent(event, mediaEvents[event], node)); - } - } - break; - case 'source': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node)]; - break; - case 'img': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node), ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; - break; - case 'form': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topReset', 'reset', node), ReactBrowserEventEmitter.trapBubbledEvent('topSubmit', 'submit', node)]; - break; - case 'input': - case 'select': - case 'textarea': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topInvalid', 'invalid', node)]; - break; - } + return [content].concat(sourceURLs).concat([sourceMapping]).join('\n'); + } + + return [content].join('\n'); } -function postUpdateSelectWrapper() { - ReactDOMSelect.postUpdateWrapper(this); +// Adapted from convert-source-map (MIT) +function toComment(sourceMap) { + // eslint-disable-next-line no-undef + var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))); + var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64; + + return '/*# ' + data + ' */'; } -// For HTML, certain tags should omit their close tag. We keep a whitelist for -// those special-case tags. -var omittedCloseTags = { - area: true, - base: true, - br: true, - col: true, - embed: true, - hr: true, - img: true, - input: true, - keygen: true, - link: true, - meta: true, - param: true, - source: true, - track: true, - wbr: true - // NOTE: menuitem's close tag should be omitted, but that causes problems. -}; +/***/ }), +/* 118 */ +/***/ (function(module, exports, __webpack_require__) { -var newlineEatingTags = { - listing: true, - pre: true, - textarea: true -}; +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ -// For HTML, certain tags cannot have children. This has the same purpose as -// `omittedCloseTags` except that `menuitem` should still have its closing tag. +var stylesInDom = {}; -var voidElementTags = _assign({ - menuitem: true -}, omittedCloseTags); +var memoize = function (fn) { + var memo; -// We accept any tag to be rendered but since this gets injected into arbitrary -// HTML, we want to make sure that it's a safe tag. -// http://www.w3.org/TR/REC-xml/#NT-Name + return function () { + if (typeof memo === "undefined") memo = fn.apply(this, arguments); + return memo; + }; +}; -var VALID_TAG_REGEX = /^[a-zA-Z][a-zA-Z:_\.\-\d]*$/; // Simplified subset -var validatedTagCache = {}; -var hasOwnProperty = {}.hasOwnProperty; +var isOldIE = memoize(function () { + // Test for IE <= 9 as proposed by Browserhacks + // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805 + // Tests for existence of standard globals is to allow style-loader + // to operate correctly into non-standard environments + // @see https://github.com/webpack-contrib/style-loader/issues/177 + return window && document && document.all && !window.atob; +}); -function validateDangerousTag(tag) { - if (!hasOwnProperty.call(validatedTagCache, tag)) { - !VALID_TAG_REGEX.test(tag) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Invalid tag: %s', tag) : _prodInvariant('65', tag) : void 0; - validatedTagCache[tag] = true; - } -} +var getElement = (function (fn) { + var memo = {}; -function isCustomComponent(tagName, props) { - return tagName.indexOf('-') >= 0 || props.is != null; -} + return function(selector) { + if (typeof memo[selector] === "undefined") { + memo[selector] = fn.call(this, selector); + } -var globalIdCounter = 1; + return memo[selector] + }; +})(function (target) { + return document.querySelector(target) +}); -/** - * Creates a new React class that is idempotent and capable of containing other - * React components. It accepts event listeners and DOM properties that are - * valid according to `DOMProperty`. - * - * - Event listeners: `onClick`, `onMouseDown`, etc. - * - DOM properties: `className`, `name`, `title`, etc. - * - * The `style` property functions differently from the DOM API. It accepts an - * object mapping of style properties to values. - * - * @constructor ReactDOMComponent - * @extends ReactMultiChild - */ -function ReactDOMComponent(element) { - var tag = element.type; - validateDangerousTag(tag); - this._currentElement = element; - this._tag = tag.toLowerCase(); - this._namespaceURI = null; - this._renderedChildren = null; - this._previousStyle = null; - this._previousStyleCopy = null; - this._hostNode = null; - this._hostParent = null; - this._rootNodeID = 0; - this._domID = 0; - this._hostContainerInfo = null; - this._wrapperState = null; - this._topLevelWrapper = null; - this._flags = 0; - if (process.env.NODE_ENV !== 'production') { - this._ancestorInfo = null; - setAndValidateContentChildDev.call(this, null); - } -} +var singleton = null; +var singletonCounter = 0; +var stylesInsertedAtTop = []; -ReactDOMComponent.displayName = 'ReactDOMComponent'; +var fixUrls = __webpack_require__(213); -ReactDOMComponent.Mixin = { - /** - * Generates root tag markup then recurses. This method has side effects and - * is not idempotent. - * - * @internal - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?ReactDOMComponent} the parent component instance - * @param {?object} info about the host container - * @param {object} context - * @return {string} The computed markup. - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - this._rootNodeID = globalIdCounter++; - this._domID = hostContainerInfo._idCounter++; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; +module.exports = function(list, options) { + if (typeof DEBUG !== "undefined" && DEBUG) { + if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment"); + } - var props = this._currentElement.props; + options = options || {}; - switch (this._tag) { - case 'audio': - case 'form': - case 'iframe': - case 'img': - case 'link': - case 'object': - case 'source': - case 'video': - this._wrapperState = { - listeners: null - }; - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'input': - ReactDOMInput.mountWrapper(this, props, hostParent); - props = ReactDOMInput.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trackInputValue, this); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'option': - ReactDOMOption.mountWrapper(this, props, hostParent); - props = ReactDOMOption.getHostProps(this, props); - break; - case 'select': - ReactDOMSelect.mountWrapper(this, props, hostParent); - props = ReactDOMSelect.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'textarea': - ReactDOMTextarea.mountWrapper(this, props, hostParent); - props = ReactDOMTextarea.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trackInputValue, this); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - } + options.attrs = typeof options.attrs === "object" ? options.attrs : {}; - assertValidProps(this, props); + // Force single-tag solution on IE6-9, which has a hard limit on the # of <style> + // tags it will allow on a page + if (!options.singleton) options.singleton = isOldIE(); - // We create tags in the namespace of their parent container, except HTML - // tags get no namespace. - var namespaceURI; - var parentTag; - if (hostParent != null) { - namespaceURI = hostParent._namespaceURI; - parentTag = hostParent._tag; - } else if (hostContainerInfo._tag) { - namespaceURI = hostContainerInfo._namespaceURI; - parentTag = hostContainerInfo._tag; - } - if (namespaceURI == null || namespaceURI === DOMNamespaces.svg && parentTag === 'foreignobject') { - namespaceURI = DOMNamespaces.html; - } - if (namespaceURI === DOMNamespaces.html) { - if (this._tag === 'svg') { - namespaceURI = DOMNamespaces.svg; - } else if (this._tag === 'math') { - namespaceURI = DOMNamespaces.mathml; - } - } - this._namespaceURI = namespaceURI; + // By default, add <style> tags to the <head> element + if (!options.insertInto) options.insertInto = "head"; - if (process.env.NODE_ENV !== 'production') { - var parentInfo; - if (hostParent != null) { - parentInfo = hostParent._ancestorInfo; - } else if (hostContainerInfo._tag) { - parentInfo = hostContainerInfo._ancestorInfo; - } - if (parentInfo) { - // parentInfo should always be present except for the top-level - // component when server rendering - validateDOMNesting(this._tag, null, this, parentInfo); - } - this._ancestorInfo = validateDOMNesting.updatedAncestorInfo(parentInfo, this._tag, this); - } + // By default, add <style> tags to the bottom of the target + if (!options.insertAt) options.insertAt = "bottom"; - var mountImage; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var el; - if (namespaceURI === DOMNamespaces.html) { - if (this._tag === 'script') { - // Create the script via .innerHTML so its "parser-inserted" flag is - // set to true and it does not execute - var div = ownerDocument.createElement('div'); - var type = this._currentElement.type; - div.innerHTML = '<' + type + '></' + type + '>'; - el = div.removeChild(div.firstChild); - } else if (props.is) { - el = ownerDocument.createElement(this._currentElement.type, props.is); - } else { - // Separate else branch instead of using `props.is || undefined` above becuase of a Firefox bug. - // See discussion in https://github.com/facebook/react/pull/6896 - // and discussion in https://bugzilla.mozilla.org/show_bug.cgi?id=1276240 - el = ownerDocument.createElement(this._currentElement.type); - } - } else { - el = ownerDocument.createElementNS(namespaceURI, this._currentElement.type); - } - ReactDOMComponentTree.precacheNode(this, el); - this._flags |= Flags.hasCachedChildNodes; - if (!this._hostParent) { - DOMPropertyOperations.setAttributeForRoot(el); - } - this._updateDOMProperties(null, props, transaction); - var lazyTree = DOMLazyTree(el); - this._createInitialChildren(transaction, props, context, lazyTree); - mountImage = lazyTree; - } else { - var tagOpen = this._createOpenTagMarkupAndPutListeners(transaction, props); - var tagContent = this._createContentMarkup(transaction, props, context); - if (!tagContent && omittedCloseTags[this._tag]) { - mountImage = tagOpen + '/>'; - } else { - mountImage = tagOpen + '>' + tagContent + '</' + this._currentElement.type + '>'; - } - } + var styles = listToStyles(list, options); - switch (this._tag) { - case 'input': - transaction.getReactMountReady().enqueue(inputPostMount, this); - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'textarea': - transaction.getReactMountReady().enqueue(textareaPostMount, this); - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'select': - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'button': - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'option': - transaction.getReactMountReady().enqueue(optionPostMount, this); - break; - } + addStylesToDom(styles, options); - return mountImage; - }, + return function update (newList) { + var mayRemove = []; - /** - * Creates markup for the open tag and all attributes. - * - * This method has side effects because events get registered. - * - * Iterating over object properties is faster than iterating over arrays. - * @see http://jsperf.com/obj-vs-arr-iteration - * - * @private - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} props - * @return {string} Markup of opening tag. - */ - _createOpenTagMarkupAndPutListeners: function (transaction, props) { - var ret = '<' + this._currentElement.type; + for (var i = 0; i < styles.length; i++) { + var item = styles[i]; + var domStyle = stylesInDom[item.id]; - for (var propKey in props) { - if (!props.hasOwnProperty(propKey)) { - continue; - } - var propValue = props[propKey]; - if (propValue == null) { - continue; - } - if (registrationNameModules.hasOwnProperty(propKey)) { - if (propValue) { - enqueuePutListener(this, propKey, propValue, transaction); - } - } else { - if (propKey === STYLE) { - if (propValue) { - if (process.env.NODE_ENV !== 'production') { - // See `_updateDOMProperties`. style block - this._previousStyle = propValue; - } - propValue = this._previousStyleCopy = _assign({}, props.style); - } - propValue = CSSPropertyOperations.createMarkupForStyles(propValue, this); - } - var markup = null; - if (this._tag != null && isCustomComponent(this._tag, props)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - markup = DOMPropertyOperations.createMarkupForCustomAttribute(propKey, propValue); - } - } else { - markup = DOMPropertyOperations.createMarkupForProperty(propKey, propValue); - } - if (markup) { - ret += ' ' + markup; - } - } - } + domStyle.refs--; + mayRemove.push(domStyle); + } - // For static pages, no need to put React ID and checksum. Saves lots of - // bytes. - if (transaction.renderToStaticMarkup) { - return ret; - } + if(newList) { + var newStyles = listToStyles(newList, options); + addStylesToDom(newStyles, options); + } - if (!this._hostParent) { - ret += ' ' + DOMPropertyOperations.createMarkupForRoot(); - } - ret += ' ' + DOMPropertyOperations.createMarkupForID(this._domID); - return ret; - }, + for (var i = 0; i < mayRemove.length; i++) { + var domStyle = mayRemove[i]; - /** - * Creates markup for the content between the tags. - * - * @private - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} props - * @param {object} context - * @return {string} Content markup. - */ - _createContentMarkup: function (transaction, props, context) { - var ret = ''; + if(domStyle.refs === 0) { + for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](); - // Intentional use of != to avoid catching zero/false. - var innerHTML = props.dangerouslySetInnerHTML; + delete stylesInDom[domStyle.id]; + } + } + }; +}; + +function addStylesToDom (styles, options) { + for (var i = 0; i < styles.length; i++) { + var item = styles[i]; + var domStyle = stylesInDom[item.id]; + + if(domStyle) { + domStyle.refs++; + + for(var j = 0; j < domStyle.parts.length; j++) { + domStyle.parts[j](item.parts[j]); + } + + for(; j < item.parts.length; j++) { + domStyle.parts.push(addStyle(item.parts[j], options)); + } + } else { + var parts = []; + + for(var j = 0; j < item.parts.length; j++) { + parts.push(addStyle(item.parts[j], options)); + } + + stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts}; + } + } +} + +function listToStyles (list, options) { + var styles = []; + var newStyles = {}; + + for (var i = 0; i < list.length; i++) { + var item = list[i]; + var id = options.base ? item[0] + options.base : item[0]; + var css = item[1]; + var media = item[2]; + var sourceMap = item[3]; + var part = {css: css, media: media, sourceMap: sourceMap}; + + if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]}); + else newStyles[id].parts.push(part); + } + + return styles; +} + +function insertStyleElement (options, style) { + var target = getElement(options.insertInto) + + if (!target) { + throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid."); + } + + var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1]; + + if (options.insertAt === "top") { + if (!lastStyleElementInsertedAtTop) { + target.insertBefore(style, target.firstChild); + } else if (lastStyleElementInsertedAtTop.nextSibling) { + target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling); + } else { + target.appendChild(style); + } + stylesInsertedAtTop.push(style); + } else if (options.insertAt === "bottom") { + target.appendChild(style); + } else { + throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'."); + } +} + +function removeStyleElement (style) { + if (style.parentNode === null) return false; + style.parentNode.removeChild(style); + + var idx = stylesInsertedAtTop.indexOf(style); + if(idx >= 0) { + stylesInsertedAtTop.splice(idx, 1); + } +} + +function createStyleElement (options) { + var style = document.createElement("style"); + + options.attrs.type = "text/css"; + + addAttrs(style, options.attrs); + insertStyleElement(options, style); + + return style; +} + +function createLinkElement (options) { + var link = document.createElement("link"); + + options.attrs.type = "text/css"; + options.attrs.rel = "stylesheet"; + + addAttrs(link, options.attrs); + insertStyleElement(options, link); + + return link; +} + +function addAttrs (el, attrs) { + Object.keys(attrs).forEach(function (key) { + el.setAttribute(key, attrs[key]); + }); +} + +function addStyle (obj, options) { + var style, update, remove, result; + + // If a transform function was defined, run it on the css + if (options.transform && obj.css) { + result = options.transform(obj.css); + + if (result) { + // If transform returns a value, use that instead of the original css. + // This allows running runtime transformations on the css. + obj.css = result; + } else { + // If the transform function returns a falsy value, don't add this css. + // This allows conditional loading of css + return function() { + // noop + }; + } + } + + if (options.singleton) { + var styleIndex = singletonCounter++; + + style = singleton || (singleton = createStyleElement(options)); + + update = applyToSingletonTag.bind(null, style, styleIndex, false); + remove = applyToSingletonTag.bind(null, style, styleIndex, true); + + } else if ( + obj.sourceMap && + typeof URL === "function" && + typeof URL.createObjectURL === "function" && + typeof URL.revokeObjectURL === "function" && + typeof Blob === "function" && + typeof btoa === "function" + ) { + style = createLinkElement(options); + update = updateLink.bind(null, style, options); + remove = function () { + removeStyleElement(style); + + if(style.href) URL.revokeObjectURL(style.href); + }; + } else { + style = createStyleElement(options); + update = applyToTag.bind(null, style); + remove = function () { + removeStyleElement(style); + }; + } + + update(obj); + + return function updateStyle (newObj) { + if (newObj) { + if ( + newObj.css === obj.css && + newObj.media === obj.media && + newObj.sourceMap === obj.sourceMap + ) { + return; + } + + update(obj = newObj); + } else { + remove(); + } + }; +} + +var replaceText = (function () { + var textStore = []; + + return function (index, replacement) { + textStore[index] = replacement; + + return textStore.filter(Boolean).join('\n'); + }; +})(); + +function applyToSingletonTag (style, index, remove, obj) { + var css = remove ? "" : obj.css; + + if (style.styleSheet) { + style.styleSheet.cssText = replaceText(index, css); + } else { + var cssNode = document.createTextNode(css); + var childNodes = style.childNodes; + + if (childNodes[index]) style.removeChild(childNodes[index]); + + if (childNodes.length) { + style.insertBefore(cssNode, childNodes[index]); + } else { + style.appendChild(cssNode); + } + } +} + +function applyToTag (style, obj) { + var css = obj.css; + var media = obj.media; + + if(media) { + style.setAttribute("media", media) + } + + if(style.styleSheet) { + style.styleSheet.cssText = css; + } else { + while(style.firstChild) { + style.removeChild(style.firstChild); + } + + style.appendChild(document.createTextNode(css)); + } +} + +function updateLink (link, options, obj) { + var css = obj.css; + var sourceMap = obj.sourceMap; + + /* + If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled + and there is no publicPath defined then lets turn convertToAbsoluteUrls + on by default. Otherwise default to the convertToAbsoluteUrls option + directly + */ + var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap; + + if (options.convertToAbsoluteUrls || autoFixUrls) { + css = fixUrls(css); + } + + if (sourceMap) { + // http://stackoverflow.com/a/26603875 + css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */"; + } + + var blob = new Blob([css], { type: "text/css" }); + + var oldSrc = link.href; + + link.href = URL.createObjectURL(blob); + + if(oldSrc) URL.revokeObjectURL(oldSrc); +} + + +/***/ }), +/* 119 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(37), + _assign = __webpack_require__(8); + +var ReactNoopUpdateQueue = __webpack_require__(120); + +var canDefineProperty = __webpack_require__(55); +var emptyObject = __webpack_require__(56); +var invariant = __webpack_require__(2); +var lowPriorityWarning = __webpack_require__(74); + +/** + * Base class helpers for the updating state of a component. + */ +function ReactComponent(props, context, updater) { + this.props = props; + this.context = context; + this.refs = emptyObject; + // We initialize the default updater but the real one gets injected by the + // renderer. + this.updater = updater || ReactNoopUpdateQueue; +} + +ReactComponent.prototype.isReactComponent = {}; + +/** + * Sets a subset of the state. Always use this to mutate + * state. You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * There is no guarantee that calls to `setState` will run synchronously, + * as they may eventually be batched together. You can provide an optional + * callback that will be executed when the call to setState is actually + * completed. + * + * When a function is provided to setState, it will be called at some point in + * the future (not synchronously). It will be called with the up to date + * component arguments (state, props, context). These values can be different + * from this.* because your function may be called after receiveProps but before + * shouldComponentUpdate, and this new state, props, and context will not yet be + * assigned to this. + * + * @param {object|function} partialState Next partial state or function to + * produce next partial state to be merged with current state. + * @param {?function} callback Called after state is updated. + * @final + * @protected + */ +ReactComponent.prototype.setState = function (partialState, callback) { + !(typeof partialState === 'object' || typeof partialState === 'function' || partialState == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.') : _prodInvariant('85') : void 0; + this.updater.enqueueSetState(this, partialState); + if (callback) { + this.updater.enqueueCallback(this, callback, 'setState'); + } +}; + +/** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {?function} callback Called after update is complete. + * @final + * @protected + */ +ReactComponent.prototype.forceUpdate = function (callback) { + this.updater.enqueueForceUpdate(this); + if (callback) { + this.updater.enqueueCallback(this, callback, 'forceUpdate'); + } +}; + +/** + * Deprecated APIs. These APIs used to exist on classic React classes but since + * we would like to deprecate them, we're not going to move them over to this + * modern base class. Instead, we define a getter that warns if it's accessed. + */ +if (process.env.NODE_ENV !== 'production') { + var deprecatedAPIs = { + isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'], + replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).'] + }; + var defineDeprecationWarning = function (methodName, info) { + if (canDefineProperty) { + Object.defineProperty(ReactComponent.prototype, methodName, { + get: function () { + lowPriorityWarning(false, '%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]); + return undefined; + } + }); + } + }; + for (var fnName in deprecatedAPIs) { + if (deprecatedAPIs.hasOwnProperty(fnName)) { + defineDeprecationWarning(fnName, deprecatedAPIs[fnName]); + } + } +} + +/** + * Base class helpers for the updating state of a component. + */ +function ReactPureComponent(props, context, updater) { + // Duplicated from ReactComponent. + this.props = props; + this.context = context; + this.refs = emptyObject; + // We initialize the default updater but the real one gets injected by the + // renderer. + this.updater = updater || ReactNoopUpdateQueue; +} + +function ComponentDummy() {} +ComponentDummy.prototype = ReactComponent.prototype; +ReactPureComponent.prototype = new ComponentDummy(); +ReactPureComponent.prototype.constructor = ReactPureComponent; +// Avoid an extra prototype jump for these methods. +_assign(ReactPureComponent.prototype, ReactComponent.prototype); +ReactPureComponent.prototype.isPureReactComponent = true; + +module.exports = { + Component: ReactComponent, + PureComponent: ReactPureComponent +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 120 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var warning = __webpack_require__(3); + +function warnNoop(publicInstance, callerName) { + if (process.env.NODE_ENV !== 'production') { + var constructor = publicInstance.constructor; + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; + } +} + +/** + * This is the abstract API for an update queue. + */ +var ReactNoopUpdateQueue = { + /** + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + isMounted: function (publicInstance) { + return false; + }, + + /** + * Enqueue a callback that will be executed after all the pending updates + * have processed. + * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @internal + */ + enqueueCallback: function (publicInstance, callback) {}, + + /** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal + */ + enqueueForceUpdate: function (publicInstance) { + warnNoop(publicInstance, 'forceUpdate'); + }, + + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} completeState Next state. + * @internal + */ + enqueueReplaceState: function (publicInstance, completeState) { + warnNoop(publicInstance, 'replaceState'); + }, + + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} partialState Next partial state to be merged with state. + * @internal + */ + enqueueSetState: function (publicInstance, partialState) { + warnNoop(publicInstance, 'setState'); + } +}; + +module.exports = ReactNoopUpdateQueue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 121 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +// The Symbol used to tag the ReactElement type. If there is no native Symbol +// nor polyfill, then a plain number is used for performance. + +var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; + +module.exports = REACT_ELEMENT_TYPE; + +/***/ }), +/* 122 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/* global Symbol */ + +var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; +var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. + +/** + * Returns the iterator method function contained on the iterable object. + * + * Be sure to invoke the function with the iterable as context: + * + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} + */ +function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } +} + +module.exports = getIteratorFn; + +/***/ }), +/* 123 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/** + * ReactElementValidator provides a wrapper around a element factory + * which validates the props passed to the element. This is intended to be + * used only in DEV and could be replaced by a static type checker for languages + * that support it. + */ + + + +var ReactCurrentOwner = __webpack_require__(22); +var ReactComponentTreeHook = __webpack_require__(17); +var ReactElement = __webpack_require__(31); + +var checkReactTypeSpec = __webpack_require__(221); + +var canDefineProperty = __webpack_require__(55); +var getIteratorFn = __webpack_require__(122); +var warning = __webpack_require__(3); +var lowPriorityWarning = __webpack_require__(74); + +function getDeclarationErrorAddendum() { + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} + +function getSourceInfoErrorAddendum(elementProps) { + if (elementProps !== null && elementProps !== undefined && elementProps.__source !== undefined) { + var source = elementProps.__source; + var fileName = source.fileName.replace(/^.*[\\\/]/, ''); + var lineNumber = source.lineNumber; + return ' Check your code at ' + fileName + ':' + lineNumber + '.'; + } + return ''; +} + +/** + * Warn if there's no key explicitly set on dynamic arrays of children or + * object keys are not valid. This allows us to keep track of children between + * updates. + */ +var ownerHasKeyUseWarning = {}; + +function getCurrentComponentErrorInfo(parentType) { + var info = getDeclarationErrorAddendum(); + + if (!info) { + var parentName = typeof parentType === 'string' ? parentType : parentType.displayName || parentType.name; + if (parentName) { + info = ' Check the top-level render call using <' + parentName + '>.'; + } + } + return info; +} + +/** + * Warn if the element doesn't have an explicit key assigned to it. + * This element is in an array. The array could grow and shrink or be + * reordered. All children that haven't already been validated are required to + * have a "key" property assigned to it. Error statuses are cached so a warning + * will only be shown once. + * + * @internal + * @param {ReactElement} element Element that requires a key. + * @param {*} parentType element's parent's type. + */ +function validateExplicitKey(element, parentType) { + if (!element._store || element._store.validated || element.key != null) { + return; + } + element._store.validated = true; + + var memoizer = ownerHasKeyUseWarning.uniqueKey || (ownerHasKeyUseWarning.uniqueKey = {}); + + var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType); + if (memoizer[currentComponentErrorInfo]) { + return; + } + memoizer[currentComponentErrorInfo] = true; + + // Usually the current owner is the offender, but if it accepts children as a + // property, it may be the creator of the child that's responsible for + // assigning it a key. + var childOwner = ''; + if (element && element._owner && element._owner !== ReactCurrentOwner.current) { + // Give the component that originally created this child. + childOwner = ' It was passed a child from ' + element._owner.getName() + '.'; + } + + process.env.NODE_ENV !== 'production' ? warning(false, 'Each child in an array or iterator should have a unique "key" prop.' + '%s%s See https://fb.me/react-warning-keys for more information.%s', currentComponentErrorInfo, childOwner, ReactComponentTreeHook.getCurrentStackAddendum(element)) : void 0; +} + +/** + * Ensure that every element either is passed in a static location, in an + * array with an explicit keys property defined, or in an object literal + * with valid key property. + * + * @internal + * @param {ReactNode} node Statically passed child of any type. + * @param {*} parentType node's parent's type. + */ +function validateChildKeys(node, parentType) { + if (typeof node !== 'object') { + return; + } + if (Array.isArray(node)) { + for (var i = 0; i < node.length; i++) { + var child = node[i]; + if (ReactElement.isValidElement(child)) { + validateExplicitKey(child, parentType); + } + } + } else if (ReactElement.isValidElement(node)) { + // This element was passed in a valid location. + if (node._store) { + node._store.validated = true; + } + } else if (node) { + var iteratorFn = getIteratorFn(node); + // Entry iterators provide implicit keys. + if (iteratorFn) { + if (iteratorFn !== node.entries) { + var iterator = iteratorFn.call(node); + var step; + while (!(step = iterator.next()).done) { + if (ReactElement.isValidElement(step.value)) { + validateExplicitKey(step.value, parentType); + } + } + } + } + } +} + +/** + * Given an element, validate that its props follow the propTypes definition, + * provided by the type. + * + * @param {ReactElement} element + */ +function validatePropTypes(element) { + var componentClass = element.type; + if (typeof componentClass !== 'function') { + return; + } + var name = componentClass.displayName || componentClass.name; + if (componentClass.propTypes) { + checkReactTypeSpec(componentClass.propTypes, element.props, 'prop', name, element, null); + } + if (typeof componentClass.getDefaultProps === 'function') { + process.env.NODE_ENV !== 'production' ? warning(componentClass.getDefaultProps.isReactClassApproved, 'getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.') : void 0; + } +} + +var ReactElementValidator = { + createElement: function (type, props, children) { + var validType = typeof type === 'string' || typeof type === 'function'; + // We warn in this case but don't throw. We expect the element creation to + // succeed and there will likely be errors in render. + if (!validType) { + if (typeof type !== 'function' && typeof type !== 'string') { + var info = ''; + if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { + info += ' You likely forgot to export your component from the file ' + "it's defined in."; + } + + var sourceInfo = getSourceInfoErrorAddendum(props); + if (sourceInfo) { + info += sourceInfo; + } else { + info += getDeclarationErrorAddendum(); + } + + info += ReactComponentTreeHook.getCurrentStackAddendum(); + + var currentSource = props !== null && props !== undefined && props.__source !== undefined ? props.__source : null; + ReactComponentTreeHook.pushNonStandardWarningStack(true, currentSource); + process.env.NODE_ENV !== 'production' ? warning(false, 'React.createElement: type is invalid -- expected a string (for ' + 'built-in components) or a class/function (for composite ' + 'components) but got: %s.%s', type == null ? type : typeof type, info) : void 0; + ReactComponentTreeHook.popNonStandardWarningStack(); + } + } + + var element = ReactElement.createElement.apply(this, arguments); + + // The result can be nullish if a mock or a custom function is used. + // TODO: Drop this when these are no longer allowed as the type argument. + if (element == null) { + return element; + } + + // Skip key warning if the type isn't valid since our key validation logic + // doesn't expect a non-string/function type and can throw confusing errors. + // We don't want exception behavior to differ between dev and prod. + // (Rendering will throw with a helpful message and as soon as the type is + // fixed, the key warnings will appear.) + if (validType) { + for (var i = 2; i < arguments.length; i++) { + validateChildKeys(arguments[i], type); + } + } + + validatePropTypes(element); + + return element; + }, + + createFactory: function (type) { + var validatedFactory = ReactElementValidator.createElement.bind(null, type); + // Legacy hook TODO: Warn if this is accessed + validatedFactory.type = type; + + if (process.env.NODE_ENV !== 'production') { + if (canDefineProperty) { + Object.defineProperty(validatedFactory, 'type', { + enumerable: false, + get: function () { + lowPriorityWarning(false, 'Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.'); + Object.defineProperty(this, 'type', { + value: type + }); + return type; + } + }); + } + } + + return validatedFactory; + }, + + cloneElement: function (element, props, children) { + var newElement = ReactElement.cloneElement.apply(this, arguments); + for (var i = 2; i < arguments.length; i++) { + validateChildKeys(arguments[i], newElement.type); + } + validatePropTypes(newElement); + return newElement; + } +}; + +module.exports = ReactElementValidator; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 124 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +// React 15.5 references this module, and assumes PropTypes are still callable in production. +// Therefore we re-export development-only version with all the PropTypes checks here. +// However if one is migrating to the `prop-types` npm library, they will go through the +// `index.js` entry point, and it will branch depending on the environment. +var factory = __webpack_require__(125); +module.exports = function(isValidElement) { + // It is still allowed in 15.5. + var throwOnDirectAccess = false; + return factory(isValidElement, throwOnDirectAccess); +}; + + +/***/ }), +/* 125 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var ReactPropTypesSecret = __webpack_require__(75); +var checkPropTypes = __webpack_require__(225); + +module.exports = function(isValidElement, throwOnDirectAccess) { + /* global Symbol */ + var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; + var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. + + /** + * Returns the iterator method function contained on the iterable object. + * + * Be sure to invoke the function with the iterable as context: + * + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} + */ + function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } + } + + /** + * Collection of methods that allow declaration and validation of props that are + * supplied to React components. Example usage: + * + * var Props = require('ReactPropTypes'); + * var MyArticle = React.createClass({ + * propTypes: { + * // An optional string prop named "description". + * description: Props.string, + * + * // A required enum prop named "category". + * category: Props.oneOf(['News','Photos']).isRequired, + * + * // A prop named "dialog" that requires an instance of Dialog. + * dialog: Props.instanceOf(Dialog).isRequired + * }, + * render: function() { ... } + * }); + * + * A more formal specification of how these methods are used: + * + * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...) + * decl := ReactPropTypes.{type}(.isRequired)? + * + * Each and every declaration produces a function with the same signature. This + * allows the creation of custom validation functions. For example: + * + * var MyLink = React.createClass({ + * propTypes: { + * // An optional string or URI prop named "href". + * href: function(props, propName, componentName) { + * var propValue = props[propName]; + * if (propValue != null && typeof propValue !== 'string' && + * !(propValue instanceof URI)) { + * return new Error( + * 'Expected a string or an URI for ' + propName + ' in ' + + * componentName + * ); + * } + * } + * }, + * render: function() {...} + * }); + * + * @internal + */ + + var ANONYMOUS = '<<anonymous>>'; + + // Important! + // Keep this list in sync with production version in `./factoryWithThrowingShims.js`. + var ReactPropTypes = { + array: createPrimitiveTypeChecker('array'), + bool: createPrimitiveTypeChecker('boolean'), + func: createPrimitiveTypeChecker('function'), + number: createPrimitiveTypeChecker('number'), + object: createPrimitiveTypeChecker('object'), + string: createPrimitiveTypeChecker('string'), + symbol: createPrimitiveTypeChecker('symbol'), + + any: createAnyTypeChecker(), + arrayOf: createArrayOfTypeChecker, + element: createElementTypeChecker(), + instanceOf: createInstanceTypeChecker, + node: createNodeChecker(), + objectOf: createObjectOfTypeChecker, + oneOf: createEnumTypeChecker, + oneOfType: createUnionTypeChecker, + shape: createShapeTypeChecker + }; + + /** + * inlined Object.is polyfill to avoid requiring consumers ship their own + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is + */ + /*eslint-disable no-self-compare*/ + function is(x, y) { + // SameValue algorithm + if (x === y) { + // Steps 1-5, 7-10 + // Steps 6.b-6.e: +0 != -0 + return x !== 0 || 1 / x === 1 / y; + } else { + // Step 6.a: NaN == NaN + return x !== x && y !== y; + } + } + /*eslint-enable no-self-compare*/ + + /** + * We use an Error-like object for backward compatibility as people may call + * PropTypes directly and inspect their output. However, we don't use real + * Errors anymore. We don't inspect their stack anyway, and creating them + * is prohibitively expensive if they are created too often, such as what + * happens in oneOfType() for any type before the one that matched. + */ + function PropTypeError(message) { + this.message = message; + this.stack = ''; + } + // Make `instanceof Error` still work for returned errors. + PropTypeError.prototype = Error.prototype; + + function createChainableTypeChecker(validate) { + if (process.env.NODE_ENV !== 'production') { + var manualPropTypeCallCache = {}; + var manualPropTypeWarningCount = 0; + } + function checkType(isRequired, props, propName, componentName, location, propFullName, secret) { + componentName = componentName || ANONYMOUS; + propFullName = propFullName || propName; + + if (secret !== ReactPropTypesSecret) { + if (throwOnDirectAccess) { + // New behavior only for users of `prop-types` package + invariant( + false, + 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + + 'Use `PropTypes.checkPropTypes()` to call them. ' + + 'Read more at http://fb.me/use-check-prop-types' + ); + } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') { + // Old behavior for people using React.PropTypes + var cacheKey = componentName + ':' + propName; + if ( + !manualPropTypeCallCache[cacheKey] && + // Avoid spamming the console because they are often not actionable except for lib authors + manualPropTypeWarningCount < 3 + ) { + warning( + false, + 'You are manually calling a React.PropTypes validation ' + + 'function for the `%s` prop on `%s`. This is deprecated ' + + 'and will throw in the standalone `prop-types` package. ' + + 'You may be seeing this warning due to a third-party PropTypes ' + + 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.', + propFullName, + componentName + ); + manualPropTypeCallCache[cacheKey] = true; + manualPropTypeWarningCount++; + } + } + } + if (props[propName] == null) { + if (isRequired) { + if (props[propName] === null) { + return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.')); + } + return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.')); + } + return null; + } else { + return validate(props, propName, componentName, location, propFullName); + } + } + + var chainedCheckType = checkType.bind(null, false); + chainedCheckType.isRequired = checkType.bind(null, true); + + return chainedCheckType; + } + + function createPrimitiveTypeChecker(expectedType) { + function validate(props, propName, componentName, location, propFullName, secret) { + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== expectedType) { + // `propValue` being instance of, say, date/regexp, pass the 'object' + // check, but we can offer a more precise error message here rather than + // 'of type `object`'. + var preciseType = getPreciseType(propValue); + + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.')); + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createAnyTypeChecker() { + return createChainableTypeChecker(emptyFunction.thatReturnsNull); + } + + function createArrayOfTypeChecker(typeChecker) { + function validate(props, propName, componentName, location, propFullName) { + if (typeof typeChecker !== 'function') { + return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.'); + } + var propValue = props[propName]; + if (!Array.isArray(propValue)) { + var propType = getPropType(propValue); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.')); + } + for (var i = 0; i < propValue.length; i++) { + var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret); + if (error instanceof Error) { + return error; + } + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createElementTypeChecker() { + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + if (!isValidElement(propValue)) { + var propType = getPropType(propValue); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.')); + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createInstanceTypeChecker(expectedClass) { + function validate(props, propName, componentName, location, propFullName) { + if (!(props[propName] instanceof expectedClass)) { + var expectedClassName = expectedClass.name || ANONYMOUS; + var actualClassName = getClassName(props[propName]); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.')); + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createEnumTypeChecker(expectedValues) { + if (!Array.isArray(expectedValues)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOf, expected an instance of array.') : void 0; + return emptyFunction.thatReturnsNull; + } + + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + for (var i = 0; i < expectedValues.length; i++) { + if (is(propValue, expectedValues[i])) { + return null; + } + } + + var valuesString = JSON.stringify(expectedValues); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + propValue + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.')); + } + return createChainableTypeChecker(validate); + } + + function createObjectOfTypeChecker(typeChecker) { + function validate(props, propName, componentName, location, propFullName) { + if (typeof typeChecker !== 'function') { + return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.'); + } + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== 'object') { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.')); + } + for (var key in propValue) { + if (propValue.hasOwnProperty(key)) { + var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); + if (error instanceof Error) { + return error; + } + } + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createUnionTypeChecker(arrayOfTypeCheckers) { + if (!Array.isArray(arrayOfTypeCheckers)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOfType, expected an instance of array.') : void 0; + return emptyFunction.thatReturnsNull; + } + + for (var i = 0; i < arrayOfTypeCheckers.length; i++) { + var checker = arrayOfTypeCheckers[i]; + if (typeof checker !== 'function') { + warning( + false, + 'Invalid argument supplid to oneOfType. Expected an array of check functions, but ' + + 'received %s at index %s.', + getPostfixForTypeWarning(checker), + i + ); + return emptyFunction.thatReturnsNull; + } + } + + function validate(props, propName, componentName, location, propFullName) { + for (var i = 0; i < arrayOfTypeCheckers.length; i++) { + var checker = arrayOfTypeCheckers[i]; + if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) { + return null; + } + } + + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.')); + } + return createChainableTypeChecker(validate); + } + + function createNodeChecker() { + function validate(props, propName, componentName, location, propFullName) { + if (!isNode(props[propName])) { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.')); + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createShapeTypeChecker(shapeTypes) { + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== 'object') { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.')); + } + for (var key in shapeTypes) { + var checker = shapeTypes[key]; + if (!checker) { + continue; + } + var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); + if (error) { + return error; + } + } + return null; + } + return createChainableTypeChecker(validate); + } + + function isNode(propValue) { + switch (typeof propValue) { + case 'number': + case 'string': + case 'undefined': + return true; + case 'boolean': + return !propValue; + case 'object': + if (Array.isArray(propValue)) { + return propValue.every(isNode); + } + if (propValue === null || isValidElement(propValue)) { + return true; + } + + var iteratorFn = getIteratorFn(propValue); + if (iteratorFn) { + var iterator = iteratorFn.call(propValue); + var step; + if (iteratorFn !== propValue.entries) { + while (!(step = iterator.next()).done) { + if (!isNode(step.value)) { + return false; + } + } + } else { + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + if (!isNode(entry[1])) { + return false; + } + } + } + } + } else { + return false; + } + + return true; + default: + return false; + } + } + + function isSymbol(propType, propValue) { + // Native Symbol. + if (propType === 'symbol') { + return true; + } + + // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol' + if (propValue['@@toStringTag'] === 'Symbol') { + return true; + } + + // Fallback for non-spec compliant Symbols which are polyfilled. + if (typeof Symbol === 'function' && propValue instanceof Symbol) { + return true; + } + + return false; + } + + // Equivalent of `typeof` but with special handling for array and regexp. + function getPropType(propValue) { + var propType = typeof propValue; + if (Array.isArray(propValue)) { + return 'array'; + } + if (propValue instanceof RegExp) { + // Old webkits (at least until Android 4.0) return 'function' rather than + // 'object' for typeof a RegExp. We'll normalize this here so that /bla/ + // passes PropTypes.object. + return 'object'; + } + if (isSymbol(propType, propValue)) { + return 'symbol'; + } + return propType; + } + + // This handles more types than `getPropType`. Only used for error messages. + // See `createPrimitiveTypeChecker`. + function getPreciseType(propValue) { + if (typeof propValue === 'undefined' || propValue === null) { + return '' + propValue; + } + var propType = getPropType(propValue); + if (propType === 'object') { + if (propValue instanceof Date) { + return 'date'; + } else if (propValue instanceof RegExp) { + return 'regexp'; + } + } + return propType; + } + + // Returns a string that is postfixed to a warning about an invalid type. + // For example, "undefined" or "of type array" + function getPostfixForTypeWarning(value) { + var type = getPreciseType(value); + switch (type) { + case 'array': + case 'object': + return 'an ' + type; + case 'boolean': + case 'date': + case 'regexp': + return 'a ' + type; + default: + return type; + } + } + + // Returns class name of the object, if any. + function getClassName(propValue) { + if (!propValue.constructor || !propValue.constructor.name) { + return ANONYMOUS; + } + return propValue.constructor.name; + } + + ReactPropTypes.checkPropTypes = checkPropTypes; + ReactPropTypes.PropTypes = ReactPropTypes; + + return ReactPropTypes; +}; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 126 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMComponentFlags = { + hasCachedChildNodes: 1 << 0 +}; + +module.exports = ReactDOMComponentFlags; + +/***/ }), +/* 127 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +/** + * Accumulates items that must not be null or undefined into the first one. This + * is used to conserve memory by avoiding array allocations, and thus sacrifices + * API cleanness. Since `current` can be null before being passed in and not + * null after this function, make sure to assign it back to `current`: + * + * `a = accumulateInto(a, b);` + * + * This API should be sparingly used. Try `accumulate` for something cleaner. + * + * @return {*|array<*>} An accumulation of items. + */ + +function accumulateInto(current, next) { + !(next != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'accumulateInto(...): Accumulated items must not be null or undefined.') : _prodInvariant('30') : void 0; + + if (current == null) { + return next; + } + + // Both are not empty. Warning: Never call x.concat(y) when you are not + // certain that x is an Array (x could be a string with concat method). + if (Array.isArray(current)) { + if (Array.isArray(next)) { + current.push.apply(current, next); + return current; + } + current.push(next); + return current; + } + + if (Array.isArray(next)) { + // A bit too dangerous to mutate `next`. + return [current].concat(next); + } + + return [current, next]; +} + +module.exports = accumulateInto; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 128 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/** + * @param {array} arr an "accumulation" of items which is either an Array or + * a single item. Useful when paired with the `accumulate` module. This is a + * simple utility that allows us to reason about a collection of items, but + * handling the case when there is exactly one item (and we do not need to + * allocate an array). + */ + +function forEachAccumulated(arr, cb, scope) { + if (Array.isArray(arr)) { + arr.forEach(cb, scope); + } else if (arr) { + cb.call(scope, arr); + } +} + +module.exports = forEachAccumulated; + +/***/ }), +/* 129 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +var contentKey = null; + +/** + * Gets the key used to access text content on a DOM node. + * + * @return {?string} Key used to access text content. + * @internal + */ +function getTextContentAccessor() { + if (!contentKey && ExecutionEnvironment.canUseDOM) { + // Prefer textContent to innerText because many browsers support both but + // SVG <text> elements don't support innerText even when <div> does. + contentKey = 'textContent' in document.documentElement ? 'textContent' : 'innerText'; + } + return contentKey; +} + +module.exports = getTextContentAccessor; + +/***/ }), +/* 130 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +var PooledClass = __webpack_require__(32); + +var invariant = __webpack_require__(2); + +/** + * A specialized pseudo-event module to help keep track of components waiting to + * be notified when their DOM representations are available for use. + * + * This implements `PooledClass`, so you should never need to instantiate this. + * Instead, use `CallbackQueue.getPooled()`. + * + * @class ReactMountReady + * @implements PooledClass + * @internal + */ + +var CallbackQueue = function () { + function CallbackQueue(arg) { + _classCallCheck(this, CallbackQueue); + + this._callbacks = null; + this._contexts = null; + this._arg = arg; + } + + /** + * Enqueues a callback to be invoked when `notifyAll` is invoked. + * + * @param {function} callback Invoked when `notifyAll` is invoked. + * @param {?object} context Context to call `callback` with. + * @internal + */ + + + CallbackQueue.prototype.enqueue = function enqueue(callback, context) { + this._callbacks = this._callbacks || []; + this._callbacks.push(callback); + this._contexts = this._contexts || []; + this._contexts.push(context); + }; + + /** + * Invokes all enqueued callbacks and clears the queue. This is invoked after + * the DOM representation of a component has been created or updated. + * + * @internal + */ + + + CallbackQueue.prototype.notifyAll = function notifyAll() { + var callbacks = this._callbacks; + var contexts = this._contexts; + var arg = this._arg; + if (callbacks && contexts) { + !(callbacks.length === contexts.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Mismatched list of contexts in callback queue') : _prodInvariant('24') : void 0; + this._callbacks = null; + this._contexts = null; + for (var i = 0; i < callbacks.length; i++) { + callbacks[i].call(contexts[i], arg); + } + callbacks.length = 0; + contexts.length = 0; + } + }; + + CallbackQueue.prototype.checkpoint = function checkpoint() { + return this._callbacks ? this._callbacks.length : 0; + }; + + CallbackQueue.prototype.rollback = function rollback(len) { + if (this._callbacks && this._contexts) { + this._callbacks.length = len; + this._contexts.length = len; + } + }; + + /** + * Resets the internal queue. + * + * @internal + */ + + + CallbackQueue.prototype.reset = function reset() { + this._callbacks = null; + this._contexts = null; + }; + + /** + * `PooledClass` looks for this. + */ + + + CallbackQueue.prototype.destructor = function destructor() { + this.reset(); + }; + + return CallbackQueue; +}(); + +module.exports = PooledClass.addPoolingTo(CallbackQueue); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 131 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactFeatureFlags = { + // When true, call console.time() before and .timeEnd() after each top-level + // render (both initial renders and updates). Useful when looking at prod-mode + // timeline profiles in Chrome, for example. + logTopLevelRenders: false +}; + +module.exports = ReactFeatureFlags; + +/***/ }), +/* 132 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMComponentTree = __webpack_require__(10); + +function isCheckable(elem) { + var type = elem.type; + var nodeName = elem.nodeName; + return nodeName && nodeName.toLowerCase() === 'input' && (type === 'checkbox' || type === 'radio'); +} + +function getTracker(inst) { + return inst._wrapperState.valueTracker; +} + +function attachTracker(inst, tracker) { + inst._wrapperState.valueTracker = tracker; +} + +function detachTracker(inst) { + delete inst._wrapperState.valueTracker; +} + +function getValueFromNode(node) { + var value; + if (node) { + value = isCheckable(node) ? '' + node.checked : node.value; + } + return value; +} + +var inputValueTracking = { + // exposed for testing + _getTrackerFromNode: function (node) { + return getTracker(ReactDOMComponentTree.getInstanceFromNode(node)); + }, + + + track: function (inst) { + if (getTracker(inst)) { + return; + } + + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var valueField = isCheckable(node) ? 'checked' : 'value'; + var descriptor = Object.getOwnPropertyDescriptor(node.constructor.prototype, valueField); + + var currentValue = '' + node[valueField]; + + // if someone has already defined a value or Safari, then bail + // and don't track value will cause over reporting of changes, + // but it's better then a hard failure + // (needed for certain tests that spyOn input values and Safari) + if (node.hasOwnProperty(valueField) || typeof descriptor.get !== 'function' || typeof descriptor.set !== 'function') { + return; + } + + Object.defineProperty(node, valueField, { + enumerable: descriptor.enumerable, + configurable: true, + get: function () { + return descriptor.get.call(this); + }, + set: function (value) { + currentValue = '' + value; + descriptor.set.call(this, value); + } + }); + + attachTracker(inst, { + getValue: function () { + return currentValue; + }, + setValue: function (value) { + currentValue = '' + value; + }, + stopTracking: function () { + detachTracker(inst); + delete node[valueField]; + } + }); + }, + + updateValueIfChanged: function (inst) { + if (!inst) { + return false; + } + var tracker = getTracker(inst); + + if (!tracker) { + inputValueTracking.track(inst); + return true; + } + + var lastValue = tracker.getValue(); + var nextValue = getValueFromNode(ReactDOMComponentTree.getNodeFromInstance(inst)); + + if (nextValue !== lastValue) { + tracker.setValue(nextValue); + return true; + } + + return false; + }, + stopTracking: function (inst) { + var tracker = getTracker(inst); + if (tracker) { + tracker.stopTracking(); + } + } +}; + +module.exports = inputValueTracking; + +/***/ }), +/* 133 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/** + * @see http://www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#input-type-attr-summary + */ + +var supportedInputTypes = { + color: true, + date: true, + datetime: true, + 'datetime-local': true, + email: true, + month: true, + number: true, + password: true, + range: true, + search: true, + tel: true, + text: true, + time: true, + url: true, + week: true +}; + +function isTextInputElement(elem) { + var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); + + if (nodeName === 'input') { + return !!supportedInputTypes[elem.type]; + } + + if (nodeName === 'textarea') { + return true; + } + + return false; +} + +module.exports = isTextInputElement; + +/***/ }), +/* 134 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ViewportMetrics = { + currentScrollLeft: 0, + + currentScrollTop: 0, + + refreshScrollValues: function (scrollPosition) { + ViewportMetrics.currentScrollLeft = scrollPosition.x; + ViewportMetrics.currentScrollTop = scrollPosition.y; + } +}; + +module.exports = ViewportMetrics; + +/***/ }), +/* 135 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); +var escapeTextContentForBrowser = __webpack_require__(61); +var setInnerHTML = __webpack_require__(60); + +/** + * Set the textContent property of a node, ensuring that whitespace is preserved + * even in IE8. innerText is a poor substitute for textContent and, among many + * issues, inserts <br> instead of the literal newline chars. innerHTML behaves + * as it should. + * + * @param {DOMElement} node + * @param {string} text + * @internal + */ +var setTextContent = function (node, text) { + if (text) { + var firstChild = node.firstChild; + + if (firstChild && firstChild === node.lastChild && firstChild.nodeType === 3) { + firstChild.nodeValue = text; + return; + } + } + node.textContent = text; +}; + +if (ExecutionEnvironment.canUseDOM) { + if (!('textContent' in document.documentElement)) { + setTextContent = function (node, text) { + if (node.nodeType === 3) { + node.nodeValue = text; + return; + } + setInnerHTML(node, escapeTextContentForBrowser(text)); + }; + } +} + +module.exports = setTextContent; + +/***/ }), +/* 136 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * @param {DOMElement} node input/textarea to focus + */ + +function focusNode(node) { + // IE8 can throw "Can't move focus to the control because it is invisible, + // not enabled, or of a type that does not accept the focus." for all kinds of + // reasons that are too expensive and fragile to test. + try { + node.focus(); + } catch (e) {} +} + +module.exports = focusNode; + +/***/ }), +/* 137 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * CSS properties which accept numbers but are not in units of "px". + */ + +var isUnitlessNumber = { + animationIterationCount: true, + borderImageOutset: true, + borderImageSlice: true, + borderImageWidth: true, + boxFlex: true, + boxFlexGroup: true, + boxOrdinalGroup: true, + columnCount: true, + flex: true, + flexGrow: true, + flexPositive: true, + flexShrink: true, + flexNegative: true, + flexOrder: true, + gridRow: true, + gridRowEnd: true, + gridRowSpan: true, + gridRowStart: true, + gridColumn: true, + gridColumnEnd: true, + gridColumnSpan: true, + gridColumnStart: true, + fontWeight: true, + lineClamp: true, + lineHeight: true, + opacity: true, + order: true, + orphans: true, + tabSize: true, + widows: true, + zIndex: true, + zoom: true, + + // SVG-related properties + fillOpacity: true, + floodOpacity: true, + stopOpacity: true, + strokeDasharray: true, + strokeDashoffset: true, + strokeMiterlimit: true, + strokeOpacity: true, + strokeWidth: true +}; + +/** + * @param {string} prefix vendor-specific prefix, eg: Webkit + * @param {string} key style name, eg: transitionDuration + * @return {string} style name prefixed with `prefix`, properly camelCased, eg: + * WebkitTransitionDuration + */ +function prefixKey(prefix, key) { + return prefix + key.charAt(0).toUpperCase() + key.substring(1); +} + +/** + * Support style names that may come passed in prefixed by adding permutations + * of vendor prefixes. + */ +var prefixes = ['Webkit', 'ms', 'Moz', 'O']; + +// Using Object.keys here, or else the vanilla for-in loop makes IE8 go into an +// infinite loop, because it iterates over the newly added props too. +Object.keys(isUnitlessNumber).forEach(function (prop) { + prefixes.forEach(function (prefix) { + isUnitlessNumber[prefixKey(prefix, prop)] = isUnitlessNumber[prop]; + }); +}); + +/** + * Most style properties can be unset by doing .style[prop] = '' but IE8 + * doesn't like doing that with shorthand properties so for the properties that + * IE8 breaks on, which are listed here, we instead unset each of the + * individual properties. See http://bugs.jquery.com/ticket/12385. + * The 4-value 'clock' properties like margin, padding, border-width seem to + * behave without any problems. Curiously, list-style works too without any + * special prodding. + */ +var shorthandPropertyExpansions = { + background: { + backgroundAttachment: true, + backgroundColor: true, + backgroundImage: true, + backgroundPositionX: true, + backgroundPositionY: true, + backgroundRepeat: true + }, + backgroundPosition: { + backgroundPositionX: true, + backgroundPositionY: true + }, + border: { + borderWidth: true, + borderStyle: true, + borderColor: true + }, + borderBottom: { + borderBottomWidth: true, + borderBottomStyle: true, + borderBottomColor: true + }, + borderLeft: { + borderLeftWidth: true, + borderLeftStyle: true, + borderLeftColor: true + }, + borderRight: { + borderRightWidth: true, + borderRightStyle: true, + borderRightColor: true + }, + borderTop: { + borderTopWidth: true, + borderTopStyle: true, + borderTopColor: true + }, + font: { + fontStyle: true, + fontVariant: true, + fontWeight: true, + fontSize: true, + lineHeight: true, + fontFamily: true + }, + outline: { + outlineWidth: true, + outlineStyle: true, + outlineColor: true + } +}; + +var CSSProperty = { + isUnitlessNumber: isUnitlessNumber, + shorthandPropertyExpansions: shorthandPropertyExpansions +}; + +module.exports = CSSProperty; + +/***/ }), +/* 138 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstrumentation = __webpack_require__(19); + +var quoteAttributeValueForBrowser = __webpack_require__(263); +var warning = __webpack_require__(3); + +var VALID_ATTRIBUTE_NAME_REGEX = new RegExp('^[' + DOMProperty.ATTRIBUTE_NAME_START_CHAR + '][' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); +var illegalAttributeNameCache = {}; +var validatedAttributeNameCache = {}; + +function isAttributeNameSafe(attributeName) { + if (validatedAttributeNameCache.hasOwnProperty(attributeName)) { + return true; + } + if (illegalAttributeNameCache.hasOwnProperty(attributeName)) { + return false; + } + if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) { + validatedAttributeNameCache[attributeName] = true; + return true; + } + illegalAttributeNameCache[attributeName] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid attribute name: `%s`', attributeName) : void 0; + return false; +} + +function shouldIgnoreValue(propertyInfo, value) { + return value == null || propertyInfo.hasBooleanValue && !value || propertyInfo.hasNumericValue && isNaN(value) || propertyInfo.hasPositiveNumericValue && value < 1 || propertyInfo.hasOverloadedBooleanValue && value === false; +} + +/** + * Operations for dealing with DOM properties. + */ +var DOMPropertyOperations = { + /** + * Creates markup for the ID property. + * + * @param {string} id Unescaped ID. + * @return {string} Markup string. + */ + createMarkupForID: function (id) { + return DOMProperty.ID_ATTRIBUTE_NAME + '=' + quoteAttributeValueForBrowser(id); + }, + + setAttributeForID: function (node, id) { + node.setAttribute(DOMProperty.ID_ATTRIBUTE_NAME, id); + }, + + createMarkupForRoot: function () { + return DOMProperty.ROOT_ATTRIBUTE_NAME + '=""'; + }, + + setAttributeForRoot: function (node) { + node.setAttribute(DOMProperty.ROOT_ATTRIBUTE_NAME, ''); + }, + + /** + * Creates markup for a property. + * + * @param {string} name + * @param {*} value + * @return {?string} Markup string, or null if the property was invalid. + */ + createMarkupForProperty: function (name, value) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + if (shouldIgnoreValue(propertyInfo, value)) { + return ''; + } + var attributeName = propertyInfo.attributeName; + if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { + return attributeName + '=""'; + } + return attributeName + '=' + quoteAttributeValueForBrowser(value); + } else if (DOMProperty.isCustomAttribute(name)) { + if (value == null) { + return ''; + } + return name + '=' + quoteAttributeValueForBrowser(value); + } + return null; + }, + + /** + * Creates markup for a custom property. + * + * @param {string} name + * @param {*} value + * @return {string} Markup string, or empty string if the property was invalid. + */ + createMarkupForCustomAttribute: function (name, value) { + if (!isAttributeNameSafe(name) || value == null) { + return ''; + } + return name + '=' + quoteAttributeValueForBrowser(value); + }, + + /** + * Sets the value for a property on a node. + * + * @param {DOMElement} node + * @param {string} name + * @param {*} value + */ + setValueForProperty: function (node, name, value) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + var mutationMethod = propertyInfo.mutationMethod; + if (mutationMethod) { + mutationMethod(node, value); + } else if (shouldIgnoreValue(propertyInfo, value)) { + this.deleteValueForProperty(node, name); + return; + } else if (propertyInfo.mustUseProperty) { + // Contrary to `setAttribute`, object properties are properly + // `toString`ed by IE8/9. + node[propertyInfo.propertyName] = value; + } else { + var attributeName = propertyInfo.attributeName; + var namespace = propertyInfo.attributeNamespace; + // `setAttribute` with objects becomes only `[object]` in IE8/9, + // ('' + value) makes it output the correct toString()-value. + if (namespace) { + node.setAttributeNS(namespace, attributeName, '' + value); + } else if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { + node.setAttribute(attributeName, ''); + } else { + node.setAttribute(attributeName, '' + value); + } + } + } else if (DOMProperty.isCustomAttribute(name)) { + DOMPropertyOperations.setValueForAttribute(node, name, value); + return; + } + + if (process.env.NODE_ENV !== 'production') { + var payload = {}; + payload[name] = value; + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'update attribute', + payload: payload + }); + } + }, + + setValueForAttribute: function (node, name, value) { + if (!isAttributeNameSafe(name)) { + return; + } + if (value == null) { + node.removeAttribute(name); + } else { + node.setAttribute(name, '' + value); + } + + if (process.env.NODE_ENV !== 'production') { + var payload = {}; + payload[name] = value; + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'update attribute', + payload: payload + }); + } + }, + + /** + * Deletes an attributes from a node. + * + * @param {DOMElement} node + * @param {string} name + */ + deleteValueForAttribute: function (node, name) { + node.removeAttribute(name); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'remove attribute', + payload: name + }); + } + }, + + /** + * Deletes the value for a property on a node. + * + * @param {DOMElement} node + * @param {string} name + */ + deleteValueForProperty: function (node, name) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + var mutationMethod = propertyInfo.mutationMethod; + if (mutationMethod) { + mutationMethod(node, undefined); + } else if (propertyInfo.mustUseProperty) { + var propName = propertyInfo.propertyName; + if (propertyInfo.hasBooleanValue) { + node[propName] = false; + } else { + node[propName] = ''; + } + } else { + node.removeAttribute(propertyInfo.attributeName); + } + } else if (DOMProperty.isCustomAttribute(name)) { + node.removeAttribute(name); + } + + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'remove attribute', + payload: name + }); + } + } +}; + +module.exports = DOMPropertyOperations; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 139 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; + +module.exports = ReactPropTypesSecret; + +/***/ }), +/* 140 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); + +var warning = __webpack_require__(3); + +var didWarnValueLink = false; +var didWarnValueDefaultValue = false; + +function updateOptionsIfPendingUpdateAndMounted() { + if (this._rootNodeID && this._wrapperState.pendingUpdate) { + this._wrapperState.pendingUpdate = false; + + var props = this._currentElement.props; + var value = LinkedValueUtils.getValue(props); + + if (value != null) { + updateOptions(this, Boolean(props.multiple), value); + } + } +} + +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} + +var valuePropNames = ['value', 'defaultValue']; + +/** + * Validation function for `value` and `defaultValue`. + * @private + */ +function checkSelectPropTypes(inst, props) { + var owner = inst._currentElement._owner; + LinkedValueUtils.checkPropTypes('select', props, owner); + + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `select` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + + for (var i = 0; i < valuePropNames.length; i++) { + var propName = valuePropNames[i]; + if (props[propName] == null) { + continue; + } + var isArray = Array.isArray(props[propName]); + if (props.multiple && !isArray) { + process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be an array if ' + '`multiple` is true.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; + } else if (!props.multiple && isArray) { + process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be a scalar ' + 'value if `multiple` is false.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; + } + } +} + +/** + * @param {ReactDOMComponent} inst + * @param {boolean} multiple + * @param {*} propValue A stringable (with `multiple`, a list of stringables). + * @private + */ +function updateOptions(inst, multiple, propValue) { + var selectedValue, i; + var options = ReactDOMComponentTree.getNodeFromInstance(inst).options; + + if (multiple) { + selectedValue = {}; + for (i = 0; i < propValue.length; i++) { + selectedValue['' + propValue[i]] = true; + } + for (i = 0; i < options.length; i++) { + var selected = selectedValue.hasOwnProperty(options[i].value); + if (options[i].selected !== selected) { + options[i].selected = selected; + } + } + } else { + // Do not set `select.value` as exact behavior isn't consistent across all + // browsers for all cases. + selectedValue = '' + propValue; + for (i = 0; i < options.length; i++) { + if (options[i].value === selectedValue) { + options[i].selected = true; + return; + } + } + if (options.length) { + options[0].selected = true; + } + } +} + +/** + * Implements a <select> host component that allows optionally setting the + * props `value` and `defaultValue`. If `multiple` is false, the prop must be a + * stringable. If `multiple` is true, the prop must be an array of stringables. + * + * If `value` is not supplied (or null/undefined), user actions that change the + * selected option will trigger updates to the rendered options. + * + * If it is supplied (and not null/undefined), the rendered options will not + * update in response to user actions. Instead, the `value` prop must change in + * order for the rendered options to update. + * + * If `defaultValue` is provided, any options with the supplied values will be + * selected. + */ +var ReactDOMSelect = { + getHostProps: function (inst, props) { + return _assign({}, props, { + onChange: inst._wrapperState.onChange, + value: undefined + }); + }, + + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + checkSelectPropTypes(inst, props); + } + + var value = LinkedValueUtils.getValue(props); + inst._wrapperState = { + pendingUpdate: false, + initialValue: value != null ? value : props.defaultValue, + listeners: null, + onChange: _handleChange.bind(inst), + wasMultiple: Boolean(props.multiple) + }; + + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Select elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; + didWarnValueDefaultValue = true; + } + }, + + getSelectValueContext: function (inst) { + // ReactDOMOption looks at this initial value so the initial generated + // markup has correct `selected` attributes + return inst._wrapperState.initialValue; + }, + + postUpdateWrapper: function (inst) { + var props = inst._currentElement.props; + + // After the initial mount, we control selected-ness manually so don't pass + // this value down + inst._wrapperState.initialValue = undefined; + + var wasMultiple = inst._wrapperState.wasMultiple; + inst._wrapperState.wasMultiple = Boolean(props.multiple); + + var value = LinkedValueUtils.getValue(props); + if (value != null) { + inst._wrapperState.pendingUpdate = false; + updateOptions(inst, Boolean(props.multiple), value); + } else if (wasMultiple !== Boolean(props.multiple)) { + // For simplicity, reapply `defaultValue` if `multiple` is toggled. + if (props.defaultValue != null) { + updateOptions(inst, Boolean(props.multiple), props.defaultValue); + } else { + // Revert the select back to its default unselected state. + updateOptions(inst, Boolean(props.multiple), props.multiple ? [] : ''); + } + } + } +}; + +function _handleChange(event) { + var props = this._currentElement.props; + var returnValue = LinkedValueUtils.executeOnChange(props, event); + + if (this._rootNodeID) { + this._wrapperState.pendingUpdate = true; + } + ReactUpdates.asap(updateOptionsIfPendingUpdateAndMounted, this); + return returnValue; +} + +module.exports = ReactDOMSelect; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 141 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var ReactCompositeComponent = __webpack_require__(271); +var ReactEmptyComponent = __webpack_require__(143); +var ReactHostComponent = __webpack_require__(144); + +var getNextDebugID = __webpack_require__(274); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +// To avoid a cyclic dependency, we create the final class in this module +var ReactCompositeComponentWrapper = function (element) { + this.construct(element); +}; + +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} + +/** + * Check if the type reference is a known internal type. I.e. not a user + * provided composite type. + * + * @param {function} type + * @return {boolean} Returns true if this is a valid internal type. + */ +function isInternalComponentType(type) { + return typeof type === 'function' && typeof type.prototype !== 'undefined' && typeof type.prototype.mountComponent === 'function' && typeof type.prototype.receiveComponent === 'function'; +} + +/** + * Given a ReactNode, create an instance that will actually be mounted. + * + * @param {ReactNode} node + * @param {boolean} shouldHaveDebugID + * @return {object} A new instance of the element's constructor. + * @protected + */ +function instantiateReactComponent(node, shouldHaveDebugID) { + var instance; + + if (node === null || node === false) { + instance = ReactEmptyComponent.create(instantiateReactComponent); + } else if (typeof node === 'object') { + var element = node; + var type = element.type; + if (typeof type !== 'function' && typeof type !== 'string') { + var info = ''; + if (process.env.NODE_ENV !== 'production') { + if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { + info += ' You likely forgot to export your component from the file ' + "it's defined in."; + } + } + info += getDeclarationErrorAddendum(element._owner); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s', type == null ? type : typeof type, info) : _prodInvariant('130', type == null ? type : typeof type, info) : void 0; + } + + // Special case string values + if (typeof element.type === 'string') { + instance = ReactHostComponent.createInternalComponent(element); + } else if (isInternalComponentType(element.type)) { + // This is temporarily available for custom components that are not string + // representations. I.e. ART. Once those are updated to use the string + // representation, we can drop this code path. + instance = new element.type(element); + + // We renamed this. Allow the old name for compat. :( + if (!instance.getHostNode) { + instance.getHostNode = instance.getNativeNode; + } + } else { + instance = new ReactCompositeComponentWrapper(element); + } + } else if (typeof node === 'string' || typeof node === 'number') { + instance = ReactHostComponent.createInstanceForText(node); + } else { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Encountered invalid React node of type %s', typeof node) : _prodInvariant('131', typeof node) : void 0; + } + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(typeof instance.mountComponent === 'function' && typeof instance.receiveComponent === 'function' && typeof instance.getHostNode === 'function' && typeof instance.unmountComponent === 'function', 'Only React Components can be mounted.') : void 0; + } + + // These two fields are used by the DOM and ART diffing algorithms + // respectively. Instead of using expandos on components, we should be + // storing the state needed by the diffing algorithms elsewhere. + instance._mountIndex = 0; + instance._mountImage = null; + + if (process.env.NODE_ENV !== 'production') { + instance._debugID = shouldHaveDebugID ? getNextDebugID() : 0; + } + + // Internal instances should fully constructed at this point, so they should + // not get any new fields added to them at this point. + if (process.env.NODE_ENV !== 'production') { + if (Object.preventExtensions) { + Object.preventExtensions(instance); + } + } + + return instance; +} + +_assign(ReactCompositeComponentWrapper.prototype, ReactCompositeComponent, { + _instantiateReactComponent: instantiateReactComponent +}); + +module.exports = instantiateReactComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 142 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var React = __webpack_require__(36); + +var invariant = __webpack_require__(2); + +var ReactNodeTypes = { + HOST: 0, + COMPOSITE: 1, + EMPTY: 2, + + getType: function (node) { + if (node === null || node === false) { + return ReactNodeTypes.EMPTY; + } else if (React.isValidElement(node)) { + if (typeof node.type === 'function') { + return ReactNodeTypes.COMPOSITE; + } else { + return ReactNodeTypes.HOST; + } + } + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unexpected node: %s', node) : _prodInvariant('26', node) : void 0; + } +}; + +module.exports = ReactNodeTypes; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 143 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var emptyComponentFactory; + +var ReactEmptyComponentInjection = { + injectEmptyComponentFactory: function (factory) { + emptyComponentFactory = factory; + } +}; + +var ReactEmptyComponent = { + create: function (instantiate) { + return emptyComponentFactory(instantiate); + } +}; + +ReactEmptyComponent.injection = ReactEmptyComponentInjection; + +module.exports = ReactEmptyComponent; + +/***/ }), +/* 144 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +var genericComponentClass = null; +var textComponentClass = null; + +var ReactHostComponentInjection = { + // This accepts a class that receives the tag string. This is a catch all + // that can render any kind of tag. + injectGenericComponentClass: function (componentClass) { + genericComponentClass = componentClass; + }, + // This accepts a text component class that takes the text string to be + // rendered as props. + injectTextComponentClass: function (componentClass) { + textComponentClass = componentClass; + } +}; + +/** + * Get a host internal component class for a specific tag. + * + * @param {ReactElement} element The element to create. + * @return {function} The internal class constructor function. + */ +function createInternalComponent(element) { + !genericComponentClass ? process.env.NODE_ENV !== 'production' ? invariant(false, 'There is no registered component for the tag %s', element.type) : _prodInvariant('111', element.type) : void 0; + return new genericComponentClass(element); +} + +/** + * @param {ReactText} text + * @return {ReactComponent} + */ +function createInstanceForText(text) { + return new textComponentClass(text); +} + +/** + * @param {ReactComponent} component + * @return {boolean} + */ +function isTextComponent(component) { + return component instanceof textComponentClass; +} + +var ReactHostComponent = { + createInternalComponent: createInternalComponent, + createInstanceForText: createInstanceForText, + isTextComponent: isTextComponent, + injection: ReactHostComponentInjection +}; + +module.exports = ReactHostComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 145 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactCurrentOwner = __webpack_require__(22); +var REACT_ELEMENT_TYPE = __webpack_require__(275); + +var getIteratorFn = __webpack_require__(276); +var invariant = __webpack_require__(2); +var KeyEscapeUtils = __webpack_require__(89); +var warning = __webpack_require__(3); + +var SEPARATOR = '.'; +var SUBSEPARATOR = ':'; + +/** + * This is inlined from ReactElement since this file is shared between + * isomorphic and renderers. We could extract this to a + * + */ + +/** + * TODO: Test that a single child and an array with one item have the same key + * pattern. + */ + +var didWarnAboutMaps = false; + +/** + * Generate a key string that identifies a component within a set. + * + * @param {*} component A component that could contain a manual key. + * @param {number} index Index that is used if a manual key is not provided. + * @return {string} + */ +function getComponentKey(component, index) { + // Do some typechecking here since we call this blindly. We want to ensure + // that we don't block potential future ES APIs. + if (component && typeof component === 'object' && component.key != null) { + // Explicit key + return KeyEscapeUtils.escape(component.key); + } + // Implicit key determined by the index in the set + return index.toString(36); +} + +/** + * @param {?*} children Children tree container. + * @param {!string} nameSoFar Name of the key path so far. + * @param {!function} callback Callback to invoke with each child found. + * @param {?*} traverseContext Used to pass information throughout the traversal + * process. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { + var type = typeof children; + + if (type === 'undefined' || type === 'boolean') { + // All of the above are perceived as null. + children = null; + } + + if (children === null || type === 'string' || type === 'number' || + // The following is inlined from ReactElement. This means we can optimize + // some checks. React Fiber also inlines this logic for similar purposes. + type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { + callback(traverseContext, children, + // If it's the only child, treat the name as if it was wrapped in an array + // so that it's consistent if the number of children grows. + nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); + return 1; + } + + var child; + var nextName; + var subtreeCount = 0; // Count of children found in the current subtree. + var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; + + if (Array.isArray(children)) { + for (var i = 0; i < children.length; i++) { + child = children[i]; + nextName = nextNamePrefix + getComponentKey(child, i); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + var iteratorFn = getIteratorFn(children); + if (iteratorFn) { + var iterator = iteratorFn.call(children); + var step; + if (iteratorFn !== children.entries) { + var ii = 0; + while (!(step = iterator.next()).done) { + child = step.value; + nextName = nextNamePrefix + getComponentKey(child, ii++); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + if (process.env.NODE_ENV !== 'production') { + var mapsAsChildrenAddendum = ''; + if (ReactCurrentOwner.current) { + var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); + if (mapsAsChildrenOwnerName) { + mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; + } + } + process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; + didWarnAboutMaps = true; + } + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + child = entry[1]; + nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } + } + } else if (type === 'object') { + var addendum = ''; + if (process.env.NODE_ENV !== 'production') { + addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; + if (children._isReactElement) { + addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; + } + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + addendum += ' Check the render method of `' + name + '`.'; + } + } + } + var childrenString = String(children); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; + } + } + + return subtreeCount; +} + +/** + * Traverses children that are typically specified as `props.children`, but + * might also be specified through attributes: + * + * - `traverseAllChildren(this.props.children, ...)` + * - `traverseAllChildren(this.props.leftPanelChildren, ...)` + * + * The `traverseContext` is an optional argument that is passed through the + * entire traversal. It can be used to store accumulations or anything else that + * the callback might find relevant. + * + * @param {?*} children Children tree object. + * @param {!function} callback To invoke upon traversing each child. + * @param {?*} traverseContext Context for traversal. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildren(children, callback, traverseContext) { + if (children == null) { + return 0; + } + + return traverseAllChildrenImpl(children, '', callback, traverseContext); +} + +module.exports = traverseAllChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 146 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * @typechecks + */ + +var emptyFunction = __webpack_require__(18); + +/** + * Upstream version of event listener. Does not take into account specific + * nature of platform. + */ +var EventListener = { + /** + * Listen to DOM events during the bubble phase. + * + * @param {DOMEventTarget} target DOM element to register listener on. + * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. + * @param {function} callback Callback function. + * @return {object} Object with a `remove` method. + */ + listen: function listen(target, eventType, callback) { + if (target.addEventListener) { + target.addEventListener(eventType, callback, false); + return { + remove: function remove() { + target.removeEventListener(eventType, callback, false); + } + }; + } else if (target.attachEvent) { + target.attachEvent('on' + eventType, callback); + return { + remove: function remove() { + target.detachEvent('on' + eventType, callback); + } + }; + } + }, + + /** + * Listen to DOM events during the capture phase. + * + * @param {DOMEventTarget} target DOM element to register listener on. + * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. + * @param {function} callback Callback function. + * @return {object} Object with a `remove` method. + */ + capture: function capture(target, eventType, callback) { + if (target.addEventListener) { + target.addEventListener(eventType, callback, true); + return { + remove: function remove() { + target.removeEventListener(eventType, callback, true); + } + }; + } else { + if (process.env.NODE_ENV !== 'production') { + console.error('Attempted to listen to events during the capture phase on a ' + 'browser that does not support the capture phase. Your application ' + 'will not receive some events.'); + } + return { + remove: emptyFunction + }; + } + }, + + registerDefault: function registerDefault() {} +}; + +module.exports = EventListener; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 147 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMSelection = __webpack_require__(288); + +var containsNode = __webpack_require__(290); +var focusNode = __webpack_require__(136); +var getActiveElement = __webpack_require__(148); + +function isInDocument(node) { + return containsNode(document.documentElement, node); +} + +/** + * @ReactInputSelection: React input selection module. Based on Selection.js, + * but modified to be suitable for react and has a couple of bug fixes (doesn't + * assume buttons have range selections allowed). + * Input selection module for React. + */ +var ReactInputSelection = { + hasSelectionCapabilities: function (elem) { + var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); + return nodeName && (nodeName === 'input' && elem.type === 'text' || nodeName === 'textarea' || elem.contentEditable === 'true'); + }, + + getSelectionInformation: function () { + var focusedElem = getActiveElement(); + return { + focusedElem: focusedElem, + selectionRange: ReactInputSelection.hasSelectionCapabilities(focusedElem) ? ReactInputSelection.getSelection(focusedElem) : null + }; + }, + + /** + * @restoreSelection: If any selection information was potentially lost, + * restore it. This is useful when performing operations that could remove dom + * nodes and place them back in, resulting in focus being lost. + */ + restoreSelection: function (priorSelectionInformation) { + var curFocusedElem = getActiveElement(); + var priorFocusedElem = priorSelectionInformation.focusedElem; + var priorSelectionRange = priorSelectionInformation.selectionRange; + if (curFocusedElem !== priorFocusedElem && isInDocument(priorFocusedElem)) { + if (ReactInputSelection.hasSelectionCapabilities(priorFocusedElem)) { + ReactInputSelection.setSelection(priorFocusedElem, priorSelectionRange); + } + focusNode(priorFocusedElem); + } + }, + + /** + * @getSelection: Gets the selection bounds of a focused textarea, input or + * contentEditable node. + * -@input: Look up selection bounds of this input + * -@return {start: selectionStart, end: selectionEnd} + */ + getSelection: function (input) { + var selection; + + if ('selectionStart' in input) { + // Modern browser with input or textarea. + selection = { + start: input.selectionStart, + end: input.selectionEnd + }; + } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { + // IE8 input. + var range = document.selection.createRange(); + // There can only be one selection per document in IE, so it must + // be in our element. + if (range.parentElement() === input) { + selection = { + start: -range.moveStart('character', -input.value.length), + end: -range.moveEnd('character', -input.value.length) + }; + } + } else { + // Content editable or old IE textarea. + selection = ReactDOMSelection.getOffsets(input); + } + + return selection || { start: 0, end: 0 }; + }, + + /** + * @setSelection: Sets the selection bounds of a textarea or input and focuses + * the input. + * -@input Set selection bounds of this input or textarea + * -@offsets Object of same form that is returned from get* + */ + setSelection: function (input, offsets) { + var start = offsets.start; + var end = offsets.end; + if (end === undefined) { + end = start; + } + + if ('selectionStart' in input) { + input.selectionStart = start; + input.selectionEnd = Math.min(end, input.value.length); + } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { + var range = input.createTextRange(); + range.collapse(true); + range.moveStart('character', start); + range.moveEnd('character', end - start); + range.select(); + } else { + ReactDOMSelection.setOffsets(input, offsets); + } + } +}; + +module.exports = ReactInputSelection; + +/***/ }), +/* 148 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +/* eslint-disable fb-www/typeof-undefined */ + +/** + * Same as document.activeElement but wraps in a try-catch block. In IE it is + * not safe to call document.activeElement if there is nothing focused. + * + * The activeElement will be null only if the document or document body is not + * yet defined. + * + * @param {?DOMDocument} doc Defaults to current document. + * @return {?DOMElement} + */ +function getActiveElement(doc) /*?DOMElement*/{ + doc = doc || (typeof document !== 'undefined' ? document : undefined); + if (typeof doc === 'undefined') { + return null; + } + try { + return doc.activeElement || doc.body; + } catch (e) { + return doc.body; + } +} + +module.exports = getActiveElement; + +/***/ }), +/* 149 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var DOMLazyTree = __webpack_require__(39); +var DOMProperty = __webpack_require__(28); +var React = __webpack_require__(36); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactCurrentOwner = __webpack_require__(22); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMContainerInfo = __webpack_require__(305); +var ReactDOMFeatureFlags = __webpack_require__(306); +var ReactFeatureFlags = __webpack_require__(131); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactMarkupChecksum = __webpack_require__(307); +var ReactReconciler = __webpack_require__(38); +var ReactUpdateQueue = __webpack_require__(90); +var ReactUpdates = __webpack_require__(23); + +var emptyObject = __webpack_require__(56); +var instantiateReactComponent = __webpack_require__(141); +var invariant = __webpack_require__(2); +var setInnerHTML = __webpack_require__(60); +var shouldUpdateReactComponent = __webpack_require__(88); +var warning = __webpack_require__(3); + +var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; +var ROOT_ATTR_NAME = DOMProperty.ROOT_ATTRIBUTE_NAME; + +var ELEMENT_NODE_TYPE = 1; +var DOC_NODE_TYPE = 9; +var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + +var instancesByReactRootID = {}; + +/** + * Finds the index of the first character + * that's not common between the two given strings. + * + * @return {number} the index of the character where the strings diverge + */ +function firstDifferenceIndex(string1, string2) { + var minLen = Math.min(string1.length, string2.length); + for (var i = 0; i < minLen; i++) { + if (string1.charAt(i) !== string2.charAt(i)) { + return i; + } + } + return string1.length === string2.length ? -1 : minLen; +} + +/** + * @param {DOMElement|DOMDocument} container DOM element that may contain + * a React component + * @return {?*} DOM element that may have the reactRoot ID, or null. + */ +function getReactRootElementInContainer(container) { + if (!container) { + return null; + } + + if (container.nodeType === DOC_NODE_TYPE) { + return container.documentElement; + } else { + return container.firstChild; + } +} + +function internalGetID(node) { + // If node is something like a window, document, or text node, none of + // which support attributes or a .getAttribute method, gracefully return + // the empty string, as if the attribute were missing. + return node.getAttribute && node.getAttribute(ATTR_NAME) || ''; +} + +/** + * Mounts this component and inserts it into the DOM. + * + * @param {ReactComponent} componentInstance The instance to mount. + * @param {DOMElement} container DOM element to mount into. + * @param {ReactReconcileTransaction} transaction + * @param {boolean} shouldReuseMarkup If true, do not insert markup + */ +function mountComponentIntoNode(wrapperInstance, container, transaction, shouldReuseMarkup, context) { + var markerName; + if (ReactFeatureFlags.logTopLevelRenders) { + var wrappedElement = wrapperInstance._currentElement.props.child; + var type = wrappedElement.type; + markerName = 'React mount: ' + (typeof type === 'string' ? type : type.displayName || type.name); + console.time(markerName); + } + + var markup = ReactReconciler.mountComponent(wrapperInstance, transaction, null, ReactDOMContainerInfo(wrapperInstance, container), context, 0 /* parentDebugID */ + ); + + if (markerName) { + console.timeEnd(markerName); + } + + wrapperInstance._renderedComponent._topLevelWrapper = wrapperInstance; + ReactMount._mountImageIntoNode(markup, container, wrapperInstance, shouldReuseMarkup, transaction); +} + +/** + * Batched mount. + * + * @param {ReactComponent} componentInstance The instance to mount. + * @param {DOMElement} container DOM element to mount into. + * @param {boolean} shouldReuseMarkup If true, do not insert markup + */ +function batchedMountComponentIntoNode(componentInstance, container, shouldReuseMarkup, context) { + var transaction = ReactUpdates.ReactReconcileTransaction.getPooled( + /* useCreateElement */ + !shouldReuseMarkup && ReactDOMFeatureFlags.useCreateElement); + transaction.perform(mountComponentIntoNode, null, componentInstance, container, transaction, shouldReuseMarkup, context); + ReactUpdates.ReactReconcileTransaction.release(transaction); +} + +/** + * Unmounts a component and removes it from the DOM. + * + * @param {ReactComponent} instance React component instance. + * @param {DOMElement} container DOM element to unmount from. + * @final + * @internal + * @see {ReactMount.unmountComponentAtNode} + */ +function unmountComponentFromNode(instance, container, safely) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onBeginFlush(); + } + ReactReconciler.unmountComponent(instance, safely); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onEndFlush(); + } + + if (container.nodeType === DOC_NODE_TYPE) { + container = container.documentElement; + } + + // http://jsperf.com/emptying-a-node + while (container.lastChild) { + container.removeChild(container.lastChild); + } +} + +/** + * True if the supplied DOM node has a direct React-rendered child that is + * not a React root element. Useful for warning in `render`, + * `unmountComponentAtNode`, etc. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM element contains a direct child that was + * rendered by React but is not a root element. + * @internal + */ +function hasNonRootReactChild(container) { + var rootEl = getReactRootElementInContainer(container); + if (rootEl) { + var inst = ReactDOMComponentTree.getInstanceFromNode(rootEl); + return !!(inst && inst._hostParent); + } +} + +/** + * True if the supplied DOM node is a React DOM element and + * it has been rendered by another copy of React. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM has been rendered by another copy of React + * @internal + */ +function nodeIsRenderedByOtherInstance(container) { + var rootEl = getReactRootElementInContainer(container); + return !!(rootEl && isReactNode(rootEl) && !ReactDOMComponentTree.getInstanceFromNode(rootEl)); +} + +/** + * True if the supplied DOM node is a valid node element. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM is a valid DOM node. + * @internal + */ +function isValidContainer(node) { + return !!(node && (node.nodeType === ELEMENT_NODE_TYPE || node.nodeType === DOC_NODE_TYPE || node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE)); +} + +/** + * True if the supplied DOM node is a valid React node element. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM is a valid React DOM node. + * @internal + */ +function isReactNode(node) { + return isValidContainer(node) && (node.hasAttribute(ROOT_ATTR_NAME) || node.hasAttribute(ATTR_NAME)); +} + +function getHostRootInstanceInContainer(container) { + var rootEl = getReactRootElementInContainer(container); + var prevHostInstance = rootEl && ReactDOMComponentTree.getInstanceFromNode(rootEl); + return prevHostInstance && !prevHostInstance._hostParent ? prevHostInstance : null; +} + +function getTopLevelWrapperInContainer(container) { + var root = getHostRootInstanceInContainer(container); + return root ? root._hostContainerInfo._topLevelWrapper : null; +} + +/** + * Temporary (?) hack so that we can store all top-level pending updates on + * composites instead of having to worry about different types of components + * here. + */ +var topLevelRootCounter = 1; +var TopLevelWrapper = function () { + this.rootID = topLevelRootCounter++; +}; +TopLevelWrapper.prototype.isReactComponent = {}; +if (process.env.NODE_ENV !== 'production') { + TopLevelWrapper.displayName = 'TopLevelWrapper'; +} +TopLevelWrapper.prototype.render = function () { + return this.props.child; +}; +TopLevelWrapper.isReactTopLevelWrapper = true; + +/** + * Mounting is the process of initializing a React component by creating its + * representative DOM elements and inserting them into a supplied `container`. + * Any prior content inside `container` is destroyed in the process. + * + * ReactMount.render( + * component, + * document.getElementById('container') + * ); + * + * <div id="container"> <-- Supplied `container`. + * <div data-reactid=".3"> <-- Rendered reactRoot of React + * // ... component. + * </div> + * </div> + * + * Inside of `container`, the first element rendered is the "reactRoot". + */ +var ReactMount = { + TopLevelWrapper: TopLevelWrapper, + + /** + * Used by devtools. The keys are not important. + */ + _instancesByReactRootID: instancesByReactRootID, + + /** + * This is a hook provided to support rendering React components while + * ensuring that the apparent scroll position of its `container` does not + * change. + * + * @param {DOMElement} container The `container` being rendered into. + * @param {function} renderCallback This must be called once to do the render. + */ + scrollMonitor: function (container, renderCallback) { + renderCallback(); + }, + + /** + * Take a component that's already mounted into the DOM and replace its props + * @param {ReactComponent} prevComponent component instance already in the DOM + * @param {ReactElement} nextElement component instance to render + * @param {DOMElement} container container to render into + * @param {?function} callback function triggered on completion + */ + _updateRootComponent: function (prevComponent, nextElement, nextContext, container, callback) { + ReactMount.scrollMonitor(container, function () { + ReactUpdateQueue.enqueueElementInternal(prevComponent, nextElement, nextContext); + if (callback) { + ReactUpdateQueue.enqueueCallbackInternal(prevComponent, callback); + } + }); + + return prevComponent; + }, + + /** + * Render a new component into the DOM. Hooked by hooks! + * + * @param {ReactElement} nextElement element to render + * @param {DOMElement} container container to render into + * @param {boolean} shouldReuseMarkup if we should skip the markup insertion + * @return {ReactComponent} nextComponent + */ + _renderNewRootComponent: function (nextElement, container, shouldReuseMarkup, context) { + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '_renderNewRootComponent(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from ' + 'render is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; + + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, '_registerComponent(...): Target container is not a DOM element.') : _prodInvariant('37') : void 0; + + ReactBrowserEventEmitter.ensureScrollValueMonitoring(); + var componentInstance = instantiateReactComponent(nextElement, false); + + // The initial render is synchronous but any updates that happen during + // rendering, in componentWillMount or componentDidMount, will be batched + // according to the current batching strategy. + + ReactUpdates.batchedUpdates(batchedMountComponentIntoNode, componentInstance, container, shouldReuseMarkup, context); + + var wrapperID = componentInstance._instance.rootID; + instancesByReactRootID[wrapperID] = componentInstance; + + return componentInstance; + }, + + /** + * Renders a React component into the DOM in the supplied `container`. + * + * If the React component was previously rendered into `container`, this will + * perform an update on it and only mutate the DOM as necessary to reflect the + * latest React component. + * + * @param {ReactComponent} parentComponent The conceptual parent of this render tree. + * @param {ReactElement} nextElement Component element to render. + * @param {DOMElement} container DOM element to render into. + * @param {?function} callback function triggered on completion + * @return {ReactComponent} Component instance rendered in `container`. + */ + renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { + !(parentComponent != null && ReactInstanceMap.has(parentComponent)) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'parentComponent must be a valid React Component') : _prodInvariant('38') : void 0; + return ReactMount._renderSubtreeIntoContainer(parentComponent, nextElement, container, callback); + }, + + _renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { + ReactUpdateQueue.validateCallback(callback, 'ReactDOM.render'); + !React.isValidElement(nextElement) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOM.render(): Invalid component element.%s', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : // Check if it quacks like an element + nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : _prodInvariant('39', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : void 0; + + process.env.NODE_ENV !== 'production' ? warning(!container || !container.tagName || container.tagName.toUpperCase() !== 'BODY', 'render(): Rendering components directly into document.body is ' + 'discouraged, since its children are often manipulated by third-party ' + 'scripts and browser extensions. This may lead to subtle ' + 'reconciliation issues. Try rendering into a container element created ' + 'for your app.') : void 0; + + var nextWrappedElement = React.createElement(TopLevelWrapper, { + child: nextElement + }); + + var nextContext; + if (parentComponent) { + var parentInst = ReactInstanceMap.get(parentComponent); + nextContext = parentInst._processChildContext(parentInst._context); + } else { + nextContext = emptyObject; + } + + var prevComponent = getTopLevelWrapperInContainer(container); + + if (prevComponent) { + var prevWrappedElement = prevComponent._currentElement; + var prevElement = prevWrappedElement.props.child; + if (shouldUpdateReactComponent(prevElement, nextElement)) { + var publicInst = prevComponent._renderedComponent.getPublicInstance(); + var updatedCallback = callback && function () { + callback.call(publicInst); + }; + ReactMount._updateRootComponent(prevComponent, nextWrappedElement, nextContext, container, updatedCallback); + return publicInst; + } else { + ReactMount.unmountComponentAtNode(container); + } + } + + var reactRootElement = getReactRootElementInContainer(container); + var containerHasReactMarkup = reactRootElement && !!internalGetID(reactRootElement); + var containerHasNonRootReactChild = hasNonRootReactChild(container); + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, 'render(...): Replacing React-rendered children with a new root ' + 'component. If you intended to update the children of this node, ' + 'you should instead have the existing children update their state ' + 'and render the new components instead of calling ReactDOM.render.') : void 0; + + if (!containerHasReactMarkup || reactRootElement.nextSibling) { + var rootElementSibling = reactRootElement; + while (rootElementSibling) { + if (internalGetID(rootElementSibling)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'render(): Target node has markup rendered by React, but there ' + 'are unrelated nodes as well. This is most commonly caused by ' + 'white-space inserted around server-rendered markup.') : void 0; + break; + } + rootElementSibling = rootElementSibling.nextSibling; + } + } + } + + var shouldReuseMarkup = containerHasReactMarkup && !prevComponent && !containerHasNonRootReactChild; + var component = ReactMount._renderNewRootComponent(nextWrappedElement, container, shouldReuseMarkup, nextContext)._renderedComponent.getPublicInstance(); + if (callback) { + callback.call(component); + } + return component; + }, + + /** + * Renders a React component into the DOM in the supplied `container`. + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.render + * + * If the React component was previously rendered into `container`, this will + * perform an update on it and only mutate the DOM as necessary to reflect the + * latest React component. + * + * @param {ReactElement} nextElement Component element to render. + * @param {DOMElement} container DOM element to render into. + * @param {?function} callback function triggered on completion + * @return {ReactComponent} Component instance rendered in `container`. + */ + render: function (nextElement, container, callback) { + return ReactMount._renderSubtreeIntoContainer(null, nextElement, container, callback); + }, + + /** + * Unmounts and destroys the React component rendered in the `container`. + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.unmountcomponentatnode + * + * @param {DOMElement} container DOM element containing a React component. + * @return {boolean} True if a component was found in and unmounted from + * `container` + */ + unmountComponentAtNode: function (container) { + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. (Strictly speaking, unmounting won't cause a + // render but we still don't expect to be in a render call here.) + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, 'unmountComponentAtNode(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from render ' + 'is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; + + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'unmountComponentAtNode(...): Target container is not a DOM element.') : _prodInvariant('40') : void 0; + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!nodeIsRenderedByOtherInstance(container), "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by another copy of React.') : void 0; + } + + var prevComponent = getTopLevelWrapperInContainer(container); + if (!prevComponent) { + // Check if the node being unmounted was rendered by React, but isn't a + // root node. + var containerHasNonRootReactChild = hasNonRootReactChild(container); + + // Check if the container itself is a React root node. + var isContainerReactRoot = container.nodeType === 1 && container.hasAttribute(ROOT_ATTR_NAME); + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by React and is not a top-level container. %s', isContainerReactRoot ? 'You may have accidentally passed in a React root node instead ' + 'of its container.' : 'Instead, have the parent component update its state and ' + 'rerender in order to remove this component.') : void 0; + } + + return false; + } + delete instancesByReactRootID[prevComponent._instance.rootID]; + ReactUpdates.batchedUpdates(unmountComponentFromNode, prevComponent, container, false); + return true; + }, + + _mountImageIntoNode: function (markup, container, instance, shouldReuseMarkup, transaction) { + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'mountComponentIntoNode(...): Target container is not valid.') : _prodInvariant('41') : void 0; + + if (shouldReuseMarkup) { + var rootElement = getReactRootElementInContainer(container); + if (ReactMarkupChecksum.canReuseMarkup(markup, rootElement)) { + ReactDOMComponentTree.precacheNode(instance, rootElement); + return; + } else { + var checksum = rootElement.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + rootElement.removeAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + + var rootMarkup = rootElement.outerHTML; + rootElement.setAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME, checksum); + + var normalizedMarkup = markup; + if (process.env.NODE_ENV !== 'production') { + // because rootMarkup is retrieved from the DOM, various normalizations + // will have occurred which will not be present in `markup`. Here, + // insert markup into a <div> or <iframe> depending on the container + // type to perform the same normalizations before comparing. + var normalizer; + if (container.nodeType === ELEMENT_NODE_TYPE) { + normalizer = document.createElement('div'); + normalizer.innerHTML = markup; + normalizedMarkup = normalizer.innerHTML; + } else { + normalizer = document.createElement('iframe'); + document.body.appendChild(normalizer); + normalizer.contentDocument.write(markup); + normalizedMarkup = normalizer.contentDocument.documentElement.outerHTML; + document.body.removeChild(normalizer); + } + } + + var diffIndex = firstDifferenceIndex(normalizedMarkup, rootMarkup); + var difference = ' (client) ' + normalizedMarkup.substring(diffIndex - 20, diffIndex + 20) + '\n (server) ' + rootMarkup.substring(diffIndex - 20, diffIndex + 20); + + !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document using server rendering but the checksum was invalid. This usually means you rendered a different component type or props on the client from the one on the server, or your render() methods are impure. React cannot handle this case due to cross-browser quirks by rendering at the document root. You should look for environment dependent code in your components and ensure the props are the same client and server side:\n%s', difference) : _prodInvariant('42', difference) : void 0; + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(false, 'React attempted to reuse markup in a container but the ' + 'checksum was invalid. This generally means that you are ' + 'using server rendering and the markup generated on the ' + 'server was not what the client was expecting. React injected ' + 'new markup to compensate which works but you have lost many ' + 'of the benefits of server rendering. Instead, figure out ' + 'why the markup being generated is different on the client ' + 'or server:\n%s', difference) : void 0; + } + } + } + + !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document but you didn\'t use server rendering. We can\'t do this without using server rendering due to cross-browser quirks. See ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('43') : void 0; + + if (transaction.useCreateElement) { + while (container.lastChild) { + container.removeChild(container.lastChild); + } + DOMLazyTree.insertTreeBefore(container, markup, null); + } else { + setInnerHTML(container, markup); + ReactDOMComponentTree.precacheNode(instance, container.firstChild); + } + + if (process.env.NODE_ENV !== 'production') { + var hostNode = ReactDOMComponentTree.getInstanceFromNode(container.firstChild); + if (hostNode._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: hostNode._debugID, + type: 'mount', + payload: markup.toString() + }); + } + } + } +}; + +module.exports = ReactMount; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 150 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactNodeTypes = __webpack_require__(142); + +function getHostComponentFromComposite(inst) { + var type; + + while ((type = inst._renderedNodeType) === ReactNodeTypes.COMPOSITE) { + inst = inst._renderedComponent; + } + + if (type === ReactNodeTypes.HOST) { + return inst._renderedComponent; + } else if (type === ReactNodeTypes.EMPTY) { + return null; + } +} + +module.exports = getHostComponentFromComposite; + +/***/ }), +/* 151 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +exports.__esModule = true; + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _chainFunction = __webpack_require__(323); + +var _chainFunction2 = _interopRequireDefault(_chainFunction); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _propTypes = __webpack_require__(40); + +var _propTypes2 = _interopRequireDefault(_propTypes); + +var _warning = __webpack_require__(324); + +var _warning2 = _interopRequireDefault(_warning); + +var _ChildMapping = __webpack_require__(325); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var propTypes = { + component: _propTypes2.default.any, + childFactory: _propTypes2.default.func, + children: _propTypes2.default.node +}; + +var defaultProps = { + component: 'span', + childFactory: function childFactory(child) { + return child; + } +}; + +var TransitionGroup = function (_React$Component) { + _inherits(TransitionGroup, _React$Component); + + function TransitionGroup(props, context) { + _classCallCheck(this, TransitionGroup); + + var _this = _possibleConstructorReturn(this, _React$Component.call(this, props, context)); + + _this.performAppear = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; + + if (component.componentWillAppear) { + component.componentWillAppear(_this._handleDoneAppearing.bind(_this, key, component)); + } else { + _this._handleDoneAppearing(key, component); + } + }; + + _this._handleDoneAppearing = function (key, component) { + if (component.componentDidAppear) { + component.componentDidAppear(); + } + + delete _this.currentlyTransitioningKeys[key]; + + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + + if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { + // This was removed before it had fully appeared. Remove it. + _this.performLeave(key, component); + } + }; + + _this.performEnter = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; + + if (component.componentWillEnter) { + component.componentWillEnter(_this._handleDoneEntering.bind(_this, key, component)); + } else { + _this._handleDoneEntering(key, component); + } + }; + + _this._handleDoneEntering = function (key, component) { + if (component.componentDidEnter) { + component.componentDidEnter(); + } + + delete _this.currentlyTransitioningKeys[key]; + + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + + if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { + // This was removed before it had fully entered. Remove it. + _this.performLeave(key, component); + } + }; + + _this.performLeave = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; + + if (component.componentWillLeave) { + component.componentWillLeave(_this._handleDoneLeaving.bind(_this, key, component)); + } else { + // Note that this is somewhat dangerous b/c it calls setState() + // again, effectively mutating the component before all the work + // is done. + _this._handleDoneLeaving(key, component); + } + }; + + _this._handleDoneLeaving = function (key, component) { + if (component.componentDidLeave) { + component.componentDidLeave(); + } + + delete _this.currentlyTransitioningKeys[key]; + + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + + if (currentChildMapping && currentChildMapping.hasOwnProperty(key)) { + // This entered again before it fully left. Add it again. + _this.keysToEnter.push(key); + } else { + _this.setState(function (state) { + var newChildren = _extends({}, state.children); + delete newChildren[key]; + return { children: newChildren }; + }); + } + }; + + _this.childRefs = Object.create(null); + + _this.state = { + children: (0, _ChildMapping.getChildMapping)(props.children) + }; + return _this; + } + + TransitionGroup.prototype.componentWillMount = function componentWillMount() { + this.currentlyTransitioningKeys = {}; + this.keysToEnter = []; + this.keysToLeave = []; + }; + + TransitionGroup.prototype.componentDidMount = function componentDidMount() { + var initialChildMapping = this.state.children; + for (var key in initialChildMapping) { + if (initialChildMapping[key]) { + this.performAppear(key, this.childRefs[key]); + } + } + }; + + TransitionGroup.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { + var nextChildMapping = (0, _ChildMapping.getChildMapping)(nextProps.children); + var prevChildMapping = this.state.children; + + this.setState({ + children: (0, _ChildMapping.mergeChildMappings)(prevChildMapping, nextChildMapping) + }); + + for (var key in nextChildMapping) { + var hasPrev = prevChildMapping && prevChildMapping.hasOwnProperty(key); + if (nextChildMapping[key] && !hasPrev && !this.currentlyTransitioningKeys[key]) { + this.keysToEnter.push(key); + } + } + + for (var _key in prevChildMapping) { + var hasNext = nextChildMapping && nextChildMapping.hasOwnProperty(_key); + if (prevChildMapping[_key] && !hasNext && !this.currentlyTransitioningKeys[_key]) { + this.keysToLeave.push(_key); + } + } + + // If we want to someday check for reordering, we could do it here. + }; + + TransitionGroup.prototype.componentDidUpdate = function componentDidUpdate() { + var _this2 = this; + + var keysToEnter = this.keysToEnter; + this.keysToEnter = []; + keysToEnter.forEach(function (key) { + return _this2.performEnter(key, _this2.childRefs[key]); + }); + + var keysToLeave = this.keysToLeave; + this.keysToLeave = []; + keysToLeave.forEach(function (key) { + return _this2.performLeave(key, _this2.childRefs[key]); + }); + }; + + TransitionGroup.prototype.render = function render() { + var _this3 = this; + + // TODO: we could get rid of the need for the wrapper node + // by cloning a single child + var childrenToRender = []; + + var _loop = function _loop(key) { + var child = _this3.state.children[key]; + if (child) { + var isCallbackRef = typeof child.ref !== 'string'; + var factoryChild = _this3.props.childFactory(child); + var ref = function ref(r) { + _this3.childRefs[key] = r; + }; + + process.env.NODE_ENV !== 'production' ? (0, _warning2.default)(isCallbackRef, 'string refs are not supported on children of TransitionGroup and will be ignored. ' + 'Please use a callback ref instead: https://facebook.github.io/react/docs/refs-and-the-dom.html#the-ref-callback-attribute') : void 0; + + // Always chaining the refs leads to problems when the childFactory + // wraps the child. The child ref callback gets called twice with the + // wrapper and the child. So we only need to chain the ref if the + // factoryChild is not different from child. + if (factoryChild === child && isCallbackRef) { + ref = (0, _chainFunction2.default)(child.ref, ref); + } + + // You may need to apply reactive updates to a child as it is leaving. + // The normal React way to do it won't work since the child will have + // already been removed. In case you need this behavior you can provide + // a childFactory function to wrap every child, even the ones that are + // leaving. + childrenToRender.push(_react2.default.cloneElement(factoryChild, { + key: key, + ref: ref + })); + } + }; + + for (var key in this.state.children) { + _loop(key); + } + + // Do not forward TransitionGroup props to primitive DOM nodes + var props = _extends({}, this.props); + delete props.transitionLeave; + delete props.transitionName; + delete props.transitionAppear; + delete props.transitionEnter; + delete props.childFactory; + delete props.transitionLeaveTimeout; + delete props.transitionEnterTimeout; + delete props.transitionAppearTimeout; + delete props.component; + + return _react2.default.createElement(this.props.component, props, childrenToRender); + }; + + return TransitionGroup; +}(_react2.default.Component); + +TransitionGroup.displayName = 'TransitionGroup'; + + +TransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; +TransitionGroup.defaultProps = defaultProps; + +exports.default = TransitionGroup; +module.exports = exports['default']; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 152 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = !!(typeof window !== 'undefined' && window.document && window.document.createElement); +module.exports = exports['default']; + +/***/ }), +/* 153 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.__esModule = true; +exports.nameShape = undefined; +exports.transitionTimeout = transitionTimeout; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _propTypes = __webpack_require__(40); + +var _propTypes2 = _interopRequireDefault(_propTypes); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function transitionTimeout(transitionType) { + var timeoutPropName = 'transition' + transitionType + 'Timeout'; + var enabledPropName = 'transition' + transitionType; + + return function (props) { + // If the transition is enabled + if (props[enabledPropName]) { + // If no timeout duration is provided + if (props[timeoutPropName] == null) { + return new Error(timeoutPropName + ' wasn\'t supplied to CSSTransitionGroup: ' + 'this can cause unreliable animations and won\'t be supported in ' + 'a future version of React. See ' + 'https://fb.me/react-animation-transition-group-timeout for more ' + 'information.'); + + // If the duration isn't a number + } else if (typeof props[timeoutPropName] !== 'number') { + return new Error(timeoutPropName + ' must be a number (in milliseconds)'); + } + } + + return null; + }; +} + +var nameShape = exports.nameShape = _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.shape({ + enter: _propTypes2.default.string, + leave: _propTypes2.default.string, + active: _propTypes2.default.string +}), _propTypes2.default.shape({ + enter: _propTypes2.default.string, + enterActive: _propTypes2.default.string, + leave: _propTypes2.default.string, + leaveActive: _propTypes2.default.string, + appear: _propTypes2.default.string, + appearActive: _propTypes2.default.string +})]); + +/***/ }), +/* 154 */ +/***/ (function(module, exports) { + +var toString = {}.toString; + +module.exports = Array.isArray || function (arr) { + return toString.call(arr) == '[object Array]'; +}; + + +/***/ }), +/* 155 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +module.exports = function bind(fn, thisArg) { + return function wrap() { + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; + } + return fn.apply(thisArg, args); + }; +}; + + +/***/ }), +/* 156 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +var utils = __webpack_require__(20); +var settle = __webpack_require__(340); +var buildURL = __webpack_require__(342); +var parseHeaders = __webpack_require__(343); +var isURLSameOrigin = __webpack_require__(344); +var createError = __webpack_require__(157); +var btoa = (typeof window !== 'undefined' && window.btoa && window.btoa.bind(window)) || __webpack_require__(345); + +module.exports = function xhrAdapter(config) { + return new Promise(function dispatchXhrRequest(resolve, reject) { + var requestData = config.data; + var requestHeaders = config.headers; + + if (utils.isFormData(requestData)) { + delete requestHeaders['Content-Type']; // Let the browser set it + } + + var request = new XMLHttpRequest(); + var loadEvent = 'onreadystatechange'; + var xDomain = false; + + // For IE 8/9 CORS support + // Only supports POST and GET calls and doesn't returns the response headers. + // DON'T do this for testing b/c XMLHttpRequest is mocked, not XDomainRequest. + if (process.env.NODE_ENV !== 'test' && + typeof window !== 'undefined' && + window.XDomainRequest && !('withCredentials' in request) && + !isURLSameOrigin(config.url)) { + request = new window.XDomainRequest(); + loadEvent = 'onload'; + xDomain = true; + request.onprogress = function handleProgress() {}; + request.ontimeout = function handleTimeout() {}; + } + + // HTTP basic authentication + if (config.auth) { + var username = config.auth.username || ''; + var password = config.auth.password || ''; + requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password); + } + + request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true); + + // Set the request timeout in MS + request.timeout = config.timeout; + + // Listen for ready state + request[loadEvent] = function handleLoad() { + if (!request || (request.readyState !== 4 && !xDomain)) { + return; + } + + // The request errored out and we didn't get a response, this will be + // handled by onerror instead + // With one exception: request that using file: protocol, most browsers + // will return status as 0 even though it's a successful request + if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) { + return; + } + + // Prepare the response + var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null; + var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response; + var response = { + data: responseData, + // IE sends 1223 instead of 204 (https://github.com/mzabriskie/axios/issues/201) + status: request.status === 1223 ? 204 : request.status, + statusText: request.status === 1223 ? 'No Content' : request.statusText, + headers: responseHeaders, + config: config, + request: request + }; + + settle(resolve, reject, response); + + // Clean up request + request = null; + }; + + // Handle low level network errors + request.onerror = function handleError() { + // Real errors are hidden from us by the browser + // onerror should only fire if it's a network error + reject(createError('Network Error', config, null, request)); + + // Clean up request + request = null; + }; + + // Handle timeout + request.ontimeout = function handleTimeout() { + reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED', + request)); + + // Clean up request + request = null; + }; + + // Add xsrf header + // This is only done if running in a standard browser environment. + // Specifically not if we're in a web worker, or react-native. + if (utils.isStandardBrowserEnv()) { + var cookies = __webpack_require__(346); + + // Add xsrf header + var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ? + cookies.read(config.xsrfCookieName) : + undefined; + + if (xsrfValue) { + requestHeaders[config.xsrfHeaderName] = xsrfValue; + } + } + + // Add headers to the request + if ('setRequestHeader' in request) { + utils.forEach(requestHeaders, function setRequestHeader(val, key) { + if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') { + // Remove Content-Type if data is undefined + delete requestHeaders[key]; + } else { + // Otherwise add header to the request + request.setRequestHeader(key, val); + } + }); + } + + // Add withCredentials to request if needed + if (config.withCredentials) { + request.withCredentials = true; + } + + // Add responseType to request if needed + if (config.responseType) { + try { + request.responseType = config.responseType; + } catch (e) { + // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2. + // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function. + if (config.responseType !== 'json') { + throw e; + } + } + } + + // Handle progress if needed + if (typeof config.onDownloadProgress === 'function') { + request.addEventListener('progress', config.onDownloadProgress); + } + + // Not all browsers support upload events + if (typeof config.onUploadProgress === 'function' && request.upload) { + request.upload.addEventListener('progress', config.onUploadProgress); + } + + if (config.cancelToken) { + // Handle cancellation + config.cancelToken.promise.then(function onCanceled(cancel) { + if (!request) { + return; + } + + request.abort(); + reject(cancel); + // Clean up request + request = null; + }); + } + + if (requestData === undefined) { + requestData = null; + } + + // Send the request + request.send(requestData); + }); +}; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 157 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var enhanceError = __webpack_require__(341); + +/** + * Create an Error with the specified message, config, error code, request and response. + * + * @param {string} message The error message. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The created error. + */ +module.exports = function createError(message, config, code, request, response) { + var error = new Error(message); + return enhanceError(error, config, code, request, response); +}; + + +/***/ }), +/* 158 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +module.exports = function isCancel(value) { + return !!(value && value.__CANCEL__); +}; + + +/***/ }), +/* 159 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * A `Cancel` is an object that is thrown when an operation is canceled. + * + * @class + * @param {string=} message The message. + */ +function Cancel(message) { + this.message = message; +} + +Cancel.prototype.toString = function toString() { + return 'Cancel' + (this.message ? ': ' + this.message : ''); +}; + +Cancel.prototype.__CANCEL__ = true; + +module.exports = Cancel; + + +/***/ }), +/* 160 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = { + address: __webpack_require__(96), + config: __webpack_require__(66), + zaddress: __webpack_require__(412), + crypto: __webpack_require__(107), + transaction: __webpack_require__(458) +}; + +/***/ }), +/* 161 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(global, process) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + + + +/*<replacement>*/ + +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +module.exports = Readable; + +/*<replacement>*/ +var isArray = __webpack_require__(154); +/*</replacement>*/ + +/*<replacement>*/ +var Duplex; +/*</replacement>*/ + +Readable.ReadableState = ReadableState; + +/*<replacement>*/ +var EE = __webpack_require__(99).EventEmitter; + +var EElistenerCount = function (emitter, type) { + return emitter.listeners(type).length; +}; +/*</replacement>*/ + +/*<replacement>*/ +var Stream = __webpack_require__(162); +/*</replacement>*/ + +// TODO(bmeurer): Change this back to const once hole checks are +// properly optimized away early in Ignition+TurboFan. +/*<replacement>*/ +var Buffer = __webpack_require__(7).Buffer; +var OurUint8Array = global.Uint8Array || function () {}; +function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk); +} +function _isUint8Array(obj) { + return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; +} +/*</replacement>*/ + +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ + +/*<replacement>*/ +var debugUtil = __webpack_require__(367); +var debug = void 0; +if (debugUtil && debugUtil.debuglog) { + debug = debugUtil.debuglog('stream'); +} else { + debug = function () {}; +} +/*</replacement>*/ + +var BufferList = __webpack_require__(368); +var destroyImpl = __webpack_require__(163); +var StringDecoder; + +util.inherits(Readable, Stream); + +var kProxyEvents = ['error', 'close', 'destroy', 'pause', 'resume']; + +function prependListener(emitter, event, fn) { + // Sadly this is not cacheable as some libraries bundle their own + // event emitter implementation with them. + if (typeof emitter.prependListener === 'function') { + return emitter.prependListener(event, fn); + } else { + // This is a hack to make sure that our error handler is attached before any + // userland ones. NEVER DO THIS. This is here only because this code needs + // to continue to work with older versions of Node.js that do not include + // the prependListener() method. The goal is to eventually remove this hack. + if (!emitter._events || !emitter._events[event]) emitter.on(event, fn);else if (isArray(emitter._events[event])) emitter._events[event].unshift(fn);else emitter._events[event] = [fn, emitter._events[event]]; + } +} + +function ReadableState(options, stream) { + Duplex = Duplex || __webpack_require__(34); + + options = options || {}; + + // object stream flag. Used to make read(n) ignore n and to + // make all the buffer merging and length checks go away + this.objectMode = !!options.objectMode; + + if (stream instanceof Duplex) this.objectMode = this.objectMode || !!options.readableObjectMode; + + // the point at which it stops calling _read() to fill the buffer + // Note: 0 is a valid value, means "don't call _read preemptively ever" + var hwm = options.highWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; + this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm; + + // cast to ints. + this.highWaterMark = Math.floor(this.highWaterMark); + + // A linked list is used to store data chunks instead of an array because the + // linked list can remove elements from the beginning faster than + // array.shift() + this.buffer = new BufferList(); + this.length = 0; + this.pipes = null; + this.pipesCount = 0; + this.flowing = null; + this.ended = false; + this.endEmitted = false; + this.reading = false; + + // a flag to be able to tell if the event 'readable'/'data' is emitted + // immediately, or on a later tick. We set this to true at first, because + // any actions that shouldn't happen until "later" should generally also + // not happen before the first read call. + this.sync = true; + + // whenever we return null, then we set a flag to say + // that we're awaiting a 'readable' event emission. + this.needReadable = false; + this.emittedReadable = false; + this.readableListening = false; + this.resumeScheduled = false; + + // has it been destroyed + this.destroyed = false; + + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; + + // the number of writers that are awaiting a drain event in .pipe()s + this.awaitDrain = 0; + + // if true, a maybeReadMore has been scheduled + this.readingMore = false; + + this.decoder = null; + this.encoding = null; + if (options.encoding) { + if (!StringDecoder) StringDecoder = __webpack_require__(102).StringDecoder; + this.decoder = new StringDecoder(options.encoding); + this.encoding = options.encoding; + } +} + +function Readable(options) { + Duplex = Duplex || __webpack_require__(34); + + if (!(this instanceof Readable)) return new Readable(options); + + this._readableState = new ReadableState(options, this); + + // legacy + this.readable = true; + + if (options) { + if (typeof options.read === 'function') this._read = options.read; + + if (typeof options.destroy === 'function') this._destroy = options.destroy; + } + + Stream.call(this); +} + +Object.defineProperty(Readable.prototype, 'destroyed', { + get: function () { + if (this._readableState === undefined) { + return false; + } + return this._readableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (!this._readableState) { + return; + } + + // backward compatibility, the user is explicitly + // managing destroyed + this._readableState.destroyed = value; + } +}); + +Readable.prototype.destroy = destroyImpl.destroy; +Readable.prototype._undestroy = destroyImpl.undestroy; +Readable.prototype._destroy = function (err, cb) { + this.push(null); + cb(err); +}; + +// Manually shove something into the read() buffer. +// This returns true if the highWaterMark has not been hit yet, +// similar to how Writable.write() returns true if you should +// write() some more. +Readable.prototype.push = function (chunk, encoding) { + var state = this._readableState; + var skipChunkCheck; + + if (!state.objectMode) { + if (typeof chunk === 'string') { + encoding = encoding || state.defaultEncoding; + if (encoding !== state.encoding) { + chunk = Buffer.from(chunk, encoding); + encoding = ''; + } + skipChunkCheck = true; + } + } else { + skipChunkCheck = true; + } + + return readableAddChunk(this, chunk, encoding, false, skipChunkCheck); +}; + +// Unshift should *always* be something directly out of read() +Readable.prototype.unshift = function (chunk) { + return readableAddChunk(this, chunk, null, true, false); +}; + +function readableAddChunk(stream, chunk, encoding, addToFront, skipChunkCheck) { + var state = stream._readableState; + if (chunk === null) { + state.reading = false; + onEofChunk(stream, state); + } else { + var er; + if (!skipChunkCheck) er = chunkInvalid(state, chunk); + if (er) { + stream.emit('error', er); + } else if (state.objectMode || chunk && chunk.length > 0) { + if (typeof chunk !== 'string' && !state.objectMode && Object.getPrototypeOf(chunk) !== Buffer.prototype) { + chunk = _uint8ArrayToBuffer(chunk); + } + + if (addToFront) { + if (state.endEmitted) stream.emit('error', new Error('stream.unshift() after end event'));else addChunk(stream, state, chunk, true); + } else if (state.ended) { + stream.emit('error', new Error('stream.push() after EOF')); + } else { + state.reading = false; + if (state.decoder && !encoding) { + chunk = state.decoder.write(chunk); + if (state.objectMode || chunk.length !== 0) addChunk(stream, state, chunk, false);else maybeReadMore(stream, state); + } else { + addChunk(stream, state, chunk, false); + } + } + } else if (!addToFront) { + state.reading = false; + } + } + + return needMoreData(state); +} + +function addChunk(stream, state, chunk, addToFront) { + if (state.flowing && state.length === 0 && !state.sync) { + stream.emit('data', chunk); + stream.read(0); + } else { + // update the buffer info. + state.length += state.objectMode ? 1 : chunk.length; + if (addToFront) state.buffer.unshift(chunk);else state.buffer.push(chunk); + + if (state.needReadable) emitReadable(stream); + } + maybeReadMore(stream, state); +} + +function chunkInvalid(state, chunk) { + var er; + if (!_isUint8Array(chunk) && typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); + } + return er; +} + +// if it's past the high water mark, we can push in some more. +// Also, if we have no data yet, we can stand some +// more bytes. This is to work around cases where hwm=0, +// such as the repl. Also, if the push() triggered a +// readable event, and the user called read(largeNumber) such that +// needReadable was set, then we ought to push more, so that another +// 'readable' event will be triggered. +function needMoreData(state) { + return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0); +} + +Readable.prototype.isPaused = function () { + return this._readableState.flowing === false; +}; + +// backwards compatibility. +Readable.prototype.setEncoding = function (enc) { + if (!StringDecoder) StringDecoder = __webpack_require__(102).StringDecoder; + this._readableState.decoder = new StringDecoder(enc); + this._readableState.encoding = enc; + return this; +}; + +// Don't raise the hwm > 8MB +var MAX_HWM = 0x800000; +function computeNewHighWaterMark(n) { + if (n >= MAX_HWM) { + n = MAX_HWM; + } else { + // Get the next highest power of 2 to prevent increasing hwm excessively in + // tiny amounts + n--; + n |= n >>> 1; + n |= n >>> 2; + n |= n >>> 4; + n |= n >>> 8; + n |= n >>> 16; + n++; + } + return n; +} + +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function howMuchToRead(n, state) { + if (n <= 0 || state.length === 0 && state.ended) return 0; + if (state.objectMode) return 1; + if (n !== n) { + // Only flow one buffer at a time + if (state.flowing && state.length) return state.buffer.head.data.length;else return state.length; + } + // If we're asking for more than the current hwm, then raise the hwm. + if (n > state.highWaterMark) state.highWaterMark = computeNewHighWaterMark(n); + if (n <= state.length) return n; + // Don't have enough + if (!state.ended) { + state.needReadable = true; + return 0; + } + return state.length; +} + +// you can override either this method, or the async _read(n) below. +Readable.prototype.read = function (n) { + debug('read', n); + n = parseInt(n, 10); + var state = this._readableState; + var nOrig = n; + + if (n !== 0) state.emittedReadable = false; + + // if we're doing read(0) to trigger a readable event, but we + // already have a bunch of data in the buffer, then just trigger + // the 'readable' event and move on. + if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) { + debug('read: emitReadable', state.length, state.ended); + if (state.length === 0 && state.ended) endReadable(this);else emitReadable(this); + return null; + } + + n = howMuchToRead(n, state); + + // if we've ended, and we're now clear, then finish it up. + if (n === 0 && state.ended) { + if (state.length === 0) endReadable(this); + return null; + } + + // All the actual chunk generation logic needs to be + // *below* the call to _read. The reason is that in certain + // synthetic stream cases, such as passthrough streams, _read + // may be a completely synchronous operation which may change + // the state of the read buffer, providing enough data when + // before there was *not* enough. + // + // So, the steps are: + // 1. Figure out what the state of things will be after we do + // a read from the buffer. + // + // 2. If that resulting state will trigger a _read, then call _read. + // Note that this may be asynchronous, or synchronous. Yes, it is + // deeply ugly to write APIs this way, but that still doesn't mean + // that the Readable class should behave improperly, as streams are + // designed to be sync/async agnostic. + // Take note if the _read call is sync or async (ie, if the read call + // has returned yet), so that we know whether or not it's safe to emit + // 'readable' etc. + // + // 3. Actually pull the requested chunks out of the buffer and return. + + // if we need a readable event, then we need to do some reading. + var doRead = state.needReadable; + debug('need readable', doRead); + + // if we currently have less than the highWaterMark, then also read some + if (state.length === 0 || state.length - n < state.highWaterMark) { + doRead = true; + debug('length less than watermark', doRead); + } + + // however, if we've ended, then there's no point, and if we're already + // reading, then it's unnecessary. + if (state.ended || state.reading) { + doRead = false; + debug('reading or ended', doRead); + } else if (doRead) { + debug('do read'); + state.reading = true; + state.sync = true; + // if the length is currently zero, then we *need* a readable event. + if (state.length === 0) state.needReadable = true; + // call internal read method + this._read(state.highWaterMark); + state.sync = false; + // If _read pushed data synchronously, then `reading` will be false, + // and we need to re-evaluate how much data we can return to the user. + if (!state.reading) n = howMuchToRead(nOrig, state); + } + + var ret; + if (n > 0) ret = fromList(n, state);else ret = null; + + if (ret === null) { + state.needReadable = true; + n = 0; + } else { + state.length -= n; + } + + if (state.length === 0) { + // If we have nothing in the buffer, then we want to know + // as soon as we *do* get something into the buffer. + if (!state.ended) state.needReadable = true; + + // If we tried to read() past the EOF, then emit end on the next tick. + if (nOrig !== n && state.ended) endReadable(this); + } + + if (ret !== null) this.emit('data', ret); + + return ret; +}; + +function onEofChunk(stream, state) { + if (state.ended) return; + if (state.decoder) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) { + state.buffer.push(chunk); + state.length += state.objectMode ? 1 : chunk.length; + } + } + state.ended = true; + + // emit 'readable' now to make sure it gets picked up. + emitReadable(stream); +} + +// Don't emit readable right away in sync mode, because this can trigger +// another read() call => stack overflow. This way, it might trigger +// a nextTick recursion warning, but that's not so bad. +function emitReadable(stream) { + var state = stream._readableState; + state.needReadable = false; + if (!state.emittedReadable) { + debug('emitReadable', state.flowing); + state.emittedReadable = true; + if (state.sync) processNextTick(emitReadable_, stream);else emitReadable_(stream); + } +} + +function emitReadable_(stream) { + debug('emit readable'); + stream.emit('readable'); + flow(stream); +} + +// at this point, the user has presumably seen the 'readable' event, +// and called read() to consume some data. that may have triggered +// in turn another _read(n) call, in which case reading = true if +// it's in progress. +// However, if we're not ended, or reading, and the length < hwm, +// then go ahead and try to read some more preemptively. +function maybeReadMore(stream, state) { + if (!state.readingMore) { + state.readingMore = true; + processNextTick(maybeReadMore_, stream, state); + } +} + +function maybeReadMore_(stream, state) { + var len = state.length; + while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) { + debug('maybeReadMore read 0'); + stream.read(0); + if (len === state.length) + // didn't get any data, stop spinning. + break;else len = state.length; + } + state.readingMore = false; +} + +// abstract method. to be overridden in specific implementation classes. +// call cb(er, data) where data is <= n in length. +// for virtual (non-string, non-buffer) streams, "length" is somewhat +// arbitrary, and perhaps not very meaningful. +Readable.prototype._read = function (n) { + this.emit('error', new Error('_read() is not implemented')); +}; + +Readable.prototype.pipe = function (dest, pipeOpts) { + var src = this; + var state = this._readableState; + + switch (state.pipesCount) { + case 0: + state.pipes = dest; + break; + case 1: + state.pipes = [state.pipes, dest]; + break; + default: + state.pipes.push(dest); + break; + } + state.pipesCount += 1; + debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts); + + var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr; + + var endFn = doEnd ? onend : unpipe; + if (state.endEmitted) processNextTick(endFn);else src.once('end', endFn); + + dest.on('unpipe', onunpipe); + function onunpipe(readable, unpipeInfo) { + debug('onunpipe'); + if (readable === src) { + if (unpipeInfo && unpipeInfo.hasUnpiped === false) { + unpipeInfo.hasUnpiped = true; + cleanup(); + } + } + } + + function onend() { + debug('onend'); + dest.end(); + } + + // when the dest drains, it reduces the awaitDrain counter + // on the source. This would be more elegant with a .once() + // handler in flow(), but adding and removing repeatedly is + // too slow. + var ondrain = pipeOnDrain(src); + dest.on('drain', ondrain); + + var cleanedUp = false; + function cleanup() { + debug('cleanup'); + // cleanup event handlers once the pipe is broken + dest.removeListener('close', onclose); + dest.removeListener('finish', onfinish); + dest.removeListener('drain', ondrain); + dest.removeListener('error', onerror); + dest.removeListener('unpipe', onunpipe); + src.removeListener('end', onend); + src.removeListener('end', unpipe); + src.removeListener('data', ondata); + + cleanedUp = true; + + // if the reader is waiting for a drain event from this + // specific writer, then it would cause it to never start + // flowing again. + // So, if this is awaiting a drain, then we just call it now. + // If we don't know, then assume that we are waiting for one. + if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain)) ondrain(); + } + + // If the user pushes more data while we're writing to dest then we'll end up + // in ondata again. However, we only want to increase awaitDrain once because + // dest will only emit one 'drain' event for the multiple writes. + // => Introduce a guard on increasing awaitDrain. + var increasedAwaitDrain = false; + src.on('data', ondata); + function ondata(chunk) { + debug('ondata'); + increasedAwaitDrain = false; + var ret = dest.write(chunk); + if (false === ret && !increasedAwaitDrain) { + // If the user unpiped during `dest.write()`, it is possible + // to get stuck in a permanently paused state if that write + // also returned false. + // => Check whether `dest` is still a piping destination. + if ((state.pipesCount === 1 && state.pipes === dest || state.pipesCount > 1 && indexOf(state.pipes, dest) !== -1) && !cleanedUp) { + debug('false write response, pause', src._readableState.awaitDrain); + src._readableState.awaitDrain++; + increasedAwaitDrain = true; + } + src.pause(); + } + } + + // if the dest has an error, then stop piping into it. + // however, don't suppress the throwing behavior for this. + function onerror(er) { + debug('onerror', er); + unpipe(); + dest.removeListener('error', onerror); + if (EElistenerCount(dest, 'error') === 0) dest.emit('error', er); + } + + // Make sure our error handler is attached before userland ones. + prependListener(dest, 'error', onerror); + + // Both close and finish should trigger unpipe, but only once. + function onclose() { + dest.removeListener('finish', onfinish); + unpipe(); + } + dest.once('close', onclose); + function onfinish() { + debug('onfinish'); + dest.removeListener('close', onclose); + unpipe(); + } + dest.once('finish', onfinish); + + function unpipe() { + debug('unpipe'); + src.unpipe(dest); + } + + // tell the dest that it's being piped to + dest.emit('pipe', src); + + // start the flow if it hasn't been started already. + if (!state.flowing) { + debug('pipe resume'); + src.resume(); + } + + return dest; +}; + +function pipeOnDrain(src) { + return function () { + var state = src._readableState; + debug('pipeOnDrain', state.awaitDrain); + if (state.awaitDrain) state.awaitDrain--; + if (state.awaitDrain === 0 && EElistenerCount(src, 'data')) { + state.flowing = true; + flow(src); + } + }; +} + +Readable.prototype.unpipe = function (dest) { + var state = this._readableState; + var unpipeInfo = { hasUnpiped: false }; + + // if we're not piping anywhere, then do nothing. + if (state.pipesCount === 0) return this; + + // just one destination. most common case. + if (state.pipesCount === 1) { + // passed in one, but it's not the right one. + if (dest && dest !== state.pipes) return this; + + if (!dest) dest = state.pipes; + + // got a match. + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + if (dest) dest.emit('unpipe', this, unpipeInfo); + return this; + } + + // slow case. multiple pipe destinations. + + if (!dest) { + // remove all. + var dests = state.pipes; + var len = state.pipesCount; + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + + for (var i = 0; i < len; i++) { + dests[i].emit('unpipe', this, unpipeInfo); + }return this; + } + + // try to find the right one. + var index = indexOf(state.pipes, dest); + if (index === -1) return this; + + state.pipes.splice(index, 1); + state.pipesCount -= 1; + if (state.pipesCount === 1) state.pipes = state.pipes[0]; + + dest.emit('unpipe', this, unpipeInfo); + + return this; +}; + +// set up data events if they are asked for +// Ensure readable listeners eventually get something +Readable.prototype.on = function (ev, fn) { + var res = Stream.prototype.on.call(this, ev, fn); + + if (ev === 'data') { + // Start flowing on next tick if stream isn't explicitly paused + if (this._readableState.flowing !== false) this.resume(); + } else if (ev === 'readable') { + var state = this._readableState; + if (!state.endEmitted && !state.readableListening) { + state.readableListening = state.needReadable = true; + state.emittedReadable = false; + if (!state.reading) { + processNextTick(nReadingNextTick, this); + } else if (state.length) { + emitReadable(this); + } + } + } + + return res; +}; +Readable.prototype.addListener = Readable.prototype.on; + +function nReadingNextTick(self) { + debug('readable nexttick read 0'); + self.read(0); +} + +// pause() and resume() are remnants of the legacy readable stream API +// If the user uses them, then switch into old mode. +Readable.prototype.resume = function () { + var state = this._readableState; + if (!state.flowing) { + debug('resume'); + state.flowing = true; + resume(this, state); + } + return this; +}; + +function resume(stream, state) { + if (!state.resumeScheduled) { + state.resumeScheduled = true; + processNextTick(resume_, stream, state); + } +} + +function resume_(stream, state) { + if (!state.reading) { + debug('resume read 0'); + stream.read(0); + } + + state.resumeScheduled = false; + state.awaitDrain = 0; + stream.emit('resume'); + flow(stream); + if (state.flowing && !state.reading) stream.read(0); +} + +Readable.prototype.pause = function () { + debug('call pause flowing=%j', this._readableState.flowing); + if (false !== this._readableState.flowing) { + debug('pause'); + this._readableState.flowing = false; + this.emit('pause'); + } + return this; +}; + +function flow(stream) { + var state = stream._readableState; + debug('flow', state.flowing); + while (state.flowing && stream.read() !== null) {} +} + +// wrap an old-style stream as the async data source. +// This is *not* part of the readable stream interface. +// It is an ugly unfortunate mess of history. +Readable.prototype.wrap = function (stream) { + var state = this._readableState; + var paused = false; + + var self = this; + stream.on('end', function () { + debug('wrapped end'); + if (state.decoder && !state.ended) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) self.push(chunk); + } + + self.push(null); + }); + + stream.on('data', function (chunk) { + debug('wrapped data'); + if (state.decoder) chunk = state.decoder.write(chunk); + + // don't skip over falsy values in objectMode + if (state.objectMode && (chunk === null || chunk === undefined)) return;else if (!state.objectMode && (!chunk || !chunk.length)) return; + + var ret = self.push(chunk); + if (!ret) { + paused = true; + stream.pause(); + } + }); + + // proxy all the other methods. + // important when wrapping filters and duplexes. + for (var i in stream) { + if (this[i] === undefined && typeof stream[i] === 'function') { + this[i] = function (method) { + return function () { + return stream[method].apply(stream, arguments); + }; + }(i); + } + } + + // proxy certain important events. + for (var n = 0; n < kProxyEvents.length; n++) { + stream.on(kProxyEvents[n], self.emit.bind(self, kProxyEvents[n])); + } + + // when we try to consume some more bytes, simply unpause the + // underlying stream. + self._read = function (n) { + debug('wrapped _read', n); + if (paused) { + paused = false; + stream.resume(); + } + }; + + return self; +}; + +// exposed for testing purposes only. +Readable._fromList = fromList; + +// Pluck off n bytes from an array of buffers. +// Length is the combined lengths of all the buffers in the list. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function fromList(n, state) { + // nothing buffered + if (state.length === 0) return null; + + var ret; + if (state.objectMode) ret = state.buffer.shift();else if (!n || n >= state.length) { + // read it all, truncate the list + if (state.decoder) ret = state.buffer.join('');else if (state.buffer.length === 1) ret = state.buffer.head.data;else ret = state.buffer.concat(state.length); + state.buffer.clear(); + } else { + // read part of list + ret = fromListPartial(n, state.buffer, state.decoder); + } + + return ret; +} + +// Extracts only enough buffered data to satisfy the amount requested. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function fromListPartial(n, list, hasStrings) { + var ret; + if (n < list.head.data.length) { + // slice is the same for buffers and strings + ret = list.head.data.slice(0, n); + list.head.data = list.head.data.slice(n); + } else if (n === list.head.data.length) { + // first chunk is a perfect match + ret = list.shift(); + } else { + // result spans more than one buffer + ret = hasStrings ? copyFromBufferString(n, list) : copyFromBuffer(n, list); + } + return ret; +} + +// Copies a specified amount of characters from the list of buffered data +// chunks. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function copyFromBufferString(n, list) { + var p = list.head; + var c = 1; + var ret = p.data; + n -= ret.length; + while (p = p.next) { + var str = p.data; + var nb = n > str.length ? str.length : n; + if (nb === str.length) ret += str;else ret += str.slice(0, n); + n -= nb; + if (n === 0) { + if (nb === str.length) { + ++c; + if (p.next) list.head = p.next;else list.head = list.tail = null; + } else { + list.head = p; + p.data = str.slice(nb); + } + break; + } + ++c; + } + list.length -= c; + return ret; +} + +// Copies a specified amount of bytes from the list of buffered data chunks. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function copyFromBuffer(n, list) { + var ret = Buffer.allocUnsafe(n); + var p = list.head; + var c = 1; + p.data.copy(ret); + n -= p.data.length; + while (p = p.next) { + var buf = p.data; + var nb = n > buf.length ? buf.length : n; + buf.copy(ret, ret.length - n, 0, nb); + n -= nb; + if (n === 0) { + if (nb === buf.length) { + ++c; + if (p.next) list.head = p.next;else list.head = list.tail = null; + } else { + list.head = p; + p.data = buf.slice(nb); + } + break; + } + ++c; + } + list.length -= c; + return ret; +} + +function endReadable(stream) { + var state = stream._readableState; + + // If we get here before consuming all the bytes, then that is a + // bug in node. Should never happen. + if (state.length > 0) throw new Error('"endReadable()" called on non-empty stream'); + + if (!state.endEmitted) { + state.ended = true; + processNextTick(endReadableNT, state, stream); + } +} + +function endReadableNT(state, stream) { + // Check that we didn't get one last unshift. + if (!state.endEmitted && state.length === 0) { + state.endEmitted = true; + stream.readable = false; + stream.emit('end'); + } +} + +function forEach(xs, f) { + for (var i = 0, l = xs.length; i < l; i++) { + f(xs[i], i); + } +} + +function indexOf(xs, x) { + for (var i = 0, l = xs.length; i < l; i++) { + if (xs[i] === x) return i; + } + return -1; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) + +/***/ }), +/* 162 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(99).EventEmitter; + + +/***/ }), +/* 163 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/*<replacement>*/ + +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +// undocumented cb() API, needed for core, not for public API +function destroy(err, cb) { + var _this = this; + + var readableDestroyed = this._readableState && this._readableState.destroyed; + var writableDestroyed = this._writableState && this._writableState.destroyed; + + if (readableDestroyed || writableDestroyed) { + if (cb) { + cb(err); + } else if (err && (!this._writableState || !this._writableState.errorEmitted)) { + processNextTick(emitErrorNT, this, err); + } + return; + } + + // we set destroyed to true before firing error callbacks in order + // to make it re-entrance safe in case destroy() is called within callbacks + + if (this._readableState) { + this._readableState.destroyed = true; + } + + // if this is a duplex stream mark the writable part as destroyed as well + if (this._writableState) { + this._writableState.destroyed = true; + } + + this._destroy(err || null, function (err) { + if (!cb && err) { + processNextTick(emitErrorNT, _this, err); + if (_this._writableState) { + _this._writableState.errorEmitted = true; + } + } else if (cb) { + cb(err); + } + }); +} + +function undestroy() { + if (this._readableState) { + this._readableState.destroyed = false; + this._readableState.reading = false; + this._readableState.ended = false; + this._readableState.endEmitted = false; + } + + if (this._writableState) { + this._writableState.destroyed = false; + this._writableState.ended = false; + this._writableState.ending = false; + this._writableState.finished = false; + this._writableState.errorEmitted = false; + } +} + +function emitErrorNT(self, err) { + self.emit('error', err); +} + +module.exports = { + destroy: destroy, + undestroy: undestroy +}; + +/***/ }), +/* 164 */ +/***/ (function(module, exports, __webpack_require__) { + +var apply = Function.prototype.apply; + +// DOM APIs, for completeness + +exports.setTimeout = function() { + return new Timeout(apply.call(setTimeout, window, arguments), clearTimeout); +}; +exports.setInterval = function() { + return new Timeout(apply.call(setInterval, window, arguments), clearInterval); +}; +exports.clearTimeout = +exports.clearInterval = function(timeout) { + if (timeout) { + timeout.close(); + } +}; + +function Timeout(id, clearFn) { + this._id = id; + this._clearFn = clearFn; +} +Timeout.prototype.unref = Timeout.prototype.ref = function() {}; +Timeout.prototype.close = function() { + this._clearFn.call(window, this._id); +}; + +// Does not start the time, just sets up the members needed. +exports.enroll = function(item, msecs) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = msecs; +}; + +exports.unenroll = function(item) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = -1; +}; + +exports._unrefActive = exports.active = function(item) { + clearTimeout(item._idleTimeoutId); + + var msecs = item._idleTimeout; + if (msecs >= 0) { + item._idleTimeoutId = setTimeout(function onTimeout() { + if (item._onTimeout) + item._onTimeout(); + }, msecs); + } +}; + +// setimmediate attaches itself to the global object +__webpack_require__(369); +exports.setImmediate = setImmediate; +exports.clearImmediate = clearImmediate; + + +/***/ }), +/* 165 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a transform stream is a readable/writable stream where you do +// something with the data. Sometimes it's called a "filter", +// but that's not a great name for it, since that implies a thing where +// some bits pass through, and others are simply ignored. (That would +// be a valid example of a transform, of course.) +// +// While the output is causally related to the input, it's not a +// necessarily symmetric or synchronous transformation. For example, +// a zlib stream might take multiple plain-text writes(), and then +// emit a single compressed chunk some time in the future. +// +// Here's how this works: +// +// The Transform stream has all the aspects of the readable and writable +// stream classes. When you write(chunk), that calls _write(chunk,cb) +// internally, and returns false if there's a lot of pending writes +// buffered up. When you call read(), that calls _read(n) until +// there's enough pending readable data buffered up. +// +// In a transform stream, the written data is placed in a buffer. When +// _read(n) is called, it transforms the queued up data, calling the +// buffered _write cb's as it consumes chunks. If consuming a single +// written chunk would result in multiple output chunks, then the first +// outputted bit calls the readcb, and subsequent chunks just go into +// the read buffer, and will cause it to emit 'readable' if necessary. +// +// This way, back-pressure is actually determined by the reading side, +// since _read has to be called to start processing a new chunk. However, +// a pathological inflate type of transform can cause excessive buffering +// here. For example, imagine a stream where every byte of input is +// interpreted as an integer from 0-255, and then results in that many +// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in +// 1kb of data being output. In this case, you could write a very small +// amount of input, and end up with a very large amount of output. In +// such a pathological inflating mechanism, there'd be no way to tell +// the system to stop doing the transform. A single 4MB write could +// cause the system to run out of memory. +// +// However, even in such a pathological case, only a single written chunk +// would be consumed, and then the rest would wait (un-transformed) until +// the results of the previous transformed chunk were consumed. + + + +module.exports = Transform; + +var Duplex = __webpack_require__(34); + +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ + +util.inherits(Transform, Duplex); + +function TransformState(stream) { + this.afterTransform = function (er, data) { + return afterTransform(stream, er, data); + }; + + this.needTransform = false; + this.transforming = false; + this.writecb = null; + this.writechunk = null; + this.writeencoding = null; +} + +function afterTransform(stream, er, data) { + var ts = stream._transformState; + ts.transforming = false; + + var cb = ts.writecb; + + if (!cb) { + return stream.emit('error', new Error('write callback called multiple times')); + } + + ts.writechunk = null; + ts.writecb = null; + + if (data !== null && data !== undefined) stream.push(data); + + cb(er); + + var rs = stream._readableState; + rs.reading = false; + if (rs.needReadable || rs.length < rs.highWaterMark) { + stream._read(rs.highWaterMark); + } +} + +function Transform(options) { + if (!(this instanceof Transform)) return new Transform(options); + + Duplex.call(this, options); + + this._transformState = new TransformState(this); + + var stream = this; + + // start out asking for a readable event once data is transformed. + this._readableState.needReadable = true; + + // we have implemented the _read method, and done the other things + // that Readable wants before the first _read call, so unset the + // sync guard flag. + this._readableState.sync = false; + + if (options) { + if (typeof options.transform === 'function') this._transform = options.transform; + + if (typeof options.flush === 'function') this._flush = options.flush; + } + + // When the writable side finishes, then flush out anything remaining. + this.once('prefinish', function () { + if (typeof this._flush === 'function') this._flush(function (er, data) { + done(stream, er, data); + });else done(stream); + }); +} + +Transform.prototype.push = function (chunk, encoding) { + this._transformState.needTransform = false; + return Duplex.prototype.push.call(this, chunk, encoding); +}; + +// This is the part where you do stuff! +// override this function in implementation classes. +// 'chunk' is an input chunk. +// +// Call `push(newChunk)` to pass along transformed output +// to the readable side. You may call 'push' zero or more times. +// +// Call `cb(err)` when you are done with this chunk. If you pass +// an error, then that'll put the hurt on the whole operation. If you +// never call cb(), then you'll never get another chunk. +Transform.prototype._transform = function (chunk, encoding, cb) { + throw new Error('_transform() is not implemented'); +}; + +Transform.prototype._write = function (chunk, encoding, cb) { + var ts = this._transformState; + ts.writecb = cb; + ts.writechunk = chunk; + ts.writeencoding = encoding; + if (!ts.transforming) { + var rs = this._readableState; + if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark) this._read(rs.highWaterMark); + } +}; + +// Doesn't matter what the args are here. +// _transform does all the work. +// That we got here means that the readable side wants more data. +Transform.prototype._read = function (n) { + var ts = this._transformState; + + if (ts.writechunk !== null && ts.writecb && !ts.transforming) { + ts.transforming = true; + this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); + } else { + // mark that we need a transform, so that any data that comes in + // will get processed, now that we've asked for it. + ts.needTransform = true; + } +}; + +Transform.prototype._destroy = function (err, cb) { + var _this = this; + + Duplex.prototype._destroy.call(this, err, function (err2) { + cb(err2); + _this.emit('close'); + }); +}; + +function done(stream, er, data) { + if (er) return stream.emit('error', er); + + if (data !== null && data !== undefined) stream.push(data); + + // if there's nothing in the write buffer, then that means + // that nothing more will ever be provided + var ws = stream._writableState; + var ts = stream._transformState; + + if (ws.length) throw new Error('Calling transform done when ws.length != 0'); + + if (ts.transforming) throw new Error('Calling transform done when still transforming'); + + return stream.push(null); +} + +/***/ }), +/* 166 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/** + * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined + * in FIPS 180-2 + * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * + */ + +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) + +var K = [ + 0x428A2F98, 0x71374491, 0xB5C0FBCF, 0xE9B5DBA5, + 0x3956C25B, 0x59F111F1, 0x923F82A4, 0xAB1C5ED5, + 0xD807AA98, 0x12835B01, 0x243185BE, 0x550C7DC3, + 0x72BE5D74, 0x80DEB1FE, 0x9BDC06A7, 0xC19BF174, + 0xE49B69C1, 0xEFBE4786, 0x0FC19DC6, 0x240CA1CC, + 0x2DE92C6F, 0x4A7484AA, 0x5CB0A9DC, 0x76F988DA, + 0x983E5152, 0xA831C66D, 0xB00327C8, 0xBF597FC7, + 0xC6E00BF3, 0xD5A79147, 0x06CA6351, 0x14292967, + 0x27B70A85, 0x2E1B2138, 0x4D2C6DFC, 0x53380D13, + 0x650A7354, 0x766A0ABB, 0x81C2C92E, 0x92722C85, + 0xA2BFE8A1, 0xA81A664B, 0xC24B8B70, 0xC76C51A3, + 0xD192E819, 0xD6990624, 0xF40E3585, 0x106AA070, + 0x19A4C116, 0x1E376C08, 0x2748774C, 0x34B0BCB5, + 0x391C0CB3, 0x4ED8AA4A, 0x5B9CCA4F, 0x682E6FF3, + 0x748F82EE, 0x78A5636F, 0x84C87814, 0x8CC70208, + 0x90BEFFFA, 0xA4506CEB, 0xBEF9A3F7, 0xC67178F2 +] + +var W = new Array(64) + +function Sha256 () { + this.init() + + this._w = W // new Array(64) + + Hash.call(this, 64, 56) +} + +inherits(Sha256, Hash) + +Sha256.prototype.init = function () { + this._a = 0x6a09e667 + this._b = 0xbb67ae85 + this._c = 0x3c6ef372 + this._d = 0xa54ff53a + this._e = 0x510e527f + this._f = 0x9b05688c + this._g = 0x1f83d9ab + this._h = 0x5be0cd19 + + return this +} + +function ch (x, y, z) { + return z ^ (x & (y ^ z)) +} + +function maj (x, y, z) { + return (x & y) | (z & (x | y)) +} + +function sigma0 (x) { + return (x >>> 2 | x << 30) ^ (x >>> 13 | x << 19) ^ (x >>> 22 | x << 10) +} + +function sigma1 (x) { + return (x >>> 6 | x << 26) ^ (x >>> 11 | x << 21) ^ (x >>> 25 | x << 7) +} + +function gamma0 (x) { + return (x >>> 7 | x << 25) ^ (x >>> 18 | x << 14) ^ (x >>> 3) +} + +function gamma1 (x) { + return (x >>> 17 | x << 15) ^ (x >>> 19 | x << 13) ^ (x >>> 10) +} + +Sha256.prototype._update = function (M) { + var W = this._w + + var a = this._a | 0 + var b = this._b | 0 + var c = this._c | 0 + var d = this._d | 0 + var e = this._e | 0 + var f = this._f | 0 + var g = this._g | 0 + var h = this._h | 0 + + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4) + for (; i < 64; ++i) W[i] = (gamma1(W[i - 2]) + W[i - 7] + gamma0(W[i - 15]) + W[i - 16]) | 0 + + for (var j = 0; j < 64; ++j) { + var T1 = (h + sigma1(e) + ch(e, f, g) + K[j] + W[j]) | 0 + var T2 = (sigma0(a) + maj(a, b, c)) | 0 + + h = g + g = f + f = e + e = (d + T1) | 0 + d = c + c = b + b = a + a = (T1 + T2) | 0 + } + + this._a = (a + this._a) | 0 + this._b = (b + this._b) | 0 + this._c = (c + this._c) | 0 + this._d = (d + this._d) | 0 + this._e = (e + this._e) | 0 + this._f = (f + this._f) | 0 + this._g = (g + this._g) | 0 + this._h = (h + this._h) | 0 +} + +Sha256.prototype._hash = function () { + var H = new Buffer(32) + + H.writeInt32BE(this._a, 0) + H.writeInt32BE(this._b, 4) + H.writeInt32BE(this._c, 8) + H.writeInt32BE(this._d, 12) + H.writeInt32BE(this._e, 16) + H.writeInt32BE(this._f, 20) + H.writeInt32BE(this._g, 24) + H.writeInt32BE(this._h, 28) + + return H +} + +module.exports = Sha256 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 167 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) + +var K = [ + 0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd, + 0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc, + 0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019, + 0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118, + 0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe, + 0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2, + 0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1, + 0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694, + 0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3, + 0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65, + 0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483, + 0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5, + 0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210, + 0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4, + 0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725, + 0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70, + 0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926, + 0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df, + 0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8, + 0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b, + 0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001, + 0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30, + 0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910, + 0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8, + 0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53, + 0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8, + 0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb, + 0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3, + 0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60, + 0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec, + 0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9, + 0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b, + 0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207, + 0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178, + 0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6, + 0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b, + 0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493, + 0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c, + 0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a, + 0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817 +] + +var W = new Array(160) + +function Sha512 () { + this.init() + this._w = W + + Hash.call(this, 128, 112) +} + +inherits(Sha512, Hash) + +Sha512.prototype.init = function () { + this._ah = 0x6a09e667 + this._bh = 0xbb67ae85 + this._ch = 0x3c6ef372 + this._dh = 0xa54ff53a + this._eh = 0x510e527f + this._fh = 0x9b05688c + this._gh = 0x1f83d9ab + this._hh = 0x5be0cd19 + + this._al = 0xf3bcc908 + this._bl = 0x84caa73b + this._cl = 0xfe94f82b + this._dl = 0x5f1d36f1 + this._el = 0xade682d1 + this._fl = 0x2b3e6c1f + this._gl = 0xfb41bd6b + this._hl = 0x137e2179 + + return this +} + +function Ch (x, y, z) { + return z ^ (x & (y ^ z)) +} + +function maj (x, y, z) { + return (x & y) | (z & (x | y)) +} + +function sigma0 (x, xl) { + return (x >>> 28 | xl << 4) ^ (xl >>> 2 | x << 30) ^ (xl >>> 7 | x << 25) +} + +function sigma1 (x, xl) { + return (x >>> 14 | xl << 18) ^ (x >>> 18 | xl << 14) ^ (xl >>> 9 | x << 23) +} + +function Gamma0 (x, xl) { + return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7) +} + +function Gamma0l (x, xl) { + return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7 | xl << 25) +} + +function Gamma1 (x, xl) { + return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6) +} + +function Gamma1l (x, xl) { + return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6 | xl << 26) +} + +function getCarry (a, b) { + return (a >>> 0) < (b >>> 0) ? 1 : 0 +} + +Sha512.prototype._update = function (M) { + var W = this._w + + var ah = this._ah | 0 + var bh = this._bh | 0 + var ch = this._ch | 0 + var dh = this._dh | 0 + var eh = this._eh | 0 + var fh = this._fh | 0 + var gh = this._gh | 0 + var hh = this._hh | 0 + + var al = this._al | 0 + var bl = this._bl | 0 + var cl = this._cl | 0 + var dl = this._dl | 0 + var el = this._el | 0 + var fl = this._fl | 0 + var gl = this._gl | 0 + var hl = this._hl | 0 + + for (var i = 0; i < 32; i += 2) { + W[i] = M.readInt32BE(i * 4) + W[i + 1] = M.readInt32BE(i * 4 + 4) + } + for (; i < 160; i += 2) { + var xh = W[i - 15 * 2] + var xl = W[i - 15 * 2 + 1] + var gamma0 = Gamma0(xh, xl) + var gamma0l = Gamma0l(xl, xh) + + xh = W[i - 2 * 2] + xl = W[i - 2 * 2 + 1] + var gamma1 = Gamma1(xh, xl) + var gamma1l = Gamma1l(xl, xh) + + // W[i] = gamma0 + W[i - 7] + gamma1 + W[i - 16] + var Wi7h = W[i - 7 * 2] + var Wi7l = W[i - 7 * 2 + 1] + + var Wi16h = W[i - 16 * 2] + var Wi16l = W[i - 16 * 2 + 1] + + var Wil = (gamma0l + Wi7l) | 0 + var Wih = (gamma0 + Wi7h + getCarry(Wil, gamma0l)) | 0 + Wil = (Wil + gamma1l) | 0 + Wih = (Wih + gamma1 + getCarry(Wil, gamma1l)) | 0 + Wil = (Wil + Wi16l) | 0 + Wih = (Wih + Wi16h + getCarry(Wil, Wi16l)) | 0 + + W[i] = Wih + W[i + 1] = Wil + } + + for (var j = 0; j < 160; j += 2) { + Wih = W[j] + Wil = W[j + 1] + + var majh = maj(ah, bh, ch) + var majl = maj(al, bl, cl) + + var sigma0h = sigma0(ah, al) + var sigma0l = sigma0(al, ah) + var sigma1h = sigma1(eh, el) + var sigma1l = sigma1(el, eh) + + // t1 = h + sigma1 + ch + K[j] + W[j] + var Kih = K[j] + var Kil = K[j + 1] + + var chh = Ch(eh, fh, gh) + var chl = Ch(el, fl, gl) + + var t1l = (hl + sigma1l) | 0 + var t1h = (hh + sigma1h + getCarry(t1l, hl)) | 0 + t1l = (t1l + chl) | 0 + t1h = (t1h + chh + getCarry(t1l, chl)) | 0 + t1l = (t1l + Kil) | 0 + t1h = (t1h + Kih + getCarry(t1l, Kil)) | 0 + t1l = (t1l + Wil) | 0 + t1h = (t1h + Wih + getCarry(t1l, Wil)) | 0 + + // t2 = sigma0 + maj + var t2l = (sigma0l + majl) | 0 + var t2h = (sigma0h + majh + getCarry(t2l, sigma0l)) | 0 + + hh = gh + hl = gl + gh = fh + gl = fl + fh = eh + fl = el + el = (dl + t1l) | 0 + eh = (dh + t1h + getCarry(el, dl)) | 0 + dh = ch + dl = cl + ch = bh + cl = bl + bh = ah + bl = al + al = (t1l + t2l) | 0 + ah = (t1h + t2h + getCarry(al, t1l)) | 0 + } + + this._al = (this._al + al) | 0 + this._bl = (this._bl + bl) | 0 + this._cl = (this._cl + cl) | 0 + this._dl = (this._dl + dl) | 0 + this._el = (this._el + el) | 0 + this._fl = (this._fl + fl) | 0 + this._gl = (this._gl + gl) | 0 + this._hl = (this._hl + hl) | 0 + + this._ah = (this._ah + ah + getCarry(this._al, al)) | 0 + this._bh = (this._bh + bh + getCarry(this._bl, bl)) | 0 + this._ch = (this._ch + ch + getCarry(this._cl, cl)) | 0 + this._dh = (this._dh + dh + getCarry(this._dl, dl)) | 0 + this._eh = (this._eh + eh + getCarry(this._el, el)) | 0 + this._fh = (this._fh + fh + getCarry(this._fl, fl)) | 0 + this._gh = (this._gh + gh + getCarry(this._gl, gl)) | 0 + this._hh = (this._hh + hh + getCarry(this._hl, hl)) | 0 +} + +Sha512.prototype._hash = function () { + var H = new Buffer(64) + + function writeInt64BE (h, l, offset) { + H.writeInt32BE(h, offset) + H.writeInt32BE(l, offset + 4) + } + + writeInt64BE(this._ah, this._al, 0) + writeInt64BE(this._bh, this._bl, 8) + writeInt64BE(this._ch, this._cl, 16) + writeInt64BE(this._dh, this._dl, 24) + writeInt64BE(this._eh, this._el, 32) + writeInt64BE(this._fh, this._fl, 40) + writeInt64BE(this._gh, this._gl, 48) + writeInt64BE(this._hh, this._hl, 56) + + return H +} + +module.exports = Sha512 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 168 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +module.exports = __webpack_require__(380)(__webpack_require__(383)) + + +/***/ }), +/* 169 */ +/***/ (function(module, exports) { + +module.exports = { + "COMPRESSED_TYPE_INVALID": "compressed should be a boolean", + "EC_PRIVATE_KEY_TYPE_INVALID": "private key should be a Buffer", + "EC_PRIVATE_KEY_LENGTH_INVALID": "private key length is invalid", + "EC_PRIVATE_KEY_TWEAK_ADD_FAIL": "tweak out of range or resulting private key is invalid", + "EC_PRIVATE_KEY_TWEAK_MUL_FAIL": "tweak out of range", + "EC_PRIVATE_KEY_EXPORT_DER_FAIL": "couldn't export to DER format", + "EC_PRIVATE_KEY_IMPORT_DER_FAIL": "couldn't import from DER format", + "EC_PUBLIC_KEYS_TYPE_INVALID": "public keys should be an Array", + "EC_PUBLIC_KEYS_LENGTH_INVALID": "public keys Array should have at least 1 element", + "EC_PUBLIC_KEY_TYPE_INVALID": "public key should be a Buffer", + "EC_PUBLIC_KEY_LENGTH_INVALID": "public key length is invalid", + "EC_PUBLIC_KEY_PARSE_FAIL": "the public key could not be parsed or is invalid", + "EC_PUBLIC_KEY_CREATE_FAIL": "private was invalid, try again", + "EC_PUBLIC_KEY_TWEAK_ADD_FAIL": "tweak out of range or resulting public key is invalid", + "EC_PUBLIC_KEY_TWEAK_MUL_FAIL": "tweak out of range", + "EC_PUBLIC_KEY_COMBINE_FAIL": "the sum of the public keys is not valid", + "ECDH_FAIL": "scalar was invalid (zero or overflow)", + "ECDSA_SIGNATURE_TYPE_INVALID": "signature should be a Buffer", + "ECDSA_SIGNATURE_LENGTH_INVALID": "signature length is invalid", + "ECDSA_SIGNATURE_PARSE_FAIL": "couldn't parse signature", + "ECDSA_SIGNATURE_PARSE_DER_FAIL": "couldn't parse DER signature", + "ECDSA_SIGNATURE_SERIALIZE_DER_FAIL": "couldn't serialize signature to DER format", + "ECDSA_SIGN_FAIL": "nonce generation function failed or private key is invalid", + "ECDSA_RECOVER_FAIL": "couldn't recover public key from signature", + "MSG32_TYPE_INVALID": "message should be a Buffer", + "MSG32_LENGTH_INVALID": "message length is invalid", + "OPTIONS_TYPE_INVALID": "options should be an Object", + "OPTIONS_DATA_TYPE_INVALID": "options.data should be a Buffer", + "OPTIONS_DATA_LENGTH_INVALID": "options.data length is invalid", + "OPTIONS_NONCEFN_TYPE_INVALID": "options.noncefn should be a Function", + "RECOVERY_ID_TYPE_INVALID": "recovery should be a Number", + "RECOVERY_ID_VALUE_INVALID": "recovery should have value between -1 and 4", + "TWEAK_TYPE_INVALID": "tweak should be a Buffer", + "TWEAK_LENGTH_INVALID": "tweak length is invalid" +}; + +/***/ }), +/* 170 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = exports; + +function toArray(msg, enc) { + if (Array.isArray(msg)) + return msg.slice(); + if (!msg) + return []; + var res = []; + if (typeof msg !== 'string') { + for (var i = 0; i < msg.length; i++) + res[i] = msg[i] | 0; + return res; + } + if (enc === 'hex') { + msg = msg.replace(/[^a-z0-9]+/ig, ''); + if (msg.length % 2 !== 0) + msg = '0' + msg; + for (var i = 0; i < msg.length; i += 2) + res.push(parseInt(msg[i] + msg[i + 1], 16)); + } else { + for (var i = 0; i < msg.length; i++) { + var c = msg.charCodeAt(i); + var hi = c >> 8; + var lo = c & 0xff; + if (hi) + res.push(hi, lo); + else + res.push(lo); + } + } + return res; +} +utils.toArray = toArray; + +function zero2(word) { + if (word.length === 1) + return '0' + word; + else + return word; +} +utils.zero2 = zero2; + +function toHex(msg) { + var res = ''; + for (var i = 0; i < msg.length; i++) + res += zero2(msg[i].toString(16)); + return res; +} +utils.toHex = toHex; + +utils.encode = function encode(arr, enc) { + if (enc === 'hex') + return toHex(arr); + else + return arr; +}; + + +/***/ }), +/* 171 */ +/***/ (function(module, exports, __webpack_require__) { + +var r; + +module.exports = function rand(len) { + if (!r) + r = new Rand(null); + + return r.generate(len); +}; + +function Rand(rand) { + this.rand = rand; +} +module.exports.Rand = Rand; + +Rand.prototype.generate = function generate(len) { + return this._rand(len); +}; + +// Emulate crypto API using randy +Rand.prototype._rand = function _rand(n) { + if (this.rand.getBytes) + return this.rand.getBytes(n); + + var res = new Uint8Array(n); + for (var i = 0; i < res.length; i++) + res[i] = this.rand.getByte(); + return res; +}; + +if (typeof self === 'object') { + if (self.crypto && self.crypto.getRandomValues) { + // Modern browsers + Rand.prototype._rand = function _rand(n) { + var arr = new Uint8Array(n); + self.crypto.getRandomValues(arr); + return arr; + }; + } else if (self.msCrypto && self.msCrypto.getRandomValues) { + // IE + Rand.prototype._rand = function _rand(n) { + var arr = new Uint8Array(n); + self.msCrypto.getRandomValues(arr); + return arr; + }; + + // Safari's WebWorkers do not have `crypto` + } else if (typeof window === 'object') { + // Old junk + Rand.prototype._rand = function() { + throw new Error('Not implemented yet'); + }; + } +} else { + // Node.js or Web worker with no crypto support + try { + var crypto = __webpack_require__(387); + if (typeof crypto.randomBytes !== 'function') + throw new Error('Not supported'); + + Rand.prototype._rand = function _rand(n) { + return crypto.randomBytes(n); + }; + } catch (e) { + } +} + + +/***/ }), +/* 172 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var rotr32 = utils.rotr32; + +function ft_1(s, x, y, z) { + if (s === 0) + return ch32(x, y, z); + if (s === 1 || s === 3) + return p32(x, y, z); + if (s === 2) + return maj32(x, y, z); +} +exports.ft_1 = ft_1; + +function ch32(x, y, z) { + return (x & y) ^ ((~x) & z); +} +exports.ch32 = ch32; + +function maj32(x, y, z) { + return (x & y) ^ (x & z) ^ (y & z); +} +exports.maj32 = maj32; + +function p32(x, y, z) { + return x ^ y ^ z; +} +exports.p32 = p32; + +function s0_256(x) { + return rotr32(x, 2) ^ rotr32(x, 13) ^ rotr32(x, 22); +} +exports.s0_256 = s0_256; + +function s1_256(x) { + return rotr32(x, 6) ^ rotr32(x, 11) ^ rotr32(x, 25); +} +exports.s1_256 = s1_256; + +function g0_256(x) { + return rotr32(x, 7) ^ rotr32(x, 18) ^ (x >>> 3); +} +exports.g0_256 = g0_256; + +function g1_256(x) { + return rotr32(x, 17) ^ rotr32(x, 19) ^ (x >>> 10); +} +exports.g1_256 = g1_256; + + +/***/ }), +/* 173 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var shaCommon = __webpack_require__(172); +var assert = __webpack_require__(21); + +var sum32 = utils.sum32; +var sum32_4 = utils.sum32_4; +var sum32_5 = utils.sum32_5; +var ch32 = shaCommon.ch32; +var maj32 = shaCommon.maj32; +var s0_256 = shaCommon.s0_256; +var s1_256 = shaCommon.s1_256; +var g0_256 = shaCommon.g0_256; +var g1_256 = shaCommon.g1_256; + +var BlockHash = common.BlockHash; + +var sha256_K = [ + 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, + 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5, + 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, + 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174, + 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, + 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da, + 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, + 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967, + 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, + 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85, + 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, + 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070, + 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, + 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3, + 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, + 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2 +]; + +function SHA256() { + if (!(this instanceof SHA256)) + return new SHA256(); + + BlockHash.call(this); + this.h = [ + 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, + 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19 + ]; + this.k = sha256_K; + this.W = new Array(64); +} +utils.inherits(SHA256, BlockHash); +module.exports = SHA256; + +SHA256.blockSize = 512; +SHA256.outSize = 256; +SHA256.hmacStrength = 192; +SHA256.padLength = 64; + +SHA256.prototype._update = function _update(msg, start) { + var W = this.W; + + for (var i = 0; i < 16; i++) + W[i] = msg[start + i]; + for (; i < W.length; i++) + W[i] = sum32_4(g1_256(W[i - 2]), W[i - 7], g0_256(W[i - 15]), W[i - 16]); + + var a = this.h[0]; + var b = this.h[1]; + var c = this.h[2]; + var d = this.h[3]; + var e = this.h[4]; + var f = this.h[5]; + var g = this.h[6]; + var h = this.h[7]; + + assert(this.k.length === W.length); + for (i = 0; i < W.length; i++) { + var T1 = sum32_5(h, s1_256(e), ch32(e, f, g), this.k[i], W[i]); + var T2 = sum32(s0_256(a), maj32(a, b, c)); + h = g; + g = f; + f = e; + e = sum32(d, T1); + d = c; + c = b; + b = a; + a = sum32(T1, T2); + } + + this.h[0] = sum32(this.h[0], a); + this.h[1] = sum32(this.h[1], b); + this.h[2] = sum32(this.h[2], c); + this.h[3] = sum32(this.h[3], d); + this.h[4] = sum32(this.h[4], e); + this.h[5] = sum32(this.h[5], f); + this.h[6] = sum32(this.h[6], g); + this.h[7] = sum32(this.h[7], h); +}; + +SHA256.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'big'); + else + return utils.split32(this.h, 'big'); +}; + + +/***/ }), +/* 174 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var assert = __webpack_require__(21); + +var rotr64_hi = utils.rotr64_hi; +var rotr64_lo = utils.rotr64_lo; +var shr64_hi = utils.shr64_hi; +var shr64_lo = utils.shr64_lo; +var sum64 = utils.sum64; +var sum64_hi = utils.sum64_hi; +var sum64_lo = utils.sum64_lo; +var sum64_4_hi = utils.sum64_4_hi; +var sum64_4_lo = utils.sum64_4_lo; +var sum64_5_hi = utils.sum64_5_hi; +var sum64_5_lo = utils.sum64_5_lo; + +var BlockHash = common.BlockHash; + +var sha512_K = [ + 0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd, + 0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc, + 0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019, + 0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118, + 0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe, + 0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2, + 0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1, + 0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694, + 0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3, + 0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65, + 0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483, + 0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5, + 0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210, + 0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4, + 0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725, + 0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70, + 0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926, + 0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df, + 0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8, + 0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b, + 0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001, + 0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30, + 0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910, + 0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8, + 0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53, + 0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8, + 0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb, + 0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3, + 0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60, + 0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec, + 0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9, + 0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b, + 0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207, + 0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178, + 0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6, + 0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b, + 0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493, + 0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c, + 0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a, + 0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817 +]; + +function SHA512() { + if (!(this instanceof SHA512)) + return new SHA512(); + + BlockHash.call(this); + this.h = [ + 0x6a09e667, 0xf3bcc908, + 0xbb67ae85, 0x84caa73b, + 0x3c6ef372, 0xfe94f82b, + 0xa54ff53a, 0x5f1d36f1, + 0x510e527f, 0xade682d1, + 0x9b05688c, 0x2b3e6c1f, + 0x1f83d9ab, 0xfb41bd6b, + 0x5be0cd19, 0x137e2179 ]; + this.k = sha512_K; + this.W = new Array(160); +} +utils.inherits(SHA512, BlockHash); +module.exports = SHA512; + +SHA512.blockSize = 1024; +SHA512.outSize = 512; +SHA512.hmacStrength = 192; +SHA512.padLength = 128; + +SHA512.prototype._prepareBlock = function _prepareBlock(msg, start) { + var W = this.W; + + // 32 x 32bit words + for (var i = 0; i < 32; i++) + W[i] = msg[start + i]; + for (; i < W.length; i += 2) { + var c0_hi = g1_512_hi(W[i - 4], W[i - 3]); // i - 2 + var c0_lo = g1_512_lo(W[i - 4], W[i - 3]); + var c1_hi = W[i - 14]; // i - 7 + var c1_lo = W[i - 13]; + var c2_hi = g0_512_hi(W[i - 30], W[i - 29]); // i - 15 + var c2_lo = g0_512_lo(W[i - 30], W[i - 29]); + var c3_hi = W[i - 32]; // i - 16 + var c3_lo = W[i - 31]; + + W[i] = sum64_4_hi( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo); + W[i + 1] = sum64_4_lo( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo); + } +}; + +SHA512.prototype._update = function _update(msg, start) { + this._prepareBlock(msg, start); + + var W = this.W; + + var ah = this.h[0]; + var al = this.h[1]; + var bh = this.h[2]; + var bl = this.h[3]; + var ch = this.h[4]; + var cl = this.h[5]; + var dh = this.h[6]; + var dl = this.h[7]; + var eh = this.h[8]; + var el = this.h[9]; + var fh = this.h[10]; + var fl = this.h[11]; + var gh = this.h[12]; + var gl = this.h[13]; + var hh = this.h[14]; + var hl = this.h[15]; + + assert(this.k.length === W.length); + for (var i = 0; i < W.length; i += 2) { + var c0_hi = hh; + var c0_lo = hl; + var c1_hi = s1_512_hi(eh, el); + var c1_lo = s1_512_lo(eh, el); + var c2_hi = ch64_hi(eh, el, fh, fl, gh, gl); + var c2_lo = ch64_lo(eh, el, fh, fl, gh, gl); + var c3_hi = this.k[i]; + var c3_lo = this.k[i + 1]; + var c4_hi = W[i]; + var c4_lo = W[i + 1]; + + var T1_hi = sum64_5_hi( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo, + c4_hi, c4_lo); + var T1_lo = sum64_5_lo( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo, + c4_hi, c4_lo); + + c0_hi = s0_512_hi(ah, al); + c0_lo = s0_512_lo(ah, al); + c1_hi = maj64_hi(ah, al, bh, bl, ch, cl); + c1_lo = maj64_lo(ah, al, bh, bl, ch, cl); + + var T2_hi = sum64_hi(c0_hi, c0_lo, c1_hi, c1_lo); + var T2_lo = sum64_lo(c0_hi, c0_lo, c1_hi, c1_lo); + + hh = gh; + hl = gl; + + gh = fh; + gl = fl; + + fh = eh; + fl = el; + + eh = sum64_hi(dh, dl, T1_hi, T1_lo); + el = sum64_lo(dl, dl, T1_hi, T1_lo); + + dh = ch; + dl = cl; + + ch = bh; + cl = bl; + + bh = ah; + bl = al; + + ah = sum64_hi(T1_hi, T1_lo, T2_hi, T2_lo); + al = sum64_lo(T1_hi, T1_lo, T2_hi, T2_lo); + } + + sum64(this.h, 0, ah, al); + sum64(this.h, 2, bh, bl); + sum64(this.h, 4, ch, cl); + sum64(this.h, 6, dh, dl); + sum64(this.h, 8, eh, el); + sum64(this.h, 10, fh, fl); + sum64(this.h, 12, gh, gl); + sum64(this.h, 14, hh, hl); +}; + +SHA512.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'big'); + else + return utils.split32(this.h, 'big'); +}; + +function ch64_hi(xh, xl, yh, yl, zh) { + var r = (xh & yh) ^ ((~xh) & zh); + if (r < 0) + r += 0x100000000; + return r; +} + +function ch64_lo(xh, xl, yh, yl, zh, zl) { + var r = (xl & yl) ^ ((~xl) & zl); + if (r < 0) + r += 0x100000000; + return r; +} + +function maj64_hi(xh, xl, yh, yl, zh) { + var r = (xh & yh) ^ (xh & zh) ^ (yh & zh); + if (r < 0) + r += 0x100000000; + return r; +} + +function maj64_lo(xh, xl, yh, yl, zh, zl) { + var r = (xl & yl) ^ (xl & zl) ^ (yl & zl); + if (r < 0) + r += 0x100000000; + return r; +} + +function s0_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 28); + var c1_hi = rotr64_hi(xl, xh, 2); // 34 + var c2_hi = rotr64_hi(xl, xh, 7); // 39 + + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} + +function s0_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 28); + var c1_lo = rotr64_lo(xl, xh, 2); // 34 + var c2_lo = rotr64_lo(xl, xh, 7); // 39 + + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} + +function s1_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 14); + var c1_hi = rotr64_hi(xh, xl, 18); + var c2_hi = rotr64_hi(xl, xh, 9); // 41 + + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} + +function s1_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 14); + var c1_lo = rotr64_lo(xh, xl, 18); + var c2_lo = rotr64_lo(xl, xh, 9); // 41 + + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} + +function g0_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 1); + var c1_hi = rotr64_hi(xh, xl, 8); + var c2_hi = shr64_hi(xh, xl, 7); + + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} + +function g0_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 1); + var c1_lo = rotr64_lo(xh, xl, 8); + var c2_lo = shr64_lo(xh, xl, 7); + + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} + +function g1_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 19); + var c1_hi = rotr64_hi(xl, xh, 29); // 61 + var c2_hi = shr64_hi(xh, xl, 6); + + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} + +function g1_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 19); + var c1_lo = rotr64_lo(xl, xh, 29); // 61 + var c2_lo = shr64_lo(xh, xl, 6); + + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} + + +/***/ }), +/* 175 */ +/***/ (function(module, exports, __webpack_require__) { + +// (public) Constructor +function BigInteger(a, b, c) { + if (!(this instanceof BigInteger)) + return new BigInteger(a, b, c) + + if (a != null) { + if ("number" == typeof a) this.fromNumber(a, b, c) + else if (b == null && "string" != typeof a) this.fromString(a, 256) + else this.fromString(a, b) + } +} + +var proto = BigInteger.prototype + +// duck-typed isBigInteger +proto.__bigi = __webpack_require__(407).version +BigInteger.isBigInteger = function (obj, check_ver) { + return obj && obj.__bigi && (!check_ver || obj.__bigi === proto.__bigi) +} + +// Bits per digit +var dbits + +// am: Compute w_j += (x*this_i), propagate carries, +// c is initial carry, returns final carry. +// c < 3*dvalue, x < 2*dvalue, this_i < dvalue +// We need to select the fastest one that works in this environment. + +// am1: use a single mult and divide to get the high bits, +// max digit bits should be 26 because +// max internal value = 2*dvalue^2-2*dvalue (< 2^53) +function am1(i, x, w, j, c, n) { + while (--n >= 0) { + var v = x * this[i++] + w[j] + c + c = Math.floor(v / 0x4000000) + w[j++] = v & 0x3ffffff + } + return c +} +// am2 avoids a big mult-and-extract completely. +// Max digit bits should be <= 30 because we do bitwise ops +// on values up to 2*hdvalue^2-hdvalue-1 (< 2^31) +function am2(i, x, w, j, c, n) { + var xl = x & 0x7fff, + xh = x >> 15 + while (--n >= 0) { + var l = this[i] & 0x7fff + var h = this[i++] >> 15 + var m = xh * l + h * xl + l = xl * l + ((m & 0x7fff) << 15) + w[j] + (c & 0x3fffffff) + c = (l >>> 30) + (m >>> 15) + xh * h + (c >>> 30) + w[j++] = l & 0x3fffffff + } + return c +} +// Alternately, set max digit bits to 28 since some +// browsers slow down when dealing with 32-bit numbers. +function am3(i, x, w, j, c, n) { + var xl = x & 0x3fff, + xh = x >> 14 + while (--n >= 0) { + var l = this[i] & 0x3fff + var h = this[i++] >> 14 + var m = xh * l + h * xl + l = xl * l + ((m & 0x3fff) << 14) + w[j] + c + c = (l >> 28) + (m >> 14) + xh * h + w[j++] = l & 0xfffffff + } + return c +} + +// wtf? +BigInteger.prototype.am = am1 +dbits = 26 + +BigInteger.prototype.DB = dbits +BigInteger.prototype.DM = ((1 << dbits) - 1) +var DV = BigInteger.prototype.DV = (1 << dbits) + +var BI_FP = 52 +BigInteger.prototype.FV = Math.pow(2, BI_FP) +BigInteger.prototype.F1 = BI_FP - dbits +BigInteger.prototype.F2 = 2 * dbits - BI_FP + +// Digit conversions +var BI_RM = "0123456789abcdefghijklmnopqrstuvwxyz" +var BI_RC = new Array() +var rr, vv +rr = "0".charCodeAt(0) +for (vv = 0; vv <= 9; ++vv) BI_RC[rr++] = vv +rr = "a".charCodeAt(0) +for (vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv +rr = "A".charCodeAt(0) +for (vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv + +function int2char(n) { + return BI_RM.charAt(n) +} + +function intAt(s, i) { + var c = BI_RC[s.charCodeAt(i)] + return (c == null) ? -1 : c +} + +// (protected) copy this to r +function bnpCopyTo(r) { + for (var i = this.t - 1; i >= 0; --i) r[i] = this[i] + r.t = this.t + r.s = this.s +} + +// (protected) set from integer value x, -DV <= x < DV +function bnpFromInt(x) { + this.t = 1 + this.s = (x < 0) ? -1 : 0 + if (x > 0) this[0] = x + else if (x < -1) this[0] = x + DV + else this.t = 0 +} + +// return bigint initialized to value +function nbv(i) { + var r = new BigInteger() + r.fromInt(i) + return r +} + +// (protected) set from string and radix +function bnpFromString(s, b) { + var self = this + + var k + if (b == 16) k = 4 + else if (b == 8) k = 3 + else if (b == 256) k = 8; // byte array + else if (b == 2) k = 1 + else if (b == 32) k = 5 + else if (b == 4) k = 2 + else { + self.fromRadix(s, b) + return + } + self.t = 0 + self.s = 0 + var i = s.length, + mi = false, + sh = 0 + while (--i >= 0) { + var x = (k == 8) ? s[i] & 0xff : intAt(s, i) + if (x < 0) { + if (s.charAt(i) == "-") mi = true + continue + } + mi = false + if (sh == 0) + self[self.t++] = x + else if (sh + k > self.DB) { + self[self.t - 1] |= (x & ((1 << (self.DB - sh)) - 1)) << sh + self[self.t++] = (x >> (self.DB - sh)) + } else + self[self.t - 1] |= x << sh + sh += k + if (sh >= self.DB) sh -= self.DB + } + if (k == 8 && (s[0] & 0x80) != 0) { + self.s = -1 + if (sh > 0) self[self.t - 1] |= ((1 << (self.DB - sh)) - 1) << sh + } + self.clamp() + if (mi) BigInteger.ZERO.subTo(self, self) +} + +// (protected) clamp off excess high words +function bnpClamp() { + var c = this.s & this.DM + while (this.t > 0 && this[this.t - 1] == c)--this.t +} + +// (public) return string representation in given radix +function bnToString(b) { + var self = this + if (self.s < 0) return "-" + self.negate() + .toString(b) + var k + if (b == 16) k = 4 + else if (b == 8) k = 3 + else if (b == 2) k = 1 + else if (b == 32) k = 5 + else if (b == 4) k = 2 + else return self.toRadix(b) + var km = (1 << k) - 1, + d, m = false, + r = "", + i = self.t + var p = self.DB - (i * self.DB) % k + if (i-- > 0) { + if (p < self.DB && (d = self[i] >> p) > 0) { + m = true + r = int2char(d) + } + while (i >= 0) { + if (p < k) { + d = (self[i] & ((1 << p) - 1)) << (k - p) + d |= self[--i] >> (p += self.DB - k) + } else { + d = (self[i] >> (p -= k)) & km + if (p <= 0) { + p += self.DB + --i + } + } + if (d > 0) m = true + if (m) r += int2char(d) + } + } + return m ? r : "0" +} + +// (public) -this +function bnNegate() { + var r = new BigInteger() + BigInteger.ZERO.subTo(this, r) + return r +} + +// (public) |this| +function bnAbs() { + return (this.s < 0) ? this.negate() : this +} + +// (public) return + if this > a, - if this < a, 0 if equal +function bnCompareTo(a) { + var r = this.s - a.s + if (r != 0) return r + var i = this.t + r = i - a.t + if (r != 0) return (this.s < 0) ? -r : r + while (--i >= 0) + if ((r = this[i] - a[i]) != 0) return r + return 0 +} + +// returns bit length of the integer x +function nbits(x) { + var r = 1, + t + if ((t = x >>> 16) != 0) { + x = t + r += 16 + } + if ((t = x >> 8) != 0) { + x = t + r += 8 + } + if ((t = x >> 4) != 0) { + x = t + r += 4 + } + if ((t = x >> 2) != 0) { + x = t + r += 2 + } + if ((t = x >> 1) != 0) { + x = t + r += 1 + } + return r +} + +// (public) return the number of bits in "this" +function bnBitLength() { + if (this.t <= 0) return 0 + return this.DB * (this.t - 1) + nbits(this[this.t - 1] ^ (this.s & this.DM)) +} + +// (public) return the number of bytes in "this" +function bnByteLength() { + return this.bitLength() >> 3 +} + +// (protected) r = this << n*DB +function bnpDLShiftTo(n, r) { + var i + for (i = this.t - 1; i >= 0; --i) r[i + n] = this[i] + for (i = n - 1; i >= 0; --i) r[i] = 0 + r.t = this.t + n + r.s = this.s +} + +// (protected) r = this >> n*DB +function bnpDRShiftTo(n, r) { + for (var i = n; i < this.t; ++i) r[i - n] = this[i] + r.t = Math.max(this.t - n, 0) + r.s = this.s +} + +// (protected) r = this << n +function bnpLShiftTo(n, r) { + var self = this + var bs = n % self.DB + var cbs = self.DB - bs + var bm = (1 << cbs) - 1 + var ds = Math.floor(n / self.DB), + c = (self.s << bs) & self.DM, + i + for (i = self.t - 1; i >= 0; --i) { + r[i + ds + 1] = (self[i] >> cbs) | c + c = (self[i] & bm) << bs + } + for (i = ds - 1; i >= 0; --i) r[i] = 0 + r[ds] = c + r.t = self.t + ds + 1 + r.s = self.s + r.clamp() +} + +// (protected) r = this >> n +function bnpRShiftTo(n, r) { + var self = this + r.s = self.s + var ds = Math.floor(n / self.DB) + if (ds >= self.t) { + r.t = 0 + return + } + var bs = n % self.DB + var cbs = self.DB - bs + var bm = (1 << bs) - 1 + r[0] = self[ds] >> bs + for (var i = ds + 1; i < self.t; ++i) { + r[i - ds - 1] |= (self[i] & bm) << cbs + r[i - ds] = self[i] >> bs + } + if (bs > 0) r[self.t - ds - 1] |= (self.s & bm) << cbs + r.t = self.t - ds + r.clamp() +} + +// (protected) r = this - a +function bnpSubTo(a, r) { + var self = this + var i = 0, + c = 0, + m = Math.min(a.t, self.t) + while (i < m) { + c += self[i] - a[i] + r[i++] = c & self.DM + c >>= self.DB + } + if (a.t < self.t) { + c -= a.s + while (i < self.t) { + c += self[i] + r[i++] = c & self.DM + c >>= self.DB + } + c += self.s + } else { + c += self.s + while (i < a.t) { + c -= a[i] + r[i++] = c & self.DM + c >>= self.DB + } + c -= a.s + } + r.s = (c < 0) ? -1 : 0 + if (c < -1) r[i++] = self.DV + c + else if (c > 0) r[i++] = c + r.t = i + r.clamp() +} + +// (protected) r = this * a, r != this,a (HAC 14.12) +// "this" should be the larger one if appropriate. +function bnpMultiplyTo(a, r) { + var x = this.abs(), + y = a.abs() + var i = x.t + r.t = i + y.t + while (--i >= 0) r[i] = 0 + for (i = 0; i < y.t; ++i) r[i + x.t] = x.am(0, y[i], r, i, 0, x.t) + r.s = 0 + r.clamp() + if (this.s != a.s) BigInteger.ZERO.subTo(r, r) +} + +// (protected) r = this^2, r != this (HAC 14.16) +function bnpSquareTo(r) { + var x = this.abs() + var i = r.t = 2 * x.t + while (--i >= 0) r[i] = 0 + for (i = 0; i < x.t - 1; ++i) { + var c = x.am(i, x[i], r, 2 * i, 0, 1) + if ((r[i + x.t] += x.am(i + 1, 2 * x[i], r, 2 * i + 1, c, x.t - i - 1)) >= x.DV) { + r[i + x.t] -= x.DV + r[i + x.t + 1] = 1 + } + } + if (r.t > 0) r[r.t - 1] += x.am(i, x[i], r, 2 * i, 0, 1) + r.s = 0 + r.clamp() +} + +// (protected) divide this by m, quotient and remainder to q, r (HAC 14.20) +// r != q, this != m. q or r may be null. +function bnpDivRemTo(m, q, r) { + var self = this + var pm = m.abs() + if (pm.t <= 0) return + var pt = self.abs() + if (pt.t < pm.t) { + if (q != null) q.fromInt(0) + if (r != null) self.copyTo(r) + return + } + if (r == null) r = new BigInteger() + var y = new BigInteger(), + ts = self.s, + ms = m.s + var nsh = self.DB - nbits(pm[pm.t - 1]); // normalize modulus + if (nsh > 0) { + pm.lShiftTo(nsh, y) + pt.lShiftTo(nsh, r) + } else { + pm.copyTo(y) + pt.copyTo(r) + } + var ys = y.t + var y0 = y[ys - 1] + if (y0 == 0) return + var yt = y0 * (1 << self.F1) + ((ys > 1) ? y[ys - 2] >> self.F2 : 0) + var d1 = self.FV / yt, + d2 = (1 << self.F1) / yt, + e = 1 << self.F2 + var i = r.t, + j = i - ys, + t = (q == null) ? new BigInteger() : q + y.dlShiftTo(j, t) + if (r.compareTo(t) >= 0) { + r[r.t++] = 1 + r.subTo(t, r) + } + BigInteger.ONE.dlShiftTo(ys, t) + t.subTo(y, y); // "negative" y so we can replace sub with am later + while (y.t < ys) y[y.t++] = 0 + while (--j >= 0) { + // Estimate quotient digit + var qd = (r[--i] == y0) ? self.DM : Math.floor(r[i] * d1 + (r[i - 1] + e) * d2) + if ((r[i] += y.am(0, qd, r, j, 0, ys)) < qd) { // Try it out + y.dlShiftTo(j, t) + r.subTo(t, r) + while (r[i] < --qd) r.subTo(t, r) + } + } + if (q != null) { + r.drShiftTo(ys, q) + if (ts != ms) BigInteger.ZERO.subTo(q, q) + } + r.t = ys + r.clamp() + if (nsh > 0) r.rShiftTo(nsh, r); // Denormalize remainder + if (ts < 0) BigInteger.ZERO.subTo(r, r) +} + +// (public) this mod a +function bnMod(a) { + var r = new BigInteger() + this.abs() + .divRemTo(a, null, r) + if (this.s < 0 && r.compareTo(BigInteger.ZERO) > 0) a.subTo(r, r) + return r +} + +// Modular reduction using "classic" algorithm +function Classic(m) { + this.m = m +} + +function cConvert(x) { + if (x.s < 0 || x.compareTo(this.m) >= 0) return x.mod(this.m) + else return x +} + +function cRevert(x) { + return x +} + +function cReduce(x) { + x.divRemTo(this.m, null, x) +} + +function cMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) +} + +function cSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} + +Classic.prototype.convert = cConvert +Classic.prototype.revert = cRevert +Classic.prototype.reduce = cReduce +Classic.prototype.mulTo = cMulTo +Classic.prototype.sqrTo = cSqrTo + +// (protected) return "-1/this % 2^DB"; useful for Mont. reduction +// justification: +// xy == 1 (mod m) +// xy = 1+km +// xy(2-xy) = (1+km)(1-km) +// x[y(2-xy)] = 1-k^2m^2 +// x[y(2-xy)] == 1 (mod m^2) +// if y is 1/x mod m, then y(2-xy) is 1/x mod m^2 +// should reduce x and y(2-xy) by m^2 at each step to keep size bounded. +// JS multiply "overflows" differently from C/C++, so care is needed here. +function bnpInvDigit() { + if (this.t < 1) return 0 + var x = this[0] + if ((x & 1) == 0) return 0 + var y = x & 3; // y == 1/x mod 2^2 + y = (y * (2 - (x & 0xf) * y)) & 0xf; // y == 1/x mod 2^4 + y = (y * (2 - (x & 0xff) * y)) & 0xff; // y == 1/x mod 2^8 + y = (y * (2 - (((x & 0xffff) * y) & 0xffff))) & 0xffff; // y == 1/x mod 2^16 + // last step - calculate inverse mod DV directly + // assumes 16 < DB <= 32 and assumes ability to handle 48-bit ints + y = (y * (2 - x * y % this.DV)) % this.DV; // y == 1/x mod 2^dbits + // we really want the negative inverse, and -DV < y < DV + return (y > 0) ? this.DV - y : -y +} + +// Montgomery reduction +function Montgomery(m) { + this.m = m + this.mp = m.invDigit() + this.mpl = this.mp & 0x7fff + this.mph = this.mp >> 15 + this.um = (1 << (m.DB - 15)) - 1 + this.mt2 = 2 * m.t +} + +// xR mod m +function montConvert(x) { + var r = new BigInteger() + x.abs() + .dlShiftTo(this.m.t, r) + r.divRemTo(this.m, null, r) + if (x.s < 0 && r.compareTo(BigInteger.ZERO) > 0) this.m.subTo(r, r) + return r +} + +// x/R mod m +function montRevert(x) { + var r = new BigInteger() + x.copyTo(r) + this.reduce(r) + return r +} + +// x = x/R mod m (HAC 14.32) +function montReduce(x) { + while (x.t <= this.mt2) // pad x so am has enough room later + x[x.t++] = 0 + for (var i = 0; i < this.m.t; ++i) { + // faster way of calculating u0 = x[i]*mp mod DV + var j = x[i] & 0x7fff + var u0 = (j * this.mpl + (((j * this.mph + (x[i] >> 15) * this.mpl) & this.um) << 15)) & x.DM + // use am to combine the multiply-shift-add into one call + j = i + this.m.t + x[j] += this.m.am(0, u0, x, i, 0, this.m.t) + // propagate carry + while (x[j] >= x.DV) { + x[j] -= x.DV + x[++j]++ + } + } + x.clamp() + x.drShiftTo(this.m.t, x) + if (x.compareTo(this.m) >= 0) x.subTo(this.m, x) +} + +// r = "x^2/R mod m"; x != r +function montSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} + +// r = "xy/R mod m"; x,y != r +function montMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) +} + +Montgomery.prototype.convert = montConvert +Montgomery.prototype.revert = montRevert +Montgomery.prototype.reduce = montReduce +Montgomery.prototype.mulTo = montMulTo +Montgomery.prototype.sqrTo = montSqrTo + +// (protected) true iff this is even +function bnpIsEven() { + return ((this.t > 0) ? (this[0] & 1) : this.s) == 0 +} + +// (protected) this^e, e < 2^32, doing sqr and mul with "r" (HAC 14.79) +function bnpExp(e, z) { + if (e > 0xffffffff || e < 1) return BigInteger.ONE + var r = new BigInteger(), + r2 = new BigInteger(), + g = z.convert(this), + i = nbits(e) - 1 + g.copyTo(r) + while (--i >= 0) { + z.sqrTo(r, r2) + if ((e & (1 << i)) > 0) z.mulTo(r2, g, r) + else { + var t = r + r = r2 + r2 = t + } + } + return z.revert(r) +} + +// (public) this^e % m, 0 <= e < 2^32 +function bnModPowInt(e, m) { + var z + if (e < 256 || m.isEven()) z = new Classic(m) + else z = new Montgomery(m) + return this.exp(e, z) +} + +// protected +proto.copyTo = bnpCopyTo +proto.fromInt = bnpFromInt +proto.fromString = bnpFromString +proto.clamp = bnpClamp +proto.dlShiftTo = bnpDLShiftTo +proto.drShiftTo = bnpDRShiftTo +proto.lShiftTo = bnpLShiftTo +proto.rShiftTo = bnpRShiftTo +proto.subTo = bnpSubTo +proto.multiplyTo = bnpMultiplyTo +proto.squareTo = bnpSquareTo +proto.divRemTo = bnpDivRemTo +proto.invDigit = bnpInvDigit +proto.isEven = bnpIsEven +proto.exp = bnpExp + +// public +proto.toString = bnToString +proto.negate = bnNegate +proto.abs = bnAbs +proto.compareTo = bnCompareTo +proto.bitLength = bnBitLength +proto.byteLength = bnByteLength +proto.mod = bnMod +proto.modPowInt = bnModPowInt + +// (public) +function bnClone() { + var r = new BigInteger() + this.copyTo(r) + return r +} + +// (public) return value as integer +function bnIntValue() { + if (this.s < 0) { + if (this.t == 1) return this[0] - this.DV + else if (this.t == 0) return -1 + } else if (this.t == 1) return this[0] + else if (this.t == 0) return 0 + // assumes 16 < DB < 32 + return ((this[1] & ((1 << (32 - this.DB)) - 1)) << this.DB) | this[0] +} + +// (public) return value as byte +function bnByteValue() { + return (this.t == 0) ? this.s : (this[0] << 24) >> 24 +} + +// (public) return value as short (assumes DB>=16) +function bnShortValue() { + return (this.t == 0) ? this.s : (this[0] << 16) >> 16 +} + +// (protected) return x s.t. r^x < DV +function bnpChunkSize(r) { + return Math.floor(Math.LN2 * this.DB / Math.log(r)) +} + +// (public) 0 if this == 0, 1 if this > 0 +function bnSigNum() { + if (this.s < 0) return -1 + else if (this.t <= 0 || (this.t == 1 && this[0] <= 0)) return 0 + else return 1 +} + +// (protected) convert to radix string +function bnpToRadix(b) { + if (b == null) b = 10 + if (this.signum() == 0 || b < 2 || b > 36) return "0" + var cs = this.chunkSize(b) + var a = Math.pow(b, cs) + var d = nbv(a), + y = new BigInteger(), + z = new BigInteger(), + r = "" + this.divRemTo(d, y, z) + while (y.signum() > 0) { + r = (a + z.intValue()) + .toString(b) + .substr(1) + r + y.divRemTo(d, y, z) + } + return z.intValue() + .toString(b) + r +} + +// (protected) convert from radix string +function bnpFromRadix(s, b) { + var self = this + self.fromInt(0) + if (b == null) b = 10 + var cs = self.chunkSize(b) + var d = Math.pow(b, cs), + mi = false, + j = 0, + w = 0 + for (var i = 0; i < s.length; ++i) { + var x = intAt(s, i) + if (x < 0) { + if (s.charAt(i) == "-" && self.signum() == 0) mi = true + continue + } + w = b * w + x + if (++j >= cs) { + self.dMultiply(d) + self.dAddOffset(w, 0) + j = 0 + w = 0 + } + } + if (j > 0) { + self.dMultiply(Math.pow(b, j)) + self.dAddOffset(w, 0) + } + if (mi) BigInteger.ZERO.subTo(self, self) +} + +// (protected) alternate constructor +function bnpFromNumber(a, b, c) { + var self = this + if ("number" == typeof b) { + // new BigInteger(int,int,RNG) + if (a < 2) self.fromInt(1) + else { + self.fromNumber(a, c) + if (!self.testBit(a - 1)) // force MSB set + self.bitwiseTo(BigInteger.ONE.shiftLeft(a - 1), op_or, self) + if (self.isEven()) self.dAddOffset(1, 0); // force odd + while (!self.isProbablePrime(b)) { + self.dAddOffset(2, 0) + if (self.bitLength() > a) self.subTo(BigInteger.ONE.shiftLeft(a - 1), self) + } + } + } else { + // new BigInteger(int,RNG) + var x = new Array(), + t = a & 7 + x.length = (a >> 3) + 1 + b.nextBytes(x) + if (t > 0) x[0] &= ((1 << t) - 1) + else x[0] = 0 + self.fromString(x, 256) + } +} + +// (public) convert to bigendian byte array +function bnToByteArray() { + var self = this + var i = self.t, + r = new Array() + r[0] = self.s + var p = self.DB - (i * self.DB) % 8, + d, k = 0 + if (i-- > 0) { + if (p < self.DB && (d = self[i] >> p) != (self.s & self.DM) >> p) + r[k++] = d | (self.s << (self.DB - p)) + while (i >= 0) { + if (p < 8) { + d = (self[i] & ((1 << p) - 1)) << (8 - p) + d |= self[--i] >> (p += self.DB - 8) + } else { + d = (self[i] >> (p -= 8)) & 0xff + if (p <= 0) { + p += self.DB + --i + } + } + if ((d & 0x80) != 0) d |= -256 + if (k === 0 && (self.s & 0x80) != (d & 0x80))++k + if (k > 0 || d != self.s) r[k++] = d + } + } + return r +} + +function bnEquals(a) { + return (this.compareTo(a) == 0) +} + +function bnMin(a) { + return (this.compareTo(a) < 0) ? this : a +} + +function bnMax(a) { + return (this.compareTo(a) > 0) ? this : a +} + +// (protected) r = this op a (bitwise) +function bnpBitwiseTo(a, op, r) { + var self = this + var i, f, m = Math.min(a.t, self.t) + for (i = 0; i < m; ++i) r[i] = op(self[i], a[i]) + if (a.t < self.t) { + f = a.s & self.DM + for (i = m; i < self.t; ++i) r[i] = op(self[i], f) + r.t = self.t + } else { + f = self.s & self.DM + for (i = m; i < a.t; ++i) r[i] = op(f, a[i]) + r.t = a.t + } + r.s = op(self.s, a.s) + r.clamp() +} + +// (public) this & a +function op_and(x, y) { + return x & y +} + +function bnAnd(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_and, r) + return r +} + +// (public) this | a +function op_or(x, y) { + return x | y +} + +function bnOr(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_or, r) + return r +} + +// (public) this ^ a +function op_xor(x, y) { + return x ^ y +} + +function bnXor(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_xor, r) + return r +} + +// (public) this & ~a +function op_andnot(x, y) { + return x & ~y +} + +function bnAndNot(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_andnot, r) + return r +} + +// (public) ~this +function bnNot() { + var r = new BigInteger() + for (var i = 0; i < this.t; ++i) r[i] = this.DM & ~this[i] + r.t = this.t + r.s = ~this.s + return r +} + +// (public) this << n +function bnShiftLeft(n) { + var r = new BigInteger() + if (n < 0) this.rShiftTo(-n, r) + else this.lShiftTo(n, r) + return r +} + +// (public) this >> n +function bnShiftRight(n) { + var r = new BigInteger() + if (n < 0) this.lShiftTo(-n, r) + else this.rShiftTo(n, r) + return r +} + +// return index of lowest 1-bit in x, x < 2^31 +function lbit(x) { + if (x == 0) return -1 + var r = 0 + if ((x & 0xffff) == 0) { + x >>= 16 + r += 16 + } + if ((x & 0xff) == 0) { + x >>= 8 + r += 8 + } + if ((x & 0xf) == 0) { + x >>= 4 + r += 4 + } + if ((x & 3) == 0) { + x >>= 2 + r += 2 + } + if ((x & 1) == 0)++r + return r +} + +// (public) returns index of lowest 1-bit (or -1 if none) +function bnGetLowestSetBit() { + for (var i = 0; i < this.t; ++i) + if (this[i] != 0) return i * this.DB + lbit(this[i]) + if (this.s < 0) return this.t * this.DB + return -1 +} + +// return number of 1 bits in x +function cbit(x) { + var r = 0 + while (x != 0) { + x &= x - 1 + ++r + } + return r +} + +// (public) return number of set bits +function bnBitCount() { + var r = 0, + x = this.s & this.DM + for (var i = 0; i < this.t; ++i) r += cbit(this[i] ^ x) + return r +} + +// (public) true iff nth bit is set +function bnTestBit(n) { + var j = Math.floor(n / this.DB) + if (j >= this.t) return (this.s != 0) + return ((this[j] & (1 << (n % this.DB))) != 0) +} + +// (protected) this op (1<<n) +function bnpChangeBit(n, op) { + var r = BigInteger.ONE.shiftLeft(n) + this.bitwiseTo(r, op, r) + return r +} + +// (public) this | (1<<n) +function bnSetBit(n) { + return this.changeBit(n, op_or) +} + +// (public) this & ~(1<<n) +function bnClearBit(n) { + return this.changeBit(n, op_andnot) +} + +// (public) this ^ (1<<n) +function bnFlipBit(n) { + return this.changeBit(n, op_xor) +} + +// (protected) r = this + a +function bnpAddTo(a, r) { + var self = this + + var i = 0, + c = 0, + m = Math.min(a.t, self.t) + while (i < m) { + c += self[i] + a[i] + r[i++] = c & self.DM + c >>= self.DB + } + if (a.t < self.t) { + c += a.s + while (i < self.t) { + c += self[i] + r[i++] = c & self.DM + c >>= self.DB + } + c += self.s + } else { + c += self.s + while (i < a.t) { + c += a[i] + r[i++] = c & self.DM + c >>= self.DB + } + c += a.s + } + r.s = (c < 0) ? -1 : 0 + if (c > 0) r[i++] = c + else if (c < -1) r[i++] = self.DV + c + r.t = i + r.clamp() +} + +// (public) this + a +function bnAdd(a) { + var r = new BigInteger() + this.addTo(a, r) + return r +} + +// (public) this - a +function bnSubtract(a) { + var r = new BigInteger() + this.subTo(a, r) + return r +} + +// (public) this * a +function bnMultiply(a) { + var r = new BigInteger() + this.multiplyTo(a, r) + return r +} + +// (public) this^2 +function bnSquare() { + var r = new BigInteger() + this.squareTo(r) + return r +} + +// (public) this / a +function bnDivide(a) { + var r = new BigInteger() + this.divRemTo(a, r, null) + return r +} + +// (public) this % a +function bnRemainder(a) { + var r = new BigInteger() + this.divRemTo(a, null, r) + return r +} + +// (public) [this/a,this%a] +function bnDivideAndRemainder(a) { + var q = new BigInteger(), + r = new BigInteger() + this.divRemTo(a, q, r) + return new Array(q, r) +} + +// (protected) this *= n, this >= 0, 1 < n < DV +function bnpDMultiply(n) { + this[this.t] = this.am(0, n - 1, this, 0, 0, this.t) + ++this.t + this.clamp() +} + +// (protected) this += n << w words, this >= 0 +function bnpDAddOffset(n, w) { + if (n == 0) return + while (this.t <= w) this[this.t++] = 0 + this[w] += n + while (this[w] >= this.DV) { + this[w] -= this.DV + if (++w >= this.t) this[this.t++] = 0 + ++this[w] + } +} + +// A "null" reducer +function NullExp() {} + +function nNop(x) { + return x +} + +function nMulTo(x, y, r) { + x.multiplyTo(y, r) +} + +function nSqrTo(x, r) { + x.squareTo(r) +} + +NullExp.prototype.convert = nNop +NullExp.prototype.revert = nNop +NullExp.prototype.mulTo = nMulTo +NullExp.prototype.sqrTo = nSqrTo + +// (public) this^e +function bnPow(e) { + return this.exp(e, new NullExp()) +} + +// (protected) r = lower n words of "this * a", a.t <= n +// "this" should be the larger one if appropriate. +function bnpMultiplyLowerTo(a, n, r) { + var i = Math.min(this.t + a.t, n) + r.s = 0; // assumes a,this >= 0 + r.t = i + while (i > 0) r[--i] = 0 + var j + for (j = r.t - this.t; i < j; ++i) r[i + this.t] = this.am(0, a[i], r, i, 0, this.t) + for (j = Math.min(a.t, n); i < j; ++i) this.am(0, a[i], r, i, 0, n - i) + r.clamp() +} + +// (protected) r = "this * a" without lower n words, n > 0 +// "this" should be the larger one if appropriate. +function bnpMultiplyUpperTo(a, n, r) { + --n + var i = r.t = this.t + a.t - n + r.s = 0; // assumes a,this >= 0 + while (--i >= 0) r[i] = 0 + for (i = Math.max(n - this.t, 0); i < a.t; ++i) + r[this.t + i - n] = this.am(n - i, a[i], r, 0, 0, this.t + i - n) + r.clamp() + r.drShiftTo(1, r) +} + +// Barrett modular reduction +function Barrett(m) { + // setup Barrett + this.r2 = new BigInteger() + this.q3 = new BigInteger() + BigInteger.ONE.dlShiftTo(2 * m.t, this.r2) + this.mu = this.r2.divide(m) + this.m = m +} + +function barrettConvert(x) { + if (x.s < 0 || x.t > 2 * this.m.t) return x.mod(this.m) + else if (x.compareTo(this.m) < 0) return x + else { + var r = new BigInteger() + x.copyTo(r) + this.reduce(r) + return r + } +} + +function barrettRevert(x) { + return x +} + +// x = x mod m (HAC 14.42) +function barrettReduce(x) { + var self = this + x.drShiftTo(self.m.t - 1, self.r2) + if (x.t > self.m.t + 1) { + x.t = self.m.t + 1 + x.clamp() + } + self.mu.multiplyUpperTo(self.r2, self.m.t + 1, self.q3) + self.m.multiplyLowerTo(self.q3, self.m.t + 1, self.r2) + while (x.compareTo(self.r2) < 0) x.dAddOffset(1, self.m.t + 1) + x.subTo(self.r2, x) + while (x.compareTo(self.m) >= 0) x.subTo(self.m, x) +} + +// r = x^2 mod m; x != r +function barrettSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} + +// r = x*y mod m; x,y != r +function barrettMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) +} + +Barrett.prototype.convert = barrettConvert +Barrett.prototype.revert = barrettRevert +Barrett.prototype.reduce = barrettReduce +Barrett.prototype.mulTo = barrettMulTo +Barrett.prototype.sqrTo = barrettSqrTo + +// (public) this^e % m (HAC 14.85) +function bnModPow(e, m) { + var i = e.bitLength(), + k, r = nbv(1), + z + if (i <= 0) return r + else if (i < 18) k = 1 + else if (i < 48) k = 3 + else if (i < 144) k = 4 + else if (i < 768) k = 5 + else k = 6 + if (i < 8) + z = new Classic(m) + else if (m.isEven()) + z = new Barrett(m) + else + z = new Montgomery(m) + + // precomputation + var g = new Array(), + n = 3, + k1 = k - 1, + km = (1 << k) - 1 + g[1] = z.convert(this) + if (k > 1) { + var g2 = new BigInteger() + z.sqrTo(g[1], g2) + while (n <= km) { + g[n] = new BigInteger() + z.mulTo(g2, g[n - 2], g[n]) + n += 2 + } + } + + var j = e.t - 1, + w, is1 = true, + r2 = new BigInteger(), + t + i = nbits(e[j]) - 1 + while (j >= 0) { + if (i >= k1) w = (e[j] >> (i - k1)) & km + else { + w = (e[j] & ((1 << (i + 1)) - 1)) << (k1 - i) + if (j > 0) w |= e[j - 1] >> (this.DB + i - k1) + } + + n = k + while ((w & 1) == 0) { + w >>= 1 + --n + } + if ((i -= n) < 0) { + i += this.DB + --j + } + if (is1) { // ret == 1, don't bother squaring or multiplying it + g[w].copyTo(r) + is1 = false + } else { + while (n > 1) { + z.sqrTo(r, r2) + z.sqrTo(r2, r) + n -= 2 + } + if (n > 0) z.sqrTo(r, r2) + else { + t = r + r = r2 + r2 = t + } + z.mulTo(r2, g[w], r) + } + + while (j >= 0 && (e[j] & (1 << i)) == 0) { + z.sqrTo(r, r2) + t = r + r = r2 + r2 = t + if (--i < 0) { + i = this.DB - 1 + --j + } + } + } + return z.revert(r) +} + +// (public) gcd(this,a) (HAC 14.54) +function bnGCD(a) { + var x = (this.s < 0) ? this.negate() : this.clone() + var y = (a.s < 0) ? a.negate() : a.clone() + if (x.compareTo(y) < 0) { + var t = x + x = y + y = t + } + var i = x.getLowestSetBit(), + g = y.getLowestSetBit() + if (g < 0) return x + if (i < g) g = i + if (g > 0) { + x.rShiftTo(g, x) + y.rShiftTo(g, y) + } + while (x.signum() > 0) { + if ((i = x.getLowestSetBit()) > 0) x.rShiftTo(i, x) + if ((i = y.getLowestSetBit()) > 0) y.rShiftTo(i, y) + if (x.compareTo(y) >= 0) { + x.subTo(y, x) + x.rShiftTo(1, x) + } else { + y.subTo(x, y) + y.rShiftTo(1, y) + } + } + if (g > 0) y.lShiftTo(g, y) + return y +} + +// (protected) this % n, n < 2^26 +function bnpModInt(n) { + if (n <= 0) return 0 + var d = this.DV % n, + r = (this.s < 0) ? n - 1 : 0 + if (this.t > 0) + if (d == 0) r = this[0] % n + else + for (var i = this.t - 1; i >= 0; --i) r = (d * r + this[i]) % n + return r +} + +// (public) 1/this % m (HAC 14.61) +function bnModInverse(m) { + var ac = m.isEven() + if (this.signum() === 0) throw new Error('division by zero') + if ((this.isEven() && ac) || m.signum() == 0) return BigInteger.ZERO + var u = m.clone(), + v = this.clone() + var a = nbv(1), + b = nbv(0), + c = nbv(0), + d = nbv(1) + while (u.signum() != 0) { + while (u.isEven()) { + u.rShiftTo(1, u) + if (ac) { + if (!a.isEven() || !b.isEven()) { + a.addTo(this, a) + b.subTo(m, b) + } + a.rShiftTo(1, a) + } else if (!b.isEven()) b.subTo(m, b) + b.rShiftTo(1, b) + } + while (v.isEven()) { + v.rShiftTo(1, v) + if (ac) { + if (!c.isEven() || !d.isEven()) { + c.addTo(this, c) + d.subTo(m, d) + } + c.rShiftTo(1, c) + } else if (!d.isEven()) d.subTo(m, d) + d.rShiftTo(1, d) + } + if (u.compareTo(v) >= 0) { + u.subTo(v, u) + if (ac) a.subTo(c, a) + b.subTo(d, b) + } else { + v.subTo(u, v) + if (ac) c.subTo(a, c) + d.subTo(b, d) + } + } + if (v.compareTo(BigInteger.ONE) != 0) return BigInteger.ZERO + while (d.compareTo(m) >= 0) d.subTo(m, d) + while (d.signum() < 0) d.addTo(m, d) + return d +} + +var lowprimes = [ + 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, + 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, + 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, + 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307, 311, 313, 317, + 331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409, 419, + 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, + 509, 521, 523, 541, 547, 557, 563, 569, 571, 577, 587, 593, 599, 601, 607, + 613, 617, 619, 631, 641, 643, 647, 653, 659, 661, 673, 677, 683, 691, 701, + 709, 719, 727, 733, 739, 743, 751, 757, 761, 769, 773, 787, 797, 809, 811, + 821, 823, 827, 829, 839, 853, 857, 859, 863, 877, 881, 883, 887, 907, 911, + 919, 929, 937, 941, 947, 953, 967, 971, 977, 983, 991, 997 +] + +var lplim = (1 << 26) / lowprimes[lowprimes.length - 1] + +// (public) test primality with certainty >= 1-.5^t +function bnIsProbablePrime(t) { + var i, x = this.abs() + if (x.t == 1 && x[0] <= lowprimes[lowprimes.length - 1]) { + for (i = 0; i < lowprimes.length; ++i) + if (x[0] == lowprimes[i]) return true + return false + } + if (x.isEven()) return false + i = 1 + while (i < lowprimes.length) { + var m = lowprimes[i], + j = i + 1 + while (j < lowprimes.length && m < lplim) m *= lowprimes[j++] + m = x.modInt(m) + while (i < j) if (m % lowprimes[i++] == 0) return false + } + return x.millerRabin(t) +} + +// (protected) true if probably prime (HAC 4.24, Miller-Rabin) +function bnpMillerRabin(t) { + var n1 = this.subtract(BigInteger.ONE) + var k = n1.getLowestSetBit() + if (k <= 0) return false + var r = n1.shiftRight(k) + t = (t + 1) >> 1 + if (t > lowprimes.length) t = lowprimes.length + var a = new BigInteger(null) + var j, bases = [] + for (var i = 0; i < t; ++i) { + for (;;) { + j = lowprimes[Math.floor(Math.random() * lowprimes.length)] + if (bases.indexOf(j) == -1) break + } + bases.push(j) + a.fromInt(j) + var y = a.modPow(r, this) + if (y.compareTo(BigInteger.ONE) != 0 && y.compareTo(n1) != 0) { + var j = 1 + while (j++ < k && y.compareTo(n1) != 0) { + y = y.modPowInt(2, this) + if (y.compareTo(BigInteger.ONE) == 0) return false + } + if (y.compareTo(n1) != 0) return false + } + } + return true +} + +// protected +proto.chunkSize = bnpChunkSize +proto.toRadix = bnpToRadix +proto.fromRadix = bnpFromRadix +proto.fromNumber = bnpFromNumber +proto.bitwiseTo = bnpBitwiseTo +proto.changeBit = bnpChangeBit +proto.addTo = bnpAddTo +proto.dMultiply = bnpDMultiply +proto.dAddOffset = bnpDAddOffset +proto.multiplyLowerTo = bnpMultiplyLowerTo +proto.multiplyUpperTo = bnpMultiplyUpperTo +proto.modInt = bnpModInt +proto.millerRabin = bnpMillerRabin + +// public +proto.clone = bnClone +proto.intValue = bnIntValue +proto.byteValue = bnByteValue +proto.shortValue = bnShortValue +proto.signum = bnSigNum +proto.toByteArray = bnToByteArray +proto.equals = bnEquals +proto.min = bnMin +proto.max = bnMax +proto.and = bnAnd +proto.or = bnOr +proto.xor = bnXor +proto.andNot = bnAndNot +proto.not = bnNot +proto.shiftLeft = bnShiftLeft +proto.shiftRight = bnShiftRight +proto.getLowestSetBit = bnGetLowestSetBit +proto.bitCount = bnBitCount +proto.testBit = bnTestBit +proto.setBit = bnSetBit +proto.clearBit = bnClearBit +proto.flipBit = bnFlipBit +proto.add = bnAdd +proto.subtract = bnSubtract +proto.multiply = bnMultiply +proto.divide = bnDivide +proto.remainder = bnRemainder +proto.divideAndRemainder = bnDivideAndRemainder +proto.modPow = bnModPow +proto.modInverse = bnModInverse +proto.pow = bnPow +proto.gcd = bnGCD +proto.isProbablePrime = bnIsProbablePrime + +// JSBN-specific extension +proto.square = bnSquare + +// constants +BigInteger.ZERO = nbv(0) +BigInteger.ONE = nbv(1) +BigInteger.valueOf = nbv + +module.exports = BigInteger + + +/***/ }), +/* 176 */ +/***/ (function(module, exports) { + +module.exports = { + "sha224WithRSAEncryption": { + "sign": "rsa", + "hash": "sha224", + "id": "302d300d06096086480165030402040500041c" + }, + "RSA-SHA224": { + "sign": "ecdsa/rsa", + "hash": "sha224", + "id": "302d300d06096086480165030402040500041c" + }, + "sha256WithRSAEncryption": { + "sign": "rsa", + "hash": "sha256", + "id": "3031300d060960864801650304020105000420" + }, + "RSA-SHA256": { + "sign": "ecdsa/rsa", + "hash": "sha256", + "id": "3031300d060960864801650304020105000420" + }, + "sha384WithRSAEncryption": { + "sign": "rsa", + "hash": "sha384", + "id": "3041300d060960864801650304020205000430" + }, + "RSA-SHA384": { + "sign": "ecdsa/rsa", + "hash": "sha384", + "id": "3041300d060960864801650304020205000430" + }, + "sha512WithRSAEncryption": { + "sign": "rsa", + "hash": "sha512", + "id": "3051300d060960864801650304020305000440" + }, + "RSA-SHA512": { + "sign": "ecdsa/rsa", + "hash": "sha512", + "id": "3051300d060960864801650304020305000440" + }, + "RSA-SHA1": { + "sign": "rsa", + "hash": "sha1", + "id": "3021300906052b0e03021a05000414" + }, + "ecdsa-with-SHA1": { + "sign": "ecdsa", + "hash": "sha1", + "id": "" + }, + "sha256": { + "sign": "ecdsa", + "hash": "sha256", + "id": "" + }, + "sha224": { + "sign": "ecdsa", + "hash": "sha224", + "id": "" + }, + "sha384": { + "sign": "ecdsa", + "hash": "sha384", + "id": "" + }, + "sha512": { + "sign": "ecdsa", + "hash": "sha512", + "id": "" + }, + "DSA-SHA": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA-SHA1": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA-WITH-SHA224": { + "sign": "dsa", + "hash": "sha224", + "id": "" + }, + "DSA-SHA224": { + "sign": "dsa", + "hash": "sha224", + "id": "" + }, + "DSA-WITH-SHA256": { + "sign": "dsa", + "hash": "sha256", + "id": "" + }, + "DSA-SHA256": { + "sign": "dsa", + "hash": "sha256", + "id": "" + }, + "DSA-WITH-SHA384": { + "sign": "dsa", + "hash": "sha384", + "id": "" + }, + "DSA-SHA384": { + "sign": "dsa", + "hash": "sha384", + "id": "" + }, + "DSA-WITH-SHA512": { + "sign": "dsa", + "hash": "sha512", + "id": "" + }, + "DSA-SHA512": { + "sign": "dsa", + "hash": "sha512", + "id": "" + }, + "DSA-RIPEMD160": { + "sign": "dsa", + "hash": "rmd160", + "id": "" + }, + "ripemd160WithRSA": { + "sign": "rsa", + "hash": "rmd160", + "id": "3021300906052b2403020105000414" + }, + "RSA-RIPEMD160": { + "sign": "rsa", + "hash": "rmd160", + "id": "3021300906052b2403020105000414" + }, + "md5WithRSAEncryption": { + "sign": "rsa", + "hash": "md5", + "id": "3020300c06082a864886f70d020505000410" + }, + "RSA-MD5": { + "sign": "rsa", + "hash": "md5", + "id": "3020300c06082a864886f70d020505000410" + } +}; + +/***/ }), +/* 177 */ +/***/ (function(module, exports, __webpack_require__) { + + +exports.pbkdf2 = __webpack_require__(422) + +exports.pbkdf2Sync = __webpack_require__(180) + + +/***/ }), +/* 178 */ +/***/ (function(module, exports) { + +var MAX_ALLOC = Math.pow(2, 30) - 1 // default in iojs +module.exports = function (iterations, keylen) { + if (typeof iterations !== 'number') { + throw new TypeError('Iterations not a number') + } + + if (iterations < 0) { + throw new TypeError('Bad iterations') + } + + if (typeof keylen !== 'number') { + throw new TypeError('Key length not a number') + } + + if (keylen < 0 || keylen > MAX_ALLOC || keylen !== keylen) { /* eslint no-self-compare: 0 */ + throw new TypeError('Bad key length') + } +} + + +/***/ }), +/* 179 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(process) {var defaultEncoding +/* istanbul ignore next */ +if (process.browser) { + defaultEncoding = 'utf-8' +} else { + var pVersionMajor = parseInt(process.version.split('.')[0].slice(1), 10) + + defaultEncoding = pVersionMajor >= 6 ? 'utf-8' : 'binary' +} +module.exports = defaultEncoding + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 180 */ +/***/ (function(module, exports, __webpack_require__) { + +var md5 = __webpack_require__(63) +var rmd160 = __webpack_require__(97) +var sha = __webpack_require__(103) + +var checkParameters = __webpack_require__(178) +var defaultEncoding = __webpack_require__(179) +var Buffer = __webpack_require__(7).Buffer +var ZEROS = Buffer.alloc(128) +var sizes = { + md5: 16, + sha1: 20, + sha224: 28, + sha256: 32, + sha384: 48, + sha512: 64, + rmd160: 20, + ripemd160: 20 +} +function Hmac (alg, key, saltLen) { + var hash = getDigest(alg) + var blocksize = (alg === 'sha512' || alg === 'sha384') ? 128 : 64 + + if (key.length > blocksize) { + key = hash(key) + } else if (key.length < blocksize) { + key = Buffer.concat([key, ZEROS], blocksize) + } + + var ipad = Buffer.allocUnsafe(blocksize + sizes[alg]) + var opad = Buffer.allocUnsafe(blocksize + sizes[alg]) + for (var i = 0; i < blocksize; i++) { + ipad[i] = key[i] ^ 0x36 + opad[i] = key[i] ^ 0x5C + } + + var ipad1 = Buffer.allocUnsafe(blocksize + saltLen + 4) + ipad.copy(ipad1, 0, 0, blocksize) + this.ipad1 = ipad1 + this.ipad2 = ipad + this.opad = opad + this.alg = alg + this.blocksize = blocksize + this.hash = hash + this.size = sizes[alg] +} + +Hmac.prototype.run = function (data, ipad) { + data.copy(ipad, this.blocksize) + var h = this.hash(ipad) + h.copy(this.opad, this.blocksize) + return this.hash(this.opad) +} + +function getDigest (alg) { + if (alg === 'rmd160' || alg === 'ripemd160') return rmd160 + if (alg === 'md5') return md5 + return shaFunc + + function shaFunc (data) { + return sha(alg).update(data).digest() + } +} + +module.exports = function (password, salt, iterations, keylen, digest) { + if (!Buffer.isBuffer(password)) password = Buffer.from(password, defaultEncoding) + if (!Buffer.isBuffer(salt)) salt = Buffer.from(salt, defaultEncoding) + + checkParameters(iterations, keylen) + + digest = digest || 'sha1' + + var hmac = new Hmac(digest, password, salt.length) + + var DK = Buffer.allocUnsafe(keylen) + var block1 = Buffer.allocUnsafe(salt.length + 4) + salt.copy(block1, 0, 0, salt.length) + + var U, j, destPos, len + + var hLen = hmac.size + var T = Buffer.allocUnsafe(hLen) + var l = Math.ceil(keylen / hLen) + var r = keylen - (l - 1) * hLen + + for (var i = 1; i <= l; i++) { + block1.writeUInt32BE(i, salt.length) + U = hmac.run(block1, hmac.ipad1) + + U.copy(T, 0, 0, hLen) + + for (j = 1; j < iterations; j++) { + U = hmac.run(U, hmac.ipad2) + for (var k = 0; k < hLen; k++) T[k] ^= U[k] + } + + destPos = (i - 1) * hLen + len = (i === l ? r : hLen) + T.copy(DK, destPos, 0, len) + } + + return DK +} + + +/***/ }), +/* 181 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) + +inherits(StreamCipher, Transform) +module.exports = StreamCipher +function StreamCipher (mode, key, iv, decrypt) { + if (!(this instanceof StreamCipher)) { + return new StreamCipher(mode, key, iv) + } + Transform.call(this) + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + this._cache = new Buffer('') + this._secCache = new Buffer('') + this._decrypt = decrypt + iv.copy(this._prev) + this._mode = mode +} +StreamCipher.prototype._update = function (chunk) { + return this._mode.encrypt(this, chunk, this._decrypt) +} +StreamCipher.prototype._final = function () { + this._cipher.scrub() +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 182 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var GHASH = __webpack_require__(425) +var xor = __webpack_require__(51) +inherits(StreamCipher, Transform) +module.exports = StreamCipher + +function StreamCipher (mode, key, iv, decrypt) { + if (!(this instanceof StreamCipher)) { + return new StreamCipher(mode, key, iv) + } + Transform.call(this) + this._finID = Buffer.concat([iv, new Buffer([0, 0, 0, 1])]) + iv = Buffer.concat([iv, new Buffer([0, 0, 0, 2])]) + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + this._cache = new Buffer('') + this._secCache = new Buffer('') + this._decrypt = decrypt + this._alen = 0 + this._len = 0 + iv.copy(this._prev) + this._mode = mode + var h = new Buffer(4) + h.fill(0) + this._ghash = new GHASH(this._cipher.encryptBlock(h)) + this._authTag = null + this._called = false +} +StreamCipher.prototype._update = function (chunk) { + if (!this._called && this._alen) { + var rump = 16 - (this._alen % 16) + if (rump < 16) { + rump = new Buffer(rump) + rump.fill(0) + this._ghash.update(rump) + } + } + this._called = true + var out = this._mode.encrypt(this, chunk) + if (this._decrypt) { + this._ghash.update(chunk) + } else { + this._ghash.update(out) + } + this._len += chunk.length + return out +} +StreamCipher.prototype._final = function () { + if (this._decrypt && !this._authTag) { + throw new Error('Unsupported state or unable to authenticate data') + } + var tag = xor(this._ghash.final(this._alen * 8, this._len * 8), this._cipher.encryptBlock(this._finID)) + if (this._decrypt) { + if (xorTest(tag, this._authTag)) { + throw new Error('Unsupported state or unable to authenticate data') + } + } else { + this._authTag = tag + } + this._cipher.scrub() +} +StreamCipher.prototype.getAuthTag = function getAuthTag () { + if (!this._decrypt && Buffer.isBuffer(this._authTag)) { + return this._authTag + } else { + throw new Error('Attempting to get auth tag in unsupported state') + } +} +StreamCipher.prototype.setAuthTag = function setAuthTag (tag) { + if (this._decrypt) { + this._authTag = tag + } else { + throw new Error('Attempting to set auth tag in unsupported state') + } +} +StreamCipher.prototype.setAAD = function setAAD (buf) { + if (!this._called) { + this._ghash.update(buf) + this._alen += buf.length + } else { + throw new Error('Attempting to set AAD in unsupported state') + } +} +function xorTest (a, b) { + var out = 0 + if (a.length !== b.length) { + out++ + } + var len = Math.min(a.length, b.length) + var i = -1 + while (++i < len) { + out += (a[i] ^ b[i]) + } + return out +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 183 */ +/***/ (function(module, exports) { + +exports.encrypt = function (self, block) { + return self._cipher.encryptBlock(block) +} +exports.decrypt = function (self, block) { + return self._cipher.decryptBlock(block) +} + + +/***/ }), +/* 184 */ +/***/ (function(module, exports, __webpack_require__) { + +var xor = __webpack_require__(51) + +exports.encrypt = function (self, block) { + var data = xor(block, self._prev) + + self._prev = self._cipher.encryptBlock(data) + return self._prev +} + +exports.decrypt = function (self, block) { + var pad = self._prev + + self._prev = block + var out = self._cipher.decryptBlock(block) + + return xor(out, pad) +} + + +/***/ }), +/* 185 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) + +exports.encrypt = function (self, data, decrypt) { + var out = new Buffer('') + var len + + while (data.length) { + if (self._cache.length === 0) { + self._cache = self._cipher.encryptBlock(self._prev) + self._prev = new Buffer('') + } + + if (self._cache.length <= data.length) { + len = self._cache.length + out = Buffer.concat([out, encryptStart(self, data.slice(0, len), decrypt)]) + data = data.slice(len) + } else { + out = Buffer.concat([out, encryptStart(self, data, decrypt)]) + break + } + } + + return out +} +function encryptStart (self, data, decrypt) { + var len = data.length + var out = xor(data, self._cache) + self._cache = self._cache.slice(len) + self._prev = Buffer.concat([self._prev, decrypt ? data : out]) + return out +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 186 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {function encryptByte (self, byteParam, decrypt) { + var pad = self._cipher.encryptBlock(self._prev) + var out = pad[0] ^ byteParam + self._prev = Buffer.concat([self._prev.slice(1), new Buffer([decrypt ? byteParam : out])]) + return out +} +exports.encrypt = function (self, chunk, decrypt) { + var len = chunk.length + var out = new Buffer(len) + var i = -1 + while (++i < len) { + out[i] = encryptByte(self, chunk[i], decrypt) + } + return out +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 187 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {function encryptByte (self, byteParam, decrypt) { + var pad + var i = -1 + var len = 8 + var out = 0 + var bit, value + while (++i < len) { + pad = self._cipher.encryptBlock(self._prev) + bit = (byteParam & (1 << (7 - i))) ? 0x80 : 0 + value = pad[0] ^ bit + out += ((value & 0x80) >> (i % 8)) + self._prev = shiftIn(self._prev, decrypt ? bit : value) + } + return out +} +exports.encrypt = function (self, chunk, decrypt) { + var len = chunk.length + var out = new Buffer(len) + var i = -1 + while (++i < len) { + out[i] = encryptByte(self, chunk[i], decrypt) + } + return out +} +function shiftIn (buffer, value) { + var len = buffer.length + var i = -1 + var out = new Buffer(buffer.length) + buffer = Buffer.concat([buffer, new Buffer([value])]) + while (++i < len) { + out[i] = buffer[i] << 1 | buffer[i + 1] >> (7) + } + return out +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 188 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) + +function getBlock (self) { + self._prev = self._cipher.encryptBlock(self._prev) + return self._prev +} + +exports.encrypt = function (self, chunk) { + while (self._cache.length < chunk.length) { + self._cache = Buffer.concat([self._cache, getBlock(self)]) + } + + var pad = self._cache.slice(0, chunk.length) + self._cache = self._cache.slice(chunk.length) + return xor(chunk, pad) +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 189 */ +/***/ (function(module, exports, __webpack_require__) { + +var randomBytes = __webpack_require__(43); +module.exports = findPrime; +findPrime.simpleSieve = simpleSieve; +findPrime.fermatTest = fermatTest; +var BN = __webpack_require__(11); +var TWENTYFOUR = new BN(24); +var MillerRabin = __webpack_require__(190); +var millerRabin = new MillerRabin(); +var ONE = new BN(1); +var TWO = new BN(2); +var FIVE = new BN(5); +var SIXTEEN = new BN(16); +var EIGHT = new BN(8); +var TEN = new BN(10); +var THREE = new BN(3); +var SEVEN = new BN(7); +var ELEVEN = new BN(11); +var FOUR = new BN(4); +var TWELVE = new BN(12); +var primes = null; + +function _getPrimes() { + if (primes !== null) + return primes; + + var limit = 0x100000; + var res = []; + res[0] = 2; + for (var i = 1, k = 3; k < limit; k += 2) { + var sqrt = Math.ceil(Math.sqrt(k)); + for (var j = 0; j < i && res[j] <= sqrt; j++) + if (k % res[j] === 0) + break; + + if (i !== j && res[j] <= sqrt) + continue; + + res[i++] = k; + } + primes = res; + return res; +} + +function simpleSieve(p) { + var primes = _getPrimes(); + + for (var i = 0; i < primes.length; i++) + if (p.modn(primes[i]) === 0) { + if (p.cmpn(primes[i]) === 0) { + return true; + } else { + return false; + } + } + + return true; +} + +function fermatTest(p) { + var red = BN.mont(p); + return TWO.toRed(red).redPow(p.subn(1)).fromRed().cmpn(1) === 0; +} + +function findPrime(bits, gen) { + if (bits < 16) { + // this is what openssl does + if (gen === 2 || gen === 5) { + return new BN([0x8c, 0x7b]); + } else { + return new BN([0x8c, 0x27]); + } + } + gen = new BN(gen); + + var num, n2; + + while (true) { + num = new BN(randomBytes(Math.ceil(bits / 8))); + while (num.bitLength() > bits) { + num.ishrn(1); + } + if (num.isEven()) { + num.iadd(ONE); + } + if (!num.testn(1)) { + num.iadd(TWO); + } + if (!gen.cmp(TWO)) { + while (num.mod(TWENTYFOUR).cmp(ELEVEN)) { + num.iadd(FOUR); + } + } else if (!gen.cmp(FIVE)) { + while (num.mod(TEN).cmp(THREE)) { + num.iadd(FOUR); + } + } + n2 = num.shrn(1); + if (simpleSieve(n2) && simpleSieve(num) && + fermatTest(n2) && fermatTest(num) && + millerRabin.test(n2) && millerRabin.test(num)) { + return num; + } + } + +} + + +/***/ }), +/* 190 */ +/***/ (function(module, exports, __webpack_require__) { + +var bn = __webpack_require__(11); +var brorand = __webpack_require__(171); + +function MillerRabin(rand) { + this.rand = rand || new brorand.Rand(); +} +module.exports = MillerRabin; + +MillerRabin.create = function create(rand) { + return new MillerRabin(rand); +}; + +MillerRabin.prototype._rand = function _rand(n) { + var len = n.bitLength(); + var buf = this.rand.generate(Math.ceil(len / 8)); + + // Set low bits + buf[0] |= 3; + + // Mask high bits + var mask = len & 0x7; + if (mask !== 0) + buf[buf.length - 1] >>= 7 - mask; + + return new bn(buf); +} + +MillerRabin.prototype.test = function test(n, k, cb) { + var len = n.bitLength(); + var red = bn.mont(n); + var rone = new bn(1).toRed(red); + + if (!k) + k = Math.max(1, (len / 48) | 0); + + // Find d and s, (n - 1) = (2 ^ s) * d; + var n1 = n.subn(1); + var n2 = n1.subn(1); + for (var s = 0; !n1.testn(s); s++) {} + var d = n.shrn(s); + + var rn1 = n1.toRed(red); + + var prime = true; + for (; k > 0; k--) { + var a = this._rand(n2); + if (cb) + cb(a); + + var x = a.toRed(red).redPow(d); + if (x.cmp(rone) === 0 || x.cmp(rn1) === 0) + continue; + + for (var i = 1; i < s; i++) { + x = x.redSqr(); + + if (x.cmp(rone) === 0) + return false; + if (x.cmp(rn1) === 0) + break; + } + + if (i === s) + return false; + } + + return prime; +}; + +MillerRabin.prototype.getDivisor = function getDivisor(n, k) { + var len = n.bitLength(); + var red = bn.mont(n); + var rone = new bn(1).toRed(red); + + if (!k) + k = Math.max(1, (len / 48) | 0); + + // Find d and s, (n - 1) = (2 ^ s) * d; + var n1 = n.subn(1); + var n2 = n1.subn(1); + for (var s = 0; !n1.testn(s); s++) {} + var d = n.shrn(s); + + var rn1 = n1.toRed(red); + + for (; k > 0; k--) { + var a = this._rand(n2); + + var g = n.gcd(a); + if (g.cmpn(1) !== 0) + return g; + + var x = a.toRed(red).redPow(d); + if (x.cmp(rone) === 0 || x.cmp(rn1) === 0) + continue; + + for (var i = 1; i < s; i++) { + x = x.redSqr(); + + if (x.cmp(rone) === 0) + return x.fromRed().subn(1).gcd(n); + if (x.cmp(rn1) === 0) + break; + } + + if (i === s) { + x = x.redSqr(); + return x.fromRed().subn(1).gcd(n); + } + } + + return false; +}; + + +/***/ }), +/* 191 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4); +var Reporter = __webpack_require__(53).Reporter; +var Buffer = __webpack_require__(1).Buffer; + +function DecoderBuffer(base, options) { + Reporter.call(this, options); + if (!Buffer.isBuffer(base)) { + this.error('Input not Buffer'); + return; + } + + this.base = base; + this.offset = 0; + this.length = base.length; +} +inherits(DecoderBuffer, Reporter); +exports.DecoderBuffer = DecoderBuffer; + +DecoderBuffer.prototype.save = function save() { + return { offset: this.offset, reporter: Reporter.prototype.save.call(this) }; +}; + +DecoderBuffer.prototype.restore = function restore(save) { + // Return skipped data + var res = new DecoderBuffer(this.base); + res.offset = save.offset; + res.length = this.offset; + + this.offset = save.offset; + Reporter.prototype.restore.call(this, save.reporter); + + return res; +}; + +DecoderBuffer.prototype.isEmpty = function isEmpty() { + return this.offset === this.length; +}; + +DecoderBuffer.prototype.readUInt8 = function readUInt8(fail) { + if (this.offset + 1 <= this.length) + return this.base.readUInt8(this.offset++, true); + else + return this.error(fail || 'DecoderBuffer overrun'); +} + +DecoderBuffer.prototype.skip = function skip(bytes, fail) { + if (!(this.offset + bytes <= this.length)) + return this.error(fail || 'DecoderBuffer overrun'); + + var res = new DecoderBuffer(this.base); + + // Share reporter state + res._reporterState = this._reporterState; + + res.offset = this.offset; + res.length = this.offset + bytes; + this.offset += bytes; + return res; +} + +DecoderBuffer.prototype.raw = function raw(save) { + return this.base.slice(save ? save.offset : this.offset, this.length); +} + +function EncoderBuffer(value, reporter) { + if (Array.isArray(value)) { + this.length = 0; + this.value = value.map(function(item) { + if (!(item instanceof EncoderBuffer)) + item = new EncoderBuffer(item, reporter); + this.length += item.length; + return item; + }, this); + } else if (typeof value === 'number') { + if (!(0 <= value && value <= 0xff)) + return reporter.error('non-byte EncoderBuffer value'); + this.value = value; + this.length = 1; + } else if (typeof value === 'string') { + this.value = value; + this.length = Buffer.byteLength(value); + } else if (Buffer.isBuffer(value)) { + this.value = value; + this.length = value.length; + } else { + return reporter.error('Unsupported type: ' + typeof value); + } +} +exports.EncoderBuffer = EncoderBuffer; + +EncoderBuffer.prototype.join = function join(out, offset) { + if (!out) + out = new Buffer(this.length); + if (!offset) + offset = 0; + + if (this.length === 0) + return out; + + if (Array.isArray(this.value)) { + this.value.forEach(function(item) { + item.join(out, offset); + offset += item.length; + }); + } else { + if (typeof this.value === 'number') + out[offset] = this.value; + else if (typeof this.value === 'string') + out.write(this.value, offset); + else if (Buffer.isBuffer(this.value)) + this.value.copy(out, offset); + offset += this.length; + } + + return out; +}; + + +/***/ }), +/* 192 */ +/***/ (function(module, exports, __webpack_require__) { + +var constants = exports; + +// Helper +constants._reverse = function reverse(map) { + var res = {}; + + Object.keys(map).forEach(function(key) { + // Convert key to integer if it is stringified + if ((key | 0) == key) + key = key | 0; + + var value = map[key]; + res[value] = key; + }); + + return res; +}; + +constants.der = __webpack_require__(445); + + +/***/ }), +/* 193 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4); + +var asn1 = __webpack_require__(52); +var base = asn1.base; +var bignum = asn1.bignum; + +// Import DER constants +var der = asn1.constants.der; + +function DERDecoder(entity) { + this.enc = 'der'; + this.name = entity.name; + this.entity = entity; + + // Construct base tree + this.tree = new DERNode(); + this.tree._init(entity.body); +}; +module.exports = DERDecoder; + +DERDecoder.prototype.decode = function decode(data, options) { + if (!(data instanceof base.DecoderBuffer)) + data = new base.DecoderBuffer(data, options); + + return this.tree._decode(data, options); +}; + +// Tree methods + +function DERNode(parent) { + base.Node.call(this, 'der', parent); +} +inherits(DERNode, base.Node); + +DERNode.prototype._peekTag = function peekTag(buffer, tag, any) { + if (buffer.isEmpty()) + return false; + + var state = buffer.save(); + var decodedTag = derDecodeTag(buffer, 'Failed to peek tag: "' + tag + '"'); + if (buffer.isError(decodedTag)) + return decodedTag; + + buffer.restore(state); + + return decodedTag.tag === tag || decodedTag.tagStr === tag || + (decodedTag.tagStr + 'of') === tag || any; +}; + +DERNode.prototype._decodeTag = function decodeTag(buffer, tag, any) { + var decodedTag = derDecodeTag(buffer, + 'Failed to decode tag of "' + tag + '"'); + if (buffer.isError(decodedTag)) + return decodedTag; + + var len = derDecodeLen(buffer, + decodedTag.primitive, + 'Failed to get length of "' + tag + '"'); + + // Failure + if (buffer.isError(len)) + return len; + + if (!any && + decodedTag.tag !== tag && + decodedTag.tagStr !== tag && + decodedTag.tagStr + 'of' !== tag) { + return buffer.error('Failed to match tag: "' + tag + '"'); + } + + if (decodedTag.primitive || len !== null) + return buffer.skip(len, 'Failed to match body of: "' + tag + '"'); + + // Indefinite length... find END tag + var state = buffer.save(); + var res = this._skipUntilEnd( + buffer, + 'Failed to skip indefinite length body: "' + this.tag + '"'); + if (buffer.isError(res)) + return res; + + len = buffer.offset - state.offset; + buffer.restore(state); + return buffer.skip(len, 'Failed to match body of: "' + tag + '"'); +}; + +DERNode.prototype._skipUntilEnd = function skipUntilEnd(buffer, fail) { + while (true) { + var tag = derDecodeTag(buffer, fail); + if (buffer.isError(tag)) + return tag; + var len = derDecodeLen(buffer, tag.primitive, fail); + if (buffer.isError(len)) + return len; + + var res; + if (tag.primitive || len !== null) + res = buffer.skip(len) + else + res = this._skipUntilEnd(buffer, fail); + + // Failure + if (buffer.isError(res)) + return res; + + if (tag.tagStr === 'end') + break; + } +}; + +DERNode.prototype._decodeList = function decodeList(buffer, tag, decoder, + options) { + var result = []; + while (!buffer.isEmpty()) { + var possibleEnd = this._peekTag(buffer, 'end'); + if (buffer.isError(possibleEnd)) + return possibleEnd; + + var res = decoder.decode(buffer, 'der', options); + if (buffer.isError(res) && possibleEnd) + break; + result.push(res); + } + return result; +}; + +DERNode.prototype._decodeStr = function decodeStr(buffer, tag) { + if (tag === 'bitstr') { + var unused = buffer.readUInt8(); + if (buffer.isError(unused)) + return unused; + return { unused: unused, data: buffer.raw() }; + } else if (tag === 'bmpstr') { + var raw = buffer.raw(); + if (raw.length % 2 === 1) + return buffer.error('Decoding of string type: bmpstr length mismatch'); + + var str = ''; + for (var i = 0; i < raw.length / 2; i++) { + str += String.fromCharCode(raw.readUInt16BE(i * 2)); + } + return str; + } else if (tag === 'numstr') { + var numstr = buffer.raw().toString('ascii'); + if (!this._isNumstr(numstr)) { + return buffer.error('Decoding of string type: ' + + 'numstr unsupported characters'); + } + return numstr; + } else if (tag === 'octstr') { + return buffer.raw(); + } else if (tag === 'objDesc') { + return buffer.raw(); + } else if (tag === 'printstr') { + var printstr = buffer.raw().toString('ascii'); + if (!this._isPrintstr(printstr)) { + return buffer.error('Decoding of string type: ' + + 'printstr unsupported characters'); + } + return printstr; + } else if (/str$/.test(tag)) { + return buffer.raw().toString(); + } else { + return buffer.error('Decoding of string type: ' + tag + ' unsupported'); + } +}; + +DERNode.prototype._decodeObjid = function decodeObjid(buffer, values, relative) { + var result; + var identifiers = []; + var ident = 0; + while (!buffer.isEmpty()) { + var subident = buffer.readUInt8(); + ident <<= 7; + ident |= subident & 0x7f; + if ((subident & 0x80) === 0) { + identifiers.push(ident); + ident = 0; + } + } + if (subident & 0x80) + identifiers.push(ident); + + var first = (identifiers[0] / 40) | 0; + var second = identifiers[0] % 40; + + if (relative) + result = identifiers; + else + result = [first, second].concat(identifiers.slice(1)); + + if (values) { + var tmp = values[result.join(' ')]; + if (tmp === undefined) + tmp = values[result.join('.')]; + if (tmp !== undefined) + result = tmp; + } + + return result; +}; + +DERNode.prototype._decodeTime = function decodeTime(buffer, tag) { + var str = buffer.raw().toString(); + if (tag === 'gentime') { + var year = str.slice(0, 4) | 0; + var mon = str.slice(4, 6) | 0; + var day = str.slice(6, 8) | 0; + var hour = str.slice(8, 10) | 0; + var min = str.slice(10, 12) | 0; + var sec = str.slice(12, 14) | 0; + } else if (tag === 'utctime') { + var year = str.slice(0, 2) | 0; + var mon = str.slice(2, 4) | 0; + var day = str.slice(4, 6) | 0; + var hour = str.slice(6, 8) | 0; + var min = str.slice(8, 10) | 0; + var sec = str.slice(10, 12) | 0; + if (year < 70) + year = 2000 + year; + else + year = 1900 + year; + } else { + return buffer.error('Decoding ' + tag + ' time is not supported yet'); + } + + return Date.UTC(year, mon - 1, day, hour, min, sec, 0); +}; + +DERNode.prototype._decodeNull = function decodeNull(buffer) { + return null; +}; + +DERNode.prototype._decodeBool = function decodeBool(buffer) { + var res = buffer.readUInt8(); + if (buffer.isError(res)) + return res; + else + return res !== 0; +}; + +DERNode.prototype._decodeInt = function decodeInt(buffer, values) { + // Bigint, return as it is (assume big endian) + var raw = buffer.raw(); + var res = new bignum(raw); + + if (values) + res = values[res.toString(10)] || res; + + return res; +}; + +DERNode.prototype._use = function use(entity, obj) { + if (typeof entity === 'function') + entity = entity(obj); + return entity._getDecoder('der').tree; +}; + +// Utility methods + +function derDecodeTag(buf, fail) { + var tag = buf.readUInt8(fail); + if (buf.isError(tag)) + return tag; + + var cls = der.tagClass[tag >> 6]; + var primitive = (tag & 0x20) === 0; + + // Multi-octet tag - load + if ((tag & 0x1f) === 0x1f) { + var oct = tag; + tag = 0; + while ((oct & 0x80) === 0x80) { + oct = buf.readUInt8(fail); + if (buf.isError(oct)) + return oct; + + tag <<= 7; + tag |= oct & 0x7f; + } + } else { + tag &= 0x1f; + } + var tagStr = der.tag[tag]; + + return { + cls: cls, + primitive: primitive, + tag: tag, + tagStr: tagStr + }; +} + +function derDecodeLen(buf, primitive, fail) { + var len = buf.readUInt8(fail); + if (buf.isError(len)) + return len; + + // Indefinite form + if (!primitive && len === 0x80) + return null; + + // Definite form + if ((len & 0x80) === 0) { + // Short form + return len; + } + + // Long form + var num = len & 0x7f; + if (num > 4) + return buf.error('length octect is too long'); + + len = 0; + for (var i = 0; i < num; i++) { + len <<= 8; + var j = buf.readUInt8(fail); + if (buf.isError(j)) + return j; + len |= j; + } + + return len; +} + + +/***/ }), +/* 194 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4); +var Buffer = __webpack_require__(1).Buffer; + +var asn1 = __webpack_require__(52); +var base = asn1.base; + +// Import DER constants +var der = asn1.constants.der; + +function DEREncoder(entity) { + this.enc = 'der'; + this.name = entity.name; + this.entity = entity; + + // Construct base tree + this.tree = new DERNode(); + this.tree._init(entity.body); +}; +module.exports = DEREncoder; + +DEREncoder.prototype.encode = function encode(data, reporter) { + return this.tree._encode(data, reporter).join(); +}; + +// Tree methods + +function DERNode(parent) { + base.Node.call(this, 'der', parent); +} +inherits(DERNode, base.Node); + +DERNode.prototype._encodeComposite = function encodeComposite(tag, + primitive, + cls, + content) { + var encodedTag = encodeTag(tag, primitive, cls, this.reporter); + + // Short form + if (content.length < 0x80) { + var header = new Buffer(2); + header[0] = encodedTag; + header[1] = content.length; + return this._createEncoderBuffer([ header, content ]); + } + + // Long form + // Count octets required to store length + var lenOctets = 1; + for (var i = content.length; i >= 0x100; i >>= 8) + lenOctets++; + + var header = new Buffer(1 + 1 + lenOctets); + header[0] = encodedTag; + header[1] = 0x80 | lenOctets; + + for (var i = 1 + lenOctets, j = content.length; j > 0; i--, j >>= 8) + header[i] = j & 0xff; + + return this._createEncoderBuffer([ header, content ]); +}; + +DERNode.prototype._encodeStr = function encodeStr(str, tag) { + if (tag === 'bitstr') { + return this._createEncoderBuffer([ str.unused | 0, str.data ]); + } else if (tag === 'bmpstr') { + var buf = new Buffer(str.length * 2); + for (var i = 0; i < str.length; i++) { + buf.writeUInt16BE(str.charCodeAt(i), i * 2); + } + return this._createEncoderBuffer(buf); + } else if (tag === 'numstr') { + if (!this._isNumstr(str)) { + return this.reporter.error('Encoding of string type: numstr supports ' + + 'only digits and space'); + } + return this._createEncoderBuffer(str); + } else if (tag === 'printstr') { + if (!this._isPrintstr(str)) { + return this.reporter.error('Encoding of string type: printstr supports ' + + 'only latin upper and lower case letters, ' + + 'digits, space, apostrophe, left and rigth ' + + 'parenthesis, plus sign, comma, hyphen, ' + + 'dot, slash, colon, equal sign, ' + + 'question mark'); + } + return this._createEncoderBuffer(str); + } else if (/str$/.test(tag)) { + return this._createEncoderBuffer(str); + } else if (tag === 'objDesc') { + return this._createEncoderBuffer(str); + } else { + return this.reporter.error('Encoding of string type: ' + tag + + ' unsupported'); + } +}; + +DERNode.prototype._encodeObjid = function encodeObjid(id, values, relative) { + if (typeof id === 'string') { + if (!values) + return this.reporter.error('string objid given, but no values map found'); + if (!values.hasOwnProperty(id)) + return this.reporter.error('objid not found in values map'); + id = values[id].split(/[\s\.]+/g); + for (var i = 0; i < id.length; i++) + id[i] |= 0; + } else if (Array.isArray(id)) { + id = id.slice(); + for (var i = 0; i < id.length; i++) + id[i] |= 0; + } + + if (!Array.isArray(id)) { + return this.reporter.error('objid() should be either array or string, ' + + 'got: ' + JSON.stringify(id)); + } + + if (!relative) { + if (id[1] >= 40) + return this.reporter.error('Second objid identifier OOB'); + id.splice(0, 2, id[0] * 40 + id[1]); + } + + // Count number of octets + var size = 0; + for (var i = 0; i < id.length; i++) { + var ident = id[i]; + for (size++; ident >= 0x80; ident >>= 7) + size++; + } + + var objid = new Buffer(size); + var offset = objid.length - 1; + for (var i = id.length - 1; i >= 0; i--) { + var ident = id[i]; + objid[offset--] = ident & 0x7f; + while ((ident >>= 7) > 0) + objid[offset--] = 0x80 | (ident & 0x7f); + } + + return this._createEncoderBuffer(objid); +}; + +function two(num) { + if (num < 10) + return '0' + num; + else + return num; +} + +DERNode.prototype._encodeTime = function encodeTime(time, tag) { + var str; + var date = new Date(time); + + if (tag === 'gentime') { + str = [ + two(date.getFullYear()), + two(date.getUTCMonth() + 1), + two(date.getUTCDate()), + two(date.getUTCHours()), + two(date.getUTCMinutes()), + two(date.getUTCSeconds()), + 'Z' + ].join(''); + } else if (tag === 'utctime') { + str = [ + two(date.getFullYear() % 100), + two(date.getUTCMonth() + 1), + two(date.getUTCDate()), + two(date.getUTCHours()), + two(date.getUTCMinutes()), + two(date.getUTCSeconds()), + 'Z' + ].join(''); + } else { + this.reporter.error('Encoding ' + tag + ' time is not supported yet'); + } + + return this._encodeStr(str, 'octstr'); +}; + +DERNode.prototype._encodeNull = function encodeNull() { + return this._createEncoderBuffer(''); +}; + +DERNode.prototype._encodeInt = function encodeInt(num, values) { + if (typeof num === 'string') { + if (!values) + return this.reporter.error('String int or enum given, but no values map'); + if (!values.hasOwnProperty(num)) { + return this.reporter.error('Values map doesn\'t contain: ' + + JSON.stringify(num)); + } + num = values[num]; + } + + // Bignum, assume big endian + if (typeof num !== 'number' && !Buffer.isBuffer(num)) { + var numArray = num.toArray(); + if (!num.sign && numArray[0] & 0x80) { + numArray.unshift(0); + } + num = new Buffer(numArray); + } + + if (Buffer.isBuffer(num)) { + var size = num.length; + if (num.length === 0) + size++; + + var out = new Buffer(size); + num.copy(out); + if (num.length === 0) + out[0] = 0 + return this._createEncoderBuffer(out); + } + + if (num < 0x80) + return this._createEncoderBuffer(num); + + if (num < 0x100) + return this._createEncoderBuffer([0, num]); + + var size = 1; + for (var i = num; i >= 0x100; i >>= 8) + size++; + + var out = new Array(size); + for (var i = out.length - 1; i >= 0; i--) { + out[i] = num & 0xff; + num >>= 8; + } + if(out[0] & 0x80) { + out.unshift(0); + } + + return this._createEncoderBuffer(new Buffer(out)); +}; + +DERNode.prototype._encodeBool = function encodeBool(value) { + return this._createEncoderBuffer(value ? 0xff : 0); +}; + +DERNode.prototype._use = function use(entity, obj) { + if (typeof entity === 'function') + entity = entity(obj); + return entity._getEncoder('der').tree; +}; + +DERNode.prototype._skipDefault = function skipDefault(dataBuffer, reporter, parent) { + var state = this._baseState; + var i; + if (state['default'] === null) + return false; + + var data = dataBuffer.join(); + if (state.defaultBuffer === undefined) + state.defaultBuffer = this._encodeValue(state['default'], reporter, parent).join(); + + if (data.length !== state.defaultBuffer.length) + return false; + + for (i=0; i < data.length; i++) + if (data[i] !== state.defaultBuffer[i]) + return false; + + return true; +}; + +// Utility methods + +function encodeTag(tag, primitive, cls, reporter) { + var res; + + if (tag === 'seqof') + tag = 'seq'; + else if (tag === 'setof') + tag = 'set'; + + if (der.tagByName.hasOwnProperty(tag)) + res = der.tagByName[tag]; + else if (typeof tag === 'number' && (tag | 0) === tag) + res = tag; + else + return reporter.error('Unknown tag: ' + tag); + + if (res >= 0x1f) + return reporter.error('Multi-octet tag encoding unsupported'); + + if (!primitive) + res |= 0x20; + + res |= (der.tagClassByName[cls || 'universal'] << 6); + + return res; +} + + +/***/ }), +/* 195 */ +/***/ (function(module, exports) { + +module.exports = { + "1.3.132.0.10": "secp256k1", + "1.3.132.0.33": "p224", + "1.2.840.10045.3.1.1": "p192", + "1.2.840.10045.3.1.7": "p256", + "1.3.132.0.34": "p384", + "1.3.132.0.35": "p521" +}; + +/***/ }), +/* 196 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var createHash = __webpack_require__(27); +module.exports = function (seed, len) { + var t = new Buffer(''); + var i = 0, c; + while (t.length < len) { + c = i2ops(i++); + t = Buffer.concat([t, createHash('sha1').update(seed).update(c).digest()]); + } + return t.slice(0, len); +}; + +function i2ops(c) { + var out = new Buffer(4); + out.writeUInt32BE(c,0); + return out; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 197 */ +/***/ (function(module, exports) { + +module.exports = function xor(a, b) { + var len = a.length; + var i = -1; + while (++i < len) { + a[i] ^= b[i]; + } + return a +}; + +/***/ }), +/* 198 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var bn = __webpack_require__(11); +function withPublic(paddedMsg, key) { + return new Buffer(paddedMsg + .toRed(bn.mont(key.modulus)) + .redPow(new bn(key.publicExponent)) + .fromRed() + .toArray()); +} + +module.exports = withPublic; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 199 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) { + +// https://github.com/bitcoinjs/bitcoinjs-lib/issues/14 +function numToBytes(num, bytes) { + if (bytes == 0) return [];else return [num % 256].concat(numToBytes(Math.floor(num / 256), bytes - 1)); +} + +function numToVarInt(num) { + var b; + if (num < 253) b = [num];else if (num < 65536) b = [253].concat(numToBytes(num, 2));else if (num < 4294967296) b = [254].concat(numToBytes(num, 4));else b = [253].concat(numToBytes(num, 8)); + return Buffer.from(b).toString('hex'); +} + +// https://github.com/feross/buffer/blob/master/index.js#L1127 +function verifuint(value, max) { + if (typeof value !== 'number') { + throw new Error('cannot write a non-number as a number'); + } + if (value < 0) { + throw new Error('specified a negative value for writing an unsigned value'); + } + if (value > max) throw new Error('RangeError: value out of range'); + if (Math.floor(value) !== value) { + throw new Error('value has a fractional component'); + } +} + +function readUInt64LE(buffer, offset) { + var a = buffer.readUInt32LE(offset); + var b = buffer.readUInt32LE(offset + 4); + b *= 0x100000000; + + verifuint(b + a, 0x001fffffffffffff); + + return b + a; +} + +function writeUInt64LE(buffer, value, offset) { + verifuint(value, 0x001fffffffffffff); + + buffer.writeInt32LE(value & -1, offset); + buffer.writeUInt32LE(Math.floor(value / 0x100000000), offset + 4); + return offset + 8; +} + +/* + * Given a hex string, get the length of it in bytes + * ** NOT string.length, but convert it into bytes + * and return the length of that in bytes in hex + * @param {String} hexStr + * return {String} Length of hexStr in bytes + */ +function getStringBufferLength(hexStr) { + const _tmpBuf = Buffer.from(hexStr, 'hex').length; + return Buffer.from([_tmpBuf]).toString('hex'); +} + +module.exports = { + readUInt64LE: readUInt64LE, + writeUInt64LE: writeUInt64LE, + getStringBufferLength: getStringBufferLength, + numToVarInt: numToVarInt, + numToBytes: numToBytes +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 200 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = { + Block: __webpack_require__(465), + ECPair: __webpack_require__(113), + ECSignature: __webpack_require__(115), + HDNode: __webpack_require__(493), + Transaction: __webpack_require__(112), + TransactionBuilder: __webpack_require__(494), + + address: __webpack_require__(114), + bufferutils: __webpack_require__(206), // TODO: remove in 4.0.0 + crypto: __webpack_require__(44), + networks: __webpack_require__(54), + opcodes: __webpack_require__(16), + script: __webpack_require__(14) +} + + +/***/ }), +/* 201 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4) +var native = __webpack_require__(111) + +function TfTypeError (type, value, valueTypeName) { + this.__error = Error.call(this) + this.__type = type + this.__value = value + this.__valueTypeName = valueTypeName + + var message + Object.defineProperty(this, 'message', { + enumerable: true, + get: function () { + if (message) return message + + valueTypeName = valueTypeName || getValueTypeName(value) + message = tfErrorString(type, value, valueTypeName) + + return message + } + }) +} + +function TfPropertyTypeError (type, property, label, value, error, valueTypeName) { + this.__error = error || Error.call(this) + this.__label = label + this.__property = property + this.__type = type + this.__value = value + this.__valueTypeName = valueTypeName + + var message + Object.defineProperty(this, 'message', { + enumerable: true, + get: function () { + if (message) return message + if (type) { + valueTypeName = valueTypeName || getValueTypeName(value) + message = tfPropertyErrorString(type, label, property, value, valueTypeName) + } else { + message = 'Unexpected property "' + property + '"' + } + + return message + } + }) +} + +// inherit from Error, assign stack +[TfTypeError, TfPropertyTypeError].forEach(function (tfErrorType) { + inherits(tfErrorType, Error) + Object.defineProperty(tfErrorType, 'stack', { + get: function () { return this.__error.stack } + }) +}) + +function tfCustomError (expected, actual) { + return new TfTypeError(expected, {}, actual) +} + +function tfSubError (e, property, label) { + // sub child? + if (e instanceof TfPropertyTypeError) { + property = property + '.' + e.__property + label = e.__label + + return new TfPropertyTypeError( + e.__type, property, label, e.__value, e.__error, e.__valueTypeName + ) + } + + // child? + if (e instanceof TfTypeError) { + return new TfPropertyTypeError( + e.__type, property, label, e.__value, e.__error, e.__valueTypeName + ) + } + + return e +} + +function getTypeName (fn) { + return fn.name || fn.toString().match(/function (.*?)\s*\(/)[1] +} + +function getValueTypeName (value) { + return native.Nil(value) ? '' : getTypeName(value.constructor) +} + +function getValue (value) { + if (native.Function(value)) return '' + if (native.String(value)) return JSON.stringify(value) + if (value && native.Object(value)) return '' + return value +} + +function tfJSON (type) { + if (native.Function(type)) return type.toJSON ? type.toJSON() : getTypeName(type) + if (native.Array(type)) return 'Array' + if (type && native.Object(type)) return 'Object' + + return type !== undefined ? type : '' +} + +function tfErrorString (type, value, valueTypeName) { + var valueJson = getValue(value) + + return 'Expected ' + tfJSON(type) + ', got' + + (valueTypeName !== '' ? ' ' + valueTypeName : '') + + (valueJson !== '' ? ' ' + valueJson : '') +} + +function tfPropertyErrorString (type, label, name, value, valueTypeName) { + var description = '" of type ' + if (label === 'key') description = '" with key type ' + + return tfErrorString('property "' + tfJSON(name) + description + tfJSON(type), value, valueTypeName) +} + +module.exports = { + TfTypeError: TfTypeError, + TfPropertyTypeError: TfPropertyTypeError, + tfCustomError: tfCustomError, + tfSubError: tfSubError, + tfJSON: tfJSON, + getValueTypeName: getValueTypeName +} + + +/***/ }), +/* 202 */ +/***/ (function(module, exports, __webpack_require__) { + +var OPS = __webpack_require__(16) + +function encodingLength (i) { + return i < OPS.OP_PUSHDATA1 ? 1 + : i <= 0xff ? 2 + : i <= 0xffff ? 3 + : 5 +} + +function encode (buffer, number, offset) { + var size = encodingLength(number) + + // ~6 bit + if (size === 1) { + buffer.writeUInt8(number, offset) + + // 8 bit + } else if (size === 2) { + buffer.writeUInt8(OPS.OP_PUSHDATA1, offset) + buffer.writeUInt8(number, offset + 1) + + // 16 bit + } else if (size === 3) { + buffer.writeUInt8(OPS.OP_PUSHDATA2, offset) + buffer.writeUInt16LE(number, offset + 1) + + // 32 bit + } else { + buffer.writeUInt8(OPS.OP_PUSHDATA4, offset) + buffer.writeUInt32LE(number, offset + 1) + } + + return size +} + +function decode (buffer, offset) { + var opcode = buffer.readUInt8(offset) + var number, size + + // ~6 bit + if (opcode < OPS.OP_PUSHDATA1) { + number = opcode + size = 1 + + // 8 bit + } else if (opcode === OPS.OP_PUSHDATA1) { + if (offset + 2 > buffer.length) return null + number = buffer.readUInt8(offset + 1) + size = 2 + + // 16 bit + } else if (opcode === OPS.OP_PUSHDATA2) { + if (offset + 3 > buffer.length) return null + number = buffer.readUInt16LE(offset + 1) + size = 3 + + // 32 bit + } else { + if (offset + 5 > buffer.length) return null + if (opcode !== OPS.OP_PUSHDATA4) throw new Error('Unexpected opcode') + + number = buffer.readUInt32LE(offset + 1) + size = 5 + } + + return { + opcode: opcode, + number: number, + size: size + } +} + +module.exports = { + encodingLength: encodingLength, + encode: encode, + decode: decode +} + + +/***/ }), +/* 203 */ +/***/ (function(module, exports, __webpack_require__) { + +var Buffer = __webpack_require__(7).Buffer + +function decode (buffer, maxLength, minimal) { + maxLength = maxLength || 4 + minimal = minimal === undefined ? true : minimal + + var length = buffer.length + if (length === 0) return 0 + if (length > maxLength) throw new TypeError('Script number overflow') + if (minimal) { + if ((buffer[length - 1] & 0x7f) === 0) { + if (length <= 1 || (buffer[length - 2] & 0x80) === 0) throw new Error('Non-minimally encoded script number') + } + } + + // 40-bit + if (length === 5) { + var a = buffer.readUInt32LE(0) + var b = buffer.readUInt8(4) + + if (b & 0x80) return -(((b & ~0x80) * 0x100000000) + a) + return (b * 0x100000000) + a + } + + var result = 0 + + // 32-bit / 24-bit / 16-bit / 8-bit + for (var i = 0; i < length; ++i) { + result |= buffer[i] << (8 * i) + } + + if (buffer[length - 1] & 0x80) return -(result & ~(0x80 << (8 * (length - 1)))) + return result +} + +function scriptNumSize (i) { + return i > 0x7fffffff ? 5 + : i > 0x7fffff ? 4 + : i > 0x7fff ? 3 + : i > 0x7f ? 2 + : i > 0x00 ? 1 + : 0 +} + +function encode (number) { + var value = Math.abs(number) + var size = scriptNumSize(value) + var buffer = Buffer.allocUnsafe(size) + var negative = number < 0 + + for (var i = 0; i < size; ++i) { + buffer.writeUInt8(value & 0xff, i) + value >>= 8 + } + + if (buffer[size - 1] & 0x80) { + buffer.writeUInt8(negative ? 0x80 : 0x00, size - 1) + } else if (negative) { + buffer[size - 1] |= 0x80 + } + + return buffer +} + +module.exports = { + decode: decode, + encode: encode +} + + +/***/ }), +/* 204 */ +/***/ (function(module, exports, __webpack_require__) { + +// {signature} {pubKey} + +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) + +function check (script) { + var chunks = bscript.decompile(script) + + return chunks.length === 2 && + bscript.isCanonicalSignature(chunks[0]) && + bscript.isCanonicalPubKey(chunks[1]) +} +check.toJSON = function () { return 'pubKeyHash input' } + +function encodeStack (signature, pubKey) { + typeforce({ + signature: types.Buffer, pubKey: types.Buffer + }, { + signature: signature, pubKey: pubKey + }) + + return [signature, pubKey] +} + +function encode (signature, pubKey) { + return bscript.compile(encodeStack(signature, pubKey)) +} + +function decodeStack (stack) { + typeforce(check, stack) + + return { + signature: stack[0], + pubKey: stack[1] + } +} + +function decode (buffer) { + var stack = bscript.decompile(buffer) + return decodeStack(stack) +} + +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} + + +/***/ }), +/* 205 */ +/***/ (function(module, exports, __webpack_require__) { + +// <scriptSig> {serialized scriptPubKey script} + +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) + +function check (script, allowIncomplete) { + var chunks = bscript.decompile(script) + if (chunks.length < 1) return false + + var lastChunk = chunks[chunks.length - 1] + if (!Buffer.isBuffer(lastChunk)) return false + + var scriptSigChunks = bscript.decompile(bscript.compile(chunks.slice(0, -1))) + var redeemScriptChunks = bscript.decompile(lastChunk) + + // is redeemScript a valid script? + if (redeemScriptChunks.length === 0) return false + + // is redeemScriptSig push only? + if (!bscript.isPushOnly(scriptSigChunks)) return false + + var inputType = bscript.classifyInput(scriptSigChunks, allowIncomplete) + var outputType = bscript.classifyOutput(redeemScriptChunks) + if (chunks.length === 1) { + return outputType === bscript.types.P2WSH || outputType === bscript.types.P2WPKH + } + return inputType === outputType +} +check.toJSON = function () { return 'scriptHash input' } + +function encodeStack (redeemScriptStack, redeemScript) { + var serializedScriptPubKey = bscript.compile(redeemScript) + + return [].concat(redeemScriptStack, serializedScriptPubKey) +} + +function encode (redeemScriptSig, redeemScript) { + var redeemScriptStack = bscript.decompile(redeemScriptSig) + + return bscript.compile(encodeStack(redeemScriptStack, redeemScript)) +} + +function decodeStack (stack) { + typeforce(check, stack) + + return { + redeemScriptStack: stack.slice(0, -1), + redeemScript: stack[stack.length - 1] + } +} + +function decode (buffer) { + var stack = bscript.decompile(buffer) + var result = decodeStack(stack) + result.redeemScriptSig = bscript.compile(result.redeemScriptStack) + delete result.redeemScriptStack + return result +} + +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} + + +/***/ }), +/* 206 */ +/***/ (function(module, exports, __webpack_require__) { + +var pushdata = __webpack_require__(202) +var varuint = __webpack_require__(73) + +// https://github.com/feross/buffer/blob/master/index.js#L1127 +function verifuint (value, max) { + if (typeof value !== 'number') throw new Error('cannot write a non-number as a number') + if (value < 0) throw new Error('specified a negative value for writing an unsigned value') + if (value > max) throw new Error('RangeError: value out of range') + if (Math.floor(value) !== value) throw new Error('value has a fractional component') +} + +function readUInt64LE (buffer, offset) { + var a = buffer.readUInt32LE(offset) + var b = buffer.readUInt32LE(offset + 4) + b *= 0x100000000 + + verifuint(b + a, 0x001fffffffffffff) + + return b + a +} + +function writeUInt64LE (buffer, value, offset) { + verifuint(value, 0x001fffffffffffff) + + buffer.writeInt32LE(value & -1, offset) + buffer.writeUInt32LE(Math.floor(value / 0x100000000), offset + 4) + return offset + 8 +} + +// TODO: remove in 4.0.0? +function readVarInt (buffer, offset) { + var result = varuint.decode(buffer, offset) + + return { + number: result, + size: varuint.decode.bytes + } +} + +// TODO: remove in 4.0.0? +function writeVarInt (buffer, number, offset) { + varuint.encode(number, buffer, offset) + return varuint.encode.bytes +} + +module.exports = { + pushDataSize: pushdata.encodingLength, + readPushDataInt: pushdata.decode, + readUInt64LE: readUInt64LE, + readVarInt: readVarInt, + varIntBuffer: varuint.encode, + varIntSize: varuint.encodingLength, + writePushDataInt: pushdata.encode, + writeUInt64LE: writeUInt64LE, + writeVarInt: writeVarInt +} + + +/***/ }), +/* 207 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(30) + +var THREE = BigInteger.valueOf(3) + +function Point (curve, x, y, z) { + assert.notStrictEqual(z, undefined, 'Missing Z coordinate') + + this.curve = curve + this.x = x + this.y = y + this.z = z + this._zInv = null + + this.compressed = true +} + +Object.defineProperty(Point.prototype, 'zInv', { + get: function () { + if (this._zInv === null) { + this._zInv = this.z.modInverse(this.curve.p) + } + + return this._zInv + } +}) + +Object.defineProperty(Point.prototype, 'affineX', { + get: function () { + return this.x.multiply(this.zInv).mod(this.curve.p) + } +}) + +Object.defineProperty(Point.prototype, 'affineY', { + get: function () { + return this.y.multiply(this.zInv).mod(this.curve.p) + } +}) + +Point.fromAffine = function (curve, x, y) { + return new Point(curve, x, y, BigInteger.ONE) +} + +Point.prototype.equals = function (other) { + if (other === this) return true + if (this.curve.isInfinity(this)) return this.curve.isInfinity(other) + if (this.curve.isInfinity(other)) return this.curve.isInfinity(this) + + // u = Y2 * Z1 - Y1 * Z2 + var u = other.y.multiply(this.z).subtract(this.y.multiply(other.z)).mod(this.curve.p) + + if (u.signum() !== 0) return false + + // v = X2 * Z1 - X1 * Z2 + var v = other.x.multiply(this.z).subtract(this.x.multiply(other.z)).mod(this.curve.p) + + return v.signum() === 0 +} + +Point.prototype.negate = function () { + var y = this.curve.p.subtract(this.y) + + return new Point(this.curve, this.x, y, this.z) +} + +Point.prototype.add = function (b) { + if (this.curve.isInfinity(this)) return b + if (this.curve.isInfinity(b)) return this + + var x1 = this.x + var y1 = this.y + var x2 = b.x + var y2 = b.y + + // u = Y2 * Z1 - Y1 * Z2 + var u = y2.multiply(this.z).subtract(y1.multiply(b.z)).mod(this.curve.p) + // v = X2 * Z1 - X1 * Z2 + var v = x2.multiply(this.z).subtract(x1.multiply(b.z)).mod(this.curve.p) + + if (v.signum() === 0) { + if (u.signum() === 0) { + return this.twice() // this == b, so double + } + + return this.curve.infinity // this = -b, so infinity + } + + var v2 = v.square() + var v3 = v2.multiply(v) + var x1v2 = x1.multiply(v2) + var zu2 = u.square().multiply(this.z) + + // x3 = v * (z2 * (z1 * u^2 - 2 * x1 * v^2) - v^3) + var x3 = zu2.subtract(x1v2.shiftLeft(1)).multiply(b.z).subtract(v3).multiply(v).mod(this.curve.p) + // y3 = z2 * (3 * x1 * u * v^2 - y1 * v^3 - z1 * u^3) + u * v^3 + var y3 = x1v2.multiply(THREE).multiply(u).subtract(y1.multiply(v3)).subtract(zu2.multiply(u)).multiply(b.z).add(u.multiply(v3)).mod(this.curve.p) + // z3 = v^3 * z1 * z2 + var z3 = v3.multiply(this.z).multiply(b.z).mod(this.curve.p) + + return new Point(this.curve, x3, y3, z3) +} + +Point.prototype.twice = function () { + if (this.curve.isInfinity(this)) return this + if (this.y.signum() === 0) return this.curve.infinity + + var x1 = this.x + var y1 = this.y + + var y1z1 = y1.multiply(this.z).mod(this.curve.p) + var y1sqz1 = y1z1.multiply(y1).mod(this.curve.p) + var a = this.curve.a + + // w = 3 * x1^2 + a * z1^2 + var w = x1.square().multiply(THREE) + + if (a.signum() !== 0) { + w = w.add(this.z.square().multiply(a)) + } + + w = w.mod(this.curve.p) + // x3 = 2 * y1 * z1 * (w^2 - 8 * x1 * y1^2 * z1) + var x3 = w.square().subtract(x1.shiftLeft(3).multiply(y1sqz1)).shiftLeft(1).multiply(y1z1).mod(this.curve.p) + // y3 = 4 * y1^2 * z1 * (3 * w * x1 - 2 * y1^2 * z1) - w^3 + var y3 = w.multiply(THREE).multiply(x1).subtract(y1sqz1.shiftLeft(1)).shiftLeft(2).multiply(y1sqz1).subtract(w.pow(3)).mod(this.curve.p) + // z3 = 8 * (y1 * z1)^3 + var z3 = y1z1.pow(3).shiftLeft(3).mod(this.curve.p) + + return new Point(this.curve, x3, y3, z3) +} + +// Simple NAF (Non-Adjacent Form) multiplication algorithm +// TODO: modularize the multiplication algorithm +Point.prototype.multiply = function (k) { + if (this.curve.isInfinity(this)) return this + if (k.signum() === 0) return this.curve.infinity + + var e = k + var h = e.multiply(THREE) + + var neg = this.negate() + var R = this + + for (var i = h.bitLength() - 2; i > 0; --i) { + var hBit = h.testBit(i) + var eBit = e.testBit(i) + + R = R.twice() + + if (hBit !== eBit) { + R = R.add(hBit ? this : neg) + } + } + + return R +} + +// Compute this*j + x*k (simultaneous multiplication) +Point.prototype.multiplyTwo = function (j, x, k) { + var i = Math.max(j.bitLength(), k.bitLength()) - 1 + var R = this.curve.infinity + var both = this.add(x) + + while (i >= 0) { + var jBit = j.testBit(i) + var kBit = k.testBit(i) + + R = R.twice() + + if (jBit) { + if (kBit) { + R = R.add(both) + } else { + R = R.add(this) + } + } else if (kBit) { + R = R.add(x) + } + --i + } + + return R +} + +Point.prototype.getEncoded = function (compressed) { + if (compressed == null) compressed = this.compressed + if (this.curve.isInfinity(this)) return new Buffer('00', 'hex') // Infinity point encoded is simply '00' + + var x = this.affineX + var y = this.affineY + var byteLength = this.curve.pLength + var buffer + + // 0x02/0x03 | X + if (compressed) { + buffer = new Buffer(1 + byteLength) + buffer.writeUInt8(y.isEven() ? 0x02 : 0x03, 0) + + // 0x04 | X | Y + } else { + buffer = new Buffer(1 + byteLength + byteLength) + buffer.writeUInt8(0x04, 0) + + y.toBuffer(byteLength).copy(buffer, 1 + byteLength) + } + + x.toBuffer(byteLength).copy(buffer, 1) + + return buffer +} + +Point.decodeFrom = function (curve, buffer) { + var type = buffer.readUInt8(0) + var compressed = (type !== 4) + + var byteLength = Math.floor((curve.p.bitLength() + 7) / 8) + var x = BigInteger.fromBuffer(buffer.slice(1, 1 + byteLength)) + + var Q + if (compressed) { + assert.equal(buffer.length, byteLength + 1, 'Invalid sequence length') + assert(type === 0x02 || type === 0x03, 'Invalid sequence tag') + + var isOdd = (type === 0x03) + Q = curve.pointFromX(isOdd, x) + } else { + assert.equal(buffer.length, 1 + byteLength + byteLength, 'Invalid sequence length') + + var y = BigInteger.fromBuffer(buffer.slice(1 + byteLength)) + Q = Point.fromAffine(curve, x, y) + } + + Q.compressed = compressed + return Q +} + +Point.prototype.toString = function () { + if (this.curve.isInfinity(this)) return '(INFINITY)' + + return '(' + this.affineX.toString() + ',' + this.affineY.toString() + ')' +} + +module.exports = Point + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 208 */ +/***/ (function(module, exports, __webpack_require__) { + +var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(30) + +var Point = __webpack_require__(207) + +function Curve (p, a, b, Gx, Gy, n, h) { + this.p = p + this.a = a + this.b = b + this.G = Point.fromAffine(this, Gx, Gy) + this.n = n + this.h = h + + this.infinity = new Point(this, null, null, BigInteger.ZERO) + + // result caching + this.pOverFour = p.add(BigInteger.ONE).shiftRight(2) + + // determine size of p in bytes + this.pLength = Math.floor((this.p.bitLength() + 7) / 8) +} + +Curve.prototype.pointFromX = function (isOdd, x) { + var alpha = x.pow(3).add(this.a.multiply(x)).add(this.b).mod(this.p) + var beta = alpha.modPow(this.pOverFour, this.p) // XXX: not compatible with all curves + + var y = beta + if (beta.isEven() ^ !isOdd) { + y = this.p.subtract(y) // -y % p + } + + return Point.fromAffine(this, x, y) +} + +Curve.prototype.isInfinity = function (Q) { + if (Q === this.infinity) return true + + return Q.z.signum() === 0 && Q.y.signum() !== 0 +} + +Curve.prototype.isOnCurve = function (Q) { + if (this.isInfinity(Q)) return true + + var x = Q.affineX + var y = Q.affineY + var a = this.a + var b = this.b + var p = this.p + + // Check that xQ and yQ are integers in the interval [0, p - 1] + if (x.signum() < 0 || x.compareTo(p) >= 0) return false + if (y.signum() < 0 || y.compareTo(p) >= 0) return false + + // and check that y^2 = x^3 + ax + b (mod p) + var lhs = y.square().mod(p) + var rhs = x.pow(3).add(a.multiply(x)).add(b).mod(p) + return lhs.equals(rhs) +} + +/** + * Validate an elliptic curve point. + * + * See SEC 1, section 3.2.2.1: Elliptic Curve Public Key Validation Primitive + */ +Curve.prototype.validate = function (Q) { + // Check Q != O + assert(!this.isInfinity(Q), 'Point is at infinity') + assert(this.isOnCurve(Q), 'Point is not on the curve') + + // Check nQ = O (where Q is a scalar multiple of G) + var nQ = Q.multiply(this.n) + assert(this.isInfinity(nQ), 'Point is not a scalar multiple of G') + + return true +} + +module.exports = Curve + + +/***/ }), +/* 209 */ +/***/ (function(module, exports) { + +// https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki#account-discovery +module.exports = function discovery (chain, gapLimit, queryCb, done) { + var gap = 0 + var checked = 0 + + function cycle () { + var batch = [chain.get()] + checked++ + + while (batch.length < gapLimit) { + chain.next() + batch.push(chain.get()) + + checked++ + } + + queryCb(batch, function (err, results) { + if (err) return done(err) + + results.forEach(function (isUsed) { + if (isUsed) { + gap = 0 + } else { + gap += 1 + } + }) + + if (gap >= gapLimit) { + var used = checked - gap + + return done(undefined, used, checked) + } else { + chain.next() + } + + cycle() + }) + } + + cycle() +} + + +/***/ }), +/* 210 */ +/***/ (function(module, exports) { + +function Chain (parent, k) { + k = k || 0 + this.__parent = parent + + this.addresses = [] + this.k = k + this.map = {} +} + +Chain.prototype.__initialize = function () { + var address = this.__parent.derive(this.k).getAddress() + this.map[address] = this.k + this.addresses.push(address) +} + +Chain.prototype.clone = function () { + var chain = new Chain(this.__parent, this.k) + + for (var k in this.addresses) chain.addresses[k] = this.addresses[k] + for (k in this.map) chain.map[k] = this.map[k] + + return chain +} + +Chain.prototype.derive = function (address, parent) { + var k = this.map[address] + if (k === undefined) return + + parent = parent || this.__parent + return parent.derive(k) +} + +Chain.prototype.find = function (address) { + return this.map[address] +} + +Chain.prototype.get = function () { + if (this.addresses.length === 0) this.__initialize() + + return this.addresses[this.addresses.length - 1] +} + +Chain.prototype.getAll = function () { + if (this.addresses.length === 0) this.__initialize() + + return this.addresses +} + +Chain.prototype.getParent = function () { + return this.__parent +} + +Chain.prototype.next = function () { + if (this.addresses.length === 0) this.__initialize() + var address = this.__parent.derive(this.k + 1).getAddress() + + this.k += 1 + this.map[address] = this.k + this.addresses.push(address) + + return address +} + +Chain.prototype.pop = function () { + var address = this.addresses.pop() + delete this.map[address] + this.k -= 1 + + return address +} + +module.exports = Chain + + +/***/ }), +/* 211 */ +/***/ (function(module, exports, __webpack_require__) { + +// style-loader: Adds some css to the DOM by adding a <style> tag + +// load the styles +var content = __webpack_require__(212); +if(typeof content === 'string') content = [[module.i, content, '']]; +// Prepare cssTransformation +var transform; + +var options = {} +options.transform = transform +// add the styles to the DOM +var update = __webpack_require__(118)(content, options); +if(content.locals) module.exports = content.locals; +// Hot Module Replacement +if(false) { + // When the styles change, update the <style> tags + if(!content.locals) { + module.hot.accept("!!../../../css-loader/index.js!./bootstrap.css", function() { + var newContent = require("!!../../../css-loader/index.js!./bootstrap.css"); + if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; + update(newContent); + }); + } + // When the module is disposed, remove the <style> tags + module.hot.dispose(function() { update(); }); +} + +/***/ }), +/* 212 */ +/***/ (function(module, exports, __webpack_require__) { + +exports = module.exports = __webpack_require__(117)(undefined); +// imports + + +// module +exports.push([module.i, "/*!\n * Bootstrap v4.0.0-alpha.6 (https://getbootstrap.com)\n * Copyright 2011-2017 The Bootstrap Authors\n * Copyright 2011-2017 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n */\n/*! normalize.css v5.0.0 | MIT License | github.com/necolas/normalize.css */\nhtml {\n font-family: sans-serif;\n line-height: 1.15;\n -ms-text-size-adjust: 100%;\n -webkit-text-size-adjust: 100%;\n}\n\nbody {\n margin: 0;\n}\n\narticle,\naside,\nfooter,\nheader,\nnav,\nsection {\n display: block;\n}\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\nfigcaption,\nfigure,\nmain {\n display: block;\n}\n\nfigure {\n margin: 1em 40px;\n}\n\nhr {\n -webkit-box-sizing: content-box;\n box-sizing: content-box;\n height: 0;\n overflow: visible;\n}\n\npre {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\na {\n background-color: transparent;\n -webkit-text-decoration-skip: objects;\n}\n\na:active,\na:hover {\n outline-width: 0;\n}\n\nabbr[title] {\n border-bottom: none;\n text-decoration: underline;\n text-decoration: underline dotted;\n}\n\nb,\nstrong {\n font-weight: inherit;\n}\n\nb,\nstrong {\n font-weight: bolder;\n}\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\ndfn {\n font-style: italic;\n}\n\nmark {\n background-color: #ff0;\n color: #000;\n}\n\nsmall {\n font-size: 80%;\n}\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\naudio,\nvideo {\n display: inline-block;\n}\n\naudio:not([controls]) {\n display: none;\n height: 0;\n}\n\nimg {\n border-style: none;\n}\n\nsvg:not(:root) {\n overflow: hidden;\n}\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: sans-serif;\n font-size: 100%;\n line-height: 1.15;\n margin: 0;\n}\n\nbutton,\ninput {\n overflow: visible;\n}\n\nbutton,\nselect {\n text-transform: none;\n}\n\nbutton,\nhtml [type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\nfieldset {\n border: 1px solid #c0c0c0;\n margin: 0 2px;\n padding: 0.35em 0.625em 0.75em;\n}\n\nlegend {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: inherit;\n display: table;\n max-width: 100%;\n padding: 0;\n white-space: normal;\n}\n\nprogress {\n display: inline-block;\n vertical-align: baseline;\n}\n\ntextarea {\n overflow: auto;\n}\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n padding: 0;\n}\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n[type=\"search\"] {\n -webkit-appearance: textfield;\n outline-offset: -2px;\n}\n\n[type=\"search\"]::-webkit-search-cancel-button,\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n::-webkit-file-upload-button {\n -webkit-appearance: button;\n font: inherit;\n}\n\ndetails,\nmenu {\n display: block;\n}\n\nsummary {\n display: list-item;\n}\n\ncanvas {\n display: inline-block;\n}\n\ntemplate {\n display: none;\n}\n\n[hidden] {\n display: none;\n}\n\n@media print {\n *,\n *::before,\n *::after,\n p::first-letter,\n div::first-letter,\n blockquote::first-letter,\n li::first-letter,\n p::first-line,\n div::first-line,\n blockquote::first-line,\n li::first-line {\n text-shadow: none !important;\n -webkit-box-shadow: none !important;\n box-shadow: none !important;\n }\n a,\n a:visited {\n text-decoration: underline;\n }\n abbr[title]::after {\n content: \" (\" attr(title) \")\";\n }\n pre {\n white-space: pre-wrap !important;\n }\n pre,\n blockquote {\n border: 1px solid #999;\n page-break-inside: avoid;\n }\n thead {\n display: table-header-group;\n }\n tr,\n img {\n page-break-inside: avoid;\n }\n p,\n h2,\n h3 {\n orphans: 3;\n widows: 3;\n }\n h2,\n h3 {\n page-break-after: avoid;\n }\n .navbar {\n display: none;\n }\n .badge {\n border: 1px solid #000;\n }\n .table {\n border-collapse: collapse !important;\n }\n .table td,\n .table th {\n background-color: #fff !important;\n }\n .table-bordered th,\n .table-bordered td {\n border: 1px solid #ddd !important;\n }\n}\n\nhtml {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n}\n\n*,\n*::before,\n*::after {\n -webkit-box-sizing: inherit;\n box-sizing: inherit;\n}\n\n@-ms-viewport {\n width: device-width;\n}\n\nhtml {\n -ms-overflow-style: scrollbar;\n -webkit-tap-highlight-color: transparent;\n}\n\nbody {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.5;\n color: #292b2c;\n background-color: #fff;\n}\n\n[tabindex=\"-1\"]:focus {\n outline: none !important;\n}\n\nh1, h2, h3, h4, h5, h6 {\n margin-top: 0;\n margin-bottom: .5rem;\n}\n\np {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nabbr[title],\nabbr[data-original-title] {\n cursor: help;\n}\n\naddress {\n margin-bottom: 1rem;\n font-style: normal;\n line-height: inherit;\n}\n\nol,\nul,\ndl {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nol ol,\nul ul,\nol ul,\nul ol {\n margin-bottom: 0;\n}\n\ndt {\n font-weight: bold;\n}\n\ndd {\n margin-bottom: .5rem;\n margin-left: 0;\n}\n\nblockquote {\n margin: 0 0 1rem;\n}\n\na {\n color: #0275d8;\n text-decoration: none;\n}\n\na:focus, a:hover {\n color: #014c8c;\n text-decoration: underline;\n}\n\na:not([href]):not([tabindex]) {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus, a:not([href]):not([tabindex]):hover {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus {\n outline: 0;\n}\n\npre {\n margin-top: 0;\n margin-bottom: 1rem;\n overflow: auto;\n}\n\nfigure {\n margin: 0 0 1rem;\n}\n\nimg {\n vertical-align: middle;\n}\n\n[role=\"button\"] {\n cursor: pointer;\n}\n\na,\narea,\nbutton,\n[role=\"button\"],\ninput,\nlabel,\nselect,\nsummary,\ntextarea {\n -ms-touch-action: manipulation;\n touch-action: manipulation;\n}\n\ntable {\n border-collapse: collapse;\n background-color: transparent;\n}\n\ncaption {\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n color: #636c72;\n text-align: left;\n caption-side: bottom;\n}\n\nth {\n text-align: left;\n}\n\nlabel {\n display: inline-block;\n margin-bottom: .5rem;\n}\n\nbutton:focus {\n outline: 1px dotted;\n outline: 5px auto -webkit-focus-ring-color;\n}\n\ninput,\nbutton,\nselect,\ntextarea {\n line-height: inherit;\n}\n\ninput[type=\"radio\"]:disabled,\ninput[type=\"checkbox\"]:disabled {\n cursor: not-allowed;\n}\n\ninput[type=\"date\"],\ninput[type=\"time\"],\ninput[type=\"datetime-local\"],\ninput[type=\"month\"] {\n -webkit-appearance: listbox;\n}\n\ntextarea {\n resize: vertical;\n}\n\nfieldset {\n min-width: 0;\n padding: 0;\n margin: 0;\n border: 0;\n}\n\nlegend {\n display: block;\n width: 100%;\n padding: 0;\n margin-bottom: .5rem;\n font-size: 1.5rem;\n line-height: inherit;\n}\n\ninput[type=\"search\"] {\n -webkit-appearance: none;\n}\n\noutput {\n display: inline-block;\n}\n\n[hidden] {\n display: none !important;\n}\n\nh1, h2, h3, h4, h5, h6,\n.h1, .h2, .h3, .h4, .h5, .h6 {\n margin-bottom: 0.5rem;\n font-family: inherit;\n font-weight: 500;\n line-height: 1.1;\n color: inherit;\n}\n\nh1, .h1 {\n font-size: 2.5rem;\n}\n\nh2, .h2 {\n font-size: 2rem;\n}\n\nh3, .h3 {\n font-size: 1.75rem;\n}\n\nh4, .h4 {\n font-size: 1.5rem;\n}\n\nh5, .h5 {\n font-size: 1.25rem;\n}\n\nh6, .h6 {\n font-size: 1rem;\n}\n\n.lead {\n font-size: 1.25rem;\n font-weight: 300;\n}\n\n.display-1 {\n font-size: 6rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-2 {\n font-size: 5.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-3 {\n font-size: 4.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-4 {\n font-size: 3.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\nhr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n border: 0;\n border-top: 1px solid rgba(0, 0, 0, 0.1);\n}\n\nsmall,\n.small {\n font-size: 80%;\n font-weight: normal;\n}\n\nmark,\n.mark {\n padding: 0.2em;\n background-color: #fcf8e3;\n}\n\n.list-unstyled {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline-item {\n display: inline-block;\n}\n\n.list-inline-item:not(:last-child) {\n margin-right: 5px;\n}\n\n.initialism {\n font-size: 90%;\n text-transform: uppercase;\n}\n\n.blockquote {\n padding: 0.5rem 1rem;\n margin-bottom: 1rem;\n font-size: 1.25rem;\n border-left: 0.25rem solid #eceeef;\n}\n\n.blockquote-footer {\n display: block;\n font-size: 80%;\n color: #636c72;\n}\n\n.blockquote-footer::before {\n content: \"\\2014 \\A0\";\n}\n\n.blockquote-reverse {\n padding-right: 1rem;\n padding-left: 0;\n text-align: right;\n border-right: 0.25rem solid #eceeef;\n border-left: 0;\n}\n\n.blockquote-reverse .blockquote-footer::before {\n content: \"\";\n}\n\n.blockquote-reverse .blockquote-footer::after {\n content: \"\\A0 \\2014\";\n}\n\n.img-fluid {\n max-width: 100%;\n height: auto;\n}\n\n.img-thumbnail {\n padding: 0.25rem;\n background-color: #fff;\n border: 1px solid #ddd;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n max-width: 100%;\n height: auto;\n}\n\n.figure {\n display: inline-block;\n}\n\n.figure-img {\n margin-bottom: 0.5rem;\n line-height: 1;\n}\n\n.figure-caption {\n font-size: 90%;\n color: #636c72;\n}\n\ncode,\nkbd,\npre,\nsamp {\n font-family: Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;\n}\n\ncode {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #bd4147;\n background-color: #f7f7f9;\n border-radius: 0.25rem;\n}\n\na > code {\n padding: 0;\n color: inherit;\n background-color: inherit;\n}\n\nkbd {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #fff;\n background-color: #292b2c;\n border-radius: 0.2rem;\n}\n\nkbd kbd {\n padding: 0;\n font-size: 100%;\n font-weight: bold;\n}\n\npre {\n display: block;\n margin-top: 0;\n margin-bottom: 1rem;\n font-size: 90%;\n color: #292b2c;\n}\n\npre code {\n padding: 0;\n font-size: inherit;\n color: inherit;\n background-color: transparent;\n border-radius: 0;\n}\n\n.pre-scrollable {\n max-height: 340px;\n overflow-y: scroll;\n}\n\n.container {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .container {\n width: 540px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n width: 720px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n width: 960px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n width: 1140px;\n max-width: 100%;\n }\n}\n\n.container-fluid {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.row {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: wrap;\n -ms-flex-wrap: wrap;\n flex-wrap: wrap;\n margin-right: -15px;\n margin-left: -15px;\n}\n\n@media (min-width: 576px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 768px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 992px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 1200px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n.no-gutters {\n margin-right: 0;\n margin-left: 0;\n}\n\n.no-gutters > .col,\n.no-gutters > [class*=\"col-\"] {\n padding-right: 0;\n padding-left: 0;\n}\n\n.col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n position: relative;\n width: 100%;\n min-height: 1px;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.col {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n}\n\n.col-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n}\n\n.col-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n}\n\n.col-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n}\n\n.col-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n}\n\n.col-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n}\n\n.col-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n}\n\n.col-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n}\n\n.col-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n}\n\n.col-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n}\n\n.col-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n}\n\n.col-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n}\n\n.col-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n}\n\n.col-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n}\n\n.pull-0 {\n right: auto;\n}\n\n.pull-1 {\n right: 8.333333%;\n}\n\n.pull-2 {\n right: 16.666667%;\n}\n\n.pull-3 {\n right: 25%;\n}\n\n.pull-4 {\n right: 33.333333%;\n}\n\n.pull-5 {\n right: 41.666667%;\n}\n\n.pull-6 {\n right: 50%;\n}\n\n.pull-7 {\n right: 58.333333%;\n}\n\n.pull-8 {\n right: 66.666667%;\n}\n\n.pull-9 {\n right: 75%;\n}\n\n.pull-10 {\n right: 83.333333%;\n}\n\n.pull-11 {\n right: 91.666667%;\n}\n\n.pull-12 {\n right: 100%;\n}\n\n.push-0 {\n left: auto;\n}\n\n.push-1 {\n left: 8.333333%;\n}\n\n.push-2 {\n left: 16.666667%;\n}\n\n.push-3 {\n left: 25%;\n}\n\n.push-4 {\n left: 33.333333%;\n}\n\n.push-5 {\n left: 41.666667%;\n}\n\n.push-6 {\n left: 50%;\n}\n\n.push-7 {\n left: 58.333333%;\n}\n\n.push-8 {\n left: 66.666667%;\n}\n\n.push-9 {\n left: 75%;\n}\n\n.push-10 {\n left: 83.333333%;\n}\n\n.push-11 {\n left: 91.666667%;\n}\n\n.push-12 {\n left: 100%;\n}\n\n.offset-1 {\n margin-left: 8.333333%;\n}\n\n.offset-2 {\n margin-left: 16.666667%;\n}\n\n.offset-3 {\n margin-left: 25%;\n}\n\n.offset-4 {\n margin-left: 33.333333%;\n}\n\n.offset-5 {\n margin-left: 41.666667%;\n}\n\n.offset-6 {\n margin-left: 50%;\n}\n\n.offset-7 {\n margin-left: 58.333333%;\n}\n\n.offset-8 {\n margin-left: 66.666667%;\n}\n\n.offset-9 {\n margin-left: 75%;\n}\n\n.offset-10 {\n margin-left: 83.333333%;\n}\n\n.offset-11 {\n margin-left: 91.666667%;\n}\n\n@media (min-width: 576px) {\n .col-sm {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-sm-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-sm-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-sm-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-sm-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-sm-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-sm-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-sm-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-sm-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-sm-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-sm-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-sm-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-sm-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-sm-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-sm-0 {\n right: auto;\n }\n .pull-sm-1 {\n right: 8.333333%;\n }\n .pull-sm-2 {\n right: 16.666667%;\n }\n .pull-sm-3 {\n right: 25%;\n }\n .pull-sm-4 {\n right: 33.333333%;\n }\n .pull-sm-5 {\n right: 41.666667%;\n }\n .pull-sm-6 {\n right: 50%;\n }\n .pull-sm-7 {\n right: 58.333333%;\n }\n .pull-sm-8 {\n right: 66.666667%;\n }\n .pull-sm-9 {\n right: 75%;\n }\n .pull-sm-10 {\n right: 83.333333%;\n }\n .pull-sm-11 {\n right: 91.666667%;\n }\n .pull-sm-12 {\n right: 100%;\n }\n .push-sm-0 {\n left: auto;\n }\n .push-sm-1 {\n left: 8.333333%;\n }\n .push-sm-2 {\n left: 16.666667%;\n }\n .push-sm-3 {\n left: 25%;\n }\n .push-sm-4 {\n left: 33.333333%;\n }\n .push-sm-5 {\n left: 41.666667%;\n }\n .push-sm-6 {\n left: 50%;\n }\n .push-sm-7 {\n left: 58.333333%;\n }\n .push-sm-8 {\n left: 66.666667%;\n }\n .push-sm-9 {\n left: 75%;\n }\n .push-sm-10 {\n left: 83.333333%;\n }\n .push-sm-11 {\n left: 91.666667%;\n }\n .push-sm-12 {\n left: 100%;\n }\n .offset-sm-0 {\n margin-left: 0%;\n }\n .offset-sm-1 {\n margin-left: 8.333333%;\n }\n .offset-sm-2 {\n margin-left: 16.666667%;\n }\n .offset-sm-3 {\n margin-left: 25%;\n }\n .offset-sm-4 {\n margin-left: 33.333333%;\n }\n .offset-sm-5 {\n margin-left: 41.666667%;\n }\n .offset-sm-6 {\n margin-left: 50%;\n }\n .offset-sm-7 {\n margin-left: 58.333333%;\n }\n .offset-sm-8 {\n margin-left: 66.666667%;\n }\n .offset-sm-9 {\n margin-left: 75%;\n }\n .offset-sm-10 {\n margin-left: 83.333333%;\n }\n .offset-sm-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 768px) {\n .col-md {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-md-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-md-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-md-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-md-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-md-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-md-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-md-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-md-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-md-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-md-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-md-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-md-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-md-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-md-0 {\n right: auto;\n }\n .pull-md-1 {\n right: 8.333333%;\n }\n .pull-md-2 {\n right: 16.666667%;\n }\n .pull-md-3 {\n right: 25%;\n }\n .pull-md-4 {\n right: 33.333333%;\n }\n .pull-md-5 {\n right: 41.666667%;\n }\n .pull-md-6 {\n right: 50%;\n }\n .pull-md-7 {\n right: 58.333333%;\n }\n .pull-md-8 {\n right: 66.666667%;\n }\n .pull-md-9 {\n right: 75%;\n }\n .pull-md-10 {\n right: 83.333333%;\n }\n .pull-md-11 {\n right: 91.666667%;\n }\n .pull-md-12 {\n right: 100%;\n }\n .push-md-0 {\n left: auto;\n }\n .push-md-1 {\n left: 8.333333%;\n }\n .push-md-2 {\n left: 16.666667%;\n }\n .push-md-3 {\n left: 25%;\n }\n .push-md-4 {\n left: 33.333333%;\n }\n .push-md-5 {\n left: 41.666667%;\n }\n .push-md-6 {\n left: 50%;\n }\n .push-md-7 {\n left: 58.333333%;\n }\n .push-md-8 {\n left: 66.666667%;\n }\n .push-md-9 {\n left: 75%;\n }\n .push-md-10 {\n left: 83.333333%;\n }\n .push-md-11 {\n left: 91.666667%;\n }\n .push-md-12 {\n left: 100%;\n }\n .offset-md-0 {\n margin-left: 0%;\n }\n .offset-md-1 {\n margin-left: 8.333333%;\n }\n .offset-md-2 {\n margin-left: 16.666667%;\n }\n .offset-md-3 {\n margin-left: 25%;\n }\n .offset-md-4 {\n margin-left: 33.333333%;\n }\n .offset-md-5 {\n margin-left: 41.666667%;\n }\n .offset-md-6 {\n margin-left: 50%;\n }\n .offset-md-7 {\n margin-left: 58.333333%;\n }\n .offset-md-8 {\n margin-left: 66.666667%;\n }\n .offset-md-9 {\n margin-left: 75%;\n }\n .offset-md-10 {\n margin-left: 83.333333%;\n }\n .offset-md-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 992px) {\n .col-lg {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-lg-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-lg-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-lg-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-lg-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-lg-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-lg-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-lg-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-lg-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-lg-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-lg-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-lg-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-lg-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-lg-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-lg-0 {\n right: auto;\n }\n .pull-lg-1 {\n right: 8.333333%;\n }\n .pull-lg-2 {\n right: 16.666667%;\n }\n .pull-lg-3 {\n right: 25%;\n }\n .pull-lg-4 {\n right: 33.333333%;\n }\n .pull-lg-5 {\n right: 41.666667%;\n }\n .pull-lg-6 {\n right: 50%;\n }\n .pull-lg-7 {\n right: 58.333333%;\n }\n .pull-lg-8 {\n right: 66.666667%;\n }\n .pull-lg-9 {\n right: 75%;\n }\n .pull-lg-10 {\n right: 83.333333%;\n }\n .pull-lg-11 {\n right: 91.666667%;\n }\n .pull-lg-12 {\n right: 100%;\n }\n .push-lg-0 {\n left: auto;\n }\n .push-lg-1 {\n left: 8.333333%;\n }\n .push-lg-2 {\n left: 16.666667%;\n }\n .push-lg-3 {\n left: 25%;\n }\n .push-lg-4 {\n left: 33.333333%;\n }\n .push-lg-5 {\n left: 41.666667%;\n }\n .push-lg-6 {\n left: 50%;\n }\n .push-lg-7 {\n left: 58.333333%;\n }\n .push-lg-8 {\n left: 66.666667%;\n }\n .push-lg-9 {\n left: 75%;\n }\n .push-lg-10 {\n left: 83.333333%;\n }\n .push-lg-11 {\n left: 91.666667%;\n }\n .push-lg-12 {\n left: 100%;\n }\n .offset-lg-0 {\n margin-left: 0%;\n }\n .offset-lg-1 {\n margin-left: 8.333333%;\n }\n .offset-lg-2 {\n margin-left: 16.666667%;\n }\n .offset-lg-3 {\n margin-left: 25%;\n }\n .offset-lg-4 {\n margin-left: 33.333333%;\n }\n .offset-lg-5 {\n margin-left: 41.666667%;\n }\n .offset-lg-6 {\n margin-left: 50%;\n }\n .offset-lg-7 {\n margin-left: 58.333333%;\n }\n .offset-lg-8 {\n margin-left: 66.666667%;\n }\n .offset-lg-9 {\n margin-left: 75%;\n }\n .offset-lg-10 {\n margin-left: 83.333333%;\n }\n .offset-lg-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 1200px) {\n .col-xl {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-xl-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-xl-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-xl-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-xl-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-xl-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-xl-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-xl-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-xl-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-xl-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-xl-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-xl-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-xl-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-xl-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-xl-0 {\n right: auto;\n }\n .pull-xl-1 {\n right: 8.333333%;\n }\n .pull-xl-2 {\n right: 16.666667%;\n }\n .pull-xl-3 {\n right: 25%;\n }\n .pull-xl-4 {\n right: 33.333333%;\n }\n .pull-xl-5 {\n right: 41.666667%;\n }\n .pull-xl-6 {\n right: 50%;\n }\n .pull-xl-7 {\n right: 58.333333%;\n }\n .pull-xl-8 {\n right: 66.666667%;\n }\n .pull-xl-9 {\n right: 75%;\n }\n .pull-xl-10 {\n right: 83.333333%;\n }\n .pull-xl-11 {\n right: 91.666667%;\n }\n .pull-xl-12 {\n right: 100%;\n }\n .push-xl-0 {\n left: auto;\n }\n .push-xl-1 {\n left: 8.333333%;\n }\n .push-xl-2 {\n left: 16.666667%;\n }\n .push-xl-3 {\n left: 25%;\n }\n .push-xl-4 {\n left: 33.333333%;\n }\n .push-xl-5 {\n left: 41.666667%;\n }\n .push-xl-6 {\n left: 50%;\n }\n .push-xl-7 {\n left: 58.333333%;\n }\n .push-xl-8 {\n left: 66.666667%;\n }\n .push-xl-9 {\n left: 75%;\n }\n .push-xl-10 {\n left: 83.333333%;\n }\n .push-xl-11 {\n left: 91.666667%;\n }\n .push-xl-12 {\n left: 100%;\n }\n .offset-xl-0 {\n margin-left: 0%;\n }\n .offset-xl-1 {\n margin-left: 8.333333%;\n }\n .offset-xl-2 {\n margin-left: 16.666667%;\n }\n .offset-xl-3 {\n margin-left: 25%;\n }\n .offset-xl-4 {\n margin-left: 33.333333%;\n }\n .offset-xl-5 {\n margin-left: 41.666667%;\n }\n .offset-xl-6 {\n margin-left: 50%;\n }\n .offset-xl-7 {\n margin-left: 58.333333%;\n }\n .offset-xl-8 {\n margin-left: 66.666667%;\n }\n .offset-xl-9 {\n margin-left: 75%;\n }\n .offset-xl-10 {\n margin-left: 83.333333%;\n }\n .offset-xl-11 {\n margin-left: 91.666667%;\n }\n}\n\n.table {\n width: 100%;\n max-width: 100%;\n margin-bottom: 1rem;\n}\n\n.table th,\n.table td {\n padding: 0.75rem;\n vertical-align: top;\n border-top: 1px solid #eceeef;\n}\n\n.table thead th {\n vertical-align: bottom;\n border-bottom: 2px solid #eceeef;\n}\n\n.table tbody + tbody {\n border-top: 2px solid #eceeef;\n}\n\n.table .table {\n background-color: #fff;\n}\n\n.table-sm th,\n.table-sm td {\n padding: 0.3rem;\n}\n\n.table-bordered {\n border: 1px solid #eceeef;\n}\n\n.table-bordered th,\n.table-bordered td {\n border: 1px solid #eceeef;\n}\n\n.table-bordered thead th,\n.table-bordered thead td {\n border-bottom-width: 2px;\n}\n\n.table-striped tbody tr:nth-of-type(odd) {\n background-color: rgba(0, 0, 0, 0.05);\n}\n\n.table-hover tbody tr:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-active,\n.table-active > th,\n.table-active > td {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover > td,\n.table-hover .table-active:hover > th {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-success,\n.table-success > th,\n.table-success > td {\n background-color: #dff0d8;\n}\n\n.table-hover .table-success:hover {\n background-color: #d0e9c6;\n}\n\n.table-hover .table-success:hover > td,\n.table-hover .table-success:hover > th {\n background-color: #d0e9c6;\n}\n\n.table-info,\n.table-info > th,\n.table-info > td {\n background-color: #d9edf7;\n}\n\n.table-hover .table-info:hover {\n background-color: #c4e3f3;\n}\n\n.table-hover .table-info:hover > td,\n.table-hover .table-info:hover > th {\n background-color: #c4e3f3;\n}\n\n.table-warning,\n.table-warning > th,\n.table-warning > td {\n background-color: #fcf8e3;\n}\n\n.table-hover .table-warning:hover {\n background-color: #faf2cc;\n}\n\n.table-hover .table-warning:hover > td,\n.table-hover .table-warning:hover > th {\n background-color: #faf2cc;\n}\n\n.table-danger,\n.table-danger > th,\n.table-danger > td {\n background-color: #f2dede;\n}\n\n.table-hover .table-danger:hover {\n background-color: #ebcccc;\n}\n\n.table-hover .table-danger:hover > td,\n.table-hover .table-danger:hover > th {\n background-color: #ebcccc;\n}\n\n.thead-inverse th {\n color: #fff;\n background-color: #292b2c;\n}\n\n.thead-default th {\n color: #464a4c;\n background-color: #eceeef;\n}\n\n.table-inverse {\n color: #fff;\n background-color: #292b2c;\n}\n\n.table-inverse th,\n.table-inverse td,\n.table-inverse thead th {\n border-color: #fff;\n}\n\n.table-inverse.table-bordered {\n border: 0;\n}\n\n.table-responsive {\n display: block;\n width: 100%;\n overflow-x: auto;\n -ms-overflow-style: -ms-autohiding-scrollbar;\n}\n\n.table-responsive.table-bordered {\n border: 0;\n}\n\n.form-control {\n display: block;\n width: 100%;\n padding: 0.5rem 0.75rem;\n font-size: 1rem;\n line-height: 1.25;\n color: #464a4c;\n background-color: #fff;\n background-image: none;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -webkit-transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n -o-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n}\n\n.form-control::-ms-expand {\n background-color: transparent;\n border: 0;\n}\n\n.form-control:focus {\n color: #464a4c;\n background-color: #fff;\n border-color: #5cb3fd;\n outline: none;\n}\n\n.form-control::-webkit-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::-moz-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:-ms-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:disabled, .form-control[readonly] {\n background-color: #eceeef;\n opacity: 1;\n}\n\n.form-control:disabled {\n cursor: not-allowed;\n}\n\nselect.form-control:not([size]):not([multiple]) {\n height: calc(2.25rem + 2px);\n}\n\nselect.form-control:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.form-control-file,\n.form-control-range {\n display: block;\n}\n\n.col-form-label {\n padding-top: calc(0.5rem - 1px * 2);\n padding-bottom: calc(0.5rem - 1px * 2);\n margin-bottom: 0;\n}\n\n.col-form-label-lg {\n padding-top: calc(0.75rem - 1px * 2);\n padding-bottom: calc(0.75rem - 1px * 2);\n font-size: 1.25rem;\n}\n\n.col-form-label-sm {\n padding-top: calc(0.25rem - 1px * 2);\n padding-bottom: calc(0.25rem - 1px * 2);\n font-size: 0.875rem;\n}\n\n.col-form-legend {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n font-size: 1rem;\n}\n\n.form-control-static {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n line-height: 1.25;\n border: solid transparent;\n border-width: 1px 0;\n}\n\n.form-control-static.form-control-sm, .input-group-sm > .form-control-static.form-control,\n.input-group-sm > .form-control-static.input-group-addon,\n.input-group-sm > .input-group-btn > .form-control-static.btn, .form-control-static.form-control-lg, .input-group-lg > .form-control-static.form-control,\n.input-group-lg > .form-control-static.input-group-addon,\n.input-group-lg > .input-group-btn > .form-control-static.btn {\n padding-right: 0;\n padding-left: 0;\n}\n\n.form-control-sm, .input-group-sm > .form-control,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\nselect.form-control-sm:not([size]):not([multiple]), .input-group-sm > select.form-control:not([size]):not([multiple]),\n.input-group-sm > select.input-group-addon:not([size]):not([multiple]),\n.input-group-sm > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 1.8125rem;\n}\n\n.form-control-lg, .input-group-lg > .form-control,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\nselect.form-control-lg:not([size]):not([multiple]), .input-group-lg > select.form-control:not([size]):not([multiple]),\n.input-group-lg > select.input-group-addon:not([size]):not([multiple]),\n.input-group-lg > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 3.166667rem;\n}\n\n.form-group {\n margin-bottom: 1rem;\n}\n\n.form-text {\n display: block;\n margin-top: 0.25rem;\n}\n\n.form-check {\n position: relative;\n display: block;\n margin-bottom: 0.5rem;\n}\n\n.form-check.disabled .form-check-label {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.form-check-label {\n padding-left: 1.25rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.form-check-input {\n position: absolute;\n margin-top: 0.25rem;\n margin-left: -1.25rem;\n}\n\n.form-check-input:only-child {\n position: static;\n}\n\n.form-check-inline {\n display: inline-block;\n}\n\n.form-check-inline .form-check-label {\n vertical-align: middle;\n}\n\n.form-check-inline + .form-check-inline {\n margin-left: 0.75rem;\n}\n\n.form-control-feedback {\n margin-top: 0.25rem;\n}\n\n.form-control-success,\n.form-control-warning,\n.form-control-danger {\n padding-right: 2.25rem;\n background-repeat: no-repeat;\n background-position: center right 0.5625rem;\n -webkit-background-size: 1.125rem 1.125rem;\n background-size: 1.125rem 1.125rem;\n}\n\n.has-success .form-control-feedback,\n.has-success .form-control-label,\n.has-success .col-form-label,\n.has-success .form-check-label,\n.has-success .custom-control {\n color: #5cb85c;\n}\n\n.has-success .form-control {\n border-color: #5cb85c;\n}\n\n.has-success .input-group-addon {\n color: #5cb85c;\n border-color: #5cb85c;\n background-color: #eaf6ea;\n}\n\n.has-success .form-control-success {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%235cb85c' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3E%3C/svg%3E\");\n}\n\n.has-warning .form-control-feedback,\n.has-warning .form-control-label,\n.has-warning .col-form-label,\n.has-warning .form-check-label,\n.has-warning .custom-control {\n color: #f0ad4e;\n}\n\n.has-warning .form-control {\n border-color: #f0ad4e;\n}\n\n.has-warning .input-group-addon {\n color: #f0ad4e;\n border-color: #f0ad4e;\n background-color: white;\n}\n\n.has-warning .form-control-warning {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23f0ad4e' d='M4.4 5.324h-.8v-2.46h.8zm0 1.42h-.8V5.89h.8zM3.76.63L.04 7.075c-.115.2.016.425.26.426h7.397c.242 0 .372-.226.258-.426C6.726 4.924 5.47 2.79 4.253.63c-.113-.174-.39-.174-.494 0z'/%3E%3C/svg%3E\");\n}\n\n.has-danger .form-control-feedback,\n.has-danger .form-control-label,\n.has-danger .col-form-label,\n.has-danger .form-check-label,\n.has-danger .custom-control {\n color: #d9534f;\n}\n\n.has-danger .form-control {\n border-color: #d9534f;\n}\n\n.has-danger .input-group-addon {\n color: #d9534f;\n border-color: #d9534f;\n background-color: #fdf7f7;\n}\n\n.has-danger .form-control-danger {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23d9534f' viewBox='-2 -2 7 7'%3E%3Cpath stroke='%23d9534f' d='M0 0l3 3m0-3L0 3'/%3E%3Ccircle r='.5'/%3E%3Ccircle cx='3' r='.5'/%3E%3Ccircle cy='3' r='.5'/%3E%3Ccircle cx='3' cy='3' r='.5'/%3E%3C/svg%3E\");\n}\n\n.form-inline {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.form-inline .form-check {\n width: 100%;\n}\n\n@media (min-width: 576px) {\n .form-inline label {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n margin-bottom: 0;\n }\n .form-inline .form-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n margin-bottom: 0;\n }\n .form-inline .form-control {\n display: inline-block;\n width: auto;\n vertical-align: middle;\n }\n .form-inline .form-control-static {\n display: inline-block;\n }\n .form-inline .input-group {\n width: auto;\n }\n .form-inline .form-control-label {\n margin-bottom: 0;\n vertical-align: middle;\n }\n .form-inline .form-check {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: auto;\n margin-top: 0;\n margin-bottom: 0;\n }\n .form-inline .form-check-label {\n padding-left: 0;\n }\n .form-inline .form-check-input {\n position: relative;\n margin-top: 0;\n margin-right: 0.25rem;\n margin-left: 0;\n }\n .form-inline .custom-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n }\n .form-inline .custom-control-indicator {\n position: static;\n display: inline-block;\n margin-right: 0.25rem;\n vertical-align: text-bottom;\n }\n .form-inline .has-feedback .form-control-feedback {\n top: 0;\n }\n}\n\n.btn {\n display: inline-block;\n font-weight: normal;\n line-height: 1.25;\n text-align: center;\n white-space: nowrap;\n vertical-align: middle;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n border: 1px solid transparent;\n padding: 0.5rem 1rem;\n font-size: 1rem;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n}\n\n.btn:focus, .btn:hover {\n text-decoration: none;\n}\n\n.btn:focus, .btn.focus {\n outline: 0;\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n}\n\n.btn.disabled, .btn:disabled {\n cursor: not-allowed;\n opacity: .65;\n}\n\n.btn:active, .btn.active {\n background-image: none;\n}\n\na.btn.disabled,\nfieldset[disabled] a.btn {\n pointer-events: none;\n}\n\n.btn-primary {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:hover {\n color: #fff;\n background-color: #025aa5;\n border-color: #01549b;\n}\n\n.btn-primary:focus, .btn-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-primary.disabled, .btn-primary:disabled {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:active, .btn-primary.active,\n.show > .btn-primary.dropdown-toggle {\n color: #fff;\n background-color: #025aa5;\n background-image: none;\n border-color: #01549b;\n}\n\n.btn-secondary {\n color: #292b2c;\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:hover {\n color: #292b2c;\n background-color: #e6e6e6;\n border-color: #adadad;\n}\n\n.btn-secondary:focus, .btn-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-secondary.disabled, .btn-secondary:disabled {\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:active, .btn-secondary.active,\n.show > .btn-secondary.dropdown-toggle {\n color: #292b2c;\n background-color: #e6e6e6;\n background-image: none;\n border-color: #adadad;\n}\n\n.btn-info {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:hover {\n color: #fff;\n background-color: #31b0d5;\n border-color: #2aabd2;\n}\n\n.btn-info:focus, .btn-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-info.disabled, .btn-info:disabled {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:active, .btn-info.active,\n.show > .btn-info.dropdown-toggle {\n color: #fff;\n background-color: #31b0d5;\n background-image: none;\n border-color: #2aabd2;\n}\n\n.btn-success {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:hover {\n color: #fff;\n background-color: #449d44;\n border-color: #419641;\n}\n\n.btn-success:focus, .btn-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-success.disabled, .btn-success:disabled {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:active, .btn-success.active,\n.show > .btn-success.dropdown-toggle {\n color: #fff;\n background-color: #449d44;\n background-image: none;\n border-color: #419641;\n}\n\n.btn-warning {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:hover {\n color: #fff;\n background-color: #ec971f;\n border-color: #eb9316;\n}\n\n.btn-warning:focus, .btn-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-warning.disabled, .btn-warning:disabled {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:active, .btn-warning.active,\n.show > .btn-warning.dropdown-toggle {\n color: #fff;\n background-color: #ec971f;\n background-image: none;\n border-color: #eb9316;\n}\n\n.btn-danger {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:hover {\n color: #fff;\n background-color: #c9302c;\n border-color: #c12e2a;\n}\n\n.btn-danger:focus, .btn-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-danger.disabled, .btn-danger:disabled {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:active, .btn-danger.active,\n.show > .btn-danger.dropdown-toggle {\n color: #fff;\n background-color: #c9302c;\n background-image: none;\n border-color: #c12e2a;\n}\n\n.btn-outline-primary {\n color: #0275d8;\n background-image: none;\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:hover {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:focus, .btn-outline-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-outline-primary.disabled, .btn-outline-primary:disabled {\n color: #0275d8;\n background-color: transparent;\n}\n\n.btn-outline-primary:active, .btn-outline-primary.active,\n.show > .btn-outline-primary.dropdown-toggle {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-secondary {\n color: #ccc;\n background-image: none;\n background-color: transparent;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:hover {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:focus, .btn-outline-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-outline-secondary.disabled, .btn-outline-secondary:disabled {\n color: #ccc;\n background-color: transparent;\n}\n\n.btn-outline-secondary:active, .btn-outline-secondary.active,\n.show > .btn-outline-secondary.dropdown-toggle {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-info {\n color: #5bc0de;\n background-image: none;\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:hover {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:focus, .btn-outline-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-outline-info.disabled, .btn-outline-info:disabled {\n color: #5bc0de;\n background-color: transparent;\n}\n\n.btn-outline-info:active, .btn-outline-info.active,\n.show > .btn-outline-info.dropdown-toggle {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-success {\n color: #5cb85c;\n background-image: none;\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:hover {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:focus, .btn-outline-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-outline-success.disabled, .btn-outline-success:disabled {\n color: #5cb85c;\n background-color: transparent;\n}\n\n.btn-outline-success:active, .btn-outline-success.active,\n.show > .btn-outline-success.dropdown-toggle {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-warning {\n color: #f0ad4e;\n background-image: none;\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:hover {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:focus, .btn-outline-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-outline-warning.disabled, .btn-outline-warning:disabled {\n color: #f0ad4e;\n background-color: transparent;\n}\n\n.btn-outline-warning:active, .btn-outline-warning.active,\n.show > .btn-outline-warning.dropdown-toggle {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-danger {\n color: #d9534f;\n background-image: none;\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:hover {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:focus, .btn-outline-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-outline-danger.disabled, .btn-outline-danger:disabled {\n color: #d9534f;\n background-color: transparent;\n}\n\n.btn-outline-danger:active, .btn-outline-danger.active,\n.show > .btn-outline-danger.dropdown-toggle {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-link {\n font-weight: normal;\n color: #0275d8;\n border-radius: 0;\n}\n\n.btn-link, .btn-link:active, .btn-link.active, .btn-link:disabled {\n background-color: transparent;\n}\n\n.btn-link, .btn-link:focus, .btn-link:active {\n border-color: transparent;\n}\n\n.btn-link:hover {\n border-color: transparent;\n}\n\n.btn-link:focus, .btn-link:hover {\n color: #014c8c;\n text-decoration: underline;\n background-color: transparent;\n}\n\n.btn-link:disabled {\n color: #636c72;\n}\n\n.btn-link:disabled:focus, .btn-link:disabled:hover {\n text-decoration: none;\n}\n\n.btn-lg, .btn-group-lg > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.btn-sm, .btn-group-sm > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.btn-block {\n display: block;\n width: 100%;\n}\n\n.btn-block + .btn-block {\n margin-top: 0.5rem;\n}\n\ninput[type=\"submit\"].btn-block,\ninput[type=\"reset\"].btn-block,\ninput[type=\"button\"].btn-block {\n width: 100%;\n}\n\n.fade {\n opacity: 0;\n -webkit-transition: opacity 0.15s linear;\n -o-transition: opacity 0.15s linear;\n transition: opacity 0.15s linear;\n}\n\n.fade.show {\n opacity: 1;\n}\n\n.collapse {\n display: none;\n}\n\n.collapse.show {\n display: block;\n}\n\ntr.collapse.show {\n display: table-row;\n}\n\ntbody.collapse.show {\n display: table-row-group;\n}\n\n.collapsing {\n position: relative;\n height: 0;\n overflow: hidden;\n -webkit-transition: height 0.35s ease;\n -o-transition: height 0.35s ease;\n transition: height 0.35s ease;\n}\n\n.dropup,\n.dropdown {\n position: relative;\n}\n\n.dropdown-toggle::after {\n display: inline-block;\n width: 0;\n height: 0;\n margin-left: 0.3em;\n vertical-align: middle;\n content: \"\";\n border-top: 0.3em solid;\n border-right: 0.3em solid transparent;\n border-left: 0.3em solid transparent;\n}\n\n.dropdown-toggle:focus {\n outline: 0;\n}\n\n.dropup .dropdown-toggle::after {\n border-top: 0;\n border-bottom: 0.3em solid;\n}\n\n.dropdown-menu {\n position: absolute;\n top: 100%;\n left: 0;\n z-index: 1000;\n display: none;\n float: left;\n min-width: 10rem;\n padding: 0.5rem 0;\n margin: 0.125rem 0 0;\n font-size: 1rem;\n color: #292b2c;\n text-align: left;\n list-style: none;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.dropdown-divider {\n height: 1px;\n margin: 0.5rem 0;\n overflow: hidden;\n background-color: #eceeef;\n}\n\n.dropdown-item {\n display: block;\n width: 100%;\n padding: 3px 1.5rem;\n clear: both;\n font-weight: normal;\n color: #292b2c;\n text-align: inherit;\n white-space: nowrap;\n background: none;\n border: 0;\n}\n\n.dropdown-item:focus, .dropdown-item:hover {\n color: #1d1e1f;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.dropdown-item.active, .dropdown-item:active {\n color: #fff;\n text-decoration: none;\n background-color: #0275d8;\n}\n\n.dropdown-item.disabled, .dropdown-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: transparent;\n}\n\n.show > .dropdown-menu {\n display: block;\n}\n\n.show > a {\n outline: 0;\n}\n\n.dropdown-menu-right {\n right: 0;\n left: auto;\n}\n\n.dropdown-menu-left {\n right: auto;\n left: 0;\n}\n\n.dropdown-header {\n display: block;\n padding: 0.5rem 1.5rem;\n margin-bottom: 0;\n font-size: 0.875rem;\n color: #636c72;\n white-space: nowrap;\n}\n\n.dropdown-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 990;\n}\n\n.dropup .dropdown-menu {\n top: auto;\n bottom: 100%;\n margin-bottom: 0.125rem;\n}\n\n.btn-group,\n.btn-group-vertical {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n vertical-align: middle;\n}\n\n.btn-group > .btn,\n.btn-group-vertical > .btn {\n position: relative;\n -webkit-box-flex: 0;\n -webkit-flex: 0 1 auto;\n -ms-flex: 0 1 auto;\n flex: 0 1 auto;\n}\n\n.btn-group > .btn:hover,\n.btn-group-vertical > .btn:hover {\n z-index: 2;\n}\n\n.btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active,\n.btn-group-vertical > .btn:focus,\n.btn-group-vertical > .btn:active,\n.btn-group-vertical > .btn.active {\n z-index: 2;\n}\n\n.btn-group .btn + .btn,\n.btn-group .btn + .btn-group,\n.btn-group .btn-group + .btn,\n.btn-group .btn-group + .btn-group,\n.btn-group-vertical .btn + .btn,\n.btn-group-vertical .btn + .btn-group,\n.btn-group-vertical .btn-group + .btn,\n.btn-group-vertical .btn-group + .btn-group {\n margin-left: -1px;\n}\n\n.btn-toolbar {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: start;\n -webkit-justify-content: flex-start;\n -ms-flex-pack: start;\n justify-content: flex-start;\n}\n\n.btn-toolbar .input-group {\n width: auto;\n}\n\n.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {\n border-radius: 0;\n}\n\n.btn-group > .btn:first-child {\n margin-left: 0;\n}\n\n.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn:last-child:not(:first-child),\n.btn-group > .dropdown-toggle:not(:first-child) {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group > .btn-group {\n float: left;\n}\n\n.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group .dropdown-toggle:active,\n.btn-group.open .dropdown-toggle {\n outline: 0;\n}\n\n.btn + .dropdown-toggle-split {\n padding-right: 0.75rem;\n padding-left: 0.75rem;\n}\n\n.btn + .dropdown-toggle-split::after {\n margin-left: 0;\n}\n\n.btn-sm + .dropdown-toggle-split, .btn-group-sm > .btn + .dropdown-toggle-split {\n padding-right: 0.375rem;\n padding-left: 0.375rem;\n}\n\n.btn-lg + .dropdown-toggle-split, .btn-group-lg > .btn + .dropdown-toggle-split {\n padding-right: 1.125rem;\n padding-left: 1.125rem;\n}\n\n.btn-group-vertical {\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.btn-group-vertical .btn,\n.btn-group-vertical .btn-group {\n width: 100%;\n}\n\n.btn-group-vertical > .btn + .btn,\n.btn-group-vertical > .btn + .btn-group,\n.btn-group-vertical > .btn-group + .btn,\n.btn-group-vertical > .btn-group + .btn-group {\n margin-top: -1px;\n margin-left: 0;\n}\n\n.btn-group-vertical > .btn:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn:first-child:not(:last-child) {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn:last-child:not(:first-child) {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n[data-toggle=\"buttons\"] > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn input[type=\"checkbox\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"checkbox\"] {\n position: absolute;\n clip: rect(0, 0, 0, 0);\n pointer-events: none;\n}\n\n.input-group {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n width: 100%;\n}\n\n.input-group .form-control {\n position: relative;\n z-index: 2;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n width: 1%;\n margin-bottom: 0;\n}\n\n.input-group .form-control:focus, .input-group .form-control:active, .input-group .form-control:hover {\n z-index: 3;\n}\n\n.input-group-addon,\n.input-group-btn,\n.input-group .form-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.input-group-addon:not(:first-child):not(:last-child),\n.input-group-btn:not(:first-child):not(:last-child),\n.input-group .form-control:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.input-group-addon,\n.input-group-btn {\n white-space: nowrap;\n vertical-align: middle;\n}\n\n.input-group-addon {\n padding: 0.5rem 0.75rem;\n margin-bottom: 0;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.25;\n color: #464a4c;\n text-align: center;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.input-group-addon.form-control-sm,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .input-group-addon.btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.input-group-addon.form-control-lg,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .input-group-addon.btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.input-group-addon input[type=\"radio\"],\n.input-group-addon input[type=\"checkbox\"] {\n margin-top: 0;\n}\n\n.input-group .form-control:not(:last-child),\n.input-group-addon:not(:last-child),\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group > .btn,\n.input-group-btn:not(:last-child) > .dropdown-toggle,\n.input-group-btn:not(:first-child) > .btn:not(:last-child):not(.dropdown-toggle),\n.input-group-btn:not(:first-child) > .btn-group:not(:last-child) > .btn {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.input-group-addon:not(:last-child) {\n border-right: 0;\n}\n\n.input-group .form-control:not(:first-child),\n.input-group-addon:not(:first-child),\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group > .btn,\n.input-group-btn:not(:first-child) > .dropdown-toggle,\n.input-group-btn:not(:last-child) > .btn:not(:first-child),\n.input-group-btn:not(:last-child) > .btn-group:not(:first-child) > .btn {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.form-control + .input-group-addon:not(:first-child) {\n border-left: 0;\n}\n\n.input-group-btn {\n position: relative;\n font-size: 0;\n white-space: nowrap;\n}\n\n.input-group-btn > .btn {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.input-group-btn > .btn + .btn {\n margin-left: -1px;\n}\n\n.input-group-btn > .btn:focus, .input-group-btn > .btn:active, .input-group-btn > .btn:hover {\n z-index: 3;\n}\n\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group {\n margin-right: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group {\n z-index: 2;\n margin-left: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn:focus, .input-group-btn:not(:first-child) > .btn:active, .input-group-btn:not(:first-child) > .btn:hover,\n.input-group-btn:not(:first-child) > .btn-group:focus,\n.input-group-btn:not(:first-child) > .btn-group:active,\n.input-group-btn:not(:first-child) > .btn-group:hover {\n z-index: 3;\n}\n\n.custom-control {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n min-height: 1.5rem;\n padding-left: 1.5rem;\n margin-right: 1rem;\n cursor: pointer;\n}\n\n.custom-control-input {\n position: absolute;\n z-index: -1;\n opacity: 0;\n}\n\n.custom-control-input:checked ~ .custom-control-indicator {\n color: #fff;\n background-color: #0275d8;\n}\n\n.custom-control-input:focus ~ .custom-control-indicator {\n -webkit-box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n}\n\n.custom-control-input:active ~ .custom-control-indicator {\n color: #fff;\n background-color: #8fcafe;\n}\n\n.custom-control-input:disabled ~ .custom-control-indicator {\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-control-input:disabled ~ .custom-control-description {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.custom-control-indicator {\n position: absolute;\n top: 0.25rem;\n left: 0;\n display: block;\n width: 1rem;\n height: 1rem;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #ddd;\n background-repeat: no-repeat;\n background-position: center center;\n -webkit-background-size: 50% 50%;\n background-size: 50% 50%;\n}\n\n.custom-checkbox .custom-control-indicator {\n border-radius: 0.25rem;\n}\n\n.custom-checkbox .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26 2.974 7.25 8 2.193z'/%3E%3C/svg%3E\");\n}\n\n.custom-checkbox .custom-control-input:indeterminate ~ .custom-control-indicator {\n background-color: #0275d8;\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 4'%3E%3Cpath stroke='%23fff' d='M0 2h4'/%3E%3C/svg%3E\");\n}\n\n.custom-radio .custom-control-indicator {\n border-radius: 50%;\n}\n\n.custom-radio .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3E%3Ccircle r='3' fill='%23fff'/%3E%3C/svg%3E\");\n}\n\n.custom-controls-stacked {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n\n.custom-controls-stacked .custom-control {\n margin-bottom: 0.25rem;\n}\n\n.custom-controls-stacked .custom-control + .custom-control {\n margin-left: 0;\n}\n\n.custom-select {\n display: inline-block;\n max-width: 100%;\n height: calc(2.25rem + 2px);\n padding: 0.375rem 1.75rem 0.375rem 0.75rem;\n line-height: 1.25;\n color: #464a4c;\n vertical-align: middle;\n background: #fff url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23333' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E\") no-repeat right 0.75rem center;\n -webkit-background-size: 8px 10px;\n background-size: 8px 10px;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -moz-appearance: none;\n -webkit-appearance: none;\n}\n\n.custom-select:focus {\n border-color: #5cb3fd;\n outline: none;\n}\n\n.custom-select:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.custom-select:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-select::-ms-expand {\n opacity: 0;\n}\n\n.custom-select-sm {\n padding-top: 0.375rem;\n padding-bottom: 0.375rem;\n font-size: 75%;\n}\n\n.custom-file {\n position: relative;\n display: inline-block;\n max-width: 100%;\n height: 2.5rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.custom-file-input {\n min-width: 14rem;\n max-width: 100%;\n height: 2.5rem;\n margin: 0;\n filter: alpha(opacity=0);\n opacity: 0;\n}\n\n.custom-file-control {\n position: absolute;\n top: 0;\n right: 0;\n left: 0;\n z-index: 5;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.custom-file-control:lang(en)::after {\n content: \"Choose file...\";\n}\n\n.custom-file-control::before {\n position: absolute;\n top: -1px;\n right: -1px;\n bottom: -1px;\n z-index: 6;\n display: block;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0 0.25rem 0.25rem 0;\n}\n\n.custom-file-control:lang(en)::before {\n content: \"Browse\";\n}\n\n.nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.nav-link {\n display: block;\n padding: 0.5em 1em;\n}\n\n.nav-link:focus, .nav-link:hover {\n text-decoration: none;\n}\n\n.nav-link.disabled {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.nav-tabs {\n border-bottom: 1px solid #ddd;\n}\n\n.nav-tabs .nav-item {\n margin-bottom: -1px;\n}\n\n.nav-tabs .nav-link {\n border: 1px solid transparent;\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.nav-tabs .nav-link:focus, .nav-tabs .nav-link:hover {\n border-color: #eceeef #eceeef #ddd;\n}\n\n.nav-tabs .nav-link.disabled {\n color: #636c72;\n background-color: transparent;\n border-color: transparent;\n}\n\n.nav-tabs .nav-link.active,\n.nav-tabs .nav-item.show .nav-link {\n color: #464a4c;\n background-color: #fff;\n border-color: #ddd #ddd #fff;\n}\n\n.nav-tabs .dropdown-menu {\n margin-top: -1px;\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.nav-pills .nav-link {\n border-radius: 0.25rem;\n}\n\n.nav-pills .nav-link.active,\n.nav-pills .nav-item.show .nav-link {\n color: #fff;\n cursor: default;\n background-color: #0275d8;\n}\n\n.nav-fill .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n text-align: center;\n}\n\n.nav-justified .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 100%;\n -ms-flex: 1 1 100%;\n flex: 1 1 100%;\n text-align: center;\n}\n\n.tab-content > .tab-pane {\n display: none;\n}\n\n.tab-content > .active {\n display: block;\n}\n\n.navbar {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding: 0.5rem 1rem;\n}\n\n.navbar-brand {\n display: inline-block;\n padding-top: .25rem;\n padding-bottom: .25rem;\n margin-right: 1rem;\n font-size: 1.25rem;\n line-height: inherit;\n white-space: nowrap;\n}\n\n.navbar-brand:focus, .navbar-brand:hover {\n text-decoration: none;\n}\n\n.navbar-nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.navbar-nav .nav-link {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-text {\n display: inline-block;\n padding-top: .425rem;\n padding-bottom: .425rem;\n}\n\n.navbar-toggler {\n -webkit-align-self: flex-start;\n -ms-flex-item-align: start;\n align-self: flex-start;\n padding: 0.25rem 0.75rem;\n font-size: 1.25rem;\n line-height: 1;\n background: transparent;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.navbar-toggler:focus, .navbar-toggler:hover {\n text-decoration: none;\n}\n\n.navbar-toggler-icon {\n display: inline-block;\n width: 1.5em;\n height: 1.5em;\n vertical-align: middle;\n content: \"\";\n background: no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.navbar-toggler-left {\n position: absolute;\n left: 1rem;\n}\n\n.navbar-toggler-right {\n position: absolute;\n right: 1rem;\n}\n\n@media (max-width: 575px) {\n .navbar-toggleable .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 576px) {\n .navbar-toggleable {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 767px) {\n .navbar-toggleable-sm .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-sm > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 768px) {\n .navbar-toggleable-sm {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-sm .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-sm > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-sm .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 991px) {\n .navbar-toggleable-md .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-md > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 992px) {\n .navbar-toggleable-md {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-md .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-md > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-md .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 1199px) {\n .navbar-toggleable-lg .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-lg > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 1200px) {\n .navbar-toggleable-lg {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-lg .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-lg > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-lg .navbar-toggler {\n display: none;\n }\n}\n\n.navbar-toggleable-xl {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n}\n\n.navbar-toggleable-xl > .container {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-toggleable-xl .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n\n.navbar-toggleable-xl .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n}\n\n.navbar-toggleable-xl > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n}\n\n.navbar-toggleable-xl .navbar-toggler {\n display: none;\n}\n\n.navbar-light .navbar-brand,\n.navbar-light .navbar-toggler {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-brand:focus, .navbar-light .navbar-brand:hover,\n.navbar-light .navbar-toggler:focus,\n.navbar-light .navbar-toggler:hover {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-nav .nav-link {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-light .navbar-nav .nav-link:focus, .navbar-light .navbar-nav .nav-link:hover {\n color: rgba(0, 0, 0, 0.7);\n}\n\n.navbar-light .navbar-nav .nav-link.disabled {\n color: rgba(0, 0, 0, 0.3);\n}\n\n.navbar-light .navbar-nav .open > .nav-link,\n.navbar-light .navbar-nav .active > .nav-link,\n.navbar-light .navbar-nav .nav-link.open,\n.navbar-light .navbar-nav .nav-link.active {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-toggler {\n border-color: rgba(0, 0, 0, 0.1);\n}\n\n.navbar-light .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(0, 0, 0, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-light .navbar-text {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-inverse .navbar-brand,\n.navbar-inverse .navbar-toggler {\n color: white;\n}\n\n.navbar-inverse .navbar-brand:focus, .navbar-inverse .navbar-brand:hover,\n.navbar-inverse .navbar-toggler:focus,\n.navbar-inverse .navbar-toggler:hover {\n color: white;\n}\n\n.navbar-inverse .navbar-nav .nav-link {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.navbar-inverse .navbar-nav .nav-link:focus, .navbar-inverse .navbar-nav .nav-link:hover {\n color: rgba(255, 255, 255, 0.75);\n}\n\n.navbar-inverse .navbar-nav .nav-link.disabled {\n color: rgba(255, 255, 255, 0.25);\n}\n\n.navbar-inverse .navbar-nav .open > .nav-link,\n.navbar-inverse .navbar-nav .active > .nav-link,\n.navbar-inverse .navbar-nav .nav-link.open,\n.navbar-inverse .navbar-nav .nav-link.active {\n color: white;\n}\n\n.navbar-inverse .navbar-toggler {\n border-color: rgba(255, 255, 255, 0.1);\n}\n\n.navbar-inverse .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255, 255, 255, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-inverse .navbar-text {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.card {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n border-radius: 0.25rem;\n}\n\n.card-block {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 1.25rem;\n}\n\n.card-title {\n margin-bottom: 0.75rem;\n}\n\n.card-subtitle {\n margin-top: -0.375rem;\n margin-bottom: 0;\n}\n\n.card-text:last-child {\n margin-bottom: 0;\n}\n\n.card-link:hover {\n text-decoration: none;\n}\n\n.card-link + .card-link {\n margin-left: 1.25rem;\n}\n\n.card > .list-group:first-child .list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.card > .list-group:last-child .list-group-item:last-child {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.card-header {\n padding: 0.75rem 1.25rem;\n margin-bottom: 0;\n background-color: #f7f7f9;\n border-bottom: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-header:first-child {\n border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;\n}\n\n.card-footer {\n padding: 0.75rem 1.25rem;\n background-color: #f7f7f9;\n border-top: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-footer:last-child {\n border-radius: 0 0 calc(0.25rem - 1px) calc(0.25rem - 1px);\n}\n\n.card-header-tabs {\n margin-right: -0.625rem;\n margin-bottom: -0.75rem;\n margin-left: -0.625rem;\n border-bottom: 0;\n}\n\n.card-header-pills {\n margin-right: -0.625rem;\n margin-left: -0.625rem;\n}\n\n.card-primary {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.card-primary .card-header,\n.card-primary .card-footer {\n background-color: transparent;\n}\n\n.card-success {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.card-success .card-header,\n.card-success .card-footer {\n background-color: transparent;\n}\n\n.card-info {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.card-info .card-header,\n.card-info .card-footer {\n background-color: transparent;\n}\n\n.card-warning {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.card-warning .card-header,\n.card-warning .card-footer {\n background-color: transparent;\n}\n\n.card-danger {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.card-danger .card-header,\n.card-danger .card-footer {\n background-color: transparent;\n}\n\n.card-outline-primary {\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.card-outline-secondary {\n background-color: transparent;\n border-color: #ccc;\n}\n\n.card-outline-info {\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.card-outline-success {\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.card-outline-warning {\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.card-outline-danger {\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.card-inverse {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer {\n background-color: transparent;\n border-color: rgba(255, 255, 255, 0.2);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer,\n.card-inverse .card-title,\n.card-inverse .card-blockquote {\n color: #fff;\n}\n\n.card-inverse .card-link,\n.card-inverse .card-text,\n.card-inverse .card-subtitle,\n.card-inverse .card-blockquote .blockquote-footer {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-link:focus, .card-inverse .card-link:hover {\n color: #fff;\n}\n\n.card-blockquote {\n padding: 0;\n margin-bottom: 0;\n border-left: 0;\n}\n\n.card-img {\n border-radius: calc(0.25rem - 1px);\n}\n\n.card-img-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n padding: 1.25rem;\n}\n\n.card-img-top {\n border-top-right-radius: calc(0.25rem - 1px);\n border-top-left-radius: calc(0.25rem - 1px);\n}\n\n.card-img-bottom {\n border-bottom-right-radius: calc(0.25rem - 1px);\n border-bottom-left-radius: calc(0.25rem - 1px);\n}\n\n@media (min-width: 576px) {\n .card-deck {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-deck .card {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n }\n .card-deck .card:not(:first-child) {\n margin-left: 15px;\n }\n .card-deck .card:not(:last-child) {\n margin-right: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .card-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-group .card {\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n }\n .card-group .card + .card {\n margin-left: 0;\n border-left: 0;\n }\n .card-group .card:first-child {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-top {\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-bottom {\n border-bottom-right-radius: 0;\n }\n .card-group .card:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-top {\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-bottom {\n border-bottom-left-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) {\n border-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) .card-img-top,\n .card-group .card:not(:first-child):not(:last-child) .card-img-bottom {\n border-radius: 0;\n }\n}\n\n@media (min-width: 576px) {\n .card-columns {\n -webkit-column-count: 3;\n -moz-column-count: 3;\n column-count: 3;\n -webkit-column-gap: 1.25rem;\n -moz-column-gap: 1.25rem;\n column-gap: 1.25rem;\n }\n .card-columns .card {\n display: inline-block;\n width: 100%;\n margin-bottom: 0.75rem;\n }\n}\n\n.breadcrumb {\n padding: 0.75rem 1rem;\n margin-bottom: 1rem;\n list-style: none;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.breadcrumb::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.breadcrumb-item {\n float: left;\n}\n\n.breadcrumb-item + .breadcrumb-item::before {\n display: inline-block;\n padding-right: 0.5rem;\n padding-left: 0.5rem;\n color: #636c72;\n content: \"/\";\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: underline;\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: none;\n}\n\n.breadcrumb-item.active {\n color: #636c72;\n}\n\n.pagination {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n list-style: none;\n border-radius: 0.25rem;\n}\n\n.page-item:first-child .page-link {\n margin-left: 0;\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.page-item:last-child .page-link {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.page-item.active .page-link {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.page-item.disabled .page-link {\n color: #636c72;\n pointer-events: none;\n cursor: not-allowed;\n background-color: #fff;\n border-color: #ddd;\n}\n\n.page-link {\n position: relative;\n display: block;\n padding: 0.5rem 0.75rem;\n margin-left: -1px;\n line-height: 1.25;\n color: #0275d8;\n background-color: #fff;\n border: 1px solid #ddd;\n}\n\n.page-link:focus, .page-link:hover {\n color: #014c8c;\n text-decoration: none;\n background-color: #eceeef;\n border-color: #ddd;\n}\n\n.pagination-lg .page-link {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n}\n\n.pagination-lg .page-item:first-child .page-link {\n border-bottom-left-radius: 0.3rem;\n border-top-left-radius: 0.3rem;\n}\n\n.pagination-lg .page-item:last-child .page-link {\n border-bottom-right-radius: 0.3rem;\n border-top-right-radius: 0.3rem;\n}\n\n.pagination-sm .page-link {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n}\n\n.pagination-sm .page-item:first-child .page-link {\n border-bottom-left-radius: 0.2rem;\n border-top-left-radius: 0.2rem;\n}\n\n.pagination-sm .page-item:last-child .page-link {\n border-bottom-right-radius: 0.2rem;\n border-top-right-radius: 0.2rem;\n}\n\n.badge {\n display: inline-block;\n padding: 0.25em 0.4em;\n font-size: 75%;\n font-weight: bold;\n line-height: 1;\n color: #fff;\n text-align: center;\n white-space: nowrap;\n vertical-align: baseline;\n border-radius: 0.25rem;\n}\n\n.badge:empty {\n display: none;\n}\n\n.btn .badge {\n position: relative;\n top: -1px;\n}\n\na.badge:focus, a.badge:hover {\n color: #fff;\n text-decoration: none;\n cursor: pointer;\n}\n\n.badge-pill {\n padding-right: 0.6em;\n padding-left: 0.6em;\n border-radius: 10rem;\n}\n\n.badge-default {\n background-color: #636c72;\n}\n\n.badge-default[href]:focus, .badge-default[href]:hover {\n background-color: #4b5257;\n}\n\n.badge-primary {\n background-color: #0275d8;\n}\n\n.badge-primary[href]:focus, .badge-primary[href]:hover {\n background-color: #025aa5;\n}\n\n.badge-success {\n background-color: #5cb85c;\n}\n\n.badge-success[href]:focus, .badge-success[href]:hover {\n background-color: #449d44;\n}\n\n.badge-info {\n background-color: #5bc0de;\n}\n\n.badge-info[href]:focus, .badge-info[href]:hover {\n background-color: #31b0d5;\n}\n\n.badge-warning {\n background-color: #f0ad4e;\n}\n\n.badge-warning[href]:focus, .badge-warning[href]:hover {\n background-color: #ec971f;\n}\n\n.badge-danger {\n background-color: #d9534f;\n}\n\n.badge-danger[href]:focus, .badge-danger[href]:hover {\n background-color: #c9302c;\n}\n\n.jumbotron {\n padding: 2rem 1rem;\n margin-bottom: 2rem;\n background-color: #eceeef;\n border-radius: 0.3rem;\n}\n\n@media (min-width: 576px) {\n .jumbotron {\n padding: 4rem 2rem;\n }\n}\n\n.jumbotron-hr {\n border-top-color: #d0d5d8;\n}\n\n.jumbotron-fluid {\n padding-right: 0;\n padding-left: 0;\n border-radius: 0;\n}\n\n.alert {\n padding: 0.75rem 1.25rem;\n margin-bottom: 1rem;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.alert-heading {\n color: inherit;\n}\n\n.alert-link {\n font-weight: bold;\n}\n\n.alert-dismissible .close {\n position: relative;\n top: -0.75rem;\n right: -1.25rem;\n padding: 0.75rem 1.25rem;\n color: inherit;\n}\n\n.alert-success {\n background-color: #dff0d8;\n border-color: #d0e9c6;\n color: #3c763d;\n}\n\n.alert-success hr {\n border-top-color: #c1e2b3;\n}\n\n.alert-success .alert-link {\n color: #2b542c;\n}\n\n.alert-info {\n background-color: #d9edf7;\n border-color: #bcdff1;\n color: #31708f;\n}\n\n.alert-info hr {\n border-top-color: #a6d5ec;\n}\n\n.alert-info .alert-link {\n color: #245269;\n}\n\n.alert-warning {\n background-color: #fcf8e3;\n border-color: #faf2cc;\n color: #8a6d3b;\n}\n\n.alert-warning hr {\n border-top-color: #f7ecb5;\n}\n\n.alert-warning .alert-link {\n color: #66512c;\n}\n\n.alert-danger {\n background-color: #f2dede;\n border-color: #ebcccc;\n color: #a94442;\n}\n\n.alert-danger hr {\n border-top-color: #e4b9b9;\n}\n\n.alert-danger .alert-link {\n color: #843534;\n}\n\n@-webkit-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@-o-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n.progress {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n overflow: hidden;\n font-size: 0.75rem;\n line-height: 1rem;\n text-align: center;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.progress-bar {\n height: 1rem;\n color: #fff;\n background-color: #0275d8;\n}\n\n.progress-bar-striped {\n background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n -webkit-background-size: 1rem 1rem;\n background-size: 1rem 1rem;\n}\n\n.progress-bar-animated {\n -webkit-animation: progress-bar-stripes 1s linear infinite;\n -o-animation: progress-bar-stripes 1s linear infinite;\n animation: progress-bar-stripes 1s linear infinite;\n}\n\n.media {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n}\n\n.media-body {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.list-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n}\n\n.list-group-item-action {\n width: 100%;\n color: #464a4c;\n text-align: inherit;\n}\n\n.list-group-item-action .list-group-item-heading {\n color: #292b2c;\n}\n\n.list-group-item-action:focus, .list-group-item-action:hover {\n color: #464a4c;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.list-group-item-action:active {\n color: #292b2c;\n background-color: #eceeef;\n}\n\n.list-group-item {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n padding: 0.75rem 1.25rem;\n margin-bottom: -1px;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.list-group-item:last-child {\n margin-bottom: 0;\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.list-group-item:focus, .list-group-item:hover {\n text-decoration: none;\n}\n\n.list-group-item.disabled, .list-group-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #fff;\n}\n\n.list-group-item.disabled .list-group-item-heading, .list-group-item:disabled .list-group-item-heading {\n color: inherit;\n}\n\n.list-group-item.disabled .list-group-item-text, .list-group-item:disabled .list-group-item-text {\n color: #636c72;\n}\n\n.list-group-item.active {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.list-group-item.active .list-group-item-heading,\n.list-group-item.active .list-group-item-heading > small,\n.list-group-item.active .list-group-item-heading > .small {\n color: inherit;\n}\n\n.list-group-item.active .list-group-item-text {\n color: #daeeff;\n}\n\n.list-group-flush .list-group-item {\n border-right: 0;\n border-left: 0;\n border-radius: 0;\n}\n\n.list-group-flush:first-child .list-group-item:first-child {\n border-top: 0;\n}\n\n.list-group-flush:last-child .list-group-item:last-child {\n border-bottom: 0;\n}\n\n.list-group-item-success {\n color: #3c763d;\n background-color: #dff0d8;\n}\n\na.list-group-item-success,\nbutton.list-group-item-success {\n color: #3c763d;\n}\n\na.list-group-item-success .list-group-item-heading,\nbutton.list-group-item-success .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-success:focus, a.list-group-item-success:hover,\nbutton.list-group-item-success:focus,\nbutton.list-group-item-success:hover {\n color: #3c763d;\n background-color: #d0e9c6;\n}\n\na.list-group-item-success.active,\nbutton.list-group-item-success.active {\n color: #fff;\n background-color: #3c763d;\n border-color: #3c763d;\n}\n\n.list-group-item-info {\n color: #31708f;\n background-color: #d9edf7;\n}\n\na.list-group-item-info,\nbutton.list-group-item-info {\n color: #31708f;\n}\n\na.list-group-item-info .list-group-item-heading,\nbutton.list-group-item-info .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-info:focus, a.list-group-item-info:hover,\nbutton.list-group-item-info:focus,\nbutton.list-group-item-info:hover {\n color: #31708f;\n background-color: #c4e3f3;\n}\n\na.list-group-item-info.active,\nbutton.list-group-item-info.active {\n color: #fff;\n background-color: #31708f;\n border-color: #31708f;\n}\n\n.list-group-item-warning {\n color: #8a6d3b;\n background-color: #fcf8e3;\n}\n\na.list-group-item-warning,\nbutton.list-group-item-warning {\n color: #8a6d3b;\n}\n\na.list-group-item-warning .list-group-item-heading,\nbutton.list-group-item-warning .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-warning:focus, a.list-group-item-warning:hover,\nbutton.list-group-item-warning:focus,\nbutton.list-group-item-warning:hover {\n color: #8a6d3b;\n background-color: #faf2cc;\n}\n\na.list-group-item-warning.active,\nbutton.list-group-item-warning.active {\n color: #fff;\n background-color: #8a6d3b;\n border-color: #8a6d3b;\n}\n\n.list-group-item-danger {\n color: #a94442;\n background-color: #f2dede;\n}\n\na.list-group-item-danger,\nbutton.list-group-item-danger {\n color: #a94442;\n}\n\na.list-group-item-danger .list-group-item-heading,\nbutton.list-group-item-danger .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-danger:focus, a.list-group-item-danger:hover,\nbutton.list-group-item-danger:focus,\nbutton.list-group-item-danger:hover {\n color: #a94442;\n background-color: #ebcccc;\n}\n\na.list-group-item-danger.active,\nbutton.list-group-item-danger.active {\n color: #fff;\n background-color: #a94442;\n border-color: #a94442;\n}\n\n.embed-responsive {\n position: relative;\n display: block;\n width: 100%;\n padding: 0;\n overflow: hidden;\n}\n\n.embed-responsive::before {\n display: block;\n content: \"\";\n}\n\n.embed-responsive .embed-responsive-item,\n.embed-responsive iframe,\n.embed-responsive embed,\n.embed-responsive object,\n.embed-responsive video {\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 100%;\n border: 0;\n}\n\n.embed-responsive-21by9::before {\n padding-top: 42.857143%;\n}\n\n.embed-responsive-16by9::before {\n padding-top: 56.25%;\n}\n\n.embed-responsive-4by3::before {\n padding-top: 75%;\n}\n\n.embed-responsive-1by1::before {\n padding-top: 100%;\n}\n\n.close {\n float: right;\n font-size: 1.5rem;\n font-weight: bold;\n line-height: 1;\n color: #000;\n text-shadow: 0 1px 0 #fff;\n opacity: .5;\n}\n\n.close:focus, .close:hover {\n color: #000;\n text-decoration: none;\n cursor: pointer;\n opacity: .75;\n}\n\nbutton.close {\n padding: 0;\n cursor: pointer;\n background: transparent;\n border: 0;\n -webkit-appearance: none;\n}\n\n.modal-open {\n overflow: hidden;\n}\n\n.modal {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1050;\n display: none;\n overflow: hidden;\n outline: 0;\n}\n\n.modal.fade .modal-dialog {\n -webkit-transition: -webkit-transform 0.3s ease-out;\n transition: -webkit-transform 0.3s ease-out;\n -o-transition: -o-transform 0.3s ease-out;\n transition: transform 0.3s ease-out;\n transition: transform 0.3s ease-out, -webkit-transform 0.3s ease-out, -o-transform 0.3s ease-out;\n -webkit-transform: translate(0, -25%);\n -o-transform: translate(0, -25%);\n transform: translate(0, -25%);\n}\n\n.modal.show .modal-dialog {\n -webkit-transform: translate(0, 0);\n -o-transform: translate(0, 0);\n transform: translate(0, 0);\n}\n\n.modal-open .modal {\n overflow-x: hidden;\n overflow-y: auto;\n}\n\n.modal-dialog {\n position: relative;\n width: auto;\n margin: 10px;\n}\n\n.modal-content {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n outline: 0;\n}\n\n.modal-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1040;\n background-color: #000;\n}\n\n.modal-backdrop.fade {\n opacity: 0;\n}\n\n.modal-backdrop.show {\n opacity: 0.5;\n}\n\n.modal-header {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n padding: 15px;\n border-bottom: 1px solid #eceeef;\n}\n\n.modal-title {\n margin-bottom: 0;\n line-height: 1.5;\n}\n\n.modal-body {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 15px;\n}\n\n.modal-footer {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: end;\n -webkit-justify-content: flex-end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n padding: 15px;\n border-top: 1px solid #eceeef;\n}\n\n.modal-footer > :not(:first-child) {\n margin-left: .25rem;\n}\n\n.modal-footer > :not(:last-child) {\n margin-right: .25rem;\n}\n\n.modal-scrollbar-measure {\n position: absolute;\n top: -9999px;\n width: 50px;\n height: 50px;\n overflow: scroll;\n}\n\n@media (min-width: 576px) {\n .modal-dialog {\n max-width: 500px;\n margin: 30px auto;\n }\n .modal-sm {\n max-width: 300px;\n }\n}\n\n@media (min-width: 992px) {\n .modal-lg {\n max-width: 800px;\n }\n}\n\n.tooltip {\n position: absolute;\n z-index: 1070;\n display: block;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n opacity: 0;\n}\n\n.tooltip.show {\n opacity: 0.9;\n}\n\n.tooltip.tooltip-top, .tooltip.bs-tether-element-attached-bottom {\n padding: 5px 0;\n margin-top: -3px;\n}\n\n.tooltip.tooltip-top .tooltip-inner::before, .tooltip.bs-tether-element-attached-bottom .tooltip-inner::before {\n bottom: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 5px 5px 0;\n border-top-color: #000;\n}\n\n.tooltip.tooltip-right, .tooltip.bs-tether-element-attached-left {\n padding: 0 5px;\n margin-left: 3px;\n}\n\n.tooltip.tooltip-right .tooltip-inner::before, .tooltip.bs-tether-element-attached-left .tooltip-inner::before {\n top: 50%;\n left: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 5px 5px 0;\n border-right-color: #000;\n}\n\n.tooltip.tooltip-bottom, .tooltip.bs-tether-element-attached-top {\n padding: 5px 0;\n margin-top: 3px;\n}\n\n.tooltip.tooltip-bottom .tooltip-inner::before, .tooltip.bs-tether-element-attached-top .tooltip-inner::before {\n top: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 0 5px 5px;\n border-bottom-color: #000;\n}\n\n.tooltip.tooltip-left, .tooltip.bs-tether-element-attached-right {\n padding: 0 5px;\n margin-left: -3px;\n}\n\n.tooltip.tooltip-left .tooltip-inner::before, .tooltip.bs-tether-element-attached-right .tooltip-inner::before {\n top: 50%;\n right: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 0 5px 5px;\n border-left-color: #000;\n}\n\n.tooltip-inner {\n max-width: 200px;\n padding: 3px 8px;\n color: #fff;\n text-align: center;\n background-color: #000;\n border-radius: 0.25rem;\n}\n\n.tooltip-inner::before {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1060;\n display: block;\n max-width: 276px;\n padding: 1px;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n}\n\n.popover.popover-top, .popover.bs-tether-element-attached-bottom {\n margin-top: -10px;\n}\n\n.popover.popover-top::before, .popover.popover-top::after, .popover.bs-tether-element-attached-bottom::before, .popover.bs-tether-element-attached-bottom::after {\n left: 50%;\n border-bottom-width: 0;\n}\n\n.popover.popover-top::before, .popover.bs-tether-element-attached-bottom::before {\n bottom: -11px;\n margin-left: -11px;\n border-top-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-top::after, .popover.bs-tether-element-attached-bottom::after {\n bottom: -10px;\n margin-left: -10px;\n border-top-color: #fff;\n}\n\n.popover.popover-right, .popover.bs-tether-element-attached-left {\n margin-left: 10px;\n}\n\n.popover.popover-right::before, .popover.popover-right::after, .popover.bs-tether-element-attached-left::before, .popover.bs-tether-element-attached-left::after {\n top: 50%;\n border-left-width: 0;\n}\n\n.popover.popover-right::before, .popover.bs-tether-element-attached-left::before {\n left: -11px;\n margin-top: -11px;\n border-right-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-right::after, .popover.bs-tether-element-attached-left::after {\n left: -10px;\n margin-top: -10px;\n border-right-color: #fff;\n}\n\n.popover.popover-bottom, .popover.bs-tether-element-attached-top {\n margin-top: 10px;\n}\n\n.popover.popover-bottom::before, .popover.popover-bottom::after, .popover.bs-tether-element-attached-top::before, .popover.bs-tether-element-attached-top::after {\n left: 50%;\n border-top-width: 0;\n}\n\n.popover.popover-bottom::before, .popover.bs-tether-element-attached-top::before {\n top: -11px;\n margin-left: -11px;\n border-bottom-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-bottom::after, .popover.bs-tether-element-attached-top::after {\n top: -10px;\n margin-left: -10px;\n border-bottom-color: #f7f7f7;\n}\n\n.popover.popover-bottom .popover-title::before, .popover.bs-tether-element-attached-top .popover-title::before {\n position: absolute;\n top: 0;\n left: 50%;\n display: block;\n width: 20px;\n margin-left: -10px;\n content: \"\";\n border-bottom: 1px solid #f7f7f7;\n}\n\n.popover.popover-left, .popover.bs-tether-element-attached-right {\n margin-left: -10px;\n}\n\n.popover.popover-left::before, .popover.popover-left::after, .popover.bs-tether-element-attached-right::before, .popover.bs-tether-element-attached-right::after {\n top: 50%;\n border-right-width: 0;\n}\n\n.popover.popover-left::before, .popover.bs-tether-element-attached-right::before {\n right: -11px;\n margin-top: -11px;\n border-left-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-left::after, .popover.bs-tether-element-attached-right::after {\n right: -10px;\n margin-top: -10px;\n border-left-color: #fff;\n}\n\n.popover-title {\n padding: 8px 14px;\n margin-bottom: 0;\n font-size: 1rem;\n background-color: #f7f7f7;\n border-bottom: 1px solid #ebebeb;\n border-top-right-radius: calc(0.3rem - 1px);\n border-top-left-radius: calc(0.3rem - 1px);\n}\n\n.popover-title:empty {\n display: none;\n}\n\n.popover-content {\n padding: 9px 14px;\n}\n\n.popover::before,\n.popover::after {\n position: absolute;\n display: block;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover::before {\n content: \"\";\n border-width: 11px;\n}\n\n.popover::after {\n content: \"\";\n border-width: 10px;\n}\n\n.carousel {\n position: relative;\n}\n\n.carousel-inner {\n position: relative;\n width: 100%;\n overflow: hidden;\n}\n\n.carousel-item {\n position: relative;\n display: none;\n width: 100%;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n.carousel-item.active,\n.carousel-item-next,\n.carousel-item-prev {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n}\n\n.carousel-item-next,\n.carousel-item-prev {\n position: absolute;\n top: 0;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n.carousel-control-prev,\n.carousel-control-next {\n position: absolute;\n top: 0;\n bottom: 0;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: 15%;\n color: #fff;\n text-align: center;\n opacity: 0.5;\n}\n\n.carousel-control-prev:focus, .carousel-control-prev:hover,\n.carousel-control-next:focus,\n.carousel-control-next:hover {\n color: #fff;\n text-decoration: none;\n outline: 0;\n opacity: .9;\n}\n\n.carousel-control-prev {\n left: 0;\n}\n\n.carousel-control-next {\n right: 0;\n}\n\n.carousel-control-prev-icon,\n.carousel-control-next-icon {\n display: inline-block;\n width: 20px;\n height: 20px;\n background: transparent no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.carousel-control-prev-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M4 0l-4 4 4 4 1.5-1.5-2.5-2.5 2.5-2.5-1.5-1.5z'/%3E%3C/svg%3E\");\n}\n\n.carousel-control-next-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M1.5 0l-1.5 1.5 2.5 2.5-2.5 2.5 1.5 1.5 4-4-4-4z'/%3E%3C/svg%3E\");\n}\n\n.carousel-indicators {\n position: absolute;\n right: 0;\n bottom: 10px;\n left: 0;\n z-index: 15;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n margin-right: 15%;\n margin-left: 15%;\n list-style: none;\n}\n\n.carousel-indicators li {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 auto;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n max-width: 30px;\n height: 3px;\n margin-right: 3px;\n margin-left: 3px;\n text-indent: -999px;\n cursor: pointer;\n background-color: rgba(255, 255, 255, 0.5);\n}\n\n.carousel-indicators li::before {\n position: absolute;\n top: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators li::after {\n position: absolute;\n bottom: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators .active {\n background-color: #fff;\n}\n\n.carousel-caption {\n position: absolute;\n right: 15%;\n bottom: 20px;\n left: 15%;\n z-index: 10;\n padding-top: 20px;\n padding-bottom: 20px;\n color: #fff;\n text-align: center;\n}\n\n.align-baseline {\n vertical-align: baseline !important;\n}\n\n.align-top {\n vertical-align: top !important;\n}\n\n.align-middle {\n vertical-align: middle !important;\n}\n\n.align-bottom {\n vertical-align: bottom !important;\n}\n\n.align-text-bottom {\n vertical-align: text-bottom !important;\n}\n\n.align-text-top {\n vertical-align: text-top !important;\n}\n\n.bg-faded {\n background-color: #f7f7f7;\n}\n\n.bg-primary {\n background-color: #0275d8 !important;\n}\n\na.bg-primary:focus, a.bg-primary:hover {\n background-color: #025aa5 !important;\n}\n\n.bg-success {\n background-color: #5cb85c !important;\n}\n\na.bg-success:focus, a.bg-success:hover {\n background-color: #449d44 !important;\n}\n\n.bg-info {\n background-color: #5bc0de !important;\n}\n\na.bg-info:focus, a.bg-info:hover {\n background-color: #31b0d5 !important;\n}\n\n.bg-warning {\n background-color: #f0ad4e !important;\n}\n\na.bg-warning:focus, a.bg-warning:hover {\n background-color: #ec971f !important;\n}\n\n.bg-danger {\n background-color: #d9534f !important;\n}\n\na.bg-danger:focus, a.bg-danger:hover {\n background-color: #c9302c !important;\n}\n\n.bg-inverse {\n background-color: #292b2c !important;\n}\n\na.bg-inverse:focus, a.bg-inverse:hover {\n background-color: #101112 !important;\n}\n\n.border-0 {\n border: 0 !important;\n}\n\n.border-top-0 {\n border-top: 0 !important;\n}\n\n.border-right-0 {\n border-right: 0 !important;\n}\n\n.border-bottom-0 {\n border-bottom: 0 !important;\n}\n\n.border-left-0 {\n border-left: 0 !important;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.rounded-top {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-right {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.rounded-bottom {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.rounded-left {\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-circle {\n border-radius: 50%;\n}\n\n.rounded-0 {\n border-radius: 0;\n}\n\n.clearfix::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.d-none {\n display: none !important;\n}\n\n.d-inline {\n display: inline !important;\n}\n\n.d-inline-block {\n display: inline-block !important;\n}\n\n.d-block {\n display: block !important;\n}\n\n.d-table {\n display: table !important;\n}\n\n.d-table-cell {\n display: table-cell !important;\n}\n\n.d-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n}\n\n.d-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n}\n\n@media (min-width: 576px) {\n .d-sm-none {\n display: none !important;\n }\n .d-sm-inline {\n display: inline !important;\n }\n .d-sm-inline-block {\n display: inline-block !important;\n }\n .d-sm-block {\n display: block !important;\n }\n .d-sm-table {\n display: table !important;\n }\n .d-sm-table-cell {\n display: table-cell !important;\n }\n .d-sm-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-sm-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 768px) {\n .d-md-none {\n display: none !important;\n }\n .d-md-inline {\n display: inline !important;\n }\n .d-md-inline-block {\n display: inline-block !important;\n }\n .d-md-block {\n display: block !important;\n }\n .d-md-table {\n display: table !important;\n }\n .d-md-table-cell {\n display: table-cell !important;\n }\n .d-md-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-md-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 992px) {\n .d-lg-none {\n display: none !important;\n }\n .d-lg-inline {\n display: inline !important;\n }\n .d-lg-inline-block {\n display: inline-block !important;\n }\n .d-lg-block {\n display: block !important;\n }\n .d-lg-table {\n display: table !important;\n }\n .d-lg-table-cell {\n display: table-cell !important;\n }\n .d-lg-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-lg-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 1200px) {\n .d-xl-none {\n display: none !important;\n }\n .d-xl-inline {\n display: inline !important;\n }\n .d-xl-inline-block {\n display: inline-block !important;\n }\n .d-xl-block {\n display: block !important;\n }\n .d-xl-table {\n display: table !important;\n }\n .d-xl-table-cell {\n display: table-cell !important;\n }\n .d-xl-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-xl-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n.flex-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n}\n\n.flex-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n}\n\n.flex-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n}\n\n.flex-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n}\n\n.flex-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n}\n\n.flex-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n}\n\n.flex-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n}\n\n.flex-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n}\n\n.flex-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n}\n\n.flex-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n}\n\n.justify-content-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n}\n\n.justify-content-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n}\n\n.justify-content-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n}\n\n.justify-content-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n}\n\n.justify-content-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n}\n\n.align-items-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n}\n\n.align-items-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n}\n\n.align-items-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n}\n\n.align-items-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n}\n\n.align-items-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n}\n\n.align-content-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n}\n\n.align-content-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n}\n\n.align-content-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n}\n\n.align-content-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n}\n\n.align-content-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n}\n\n.align-content-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n}\n\n.align-self-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n}\n\n.align-self-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n}\n\n.align-self-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n}\n\n.align-self-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n}\n\n.align-self-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n}\n\n.align-self-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n}\n\n@media (min-width: 576px) {\n .flex-sm-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-sm-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-sm-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-sm-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-sm-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-sm-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-sm-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-sm-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-sm-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-sm-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-sm-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-sm-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-sm-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-sm-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-sm-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-sm-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-sm-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-sm-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-sm-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-sm-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-sm-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-sm-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-sm-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-sm-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-sm-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-sm-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-sm-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-sm-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-sm-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-sm-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-sm-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-sm-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 768px) {\n .flex-md-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-md-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-md-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-md-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-md-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-md-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-md-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-md-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-md-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-md-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-md-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-md-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-md-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-md-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-md-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-md-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-md-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-md-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-md-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-md-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-md-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-md-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-md-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-md-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-md-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-md-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-md-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-md-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-md-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-md-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-md-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-md-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 992px) {\n .flex-lg-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-lg-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-lg-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-lg-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-lg-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-lg-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-lg-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-lg-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-lg-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-lg-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-lg-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-lg-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-lg-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-lg-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-lg-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-lg-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-lg-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-lg-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-lg-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-lg-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-lg-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-lg-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-lg-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-lg-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-lg-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-lg-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-lg-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-lg-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-lg-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-lg-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-lg-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-lg-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 1200px) {\n .flex-xl-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-xl-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-xl-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-xl-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-xl-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-xl-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-xl-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-xl-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-xl-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-xl-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-xl-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-xl-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-xl-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-xl-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-xl-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-xl-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-xl-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-xl-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-xl-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-xl-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-xl-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-xl-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-xl-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-xl-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-xl-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-xl-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-xl-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-xl-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-xl-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-xl-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-xl-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-xl-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n.float-left {\n float: left !important;\n}\n\n.float-right {\n float: right !important;\n}\n\n.float-none {\n float: none !important;\n}\n\n@media (min-width: 576px) {\n .float-sm-left {\n float: left !important;\n }\n .float-sm-right {\n float: right !important;\n }\n .float-sm-none {\n float: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .float-md-left {\n float: left !important;\n }\n .float-md-right {\n float: right !important;\n }\n .float-md-none {\n float: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .float-lg-left {\n float: left !important;\n }\n .float-lg-right {\n float: right !important;\n }\n .float-lg-none {\n float: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .float-xl-left {\n float: left !important;\n }\n .float-xl-right {\n float: right !important;\n }\n .float-xl-none {\n float: none !important;\n }\n}\n\n.fixed-top {\n position: fixed;\n top: 0;\n right: 0;\n left: 0;\n z-index: 1030;\n}\n\n.fixed-bottom {\n position: fixed;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1030;\n}\n\n.sticky-top {\n position: -webkit-sticky;\n position: sticky;\n top: 0;\n z-index: 1030;\n}\n\n.sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n border: 0;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n position: static;\n width: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n clip: auto;\n}\n\n.w-25 {\n width: 25% !important;\n}\n\n.w-50 {\n width: 50% !important;\n}\n\n.w-75 {\n width: 75% !important;\n}\n\n.w-100 {\n width: 100% !important;\n}\n\n.h-25 {\n height: 25% !important;\n}\n\n.h-50 {\n height: 50% !important;\n}\n\n.h-75 {\n height: 75% !important;\n}\n\n.h-100 {\n height: 100% !important;\n}\n\n.mw-100 {\n max-width: 100% !important;\n}\n\n.mh-100 {\n max-height: 100% !important;\n}\n\n.m-0 {\n margin: 0 0 !important;\n}\n\n.mt-0 {\n margin-top: 0 !important;\n}\n\n.mr-0 {\n margin-right: 0 !important;\n}\n\n.mb-0 {\n margin-bottom: 0 !important;\n}\n\n.ml-0 {\n margin-left: 0 !important;\n}\n\n.mx-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n}\n\n.my-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n}\n\n.m-1 {\n margin: 0.25rem 0.25rem !important;\n}\n\n.mt-1 {\n margin-top: 0.25rem !important;\n}\n\n.mr-1 {\n margin-right: 0.25rem !important;\n}\n\n.mb-1 {\n margin-bottom: 0.25rem !important;\n}\n\n.ml-1 {\n margin-left: 0.25rem !important;\n}\n\n.mx-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n}\n\n.my-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n}\n\n.m-2 {\n margin: 0.5rem 0.5rem !important;\n}\n\n.mt-2 {\n margin-top: 0.5rem !important;\n}\n\n.mr-2 {\n margin-right: 0.5rem !important;\n}\n\n.mb-2 {\n margin-bottom: 0.5rem !important;\n}\n\n.ml-2 {\n margin-left: 0.5rem !important;\n}\n\n.mx-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n}\n\n.my-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n}\n\n.m-3 {\n margin: 1rem 1rem !important;\n}\n\n.mt-3 {\n margin-top: 1rem !important;\n}\n\n.mr-3 {\n margin-right: 1rem !important;\n}\n\n.mb-3 {\n margin-bottom: 1rem !important;\n}\n\n.ml-3 {\n margin-left: 1rem !important;\n}\n\n.mx-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n}\n\n.my-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n}\n\n.m-4 {\n margin: 1.5rem 1.5rem !important;\n}\n\n.mt-4 {\n margin-top: 1.5rem !important;\n}\n\n.mr-4 {\n margin-right: 1.5rem !important;\n}\n\n.mb-4 {\n margin-bottom: 1.5rem !important;\n}\n\n.ml-4 {\n margin-left: 1.5rem !important;\n}\n\n.mx-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n}\n\n.my-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n}\n\n.m-5 {\n margin: 3rem 3rem !important;\n}\n\n.mt-5 {\n margin-top: 3rem !important;\n}\n\n.mr-5 {\n margin-right: 3rem !important;\n}\n\n.mb-5 {\n margin-bottom: 3rem !important;\n}\n\n.ml-5 {\n margin-left: 3rem !important;\n}\n\n.mx-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n}\n\n.my-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n}\n\n.p-0 {\n padding: 0 0 !important;\n}\n\n.pt-0 {\n padding-top: 0 !important;\n}\n\n.pr-0 {\n padding-right: 0 !important;\n}\n\n.pb-0 {\n padding-bottom: 0 !important;\n}\n\n.pl-0 {\n padding-left: 0 !important;\n}\n\n.px-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n}\n\n.py-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n}\n\n.p-1 {\n padding: 0.25rem 0.25rem !important;\n}\n\n.pt-1 {\n padding-top: 0.25rem !important;\n}\n\n.pr-1 {\n padding-right: 0.25rem !important;\n}\n\n.pb-1 {\n padding-bottom: 0.25rem !important;\n}\n\n.pl-1 {\n padding-left: 0.25rem !important;\n}\n\n.px-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n}\n\n.py-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n}\n\n.p-2 {\n padding: 0.5rem 0.5rem !important;\n}\n\n.pt-2 {\n padding-top: 0.5rem !important;\n}\n\n.pr-2 {\n padding-right: 0.5rem !important;\n}\n\n.pb-2 {\n padding-bottom: 0.5rem !important;\n}\n\n.pl-2 {\n padding-left: 0.5rem !important;\n}\n\n.px-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n}\n\n.py-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n}\n\n.p-3 {\n padding: 1rem 1rem !important;\n}\n\n.pt-3 {\n padding-top: 1rem !important;\n}\n\n.pr-3 {\n padding-right: 1rem !important;\n}\n\n.pb-3 {\n padding-bottom: 1rem !important;\n}\n\n.pl-3 {\n padding-left: 1rem !important;\n}\n\n.px-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n}\n\n.py-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n}\n\n.p-4 {\n padding: 1.5rem 1.5rem !important;\n}\n\n.pt-4 {\n padding-top: 1.5rem !important;\n}\n\n.pr-4 {\n padding-right: 1.5rem !important;\n}\n\n.pb-4 {\n padding-bottom: 1.5rem !important;\n}\n\n.pl-4 {\n padding-left: 1.5rem !important;\n}\n\n.px-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n}\n\n.py-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n}\n\n.p-5 {\n padding: 3rem 3rem !important;\n}\n\n.pt-5 {\n padding-top: 3rem !important;\n}\n\n.pr-5 {\n padding-right: 3rem !important;\n}\n\n.pb-5 {\n padding-bottom: 3rem !important;\n}\n\n.pl-5 {\n padding-left: 3rem !important;\n}\n\n.px-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n}\n\n.py-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n}\n\n.m-auto {\n margin: auto !important;\n}\n\n.mt-auto {\n margin-top: auto !important;\n}\n\n.mr-auto {\n margin-right: auto !important;\n}\n\n.mb-auto {\n margin-bottom: auto !important;\n}\n\n.ml-auto {\n margin-left: auto !important;\n}\n\n.mx-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n}\n\n.my-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n}\n\n@media (min-width: 576px) {\n .m-sm-0 {\n margin: 0 0 !important;\n }\n .mt-sm-0 {\n margin-top: 0 !important;\n }\n .mr-sm-0 {\n margin-right: 0 !important;\n }\n .mb-sm-0 {\n margin-bottom: 0 !important;\n }\n .ml-sm-0 {\n margin-left: 0 !important;\n }\n .mx-sm-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-sm-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-sm-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-sm-1 {\n margin-top: 0.25rem !important;\n }\n .mr-sm-1 {\n margin-right: 0.25rem !important;\n }\n .mb-sm-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-sm-1 {\n margin-left: 0.25rem !important;\n }\n .mx-sm-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-sm-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-sm-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-sm-2 {\n margin-top: 0.5rem !important;\n }\n .mr-sm-2 {\n margin-right: 0.5rem !important;\n }\n .mb-sm-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-sm-2 {\n margin-left: 0.5rem !important;\n }\n .mx-sm-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-sm-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-sm-3 {\n margin: 1rem 1rem !important;\n }\n .mt-sm-3 {\n margin-top: 1rem !important;\n }\n .mr-sm-3 {\n margin-right: 1rem !important;\n }\n .mb-sm-3 {\n margin-bottom: 1rem !important;\n }\n .ml-sm-3 {\n margin-left: 1rem !important;\n }\n .mx-sm-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-sm-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-sm-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-sm-4 {\n margin-top: 1.5rem !important;\n }\n .mr-sm-4 {\n margin-right: 1.5rem !important;\n }\n .mb-sm-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-sm-4 {\n margin-left: 1.5rem !important;\n }\n .mx-sm-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-sm-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-sm-5 {\n margin: 3rem 3rem !important;\n }\n .mt-sm-5 {\n margin-top: 3rem !important;\n }\n .mr-sm-5 {\n margin-right: 3rem !important;\n }\n .mb-sm-5 {\n margin-bottom: 3rem !important;\n }\n .ml-sm-5 {\n margin-left: 3rem !important;\n }\n .mx-sm-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-sm-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-sm-0 {\n padding: 0 0 !important;\n }\n .pt-sm-0 {\n padding-top: 0 !important;\n }\n .pr-sm-0 {\n padding-right: 0 !important;\n }\n .pb-sm-0 {\n padding-bottom: 0 !important;\n }\n .pl-sm-0 {\n padding-left: 0 !important;\n }\n .px-sm-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-sm-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-sm-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-sm-1 {\n padding-top: 0.25rem !important;\n }\n .pr-sm-1 {\n padding-right: 0.25rem !important;\n }\n .pb-sm-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-sm-1 {\n padding-left: 0.25rem !important;\n }\n .px-sm-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-sm-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-sm-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-sm-2 {\n padding-top: 0.5rem !important;\n }\n .pr-sm-2 {\n padding-right: 0.5rem !important;\n }\n .pb-sm-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-sm-2 {\n padding-left: 0.5rem !important;\n }\n .px-sm-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-sm-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-sm-3 {\n padding: 1rem 1rem !important;\n }\n .pt-sm-3 {\n padding-top: 1rem !important;\n }\n .pr-sm-3 {\n padding-right: 1rem !important;\n }\n .pb-sm-3 {\n padding-bottom: 1rem !important;\n }\n .pl-sm-3 {\n padding-left: 1rem !important;\n }\n .px-sm-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-sm-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-sm-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-sm-4 {\n padding-top: 1.5rem !important;\n }\n .pr-sm-4 {\n padding-right: 1.5rem !important;\n }\n .pb-sm-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-sm-4 {\n padding-left: 1.5rem !important;\n }\n .px-sm-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-sm-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-sm-5 {\n padding: 3rem 3rem !important;\n }\n .pt-sm-5 {\n padding-top: 3rem !important;\n }\n .pr-sm-5 {\n padding-right: 3rem !important;\n }\n .pb-sm-5 {\n padding-bottom: 3rem !important;\n }\n .pl-sm-5 {\n padding-left: 3rem !important;\n }\n .px-sm-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-sm-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-sm-auto {\n margin: auto !important;\n }\n .mt-sm-auto {\n margin-top: auto !important;\n }\n .mr-sm-auto {\n margin-right: auto !important;\n }\n .mb-sm-auto {\n margin-bottom: auto !important;\n }\n .ml-sm-auto {\n margin-left: auto !important;\n }\n .mx-sm-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-sm-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 768px) {\n .m-md-0 {\n margin: 0 0 !important;\n }\n .mt-md-0 {\n margin-top: 0 !important;\n }\n .mr-md-0 {\n margin-right: 0 !important;\n }\n .mb-md-0 {\n margin-bottom: 0 !important;\n }\n .ml-md-0 {\n margin-left: 0 !important;\n }\n .mx-md-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-md-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-md-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-md-1 {\n margin-top: 0.25rem !important;\n }\n .mr-md-1 {\n margin-right: 0.25rem !important;\n }\n .mb-md-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-md-1 {\n margin-left: 0.25rem !important;\n }\n .mx-md-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-md-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-md-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-md-2 {\n margin-top: 0.5rem !important;\n }\n .mr-md-2 {\n margin-right: 0.5rem !important;\n }\n .mb-md-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-md-2 {\n margin-left: 0.5rem !important;\n }\n .mx-md-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-md-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-md-3 {\n margin: 1rem 1rem !important;\n }\n .mt-md-3 {\n margin-top: 1rem !important;\n }\n .mr-md-3 {\n margin-right: 1rem !important;\n }\n .mb-md-3 {\n margin-bottom: 1rem !important;\n }\n .ml-md-3 {\n margin-left: 1rem !important;\n }\n .mx-md-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-md-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-md-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-md-4 {\n margin-top: 1.5rem !important;\n }\n .mr-md-4 {\n margin-right: 1.5rem !important;\n }\n .mb-md-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-md-4 {\n margin-left: 1.5rem !important;\n }\n .mx-md-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-md-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-md-5 {\n margin: 3rem 3rem !important;\n }\n .mt-md-5 {\n margin-top: 3rem !important;\n }\n .mr-md-5 {\n margin-right: 3rem !important;\n }\n .mb-md-5 {\n margin-bottom: 3rem !important;\n }\n .ml-md-5 {\n margin-left: 3rem !important;\n }\n .mx-md-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-md-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-md-0 {\n padding: 0 0 !important;\n }\n .pt-md-0 {\n padding-top: 0 !important;\n }\n .pr-md-0 {\n padding-right: 0 !important;\n }\n .pb-md-0 {\n padding-bottom: 0 !important;\n }\n .pl-md-0 {\n padding-left: 0 !important;\n }\n .px-md-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-md-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-md-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-md-1 {\n padding-top: 0.25rem !important;\n }\n .pr-md-1 {\n padding-right: 0.25rem !important;\n }\n .pb-md-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-md-1 {\n padding-left: 0.25rem !important;\n }\n .px-md-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-md-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-md-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-md-2 {\n padding-top: 0.5rem !important;\n }\n .pr-md-2 {\n padding-right: 0.5rem !important;\n }\n .pb-md-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-md-2 {\n padding-left: 0.5rem !important;\n }\n .px-md-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-md-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-md-3 {\n padding: 1rem 1rem !important;\n }\n .pt-md-3 {\n padding-top: 1rem !important;\n }\n .pr-md-3 {\n padding-right: 1rem !important;\n }\n .pb-md-3 {\n padding-bottom: 1rem !important;\n }\n .pl-md-3 {\n padding-left: 1rem !important;\n }\n .px-md-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-md-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-md-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-md-4 {\n padding-top: 1.5rem !important;\n }\n .pr-md-4 {\n padding-right: 1.5rem !important;\n }\n .pb-md-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-md-4 {\n padding-left: 1.5rem !important;\n }\n .px-md-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-md-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-md-5 {\n padding: 3rem 3rem !important;\n }\n .pt-md-5 {\n padding-top: 3rem !important;\n }\n .pr-md-5 {\n padding-right: 3rem !important;\n }\n .pb-md-5 {\n padding-bottom: 3rem !important;\n }\n .pl-md-5 {\n padding-left: 3rem !important;\n }\n .px-md-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-md-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-md-auto {\n margin: auto !important;\n }\n .mt-md-auto {\n margin-top: auto !important;\n }\n .mr-md-auto {\n margin-right: auto !important;\n }\n .mb-md-auto {\n margin-bottom: auto !important;\n }\n .ml-md-auto {\n margin-left: auto !important;\n }\n .mx-md-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-md-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 992px) {\n .m-lg-0 {\n margin: 0 0 !important;\n }\n .mt-lg-0 {\n margin-top: 0 !important;\n }\n .mr-lg-0 {\n margin-right: 0 !important;\n }\n .mb-lg-0 {\n margin-bottom: 0 !important;\n }\n .ml-lg-0 {\n margin-left: 0 !important;\n }\n .mx-lg-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-lg-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-lg-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-lg-1 {\n margin-top: 0.25rem !important;\n }\n .mr-lg-1 {\n margin-right: 0.25rem !important;\n }\n .mb-lg-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-lg-1 {\n margin-left: 0.25rem !important;\n }\n .mx-lg-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-lg-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-lg-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-lg-2 {\n margin-top: 0.5rem !important;\n }\n .mr-lg-2 {\n margin-right: 0.5rem !important;\n }\n .mb-lg-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-lg-2 {\n margin-left: 0.5rem !important;\n }\n .mx-lg-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-lg-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-lg-3 {\n margin: 1rem 1rem !important;\n }\n .mt-lg-3 {\n margin-top: 1rem !important;\n }\n .mr-lg-3 {\n margin-right: 1rem !important;\n }\n .mb-lg-3 {\n margin-bottom: 1rem !important;\n }\n .ml-lg-3 {\n margin-left: 1rem !important;\n }\n .mx-lg-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-lg-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-lg-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-lg-4 {\n margin-top: 1.5rem !important;\n }\n .mr-lg-4 {\n margin-right: 1.5rem !important;\n }\n .mb-lg-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-lg-4 {\n margin-left: 1.5rem !important;\n }\n .mx-lg-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-lg-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-lg-5 {\n margin: 3rem 3rem !important;\n }\n .mt-lg-5 {\n margin-top: 3rem !important;\n }\n .mr-lg-5 {\n margin-right: 3rem !important;\n }\n .mb-lg-5 {\n margin-bottom: 3rem !important;\n }\n .ml-lg-5 {\n margin-left: 3rem !important;\n }\n .mx-lg-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-lg-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-lg-0 {\n padding: 0 0 !important;\n }\n .pt-lg-0 {\n padding-top: 0 !important;\n }\n .pr-lg-0 {\n padding-right: 0 !important;\n }\n .pb-lg-0 {\n padding-bottom: 0 !important;\n }\n .pl-lg-0 {\n padding-left: 0 !important;\n }\n .px-lg-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-lg-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-lg-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-lg-1 {\n padding-top: 0.25rem !important;\n }\n .pr-lg-1 {\n padding-right: 0.25rem !important;\n }\n .pb-lg-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-lg-1 {\n padding-left: 0.25rem !important;\n }\n .px-lg-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-lg-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-lg-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-lg-2 {\n padding-top: 0.5rem !important;\n }\n .pr-lg-2 {\n padding-right: 0.5rem !important;\n }\n .pb-lg-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-lg-2 {\n padding-left: 0.5rem !important;\n }\n .px-lg-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-lg-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-lg-3 {\n padding: 1rem 1rem !important;\n }\n .pt-lg-3 {\n padding-top: 1rem !important;\n }\n .pr-lg-3 {\n padding-right: 1rem !important;\n }\n .pb-lg-3 {\n padding-bottom: 1rem !important;\n }\n .pl-lg-3 {\n padding-left: 1rem !important;\n }\n .px-lg-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-lg-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-lg-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-lg-4 {\n padding-top: 1.5rem !important;\n }\n .pr-lg-4 {\n padding-right: 1.5rem !important;\n }\n .pb-lg-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-lg-4 {\n padding-left: 1.5rem !important;\n }\n .px-lg-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-lg-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-lg-5 {\n padding: 3rem 3rem !important;\n }\n .pt-lg-5 {\n padding-top: 3rem !important;\n }\n .pr-lg-5 {\n padding-right: 3rem !important;\n }\n .pb-lg-5 {\n padding-bottom: 3rem !important;\n }\n .pl-lg-5 {\n padding-left: 3rem !important;\n }\n .px-lg-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-lg-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-lg-auto {\n margin: auto !important;\n }\n .mt-lg-auto {\n margin-top: auto !important;\n }\n .mr-lg-auto {\n margin-right: auto !important;\n }\n .mb-lg-auto {\n margin-bottom: auto !important;\n }\n .ml-lg-auto {\n margin-left: auto !important;\n }\n .mx-lg-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-lg-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 1200px) {\n .m-xl-0 {\n margin: 0 0 !important;\n }\n .mt-xl-0 {\n margin-top: 0 !important;\n }\n .mr-xl-0 {\n margin-right: 0 !important;\n }\n .mb-xl-0 {\n margin-bottom: 0 !important;\n }\n .ml-xl-0 {\n margin-left: 0 !important;\n }\n .mx-xl-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-xl-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-xl-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-xl-1 {\n margin-top: 0.25rem !important;\n }\n .mr-xl-1 {\n margin-right: 0.25rem !important;\n }\n .mb-xl-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-xl-1 {\n margin-left: 0.25rem !important;\n }\n .mx-xl-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-xl-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-xl-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-xl-2 {\n margin-top: 0.5rem !important;\n }\n .mr-xl-2 {\n margin-right: 0.5rem !important;\n }\n .mb-xl-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-xl-2 {\n margin-left: 0.5rem !important;\n }\n .mx-xl-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-xl-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-xl-3 {\n margin: 1rem 1rem !important;\n }\n .mt-xl-3 {\n margin-top: 1rem !important;\n }\n .mr-xl-3 {\n margin-right: 1rem !important;\n }\n .mb-xl-3 {\n margin-bottom: 1rem !important;\n }\n .ml-xl-3 {\n margin-left: 1rem !important;\n }\n .mx-xl-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-xl-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-xl-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-xl-4 {\n margin-top: 1.5rem !important;\n }\n .mr-xl-4 {\n margin-right: 1.5rem !important;\n }\n .mb-xl-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-xl-4 {\n margin-left: 1.5rem !important;\n }\n .mx-xl-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-xl-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-xl-5 {\n margin: 3rem 3rem !important;\n }\n .mt-xl-5 {\n margin-top: 3rem !important;\n }\n .mr-xl-5 {\n margin-right: 3rem !important;\n }\n .mb-xl-5 {\n margin-bottom: 3rem !important;\n }\n .ml-xl-5 {\n margin-left: 3rem !important;\n }\n .mx-xl-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-xl-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-xl-0 {\n padding: 0 0 !important;\n }\n .pt-xl-0 {\n padding-top: 0 !important;\n }\n .pr-xl-0 {\n padding-right: 0 !important;\n }\n .pb-xl-0 {\n padding-bottom: 0 !important;\n }\n .pl-xl-0 {\n padding-left: 0 !important;\n }\n .px-xl-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-xl-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-xl-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-xl-1 {\n padding-top: 0.25rem !important;\n }\n .pr-xl-1 {\n padding-right: 0.25rem !important;\n }\n .pb-xl-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-xl-1 {\n padding-left: 0.25rem !important;\n }\n .px-xl-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-xl-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-xl-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-xl-2 {\n padding-top: 0.5rem !important;\n }\n .pr-xl-2 {\n padding-right: 0.5rem !important;\n }\n .pb-xl-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-xl-2 {\n padding-left: 0.5rem !important;\n }\n .px-xl-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-xl-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-xl-3 {\n padding: 1rem 1rem !important;\n }\n .pt-xl-3 {\n padding-top: 1rem !important;\n }\n .pr-xl-3 {\n padding-right: 1rem !important;\n }\n .pb-xl-3 {\n padding-bottom: 1rem !important;\n }\n .pl-xl-3 {\n padding-left: 1rem !important;\n }\n .px-xl-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-xl-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-xl-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-xl-4 {\n padding-top: 1.5rem !important;\n }\n .pr-xl-4 {\n padding-right: 1.5rem !important;\n }\n .pb-xl-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-xl-4 {\n padding-left: 1.5rem !important;\n }\n .px-xl-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-xl-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-xl-5 {\n padding: 3rem 3rem !important;\n }\n .pt-xl-5 {\n padding-top: 3rem !important;\n }\n .pr-xl-5 {\n padding-right: 3rem !important;\n }\n .pb-xl-5 {\n padding-bottom: 3rem !important;\n }\n .pl-xl-5 {\n padding-left: 3rem !important;\n }\n .px-xl-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-xl-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-xl-auto {\n margin: auto !important;\n }\n .mt-xl-auto {\n margin-top: auto !important;\n }\n .mr-xl-auto {\n margin-right: auto !important;\n }\n .mb-xl-auto {\n margin-bottom: auto !important;\n }\n .ml-xl-auto {\n margin-left: auto !important;\n }\n .mx-xl-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-xl-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n.text-justify {\n text-align: justify !important;\n}\n\n.text-nowrap {\n white-space: nowrap !important;\n}\n\n.text-truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.text-left {\n text-align: left !important;\n}\n\n.text-right {\n text-align: right !important;\n}\n\n.text-center {\n text-align: center !important;\n}\n\n@media (min-width: 576px) {\n .text-sm-left {\n text-align: left !important;\n }\n .text-sm-right {\n text-align: right !important;\n }\n .text-sm-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 768px) {\n .text-md-left {\n text-align: left !important;\n }\n .text-md-right {\n text-align: right !important;\n }\n .text-md-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 992px) {\n .text-lg-left {\n text-align: left !important;\n }\n .text-lg-right {\n text-align: right !important;\n }\n .text-lg-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 1200px) {\n .text-xl-left {\n text-align: left !important;\n }\n .text-xl-right {\n text-align: right !important;\n }\n .text-xl-center {\n text-align: center !important;\n }\n}\n\n.text-lowercase {\n text-transform: lowercase !important;\n}\n\n.text-uppercase {\n text-transform: uppercase !important;\n}\n\n.text-capitalize {\n text-transform: capitalize !important;\n}\n\n.font-weight-normal {\n font-weight: normal;\n}\n\n.font-weight-bold {\n font-weight: bold;\n}\n\n.font-italic {\n font-style: italic;\n}\n\n.text-white {\n color: #fff !important;\n}\n\n.text-muted {\n color: #636c72 !important;\n}\n\na.text-muted:focus, a.text-muted:hover {\n color: #4b5257 !important;\n}\n\n.text-primary {\n color: #0275d8 !important;\n}\n\na.text-primary:focus, a.text-primary:hover {\n color: #025aa5 !important;\n}\n\n.text-success {\n color: #5cb85c !important;\n}\n\na.text-success:focus, a.text-success:hover {\n color: #449d44 !important;\n}\n\n.text-info {\n color: #5bc0de !important;\n}\n\na.text-info:focus, a.text-info:hover {\n color: #31b0d5 !important;\n}\n\n.text-warning {\n color: #f0ad4e !important;\n}\n\na.text-warning:focus, a.text-warning:hover {\n color: #ec971f !important;\n}\n\n.text-danger {\n color: #d9534f !important;\n}\n\na.text-danger:focus, a.text-danger:hover {\n color: #c9302c !important;\n}\n\n.text-gray-dark {\n color: #292b2c !important;\n}\n\na.text-gray-dark:focus, a.text-gray-dark:hover {\n color: #101112 !important;\n}\n\n.text-hide {\n font: 0/0 a;\n color: transparent;\n text-shadow: none;\n background-color: transparent;\n border: 0;\n}\n\n.invisible {\n visibility: hidden !important;\n}\n\n.hidden-xs-up {\n display: none !important;\n}\n\n@media (max-width: 575px) {\n .hidden-xs-down {\n display: none !important;\n }\n}\n\n@media (min-width: 576px) {\n .hidden-sm-up {\n display: none !important;\n }\n}\n\n@media (max-width: 767px) {\n .hidden-sm-down {\n display: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .hidden-md-up {\n display: none !important;\n }\n}\n\n@media (max-width: 991px) {\n .hidden-md-down {\n display: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .hidden-lg-up {\n display: none !important;\n }\n}\n\n@media (max-width: 1199px) {\n .hidden-lg-down {\n display: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .hidden-xl-up {\n display: none !important;\n }\n}\n\n.hidden-xl-down {\n display: none !important;\n}\n\n.visible-print-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-block {\n display: block !important;\n }\n}\n\n.visible-print-inline {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline {\n display: inline !important;\n }\n}\n\n.visible-print-inline-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline-block {\n display: inline-block !important;\n }\n}\n\n@media print {\n .hidden-print {\n display: none !important;\n }\n}", ""]); + +// exports + + +/***/ }), +/* 213 */ +/***/ (function(module, exports) { + + +/** + * When source maps are enabled, `style-loader` uses a link element with a data-uri to + * embed the css on the page. This breaks all relative urls because now they are relative to a + * bundle instead of the current page. + * + * One solution is to only use full urls, but that may be impossible. + * + * Instead, this function "fixes" the relative urls to be absolute according to the current page location. + * + * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command. + * + */ + +module.exports = function (css) { + // get current location + var location = typeof window !== "undefined" && window.location; + + if (!location) { + throw new Error("fixUrls requires window.location"); + } + + // blank or null? + if (!css || typeof css !== "string") { + return css; + } + + var baseUrl = location.protocol + "//" + location.host; + var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/"); + + // convert each url(...) + /* + This regular expression is just a way to recursively match brackets within + a string. + + /url\s*\( = Match on the word "url" with any whitespace after it and then a parens + ( = Start a capturing group + (?: = Start a non-capturing group + [^)(] = Match anything that isn't a parentheses + | = OR + \( = Match a start parentheses + (?: = Start another non-capturing groups + [^)(]+ = Match anything that isn't a parentheses + | = OR + \( = Match a start parentheses + [^)(]* = Match anything that isn't a parentheses + \) = Match a end parentheses + ) = End Group + *\) = Match anything and then a close parens + ) = Close non-capturing group + * = Match anything + ) = Close capturing group + \) = Match a close parens + + /gi = Get all matches, not the first. Be case insensitive. + */ + var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) { + // strip quotes (if they exist) + var unquotedOrigUrl = origUrl + .trim() + .replace(/^"(.*)"$/, function(o, $1){ return $1; }) + .replace(/^'(.*)'$/, function(o, $1){ return $1; }); + + // already a full url? no change + if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(unquotedOrigUrl)) { + return fullMatch; + } + + // convert the url to a full url + var newUrl; + + if (unquotedOrigUrl.indexOf("//") === 0) { + //TODO: should we add protocol? + newUrl = unquotedOrigUrl; + } else if (unquotedOrigUrl.indexOf("/") === 0) { + // path should be relative to the base url + newUrl = baseUrl + unquotedOrigUrl; // already starts with '/' + } else { + // path should be relative to current directory + newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './' + } + + // send back the fixed url(...) + return "url(" + JSON.stringify(newUrl) + ")"; + }); + + // send back the fixed css + return fixedCss; +}; + + +/***/ }), +/* 214 */ +/***/ (function(module, exports, __webpack_require__) { + +// style-loader: Adds some css to the DOM by adding a <style> tag + +// load the styles +var content = __webpack_require__(215); +if(typeof content === 'string') content = [[module.i, content, '']]; +// Prepare cssTransformation +var transform; + +var options = {} +options.transform = transform +// add the styles to the DOM +var update = __webpack_require__(118)(content, options); +if(content.locals) module.exports = content.locals; +// Hot Module Replacement +if(false) { + // When the styles change, update the <style> tags + if(!content.locals) { + module.hot.accept("!!../css-loader/index.js!./react-table.css", function() { + var newContent = require("!!../css-loader/index.js!./react-table.css"); + if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; + update(newContent); + }); + } + // When the module is disposed, remove the <style> tags + module.hot.dispose(function() { update(); }); +} + +/***/ }), +/* 215 */ +/***/ (function(module, exports, __webpack_require__) { + +exports = module.exports = __webpack_require__(117)(undefined); +// imports + + +// module +exports.push([module.i, ".ReactTable{position:relative;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;border:1px solid rgba(0,0,0,0.1);}.ReactTable *{box-sizing:border-box}.ReactTable .rt-table{-webkit-box-flex:1;-ms-flex:1;flex:1;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;width:100%;border-collapse:collapse;overflow:auto}.ReactTable .rt-thead{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;}.ReactTable .rt-thead.-headerGroups{background:rgba(0,0,0,0.03);border-bottom:1px solid rgba(0,0,0,0.05)}.ReactTable .rt-thead.-filters{border-bottom:1px solid rgba(0,0,0,0.05);}.ReactTable .rt-thead.-filters .rt-th{border-right:1px solid rgba(0,0,0,0.02)}.ReactTable .rt-thead.-header{box-shadow:0 2px 15px 0 rgba(0,0,0,0.15)}.ReactTable .rt-thead .rt-tr{text-align:center}.ReactTable .rt-thead .rt-th,.ReactTable .rt-thead .rt-td{padding:5px 5px;line-height:normal;position:relative;border-right:1px solid rgba(0,0,0,0.05);-webkit-transition:box-shadow .3s cubic-bezier(.175,.885,.32,1.275);transition:box-shadow .3s cubic-bezier(.175,.885,.32,1.275);box-shadow:inset 0 0 0 0 transparent;}.ReactTable .rt-thead .rt-th.-sort-asc,.ReactTable .rt-thead .rt-td.-sort-asc{box-shadow:inset 0 3px 0 0 rgba(0,0,0,0.6)}.ReactTable .rt-thead .rt-th.-sort-desc,.ReactTable .rt-thead .rt-td.-sort-desc{box-shadow:inset 0 -3px 0 0 rgba(0,0,0,0.6)}.ReactTable .rt-thead .rt-th.-cursor-pointer,.ReactTable .rt-thead .rt-td.-cursor-pointer{cursor:pointer}.ReactTable .rt-thead .rt-th:last-child,.ReactTable .rt-thead .rt-td:last-child{border-right:0}.ReactTable .rt-thead .rt-resizable-header{overflow:visible;}.ReactTable .rt-thead .rt-resizable-header:last-child{overflow:hidden}.ReactTable .rt-thead .rt-resizable-header-content{overflow:hidden;text-overflow:ellipsis}.ReactTable .rt-thead .rt-header-pivot{border-right-color:#f7f7f7}.ReactTable .rt-thead .rt-header-pivot:after,.ReactTable .rt-thead .rt-header-pivot:before{left:100%;top:50%;border:solid transparent;content:\" \";height:0;width:0;position:absolute;pointer-events:none}.ReactTable .rt-thead .rt-header-pivot:after{border-color:rgba(255,255,255,0);border-left-color:#fff;border-width:8px;margin-top:-8px}.ReactTable .rt-thead .rt-header-pivot:before{border-color:rgba(102,102,102,0);border-left-color:#f7f7f7;border-width:10px;margin-top:-10px}.ReactTable .rt-tbody{-webkit-box-flex:99999;-ms-flex:99999 1 auto;flex:99999 1 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;overflow:auto;}.ReactTable .rt-tbody .rt-tr-group{border-bottom:solid 1px rgba(0,0,0,0.05);}.ReactTable .rt-tbody .rt-tr-group:last-child{border-bottom:0}.ReactTable .rt-tbody .rt-td{border-right:1px solid rgba(0,0,0,0.02);}.ReactTable .rt-tbody .rt-td:last-child{border-right:0}.ReactTable .rt-tbody .rt-expandable{cursor:pointer}.ReactTable .rt-tr-group{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch}.ReactTable .rt-tr{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.ReactTable .rt-th,.ReactTable .rt-td{-webkit-box-flex:1;-ms-flex:1 0 0px;flex:1 0 0;white-space:nowrap;text-overflow:ellipsis;padding:7px 5px;overflow:hidden;-webkit-transition:.3s ease;transition:.3s ease;-webkit-transition-property:width,min-width,padding,opacity;transition-property:width,min-width,padding,opacity;}.ReactTable .rt-th.-hidden,.ReactTable .rt-td.-hidden{width:0 !important;min-width:0 !important;padding:0 !important;border:0 !important;opacity:0 !important}.ReactTable .rt-expander{display:inline-block;position:relative;margin:0;color:transparent;margin:0 10px;}.ReactTable .rt-expander:after{content:'';position:absolute;width:0;height:0;top:50%;left:50%;-webkit-transform:translate(-50%,-50%) rotate(-90deg);transform:translate(-50%,-50%) rotate(-90deg);border-left:5.04px solid transparent;border-right:5.04px solid transparent;border-top:7px solid rgba(0,0,0,0.8);-webkit-transition:all .3s cubic-bezier(.175,.885,.32,1.275);transition:all .3s cubic-bezier(.175,.885,.32,1.275);cursor:pointer}.ReactTable .rt-expander.-open:after{-webkit-transform:translate(-50%,-50%) rotate(0);transform:translate(-50%,-50%) rotate(0)}.ReactTable .rt-resizer{display:inline-block;position:absolute;width:36px;top:0;bottom:0;right:-18px;cursor:col-resize;z-index:10}.ReactTable .rt-tfoot{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;box-shadow:0 0 15px 0 rgba(0,0,0,0.15);}.ReactTable .rt-tfoot .rt-td{border-right:1px solid rgba(0,0,0,0.05);}.ReactTable .rt-tfoot .rt-td:last-child{border-right:0}.ReactTable.-striped .rt-tr.-odd{background:rgba(0,0,0,0.03)}.ReactTable.-highlight .rt-tbody .rt-tr:not(.-padRow):hover{background:rgba(0,0,0,0.05)}.ReactTable .-pagination{z-index:1;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;-ms-flex-wrap:wrap;flex-wrap:wrap;padding:3px;box-shadow:0 0 15px 0 rgba(0,0,0,0.1);border-top:2px solid rgba(0,0,0,0.1);}.ReactTable .-pagination .-btn{-webkit-appearance:none;-moz-appearance:none;appearance:none;display:block;width:100%;height:100%;border:0;border-radius:3px;padding:6px;font-size:1em;color:rgba(0,0,0,0.6);background:rgba(0,0,0,0.1);-webkit-transition:all .1s ease;transition:all .1s ease;cursor:pointer;outline:none;}.ReactTable .-pagination .-btn[disabled]{opacity:.5;cursor:default}.ReactTable .-pagination .-btn:not([disabled]):hover{background:rgba(0,0,0,0.3);color:#fff}.ReactTable .-pagination .-previous,.ReactTable .-pagination .-next{-webkit-box-flex:1;-ms-flex:1;flex:1;text-align:center}.ReactTable .-pagination .-center{-webkit-box-flex:1.5;-ms-flex:1.5;flex:1.5;text-align:center;margin-bottom:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-ms-flex-pack:distribute;justify-content:space-around}.ReactTable .-pagination .-pageInfo{display:inline-block;margin:3px 10px;white-space:nowrap}.ReactTable .-pagination .-pageJump{display:inline-block;}.ReactTable .-pagination .-pageJump input{width:70px;text-align:center}.ReactTable .-pagination .-pageSizeOptions{margin:3px 10px}.ReactTable .rt-noData{display:block;position:absolute;left:50%;top:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);background:rgba(255,255,255,0.8);-webkit-transition:all .3s ease;transition:all .3s ease;z-index:1;pointer-events:none;padding:20px;color:rgba(0,0,0,0.5)}.ReactTable .-loading{display:block;position:absolute;left:0;right:0;top:0;bottom:0;background:rgba(255,255,255,0.8);-webkit-transition:all .3s ease;transition:all .3s ease;z-index:-1;opacity:0;pointer-events:none;}.ReactTable .-loading > div{position:absolute;display:block;text-align:center;width:100%;top:50%;left:0;font-size:15px;color:rgba(0,0,0,0.6);-webkit-transform:translateY(-52%);transform:translateY(-52%);-webkit-transition:all .3s cubic-bezier(.25,.46,.45,.94);transition:all .3s cubic-bezier(.25,.46,.45,.94)}.ReactTable .-loading.-active{opacity:1;z-index:2;pointer-events:all;}.ReactTable .-loading.-active > div{-webkit-transform:translateY(50%);transform:translateY(50%)}.ReactTable input,.ReactTable select{border:1px solid rgba(0,0,0,0.1);background:#fff;padding:5px 7px;font-size:inherit;border-radius:3px;font-weight:normal;outline:none}.ReactTable .rt-resizing .rt-th,.ReactTable .rt-resizing .rt-td{-webkit-transition:none !important;transition:none !important;cursor:col-resize;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}", ""]); + +// exports + + +/***/ }), +/* 216 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var PooledClass = __webpack_require__(217); +var ReactElement = __webpack_require__(31); + +var emptyFunction = __webpack_require__(18); +var traverseAllChildren = __webpack_require__(218); + +var twoArgumentPooler = PooledClass.twoArgumentPooler; +var fourArgumentPooler = PooledClass.fourArgumentPooler; + +var userProvidedKeyEscapeRegex = /\/+/g; +function escapeUserProvidedKey(text) { + return ('' + text).replace(userProvidedKeyEscapeRegex, '$&/'); +} + +/** + * PooledClass representing the bookkeeping associated with performing a child + * traversal. Allows avoiding binding callbacks. + * + * @constructor ForEachBookKeeping + * @param {!function} forEachFunction Function to perform traversal with. + * @param {?*} forEachContext Context to perform context with. + */ +function ForEachBookKeeping(forEachFunction, forEachContext) { + this.func = forEachFunction; + this.context = forEachContext; + this.count = 0; +} +ForEachBookKeeping.prototype.destructor = function () { + this.func = null; + this.context = null; + this.count = 0; +}; +PooledClass.addPoolingTo(ForEachBookKeeping, twoArgumentPooler); + +function forEachSingleChild(bookKeeping, child, name) { + var func = bookKeeping.func, + context = bookKeeping.context; + + func.call(context, child, bookKeeping.count++); +} + +/** + * Iterates through children that are typically specified as `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.foreach + * + * The provided forEachFunc(child, index) will be called for each + * leaf child. + * + * @param {?*} children Children tree container. + * @param {function(*, int)} forEachFunc + * @param {*} forEachContext Context for forEachContext. + */ +function forEachChildren(children, forEachFunc, forEachContext) { + if (children == null) { + return children; + } + var traverseContext = ForEachBookKeeping.getPooled(forEachFunc, forEachContext); + traverseAllChildren(children, forEachSingleChild, traverseContext); + ForEachBookKeeping.release(traverseContext); +} + +/** + * PooledClass representing the bookkeeping associated with performing a child + * mapping. Allows avoiding binding callbacks. + * + * @constructor MapBookKeeping + * @param {!*} mapResult Object containing the ordered map of results. + * @param {!function} mapFunction Function to perform mapping with. + * @param {?*} mapContext Context to perform mapping with. + */ +function MapBookKeeping(mapResult, keyPrefix, mapFunction, mapContext) { + this.result = mapResult; + this.keyPrefix = keyPrefix; + this.func = mapFunction; + this.context = mapContext; + this.count = 0; +} +MapBookKeeping.prototype.destructor = function () { + this.result = null; + this.keyPrefix = null; + this.func = null; + this.context = null; + this.count = 0; +}; +PooledClass.addPoolingTo(MapBookKeeping, fourArgumentPooler); + +function mapSingleChildIntoContext(bookKeeping, child, childKey) { + var result = bookKeeping.result, + keyPrefix = bookKeeping.keyPrefix, + func = bookKeeping.func, + context = bookKeeping.context; + + + var mappedChild = func.call(context, child, bookKeeping.count++); + if (Array.isArray(mappedChild)) { + mapIntoWithKeyPrefixInternal(mappedChild, result, childKey, emptyFunction.thatReturnsArgument); + } else if (mappedChild != null) { + if (ReactElement.isValidElement(mappedChild)) { + mappedChild = ReactElement.cloneAndReplaceKey(mappedChild, + // Keep both the (mapped) and old keys if they differ, just as + // traverseAllChildren used to do for objects as children + keyPrefix + (mappedChild.key && (!child || child.key !== mappedChild.key) ? escapeUserProvidedKey(mappedChild.key) + '/' : '') + childKey); + } + result.push(mappedChild); + } +} + +function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) { + var escapedPrefix = ''; + if (prefix != null) { + escapedPrefix = escapeUserProvidedKey(prefix) + '/'; + } + var traverseContext = MapBookKeeping.getPooled(array, escapedPrefix, func, context); + traverseAllChildren(children, mapSingleChildIntoContext, traverseContext); + MapBookKeeping.release(traverseContext); +} + +/** + * Maps children that are typically specified as `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.map + * + * The provided mapFunction(child, key, index) will be called for each + * leaf child. + * + * @param {?*} children Children tree container. + * @param {function(*, int)} func The map function. + * @param {*} context Context for mapFunction. + * @return {object} Object containing the ordered map of results. + */ +function mapChildren(children, func, context) { + if (children == null) { + return children; + } + var result = []; + mapIntoWithKeyPrefixInternal(children, result, null, func, context); + return result; +} + +function forEachSingleChildDummy(traverseContext, child, name) { + return null; +} + +/** + * Count the number of children that are typically specified as + * `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.count + * + * @param {?*} children Children tree container. + * @return {number} The number of children. + */ +function countChildren(children, context) { + return traverseAllChildren(children, forEachSingleChildDummy, null); +} + +/** + * Flatten a children object (typically specified as `props.children`) and + * return an array with appropriately re-keyed children. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.toarray + */ +function toArray(children) { + var result = []; + mapIntoWithKeyPrefixInternal(children, result, null, emptyFunction.thatReturnsArgument); + return result; +} + +var ReactChildren = { + forEach: forEachChildren, + map: mapChildren, + mapIntoWithKeyPrefixInternal: mapIntoWithKeyPrefixInternal, + count: countChildren, + toArray: toArray +}; + +module.exports = ReactChildren; + +/***/ }), +/* 217 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(37); + +var invariant = __webpack_require__(2); + +/** + * Static poolers. Several custom versions for each potential number of + * arguments. A completely generic pooler is easy to implement, but would + * require accessing the `arguments` object. In each of these, `this` refers to + * the Class itself, not an instance. If any others are needed, simply add them + * here, or in their own files. + */ +var oneArgumentPooler = function (copyFieldsFrom) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, copyFieldsFrom); + return instance; + } else { + return new Klass(copyFieldsFrom); + } +}; + +var twoArgumentPooler = function (a1, a2) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2); + return instance; + } else { + return new Klass(a1, a2); + } +}; + +var threeArgumentPooler = function (a1, a2, a3) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3); + return instance; + } else { + return new Klass(a1, a2, a3); + } +}; + +var fourArgumentPooler = function (a1, a2, a3, a4) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3, a4); + return instance; + } else { + return new Klass(a1, a2, a3, a4); + } +}; + +var standardReleaser = function (instance) { + var Klass = this; + !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; + instance.destructor(); + if (Klass.instancePool.length < Klass.poolSize) { + Klass.instancePool.push(instance); + } +}; + +var DEFAULT_POOL_SIZE = 10; +var DEFAULT_POOLER = oneArgumentPooler; + +/** + * Augments `CopyConstructor` to be a poolable class, augmenting only the class + * itself (statically) not adding any prototypical fields. Any CopyConstructor + * you give this may have a `poolSize` property, and will look for a + * prototypical `destructor` on instances. + * + * @param {Function} CopyConstructor Constructor that can be used to reset. + * @param {Function} pooler Customizable pooler. + */ +var addPoolingTo = function (CopyConstructor, pooler) { + // Casting as any so that flow ignores the actual implementation and trusts + // it to match the type we declared + var NewKlass = CopyConstructor; + NewKlass.instancePool = []; + NewKlass.getPooled = pooler || DEFAULT_POOLER; + if (!NewKlass.poolSize) { + NewKlass.poolSize = DEFAULT_POOL_SIZE; + } + NewKlass.release = standardReleaser; + return NewKlass; +}; + +var PooledClass = { + addPoolingTo: addPoolingTo, + oneArgumentPooler: oneArgumentPooler, + twoArgumentPooler: twoArgumentPooler, + threeArgumentPooler: threeArgumentPooler, + fourArgumentPooler: fourArgumentPooler +}; + +module.exports = PooledClass; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 218 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(37); + +var ReactCurrentOwner = __webpack_require__(22); +var REACT_ELEMENT_TYPE = __webpack_require__(121); + +var getIteratorFn = __webpack_require__(122); +var invariant = __webpack_require__(2); +var KeyEscapeUtils = __webpack_require__(219); +var warning = __webpack_require__(3); + +var SEPARATOR = '.'; +var SUBSEPARATOR = ':'; + +/** + * This is inlined from ReactElement since this file is shared between + * isomorphic and renderers. We could extract this to a + * + */ + +/** + * TODO: Test that a single child and an array with one item have the same key + * pattern. + */ + +var didWarnAboutMaps = false; + +/** + * Generate a key string that identifies a component within a set. + * + * @param {*} component A component that could contain a manual key. + * @param {number} index Index that is used if a manual key is not provided. + * @return {string} + */ +function getComponentKey(component, index) { + // Do some typechecking here since we call this blindly. We want to ensure + // that we don't block potential future ES APIs. + if (component && typeof component === 'object' && component.key != null) { + // Explicit key + return KeyEscapeUtils.escape(component.key); + } + // Implicit key determined by the index in the set + return index.toString(36); +} + +/** + * @param {?*} children Children tree container. + * @param {!string} nameSoFar Name of the key path so far. + * @param {!function} callback Callback to invoke with each child found. + * @param {?*} traverseContext Used to pass information throughout the traversal + * process. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { + var type = typeof children; + + if (type === 'undefined' || type === 'boolean') { + // All of the above are perceived as null. + children = null; + } + + if (children === null || type === 'string' || type === 'number' || + // The following is inlined from ReactElement. This means we can optimize + // some checks. React Fiber also inlines this logic for similar purposes. + type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { + callback(traverseContext, children, + // If it's the only child, treat the name as if it was wrapped in an array + // so that it's consistent if the number of children grows. + nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); + return 1; + } + + var child; + var nextName; + var subtreeCount = 0; // Count of children found in the current subtree. + var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; + + if (Array.isArray(children)) { + for (var i = 0; i < children.length; i++) { + child = children[i]; + nextName = nextNamePrefix + getComponentKey(child, i); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + var iteratorFn = getIteratorFn(children); + if (iteratorFn) { + var iterator = iteratorFn.call(children); + var step; + if (iteratorFn !== children.entries) { + var ii = 0; + while (!(step = iterator.next()).done) { + child = step.value; + nextName = nextNamePrefix + getComponentKey(child, ii++); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + if (process.env.NODE_ENV !== 'production') { + var mapsAsChildrenAddendum = ''; + if (ReactCurrentOwner.current) { + var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); + if (mapsAsChildrenOwnerName) { + mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; + } + } + process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; + didWarnAboutMaps = true; + } + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + child = entry[1]; + nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } + } + } else if (type === 'object') { + var addendum = ''; + if (process.env.NODE_ENV !== 'production') { + addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; + if (children._isReactElement) { + addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; + } + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + addendum += ' Check the render method of `' + name + '`.'; + } + } + } + var childrenString = String(children); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; + } + } + + return subtreeCount; +} + +/** + * Traverses children that are typically specified as `props.children`, but + * might also be specified through attributes: + * + * - `traverseAllChildren(this.props.children, ...)` + * - `traverseAllChildren(this.props.leftPanelChildren, ...)` + * + * The `traverseContext` is an optional argument that is passed through the + * entire traversal. It can be used to store accumulations or anything else that + * the callback might find relevant. + * + * @param {?*} children Children tree object. + * @param {!function} callback To invoke upon traversing each child. + * @param {?*} traverseContext Context for traversal. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildren(children, callback, traverseContext) { + if (children == null) { + return 0; + } + + return traverseAllChildrenImpl(children, '', callback, traverseContext); +} + +module.exports = traverseAllChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 219 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/** + * Escape and wrap key so it is safe to use as a reactid + * + * @param {string} key to be escaped. + * @return {string} the escaped key. + */ + +function escape(key) { + var escapeRegex = /[=:]/g; + var escaperLookup = { + '=': '=0', + ':': '=2' + }; + var escapedString = ('' + key).replace(escapeRegex, function (match) { + return escaperLookup[match]; + }); + + return '$' + escapedString; +} + +/** + * Unescape and unwrap key for human-readable display + * + * @param {string} key to unescape. + * @return {string} the unescaped key. + */ +function unescape(key) { + var unescapeRegex = /(=0|=2)/g; + var unescaperLookup = { + '=0': '=', + '=2': ':' + }; + var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); + + return ('' + keySubstring).replace(unescapeRegex, function (match) { + return unescaperLookup[match]; + }); +} + +var KeyEscapeUtils = { + escape: escape, + unescape: unescape +}; + +module.exports = KeyEscapeUtils; + +/***/ }), +/* 220 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactElement = __webpack_require__(31); + +/** + * Create a factory that creates HTML tag elements. + * + * @private + */ +var createDOMFactory = ReactElement.createFactory; +if (process.env.NODE_ENV !== 'production') { + var ReactElementValidator = __webpack_require__(123); + createDOMFactory = ReactElementValidator.createFactory; +} + +/** + * Creates a mapping from supported HTML tags to `ReactDOMComponent` classes. + * + * @public + */ +var ReactDOMFactories = { + a: createDOMFactory('a'), + abbr: createDOMFactory('abbr'), + address: createDOMFactory('address'), + area: createDOMFactory('area'), + article: createDOMFactory('article'), + aside: createDOMFactory('aside'), + audio: createDOMFactory('audio'), + b: createDOMFactory('b'), + base: createDOMFactory('base'), + bdi: createDOMFactory('bdi'), + bdo: createDOMFactory('bdo'), + big: createDOMFactory('big'), + blockquote: createDOMFactory('blockquote'), + body: createDOMFactory('body'), + br: createDOMFactory('br'), + button: createDOMFactory('button'), + canvas: createDOMFactory('canvas'), + caption: createDOMFactory('caption'), + cite: createDOMFactory('cite'), + code: createDOMFactory('code'), + col: createDOMFactory('col'), + colgroup: createDOMFactory('colgroup'), + data: createDOMFactory('data'), + datalist: createDOMFactory('datalist'), + dd: createDOMFactory('dd'), + del: createDOMFactory('del'), + details: createDOMFactory('details'), + dfn: createDOMFactory('dfn'), + dialog: createDOMFactory('dialog'), + div: createDOMFactory('div'), + dl: createDOMFactory('dl'), + dt: createDOMFactory('dt'), + em: createDOMFactory('em'), + embed: createDOMFactory('embed'), + fieldset: createDOMFactory('fieldset'), + figcaption: createDOMFactory('figcaption'), + figure: createDOMFactory('figure'), + footer: createDOMFactory('footer'), + form: createDOMFactory('form'), + h1: createDOMFactory('h1'), + h2: createDOMFactory('h2'), + h3: createDOMFactory('h3'), + h4: createDOMFactory('h4'), + h5: createDOMFactory('h5'), + h6: createDOMFactory('h6'), + head: createDOMFactory('head'), + header: createDOMFactory('header'), + hgroup: createDOMFactory('hgroup'), + hr: createDOMFactory('hr'), + html: createDOMFactory('html'), + i: createDOMFactory('i'), + iframe: createDOMFactory('iframe'), + img: createDOMFactory('img'), + input: createDOMFactory('input'), + ins: createDOMFactory('ins'), + kbd: createDOMFactory('kbd'), + keygen: createDOMFactory('keygen'), + label: createDOMFactory('label'), + legend: createDOMFactory('legend'), + li: createDOMFactory('li'), + link: createDOMFactory('link'), + main: createDOMFactory('main'), + map: createDOMFactory('map'), + mark: createDOMFactory('mark'), + menu: createDOMFactory('menu'), + menuitem: createDOMFactory('menuitem'), + meta: createDOMFactory('meta'), + meter: createDOMFactory('meter'), + nav: createDOMFactory('nav'), + noscript: createDOMFactory('noscript'), + object: createDOMFactory('object'), + ol: createDOMFactory('ol'), + optgroup: createDOMFactory('optgroup'), + option: createDOMFactory('option'), + output: createDOMFactory('output'), + p: createDOMFactory('p'), + param: createDOMFactory('param'), + picture: createDOMFactory('picture'), + pre: createDOMFactory('pre'), + progress: createDOMFactory('progress'), + q: createDOMFactory('q'), + rp: createDOMFactory('rp'), + rt: createDOMFactory('rt'), + ruby: createDOMFactory('ruby'), + s: createDOMFactory('s'), + samp: createDOMFactory('samp'), + script: createDOMFactory('script'), + section: createDOMFactory('section'), + select: createDOMFactory('select'), + small: createDOMFactory('small'), + source: createDOMFactory('source'), + span: createDOMFactory('span'), + strong: createDOMFactory('strong'), + style: createDOMFactory('style'), + sub: createDOMFactory('sub'), + summary: createDOMFactory('summary'), + sup: createDOMFactory('sup'), + table: createDOMFactory('table'), + tbody: createDOMFactory('tbody'), + td: createDOMFactory('td'), + textarea: createDOMFactory('textarea'), + tfoot: createDOMFactory('tfoot'), + th: createDOMFactory('th'), + thead: createDOMFactory('thead'), + time: createDOMFactory('time'), + title: createDOMFactory('title'), + tr: createDOMFactory('tr'), + track: createDOMFactory('track'), + u: createDOMFactory('u'), + ul: createDOMFactory('ul'), + 'var': createDOMFactory('var'), + video: createDOMFactory('video'), + wbr: createDOMFactory('wbr'), + + // SVG + circle: createDOMFactory('circle'), + clipPath: createDOMFactory('clipPath'), + defs: createDOMFactory('defs'), + ellipse: createDOMFactory('ellipse'), + g: createDOMFactory('g'), + image: createDOMFactory('image'), + line: createDOMFactory('line'), + linearGradient: createDOMFactory('linearGradient'), + mask: createDOMFactory('mask'), + path: createDOMFactory('path'), + pattern: createDOMFactory('pattern'), + polygon: createDOMFactory('polygon'), + polyline: createDOMFactory('polyline'), + radialGradient: createDOMFactory('radialGradient'), + rect: createDOMFactory('rect'), + stop: createDOMFactory('stop'), + svg: createDOMFactory('svg'), + text: createDOMFactory('text'), + tspan: createDOMFactory('tspan') +}; + +module.exports = ReactDOMFactories; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 221 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(37); + +var ReactPropTypeLocationNames = __webpack_require__(222); +var ReactPropTypesSecret = __webpack_require__(223); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var ReactComponentTreeHook; + +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} + +var loggedTypeFailures = {}; + +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?object} element The React element that is being type-checked + * @param {?number} debugID The React component instance that is being type-checked + * @private + */ +function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var componentStackInfo = ''; + + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (debugID !== null) { + componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); + } else if (element !== null) { + componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); + } + } + + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; + } + } + } +} + +module.exports = checkReactTypeSpec; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 222 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactPropTypeLocationNames = {}; + +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} + +module.exports = ReactPropTypeLocationNames; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 223 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; + +module.exports = ReactPropTypesSecret; + +/***/ }), +/* 224 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _require = __webpack_require__(31), + isValidElement = _require.isValidElement; + +var factory = __webpack_require__(124); + +module.exports = factory(isValidElement); + +/***/ }), +/* 225 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +if (process.env.NODE_ENV !== 'production') { + var invariant = __webpack_require__(2); + var warning = __webpack_require__(3); + var ReactPropTypesSecret = __webpack_require__(75); + var loggedTypeFailures = {}; +} + +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?Function} getStack Returns the component stack. + * @private + */ +function checkPropTypes(typeSpecs, values, location, componentName, getStack) { + if (process.env.NODE_ENV !== 'production') { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + invariant(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', componentName || 'React class', location, typeSpecName); + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error); + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var stack = getStack ? getStack() : ''; + + warning(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : ''); + } + } + } + } +} + +module.exports = checkPropTypes; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 226 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +module.exports = '15.6.1'; + +/***/ }), +/* 227 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _require = __webpack_require__(119), + Component = _require.Component; + +var _require2 = __webpack_require__(31), + isValidElement = _require2.isValidElement; + +var ReactNoopUpdateQueue = __webpack_require__(120); +var factory = __webpack_require__(228); + +module.exports = factory(Component, isValidElement, ReactNoopUpdateQueue); + +/***/ }), +/* 228 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var emptyObject = __webpack_require__(56); +var _invariant = __webpack_require__(2); + +if (process.env.NODE_ENV !== 'production') { + var warning = __webpack_require__(3); +} + +var MIXINS_KEY = 'mixins'; + +// Helper function to allow the creation of anonymous functions which do not +// have .name set to the name of the variable being assigned to. +function identity(fn) { + return fn; +} + +var ReactPropTypeLocationNames; +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} else { + ReactPropTypeLocationNames = {}; +} + +function factory(ReactComponent, isValidElement, ReactNoopUpdateQueue) { + /** + * Policies that describe methods in `ReactClassInterface`. + */ + + var injectedMixins = []; + + /** + * Composite components are higher-level components that compose other composite + * or host components. + * + * To create a new type of `ReactClass`, pass a specification of + * your new class to `React.createClass`. The only requirement of your class + * specification is that you implement a `render` method. + * + * var MyComponent = React.createClass({ + * render: function() { + * return <div>Hello World</div>; + * } + * }); + * + * The class specification supports a specific protocol of methods that have + * special meaning (e.g. `render`). See `ReactClassInterface` for + * more the comprehensive protocol. Any other properties and methods in the + * class specification will be available on the prototype. + * + * @interface ReactClassInterface + * @internal + */ + var ReactClassInterface = { + /** + * An array of Mixin objects to include when defining your component. + * + * @type {array} + * @optional + */ + mixins: 'DEFINE_MANY', + + /** + * An object containing properties and methods that should be defined on + * the component's constructor instead of its prototype (static methods). + * + * @type {object} + * @optional + */ + statics: 'DEFINE_MANY', + + /** + * Definition of prop types for this component. + * + * @type {object} + * @optional + */ + propTypes: 'DEFINE_MANY', + + /** + * Definition of context types for this component. + * + * @type {object} + * @optional + */ + contextTypes: 'DEFINE_MANY', + + /** + * Definition of context types this component sets for its children. + * + * @type {object} + * @optional + */ + childContextTypes: 'DEFINE_MANY', + + // ==== Definition methods ==== + + /** + * Invoked when the component is mounted. Values in the mapping will be set on + * `this.props` if that prop is not specified (i.e. using an `in` check). + * + * This method is invoked before `getInitialState` and therefore cannot rely + * on `this.state` or use `this.setState`. + * + * @return {object} + * @optional + */ + getDefaultProps: 'DEFINE_MANY_MERGED', + + /** + * Invoked once before the component is mounted. The return value will be used + * as the initial value of `this.state`. + * + * getInitialState: function() { + * return { + * isOn: false, + * fooBaz: new BazFoo() + * } + * } + * + * @return {object} + * @optional + */ + getInitialState: 'DEFINE_MANY_MERGED', + + /** + * @return {object} + * @optional + */ + getChildContext: 'DEFINE_MANY_MERGED', + + /** + * Uses props from `this.props` and state from `this.state` to render the + * structure of the component. + * + * No guarantees are made about when or how often this method is invoked, so + * it must not have side effects. + * + * render: function() { + * var name = this.props.name; + * return <div>Hello, {name}!</div>; + * } + * + * @return {ReactComponent} + * @required + */ + render: 'DEFINE_ONCE', + + // ==== Delegate methods ==== + + /** + * Invoked when the component is initially created and about to be mounted. + * This may have side effects, but any external subscriptions or data created + * by this method must be cleaned up in `componentWillUnmount`. + * + * @optional + */ + componentWillMount: 'DEFINE_MANY', + + /** + * Invoked when the component has been mounted and has a DOM representation. + * However, there is no guarantee that the DOM node is in the document. + * + * Use this as an opportunity to operate on the DOM when the component has + * been mounted (initialized and rendered) for the first time. + * + * @param {DOMElement} rootNode DOM element representing the component. + * @optional + */ + componentDidMount: 'DEFINE_MANY', + + /** + * Invoked before the component receives new props. + * + * Use this as an opportunity to react to a prop transition by updating the + * state using `this.setState`. Current props are accessed via `this.props`. + * + * componentWillReceiveProps: function(nextProps, nextContext) { + * this.setState({ + * likesIncreasing: nextProps.likeCount > this.props.likeCount + * }); + * } + * + * NOTE: There is no equivalent `componentWillReceiveState`. An incoming prop + * transition may cause a state change, but the opposite is not true. If you + * need it, you are probably looking for `componentWillUpdate`. + * + * @param {object} nextProps + * @optional + */ + componentWillReceiveProps: 'DEFINE_MANY', + + /** + * Invoked while deciding if the component should be updated as a result of + * receiving new props, state and/or context. + * + * Use this as an opportunity to `return false` when you're certain that the + * transition to the new props/state/context will not require a component + * update. + * + * shouldComponentUpdate: function(nextProps, nextState, nextContext) { + * return !equal(nextProps, this.props) || + * !equal(nextState, this.state) || + * !equal(nextContext, this.context); + * } + * + * @param {object} nextProps + * @param {?object} nextState + * @param {?object} nextContext + * @return {boolean} True if the component should update. + * @optional + */ + shouldComponentUpdate: 'DEFINE_ONCE', + + /** + * Invoked when the component is about to update due to a transition from + * `this.props`, `this.state` and `this.context` to `nextProps`, `nextState` + * and `nextContext`. + * + * Use this as an opportunity to perform preparation before an update occurs. + * + * NOTE: You **cannot** use `this.setState()` in this method. + * + * @param {object} nextProps + * @param {?object} nextState + * @param {?object} nextContext + * @param {ReactReconcileTransaction} transaction + * @optional + */ + componentWillUpdate: 'DEFINE_MANY', + + /** + * Invoked when the component's DOM representation has been updated. + * + * Use this as an opportunity to operate on the DOM when the component has + * been updated. + * + * @param {object} prevProps + * @param {?object} prevState + * @param {?object} prevContext + * @param {DOMElement} rootNode DOM element representing the component. + * @optional + */ + componentDidUpdate: 'DEFINE_MANY', + + /** + * Invoked when the component is about to be removed from its parent and have + * its DOM representation destroyed. + * + * Use this as an opportunity to deallocate any external resources. + * + * NOTE: There is no `componentDidUnmount` since your component will have been + * destroyed by that point. + * + * @optional + */ + componentWillUnmount: 'DEFINE_MANY', + + // ==== Advanced methods ==== + + /** + * Updates the component's currently mounted DOM representation. + * + * By default, this implements React's rendering and reconciliation algorithm. + * Sophisticated clients may wish to override this. + * + * @param {ReactReconcileTransaction} transaction + * @internal + * @overridable + */ + updateComponent: 'OVERRIDE_BASE' + }; + + /** + * Mapping from class specification keys to special processing functions. + * + * Although these are declared like instance properties in the specification + * when defining classes using `React.createClass`, they are actually static + * and are accessible on the constructor instead of the prototype. Despite + * being static, they must be defined outside of the "statics" key under + * which all other static methods are defined. + */ + var RESERVED_SPEC_KEYS = { + displayName: function(Constructor, displayName) { + Constructor.displayName = displayName; + }, + mixins: function(Constructor, mixins) { + if (mixins) { + for (var i = 0; i < mixins.length; i++) { + mixSpecIntoComponent(Constructor, mixins[i]); + } + } + }, + childContextTypes: function(Constructor, childContextTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, childContextTypes, 'childContext'); + } + Constructor.childContextTypes = _assign( + {}, + Constructor.childContextTypes, + childContextTypes + ); + }, + contextTypes: function(Constructor, contextTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, contextTypes, 'context'); + } + Constructor.contextTypes = _assign( + {}, + Constructor.contextTypes, + contextTypes + ); + }, + /** + * Special case getDefaultProps which should move into statics but requires + * automatic merging. + */ + getDefaultProps: function(Constructor, getDefaultProps) { + if (Constructor.getDefaultProps) { + Constructor.getDefaultProps = createMergedResultFunction( + Constructor.getDefaultProps, + getDefaultProps + ); + } else { + Constructor.getDefaultProps = getDefaultProps; + } + }, + propTypes: function(Constructor, propTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, propTypes, 'prop'); + } + Constructor.propTypes = _assign({}, Constructor.propTypes, propTypes); + }, + statics: function(Constructor, statics) { + mixStaticSpecIntoComponent(Constructor, statics); + }, + autobind: function() {} + }; + + function validateTypeDef(Constructor, typeDef, location) { + for (var propName in typeDef) { + if (typeDef.hasOwnProperty(propName)) { + // use a warning instead of an _invariant so components + // don't show up in prod but only in __DEV__ + if (process.env.NODE_ENV !== 'production') { + warning( + typeof typeDef[propName] === 'function', + '%s: %s type `%s` is invalid; it must be a function, usually from ' + + 'React.PropTypes.', + Constructor.displayName || 'ReactClass', + ReactPropTypeLocationNames[location], + propName + ); + } + } + } + } + + function validateMethodOverride(isAlreadyDefined, name) { + var specPolicy = ReactClassInterface.hasOwnProperty(name) + ? ReactClassInterface[name] + : null; + + // Disallow overriding of base class methods unless explicitly allowed. + if (ReactClassMixin.hasOwnProperty(name)) { + _invariant( + specPolicy === 'OVERRIDE_BASE', + 'ReactClassInterface: You are attempting to override ' + + '`%s` from your class specification. Ensure that your method names ' + + 'do not overlap with React methods.', + name + ); + } + + // Disallow defining methods more than once unless explicitly allowed. + if (isAlreadyDefined) { + _invariant( + specPolicy === 'DEFINE_MANY' || specPolicy === 'DEFINE_MANY_MERGED', + 'ReactClassInterface: You are attempting to define ' + + '`%s` on your component more than once. This conflict may be due ' + + 'to a mixin.', + name + ); + } + } + + /** + * Mixin helper which handles policy validation and reserved + * specification keys when building React classes. + */ + function mixSpecIntoComponent(Constructor, spec) { + if (!spec) { + if (process.env.NODE_ENV !== 'production') { + var typeofSpec = typeof spec; + var isMixinValid = typeofSpec === 'object' && spec !== null; + + if (process.env.NODE_ENV !== 'production') { + warning( + isMixinValid, + "%s: You're attempting to include a mixin that is either null " + + 'or not an object. Check the mixins included by the component, ' + + 'as well as any mixins they include themselves. ' + + 'Expected object but got %s.', + Constructor.displayName || 'ReactClass', + spec === null ? null : typeofSpec + ); + } + } + + return; + } + + _invariant( + typeof spec !== 'function', + "ReactClass: You're attempting to " + + 'use a component class or function as a mixin. Instead, just use a ' + + 'regular object.' + ); + _invariant( + !isValidElement(spec), + "ReactClass: You're attempting to " + + 'use a component as a mixin. Instead, just use a regular object.' + ); + + var proto = Constructor.prototype; + var autoBindPairs = proto.__reactAutoBindPairs; + + // By handling mixins before any other properties, we ensure the same + // chaining order is applied to methods with DEFINE_MANY policy, whether + // mixins are listed before or after these methods in the spec. + if (spec.hasOwnProperty(MIXINS_KEY)) { + RESERVED_SPEC_KEYS.mixins(Constructor, spec.mixins); + } + + for (var name in spec) { + if (!spec.hasOwnProperty(name)) { + continue; + } + + if (name === MIXINS_KEY) { + // We have already handled mixins in a special case above. + continue; + } + + var property = spec[name]; + var isAlreadyDefined = proto.hasOwnProperty(name); + validateMethodOverride(isAlreadyDefined, name); + + if (RESERVED_SPEC_KEYS.hasOwnProperty(name)) { + RESERVED_SPEC_KEYS[name](Constructor, property); + } else { + // Setup methods on prototype: + // The following member methods should not be automatically bound: + // 1. Expected ReactClass methods (in the "interface"). + // 2. Overridden methods (that were mixed in). + var isReactClassMethod = ReactClassInterface.hasOwnProperty(name); + var isFunction = typeof property === 'function'; + var shouldAutoBind = + isFunction && + !isReactClassMethod && + !isAlreadyDefined && + spec.autobind !== false; + + if (shouldAutoBind) { + autoBindPairs.push(name, property); + proto[name] = property; + } else { + if (isAlreadyDefined) { + var specPolicy = ReactClassInterface[name]; + + // These cases should already be caught by validateMethodOverride. + _invariant( + isReactClassMethod && + (specPolicy === 'DEFINE_MANY_MERGED' || + specPolicy === 'DEFINE_MANY'), + 'ReactClass: Unexpected spec policy %s for key %s ' + + 'when mixing in component specs.', + specPolicy, + name + ); + + // For methods which are defined more than once, call the existing + // methods before calling the new property, merging if appropriate. + if (specPolicy === 'DEFINE_MANY_MERGED') { + proto[name] = createMergedResultFunction(proto[name], property); + } else if (specPolicy === 'DEFINE_MANY') { + proto[name] = createChainedFunction(proto[name], property); + } + } else { + proto[name] = property; + if (process.env.NODE_ENV !== 'production') { + // Add verbose displayName to the function, which helps when looking + // at profiling tools. + if (typeof property === 'function' && spec.displayName) { + proto[name].displayName = spec.displayName + '_' + name; + } + } + } + } + } + } + } + + function mixStaticSpecIntoComponent(Constructor, statics) { + if (!statics) { + return; + } + for (var name in statics) { + var property = statics[name]; + if (!statics.hasOwnProperty(name)) { + continue; + } + + var isReserved = name in RESERVED_SPEC_KEYS; + _invariant( + !isReserved, + 'ReactClass: You are attempting to define a reserved ' + + 'property, `%s`, that shouldn\'t be on the "statics" key. Define it ' + + 'as an instance property instead; it will still be accessible on the ' + + 'constructor.', + name + ); + + var isInherited = name in Constructor; + _invariant( + !isInherited, + 'ReactClass: You are attempting to define ' + + '`%s` on your component more than once. This conflict may be ' + + 'due to a mixin.', + name + ); + Constructor[name] = property; + } + } + + /** + * Merge two objects, but throw if both contain the same key. + * + * @param {object} one The first object, which is mutated. + * @param {object} two The second object + * @return {object} one after it has been mutated to contain everything in two. + */ + function mergeIntoWithNoDuplicateKeys(one, two) { + _invariant( + one && two && typeof one === 'object' && typeof two === 'object', + 'mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.' + ); + + for (var key in two) { + if (two.hasOwnProperty(key)) { + _invariant( + one[key] === undefined, + 'mergeIntoWithNoDuplicateKeys(): ' + + 'Tried to merge two objects with the same key: `%s`. This conflict ' + + 'may be due to a mixin; in particular, this may be caused by two ' + + 'getInitialState() or getDefaultProps() methods returning objects ' + + 'with clashing keys.', + key + ); + one[key] = two[key]; + } + } + return one; + } + + /** + * Creates a function that invokes two functions and merges their return values. + * + * @param {function} one Function to invoke first. + * @param {function} two Function to invoke second. + * @return {function} Function that invokes the two argument functions. + * @private + */ + function createMergedResultFunction(one, two) { + return function mergedResult() { + var a = one.apply(this, arguments); + var b = two.apply(this, arguments); + if (a == null) { + return b; + } else if (b == null) { + return a; + } + var c = {}; + mergeIntoWithNoDuplicateKeys(c, a); + mergeIntoWithNoDuplicateKeys(c, b); + return c; + }; + } + + /** + * Creates a function that invokes two functions and ignores their return vales. + * + * @param {function} one Function to invoke first. + * @param {function} two Function to invoke second. + * @return {function} Function that invokes the two argument functions. + * @private + */ + function createChainedFunction(one, two) { + return function chainedFunction() { + one.apply(this, arguments); + two.apply(this, arguments); + }; + } + + /** + * Binds a method to the component. + * + * @param {object} component Component whose method is going to be bound. + * @param {function} method Method to be bound. + * @return {function} The bound method. + */ + function bindAutoBindMethod(component, method) { + var boundMethod = method.bind(component); + if (process.env.NODE_ENV !== 'production') { + boundMethod.__reactBoundContext = component; + boundMethod.__reactBoundMethod = method; + boundMethod.__reactBoundArguments = null; + var componentName = component.constructor.displayName; + var _bind = boundMethod.bind; + boundMethod.bind = function(newThis) { + for ( + var _len = arguments.length, + args = Array(_len > 1 ? _len - 1 : 0), + _key = 1; + _key < _len; + _key++ + ) { + args[_key - 1] = arguments[_key]; + } + + // User is trying to bind() an autobound method; we effectively will + // ignore the value of "this" that the user is trying to use, so + // let's warn. + if (newThis !== component && newThis !== null) { + if (process.env.NODE_ENV !== 'production') { + warning( + false, + 'bind(): React component methods may only be bound to the ' + + 'component instance. See %s', + componentName + ); + } + } else if (!args.length) { + if (process.env.NODE_ENV !== 'production') { + warning( + false, + 'bind(): You are binding a component method to the component. ' + + 'React does this for you automatically in a high-performance ' + + 'way, so you can safely remove this call. See %s', + componentName + ); + } + return boundMethod; + } + var reboundMethod = _bind.apply(boundMethod, arguments); + reboundMethod.__reactBoundContext = component; + reboundMethod.__reactBoundMethod = method; + reboundMethod.__reactBoundArguments = args; + return reboundMethod; + }; + } + return boundMethod; + } + + /** + * Binds all auto-bound methods in a component. + * + * @param {object} component Component whose method is going to be bound. + */ + function bindAutoBindMethods(component) { + var pairs = component.__reactAutoBindPairs; + for (var i = 0; i < pairs.length; i += 2) { + var autoBindKey = pairs[i]; + var method = pairs[i + 1]; + component[autoBindKey] = bindAutoBindMethod(component, method); + } + } + + var IsMountedPreMixin = { + componentDidMount: function() { + this.__isMounted = true; + } + }; + + var IsMountedPostMixin = { + componentWillUnmount: function() { + this.__isMounted = false; + } + }; + + /** + * Add more to the ReactClass base class. These are all legacy features and + * therefore not already part of the modern ReactComponent. + */ + var ReactClassMixin = { + /** + * TODO: This will be deprecated because state should always keep a consistent + * type signature and the only use case for this, is to avoid that. + */ + replaceState: function(newState, callback) { + this.updater.enqueueReplaceState(this, newState, callback); + }, + + /** + * Checks whether or not this composite component is mounted. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + isMounted: function() { + if (process.env.NODE_ENV !== 'production') { + warning( + this.__didWarnIsMounted, + '%s: isMounted is deprecated. Instead, make sure to clean up ' + + 'subscriptions and pending requests in componentWillUnmount to ' + + 'prevent memory leaks.', + (this.constructor && this.constructor.displayName) || + this.name || + 'Component' + ); + this.__didWarnIsMounted = true; + } + return !!this.__isMounted; + } + }; + + var ReactClassComponent = function() {}; + _assign( + ReactClassComponent.prototype, + ReactComponent.prototype, + ReactClassMixin + ); + + /** + * Creates a composite component class given a class specification. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createclass + * + * @param {object} spec Class specification (which must define `render`). + * @return {function} Component constructor function. + * @public + */ + function createClass(spec) { + // To keep our warnings more understandable, we'll use a little hack here to + // ensure that Constructor.name !== 'Constructor'. This makes sure we don't + // unnecessarily identify a class without displayName as 'Constructor'. + var Constructor = identity(function(props, context, updater) { + // This constructor gets overridden by mocks. The argument is used + // by mocks to assert on what gets mounted. + + if (process.env.NODE_ENV !== 'production') { + warning( + this instanceof Constructor, + 'Something is calling a React component directly. Use a factory or ' + + 'JSX instead. See: https://fb.me/react-legacyfactory' + ); + } + + // Wire up auto-binding + if (this.__reactAutoBindPairs.length) { + bindAutoBindMethods(this); + } + + this.props = props; + this.context = context; + this.refs = emptyObject; + this.updater = updater || ReactNoopUpdateQueue; + + this.state = null; + + // ReactClasses doesn't have constructors. Instead, they use the + // getInitialState and componentWillMount methods for initialization. + + var initialState = this.getInitialState ? this.getInitialState() : null; + if (process.env.NODE_ENV !== 'production') { + // We allow auto-mocks to proceed as if they're returning null. + if ( + initialState === undefined && + this.getInitialState._isMockFunction + ) { + // This is probably bad practice. Consider warning here and + // deprecating this convenience. + initialState = null; + } + } + _invariant( + typeof initialState === 'object' && !Array.isArray(initialState), + '%s.getInitialState(): must return an object or null', + Constructor.displayName || 'ReactCompositeComponent' + ); + + this.state = initialState; + }); + Constructor.prototype = new ReactClassComponent(); + Constructor.prototype.constructor = Constructor; + Constructor.prototype.__reactAutoBindPairs = []; + + injectedMixins.forEach(mixSpecIntoComponent.bind(null, Constructor)); + + mixSpecIntoComponent(Constructor, IsMountedPreMixin); + mixSpecIntoComponent(Constructor, spec); + mixSpecIntoComponent(Constructor, IsMountedPostMixin); + + // Initialize the defaultProps property after all mixins have been merged. + if (Constructor.getDefaultProps) { + Constructor.defaultProps = Constructor.getDefaultProps(); + } + + if (process.env.NODE_ENV !== 'production') { + // This is a tag to indicate that the use of these method names is ok, + // since it's used with createClass. If it's not, then it's likely a + // mistake so we'll warn you to use the static property, property + // initializer or constructor respectively. + if (Constructor.getDefaultProps) { + Constructor.getDefaultProps.isReactClassApproved = {}; + } + if (Constructor.prototype.getInitialState) { + Constructor.prototype.getInitialState.isReactClassApproved = {}; + } + } + + _invariant( + Constructor.prototype.render, + 'createClass(...): Class specification must implement a `render` method.' + ); + + if (process.env.NODE_ENV !== 'production') { + warning( + !Constructor.prototype.componentShouldUpdate, + '%s has a method called ' + + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + + 'The name is phrased as a question because the function is ' + + 'expected to return a value.', + spec.displayName || 'A component' + ); + warning( + !Constructor.prototype.componentWillRecieveProps, + '%s has a method called ' + + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', + spec.displayName || 'A component' + ); + } + + // Reduce time spent doing lookups by setting these on the prototype. + for (var methodName in ReactClassInterface) { + if (!Constructor.prototype[methodName]) { + Constructor.prototype[methodName] = null; + } + } + + return Constructor; + } + + return createClass; +} + +module.exports = factory; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 229 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + +var _prodInvariant = __webpack_require__(37); + +var ReactElement = __webpack_require__(31); + +var invariant = __webpack_require__(2); + +/** + * Returns the first child in a collection of children and verifies that there + * is only one child in the collection. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.only + * + * The current implementation of this function assumes that a single child gets + * passed without a wrapper, but the purpose of this helper function is to + * abstract away the particular structure of children. + * + * @param {?object} children Child collection structure. + * @return {ReactElement} The first and only `ReactElement` contained in the + * structure. + */ +function onlyChild(children) { + !ReactElement.isValidElement(children) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React.Children.only expected to receive a single React element child.') : _prodInvariant('143') : void 0; + return children; +} + +module.exports = onlyChild; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 230 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/* globals __REACT_DEVTOOLS_GLOBAL_HOOK__*/ + + + +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDefaultInjection = __webpack_require__(231); +var ReactMount = __webpack_require__(149); +var ReactReconciler = __webpack_require__(38); +var ReactUpdates = __webpack_require__(23); +var ReactVersion = __webpack_require__(309); + +var findDOMNode = __webpack_require__(310); +var getHostComponentFromComposite = __webpack_require__(150); +var renderSubtreeIntoContainer = __webpack_require__(311); +var warning = __webpack_require__(3); + +ReactDefaultInjection.inject(); + +var ReactDOM = { + findDOMNode: findDOMNode, + render: ReactMount.render, + unmountComponentAtNode: ReactMount.unmountComponentAtNode, + version: ReactVersion, + + /* eslint-disable camelcase */ + unstable_batchedUpdates: ReactUpdates.batchedUpdates, + unstable_renderSubtreeIntoContainer: renderSubtreeIntoContainer + /* eslint-enable camelcase */ +}; + +// Inject the runtime into a devtools global hook regardless of browser. +// Allows for debugging when the hook is injected on the page. +if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject === 'function') { + __REACT_DEVTOOLS_GLOBAL_HOOK__.inject({ + ComponentTree: { + getClosestInstanceFromNode: ReactDOMComponentTree.getClosestInstanceFromNode, + getNodeFromInstance: function (inst) { + // inst is an internal instance (but could be a composite) + if (inst._renderedComponent) { + inst = getHostComponentFromComposite(inst); + } + if (inst) { + return ReactDOMComponentTree.getNodeFromInstance(inst); + } else { + return null; + } + } + }, + Mount: ReactMount, + Reconciler: ReactReconciler + }); +} + +if (process.env.NODE_ENV !== 'production') { + var ExecutionEnvironment = __webpack_require__(13); + if (ExecutionEnvironment.canUseDOM && window.top === window.self) { + // First check if devtools is not installed + if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined') { + // If we're in Chrome or Firefox, provide a download link if not installed. + if (navigator.userAgent.indexOf('Chrome') > -1 && navigator.userAgent.indexOf('Edge') === -1 || navigator.userAgent.indexOf('Firefox') > -1) { + // Firefox does not have the issue with devtools loaded over file:// + var showFileUrlMessage = window.location.protocol.indexOf('http') === -1 && navigator.userAgent.indexOf('Firefox') === -1; + console.debug('Download the React DevTools ' + (showFileUrlMessage ? 'and use an HTTP server (instead of a file: URL) ' : '') + 'for a better development experience: ' + 'https://fb.me/react-devtools'); + } + } + + var testFunc = function testFn() {}; + process.env.NODE_ENV !== 'production' ? warning((testFunc.name || testFunc.toString()).indexOf('testFn') !== -1, "It looks like you're using a minified copy of the development build " + 'of React. When deploying React apps to production, make sure to use ' + 'the production build which skips development warnings and is faster. ' + 'See https://fb.me/react-minification for more details.') : void 0; + + // If we're in IE8, check to see if we are in compatibility mode and provide + // information on preventing compatibility mode + var ieCompatibilityMode = document.documentMode && document.documentMode < 8; + + process.env.NODE_ENV !== 'production' ? warning(!ieCompatibilityMode, 'Internet Explorer is running in compatibility mode; please add the ' + 'following tag to your HTML to prevent this from happening: ' + '<meta http-equiv="X-UA-Compatible" content="IE=edge" />') : void 0; + + var expectedFeatures = [ + // shims + Array.isArray, Array.prototype.every, Array.prototype.forEach, Array.prototype.indexOf, Array.prototype.map, Date.now, Function.prototype.bind, Object.keys, String.prototype.trim]; + + for (var i = 0; i < expectedFeatures.length; i++) { + if (!expectedFeatures[i]) { + process.env.NODE_ENV !== 'production' ? warning(false, 'One or more ES5 shims expected by React are not available: ' + 'https://fb.me/react-warning-polyfills') : void 0; + break; + } + } + } +} + +if (process.env.NODE_ENV !== 'production') { + var ReactInstrumentation = __webpack_require__(19); + var ReactDOMUnknownPropertyHook = __webpack_require__(312); + var ReactDOMNullInputValuePropHook = __webpack_require__(313); + var ReactDOMInvalidARIAHook = __webpack_require__(314); + + ReactInstrumentation.debugTool.addHook(ReactDOMUnknownPropertyHook); + ReactInstrumentation.debugTool.addHook(ReactDOMNullInputValuePropHook); + ReactInstrumentation.debugTool.addHook(ReactDOMInvalidARIAHook); +} + +module.exports = ReactDOM; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 231 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ARIADOMPropertyConfig = __webpack_require__(232); +var BeforeInputEventPlugin = __webpack_require__(233); +var ChangeEventPlugin = __webpack_require__(237); +var DefaultEventPluginOrder = __webpack_require__(245); +var EnterLeaveEventPlugin = __webpack_require__(246); +var HTMLDOMPropertyConfig = __webpack_require__(247); +var ReactComponentBrowserEnvironment = __webpack_require__(248); +var ReactDOMComponent = __webpack_require__(254); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMEmptyComponent = __webpack_require__(280); +var ReactDOMTreeTraversal = __webpack_require__(281); +var ReactDOMTextComponent = __webpack_require__(282); +var ReactDefaultBatchingStrategy = __webpack_require__(283); +var ReactEventListener = __webpack_require__(284); +var ReactInjection = __webpack_require__(286); +var ReactReconcileTransaction = __webpack_require__(287); +var SVGDOMPropertyConfig = __webpack_require__(293); +var SelectEventPlugin = __webpack_require__(294); +var SimpleEventPlugin = __webpack_require__(295); + +var alreadyInjected = false; + +function inject() { + if (alreadyInjected) { + // TODO: This is currently true because these injections are shared between + // the client and the server package. They should be built independently + // and not share any injection state. Then this problem will be solved. + return; + } + alreadyInjected = true; + + ReactInjection.EventEmitter.injectReactEventListener(ReactEventListener); + + /** + * Inject modules for resolving DOM hierarchy and plugin ordering. + */ + ReactInjection.EventPluginHub.injectEventPluginOrder(DefaultEventPluginOrder); + ReactInjection.EventPluginUtils.injectComponentTree(ReactDOMComponentTree); + ReactInjection.EventPluginUtils.injectTreeTraversal(ReactDOMTreeTraversal); + + /** + * Some important event plugins included by default (without having to require + * them). + */ + ReactInjection.EventPluginHub.injectEventPluginsByName({ + SimpleEventPlugin: SimpleEventPlugin, + EnterLeaveEventPlugin: EnterLeaveEventPlugin, + ChangeEventPlugin: ChangeEventPlugin, + SelectEventPlugin: SelectEventPlugin, + BeforeInputEventPlugin: BeforeInputEventPlugin + }); + + ReactInjection.HostComponent.injectGenericComponentClass(ReactDOMComponent); + + ReactInjection.HostComponent.injectTextComponentClass(ReactDOMTextComponent); + + ReactInjection.DOMProperty.injectDOMPropertyConfig(ARIADOMPropertyConfig); + ReactInjection.DOMProperty.injectDOMPropertyConfig(HTMLDOMPropertyConfig); + ReactInjection.DOMProperty.injectDOMPropertyConfig(SVGDOMPropertyConfig); + + ReactInjection.EmptyComponent.injectEmptyComponentFactory(function (instantiate) { + return new ReactDOMEmptyComponent(instantiate); + }); + + ReactInjection.Updates.injectReconcileTransaction(ReactReconcileTransaction); + ReactInjection.Updates.injectBatchingStrategy(ReactDefaultBatchingStrategy); + + ReactInjection.Component.injectEnvironment(ReactComponentBrowserEnvironment); +} + +module.exports = { + inject: inject +}; + +/***/ }), +/* 232 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ARIADOMPropertyConfig = { + Properties: { + // Global States and Properties + 'aria-current': 0, // state + 'aria-details': 0, + 'aria-disabled': 0, // state + 'aria-hidden': 0, // state + 'aria-invalid': 0, // state + 'aria-keyshortcuts': 0, + 'aria-label': 0, + 'aria-roledescription': 0, + // Widget Attributes + 'aria-autocomplete': 0, + 'aria-checked': 0, + 'aria-expanded': 0, + 'aria-haspopup': 0, + 'aria-level': 0, + 'aria-modal': 0, + 'aria-multiline': 0, + 'aria-multiselectable': 0, + 'aria-orientation': 0, + 'aria-placeholder': 0, + 'aria-pressed': 0, + 'aria-readonly': 0, + 'aria-required': 0, + 'aria-selected': 0, + 'aria-sort': 0, + 'aria-valuemax': 0, + 'aria-valuemin': 0, + 'aria-valuenow': 0, + 'aria-valuetext': 0, + // Live Region Attributes + 'aria-atomic': 0, + 'aria-busy': 0, + 'aria-live': 0, + 'aria-relevant': 0, + // Drag-and-Drop Attributes + 'aria-dropeffect': 0, + 'aria-grabbed': 0, + // Relationship Attributes + 'aria-activedescendant': 0, + 'aria-colcount': 0, + 'aria-colindex': 0, + 'aria-colspan': 0, + 'aria-controls': 0, + 'aria-describedby': 0, + 'aria-errormessage': 0, + 'aria-flowto': 0, + 'aria-labelledby': 0, + 'aria-owns': 0, + 'aria-posinset': 0, + 'aria-rowcount': 0, + 'aria-rowindex': 0, + 'aria-rowspan': 0, + 'aria-setsize': 0 + }, + DOMAttributeNames: {}, + DOMPropertyNames: {} +}; + +module.exports = ARIADOMPropertyConfig; + +/***/ }), +/* 233 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var FallbackCompositionState = __webpack_require__(234); +var SyntheticCompositionEvent = __webpack_require__(235); +var SyntheticInputEvent = __webpack_require__(236); + +var END_KEYCODES = [9, 13, 27, 32]; // Tab, Return, Esc, Space +var START_KEYCODE = 229; + +var canUseCompositionEvent = ExecutionEnvironment.canUseDOM && 'CompositionEvent' in window; + +var documentMode = null; +if (ExecutionEnvironment.canUseDOM && 'documentMode' in document) { + documentMode = document.documentMode; +} + +// Webkit offers a very useful `textInput` event that can be used to +// directly represent `beforeInput`. The IE `textinput` event is not as +// useful, so we don't use it. +var canUseTextInputEvent = ExecutionEnvironment.canUseDOM && 'TextEvent' in window && !documentMode && !isPresto(); + +// In IE9+, we have access to composition events, but the data supplied +// by the native compositionend event may be incorrect. Japanese ideographic +// spaces, for instance (\u3000) are not recorded correctly. +var useFallbackCompositionData = ExecutionEnvironment.canUseDOM && (!canUseCompositionEvent || documentMode && documentMode > 8 && documentMode <= 11); + +/** + * Opera <= 12 includes TextEvent in window, but does not fire + * text input events. Rely on keypress instead. + */ +function isPresto() { + var opera = window.opera; + return typeof opera === 'object' && typeof opera.version === 'function' && parseInt(opera.version(), 10) <= 12; +} + +var SPACEBAR_CODE = 32; +var SPACEBAR_CHAR = String.fromCharCode(SPACEBAR_CODE); + +// Events and their corresponding property names. +var eventTypes = { + beforeInput: { + phasedRegistrationNames: { + bubbled: 'onBeforeInput', + captured: 'onBeforeInputCapture' + }, + dependencies: ['topCompositionEnd', 'topKeyPress', 'topTextInput', 'topPaste'] + }, + compositionEnd: { + phasedRegistrationNames: { + bubbled: 'onCompositionEnd', + captured: 'onCompositionEndCapture' + }, + dependencies: ['topBlur', 'topCompositionEnd', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + }, + compositionStart: { + phasedRegistrationNames: { + bubbled: 'onCompositionStart', + captured: 'onCompositionStartCapture' + }, + dependencies: ['topBlur', 'topCompositionStart', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + }, + compositionUpdate: { + phasedRegistrationNames: { + bubbled: 'onCompositionUpdate', + captured: 'onCompositionUpdateCapture' + }, + dependencies: ['topBlur', 'topCompositionUpdate', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + } +}; + +// Track whether we've ever handled a keypress on the space key. +var hasSpaceKeypress = false; + +/** + * Return whether a native keypress event is assumed to be a command. + * This is required because Firefox fires `keypress` events for key commands + * (cut, copy, select-all, etc.) even though no character is inserted. + */ +function isKeypressCommand(nativeEvent) { + return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) && + // ctrlKey && altKey is equivalent to AltGr, and is not a command. + !(nativeEvent.ctrlKey && nativeEvent.altKey); +} + +/** + * Translate native top level events into event types. + * + * @param {string} topLevelType + * @return {object} + */ +function getCompositionEventType(topLevelType) { + switch (topLevelType) { + case 'topCompositionStart': + return eventTypes.compositionStart; + case 'topCompositionEnd': + return eventTypes.compositionEnd; + case 'topCompositionUpdate': + return eventTypes.compositionUpdate; + } +} + +/** + * Does our fallback best-guess model think this event signifies that + * composition has begun? + * + * @param {string} topLevelType + * @param {object} nativeEvent + * @return {boolean} + */ +function isFallbackCompositionStart(topLevelType, nativeEvent) { + return topLevelType === 'topKeyDown' && nativeEvent.keyCode === START_KEYCODE; +} + +/** + * Does our fallback mode think that this event is the end of composition? + * + * @param {string} topLevelType + * @param {object} nativeEvent + * @return {boolean} + */ +function isFallbackCompositionEnd(topLevelType, nativeEvent) { + switch (topLevelType) { + case 'topKeyUp': + // Command keys insert or clear IME input. + return END_KEYCODES.indexOf(nativeEvent.keyCode) !== -1; + case 'topKeyDown': + // Expect IME keyCode on each keydown. If we get any other + // code we must have exited earlier. + return nativeEvent.keyCode !== START_KEYCODE; + case 'topKeyPress': + case 'topMouseDown': + case 'topBlur': + // Events are not possible without cancelling IME. + return true; + default: + return false; + } +} + +/** + * Google Input Tools provides composition data via a CustomEvent, + * with the `data` property populated in the `detail` object. If this + * is available on the event object, use it. If not, this is a plain + * composition event and we have nothing special to extract. + * + * @param {object} nativeEvent + * @return {?string} + */ +function getDataFromCustomEvent(nativeEvent) { + var detail = nativeEvent.detail; + if (typeof detail === 'object' && 'data' in detail) { + return detail.data; + } + return null; +} + +// Track the current IME composition fallback object, if any. +var currentComposition = null; + +/** + * @return {?object} A SyntheticCompositionEvent. + */ +function extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var eventType; + var fallbackData; + + if (canUseCompositionEvent) { + eventType = getCompositionEventType(topLevelType); + } else if (!currentComposition) { + if (isFallbackCompositionStart(topLevelType, nativeEvent)) { + eventType = eventTypes.compositionStart; + } + } else if (isFallbackCompositionEnd(topLevelType, nativeEvent)) { + eventType = eventTypes.compositionEnd; + } + + if (!eventType) { + return null; + } + + if (useFallbackCompositionData) { + // The current composition is stored statically and must not be + // overwritten while composition continues. + if (!currentComposition && eventType === eventTypes.compositionStart) { + currentComposition = FallbackCompositionState.getPooled(nativeEventTarget); + } else if (eventType === eventTypes.compositionEnd) { + if (currentComposition) { + fallbackData = currentComposition.getData(); + } + } + } + + var event = SyntheticCompositionEvent.getPooled(eventType, targetInst, nativeEvent, nativeEventTarget); + + if (fallbackData) { + // Inject data generated from fallback path into the synthetic event. + // This matches the property of native CompositionEventInterface. + event.data = fallbackData; + } else { + var customData = getDataFromCustomEvent(nativeEvent); + if (customData !== null) { + event.data = customData; + } + } + + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} + +/** + * @param {string} topLevelType Record from `EventConstants`. + * @param {object} nativeEvent Native browser event. + * @return {?string} The string corresponding to this `beforeInput` event. + */ +function getNativeBeforeInputChars(topLevelType, nativeEvent) { + switch (topLevelType) { + case 'topCompositionEnd': + return getDataFromCustomEvent(nativeEvent); + case 'topKeyPress': + /** + * If native `textInput` events are available, our goal is to make + * use of them. However, there is a special case: the spacebar key. + * In Webkit, preventing default on a spacebar `textInput` event + * cancels character insertion, but it *also* causes the browser + * to fall back to its default spacebar behavior of scrolling the + * page. + * + * Tracking at: + * https://code.google.com/p/chromium/issues/detail?id=355103 + * + * To avoid this issue, use the keypress event as if no `textInput` + * event is available. + */ + var which = nativeEvent.which; + if (which !== SPACEBAR_CODE) { + return null; + } + + hasSpaceKeypress = true; + return SPACEBAR_CHAR; + + case 'topTextInput': + // Record the characters to be added to the DOM. + var chars = nativeEvent.data; + + // If it's a spacebar character, assume that we have already handled + // it at the keypress level and bail immediately. Android Chrome + // doesn't give us keycodes, so we need to blacklist it. + if (chars === SPACEBAR_CHAR && hasSpaceKeypress) { + return null; + } + + return chars; + + default: + // For other native event types, do nothing. + return null; + } +} + +/** + * For browsers that do not provide the `textInput` event, extract the + * appropriate string to use for SyntheticInputEvent. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {object} nativeEvent Native browser event. + * @return {?string} The fallback string for this `beforeInput` event. + */ +function getFallbackBeforeInputChars(topLevelType, nativeEvent) { + // If we are currently composing (IME) and using a fallback to do so, + // try to extract the composed characters from the fallback object. + // If composition event is available, we extract a string only at + // compositionevent, otherwise extract it at fallback events. + if (currentComposition) { + if (topLevelType === 'topCompositionEnd' || !canUseCompositionEvent && isFallbackCompositionEnd(topLevelType, nativeEvent)) { + var chars = currentComposition.getData(); + FallbackCompositionState.release(currentComposition); + currentComposition = null; + return chars; + } + return null; + } + + switch (topLevelType) { + case 'topPaste': + // If a paste event occurs after a keypress, throw out the input + // chars. Paste events should not lead to BeforeInput events. + return null; + case 'topKeyPress': + /** + * As of v27, Firefox may fire keypress events even when no character + * will be inserted. A few possibilities: + * + * - `which` is `0`. Arrow keys, Esc key, etc. + * + * - `which` is the pressed key code, but no char is available. + * Ex: 'AltGr + d` in Polish. There is no modified character for + * this key combination and no character is inserted into the + * document, but FF fires the keypress for char code `100` anyway. + * No `input` event will occur. + * + * - `which` is the pressed key code, but a command combination is + * being used. Ex: `Cmd+C`. No character is inserted, and no + * `input` event will occur. + */ + if (nativeEvent.which && !isKeypressCommand(nativeEvent)) { + return String.fromCharCode(nativeEvent.which); + } + return null; + case 'topCompositionEnd': + return useFallbackCompositionData ? null : nativeEvent.data; + default: + return null; + } +} + +/** + * Extract a SyntheticInputEvent for `beforeInput`, based on either native + * `textInput` or fallback behavior. + * + * @return {?object} A SyntheticInputEvent. + */ +function extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var chars; + + if (canUseTextInputEvent) { + chars = getNativeBeforeInputChars(topLevelType, nativeEvent); + } else { + chars = getFallbackBeforeInputChars(topLevelType, nativeEvent); + } + + // If no characters are being inserted, no BeforeInput event should + // be fired. + if (!chars) { + return null; + } + + var event = SyntheticInputEvent.getPooled(eventTypes.beforeInput, targetInst, nativeEvent, nativeEventTarget); + + event.data = chars; + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} + +/** + * Create an `onBeforeInput` event to match + * http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105/#events-inputevents. + * + * This event plugin is based on the native `textInput` event + * available in Chrome, Safari, Opera, and IE. This event fires after + * `onKeyPress` and `onCompositionEnd`, but before `onInput`. + * + * `beforeInput` is spec'd but not implemented in any browsers, and + * the `input` event does not provide any useful information about what has + * actually been added, contrary to the spec. Thus, `textInput` is the best + * available event to identify the characters that have actually been inserted + * into the target node. + * + * This plugin is also responsible for emitting `composition` events, thus + * allowing us to share composition fallback code for both `beforeInput` and + * `composition` event types. + */ +var BeforeInputEventPlugin = { + eventTypes: eventTypes, + + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + return [extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget), extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget)]; + } +}; + +module.exports = BeforeInputEventPlugin; + +/***/ }), +/* 234 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var PooledClass = __webpack_require__(32); + +var getTextContentAccessor = __webpack_require__(129); + +/** + * This helper class stores information about text content of a target node, + * allowing comparison of content before and after a given event. + * + * Identify the node where selection currently begins, then observe + * both its text content and its current position in the DOM. Since the + * browser may natively replace the target node during composition, we can + * use its position to find its replacement. + * + * @param {DOMEventTarget} root + */ +function FallbackCompositionState(root) { + this._root = root; + this._startText = this.getText(); + this._fallbackText = null; +} + +_assign(FallbackCompositionState.prototype, { + destructor: function () { + this._root = null; + this._startText = null; + this._fallbackText = null; + }, + + /** + * Get current text of input. + * + * @return {string} + */ + getText: function () { + if ('value' in this._root) { + return this._root.value; + } + return this._root[getTextContentAccessor()]; + }, + + /** + * Determine the differing substring between the initially stored + * text content and the current content. + * + * @return {string} + */ + getData: function () { + if (this._fallbackText) { + return this._fallbackText; + } + + var start; + var startValue = this._startText; + var startLength = startValue.length; + var end; + var endValue = this.getText(); + var endLength = endValue.length; + + for (start = 0; start < startLength; start++) { + if (startValue[start] !== endValue[start]) { + break; + } + } + + var minEnd = startLength - start; + for (end = 1; end <= minEnd; end++) { + if (startValue[startLength - end] !== endValue[endLength - end]) { + break; + } + } + + var sliceTail = end > 1 ? 1 - end : undefined; + this._fallbackText = endValue.slice(start, sliceTail); + return this._fallbackText; + } +}); + +PooledClass.addPoolingTo(FallbackCompositionState); + +module.exports = FallbackCompositionState; + +/***/ }), +/* 235 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/DOM-Level-3-Events/#events-compositionevents + */ +var CompositionEventInterface = { + data: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticCompositionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticCompositionEvent, CompositionEventInterface); + +module.exports = SyntheticCompositionEvent; + +/***/ }), +/* 236 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105 + * /#events-inputevents + */ +var InputEventInterface = { + data: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticInputEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticInputEvent, InputEventInterface); + +module.exports = SyntheticInputEvent; + +/***/ }), +/* 237 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPluginHub = __webpack_require__(46); +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); +var SyntheticEvent = __webpack_require__(26); + +var inputValueTracking = __webpack_require__(132); +var getEventTarget = __webpack_require__(79); +var isEventSupported = __webpack_require__(80); +var isTextInputElement = __webpack_require__(133); + +var eventTypes = { + change: { + phasedRegistrationNames: { + bubbled: 'onChange', + captured: 'onChangeCapture' + }, + dependencies: ['topBlur', 'topChange', 'topClick', 'topFocus', 'topInput', 'topKeyDown', 'topKeyUp', 'topSelectionChange'] + } +}; + +function createAndAccumulateChangeEvent(inst, nativeEvent, target) { + var event = SyntheticEvent.getPooled(eventTypes.change, inst, nativeEvent, target); + event.type = 'change'; + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} +/** + * For IE shims + */ +var activeElement = null; +var activeElementInst = null; + +/** + * SECTION: handle `change` event + */ +function shouldUseChangeEvent(elem) { + var nodeName = elem.nodeName && elem.nodeName.toLowerCase(); + return nodeName === 'select' || nodeName === 'input' && elem.type === 'file'; +} + +var doesChangeEventBubble = false; +if (ExecutionEnvironment.canUseDOM) { + // See `handleChange` comment below + doesChangeEventBubble = isEventSupported('change') && (!document.documentMode || document.documentMode > 8); +} + +function manualDispatchChangeEvent(nativeEvent) { + var event = createAndAccumulateChangeEvent(activeElementInst, nativeEvent, getEventTarget(nativeEvent)); + + // If change and propertychange bubbled, we'd just bind to it like all the + // other events and have it go through ReactBrowserEventEmitter. Since it + // doesn't, we manually listen for the events and so we have to enqueue and + // process the abstract event manually. + // + // Batching is necessary here in order to ensure that all event handlers run + // before the next rerender (including event handlers attached to ancestor + // elements instead of directly on the input). Without this, controlled + // components don't work properly in conjunction with event bubbling because + // the component is rerendered and the value reverted before all the event + // handlers can run. See https://github.com/facebook/react/issues/708. + ReactUpdates.batchedUpdates(runEventInBatch, event); +} + +function runEventInBatch(event) { + EventPluginHub.enqueueEvents(event); + EventPluginHub.processEventQueue(false); +} + +function startWatchingForChangeEventIE8(target, targetInst) { + activeElement = target; + activeElementInst = targetInst; + activeElement.attachEvent('onchange', manualDispatchChangeEvent); +} + +function stopWatchingForChangeEventIE8() { + if (!activeElement) { + return; + } + activeElement.detachEvent('onchange', manualDispatchChangeEvent); + activeElement = null; + activeElementInst = null; +} + +function getInstIfValueChanged(targetInst, nativeEvent) { + var updated = inputValueTracking.updateValueIfChanged(targetInst); + var simulated = nativeEvent.simulated === true && ChangeEventPlugin._allowSimulatedPassThrough; + + if (updated || simulated) { + return targetInst; + } +} + +function getTargetInstForChangeEvent(topLevelType, targetInst) { + if (topLevelType === 'topChange') { + return targetInst; + } +} + +function handleEventsForChangeEventIE8(topLevelType, target, targetInst) { + if (topLevelType === 'topFocus') { + // stopWatching() should be a noop here but we call it just in case we + // missed a blur event somehow. + stopWatchingForChangeEventIE8(); + startWatchingForChangeEventIE8(target, targetInst); + } else if (topLevelType === 'topBlur') { + stopWatchingForChangeEventIE8(); + } +} + +/** + * SECTION: handle `input` event + */ +var isInputEventSupported = false; +if (ExecutionEnvironment.canUseDOM) { + // IE9 claims to support the input event but fails to trigger it when + // deleting text, so we ignore its input events. + + isInputEventSupported = isEventSupported('input') && (!('documentMode' in document) || document.documentMode > 9); +} + +/** + * (For IE <=9) Starts tracking propertychange events on the passed-in element + * and override the value property so that we can distinguish user events from + * value changes in JS. + */ +function startWatchingForValueChange(target, targetInst) { + activeElement = target; + activeElementInst = targetInst; + activeElement.attachEvent('onpropertychange', handlePropertyChange); +} + +/** + * (For IE <=9) Removes the event listeners from the currently-tracked element, + * if any exists. + */ +function stopWatchingForValueChange() { + if (!activeElement) { + return; + } + activeElement.detachEvent('onpropertychange', handlePropertyChange); + + activeElement = null; + activeElementInst = null; +} + +/** + * (For IE <=9) Handles a propertychange event, sending a `change` event if + * the value of the active element has changed. + */ +function handlePropertyChange(nativeEvent) { + if (nativeEvent.propertyName !== 'value') { + return; + } + if (getInstIfValueChanged(activeElementInst, nativeEvent)) { + manualDispatchChangeEvent(nativeEvent); + } +} + +function handleEventsForInputEventPolyfill(topLevelType, target, targetInst) { + if (topLevelType === 'topFocus') { + // In IE8, we can capture almost all .value changes by adding a + // propertychange handler and looking for events with propertyName + // equal to 'value' + // In IE9, propertychange fires for most input events but is buggy and + // doesn't fire when text is deleted, but conveniently, selectionchange + // appears to fire in all of the remaining cases so we catch those and + // forward the event if the value has changed + // In either case, we don't want to call the event handler if the value + // is changed from JS so we redefine a setter for `.value` that updates + // our activeElementValue variable, allowing us to ignore those changes + // + // stopWatching() should be a noop here but we call it just in case we + // missed a blur event somehow. + stopWatchingForValueChange(); + startWatchingForValueChange(target, targetInst); + } else if (topLevelType === 'topBlur') { + stopWatchingForValueChange(); + } +} + +// For IE8 and IE9. +function getTargetInstForInputEventPolyfill(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topSelectionChange' || topLevelType === 'topKeyUp' || topLevelType === 'topKeyDown') { + // On the selectionchange event, the target is just document which isn't + // helpful for us so just check activeElement instead. + // + // 99% of the time, keydown and keyup aren't necessary. IE8 fails to fire + // propertychange on the first input event after setting `value` from a + // script and fires only keydown, keypress, keyup. Catching keyup usually + // gets it and catching keydown lets us fire an event for the first + // keystroke if user does a key repeat (it'll be a little delayed: right + // before the second keystroke). Other input methods (e.g., paste) seem to + // fire selectionchange normally. + return getInstIfValueChanged(activeElementInst, nativeEvent); + } +} + +/** + * SECTION: handle `click` event + */ +function shouldUseClickEvent(elem) { + // Use the `click` event to detect changes to checkbox and radio inputs. + // This approach works across all browsers, whereas `change` does not fire + // until `blur` in IE8. + var nodeName = elem.nodeName; + return nodeName && nodeName.toLowerCase() === 'input' && (elem.type === 'checkbox' || elem.type === 'radio'); +} + +function getTargetInstForClickEvent(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topClick') { + return getInstIfValueChanged(targetInst, nativeEvent); + } +} + +function getTargetInstForInputOrChangeEvent(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topInput' || topLevelType === 'topChange') { + return getInstIfValueChanged(targetInst, nativeEvent); + } +} + +function handleControlledInputBlur(inst, node) { + // TODO: In IE, inst is occasionally null. Why? + if (inst == null) { + return; + } + + // Fiber and ReactDOM keep wrapper state in separate places + var state = inst._wrapperState || node._wrapperState; + + if (!state || !state.controlled || node.type !== 'number') { + return; + } + + // If controlled, assign the value attribute to the current value on blur + var value = '' + node.value; + if (node.getAttribute('value') !== value) { + node.setAttribute('value', value); + } +} + +/** + * This plugin creates an `onChange` event that normalizes change events + * across form elements. This event fires at a time when it's possible to + * change the element's value without seeing a flicker. + * + * Supported elements are: + * - input (see `isTextInputElement`) + * - textarea + * - select + */ +var ChangeEventPlugin = { + eventTypes: eventTypes, + + _allowSimulatedPassThrough: true, + _isInputEventSupported: isInputEventSupported, + + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; + + var getTargetInstFunc, handleEventFunc; + if (shouldUseChangeEvent(targetNode)) { + if (doesChangeEventBubble) { + getTargetInstFunc = getTargetInstForChangeEvent; + } else { + handleEventFunc = handleEventsForChangeEventIE8; + } + } else if (isTextInputElement(targetNode)) { + if (isInputEventSupported) { + getTargetInstFunc = getTargetInstForInputOrChangeEvent; + } else { + getTargetInstFunc = getTargetInstForInputEventPolyfill; + handleEventFunc = handleEventsForInputEventPolyfill; + } + } else if (shouldUseClickEvent(targetNode)) { + getTargetInstFunc = getTargetInstForClickEvent; + } + + if (getTargetInstFunc) { + var inst = getTargetInstFunc(topLevelType, targetInst, nativeEvent); + if (inst) { + var event = createAndAccumulateChangeEvent(inst, nativeEvent, nativeEventTarget); + return event; + } + } + + if (handleEventFunc) { + handleEventFunc(topLevelType, targetNode, targetInst); + } + + // When blurring, set the value attribute for number inputs + if (topLevelType === 'topBlur') { + handleControlledInputBlur(targetInst, targetNode); + } + } +}; + +module.exports = ChangeEventPlugin; + +/***/ }), +/* 238 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactOwner = __webpack_require__(239); + +var ReactRef = {}; + +function attachRef(ref, component, owner) { + if (typeof ref === 'function') { + ref(component.getPublicInstance()); + } else { + // Legacy ref + ReactOwner.addComponentAsRefTo(component, ref, owner); + } +} + +function detachRef(ref, component, owner) { + if (typeof ref === 'function') { + ref(null); + } else { + // Legacy ref + ReactOwner.removeComponentAsRefFrom(component, ref, owner); + } +} + +ReactRef.attachRefs = function (instance, element) { + if (element === null || typeof element !== 'object') { + return; + } + var ref = element.ref; + if (ref != null) { + attachRef(ref, instance, element._owner); + } +}; + +ReactRef.shouldUpdateRefs = function (prevElement, nextElement) { + // If either the owner or a `ref` has changed, make sure the newest owner + // has stored a reference to `this`, and the previous owner (if different) + // has forgotten the reference to `this`. We use the element instead + // of the public this.props because the post processing cannot determine + // a ref. The ref conceptually lives on the element. + + // TODO: Should this even be possible? The owner cannot change because + // it's forbidden by shouldUpdateReactComponent. The ref can change + // if you swap the keys of but not the refs. Reconsider where this check + // is made. It probably belongs where the key checking and + // instantiateReactComponent is done. + + var prevRef = null; + var prevOwner = null; + if (prevElement !== null && typeof prevElement === 'object') { + prevRef = prevElement.ref; + prevOwner = prevElement._owner; + } + + var nextRef = null; + var nextOwner = null; + if (nextElement !== null && typeof nextElement === 'object') { + nextRef = nextElement.ref; + nextOwner = nextElement._owner; + } + + return prevRef !== nextRef || + // If owner changes but we have an unchanged function ref, don't update refs + typeof nextRef === 'string' && nextOwner !== prevOwner; +}; + +ReactRef.detachRefs = function (instance, element) { + if (element === null || typeof element !== 'object') { + return; + } + var ref = element.ref; + if (ref != null) { + detachRef(ref, instance, element._owner); + } +}; + +module.exports = ReactRef; + +/***/ }), +/* 239 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +/** + * @param {?object} object + * @return {boolean} True if `object` is a valid owner. + * @final + */ +function isValidOwner(object) { + return !!(object && typeof object.attachRef === 'function' && typeof object.detachRef === 'function'); +} + +/** + * ReactOwners are capable of storing references to owned components. + * + * All components are capable of //being// referenced by owner components, but + * only ReactOwner components are capable of //referencing// owned components. + * The named reference is known as a "ref". + * + * Refs are available when mounted and updated during reconciliation. + * + * var MyComponent = React.createClass({ + * render: function() { + * return ( + * <div onClick={this.handleClick}> + * <CustomComponent ref="custom" /> + * </div> + * ); + * }, + * handleClick: function() { + * this.refs.custom.handleClick(); + * }, + * componentDidMount: function() { + * this.refs.custom.initialize(); + * } + * }); + * + * Refs should rarely be used. When refs are used, they should only be done to + * control data that is not handled by React's data flow. + * + * @class ReactOwner + */ +var ReactOwner = { + /** + * Adds a component by ref to an owner component. + * + * @param {ReactComponent} component Component to reference. + * @param {string} ref Name by which to refer to the component. + * @param {ReactOwner} owner Component on which to record the ref. + * @final + * @internal + */ + addComponentAsRefTo: function (component, ref, owner) { + !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('119') : void 0; + owner.attachRef(ref, component); + }, + + /** + * Removes a component by ref from an owner component. + * + * @param {ReactComponent} component Component to dereference. + * @param {string} ref Name of the ref to remove. + * @param {ReactOwner} owner Component on which the ref is recorded. + * @final + * @internal + */ + removeComponentAsRefFrom: function (component, ref, owner) { + !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'removeComponentAsRefFrom(...): Only a ReactOwner can have refs. You might be removing a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('120') : void 0; + var ownerPublicInstance = owner.getPublicInstance(); + // Check that `component`'s owner is still alive and that `component` is still the current ref + // because we do not want to detach the ref if another component stole it. + if (ownerPublicInstance && ownerPublicInstance.refs[ref] === component.getPublicInstance()) { + owner.detachRef(ref); + } + } +}; + +module.exports = ReactOwner; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 240 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactInvalidSetStateWarningHook = __webpack_require__(241); +var ReactHostOperationHistoryHook = __webpack_require__(242); +var ReactComponentTreeHook = __webpack_require__(17); +var ExecutionEnvironment = __webpack_require__(13); + +var performanceNow = __webpack_require__(243); +var warning = __webpack_require__(3); + +var hooks = []; +var didHookThrowForEvent = {}; + +function callHook(event, fn, context, arg1, arg2, arg3, arg4, arg5) { + try { + fn.call(context, arg1, arg2, arg3, arg4, arg5); + } catch (e) { + process.env.NODE_ENV !== 'production' ? warning(didHookThrowForEvent[event], 'Exception thrown by hook while handling %s: %s', event, e + '\n' + e.stack) : void 0; + didHookThrowForEvent[event] = true; + } +} + +function emitEvent(event, arg1, arg2, arg3, arg4, arg5) { + for (var i = 0; i < hooks.length; i++) { + var hook = hooks[i]; + var fn = hook[event]; + if (fn) { + callHook(event, fn, hook, arg1, arg2, arg3, arg4, arg5); + } + } +} + +var isProfiling = false; +var flushHistory = []; +var lifeCycleTimerStack = []; +var currentFlushNesting = 0; +var currentFlushMeasurements = []; +var currentFlushStartTime = 0; +var currentTimerDebugID = null; +var currentTimerStartTime = 0; +var currentTimerNestedFlushDuration = 0; +var currentTimerType = null; + +var lifeCycleTimerHasWarned = false; + +function clearHistory() { + ReactComponentTreeHook.purgeUnmountedComponents(); + ReactHostOperationHistoryHook.clearHistory(); +} + +function getTreeSnapshot(registeredIDs) { + return registeredIDs.reduce(function (tree, id) { + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var parentID = ReactComponentTreeHook.getParentID(id); + tree[id] = { + displayName: ReactComponentTreeHook.getDisplayName(id), + text: ReactComponentTreeHook.getText(id), + updateCount: ReactComponentTreeHook.getUpdateCount(id), + childIDs: ReactComponentTreeHook.getChildIDs(id), + // Text nodes don't have owners but this is close enough. + ownerID: ownerID || parentID && ReactComponentTreeHook.getOwnerID(parentID) || 0, + parentID: parentID + }; + return tree; + }, {}); +} + +function resetMeasurements() { + var previousStartTime = currentFlushStartTime; + var previousMeasurements = currentFlushMeasurements; + var previousOperations = ReactHostOperationHistoryHook.getHistory(); + + if (currentFlushNesting === 0) { + currentFlushStartTime = 0; + currentFlushMeasurements = []; + clearHistory(); + return; + } + + if (previousMeasurements.length || previousOperations.length) { + var registeredIDs = ReactComponentTreeHook.getRegisteredIDs(); + flushHistory.push({ + duration: performanceNow() - previousStartTime, + measurements: previousMeasurements || [], + operations: previousOperations || [], + treeSnapshot: getTreeSnapshot(registeredIDs) + }); + } + + clearHistory(); + currentFlushStartTime = performanceNow(); + currentFlushMeasurements = []; +} + +function checkDebugID(debugID) { + var allowRoot = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; + + if (allowRoot && debugID === 0) { + return; + } + if (!debugID) { + process.env.NODE_ENV !== 'production' ? warning(false, 'ReactDebugTool: debugID may not be empty.') : void 0; + } +} + +function beginLifeCycleTimer(debugID, timerType) { + if (currentFlushNesting === 0) { + return; + } + if (currentTimerType && !lifeCycleTimerHasWarned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'Did not expect %s timer to start while %s timer is still in ' + 'progress for %s instance.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; + lifeCycleTimerHasWarned = true; + } + currentTimerStartTime = performanceNow(); + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = debugID; + currentTimerType = timerType; +} + +function endLifeCycleTimer(debugID, timerType) { + if (currentFlushNesting === 0) { + return; + } + if (currentTimerType !== timerType && !lifeCycleTimerHasWarned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'We did not expect %s timer to stop while %s timer is still in ' + 'progress for %s instance. Please report this as a bug in React.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; + lifeCycleTimerHasWarned = true; + } + if (isProfiling) { + currentFlushMeasurements.push({ + timerType: timerType, + instanceID: debugID, + duration: performanceNow() - currentTimerStartTime - currentTimerNestedFlushDuration + }); + } + currentTimerStartTime = 0; + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = null; + currentTimerType = null; +} + +function pauseCurrentLifeCycleTimer() { + var currentTimer = { + startTime: currentTimerStartTime, + nestedFlushStartTime: performanceNow(), + debugID: currentTimerDebugID, + timerType: currentTimerType + }; + lifeCycleTimerStack.push(currentTimer); + currentTimerStartTime = 0; + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = null; + currentTimerType = null; +} + +function resumeCurrentLifeCycleTimer() { + var _lifeCycleTimerStack$ = lifeCycleTimerStack.pop(), + startTime = _lifeCycleTimerStack$.startTime, + nestedFlushStartTime = _lifeCycleTimerStack$.nestedFlushStartTime, + debugID = _lifeCycleTimerStack$.debugID, + timerType = _lifeCycleTimerStack$.timerType; + + var nestedFlushDuration = performanceNow() - nestedFlushStartTime; + currentTimerStartTime = startTime; + currentTimerNestedFlushDuration += nestedFlushDuration; + currentTimerDebugID = debugID; + currentTimerType = timerType; +} + +var lastMarkTimeStamp = 0; +var canUsePerformanceMeasure = typeof performance !== 'undefined' && typeof performance.mark === 'function' && typeof performance.clearMarks === 'function' && typeof performance.measure === 'function' && typeof performance.clearMeasures === 'function'; + +function shouldMark(debugID) { + if (!isProfiling || !canUsePerformanceMeasure) { + return false; + } + var element = ReactComponentTreeHook.getElement(debugID); + if (element == null || typeof element !== 'object') { + return false; + } + var isHostElement = typeof element.type === 'string'; + if (isHostElement) { + return false; + } + return true; +} + +function markBegin(debugID, markType) { + if (!shouldMark(debugID)) { + return; + } + + var markName = debugID + '::' + markType; + lastMarkTimeStamp = performanceNow(); + performance.mark(markName); +} + +function markEnd(debugID, markType) { + if (!shouldMark(debugID)) { + return; + } + + var markName = debugID + '::' + markType; + var displayName = ReactComponentTreeHook.getDisplayName(debugID) || 'Unknown'; + + // Chrome has an issue of dropping markers recorded too fast: + // https://bugs.chromium.org/p/chromium/issues/detail?id=640652 + // To work around this, we will not report very small measurements. + // I determined the magic number by tweaking it back and forth. + // 0.05ms was enough to prevent the issue, but I set it to 0.1ms to be safe. + // When the bug is fixed, we can `measure()` unconditionally if we want to. + var timeStamp = performanceNow(); + if (timeStamp - lastMarkTimeStamp > 0.1) { + var measurementName = displayName + ' [' + markType + ']'; + performance.measure(measurementName, markName); + } + + performance.clearMarks(markName); + if (measurementName) { + performance.clearMeasures(measurementName); + } +} + +var ReactDebugTool = { + addHook: function (hook) { + hooks.push(hook); + }, + removeHook: function (hook) { + for (var i = 0; i < hooks.length; i++) { + if (hooks[i] === hook) { + hooks.splice(i, 1); + i--; + } + } + }, + isProfiling: function () { + return isProfiling; + }, + beginProfiling: function () { + if (isProfiling) { + return; + } + + isProfiling = true; + flushHistory.length = 0; + resetMeasurements(); + ReactDebugTool.addHook(ReactHostOperationHistoryHook); + }, + endProfiling: function () { + if (!isProfiling) { + return; + } + + isProfiling = false; + resetMeasurements(); + ReactDebugTool.removeHook(ReactHostOperationHistoryHook); + }, + getFlushHistory: function () { + return flushHistory; + }, + onBeginFlush: function () { + currentFlushNesting++; + resetMeasurements(); + pauseCurrentLifeCycleTimer(); + emitEvent('onBeginFlush'); + }, + onEndFlush: function () { + resetMeasurements(); + currentFlushNesting--; + resumeCurrentLifeCycleTimer(); + emitEvent('onEndFlush'); + }, + onBeginLifeCycleTimer: function (debugID, timerType) { + checkDebugID(debugID); + emitEvent('onBeginLifeCycleTimer', debugID, timerType); + markBegin(debugID, timerType); + beginLifeCycleTimer(debugID, timerType); + }, + onEndLifeCycleTimer: function (debugID, timerType) { + checkDebugID(debugID); + endLifeCycleTimer(debugID, timerType); + markEnd(debugID, timerType); + emitEvent('onEndLifeCycleTimer', debugID, timerType); + }, + onBeginProcessingChildContext: function () { + emitEvent('onBeginProcessingChildContext'); + }, + onEndProcessingChildContext: function () { + emitEvent('onEndProcessingChildContext'); + }, + onHostOperation: function (operation) { + checkDebugID(operation.instanceID); + emitEvent('onHostOperation', operation); + }, + onSetState: function () { + emitEvent('onSetState'); + }, + onSetChildren: function (debugID, childDebugIDs) { + checkDebugID(debugID); + childDebugIDs.forEach(checkDebugID); + emitEvent('onSetChildren', debugID, childDebugIDs); + }, + onBeforeMountComponent: function (debugID, element, parentDebugID) { + checkDebugID(debugID); + checkDebugID(parentDebugID, true); + emitEvent('onBeforeMountComponent', debugID, element, parentDebugID); + markBegin(debugID, 'mount'); + }, + onMountComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'mount'); + emitEvent('onMountComponent', debugID); + }, + onBeforeUpdateComponent: function (debugID, element) { + checkDebugID(debugID); + emitEvent('onBeforeUpdateComponent', debugID, element); + markBegin(debugID, 'update'); + }, + onUpdateComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'update'); + emitEvent('onUpdateComponent', debugID); + }, + onBeforeUnmountComponent: function (debugID) { + checkDebugID(debugID); + emitEvent('onBeforeUnmountComponent', debugID); + markBegin(debugID, 'unmount'); + }, + onUnmountComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'unmount'); + emitEvent('onUnmountComponent', debugID); + }, + onTestEvent: function () { + emitEvent('onTestEvent'); + } +}; + +// TODO remove these when RN/www gets updated +ReactDebugTool.addDevtool = ReactDebugTool.addHook; +ReactDebugTool.removeDevtool = ReactDebugTool.removeHook; + +ReactDebugTool.addHook(ReactInvalidSetStateWarningHook); +ReactDebugTool.addHook(ReactComponentTreeHook); +var url = ExecutionEnvironment.canUseDOM && window.location.href || ''; +if (/[?&]react_perf\b/.test(url)) { + ReactDebugTool.beginProfiling(); +} + +module.exports = ReactDebugTool; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 241 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var warning = __webpack_require__(3); + +if (process.env.NODE_ENV !== 'production') { + var processingChildContext = false; + + var warnInvalidSetState = function () { + process.env.NODE_ENV !== 'production' ? warning(!processingChildContext, 'setState(...): Cannot call setState() inside getChildContext()') : void 0; + }; +} + +var ReactInvalidSetStateWarningHook = { + onBeginProcessingChildContext: function () { + processingChildContext = true; + }, + onEndProcessingChildContext: function () { + processingChildContext = false; + }, + onSetState: function () { + warnInvalidSetState(); + } +}; + +module.exports = ReactInvalidSetStateWarningHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 242 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var history = []; + +var ReactHostOperationHistoryHook = { + onHostOperation: function (operation) { + history.push(operation); + }, + clearHistory: function () { + if (ReactHostOperationHistoryHook._preventClearing) { + // Should only be used for tests. + return; + } + + history = []; + }, + getHistory: function () { + return history; + } +}; + +module.exports = ReactHostOperationHistoryHook; + +/***/ }), +/* 243 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var performance = __webpack_require__(244); + +var performanceNow; + +/** + * Detect if we can use `window.performance.now()` and gracefully fallback to + * `Date.now()` if it doesn't exist. We need to support Firefox < 15 for now + * because of Facebook's testing infrastructure. + */ +if (performance.now) { + performanceNow = function performanceNow() { + return performance.now(); + }; +} else { + performanceNow = function performanceNow() { + return Date.now(); + }; +} + +module.exports = performanceNow; + +/***/ }), +/* 244 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +var performance; + +if (ExecutionEnvironment.canUseDOM) { + performance = window.performance || window.msPerformance || window.webkitPerformance; +} + +module.exports = performance || {}; + +/***/ }), +/* 245 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * Module that is injectable into `EventPluginHub`, that specifies a + * deterministic ordering of `EventPlugin`s. A convenient way to reason about + * plugins, without having to package every one of them. This is better than + * having plugins be ordered in the same order that they are injected because + * that ordering would be influenced by the packaging order. + * `ResponderEventPlugin` must occur before `SimpleEventPlugin` so that + * preventing default on events is convenient in `SimpleEventPlugin` handlers. + */ + +var DefaultEventPluginOrder = ['ResponderEventPlugin', 'SimpleEventPlugin', 'TapEventPlugin', 'EnterLeaveEventPlugin', 'ChangeEventPlugin', 'SelectEventPlugin', 'BeforeInputEventPlugin']; + +module.exports = DefaultEventPluginOrder; + +/***/ }), +/* 246 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPropagators = __webpack_require__(45); +var ReactDOMComponentTree = __webpack_require__(10); +var SyntheticMouseEvent = __webpack_require__(59); + +var eventTypes = { + mouseEnter: { + registrationName: 'onMouseEnter', + dependencies: ['topMouseOut', 'topMouseOver'] + }, + mouseLeave: { + registrationName: 'onMouseLeave', + dependencies: ['topMouseOut', 'topMouseOver'] + } +}; + +var EnterLeaveEventPlugin = { + eventTypes: eventTypes, + + /** + * For almost every interaction we care about, there will be both a top-level + * `mouseover` and `mouseout` event that occurs. Only use `mouseout` so that + * we do not extract duplicate events. However, moving the mouse into the + * browser from outside will not fire a `mouseout` event. In this case, we use + * the `mouseover` top-level event. + */ + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + if (topLevelType === 'topMouseOver' && (nativeEvent.relatedTarget || nativeEvent.fromElement)) { + return null; + } + if (topLevelType !== 'topMouseOut' && topLevelType !== 'topMouseOver') { + // Must not be a mouse in or mouse out - ignoring. + return null; + } + + var win; + if (nativeEventTarget.window === nativeEventTarget) { + // `nativeEventTarget` is probably a window object. + win = nativeEventTarget; + } else { + // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. + var doc = nativeEventTarget.ownerDocument; + if (doc) { + win = doc.defaultView || doc.parentWindow; + } else { + win = window; + } + } + + var from; + var to; + if (topLevelType === 'topMouseOut') { + from = targetInst; + var related = nativeEvent.relatedTarget || nativeEvent.toElement; + to = related ? ReactDOMComponentTree.getClosestInstanceFromNode(related) : null; + } else { + // Moving to a node from outside the window. + from = null; + to = targetInst; + } + + if (from === to) { + // Nothing pertains to our managed components. + return null; + } + + var fromNode = from == null ? win : ReactDOMComponentTree.getNodeFromInstance(from); + var toNode = to == null ? win : ReactDOMComponentTree.getNodeFromInstance(to); + + var leave = SyntheticMouseEvent.getPooled(eventTypes.mouseLeave, from, nativeEvent, nativeEventTarget); + leave.type = 'mouseleave'; + leave.target = fromNode; + leave.relatedTarget = toNode; + + var enter = SyntheticMouseEvent.getPooled(eventTypes.mouseEnter, to, nativeEvent, nativeEventTarget); + enter.type = 'mouseenter'; + enter.target = toNode; + enter.relatedTarget = fromNode; + + EventPropagators.accumulateEnterLeaveDispatches(leave, enter, from, to); + + return [leave, enter]; + } +}; + +module.exports = EnterLeaveEventPlugin; + +/***/ }), +/* 247 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); + +var MUST_USE_PROPERTY = DOMProperty.injection.MUST_USE_PROPERTY; +var HAS_BOOLEAN_VALUE = DOMProperty.injection.HAS_BOOLEAN_VALUE; +var HAS_NUMERIC_VALUE = DOMProperty.injection.HAS_NUMERIC_VALUE; +var HAS_POSITIVE_NUMERIC_VALUE = DOMProperty.injection.HAS_POSITIVE_NUMERIC_VALUE; +var HAS_OVERLOADED_BOOLEAN_VALUE = DOMProperty.injection.HAS_OVERLOADED_BOOLEAN_VALUE; + +var HTMLDOMPropertyConfig = { + isCustomAttribute: RegExp.prototype.test.bind(new RegExp('^(data|aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$')), + Properties: { + /** + * Standard Properties + */ + accept: 0, + acceptCharset: 0, + accessKey: 0, + action: 0, + allowFullScreen: HAS_BOOLEAN_VALUE, + allowTransparency: 0, + alt: 0, + // specifies target context for links with `preload` type + as: 0, + async: HAS_BOOLEAN_VALUE, + autoComplete: 0, + // autoFocus is polyfilled/normalized by AutoFocusUtils + // autoFocus: HAS_BOOLEAN_VALUE, + autoPlay: HAS_BOOLEAN_VALUE, + capture: HAS_BOOLEAN_VALUE, + cellPadding: 0, + cellSpacing: 0, + charSet: 0, + challenge: 0, + checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + cite: 0, + classID: 0, + className: 0, + cols: HAS_POSITIVE_NUMERIC_VALUE, + colSpan: 0, + content: 0, + contentEditable: 0, + contextMenu: 0, + controls: HAS_BOOLEAN_VALUE, + coords: 0, + crossOrigin: 0, + data: 0, // For `<object />` acts as `src`. + dateTime: 0, + 'default': HAS_BOOLEAN_VALUE, + defer: HAS_BOOLEAN_VALUE, + dir: 0, + disabled: HAS_BOOLEAN_VALUE, + download: HAS_OVERLOADED_BOOLEAN_VALUE, + draggable: 0, + encType: 0, + form: 0, + formAction: 0, + formEncType: 0, + formMethod: 0, + formNoValidate: HAS_BOOLEAN_VALUE, + formTarget: 0, + frameBorder: 0, + headers: 0, + height: 0, + hidden: HAS_BOOLEAN_VALUE, + high: 0, + href: 0, + hrefLang: 0, + htmlFor: 0, + httpEquiv: 0, + icon: 0, + id: 0, + inputMode: 0, + integrity: 0, + is: 0, + keyParams: 0, + keyType: 0, + kind: 0, + label: 0, + lang: 0, + list: 0, + loop: HAS_BOOLEAN_VALUE, + low: 0, + manifest: 0, + marginHeight: 0, + marginWidth: 0, + max: 0, + maxLength: 0, + media: 0, + mediaGroup: 0, + method: 0, + min: 0, + minLength: 0, + // Caution; `option.selected` is not updated if `select.multiple` is + // disabled with `removeAttribute`. + multiple: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + muted: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + name: 0, + nonce: 0, + noValidate: HAS_BOOLEAN_VALUE, + open: HAS_BOOLEAN_VALUE, + optimum: 0, + pattern: 0, + placeholder: 0, + playsInline: HAS_BOOLEAN_VALUE, + poster: 0, + preload: 0, + profile: 0, + radioGroup: 0, + readOnly: HAS_BOOLEAN_VALUE, + referrerPolicy: 0, + rel: 0, + required: HAS_BOOLEAN_VALUE, + reversed: HAS_BOOLEAN_VALUE, + role: 0, + rows: HAS_POSITIVE_NUMERIC_VALUE, + rowSpan: HAS_NUMERIC_VALUE, + sandbox: 0, + scope: 0, + scoped: HAS_BOOLEAN_VALUE, + scrolling: 0, + seamless: HAS_BOOLEAN_VALUE, + selected: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + shape: 0, + size: HAS_POSITIVE_NUMERIC_VALUE, + sizes: 0, + span: HAS_POSITIVE_NUMERIC_VALUE, + spellCheck: 0, + src: 0, + srcDoc: 0, + srcLang: 0, + srcSet: 0, + start: HAS_NUMERIC_VALUE, + step: 0, + style: 0, + summary: 0, + tabIndex: 0, + target: 0, + title: 0, + // Setting .type throws on non-<input> tags + type: 0, + useMap: 0, + value: 0, + width: 0, + wmode: 0, + wrap: 0, + + /** + * RDFa Properties + */ + about: 0, + datatype: 0, + inlist: 0, + prefix: 0, + // property is also supported for OpenGraph in meta tags. + property: 0, + resource: 0, + 'typeof': 0, + vocab: 0, + + /** + * Non-standard Properties + */ + // autoCapitalize and autoCorrect are supported in Mobile Safari for + // keyboard hints. + autoCapitalize: 0, + autoCorrect: 0, + // autoSave allows WebKit/Blink to persist values of input fields on page reloads + autoSave: 0, + // color is for Safari mask-icon link + color: 0, + // itemProp, itemScope, itemType are for + // Microdata support. See http://schema.org/docs/gs.html + itemProp: 0, + itemScope: HAS_BOOLEAN_VALUE, + itemType: 0, + // itemID and itemRef are for Microdata support as well but + // only specified in the WHATWG spec document. See + // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api + itemID: 0, + itemRef: 0, + // results show looking glass icon and recent searches on input + // search fields in WebKit/Blink + results: 0, + // IE-only attribute that specifies security restrictions on an iframe + // as an alternative to the sandbox attribute on IE<10 + security: 0, + // IE-only attribute that controls focus behavior + unselectable: 0 + }, + DOMAttributeNames: { + acceptCharset: 'accept-charset', + className: 'class', + htmlFor: 'for', + httpEquiv: 'http-equiv' + }, + DOMPropertyNames: {}, + DOMMutationMethods: { + value: function (node, value) { + if (value == null) { + return node.removeAttribute('value'); + } + + // Number inputs get special treatment due to some edge cases in + // Chrome. Let everything else assign the value attribute as normal. + // https://github.com/facebook/react/issues/7253#issuecomment-236074326 + if (node.type !== 'number' || node.hasAttribute('value') === false) { + node.setAttribute('value', '' + value); + } else if (node.validity && !node.validity.badInput && node.ownerDocument.activeElement !== node) { + // Don't assign an attribute if validation reports bad + // input. Chrome will clear the value. Additionally, don't + // operate on inputs that have focus, otherwise Chrome might + // strip off trailing decimal places and cause the user's + // cursor position to jump to the beginning of the input. + // + // In ReactDOMInput, we have an onBlur event that will trigger + // this function again when focus is lost. + node.setAttribute('value', '' + value); + } + } + } +}; + +module.exports = HTMLDOMPropertyConfig; + +/***/ }), +/* 248 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMChildrenOperations = __webpack_require__(82); +var ReactDOMIDOperations = __webpack_require__(253); + +/** + * Abstracts away all functionality of the reconciler that requires knowledge of + * the browser context. TODO: These callers should be refactored to avoid the + * need for this injection. + */ +var ReactComponentBrowserEnvironment = { + processChildrenUpdates: ReactDOMIDOperations.dangerouslyProcessChildrenUpdates, + + replaceNodeWithMarkup: DOMChildrenOperations.dangerouslyReplaceNodeWithMarkup +}; + +module.exports = ReactComponentBrowserEnvironment; + +/***/ }), +/* 249 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var DOMLazyTree = __webpack_require__(39); +var ExecutionEnvironment = __webpack_require__(13); + +var createNodesFromMarkup = __webpack_require__(250); +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); + +var Danger = { + /** + * Replaces a node with a string of markup at its current position within its + * parent. The markup must render into a single root node. + * + * @param {DOMElement} oldChild Child node to replace. + * @param {string} markup Markup to render in place of the child node. + * @internal + */ + dangerouslyReplaceNodeWithMarkup: function (oldChild, markup) { + !ExecutionEnvironment.canUseDOM ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot render markup in a worker thread. Make sure `window` and `document` are available globally before requiring React when unit testing or use ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('56') : void 0; + !markup ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Missing markup.') : _prodInvariant('57') : void 0; + !(oldChild.nodeName !== 'HTML') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot replace markup of the <html> node. This is because browser quirks make this unreliable and/or slow. If you want to render to the root you must use server rendering. See ReactDOMServer.renderToString().') : _prodInvariant('58') : void 0; + + if (typeof markup === 'string') { + var newChild = createNodesFromMarkup(markup, emptyFunction)[0]; + oldChild.parentNode.replaceChild(newChild, oldChild); + } else { + DOMLazyTree.replaceChildWithTree(oldChild, markup); + } + } +}; + +module.exports = Danger; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 250 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +/*eslint-disable fb-www/unsafe-html*/ + +var ExecutionEnvironment = __webpack_require__(13); + +var createArrayFromMixed = __webpack_require__(251); +var getMarkupWrap = __webpack_require__(252); +var invariant = __webpack_require__(2); + +/** + * Dummy container used to render all markup. + */ +var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; + +/** + * Pattern used by `getNodeName`. + */ +var nodeNamePattern = /^\s*<(\w+)/; + +/** + * Extracts the `nodeName` of the first element in a string of markup. + * + * @param {string} markup String of markup. + * @return {?string} Node name of the supplied markup. + */ +function getNodeName(markup) { + var nodeNameMatch = markup.match(nodeNamePattern); + return nodeNameMatch && nodeNameMatch[1].toLowerCase(); +} + +/** + * Creates an array containing the nodes rendered from the supplied markup. The + * optionally supplied `handleScript` function will be invoked once for each + * <script> element that is rendered. If no `handleScript` function is supplied, + * an exception is thrown if any <script> elements are rendered. + * + * @param {string} markup A string of valid HTML markup. + * @param {?function} handleScript Invoked once for each rendered <script>. + * @return {array<DOMElement|DOMTextNode>} An array of rendered nodes. + */ +function createNodesFromMarkup(markup, handleScript) { + var node = dummyNode; + !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup dummy not initialized') : invariant(false) : void 0; + var nodeName = getNodeName(markup); + + var wrap = nodeName && getMarkupWrap(nodeName); + if (wrap) { + node.innerHTML = wrap[1] + markup + wrap[2]; + + var wrapDepth = wrap[0]; + while (wrapDepth--) { + node = node.lastChild; + } + } else { + node.innerHTML = markup; + } + + var scripts = node.getElementsByTagName('script'); + if (scripts.length) { + !handleScript ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup(...): Unexpected <script> element rendered.') : invariant(false) : void 0; + createArrayFromMixed(scripts).forEach(handleScript); + } + + var nodes = Array.from(node.childNodes); + while (node.lastChild) { + node.removeChild(node.lastChild); + } + return nodes; +} + +module.exports = createNodesFromMarkup; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 251 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var invariant = __webpack_require__(2); + +/** + * Convert array-like objects to arrays. + * + * This API assumes the caller knows the contents of the data type. For less + * well defined inputs use createArrayFromMixed. + * + * @param {object|function|filelist} obj + * @return {array} + */ +function toArray(obj) { + var length = obj.length; + + // Some browsers builtin objects can report typeof 'function' (e.g. NodeList + // in old versions of Safari). + !(!Array.isArray(obj) && (typeof obj === 'object' || typeof obj === 'function')) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Array-like object expected') : invariant(false) : void 0; + + !(typeof length === 'number') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object needs a length property') : invariant(false) : void 0; + + !(length === 0 || length - 1 in obj) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object should have keys for indices') : invariant(false) : void 0; + + !(typeof obj.callee !== 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object can\'t be `arguments`. Use rest params ' + '(function(...args) {}) or Array.from() instead.') : invariant(false) : void 0; + + // Old IE doesn't give collections access to hasOwnProperty. Assume inputs + // without method will throw during the slice call and skip straight to the + // fallback. + if (obj.hasOwnProperty) { + try { + return Array.prototype.slice.call(obj); + } catch (e) { + // IE < 9 does not support Array#slice on collections objects + } + } + + // Fall back to copying key by key. This assumes all keys have a value, + // so will not preserve sparsely populated inputs. + var ret = Array(length); + for (var ii = 0; ii < length; ii++) { + ret[ii] = obj[ii]; + } + return ret; +} + +/** + * Perform a heuristic test to determine if an object is "array-like". + * + * A monk asked Joshu, a Zen master, "Has a dog Buddha nature?" + * Joshu replied: "Mu." + * + * This function determines if its argument has "array nature": it returns + * true if the argument is an actual array, an `arguments' object, or an + * HTMLCollection (e.g. node.childNodes or node.getElementsByTagName()). + * + * It will return false for other array-like objects like Filelist. + * + * @param {*} obj + * @return {boolean} + */ +function hasArrayNature(obj) { + return ( + // not null/false + !!obj && ( + // arrays are objects, NodeLists are functions in Safari + typeof obj == 'object' || typeof obj == 'function') && + // quacks like an array + 'length' in obj && + // not window + !('setInterval' in obj) && + // no DOM node should be considered an array-like + // a 'select' element has 'length' and 'item' properties on IE8 + typeof obj.nodeType != 'number' && ( + // a real array + Array.isArray(obj) || + // arguments + 'callee' in obj || + // HTMLCollection/NodeList + 'item' in obj) + ); +} + +/** + * Ensure that the argument is an array by wrapping it in an array if it is not. + * Creates a copy of the argument if it is already an array. + * + * This is mostly useful idiomatically: + * + * var createArrayFromMixed = require('createArrayFromMixed'); + * + * function takesOneOrMoreThings(things) { + * things = createArrayFromMixed(things); + * ... + * } + * + * This allows you to treat `things' as an array, but accept scalars in the API. + * + * If you need to convert an array-like object, like `arguments`, into an array + * use toArray instead. + * + * @param {*} obj + * @return {array} + */ +function createArrayFromMixed(obj) { + if (!hasArrayNature(obj)) { + return [obj]; + } else if (Array.isArray(obj)) { + return obj.slice(); + } else { + return toArray(obj); + } +} + +module.exports = createArrayFromMixed; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 252 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/*eslint-disable fb-www/unsafe-html */ + +var ExecutionEnvironment = __webpack_require__(13); + +var invariant = __webpack_require__(2); + +/** + * Dummy container used to detect which wraps are necessary. + */ +var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; + +/** + * Some browsers cannot use `innerHTML` to render certain elements standalone, + * so we wrap them, render the wrapped nodes, then extract the desired node. + * + * In IE8, certain elements cannot render alone, so wrap all elements ('*'). + */ + +var shouldWrap = {}; + +var selectWrap = [1, '<select multiple="true">', '</select>']; +var tableWrap = [1, '<table>', '</table>']; +var trWrap = [3, '<table><tbody><tr>', '</tr></tbody></table>']; + +var svgWrap = [1, '<svg xmlns="http://www.w3.org/2000/svg">', '</svg>']; + +var markupWrap = { + '*': [1, '?<div>', '</div>'], + + 'area': [1, '<map>', '</map>'], + 'col': [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>'], + 'legend': [1, '<fieldset>', '</fieldset>'], + 'param': [1, '<object>', '</object>'], + 'tr': [2, '<table><tbody>', '</tbody></table>'], + + 'optgroup': selectWrap, + 'option': selectWrap, + + 'caption': tableWrap, + 'colgroup': tableWrap, + 'tbody': tableWrap, + 'tfoot': tableWrap, + 'thead': tableWrap, + + 'td': trWrap, + 'th': trWrap +}; + +// Initialize the SVG elements since we know they'll always need to be wrapped +// consistently. If they are created inside a <div> they will be initialized in +// the wrong namespace (and will not display). +var svgElements = ['circle', 'clipPath', 'defs', 'ellipse', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'text', 'tspan']; +svgElements.forEach(function (nodeName) { + markupWrap[nodeName] = svgWrap; + shouldWrap[nodeName] = true; +}); + +/** + * Gets the markup wrap configuration for the supplied `nodeName`. + * + * NOTE: This lazily detects which wraps are necessary for the current browser. + * + * @param {string} nodeName Lowercase `nodeName`. + * @return {?array} Markup wrap configuration, if applicable. + */ +function getMarkupWrap(nodeName) { + !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Markup wrapping node not initialized') : invariant(false) : void 0; + if (!markupWrap.hasOwnProperty(nodeName)) { + nodeName = '*'; + } + if (!shouldWrap.hasOwnProperty(nodeName)) { + if (nodeName === '*') { + dummyNode.innerHTML = '<link />'; + } else { + dummyNode.innerHTML = '<' + nodeName + '></' + nodeName + '>'; + } + shouldWrap[nodeName] = !dummyNode.firstChild; + } + return shouldWrap[nodeName] ? markupWrap[nodeName] : null; +} + +module.exports = getMarkupWrap; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 253 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMChildrenOperations = __webpack_require__(82); +var ReactDOMComponentTree = __webpack_require__(10); + +/** + * Operations used to process updates to DOM nodes. + */ +var ReactDOMIDOperations = { + /** + * Updates a component's children by processing a series of updates. + * + * @param {array<object>} updates List of update configurations. + * @internal + */ + dangerouslyProcessChildrenUpdates: function (parentInst, updates) { + var node = ReactDOMComponentTree.getNodeFromInstance(parentInst); + DOMChildrenOperations.processUpdates(node, updates); + } +}; + +module.exports = ReactDOMIDOperations; + +/***/ }), +/* 254 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/* global hasOwnProperty:true */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var AutoFocusUtils = __webpack_require__(255); +var CSSPropertyOperations = __webpack_require__(256); +var DOMLazyTree = __webpack_require__(39); +var DOMNamespaces = __webpack_require__(83); +var DOMProperty = __webpack_require__(28); +var DOMPropertyOperations = __webpack_require__(138); +var EventPluginHub = __webpack_require__(46); +var EventPluginRegistry = __webpack_require__(57); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactDOMComponentFlags = __webpack_require__(126); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMInput = __webpack_require__(266); +var ReactDOMOption = __webpack_require__(267); +var ReactDOMSelect = __webpack_require__(140); +var ReactDOMTextarea = __webpack_require__(268); +var ReactInstrumentation = __webpack_require__(19); +var ReactMultiChild = __webpack_require__(269); +var ReactServerRenderingTransaction = __webpack_require__(278); + +var emptyFunction = __webpack_require__(18); +var escapeTextContentForBrowser = __webpack_require__(61); +var invariant = __webpack_require__(2); +var isEventSupported = __webpack_require__(80); +var shallowEqual = __webpack_require__(87); +var inputValueTracking = __webpack_require__(132); +var validateDOMNesting = __webpack_require__(91); +var warning = __webpack_require__(3); + +var Flags = ReactDOMComponentFlags; +var deleteListener = EventPluginHub.deleteListener; +var getNode = ReactDOMComponentTree.getNodeFromInstance; +var listenTo = ReactBrowserEventEmitter.listenTo; +var registrationNameModules = EventPluginRegistry.registrationNameModules; + +// For quickly matching children type, to test if can be treated as content. +var CONTENT_TYPES = { string: true, number: true }; + +var STYLE = 'style'; +var HTML = '__html'; +var RESERVED_PROPS = { + children: null, + dangerouslySetInnerHTML: null, + suppressContentEditableWarning: null +}; + +// Node type for document fragments (Node.DOCUMENT_FRAGMENT_NODE). +var DOC_FRAGMENT_TYPE = 11; + +function getDeclarationErrorAddendum(internalInstance) { + if (internalInstance) { + var owner = internalInstance._currentElement._owner || null; + if (owner) { + var name = owner.getName(); + if (name) { + return ' This DOM node was rendered by `' + name + '`.'; + } + } + } + return ''; +} + +function friendlyStringify(obj) { + if (typeof obj === 'object') { + if (Array.isArray(obj)) { + return '[' + obj.map(friendlyStringify).join(', ') + ']'; + } else { + var pairs = []; + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key)) { + var keyEscaped = /^[a-z$_][\w$_]*$/i.test(key) ? key : JSON.stringify(key); + pairs.push(keyEscaped + ': ' + friendlyStringify(obj[key])); + } + } + return '{' + pairs.join(', ') + '}'; + } + } else if (typeof obj === 'string') { + return JSON.stringify(obj); + } else if (typeof obj === 'function') { + return '[function object]'; + } + // Differs from JSON.stringify in that undefined because undefined and that + // inf and nan don't become null + return String(obj); +} + +var styleMutationWarning = {}; + +function checkAndWarnForMutatedStyle(style1, style2, component) { + if (style1 == null || style2 == null) { + return; + } + if (shallowEqual(style1, style2)) { + return; + } + + var componentName = component._tag; + var owner = component._currentElement._owner; + var ownerName; + if (owner) { + ownerName = owner.getName(); + } + + var hash = ownerName + '|' + componentName; + + if (styleMutationWarning.hasOwnProperty(hash)) { + return; + } + + styleMutationWarning[hash] = true; + + process.env.NODE_ENV !== 'production' ? warning(false, '`%s` was passed a style object that has previously been mutated. ' + 'Mutating `style` is deprecated. Consider cloning it beforehand. Check ' + 'the `render` %s. Previous style: %s. Mutated style: %s.', componentName, owner ? 'of `' + ownerName + '`' : 'using <' + componentName + '>', friendlyStringify(style1), friendlyStringify(style2)) : void 0; +} + +/** + * @param {object} component + * @param {?object} props + */ +function assertValidProps(component, props) { + if (!props) { + return; + } + // Note the use of `==` which checks for null or undefined. + if (voidElementTags[component._tag]) { + !(props.children == null && props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.%s', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : _prodInvariant('137', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : void 0; + } + if (props.dangerouslySetInnerHTML != null) { + !(props.children == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Can only set one of `children` or `props.dangerouslySetInnerHTML`.') : _prodInvariant('60') : void 0; + !(typeof props.dangerouslySetInnerHTML === 'object' && HTML in props.dangerouslySetInnerHTML) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.') : _prodInvariant('61') : void 0; + } + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(props.innerHTML == null, 'Directly setting property `innerHTML` is not permitted. ' + 'For more information, lookup documentation on `dangerouslySetInnerHTML`.') : void 0; + process.env.NODE_ENV !== 'production' ? warning(props.suppressContentEditableWarning || !props.contentEditable || props.children == null, 'A component is `contentEditable` and contains `children` managed by ' + 'React. It is now your responsibility to guarantee that none of ' + 'those nodes are unexpectedly modified or duplicated. This is ' + 'probably not intentional.') : void 0; + process.env.NODE_ENV !== 'production' ? warning(props.onFocusIn == null && props.onFocusOut == null, 'React uses onFocus and onBlur instead of onFocusIn and onFocusOut. ' + 'All React events are normalized to bubble, so onFocusIn and onFocusOut ' + 'are not needed/supported by React.') : void 0; + } + !(props.style == null || typeof props.style === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + \'em\'}} when using JSX.%s', getDeclarationErrorAddendum(component)) : _prodInvariant('62', getDeclarationErrorAddendum(component)) : void 0; +} + +function enqueuePutListener(inst, registrationName, listener, transaction) { + if (transaction instanceof ReactServerRenderingTransaction) { + return; + } + if (process.env.NODE_ENV !== 'production') { + // IE8 has no API for event capturing and the `onScroll` event doesn't + // bubble. + process.env.NODE_ENV !== 'production' ? warning(registrationName !== 'onScroll' || isEventSupported('scroll', true), "This browser doesn't support the `onScroll` event") : void 0; + } + var containerInfo = inst._hostContainerInfo; + var isDocumentFragment = containerInfo._node && containerInfo._node.nodeType === DOC_FRAGMENT_TYPE; + var doc = isDocumentFragment ? containerInfo._node : containerInfo._ownerDocument; + listenTo(registrationName, doc); + transaction.getReactMountReady().enqueue(putListener, { + inst: inst, + registrationName: registrationName, + listener: listener + }); +} + +function putListener() { + var listenerToPut = this; + EventPluginHub.putListener(listenerToPut.inst, listenerToPut.registrationName, listenerToPut.listener); +} + +function inputPostMount() { + var inst = this; + ReactDOMInput.postMountWrapper(inst); +} + +function textareaPostMount() { + var inst = this; + ReactDOMTextarea.postMountWrapper(inst); +} + +function optionPostMount() { + var inst = this; + ReactDOMOption.postMountWrapper(inst); +} + +var setAndValidateContentChildDev = emptyFunction; +if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev = function (content) { + var hasExistingContent = this._contentDebugID != null; + var debugID = this._debugID; + // This ID represents the inlined child that has no backing instance: + var contentDebugID = -debugID; + + if (content == null) { + if (hasExistingContent) { + ReactInstrumentation.debugTool.onUnmountComponent(this._contentDebugID); + } + this._contentDebugID = null; + return; + } + + validateDOMNesting(null, String(content), this, this._ancestorInfo); + this._contentDebugID = contentDebugID; + if (hasExistingContent) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(contentDebugID, content); + ReactInstrumentation.debugTool.onUpdateComponent(contentDebugID); + } else { + ReactInstrumentation.debugTool.onBeforeMountComponent(contentDebugID, content, debugID); + ReactInstrumentation.debugTool.onMountComponent(contentDebugID); + ReactInstrumentation.debugTool.onSetChildren(debugID, [contentDebugID]); + } + }; +} + +// There are so many media events, it makes sense to just +// maintain a list rather than create a `trapBubbledEvent` for each +var mediaEvents = { + topAbort: 'abort', + topCanPlay: 'canplay', + topCanPlayThrough: 'canplaythrough', + topDurationChange: 'durationchange', + topEmptied: 'emptied', + topEncrypted: 'encrypted', + topEnded: 'ended', + topError: 'error', + topLoadedData: 'loadeddata', + topLoadedMetadata: 'loadedmetadata', + topLoadStart: 'loadstart', + topPause: 'pause', + topPlay: 'play', + topPlaying: 'playing', + topProgress: 'progress', + topRateChange: 'ratechange', + topSeeked: 'seeked', + topSeeking: 'seeking', + topStalled: 'stalled', + topSuspend: 'suspend', + topTimeUpdate: 'timeupdate', + topVolumeChange: 'volumechange', + topWaiting: 'waiting' +}; + +function trackInputValue() { + inputValueTracking.track(this); +} + +function trapBubbledEventsLocal() { + var inst = this; + // If a component renders to null or if another component fatals and causes + // the state of the tree to be corrupted, `node` here can be null. + !inst._rootNodeID ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Must be mounted to trap events') : _prodInvariant('63') : void 0; + var node = getNode(inst); + !node ? process.env.NODE_ENV !== 'production' ? invariant(false, 'trapBubbledEvent(...): Requires node to be rendered.') : _prodInvariant('64') : void 0; + + switch (inst._tag) { + case 'iframe': + case 'object': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; + break; + case 'video': + case 'audio': + inst._wrapperState.listeners = []; + // Create listener for each media event + for (var event in mediaEvents) { + if (mediaEvents.hasOwnProperty(event)) { + inst._wrapperState.listeners.push(ReactBrowserEventEmitter.trapBubbledEvent(event, mediaEvents[event], node)); + } + } + break; + case 'source': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node)]; + break; + case 'img': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node), ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; + break; + case 'form': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topReset', 'reset', node), ReactBrowserEventEmitter.trapBubbledEvent('topSubmit', 'submit', node)]; + break; + case 'input': + case 'select': + case 'textarea': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topInvalid', 'invalid', node)]; + break; + } +} + +function postUpdateSelectWrapper() { + ReactDOMSelect.postUpdateWrapper(this); +} + +// For HTML, certain tags should omit their close tag. We keep a whitelist for +// those special-case tags. + +var omittedCloseTags = { + area: true, + base: true, + br: true, + col: true, + embed: true, + hr: true, + img: true, + input: true, + keygen: true, + link: true, + meta: true, + param: true, + source: true, + track: true, + wbr: true + // NOTE: menuitem's close tag should be omitted, but that causes problems. +}; + +var newlineEatingTags = { + listing: true, + pre: true, + textarea: true +}; + +// For HTML, certain tags cannot have children. This has the same purpose as +// `omittedCloseTags` except that `menuitem` should still have its closing tag. + +var voidElementTags = _assign({ + menuitem: true +}, omittedCloseTags); + +// We accept any tag to be rendered but since this gets injected into arbitrary +// HTML, we want to make sure that it's a safe tag. +// http://www.w3.org/TR/REC-xml/#NT-Name + +var VALID_TAG_REGEX = /^[a-zA-Z][a-zA-Z:_\.\-\d]*$/; // Simplified subset +var validatedTagCache = {}; +var hasOwnProperty = {}.hasOwnProperty; + +function validateDangerousTag(tag) { + if (!hasOwnProperty.call(validatedTagCache, tag)) { + !VALID_TAG_REGEX.test(tag) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Invalid tag: %s', tag) : _prodInvariant('65', tag) : void 0; + validatedTagCache[tag] = true; + } +} + +function isCustomComponent(tagName, props) { + return tagName.indexOf('-') >= 0 || props.is != null; +} + +var globalIdCounter = 1; + +/** + * Creates a new React class that is idempotent and capable of containing other + * React components. It accepts event listeners and DOM properties that are + * valid according to `DOMProperty`. + * + * - Event listeners: `onClick`, `onMouseDown`, etc. + * - DOM properties: `className`, `name`, `title`, etc. + * + * The `style` property functions differently from the DOM API. It accepts an + * object mapping of style properties to values. + * + * @constructor ReactDOMComponent + * @extends ReactMultiChild + */ +function ReactDOMComponent(element) { + var tag = element.type; + validateDangerousTag(tag); + this._currentElement = element; + this._tag = tag.toLowerCase(); + this._namespaceURI = null; + this._renderedChildren = null; + this._previousStyle = null; + this._previousStyleCopy = null; + this._hostNode = null; + this._hostParent = null; + this._rootNodeID = 0; + this._domID = 0; + this._hostContainerInfo = null; + this._wrapperState = null; + this._topLevelWrapper = null; + this._flags = 0; + if (process.env.NODE_ENV !== 'production') { + this._ancestorInfo = null; + setAndValidateContentChildDev.call(this, null); + } +} + +ReactDOMComponent.displayName = 'ReactDOMComponent'; + +ReactDOMComponent.Mixin = { + /** + * Generates root tag markup then recurses. This method has side effects and + * is not idempotent. + * + * @internal + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?ReactDOMComponent} the parent component instance + * @param {?object} info about the host container + * @param {object} context + * @return {string} The computed markup. + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + this._rootNodeID = globalIdCounter++; + this._domID = hostContainerInfo._idCounter++; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; + + var props = this._currentElement.props; + + switch (this._tag) { + case 'audio': + case 'form': + case 'iframe': + case 'img': + case 'link': + case 'object': + case 'source': + case 'video': + this._wrapperState = { + listeners: null + }; + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'input': + ReactDOMInput.mountWrapper(this, props, hostParent); + props = ReactDOMInput.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trackInputValue, this); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'option': + ReactDOMOption.mountWrapper(this, props, hostParent); + props = ReactDOMOption.getHostProps(this, props); + break; + case 'select': + ReactDOMSelect.mountWrapper(this, props, hostParent); + props = ReactDOMSelect.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'textarea': + ReactDOMTextarea.mountWrapper(this, props, hostParent); + props = ReactDOMTextarea.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trackInputValue, this); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + } + + assertValidProps(this, props); + + // We create tags in the namespace of their parent container, except HTML + // tags get no namespace. + var namespaceURI; + var parentTag; + if (hostParent != null) { + namespaceURI = hostParent._namespaceURI; + parentTag = hostParent._tag; + } else if (hostContainerInfo._tag) { + namespaceURI = hostContainerInfo._namespaceURI; + parentTag = hostContainerInfo._tag; + } + if (namespaceURI == null || namespaceURI === DOMNamespaces.svg && parentTag === 'foreignobject') { + namespaceURI = DOMNamespaces.html; + } + if (namespaceURI === DOMNamespaces.html) { + if (this._tag === 'svg') { + namespaceURI = DOMNamespaces.svg; + } else if (this._tag === 'math') { + namespaceURI = DOMNamespaces.mathml; + } + } + this._namespaceURI = namespaceURI; + + if (process.env.NODE_ENV !== 'production') { + var parentInfo; + if (hostParent != null) { + parentInfo = hostParent._ancestorInfo; + } else if (hostContainerInfo._tag) { + parentInfo = hostContainerInfo._ancestorInfo; + } + if (parentInfo) { + // parentInfo should always be present except for the top-level + // component when server rendering + validateDOMNesting(this._tag, null, this, parentInfo); + } + this._ancestorInfo = validateDOMNesting.updatedAncestorInfo(parentInfo, this._tag, this); + } + + var mountImage; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var el; + if (namespaceURI === DOMNamespaces.html) { + if (this._tag === 'script') { + // Create the script via .innerHTML so its "parser-inserted" flag is + // set to true and it does not execute + var div = ownerDocument.createElement('div'); + var type = this._currentElement.type; + div.innerHTML = '<' + type + '></' + type + '>'; + el = div.removeChild(div.firstChild); + } else if (props.is) { + el = ownerDocument.createElement(this._currentElement.type, props.is); + } else { + // Separate else branch instead of using `props.is || undefined` above becuase of a Firefox bug. + // See discussion in https://github.com/facebook/react/pull/6896 + // and discussion in https://bugzilla.mozilla.org/show_bug.cgi?id=1276240 + el = ownerDocument.createElement(this._currentElement.type); + } + } else { + el = ownerDocument.createElementNS(namespaceURI, this._currentElement.type); + } + ReactDOMComponentTree.precacheNode(this, el); + this._flags |= Flags.hasCachedChildNodes; + if (!this._hostParent) { + DOMPropertyOperations.setAttributeForRoot(el); + } + this._updateDOMProperties(null, props, transaction); + var lazyTree = DOMLazyTree(el); + this._createInitialChildren(transaction, props, context, lazyTree); + mountImage = lazyTree; + } else { + var tagOpen = this._createOpenTagMarkupAndPutListeners(transaction, props); + var tagContent = this._createContentMarkup(transaction, props, context); + if (!tagContent && omittedCloseTags[this._tag]) { + mountImage = tagOpen + '/>'; + } else { + mountImage = tagOpen + '>' + tagContent + '</' + this._currentElement.type + '>'; + } + } + + switch (this._tag) { + case 'input': + transaction.getReactMountReady().enqueue(inputPostMount, this); + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'textarea': + transaction.getReactMountReady().enqueue(textareaPostMount, this); + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'select': + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'button': + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'option': + transaction.getReactMountReady().enqueue(optionPostMount, this); + break; + } + + return mountImage; + }, + + /** + * Creates markup for the open tag and all attributes. + * + * This method has side effects because events get registered. + * + * Iterating over object properties is faster than iterating over arrays. + * @see http://jsperf.com/obj-vs-arr-iteration + * + * @private + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} props + * @return {string} Markup of opening tag. + */ + _createOpenTagMarkupAndPutListeners: function (transaction, props) { + var ret = '<' + this._currentElement.type; + + for (var propKey in props) { + if (!props.hasOwnProperty(propKey)) { + continue; + } + var propValue = props[propKey]; + if (propValue == null) { + continue; + } + if (registrationNameModules.hasOwnProperty(propKey)) { + if (propValue) { + enqueuePutListener(this, propKey, propValue, transaction); + } + } else { + if (propKey === STYLE) { + if (propValue) { + if (process.env.NODE_ENV !== 'production') { + // See `_updateDOMProperties`. style block + this._previousStyle = propValue; + } + propValue = this._previousStyleCopy = _assign({}, props.style); + } + propValue = CSSPropertyOperations.createMarkupForStyles(propValue, this); + } + var markup = null; + if (this._tag != null && isCustomComponent(this._tag, props)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + markup = DOMPropertyOperations.createMarkupForCustomAttribute(propKey, propValue); + } + } else { + markup = DOMPropertyOperations.createMarkupForProperty(propKey, propValue); + } + if (markup) { + ret += ' ' + markup; + } + } + } + + // For static pages, no need to put React ID and checksum. Saves lots of + // bytes. + if (transaction.renderToStaticMarkup) { + return ret; + } + + if (!this._hostParent) { + ret += ' ' + DOMPropertyOperations.createMarkupForRoot(); + } + ret += ' ' + DOMPropertyOperations.createMarkupForID(this._domID); + return ret; + }, + + /** + * Creates markup for the content between the tags. + * + * @private + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} props + * @param {object} context + * @return {string} Content markup. + */ + _createContentMarkup: function (transaction, props, context) { + var ret = ''; + + // Intentional use of != to avoid catching zero/false. + var innerHTML = props.dangerouslySetInnerHTML; if (innerHTML != null) { if (innerHTML.__html != null) { ret = innerHTML.__html; } } else { - var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; - var childrenToUse = contentToUse != null ? null : props.children; - if (contentToUse != null) { - // TODO: Validate that text is allowed as a child of this node - ret = escapeTextContentForBrowser(contentToUse); - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, contentToUse); + var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; + var childrenToUse = contentToUse != null ? null : props.children; + if (contentToUse != null) { + // TODO: Validate that text is allowed as a child of this node + ret = escapeTextContentForBrowser(contentToUse); + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, contentToUse); + } + } else if (childrenToUse != null) { + var mountImages = this.mountChildren(childrenToUse, transaction, context); + ret = mountImages.join(''); + } + } + if (newlineEatingTags[this._tag] && ret.charAt(0) === '\n') { + // text/html ignores the first character in these tags if it's a newline + // Prefer to break application/xml over text/html (for now) by adding + // a newline specifically to get eaten by the parser. (Alternately for + // textareas, replacing "^\n" with "\r\n" doesn't get eaten, and the first + // \r is normalized out by HTMLTextAreaElement#value.) + // See: <http://www.w3.org/TR/html-polyglot/#newlines-in-textarea-and-pre> + // See: <http://www.w3.org/TR/html5/syntax.html#element-restrictions> + // See: <http://www.w3.org/TR/html5/syntax.html#newlines> + // See: Parsing of "textarea" "listing" and "pre" elements + // from <http://www.w3.org/TR/html5/syntax.html#parsing-main-inbody> + return '\n' + ret; + } else { + return ret; + } + }, + + _createInitialChildren: function (transaction, props, context, lazyTree) { + // Intentional use of != to avoid catching zero/false. + var innerHTML = props.dangerouslySetInnerHTML; + if (innerHTML != null) { + if (innerHTML.__html != null) { + DOMLazyTree.queueHTML(lazyTree, innerHTML.__html); + } + } else { + var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; + var childrenToUse = contentToUse != null ? null : props.children; + // TODO: Validate that text is allowed as a child of this node + if (contentToUse != null) { + // Avoid setting textContent when the text is empty. In IE11 setting + // textContent on a text area will cause the placeholder to not + // show within the textarea until it has been focused and blurred again. + // https://github.com/facebook/react/issues/6731#issuecomment-254874553 + if (contentToUse !== '') { + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, contentToUse); + } + DOMLazyTree.queueText(lazyTree, contentToUse); + } + } else if (childrenToUse != null) { + var mountImages = this.mountChildren(childrenToUse, transaction, context); + for (var i = 0; i < mountImages.length; i++) { + DOMLazyTree.queueChild(lazyTree, mountImages[i]); + } + } + } + }, + + /** + * Receives a next element and updates the component. + * + * @internal + * @param {ReactElement} nextElement + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} context + */ + receiveComponent: function (nextElement, transaction, context) { + var prevElement = this._currentElement; + this._currentElement = nextElement; + this.updateComponent(transaction, prevElement, nextElement, context); + }, + + /** + * Updates a DOM component after it has already been allocated and + * attached to the DOM. Reconciles the root DOM node, then recurses. + * + * @param {ReactReconcileTransaction} transaction + * @param {ReactElement} prevElement + * @param {ReactElement} nextElement + * @internal + * @overridable + */ + updateComponent: function (transaction, prevElement, nextElement, context) { + var lastProps = prevElement.props; + var nextProps = this._currentElement.props; + + switch (this._tag) { + case 'input': + lastProps = ReactDOMInput.getHostProps(this, lastProps); + nextProps = ReactDOMInput.getHostProps(this, nextProps); + break; + case 'option': + lastProps = ReactDOMOption.getHostProps(this, lastProps); + nextProps = ReactDOMOption.getHostProps(this, nextProps); + break; + case 'select': + lastProps = ReactDOMSelect.getHostProps(this, lastProps); + nextProps = ReactDOMSelect.getHostProps(this, nextProps); + break; + case 'textarea': + lastProps = ReactDOMTextarea.getHostProps(this, lastProps); + nextProps = ReactDOMTextarea.getHostProps(this, nextProps); + break; + } + + assertValidProps(this, nextProps); + this._updateDOMProperties(lastProps, nextProps, transaction); + this._updateDOMChildren(lastProps, nextProps, transaction, context); + + switch (this._tag) { + case 'input': + // Update the wrapper around inputs *after* updating props. This has to + // happen after `_updateDOMProperties`. Otherwise HTML5 input validations + // raise warnings and prevent the new value from being assigned. + ReactDOMInput.updateWrapper(this); + break; + case 'textarea': + ReactDOMTextarea.updateWrapper(this); + break; + case 'select': + // <select> value update needs to occur after <option> children + // reconciliation + transaction.getReactMountReady().enqueue(postUpdateSelectWrapper, this); + break; + } + }, + + /** + * Reconciles the properties by detecting differences in property values and + * updating the DOM as necessary. This function is probably the single most + * critical path for performance optimization. + * + * TODO: Benchmark whether checking for changed values in memory actually + * improves performance (especially statically positioned elements). + * TODO: Benchmark the effects of putting this at the top since 99% of props + * do not change for a given reconciliation. + * TODO: Benchmark areas that can be improved with caching. + * + * @private + * @param {object} lastProps + * @param {object} nextProps + * @param {?DOMElement} node + */ + _updateDOMProperties: function (lastProps, nextProps, transaction) { + var propKey; + var styleName; + var styleUpdates; + for (propKey in lastProps) { + if (nextProps.hasOwnProperty(propKey) || !lastProps.hasOwnProperty(propKey) || lastProps[propKey] == null) { + continue; + } + if (propKey === STYLE) { + var lastStyle = this._previousStyleCopy; + for (styleName in lastStyle) { + if (lastStyle.hasOwnProperty(styleName)) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = ''; + } + } + this._previousStyleCopy = null; + } else if (registrationNameModules.hasOwnProperty(propKey)) { + if (lastProps[propKey]) { + // Only call deleteListener if there was a listener previously or + // else willDeleteListener gets called when there wasn't actually a + // listener (e.g., onClick={null}) + deleteListener(this, propKey); + } + } else if (isCustomComponent(this._tag, lastProps)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + DOMPropertyOperations.deleteValueForAttribute(getNode(this), propKey); + } + } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { + DOMPropertyOperations.deleteValueForProperty(getNode(this), propKey); + } + } + for (propKey in nextProps) { + var nextProp = nextProps[propKey]; + var lastProp = propKey === STYLE ? this._previousStyleCopy : lastProps != null ? lastProps[propKey] : undefined; + if (!nextProps.hasOwnProperty(propKey) || nextProp === lastProp || nextProp == null && lastProp == null) { + continue; + } + if (propKey === STYLE) { + if (nextProp) { + if (process.env.NODE_ENV !== 'production') { + checkAndWarnForMutatedStyle(this._previousStyleCopy, this._previousStyle, this); + this._previousStyle = nextProp; + } + nextProp = this._previousStyleCopy = _assign({}, nextProp); + } else { + this._previousStyleCopy = null; + } + if (lastProp) { + // Unset styles on `lastProp` but not on `nextProp`. + for (styleName in lastProp) { + if (lastProp.hasOwnProperty(styleName) && (!nextProp || !nextProp.hasOwnProperty(styleName))) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = ''; + } + } + // Update styles that changed since `lastProp`. + for (styleName in nextProp) { + if (nextProp.hasOwnProperty(styleName) && lastProp[styleName] !== nextProp[styleName]) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = nextProp[styleName]; + } + } + } else { + // Relies on `updateStylesByID` not mutating `styleUpdates`. + styleUpdates = nextProp; + } + } else if (registrationNameModules.hasOwnProperty(propKey)) { + if (nextProp) { + enqueuePutListener(this, propKey, nextProp, transaction); + } else if (lastProp) { + deleteListener(this, propKey); + } + } else if (isCustomComponent(this._tag, nextProps)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + DOMPropertyOperations.setValueForAttribute(getNode(this), propKey, nextProp); + } + } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { + var node = getNode(this); + // If we're updating to null or undefined, we should remove the property + // from the DOM node instead of inadvertently setting to a string. This + // brings us in line with the same behavior we have on initial render. + if (nextProp != null) { + DOMPropertyOperations.setValueForProperty(node, propKey, nextProp); + } else { + DOMPropertyOperations.deleteValueForProperty(node, propKey); + } + } + } + if (styleUpdates) { + CSSPropertyOperations.setValueForStyles(getNode(this), styleUpdates, this); + } + }, + + /** + * Reconciles the children with the various properties that affect the + * children content. + * + * @param {object} lastProps + * @param {object} nextProps + * @param {ReactReconcileTransaction} transaction + * @param {object} context + */ + _updateDOMChildren: function (lastProps, nextProps, transaction, context) { + var lastContent = CONTENT_TYPES[typeof lastProps.children] ? lastProps.children : null; + var nextContent = CONTENT_TYPES[typeof nextProps.children] ? nextProps.children : null; + + var lastHtml = lastProps.dangerouslySetInnerHTML && lastProps.dangerouslySetInnerHTML.__html; + var nextHtml = nextProps.dangerouslySetInnerHTML && nextProps.dangerouslySetInnerHTML.__html; + + // Note the use of `!=` which checks for null or undefined. + var lastChildren = lastContent != null ? null : lastProps.children; + var nextChildren = nextContent != null ? null : nextProps.children; + + // If we're switching from children to content/html or vice versa, remove + // the old content + var lastHasContentOrHtml = lastContent != null || lastHtml != null; + var nextHasContentOrHtml = nextContent != null || nextHtml != null; + if (lastChildren != null && nextChildren == null) { + this.updateChildren(null, transaction, context); + } else if (lastHasContentOrHtml && !nextHasContentOrHtml) { + this.updateTextContent(''); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); + } + } + + if (nextContent != null) { + if (lastContent !== nextContent) { + this.updateTextContent('' + nextContent); + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, nextContent); + } + } + } else if (nextHtml != null) { + if (lastHtml !== nextHtml) { + this.updateMarkup('' + nextHtml); + } + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); + } + } else if (nextChildren != null) { + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, null); + } + + this.updateChildren(nextChildren, transaction, context); + } + }, + + getHostNode: function () { + return getNode(this); + }, + + /** + * Destroys all event registrations for this instance. Does not remove from + * the DOM. That must be done by the parent. + * + * @internal + */ + unmountComponent: function (safely) { + switch (this._tag) { + case 'audio': + case 'form': + case 'iframe': + case 'img': + case 'link': + case 'object': + case 'source': + case 'video': + var listeners = this._wrapperState.listeners; + if (listeners) { + for (var i = 0; i < listeners.length; i++) { + listeners[i].remove(); + } + } + break; + case 'input': + case 'textarea': + inputValueTracking.stopTracking(this); + break; + case 'html': + case 'head': + case 'body': + /** + * Components like <html> <head> and <body> can't be removed or added + * easily in a cross-browser way, however it's valuable to be able to + * take advantage of React's reconciliation for styling and <title> + * management. So we just document it and throw in dangerous cases. + */ + true ? process.env.NODE_ENV !== 'production' ? invariant(false, '<%s> tried to unmount. Because of cross-browser quirks it is impossible to unmount some top-level components (eg <html>, <head>, and <body>) reliably and efficiently. To fix this, have a single top-level component that never unmounts render these elements.', this._tag) : _prodInvariant('66', this._tag) : void 0; + break; + } + + this.unmountChildren(safely); + ReactDOMComponentTree.uncacheNode(this); + EventPluginHub.deleteAllListeners(this); + this._rootNodeID = 0; + this._domID = 0; + this._wrapperState = null; + + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, null); + } + }, + + getPublicInstance: function () { + return getNode(this); + } +}; + +_assign(ReactDOMComponent.prototype, ReactDOMComponent.Mixin, ReactMultiChild.Mixin); + +module.exports = ReactDOMComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 255 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMComponentTree = __webpack_require__(10); + +var focusNode = __webpack_require__(136); + +var AutoFocusUtils = { + focusDOMComponent: function () { + focusNode(ReactDOMComponentTree.getNodeFromInstance(this)); + } +}; + +module.exports = AutoFocusUtils; + +/***/ }), +/* 256 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var CSSProperty = __webpack_require__(137); +var ExecutionEnvironment = __webpack_require__(13); +var ReactInstrumentation = __webpack_require__(19); + +var camelizeStyleName = __webpack_require__(257); +var dangerousStyleValue = __webpack_require__(259); +var hyphenateStyleName = __webpack_require__(260); +var memoizeStringOnly = __webpack_require__(262); +var warning = __webpack_require__(3); + +var processStyleName = memoizeStringOnly(function (styleName) { + return hyphenateStyleName(styleName); +}); + +var hasShorthandPropertyBug = false; +var styleFloatAccessor = 'cssFloat'; +if (ExecutionEnvironment.canUseDOM) { + var tempStyle = document.createElement('div').style; + try { + // IE8 throws "Invalid argument." if resetting shorthand style properties. + tempStyle.font = ''; + } catch (e) { + hasShorthandPropertyBug = true; + } + // IE8 only supports accessing cssFloat (standard) as styleFloat + if (document.documentElement.style.cssFloat === undefined) { + styleFloatAccessor = 'styleFloat'; + } +} + +if (process.env.NODE_ENV !== 'production') { + // 'msTransform' is correct, but the other prefixes should be capitalized + var badVendoredStyleNamePattern = /^(?:webkit|moz|o)[A-Z]/; + + // style values shouldn't contain a semicolon + var badStyleValueWithSemicolonPattern = /;\s*$/; + + var warnedStyleNames = {}; + var warnedStyleValues = {}; + var warnedForNaNValue = false; + + var warnHyphenatedStyleName = function (name, owner) { + if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { + return; + } + + warnedStyleNames[name] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported style property %s. Did you mean %s?%s', name, camelizeStyleName(name), checkRenderMessage(owner)) : void 0; + }; + + var warnBadVendoredStyleName = function (name, owner) { + if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { + return; + } + + warnedStyleNames[name] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported vendor-prefixed style property %s. Did you mean %s?%s', name, name.charAt(0).toUpperCase() + name.slice(1), checkRenderMessage(owner)) : void 0; + }; + + var warnStyleValueWithSemicolon = function (name, value, owner) { + if (warnedStyleValues.hasOwnProperty(value) && warnedStyleValues[value]) { + return; + } + + warnedStyleValues[value] = true; + process.env.NODE_ENV !== 'production' ? warning(false, "Style property values shouldn't contain a semicolon.%s " + 'Try "%s: %s" instead.', checkRenderMessage(owner), name, value.replace(badStyleValueWithSemicolonPattern, '')) : void 0; + }; + + var warnStyleValueIsNaN = function (name, value, owner) { + if (warnedForNaNValue) { + return; + } + + warnedForNaNValue = true; + process.env.NODE_ENV !== 'production' ? warning(false, '`NaN` is an invalid value for the `%s` css style property.%s', name, checkRenderMessage(owner)) : void 0; + }; + + var checkRenderMessage = function (owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; + }; + + /** + * @param {string} name + * @param {*} value + * @param {ReactDOMComponent} component + */ + var warnValidStyle = function (name, value, component) { + var owner; + if (component) { + owner = component._currentElement._owner; + } + if (name.indexOf('-') > -1) { + warnHyphenatedStyleName(name, owner); + } else if (badVendoredStyleNamePattern.test(name)) { + warnBadVendoredStyleName(name, owner); + } else if (badStyleValueWithSemicolonPattern.test(value)) { + warnStyleValueWithSemicolon(name, value, owner); + } + + if (typeof value === 'number' && isNaN(value)) { + warnStyleValueIsNaN(name, value, owner); + } + }; +} + +/** + * Operations for dealing with CSS properties. + */ +var CSSPropertyOperations = { + /** + * Serializes a mapping of style properties for use as inline styles: + * + * > createMarkupForStyles({width: '200px', height: 0}) + * "width:200px;height:0;" + * + * Undefined values are ignored so that declarative programming is easier. + * The result should be HTML-escaped before insertion into the DOM. + * + * @param {object} styles + * @param {ReactDOMComponent} component + * @return {?string} + */ + createMarkupForStyles: function (styles, component) { + var serialized = ''; + for (var styleName in styles) { + if (!styles.hasOwnProperty(styleName)) { + continue; + } + var isCustomProperty = styleName.indexOf('--') === 0; + var styleValue = styles[styleName]; + if (process.env.NODE_ENV !== 'production') { + if (!isCustomProperty) { + warnValidStyle(styleName, styleValue, component); + } + } + if (styleValue != null) { + serialized += processStyleName(styleName) + ':'; + serialized += dangerousStyleValue(styleName, styleValue, component, isCustomProperty) + ';'; + } + } + return serialized || null; + }, + + /** + * Sets the value for multiple styles on a node. If a value is specified as + * '' (empty string), the corresponding style property will be unset. + * + * @param {DOMElement} node + * @param {object} styles + * @param {ReactDOMComponent} component + */ + setValueForStyles: function (node, styles, component) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: component._debugID, + type: 'update styles', + payload: styles + }); + } + + var style = node.style; + for (var styleName in styles) { + if (!styles.hasOwnProperty(styleName)) { + continue; + } + var isCustomProperty = styleName.indexOf('--') === 0; + if (process.env.NODE_ENV !== 'production') { + if (!isCustomProperty) { + warnValidStyle(styleName, styles[styleName], component); + } + } + var styleValue = dangerousStyleValue(styleName, styles[styleName], component, isCustomProperty); + if (styleName === 'float' || styleName === 'cssFloat') { + styleName = styleFloatAccessor; + } + if (isCustomProperty) { + style.setProperty(styleName, styleValue); + } else if (styleValue) { + style[styleName] = styleValue; + } else { + var expansion = hasShorthandPropertyBug && CSSProperty.shorthandPropertyExpansions[styleName]; + if (expansion) { + // Shorthand property that IE8 won't like unsetting, so unset each + // component to placate it + for (var individualStyleName in expansion) { + style[individualStyleName] = ''; + } + } else { + style[styleName] = ''; + } + } + } + } +}; + +module.exports = CSSPropertyOperations; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 257 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + + + +var camelize = __webpack_require__(258); + +var msPattern = /^-ms-/; + +/** + * Camelcases a hyphenated CSS property name, for example: + * + * > camelizeStyleName('background-color') + * < "backgroundColor" + * > camelizeStyleName('-moz-transition') + * < "MozTransition" + * > camelizeStyleName('-ms-transition') + * < "msTransition" + * + * As Andi Smith suggests + * (http://www.andismith.com/blog/2012/02/modernizr-prefixed/), an `-ms` prefix + * is converted to lowercase `ms`. + * + * @param {string} string + * @return {string} + */ +function camelizeStyleName(string) { + return camelize(string.replace(msPattern, 'ms-')); +} + +module.exports = camelizeStyleName; + +/***/ }), +/* 258 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var _hyphenPattern = /-(.)/g; + +/** + * Camelcases a hyphenated string, for example: + * + * > camelize('background-color') + * < "backgroundColor" + * + * @param {string} string + * @return {string} + */ +function camelize(string) { + return string.replace(_hyphenPattern, function (_, character) { + return character.toUpperCase(); + }); +} + +module.exports = camelize; + +/***/ }), +/* 259 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var CSSProperty = __webpack_require__(137); +var warning = __webpack_require__(3); + +var isUnitlessNumber = CSSProperty.isUnitlessNumber; +var styleWarnings = {}; + +/** + * Convert a value into the proper css writable value. The style name `name` + * should be logical (no hyphens), as specified + * in `CSSProperty.isUnitlessNumber`. + * + * @param {string} name CSS property name such as `topMargin`. + * @param {*} value CSS property value such as `10px`. + * @param {ReactDOMComponent} component + * @return {string} Normalized style value with dimensions applied. + */ +function dangerousStyleValue(name, value, component, isCustomProperty) { + // Note that we've removed escapeTextForBrowser() calls here since the + // whole string will be escaped when the attribute is injected into + // the markup. If you provide unsafe user data here they can inject + // arbitrary CSS which may be problematic (I couldn't repro this): + // https://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet + // http://www.thespanner.co.uk/2007/11/26/ultimate-xss-css-injection/ + // This is not an XSS hole but instead a potential CSS injection issue + // which has lead to a greater discussion about how we're going to + // trust URLs moving forward. See #2115901 + + var isEmpty = value == null || typeof value === 'boolean' || value === ''; + if (isEmpty) { + return ''; + } + + var isNonNumeric = isNaN(value); + if (isCustomProperty || isNonNumeric || value === 0 || isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name]) { + return '' + value; // cast to string + } + + if (typeof value === 'string') { + if (process.env.NODE_ENV !== 'production') { + // Allow '0' to pass through without warning. 0 is already special and + // doesn't require units, so we don't need to warn about it. + if (component && value !== '0') { + var owner = component._currentElement._owner; + var ownerName = owner ? owner.getName() : null; + if (ownerName && !styleWarnings[ownerName]) { + styleWarnings[ownerName] = {}; + } + var warned = false; + if (ownerName) { + var warnings = styleWarnings[ownerName]; + warned = warnings[name]; + if (!warned) { + warnings[name] = true; + } + } + if (!warned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'a `%s` tag (owner: `%s`) was passed a numeric string value ' + 'for CSS property `%s` (value: `%s`) which will be treated ' + 'as a unitless number in a future version of React.', component._currentElement.type, ownerName || 'unknown', name, value) : void 0; + } + } + } + value = value.trim(); + } + return value + 'px'; +} + +module.exports = dangerousStyleValue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 260 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + + + +var hyphenate = __webpack_require__(261); + +var msPattern = /^ms-/; + +/** + * Hyphenates a camelcased CSS property name, for example: + * + * > hyphenateStyleName('backgroundColor') + * < "background-color" + * > hyphenateStyleName('MozTransition') + * < "-moz-transition" + * > hyphenateStyleName('msTransition') + * < "-ms-transition" + * + * As Modernizr suggests (http://modernizr.com/docs/#prefixed), an `ms` prefix + * is converted to `-ms-`. + * + * @param {string} string + * @return {string} + */ +function hyphenateStyleName(string) { + return hyphenate(string).replace(msPattern, '-ms-'); +} + +module.exports = hyphenateStyleName; + +/***/ }), +/* 261 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var _uppercasePattern = /([A-Z])/g; + +/** + * Hyphenates a camelcased string, for example: + * + * > hyphenate('backgroundColor') + * < "background-color" + * + * For CSS style names, use `hyphenateStyleName` instead which works properly + * with all vendor prefixes, including `ms`. + * + * @param {string} string + * @return {string} + */ +function hyphenate(string) { + return string.replace(_uppercasePattern, '-$1').toLowerCase(); +} + +module.exports = hyphenate; + +/***/ }), +/* 262 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + * @typechecks static-only + */ + + + +/** + * Memoizes the return value of a function that accepts one string argument. + */ + +function memoizeStringOnly(callback) { + var cache = {}; + return function (string) { + if (!cache.hasOwnProperty(string)) { + cache[string] = callback.call(this, string); + } + return cache[string]; + }; +} + +module.exports = memoizeStringOnly; + +/***/ }), +/* 263 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var escapeTextContentForBrowser = __webpack_require__(61); + +/** + * Escapes attribute value to prevent scripting attacks. + * + * @param {*} value Value to escape. + * @return {string} An escaped string. + */ +function quoteAttributeValueForBrowser(value) { + return '"' + escapeTextContentForBrowser(value) + '"'; +} + +module.exports = quoteAttributeValueForBrowser; + +/***/ }), +/* 264 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPluginHub = __webpack_require__(46); + +function runEventQueueInBatch(events) { + EventPluginHub.enqueueEvents(events); + EventPluginHub.processEventQueue(false); +} + +var ReactEventEmitterMixin = { + /** + * Streams a fired top-level event to `EventPluginHub` where plugins have the + * opportunity to create `ReactEvent`s to be dispatched. + */ + handleTopLevel: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var events = EventPluginHub.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); + runEventQueueInBatch(events); + } +}; + +module.exports = ReactEventEmitterMixin; + +/***/ }), +/* 265 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +/** + * Generate a mapping of standard vendor prefixes using the defined style property and event name. + * + * @param {string} styleProp + * @param {string} eventName + * @returns {object} + */ +function makePrefixMap(styleProp, eventName) { + var prefixes = {}; + + prefixes[styleProp.toLowerCase()] = eventName.toLowerCase(); + prefixes['Webkit' + styleProp] = 'webkit' + eventName; + prefixes['Moz' + styleProp] = 'moz' + eventName; + prefixes['ms' + styleProp] = 'MS' + eventName; + prefixes['O' + styleProp] = 'o' + eventName.toLowerCase(); + + return prefixes; +} + +/** + * A list of event names to a configurable list of vendor prefixes. + */ +var vendorPrefixes = { + animationend: makePrefixMap('Animation', 'AnimationEnd'), + animationiteration: makePrefixMap('Animation', 'AnimationIteration'), + animationstart: makePrefixMap('Animation', 'AnimationStart'), + transitionend: makePrefixMap('Transition', 'TransitionEnd') +}; + +/** + * Event names that have already been detected and prefixed (if applicable). + */ +var prefixedEventNames = {}; + +/** + * Element to check for prefixes on. + */ +var style = {}; + +/** + * Bootstrap if a DOM exists. + */ +if (ExecutionEnvironment.canUseDOM) { + style = document.createElement('div').style; + + // On some platforms, in particular some releases of Android 4.x, + // the un-prefixed "animation" and "transition" properties are defined on the + // style object but the events that fire will still be prefixed, so we need + // to check if the un-prefixed events are usable, and if not remove them from the map. + if (!('AnimationEvent' in window)) { + delete vendorPrefixes.animationend.animation; + delete vendorPrefixes.animationiteration.animation; + delete vendorPrefixes.animationstart.animation; + } + + // Same as above + if (!('TransitionEvent' in window)) { + delete vendorPrefixes.transitionend.transition; + } +} + +/** + * Attempts to determine the correct vendor prefixed event name. + * + * @param {string} eventName + * @returns {string} + */ +function getVendorPrefixedEventName(eventName) { + if (prefixedEventNames[eventName]) { + return prefixedEventNames[eventName]; + } else if (!vendorPrefixes[eventName]) { + return eventName; + } + + var prefixMap = vendorPrefixes[eventName]; + + for (var styleProp in prefixMap) { + if (prefixMap.hasOwnProperty(styleProp) && styleProp in style) { + return prefixedEventNames[eventName] = prefixMap[styleProp]; + } + } + + return ''; +} + +module.exports = getVendorPrefixedEventName; + +/***/ }), +/* 266 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var DOMPropertyOperations = __webpack_require__(138); +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var didWarnValueLink = false; +var didWarnCheckedLink = false; +var didWarnValueDefaultValue = false; +var didWarnCheckedDefaultChecked = false; +var didWarnControlledToUncontrolled = false; +var didWarnUncontrolledToControlled = false; + +function forceUpdateIfMounted() { + if (this._rootNodeID) { + // DOM component is still mounted; update + ReactDOMInput.updateWrapper(this); + } +} + +function isControlled(props) { + var usesChecked = props.type === 'checkbox' || props.type === 'radio'; + return usesChecked ? props.checked != null : props.value != null; +} + +/** + * Implements an <input> host component that allows setting these optional + * props: `checked`, `value`, `defaultChecked`, and `defaultValue`. + * + * If `checked` or `value` are not supplied (or null/undefined), user actions + * that affect the checked state or value will trigger updates to the element. + * + * If they are supplied (and not null/undefined), the rendered element will not + * trigger updates to the element. Instead, the props must change in order for + * the rendered element to be updated. + * + * The rendered element will be initialized as unchecked (or `defaultChecked`) + * with an empty value (or `defaultValue`). + * + * @see http://www.w3.org/TR/2012/WD-html5-20121025/the-input-element.html + */ +var ReactDOMInput = { + getHostProps: function (inst, props) { + var value = LinkedValueUtils.getValue(props); + var checked = LinkedValueUtils.getChecked(props); + + var hostProps = _assign({ + // Make sure we set .type before any other properties (setting .value + // before .type means .value is lost in IE11 and below) + type: undefined, + // Make sure we set .step before .value (setting .value before .step + // means .value is rounded on mount, based upon step precision) + step: undefined, + // Make sure we set .min & .max before .value (to ensure proper order + // in corner cases such as min or max deriving from value, e.g. Issue #7170) + min: undefined, + max: undefined + }, props, { + defaultChecked: undefined, + defaultValue: undefined, + value: value != null ? value : inst._wrapperState.initialValue, + checked: checked != null ? checked : inst._wrapperState.initialChecked, + onChange: inst._wrapperState.onChange + }); + + return hostProps; + }, + + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + LinkedValueUtils.checkPropTypes('input', props, inst._currentElement._owner); + + var owner = inst._currentElement._owner; + + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + if (props.checkedLink !== undefined && !didWarnCheckedLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`checkedLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnCheckedLink = true; + } + if (props.checked !== undefined && props.defaultChecked !== undefined && !didWarnCheckedDefaultChecked) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both checked and defaultChecked props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnCheckedDefaultChecked = true; + } + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both value and defaultValue props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnValueDefaultValue = true; + } + } + + var defaultValue = props.defaultValue; + inst._wrapperState = { + initialChecked: props.checked != null ? props.checked : props.defaultChecked, + initialValue: props.value != null ? props.value : defaultValue, + listeners: null, + onChange: _handleChange.bind(inst), + controlled: isControlled(props) + }; + }, + + updateWrapper: function (inst) { + var props = inst._currentElement.props; + + if (process.env.NODE_ENV !== 'production') { + var controlled = isControlled(props); + var owner = inst._currentElement._owner; + + if (!inst._wrapperState.controlled && controlled && !didWarnUncontrolledToControlled) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing an uncontrolled input of type %s to be controlled. ' + 'Input elements should not switch from uncontrolled to controlled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnUncontrolledToControlled = true; + } + if (inst._wrapperState.controlled && !controlled && !didWarnControlledToUncontrolled) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing a controlled input of type %s to be uncontrolled. ' + 'Input elements should not switch from controlled to uncontrolled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnControlledToUncontrolled = true; + } + } + + // TODO: Shouldn't this be getChecked(props)? + var checked = props.checked; + if (checked != null) { + DOMPropertyOperations.setValueForProperty(ReactDOMComponentTree.getNodeFromInstance(inst), 'checked', checked || false); + } + + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var value = LinkedValueUtils.getValue(props); + if (value != null) { + if (value === 0 && node.value === '') { + node.value = '0'; + // Note: IE9 reports a number inputs as 'text', so check props instead. + } else if (props.type === 'number') { + // Simulate `input.valueAsNumber`. IE9 does not support it + var valueAsNumber = parseFloat(node.value, 10) || 0; + + if ( + // eslint-disable-next-line + value != valueAsNumber || + // eslint-disable-next-line + value == valueAsNumber && node.value != value) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + node.value = '' + value; + } + } else if (node.value !== '' + value) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + node.value = '' + value; + } + } else { + if (props.value == null && props.defaultValue != null) { + // In Chrome, assigning defaultValue to certain input types triggers input validation. + // For number inputs, the display value loses trailing decimal points. For email inputs, + // Chrome raises "The specified value <x> is not a valid email address". + // + // Here we check to see if the defaultValue has actually changed, avoiding these problems + // when the user is inputting text + // + // https://github.com/facebook/react/issues/7253 + if (node.defaultValue !== '' + props.defaultValue) { + node.defaultValue = '' + props.defaultValue; + } + } + if (props.checked == null && props.defaultChecked != null) { + node.defaultChecked = !!props.defaultChecked; + } + } + }, + + postMountWrapper: function (inst) { + var props = inst._currentElement.props; + + // This is in postMount because we need access to the DOM node, which is not + // available until after the component has mounted. + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + + // Detach value from defaultValue. We won't do anything if we're working on + // submit or reset inputs as those values & defaultValues are linked. They + // are not resetable nodes so this operation doesn't matter and actually + // removes browser-default values (eg "Submit Query") when no value is + // provided. + + switch (props.type) { + case 'submit': + case 'reset': + break; + case 'color': + case 'date': + case 'datetime': + case 'datetime-local': + case 'month': + case 'time': + case 'week': + // This fixes the no-show issue on iOS Safari and Android Chrome: + // https://github.com/facebook/react/issues/7233 + node.value = ''; + node.value = node.defaultValue; + break; + default: + node.value = node.value; + break; + } + + // Normally, we'd just do `node.checked = node.checked` upon initial mount, less this bug + // this is needed to work around a chrome bug where setting defaultChecked + // will sometimes influence the value of checked (even after detachment). + // Reference: https://bugs.chromium.org/p/chromium/issues/detail?id=608416 + // We need to temporarily unset name to avoid disrupting radio button groups. + var name = node.name; + if (name !== '') { + node.name = ''; + } + node.defaultChecked = !node.defaultChecked; + node.defaultChecked = !node.defaultChecked; + if (name !== '') { + node.name = name; + } + } +}; + +function _handleChange(event) { + var props = this._currentElement.props; + + var returnValue = LinkedValueUtils.executeOnChange(props, event); + + // Here we use asap to wait until all updates have propagated, which + // is important when using controlled components within layers: + // https://github.com/facebook/react/issues/1698 + ReactUpdates.asap(forceUpdateIfMounted, this); + + var name = props.name; + if (props.type === 'radio' && name != null) { + var rootNode = ReactDOMComponentTree.getNodeFromInstance(this); + var queryRoot = rootNode; + + while (queryRoot.parentNode) { + queryRoot = queryRoot.parentNode; + } + + // If `rootNode.form` was non-null, then we could try `form.elements`, + // but that sometimes behaves strangely in IE8. We could also try using + // `form.getElementsByName`, but that will only return direct children + // and won't include inputs that use the HTML5 `form=` attribute. Since + // the input might not even be in a form, let's just use the global + // `querySelectorAll` to ensure we don't miss anything. + var group = queryRoot.querySelectorAll('input[name=' + JSON.stringify('' + name) + '][type="radio"]'); + + for (var i = 0; i < group.length; i++) { + var otherNode = group[i]; + if (otherNode === rootNode || otherNode.form !== rootNode.form) { + continue; + } + // This will throw if radio buttons rendered by different copies of React + // and the same name are rendered into the same form (same as #1939). + // That's probably okay; we don't support it just as we don't support + // mixing React radio buttons with non-React ones. + var otherInstance = ReactDOMComponentTree.getInstanceFromNode(otherNode); + !otherInstance ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOMInput: Mixing React and non-React radio inputs with the same `name` is not supported.') : _prodInvariant('90') : void 0; + // If this is a controlled radio button group, forcing the input that + // was previously checked to update will cause it to be come re-checked + // as appropriate. + ReactUpdates.asap(forceUpdateIfMounted, otherInstance); + } + } + + return returnValue; +} + +module.exports = ReactDOMInput; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 267 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var React = __webpack_require__(36); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMSelect = __webpack_require__(140); + +var warning = __webpack_require__(3); +var didWarnInvalidOptionChildren = false; + +function flattenChildren(children) { + var content = ''; + + // Flatten children and warn if they aren't strings or numbers; + // invalid types are ignored. + React.Children.forEach(children, function (child) { + if (child == null) { + return; + } + if (typeof child === 'string' || typeof child === 'number') { + content += child; + } else if (!didWarnInvalidOptionChildren) { + didWarnInvalidOptionChildren = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Only strings and numbers are supported as <option> children.') : void 0; + } + }); + + return content; +} + +/** + * Implements an <option> host component that warns when `selected` is set. + */ +var ReactDOMOption = { + mountWrapper: function (inst, props, hostParent) { + // TODO (yungsters): Remove support for `selected` in <option>. + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(props.selected == null, 'Use the `defaultValue` or `value` props on <select> instead of ' + 'setting `selected` on <option>.') : void 0; + } + + // Look up whether this option is 'selected' + var selectValue = null; + if (hostParent != null) { + var selectParent = hostParent; + + if (selectParent._tag === 'optgroup') { + selectParent = selectParent._hostParent; + } + + if (selectParent != null && selectParent._tag === 'select') { + selectValue = ReactDOMSelect.getSelectValueContext(selectParent); + } + } + + // If the value is null (e.g., no specified value or after initial mount) + // or missing (e.g., for <datalist>), we don't change props.selected + var selected = null; + if (selectValue != null) { + var value; + if (props.value != null) { + value = props.value + ''; + } else { + value = flattenChildren(props.children); + } + selected = false; + if (Array.isArray(selectValue)) { + // multiple + for (var i = 0; i < selectValue.length; i++) { + if ('' + selectValue[i] === value) { + selected = true; + break; + } + } + } else { + selected = '' + selectValue === value; + } + } + + inst._wrapperState = { selected: selected }; + }, + + postMountWrapper: function (inst) { + // value="" should make a value attribute (#6219) + var props = inst._currentElement.props; + if (props.value != null) { + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + node.setAttribute('value', props.value); + } + }, + + getHostProps: function (inst, props) { + var hostProps = _assign({ selected: undefined, children: undefined }, props); + + // Read state only from initial mount because <select> updates value + // manually; we need the initial state only for server rendering + if (inst._wrapperState.selected != null) { + hostProps.selected = inst._wrapperState.selected; + } + + var content = flattenChildren(props.children); + + if (content) { + hostProps.children = content; + } + + return hostProps; + } +}; + +module.exports = ReactDOMOption; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 268 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var didWarnValueLink = false; +var didWarnValDefaultVal = false; + +function forceUpdateIfMounted() { + if (this._rootNodeID) { + // DOM component is still mounted; update + ReactDOMTextarea.updateWrapper(this); + } +} + +/** + * Implements a <textarea> host component that allows setting `value`, and + * `defaultValue`. This differs from the traditional DOM API because value is + * usually set as PCDATA children. + * + * If `value` is not supplied (or null/undefined), user actions that affect the + * value will trigger updates to the element. + * + * If `value` is supplied (and not null/undefined), the rendered element will + * not trigger updates to the element. Instead, the `value` prop must change in + * order for the rendered element to be updated. + * + * The rendered element will be initialized with an empty value, the prop + * `defaultValue` if specified, or the children content (deprecated). + */ +var ReactDOMTextarea = { + getHostProps: function (inst, props) { + !(props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`dangerouslySetInnerHTML` does not make sense on <textarea>.') : _prodInvariant('91') : void 0; + + // Always set children to the same thing. In IE9, the selection range will + // get reset if `textContent` is mutated. We could add a check in setTextContent + // to only set the value if/when the value differs from the node value (which would + // completely solve this IE9 bug), but Sebastian+Ben seemed to like this solution. + // The value can be a boolean or object so that's why it's forced to be a string. + var hostProps = _assign({}, props, { + value: undefined, + defaultValue: undefined, + children: '' + inst._wrapperState.initialValue, + onChange: inst._wrapperState.onChange + }); + + return hostProps; + }, + + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + LinkedValueUtils.checkPropTypes('textarea', props, inst._currentElement._owner); + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `textarea` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValDefaultVal) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Textarea elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; + didWarnValDefaultVal = true; + } + } + + var value = LinkedValueUtils.getValue(props); + var initialValue = value; + + // Only bother fetching default value if we're going to use it + if (value == null) { + var defaultValue = props.defaultValue; + // TODO (yungsters): Remove support for children content in <textarea>. + var children = props.children; + if (children != null) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(false, 'Use the `defaultValue` or `value` props instead of setting ' + 'children on <textarea>.') : void 0; + } + !(defaultValue == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'If you supply `defaultValue` on a <textarea>, do not pass children.') : _prodInvariant('92') : void 0; + if (Array.isArray(children)) { + !(children.length <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, '<textarea> can only have at most one child.') : _prodInvariant('93') : void 0; + children = children[0]; + } + + defaultValue = '' + children; + } + if (defaultValue == null) { + defaultValue = ''; + } + initialValue = defaultValue; + } + + inst._wrapperState = { + initialValue: '' + initialValue, + listeners: null, + onChange: _handleChange.bind(inst) + }; + }, + + updateWrapper: function (inst) { + var props = inst._currentElement.props; + + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var value = LinkedValueUtils.getValue(props); + if (value != null) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + var newValue = '' + value; + + // To avoid side effects (such as losing text selection), only set value if changed + if (newValue !== node.value) { + node.value = newValue; + } + if (props.defaultValue == null) { + node.defaultValue = newValue; + } + } + if (props.defaultValue != null) { + node.defaultValue = props.defaultValue; + } + }, + + postMountWrapper: function (inst) { + // This is in postMount because we need access to the DOM node, which is not + // available until after the component has mounted. + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var textContent = node.textContent; + + // Only set node.value if textContent is equal to the expected + // initial value. In IE10/IE11 there is a bug where the placeholder attribute + // will populate textContent as well. + // https://developer.microsoft.com/microsoft-edge/platform/issues/101525/ + if (textContent === inst._wrapperState.initialValue) { + node.value = textContent; + } + } +}; + +function _handleChange(event) { + var props = this._currentElement.props; + var returnValue = LinkedValueUtils.executeOnChange(props, event); + ReactUpdates.asap(forceUpdateIfMounted, this); + return returnValue; +} + +module.exports = ReactDOMTextarea; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 269 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactComponentEnvironment = __webpack_require__(86); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); + +var ReactCurrentOwner = __webpack_require__(22); +var ReactReconciler = __webpack_require__(38); +var ReactChildReconciler = __webpack_require__(270); + +var emptyFunction = __webpack_require__(18); +var flattenChildren = __webpack_require__(277); +var invariant = __webpack_require__(2); + +/** + * Make an update for markup to be rendered and inserted at a supplied index. + * + * @param {string} markup Markup that renders into an element. + * @param {number} toIndex Destination index. + * @private + */ +function makeInsertMarkup(markup, afterNode, toIndex) { + // NOTE: Null values reduce hidden classes. + return { + type: 'INSERT_MARKUP', + content: markup, + fromIndex: null, + fromNode: null, + toIndex: toIndex, + afterNode: afterNode + }; +} + +/** + * Make an update for moving an existing element to another index. + * + * @param {number} fromIndex Source index of the existing element. + * @param {number} toIndex Destination index of the element. + * @private + */ +function makeMove(child, afterNode, toIndex) { + // NOTE: Null values reduce hidden classes. + return { + type: 'MOVE_EXISTING', + content: null, + fromIndex: child._mountIndex, + fromNode: ReactReconciler.getHostNode(child), + toIndex: toIndex, + afterNode: afterNode + }; +} + +/** + * Make an update for removing an element at an index. + * + * @param {number} fromIndex Index of the element to remove. + * @private + */ +function makeRemove(child, node) { + // NOTE: Null values reduce hidden classes. + return { + type: 'REMOVE_NODE', + content: null, + fromIndex: child._mountIndex, + fromNode: node, + toIndex: null, + afterNode: null + }; +} + +/** + * Make an update for setting the markup of a node. + * + * @param {string} markup Markup that renders into an element. + * @private + */ +function makeSetMarkup(markup) { + // NOTE: Null values reduce hidden classes. + return { + type: 'SET_MARKUP', + content: markup, + fromIndex: null, + fromNode: null, + toIndex: null, + afterNode: null + }; +} + +/** + * Make an update for setting the text content. + * + * @param {string} textContent Text content to set. + * @private + */ +function makeTextContent(textContent) { + // NOTE: Null values reduce hidden classes. + return { + type: 'TEXT_CONTENT', + content: textContent, + fromIndex: null, + fromNode: null, + toIndex: null, + afterNode: null + }; +} + +/** + * Push an update, if any, onto the queue. Creates a new queue if none is + * passed and always returns the queue. Mutative. + */ +function enqueue(queue, update) { + if (update) { + queue = queue || []; + queue.push(update); + } + return queue; +} + +/** + * Processes any enqueued updates. + * + * @private + */ +function processQueue(inst, updateQueue) { + ReactComponentEnvironment.processChildrenUpdates(inst, updateQueue); +} + +var setChildrenForInstrumentation = emptyFunction; +if (process.env.NODE_ENV !== 'production') { + var getDebugID = function (inst) { + if (!inst._debugID) { + // Check for ART-like instances. TODO: This is silly/gross. + var internal; + if (internal = ReactInstanceMap.get(inst)) { + inst = internal; + } + } + return inst._debugID; + }; + setChildrenForInstrumentation = function (children) { + var debugID = getDebugID(this); + // TODO: React Native empty components are also multichild. + // This means they still get into this method but don't have _debugID. + if (debugID !== 0) { + ReactInstrumentation.debugTool.onSetChildren(debugID, children ? Object.keys(children).map(function (key) { + return children[key]._debugID; + }) : []); + } + }; +} + +/** + * ReactMultiChild are capable of reconciling multiple children. + * + * @class ReactMultiChild + * @internal + */ +var ReactMultiChild = { + /** + * Provides common functionality for components that must reconcile multiple + * children. This is used by `ReactDOMComponent` to mount, update, and + * unmount child components. + * + * @lends {ReactMultiChild.prototype} + */ + Mixin: { + _reconcilerInstantiateChildren: function (nestedChildren, transaction, context) { + if (process.env.NODE_ENV !== 'production') { + var selfDebugID = getDebugID(this); + if (this._currentElement) { + try { + ReactCurrentOwner.current = this._currentElement._owner; + return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context, selfDebugID); + } finally { + ReactCurrentOwner.current = null; + } + } + } + return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context); + }, + + _reconcilerUpdateChildren: function (prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context) { + var nextChildren; + var selfDebugID = 0; + if (process.env.NODE_ENV !== 'production') { + selfDebugID = getDebugID(this); + if (this._currentElement) { + try { + ReactCurrentOwner.current = this._currentElement._owner; + nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); + } finally { + ReactCurrentOwner.current = null; + } + ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); + return nextChildren; + } + } + nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); + ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); + return nextChildren; + }, + + /** + * Generates a "mount image" for each of the supplied children. In the case + * of `ReactDOMComponent`, a mount image is a string of markup. + * + * @param {?object} nestedChildren Nested child maps. + * @return {array} An array of mounted representations. + * @internal + */ + mountChildren: function (nestedChildren, transaction, context) { + var children = this._reconcilerInstantiateChildren(nestedChildren, transaction, context); + this._renderedChildren = children; + + var mountImages = []; + var index = 0; + for (var name in children) { + if (children.hasOwnProperty(name)) { + var child = children[name]; + var selfDebugID = 0; + if (process.env.NODE_ENV !== 'production') { + selfDebugID = getDebugID(this); + } + var mountImage = ReactReconciler.mountComponent(child, transaction, this, this._hostContainerInfo, context, selfDebugID); + child._mountIndex = index++; + mountImages.push(mountImage); + } + } + + if (process.env.NODE_ENV !== 'production') { + setChildrenForInstrumentation.call(this, children); + } + + return mountImages; + }, + + /** + * Replaces any rendered children with a text content string. + * + * @param {string} nextContent String of content. + * @internal + */ + updateTextContent: function (nextContent) { + var prevChildren = this._renderedChildren; + // Remove any rendered children. + ReactChildReconciler.unmountChildren(prevChildren, false); + for (var name in prevChildren) { + if (prevChildren.hasOwnProperty(name)) { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; + } + } + // Set new text content. + var updates = [makeTextContent(nextContent)]; + processQueue(this, updates); + }, + + /** + * Replaces any rendered children with a markup string. + * + * @param {string} nextMarkup String of markup. + * @internal + */ + updateMarkup: function (nextMarkup) { + var prevChildren = this._renderedChildren; + // Remove any rendered children. + ReactChildReconciler.unmountChildren(prevChildren, false); + for (var name in prevChildren) { + if (prevChildren.hasOwnProperty(name)) { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; + } + } + var updates = [makeSetMarkup(nextMarkup)]; + processQueue(this, updates); + }, + + /** + * Updates the rendered children with new children. + * + * @param {?object} nextNestedChildrenElements Nested child element maps. + * @param {ReactReconcileTransaction} transaction + * @internal + */ + updateChildren: function (nextNestedChildrenElements, transaction, context) { + // Hook used by React ART + this._updateChildren(nextNestedChildrenElements, transaction, context); + }, + + /** + * @param {?object} nextNestedChildrenElements Nested child element maps. + * @param {ReactReconcileTransaction} transaction + * @final + * @protected + */ + _updateChildren: function (nextNestedChildrenElements, transaction, context) { + var prevChildren = this._renderedChildren; + var removedNodes = {}; + var mountImages = []; + var nextChildren = this._reconcilerUpdateChildren(prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context); + if (!nextChildren && !prevChildren) { + return; + } + var updates = null; + var name; + // `nextIndex` will increment for each child in `nextChildren`, but + // `lastIndex` will be the last index visited in `prevChildren`. + var nextIndex = 0; + var lastIndex = 0; + // `nextMountIndex` will increment for each newly mounted child. + var nextMountIndex = 0; + var lastPlacedNode = null; + for (name in nextChildren) { + if (!nextChildren.hasOwnProperty(name)) { + continue; + } + var prevChild = prevChildren && prevChildren[name]; + var nextChild = nextChildren[name]; + if (prevChild === nextChild) { + updates = enqueue(updates, this.moveChild(prevChild, lastPlacedNode, nextIndex, lastIndex)); + lastIndex = Math.max(prevChild._mountIndex, lastIndex); + prevChild._mountIndex = nextIndex; + } else { + if (prevChild) { + // Update `lastIndex` before `_mountIndex` gets unset by unmounting. + lastIndex = Math.max(prevChild._mountIndex, lastIndex); + // The `removedNodes` loop below will actually remove the child. + } + // The child must be instantiated before it's mounted. + updates = enqueue(updates, this._mountChildAtIndex(nextChild, mountImages[nextMountIndex], lastPlacedNode, nextIndex, transaction, context)); + nextMountIndex++; + } + nextIndex++; + lastPlacedNode = ReactReconciler.getHostNode(nextChild); + } + // Remove children that are no longer present. + for (name in removedNodes) { + if (removedNodes.hasOwnProperty(name)) { + updates = enqueue(updates, this._unmountChild(prevChildren[name], removedNodes[name])); + } + } + if (updates) { + processQueue(this, updates); + } + this._renderedChildren = nextChildren; + + if (process.env.NODE_ENV !== 'production') { + setChildrenForInstrumentation.call(this, nextChildren); + } + }, + + /** + * Unmounts all rendered children. This should be used to clean up children + * when this component is unmounted. It does not actually perform any + * backend operations. + * + * @internal + */ + unmountChildren: function (safely) { + var renderedChildren = this._renderedChildren; + ReactChildReconciler.unmountChildren(renderedChildren, safely); + this._renderedChildren = null; + }, + + /** + * Moves a child component to the supplied index. + * + * @param {ReactComponent} child Component to move. + * @param {number} toIndex Destination index of the element. + * @param {number} lastIndex Last index visited of the siblings of `child`. + * @protected + */ + moveChild: function (child, afterNode, toIndex, lastIndex) { + // If the index of `child` is less than `lastIndex`, then it needs to + // be moved. Otherwise, we do not need to move it because a child will be + // inserted or moved before `child`. + if (child._mountIndex < lastIndex) { + return makeMove(child, afterNode, toIndex); + } + }, + + /** + * Creates a child component. + * + * @param {ReactComponent} child Component to create. + * @param {string} mountImage Markup to insert. + * @protected + */ + createChild: function (child, afterNode, mountImage) { + return makeInsertMarkup(mountImage, afterNode, child._mountIndex); + }, + + /** + * Removes a child component. + * + * @param {ReactComponent} child Child to remove. + * @protected + */ + removeChild: function (child, node) { + return makeRemove(child, node); + }, + + /** + * Mounts a child with the supplied name. + * + * NOTE: This is part of `updateChildren` and is here for readability. + * + * @param {ReactComponent} child Component to mount. + * @param {string} name Name of the child. + * @param {number} index Index at which to insert the child. + * @param {ReactReconcileTransaction} transaction + * @private + */ + _mountChildAtIndex: function (child, mountImage, afterNode, index, transaction, context) { + child._mountIndex = index; + return this.createChild(child, afterNode, mountImage); + }, + + /** + * Unmounts a rendered child. + * + * NOTE: This is part of `updateChildren` and is here for readability. + * + * @param {ReactComponent} child Component to unmount. + * @private + */ + _unmountChild: function (child, node) { + var update = this.removeChild(child, node); + child._mountIndex = null; + return update; + } + } +}; + +module.exports = ReactMultiChild; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 270 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactReconciler = __webpack_require__(38); + +var instantiateReactComponent = __webpack_require__(141); +var KeyEscapeUtils = __webpack_require__(89); +var shouldUpdateReactComponent = __webpack_require__(88); +var traverseAllChildren = __webpack_require__(145); +var warning = __webpack_require__(3); + +var ReactComponentTreeHook; + +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} + +function instantiateChild(childInstances, child, name, selfDebugID) { + // We found a component instance. + var keyUnique = childInstances[name] === undefined; + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (!keyUnique) { + process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; + } + } + if (child != null && keyUnique) { + childInstances[name] = instantiateReactComponent(child, true); + } +} + +/** + * ReactChildReconciler provides helpers for initializing or updating a set of + * children. Its output is suitable for passing it onto ReactMultiChild which + * does diffed reordering and insertion. + */ +var ReactChildReconciler = { + /** + * Generates a "mount image" for each of the supplied children. In the case + * of `ReactDOMComponent`, a mount image is a string of markup. + * + * @param {?object} nestedChildNodes Nested child maps. + * @return {?object} A set of child instances. + * @internal + */ + instantiateChildren: function (nestedChildNodes, transaction, context, selfDebugID) // 0 in production and for roots + { + if (nestedChildNodes == null) { + return null; + } + var childInstances = {}; + + if (process.env.NODE_ENV !== 'production') { + traverseAllChildren(nestedChildNodes, function (childInsts, child, name) { + return instantiateChild(childInsts, child, name, selfDebugID); + }, childInstances); + } else { + traverseAllChildren(nestedChildNodes, instantiateChild, childInstances); + } + return childInstances; + }, + + /** + * Updates the rendered children and returns a new set of children. + * + * @param {?object} prevChildren Previously initialized set of children. + * @param {?object} nextChildren Flat child element maps. + * @param {ReactReconcileTransaction} transaction + * @param {object} context + * @return {?object} A new set of child instances. + * @internal + */ + updateChildren: function (prevChildren, nextChildren, mountImages, removedNodes, transaction, hostParent, hostContainerInfo, context, selfDebugID) // 0 in production and for roots + { + // We currently don't have a way to track moves here but if we use iterators + // instead of for..in we can zip the iterators and check if an item has + // moved. + // TODO: If nothing has changed, return the prevChildren object so that we + // can quickly bailout if nothing has changed. + if (!nextChildren && !prevChildren) { + return; + } + var name; + var prevChild; + for (name in nextChildren) { + if (!nextChildren.hasOwnProperty(name)) { + continue; + } + prevChild = prevChildren && prevChildren[name]; + var prevElement = prevChild && prevChild._currentElement; + var nextElement = nextChildren[name]; + if (prevChild != null && shouldUpdateReactComponent(prevElement, nextElement)) { + ReactReconciler.receiveComponent(prevChild, nextElement, transaction, context); + nextChildren[name] = prevChild; + } else { + if (prevChild) { + removedNodes[name] = ReactReconciler.getHostNode(prevChild); + ReactReconciler.unmountComponent(prevChild, false); + } + // The child must be instantiated before it's mounted. + var nextChildInstance = instantiateReactComponent(nextElement, true); + nextChildren[name] = nextChildInstance; + // Creating mount image now ensures refs are resolved in right order + // (see https://github.com/facebook/react/pull/7101 for explanation). + var nextChildMountImage = ReactReconciler.mountComponent(nextChildInstance, transaction, hostParent, hostContainerInfo, context, selfDebugID); + mountImages.push(nextChildMountImage); + } + } + // Unmount children that are no longer present. + for (name in prevChildren) { + if (prevChildren.hasOwnProperty(name) && !(nextChildren && nextChildren.hasOwnProperty(name))) { + prevChild = prevChildren[name]; + removedNodes[name] = ReactReconciler.getHostNode(prevChild); + ReactReconciler.unmountComponent(prevChild, false); + } + } + }, + + /** + * Unmounts all rendered children. This should be used to clean up children + * when this component is unmounted. + * + * @param {?object} renderedChildren Previously initialized set of children. + * @internal + */ + unmountChildren: function (renderedChildren, safely) { + for (var name in renderedChildren) { + if (renderedChildren.hasOwnProperty(name)) { + var renderedChild = renderedChildren[name]; + ReactReconciler.unmountComponent(renderedChild, safely); + } + } + } +}; + +module.exports = ReactChildReconciler; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 271 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var React = __webpack_require__(36); +var ReactComponentEnvironment = __webpack_require__(86); +var ReactCurrentOwner = __webpack_require__(22); +var ReactErrorUtils = __webpack_require__(78); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactNodeTypes = __webpack_require__(142); +var ReactReconciler = __webpack_require__(38); + +if (process.env.NODE_ENV !== 'production') { + var checkReactTypeSpec = __webpack_require__(272); +} + +var emptyObject = __webpack_require__(56); +var invariant = __webpack_require__(2); +var shallowEqual = __webpack_require__(87); +var shouldUpdateReactComponent = __webpack_require__(88); +var warning = __webpack_require__(3); + +var CompositeTypes = { + ImpureClass: 0, + PureClass: 1, + StatelessFunctional: 2 +}; + +function StatelessComponent(Component) {} +StatelessComponent.prototype.render = function () { + var Component = ReactInstanceMap.get(this)._currentElement.type; + var element = Component(this.props, this.context, this.updater); + warnIfInvalidElement(Component, element); + return element; +}; + +function warnIfInvalidElement(Component, element) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(element === null || element === false || React.isValidElement(element), '%s(...): A valid React element (or null) must be returned. You may have ' + 'returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!Component.childContextTypes, '%s(...): childContextTypes cannot be defined on a functional component.', Component.displayName || Component.name || 'Component') : void 0; + } +} + +function shouldConstruct(Component) { + return !!(Component.prototype && Component.prototype.isReactComponent); +} + +function isPureComponent(Component) { + return !!(Component.prototype && Component.prototype.isPureReactComponent); +} + +// Separated into a function to contain deoptimizations caused by try/finally. +function measureLifeCyclePerf(fn, debugID, timerType) { + if (debugID === 0) { + // Top-level wrappers (see ReactMount) and empty components (see + // ReactDOMEmptyComponent) are invisible to hooks and devtools. + // Both are implementation details that should go away in the future. + return fn(); + } + + ReactInstrumentation.debugTool.onBeginLifeCycleTimer(debugID, timerType); + try { + return fn(); + } finally { + ReactInstrumentation.debugTool.onEndLifeCycleTimer(debugID, timerType); + } +} + +/** + * ------------------ The Life-Cycle of a Composite Component ------------------ + * + * - constructor: Initialization of state. The instance is now retained. + * - componentWillMount + * - render + * - [children's constructors] + * - [children's componentWillMount and render] + * - [children's componentDidMount] + * - componentDidMount + * + * Update Phases: + * - componentWillReceiveProps (only called if parent updated) + * - shouldComponentUpdate + * - componentWillUpdate + * - render + * - [children's constructors or receive props phases] + * - componentDidUpdate + * + * - componentWillUnmount + * - [children's componentWillUnmount] + * - [children destroyed] + * - (destroyed): The instance is now blank, released by React and ready for GC. + * + * ----------------------------------------------------------------------------- + */ + +/** + * An incrementing ID assigned to each component when it is mounted. This is + * used to enforce the order in which `ReactUpdates` updates dirty components. + * + * @private + */ +var nextMountID = 1; + +/** + * @lends {ReactCompositeComponent.prototype} + */ +var ReactCompositeComponent = { + /** + * Base constructor for all composite component. + * + * @param {ReactElement} element + * @final + * @internal + */ + construct: function (element) { + this._currentElement = element; + this._rootNodeID = 0; + this._compositeType = null; + this._instance = null; + this._hostParent = null; + this._hostContainerInfo = null; + + // See ReactUpdateQueue + this._updateBatchNumber = null; + this._pendingElement = null; + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; + + this._renderedNodeType = null; + this._renderedComponent = null; + this._context = null; + this._mountOrder = 0; + this._topLevelWrapper = null; + + // See ReactUpdates and ReactUpdateQueue. + this._pendingCallbacks = null; + + // ComponentWillUnmount shall only be called once + this._calledComponentWillUnmount = false; + + if (process.env.NODE_ENV !== 'production') { + this._warnedAboutRefsInRender = false; + } + }, + + /** + * Initializes the component, renders markup, and registers event listeners. + * + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?object} hostParent + * @param {?object} hostContainerInfo + * @param {?object} context + * @return {?string} Rendered markup to be inserted into the DOM. + * @final + * @internal + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + var _this = this; + + this._context = context; + this._mountOrder = nextMountID++; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; + + var publicProps = this._currentElement.props; + var publicContext = this._processContext(context); + + var Component = this._currentElement.type; + + var updateQueue = transaction.getUpdateQueue(); + + // Initialize the public class + var doConstruct = shouldConstruct(Component); + var inst = this._constructComponent(doConstruct, publicProps, publicContext, updateQueue); + var renderedElement; + + // Support functional components + if (!doConstruct && (inst == null || inst.render == null)) { + renderedElement = inst; + warnIfInvalidElement(Component, renderedElement); + !(inst === null || inst === false || React.isValidElement(inst)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : _prodInvariant('105', Component.displayName || Component.name || 'Component') : void 0; + inst = new StatelessComponent(Component); + this._compositeType = CompositeTypes.StatelessFunctional; + } else { + if (isPureComponent(Component)) { + this._compositeType = CompositeTypes.PureClass; + } else { + this._compositeType = CompositeTypes.ImpureClass; + } + } + + if (process.env.NODE_ENV !== 'production') { + // This will throw later in _renderValidatedComponent, but add an early + // warning now to help debugging + if (inst.render == null) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): No `render` method found on the returned component ' + 'instance: you may have forgotten to define `render`.', Component.displayName || Component.name || 'Component') : void 0; + } + + var propsMutated = inst.props !== publicProps; + var componentName = Component.displayName || Component.name || 'Component'; + + process.env.NODE_ENV !== 'production' ? warning(inst.props === undefined || !propsMutated, '%s(...): When calling super() in `%s`, make sure to pass ' + "up the same props that your component's constructor was passed.", componentName, componentName) : void 0; + } + + // These should be set up in the constructor, but as a convenience for + // simpler class abstractions, we set them up after the fact. + inst.props = publicProps; + inst.context = publicContext; + inst.refs = emptyObject; + inst.updater = updateQueue; + + this._instance = inst; + + // Store a reference from the instance back to the internal representation + ReactInstanceMap.set(inst, this); + + if (process.env.NODE_ENV !== 'production') { + // Since plain JS classes are defined without any special initialization + // logic, we can not catch common errors early. Therefore, we have to + // catch them here, at initialization time, instead. + process.env.NODE_ENV !== 'production' ? warning(!inst.getInitialState || inst.getInitialState.isReactClassApproved || inst.state, 'getInitialState was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Did you mean to define a state property instead?', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.getDefaultProps || inst.getDefaultProps.isReactClassApproved, 'getDefaultProps was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Use a static property to define defaultProps instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.propTypes, 'propTypes was defined as an instance property on %s. Use a static ' + 'property to define propTypes instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.contextTypes, 'contextTypes was defined as an instance property on %s. Use a ' + 'static property to define contextTypes instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentShouldUpdate !== 'function', '%s has a method called ' + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + 'The name is phrased as a question because the function is ' + 'expected to return a value.', this.getName() || 'A component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentDidUnmount !== 'function', '%s has a method called ' + 'componentDidUnmount(). But there is no such lifecycle method. ' + 'Did you mean componentWillUnmount()?', this.getName() || 'A component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentWillRecieveProps !== 'function', '%s has a method called ' + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', this.getName() || 'A component') : void 0; + } + + var initialState = inst.state; + if (initialState === undefined) { + inst.state = initialState = null; + } + !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.state: must be set to an object or null', this.getName() || 'ReactCompositeComponent') : _prodInvariant('106', this.getName() || 'ReactCompositeComponent') : void 0; + + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; + + var markup; + if (inst.unstable_handleError) { + markup = this.performInitialMountWithErrorHandling(renderedElement, hostParent, hostContainerInfo, transaction, context); + } else { + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); + } + + if (inst.componentDidMount) { + if (process.env.NODE_ENV !== 'production') { + transaction.getReactMountReady().enqueue(function () { + measureLifeCyclePerf(function () { + return inst.componentDidMount(); + }, _this._debugID, 'componentDidMount'); + }); + } else { + transaction.getReactMountReady().enqueue(inst.componentDidMount, inst); + } + } + + return markup; + }, + + _constructComponent: function (doConstruct, publicProps, publicContext, updateQueue) { + if (process.env.NODE_ENV !== 'production') { + ReactCurrentOwner.current = this; + try { + return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); + } finally { + ReactCurrentOwner.current = null; + } + } else { + return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); + } + }, + + _constructComponentWithoutOwner: function (doConstruct, publicProps, publicContext, updateQueue) { + var Component = this._currentElement.type; + + if (doConstruct) { + if (process.env.NODE_ENV !== 'production') { + return measureLifeCyclePerf(function () { + return new Component(publicProps, publicContext, updateQueue); + }, this._debugID, 'ctor'); + } else { + return new Component(publicProps, publicContext, updateQueue); + } + } + + // This can still be an instance in case of factory components + // but we'll count this as time spent rendering as the more common case. + if (process.env.NODE_ENV !== 'production') { + return measureLifeCyclePerf(function () { + return Component(publicProps, publicContext, updateQueue); + }, this._debugID, 'render'); + } else { + return Component(publicProps, publicContext, updateQueue); + } + }, + + performInitialMountWithErrorHandling: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { + var markup; + var checkpoint = transaction.checkpoint(); + try { + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); + } catch (e) { + // Roll back to checkpoint, handle error (which may add items to the transaction), and take a new checkpoint + transaction.rollback(checkpoint); + this._instance.unstable_handleError(e); + if (this._pendingStateQueue) { + this._instance.state = this._processPendingState(this._instance.props, this._instance.context); + } + checkpoint = transaction.checkpoint(); + + this._renderedComponent.unmountComponent(true); + transaction.rollback(checkpoint); + + // Try again - we've informed the component about the error, so they can render an error message this time. + // If this throws again, the error will bubble up (and can be caught by a higher error boundary). + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); + } + return markup; + }, + + performInitialMount: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { + var inst = this._instance; + + var debugID = 0; + if (process.env.NODE_ENV !== 'production') { + debugID = this._debugID; + } + + if (inst.componentWillMount) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillMount(); + }, debugID, 'componentWillMount'); + } else { + inst.componentWillMount(); + } + // When mounting, calls to `setState` by `componentWillMount` will set + // `this._pendingStateQueue` without triggering a re-render. + if (this._pendingStateQueue) { + inst.state = this._processPendingState(inst.props, inst.context); + } + } + + // If not a stateless component, we now render + if (renderedElement === undefined) { + renderedElement = this._renderValidatedComponent(); + } + + var nodeType = ReactNodeTypes.getType(renderedElement); + this._renderedNodeType = nodeType; + var child = this._instantiateReactComponent(renderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ + ); + this._renderedComponent = child; + + var markup = ReactReconciler.mountComponent(child, transaction, hostParent, hostContainerInfo, this._processChildContext(context), debugID); + + if (process.env.NODE_ENV !== 'production') { + if (debugID !== 0) { + var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; + ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); + } + } + + return markup; + }, + + getHostNode: function () { + return ReactReconciler.getHostNode(this._renderedComponent); + }, + + /** + * Releases any resources allocated by `mountComponent`. + * + * @final + * @internal + */ + unmountComponent: function (safely) { + if (!this._renderedComponent) { + return; + } + + var inst = this._instance; + + if (inst.componentWillUnmount && !inst._calledComponentWillUnmount) { + inst._calledComponentWillUnmount = true; + + if (safely) { + var name = this.getName() + '.componentWillUnmount()'; + ReactErrorUtils.invokeGuardedCallback(name, inst.componentWillUnmount.bind(inst)); + } else { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillUnmount(); + }, this._debugID, 'componentWillUnmount'); + } else { + inst.componentWillUnmount(); + } + } + } + + if (this._renderedComponent) { + ReactReconciler.unmountComponent(this._renderedComponent, safely); + this._renderedNodeType = null; + this._renderedComponent = null; + this._instance = null; + } + + // Reset pending fields + // Even if this component is scheduled for another update in ReactUpdates, + // it would still be ignored because these fields are reset. + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; + this._pendingCallbacks = null; + this._pendingElement = null; + + // These fields do not really need to be reset since this object is no + // longer accessible. + this._context = null; + this._rootNodeID = 0; + this._topLevelWrapper = null; + + // Delete the reference from the instance to this internal representation + // which allow the internals to be properly cleaned up even if the user + // leaks a reference to the public instance. + ReactInstanceMap.remove(inst); + + // Some existing components rely on inst.props even after they've been + // destroyed (in event handlers). + // TODO: inst.props = null; + // TODO: inst.state = null; + // TODO: inst.context = null; + }, + + /** + * Filters the context object to only contain keys specified in + * `contextTypes` + * + * @param {object} context + * @return {?object} + * @private + */ + _maskContext: function (context) { + var Component = this._currentElement.type; + var contextTypes = Component.contextTypes; + if (!contextTypes) { + return emptyObject; + } + var maskedContext = {}; + for (var contextName in contextTypes) { + maskedContext[contextName] = context[contextName]; + } + return maskedContext; + }, + + /** + * Filters the context object to only contain keys specified in + * `contextTypes`, and asserts that they are valid. + * + * @param {object} context + * @return {?object} + * @private + */ + _processContext: function (context) { + var maskedContext = this._maskContext(context); + if (process.env.NODE_ENV !== 'production') { + var Component = this._currentElement.type; + if (Component.contextTypes) { + this._checkContextTypes(Component.contextTypes, maskedContext, 'context'); + } + } + return maskedContext; + }, + + /** + * @param {object} currentContext + * @return {object} + * @private + */ + _processChildContext: function (currentContext) { + var Component = this._currentElement.type; + var inst = this._instance; + var childContext; + + if (inst.getChildContext) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onBeginProcessingChildContext(); + try { + childContext = inst.getChildContext(); + } finally { + ReactInstrumentation.debugTool.onEndProcessingChildContext(); + } + } else { + childContext = inst.getChildContext(); + } + } + + if (childContext) { + !(typeof Component.childContextTypes === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().', this.getName() || 'ReactCompositeComponent') : _prodInvariant('107', this.getName() || 'ReactCompositeComponent') : void 0; + if (process.env.NODE_ENV !== 'production') { + this._checkContextTypes(Component.childContextTypes, childContext, 'child context'); + } + for (var name in childContext) { + !(name in Component.childContextTypes) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): key "%s" is not defined in childContextTypes.', this.getName() || 'ReactCompositeComponent', name) : _prodInvariant('108', this.getName() || 'ReactCompositeComponent', name) : void 0; + } + return _assign({}, currentContext, childContext); + } + return currentContext; + }, + + /** + * Assert that the context types are valid + * + * @param {object} typeSpecs Map of context field to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @private + */ + _checkContextTypes: function (typeSpecs, values, location) { + if (process.env.NODE_ENV !== 'production') { + checkReactTypeSpec(typeSpecs, values, location, this.getName(), null, this._debugID); + } + }, + + receiveComponent: function (nextElement, transaction, nextContext) { + var prevElement = this._currentElement; + var prevContext = this._context; + + this._pendingElement = null; + + this.updateComponent(transaction, prevElement, nextElement, prevContext, nextContext); + }, + + /** + * If any of `_pendingElement`, `_pendingStateQueue`, or `_pendingForceUpdate` + * is set, update the component. + * + * @param {ReactReconcileTransaction} transaction + * @internal + */ + performUpdateIfNecessary: function (transaction) { + if (this._pendingElement != null) { + ReactReconciler.receiveComponent(this, this._pendingElement, transaction, this._context); + } else if (this._pendingStateQueue !== null || this._pendingForceUpdate) { + this.updateComponent(transaction, this._currentElement, this._currentElement, this._context, this._context); + } else { + this._updateBatchNumber = null; + } + }, + + /** + * Perform an update to a mounted component. The componentWillReceiveProps and + * shouldComponentUpdate methods are called, then (assuming the update isn't + * skipped) the remaining update lifecycle methods are called and the DOM + * representation is updated. + * + * By default, this implements React's rendering and reconciliation algorithm. + * Sophisticated clients may wish to override this. + * + * @param {ReactReconcileTransaction} transaction + * @param {ReactElement} prevParentElement + * @param {ReactElement} nextParentElement + * @internal + * @overridable + */ + updateComponent: function (transaction, prevParentElement, nextParentElement, prevUnmaskedContext, nextUnmaskedContext) { + var inst = this._instance; + !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Attempted to update component `%s` that has already been unmounted (or failed to mount).', this.getName() || 'ReactCompositeComponent') : _prodInvariant('136', this.getName() || 'ReactCompositeComponent') : void 0; + + var willReceive = false; + var nextContext; + + // Determine if the context has changed or not + if (this._context === nextUnmaskedContext) { + nextContext = inst.context; + } else { + nextContext = this._processContext(nextUnmaskedContext); + willReceive = true; + } + + var prevProps = prevParentElement.props; + var nextProps = nextParentElement.props; + + // Not a simple state update but a props update + if (prevParentElement !== nextParentElement) { + willReceive = true; + } + + // An update here will schedule an update but immediately set + // _pendingStateQueue which will ensure that any state updates gets + // immediately reconciled instead of waiting for the next batch. + if (willReceive && inst.componentWillReceiveProps) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillReceiveProps(nextProps, nextContext); + }, this._debugID, 'componentWillReceiveProps'); + } else { + inst.componentWillReceiveProps(nextProps, nextContext); + } + } + + var nextState = this._processPendingState(nextProps, nextContext); + var shouldUpdate = true; + + if (!this._pendingForceUpdate) { + if (inst.shouldComponentUpdate) { + if (process.env.NODE_ENV !== 'production') { + shouldUpdate = measureLifeCyclePerf(function () { + return inst.shouldComponentUpdate(nextProps, nextState, nextContext); + }, this._debugID, 'shouldComponentUpdate'); + } else { + shouldUpdate = inst.shouldComponentUpdate(nextProps, nextState, nextContext); + } + } else { + if (this._compositeType === CompositeTypes.PureClass) { + shouldUpdate = !shallowEqual(prevProps, nextProps) || !shallowEqual(inst.state, nextState); + } + } + } + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(shouldUpdate !== undefined, '%s.shouldComponentUpdate(): Returned undefined instead of a ' + 'boolean value. Make sure to return true or false.', this.getName() || 'ReactCompositeComponent') : void 0; + } + + this._updateBatchNumber = null; + if (shouldUpdate) { + this._pendingForceUpdate = false; + // Will set `this.props`, `this.state` and `this.context`. + this._performComponentUpdate(nextParentElement, nextProps, nextState, nextContext, transaction, nextUnmaskedContext); + } else { + // If it's determined that a component should not update, we still want + // to set props and state but we shortcut the rest of the update. + this._currentElement = nextParentElement; + this._context = nextUnmaskedContext; + inst.props = nextProps; + inst.state = nextState; + inst.context = nextContext; + } + }, + + _processPendingState: function (props, context) { + var inst = this._instance; + var queue = this._pendingStateQueue; + var replace = this._pendingReplaceState; + this._pendingReplaceState = false; + this._pendingStateQueue = null; + + if (!queue) { + return inst.state; + } + + if (replace && queue.length === 1) { + return queue[0]; + } + + var nextState = _assign({}, replace ? queue[0] : inst.state); + for (var i = replace ? 1 : 0; i < queue.length; i++) { + var partial = queue[i]; + _assign(nextState, typeof partial === 'function' ? partial.call(inst, nextState, props, context) : partial); + } + + return nextState; + }, + + /** + * Merges new props and state, notifies delegate methods of update and + * performs update. + * + * @param {ReactElement} nextElement Next element + * @param {object} nextProps Next public object to set as properties. + * @param {?object} nextState Next object to set as state. + * @param {?object} nextContext Next public object to set as context. + * @param {ReactReconcileTransaction} transaction + * @param {?object} unmaskedContext + * @private + */ + _performComponentUpdate: function (nextElement, nextProps, nextState, nextContext, transaction, unmaskedContext) { + var _this2 = this; + + var inst = this._instance; + + var hasComponentDidUpdate = Boolean(inst.componentDidUpdate); + var prevProps; + var prevState; + var prevContext; + if (hasComponentDidUpdate) { + prevProps = inst.props; + prevState = inst.state; + prevContext = inst.context; + } + + if (inst.componentWillUpdate) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillUpdate(nextProps, nextState, nextContext); + }, this._debugID, 'componentWillUpdate'); + } else { + inst.componentWillUpdate(nextProps, nextState, nextContext); + } + } + + this._currentElement = nextElement; + this._context = unmaskedContext; + inst.props = nextProps; + inst.state = nextState; + inst.context = nextContext; + + this._updateRenderedComponent(transaction, unmaskedContext); + + if (hasComponentDidUpdate) { + if (process.env.NODE_ENV !== 'production') { + transaction.getReactMountReady().enqueue(function () { + measureLifeCyclePerf(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), _this2._debugID, 'componentDidUpdate'); + }); + } else { + transaction.getReactMountReady().enqueue(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), inst); + } + } + }, + + /** + * Call the component's `render` method and update the DOM accordingly. + * + * @param {ReactReconcileTransaction} transaction + * @internal + */ + _updateRenderedComponent: function (transaction, context) { + var prevComponentInstance = this._renderedComponent; + var prevRenderedElement = prevComponentInstance._currentElement; + var nextRenderedElement = this._renderValidatedComponent(); + + var debugID = 0; + if (process.env.NODE_ENV !== 'production') { + debugID = this._debugID; + } + + if (shouldUpdateReactComponent(prevRenderedElement, nextRenderedElement)) { + ReactReconciler.receiveComponent(prevComponentInstance, nextRenderedElement, transaction, this._processChildContext(context)); + } else { + var oldHostNode = ReactReconciler.getHostNode(prevComponentInstance); + ReactReconciler.unmountComponent(prevComponentInstance, false); + + var nodeType = ReactNodeTypes.getType(nextRenderedElement); + this._renderedNodeType = nodeType; + var child = this._instantiateReactComponent(nextRenderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ + ); + this._renderedComponent = child; + + var nextMarkup = ReactReconciler.mountComponent(child, transaction, this._hostParent, this._hostContainerInfo, this._processChildContext(context), debugID); + + if (process.env.NODE_ENV !== 'production') { + if (debugID !== 0) { + var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; + ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); + } + } + + this._replaceNodeWithMarkup(oldHostNode, nextMarkup, prevComponentInstance); + } + }, + + /** + * Overridden in shallow rendering. + * + * @protected + */ + _replaceNodeWithMarkup: function (oldHostNode, nextMarkup, prevInstance) { + ReactComponentEnvironment.replaceNodeWithMarkup(oldHostNode, nextMarkup, prevInstance); + }, + + /** + * @protected + */ + _renderValidatedComponentWithoutOwnerOrContext: function () { + var inst = this._instance; + var renderedElement; + + if (process.env.NODE_ENV !== 'production') { + renderedElement = measureLifeCyclePerf(function () { + return inst.render(); + }, this._debugID, 'render'); + } else { + renderedElement = inst.render(); + } + + if (process.env.NODE_ENV !== 'production') { + // We allow auto-mocks to proceed as if they're returning null. + if (renderedElement === undefined && inst.render._isMockFunction) { + // This is probably bad practice. Consider warning here and + // deprecating this convenience. + renderedElement = null; + } + } + + return renderedElement; + }, + + /** + * @private + */ + _renderValidatedComponent: function () { + var renderedElement; + if (process.env.NODE_ENV !== 'production' || this._compositeType !== CompositeTypes.StatelessFunctional) { + ReactCurrentOwner.current = this; + try { + renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); + } finally { + ReactCurrentOwner.current = null; + } + } else { + renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); + } + !( + // TODO: An `isValidNode` function would probably be more appropriate + renderedElement === null || renderedElement === false || React.isValidElement(renderedElement)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.render(): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', this.getName() || 'ReactCompositeComponent') : _prodInvariant('109', this.getName() || 'ReactCompositeComponent') : void 0; + + return renderedElement; + }, + + /** + * Lazily allocates the refs object and stores `component` as `ref`. + * + * @param {string} ref Reference name. + * @param {component} component Component to store as `ref`. + * @final + * @private + */ + attachRef: function (ref, component) { + var inst = this.getPublicInstance(); + !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Stateless function components cannot have refs.') : _prodInvariant('110') : void 0; + var publicComponentInstance = component.getPublicInstance(); + if (process.env.NODE_ENV !== 'production') { + var componentName = component && component.getName ? component.getName() : 'a component'; + process.env.NODE_ENV !== 'production' ? warning(publicComponentInstance != null || component._compositeType !== CompositeTypes.StatelessFunctional, 'Stateless function components cannot be given refs ' + '(See ref "%s" in %s created by %s). ' + 'Attempts to access this ref will fail.', ref, componentName, this.getName()) : void 0; + } + var refs = inst.refs === emptyObject ? inst.refs = {} : inst.refs; + refs[ref] = publicComponentInstance; + }, + + /** + * Detaches a reference name. + * + * @param {string} ref Name to dereference. + * @final + * @private + */ + detachRef: function (ref) { + var refs = this.getPublicInstance().refs; + delete refs[ref]; + }, + + /** + * Get a text description of the component that can be used to identify it + * in error messages. + * @return {string} The name or null. + * @internal + */ + getName: function () { + var type = this._currentElement.type; + var constructor = this._instance && this._instance.constructor; + return type.displayName || constructor && constructor.displayName || type.name || constructor && constructor.name || null; + }, + + /** + * Get the publicly accessible representation of this component - i.e. what + * is exposed by refs and returned by render. Can be null for stateless + * components. + * + * @return {ReactComponent} the public component instance. + * @internal + */ + getPublicInstance: function () { + var inst = this._instance; + if (this._compositeType === CompositeTypes.StatelessFunctional) { + return null; + } + return inst; + }, + + // Stub + _instantiateReactComponent: null +}; + +module.exports = ReactCompositeComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 272 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactPropTypeLocationNames = __webpack_require__(273); +var ReactPropTypesSecret = __webpack_require__(139); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var ReactComponentTreeHook; + +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} + +var loggedTypeFailures = {}; + +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?object} element The React element that is being type-checked + * @param {?number} debugID The React component instance that is being type-checked + * @private + */ +function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var componentStackInfo = ''; + + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (debugID !== null) { + componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); + } else if (element !== null) { + componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); + } + } + + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; + } + } + } +} + +module.exports = checkReactTypeSpec; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 273 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactPropTypeLocationNames = {}; + +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} + +module.exports = ReactPropTypeLocationNames; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 274 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var nextDebugID = 1; + +function getNextDebugID() { + return nextDebugID++; +} + +module.exports = getNextDebugID; + +/***/ }), +/* 275 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +// The Symbol used to tag the ReactElement type. If there is no native Symbol +// nor polyfill, then a plain number is used for performance. + +var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; + +module.exports = REACT_ELEMENT_TYPE; + +/***/ }), +/* 276 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/* global Symbol */ + +var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; +var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. + +/** + * Returns the iterator method function contained on the iterable object. + * + * Be sure to invoke the function with the iterable as context: + * + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} + */ +function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } +} + +module.exports = getIteratorFn; + +/***/ }), +/* 277 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var KeyEscapeUtils = __webpack_require__(89); +var traverseAllChildren = __webpack_require__(145); +var warning = __webpack_require__(3); + +var ReactComponentTreeHook; + +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} + +/** + * @param {function} traverseContext Context passed through traversal. + * @param {?ReactComponent} child React child component. + * @param {!string} name String name of key path to child. + * @param {number=} selfDebugID Optional debugID of the current internal instance. + */ +function flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID) { + // We found a component instance. + if (traverseContext && typeof traverseContext === 'object') { + var result = traverseContext; + var keyUnique = result[name] === undefined; + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (!keyUnique) { + process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; + } + } + if (keyUnique && child != null) { + result[name] = child; + } + } +} + +/** + * Flattens children that are typically specified as `props.children`. Any null + * children will not be included in the resulting object. + * @return {!object} flattened children keyed by name. + */ +function flattenChildren(children, selfDebugID) { + if (children == null) { + return children; + } + var result = {}; + + if (process.env.NODE_ENV !== 'production') { + traverseAllChildren(children, function (traverseContext, child, name) { + return flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID); + }, result); + } else { + traverseAllChildren(children, flattenSingleChildIntoContext, result); + } + return result; +} + +module.exports = flattenChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 278 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var PooledClass = __webpack_require__(32); +var Transaction = __webpack_require__(58); +var ReactInstrumentation = __webpack_require__(19); +var ReactServerUpdateQueue = __webpack_require__(279); + +/** + * Executed within the scope of the `Transaction` instance. Consider these as + * being member methods, but with an implied ordering while being isolated from + * each other. + */ +var TRANSACTION_WRAPPERS = []; + +if (process.env.NODE_ENV !== 'production') { + TRANSACTION_WRAPPERS.push({ + initialize: ReactInstrumentation.debugTool.onBeginFlush, + close: ReactInstrumentation.debugTool.onEndFlush + }); +} + +var noopCallbackQueue = { + enqueue: function () {} +}; + +/** + * @class ReactServerRenderingTransaction + * @param {boolean} renderToStaticMarkup + */ +function ReactServerRenderingTransaction(renderToStaticMarkup) { + this.reinitializeTransaction(); + this.renderToStaticMarkup = renderToStaticMarkup; + this.useCreateElement = false; + this.updateQueue = new ReactServerUpdateQueue(this); +} + +var Mixin = { + /** + * @see Transaction + * @abstract + * @final + * @return {array} Empty list of operation wrap procedures. + */ + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, + + /** + * @return {object} The queue to collect `onDOMReady` callbacks with. + */ + getReactMountReady: function () { + return noopCallbackQueue; + }, + + /** + * @return {object} The queue to collect React async events. + */ + getUpdateQueue: function () { + return this.updateQueue; + }, + + /** + * `PooledClass` looks for this, and will invoke this before allowing this + * instance to be reused. + */ + destructor: function () {}, + + checkpoint: function () {}, + + rollback: function () {} +}; + +_assign(ReactServerRenderingTransaction.prototype, Transaction, Mixin); + +PooledClass.addPoolingTo(ReactServerRenderingTransaction); + +module.exports = ReactServerRenderingTransaction; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 279 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +var ReactUpdateQueue = __webpack_require__(90); + +var warning = __webpack_require__(3); + +function warnNoop(publicInstance, callerName) { + if (process.env.NODE_ENV !== 'production') { + var constructor = publicInstance.constructor; + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounting component. ' + 'This usually means you called %s() outside componentWillMount() on the server. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; + } +} + +/** + * This is the update queue used for server rendering. + * It delegates to ReactUpdateQueue while server rendering is in progress and + * switches to ReactNoopUpdateQueue after the transaction has completed. + * @class ReactServerUpdateQueue + * @param {Transaction} transaction + */ + +var ReactServerUpdateQueue = function () { + function ReactServerUpdateQueue(transaction) { + _classCallCheck(this, ReactServerUpdateQueue); + + this.transaction = transaction; + } + + /** + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + + + ReactServerUpdateQueue.prototype.isMounted = function isMounted(publicInstance) { + return false; + }; + + /** + * Enqueue a callback that will be executed after all the pending updates + * have processed. + * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @internal + */ + + + ReactServerUpdateQueue.prototype.enqueueCallback = function enqueueCallback(publicInstance, callback, callerName) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueCallback(publicInstance, callback, callerName); + } + }; + + /** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal + */ + + + ReactServerUpdateQueue.prototype.enqueueForceUpdate = function enqueueForceUpdate(publicInstance) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueForceUpdate(publicInstance); + } else { + warnNoop(publicInstance, 'forceUpdate'); + } + }; + + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object|function} completeState Next state. + * @internal + */ + + + ReactServerUpdateQueue.prototype.enqueueReplaceState = function enqueueReplaceState(publicInstance, completeState) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueReplaceState(publicInstance, completeState); + } else { + warnNoop(publicInstance, 'replaceState'); + } + }; + + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object|function} partialState Next partial state to be merged with state. + * @internal + */ + + + ReactServerUpdateQueue.prototype.enqueueSetState = function enqueueSetState(publicInstance, partialState) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueSetState(publicInstance, partialState); + } else { + warnNoop(publicInstance, 'setState'); + } + }; + + return ReactServerUpdateQueue; +}(); + +module.exports = ReactServerUpdateQueue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 280 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var DOMLazyTree = __webpack_require__(39); +var ReactDOMComponentTree = __webpack_require__(10); + +var ReactDOMEmptyComponent = function (instantiate) { + // ReactCompositeComponent uses this: + this._currentElement = null; + // ReactDOMComponentTree uses these: + this._hostNode = null; + this._hostParent = null; + this._hostContainerInfo = null; + this._domID = 0; +}; +_assign(ReactDOMEmptyComponent.prototype, { + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + var domID = hostContainerInfo._idCounter++; + this._domID = domID; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; + + var nodeValue = ' react-empty: ' + this._domID + ' '; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var node = ownerDocument.createComment(nodeValue); + ReactDOMComponentTree.precacheNode(this, node); + return DOMLazyTree(node); + } else { + if (transaction.renderToStaticMarkup) { + // Normally we'd insert a comment node, but since this is a situation + // where React won't take over (static pages), we can simply return + // nothing. + return ''; + } + return '<!--' + nodeValue + '-->'; + } + }, + receiveComponent: function () {}, + getHostNode: function () { + return ReactDOMComponentTree.getNodeFromInstance(this); + }, + unmountComponent: function () { + ReactDOMComponentTree.uncacheNode(this); + } +}); + +module.exports = ReactDOMEmptyComponent; + +/***/ }), +/* 281 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +/** + * Return the lowest common ancestor of A and B, or null if they are in + * different trees. + */ +function getLowestCommonAncestor(instA, instB) { + !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; + !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; + + var depthA = 0; + for (var tempA = instA; tempA; tempA = tempA._hostParent) { + depthA++; + } + var depthB = 0; + for (var tempB = instB; tempB; tempB = tempB._hostParent) { + depthB++; + } + + // If A is deeper, crawl up. + while (depthA - depthB > 0) { + instA = instA._hostParent; + depthA--; + } + + // If B is deeper, crawl up. + while (depthB - depthA > 0) { + instB = instB._hostParent; + depthB--; + } + + // Walk in lockstep until we find a match. + var depth = depthA; + while (depth--) { + if (instA === instB) { + return instA; + } + instA = instA._hostParent; + instB = instB._hostParent; + } + return null; +} + +/** + * Return if A is an ancestor of B. + */ +function isAncestor(instA, instB) { + !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; + !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; + + while (instB) { + if (instB === instA) { + return true; + } + instB = instB._hostParent; + } + return false; +} + +/** + * Return the parent instance of the passed-in instance. + */ +function getParentInstance(inst) { + !('_hostNode' in inst) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getParentInstance: Invalid argument.') : _prodInvariant('36') : void 0; + + return inst._hostParent; +} + +/** + * Simulates the traversal of a two-phase, capture/bubble event dispatch. + */ +function traverseTwoPhase(inst, fn, arg) { + var path = []; + while (inst) { + path.push(inst); + inst = inst._hostParent; + } + var i; + for (i = path.length; i-- > 0;) { + fn(path[i], 'captured', arg); + } + for (i = 0; i < path.length; i++) { + fn(path[i], 'bubbled', arg); + } +} + +/** + * Traverses the ID hierarchy and invokes the supplied `cb` on any IDs that + * should would receive a `mouseEnter` or `mouseLeave` event. + * + * Does not invoke the callback on the nearest common ancestor because nothing + * "entered" or "left" that element. + */ +function traverseEnterLeave(from, to, fn, argFrom, argTo) { + var common = from && to ? getLowestCommonAncestor(from, to) : null; + var pathFrom = []; + while (from && from !== common) { + pathFrom.push(from); + from = from._hostParent; + } + var pathTo = []; + while (to && to !== common) { + pathTo.push(to); + to = to._hostParent; + } + var i; + for (i = 0; i < pathFrom.length; i++) { + fn(pathFrom[i], 'bubbled', argFrom); + } + for (i = pathTo.length; i-- > 0;) { + fn(pathTo[i], 'captured', argTo); + } +} + +module.exports = { + isAncestor: isAncestor, + getLowestCommonAncestor: getLowestCommonAncestor, + getParentInstance: getParentInstance, + traverseTwoPhase: traverseTwoPhase, + traverseEnterLeave: traverseEnterLeave +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 282 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var DOMChildrenOperations = __webpack_require__(82); +var DOMLazyTree = __webpack_require__(39); +var ReactDOMComponentTree = __webpack_require__(10); + +var escapeTextContentForBrowser = __webpack_require__(61); +var invariant = __webpack_require__(2); +var validateDOMNesting = __webpack_require__(91); + +/** + * Text nodes violate a couple assumptions that React makes about components: + * + * - When mounting text into the DOM, adjacent text nodes are merged. + * - Text nodes cannot be assigned a React root ID. + * + * This component is used to wrap strings between comment nodes so that they + * can undergo the same reconciliation that is applied to elements. + * + * TODO: Investigate representing React components in the DOM with text nodes. + * + * @class ReactDOMTextComponent + * @extends ReactComponent + * @internal + */ +var ReactDOMTextComponent = function (text) { + // TODO: This is really a ReactText (ReactNode), not a ReactElement + this._currentElement = text; + this._stringText = '' + text; + // ReactDOMComponentTree uses these: + this._hostNode = null; + this._hostParent = null; + + // Properties + this._domID = 0; + this._mountIndex = 0; + this._closingComment = null; + this._commentNodes = null; +}; + +_assign(ReactDOMTextComponent.prototype, { + /** + * Creates the markup for this text node. This node is not intended to have + * any features besides containing text content. + * + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @return {string} Markup for this text node. + * @internal + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + if (process.env.NODE_ENV !== 'production') { + var parentInfo; + if (hostParent != null) { + parentInfo = hostParent._ancestorInfo; + } else if (hostContainerInfo != null) { + parentInfo = hostContainerInfo._ancestorInfo; + } + if (parentInfo) { + // parentInfo should always be present except for the top-level + // component when server rendering + validateDOMNesting(null, this._stringText, this, parentInfo); + } + } + + var domID = hostContainerInfo._idCounter++; + var openingValue = ' react-text: ' + domID + ' '; + var closingValue = ' /react-text '; + this._domID = domID; + this._hostParent = hostParent; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var openingComment = ownerDocument.createComment(openingValue); + var closingComment = ownerDocument.createComment(closingValue); + var lazyTree = DOMLazyTree(ownerDocument.createDocumentFragment()); + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(openingComment)); + if (this._stringText) { + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(ownerDocument.createTextNode(this._stringText))); + } + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(closingComment)); + ReactDOMComponentTree.precacheNode(this, openingComment); + this._closingComment = closingComment; + return lazyTree; + } else { + var escapedText = escapeTextContentForBrowser(this._stringText); + + if (transaction.renderToStaticMarkup) { + // Normally we'd wrap this between comment nodes for the reasons stated + // above, but since this is a situation where React won't take over + // (static pages), we can simply return the text as it is. + return escapedText; + } + + return '<!--' + openingValue + '-->' + escapedText + '<!--' + closingValue + '-->'; + } + }, + + /** + * Updates this component by updating the text content. + * + * @param {ReactText} nextText The next text content + * @param {ReactReconcileTransaction} transaction + * @internal + */ + receiveComponent: function (nextText, transaction) { + if (nextText !== this._currentElement) { + this._currentElement = nextText; + var nextStringText = '' + nextText; + if (nextStringText !== this._stringText) { + // TODO: Save this as pending props and use performUpdateIfNecessary + // and/or updateComponent to do the actual update for consistency with + // other component types? + this._stringText = nextStringText; + var commentNodes = this.getHostNode(); + DOMChildrenOperations.replaceDelimitedText(commentNodes[0], commentNodes[1], nextStringText); + } + } + }, + + getHostNode: function () { + var hostNode = this._commentNodes; + if (hostNode) { + return hostNode; + } + if (!this._closingComment) { + var openingComment = ReactDOMComponentTree.getNodeFromInstance(this); + var node = openingComment.nextSibling; + while (true) { + !(node != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Missing closing comment for text component %s', this._domID) : _prodInvariant('67', this._domID) : void 0; + if (node.nodeType === 8 && node.nodeValue === ' /react-text ') { + this._closingComment = node; + break; + } + node = node.nextSibling; + } + } + hostNode = [this._hostNode, this._closingComment]; + this._commentNodes = hostNode; + return hostNode; + }, + + unmountComponent: function () { + this._closingComment = null; + this._commentNodes = null; + ReactDOMComponentTree.uncacheNode(this); + } +}); + +module.exports = ReactDOMTextComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 283 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var ReactUpdates = __webpack_require__(23); +var Transaction = __webpack_require__(58); + +var emptyFunction = __webpack_require__(18); + +var RESET_BATCHED_UPDATES = { + initialize: emptyFunction, + close: function () { + ReactDefaultBatchingStrategy.isBatchingUpdates = false; + } +}; + +var FLUSH_BATCHED_UPDATES = { + initialize: emptyFunction, + close: ReactUpdates.flushBatchedUpdates.bind(ReactUpdates) +}; + +var TRANSACTION_WRAPPERS = [FLUSH_BATCHED_UPDATES, RESET_BATCHED_UPDATES]; + +function ReactDefaultBatchingStrategyTransaction() { + this.reinitializeTransaction(); +} + +_assign(ReactDefaultBatchingStrategyTransaction.prototype, Transaction, { + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + } +}); + +var transaction = new ReactDefaultBatchingStrategyTransaction(); + +var ReactDefaultBatchingStrategy = { + isBatchingUpdates: false, + + /** + * Call the provided function in a context within which calls to `setState` + * and friends are batched such that components aren't updated unnecessarily. + */ + batchedUpdates: function (callback, a, b, c, d, e) { + var alreadyBatchingUpdates = ReactDefaultBatchingStrategy.isBatchingUpdates; + + ReactDefaultBatchingStrategy.isBatchingUpdates = true; + + // The code is written this way to avoid extra allocations + if (alreadyBatchingUpdates) { + return callback(a, b, c, d, e); + } else { + return transaction.perform(callback, null, a, b, c, d, e); + } + } +}; + +module.exports = ReactDefaultBatchingStrategy; + +/***/ }), +/* 284 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var EventListener = __webpack_require__(146); +var ExecutionEnvironment = __webpack_require__(13); +var PooledClass = __webpack_require__(32); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); + +var getEventTarget = __webpack_require__(79); +var getUnboundedScrollPosition = __webpack_require__(285); + +/** + * Find the deepest React component completely containing the root of the + * passed-in instance (for use when entire React trees are nested within each + * other). If React trees are not nested, returns null. + */ +function findParent(inst) { + // TODO: It may be a good idea to cache this to prevent unnecessary DOM + // traversal, but caching is difficult to do correctly without using a + // mutation observer to listen for all DOM changes. + while (inst._hostParent) { + inst = inst._hostParent; + } + var rootNode = ReactDOMComponentTree.getNodeFromInstance(inst); + var container = rootNode.parentNode; + return ReactDOMComponentTree.getClosestInstanceFromNode(container); +} + +// Used to store ancestor hierarchy in top level callback +function TopLevelCallbackBookKeeping(topLevelType, nativeEvent) { + this.topLevelType = topLevelType; + this.nativeEvent = nativeEvent; + this.ancestors = []; +} +_assign(TopLevelCallbackBookKeeping.prototype, { + destructor: function () { + this.topLevelType = null; + this.nativeEvent = null; + this.ancestors.length = 0; + } +}); +PooledClass.addPoolingTo(TopLevelCallbackBookKeeping, PooledClass.twoArgumentPooler); + +function handleTopLevelImpl(bookKeeping) { + var nativeEventTarget = getEventTarget(bookKeeping.nativeEvent); + var targetInst = ReactDOMComponentTree.getClosestInstanceFromNode(nativeEventTarget); + + // Loop through the hierarchy, in case there's any nested components. + // It's important that we build the array of ancestors before calling any + // event handlers, because event handlers can modify the DOM, leading to + // inconsistencies with ReactMount's node cache. See #1105. + var ancestor = targetInst; + do { + bookKeeping.ancestors.push(ancestor); + ancestor = ancestor && findParent(ancestor); + } while (ancestor); + + for (var i = 0; i < bookKeeping.ancestors.length; i++) { + targetInst = bookKeeping.ancestors[i]; + ReactEventListener._handleTopLevel(bookKeeping.topLevelType, targetInst, bookKeeping.nativeEvent, getEventTarget(bookKeeping.nativeEvent)); + } +} + +function scrollValueMonitor(cb) { + var scrollPosition = getUnboundedScrollPosition(window); + cb(scrollPosition); +} + +var ReactEventListener = { + _enabled: true, + _handleTopLevel: null, + + WINDOW_HANDLE: ExecutionEnvironment.canUseDOM ? window : null, + + setHandleTopLevel: function (handleTopLevel) { + ReactEventListener._handleTopLevel = handleTopLevel; + }, + + setEnabled: function (enabled) { + ReactEventListener._enabled = !!enabled; + }, + + isEnabled: function () { + return ReactEventListener._enabled; + }, + + /** + * Traps top-level events by using event bubbling. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {string} handlerBaseName Event name (e.g. "click"). + * @param {object} element Element on which to attach listener. + * @return {?object} An object with a remove function which will forcefully + * remove the listener. + * @internal + */ + trapBubbledEvent: function (topLevelType, handlerBaseName, element) { + if (!element) { + return null; + } + return EventListener.listen(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); + }, + + /** + * Traps a top-level event by using event capturing. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {string} handlerBaseName Event name (e.g. "click"). + * @param {object} element Element on which to attach listener. + * @return {?object} An object with a remove function which will forcefully + * remove the listener. + * @internal + */ + trapCapturedEvent: function (topLevelType, handlerBaseName, element) { + if (!element) { + return null; + } + return EventListener.capture(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); + }, + + monitorScrollValue: function (refresh) { + var callback = scrollValueMonitor.bind(null, refresh); + EventListener.listen(window, 'scroll', callback); + }, + + dispatchEvent: function (topLevelType, nativeEvent) { + if (!ReactEventListener._enabled) { + return; + } + + var bookKeeping = TopLevelCallbackBookKeeping.getPooled(topLevelType, nativeEvent); + try { + // Event queue being processed in the same cycle allows + // `preventDefault`. + ReactUpdates.batchedUpdates(handleTopLevelImpl, bookKeeping); + } finally { + TopLevelCallbackBookKeeping.release(bookKeeping); + } + } +}; + +module.exports = ReactEventListener; + +/***/ }), +/* 285 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + + + +/** + * Gets the scroll position of the supplied element or window. + * + * The return values are unbounded, unlike `getScrollPosition`. This means they + * may be negative or exceed the element boundaries (which is possible using + * inertial scrolling). + * + * @param {DOMWindow|DOMElement} scrollable + * @return {object} Map with `x` and `y` keys. + */ + +function getUnboundedScrollPosition(scrollable) { + if (scrollable.Window && scrollable instanceof scrollable.Window) { + return { + x: scrollable.pageXOffset || scrollable.document.documentElement.scrollLeft, + y: scrollable.pageYOffset || scrollable.document.documentElement.scrollTop + }; + } + return { + x: scrollable.scrollLeft, + y: scrollable.scrollTop + }; +} + +module.exports = getUnboundedScrollPosition; + +/***/ }), +/* 286 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var EventPluginHub = __webpack_require__(46); +var EventPluginUtils = __webpack_require__(77); +var ReactComponentEnvironment = __webpack_require__(86); +var ReactEmptyComponent = __webpack_require__(143); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactHostComponent = __webpack_require__(144); +var ReactUpdates = __webpack_require__(23); + +var ReactInjection = { + Component: ReactComponentEnvironment.injection, + DOMProperty: DOMProperty.injection, + EmptyComponent: ReactEmptyComponent.injection, + EventPluginHub: EventPluginHub.injection, + EventPluginUtils: EventPluginUtils.injection, + EventEmitter: ReactBrowserEventEmitter.injection, + HostComponent: ReactHostComponent.injection, + Updates: ReactUpdates.injection +}; + +module.exports = ReactInjection; + +/***/ }), +/* 287 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var CallbackQueue = __webpack_require__(130); +var PooledClass = __webpack_require__(32); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactInputSelection = __webpack_require__(147); +var ReactInstrumentation = __webpack_require__(19); +var Transaction = __webpack_require__(58); +var ReactUpdateQueue = __webpack_require__(90); + +/** + * Ensures that, when possible, the selection range (currently selected text + * input) is not disturbed by performing the transaction. + */ +var SELECTION_RESTORATION = { + /** + * @return {Selection} Selection information. + */ + initialize: ReactInputSelection.getSelectionInformation, + /** + * @param {Selection} sel Selection information returned from `initialize`. + */ + close: ReactInputSelection.restoreSelection +}; + +/** + * Suppresses events (blur/focus) that could be inadvertently dispatched due to + * high level DOM manipulations (like temporarily removing a text input from the + * DOM). + */ +var EVENT_SUPPRESSION = { + /** + * @return {boolean} The enabled status of `ReactBrowserEventEmitter` before + * the reconciliation. + */ + initialize: function () { + var currentlyEnabled = ReactBrowserEventEmitter.isEnabled(); + ReactBrowserEventEmitter.setEnabled(false); + return currentlyEnabled; + }, + + /** + * @param {boolean} previouslyEnabled Enabled status of + * `ReactBrowserEventEmitter` before the reconciliation occurred. `close` + * restores the previous value. + */ + close: function (previouslyEnabled) { + ReactBrowserEventEmitter.setEnabled(previouslyEnabled); + } +}; + +/** + * Provides a queue for collecting `componentDidMount` and + * `componentDidUpdate` callbacks during the transaction. + */ +var ON_DOM_READY_QUEUEING = { + /** + * Initializes the internal `onDOMReady` queue. + */ + initialize: function () { + this.reactMountReady.reset(); + }, + + /** + * After DOM is flushed, invoke all registered `onDOMReady` callbacks. + */ + close: function () { + this.reactMountReady.notifyAll(); + } +}; + +/** + * Executed within the scope of the `Transaction` instance. Consider these as + * being member methods, but with an implied ordering while being isolated from + * each other. + */ +var TRANSACTION_WRAPPERS = [SELECTION_RESTORATION, EVENT_SUPPRESSION, ON_DOM_READY_QUEUEING]; + +if (process.env.NODE_ENV !== 'production') { + TRANSACTION_WRAPPERS.push({ + initialize: ReactInstrumentation.debugTool.onBeginFlush, + close: ReactInstrumentation.debugTool.onEndFlush + }); +} + +/** + * Currently: + * - The order that these are listed in the transaction is critical: + * - Suppresses events. + * - Restores selection range. + * + * Future: + * - Restore document/overflow scroll positions that were unintentionally + * modified via DOM insertions above the top viewport boundary. + * - Implement/integrate with customized constraint based layout system and keep + * track of which dimensions must be remeasured. + * + * @class ReactReconcileTransaction + */ +function ReactReconcileTransaction(useCreateElement) { + this.reinitializeTransaction(); + // Only server-side rendering really needs this option (see + // `ReactServerRendering`), but server-side uses + // `ReactServerRenderingTransaction` instead. This option is here so that it's + // accessible and defaults to false when `ReactDOMComponent` and + // `ReactDOMTextComponent` checks it in `mountComponent`.` + this.renderToStaticMarkup = false; + this.reactMountReady = CallbackQueue.getPooled(null); + this.useCreateElement = useCreateElement; +} + +var Mixin = { + /** + * @see Transaction + * @abstract + * @final + * @return {array<object>} List of operation wrap procedures. + * TODO: convert to array<TransactionWrapper> + */ + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, + + /** + * @return {object} The queue to collect `onDOMReady` callbacks with. + */ + getReactMountReady: function () { + return this.reactMountReady; + }, + + /** + * @return {object} The queue to collect React async events. + */ + getUpdateQueue: function () { + return ReactUpdateQueue; + }, + + /** + * Save current transaction state -- if the return value from this method is + * passed to `rollback`, the transaction will be reset to that state. + */ + checkpoint: function () { + // reactMountReady is the our only stateful wrapper + return this.reactMountReady.checkpoint(); + }, + + rollback: function (checkpoint) { + this.reactMountReady.rollback(checkpoint); + }, + + /** + * `PooledClass` looks for this, and will invoke this before allowing this + * instance to be reused. + */ + destructor: function () { + CallbackQueue.release(this.reactMountReady); + this.reactMountReady = null; + } +}; + +_assign(ReactReconcileTransaction.prototype, Transaction, Mixin); + +PooledClass.addPoolingTo(ReactReconcileTransaction); + +module.exports = ReactReconcileTransaction; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 288 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +var getNodeForCharacterOffset = __webpack_require__(289); +var getTextContentAccessor = __webpack_require__(129); + +/** + * While `isCollapsed` is available on the Selection object and `collapsed` + * is available on the Range object, IE11 sometimes gets them wrong. + * If the anchor/focus nodes and offsets are the same, the range is collapsed. + */ +function isCollapsed(anchorNode, anchorOffset, focusNode, focusOffset) { + return anchorNode === focusNode && anchorOffset === focusOffset; +} + +/** + * Get the appropriate anchor and focus node/offset pairs for IE. + * + * The catch here is that IE's selection API doesn't provide information + * about whether the selection is forward or backward, so we have to + * behave as though it's always forward. + * + * IE text differs from modern selection in that it behaves as though + * block elements end with a new line. This means character offsets will + * differ between the two APIs. + * + * @param {DOMElement} node + * @return {object} + */ +function getIEOffsets(node) { + var selection = document.selection; + var selectedRange = selection.createRange(); + var selectedLength = selectedRange.text.length; + + // Duplicate selection so we can move range without breaking user selection. + var fromStart = selectedRange.duplicate(); + fromStart.moveToElementText(node); + fromStart.setEndPoint('EndToStart', selectedRange); + + var startOffset = fromStart.text.length; + var endOffset = startOffset + selectedLength; + + return { + start: startOffset, + end: endOffset + }; +} + +/** + * @param {DOMElement} node + * @return {?object} + */ +function getModernOffsets(node) { + var selection = window.getSelection && window.getSelection(); + + if (!selection || selection.rangeCount === 0) { + return null; + } + + var anchorNode = selection.anchorNode; + var anchorOffset = selection.anchorOffset; + var focusNode = selection.focusNode; + var focusOffset = selection.focusOffset; + + var currentRange = selection.getRangeAt(0); + + // In Firefox, range.startContainer and range.endContainer can be "anonymous + // divs", e.g. the up/down buttons on an <input type="number">. Anonymous + // divs do not seem to expose properties, triggering a "Permission denied + // error" if any of its properties are accessed. The only seemingly possible + // way to avoid erroring is to access a property that typically works for + // non-anonymous divs and catch any error that may otherwise arise. See + // https://bugzilla.mozilla.org/show_bug.cgi?id=208427 + try { + /* eslint-disable no-unused-expressions */ + currentRange.startContainer.nodeType; + currentRange.endContainer.nodeType; + /* eslint-enable no-unused-expressions */ + } catch (e) { + return null; + } + + // If the node and offset values are the same, the selection is collapsed. + // `Selection.isCollapsed` is available natively, but IE sometimes gets + // this value wrong. + var isSelectionCollapsed = isCollapsed(selection.anchorNode, selection.anchorOffset, selection.focusNode, selection.focusOffset); + + var rangeLength = isSelectionCollapsed ? 0 : currentRange.toString().length; + + var tempRange = currentRange.cloneRange(); + tempRange.selectNodeContents(node); + tempRange.setEnd(currentRange.startContainer, currentRange.startOffset); + + var isTempRangeCollapsed = isCollapsed(tempRange.startContainer, tempRange.startOffset, tempRange.endContainer, tempRange.endOffset); + + var start = isTempRangeCollapsed ? 0 : tempRange.toString().length; + var end = start + rangeLength; + + // Detect whether the selection is backward. + var detectionRange = document.createRange(); + detectionRange.setStart(anchorNode, anchorOffset); + detectionRange.setEnd(focusNode, focusOffset); + var isBackward = detectionRange.collapsed; + + return { + start: isBackward ? end : start, + end: isBackward ? start : end + }; +} + +/** + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ +function setIEOffsets(node, offsets) { + var range = document.selection.createRange().duplicate(); + var start, end; + + if (offsets.end === undefined) { + start = offsets.start; + end = start; + } else if (offsets.start > offsets.end) { + start = offsets.end; + end = offsets.start; + } else { + start = offsets.start; + end = offsets.end; + } + + range.moveToElementText(node); + range.moveStart('character', start); + range.setEndPoint('EndToStart', range); + range.moveEnd('character', end - start); + range.select(); +} + +/** + * In modern non-IE browsers, we can support both forward and backward + * selections. + * + * Note: IE10+ supports the Selection object, but it does not support + * the `extend` method, which means that even in modern IE, it's not possible + * to programmatically create a backward selection. Thus, for all IE + * versions, we use the old IE API to create our selections. + * + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ +function setModernOffsets(node, offsets) { + if (!window.getSelection) { + return; + } + + var selection = window.getSelection(); + var length = node[getTextContentAccessor()].length; + var start = Math.min(offsets.start, length); + var end = offsets.end === undefined ? start : Math.min(offsets.end, length); + + // IE 11 uses modern selection, but doesn't support the extend method. + // Flip backward selections, so we can set with a single range. + if (!selection.extend && start > end) { + var temp = end; + end = start; + start = temp; + } + + var startMarker = getNodeForCharacterOffset(node, start); + var endMarker = getNodeForCharacterOffset(node, end); + + if (startMarker && endMarker) { + var range = document.createRange(); + range.setStart(startMarker.node, startMarker.offset); + selection.removeAllRanges(); + + if (start > end) { + selection.addRange(range); + selection.extend(endMarker.node, endMarker.offset); + } else { + range.setEnd(endMarker.node, endMarker.offset); + selection.addRange(range); + } + } +} + +var useIEOffsets = ExecutionEnvironment.canUseDOM && 'selection' in document && !('getSelection' in window); + +var ReactDOMSelection = { + /** + * @param {DOMElement} node + */ + getOffsets: useIEOffsets ? getIEOffsets : getModernOffsets, + + /** + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ + setOffsets: useIEOffsets ? setIEOffsets : setModernOffsets +}; + +module.exports = ReactDOMSelection; + +/***/ }), +/* 289 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * Given any node return the first leaf node without children. + * + * @param {DOMElement|DOMTextNode} node + * @return {DOMElement|DOMTextNode} + */ + +function getLeafNode(node) { + while (node && node.firstChild) { + node = node.firstChild; + } + return node; +} + +/** + * Get the next sibling within a container. This will walk up the + * DOM if a node's siblings have been exhausted. + * + * @param {DOMElement|DOMTextNode} node + * @return {?DOMElement|DOMTextNode} + */ +function getSiblingNode(node) { + while (node) { + if (node.nextSibling) { + return node.nextSibling; + } + node = node.parentNode; + } +} + +/** + * Get object describing the nodes which contain characters at offset. + * + * @param {DOMElement|DOMTextNode} root + * @param {number} offset + * @return {?object} + */ +function getNodeForCharacterOffset(root, offset) { + var node = getLeafNode(root); + var nodeStart = 0; + var nodeEnd = 0; + + while (node) { + if (node.nodeType === 3) { + nodeEnd = nodeStart + node.textContent.length; + + if (nodeStart <= offset && nodeEnd >= offset) { + return { + node: node, + offset: offset - nodeStart + }; + } + + nodeStart = nodeEnd; + } + + node = getLeafNode(getSiblingNode(node)); + } +} + +module.exports = getNodeForCharacterOffset; + +/***/ }), +/* 290 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + +var isTextNode = __webpack_require__(291); + +/*eslint-disable no-bitwise */ + +/** + * Checks if a given DOM node contains or is another DOM node. + */ +function containsNode(outerNode, innerNode) { + if (!outerNode || !innerNode) { + return false; + } else if (outerNode === innerNode) { + return true; + } else if (isTextNode(outerNode)) { + return false; + } else if (isTextNode(innerNode)) { + return containsNode(outerNode, innerNode.parentNode); + } else if ('contains' in outerNode) { + return outerNode.contains(innerNode); + } else if (outerNode.compareDocumentPosition) { + return !!(outerNode.compareDocumentPosition(innerNode) & 16); + } else { + return false; + } +} + +module.exports = containsNode; + +/***/ }), +/* 291 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var isNode = __webpack_require__(292); + +/** + * @param {*} object The object to check. + * @return {boolean} Whether or not the object is a DOM text node. + */ +function isTextNode(object) { + return isNode(object) && object.nodeType == 3; +} + +module.exports = isTextNode; + +/***/ }), +/* 292 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +/** + * @param {*} object The object to check. + * @return {boolean} Whether or not the object is a DOM node. + */ +function isNode(object) { + var doc = object ? object.ownerDocument || object : document; + var defaultView = doc.defaultView || window; + return !!(object && (typeof defaultView.Node === 'function' ? object instanceof defaultView.Node : typeof object === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string')); +} + +module.exports = isNode; + +/***/ }), +/* 293 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var NS = { + xlink: 'http://www.w3.org/1999/xlink', + xml: 'http://www.w3.org/XML/1998/namespace' +}; + +// We use attributes for everything SVG so let's avoid some duplication and run +// code instead. +// The following are all specified in the HTML config already so we exclude here. +// - class (as className) +// - color +// - height +// - id +// - lang +// - max +// - media +// - method +// - min +// - name +// - style +// - target +// - type +// - width +var ATTRS = { + accentHeight: 'accent-height', + accumulate: 0, + additive: 0, + alignmentBaseline: 'alignment-baseline', + allowReorder: 'allowReorder', + alphabetic: 0, + amplitude: 0, + arabicForm: 'arabic-form', + ascent: 0, + attributeName: 'attributeName', + attributeType: 'attributeType', + autoReverse: 'autoReverse', + azimuth: 0, + baseFrequency: 'baseFrequency', + baseProfile: 'baseProfile', + baselineShift: 'baseline-shift', + bbox: 0, + begin: 0, + bias: 0, + by: 0, + calcMode: 'calcMode', + capHeight: 'cap-height', + clip: 0, + clipPath: 'clip-path', + clipRule: 'clip-rule', + clipPathUnits: 'clipPathUnits', + colorInterpolation: 'color-interpolation', + colorInterpolationFilters: 'color-interpolation-filters', + colorProfile: 'color-profile', + colorRendering: 'color-rendering', + contentScriptType: 'contentScriptType', + contentStyleType: 'contentStyleType', + cursor: 0, + cx: 0, + cy: 0, + d: 0, + decelerate: 0, + descent: 0, + diffuseConstant: 'diffuseConstant', + direction: 0, + display: 0, + divisor: 0, + dominantBaseline: 'dominant-baseline', + dur: 0, + dx: 0, + dy: 0, + edgeMode: 'edgeMode', + elevation: 0, + enableBackground: 'enable-background', + end: 0, + exponent: 0, + externalResourcesRequired: 'externalResourcesRequired', + fill: 0, + fillOpacity: 'fill-opacity', + fillRule: 'fill-rule', + filter: 0, + filterRes: 'filterRes', + filterUnits: 'filterUnits', + floodColor: 'flood-color', + floodOpacity: 'flood-opacity', + focusable: 0, + fontFamily: 'font-family', + fontSize: 'font-size', + fontSizeAdjust: 'font-size-adjust', + fontStretch: 'font-stretch', + fontStyle: 'font-style', + fontVariant: 'font-variant', + fontWeight: 'font-weight', + format: 0, + from: 0, + fx: 0, + fy: 0, + g1: 0, + g2: 0, + glyphName: 'glyph-name', + glyphOrientationHorizontal: 'glyph-orientation-horizontal', + glyphOrientationVertical: 'glyph-orientation-vertical', + glyphRef: 'glyphRef', + gradientTransform: 'gradientTransform', + gradientUnits: 'gradientUnits', + hanging: 0, + horizAdvX: 'horiz-adv-x', + horizOriginX: 'horiz-origin-x', + ideographic: 0, + imageRendering: 'image-rendering', + 'in': 0, + in2: 0, + intercept: 0, + k: 0, + k1: 0, + k2: 0, + k3: 0, + k4: 0, + kernelMatrix: 'kernelMatrix', + kernelUnitLength: 'kernelUnitLength', + kerning: 0, + keyPoints: 'keyPoints', + keySplines: 'keySplines', + keyTimes: 'keyTimes', + lengthAdjust: 'lengthAdjust', + letterSpacing: 'letter-spacing', + lightingColor: 'lighting-color', + limitingConeAngle: 'limitingConeAngle', + local: 0, + markerEnd: 'marker-end', + markerMid: 'marker-mid', + markerStart: 'marker-start', + markerHeight: 'markerHeight', + markerUnits: 'markerUnits', + markerWidth: 'markerWidth', + mask: 0, + maskContentUnits: 'maskContentUnits', + maskUnits: 'maskUnits', + mathematical: 0, + mode: 0, + numOctaves: 'numOctaves', + offset: 0, + opacity: 0, + operator: 0, + order: 0, + orient: 0, + orientation: 0, + origin: 0, + overflow: 0, + overlinePosition: 'overline-position', + overlineThickness: 'overline-thickness', + paintOrder: 'paint-order', + panose1: 'panose-1', + pathLength: 'pathLength', + patternContentUnits: 'patternContentUnits', + patternTransform: 'patternTransform', + patternUnits: 'patternUnits', + pointerEvents: 'pointer-events', + points: 0, + pointsAtX: 'pointsAtX', + pointsAtY: 'pointsAtY', + pointsAtZ: 'pointsAtZ', + preserveAlpha: 'preserveAlpha', + preserveAspectRatio: 'preserveAspectRatio', + primitiveUnits: 'primitiveUnits', + r: 0, + radius: 0, + refX: 'refX', + refY: 'refY', + renderingIntent: 'rendering-intent', + repeatCount: 'repeatCount', + repeatDur: 'repeatDur', + requiredExtensions: 'requiredExtensions', + requiredFeatures: 'requiredFeatures', + restart: 0, + result: 0, + rotate: 0, + rx: 0, + ry: 0, + scale: 0, + seed: 0, + shapeRendering: 'shape-rendering', + slope: 0, + spacing: 0, + specularConstant: 'specularConstant', + specularExponent: 'specularExponent', + speed: 0, + spreadMethod: 'spreadMethod', + startOffset: 'startOffset', + stdDeviation: 'stdDeviation', + stemh: 0, + stemv: 0, + stitchTiles: 'stitchTiles', + stopColor: 'stop-color', + stopOpacity: 'stop-opacity', + strikethroughPosition: 'strikethrough-position', + strikethroughThickness: 'strikethrough-thickness', + string: 0, + stroke: 0, + strokeDasharray: 'stroke-dasharray', + strokeDashoffset: 'stroke-dashoffset', + strokeLinecap: 'stroke-linecap', + strokeLinejoin: 'stroke-linejoin', + strokeMiterlimit: 'stroke-miterlimit', + strokeOpacity: 'stroke-opacity', + strokeWidth: 'stroke-width', + surfaceScale: 'surfaceScale', + systemLanguage: 'systemLanguage', + tableValues: 'tableValues', + targetX: 'targetX', + targetY: 'targetY', + textAnchor: 'text-anchor', + textDecoration: 'text-decoration', + textRendering: 'text-rendering', + textLength: 'textLength', + to: 0, + transform: 0, + u1: 0, + u2: 0, + underlinePosition: 'underline-position', + underlineThickness: 'underline-thickness', + unicode: 0, + unicodeBidi: 'unicode-bidi', + unicodeRange: 'unicode-range', + unitsPerEm: 'units-per-em', + vAlphabetic: 'v-alphabetic', + vHanging: 'v-hanging', + vIdeographic: 'v-ideographic', + vMathematical: 'v-mathematical', + values: 0, + vectorEffect: 'vector-effect', + version: 0, + vertAdvY: 'vert-adv-y', + vertOriginX: 'vert-origin-x', + vertOriginY: 'vert-origin-y', + viewBox: 'viewBox', + viewTarget: 'viewTarget', + visibility: 0, + widths: 0, + wordSpacing: 'word-spacing', + writingMode: 'writing-mode', + x: 0, + xHeight: 'x-height', + x1: 0, + x2: 0, + xChannelSelector: 'xChannelSelector', + xlinkActuate: 'xlink:actuate', + xlinkArcrole: 'xlink:arcrole', + xlinkHref: 'xlink:href', + xlinkRole: 'xlink:role', + xlinkShow: 'xlink:show', + xlinkTitle: 'xlink:title', + xlinkType: 'xlink:type', + xmlBase: 'xml:base', + xmlns: 0, + xmlnsXlink: 'xmlns:xlink', + xmlLang: 'xml:lang', + xmlSpace: 'xml:space', + y: 0, + y1: 0, + y2: 0, + yChannelSelector: 'yChannelSelector', + z: 0, + zoomAndPan: 'zoomAndPan' +}; + +var SVGDOMPropertyConfig = { + Properties: {}, + DOMAttributeNamespaces: { + xlinkActuate: NS.xlink, + xlinkArcrole: NS.xlink, + xlinkHref: NS.xlink, + xlinkRole: NS.xlink, + xlinkShow: NS.xlink, + xlinkTitle: NS.xlink, + xlinkType: NS.xlink, + xmlBase: NS.xml, + xmlLang: NS.xml, + xmlSpace: NS.xml + }, + DOMAttributeNames: {} +}; + +Object.keys(ATTRS).forEach(function (key) { + SVGDOMPropertyConfig.Properties[key] = 0; + if (ATTRS[key]) { + SVGDOMPropertyConfig.DOMAttributeNames[key] = ATTRS[key]; + } +}); + +module.exports = SVGDOMPropertyConfig; + +/***/ }), +/* 294 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInputSelection = __webpack_require__(147); +var SyntheticEvent = __webpack_require__(26); + +var getActiveElement = __webpack_require__(148); +var isTextInputElement = __webpack_require__(133); +var shallowEqual = __webpack_require__(87); + +var skipSelectionChangeEvent = ExecutionEnvironment.canUseDOM && 'documentMode' in document && document.documentMode <= 11; + +var eventTypes = { + select: { + phasedRegistrationNames: { + bubbled: 'onSelect', + captured: 'onSelectCapture' + }, + dependencies: ['topBlur', 'topContextMenu', 'topFocus', 'topKeyDown', 'topKeyUp', 'topMouseDown', 'topMouseUp', 'topSelectionChange'] + } +}; + +var activeElement = null; +var activeElementInst = null; +var lastSelection = null; +var mouseDown = false; + +// Track whether a listener exists for this plugin. If none exist, we do +// not extract events. See #3639. +var hasListener = false; + +/** + * Get an object which is a unique representation of the current selection. + * + * The return value will not be consistent across nodes or browsers, but + * two identical selections on the same node will return identical objects. + * + * @param {DOMElement} node + * @return {object} + */ +function getSelection(node) { + if ('selectionStart' in node && ReactInputSelection.hasSelectionCapabilities(node)) { + return { + start: node.selectionStart, + end: node.selectionEnd + }; + } else if (window.getSelection) { + var selection = window.getSelection(); + return { + anchorNode: selection.anchorNode, + anchorOffset: selection.anchorOffset, + focusNode: selection.focusNode, + focusOffset: selection.focusOffset + }; + } else if (document.selection) { + var range = document.selection.createRange(); + return { + parentElement: range.parentElement(), + text: range.text, + top: range.boundingTop, + left: range.boundingLeft + }; + } +} + +/** + * Poll selection to see whether it's changed. + * + * @param {object} nativeEvent + * @return {?SyntheticEvent} + */ +function constructSelectEvent(nativeEvent, nativeEventTarget) { + // Ensure we have the right element, and that the user is not dragging a + // selection (this matches native `select` event behavior). In HTML5, select + // fires only on input and textarea thus if there's no focused element we + // won't dispatch. + if (mouseDown || activeElement == null || activeElement !== getActiveElement()) { + return null; + } + + // Only fire when selection has actually changed. + var currentSelection = getSelection(activeElement); + if (!lastSelection || !shallowEqual(lastSelection, currentSelection)) { + lastSelection = currentSelection; + + var syntheticEvent = SyntheticEvent.getPooled(eventTypes.select, activeElementInst, nativeEvent, nativeEventTarget); + + syntheticEvent.type = 'select'; + syntheticEvent.target = activeElement; + + EventPropagators.accumulateTwoPhaseDispatches(syntheticEvent); + + return syntheticEvent; + } + + return null; +} + +/** + * This plugin creates an `onSelect` event that normalizes select events + * across form elements. + * + * Supported elements are: + * - input (see `isTextInputElement`) + * - textarea + * - contentEditable + * + * This differs from native browser implementations in the following ways: + * - Fires on contentEditable fields as well as inputs. + * - Fires for collapsed selection. + * - Fires after user input. + */ +var SelectEventPlugin = { + eventTypes: eventTypes, + + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + if (!hasListener) { + return null; + } + + var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; + + switch (topLevelType) { + // Track the input node that has focus. + case 'topFocus': + if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') { + activeElement = targetNode; + activeElementInst = targetInst; + lastSelection = null; + } + break; + case 'topBlur': + activeElement = null; + activeElementInst = null; + lastSelection = null; + break; + // Don't fire the event while the user is dragging. This matches the + // semantics of the native select event. + case 'topMouseDown': + mouseDown = true; + break; + case 'topContextMenu': + case 'topMouseUp': + mouseDown = false; + return constructSelectEvent(nativeEvent, nativeEventTarget); + // Chrome and IE fire non-standard event when selection is changed (and + // sometimes when it hasn't). IE's event fires out of order with respect + // to key and input events on deletion, so we discard it. + // + // Firefox doesn't support selectionchange, so check selection status + // after each key entry. The selection changes after keydown and before + // keyup, but we check on keydown as well in the case of holding down a + // key, when multiple keydown events are fired but only one keyup is. + // This is also our approach for IE handling, for the reason above. + case 'topSelectionChange': + if (skipSelectionChangeEvent) { + break; + } + // falls through + case 'topKeyDown': + case 'topKeyUp': + return constructSelectEvent(nativeEvent, nativeEventTarget); + } + + return null; + }, + + didPutListener: function (inst, registrationName, listener) { + if (registrationName === 'onSelect') { + hasListener = true; + } + } +}; + +module.exports = SelectEventPlugin; + +/***/ }), +/* 295 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var EventListener = __webpack_require__(146); +var EventPropagators = __webpack_require__(45); +var ReactDOMComponentTree = __webpack_require__(10); +var SyntheticAnimationEvent = __webpack_require__(296); +var SyntheticClipboardEvent = __webpack_require__(297); +var SyntheticEvent = __webpack_require__(26); +var SyntheticFocusEvent = __webpack_require__(298); +var SyntheticKeyboardEvent = __webpack_require__(299); +var SyntheticMouseEvent = __webpack_require__(59); +var SyntheticDragEvent = __webpack_require__(301); +var SyntheticTouchEvent = __webpack_require__(302); +var SyntheticTransitionEvent = __webpack_require__(303); +var SyntheticUIEvent = __webpack_require__(47); +var SyntheticWheelEvent = __webpack_require__(304); + +var emptyFunction = __webpack_require__(18); +var getEventCharCode = __webpack_require__(92); +var invariant = __webpack_require__(2); + +/** + * Turns + * ['abort', ...] + * into + * eventTypes = { + * 'abort': { + * phasedRegistrationNames: { + * bubbled: 'onAbort', + * captured: 'onAbortCapture', + * }, + * dependencies: ['topAbort'], + * }, + * ... + * }; + * topLevelEventsToDispatchConfig = { + * 'topAbort': { sameConfig } + * }; + */ +var eventTypes = {}; +var topLevelEventsToDispatchConfig = {}; +['abort', 'animationEnd', 'animationIteration', 'animationStart', 'blur', 'canPlay', 'canPlayThrough', 'click', 'contextMenu', 'copy', 'cut', 'doubleClick', 'drag', 'dragEnd', 'dragEnter', 'dragExit', 'dragLeave', 'dragOver', 'dragStart', 'drop', 'durationChange', 'emptied', 'encrypted', 'ended', 'error', 'focus', 'input', 'invalid', 'keyDown', 'keyPress', 'keyUp', 'load', 'loadedData', 'loadedMetadata', 'loadStart', 'mouseDown', 'mouseMove', 'mouseOut', 'mouseOver', 'mouseUp', 'paste', 'pause', 'play', 'playing', 'progress', 'rateChange', 'reset', 'scroll', 'seeked', 'seeking', 'stalled', 'submit', 'suspend', 'timeUpdate', 'touchCancel', 'touchEnd', 'touchMove', 'touchStart', 'transitionEnd', 'volumeChange', 'waiting', 'wheel'].forEach(function (event) { + var capitalizedEvent = event[0].toUpperCase() + event.slice(1); + var onEvent = 'on' + capitalizedEvent; + var topEvent = 'top' + capitalizedEvent; + + var type = { + phasedRegistrationNames: { + bubbled: onEvent, + captured: onEvent + 'Capture' + }, + dependencies: [topEvent] + }; + eventTypes[event] = type; + topLevelEventsToDispatchConfig[topEvent] = type; +}); + +var onClickListeners = {}; + +function getDictionaryKey(inst) { + // Prevents V8 performance issue: + // https://github.com/facebook/react/pull/7232 + return '.' + inst._rootNodeID; +} + +function isInteractive(tag) { + return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; +} + +var SimpleEventPlugin = { + eventTypes: eventTypes, + + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var dispatchConfig = topLevelEventsToDispatchConfig[topLevelType]; + if (!dispatchConfig) { + return null; + } + var EventConstructor; + switch (topLevelType) { + case 'topAbort': + case 'topCanPlay': + case 'topCanPlayThrough': + case 'topDurationChange': + case 'topEmptied': + case 'topEncrypted': + case 'topEnded': + case 'topError': + case 'topInput': + case 'topInvalid': + case 'topLoad': + case 'topLoadedData': + case 'topLoadedMetadata': + case 'topLoadStart': + case 'topPause': + case 'topPlay': + case 'topPlaying': + case 'topProgress': + case 'topRateChange': + case 'topReset': + case 'topSeeked': + case 'topSeeking': + case 'topStalled': + case 'topSubmit': + case 'topSuspend': + case 'topTimeUpdate': + case 'topVolumeChange': + case 'topWaiting': + // HTML Events + // @see http://www.w3.org/TR/html5/index.html#events-0 + EventConstructor = SyntheticEvent; + break; + case 'topKeyPress': + // Firefox creates a keypress event for function keys too. This removes + // the unwanted keypress events. Enter is however both printable and + // non-printable. One would expect Tab to be as well (but it isn't). + if (getEventCharCode(nativeEvent) === 0) { + return null; + } + /* falls through */ + case 'topKeyDown': + case 'topKeyUp': + EventConstructor = SyntheticKeyboardEvent; + break; + case 'topBlur': + case 'topFocus': + EventConstructor = SyntheticFocusEvent; + break; + case 'topClick': + // Firefox creates a click event on right mouse clicks. This removes the + // unwanted click events. + if (nativeEvent.button === 2) { + return null; + } + /* falls through */ + case 'topDoubleClick': + case 'topMouseDown': + case 'topMouseMove': + case 'topMouseUp': + // TODO: Disabled elements should not respond to mouse events + /* falls through */ + case 'topMouseOut': + case 'topMouseOver': + case 'topContextMenu': + EventConstructor = SyntheticMouseEvent; + break; + case 'topDrag': + case 'topDragEnd': + case 'topDragEnter': + case 'topDragExit': + case 'topDragLeave': + case 'topDragOver': + case 'topDragStart': + case 'topDrop': + EventConstructor = SyntheticDragEvent; + break; + case 'topTouchCancel': + case 'topTouchEnd': + case 'topTouchMove': + case 'topTouchStart': + EventConstructor = SyntheticTouchEvent; + break; + case 'topAnimationEnd': + case 'topAnimationIteration': + case 'topAnimationStart': + EventConstructor = SyntheticAnimationEvent; + break; + case 'topTransitionEnd': + EventConstructor = SyntheticTransitionEvent; + break; + case 'topScroll': + EventConstructor = SyntheticUIEvent; + break; + case 'topWheel': + EventConstructor = SyntheticWheelEvent; + break; + case 'topCopy': + case 'topCut': + case 'topPaste': + EventConstructor = SyntheticClipboardEvent; + break; + } + !EventConstructor ? process.env.NODE_ENV !== 'production' ? invariant(false, 'SimpleEventPlugin: Unhandled event type, `%s`.', topLevelType) : _prodInvariant('86', topLevelType) : void 0; + var event = EventConstructor.getPooled(dispatchConfig, targetInst, nativeEvent, nativeEventTarget); + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; + }, + + didPutListener: function (inst, registrationName, listener) { + // Mobile Safari does not fire properly bubble click events on + // non-interactive elements, which means delegated click listeners do not + // fire. The workaround for this bug involves attaching an empty click + // listener on the target node. + // http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html + if (registrationName === 'onClick' && !isInteractive(inst._tag)) { + var key = getDictionaryKey(inst); + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + if (!onClickListeners[key]) { + onClickListeners[key] = EventListener.listen(node, 'click', emptyFunction); + } + } + }, + + willDeleteListener: function (inst, registrationName) { + if (registrationName === 'onClick' && !isInteractive(inst._tag)) { + var key = getDictionaryKey(inst); + onClickListeners[key].remove(); + delete onClickListeners[key]; + } + } +}; + +module.exports = SimpleEventPlugin; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 296 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/css3-animations/#AnimationEvent-interface + * @see https://developer.mozilla.org/en-US/docs/Web/API/AnimationEvent + */ +var AnimationEventInterface = { + animationName: null, + elapsedTime: null, + pseudoElement: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticAnimationEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticAnimationEvent, AnimationEventInterface); + +module.exports = SyntheticAnimationEvent; + +/***/ }), +/* 297 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/clipboard-apis/ + */ +var ClipboardEventInterface = { + clipboardData: function (event) { + return 'clipboardData' in event ? event.clipboardData : window.clipboardData; + } +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticClipboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticClipboardEvent, ClipboardEventInterface); + +module.exports = SyntheticClipboardEvent; + +/***/ }), +/* 298 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticUIEvent = __webpack_require__(47); + +/** + * @interface FocusEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var FocusEventInterface = { + relatedTarget: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticFocusEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticUIEvent.augmentClass(SyntheticFocusEvent, FocusEventInterface); + +module.exports = SyntheticFocusEvent; + +/***/ }), +/* 299 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticUIEvent = __webpack_require__(47); + +var getEventCharCode = __webpack_require__(92); +var getEventKey = __webpack_require__(300); +var getEventModifierState = __webpack_require__(81); + +/** + * @interface KeyboardEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var KeyboardEventInterface = { + key: getEventKey, + location: null, + ctrlKey: null, + shiftKey: null, + altKey: null, + metaKey: null, + repeat: null, + locale: null, + getModifierState: getEventModifierState, + // Legacy Interface + charCode: function (event) { + // `charCode` is the result of a KeyPress event and represents the value of + // the actual printable character. + + // KeyPress is deprecated, but its replacement is not yet final and not + // implemented in any major browser. Only KeyPress has charCode. + if (event.type === 'keypress') { + return getEventCharCode(event); + } + return 0; + }, + keyCode: function (event) { + // `keyCode` is the result of a KeyDown/Up event and represents the value of + // physical keyboard key. + + // The actual meaning of the value depends on the users' keyboard layout + // which cannot be detected. Assuming that it is a US keyboard layout + // provides a surprisingly accurate mapping for US and European users. + // Due to this, it is left to the user to implement at this time. + if (event.type === 'keydown' || event.type === 'keyup') { + return event.keyCode; + } + return 0; + }, + which: function (event) { + // `which` is an alias for either `keyCode` or `charCode` depending on the + // type of the event. + if (event.type === 'keypress') { + return getEventCharCode(event); + } + if (event.type === 'keydown' || event.type === 'keyup') { + return event.keyCode; + } + return 0; + } +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticKeyboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticUIEvent.augmentClass(SyntheticKeyboardEvent, KeyboardEventInterface); + +module.exports = SyntheticKeyboardEvent; + +/***/ }), +/* 300 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var getEventCharCode = __webpack_require__(92); + +/** + * Normalization of deprecated HTML5 `key` values + * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names + */ +var normalizeKey = { + Esc: 'Escape', + Spacebar: ' ', + Left: 'ArrowLeft', + Up: 'ArrowUp', + Right: 'ArrowRight', + Down: 'ArrowDown', + Del: 'Delete', + Win: 'OS', + Menu: 'ContextMenu', + Apps: 'ContextMenu', + Scroll: 'ScrollLock', + MozPrintableKey: 'Unidentified' +}; + +/** + * Translation from legacy `keyCode` to HTML5 `key` + * Only special keys supported, all others depend on keyboard layout or browser + * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names + */ +var translateToKey = { + 8: 'Backspace', + 9: 'Tab', + 12: 'Clear', + 13: 'Enter', + 16: 'Shift', + 17: 'Control', + 18: 'Alt', + 19: 'Pause', + 20: 'CapsLock', + 27: 'Escape', + 32: ' ', + 33: 'PageUp', + 34: 'PageDown', + 35: 'End', + 36: 'Home', + 37: 'ArrowLeft', + 38: 'ArrowUp', + 39: 'ArrowRight', + 40: 'ArrowDown', + 45: 'Insert', + 46: 'Delete', + 112: 'F1', + 113: 'F2', + 114: 'F3', + 115: 'F4', + 116: 'F5', + 117: 'F6', + 118: 'F7', + 119: 'F8', + 120: 'F9', + 121: 'F10', + 122: 'F11', + 123: 'F12', + 144: 'NumLock', + 145: 'ScrollLock', + 224: 'Meta' +}; + +/** + * @param {object} nativeEvent Native browser event. + * @return {string} Normalized `key` property. + */ +function getEventKey(nativeEvent) { + if (nativeEvent.key) { + // Normalize inconsistent values reported by browsers due to + // implementations of a working draft specification. + + // FireFox implements `key` but returns `MozPrintableKey` for all + // printable characters (normalized to `Unidentified`), ignore it. + var key = normalizeKey[nativeEvent.key] || nativeEvent.key; + if (key !== 'Unidentified') { + return key; + } + } + + // Browser does not implement `key`, polyfill as much of it as we can. + if (nativeEvent.type === 'keypress') { + var charCode = getEventCharCode(nativeEvent); + + // The enter-key is technically both printable and non-printable and can + // thus be captured by `keypress`, no other non-printable key should. + return charCode === 13 ? 'Enter' : String.fromCharCode(charCode); + } + if (nativeEvent.type === 'keydown' || nativeEvent.type === 'keyup') { + // While user keyboard layout determines the actual meaning of each + // `keyCode` value, almost all function keys have a universal value. + return translateToKey[nativeEvent.keyCode] || 'Unidentified'; + } + return ''; +} + +module.exports = getEventKey; + +/***/ }), +/* 301 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticMouseEvent = __webpack_require__(59); + +/** + * @interface DragEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var DragEventInterface = { + dataTransfer: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticDragEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticMouseEvent.augmentClass(SyntheticDragEvent, DragEventInterface); + +module.exports = SyntheticDragEvent; + +/***/ }), +/* 302 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticUIEvent = __webpack_require__(47); + +var getEventModifierState = __webpack_require__(81); + +/** + * @interface TouchEvent + * @see http://www.w3.org/TR/touch-events/ + */ +var TouchEventInterface = { + touches: null, + targetTouches: null, + changedTouches: null, + altKey: null, + metaKey: null, + ctrlKey: null, + shiftKey: null, + getModifierState: getEventModifierState +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticTouchEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticUIEvent.augmentClass(SyntheticTouchEvent, TouchEventInterface); + +module.exports = SyntheticTouchEvent; + +/***/ }), +/* 303 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/2009/WD-css3-transitions-20090320/#transition-events- + * @see https://developer.mozilla.org/en-US/docs/Web/API/TransitionEvent + */ +var TransitionEventInterface = { + propertyName: null, + elapsedTime: null, + pseudoElement: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticTransitionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticTransitionEvent, TransitionEventInterface); + +module.exports = SyntheticTransitionEvent; + +/***/ }), +/* 304 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticMouseEvent = __webpack_require__(59); + +/** + * @interface WheelEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var WheelEventInterface = { + deltaX: function (event) { + return 'deltaX' in event ? event.deltaX : // Fallback to `wheelDeltaX` for Webkit and normalize (right is positive). + 'wheelDeltaX' in event ? -event.wheelDeltaX : 0; + }, + deltaY: function (event) { + return 'deltaY' in event ? event.deltaY : // Fallback to `wheelDeltaY` for Webkit and normalize (down is positive). + 'wheelDeltaY' in event ? -event.wheelDeltaY : // Fallback to `wheelDelta` for IE<9 and normalize (down is positive). + 'wheelDelta' in event ? -event.wheelDelta : 0; + }, + deltaZ: null, + + // Browsers without "deltaMode" is reporting in raw wheel delta where one + // notch on the scroll is always +/- 120, roughly equivalent to pixels. + // A good approximation of DOM_DELTA_LINE (1) is 5% of viewport size or + // ~40 pixels, for DOM_DELTA_SCREEN (2) it is 87.5% of viewport size. + deltaMode: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticMouseEvent} + */ +function SyntheticWheelEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticMouseEvent.augmentClass(SyntheticWheelEvent, WheelEventInterface); + +module.exports = SyntheticWheelEvent; + +/***/ }), +/* 305 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var validateDOMNesting = __webpack_require__(91); + +var DOC_NODE_TYPE = 9; + +function ReactDOMContainerInfo(topLevelWrapper, node) { + var info = { + _topLevelWrapper: topLevelWrapper, + _idCounter: 1, + _ownerDocument: node ? node.nodeType === DOC_NODE_TYPE ? node : node.ownerDocument : null, + _node: node, + _tag: node ? node.nodeName.toLowerCase() : null, + _namespaceURI: node ? node.namespaceURI : null + }; + if (process.env.NODE_ENV !== 'production') { + info._ancestorInfo = node ? validateDOMNesting.updatedAncestorInfo(null, info._tag, null) : null; + } + return info; +} + +module.exports = ReactDOMContainerInfo; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 306 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMFeatureFlags = { + useCreateElement: true, + useFiber: false +}; + +module.exports = ReactDOMFeatureFlags; + +/***/ }), +/* 307 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var adler32 = __webpack_require__(308); + +var TAG_END = /\/?>/; +var COMMENT_START = /^<\!\-\-/; + +var ReactMarkupChecksum = { + CHECKSUM_ATTR_NAME: 'data-react-checksum', + + /** + * @param {string} markup Markup string + * @return {string} Markup string with checksum attribute attached + */ + addChecksumToMarkup: function (markup) { + var checksum = adler32(markup); + + // Add checksum (handle both parent tags, comments and self-closing tags) + if (COMMENT_START.test(markup)) { + return markup; + } else { + return markup.replace(TAG_END, ' ' + ReactMarkupChecksum.CHECKSUM_ATTR_NAME + '="' + checksum + '"$&'); + } + }, + + /** + * @param {string} markup to use + * @param {DOMElement} element root React element + * @returns {boolean} whether or not the markup is the same + */ + canReuseMarkup: function (markup, element) { + var existingChecksum = element.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + existingChecksum = existingChecksum && parseInt(existingChecksum, 10); + var markupChecksum = adler32(markup); + return markupChecksum === existingChecksum; + } +}; + +module.exports = ReactMarkupChecksum; + +/***/ }), +/* 308 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var MOD = 65521; + +// adler32 is not cryptographically strong, and is only used to sanity check that +// markup generated on the server matches the markup generated on the client. +// This implementation (a modified version of the SheetJS version) has been optimized +// for our use case, at the expense of conforming to the adler32 specification +// for non-ascii inputs. +function adler32(data) { + var a = 1; + var b = 0; + var i = 0; + var l = data.length; + var m = l & ~0x3; + while (i < m) { + var n = Math.min(i + 4096, m); + for (; i < n; i += 4) { + b += (a += data.charCodeAt(i)) + (a += data.charCodeAt(i + 1)) + (a += data.charCodeAt(i + 2)) + (a += data.charCodeAt(i + 3)); + } + a %= MOD; + b %= MOD; + } + for (; i < l; i++) { + b += a += data.charCodeAt(i); + } + a %= MOD; + b %= MOD; + return a | b << 16; +} + +module.exports = adler32; + +/***/ }), +/* 309 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +module.exports = '15.6.1'; + +/***/ }), +/* 310 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactCurrentOwner = __webpack_require__(22); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstanceMap = __webpack_require__(48); + +var getHostComponentFromComposite = __webpack_require__(150); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +/** + * Returns the DOM node rendered by this element. + * + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.finddomnode + * + * @param {ReactComponent|DOMElement} componentOrElement + * @return {?DOMElement} The root node of this element. + */ +function findDOMNode(componentOrElement) { + if (process.env.NODE_ENV !== 'production') { + var owner = ReactCurrentOwner.current; + if (owner !== null) { + process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing findDOMNode inside its render(). ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; + owner._warnedAboutRefsInRender = true; + } + } + if (componentOrElement == null) { + return null; + } + if (componentOrElement.nodeType === 1) { + return componentOrElement; + } + + var inst = ReactInstanceMap.get(componentOrElement); + if (inst) { + inst = getHostComponentFromComposite(inst); + return inst ? ReactDOMComponentTree.getNodeFromInstance(inst) : null; + } + + if (typeof componentOrElement.render === 'function') { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'findDOMNode was called on an unmounted component.') : _prodInvariant('44') : void 0; + } else { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element appears to be neither ReactComponent nor DOMNode (keys: %s)', Object.keys(componentOrElement)) : _prodInvariant('45', Object.keys(componentOrElement)) : void 0; + } +} + +module.exports = findDOMNode; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 311 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactMount = __webpack_require__(149); + +module.exports = ReactMount.renderSubtreeIntoContainer; + +/***/ }), +/* 312 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var EventPluginRegistry = __webpack_require__(57); +var ReactComponentTreeHook = __webpack_require__(17); + +var warning = __webpack_require__(3); + +if (process.env.NODE_ENV !== 'production') { + var reactProps = { + children: true, + dangerouslySetInnerHTML: true, + key: true, + ref: true, + + autoFocus: true, + defaultValue: true, + valueLink: true, + defaultChecked: true, + checkedLink: true, + innerHTML: true, + suppressContentEditableWarning: true, + onFocusIn: true, + onFocusOut: true + }; + var warnedProperties = {}; + + var validateProperty = function (tagName, name, debugID) { + if (DOMProperty.properties.hasOwnProperty(name) || DOMProperty.isCustomAttribute(name)) { + return true; + } + if (reactProps.hasOwnProperty(name) && reactProps[name] || warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { + return true; + } + if (EventPluginRegistry.registrationNameModules.hasOwnProperty(name)) { + return true; + } + warnedProperties[name] = true; + var lowerCasedName = name.toLowerCase(); + + // data-* attributes should be lowercase; suggest the lowercase version + var standardName = DOMProperty.isCustomAttribute(lowerCasedName) ? lowerCasedName : DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; + + var registrationName = EventPluginRegistry.possibleRegistrationNames.hasOwnProperty(lowerCasedName) ? EventPluginRegistry.possibleRegistrationNames[lowerCasedName] : null; + + if (standardName != null) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown DOM property %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + return true; + } else if (registrationName != null) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown event handler property %s. Did you mean `%s`?%s', name, registrationName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + return true; + } else { + // We were unable to guess which prop the user intended. + // It is likely that the user was just blindly spreading/forwarding props + // Components should be careful to only render valid props/attributes. + // Warning will be invoked in warnUnknownProperties to allow grouping. + return false; + } + }; +} + +var warnUnknownProperties = function (debugID, element) { + var unknownProps = []; + for (var key in element.props) { + var isValid = validateProperty(element.type, key, debugID); + if (!isValid) { + unknownProps.push(key); + } + } + + var unknownPropString = unknownProps.map(function (prop) { + return '`' + prop + '`'; + }).join(', '); + + if (unknownProps.length === 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown prop %s on <%s> tag. Remove this prop from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } else if (unknownProps.length > 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown props %s on <%s> tag. Remove these props from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } +}; + +function handleElement(debugID, element) { + if (element == null || typeof element.type !== 'string') { + return; + } + if (element.type.indexOf('-') >= 0 || element.props.is) { + return; + } + warnUnknownProperties(debugID, element); +} + +var ReactDOMUnknownPropertyHook = { + onBeforeMountComponent: function (debugID, element) { + handleElement(debugID, element); + }, + onBeforeUpdateComponent: function (debugID, element) { + handleElement(debugID, element); + } +}; + +module.exports = ReactDOMUnknownPropertyHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 313 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactComponentTreeHook = __webpack_require__(17); + +var warning = __webpack_require__(3); + +var didWarnValueNull = false; + +function handleElement(debugID, element) { + if (element == null) { + return; + } + if (element.type !== 'input' && element.type !== 'textarea' && element.type !== 'select') { + return; + } + if (element.props != null && element.props.value === null && !didWarnValueNull) { + process.env.NODE_ENV !== 'production' ? warning(false, '`value` prop on `%s` should not be null. ' + 'Consider using the empty string to clear the component or `undefined` ' + 'for uncontrolled components.%s', element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + + didWarnValueNull = true; + } +} + +var ReactDOMNullInputValuePropHook = { + onBeforeMountComponent: function (debugID, element) { + handleElement(debugID, element); + }, + onBeforeUpdateComponent: function (debugID, element) { + handleElement(debugID, element); + } +}; + +module.exports = ReactDOMNullInputValuePropHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 314 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var ReactComponentTreeHook = __webpack_require__(17); + +var warning = __webpack_require__(3); + +var warnedProperties = {}; +var rARIA = new RegExp('^(aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); + +function validateProperty(tagName, name, debugID) { + if (warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { + return true; + } + + if (rARIA.test(name)) { + var lowerCasedName = name.toLowerCase(); + var standardName = DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; + + // If this is an aria-* attribute, but is not listed in the known DOM + // DOM properties, then it is an invalid aria-* attribute. + if (standardName == null) { + warnedProperties[name] = true; + return false; + } + // aria-* attributes should be lowercase; suggest the lowercase version. + if (name !== standardName) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown ARIA attribute %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + warnedProperties[name] = true; + return true; + } + } + + return true; +} + +function warnInvalidARIAProps(debugID, element) { + var invalidProps = []; + + for (var key in element.props) { + var isValid = validateProperty(element.type, key, debugID); + if (!isValid) { + invalidProps.push(key); + } + } + + var unknownPropString = invalidProps.map(function (prop) { + return '`' + prop + '`'; + }).join(', '); + + if (invalidProps.length === 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria prop %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } else if (invalidProps.length > 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria props %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } +} + +function handleElement(debugID, element) { + if (element == null || typeof element.type !== 'string') { + return; + } + if (element.type.indexOf('-') >= 0 || element.props.is) { + return; + } + + warnInvalidARIAProps(debugID, element); +} + +var ReactDOMInvalidARIAHook = { + onBeforeMountComponent: function (debugID, element) { + if (process.env.NODE_ENV !== 'production') { + handleElement(debugID, element); + } + }, + onBeforeUpdateComponent: function (debugID, element) { + if (process.env.NODE_ENV !== 'production') { + handleElement(debugID, element); + } + } +}; + +module.exports = ReactDOMInvalidARIAHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 315 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactstrap = __webpack_require__(93); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var ZNavbar = function (_React$Component) { + _inherits(ZNavbar, _React$Component); + + function ZNavbar(props) { + _classCallCheck(this, ZNavbar); + + var _this = _possibleConstructorReturn(this, (ZNavbar.__proto__ || Object.getPrototypeOf(ZNavbar)).call(this, props)); + + _this.toggleNavbar = _this.toggleNavbar.bind(_this); + _this.state = { + isOpen: false + }; + return _this; + } + + _createClass(ZNavbar, [{ + key: 'toggleNavbar', + value: function toggleNavbar() { + this.setState({ + isOpen: !this.state.isOpen + }); + } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + _reactstrap.Navbar, + { color: 'faded', light: true, toggleable: true }, + _react2.default.createElement(_reactstrap.NavbarToggler, { right: true, onClick: this.toggleNavbar }), + _react2.default.createElement( + _reactstrap.NavbarBrand, + { href: '/' }, + _react2.default.createElement('img', { src: '/favicon.ico', height: 42 }), + '\xA0myzenwallet.io' + ), + _react2.default.createElement( + _reactstrap.Collapse, + { isOpen: this.state.isOpen, navbar: true }, + _react2.default.createElement( + _reactstrap.Nav, + { className: 'ml-auto', navbar: true }, + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: 'http://getzen.cash' }, + 'FREE ZEN' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: '/faq.html' }, + 'FAQ' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: '/guide.html' }, + 'GETTING STARTED' + ) + ) + ) + ) + ); + } + }]); + + return ZNavbar; +}(_react2.default.Component); + +exports.default = ZNavbar; + +/***/ }), +/* 316 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); +var ReactPropTypesSecret = __webpack_require__(75); + +module.exports = function() { + function shim(props, propName, componentName, location, propFullName, secret) { + if (secret === ReactPropTypesSecret) { + // It is still safe when called from React. + return; + } + invariant( + false, + 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + + 'Use PropTypes.checkPropTypes() to call them. ' + + 'Read more at http://fb.me/use-check-prop-types' + ); + }; + shim.isRequired = shim; + function getShim() { + return shim; + }; + // Important! + // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`. + var ReactPropTypes = { + array: shim, + bool: shim, + func: shim, + number: shim, + object: shim, + string: shim, + symbol: shim, + + any: shim, + arrayOf: getShim, + element: shim, + instanceOf: getShim, + node: shim, + objectOf: getShim, + oneOf: getShim, + oneOfType: getShim, + shape: getShim + }; + + ReactPropTypes.checkPropTypes = emptyFunction; + ReactPropTypes.PropTypes = ReactPropTypes; + + return ReactPropTypes; +}; + + +/***/ }), +/* 317 */ +/***/ (function(module, exports) { + +/** + * lodash 3.0.2 (Custom Build) <https://lodash.com/> + * Build: `lodash modern modularize exports="npm" -o ./` + * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license <https://lodash.com/license> + */ + +/** + * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. + * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(1); + * // => false + */ +function isObject(value) { + // Avoid a V8 JIT bug in Chrome 19-20. + // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +module.exports = isObject; + + +/***/ }), +/* 318 */ +/***/ (function(module, exports) { + +/** + * lodash 3.0.8 (Custom Build) <https://lodash.com/> + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation <http://dojofoundation.org/> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license <https://lodash.com/license> + */ + +/** `Object#toString` result references. */ +var funcTag = '[object Function]', + genTag = '[object GeneratorFunction]'; + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** + * Checks if `value` is classified as a `Function` object. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isFunction(_); + * // => true + * + * _.isFunction(/abc/); + * // => false + */ +function isFunction(value) { + // The use of `Object#toString` avoids issues with the `typeof` operator + // in Safari 8 which returns 'object' for typed array constructors, and + // PhantomJS 1.9 which returns 'function' for `NodeList` instances. + var tag = isObject(value) ? objectToString.call(value) : ''; + return tag == funcTag || tag == genTag; +} + +/** + * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. + * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +module.exports = isFunction; + + +/***/ }), +/* 319 */ +/***/ (function(module, exports, __webpack_require__) { + +var require;var require;/*! tether 1.3.4 */ +(function(f){if(true){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Tether = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ +'use strict'; + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } + +var _utils = require('./utils'); + +var _utils2 = _interopRequireDefault(_utils); + +var _TetherBase$Utils = _utils2['default'].Utils; +var getBounds = _TetherBase$Utils.getBounds; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; + +_utils2['default'].modules.push({ + position: function position(_ref) { + var _this = this; + + var top = _ref.top; + var left = _ref.left; + + var _cache = this.cache('element-bounds', function () { + return getBounds(_this.element); + }); + + var height = _cache.height; + var width = _cache.width; + + var targetPos = this.getTargetBounds(); + + var bottom = top + height; + var right = left + width; + + var abutted = []; + if (top <= targetPos.bottom && bottom >= targetPos.top) { + ['left', 'right'].forEach(function (side) { + var targetPosSide = targetPos[side]; + if (targetPosSide === left || targetPosSide === right) { + abutted.push(side); + } + }); + } + + if (left <= targetPos.right && right >= targetPos.left) { + ['top', 'bottom'].forEach(function (side) { + var targetPosSide = targetPos[side]; + if (targetPosSide === top || targetPosSide === bottom) { + abutted.push(side); + } + }); + } + + var allClasses = []; + var addClasses = []; + + var sides = ['left', 'top', 'right', 'bottom']; + allClasses.push(this.getClass('abutted')); + sides.forEach(function (side) { + allClasses.push(_this.getClass('abutted') + '-' + side); + }); + + if (abutted.length) { + addClasses.push(this.getClass('abutted')); + } + + abutted.forEach(function (side) { + addClasses.push(_this.getClass('abutted') + '-' + side); + }); + + defer(function () { + if (!(_this.options.addTargetClasses === false)) { + updateClasses(_this.target, addClasses, allClasses); + } + updateClasses(_this.element, addClasses, allClasses); + }); + + return true; + } +}); + +},{"./utils":5}],2:[function(require,module,exports){ +'use strict'; + +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } + +var _utils = require('./utils'); + +var _utils2 = _interopRequireDefault(_utils); + +var _TetherBase$Utils = _utils2['default'].Utils; +var getBounds = _TetherBase$Utils.getBounds; +var extend = _TetherBase$Utils.extend; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; + +var BOUNDS_FORMAT = ['left', 'top', 'right', 'bottom']; + +function getBoundingRect(tether, to) { + if (to === 'scrollParent') { + to = tether.scrollParents[0]; + } else if (to === 'window') { + to = [pageXOffset, pageYOffset, innerWidth + pageXOffset, innerHeight + pageYOffset]; + } + + if (to === document) { + to = to.documentElement; + } + + if (typeof to.nodeType !== 'undefined') { + (function () { + var node = to; + var size = getBounds(to); + var pos = size; + var style = getComputedStyle(to); + + to = [pos.left, pos.top, size.width + pos.left, size.height + pos.top]; + + // Account any parent Frames scroll offset + if (node.ownerDocument !== document) { + var win = node.ownerDocument.defaultView; + to[0] += win.pageXOffset; + to[1] += win.pageYOffset; + to[2] += win.pageXOffset; + to[3] += win.pageYOffset; + } + + BOUNDS_FORMAT.forEach(function (side, i) { + side = side[0].toUpperCase() + side.substr(1); + if (side === 'Top' || side === 'Left') { + to[i] += parseFloat(style['border' + side + 'Width']); + } else { + to[i] -= parseFloat(style['border' + side + 'Width']); + } + }); + })(); + } + + return to; +} + +_utils2['default'].modules.push({ + position: function position(_ref) { + var _this = this; + + var top = _ref.top; + var left = _ref.left; + var targetAttachment = _ref.targetAttachment; + + if (!this.options.constraints) { + return true; + } + + var _cache = this.cache('element-bounds', function () { + return getBounds(_this.element); + }); + + var height = _cache.height; + var width = _cache.width; + + if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { + var _lastSize = this.lastSize; + + // Handle the item getting hidden as a result of our positioning without glitching + // the classes in and out + width = _lastSize.width; + height = _lastSize.height; + } + + var targetSize = this.cache('target-bounds', function () { + return _this.getTargetBounds(); + }); + + var targetHeight = targetSize.height; + var targetWidth = targetSize.width; + + var allClasses = [this.getClass('pinned'), this.getClass('out-of-bounds')]; + + this.options.constraints.forEach(function (constraint) { + var outOfBoundsClass = constraint.outOfBoundsClass; + var pinnedClass = constraint.pinnedClass; + + if (outOfBoundsClass) { + allClasses.push(outOfBoundsClass); + } + if (pinnedClass) { + allClasses.push(pinnedClass); + } + }); + + allClasses.forEach(function (cls) { + ['left', 'top', 'right', 'bottom'].forEach(function (side) { + allClasses.push(cls + '-' + side); + }); + }); + + var addClasses = []; + + var tAttachment = extend({}, targetAttachment); + var eAttachment = extend({}, this.attachment); + + this.options.constraints.forEach(function (constraint) { + var to = constraint.to; + var attachment = constraint.attachment; + var pin = constraint.pin; + + if (typeof attachment === 'undefined') { + attachment = ''; + } + + var changeAttachX = undefined, + changeAttachY = undefined; + if (attachment.indexOf(' ') >= 0) { + var _attachment$split = attachment.split(' '); + + var _attachment$split2 = _slicedToArray(_attachment$split, 2); + + changeAttachY = _attachment$split2[0]; + changeAttachX = _attachment$split2[1]; + } else { + changeAttachX = changeAttachY = attachment; + } + + var bounds = getBoundingRect(_this, to); + + if (changeAttachY === 'target' || changeAttachY === 'both') { + if (top < bounds[1] && tAttachment.top === 'top') { + top += targetHeight; + tAttachment.top = 'bottom'; + } + + if (top + height > bounds[3] && tAttachment.top === 'bottom') { + top -= targetHeight; + tAttachment.top = 'top'; + } + } + + if (changeAttachY === 'together') { + if (tAttachment.top === 'top') { + if (eAttachment.top === 'bottom' && top < bounds[1]) { + top += targetHeight; + tAttachment.top = 'bottom'; + + top += height; + eAttachment.top = 'top'; + } else if (eAttachment.top === 'top' && top + height > bounds[3] && top - (height - targetHeight) >= bounds[1]) { + top -= height - targetHeight; + tAttachment.top = 'bottom'; + + eAttachment.top = 'bottom'; + } + } + + if (tAttachment.top === 'bottom') { + if (eAttachment.top === 'top' && top + height > bounds[3]) { + top -= targetHeight; + tAttachment.top = 'top'; + + top -= height; + eAttachment.top = 'bottom'; + } else if (eAttachment.top === 'bottom' && top < bounds[1] && top + (height * 2 - targetHeight) <= bounds[3]) { + top += height - targetHeight; + tAttachment.top = 'top'; + + eAttachment.top = 'top'; + } + } + + if (tAttachment.top === 'middle') { + if (top + height > bounds[3] && eAttachment.top === 'top') { + top -= height; + eAttachment.top = 'bottom'; + } else if (top < bounds[1] && eAttachment.top === 'bottom') { + top += height; + eAttachment.top = 'top'; + } + } + } + + if (changeAttachX === 'target' || changeAttachX === 'both') { + if (left < bounds[0] && tAttachment.left === 'left') { + left += targetWidth; + tAttachment.left = 'right'; + } + + if (left + width > bounds[2] && tAttachment.left === 'right') { + left -= targetWidth; + tAttachment.left = 'left'; + } + } + + if (changeAttachX === 'together') { + if (left < bounds[0] && tAttachment.left === 'left') { + if (eAttachment.left === 'right') { + left += targetWidth; + tAttachment.left = 'right'; + + left += width; + eAttachment.left = 'left'; + } else if (eAttachment.left === 'left') { + left += targetWidth; + tAttachment.left = 'right'; + + left -= width; + eAttachment.left = 'right'; + } + } else if (left + width > bounds[2] && tAttachment.left === 'right') { + if (eAttachment.left === 'left') { + left -= targetWidth; + tAttachment.left = 'left'; + + left -= width; + eAttachment.left = 'right'; + } else if (eAttachment.left === 'right') { + left -= targetWidth; + tAttachment.left = 'left'; + + left += width; + eAttachment.left = 'left'; + } + } else if (tAttachment.left === 'center') { + if (left + width > bounds[2] && eAttachment.left === 'left') { + left -= width; + eAttachment.left = 'right'; + } else if (left < bounds[0] && eAttachment.left === 'right') { + left += width; + eAttachment.left = 'left'; + } + } + } + + if (changeAttachY === 'element' || changeAttachY === 'both') { + if (top < bounds[1] && eAttachment.top === 'bottom') { + top += height; + eAttachment.top = 'top'; + } + + if (top + height > bounds[3] && eAttachment.top === 'top') { + top -= height; + eAttachment.top = 'bottom'; + } + } + + if (changeAttachX === 'element' || changeAttachX === 'both') { + if (left < bounds[0]) { + if (eAttachment.left === 'right') { + left += width; + eAttachment.left = 'left'; + } else if (eAttachment.left === 'center') { + left += width / 2; + eAttachment.left = 'left'; + } + } + + if (left + width > bounds[2]) { + if (eAttachment.left === 'left') { + left -= width; + eAttachment.left = 'right'; + } else if (eAttachment.left === 'center') { + left -= width / 2; + eAttachment.left = 'right'; + } + } + } + + if (typeof pin === 'string') { + pin = pin.split(',').map(function (p) { + return p.trim(); + }); + } else if (pin === true) { + pin = ['top', 'left', 'right', 'bottom']; + } + + pin = pin || []; + + var pinned = []; + var oob = []; + + if (top < bounds[1]) { + if (pin.indexOf('top') >= 0) { + top = bounds[1]; + pinned.push('top'); + } else { + oob.push('top'); + } + } + + if (top + height > bounds[3]) { + if (pin.indexOf('bottom') >= 0) { + top = bounds[3] - height; + pinned.push('bottom'); + } else { + oob.push('bottom'); + } + } + + if (left < bounds[0]) { + if (pin.indexOf('left') >= 0) { + left = bounds[0]; + pinned.push('left'); + } else { + oob.push('left'); + } + } + + if (left + width > bounds[2]) { + if (pin.indexOf('right') >= 0) { + left = bounds[2] - width; + pinned.push('right'); + } else { + oob.push('right'); + } + } + + if (pinned.length) { + (function () { + var pinnedClass = undefined; + if (typeof _this.options.pinnedClass !== 'undefined') { + pinnedClass = _this.options.pinnedClass; + } else { + pinnedClass = _this.getClass('pinned'); + } + + addClasses.push(pinnedClass); + pinned.forEach(function (side) { + addClasses.push(pinnedClass + '-' + side); + }); + })(); + } + + if (oob.length) { + (function () { + var oobClass = undefined; + if (typeof _this.options.outOfBoundsClass !== 'undefined') { + oobClass = _this.options.outOfBoundsClass; + } else { + oobClass = _this.getClass('out-of-bounds'); + } + + addClasses.push(oobClass); + oob.forEach(function (side) { + addClasses.push(oobClass + '-' + side); + }); + })(); + } + + if (pinned.indexOf('left') >= 0 || pinned.indexOf('right') >= 0) { + eAttachment.left = tAttachment.left = false; + } + if (pinned.indexOf('top') >= 0 || pinned.indexOf('bottom') >= 0) { + eAttachment.top = tAttachment.top = false; + } + + if (tAttachment.top !== targetAttachment.top || tAttachment.left !== targetAttachment.left || eAttachment.top !== _this.attachment.top || eAttachment.left !== _this.attachment.left) { + _this.updateAttachClasses(eAttachment, tAttachment); + _this.trigger('update', { + attachment: eAttachment, + targetAttachment: tAttachment + }); + } + }); + + defer(function () { + if (!(_this.options.addTargetClasses === false)) { + updateClasses(_this.target, addClasses, allClasses); + } + updateClasses(_this.element, addClasses, allClasses); + }); + + return { top: top, left: left }; + } +}); + +},{"./utils":5}],3:[function(require,module,exports){ +'use strict'; + +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } + +var _utils = require('./utils'); + +var _utils2 = _interopRequireDefault(_utils); + +_utils2['default'].modules.push({ + position: function position(_ref) { + var top = _ref.top; + var left = _ref.left; + + if (!this.options.shift) { + return; + } + + var shift = this.options.shift; + if (typeof this.options.shift === 'function') { + shift = this.options.shift.call(this, { top: top, left: left }); + } + + var shiftTop = undefined, + shiftLeft = undefined; + if (typeof shift === 'string') { + shift = shift.split(' '); + shift[1] = shift[1] || shift[0]; + + var _shift = shift; + + var _shift2 = _slicedToArray(_shift, 2); + + shiftTop = _shift2[0]; + shiftLeft = _shift2[1]; + + shiftTop = parseFloat(shiftTop, 10); + shiftLeft = parseFloat(shiftLeft, 10); + } else { + shiftTop = shift.top; + shiftLeft = shift.left; + } + + top += shiftTop; + left += shiftLeft; + + return { top: top, left: left }; + } +}); + +},{"./utils":5}],4:[function(require,module,exports){ +/* globals performance */ + +'use strict'; + +Object.defineProperty(exports, '__esModule', { + value: true +}); + +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); + +var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); + +var _get = function get(_x6, _x7, _x8) { var _again = true; _function: while (_again) { var object = _x6, property = _x7, receiver = _x8; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x6 = parent; _x7 = property; _x8 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var _utils = require('./utils'); + +var _utils2 = _interopRequireDefault(_utils); + +require('./constraint'); + +require('./abutment'); + +require('./shift'); + +var _TetherBase$Utils = _utils2['default'].Utils; +var getScrollParents = _TetherBase$Utils.getScrollParents; +var getBounds = _TetherBase$Utils.getBounds; +var getOffsetParent = _TetherBase$Utils.getOffsetParent; +var extend = _TetherBase$Utils.extend; +var addClass = _TetherBase$Utils.addClass; +var removeClass = _TetherBase$Utils.removeClass; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; +var flush = _TetherBase$Utils.flush; +var getScrollBarSize = _TetherBase$Utils.getScrollBarSize; +var removeUtilElements = _TetherBase$Utils.removeUtilElements; +var Evented = _TetherBase$Utils.Evented; + +function within(a, b) { + var diff = arguments.length <= 2 || arguments[2] === undefined ? 1 : arguments[2]; + + return a + diff >= b && b >= a - diff; +} + +var transformKey = (function () { + if (typeof document === 'undefined') { + return ''; + } + var el = document.createElement('div'); + + var transforms = ['transform', 'WebkitTransform', 'OTransform', 'MozTransform', 'msTransform']; + for (var i = 0; i < transforms.length; ++i) { + var key = transforms[i]; + if (el.style[key] !== undefined) { + return key; + } + } +})(); + +var tethers = []; + +var position = function position() { + tethers.forEach(function (tether) { + tether.position(false); + }); + flush(); +}; + +function now() { + if (typeof performance !== 'undefined' && typeof performance.now !== 'undefined') { + return performance.now(); + } + return +new Date(); +} + +(function () { + var lastCall = null; + var lastDuration = null; + var pendingTimeout = null; + + var tick = function tick() { + if (typeof lastDuration !== 'undefined' && lastDuration > 16) { + // We voluntarily throttle ourselves if we can't manage 60fps + lastDuration = Math.min(lastDuration - 16, 250); + + // Just in case this is the last event, remember to position just once more + pendingTimeout = setTimeout(tick, 250); + return; + } + + if (typeof lastCall !== 'undefined' && now() - lastCall < 10) { + // Some browsers call events a little too frequently, refuse to run more than is reasonable + return; + } + + if (pendingTimeout != null) { + clearTimeout(pendingTimeout); + pendingTimeout = null; + } + + lastCall = now(); + position(); + lastDuration = now() - lastCall; + }; + + if (typeof window !== 'undefined' && typeof window.addEventListener !== 'undefined') { + ['resize', 'scroll', 'touchmove'].forEach(function (event) { + window.addEventListener(event, tick); + }); + } +})(); + +var MIRROR_LR = { + center: 'center', + left: 'right', + right: 'left' +}; + +var MIRROR_TB = { + middle: 'middle', + top: 'bottom', + bottom: 'top' +}; + +var OFFSET_MAP = { + top: 0, + left: 0, + middle: '50%', + center: '50%', + bottom: '100%', + right: '100%' +}; + +var autoToFixedAttachment = function autoToFixedAttachment(attachment, relativeToAttachment) { + var left = attachment.left; + var top = attachment.top; + + if (left === 'auto') { + left = MIRROR_LR[relativeToAttachment.left]; + } + + if (top === 'auto') { + top = MIRROR_TB[relativeToAttachment.top]; + } + + return { left: left, top: top }; +}; + +var attachmentToOffset = function attachmentToOffset(attachment) { + var left = attachment.left; + var top = attachment.top; + + if (typeof OFFSET_MAP[attachment.left] !== 'undefined') { + left = OFFSET_MAP[attachment.left]; + } + + if (typeof OFFSET_MAP[attachment.top] !== 'undefined') { + top = OFFSET_MAP[attachment.top]; + } + + return { left: left, top: top }; +}; + +function addOffset() { + var out = { top: 0, left: 0 }; + + for (var _len = arguments.length, offsets = Array(_len), _key = 0; _key < _len; _key++) { + offsets[_key] = arguments[_key]; + } + + offsets.forEach(function (_ref) { + var top = _ref.top; + var left = _ref.left; + + if (typeof top === 'string') { + top = parseFloat(top, 10); + } + if (typeof left === 'string') { + left = parseFloat(left, 10); + } + + out.top += top; + out.left += left; + }); + + return out; +} + +function offsetToPx(offset, size) { + if (typeof offset.left === 'string' && offset.left.indexOf('%') !== -1) { + offset.left = parseFloat(offset.left, 10) / 100 * size.width; + } + if (typeof offset.top === 'string' && offset.top.indexOf('%') !== -1) { + offset.top = parseFloat(offset.top, 10) / 100 * size.height; + } + + return offset; +} + +var parseOffset = function parseOffset(value) { + var _value$split = value.split(' '); + + var _value$split2 = _slicedToArray(_value$split, 2); + + var top = _value$split2[0]; + var left = _value$split2[1]; + + return { top: top, left: left }; +}; +var parseAttachment = parseOffset; + +var TetherClass = (function (_Evented) { + _inherits(TetherClass, _Evented); + + function TetherClass(options) { + var _this = this; + + _classCallCheck(this, TetherClass); + + _get(Object.getPrototypeOf(TetherClass.prototype), 'constructor', this).call(this); + this.position = this.position.bind(this); + + tethers.push(this); + + this.history = []; + + this.setOptions(options, false); + + _utils2['default'].modules.forEach(function (module) { + if (typeof module.initialize !== 'undefined') { + module.initialize.call(_this); + } + }); + + this.position(); + } + + _createClass(TetherClass, [{ + key: 'getClass', + value: function getClass() { + var key = arguments.length <= 0 || arguments[0] === undefined ? '' : arguments[0]; + var classes = this.options.classes; + + if (typeof classes !== 'undefined' && classes[key]) { + return this.options.classes[key]; + } else if (this.options.classPrefix) { + return this.options.classPrefix + '-' + key; + } else { + return key; + } + } + }, { + key: 'setOptions', + value: function setOptions(options) { + var _this2 = this; + + var pos = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1]; + + var defaults = { + offset: '0 0', + targetOffset: '0 0', + targetAttachment: 'auto auto', + classPrefix: 'tether' + }; + + this.options = extend(defaults, options); + + var _options = this.options; + var element = _options.element; + var target = _options.target; + var targetModifier = _options.targetModifier; + + this.element = element; + this.target = target; + this.targetModifier = targetModifier; + + if (this.target === 'viewport') { + this.target = document.body; + this.targetModifier = 'visible'; + } else if (this.target === 'scroll-handle') { + this.target = document.body; + this.targetModifier = 'scroll-handle'; + } + + ['element', 'target'].forEach(function (key) { + if (typeof _this2[key] === 'undefined') { + throw new Error('Tether Error: Both element and target must be defined'); + } + + if (typeof _this2[key].jquery !== 'undefined') { + _this2[key] = _this2[key][0]; + } else if (typeof _this2[key] === 'string') { + _this2[key] = document.querySelector(_this2[key]); + } + }); + + addClass(this.element, this.getClass('element')); + if (!(this.options.addTargetClasses === false)) { + addClass(this.target, this.getClass('target')); + } + + if (!this.options.attachment) { + throw new Error('Tether Error: You must provide an attachment'); + } + + this.targetAttachment = parseAttachment(this.options.targetAttachment); + this.attachment = parseAttachment(this.options.attachment); + this.offset = parseOffset(this.options.offset); + this.targetOffset = parseOffset(this.options.targetOffset); + + if (typeof this.scrollParents !== 'undefined') { + this.disable(); + } + + if (this.targetModifier === 'scroll-handle') { + this.scrollParents = [this.target]; + } else { + this.scrollParents = getScrollParents(this.target); + } + + if (!(this.options.enabled === false)) { + this.enable(pos); + } + } + }, { + key: 'getTargetBounds', + value: function getTargetBounds() { + if (typeof this.targetModifier !== 'undefined') { + if (this.targetModifier === 'visible') { + if (this.target === document.body) { + return { top: pageYOffset, left: pageXOffset, height: innerHeight, width: innerWidth }; + } else { + var bounds = getBounds(this.target); + + var out = { + height: bounds.height, + width: bounds.width, + top: bounds.top, + left: bounds.left + }; + + out.height = Math.min(out.height, bounds.height - (pageYOffset - bounds.top)); + out.height = Math.min(out.height, bounds.height - (bounds.top + bounds.height - (pageYOffset + innerHeight))); + out.height = Math.min(innerHeight, out.height); + out.height -= 2; + + out.width = Math.min(out.width, bounds.width - (pageXOffset - bounds.left)); + out.width = Math.min(out.width, bounds.width - (bounds.left + bounds.width - (pageXOffset + innerWidth))); + out.width = Math.min(innerWidth, out.width); + out.width -= 2; + + if (out.top < pageYOffset) { + out.top = pageYOffset; + } + if (out.left < pageXOffset) { + out.left = pageXOffset; + } + + return out; + } + } else if (this.targetModifier === 'scroll-handle') { + var bounds = undefined; + var target = this.target; + if (target === document.body) { + target = document.documentElement; + + bounds = { + left: pageXOffset, + top: pageYOffset, + height: innerHeight, + width: innerWidth + }; + } else { + bounds = getBounds(target); + } + + var style = getComputedStyle(target); + + var hasBottomScroll = target.scrollWidth > target.clientWidth || [style.overflow, style.overflowX].indexOf('scroll') >= 0 || this.target !== document.body; + + var scrollBottom = 0; + if (hasBottomScroll) { + scrollBottom = 15; + } + + var height = bounds.height - parseFloat(style.borderTopWidth) - parseFloat(style.borderBottomWidth) - scrollBottom; + + var out = { + width: 15, + height: height * 0.975 * (height / target.scrollHeight), + left: bounds.left + bounds.width - parseFloat(style.borderLeftWidth) - 15 + }; + + var fitAdj = 0; + if (height < 408 && this.target === document.body) { + fitAdj = -0.00011 * Math.pow(height, 2) - 0.00727 * height + 22.58; + } + + if (this.target !== document.body) { + out.height = Math.max(out.height, 24); + } + + var scrollPercentage = this.target.scrollTop / (target.scrollHeight - height); + out.top = scrollPercentage * (height - out.height - fitAdj) + bounds.top + parseFloat(style.borderTopWidth); + + if (this.target === document.body) { + out.height = Math.max(out.height, 24); + } + + return out; + } + } else { + return getBounds(this.target); + } + } + }, { + key: 'clearCache', + value: function clearCache() { + this._cache = {}; + } + }, { + key: 'cache', + value: function cache(k, getter) { + // More than one module will often need the same DOM info, so + // we keep a cache which is cleared on each position call + if (typeof this._cache === 'undefined') { + this._cache = {}; + } + + if (typeof this._cache[k] === 'undefined') { + this._cache[k] = getter.call(this); + } + + return this._cache[k]; + } + }, { + key: 'enable', + value: function enable() { + var _this3 = this; + + var pos = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; + + if (!(this.options.addTargetClasses === false)) { + addClass(this.target, this.getClass('enabled')); + } + addClass(this.element, this.getClass('enabled')); + this.enabled = true; + + this.scrollParents.forEach(function (parent) { + if (parent !== _this3.target.ownerDocument) { + parent.addEventListener('scroll', _this3.position); + } + }); + + if (pos) { + this.position(); + } + } + }, { + key: 'disable', + value: function disable() { + var _this4 = this; + + removeClass(this.target, this.getClass('enabled')); + removeClass(this.element, this.getClass('enabled')); + this.enabled = false; + + if (typeof this.scrollParents !== 'undefined') { + this.scrollParents.forEach(function (parent) { + parent.removeEventListener('scroll', _this4.position); + }); + } + } + }, { + key: 'destroy', + value: function destroy() { + var _this5 = this; + + this.disable(); + + tethers.forEach(function (tether, i) { + if (tether === _this5) { + tethers.splice(i, 1); + } + }); + + // Remove any elements we were using for convenience from the DOM + if (tethers.length === 0) { + removeUtilElements(); + } + } + }, { + key: 'updateAttachClasses', + value: function updateAttachClasses(elementAttach, targetAttach) { + var _this6 = this; + + elementAttach = elementAttach || this.attachment; + targetAttach = targetAttach || this.targetAttachment; + var sides = ['left', 'top', 'bottom', 'right', 'middle', 'center']; + + if (typeof this._addAttachClasses !== 'undefined' && this._addAttachClasses.length) { + // updateAttachClasses can be called more than once in a position call, so + // we need to clean up after ourselves such that when the last defer gets + // ran it doesn't add any extra classes from previous calls. + this._addAttachClasses.splice(0, this._addAttachClasses.length); + } + + if (typeof this._addAttachClasses === 'undefined') { + this._addAttachClasses = []; + } + var add = this._addAttachClasses; + + if (elementAttach.top) { + add.push(this.getClass('element-attached') + '-' + elementAttach.top); + } + if (elementAttach.left) { + add.push(this.getClass('element-attached') + '-' + elementAttach.left); + } + if (targetAttach.top) { + add.push(this.getClass('target-attached') + '-' + targetAttach.top); + } + if (targetAttach.left) { + add.push(this.getClass('target-attached') + '-' + targetAttach.left); + } + + var all = []; + sides.forEach(function (side) { + all.push(_this6.getClass('element-attached') + '-' + side); + all.push(_this6.getClass('target-attached') + '-' + side); + }); + + defer(function () { + if (!(typeof _this6._addAttachClasses !== 'undefined')) { + return; + } + + updateClasses(_this6.element, _this6._addAttachClasses, all); + if (!(_this6.options.addTargetClasses === false)) { + updateClasses(_this6.target, _this6._addAttachClasses, all); + } + + delete _this6._addAttachClasses; + }); + } + }, { + key: 'position', + value: function position() { + var _this7 = this; + + var flushChanges = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; + + // flushChanges commits the changes immediately, leave true unless you are positioning multiple + // tethers (in which case call Tether.Utils.flush yourself when you're done) + + if (!this.enabled) { + return; + } + + this.clearCache(); + + // Turn 'auto' attachments into the appropriate corner or edge + var targetAttachment = autoToFixedAttachment(this.targetAttachment, this.attachment); + + this.updateAttachClasses(this.attachment, targetAttachment); + + var elementPos = this.cache('element-bounds', function () { + return getBounds(_this7.element); + }); + + var width = elementPos.width; + var height = elementPos.height; + + if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { + var _lastSize = this.lastSize; + + // We cache the height and width to make it possible to position elements that are + // getting hidden. + width = _lastSize.width; + height = _lastSize.height; + } else { + this.lastSize = { width: width, height: height }; + } + + var targetPos = this.cache('target-bounds', function () { + return _this7.getTargetBounds(); + }); + var targetSize = targetPos; + + // Get an actual px offset from the attachment + var offset = offsetToPx(attachmentToOffset(this.attachment), { width: width, height: height }); + var targetOffset = offsetToPx(attachmentToOffset(targetAttachment), targetSize); + + var manualOffset = offsetToPx(this.offset, { width: width, height: height }); + var manualTargetOffset = offsetToPx(this.targetOffset, targetSize); + + // Add the manually provided offset + offset = addOffset(offset, manualOffset); + targetOffset = addOffset(targetOffset, manualTargetOffset); + + // It's now our goal to make (element position + offset) == (target position + target offset) + var left = targetPos.left + targetOffset.left - offset.left; + var top = targetPos.top + targetOffset.top - offset.top; + + for (var i = 0; i < _utils2['default'].modules.length; ++i) { + var _module2 = _utils2['default'].modules[i]; + var ret = _module2.position.call(this, { + left: left, + top: top, + targetAttachment: targetAttachment, + targetPos: targetPos, + elementPos: elementPos, + offset: offset, + targetOffset: targetOffset, + manualOffset: manualOffset, + manualTargetOffset: manualTargetOffset, + scrollbarSize: scrollbarSize, + attachment: this.attachment + }); + + if (ret === false) { + return false; + } else if (typeof ret === 'undefined' || typeof ret !== 'object') { + continue; + } else { + top = ret.top; + left = ret.left; + } + } + + // We describe the position three different ways to give the optimizer + // a chance to decide the best possible way to position the element + // with the fewest repaints. + var next = { + // It's position relative to the page (absolute positioning when + // the element is a child of the body) + page: { + top: top, + left: left + }, + + // It's position relative to the viewport (fixed positioning) + viewport: { + top: top - pageYOffset, + bottom: pageYOffset - top - height + innerHeight, + left: left - pageXOffset, + right: pageXOffset - left - width + innerWidth + } + }; + + var doc = this.target.ownerDocument; + var win = doc.defaultView; + + var scrollbarSize = undefined; + if (doc.body.scrollWidth > win.innerWidth) { + scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); + next.viewport.bottom -= scrollbarSize.height; + } + + if (doc.body.scrollHeight > win.innerHeight) { + scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); + next.viewport.right -= scrollbarSize.width; + } + + if (['', 'static'].indexOf(doc.body.style.position) === -1 || ['', 'static'].indexOf(doc.body.parentElement.style.position) === -1) { + // Absolute positioning in the body will be relative to the page, not the 'initial containing block' + next.page.bottom = doc.body.scrollHeight - top - height; + next.page.right = doc.body.scrollWidth - left - width; + } + + if (typeof this.options.optimizations !== 'undefined' && this.options.optimizations.moveElement !== false && !(typeof this.targetModifier !== 'undefined')) { + (function () { + var offsetParent = _this7.cache('target-offsetparent', function () { + return getOffsetParent(_this7.target); + }); + var offsetPosition = _this7.cache('target-offsetparent-bounds', function () { + return getBounds(offsetParent); + }); + var offsetParentStyle = getComputedStyle(offsetParent); + var offsetParentSize = offsetPosition; + + var offsetBorder = {}; + ['Top', 'Left', 'Bottom', 'Right'].forEach(function (side) { + offsetBorder[side.toLowerCase()] = parseFloat(offsetParentStyle['border' + side + 'Width']); + }); + + offsetPosition.right = doc.body.scrollWidth - offsetPosition.left - offsetParentSize.width + offsetBorder.right; + offsetPosition.bottom = doc.body.scrollHeight - offsetPosition.top - offsetParentSize.height + offsetBorder.bottom; + + if (next.page.top >= offsetPosition.top + offsetBorder.top && next.page.bottom >= offsetPosition.bottom) { + if (next.page.left >= offsetPosition.left + offsetBorder.left && next.page.right >= offsetPosition.right) { + // We're within the visible part of the target's scroll parent + var scrollTop = offsetParent.scrollTop; + var scrollLeft = offsetParent.scrollLeft; + + // It's position relative to the target's offset parent (absolute positioning when + // the element is moved to be a child of the target's offset parent). + next.offset = { + top: next.page.top - offsetPosition.top + scrollTop - offsetBorder.top, + left: next.page.left - offsetPosition.left + scrollLeft - offsetBorder.left + }; + } + } + })(); + } + + // We could also travel up the DOM and try each containing context, rather than only + // looking at the body, but we're gonna get diminishing returns. + + this.move(next); + + this.history.unshift(next); + + if (this.history.length > 3) { + this.history.pop(); + } + + if (flushChanges) { + flush(); + } + + return true; + } + + // THE ISSUE + }, { + key: 'move', + value: function move(pos) { + var _this8 = this; + + if (!(typeof this.element.parentNode !== 'undefined')) { + return; + } + + var same = {}; + + for (var type in pos) { + same[type] = {}; + + for (var key in pos[type]) { + var found = false; + + for (var i = 0; i < this.history.length; ++i) { + var point = this.history[i]; + if (typeof point[type] !== 'undefined' && !within(point[type][key], pos[type][key])) { + found = true; + break; + } + } + + if (!found) { + same[type][key] = true; + } + } + } + + var css = { top: '', left: '', right: '', bottom: '' }; + + var transcribe = function transcribe(_same, _pos) { + var hasOptimizations = typeof _this8.options.optimizations !== 'undefined'; + var gpu = hasOptimizations ? _this8.options.optimizations.gpu : null; + if (gpu !== false) { + var yPos = undefined, + xPos = undefined; + if (_same.top) { + css.top = 0; + yPos = _pos.top; + } else { + css.bottom = 0; + yPos = -_pos.bottom; + } + + if (_same.left) { + css.left = 0; + xPos = _pos.left; + } else { + css.right = 0; + xPos = -_pos.right; + } + + css[transformKey] = 'translateX(' + Math.round(xPos) + 'px) translateY(' + Math.round(yPos) + 'px)'; + + if (transformKey !== 'msTransform') { + // The Z transform will keep this in the GPU (faster, and prevents artifacts), + // but IE9 doesn't support 3d transforms and will choke. + css[transformKey] += " translateZ(0)"; + } + } else { + if (_same.top) { + css.top = _pos.top + 'px'; + } else { + css.bottom = _pos.bottom + 'px'; + } + + if (_same.left) { + css.left = _pos.left + 'px'; + } else { + css.right = _pos.right + 'px'; + } + } + }; + + var moved = false; + if ((same.page.top || same.page.bottom) && (same.page.left || same.page.right)) { + css.position = 'absolute'; + transcribe(same.page, pos.page); + } else if ((same.viewport.top || same.viewport.bottom) && (same.viewport.left || same.viewport.right)) { + css.position = 'fixed'; + transcribe(same.viewport, pos.viewport); + } else if (typeof same.offset !== 'undefined' && same.offset.top && same.offset.left) { + (function () { + css.position = 'absolute'; + var offsetParent = _this8.cache('target-offsetparent', function () { + return getOffsetParent(_this8.target); + }); + + if (getOffsetParent(_this8.element) !== offsetParent) { + defer(function () { + _this8.element.parentNode.removeChild(_this8.element); + offsetParent.appendChild(_this8.element); + }); + } + + transcribe(same.offset, pos.offset); + moved = true; + })(); + } else { + css.position = 'absolute'; + transcribe({ top: true, left: true }, pos.page); + } + + if (!moved) { + var offsetParentIsBody = true; + var currentNode = this.element.parentNode; + while (currentNode && currentNode.nodeType === 1 && currentNode.tagName !== 'BODY') { + if (getComputedStyle(currentNode).position !== 'static') { + offsetParentIsBody = false; + break; + } + + currentNode = currentNode.parentNode; + } + + if (!offsetParentIsBody) { + this.element.parentNode.removeChild(this.element); + this.element.ownerDocument.body.appendChild(this.element); + } + } + + // Any css change will trigger a repaint, so let's avoid one if nothing changed + var writeCSS = {}; + var write = false; + for (var key in css) { + var val = css[key]; + var elVal = this.element.style[key]; + + if (elVal !== val) { + write = true; + writeCSS[key] = val; + } + } + + if (write) { + defer(function () { + extend(_this8.element.style, writeCSS); + _this8.trigger('repositioned'); + }); + } + } + }]); + + return TetherClass; +})(Evented); + +TetherClass.modules = []; + +_utils2['default'].position = position; + +var Tether = extend(TetherClass, _utils2['default']); + +exports['default'] = Tether; +module.exports = exports['default']; + +},{"./abutment":1,"./constraint":2,"./shift":3,"./utils":5}],5:[function(require,module,exports){ +'use strict'; + +Object.defineProperty(exports, '__esModule', { + value: true +}); + +var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + +var TetherBase = { modules: [] }; + +var zeroElement = null; + +// Same as native getBoundingClientRect, except it takes into account parent <frame> offsets +// if the element lies within a nested document (<frame> or <iframe>-like). +function getActualBoundingClientRect(node) { + var boundingRect = node.getBoundingClientRect(); + + // The original object returned by getBoundingClientRect is immutable, so we clone it + // We can't use extend because the properties are not considered part of the object by hasOwnProperty in IE9 + var rect = {}; + for (var k in boundingRect) { + rect[k] = boundingRect[k]; + } + + if (node.ownerDocument !== document) { + var _frameElement = node.ownerDocument.defaultView.frameElement; + if (_frameElement) { + var frameRect = getActualBoundingClientRect(_frameElement); + rect.top += frameRect.top; + rect.bottom += frameRect.top; + rect.left += frameRect.left; + rect.right += frameRect.left; + } + } + + return rect; +} + +function getScrollParents(el) { + // In firefox if the el is inside an iframe with display: none; window.getComputedStyle() will return null; + // https://bugzilla.mozilla.org/show_bug.cgi?id=548397 + var computedStyle = getComputedStyle(el) || {}; + var position = computedStyle.position; + var parents = []; + + if (position === 'fixed') { + return [el]; + } + + var parent = el; + while ((parent = parent.parentNode) && parent && parent.nodeType === 1) { + var style = undefined; + try { + style = getComputedStyle(parent); + } catch (err) {} + + if (typeof style === 'undefined' || style === null) { + parents.push(parent); + return parents; + } + + var _style = style; + var overflow = _style.overflow; + var overflowX = _style.overflowX; + var overflowY = _style.overflowY; + + if (/(auto|scroll)/.test(overflow + overflowY + overflowX)) { + if (position !== 'absolute' || ['relative', 'absolute', 'fixed'].indexOf(style.position) >= 0) { + parents.push(parent); + } + } + } + + parents.push(el.ownerDocument.body); + + // If the node is within a frame, account for the parent window scroll + if (el.ownerDocument !== document) { + parents.push(el.ownerDocument.defaultView); + } + + return parents; +} + +var uniqueId = (function () { + var id = 0; + return function () { + return ++id; + }; +})(); + +var zeroPosCache = {}; +var getOrigin = function getOrigin() { + // getBoundingClientRect is unfortunately too accurate. It introduces a pixel or two of + // jitter as the user scrolls that messes with our ability to detect if two positions + // are equivilant or not. We place an element at the top left of the page that will + // get the same jitter, so we can cancel the two out. + var node = zeroElement; + if (!node) { + node = document.createElement('div'); + node.setAttribute('data-tether-id', uniqueId()); + extend(node.style, { + top: 0, + left: 0, + position: 'absolute' + }); + + document.body.appendChild(node); + + zeroElement = node; + } + + var id = node.getAttribute('data-tether-id'); + if (typeof zeroPosCache[id] === 'undefined') { + zeroPosCache[id] = getActualBoundingClientRect(node); + + // Clear the cache when this position call is done + defer(function () { + delete zeroPosCache[id]; + }); + } + + return zeroPosCache[id]; +}; + +function removeUtilElements() { + if (zeroElement) { + document.body.removeChild(zeroElement); + } + zeroElement = null; +}; + +function getBounds(el) { + var doc = undefined; + if (el === document) { + doc = document; + el = document.documentElement; + } else { + doc = el.ownerDocument; + } + + var docEl = doc.documentElement; + + var box = getActualBoundingClientRect(el); + + var origin = getOrigin(); + + box.top -= origin.top; + box.left -= origin.left; + + if (typeof box.width === 'undefined') { + box.width = document.body.scrollWidth - box.left - box.right; + } + if (typeof box.height === 'undefined') { + box.height = document.body.scrollHeight - box.top - box.bottom; + } + + box.top = box.top - docEl.clientTop; + box.left = box.left - docEl.clientLeft; + box.right = doc.body.clientWidth - box.width - box.left; + box.bottom = doc.body.clientHeight - box.height - box.top; + + return box; +} + +function getOffsetParent(el) { + return el.offsetParent || document.documentElement; +} + +function getScrollBarSize() { + var inner = document.createElement('div'); + inner.style.width = '100%'; + inner.style.height = '200px'; + + var outer = document.createElement('div'); + extend(outer.style, { + position: 'absolute', + top: 0, + left: 0, + pointerEvents: 'none', + visibility: 'hidden', + width: '200px', + height: '150px', + overflow: 'hidden' + }); + + outer.appendChild(inner); + + document.body.appendChild(outer); + + var widthContained = inner.offsetWidth; + outer.style.overflow = 'scroll'; + var widthScroll = inner.offsetWidth; + + if (widthContained === widthScroll) { + widthScroll = outer.clientWidth; + } + + document.body.removeChild(outer); + + var width = widthContained - widthScroll; + + return { width: width, height: width }; +} + +function extend() { + var out = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0]; + + var args = []; + + Array.prototype.push.apply(args, arguments); + + args.slice(1).forEach(function (obj) { + if (obj) { + for (var key in obj) { + if (({}).hasOwnProperty.call(obj, key)) { + out[key] = obj[key]; + } + } + } + }); + + return out; +} + +function removeClass(el, name) { + if (typeof el.classList !== 'undefined') { + name.split(' ').forEach(function (cls) { + if (cls.trim()) { + el.classList.remove(cls); + } + }); + } else { + var regex = new RegExp('(^| )' + name.split(' ').join('|') + '( |$)', 'gi'); + var className = getClassName(el).replace(regex, ' '); + setClassName(el, className); + } +} + +function addClass(el, name) { + if (typeof el.classList !== 'undefined') { + name.split(' ').forEach(function (cls) { + if (cls.trim()) { + el.classList.add(cls); + } + }); + } else { + removeClass(el, name); + var cls = getClassName(el) + (' ' + name); + setClassName(el, cls); + } +} + +function hasClass(el, name) { + if (typeof el.classList !== 'undefined') { + return el.classList.contains(name); + } + var className = getClassName(el); + return new RegExp('(^| )' + name + '( |$)', 'gi').test(className); +} + +function getClassName(el) { + // Can't use just SVGAnimatedString here since nodes within a Frame in IE have + // completely separately SVGAnimatedString base classes + if (el.className instanceof el.ownerDocument.defaultView.SVGAnimatedString) { + return el.className.baseVal; + } + return el.className; +} + +function setClassName(el, className) { + el.setAttribute('class', className); +} + +function updateClasses(el, add, all) { + // Of the set of 'all' classes, we need the 'add' classes, and only the + // 'add' classes to be set. + all.forEach(function (cls) { + if (add.indexOf(cls) === -1 && hasClass(el, cls)) { + removeClass(el, cls); + } + }); + + add.forEach(function (cls) { + if (!hasClass(el, cls)) { + addClass(el, cls); + } + }); +} + +var deferred = []; + +var defer = function defer(fn) { + deferred.push(fn); +}; + +var flush = function flush() { + var fn = undefined; + while (fn = deferred.pop()) { + fn(); + } +}; + +var Evented = (function () { + function Evented() { + _classCallCheck(this, Evented); + } + + _createClass(Evented, [{ + key: 'on', + value: function on(event, handler, ctx) { + var once = arguments.length <= 3 || arguments[3] === undefined ? false : arguments[3]; + + if (typeof this.bindings === 'undefined') { + this.bindings = {}; + } + if (typeof this.bindings[event] === 'undefined') { + this.bindings[event] = []; + } + this.bindings[event].push({ handler: handler, ctx: ctx, once: once }); + } + }, { + key: 'once', + value: function once(event, handler, ctx) { + this.on(event, handler, ctx, true); + } + }, { + key: 'off', + value: function off(event, handler) { + if (typeof this.bindings === 'undefined' || typeof this.bindings[event] === 'undefined') { + return; + } + + if (typeof handler === 'undefined') { + delete this.bindings[event]; + } else { + var i = 0; + while (i < this.bindings[event].length) { + if (this.bindings[event][i].handler === handler) { + this.bindings[event].splice(i, 1); + } else { + ++i; + } + } + } + } + }, { + key: 'trigger', + value: function trigger(event) { + if (typeof this.bindings !== 'undefined' && this.bindings[event]) { + var i = 0; + + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } + + while (i < this.bindings[event].length) { + var _bindings$event$i = this.bindings[event][i]; + var handler = _bindings$event$i.handler; + var ctx = _bindings$event$i.ctx; + var once = _bindings$event$i.once; + + var context = ctx; + if (typeof context === 'undefined') { + context = this; + } + + handler.apply(context, args); + + if (once) { + this.bindings[event].splice(i, 1); + } else { + ++i; + } + } + } + } + }]); + + return Evented; +})(); + +TetherBase.Utils = { + getActualBoundingClientRect: getActualBoundingClientRect, + getScrollParents: getScrollParents, + getBounds: getBounds, + getOffsetParent: getOffsetParent, + extend: extend, + addClass: addClass, + removeClass: removeClass, + hasClass: hasClass, + updateClasses: updateClasses, + defer: defer, + flush: flush, + uniqueId: uniqueId, + Evented: Evented, + getScrollBarSize: getScrollBarSize, + removeUtilElements: removeUtilElements +}; + +exports['default'] = TetherBase; +module.exports = exports['default']; + +},{}]},{},[4])(4) +}); + +/***/ }), +/* 320 */ +/***/ (function(module, exports) { + +/** + * lodash (Custom Build) <https://lodash.com/> + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors <https://jquery.org/> + * Released under MIT license <https://lodash.com/license> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ + +/** Used as references for various `Number` constants. */ +var NAN = 0 / 0; + +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; + +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; + +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; + +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; + +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; + +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); +} + +module.exports = toNumber; + + +/***/ }), +/* 321 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var _CSSTransitionGroup = __webpack_require__(322); + +var _CSSTransitionGroup2 = _interopRequireDefault(_CSSTransitionGroup); + +var _TransitionGroup = __webpack_require__(151); + +var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +module.exports = { + TransitionGroup: _TransitionGroup2.default, + CSSTransitionGroup: _CSSTransitionGroup2.default +}; + +/***/ }), +/* 322 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +exports.__esModule = true; + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _propTypes = __webpack_require__(40); + +var _propTypes2 = _interopRequireDefault(_propTypes); + +var _TransitionGroup = __webpack_require__(151); + +var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); + +var _CSSTransitionGroupChild = __webpack_require__(326); + +var _CSSTransitionGroupChild2 = _interopRequireDefault(_CSSTransitionGroupChild); + +var _PropTypes = __webpack_require__(153); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var propTypes = { + transitionName: _PropTypes.nameShape.isRequired, + + transitionAppear: _propTypes2.default.bool, + transitionEnter: _propTypes2.default.bool, + transitionLeave: _propTypes2.default.bool, + transitionAppearTimeout: (0, _PropTypes.transitionTimeout)('Appear'), + transitionEnterTimeout: (0, _PropTypes.transitionTimeout)('Enter'), + transitionLeaveTimeout: (0, _PropTypes.transitionTimeout)('Leave') +}; + +var defaultProps = { + transitionAppear: false, + transitionEnter: true, + transitionLeave: true +}; + +var CSSTransitionGroup = function (_React$Component) { + _inherits(CSSTransitionGroup, _React$Component); + + function CSSTransitionGroup() { + var _temp, _this, _ret; + + _classCallCheck(this, CSSTransitionGroup); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this._wrapChild = function (child) { + return _react2.default.createElement(_CSSTransitionGroupChild2.default, { + name: _this.props.transitionName, + appear: _this.props.transitionAppear, + enter: _this.props.transitionEnter, + leave: _this.props.transitionLeave, + appearTimeout: _this.props.transitionAppearTimeout, + enterTimeout: _this.props.transitionEnterTimeout, + leaveTimeout: _this.props.transitionLeaveTimeout + }, child); + }, _temp), _possibleConstructorReturn(_this, _ret); + } + + // We need to provide this childFactory so that + // ReactCSSTransitionGroupChild can receive updates to name, enter, and + // leave while it is leaving. + + + CSSTransitionGroup.prototype.render = function render() { + return _react2.default.createElement(_TransitionGroup2.default, _extends({}, this.props, { childFactory: this._wrapChild })); + }; + + return CSSTransitionGroup; +}(_react2.default.Component); + +CSSTransitionGroup.displayName = 'CSSTransitionGroup'; + + +CSSTransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; +CSSTransitionGroup.defaultProps = defaultProps; + +exports.default = CSSTransitionGroup; +module.exports = exports['default']; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 323 */ +/***/ (function(module, exports) { + + +module.exports = function chain(){ + var len = arguments.length + var args = []; + + for (var i = 0; i < len; i++) + args[i] = arguments[i] + + args = args.filter(function(fn){ return fn != null }) + + if (args.length === 0) return undefined + if (args.length === 1) return args[0] + + return args.reduce(function(current, next){ + return function chainedFunction() { + current.apply(this, arguments); + next.apply(this, arguments); + }; + }) +} + + +/***/ }), +/* 324 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +/** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ + +var warning = function() {}; + +if (process.env.NODE_ENV !== 'production') { + warning = function(condition, format, args) { + var len = arguments.length; + args = new Array(len > 2 ? len - 2 : 0); + for (var key = 2; key < len; key++) { + args[key - 2] = arguments[key]; + } + if (format === undefined) { + throw new Error( + '`warning(condition, format, ...args)` requires a warning ' + + 'message argument' + ); + } + + if (format.length < 10 || (/^[s\W]*$/).test(format)) { + throw new Error( + 'The warning format should be able to uniquely identify this ' + + 'warning. Please, use a more descriptive format than: ' + format + ); + } + + if (!condition) { + var argIndex = 0; + var message = 'Warning: ' + + format.replace(/%s/g, function() { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.error(message); + } + try { + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch(x) {} + } + }; +} + +module.exports = warning; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 325 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.__esModule = true; +exports.getChildMapping = getChildMapping; +exports.mergeChildMappings = mergeChildMappings; + +var _react = __webpack_require__(6); + +/** + * Given `this.props.children`, return an object mapping key to child. + * + * @param {*} children `this.props.children` + * @return {object} Mapping of key to child + */ +function getChildMapping(children) { + if (!children) { + return children; + } + var result = {}; + _react.Children.map(children, function (child) { + return child; + }).forEach(function (child) { + result[child.key] = child; + }); + return result; +} + +/** + * When you're adding or removing children some may be added or removed in the + * same render pass. We want to show *both* since we want to simultaneously + * animate elements in and out. This function takes a previous set of keys + * and a new set of keys and merges them with its best guess of the correct + * ordering. In the future we may expose some of the utilities in + * ReactMultiChild to make this easy, but for now React itself does not + * directly have this concept of the union of prevChildren and nextChildren + * so we implement it here. + * + * @param {object} prev prev children as returned from + * `ReactTransitionChildMapping.getChildMapping()`. + * @param {object} next next children as returned from + * `ReactTransitionChildMapping.getChildMapping()`. + * @return {object} a key set that contains all keys in `prev` and all keys + * in `next` in a reasonable order. + */ +function mergeChildMappings(prev, next) { + prev = prev || {}; + next = next || {}; + + function getValueForKey(key) { + if (next.hasOwnProperty(key)) { + return next[key]; + } + + return prev[key]; + } + + // For each key of `next`, the list of keys to insert before that key in + // the combined list + var nextKeysPending = {}; + + var pendingKeys = []; + for (var prevKey in prev) { + if (next.hasOwnProperty(prevKey)) { + if (pendingKeys.length) { + nextKeysPending[prevKey] = pendingKeys; + pendingKeys = []; + } + } else { + pendingKeys.push(prevKey); + } + } + + var i = void 0; + var childMapping = {}; + for (var nextKey in next) { + if (nextKeysPending.hasOwnProperty(nextKey)) { + for (i = 0; i < nextKeysPending[nextKey].length; i++) { + var pendingNextKey = nextKeysPending[nextKey][i]; + childMapping[nextKeysPending[nextKey][i]] = getValueForKey(pendingNextKey); + } + } + childMapping[nextKey] = getValueForKey(nextKey); + } + + // Finally, add the keys which didn't appear before any key in `next` + for (i = 0; i < pendingKeys.length; i++) { + childMapping[pendingKeys[i]] = getValueForKey(pendingKeys[i]); + } + + return childMapping; +} + +/***/ }), +/* 326 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +exports.__esModule = true; + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _addClass = __webpack_require__(327); + +var _addClass2 = _interopRequireDefault(_addClass); + +var _removeClass = __webpack_require__(329); + +var _removeClass2 = _interopRequireDefault(_removeClass); + +var _requestAnimationFrame = __webpack_require__(330); + +var _requestAnimationFrame2 = _interopRequireDefault(_requestAnimationFrame); + +var _properties = __webpack_require__(331); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _propTypes = __webpack_require__(40); + +var _propTypes2 = _interopRequireDefault(_propTypes); + +var _reactDom = __webpack_require__(76); + +var _PropTypes = __webpack_require__(153); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var events = []; +if (_properties.transitionEnd) events.push(_properties.transitionEnd); +if (_properties.animationEnd) events.push(_properties.animationEnd); + +function addEndListener(node, listener) { + if (events.length) { + events.forEach(function (e) { + return node.addEventListener(e, listener, false); + }); + } else { + setTimeout(listener, 0); + } + + return function () { + if (!events.length) return; + events.forEach(function (e) { + return node.removeEventListener(e, listener, false); + }); + }; +} + +var propTypes = { + children: _propTypes2.default.node, + name: _PropTypes.nameShape.isRequired, + + // Once we require timeouts to be specified, we can remove the + // boolean flags (appear etc.) and just accept a number + // or a bool for the timeout flags (appearTimeout etc.) + appear: _propTypes2.default.bool, + enter: _propTypes2.default.bool, + leave: _propTypes2.default.bool, + appearTimeout: _propTypes2.default.number, + enterTimeout: _propTypes2.default.number, + leaveTimeout: _propTypes2.default.number +}; + +var CSSTransitionGroupChild = function (_React$Component) { + _inherits(CSSTransitionGroupChild, _React$Component); + + function CSSTransitionGroupChild() { + var _temp, _this, _ret; + + _classCallCheck(this, CSSTransitionGroupChild); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.componentWillAppear = function (done) { + if (_this.props.appear) { + _this.transition('appear', done, _this.props.appearTimeout); + } else { + done(); + } + }, _this.componentWillEnter = function (done) { + if (_this.props.enter) { + _this.transition('enter', done, _this.props.enterTimeout); + } else { + done(); + } + }, _this.componentWillLeave = function (done) { + if (_this.props.leave) { + _this.transition('leave', done, _this.props.leaveTimeout); + } else { + done(); + } + }, _temp), _possibleConstructorReturn(_this, _ret); + } + + CSSTransitionGroupChild.prototype.componentWillMount = function componentWillMount() { + this.classNameAndNodeQueue = []; + this.transitionTimeouts = []; + }; + + CSSTransitionGroupChild.prototype.componentWillUnmount = function componentWillUnmount() { + this.unmounted = true; + + if (this.timeout) { + clearTimeout(this.timeout); + } + this.transitionTimeouts.forEach(function (timeout) { + clearTimeout(timeout); + }); + + this.classNameAndNodeQueue.length = 0; + }; + + CSSTransitionGroupChild.prototype.transition = function transition(animationType, finishCallback, timeout) { + var node = (0, _reactDom.findDOMNode)(this); + + if (!node) { + if (finishCallback) { + finishCallback(); + } + return; + } + + var className = this.props.name[animationType] || this.props.name + '-' + animationType; + var activeClassName = this.props.name[animationType + 'Active'] || className + '-active'; + var timer = null; + var removeListeners = void 0; + + (0, _addClass2.default)(node, className); + + // Need to do this to actually trigger a transition. + this.queueClassAndNode(activeClassName, node); + + // Clean-up the animation after the specified delay + var finish = function finish(e) { + if (e && e.target !== node) { + return; + } + + clearTimeout(timer); + if (removeListeners) removeListeners(); + + (0, _removeClass2.default)(node, className); + (0, _removeClass2.default)(node, activeClassName); + + if (removeListeners) removeListeners(); + + // Usually this optional callback is used for informing an owner of + // a leave animation and telling it to remove the child. + if (finishCallback) { + finishCallback(); + } + }; + + if (timeout) { + timer = setTimeout(finish, timeout); + this.transitionTimeouts.push(timer); + } else if (_properties.transitionEnd) { + removeListeners = addEndListener(node, finish); + } + }; + + CSSTransitionGroupChild.prototype.queueClassAndNode = function queueClassAndNode(className, node) { + var _this2 = this; + + this.classNameAndNodeQueue.push({ + className: className, + node: node + }); + + if (!this.rafHandle) { + this.rafHandle = (0, _requestAnimationFrame2.default)(function () { + return _this2.flushClassNameAndNodeQueue(); + }); + } + }; + + CSSTransitionGroupChild.prototype.flushClassNameAndNodeQueue = function flushClassNameAndNodeQueue() { + if (!this.unmounted) { + this.classNameAndNodeQueue.forEach(function (obj) { + // This is for to force a repaint, + // which is necessary in order to transition styles when adding a class name. + /* eslint-disable no-unused-expressions */ + obj.node.scrollTop; + /* eslint-enable no-unused-expressions */ + (0, _addClass2.default)(obj.node, obj.className); + }); + } + this.classNameAndNodeQueue.length = 0; + this.rafHandle = null; + }; + + CSSTransitionGroupChild.prototype.render = function render() { + var props = _extends({}, this.props); + delete props.name; + delete props.appear; + delete props.enter; + delete props.leave; + delete props.appearTimeout; + delete props.enterTimeout; + delete props.leaveTimeout; + delete props.children; + return _react2.default.cloneElement(_react2.default.Children.only(this.props.children), props); + }; + + return CSSTransitionGroupChild; +}(_react2.default.Component); + +CSSTransitionGroupChild.displayName = 'CSSTransitionGroupChild'; + + +CSSTransitionGroupChild.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; + +exports.default = CSSTransitionGroupChild; +module.exports = exports['default']; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 327 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = addClass; + +var _hasClass = __webpack_require__(328); + +var _hasClass2 = _interopRequireDefault(_hasClass); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function addClass(element, className) { + if (element.classList) element.classList.add(className);else if (!(0, _hasClass2.default)(element)) element.className = element.className + ' ' + className; +} +module.exports = exports['default']; + +/***/ }), +/* 328 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = hasClass; +function hasClass(element, className) { + if (element.classList) return !!className && element.classList.contains(className);else return (" " + element.className + " ").indexOf(" " + className + " ") !== -1; +} +module.exports = exports["default"]; + +/***/ }), +/* 329 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +module.exports = function removeClass(element, className) { + if (element.classList) element.classList.remove(className);else element.className = element.className.replace(new RegExp('(^|\\s)' + className + '(?:\\s|$)', 'g'), '$1').replace(/\s+/g, ' ').replace(/^\s*|\s*$/g, ''); +}; + +/***/ }), +/* 330 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _inDOM = __webpack_require__(152); + +var _inDOM2 = _interopRequireDefault(_inDOM); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var vendors = ['', 'webkit', 'moz', 'o', 'ms']; +var cancel = 'clearTimeout'; +var raf = fallback; +var compatRaf = void 0; + +var getKey = function getKey(vendor, k) { + return vendor + (!vendor ? k : k[0].toUpperCase() + k.substr(1)) + 'AnimationFrame'; +}; + +if (_inDOM2.default) { + vendors.some(function (vendor) { + var rafKey = getKey(vendor, 'request'); + + if (rafKey in window) { + cancel = getKey(vendor, 'cancel'); + return raf = function raf(cb) { + return window[rafKey](cb); + }; + } + }); +} + +/* https://github.com/component/raf */ +var prev = new Date().getTime(); +function fallback(fn) { + var curr = new Date().getTime(), + ms = Math.max(0, 16 - (curr - prev)), + req = setTimeout(fn, ms); + + prev = curr; + return req; +} + +compatRaf = function compatRaf(cb) { + return raf(cb); +}; +compatRaf.cancel = function (id) { + window[cancel] && typeof window[cancel] === 'function' && window[cancel](id); +}; +exports.default = compatRaf; +module.exports = exports['default']; + +/***/ }), +/* 331 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.animationEnd = exports.animationDelay = exports.animationTiming = exports.animationDuration = exports.animationName = exports.transitionEnd = exports.transitionDuration = exports.transitionDelay = exports.transitionTiming = exports.transitionProperty = exports.transform = undefined; + +var _inDOM = __webpack_require__(152); + +var _inDOM2 = _interopRequireDefault(_inDOM); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var transform = 'transform'; +var prefix = void 0, + transitionEnd = void 0, + animationEnd = void 0; +var transitionProperty = void 0, + transitionDuration = void 0, + transitionTiming = void 0, + transitionDelay = void 0; +var animationName = void 0, + animationDuration = void 0, + animationTiming = void 0, + animationDelay = void 0; + +if (_inDOM2.default) { + var _getTransitionPropert = getTransitionProperties(); + + prefix = _getTransitionPropert.prefix; + exports.transitionEnd = transitionEnd = _getTransitionPropert.transitionEnd; + exports.animationEnd = animationEnd = _getTransitionPropert.animationEnd; + + + exports.transform = transform = prefix + '-' + transform; + exports.transitionProperty = transitionProperty = prefix + '-transition-property'; + exports.transitionDuration = transitionDuration = prefix + '-transition-duration'; + exports.transitionDelay = transitionDelay = prefix + '-transition-delay'; + exports.transitionTiming = transitionTiming = prefix + '-transition-timing-function'; + + exports.animationName = animationName = prefix + '-animation-name'; + exports.animationDuration = animationDuration = prefix + '-animation-duration'; + exports.animationTiming = animationTiming = prefix + '-animation-delay'; + exports.animationDelay = animationDelay = prefix + '-animation-timing-function'; +} + +exports.transform = transform; +exports.transitionProperty = transitionProperty; +exports.transitionTiming = transitionTiming; +exports.transitionDelay = transitionDelay; +exports.transitionDuration = transitionDuration; +exports.transitionEnd = transitionEnd; +exports.animationName = animationName; +exports.animationDuration = animationDuration; +exports.animationTiming = animationTiming; +exports.animationDelay = animationDelay; +exports.animationEnd = animationEnd; +exports.default = { + transform: transform, + end: transitionEnd, + property: transitionProperty, + timing: transitionTiming, + delay: transitionDelay, + duration: transitionDuration +}; + + +function getTransitionProperties() { + var style = document.createElement('div').style; + + var vendorMap = { + O: function O(e) { + return 'o' + e.toLowerCase(); + }, + Moz: function Moz(e) { + return e.toLowerCase(); + }, + Webkit: function Webkit(e) { + return 'webkit' + e; + }, + ms: function ms(e) { + return 'MS' + e; + } + }; + + var vendors = Object.keys(vendorMap); + + var transitionEnd = void 0, + animationEnd = void 0; + var prefix = ''; + + for (var i = 0; i < vendors.length; i++) { + var vendor = vendors[i]; + + if (vendor + 'TransitionProperty' in style) { + prefix = '-' + vendor.toLowerCase(); + transitionEnd = vendorMap[vendor]('TransitionEnd'); + animationEnd = vendorMap[vendor]('AnimationEnd'); + break; + } + } + + if (!transitionEnd && 'transitionProperty' in style) transitionEnd = 'transitionend'; + + if (!animationEnd && 'animationName' in style) animationEnd = 'animationend'; + + style = null; + + return { animationEnd: animationEnd, transitionEnd: transitionEnd, prefix: prefix }; +} + +/***/ }), +/* 332 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _reactstrap = __webpack_require__(93); + +var _axios = __webpack_require__(335); + +var _axios2 = _interopRequireDefault(_axios); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _classnames = __webpack_require__(41); + +var _classnames2 = _interopRequireDefault(_classnames); + +var _reactCopyToClipboard = __webpack_require__(354); + +var _reactCopyToClipboard2 = _interopRequireDefault(_reactCopyToClipboard); + +var _reactTable = __webpack_require__(358); + +var _reactTable2 = _interopRequireDefault(_reactTable); + +var _zencashjs = __webpack_require__(160); + +var _zencashjs2 = _interopRequireDefault(_zencashjs); + +var _utils = __webpack_require__(462); + +var _utils2 = _interopRequireDefault(_utils); + +var _hdwallet = __webpack_require__(464); + +var _hdwallet2 = _interopRequireDefault(_hdwallet); + +var _fileSaver = __webpack_require__(497); + +var _fileSaver2 = _interopRequireDefault(_fileSaver); + +var _refresh = __webpack_require__(500); + +var _refresh2 = _interopRequireDefault(_refresh); + +var _contentCopy = __webpack_require__(501); + +var _contentCopy2 = _interopRequireDefault(_contentCopy); + +var _settings2 = __webpack_require__(502); + +var _settings3 = _interopRequireDefault(_settings2); + +var _repeat = __webpack_require__(503); + +var _repeat2 = _interopRequireDefault(_repeat); + +var _unlockAlt = __webpack_require__(504); + +var _unlockAlt2 = _interopRequireDefault(_unlockAlt); + +var _eyeSlash = __webpack_require__(505); + +var _eyeSlash2 = _interopRequireDefault(_eyeSlash); + +var _eye = __webpack_require__(506); + +var _eye2 = _interopRequireDefault(_eye); + +var _package = __webpack_require__(507); + +var _package2 = _interopRequireDefault(_package); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +// Throttled GET request to prevent unusable lag +var throttledAxiosGet = _utils2.default.promiseDebounce(_axios2.default.get, 1000, 5); + +// Unlock wallet enum +var UNLOCK_WALLET_TYPE = { + IMPORT_WALLET: 0, + HD_WALLET: 1, + PASTE_PRIV_KEY: 2 + + // Components +}; +var ToolTipButton = function (_React$Component) { + _inherits(ToolTipButton, _React$Component); + + function ToolTipButton(props) { + _classCallCheck(this, ToolTipButton); + + var _this = _possibleConstructorReturn(this, (ToolTipButton.__proto__ || Object.getPrototypeOf(ToolTipButton)).call(this, props)); + + _this.toggle = _this.toggle.bind(_this); + _this.state = { + tooltipOpen: false + }; + return _this; + } + + _createClass(ToolTipButton, [{ + key: 'toggle', + value: function toggle() { + this.setState({ + tooltipOpen: !this.state.tooltipOpen + }); + } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + 'span', + null, + _react2.default.createElement( + _reactstrap.Button, + { disabled: this.props.disabled, onClick: this.props.onClick, className: 'mr-1', color: 'secondary', id: 'Tooltip-' + this.props.id }, + this.props.buttonText + ), + _react2.default.createElement( + _reactstrap.Tooltip, + { placement: 'top', isOpen: this.state.tooltipOpen, target: 'Tooltip-' + this.props.id, toggle: this.toggle }, + this.props.tooltipText + ) + ); + } + }]); + + return ToolTipButton; +}(_react2.default.Component); + +var ZWalletGenerator = function (_React$Component2) { + _inherits(ZWalletGenerator, _React$Component2); + + function ZWalletGenerator(props) { + _classCallCheck(this, ZWalletGenerator); + + var _this2 = _possibleConstructorReturn(this, (ZWalletGenerator.__proto__ || Object.getPrototypeOf(ZWalletGenerator)).call(this, props)); + + _this2.handlePasswordPhrase = _this2.handlePasswordPhrase.bind(_this2); + _this2.state = { + passwordPhrase: '', + privateKey: '' + }; + return _this2; + } + + _createClass(ZWalletGenerator, [{ + key: 'handlePasswordPhrase', + value: function handlePasswordPhrase(e) { + // What wif format do we use? + var wifHash = this.props.settings.useTestNet ? _zencashjs2.default.config.testnet.wif : _zencashjs2.default.config.mainnet.wif; + + var pk = _zencashjs2.default.address.mkPrivKey(e.target.value); + var pkwif = _zencashjs2.default.address.privKeyToWIF(pk, true, wifHash); + + if (e.target.value === '') { + pkwif = ''; + } + + this.setState({ + privateKey: pkwif + }); + } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + 'h3', + { className: 'display-6' }, + 'Generate New Address' + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement(_reactstrap.Input, { onChange: this.handlePasswordPhrase, placeholder: 'Password phrase. Do NOT forget to save this! Use >15 words to be safe.' }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement(_reactstrap.Input, { value: this.state.privateKey, placeholder: 'Private key generated from password phrase' }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement( + _reactCopyToClipboard2.default, + { text: this.state.privateKey }, + _react2.default.createElement( + _reactstrap.Button, + null, + _react2.default.createElement(_contentCopy2.default, null) + ) + ) + ) + ) + ); + } + }]); + + return ZWalletGenerator; +}(_react2.default.Component); + +var ZWalletUnlockKey = function (_React$Component3) { + _inherits(ZWalletUnlockKey, _React$Component3); + + function ZWalletUnlockKey(props) { + _classCallCheck(this, ZWalletUnlockKey); + + var _this3 = _possibleConstructorReturn(this, (ZWalletUnlockKey.__proto__ || Object.getPrototypeOf(ZWalletUnlockKey)).call(this, props)); + + _this3.unlockHDWallet = _this3.unlockHDWallet.bind(_this3); + _this3.loadWalletDat = _this3.loadWalletDat.bind(_this3); + _this3.toggleShowPassword = _this3.toggleShowPassword.bind(_this3); + _this3.unlockPrivateKeys = _this3.unlockPrivateKeys.bind(_this3); + + _this3.state = { + showPassword: false, + secretPhrase: '', + invalidPrivateKey: false, + secretPhraseTooShort: false, + + // Style for input button + inputFileStyle: { + WebkitAppearance: 'button', + cursor: 'pointer' + } + }; + return _this3; + } + + _createClass(ZWalletUnlockKey, [{ + key: 'toggleShowPassword', + value: function toggleShowPassword() { + this.setState({ + showPassword: !this.state.showPassword + }); + } + }, { + key: 'unlockPrivateKeys', + value: function unlockPrivateKeys() { + // Success = return 0 + var success = this.props.handleUnlockPrivateKeys() === 0; + + if (!success) { + this.setState({ + invalidPrivateKey: true + }); + } + } + }, { + key: 'unlockHDWallet', + value: function unlockHDWallet() { + try { + // Generate private keys from secret phrase + var pk = _hdwallet2.default.phraseToHDWallet(this.state.secretPhrase); + + this.setState({ + secretPhraseTooShort: false + }); + + // Set private key and unlock them (we know it'll work so no need to validate) + this.props.setPrivateKeys(pk, true); + } catch (err) { + this.setState({ + secretPhraseTooShort: true + }); + } + } + }, { + key: 'loadWalletDat', + value: function loadWalletDat(e) { + var _this4 = this; + + var reader = new FileReader(); + var file = e.target.files[0]; + + // Read file callback function + reader.onloadend = function () { + // Get reader results in bytes + var dataHexStr = reader.result; + + // Retrieve private keys from wallet.dat + // Source: https://gist.github.com/moocowmoo/a715c80399bb202a65955771c465530c + var re = /\x30\x81\xD3\x02\x01\x01\x04\x20(.{32})/gm; + var privateKeys = dataHexStr.match(re); + privateKeys = privateKeys.map(function (x) { + x = x.replace('\x30\x81\xD3\x02\x01\x01\x04\x20', ''); + x = Buffer.from(x, 'latin1').toString('hex'); + return x; + }); + + // Set private key + _this4.props.setPrivateKeys(privateKeys); + + // Unlock private key + var success = _this4.props.handleUnlockPrivateKeys() === 0; + + if (!success) { + _this4.setState({ + invalidPrivateKey: true + }); + } + }; + + // Read file + reader.readAsBinaryString(file); + } + }, { + key: 'render', + value: function render() { + var _this5 = this; + + if (this.props.unlockType == UNLOCK_WALLET_TYPE.IMPORT_WALLET) { + return _react2.default.createElement( + _reactstrap.Form, + null, + _react2.default.createElement( + _reactstrap.FormGroup, + { row: true }, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.invalidPrivateKey ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Keys in files are corrupted' + ) : '', + _react2.default.createElement( + _reactstrap.Label, + { 'for': 'walletDatFile', className: 'btn btn-block btn-secondary', style: this.state.inputFileStyle }, + 'Select wallet.dat file', + _react2.default.createElement(_reactstrap.Input, { + style: { display: 'none' }, + type: 'file', + name: 'file', + id: 'walletDatFile', + onChange: this.loadWalletDat + }) + ), + _react2.default.createElement( + _reactstrap.FormText, + { color: 'muted' }, + 'For Windows, it should be in %APPDATA%/zen', + _react2.default.createElement('br', null), + 'For Mac/Linux, it should be in ~/.zen' + ) + ) + ) + ); + } else if (this.props.unlockType == UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY) { + return _react2.default.createElement( + 'div', + null, + this.state.invalidPrivateKey ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Invalid private key' + ) : '', + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { id: 4, + onClick: this.toggleShowPassword, + buttonText: this.state.showPassword ? _react2.default.createElement(_eye2.default, null) : _react2.default.createElement(_eyeSlash2.default, null), + tooltipText: this.state.showPassword ? 'show password' : 'hide password' + }) + ), + _react2.default.createElement(_reactstrap.Input, { + type: this.state.showPassword ? "text" : "password", + onChange: function onChange(e) { + return _this5.props.setPrivateKeys([e.target.value]); + } // Set it in a list so we can map over it later + , placeholder: 'Private key' + }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { onClick: this.unlockPrivateKeys, id: 3, buttonText: _react2.default.createElement(_unlockAlt2.default, null), tooltipText: 'unlock' }) + ) + ) + ); + } else if (this.props.unlockType == UNLOCK_WALLET_TYPE.HD_WALLET) { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + _reactstrap.Alert, + { color: 'warning' }, + _react2.default.createElement( + 'strong', + null, + 'Warning.' + ), + '\xA0Make sure you have saved your secret phrase somewhere.' + ), + this.state.secretPhraseTooShort ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Secret phrase too short' + ) : '', + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { id: 7, + onClick: this.toggleShowPassword, + buttonText: this.state.showPassword ? _react2.default.createElement(_eye2.default, null) : _react2.default.createElement(_eyeSlash2.default, null), + tooltipText: this.state.showPassword ? 'show phrase' : 'hide phrase' + }) + ), + _react2.default.createElement(_reactstrap.Input, { + type: this.state.showPassword ? "text" : "password", + maxLength: '64', + onChange: function onChange(e) { + return _this5.setState({ secretPhrase: e.target.value }); + }, + placeholder: 'Secret phrase. e.g. cash cow money heros cardboard money bag late green' + }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { onClick: this.unlockHDWallet, id: 8, buttonText: _react2.default.createElement(_unlockAlt2.default, null), tooltipText: 'unlock HD wallet' }) + ) + ) + ); + } + } + }]); + + return ZWalletUnlockKey; +}(_react2.default.Component); + +var ZWalletSettings = function (_React$Component4) { + _inherits(ZWalletSettings, _React$Component4); + + function ZWalletSettings() { + _classCallCheck(this, ZWalletSettings); + + return _possibleConstructorReturn(this, (ZWalletSettings.__proto__ || Object.getPrototypeOf(ZWalletSettings)).apply(this, arguments)); + } + + _createClass(ZWalletSettings, [{ + key: 'render', + value: function render() { + var _this7 = this; + + return _react2.default.createElement( + _reactstrap.Modal, + { isOpen: this.props.settings.showSettings, toggle: this.props.toggleModalSettings }, + _react2.default.createElement( + _reactstrap.ModalHeader, + { toggle: this.props.toggleShowSettings }, + 'ZenCash Wallet Settings' + ), + _react2.default.createElement( + _reactstrap.ModalBody, + null, + _react2.default.createElement(ZWalletSelectUnlockType, { + setUnlockType: this.props.setUnlockType, + unlockType: this.props.settings.unlockType + }) + ), + _react2.default.createElement( + _reactstrap.ModalBody, + null, + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Insight API' + ), + _react2.default.createElement(_reactstrap.Input, { + value: this.props.settings.insightAPI, + onChange: function onChange(e) { + return _this7.props.setInsightAPI(e.target.value); + } + }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + { sm: '6' }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { + disabled: !(this.props.publicAddresses === null), + defaultChecked: this.props.settings.compressPubKey, type: 'checkbox', + onChange: this.props.toggleCompressPubKey + }), + ' ', + 'Compress Public Key' + ) + ), + _react2.default.createElement( + _reactstrap.Col, + { sm: '6' }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { + defaultChecked: this.props.settings.showWalletGen, type: 'checkbox', + onChange: this.props.toggleShowWalletGen + }), + ' ', + 'Show Address Generator' + ) + ) + ) + ), + _react2.default.createElement( + _reactstrap.ModalFooter, + null, + _react2.default.createElement( + _reactstrap.Label, + null, + _react2.default.createElement(_reactstrap.Input, { + disabled: !(this.props.publicAddresses === null), + defaultChecked: this.props.settings.useTestNet, type: 'checkbox', + onChange: this.props.toggleUseTestNet + }), + ' ', + 'testnet' + ) + ) + ); + } + }]); + + return ZWalletSettings; +}(_react2.default.Component); + +var ZAddressInfo = function (_React$Component5) { + _inherits(ZAddressInfo, _React$Component5); + + function ZAddressInfo(props) { + _classCallCheck(this, ZAddressInfo); + + var _this8 = _possibleConstructorReturn(this, (ZAddressInfo.__proto__ || Object.getPrototypeOf(ZAddressInfo)).call(this, props)); + + _this8.updateAddressInfo = _this8.updateAddressInfo.bind(_this8); + _this8.updateAddressesInfo = _this8.updateAddressesInfo.bind(_this8); + _this8.getAddressBlockExplorerURL = _this8.getAddressBlockExplorerURL.bind(_this8); + + _this8.state = { + retrieveAddressError: false + }; + return _this8; + } + + // Updates all address info + + + _createClass(ZAddressInfo, [{ + key: 'updateAddressesInfo', + value: function updateAddressesInfo() { + // The key is the address + // Value is the private key + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + this.updateAddressInfo(key); + } + }.bind(this)); + } + + // Gets the blockchain explorer URL for an address + + }, { + key: 'getAddressBlockExplorerURL', + value: function getAddressBlockExplorerURL(address) { + return _utils2.default.urlAppend(this.props.settings.explorerURL, 'address/') + address; + } + + // Updates a address info + + }, { + key: 'updateAddressInfo', + value: function updateAddressInfo(address) { + // GET request to URL + var info_url = _utils2.default.urlAppend(this.props.settings.insightAPI, 'addr/'); + info_url = _utils2.default.urlAppend(info_url, address + '?noTxList=1'); + + throttledAxiosGet(info_url).then(function (response) { + var data = response.data; + + this.props.setPublicAddressesKeyValue(address, 'confirmedBalance', data.balance); + this.props.setPublicAddressesKeyValue(address, 'unconfirmedBalance', data.unconfirmedBalance); + this.setState({ + retrieveAddressError: false + }); + }.bind(this)).catch(function (error) { + this.setState({ + retrieveAddressError: true + }); + }.bind(this)); + } + }, { + key: 'componentDidMount', + value: function componentDidMount() { + // Run immediately + this.updateAddressesInfo(); + + // Update every 30 seconds + this.interval = setInterval(this.updateAddressesInfo, 300000); + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + clearInterval(this.interval); + } + }, { + key: 'render', + value: function render() { + var _this9 = this; + + // Key is the address + var addresses = []; + var totalConfirmed = 0.0; + var totalUnconfirmed = 0.0; + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + // Add to address + addresses.push({ + address: key, + privateKeyWIF: this.props.publicAddresses[key].privateKeyWIF, + confirmedBalance: this.props.publicAddresses[key].confirmedBalance, + unconfirmedBalance: this.props.publicAddresses[key].unconfirmedBalance + }); + + var c_confirmed = Number(this.props.publicAddresses[key].confirmedBalance); + var c_unconfirmed = Number(this.props.publicAddresses[key].unconfirmedBalance); + if (!isNaN(c_confirmed)) { + totalConfirmed += c_confirmed; + } + + if (!isNaN(c_unconfirmed)) { + totalUnconfirmed += c_unconfirmed; + } + } + }.bind(this)); + + var addressColumns = [{ + Header: 'Address', + accessor: 'address', + resizable: true, + Cell: function Cell(props) { + return _react2.default.createElement( + 'a', + { href: _this9.getAddressBlockExplorerURL(props.value) }, + props.value + ); + } + }, { + Header: 'Confirmed', + accessor: 'confirmedBalance', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }, { + Header: 'Unconfirmed', + accessor: 'unconfirmedBalance', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }]; + + return _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + this.state.retrieveAddressError ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + 'Error connecting to the Insight API. Double check the Insight API supplied in settings.' + ) : _react2.default.createElement( + _reactstrap.Alert, + { color: 'warning' }, + 'The balance displayed here is dependent on the insight node.', + _react2.default.createElement('br', null), + 'Automatically updates every 5 minutes. Alternatively, you can ', + _react2.default.createElement( + 'a', + { href: '#', onClick: function onClick() { + return _this9.updateAddressesInfo(); + } }, + 'forcefully refresh' + ), + ' them.' + ) + ) + ), + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement(_reactTable2.default, { + columns: [{ + Header: 'Total Confirmed', + accessor: 'totalConfirmed', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }, { + Header: 'Total Unconfirmed', + accessor: 'totalUnconfirmed', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }], + + data: [{ + totalConfirmed: totalConfirmed, + totalUnconfirmed: totalUnconfirmed + }], + + showPagination: false, + + minRows: 1 + }) + ) + ), + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement(_reactTable2.default, { + data: addresses, columns: addressColumns, + minRows: addresses.length > 20 ? 20 : addresses.length, + showPagination: addresses.length > 20 + }) + ) + ) + ) + ); + } + }]); + + return ZAddressInfo; +}(_react2.default.Component); + +var ZSendZEN = function (_React$Component6) { + _inherits(ZSendZEN, _React$Component6); + + function ZSendZEN(props) { + _classCallCheck(this, ZSendZEN); + + var _this10 = _possibleConstructorReturn(this, (ZSendZEN.__proto__ || Object.getPrototypeOf(ZSendZEN)).call(this, props)); + + _this10.setProgressValue = _this10.setProgressValue.bind(_this10); + _this10.setSendErrorMessage = _this10.setSendErrorMessage.bind(_this10); + _this10.handleUpdateSelectedAddress = _this10.handleUpdateSelectedAddress.bind(_this10); + _this10.handleUpdateRecipientAddress = _this10.handleUpdateRecipientAddress.bind(_this10); + _this10.handleUpdateAmount = _this10.handleUpdateAmount.bind(_this10); + _this10.handleCheckChanged = _this10.handleCheckChanged.bind(_this10); + _this10.handleUpdateFee = _this10.handleUpdateFee.bind(_this10); + _this10.handleSendZEN = _this10.handleSendZEN.bind(_this10); + + _this10.state = { + selectedAddress: '', // which address did we select + recipientAddress: '', + fee: '', + amount: '', + sentTxid: '', // Whats the send txid + sendProgress: 0, // Progress bar, 100 to indicate complete + sendErrorMessage: '', + confirmSend: false + }; + return _this10; + } + + _createClass(ZSendZEN, [{ + key: 'handleUpdateSelectedAddress', + value: function handleUpdateSelectedAddress(e) { + this.setState({ + selectedAddress: e.target.value + }); + } + }, { + key: 'handleUpdateRecipientAddress', + value: function handleUpdateRecipientAddress(e) { + this.setState({ + recipientAddress: e.target.value + }); + } + }, { + key: 'handleUpdateFee', + value: function handleUpdateFee(e) { + this.setState({ + fee: e.target.value + }); + } + }, { + key: 'handleUpdateAmount', + value: function handleUpdateAmount(e) { + this.setState({ + amount: e.target.value + }); + } + }, { + key: 'handleCheckChanged', + value: function handleCheckChanged(e) { + this.setState({ + confirmSend: e.target.checked + }); + } + }, { + key: 'setProgressValue', + value: function setProgressValue(v) { + this.setState({ + sendProgress: v + }); + } + }, { + key: 'setSendErrorMessage', + value: function setSendErrorMessage(msg) { + this.setState({ + sendErrorMessage: msg + }); + } + }, { + key: 'handleSendZEN', + value: function handleSendZEN() { + var value = this.state.amount; + var fee = this.state.fee; + var recipientAddress = this.state.recipientAddress; + var senderAddress = this.state.selectedAddress; + + // Convert how much we wanna send + // to satoshis + var satoshisToSend = Math.round(value * 100000000); + var satoshisfeesToSend = Math.round(fee * 100000000); + + // Reset zen send progress and error message + this.setProgressValue(1); + this.setSendErrorMessage(''); + + // Error strings + var errString = ''; + + // Validation + if (senderAddress === '') { + errString += '`From Address` field can\'t be empty.;'; + } + + if (recipientAddress.length !== 35) { + errString += 'Invalid address. Only transparent addresses are supported at this point in time.;'; + } + + if (typeof parseInt(value) !== 'number' || value === '') { + errString += 'Invalid amount.;'; + } + + // Can't send 0 satoshis + if (satoshisToSend <= 0) { + errString += 'Amount must be greater than 0.;'; + } + + if (typeof parseInt(fee) !== 'number' || fee === '') { + errString += 'Invalid fee.;'; + } + + if (errString !== '') { + this.setSendErrorMessage(errString); + this.setProgressValue(0); + return; + } + + // Private key + var senderPrivateKey = this.props.publicAddresses[senderAddress].privateKey; + + // Get previous transactions + var prevTxURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'addr/') + senderAddress + '/utxo'; + var infoURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'status?q=getInfo'); + var sendRawTxURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'tx/send'); + + // Building our transaction TXOBJ + // How many satoshis do we have so far + var satoshisSoFar = 0; + var history = []; + var recipients = [{ address: recipientAddress, satoshis: satoshisToSend }]; + + // Get transactions and info + _axios2.default.get(prevTxURL).then(function (tx_resp) { + this.setProgressValue(25); + + var tx_data = tx_resp.data; + + _axios2.default.get(infoURL).then(function (info_resp) { + this.setProgressValue(50); + var info_data = info_resp.data; + + var blockHeight = info_data.info.blocks - 300; + var blockHashURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'block-index/') + blockHeight; + + // Get block hash + _axios2.default.get(blockHashURL).then(function (response_bhash) { + this.setProgressValue(75); + + var blockHash = response_bhash.data.blockHash; + + // Iterate through each utxo + // append it to history + for (var i = 0; i < tx_data.length; i++) { + if (tx_data[i].confirmations == 0) { + continue; + } + + history = history.concat({ + txid: tx_data[i].txid, + vout: tx_data[i].vout, + scriptPubKey: tx_data[i].scriptPubKey + }); + + // How many satoshis do we have so far + satoshisSoFar = satoshisSoFar + tx_data[i].satoshis; + if (satoshisSoFar >= satoshisToSend + satoshisfeesToSend) { + break; + } + } + + // If we don't have enough address + // fail and tell user + if (satoshisSoFar < satoshisToSend + satoshisfeesToSend) { + this.setSendErrorMessage('Not enough confirmed ZEN in account to perform transaction'); + this.setProgressValue(0); + } + + // If we don't have exact amount + // Refund remaining to current address + if (satoshisSoFar !== satoshisToSend + satoshisfeesToSend) { + var refundSatoshis = satoshisSoFar - satoshisToSend - satoshisfeesToSend; + recipients = recipients.concat({ address: senderAddress, satoshis: refundSatoshis }); + } + + // Create transaction + var txObj = _zencashjs2.default.transaction.createRawTx(history, recipients, blockHeight, blockHash); + + // Sign each history transcation + for (var i = 0; i < history.length; i++) { + txObj = _zencashjs2.default.transaction.signTx(txObj, i, senderPrivateKey, this.props.settings.compressPubKey); + } + + // Convert it to hex string + var txHexString = _zencashjs2.default.transaction.serializeTx(txObj); + + _axios2.default.post(sendRawTxURL, { rawtx: txHexString }).then(function (sendtx_resp) { + this.setState({ + sendProgress: 100, + sentTxid: sendtx_resp.data.txid + }); + }.bind(this)).catch(function (error) { + this.setSendErrorMessage(error + ''); + this.setProgressValue(0); + return; + }.bind(this)); + }.bind(this)); + }.bind(this)); + }.bind(this)).catch(function (error) { + this.setSendErrorMessage(error); + this.setProgressValue(0); + return; + }.bind(this)); + } + }, { + key: 'render', + value: function render() { + // If send was successful + var zenTxLink; + if (this.state.sendProgress === 100) { + var zentx = _utils2.default.urlAppend(this.props.settings.explorerURL, 'tx/') + this.state.sentTxid; + zenTxLink = _react2.default.createElement( + _reactstrap.Alert, + { color: 'success' }, + _react2.default.createElement( + 'strong', + null, + 'ZEN successfully sent!' + ), + ' ', + _react2.default.createElement( + 'a', + { href: zentx }, + 'Click here to view your transaction' + ) + ); + } + + // Else show error why + else if (this.state.sendErrorMessage !== '') { + zenTxLink = this.state.sendErrorMessage.split(';').map(function (s) { + if (s !== '') { + return _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + ' ', + s + ); + } + }); + } + + // Send addresses + // Key is the address btw + var sendAddresses = []; + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + sendAddresses.push(_react2.default.createElement( + 'option', + { value: key }, + '[', + this.props.publicAddresses[key].confirmedBalance, + '] - ', + key + )); + } + }.bind(this)); + + return _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + 'ALWAYS VALIDATE YOUR DESINATION ADDRESS BY SENDING SMALL AMOUNTS OF ZEN FIRST' + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'From Address' + ), + _react2.default.createElement( + _reactstrap.Input, + { type: 'select', onChange: this.handleUpdateSelectedAddress }, + _react2.default.createElement('option', { value: '' }), + sendAddresses + ) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'To Address' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateRecipientAddress, placeholder: 'e.g znSDvF9nA5VCdse5HbEKmsoNbjCbsEA3VAH' }) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Amount' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateAmount, placeholder: 'e.g 42' }) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Fee' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateFee, placeholder: 'e.g 0.001' }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.FormGroup, + { check: true }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleCheckChanged, type: 'checkbox' }), + ' ', + 'Yes, I would like to send these ZEN' + ) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.Button, + { + color: 'warning', className: 'btn-block', + disabled: !this.state.confirmSend || this.state.sendProgress > 0 && this.state.sendProgress < 100, + onClick: this.handleSendZEN + }, + 'Send' + ) + ), + _react2.default.createElement( + _reactstrap.CardFooter, + null, + zenTxLink, + _react2.default.createElement(_reactstrap.Progress, { value: this.state.sendProgress }) + ) + ) + ) + ); + } + }]); + + return ZSendZEN; +}(_react2.default.Component); + +var ZWalletSelectUnlockType = function (_React$Component7) { + _inherits(ZWalletSelectUnlockType, _React$Component7); + + function ZWalletSelectUnlockType(props) { + _classCallCheck(this, ZWalletSelectUnlockType); + + var _this11 = _possibleConstructorReturn(this, (ZWalletSelectUnlockType.__proto__ || Object.getPrototypeOf(ZWalletSelectUnlockType)).call(this, props)); + + _this11.state = { cSelected: _this11.props.unlockType }; + return _this11; + } + + _createClass(ZWalletSelectUnlockType, [{ + key: 'onRadioBtnClick', + value: function onRadioBtnClick(s) { + this.setState({ + cSelected: s + }); + + this.props.setUnlockType(s); + } + }, { + key: 'render', + value: function render() { + var _this12 = this; + + return _react2.default.createElement( + 'div', + { style: { textAlign: 'center' } }, + _react2.default.createElement( + _reactstrap.ButtonGroup, + { vertical: true }, + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.HD_WALLET); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.HD_WALLET }, + 'Enter secret phrase' + ), + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.IMPORT_WALLET); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.IMPORT_WALLET }, + 'Load wallet.dat' + ), + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY }, + 'Paste private key' + ) + ) + ); + } + }]); + + return ZWalletSelectUnlockType; +}(_react2.default.Component); + +var ZWalletTabs = function (_React$Component8) { + _inherits(ZWalletTabs, _React$Component8); + + function ZWalletTabs(props) { + _classCallCheck(this, ZWalletTabs); + + var _this13 = _possibleConstructorReturn(this, (ZWalletTabs.__proto__ || Object.getPrototypeOf(ZWalletTabs)).call(this, props)); + + _this13.toggleTabs = _this13.toggleTabs.bind(_this13); + _this13.savePrivateKeys = _this13.savePrivateKeys.bind(_this13); + _this13.state = { + activeTab: '1' + }; + return _this13; + } + + _createClass(ZWalletTabs, [{ + key: 'toggleTabs', + value: function toggleTabs(tab) { + if (this.state.activeTab !== tab) { + this.setState({ + activeTab: tab + }); + } + } + }, { + key: 'savePrivateKeys', + value: function savePrivateKeys() { + // ISO 8601 + var now = new Date(); + now = now.toISOString().split('.')[0] + 'Z'; + + var fileStr = '# Wallet dump created by myzenwallet ' + _package2.default.version + '\n'; + fileStr += '# Created on ' + now + '\n\n\n'; + + Object.keys(this.props.publicAddresses).forEach(function (key) { + fileStr += this.props.publicAddresses[key].privateKeyWIF; + fileStr += ' ' + now + ' ' + 'label=' + ' ' + '# addr=' + key; + fileStr += '\n'; + }.bind(this)); + + var pkBlob = new Blob([fileStr], { type: 'text/plain;charset=utf-8' }); + _fileSaver2.default.saveAs(pkBlob, now + '_myzenwallet_private_keys.txt'); + } + }, { + key: 'render', + value: function render() { + var _this14 = this; + + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + _reactstrap.Nav, + { tabs: true }, + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '1' }), + onClick: function onClick() { + _this14.toggleTabs('1'); + } + }, + 'Info' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '2' }), + onClick: function onClick() { + _this14.toggleTabs('2'); + } + }, + 'Send ZEN' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '3' }), + onClick: function onClick() { + _this14.toggleTabs('3'); + } + }, + 'Export' + ) + ) + ), + _react2.default.createElement( + _reactstrap.TabContent, + { activeTab: this.state.activeTab }, + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '1' }, + _react2.default.createElement(ZAddressInfo, { + publicAddresses: this.props.publicAddresses, + settings: this.props.settings, + setPublicAddressesKeyValue: this.props.setPublicAddressesKeyValue + }) + ), + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '2' }, + _react2.default.createElement(ZSendZEN, { + settings: this.props.settings, + publicAddresses: this.props.publicAddresses + }) + ), + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '3' }, + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement( + _reactstrap.Button, + { + color: 'secondary', className: 'btn-block', + onClick: this.savePrivateKeys + }, + 'Download Private Keys' + ) + ) + ) + ) + ) + ) + ) + ); + } + }]); + + return ZWalletTabs; +}(_react2.default.Component); + +var ZWallet = function (_React$Component9) { + _inherits(ZWallet, _React$Component9); + + function ZWallet(props) { + _classCallCheck(this, ZWallet); + + var _this15 = _possibleConstructorReturn(this, (ZWallet.__proto__ || Object.getPrototypeOf(ZWallet)).call(this, props)); + + _this15.resetKeys = _this15.resetKeys.bind(_this15); + _this15.handleUnlockPrivateKeys = _this15.handleUnlockPrivateKeys.bind(_this15); + _this15.setPrivateKeys = _this15.setPrivateKeys.bind(_this15); + _this15.setInsightAPI = _this15.setInsightAPI.bind(_this15); + _this15.setUnlockType = _this15.setUnlockType.bind(_this15); + _this15.setPublicAddressesKeyValue = _this15.setPublicAddressesKeyValue.bind(_this15); + _this15.toggleUseTestNet = _this15.toggleUseTestNet.bind(_this15); + _this15.toggleCompressPubKey = _this15.toggleCompressPubKey.bind(_this15); + _this15.toggleShowSettings = _this15.toggleShowSettings.bind(_this15); + _this15.toggleShowWalletGen = _this15.toggleShowWalletGen.bind(_this15); + + _this15.state = { + privateKeys: '', + publicAddresses: null, // Public address will be {address: {privateKey: '', transactionURL: '', privateKeyWIF: ''} + settings: { + showSettings: false, + showWalletGen: false, + compressPubKey: true, + insightAPI: 'https://explorer.zensystem.io/insight-api-zen/', + explorerURL: 'https://explorer.zensystem.io/', + useTestNet: false, + unlockType: UNLOCK_WALLET_TYPE.HD_WALLET + } + }; + return _this15; + } + + _createClass(ZWallet, [{ + key: 'handleUnlockPrivateKeys', + value: function handleUnlockPrivateKeys() { + if (this.state.privateKeys.length === 0) { + return -2; + } + + try { + var _privKeyToAddr = function _privKeyToAddr(pk, compressPubKey, useTestNet) { + // If not 64 length, probs WIF format + if (pk.length !== 64) { + pk = _zencashjs2.default.address.WIFToPrivKey(pk); + } + + // Convert public key to public address + var pubKey = _zencashjs2.default.address.privKeyToPubKey(pk, compressPubKey); + + // Testnet or nah + var pubKeyHash = useTestNet ? _zencashjs2.default.config.testnet.pubKeyHash : _zencashjs2.default.config.mainnet.pubKeyHash; + var publicAddr = _zencashjs2.default.address.pubKeyToAddr(pubKey, pubKeyHash); + + return publicAddr; + }; + + var publicAddresses = {}; + + for (var i = 0; i < this.state.privateKeys.length; i++) { + var pubKeyHash = this.state.settings.useTestNet ? _zencashjs2.default.config.testnet.wif : _zencashjs2.default.config.mainnet.wif; + + var c_pk_wif; + var c_pk = this.state.privateKeys[i]; + + // If not 64 length, probs WIF format + if (c_pk.length !== 64) { + c_pk_wif = c_pk; + c_pk = _zencashjs2.default.address.WIFToPrivKey(c_pk); + } else { + c_pk_wif = _zencashjs2.default.address.privKeyToWIF(c_pk); + } + + var c_pk_wif = _zencashjs2.default.address.privKeyToWIF(c_pk, true, pubKeyHash); + var c_addr = _privKeyToAddr(c_pk, this.state.settings.compressPubKey, this.state.settings.useTestNet); + + publicAddresses[c_addr] = { + privateKey: c_pk, + privateKeyWIF: c_pk_wif, + confirmedBalance: 'loading...', + unconfirmedBalance: 'loading...' + }; + } + + // Set public address + this.setPublicAddresses(publicAddresses); + + // Return success + return 0; + } catch (err) { + this.setPublicAddresses(null); + return -1; + } + } + }, { + key: 'resetKeys', + value: function resetKeys() { + this.setState({ + privateKeys: '', + publicAddresses: null + }); + } + + // Only used for bip32 gen wallet because + // of the async nature + + }, { + key: 'setPrivateKeys', + value: function setPrivateKeys(pk, handleUnlockingKeys) { + if (handleUnlockingKeys === undefined) { + handleUnlockingKeys = false; + } + this.setState({ + privateKeys: pk + }, handleUnlockingKeys ? this.handleUnlockPrivateKeys : undefined); + } + }, { + key: 'setPublicAddresses', + value: function setPublicAddresses(pa) { + this.setState({ + publicAddresses: pa + }); + } + }, { + key: 'setPublicAddressesKeyValue', + value: function setPublicAddressesKeyValue(address, key, value) { + var newPublicAddresses = this.state.publicAddresses; + newPublicAddresses[address][key] = value; + + this.setState({ + publicAddresses: newPublicAddresses + }); + } + }, { + key: 'setInsightAPI', + value: function setInsightAPI(uri) { + var _settings = this.state.settings; + _settings.insightAPI = uri; + + this.setState({ + _settings: _settings + }); + } + }, { + key: 'setUnlockType', + value: function setUnlockType(t) { + var _settings = this.state.settings; + _settings.unlockType = t; + + this.setState({ + _settings: _settings + }); + } + }, { + key: 'toggleCompressPubKey', + value: function toggleCompressPubKey(b) { + var _settings = this.state.settings; + _settings.compressPubKey = !_settings.compressPubKey; + + this.setState({ + _settings: _settings + }); + } + }, { + key: 'toggleUseTestNet', + value: function toggleUseTestNet() { + var _settings = this.state.settings; + _settings.useTestNet = !_settings.useTestNet; + + if (_settings.useTestNet) { + _settings.insightAPI = 'http://aayanl.tech:8081/insight-api-zen/'; + _settings.explorerURL = 'http://aayanl.tech:8081/'; + } else { + _settings.insightAPI = 'https://explorer.zensystem.io/insight-api-zen/'; + _settings.explorerURL = 'https://explorer.zensystem.io/insight/'; + } + + this.setState({ + settings: _settings + }); + } + }, { + key: 'toggleShowSettings', + value: function toggleShowSettings() { + var _settings = this.state.settings; + _settings.showSettings = !_settings.showSettings; + + this.setState({ + settings: _settings + }); + } + }, { + key: 'toggleShowWalletGen', + value: function toggleShowWalletGen() { + var _settings = this.state.settings; + _settings.showWalletGen = !_settings.showWalletGen; + + this.setState({ + settings: _settings + }); + } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + _reactstrap.Container, + null, + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + 'h1', + { className: 'display-6' }, + 'ZenCash Wallet\xA0', + _react2.default.createElement(ToolTipButton, { onClick: this.toggleShowSettings, id: 1, buttonText: _react2.default.createElement(_settings3.default, null), tooltipText: 'settings' }), + '\xA0', + _react2.default.createElement(ToolTipButton, { disabled: this.state.publicAddresses === null, onClick: this.resetKeys, id: 2, buttonText: _react2.default.createElement(_repeat2.default, null), tooltipText: 'reset wallet' }) + ), + _react2.default.createElement(ZWalletSettings, { + setUnlockType: this.setUnlockType, + toggleShowSettings: this.toggleShowSettings, + toggleCompressPubKey: this.toggleCompressPubKey, + toggleShowWalletGen: this.toggleShowWalletGen, + toggleUseTestNet: this.toggleUseTestNet, + setInsightAPI: this.setInsightAPI, + settings: this.state.settings, + publicAddresses: this.state.publicAddresses + }), + _react2.default.createElement('br', null) + ) + ), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.publicAddresses === null ? _react2.default.createElement(ZWalletUnlockKey, { + handleUnlockPrivateKeys: this.handleUnlockPrivateKeys, + setPrivateKeys: this.setPrivateKeys, + unlockType: this.state.settings.unlockType + }) : _react2.default.createElement(ZWalletTabs, { + publicAddresses: this.state.publicAddresses, + settings: this.state.settings, + setPublicAddressesKeyValue: this.setPublicAddressesKeyValue, + privateKeys: this.state.privateKeys + }) + ) + ), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.settings.showWalletGen ? _react2.default.createElement( + 'div', + null, + _react2.default.createElement('br', null), + _react2.default.createElement('hr', null), + _react2.default.createElement(ZWalletGenerator, { settings: this.state.settings }) + ) : null + ) + ) + ); + } + }]); + + return ZWallet; +}(_react2.default.Component); + +exports.default = ZWallet; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 333 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.byteLength = byteLength +exports.toByteArray = toByteArray +exports.fromByteArray = fromByteArray + +var lookup = [] +var revLookup = [] +var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array + +var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' +for (var i = 0, len = code.length; i < len; ++i) { + lookup[i] = code[i] + revLookup[code.charCodeAt(i)] = i +} + +revLookup['-'.charCodeAt(0)] = 62 +revLookup['_'.charCodeAt(0)] = 63 + +function placeHoldersCount (b64) { + var len = b64.length + if (len % 4 > 0) { + throw new Error('Invalid string. Length must be a multiple of 4') + } + + // the number of equal signs (place holders) + // if there are two placeholders, than the two characters before it + // represent one byte + // if there is only one, then the three characters before it represent 2 bytes + // this is just a cheap hack to not do indexOf twice + return b64[len - 2] === '=' ? 2 : b64[len - 1] === '=' ? 1 : 0 +} + +function byteLength (b64) { + // base64 is 4/3 + up to two characters of the original data + return (b64.length * 3 / 4) - placeHoldersCount(b64) +} + +function toByteArray (b64) { + var i, l, tmp, placeHolders, arr + var len = b64.length + placeHolders = placeHoldersCount(b64) + + arr = new Arr((len * 3 / 4) - placeHolders) + + // if there are placeholders, only get up to the last complete 4 chars + l = placeHolders > 0 ? len - 4 : len + + var L = 0 + + for (i = 0; i < l; i += 4) { + tmp = (revLookup[b64.charCodeAt(i)] << 18) | (revLookup[b64.charCodeAt(i + 1)] << 12) | (revLookup[b64.charCodeAt(i + 2)] << 6) | revLookup[b64.charCodeAt(i + 3)] + arr[L++] = (tmp >> 16) & 0xFF + arr[L++] = (tmp >> 8) & 0xFF + arr[L++] = tmp & 0xFF + } + + if (placeHolders === 2) { + tmp = (revLookup[b64.charCodeAt(i)] << 2) | (revLookup[b64.charCodeAt(i + 1)] >> 4) + arr[L++] = tmp & 0xFF + } else if (placeHolders === 1) { + tmp = (revLookup[b64.charCodeAt(i)] << 10) | (revLookup[b64.charCodeAt(i + 1)] << 4) | (revLookup[b64.charCodeAt(i + 2)] >> 2) + arr[L++] = (tmp >> 8) & 0xFF + arr[L++] = tmp & 0xFF + } + + return arr +} + +function tripletToBase64 (num) { + return lookup[num >> 18 & 0x3F] + lookup[num >> 12 & 0x3F] + lookup[num >> 6 & 0x3F] + lookup[num & 0x3F] +} + +function encodeChunk (uint8, start, end) { + var tmp + var output = [] + for (var i = start; i < end; i += 3) { + tmp = (uint8[i] << 16) + (uint8[i + 1] << 8) + (uint8[i + 2]) + output.push(tripletToBase64(tmp)) + } + return output.join('') +} + +function fromByteArray (uint8) { + var tmp + var len = uint8.length + var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes + var output = '' + var parts = [] + var maxChunkLength = 16383 // must be multiple of 3 + + // go through the array every three bytes, we'll deal with trailing stuff later + for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) { + parts.push(encodeChunk(uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength))) + } + + // pad the end with zeros, but make sure to not forget the extra bytes + if (extraBytes === 1) { + tmp = uint8[len - 1] + output += lookup[tmp >> 2] + output += lookup[(tmp << 4) & 0x3F] + output += '==' + } else if (extraBytes === 2) { + tmp = (uint8[len - 2] << 8) + (uint8[len - 1]) + output += lookup[tmp >> 10] + output += lookup[(tmp >> 4) & 0x3F] + output += lookup[(tmp << 2) & 0x3F] + output += '=' + } + + parts.push(output) + + return parts.join('') +} + + +/***/ }), +/* 334 */ +/***/ (function(module, exports) { + +exports.read = function (buffer, offset, isLE, mLen, nBytes) { + var e, m + var eLen = nBytes * 8 - mLen - 1 + var eMax = (1 << eLen) - 1 + var eBias = eMax >> 1 + var nBits = -7 + var i = isLE ? (nBytes - 1) : 0 + var d = isLE ? -1 : 1 + var s = buffer[offset + i] + + i += d + + e = s & ((1 << (-nBits)) - 1) + s >>= (-nBits) + nBits += eLen + for (; nBits > 0; e = e * 256 + buffer[offset + i], i += d, nBits -= 8) {} + + m = e & ((1 << (-nBits)) - 1) + e >>= (-nBits) + nBits += mLen + for (; nBits > 0; m = m * 256 + buffer[offset + i], i += d, nBits -= 8) {} + + if (e === 0) { + e = 1 - eBias + } else if (e === eMax) { + return m ? NaN : ((s ? -1 : 1) * Infinity) + } else { + m = m + Math.pow(2, mLen) + e = e - eBias + } + return (s ? -1 : 1) * m * Math.pow(2, e - mLen) +} + +exports.write = function (buffer, value, offset, isLE, mLen, nBytes) { + var e, m, c + var eLen = nBytes * 8 - mLen - 1 + var eMax = (1 << eLen) - 1 + var eBias = eMax >> 1 + var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0) + var i = isLE ? 0 : (nBytes - 1) + var d = isLE ? 1 : -1 + var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0 + + value = Math.abs(value) + + if (isNaN(value) || value === Infinity) { + m = isNaN(value) ? 1 : 0 + e = eMax + } else { + e = Math.floor(Math.log(value) / Math.LN2) + if (value * (c = Math.pow(2, -e)) < 1) { + e-- + c *= 2 + } + if (e + eBias >= 1) { + value += rt / c + } else { + value += rt * Math.pow(2, 1 - eBias) + } + if (value * c >= 2) { + e++ + c /= 2 + } + + if (e + eBias >= eMax) { + m = 0 + e = eMax + } else if (e + eBias >= 1) { + m = (value * c - 1) * Math.pow(2, mLen) + e = e + eBias + } else { + m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen) + e = 0 + } + } + + for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {} + + e = (e << mLen) | m + eLen += mLen + for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {} + + buffer[offset + i - d] |= s * 128 +} + + +/***/ }), +/* 335 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(336); + +/***/ }), +/* 336 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); +var bind = __webpack_require__(155); +var Axios = __webpack_require__(338); +var defaults = __webpack_require__(94); + +/** + * Create an instance of Axios + * + * @param {Object} defaultConfig The default config for the instance + * @return {Axios} A new instance of Axios + */ +function createInstance(defaultConfig) { + var context = new Axios(defaultConfig); + var instance = bind(Axios.prototype.request, context); + + // Copy axios.prototype to instance + utils.extend(instance, Axios.prototype, context); + + // Copy context to instance + utils.extend(instance, context); + + return instance; +} + +// Create the default instance to be exported +var axios = createInstance(defaults); + +// Expose Axios class to allow class inheritance +axios.Axios = Axios; + +// Factory for creating new instances +axios.create = function create(instanceConfig) { + return createInstance(utils.merge(defaults, instanceConfig)); +}; + +// Expose Cancel & CancelToken +axios.Cancel = __webpack_require__(159); +axios.CancelToken = __webpack_require__(352); +axios.isCancel = __webpack_require__(158); + +// Expose all/spread +axios.all = function all(promises) { + return Promise.all(promises); +}; +axios.spread = __webpack_require__(353); + +module.exports = axios; + +// Allow use of default import syntax in TypeScript +module.exports.default = axios; + + +/***/ }), +/* 337 */ +/***/ (function(module, exports) { + +/*! + * Determine if an object is a Buffer + * + * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> + * @license MIT + */ + +// The _isBuffer check is for Safari 5-7 support, because it's missing +// Object.prototype.constructor. Remove this eventually +module.exports = function (obj) { + return obj != null && (isBuffer(obj) || isSlowBuffer(obj) || !!obj._isBuffer) +} + +function isBuffer (obj) { + return !!obj.constructor && typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj) +} + +// For Node v0.10 support. Remove this eventually. +function isSlowBuffer (obj) { + return typeof obj.readFloatLE === 'function' && typeof obj.slice === 'function' && isBuffer(obj.slice(0, 0)) +} + + +/***/ }), +/* 338 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var defaults = __webpack_require__(94); +var utils = __webpack_require__(20); +var InterceptorManager = __webpack_require__(347); +var dispatchRequest = __webpack_require__(348); +var isAbsoluteURL = __webpack_require__(350); +var combineURLs = __webpack_require__(351); + +/** + * Create a new instance of Axios + * + * @param {Object} instanceConfig The default config for the instance + */ +function Axios(instanceConfig) { + this.defaults = instanceConfig; + this.interceptors = { + request: new InterceptorManager(), + response: new InterceptorManager() + }; +} + +/** + * Dispatch a request + * + * @param {Object} config The config specific for this request (merged with this.defaults) + */ +Axios.prototype.request = function request(config) { + /*eslint no-param-reassign:0*/ + // Allow for axios('example/url'[, config]) a la fetch API + if (typeof config === 'string') { + config = utils.merge({ + url: arguments[0] + }, arguments[1]); + } + + config = utils.merge(defaults, this.defaults, { method: 'get' }, config); + config.method = config.method.toLowerCase(); + + // Support baseURL config + if (config.baseURL && !isAbsoluteURL(config.url)) { + config.url = combineURLs(config.baseURL, config.url); + } + + // Hook up interceptors middleware + var chain = [dispatchRequest, undefined]; + var promise = Promise.resolve(config); + + this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) { + chain.unshift(interceptor.fulfilled, interceptor.rejected); + }); + + this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) { + chain.push(interceptor.fulfilled, interceptor.rejected); + }); + + while (chain.length) { + promise = promise.then(chain.shift(), chain.shift()); + } + + return promise; +}; + +// Provide aliases for supported request methods +utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url + })); + }; +}); + +utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, data, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url, + data: data + })); + }; +}); + +module.exports = Axios; + + +/***/ }), +/* 339 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +module.exports = function normalizeHeaderName(headers, normalizedName) { + utils.forEach(headers, function processHeader(value, name) { + if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) { + headers[normalizedName] = value; + delete headers[name]; + } + }); +}; + + +/***/ }), +/* 340 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var createError = __webpack_require__(157); + +/** + * Resolve or reject a Promise based on response status. + * + * @param {Function} resolve A function that resolves the promise. + * @param {Function} reject A function that rejects the promise. + * @param {object} response The response. + */ +module.exports = function settle(resolve, reject, response) { + var validateStatus = response.config.validateStatus; + // Note: status is not exposed by XDomainRequest + if (!response.status || !validateStatus || validateStatus(response.status)) { + resolve(response); + } else { + reject(createError( + 'Request failed with status code ' + response.status, + response.config, + null, + response.request, + response + )); + } +}; + + +/***/ }), +/* 341 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Update an Error with the specified config, error code, and response. + * + * @param {Error} error The error to update. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The error. + */ +module.exports = function enhanceError(error, config, code, request, response) { + error.config = config; + if (code) { + error.code = code; + } + error.request = request; + error.response = response; + return error; +}; + + +/***/ }), +/* 342 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +function encode(val) { + return encodeURIComponent(val). + replace(/%40/gi, '@'). + replace(/%3A/gi, ':'). + replace(/%24/g, '$'). + replace(/%2C/gi, ','). + replace(/%20/g, '+'). + replace(/%5B/gi, '['). + replace(/%5D/gi, ']'); +} + +/** + * Build a URL by appending params to the end + * + * @param {string} url The base of the url (e.g., http://www.google.com) + * @param {object} [params] The params to be appended + * @returns {string} The formatted url + */ +module.exports = function buildURL(url, params, paramsSerializer) { + /*eslint no-param-reassign:0*/ + if (!params) { + return url; + } + + var serializedParams; + if (paramsSerializer) { + serializedParams = paramsSerializer(params); + } else if (utils.isURLSearchParams(params)) { + serializedParams = params.toString(); + } else { + var parts = []; + + utils.forEach(params, function serialize(val, key) { + if (val === null || typeof val === 'undefined') { + return; + } + + if (utils.isArray(val)) { + key = key + '[]'; + } + + if (!utils.isArray(val)) { + val = [val]; + } + + utils.forEach(val, function parseValue(v) { + if (utils.isDate(v)) { + v = v.toISOString(); + } else if (utils.isObject(v)) { + v = JSON.stringify(v); + } + parts.push(encode(key) + '=' + encode(v)); + }); + }); + + serializedParams = parts.join('&'); + } + + if (serializedParams) { + url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams; + } + + return url; +}; + + +/***/ }), +/* 343 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +/** + * Parse headers into an object + * + * ``` + * Date: Wed, 27 Aug 2014 08:58:49 GMT + * Content-Type: application/json + * Connection: keep-alive + * Transfer-Encoding: chunked + * ``` + * + * @param {String} headers Headers needing to be parsed + * @returns {Object} Headers parsed into an object + */ +module.exports = function parseHeaders(headers) { + var parsed = {}; + var key; + var val; + var i; + + if (!headers) { return parsed; } + + utils.forEach(headers.split('\n'), function parser(line) { + i = line.indexOf(':'); + key = utils.trim(line.substr(0, i)).toLowerCase(); + val = utils.trim(line.substr(i + 1)); + + if (key) { + parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val; + } + }); + + return parsed; +}; + + +/***/ }), +/* 344 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +module.exports = ( + utils.isStandardBrowserEnv() ? + + // Standard browser envs have full support of the APIs needed to test + // whether the request URL is of the same origin as current location. + (function standardBrowserEnv() { + var msie = /(msie|trident)/i.test(navigator.userAgent); + var urlParsingNode = document.createElement('a'); + var originURL; + + /** + * Parse a URL to discover it's components + * + * @param {String} url The URL to be parsed + * @returns {Object} + */ + function resolveURL(url) { + var href = url; + + if (msie) { + // IE needs attribute set twice to normalize properties + urlParsingNode.setAttribute('href', href); + href = urlParsingNode.href; + } + + urlParsingNode.setAttribute('href', href); + + // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils + return { + href: urlParsingNode.href, + protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '', + host: urlParsingNode.host, + search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '', + hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '', + hostname: urlParsingNode.hostname, + port: urlParsingNode.port, + pathname: (urlParsingNode.pathname.charAt(0) === '/') ? + urlParsingNode.pathname : + '/' + urlParsingNode.pathname + }; + } + + originURL = resolveURL(window.location.href); + + /** + * Determine if a URL shares the same origin as the current location + * + * @param {String} requestURL The URL to test + * @returns {boolean} True if URL shares the same origin, otherwise false + */ + return function isURLSameOrigin(requestURL) { + var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL; + return (parsed.protocol === originURL.protocol && + parsed.host === originURL.host); + }; + })() : + + // Non standard browser envs (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return function isURLSameOrigin() { + return true; + }; + })() +); + + +/***/ }), +/* 345 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +// btoa polyfill for IE<10 courtesy https://github.com/davidchambers/Base64.js + +var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='; + +function E() { + this.message = 'String contains an invalid character'; +} +E.prototype = new Error; +E.prototype.code = 5; +E.prototype.name = 'InvalidCharacterError'; + +function btoa(input) { + var str = String(input); + var output = ''; + for ( + // initialize result and counter + var block, charCode, idx = 0, map = chars; + // if the next str index does not exist: + // change the mapping table to "=" + // check if d has no fractional digits + str.charAt(idx | 0) || (map = '=', idx % 1); + // "8 - idx % 1 * 8" generates the sequence 2, 4, 6, 8 + output += map.charAt(63 & block >> 8 - idx % 1 * 8) + ) { + charCode = str.charCodeAt(idx += 3 / 4); + if (charCode > 0xFF) { + throw new E(); + } + block = block << 8 | charCode; + } + return output; +} + +module.exports = btoa; + + +/***/ }), +/* 346 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +module.exports = ( + utils.isStandardBrowserEnv() ? + + // Standard browser envs support document.cookie + (function standardBrowserEnv() { + return { + write: function write(name, value, expires, path, domain, secure) { + var cookie = []; + cookie.push(name + '=' + encodeURIComponent(value)); + + if (utils.isNumber(expires)) { + cookie.push('expires=' + new Date(expires).toGMTString()); + } + + if (utils.isString(path)) { + cookie.push('path=' + path); + } + + if (utils.isString(domain)) { + cookie.push('domain=' + domain); + } + + if (secure === true) { + cookie.push('secure'); + } + + document.cookie = cookie.join('; '); + }, + + read: function read(name) { + var match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)')); + return (match ? decodeURIComponent(match[3]) : null); + }, + + remove: function remove(name) { + this.write(name, '', Date.now() - 86400000); + } + }; + })() : + + // Non standard browser env (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return { + write: function write() {}, + read: function read() { return null; }, + remove: function remove() {} + }; + })() +); + + +/***/ }), +/* 347 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +function InterceptorManager() { + this.handlers = []; +} + +/** + * Add a new interceptor to the stack + * + * @param {Function} fulfilled The function to handle `then` for a `Promise` + * @param {Function} rejected The function to handle `reject` for a `Promise` + * + * @return {Number} An ID used to remove interceptor later + */ +InterceptorManager.prototype.use = function use(fulfilled, rejected) { + this.handlers.push({ + fulfilled: fulfilled, + rejected: rejected + }); + return this.handlers.length - 1; +}; + +/** + * Remove an interceptor from the stack + * + * @param {Number} id The ID that was returned by `use` + */ +InterceptorManager.prototype.eject = function eject(id) { + if (this.handlers[id]) { + this.handlers[id] = null; + } +}; + +/** + * Iterate over all the registered interceptors + * + * This method is particularly useful for skipping over any + * interceptors that may have become `null` calling `eject`. + * + * @param {Function} fn The function to call for each interceptor + */ +InterceptorManager.prototype.forEach = function forEach(fn) { + utils.forEach(this.handlers, function forEachHandler(h) { + if (h !== null) { + fn(h); + } + }); +}; + +module.exports = InterceptorManager; + + +/***/ }), +/* 348 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); +var transformData = __webpack_require__(349); +var isCancel = __webpack_require__(158); +var defaults = __webpack_require__(94); + +/** + * Throws a `Cancel` if cancellation has been requested. + */ +function throwIfCancellationRequested(config) { + if (config.cancelToken) { + config.cancelToken.throwIfRequested(); + } +} + +/** + * Dispatch a request to the server using the configured adapter. + * + * @param {object} config The config that is to be used for the request + * @returns {Promise} The Promise to be fulfilled + */ +module.exports = function dispatchRequest(config) { + throwIfCancellationRequested(config); + + // Ensure headers exist + config.headers = config.headers || {}; + + // Transform request data + config.data = transformData( + config.data, + config.headers, + config.transformRequest + ); + + // Flatten headers + config.headers = utils.merge( + config.headers.common || {}, + config.headers[config.method] || {}, + config.headers || {} + ); + + utils.forEach( + ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], + function cleanHeaderConfig(method) { + delete config.headers[method]; + } + ); + + var adapter = config.adapter || defaults.adapter; + + return adapter(config).then(function onAdapterResolution(response) { + throwIfCancellationRequested(config); + + // Transform response data + response.data = transformData( + response.data, + response.headers, + config.transformResponse + ); + + return response; + }, function onAdapterRejection(reason) { + if (!isCancel(reason)) { + throwIfCancellationRequested(config); + + // Transform response data + if (reason && reason.response) { + reason.response.data = transformData( + reason.response.data, + reason.response.headers, + config.transformResponse + ); + } + } + + return Promise.reject(reason); + }); +}; + + +/***/ }), +/* 349 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +/** + * Transform the data for a request or a response + * + * @param {Object|String} data The data to be transformed + * @param {Array} headers The headers for the request or response + * @param {Array|Function} fns A single function or Array of functions + * @returns {*} The resulting transformed data + */ +module.exports = function transformData(data, headers, fns) { + /*eslint no-param-reassign:0*/ + utils.forEach(fns, function transform(fn) { + data = fn(data, headers); + }); + + return data; +}; + + +/***/ }), +/* 350 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Determines whether the specified URL is absolute + * + * @param {string} url The URL to test + * @returns {boolean} True if the specified URL is absolute, otherwise false + */ +module.exports = function isAbsoluteURL(url) { + // A URL is considered absolute if it begins with "<scheme>://" or "//" (protocol-relative URL). + // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed + // by any combination of letters, digits, plus, period, or hyphen. + return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url); +}; + + +/***/ }), +/* 351 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Creates a new URL by combining the specified URLs + * + * @param {string} baseURL The base URL + * @param {string} relativeURL The relative URL + * @returns {string} The combined URL + */ +module.exports = function combineURLs(baseURL, relativeURL) { + return relativeURL + ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '') + : baseURL; +}; + + +/***/ }), +/* 352 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var Cancel = __webpack_require__(159); + +/** + * A `CancelToken` is an object that can be used to request cancellation of an operation. + * + * @class + * @param {Function} executor The executor function. + */ +function CancelToken(executor) { + if (typeof executor !== 'function') { + throw new TypeError('executor must be a function.'); + } + + var resolvePromise; + this.promise = new Promise(function promiseExecutor(resolve) { + resolvePromise = resolve; + }); + + var token = this; + executor(function cancel(message) { + if (token.reason) { + // Cancellation has already been requested + return; + } + + token.reason = new Cancel(message); + resolvePromise(token.reason); + }); +} + +/** + * Throws a `Cancel` if cancellation has been requested. + */ +CancelToken.prototype.throwIfRequested = function throwIfRequested() { + if (this.reason) { + throw this.reason; + } +}; + +/** + * Returns an object that contains a new `CancelToken` and a function that, when called, + * cancels the `CancelToken`. + */ +CancelToken.source = function source() { + var cancel; + var token = new CancelToken(function executor(c) { + cancel = c; + }); + return { + token: token, + cancel: cancel + }; +}; + +module.exports = CancelToken; + + +/***/ }), +/* 353 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Syntactic sugar for invoking a function and expanding an array for arguments. + * + * Common use case would be to use `Function.prototype.apply`. + * + * ```js + * function f(x, y, z) {} + * var args = [1, 2, 3]; + * f.apply(null, args); + * ``` + * + * With `spread` this example can be re-written. + * + * ```js + * spread(function(x, y, z) {})([1, 2, 3]); + * ``` + * + * @param {Function} callback + * @returns {Function} + */ +module.exports = function spread(callback) { + return function wrap(arr) { + return callback.apply(null, arr); + }; +}; + + +/***/ }), +/* 354 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var _require = __webpack_require__(355), + CopyToClipboard = _require.CopyToClipboard; + +module.exports = CopyToClipboard; + +/***/ }), +/* 355 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.CopyToClipboard = undefined; + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _copyToClipboard = __webpack_require__(356); + +var _copyToClipboard2 = _interopRequireDefault(_copyToClipboard); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var CopyToClipboard = exports.CopyToClipboard = function (_React$PureComponent) { + _inherits(CopyToClipboard, _React$PureComponent); + + function CopyToClipboard() { + var _ref; + + var _temp, _this, _ret; + + _classCallCheck(this, CopyToClipboard); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = CopyToClipboard.__proto__ || Object.getPrototypeOf(CopyToClipboard)).call.apply(_ref, [this].concat(args))), _this), _this.onClick = function (event) { + var _this$props = _this.props, + text = _this$props.text, + onCopy = _this$props.onCopy, + children = _this$props.children, + options = _this$props.options; + + + var elem = _react2.default.Children.only(children); + + var result = (0, _copyToClipboard2.default)(text, options); + + if (onCopy) { + onCopy(text, result); + } + + // Bypass onClick if it was present + if (elem && elem.props && typeof elem.props.onClick === 'function') { + elem.props.onClick(event); + } + }, _temp), _possibleConstructorReturn(_this, _ret); + } + + _createClass(CopyToClipboard, [{ + key: 'render', + value: function render() { + var _props = this.props, + _text = _props.text, + _onCopy = _props.onCopy, + _options = _props.options, + children = _props.children, + props = _objectWithoutProperties(_props, ['text', 'onCopy', 'options', 'children']); + + var elem = _react2.default.Children.only(children); + + return _react2.default.cloneElement(elem, _extends({}, props, { onClick: this.onClick })); + } + }]); + + return CopyToClipboard; +}(_react2.default.PureComponent); + +/***/ }), +/* 356 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var deselectCurrent = __webpack_require__(357); + +var defaultMessage = 'Copy to clipboard: #{key}, Enter'; + +function format(message) { + var copyKey = (/mac os x/i.test(navigator.userAgent) ? '⌘' : 'Ctrl') + '+C'; + return message.replace(/#{\s*key\s*}/g, copyKey); +} + +function copy(text, options) { + var debug, message, reselectPrevious, range, selection, mark, success = false; + if (!options) { options = {}; } + debug = options.debug || false; + try { + reselectPrevious = deselectCurrent(); + + range = document.createRange(); + selection = document.getSelection(); + + mark = document.createElement('span'); + mark.textContent = text; + // reset user styles for span element + mark.style.all = 'unset'; + // prevents scrolling to the end of the page + mark.style.position = 'fixed'; + mark.style.top = 0; + mark.style.clip = 'rect(0, 0, 0, 0)'; + // used to preserve spaces and line breaks + mark.style.whiteSpace = 'pre'; + // do not inherit user-select (it may be `none`) + mark.style.webkitUserSelect = 'text'; + mark.style.MozUserSelect = 'text'; + mark.style.msUserSelect = 'text'; + mark.style.userSelect = 'text'; + + document.body.appendChild(mark); + + range.selectNode(mark); + selection.addRange(range); + + var successful = document.execCommand('copy'); + if (!successful) { + throw new Error('copy command was unsuccessful'); + } + success = true; + } catch (err) { + debug && console.error('unable to copy using execCommand: ', err); + debug && console.warn('trying IE specific stuff'); + try { + window.clipboardData.setData('text', text); + success = true; + } catch (err) { + debug && console.error('unable to copy using clipboardData: ', err); + debug && console.error('falling back to prompt'); + message = format('message' in options ? options.message : defaultMessage); + window.prompt(message, text); + } + } finally { + if (selection) { + if (typeof selection.removeRange == 'function') { + selection.removeRange(range); + } else { + selection.removeAllRanges(); + } + } + + if (mark) { + document.body.removeChild(mark); + } + reselectPrevious(); + } + + return success; +} + +module.exports = copy; + + +/***/ }), +/* 357 */ +/***/ (function(module, exports) { + + +module.exports = function () { + var selection = document.getSelection(); + if (!selection.rangeCount) { + return function () {}; + } + var active = document.activeElement; + + var ranges = []; + for (var i = 0; i < selection.rangeCount; i++) { + ranges.push(selection.getRangeAt(i)); + } + + switch (active.tagName.toUpperCase()) { // .toUpperCase handles XHTML + case 'INPUT': + case 'TEXTAREA': + active.blur(); + break; + + default: + active = null; + break; + } + + selection.removeAllRanges(); + return function () { + selection.type === 'Caret' && + selection.removeAllRanges(); + + if (!selection.rangeCount) { + ranges.forEach(function(range) { + selection.addRange(range); + }); + } + + active && + active.focus(); + }; +}; + + +/***/ }), +/* 358 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.ReactTableDefaults = undefined; + +var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _classnames = __webpack_require__(41); + +var _classnames2 = _interopRequireDefault(_classnames); + +var _utils = __webpack_require__(95); + +var _utils2 = _interopRequireDefault(_utils); + +var _lifecycle = __webpack_require__(359); + +var _lifecycle2 = _interopRequireDefault(_lifecycle); + +var _methods = __webpack_require__(360); + +var _methods2 = _interopRequireDefault(_methods); + +var _defaultProps = __webpack_require__(361); + +var _defaultProps2 = _interopRequireDefault(_defaultProps); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +// + + +var ReactTableDefaults = exports.ReactTableDefaults = _defaultProps2.default; + +var ReactTable = function (_Methods) { + _inherits(ReactTable, _Methods); + + function ReactTable(props) { + _classCallCheck(this, ReactTable); + + var _this = _possibleConstructorReturn(this, (ReactTable.__proto__ || Object.getPrototypeOf(ReactTable)).call(this)); + + _this.getResolvedState = _this.getResolvedState.bind(_this); + _this.getDataModel = _this.getDataModel.bind(_this); + _this.getSortedData = _this.getSortedData.bind(_this); + _this.fireFetchData = _this.fireFetchData.bind(_this); + _this.getPropOrState = _this.getPropOrState.bind(_this); + _this.getStateOrProp = _this.getStateOrProp.bind(_this); + _this.filterData = _this.filterData.bind(_this); + _this.sortData = _this.sortData.bind(_this); + _this.getMinRows = _this.getMinRows.bind(_this); + _this.onPageChange = _this.onPageChange.bind(_this); + _this.onPageSizeChange = _this.onPageSizeChange.bind(_this); + _this.sortColumn = _this.sortColumn.bind(_this); + _this.filterColumn = _this.filterColumn.bind(_this); + _this.resizeColumnStart = _this.resizeColumnStart.bind(_this); + _this.resizeColumnEnd = _this.resizeColumnEnd.bind(_this); + _this.resizeColumnMoving = _this.resizeColumnMoving.bind(_this); + + _this.state = { + page: 0, + pageSize: props.defaultPageSize, + sorted: props.defaultSorted, + expanded: props.defaultExpanded, + filtered: props.defaultFiltered, + resized: props.defaultResized, + currentlyResizing: false, + skipNextSort: false + }; + return _this; + } + + _createClass(ReactTable, [{ + key: 'render', + value: function render() { + var _this2 = this; + + var resolvedState = this.getResolvedState(); + var children = resolvedState.children, + className = resolvedState.className, + style = resolvedState.style, + getProps = resolvedState.getProps, + getTableProps = resolvedState.getTableProps, + getTheadGroupProps = resolvedState.getTheadGroupProps, + getTheadGroupTrProps = resolvedState.getTheadGroupTrProps, + getTheadGroupThProps = resolvedState.getTheadGroupThProps, + getTheadProps = resolvedState.getTheadProps, + getTheadTrProps = resolvedState.getTheadTrProps, + getTheadThProps = resolvedState.getTheadThProps, + getTheadFilterProps = resolvedState.getTheadFilterProps, + getTheadFilterTrProps = resolvedState.getTheadFilterTrProps, + getTheadFilterThProps = resolvedState.getTheadFilterThProps, + getTbodyProps = resolvedState.getTbodyProps, + getTrGroupProps = resolvedState.getTrGroupProps, + getTrProps = resolvedState.getTrProps, + getTdProps = resolvedState.getTdProps, + getTfootProps = resolvedState.getTfootProps, + getTfootTrProps = resolvedState.getTfootTrProps, + getTfootTdProps = resolvedState.getTfootTdProps, + getPaginationProps = resolvedState.getPaginationProps, + getLoadingProps = resolvedState.getLoadingProps, + getNoDataProps = resolvedState.getNoDataProps, + getResizerProps = resolvedState.getResizerProps, + showPagination = resolvedState.showPagination, + showPaginationTop = resolvedState.showPaginationTop, + showPaginationBottom = resolvedState.showPaginationBottom, + manual = resolvedState.manual, + loadingText = resolvedState.loadingText, + noDataText = resolvedState.noDataText, + sortable = resolvedState.sortable, + resizable = resolvedState.resizable, + filterable = resolvedState.filterable, + pivotIDKey = resolvedState.pivotIDKey, + pivotValKey = resolvedState.pivotValKey, + pivotBy = resolvedState.pivotBy, + subRowsKey = resolvedState.subRowsKey, + aggregatedKey = resolvedState.aggregatedKey, + originalKey = resolvedState.originalKey, + indexKey = resolvedState.indexKey, + groupedByPivotKey = resolvedState.groupedByPivotKey, + loading = resolvedState.loading, + pageSize = resolvedState.pageSize, + page = resolvedState.page, + sorted = resolvedState.sorted, + filtered = resolvedState.filtered, + resized = resolvedState.resized, + expanded = resolvedState.expanded, + pages = resolvedState.pages, + onExpandedChange = resolvedState.onExpandedChange, + TableComponent = resolvedState.TableComponent, + TheadComponent = resolvedState.TheadComponent, + TbodyComponent = resolvedState.TbodyComponent, + TrGroupComponent = resolvedState.TrGroupComponent, + TrComponent = resolvedState.TrComponent, + ThComponent = resolvedState.ThComponent, + TdComponent = resolvedState.TdComponent, + TfootComponent = resolvedState.TfootComponent, + PaginationComponent = resolvedState.PaginationComponent, + LoadingComponent = resolvedState.LoadingComponent, + SubComponent = resolvedState.SubComponent, + NoDataComponent = resolvedState.NoDataComponent, + ResizerComponent = resolvedState.ResizerComponent, + ExpanderComponent = resolvedState.ExpanderComponent, + PivotValueComponent = resolvedState.PivotValueComponent, + PivotComponent = resolvedState.PivotComponent, + AggregatedComponent = resolvedState.AggregatedComponent, + FilterComponent = resolvedState.FilterComponent, + PadRowComponent = resolvedState.PadRowComponent, + resolvedData = resolvedState.resolvedData, + allVisibleColumns = resolvedState.allVisibleColumns, + headerGroups = resolvedState.headerGroups, + hasHeaderGroups = resolvedState.hasHeaderGroups, + sortedData = resolvedState.sortedData, + currentlyResizing = resolvedState.currentlyResizing; + + // Pagination + + var startRow = pageSize * page; + var endRow = startRow + pageSize; + var pageRows = manual ? resolvedData : sortedData.slice(startRow, endRow); + var minRows = this.getMinRows(); + var padRows = _utils2.default.range(Math.max(minRows - pageRows.length, 0)); + + var hasColumnFooter = allVisibleColumns.some(function (d) { + return d.Footer; + }); + var hasFilters = filterable || allVisibleColumns.some(function (d) { + return d.filterable; + }); + + var recurseRowsViewIndex = function recurseRowsViewIndex(rows) { + var path = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : []; + var index = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : -1; + + return [rows.map(function (row, i) { + index++; + var rowWithViewIndex = _extends({}, row, { + _viewIndex: index + }); + var newPath = path.concat([i]); + if (rowWithViewIndex[subRowsKey] && _utils2.default.get(expanded, newPath)) { + ; + var _recurseRowsViewIndex = recurseRowsViewIndex(rowWithViewIndex[subRowsKey], newPath, index); + + var _recurseRowsViewIndex2 = _slicedToArray(_recurseRowsViewIndex, 2); + + rowWithViewIndex[subRowsKey] = _recurseRowsViewIndex2[0]; + index = _recurseRowsViewIndex2[1]; + } + return rowWithViewIndex; + }), index]; + }; + var _recurseRowsViewIndex3 = recurseRowsViewIndex(pageRows); + + var _recurseRowsViewIndex4 = _slicedToArray(_recurseRowsViewIndex3, 1); + + pageRows = _recurseRowsViewIndex4[0]; + + + var canPrevious = page > 0; + var canNext = page + 1 < pages; + + var rowMinWidth = _utils2.default.sum(allVisibleColumns.map(function (d) { + var resizedColumn = resized.find(function (x) { + return x.id === d.id; + }) || {}; + return _utils2.default.getFirstDefined(resizedColumn.value, d.width, d.minWidth); + })); + + var rowIndex = -1; + + var finalState = _extends({}, resolvedState, { + startRow: startRow, + endRow: endRow, + pageRows: pageRows, + minRows: minRows, + padRows: padRows, + hasColumnFooter: hasColumnFooter, + canPrevious: canPrevious, + canNext: canNext, + rowMinWidth: rowMinWidth + }); + + // Visual Components + + var makeHeaderGroups = function makeHeaderGroups() { + var theadGroupProps = _utils2.default.splitProps(getTheadGroupProps(finalState, undefined, undefined, _this2)); + var theadGroupTrProps = _utils2.default.splitProps(getTheadGroupTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-headerGroups', theadGroupProps.className), + style: _extends({}, theadGroupProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadGroupProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadGroupTrProps.className, + style: theadGroupTrProps.style + }, theadGroupTrProps.rest), + headerGroups.map(makeHeaderGroup) + ) + ); + }; + + var makeHeaderGroup = function makeHeaderGroup(column, i) { + var resizedValue = function resizedValue(col) { + return (resized.find(function (x) { + return x.id === col.id; + }) || {}).value; + }; + var flex = _utils2.default.sum(column.columns.map(function (col) { + return col.width || resizedValue(col) ? 0 : col.minWidth; + })); + var width = _utils2.default.sum(column.columns.map(function (col) { + return _utils2.default.getFirstDefined(resizedValue(col), col.width, col.minWidth); + })); + var maxWidth = _utils2.default.sum(column.columns.map(function (col) { + return _utils2.default.getFirstDefined(resizedValue(col), col.width, col.maxWidth); + })); + + var theadGroupThProps = _utils2.default.splitProps(getTheadGroupThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); + + var classes = [column.headerClassName, theadGroupThProps.className, columnHeaderProps.className]; + + var styles = _extends({}, column.headerStyle, theadGroupThProps.style, columnHeaderProps.style); + + var rest = _extends({}, theadGroupThProps.rest, columnHeaderProps.rest); + + var flexStyles = { + flex: flex + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }; + + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes), + style: _extends({}, styles, flexStyles) + }, rest), + _utils2.default.normalizeComponent(column.Header, { + data: sortedData, + column: column + }) + ); + }; + + var makeHeaders = function makeHeaders() { + var theadProps = _utils2.default.splitProps(getTheadProps(finalState, undefined, undefined, _this2)); + var theadTrProps = _utils2.default.splitProps(getTheadTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-header', theadProps.className), + style: _extends({}, theadProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadTrProps.className, + style: theadTrProps.style + }, theadTrProps.rest), + allVisibleColumns.map(makeHeader) + ) + ); + }; + + var makeHeader = function makeHeader(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var sort = sorted.find(function (d) { + return d.id === column.id; + }); + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var theadThProps = _utils2.default.splitProps(getTheadThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); + + var classes = [column.headerClassName, theadThProps.className, columnHeaderProps.className]; + + var styles = _extends({}, column.headerStyle, theadThProps.style, columnHeaderProps.style); + + var rest = _extends({}, theadThProps.rest, columnHeaderProps.rest); + + var isResizable = _utils2.default.getFirstDefined(column.resizable, resizable, false); + var resizer = isResizable ? _react2.default.createElement(ResizerComponent, _extends({ + onMouseDown: function onMouseDown(e) { + return _this2.resizeColumnStart(e, column, false); + }, + onTouchStart: function onTouchStart(e) { + return _this2.resizeColumnStart(e, column, true); + } + }, resizerProps)) : null; + + var isSortable = _utils2.default.getFirstDefined(column.sortable, sortable, false); + + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, 'rt-resizable-header', sort ? sort.desc ? '-sort-desc' : '-sort-asc' : '', isSortable && '-cursor-pointer', !show && '-hidden', pivotBy && pivotBy.slice(0, -1).includes(column.id) && 'rt-header-pivot'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }), + toggleSort: function toggleSort(e) { + isSortable && _this2.sortColumn(column, e.shiftKey); + } + }, rest), + _react2.default.createElement( + 'div', + { className: 'rt-resizable-header-content' }, + _utils2.default.normalizeComponent(column.Header, { + data: sortedData, + column: column + }) + ), + resizer + ); + }; + + var makeFilters = function makeFilters() { + var theadFilterProps = _utils2.default.splitProps(getTheadFilterProps(finalState, undefined, undefined, _this2)); + var theadFilterTrProps = _utils2.default.splitProps(getTheadFilterTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-filters', theadFilterProps.className), + style: _extends({}, theadFilterProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadFilterProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadFilterTrProps.className, + style: theadFilterTrProps.style + }, theadFilterTrProps.rest), + allVisibleColumns.map(makeFilter) + ) + ); + }; + + var makeFilter = function makeFilter(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var theadFilterThProps = _utils2.default.splitProps(getTheadFilterThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); + + var classes = [column.headerClassName, theadFilterThProps.className, columnHeaderProps.className]; + + var styles = _extends({}, column.headerStyle, theadFilterThProps.style, columnHeaderProps.style); + + var rest = _extends({}, theadFilterThProps.rest, columnHeaderProps.rest); + + var filter = filtered.find(function (filter) { + return filter.id === column.id; + }); + + var ResolvedFilterComponent = column.Filter || FilterComponent; + + var isFilterable = _utils2.default.getFirstDefined(column.filterable, filterable, false); + + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, rest), + isFilterable ? _utils2.default.normalizeComponent(ResolvedFilterComponent, { + column: column, + filter: filter, + onChange: function onChange(value) { + return _this2.filterColumn(column, value); + } + }, _defaultProps2.default.column.Filter) : null + ); + }; + + var makePageRow = function makePageRow(row, i) { + var path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : []; + + var rowInfo = { + original: row[originalKey], + row: row, + index: row[indexKey], + viewIndex: ++rowIndex, + level: path.length, + nestingPath: path.concat([i]), + aggregated: row[aggregatedKey], + groupedByPivot: row[groupedByPivotKey], + subRows: row[subRowsKey] + }; + var isExpanded = _utils2.default.get(expanded, rowInfo.nestingPath); + var trGroupProps = getTrGroupProps(finalState, rowInfo, undefined, _this2); + var trProps = _utils2.default.splitProps(getTrProps(finalState, rowInfo, undefined, _this2)); + return _react2.default.createElement( + TrGroupComponent, + _extends({ key: rowInfo.nestingPath.join('_') }, trGroupProps), + _react2.default.createElement( + TrComponent, + _extends({ + className: (0, _classnames2.default)(trProps.className, row._viewIndex % 2 ? '-even' : '-odd'), + style: trProps.style + }, trProps.rest), + allVisibleColumns.map(function (column, i2) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tdProps = _utils2.default.splitProps(getTdProps(finalState, rowInfo, column, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, rowInfo, column, _this2)); + + var classes = [tdProps.className, column.className, columnProps.className]; + + var styles = _extends({}, tdProps.style, column.style, columnProps.style); + + var cellInfo = _extends({}, rowInfo, { + isExpanded: isExpanded, + column: _extends({}, column), + value: rowInfo.row[column.id], + pivoted: column.pivoted, + expander: column.expander, + resized: resized, + show: show, + width: width, + maxWidth: maxWidth, + tdProps: tdProps, + columnProps: columnProps, + classes: classes, + styles: styles + }); + + var value = cellInfo.value; + + var useOnExpanderClick = void 0; + var isBranch = void 0; + var isPreview = void 0; + + var onExpanderClick = function onExpanderClick(e) { + var newExpanded = _utils2.default.clone(expanded); + if (isExpanded) { + newExpanded = _utils2.default.set(newExpanded, cellInfo.nestingPath, false); + } else { + newExpanded = _utils2.default.set(newExpanded, cellInfo.nestingPath, {}); + } + + return _this2.setStateWithData({ + expanded: newExpanded + }, function () { + onExpandedChange && onExpandedChange(newExpanded, cellInfo.nestingPath, e); + }); + }; + + // Default to a standard cell + var resolvedCell = _utils2.default.normalizeComponent(column.Cell, cellInfo, value); + + // Resolve Renderers + var ResolvedAggregatedComponent = column.Aggregated || (!column.aggregate ? AggregatedComponent : column.Cell); + var ResolvedExpanderComponent = column.Expander || ExpanderComponent; + var ResolvedPivotValueComponent = column.PivotValue || PivotValueComponent; + var DefaultResolvedPivotComponent = PivotComponent || function (props) { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement(ResolvedExpanderComponent, props), + _react2.default.createElement(ResolvedPivotValueComponent, props) + ); + }; + var ResolvedPivotComponent = column.Pivot || DefaultResolvedPivotComponent; + + // Is this cell expandable? + if (cellInfo.pivoted || cellInfo.expander) { + // Make it expandable by defualt + cellInfo.expandable = true; + useOnExpanderClick = true; + // If pivoted, has no subRows, and does not have a subComponent, do not make expandable + if (cellInfo.pivoted && !cellInfo.subRows && !SubComponent) { + cellInfo.expandable = false; + } + } + + if (cellInfo.pivoted) { + // Is this column a branch? + isBranch = rowInfo.row[pivotIDKey] === column.id && cellInfo.subRows; + // Should this column be blank? + isPreview = pivotBy.indexOf(column.id) > pivotBy.indexOf(rowInfo.row[pivotIDKey]) && cellInfo.subRows; + // Pivot Cell Render Override + if (isBranch) { + // isPivot + resolvedCell = _utils2.default.normalizeComponent(ResolvedPivotComponent, _extends({}, cellInfo, { + value: row[pivotValKey] + }), row[pivotValKey]); + } else if (isPreview) { + // Show the pivot preview + resolvedCell = _utils2.default.normalizeComponent(ResolvedAggregatedComponent, cellInfo, value); + } else { + resolvedCell = null; + } + } else if (cellInfo.aggregated) { + resolvedCell = _utils2.default.normalizeComponent(ResolvedAggregatedComponent, cellInfo, value); + } + + if (cellInfo.expander) { + resolvedCell = _utils2.default.normalizeComponent(ResolvedExpanderComponent, cellInfo, row[pivotValKey]); + if (pivotBy) { + if (cellInfo.groupedByPivot) { + resolvedCell = null; + } + if (!cellInfo.subRows && !SubComponent) { + resolvedCell = null; + } + } + } + + var resolvedOnExpanderClick = useOnExpanderClick ? onExpanderClick : function () {}; + + // If there are multiple onClick events, make sure they don't override eachother. This should maybe be expanded to handle all function attributes + var interactionProps = { + onClick: resolvedOnExpanderClick + }; + + if (tdProps.rest.onClick) { + interactionProps.onClick = function (e) { + tdProps.rest.onClick(e, function () { + return resolvedOnExpanderClick(e); + }); + }; + } + + if (columnProps.rest.onClick) { + interactionProps.onClick = function (e) { + columnProps.rest.onClick(e, function () { + return resolvedOnExpanderClick(e); + }); + }; + } + + // Return the cell + return _react2.default.createElement( + TdComponent, + _extends({ + key: i2 + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden', cellInfo.expandable && 'rt-expandable', (isBranch || isPreview) && 'rt-pivot'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, tdProps.rest, columnProps.rest, interactionProps), + resolvedCell + ); + }) + ), + rowInfo.subRows && isExpanded && rowInfo.subRows.map(function (d, i) { + return makePageRow(d, i, rowInfo.nestingPath); + }), + SubComponent && !rowInfo.subRows && isExpanded && SubComponent(rowInfo) + ); + }; + + var makePadRow = function makePadRow(row, i) { + var trGroupProps = getTrGroupProps(finalState, undefined, undefined, _this2); + var trProps = _utils2.default.splitProps(getTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TrGroupComponent, + _extends({ key: i }, trGroupProps), + _react2.default.createElement( + TrComponent, + { + className: (0, _classnames2.default)('-padRow', (pageRows.length + i) % 2 ? '-even' : '-odd', trProps.className), + style: trProps.style || {} + }, + allVisibleColumns.map(makePadColumn) + ) + ); + }; + + var makePadColumn = function makePadColumn(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var flex = width; + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tdProps = _utils2.default.splitProps(getTdProps(finalState, undefined, column, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, undefined, column, _this2)); + + var classes = [tdProps.className, column.className, columnProps.className]; + + var styles = _extends({}, tdProps.style, column.style, columnProps.style); + + return _react2.default.createElement( + TdComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden'), + style: _extends({}, styles, { + flex: flex + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, tdProps.rest), + _utils2.default.normalizeComponent(PadRowComponent) + ); + }; + + var makeColumnFooters = function makeColumnFooters() { + var tFootProps = getTfootProps(finalState, undefined, undefined, _this2); + var tFootTrProps = _utils2.default.splitProps(getTfootTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TfootComponent, + _extends({ + className: tFootProps.className, + style: _extends({}, tFootProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, tFootProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: (0, _classnames2.default)(tFootTrProps.className), + style: tFootTrProps.style + }, tFootTrProps.rest), + allVisibleColumns.map(makeColumnFooter) + ) + ); + }; + + var makeColumnFooter = function makeColumnFooter(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tFootTdProps = _utils2.default.splitProps(getTfootTdProps(finalState, undefined, undefined, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, undefined, column, _this2)); + var columnFooterProps = _utils2.default.splitProps(column.getFooterProps(finalState, undefined, column, _this2)); + + var classes = [tFootTdProps.className, column.className, columnProps.className, columnFooterProps.className]; + + var styles = _extends({}, tFootTdProps.style, column.style, columnProps.style, columnFooterProps.style); + + return _react2.default.createElement( + TdComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, columnProps.rest, tFootTdProps.rest, columnFooterProps.rest), + _utils2.default.normalizeComponent(column.Footer, { + data: sortedData, + column: column + }) + ); + }; + + var makePagination = function makePagination() { + var paginationProps = _utils2.default.splitProps(getPaginationProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement(PaginationComponent, _extends({}, resolvedState, { + pages: pages, + canPrevious: canPrevious, + canNext: canNext, + onPageChange: _this2.onPageChange, + onPageSizeChange: _this2.onPageSizeChange, + className: paginationProps.className, + style: paginationProps.style + }, paginationProps.rest)); + }; + + var rootProps = _utils2.default.splitProps(getProps(finalState, undefined, undefined, this)); + var tableProps = _utils2.default.splitProps(getTableProps(finalState, undefined, undefined, this)); + var tBodyProps = _utils2.default.splitProps(getTbodyProps(finalState, undefined, undefined, this)); + var loadingProps = getLoadingProps(finalState, undefined, undefined, this); + var noDataProps = getNoDataProps(finalState, undefined, undefined, this); + var resizerProps = getResizerProps(finalState, undefined, undefined, this); + + var makeTable = function makeTable() { + var pagination = makePagination(); + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)('ReactTable', className, rootProps.className), + style: _extends({}, style, rootProps.style) + }, rootProps.rest), + showPagination && showPaginationTop ? _react2.default.createElement( + 'div', + { className: 'pagination-top' }, + pagination + ) : null, + _react2.default.createElement( + TableComponent, + _extends({ + className: (0, _classnames2.default)(tableProps.className, currentlyResizing ? 'rt-resizing' : ''), + style: tableProps.style + }, tableProps.rest), + hasHeaderGroups ? makeHeaderGroups() : null, + makeHeaders(), + hasFilters ? makeFilters() : null, + _react2.default.createElement( + TbodyComponent, + _extends({ + className: (0, _classnames2.default)(tBodyProps.className), + style: _extends({}, tBodyProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, tBodyProps.rest), + pageRows.map(function (d, i) { + return makePageRow(d, i); + }), + padRows.map(makePadRow) + ), + hasColumnFooter ? makeColumnFooters() : null + ), + showPagination && showPaginationBottom ? _react2.default.createElement( + 'div', + { className: 'pagination-bottom' }, + pagination + ) : null, + !pageRows.length && _react2.default.createElement( + NoDataComponent, + noDataProps, + _utils2.default.normalizeComponent(noDataText) + ), + _react2.default.createElement(LoadingComponent, _extends({ + loading: loading, + loadingText: loadingText + }, loadingProps)) + ); + }; + + // childProps are optionally passed to a function-as-a-child + return children ? children(finalState, makeTable, this) : makeTable(); + } + }]); + + return ReactTable; +}((0, _methods2.default)((0, _lifecycle2.default)(_react.Component))); + +ReactTable.defaultProps = _defaultProps2.default; +exports.default = ReactTable; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC5qcyJdLCJuYW1lcyI6WyJSZWFjdFRhYmxlRGVmYXVsdHMiLCJSZWFjdFRhYmxlIiwicHJvcHMiLCJnZXRSZXNvbHZlZFN0YXRlIiwiYmluZCIsImdldERhdGFNb2RlbCIsImdldFNvcnRlZERhdGEiLCJmaXJlRmV0Y2hEYXRhIiwiZ2V0UHJvcE9yU3RhdGUiLCJnZXRTdGF0ZU9yUHJvcCIsImZpbHRlckRhdGEiLCJzb3J0RGF0YSIsImdldE1pblJvd3MiLCJvblBhZ2VDaGFuZ2UiLCJvblBhZ2VTaXplQ2hhbmdlIiwic29ydENvbHVtbiIsImZpbHRlckNvbHVtbiIsInJlc2l6ZUNvbHVtblN0YXJ0IiwicmVzaXplQ29sdW1uRW5kIiwicmVzaXplQ29sdW1uTW92aW5nIiwic3RhdGUiLCJwYWdlIiwicGFnZVNpemUiLCJkZWZhdWx0UGFnZVNpemUiLCJzb3J0ZWQiLCJkZWZhdWx0U29ydGVkIiwiZXhwYW5kZWQiLCJkZWZhdWx0RXhwYW5kZWQiLCJmaWx0ZXJlZCIsImRlZmF1bHRGaWx0ZXJlZCIsInJlc2l6ZWQiLCJkZWZhdWx0UmVzaXplZCIsImN1cnJlbnRseVJlc2l6aW5nIiwic2tpcE5leHRTb3J0IiwicmVzb2x2ZWRTdGF0ZSIsImNoaWxkcmVuIiwiY2xhc3NOYW1lIiwic3R5bGUiLCJnZXRQcm9wcyIsImdldFRhYmxlUHJvcHMiLCJnZXRUaGVhZEdyb3VwUHJvcHMiLCJnZXRUaGVhZEdyb3VwVHJQcm9wcyIsImdldFRoZWFkR3JvdXBUaFByb3BzIiwiZ2V0VGhlYWRQcm9wcyIsImdldFRoZWFkVHJQcm9wcyIsImdldFRoZWFkVGhQcm9wcyIsImdldFRoZWFkRmlsdGVyUHJvcHMiLCJnZXRUaGVhZEZpbHRlclRyUHJvcHMiLCJnZXRUaGVhZEZpbHRlclRoUHJvcHMiLCJnZXRUYm9keVByb3BzIiwiZ2V0VHJHcm91cFByb3BzIiwiZ2V0VHJQcm9wcyIsImdldFRkUHJvcHMiLCJnZXRUZm9vdFByb3BzIiwiZ2V0VGZvb3RUclByb3BzIiwiZ2V0VGZvb3RUZFByb3BzIiwiZ2V0UGFnaW5hdGlvblByb3BzIiwiZ2V0TG9hZGluZ1Byb3BzIiwiZ2V0Tm9EYXRhUHJvcHMiLCJnZXRSZXNpemVyUHJvcHMiLCJzaG93UGFnaW5hdGlvbiIsInNob3dQYWdpbmF0aW9uVG9wIiwic2hvd1BhZ2luYXRpb25Cb3R0b20iLCJtYW51YWwiLCJsb2FkaW5nVGV4dCIsIm5vRGF0YVRleHQiLCJzb3J0YWJsZSIsInJlc2l6YWJsZSIsImZpbHRlcmFibGUiLCJwaXZvdElES2V5IiwicGl2b3RWYWxLZXkiLCJwaXZvdEJ5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJsb2FkaW5nIiwicGFnZXMiLCJvbkV4cGFuZGVkQ2hhbmdlIiwiVGFibGVDb21wb25lbnQiLCJUaGVhZENvbXBvbmVudCIsIlRib2R5Q29tcG9uZW50IiwiVHJHcm91cENvbXBvbmVudCIsIlRyQ29tcG9uZW50IiwiVGhDb21wb25lbnQiLCJUZENvbXBvbmVudCIsIlRmb290Q29tcG9uZW50IiwiUGFnaW5hdGlvbkNvbXBvbmVudCIsIkxvYWRpbmdDb21wb25lbnQiLCJTdWJDb21wb25lbnQiLCJOb0RhdGFDb21wb25lbnQiLCJSZXNpemVyQ29tcG9uZW50IiwiRXhwYW5kZXJDb21wb25lbnQiLCJQaXZvdFZhbHVlQ29tcG9uZW50IiwiUGl2b3RDb21wb25lbnQiLCJBZ2dyZWdhdGVkQ29tcG9uZW50IiwiRmlsdGVyQ29tcG9uZW50IiwiUGFkUm93Q29tcG9uZW50IiwicmVzb2x2ZWREYXRhIiwiYWxsVmlzaWJsZUNvbHVtbnMiLCJoZWFkZXJHcm91cHMiLCJoYXNIZWFkZXJHcm91cHMiLCJzb3J0ZWREYXRhIiwic3RhcnRSb3ciLCJlbmRSb3ciLCJwYWdlUm93cyIsInNsaWNlIiwibWluUm93cyIsInBhZFJvd3MiLCJyYW5nZSIsIk1hdGgiLCJtYXgiLCJsZW5ndGgiLCJoYXNDb2x1bW5Gb290ZXIiLCJzb21lIiwiZCIsIkZvb3RlciIsImhhc0ZpbHRlcnMiLCJyZWN1cnNlUm93c1ZpZXdJbmRleCIsInJvd3MiLCJwYXRoIiwiaW5kZXgiLCJtYXAiLCJyb3ciLCJpIiwicm93V2l0aFZpZXdJbmRleCIsIl92aWV3SW5kZXgiLCJuZXdQYXRoIiwiY29uY2F0IiwiZ2V0IiwiY2FuUHJldmlvdXMiLCJjYW5OZXh0Iiwicm93TWluV2lkdGgiLCJzdW0iLCJyZXNpemVkQ29sdW1uIiwiZmluZCIsIngiLCJpZCIsImdldEZpcnN0RGVmaW5lZCIsInZhbHVlIiwid2lkdGgiLCJtaW5XaWR0aCIsInJvd0luZGV4IiwiZmluYWxTdGF0ZSIsIm1ha2VIZWFkZXJHcm91cHMiLCJ0aGVhZEdyb3VwUHJvcHMiLCJzcGxpdFByb3BzIiwidW5kZWZpbmVkIiwidGhlYWRHcm91cFRyUHJvcHMiLCJyZXN0IiwibWFrZUhlYWRlckdyb3VwIiwiY29sdW1uIiwicmVzaXplZFZhbHVlIiwiY29sIiwiZmxleCIsImNvbHVtbnMiLCJtYXhXaWR0aCIsInRoZWFkR3JvdXBUaFByb3BzIiwiY29sdW1uSGVhZGVyUHJvcHMiLCJnZXRIZWFkZXJQcm9wcyIsImNsYXNzZXMiLCJoZWFkZXJDbGFzc05hbWUiLCJzdHlsZXMiLCJoZWFkZXJTdHlsZSIsImZsZXhTdHlsZXMiLCJhc1B4Iiwibm9ybWFsaXplQ29tcG9uZW50IiwiSGVhZGVyIiwiZGF0YSIsIm1ha2VIZWFkZXJzIiwidGhlYWRQcm9wcyIsInRoZWFkVHJQcm9wcyIsIm1ha2VIZWFkZXIiLCJyZXNpemVkQ29sIiwic29ydCIsInNob3ciLCJ0aGVhZFRoUHJvcHMiLCJpc1Jlc2l6YWJsZSIsInJlc2l6ZXIiLCJlIiwicmVzaXplclByb3BzIiwiaXNTb3J0YWJsZSIsImRlc2MiLCJpbmNsdWRlcyIsInNoaWZ0S2V5IiwibWFrZUZpbHRlcnMiLCJ0aGVhZEZpbHRlclByb3BzIiwidGhlYWRGaWx0ZXJUclByb3BzIiwibWFrZUZpbHRlciIsInRoZWFkRmlsdGVyVGhQcm9wcyIsImZpbHRlciIsIlJlc29sdmVkRmlsdGVyQ29tcG9uZW50IiwiRmlsdGVyIiwiaXNGaWx0ZXJhYmxlIiwib25DaGFuZ2UiLCJtYWtlUGFnZVJvdyIsInJvd0luZm8iLCJvcmlnaW5hbCIsInZpZXdJbmRleCIsImxldmVsIiwibmVzdGluZ1BhdGgiLCJhZ2dyZWdhdGVkIiwiZ3JvdXBlZEJ5UGl2b3QiLCJzdWJSb3dzIiwiaXNFeHBhbmRlZCIsInRyR3JvdXBQcm9wcyIsInRyUHJvcHMiLCJqb2luIiwiaTIiLCJ0ZFByb3BzIiwiY29sdW1uUHJvcHMiLCJjZWxsSW5mbyIsInBpdm90ZWQiLCJleHBhbmRlciIsInVzZU9uRXhwYW5kZXJDbGljayIsImlzQnJhbmNoIiwiaXNQcmV2aWV3Iiwib25FeHBhbmRlckNsaWNrIiwibmV3RXhwYW5kZWQiLCJjbG9uZSIsInNldCIsInNldFN0YXRlV2l0aERhdGEiLCJyZXNvbHZlZENlbGwiLCJDZWxsIiwiUmVzb2x2ZWRBZ2dyZWdhdGVkQ29tcG9uZW50IiwiQWdncmVnYXRlZCIsImFnZ3JlZ2F0ZSIsIlJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQiLCJFeHBhbmRlciIsIlJlc29sdmVkUGl2b3RWYWx1ZUNvbXBvbmVudCIsIlBpdm90VmFsdWUiLCJEZWZhdWx0UmVzb2x2ZWRQaXZvdENvbXBvbmVudCIsIlJlc29sdmVkUGl2b3RDb21wb25lbnQiLCJQaXZvdCIsImV4cGFuZGFibGUiLCJpbmRleE9mIiwicmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2siLCJpbnRlcmFjdGlvblByb3BzIiwib25DbGljayIsIm1ha2VQYWRSb3ciLCJtYWtlUGFkQ29sdW1uIiwibWFrZUNvbHVtbkZvb3RlcnMiLCJ0Rm9vdFByb3BzIiwidEZvb3RUclByb3BzIiwibWFrZUNvbHVtbkZvb3RlciIsInRGb290VGRQcm9wcyIsImNvbHVtbkZvb3RlclByb3BzIiwiZ2V0Rm9vdGVyUHJvcHMiLCJtYWtlUGFnaW5hdGlvbiIsInBhZ2luYXRpb25Qcm9wcyIsInJvb3RQcm9wcyIsInRhYmxlUHJvcHMiLCJ0Qm9keVByb3BzIiwibG9hZGluZ1Byb3BzIiwibm9EYXRhUHJvcHMiLCJtYWtlVGFibGUiLCJwYWdpbmF0aW9uIiwiZGVmYXVsdFByb3BzIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7O0FBQUE7Ozs7QUFDQTs7OztBQUVBOzs7O0FBQ0E7Ozs7QUFDQTs7OztBQUNBOzs7Ozs7Ozs7OztBQUpBOzs7QUFNTyxJQUFNQSx3RUFBTjs7SUFFY0MsVTs7O0FBR25CLHNCQUFhQyxLQUFiLEVBQW9CO0FBQUE7O0FBQUE7O0FBR2xCLFVBQUtDLGdCQUFMLEdBQXdCLE1BQUtBLGdCQUFMLENBQXNCQyxJQUF0QixPQUF4QjtBQUNBLFVBQUtDLFlBQUwsR0FBb0IsTUFBS0EsWUFBTCxDQUFrQkQsSUFBbEIsT0FBcEI7QUFDQSxVQUFLRSxhQUFMLEdBQXFCLE1BQUtBLGFBQUwsQ0FBbUJGLElBQW5CLE9BQXJCO0FBQ0EsVUFBS0csYUFBTCxHQUFxQixNQUFLQSxhQUFMLENBQW1CSCxJQUFuQixPQUFyQjtBQUNBLFVBQUtJLGNBQUwsR0FBc0IsTUFBS0EsY0FBTCxDQUFvQkosSUFBcEIsT0FBdEI7QUFDQSxVQUFLSyxjQUFMLEdBQXNCLE1BQUtBLGNBQUwsQ0FBb0JMLElBQXBCLE9BQXRCO0FBQ0EsVUFBS00sVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCTixJQUFoQixPQUFsQjtBQUNBLFVBQUtPLFFBQUwsR0FBZ0IsTUFBS0EsUUFBTCxDQUFjUCxJQUFkLE9BQWhCO0FBQ0EsVUFBS1EsVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCUixJQUFoQixPQUFsQjtBQUNBLFVBQUtTLFlBQUwsR0FBb0IsTUFBS0EsWUFBTCxDQUFrQlQsSUFBbEIsT0FBcEI7QUFDQSxVQUFLVSxnQkFBTCxHQUF3QixNQUFLQSxnQkFBTCxDQUFzQlYsSUFBdEIsT0FBeEI7QUFDQSxVQUFLVyxVQUFMLEdBQWtCLE1BQUtBLFVBQUwsQ0FBZ0JYLElBQWhCLE9BQWxCO0FBQ0EsVUFBS1ksWUFBTCxHQUFvQixNQUFLQSxZQUFMLENBQWtCWixJQUFsQixPQUFwQjtBQUNBLFVBQUthLGlCQUFMLEdBQXlCLE1BQUtBLGlCQUFMLENBQXVCYixJQUF2QixPQUF6QjtBQUNBLFVBQUtjLGVBQUwsR0FBdUIsTUFBS0EsZUFBTCxDQUFxQmQsSUFBckIsT0FBdkI7QUFDQSxVQUFLZSxrQkFBTCxHQUEwQixNQUFLQSxrQkFBTCxDQUF3QmYsSUFBeEIsT0FBMUI7O0FBRUEsVUFBS2dCLEtBQUwsR0FBYTtBQUNYQyxZQUFNLENBREs7QUFFWEMsZ0JBQVVwQixNQUFNcUIsZUFGTDtBQUdYQyxjQUFRdEIsTUFBTXVCLGFBSEg7QUFJWEMsZ0JBQVV4QixNQUFNeUIsZUFKTDtBQUtYQyxnQkFBVTFCLE1BQU0yQixlQUxMO0FBTVhDLGVBQVM1QixNQUFNNkIsY0FOSjtBQU9YQyx5QkFBbUIsS0FQUjtBQVFYQyxvQkFBYztBQVJILEtBQWI7QUFwQmtCO0FBOEJuQjs7Ozs2QkFFUztBQUFBOztBQUNSLFVBQU1DLGdCQUFnQixLQUFLL0IsZ0JBQUwsRUFBdEI7QUFEUSxVQUdOZ0MsUUFITSxHQW9GSkQsYUFwRkksQ0FHTkMsUUFITTtBQUFBLFVBSU5DLFNBSk0sR0FvRkpGLGFBcEZJLENBSU5FLFNBSk07QUFBQSxVQUtOQyxLQUxNLEdBb0ZKSCxhQXBGSSxDQUtORyxLQUxNO0FBQUEsVUFNTkMsUUFOTSxHQW9GSkosYUFwRkksQ0FNTkksUUFOTTtBQUFBLFVBT05DLGFBUE0sR0FvRkpMLGFBcEZJLENBT05LLGFBUE07QUFBQSxVQVFOQyxrQkFSTSxHQW9GSk4sYUFwRkksQ0FRTk0sa0JBUk07QUFBQSxVQVNOQyxvQkFUTSxHQW9GSlAsYUFwRkksQ0FTTk8sb0JBVE07QUFBQSxVQVVOQyxvQkFWTSxHQW9GSlIsYUFwRkksQ0FVTlEsb0JBVk07QUFBQSxVQVdOQyxhQVhNLEdBb0ZKVCxhQXBGSSxDQVdOUyxhQVhNO0FBQUEsVUFZTkMsZUFaTSxHQW9GSlYsYUFwRkksQ0FZTlUsZUFaTTtBQUFBLFVBYU5DLGVBYk0sR0FvRkpYLGFBcEZJLENBYU5XLGVBYk07QUFBQSxVQWNOQyxtQkFkTSxHQW9GSlosYUFwRkksQ0FjTlksbUJBZE07QUFBQSxVQWVOQyxxQkFmTSxHQW9GSmIsYUFwRkksQ0FlTmEscUJBZk07QUFBQSxVQWdCTkMscUJBaEJNLEdBb0ZKZCxhQXBGSSxDQWdCTmMscUJBaEJNO0FBQUEsVUFpQk5DLGFBakJNLEdBb0ZKZixhQXBGSSxDQWlCTmUsYUFqQk07QUFBQSxVQWtCTkMsZUFsQk0sR0FvRkpoQixhQXBGSSxDQWtCTmdCLGVBbEJNO0FBQUEsVUFtQk5DLFVBbkJNLEdBb0ZKakIsYUFwRkksQ0FtQk5pQixVQW5CTTtBQUFBLFVBb0JOQyxVQXBCTSxHQW9GSmxCLGFBcEZJLENBb0JOa0IsVUFwQk07QUFBQSxVQXFCTkMsYUFyQk0sR0FvRkpuQixhQXBGSSxDQXFCTm1CLGFBckJNO0FBQUEsVUFzQk5DLGVBdEJNLEdBb0ZKcEIsYUFwRkksQ0FzQk5vQixlQXRCTTtBQUFBLFVBdUJOQyxlQXZCTSxHQW9GSnJCLGFBcEZJLENBdUJOcUIsZUF2Qk07QUFBQSxVQXdCTkMsa0JBeEJNLEdBb0ZKdEIsYUFwRkksQ0F3Qk5zQixrQkF4Qk07QUFBQSxVQXlCTkMsZUF6Qk0sR0FvRkp2QixhQXBGSSxDQXlCTnVCLGVBekJNO0FBQUEsVUEwQk5DLGNBMUJNLEdBb0ZKeEIsYUFwRkksQ0EwQk53QixjQTFCTTtBQUFBLFVBMkJOQyxlQTNCTSxHQW9GSnpCLGFBcEZJLENBMkJOeUIsZUEzQk07QUFBQSxVQTRCTkMsY0E1Qk0sR0FvRkoxQixhQXBGSSxDQTRCTjBCLGNBNUJNO0FBQUEsVUE2Qk5DLGlCQTdCTSxHQW9GSjNCLGFBcEZJLENBNkJOMkIsaUJBN0JNO0FBQUEsVUE4Qk5DLG9CQTlCTSxHQW9GSjVCLGFBcEZJLENBOEJONEIsb0JBOUJNO0FBQUEsVUErQk5DLE1BL0JNLEdBb0ZKN0IsYUFwRkksQ0ErQk42QixNQS9CTTtBQUFBLFVBZ0NOQyxXQWhDTSxHQW9GSjlCLGFBcEZJLENBZ0NOOEIsV0FoQ007QUFBQSxVQWlDTkMsVUFqQ00sR0FvRkovQixhQXBGSSxDQWlDTitCLFVBakNNO0FBQUEsVUFrQ05DLFFBbENNLEdBb0ZKaEMsYUFwRkksQ0FrQ05nQyxRQWxDTTtBQUFBLFVBbUNOQyxTQW5DTSxHQW9GSmpDLGFBcEZJLENBbUNOaUMsU0FuQ007QUFBQSxVQW9DTkMsVUFwQ00sR0FvRkpsQyxhQXBGSSxDQW9DTmtDLFVBcENNO0FBQUEsVUFzQ05DLFVBdENNLEdBb0ZKbkMsYUFwRkksQ0FzQ05tQyxVQXRDTTtBQUFBLFVBdUNOQyxXQXZDTSxHQW9GSnBDLGFBcEZJLENBdUNOb0MsV0F2Q007QUFBQSxVQXdDTkMsT0F4Q00sR0FvRkpyQyxhQXBGSSxDQXdDTnFDLE9BeENNO0FBQUEsVUF5Q05DLFVBekNNLEdBb0ZKdEMsYUFwRkksQ0F5Q05zQyxVQXpDTTtBQUFBLFVBMENOQyxhQTFDTSxHQW9GSnZDLGFBcEZJLENBMENOdUMsYUExQ007QUFBQSxVQTJDTkMsV0EzQ00sR0FvRkp4QyxhQXBGSSxDQTJDTndDLFdBM0NNO0FBQUEsVUE0Q05DLFFBNUNNLEdBb0ZKekMsYUFwRkksQ0E0Q055QyxRQTVDTTtBQUFBLFVBNkNOQyxpQkE3Q00sR0FvRkoxQyxhQXBGSSxDQTZDTjBDLGlCQTdDTTtBQUFBLFVBK0NOQyxPQS9DTSxHQW9GSjNDLGFBcEZJLENBK0NOMkMsT0EvQ007QUFBQSxVQWdETnZELFFBaERNLEdBb0ZKWSxhQXBGSSxDQWdETlosUUFoRE07QUFBQSxVQWlETkQsSUFqRE0sR0FvRkphLGFBcEZJLENBaUROYixJQWpETTtBQUFBLFVBa0RORyxNQWxETSxHQW9GSlUsYUFwRkksQ0FrRE5WLE1BbERNO0FBQUEsVUFtRE5JLFFBbkRNLEdBb0ZKTSxhQXBGSSxDQW1ETk4sUUFuRE07QUFBQSxVQW9ETkUsT0FwRE0sR0FvRkpJLGFBcEZJLENBb0ROSixPQXBETTtBQUFBLFVBcUROSixRQXJETSxHQW9GSlEsYUFwRkksQ0FxRE5SLFFBckRNO0FBQUEsVUFzRE5vRCxLQXRETSxHQW9GSjVDLGFBcEZJLENBc0RONEMsS0F0RE07QUFBQSxVQXVETkMsZ0JBdkRNLEdBb0ZKN0MsYUFwRkksQ0F1RE42QyxnQkF2RE07QUFBQSxVQXlETkMsY0F6RE0sR0FvRko5QyxhQXBGSSxDQXlETjhDLGNBekRNO0FBQUEsVUEwRE5DLGNBMURNLEdBb0ZKL0MsYUFwRkksQ0EwRE4rQyxjQTFETTtBQUFBLFVBMkROQyxjQTNETSxHQW9GSmhELGFBcEZJLENBMkROZ0QsY0EzRE07QUFBQSxVQTRETkMsZ0JBNURNLEdBb0ZKakQsYUFwRkksQ0E0RE5pRCxnQkE1RE07QUFBQSxVQTZETkMsV0E3RE0sR0FvRkpsRCxhQXBGSSxDQTZETmtELFdBN0RNO0FBQUEsVUE4RE5DLFdBOURNLEdBb0ZKbkQsYUFwRkksQ0E4RE5tRCxXQTlETTtBQUFBLFVBK0ROQyxXQS9ETSxHQW9GSnBELGFBcEZJLENBK0ROb0QsV0EvRE07QUFBQSxVQWdFTkMsY0FoRU0sR0FvRkpyRCxhQXBGSSxDQWdFTnFELGNBaEVNO0FBQUEsVUFpRU5DLG1CQWpFTSxHQW9GSnRELGFBcEZJLENBaUVOc0QsbUJBakVNO0FBQUEsVUFrRU5DLGdCQWxFTSxHQW9GSnZELGFBcEZJLENBa0VOdUQsZ0JBbEVNO0FBQUEsVUFtRU5DLFlBbkVNLEdBb0ZKeEQsYUFwRkksQ0FtRU53RCxZQW5FTTtBQUFBLFVBb0VOQyxlQXBFTSxHQW9GSnpELGFBcEZJLENBb0VOeUQsZUFwRU07QUFBQSxVQXFFTkMsZ0JBckVNLEdBb0ZKMUQsYUFwRkksQ0FxRU4wRCxnQkFyRU07QUFBQSxVQXNFTkMsaUJBdEVNLEdBb0ZKM0QsYUFwRkksQ0FzRU4yRCxpQkF0RU07QUFBQSxVQXVFTkMsbUJBdkVNLEdBb0ZKNUQsYUFwRkksQ0F1RU40RCxtQkF2RU07QUFBQSxVQXdFTkMsY0F4RU0sR0FvRko3RCxhQXBGSSxDQXdFTjZELGNBeEVNO0FBQUEsVUF5RU5DLG1CQXpFTSxHQW9GSjlELGFBcEZJLENBeUVOOEQsbUJBekVNO0FBQUEsVUEwRU5DLGVBMUVNLEdBb0ZKL0QsYUFwRkksQ0EwRU4rRCxlQTFFTTtBQUFBLFVBMkVOQyxlQTNFTSxHQW9GSmhFLGFBcEZJLENBMkVOZ0UsZUEzRU07QUFBQSxVQTZFTkMsWUE3RU0sR0FvRkpqRSxhQXBGSSxDQTZFTmlFLFlBN0VNO0FBQUEsVUE4RU5DLGlCQTlFTSxHQW9GSmxFLGFBcEZJLENBOEVOa0UsaUJBOUVNO0FBQUEsVUErRU5DLFlBL0VNLEdBb0ZKbkUsYUFwRkksQ0ErRU5tRSxZQS9FTTtBQUFBLFVBZ0ZOQyxlQWhGTSxHQW9GSnBFLGFBcEZJLENBZ0ZOb0UsZUFoRk07QUFBQSxVQWtGTkMsVUFsRk0sR0FvRkpyRSxhQXBGSSxDQWtGTnFFLFVBbEZNO0FBQUEsVUFtRk52RSxpQkFuRk0sR0FvRkpFLGFBcEZJLENBbUZORixpQkFuRk07O0FBc0ZSOztBQUNBLFVBQU13RSxXQUFXbEYsV0FBV0QsSUFBNUI7QUFDQSxVQUFNb0YsU0FBU0QsV0FBV2xGLFFBQTFCO0FBQ0EsVUFBSW9GLFdBQVczQyxTQUFTb0MsWUFBVCxHQUF3QkksV0FBV0ksS0FBWCxDQUFpQkgsUUFBakIsRUFBMkJDLE1BQTNCLENBQXZDO0FBQ0EsVUFBTUcsVUFBVSxLQUFLaEcsVUFBTCxFQUFoQjtBQUNBLFVBQU1pRyxVQUFVLGdCQUFFQyxLQUFGLENBQVFDLEtBQUtDLEdBQUwsQ0FBU0osVUFBVUYsU0FBU08sTUFBNUIsRUFBb0MsQ0FBcEMsQ0FBUixDQUFoQjs7QUFFQSxVQUFNQyxrQkFBa0JkLGtCQUFrQmUsSUFBbEIsQ0FBdUI7QUFBQSxlQUFLQyxFQUFFQyxNQUFQO0FBQUEsT0FBdkIsQ0FBeEI7QUFDQSxVQUFNQyxhQUFhbEQsY0FBY2dDLGtCQUFrQmUsSUFBbEIsQ0FBdUI7QUFBQSxlQUFLQyxFQUFFaEQsVUFBUDtBQUFBLE9BQXZCLENBQWpDOztBQUVBLFVBQU1tRCx1QkFBdUIsU0FBdkJBLG9CQUF1QixDQUFDQyxJQUFELEVBQWlDO0FBQUEsWUFBMUJDLElBQTBCLHVFQUFuQixFQUFtQjtBQUFBLFlBQWZDLEtBQWUsdUVBQVAsQ0FBQyxDQUFNOztBQUM1RCxlQUFPLENBQ0xGLEtBQUtHLEdBQUwsQ0FBUyxVQUFDQyxHQUFELEVBQU1DLENBQU4sRUFBWTtBQUNuQkg7QUFDQSxjQUFNSSxnQ0FDREYsR0FEQztBQUVKRyx3QkFBWUw7QUFGUixZQUFOO0FBSUEsY0FBTU0sVUFBVVAsS0FBS1EsTUFBTCxDQUFZLENBQUNKLENBQUQsQ0FBWixDQUFoQjtBQUNBLGNBQUlDLGlCQUFpQnRELFVBQWpCLEtBQWdDLGdCQUFFMEQsR0FBRixDQUFNeEcsUUFBTixFQUFnQnNHLE9BQWhCLENBQXBDLEVBQThEO0FBQzVEO0FBRDRELHdDQUNuQlQscUJBQ3ZDTyxpQkFBaUJ0RCxVQUFqQixDQUR1QyxFQUV2Q3dELE9BRnVDLEVBR3ZDTixLQUh1QyxDQURtQjs7QUFBQTs7QUFDMURJLDZCQUFpQnRELFVBQWpCLENBRDBEO0FBQzVCa0QsaUJBRDRCO0FBTTdEO0FBQ0QsaUJBQU9JLGdCQUFQO0FBQ0QsU0FmRCxDQURLLEVBaUJMSixLQWpCSyxDQUFQO0FBbUJELE9BcEJEO0FBaEdRLG1DQXFITUgscUJBQXFCYixRQUFyQixDQXJITjs7QUFBQTs7QUFxSE5BLGNBckhNOzs7QUF1SFIsVUFBTXlCLGNBQWM5RyxPQUFPLENBQTNCO0FBQ0EsVUFBTStHLFVBQVUvRyxPQUFPLENBQVAsR0FBV3lELEtBQTNCOztBQUVBLFVBQU11RCxjQUFjLGdCQUFFQyxHQUFGLENBQ2xCbEMsa0JBQWtCdUIsR0FBbEIsQ0FBc0IsYUFBSztBQUN6QixZQUFNWSxnQkFBZ0J6RyxRQUFRMEcsSUFBUixDQUFhO0FBQUEsaUJBQUtDLEVBQUVDLEVBQUYsS0FBU3RCLEVBQUVzQixFQUFoQjtBQUFBLFNBQWIsS0FBb0MsRUFBMUQ7QUFDQSxlQUFPLGdCQUFFQyxlQUFGLENBQWtCSixjQUFjSyxLQUFoQyxFQUF1Q3hCLEVBQUV5QixLQUF6QyxFQUFnRHpCLEVBQUUwQixRQUFsRCxDQUFQO0FBQ0QsT0FIRCxDQURrQixDQUFwQjs7QUFPQSxVQUFJQyxXQUFXLENBQUMsQ0FBaEI7O0FBRUEsVUFBTUMsMEJBQ0Q5RyxhQURDO0FBRUpzRSwwQkFGSTtBQUdKQyxzQkFISTtBQUlKQywwQkFKSTtBQUtKRSx3QkFMSTtBQU1KQyx3QkFOSTtBQU9KSyx3Q0FQSTtBQVFKaUIsZ0NBUkk7QUFTSkMsd0JBVEk7QUFVSkM7QUFWSSxRQUFOOztBQWFBOztBQUVBLFVBQU1ZLG1CQUFtQixTQUFuQkEsZ0JBQW1CLEdBQU07QUFDN0IsWUFBTUMsa0JBQWtCLGdCQUFFQyxVQUFGLENBQ3RCM0csbUJBQW1Cd0csVUFBbkIsRUFBK0JJLFNBQS9CLEVBQTBDQSxTQUExQyxTQURzQixDQUF4QjtBQUdBLFlBQU1DLG9CQUFvQixnQkFBRUYsVUFBRixDQUN4QjFHLHFCQUFxQnVHLFVBQXJCLEVBQWlDSSxTQUFqQyxFQUE0Q0EsU0FBNUMsU0FEd0IsQ0FBMUI7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXLDBCQUFXLGVBQVgsRUFBNEJGLGdCQUFnQjlHLFNBQTVDLENBRGI7QUFFRSxnQ0FDSzhHLGdCQUFnQjdHLEtBRHJCO0FBRUV5Ryx3QkFBYVQsV0FBYjtBQUZGO0FBRkYsYUFNTWEsZ0JBQWdCSSxJQU50QjtBQVFFO0FBQUMsdUJBQUQ7QUFBQTtBQUNFLHlCQUFXRCxrQkFBa0JqSCxTQUQvQjtBQUVFLHFCQUFPaUgsa0JBQWtCaEg7QUFGM0IsZUFHTWdILGtCQUFrQkMsSUFIeEI7QUFLR2pELHlCQUFhc0IsR0FBYixDQUFpQjRCLGVBQWpCO0FBTEg7QUFSRixTQURGO0FBa0JELE9BekJEOztBQTJCQSxVQUFNQSxrQkFBa0IsU0FBbEJBLGVBQWtCLENBQUNDLE1BQUQsRUFBUzNCLENBQVQsRUFBZTtBQUNyQyxZQUFNNEIsZUFBZSxTQUFmQSxZQUFlO0FBQUEsaUJBQ25CLENBQUMzSCxRQUFRMEcsSUFBUixDQUFhO0FBQUEsbUJBQUtDLEVBQUVDLEVBQUYsS0FBU2dCLElBQUloQixFQUFsQjtBQUFBLFdBQWIsS0FBc0MsRUFBdkMsRUFBMkNFLEtBRHhCO0FBQUEsU0FBckI7QUFFQSxZQUFNZSxPQUFPLGdCQUFFckIsR0FBRixDQUNYa0IsT0FBT0ksT0FBUCxDQUFlakMsR0FBZixDQUNFO0FBQUEsaUJBQVErQixJQUFJYixLQUFKLElBQWFZLGFBQWFDLEdBQWIsQ0FBYixHQUFpQyxDQUFqQyxHQUFxQ0EsSUFBSVosUUFBakQ7QUFBQSxTQURGLENBRFcsQ0FBYjtBQUtBLFlBQU1ELFFBQVEsZ0JBQUVQLEdBQUYsQ0FDWmtCLE9BQU9JLE9BQVAsQ0FBZWpDLEdBQWYsQ0FBbUI7QUFBQSxpQkFDakIsZ0JBQUVnQixlQUFGLENBQWtCYyxhQUFhQyxHQUFiLENBQWxCLEVBQXFDQSxJQUFJYixLQUF6QyxFQUFnRGEsSUFBSVosUUFBcEQsQ0FEaUI7QUFBQSxTQUFuQixDQURZLENBQWQ7QUFLQSxZQUFNZSxXQUFXLGdCQUFFdkIsR0FBRixDQUNma0IsT0FBT0ksT0FBUCxDQUFlakMsR0FBZixDQUFtQjtBQUFBLGlCQUNqQixnQkFBRWdCLGVBQUYsQ0FBa0JjLGFBQWFDLEdBQWIsQ0FBbEIsRUFBcUNBLElBQUliLEtBQXpDLEVBQWdEYSxJQUFJRyxRQUFwRCxDQURpQjtBQUFBLFNBQW5CLENBRGUsQ0FBakI7O0FBTUEsWUFBTUMsb0JBQW9CLGdCQUFFWCxVQUFGLENBQ3hCekcscUJBQXFCc0csVUFBckIsRUFBaUNJLFNBQWpDLEVBQTRDSSxNQUE1QyxTQUR3QixDQUExQjtBQUdBLFlBQU1PLG9CQUFvQixnQkFBRVosVUFBRixDQUN4QkssT0FBT1EsY0FBUCxDQUFzQmhCLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0ksTUFBN0MsU0FEd0IsQ0FBMUI7O0FBSUEsWUFBTVMsVUFBVSxDQUNkVCxPQUFPVSxlQURPLEVBRWRKLGtCQUFrQjFILFNBRkosRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRUROLGtCQUFrQnpILEtBRmpCLEVBR0QwSCxrQkFBa0IxSCxLQUhqQixDQUFOOztBQU1BLFlBQU1pSCxvQkFDRFEsa0JBQWtCUixJQURqQixFQUVEUyxrQkFBa0JULElBRmpCLENBQU47O0FBS0EsWUFBTWUsYUFBYTtBQUNqQlYsZ0JBQVNBLElBQVQsWUFEaUI7QUFFakJkLGlCQUFPLGdCQUFFeUIsSUFBRixDQUFPekIsS0FBUCxDQUZVO0FBR2pCZ0Isb0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUhPLFNBQW5COztBQU1BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUtoQyxJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLENBRmI7QUFHRSxnQ0FDS0UsTUFETCxFQUVLRSxVQUZMO0FBSEYsYUFPTWYsSUFQTjtBQVNHLDBCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9nQixNQUE1QixFQUFvQztBQUNuQ0Msa0JBQU1sRSxVQUQ2QjtBQUVuQ2lELG9CQUFRQTtBQUYyQixXQUFwQztBQVRILFNBREY7QUFnQkQsT0FqRUQ7O0FBbUVBLFVBQU1rQixjQUFjLFNBQWRBLFdBQWMsR0FBTTtBQUN4QixZQUFNQyxhQUFhLGdCQUFFeEIsVUFBRixDQUNqQnhHLGNBQWNxRyxVQUFkLEVBQTBCSSxTQUExQixFQUFxQ0EsU0FBckMsU0FEaUIsQ0FBbkI7QUFHQSxZQUFNd0IsZUFBZSxnQkFBRXpCLFVBQUYsQ0FDbkJ2RyxnQkFBZ0JvRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNBLFNBQXZDLFNBRG1CLENBQXJCO0FBR0EsZUFDRTtBQUFDLHdCQUFEO0FBQUE7QUFDRSx1QkFBVywwQkFBVyxTQUFYLEVBQXNCdUIsV0FBV3ZJLFNBQWpDLENBRGI7QUFFRSxnQ0FDS3VJLFdBQVd0SSxLQURoQjtBQUVFeUcsd0JBQWFULFdBQWI7QUFGRjtBQUZGLGFBTU1zQyxXQUFXckIsSUFOakI7QUFRRTtBQUFDLHVCQUFEO0FBQUE7QUFDRSx5QkFBV3NCLGFBQWF4SSxTQUQxQjtBQUVFLHFCQUFPd0ksYUFBYXZJO0FBRnRCLGVBR011SSxhQUFhdEIsSUFIbkI7QUFLR2xELDhCQUFrQnVCLEdBQWxCLENBQXNCa0QsVUFBdEI7QUFMSDtBQVJGLFNBREY7QUFrQkQsT0F6QkQ7O0FBMkJBLFVBQU1BLGFBQWEsU0FBYkEsVUFBYSxDQUFDckIsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ2hDLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1xQyxPQUFPdkosT0FBT2dILElBQVAsQ0FBWTtBQUFBLGlCQUFLcEIsRUFBRXNCLEVBQUYsS0FBU2MsT0FBT2QsRUFBckI7QUFBQSxTQUFaLENBQWI7QUFDQSxZQUFNc0MsT0FDSixPQUFPeEIsT0FBT3dCLElBQWQsS0FBdUIsVUFBdkIsR0FBb0N4QixPQUFPd0IsSUFBUCxFQUFwQyxHQUFvRHhCLE9BQU93QixJQUQ3RDtBQUVBLFlBQU1uQyxRQUFRLGdCQUFFRixlQUFGLENBQ1ptQyxXQUFXbEMsS0FEQyxFQUVaWSxPQUFPWCxLQUZLLEVBR1pXLE9BQU9WLFFBSEssQ0FBZDtBQUtBLFlBQU1lLFdBQVcsZ0JBQUVsQixlQUFGLENBQ2ZtQyxXQUFXbEMsS0FESSxFQUVmWSxPQUFPWCxLQUZRLEVBR2ZXLE9BQU9LLFFBSFEsQ0FBakI7QUFLQSxZQUFNb0IsZUFBZSxnQkFBRTlCLFVBQUYsQ0FDbkJ0RyxnQkFBZ0JtRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNJLE1BQXZDLFNBRG1CLENBQXJCO0FBR0EsWUFBTU8sb0JBQW9CLGdCQUFFWixVQUFGLENBQ3hCSyxPQUFPUSxjQUFQLENBQXNCaEIsVUFBdEIsRUFBa0NJLFNBQWxDLEVBQTZDSSxNQUE3QyxTQUR3QixDQUExQjs7QUFJQSxZQUFNUyxVQUFVLENBQ2RULE9BQU9VLGVBRE8sRUFFZGUsYUFBYTdJLFNBRkMsRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRURhLGFBQWE1SSxLQUZaLEVBR0QwSCxrQkFBa0IxSCxLQUhqQixDQUFOOztBQU1BLFlBQU1pSCxvQkFDRDJCLGFBQWEzQixJQURaLEVBRURTLGtCQUFrQlQsSUFGakIsQ0FBTjs7QUFLQSxZQUFNNEIsY0FBYyxnQkFBRXZDLGVBQUYsQ0FBa0JhLE9BQU9yRixTQUF6QixFQUFvQ0EsU0FBcEMsRUFBK0MsS0FBL0MsQ0FBcEI7QUFDQSxZQUFNZ0gsVUFBVUQsY0FDWCw4QkFBQyxnQkFBRDtBQUNELHVCQUFhO0FBQUEsbUJBQUssT0FBS2pLLGlCQUFMLENBQXVCbUssQ0FBdkIsRUFBMEI1QixNQUExQixFQUFrQyxLQUFsQyxDQUFMO0FBQUEsV0FEWjtBQUVELHdCQUFjO0FBQUEsbUJBQUssT0FBS3ZJLGlCQUFMLENBQXVCbUssQ0FBdkIsRUFBMEI1QixNQUExQixFQUFrQyxJQUFsQyxDQUFMO0FBQUE7QUFGYixXQUdHNkIsWUFISCxFQURXLEdBTVosSUFOSjs7QUFRQSxZQUFNQyxhQUFhLGdCQUFFM0MsZUFBRixDQUFrQmEsT0FBT3RGLFFBQXpCLEVBQW1DQSxRQUFuQyxFQUE2QyxLQUE3QyxDQUFuQjs7QUFFQSxlQUNFO0FBQUMscUJBQUQ7QUFBQTtBQUNFLGlCQUFLMkQsSUFBSSxHQUFKLEdBQVUyQixPQUFPZCxFQUR4QjtBQUVFLHVCQUFXLDBCQUNUdUIsT0FEUyxFQUVULHFCQUZTLEVBR1RjLE9BQVFBLEtBQUtRLElBQUwsR0FBWSxZQUFaLEdBQTJCLFdBQW5DLEdBQWtELEVBSHpDLEVBSVRELGNBQWMsaUJBSkwsRUFLVCxDQUFDTixJQUFELElBQVMsU0FMQSxFQU1UekcsV0FDRUEsUUFBUW9DLEtBQVIsQ0FBYyxDQUFkLEVBQWlCLENBQUMsQ0FBbEIsRUFBcUI2RSxRQUFyQixDQUE4QmhDLE9BQU9kLEVBQXJDLENBREYsSUFFRSxpQkFSTyxDQUZiO0FBWUUsZ0NBQ0t5QixNQURMO0FBRUVSLG9CQUFTZCxLQUFULFlBRkY7QUFHRUEscUJBQU8sZ0JBQUV5QixJQUFGLENBQU96QixLQUFQLENBSFQ7QUFJRWdCLHdCQUFVLGdCQUFFUyxJQUFGLENBQU9ULFFBQVA7QUFKWixjQVpGO0FBa0JFLHdCQUFZLHVCQUFLO0FBQ2Z5Qiw0QkFBYyxPQUFLdkssVUFBTCxDQUFnQnlJLE1BQWhCLEVBQXdCNEIsRUFBRUssUUFBMUIsQ0FBZDtBQUNEO0FBcEJILGFBcUJNbkMsSUFyQk47QUF1QkU7QUFBQTtBQUFBLGNBQUssV0FBVSw2QkFBZjtBQUNHLDRCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9nQixNQUE1QixFQUFvQztBQUNuQ0Msb0JBQU1sRSxVQUQ2QjtBQUVuQ2lELHNCQUFRQTtBQUYyQixhQUFwQztBQURILFdBdkJGO0FBNkJHMkI7QUE3QkgsU0FERjtBQWlDRCxPQW5GRDs7QUFxRkEsVUFBTU8sY0FBYyxTQUFkQSxXQUFjLEdBQU07QUFDeEIsWUFBTUMsbUJBQW1CLGdCQUFFeEMsVUFBRixDQUN2QnJHLG9CQUFvQmtHLFVBQXBCLEVBQWdDSSxTQUFoQyxFQUEyQ0EsU0FBM0MsU0FEdUIsQ0FBekI7QUFHQSxZQUFNd0MscUJBQXFCLGdCQUFFekMsVUFBRixDQUN6QnBHLHNCQUFzQmlHLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0EsU0FBN0MsU0FEeUIsQ0FBM0I7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXLDBCQUFXLFVBQVgsRUFBdUJ1QyxpQkFBaUJ2SixTQUF4QyxDQURiO0FBRUUsZ0NBQ0t1SixpQkFBaUJ0SixLQUR0QjtBQUVFeUcsd0JBQWFULFdBQWI7QUFGRjtBQUZGLGFBTU1zRCxpQkFBaUJyQyxJQU52QjtBQVFFO0FBQUMsdUJBQUQ7QUFBQTtBQUNFLHlCQUFXc0MsbUJBQW1CeEosU0FEaEM7QUFFRSxxQkFBT3dKLG1CQUFtQnZKO0FBRjVCLGVBR011SixtQkFBbUJ0QyxJQUh6QjtBQUtHbEQsOEJBQWtCdUIsR0FBbEIsQ0FBc0JrRSxVQUF0QjtBQUxIO0FBUkYsU0FERjtBQWtCRCxPQXpCRDs7QUEyQkEsVUFBTUEsYUFBYSxTQUFiQSxVQUFhLENBQUNyQyxNQUFELEVBQVMzQixDQUFULEVBQWU7QUFDaEMsWUFBTWlELGFBQWFoSixRQUFRMEcsSUFBUixDQUFhO0FBQUEsaUJBQUtDLEVBQUVDLEVBQUYsS0FBU2MsT0FBT2QsRUFBckI7QUFBQSxTQUFiLEtBQXlDLEVBQTVEO0FBQ0EsWUFBTUcsUUFBUSxnQkFBRUYsZUFBRixDQUNabUMsV0FBV2xDLEtBREMsRUFFWlksT0FBT1gsS0FGSyxFQUdaVyxPQUFPVixRQUhLLENBQWQ7QUFLQSxZQUFNZSxXQUFXLGdCQUFFbEIsZUFBRixDQUNmbUMsV0FBV2xDLEtBREksRUFFZlksT0FBT1gsS0FGUSxFQUdmVyxPQUFPSyxRQUhRLENBQWpCO0FBS0EsWUFBTWlDLHFCQUFxQixnQkFBRTNDLFVBQUYsQ0FDekJuRyxzQkFBc0JnRyxVQUF0QixFQUFrQ0ksU0FBbEMsRUFBNkNJLE1BQTdDLFNBRHlCLENBQTNCO0FBR0EsWUFBTU8sb0JBQW9CLGdCQUFFWixVQUFGLENBQ3hCSyxPQUFPUSxjQUFQLENBQXNCaEIsVUFBdEIsRUFBa0NJLFNBQWxDLEVBQTZDSSxNQUE3QyxTQUR3QixDQUExQjs7QUFJQSxZQUFNUyxVQUFVLENBQ2RULE9BQU9VLGVBRE8sRUFFZDRCLG1CQUFtQjFKLFNBRkwsRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRUQwQixtQkFBbUJ6SixLQUZsQixFQUdEMEgsa0JBQWtCMUgsS0FIakIsQ0FBTjs7QUFNQSxZQUFNaUgsb0JBQ0R3QyxtQkFBbUJ4QyxJQURsQixFQUVEUyxrQkFBa0JULElBRmpCLENBQU47O0FBS0EsWUFBTXlDLFNBQVNuSyxTQUFTNEcsSUFBVCxDQUFjO0FBQUEsaUJBQVV1RCxPQUFPckQsRUFBUCxLQUFjYyxPQUFPZCxFQUEvQjtBQUFBLFNBQWQsQ0FBZjs7QUFFQSxZQUFNc0QsMEJBQTBCeEMsT0FBT3lDLE1BQVAsSUFBaUJoRyxlQUFqRDs7QUFFQSxZQUFNaUcsZUFBZSxnQkFBRXZELGVBQUYsQ0FDbkJhLE9BQU9wRixVQURZLEVBRW5CQSxVQUZtQixFQUduQixLQUhtQixDQUFyQjs7QUFNQSxlQUNFO0FBQUMscUJBQUQ7QUFBQTtBQUNFLGlCQUFLeUQsSUFBSSxHQUFKLEdBQVUyQixPQUFPZCxFQUR4QjtBQUVFLHVCQUFXLDBCQUFXdUIsT0FBWCxDQUZiO0FBR0UsZ0NBQ0tFLE1BREw7QUFFRVIsb0JBQVNkLEtBQVQsWUFGRjtBQUdFQSxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTVAsSUFUTjtBQVdHNEMseUJBQ0csZ0JBQUUzQixrQkFBRixDQUNBeUIsdUJBREEsRUFFQTtBQUNFeEMsMEJBREY7QUFFRXVDLDBCQUZGO0FBR0VJLHNCQUFVO0FBQUEscUJBQVMsT0FBS25MLFlBQUwsQ0FBa0J3SSxNQUFsQixFQUEwQlosS0FBMUIsQ0FBVDtBQUFBO0FBSFosV0FGQSxFQU9BLHVCQUFhWSxNQUFiLENBQW9CeUMsTUFQcEIsQ0FESCxHQVVHO0FBckJOLFNBREY7QUF5QkQsT0F2RUQ7O0FBeUVBLFVBQU1HLGNBQWMsU0FBZEEsV0FBYyxDQUFDeEUsR0FBRCxFQUFNQyxDQUFOLEVBQXVCO0FBQUEsWUFBZEosSUFBYyx1RUFBUCxFQUFPOztBQUN6QyxZQUFNNEUsVUFBVTtBQUNkQyxvQkFBVTFFLElBQUlsRCxXQUFKLENBREk7QUFFZGtELGVBQUtBLEdBRlM7QUFHZEYsaUJBQU9FLElBQUlqRCxRQUFKLENBSE87QUFJZDRILHFCQUFXLEVBQUV4RCxRQUpDO0FBS2R5RCxpQkFBTy9FLEtBQUtSLE1BTEU7QUFNZHdGLHVCQUFhaEYsS0FBS1EsTUFBTCxDQUFZLENBQUNKLENBQUQsQ0FBWixDQU5DO0FBT2Q2RSxzQkFBWTlFLElBQUluRCxhQUFKLENBUEU7QUFRZGtJLDBCQUFnQi9FLElBQUloRCxpQkFBSixDQVJGO0FBU2RnSSxtQkFBU2hGLElBQUlwRCxVQUFKO0FBVEssU0FBaEI7QUFXQSxZQUFNcUksYUFBYSxnQkFBRTNFLEdBQUYsQ0FBTXhHLFFBQU4sRUFBZ0IySyxRQUFRSSxXQUF4QixDQUFuQjtBQUNBLFlBQU1LLGVBQWU1SixnQkFBZ0I4RixVQUFoQixFQUE0QnFELE9BQTVCLEVBQXFDakQsU0FBckMsU0FBckI7QUFDQSxZQUFNMkQsVUFBVSxnQkFBRTVELFVBQUYsQ0FDZGhHLFdBQVc2RixVQUFYLEVBQXVCcUQsT0FBdkIsRUFBZ0NqRCxTQUFoQyxTQURjLENBQWhCO0FBR0EsZUFDRTtBQUFDLDBCQUFEO0FBQUEscUJBQWtCLEtBQUtpRCxRQUFRSSxXQUFSLENBQW9CTyxJQUFwQixDQUF5QixHQUF6QixDQUF2QixJQUEwREYsWUFBMUQ7QUFDRTtBQUFDLHVCQUFEO0FBQUE7QUFDRSx5QkFBVywwQkFDVEMsUUFBUTNLLFNBREMsRUFFVHdGLElBQUlHLFVBQUosR0FBaUIsQ0FBakIsR0FBcUIsT0FBckIsR0FBK0IsTUFGdEIsQ0FEYjtBQUtFLHFCQUFPZ0YsUUFBUTFLO0FBTGpCLGVBTU0wSyxRQUFRekQsSUFOZDtBQVFHbEQsOEJBQWtCdUIsR0FBbEIsQ0FBc0IsVUFBQzZCLE1BQUQsRUFBU3lELEVBQVQsRUFBZ0I7QUFDckMsa0JBQU1uQyxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLHVCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsZUFBYixLQUF5QyxFQUE1RDtBQUNBLGtCQUFNc0MsT0FDSixPQUFPeEIsT0FBT3dCLElBQWQsS0FBdUIsVUFBdkIsR0FBb0N4QixPQUFPd0IsSUFBUCxFQUFwQyxHQUFvRHhCLE9BQU93QixJQUQ3RDtBQUVBLGtCQUFNbkMsUUFBUSxnQkFBRUYsZUFBRixDQUNabUMsV0FBV2xDLEtBREMsRUFFWlksT0FBT1gsS0FGSyxFQUdaVyxPQUFPVixRQUhLLENBQWQ7QUFLQSxrQkFBTWUsV0FBVyxnQkFBRWxCLGVBQUYsQ0FDZm1DLFdBQVdsQyxLQURJLEVBRWZZLE9BQU9YLEtBRlEsRUFHZlcsT0FBT0ssUUFIUSxDQUFqQjtBQUtBLGtCQUFNcUQsVUFBVSxnQkFBRS9ELFVBQUYsQ0FDZC9GLFdBQVc0RixVQUFYLEVBQXVCcUQsT0FBdkIsRUFBZ0M3QyxNQUFoQyxTQURjLENBQWhCO0FBR0Esa0JBQU0yRCxjQUFjLGdCQUFFaEUsVUFBRixDQUNsQkssT0FBT2xILFFBQVAsQ0FBZ0IwRyxVQUFoQixFQUE0QnFELE9BQTVCLEVBQXFDN0MsTUFBckMsU0FEa0IsQ0FBcEI7O0FBSUEsa0JBQU1TLFVBQVUsQ0FDZGlELFFBQVE5SyxTQURNLEVBRWRvSCxPQUFPcEgsU0FGTyxFQUdkK0ssWUFBWS9LLFNBSEUsQ0FBaEI7O0FBTUEsa0JBQU0rSCxzQkFDRCtDLFFBQVE3SyxLQURQLEVBRURtSCxPQUFPbkgsS0FGTixFQUdEOEssWUFBWTlLLEtBSFgsQ0FBTjs7QUFNQSxrQkFBTStLLHdCQUNEZixPQURDO0FBRUpRLHNDQUZJO0FBR0pyRCxxQ0FBYUEsTUFBYixDQUhJO0FBSUpaLHVCQUFPeUQsUUFBUXpFLEdBQVIsQ0FBWTRCLE9BQU9kLEVBQW5CLENBSkg7QUFLSjJFLHlCQUFTN0QsT0FBTzZELE9BTFo7QUFNSkMsMEJBQVU5RCxPQUFPOEQsUUFOYjtBQU9KeEwsZ0NBUEk7QUFRSmtKLDBCQVJJO0FBU0puQyw0QkFUSTtBQVVKZ0Isa0NBVkk7QUFXSnFELGdDQVhJO0FBWUpDLHdDQVpJO0FBYUpsRCxnQ0FiSTtBQWNKRTtBQWRJLGdCQUFOOztBQWlCQSxrQkFBTXZCLFFBQVF3RSxTQUFTeEUsS0FBdkI7O0FBRUEsa0JBQUkyRSwyQkFBSjtBQUNBLGtCQUFJQyxpQkFBSjtBQUNBLGtCQUFJQyxrQkFBSjs7QUFFQSxrQkFBTUMsa0JBQWtCLFNBQWxCQSxlQUFrQixJQUFLO0FBQzNCLG9CQUFJQyxjQUFjLGdCQUFFQyxLQUFGLENBQVFsTSxRQUFSLENBQWxCO0FBQ0Esb0JBQUltTCxVQUFKLEVBQWdCO0FBQ2RjLGdDQUFjLGdCQUFFRSxHQUFGLENBQU1GLFdBQU4sRUFBbUJQLFNBQVNYLFdBQTVCLEVBQXlDLEtBQXpDLENBQWQ7QUFDRCxpQkFGRCxNQUVPO0FBQ0xrQixnQ0FBYyxnQkFBRUUsR0FBRixDQUFNRixXQUFOLEVBQW1CUCxTQUFTWCxXQUE1QixFQUF5QyxFQUF6QyxDQUFkO0FBQ0Q7O0FBRUQsdUJBQU8sT0FBS3FCLGdCQUFMLENBQ0w7QUFDRXBNLDRCQUFVaU07QUFEWixpQkFESyxFQUlMLFlBQU07QUFDSjVJLHNDQUNFQSxpQkFBaUI0SSxXQUFqQixFQUE4QlAsU0FBU1gsV0FBdkMsRUFBb0RyQixDQUFwRCxDQURGO0FBRUQsaUJBUEksQ0FBUDtBQVNELGVBakJEOztBQW1CQTtBQUNBLGtCQUFJMkMsZUFBZSxnQkFBRXhELGtCQUFGLENBQ2pCZixPQUFPd0UsSUFEVSxFQUVqQlosUUFGaUIsRUFHakJ4RSxLQUhpQixDQUFuQjs7QUFNQTtBQUNBLGtCQUFNcUYsOEJBQ0p6RSxPQUFPMEUsVUFBUCxLQUNDLENBQUMxRSxPQUFPMkUsU0FBUixHQUFvQm5JLG1CQUFwQixHQUEwQ3dELE9BQU93RSxJQURsRCxDQURGO0FBR0Esa0JBQU1JLDRCQUNKNUUsT0FBTzZFLFFBQVAsSUFBbUJ4SSxpQkFEckI7QUFFQSxrQkFBTXlJLDhCQUNKOUUsT0FBTytFLFVBQVAsSUFBcUJ6SSxtQkFEdkI7QUFFQSxrQkFBTTBJLGdDQUNKekksa0JBQ0M7QUFBQSx1QkFDQztBQUFBO0FBQUE7QUFDRSxnREFBQyx5QkFBRCxFQUErQjdGLEtBQS9CLENBREY7QUFFRSxnREFBQywyQkFBRCxFQUFpQ0EsS0FBakM7QUFGRixpQkFERDtBQUFBLGVBRkg7QUFPQSxrQkFBTXVPLHlCQUNKakYsT0FBT2tGLEtBQVAsSUFBZ0JGLDZCQURsQjs7QUFHQTtBQUNBLGtCQUFJcEIsU0FBU0MsT0FBVCxJQUFvQkQsU0FBU0UsUUFBakMsRUFBMkM7QUFDekM7QUFDQUYseUJBQVN1QixVQUFULEdBQXNCLElBQXRCO0FBQ0FwQixxQ0FBcUIsSUFBckI7QUFDQTtBQUNBLG9CQUFJSCxTQUFTQyxPQUFULElBQW9CLENBQUNELFNBQVNSLE9BQTlCLElBQXlDLENBQUNsSCxZQUE5QyxFQUE0RDtBQUMxRDBILDJCQUFTdUIsVUFBVCxHQUFzQixLQUF0QjtBQUNEO0FBQ0Y7O0FBRUQsa0JBQUl2QixTQUFTQyxPQUFiLEVBQXNCO0FBQ3BCO0FBQ0FHLDJCQUNFbkIsUUFBUXpFLEdBQVIsQ0FBWXZELFVBQVosTUFBNEJtRixPQUFPZCxFQUFuQyxJQUF5QzBFLFNBQVNSLE9BRHBEO0FBRUE7QUFDQWEsNEJBQ0VsSixRQUFRcUssT0FBUixDQUFnQnBGLE9BQU9kLEVBQXZCLElBQ0VuRSxRQUFRcUssT0FBUixDQUFnQnZDLFFBQVF6RSxHQUFSLENBQVl2RCxVQUFaLENBQWhCLENBREYsSUFDOEMrSSxTQUFTUixPQUZ6RDtBQUdBO0FBQ0Esb0JBQUlZLFFBQUosRUFBYztBQUNaO0FBQ0FPLGlDQUFlLGdCQUFFeEQsa0JBQUYsQ0FDYmtFLHNCQURhLGVBR1JyQixRQUhRO0FBSVh4RSwyQkFBT2hCLElBQUl0RCxXQUFKO0FBSkksc0JBTWJzRCxJQUFJdEQsV0FBSixDQU5hLENBQWY7QUFRRCxpQkFWRCxNQVVPLElBQUltSixTQUFKLEVBQWU7QUFDcEI7QUFDQU0saUNBQWUsZ0JBQUV4RCxrQkFBRixDQUNiMEQsMkJBRGEsRUFFYmIsUUFGYSxFQUdieEUsS0FIYSxDQUFmO0FBS0QsaUJBUE0sTUFPQTtBQUNMbUYsaUNBQWUsSUFBZjtBQUNEO0FBQ0YsZUE3QkQsTUE2Qk8sSUFBSVgsU0FBU1YsVUFBYixFQUF5QjtBQUM5QnFCLCtCQUFlLGdCQUFFeEQsa0JBQUYsQ0FDYjBELDJCQURhLEVBRWJiLFFBRmEsRUFHYnhFLEtBSGEsQ0FBZjtBQUtEOztBQUVELGtCQUFJd0UsU0FBU0UsUUFBYixFQUF1QjtBQUNyQlMsK0JBQWUsZ0JBQUV4RCxrQkFBRixDQUNiNkQseUJBRGEsRUFFYmhCLFFBRmEsRUFHYnhGLElBQUl0RCxXQUFKLENBSGEsQ0FBZjtBQUtBLG9CQUFJQyxPQUFKLEVBQWE7QUFDWCxzQkFBSTZJLFNBQVNULGNBQWIsRUFBNkI7QUFDM0JvQixtQ0FBZSxJQUFmO0FBQ0Q7QUFDRCxzQkFBSSxDQUFDWCxTQUFTUixPQUFWLElBQXFCLENBQUNsSCxZQUExQixFQUF3QztBQUN0Q3FJLG1DQUFlLElBQWY7QUFDRDtBQUNGO0FBQ0Y7O0FBRUQsa0JBQU1jLDBCQUEwQnRCLHFCQUM1QkcsZUFENEIsR0FFNUIsWUFBTSxDQUFFLENBRlo7O0FBSUE7QUFDQSxrQkFBTW9CLG1CQUFtQjtBQUN2QkMseUJBQVNGO0FBRGMsZUFBekI7O0FBSUEsa0JBQUkzQixRQUFRNUQsSUFBUixDQUFheUYsT0FBakIsRUFBMEI7QUFDeEJELGlDQUFpQkMsT0FBakIsR0FBMkIsYUFBSztBQUM5QjdCLDBCQUFRNUQsSUFBUixDQUFheUYsT0FBYixDQUFxQjNELENBQXJCLEVBQXdCO0FBQUEsMkJBQU15RCx3QkFBd0J6RCxDQUF4QixDQUFOO0FBQUEsbUJBQXhCO0FBQ0QsaUJBRkQ7QUFHRDs7QUFFRCxrQkFBSStCLFlBQVk3RCxJQUFaLENBQWlCeUYsT0FBckIsRUFBOEI7QUFDNUJELGlDQUFpQkMsT0FBakIsR0FBMkIsYUFBSztBQUM5QjVCLDhCQUFZN0QsSUFBWixDQUFpQnlGLE9BQWpCLENBQXlCM0QsQ0FBekIsRUFBNEI7QUFBQSwyQkFBTXlELHdCQUF3QnpELENBQXhCLENBQU47QUFBQSxtQkFBNUI7QUFDRCxpQkFGRDtBQUdEOztBQUVEO0FBQ0EscUJBQ0U7QUFBQywyQkFBRDtBQUFBO0FBQ0UsdUJBQUs2QixLQUFLLEdBQUwsR0FBV3pELE9BQU9kLEVBRHpCO0FBRUUsNkJBQVcsMEJBQ1R1QixPQURTLEVBRVQsQ0FBQ2UsSUFBRCxJQUFTLFFBRkEsRUFHVG9DLFNBQVN1QixVQUFULElBQXVCLGVBSGQsRUFJVCxDQUFDbkIsWUFBWUMsU0FBYixLQUEyQixVQUpsQixDQUZiO0FBUUUsc0NBQ0t0RCxNQURMO0FBRUVSLDBCQUFTZCxLQUFULFlBRkY7QUFHRUEsMkJBQU8sZ0JBQUV5QixJQUFGLENBQU96QixLQUFQLENBSFQ7QUFJRWdCLDhCQUFVLGdCQUFFUyxJQUFGLENBQU9ULFFBQVA7QUFKWjtBQVJGLG1CQWNNcUQsUUFBUTVELElBZGQsRUFlTTZELFlBQVk3RCxJQWZsQixFQWdCTXdGLGdCQWhCTjtBQWtCR2Y7QUFsQkgsZUFERjtBQXNCRCxhQWhOQTtBQVJILFdBREY7QUEyTkcxQixrQkFBUU8sT0FBUixJQUNDQyxVQURELElBRUNSLFFBQVFPLE9BQVIsQ0FBZ0JqRixHQUFoQixDQUFvQixVQUFDUCxDQUFELEVBQUlTLENBQUo7QUFBQSxtQkFDbEJ1RSxZQUFZaEYsQ0FBWixFQUFlUyxDQUFmLEVBQWtCd0UsUUFBUUksV0FBMUIsQ0FEa0I7QUFBQSxXQUFwQixDQTdOSjtBQWdPRy9HLDBCQUNDLENBQUMyRyxRQUFRTyxPQURWLElBRUNDLFVBRkQsSUFHQ25ILGFBQWEyRyxPQUFiO0FBbk9KLFNBREY7QUF1T0QsT0F4UEQ7O0FBMFBBLFVBQU0yQyxhQUFhLFNBQWJBLFVBQWEsQ0FBQ3BILEdBQUQsRUFBTUMsQ0FBTixFQUFZO0FBQzdCLFlBQU1pRixlQUFlNUosZ0JBQ25COEYsVUFEbUIsRUFFbkJJLFNBRm1CLEVBR25CQSxTQUhtQixTQUFyQjtBQU1BLFlBQU0yRCxVQUFVLGdCQUFFNUQsVUFBRixDQUNkaEcsV0FBVzZGLFVBQVgsRUFBdUJJLFNBQXZCLEVBQWtDQSxTQUFsQyxTQURjLENBQWhCO0FBR0EsZUFDRTtBQUFDLDBCQUFEO0FBQUEscUJBQWtCLEtBQUt2QixDQUF2QixJQUE4QmlGLFlBQTlCO0FBQ0U7QUFBQyx1QkFBRDtBQUFBO0FBQ0UseUJBQVcsMEJBQ1QsU0FEUyxFQUVULENBQUNwRyxTQUFTTyxNQUFULEdBQWtCWSxDQUFuQixJQUF3QixDQUF4QixHQUE0QixPQUE1QixHQUFzQyxNQUY3QixFQUdUa0YsUUFBUTNLLFNBSEMsQ0FEYjtBQU1FLHFCQUFPMkssUUFBUTFLLEtBQVIsSUFBaUI7QUFOMUI7QUFRRytELDhCQUFrQnVCLEdBQWxCLENBQXNCc0gsYUFBdEI7QUFSSDtBQURGLFNBREY7QUFjRCxPQXhCRDs7QUEwQkEsVUFBTUEsZ0JBQWdCLFNBQWhCQSxhQUFnQixDQUFDekYsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ25DLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1zQyxPQUNKLE9BQU94QixPQUFPd0IsSUFBZCxLQUF1QixVQUF2QixHQUFvQ3hCLE9BQU93QixJQUFQLEVBQXBDLEdBQW9EeEIsT0FBT3dCLElBRDdEO0FBRUEsWUFBSW5DLFFBQVEsZ0JBQUVGLGVBQUYsQ0FDVm1DLFdBQVdsQyxLQURELEVBRVZZLE9BQU9YLEtBRkcsRUFHVlcsT0FBT1YsUUFIRyxDQUFaO0FBS0EsWUFBSWEsT0FBT2QsS0FBWDtBQUNBLFlBQUlnQixXQUFXLGdCQUFFbEIsZUFBRixDQUNibUMsV0FBV2xDLEtBREUsRUFFYlksT0FBT1gsS0FGTSxFQUdiVyxPQUFPSyxRQUhNLENBQWY7QUFLQSxZQUFNcUQsVUFBVSxnQkFBRS9ELFVBQUYsQ0FDZC9GLFdBQVc0RixVQUFYLEVBQXVCSSxTQUF2QixFQUFrQ0ksTUFBbEMsU0FEYyxDQUFoQjtBQUdBLFlBQU0yRCxjQUFjLGdCQUFFaEUsVUFBRixDQUNsQkssT0FBT2xILFFBQVAsQ0FBZ0IwRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNJLE1BQXZDLFNBRGtCLENBQXBCOztBQUlBLFlBQU1TLFVBQVUsQ0FDZGlELFFBQVE5SyxTQURNLEVBRWRvSCxPQUFPcEgsU0FGTyxFQUdkK0ssWUFBWS9LLFNBSEUsQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEK0MsUUFBUTdLLEtBRFAsRUFFRG1ILE9BQU9uSCxLQUZOLEVBR0Q4SyxZQUFZOUssS0FIWCxDQUFOOztBQU1BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUt3RixJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLEVBQW9CLENBQUNlLElBQUQsSUFBUyxRQUE3QixDQUZiO0FBR0UsZ0NBQ0tiLE1BREw7QUFFRVIsb0JBQVNBLElBQVQsWUFGRjtBQUdFZCxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTXFELFFBQVE1RCxJQVRkO0FBV0csMEJBQUVpQixrQkFBRixDQUFxQnJFLGVBQXJCO0FBWEgsU0FERjtBQWVELE9BakREOztBQW1EQSxVQUFNZ0osb0JBQW9CLFNBQXBCQSxpQkFBb0IsR0FBTTtBQUM5QixZQUFNQyxhQUFhOUwsY0FBYzJGLFVBQWQsRUFBMEJJLFNBQTFCLEVBQXFDQSxTQUFyQyxTQUFuQjtBQUNBLFlBQU1nRyxlQUFlLGdCQUFFakcsVUFBRixDQUNuQjdGLGdCQUFnQjBGLFVBQWhCLEVBQTRCSSxTQUE1QixFQUF1Q0EsU0FBdkMsU0FEbUIsQ0FBckI7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXK0YsV0FBVy9NLFNBRHhCO0FBRUUsZ0NBQ0srTSxXQUFXOU0sS0FEaEI7QUFFRXlHLHdCQUFhVCxXQUFiO0FBRkY7QUFGRixhQU1NOEcsV0FBVzdGLElBTmpCO0FBUUU7QUFBQyx1QkFBRDtBQUFBO0FBQ0UseUJBQVcsMEJBQVc4RixhQUFhaE4sU0FBeEIsQ0FEYjtBQUVFLHFCQUFPZ04sYUFBYS9NO0FBRnRCLGVBR00rTSxhQUFhOUYsSUFIbkI7QUFLR2xELDhCQUFrQnVCLEdBQWxCLENBQXNCMEgsZ0JBQXRCO0FBTEg7QUFSRixTQURGO0FBa0JELE9BdkJEOztBQXlCQSxVQUFNQSxtQkFBbUIsU0FBbkJBLGdCQUFtQixDQUFDN0YsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ3RDLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1zQyxPQUNKLE9BQU94QixPQUFPd0IsSUFBZCxLQUF1QixVQUF2QixHQUFvQ3hCLE9BQU93QixJQUFQLEVBQXBDLEdBQW9EeEIsT0FBT3dCLElBRDdEO0FBRUEsWUFBTW5DLFFBQVEsZ0JBQUVGLGVBQUYsQ0FDWm1DLFdBQVdsQyxLQURDLEVBRVpZLE9BQU9YLEtBRkssRUFHWlcsT0FBT1YsUUFISyxDQUFkO0FBS0EsWUFBTWUsV0FBVyxnQkFBRWxCLGVBQUYsQ0FDZm1DLFdBQVdsQyxLQURJLEVBRWZZLE9BQU9YLEtBRlEsRUFHZlcsT0FBT0ssUUFIUSxDQUFqQjtBQUtBLFlBQU15RixlQUFlLGdCQUFFbkcsVUFBRixDQUNuQjVGLGdCQUFnQnlGLFVBQWhCLEVBQTRCSSxTQUE1QixFQUF1Q0EsU0FBdkMsU0FEbUIsQ0FBckI7QUFHQSxZQUFNK0QsY0FBYyxnQkFBRWhFLFVBQUYsQ0FDbEJLLE9BQU9sSCxRQUFQLENBQWdCMEcsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDSSxNQUF2QyxTQURrQixDQUFwQjtBQUdBLFlBQU0rRixvQkFBb0IsZ0JBQUVwRyxVQUFGLENBQ3hCSyxPQUFPZ0csY0FBUCxDQUFzQnhHLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0ksTUFBN0MsU0FEd0IsQ0FBMUI7O0FBSUEsWUFBTVMsVUFBVSxDQUNkcUYsYUFBYWxOLFNBREMsRUFFZG9ILE9BQU9wSCxTQUZPLEVBR2QrSyxZQUFZL0ssU0FIRSxFQUlkbU4sa0JBQWtCbk4sU0FKSixDQUFoQjs7QUFPQSxZQUFNK0gsc0JBQ0RtRixhQUFhak4sS0FEWixFQUVEbUgsT0FBT25ILEtBRk4sRUFHRDhLLFlBQVk5SyxLQUhYLEVBSURrTixrQkFBa0JsTixLQUpqQixDQUFOOztBQU9BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUt3RixJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLEVBQW9CLENBQUNlLElBQUQsSUFBUyxRQUE3QixDQUZiO0FBR0UsZ0NBQ0tiLE1BREw7QUFFRVIsb0JBQVNkLEtBQVQsWUFGRjtBQUdFQSxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTXNELFlBQVk3RCxJQVRsQixFQVVNZ0csYUFBYWhHLElBVm5CLEVBV01pRyxrQkFBa0JqRyxJQVh4QjtBQWFHLDBCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9uQyxNQUE1QixFQUFvQztBQUNuQ29ELGtCQUFNbEUsVUFENkI7QUFFbkNpRCxvQkFBUUE7QUFGMkIsV0FBcEM7QUFiSCxTQURGO0FBb0JELE9BMUREOztBQTREQSxVQUFNaUcsaUJBQWlCLFNBQWpCQSxjQUFpQixHQUFNO0FBQzNCLFlBQU1DLGtCQUFrQixnQkFBRXZHLFVBQUYsQ0FDdEIzRixtQkFBbUJ3RixVQUFuQixFQUErQkksU0FBL0IsRUFBMENBLFNBQTFDLFNBRHNCLENBQXhCO0FBR0EsZUFDRSw4QkFBQyxtQkFBRCxlQUNNbEgsYUFETjtBQUVFLGlCQUFPNEMsS0FGVDtBQUdFLHVCQUFhcUQsV0FIZjtBQUlFLG1CQUFTQyxPQUpYO0FBS0Usd0JBQWMsT0FBS3ZILFlBTHJCO0FBTUUsNEJBQWtCLE9BQUtDLGdCQU56QjtBQU9FLHFCQUFXNE8sZ0JBQWdCdE4sU0FQN0I7QUFRRSxpQkFBT3NOLGdCQUFnQnJOO0FBUnpCLFdBU01xTixnQkFBZ0JwRyxJQVR0QixFQURGO0FBYUQsT0FqQkQ7O0FBbUJBLFVBQU1xRyxZQUFZLGdCQUFFeEcsVUFBRixDQUNoQjdHLFNBQVMwRyxVQUFULEVBQXFCSSxTQUFyQixFQUFnQ0EsU0FBaEMsRUFBMkMsSUFBM0MsQ0FEZ0IsQ0FBbEI7QUFHQSxVQUFNd0csYUFBYSxnQkFBRXpHLFVBQUYsQ0FDakI1RyxjQUFjeUcsVUFBZCxFQUEwQkksU0FBMUIsRUFBcUNBLFNBQXJDLEVBQWdELElBQWhELENBRGlCLENBQW5CO0FBR0EsVUFBTXlHLGFBQWEsZ0JBQUUxRyxVQUFGLENBQ2pCbEcsY0FBYytGLFVBQWQsRUFBMEJJLFNBQTFCLEVBQXFDQSxTQUFyQyxFQUFnRCxJQUFoRCxDQURpQixDQUFuQjtBQUdBLFVBQU0wRyxlQUFlck0sZ0JBQWdCdUYsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDQSxTQUF2QyxFQUFrRCxJQUFsRCxDQUFyQjtBQUNBLFVBQU0yRyxjQUFjck0sZUFBZXNGLFVBQWYsRUFBMkJJLFNBQTNCLEVBQXNDQSxTQUF0QyxFQUFpRCxJQUFqRCxDQUFwQjtBQUNBLFVBQU1pQyxlQUFlMUgsZ0JBQWdCcUYsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDQSxTQUF2QyxFQUFrRCxJQUFsRCxDQUFyQjs7QUFFQSxVQUFNNEcsWUFBWSxTQUFaQSxTQUFZLEdBQU07QUFDdEIsWUFBTUMsYUFBYVIsZ0JBQW5CO0FBQ0EsZUFDRTtBQUFBO0FBQUE7QUFDRSx1QkFBVywwQkFBVyxZQUFYLEVBQXlCck4sU0FBekIsRUFBb0N1TixVQUFVdk4sU0FBOUMsQ0FEYjtBQUVFLGdDQUNLQyxLQURMLEVBRUtzTixVQUFVdE4sS0FGZjtBQUZGLGFBTU1zTixVQUFVckcsSUFOaEI7QUFRRzFGLDRCQUFrQkMsaUJBQWxCLEdBQ0c7QUFBQTtBQUFBLGNBQUssV0FBVSxnQkFBZjtBQUNDb007QUFERCxXQURILEdBSUcsSUFaTjtBQWFFO0FBQUMsMEJBQUQ7QUFBQTtBQUNFLHlCQUFXLDBCQUNUTCxXQUFXeE4sU0FERixFQUVUSixvQkFBb0IsYUFBcEIsR0FBb0MsRUFGM0IsQ0FEYjtBQUtFLHFCQUFPNE4sV0FBV3ZOO0FBTHBCLGVBTU11TixXQUFXdEcsSUFOakI7QUFRR2hELDhCQUFrQjJDLGtCQUFsQixHQUF1QyxJQVIxQztBQVNHeUIseUJBVEg7QUFVR3BELHlCQUFhb0UsYUFBYixHQUE2QixJQVZoQztBQVdFO0FBQUMsNEJBQUQ7QUFBQTtBQUNFLDJCQUFXLDBCQUFXbUUsV0FBV3pOLFNBQXRCLENBRGI7QUFFRSxvQ0FDS3lOLFdBQVd4TixLQURoQjtBQUVFeUcsNEJBQWFULFdBQWI7QUFGRjtBQUZGLGlCQU1Nd0gsV0FBV3ZHLElBTmpCO0FBUUc1Qyx1QkFBU2lCLEdBQVQsQ0FBYSxVQUFDUCxDQUFELEVBQUlTLENBQUo7QUFBQSx1QkFBVXVFLFlBQVloRixDQUFaLEVBQWVTLENBQWYsQ0FBVjtBQUFBLGVBQWIsQ0FSSDtBQVNHaEIsc0JBQVFjLEdBQVIsQ0FBWXFILFVBQVo7QUFUSCxhQVhGO0FBc0JHOUgsOEJBQWtCZ0ksbUJBQWxCLEdBQXdDO0FBdEIzQyxXQWJGO0FBcUNHdEwsNEJBQWtCRSxvQkFBbEIsR0FDRztBQUFBO0FBQUEsY0FBSyxXQUFVLG1CQUFmO0FBQ0NtTTtBQURELFdBREgsR0FJRyxJQXpDTjtBQTBDRyxXQUFDdkosU0FBU08sTUFBVixJQUNDO0FBQUMsMkJBQUQ7QUFBcUI4SSx1QkFBckI7QUFDRyw0QkFBRXhGLGtCQUFGLENBQXFCdEcsVUFBckI7QUFESCxXQTNDSjtBQThDRSx3Q0FBQyxnQkFBRDtBQUNFLHFCQUFTWSxPQURYO0FBRUUseUJBQWFiO0FBRmYsYUFHTThMLFlBSE47QUE5Q0YsU0FERjtBQXNERCxPQXhERDs7QUEwREE7QUFDQSxhQUFPM04sV0FBV0EsU0FBUzZHLFVBQVQsRUFBcUJnSCxTQUFyQixFQUFnQyxJQUFoQyxDQUFYLEdBQW1EQSxXQUExRDtBQUNEOzs7O0VBLzlCcUMsdUJBQVEsMENBQVIsQzs7QUFBbkIvUCxVLENBQ1ppUSxZO2tCQURZalEsVSIsImZpbGUiOiJpbmRleC5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBSZWFjdCwgeyBDb21wb25lbnQgfSBmcm9tICdyZWFjdCdcbmltcG9ydCBjbGFzc25hbWVzIGZyb20gJ2NsYXNzbmFtZXMnXG4vL1xuaW1wb3J0IF8gZnJvbSAnLi91dGlscydcbmltcG9ydCBMaWZlY3ljbGUgZnJvbSAnLi9saWZlY3ljbGUnXG5pbXBvcnQgTWV0aG9kcyBmcm9tICcuL21ldGhvZHMnXG5pbXBvcnQgZGVmYXVsdFByb3BzIGZyb20gJy4vZGVmYXVsdFByb3BzJ1xuXG5leHBvcnQgY29uc3QgUmVhY3RUYWJsZURlZmF1bHRzID0gZGVmYXVsdFByb3BzXG5cbmV4cG9ydCBkZWZhdWx0IGNsYXNzIFJlYWN0VGFibGUgZXh0ZW5kcyBNZXRob2RzKExpZmVjeWNsZShDb21wb25lbnQpKSB7XG4gIHN0YXRpYyBkZWZhdWx0UHJvcHMgPSBkZWZhdWx0UHJvcHNcblxuICBjb25zdHJ1Y3RvciAocHJvcHMpIHtcbiAgICBzdXBlcigpXG5cbiAgICB0aGlzLmdldFJlc29sdmVkU3RhdGUgPSB0aGlzLmdldFJlc29sdmVkU3RhdGUuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0RGF0YU1vZGVsID0gdGhpcy5nZXREYXRhTW9kZWwuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0U29ydGVkRGF0YSA9IHRoaXMuZ2V0U29ydGVkRGF0YS5iaW5kKHRoaXMpXG4gICAgdGhpcy5maXJlRmV0Y2hEYXRhID0gdGhpcy5maXJlRmV0Y2hEYXRhLmJpbmQodGhpcylcbiAgICB0aGlzLmdldFByb3BPclN0YXRlID0gdGhpcy5nZXRQcm9wT3JTdGF0ZS5iaW5kKHRoaXMpXG4gICAgdGhpcy5nZXRTdGF0ZU9yUHJvcCA9IHRoaXMuZ2V0U3RhdGVPclByb3AuYmluZCh0aGlzKVxuICAgIHRoaXMuZmlsdGVyRGF0YSA9IHRoaXMuZmlsdGVyRGF0YS5iaW5kKHRoaXMpXG4gICAgdGhpcy5zb3J0RGF0YSA9IHRoaXMuc29ydERhdGEuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0TWluUm93cyA9IHRoaXMuZ2V0TWluUm93cy5iaW5kKHRoaXMpXG4gICAgdGhpcy5vblBhZ2VDaGFuZ2UgPSB0aGlzLm9uUGFnZUNoYW5nZS5iaW5kKHRoaXMpXG4gICAgdGhpcy5vblBhZ2VTaXplQ2hhbmdlID0gdGhpcy5vblBhZ2VTaXplQ2hhbmdlLmJpbmQodGhpcylcbiAgICB0aGlzLnNvcnRDb2x1bW4gPSB0aGlzLnNvcnRDb2x1bW4uYmluZCh0aGlzKVxuICAgIHRoaXMuZmlsdGVyQ29sdW1uID0gdGhpcy5maWx0ZXJDb2x1bW4uYmluZCh0aGlzKVxuICAgIHRoaXMucmVzaXplQ29sdW1uU3RhcnQgPSB0aGlzLnJlc2l6ZUNvbHVtblN0YXJ0LmJpbmQodGhpcylcbiAgICB0aGlzLnJlc2l6ZUNvbHVtbkVuZCA9IHRoaXMucmVzaXplQ29sdW1uRW5kLmJpbmQodGhpcylcbiAgICB0aGlzLnJlc2l6ZUNvbHVtbk1vdmluZyA9IHRoaXMucmVzaXplQ29sdW1uTW92aW5nLmJpbmQodGhpcylcblxuICAgIHRoaXMuc3RhdGUgPSB7XG4gICAgICBwYWdlOiAwLFxuICAgICAgcGFnZVNpemU6IHByb3BzLmRlZmF1bHRQYWdlU2l6ZSxcbiAgICAgIHNvcnRlZDogcHJvcHMuZGVmYXVsdFNvcnRlZCxcbiAgICAgIGV4cGFuZGVkOiBwcm9wcy5kZWZhdWx0RXhwYW5kZWQsXG4gICAgICBmaWx0ZXJlZDogcHJvcHMuZGVmYXVsdEZpbHRlcmVkLFxuICAgICAgcmVzaXplZDogcHJvcHMuZGVmYXVsdFJlc2l6ZWQsXG4gICAgICBjdXJyZW50bHlSZXNpemluZzogZmFsc2UsXG4gICAgICBza2lwTmV4dFNvcnQ6IGZhbHNlLFxuICAgIH1cbiAgfVxuXG4gIHJlbmRlciAoKSB7XG4gICAgY29uc3QgcmVzb2x2ZWRTdGF0ZSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpXG4gICAgY29uc3Qge1xuICAgICAgY2hpbGRyZW4sXG4gICAgICBjbGFzc05hbWUsXG4gICAgICBzdHlsZSxcbiAgICAgIGdldFByb3BzLFxuICAgICAgZ2V0VGFibGVQcm9wcyxcbiAgICAgIGdldFRoZWFkR3JvdXBQcm9wcyxcbiAgICAgIGdldFRoZWFkR3JvdXBUclByb3BzLFxuICAgICAgZ2V0VGhlYWRHcm91cFRoUHJvcHMsXG4gICAgICBnZXRUaGVhZFByb3BzLFxuICAgICAgZ2V0VGhlYWRUclByb3BzLFxuICAgICAgZ2V0VGhlYWRUaFByb3BzLFxuICAgICAgZ2V0VGhlYWRGaWx0ZXJQcm9wcyxcbiAgICAgIGdldFRoZWFkRmlsdGVyVHJQcm9wcyxcbiAgICAgIGdldFRoZWFkRmlsdGVyVGhQcm9wcyxcbiAgICAgIGdldFRib2R5UHJvcHMsXG4gICAgICBnZXRUckdyb3VwUHJvcHMsXG4gICAgICBnZXRUclByb3BzLFxuICAgICAgZ2V0VGRQcm9wcyxcbiAgICAgIGdldFRmb290UHJvcHMsXG4gICAgICBnZXRUZm9vdFRyUHJvcHMsXG4gICAgICBnZXRUZm9vdFRkUHJvcHMsXG4gICAgICBnZXRQYWdpbmF0aW9uUHJvcHMsXG4gICAgICBnZXRMb2FkaW5nUHJvcHMsXG4gICAgICBnZXROb0RhdGFQcm9wcyxcbiAgICAgIGdldFJlc2l6ZXJQcm9wcyxcbiAgICAgIHNob3dQYWdpbmF0aW9uLFxuICAgICAgc2hvd1BhZ2luYXRpb25Ub3AsXG4gICAgICBzaG93UGFnaW5hdGlvbkJvdHRvbSxcbiAgICAgIG1hbnVhbCxcbiAgICAgIGxvYWRpbmdUZXh0LFxuICAgICAgbm9EYXRhVGV4dCxcbiAgICAgIHNvcnRhYmxlLFxuICAgICAgcmVzaXphYmxlLFxuICAgICAgZmlsdGVyYWJsZSxcbiAgICAgIC8vIFBpdm90aW5nIFN0YXRlXG4gICAgICBwaXZvdElES2V5LFxuICAgICAgcGl2b3RWYWxLZXksXG4gICAgICBwaXZvdEJ5LFxuICAgICAgc3ViUm93c0tleSxcbiAgICAgIGFnZ3JlZ2F0ZWRLZXksXG4gICAgICBvcmlnaW5hbEtleSxcbiAgICAgIGluZGV4S2V5LFxuICAgICAgZ3JvdXBlZEJ5UGl2b3RLZXksXG4gICAgICAvLyBTdGF0ZVxuICAgICAgbG9hZGluZyxcbiAgICAgIHBhZ2VTaXplLFxuICAgICAgcGFnZSxcbiAgICAgIHNvcnRlZCxcbiAgICAgIGZpbHRlcmVkLFxuICAgICAgcmVzaXplZCxcbiAgICAgIGV4cGFuZGVkLFxuICAgICAgcGFnZXMsXG4gICAgICBvbkV4cGFuZGVkQ2hhbmdlLFxuICAgICAgLy8gQ29tcG9uZW50c1xuICAgICAgVGFibGVDb21wb25lbnQsXG4gICAgICBUaGVhZENvbXBvbmVudCxcbiAgICAgIFRib2R5Q29tcG9uZW50LFxuICAgICAgVHJHcm91cENvbXBvbmVudCxcbiAgICAgIFRyQ29tcG9uZW50LFxuICAgICAgVGhDb21wb25lbnQsXG4gICAgICBUZENvbXBvbmVudCxcbiAgICAgIFRmb290Q29tcG9uZW50LFxuICAgICAgUGFnaW5hdGlvbkNvbXBvbmVudCxcbiAgICAgIExvYWRpbmdDb21wb25lbnQsXG4gICAgICBTdWJDb21wb25lbnQsXG4gICAgICBOb0RhdGFDb21wb25lbnQsXG4gICAgICBSZXNpemVyQ29tcG9uZW50LFxuICAgICAgRXhwYW5kZXJDb21wb25lbnQsXG4gICAgICBQaXZvdFZhbHVlQ29tcG9uZW50LFxuICAgICAgUGl2b3RDb21wb25lbnQsXG4gICAgICBBZ2dyZWdhdGVkQ29tcG9uZW50LFxuICAgICAgRmlsdGVyQ29tcG9uZW50LFxuICAgICAgUGFkUm93Q29tcG9uZW50LFxuICAgICAgLy8gRGF0YSBtb2RlbFxuICAgICAgcmVzb2x2ZWREYXRhLFxuICAgICAgYWxsVmlzaWJsZUNvbHVtbnMsXG4gICAgICBoZWFkZXJHcm91cHMsXG4gICAgICBoYXNIZWFkZXJHcm91cHMsXG4gICAgICAvLyBTb3J0ZWQgRGF0YVxuICAgICAgc29ydGVkRGF0YSxcbiAgICAgIGN1cnJlbnRseVJlc2l6aW5nLFxuICAgIH0gPSByZXNvbHZlZFN0YXRlXG5cbiAgICAvLyBQYWdpbmF0aW9uXG4gICAgY29uc3Qgc3RhcnRSb3cgPSBwYWdlU2l6ZSAqIHBhZ2VcbiAgICBjb25zdCBlbmRSb3cgPSBzdGFydFJvdyArIHBhZ2VTaXplXG4gICAgbGV0IHBhZ2VSb3dzID0gbWFudWFsID8gcmVzb2x2ZWREYXRhIDogc29ydGVkRGF0YS5zbGljZShzdGFydFJvdywgZW5kUm93KVxuICAgIGNvbnN0IG1pblJvd3MgPSB0aGlzLmdldE1pblJvd3MoKVxuICAgIGNvbnN0IHBhZFJvd3MgPSBfLnJhbmdlKE1hdGgubWF4KG1pblJvd3MgLSBwYWdlUm93cy5sZW5ndGgsIDApKVxuXG4gICAgY29uc3QgaGFzQ29sdW1uRm9vdGVyID0gYWxsVmlzaWJsZUNvbHVtbnMuc29tZShkID0+IGQuRm9vdGVyKVxuICAgIGNvbnN0IGhhc0ZpbHRlcnMgPSBmaWx0ZXJhYmxlIHx8IGFsbFZpc2libGVDb2x1bW5zLnNvbWUoZCA9PiBkLmZpbHRlcmFibGUpXG5cbiAgICBjb25zdCByZWN1cnNlUm93c1ZpZXdJbmRleCA9IChyb3dzLCBwYXRoID0gW10sIGluZGV4ID0gLTEpID0+IHtcbiAgICAgIHJldHVybiBbXG4gICAgICAgIHJvd3MubWFwKChyb3csIGkpID0+IHtcbiAgICAgICAgICBpbmRleCsrXG4gICAgICAgICAgY29uc3Qgcm93V2l0aFZpZXdJbmRleCA9IHtcbiAgICAgICAgICAgIC4uLnJvdyxcbiAgICAgICAgICAgIF92aWV3SW5kZXg6IGluZGV4LFxuICAgICAgICAgIH1cbiAgICAgICAgICBjb25zdCBuZXdQYXRoID0gcGF0aC5jb25jYXQoW2ldKVxuICAgICAgICAgIGlmIChyb3dXaXRoVmlld0luZGV4W3N1YlJvd3NLZXldICYmIF8uZ2V0KGV4cGFuZGVkLCBuZXdQYXRoKSkge1xuICAgICAgICAgICAgO1tyb3dXaXRoVmlld0luZGV4W3N1YlJvd3NLZXldLCBpbmRleF0gPSByZWN1cnNlUm93c1ZpZXdJbmRleChcbiAgICAgICAgICAgICAgcm93V2l0aFZpZXdJbmRleFtzdWJSb3dzS2V5XSxcbiAgICAgICAgICAgICAgbmV3UGF0aCxcbiAgICAgICAgICAgICAgaW5kZXhcbiAgICAgICAgICAgIClcbiAgICAgICAgICB9XG4gICAgICAgICAgcmV0dXJuIHJvd1dpdGhWaWV3SW5kZXhcbiAgICAgICAgfSksXG4gICAgICAgIGluZGV4LFxuICAgICAgXVxuICAgIH1cbiAgICA7W3BhZ2VSb3dzXSA9IHJlY3Vyc2VSb3dzVmlld0luZGV4KHBhZ2VSb3dzKVxuXG4gICAgY29uc3QgY2FuUHJldmlvdXMgPSBwYWdlID4gMFxuICAgIGNvbnN0IGNhbk5leHQgPSBwYWdlICsgMSA8IHBhZ2VzXG5cbiAgICBjb25zdCByb3dNaW5XaWR0aCA9IF8uc3VtKFxuICAgICAgYWxsVmlzaWJsZUNvbHVtbnMubWFwKGQgPT4ge1xuICAgICAgICBjb25zdCByZXNpemVkQ29sdW1uID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gZC5pZCkgfHwge31cbiAgICAgICAgcmV0dXJuIF8uZ2V0Rmlyc3REZWZpbmVkKHJlc2l6ZWRDb2x1bW4udmFsdWUsIGQud2lkdGgsIGQubWluV2lkdGgpXG4gICAgICB9KVxuICAgIClcblxuICAgIGxldCByb3dJbmRleCA9IC0xXG5cbiAgICBjb25zdCBmaW5hbFN0YXRlID0ge1xuICAgICAgLi4ucmVzb2x2ZWRTdGF0ZSxcbiAgICAgIHN0YXJ0Um93LFxuICAgICAgZW5kUm93LFxuICAgICAgcGFnZVJvd3MsXG4gICAgICBtaW5Sb3dzLFxuICAgICAgcGFkUm93cyxcbiAgICAgIGhhc0NvbHVtbkZvb3RlcixcbiAgICAgIGNhblByZXZpb3VzLFxuICAgICAgY2FuTmV4dCxcbiAgICAgIHJvd01pbldpZHRoLFxuICAgIH1cblxuICAgIC8vIFZpc3VhbCBDb21wb25lbnRzXG5cbiAgICBjb25zdCBtYWtlSGVhZGVyR3JvdXBzID0gKCkgPT4ge1xuICAgICAgY29uc3QgdGhlYWRHcm91cFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEdyb3VwUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCB0aGVhZEdyb3VwVHJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VGhlYWRHcm91cFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1oZWFkZXJHcm91cHMnLCB0aGVhZEdyb3VwUHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4udGhlYWRHcm91cFByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50aGVhZEdyb3VwUHJvcHMucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXt0aGVhZEdyb3VwVHJQcm9wcy5jbGFzc05hbWV9XG4gICAgICAgICAgICBzdHlsZT17dGhlYWRHcm91cFRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGhlYWRHcm91cFRyUHJvcHMucmVzdH1cbiAgICAgICAgICA+XG4gICAgICAgICAgICB7aGVhZGVyR3JvdXBzLm1hcChtYWtlSGVhZGVyR3JvdXApfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgIDwvVGhlYWRDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlckdyb3VwID0gKGNvbHVtbiwgaSkgPT4ge1xuICAgICAgY29uc3QgcmVzaXplZFZhbHVlID0gY29sID0+XG4gICAgICAgIChyZXNpemVkLmZpbmQoeCA9PiB4LmlkID09PSBjb2wuaWQpIHx8IHt9KS52YWx1ZVxuICAgICAgY29uc3QgZmxleCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoXG4gICAgICAgICAgY29sID0+IChjb2wud2lkdGggfHwgcmVzaXplZFZhbHVlKGNvbCkgPyAwIDogY29sLm1pbldpZHRoKVxuICAgICAgICApXG4gICAgICApXG4gICAgICBjb25zdCB3aWR0aCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoY29sID0+XG4gICAgICAgICAgXy5nZXRGaXJzdERlZmluZWQocmVzaXplZFZhbHVlKGNvbCksIGNvbC53aWR0aCwgY29sLm1pbldpZHRoKVxuICAgICAgICApXG4gICAgICApXG4gICAgICBjb25zdCBtYXhXaWR0aCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoY29sID0+XG4gICAgICAgICAgXy5nZXRGaXJzdERlZmluZWQocmVzaXplZFZhbHVlKGNvbCksIGNvbC53aWR0aCwgY29sLm1heFdpZHRoKVxuICAgICAgICApXG4gICAgICApXG5cbiAgICAgIGNvbnN0IHRoZWFkR3JvdXBUaFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEdyb3VwVGhQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtbkhlYWRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0SGVhZGVyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG5cbiAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgIGNvbHVtbi5oZWFkZXJDbGFzc05hbWUsXG4gICAgICAgIHRoZWFkR3JvdXBUaFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uSGVhZGVyUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLmNvbHVtbi5oZWFkZXJTdHlsZSxcbiAgICAgICAgLi4udGhlYWRHcm91cFRoUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbkhlYWRlclByb3BzLnN0eWxlLFxuICAgICAgfVxuXG4gICAgICBjb25zdCByZXN0ID0ge1xuICAgICAgICAuLi50aGVhZEdyb3VwVGhQcm9wcy5yZXN0LFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5yZXN0LFxuICAgICAgfVxuXG4gICAgICBjb25zdCBmbGV4U3R5bGVzID0ge1xuICAgICAgICBmbGV4OiBgJHtmbGV4fSAwIGF1dG9gLFxuICAgICAgICB3aWR0aDogXy5hc1B4KHdpZHRoKSxcbiAgICAgICAgbWF4V2lkdGg6IF8uYXNQeChtYXhXaWR0aCksXG4gICAgICB9XG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUaENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3Nlcyl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIC4uLmZsZXhTdHlsZXMsXG4gICAgICAgICAgfX1cbiAgICAgICAgICB7Li4ucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIHtfLm5vcm1hbGl6ZUNvbXBvbmVudChjb2x1bW4uSGVhZGVyLCB7XG4gICAgICAgICAgICBkYXRhOiBzb3J0ZWREYXRhLFxuICAgICAgICAgICAgY29sdW1uOiBjb2x1bW4sXG4gICAgICAgICAgfSl9XG4gICAgICAgIDwvVGhDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlcnMgPSAoKSA9PiB7XG4gICAgICBjb25zdCB0aGVhZFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgdGhlYWRUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1oZWFkZXInLCB0aGVhZFByb3BzLmNsYXNzTmFtZSl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnRoZWFkUHJvcHMuc3R5bGUsXG4gICAgICAgICAgICBtaW5XaWR0aDogYCR7cm93TWluV2lkdGh9cHhgLFxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLnRoZWFkUHJvcHMucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXt0aGVhZFRyUHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgICAgc3R5bGU9e3RoZWFkVHJQcm9wcy5zdHlsZX1cbiAgICAgICAgICAgIHsuLi50aGVhZFRyUHJvcHMucmVzdH1cbiAgICAgICAgICA+XG4gICAgICAgICAgICB7YWxsVmlzaWJsZUNvbHVtbnMubWFwKG1ha2VIZWFkZXIpfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgIDwvVGhlYWRDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlciA9IChjb2x1bW4sIGkpID0+IHtcbiAgICAgIGNvbnN0IHJlc2l6ZWRDb2wgPSByZXNpemVkLmZpbmQoeCA9PiB4LmlkID09PSBjb2x1bW4uaWQpIHx8IHt9XG4gICAgICBjb25zdCBzb3J0ID0gc29ydGVkLmZpbmQoZCA9PiBkLmlkID09PSBjb2x1bW4uaWQpXG4gICAgICBjb25zdCBzaG93ID1cbiAgICAgICAgdHlwZW9mIGNvbHVtbi5zaG93ID09PSAnZnVuY3Rpb24nID8gY29sdW1uLnNob3coKSA6IGNvbHVtbi5zaG93XG4gICAgICBjb25zdCB3aWR0aCA9IF8uZ2V0Rmlyc3REZWZpbmVkKFxuICAgICAgICByZXNpemVkQ29sLnZhbHVlLFxuICAgICAgICBjb2x1bW4ud2lkdGgsXG4gICAgICAgIGNvbHVtbi5taW5XaWR0aFxuICAgICAgKVxuICAgICAgY29uc3QgbWF4V2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWF4V2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IHRoZWFkVGhQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VGhlYWRUaFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgY29sdW1uSGVhZGVyUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGNvbHVtbi5nZXRIZWFkZXJQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcblxuICAgICAgY29uc3QgY2xhc3NlcyA9IFtcbiAgICAgICAgY29sdW1uLmhlYWRlckNsYXNzTmFtZSxcbiAgICAgICAgdGhlYWRUaFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uSGVhZGVyUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLmNvbHVtbi5oZWFkZXJTdHlsZSxcbiAgICAgICAgLi4udGhlYWRUaFByb3BzLnN0eWxlLFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5zdHlsZSxcbiAgICAgIH1cblxuICAgICAgY29uc3QgcmVzdCA9IHtcbiAgICAgICAgLi4udGhlYWRUaFByb3BzLnJlc3QsXG4gICAgICAgIC4uLmNvbHVtbkhlYWRlclByb3BzLnJlc3QsXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IGlzUmVzaXphYmxlID0gXy5nZXRGaXJzdERlZmluZWQoY29sdW1uLnJlc2l6YWJsZSwgcmVzaXphYmxlLCBmYWxzZSlcbiAgICAgIGNvbnN0IHJlc2l6ZXIgPSBpc1Jlc2l6YWJsZVxuICAgICAgICA/ICg8UmVzaXplckNvbXBvbmVudFxuICAgICAgICAgIG9uTW91c2VEb3duPXtlID0+IHRoaXMucmVzaXplQ29sdW1uU3RhcnQoZSwgY29sdW1uLCBmYWxzZSl9XG4gICAgICAgICAgb25Ub3VjaFN0YXJ0PXtlID0+IHRoaXMucmVzaXplQ29sdW1uU3RhcnQoZSwgY29sdW1uLCB0cnVlKX1cbiAgICAgICAgICB7Li4ucmVzaXplclByb3BzfVxuICAgICAgICAvPilcbiAgICAgICAgOiBudWxsXG5cbiAgICAgIGNvbnN0IGlzU29ydGFibGUgPSBfLmdldEZpcnN0RGVmaW5lZChjb2x1bW4uc29ydGFibGUsIHNvcnRhYmxlLCBmYWxzZSlcblxuICAgICAgcmV0dXJuIChcbiAgICAgICAgPFRoQ29tcG9uZW50XG4gICAgICAgICAga2V5PXtpICsgJy0nICsgY29sdW1uLmlkfVxuICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgIGNsYXNzZXMsXG4gICAgICAgICAgICAncnQtcmVzaXphYmxlLWhlYWRlcicsXG4gICAgICAgICAgICBzb3J0ID8gKHNvcnQuZGVzYyA/ICctc29ydC1kZXNjJyA6ICctc29ydC1hc2MnKSA6ICcnLFxuICAgICAgICAgICAgaXNTb3J0YWJsZSAmJiAnLWN1cnNvci1wb2ludGVyJyxcbiAgICAgICAgICAgICFzaG93ICYmICctaGlkZGVuJyxcbiAgICAgICAgICAgIHBpdm90QnkgJiZcbiAgICAgICAgICAgICAgcGl2b3RCeS5zbGljZSgwLCAtMSkuaW5jbHVkZXMoY29sdW1uLmlkKSAmJlxuICAgICAgICAgICAgICAncnQtaGVhZGVyLXBpdm90J1xuICAgICAgICAgICl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIGZsZXg6IGAke3dpZHRofSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHRvZ2dsZVNvcnQ9e2UgPT4ge1xuICAgICAgICAgICAgaXNTb3J0YWJsZSAmJiB0aGlzLnNvcnRDb2x1bW4oY29sdW1uLCBlLnNoaWZ0S2V5KVxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8ZGl2IGNsYXNzTmFtZT0ncnQtcmVzaXphYmxlLWhlYWRlci1jb250ZW50Jz5cbiAgICAgICAgICAgIHtfLm5vcm1hbGl6ZUNvbXBvbmVudChjb2x1bW4uSGVhZGVyLCB7XG4gICAgICAgICAgICAgIGRhdGE6IHNvcnRlZERhdGEsXG4gICAgICAgICAgICAgIGNvbHVtbjogY29sdW1uLFxuICAgICAgICAgICAgfSl9XG4gICAgICAgICAgPC9kaXY+XG4gICAgICAgICAge3Jlc2l6ZXJ9XG4gICAgICAgIDwvVGhDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUZpbHRlcnMgPSAoKSA9PiB7XG4gICAgICBjb25zdCB0aGVhZEZpbHRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEZpbHRlclByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgdGhlYWRGaWx0ZXJUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEZpbHRlclRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1maWx0ZXJzJywgdGhlYWRGaWx0ZXJQcm9wcy5jbGFzc05hbWUpfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi50aGVhZEZpbHRlclByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50aGVhZEZpbHRlclByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17dGhlYWRGaWx0ZXJUclByb3BzLmNsYXNzTmFtZX1cbiAgICAgICAgICAgIHN0eWxlPXt0aGVhZEZpbHRlclRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGhlYWRGaWx0ZXJUclByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcChtYWtlRmlsdGVyKX1cbiAgICAgICAgICA8L1RyQ29tcG9uZW50PlxuICAgICAgICA8L1RoZWFkQ29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VGaWx0ZXIgPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IG1heFdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1heFdpZHRoXG4gICAgICApXG4gICAgICBjb25zdCB0aGVhZEZpbHRlclRoUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRoZWFkRmlsdGVyVGhQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtbkhlYWRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0SGVhZGVyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG5cbiAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgIGNvbHVtbi5oZWFkZXJDbGFzc05hbWUsXG4gICAgICAgIHRoZWFkRmlsdGVyVGhQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgIGNvbHVtbkhlYWRlclByb3BzLmNsYXNzTmFtZSxcbiAgICAgIF1cblxuICAgICAgY29uc3Qgc3R5bGVzID0ge1xuICAgICAgICAuLi5jb2x1bW4uaGVhZGVyU3R5bGUsXG4gICAgICAgIC4uLnRoZWFkRmlsdGVyVGhQcm9wcy5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uSGVhZGVyUHJvcHMuc3R5bGUsXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IHJlc3QgPSB7XG4gICAgICAgIC4uLnRoZWFkRmlsdGVyVGhQcm9wcy5yZXN0LFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5yZXN0LFxuICAgICAgfVxuXG4gICAgICBjb25zdCBmaWx0ZXIgPSBmaWx0ZXJlZC5maW5kKGZpbHRlciA9PiBmaWx0ZXIuaWQgPT09IGNvbHVtbi5pZClcblxuICAgICAgY29uc3QgUmVzb2x2ZWRGaWx0ZXJDb21wb25lbnQgPSBjb2x1bW4uRmlsdGVyIHx8IEZpbHRlckNvbXBvbmVudFxuXG4gICAgICBjb25zdCBpc0ZpbHRlcmFibGUgPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgY29sdW1uLmZpbHRlcmFibGUsXG4gICAgICAgIGZpbHRlcmFibGUsXG4gICAgICAgIGZhbHNlXG4gICAgICApXG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUaENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3Nlcyl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIGZsZXg6IGAke3dpZHRofSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi5yZXN0fVxuICAgICAgICA+XG4gICAgICAgICAge2lzRmlsdGVyYWJsZVxuICAgICAgICAgICAgPyBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgUmVzb2x2ZWRGaWx0ZXJDb21wb25lbnQsXG4gICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICBjb2x1bW4sXG4gICAgICAgICAgICAgICAgZmlsdGVyLFxuICAgICAgICAgICAgICAgIG9uQ2hhbmdlOiB2YWx1ZSA9PiB0aGlzLmZpbHRlckNvbHVtbihjb2x1bW4sIHZhbHVlKSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgZGVmYXVsdFByb3BzLmNvbHVtbi5GaWx0ZXJcbiAgICAgICAgICAgIClcbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgPC9UaENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlUGFnZVJvdyA9IChyb3csIGksIHBhdGggPSBbXSkgPT4ge1xuICAgICAgY29uc3Qgcm93SW5mbyA9IHtcbiAgICAgICAgb3JpZ2luYWw6IHJvd1tvcmlnaW5hbEtleV0sXG4gICAgICAgIHJvdzogcm93LFxuICAgICAgICBpbmRleDogcm93W2luZGV4S2V5XSxcbiAgICAgICAgdmlld0luZGV4OiArK3Jvd0luZGV4LFxuICAgICAgICBsZXZlbDogcGF0aC5sZW5ndGgsXG4gICAgICAgIG5lc3RpbmdQYXRoOiBwYXRoLmNvbmNhdChbaV0pLFxuICAgICAgICBhZ2dyZWdhdGVkOiByb3dbYWdncmVnYXRlZEtleV0sXG4gICAgICAgIGdyb3VwZWRCeVBpdm90OiByb3dbZ3JvdXBlZEJ5UGl2b3RLZXldLFxuICAgICAgICBzdWJSb3dzOiByb3dbc3ViUm93c0tleV0sXG4gICAgICB9XG4gICAgICBjb25zdCBpc0V4cGFuZGVkID0gXy5nZXQoZXhwYW5kZWQsIHJvd0luZm8ubmVzdGluZ1BhdGgpXG4gICAgICBjb25zdCB0ckdyb3VwUHJvcHMgPSBnZXRUckdyb3VwUHJvcHMoZmluYWxTdGF0ZSwgcm93SW5mbywgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgY29uc3QgdHJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VHJQcm9wcyhmaW5hbFN0YXRlLCByb3dJbmZvLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VHJHcm91cENvbXBvbmVudCBrZXk9e3Jvd0luZm8ubmVzdGluZ1BhdGguam9pbignXycpfSB7Li4udHJHcm91cFByb3BzfT5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgICAgdHJQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIHJvdy5fdmlld0luZGV4ICUgMiA/ICctZXZlbicgOiAnLW9kZCdcbiAgICAgICAgICAgICl9XG4gICAgICAgICAgICBzdHlsZT17dHJQcm9wcy5zdHlsZX1cbiAgICAgICAgICAgIHsuLi50clByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcCgoY29sdW1uLCBpMikgPT4ge1xuICAgICAgICAgICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgICAgICAgICBjb25zdCBzaG93ID1cbiAgICAgICAgICAgICAgICB0eXBlb2YgY29sdW1uLnNob3cgPT09ICdmdW5jdGlvbicgPyBjb2x1bW4uc2hvdygpIDogY29sdW1uLnNob3dcbiAgICAgICAgICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgICAgICAgICByZXNpemVkQ29sLnZhbHVlLFxuICAgICAgICAgICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgICAgICAgICAgKVxuICAgICAgICAgICAgICBjb25zdCBtYXhXaWR0aCA9IF8uZ2V0Rmlyc3REZWZpbmVkKFxuICAgICAgICAgICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgICAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICAgICAgICAgIGNvbHVtbi5tYXhXaWR0aFxuICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIGNvbnN0IHRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgICAgICAgICAgZ2V0VGRQcm9wcyhmaW5hbFN0YXRlLCByb3dJbmZvLCBjb2x1bW4sIHRoaXMpXG4gICAgICAgICAgICAgIClcbiAgICAgICAgICAgICAgY29uc3QgY29sdW1uUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgICAgICAgICAgY29sdW1uLmdldFByb3BzKGZpbmFsU3RhdGUsIHJvd0luZm8sIGNvbHVtbiwgdGhpcylcbiAgICAgICAgICAgICAgKVxuXG4gICAgICAgICAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgICAgICAgICAgdGRQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgICAgY29sdW1uLmNsYXNzTmFtZSxcbiAgICAgICAgICAgICAgICBjb2x1bW5Qcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIF1cblxuICAgICAgICAgICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgICAgICAgICAgLi4udGRQcm9wcy5zdHlsZSxcbiAgICAgICAgICAgICAgICAuLi5jb2x1bW4uc3R5bGUsXG4gICAgICAgICAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBjb25zdCBjZWxsSW5mbyA9IHtcbiAgICAgICAgICAgICAgICAuLi5yb3dJbmZvLFxuICAgICAgICAgICAgICAgIGlzRXhwYW5kZWQsXG4gICAgICAgICAgICAgICAgY29sdW1uOiB7IC4uLmNvbHVtbiB9LFxuICAgICAgICAgICAgICAgIHZhbHVlOiByb3dJbmZvLnJvd1tjb2x1bW4uaWRdLFxuICAgICAgICAgICAgICAgIHBpdm90ZWQ6IGNvbHVtbi5waXZvdGVkLFxuICAgICAgICAgICAgICAgIGV4cGFuZGVyOiBjb2x1bW4uZXhwYW5kZXIsXG4gICAgICAgICAgICAgICAgcmVzaXplZCxcbiAgICAgICAgICAgICAgICBzaG93LFxuICAgICAgICAgICAgICAgIHdpZHRoLFxuICAgICAgICAgICAgICAgIG1heFdpZHRoLFxuICAgICAgICAgICAgICAgIHRkUHJvcHMsXG4gICAgICAgICAgICAgICAgY29sdW1uUHJvcHMsXG4gICAgICAgICAgICAgICAgY2xhc3NlcyxcbiAgICAgICAgICAgICAgICBzdHlsZXMsXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBjb25zdCB2YWx1ZSA9IGNlbGxJbmZvLnZhbHVlXG5cbiAgICAgICAgICAgICAgbGV0IHVzZU9uRXhwYW5kZXJDbGlja1xuICAgICAgICAgICAgICBsZXQgaXNCcmFuY2hcbiAgICAgICAgICAgICAgbGV0IGlzUHJldmlld1xuXG4gICAgICAgICAgICAgIGNvbnN0IG9uRXhwYW5kZXJDbGljayA9IGUgPT4ge1xuICAgICAgICAgICAgICAgIGxldCBuZXdFeHBhbmRlZCA9IF8uY2xvbmUoZXhwYW5kZWQpXG4gICAgICAgICAgICAgICAgaWYgKGlzRXhwYW5kZWQpIHtcbiAgICAgICAgICAgICAgICAgIG5ld0V4cGFuZGVkID0gXy5zZXQobmV3RXhwYW5kZWQsIGNlbGxJbmZvLm5lc3RpbmdQYXRoLCBmYWxzZSlcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgbmV3RXhwYW5kZWQgPSBfLnNldChuZXdFeHBhbmRlZCwgY2VsbEluZm8ubmVzdGluZ1BhdGgsIHt9KVxuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLnNldFN0YXRlV2l0aERhdGEoXG4gICAgICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgICAgIGV4cGFuZGVkOiBuZXdFeHBhbmRlZCxcbiAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICAoKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIG9uRXhwYW5kZWRDaGFuZ2UgJiZcbiAgICAgICAgICAgICAgICAgICAgICBvbkV4cGFuZGVkQ2hhbmdlKG5ld0V4cGFuZGVkLCBjZWxsSW5mby5uZXN0aW5nUGF0aCwgZSlcbiAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAvLyBEZWZhdWx0IHRvIGEgc3RhbmRhcmQgY2VsbFxuICAgICAgICAgICAgICBsZXQgcmVzb2x2ZWRDZWxsID0gXy5ub3JtYWxpemVDb21wb25lbnQoXG4gICAgICAgICAgICAgICAgY29sdW1uLkNlbGwsXG4gICAgICAgICAgICAgICAgY2VsbEluZm8sXG4gICAgICAgICAgICAgICAgdmFsdWVcbiAgICAgICAgICAgICAgKVxuXG4gICAgICAgICAgICAgIC8vIFJlc29sdmUgUmVuZGVyZXJzXG4gICAgICAgICAgICAgIGNvbnN0IFJlc29sdmVkQWdncmVnYXRlZENvbXBvbmVudCA9XG4gICAgICAgICAgICAgICAgY29sdW1uLkFnZ3JlZ2F0ZWQgfHxcbiAgICAgICAgICAgICAgICAoIWNvbHVtbi5hZ2dyZWdhdGUgPyBBZ2dyZWdhdGVkQ29tcG9uZW50IDogY29sdW1uLkNlbGwpXG4gICAgICAgICAgICAgIGNvbnN0IFJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIGNvbHVtbi5FeHBhbmRlciB8fCBFeHBhbmRlckNvbXBvbmVudFxuICAgICAgICAgICAgICBjb25zdCBSZXNvbHZlZFBpdm90VmFsdWVDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIGNvbHVtbi5QaXZvdFZhbHVlIHx8IFBpdm90VmFsdWVDb21wb25lbnRcbiAgICAgICAgICAgICAgY29uc3QgRGVmYXVsdFJlc29sdmVkUGl2b3RDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIFBpdm90Q29tcG9uZW50IHx8XG4gICAgICAgICAgICAgICAgKHByb3BzID0+XG4gICAgICAgICAgICAgICAgICA8ZGl2PlxuICAgICAgICAgICAgICAgICAgICA8UmVzb2x2ZWRFeHBhbmRlckNvbXBvbmVudCB7Li4ucHJvcHN9IC8+XG4gICAgICAgICAgICAgICAgICAgIDxSZXNvbHZlZFBpdm90VmFsdWVDb21wb25lbnQgey4uLnByb3BzfSAvPlxuICAgICAgICAgICAgICAgICAgPC9kaXY+KVxuICAgICAgICAgICAgICBjb25zdCBSZXNvbHZlZFBpdm90Q29tcG9uZW50ID1cbiAgICAgICAgICAgICAgICBjb2x1bW4uUGl2b3QgfHwgRGVmYXVsdFJlc29sdmVkUGl2b3RDb21wb25lbnRcblxuICAgICAgICAgICAgICAvLyBJcyB0aGlzIGNlbGwgZXhwYW5kYWJsZT9cbiAgICAgICAgICAgICAgaWYgKGNlbGxJbmZvLnBpdm90ZWQgfHwgY2VsbEluZm8uZXhwYW5kZXIpIHtcbiAgICAgICAgICAgICAgICAvLyBNYWtlIGl0IGV4cGFuZGFibGUgYnkgZGVmdWFsdFxuICAgICAgICAgICAgICAgIGNlbGxJbmZvLmV4cGFuZGFibGUgPSB0cnVlXG4gICAgICAgICAgICAgICAgdXNlT25FeHBhbmRlckNsaWNrID0gdHJ1ZVxuICAgICAgICAgICAgICAgIC8vIElmIHBpdm90ZWQsIGhhcyBubyBzdWJSb3dzLCBhbmQgZG9lcyBub3QgaGF2ZSBhIHN1YkNvbXBvbmVudCwgZG8gbm90IG1ha2UgZXhwYW5kYWJsZVxuICAgICAgICAgICAgICAgIGlmIChjZWxsSW5mby5waXZvdGVkICYmICFjZWxsSW5mby5zdWJSb3dzICYmICFTdWJDb21wb25lbnQpIHtcbiAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLmV4cGFuZGFibGUgPSBmYWxzZVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgIGlmIChjZWxsSW5mby5waXZvdGVkKSB7XG4gICAgICAgICAgICAgICAgLy8gSXMgdGhpcyBjb2x1bW4gYSBicmFuY2g/XG4gICAgICAgICAgICAgICAgaXNCcmFuY2ggPVxuICAgICAgICAgICAgICAgICAgcm93SW5mby5yb3dbcGl2b3RJREtleV0gPT09IGNvbHVtbi5pZCAmJiBjZWxsSW5mby5zdWJSb3dzXG4gICAgICAgICAgICAgICAgLy8gU2hvdWxkIHRoaXMgY29sdW1uIGJlIGJsYW5rP1xuICAgICAgICAgICAgICAgIGlzUHJldmlldyA9XG4gICAgICAgICAgICAgICAgICBwaXZvdEJ5LmluZGV4T2YoY29sdW1uLmlkKSA+XG4gICAgICAgICAgICAgICAgICAgIHBpdm90QnkuaW5kZXhPZihyb3dJbmZvLnJvd1twaXZvdElES2V5XSkgJiYgY2VsbEluZm8uc3ViUm93c1xuICAgICAgICAgICAgICAgIC8vIFBpdm90IENlbGwgUmVuZGVyIE92ZXJyaWRlXG4gICAgICAgICAgICAgICAgaWYgKGlzQnJhbmNoKSB7XG4gICAgICAgICAgICAgICAgICAvLyBpc1Bpdm90XG4gICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgICAgUmVzb2x2ZWRQaXZvdENvbXBvbmVudCxcbiAgICAgICAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICAgICAgIC4uLmNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiByb3dbcGl2b3RWYWxLZXldLFxuICAgICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgICAgICByb3dbcGl2b3RWYWxLZXldXG4gICAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpc1ByZXZpZXcpIHtcbiAgICAgICAgICAgICAgICAgIC8vIFNob3cgdGhlIHBpdm90IHByZXZpZXdcbiAgICAgICAgICAgICAgICAgIHJlc29sdmVkQ2VsbCA9IF8ubm9ybWFsaXplQ29tcG9uZW50KFxuICAgICAgICAgICAgICAgICAgICBSZXNvbHZlZEFnZ3JlZ2F0ZWRDb21wb25lbnQsXG4gICAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgICB2YWx1ZVxuICAgICAgICAgICAgICAgICAgKVxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICB9IGVsc2UgaWYgKGNlbGxJbmZvLmFnZ3JlZ2F0ZWQpIHtcbiAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgIFJlc29sdmVkQWdncmVnYXRlZENvbXBvbmVudCxcbiAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgdmFsdWVcbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBpZiAoY2VsbEluZm8uZXhwYW5kZXIpIHtcbiAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgIFJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQsXG4gICAgICAgICAgICAgICAgICBjZWxsSW5mbyxcbiAgICAgICAgICAgICAgICAgIHJvd1twaXZvdFZhbEtleV1cbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgICAgaWYgKHBpdm90QnkpIHtcbiAgICAgICAgICAgICAgICAgIGlmIChjZWxsSW5mby5ncm91cGVkQnlQaXZvdCkge1xuICAgICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICBpZiAoIWNlbGxJbmZvLnN1YlJvd3MgJiYgIVN1YkNvbXBvbmVudCkge1xuICAgICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgY29uc3QgcmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2sgPSB1c2VPbkV4cGFuZGVyQ2xpY2tcbiAgICAgICAgICAgICAgICA/IG9uRXhwYW5kZXJDbGlja1xuICAgICAgICAgICAgICAgIDogKCkgPT4ge31cblxuICAgICAgICAgICAgICAvLyBJZiB0aGVyZSBhcmUgbXVsdGlwbGUgb25DbGljayBldmVudHMsIG1ha2Ugc3VyZSB0aGV5IGRvbid0IG92ZXJyaWRlIGVhY2hvdGhlci4gVGhpcyBzaG91bGQgbWF5YmUgYmUgZXhwYW5kZWQgdG8gaGFuZGxlIGFsbCBmdW5jdGlvbiBhdHRyaWJ1dGVzXG4gICAgICAgICAgICAgIGNvbnN0IGludGVyYWN0aW9uUHJvcHMgPSB7XG4gICAgICAgICAgICAgICAgb25DbGljazogcmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2ssXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBpZiAodGRQcm9wcy5yZXN0Lm9uQ2xpY2spIHtcbiAgICAgICAgICAgICAgICBpbnRlcmFjdGlvblByb3BzLm9uQ2xpY2sgPSBlID0+IHtcbiAgICAgICAgICAgICAgICAgIHRkUHJvcHMucmVzdC5vbkNsaWNrKGUsICgpID0+IHJlc29sdmVkT25FeHBhbmRlckNsaWNrKGUpKVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgIGlmIChjb2x1bW5Qcm9wcy5yZXN0Lm9uQ2xpY2spIHtcbiAgICAgICAgICAgICAgICBpbnRlcmFjdGlvblByb3BzLm9uQ2xpY2sgPSBlID0+IHtcbiAgICAgICAgICAgICAgICAgIGNvbHVtblByb3BzLnJlc3Qub25DbGljayhlLCAoKSA9PiByZXNvbHZlZE9uRXhwYW5kZXJDbGljayhlKSlcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAvLyBSZXR1cm4gdGhlIGNlbGxcbiAgICAgICAgICAgICAgcmV0dXJuIChcbiAgICAgICAgICAgICAgICA8VGRDb21wb25lbnRcbiAgICAgICAgICAgICAgICAgIGtleT17aTIgKyAnLScgKyBjb2x1bW4uaWR9XG4gICAgICAgICAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoXG4gICAgICAgICAgICAgICAgICAgIGNsYXNzZXMsXG4gICAgICAgICAgICAgICAgICAgICFzaG93ICYmICdoaWRkZW4nLFxuICAgICAgICAgICAgICAgICAgICBjZWxsSW5mby5leHBhbmRhYmxlICYmICdydC1leHBhbmRhYmxlJyxcbiAgICAgICAgICAgICAgICAgICAgKGlzQnJhbmNoIHx8IGlzUHJldmlldykgJiYgJ3J0LXBpdm90J1xuICAgICAgICAgICAgICAgICAgKX1cbiAgICAgICAgICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgICAgICAgICAgZmxleDogYCR7d2lkdGh9IDAgYXV0b2AsXG4gICAgICAgICAgICAgICAgICAgIHdpZHRoOiBfLmFzUHgod2lkdGgpLFxuICAgICAgICAgICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICAgICAgICAgIH19XG4gICAgICAgICAgICAgICAgICB7Li4udGRQcm9wcy5yZXN0fVxuICAgICAgICAgICAgICAgICAgey4uLmNvbHVtblByb3BzLnJlc3R9XG4gICAgICAgICAgICAgICAgICB7Li4uaW50ZXJhY3Rpb25Qcm9wc31cbiAgICAgICAgICAgICAgICA+XG4gICAgICAgICAgICAgICAgICB7cmVzb2x2ZWRDZWxsfVxuICAgICAgICAgICAgICAgIDwvVGRDb21wb25lbnQ+XG4gICAgICAgICAgICAgIClcbiAgICAgICAgICAgIH0pfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgICAge3Jvd0luZm8uc3ViUm93cyAmJlxuICAgICAgICAgICAgaXNFeHBhbmRlZCAmJlxuICAgICAgICAgICAgcm93SW5mby5zdWJSb3dzLm1hcCgoZCwgaSkgPT5cbiAgICAgICAgICAgICAgbWFrZVBhZ2VSb3coZCwgaSwgcm93SW5mby5uZXN0aW5nUGF0aClcbiAgICAgICAgICAgICl9XG4gICAgICAgICAge1N1YkNvbXBvbmVudCAmJlxuICAgICAgICAgICAgIXJvd0luZm8uc3ViUm93cyAmJlxuICAgICAgICAgICAgaXNFeHBhbmRlZCAmJlxuICAgICAgICAgICAgU3ViQ29tcG9uZW50KHJvd0luZm8pfVxuICAgICAgICA8L1RyR3JvdXBDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZVBhZFJvdyA9IChyb3csIGkpID0+IHtcbiAgICAgIGNvbnN0IHRyR3JvdXBQcm9wcyA9IGdldFRyR3JvdXBQcm9wcyhcbiAgICAgICAgZmluYWxTdGF0ZSxcbiAgICAgICAgdW5kZWZpbmVkLFxuICAgICAgICB1bmRlZmluZWQsXG4gICAgICAgIHRoaXNcbiAgICAgIClcbiAgICAgIGNvbnN0IHRyUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VHJHcm91cENvbXBvbmVudCBrZXk9e2l9IHsuLi50ckdyb3VwUHJvcHN9PlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKFxuICAgICAgICAgICAgICAnLXBhZFJvdycsXG4gICAgICAgICAgICAgIChwYWdlUm93cy5sZW5ndGggKyBpKSAlIDIgPyAnLWV2ZW4nIDogJy1vZGQnLFxuICAgICAgICAgICAgICB0clByb3BzLmNsYXNzTmFtZVxuICAgICAgICAgICAgKX1cbiAgICAgICAgICAgIHN0eWxlPXt0clByb3BzLnN0eWxlIHx8IHt9fVxuICAgICAgICAgID5cbiAgICAgICAgICAgIHthbGxWaXNpYmxlQ29sdW1ucy5tYXAobWFrZVBhZENvbHVtbil9XG4gICAgICAgICAgPC9UckNvbXBvbmVudD5cbiAgICAgICAgPC9Uckdyb3VwQ29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VQYWRDb2x1bW4gPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgc2hvdyA9XG4gICAgICAgIHR5cGVvZiBjb2x1bW4uc2hvdyA9PT0gJ2Z1bmN0aW9uJyA/IGNvbHVtbi5zaG93KCkgOiBjb2x1bW4uc2hvd1xuICAgICAgbGV0IHdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1pbldpZHRoXG4gICAgICApXG4gICAgICBsZXQgZmxleCA9IHdpZHRoXG4gICAgICBsZXQgbWF4V2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWF4V2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IHRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRkUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCBjb2x1bW5Qcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgY29sdW1uLmdldFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuXG4gICAgICBjb25zdCBjbGFzc2VzID0gW1xuICAgICAgICB0ZFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLnRkUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbi5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICB9XG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUZENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NlcywgIXNob3cgJiYgJ2hpZGRlbicpfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi5zdHlsZXMsXG4gICAgICAgICAgICBmbGV4OiBgJHtmbGV4fSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50ZFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICB7Xy5ub3JtYWxpemVDb21wb25lbnQoUGFkUm93Q29tcG9uZW50KX1cbiAgICAgICAgPC9UZENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlQ29sdW1uRm9vdGVycyA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHRGb290UHJvcHMgPSBnZXRUZm9vdFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgY29uc3QgdEZvb3RUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUZm9vdFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGZvb3RDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e3RGb290UHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi50Rm9vdFByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50Rm9vdFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyh0Rm9vdFRyUHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICAgIHN0eWxlPXt0Rm9vdFRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udEZvb3RUclByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcChtYWtlQ29sdW1uRm9vdGVyKX1cbiAgICAgICAgICA8L1RyQ29tcG9uZW50PlxuICAgICAgICA8L1Rmb290Q29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VDb2x1bW5Gb290ZXIgPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgc2hvdyA9XG4gICAgICAgIHR5cGVvZiBjb2x1bW4uc2hvdyA9PT0gJ2Z1bmN0aW9uJyA/IGNvbHVtbi5zaG93KCkgOiBjb2x1bW4uc2hvd1xuICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IG1heFdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1heFdpZHRoXG4gICAgICApXG4gICAgICBjb25zdCB0Rm9vdFRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRmb290VGRQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtblByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0UHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCBjb2x1bW5Gb290ZXJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgY29sdW1uLmdldEZvb3RlclByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuXG4gICAgICBjb25zdCBjbGFzc2VzID0gW1xuICAgICAgICB0Rm9vdFRkUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgICBjb2x1bW4uY2xhc3NOYW1lLFxuICAgICAgICBjb2x1bW5Qcm9wcy5jbGFzc05hbWUsXG4gICAgICAgIGNvbHVtbkZvb3RlclByb3BzLmNsYXNzTmFtZSxcbiAgICAgIF1cblxuICAgICAgY29uc3Qgc3R5bGVzID0ge1xuICAgICAgICAuLi50Rm9vdFRkUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbi5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbkZvb3RlclByb3BzLnN0eWxlLFxuICAgICAgfVxuXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGRDb21wb25lbnRcbiAgICAgICAgICBrZXk9e2kgKyAnLScgKyBjb2x1bW4uaWR9XG4gICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKGNsYXNzZXMsICFzaG93ICYmICdoaWRkZW4nKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4uc3R5bGVzLFxuICAgICAgICAgICAgZmxleDogYCR7d2lkdGh9IDAgYXV0b2AsXG4gICAgICAgICAgICB3aWR0aDogXy5hc1B4KHdpZHRoKSxcbiAgICAgICAgICAgIG1heFdpZHRoOiBfLmFzUHgobWF4V2lkdGgpLFxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLmNvbHVtblByb3BzLnJlc3R9XG4gICAgICAgICAgey4uLnRGb290VGRQcm9wcy5yZXN0fVxuICAgICAgICAgIHsuLi5jb2x1bW5Gb290ZXJQcm9wcy5yZXN0fVxuICAgICAgICA+XG4gICAgICAgICAge18ubm9ybWFsaXplQ29tcG9uZW50KGNvbHVtbi5Gb290ZXIsIHtcbiAgICAgICAgICAgIGRhdGE6IHNvcnRlZERhdGEsXG4gICAgICAgICAgICBjb2x1bW46IGNvbHVtbixcbiAgICAgICAgICB9KX1cbiAgICAgICAgPC9UZENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlUGFnaW5hdGlvbiA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHBhZ2luYXRpb25Qcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0UGFnaW5hdGlvblByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgcmV0dXJuIChcbiAgICAgICAgPFBhZ2luYXRpb25Db21wb25lbnRcbiAgICAgICAgICB7Li4ucmVzb2x2ZWRTdGF0ZX1cbiAgICAgICAgICBwYWdlcz17cGFnZXN9XG4gICAgICAgICAgY2FuUHJldmlvdXM9e2NhblByZXZpb3VzfVxuICAgICAgICAgIGNhbk5leHQ9e2Nhbk5leHR9XG4gICAgICAgICAgb25QYWdlQ2hhbmdlPXt0aGlzLm9uUGFnZUNoYW5nZX1cbiAgICAgICAgICBvblBhZ2VTaXplQ2hhbmdlPXt0aGlzLm9uUGFnZVNpemVDaGFuZ2V9XG4gICAgICAgICAgY2xhc3NOYW1lPXtwYWdpbmF0aW9uUHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgIHN0eWxlPXtwYWdpbmF0aW9uUHJvcHMuc3R5bGV9XG4gICAgICAgICAgey4uLnBhZ2luYXRpb25Qcm9wcy5yZXN0fVxuICAgICAgICAvPlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IHJvb3RQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgIGdldFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgIClcbiAgICBjb25zdCB0YWJsZVByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgZ2V0VGFibGVQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICApXG4gICAgY29uc3QgdEJvZHlQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgIGdldFRib2R5UHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgKVxuICAgIGNvbnN0IGxvYWRpbmdQcm9wcyA9IGdldExvYWRpbmdQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICBjb25zdCBub0RhdGFQcm9wcyA9IGdldE5vRGF0YVByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgIGNvbnN0IHJlc2l6ZXJQcm9wcyA9IGdldFJlc2l6ZXJQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcblxuICAgIGNvbnN0IG1ha2VUYWJsZSA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHBhZ2luYXRpb24gPSBtYWtlUGFnaW5hdGlvbigpXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8ZGl2XG4gICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCdSZWFjdFRhYmxlJywgY2xhc3NOYW1lLCByb290UHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4uc3R5bGUsXG4gICAgICAgICAgICAuLi5yb290UHJvcHMuc3R5bGUsXG4gICAgICAgICAgfX1cbiAgICAgICAgICB7Li4ucm9vdFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICB7c2hvd1BhZ2luYXRpb24gJiYgc2hvd1BhZ2luYXRpb25Ub3BcbiAgICAgICAgICAgID8gPGRpdiBjbGFzc05hbWU9J3BhZ2luYXRpb24tdG9wJz5cbiAgICAgICAgICAgICAge3BhZ2luYXRpb259XG4gICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgICA8VGFibGVDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgICAgdGFibGVQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIGN1cnJlbnRseVJlc2l6aW5nID8gJ3J0LXJlc2l6aW5nJyA6ICcnXG4gICAgICAgICAgICApfVxuICAgICAgICAgICAgc3R5bGU9e3RhYmxlUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGFibGVQcm9wcy5yZXN0fVxuICAgICAgICAgID5cbiAgICAgICAgICAgIHtoYXNIZWFkZXJHcm91cHMgPyBtYWtlSGVhZGVyR3JvdXBzKCkgOiBudWxsfVxuICAgICAgICAgICAge21ha2VIZWFkZXJzKCl9XG4gICAgICAgICAgICB7aGFzRmlsdGVycyA/IG1ha2VGaWx0ZXJzKCkgOiBudWxsfVxuICAgICAgICAgICAgPFRib2R5Q29tcG9uZW50XG4gICAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyh0Qm9keVByb3BzLmNsYXNzTmFtZSl9XG4gICAgICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAgICAgLi4udEJvZHlQcm9wcy5zdHlsZSxcbiAgICAgICAgICAgICAgICBtaW5XaWR0aDogYCR7cm93TWluV2lkdGh9cHhgLFxuICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICB7Li4udEJvZHlQcm9wcy5yZXN0fVxuICAgICAgICAgICAgPlxuICAgICAgICAgICAgICB7cGFnZVJvd3MubWFwKChkLCBpKSA9PiBtYWtlUGFnZVJvdyhkLCBpKSl9XG4gICAgICAgICAgICAgIHtwYWRSb3dzLm1hcChtYWtlUGFkUm93KX1cbiAgICAgICAgICAgIDwvVGJvZHlDb21wb25lbnQ+XG4gICAgICAgICAgICB7aGFzQ29sdW1uRm9vdGVyID8gbWFrZUNvbHVtbkZvb3RlcnMoKSA6IG51bGx9XG4gICAgICAgICAgPC9UYWJsZUNvbXBvbmVudD5cbiAgICAgICAgICB7c2hvd1BhZ2luYXRpb24gJiYgc2hvd1BhZ2luYXRpb25Cb3R0b21cbiAgICAgICAgICAgID8gPGRpdiBjbGFzc05hbWU9J3BhZ2luYXRpb24tYm90dG9tJz5cbiAgICAgICAgICAgICAge3BhZ2luYXRpb259XG4gICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgICB7IXBhZ2VSb3dzLmxlbmd0aCAmJlxuICAgICAgICAgICAgPE5vRGF0YUNvbXBvbmVudCB7Li4ubm9EYXRhUHJvcHN9PlxuICAgICAgICAgICAgICB7Xy5ub3JtYWxpemVDb21wb25lbnQobm9EYXRhVGV4dCl9XG4gICAgICAgICAgICA8L05vRGF0YUNvbXBvbmVudD59XG4gICAgICAgICAgPExvYWRpbmdDb21wb25lbnRcbiAgICAgICAgICAgIGxvYWRpbmc9e2xvYWRpbmd9XG4gICAgICAgICAgICBsb2FkaW5nVGV4dD17bG9hZGluZ1RleHR9XG4gICAgICAgICAgICB7Li4ubG9hZGluZ1Byb3BzfVxuICAgICAgICAgIC8+XG4gICAgICAgIDwvZGl2PlxuICAgICAgKVxuICAgIH1cblxuICAgIC8vIGNoaWxkUHJvcHMgYXJlIG9wdGlvbmFsbHkgcGFzc2VkIHRvIGEgZnVuY3Rpb24tYXMtYS1jaGlsZFxuICAgIHJldHVybiBjaGlsZHJlbiA/IGNoaWxkcmVuKGZpbmFsU3RhdGUsIG1ha2VUYWJsZSwgdGhpcykgOiBtYWtlVGFibGUoKVxuICB9XG59XG4iXX0= + +/***/ }), +/* 359 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +exports.default = function (Base) { + return function (_Base) { + _inherits(_class, _Base); + + function _class() { + _classCallCheck(this, _class); + + return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments)); + } + + _createClass(_class, [{ + key: 'componentWillMount', + value: function componentWillMount() { + this.setStateWithData(this.getDataModel(this.getResolvedState())); + } + }, { + key: 'componentDidMount', + value: function componentDidMount() { + this.fireFetchData(); + } + }, { + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps, nextState) { + var oldState = this.getResolvedState(); + var newState = this.getResolvedState(nextProps, nextState); + + // Do a deep compare of new and old `defaultOption` and + // if they are different reset `option = defaultOption` + var defaultableOptions = ['sorted', 'filtered', 'resized', 'expanded']; + defaultableOptions.forEach(function (x) { + var defaultName = 'default' + (x.charAt(0).toUpperCase() + x.slice(1)); + if (JSON.stringify(oldState[defaultName]) !== JSON.stringify(newState[defaultName])) { + newState[x] = newState[defaultName]; + } + }); + + // If they change these table options, we need to reset defaults + // or else we could get into a state where the user has changed the UI + // and then disabled the ability to change it back. + // e.g. If `filterable` has changed, set `filtered = defaultFiltered` + var resettableOptions = ['sortable', 'filterable', 'resizable']; + resettableOptions.forEach(function (x) { + if (oldState[x] !== newState[x]) { + var baseName = x.replace('able', ''); + var optionName = baseName + 'ed'; + var defaultName = 'default' + (optionName.charAt(0).toUpperCase() + optionName.slice(1)); + newState[optionName] = newState[defaultName]; + } + }); + + // Props that trigger a data update + if (oldState.data !== newState.data || oldState.columns !== newState.columns || oldState.pivotBy !== newState.pivotBy || oldState.sorted !== newState.sorted || oldState.filtered !== newState.filtered) { + this.setStateWithData(this.getDataModel(newState)); + } + } + }, { + key: 'setStateWithData', + value: function setStateWithData(newState, cb) { + var _this2 = this; + + var oldState = this.getResolvedState(); + var newResolvedState = this.getResolvedState({}, newState); + var freezeWhenExpanded = newResolvedState.freezeWhenExpanded; + + // Default to unfrozen state + + newResolvedState.frozen = false; + + // If freezeWhenExpanded is set, check for frozen conditions + if (freezeWhenExpanded) { + // if any rows are expanded, freeze the existing data and sorting + var keys = Object.keys(newResolvedState.expanded); + for (var i = 0; i < keys.length; i++) { + if (newResolvedState.expanded[keys[i]]) { + newResolvedState.frozen = true; + break; + } + } + } + + // If the data isn't frozen and either the data or + // sorting model has changed, update the data + if (oldState.frozen && !newResolvedState.frozen || oldState.sorted !== newResolvedState.sorted || oldState.filtered !== newResolvedState.filtered || oldState.showFilters !== newResolvedState.showFilters || !newResolvedState.frozen && oldState.resolvedData !== newResolvedState.resolvedData) { + // Handle collapseOnsortedChange & collapseOnDataChange + if (oldState.sorted !== newResolvedState.sorted && this.props.collapseOnSortingChange || oldState.filtered !== newResolvedState.filtered || oldState.showFilters !== newResolvedState.showFilters || oldState.sortedData && !newResolvedState.frozen && oldState.resolvedData !== newResolvedState.resolvedData && this.props.collapseOnDataChange) { + newResolvedState.expanded = {}; + } + + Object.assign(newResolvedState, this.getSortedData(newResolvedState)); + } + + // Set page to 0 if filters change + if (oldState.filtered !== newResolvedState.filtered) { + newResolvedState.page = 0; + } + + // Calculate pageSize all the time + if (newResolvedState.sortedData) { + newResolvedState.pages = newResolvedState.manual ? newResolvedState.pages : Math.ceil(newResolvedState.sortedData.length / newResolvedState.pageSize); + newResolvedState.page = Math.max(newResolvedState.page >= newResolvedState.pages ? newResolvedState.pages - 1 : newResolvedState.page, 0); + } + + return this.setState(newResolvedState, function () { + cb && cb(); + if (oldState.page !== newResolvedState.page || oldState.pageSize !== newResolvedState.pageSize || oldState.sorted !== newResolvedState.sorted || oldState.filtered !== newResolvedState.filtered) { + _this2.fireFetchData(); + } + }); + } + }]); + + return _class; + }(Base); +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9saWZlY3ljbGUuanMiXSwibmFtZXMiOlsic2V0U3RhdGVXaXRoRGF0YSIsImdldERhdGFNb2RlbCIsImdldFJlc29sdmVkU3RhdGUiLCJmaXJlRmV0Y2hEYXRhIiwibmV4dFByb3BzIiwibmV4dFN0YXRlIiwib2xkU3RhdGUiLCJuZXdTdGF0ZSIsImRlZmF1bHRhYmxlT3B0aW9ucyIsImZvckVhY2giLCJkZWZhdWx0TmFtZSIsIngiLCJjaGFyQXQiLCJ0b1VwcGVyQ2FzZSIsInNsaWNlIiwiSlNPTiIsInN0cmluZ2lmeSIsInJlc2V0dGFibGVPcHRpb25zIiwiYmFzZU5hbWUiLCJyZXBsYWNlIiwib3B0aW9uTmFtZSIsImRhdGEiLCJjb2x1bW5zIiwicGl2b3RCeSIsInNvcnRlZCIsImZpbHRlcmVkIiwiY2IiLCJuZXdSZXNvbHZlZFN0YXRlIiwiZnJlZXplV2hlbkV4cGFuZGVkIiwiZnJvemVuIiwia2V5cyIsIk9iamVjdCIsImV4cGFuZGVkIiwiaSIsImxlbmd0aCIsInNob3dGaWx0ZXJzIiwicmVzb2x2ZWREYXRhIiwicHJvcHMiLCJjb2xsYXBzZU9uU29ydGluZ0NoYW5nZSIsInNvcnRlZERhdGEiLCJjb2xsYXBzZU9uRGF0YUNoYW5nZSIsImFzc2lnbiIsImdldFNvcnRlZERhdGEiLCJwYWdlIiwicGFnZXMiLCJtYW51YWwiLCJNYXRoIiwiY2VpbCIsInBhZ2VTaXplIiwibWF4Iiwic2V0U3RhdGUiLCJCYXNlIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7OztrQkFBZTtBQUFBO0FBQUE7O0FBQUE7QUFBQTs7QUFBQTtBQUFBOztBQUFBO0FBQUE7QUFBQSwyQ0FFVztBQUNwQixhQUFLQSxnQkFBTCxDQUFzQixLQUFLQyxZQUFMLENBQWtCLEtBQUtDLGdCQUFMLEVBQWxCLENBQXRCO0FBQ0Q7QUFKVTtBQUFBO0FBQUEsMENBTVU7QUFDbkIsYUFBS0MsYUFBTDtBQUNEO0FBUlU7QUFBQTtBQUFBLGdEQVVnQkMsU0FWaEIsRUFVMkJDLFNBVjNCLEVBVXNDO0FBQy9DLFlBQU1DLFdBQVcsS0FBS0osZ0JBQUwsRUFBakI7QUFDQSxZQUFNSyxXQUFXLEtBQUtMLGdCQUFMLENBQXNCRSxTQUF0QixFQUFpQ0MsU0FBakMsQ0FBakI7O0FBRUE7QUFDQTtBQUNBLFlBQU1HLHFCQUFxQixDQUFDLFFBQUQsRUFBVyxVQUFYLEVBQXVCLFNBQXZCLEVBQWtDLFVBQWxDLENBQTNCO0FBQ0FBLDJCQUFtQkMsT0FBbkIsQ0FBMkIsYUFBSztBQUM5QixjQUFNQywyQkFBd0JDLEVBQUVDLE1BQUYsQ0FBUyxDQUFULEVBQVlDLFdBQVosS0FBNEJGLEVBQUVHLEtBQUYsQ0FBUSxDQUFSLENBQXBELENBQU47QUFDQSxjQUNFQyxLQUFLQyxTQUFMLENBQWVWLFNBQVNJLFdBQVQsQ0FBZixNQUNBSyxLQUFLQyxTQUFMLENBQWVULFNBQVNHLFdBQVQsQ0FBZixDQUZGLEVBR0U7QUFDQUgscUJBQVNJLENBQVQsSUFBY0osU0FBU0csV0FBVCxDQUFkO0FBQ0Q7QUFDRixTQVJEOztBQVVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsWUFBTU8sb0JBQW9CLENBQUMsVUFBRCxFQUFhLFlBQWIsRUFBMkIsV0FBM0IsQ0FBMUI7QUFDQUEsMEJBQWtCUixPQUFsQixDQUEwQixhQUFLO0FBQzdCLGNBQUlILFNBQVNLLENBQVQsTUFBZ0JKLFNBQVNJLENBQVQsQ0FBcEIsRUFBaUM7QUFDL0IsZ0JBQU1PLFdBQVdQLEVBQUVRLE9BQUYsQ0FBVSxNQUFWLEVBQWtCLEVBQWxCLENBQWpCO0FBQ0EsZ0JBQU1DLGFBQWdCRixRQUFoQixPQUFOO0FBQ0EsZ0JBQU1SLDJCQUF3QlUsV0FBV1IsTUFBWCxDQUFrQixDQUFsQixFQUFxQkMsV0FBckIsS0FDNUJPLFdBQVdOLEtBQVgsQ0FBaUIsQ0FBakIsQ0FESSxDQUFOO0FBRUFQLHFCQUFTYSxVQUFULElBQXVCYixTQUFTRyxXQUFULENBQXZCO0FBQ0Q7QUFDRixTQVJEOztBQVVBO0FBQ0EsWUFDRUosU0FBU2UsSUFBVCxLQUFrQmQsU0FBU2MsSUFBM0IsSUFDQWYsU0FBU2dCLE9BQVQsS0FBcUJmLFNBQVNlLE9BRDlCLElBRUFoQixTQUFTaUIsT0FBVCxLQUFxQmhCLFNBQVNnQixPQUY5QixJQUdBakIsU0FBU2tCLE1BQVQsS0FBb0JqQixTQUFTaUIsTUFIN0IsSUFJQWxCLFNBQVNtQixRQUFULEtBQXNCbEIsU0FBU2tCLFFBTGpDLEVBTUU7QUFDQSxlQUFLekIsZ0JBQUwsQ0FBc0IsS0FBS0MsWUFBTCxDQUFrQk0sUUFBbEIsQ0FBdEI7QUFDRDtBQUNGO0FBcERVO0FBQUE7QUFBQSx1Q0FzRE9BLFFBdERQLEVBc0RpQm1CLEVBdERqQixFQXNEcUI7QUFBQTs7QUFDOUIsWUFBTXBCLFdBQVcsS0FBS0osZ0JBQUwsRUFBakI7QUFDQSxZQUFNeUIsbUJBQW1CLEtBQUt6QixnQkFBTCxDQUFzQixFQUF0QixFQUEwQkssUUFBMUIsQ0FBekI7QUFGOEIsWUFHdEJxQixrQkFIc0IsR0FHQ0QsZ0JBSEQsQ0FHdEJDLGtCQUhzQjs7QUFLOUI7O0FBQ0FELHlCQUFpQkUsTUFBakIsR0FBMEIsS0FBMUI7O0FBRUE7QUFDQSxZQUFJRCxrQkFBSixFQUF3QjtBQUN0QjtBQUNBLGNBQU1FLE9BQU9DLE9BQU9ELElBQVAsQ0FBWUgsaUJBQWlCSyxRQUE3QixDQUFiO0FBQ0EsZUFBSyxJQUFJQyxJQUFJLENBQWIsRUFBZ0JBLElBQUlILEtBQUtJLE1BQXpCLEVBQWlDRCxHQUFqQyxFQUFzQztBQUNwQyxnQkFBSU4saUJBQWlCSyxRQUFqQixDQUEwQkYsS0FBS0csQ0FBTCxDQUExQixDQUFKLEVBQXdDO0FBQ3RDTiwrQkFBaUJFLE1BQWpCLEdBQTBCLElBQTFCO0FBQ0E7QUFDRDtBQUNGO0FBQ0Y7O0FBRUQ7QUFDQTtBQUNBLFlBQ0d2QixTQUFTdUIsTUFBVCxJQUFtQixDQUFDRixpQkFBaUJFLE1BQXRDLElBQ0F2QixTQUFTa0IsTUFBVCxLQUFvQkcsaUJBQWlCSCxNQURyQyxJQUVBbEIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFGdkMsSUFHQW5CLFNBQVM2QixXQUFULEtBQXlCUixpQkFBaUJRLFdBSDFDLElBSUMsQ0FBQ1IsaUJBQWlCRSxNQUFsQixJQUNDdkIsU0FBUzhCLFlBQVQsS0FBMEJULGlCQUFpQlMsWUFOL0MsRUFPRTtBQUNBO0FBQ0EsY0FDRzlCLFNBQVNrQixNQUFULEtBQW9CRyxpQkFBaUJILE1BQXJDLElBQ0MsS0FBS2EsS0FBTCxDQUFXQyx1QkFEYixJQUVBaEMsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFGdkMsSUFHQW5CLFNBQVM2QixXQUFULEtBQXlCUixpQkFBaUJRLFdBSDFDLElBSUM3QixTQUFTaUMsVUFBVCxJQUNDLENBQUNaLGlCQUFpQkUsTUFEbkIsSUFFQ3ZCLFNBQVM4QixZQUFULEtBQTBCVCxpQkFBaUJTLFlBRjVDLElBR0MsS0FBS0MsS0FBTCxDQUFXRyxvQkFSZixFQVNFO0FBQ0FiLDZCQUFpQkssUUFBakIsR0FBNEIsRUFBNUI7QUFDRDs7QUFFREQsaUJBQU9VLE1BQVAsQ0FBY2QsZ0JBQWQsRUFBZ0MsS0FBS2UsYUFBTCxDQUFtQmYsZ0JBQW5CLENBQWhDO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJckIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFBM0MsRUFBcUQ7QUFDbkRFLDJCQUFpQmdCLElBQWpCLEdBQXdCLENBQXhCO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJaEIsaUJBQWlCWSxVQUFyQixFQUFpQztBQUMvQlosMkJBQWlCaUIsS0FBakIsR0FBeUJqQixpQkFBaUJrQixNQUFqQixHQUNyQmxCLGlCQUFpQmlCLEtBREksR0FFckJFLEtBQUtDLElBQUwsQ0FDQXBCLGlCQUFpQlksVUFBakIsQ0FBNEJMLE1BQTVCLEdBQXFDUCxpQkFBaUJxQixRQUR0RCxDQUZKO0FBS0FyQiwyQkFBaUJnQixJQUFqQixHQUF3QkcsS0FBS0csR0FBTCxDQUN0QnRCLGlCQUFpQmdCLElBQWpCLElBQXlCaEIsaUJBQWlCaUIsS0FBMUMsR0FDSWpCLGlCQUFpQmlCLEtBQWpCLEdBQXlCLENBRDdCLEdBRUlqQixpQkFBaUJnQixJQUhDLEVBSXRCLENBSnNCLENBQXhCO0FBTUQ7O0FBRUQsZUFBTyxLQUFLTyxRQUFMLENBQWN2QixnQkFBZCxFQUFnQyxZQUFNO0FBQzNDRCxnQkFBTUEsSUFBTjtBQUNBLGNBQ0VwQixTQUFTcUMsSUFBVCxLQUFrQmhCLGlCQUFpQmdCLElBQW5DLElBQ0FyQyxTQUFTMEMsUUFBVCxLQUFzQnJCLGlCQUFpQnFCLFFBRHZDLElBRUExQyxTQUFTa0IsTUFBVCxLQUFvQkcsaUJBQWlCSCxNQUZyQyxJQUdBbEIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFKekMsRUFLRTtBQUNBLG1CQUFLdEIsYUFBTDtBQUNEO0FBQ0YsU0FWTSxDQUFQO0FBV0Q7QUFwSVU7O0FBQUE7QUFBQSxJQUNDZ0QsSUFERDtBQUFBLEMiLCJmaWxlIjoibGlmZWN5Y2xlLmpzIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0IGRlZmF1bHQgQmFzZSA9PlxuICBjbGFzcyBleHRlbmRzIEJhc2Uge1xuICAgIGNvbXBvbmVudFdpbGxNb3VudCAoKSB7XG4gICAgICB0aGlzLnNldFN0YXRlV2l0aERhdGEodGhpcy5nZXREYXRhTW9kZWwodGhpcy5nZXRSZXNvbHZlZFN0YXRlKCkpKVxuICAgIH1cblxuICAgIGNvbXBvbmVudERpZE1vdW50ICgpIHtcbiAgICAgIHRoaXMuZmlyZUZldGNoRGF0YSgpXG4gICAgfVxuXG4gICAgY29tcG9uZW50V2lsbFJlY2VpdmVQcm9wcyAobmV4dFByb3BzLCBuZXh0U3RhdGUpIHtcbiAgICAgIGNvbnN0IG9sZFN0YXRlID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKClcbiAgICAgIGNvbnN0IG5ld1N0YXRlID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKG5leHRQcm9wcywgbmV4dFN0YXRlKVxuXG4gICAgICAvLyBEbyBhIGRlZXAgY29tcGFyZSBvZiBuZXcgYW5kIG9sZCBgZGVmYXVsdE9wdGlvbmAgYW5kXG4gICAgICAvLyBpZiB0aGV5IGFyZSBkaWZmZXJlbnQgcmVzZXQgYG9wdGlvbiA9IGRlZmF1bHRPcHRpb25gXG4gICAgICBjb25zdCBkZWZhdWx0YWJsZU9wdGlvbnMgPSBbJ3NvcnRlZCcsICdmaWx0ZXJlZCcsICdyZXNpemVkJywgJ2V4cGFuZGVkJ11cbiAgICAgIGRlZmF1bHRhYmxlT3B0aW9ucy5mb3JFYWNoKHggPT4ge1xuICAgICAgICBjb25zdCBkZWZhdWx0TmFtZSA9IGBkZWZhdWx0JHt4LmNoYXJBdCgwKS50b1VwcGVyQ2FzZSgpICsgeC5zbGljZSgxKX1gXG4gICAgICAgIGlmIChcbiAgICAgICAgICBKU09OLnN0cmluZ2lmeShvbGRTdGF0ZVtkZWZhdWx0TmFtZV0pICE9PVxuICAgICAgICAgIEpTT04uc3RyaW5naWZ5KG5ld1N0YXRlW2RlZmF1bHROYW1lXSlcbiAgICAgICAgKSB7XG4gICAgICAgICAgbmV3U3RhdGVbeF0gPSBuZXdTdGF0ZVtkZWZhdWx0TmFtZV1cbiAgICAgICAgfVxuICAgICAgfSlcblxuICAgICAgLy8gSWYgdGhleSBjaGFuZ2UgdGhlc2UgdGFibGUgb3B0aW9ucywgd2UgbmVlZCB0byByZXNldCBkZWZhdWx0c1xuICAgICAgLy8gb3IgZWxzZSB3ZSBjb3VsZCBnZXQgaW50byBhIHN0YXRlIHdoZXJlIHRoZSB1c2VyIGhhcyBjaGFuZ2VkIHRoZSBVSVxuICAgICAgLy8gYW5kIHRoZW4gZGlzYWJsZWQgdGhlIGFiaWxpdHkgdG8gY2hhbmdlIGl0IGJhY2suXG4gICAgICAvLyBlLmcuIElmIGBmaWx0ZXJhYmxlYCBoYXMgY2hhbmdlZCwgc2V0IGBmaWx0ZXJlZCA9IGRlZmF1bHRGaWx0ZXJlZGBcbiAgICAgIGNvbnN0IHJlc2V0dGFibGVPcHRpb25zID0gWydzb3J0YWJsZScsICdmaWx0ZXJhYmxlJywgJ3Jlc2l6YWJsZSddXG4gICAgICByZXNldHRhYmxlT3B0aW9ucy5mb3JFYWNoKHggPT4ge1xuICAgICAgICBpZiAob2xkU3RhdGVbeF0gIT09IG5ld1N0YXRlW3hdKSB7XG4gICAgICAgICAgY29uc3QgYmFzZU5hbWUgPSB4LnJlcGxhY2UoJ2FibGUnLCAnJylcbiAgICAgICAgICBjb25zdCBvcHRpb25OYW1lID0gYCR7YmFzZU5hbWV9ZWRgXG4gICAgICAgICAgY29uc3QgZGVmYXVsdE5hbWUgPSBgZGVmYXVsdCR7b3B0aW9uTmFtZS5jaGFyQXQoMCkudG9VcHBlckNhc2UoKSArXG4gICAgICAgICAgICBvcHRpb25OYW1lLnNsaWNlKDEpfWBcbiAgICAgICAgICBuZXdTdGF0ZVtvcHRpb25OYW1lXSA9IG5ld1N0YXRlW2RlZmF1bHROYW1lXVxuICAgICAgICB9XG4gICAgICB9KVxuXG4gICAgICAvLyBQcm9wcyB0aGF0IHRyaWdnZXIgYSBkYXRhIHVwZGF0ZVxuICAgICAgaWYgKFxuICAgICAgICBvbGRTdGF0ZS5kYXRhICE9PSBuZXdTdGF0ZS5kYXRhIHx8XG4gICAgICAgIG9sZFN0YXRlLmNvbHVtbnMgIT09IG5ld1N0YXRlLmNvbHVtbnMgfHxcbiAgICAgICAgb2xkU3RhdGUucGl2b3RCeSAhPT0gbmV3U3RhdGUucGl2b3RCeSB8fFxuICAgICAgICBvbGRTdGF0ZS5zb3J0ZWQgIT09IG5ld1N0YXRlLnNvcnRlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3U3RhdGUuZmlsdGVyZWRcbiAgICAgICkge1xuICAgICAgICB0aGlzLnNldFN0YXRlV2l0aERhdGEodGhpcy5nZXREYXRhTW9kZWwobmV3U3RhdGUpKVxuICAgICAgfVxuICAgIH1cblxuICAgIHNldFN0YXRlV2l0aERhdGEgKG5ld1N0YXRlLCBjYikge1xuICAgICAgY29uc3Qgb2xkU3RhdGUgPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuICAgICAgY29uc3QgbmV3UmVzb2x2ZWRTdGF0ZSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSh7fSwgbmV3U3RhdGUpXG4gICAgICBjb25zdCB7IGZyZWV6ZVdoZW5FeHBhbmRlZCB9ID0gbmV3UmVzb2x2ZWRTdGF0ZVxuXG4gICAgICAvLyBEZWZhdWx0IHRvIHVuZnJvemVuIHN0YXRlXG4gICAgICBuZXdSZXNvbHZlZFN0YXRlLmZyb3plbiA9IGZhbHNlXG5cbiAgICAgIC8vIElmIGZyZWV6ZVdoZW5FeHBhbmRlZCBpcyBzZXQsIGNoZWNrIGZvciBmcm96ZW4gY29uZGl0aW9uc1xuICAgICAgaWYgKGZyZWV6ZVdoZW5FeHBhbmRlZCkge1xuICAgICAgICAvLyBpZiBhbnkgcm93cyBhcmUgZXhwYW5kZWQsIGZyZWV6ZSB0aGUgZXhpc3RpbmcgZGF0YSBhbmQgc29ydGluZ1xuICAgICAgICBjb25zdCBrZXlzID0gT2JqZWN0LmtleXMobmV3UmVzb2x2ZWRTdGF0ZS5leHBhbmRlZClcbiAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBrZXlzLmxlbmd0aDsgaSsrKSB7XG4gICAgICAgICAgaWYgKG5ld1Jlc29sdmVkU3RhdGUuZXhwYW5kZWRba2V5c1tpXV0pIHtcbiAgICAgICAgICAgIG5ld1Jlc29sdmVkU3RhdGUuZnJvemVuID0gdHJ1ZVxuICAgICAgICAgICAgYnJlYWtcbiAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICAgIH1cblxuICAgICAgLy8gSWYgdGhlIGRhdGEgaXNuJ3QgZnJvemVuIGFuZCBlaXRoZXIgdGhlIGRhdGEgb3JcbiAgICAgIC8vIHNvcnRpbmcgbW9kZWwgaGFzIGNoYW5nZWQsIHVwZGF0ZSB0aGUgZGF0YVxuICAgICAgaWYgKFxuICAgICAgICAob2xkU3RhdGUuZnJvemVuICYmICFuZXdSZXNvbHZlZFN0YXRlLmZyb3plbikgfHxcbiAgICAgICAgb2xkU3RhdGUuc29ydGVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNvcnRlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5maWx0ZXJlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5zaG93RmlsdGVycyAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5zaG93RmlsdGVycyB8fFxuICAgICAgICAoIW5ld1Jlc29sdmVkU3RhdGUuZnJvemVuICYmXG4gICAgICAgICAgb2xkU3RhdGUucmVzb2x2ZWREYXRhICE9PSBuZXdSZXNvbHZlZFN0YXRlLnJlc29sdmVkRGF0YSlcbiAgICAgICkge1xuICAgICAgICAvLyBIYW5kbGUgY29sbGFwc2VPbnNvcnRlZENoYW5nZSAmIGNvbGxhcHNlT25EYXRhQ2hhbmdlXG4gICAgICAgIGlmIChcbiAgICAgICAgICAob2xkU3RhdGUuc29ydGVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNvcnRlZCAmJlxuICAgICAgICAgICAgdGhpcy5wcm9wcy5jb2xsYXBzZU9uU29ydGluZ0NoYW5nZSkgfHxcbiAgICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5maWx0ZXJlZCB8fFxuICAgICAgICAgIG9sZFN0YXRlLnNob3dGaWx0ZXJzICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNob3dGaWx0ZXJzIHx8XG4gICAgICAgICAgKG9sZFN0YXRlLnNvcnRlZERhdGEgJiZcbiAgICAgICAgICAgICFuZXdSZXNvbHZlZFN0YXRlLmZyb3plbiAmJlxuICAgICAgICAgICAgb2xkU3RhdGUucmVzb2x2ZWREYXRhICE9PSBuZXdSZXNvbHZlZFN0YXRlLnJlc29sdmVkRGF0YSAmJlxuICAgICAgICAgICAgdGhpcy5wcm9wcy5jb2xsYXBzZU9uRGF0YUNoYW5nZSlcbiAgICAgICAgKSB7XG4gICAgICAgICAgbmV3UmVzb2x2ZWRTdGF0ZS5leHBhbmRlZCA9IHt9XG4gICAgICAgIH1cblxuICAgICAgICBPYmplY3QuYXNzaWduKG5ld1Jlc29sdmVkU3RhdGUsIHRoaXMuZ2V0U29ydGVkRGF0YShuZXdSZXNvbHZlZFN0YXRlKSlcbiAgICAgIH1cblxuICAgICAgLy8gU2V0IHBhZ2UgdG8gMCBpZiBmaWx0ZXJzIGNoYW5nZVxuICAgICAgaWYgKG9sZFN0YXRlLmZpbHRlcmVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLmZpbHRlcmVkKSB7XG4gICAgICAgIG5ld1Jlc29sdmVkU3RhdGUucGFnZSA9IDBcbiAgICAgIH1cblxuICAgICAgLy8gQ2FsY3VsYXRlIHBhZ2VTaXplIGFsbCB0aGUgdGltZVxuICAgICAgaWYgKG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkRGF0YSkge1xuICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VzID0gbmV3UmVzb2x2ZWRTdGF0ZS5tYW51YWxcbiAgICAgICAgICA/IG5ld1Jlc29sdmVkU3RhdGUucGFnZXNcbiAgICAgICAgICA6IE1hdGguY2VpbChcbiAgICAgICAgICAgIG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkRGF0YS5sZW5ndGggLyBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VTaXplXG4gICAgICAgICAgKVxuICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UgPSBNYXRoLm1heChcbiAgICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UgPj0gbmV3UmVzb2x2ZWRTdGF0ZS5wYWdlc1xuICAgICAgICAgICAgPyBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VzIC0gMVxuICAgICAgICAgICAgOiBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UsXG4gICAgICAgICAgMFxuICAgICAgICApXG4gICAgICB9XG5cbiAgICAgIHJldHVybiB0aGlzLnNldFN0YXRlKG5ld1Jlc29sdmVkU3RhdGUsICgpID0+IHtcbiAgICAgICAgY2IgJiYgY2IoKVxuICAgICAgICBpZiAoXG4gICAgICAgICAgb2xkU3RhdGUucGFnZSAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5wYWdlIHx8XG4gICAgICAgICAgb2xkU3RhdGUucGFnZVNpemUgIT09IG5ld1Jlc29sdmVkU3RhdGUucGFnZVNpemUgfHxcbiAgICAgICAgICBvbGRTdGF0ZS5zb3J0ZWQgIT09IG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkIHx8XG4gICAgICAgICAgb2xkU3RhdGUuZmlsdGVyZWQgIT09IG5ld1Jlc29sdmVkU3RhdGUuZmlsdGVyZWRcbiAgICAgICAgKSB7XG4gICAgICAgICAgdGhpcy5maXJlRmV0Y2hEYXRhKClcbiAgICAgICAgfVxuICAgICAgfSlcbiAgICB9XG4gIH1cbiJdfQ== + +/***/ }), +/* 360 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); + +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _utils = __webpack_require__(95); + +var _utils2 = _interopRequireDefault(_utils); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } + +function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +exports.default = function (Base) { + return function (_Base) { + _inherits(_class, _Base); + + function _class() { + _classCallCheck(this, _class); + + return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments)); + } + + _createClass(_class, [{ + key: 'getResolvedState', + value: function getResolvedState(props, state) { + var resolvedState = _extends({}, _utils2.default.compactObject(this.state), _utils2.default.compactObject(this.props), _utils2.default.compactObject(state), _utils2.default.compactObject(props)); + return resolvedState; + } + }, { + key: 'getDataModel', + value: function getDataModel(newState) { + var _this2 = this; + + var columns = newState.columns, + _newState$pivotBy = newState.pivotBy, + pivotBy = _newState$pivotBy === undefined ? [] : _newState$pivotBy, + data = newState.data, + pivotIDKey = newState.pivotIDKey, + pivotValKey = newState.pivotValKey, + subRowsKey = newState.subRowsKey, + aggregatedKey = newState.aggregatedKey, + nestingLevelKey = newState.nestingLevelKey, + originalKey = newState.originalKey, + indexKey = newState.indexKey, + groupedByPivotKey = newState.groupedByPivotKey, + SubComponent = newState.SubComponent; + + // Determine Header Groups + + var hasHeaderGroups = false; + columns.forEach(function (column) { + if (column.columns) { + hasHeaderGroups = true; + } + }); + + var columnsWithExpander = [].concat(_toConsumableArray(columns)); + + var expanderColumn = columns.find(function (col) { + return col.expander || col.columns && col.columns.some(function (col2) { + return col2.expander; + }); + }); + // The actual expander might be in the columns field of a group column + if (expanderColumn && !expanderColumn.expander) { + expanderColumn = expanderColumn.columns.find(function (col) { + return col.expander; + }); + } + + // If we have SubComponent's we need to make sure we have an expander column + if (SubComponent && !expanderColumn) { + expanderColumn = { expander: true }; + columnsWithExpander = [expanderColumn].concat(_toConsumableArray(columnsWithExpander)); + } + + var makeDecoratedColumn = function makeDecoratedColumn(column, parentColumn) { + var dcol = void 0; + if (column.expander) { + dcol = _extends({}, _this2.props.column, _this2.props.expanderDefaults, column); + } else { + dcol = _extends({}, _this2.props.column, column); + } + + // Ensure minWidth is not greater than maxWidth if set + if (dcol.maxWidth < dcol.minWidth) { + dcol.minWidth = dcol.maxWidth; + } + + if (parentColumn) { + dcol.parentColumn = parentColumn; + } + + // First check for string accessor + if (typeof dcol.accessor === 'string') { + var _ret = function () { + dcol.id = dcol.id || dcol.accessor; + var accessorString = dcol.accessor; + dcol.accessor = function (row) { + return _utils2.default.get(row, accessorString); + }; + return { + v: dcol + }; + }(); + + if ((typeof _ret === 'undefined' ? 'undefined' : _typeof(_ret)) === "object") return _ret.v; + } + + // Fall back to functional accessor (but require an ID) + if (dcol.accessor && !dcol.id) { + console.warn(dcol); + throw new Error('A column id is required if using a non-string accessor for column above.'); + } + + // Fall back to an undefined accessor + if (!dcol.accessor) { + dcol.accessor = function (d) { + return undefined; + }; + } + + return dcol; + }; + + // Decorate the columns + var decorateAndAddToAll = function decorateAndAddToAll(column, parentColumn) { + var decoratedColumn = makeDecoratedColumn(column, parentColumn); + allDecoratedColumns.push(decoratedColumn); + return decoratedColumn; + }; + var allDecoratedColumns = []; + var decoratedColumns = columnsWithExpander.map(function (column, i) { + if (column.columns) { + return _extends({}, column, { + columns: column.columns.map(function (d) { + return decorateAndAddToAll(d, column); + }) + }); + } else { + return decorateAndAddToAll(column); + } + }); + + // Build the visible columns, headers and flat column list + var visibleColumns = decoratedColumns.slice(); + var allVisibleColumns = []; + + visibleColumns = visibleColumns.map(function (column, i) { + if (column.columns) { + var visibleSubColumns = column.columns.filter(function (d) { + return pivotBy.indexOf(d.id) > -1 ? false : _utils2.default.getFirstDefined(d.show, true); + }); + return _extends({}, column, { + columns: visibleSubColumns + }); + } + return column; + }); + + visibleColumns = visibleColumns.filter(function (column) { + return column.columns ? column.columns.length : pivotBy.indexOf(column.id) > -1 ? false : _utils2.default.getFirstDefined(column.show, true); + }); + + // Find any custom pivot location + var pivotIndex = visibleColumns.findIndex(function (col) { + return col.pivot; + }); + + // Handle Pivot Columns + if (pivotBy.length) { + (function () { + // Retrieve the pivot columns in the correct pivot order + var pivotColumns = []; + pivotBy.forEach(function (pivotID) { + var found = allDecoratedColumns.find(function (d) { + return d.id === pivotID; + }); + if (found) { + pivotColumns.push(found); + } + }); + + var PivotParentColumn = pivotColumns.reduce(function (prev, current) { + return prev && prev === current.parentColumn && current.parentColumn; + }, pivotColumns[0].parentColumn); + + var PivotGroupHeader = hasHeaderGroups && PivotParentColumn.Header; + PivotGroupHeader = PivotGroupHeader || function () { + return _react2.default.createElement( + 'strong', + null, + 'Pivoted' + ); + }; + + var pivotColumnGroup = { + Header: PivotGroupHeader, + columns: pivotColumns.map(function (col) { + return _extends({}, _this2.props.pivotDefaults, col, { + pivoted: true + }); + }) + }; + + // Place the pivotColumns back into the visibleColumns + if (pivotIndex >= 0) { + pivotColumnGroup = _extends({}, visibleColumns[pivotIndex], pivotColumnGroup); + visibleColumns.splice(pivotIndex, 1, pivotColumnGroup); + } else { + visibleColumns.unshift(pivotColumnGroup); + } + })(); + } + + // Build Header Groups + var headerGroups = []; + var currentSpan = []; + + // A convenience function to add a header and reset the currentSpan + var addHeader = function addHeader(columns, column) { + headerGroups.push(_extends({}, _this2.props.column, column, { + columns: columns + })); + currentSpan = []; + }; + + // Build flast list of allVisibleColumns and HeaderGroups + visibleColumns.forEach(function (column, i) { + if (column.columns) { + allVisibleColumns = allVisibleColumns.concat(column.columns); + if (currentSpan.length > 0) { + addHeader(currentSpan); + } + addHeader(column.columns, column); + return; + } + allVisibleColumns.push(column); + currentSpan.push(column); + }); + if (hasHeaderGroups && currentSpan.length > 0) { + addHeader(currentSpan); + } + + // Access the data + var accessRow = function accessRow(d, i) { + var _row; + + var level = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0; + + var row = (_row = {}, _defineProperty(_row, originalKey, d), _defineProperty(_row, indexKey, i), _defineProperty(_row, subRowsKey, d[subRowsKey]), _defineProperty(_row, nestingLevelKey, level), _row); + allDecoratedColumns.forEach(function (column) { + if (column.expander) return; + row[column.id] = column.accessor(d); + }); + if (row[subRowsKey]) { + row[subRowsKey] = row[subRowsKey].map(function (d, i) { + return accessRow(d, i, level + 1); + }); + } + return row; + }; + var resolvedData = data.map(function (d, i) { + return accessRow(d, i); + }); + + // If pivoting, recursively group the data + var aggregate = function aggregate(rows) { + var aggregationValues = {}; + aggregatingColumns.forEach(function (column) { + var values = rows.map(function (d) { + return d[column.id]; + }); + aggregationValues[column.id] = column.aggregate(values, rows); + }); + return aggregationValues; + }; + + // TODO: Make it possible to fabricate nested rows without pivoting + var aggregatingColumns = allVisibleColumns.filter(function (d) { + return !d.expander && d.aggregate; + }); + if (pivotBy.length) { + (function () { + var groupRecursively = function groupRecursively(rows, keys) { + var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0; + + // This is the last level, just return the rows + if (i === keys.length) { + return rows; + } + // Group the rows together for this level + var groupedRows = Object.entries(_utils2.default.groupBy(rows, keys[i])).map(function (_ref) { + var _ref3; + + var _ref2 = _slicedToArray(_ref, 2), + key = _ref2[0], + value = _ref2[1]; + + return _ref3 = {}, _defineProperty(_ref3, pivotIDKey, keys[i]), _defineProperty(_ref3, pivotValKey, key), _defineProperty(_ref3, keys[i], key), _defineProperty(_ref3, subRowsKey, value), _defineProperty(_ref3, nestingLevelKey, i), _defineProperty(_ref3, groupedByPivotKey, true), _ref3; + }); + // Recurse into the subRows + groupedRows = groupedRows.map(function (rowGroup) { + var _extends2; + + var subRows = groupRecursively(rowGroup[subRowsKey], keys, i + 1); + return _extends({}, rowGroup, (_extends2 = {}, _defineProperty(_extends2, subRowsKey, subRows), _defineProperty(_extends2, aggregatedKey, true), _extends2), aggregate(subRows)); + }); + return groupedRows; + }; + resolvedData = groupRecursively(resolvedData, pivotBy); + })(); + } + + return _extends({}, newState, { + resolvedData: resolvedData, + allVisibleColumns: allVisibleColumns, + headerGroups: headerGroups, + allDecoratedColumns: allDecoratedColumns, + hasHeaderGroups: hasHeaderGroups + }); + } + }, { + key: 'getSortedData', + value: function getSortedData(resolvedState) { + var manual = resolvedState.manual, + sorted = resolvedState.sorted, + filtered = resolvedState.filtered, + defaultFilterMethod = resolvedState.defaultFilterMethod, + resolvedData = resolvedState.resolvedData, + allVisibleColumns = resolvedState.allVisibleColumns, + allDecoratedColumns = resolvedState.allDecoratedColumns; + + + var sortMethodsByColumnID = {}; + + allDecoratedColumns.filter(function (col) { + return col.sortMethod; + }).forEach(function (col) { + sortMethodsByColumnID[col.id] = col.sortMethod; + }); + + // Resolve the data from either manual data or sorted data + return { + sortedData: manual ? resolvedData : this.sortData(this.filterData(resolvedData, filtered, defaultFilterMethod, allVisibleColumns), sorted, sortMethodsByColumnID) + }; + } + }, { + key: 'fireFetchData', + value: function fireFetchData() { + this.props.onFetchData(this.getResolvedState(), this); + } + }, { + key: 'getPropOrState', + value: function getPropOrState(key) { + return _utils2.default.getFirstDefined(this.props[key], this.state[key]); + } + }, { + key: 'getStateOrProp', + value: function getStateOrProp(key) { + return _utils2.default.getFirstDefined(this.state[key], this.props[key]); + } + }, { + key: 'filterData', + value: function filterData(data, filtered, defaultFilterMethod, allVisibleColumns) { + var _this3 = this; + + var filteredData = data; + + if (filtered.length) { + filteredData = filtered.reduce(function (filteredSoFar, nextFilter) { + var column = allVisibleColumns.find(function (x) { + return x.id === nextFilter.id; + }); + + // Don't filter hidden columns or columns that have had their filters disabled + if (!column || column.filterable === false) { + return filteredSoFar; + } + + var filterMethod = column.filterMethod || defaultFilterMethod; + + // If 'filterAll' is set to true, pass the entire dataset to the filter method + if (column.filterAll) { + return filterMethod(nextFilter, filteredSoFar, column); + } else { + return filteredSoFar.filter(function (row) { + return filterMethod(nextFilter, row, column); + }); + } + }, filteredData); + + // Apply the filter to the subrows if we are pivoting, and then + // filter any rows without subcolumns because it would be strange to show + filteredData = filteredData.map(function (row) { + if (!row[_this3.props.subRowsKey]) { + return row; + } + return _extends({}, row, _defineProperty({}, _this3.props.subRowsKey, _this3.filterData(row[_this3.props.subRowsKey], filtered, defaultFilterMethod, allVisibleColumns))); + }).filter(function (row) { + if (!row[_this3.props.subRowsKey]) { + return true; + } + return row[_this3.props.subRowsKey].length > 0; + }); + } + + return filteredData; + } + }, { + key: 'sortData', + value: function sortData(data, sorted) { + var _this4 = this; + + var sortMethodsByColumnID = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {}; + + if (!sorted.length) { + return data; + } + + var sortedData = (this.props.orderByMethod || _utils2.default.orderBy)(data, sorted.map(function (sort) { + // Support custom sorting methods for each column + if (sortMethodsByColumnID[sort.id]) { + return function (a, b) { + return sortMethodsByColumnID[sort.id](a[sort.id], b[sort.id]); + }; + } + return function (a, b) { + return _this4.props.defaultSortMethod(a[sort.id], b[sort.id]); + }; + }), sorted.map(function (d) { + return !d.desc; + }), this.props.indexKey); + + sortedData.forEach(function (row) { + if (!row[_this4.props.subRowsKey]) { + return; + } + row[_this4.props.subRowsKey] = _this4.sortData(row[_this4.props.subRowsKey], sorted, sortMethodsByColumnID); + }); + + return sortedData; + } + }, { + key: 'getMinRows', + value: function getMinRows() { + return _utils2.default.getFirstDefined(this.props.minRows, this.getStateOrProp('pageSize')); + } + + // User actions + + }, { + key: 'onPageChange', + value: function onPageChange(page) { + var _props = this.props, + onPageChange = _props.onPageChange, + collapseOnPageChange = _props.collapseOnPageChange; + + + var newState = { page: page }; + if (collapseOnPageChange) { + newState.expanded = {}; + } + this.setStateWithData(newState, function () { + onPageChange && onPageChange(page); + }); + } + }, { + key: 'onPageSizeChange', + value: function onPageSizeChange(newPageSize) { + var onPageSizeChange = this.props.onPageSizeChange; + + var _getResolvedState = this.getResolvedState(), + pageSize = _getResolvedState.pageSize, + page = _getResolvedState.page; + + // Normalize the page to display + + + var currentRow = pageSize * page; + var newPage = Math.floor(currentRow / newPageSize); + + this.setStateWithData({ + pageSize: newPageSize, + page: newPage + }, function () { + onPageSizeChange && onPageSizeChange(newPageSize, newPage); + }); + } + }, { + key: 'sortColumn', + value: function sortColumn(column, additive) { + var _getResolvedState2 = this.getResolvedState(), + sorted = _getResolvedState2.sorted, + skipNextSort = _getResolvedState2.skipNextSort, + defaultSortDesc = _getResolvedState2.defaultSortDesc; + + var firstSortDirection = column.hasOwnProperty('defaultSortDesc') ? column.defaultSortDesc : defaultSortDesc; + var secondSortDirection = !firstSortDirection; + + // we can't stop event propagation from the column resize move handlers + // attached to the document because of react's synthetic events + // so we have to prevent the sort function from actually sorting + // if we click on the column resize element within a header. + if (skipNextSort) { + this.setStateWithData({ + skipNextSort: false + }); + return; + } + + var onSortedChange = this.props.onSortedChange; + + + var newSorted = _utils2.default.clone(sorted || []).map(function (d) { + d.desc = _utils2.default.isSortingDesc(d); + return d; + }); + if (!_utils2.default.isArray(column)) { + // Single-Sort + var existingIndex = newSorted.findIndex(function (d) { + return d.id === column.id; + }); + if (existingIndex > -1) { + var existing = newSorted[existingIndex]; + if (existing.desc === secondSortDirection) { + if (additive) { + newSorted.splice(existingIndex, 1); + } else { + existing.desc = firstSortDirection; + newSorted = [existing]; + } + } else { + existing.desc = secondSortDirection; + if (!additive) { + newSorted = [existing]; + } + } + } else { + if (additive) { + newSorted.push({ + id: column.id, + desc: firstSortDirection + }); + } else { + newSorted = [{ + id: column.id, + desc: firstSortDirection + }]; + } + } + } else { + (function () { + // Multi-Sort + var existingIndex = newSorted.findIndex(function (d) { + return d.id === column[0].id; + }); + // Existing Sorted Column + if (existingIndex > -1) { + var _existing = newSorted[existingIndex]; + if (_existing.desc === secondSortDirection) { + if (additive) { + newSorted.splice(existingIndex, column.length); + } else { + column.forEach(function (d, i) { + newSorted[existingIndex + i].desc = firstSortDirection; + }); + } + } else { + column.forEach(function (d, i) { + newSorted[existingIndex + i].desc = secondSortDirection; + }); + } + if (!additive) { + newSorted = newSorted.slice(existingIndex, column.length); + } + } else { + // New Sort Column + if (additive) { + newSorted = newSorted.concat(column.map(function (d) { + return { + id: d.id, + desc: firstSortDirection + }; + })); + } else { + newSorted = column.map(function (d) { + return { + id: d.id, + desc: firstSortDirection + }; + }); + } + } + })(); + } + + this.setStateWithData({ + page: !sorted.length && newSorted.length || !additive ? 0 : this.state.page, + sorted: newSorted + }, function () { + onSortedChange && onSortedChange(newSorted, column, additive); + }); + } + }, { + key: 'filterColumn', + value: function filterColumn(column, value) { + var _getResolvedState3 = this.getResolvedState(), + filtered = _getResolvedState3.filtered; + + var onFilteredChange = this.props.onFilteredChange; + + // Remove old filter first if it exists + + var newFiltering = (filtered || []).filter(function (x) { + if (x.id !== column.id) { + return true; + } + }); + + if (value !== '') { + newFiltering.push({ + id: column.id, + value: value + }); + } + + this.setStateWithData({ + filtered: newFiltering + }, function () { + onFilteredChange && onFilteredChange(newFiltering, column, value); + }); + } + }, { + key: 'resizeColumnStart', + value: function resizeColumnStart(event, column, isTouch) { + var _this5 = this; + + event.stopPropagation(); + var parentWidth = event.target.parentElement.getBoundingClientRect().width; + + var pageX = void 0; + if (isTouch) { + pageX = event.changedTouches[0].pageX; + } else { + pageX = event.pageX; + } + + this.trapEvents = true; + this.setStateWithData({ + currentlyResizing: { + id: column.id, + startX: pageX, + parentWidth: parentWidth + } + }, function () { + if (isTouch) { + document.addEventListener('touchmove', _this5.resizeColumnMoving); + document.addEventListener('touchcancel', _this5.resizeColumnEnd); + document.addEventListener('touchend', _this5.resizeColumnEnd); + } else { + document.addEventListener('mousemove', _this5.resizeColumnMoving); + document.addEventListener('mouseup', _this5.resizeColumnEnd); + document.addEventListener('mouseleave', _this5.resizeColumnEnd); + } + }); + } + }, { + key: 'resizeColumnMoving', + value: function resizeColumnMoving(event) { + event.stopPropagation(); + var onResizedChange = this.props.onResizedChange; + + var _getResolvedState4 = this.getResolvedState(), + resized = _getResolvedState4.resized, + currentlyResizing = _getResolvedState4.currentlyResizing; + + // Delete old value + + + var newResized = resized.filter(function (x) { + return x.id !== currentlyResizing.id; + }); + + var pageX = void 0; + + if (event.type === 'touchmove') { + pageX = event.changedTouches[0].pageX; + } else if (event.type === 'mousemove') { + pageX = event.pageX; + } + + // Set the min size to 10 to account for margin and border or else the group headers don't line up correctly + var newWidth = Math.max(currentlyResizing.parentWidth + pageX - currentlyResizing.startX, 11); + + newResized.push({ + id: currentlyResizing.id, + value: newWidth + }); + + this.setStateWithData({ + resized: newResized + }, function () { + onResizedChange && onResizedChange(newResized, event); + }); + } + }, { + key: 'resizeColumnEnd', + value: function resizeColumnEnd(event) { + event.stopPropagation(); + var isTouch = event.type === 'touchend' || event.type === 'touchcancel'; + + if (isTouch) { + document.removeEventListener('touchmove', this.resizeColumnMoving); + document.removeEventListener('touchcancel', this.resizeColumnEnd); + document.removeEventListener('touchend', this.resizeColumnEnd); + } + + // If its a touch event clear the mouse one's as well because sometimes + // the mouseDown event gets called as well, but the mouseUp event doesn't + document.removeEventListener('mousemove', this.resizeColumnMoving); + document.removeEventListener('mouseup', this.resizeColumnEnd); + document.removeEventListener('mouseleave', this.resizeColumnEnd); + + // The touch events don't propagate up to the sorting's onMouseDown event so + // no need to prevent it from happening or else the first click after a touch + // event resize will not sort the column. + if (!isTouch) { + this.setStateWithData({ + skipNextSort: true, + currentlyResizing: false + }); + } + } + }]); + + return _class; + }(Base); +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9tZXRob2RzLmpzIl0sIm5hbWVzIjpbInByb3BzIiwic3RhdGUiLCJyZXNvbHZlZFN0YXRlIiwiY29tcGFjdE9iamVjdCIsIm5ld1N0YXRlIiwiY29sdW1ucyIsInBpdm90QnkiLCJkYXRhIiwicGl2b3RJREtleSIsInBpdm90VmFsS2V5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJuZXN0aW5nTGV2ZWxLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJTdWJDb21wb25lbnQiLCJoYXNIZWFkZXJHcm91cHMiLCJmb3JFYWNoIiwiY29sdW1uIiwiY29sdW1uc1dpdGhFeHBhbmRlciIsImV4cGFuZGVyQ29sdW1uIiwiZmluZCIsImNvbCIsImV4cGFuZGVyIiwic29tZSIsImNvbDIiLCJtYWtlRGVjb3JhdGVkQ29sdW1uIiwicGFyZW50Q29sdW1uIiwiZGNvbCIsImV4cGFuZGVyRGVmYXVsdHMiLCJtYXhXaWR0aCIsIm1pbldpZHRoIiwiYWNjZXNzb3IiLCJpZCIsImFjY2Vzc29yU3RyaW5nIiwiZ2V0Iiwicm93IiwiY29uc29sZSIsIndhcm4iLCJFcnJvciIsInVuZGVmaW5lZCIsImRlY29yYXRlQW5kQWRkVG9BbGwiLCJkZWNvcmF0ZWRDb2x1bW4iLCJhbGxEZWNvcmF0ZWRDb2x1bW5zIiwicHVzaCIsImRlY29yYXRlZENvbHVtbnMiLCJtYXAiLCJpIiwiZCIsInZpc2libGVDb2x1bW5zIiwic2xpY2UiLCJhbGxWaXNpYmxlQ29sdW1ucyIsInZpc2libGVTdWJDb2x1bW5zIiwiZmlsdGVyIiwiaW5kZXhPZiIsImdldEZpcnN0RGVmaW5lZCIsInNob3ciLCJsZW5ndGgiLCJwaXZvdEluZGV4IiwiZmluZEluZGV4IiwicGl2b3QiLCJwaXZvdENvbHVtbnMiLCJmb3VuZCIsInBpdm90SUQiLCJQaXZvdFBhcmVudENvbHVtbiIsInJlZHVjZSIsInByZXYiLCJjdXJyZW50IiwiUGl2b3RHcm91cEhlYWRlciIsIkhlYWRlciIsInBpdm90Q29sdW1uR3JvdXAiLCJwaXZvdERlZmF1bHRzIiwicGl2b3RlZCIsInNwbGljZSIsInVuc2hpZnQiLCJoZWFkZXJHcm91cHMiLCJjdXJyZW50U3BhbiIsImFkZEhlYWRlciIsImNvbmNhdCIsImFjY2Vzc1JvdyIsImxldmVsIiwicmVzb2x2ZWREYXRhIiwiYWdncmVnYXRlIiwiYWdncmVnYXRpb25WYWx1ZXMiLCJhZ2dyZWdhdGluZ0NvbHVtbnMiLCJ2YWx1ZXMiLCJyb3dzIiwiZ3JvdXBSZWN1cnNpdmVseSIsImtleXMiLCJncm91cGVkUm93cyIsIk9iamVjdCIsImVudHJpZXMiLCJncm91cEJ5Iiwia2V5IiwidmFsdWUiLCJzdWJSb3dzIiwicm93R3JvdXAiLCJtYW51YWwiLCJzb3J0ZWQiLCJmaWx0ZXJlZCIsImRlZmF1bHRGaWx0ZXJNZXRob2QiLCJzb3J0TWV0aG9kc0J5Q29sdW1uSUQiLCJzb3J0TWV0aG9kIiwic29ydGVkRGF0YSIsInNvcnREYXRhIiwiZmlsdGVyRGF0YSIsIm9uRmV0Y2hEYXRhIiwiZ2V0UmVzb2x2ZWRTdGF0ZSIsImZpbHRlcmVkRGF0YSIsImZpbHRlcmVkU29GYXIiLCJuZXh0RmlsdGVyIiwieCIsImZpbHRlcmFibGUiLCJmaWx0ZXJNZXRob2QiLCJmaWx0ZXJBbGwiLCJvcmRlckJ5TWV0aG9kIiwib3JkZXJCeSIsInNvcnQiLCJhIiwiYiIsImRlZmF1bHRTb3J0TWV0aG9kIiwiZGVzYyIsIm1pblJvd3MiLCJnZXRTdGF0ZU9yUHJvcCIsInBhZ2UiLCJvblBhZ2VDaGFuZ2UiLCJjb2xsYXBzZU9uUGFnZUNoYW5nZSIsImV4cGFuZGVkIiwic2V0U3RhdGVXaXRoRGF0YSIsIm5ld1BhZ2VTaXplIiwib25QYWdlU2l6ZUNoYW5nZSIsInBhZ2VTaXplIiwiY3VycmVudFJvdyIsIm5ld1BhZ2UiLCJNYXRoIiwiZmxvb3IiLCJhZGRpdGl2ZSIsInNraXBOZXh0U29ydCIsImRlZmF1bHRTb3J0RGVzYyIsImZpcnN0U29ydERpcmVjdGlvbiIsImhhc093blByb3BlcnR5Iiwic2Vjb25kU29ydERpcmVjdGlvbiIsIm9uU29ydGVkQ2hhbmdlIiwibmV3U29ydGVkIiwiY2xvbmUiLCJpc1NvcnRpbmdEZXNjIiwiaXNBcnJheSIsImV4aXN0aW5nSW5kZXgiLCJleGlzdGluZyIsIm9uRmlsdGVyZWRDaGFuZ2UiLCJuZXdGaWx0ZXJpbmciLCJldmVudCIsImlzVG91Y2giLCJzdG9wUHJvcGFnYXRpb24iLCJwYXJlbnRXaWR0aCIsInRhcmdldCIsInBhcmVudEVsZW1lbnQiLCJnZXRCb3VuZGluZ0NsaWVudFJlY3QiLCJ3aWR0aCIsInBhZ2VYIiwiY2hhbmdlZFRvdWNoZXMiLCJ0cmFwRXZlbnRzIiwiY3VycmVudGx5UmVzaXppbmciLCJzdGFydFgiLCJkb2N1bWVudCIsImFkZEV2ZW50TGlzdGVuZXIiLCJyZXNpemVDb2x1bW5Nb3ZpbmciLCJyZXNpemVDb2x1bW5FbmQiLCJvblJlc2l6ZWRDaGFuZ2UiLCJyZXNpemVkIiwibmV3UmVzaXplZCIsInR5cGUiLCJuZXdXaWR0aCIsIm1heCIsInJlbW92ZUV2ZW50TGlzdGVuZXIiLCJCYXNlIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7OztBQUFBOzs7O0FBQ0E7Ozs7Ozs7Ozs7Ozs7Ozs7a0JBRWU7QUFBQTtBQUFBOztBQUFBO0FBQUE7O0FBQUE7QUFBQTs7QUFBQTtBQUFBO0FBQUEsdUNBRU9BLEtBRlAsRUFFY0MsS0FGZCxFQUVxQjtBQUM5QixZQUFNQyw2QkFDRCxnQkFBRUMsYUFBRixDQUFnQixLQUFLRixLQUFyQixDQURDLEVBRUQsZ0JBQUVFLGFBQUYsQ0FBZ0IsS0FBS0gsS0FBckIsQ0FGQyxFQUdELGdCQUFFRyxhQUFGLENBQWdCRixLQUFoQixDQUhDLEVBSUQsZ0JBQUVFLGFBQUYsQ0FBZ0JILEtBQWhCLENBSkMsQ0FBTjtBQU1BLGVBQU9FLGFBQVA7QUFDRDtBQVZVO0FBQUE7QUFBQSxtQ0FZR0UsUUFaSCxFQVlhO0FBQUE7O0FBQUEsWUFFcEJDLE9BRm9CLEdBY2xCRCxRQWRrQixDQUVwQkMsT0FGb0I7QUFBQSxnQ0FjbEJELFFBZGtCLENBR3BCRSxPQUhvQjtBQUFBLFlBR3BCQSxPQUhvQixxQ0FHVixFQUhVO0FBQUEsWUFJcEJDLElBSm9CLEdBY2xCSCxRQWRrQixDQUlwQkcsSUFKb0I7QUFBQSxZQUtwQkMsVUFMb0IsR0FjbEJKLFFBZGtCLENBS3BCSSxVQUxvQjtBQUFBLFlBTXBCQyxXQU5vQixHQWNsQkwsUUFka0IsQ0FNcEJLLFdBTm9CO0FBQUEsWUFPcEJDLFVBUG9CLEdBY2xCTixRQWRrQixDQU9wQk0sVUFQb0I7QUFBQSxZQVFwQkMsYUFSb0IsR0FjbEJQLFFBZGtCLENBUXBCTyxhQVJvQjtBQUFBLFlBU3BCQyxlQVRvQixHQWNsQlIsUUFka0IsQ0FTcEJRLGVBVG9CO0FBQUEsWUFVcEJDLFdBVm9CLEdBY2xCVCxRQWRrQixDQVVwQlMsV0FWb0I7QUFBQSxZQVdwQkMsUUFYb0IsR0FjbEJWLFFBZGtCLENBV3BCVSxRQVhvQjtBQUFBLFlBWXBCQyxpQkFab0IsR0FjbEJYLFFBZGtCLENBWXBCVyxpQkFab0I7QUFBQSxZQWFwQkMsWUFib0IsR0FjbEJaLFFBZGtCLENBYXBCWSxZQWJvQjs7QUFnQnRCOztBQUNBLFlBQUlDLGtCQUFrQixLQUF0QjtBQUNBWixnQkFBUWEsT0FBUixDQUFnQixrQkFBVTtBQUN4QixjQUFJQyxPQUFPZCxPQUFYLEVBQW9CO0FBQ2xCWSw4QkFBa0IsSUFBbEI7QUFDRDtBQUNGLFNBSkQ7O0FBTUEsWUFBSUcsbURBQTBCZixPQUExQixFQUFKOztBQUVBLFlBQUlnQixpQkFBaUJoQixRQUFRaUIsSUFBUixDQUNuQjtBQUFBLGlCQUNFQyxJQUFJQyxRQUFKLElBQ0NELElBQUlsQixPQUFKLElBQWVrQixJQUFJbEIsT0FBSixDQUFZb0IsSUFBWixDQUFpQjtBQUFBLG1CQUFRQyxLQUFLRixRQUFiO0FBQUEsV0FBakIsQ0FGbEI7QUFBQSxTQURtQixDQUFyQjtBQUtBO0FBQ0EsWUFBSUgsa0JBQWtCLENBQUNBLGVBQWVHLFFBQXRDLEVBQWdEO0FBQzlDSCwyQkFBaUJBLGVBQWVoQixPQUFmLENBQXVCaUIsSUFBdkIsQ0FBNEI7QUFBQSxtQkFBT0MsSUFBSUMsUUFBWDtBQUFBLFdBQTVCLENBQWpCO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJUixnQkFBZ0IsQ0FBQ0ssY0FBckIsRUFBcUM7QUFDbkNBLDJCQUFpQixFQUFFRyxVQUFVLElBQVosRUFBakI7QUFDQUosaUNBQXVCQyxjQUF2Qiw0QkFBMENELG1CQUExQztBQUNEOztBQUVELFlBQU1PLHNCQUFzQixTQUF0QkEsbUJBQXNCLENBQUNSLE1BQUQsRUFBU1MsWUFBVCxFQUEwQjtBQUNwRCxjQUFJQyxhQUFKO0FBQ0EsY0FBSVYsT0FBT0ssUUFBWCxFQUFxQjtBQUNuQkssZ0NBQ0ssT0FBSzdCLEtBQUwsQ0FBV21CLE1BRGhCLEVBRUssT0FBS25CLEtBQUwsQ0FBVzhCLGdCQUZoQixFQUdLWCxNQUhMO0FBS0QsV0FORCxNQU1PO0FBQ0xVLGdDQUNLLE9BQUs3QixLQUFMLENBQVdtQixNQURoQixFQUVLQSxNQUZMO0FBSUQ7O0FBRUQ7QUFDQSxjQUFJVSxLQUFLRSxRQUFMLEdBQWdCRixLQUFLRyxRQUF6QixFQUFtQztBQUNqQ0gsaUJBQUtHLFFBQUwsR0FBZ0JILEtBQUtFLFFBQXJCO0FBQ0Q7O0FBRUQsY0FBSUgsWUFBSixFQUFrQjtBQUNoQkMsaUJBQUtELFlBQUwsR0FBb0JBLFlBQXBCO0FBQ0Q7O0FBRUQ7QUFDQSxjQUFJLE9BQU9DLEtBQUtJLFFBQVosS0FBeUIsUUFBN0IsRUFBdUM7QUFBQTtBQUNyQ0osbUJBQUtLLEVBQUwsR0FBVUwsS0FBS0ssRUFBTCxJQUFXTCxLQUFLSSxRQUExQjtBQUNBLGtCQUFNRSxpQkFBaUJOLEtBQUtJLFFBQTVCO0FBQ0FKLG1CQUFLSSxRQUFMLEdBQWdCO0FBQUEsdUJBQU8sZ0JBQUVHLEdBQUYsQ0FBTUMsR0FBTixFQUFXRixjQUFYLENBQVA7QUFBQSxlQUFoQjtBQUNBO0FBQUEsbUJBQU9OO0FBQVA7QUFKcUM7O0FBQUE7QUFLdEM7O0FBRUQ7QUFDQSxjQUFJQSxLQUFLSSxRQUFMLElBQWlCLENBQUNKLEtBQUtLLEVBQTNCLEVBQStCO0FBQzdCSSxvQkFBUUMsSUFBUixDQUFhVixJQUFiO0FBQ0Esa0JBQU0sSUFBSVcsS0FBSixDQUNKLDBFQURJLENBQU47QUFHRDs7QUFFRDtBQUNBLGNBQUksQ0FBQ1gsS0FBS0ksUUFBVixFQUFvQjtBQUNsQkosaUJBQUtJLFFBQUwsR0FBZ0I7QUFBQSxxQkFBS1EsU0FBTDtBQUFBLGFBQWhCO0FBQ0Q7O0FBRUQsaUJBQU9aLElBQVA7QUFDRCxTQTlDRDs7QUFnREE7QUFDQSxZQUFNYSxzQkFBc0IsU0FBdEJBLG1CQUFzQixDQUFDdkIsTUFBRCxFQUFTUyxZQUFULEVBQTBCO0FBQ3BELGNBQU1lLGtCQUFrQmhCLG9CQUFvQlIsTUFBcEIsRUFBNEJTLFlBQTVCLENBQXhCO0FBQ0FnQiw4QkFBb0JDLElBQXBCLENBQXlCRixlQUF6QjtBQUNBLGlCQUFPQSxlQUFQO0FBQ0QsU0FKRDtBQUtBLFlBQU1DLHNCQUFzQixFQUE1QjtBQUNBLFlBQU1FLG1CQUFtQjFCLG9CQUFvQjJCLEdBQXBCLENBQXdCLFVBQUM1QixNQUFELEVBQVM2QixDQUFULEVBQWU7QUFDOUQsY0FBSTdCLE9BQU9kLE9BQVgsRUFBb0I7QUFDbEIsZ0NBQ0tjLE1BREw7QUFFRWQsdUJBQVNjLE9BQU9kLE9BQVAsQ0FBZTBDLEdBQWYsQ0FBbUI7QUFBQSx1QkFBS0wsb0JBQW9CTyxDQUFwQixFQUF1QjlCLE1BQXZCLENBQUw7QUFBQSxlQUFuQjtBQUZYO0FBSUQsV0FMRCxNQUtPO0FBQ0wsbUJBQU91QixvQkFBb0J2QixNQUFwQixDQUFQO0FBQ0Q7QUFDRixTQVR3QixDQUF6Qjs7QUFXQTtBQUNBLFlBQUkrQixpQkFBaUJKLGlCQUFpQkssS0FBakIsRUFBckI7QUFDQSxZQUFJQyxvQkFBb0IsRUFBeEI7O0FBRUFGLHlCQUFpQkEsZUFBZUgsR0FBZixDQUFtQixVQUFDNUIsTUFBRCxFQUFTNkIsQ0FBVCxFQUFlO0FBQ2pELGNBQUk3QixPQUFPZCxPQUFYLEVBQW9CO0FBQ2xCLGdCQUFNZ0Qsb0JBQW9CbEMsT0FBT2QsT0FBUCxDQUFlaUQsTUFBZixDQUN4QjtBQUFBLHFCQUNFaEQsUUFBUWlELE9BQVIsQ0FBZ0JOLEVBQUVmLEVBQWxCLElBQXdCLENBQUMsQ0FBekIsR0FDSSxLQURKLEdBRUksZ0JBQUVzQixlQUFGLENBQWtCUCxFQUFFUSxJQUFwQixFQUEwQixJQUExQixDQUhOO0FBQUEsYUFEd0IsQ0FBMUI7QUFNQSxnQ0FDS3RDLE1BREw7QUFFRWQsdUJBQVNnRDtBQUZYO0FBSUQ7QUFDRCxpQkFBT2xDLE1BQVA7QUFDRCxTQWRnQixDQUFqQjs7QUFnQkErQix5QkFBaUJBLGVBQWVJLE1BQWYsQ0FBc0Isa0JBQVU7QUFDL0MsaUJBQU9uQyxPQUFPZCxPQUFQLEdBQ0hjLE9BQU9kLE9BQVAsQ0FBZXFELE1BRFosR0FFSHBELFFBQVFpRCxPQUFSLENBQWdCcEMsT0FBT2UsRUFBdkIsSUFBNkIsQ0FBQyxDQUE5QixHQUNFLEtBREYsR0FFRSxnQkFBRXNCLGVBQUYsQ0FBa0JyQyxPQUFPc0MsSUFBekIsRUFBK0IsSUFBL0IsQ0FKTjtBQUtELFNBTmdCLENBQWpCOztBQVFBO0FBQ0EsWUFBTUUsYUFBYVQsZUFBZVUsU0FBZixDQUF5QjtBQUFBLGlCQUFPckMsSUFBSXNDLEtBQVg7QUFBQSxTQUF6QixDQUFuQjs7QUFFQTtBQUNBLFlBQUl2RCxRQUFRb0QsTUFBWixFQUFvQjtBQUFBO0FBQ2xCO0FBQ0EsZ0JBQU1JLGVBQWUsRUFBckI7QUFDQXhELG9CQUFRWSxPQUFSLENBQWdCLG1CQUFXO0FBQ3pCLGtCQUFNNkMsUUFBUW5CLG9CQUFvQnRCLElBQXBCLENBQXlCO0FBQUEsdUJBQUsyQixFQUFFZixFQUFGLEtBQVM4QixPQUFkO0FBQUEsZUFBekIsQ0FBZDtBQUNBLGtCQUFJRCxLQUFKLEVBQVc7QUFDVEQsNkJBQWFqQixJQUFiLENBQWtCa0IsS0FBbEI7QUFDRDtBQUNGLGFBTEQ7O0FBT0EsZ0JBQUlFLG9CQUFvQkgsYUFBYUksTUFBYixDQUN0QixVQUFDQyxJQUFELEVBQU9DLE9BQVA7QUFBQSxxQkFDRUQsUUFBUUEsU0FBU0MsUUFBUXhDLFlBQXpCLElBQXlDd0MsUUFBUXhDLFlBRG5EO0FBQUEsYUFEc0IsRUFHdEJrQyxhQUFhLENBQWIsRUFBZ0JsQyxZQUhNLENBQXhCOztBQU1BLGdCQUFJeUMsbUJBQW1CcEQsbUJBQW1CZ0Qsa0JBQWtCSyxNQUE1RDtBQUNBRCwrQkFBbUJBLG9CQUFxQjtBQUFBLHFCQUFNO0FBQUE7QUFBQTtBQUFBO0FBQUEsZUFBTjtBQUFBLGFBQXhDOztBQUVBLGdCQUFJRSxtQkFBbUI7QUFDckJELHNCQUFRRCxnQkFEYTtBQUVyQmhFLHVCQUFTeUQsYUFBYWYsR0FBYixDQUFpQjtBQUFBLG9DQUNyQixPQUFLL0MsS0FBTCxDQUFXd0UsYUFEVSxFQUVyQmpELEdBRnFCO0FBR3hCa0QsMkJBQVM7QUFIZTtBQUFBLGVBQWpCO0FBRlksYUFBdkI7O0FBU0E7QUFDQSxnQkFBSWQsY0FBYyxDQUFsQixFQUFxQjtBQUNuQlksOENBQ0tyQixlQUFlUyxVQUFmLENBREwsRUFFS1ksZ0JBRkw7QUFJQXJCLDZCQUFld0IsTUFBZixDQUFzQmYsVUFBdEIsRUFBa0MsQ0FBbEMsRUFBcUNZLGdCQUFyQztBQUNELGFBTkQsTUFNTztBQUNMckIsNkJBQWV5QixPQUFmLENBQXVCSixnQkFBdkI7QUFDRDtBQXJDaUI7QUFzQ25COztBQUVEO0FBQ0EsWUFBTUssZUFBZSxFQUFyQjtBQUNBLFlBQUlDLGNBQWMsRUFBbEI7O0FBRUE7QUFDQSxZQUFNQyxZQUFZLFNBQVpBLFNBQVksQ0FBQ3pFLE9BQUQsRUFBVWMsTUFBVixFQUFxQjtBQUNyQ3lELHVCQUFhL0IsSUFBYixjQUNLLE9BQUs3QyxLQUFMLENBQVdtQixNQURoQixFQUVLQSxNQUZMO0FBR0VkLHFCQUFTQTtBQUhYO0FBS0F3RSx3QkFBYyxFQUFkO0FBQ0QsU0FQRDs7QUFTQTtBQUNBM0IsdUJBQWVoQyxPQUFmLENBQXVCLFVBQUNDLE1BQUQsRUFBUzZCLENBQVQsRUFBZTtBQUNwQyxjQUFJN0IsT0FBT2QsT0FBWCxFQUFvQjtBQUNsQitDLGdDQUFvQkEsa0JBQWtCMkIsTUFBbEIsQ0FBeUI1RCxPQUFPZCxPQUFoQyxDQUFwQjtBQUNBLGdCQUFJd0UsWUFBWW5CLE1BQVosR0FBcUIsQ0FBekIsRUFBNEI7QUFDMUJvQix3QkFBVUQsV0FBVjtBQUNEO0FBQ0RDLHNCQUFVM0QsT0FBT2QsT0FBakIsRUFBMEJjLE1BQTFCO0FBQ0E7QUFDRDtBQUNEaUMsNEJBQWtCUCxJQUFsQixDQUF1QjFCLE1BQXZCO0FBQ0EwRCxzQkFBWWhDLElBQVosQ0FBaUIxQixNQUFqQjtBQUNELFNBWEQ7QUFZQSxZQUFJRixtQkFBbUI0RCxZQUFZbkIsTUFBWixHQUFxQixDQUE1QyxFQUErQztBQUM3Q29CLG9CQUFVRCxXQUFWO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFNRyxZQUFZLFNBQVpBLFNBQVksQ0FBQy9CLENBQUQsRUFBSUQsQ0FBSixFQUFxQjtBQUFBOztBQUFBLGNBQWRpQyxLQUFjLHVFQUFOLENBQU07O0FBQ3JDLGNBQU01Qyx3Q0FDSHhCLFdBREcsRUFDV29DLENBRFgseUJBRUhuQyxRQUZHLEVBRVFrQyxDQUZSLHlCQUdIdEMsVUFIRyxFQUdVdUMsRUFBRXZDLFVBQUYsQ0FIVix5QkFJSEUsZUFKRyxFQUllcUUsS0FKZixRQUFOO0FBTUFyQyw4QkFBb0IxQixPQUFwQixDQUE0QixrQkFBVTtBQUNwQyxnQkFBSUMsT0FBT0ssUUFBWCxFQUFxQjtBQUNyQmEsZ0JBQUlsQixPQUFPZSxFQUFYLElBQWlCZixPQUFPYyxRQUFQLENBQWdCZ0IsQ0FBaEIsQ0FBakI7QUFDRCxXQUhEO0FBSUEsY0FBSVosSUFBSTNCLFVBQUosQ0FBSixFQUFxQjtBQUNuQjJCLGdCQUFJM0IsVUFBSixJQUFrQjJCLElBQUkzQixVQUFKLEVBQWdCcUMsR0FBaEIsQ0FBb0IsVUFBQ0UsQ0FBRCxFQUFJRCxDQUFKO0FBQUEscUJBQ3BDZ0MsVUFBVS9CLENBQVYsRUFBYUQsQ0FBYixFQUFnQmlDLFFBQVEsQ0FBeEIsQ0FEb0M7QUFBQSxhQUFwQixDQUFsQjtBQUdEO0FBQ0QsaUJBQU81QyxHQUFQO0FBQ0QsU0FqQkQ7QUFrQkEsWUFBSTZDLGVBQWUzRSxLQUFLd0MsR0FBTCxDQUFTLFVBQUNFLENBQUQsRUFBSUQsQ0FBSjtBQUFBLGlCQUFVZ0MsVUFBVS9CLENBQVYsRUFBYUQsQ0FBYixDQUFWO0FBQUEsU0FBVCxDQUFuQjs7QUFFQTtBQUNBLFlBQU1tQyxZQUFZLFNBQVpBLFNBQVksT0FBUTtBQUN4QixjQUFNQyxvQkFBb0IsRUFBMUI7QUFDQUMsNkJBQW1CbkUsT0FBbkIsQ0FBMkIsa0JBQVU7QUFDbkMsZ0JBQU1vRSxTQUFTQyxLQUFLeEMsR0FBTCxDQUFTO0FBQUEscUJBQUtFLEVBQUU5QixPQUFPZSxFQUFULENBQUw7QUFBQSxhQUFULENBQWY7QUFDQWtELDhCQUFrQmpFLE9BQU9lLEVBQXpCLElBQStCZixPQUFPZ0UsU0FBUCxDQUFpQkcsTUFBakIsRUFBeUJDLElBQXpCLENBQS9CO0FBQ0QsV0FIRDtBQUlBLGlCQUFPSCxpQkFBUDtBQUNELFNBUEQ7O0FBU0E7QUFDQSxZQUFNQyxxQkFBcUJqQyxrQkFBa0JFLE1BQWxCLENBQ3pCO0FBQUEsaUJBQUssQ0FBQ0wsRUFBRXpCLFFBQUgsSUFBZXlCLEVBQUVrQyxTQUF0QjtBQUFBLFNBRHlCLENBQTNCO0FBR0EsWUFBSTdFLFFBQVFvRCxNQUFaLEVBQW9CO0FBQUE7QUFDbEIsZ0JBQU04QixtQkFBbUIsU0FBbkJBLGdCQUFtQixDQUFDRCxJQUFELEVBQU9FLElBQVAsRUFBdUI7QUFBQSxrQkFBVnpDLENBQVUsdUVBQU4sQ0FBTTs7QUFDOUM7QUFDQSxrQkFBSUEsTUFBTXlDLEtBQUsvQixNQUFmLEVBQXVCO0FBQ3JCLHVCQUFPNkIsSUFBUDtBQUNEO0FBQ0Q7QUFDQSxrQkFBSUcsY0FBY0MsT0FBT0MsT0FBUCxDQUNoQixnQkFBRUMsT0FBRixDQUFVTixJQUFWLEVBQWdCRSxLQUFLekMsQ0FBTCxDQUFoQixDQURnQixFQUVoQkQsR0FGZ0IsQ0FFWixnQkFBa0I7QUFBQTs7QUFBQTtBQUFBLG9CQUFoQitDLEdBQWdCO0FBQUEsb0JBQVhDLEtBQVc7O0FBQ3RCLDBEQUNHdkYsVUFESCxFQUNnQmlGLEtBQUt6QyxDQUFMLENBRGhCLDBCQUVHdkMsV0FGSCxFQUVpQnFGLEdBRmpCLDBCQUdHTCxLQUFLekMsQ0FBTCxDQUhILEVBR2E4QyxHQUhiLDBCQUlHcEYsVUFKSCxFQUlnQnFGLEtBSmhCLDBCQUtHbkYsZUFMSCxFQUtxQm9DLENBTHJCLDBCQU1HakMsaUJBTkgsRUFNdUIsSUFOdkI7QUFRRCxlQVhpQixDQUFsQjtBQVlBO0FBQ0EyRSw0QkFBY0EsWUFBWTNDLEdBQVosQ0FBZ0Isb0JBQVk7QUFBQTs7QUFDeEMsb0JBQUlpRCxVQUFVUixpQkFBaUJTLFNBQVN2RixVQUFULENBQWpCLEVBQXVDK0UsSUFBdkMsRUFBNkN6QyxJQUFJLENBQWpELENBQWQ7QUFDQSxvQ0FDS2lELFFBREwsOENBRUd2RixVQUZILEVBRWdCc0YsT0FGaEIsOEJBR0dyRixhQUhILEVBR21CLElBSG5CLGVBSUt3RSxVQUFVYSxPQUFWLENBSkw7QUFNRCxlQVJhLENBQWQ7QUFTQSxxQkFBT04sV0FBUDtBQUNELGFBN0JEO0FBOEJBUiwyQkFBZU0saUJBQWlCTixZQUFqQixFQUErQjVFLE9BQS9CLENBQWY7QUEvQmtCO0FBZ0NuQjs7QUFFRCw0QkFDS0YsUUFETDtBQUVFOEUsb0NBRkY7QUFHRTlCLDhDQUhGO0FBSUV3QixvQ0FKRjtBQUtFaEMsa0RBTEY7QUFNRTNCO0FBTkY7QUFRRDtBQTVTVTtBQUFBO0FBQUEsb0NBOFNJZixhQTlTSixFQThTbUI7QUFBQSxZQUUxQmdHLE1BRjBCLEdBU3hCaEcsYUFUd0IsQ0FFMUJnRyxNQUYwQjtBQUFBLFlBRzFCQyxNQUgwQixHQVN4QmpHLGFBVHdCLENBRzFCaUcsTUFIMEI7QUFBQSxZQUkxQkMsUUFKMEIsR0FTeEJsRyxhQVR3QixDQUkxQmtHLFFBSjBCO0FBQUEsWUFLMUJDLG1CQUwwQixHQVN4Qm5HLGFBVHdCLENBSzFCbUcsbUJBTDBCO0FBQUEsWUFNMUJuQixZQU4wQixHQVN4QmhGLGFBVHdCLENBTTFCZ0YsWUFOMEI7QUFBQSxZQU8xQjlCLGlCQVAwQixHQVN4QmxELGFBVHdCLENBTzFCa0QsaUJBUDBCO0FBQUEsWUFRMUJSLG1CQVIwQixHQVN4QjFDLGFBVHdCLENBUTFCMEMsbUJBUjBCOzs7QUFXNUIsWUFBTTBELHdCQUF3QixFQUE5Qjs7QUFFQTFELDRCQUFvQlUsTUFBcEIsQ0FBMkI7QUFBQSxpQkFBTy9CLElBQUlnRixVQUFYO0FBQUEsU0FBM0IsRUFBa0RyRixPQUFsRCxDQUEwRCxlQUFPO0FBQy9Eb0YsZ0NBQXNCL0UsSUFBSVcsRUFBMUIsSUFBZ0NYLElBQUlnRixVQUFwQztBQUNELFNBRkQ7O0FBSUE7QUFDQSxlQUFPO0FBQ0xDLHNCQUFZTixTQUNSaEIsWUFEUSxHQUVSLEtBQUt1QixRQUFMLENBQ0EsS0FBS0MsVUFBTCxDQUNFeEIsWUFERixFQUVFa0IsUUFGRixFQUdFQyxtQkFIRixFQUlFakQsaUJBSkYsQ0FEQSxFQU9BK0MsTUFQQSxFQVFBRyxxQkFSQTtBQUhDLFNBQVA7QUFjRDtBQTlVVTtBQUFBO0FBQUEsc0NBZ1ZNO0FBQ2YsYUFBS3RHLEtBQUwsQ0FBVzJHLFdBQVgsQ0FBdUIsS0FBS0MsZ0JBQUwsRUFBdkIsRUFBZ0QsSUFBaEQ7QUFDRDtBQWxWVTtBQUFBO0FBQUEscUNBb1ZLZCxHQXBWTCxFQW9WVTtBQUNuQixlQUFPLGdCQUFFdEMsZUFBRixDQUFrQixLQUFLeEQsS0FBTCxDQUFXOEYsR0FBWCxDQUFsQixFQUFtQyxLQUFLN0YsS0FBTCxDQUFXNkYsR0FBWCxDQUFuQyxDQUFQO0FBQ0Q7QUF0VlU7QUFBQTtBQUFBLHFDQXdWS0EsR0F4VkwsRUF3VlU7QUFDbkIsZUFBTyxnQkFBRXRDLGVBQUYsQ0FBa0IsS0FBS3ZELEtBQUwsQ0FBVzZGLEdBQVgsQ0FBbEIsRUFBbUMsS0FBSzlGLEtBQUwsQ0FBVzhGLEdBQVgsQ0FBbkMsQ0FBUDtBQUNEO0FBMVZVO0FBQUE7QUFBQSxpQ0E0VkN2RixJQTVWRCxFQTRWTzZGLFFBNVZQLEVBNFZpQkMsbUJBNVZqQixFQTRWc0NqRCxpQkE1VnRDLEVBNFZ5RDtBQUFBOztBQUNsRSxZQUFJeUQsZUFBZXRHLElBQW5COztBQUVBLFlBQUk2RixTQUFTMUMsTUFBYixFQUFxQjtBQUNuQm1ELHlCQUFlVCxTQUFTbEMsTUFBVCxDQUFnQixVQUFDNEMsYUFBRCxFQUFnQkMsVUFBaEIsRUFBK0I7QUFDNUQsZ0JBQU01RixTQUFTaUMsa0JBQWtCOUIsSUFBbEIsQ0FBdUI7QUFBQSxxQkFBSzBGLEVBQUU5RSxFQUFGLEtBQVM2RSxXQUFXN0UsRUFBekI7QUFBQSxhQUF2QixDQUFmOztBQUVBO0FBQ0EsZ0JBQUksQ0FBQ2YsTUFBRCxJQUFXQSxPQUFPOEYsVUFBUCxLQUFzQixLQUFyQyxFQUE0QztBQUMxQyxxQkFBT0gsYUFBUDtBQUNEOztBQUVELGdCQUFNSSxlQUFlL0YsT0FBTytGLFlBQVAsSUFBdUJiLG1CQUE1Qzs7QUFFQTtBQUNBLGdCQUFJbEYsT0FBT2dHLFNBQVgsRUFBc0I7QUFDcEIscUJBQU9ELGFBQWFILFVBQWIsRUFBeUJELGFBQXpCLEVBQXdDM0YsTUFBeEMsQ0FBUDtBQUNELGFBRkQsTUFFTztBQUNMLHFCQUFPMkYsY0FBY3hELE1BQWQsQ0FBcUIsZUFBTztBQUNqQyx1QkFBTzRELGFBQWFILFVBQWIsRUFBeUIxRSxHQUF6QixFQUE4QmxCLE1BQTlCLENBQVA7QUFDRCxlQUZNLENBQVA7QUFHRDtBQUNGLFdBbEJjLEVBa0JaMEYsWUFsQlksQ0FBZjs7QUFvQkE7QUFDQTtBQUNBQSx5QkFBZUEsYUFDWjlELEdBRFksQ0FDUixlQUFPO0FBQ1YsZ0JBQUksQ0FBQ1YsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBQUwsRUFBaUM7QUFDL0IscUJBQU8yQixHQUFQO0FBQ0Q7QUFDRCxnQ0FDS0EsR0FETCxzQkFFRyxPQUFLckMsS0FBTCxDQUFXVSxVQUZkLEVBRTJCLE9BQUtnRyxVQUFMLENBQ3ZCckUsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBRHVCLEVBRXZCMEYsUUFGdUIsRUFHdkJDLG1CQUh1QixFQUl2QmpELGlCQUp1QixDQUYzQjtBQVNELFdBZFksRUFlWkUsTUFmWSxDQWVMLGVBQU87QUFDYixnQkFBSSxDQUFDakIsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBQUwsRUFBaUM7QUFDL0IscUJBQU8sSUFBUDtBQUNEO0FBQ0QsbUJBQU8yQixJQUFJLE9BQUtyQyxLQUFMLENBQVdVLFVBQWYsRUFBMkJnRCxNQUEzQixHQUFvQyxDQUEzQztBQUNELFdBcEJZLENBQWY7QUFxQkQ7O0FBRUQsZUFBT21ELFlBQVA7QUFDRDtBQTlZVTtBQUFBO0FBQUEsK0JBZ1pEdEcsSUFoWkMsRUFnWks0RixNQWhaTCxFQWdaeUM7QUFBQTs7QUFBQSxZQUE1QkcscUJBQTRCLHVFQUFKLEVBQUk7O0FBQ2xELFlBQUksQ0FBQ0gsT0FBT3pDLE1BQVosRUFBb0I7QUFDbEIsaUJBQU9uRCxJQUFQO0FBQ0Q7O0FBRUQsWUFBTWlHLGFBQWEsQ0FBQyxLQUFLeEcsS0FBTCxDQUFXb0gsYUFBWCxJQUE0QixnQkFBRUMsT0FBL0IsRUFDakI5RyxJQURpQixFQUVqQjRGLE9BQU9wRCxHQUFQLENBQVcsZ0JBQVE7QUFDakI7QUFDQSxjQUFJdUQsc0JBQXNCZ0IsS0FBS3BGLEVBQTNCLENBQUosRUFBb0M7QUFDbEMsbUJBQU8sVUFBQ3FGLENBQUQsRUFBSUMsQ0FBSixFQUFVO0FBQ2YscUJBQU9sQixzQkFBc0JnQixLQUFLcEYsRUFBM0IsRUFBK0JxRixFQUFFRCxLQUFLcEYsRUFBUCxDQUEvQixFQUEyQ3NGLEVBQUVGLEtBQUtwRixFQUFQLENBQTNDLENBQVA7QUFDRCxhQUZEO0FBR0Q7QUFDRCxpQkFBTyxVQUFDcUYsQ0FBRCxFQUFJQyxDQUFKLEVBQVU7QUFDZixtQkFBTyxPQUFLeEgsS0FBTCxDQUFXeUgsaUJBQVgsQ0FBNkJGLEVBQUVELEtBQUtwRixFQUFQLENBQTdCLEVBQXlDc0YsRUFBRUYsS0FBS3BGLEVBQVAsQ0FBekMsQ0FBUDtBQUNELFdBRkQ7QUFHRCxTQVZELENBRmlCLEVBYWpCaUUsT0FBT3BELEdBQVAsQ0FBVztBQUFBLGlCQUFLLENBQUNFLEVBQUV5RSxJQUFSO0FBQUEsU0FBWCxDQWJpQixFQWNqQixLQUFLMUgsS0FBTCxDQUFXYyxRQWRNLENBQW5COztBQWlCQTBGLG1CQUFXdEYsT0FBWCxDQUFtQixlQUFPO0FBQ3hCLGNBQUksQ0FBQ21CLElBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixDQUFMLEVBQWlDO0FBQy9CO0FBQ0Q7QUFDRDJCLGNBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixJQUE2QixPQUFLK0YsUUFBTCxDQUMzQnBFLElBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixDQUQyQixFQUUzQnlGLE1BRjJCLEVBRzNCRyxxQkFIMkIsQ0FBN0I7QUFLRCxTQVREOztBQVdBLGVBQU9FLFVBQVA7QUFDRDtBQWxiVTtBQUFBO0FBQUEsbUNBb2JHO0FBQ1osZUFBTyxnQkFBRWhELGVBQUYsQ0FDTCxLQUFLeEQsS0FBTCxDQUFXMkgsT0FETixFQUVMLEtBQUtDLGNBQUwsQ0FBb0IsVUFBcEIsQ0FGSyxDQUFQO0FBSUQ7O0FBRUQ7O0FBM2JXO0FBQUE7QUFBQSxtQ0E0YkdDLElBNWJILEVBNGJTO0FBQUEscUJBQzZCLEtBQUs3SCxLQURsQztBQUFBLFlBQ1Y4SCxZQURVLFVBQ1ZBLFlBRFU7QUFBQSxZQUNJQyxvQkFESixVQUNJQSxvQkFESjs7O0FBR2xCLFlBQU0zSCxXQUFXLEVBQUV5SCxVQUFGLEVBQWpCO0FBQ0EsWUFBSUUsb0JBQUosRUFBMEI7QUFDeEIzSCxtQkFBUzRILFFBQVQsR0FBb0IsRUFBcEI7QUFDRDtBQUNELGFBQUtDLGdCQUFMLENBQXNCN0gsUUFBdEIsRUFBZ0MsWUFBTTtBQUNwQzBILDBCQUFnQkEsYUFBYUQsSUFBYixDQUFoQjtBQUNELFNBRkQ7QUFHRDtBQXRjVTtBQUFBO0FBQUEsdUNBd2NPSyxXQXhjUCxFQXdjb0I7QUFBQSxZQUNyQkMsZ0JBRHFCLEdBQ0EsS0FBS25JLEtBREwsQ0FDckJtSSxnQkFEcUI7O0FBQUEsZ0NBRUYsS0FBS3ZCLGdCQUFMLEVBRkU7QUFBQSxZQUVyQndCLFFBRnFCLHFCQUVyQkEsUUFGcUI7QUFBQSxZQUVYUCxJQUZXLHFCQUVYQSxJQUZXOztBQUk3Qjs7O0FBQ0EsWUFBTVEsYUFBYUQsV0FBV1AsSUFBOUI7QUFDQSxZQUFNUyxVQUFVQyxLQUFLQyxLQUFMLENBQVdILGFBQWFILFdBQXhCLENBQWhCOztBQUVBLGFBQUtELGdCQUFMLENBQ0U7QUFDRUcsb0JBQVVGLFdBRFo7QUFFRUwsZ0JBQU1TO0FBRlIsU0FERixFQUtFLFlBQU07QUFDSkgsOEJBQW9CQSxpQkFBaUJELFdBQWpCLEVBQThCSSxPQUE5QixDQUFwQjtBQUNELFNBUEg7QUFTRDtBQXpkVTtBQUFBO0FBQUEsaUNBMmRDbkgsTUEzZEQsRUEyZFNzSCxRQTNkVCxFQTJkbUI7QUFBQSxpQ0FDc0IsS0FBSzdCLGdCQUFMLEVBRHRCO0FBQUEsWUFDcEJULE1BRG9CLHNCQUNwQkEsTUFEb0I7QUFBQSxZQUNadUMsWUFEWSxzQkFDWkEsWUFEWTtBQUFBLFlBQ0VDLGVBREYsc0JBQ0VBLGVBREY7O0FBRzVCLFlBQU1DLHFCQUFxQnpILE9BQU8wSCxjQUFQLENBQXNCLGlCQUF0QixJQUN2QjFILE9BQU93SCxlQURnQixHQUV2QkEsZUFGSjtBQUdBLFlBQU1HLHNCQUFzQixDQUFDRixrQkFBN0I7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7QUFDQSxZQUFJRixZQUFKLEVBQWtCO0FBQ2hCLGVBQUtULGdCQUFMLENBQXNCO0FBQ3BCUywwQkFBYztBQURNLFdBQXRCO0FBR0E7QUFDRDs7QUFqQjJCLFlBbUJwQkssY0FuQm9CLEdBbUJELEtBQUsvSSxLQW5CSixDQW1CcEIrSSxjQW5Cb0I7OztBQXFCNUIsWUFBSUMsWUFBWSxnQkFBRUMsS0FBRixDQUFROUMsVUFBVSxFQUFsQixFQUFzQnBELEdBQXRCLENBQTBCLGFBQUs7QUFDN0NFLFlBQUV5RSxJQUFGLEdBQVMsZ0JBQUV3QixhQUFGLENBQWdCakcsQ0FBaEIsQ0FBVDtBQUNBLGlCQUFPQSxDQUFQO0FBQ0QsU0FIZSxDQUFoQjtBQUlBLFlBQUksQ0FBQyxnQkFBRWtHLE9BQUYsQ0FBVWhJLE1BQVYsQ0FBTCxFQUF3QjtBQUN0QjtBQUNBLGNBQU1pSSxnQkFBZ0JKLFVBQVVwRixTQUFWLENBQW9CO0FBQUEsbUJBQUtYLEVBQUVmLEVBQUYsS0FBU2YsT0FBT2UsRUFBckI7QUFBQSxXQUFwQixDQUF0QjtBQUNBLGNBQUlrSCxnQkFBZ0IsQ0FBQyxDQUFyQixFQUF3QjtBQUN0QixnQkFBTUMsV0FBV0wsVUFBVUksYUFBVixDQUFqQjtBQUNBLGdCQUFJQyxTQUFTM0IsSUFBVCxLQUFrQm9CLG1CQUF0QixFQUEyQztBQUN6QyxrQkFBSUwsUUFBSixFQUFjO0FBQ1pPLDBCQUFVdEUsTUFBVixDQUFpQjBFLGFBQWpCLEVBQWdDLENBQWhDO0FBQ0QsZUFGRCxNQUVPO0FBQ0xDLHlCQUFTM0IsSUFBVCxHQUFnQmtCLGtCQUFoQjtBQUNBSSw0QkFBWSxDQUFDSyxRQUFELENBQVo7QUFDRDtBQUNGLGFBUEQsTUFPTztBQUNMQSx1QkFBUzNCLElBQVQsR0FBZ0JvQixtQkFBaEI7QUFDQSxrQkFBSSxDQUFDTCxRQUFMLEVBQWU7QUFDYk8sNEJBQVksQ0FBQ0ssUUFBRCxDQUFaO0FBQ0Q7QUFDRjtBQUNGLFdBZkQsTUFlTztBQUNMLGdCQUFJWixRQUFKLEVBQWM7QUFDWk8sd0JBQVVuRyxJQUFWLENBQWU7QUFDYlgsb0JBQUlmLE9BQU9lLEVBREU7QUFFYndGLHNCQUFNa0I7QUFGTyxlQUFmO0FBSUQsYUFMRCxNQUtPO0FBQ0xJLDBCQUFZLENBQ1Y7QUFDRTlHLG9CQUFJZixPQUFPZSxFQURiO0FBRUV3RixzQkFBTWtCO0FBRlIsZUFEVSxDQUFaO0FBTUQ7QUFDRjtBQUNGLFNBakNELE1BaUNPO0FBQUE7QUFDTDtBQUNBLGdCQUFNUSxnQkFBZ0JKLFVBQVVwRixTQUFWLENBQW9CO0FBQUEscUJBQUtYLEVBQUVmLEVBQUYsS0FBU2YsT0FBTyxDQUFQLEVBQVVlLEVBQXhCO0FBQUEsYUFBcEIsQ0FBdEI7QUFDQTtBQUNBLGdCQUFJa0gsZ0JBQWdCLENBQUMsQ0FBckIsRUFBd0I7QUFDdEIsa0JBQU1DLFlBQVdMLFVBQVVJLGFBQVYsQ0FBakI7QUFDQSxrQkFBSUMsVUFBUzNCLElBQVQsS0FBa0JvQixtQkFBdEIsRUFBMkM7QUFDekMsb0JBQUlMLFFBQUosRUFBYztBQUNaTyw0QkFBVXRFLE1BQVYsQ0FBaUIwRSxhQUFqQixFQUFnQ2pJLE9BQU91QyxNQUF2QztBQUNELGlCQUZELE1BRU87QUFDTHZDLHlCQUFPRCxPQUFQLENBQWUsVUFBQytCLENBQUQsRUFBSUQsQ0FBSixFQUFVO0FBQ3ZCZ0csOEJBQVVJLGdCQUFnQnBHLENBQTFCLEVBQTZCMEUsSUFBN0IsR0FBb0NrQixrQkFBcEM7QUFDRCxtQkFGRDtBQUdEO0FBQ0YsZUFSRCxNQVFPO0FBQ0x6SCx1QkFBT0QsT0FBUCxDQUFlLFVBQUMrQixDQUFELEVBQUlELENBQUosRUFBVTtBQUN2QmdHLDRCQUFVSSxnQkFBZ0JwRyxDQUExQixFQUE2QjBFLElBQTdCLEdBQW9Db0IsbUJBQXBDO0FBQ0QsaUJBRkQ7QUFHRDtBQUNELGtCQUFJLENBQUNMLFFBQUwsRUFBZTtBQUNiTyw0QkFBWUEsVUFBVTdGLEtBQVYsQ0FBZ0JpRyxhQUFoQixFQUErQmpJLE9BQU91QyxNQUF0QyxDQUFaO0FBQ0Q7QUFDRixhQWxCRCxNQWtCTztBQUNMO0FBQ0Esa0JBQUkrRSxRQUFKLEVBQWM7QUFDWk8sNEJBQVlBLFVBQVVqRSxNQUFWLENBQ1Y1RCxPQUFPNEIsR0FBUCxDQUFXO0FBQUEseUJBQU07QUFDZmIsd0JBQUllLEVBQUVmLEVBRFM7QUFFZndGLDBCQUFNa0I7QUFGUyxtQkFBTjtBQUFBLGlCQUFYLENBRFUsQ0FBWjtBQU1ELGVBUEQsTUFPTztBQUNMSSw0QkFBWTdILE9BQU80QixHQUFQLENBQVc7QUFBQSx5QkFBTTtBQUMzQmIsd0JBQUllLEVBQUVmLEVBRHFCO0FBRTNCd0YsMEJBQU1rQjtBQUZxQixtQkFBTjtBQUFBLGlCQUFYLENBQVo7QUFJRDtBQUNGO0FBckNJO0FBc0NOOztBQUVELGFBQUtYLGdCQUFMLENBQ0U7QUFDRUosZ0JBQ0csQ0FBQzFCLE9BQU96QyxNQUFSLElBQWtCc0YsVUFBVXRGLE1BQTdCLElBQXdDLENBQUMrRSxRQUF6QyxHQUNJLENBREosR0FFSSxLQUFLeEksS0FBTCxDQUFXNEgsSUFKbkI7QUFLRTFCLGtCQUFRNkM7QUFMVixTQURGLEVBUUUsWUFBTTtBQUNKRCw0QkFBa0JBLGVBQWVDLFNBQWYsRUFBMEI3SCxNQUExQixFQUFrQ3NILFFBQWxDLENBQWxCO0FBQ0QsU0FWSDtBQVlEO0FBemtCVTtBQUFBO0FBQUEsbUNBMmtCR3RILE1BM2tCSCxFQTJrQlc0RSxLQTNrQlgsRUEya0JrQjtBQUFBLGlDQUNOLEtBQUthLGdCQUFMLEVBRE07QUFBQSxZQUNuQlIsUUFEbUIsc0JBQ25CQSxRQURtQjs7QUFBQSxZQUVuQmtELGdCQUZtQixHQUVFLEtBQUt0SixLQUZQLENBRW5Cc0osZ0JBRm1COztBQUkzQjs7QUFDQSxZQUFNQyxlQUFlLENBQUNuRCxZQUFZLEVBQWIsRUFBaUI5QyxNQUFqQixDQUF3QixhQUFLO0FBQ2hELGNBQUkwRCxFQUFFOUUsRUFBRixLQUFTZixPQUFPZSxFQUFwQixFQUF3QjtBQUN0QixtQkFBTyxJQUFQO0FBQ0Q7QUFDRixTQUpvQixDQUFyQjs7QUFNQSxZQUFJNkQsVUFBVSxFQUFkLEVBQWtCO0FBQ2hCd0QsdUJBQWExRyxJQUFiLENBQWtCO0FBQ2hCWCxnQkFBSWYsT0FBT2UsRUFESztBQUVoQjZELG1CQUFPQTtBQUZTLFdBQWxCO0FBSUQ7O0FBRUQsYUFBS2tDLGdCQUFMLENBQ0U7QUFDRTdCLG9CQUFVbUQ7QUFEWixTQURGLEVBSUUsWUFBTTtBQUNKRCw4QkFBb0JBLGlCQUFpQkMsWUFBakIsRUFBK0JwSSxNQUEvQixFQUF1QzRFLEtBQXZDLENBQXBCO0FBQ0QsU0FOSDtBQVFEO0FBcm1CVTtBQUFBO0FBQUEsd0NBdW1CUXlELEtBdm1CUixFQXVtQmVySSxNQXZtQmYsRUF1bUJ1QnNJLE9Bdm1CdkIsRUF1bUJnQztBQUFBOztBQUN6Q0QsY0FBTUUsZUFBTjtBQUNBLFlBQU1DLGNBQWNILE1BQU1JLE1BQU4sQ0FBYUMsYUFBYixDQUEyQkMscUJBQTNCLEdBQ2pCQyxLQURIOztBQUdBLFlBQUlDLGNBQUo7QUFDQSxZQUFJUCxPQUFKLEVBQWE7QUFDWE8sa0JBQVFSLE1BQU1TLGNBQU4sQ0FBcUIsQ0FBckIsRUFBd0JELEtBQWhDO0FBQ0QsU0FGRCxNQUVPO0FBQ0xBLGtCQUFRUixNQUFNUSxLQUFkO0FBQ0Q7O0FBRUQsYUFBS0UsVUFBTCxHQUFrQixJQUFsQjtBQUNBLGFBQUtqQyxnQkFBTCxDQUNFO0FBQ0VrQyw2QkFBbUI7QUFDakJqSSxnQkFBSWYsT0FBT2UsRUFETTtBQUVqQmtJLG9CQUFRSixLQUZTO0FBR2pCTCx5QkFBYUE7QUFISTtBQURyQixTQURGLEVBUUUsWUFBTTtBQUNKLGNBQUlGLE9BQUosRUFBYTtBQUNYWSxxQkFBU0MsZ0JBQVQsQ0FBMEIsV0FBMUIsRUFBdUMsT0FBS0Msa0JBQTVDO0FBQ0FGLHFCQUFTQyxnQkFBVCxDQUEwQixhQUExQixFQUF5QyxPQUFLRSxlQUE5QztBQUNBSCxxQkFBU0MsZ0JBQVQsQ0FBMEIsVUFBMUIsRUFBc0MsT0FBS0UsZUFBM0M7QUFDRCxXQUpELE1BSU87QUFDTEgscUJBQVNDLGdCQUFULENBQTBCLFdBQTFCLEVBQXVDLE9BQUtDLGtCQUE1QztBQUNBRixxQkFBU0MsZ0JBQVQsQ0FBMEIsU0FBMUIsRUFBcUMsT0FBS0UsZUFBMUM7QUFDQUgscUJBQVNDLGdCQUFULENBQTBCLFlBQTFCLEVBQXdDLE9BQUtFLGVBQTdDO0FBQ0Q7QUFDRixTQWxCSDtBQW9CRDtBQXhvQlU7QUFBQTtBQUFBLHlDQTBvQlNoQixLQTFvQlQsRUEwb0JnQjtBQUN6QkEsY0FBTUUsZUFBTjtBQUR5QixZQUVqQmUsZUFGaUIsR0FFRyxLQUFLekssS0FGUixDQUVqQnlLLGVBRmlCOztBQUFBLGlDQUdjLEtBQUs3RCxnQkFBTCxFQUhkO0FBQUEsWUFHakI4RCxPQUhpQixzQkFHakJBLE9BSGlCO0FBQUEsWUFHUlAsaUJBSFEsc0JBR1JBLGlCQUhROztBQUt6Qjs7O0FBQ0EsWUFBTVEsYUFBYUQsUUFBUXBILE1BQVIsQ0FBZTtBQUFBLGlCQUFLMEQsRUFBRTlFLEVBQUYsS0FBU2lJLGtCQUFrQmpJLEVBQWhDO0FBQUEsU0FBZixDQUFuQjs7QUFFQSxZQUFJOEgsY0FBSjs7QUFFQSxZQUFJUixNQUFNb0IsSUFBTixLQUFlLFdBQW5CLEVBQWdDO0FBQzlCWixrQkFBUVIsTUFBTVMsY0FBTixDQUFxQixDQUFyQixFQUF3QkQsS0FBaEM7QUFDRCxTQUZELE1BRU8sSUFBSVIsTUFBTW9CLElBQU4sS0FBZSxXQUFuQixFQUFnQztBQUNyQ1osa0JBQVFSLE1BQU1RLEtBQWQ7QUFDRDs7QUFFRDtBQUNBLFlBQU1hLFdBQVd0QyxLQUFLdUMsR0FBTCxDQUNmWCxrQkFBa0JSLFdBQWxCLEdBQWdDSyxLQUFoQyxHQUF3Q0csa0JBQWtCQyxNQUQzQyxFQUVmLEVBRmUsQ0FBakI7O0FBS0FPLG1CQUFXOUgsSUFBWCxDQUFnQjtBQUNkWCxjQUFJaUksa0JBQWtCakksRUFEUjtBQUVkNkQsaUJBQU84RTtBQUZPLFNBQWhCOztBQUtBLGFBQUs1QyxnQkFBTCxDQUNFO0FBQ0V5QyxtQkFBU0M7QUFEWCxTQURGLEVBSUUsWUFBTTtBQUNKRiw2QkFBbUJBLGdCQUFnQkUsVUFBaEIsRUFBNEJuQixLQUE1QixDQUFuQjtBQUNELFNBTkg7QUFRRDtBQTdxQlU7QUFBQTtBQUFBLHNDQStxQk1BLEtBL3FCTixFQStxQmE7QUFDdEJBLGNBQU1FLGVBQU47QUFDQSxZQUFJRCxVQUFVRCxNQUFNb0IsSUFBTixLQUFlLFVBQWYsSUFBNkJwQixNQUFNb0IsSUFBTixLQUFlLGFBQTFEOztBQUVBLFlBQUluQixPQUFKLEVBQWE7QUFDWFksbUJBQVNVLG1CQUFULENBQTZCLFdBQTdCLEVBQTBDLEtBQUtSLGtCQUEvQztBQUNBRixtQkFBU1UsbUJBQVQsQ0FBNkIsYUFBN0IsRUFBNEMsS0FBS1AsZUFBakQ7QUFDQUgsbUJBQVNVLG1CQUFULENBQTZCLFVBQTdCLEVBQXlDLEtBQUtQLGVBQTlDO0FBQ0Q7O0FBRUQ7QUFDQTtBQUNBSCxpQkFBU1UsbUJBQVQsQ0FBNkIsV0FBN0IsRUFBMEMsS0FBS1Isa0JBQS9DO0FBQ0FGLGlCQUFTVSxtQkFBVCxDQUE2QixTQUE3QixFQUF3QyxLQUFLUCxlQUE3QztBQUNBSCxpQkFBU1UsbUJBQVQsQ0FBNkIsWUFBN0IsRUFBMkMsS0FBS1AsZUFBaEQ7O0FBRUE7QUFDQTtBQUNBO0FBQ0EsWUFBSSxDQUFDZixPQUFMLEVBQWM7QUFDWixlQUFLeEIsZ0JBQUwsQ0FBc0I7QUFDcEJTLDBCQUFjLElBRE07QUFFcEJ5QiwrQkFBbUI7QUFGQyxXQUF0QjtBQUlEO0FBQ0Y7QUF4c0JVOztBQUFBO0FBQUEsSUFDQ2EsSUFERDtBQUFBLEMiLCJmaWxlIjoibWV0aG9kcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBSZWFjdCBmcm9tICdyZWFjdCdcbmltcG9ydCBfIGZyb20gJy4vdXRpbHMnXG5cbmV4cG9ydCBkZWZhdWx0IEJhc2UgPT5cbiAgY2xhc3MgZXh0ZW5kcyBCYXNlIHtcbiAgICBnZXRSZXNvbHZlZFN0YXRlIChwcm9wcywgc3RhdGUpIHtcbiAgICAgIGNvbnN0IHJlc29sdmVkU3RhdGUgPSB7XG4gICAgICAgIC4uLl8uY29tcGFjdE9iamVjdCh0aGlzLnN0YXRlKSxcbiAgICAgICAgLi4uXy5jb21wYWN0T2JqZWN0KHRoaXMucHJvcHMpLFxuICAgICAgICAuLi5fLmNvbXBhY3RPYmplY3Qoc3RhdGUpLFxuICAgICAgICAuLi5fLmNvbXBhY3RPYmplY3QocHJvcHMpLFxuICAgICAgfVxuICAgICAgcmV0dXJuIHJlc29sdmVkU3RhdGVcbiAgICB9XG5cbiAgICBnZXREYXRhTW9kZWwgKG5ld1N0YXRlKSB7XG4gICAgICBjb25zdCB7XG4gICAgICAgIGNvbHVtbnMsXG4gICAgICAgIHBpdm90QnkgPSBbXSxcbiAgICAgICAgZGF0YSxcbiAgICAgICAgcGl2b3RJREtleSxcbiAgICAgICAgcGl2b3RWYWxLZXksXG4gICAgICAgIHN1YlJvd3NLZXksXG4gICAgICAgIGFnZ3JlZ2F0ZWRLZXksXG4gICAgICAgIG5lc3RpbmdMZXZlbEtleSxcbiAgICAgICAgb3JpZ2luYWxLZXksXG4gICAgICAgIGluZGV4S2V5LFxuICAgICAgICBncm91cGVkQnlQaXZvdEtleSxcbiAgICAgICAgU3ViQ29tcG9uZW50LFxuICAgICAgfSA9IG5ld1N0YXRlXG5cbiAgICAgIC8vIERldGVybWluZSBIZWFkZXIgR3JvdXBzXG4gICAgICBsZXQgaGFzSGVhZGVyR3JvdXBzID0gZmFsc2VcbiAgICAgIGNvbHVtbnMuZm9yRWFjaChjb2x1bW4gPT4ge1xuICAgICAgICBpZiAoY29sdW1uLmNvbHVtbnMpIHtcbiAgICAgICAgICBoYXNIZWFkZXJHcm91cHMgPSB0cnVlXG4gICAgICAgIH1cbiAgICAgIH0pXG5cbiAgICAgIGxldCBjb2x1bW5zV2l0aEV4cGFuZGVyID0gWy4uLmNvbHVtbnNdXG5cbiAgICAgIGxldCBleHBhbmRlckNvbHVtbiA9IGNvbHVtbnMuZmluZChcbiAgICAgICAgY29sID0+XG4gICAgICAgICAgY29sLmV4cGFuZGVyIHx8XG4gICAgICAgICAgKGNvbC5jb2x1bW5zICYmIGNvbC5jb2x1bW5zLnNvbWUoY29sMiA9PiBjb2wyLmV4cGFuZGVyKSlcbiAgICAgIClcbiAgICAgIC8vIFRoZSBhY3R1YWwgZXhwYW5kZXIgbWlnaHQgYmUgaW4gdGhlIGNvbHVtbnMgZmllbGQgb2YgYSBncm91cCBjb2x1bW5cbiAgICAgIGlmIChleHBhbmRlckNvbHVtbiAmJiAhZXhwYW5kZXJDb2x1bW4uZXhwYW5kZXIpIHtcbiAgICAgICAgZXhwYW5kZXJDb2x1bW4gPSBleHBhbmRlckNvbHVtbi5jb2x1bW5zLmZpbmQoY29sID0+IGNvbC5leHBhbmRlcilcbiAgICAgIH1cblxuICAgICAgLy8gSWYgd2UgaGF2ZSBTdWJDb21wb25lbnQncyB3ZSBuZWVkIHRvIG1ha2Ugc3VyZSB3ZSBoYXZlIGFuIGV4cGFuZGVyIGNvbHVtblxuICAgICAgaWYgKFN1YkNvbXBvbmVudCAmJiAhZXhwYW5kZXJDb2x1bW4pIHtcbiAgICAgICAgZXhwYW5kZXJDb2x1bW4gPSB7IGV4cGFuZGVyOiB0cnVlIH1cbiAgICAgICAgY29sdW1uc1dpdGhFeHBhbmRlciA9IFtleHBhbmRlckNvbHVtbiwgLi4uY29sdW1uc1dpdGhFeHBhbmRlcl1cbiAgICAgIH1cblxuICAgICAgY29uc3QgbWFrZURlY29yYXRlZENvbHVtbiA9IChjb2x1bW4sIHBhcmVudENvbHVtbikgPT4ge1xuICAgICAgICBsZXQgZGNvbFxuICAgICAgICBpZiAoY29sdW1uLmV4cGFuZGVyKSB7XG4gICAgICAgICAgZGNvbCA9IHtcbiAgICAgICAgICAgIC4uLnRoaXMucHJvcHMuY29sdW1uLFxuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5leHBhbmRlckRlZmF1bHRzLFxuICAgICAgICAgICAgLi4uY29sdW1uLFxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBkY29sID0ge1xuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5jb2x1bW4sXG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgfVxuICAgICAgICB9XG5cbiAgICAgICAgLy8gRW5zdXJlIG1pbldpZHRoIGlzIG5vdCBncmVhdGVyIHRoYW4gbWF4V2lkdGggaWYgc2V0XG4gICAgICAgIGlmIChkY29sLm1heFdpZHRoIDwgZGNvbC5taW5XaWR0aCkge1xuICAgICAgICAgIGRjb2wubWluV2lkdGggPSBkY29sLm1heFdpZHRoXG4gICAgICAgIH1cblxuICAgICAgICBpZiAocGFyZW50Q29sdW1uKSB7XG4gICAgICAgICAgZGNvbC5wYXJlbnRDb2x1bW4gPSBwYXJlbnRDb2x1bW5cbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZpcnN0IGNoZWNrIGZvciBzdHJpbmcgYWNjZXNzb3JcbiAgICAgICAgaWYgKHR5cGVvZiBkY29sLmFjY2Vzc29yID09PSAnc3RyaW5nJykge1xuICAgICAgICAgIGRjb2wuaWQgPSBkY29sLmlkIHx8IGRjb2wuYWNjZXNzb3JcbiAgICAgICAgICBjb25zdCBhY2Nlc3NvclN0cmluZyA9IGRjb2wuYWNjZXNzb3JcbiAgICAgICAgICBkY29sLmFjY2Vzc29yID0gcm93ID0+IF8uZ2V0KHJvdywgYWNjZXNzb3JTdHJpbmcpXG4gICAgICAgICAgcmV0dXJuIGRjb2xcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZhbGwgYmFjayB0byBmdW5jdGlvbmFsIGFjY2Vzc29yIChidXQgcmVxdWlyZSBhbiBJRClcbiAgICAgICAgaWYgKGRjb2wuYWNjZXNzb3IgJiYgIWRjb2wuaWQpIHtcbiAgICAgICAgICBjb25zb2xlLndhcm4oZGNvbClcbiAgICAgICAgICB0aHJvdyBuZXcgRXJyb3IoXG4gICAgICAgICAgICAnQSBjb2x1bW4gaWQgaXMgcmVxdWlyZWQgaWYgdXNpbmcgYSBub24tc3RyaW5nIGFjY2Vzc29yIGZvciBjb2x1bW4gYWJvdmUuJ1xuICAgICAgICAgIClcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZhbGwgYmFjayB0byBhbiB1bmRlZmluZWQgYWNjZXNzb3JcbiAgICAgICAgaWYgKCFkY29sLmFjY2Vzc29yKSB7XG4gICAgICAgICAgZGNvbC5hY2Nlc3NvciA9IGQgPT4gdW5kZWZpbmVkXG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gZGNvbFxuICAgICAgfVxuXG4gICAgICAvLyBEZWNvcmF0ZSB0aGUgY29sdW1uc1xuICAgICAgY29uc3QgZGVjb3JhdGVBbmRBZGRUb0FsbCA9IChjb2x1bW4sIHBhcmVudENvbHVtbikgPT4ge1xuICAgICAgICBjb25zdCBkZWNvcmF0ZWRDb2x1bW4gPSBtYWtlRGVjb3JhdGVkQ29sdW1uKGNvbHVtbiwgcGFyZW50Q29sdW1uKVxuICAgICAgICBhbGxEZWNvcmF0ZWRDb2x1bW5zLnB1c2goZGVjb3JhdGVkQ29sdW1uKVxuICAgICAgICByZXR1cm4gZGVjb3JhdGVkQ29sdW1uXG4gICAgICB9XG4gICAgICBjb25zdCBhbGxEZWNvcmF0ZWRDb2x1bW5zID0gW11cbiAgICAgIGNvbnN0IGRlY29yYXRlZENvbHVtbnMgPSBjb2x1bW5zV2l0aEV4cGFuZGVyLm1hcCgoY29sdW1uLCBpKSA9PiB7XG4gICAgICAgIGlmIChjb2x1bW4uY29sdW1ucykge1xuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgICBjb2x1bW5zOiBjb2x1bW4uY29sdW1ucy5tYXAoZCA9PiBkZWNvcmF0ZUFuZEFkZFRvQWxsKGQsIGNvbHVtbikpLFxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICByZXR1cm4gZGVjb3JhdGVBbmRBZGRUb0FsbChjb2x1bW4pXG4gICAgICAgIH1cbiAgICAgIH0pXG5cbiAgICAgIC8vIEJ1aWxkIHRoZSB2aXNpYmxlIGNvbHVtbnMsIGhlYWRlcnMgYW5kIGZsYXQgY29sdW1uIGxpc3RcbiAgICAgIGxldCB2aXNpYmxlQ29sdW1ucyA9IGRlY29yYXRlZENvbHVtbnMuc2xpY2UoKVxuICAgICAgbGV0IGFsbFZpc2libGVDb2x1bW5zID0gW11cblxuICAgICAgdmlzaWJsZUNvbHVtbnMgPSB2aXNpYmxlQ29sdW1ucy5tYXAoKGNvbHVtbiwgaSkgPT4ge1xuICAgICAgICBpZiAoY29sdW1uLmNvbHVtbnMpIHtcbiAgICAgICAgICBjb25zdCB2aXNpYmxlU3ViQ29sdW1ucyA9IGNvbHVtbi5jb2x1bW5zLmZpbHRlcihcbiAgICAgICAgICAgIGQgPT5cbiAgICAgICAgICAgICAgcGl2b3RCeS5pbmRleE9mKGQuaWQpID4gLTFcbiAgICAgICAgICAgICAgICA/IGZhbHNlXG4gICAgICAgICAgICAgICAgOiBfLmdldEZpcnN0RGVmaW5lZChkLnNob3csIHRydWUpXG4gICAgICAgICAgKVxuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgICBjb2x1bW5zOiB2aXNpYmxlU3ViQ29sdW1ucyxcbiAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGNvbHVtblxuICAgICAgfSlcblxuICAgICAgdmlzaWJsZUNvbHVtbnMgPSB2aXNpYmxlQ29sdW1ucy5maWx0ZXIoY29sdW1uID0+IHtcbiAgICAgICAgcmV0dXJuIGNvbHVtbi5jb2x1bW5zXG4gICAgICAgICAgPyBjb2x1bW4uY29sdW1ucy5sZW5ndGhcbiAgICAgICAgICA6IHBpdm90QnkuaW5kZXhPZihjb2x1bW4uaWQpID4gLTFcbiAgICAgICAgICAgID8gZmFsc2VcbiAgICAgICAgICAgIDogXy5nZXRGaXJzdERlZmluZWQoY29sdW1uLnNob3csIHRydWUpXG4gICAgICB9KVxuXG4gICAgICAvLyBGaW5kIGFueSBjdXN0b20gcGl2b3QgbG9jYXRpb25cbiAgICAgIGNvbnN0IHBpdm90SW5kZXggPSB2aXNpYmxlQ29sdW1ucy5maW5kSW5kZXgoY29sID0+IGNvbC5waXZvdClcblxuICAgICAgLy8gSGFuZGxlIFBpdm90IENvbHVtbnNcbiAgICAgIGlmIChwaXZvdEJ5Lmxlbmd0aCkge1xuICAgICAgICAvLyBSZXRyaWV2ZSB0aGUgcGl2b3QgY29sdW1ucyBpbiB0aGUgY29ycmVjdCBwaXZvdCBvcmRlclxuICAgICAgICBjb25zdCBwaXZvdENvbHVtbnMgPSBbXVxuICAgICAgICBwaXZvdEJ5LmZvckVhY2gocGl2b3RJRCA9PiB7XG4gICAgICAgICAgY29uc3QgZm91bmQgPSBhbGxEZWNvcmF0ZWRDb2x1bW5zLmZpbmQoZCA9PiBkLmlkID09PSBwaXZvdElEKVxuICAgICAgICAgIGlmIChmb3VuZCkge1xuICAgICAgICAgICAgcGl2b3RDb2x1bW5zLnB1c2goZm91bmQpXG4gICAgICAgICAgfVxuICAgICAgICB9KVxuXG4gICAgICAgIGxldCBQaXZvdFBhcmVudENvbHVtbiA9IHBpdm90Q29sdW1ucy5yZWR1Y2UoXG4gICAgICAgICAgKHByZXYsIGN1cnJlbnQpID0+XG4gICAgICAgICAgICBwcmV2ICYmIHByZXYgPT09IGN1cnJlbnQucGFyZW50Q29sdW1uICYmIGN1cnJlbnQucGFyZW50Q29sdW1uLFxuICAgICAgICAgIHBpdm90Q29sdW1uc1swXS5wYXJlbnRDb2x1bW5cbiAgICAgICAgKVxuXG4gICAgICAgIGxldCBQaXZvdEdyb3VwSGVhZGVyID0gaGFzSGVhZGVyR3JvdXBzICYmIFBpdm90UGFyZW50Q29sdW1uLkhlYWRlclxuICAgICAgICBQaXZvdEdyb3VwSGVhZGVyID0gUGl2b3RHcm91cEhlYWRlciB8fCAoKCkgPT4gPHN0cm9uZz5QaXZvdGVkPC9zdHJvbmc+KVxuXG4gICAgICAgIGxldCBwaXZvdENvbHVtbkdyb3VwID0ge1xuICAgICAgICAgIEhlYWRlcjogUGl2b3RHcm91cEhlYWRlcixcbiAgICAgICAgICBjb2x1bW5zOiBwaXZvdENvbHVtbnMubWFwKGNvbCA9PiAoe1xuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5waXZvdERlZmF1bHRzLFxuICAgICAgICAgICAgLi4uY29sLFxuICAgICAgICAgICAgcGl2b3RlZDogdHJ1ZSxcbiAgICAgICAgICB9KSksXG4gICAgICAgIH1cblxuICAgICAgICAvLyBQbGFjZSB0aGUgcGl2b3RDb2x1bW5zIGJhY2sgaW50byB0aGUgdmlzaWJsZUNvbHVtbnNcbiAgICAgICAgaWYgKHBpdm90SW5kZXggPj0gMCkge1xuICAgICAgICAgIHBpdm90Q29sdW1uR3JvdXAgPSB7XG4gICAgICAgICAgICAuLi52aXNpYmxlQ29sdW1uc1twaXZvdEluZGV4XSxcbiAgICAgICAgICAgIC4uLnBpdm90Q29sdW1uR3JvdXAsXG4gICAgICAgICAgfVxuICAgICAgICAgIHZpc2libGVDb2x1bW5zLnNwbGljZShwaXZvdEluZGV4LCAxLCBwaXZvdENvbHVtbkdyb3VwKVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgIHZpc2libGVDb2x1bW5zLnVuc2hpZnQocGl2b3RDb2x1bW5Hcm91cClcbiAgICAgICAgfVxuICAgICAgfVxuXG4gICAgICAvLyBCdWlsZCBIZWFkZXIgR3JvdXBzXG4gICAgICBjb25zdCBoZWFkZXJHcm91cHMgPSBbXVxuICAgICAgbGV0IGN1cnJlbnRTcGFuID0gW11cblxuICAgICAgLy8gQSBjb252ZW5pZW5jZSBmdW5jdGlvbiB0byBhZGQgYSBoZWFkZXIgYW5kIHJlc2V0IHRoZSBjdXJyZW50U3BhblxuICAgICAgY29uc3QgYWRkSGVhZGVyID0gKGNvbHVtbnMsIGNvbHVtbikgPT4ge1xuICAgICAgICBoZWFkZXJHcm91cHMucHVzaCh7XG4gICAgICAgICAgLi4udGhpcy5wcm9wcy5jb2x1bW4sXG4gICAgICAgICAgLi4uY29sdW1uLFxuICAgICAgICAgIGNvbHVtbnM6IGNvbHVtbnMsXG4gICAgICAgIH0pXG4gICAgICAgIGN1cnJlbnRTcGFuID0gW11cbiAgICAgIH1cblxuICAgICAgLy8gQnVpbGQgZmxhc3QgbGlzdCBvZiBhbGxWaXNpYmxlQ29sdW1ucyBhbmQgSGVhZGVyR3JvdXBzXG4gICAgICB2aXNpYmxlQ29sdW1ucy5mb3JFYWNoKChjb2x1bW4sIGkpID0+IHtcbiAgICAgICAgaWYgKGNvbHVtbi5jb2x1bW5zKSB7XG4gICAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMgPSBhbGxWaXNpYmxlQ29sdW1ucy5jb25jYXQoY29sdW1uLmNvbHVtbnMpXG4gICAgICAgICAgaWYgKGN1cnJlbnRTcGFuLmxlbmd0aCA+IDApIHtcbiAgICAgICAgICAgIGFkZEhlYWRlcihjdXJyZW50U3BhbilcbiAgICAgICAgICB9XG4gICAgICAgICAgYWRkSGVhZGVyKGNvbHVtbi5jb2x1bW5zLCBjb2x1bW4pXG4gICAgICAgICAgcmV0dXJuXG4gICAgICAgIH1cbiAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMucHVzaChjb2x1bW4pXG4gICAgICAgIGN1cnJlbnRTcGFuLnB1c2goY29sdW1uKVxuICAgICAgfSlcbiAgICAgIGlmIChoYXNIZWFkZXJHcm91cHMgJiYgY3VycmVudFNwYW4ubGVuZ3RoID4gMCkge1xuICAgICAgICBhZGRIZWFkZXIoY3VycmVudFNwYW4pXG4gICAgICB9XG5cbiAgICAgIC8vIEFjY2VzcyB0aGUgZGF0YVxuICAgICAgY29uc3QgYWNjZXNzUm93ID0gKGQsIGksIGxldmVsID0gMCkgPT4ge1xuICAgICAgICBjb25zdCByb3cgPSB7XG4gICAgICAgICAgW29yaWdpbmFsS2V5XTogZCxcbiAgICAgICAgICBbaW5kZXhLZXldOiBpLFxuICAgICAgICAgIFtzdWJSb3dzS2V5XTogZFtzdWJSb3dzS2V5XSxcbiAgICAgICAgICBbbmVzdGluZ0xldmVsS2V5XTogbGV2ZWwsXG4gICAgICAgIH1cbiAgICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucy5mb3JFYWNoKGNvbHVtbiA9PiB7XG4gICAgICAgICAgaWYgKGNvbHVtbi5leHBhbmRlcikgcmV0dXJuXG4gICAgICAgICAgcm93W2NvbHVtbi5pZF0gPSBjb2x1bW4uYWNjZXNzb3IoZClcbiAgICAgICAgfSlcbiAgICAgICAgaWYgKHJvd1tzdWJSb3dzS2V5XSkge1xuICAgICAgICAgIHJvd1tzdWJSb3dzS2V5XSA9IHJvd1tzdWJSb3dzS2V5XS5tYXAoKGQsIGkpID0+XG4gICAgICAgICAgICBhY2Nlc3NSb3coZCwgaSwgbGV2ZWwgKyAxKVxuICAgICAgICAgIClcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gcm93XG4gICAgICB9XG4gICAgICBsZXQgcmVzb2x2ZWREYXRhID0gZGF0YS5tYXAoKGQsIGkpID0+IGFjY2Vzc1JvdyhkLCBpKSlcblxuICAgICAgLy8gSWYgcGl2b3RpbmcsIHJlY3Vyc2l2ZWx5IGdyb3VwIHRoZSBkYXRhXG4gICAgICBjb25zdCBhZ2dyZWdhdGUgPSByb3dzID0+IHtcbiAgICAgICAgY29uc3QgYWdncmVnYXRpb25WYWx1ZXMgPSB7fVxuICAgICAgICBhZ2dyZWdhdGluZ0NvbHVtbnMuZm9yRWFjaChjb2x1bW4gPT4ge1xuICAgICAgICAgIGNvbnN0IHZhbHVlcyA9IHJvd3MubWFwKGQgPT4gZFtjb2x1bW4uaWRdKVxuICAgICAgICAgIGFnZ3JlZ2F0aW9uVmFsdWVzW2NvbHVtbi5pZF0gPSBjb2x1bW4uYWdncmVnYXRlKHZhbHVlcywgcm93cylcbiAgICAgICAgfSlcbiAgICAgICAgcmV0dXJuIGFnZ3JlZ2F0aW9uVmFsdWVzXG4gICAgICB9XG5cbiAgICAgIC8vIFRPRE86IE1ha2UgaXQgcG9zc2libGUgdG8gZmFicmljYXRlIG5lc3RlZCByb3dzIHdpdGhvdXQgcGl2b3RpbmdcbiAgICAgIGNvbnN0IGFnZ3JlZ2F0aW5nQ29sdW1ucyA9IGFsbFZpc2libGVDb2x1bW5zLmZpbHRlcihcbiAgICAgICAgZCA9PiAhZC5leHBhbmRlciAmJiBkLmFnZ3JlZ2F0ZVxuICAgICAgKVxuICAgICAgaWYgKHBpdm90QnkubGVuZ3RoKSB7XG4gICAgICAgIGNvbnN0IGdyb3VwUmVjdXJzaXZlbHkgPSAocm93cywga2V5cywgaSA9IDApID0+IHtcbiAgICAgICAgICAvLyBUaGlzIGlzIHRoZSBsYXN0IGxldmVsLCBqdXN0IHJldHVybiB0aGUgcm93c1xuICAgICAgICAgIGlmIChpID09PSBrZXlzLmxlbmd0aCkge1xuICAgICAgICAgICAgcmV0dXJuIHJvd3NcbiAgICAgICAgICB9XG4gICAgICAgICAgLy8gR3JvdXAgdGhlIHJvd3MgdG9nZXRoZXIgZm9yIHRoaXMgbGV2ZWxcbiAgICAgICAgICBsZXQgZ3JvdXBlZFJvd3MgPSBPYmplY3QuZW50cmllcyhcbiAgICAgICAgICAgIF8uZ3JvdXBCeShyb3dzLCBrZXlzW2ldKVxuICAgICAgICAgICkubWFwKChba2V5LCB2YWx1ZV0pID0+IHtcbiAgICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAgIFtwaXZvdElES2V5XToga2V5c1tpXSxcbiAgICAgICAgICAgICAgW3Bpdm90VmFsS2V5XToga2V5LFxuICAgICAgICAgICAgICBba2V5c1tpXV06IGtleSxcbiAgICAgICAgICAgICAgW3N1YlJvd3NLZXldOiB2YWx1ZSxcbiAgICAgICAgICAgICAgW25lc3RpbmdMZXZlbEtleV06IGksXG4gICAgICAgICAgICAgIFtncm91cGVkQnlQaXZvdEtleV06IHRydWUsXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcbiAgICAgICAgICAvLyBSZWN1cnNlIGludG8gdGhlIHN1YlJvd3NcbiAgICAgICAgICBncm91cGVkUm93cyA9IGdyb3VwZWRSb3dzLm1hcChyb3dHcm91cCA9PiB7XG4gICAgICAgICAgICBsZXQgc3ViUm93cyA9IGdyb3VwUmVjdXJzaXZlbHkocm93R3JvdXBbc3ViUm93c0tleV0sIGtleXMsIGkgKyAxKVxuICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgLi4ucm93R3JvdXAsXG4gICAgICAgICAgICAgIFtzdWJSb3dzS2V5XTogc3ViUm93cyxcbiAgICAgICAgICAgICAgW2FnZ3JlZ2F0ZWRLZXldOiB0cnVlLFxuICAgICAgICAgICAgICAuLi5hZ2dyZWdhdGUoc3ViUm93cyksXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcbiAgICAgICAgICByZXR1cm4gZ3JvdXBlZFJvd3NcbiAgICAgICAgfVxuICAgICAgICByZXNvbHZlZERhdGEgPSBncm91cFJlY3Vyc2l2ZWx5KHJlc29sdmVkRGF0YSwgcGl2b3RCeSlcbiAgICAgIH1cblxuICAgICAgcmV0dXJuIHtcbiAgICAgICAgLi4ubmV3U3RhdGUsXG4gICAgICAgIHJlc29sdmVkRGF0YSxcbiAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMsXG4gICAgICAgIGhlYWRlckdyb3VwcyxcbiAgICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucyxcbiAgICAgICAgaGFzSGVhZGVyR3JvdXBzLFxuICAgICAgfVxuICAgIH1cblxuICAgIGdldFNvcnRlZERhdGEgKHJlc29sdmVkU3RhdGUpIHtcbiAgICAgIGNvbnN0IHtcbiAgICAgICAgbWFudWFsLFxuICAgICAgICBzb3J0ZWQsXG4gICAgICAgIGZpbHRlcmVkLFxuICAgICAgICBkZWZhdWx0RmlsdGVyTWV0aG9kLFxuICAgICAgICByZXNvbHZlZERhdGEsXG4gICAgICAgIGFsbFZpc2libGVDb2x1bW5zLFxuICAgICAgICBhbGxEZWNvcmF0ZWRDb2x1bW5zLFxuICAgICAgfSA9IHJlc29sdmVkU3RhdGVcblxuICAgICAgY29uc3Qgc29ydE1ldGhvZHNCeUNvbHVtbklEID0ge31cblxuICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucy5maWx0ZXIoY29sID0+IGNvbC5zb3J0TWV0aG9kKS5mb3JFYWNoKGNvbCA9PiB7XG4gICAgICAgIHNvcnRNZXRob2RzQnlDb2x1bW5JRFtjb2wuaWRdID0gY29sLnNvcnRNZXRob2RcbiAgICAgIH0pXG5cbiAgICAgIC8vIFJlc29sdmUgdGhlIGRhdGEgZnJvbSBlaXRoZXIgbWFudWFsIGRhdGEgb3Igc29ydGVkIGRhdGFcbiAgICAgIHJldHVybiB7XG4gICAgICAgIHNvcnRlZERhdGE6IG1hbnVhbFxuICAgICAgICAgID8gcmVzb2x2ZWREYXRhXG4gICAgICAgICAgOiB0aGlzLnNvcnREYXRhKFxuICAgICAgICAgICAgdGhpcy5maWx0ZXJEYXRhKFxuICAgICAgICAgICAgICByZXNvbHZlZERhdGEsXG4gICAgICAgICAgICAgIGZpbHRlcmVkLFxuICAgICAgICAgICAgICBkZWZhdWx0RmlsdGVyTWV0aG9kLFxuICAgICAgICAgICAgICBhbGxWaXNpYmxlQ29sdW1uc1xuICAgICAgICAgICAgKSxcbiAgICAgICAgICAgIHNvcnRlZCxcbiAgICAgICAgICAgIHNvcnRNZXRob2RzQnlDb2x1bW5JRFxuICAgICAgICAgICksXG4gICAgICB9XG4gICAgfVxuXG4gICAgZmlyZUZldGNoRGF0YSAoKSB7XG4gICAgICB0aGlzLnByb3BzLm9uRmV0Y2hEYXRhKHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpLCB0aGlzKVxuICAgIH1cblxuICAgIGdldFByb3BPclN0YXRlIChrZXkpIHtcbiAgICAgIHJldHVybiBfLmdldEZpcnN0RGVmaW5lZCh0aGlzLnByb3BzW2tleV0sIHRoaXMuc3RhdGVba2V5XSlcbiAgICB9XG5cbiAgICBnZXRTdGF0ZU9yUHJvcCAoa2V5KSB7XG4gICAgICByZXR1cm4gXy5nZXRGaXJzdERlZmluZWQodGhpcy5zdGF0ZVtrZXldLCB0aGlzLnByb3BzW2tleV0pXG4gICAgfVxuXG4gICAgZmlsdGVyRGF0YSAoZGF0YSwgZmlsdGVyZWQsIGRlZmF1bHRGaWx0ZXJNZXRob2QsIGFsbFZpc2libGVDb2x1bW5zKSB7XG4gICAgICBsZXQgZmlsdGVyZWREYXRhID0gZGF0YVxuXG4gICAgICBpZiAoZmlsdGVyZWQubGVuZ3RoKSB7XG4gICAgICAgIGZpbHRlcmVkRGF0YSA9IGZpbHRlcmVkLnJlZHVjZSgoZmlsdGVyZWRTb0ZhciwgbmV4dEZpbHRlcikgPT4ge1xuICAgICAgICAgIGNvbnN0IGNvbHVtbiA9IGFsbFZpc2libGVDb2x1bW5zLmZpbmQoeCA9PiB4LmlkID09PSBuZXh0RmlsdGVyLmlkKVxuXG4gICAgICAgICAgLy8gRG9uJ3QgZmlsdGVyIGhpZGRlbiBjb2x1bW5zIG9yIGNvbHVtbnMgdGhhdCBoYXZlIGhhZCB0aGVpciBmaWx0ZXJzIGRpc2FibGVkXG4gICAgICAgICAgaWYgKCFjb2x1bW4gfHwgY29sdW1uLmZpbHRlcmFibGUgPT09IGZhbHNlKSB7XG4gICAgICAgICAgICByZXR1cm4gZmlsdGVyZWRTb0ZhclxuICAgICAgICAgIH1cblxuICAgICAgICAgIGNvbnN0IGZpbHRlck1ldGhvZCA9IGNvbHVtbi5maWx0ZXJNZXRob2QgfHwgZGVmYXVsdEZpbHRlck1ldGhvZFxuXG4gICAgICAgICAgLy8gSWYgJ2ZpbHRlckFsbCcgaXMgc2V0IHRvIHRydWUsIHBhc3MgdGhlIGVudGlyZSBkYXRhc2V0IHRvIHRoZSBmaWx0ZXIgbWV0aG9kXG4gICAgICAgICAgaWYgKGNvbHVtbi5maWx0ZXJBbGwpIHtcbiAgICAgICAgICAgIHJldHVybiBmaWx0ZXJNZXRob2QobmV4dEZpbHRlciwgZmlsdGVyZWRTb0ZhciwgY29sdW1uKVxuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICByZXR1cm4gZmlsdGVyZWRTb0Zhci5maWx0ZXIocm93ID0+IHtcbiAgICAgICAgICAgICAgcmV0dXJuIGZpbHRlck1ldGhvZChuZXh0RmlsdGVyLCByb3csIGNvbHVtbilcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICB9LCBmaWx0ZXJlZERhdGEpXG5cbiAgICAgICAgLy8gQXBwbHkgdGhlIGZpbHRlciB0byB0aGUgc3Vicm93cyBpZiB3ZSBhcmUgcGl2b3RpbmcsIGFuZCB0aGVuXG4gICAgICAgIC8vIGZpbHRlciBhbnkgcm93cyB3aXRob3V0IHN1YmNvbHVtbnMgYmVjYXVzZSBpdCB3b3VsZCBiZSBzdHJhbmdlIHRvIHNob3dcbiAgICAgICAgZmlsdGVyZWREYXRhID0gZmlsdGVyZWREYXRhXG4gICAgICAgICAgLm1hcChyb3cgPT4ge1xuICAgICAgICAgICAgaWYgKCFyb3dbdGhpcy5wcm9wcy5zdWJSb3dzS2V5XSkge1xuICAgICAgICAgICAgICByZXR1cm4gcm93XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICAuLi5yb3csXG4gICAgICAgICAgICAgIFt0aGlzLnByb3BzLnN1YlJvd3NLZXldOiB0aGlzLmZpbHRlckRhdGEoXG4gICAgICAgICAgICAgICAgcm93W3RoaXMucHJvcHMuc3ViUm93c0tleV0sXG4gICAgICAgICAgICAgICAgZmlsdGVyZWQsXG4gICAgICAgICAgICAgICAgZGVmYXVsdEZpbHRlck1ldGhvZCxcbiAgICAgICAgICAgICAgICBhbGxWaXNpYmxlQ29sdW1uc1xuICAgICAgICAgICAgICApLFxuICAgICAgICAgICAgfVxuICAgICAgICAgIH0pXG4gICAgICAgICAgLmZpbHRlcihyb3cgPT4ge1xuICAgICAgICAgICAgaWYgKCFyb3dbdGhpcy5wcm9wcy5zdWJSb3dzS2V5XSkge1xuICAgICAgICAgICAgICByZXR1cm4gdHJ1ZVxuICAgICAgICAgICAgfVxuICAgICAgICAgICAgcmV0dXJuIHJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldLmxlbmd0aCA+IDBcbiAgICAgICAgICB9KVxuICAgICAgfVxuXG4gICAgICByZXR1cm4gZmlsdGVyZWREYXRhXG4gICAgfVxuXG4gICAgc29ydERhdGEgKGRhdGEsIHNvcnRlZCwgc29ydE1ldGhvZHNCeUNvbHVtbklEID0ge30pIHtcbiAgICAgIGlmICghc29ydGVkLmxlbmd0aCkge1xuICAgICAgICByZXR1cm4gZGF0YVxuICAgICAgfVxuXG4gICAgICBjb25zdCBzb3J0ZWREYXRhID0gKHRoaXMucHJvcHMub3JkZXJCeU1ldGhvZCB8fCBfLm9yZGVyQnkpKFxuICAgICAgICBkYXRhLFxuICAgICAgICBzb3J0ZWQubWFwKHNvcnQgPT4ge1xuICAgICAgICAgIC8vIFN1cHBvcnQgY3VzdG9tIHNvcnRpbmcgbWV0aG9kcyBmb3IgZWFjaCBjb2x1bW5cbiAgICAgICAgICBpZiAoc29ydE1ldGhvZHNCeUNvbHVtbklEW3NvcnQuaWRdKSB7XG4gICAgICAgICAgICByZXR1cm4gKGEsIGIpID0+IHtcbiAgICAgICAgICAgICAgcmV0dXJuIHNvcnRNZXRob2RzQnlDb2x1bW5JRFtzb3J0LmlkXShhW3NvcnQuaWRdLCBiW3NvcnQuaWRdKVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH1cbiAgICAgICAgICByZXR1cm4gKGEsIGIpID0+IHtcbiAgICAgICAgICAgIHJldHVybiB0aGlzLnByb3BzLmRlZmF1bHRTb3J0TWV0aG9kKGFbc29ydC5pZF0sIGJbc29ydC5pZF0pXG4gICAgICAgICAgfVxuICAgICAgICB9KSxcbiAgICAgICAgc29ydGVkLm1hcChkID0+ICFkLmRlc2MpLFxuICAgICAgICB0aGlzLnByb3BzLmluZGV4S2V5XG4gICAgICApXG5cbiAgICAgIHNvcnRlZERhdGEuZm9yRWFjaChyb3cgPT4ge1xuICAgICAgICBpZiAoIXJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldKSB7XG4gICAgICAgICAgcmV0dXJuXG4gICAgICAgIH1cbiAgICAgICAgcm93W3RoaXMucHJvcHMuc3ViUm93c0tleV0gPSB0aGlzLnNvcnREYXRhKFxuICAgICAgICAgIHJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldLFxuICAgICAgICAgIHNvcnRlZCxcbiAgICAgICAgICBzb3J0TWV0aG9kc0J5Q29sdW1uSURcbiAgICAgICAgKVxuICAgICAgfSlcblxuICAgICAgcmV0dXJuIHNvcnRlZERhdGFcbiAgICB9XG5cbiAgICBnZXRNaW5Sb3dzICgpIHtcbiAgICAgIHJldHVybiBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgdGhpcy5wcm9wcy5taW5Sb3dzLFxuICAgICAgICB0aGlzLmdldFN0YXRlT3JQcm9wKCdwYWdlU2l6ZScpXG4gICAgICApXG4gICAgfVxuXG4gICAgLy8gVXNlciBhY3Rpb25zXG4gICAgb25QYWdlQ2hhbmdlIChwYWdlKSB7XG4gICAgICBjb25zdCB7IG9uUGFnZUNoYW5nZSwgY29sbGFwc2VPblBhZ2VDaGFuZ2UgfSA9IHRoaXMucHJvcHNcblxuICAgICAgY29uc3QgbmV3U3RhdGUgPSB7IHBhZ2UgfVxuICAgICAgaWYgKGNvbGxhcHNlT25QYWdlQ2hhbmdlKSB7XG4gICAgICAgIG5ld1N0YXRlLmV4cGFuZGVkID0ge31cbiAgICAgIH1cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShuZXdTdGF0ZSwgKCkgPT4ge1xuICAgICAgICBvblBhZ2VDaGFuZ2UgJiYgb25QYWdlQ2hhbmdlKHBhZ2UpXG4gICAgICB9KVxuICAgIH1cblxuICAgIG9uUGFnZVNpemVDaGFuZ2UgKG5ld1BhZ2VTaXplKSB7XG4gICAgICBjb25zdCB7IG9uUGFnZVNpemVDaGFuZ2UgfSA9IHRoaXMucHJvcHNcbiAgICAgIGNvbnN0IHsgcGFnZVNpemUsIHBhZ2UgfSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpXG5cbiAgICAgIC8vIE5vcm1hbGl6ZSB0aGUgcGFnZSB0byBkaXNwbGF5XG4gICAgICBjb25zdCBjdXJyZW50Um93ID0gcGFnZVNpemUgKiBwYWdlXG4gICAgICBjb25zdCBuZXdQYWdlID0gTWF0aC5mbG9vcihjdXJyZW50Um93IC8gbmV3UGFnZVNpemUpXG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHBhZ2VTaXplOiBuZXdQYWdlU2l6ZSxcbiAgICAgICAgICBwYWdlOiBuZXdQYWdlLFxuICAgICAgICB9LFxuICAgICAgICAoKSA9PiB7XG4gICAgICAgICAgb25QYWdlU2l6ZUNoYW5nZSAmJiBvblBhZ2VTaXplQ2hhbmdlKG5ld1BhZ2VTaXplLCBuZXdQYWdlKVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgc29ydENvbHVtbiAoY29sdW1uLCBhZGRpdGl2ZSkge1xuICAgICAgY29uc3QgeyBzb3J0ZWQsIHNraXBOZXh0U29ydCwgZGVmYXVsdFNvcnREZXNjIH0gPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuXG4gICAgICBjb25zdCBmaXJzdFNvcnREaXJlY3Rpb24gPSBjb2x1bW4uaGFzT3duUHJvcGVydHkoJ2RlZmF1bHRTb3J0RGVzYycpXG4gICAgICAgID8gY29sdW1uLmRlZmF1bHRTb3J0RGVzY1xuICAgICAgICA6IGRlZmF1bHRTb3J0RGVzY1xuICAgICAgY29uc3Qgc2Vjb25kU29ydERpcmVjdGlvbiA9ICFmaXJzdFNvcnREaXJlY3Rpb25cblxuICAgICAgLy8gd2UgY2FuJ3Qgc3RvcCBldmVudCBwcm9wYWdhdGlvbiBmcm9tIHRoZSBjb2x1bW4gcmVzaXplIG1vdmUgaGFuZGxlcnNcbiAgICAgIC8vIGF0dGFjaGVkIHRvIHRoZSBkb2N1bWVudCBiZWNhdXNlIG9mIHJlYWN0J3Mgc3ludGhldGljIGV2ZW50c1xuICAgICAgLy8gc28gd2UgaGF2ZSB0byBwcmV2ZW50IHRoZSBzb3J0IGZ1bmN0aW9uIGZyb20gYWN0dWFsbHkgc29ydGluZ1xuICAgICAgLy8gaWYgd2UgY2xpY2sgb24gdGhlIGNvbHVtbiByZXNpemUgZWxlbWVudCB3aXRoaW4gYSBoZWFkZXIuXG4gICAgICBpZiAoc2tpcE5leHRTb3J0KSB7XG4gICAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YSh7XG4gICAgICAgICAgc2tpcE5leHRTb3J0OiBmYWxzZSxcbiAgICAgICAgfSlcbiAgICAgICAgcmV0dXJuXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IHsgb25Tb3J0ZWRDaGFuZ2UgfSA9IHRoaXMucHJvcHNcblxuICAgICAgbGV0IG5ld1NvcnRlZCA9IF8uY2xvbmUoc29ydGVkIHx8IFtdKS5tYXAoZCA9PiB7XG4gICAgICAgIGQuZGVzYyA9IF8uaXNTb3J0aW5nRGVzYyhkKVxuICAgICAgICByZXR1cm4gZFxuICAgICAgfSlcbiAgICAgIGlmICghXy5pc0FycmF5KGNvbHVtbikpIHtcbiAgICAgICAgLy8gU2luZ2xlLVNvcnRcbiAgICAgICAgY29uc3QgZXhpc3RpbmdJbmRleCA9IG5ld1NvcnRlZC5maW5kSW5kZXgoZCA9PiBkLmlkID09PSBjb2x1bW4uaWQpXG4gICAgICAgIGlmIChleGlzdGluZ0luZGV4ID4gLTEpIHtcbiAgICAgICAgICBjb25zdCBleGlzdGluZyA9IG5ld1NvcnRlZFtleGlzdGluZ0luZGV4XVxuICAgICAgICAgIGlmIChleGlzdGluZy5kZXNjID09PSBzZWNvbmRTb3J0RGlyZWN0aW9uKSB7XG4gICAgICAgICAgICBpZiAoYWRkaXRpdmUpIHtcbiAgICAgICAgICAgICAgbmV3U29ydGVkLnNwbGljZShleGlzdGluZ0luZGV4LCAxKVxuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgZXhpc3RpbmcuZGVzYyA9IGZpcnN0U29ydERpcmVjdGlvblxuICAgICAgICAgICAgICBuZXdTb3J0ZWQgPSBbZXhpc3RpbmddXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGV4aXN0aW5nLmRlc2MgPSBzZWNvbmRTb3J0RGlyZWN0aW9uXG4gICAgICAgICAgICBpZiAoIWFkZGl0aXZlKSB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZCA9IFtleGlzdGluZ11cbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgaWYgKGFkZGl0aXZlKSB7XG4gICAgICAgICAgICBuZXdTb3J0ZWQucHVzaCh7XG4gICAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICAgIGRlc2M6IGZpcnN0U29ydERpcmVjdGlvbixcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IFtcbiAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICAgICAgZGVzYzogZmlyc3RTb3J0RGlyZWN0aW9uLFxuICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgXVxuICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgfSBlbHNlIHtcbiAgICAgICAgLy8gTXVsdGktU29ydFxuICAgICAgICBjb25zdCBleGlzdGluZ0luZGV4ID0gbmV3U29ydGVkLmZpbmRJbmRleChkID0+IGQuaWQgPT09IGNvbHVtblswXS5pZClcbiAgICAgICAgLy8gRXhpc3RpbmcgU29ydGVkIENvbHVtblxuICAgICAgICBpZiAoZXhpc3RpbmdJbmRleCA+IC0xKSB7XG4gICAgICAgICAgY29uc3QgZXhpc3RpbmcgPSBuZXdTb3J0ZWRbZXhpc3RpbmdJbmRleF1cbiAgICAgICAgICBpZiAoZXhpc3RpbmcuZGVzYyA9PT0gc2Vjb25kU29ydERpcmVjdGlvbikge1xuICAgICAgICAgICAgaWYgKGFkZGl0aXZlKSB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZC5zcGxpY2UoZXhpc3RpbmdJbmRleCwgY29sdW1uLmxlbmd0aClcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIGNvbHVtbi5mb3JFYWNoKChkLCBpKSA9PiB7XG4gICAgICAgICAgICAgICAgbmV3U29ydGVkW2V4aXN0aW5nSW5kZXggKyBpXS5kZXNjID0gZmlyc3RTb3J0RGlyZWN0aW9uXG4gICAgICAgICAgICAgIH0pXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGNvbHVtbi5mb3JFYWNoKChkLCBpKSA9PiB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZFtleGlzdGluZ0luZGV4ICsgaV0uZGVzYyA9IHNlY29uZFNvcnREaXJlY3Rpb25cbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICAgIGlmICghYWRkaXRpdmUpIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IG5ld1NvcnRlZC5zbGljZShleGlzdGluZ0luZGV4LCBjb2x1bW4ubGVuZ3RoKVxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAvLyBOZXcgU29ydCBDb2x1bW5cbiAgICAgICAgICBpZiAoYWRkaXRpdmUpIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IG5ld1NvcnRlZC5jb25jYXQoXG4gICAgICAgICAgICAgIGNvbHVtbi5tYXAoZCA9PiAoe1xuICAgICAgICAgICAgICAgIGlkOiBkLmlkLFxuICAgICAgICAgICAgICAgIGRlc2M6IGZpcnN0U29ydERpcmVjdGlvbixcbiAgICAgICAgICAgICAgfSkpXG4gICAgICAgICAgICApXG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IGNvbHVtbi5tYXAoZCA9PiAoe1xuICAgICAgICAgICAgICBpZDogZC5pZCxcbiAgICAgICAgICAgICAgZGVzYzogZmlyc3RTb3J0RGlyZWN0aW9uLFxuICAgICAgICAgICAgfSkpXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICB9XG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHBhZ2U6XG4gICAgICAgICAgICAoIXNvcnRlZC5sZW5ndGggJiYgbmV3U29ydGVkLmxlbmd0aCkgfHwgIWFkZGl0aXZlXG4gICAgICAgICAgICAgID8gMFxuICAgICAgICAgICAgICA6IHRoaXMuc3RhdGUucGFnZSxcbiAgICAgICAgICBzb3J0ZWQ6IG5ld1NvcnRlZCxcbiAgICAgICAgfSxcbiAgICAgICAgKCkgPT4ge1xuICAgICAgICAgIG9uU29ydGVkQ2hhbmdlICYmIG9uU29ydGVkQ2hhbmdlKG5ld1NvcnRlZCwgY29sdW1uLCBhZGRpdGl2ZSlcbiAgICAgICAgfVxuICAgICAgKVxuICAgIH1cblxuICAgIGZpbHRlckNvbHVtbiAoY29sdW1uLCB2YWx1ZSkge1xuICAgICAgY29uc3QgeyBmaWx0ZXJlZCB9ID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKClcbiAgICAgIGNvbnN0IHsgb25GaWx0ZXJlZENoYW5nZSB9ID0gdGhpcy5wcm9wc1xuXG4gICAgICAvLyBSZW1vdmUgb2xkIGZpbHRlciBmaXJzdCBpZiBpdCBleGlzdHNcbiAgICAgIGNvbnN0IG5ld0ZpbHRlcmluZyA9IChmaWx0ZXJlZCB8fCBbXSkuZmlsdGVyKHggPT4ge1xuICAgICAgICBpZiAoeC5pZCAhPT0gY29sdW1uLmlkKSB7XG4gICAgICAgICAgcmV0dXJuIHRydWVcbiAgICAgICAgfVxuICAgICAgfSlcblxuICAgICAgaWYgKHZhbHVlICE9PSAnJykge1xuICAgICAgICBuZXdGaWx0ZXJpbmcucHVzaCh7XG4gICAgICAgICAgaWQ6IGNvbHVtbi5pZCxcbiAgICAgICAgICB2YWx1ZTogdmFsdWUsXG4gICAgICAgIH0pXG4gICAgICB9XG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIGZpbHRlcmVkOiBuZXdGaWx0ZXJpbmcsXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBvbkZpbHRlcmVkQ2hhbmdlICYmIG9uRmlsdGVyZWRDaGFuZ2UobmV3RmlsdGVyaW5nLCBjb2x1bW4sIHZhbHVlKVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uU3RhcnQgKGV2ZW50LCBjb2x1bW4sIGlzVG91Y2gpIHtcbiAgICAgIGV2ZW50LnN0b3BQcm9wYWdhdGlvbigpXG4gICAgICBjb25zdCBwYXJlbnRXaWR0aCA9IGV2ZW50LnRhcmdldC5wYXJlbnRFbGVtZW50LmdldEJvdW5kaW5nQ2xpZW50UmVjdCgpXG4gICAgICAgIC53aWR0aFxuXG4gICAgICBsZXQgcGFnZVhcbiAgICAgIGlmIChpc1RvdWNoKSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQuY2hhbmdlZFRvdWNoZXNbMF0ucGFnZVhcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQucGFnZVhcbiAgICAgIH1cblxuICAgICAgdGhpcy50cmFwRXZlbnRzID0gdHJ1ZVxuICAgICAgdGhpcy5zZXRTdGF0ZVdpdGhEYXRhKFxuICAgICAgICB7XG4gICAgICAgICAgY3VycmVudGx5UmVzaXppbmc6IHtcbiAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICBzdGFydFg6IHBhZ2VYLFxuICAgICAgICAgICAgcGFyZW50V2lkdGg6IHBhcmVudFdpZHRoLFxuICAgICAgICAgIH0sXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBpZiAoaXNUb3VjaCkge1xuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcigndG91Y2htb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCd0b3VjaGNhbmNlbCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcigndG91Y2hlbmQnLCB0aGlzLnJlc2l6ZUNvbHVtbkVuZClcbiAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcignbW91c2Vtb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCdtb3VzZXVwJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCdtb3VzZWxlYXZlJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uTW92aW5nIChldmVudCkge1xuICAgICAgZXZlbnQuc3RvcFByb3BhZ2F0aW9uKClcbiAgICAgIGNvbnN0IHsgb25SZXNpemVkQ2hhbmdlIH0gPSB0aGlzLnByb3BzXG4gICAgICBjb25zdCB7IHJlc2l6ZWQsIGN1cnJlbnRseVJlc2l6aW5nIH0gPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuXG4gICAgICAvLyBEZWxldGUgb2xkIHZhbHVlXG4gICAgICBjb25zdCBuZXdSZXNpemVkID0gcmVzaXplZC5maWx0ZXIoeCA9PiB4LmlkICE9PSBjdXJyZW50bHlSZXNpemluZy5pZClcblxuICAgICAgbGV0IHBhZ2VYXG5cbiAgICAgIGlmIChldmVudC50eXBlID09PSAndG91Y2htb3ZlJykge1xuICAgICAgICBwYWdlWCA9IGV2ZW50LmNoYW5nZWRUb3VjaGVzWzBdLnBhZ2VYXG4gICAgICB9IGVsc2UgaWYgKGV2ZW50LnR5cGUgPT09ICdtb3VzZW1vdmUnKSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQucGFnZVhcbiAgICAgIH1cblxuICAgICAgLy8gU2V0IHRoZSBtaW4gc2l6ZSB0byAxMCB0byBhY2NvdW50IGZvciBtYXJnaW4gYW5kIGJvcmRlciBvciBlbHNlIHRoZSBncm91cCBoZWFkZXJzIGRvbid0IGxpbmUgdXAgY29ycmVjdGx5XG4gICAgICBjb25zdCBuZXdXaWR0aCA9IE1hdGgubWF4KFxuICAgICAgICBjdXJyZW50bHlSZXNpemluZy5wYXJlbnRXaWR0aCArIHBhZ2VYIC0gY3VycmVudGx5UmVzaXppbmcuc3RhcnRYLFxuICAgICAgICAxMVxuICAgICAgKVxuXG4gICAgICBuZXdSZXNpemVkLnB1c2goe1xuICAgICAgICBpZDogY3VycmVudGx5UmVzaXppbmcuaWQsXG4gICAgICAgIHZhbHVlOiBuZXdXaWR0aCxcbiAgICAgIH0pXG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHJlc2l6ZWQ6IG5ld1Jlc2l6ZWQsXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBvblJlc2l6ZWRDaGFuZ2UgJiYgb25SZXNpemVkQ2hhbmdlKG5ld1Jlc2l6ZWQsIGV2ZW50KVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uRW5kIChldmVudCkge1xuICAgICAgZXZlbnQuc3RvcFByb3BhZ2F0aW9uKClcbiAgICAgIGxldCBpc1RvdWNoID0gZXZlbnQudHlwZSA9PT0gJ3RvdWNoZW5kJyB8fCBldmVudC50eXBlID09PSAndG91Y2hjYW5jZWwnXG5cbiAgICAgIGlmIChpc1RvdWNoKSB7XG4gICAgICAgIGRvY3VtZW50LnJlbW92ZUV2ZW50TGlzdGVuZXIoJ3RvdWNobW92ZScsIHRoaXMucmVzaXplQ29sdW1uTW92aW5nKVxuICAgICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCd0b3VjaGNhbmNlbCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCd0b3VjaGVuZCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgfVxuXG4gICAgICAvLyBJZiBpdHMgYSB0b3VjaCBldmVudCBjbGVhciB0aGUgbW91c2Ugb25lJ3MgYXMgd2VsbCBiZWNhdXNlIHNvbWV0aW1lc1xuICAgICAgLy8gdGhlIG1vdXNlRG93biBldmVudCBnZXRzIGNhbGxlZCBhcyB3ZWxsLCBidXQgdGhlIG1vdXNlVXAgZXZlbnQgZG9lc24ndFxuICAgICAgZG9jdW1lbnQucmVtb3ZlRXZlbnRMaXN0ZW5lcignbW91c2Vtb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCdtb3VzZXVwJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCdtb3VzZWxlYXZlJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG5cbiAgICAgIC8vIFRoZSB0b3VjaCBldmVudHMgZG9uJ3QgcHJvcGFnYXRlIHVwIHRvIHRoZSBzb3J0aW5nJ3Mgb25Nb3VzZURvd24gZXZlbnQgc29cbiAgICAgIC8vIG5vIG5lZWQgdG8gcHJldmVudCBpdCBmcm9tIGhhcHBlbmluZyBvciBlbHNlIHRoZSBmaXJzdCBjbGljayBhZnRlciBhIHRvdWNoXG4gICAgICAvLyBldmVudCByZXNpemUgd2lsbCBub3Qgc29ydCB0aGUgY29sdW1uLlxuICAgICAgaWYgKCFpc1RvdWNoKSB7XG4gICAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YSh7XG4gICAgICAgICAgc2tpcE5leHRTb3J0OiB0cnVlLFxuICAgICAgICAgIGN1cnJlbnRseVJlc2l6aW5nOiBmYWxzZSxcbiAgICAgICAgfSlcbiAgICAgIH1cbiAgICB9XG4gIH1cbiJdfQ== + +/***/ }), +/* 361 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _classnames = __webpack_require__(41); + +var _classnames2 = _interopRequireDefault(_classnames); + +var _utils = __webpack_require__(95); + +var _utils2 = _interopRequireDefault(_utils); + +var _pagination = __webpack_require__(362); + +var _pagination2 = _interopRequireDefault(_pagination); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } +// + + +var emptyObj = function emptyObj() { + return {}; +}; + +exports.default = { + // General + data: [], + loading: false, + showPagination: true, + showPaginationTop: false, + showPaginationBottom: true, + showPageSizeOptions: true, + pageSizeOptions: [5, 10, 20, 25, 50, 100], + defaultPageSize: 20, + showPageJump: true, + collapseOnSortingChange: true, + collapseOnPageChange: true, + collapseOnDataChange: true, + freezeWhenExpanded: false, + sortable: true, + resizable: true, + filterable: false, + defaultSortDesc: false, + defaultSorted: [], + defaultFiltered: [], + defaultResized: [], + defaultExpanded: {}, + defaultFilterMethod: function defaultFilterMethod(filter, row, column) { + var id = filter.pivotId || filter.id; + return row[id] !== undefined ? String(row[id]).startsWith(filter.value) : true; + }, + defaultSortMethod: function defaultSortMethod(a, b) { + // force null and undefined to the bottom + a = a === null || a === undefined ? '' : a; + b = b === null || b === undefined ? '' : b; + // force any string values to lowercase + a = typeof a === 'string' ? a.toLowerCase() : a; + b = typeof b === 'string' ? b.toLowerCase() : b; + // Return either 1 or -1 to indicate a sort priority + if (a > b) { + return 1; + } + if (a < b) { + return -1; + } + // returning 0, undefined or any falsey value will use subsequent sorts or the index as a tiebreaker + return 0; + }, + + // Controlled State Props + // page: undefined, + // pageSize: undefined, + // sorted: [], + // filtered: [], + // resized: [], + // expanded: {}, + + // Controlled State Callbacks + onPageChange: undefined, + onPageSizeChange: undefined, + onSortedChange: undefined, + onFilteredChange: undefined, + onResizedChange: undefined, + onExpandedChange: undefined, + + // Pivoting + pivotBy: undefined, + + // Key Constants + pivotValKey: '_pivotVal', + pivotIDKey: '_pivotID', + subRowsKey: '_subRows', + aggregatedKey: '_aggregated', + nestingLevelKey: '_nestingLevel', + originalKey: '_original', + indexKey: '_index', + groupedByPivotKey: '_groupedByPivot', + + // Server-side Callbacks + onFetchData: function onFetchData() { + return null; + }, + + // Classes + className: '', + style: {}, + + // Component decorators + getProps: emptyObj, + getTableProps: emptyObj, + getTheadGroupProps: emptyObj, + getTheadGroupTrProps: emptyObj, + getTheadGroupThProps: emptyObj, + getTheadProps: emptyObj, + getTheadTrProps: emptyObj, + getTheadThProps: emptyObj, + getTheadFilterProps: emptyObj, + getTheadFilterTrProps: emptyObj, + getTheadFilterThProps: emptyObj, + getTbodyProps: emptyObj, + getTrGroupProps: emptyObj, + getTrProps: emptyObj, + getTdProps: emptyObj, + getTfootProps: emptyObj, + getTfootTrProps: emptyObj, + getTfootTdProps: emptyObj, + getPaginationProps: emptyObj, + getLoadingProps: emptyObj, + getNoDataProps: emptyObj, + getResizerProps: emptyObj, + + // Global Column Defaults + column: { + // Renderers + Cell: undefined, + Header: undefined, + Footer: undefined, + Aggregated: undefined, + Pivot: undefined, + PivotValue: undefined, + Expander: undefined, + Filter: undefined, + // All Columns + sortable: undefined, // use table default + resizable: undefined, // use table default + filterable: undefined, // use table default + show: true, + minWidth: 100, + // Cells only + className: '', + style: {}, + getProps: emptyObj, + // Pivot only + aggregate: undefined, + // Headers only + headerClassName: '', + headerStyle: {}, + getHeaderProps: emptyObj, + // Footers only + footerClassName: '', + footerStyle: {}, + getFooterProps: emptyObj, + filterMethod: undefined, + filterAll: false, + sortMethod: undefined + }, + + // Global Expander Column Defaults + expanderDefaults: { + sortable: false, + resizable: false, + filterable: false, + width: 35 + }, + + pivotDefaults: { + // extend the defaults for pivoted columns here + }, + + // Text + previousText: 'Previous', + nextText: 'Next', + loadingText: 'Loading...', + noDataText: 'No rows found', + pageText: 'Page', + ofText: 'of', + rowsText: 'rows', + + // Components + TableComponent: _utils2.default.makeTemplateComponent('rt-table', 'Table'), + TheadComponent: _utils2.default.makeTemplateComponent('rt-thead', 'Thead'), + TbodyComponent: _utils2.default.makeTemplateComponent('rt-tbody', 'Tbody'), + TrGroupComponent: _utils2.default.makeTemplateComponent('rt-tr-group', 'TrGroup'), + TrComponent: _utils2.default.makeTemplateComponent('rt-tr', 'Tr'), + ThComponent: function ThComponent(_ref) { + var toggleSort = _ref.toggleSort, + className = _ref.className, + children = _ref.children, + rest = _objectWithoutProperties(_ref, ['toggleSort', 'className', 'children']); + + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)(className, 'rt-th'), + onClick: function onClick(e) { + toggleSort && toggleSort(e); + } + }, rest), + children + ); + }, + TdComponent: _utils2.default.makeTemplateComponent('rt-td', 'Td'), + TfootComponent: _utils2.default.makeTemplateComponent('rt-tfoot', 'Tfoot'), + FilterComponent: function FilterComponent(_ref2) { + var filter = _ref2.filter, + _onChange = _ref2.onChange; + return _react2.default.createElement('input', { + type: 'text', + style: { + width: '100%' + }, + value: filter ? filter.value : '', + onChange: function onChange(event) { + return _onChange(event.target.value); + } + }); + }, + ExpanderComponent: function ExpanderComponent(_ref3) { + var isExpanded = _ref3.isExpanded; + return _react2.default.createElement( + 'div', + { className: (0, _classnames2.default)('rt-expander', isExpanded && '-open') }, + '\u2022' + ); + }, + PivotValueComponent: function PivotValueComponent(_ref4) { + var subRows = _ref4.subRows, + value = _ref4.value; + return _react2.default.createElement( + 'span', + null, + value, + ' ', + subRows && '(' + subRows.length + ')' + ); + }, + AggregatedComponent: function AggregatedComponent(_ref5) { + var subRows = _ref5.subRows, + column = _ref5.column; + + var previewValues = subRows.filter(function (d) { + return typeof d[column.id] !== 'undefined'; + }).map(function (row, i) { + return _react2.default.createElement( + 'span', + { key: i }, + row[column.id], + i < subRows.length - 1 ? ', ' : '' + ); + }); + return _react2.default.createElement( + 'span', + null, + previewValues + ); + }, + PivotComponent: undefined, // this is a computed default generated using + // the ExpanderComponent and PivotValueComponent at run-time in methods.js + PaginationComponent: _pagination2.default, + PreviousComponent: undefined, + NextComponent: undefined, + LoadingComponent: function LoadingComponent(_ref6) { + var className = _ref6.className, + loading = _ref6.loading, + loadingText = _ref6.loadingText, + rest = _objectWithoutProperties(_ref6, ['className', 'loading', 'loadingText']); + + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)('-loading', { '-active': loading }, className) + }, rest), + _react2.default.createElement( + 'div', + { className: '-loading-inner' }, + loadingText + ) + ); + }, + NoDataComponent: _utils2.default.makeTemplateComponent('rt-noData', 'NoData'), + ResizerComponent: _utils2.default.makeTemplateComponent('rt-resizer', 'Resizer'), + PadRowComponent: function PadRowComponent() { + return _react2.default.createElement( + 'span', + null, + '\xA0' + ); + } +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9kZWZhdWx0UHJvcHMuanMiXSwibmFtZXMiOlsiZW1wdHlPYmoiLCJkYXRhIiwibG9hZGluZyIsInNob3dQYWdpbmF0aW9uIiwic2hvd1BhZ2luYXRpb25Ub3AiLCJzaG93UGFnaW5hdGlvbkJvdHRvbSIsInNob3dQYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZU9wdGlvbnMiLCJkZWZhdWx0UGFnZVNpemUiLCJzaG93UGFnZUp1bXAiLCJjb2xsYXBzZU9uU29ydGluZ0NoYW5nZSIsImNvbGxhcHNlT25QYWdlQ2hhbmdlIiwiY29sbGFwc2VPbkRhdGFDaGFuZ2UiLCJmcmVlemVXaGVuRXhwYW5kZWQiLCJzb3J0YWJsZSIsInJlc2l6YWJsZSIsImZpbHRlcmFibGUiLCJkZWZhdWx0U29ydERlc2MiLCJkZWZhdWx0U29ydGVkIiwiZGVmYXVsdEZpbHRlcmVkIiwiZGVmYXVsdFJlc2l6ZWQiLCJkZWZhdWx0RXhwYW5kZWQiLCJkZWZhdWx0RmlsdGVyTWV0aG9kIiwiZmlsdGVyIiwicm93IiwiY29sdW1uIiwiaWQiLCJwaXZvdElkIiwidW5kZWZpbmVkIiwiU3RyaW5nIiwic3RhcnRzV2l0aCIsInZhbHVlIiwiZGVmYXVsdFNvcnRNZXRob2QiLCJhIiwiYiIsInRvTG93ZXJDYXNlIiwib25QYWdlQ2hhbmdlIiwib25QYWdlU2l6ZUNoYW5nZSIsIm9uU29ydGVkQ2hhbmdlIiwib25GaWx0ZXJlZENoYW5nZSIsIm9uUmVzaXplZENoYW5nZSIsIm9uRXhwYW5kZWRDaGFuZ2UiLCJwaXZvdEJ5IiwicGl2b3RWYWxLZXkiLCJwaXZvdElES2V5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJuZXN0aW5nTGV2ZWxLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJvbkZldGNoRGF0YSIsImNsYXNzTmFtZSIsInN0eWxlIiwiZ2V0UHJvcHMiLCJnZXRUYWJsZVByb3BzIiwiZ2V0VGhlYWRHcm91cFByb3BzIiwiZ2V0VGhlYWRHcm91cFRyUHJvcHMiLCJnZXRUaGVhZEdyb3VwVGhQcm9wcyIsImdldFRoZWFkUHJvcHMiLCJnZXRUaGVhZFRyUHJvcHMiLCJnZXRUaGVhZFRoUHJvcHMiLCJnZXRUaGVhZEZpbHRlclByb3BzIiwiZ2V0VGhlYWRGaWx0ZXJUclByb3BzIiwiZ2V0VGhlYWRGaWx0ZXJUaFByb3BzIiwiZ2V0VGJvZHlQcm9wcyIsImdldFRyR3JvdXBQcm9wcyIsImdldFRyUHJvcHMiLCJnZXRUZFByb3BzIiwiZ2V0VGZvb3RQcm9wcyIsImdldFRmb290VHJQcm9wcyIsImdldFRmb290VGRQcm9wcyIsImdldFBhZ2luYXRpb25Qcm9wcyIsImdldExvYWRpbmdQcm9wcyIsImdldE5vRGF0YVByb3BzIiwiZ2V0UmVzaXplclByb3BzIiwiQ2VsbCIsIkhlYWRlciIsIkZvb3RlciIsIkFnZ3JlZ2F0ZWQiLCJQaXZvdCIsIlBpdm90VmFsdWUiLCJFeHBhbmRlciIsIkZpbHRlciIsInNob3ciLCJtaW5XaWR0aCIsImFnZ3JlZ2F0ZSIsImhlYWRlckNsYXNzTmFtZSIsImhlYWRlclN0eWxlIiwiZ2V0SGVhZGVyUHJvcHMiLCJmb290ZXJDbGFzc05hbWUiLCJmb290ZXJTdHlsZSIsImdldEZvb3RlclByb3BzIiwiZmlsdGVyTWV0aG9kIiwiZmlsdGVyQWxsIiwic29ydE1ldGhvZCIsImV4cGFuZGVyRGVmYXVsdHMiLCJ3aWR0aCIsInBpdm90RGVmYXVsdHMiLCJwcmV2aW91c1RleHQiLCJuZXh0VGV4dCIsImxvYWRpbmdUZXh0Iiwibm9EYXRhVGV4dCIsInBhZ2VUZXh0Iiwib2ZUZXh0Iiwicm93c1RleHQiLCJUYWJsZUNvbXBvbmVudCIsIm1ha2VUZW1wbGF0ZUNvbXBvbmVudCIsIlRoZWFkQ29tcG9uZW50IiwiVGJvZHlDb21wb25lbnQiLCJUckdyb3VwQ29tcG9uZW50IiwiVHJDb21wb25lbnQiLCJUaENvbXBvbmVudCIsInRvZ2dsZVNvcnQiLCJjaGlsZHJlbiIsInJlc3QiLCJlIiwiVGRDb21wb25lbnQiLCJUZm9vdENvbXBvbmVudCIsIkZpbHRlckNvbXBvbmVudCIsIm9uQ2hhbmdlIiwiZXZlbnQiLCJ0YXJnZXQiLCJFeHBhbmRlckNvbXBvbmVudCIsImlzRXhwYW5kZWQiLCJQaXZvdFZhbHVlQ29tcG9uZW50Iiwic3ViUm93cyIsImxlbmd0aCIsIkFnZ3JlZ2F0ZWRDb21wb25lbnQiLCJwcmV2aWV3VmFsdWVzIiwiZCIsIm1hcCIsImkiLCJQaXZvdENvbXBvbmVudCIsIlBhZ2luYXRpb25Db21wb25lbnQiLCJQcmV2aW91c0NvbXBvbmVudCIsIk5leHRDb21wb25lbnQiLCJMb2FkaW5nQ29tcG9uZW50IiwiTm9EYXRhQ29tcG9uZW50IiwiUmVzaXplckNvbXBvbmVudCIsIlBhZFJvd0NvbXBvbmVudCJdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7O0FBRUE7Ozs7QUFDQTs7Ozs7OztBQUZBOzs7QUFJQSxJQUFNQSxXQUFXLFNBQVhBLFFBQVc7QUFBQSxTQUFPLEVBQVA7QUFBQSxDQUFqQjs7a0JBRWU7QUFDYjtBQUNBQyxRQUFNLEVBRk87QUFHYkMsV0FBUyxLQUhJO0FBSWJDLGtCQUFnQixJQUpIO0FBS2JDLHFCQUFtQixLQUxOO0FBTWJDLHdCQUFzQixJQU5UO0FBT2JDLHVCQUFxQixJQVBSO0FBUWJDLG1CQUFpQixDQUFDLENBQUQsRUFBSSxFQUFKLEVBQVEsRUFBUixFQUFZLEVBQVosRUFBZ0IsRUFBaEIsRUFBb0IsR0FBcEIsQ0FSSjtBQVNiQyxtQkFBaUIsRUFUSjtBQVViQyxnQkFBYyxJQVZEO0FBV2JDLDJCQUF5QixJQVhaO0FBWWJDLHdCQUFzQixJQVpUO0FBYWJDLHdCQUFzQixJQWJUO0FBY2JDLHNCQUFvQixLQWRQO0FBZWJDLFlBQVUsSUFmRztBQWdCYkMsYUFBVyxJQWhCRTtBQWlCYkMsY0FBWSxLQWpCQztBQWtCYkMsbUJBQWlCLEtBbEJKO0FBbUJiQyxpQkFBZSxFQW5CRjtBQW9CYkMsbUJBQWlCLEVBcEJKO0FBcUJiQyxrQkFBZ0IsRUFyQkg7QUFzQmJDLG1CQUFpQixFQXRCSjtBQXVCYkMsdUJBQXFCLDZCQUFDQyxNQUFELEVBQVNDLEdBQVQsRUFBY0MsTUFBZCxFQUF5QjtBQUM1QyxRQUFNQyxLQUFLSCxPQUFPSSxPQUFQLElBQWtCSixPQUFPRyxFQUFwQztBQUNBLFdBQU9GLElBQUlFLEVBQUosTUFBWUUsU0FBWixHQUNIQyxPQUFPTCxJQUFJRSxFQUFKLENBQVAsRUFBZ0JJLFVBQWhCLENBQTJCUCxPQUFPUSxLQUFsQyxDQURHLEdBRUgsSUFGSjtBQUdELEdBNUJZO0FBNkJiQyxxQkFBbUIsMkJBQUNDLENBQUQsRUFBSUMsQ0FBSixFQUFVO0FBQzNCO0FBQ0FELFFBQUlBLE1BQU0sSUFBTixJQUFjQSxNQUFNTCxTQUFwQixHQUFnQyxFQUFoQyxHQUFxQ0ssQ0FBekM7QUFDQUMsUUFBSUEsTUFBTSxJQUFOLElBQWNBLE1BQU1OLFNBQXBCLEdBQWdDLEVBQWhDLEdBQXFDTSxDQUF6QztBQUNBO0FBQ0FELFFBQUksT0FBT0EsQ0FBUCxLQUFhLFFBQWIsR0FBd0JBLEVBQUVFLFdBQUYsRUFBeEIsR0FBMENGLENBQTlDO0FBQ0FDLFFBQUksT0FBT0EsQ0FBUCxLQUFhLFFBQWIsR0FBd0JBLEVBQUVDLFdBQUYsRUFBeEIsR0FBMENELENBQTlDO0FBQ0E7QUFDQSxRQUFJRCxJQUFJQyxDQUFSLEVBQVc7QUFDVCxhQUFPLENBQVA7QUFDRDtBQUNELFFBQUlELElBQUlDLENBQVIsRUFBVztBQUNULGFBQU8sQ0FBQyxDQUFSO0FBQ0Q7QUFDRDtBQUNBLFdBQU8sQ0FBUDtBQUNELEdBN0NZOztBQStDYjtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBRSxnQkFBY1IsU0F4REQ7QUF5RGJTLG9CQUFrQlQsU0F6REw7QUEwRGJVLGtCQUFnQlYsU0ExREg7QUEyRGJXLG9CQUFrQlgsU0EzREw7QUE0RGJZLG1CQUFpQlosU0E1REo7QUE2RGJhLG9CQUFrQmIsU0E3REw7O0FBK0RiO0FBQ0FjLFdBQVNkLFNBaEVJOztBQWtFYjtBQUNBZSxlQUFhLFdBbkVBO0FBb0ViQyxjQUFZLFVBcEVDO0FBcUViQyxjQUFZLFVBckVDO0FBc0ViQyxpQkFBZSxhQXRFRjtBQXVFYkMsbUJBQWlCLGVBdkVKO0FBd0ViQyxlQUFhLFdBeEVBO0FBeUViQyxZQUFVLFFBekVHO0FBMEViQyxxQkFBbUIsaUJBMUVOOztBQTRFYjtBQUNBQyxlQUFhO0FBQUEsV0FBTSxJQUFOO0FBQUEsR0E3RUE7O0FBK0ViO0FBQ0FDLGFBQVcsRUFoRkU7QUFpRmJDLFNBQU8sRUFqRk07O0FBbUZiO0FBQ0FDLFlBQVV0RCxRQXBGRztBQXFGYnVELGlCQUFldkQsUUFyRkY7QUFzRmJ3RCxzQkFBb0J4RCxRQXRGUDtBQXVGYnlELHdCQUFzQnpELFFBdkZUO0FBd0ZiMEQsd0JBQXNCMUQsUUF4RlQ7QUF5RmIyRCxpQkFBZTNELFFBekZGO0FBMEZiNEQsbUJBQWlCNUQsUUExRko7QUEyRmI2RCxtQkFBaUI3RCxRQTNGSjtBQTRGYjhELHVCQUFxQjlELFFBNUZSO0FBNkZiK0QseUJBQXVCL0QsUUE3RlY7QUE4RmJnRSx5QkFBdUJoRSxRQTlGVjtBQStGYmlFLGlCQUFlakUsUUEvRkY7QUFnR2JrRSxtQkFBaUJsRSxRQWhHSjtBQWlHYm1FLGNBQVluRSxRQWpHQztBQWtHYm9FLGNBQVlwRSxRQWxHQztBQW1HYnFFLGlCQUFlckUsUUFuR0Y7QUFvR2JzRSxtQkFBaUJ0RSxRQXBHSjtBQXFHYnVFLG1CQUFpQnZFLFFBckdKO0FBc0did0Usc0JBQW9CeEUsUUF0R1A7QUF1R2J5RSxtQkFBaUJ6RSxRQXZHSjtBQXdHYjBFLGtCQUFnQjFFLFFBeEdIO0FBeUdiMkUsbUJBQWlCM0UsUUF6R0o7O0FBMkdiO0FBQ0F5QixVQUFRO0FBQ047QUFDQW1ELFVBQU1oRCxTQUZBO0FBR05pRCxZQUFRakQsU0FIRjtBQUlOa0QsWUFBUWxELFNBSkY7QUFLTm1ELGdCQUFZbkQsU0FMTjtBQU1Ob0QsV0FBT3BELFNBTkQ7QUFPTnFELGdCQUFZckQsU0FQTjtBQVFOc0QsY0FBVXRELFNBUko7QUFTTnVELFlBQVF2RCxTQVRGO0FBVU47QUFDQWQsY0FBVWMsU0FYSixFQVdlO0FBQ3JCYixlQUFXYSxTQVpMLEVBWWdCO0FBQ3RCWixnQkFBWVksU0FiTixFQWFpQjtBQUN2QndELFVBQU0sSUFkQTtBQWVOQyxjQUFVLEdBZko7QUFnQk47QUFDQWpDLGVBQVcsRUFqQkw7QUFrQk5DLFdBQU8sRUFsQkQ7QUFtQk5DLGNBQVV0RCxRQW5CSjtBQW9CTjtBQUNBc0YsZUFBVzFELFNBckJMO0FBc0JOO0FBQ0EyRCxxQkFBaUIsRUF2Qlg7QUF3Qk5DLGlCQUFhLEVBeEJQO0FBeUJOQyxvQkFBZ0J6RixRQXpCVjtBQTBCTjtBQUNBMEYscUJBQWlCLEVBM0JYO0FBNEJOQyxpQkFBYSxFQTVCUDtBQTZCTkMsb0JBQWdCNUYsUUE3QlY7QUE4Qk42RixrQkFBY2pFLFNBOUJSO0FBK0JOa0UsZUFBVyxLQS9CTDtBQWdDTkMsZ0JBQVluRTtBQWhDTixHQTVHSzs7QUErSWI7QUFDQW9FLG9CQUFrQjtBQUNoQmxGLGNBQVUsS0FETTtBQUVoQkMsZUFBVyxLQUZLO0FBR2hCQyxnQkFBWSxLQUhJO0FBSWhCaUYsV0FBTztBQUpTLEdBaEpMOztBQXVKYkMsaUJBQWU7QUFDYjtBQURhLEdBdkpGOztBQTJKYjtBQUNBQyxnQkFBYyxVQTVKRDtBQTZKYkMsWUFBVSxNQTdKRztBQThKYkMsZUFBYSxZQTlKQTtBQStKYkMsY0FBWSxlQS9KQztBQWdLYkMsWUFBVSxNQWhLRztBQWlLYkMsVUFBUSxJQWpLSztBQWtLYkMsWUFBVSxNQWxLRzs7QUFvS2I7QUFDQUMsa0JBQWdCLGdCQUFFQyxxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXJLSDtBQXNLYkMsa0JBQWdCLGdCQUFFRCxxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXRLSDtBQXVLYkUsa0JBQWdCLGdCQUFFRixxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXZLSDtBQXdLYkcsb0JBQWtCLGdCQUFFSCxxQkFBRixDQUF3QixhQUF4QixFQUF1QyxTQUF2QyxDQXhLTDtBQXlLYkksZUFBYSxnQkFBRUoscUJBQUYsQ0FBd0IsT0FBeEIsRUFBaUMsSUFBakMsQ0F6S0E7QUEwS2JLLGVBQWEsMkJBQWtEO0FBQUEsUUFBL0NDLFVBQStDLFFBQS9DQSxVQUErQztBQUFBLFFBQW5DN0QsU0FBbUMsUUFBbkNBLFNBQW1DO0FBQUEsUUFBeEI4RCxRQUF3QixRQUF4QkEsUUFBd0I7QUFBQSxRQUFYQyxJQUFXOztBQUM3RCxXQUNFO0FBQUE7QUFBQTtBQUNFLG1CQUFXLDBCQUFXL0QsU0FBWCxFQUFzQixPQUF0QixDQURiO0FBRUUsaUJBQVMsb0JBQUs7QUFDWjZELHdCQUFjQSxXQUFXRyxDQUFYLENBQWQ7QUFDRDtBQUpILFNBS01ELElBTE47QUFPR0Q7QUFQSCxLQURGO0FBV0QsR0F0TFk7QUF1TGJHLGVBQWEsZ0JBQUVWLHFCQUFGLENBQXdCLE9BQXhCLEVBQWlDLElBQWpDLENBdkxBO0FBd0xiVyxrQkFBZ0IsZ0JBQUVYLHFCQUFGLENBQXdCLFVBQXhCLEVBQW9DLE9BQXBDLENBeExIO0FBeUxiWSxtQkFBaUI7QUFBQSxRQUFHaEcsTUFBSCxTQUFHQSxNQUFIO0FBQUEsUUFBV2lHLFNBQVgsU0FBV0EsUUFBWDtBQUFBLFdBQ2Y7QUFDRSxZQUFLLE1BRFA7QUFFRSxhQUFPO0FBQ0x2QixlQUFPO0FBREYsT0FGVDtBQUtFLGFBQU8xRSxTQUFTQSxPQUFPUSxLQUFoQixHQUF3QixFQUxqQztBQU1FLGdCQUFVO0FBQUEsZUFBU3lGLFVBQVNDLE1BQU1DLE1BQU4sQ0FBYTNGLEtBQXRCLENBQVQ7QUFBQTtBQU5aLE1BRGU7QUFBQSxHQXpMSjtBQWtNYjRGLHFCQUFtQjtBQUFBLFFBQUdDLFVBQUgsU0FBR0EsVUFBSDtBQUFBLFdBQ2pCO0FBQUE7QUFBQSxRQUFLLFdBQVcsMEJBQVcsYUFBWCxFQUEwQkEsY0FBYyxPQUF4QyxDQUFoQjtBQUFBO0FBQUEsS0FEaUI7QUFBQSxHQWxNTjtBQXNNYkMsdUJBQXFCO0FBQUEsUUFBR0MsT0FBSCxTQUFHQSxPQUFIO0FBQUEsUUFBWS9GLEtBQVosU0FBWUEsS0FBWjtBQUFBLFdBQ25CO0FBQUE7QUFBQTtBQUNHQSxXQURIO0FBQUE7QUFDVytGLHVCQUFlQSxRQUFRQyxNQUF2QjtBQURYLEtBRG1CO0FBQUEsR0F0TVI7QUEwTWJDLHVCQUFxQixvQ0FBeUI7QUFBQSxRQUF0QkYsT0FBc0IsU0FBdEJBLE9BQXNCO0FBQUEsUUFBYnJHLE1BQWEsU0FBYkEsTUFBYTs7QUFDNUMsUUFBTXdHLGdCQUFnQkgsUUFDbkJ2RyxNQURtQixDQUNaO0FBQUEsYUFBSyxPQUFPMkcsRUFBRXpHLE9BQU9DLEVBQVQsQ0FBUCxLQUF3QixXQUE3QjtBQUFBLEtBRFksRUFFbkJ5RyxHQUZtQixDQUVmLFVBQUMzRyxHQUFELEVBQU00RyxDQUFOO0FBQUEsYUFDSDtBQUFBO0FBQUEsVUFBTSxLQUFLQSxDQUFYO0FBQ0c1RyxZQUFJQyxPQUFPQyxFQUFYLENBREg7QUFFRzBHLFlBQUlOLFFBQVFDLE1BQVIsR0FBaUIsQ0FBckIsR0FBeUIsSUFBekIsR0FBZ0M7QUFGbkMsT0FERztBQUFBLEtBRmUsQ0FBdEI7QUFRQSxXQUNFO0FBQUE7QUFBQTtBQUNHRTtBQURILEtBREY7QUFLRCxHQXhOWTtBQXlOYkksa0JBQWdCekcsU0F6TkgsRUF5TmM7QUFDM0I7QUFDQTBHLDJDQTNOYTtBQTROYkMscUJBQW1CM0csU0E1Tk47QUE2TmI0RyxpQkFBZTVHLFNBN05GO0FBOE5iNkcsb0JBQWtCO0FBQUEsUUFBR3JGLFNBQUgsU0FBR0EsU0FBSDtBQUFBLFFBQWNsRCxPQUFkLFNBQWNBLE9BQWQ7QUFBQSxRQUF1Qm1HLFdBQXZCLFNBQXVCQSxXQUF2QjtBQUFBLFFBQXVDYyxJQUF2Qzs7QUFBQSxXQUNoQjtBQUFBO0FBQUE7QUFDRSxtQkFBVywwQkFBVyxVQUFYLEVBQXVCLEVBQUUsV0FBV2pILE9BQWIsRUFBdkIsRUFBK0NrRCxTQUEvQztBQURiLFNBRU0rRCxJQUZOO0FBSUU7QUFBQTtBQUFBLFVBQUssV0FBVSxnQkFBZjtBQUNHZDtBQURIO0FBSkYsS0FEZ0I7QUFBQSxHQTlOTDtBQXVPYnFDLG1CQUFpQixnQkFBRS9CLHFCQUFGLENBQXdCLFdBQXhCLEVBQXFDLFFBQXJDLENBdk9KO0FBd09iZ0Msb0JBQWtCLGdCQUFFaEMscUJBQUYsQ0FBd0IsWUFBeEIsRUFBc0MsU0FBdEMsQ0F4T0w7QUF5T2JpQyxtQkFBaUI7QUFBQSxXQUFNO0FBQUE7QUFBQTtBQUFBO0FBQUEsS0FBTjtBQUFBO0FBek9KLEMiLCJmaWxlIjoiZGVmYXVsdFByb3BzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IFJlYWN0IGZyb20gJ3JlYWN0J1xuaW1wb3J0IGNsYXNzbmFtZXMgZnJvbSAnY2xhc3NuYW1lcydcbi8vXG5pbXBvcnQgXyBmcm9tICcuL3V0aWxzJ1xuaW1wb3J0IFBhZ2luYXRpb24gZnJvbSAnLi9wYWdpbmF0aW9uJ1xuXG5jb25zdCBlbXB0eU9iaiA9ICgpID0+ICh7fSlcblxuZXhwb3J0IGRlZmF1bHQge1xuICAvLyBHZW5lcmFsXG4gIGRhdGE6IFtdLFxuICBsb2FkaW5nOiBmYWxzZSxcbiAgc2hvd1BhZ2luYXRpb246IHRydWUsXG4gIHNob3dQYWdpbmF0aW9uVG9wOiBmYWxzZSxcbiAgc2hvd1BhZ2luYXRpb25Cb3R0b206IHRydWUsXG4gIHNob3dQYWdlU2l6ZU9wdGlvbnM6IHRydWUsXG4gIHBhZ2VTaXplT3B0aW9uczogWzUsIDEwLCAyMCwgMjUsIDUwLCAxMDBdLFxuICBkZWZhdWx0UGFnZVNpemU6IDIwLFxuICBzaG93UGFnZUp1bXA6IHRydWUsXG4gIGNvbGxhcHNlT25Tb3J0aW5nQ2hhbmdlOiB0cnVlLFxuICBjb2xsYXBzZU9uUGFnZUNoYW5nZTogdHJ1ZSxcbiAgY29sbGFwc2VPbkRhdGFDaGFuZ2U6IHRydWUsXG4gIGZyZWV6ZVdoZW5FeHBhbmRlZDogZmFsc2UsXG4gIHNvcnRhYmxlOiB0cnVlLFxuICByZXNpemFibGU6IHRydWUsXG4gIGZpbHRlcmFibGU6IGZhbHNlLFxuICBkZWZhdWx0U29ydERlc2M6IGZhbHNlLFxuICBkZWZhdWx0U29ydGVkOiBbXSxcbiAgZGVmYXVsdEZpbHRlcmVkOiBbXSxcbiAgZGVmYXVsdFJlc2l6ZWQ6IFtdLFxuICBkZWZhdWx0RXhwYW5kZWQ6IHt9LFxuICBkZWZhdWx0RmlsdGVyTWV0aG9kOiAoZmlsdGVyLCByb3csIGNvbHVtbikgPT4ge1xuICAgIGNvbnN0IGlkID0gZmlsdGVyLnBpdm90SWQgfHwgZmlsdGVyLmlkXG4gICAgcmV0dXJuIHJvd1tpZF0gIT09IHVuZGVmaW5lZFxuICAgICAgPyBTdHJpbmcocm93W2lkXSkuc3RhcnRzV2l0aChmaWx0ZXIudmFsdWUpXG4gICAgICA6IHRydWVcbiAgfSxcbiAgZGVmYXVsdFNvcnRNZXRob2Q6IChhLCBiKSA9PiB7XG4gICAgLy8gZm9yY2UgbnVsbCBhbmQgdW5kZWZpbmVkIHRvIHRoZSBib3R0b21cbiAgICBhID0gYSA9PT0gbnVsbCB8fCBhID09PSB1bmRlZmluZWQgPyAnJyA6IGFcbiAgICBiID0gYiA9PT0gbnVsbCB8fCBiID09PSB1bmRlZmluZWQgPyAnJyA6IGJcbiAgICAvLyBmb3JjZSBhbnkgc3RyaW5nIHZhbHVlcyB0byBsb3dlcmNhc2VcbiAgICBhID0gdHlwZW9mIGEgPT09ICdzdHJpbmcnID8gYS50b0xvd2VyQ2FzZSgpIDogYVxuICAgIGIgPSB0eXBlb2YgYiA9PT0gJ3N0cmluZycgPyBiLnRvTG93ZXJDYXNlKCkgOiBiXG4gICAgLy8gUmV0dXJuIGVpdGhlciAxIG9yIC0xIHRvIGluZGljYXRlIGEgc29ydCBwcmlvcml0eVxuICAgIGlmIChhID4gYikge1xuICAgICAgcmV0dXJuIDFcbiAgICB9XG4gICAgaWYgKGEgPCBiKSB7XG4gICAgICByZXR1cm4gLTFcbiAgICB9XG4gICAgLy8gcmV0dXJuaW5nIDAsIHVuZGVmaW5lZCBvciBhbnkgZmFsc2V5IHZhbHVlIHdpbGwgdXNlIHN1YnNlcXVlbnQgc29ydHMgb3IgdGhlIGluZGV4IGFzIGEgdGllYnJlYWtlclxuICAgIHJldHVybiAwXG4gIH0sXG5cbiAgLy8gQ29udHJvbGxlZCBTdGF0ZSBQcm9wc1xuICAvLyBwYWdlOiB1bmRlZmluZWQsXG4gIC8vIHBhZ2VTaXplOiB1bmRlZmluZWQsXG4gIC8vIHNvcnRlZDogW10sXG4gIC8vIGZpbHRlcmVkOiBbXSxcbiAgLy8gcmVzaXplZDogW10sXG4gIC8vIGV4cGFuZGVkOiB7fSxcblxuICAvLyBDb250cm9sbGVkIFN0YXRlIENhbGxiYWNrc1xuICBvblBhZ2VDaGFuZ2U6IHVuZGVmaW5lZCxcbiAgb25QYWdlU2l6ZUNoYW5nZTogdW5kZWZpbmVkLFxuICBvblNvcnRlZENoYW5nZTogdW5kZWZpbmVkLFxuICBvbkZpbHRlcmVkQ2hhbmdlOiB1bmRlZmluZWQsXG4gIG9uUmVzaXplZENoYW5nZTogdW5kZWZpbmVkLFxuICBvbkV4cGFuZGVkQ2hhbmdlOiB1bmRlZmluZWQsXG5cbiAgLy8gUGl2b3RpbmdcbiAgcGl2b3RCeTogdW5kZWZpbmVkLFxuXG4gIC8vIEtleSBDb25zdGFudHNcbiAgcGl2b3RWYWxLZXk6ICdfcGl2b3RWYWwnLFxuICBwaXZvdElES2V5OiAnX3Bpdm90SUQnLFxuICBzdWJSb3dzS2V5OiAnX3N1YlJvd3MnLFxuICBhZ2dyZWdhdGVkS2V5OiAnX2FnZ3JlZ2F0ZWQnLFxuICBuZXN0aW5nTGV2ZWxLZXk6ICdfbmVzdGluZ0xldmVsJyxcbiAgb3JpZ2luYWxLZXk6ICdfb3JpZ2luYWwnLFxuICBpbmRleEtleTogJ19pbmRleCcsXG4gIGdyb3VwZWRCeVBpdm90S2V5OiAnX2dyb3VwZWRCeVBpdm90JyxcblxuICAvLyBTZXJ2ZXItc2lkZSBDYWxsYmFja3NcbiAgb25GZXRjaERhdGE6ICgpID0+IG51bGwsXG5cbiAgLy8gQ2xhc3Nlc1xuICBjbGFzc05hbWU6ICcnLFxuICBzdHlsZToge30sXG5cbiAgLy8gQ29tcG9uZW50IGRlY29yYXRvcnNcbiAgZ2V0UHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUYWJsZVByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRHcm91cFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRHcm91cFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZEdyb3VwVGhQcm9wczogZW1wdHlPYmosXG4gIGdldFRoZWFkUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZFRoUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZEZpbHRlclByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRGaWx0ZXJUclByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRGaWx0ZXJUaFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGJvZHlQcm9wczogZW1wdHlPYmosXG4gIGdldFRyR3JvdXBQcm9wczogZW1wdHlPYmosXG4gIGdldFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUZFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGZvb3RQcm9wczogZW1wdHlPYmosXG4gIGdldFRmb290VHJQcm9wczogZW1wdHlPYmosXG4gIGdldFRmb290VGRQcm9wczogZW1wdHlPYmosXG4gIGdldFBhZ2luYXRpb25Qcm9wczogZW1wdHlPYmosXG4gIGdldExvYWRpbmdQcm9wczogZW1wdHlPYmosXG4gIGdldE5vRGF0YVByb3BzOiBlbXB0eU9iaixcbiAgZ2V0UmVzaXplclByb3BzOiBlbXB0eU9iaixcblxuICAvLyBHbG9iYWwgQ29sdW1uIERlZmF1bHRzXG4gIGNvbHVtbjoge1xuICAgIC8vIFJlbmRlcmVyc1xuICAgIENlbGw6IHVuZGVmaW5lZCxcbiAgICBIZWFkZXI6IHVuZGVmaW5lZCxcbiAgICBGb290ZXI6IHVuZGVmaW5lZCxcbiAgICBBZ2dyZWdhdGVkOiB1bmRlZmluZWQsXG4gICAgUGl2b3Q6IHVuZGVmaW5lZCxcbiAgICBQaXZvdFZhbHVlOiB1bmRlZmluZWQsXG4gICAgRXhwYW5kZXI6IHVuZGVmaW5lZCxcbiAgICBGaWx0ZXI6IHVuZGVmaW5lZCxcbiAgICAvLyBBbGwgQ29sdW1uc1xuICAgIHNvcnRhYmxlOiB1bmRlZmluZWQsIC8vIHVzZSB0YWJsZSBkZWZhdWx0XG4gICAgcmVzaXphYmxlOiB1bmRlZmluZWQsIC8vIHVzZSB0YWJsZSBkZWZhdWx0XG4gICAgZmlsdGVyYWJsZTogdW5kZWZpbmVkLCAvLyB1c2UgdGFibGUgZGVmYXVsdFxuICAgIHNob3c6IHRydWUsXG4gICAgbWluV2lkdGg6IDEwMCxcbiAgICAvLyBDZWxscyBvbmx5XG4gICAgY2xhc3NOYW1lOiAnJyxcbiAgICBzdHlsZToge30sXG4gICAgZ2V0UHJvcHM6IGVtcHR5T2JqLFxuICAgIC8vIFBpdm90IG9ubHlcbiAgICBhZ2dyZWdhdGU6IHVuZGVmaW5lZCxcbiAgICAvLyBIZWFkZXJzIG9ubHlcbiAgICBoZWFkZXJDbGFzc05hbWU6ICcnLFxuICAgIGhlYWRlclN0eWxlOiB7fSxcbiAgICBnZXRIZWFkZXJQcm9wczogZW1wdHlPYmosXG4gICAgLy8gRm9vdGVycyBvbmx5XG4gICAgZm9vdGVyQ2xhc3NOYW1lOiAnJyxcbiAgICBmb290ZXJTdHlsZToge30sXG4gICAgZ2V0Rm9vdGVyUHJvcHM6IGVtcHR5T2JqLFxuICAgIGZpbHRlck1ldGhvZDogdW5kZWZpbmVkLFxuICAgIGZpbHRlckFsbDogZmFsc2UsXG4gICAgc29ydE1ldGhvZDogdW5kZWZpbmVkLFxuICB9LFxuXG4gIC8vIEdsb2JhbCBFeHBhbmRlciBDb2x1bW4gRGVmYXVsdHNcbiAgZXhwYW5kZXJEZWZhdWx0czoge1xuICAgIHNvcnRhYmxlOiBmYWxzZSxcbiAgICByZXNpemFibGU6IGZhbHNlLFxuICAgIGZpbHRlcmFibGU6IGZhbHNlLFxuICAgIHdpZHRoOiAzNSxcbiAgfSxcblxuICBwaXZvdERlZmF1bHRzOiB7XG4gICAgLy8gZXh0ZW5kIHRoZSBkZWZhdWx0cyBmb3IgcGl2b3RlZCBjb2x1bW5zIGhlcmVcbiAgfSxcblxuICAvLyBUZXh0XG4gIHByZXZpb3VzVGV4dDogJ1ByZXZpb3VzJyxcbiAgbmV4dFRleHQ6ICdOZXh0JyxcbiAgbG9hZGluZ1RleHQ6ICdMb2FkaW5nLi4uJyxcbiAgbm9EYXRhVGV4dDogJ05vIHJvd3MgZm91bmQnLFxuICBwYWdlVGV4dDogJ1BhZ2UnLFxuICBvZlRleHQ6ICdvZicsXG4gIHJvd3NUZXh0OiAncm93cycsXG5cbiAgLy8gQ29tcG9uZW50c1xuICBUYWJsZUNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXRhYmxlJywgJ1RhYmxlJyksXG4gIFRoZWFkQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdGhlYWQnLCAnVGhlYWQnKSxcbiAgVGJvZHlDb21wb25lbnQ6IF8ubWFrZVRlbXBsYXRlQ29tcG9uZW50KCdydC10Ym9keScsICdUYm9keScpLFxuICBUckdyb3VwQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdHItZ3JvdXAnLCAnVHJHcm91cCcpLFxuICBUckNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXRyJywgJ1RyJyksXG4gIFRoQ29tcG9uZW50OiAoeyB0b2dnbGVTb3J0LCBjbGFzc05hbWUsIGNoaWxkcmVuLCAuLi5yZXN0IH0pID0+IHtcbiAgICByZXR1cm4gKFxuICAgICAgPGRpdlxuICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NOYW1lLCAncnQtdGgnKX1cbiAgICAgICAgb25DbGljaz17ZSA9PiB7XG4gICAgICAgICAgdG9nZ2xlU29ydCAmJiB0b2dnbGVTb3J0KGUpXG4gICAgICAgIH19XG4gICAgICAgIHsuLi5yZXN0fVxuICAgICAgPlxuICAgICAgICB7Y2hpbGRyZW59XG4gICAgICA8L2Rpdj5cbiAgICApXG4gIH0sXG4gIFRkQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdGQnLCAnVGQnKSxcbiAgVGZvb3RDb21wb25lbnQ6IF8ubWFrZVRlbXBsYXRlQ29tcG9uZW50KCdydC10Zm9vdCcsICdUZm9vdCcpLFxuICBGaWx0ZXJDb21wb25lbnQ6ICh7IGZpbHRlciwgb25DaGFuZ2UgfSkgPT5cbiAgICA8aW5wdXRcbiAgICAgIHR5cGU9J3RleHQnXG4gICAgICBzdHlsZT17e1xuICAgICAgICB3aWR0aDogJzEwMCUnLFxuICAgICAgfX1cbiAgICAgIHZhbHVlPXtmaWx0ZXIgPyBmaWx0ZXIudmFsdWUgOiAnJ31cbiAgICAgIG9uQ2hhbmdlPXtldmVudCA9PiBvbkNoYW5nZShldmVudC50YXJnZXQudmFsdWUpfVxuICAgIC8+LFxuICBFeHBhbmRlckNvbXBvbmVudDogKHsgaXNFeHBhbmRlZCB9KSA9PlxuICAgIDxkaXYgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCdydC1leHBhbmRlcicsIGlzRXhwYW5kZWQgJiYgJy1vcGVuJyl9PlxuICAgICAgJmJ1bGw7XG4gICAgPC9kaXY+LFxuICBQaXZvdFZhbHVlQ29tcG9uZW50OiAoeyBzdWJSb3dzLCB2YWx1ZSB9KSA9PlxuICAgIDxzcGFuPlxuICAgICAge3ZhbHVlfSB7c3ViUm93cyAmJiBgKCR7c3ViUm93cy5sZW5ndGh9KWB9XG4gICAgPC9zcGFuPixcbiAgQWdncmVnYXRlZENvbXBvbmVudDogKHsgc3ViUm93cywgY29sdW1uIH0pID0+IHtcbiAgICBjb25zdCBwcmV2aWV3VmFsdWVzID0gc3ViUm93c1xuICAgICAgLmZpbHRlcihkID0+IHR5cGVvZiBkW2NvbHVtbi5pZF0gIT09ICd1bmRlZmluZWQnKVxuICAgICAgLm1hcCgocm93LCBpKSA9PlxuICAgICAgICA8c3BhbiBrZXk9e2l9PlxuICAgICAgICAgIHtyb3dbY29sdW1uLmlkXX1cbiAgICAgICAgICB7aSA8IHN1YlJvd3MubGVuZ3RoIC0gMSA/ICcsICcgOiAnJ31cbiAgICAgICAgPC9zcGFuPlxuICAgICAgKVxuICAgIHJldHVybiAoXG4gICAgICA8c3Bhbj5cbiAgICAgICAge3ByZXZpZXdWYWx1ZXN9XG4gICAgICA8L3NwYW4+XG4gICAgKVxuICB9LFxuICBQaXZvdENvbXBvbmVudDogdW5kZWZpbmVkLCAvLyB0aGlzIGlzIGEgY29tcHV0ZWQgZGVmYXVsdCBnZW5lcmF0ZWQgdXNpbmdcbiAgLy8gdGhlIEV4cGFuZGVyQ29tcG9uZW50IGFuZCBQaXZvdFZhbHVlQ29tcG9uZW50IGF0IHJ1bi10aW1lIGluIG1ldGhvZHMuanNcbiAgUGFnaW5hdGlvbkNvbXBvbmVudDogUGFnaW5hdGlvbixcbiAgUHJldmlvdXNDb21wb25lbnQ6IHVuZGVmaW5lZCxcbiAgTmV4dENvbXBvbmVudDogdW5kZWZpbmVkLFxuICBMb2FkaW5nQ29tcG9uZW50OiAoeyBjbGFzc05hbWUsIGxvYWRpbmcsIGxvYWRpbmdUZXh0LCAuLi5yZXN0IH0pID0+XG4gICAgPGRpdlxuICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCctbG9hZGluZycsIHsgJy1hY3RpdmUnOiBsb2FkaW5nIH0sIGNsYXNzTmFtZSl9XG4gICAgICB7Li4ucmVzdH1cbiAgICA+XG4gICAgICA8ZGl2IGNsYXNzTmFtZT0nLWxvYWRpbmctaW5uZXInPlxuICAgICAgICB7bG9hZGluZ1RleHR9XG4gICAgICA8L2Rpdj5cbiAgICA8L2Rpdj4sXG4gIE5vRGF0YUNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LW5vRGF0YScsICdOb0RhdGEnKSxcbiAgUmVzaXplckNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXJlc2l6ZXInLCAnUmVzaXplcicpLFxuICBQYWRSb3dDb21wb25lbnQ6ICgpID0+IDxzcGFuPiZuYnNwOzwvc3Bhbj4sXG59XG4iXX0= + +/***/ }), +/* 362 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _classnames = __webpack_require__(41); + +var _classnames2 = _interopRequireDefault(_classnames); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +// +// import _ from './utils' + +var defaultButton = function defaultButton(props) { + return _react2.default.createElement( + 'button', + _extends({ type: 'button' }, props, { className: '-btn' }), + props.children + ); +}; + +var ReactTablePagination = function (_Component) { + _inherits(ReactTablePagination, _Component); + + function ReactTablePagination(props) { + _classCallCheck(this, ReactTablePagination); + + var _this = _possibleConstructorReturn(this, (ReactTablePagination.__proto__ || Object.getPrototypeOf(ReactTablePagination)).call(this)); + + _this.getSafePage = _this.getSafePage.bind(_this); + _this.changePage = _this.changePage.bind(_this); + _this.applyPage = _this.applyPage.bind(_this); + + _this.state = { + page: props.page + }; + return _this; + } + + _createClass(ReactTablePagination, [{ + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + this.setState({ page: nextProps.page }); + } + }, { + key: 'getSafePage', + value: function getSafePage(page) { + if (isNaN(page)) { + page = this.props.page; + } + return Math.min(Math.max(page, 0), this.props.pages - 1); + } + }, { + key: 'changePage', + value: function changePage(page) { + page = this.getSafePage(page); + this.setState({ page: page }); + if (this.props.page !== page) { + this.props.onPageChange(page); + } + } + }, { + key: 'applyPage', + value: function applyPage(e) { + e && e.preventDefault(); + var page = this.state.page; + this.changePage(page === '' ? this.props.page : page); + } + }, { + key: 'render', + value: function render() { + var _this2 = this; + + var _props = this.props, + pages = _props.pages, + page = _props.page, + showPageSizeOptions = _props.showPageSizeOptions, + pageSizeOptions = _props.pageSizeOptions, + pageSize = _props.pageSize, + showPageJump = _props.showPageJump, + canPrevious = _props.canPrevious, + canNext = _props.canNext, + onPageSizeChange = _props.onPageSizeChange, + className = _props.className, + _props$PreviousCompon = _props.PreviousComponent, + PreviousComponent = _props$PreviousCompon === undefined ? defaultButton : _props$PreviousCompon, + _props$NextComponent = _props.NextComponent, + NextComponent = _props$NextComponent === undefined ? defaultButton : _props$NextComponent; + + + return _react2.default.createElement( + 'div', + { + className: (0, _classnames2.default)(className, '-pagination'), + style: this.props.paginationStyle + }, + _react2.default.createElement( + 'div', + { className: '-previous' }, + _react2.default.createElement( + PreviousComponent, + { + onClick: function onClick(e) { + if (!canPrevious) return; + _this2.changePage(page - 1); + }, + disabled: !canPrevious + }, + this.props.previousText + ) + ), + _react2.default.createElement( + 'div', + { className: '-center' }, + _react2.default.createElement( + 'span', + { className: '-pageInfo' }, + this.props.pageText, + ' ', + showPageJump ? _react2.default.createElement( + 'div', + { className: '-pageJump' }, + _react2.default.createElement('input', { + type: this.state.page === '' ? 'text' : 'number', + onChange: function onChange(e) { + var val = e.target.value; + var page = val - 1; + if (val === '') { + return _this2.setState({ page: val }); + } + _this2.setState({ page: _this2.getSafePage(page) }); + }, + value: this.state.page === '' ? '' : this.state.page + 1, + onBlur: this.applyPage, + onKeyPress: function onKeyPress(e) { + if (e.which === 13 || e.keyCode === 13) { + _this2.applyPage(); + } + } + }) + ) : _react2.default.createElement( + 'span', + { className: '-currentPage' }, + page + 1 + ), + ' ', + this.props.ofText, + ' ', + _react2.default.createElement( + 'span', + { className: '-totalPages' }, + pages || 1 + ) + ), + showPageSizeOptions && _react2.default.createElement( + 'span', + { className: 'select-wrap -pageSizeOptions' }, + _react2.default.createElement( + 'select', + { + onChange: function onChange(e) { + return onPageSizeChange(Number(e.target.value)); + }, + value: pageSize + }, + pageSizeOptions.map(function (option, i) { + return _react2.default.createElement( + 'option', + { key: i, value: option }, + option, + ' ', + _this2.props.rowsText + ); + }) + ) + ) + ), + _react2.default.createElement( + 'div', + { className: '-next' }, + _react2.default.createElement( + NextComponent, + { + onClick: function onClick(e) { + if (!canNext) return; + _this2.changePage(page + 1); + }, + disabled: !canNext + }, + this.props.nextText + ) + ) + ); + } + }]); + + return ReactTablePagination; +}(_react.Component); + +exports.default = ReactTablePagination; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9wYWdpbmF0aW9uLmpzIl0sIm5hbWVzIjpbImRlZmF1bHRCdXR0b24iLCJwcm9wcyIsImNoaWxkcmVuIiwiUmVhY3RUYWJsZVBhZ2luYXRpb24iLCJnZXRTYWZlUGFnZSIsImJpbmQiLCJjaGFuZ2VQYWdlIiwiYXBwbHlQYWdlIiwic3RhdGUiLCJwYWdlIiwibmV4dFByb3BzIiwic2V0U3RhdGUiLCJpc05hTiIsIk1hdGgiLCJtaW4iLCJtYXgiLCJwYWdlcyIsIm9uUGFnZUNoYW5nZSIsImUiLCJwcmV2ZW50RGVmYXVsdCIsInNob3dQYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZSIsInNob3dQYWdlSnVtcCIsImNhblByZXZpb3VzIiwiY2FuTmV4dCIsIm9uUGFnZVNpemVDaGFuZ2UiLCJjbGFzc05hbWUiLCJQcmV2aW91c0NvbXBvbmVudCIsIk5leHRDb21wb25lbnQiLCJwYWdpbmF0aW9uU3R5bGUiLCJwcmV2aW91c1RleHQiLCJwYWdlVGV4dCIsInZhbCIsInRhcmdldCIsInZhbHVlIiwid2hpY2giLCJrZXlDb2RlIiwib2ZUZXh0IiwiTnVtYmVyIiwibWFwIiwib3B0aW9uIiwiaSIsInJvd3NUZXh0IiwibmV4dFRleHQiXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7Ozs7Ozs7Ozs7QUFDQTtBQUNBOztBQUVBLElBQU1BLGdCQUFnQixTQUFoQkEsYUFBZ0I7QUFBQSxTQUNwQjtBQUFBO0FBQUEsZUFBUSxNQUFLLFFBQWIsSUFBMEJDLEtBQTFCLElBQWlDLFdBQVUsTUFBM0M7QUFDR0EsVUFBTUM7QUFEVCxHQURvQjtBQUFBLENBQXRCOztJQUtxQkMsb0I7OztBQUNuQixnQ0FBYUYsS0FBYixFQUFvQjtBQUFBOztBQUFBOztBQUdsQixVQUFLRyxXQUFMLEdBQW1CLE1BQUtBLFdBQUwsQ0FBaUJDLElBQWpCLE9BQW5CO0FBQ0EsVUFBS0MsVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCRCxJQUFoQixPQUFsQjtBQUNBLFVBQUtFLFNBQUwsR0FBaUIsTUFBS0EsU0FBTCxDQUFlRixJQUFmLE9BQWpCOztBQUVBLFVBQUtHLEtBQUwsR0FBYTtBQUNYQyxZQUFNUixNQUFNUTtBQURELEtBQWI7QUFQa0I7QUFVbkI7Ozs7OENBRTBCQyxTLEVBQVc7QUFDcEMsV0FBS0MsUUFBTCxDQUFjLEVBQUVGLE1BQU1DLFVBQVVELElBQWxCLEVBQWQ7QUFDRDs7O2dDQUVZQSxJLEVBQU07QUFDakIsVUFBSUcsTUFBTUgsSUFBTixDQUFKLEVBQWlCO0FBQ2ZBLGVBQU8sS0FBS1IsS0FBTCxDQUFXUSxJQUFsQjtBQUNEO0FBQ0QsYUFBT0ksS0FBS0MsR0FBTCxDQUFTRCxLQUFLRSxHQUFMLENBQVNOLElBQVQsRUFBZSxDQUFmLENBQVQsRUFBNEIsS0FBS1IsS0FBTCxDQUFXZSxLQUFYLEdBQW1CLENBQS9DLENBQVA7QUFDRDs7OytCQUVXUCxJLEVBQU07QUFDaEJBLGFBQU8sS0FBS0wsV0FBTCxDQUFpQkssSUFBakIsQ0FBUDtBQUNBLFdBQUtFLFFBQUwsQ0FBYyxFQUFFRixVQUFGLEVBQWQ7QUFDQSxVQUFJLEtBQUtSLEtBQUwsQ0FBV1EsSUFBWCxLQUFvQkEsSUFBeEIsRUFBOEI7QUFDNUIsYUFBS1IsS0FBTCxDQUFXZ0IsWUFBWCxDQUF3QlIsSUFBeEI7QUFDRDtBQUNGOzs7OEJBRVVTLEMsRUFBRztBQUNaQSxXQUFLQSxFQUFFQyxjQUFGLEVBQUw7QUFDQSxVQUFNVixPQUFPLEtBQUtELEtBQUwsQ0FBV0MsSUFBeEI7QUFDQSxXQUFLSCxVQUFMLENBQWdCRyxTQUFTLEVBQVQsR0FBYyxLQUFLUixLQUFMLENBQVdRLElBQXpCLEdBQWdDQSxJQUFoRDtBQUNEOzs7NkJBRVM7QUFBQTs7QUFBQSxtQkFnQkosS0FBS1IsS0FoQkQ7QUFBQSxVQUdOZSxLQUhNLFVBR05BLEtBSE07QUFBQSxVQUtOUCxJQUxNLFVBS05BLElBTE07QUFBQSxVQU1OVyxtQkFOTSxVQU1OQSxtQkFOTTtBQUFBLFVBT05DLGVBUE0sVUFPTkEsZUFQTTtBQUFBLFVBUU5DLFFBUk0sVUFRTkEsUUFSTTtBQUFBLFVBU05DLFlBVE0sVUFTTkEsWUFUTTtBQUFBLFVBVU5DLFdBVk0sVUFVTkEsV0FWTTtBQUFBLFVBV05DLE9BWE0sVUFXTkEsT0FYTTtBQUFBLFVBWU5DLGdCQVpNLFVBWU5BLGdCQVpNO0FBQUEsVUFhTkMsU0FiTSxVQWFOQSxTQWJNO0FBQUEseUNBY05DLGlCQWRNO0FBQUEsVUFjTkEsaUJBZE0seUNBY2M1QixhQWRkO0FBQUEsd0NBZU42QixhQWZNO0FBQUEsVUFlTkEsYUFmTSx3Q0FlVTdCLGFBZlY7OztBQWtCUixhQUNFO0FBQUE7QUFBQTtBQUNFLHFCQUFXLDBCQUFXMkIsU0FBWCxFQUFzQixhQUF0QixDQURiO0FBRUUsaUJBQU8sS0FBSzFCLEtBQUwsQ0FBVzZCO0FBRnBCO0FBSUU7QUFBQTtBQUFBLFlBQUssV0FBVSxXQUFmO0FBQ0U7QUFBQyw2QkFBRDtBQUFBO0FBQ0UsdUJBQVMsb0JBQUs7QUFDWixvQkFBSSxDQUFDTixXQUFMLEVBQWtCO0FBQ2xCLHVCQUFLbEIsVUFBTCxDQUFnQkcsT0FBTyxDQUF2QjtBQUNELGVBSkg7QUFLRSx3QkFBVSxDQUFDZTtBQUxiO0FBT0csaUJBQUt2QixLQUFMLENBQVc4QjtBQVBkO0FBREYsU0FKRjtBQWVFO0FBQUE7QUFBQSxZQUFLLFdBQVUsU0FBZjtBQUNFO0FBQUE7QUFBQSxjQUFNLFdBQVUsV0FBaEI7QUFDRyxpQkFBSzlCLEtBQUwsQ0FBVytCLFFBRGQ7QUFDd0IsZUFEeEI7QUFFR1QsMkJBQ0c7QUFBQTtBQUFBLGdCQUFLLFdBQVUsV0FBZjtBQUNBO0FBQ0Usc0JBQU0sS0FBS2YsS0FBTCxDQUFXQyxJQUFYLEtBQW9CLEVBQXBCLEdBQXlCLE1BQXpCLEdBQWtDLFFBRDFDO0FBRUUsMEJBQVUscUJBQUs7QUFDYixzQkFBTXdCLE1BQU1mLEVBQUVnQixNQUFGLENBQVNDLEtBQXJCO0FBQ0Esc0JBQU0xQixPQUFPd0IsTUFBTSxDQUFuQjtBQUNBLHNCQUFJQSxRQUFRLEVBQVosRUFBZ0I7QUFDZCwyQkFBTyxPQUFLdEIsUUFBTCxDQUFjLEVBQUVGLE1BQU13QixHQUFSLEVBQWQsQ0FBUDtBQUNEO0FBQ0QseUJBQUt0QixRQUFMLENBQWMsRUFBRUYsTUFBTSxPQUFLTCxXQUFMLENBQWlCSyxJQUFqQixDQUFSLEVBQWQ7QUFDRCxpQkFUSDtBQVVFLHVCQUFPLEtBQUtELEtBQUwsQ0FBV0MsSUFBWCxLQUFvQixFQUFwQixHQUF5QixFQUF6QixHQUE4QixLQUFLRCxLQUFMLENBQVdDLElBQVgsR0FBa0IsQ0FWekQ7QUFXRSx3QkFBUSxLQUFLRixTQVhmO0FBWUUsNEJBQVksdUJBQUs7QUFDZixzQkFBSVcsRUFBRWtCLEtBQUYsS0FBWSxFQUFaLElBQWtCbEIsRUFBRW1CLE9BQUYsS0FBYyxFQUFwQyxFQUF3QztBQUN0QywyQkFBSzlCLFNBQUw7QUFDRDtBQUNGO0FBaEJIO0FBREEsYUFESCxHQXFCRztBQUFBO0FBQUEsZ0JBQU0sV0FBVSxjQUFoQjtBQUNDRSxxQkFBTztBQURSLGFBdkJOO0FBeUJhLGVBekJiO0FBMEJHLGlCQUFLUixLQUFMLENBQVdxQyxNQTFCZDtBQTBCc0IsZUExQnRCO0FBMkJFO0FBQUE7QUFBQSxnQkFBTSxXQUFVLGFBQWhCO0FBQStCdEIsdUJBQVM7QUFBeEM7QUEzQkYsV0FERjtBQThCR0ksaUNBQ0M7QUFBQTtBQUFBLGNBQU0sV0FBVSw4QkFBaEI7QUFDRTtBQUFBO0FBQUE7QUFDRSwwQkFBVTtBQUFBLHlCQUFLTSxpQkFBaUJhLE9BQU9yQixFQUFFZ0IsTUFBRixDQUFTQyxLQUFoQixDQUFqQixDQUFMO0FBQUEsaUJBRFo7QUFFRSx1QkFBT2I7QUFGVDtBQUlHRCw4QkFBZ0JtQixHQUFoQixDQUFvQixVQUFDQyxNQUFELEVBQVNDLENBQVQsRUFBZTtBQUNsQyx1QkFDRTtBQUFBO0FBQUEsb0JBQVEsS0FBS0EsQ0FBYixFQUFnQixPQUFPRCxNQUF2QjtBQUNHQSx3QkFESDtBQUFBO0FBQ1kseUJBQUt4QyxLQUFMLENBQVcwQztBQUR2QixpQkFERjtBQUtELGVBTkE7QUFKSDtBQURGO0FBL0JKLFNBZkY7QUE2REU7QUFBQTtBQUFBLFlBQUssV0FBVSxPQUFmO0FBQ0U7QUFBQyx5QkFBRDtBQUFBO0FBQ0UsdUJBQVMsb0JBQUs7QUFDWixvQkFBSSxDQUFDbEIsT0FBTCxFQUFjO0FBQ2QsdUJBQUtuQixVQUFMLENBQWdCRyxPQUFPLENBQXZCO0FBQ0QsZUFKSDtBQUtFLHdCQUFVLENBQUNnQjtBQUxiO0FBT0csaUJBQUt4QixLQUFMLENBQVcyQztBQVBkO0FBREY7QUE3REYsT0FERjtBQTJFRDs7Ozs7O2tCQW5Ja0J6QyxvQiIsImZpbGUiOiJwYWdpbmF0aW9uLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IFJlYWN0LCB7IENvbXBvbmVudCB9IGZyb20gJ3JlYWN0J1xuaW1wb3J0IGNsYXNzbmFtZXMgZnJvbSAnY2xhc3NuYW1lcydcbi8vXG4vLyBpbXBvcnQgXyBmcm9tICcuL3V0aWxzJ1xuXG5jb25zdCBkZWZhdWx0QnV0dG9uID0gcHJvcHMgPT5cbiAgPGJ1dHRvbiB0eXBlPSdidXR0b24nIHsuLi5wcm9wc30gY2xhc3NOYW1lPSctYnRuJz5cbiAgICB7cHJvcHMuY2hpbGRyZW59XG4gIDwvYnV0dG9uPlxuXG5leHBvcnQgZGVmYXVsdCBjbGFzcyBSZWFjdFRhYmxlUGFnaW5hdGlvbiBleHRlbmRzIENvbXBvbmVudCB7XG4gIGNvbnN0cnVjdG9yIChwcm9wcykge1xuICAgIHN1cGVyKClcblxuICAgIHRoaXMuZ2V0U2FmZVBhZ2UgPSB0aGlzLmdldFNhZmVQYWdlLmJpbmQodGhpcylcbiAgICB0aGlzLmNoYW5nZVBhZ2UgPSB0aGlzLmNoYW5nZVBhZ2UuYmluZCh0aGlzKVxuICAgIHRoaXMuYXBwbHlQYWdlID0gdGhpcy5hcHBseVBhZ2UuYmluZCh0aGlzKVxuXG4gICAgdGhpcy5zdGF0ZSA9IHtcbiAgICAgIHBhZ2U6IHByb3BzLnBhZ2UsXG4gICAgfVxuICB9XG5cbiAgY29tcG9uZW50V2lsbFJlY2VpdmVQcm9wcyAobmV4dFByb3BzKSB7XG4gICAgdGhpcy5zZXRTdGF0ZSh7IHBhZ2U6IG5leHRQcm9wcy5wYWdlIH0pXG4gIH1cblxuICBnZXRTYWZlUGFnZSAocGFnZSkge1xuICAgIGlmIChpc05hTihwYWdlKSkge1xuICAgICAgcGFnZSA9IHRoaXMucHJvcHMucGFnZVxuICAgIH1cbiAgICByZXR1cm4gTWF0aC5taW4oTWF0aC5tYXgocGFnZSwgMCksIHRoaXMucHJvcHMucGFnZXMgLSAxKVxuICB9XG5cbiAgY2hhbmdlUGFnZSAocGFnZSkge1xuICAgIHBhZ2UgPSB0aGlzLmdldFNhZmVQYWdlKHBhZ2UpXG4gICAgdGhpcy5zZXRTdGF0ZSh7IHBhZ2UgfSlcbiAgICBpZiAodGhpcy5wcm9wcy5wYWdlICE9PSBwYWdlKSB7XG4gICAgICB0aGlzLnByb3BzLm9uUGFnZUNoYW5nZShwYWdlKVxuICAgIH1cbiAgfVxuXG4gIGFwcGx5UGFnZSAoZSkge1xuICAgIGUgJiYgZS5wcmV2ZW50RGVmYXVsdCgpXG4gICAgY29uc3QgcGFnZSA9IHRoaXMuc3RhdGUucGFnZVxuICAgIHRoaXMuY2hhbmdlUGFnZShwYWdlID09PSAnJyA/IHRoaXMucHJvcHMucGFnZSA6IHBhZ2UpXG4gIH1cblxuICByZW5kZXIgKCkge1xuICAgIGNvbnN0IHtcbiAgICAgIC8vIENvbXB1dGVkXG4gICAgICBwYWdlcyxcbiAgICAgIC8vIFByb3BzXG4gICAgICBwYWdlLFxuICAgICAgc2hvd1BhZ2VTaXplT3B0aW9ucyxcbiAgICAgIHBhZ2VTaXplT3B0aW9ucyxcbiAgICAgIHBhZ2VTaXplLFxuICAgICAgc2hvd1BhZ2VKdW1wLFxuICAgICAgY2FuUHJldmlvdXMsXG4gICAgICBjYW5OZXh0LFxuICAgICAgb25QYWdlU2l6ZUNoYW5nZSxcbiAgICAgIGNsYXNzTmFtZSxcbiAgICAgIFByZXZpb3VzQ29tcG9uZW50ID0gZGVmYXVsdEJ1dHRvbixcbiAgICAgIE5leHRDb21wb25lbnQgPSBkZWZhdWx0QnV0dG9uLFxuICAgIH0gPSB0aGlzLnByb3BzXG5cbiAgICByZXR1cm4gKFxuICAgICAgPGRpdlxuICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NOYW1lLCAnLXBhZ2luYXRpb24nKX1cbiAgICAgICAgc3R5bGU9e3RoaXMucHJvcHMucGFnaW5hdGlvblN0eWxlfVxuICAgICAgPlxuICAgICAgICA8ZGl2IGNsYXNzTmFtZT0nLXByZXZpb3VzJz5cbiAgICAgICAgICA8UHJldmlvdXNDb21wb25lbnRcbiAgICAgICAgICAgIG9uQ2xpY2s9e2UgPT4ge1xuICAgICAgICAgICAgICBpZiAoIWNhblByZXZpb3VzKSByZXR1cm5cbiAgICAgICAgICAgICAgdGhpcy5jaGFuZ2VQYWdlKHBhZ2UgLSAxKVxuICAgICAgICAgICAgfX1cbiAgICAgICAgICAgIGRpc2FibGVkPXshY2FuUHJldmlvdXN9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge3RoaXMucHJvcHMucHJldmlvdXNUZXh0fVxuICAgICAgICAgIDwvUHJldmlvdXNDb21wb25lbnQ+XG4gICAgICAgIDwvZGl2PlxuICAgICAgICA8ZGl2IGNsYXNzTmFtZT0nLWNlbnRlcic+XG4gICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSctcGFnZUluZm8nPlxuICAgICAgICAgICAge3RoaXMucHJvcHMucGFnZVRleHR9eycgJ31cbiAgICAgICAgICAgIHtzaG93UGFnZUp1bXBcbiAgICAgICAgICAgICAgPyA8ZGl2IGNsYXNzTmFtZT0nLXBhZ2VKdW1wJz5cbiAgICAgICAgICAgICAgICA8aW5wdXRcbiAgICAgICAgICAgICAgICAgIHR5cGU9e3RoaXMuc3RhdGUucGFnZSA9PT0gJycgPyAndGV4dCcgOiAnbnVtYmVyJ31cbiAgICAgICAgICAgICAgICAgIG9uQ2hhbmdlPXtlID0+IHtcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgdmFsID0gZS50YXJnZXQudmFsdWVcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgcGFnZSA9IHZhbCAtIDFcbiAgICAgICAgICAgICAgICAgICAgaWYgKHZhbCA9PT0gJycpIHtcbiAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdGhpcy5zZXRTdGF0ZSh7IHBhZ2U6IHZhbCB9KVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuc2V0U3RhdGUoeyBwYWdlOiB0aGlzLmdldFNhZmVQYWdlKHBhZ2UpIH0pXG4gICAgICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICAgICAgdmFsdWU9e3RoaXMuc3RhdGUucGFnZSA9PT0gJycgPyAnJyA6IHRoaXMuc3RhdGUucGFnZSArIDF9XG4gICAgICAgICAgICAgICAgICBvbkJsdXI9e3RoaXMuYXBwbHlQYWdlfVxuICAgICAgICAgICAgICAgICAgb25LZXlQcmVzcz17ZSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChlLndoaWNoID09PSAxMyB8fCBlLmtleUNvZGUgPT09IDEzKSB7XG4gICAgICAgICAgICAgICAgICAgICAgdGhpcy5hcHBseVBhZ2UoKVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICAgIC8+XG4gICAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgICAgICA6IDxzcGFuIGNsYXNzTmFtZT0nLWN1cnJlbnRQYWdlJz5cbiAgICAgICAgICAgICAgICB7cGFnZSArIDF9XG4gICAgICAgICAgICAgIDwvc3Bhbj59eycgJ31cbiAgICAgICAgICAgIHt0aGlzLnByb3BzLm9mVGV4dH17JyAnfVxuICAgICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSctdG90YWxQYWdlcyc+e3BhZ2VzIHx8IDF9PC9zcGFuPlxuICAgICAgICAgIDwvc3Bhbj5cbiAgICAgICAgICB7c2hvd1BhZ2VTaXplT3B0aW9ucyAmJlxuICAgICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSdzZWxlY3Qtd3JhcCAtcGFnZVNpemVPcHRpb25zJz5cbiAgICAgICAgICAgICAgPHNlbGVjdFxuICAgICAgICAgICAgICAgIG9uQ2hhbmdlPXtlID0+IG9uUGFnZVNpemVDaGFuZ2UoTnVtYmVyKGUudGFyZ2V0LnZhbHVlKSl9XG4gICAgICAgICAgICAgICAgdmFsdWU9e3BhZ2VTaXplfVxuICAgICAgICAgICAgICA+XG4gICAgICAgICAgICAgICAge3BhZ2VTaXplT3B0aW9ucy5tYXAoKG9wdGlvbiwgaSkgPT4ge1xuICAgICAgICAgICAgICAgICAgcmV0dXJuIChcbiAgICAgICAgICAgICAgICAgICAgPG9wdGlvbiBrZXk9e2l9IHZhbHVlPXtvcHRpb259PlxuICAgICAgICAgICAgICAgICAgICAgIHtvcHRpb259IHt0aGlzLnByb3BzLnJvd3NUZXh0fVxuICAgICAgICAgICAgICAgICAgICA8L29wdGlvbj5cbiAgICAgICAgICAgICAgICAgIClcbiAgICAgICAgICAgICAgICB9KX1cbiAgICAgICAgICAgICAgPC9zZWxlY3Q+XG4gICAgICAgICAgICA8L3NwYW4+fVxuICAgICAgICA8L2Rpdj5cbiAgICAgICAgPGRpdiBjbGFzc05hbWU9Jy1uZXh0Jz5cbiAgICAgICAgICA8TmV4dENvbXBvbmVudFxuICAgICAgICAgICAgb25DbGljaz17ZSA9PiB7XG4gICAgICAgICAgICAgIGlmICghY2FuTmV4dCkgcmV0dXJuXG4gICAgICAgICAgICAgIHRoaXMuY2hhbmdlUGFnZShwYWdlICsgMSlcbiAgICAgICAgICAgIH19XG4gICAgICAgICAgICBkaXNhYmxlZD17IWNhbk5leHR9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge3RoaXMucHJvcHMubmV4dFRleHR9XG4gICAgICAgICAgPC9OZXh0Q29tcG9uZW50PlxuICAgICAgICA8L2Rpdj5cbiAgICAgIDwvZGl2PlxuICAgIClcbiAgfVxufVxuIl19 + +/***/ }), +/* 363 */ +/***/ (function(module, exports, __webpack_require__) { + +var basex = __webpack_require__(364) +var ALPHABET = '123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz' + +module.exports = basex(ALPHABET) + + +/***/ }), +/* 364 */ +/***/ (function(module, exports, __webpack_require__) { + +// base-x encoding +// Forked from https://github.com/cryptocoinjs/bs58 +// Originally written by Mike Hearn for BitcoinJ +// Copyright (c) 2011 Google Inc +// Ported to JavaScript by Stefan Thomas +// Merged Buffer refactorings from base58-native by Stephen Pair +// Copyright (c) 2013 BitPay Inc + +var Buffer = __webpack_require__(7).Buffer + +module.exports = function base (ALPHABET) { + var ALPHABET_MAP = {} + var BASE = ALPHABET.length + var LEADER = ALPHABET.charAt(0) + + // pre-compute lookup table + for (var z = 0; z < ALPHABET.length; z++) { + var x = ALPHABET.charAt(z) + + if (ALPHABET_MAP[x] !== undefined) throw new TypeError(x + ' is ambiguous') + ALPHABET_MAP[x] = z + } + + function encode (source) { + if (source.length === 0) return '' + + var digits = [0] + for (var i = 0; i < source.length; ++i) { + for (var j = 0, carry = source[i]; j < digits.length; ++j) { + carry += digits[j] << 8 + digits[j] = carry % BASE + carry = (carry / BASE) | 0 + } + + while (carry > 0) { + digits.push(carry % BASE) + carry = (carry / BASE) | 0 + } + } + + var string = '' + + // deal with leading zeros + for (var k = 0; source[k] === 0 && k < source.length - 1; ++k) string += ALPHABET[0] + // convert digits to a string + for (var q = digits.length - 1; q >= 0; --q) string += ALPHABET[digits[q]] + + return string + } + + function decodeUnsafe (string) { + if (string.length === 0) return Buffer.allocUnsafe(0) + + var bytes = [0] + for (var i = 0; i < string.length; i++) { + var value = ALPHABET_MAP[string[i]] + if (value === undefined) return + + for (var j = 0, carry = value; j < bytes.length; ++j) { + carry += bytes[j] * BASE + bytes[j] = carry & 0xff + carry >>= 8 + } + + while (carry > 0) { + bytes.push(carry & 0xff) + carry >>= 8 + } + } + + // deal with leading zeros + for (var k = 0; string[k] === LEADER && k < string.length - 1; ++k) { + bytes.push(0) + } + + return Buffer.from(bytes.reverse()) + } + + function decode (string) { + var buffer = decodeUnsafe(string) + if (buffer) return buffer + + throw new Error('Non-base' + BASE + ' character') + } + + return { + encode: encode, + decodeUnsafe: decodeUnsafe, + decode: decode + } +} + + +/***/ }), +/* 365 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var intSize = 4 +var zeroBuffer = new Buffer(intSize) +zeroBuffer.fill(0) + +var charSize = 8 +var hashSize = 16 + +function toArray (buf) { + if ((buf.length % intSize) !== 0) { + var len = buf.length + (intSize - (buf.length % intSize)) + buf = Buffer.concat([buf, zeroBuffer], len) + } + + var arr = new Array(buf.length >>> 2) + for (var i = 0, j = 0; i < buf.length; i += intSize, j++) { + arr[j] = buf.readInt32LE(i) + } + + return arr +} + +module.exports = function hash (buf, fn) { + var arr = fn(toArray(buf), buf.length * charSize) + buf = new Buffer(hashSize) + for (var i = 0; i < arr.length; i++) { + buf.writeInt32LE(arr[i], i << 2, true) + } + return buf +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 366 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var Transform = __webpack_require__(98).Transform +var inherits = __webpack_require__(4) + +function HashBase (blockSize) { + Transform.call(this) + + this._block = new Buffer(blockSize) + this._blockSize = blockSize + this._blockOffset = 0 + this._length = [0, 0, 0, 0] + + this._finalized = false +} + +inherits(HashBase, Transform) + +HashBase.prototype._transform = function (chunk, encoding, callback) { + var error = null + try { + if (encoding !== 'buffer') chunk = new Buffer(chunk, encoding) + this.update(chunk) + } catch (err) { + error = err + } + + callback(error) +} + +HashBase.prototype._flush = function (callback) { + var error = null + try { + this.push(this._digest()) + } catch (err) { + error = err + } + + callback(error) +} + +HashBase.prototype.update = function (data, encoding) { + if (!Buffer.isBuffer(data) && typeof data !== 'string') throw new TypeError('Data must be a string or a buffer') + if (this._finalized) throw new Error('Digest already called') + if (!Buffer.isBuffer(data)) data = new Buffer(data, encoding || 'binary') + + // consume data + var block = this._block + var offset = 0 + while (this._blockOffset + data.length - offset >= this._blockSize) { + for (var i = this._blockOffset; i < this._blockSize;) block[i++] = data[offset++] + this._update() + this._blockOffset = 0 + } + while (offset < data.length) block[this._blockOffset++] = data[offset++] + + // update length + for (var j = 0, carry = data.length * 8; carry > 0; ++j) { + this._length[j] += carry + carry = (this._length[j] / 0x0100000000) | 0 + if (carry > 0) this._length[j] -= 0x0100000000 * carry + } + + return this +} + +HashBase.prototype._update = function (data) { + throw new Error('_update is not implemented') +} + +HashBase.prototype.digest = function (encoding) { + if (this._finalized) throw new Error('Digest already called') + this._finalized = true + + var digest = this._digest() + if (encoding !== undefined) digest = digest.toString(encoding) + return digest +} + +HashBase.prototype._digest = function () { + throw new Error('_digest is not implemented') +} + +module.exports = HashBase + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 367 */ +/***/ (function(module, exports) { + +/* (ignored) */ + +/***/ }), +/* 368 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/*<replacement>*/ + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +var Buffer = __webpack_require__(7).Buffer; +/*</replacement>*/ + +function copyBuffer(src, target, offset) { + src.copy(target, offset); +} + +module.exports = function () { + function BufferList() { + _classCallCheck(this, BufferList); + + this.head = null; + this.tail = null; + this.length = 0; + } + + BufferList.prototype.push = function push(v) { + var entry = { data: v, next: null }; + if (this.length > 0) this.tail.next = entry;else this.head = entry; + this.tail = entry; + ++this.length; + }; + + BufferList.prototype.unshift = function unshift(v) { + var entry = { data: v, next: this.head }; + if (this.length === 0) this.tail = entry; + this.head = entry; + ++this.length; + }; + + BufferList.prototype.shift = function shift() { + if (this.length === 0) return; + var ret = this.head.data; + if (this.length === 1) this.head = this.tail = null;else this.head = this.head.next; + --this.length; + return ret; + }; + + BufferList.prototype.clear = function clear() { + this.head = this.tail = null; + this.length = 0; + }; + + BufferList.prototype.join = function join(s) { + if (this.length === 0) return ''; + var p = this.head; + var ret = '' + p.data; + while (p = p.next) { + ret += s + p.data; + }return ret; + }; + + BufferList.prototype.concat = function concat(n) { + if (this.length === 0) return Buffer.alloc(0); + if (this.length === 1) return this.head.data; + var ret = Buffer.allocUnsafe(n >>> 0); + var p = this.head; + var i = 0; + while (p) { + copyBuffer(p.data, ret, i); + i += p.data.length; + p = p.next; + } + return ret; + }; + + return BufferList; +}(); + +/***/ }), +/* 369 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global, process) {(function (global, undefined) { + "use strict"; + + if (global.setImmediate) { + return; + } + + var nextHandle = 1; // Spec says greater than zero + var tasksByHandle = {}; + var currentlyRunningATask = false; + var doc = global.document; + var registerImmediate; + + function setImmediate(callback) { + // Callback can either be a function or a string + if (typeof callback !== "function") { + callback = new Function("" + callback); + } + // Copy function arguments + var args = new Array(arguments.length - 1); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i + 1]; + } + // Store and register the task + var task = { callback: callback, args: args }; + tasksByHandle[nextHandle] = task; + registerImmediate(nextHandle); + return nextHandle++; + } + + function clearImmediate(handle) { + delete tasksByHandle[handle]; + } + + function run(task) { + var callback = task.callback; + var args = task.args; + switch (args.length) { + case 0: + callback(); + break; + case 1: + callback(args[0]); + break; + case 2: + callback(args[0], args[1]); + break; + case 3: + callback(args[0], args[1], args[2]); + break; + default: + callback.apply(undefined, args); + break; + } + } + + function runIfPresent(handle) { + // From the spec: "Wait until any invocations of this algorithm started before this one have completed." + // So if we're currently running a task, we'll need to delay this invocation. + if (currentlyRunningATask) { + // Delay by doing a setTimeout. setImmediate was tried instead, but in Firefox 7 it generated a + // "too much recursion" error. + setTimeout(runIfPresent, 0, handle); + } else { + var task = tasksByHandle[handle]; + if (task) { + currentlyRunningATask = true; + try { + run(task); + } finally { + clearImmediate(handle); + currentlyRunningATask = false; + } + } + } + } + + function installNextTickImplementation() { + registerImmediate = function(handle) { + process.nextTick(function () { runIfPresent(handle); }); + }; + } + + function canUsePostMessage() { + // The test against `importScripts` prevents this implementation from being installed inside a web worker, + // where `global.postMessage` means something completely different and can't be used for this purpose. + if (global.postMessage && !global.importScripts) { + var postMessageIsAsynchronous = true; + var oldOnMessage = global.onmessage; + global.onmessage = function() { + postMessageIsAsynchronous = false; + }; + global.postMessage("", "*"); + global.onmessage = oldOnMessage; + return postMessageIsAsynchronous; + } + } + + function installPostMessageImplementation() { + // Installs an event handler on `global` for the `message` event: see + // * https://developer.mozilla.org/en/DOM/window.postMessage + // * http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#crossDocumentMessages + + var messagePrefix = "setImmediate$" + Math.random() + "$"; + var onGlobalMessage = function(event) { + if (event.source === global && + typeof event.data === "string" && + event.data.indexOf(messagePrefix) === 0) { + runIfPresent(+event.data.slice(messagePrefix.length)); + } + }; + + if (global.addEventListener) { + global.addEventListener("message", onGlobalMessage, false); + } else { + global.attachEvent("onmessage", onGlobalMessage); + } + + registerImmediate = function(handle) { + global.postMessage(messagePrefix + handle, "*"); + }; + } + + function installMessageChannelImplementation() { + var channel = new MessageChannel(); + channel.port1.onmessage = function(event) { + var handle = event.data; + runIfPresent(handle); + }; + + registerImmediate = function(handle) { + channel.port2.postMessage(handle); + }; + } + + function installReadyStateChangeImplementation() { + var html = doc.documentElement; + registerImmediate = function(handle) { + // Create a <script> element; its readystatechange event will be fired asynchronously once it is inserted + // into the document. Do so, thus queuing up the task. Remember to clean up once it's been called. + var script = doc.createElement("script"); + script.onreadystatechange = function () { + runIfPresent(handle); + script.onreadystatechange = null; + html.removeChild(script); + script = null; + }; + html.appendChild(script); + }; + } + + function installSetTimeoutImplementation() { + registerImmediate = function(handle) { + setTimeout(runIfPresent, 0, handle); + }; + } + + // If supported, we should attach to the prototype of global, since that is where setTimeout et al. live. + var attachTo = Object.getPrototypeOf && Object.getPrototypeOf(global); + attachTo = attachTo && attachTo.setTimeout ? attachTo : global; + + // Don't get fooled by e.g. browserify environments. + if ({}.toString.call(global.process) === "[object process]") { + // For Node.js before 0.9 + installNextTickImplementation(); + + } else if (canUsePostMessage()) { + // For non-IE10 modern browsers + installPostMessageImplementation(); + + } else if (global.MessageChannel) { + // For web workers, where supported + installMessageChannelImplementation(); + + } else if (doc && "onreadystatechange" in doc.createElement("script")) { + // For IE 6–8 + installReadyStateChangeImplementation(); + + } else { + // For older browsers + installSetTimeoutImplementation(); + } + + attachTo.setImmediate = setImmediate; + attachTo.clearImmediate = clearImmediate; +}(typeof self === "undefined" ? typeof global === "undefined" ? this : global : self)); + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) + +/***/ }), +/* 370 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global) { +/** + * Module exports. + */ + +module.exports = deprecate; + +/** + * Mark that a method should not be used. + * Returns a modified function which warns once by default. + * + * If `localStorage.noDeprecation = true` is set, then it is a no-op. + * + * If `localStorage.throwDeprecation = true` is set, then deprecated functions + * will throw an Error when invoked. + * + * If `localStorage.traceDeprecation = true` is set, then deprecated functions + * will invoke `console.trace()` instead of `console.error()`. + * + * @param {Function} fn - the function to deprecate + * @param {String} msg - the string to print to the console when `fn` is invoked + * @returns {Function} a new "deprecated" version of `fn` + * @api public + */ + +function deprecate (fn, msg) { + if (config('noDeprecation')) { + return fn; + } + + var warned = false; + function deprecated() { + if (!warned) { + if (config('throwDeprecation')) { + throw new Error(msg); + } else if (config('traceDeprecation')) { + console.trace(msg); + } else { + console.warn(msg); + } + warned = true; + } + return fn.apply(this, arguments); + } + + return deprecated; +} + +/** + * Checks `localStorage` for boolean values for the given `name`. + * + * @param {String} name + * @returns {Boolean} + * @api private + */ + +function config (name) { + // accessing global.localStorage can trigger a DOMException in sandboxed iframes + try { + if (!global.localStorage) return false; + } catch (_) { + return false; + } + var val = global.localStorage[name]; + if (null == val) return false; + return String(val).toLowerCase() === 'true'; +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) + +/***/ }), +/* 371 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a passthrough stream. +// basically just the most minimal sort of Transform stream. +// Every written chunk gets output as-is. + + + +module.exports = PassThrough; + +var Transform = __webpack_require__(165); + +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ + +util.inherits(PassThrough, Transform); + +function PassThrough(options) { + if (!(this instanceof PassThrough)) return new PassThrough(options); + + Transform.call(this, options); +} + +PassThrough.prototype._transform = function (chunk, encoding, cb) { + cb(null, chunk); +}; + +/***/ }), +/* 372 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(101); + + +/***/ }), +/* 373 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(34); + + +/***/ }), +/* 374 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(100).Transform + + +/***/ }), +/* 375 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(100).PassThrough + + +/***/ }), +/* 376 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/* + * A JavaScript implementation of the Secure Hash Algorithm, SHA-0, as defined + * in FIPS PUB 180-1 + * This source code is derived from sha1.js of the same repository. + * The difference between SHA-0 and SHA-1 is just a bitwise rotate left + * operation was added. + */ + +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) + +var K = [ + 0x5a827999, 0x6ed9eba1, 0x8f1bbcdc | 0, 0xca62c1d6 | 0 +] + +var W = new Array(80) + +function Sha () { + this.init() + this._w = W + + Hash.call(this, 64, 56) +} + +inherits(Sha, Hash) + +Sha.prototype.init = function () { + this._a = 0x67452301 + this._b = 0xefcdab89 + this._c = 0x98badcfe + this._d = 0x10325476 + this._e = 0xc3d2e1f0 + + return this +} + +function rotl5 (num) { + return (num << 5) | (num >>> 27) +} + +function rotl30 (num) { + return (num << 30) | (num >>> 2) +} + +function ft (s, b, c, d) { + if (s === 0) return (b & c) | ((~b) & d) + if (s === 2) return (b & c) | (b & d) | (c & d) + return b ^ c ^ d +} + +Sha.prototype._update = function (M) { + var W = this._w + + var a = this._a | 0 + var b = this._b | 0 + var c = this._c | 0 + var d = this._d | 0 + var e = this._e | 0 + + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4) + for (; i < 80; ++i) W[i] = W[i - 3] ^ W[i - 8] ^ W[i - 14] ^ W[i - 16] + + for (var j = 0; j < 80; ++j) { + var s = ~~(j / 20) + var t = (rotl5(a) + ft(s, b, c, d) + e + W[j] + K[s]) | 0 + + e = d + d = c + c = rotl30(b) + b = a + a = t + } + + this._a = (a + this._a) | 0 + this._b = (b + this._b) | 0 + this._c = (c + this._c) | 0 + this._d = (d + this._d) | 0 + this._e = (e + this._e) | 0 +} + +Sha.prototype._hash = function () { + var H = new Buffer(20) + + H.writeInt32BE(this._a | 0, 0) + H.writeInt32BE(this._b | 0, 4) + H.writeInt32BE(this._c | 0, 8) + H.writeInt32BE(this._d | 0, 12) + H.writeInt32BE(this._e | 0, 16) + + return H +} + +module.exports = Sha + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 377 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/* + * A JavaScript implementation of the Secure Hash Algorithm, SHA-1, as defined + * in FIPS PUB 180-1 + * Version 2.1a Copyright Paul Johnston 2000 - 2002. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * Distributed under the BSD License + * See http://pajhome.org.uk/crypt/md5 for details. + */ + +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) + +var K = [ + 0x5a827999, 0x6ed9eba1, 0x8f1bbcdc | 0, 0xca62c1d6 | 0 +] + +var W = new Array(80) + +function Sha1 () { + this.init() + this._w = W + + Hash.call(this, 64, 56) +} + +inherits(Sha1, Hash) + +Sha1.prototype.init = function () { + this._a = 0x67452301 + this._b = 0xefcdab89 + this._c = 0x98badcfe + this._d = 0x10325476 + this._e = 0xc3d2e1f0 + + return this +} + +function rotl1 (num) { + return (num << 1) | (num >>> 31) +} + +function rotl5 (num) { + return (num << 5) | (num >>> 27) +} + +function rotl30 (num) { + return (num << 30) | (num >>> 2) +} + +function ft (s, b, c, d) { + if (s === 0) return (b & c) | ((~b) & d) + if (s === 2) return (b & c) | (b & d) | (c & d) + return b ^ c ^ d +} + +Sha1.prototype._update = function (M) { + var W = this._w + + var a = this._a | 0 + var b = this._b | 0 + var c = this._c | 0 + var d = this._d | 0 + var e = this._e | 0 + + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4) + for (; i < 80; ++i) W[i] = rotl1(W[i - 3] ^ W[i - 8] ^ W[i - 14] ^ W[i - 16]) + + for (var j = 0; j < 80; ++j) { + var s = ~~(j / 20) + var t = (rotl5(a) + ft(s, b, c, d) + e + W[j] + K[s]) | 0 + + e = d + d = c + c = rotl30(b) + b = a + a = t + } + + this._a = (a + this._a) | 0 + this._b = (b + this._b) | 0 + this._c = (c + this._c) | 0 + this._d = (d + this._d) | 0 + this._e = (e + this._e) | 0 +} + +Sha1.prototype._hash = function () { + var H = new Buffer(20) + + H.writeInt32BE(this._a | 0, 0) + H.writeInt32BE(this._b | 0, 4) + H.writeInt32BE(this._c | 0, 8) + H.writeInt32BE(this._d | 0, 12) + H.writeInt32BE(this._e | 0, 16) + + return H +} + +module.exports = Sha1 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 378 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/** + * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined + * in FIPS 180-2 + * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * + */ + +var inherits = __webpack_require__(4) +var Sha256 = __webpack_require__(166) +var Hash = __webpack_require__(42) + +var W = new Array(64) + +function Sha224 () { + this.init() + + this._w = W // new Array(64) + + Hash.call(this, 64, 56) +} + +inherits(Sha224, Sha256) + +Sha224.prototype.init = function () { + this._a = 0xc1059ed8 + this._b = 0x367cd507 + this._c = 0x3070dd17 + this._d = 0xf70e5939 + this._e = 0xffc00b31 + this._f = 0x68581511 + this._g = 0x64f98fa7 + this._h = 0xbefa4fa4 + + return this +} + +Sha224.prototype._hash = function () { + var H = new Buffer(28) + + H.writeInt32BE(this._a, 0) + H.writeInt32BE(this._b, 4) + H.writeInt32BE(this._c, 8) + H.writeInt32BE(this._d, 12) + H.writeInt32BE(this._e, 16) + H.writeInt32BE(this._f, 20) + H.writeInt32BE(this._g, 24) + + return H +} + +module.exports = Sha224 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 379 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var inherits = __webpack_require__(4) +var SHA512 = __webpack_require__(167) +var Hash = __webpack_require__(42) + +var W = new Array(160) + +function Sha384 () { + this.init() + this._w = W + + Hash.call(this, 128, 112) +} + +inherits(Sha384, SHA512) + +Sha384.prototype.init = function () { + this._ah = 0xcbbb9d5d + this._bh = 0x629a292a + this._ch = 0x9159015a + this._dh = 0x152fecd8 + this._eh = 0x67332667 + this._fh = 0x8eb44a87 + this._gh = 0xdb0c2e0d + this._hh = 0x47b5481d + + this._al = 0xc1059ed8 + this._bl = 0x367cd507 + this._cl = 0x3070dd17 + this._dl = 0xf70e5939 + this._el = 0xffc00b31 + this._fl = 0x68581511 + this._gl = 0x64f98fa7 + this._hl = 0xbefa4fa4 + + return this +} + +Sha384.prototype._hash = function () { + var H = new Buffer(48) + + function writeInt64BE (h, l, offset) { + H.writeInt32BE(h, offset) + H.writeInt32BE(l, offset + 4) + } + + writeInt64BE(this._ah, this._al, 0) + writeInt64BE(this._bh, this._bl, 8) + writeInt64BE(this._ch, this._cl, 16) + writeInt64BE(this._dh, this._dl, 24) + writeInt64BE(this._eh, this._el, 32) + writeInt64BE(this._fh, this._fl, 40) + + return H +} + +module.exports = Sha384 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 380 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var assert = __webpack_require__(381) +var der = __webpack_require__(382) +var messages = __webpack_require__(169) + +function initCompressedValue (value, defaultValue) { + if (value === undefined) return defaultValue + + assert.isBoolean(value, messages.COMPRESSED_TYPE_INVALID) + return value +} + +module.exports = function (secp256k1) { + return { + privateKeyVerify: function (privateKey) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + return privateKey.length === 32 && secp256k1.privateKeyVerify(privateKey) + }, + + privateKeyExport: function (privateKey, compressed) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + compressed = initCompressedValue(compressed, true) + var publicKey = secp256k1.privateKeyExport(privateKey, compressed) + + return der.privateKeyExport(privateKey, publicKey, compressed) + }, + + privateKeyImport: function (privateKey) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + + privateKey = der.privateKeyImport(privateKey) + if (privateKey && privateKey.length === 32 && secp256k1.privateKeyVerify(privateKey)) return privateKey + + throw new Error(messages.EC_PRIVATE_KEY_IMPORT_DER_FAIL) + }, + + privateKeyTweakAdd: function (privateKey, tweak) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + assert.isBuffer(tweak, messages.TWEAK_TYPE_INVALID) + assert.isBufferLength(tweak, 32, messages.TWEAK_LENGTH_INVALID) + + return secp256k1.privateKeyTweakAdd(privateKey, tweak) + }, + + privateKeyTweakMul: function (privateKey, tweak) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + assert.isBuffer(tweak, messages.TWEAK_TYPE_INVALID) + assert.isBufferLength(tweak, 32, messages.TWEAK_LENGTH_INVALID) + + return secp256k1.privateKeyTweakMul(privateKey, tweak) + }, + + publicKeyCreate: function (privateKey, compressed) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + compressed = initCompressedValue(compressed, true) + + return secp256k1.publicKeyCreate(privateKey, compressed) + }, + + publicKeyConvert: function (publicKey, compressed) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + compressed = initCompressedValue(compressed, true) + + return secp256k1.publicKeyConvert(publicKey, compressed) + }, + + publicKeyVerify: function (publicKey) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + return secp256k1.publicKeyVerify(publicKey) + }, + + publicKeyTweakAdd: function (publicKey, tweak, compressed) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + assert.isBuffer(tweak, messages.TWEAK_TYPE_INVALID) + assert.isBufferLength(tweak, 32, messages.TWEAK_LENGTH_INVALID) + + compressed = initCompressedValue(compressed, true) + + return secp256k1.publicKeyTweakAdd(publicKey, tweak, compressed) + }, + + publicKeyTweakMul: function (publicKey, tweak, compressed) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + assert.isBuffer(tweak, messages.TWEAK_TYPE_INVALID) + assert.isBufferLength(tweak, 32, messages.TWEAK_LENGTH_INVALID) + + compressed = initCompressedValue(compressed, true) + + return secp256k1.publicKeyTweakMul(publicKey, tweak, compressed) + }, + + publicKeyCombine: function (publicKeys, compressed) { + assert.isArray(publicKeys, messages.EC_PUBLIC_KEYS_TYPE_INVALID) + assert.isLengthGTZero(publicKeys, messages.EC_PUBLIC_KEYS_LENGTH_INVALID) + for (var i = 0; i < publicKeys.length; ++i) { + assert.isBuffer(publicKeys[i], messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKeys[i], 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + } + + compressed = initCompressedValue(compressed, true) + + return secp256k1.publicKeyCombine(publicKeys, compressed) + }, + + signatureNormalize: function (signature) { + assert.isBuffer(signature, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isBufferLength(signature, 64, messages.ECDSA_SIGNATURE_LENGTH_INVALID) + + return secp256k1.signatureNormalize(signature) + }, + + signatureExport: function (signature) { + assert.isBuffer(signature, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isBufferLength(signature, 64, messages.ECDSA_SIGNATURE_LENGTH_INVALID) + + var sigObj = secp256k1.signatureExport(signature) + return der.signatureExport(sigObj) + }, + + signatureImport: function (sig) { + assert.isBuffer(sig, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isLengthGTZero(sig, messages.ECDSA_SIGNATURE_LENGTH_INVALID) + + var sigObj = der.signatureImport(sig) + if (sigObj) return secp256k1.signatureImport(sigObj) + + throw new Error(messages.ECDSA_SIGNATURE_PARSE_DER_FAIL) + }, + + signatureImportLax: function (sig) { + assert.isBuffer(sig, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isLengthGTZero(sig, messages.ECDSA_SIGNATURE_LENGTH_INVALID) + + var sigObj = der.signatureImportLax(sig) + if (sigObj) return secp256k1.signatureImport(sigObj) + + throw new Error(messages.ECDSA_SIGNATURE_PARSE_DER_FAIL) + }, + + sign: function (message, privateKey, options) { + assert.isBuffer(message, messages.MSG32_TYPE_INVALID) + assert.isBufferLength(message, 32, messages.MSG32_LENGTH_INVALID) + + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + var data = null + var noncefn = null + if (options !== undefined) { + assert.isObject(options, messages.OPTIONS_TYPE_INVALID) + + if (options.data !== undefined) { + assert.isBuffer(options.data, messages.OPTIONS_DATA_TYPE_INVALID) + assert.isBufferLength(options.data, 32, messages.OPTIONS_DATA_LENGTH_INVALID) + data = options.data + } + + if (options.noncefn !== undefined) { + assert.isFunction(options.noncefn, messages.OPTIONS_NONCEFN_TYPE_INVALID) + noncefn = options.noncefn + } + } + + return secp256k1.sign(message, privateKey, noncefn, data) + }, + + verify: function (message, signature, publicKey) { + assert.isBuffer(message, messages.MSG32_TYPE_INVALID) + assert.isBufferLength(message, 32, messages.MSG32_LENGTH_INVALID) + + assert.isBuffer(signature, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isBufferLength(signature, 64, messages.ECDSA_SIGNATURE_LENGTH_INVALID) + + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + return secp256k1.verify(message, signature, publicKey) + }, + + recover: function (message, signature, recovery, compressed) { + assert.isBuffer(message, messages.MSG32_TYPE_INVALID) + assert.isBufferLength(message, 32, messages.MSG32_LENGTH_INVALID) + + assert.isBuffer(signature, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isBufferLength(signature, 64, messages.ECDSA_SIGNATURE_LENGTH_INVALID) + + assert.isNumber(recovery, messages.RECOVERY_ID_TYPE_INVALID) + assert.isNumberInInterval(recovery, -1, 4, messages.RECOVERY_ID_VALUE_INVALID) + + compressed = initCompressedValue(compressed, true) + + return secp256k1.recover(message, signature, recovery, compressed) + }, + + ecdh: function (publicKey, privateKey) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + return secp256k1.ecdh(publicKey, privateKey) + }, + + ecdhUnsafe: function (publicKey, privateKey, compressed) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + compressed = initCompressedValue(compressed, true) + + return secp256k1.ecdhUnsafe(publicKey, privateKey, compressed) + } + } +} + + +/***/ }), +/* 381 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var toString = Object.prototype.toString + +// TypeError +exports.isArray = function (value, message) { + if (!Array.isArray(value)) throw TypeError(message) +} + +exports.isBoolean = function (value, message) { + if (toString.call(value) !== '[object Boolean]') throw TypeError(message) +} + +exports.isBuffer = function (value, message) { + if (!Buffer.isBuffer(value)) throw TypeError(message) +} + +exports.isFunction = function (value, message) { + if (toString.call(value) !== '[object Function]') throw TypeError(message) +} + +exports.isNumber = function (value, message) { + if (toString.call(value) !== '[object Number]') throw TypeError(message) +} + +exports.isObject = function (value, message) { + if (toString.call(value) !== '[object Object]') throw TypeError(message) +} + +// RangeError +exports.isBufferLength = function (buffer, length, message) { + if (buffer.length !== length) throw RangeError(message) +} + +exports.isBufferLength2 = function (buffer, length1, length2, message) { + if (buffer.length !== length1 && buffer.length !== length2) throw RangeError(message) +} + +exports.isLengthGTZero = function (value, message) { + if (value.length === 0) throw RangeError(message) +} + +exports.isNumberInInterval = function (number, x, y, message) { + if (number <= x || number >= y) throw RangeError(message) +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 382 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var Buffer = __webpack_require__(7).Buffer +var bip66 = __webpack_require__(104) + +var EC_PRIVKEY_EXPORT_DER_COMPRESSED = Buffer.from([ + // begin + 0x30, 0x81, 0xd3, 0x02, 0x01, 0x01, 0x04, 0x20, + // private key + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + // middle + 0xa0, 0x81, 0x85, 0x30, 0x81, 0x82, 0x02, 0x01, 0x01, 0x30, 0x2c, 0x06, 0x07, 0x2a, 0x86, 0x48, + 0xcE, 0x3d, 0x01, 0x01, 0x02, 0x21, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xfE, 0xff, 0xff, 0xfc, 0x2f, 0x30, 0x06, 0x04, 0x01, 0x00, 0x04, 0x01, 0x07, 0x04, + 0x21, 0x02, 0x79, 0xbE, 0x66, 0x7E, 0xf9, 0xdc, 0xbb, 0xac, 0x55, 0xa0, 0x62, 0x95, 0xcE, 0x87, + 0x0b, 0x07, 0x02, 0x9b, 0xfc, 0xdb, 0x2d, 0xcE, 0x28, 0xd9, 0x59, 0xf2, 0x81, 0x5b, 0x16, 0xf8, + 0x17, 0x98, 0x02, 0x21, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xfE, 0xba, 0xaE, 0xdc, 0xE6, 0xaf, 0x48, 0xa0, 0x3b, 0xbf, 0xd2, 0x5E, + 0x8c, 0xd0, 0x36, 0x41, 0x41, 0x02, 0x01, 0x01, 0xa1, 0x24, 0x03, 0x22, 0x00, + // public key + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00 +]) + +var EC_PRIVKEY_EXPORT_DER_UNCOMPRESSED = Buffer.from([ + // begin + 0x30, 0x82, 0x01, 0x13, 0x02, 0x01, 0x01, 0x04, 0x20, + // private key + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + // middle + 0xa0, 0x81, 0xa5, 0x30, 0x81, 0xa2, 0x02, 0x01, 0x01, 0x30, 0x2c, 0x06, 0x07, 0x2a, 0x86, 0x48, + 0xcE, 0x3d, 0x01, 0x01, 0x02, 0x21, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xfE, 0xff, 0xff, 0xfc, 0x2f, 0x30, 0x06, 0x04, 0x01, 0x00, 0x04, 0x01, 0x07, 0x04, + 0x41, 0x04, 0x79, 0xbE, 0x66, 0x7E, 0xf9, 0xdc, 0xbb, 0xac, 0x55, 0xa0, 0x62, 0x95, 0xcE, 0x87, + 0x0b, 0x07, 0x02, 0x9b, 0xfc, 0xdb, 0x2d, 0xcE, 0x28, 0xd9, 0x59, 0xf2, 0x81, 0x5b, 0x16, 0xf8, + 0x17, 0x98, 0x48, 0x3a, 0xda, 0x77, 0x26, 0xa3, 0xc4, 0x65, 0x5d, 0xa4, 0xfb, 0xfc, 0x0E, 0x11, + 0x08, 0xa8, 0xfd, 0x17, 0xb4, 0x48, 0xa6, 0x85, 0x54, 0x19, 0x9c, 0x47, 0xd0, 0x8f, 0xfb, 0x10, + 0xd4, 0xb8, 0x02, 0x21, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xfE, 0xba, 0xaE, 0xdc, 0xE6, 0xaf, 0x48, 0xa0, 0x3b, 0xbf, 0xd2, 0x5E, + 0x8c, 0xd0, 0x36, 0x41, 0x41, 0x02, 0x01, 0x01, 0xa1, 0x44, 0x03, 0x42, 0x00, + // public key + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00 +]) + +var ZERO_BUFFER_32 = Buffer.from([ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 +]) + +exports.privateKeyExport = function (privateKey, publicKey, compressed) { + var result = Buffer.from(compressed ? EC_PRIVKEY_EXPORT_DER_COMPRESSED : EC_PRIVKEY_EXPORT_DER_UNCOMPRESSED) + privateKey.copy(result, compressed ? 8 : 9) + publicKey.copy(result, compressed ? 181 : 214) + return result +} + +exports.privateKeyImport = function (privateKey) { + var length = privateKey.length + + // sequence header + var index = 0 + if (length < index + 1 || privateKey[index] !== 0x30) return + index += 1 + + // sequence length constructor + if (length < index + 1 || !(privateKey[index] & 0x80)) return + + var lenb = privateKey[index] & 0x7f + index += 1 + if (lenb < 1 || lenb > 2) return + if (length < index + lenb) return + + // sequence length + var len = privateKey[index + lenb - 1] | (lenb > 1 ? privateKey[index + lenb - 2] << 8 : 0) + index += lenb + if (length < index + len) return + + // sequence element 0: version number (=1) + if (length < index + 3 || + privateKey[index] !== 0x02 || + privateKey[index + 1] !== 0x01 || + privateKey[index + 2] !== 0x01) { + return + } + index += 3 + + // sequence element 1: octet string, up to 32 bytes + if (length < index + 2 || + privateKey[index] !== 0x04 || + privateKey[index + 1] > 0x20 || + length < index + 2 + privateKey[index + 1]) { + return + } + + return privateKey.slice(index + 2, index + 2 + privateKey[index + 1]) +} + +exports.signatureExport = function (sigObj) { + var r = Buffer.concat([Buffer.from([0]), sigObj.r]) + for (var lenR = 33, posR = 0; lenR > 1 && r[posR] === 0x00 && !(r[posR + 1] & 0x80); --lenR, ++posR); + + var s = Buffer.concat([Buffer.from([0]), sigObj.s]) + for (var lenS = 33, posS = 0; lenS > 1 && s[posS] === 0x00 && !(s[posS + 1] & 0x80); --lenS, ++posS); + + return bip66.encode(r.slice(posR), s.slice(posS)) +} + +exports.signatureImport = function (sig) { + var r = Buffer.from(ZERO_BUFFER_32) + var s = Buffer.from(ZERO_BUFFER_32) + + try { + var sigObj = bip66.decode(sig) + if (sigObj.r.length === 33 && sigObj.r[0] === 0x00) sigObj.r = sigObj.r.slice(1) + if (sigObj.r.length > 32) throw new Error('R length is too long') + if (sigObj.s.length === 33 && sigObj.s[0] === 0x00) sigObj.s = sigObj.s.slice(1) + if (sigObj.s.length > 32) throw new Error('S length is too long') + } catch (err) { + return + } + + sigObj.r.copy(r, 32 - sigObj.r.length) + sigObj.s.copy(s, 32 - sigObj.s.length) + + return { r: r, s: s } +} + +exports.signatureImportLax = function (sig) { + var r = Buffer.from(ZERO_BUFFER_32) + var s = Buffer.from(ZERO_BUFFER_32) + + var length = sig.length + var index = 0 + + // sequence tag byte + if (sig[index++] !== 0x30) return + + // sequence length byte + var lenbyte = sig[index++] + if (lenbyte & 0x80) { + index += lenbyte - 0x80 + if (index > length) return + } + + // sequence tag byte for r + if (sig[index++] !== 0x02) return + + // length for r + var rlen = sig[index++] + if (rlen & 0x80) { + lenbyte = rlen - 0x80 + if (index + lenbyte > length) return + for (; lenbyte > 0 && sig[index] === 0x00; index += 1, lenbyte -= 1); + for (rlen = 0; lenbyte > 0; index += 1, lenbyte -= 1) rlen = (rlen << 8) + sig[index] + } + if (rlen > length - index) return + var rindex = index + index += rlen + + // sequence tag byte for s + if (sig[index++] !== 0x02) return + + // length for s + var slen = sig[index++] + if (slen & 0x80) { + lenbyte = slen - 0x80 + if (index + lenbyte > length) return + for (; lenbyte > 0 && sig[index] === 0x00; index += 1, lenbyte -= 1); + for (slen = 0; lenbyte > 0; index += 1, lenbyte -= 1) slen = (slen << 8) + sig[index] + } + if (slen > length - index) return + var sindex = index + index += slen + + // ignore leading zeros in r + for (; rlen > 0 && sig[rindex] === 0x00; rlen -= 1, rindex += 1); + // copy r value + if (rlen > 32) return + var rvalue = sig.slice(rindex, rindex + rlen) + rvalue.copy(r, 32 - rvalue.length) + + // ignore leading zeros in s + for (; slen > 0 && sig[sindex] === 0x00; slen -= 1, sindex += 1); + // copy s value + if (slen > 32) return + var svalue = sig.slice(sindex, sindex + slen) + svalue.copy(s, 32 - svalue.length) + + return { r: r, s: s } +} + + +/***/ }), +/* 383 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var Buffer = __webpack_require__(7).Buffer +var createHash = __webpack_require__(27) +var BN = __webpack_require__(11) +var EC = __webpack_require__(15).ec + +var messages = __webpack_require__(169) + +var ec = new EC('secp256k1') +var ecparams = ec.curve + +function loadCompressedPublicKey (first, xBuffer) { + var x = new BN(xBuffer) + + // overflow + if (x.cmp(ecparams.p) >= 0) return null + x = x.toRed(ecparams.red) + + // compute corresponding Y + var y = x.redSqr().redIMul(x).redIAdd(ecparams.b).redSqrt() + if ((first === 0x03) !== y.isOdd()) y = y.redNeg() + + return ec.keyPair({ pub: { x: x, y: y } }) +} + +function loadUncompressedPublicKey (first, xBuffer, yBuffer) { + var x = new BN(xBuffer) + var y = new BN(yBuffer) + + // overflow + if (x.cmp(ecparams.p) >= 0 || y.cmp(ecparams.p) >= 0) return null + + x = x.toRed(ecparams.red) + y = y.toRed(ecparams.red) + + // is odd flag + if ((first === 0x06 || first === 0x07) && y.isOdd() !== (first === 0x07)) return null + + // x*x*x + b = y*y + var x3 = x.redSqr().redIMul(x) + if (!y.redSqr().redISub(x3.redIAdd(ecparams.b)).isZero()) return null + + return ec.keyPair({ pub: { x: x, y: y } }) +} + +function loadPublicKey (publicKey) { + var first = publicKey[0] + switch (first) { + case 0x02: + case 0x03: + if (publicKey.length !== 33) return null + return loadCompressedPublicKey(first, publicKey.slice(1, 33)) + case 0x04: + case 0x06: + case 0x07: + if (publicKey.length !== 65) return null + return loadUncompressedPublicKey(first, publicKey.slice(1, 33), publicKey.slice(33, 65)) + default: + return null + } +} + +exports.privateKeyVerify = function (privateKey) { + var bn = new BN(privateKey) + return bn.cmp(ecparams.n) < 0 && !bn.isZero() +} + +exports.privateKeyExport = function (privateKey, compressed) { + var d = new BN(privateKey) + if (d.cmp(ecparams.n) >= 0 || d.isZero()) throw new Error(messages.EC_PRIVATE_KEY_EXPORT_DER_FAIL) + + return Buffer.from(ec.keyFromPrivate(privateKey).getPublic(compressed, true)) +} + +exports.privateKeyTweakAdd = function (privateKey, tweak) { + var bn = new BN(tweak) + if (bn.cmp(ecparams.n) >= 0) throw new Error(messages.EC_PRIVATE_KEY_TWEAK_ADD_FAIL) + + bn.iadd(new BN(privateKey)) + if (bn.cmp(ecparams.n) >= 0) bn.isub(ecparams.n) + if (bn.isZero()) throw new Error(messages.EC_PRIVATE_KEY_TWEAK_ADD_FAIL) + + return bn.toArrayLike(Buffer, 'be', 32) +} + +exports.privateKeyTweakMul = function (privateKey, tweak) { + var bn = new BN(tweak) + if (bn.cmp(ecparams.n) >= 0 || bn.isZero()) throw new Error(messages.EC_PRIVATE_KEY_TWEAK_MUL_FAIL) + + bn.imul(new BN(privateKey)) + if (bn.cmp(ecparams.n)) bn = bn.umod(ecparams.n) + + return bn.toArrayLike(Buffer, 'be', 32) +} + +exports.publicKeyCreate = function (privateKey, compressed) { + var d = new BN(privateKey) + if (d.cmp(ecparams.n) >= 0 || d.isZero()) throw new Error(messages.EC_PUBLIC_KEY_CREATE_FAIL) + + return Buffer.from(ec.keyFromPrivate(privateKey).getPublic(compressed, true)) +} + +exports.publicKeyConvert = function (publicKey, compressed) { + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + + return Buffer.from(pair.getPublic(compressed, true)) +} + +exports.publicKeyVerify = function (publicKey) { + return loadPublicKey(publicKey) !== null +} + +exports.publicKeyTweakAdd = function (publicKey, tweak, compressed) { + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + + tweak = new BN(tweak) + if (tweak.cmp(ecparams.n) >= 0) throw new Error(messages.EC_PUBLIC_KEY_TWEAK_ADD_FAIL) + + return Buffer.from(ecparams.g.mul(tweak).add(pair.pub).encode(true, compressed)) +} + +exports.publicKeyTweakMul = function (publicKey, tweak, compressed) { + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + + tweak = new BN(tweak) + if (tweak.cmp(ecparams.n) >= 0 || tweak.isZero()) throw new Error(messages.EC_PUBLIC_KEY_TWEAK_MUL_FAIL) + + return Buffer.from(pair.pub.mul(tweak).encode(true, compressed)) +} + +exports.publicKeyCombine = function (publicKeys, compressed) { + var pairs = new Array(publicKeys.length) + for (var i = 0; i < publicKeys.length; ++i) { + pairs[i] = loadPublicKey(publicKeys[i]) + if (pairs[i] === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + } + + var point = pairs[0].pub + for (var j = 1; j < pairs.length; ++j) point = point.add(pairs[j].pub) + if (point.isInfinity()) throw new Error(messages.EC_PUBLIC_KEY_COMBINE_FAIL) + + return Buffer.from(point.encode(true, compressed)) +} + +exports.signatureNormalize = function (signature) { + var r = new BN(signature.slice(0, 32)) + var s = new BN(signature.slice(32, 64)) + if (r.cmp(ecparams.n) >= 0 || s.cmp(ecparams.n) >= 0) throw new Error(messages.ECDSA_SIGNATURE_PARSE_FAIL) + + var result = Buffer.from(signature) + if (s.cmp(ec.nh) === 1) ecparams.n.sub(s).toArrayLike(Buffer, 'be', 32).copy(result, 32) + + return result +} + +exports.signatureExport = function (signature) { + var r = signature.slice(0, 32) + var s = signature.slice(32, 64) + if (new BN(r).cmp(ecparams.n) >= 0 || new BN(s).cmp(ecparams.n) >= 0) throw new Error(messages.ECDSA_SIGNATURE_PARSE_FAIL) + + return { r: r, s: s } +} + +exports.signatureImport = function (sigObj) { + var r = new BN(sigObj.r) + if (r.cmp(ecparams.n) >= 0) r = new BN(0) + + var s = new BN(sigObj.s) + if (s.cmp(ecparams.n) >= 0) s = new BN(0) + + return Buffer.concat([ + r.toArrayLike(Buffer, 'be', 32), + s.toArrayLike(Buffer, 'be', 32) + ]) +} + +exports.sign = function (message, privateKey, noncefn, data) { + if (typeof noncefn === 'function') { + var getNonce = noncefn + noncefn = function (counter) { + var nonce = getNonce(message, privateKey, null, data, counter) + if (!Buffer.isBuffer(nonce) || nonce.length !== 32) throw new Error(messages.ECDSA_SIGN_FAIL) + + return new BN(nonce) + } + } + + var d = new BN(privateKey) + if (d.cmp(ecparams.n) >= 0 || d.isZero()) throw new Error(messages.ECDSA_SIGN_FAIL) + + var result = ec.sign(message, privateKey, { canonical: true, k: noncefn, pers: data }) + return { + signature: Buffer.concat([ + result.r.toArrayLike(Buffer, 'be', 32), + result.s.toArrayLike(Buffer, 'be', 32) + ]), + recovery: result.recoveryParam + } +} + +exports.verify = function (message, signature, publicKey) { + var sigObj = {r: signature.slice(0, 32), s: signature.slice(32, 64)} + + var sigr = new BN(sigObj.r) + var sigs = new BN(sigObj.s) + if (sigr.cmp(ecparams.n) >= 0 || sigs.cmp(ecparams.n) >= 0) throw new Error(messages.ECDSA_SIGNATURE_PARSE_FAIL) + if (sigs.cmp(ec.nh) === 1 || sigr.isZero() || sigs.isZero()) return false + + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + + return ec.verify(message, sigObj, {x: pair.pub.x, y: pair.pub.y}) +} + +exports.recover = function (message, signature, recovery, compressed) { + var sigObj = {r: signature.slice(0, 32), s: signature.slice(32, 64)} + + var sigr = new BN(sigObj.r) + var sigs = new BN(sigObj.s) + if (sigr.cmp(ecparams.n) >= 0 || sigs.cmp(ecparams.n) >= 0) throw new Error(messages.ECDSA_SIGNATURE_PARSE_FAIL) + + try { + if (sigr.isZero() || sigs.isZero()) throw new Error() + + var point = ec.recoverPubKey(message, sigObj, recovery) + return Buffer.from(point.encode(true, compressed)) + } catch (err) { + throw new Error(messages.ECDSA_RECOVER_FAIL) + } +} + +exports.ecdh = function (publicKey, privateKey) { + var shared = exports.ecdhUnsafe(publicKey, privateKey, true) + return createHash('sha256').update(shared).digest() +} + +exports.ecdhUnsafe = function (publicKey, privateKey, compressed) { + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + + var scalar = new BN(privateKey) + if (scalar.cmp(ecparams.n) >= 0 || scalar.isZero()) throw new Error(messages.ECDH_FAIL) + + return Buffer.from(pair.pub.mul(scalar).encode(true, compressed)) +} + + +/***/ }), +/* 384 */ +/***/ (function(module, exports) { + +module.exports = function(module) { + if(!module.webpackPolyfill) { + module.deprecate = function() {}; + module.paths = []; + // module.parent = undefined by default + if(!module.children) module.children = []; + Object.defineProperty(module, "loaded", { + enumerable: true, + get: function() { + return module.l; + } + }); + Object.defineProperty(module, "id", { + enumerable: true, + get: function() { + return module.i; + } + }); + module.webpackPolyfill = 1; + } + return module; +}; + + +/***/ }), +/* 385 */ +/***/ (function(module, exports) { + +module.exports = { + "name": "elliptic", + "version": "6.4.0", + "description": "EC cryptography", + "main": "lib/elliptic.js", + "files": [ + "lib" + ], + "scripts": { + "jscs": "jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js", + "jshint": "jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js", + "lint": "npm run jscs && npm run jshint", + "unit": "istanbul test _mocha --reporter=spec test/index.js", + "test": "npm run lint && npm run unit", + "version": "grunt dist && git add dist/" + }, + "repository": { + "type": "git", + "url": "git@github.com:indutny/elliptic" + }, + "keywords": [ + "EC", + "Elliptic", + "curve", + "Cryptography" + ], + "author": "Fedor Indutny <fedor@indutny.com>", + "license": "MIT", + "bugs": { + "url": "https://github.com/indutny/elliptic/issues" + }, + "homepage": "https://github.com/indutny/elliptic", + "devDependencies": { + "brfs": "^1.4.3", + "coveralls": "^2.11.3", + "grunt": "^0.4.5", + "grunt-browserify": "^5.0.0", + "grunt-cli": "^1.2.0", + "grunt-contrib-connect": "^1.0.0", + "grunt-contrib-copy": "^1.0.0", + "grunt-contrib-uglify": "^1.0.1", + "grunt-mocha-istanbul": "^3.0.1", + "grunt-saucelabs": "^8.6.2", + "istanbul": "^0.4.2", + "jscs": "^2.9.0", + "jshint": "^2.6.0", + "mocha": "^2.1.0" + }, + "dependencies": { + "bn.js": "^4.4.0", + "brorand": "^1.0.1", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.0" + } +}; + +/***/ }), +/* 386 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = exports; +var BN = __webpack_require__(11); +var minAssert = __webpack_require__(21); +var minUtils = __webpack_require__(170); + +utils.assert = minAssert; +utils.toArray = minUtils.toArray; +utils.zero2 = minUtils.zero2; +utils.toHex = minUtils.toHex; +utils.encode = minUtils.encode; + +// Represent num in a w-NAF form +function getNAF(num, w) { + var naf = []; + var ws = 1 << (w + 1); + var k = num.clone(); + while (k.cmpn(1) >= 0) { + var z; + if (k.isOdd()) { + var mod = k.andln(ws - 1); + if (mod > (ws >> 1) - 1) + z = (ws >> 1) - mod; + else + z = mod; + k.isubn(z); + } else { + z = 0; + } + naf.push(z); + + // Optimization, shift by word if possible + var shift = (k.cmpn(0) !== 0 && k.andln(ws - 1) === 0) ? (w + 1) : 1; + for (var i = 1; i < shift; i++) + naf.push(0); + k.iushrn(shift); + } + + return naf; +} +utils.getNAF = getNAF; + +// Represent k1, k2 in a Joint Sparse Form +function getJSF(k1, k2) { + var jsf = [ + [], + [] + ]; + + k1 = k1.clone(); + k2 = k2.clone(); + var d1 = 0; + var d2 = 0; + while (k1.cmpn(-d1) > 0 || k2.cmpn(-d2) > 0) { + + // First phase + var m14 = (k1.andln(3) + d1) & 3; + var m24 = (k2.andln(3) + d2) & 3; + if (m14 === 3) + m14 = -1; + if (m24 === 3) + m24 = -1; + var u1; + if ((m14 & 1) === 0) { + u1 = 0; + } else { + var m8 = (k1.andln(7) + d1) & 7; + if ((m8 === 3 || m8 === 5) && m24 === 2) + u1 = -m14; + else + u1 = m14; + } + jsf[0].push(u1); + + var u2; + if ((m24 & 1) === 0) { + u2 = 0; + } else { + var m8 = (k2.andln(7) + d2) & 7; + if ((m8 === 3 || m8 === 5) && m14 === 2) + u2 = -m24; + else + u2 = m24; + } + jsf[1].push(u2); + + // Second phase + if (2 * d1 === u1 + 1) + d1 = 1 - d1; + if (2 * d2 === u2 + 1) + d2 = 1 - d2; + k1.iushrn(1); + k2.iushrn(1); + } + + return jsf; +} +utils.getJSF = getJSF; + +function cachedProperty(obj, name, computer) { + var key = '_' + name; + obj.prototype[name] = function cachedProperty() { + return this[key] !== undefined ? this[key] : + this[key] = computer.call(this); + }; +} +utils.cachedProperty = cachedProperty; + +function parseBytes(bytes) { + return typeof bytes === 'string' ? utils.toArray(bytes, 'hex') : + bytes; +} +utils.parseBytes = parseBytes; + +function intFromLE(bytes) { + return new BN(bytes, 'hex', 'le'); +} +utils.intFromLE = intFromLE; + + + +/***/ }), +/* 387 */ +/***/ (function(module, exports) { + +/* (ignored) */ + +/***/ }), +/* 388 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var getNAF = utils.getNAF; +var getJSF = utils.getJSF; +var assert = utils.assert; + +function BaseCurve(type, conf) { + this.type = type; + this.p = new BN(conf.p, 16); + + // Use Montgomery, when there is no fast reduction for the prime + this.red = conf.prime ? BN.red(conf.prime) : BN.mont(this.p); + + // Useful for many curves + this.zero = new BN(0).toRed(this.red); + this.one = new BN(1).toRed(this.red); + this.two = new BN(2).toRed(this.red); + + // Curve configuration, optional + this.n = conf.n && new BN(conf.n, 16); + this.g = conf.g && this.pointFromJSON(conf.g, conf.gRed); + + // Temporary arrays + this._wnafT1 = new Array(4); + this._wnafT2 = new Array(4); + this._wnafT3 = new Array(4); + this._wnafT4 = new Array(4); + + // Generalized Greg Maxwell's trick + var adjustCount = this.n && this.p.div(this.n); + if (!adjustCount || adjustCount.cmpn(100) > 0) { + this.redN = null; + } else { + this._maxwellTrick = true; + this.redN = this.n.toRed(this.red); + } +} +module.exports = BaseCurve; + +BaseCurve.prototype.point = function point() { + throw new Error('Not implemented'); +}; + +BaseCurve.prototype.validate = function validate() { + throw new Error('Not implemented'); +}; + +BaseCurve.prototype._fixedNafMul = function _fixedNafMul(p, k) { + assert(p.precomputed); + var doubles = p._getDoubles(); + + var naf = getNAF(k, 1); + var I = (1 << (doubles.step + 1)) - (doubles.step % 2 === 0 ? 2 : 1); + I /= 3; + + // Translate into more windowed form + var repr = []; + for (var j = 0; j < naf.length; j += doubles.step) { + var nafW = 0; + for (var k = j + doubles.step - 1; k >= j; k--) + nafW = (nafW << 1) + naf[k]; + repr.push(nafW); + } + + var a = this.jpoint(null, null, null); + var b = this.jpoint(null, null, null); + for (var i = I; i > 0; i--) { + for (var j = 0; j < repr.length; j++) { + var nafW = repr[j]; + if (nafW === i) + b = b.mixedAdd(doubles.points[j]); + else if (nafW === -i) + b = b.mixedAdd(doubles.points[j].neg()); + } + a = a.add(b); + } + return a.toP(); +}; + +BaseCurve.prototype._wnafMul = function _wnafMul(p, k) { + var w = 4; + + // Precompute window + var nafPoints = p._getNAFPoints(w); + w = nafPoints.wnd; + var wnd = nafPoints.points; + + // Get NAF form + var naf = getNAF(k, w); + + // Add `this`*(N+1) for every w-NAF index + var acc = this.jpoint(null, null, null); + for (var i = naf.length - 1; i >= 0; i--) { + // Count zeroes + for (var k = 0; i >= 0 && naf[i] === 0; i--) + k++; + if (i >= 0) + k++; + acc = acc.dblp(k); + + if (i < 0) + break; + var z = naf[i]; + assert(z !== 0); + if (p.type === 'affine') { + // J +- P + if (z > 0) + acc = acc.mixedAdd(wnd[(z - 1) >> 1]); + else + acc = acc.mixedAdd(wnd[(-z - 1) >> 1].neg()); + } else { + // J +- J + if (z > 0) + acc = acc.add(wnd[(z - 1) >> 1]); + else + acc = acc.add(wnd[(-z - 1) >> 1].neg()); + } + } + return p.type === 'affine' ? acc.toP() : acc; +}; + +BaseCurve.prototype._wnafMulAdd = function _wnafMulAdd(defW, + points, + coeffs, + len, + jacobianResult) { + var wndWidth = this._wnafT1; + var wnd = this._wnafT2; + var naf = this._wnafT3; + + // Fill all arrays + var max = 0; + for (var i = 0; i < len; i++) { + var p = points[i]; + var nafPoints = p._getNAFPoints(defW); + wndWidth[i] = nafPoints.wnd; + wnd[i] = nafPoints.points; + } + + // Comb small window NAFs + for (var i = len - 1; i >= 1; i -= 2) { + var a = i - 1; + var b = i; + if (wndWidth[a] !== 1 || wndWidth[b] !== 1) { + naf[a] = getNAF(coeffs[a], wndWidth[a]); + naf[b] = getNAF(coeffs[b], wndWidth[b]); + max = Math.max(naf[a].length, max); + max = Math.max(naf[b].length, max); + continue; + } + + var comb = [ + points[a], /* 1 */ + null, /* 3 */ + null, /* 5 */ + points[b] /* 7 */ + ]; + + // Try to avoid Projective points, if possible + if (points[a].y.cmp(points[b].y) === 0) { + comb[1] = points[a].add(points[b]); + comb[2] = points[a].toJ().mixedAdd(points[b].neg()); + } else if (points[a].y.cmp(points[b].y.redNeg()) === 0) { + comb[1] = points[a].toJ().mixedAdd(points[b]); + comb[2] = points[a].add(points[b].neg()); + } else { + comb[1] = points[a].toJ().mixedAdd(points[b]); + comb[2] = points[a].toJ().mixedAdd(points[b].neg()); + } + + var index = [ + -3, /* -1 -1 */ + -1, /* -1 0 */ + -5, /* -1 1 */ + -7, /* 0 -1 */ + 0, /* 0 0 */ + 7, /* 0 1 */ + 5, /* 1 -1 */ + 1, /* 1 0 */ + 3 /* 1 1 */ + ]; + + var jsf = getJSF(coeffs[a], coeffs[b]); + max = Math.max(jsf[0].length, max); + naf[a] = new Array(max); + naf[b] = new Array(max); + for (var j = 0; j < max; j++) { + var ja = jsf[0][j] | 0; + var jb = jsf[1][j] | 0; + + naf[a][j] = index[(ja + 1) * 3 + (jb + 1)]; + naf[b][j] = 0; + wnd[a] = comb; + } + } + + var acc = this.jpoint(null, null, null); + var tmp = this._wnafT4; + for (var i = max; i >= 0; i--) { + var k = 0; + + while (i >= 0) { + var zero = true; + for (var j = 0; j < len; j++) { + tmp[j] = naf[j][i] | 0; + if (tmp[j] !== 0) + zero = false; + } + if (!zero) + break; + k++; + i--; + } + if (i >= 0) + k++; + acc = acc.dblp(k); + if (i < 0) + break; + + for (var j = 0; j < len; j++) { + var z = tmp[j]; + var p; + if (z === 0) + continue; + else if (z > 0) + p = wnd[j][(z - 1) >> 1]; + else if (z < 0) + p = wnd[j][(-z - 1) >> 1].neg(); + + if (p.type === 'affine') + acc = acc.mixedAdd(p); + else + acc = acc.add(p); + } + } + // Zeroify references + for (var i = 0; i < len; i++) + wnd[i] = null; + + if (jacobianResult) + return acc; + else + return acc.toP(); +}; + +function BasePoint(curve, type) { + this.curve = curve; + this.type = type; + this.precomputed = null; +} +BaseCurve.BasePoint = BasePoint; + +BasePoint.prototype.eq = function eq(/*other*/) { + throw new Error('Not implemented'); +}; + +BasePoint.prototype.validate = function validate() { + return this.curve.validate(this); +}; + +BaseCurve.prototype.decodePoint = function decodePoint(bytes, enc) { + bytes = utils.toArray(bytes, enc); + + var len = this.p.byteLength(); + + // uncompressed, hybrid-odd, hybrid-even + if ((bytes[0] === 0x04 || bytes[0] === 0x06 || bytes[0] === 0x07) && + bytes.length - 1 === 2 * len) { + if (bytes[0] === 0x06) + assert(bytes[bytes.length - 1] % 2 === 0); + else if (bytes[0] === 0x07) + assert(bytes[bytes.length - 1] % 2 === 1); + + var res = this.point(bytes.slice(1, 1 + len), + bytes.slice(1 + len, 1 + 2 * len)); + + return res; + } else if ((bytes[0] === 0x02 || bytes[0] === 0x03) && + bytes.length - 1 === len) { + return this.pointFromX(bytes.slice(1, 1 + len), bytes[0] === 0x03); + } + throw new Error('Unknown point format'); +}; + +BasePoint.prototype.encodeCompressed = function encodeCompressed(enc) { + return this.encode(enc, true); +}; + +BasePoint.prototype._encode = function _encode(compact) { + var len = this.curve.p.byteLength(); + var x = this.getX().toArray('be', len); + + if (compact) + return [ this.getY().isEven() ? 0x02 : 0x03 ].concat(x); + + return [ 0x04 ].concat(x, this.getY().toArray('be', len)) ; +}; + +BasePoint.prototype.encode = function encode(enc, compact) { + return utils.encode(this._encode(compact), enc); +}; + +BasePoint.prototype.precompute = function precompute(power) { + if (this.precomputed) + return this; + + var precomputed = { + doubles: null, + naf: null, + beta: null + }; + precomputed.naf = this._getNAFPoints(8); + precomputed.doubles = this._getDoubles(4, power); + precomputed.beta = this._getBeta(); + this.precomputed = precomputed; + + return this; +}; + +BasePoint.prototype._hasDoubles = function _hasDoubles(k) { + if (!this.precomputed) + return false; + + var doubles = this.precomputed.doubles; + if (!doubles) + return false; + + return doubles.points.length >= Math.ceil((k.bitLength() + 1) / doubles.step); +}; + +BasePoint.prototype._getDoubles = function _getDoubles(step, power) { + if (this.precomputed && this.precomputed.doubles) + return this.precomputed.doubles; + + var doubles = [ this ]; + var acc = this; + for (var i = 0; i < power; i += step) { + for (var j = 0; j < step; j++) + acc = acc.dbl(); + doubles.push(acc); + } + return { + step: step, + points: doubles + }; +}; + +BasePoint.prototype._getNAFPoints = function _getNAFPoints(wnd) { + if (this.precomputed && this.precomputed.naf) + return this.precomputed.naf; + + var res = [ this ]; + var max = (1 << wnd) - 1; + var dbl = max === 1 ? null : this.dbl(); + for (var i = 1; i < max; i++) + res[i] = res[i - 1].add(dbl); + return { + wnd: wnd, + points: res + }; +}; + +BasePoint.prototype._getBeta = function _getBeta() { + return null; +}; + +BasePoint.prototype.dblp = function dblp(k) { + var r = this; + for (var i = 0; i < k; i++) + r = r.dbl(); + return r; +}; + + +/***/ }), +/* 389 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var curve = __webpack_require__(65); +var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); +var Base = curve.base; + +var assert = elliptic.utils.assert; + +function ShortCurve(conf) { + Base.call(this, 'short', conf); + + this.a = new BN(conf.a, 16).toRed(this.red); + this.b = new BN(conf.b, 16).toRed(this.red); + this.tinv = this.two.redInvm(); + + this.zeroA = this.a.fromRed().cmpn(0) === 0; + this.threeA = this.a.fromRed().sub(this.p).cmpn(-3) === 0; + + // If the curve is endomorphic, precalculate beta and lambda + this.endo = this._getEndomorphism(conf); + this._endoWnafT1 = new Array(4); + this._endoWnafT2 = new Array(4); +} +inherits(ShortCurve, Base); +module.exports = ShortCurve; + +ShortCurve.prototype._getEndomorphism = function _getEndomorphism(conf) { + // No efficient endomorphism + if (!this.zeroA || !this.g || !this.n || this.p.modn(3) !== 1) + return; + + // Compute beta and lambda, that lambda * P = (beta * Px; Py) + var beta; + var lambda; + if (conf.beta) { + beta = new BN(conf.beta, 16).toRed(this.red); + } else { + var betas = this._getEndoRoots(this.p); + // Choose the smallest beta + beta = betas[0].cmp(betas[1]) < 0 ? betas[0] : betas[1]; + beta = beta.toRed(this.red); + } + if (conf.lambda) { + lambda = new BN(conf.lambda, 16); + } else { + // Choose the lambda that is matching selected beta + var lambdas = this._getEndoRoots(this.n); + if (this.g.mul(lambdas[0]).x.cmp(this.g.x.redMul(beta)) === 0) { + lambda = lambdas[0]; + } else { + lambda = lambdas[1]; + assert(this.g.mul(lambda).x.cmp(this.g.x.redMul(beta)) === 0); + } + } + + // Get basis vectors, used for balanced length-two representation + var basis; + if (conf.basis) { + basis = conf.basis.map(function(vec) { + return { + a: new BN(vec.a, 16), + b: new BN(vec.b, 16) + }; + }); + } else { + basis = this._getEndoBasis(lambda); + } + + return { + beta: beta, + lambda: lambda, + basis: basis + }; +}; + +ShortCurve.prototype._getEndoRoots = function _getEndoRoots(num) { + // Find roots of for x^2 + x + 1 in F + // Root = (-1 +- Sqrt(-3)) / 2 + // + var red = num === this.p ? this.red : BN.mont(num); + var tinv = new BN(2).toRed(red).redInvm(); + var ntinv = tinv.redNeg(); + + var s = new BN(3).toRed(red).redNeg().redSqrt().redMul(tinv); + + var l1 = ntinv.redAdd(s).fromRed(); + var l2 = ntinv.redSub(s).fromRed(); + return [ l1, l2 ]; +}; + +ShortCurve.prototype._getEndoBasis = function _getEndoBasis(lambda) { + // aprxSqrt >= sqrt(this.n) + var aprxSqrt = this.n.ushrn(Math.floor(this.n.bitLength() / 2)); + + // 3.74 + // Run EGCD, until r(L + 1) < aprxSqrt + var u = lambda; + var v = this.n.clone(); + var x1 = new BN(1); + var y1 = new BN(0); + var x2 = new BN(0); + var y2 = new BN(1); + + // NOTE: all vectors are roots of: a + b * lambda = 0 (mod n) + var a0; + var b0; + // First vector + var a1; + var b1; + // Second vector + var a2; + var b2; + + var prevR; + var i = 0; + var r; + var x; + while (u.cmpn(0) !== 0) { + var q = v.div(u); + r = v.sub(q.mul(u)); + x = x2.sub(q.mul(x1)); + var y = y2.sub(q.mul(y1)); + + if (!a1 && r.cmp(aprxSqrt) < 0) { + a0 = prevR.neg(); + b0 = x1; + a1 = r.neg(); + b1 = x; + } else if (a1 && ++i === 2) { + break; + } + prevR = r; + + v = u; + u = r; + x2 = x1; + x1 = x; + y2 = y1; + y1 = y; + } + a2 = r.neg(); + b2 = x; + + var len1 = a1.sqr().add(b1.sqr()); + var len2 = a2.sqr().add(b2.sqr()); + if (len2.cmp(len1) >= 0) { + a2 = a0; + b2 = b0; + } + + // Normalize signs + if (a1.negative) { + a1 = a1.neg(); + b1 = b1.neg(); + } + if (a2.negative) { + a2 = a2.neg(); + b2 = b2.neg(); + } + + return [ + { a: a1, b: b1 }, + { a: a2, b: b2 } + ]; +}; + +ShortCurve.prototype._endoSplit = function _endoSplit(k) { + var basis = this.endo.basis; + var v1 = basis[0]; + var v2 = basis[1]; + + var c1 = v2.b.mul(k).divRound(this.n); + var c2 = v1.b.neg().mul(k).divRound(this.n); + + var p1 = c1.mul(v1.a); + var p2 = c2.mul(v2.a); + var q1 = c1.mul(v1.b); + var q2 = c2.mul(v2.b); + + // Calculate answer + var k1 = k.sub(p1).sub(p2); + var k2 = q1.add(q2).neg(); + return { k1: k1, k2: k2 }; +}; + +ShortCurve.prototype.pointFromX = function pointFromX(x, odd) { + x = new BN(x, 16); + if (!x.red) + x = x.toRed(this.red); + + var y2 = x.redSqr().redMul(x).redIAdd(x.redMul(this.a)).redIAdd(this.b); + var y = y2.redSqrt(); + if (y.redSqr().redSub(y2).cmp(this.zero) !== 0) + throw new Error('invalid point'); + + // XXX Is there any way to tell if the number is odd without converting it + // to non-red form? + var isOdd = y.fromRed().isOdd(); + if (odd && !isOdd || !odd && isOdd) + y = y.redNeg(); + + return this.point(x, y); +}; + +ShortCurve.prototype.validate = function validate(point) { + if (point.inf) + return true; + + var x = point.x; + var y = point.y; + + var ax = this.a.redMul(x); + var rhs = x.redSqr().redMul(x).redIAdd(ax).redIAdd(this.b); + return y.redSqr().redISub(rhs).cmpn(0) === 0; +}; + +ShortCurve.prototype._endoWnafMulAdd = + function _endoWnafMulAdd(points, coeffs, jacobianResult) { + var npoints = this._endoWnafT1; + var ncoeffs = this._endoWnafT2; + for (var i = 0; i < points.length; i++) { + var split = this._endoSplit(coeffs[i]); + var p = points[i]; + var beta = p._getBeta(); + + if (split.k1.negative) { + split.k1.ineg(); + p = p.neg(true); + } + if (split.k2.negative) { + split.k2.ineg(); + beta = beta.neg(true); + } + + npoints[i * 2] = p; + npoints[i * 2 + 1] = beta; + ncoeffs[i * 2] = split.k1; + ncoeffs[i * 2 + 1] = split.k2; + } + var res = this._wnafMulAdd(1, npoints, ncoeffs, i * 2, jacobianResult); + + // Clean-up references to points and coefficients + for (var j = 0; j < i * 2; j++) { + npoints[j] = null; + ncoeffs[j] = null; + } + return res; +}; + +function Point(curve, x, y, isRed) { + Base.BasePoint.call(this, curve, 'affine'); + if (x === null && y === null) { + this.x = null; + this.y = null; + this.inf = true; + } else { + this.x = new BN(x, 16); + this.y = new BN(y, 16); + // Force redgomery representation when loading from JSON + if (isRed) { + this.x.forceRed(this.curve.red); + this.y.forceRed(this.curve.red); + } + if (!this.x.red) + this.x = this.x.toRed(this.curve.red); + if (!this.y.red) + this.y = this.y.toRed(this.curve.red); + this.inf = false; + } +} +inherits(Point, Base.BasePoint); + +ShortCurve.prototype.point = function point(x, y, isRed) { + return new Point(this, x, y, isRed); +}; + +ShortCurve.prototype.pointFromJSON = function pointFromJSON(obj, red) { + return Point.fromJSON(this, obj, red); +}; + +Point.prototype._getBeta = function _getBeta() { + if (!this.curve.endo) + return; + + var pre = this.precomputed; + if (pre && pre.beta) + return pre.beta; + + var beta = this.curve.point(this.x.redMul(this.curve.endo.beta), this.y); + if (pre) { + var curve = this.curve; + var endoMul = function(p) { + return curve.point(p.x.redMul(curve.endo.beta), p.y); + }; + pre.beta = beta; + beta.precomputed = { + beta: null, + naf: pre.naf && { + wnd: pre.naf.wnd, + points: pre.naf.points.map(endoMul) + }, + doubles: pre.doubles && { + step: pre.doubles.step, + points: pre.doubles.points.map(endoMul) + } + }; + } + return beta; +}; + +Point.prototype.toJSON = function toJSON() { + if (!this.precomputed) + return [ this.x, this.y ]; + + return [ this.x, this.y, this.precomputed && { + doubles: this.precomputed.doubles && { + step: this.precomputed.doubles.step, + points: this.precomputed.doubles.points.slice(1) + }, + naf: this.precomputed.naf && { + wnd: this.precomputed.naf.wnd, + points: this.precomputed.naf.points.slice(1) + } + } ]; +}; + +Point.fromJSON = function fromJSON(curve, obj, red) { + if (typeof obj === 'string') + obj = JSON.parse(obj); + var res = curve.point(obj[0], obj[1], red); + if (!obj[2]) + return res; + + function obj2point(obj) { + return curve.point(obj[0], obj[1], red); + } + + var pre = obj[2]; + res.precomputed = { + beta: null, + doubles: pre.doubles && { + step: pre.doubles.step, + points: [ res ].concat(pre.doubles.points.map(obj2point)) + }, + naf: pre.naf && { + wnd: pre.naf.wnd, + points: [ res ].concat(pre.naf.points.map(obj2point)) + } + }; + return res; +}; + +Point.prototype.inspect = function inspect() { + if (this.isInfinity()) + return '<EC Point Infinity>'; + return '<EC Point x: ' + this.x.fromRed().toString(16, 2) + + ' y: ' + this.y.fromRed().toString(16, 2) + '>'; +}; + +Point.prototype.isInfinity = function isInfinity() { + return this.inf; +}; + +Point.prototype.add = function add(p) { + // O + P = P + if (this.inf) + return p; + + // P + O = P + if (p.inf) + return this; + + // P + P = 2P + if (this.eq(p)) + return this.dbl(); + + // P + (-P) = O + if (this.neg().eq(p)) + return this.curve.point(null, null); + + // P + Q = O + if (this.x.cmp(p.x) === 0) + return this.curve.point(null, null); + + var c = this.y.redSub(p.y); + if (c.cmpn(0) !== 0) + c = c.redMul(this.x.redSub(p.x).redInvm()); + var nx = c.redSqr().redISub(this.x).redISub(p.x); + var ny = c.redMul(this.x.redSub(nx)).redISub(this.y); + return this.curve.point(nx, ny); +}; + +Point.prototype.dbl = function dbl() { + if (this.inf) + return this; + + // 2P = O + var ys1 = this.y.redAdd(this.y); + if (ys1.cmpn(0) === 0) + return this.curve.point(null, null); + + var a = this.curve.a; + + var x2 = this.x.redSqr(); + var dyinv = ys1.redInvm(); + var c = x2.redAdd(x2).redIAdd(x2).redIAdd(a).redMul(dyinv); + + var nx = c.redSqr().redISub(this.x.redAdd(this.x)); + var ny = c.redMul(this.x.redSub(nx)).redISub(this.y); + return this.curve.point(nx, ny); +}; + +Point.prototype.getX = function getX() { + return this.x.fromRed(); +}; + +Point.prototype.getY = function getY() { + return this.y.fromRed(); +}; + +Point.prototype.mul = function mul(k) { + k = new BN(k, 16); + + if (this._hasDoubles(k)) + return this.curve._fixedNafMul(this, k); + else if (this.curve.endo) + return this.curve._endoWnafMulAdd([ this ], [ k ]); + else + return this.curve._wnafMul(this, k); +}; + +Point.prototype.mulAdd = function mulAdd(k1, p2, k2) { + var points = [ this, p2 ]; + var coeffs = [ k1, k2 ]; + if (this.curve.endo) + return this.curve._endoWnafMulAdd(points, coeffs); + else + return this.curve._wnafMulAdd(1, points, coeffs, 2); +}; + +Point.prototype.jmulAdd = function jmulAdd(k1, p2, k2) { + var points = [ this, p2 ]; + var coeffs = [ k1, k2 ]; + if (this.curve.endo) + return this.curve._endoWnafMulAdd(points, coeffs, true); + else + return this.curve._wnafMulAdd(1, points, coeffs, 2, true); +}; + +Point.prototype.eq = function eq(p) { + return this === p || + this.inf === p.inf && + (this.inf || this.x.cmp(p.x) === 0 && this.y.cmp(p.y) === 0); +}; + +Point.prototype.neg = function neg(_precompute) { + if (this.inf) + return this; + + var res = this.curve.point(this.x, this.y.redNeg()); + if (_precompute && this.precomputed) { + var pre = this.precomputed; + var negate = function(p) { + return p.neg(); + }; + res.precomputed = { + naf: pre.naf && { + wnd: pre.naf.wnd, + points: pre.naf.points.map(negate) + }, + doubles: pre.doubles && { + step: pre.doubles.step, + points: pre.doubles.points.map(negate) + } + }; + } + return res; +}; + +Point.prototype.toJ = function toJ() { + if (this.inf) + return this.curve.jpoint(null, null, null); + + var res = this.curve.jpoint(this.x, this.y, this.curve.one); + return res; +}; + +function JPoint(curve, x, y, z) { + Base.BasePoint.call(this, curve, 'jacobian'); + if (x === null && y === null && z === null) { + this.x = this.curve.one; + this.y = this.curve.one; + this.z = new BN(0); + } else { + this.x = new BN(x, 16); + this.y = new BN(y, 16); + this.z = new BN(z, 16); + } + if (!this.x.red) + this.x = this.x.toRed(this.curve.red); + if (!this.y.red) + this.y = this.y.toRed(this.curve.red); + if (!this.z.red) + this.z = this.z.toRed(this.curve.red); + + this.zOne = this.z === this.curve.one; +} +inherits(JPoint, Base.BasePoint); + +ShortCurve.prototype.jpoint = function jpoint(x, y, z) { + return new JPoint(this, x, y, z); +}; + +JPoint.prototype.toP = function toP() { + if (this.isInfinity()) + return this.curve.point(null, null); + + var zinv = this.z.redInvm(); + var zinv2 = zinv.redSqr(); + var ax = this.x.redMul(zinv2); + var ay = this.y.redMul(zinv2).redMul(zinv); + + return this.curve.point(ax, ay); +}; + +JPoint.prototype.neg = function neg() { + return this.curve.jpoint(this.x, this.y.redNeg(), this.z); +}; + +JPoint.prototype.add = function add(p) { + // O + P = P + if (this.isInfinity()) + return p; + + // P + O = P + if (p.isInfinity()) + return this; + + // 12M + 4S + 7A + var pz2 = p.z.redSqr(); + var z2 = this.z.redSqr(); + var u1 = this.x.redMul(pz2); + var u2 = p.x.redMul(z2); + var s1 = this.y.redMul(pz2.redMul(p.z)); + var s2 = p.y.redMul(z2.redMul(this.z)); + + var h = u1.redSub(u2); + var r = s1.redSub(s2); + if (h.cmpn(0) === 0) { + if (r.cmpn(0) !== 0) + return this.curve.jpoint(null, null, null); + else + return this.dbl(); + } + + var h2 = h.redSqr(); + var h3 = h2.redMul(h); + var v = u1.redMul(h2); + + var nx = r.redSqr().redIAdd(h3).redISub(v).redISub(v); + var ny = r.redMul(v.redISub(nx)).redISub(s1.redMul(h3)); + var nz = this.z.redMul(p.z).redMul(h); + + return this.curve.jpoint(nx, ny, nz); +}; + +JPoint.prototype.mixedAdd = function mixedAdd(p) { + // O + P = P + if (this.isInfinity()) + return p.toJ(); + + // P + O = P + if (p.isInfinity()) + return this; + + // 8M + 3S + 7A + var z2 = this.z.redSqr(); + var u1 = this.x; + var u2 = p.x.redMul(z2); + var s1 = this.y; + var s2 = p.y.redMul(z2).redMul(this.z); + + var h = u1.redSub(u2); + var r = s1.redSub(s2); + if (h.cmpn(0) === 0) { + if (r.cmpn(0) !== 0) + return this.curve.jpoint(null, null, null); + else + return this.dbl(); + } + + var h2 = h.redSqr(); + var h3 = h2.redMul(h); + var v = u1.redMul(h2); + + var nx = r.redSqr().redIAdd(h3).redISub(v).redISub(v); + var ny = r.redMul(v.redISub(nx)).redISub(s1.redMul(h3)); + var nz = this.z.redMul(h); + + return this.curve.jpoint(nx, ny, nz); +}; + +JPoint.prototype.dblp = function dblp(pow) { + if (pow === 0) + return this; + if (this.isInfinity()) + return this; + if (!pow) + return this.dbl(); + + if (this.curve.zeroA || this.curve.threeA) { + var r = this; + for (var i = 0; i < pow; i++) + r = r.dbl(); + return r; + } + + // 1M + 2S + 1A + N * (4S + 5M + 8A) + // N = 1 => 6M + 6S + 9A + var a = this.curve.a; + var tinv = this.curve.tinv; + + var jx = this.x; + var jy = this.y; + var jz = this.z; + var jz4 = jz.redSqr().redSqr(); + + // Reuse results + var jyd = jy.redAdd(jy); + for (var i = 0; i < pow; i++) { + var jx2 = jx.redSqr(); + var jyd2 = jyd.redSqr(); + var jyd4 = jyd2.redSqr(); + var c = jx2.redAdd(jx2).redIAdd(jx2).redIAdd(a.redMul(jz4)); + + var t1 = jx.redMul(jyd2); + var nx = c.redSqr().redISub(t1.redAdd(t1)); + var t2 = t1.redISub(nx); + var dny = c.redMul(t2); + dny = dny.redIAdd(dny).redISub(jyd4); + var nz = jyd.redMul(jz); + if (i + 1 < pow) + jz4 = jz4.redMul(jyd4); + + jx = nx; + jz = nz; + jyd = dny; + } + + return this.curve.jpoint(jx, jyd.redMul(tinv), jz); +}; + +JPoint.prototype.dbl = function dbl() { + if (this.isInfinity()) + return this; + + if (this.curve.zeroA) + return this._zeroDbl(); + else if (this.curve.threeA) + return this._threeDbl(); + else + return this._dbl(); +}; + +JPoint.prototype._zeroDbl = function _zeroDbl() { + var nx; + var ny; + var nz; + // Z = 1 + if (this.zOne) { + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html + // #doubling-mdbl-2007-bl + // 1M + 5S + 14A + + // XX = X1^2 + var xx = this.x.redSqr(); + // YY = Y1^2 + var yy = this.y.redSqr(); + // YYYY = YY^2 + var yyyy = yy.redSqr(); + // S = 2 * ((X1 + YY)^2 - XX - YYYY) + var s = this.x.redAdd(yy).redSqr().redISub(xx).redISub(yyyy); + s = s.redIAdd(s); + // M = 3 * XX + a; a = 0 + var m = xx.redAdd(xx).redIAdd(xx); + // T = M ^ 2 - 2*S + var t = m.redSqr().redISub(s).redISub(s); + + // 8 * YYYY + var yyyy8 = yyyy.redIAdd(yyyy); + yyyy8 = yyyy8.redIAdd(yyyy8); + yyyy8 = yyyy8.redIAdd(yyyy8); + + // X3 = T + nx = t; + // Y3 = M * (S - T) - 8 * YYYY + ny = m.redMul(s.redISub(t)).redISub(yyyy8); + // Z3 = 2*Y1 + nz = this.y.redAdd(this.y); + } else { + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html + // #doubling-dbl-2009-l + // 2M + 5S + 13A + + // A = X1^2 + var a = this.x.redSqr(); + // B = Y1^2 + var b = this.y.redSqr(); + // C = B^2 + var c = b.redSqr(); + // D = 2 * ((X1 + B)^2 - A - C) + var d = this.x.redAdd(b).redSqr().redISub(a).redISub(c); + d = d.redIAdd(d); + // E = 3 * A + var e = a.redAdd(a).redIAdd(a); + // F = E^2 + var f = e.redSqr(); + + // 8 * C + var c8 = c.redIAdd(c); + c8 = c8.redIAdd(c8); + c8 = c8.redIAdd(c8); + + // X3 = F - 2 * D + nx = f.redISub(d).redISub(d); + // Y3 = E * (D - X3) - 8 * C + ny = e.redMul(d.redISub(nx)).redISub(c8); + // Z3 = 2 * Y1 * Z1 + nz = this.y.redMul(this.z); + nz = nz.redIAdd(nz); + } + + return this.curve.jpoint(nx, ny, nz); +}; + +JPoint.prototype._threeDbl = function _threeDbl() { + var nx; + var ny; + var nz; + // Z = 1 + if (this.zOne) { + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-3.html + // #doubling-mdbl-2007-bl + // 1M + 5S + 15A + + // XX = X1^2 + var xx = this.x.redSqr(); + // YY = Y1^2 + var yy = this.y.redSqr(); + // YYYY = YY^2 + var yyyy = yy.redSqr(); + // S = 2 * ((X1 + YY)^2 - XX - YYYY) + var s = this.x.redAdd(yy).redSqr().redISub(xx).redISub(yyyy); + s = s.redIAdd(s); + // M = 3 * XX + a + var m = xx.redAdd(xx).redIAdd(xx).redIAdd(this.curve.a); + // T = M^2 - 2 * S + var t = m.redSqr().redISub(s).redISub(s); + // X3 = T + nx = t; + // Y3 = M * (S - T) - 8 * YYYY + var yyyy8 = yyyy.redIAdd(yyyy); + yyyy8 = yyyy8.redIAdd(yyyy8); + yyyy8 = yyyy8.redIAdd(yyyy8); + ny = m.redMul(s.redISub(t)).redISub(yyyy8); + // Z3 = 2 * Y1 + nz = this.y.redAdd(this.y); + } else { + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-3.html#doubling-dbl-2001-b + // 3M + 5S + + // delta = Z1^2 + var delta = this.z.redSqr(); + // gamma = Y1^2 + var gamma = this.y.redSqr(); + // beta = X1 * gamma + var beta = this.x.redMul(gamma); + // alpha = 3 * (X1 - delta) * (X1 + delta) + var alpha = this.x.redSub(delta).redMul(this.x.redAdd(delta)); + alpha = alpha.redAdd(alpha).redIAdd(alpha); + // X3 = alpha^2 - 8 * beta + var beta4 = beta.redIAdd(beta); + beta4 = beta4.redIAdd(beta4); + var beta8 = beta4.redAdd(beta4); + nx = alpha.redSqr().redISub(beta8); + // Z3 = (Y1 + Z1)^2 - gamma - delta + nz = this.y.redAdd(this.z).redSqr().redISub(gamma).redISub(delta); + // Y3 = alpha * (4 * beta - X3) - 8 * gamma^2 + var ggamma8 = gamma.redSqr(); + ggamma8 = ggamma8.redIAdd(ggamma8); + ggamma8 = ggamma8.redIAdd(ggamma8); + ggamma8 = ggamma8.redIAdd(ggamma8); + ny = alpha.redMul(beta4.redISub(nx)).redISub(ggamma8); + } + + return this.curve.jpoint(nx, ny, nz); +}; + +JPoint.prototype._dbl = function _dbl() { + var a = this.curve.a; + + // 4M + 6S + 10A + var jx = this.x; + var jy = this.y; + var jz = this.z; + var jz4 = jz.redSqr().redSqr(); + + var jx2 = jx.redSqr(); + var jy2 = jy.redSqr(); + + var c = jx2.redAdd(jx2).redIAdd(jx2).redIAdd(a.redMul(jz4)); + + var jxd4 = jx.redAdd(jx); + jxd4 = jxd4.redIAdd(jxd4); + var t1 = jxd4.redMul(jy2); + var nx = c.redSqr().redISub(t1.redAdd(t1)); + var t2 = t1.redISub(nx); + + var jyd8 = jy2.redSqr(); + jyd8 = jyd8.redIAdd(jyd8); + jyd8 = jyd8.redIAdd(jyd8); + jyd8 = jyd8.redIAdd(jyd8); + var ny = c.redMul(t2).redISub(jyd8); + var nz = jy.redAdd(jy).redMul(jz); + + return this.curve.jpoint(nx, ny, nz); +}; + +JPoint.prototype.trpl = function trpl() { + if (!this.curve.zeroA) + return this.dbl().add(this); + + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html#tripling-tpl-2007-bl + // 5M + 10S + ... + + // XX = X1^2 + var xx = this.x.redSqr(); + // YY = Y1^2 + var yy = this.y.redSqr(); + // ZZ = Z1^2 + var zz = this.z.redSqr(); + // YYYY = YY^2 + var yyyy = yy.redSqr(); + // M = 3 * XX + a * ZZ2; a = 0 + var m = xx.redAdd(xx).redIAdd(xx); + // MM = M^2 + var mm = m.redSqr(); + // E = 6 * ((X1 + YY)^2 - XX - YYYY) - MM + var e = this.x.redAdd(yy).redSqr().redISub(xx).redISub(yyyy); + e = e.redIAdd(e); + e = e.redAdd(e).redIAdd(e); + e = e.redISub(mm); + // EE = E^2 + var ee = e.redSqr(); + // T = 16*YYYY + var t = yyyy.redIAdd(yyyy); + t = t.redIAdd(t); + t = t.redIAdd(t); + t = t.redIAdd(t); + // U = (M + E)^2 - MM - EE - T + var u = m.redIAdd(e).redSqr().redISub(mm).redISub(ee).redISub(t); + // X3 = 4 * (X1 * EE - 4 * YY * U) + var yyu4 = yy.redMul(u); + yyu4 = yyu4.redIAdd(yyu4); + yyu4 = yyu4.redIAdd(yyu4); + var nx = this.x.redMul(ee).redISub(yyu4); + nx = nx.redIAdd(nx); + nx = nx.redIAdd(nx); + // Y3 = 8 * Y1 * (U * (T - U) - E * EE) + var ny = this.y.redMul(u.redMul(t.redISub(u)).redISub(e.redMul(ee))); + ny = ny.redIAdd(ny); + ny = ny.redIAdd(ny); + ny = ny.redIAdd(ny); + // Z3 = (Z1 + E)^2 - ZZ - EE + var nz = this.z.redAdd(e).redSqr().redISub(zz).redISub(ee); + + return this.curve.jpoint(nx, ny, nz); +}; + +JPoint.prototype.mul = function mul(k, kbase) { + k = new BN(k, kbase); + + return this.curve._wnafMul(this, k); +}; + +JPoint.prototype.eq = function eq(p) { + if (p.type === 'affine') + return this.eq(p.toJ()); + + if (this === p) + return true; + + // x1 * z2^2 == x2 * z1^2 + var z2 = this.z.redSqr(); + var pz2 = p.z.redSqr(); + if (this.x.redMul(pz2).redISub(p.x.redMul(z2)).cmpn(0) !== 0) + return false; + + // y1 * z2^3 == y2 * z1^3 + var z3 = z2.redMul(this.z); + var pz3 = pz2.redMul(p.z); + return this.y.redMul(pz3).redISub(p.y.redMul(z3)).cmpn(0) === 0; +}; + +JPoint.prototype.eqXToP = function eqXToP(x) { + var zs = this.z.redSqr(); + var rx = x.toRed(this.curve.red).redMul(zs); + if (this.x.cmp(rx) === 0) + return true; + + var xc = x.clone(); + var t = this.curve.redN.redMul(zs); + for (;;) { + xc.iadd(this.curve.n); + if (xc.cmp(this.curve.p) >= 0) + return false; + + rx.redIAdd(t); + if (this.x.cmp(rx) === 0) + return true; + } + return false; +}; + +JPoint.prototype.inspect = function inspect() { + if (this.isInfinity()) + return '<EC JPoint Infinity>'; + return '<EC JPoint x: ' + this.x.toString(16, 2) + + ' y: ' + this.y.toString(16, 2) + + ' z: ' + this.z.toString(16, 2) + '>'; +}; + +JPoint.prototype.isInfinity = function isInfinity() { + // XXX This code assumes that zero is always zero in red + return this.z.cmpn(0) === 0; +}; + + +/***/ }), +/* 390 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var curve = __webpack_require__(65); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); +var Base = curve.base; + +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; + +function MontCurve(conf) { + Base.call(this, 'mont', conf); + + this.a = new BN(conf.a, 16).toRed(this.red); + this.b = new BN(conf.b, 16).toRed(this.red); + this.i4 = new BN(4).toRed(this.red).redInvm(); + this.two = new BN(2).toRed(this.red); + this.a24 = this.i4.redMul(this.a.redAdd(this.two)); +} +inherits(MontCurve, Base); +module.exports = MontCurve; + +MontCurve.prototype.validate = function validate(point) { + var x = point.normalize().x; + var x2 = x.redSqr(); + var rhs = x2.redMul(x).redAdd(x2.redMul(this.a)).redAdd(x); + var y = rhs.redSqrt(); + + return y.redSqr().cmp(rhs) === 0; +}; + +function Point(curve, x, z) { + Base.BasePoint.call(this, curve, 'projective'); + if (x === null && z === null) { + this.x = this.curve.one; + this.z = this.curve.zero; + } else { + this.x = new BN(x, 16); + this.z = new BN(z, 16); + if (!this.x.red) + this.x = this.x.toRed(this.curve.red); + if (!this.z.red) + this.z = this.z.toRed(this.curve.red); + } +} +inherits(Point, Base.BasePoint); + +MontCurve.prototype.decodePoint = function decodePoint(bytes, enc) { + return this.point(utils.toArray(bytes, enc), 1); +}; + +MontCurve.prototype.point = function point(x, z) { + return new Point(this, x, z); +}; + +MontCurve.prototype.pointFromJSON = function pointFromJSON(obj) { + return Point.fromJSON(this, obj); +}; + +Point.prototype.precompute = function precompute() { + // No-op +}; + +Point.prototype._encode = function _encode() { + return this.getX().toArray('be', this.curve.p.byteLength()); +}; + +Point.fromJSON = function fromJSON(curve, obj) { + return new Point(curve, obj[0], obj[1] || curve.one); +}; + +Point.prototype.inspect = function inspect() { + if (this.isInfinity()) + return '<EC Point Infinity>'; + return '<EC Point x: ' + this.x.fromRed().toString(16, 2) + + ' z: ' + this.z.fromRed().toString(16, 2) + '>'; +}; + +Point.prototype.isInfinity = function isInfinity() { + // XXX This code assumes that zero is always zero in red + return this.z.cmpn(0) === 0; +}; + +Point.prototype.dbl = function dbl() { + // http://hyperelliptic.org/EFD/g1p/auto-montgom-xz.html#doubling-dbl-1987-m-3 + // 2M + 2S + 4A + + // A = X1 + Z1 + var a = this.x.redAdd(this.z); + // AA = A^2 + var aa = a.redSqr(); + // B = X1 - Z1 + var b = this.x.redSub(this.z); + // BB = B^2 + var bb = b.redSqr(); + // C = AA - BB + var c = aa.redSub(bb); + // X3 = AA * BB + var nx = aa.redMul(bb); + // Z3 = C * (BB + A24 * C) + var nz = c.redMul(bb.redAdd(this.curve.a24.redMul(c))); + return this.curve.point(nx, nz); +}; + +Point.prototype.add = function add() { + throw new Error('Not supported on Montgomery curve'); +}; + +Point.prototype.diffAdd = function diffAdd(p, diff) { + // http://hyperelliptic.org/EFD/g1p/auto-montgom-xz.html#diffadd-dadd-1987-m-3 + // 4M + 2S + 6A + + // A = X2 + Z2 + var a = this.x.redAdd(this.z); + // B = X2 - Z2 + var b = this.x.redSub(this.z); + // C = X3 + Z3 + var c = p.x.redAdd(p.z); + // D = X3 - Z3 + var d = p.x.redSub(p.z); + // DA = D * A + var da = d.redMul(a); + // CB = C * B + var cb = c.redMul(b); + // X5 = Z1 * (DA + CB)^2 + var nx = diff.z.redMul(da.redAdd(cb).redSqr()); + // Z5 = X1 * (DA - CB)^2 + var nz = diff.x.redMul(da.redISub(cb).redSqr()); + return this.curve.point(nx, nz); +}; + +Point.prototype.mul = function mul(k) { + var t = k.clone(); + var a = this; // (N / 2) * Q + Q + var b = this.curve.point(null, null); // (N / 2) * Q + var c = this; // Q + + for (var bits = []; t.cmpn(0) !== 0; t.iushrn(1)) + bits.push(t.andln(1)); + + for (var i = bits.length - 1; i >= 0; i--) { + if (bits[i] === 0) { + // N * Q + Q = ((N / 2) * Q + Q)) + (N / 2) * Q + a = a.diffAdd(b, c); + // N * Q = 2 * ((N / 2) * Q + Q)) + b = b.dbl(); + } else { + // N * Q = ((N / 2) * Q + Q) + ((N / 2) * Q) + b = a.diffAdd(b, c); + // N * Q + Q = 2 * ((N / 2) * Q + Q) + a = a.dbl(); + } + } + return b; +}; + +Point.prototype.mulAdd = function mulAdd() { + throw new Error('Not supported on Montgomery curve'); +}; + +Point.prototype.jumlAdd = function jumlAdd() { + throw new Error('Not supported on Montgomery curve'); +}; + +Point.prototype.eq = function eq(other) { + return this.getX().cmp(other.getX()) === 0; +}; + +Point.prototype.normalize = function normalize() { + this.x = this.x.redMul(this.z.redInvm()); + this.z = this.curve.one; + return this; +}; + +Point.prototype.getX = function getX() { + // Normalize coordinates + this.normalize(); + + return this.x.fromRed(); +}; + + +/***/ }), +/* 391 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var curve = __webpack_require__(65); +var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); +var Base = curve.base; + +var assert = elliptic.utils.assert; + +function EdwardsCurve(conf) { + // NOTE: Important as we are creating point in Base.call() + this.twisted = (conf.a | 0) !== 1; + this.mOneA = this.twisted && (conf.a | 0) === -1; + this.extended = this.mOneA; + + Base.call(this, 'edwards', conf); + + this.a = new BN(conf.a, 16).umod(this.red.m); + this.a = this.a.toRed(this.red); + this.c = new BN(conf.c, 16).toRed(this.red); + this.c2 = this.c.redSqr(); + this.d = new BN(conf.d, 16).toRed(this.red); + this.dd = this.d.redAdd(this.d); + + assert(!this.twisted || this.c.fromRed().cmpn(1) === 0); + this.oneC = (conf.c | 0) === 1; +} +inherits(EdwardsCurve, Base); +module.exports = EdwardsCurve; + +EdwardsCurve.prototype._mulA = function _mulA(num) { + if (this.mOneA) + return num.redNeg(); + else + return this.a.redMul(num); +}; + +EdwardsCurve.prototype._mulC = function _mulC(num) { + if (this.oneC) + return num; + else + return this.c.redMul(num); +}; + +// Just for compatibility with Short curve +EdwardsCurve.prototype.jpoint = function jpoint(x, y, z, t) { + return this.point(x, y, z, t); +}; + +EdwardsCurve.prototype.pointFromX = function pointFromX(x, odd) { + x = new BN(x, 16); + if (!x.red) + x = x.toRed(this.red); + + var x2 = x.redSqr(); + var rhs = this.c2.redSub(this.a.redMul(x2)); + var lhs = this.one.redSub(this.c2.redMul(this.d).redMul(x2)); + + var y2 = rhs.redMul(lhs.redInvm()); + var y = y2.redSqrt(); + if (y.redSqr().redSub(y2).cmp(this.zero) !== 0) + throw new Error('invalid point'); + + var isOdd = y.fromRed().isOdd(); + if (odd && !isOdd || !odd && isOdd) + y = y.redNeg(); + + return this.point(x, y); +}; + +EdwardsCurve.prototype.pointFromY = function pointFromY(y, odd) { + y = new BN(y, 16); + if (!y.red) + y = y.toRed(this.red); + + // x^2 = (y^2 - 1) / (d y^2 + 1) + var y2 = y.redSqr(); + var lhs = y2.redSub(this.one); + var rhs = y2.redMul(this.d).redAdd(this.one); + var x2 = lhs.redMul(rhs.redInvm()); + + if (x2.cmp(this.zero) === 0) { + if (odd) + throw new Error('invalid point'); + else + return this.point(this.zero, y); + } + + var x = x2.redSqrt(); + if (x.redSqr().redSub(x2).cmp(this.zero) !== 0) + throw new Error('invalid point'); + + if (x.isOdd() !== odd) + x = x.redNeg(); + + return this.point(x, y); +}; + +EdwardsCurve.prototype.validate = function validate(point) { + if (point.isInfinity()) + return true; + + // Curve: A * X^2 + Y^2 = C^2 * (1 + D * X^2 * Y^2) + point.normalize(); + + var x2 = point.x.redSqr(); + var y2 = point.y.redSqr(); + var lhs = x2.redMul(this.a).redAdd(y2); + var rhs = this.c2.redMul(this.one.redAdd(this.d.redMul(x2).redMul(y2))); + + return lhs.cmp(rhs) === 0; +}; + +function Point(curve, x, y, z, t) { + Base.BasePoint.call(this, curve, 'projective'); + if (x === null && y === null && z === null) { + this.x = this.curve.zero; + this.y = this.curve.one; + this.z = this.curve.one; + this.t = this.curve.zero; + this.zOne = true; + } else { + this.x = new BN(x, 16); + this.y = new BN(y, 16); + this.z = z ? new BN(z, 16) : this.curve.one; + this.t = t && new BN(t, 16); + if (!this.x.red) + this.x = this.x.toRed(this.curve.red); + if (!this.y.red) + this.y = this.y.toRed(this.curve.red); + if (!this.z.red) + this.z = this.z.toRed(this.curve.red); + if (this.t && !this.t.red) + this.t = this.t.toRed(this.curve.red); + this.zOne = this.z === this.curve.one; + + // Use extended coordinates + if (this.curve.extended && !this.t) { + this.t = this.x.redMul(this.y); + if (!this.zOne) + this.t = this.t.redMul(this.z.redInvm()); + } + } +} +inherits(Point, Base.BasePoint); + +EdwardsCurve.prototype.pointFromJSON = function pointFromJSON(obj) { + return Point.fromJSON(this, obj); +}; + +EdwardsCurve.prototype.point = function point(x, y, z, t) { + return new Point(this, x, y, z, t); +}; + +Point.fromJSON = function fromJSON(curve, obj) { + return new Point(curve, obj[0], obj[1], obj[2]); +}; + +Point.prototype.inspect = function inspect() { + if (this.isInfinity()) + return '<EC Point Infinity>'; + return '<EC Point x: ' + this.x.fromRed().toString(16, 2) + + ' y: ' + this.y.fromRed().toString(16, 2) + + ' z: ' + this.z.fromRed().toString(16, 2) + '>'; +}; + +Point.prototype.isInfinity = function isInfinity() { + // XXX This code assumes that zero is always zero in red + return this.x.cmpn(0) === 0 && + this.y.cmp(this.z) === 0; +}; + +Point.prototype._extDbl = function _extDbl() { + // hyperelliptic.org/EFD/g1p/auto-twisted-extended-1.html + // #doubling-dbl-2008-hwcd + // 4M + 4S + + // A = X1^2 + var a = this.x.redSqr(); + // B = Y1^2 + var b = this.y.redSqr(); + // C = 2 * Z1^2 + var c = this.z.redSqr(); + c = c.redIAdd(c); + // D = a * A + var d = this.curve._mulA(a); + // E = (X1 + Y1)^2 - A - B + var e = this.x.redAdd(this.y).redSqr().redISub(a).redISub(b); + // G = D + B + var g = d.redAdd(b); + // F = G - C + var f = g.redSub(c); + // H = D - B + var h = d.redSub(b); + // X3 = E * F + var nx = e.redMul(f); + // Y3 = G * H + var ny = g.redMul(h); + // T3 = E * H + var nt = e.redMul(h); + // Z3 = F * G + var nz = f.redMul(g); + return this.curve.point(nx, ny, nz, nt); +}; + +Point.prototype._projDbl = function _projDbl() { + // hyperelliptic.org/EFD/g1p/auto-twisted-projective.html + // #doubling-dbl-2008-bbjlp + // #doubling-dbl-2007-bl + // and others + // Generally 3M + 4S or 2M + 4S + + // B = (X1 + Y1)^2 + var b = this.x.redAdd(this.y).redSqr(); + // C = X1^2 + var c = this.x.redSqr(); + // D = Y1^2 + var d = this.y.redSqr(); + + var nx; + var ny; + var nz; + if (this.curve.twisted) { + // E = a * C + var e = this.curve._mulA(c); + // F = E + D + var f = e.redAdd(d); + if (this.zOne) { + // X3 = (B - C - D) * (F - 2) + nx = b.redSub(c).redSub(d).redMul(f.redSub(this.curve.two)); + // Y3 = F * (E - D) + ny = f.redMul(e.redSub(d)); + // Z3 = F^2 - 2 * F + nz = f.redSqr().redSub(f).redSub(f); + } else { + // H = Z1^2 + var h = this.z.redSqr(); + // J = F - 2 * H + var j = f.redSub(h).redISub(h); + // X3 = (B-C-D)*J + nx = b.redSub(c).redISub(d).redMul(j); + // Y3 = F * (E - D) + ny = f.redMul(e.redSub(d)); + // Z3 = F * J + nz = f.redMul(j); + } + } else { + // E = C + D + var e = c.redAdd(d); + // H = (c * Z1)^2 + var h = this.curve._mulC(this.c.redMul(this.z)).redSqr(); + // J = E - 2 * H + var j = e.redSub(h).redSub(h); + // X3 = c * (B - E) * J + nx = this.curve._mulC(b.redISub(e)).redMul(j); + // Y3 = c * E * (C - D) + ny = this.curve._mulC(e).redMul(c.redISub(d)); + // Z3 = E * J + nz = e.redMul(j); + } + return this.curve.point(nx, ny, nz); +}; + +Point.prototype.dbl = function dbl() { + if (this.isInfinity()) + return this; + + // Double in extended coordinates + if (this.curve.extended) + return this._extDbl(); + else + return this._projDbl(); +}; + +Point.prototype._extAdd = function _extAdd(p) { + // hyperelliptic.org/EFD/g1p/auto-twisted-extended-1.html + // #addition-add-2008-hwcd-3 + // 8M + + // A = (Y1 - X1) * (Y2 - X2) + var a = this.y.redSub(this.x).redMul(p.y.redSub(p.x)); + // B = (Y1 + X1) * (Y2 + X2) + var b = this.y.redAdd(this.x).redMul(p.y.redAdd(p.x)); + // C = T1 * k * T2 + var c = this.t.redMul(this.curve.dd).redMul(p.t); + // D = Z1 * 2 * Z2 + var d = this.z.redMul(p.z.redAdd(p.z)); + // E = B - A + var e = b.redSub(a); + // F = D - C + var f = d.redSub(c); + // G = D + C + var g = d.redAdd(c); + // H = B + A + var h = b.redAdd(a); + // X3 = E * F + var nx = e.redMul(f); + // Y3 = G * H + var ny = g.redMul(h); + // T3 = E * H + var nt = e.redMul(h); + // Z3 = F * G + var nz = f.redMul(g); + return this.curve.point(nx, ny, nz, nt); +}; + +Point.prototype._projAdd = function _projAdd(p) { + // hyperelliptic.org/EFD/g1p/auto-twisted-projective.html + // #addition-add-2008-bbjlp + // #addition-add-2007-bl + // 10M + 1S + + // A = Z1 * Z2 + var a = this.z.redMul(p.z); + // B = A^2 + var b = a.redSqr(); + // C = X1 * X2 + var c = this.x.redMul(p.x); + // D = Y1 * Y2 + var d = this.y.redMul(p.y); + // E = d * C * D + var e = this.curve.d.redMul(c).redMul(d); + // F = B - E + var f = b.redSub(e); + // G = B + E + var g = b.redAdd(e); + // X3 = A * F * ((X1 + Y1) * (X2 + Y2) - C - D) + var tmp = this.x.redAdd(this.y).redMul(p.x.redAdd(p.y)).redISub(c).redISub(d); + var nx = a.redMul(f).redMul(tmp); + var ny; + var nz; + if (this.curve.twisted) { + // Y3 = A * G * (D - a * C) + ny = a.redMul(g).redMul(d.redSub(this.curve._mulA(c))); + // Z3 = F * G + nz = f.redMul(g); + } else { + // Y3 = A * G * (D - C) + ny = a.redMul(g).redMul(d.redSub(c)); + // Z3 = c * F * G + nz = this.curve._mulC(f).redMul(g); + } + return this.curve.point(nx, ny, nz); +}; + +Point.prototype.add = function add(p) { + if (this.isInfinity()) + return p; + if (p.isInfinity()) + return this; + + if (this.curve.extended) + return this._extAdd(p); + else + return this._projAdd(p); +}; + +Point.prototype.mul = function mul(k) { + if (this._hasDoubles(k)) + return this.curve._fixedNafMul(this, k); + else + return this.curve._wnafMul(this, k); +}; + +Point.prototype.mulAdd = function mulAdd(k1, p, k2) { + return this.curve._wnafMulAdd(1, [ this, p ], [ k1, k2 ], 2, false); +}; + +Point.prototype.jmulAdd = function jmulAdd(k1, p, k2) { + return this.curve._wnafMulAdd(1, [ this, p ], [ k1, k2 ], 2, true); +}; + +Point.prototype.normalize = function normalize() { + if (this.zOne) + return this; + + // Normalize coordinates + var zi = this.z.redInvm(); + this.x = this.x.redMul(zi); + this.y = this.y.redMul(zi); + if (this.t) + this.t = this.t.redMul(zi); + this.z = this.curve.one; + this.zOne = true; + return this; +}; + +Point.prototype.neg = function neg() { + return this.curve.point(this.x.redNeg(), + this.y, + this.z, + this.t && this.t.redNeg()); +}; + +Point.prototype.getX = function getX() { + this.normalize(); + return this.x.fromRed(); +}; + +Point.prototype.getY = function getY() { + this.normalize(); + return this.y.fromRed(); +}; + +Point.prototype.eq = function eq(other) { + return this === other || + this.getX().cmp(other.getX()) === 0 && + this.getY().cmp(other.getY()) === 0; +}; + +Point.prototype.eqXToP = function eqXToP(x) { + var rx = x.toRed(this.curve.red).redMul(this.z); + if (this.x.cmp(rx) === 0) + return true; + + var xc = x.clone(); + var t = this.curve.redN.redMul(this.z); + for (;;) { + xc.iadd(this.curve.n); + if (xc.cmp(this.curve.p) >= 0) + return false; + + rx.redIAdd(t); + if (this.x.cmp(rx) === 0) + return true; + } + return false; +}; + +// Compatibility with BaseCurve +Point.prototype.toP = Point.prototype.normalize; +Point.prototype.mixedAdd = Point.prototype.add; + + +/***/ }), +/* 392 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var curves = exports; + +var hash = __webpack_require__(105); +var elliptic = __webpack_require__(15); + +var assert = elliptic.utils.assert; + +function PresetCurve(options) { + if (options.type === 'short') + this.curve = new elliptic.curve.short(options); + else if (options.type === 'edwards') + this.curve = new elliptic.curve.edwards(options); + else + this.curve = new elliptic.curve.mont(options); + this.g = this.curve.g; + this.n = this.curve.n; + this.hash = options.hash; + + assert(this.g.validate(), 'Invalid curve'); + assert(this.g.mul(this.n).isInfinity(), 'Invalid curve, G*N != O'); +} +curves.PresetCurve = PresetCurve; + +function defineCurve(name, options) { + Object.defineProperty(curves, name, { + configurable: true, + enumerable: true, + get: function() { + var curve = new PresetCurve(options); + Object.defineProperty(curves, name, { + configurable: true, + enumerable: true, + value: curve + }); + return curve; + } + }); +} + +defineCurve('p192', { + type: 'short', + prime: 'p192', + p: 'ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff', + a: 'ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc', + b: '64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1', + n: 'ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831', + hash: hash.sha256, + gRed: false, + g: [ + '188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012', + '07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811' + ] +}); + +defineCurve('p224', { + type: 'short', + prime: 'p224', + p: 'ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001', + a: 'ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe', + b: 'b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4', + n: 'ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d', + hash: hash.sha256, + gRed: false, + g: [ + 'b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21', + 'bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34' + ] +}); + +defineCurve('p256', { + type: 'short', + prime: null, + p: 'ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff', + a: 'ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc', + b: '5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b', + n: 'ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551', + hash: hash.sha256, + gRed: false, + g: [ + '6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296', + '4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5' + ] +}); + +defineCurve('p384', { + type: 'short', + prime: null, + p: 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'fffffffe ffffffff 00000000 00000000 ffffffff', + a: 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'fffffffe ffffffff 00000000 00000000 fffffffc', + b: 'b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f ' + + '5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef', + n: 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 ' + + 'f4372ddf 581a0db2 48b0a77a ecec196a ccc52973', + hash: hash.sha384, + gRed: false, + g: [ + 'aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 ' + + '5502f25d bf55296c 3a545e38 72760ab7', + '3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 ' + + '0a60b1ce 1d7e819d 7a431d7c 90ea0e5f' + ] +}); + +defineCurve('p521', { + type: 'short', + prime: null, + p: '000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff ffffffff ffffffff ffffffff', + a: '000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff ffffffff ffffffff fffffffc', + b: '00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b ' + + '99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd ' + + '3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00', + n: '000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 ' + + 'f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409', + hash: hash.sha512, + gRed: false, + g: [ + '000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 ' + + '053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 ' + + 'a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66', + '00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 ' + + '579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 ' + + '3fad0761 353c7086 a272c240 88be9476 9fd16650' + ] +}); + +defineCurve('curve25519', { + type: 'mont', + prime: 'p25519', + p: '7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed', + a: '76d06', + b: '1', + n: '1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed', + hash: hash.sha256, + gRed: false, + g: [ + '9' + ] +}); + +defineCurve('ed25519', { + type: 'edwards', + prime: 'p25519', + p: '7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed', + a: '-1', + c: '1', + // -121665 * (121666^(-1)) (mod P) + d: '52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3', + n: '1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed', + hash: hash.sha256, + gRed: false, + g: [ + '216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a', + + // 4/5 + '6666666666666666666666666666666666666666666666666666666666666658' + ] +}); + +var pre; +try { + pre = __webpack_require__(399); +} catch (e) { + pre = undefined; +} + +defineCurve('secp256k1', { + type: 'short', + prime: 'k256', + p: 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f', + a: '0', + b: '7', + n: 'ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141', + h: '1', + hash: hash.sha256, + + // Precomputed endomorphism + beta: '7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee', + lambda: '5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72', + basis: [ + { + a: '3086d221a7d46bcde86c90e49284eb15', + b: '-e4437ed6010e88286f547fa90abfe4c3' + }, + { + a: '114ca50f7a8e2f3f657c1108d9d44cfd8', + b: '3086d221a7d46bcde86c90e49284eb15' + } + ], + + gRed: false, + g: [ + '79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798', + '483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8', + pre + ] +}); + + +/***/ }), +/* 393 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.sha1 = __webpack_require__(394); +exports.sha224 = __webpack_require__(395); +exports.sha256 = __webpack_require__(173); +exports.sha384 = __webpack_require__(396); +exports.sha512 = __webpack_require__(174); + + +/***/ }), +/* 394 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var shaCommon = __webpack_require__(172); + +var rotl32 = utils.rotl32; +var sum32 = utils.sum32; +var sum32_5 = utils.sum32_5; +var ft_1 = shaCommon.ft_1; +var BlockHash = common.BlockHash; + +var sha1_K = [ + 0x5A827999, 0x6ED9EBA1, + 0x8F1BBCDC, 0xCA62C1D6 +]; + +function SHA1() { + if (!(this instanceof SHA1)) + return new SHA1(); + + BlockHash.call(this); + this.h = [ + 0x67452301, 0xefcdab89, 0x98badcfe, + 0x10325476, 0xc3d2e1f0 ]; + this.W = new Array(80); +} + +utils.inherits(SHA1, BlockHash); +module.exports = SHA1; + +SHA1.blockSize = 512; +SHA1.outSize = 160; +SHA1.hmacStrength = 80; +SHA1.padLength = 64; + +SHA1.prototype._update = function _update(msg, start) { + var W = this.W; + + for (var i = 0; i < 16; i++) + W[i] = msg[start + i]; + + for(; i < W.length; i++) + W[i] = rotl32(W[i - 3] ^ W[i - 8] ^ W[i - 14] ^ W[i - 16], 1); + + var a = this.h[0]; + var b = this.h[1]; + var c = this.h[2]; + var d = this.h[3]; + var e = this.h[4]; + + for (i = 0; i < W.length; i++) { + var s = ~~(i / 20); + var t = sum32_5(rotl32(a, 5), ft_1(s, b, c, d), e, W[i], sha1_K[s]); + e = d; + d = c; + c = rotl32(b, 30); + b = a; + a = t; + } + + this.h[0] = sum32(this.h[0], a); + this.h[1] = sum32(this.h[1], b); + this.h[2] = sum32(this.h[2], c); + this.h[3] = sum32(this.h[3], d); + this.h[4] = sum32(this.h[4], e); +}; + +SHA1.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'big'); + else + return utils.split32(this.h, 'big'); +}; + + +/***/ }), +/* 395 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var SHA256 = __webpack_require__(173); + +function SHA224() { + if (!(this instanceof SHA224)) + return new SHA224(); + + SHA256.call(this); + this.h = [ + 0xc1059ed8, 0x367cd507, 0x3070dd17, 0xf70e5939, + 0xffc00b31, 0x68581511, 0x64f98fa7, 0xbefa4fa4 ]; +} +utils.inherits(SHA224, SHA256); +module.exports = SHA224; + +SHA224.blockSize = 512; +SHA224.outSize = 224; +SHA224.hmacStrength = 192; +SHA224.padLength = 64; + +SHA224.prototype._digest = function digest(enc) { + // Just truncate output + if (enc === 'hex') + return utils.toHex32(this.h.slice(0, 7), 'big'); + else + return utils.split32(this.h.slice(0, 7), 'big'); +}; + + + +/***/ }), +/* 396 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); + +var SHA512 = __webpack_require__(174); + +function SHA384() { + if (!(this instanceof SHA384)) + return new SHA384(); + + SHA512.call(this); + this.h = [ + 0xcbbb9d5d, 0xc1059ed8, + 0x629a292a, 0x367cd507, + 0x9159015a, 0x3070dd17, + 0x152fecd8, 0xf70e5939, + 0x67332667, 0xffc00b31, + 0x8eb44a87, 0x68581511, + 0xdb0c2e0d, 0x64f98fa7, + 0x47b5481d, 0xbefa4fa4 ]; +} +utils.inherits(SHA384, SHA512); +module.exports = SHA384; + +SHA384.blockSize = 1024; +SHA384.outSize = 384; +SHA384.hmacStrength = 192; +SHA384.padLength = 128; + +SHA384.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h.slice(0, 12), 'big'); + else + return utils.split32(this.h.slice(0, 12), 'big'); +}; + + +/***/ }), +/* 397 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var common = __webpack_require__(50); + +var rotl32 = utils.rotl32; +var sum32 = utils.sum32; +var sum32_3 = utils.sum32_3; +var sum32_4 = utils.sum32_4; +var BlockHash = common.BlockHash; + +function RIPEMD160() { + if (!(this instanceof RIPEMD160)) + return new RIPEMD160(); + + BlockHash.call(this); + + this.h = [ 0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476, 0xc3d2e1f0 ]; + this.endian = 'little'; +} +utils.inherits(RIPEMD160, BlockHash); +exports.ripemd160 = RIPEMD160; + +RIPEMD160.blockSize = 512; +RIPEMD160.outSize = 160; +RIPEMD160.hmacStrength = 192; +RIPEMD160.padLength = 64; + +RIPEMD160.prototype._update = function update(msg, start) { + var A = this.h[0]; + var B = this.h[1]; + var C = this.h[2]; + var D = this.h[3]; + var E = this.h[4]; + var Ah = A; + var Bh = B; + var Ch = C; + var Dh = D; + var Eh = E; + for (var j = 0; j < 80; j++) { + var T = sum32( + rotl32( + sum32_4(A, f(j, B, C, D), msg[r[j] + start], K(j)), + s[j]), + E); + A = E; + E = D; + D = rotl32(C, 10); + C = B; + B = T; + T = sum32( + rotl32( + sum32_4(Ah, f(79 - j, Bh, Ch, Dh), msg[rh[j] + start], Kh(j)), + sh[j]), + Eh); + Ah = Eh; + Eh = Dh; + Dh = rotl32(Ch, 10); + Ch = Bh; + Bh = T; + } + T = sum32_3(this.h[1], C, Dh); + this.h[1] = sum32_3(this.h[2], D, Eh); + this.h[2] = sum32_3(this.h[3], E, Ah); + this.h[3] = sum32_3(this.h[4], A, Bh); + this.h[4] = sum32_3(this.h[0], B, Ch); + this.h[0] = T; +}; + +RIPEMD160.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'little'); + else + return utils.split32(this.h, 'little'); +}; + +function f(j, x, y, z) { + if (j <= 15) + return x ^ y ^ z; + else if (j <= 31) + return (x & y) | ((~x) & z); + else if (j <= 47) + return (x | (~y)) ^ z; + else if (j <= 63) + return (x & z) | (y & (~z)); + else + return x ^ (y | (~z)); +} + +function K(j) { + if (j <= 15) + return 0x00000000; + else if (j <= 31) + return 0x5a827999; + else if (j <= 47) + return 0x6ed9eba1; + else if (j <= 63) + return 0x8f1bbcdc; + else + return 0xa953fd4e; +} + +function Kh(j) { + if (j <= 15) + return 0x50a28be6; + else if (j <= 31) + return 0x5c4dd124; + else if (j <= 47) + return 0x6d703ef3; + else if (j <= 63) + return 0x7a6d76e9; + else + return 0x00000000; +} + +var r = [ + 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, + 7, 4, 13, 1, 10, 6, 15, 3, 12, 0, 9, 5, 2, 14, 11, 8, + 3, 10, 14, 4, 9, 15, 8, 1, 2, 7, 0, 6, 13, 11, 5, 12, + 1, 9, 11, 10, 0, 8, 12, 4, 13, 3, 7, 15, 14, 5, 6, 2, + 4, 0, 5, 9, 7, 12, 2, 10, 14, 1, 3, 8, 11, 6, 15, 13 +]; + +var rh = [ + 5, 14, 7, 0, 9, 2, 11, 4, 13, 6, 15, 8, 1, 10, 3, 12, + 6, 11, 3, 7, 0, 13, 5, 10, 14, 15, 8, 12, 4, 9, 1, 2, + 15, 5, 1, 3, 7, 14, 6, 9, 11, 8, 12, 2, 10, 0, 4, 13, + 8, 6, 4, 1, 3, 11, 15, 0, 5, 12, 2, 13, 9, 7, 10, 14, + 12, 15, 10, 4, 1, 5, 8, 7, 6, 2, 13, 14, 0, 3, 9, 11 +]; + +var s = [ + 11, 14, 15, 12, 5, 8, 7, 9, 11, 13, 14, 15, 6, 7, 9, 8, + 7, 6, 8, 13, 11, 9, 7, 15, 7, 12, 15, 9, 11, 7, 13, 12, + 11, 13, 6, 7, 14, 9, 13, 15, 14, 8, 13, 6, 5, 12, 7, 5, + 11, 12, 14, 15, 14, 15, 9, 8, 9, 14, 5, 6, 8, 6, 5, 12, + 9, 15, 5, 11, 6, 8, 13, 12, 5, 12, 13, 14, 11, 8, 5, 6 +]; + +var sh = [ + 8, 9, 9, 11, 13, 15, 15, 5, 7, 7, 8, 11, 14, 14, 12, 6, + 9, 13, 15, 7, 12, 8, 9, 11, 7, 7, 12, 7, 6, 15, 13, 11, + 9, 7, 15, 11, 8, 6, 6, 14, 12, 13, 5, 14, 13, 13, 7, 5, + 15, 5, 8, 11, 14, 14, 6, 14, 6, 9, 12, 9, 12, 5, 15, 8, + 8, 5, 12, 9, 12, 5, 14, 6, 8, 13, 6, 5, 15, 13, 11, 11 +]; + + +/***/ }), +/* 398 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var assert = __webpack_require__(21); + +function Hmac(hash, key, enc) { + if (!(this instanceof Hmac)) + return new Hmac(hash, key, enc); + this.Hash = hash; + this.blockSize = hash.blockSize / 8; + this.outSize = hash.outSize / 8; + this.inner = null; + this.outer = null; + + this._init(utils.toArray(key, enc)); +} +module.exports = Hmac; + +Hmac.prototype._init = function init(key) { + // Shorten key, if needed + if (key.length > this.blockSize) + key = new this.Hash().update(key).digest(); + assert(key.length <= this.blockSize); + + // Add padding to key + for (var i = key.length; i < this.blockSize; i++) + key.push(0); + + for (i = 0; i < key.length; i++) + key[i] ^= 0x36; + this.inner = new this.Hash().update(key); + + // 0x36 ^ 0x5c = 0x6a + for (i = 0; i < key.length; i++) + key[i] ^= 0x6a; + this.outer = new this.Hash().update(key); +}; + +Hmac.prototype.update = function update(msg, enc) { + this.inner.update(msg, enc); + return this; +}; + +Hmac.prototype.digest = function digest(enc) { + this.outer.update(this.inner.digest()); + return this.outer.digest(enc); +}; + + +/***/ }), +/* 399 */ +/***/ (function(module, exports) { + +module.exports = { + doubles: { + step: 4, + points: [ + [ + 'e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a', + 'f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821' + ], + [ + '8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508', + '11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf' + ], + [ + '175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739', + 'd3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695' + ], + [ + '363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640', + '4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9' + ], + [ + '8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c', + '4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36' + ], + [ + '723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda', + '96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f' + ], + [ + 'eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa', + '5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999' + ], + [ + '100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0', + 'cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09' + ], + [ + 'e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d', + '9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d' + ], + [ + 'feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d', + 'e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088' + ], + [ + 'da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1', + '9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d' + ], + [ + '53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0', + '5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8' + ], + [ + '8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047', + '10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a' + ], + [ + '385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862', + '283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453' + ], + [ + '6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7', + '7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160' + ], + [ + '3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd', + '56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0' + ], + [ + '85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83', + '7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6' + ], + [ + '948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a', + '53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589' + ], + [ + '6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8', + 'bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17' + ], + [ + 'e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d', + '4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda' + ], + [ + 'e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725', + '7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd' + ], + [ + '213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754', + '4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2' + ], + [ + '4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c', + '17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6' + ], + [ + 'fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6', + '6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f' + ], + [ + '76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39', + 'c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01' + ], + [ + 'c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891', + '893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3' + ], + [ + 'd895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b', + 'febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f' + ], + [ + 'b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03', + '2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7' + ], + [ + 'e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d', + 'eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78' + ], + [ + 'a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070', + '7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1' + ], + [ + '90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4', + 'e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150' + ], + [ + '8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da', + '662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82' + ], + [ + 'e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11', + '1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc' + ], + [ + '8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e', + 'efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b' + ], + [ + 'e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41', + '2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51' + ], + [ + 'b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef', + '67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45' + ], + [ + 'd68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8', + 'db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120' + ], + [ + '324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d', + '648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84' + ], + [ + '4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96', + '35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d' + ], + [ + '9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd', + 'ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d' + ], + [ + '6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5', + '9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8' + ], + [ + 'a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266', + '40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8' + ], + [ + '7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71', + '34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac' + ], + [ + '928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac', + 'c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f' + ], + [ + '85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751', + '1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962' + ], + [ + 'ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e', + '493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907' + ], + [ + '827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241', + 'c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec' + ], + [ + 'eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3', + 'be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d' + ], + [ + 'e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f', + '4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414' + ], + [ + '1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19', + 'aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd' + ], + [ + '146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be', + 'b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0' + ], + [ + 'fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9', + '6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811' + ], + [ + 'da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2', + '8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1' + ], + [ + 'a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13', + '7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c' + ], + [ + '174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c', + 'ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73' + ], + [ + '959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba', + '2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd' + ], + [ + 'd2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151', + 'e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405' + ], + [ + '64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073', + 'd99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589' + ], + [ + '8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458', + '38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e' + ], + [ + '13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b', + '69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27' + ], + [ + 'bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366', + 'd3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1' + ], + [ + '8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa', + '40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482' + ], + [ + '8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0', + '620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945' + ], + [ + 'dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787', + '7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573' + ], + [ + 'f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e', + 'ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82' + ] + ] + }, + naf: { + wnd: 7, + points: [ + [ + 'f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9', + '388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672' + ], + [ + '2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4', + 'd8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6' + ], + [ + '5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc', + '6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da' + ], + [ + 'acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe', + 'cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37' + ], + [ + '774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb', + 'd984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b' + ], + [ + 'f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8', + 'ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81' + ], + [ + 'd7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e', + '581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58' + ], + [ + 'defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34', + '4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77' + ], + [ + '2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c', + '85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a' + ], + [ + '352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5', + '321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c' + ], + [ + '2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f', + '2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67' + ], + [ + '9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714', + '73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402' + ], + [ + 'daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729', + 'a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55' + ], + [ + 'c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db', + '2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482' + ], + [ + '6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4', + 'e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82' + ], + [ + '1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5', + 'b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396' + ], + [ + '605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479', + '2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49' + ], + [ + '62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d', + '80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf' + ], + [ + '80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f', + '1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a' + ], + [ + '7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb', + 'd0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7' + ], + [ + 'd528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9', + 'eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933' + ], + [ + '49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963', + '758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a' + ], + [ + '77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74', + '958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6' + ], + [ + 'f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530', + 'e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37' + ], + [ + '463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b', + '5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e' + ], + [ + 'f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247', + 'cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6' + ], + [ + 'caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1', + 'cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476' + ], + [ + '2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120', + '4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40' + ], + [ + '7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435', + '91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61' + ], + [ + '754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18', + '673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683' + ], + [ + 'e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8', + '59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5' + ], + [ + '186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb', + '3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b' + ], + [ + 'df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f', + '55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417' + ], + [ + '5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143', + 'efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868' + ], + [ + '290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba', + 'e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a' + ], + [ + 'af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45', + 'f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6' + ], + [ + '766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a', + '744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996' + ], + [ + '59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e', + 'c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e' + ], + [ + 'f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8', + 'e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d' + ], + [ + '7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c', + '30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2' + ], + [ + '948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519', + 'e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e' + ], + [ + '7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab', + '100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437' + ], + [ + '3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca', + 'ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311' + ], + [ + 'd3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf', + '8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4' + ], + [ + '1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610', + '68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575' + ], + [ + '733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4', + 'f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d' + ], + [ + '15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c', + 'd56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d' + ], + [ + 'a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940', + 'edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629' + ], + [ + 'e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980', + 'a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06' + ], + [ + '311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3', + '66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374' + ], + [ + '34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf', + '9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee' + ], + [ + 'f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63', + '4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1' + ], + [ + 'd7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448', + 'fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b' + ], + [ + '32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf', + '5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661' + ], + [ + '7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5', + '8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6' + ], + [ + 'ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6', + '8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e' + ], + [ + '16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5', + '5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d' + ], + [ + 'eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99', + 'f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc' + ], + [ + '78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51', + 'f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4' + ], + [ + '494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5', + '42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c' + ], + [ + 'a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5', + '204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b' + ], + [ + 'c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997', + '4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913' + ], + [ + '841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881', + '73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154' + ], + [ + '5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5', + '39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865' + ], + [ + '36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66', + 'd2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc' + ], + [ + '336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726', + 'ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224' + ], + [ + '8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede', + '6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e' + ], + [ + '1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94', + '60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6' + ], + [ + '85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31', + '3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511' + ], + [ + '29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51', + 'b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b' + ], + [ + 'a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252', + 'ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2' + ], + [ + '4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5', + 'cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c' + ], + [ + 'd24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b', + '6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3' + ], + [ + 'ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4', + '322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d' + ], + [ + 'af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f', + '6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700' + ], + [ + 'e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889', + '2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4' + ], + [ + '591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246', + 'b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196' + ], + [ + '11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984', + '998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4' + ], + [ + '3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a', + 'b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257' + ], + [ + 'cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030', + 'bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13' + ], + [ + 'c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197', + '6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096' + ], + [ + 'c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593', + 'c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38' + ], + [ + 'a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef', + '21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f' + ], + [ + '347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38', + '60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448' + ], + [ + 'da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a', + '49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a' + ], + [ + 'c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111', + '5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4' + ], + [ + '4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502', + '7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437' + ], + [ + '3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea', + 'be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7' + ], + [ + 'cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26', + '8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d' + ], + [ + 'b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986', + '39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a' + ], + [ + 'd4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e', + '62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54' + ], + [ + '48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4', + '25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77' + ], + [ + 'dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda', + 'ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517' + ], + [ + '6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859', + 'cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10' + ], + [ + 'e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f', + 'f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125' + ], + [ + 'eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c', + '6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e' + ], + [ + '13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942', + 'fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1' + ], + [ + 'ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a', + '1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2' + ], + [ + 'b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80', + '5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423' + ], + [ + 'ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d', + '438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8' + ], + [ + '8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1', + 'cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758' + ], + [ + '52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63', + 'c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375' + ], + [ + 'e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352', + '6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d' + ], + [ + '7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193', + 'ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec' + ], + [ + '5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00', + '9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0' + ], + [ + '32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58', + 'ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c' + ], + [ + 'e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7', + 'd3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4' + ], + [ + '8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8', + 'c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f' + ], + [ + '4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e', + '67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649' + ], + [ + '3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d', + 'cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826' + ], + [ + '674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b', + '299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5' + ], + [ + 'd32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f', + 'f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87' + ], + [ + '30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6', + '462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b' + ], + [ + 'be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297', + '62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc' + ], + [ + '93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a', + '7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c' + ], + [ + 'b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c', + 'ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f' + ], + [ + 'd5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52', + '4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a' + ], + [ + 'd3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb', + 'bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46' + ], + [ + '463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065', + 'bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f' + ], + [ + '7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917', + '603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03' + ], + [ + '74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9', + 'cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08' + ], + [ + '30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3', + '553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8' + ], + [ + '9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57', + '712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373' + ], + [ + '176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66', + 'ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3' + ], + [ + '75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8', + '9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8' + ], + [ + '809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721', + '9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1' + ], + [ + '1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180', + '4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9' + ] + ] + } +}; + + +/***/ }), +/* 400 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var BN = __webpack_require__(11); +var HmacDRBG = __webpack_require__(401); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; + +var KeyPair = __webpack_require__(402); +var Signature = __webpack_require__(403); + +function EC(options) { + if (!(this instanceof EC)) + return new EC(options); + + // Shortcut `elliptic.ec(curve-name)` + if (typeof options === 'string') { + assert(elliptic.curves.hasOwnProperty(options), 'Unknown curve ' + options); + + options = elliptic.curves[options]; + } + + // Shortcut for `elliptic.ec(elliptic.curves.curveName)` + if (options instanceof elliptic.curves.PresetCurve) + options = { curve: options }; + + this.curve = options.curve.curve; + this.n = this.curve.n; + this.nh = this.n.ushrn(1); + this.g = this.curve.g; + + // Point on curve + this.g = options.curve.g; + this.g.precompute(options.curve.n.bitLength() + 1); + + // Hash for function for DRBG + this.hash = options.hash || options.curve.hash; +} +module.exports = EC; + +EC.prototype.keyPair = function keyPair(options) { + return new KeyPair(this, options); +}; + +EC.prototype.keyFromPrivate = function keyFromPrivate(priv, enc) { + return KeyPair.fromPrivate(this, priv, enc); +}; + +EC.prototype.keyFromPublic = function keyFromPublic(pub, enc) { + return KeyPair.fromPublic(this, pub, enc); +}; + +EC.prototype.genKeyPair = function genKeyPair(options) { + if (!options) + options = {}; + + // Instantiate Hmac_DRBG + var drbg = new HmacDRBG({ + hash: this.hash, + pers: options.pers, + persEnc: options.persEnc || 'utf8', + entropy: options.entropy || elliptic.rand(this.hash.hmacStrength), + entropyEnc: options.entropy && options.entropyEnc || 'utf8', + nonce: this.n.toArray() + }); + + var bytes = this.n.byteLength(); + var ns2 = this.n.sub(new BN(2)); + do { + var priv = new BN(drbg.generate(bytes)); + if (priv.cmp(ns2) > 0) + continue; + + priv.iaddn(1); + return this.keyFromPrivate(priv); + } while (true); +}; + +EC.prototype._truncateToN = function truncateToN(msg, truncOnly) { + var delta = msg.byteLength() * 8 - this.n.bitLength(); + if (delta > 0) + msg = msg.ushrn(delta); + if (!truncOnly && msg.cmp(this.n) >= 0) + return msg.sub(this.n); + else + return msg; +}; + +EC.prototype.sign = function sign(msg, key, enc, options) { + if (typeof enc === 'object') { + options = enc; + enc = null; + } + if (!options) + options = {}; + + key = this.keyFromPrivate(key, enc); + msg = this._truncateToN(new BN(msg, 16)); + + // Zero-extend key to provide enough entropy + var bytes = this.n.byteLength(); + var bkey = key.getPrivate().toArray('be', bytes); + + // Zero-extend nonce to have the same byte size as N + var nonce = msg.toArray('be', bytes); + + // Instantiate Hmac_DRBG + var drbg = new HmacDRBG({ + hash: this.hash, + entropy: bkey, + nonce: nonce, + pers: options.pers, + persEnc: options.persEnc || 'utf8' + }); + + // Number of bytes to generate + var ns1 = this.n.sub(new BN(1)); + + for (var iter = 0; true; iter++) { + var k = options.k ? + options.k(iter) : + new BN(drbg.generate(this.n.byteLength())); + k = this._truncateToN(k, true); + if (k.cmpn(1) <= 0 || k.cmp(ns1) >= 0) + continue; + + var kp = this.g.mul(k); + if (kp.isInfinity()) + continue; + + var kpX = kp.getX(); + var r = kpX.umod(this.n); + if (r.cmpn(0) === 0) + continue; + + var s = k.invm(this.n).mul(r.mul(key.getPrivate()).iadd(msg)); + s = s.umod(this.n); + if (s.cmpn(0) === 0) + continue; + + var recoveryParam = (kp.getY().isOdd() ? 1 : 0) | + (kpX.cmp(r) !== 0 ? 2 : 0); + + // Use complement of `s`, if it is > `n / 2` + if (options.canonical && s.cmp(this.nh) > 0) { + s = this.n.sub(s); + recoveryParam ^= 1; + } + + return new Signature({ r: r, s: s, recoveryParam: recoveryParam }); + } +}; + +EC.prototype.verify = function verify(msg, signature, key, enc) { + msg = this._truncateToN(new BN(msg, 16)); + key = this.keyFromPublic(key, enc); + signature = new Signature(signature, 'hex'); + + // Perform primitive values validation + var r = signature.r; + var s = signature.s; + if (r.cmpn(1) < 0 || r.cmp(this.n) >= 0) + return false; + if (s.cmpn(1) < 0 || s.cmp(this.n) >= 0) + return false; + + // Validate signature + var sinv = s.invm(this.n); + var u1 = sinv.mul(msg).umod(this.n); + var u2 = sinv.mul(r).umod(this.n); + + if (!this.curve._maxwellTrick) { + var p = this.g.mulAdd(u1, key.getPublic(), u2); + if (p.isInfinity()) + return false; + + return p.getX().umod(this.n).cmp(r) === 0; + } + + // NOTE: Greg Maxwell's trick, inspired by: + // https://git.io/vad3K + + var p = this.g.jmulAdd(u1, key.getPublic(), u2); + if (p.isInfinity()) + return false; + + // Compare `p.x` of Jacobian point with `r`, + // this will do `p.x == r * p.z^2` instead of multiplying `p.x` by the + // inverse of `p.z^2` + return p.eqXToP(r); +}; + +EC.prototype.recoverPubKey = function(msg, signature, j, enc) { + assert((3 & j) === j, 'The recovery param is more than two bits'); + signature = new Signature(signature, enc); + + var n = this.n; + var e = new BN(msg); + var r = signature.r; + var s = signature.s; + + // A set LSB signifies that the y-coordinate is odd + var isYOdd = j & 1; + var isSecondKey = j >> 1; + if (r.cmp(this.curve.p.umod(this.curve.n)) >= 0 && isSecondKey) + throw new Error('Unable to find sencond key candinate'); + + // 1.1. Let x = r + jn. + if (isSecondKey) + r = this.curve.pointFromX(r.add(this.curve.n), isYOdd); + else + r = this.curve.pointFromX(r, isYOdd); + + var rInv = signature.r.invm(n); + var s1 = n.sub(e).mul(rInv).umod(n); + var s2 = s.mul(rInv).umod(n); + + // 1.6.1 Compute Q = r^-1 (sR - eG) + // Q = r^-1 (sR + -eG) + return this.g.mulAdd(s1, r, s2); +}; + +EC.prototype.getKeyRecoveryParam = function(e, signature, Q, enc) { + signature = new Signature(signature, enc); + if (signature.recoveryParam !== null) + return signature.recoveryParam; + + for (var i = 0; i < 4; i++) { + var Qprime; + try { + Qprime = this.recoverPubKey(e, signature, i); + } catch (e) { + continue; + } + + if (Qprime.eq(Q)) + return i; + } + throw new Error('Unable to find valid recovery factor'); +}; + + +/***/ }), +/* 401 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var hash = __webpack_require__(105); +var utils = __webpack_require__(170); +var assert = __webpack_require__(21); + +function HmacDRBG(options) { + if (!(this instanceof HmacDRBG)) + return new HmacDRBG(options); + this.hash = options.hash; + this.predResist = !!options.predResist; + + this.outLen = this.hash.outSize; + this.minEntropy = options.minEntropy || this.hash.hmacStrength; + + this._reseed = null; + this.reseedInterval = null; + this.K = null; + this.V = null; + + var entropy = utils.toArray(options.entropy, options.entropyEnc || 'hex'); + var nonce = utils.toArray(options.nonce, options.nonceEnc || 'hex'); + var pers = utils.toArray(options.pers, options.persEnc || 'hex'); + assert(entropy.length >= (this.minEntropy / 8), + 'Not enough entropy. Minimum is: ' + this.minEntropy + ' bits'); + this._init(entropy, nonce, pers); +} +module.exports = HmacDRBG; + +HmacDRBG.prototype._init = function init(entropy, nonce, pers) { + var seed = entropy.concat(nonce).concat(pers); + + this.K = new Array(this.outLen / 8); + this.V = new Array(this.outLen / 8); + for (var i = 0; i < this.V.length; i++) { + this.K[i] = 0x00; + this.V[i] = 0x01; + } + + this._update(seed); + this._reseed = 1; + this.reseedInterval = 0x1000000000000; // 2^48 +}; + +HmacDRBG.prototype._hmac = function hmac() { + return new hash.hmac(this.hash, this.K); +}; + +HmacDRBG.prototype._update = function update(seed) { + var kmac = this._hmac() + .update(this.V) + .update([ 0x00 ]); + if (seed) + kmac = kmac.update(seed); + this.K = kmac.digest(); + this.V = this._hmac().update(this.V).digest(); + if (!seed) + return; + + this.K = this._hmac() + .update(this.V) + .update([ 0x01 ]) + .update(seed) + .digest(); + this.V = this._hmac().update(this.V).digest(); +}; + +HmacDRBG.prototype.reseed = function reseed(entropy, entropyEnc, add, addEnc) { + // Optional entropy enc + if (typeof entropyEnc !== 'string') { + addEnc = add; + add = entropyEnc; + entropyEnc = null; + } + + entropy = utils.toArray(entropy, entropyEnc); + add = utils.toArray(add, addEnc); + + assert(entropy.length >= (this.minEntropy / 8), + 'Not enough entropy. Minimum is: ' + this.minEntropy + ' bits'); + + this._update(entropy.concat(add || [])); + this._reseed = 1; +}; + +HmacDRBG.prototype.generate = function generate(len, enc, add, addEnc) { + if (this._reseed > this.reseedInterval) + throw new Error('Reseed is required'); + + // Optional encoding + if (typeof enc !== 'string') { + addEnc = add; + add = enc; + enc = null; + } + + // Optional additional data + if (add) { + add = utils.toArray(add, addEnc || 'hex'); + this._update(add); + } + + var temp = []; + while (temp.length < len) { + this.V = this._hmac().update(this.V).digest(); + temp = temp.concat(this.V); + } + + var res = temp.slice(0, len); + this._update(add); + this._reseed++; + return utils.encode(res, enc); +}; + + +/***/ }), +/* 402 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; + +function KeyPair(ec, options) { + this.ec = ec; + this.priv = null; + this.pub = null; + + // KeyPair(ec, { priv: ..., pub: ... }) + if (options.priv) + this._importPrivate(options.priv, options.privEnc); + if (options.pub) + this._importPublic(options.pub, options.pubEnc); +} +module.exports = KeyPair; + +KeyPair.fromPublic = function fromPublic(ec, pub, enc) { + if (pub instanceof KeyPair) + return pub; + + return new KeyPair(ec, { + pub: pub, + pubEnc: enc + }); +}; + +KeyPair.fromPrivate = function fromPrivate(ec, priv, enc) { + if (priv instanceof KeyPair) + return priv; + + return new KeyPair(ec, { + priv: priv, + privEnc: enc + }); +}; + +KeyPair.prototype.validate = function validate() { + var pub = this.getPublic(); + + if (pub.isInfinity()) + return { result: false, reason: 'Invalid public key' }; + if (!pub.validate()) + return { result: false, reason: 'Public key is not a point' }; + if (!pub.mul(this.ec.curve.n).isInfinity()) + return { result: false, reason: 'Public key * N != O' }; + + return { result: true, reason: null }; +}; + +KeyPair.prototype.getPublic = function getPublic(compact, enc) { + // compact is optional argument + if (typeof compact === 'string') { + enc = compact; + compact = null; + } + + if (!this.pub) + this.pub = this.ec.g.mul(this.priv); + + if (!enc) + return this.pub; + + return this.pub.encode(enc, compact); +}; + +KeyPair.prototype.getPrivate = function getPrivate(enc) { + if (enc === 'hex') + return this.priv.toString(16, 2); + else + return this.priv; +}; + +KeyPair.prototype._importPrivate = function _importPrivate(key, enc) { + this.priv = new BN(key, enc || 16); + + // Ensure that the priv won't be bigger than n, otherwise we may fail + // in fixed multiplication method + this.priv = this.priv.umod(this.ec.curve.n); +}; + +KeyPair.prototype._importPublic = function _importPublic(key, enc) { + if (key.x || key.y) { + // Montgomery points only have an `x` coordinate. + // Weierstrass/Edwards points on the other hand have both `x` and + // `y` coordinates. + if (this.ec.curve.type === 'mont') { + assert(key.x, 'Need x coordinate'); + } else if (this.ec.curve.type === 'short' || + this.ec.curve.type === 'edwards') { + assert(key.x && key.y, 'Need both x and y coordinate'); + } + this.pub = this.ec.curve.point(key.x, key.y); + return; + } + this.pub = this.ec.curve.decodePoint(key, enc); +}; + +// ECDH +KeyPair.prototype.derive = function derive(pub) { + return pub.mul(this.priv).getX(); +}; + +// ECDSA +KeyPair.prototype.sign = function sign(msg, enc, options) { + return this.ec.sign(msg, this, enc, options); +}; + +KeyPair.prototype.verify = function verify(msg, signature) { + return this.ec.verify(msg, signature, this); +}; + +KeyPair.prototype.inspect = function inspect() { + return '<Key priv: ' + (this.priv && this.priv.toString(16, 2)) + + ' pub: ' + (this.pub && this.pub.inspect()) + ' >'; +}; + + +/***/ }), +/* 403 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var BN = __webpack_require__(11); + +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; + +function Signature(options, enc) { + if (options instanceof Signature) + return options; + + if (this._importDER(options, enc)) + return; + + assert(options.r && options.s, 'Signature without r or s'); + this.r = new BN(options.r, 16); + this.s = new BN(options.s, 16); + if (options.recoveryParam === undefined) + this.recoveryParam = null; + else + this.recoveryParam = options.recoveryParam; +} +module.exports = Signature; + +function Position() { + this.place = 0; +} + +function getLength(buf, p) { + var initial = buf[p.place++]; + if (!(initial & 0x80)) { + return initial; + } + var octetLen = initial & 0xf; + var val = 0; + for (var i = 0, off = p.place; i < octetLen; i++, off++) { + val <<= 8; + val |= buf[off]; + } + p.place = off; + return val; +} + +function rmPadding(buf) { + var i = 0; + var len = buf.length - 1; + while (!buf[i] && !(buf[i + 1] & 0x80) && i < len) { + i++; + } + if (i === 0) { + return buf; + } + return buf.slice(i); +} + +Signature.prototype._importDER = function _importDER(data, enc) { + data = utils.toArray(data, enc); + var p = new Position(); + if (data[p.place++] !== 0x30) { + return false; + } + var len = getLength(data, p); + if ((len + p.place) !== data.length) { + return false; + } + if (data[p.place++] !== 0x02) { + return false; + } + var rlen = getLength(data, p); + var r = data.slice(p.place, rlen + p.place); + p.place += rlen; + if (data[p.place++] !== 0x02) { + return false; + } + var slen = getLength(data, p); + if (data.length !== slen + p.place) { + return false; + } + var s = data.slice(p.place, slen + p.place); + if (r[0] === 0 && (r[1] & 0x80)) { + r = r.slice(1); + } + if (s[0] === 0 && (s[1] & 0x80)) { + s = s.slice(1); + } + + this.r = new BN(r); + this.s = new BN(s); + this.recoveryParam = null; + + return true; +}; + +function constructLength(arr, len) { + if (len < 0x80) { + arr.push(len); + return; + } + var octets = 1 + (Math.log(len) / Math.LN2 >>> 3); + arr.push(octets | 0x80); + while (--octets) { + arr.push((len >>> (octets << 3)) & 0xff); + } + arr.push(len); +} + +Signature.prototype.toDER = function toDER(enc) { + var r = this.r.toArray(); + var s = this.s.toArray(); + + // Pad values + if (r[0] & 0x80) + r = [ 0 ].concat(r); + // Pad values + if (s[0] & 0x80) + s = [ 0 ].concat(s); + + r = rmPadding(r); + s = rmPadding(s); + + while (!s[0] && !(s[1] & 0x80)) { + s = s.slice(1); + } + var arr = [ 0x02 ]; + constructLength(arr, r.length); + arr = arr.concat(r); + arr.push(0x02); + constructLength(arr, s.length); + var backHalf = arr.concat(s); + var res = [ 0x30 ]; + constructLength(res, backHalf.length); + res = res.concat(backHalf); + return utils.encode(res, enc); +}; + + +/***/ }), +/* 404 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var hash = __webpack_require__(105); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; +var parseBytes = utils.parseBytes; +var KeyPair = __webpack_require__(405); +var Signature = __webpack_require__(406); + +function EDDSA(curve) { + assert(curve === 'ed25519', 'only tested with ed25519 so far'); + + if (!(this instanceof EDDSA)) + return new EDDSA(curve); + + var curve = elliptic.curves[curve].curve; + this.curve = curve; + this.g = curve.g; + this.g.precompute(curve.n.bitLength() + 1); + + this.pointClass = curve.point().constructor; + this.encodingLength = Math.ceil(curve.n.bitLength() / 8); + this.hash = hash.sha512; +} + +module.exports = EDDSA; + +/** +* @param {Array|String} message - message bytes +* @param {Array|String|KeyPair} secret - secret bytes or a keypair +* @returns {Signature} - signature +*/ +EDDSA.prototype.sign = function sign(message, secret) { + message = parseBytes(message); + var key = this.keyFromSecret(secret); + var r = this.hashInt(key.messagePrefix(), message); + var R = this.g.mul(r); + var Rencoded = this.encodePoint(R); + var s_ = this.hashInt(Rencoded, key.pubBytes(), message) + .mul(key.priv()); + var S = r.add(s_).umod(this.curve.n); + return this.makeSignature({ R: R, S: S, Rencoded: Rencoded }); +}; + +/** +* @param {Array} message - message bytes +* @param {Array|String|Signature} sig - sig bytes +* @param {Array|String|Point|KeyPair} pub - public key +* @returns {Boolean} - true if public key matches sig of message +*/ +EDDSA.prototype.verify = function verify(message, sig, pub) { + message = parseBytes(message); + sig = this.makeSignature(sig); + var key = this.keyFromPublic(pub); + var h = this.hashInt(sig.Rencoded(), key.pubBytes(), message); + var SG = this.g.mul(sig.S()); + var RplusAh = sig.R().add(key.pub().mul(h)); + return RplusAh.eq(SG); +}; + +EDDSA.prototype.hashInt = function hashInt() { + var hash = this.hash(); + for (var i = 0; i < arguments.length; i++) + hash.update(arguments[i]); + return utils.intFromLE(hash.digest()).umod(this.curve.n); +}; + +EDDSA.prototype.keyFromPublic = function keyFromPublic(pub) { + return KeyPair.fromPublic(this, pub); +}; + +EDDSA.prototype.keyFromSecret = function keyFromSecret(secret) { + return KeyPair.fromSecret(this, secret); +}; + +EDDSA.prototype.makeSignature = function makeSignature(sig) { + if (sig instanceof Signature) + return sig; + return new Signature(this, sig); +}; + +/** +* * https://tools.ietf.org/html/draft-josefsson-eddsa-ed25519-03#section-5.2 +* +* EDDSA defines methods for encoding and decoding points and integers. These are +* helper convenience methods, that pass along to utility functions implied +* parameters. +* +*/ +EDDSA.prototype.encodePoint = function encodePoint(point) { + var enc = point.getY().toArray('le', this.encodingLength); + enc[this.encodingLength - 1] |= point.getX().isOdd() ? 0x80 : 0; + return enc; +}; + +EDDSA.prototype.decodePoint = function decodePoint(bytes) { + bytes = utils.parseBytes(bytes); + + var lastIx = bytes.length - 1; + var normed = bytes.slice(0, lastIx).concat(bytes[lastIx] & ~0x80); + var xIsOdd = (bytes[lastIx] & 0x80) !== 0; + + var y = utils.intFromLE(normed); + return this.curve.pointFromY(y, xIsOdd); +}; + +EDDSA.prototype.encodeInt = function encodeInt(num) { + return num.toArray('le', this.encodingLength); +}; + +EDDSA.prototype.decodeInt = function decodeInt(bytes) { + return utils.intFromLE(bytes); +}; + +EDDSA.prototype.isPoint = function isPoint(val) { + return val instanceof this.pointClass; +}; + + +/***/ }), +/* 405 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; +var parseBytes = utils.parseBytes; +var cachedProperty = utils.cachedProperty; + +/** +* @param {EDDSA} eddsa - instance +* @param {Object} params - public/private key parameters +* +* @param {Array<Byte>} [params.secret] - secret seed bytes +* @param {Point} [params.pub] - public key point (aka `A` in eddsa terms) +* @param {Array<Byte>} [params.pub] - public key point encoded as bytes +* +*/ +function KeyPair(eddsa, params) { + this.eddsa = eddsa; + this._secret = parseBytes(params.secret); + if (eddsa.isPoint(params.pub)) + this._pub = params.pub; + else + this._pubBytes = parseBytes(params.pub); +} + +KeyPair.fromPublic = function fromPublic(eddsa, pub) { + if (pub instanceof KeyPair) + return pub; + return new KeyPair(eddsa, { pub: pub }); +}; + +KeyPair.fromSecret = function fromSecret(eddsa, secret) { + if (secret instanceof KeyPair) + return secret; + return new KeyPair(eddsa, { secret: secret }); +}; + +KeyPair.prototype.secret = function secret() { + return this._secret; +}; + +cachedProperty(KeyPair, 'pubBytes', function pubBytes() { + return this.eddsa.encodePoint(this.pub()); +}); + +cachedProperty(KeyPair, 'pub', function pub() { + if (this._pubBytes) + return this.eddsa.decodePoint(this._pubBytes); + return this.eddsa.g.mul(this.priv()); +}); + +cachedProperty(KeyPair, 'privBytes', function privBytes() { + var eddsa = this.eddsa; + var hash = this.hash(); + var lastIx = eddsa.encodingLength - 1; + + var a = hash.slice(0, eddsa.encodingLength); + a[0] &= 248; + a[lastIx] &= 127; + a[lastIx] |= 64; + + return a; +}); + +cachedProperty(KeyPair, 'priv', function priv() { + return this.eddsa.decodeInt(this.privBytes()); +}); + +cachedProperty(KeyPair, 'hash', function hash() { + return this.eddsa.hash().update(this.secret()).digest(); +}); + +cachedProperty(KeyPair, 'messagePrefix', function messagePrefix() { + return this.hash().slice(this.eddsa.encodingLength); +}); + +KeyPair.prototype.sign = function sign(message) { + assert(this._secret, 'KeyPair can only verify'); + return this.eddsa.sign(message, this); +}; + +KeyPair.prototype.verify = function verify(message, sig) { + return this.eddsa.verify(message, sig, this); +}; + +KeyPair.prototype.getSecret = function getSecret(enc) { + assert(this._secret, 'KeyPair is public only'); + return utils.encode(this.secret(), enc); +}; + +KeyPair.prototype.getPublic = function getPublic(enc) { + return utils.encode(this.pubBytes(), enc); +}; + +module.exports = KeyPair; + + +/***/ }), +/* 406 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; +var cachedProperty = utils.cachedProperty; +var parseBytes = utils.parseBytes; + +/** +* @param {EDDSA} eddsa - eddsa instance +* @param {Array<Bytes>|Object} sig - +* @param {Array<Bytes>|Point} [sig.R] - R point as Point or bytes +* @param {Array<Bytes>|bn} [sig.S] - S scalar as bn or bytes +* @param {Array<Bytes>} [sig.Rencoded] - R point encoded +* @param {Array<Bytes>} [sig.Sencoded] - S scalar encoded +*/ +function Signature(eddsa, sig) { + this.eddsa = eddsa; + + if (typeof sig !== 'object') + sig = parseBytes(sig); + + if (Array.isArray(sig)) { + sig = { + R: sig.slice(0, eddsa.encodingLength), + S: sig.slice(eddsa.encodingLength) + }; + } + + assert(sig.R && sig.S, 'Signature without R or S'); + + if (eddsa.isPoint(sig.R)) + this._R = sig.R; + if (sig.S instanceof BN) + this._S = sig.S; + + this._Rencoded = Array.isArray(sig.R) ? sig.R : sig.Rencoded; + this._Sencoded = Array.isArray(sig.S) ? sig.S : sig.Sencoded; +} + +cachedProperty(Signature, 'S', function S() { + return this.eddsa.decodeInt(this.Sencoded()); +}); + +cachedProperty(Signature, 'R', function R() { + return this.eddsa.decodePoint(this.Rencoded()); +}); + +cachedProperty(Signature, 'Rencoded', function Rencoded() { + return this.eddsa.encodePoint(this.R()); +}); + +cachedProperty(Signature, 'Sencoded', function Sencoded() { + return this.eddsa.encodeInt(this.S()); +}); + +Signature.prototype.toBytes = function toBytes() { + return this.Rencoded().concat(this.Sencoded()); +}; + +Signature.prototype.toHex = function toHex() { + return utils.encode(this.toBytes(), 'hex').toUpperCase(); +}; + +module.exports = Signature; + + +/***/ }), +/* 407 */ +/***/ (function(module, exports) { + +module.exports = { + "name": "bigi", + "version": "1.4.2", + "description": "Big integers.", + "keywords": [ + "cryptography", + "math", + "bitcoin", + "arbitrary", + "precision", + "arithmetic", + "big", + "integer", + "int", + "number", + "biginteger", + "bigint", + "bignumber", + "decimal", + "float" + ], + "devDependencies": { + "coveralls": "^2.11.2", + "istanbul": "^0.3.5", + "jshint": "^2.5.1", + "mocha": "^2.1.0", + "mochify": "^2.1.0" + }, + "repository": { + "url": "https://github.com/cryptocoinjs/bigi", + "type": "git" + }, + "main": "./lib/index.js", + "scripts": { + "browser-test": "./node_modules/.bin/mochify --wd -R spec", + "test": "./node_modules/.bin/_mocha -- test/*.js", + "jshint": "./node_modules/.bin/jshint --config jshint.json lib/*.js ; true", + "unit": "./node_modules/.bin/mocha", + "coverage": "./node_modules/.bin/istanbul cover ./node_modules/.bin/_mocha -- --reporter list test/*.js", + "coveralls": "npm run-script coverage && node ./node_modules/.bin/coveralls < coverage/lcov.info" + }, + "dependencies": {}, + "testling": { + "files": "test/*.js", + "harness": "mocha", + "browsers": [ + "ie/9..latest", + "firefox/latest", + "chrome/latest", + "safari/6.0..latest", + "iphone/6.0..latest", + "android-browser/4.2..latest" + ] + } +}; + +/***/ }), +/* 408 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {// FIXME: Kind of a weird way to throw exceptions, consider removing +var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(175) + +/** + * Turns a byte array into a big integer. + * + * This function will interpret a byte array as a big integer in big + * endian notation. + */ +BigInteger.fromByteArrayUnsigned = function(byteArray) { + // BigInteger expects a DER integer conformant byte array + if (byteArray[0] & 0x80) { + return new BigInteger([0].concat(byteArray)) + } + + return new BigInteger(byteArray) +} + +/** + * Returns a byte array representation of the big integer. + * + * This returns the absolute of the contained value in big endian + * form. A value of zero results in an empty array. + */ +BigInteger.prototype.toByteArrayUnsigned = function() { + var byteArray = this.toByteArray() + return byteArray[0] === 0 ? byteArray.slice(1) : byteArray +} + +BigInteger.fromDERInteger = function(byteArray) { + return new BigInteger(byteArray) +} + +/* + * Converts BigInteger to a DER integer representation. + * + * The format for this value uses the most significant bit as a sign + * bit. If the most significant bit is already set and the integer is + * positive, a 0x00 is prepended. + * + * Examples: + * + * 0 => 0x00 + * 1 => 0x01 + * -1 => 0xff + * 127 => 0x7f + * -127 => 0x81 + * 128 => 0x0080 + * -128 => 0x80 + * 255 => 0x00ff + * -255 => 0xff01 + * 16300 => 0x3fac + * -16300 => 0xc054 + * 62300 => 0x00f35c + * -62300 => 0xff0ca4 +*/ +BigInteger.prototype.toDERInteger = BigInteger.prototype.toByteArray + +BigInteger.fromBuffer = function(buffer) { + // BigInteger expects a DER integer conformant byte array + if (buffer[0] & 0x80) { + var byteArray = Array.prototype.slice.call(buffer) + + return new BigInteger([0].concat(byteArray)) + } + + return new BigInteger(buffer) +} + +BigInteger.fromHex = function(hex) { + if (hex === '') return BigInteger.ZERO + + assert.equal(hex, hex.match(/^[A-Fa-f0-9]+/), 'Invalid hex string') + assert.equal(hex.length % 2, 0, 'Incomplete hex') + return new BigInteger(hex, 16) +} + +BigInteger.prototype.toBuffer = function(size) { + var byteArray = this.toByteArrayUnsigned() + var zeros = [] + + var padding = size - byteArray.length + while (zeros.length < padding) zeros.push(0) + + return new Buffer(zeros.concat(byteArray)) +} + +BigInteger.prototype.toHex = function(size) { + return this.toBuffer(size).toString('hex') +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 409 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global, process) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +var formatRegExp = /%[sdj%]/g; +exports.format = function(f) { + if (!isString(f)) { + var objects = []; + for (var i = 0; i < arguments.length; i++) { + objects.push(inspect(arguments[i])); + } + return objects.join(' '); + } + + var i = 1; + var args = arguments; + var len = args.length; + var str = String(f).replace(formatRegExp, function(x) { + if (x === '%%') return '%'; + if (i >= len) return x; + switch (x) { + case '%s': return String(args[i++]); + case '%d': return Number(args[i++]); + case '%j': + try { + return JSON.stringify(args[i++]); + } catch (_) { + return '[Circular]'; + } + default: + return x; + } + }); + for (var x = args[i]; i < len; x = args[++i]) { + if (isNull(x) || !isObject(x)) { + str += ' ' + x; + } else { + str += ' ' + inspect(x); + } + } + return str; +}; + + +// Mark that a method should not be used. +// Returns a modified function which warns once by default. +// If --no-deprecation is set, then it is a no-op. +exports.deprecate = function(fn, msg) { + // Allow for deprecating things in the process of starting up. + if (isUndefined(global.process)) { + return function() { + return exports.deprecate(fn, msg).apply(this, arguments); + }; + } + + if (process.noDeprecation === true) { + return fn; + } + + var warned = false; + function deprecated() { + if (!warned) { + if (process.throwDeprecation) { + throw new Error(msg); + } else if (process.traceDeprecation) { + console.trace(msg); + } else { + console.error(msg); + } + warned = true; + } + return fn.apply(this, arguments); + } + + return deprecated; +}; + + +var debugs = {}; +var debugEnviron; +exports.debuglog = function(set) { + if (isUndefined(debugEnviron)) + debugEnviron = process.env.NODE_DEBUG || ''; + set = set.toUpperCase(); + if (!debugs[set]) { + if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) { + var pid = process.pid; + debugs[set] = function() { + var msg = exports.format.apply(exports, arguments); + console.error('%s %d: %s', set, pid, msg); + }; + } else { + debugs[set] = function() {}; + } + } + return debugs[set]; +}; + + +/** + * Echos the value of a value. Trys to print the value out + * in the best way possible given the different types. + * + * @param {Object} obj The object to print out. + * @param {Object} opts Optional options object that alters the output. + */ +/* legacy: obj, showHidden, depth, colors*/ +function inspect(obj, opts) { + // default options + var ctx = { + seen: [], + stylize: stylizeNoColor + }; + // legacy... + if (arguments.length >= 3) ctx.depth = arguments[2]; + if (arguments.length >= 4) ctx.colors = arguments[3]; + if (isBoolean(opts)) { + // legacy... + ctx.showHidden = opts; + } else if (opts) { + // got an "options" object + exports._extend(ctx, opts); + } + // set default options + if (isUndefined(ctx.showHidden)) ctx.showHidden = false; + if (isUndefined(ctx.depth)) ctx.depth = 2; + if (isUndefined(ctx.colors)) ctx.colors = false; + if (isUndefined(ctx.customInspect)) ctx.customInspect = true; + if (ctx.colors) ctx.stylize = stylizeWithColor; + return formatValue(ctx, obj, ctx.depth); +} +exports.inspect = inspect; + + +// http://en.wikipedia.org/wiki/ANSI_escape_code#graphics +inspect.colors = { + 'bold' : [1, 22], + 'italic' : [3, 23], + 'underline' : [4, 24], + 'inverse' : [7, 27], + 'white' : [37, 39], + 'grey' : [90, 39], + 'black' : [30, 39], + 'blue' : [34, 39], + 'cyan' : [36, 39], + 'green' : [32, 39], + 'magenta' : [35, 39], + 'red' : [31, 39], + 'yellow' : [33, 39] +}; + +// Don't use 'blue' not visible on cmd.exe +inspect.styles = { + 'special': 'cyan', + 'number': 'yellow', + 'boolean': 'yellow', + 'undefined': 'grey', + 'null': 'bold', + 'string': 'green', + 'date': 'magenta', + // "name": intentionally not styling + 'regexp': 'red' +}; + + +function stylizeWithColor(str, styleType) { + var style = inspect.styles[styleType]; + + if (style) { + return '\u001b[' + inspect.colors[style][0] + 'm' + str + + '\u001b[' + inspect.colors[style][1] + 'm'; + } else { + return str; + } +} + + +function stylizeNoColor(str, styleType) { + return str; +} + + +function arrayToHash(array) { + var hash = {}; + + array.forEach(function(val, idx) { + hash[val] = true; + }); + + return hash; +} + + +function formatValue(ctx, value, recurseTimes) { + // Provide a hook for user-specified inspect functions. + // Check that value is an object with an inspect function on it + if (ctx.customInspect && + value && + isFunction(value.inspect) && + // Filter out the util module, it's inspect function is special + value.inspect !== exports.inspect && + // Also filter out any prototype objects using the circular check. + !(value.constructor && value.constructor.prototype === value)) { + var ret = value.inspect(recurseTimes, ctx); + if (!isString(ret)) { + ret = formatValue(ctx, ret, recurseTimes); + } + return ret; + } + + // Primitive types cannot have properties + var primitive = formatPrimitive(ctx, value); + if (primitive) { + return primitive; + } + + // Look up the keys of the object. + var keys = Object.keys(value); + var visibleKeys = arrayToHash(keys); + + if (ctx.showHidden) { + keys = Object.getOwnPropertyNames(value); + } + + // IE doesn't make error fields non-enumerable + // http://msdn.microsoft.com/en-us/library/ie/dww52sbt(v=vs.94).aspx + if (isError(value) + && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) { + return formatError(value); + } + + // Some type of object without properties can be shortcutted. + if (keys.length === 0) { + if (isFunction(value)) { + var name = value.name ? ': ' + value.name : ''; + return ctx.stylize('[Function' + name + ']', 'special'); + } + if (isRegExp(value)) { + return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp'); + } + if (isDate(value)) { + return ctx.stylize(Date.prototype.toString.call(value), 'date'); + } + if (isError(value)) { + return formatError(value); + } + } + + var base = '', array = false, braces = ['{', '}']; + + // Make Array say that they are Array + if (isArray(value)) { + array = true; + braces = ['[', ']']; + } + + // Make functions say that they are functions + if (isFunction(value)) { + var n = value.name ? ': ' + value.name : ''; + base = ' [Function' + n + ']'; + } + + // Make RegExps say that they are RegExps + if (isRegExp(value)) { + base = ' ' + RegExp.prototype.toString.call(value); + } + + // Make dates with properties first say the date + if (isDate(value)) { + base = ' ' + Date.prototype.toUTCString.call(value); + } + + // Make error with message first say the error + if (isError(value)) { + base = ' ' + formatError(value); + } + + if (keys.length === 0 && (!array || value.length == 0)) { + return braces[0] + base + braces[1]; + } + + if (recurseTimes < 0) { + if (isRegExp(value)) { + return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp'); + } else { + return ctx.stylize('[Object]', 'special'); + } + } + + ctx.seen.push(value); + + var output; + if (array) { + output = formatArray(ctx, value, recurseTimes, visibleKeys, keys); + } else { + output = keys.map(function(key) { + return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array); + }); + } + + ctx.seen.pop(); + + return reduceToSingleString(output, base, braces); +} + + +function formatPrimitive(ctx, value) { + if (isUndefined(value)) + return ctx.stylize('undefined', 'undefined'); + if (isString(value)) { + var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '') + .replace(/'/g, "\\'") + .replace(/\\"/g, '"') + '\''; + return ctx.stylize(simple, 'string'); + } + if (isNumber(value)) + return ctx.stylize('' + value, 'number'); + if (isBoolean(value)) + return ctx.stylize('' + value, 'boolean'); + // For some reason typeof null is "object", so special case here. + if (isNull(value)) + return ctx.stylize('null', 'null'); +} + + +function formatError(value) { + return '[' + Error.prototype.toString.call(value) + ']'; +} + + +function formatArray(ctx, value, recurseTimes, visibleKeys, keys) { + var output = []; + for (var i = 0, l = value.length; i < l; ++i) { + if (hasOwnProperty(value, String(i))) { + output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, + String(i), true)); + } else { + output.push(''); + } + } + keys.forEach(function(key) { + if (!key.match(/^\d+$/)) { + output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, + key, true)); + } + }); + return output; +} + + +function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) { + var name, str, desc; + desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] }; + if (desc.get) { + if (desc.set) { + str = ctx.stylize('[Getter/Setter]', 'special'); + } else { + str = ctx.stylize('[Getter]', 'special'); + } + } else { + if (desc.set) { + str = ctx.stylize('[Setter]', 'special'); + } + } + if (!hasOwnProperty(visibleKeys, key)) { + name = '[' + key + ']'; + } + if (!str) { + if (ctx.seen.indexOf(desc.value) < 0) { + if (isNull(recurseTimes)) { + str = formatValue(ctx, desc.value, null); + } else { + str = formatValue(ctx, desc.value, recurseTimes - 1); + } + if (str.indexOf('\n') > -1) { + if (array) { + str = str.split('\n').map(function(line) { + return ' ' + line; + }).join('\n').substr(2); + } else { + str = '\n' + str.split('\n').map(function(line) { + return ' ' + line; + }).join('\n'); } - } else if (childrenToUse != null) { - var mountImages = this.mountChildren(childrenToUse, transaction, context); - ret = mountImages.join(''); } + } else { + str = ctx.stylize('[Circular]', 'special'); } - if (newlineEatingTags[this._tag] && ret.charAt(0) === '\n') { - // text/html ignores the first character in these tags if it's a newline - // Prefer to break application/xml over text/html (for now) by adding - // a newline specifically to get eaten by the parser. (Alternately for - // textareas, replacing "^\n" with "\r\n" doesn't get eaten, and the first - // \r is normalized out by HTMLTextAreaElement#value.) - // See: <http://www.w3.org/TR/html-polyglot/#newlines-in-textarea-and-pre> - // See: <http://www.w3.org/TR/html5/syntax.html#element-restrictions> - // See: <http://www.w3.org/TR/html5/syntax.html#newlines> - // See: Parsing of "textarea" "listing" and "pre" elements - // from <http://www.w3.org/TR/html5/syntax.html#parsing-main-inbody> - return '\n' + ret; + } + if (isUndefined(name)) { + if (array && key.match(/^\d+$/)) { + return str; + } + name = JSON.stringify('' + key); + if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) { + name = name.substr(1, name.length - 2); + name = ctx.stylize(name, 'name'); } else { - return ret; + name = name.replace(/'/g, "\\'") + .replace(/\\"/g, '"') + .replace(/(^"|"$)/g, "'"); + name = ctx.stylize(name, 'string'); } - }, + } - _createInitialChildren: function (transaction, props, context, lazyTree) { - // Intentional use of != to avoid catching zero/false. - var innerHTML = props.dangerouslySetInnerHTML; - if (innerHTML != null) { - if (innerHTML.__html != null) { - DOMLazyTree.queueHTML(lazyTree, innerHTML.__html); + return name + ': ' + str; +} + + +function reduceToSingleString(output, base, braces) { + var numLinesEst = 0; + var length = output.reduce(function(prev, cur) { + numLinesEst++; + if (cur.indexOf('\n') >= 0) numLinesEst++; + return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1; + }, 0); + + if (length > 60) { + return braces[0] + + (base === '' ? '' : base + '\n ') + + ' ' + + output.join(',\n ') + + ' ' + + braces[1]; + } + + return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1]; +} + + +// NOTE: These type checking functions intentionally don't use `instanceof` +// because it is fragile and can be easily faked with `Object.create()`. +function isArray(ar) { + return Array.isArray(ar); +} +exports.isArray = isArray; + +function isBoolean(arg) { + return typeof arg === 'boolean'; +} +exports.isBoolean = isBoolean; + +function isNull(arg) { + return arg === null; +} +exports.isNull = isNull; + +function isNullOrUndefined(arg) { + return arg == null; +} +exports.isNullOrUndefined = isNullOrUndefined; + +function isNumber(arg) { + return typeof arg === 'number'; +} +exports.isNumber = isNumber; + +function isString(arg) { + return typeof arg === 'string'; +} +exports.isString = isString; + +function isSymbol(arg) { + return typeof arg === 'symbol'; +} +exports.isSymbol = isSymbol; + +function isUndefined(arg) { + return arg === void 0; +} +exports.isUndefined = isUndefined; + +function isRegExp(re) { + return isObject(re) && objectToString(re) === '[object RegExp]'; +} +exports.isRegExp = isRegExp; + +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} +exports.isObject = isObject; + +function isDate(d) { + return isObject(d) && objectToString(d) === '[object Date]'; +} +exports.isDate = isDate; + +function isError(e) { + return isObject(e) && + (objectToString(e) === '[object Error]' || e instanceof Error); +} +exports.isError = isError; + +function isFunction(arg) { + return typeof arg === 'function'; +} +exports.isFunction = isFunction; + +function isPrimitive(arg) { + return arg === null || + typeof arg === 'boolean' || + typeof arg === 'number' || + typeof arg === 'string' || + typeof arg === 'symbol' || // ES6 symbol + typeof arg === 'undefined'; +} +exports.isPrimitive = isPrimitive; + +exports.isBuffer = __webpack_require__(410); + +function objectToString(o) { + return Object.prototype.toString.call(o); +} + + +function pad(n) { + return n < 10 ? '0' + n.toString(10) : n.toString(10); +} + + +var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', + 'Oct', 'Nov', 'Dec']; + +// 26 Feb 16:19:34 +function timestamp() { + var d = new Date(); + var time = [pad(d.getHours()), + pad(d.getMinutes()), + pad(d.getSeconds())].join(':'); + return [d.getDate(), months[d.getMonth()], time].join(' '); +} + + +// log is just a thin wrapper to console.log that prepends a timestamp +exports.log = function() { + console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments)); +}; + + +/** + * Inherit the prototype methods from one constructor into another. + * + * The Function.prototype.inherits from lang.js rewritten as a standalone + * function (not on Function.prototype). NOTE: If this file is to be loaded + * during bootstrapping this function needs to be rewritten using some native + * functions as prototype setup using normal JavaScript does not work as + * expected during bootstrapping (see mirror.js in r114903). + * + * @param {function} ctor Constructor function which needs to inherit the + * prototype. + * @param {function} superCtor Constructor function to inherit prototype from. + */ +exports.inherits = __webpack_require__(411); + +exports._extend = function(origin, add) { + // Don't do anything if add isn't an object + if (!add || !isObject(add)) return origin; + + var keys = Object.keys(add); + var i = keys.length; + while (i--) { + origin[keys[i]] = add[keys[i]]; + } + return origin; +}; + +function hasOwnProperty(obj, prop) { + return Object.prototype.hasOwnProperty.call(obj, prop); +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) + +/***/ }), +/* 410 */ +/***/ (function(module, exports) { + +module.exports = function isBuffer(arg) { + return arg && typeof arg === 'object' + && typeof arg.copy === 'function' + && typeof arg.fill === 'function' + && typeof arg.readUInt8 === 'function'; +} + +/***/ }), +/* 411 */ +/***/ (function(module, exports) { + +if (typeof Object.create === 'function') { + // implementation from standard node.js 'util' module + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + ctor.prototype = Object.create(superCtor.prototype, { + constructor: { + value: ctor, + enumerable: false, + writable: true, + configurable: true } + }); + }; +} else { + // old school shim for old browsers + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + var TempCtor = function () {} + TempCtor.prototype = superCtor.prototype + ctor.prototype = new TempCtor() + ctor.prototype.constructor = ctor + } +} + + +/***/ }), +/* 412 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var prf = __webpack_require__(413); +var address = __webpack_require__(96); +var bs58check = __webpack_require__(33); +var sodium = __webpack_require__(415); +var zconfig = __webpack_require__(66); + +/* + * Creates a Z secret key (a_sk) + * @param {String} phrase (Password phrase) + * @return {Sting} Z secret key (a_sk) + */ +function mkZSecretKey(phrase) { + const a_sk = address.mkPrivKey(phrase); + var baddr = Buffer.from(a_sk, 'hex'); + baddr[0] &= 0x0f; + return baddr.toString('hex'); +} + +/* + * Converts the secret key to a spending key + * @param {String} a_sk (secret key) + * @param {String} zcSpendingKeyHash (secret key hash,optional) + * @return {Sting} sk (spending key) + */ +function zSecretKeyToSpendingKey(a_sk, zcSpendingKeyHash) { + zcSpendingKeyHash = zcSpendingKeyHash || zconfig.mainnet.zcSpendingKeyHash; + + const buf = Buffer.from(zcSpendingKeyHash + a_sk, 'hex'); + return bs58check.encode(buf).toString('hex'); +} + +/* + * Converts a Z secret key to a paying key + * @param {String} a_sk (secret key) + * @return {Sting} a_pk key (paying key) + */ +function zSecretKeyToPayingKey(a_sk) { + return prf.PRF_addr_a_pk(Buffer.from(a_sk, 'hex')).toString('hex'); +} + +/* + * Converts a Z secret key to a transmission key + * @param {String} a_sk (secret key) + * @return {Sting} pk_enc key (transmisison key) + */ +function zSecretKeyToTransmissionKey(a_sk) { + var sk_enc = prf.PRF_addr_sk_enc(Buffer.from(a_sk, 'hex')); + + // Curve 25519 clamping + sk_enc[0] &= 248; + sk_enc[32] &= 127; + sk_enc[31] |= 64; + + return Buffer.from(sodium.crypto_scalarmult_base(sk_enc)).toString('hex'); +} + +/* + * Makes a Z address given: + * @param {String} a_pk (paying key) + * @param {String} pk_enc key (transmission key) + * @param {String} zcPaymentAddressHash (hash for payment address, optional) + * @return {String} Zaddress + */ +function mkZAddress(a_pk, pk_enc, zcPaymentAddressHash) { + zcPaymentAddressHash = zcPaymentAddressHash || zconfig.mainnet.zcPaymentAddressHash; + + const buf = Buffer.from(zcPaymentAddressHash + a_pk + pk_enc, 'hex'); + return bs58check.encode(buf).toString('hex'); +} + +module.exports = { + mkZSecretKey: mkZSecretKey, + zSecretKeyToTransmissionKey: zSecretKeyToTransmissionKey, + zSecretKeyToPayingKey: zSecretKeyToPayingKey, + zSecretKeyToSpendingKey: zSecretKeyToSpendingKey, + mkZAddress: mkZAddress +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 413 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var SHA256Compress = __webpack_require__(414); + +function prf(a, b, c, d, x, y) { + + var blob = Buffer.alloc(64); + + x.copy(blob, 0); + y.copy(blob, 32); + + blob[0] &= 0x0F; + blob[0] |= (a ? 1 << 7 : 0) | (b ? 1 << 6 : 0) | (c ? 1 << 5 : 0) | (d ? 1 << 4 : 0); + + var hasher = new SHA256Compress(); + hasher.update(blob); + return hasher.hash(); +} + +function prfAddr(aSk, t) { + var y = Buffer.alloc(32); + y.fill(0); + y[0] = t; + + return prf(1, 1, 0, 0, aSk, y); +} + +function prfAddrAPk(aSk) { + return prfAddr(aSk, 0); +} + +function prfAddrSkEnc(aSk) { + return prfAddr(aSk, 1); +} + +function prfNf(aSk, rho) { + return prf(1, 1, 1, 0, aSk, rho); +} + +function prfPk(aSk, i0, hSig) { + if (i0 !== 0 && i0 !== 1) { + throw new Error('PRF_pk invoked with index out of bounds'); + } + + return prf(0, i0, 0, 0, aSk, hSig); +} + +function prfRho(phi, i0, hSig) { + if (i0 !== 0 && i0 !== 1) { + throw new Error('PRF_rho invoked with index out of bounds'); + } + + return prf(0, i0, 1, 0, phi, hSig); +} + +module.exports = { + PRF_addr_a_pk: prfAddrAPk, + PRF_addr_sk_enc: prfAddrSkEnc, + PRF_nf: prfNf, + PRF_pk: prfPk, + PRF_rho: prfRho +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 414 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/** + * Adapted from https://github.com/crypto-browserify/sha.js/blob/master/sha256.js + * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined + * in FIPS 180-2 + * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * + */ + +var K = [0x428A2F98, 0x71374491, 0xB5C0FBCF, 0xE9B5DBA5, 0x3956C25B, 0x59F111F1, 0x923F82A4, 0xAB1C5ED5, 0xD807AA98, 0x12835B01, 0x243185BE, 0x550C7DC3, 0x72BE5D74, 0x80DEB1FE, 0x9BDC06A7, 0xC19BF174, 0xE49B69C1, 0xEFBE4786, 0x0FC19DC6, 0x240CA1CC, 0x2DE92C6F, 0x4A7484AA, 0x5CB0A9DC, 0x76F988DA, 0x983E5152, 0xA831C66D, 0xB00327C8, 0xBF597FC7, 0xC6E00BF3, 0xD5A79147, 0x06CA6351, 0x14292967, 0x27B70A85, 0x2E1B2138, 0x4D2C6DFC, 0x53380D13, 0x650A7354, 0x766A0ABB, 0x81C2C92E, 0x92722C85, 0xA2BFE8A1, 0xA81A664B, 0xC24B8B70, 0xC76C51A3, 0xD192E819, 0xD6990624, 0xF40E3585, 0x106AA070, 0x19A4C116, 0x1E376C08, 0x2748774C, 0x34B0BCB5, 0x391C0CB3, 0x4ED8AA4A, 0x5B9CCA4F, 0x682E6FF3, 0x748F82EE, 0x78A5636F, 0x84C87814, 0x8CC70208, 0x90BEFFFA, 0xA4506CEB, 0xBEF9A3F7, 0xC67178F2]; + +var W = new Array(64); + +function Sha256Compress() { + this.init(); + + this._w = W; // new Array(64) +} + +Sha256Compress.prototype.init = function () { + this._a = 0x6a09e667; + this._b = 0xbb67ae85; + this._c = 0x3c6ef372; + this._d = 0xa54ff53a; + this._e = 0x510e527f; + this._f = 0x9b05688c; + this._g = 0x1f83d9ab; + this._h = 0x5be0cd19; + + return this; +}; + +function ch(x, y, z) { + return z ^ x & (y ^ z); +} + +function maj(x, y, z) { + return x & y | z & (x | y); +} + +function sigma0(x) { + return (x >>> 2 | x << 30) ^ (x >>> 13 | x << 19) ^ (x >>> 22 | x << 10); +} + +function sigma1(x) { + return (x >>> 6 | x << 26) ^ (x >>> 11 | x << 21) ^ (x >>> 25 | x << 7); +} + +function gamma0(x) { + return (x >>> 7 | x << 25) ^ (x >>> 18 | x << 14) ^ x >>> 3; +} + +function gamma1(x) { + return (x >>> 17 | x << 15) ^ (x >>> 19 | x << 13) ^ x >>> 10; +} + +Sha256Compress.prototype.update = function (M) { + var W = this._w; + + var a = this._a | 0; + var b = this._b | 0; + var c = this._c | 0; + var d = this._d | 0; + var e = this._e | 0; + var f = this._f | 0; + var g = this._g | 0; + var h = this._h | 0; + + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4); + for (; i < 64; ++i) W[i] = gamma1(W[i - 2]) + W[i - 7] + gamma0(W[i - 15]) + W[i - 16] | 0; + + for (var j = 0; j < 64; ++j) { + var T1 = h + sigma1(e) + ch(e, f, g) + K[j] + W[j] | 0; + var T2 = sigma0(a) + maj(a, b, c) | 0; + + h = g; + g = f; + f = e; + e = d + T1 | 0; + d = c; + c = b; + b = a; + a = T1 + T2 | 0; + } + + this._a = a + this._a | 0; + this._b = b + this._b | 0; + this._c = c + this._c | 0; + this._d = d + this._d | 0; + this._e = e + this._e | 0; + this._f = f + this._f | 0; + this._g = g + this._g | 0; + this._h = h + this._h | 0; +}; + +Sha256Compress.prototype.hash = function () { + var H = Buffer.alloc(32); + + H.writeInt32BE(this._a, 0); + H.writeInt32BE(this._b, 4); + H.writeInt32BE(this._c, 8); + H.writeInt32BE(this._d, 12); + H.writeInt32BE(this._e, 16); + H.writeInt32BE(this._f, 20); + H.writeInt32BE(this._g, 24); + H.writeInt32BE(this._h, 28); + + return H; +}; + +module.exports = Sha256Compress; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 415 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(process) {var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (root, factory) { + if (typeof process === "object" && typeof process.stdout === "undefined") { + process.stderr = process.stdout = { write: function() { } }; + } + if (true) { + !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports, __webpack_require__(416)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), + __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? + (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); + } else if (typeof exports !== "undefined") { + factory(exports, require("libsodium-sumo")); } else { - var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; - var childrenToUse = contentToUse != null ? null : props.children; - // TODO: Validate that text is allowed as a child of this node - if (contentToUse != null) { - // Avoid setting textContent when the text is empty. In IE11 setting - // textContent on a text area will cause the placeholder to not - // show within the textarea until it has been focused and blurred again. - // https://github.com/facebook/react/issues/6731#issuecomment-254874553 - if (contentToUse !== '') { - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, contentToUse); - } - DOMLazyTree.queueText(lazyTree, contentToUse); + var cb = root.sodium && root.sodium.onload; + factory((root.sodium = {}), root.libsodium); + if (typeof cb === "function") { + cb(root.sodium); } - } else if (childrenToUse != null) { - var mountImages = this.mountChildren(childrenToUse, transaction, context); - for (var i = 0; i < mountImages.length; i++) { - DOMLazyTree.queueChild(lazyTree, mountImages[i]); + } +}(this, (function (exports, libsodium) { + "use strict"; + + var output_format = "uint8array"; + + if (libsodium._sodium_init() !== 0) { + throw new Error("libsodium was not correctly initialized."); + } + + // List of functions and constants defined in the wrapped libsodium + function symbols() { + return Object.keys(exports).sort(); + } + + function increment(bytes) { + if (! bytes instanceof Uint8Array) { + throw new TypeError("Only Uint8Array instances can be incremented"); + } + var c = 1 << 8; + for (var i = 0 | 0, j = bytes.length; i < j; i++) { + c >>= 8; + c += bytes[i]; + bytes[i] = c & 0xff; } - } } - }, - /** - * Receives a next element and updates the component. - * - * @internal - * @param {ReactElement} nextElement - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} context - */ - receiveComponent: function (nextElement, transaction, context) { - var prevElement = this._currentElement; - this._currentElement = nextElement; - this.updateComponent(transaction, prevElement, nextElement, context); - }, + function add(a, b) { + if (! a instanceof Uint8Array || ! b instanceof Uint8Array) { + throw new TypeError("Only Uint8Array instances can added"); + } + var j = a.length, c = 0 | 0, i = 0 | 0; + if (b.length != a.length) { + throw new TypeError("Arguments must have the same length"); + } + for (i = 0; i < j; i++) { + c >>= 8; + c += (a[i] + b[j]); + a[i] = c & 0xff; + } + } - /** - * Updates a DOM component after it has already been allocated and - * attached to the DOM. Reconciles the root DOM node, then recurses. - * - * @param {ReactReconcileTransaction} transaction - * @param {ReactElement} prevElement - * @param {ReactElement} nextElement - * @internal - * @overridable - */ - updateComponent: function (transaction, prevElement, nextElement, context) { - var lastProps = prevElement.props; - var nextProps = this._currentElement.props; + function is_zero(bytes) { + if (! bytes instanceof Uint8Array) { + throw new TypeError("Only Uint8Array instances can be checked"); + } + var d = 0 | 0; + for (var i = 0 | 0, j = bytes.length; i < j; i++) { + d |= bytes[i]; + } + return d === 0; + } - switch (this._tag) { - case 'input': - lastProps = ReactDOMInput.getHostProps(this, lastProps); - nextProps = ReactDOMInput.getHostProps(this, nextProps); - break; - case 'option': - lastProps = ReactDOMOption.getHostProps(this, lastProps); - nextProps = ReactDOMOption.getHostProps(this, nextProps); - break; - case 'select': - lastProps = ReactDOMSelect.getHostProps(this, lastProps); - nextProps = ReactDOMSelect.getHostProps(this, nextProps); - break; - case 'textarea': - lastProps = ReactDOMTextarea.getHostProps(this, lastProps); - nextProps = ReactDOMTextarea.getHostProps(this, nextProps); - break; + function memzero(bytes) { + if (! bytes instanceof Uint8Array) { + throw new TypeError("Only Uint8Array instances can be wiped"); + } + for (var i = 0 | 0, j = bytes.length; i < j; i++) { + bytes[i] = 0; + } } - assertValidProps(this, nextProps); - this._updateDOMProperties(lastProps, nextProps, transaction); - this._updateDOMChildren(lastProps, nextProps, transaction, context); + function memcmp(b1, b2) { + if (!(b1 instanceof Uint8Array && b2 instanceof Uint8Array)) { + throw new TypeError("Only Uint8Array instances can be compared"); + } + if (b1.length !== b2.length) { + throw new TypeError("Only instances of identical length can be compared"); + } + for (var d = 0 | 0, i = 0 | 0, j = b1.length; i < j; i++) { + d |= b1[i] ^ b2[i]; + } + return d === 0; + } - switch (this._tag) { - case 'input': - // Update the wrapper around inputs *after* updating props. This has to - // happen after `_updateDOMProperties`. Otherwise HTML5 input validations - // raise warnings and prevent the new value from being assigned. - ReactDOMInput.updateWrapper(this); - break; - case 'textarea': - ReactDOMTextarea.updateWrapper(this); - break; - case 'select': - // <select> value update needs to occur after <option> children - // reconciliation - transaction.getReactMountReady().enqueue(postUpdateSelectWrapper, this); - break; + function compare(b1, b2) { + if (!(b1 instanceof Uint8Array && b2 instanceof Uint8Array)) { + throw new TypeError("Only Uint8Array instances can be compared"); + } + if (b1.length !== b2.length) { + throw new TypeError("Only instances of identical length can be compared"); + } + for (var gt = 0 | 0, eq = 1 | 1, i = b1.length; i-- > 0;) { + gt |= ((b2[i] - b1[i]) >> 8) & eq; + eq &= ((b2[i] ^ b1[i]) - 1) >> 8; + } + return (gt + gt + eq) - 1; } - }, - /** - * Reconciles the properties by detecting differences in property values and - * updating the DOM as necessary. This function is probably the single most - * critical path for performance optimization. - * - * TODO: Benchmark whether checking for changed values in memory actually - * improves performance (especially statically positioned elements). - * TODO: Benchmark the effects of putting this at the top since 99% of props - * do not change for a given reconciliation. - * TODO: Benchmark areas that can be improved with caching. - * - * @private - * @param {object} lastProps - * @param {object} nextProps - * @param {?DOMElement} node - */ - _updateDOMProperties: function (lastProps, nextProps, transaction) { - var propKey; - var styleName; - var styleUpdates; - for (propKey in lastProps) { - if (nextProps.hasOwnProperty(propKey) || !lastProps.hasOwnProperty(propKey) || lastProps[propKey] == null) { - continue; - } - if (propKey === STYLE) { - var lastStyle = this._previousStyleCopy; - for (styleName in lastStyle) { - if (lastStyle.hasOwnProperty(styleName)) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = ''; - } + //--------------------------------------------------------------------------- + // Codecs + // + function from_string(str) { + if (typeof TextEncoder === "function") { + return new TextEncoder("utf-8").encode(str); } - this._previousStyleCopy = null; - } else if (registrationNameModules.hasOwnProperty(propKey)) { - if (lastProps[propKey]) { - // Only call deleteListener if there was a listener previously or - // else willDeleteListener gets called when there wasn't actually a - // listener (e.g., onClick={null}) - deleteListener(this, propKey); + str = unescape(encodeURIComponent(str)); + var bytes = new Uint8Array(str.length); + for (var i = 0; i < str.length; i++) { + bytes[i] = str.charCodeAt(i); + } + return bytes; + } + + function to_string(bytes) { + if (typeof TextDecoder === "function") { + return new TextDecoder("utf-8", {fatal: true}).decode(bytes); + } + + var toStringChunkSize = 8192, + numChunks = Math.ceil(bytes.length / toStringChunkSize); + if (numChunks <= 1) { + try { + return decodeURIComponent(escape(String.fromCharCode.apply(null, bytes))); + } + catch (_) { + throw new TypeError("The encoded data was not valid."); + } + } + var totalString = ''; + var sequenceReadOffset = 0; + for (var i = 0; i < numChunks; i++) { + var currentChunk = + Array.prototype.slice.call(bytes, + i * toStringChunkSize + sequenceReadOffset, + (i + 1) * toStringChunkSize + sequenceReadOffset); + //Depending on how much we have shifted + if (currentChunk.length == 0) { + continue; + } + + //Checking that we didn't cut the buffer in the middle of a UTF8 sequence. + //If we did, remove the bytes of the "cut" sequence and + //decrement sequenceReadOffset for each removed byte + var sequenceDetectionComplete, + sequenceIndex = currentChunk.length, + sequenceLength = 0; + + //This loop will read the chunk from its end, looking for sequence start bytes + do { + sequenceIndex--; + var currentByte = currentChunk[sequenceIndex]; + + if (currentByte >= 240) { //Beginning of a 4-byte UTF-8 sequence + sequenceLength = 4; + sequenceDetectionComplete = true; + } else if (currentByte >= 224) { //Beginning of a 3-byte UTF-8 sequence + sequenceLength = 3; + sequenceDetectionComplete = true; + } else if (currentByte >= 192) { //Beginning of a 2-byte UTF-8 sequence + sequenceLength = 2; + sequenceDetectionComplete = true; + } else if (currentByte < 128) { //A one byte UTF-8 char + sequenceLength = 1; + sequenceDetectionComplete = true; + } + //The values between [128, 192[ are part of a UTF-8 sequence. + //The loop will not exit in that case, and will iterate one byte backwards instead + } while (!sequenceDetectionComplete); + + var extraBytes = sequenceLength - (currentChunk.length - sequenceIndex); + for (var j = 0; j < extraBytes; j++) { + sequenceReadOffset--; + currentChunk.pop(); + } + + totalString += to_string(currentChunk); + } + return totalString; + } + + /* not constant-time */ + function from_hex(str) { + if (!is_hex(str)) { + throw new TypeError("The provided string doesn't look like hex data"); + } + var result = new Uint8Array(str.length / 2); + for (var i = 0; i < str.length; i += 2) { + result[i >>> 1] = parseInt(str.substr(i, 2), 16); + } + return result; + } + + function to_hex(bytes) { + var str = "", b, c, x; + for (var i = 0; i < bytes.length; i++) { + c = bytes[i] & 0xf; + b = bytes[i] >>> 4; + x = (87 + c + (((c - 10) >> 8) & ~38)) << 8 | + (87 + b + (((b - 10) >> 8) & ~38)); + str += String.fromCharCode(x & 0xff) + String.fromCharCode(x >>> 8); + } + return str; + } + + function is_hex(str) { + return (typeof str === "string" && /^[0-9a-f]+$/i.test(str) && str.length % 2 === 0); + } + + function from_base64(sBase64, nBlocksSize) { + function _b64ToUint6(nChr) { + return nChr > 64 && nChr < 91 ? + nChr - 65 : nChr > 96 && nChr < 123 ? + nChr - 71 : nChr > 47 && nChr < 58 ? + nChr + 4 : nChr === 43 ? + 62 : nChr === 47 ? + 63 : + 0; + } + + var sB64Enc = sBase64.replace(/[^A-Za-z0-9\+\/]/g, ""), + nInLen = sB64Enc.length, + nOutLen = nBlocksSize ? Math.ceil((nInLen * 3 + 1 >> 2) / nBlocksSize) * nBlocksSize : nInLen * 3 + 1 >> 2, + taBytes = new Uint8Array(nOutLen); + + for (var nMod3, nMod4, nUint24 = 0, nOutIdx = 0, nInIdx = 0; nInIdx < nInLen; nInIdx++) { + nMod4 = nInIdx & 3; + nUint24 |= _b64ToUint6(sB64Enc.charCodeAt(nInIdx)) << 18 - 6 * nMod4; + if (nMod4 === 3 || nInLen - nInIdx === 1) { + for (nMod3 = 0; nMod3 < 3 && nOutIdx < nOutLen; nMod3++, nOutIdx++) { + taBytes[nOutIdx] = nUint24 >>> (16 >>> nMod3 & 24) & 255; + } + nUint24 = 0; + } + } + return taBytes; + } + + function to_base64(aBytes, noNewLine) { + if (typeof noNewLine === "undefined") { + noNewLine = true; + } + function _uint6ToB64(nUint6) { + return nUint6 < 26 ? + nUint6 + 65 : nUint6 < 52 ? + nUint6 + 71 : nUint6 < 62 ? + nUint6 - 4 : nUint6 === 62 ? + 43 : nUint6 === 63 ? + 47 : + 65; + } + if (typeof aBytes === "string") { + throw new Error("input has to be an array"); } - } else if (isCustomComponent(this._tag, lastProps)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - DOMPropertyOperations.deleteValueForAttribute(getNode(this), propKey); + var nMod3 = 2, + sB64Enc = ""; + for (var nLen = aBytes.length, nUint24 = 0, nIdx = 0; nIdx < nLen; nIdx++) { + nMod3 = nIdx % 3; + if (nIdx > 0 && (nIdx * 4 / 3) % 76 === 0 && !noNewLine) { + sB64Enc += "\r\n"; + } + nUint24 |= aBytes[nIdx] << (16 >>> nMod3 & 24); + if (nMod3 === 2 || aBytes.length - nIdx === 1) { + sB64Enc += String.fromCharCode(_uint6ToB64(nUint24 >>> 18 & 63), + _uint6ToB64(nUint24 >>> 12 & 63), + _uint6ToB64(nUint24 >>> 6 & 63), + _uint6ToB64(nUint24 & 63)); + nUint24 = 0; + } } - } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { - DOMPropertyOperations.deleteValueForProperty(getNode(this), propKey); - } + return sB64Enc.substr(0, sB64Enc.length - 2 + nMod3) + + (nMod3 === 2 ? "" : nMod3 === 1 ? "=" : "=="); } - for (propKey in nextProps) { - var nextProp = nextProps[propKey]; - var lastProp = propKey === STYLE ? this._previousStyleCopy : lastProps != null ? lastProps[propKey] : undefined; - if (!nextProps.hasOwnProperty(propKey) || nextProp === lastProp || nextProp == null && lastProp == null) { - continue; - } - if (propKey === STYLE) { - if (nextProp) { - if (process.env.NODE_ENV !== 'production') { - checkAndWarnForMutatedStyle(this._previousStyleCopy, this._previousStyle, this); - this._previousStyle = nextProp; - } - nextProp = this._previousStyleCopy = _assign({}, nextProp); - } else { - this._previousStyleCopy = null; + + function output_formats() { + return ["uint8array", "text", "hex", "base64"]; + } + + function _format_output(output, optionalOutputFormat) { + var selectedOutputFormat = optionalOutputFormat || output_format; + if (!_is_output_format(selectedOutputFormat)) { + throw new Error(selectedOutputFormat + " output format is not available"); } - if (lastProp) { - // Unset styles on `lastProp` but not on `nextProp`. - for (styleName in lastProp) { - if (lastProp.hasOwnProperty(styleName) && (!nextProp || !nextProp.hasOwnProperty(styleName))) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = ''; + if (output instanceof AllocatedBuf) { + if (selectedOutputFormat === "uint8array") { + return output.to_Uint8Array(); + } else if (selectedOutputFormat === "text") { + return to_string(output.to_Uint8Array()); + } else if (selectedOutputFormat === "hex") { + return to_hex(output.to_Uint8Array()); + } else if (selectedOutputFormat === "base64") { + return to_base64(output.to_Uint8Array()); + } else { + throw new Error("What is output format \"" + selectedOutputFormat + "\"?"); } - } - // Update styles that changed since `lastProp`. - for (styleName in nextProp) { - if (nextProp.hasOwnProperty(styleName) && lastProp[styleName] !== nextProp[styleName]) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = nextProp[styleName]; + } else if (typeof output === "object") { //Composed output. Example : key pairs + var props = Object.keys(output); + var formattedOutput = {}; + for (var i = 0; i < props.length; i++) { + formattedOutput[props[i]] = _format_output(output[props[i]], selectedOutputFormat); } - } + return formattedOutput; + } else if (typeof output === "string") { + return output; } else { - // Relies on `updateStylesByID` not mutating `styleUpdates`. - styleUpdates = nextProp; - } - } else if (registrationNameModules.hasOwnProperty(propKey)) { - if (nextProp) { - enqueuePutListener(this, propKey, nextProp, transaction); - } else if (lastProp) { - deleteListener(this, propKey); + throw new TypeError("Cannot format output"); } - } else if (isCustomComponent(this._tag, nextProps)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - DOMPropertyOperations.setValueForAttribute(getNode(this), propKey, nextProp); + } + + function _is_output_format(format) { + var formats = output_formats(); + for (var i = 0; i < formats.length; i++) { + if (formats[i] === format) { + return true; + } } - } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { - var node = getNode(this); - // If we're updating to null or undefined, we should remove the property - // from the DOM node instead of inadvertently setting to a string. This - // brings us in line with the same behavior we have on initial render. - if (nextProp != null) { - DOMPropertyOperations.setValueForProperty(node, propKey, nextProp); - } else { - DOMPropertyOperations.deleteValueForProperty(node, propKey); + return false; + } + + function _check_output_format(format) { + if (!format) { + return; + } else if (typeof format !== "string") { + throw new TypeError("When defined, the output format must be a string"); + } else if (!_is_output_format(format)) { + throw new Error(format + " is not a supported output format"); } - } } - if (styleUpdates) { - CSSPropertyOperations.setValueForStyles(getNode(this), styleUpdates, this); + + //--------------------------------------------------------------------------- + // Memory management + // + // AllocatedBuf: address allocated using _malloc() + length + function AllocatedBuf(length) { + this.length = length; + this.address = _malloc(length); } - }, - /** - * Reconciles the children with the various properties that affect the - * children content. - * - * @param {object} lastProps - * @param {object} nextProps - * @param {ReactReconcileTransaction} transaction - * @param {object} context - */ - _updateDOMChildren: function (lastProps, nextProps, transaction, context) { - var lastContent = CONTENT_TYPES[typeof lastProps.children] ? lastProps.children : null; - var nextContent = CONTENT_TYPES[typeof nextProps.children] ? nextProps.children : null; + // Copy the content of a AllocatedBuf (_malloc()'d memory) into a Uint8Array + AllocatedBuf.prototype.to_Uint8Array = function () { + var result = new Uint8Array(this.length); + result.set(libsodium.HEAPU8.subarray(this.address, this.address + this.length)); + return result; + }; - var lastHtml = lastProps.dangerouslySetInnerHTML && lastProps.dangerouslySetInnerHTML.__html; - var nextHtml = nextProps.dangerouslySetInnerHTML && nextProps.dangerouslySetInnerHTML.__html; + // _malloc() a region and initialize it with the content of a Uint8Array + function _to_allocated_buf_address(bytes) { + var address = _malloc(bytes.length); + libsodium.HEAPU8.set(bytes, address); + return address; + } - // Note the use of `!=` which checks for null or undefined. - var lastChildren = lastContent != null ? null : lastProps.children; - var nextChildren = nextContent != null ? null : nextProps.children; + function _malloc(length) { + var result = libsodium._malloc(length); + if (result === 0) { + throw { + message: "_malloc() failed", + length: length + }; + } + return result; + } - // If we're switching from children to content/html or vice versa, remove - // the old content - var lastHasContentOrHtml = lastContent != null || lastHtml != null; - var nextHasContentOrHtml = nextContent != null || nextHtml != null; - if (lastChildren != null && nextChildren == null) { - this.updateChildren(null, transaction, context); - } else if (lastHasContentOrHtml && !nextHasContentOrHtml) { - this.updateTextContent(''); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); - } + function _free(address) { + libsodium._free(address); } - if (nextContent != null) { - if (lastContent !== nextContent) { - this.updateTextContent('' + nextContent); - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, nextContent); + function _free_all(addresses) { + for (var i = 0; i < addresses.length; i++) { + _free(addresses[i]); } - } - } else if (nextHtml != null) { - if (lastHtml !== nextHtml) { - this.updateMarkup('' + nextHtml); - } - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); - } - } else if (nextChildren != null) { - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, null); - } + } - this.updateChildren(nextChildren, transaction, context); + function _free_and_throw_error(address_pool, err) { + _free_all(address_pool); + throw new Error(err); } - }, - getHostNode: function () { - return getNode(this); - }, + function _free_and_throw_type_error(address_pool, err) { + _free_all(address_pool); + throw new TypeError(err); + } - /** - * Destroys all event registrations for this instance. Does not remove from - * the DOM. That must be done by the parent. - * - * @internal - */ - unmountComponent: function (safely) { - switch (this._tag) { - case 'audio': - case 'form': - case 'iframe': - case 'img': - case 'link': - case 'object': - case 'source': - case 'video': - var listeners = this._wrapperState.listeners; - if (listeners) { - for (var i = 0; i < listeners.length; i++) { - listeners[i].remove(); - } + function _require_defined(address_pool, varValue, varName) { + if (varValue == undefined) { + _free_and_throw_type_error(address_pool, varName + " cannot be null or undefined"); } - break; - case 'input': - case 'textarea': - inputValueTracking.stopTracking(this); - break; - case 'html': - case 'head': - case 'body': - /** - * Components like <html> <head> and <body> can't be removed or added - * easily in a cross-browser way, however it's valuable to be able to - * take advantage of React's reconciliation for styling and <title> - * management. So we just document it and throw in dangerous cases. - */ - true ? process.env.NODE_ENV !== 'production' ? invariant(false, '<%s> tried to unmount. Because of cross-browser quirks it is impossible to unmount some top-level components (eg <html>, <head>, and <body>) reliably and efficiently. To fix this, have a single top-level component that never unmounts render these elements.', this._tag) : _prodInvariant('66', this._tag) : void 0; - break; } - this.unmountChildren(safely); - ReactDOMComponentTree.uncacheNode(this); - EventPluginHub.deleteAllListeners(this); - this._rootNodeID = 0; - this._domID = 0; - this._wrapperState = null; + function _any_to_Uint8Array(address_pool, varValue, varName) { + _require_defined(address_pool, varValue, varName); + if (varValue instanceof Uint8Array) { + return varValue; + } else if (typeof varValue === "string") { + return from_string(varValue); + } + _free_and_throw_type_error(address_pool, "unsupported input type for " + varName); + } + + + function crypto_aead_chacha20poly1305_decrypt(secret_nonce, ciphertext, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length - libsodium._crypto_aead_chacha20poly1305_abytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_chacha20poly1305_decrypt(message_address, null, secret_nonce_address, ciphertext_address, ciphertext_length, 0, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_decrypt_detached(secret_nonce, ciphertext, mac, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_box_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_chacha20poly1305_decrypt_detached(message_address, secret_nonce_address, ciphertext_address, ciphertext_length, 0, mac_address, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_encrypt(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_aead_chacha20poly1305_abytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_aead_chacha20poly1305_encrypt(ciphertext_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_encrypt_detached(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_aead_chacha20poly1305_abytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_aead_chacha20poly1305_encrypt_detached(ciphertext_address, mac_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output({ciphertext: ciphertext, mac: mac}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_decrypt(secret_nonce, ciphertext, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length - libsodium._crypto_aead_chacha20poly1305_ietf_abytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_chacha20poly1305_ietf_decrypt(message_address, null, secret_nonce_address, ciphertext_address, ciphertext_length, 0, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_decrypt_detached(secret_nonce, ciphertext, mac, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_box_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_chacha20poly1305_ietf_decrypt_detached(message_address, secret_nonce_address, ciphertext_address, ciphertext_length, 0, mac_address, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_encrypt(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_aead_chacha20poly1305_ietf_abytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_aead_chacha20poly1305_ietf_encrypt(ciphertext_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_encrypt_detached(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_aead_chacha20poly1305_ietf_abytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_aead_chacha20poly1305_ietf_encrypt_detached(ciphertext_address, mac_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output({ciphertext: ciphertext, mac: mac}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_aead_chacha20poly1305_ietf_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_aead_chacha20poly1305_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_aead_chacha20poly1305_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_aead_xchacha20poly1305_ietf_decrypt(secret_nonce, ciphertext, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length - libsodium._crypto_aead_xchacha20poly1305_ietf_abytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_xchacha20poly1305_ietf_decrypt(message_address, null, secret_nonce_address, ciphertext_address, ciphertext_length, 0, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_xchacha20poly1305_ietf_decrypt_detached(secret_nonce, ciphertext, mac, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_box_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_xchacha20poly1305_ietf_decrypt_detached(message_address, secret_nonce_address, ciphertext_address, ciphertext_length, 0, mac_address, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_xchacha20poly1305_ietf_encrypt(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_aead_xchacha20poly1305_ietf_abytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_aead_xchacha20poly1305_ietf_encrypt(ciphertext_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_xchacha20poly1305_ietf_encrypt_detached(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_abytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_aead_xchacha20poly1305_ietf_encrypt_detached(ciphertext_address, mac_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output({ciphertext: ciphertext, mac: mac}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_xchacha20poly1305_ietf_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_aead_xchacha20poly1305_ietf_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_auth(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output tag (buf) + + var tag_length = (libsodium._crypto_auth_bytes()) | 0, + tag = new AllocatedBuf(tag_length), + tag_address = tag.address; + + address_pool.push(tag_address); + + if ((libsodium._crypto_auth(tag_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(tag, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_auth_hmacsha256(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_hmacsha256_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_auth_hmacsha256_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_auth_hmacsha256(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_auth_hmacsha256_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_auth_hmacsha256_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_auth_hmacsha256_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_auth_hmacsha256_verify(tag, message, key) { + var address_pool = []; + + // ---------- input: tag (buf) + + tag = _any_to_Uint8Array(address_pool, tag, "tag"); + var tag_address, tag_length = (libsodium._crypto_auth_hmacsha256_bytes()) | 0; + if (tag.length !== tag_length) { + _free_and_throw_type_error(address_pool, "invalid tag length"); + } + tag_address = _to_allocated_buf_address(tag); + address_pool.push(tag_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_hmacsha256_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + var result = libsodium._crypto_auth_hmacsha256_verify(tag_address, message_address, message_length, 0, key_address) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } + + function crypto_auth_hmacsha512(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_hmacsha512_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_auth_hmacsha512_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_auth_hmacsha512(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_auth_hmacsha512_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_auth_hmacsha512_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_auth_hmacsha512_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_auth_hmacsha512_verify(tag, message, key) { + var address_pool = []; + + // ---------- input: tag (buf) + + tag = _any_to_Uint8Array(address_pool, tag, "tag"); + var tag_address, tag_length = (libsodium._crypto_auth_hmacsha512_bytes()) | 0; + if (tag.length !== tag_length) { + _free_and_throw_type_error(address_pool, "invalid tag length"); + } + tag_address = _to_allocated_buf_address(tag); + address_pool.push(tag_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_hmacsha512_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + var result = libsodium._crypto_auth_hmacsha512_verify(tag_address, message_address, message_length, 0, key_address) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } + + function crypto_auth_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_auth_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_auth_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_auth_verify(tag, message, key) { + var address_pool = []; + + // ---------- input: tag (buf) + + tag = _any_to_Uint8Array(address_pool, tag, "tag"); + var tag_address, tag_length = (libsodium._crypto_auth_bytes()) | 0; + if (tag.length !== tag_length) { + _free_and_throw_type_error(address_pool, "invalid tag length"); + } + tag_address = _to_allocated_buf_address(tag); + address_pool.push(tag_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + var result = libsodium._crypto_auth_verify(tag_address, message_address, message_length, 0, key_address) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } + + function crypto_box_beforenm(publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output sharedKey (buf) + + var sharedKey_length = (libsodium._crypto_box_beforenmbytes()) | 0, + sharedKey = new AllocatedBuf(sharedKey_length), + sharedKey_address = sharedKey.address; + + address_pool.push(sharedKey_address); + + if ((libsodium._crypto_box_beforenm(sharedKey_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(sharedKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_detached(message, nonce, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_box_macbytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_box_detached(ciphertext_address, mac_address, message_address, message_length, 0, nonce_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output({ciphertext: ciphertext, mac: mac}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_easy(message, nonce, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_box_macbytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_box_easy(ciphertext_address, message_address, message_length, 0, nonce_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_easy_afternm(message, nonce, sharedKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: sharedKey (buf) + + sharedKey = _any_to_Uint8Array(address_pool, sharedKey, "sharedKey"); + var sharedKey_address, sharedKey_length = (libsodium._crypto_box_beforenmbytes()) | 0; + if (sharedKey.length !== sharedKey_length) { + _free_and_throw_type_error(address_pool, "invalid sharedKey length"); + } + sharedKey_address = _to_allocated_buf_address(sharedKey); + address_pool.push(sharedKey_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_box_macbytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_box_easy_afternm(ciphertext_address, message_address, message_length, 0, nonce_address, sharedKey_address) | 0) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_keypair(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output secretKey (buf) + + var secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0, + secretKey = new AllocatedBuf(secretKey_length), + secretKey_address = secretKey.address; + + address_pool.push(secretKey_address); + + if ((libsodium._crypto_box_keypair(publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: secretKey, keyType: "curve25519"}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_open_detached(ciphertext, mac, nonce, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_box_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output plaintext (buf) + + var plaintext_length = (ciphertext_length) | 0, + plaintext = new AllocatedBuf(plaintext_length), + plaintext_address = plaintext.address; + + address_pool.push(plaintext_address); + + if ((libsodium._crypto_box_open_detached(plaintext_address, ciphertext_address, mac_address, ciphertext_length, 0, nonce_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(plaintext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_open_easy(ciphertext, nonce, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output plaintext (buf) + + var plaintext_length = (ciphertext_length - libsodium._crypto_box_macbytes()) | 0, + plaintext = new AllocatedBuf(plaintext_length), + plaintext_address = plaintext.address; + + address_pool.push(plaintext_address); + + if ((libsodium._crypto_box_open_easy(plaintext_address, ciphertext_address, ciphertext_length, 0, nonce_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(plaintext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_open_easy_afternm(ciphertext, nonce, sharedKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: sharedKey (buf) + + sharedKey = _any_to_Uint8Array(address_pool, sharedKey, "sharedKey"); + var sharedKey_address, sharedKey_length = (libsodium._crypto_box_beforenmbytes()) | 0; + if (sharedKey.length !== sharedKey_length) { + _free_and_throw_type_error(address_pool, "invalid sharedKey length"); + } + sharedKey_address = _to_allocated_buf_address(sharedKey); + address_pool.push(sharedKey_address); + + // ---------- output plaintext (buf) + + var plaintext_length = (ciphertext_length - libsodium._crypto_box_macbytes()) | 0, + plaintext = new AllocatedBuf(plaintext_length), + plaintext_address = plaintext.address; + + address_pool.push(plaintext_address); + + if ((libsodium._crypto_box_open_easy_afternm(plaintext_address, ciphertext_address, ciphertext_length, 0, nonce_address, sharedKey_address) | 0) === 0) { + var ret = _format_output(plaintext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_seal(message, publicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_box_sealbytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_box_seal(ciphertext_address, message_address, message_length, 0, publicKey_address) | 0) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_seal_open(ciphertext, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output plaintext (buf) + + var plaintext_length = (ciphertext_length - libsodium._crypto_box_sealbytes()) | 0, + plaintext = new AllocatedBuf(plaintext_length), + plaintext_address = plaintext.address; + + address_pool.push(plaintext_address); + + if ((libsodium._crypto_box_seal_open(plaintext_address, ciphertext_address, ciphertext_length, 0, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(plaintext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_box_seed_keypair(seed, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: seed (buf) + + seed = _any_to_Uint8Array(address_pool, seed, "seed"); + var seed_address, seed_length = (libsodium._crypto_box_seedbytes()) | 0; + if (seed.length !== seed_length) { + _free_and_throw_type_error(address_pool, "invalid seed length"); + } + seed_address = _to_allocated_buf_address(seed); + address_pool.push(seed_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_box_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_box_seed_keypair(publicKey_address, privateKey_address, seed_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_generichash(hash_length, message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: hash_length (uint) + + _require_defined(address_pool, hash_length, "hash_length"); + + if (!(typeof hash_length === "number" && (hash_length | 0) === hash_length) && (hash_length | 0) > 0) { + _free_and_throw_type_error(address_pool, "hash_length must be an unsigned integer"); + } + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (unsized_buf_optional) + + var key_address = null, key_length = 0; + if (key != undefined) { + key = _any_to_Uint8Array(address_pool, key, "key"); + key_address = _to_allocated_buf_address(key); + key_length = key.length; + address_pool.push(key_address); + } + + // ---------- output hash (buf) + + var hash_length = (hash_length) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_generichash(hash_address, hash_length, message_address, message_length, 0, key_address, key_length) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_generichash_final(state_address, hash_length, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (generichash_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: hash_length (uint) + + _require_defined(address_pool, hash_length, "hash_length"); + + if (!(typeof hash_length === "number" && (hash_length | 0) === hash_length) && (hash_length | 0) > 0) { + _free_and_throw_type_error(address_pool, "hash_length must be an unsigned integer"); + } + + // ---------- output hash (buf) + + var hash_length = (hash_length) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_generichash_final(state_address, hash_address, hash_length) | 0) === 0) { + var ret = (libsodium._free(state_address), _format_output(hash, outputFormat)); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_generichash_init(key, hash_length, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: key (unsized_buf_optional) + + var key_address = null, key_length = 0; + if (key != undefined) { + key = _any_to_Uint8Array(address_pool, key, "key"); + key_address = _to_allocated_buf_address(key); + key_length = key.length; + address_pool.push(key_address); + } + + // ---------- input: hash_length (uint) + + _require_defined(address_pool, hash_length, "hash_length"); + + if (!(typeof hash_length === "number" && (hash_length | 0) === hash_length) && (hash_length | 0) > 0) { + _free_and_throw_type_error(address_pool, "hash_length must be an unsigned integer"); + } + + // ---------- output state (generichash_state) + + var state_address = new AllocatedBuf(357).address; + + if ((libsodium._crypto_generichash_init(state_address, key_address, key_length, hash_length) | 0) === 0) { + var ret = state_address; + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_generichash_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_generichash_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_generichash_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_generichash_update(state_address, message_chunk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (generichash_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: message_chunk (unsized_buf) + + message_chunk = _any_to_Uint8Array(address_pool, message_chunk, "message_chunk"); + var message_chunk_address = _to_allocated_buf_address(message_chunk), + message_chunk_length = message_chunk.length; + address_pool.push(message_chunk_address); + + if ((libsodium._crypto_generichash_update(state_address, message_chunk_address, message_chunk_length) | 0) === 0) { + _free_all(address_pool); + return; + } + _free_and_throw_error(address_pool); + + } + + function crypto_hash(message, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_hash_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_hash(hash_address, message_address, message_length, 0) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_hash_sha256(message, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_hash_sha256_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_hash_sha256(hash_address, message_address, message_length, 0) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_hash_sha512(message, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_hash_sha512_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_hash_sha512(hash_address, message_address, message_length, 0) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_kdf_derive_from_key(subkey_len, subkey_id, ctx, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: subkey_len (uint) + + _require_defined(address_pool, subkey_len, "subkey_len"); + + if (!(typeof subkey_len === "number" && (subkey_len | 0) === subkey_len) && (subkey_len | 0) > 0) { + _free_and_throw_type_error(address_pool, "subkey_len must be an unsigned integer"); + } + + // ---------- input: subkey_id (uint) + + _require_defined(address_pool, subkey_id, "subkey_id"); + + if (!(typeof subkey_id === "number" && (subkey_id | 0) === subkey_id) && (subkey_id | 0) > 0) { + _free_and_throw_type_error(address_pool, "subkey_id must be an unsigned integer"); + } + + // ---------- input: ctx (string) + + ctx = from_string(ctx + "\0"); + var ctx_address = _to_allocated_buf_address(ctx), + ctx_length = ctx.length - 1; + address_pool.push(ctx_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_kdf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output subkey (buf) + + var subkey_length = (subkey_len) | 0, + subkey = new AllocatedBuf(subkey_length), + subkey_address = subkey.address; + + address_pool.push(subkey_address); + + libsodium._crypto_kdf_derive_from_key(subkey_address, subkey_len, 0, subkey_id, 0, ctx_address, key_address); + var ret = (_format_output(subkey, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_kdf_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_kdf_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_kdf_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_kx_client_session_keys(clientPublicKey, clientSecretKey, serverPublicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: clientPublicKey (buf) + + clientPublicKey = _any_to_Uint8Array(address_pool, clientPublicKey, "clientPublicKey"); + var clientPublicKey_address, clientPublicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0; + if (clientPublicKey.length !== clientPublicKey_length) { + _free_and_throw_type_error(address_pool, "invalid clientPublicKey length"); + } + clientPublicKey_address = _to_allocated_buf_address(clientPublicKey); + address_pool.push(clientPublicKey_address); + + // ---------- input: clientSecretKey (buf) + + clientSecretKey = _any_to_Uint8Array(address_pool, clientSecretKey, "clientSecretKey"); + var clientSecretKey_address, clientSecretKey_length = (libsodium._crypto_kx_secretkeybytes()) | 0; + if (clientSecretKey.length !== clientSecretKey_length) { + _free_and_throw_type_error(address_pool, "invalid clientSecretKey length"); + } + clientSecretKey_address = _to_allocated_buf_address(clientSecretKey); + address_pool.push(clientSecretKey_address); + + // ---------- input: serverPublicKey (buf) + + serverPublicKey = _any_to_Uint8Array(address_pool, serverPublicKey, "serverPublicKey"); + var serverPublicKey_address, serverPublicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0; + if (serverPublicKey.length !== serverPublicKey_length) { + _free_and_throw_type_error(address_pool, "invalid serverPublicKey length"); + } + serverPublicKey_address = _to_allocated_buf_address(serverPublicKey); + address_pool.push(serverPublicKey_address); + + // ---------- output sharedRx (buf) + + var sharedRx_length = (libsodium._crypto_kx_sessionkeybytes()) | 0, + sharedRx = new AllocatedBuf(sharedRx_length), + sharedRx_address = sharedRx.address; + + address_pool.push(sharedRx_address); + + // ---------- output sharedTx (buf) + + var sharedTx_length = (libsodium._crypto_kx_sessionkeybytes()) | 0, + sharedTx = new AllocatedBuf(sharedTx_length), + sharedTx_address = sharedTx.address; + + address_pool.push(sharedTx_address); + + if ((libsodium._crypto_kx_client_session_keys(sharedRx_address, sharedTx_address, clientPublicKey_address, clientSecretKey_address, serverPublicKey_address) | 0) === 0) { + var ret = _format_output({sharedRx: sharedRx, sharedTx: sharedTx}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_kx_keypair(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_kx_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_kx_keypair(publicKey_address, privateKey_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_kx_seed_keypair(seed, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: seed (buf) + + seed = _any_to_Uint8Array(address_pool, seed, "seed"); + var seed_address, seed_length = (libsodium._crypto_kx_seedbytes()) | 0; + if (seed.length !== seed_length) { + _free_and_throw_type_error(address_pool, "invalid seed length"); + } + seed_address = _to_allocated_buf_address(seed); + address_pool.push(seed_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_kx_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_kx_seed_keypair(publicKey_address, privateKey_address, seed_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_kx_server_session_keys(serverPublicKey, serverSecretKey, clientPublicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: serverPublicKey (buf) + + serverPublicKey = _any_to_Uint8Array(address_pool, serverPublicKey, "serverPublicKey"); + var serverPublicKey_address, serverPublicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0; + if (serverPublicKey.length !== serverPublicKey_length) { + _free_and_throw_type_error(address_pool, "invalid serverPublicKey length"); + } + serverPublicKey_address = _to_allocated_buf_address(serverPublicKey); + address_pool.push(serverPublicKey_address); + + // ---------- input: serverSecretKey (buf) + + serverSecretKey = _any_to_Uint8Array(address_pool, serverSecretKey, "serverSecretKey"); + var serverSecretKey_address, serverSecretKey_length = (libsodium._crypto_kx_secretkeybytes()) | 0; + if (serverSecretKey.length !== serverSecretKey_length) { + _free_and_throw_type_error(address_pool, "invalid serverSecretKey length"); + } + serverSecretKey_address = _to_allocated_buf_address(serverSecretKey); + address_pool.push(serverSecretKey_address); + + // ---------- input: clientPublicKey (buf) + + clientPublicKey = _any_to_Uint8Array(address_pool, clientPublicKey, "clientPublicKey"); + var clientPublicKey_address, clientPublicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0; + if (clientPublicKey.length !== clientPublicKey_length) { + _free_and_throw_type_error(address_pool, "invalid clientPublicKey length"); + } + clientPublicKey_address = _to_allocated_buf_address(clientPublicKey); + address_pool.push(clientPublicKey_address); + + // ---------- output sharedRx (buf) + + var sharedRx_length = (libsodium._crypto_kx_sessionkeybytes()) | 0, + sharedRx = new AllocatedBuf(sharedRx_length), + sharedRx_address = sharedRx.address; + + address_pool.push(sharedRx_address); + + // ---------- output sharedTx (buf) + + var sharedTx_length = (libsodium._crypto_kx_sessionkeybytes()) | 0, + sharedTx = new AllocatedBuf(sharedTx_length), + sharedTx_address = sharedTx.address; + + address_pool.push(sharedTx_address); + + if ((libsodium._crypto_kx_server_session_keys(sharedRx_address, sharedTx_address, serverPublicKey_address, serverSecretKey_address, clientPublicKey_address) | 0) === 0) { + var ret = _format_output({sharedRx: sharedRx, sharedTx: sharedTx}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_onetimeauth(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_onetimeauth_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_onetimeauth_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_onetimeauth(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_onetimeauth_final(state_address, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (onetimeauth_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_onetimeauth_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_onetimeauth_final(state_address, hash_address) | 0) === 0) { + var ret = (libsodium._free(state_address), _format_output(hash, outputFormat)); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_onetimeauth_init(key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: key (unsized_buf_optional) + + var key_address = null, key_length = 0; + if (key != undefined) { + key = _any_to_Uint8Array(address_pool, key, "key"); + key_address = _to_allocated_buf_address(key); + key_length = key.length; + address_pool.push(key_address); + } + + // ---------- output state (onetimeauth_state) + + var state_address = new AllocatedBuf(144).address; + + if ((libsodium._crypto_onetimeauth_init(state_address, key_address) | 0) === 0) { + var ret = state_address; + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_onetimeauth_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_onetimeauth_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_onetimeauth_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_onetimeauth_update(state_address, message_chunk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (onetimeauth_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: message_chunk (unsized_buf) + + message_chunk = _any_to_Uint8Array(address_pool, message_chunk, "message_chunk"); + var message_chunk_address = _to_allocated_buf_address(message_chunk), + message_chunk_length = message_chunk.length; + address_pool.push(message_chunk_address); + + if ((libsodium._crypto_onetimeauth_update(state_address, message_chunk_address, message_chunk_length) | 0) === 0) { + _free_all(address_pool); + return; + } + _free_and_throw_error(address_pool); + + } + + function crypto_onetimeauth_verify(hash, message, key) { + var address_pool = []; + + // ---------- input: hash (buf) + + hash = _any_to_Uint8Array(address_pool, hash, "hash"); + var hash_address, hash_length = (libsodium._crypto_onetimeauth_bytes()) | 0; + if (hash.length !== hash_length) { + _free_and_throw_type_error(address_pool, "invalid hash length"); + } + hash_address = _to_allocated_buf_address(hash); + address_pool.push(hash_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_onetimeauth_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + var result = libsodium._crypto_onetimeauth_verify(hash_address, message_address, message_length, 0, key_address) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } + + function crypto_pwhash(keyLength, password, salt, opsLimit, memLimit, algorithm, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: keyLength (uint) + + _require_defined(address_pool, keyLength, "keyLength"); + + if (!(typeof keyLength === "number" && (keyLength | 0) === keyLength) && (keyLength | 0) > 0) { + _free_and_throw_type_error(address_pool, "keyLength must be an unsigned integer"); + } + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: salt (buf) + + salt = _any_to_Uint8Array(address_pool, salt, "salt"); + var salt_address, salt_length = (libsodium._crypto_pwhash_saltbytes()) | 0; + if (salt.length !== salt_length) { + _free_and_throw_type_error(address_pool, "invalid salt length"); + } + salt_address = _to_allocated_buf_address(salt); + address_pool.push(salt_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: memLimit (uint) + + _require_defined(address_pool, memLimit, "memLimit"); + + if (!(typeof memLimit === "number" && (memLimit | 0) === memLimit) && (memLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "memLimit must be an unsigned integer"); + } + + // ---------- input: algorithm (uint) + + _require_defined(address_pool, algorithm, "algorithm"); + + if (!(typeof algorithm === "number" && (algorithm | 0) === algorithm) && (algorithm | 0) > 0) { + _free_and_throw_type_error(address_pool, "algorithm must be an unsigned integer"); + } + + // ---------- output derivedKey (buf) + + var derivedKey_length = (keyLength) | 0, + derivedKey = new AllocatedBuf(derivedKey_length), + derivedKey_address = derivedKey.address; + + address_pool.push(derivedKey_address); + + if ((libsodium._crypto_pwhash(derivedKey_address, keyLength, 0, password_address, password_length, 0, salt_address, opsLimit, 0, memLimit, algorithm) | 0) === 0) { + var ret = _format_output(derivedKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_pwhash_scryptsalsa208sha256(keyLength, password, salt, opsLimit, memLimit, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: keyLength (uint) + + _require_defined(address_pool, keyLength, "keyLength"); + + if (!(typeof keyLength === "number" && (keyLength | 0) === keyLength) && (keyLength | 0) > 0) { + _free_and_throw_type_error(address_pool, "keyLength must be an unsigned integer"); + } + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: salt (buf) + + salt = _any_to_Uint8Array(address_pool, salt, "salt"); + var salt_address, salt_length = (libsodium._crypto_pwhash_scryptsalsa208sha256_saltbytes()) | 0; + if (salt.length !== salt_length) { + _free_and_throw_type_error(address_pool, "invalid salt length"); + } + salt_address = _to_allocated_buf_address(salt); + address_pool.push(salt_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: memLimit (uint) + + _require_defined(address_pool, memLimit, "memLimit"); + + if (!(typeof memLimit === "number" && (memLimit | 0) === memLimit) && (memLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "memLimit must be an unsigned integer"); + } + + // ---------- output derivedKey (buf) + + var derivedKey_length = (keyLength) | 0, + derivedKey = new AllocatedBuf(derivedKey_length), + derivedKey_address = derivedKey.address; + + address_pool.push(derivedKey_address); + + if ((libsodium._crypto_pwhash_scryptsalsa208sha256(derivedKey_address, keyLength, 0, password_address, password_length, 0, salt_address, opsLimit, 0, memLimit) | 0) === 0) { + var ret = _format_output(derivedKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_pwhash_scryptsalsa208sha256_ll(password, salt, opsLimit, r, p, keyLength, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: salt (unsized_buf) + + salt = _any_to_Uint8Array(address_pool, salt, "salt"); + var salt_address = _to_allocated_buf_address(salt), + salt_length = salt.length; + address_pool.push(salt_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: r (uint) + + _require_defined(address_pool, r, "r"); + + if (!(typeof r === "number" && (r | 0) === r) && (r | 0) > 0) { + _free_and_throw_type_error(address_pool, "r must be an unsigned integer"); + } + + // ---------- input: p (uint) + + _require_defined(address_pool, p, "p"); + + if (!(typeof p === "number" && (p | 0) === p) && (p | 0) > 0) { + _free_and_throw_type_error(address_pool, "p must be an unsigned integer"); + } + + // ---------- input: keyLength (uint) + + _require_defined(address_pool, keyLength, "keyLength"); + + if (!(typeof keyLength === "number" && (keyLength | 0) === keyLength) && (keyLength | 0) > 0) { + _free_and_throw_type_error(address_pool, "keyLength must be an unsigned integer"); + } + + // ---------- output derivedKey (buf) + + var derivedKey_length = (keyLength) | 0, + derivedKey = new AllocatedBuf(derivedKey_length), + derivedKey_address = derivedKey.address; + + address_pool.push(derivedKey_address); + + if ((libsodium._crypto_pwhash_scryptsalsa208sha256_ll(password_address, password_length, salt_address, salt_length, opsLimit, 0, r, p, derivedKey_address, keyLength) | 0) === 0) { + var ret = _format_output(derivedKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_pwhash_scryptsalsa208sha256_str(password, opsLimit, memLimit, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: memLimit (uint) + + _require_defined(address_pool, memLimit, "memLimit"); + + if (!(typeof memLimit === "number" && (memLimit | 0) === memLimit) && (memLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "memLimit must be an unsigned integer"); + } + + // ---------- output hashed_password (buf) + + var hashed_password_length = (libsodium._crypto_pwhash_scryptsalsa208sha256_strbytes()) | 0, + hashed_password = new AllocatedBuf(hashed_password_length), + hashed_password_address = hashed_password.address; + + address_pool.push(hashed_password_address); + + if ((libsodium._crypto_pwhash_scryptsalsa208sha256_str(hashed_password_address, password_address, password_length, 0, opsLimit, 0, memLimit) | 0) === 0) { + var ret = libsodium.Pointer_stringify(hashed_password_address); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_pwhash_scryptsalsa208sha256_str_verify(hashed_password, password, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: hashed_password (string) + + hashed_password = from_string(hashed_password + "\0"); + var hashed_password_address = _to_allocated_buf_address(hashed_password), + hashed_password_length = hashed_password.length - 1; + address_pool.push(hashed_password_address); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + var result = libsodium._crypto_pwhash_scryptsalsa208sha256_str_verify(hashed_password_address, password_address, password_length, 0) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } + + function crypto_pwhash_str(password, opsLimit, memLimit, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: memLimit (uint) + + _require_defined(address_pool, memLimit, "memLimit"); + + if (!(typeof memLimit === "number" && (memLimit | 0) === memLimit) && (memLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "memLimit must be an unsigned integer"); + } + + // ---------- output hashed_password (buf) + + var hashed_password_length = (libsodium._crypto_pwhash_strbytes()) | 0, + hashed_password = new AllocatedBuf(hashed_password_length), + hashed_password_address = hashed_password.address; + + address_pool.push(hashed_password_address); + + if ((libsodium._crypto_pwhash_str(hashed_password_address, password_address, password_length, 0, opsLimit, 0, memLimit) | 0) === 0) { + var ret = libsodium.Pointer_stringify(hashed_password_address); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_pwhash_str_verify(hashed_password, password, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: hashed_password (string) + + hashed_password = from_string(hashed_password + "\0"); + var hashed_password_address = _to_allocated_buf_address(hashed_password), + hashed_password_length = hashed_password.length - 1; + address_pool.push(hashed_password_address); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + var result = libsodium._crypto_pwhash_str_verify(hashed_password_address, password_address, password_length, 0) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } + + function crypto_scalarmult(privateKey, publicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- output sharedSecret (buf) + + var sharedSecret_length = (libsodium._crypto_scalarmult_bytes()) | 0, + sharedSecret = new AllocatedBuf(sharedSecret_length), + sharedSecret_address = sharedSecret.address; + + address_pool.push(sharedSecret_address); + + if ((libsodium._crypto_scalarmult(sharedSecret_address, privateKey_address, publicKey_address) | 0) === 0) { + var ret = _format_output(sharedSecret, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_scalarmult_base(privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + if ((libsodium._crypto_scalarmult_base(publicKey_address, privateKey_address) | 0) === 0) { + var ret = _format_output(publicKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_secretbox_detached(message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_secretbox_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_secretbox_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output cipher (buf) + + var cipher_length = (message_length) | 0, + cipher = new AllocatedBuf(cipher_length), + cipher_address = cipher.address; + + address_pool.push(cipher_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_secretbox_macbytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_secretbox_detached(cipher_address, mac_address, message_address, message_length, 0, nonce_address, key_address) | 0) === 0) { + var ret = _format_output({mac: mac, cipher: cipher}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_secretbox_easy(message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_secretbox_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_secretbox_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output cipher (buf) + + var cipher_length = (message_length + libsodium._crypto_secretbox_macbytes()) | 0, + cipher = new AllocatedBuf(cipher_length), + cipher_address = cipher.address; + + address_pool.push(cipher_address); + + if ((libsodium._crypto_secretbox_easy(cipher_address, message_address, message_length, 0, nonce_address, key_address) | 0) === 0) { + var ret = _format_output(cipher, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_secretbox_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_secretbox_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_secretbox_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_secretbox_open_detached(ciphertext, mac, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_secretbox_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_secretbox_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_secretbox_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_secretbox_open_detached(message_address, ciphertext_address, mac_address, ciphertext_length, 0, nonce_address, key_address) | 0) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_secretbox_open_easy(ciphertext, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_secretbox_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_secretbox_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length - libsodium._crypto_secretbox_macbytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_secretbox_open_easy(message_address, ciphertext_address, ciphertext_length, 0, nonce_address, key_address) | 0) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_shorthash(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_shorthash_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_shorthash_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_shorthash(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_shorthash_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_shorthash_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_shorthash_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_shorthash_siphashx24(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_shorthash_siphashx24_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_shorthash_siphashx24_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_shorthash_siphashx24(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_sign(message, privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output signature (buf) + + var signature_length = (message.length + libsodium._crypto_sign_bytes()) | 0, + signature = new AllocatedBuf(signature_length), + signature_address = signature.address; + + address_pool.push(signature_address); + + if ((libsodium._crypto_sign(signature_address, null, message_address, message_length, 0, privateKey_address) | 0) === 0) { + var ret = _format_output(signature, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, null); - } - }, + function crypto_sign_detached(message, privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output signature (buf) + + var signature_length = (libsodium._crypto_sign_bytes()) | 0, + signature = new AllocatedBuf(signature_length), + signature_address = signature.address; + + address_pool.push(signature_address); + + if ((libsodium._crypto_sign_detached(signature_address, null, message_address, message_length, 0, privateKey_address) | 0) === 0) { + var ret = _format_output(signature, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - getPublicInstance: function () { - return getNode(this); - } -}; + function crypto_sign_ed25519_pk_to_curve25519(edPk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -_assign(ReactDOMComponent.prototype, ReactDOMComponent.Mixin, ReactMultiChild.Mixin); + // ---------- input: edPk (buf) + + edPk = _any_to_Uint8Array(address_pool, edPk, "edPk"); + var edPk_address, edPk_length = (libsodium._crypto_sign_publickeybytes()) | 0; + if (edPk.length !== edPk_length) { + _free_and_throw_type_error(address_pool, "invalid edPk length"); + } + edPk_address = _to_allocated_buf_address(edPk); + address_pool.push(edPk_address); + + // ---------- output cPk (buf) + + var cPk_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0, + cPk = new AllocatedBuf(cPk_length), + cPk_address = cPk.address; + + address_pool.push(cPk_address); + + if ((libsodium._crypto_sign_ed25519_pk_to_curve25519(cPk_address, edPk_address) | 0) === 0) { + var ret = _format_output(cPk, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -module.exports = ReactDOMComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + function crypto_sign_ed25519_sk_to_curve25519(edSk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -/***/ }), -/* 160 */ -/***/ (function(module, exports, __webpack_require__) { + // ---------- input: edSk (buf) + + edSk = _any_to_Uint8Array(address_pool, edSk, "edSk"); + var edSk_address, edSk_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (edSk.length !== edSk_length) { + _free_and_throw_type_error(address_pool, "invalid edSk length"); + } + edSk_address = _to_allocated_buf_address(edSk); + address_pool.push(edSk_address); + + // ---------- output cSk (buf) + + var cSk_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0, + cSk = new AllocatedBuf(cSk_length), + cSk_address = cSk.address; + + address_pool.push(cSk_address); + + if ((libsodium._crypto_sign_ed25519_sk_to_curve25519(cSk_address, edSk_address) | 0) === 0) { + var ret = _format_output(cSk, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + function crypto_sign_ed25519_sk_to_pk(privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + if ((libsodium._crypto_sign_ed25519_sk_to_pk(publicKey_address, privateKey_address) | 0) === 0) { + var ret = _format_output(publicKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + function crypto_sign_ed25519_sk_to_seed(privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -var ReactDOMComponentTree = __webpack_require__(6); + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output seed (buf) + + var seed_length = (libsodium._crypto_sign_seedbytes()) | 0, + seed = new AllocatedBuf(seed_length), + seed_address = seed.address; + + address_pool.push(seed_address); + + if ((libsodium._crypto_sign_ed25519_sk_to_seed(seed_address, privateKey_address) | 0) === 0) { + var ret = _format_output(seed, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var focusNode = __webpack_require__(91); + function crypto_sign_final_create(state_address, privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (sign_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output signature (buf) + + var signature_length = (libsodium._crypto_sign_bytes()) | 0, + signature = new AllocatedBuf(signature_length), + signature_address = signature.address; + + address_pool.push(signature_address); + + if ((libsodium._crypto_sign_final_create(state_address, signature_address, null, privateKey_address) | 0) === 0) { + var ret = (libsodium._free(state_address), _format_output(signature, outputFormat)); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var AutoFocusUtils = { - focusDOMComponent: function () { - focusNode(ReactDOMComponentTree.getNodeFromInstance(this)); - } -}; + function crypto_sign_final_verify(state_address, signature, publicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (sign_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: signature (buf) + + signature = _any_to_Uint8Array(address_pool, signature, "signature"); + var signature_address, signature_length = (libsodium._crypto_sign_bytes()) | 0; + if (signature.length !== signature_length) { + _free_and_throw_type_error(address_pool, "invalid signature length"); + } + signature_address = _to_allocated_buf_address(signature); + address_pool.push(signature_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + var verificationResult = libsodium._crypto_sign_final_verify(state_address, signature_address, publicKey_address) | 0; + var ret = (verificationResult === 0); + _free_all(address_pool); + return ret; + + } -module.exports = AutoFocusUtils; + function crypto_sign_init(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output state (sign_state) + + var state_address = new AllocatedBuf(208).address; + + if ((libsodium._crypto_sign_init(state_address) | 0) === 0) { + var ret = state_address; + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -/***/ }), -/* 161 */ -/***/ (function(module, exports, __webpack_require__) { + function crypto_sign_keypair(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_sign_keypair(publicKey_address, privateKey_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey, keyType: 'ed25519'}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + function crypto_sign_open(signedMessage, publicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: signedMessage (unsized_buf) + + signedMessage = _any_to_Uint8Array(address_pool, signedMessage, "signedMessage"); + var signedMessage_address = _to_allocated_buf_address(signedMessage), + signedMessage_length = signedMessage.length; + address_pool.push(signedMessage_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- output message (buf) + + var message_length = (signedMessage_length - libsodium._crypto_sign_bytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_sign_open(message_address, null, signedMessage_address, signedMessage_length, 0, publicKey_address) | 0) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + function crypto_sign_seed_keypair(seed, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + // ---------- input: seed (buf) + + seed = _any_to_Uint8Array(address_pool, seed, "seed"); + var seed_address, seed_length = (libsodium._crypto_sign_seedbytes()) | 0; + if (seed.length !== seed_length) { + _free_and_throw_type_error(address_pool, "invalid seed length"); + } + seed_address = _to_allocated_buf_address(seed); + address_pool.push(seed_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_sign_seed_keypair(publicKey_address, privateKey_address, seed_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey, keyType: "ed25519"}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var CSSProperty = __webpack_require__(92); -var ExecutionEnvironment = __webpack_require__(8); -var ReactInstrumentation = __webpack_require__(13); + function crypto_sign_update(state_address, message_chunk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (sign_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: message_chunk (unsized_buf) + + message_chunk = _any_to_Uint8Array(address_pool, message_chunk, "message_chunk"); + var message_chunk_address = _to_allocated_buf_address(message_chunk), + message_chunk_length = message_chunk.length; + address_pool.push(message_chunk_address); + + if ((libsodium._crypto_sign_update(state_address, message_chunk_address, message_chunk_length) | 0) === 0) { + _free_all(address_pool); + return; + } + _free_and_throw_error(address_pool); + + } -var camelizeStyleName = __webpack_require__(162); -var dangerousStyleValue = __webpack_require__(164); -var hyphenateStyleName = __webpack_require__(165); -var memoizeStringOnly = __webpack_require__(167); -var warning = __webpack_require__(2); + function crypto_sign_verify_detached(signature, message, publicKey) { + var address_pool = []; -var processStyleName = memoizeStringOnly(function (styleName) { - return hyphenateStyleName(styleName); -}); + // ---------- input: signature (buf) + + signature = _any_to_Uint8Array(address_pool, signature, "signature"); + var signature_address, signature_length = (libsodium._crypto_sign_bytes()) | 0; + if (signature.length !== signature_length) { + _free_and_throw_type_error(address_pool, "invalid signature length"); + } + signature_address = _to_allocated_buf_address(signature); + address_pool.push(signature_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + var verificationResult = libsodium._crypto_sign_verify_detached(signature_address, message_address, message_length, 0, publicKey_address) | 0; + var ret = (verificationResult === 0); + _free_all(address_pool); + return ret; + + } -var hasShorthandPropertyBug = false; -var styleFloatAccessor = 'cssFloat'; -if (ExecutionEnvironment.canUseDOM) { - var tempStyle = document.createElement('div').style; - try { - // IE8 throws "Invalid argument." if resetting shorthand style properties. - tempStyle.font = ''; - } catch (e) { - hasShorthandPropertyBug = true; - } - // IE8 only supports accessing cssFloat (standard) as styleFloat - if (document.documentElement.style.cssFloat === undefined) { - styleFloatAccessor = 'styleFloat'; - } -} + function crypto_stream_chacha20_ietf_xor(input_message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_chacha20_ietf_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_chacha20_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_chacha20_ietf_xor(output_message_address, input_message_address, input_message_length, 0, nonce_address, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -if (process.env.NODE_ENV !== 'production') { - // 'msTransform' is correct, but the other prefixes should be capitalized - var badVendoredStyleNamePattern = /^(?:webkit|moz|o)[A-Z]/; + function crypto_stream_chacha20_ietf_xor_ic(input_message, nonce, nonce_increment, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_chacha20_ietf_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: nonce_increment (uint) + + _require_defined(address_pool, nonce_increment, "nonce_increment"); + + if (!(typeof nonce_increment === "number" && (nonce_increment | 0) === nonce_increment) && (nonce_increment | 0) > 0) { + _free_and_throw_type_error(address_pool, "nonce_increment must be an unsigned integer"); + } + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_chacha20_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_chacha20_ietf_xor_ic(output_message_address, input_message_address, input_message_length, 0, nonce_address, nonce_increment, 0, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - // style values shouldn't contain a semicolon - var badStyleValueWithSemicolonPattern = /;\s*$/; + function crypto_stream_chacha20_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_stream_chacha20_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_stream_chacha20_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - var warnedStyleNames = {}; - var warnedStyleValues = {}; - var warnedForNaNValue = false; + function crypto_stream_chacha20_xor(input_message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_chacha20_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_chacha20_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_chacha20_xor(output_message_address, input_message_address, input_message_length, 0, nonce_address, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - var warnHyphenatedStyleName = function (name, owner) { - if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { - return; - } + function crypto_stream_chacha20_xor_ic(input_message, nonce, nonce_increment, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_chacha20_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: nonce_increment (uint) + + _require_defined(address_pool, nonce_increment, "nonce_increment"); + + if (!(typeof nonce_increment === "number" && (nonce_increment | 0) === nonce_increment) && (nonce_increment | 0) > 0) { + _free_and_throw_type_error(address_pool, "nonce_increment must be an unsigned integer"); + } + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_chacha20_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_chacha20_xor_ic(output_message_address, input_message_address, input_message_length, 0, nonce_address, nonce_increment, 0, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - warnedStyleNames[name] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported style property %s. Did you mean %s?%s', name, camelizeStyleName(name), checkRenderMessage(owner)) : void 0; - }; + function crypto_stream_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_stream_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_stream_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - var warnBadVendoredStyleName = function (name, owner) { - if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { - return; - } + function crypto_stream_xchacha20_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_stream_xchacha20_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_stream_xchacha20_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - warnedStyleNames[name] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported vendor-prefixed style property %s. Did you mean %s?%s', name, name.charAt(0).toUpperCase() + name.slice(1), checkRenderMessage(owner)) : void 0; - }; + function crypto_stream_xchacha20_xor(input_message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_xchacha20_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_xchacha20_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_xchacha20_xor(output_message_address, input_message_address, input_message_length, 0, nonce_address, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - var warnStyleValueWithSemicolon = function (name, value, owner) { - if (warnedStyleValues.hasOwnProperty(value) && warnedStyleValues[value]) { - return; - } + function crypto_stream_xchacha20_xor_ic(input_message, nonce, nonce_increment, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_xchacha20_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: nonce_increment (uint) + + _require_defined(address_pool, nonce_increment, "nonce_increment"); + + if (!(typeof nonce_increment === "number" && (nonce_increment | 0) === nonce_increment) && (nonce_increment | 0) > 0) { + _free_and_throw_type_error(address_pool, "nonce_increment must be an unsigned integer"); + } + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_xchacha20_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_xchacha20_xor_ic(output_message_address, input_message_address, input_message_length, 0, nonce_address, nonce_increment, 0, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - warnedStyleValues[value] = true; - process.env.NODE_ENV !== 'production' ? warning(false, "Style property values shouldn't contain a semicolon.%s " + 'Try "%s: %s" instead.', checkRenderMessage(owner), name, value.replace(badStyleValueWithSemicolonPattern, '')) : void 0; - }; + function randombytes_buf(length, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - var warnStyleValueIsNaN = function (name, value, owner) { - if (warnedForNaNValue) { - return; - } + // ---------- input: length (uint) + + _require_defined(address_pool, length, "length"); + + if (!(typeof length === "number" && (length | 0) === length) && (length | 0) > 0) { + _free_and_throw_type_error(address_pool, "length must be an unsigned integer"); + } + + // ---------- output output (buf) + + var output_length = (length) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._randombytes_buf(output_address, length); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - warnedForNaNValue = true; - process.env.NODE_ENV !== 'production' ? warning(false, '`NaN` is an invalid value for the `%s` css style property.%s', name, checkRenderMessage(owner)) : void 0; - }; + function randombytes_buf_deterministic(length, seed, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - var checkRenderMessage = function (owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; - }; + // ---------- input: length (uint) + + _require_defined(address_pool, length, "length"); + + if (!(typeof length === "number" && (length | 0) === length) && (length | 0) > 0) { + _free_and_throw_type_error(address_pool, "length must be an unsigned integer"); + } + + // ---------- input: seed (buf) + + seed = _any_to_Uint8Array(address_pool, seed, "seed"); + var seed_address, seed_length = (libsodium._randombytes_seedbytes()) | 0; + if (seed.length !== seed_length) { + _free_and_throw_type_error(address_pool, "invalid seed length"); + } + seed_address = _to_allocated_buf_address(seed); + address_pool.push(seed_address); + + // ---------- output output (buf) + + var output_length = (length) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._randombytes_buf_deterministic(output_address, length, 0, seed); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - /** - * @param {string} name - * @param {*} value - * @param {ReactDOMComponent} component - */ - var warnValidStyle = function (name, value, component) { - var owner; - if (component) { - owner = component._currentElement._owner; - } - if (name.indexOf('-') > -1) { - warnHyphenatedStyleName(name, owner); - } else if (badVendoredStyleNamePattern.test(name)) { - warnBadVendoredStyleName(name, owner); - } else if (badStyleValueWithSemicolonPattern.test(value)) { - warnStyleValueWithSemicolon(name, value, owner); - } + function randombytes_close(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - if (typeof value === 'number' && isNaN(value)) { - warnStyleValueIsNaN(name, value, owner); - } - }; -} + libsodium._randombytes_close(); + + } -/** - * Operations for dealing with CSS properties. - */ -var CSSPropertyOperations = { - /** - * Serializes a mapping of style properties for use as inline styles: - * - * > createMarkupForStyles({width: '200px', height: 0}) - * "width:200px;height:0;" - * - * Undefined values are ignored so that declarative programming is easier. - * The result should be HTML-escaped before insertion into the DOM. - * - * @param {object} styles - * @param {ReactDOMComponent} component - * @return {?string} - */ - createMarkupForStyles: function (styles, component) { - var serialized = ''; - for (var styleName in styles) { - if (!styles.hasOwnProperty(styleName)) { - continue; - } - var isCustomProperty = styleName.indexOf('--') === 0; - var styleValue = styles[styleName]; - if (process.env.NODE_ENV !== 'production') { - if (!isCustomProperty) { - warnValidStyle(styleName, styleValue, component); - } - } - if (styleValue != null) { - serialized += processStyleName(styleName) + ':'; - serialized += dangerousStyleValue(styleName, styleValue, component, isCustomProperty) + ';'; - } - } - return serialized || null; - }, + function randombytes_random(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - /** - * Sets the value for multiple styles on a node. If a value is specified as - * '' (empty string), the corresponding style property will be unset. - * - * @param {DOMElement} node - * @param {object} styles - * @param {ReactDOMComponent} component - */ - setValueForStyles: function (node, styles, component) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: component._debugID, - type: 'update styles', - payload: styles - }); - } + var random_value = libsodium._randombytes_random() >>> 0; + var ret = (random_value); + _free_all(address_pool); + return ret; + + } - var style = node.style; - for (var styleName in styles) { - if (!styles.hasOwnProperty(styleName)) { - continue; - } - var isCustomProperty = styleName.indexOf('--') === 0; - if (process.env.NODE_ENV !== 'production') { - if (!isCustomProperty) { - warnValidStyle(styleName, styles[styleName], component); - } - } - var styleValue = dangerousStyleValue(styleName, styles[styleName], component, isCustomProperty); - if (styleName === 'float' || styleName === 'cssFloat') { - styleName = styleFloatAccessor; - } - if (isCustomProperty) { - style.setProperty(styleName, styleValue); - } else if (styleValue) { - style[styleName] = styleValue; - } else { - var expansion = hasShorthandPropertyBug && CSSProperty.shorthandPropertyExpansions[styleName]; - if (expansion) { - // Shorthand property that IE8 won't like unsetting, so unset each - // component to placate it - for (var individualStyleName in expansion) { - style[individualStyleName] = ''; - } - } else { - style[styleName] = ''; - } - } - } - } -}; + function randombytes_set_implementation(implementation, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: implementation (randombytes_implementation) + + var implementation_address = libsodium._malloc(6 * 4); + for (var i = 0; i < 6; i++) { + libsodium.setValue(implementation_address + i * 4, + libsodium.Runtime.addFunction(implementation + [["implementation_name", "random", "stir", "uniform", "buf", "close"][i]]), + "i32"); + } + + if ((libsodium._randombytes_set_implementation(implementation_address) | 0) === 0) { + _free_all(address_pool); + return; + } + _free_and_throw_error(address_pool); + + } -module.exports = CSSPropertyOperations; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + function randombytes_stir(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -/***/ }), -/* 162 */ -/***/ (function(module, exports, __webpack_require__) { + libsodium._randombytes_stir(); + + } -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + function randombytes_uniform(upper_bound, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: upper_bound (uint) + + _require_defined(address_pool, upper_bound, "upper_bound"); + + if (!(typeof upper_bound === "number" && (upper_bound | 0) === upper_bound) && (upper_bound | 0) > 0) { + _free_and_throw_type_error(address_pool, "upper_bound must be an unsigned integer"); + } + + var random_value = libsodium._randombytes_uniform(upper_bound) >>> 0; + var ret = (random_value); + _free_all(address_pool); + return ret; + + } + function sodium_version_string() { + var address_pool = []; + var version = libsodium._sodium_version_string(); + var ret = (libsodium.Pointer_stringify(version)); + _free_all(address_pool); + return ret; + + } -var camelize = __webpack_require__(163); -var msPattern = /^-ms-/; + exports.add = add; + exports.compare = compare; + exports.from_base64 = from_base64; + exports.from_hex = from_hex; + exports.from_string = from_string; + exports.increment = increment; + exports.is_zero = is_zero; + exports.libsodium = libsodium; + exports.memcmp = memcmp; + exports.memzero = memzero; + exports.output_formats = output_formats; + exports.symbols = symbols; + exports.to_base64 = to_base64; + exports.to_hex = to_hex; + exports.to_string = to_string; + + + var exported_functions = ["crypto_aead_chacha20poly1305_decrypt", "crypto_aead_chacha20poly1305_decrypt_detached", "crypto_aead_chacha20poly1305_encrypt", "crypto_aead_chacha20poly1305_encrypt_detached", "crypto_aead_chacha20poly1305_ietf_decrypt", "crypto_aead_chacha20poly1305_ietf_decrypt_detached", "crypto_aead_chacha20poly1305_ietf_encrypt", "crypto_aead_chacha20poly1305_ietf_encrypt_detached", "crypto_aead_chacha20poly1305_ietf_keygen", "crypto_aead_chacha20poly1305_keygen", "crypto_aead_xchacha20poly1305_ietf_decrypt", "crypto_aead_xchacha20poly1305_ietf_decrypt_detached", "crypto_aead_xchacha20poly1305_ietf_encrypt", "crypto_aead_xchacha20poly1305_ietf_encrypt_detached", "crypto_aead_xchacha20poly1305_ietf_keygen", "crypto_auth", "crypto_auth_hmacsha256", "crypto_auth_hmacsha256_keygen", "crypto_auth_hmacsha256_verify", "crypto_auth_hmacsha512", "crypto_auth_hmacsha512_keygen", "crypto_auth_hmacsha512_verify", "crypto_auth_keygen", "crypto_auth_verify", "crypto_box_beforenm", "crypto_box_detached", "crypto_box_easy", "crypto_box_easy_afternm", "crypto_box_keypair", "crypto_box_open_detached", "crypto_box_open_easy", "crypto_box_open_easy_afternm", "crypto_box_seal", "crypto_box_seal_open", "crypto_box_seed_keypair", "crypto_generichash", "crypto_generichash_final", "crypto_generichash_init", "crypto_generichash_keygen", "crypto_generichash_update", "crypto_hash", "crypto_hash_sha256", "crypto_hash_sha512", "crypto_kdf_derive_from_key", "crypto_kdf_keygen", "crypto_kx_client_session_keys", "crypto_kx_keypair", "crypto_kx_seed_keypair", "crypto_kx_server_session_keys", "crypto_onetimeauth", "crypto_onetimeauth_final", "crypto_onetimeauth_init", "crypto_onetimeauth_keygen", "crypto_onetimeauth_update", "crypto_onetimeauth_verify", "crypto_pwhash", "crypto_pwhash_scryptsalsa208sha256", "crypto_pwhash_scryptsalsa208sha256_ll", "crypto_pwhash_scryptsalsa208sha256_str", "crypto_pwhash_scryptsalsa208sha256_str_verify", "crypto_pwhash_str", "crypto_pwhash_str_verify", "crypto_scalarmult", "crypto_scalarmult_base", "crypto_secretbox_detached", "crypto_secretbox_easy", "crypto_secretbox_keygen", "crypto_secretbox_open_detached", "crypto_secretbox_open_easy", "crypto_shorthash", "crypto_shorthash_keygen", "crypto_shorthash_siphashx24", "crypto_sign", "crypto_sign_detached", "crypto_sign_ed25519_pk_to_curve25519", "crypto_sign_ed25519_sk_to_curve25519", "crypto_sign_ed25519_sk_to_pk", "crypto_sign_ed25519_sk_to_seed", "crypto_sign_final_create", "crypto_sign_final_verify", "crypto_sign_init", "crypto_sign_keypair", "crypto_sign_open", "crypto_sign_seed_keypair", "crypto_sign_update", "crypto_sign_verify_detached", "crypto_stream_chacha20_ietf_xor", "crypto_stream_chacha20_ietf_xor_ic", "crypto_stream_chacha20_keygen", "crypto_stream_chacha20_xor", "crypto_stream_chacha20_xor_ic", "crypto_stream_keygen", "crypto_stream_xchacha20_keygen", "crypto_stream_xchacha20_xor", "crypto_stream_xchacha20_xor_ic", "randombytes_buf", "randombytes_buf_deterministic", "randombytes_close", "randombytes_random", "randombytes_set_implementation", "randombytes_stir", "randombytes_uniform", "sodium_version_string"], + functions = [crypto_aead_chacha20poly1305_decrypt, crypto_aead_chacha20poly1305_decrypt_detached, crypto_aead_chacha20poly1305_encrypt, crypto_aead_chacha20poly1305_encrypt_detached, crypto_aead_chacha20poly1305_ietf_decrypt, crypto_aead_chacha20poly1305_ietf_decrypt_detached, crypto_aead_chacha20poly1305_ietf_encrypt, crypto_aead_chacha20poly1305_ietf_encrypt_detached, crypto_aead_chacha20poly1305_ietf_keygen, crypto_aead_chacha20poly1305_keygen, crypto_aead_xchacha20poly1305_ietf_decrypt, crypto_aead_xchacha20poly1305_ietf_decrypt_detached, crypto_aead_xchacha20poly1305_ietf_encrypt, crypto_aead_xchacha20poly1305_ietf_encrypt_detached, crypto_aead_xchacha20poly1305_ietf_keygen, crypto_auth, crypto_auth_hmacsha256, crypto_auth_hmacsha256_keygen, crypto_auth_hmacsha256_verify, crypto_auth_hmacsha512, crypto_auth_hmacsha512_keygen, crypto_auth_hmacsha512_verify, crypto_auth_keygen, crypto_auth_verify, crypto_box_beforenm, crypto_box_detached, crypto_box_easy, crypto_box_easy_afternm, crypto_box_keypair, crypto_box_open_detached, crypto_box_open_easy, crypto_box_open_easy_afternm, crypto_box_seal, crypto_box_seal_open, crypto_box_seed_keypair, crypto_generichash, crypto_generichash_final, crypto_generichash_init, crypto_generichash_keygen, crypto_generichash_update, crypto_hash, crypto_hash_sha256, crypto_hash_sha512, crypto_kdf_derive_from_key, crypto_kdf_keygen, crypto_kx_client_session_keys, crypto_kx_keypair, crypto_kx_seed_keypair, crypto_kx_server_session_keys, crypto_onetimeauth, crypto_onetimeauth_final, crypto_onetimeauth_init, crypto_onetimeauth_keygen, crypto_onetimeauth_update, crypto_onetimeauth_verify, crypto_pwhash, crypto_pwhash_scryptsalsa208sha256, crypto_pwhash_scryptsalsa208sha256_ll, crypto_pwhash_scryptsalsa208sha256_str, crypto_pwhash_scryptsalsa208sha256_str_verify, crypto_pwhash_str, crypto_pwhash_str_verify, crypto_scalarmult, crypto_scalarmult_base, crypto_secretbox_detached, crypto_secretbox_easy, crypto_secretbox_keygen, crypto_secretbox_open_detached, crypto_secretbox_open_easy, crypto_shorthash, crypto_shorthash_keygen, crypto_shorthash_siphashx24, crypto_sign, crypto_sign_detached, crypto_sign_ed25519_pk_to_curve25519, crypto_sign_ed25519_sk_to_curve25519, crypto_sign_ed25519_sk_to_pk, crypto_sign_ed25519_sk_to_seed, crypto_sign_final_create, crypto_sign_final_verify, crypto_sign_init, crypto_sign_keypair, crypto_sign_open, crypto_sign_seed_keypair, crypto_sign_update, crypto_sign_verify_detached, crypto_stream_chacha20_ietf_xor, crypto_stream_chacha20_ietf_xor_ic, crypto_stream_chacha20_keygen, crypto_stream_chacha20_xor, crypto_stream_chacha20_xor_ic, crypto_stream_keygen, crypto_stream_xchacha20_keygen, crypto_stream_xchacha20_xor, crypto_stream_xchacha20_xor_ic, randombytes_buf, randombytes_buf_deterministic, randombytes_close, randombytes_random, randombytes_set_implementation, randombytes_stir, randombytes_uniform, sodium_version_string]; + for (var i = 0; i < functions.length; i++) { + if (typeof libsodium["_" + exported_functions[i]] === "function") { + exports[exported_functions[i]] = functions[i]; + } + } + var constants = ["SODIUM_LIBRARY_VERSION_MAJOR", "SODIUM_LIBRARY_VERSION_MINOR", "crypto_aead_chacha20poly1305_ABYTES", "crypto_aead_chacha20poly1305_KEYBYTES", "crypto_aead_chacha20poly1305_NPUBBYTES", "crypto_aead_chacha20poly1305_NSECBYTES", "crypto_aead_chacha20poly1305_ietf_ABYTES", "crypto_aead_chacha20poly1305_ietf_KEYBYTES", "crypto_aead_chacha20poly1305_ietf_NPUBBYTES", "crypto_aead_chacha20poly1305_ietf_NSECBYTES", "crypto_aead_xchacha20poly1305_ietf_ABYTES", "crypto_aead_xchacha20poly1305_ietf_KEYBYTES", "crypto_aead_xchacha20poly1305_ietf_NPUBBYTES", "crypto_aead_xchacha20poly1305_ietf_NSECBYTES", "crypto_auth_BYTES", "crypto_auth_KEYBYTES", "crypto_auth_hmacsha256_BYTES", "crypto_auth_hmacsha256_KEYBYTES", "crypto_auth_hmacsha512_BYTES", "crypto_auth_hmacsha512_KEYBYTES", "crypto_box_BEFORENMBYTES", "crypto_box_MACBYTES", "crypto_box_NONCEBYTES", "crypto_box_PUBLICKEYBYTES", "crypto_box_SEALBYTES", "crypto_box_SECRETKEYBYTES", "crypto_box_SEEDBYTES", "crypto_generichash_BYTES", "crypto_generichash_BYTES_MAX", "crypto_generichash_BYTES_MIN", "crypto_generichash_KEYBYTES", "crypto_generichash_KEYBYTES_MAX", "crypto_generichash_KEYBYTES_MIN", "crypto_hash_BYTES", "crypto_kdf_BYTES_MAX", "crypto_kdf_BYTES_MIN", "crypto_kdf_CONTEXTBYTES", "crypto_kdf_KEYBYTES", "crypto_kx_PUBLICKEYBYTES", "crypto_kx_SECRETKEYBYTES", "crypto_kx_SEEDBYTES", "crypto_kx_SESSSIONKEYBYTES", "crypto_onetimeauth_BYTES", "crypto_onetimeauth_KEYBYTES", "crypto_pwhash_ALG_ARGON2I13", "crypto_pwhash_ALG_DEFAULT", "crypto_pwhash_BYTES_MAX", "crypto_pwhash_BYTES_MIN", "crypto_pwhash_MEMLIMIT_INTERACTIVE", "crypto_pwhash_MEMLIMIT_MAX", "crypto_pwhash_MEMLIMIT_MIN", "crypto_pwhash_MEMLIMIT_MODERATE", "crypto_pwhash_MEMLIMIT_SENSITIVE", "crypto_pwhash_OPSLIMIT_INTERACTIVE", "crypto_pwhash_OPSLIMIT_MAX", "crypto_pwhash_OPSLIMIT_MIN", "crypto_pwhash_OPSLIMIT_MODERATE", "crypto_pwhash_OPSLIMIT_SENSITIVE", "crypto_pwhash_PASSWD_MAX", "crypto_pwhash_PASSWD_MIN", "crypto_pwhash_SALTBYTES", "crypto_pwhash_STRBYTES", "crypto_pwhash_STR_VERIFY", "crypto_pwhash_scryptsalsa208sha256_BYTES_MAX", "crypto_pwhash_scryptsalsa208sha256_BYTES_MIN", "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_INTERACTIVE", "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_MAX", "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_MIN", "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_SENSITIVE", "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_INTERACTIVE", "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_MAX", "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_MIN", "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_SENSITIVE", "crypto_pwhash_scryptsalsa208sha256_SALTBYTES", "crypto_pwhash_scryptsalsa208sha256_STRBYTES", "crypto_pwhash_scryptsalsa208sha256_STR_VERIFY", "crypto_scalarmult_BYTES", "crypto_scalarmult_SCALARBYTES", "crypto_secretbox_KEYBYTES", "crypto_secretbox_MACBYTES", "crypto_secretbox_NONCEBYTES", "crypto_shorthash_BYTES", "crypto_shorthash_KEYBYTES", "crypto_shorthash_siphashx24_BYTES", "crypto_shorthash_siphashx24_KEYBYTES", "crypto_sign_BYTES", "crypto_sign_PUBLICKEYBYTES", "crypto_sign_SECRETKEYBYTES", "crypto_sign_SEEDBYTES", "crypto_stream_chacha20_KEYBYTES", "crypto_stream_chacha20_NONCEBYTES", "crypto_stream_chacha20_ietf_KEYBYTES", "crypto_stream_chacha20_ietf_NONCEBYTES", "crypto_stream_xchacha20_ietf_KEYBYTES", "crypto_stream_xchacha20_ietf_NONCEBYTES", "randombytes_SEEDBYTES"]; + for (var i = 0; i < constants.length; i++) { + var raw = libsodium["_" + constants[i].toLowerCase()]; + if (typeof raw === "function") exports[constants[i]] = raw()|0; + } + var constants_str = ["SODIUM_VERSION_STRING", "crypto_pwhash_STRPREFIX", "crypto_pwhash_scryptsalsa208sha256_STRPREFIX"]; + for (var i = 0; i < constants_str.length; i++) { + var raw = libsodium["_" + constants_str[i].toLowerCase()]; + if (typeof raw === "function") exports[constants_str[i]] = libsodium.Pointer_stringify(raw()); + } -/** - * Camelcases a hyphenated CSS property name, for example: - * - * > camelizeStyleName('background-color') - * < "backgroundColor" - * > camelizeStyleName('-moz-transition') - * < "MozTransition" - * > camelizeStyleName('-ms-transition') - * < "msTransition" - * - * As Andi Smith suggests - * (http://www.andismith.com/blog/2012/02/modernizr-prefixed/), an `-ms` prefix - * is converted to lowercase `ms`. - * - * @param {string} string - * @return {string} - */ -function camelizeStyleName(string) { - return camelize(string.replace(msPattern, 'ms-')); -} + return exports; +}))); -module.exports = camelizeStyleName; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 163 */ +/* 416 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (root, factory) { + if (true) { + !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), + __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? + (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); + } else if (typeof exports === 'object' && + typeof exports.nodeName !== 'string') { + factory(exports); + } else { + factory(root.libsodium = {}); + } +})(this, (function (exports) { + var Module = exports; +var Module;if(!Module)Module=(typeof Module!=="undefined"?Module:null)||{};var moduleOverrides={};for(var key in Module){if(Module.hasOwnProperty(key)){moduleOverrides[key]=Module[key]}}var ENVIRONMENT_IS_WEB=false;var ENVIRONMENT_IS_WORKER=false;var ENVIRONMENT_IS_NODE=false;var ENVIRONMENT_IS_SHELL=false;if(Module["ENVIRONMENT"]){if(Module["ENVIRONMENT"]==="WEB"){ENVIRONMENT_IS_WEB=true}else if(Module["ENVIRONMENT"]==="WORKER"){ENVIRONMENT_IS_WORKER=true}else if(Module["ENVIRONMENT"]==="NODE"){ENVIRONMENT_IS_NODE=true}else if(Module["ENVIRONMENT"]==="SHELL"){ENVIRONMENT_IS_SHELL=true}else{throw new Error("The provided Module['ENVIRONMENT'] value is not valid. It must be one of: WEB|WORKER|NODE|SHELL.")}}else{ENVIRONMENT_IS_WEB=typeof window==="object";ENVIRONMENT_IS_WORKER=typeof importScripts==="function";ENVIRONMENT_IS_NODE=typeof process==="object"&&"function"==="function"&&!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_WORKER;ENVIRONMENT_IS_SHELL=!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_NODE&&!ENVIRONMENT_IS_WORKER}if(ENVIRONMENT_IS_NODE){if(!Module["print"])Module["print"]=console.log;if(!Module["printErr"])Module["printErr"]=console.warn;var nodeFS;var nodePath;Module["read"]=function shell_read(filename,binary){if(!nodeFS)nodeFS=__webpack_require__(417);if(!nodePath)nodePath=__webpack_require__(418);filename=nodePath["normalize"](filename);var ret=nodeFS["readFileSync"](filename);return binary?ret:ret.toString()};Module["readBinary"]=function readBinary(filename){var ret=Module["read"](filename,true);if(!ret.buffer){ret=new Uint8Array(ret)}assert(ret.buffer);return ret};Module["load"]=function load(f){globalEval(read(f))};if(!Module["thisProgram"]){if(process["argv"].length>1){Module["thisProgram"]=process["argv"][1].replace(/\\/g,"/")}else{Module["thisProgram"]="unknown-program"}}Module["arguments"]=process["argv"].slice(2);if(true){module["exports"]=Module}process["on"]("uncaughtException",(function(ex){if(!(ex instanceof ExitStatus)){throw ex}}));Module["inspect"]=(function(){return"[Emscripten Module object]"})}else if(ENVIRONMENT_IS_SHELL){if(!Module["print"])Module["print"]=print;if(typeof printErr!="undefined")Module["printErr"]=printErr;if(typeof read!="undefined"){Module["read"]=read}else{Module["read"]=function shell_read(){throw"no read() available"}}Module["readBinary"]=function readBinary(f){if(typeof readbuffer==="function"){return new Uint8Array(readbuffer(f))}var data=read(f,"binary");assert(typeof data==="object");return data};if(typeof scriptArgs!="undefined"){Module["arguments"]=scriptArgs}else if(typeof arguments!="undefined"){Module["arguments"]=arguments}if(typeof quit==="function"){Module["quit"]=(function(status,toThrow){quit(status)})}}else if(ENVIRONMENT_IS_WEB||ENVIRONMENT_IS_WORKER){Module["read"]=function shell_read(url){var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.send(null);return xhr.responseText};if(ENVIRONMENT_IS_WORKER){Module["readBinary"]=function readBinary(url){var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.responseType="arraybuffer";xhr.send(null);return xhr.response}}Module["readAsync"]=function readAsync(url,onload,onerror){var xhr=new XMLHttpRequest;xhr.open("GET",url,true);xhr.responseType="arraybuffer";xhr.onload=function xhr_onload(){if(xhr.status==200||xhr.status==0&&xhr.response){onload(xhr.response)}else{onerror()}};xhr.onerror=onerror;xhr.send(null)};if(typeof arguments!="undefined"){Module["arguments"]=arguments}if(typeof console!=="undefined"){if(!Module["print"])Module["print"]=function shell_print(x){console.log(x)};if(!Module["printErr"])Module["printErr"]=function shell_printErr(x){console.warn(x)}}else{var TRY_USE_DUMP=false;if(!Module["print"])Module["print"]=TRY_USE_DUMP&&typeof dump!=="undefined"?(function(x){dump(x)}):(function(x){})}if(ENVIRONMENT_IS_WORKER){Module["load"]=importScripts}if(typeof Module["setWindowTitle"]==="undefined"){Module["setWindowTitle"]=(function(title){document.title=title})}}else{throw"Unknown runtime environment. Where are we?"}function globalEval(x){abort("NO_DYNAMIC_EXECUTION=1 was set, cannot eval")}if(!Module["load"]&&Module["read"]){Module["load"]=function load(f){globalEval(Module["read"](f))}}if(!Module["print"]){Module["print"]=(function(){})}if(!Module["printErr"]){Module["printErr"]=Module["print"]}if(!Module["arguments"]){Module["arguments"]=[]}if(!Module["thisProgram"]){Module["thisProgram"]="./this.program"}if(!Module["quit"]){Module["quit"]=(function(status,toThrow){throw toThrow})}Module.print=Module["print"];Module.printErr=Module["printErr"];Module["preRun"]=[];Module["postRun"]=[];for(var key in moduleOverrides){if(moduleOverrides.hasOwnProperty(key)){Module[key]=moduleOverrides[key]}}moduleOverrides=undefined;var Runtime={setTempRet0:(function(value){tempRet0=value;return value}),getTempRet0:(function(){return tempRet0}),stackSave:(function(){return STACKTOP}),stackRestore:(function(stackTop){STACKTOP=stackTop}),getNativeTypeSize:(function(type){switch(type){case"i1":case"i8":return 1;case"i16":return 2;case"i32":return 4;case"i64":return 8;case"float":return 4;case"double":return 8;default:{if(type[type.length-1]==="*"){return Runtime.QUANTUM_SIZE}else if(type[0]==="i"){var bits=parseInt(type.substr(1));assert(bits%8===0);return bits/8}else{return 0}}}}),getNativeFieldSize:(function(type){return Math.max(Runtime.getNativeTypeSize(type),Runtime.QUANTUM_SIZE)}),STACK_ALIGN:16,prepVararg:(function(ptr,type){if(type==="double"||type==="i64"){if(ptr&7){assert((ptr&7)===4);ptr+=4}}else{assert((ptr&3)===0)}return ptr}),getAlignSize:(function(type,size,vararg){if(!vararg&&(type=="i64"||type=="double"))return 8;if(!type)return Math.min(size,8);return Math.min(size||(type?Runtime.getNativeFieldSize(type):0),Runtime.QUANTUM_SIZE)}),dynCall:(function(sig,ptr,args){if(args&&args.length){return Module["dynCall_"+sig].apply(null,[ptr].concat(args))}else{return Module["dynCall_"+sig].call(null,ptr)}}),functionPointers:[null,null,null,null,null,null,null,null],addFunction:(function(func){for(var i=0;i<Runtime.functionPointers.length;i++){if(!Runtime.functionPointers[i]){Runtime.functionPointers[i]=func;return 1*(1+i)}}throw"Finished up all reserved function pointers. Use a higher value for RESERVED_FUNCTION_POINTERS."}),removeFunction:(function(index){Runtime.functionPointers[(index-1)/1]=null}),warnOnce:(function(text){if(!Runtime.warnOnce.shown)Runtime.warnOnce.shown={};if(!Runtime.warnOnce.shown[text]){Runtime.warnOnce.shown[text]=1;Module.printErr(text)}}),funcWrappers:{},getFuncWrapper:(function(func,sig){assert(sig);if(!Runtime.funcWrappers[sig]){Runtime.funcWrappers[sig]={}}var sigCache=Runtime.funcWrappers[sig];if(!sigCache[func]){if(sig.length===1){sigCache[func]=function dynCall_wrapper(){return Runtime.dynCall(sig,func)}}else if(sig.length===2){sigCache[func]=function dynCall_wrapper(arg){return Runtime.dynCall(sig,func,[arg])}}else{sigCache[func]=function dynCall_wrapper(){return Runtime.dynCall(sig,func,Array.prototype.slice.call(arguments))}}}return sigCache[func]}),getCompilerSetting:(function(name){throw"You must build with -s RETAIN_COMPILER_SETTINGS=1 for Runtime.getCompilerSetting or emscripten_get_compiler_setting to work"}),stackAlloc:(function(size){var ret=STACKTOP;STACKTOP=STACKTOP+size|0;STACKTOP=STACKTOP+15&-16;return ret}),staticAlloc:(function(size){var ret=STATICTOP;STATICTOP=STATICTOP+size|0;STATICTOP=STATICTOP+15&-16;return ret}),dynamicAlloc:(function(size){var ret=HEAP32[DYNAMICTOP_PTR>>2];var end=(ret+size+15|0)&-16;HEAP32[DYNAMICTOP_PTR>>2]=end;if(end>=TOTAL_MEMORY){var success=enlargeMemory();if(!success){HEAP32[DYNAMICTOP_PTR>>2]=ret;return 0}}return ret}),alignMemory:(function(size,quantum){var ret=size=Math.ceil(size/(quantum?quantum:16))*(quantum?quantum:16);return ret}),makeBigInt:(function(low,high,unsigned){var ret=unsigned?+(low>>>0)+ +(high>>>0)*+4294967296:+(low>>>0)+ +(high|0)*+4294967296;return ret}),GLOBAL_BASE:8,QUANTUM_SIZE:4,__dummy__:0};Module["Runtime"]=Runtime;var ABORT=0;var EXITSTATUS=0;function assert(condition,text){if(!condition){abort("Assertion failed: "+text)}}function getCFunc(ident){var func=Module["_"+ident];if(!func){abort("NO_DYNAMIC_EXECUTION=1 was set, cannot eval")}assert(func,"Cannot call unknown function "+ident+" (perhaps LLVM optimizations or closure removed it?)");return func}var cwrap,ccall;((function(){var JSfuncs={"stackSave":(function(){Runtime.stackSave()}),"stackRestore":(function(){Runtime.stackRestore()}),"arrayToC":(function(arr){var ret=Runtime.stackAlloc(arr.length);writeArrayToMemory(arr,ret);return ret}),"stringToC":(function(str){var ret=0;if(str!==null&&str!==undefined&&str!==0){var len=(str.length<<2)+1;ret=Runtime.stackAlloc(len);stringToUTF8(str,ret,len)}return ret})};var toC={"string":JSfuncs["stringToC"],"array":JSfuncs["arrayToC"]};ccall=function ccallFunc(ident,returnType,argTypes,args,opts){var func=getCFunc(ident);var cArgs=[];var stack=0;if(args){for(var i=0;i<args.length;i++){var converter=toC[argTypes[i]];if(converter){if(stack===0)stack=Runtime.stackSave();cArgs[i]=converter(args[i])}else{cArgs[i]=args[i]}}}var ret=func.apply(null,cArgs);if(returnType==="string")ret=Pointer_stringify(ret);if(stack!==0){if(opts&&opts.async){EmterpreterAsync.asyncFinalizers.push((function(){Runtime.stackRestore(stack)}));return}Runtime.stackRestore(stack)}return ret};cwrap=function cwrap(ident,returnType,argTypes){return(function(){return ccall(ident,returnType,argTypes,arguments)})}}))();Module["ccall"]=ccall;Module["cwrap"]=cwrap;function setValue(ptr,value,type,noSafe){type=type||"i8";if(type.charAt(type.length-1)==="*")type="i32";switch(type){case"i1":HEAP8[ptr>>0]=value;break;case"i8":HEAP8[ptr>>0]=value;break;case"i16":HEAP16[ptr>>1]=value;break;case"i32":HEAP32[ptr>>2]=value;break;case"i64":tempI64=[value>>>0,(tempDouble=value,+Math_abs(tempDouble)>=+1?tempDouble>+0?(Math_min(+Math_floor(tempDouble/+4294967296),+4294967295)|0)>>>0:~~+Math_ceil((tempDouble- +(~~tempDouble>>>0))/+4294967296)>>>0:0)],HEAP32[ptr>>2]=tempI64[0],HEAP32[ptr+4>>2]=tempI64[1];break;case"float":HEAPF32[ptr>>2]=value;break;case"double":HEAPF64[ptr>>3]=value;break;default:abort("invalid type for setValue: "+type)}}Module["setValue"]=setValue;function getValue(ptr,type,noSafe){type=type||"i8";if(type.charAt(type.length-1)==="*")type="i32";switch(type){case"i1":return HEAP8[ptr>>0];case"i8":return HEAP8[ptr>>0];case"i16":return HEAP16[ptr>>1];case"i32":return HEAP32[ptr>>2];case"i64":return HEAP32[ptr>>2];case"float":return HEAPF32[ptr>>2];case"double":return HEAPF64[ptr>>3];default:abort("invalid type for setValue: "+type)}return null}Module["getValue"]=getValue;var ALLOC_NORMAL=0;var ALLOC_STACK=1;var ALLOC_STATIC=2;var ALLOC_DYNAMIC=3;var ALLOC_NONE=4;Module["ALLOC_NORMAL"]=ALLOC_NORMAL;Module["ALLOC_STACK"]=ALLOC_STACK;Module["ALLOC_STATIC"]=ALLOC_STATIC;Module["ALLOC_DYNAMIC"]=ALLOC_DYNAMIC;Module["ALLOC_NONE"]=ALLOC_NONE;function allocate(slab,types,allocator,ptr){var zeroinit,size;if(typeof slab==="number"){zeroinit=true;size=slab}else{zeroinit=false;size=slab.length}var singleType=typeof types==="string"?types:null;var ret;if(allocator==ALLOC_NONE){ret=ptr}else{ret=[typeof _malloc==="function"?_malloc:Runtime.staticAlloc,Runtime.stackAlloc,Runtime.staticAlloc,Runtime.dynamicAlloc][allocator===undefined?ALLOC_STATIC:allocator](Math.max(size,singleType?1:types.length))}if(zeroinit){var ptr=ret,stop;assert((ret&3)==0);stop=ret+(size&~3);for(;ptr<stop;ptr+=4){HEAP32[ptr>>2]=0}stop=ret+size;while(ptr<stop){HEAP8[ptr++>>0]=0}return ret}if(singleType==="i8"){if(slab.subarray||slab.slice){HEAPU8.set(slab,ret)}else{HEAPU8.set(new Uint8Array(slab),ret)}return ret}var i=0,type,typeSize,previousType;while(i<size){var curr=slab[i];if(typeof curr==="function"){curr=Runtime.getFunctionIndex(curr)}type=singleType||types[i];if(type===0){i++;continue}if(type=="i64")type="i32";setValue(ret+i,curr,type);if(previousType!==type){typeSize=Runtime.getNativeTypeSize(type);previousType=type}i+=typeSize}return ret}Module["allocate"]=allocate;function getMemory(size){if(!staticSealed)return Runtime.staticAlloc(size);if(!runtimeInitialized)return Runtime.dynamicAlloc(size);return _malloc(size)}Module["getMemory"]=getMemory;function Pointer_stringify(ptr,length){if(length===0||!ptr)return"";var hasUtf=0;var t;var i=0;while(1){t=HEAPU8[ptr+i>>0];hasUtf|=t;if(t==0&&!length)break;i++;if(length&&i==length)break}if(!length)length=i;var ret="";if(hasUtf<128){var MAX_CHUNK=1024;var curr;while(length>0){curr=String.fromCharCode.apply(String,HEAPU8.subarray(ptr,ptr+Math.min(length,MAX_CHUNK)));ret=ret?ret+curr:curr;ptr+=MAX_CHUNK;length-=MAX_CHUNK}return ret}return Module["UTF8ToString"](ptr)}Module["Pointer_stringify"]=Pointer_stringify;function AsciiToString(ptr){var str="";while(1){var ch=HEAP8[ptr++>>0];if(!ch)return str;str+=String.fromCharCode(ch)}}Module["AsciiToString"]=AsciiToString;function stringToAscii(str,outPtr){return writeAsciiToMemory(str,outPtr,false)}Module["stringToAscii"]=stringToAscii;var UTF8Decoder=typeof TextDecoder!=="undefined"?new TextDecoder("utf8"):undefined;function UTF8ArrayToString(u8Array,idx){var endPtr=idx;while(u8Array[endPtr])++endPtr;if(endPtr-idx>16&&u8Array.subarray&&UTF8Decoder){return UTF8Decoder.decode(u8Array.subarray(idx,endPtr))}else{var u0,u1,u2,u3,u4,u5;var str="";while(1){u0=u8Array[idx++];if(!u0)return str;if(!(u0&128)){str+=String.fromCharCode(u0);continue}u1=u8Array[idx++]&63;if((u0&224)==192){str+=String.fromCharCode((u0&31)<<6|u1);continue}u2=u8Array[idx++]&63;if((u0&240)==224){u0=(u0&15)<<12|u1<<6|u2}else{u3=u8Array[idx++]&63;if((u0&248)==240){u0=(u0&7)<<18|u1<<12|u2<<6|u3}else{u4=u8Array[idx++]&63;if((u0&252)==248){u0=(u0&3)<<24|u1<<18|u2<<12|u3<<6|u4}else{u5=u8Array[idx++]&63;u0=(u0&1)<<30|u1<<24|u2<<18|u3<<12|u4<<6|u5}}}if(u0<65536){str+=String.fromCharCode(u0)}else{var ch=u0-65536;str+=String.fromCharCode(55296|ch>>10,56320|ch&1023)}}}}Module["UTF8ArrayToString"]=UTF8ArrayToString;function UTF8ToString(ptr){return UTF8ArrayToString(HEAPU8,ptr)}Module["UTF8ToString"]=UTF8ToString;function stringToUTF8Array(str,outU8Array,outIdx,maxBytesToWrite){if(!(maxBytesToWrite>0))return 0;var startIdx=outIdx;var endIdx=outIdx+maxBytesToWrite-1;for(var i=0;i<str.length;++i){var u=str.charCodeAt(i);if(u>=55296&&u<=57343)u=65536+((u&1023)<<10)|str.charCodeAt(++i)&1023;if(u<=127){if(outIdx>=endIdx)break;outU8Array[outIdx++]=u}else if(u<=2047){if(outIdx+1>=endIdx)break;outU8Array[outIdx++]=192|u>>6;outU8Array[outIdx++]=128|u&63}else if(u<=65535){if(outIdx+2>=endIdx)break;outU8Array[outIdx++]=224|u>>12;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else if(u<=2097151){if(outIdx+3>=endIdx)break;outU8Array[outIdx++]=240|u>>18;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else if(u<=67108863){if(outIdx+4>=endIdx)break;outU8Array[outIdx++]=248|u>>24;outU8Array[outIdx++]=128|u>>18&63;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else{if(outIdx+5>=endIdx)break;outU8Array[outIdx++]=252|u>>30;outU8Array[outIdx++]=128|u>>24&63;outU8Array[outIdx++]=128|u>>18&63;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}}outU8Array[outIdx]=0;return outIdx-startIdx}Module["stringToUTF8Array"]=stringToUTF8Array;function stringToUTF8(str,outPtr,maxBytesToWrite){return stringToUTF8Array(str,HEAPU8,outPtr,maxBytesToWrite)}Module["stringToUTF8"]=stringToUTF8;function lengthBytesUTF8(str){var len=0;for(var i=0;i<str.length;++i){var u=str.charCodeAt(i);if(u>=55296&&u<=57343)u=65536+((u&1023)<<10)|str.charCodeAt(++i)&1023;if(u<=127){++len}else if(u<=2047){len+=2}else if(u<=65535){len+=3}else if(u<=2097151){len+=4}else if(u<=67108863){len+=5}else{len+=6}}return len}Module["lengthBytesUTF8"]=lengthBytesUTF8;var UTF16Decoder=typeof TextDecoder!=="undefined"?new TextDecoder("utf-16le"):undefined;function demangle(func){var __cxa_demangle_func=Module["___cxa_demangle"]||Module["__cxa_demangle"];if(__cxa_demangle_func){try{var s=func.substr(1);var len=lengthBytesUTF8(s)+1;var buf=_malloc(len);stringToUTF8(s,buf,len);var status=_malloc(4);var ret=__cxa_demangle_func(buf,0,0,status);if(getValue(status,"i32")===0&&ret){return Pointer_stringify(ret)}}catch(e){}finally{if(buf)_free(buf);if(status)_free(status);if(ret)_free(ret)}return func}Runtime.warnOnce("warning: build with -s DEMANGLE_SUPPORT=1 to link in libcxxabi demangling");return func}function demangleAll(text){var regex=/__Z[\w\d_]+/g;return text.replace(regex,(function(x){var y=demangle(x);return x===y?x:x+" ["+y+"]"}))}function jsStackTrace(){var err=new Error;if(!err.stack){try{throw new Error(0)}catch(e){err=e}if(!err.stack){return"(no stack trace available)"}}return err.stack.toString()}function stackTrace(){var js=jsStackTrace();if(Module["extraStackTrace"])js+="\n"+Module["extraStackTrace"]();return demangleAll(js)}Module["stackTrace"]=stackTrace;var PAGE_SIZE=16384;var HEAP,buffer,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64;function updateGlobalBufferViews(){Module["HEAP8"]=HEAP8=new Int8Array(buffer);Module["HEAP16"]=HEAP16=new Int16Array(buffer);Module["HEAP32"]=HEAP32=new Int32Array(buffer);Module["HEAPU8"]=HEAPU8=new Uint8Array(buffer);Module["HEAPU16"]=HEAPU16=new Uint16Array(buffer);Module["HEAPU32"]=HEAPU32=new Uint32Array(buffer);Module["HEAPF32"]=HEAPF32=new Float32Array(buffer);Module["HEAPF64"]=HEAPF64=new Float64Array(buffer)}var STATIC_BASE,STATICTOP,staticSealed;var STACK_BASE,STACKTOP,STACK_MAX;var DYNAMIC_BASE,DYNAMICTOP_PTR;STATIC_BASE=STATICTOP=STACK_BASE=STACKTOP=STACK_MAX=DYNAMIC_BASE=DYNAMICTOP_PTR=0;staticSealed=false;function abortOnCannotGrowMemory(){abort("Cannot enlarge memory arrays. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value "+TOTAL_MEMORY+", (2) compile with -s ALLOW_MEMORY_GROWTH=1 which allows increasing the size at runtime but prevents some optimizations, (3) set Module.TOTAL_MEMORY to a higher value before the program runs, or (4) if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 ")}function enlargeMemory(){abortOnCannotGrowMemory()}var TOTAL_STACK=Module["TOTAL_STACK"]||5242880;var TOTAL_MEMORY=Module["TOTAL_MEMORY"]||67108864;if(TOTAL_MEMORY<TOTAL_STACK)Module.printErr("TOTAL_MEMORY should be larger than TOTAL_STACK, was "+TOTAL_MEMORY+"! (TOTAL_STACK="+TOTAL_STACK+")");if(Module["buffer"]){buffer=Module["buffer"]}else{{buffer=new ArrayBuffer(TOTAL_MEMORY)}}updateGlobalBufferViews();function getTotalMemory(){return TOTAL_MEMORY}HEAP32[0]=1668509029;HEAP16[1]=25459;if(HEAPU8[2]!==115||HEAPU8[3]!==99)throw"Runtime error: expected the system to be little-endian!";Module["HEAP"]=HEAP;Module["buffer"]=buffer;Module["HEAP8"]=HEAP8;Module["HEAP16"]=HEAP16;Module["HEAP32"]=HEAP32;Module["HEAPU8"]=HEAPU8;Module["HEAPU16"]=HEAPU16;Module["HEAPU32"]=HEAPU32;Module["HEAPF32"]=HEAPF32;Module["HEAPF64"]=HEAPF64;function callRuntimeCallbacks(callbacks){while(callbacks.length>0){var callback=callbacks.shift();if(typeof callback=="function"){callback();continue}var func=callback.func;if(typeof func==="number"){if(callback.arg===undefined){Module["dynCall_v"](func)}else{Module["dynCall_vi"](func,callback.arg)}}else{func(callback.arg===undefined?null:callback.arg)}}}var __ATPRERUN__=[];var __ATINIT__=[];var __ATMAIN__=[];var __ATEXIT__=[];var __ATPOSTRUN__=[];var runtimeInitialized=false;var runtimeExited=false;function preRun(){if(Module["preRun"]){if(typeof Module["preRun"]=="function")Module["preRun"]=[Module["preRun"]];while(Module["preRun"].length){addOnPreRun(Module["preRun"].shift())}}callRuntimeCallbacks(__ATPRERUN__)}function ensureInitRuntime(){if(runtimeInitialized)return;runtimeInitialized=true;callRuntimeCallbacks(__ATINIT__)}function preMain(){callRuntimeCallbacks(__ATMAIN__)}function exitRuntime(){callRuntimeCallbacks(__ATEXIT__);runtimeExited=true}function postRun(){if(Module["postRun"]){if(typeof Module["postRun"]=="function")Module["postRun"]=[Module["postRun"]];while(Module["postRun"].length){addOnPostRun(Module["postRun"].shift())}}callRuntimeCallbacks(__ATPOSTRUN__)}function addOnPreRun(cb){__ATPRERUN__.unshift(cb)}Module["addOnPreRun"]=addOnPreRun;function addOnInit(cb){__ATINIT__.unshift(cb)}Module["addOnInit"]=addOnInit;function addOnPreMain(cb){__ATMAIN__.unshift(cb)}Module["addOnPreMain"]=addOnPreMain;function addOnExit(cb){__ATEXIT__.unshift(cb)}Module["addOnExit"]=addOnExit;function addOnPostRun(cb){__ATPOSTRUN__.unshift(cb)}Module["addOnPostRun"]=addOnPostRun;function intArrayFromString(stringy,dontAddNull,length){var len=length>0?length:lengthBytesUTF8(stringy)+1;var u8array=new Array(len);var numBytesWritten=stringToUTF8Array(stringy,u8array,0,u8array.length);if(dontAddNull)u8array.length=numBytesWritten;return u8array}Module["intArrayFromString"]=intArrayFromString;function intArrayToString(array){var ret=[];for(var i=0;i<array.length;i++){var chr=array[i];if(chr>255){chr&=255}ret.push(String.fromCharCode(chr))}return ret.join("")}Module["intArrayToString"]=intArrayToString;function writeStringToMemory(string,buffer,dontAddNull){Runtime.warnOnce("writeStringToMemory is deprecated and should not be called! Use stringToUTF8() instead!");var lastChar,end;if(dontAddNull){end=buffer+lengthBytesUTF8(string);lastChar=HEAP8[end]}stringToUTF8(string,buffer,Infinity);if(dontAddNull)HEAP8[end]=lastChar}Module["writeStringToMemory"]=writeStringToMemory;function writeArrayToMemory(array,buffer){HEAP8.set(array,buffer)}Module["writeArrayToMemory"]=writeArrayToMemory;function writeAsciiToMemory(str,buffer,dontAddNull){for(var i=0;i<str.length;++i){HEAP8[buffer++>>0]=str.charCodeAt(i)}if(!dontAddNull)HEAP8[buffer>>0]=0}Module["writeAsciiToMemory"]=writeAsciiToMemory;if(!Math["imul"]||Math["imul"](4294967295,5)!==-5)Math["imul"]=function imul(a,b){var ah=a>>>16;var al=a&65535;var bh=b>>>16;var bl=b&65535;return al*bl+(ah*bl+al*bh<<16)|0};Math.imul=Math["imul"];if(!Math["clz32"])Math["clz32"]=(function(x){x=x>>>0;for(var i=0;i<32;i++){if(x&1<<31-i)return i}return 32});Math.clz32=Math["clz32"];if(!Math["trunc"])Math["trunc"]=(function(x){return x<0?Math.ceil(x):Math.floor(x)});Math.trunc=Math["trunc"];var Math_abs=Math.abs;var Math_cos=Math.cos;var Math_sin=Math.sin;var Math_tan=Math.tan;var Math_acos=Math.acos;var Math_asin=Math.asin;var Math_atan=Math.atan;var Math_atan2=Math.atan2;var Math_exp=Math.exp;var Math_log=Math.log;var Math_sqrt=Math.sqrt;var Math_ceil=Math.ceil;var Math_floor=Math.floor;var Math_pow=Math.pow;var Math_imul=Math.imul;var Math_fround=Math.fround;var Math_round=Math.round;var Math_min=Math.min;var Math_clz32=Math.clz32;var Math_trunc=Math.trunc;var runDependencies=0;var runDependencyWatcher=null;var dependenciesFulfilled=null;function addRunDependency(id){runDependencies++;if(Module["monitorRunDependencies"]){Module["monitorRunDependencies"](runDependencies)}}Module["addRunDependency"]=addRunDependency;function removeRunDependency(id){runDependencies--;if(Module["monitorRunDependencies"]){Module["monitorRunDependencies"](runDependencies)}if(runDependencies==0){if(runDependencyWatcher!==null){clearInterval(runDependencyWatcher);runDependencyWatcher=null}if(dependenciesFulfilled){var callback=dependenciesFulfilled;dependenciesFulfilled=null;callback()}}}Module["removeRunDependency"]=removeRunDependency;Module["preloadedImages"]={};Module["preloadedAudios"]={};var ASM_CONSTS=[(function(){{return Module.getRandomValue()}}),(function(){{if(Module.getRandomValue===undefined){try{var window_="object"===typeof window?window:self,crypto_=typeof window_.crypto!=="undefined"?window_.crypto:window_.msCrypto,randomValuesStandard=(function(){var buf=new Uint32Array(1);crypto_.getRandomValues(buf);return buf[0]>>>0});randomValuesStandard();Module.getRandomValue=randomValuesStandard}catch(e){try{var crypto=__webpack_require__(419),randomValueNodeJS=(function(){var buf=crypto.randomBytes(4);return(buf[0]<<24|buf[1]<<16|buf[2]<<8|buf[3])>>>0});randomValueNodeJS();Module.getRandomValue=randomValueNodeJS}catch(e){throw"No secure random number generator found"}}}}})];function _emscripten_asm_const_i(code){return ASM_CONSTS[code]()}function _emscripten_asm_const_v(code){return ASM_CONSTS[code]()}STATIC_BASE=Runtime.GLOBAL_BASE;STATICTOP=STATIC_BASE+36e3;__ATINIT__.push();allocate([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,38,232,149,143,194,178,39,176,69,195,244,137,242,239,152,240,213,223,172,5,211,198,51,57,177,56,2,136,109,83,252,5,199,23,106,112,61,77,216,79,186,60,11,118,13,16,103,15,42,32,83,250,44,57,204,198,78,199,253,119,146,172,3,122,19,232,149,143,194,178,39,176,69,195,244,137,242,239,152,240,213,223,172,5,211,198,51,57,177,56,2,136,109,83,252,133,180,23,106,112,61,77,216,79,186,60,11,118,13,16,103,15,42,32,83,250,44,57,204,198,78,199,253,119,146,172,3,250,236,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,237,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,238,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,217,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,218,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,219,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,8,201,188,243,103,230,9,106,59,167,202,132,133,174,103,187,43,248,148,254,114,243,110,60,241,54,29,95,58,245,79,165,209,130,230,173,127,82,14,81,31,108,62,43,140,104,5,155,107,189,65,251,171,217,131,31,121,33,126,19,25,205,224,91,34,174,40,215,152,47,138,66,205,101,239,35,145,68,55,113,47,59,77,236,207,251,192,181,188,219,137,129,165,219,181,233,56,181,72,243,91,194,86,57,25,208,5,182,241,17,241,89,155,79,25,175,164,130,63,146,24,129,109,218,213,94,28,171,66,2,3,163,152,170,7,216,190,111,112,69,1,91,131,18,140,178,228,78,190,133,49,36,226,180,255,213,195,125,12,85,111,137,123,242,116,93,190,114,177,150,22,59,254,177,222,128,53,18,199,37,167,6,220,155,148,38,105,207,116,241,155,193,210,74,241,158,193,105,155,228,227,37,79,56,134,71,190,239,181,213,140,139,198,157,193,15,101,156,172,119,204,161,12,36,117,2,43,89,111,44,233,45,131,228,166,110,170,132,116,74,212,251,65,189,220,169,176,92,181,83,17,131,218,136,249,118,171,223,102,238,82,81,62,152,16,50,180,45,109,198,49,168,63,33,251,152,200,39,3,176,228,14,239,190,199,127,89,191,194,143,168,61,243,11,224,198,37,167,10,147,71,145,167,213,111,130,3,224,81,99,202,6,112,110,14,10,103,41,41,20,252,47,210,70,133,10,183,39,38,201,38,92,56,33,27,46,237,42,196,90,252,109,44,77,223,179,149,157,19,13,56,83,222,99,175,139,84,115,10,101,168,178,119,60,187,10,106,118,230,174,237,71,46,201,194,129,59,53,130,20,133,44,114,146,100,3,241,76,161,232,191,162,1,48,66,188,75,102,26,168,145,151,248,208,112,139,75,194,48,190,84,6,163,81,108,199,24,82,239,214,25,232,146,209,16,169,101,85,36,6,153,214,42,32,113,87,133,53,14,244,184,209,187,50,112,160,106,16,200,208,210,184,22,193,164,25,83,171,65,81,8,108,55,30,153,235,142,223,76,119,72,39,168,72,155,225,181,188,176,52,99,90,201,197,179,12,28,57,203,138,65,227,74,170,216,78,115,227,99,119,79,202,156,91,163,184,178,214,243,111,46,104,252,178,239,93,238,130,143,116,96,47,23,67,111,99,165,120,114,171,240,161,20,120,200,132,236,57,100,26,8,2,199,140,40,30,99,35,250,255,190,144,233,189,130,222,235,108,80,164,21,121,198,178,247,163,249,190,43,83,114,227,242,120,113,198,156,97,38,234,206,62,39,202,7,194,192,33,199,184,134,209,30,235,224,205,214,125,218,234,120,209,110,238,127,79,125,245,186,111,23,114,170,103,240,6,166,152,200,162,197,125,99,10,174,13,249,190,4,152,63,17,27,71,28,19,53,11,113,27,132,125,4,35,245,119,219,40,147,36,199,64,123,171,202,50,188,190,201,21,10,190,158,60,76,13,16,156,196,103,29,67,182,66,62,203,190,212,197,76,42,126,101,252,156,41,127,89,236,250,214,58,171,111,203,95,23,88,71,74,140,25,68,108,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,51,51,51,51,51,51,51,51,51,51,51,51,51,51,51,51,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,182,120,89,255,133,114,211,0,189,110,21,255,15,10,106,0,41,192,1,0,152,232,121,255,188,60,160,255,153,113,206,255,0,183,226,254,180,13,72,255,176,160,14,254,211,201,134,255,158,24,143,0,127,105,53,0,96,12,189,0,167,215,251,255,159,76,128,254,106,101,225,255,30,252,4,0,146,12,174,0,89,241,178,254,10,229,166,255,123,221,42,254,30,20,212,0,82,128,3,0,48,209,243,0,119,121,64,255,50,227,156,255,0,110,197,1,103,27,144,0,133,59,140,1,189,241,36,255,248,37,195,1,96,220,55,0,183,76,62,255,195,66,61,0,50,76,164,1,225,164,76,255,76,61,163,255,117,62,31,0,81,145,64,255,118,65,14,0,162,115,214,255,6,138,46,0,124,230,244,255,10,138,143,0,52,26,194,0,184,244,76,0,129,143,41,1,190,244,19,255,123,170,122,255,98,129,68,0,121,213,147,0,86,101,30,255,161,103,155,0,140,89,67,255,239,229,190,1,67,11,181,0,198,240,137,254,238,69,188,255,67,151,238,0,19,42,108,255,229,85,113,1,50,68,135,255,17,106,9,0,50,103,1,255,80,1,168,1,35,152,30,255,16,168,185,1,56,89,232,255,101,210,252,0,41,250,71,0,204,170,79,255,14,46,239,255,80,77,239,0,189,214,75,255,17,141,249,0,38,80,76,255,190,85,117,0,86,228,170,0,156,216,208,1,195,207,164,255,150,66,76,255,175,225,16,255,141,80,98,1,76,219,242,0,198,162,114,0,46,218,152,0,155,43,241,254,155,160,104,255,51,187,165,0,2,17,175,0,66,84,160,1,247,58,30,0,35,65,53,254,69,236,191,0,45,134,245,1,163,123,221,0,32,110,20,255,52,23,165,0,186,214,71,0,233,176,96,0,242,239,54,1,57,89,138,0,83,0,84,255,136,160,100,0,92,142,120,254,104,124,190,0,181,177,62,255,250,41,85,0,152,130,42,1,96,252,246,0,151,151,63,254,239,133,62,0,32,56,156,0,45,167,189,255,142,133,179,1,131,86,211,0,187,179,150,254,250,170,14,255,210,163,78,0,37,52,151,0,99,77,26,0,238,156,213,255,213,192,209,1,73,46,84,0,20,65,41,1,54,206,79,0,201,131,146,254,170,111,24,255,177,33,50,254,171,38,203,255,78,247,116,0,209,221,153,0,133,128,178,1,58,44,25,0,201,39,59,1,189,19,252,0,49,229,210,1,117,187,117,0,181,179,184,1,0,114,219,0,48,94,147,0,245,41,56,0,125,13,204,254,244,173,119,0,44,221,32,254,84,234,20,0,249,160,198,1,236,126,234,255,47,99,168,254,170,226,153,255,102,179,216,0,226,141,122,255,122,66,153,254,182,245,134,0,227,228,25,1,214,57,235,255,216,173,56,255,181,231,210,0,119,128,157,255,129,95,136,255,110,126,51,0,2,169,183,255,7,130,98,254,69,176,94,255,116,4,227,1,217,242,145,255,202,173,31,1,105,1,39,255,46,175,69,0,228,47,58,255,215,224,69,254,207,56,69,255,16,254,139,255,23,207,212,255,202,20,126,255,95,213,96,255,9,176,33,0,200,5,207,255,241,42,128,254,35,33,192,255,248,229,196,1,129,17,120,0,251,103,151,255,7,52,112,255,140,56,66,255,40,226,245,255,217,70,37,254,172,214,9,255,72,67,134,1,146,192,214,255,44,38,112,0,68,184,75,255,206,90,251,0,149,235,141,0,181,170,58,0,116,244,239,0,92,157,2,0,102,173,98,0,233,137,96,1,127,49,203,0,5,155,148,0,23,148,9,255,211,122,12,0,34,134,26,255,219,204,136,0,134,8,41,255,224,83,43,254,85,25,247,0,109,127,0,254,169,136,48,0,238,119,219,255,231,173,213,0,206,18,254,254,8,186,7,255,126,9,7,1,111,42,72,0,111,52,236,254,96,63,141,0,147,191,127,254,205,78,192,255,14,106,237,1,187,219,76,0,175,243,187,254,105,89,173,0,85,25,89,1,162,243,148,0,2,118,209,254,33,158,9,0,139,163,46,255,93,70,40,0,108,42,142,254,111,252,142,255,155,223,144,0,51,229,167,255,73,252,155,255,94,116,12,255,152,160,218,255,156,238,37,255,179,234,207,255,197,0,179,255,154,164,141,0,225,196,104,0,10,35,25,254,209,212,242,255,97,253,222,254,184,101,229,0,222,18,127,1,164,136,135,255,30,207,140,254,146,97,243,0,129,192,26,254,201,84,33,255,111,10,78,255,147,81,178,255,4,4,24,0,161,238,215,255,6,141,33,0,53,215,14,255,41,181,208,255,231,139,157,0,179,203,221,255,255,185,113,0,189,226,172,255,113,66,214,255,202,62,45,255,102,64,8,255,78,174,16,254,133,117,68,255,133,59,140,1,189,241,36,255,248,37,195,1,96,220,55,0,183,76,62,255,195,66,61,0,50,76,164,1,225,164,76,255,76,61,163,255,117,62,31,0,81,145,64,255,118,65,14,0,162,115,214,255,6,138,46,0,124,230,244,255,10,138,143,0,52,26,194,0,184,244,76,0,129,143,41,1,190,244,19,255,123,170,122,255,98,129,68,0,121,213,147,0,86,101,30,255,161,103,155,0,140,89,67,255,239,229,190,1,67,11,181,0,198,240,137,254,238,69,188,255,234,113,60,255,37,255,57,255,69,178,182,254,128,208,179,0,118,26,125,254,3,7,214,255,241,50,77,255,85,203,197,255,211,135,250,255,25,48,100,255,187,213,180,254,17,88,105,0,83,209,158,1,5,115,98,0,4,174,60,254,171,55,110,255,217,181,17,255,20,188,170,0,146,156,102,254,87,214,174,255,114,122,155,1,233,44,170,0,127,8,239,1,214,236,234,0,175,5,219,0,49,106,61,255,6,66,208,255,2,106,110,255,81,234,19,255,215,107,192,255,67,151,238,0,19,42,108,255,229,85,113,1,50,68,135,255,17,106,9,0,50,103,1,255,80,1,168,1,35,152,30,255,16,168,185,1,56,89,232,255,101,210,252,0,41,250,71,0,204,170,79,255,14,46,239,255,80,77,239,0,189,214,75,255,17,141,249,0,38,80,76,255,190,85,117,0,86,228,170,0,156,216,208,1,195,207,164,255,150,66,76,255,175,225,16,255,141,80,98,1,76,219,242,0,198,162,114,0,46,218,152,0,155,43,241,254,155,160,104,255,178,9,252,254,100,110,212,0,14,5,167,0,233,239,163,255,28,151,157,1,101,146,10,255,254,158,70,254,71,249,228,0,88,30,50,0,68,58,160,255,191,24,104,1,129,66,129,255,192,50,85,255,8,179,138,255,38,250,201,0,115,80,160,0,131,230,113,0,125,88,147,0,90,68,199,0,253,76,158,0,28,255,118,0,113,250,254,0,66,75,46,0,230,218,43,0,229,120,186,1,148,68,43,0,136,124,238,1,187,107,197,255,84,53,246,255,51,116,254,255,51,187,165,0,2,17,175,0,66,84,160,1,247,58,30,0,35,65,53,254,69,236,191,0,45,134,245,1,163,123,221,0,32,110,20,255,52,23,165,0,186,214,71,0,233,176,96,0,242,239,54,1,57,89,138,0,83,0,84,255,136,160,100,0,92,142,120,254,104,124,190,0,181,177,62,255,250,41,85,0,152,130,42,1,96,252,246,0,151,151,63,254,239,133,62,0,32,56,156,0,45,167,189,255,142,133,179,1,131,86,211,0,187,179,150,254,250,170,14,255,68,113,21,255,222,186,59,255,66,7,241,1,69,6,72,0,86,156,108,254,55,167,89,0,109,52,219,254,13,176,23,255,196,44,106,255,239,149,71,255,164,140,125,255,159,173,1,0,51,41,231,0,145,62,33,0,138,111,93,1,185,83,69,0,144,115,46,0,97,151,16,255,24,228,26,0,49,217,226,0,113,75,234,254,193,153,12,255,182,48,96,255,14,13,26,0,128,195,249,254,69,193,59,0,132,37,81,254,125,106,60,0,214,240,169,1,164,227,66,0,210,163,78,0,37,52,151,0,99,77,26,0,238,156,213,255,213,192,209,1,73,46,84,0,20,65,41,1,54,206,79,0,201,131,146,254,170,111,24,255,177,33,50,254,171,38,203,255,78,247,116,0,209,221,153,0,133,128,178,1,58,44,25,0,201,39,59,1,189,19,252,0,49,229,210,1,117,187,117,0,181,179,184,1,0,114,219,0,48,94,147,0,245,41,56,0,125,13,204,254,244,173,119,0,44,221,32,254,84,234,20,0,249,160,198,1,236,126,234,255,143,62,221,0,129,89,214,255,55,139,5,254,68,20,191,255,14,204,178,1,35,195,217,0,47,51,206,1,38,246,165,0,206,27,6,254,158,87,36,0,217,52,146,255,125,123,215,255,85,60,31,255,171,13,7,0,218,245,88,254,252,35,60,0,55,214,160,255,133,101,56,0,224,32,19,254,147,64,234,0,26,145,162,1,114,118,125,0,248,252,250,0,101,94,196,255,198,141,226,254,51,42,182,0,135,12,9,254,109,172,210,255,197,236,194,1,241,65,154,0,48,156,47,255,153,67,55,255,218,165,34,254,74,180,179,0,218,66,71,1,88,122,99,0,212,181,219,255,92,42,231,255,239,0,154,0,245,77,183,255,94,81,170,1,18,213,216,0,171,93,71,0,52,94,248,0,18,151,161,254,197,209,66,255,174,244,15,254,162,48,183,0,49,61,240,254,182,93,195,0,199,228,6,1,200,5,17,255,137,45,237,255,108,148,4,0,90,79,237,255,39,63,77,255,53,82,207,1,142,22,118,255,101,232,18,1,92,26,67,0,5,200,88,255,33,168,138,255,149,225,72,0,2,209,27,255,44,245,168,1,220,237,17,255,30,211,105,254,141,238,221,0,128,80,245,254,111,254,14,0,222,95,190,1,223,9,241,0,146,76,212,255,108,205,104,255,63,117,153,0,144,69,48,0,35,228,111,0,192,33,193,255,112,214,190,254,115,152,151,0,23,102,88,0,51,74,248,0,226,199,143,254,204,162,101,255,208,97,189,1,245,104,18,0,230,246,30,255,23,148,69,0,110,88,52,254,226,181,89,255,208,47,90,254,114,161,80,255,33,116,248,0,179,152,87,255,69,144,177,1,88,238,26,255,58,32,113,1,1,77,69,0,59,121,52,255,152,238,83,0,52,8,193,0,231,39,233,255,199,34,138,0,222,68,173,0,91,57,242,254,220,210,127,255,192,7,246,254,151,35,187,0,195,236,165,0,111,93,206,0,212,247,133,1,154,133,209,255,155,231,10,0,64,78,38,0,122,249,100,1,30,19,97,255,62,91,249,1,248,133,77,0,197,63,168,254,116,10,82,0,184,236,113,254,212,203,194,255,61,100,252,254,36,5,202,255,119,91,153,255,129,79,29,0,103,103,171,254,237,215,111,255,216,53,69,0,239,240,23,0,194,149,221,255,38,225,222,0,232,255,180,254,118,82,133,255,57,209,177,1,139,232,133,0,158,176,46,254,194,115,46,0,88,247,229,1,28,103,191,0,221,222,175,254,149,235,44,0,151,228,25,254,218,105,103,0,142,85,210,0,149,129,190,255,213,65,94,254,117,134,224,255,82,198,117,0,157,221,220,0,163,101,36,0,197,114,37,0,104,172,166,254,11,182,0,0,81,72,188,255,97,188,16,255,69,6,10,0,199,147,145,255,8,9,115,1,65,214,175,255,217,173,209,0,80,127,166,0,247,229,4,254,167,183,124,255,90,28,204,254,175,59,240,255,11,41,248,1,108,40,51,255,144,177,195,254,150,250,126,0,138,91,65,1,120,60,222,255,245,193,239,0,29,214,189,255,128,2,25,0,80,154,162,0,77,220,107,1,234,205,74,255,54,166,103,255,116,72,9,0,228,94,47,255,30,200,25,255,35,214,89,255,61,176,140,255,83,226,163,255,75,130,172,0,128,38,17,0,95,137,152,255,215,124,159,1,79,93,0,0,148,82,157,254,195,130,251,255,40,202,76,255,251,126,224,0,157,99,62,254,207,7,225,255,96,68,195,0,140,186,157,255,131,19,231,255,42,128,254,0,52,219,61,254,102,203,72,0,141,7,11,255,186,164,213,0,31,122,119,0,133,242,145,0,208,252,232,255,91,213,182,255,143,4,250,254,249,215,74,0,165,30,111,1,171,9,223,0,229,123,34,1,92,130,26,255,77,155,45,1,195,139,28,255,59,224,78,0,136,17,247,0,108,121,32,0,79,250,189,255,96,227,252,254,38,241,62,0,62,174,125,255,155,111,93,255,10,230,206,1,97,197,40,255,0,49,57,254,65,250,13,0,18,251,150,255,220,109,210,255,5,174,166,254,44,129,189,0,235,35,147,255,37,247,141,255,72,141,4,255,103,107,255,0,247,90,4,0,53,44,42,0,2,30,240,0,4,59,63,0,88,78,36,0,113,167,180,0,190,71,193,255,199,158,164,255,58,8,172,0,77,33,12,0,65,63,3,0,153,77,33,255,172,254,102,1,228,221,4,255,87,30,254,1,146,41,86,255,138,204,239,254,108,141,17,255,187,242,135,0,210,208,127,0,68,45,14,254,73,96,62,0,81,60,24,255,170,6,36,255,3,249,26,0,35,213,109,0,22,129,54,255,21,35,225,255,234,61,56,255,58,217,6,0,143,124,88,0,236,126,66,0,209,38,183,255,34,238,6,255,174,145,102,0,95,22,211,0,196,15,153,254,46,84,232,255,117,34,146,1,231,250,74,255,27,134,100,1,92,187,195,255,170,198,112,0,120,28,42,0,209,70,67,0,29,81,31,0,29,168,100,1,169,173,160,0,107,35,117,0,62,96,59,255,81,12,69,1,135,239,190,255,220,252,18,0,163,220,58,255,137,137,188,255,83,102,109,0,96,6,76,0,234,222,210,255,185,174,205,1,60,158,213,255,13,241,214,0,172,129,140,0,93,104,242,0,192,156,251,0,43,117,30,0,225,81,158,0,127,232,218,0,226,28,203,0,233,27,151,255,117,43,5,255,242,14,47,255,33,20,6,0,137,251,44,254,27,31,245,255,183,214,125,254,40,121,149,0,186,158,213,255,89,8,227,0,69,88,0,254,203,135,225,0,201,174,203,0,147,71,184,0,18,121,41,254,94,5,78,0,224,214,240,254,36,5,180,0,251,135,231,1,163,138,212,0,210,249,116,254,88,129,187,0,19,8,49,254,62,14,144,255,159,76,211,0,214,51,82,0,109,117,228,254,103,223,203,255,75,252,15,1,154,71,220,255,23,13,91,1,141,168,96,255,181,182,133,0,250,51,55,0,234,234,212,254,175,63,158,0,39,240,52,1,158,189,36,255,213,40,85,1,32,180,247,255,19,102,26,1,84,24,97,255,69,21,222,0,148,139,122,255,220,213,235,1,232,203,255,0,121,57,147,0,227,7,154,0,53,22,147,1,72,1,225,0,82,134,48,254,83,60,157,255,145,72,169,0,34,103,239,0,198,233,47,0,116,19,4,255,184,106,9,255,183,129,83,0,36,176,230,1,34,103,72,0,219,162,134,0,245,42,158,0,32,149,96,254,165,44,144,0,202,239,72,254,215,150,5,0,42,66,36,1,132,215,175,0,86,174,86,255,26,197,156,255,49,232,135,254,103,182,82,0,253,128,176,1,153,178,122,0,245,250,10,0,236,24,178,0,137,106,132,0,40,29,41,0,50,30,152,255,124,105,38,0,230,191,75,0,143,43,170,0,44,131,20,255,44,13,23,255,237,255,155,1,159,109,100,255,112,181,24,255,104,220,108,0,55,211,131,0,99,12,213,255,152,151,145,255,238,5,159,0,97,155,8,0,33,108,81,0,1,3,103,0,62,109,34,255,250,155,180,0,32,71,195,255,38,70,145,1,159,95,245,0,69,229,101,1,136,28,240,0,79,224,25,0,78,110,121,255,248,168,124,0,187,128,247,0,2,147,235,254,79,11,132,0,70,58,12,1,181,8,163,255,79,137,133,255,37,170,11,255,141,243,85,255,176,231,215,255,204,150,164,255,239,215,39,255,46,87,156,254,8,163,88,255,172,34,232,0,66,44,102,255,27,54,41,254,236,99,87,255,41,123,169,1,52,114,43,0,117,134,40,0,155,134,26,0,231,207,91,254,35,132,38,255,19,102,125,254,36,227,133,255,118,3,113,255,29,13,124,0,152,96,74,1,88,146,206,255,167,191,220,254,162,18,88,255,182,100,23,0,31,117,52,0,81,46,106,1,12,2,7,0,69,80,201,1,209,246,172,0,12,48,141,1,224,211,88,0,116,226,159,0,122,98,130,0,65,236,234,1,225,226,9,255,207,226,123,1,89,214,59,0,112,135,88,1,90,244,203,255,49,11,38,1,129,108,186,0,89,112,15,1,101,46,204,255,127,204,45,254,79,255,221,255,51,73,18,255,127,42,101,255,241,21,202,0,160,227,7,0,105,50,236,0,79,52,197,255,104,202,208,1,180,15,16,0,101,197,78,255,98,77,203,0,41,185,241,1,35,193,124,0,35,155,23,255,207,53,192,0,11,125,163,1,249,158,185,255,4,131,48,0,21,93,111,255,61,121,231,1,69,200,36,255,185,48,185,255,111,238,21,255,39,50,25,255,99,215,163,255,87,212,30,255,164,147,5,255,128,6,35,1,108,223,110,255,194,76,178,0,74,101,180,0,243,47,48,0,174,25,43,255,82,173,253,1,54,114,192,255,40,55,91,0,215,108,176,255,11,56,7,0,224,233,76,0,209,98,202,254,242,25,125,0,44,193,93,254,203,8,177,0,135,176,19,0,112,71,213,255,206,59,176,1,4,67,26,0,14,143,213,254,42,55,208,255,60,67,120,0,193,21,163,0,99,164,115,0,10,20,118,0,156,212,222,254,160,7,217,255,114,245,76,1,117,59,123,0,176,194,86,254,213,15,176,0,78,206,207,254,213,129,59,0,233,251,22,1,96,55,152,255,236,255,15,255,197,89,84,255,93,149,133,0,174,160,113,0,234,99,169,255,152,116,88,0,144,164,83,255,95,29,198,255,34,47,15,255,99,120,134,255,5,236,193,0,249,247,126,255,147,187,30,0,50,230,117,255,108,217,219,255,163,81,166,255,72,25,169,254,155,121,79,255,28,155,89,254,7,126,17,0,147,65,33,1,47,234,253,0,26,51,18,0,105,83,199,255,163,196,230,0,113,248,164,0,226,254,218,0,189,209,203,255,164,247,222,254,255,35,165,0,4,188,243,1,127,179,71,0,37,237,254,255,100,186,240,0,5,57,71,254,103,72,73,255,244,18,81,254,229,210,132,255,238,6,180,255,11,229,174,255,227,221,192,1,17,49,28,0,163,215,196,254,9,118,4,255,51,240,71,0,113,129,109,255,76,240,231,0,188,177,127,0,125,71,44,1,26,175,243,0,94,169,25,254,27,230,29,0,15,139,119,1,168,170,186,255,172,197,76,255,252,75,188,0,137,124,196,0,72,22,96,255,45,151,249,1,220,145,100,0,64,192,159,255,120,239,226,0,129,178,146,0,0,192,125,0,235,138,234,0,183,157,146,0,83,199,192,255,184,172,72,255,73,225,128,0,77,6,250,255,186,65,67,0,104,246,207,0,188,32,138,255,218,24,242,0,67,138,81,254,237,129,121,255,20,207,150,1,41,199,16,255,6,20,128,0,159,118,5,0,181,16,143,255,220,38,15,0,23,64,147,254,73,26,13,0,87,228,57,1,204,124,128,0,43,24,223,0,219,99,199,0,22,75,20,255,19,27,126,0,157,62,215,0,110,29,230,0,179,167,255,1,54,252,190,0,221,204,182,254,179,158,65,255,81,157,3,0,194,218,159,0,170,223,0,0,224,11,32,255,38,197,98,0,168,164,37,0,23,88,7,1,164,186,110,0,96,36,134,0,234,242,229,0,250,121,19,0,242,254,112,255,3,47,94,1,9,239,6,255,81,134,153,254,214,253,168,255,67,124,224,0,245,95,74,0,28,30,44,254,1,109,220,255,178,89,89,0,252,36,76,0,24,198,46,255,76,77,111,0,134,234,136,255,39,94,29,0,185,72,234,255,70,68,135,255,231,102,7,254,77,231,140,0,167,47,58,1,148,97,118,255,16,27,225,1,166,206,143,255,110,178,214,255,180,131,162,0,143,141,225,1,13,218,78,255,114,153,33,1,98,104,204,0,175,114,117,1,167,206,75,0,202,196,83,1,58,64,67,0,138,47,111,1,196,247,128,255,137,224,224,254,158,112,207,0,154,100,255,1,134,37,107,0,198,128,79,255,127,209,155,255,163,254,185,254,60,14,243,0,31,219,112,254,29,217,65,0,200,13,116,254,123,60,196,255,224,59,184,254,242,89,196,0,123,16,75,254,149,16,206,0,69,254,48,1,231,116,223,255,209,160,65,1,200,80,98,0,37,194,184,254,148,63,34,0,139,240,65,255,217,144,132,255,56,38,45,254,199,120,210,0,108,177,166,255,160,222,4,0,220,126,119,254,165,107,160,255,82,220,248,1,241,175,136,0,144,141,23,255,169,138,84,0,160,137,78,255,226,118,80,255,52,27,132,255,63,96,139,255,152,250,39,0,188,155,15,0,232,51,150,254,40,15,232,255,240,229,9,255,137,175,27,255,75,73,97,1,218,212,11,0,135,5,162,1,107,185,213,0,2,249,107,255,40,242,70,0,219,200,25,0,25,157,13,0,67,82,80,255,196,249,23,255,145,20,149,0,50,72,146,0,94,76,148,1,24,251,65,0,31,192,23,0,184,212,201,255,123,233,162,1,247,173,72,0,162,87,219,254,126,134,89,0,159,11,12,254,166,105,29,0,73,27,228,1,113,120,183,255,66,163,109,1,212,143,11,255,159,231,168,1,255,128,90,0,57,14,58,254,89,52,10,255,253,8,163,1,0,145,210,255,10,129,85,1,46,181,27,0,103,136,160,254,126,188,209,255,34,35,111,0,215,219,24,255,212,11,214,254,101,5,118,0,232,197,133,255,223,167,109,255,237,80,86,255,70,139,94,0,158,193,191,1,155,15,51,255,15,190,115,0,78,135,207,255,249,10,27,1,181,125,233,0,95,172,13,254,170,213,161,255,39,236,138,255,95,93,87,255,190,128,95,0,125,15,206,0,166,150,159,0,227,15,158,255,206,158,120,255,42,141,128,0,101,178,120,1,156,109,131,0,218,14,44,254,247,168,206,255,212,112,28,0,112,17,228,255,90,16,37,1,197,222,108,0,254,207,83,255,9,90,243,255,243,244,172,0,26,88,115,255,205,116,122,0,191,230,193,0,180,100,11,1,217,37,96,255,154,78,156,0,235,234,31,255,206,178,178,255,149,192,251,0,182,250,135,0,246,22,105,0,124,193,109,255,2,210,149,255,169,17,170,0,0,96,110,255,117,9,8,1,50,123,40,255,193,189,99,0,34,227,160,0,48,80,70,254,211,51,236,0,45,122,245,254,44,174,8,0,173,37,233,255,158,65,171,0,122,69,215,255,90,80,2,255,131,106,96,254,227,114,135,0,205,49,119,254,176,62,64,255,82,51,17,255,241,20,243,255,130,13,8,254,128,217,243,255,162,27,1,254,90,118,241,0,246,198,246,255,55,16,118,255,200,159,157,0,163,17,1,0,140,107,121,0,85,161,118,255,38,0,149,0,156,47,238,0,9,166,166,1,75,98,181,255,50,74,25,0,66,15,47,0,139,225,159,0,76,3,142,255,14,238,184,0,11,207,53,255,183,192,186,1,171,32,174,255,191,76,221,1,247,170,219,0,25,172,50,254,217,9,233,0,203,126,68,255,183,92,48,0,127,167,183,1,65,49,254,0,16,63,127,1,254,21,170,255,59,224,127,254,22,48,63,255,27,78,130,254,40,195,29,0,250,132,112,254,35,203,144,0,104,169,168,0,207,253,30,255,104,40,38,254,94,228,88,0,206,16,128,255,212,55,122,255,223,22,234,0,223,197,127,0,253,181,181,1,145,102,118,0,236,153,36,255,212,217,72,255,20,38,24,254,138,62,62,0,152,140,4,0,230,220,99,255,1,21,212,255,148,201,231,0,244,123,9,254,0,171,210,0,51,58,37,255,1,255,14,255,244,183,145,254,0,242,166,0,22,74,132,0,121,216,41,0,95,195,114,254,133,24,151,255,156,226,231,255,247,5,77,255,246,148,115,254,225,92,81,255,222,80,246,254,170,123,89,255,74,199,141,0,29,20,8,255,138,136,70,255,93,75,92,0,221,147,49,254,52,126,226,0,229,124,23,0,46,9,181,0,205,64,52,1,131,254,28,0,151,158,212,0,131,64,78,0,206,25,171,0,0,230,139,0,191,253,110,254,103,247,167,0,64,40,40,1,42,165,241,255,59,75,228,254,124,243,189,255,196,92,178,255,130,140,86,255,141,89,56,1,147,198,5,255,203,248,158,254,144,162,141,0,11,172,226,0,130,42,21,255,1,167,143,255,144,36,36,255,48,88,164,254,168,170,220,0,98,71,214,0,91,208,79,0,159,76,201,1,166,42,214,255,69,255,0,255,6,128,125,255,190,1,140,0,146,83,218,255,215,238,72,1,122,127,53,0,189,116,165,255,84,8,66,255,214,3,208,255,213,110,133,0,195,168,44,1,158,231,69,0,162,64,200,254,91,58,104,0,182,58,187,254,249,228,136,0,203,134,76,254,99,221,233,0,75,254,214,254,80,69,154,0,64,152,248,254,236,136,202,255,157,105,153,254,149,175,20,0,22,35,19,255,124,121,233,0,186,250,198,254,132,229,139,0,137,80,174,255,165,125,68,0,144,202,148,254,235,239,248,0,135,184,118,0,101,94,17,255,122,72,70,254,69,130,146,0,127,222,248,1,69,127,118,255,30,82,215,254,188,74,19,255,229,167,194,254,117,25,66,255,65,234,56,254,213,22,156,0,151,59,93,254,45,28,27,255,186,126,164,255,32,6,239,0,127,114,99,1,219,52,2,255,99,96,166,254,62,190,126,255,108,222,168,1,75,226,174,0,230,226,199,0,60,117,218,255,252,248,20,1,214,188,204,0,31,194,134,254,123,69,192,255,169,173,36,254,55,98,91,0,223,42,102,254,137,1,102,0,157,90,25,0,239,122,64,255,252,6,233,0,7,54,20,255,82,116,174,0,135,37,54,255,15,186,125,0,227,112,175,255,100,180,225,255,42,237,244,255,244,173,226,254,248,18,33,0,171,99,150,255,74,235,50,255,117,82,32,254,106,168,237,0,207,109,208,1,228,9,186,0,135,60,169,254,179,92,143,0,244,170,104,255,235,45,124,255,70,99,186,0,117,137,183,0,224,31,215,0,40,9,100,0,26,16,95,1,68,217,87,0,8,151,20,255,26,100,58,255,176,165,203,1,52,118,70,0,7,32,254,254,244,254,245,255,167,144,194,255,125,113,23,255,176,121,181,0,136,84,209,0,138,6,30,255,89,48,28,0,33,155,14,255,25,240,154,0,141,205,109,1,70,115,62,255,20,40,107,254,138,154,199,255,94,223,226,255,157,171,38,0,163,177,25,254,45,118,3,255,14,222,23,1,209,190,81,255,118,123,232,1,13,213,101,255,123,55,123,254,27,246,165,0,50,99,76,255,140,214,32,255,97,65,67,255,24,12,28,0,174,86,78,1,64,247,96,0,160,135,67,0,66,55,243,255,147,204,96,255,26,6,33,255,98,51,83,1,153,213,208,255,2,184,54,255,25,218,11,0,49,67,246,254,18,149,72,255,13,25,72,0,42,79,214,0,42,4,38,1,27,139,144,255,149,187,23,0,18,164,132,0,245,84,184,254,120,198,104,255,126,218,96,0,56,117,234,255,13,29,214,254,68,47,10,255,167,154,132,254,152,38,198,0,66,178,89,255,200,46,171,255,13,99,83,255,210,187,253,255,170,45,42,1,138,209,124,0,214,162,141,0,12,230,156,0,102,36,112,254,3,147,67,0,52,215,123,255,233,171,54,255,98,137,62,0,247,218,39,255,231,218,236,0,247,191,127,0,195,146,84,0,165,176,92,255,19,212,94,255,17,74,227,0,88,40,153,1,198,147,1,255,206,67,245,254,240,3,218,255,61,141,213,255,97,183,106,0,195,232,235,254,95,86,154,0,209,48,205,254,118,209,241,255,240,120,223,1,213,29,159,0,163,127,147,255,13,218,93,0,85,24,68,254,70,20,80,255,189,5,140,1,82,97,254,255,99,99,191,255,132,84,133,255,107,218,116,255,112,122,46,0,105,17,32,0,194,160,63,255,68,222,39,1,216,253,92,0,177,105,205,255,149,201,195,0,42,225,11,255,40,162,115,0,9,7,81,0,165,218,219,0,180,22,0,254,29,146,252,255,146,207,225,1,180,135,96,0,31,163,112,0,177,11,219,255,133,12,193,254,43,78,50,0,65,113,121,1,59,217,6,255,110,94,24,1,112,172,111,0,7,15,96,0,36,85,123,0,71,150,21,255,208,73,188,0,192,11,167,1,213,245,34,0,9,230,92,0,162,142,39,255,215,90,27,0,98,97,89,0,94,79,211,0,90,157,240,0,95,220,126,1,102,176,226,0,36,30,224,254,35,31,127,0,231,232,115,1,85,83,130,0,210,73,245,255,47,143,114,255,68,65,197,0,59,72,62,255,183,133,173,254,93,121,118,255,59,177,81,255,234,69,173,255,205,128,177,0,220,244,51,0,26,244,209,1,73,222,77,255,163,8,96,254,150,149,211,0,158,254,203,1,54,127,139,0,161,224,59,0,4,109,22,255,222,42,45,255,208,146,102,255,236,142,187,0,50,205,245,255,10,74,89,254,48,79,142,0,222,76,130,255,30,166,63,0,236,12,13,255,49,184,244,0,187,113,102,0,218,101,253,0,153,57,182,254,32,150,42,0,25,198,146,1,237,241,56,0,140,68,5,0,91,164,172,255,78,145,186,254,67,52,205,0,219,207,129,1,109,115,17,0,54,143,58,1,21,248,120,255,179,255,30,0,193,236,66,255,1,255,7,255,253,192,48,255,19,69,217,1,3,214,0,255,64,101,146,1,223,125,35,255,235,73,179,255,249,167,226,0,225,175,10,1,97,162,58,0,106,112,171,1,84,172,5,255,133,140,178,255,134,245,142,0,97,90,125,255,186,203,185,255,223,77,23,255,192,92,106,0,15,198,115,255,217,152,248,0,171,178,120,255,228,134,53,0,176,54,193,1,250,251,53,0,213,10,100,1,34,199,106,0,151,31,244,254,172,224,87,255,14,237,23,255,253,85,26,255,127,39,116,255,172,104,100,0,251,14,70,255,212,208,138,255,253,211,250,0,176,49,165,0,15,76,123,255,37,218,160,255,92,135,16,1,10,126,114,255,70,5,224,255,247,249,141,0,68,20,60,1,241,210,189,255,195,217,187,1,151,3,113,0,151,92,174,0,231,62,178,255,219,183,225,0,23,23,33,255,205,181,80,0,57,184,248,255,67,180,1,255,90,123,93,255,39,0,162,255,96,248,52,255,84,66,140,0,34,127,228,255,194,138,7,1,166,110,188,0,21,17,155,1,154,190,198,255,214,80,59,255,18,7,143,0,72,29,226,1,199,217,249,0,232,161,71,1,149,190,201,0,217,175,95,254,113,147,67,255,138,143,199,255,127,204,1,0,29,182,83,1,206,230,155,255,186,204,60,0,10,125,85,255,232,96,25,255,255,89,247,255,213,254,175,1,232,193,81,0,28,43,156,254,12,69,8,0,147,24,248,0,18,198,49,0,134,60,35,0,118,246,18,255,49,88,254,254,228,21,186,255,182,65,112,1,219,22,1,255,22,126,52,255,189,53,49,255,112,25,143,0,38,127,55,255,226,101,163,254,208,133,61,255,137,69,174,1,190,118,145,255,60,98,219,255,217,13,245,255,250,136,10,0,84,254,226,0,201,31,125,1,240,51,251,255,31,131,130,255,2,138,50,255,215,215,177,1,223,12,238,255,252,149,56,255,124,91,68,255,72,126,170,254,119,255,100,0,130,135,232,255,14,79,178,0,250,131,197,0,138,198,208,0,121,216,139,254,119,18,36,255,29,193,122,0,16,42,45,255,213,240,235,1,230,190,169,255,198,35,228,254,110,173,72,0,214,221,241,255,56,148,135,0,192,117,78,254,141,93,207,255,143,65,149,0,21,18,98,255,95,44,244,1,106,191,77,0,254,85,8,254,214,110,176,255,73,173,19,254,160,196,199,255,237,90,144,0,193,172,113,255,200,155,136,254,228,90,221,0,137,49,74,1,164,221,215,255,209,189,5,255,105,236,55,255,42,31,129,1,193,255,236,0,46,217,60,0,138,88,187,255,226,82,236,255,81,69,151,255,142,190,16,1,13,134,8,0,127,122,48,255,81,64,156,0,171,243,139,0,237,35,246,0,122,143,193,254,212,122,146,0,95,41,255,1,87,132,77,0,4,212,31,0,17,31,78,0,39,45,173,254,24,142,217,255,95,9,6,255,227,83,6,0,98,59,130,254,62,30,33,0,8,115,211,1,162,97,128,255,7,184,23,254,116,28,168,255,248,138,151,255,98,244,240,0,186,118,130,0,114,248,235,255,105,173,200,1,160,124,71,255,94,36,164,1,175,65,146,255,238,241,170,254,202,198,197,0,228,71,138,254,45,246,109,255,194,52,158,0,133,187,176,0,83,252,154,254,89,189,221,255,170,73,252,0,148,58,125,0,36,68,51,254,42,69,177,255,168,76,86,255,38,100,204,255,38,53,35,0,175,19,97,0,225,238,253,255,81,81,135,0,210,27,255,254,235,73,107,0,8,207,115,0,82,127,136,0,84,99,21,254,207,19,136,0,100,164,101,0,80,208,77,255,132,207,237,255,15,3,15,255,33,166,110,0,156,95,85,255,37,185,111,1,150,106,35,255,166,151,76,0,114,87,135,255,159,194,64,0,12,122,31,255,232,7,101,254,173,119,98,0,154,71,220,254,191,57,53,255,168,232,160,255,224,32,99,255,218,156,165,0,151,153,163,0,217,13,148,1,197,113,89,0,149,28,161,254,207,23,30,0,105,132,227,255,54,230,94,255,133,173,204,255,92,183,157,255,88,144,252,254,102,33,90,0,159,97,3,0,181,218,155,255,240,114,119,0,106,214,53,255,165,190,115,1,152,91,225,255,88,106,44,255,208,61,113,0,151,52,124,0,191,27,156,255,110,54,236,1,14,30,166,255,39,127,207,1,229,199,28,0,188,228,188,254,100,157,235,0,246,218,183,1,107,22,193,255,206,160,95,0,76,239,147,0,207,161,117,0,51,166,2,255,52,117,10,254,73,56,227,255,152,193,225,0,132,94,136,255,101,191,209,0,32,107,229,255,198,43,180,1,100,210,118,0,114,67,153,255,23,88,26,255,89,154,92,1,220,120,140,255,144,114,207,255,252,115,250,255,34,206,72,0,138,133,127,255,8,178,124,1,87,75,97,0,15,229,92,254,240,67,131,255,118,123,227,254,146,120,104,255,145,213,255,1,129,187,70,255,219,119,54,0,1,19,173,0,45,150,148,1,248,83,72,0,203,233,169,1,142,107,56,0,247,249,38,1,45,242,80,255,30,233,103,0,96,82,70,0,23,201,111,0,81,39,30,255,161,183,78,255,194,234,33,255,68,227,140,254,216,206,116,0,70,27,235,255,104,144,79,0,164,230,93,254,214,135,156,0,154,187,242,254,188,20,131,255,36,109,174,0,159,112,241,0,5,110,149,1,36,165,218,0,166,29,19,1,178,46,73,0,93,43,32,254,248,189,237,0,102,155,141,0,201,93,195,255,241,139,253,255,15,111,98,255,108,65,163,254,155,79,190,255,73,174,193,254,246,40,48,255,107,88,11,254,202,97,85,255,253,204,18,255,113,242,66,0,110,160,194,254,208,18,186,0,81,21,60,0,188,104,167,255,124,166,97,254,210,133,142,0,56,242,137,254,41,111,130,0,111,151,58,1,111,213,141,255,183,172,241,255,38,6,196,255,185,7,123,255,46,11,246,0,245,105,119,1,15,2,161,255,8,206,45,255,18,202,74,255,83,124,115,1,212,141,157,0,83,8,209,254,139,15,232,255,172,54,173,254,50,247,132,0,214,189,213,0,144,184,105,0,223,254,248,0,255,147,240,255,23,188,72,0,7,51,54,0,188,25,180,254,220,180,0,255,83,160,20,0,163,189,243,255,58,209,194,255,87,73,60,0,106,24,49,0,245,249,220,0,22,173,167,0,118,11,195,255,19,126,237,0,110,159,37,255,59,82,47,0,180,187,86,0,188,148,208,1,100,37,133,255,7,112,193,0,129,188,156,255,84,106,129,255,133,225,202,0,14,236,111,255,40,20,101,0,172,172,49,254,51,54,74,255,251,185,184,255,93,155,224,255,180,249,224,1,230,178,146,0,72,57,54,254,178,62,184,0,119,205,72,0,185,239,253,255,61,15,218,0,196,67,56,255,234,32,171,1,46,219,228,0,208,108,234,255,20,63,232,255,165,53,199,1,133,228,5,255,52,205,107,0,74,238,140,255,150,156,219,254,239,172,178,255,251,189,223,254,32,142,211,255,218,15,138,1,241,196,80,0,28,36,98,254,22,234,199,0,61,237,220,255,246,57,37,0,142,17,142,255,157,62,26,0,43,238,95,254,3,217,6,255,213,25,240,1,39,220,174,255,154,205,48,254,19,13,192,255,244,34,54,254,140,16,155,0,240,181,5,254,155,193,60,0,166,128,4,255,36,145,56,255,150,240,219,0,120,51,145,0,82,153,42,1,140,236,146,0,107,92,248,1,189,10,3,0,63,136,242,0,211,39,24,0,19,202,161,1,173,27,186,255,210,204,239,254,41,209,162,255,182,254,159,255,172,116,52,0,195,103,222,254,205,69,59,0,53,22,41,1,218,48,194,0,80,210,242,0,210,188,207,0,187,161,161,254,216,17,1,0,136,225,113,0,250,184,63,0,223,30,98,254,77,168,162,0,59,53,175,0,19,201,10,255,139,224,194,0,147,193,154,255,212,189,12,254,1,200,174,255,50,133,113,1,94,179,90,0,173,182,135,0,94,177,113,0,43,89,215,255,136,252,106,255,123,134,83,254,5,245,66,255,82,49,39,1,220,2,224,0,97,129,177,0,77,59,89,0,61,29,155,1,203,171,220,255,92,78,139,0,145,33,181,255,169,24,141,1,55,150,179,0,139,60,80,255,218,39,97,0,2,147,107,255,60,248,72,0,173,230,47,1,6,83,182,255,16,105,162,254,137,212,81,255,180,184,134,1,39,222,164,255,221,105,251,1,239,112,125,0,63,7,97,0,63,104,227,255,148,58,12,0,90,60,224,255,84,212,252,0,79,215,168,0,248,221,199,1,115,121,1,0,36,172,120,0,32,162,187,255,57,107,49,255,147,42,21,0,106,198,43,1,57,74,87,0,126,203,81,255,129,135,195,0,140,31,177,0,221,139,194,0,3,222,215,0,131,68,231,0,177,86,178,254,124,151,180,0,184,124,38,1,70,163,17,0,249,251,181,1,42,55,227,0,226,161,44,0,23,236,110,0,51,149,142,1,93,5,236,0,218,183,106,254,67,24,77,0,40,245,209,255,222,121,153,0,165,57,30,0,83,125,60,0,70,38,82,1,229,6,188,0,109,222,157,255,55,118,63,255,205,151,186,0,227,33,149,255,254,176,246,1,227,177,227,0,34,106,163,254,176,43,79,0,106,95,78,1,185,241,122,255,185,14,61,0,36,1,202,0,13,178,162,255,247,11,132,0,161,230,92,1,65,1,185,255,212,50,165,1,141,146,64,255,158,242,218,0,21,164,125,0,213,139,122,1,67,71,87,0,203,158,178,1,151,92,43,0,152,111,5,255,39,3,239,255,217,255,250,255,176,63,71,255,74,245,77,1,250,174,18,255,34,49,227,255,246,46,251,255,154,35,48,1,125,157,61,255,106,36,78,255,97,236,153,0,136,187,120,255,113,134,171,255,19,213,217,254,216,94,209,255,252,5,61,0,94,3,202,0,3,26,183,255,64,191,43,255,30,23,21,0,129,141,77,255,102,120,7,1,194,76,140,0,188,175,52,255,17,81,148,0,232,86,55,1,225,48,172,0,134,42,42,255,238,50,47,0,169,18,254,0,20,147,87,255,14,195,239,255,69,247,23,0,238,229,128,255,177,49,112,0,168,98,251,255,121,71,248,0,243,8,145,254,246,227,153,255,219,169,177,254,251,139,165,255,12,163,185,255,164,40,171,255,153,159,27,254,243,109,91,255,222,24,112,1,18,214,231,0,107,157,181,254,195,147,0,255,194,99,104,255,89,140,190,255,177,66,126,254,106,185,66],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE);allocate([49,218,31,0,252,174,158,0,188,79,230,1,238,41,224,0,212,234,8,1,136,11,181,0,166,117,83,255,68,195,94,0,46,132,201,0,240,152,88,0,164,57,69,254,160,224,42,255,59,215,67,255,119,195,141,255,36,180,121,254,207,47,8,255,174,210,223,0,101,197,68,255,255,82,141,1,250,137,233,0,97,86,133,1,16,80,69,0,132,131,159,0,116,93,100,0,45,141,139,0,152,172,157,255,90,43,91,0,71,153,46,0,39,16,112,255,217,136,97,255,220,198,25,254,177,53,49,0,222,88,134,255,128,15,60,0,207,192,169,255,192,116,209,255,106,78,211,1,200,213,183,255,7,12,122,254,222,203,60,255,33,110,199,254,251,106,117,0,228,225,4,1,120,58,7,255,221,193,84,254,112,133,27,0,189,200,201,255,139,135,150,0,234,55,176,255,61,50,65,0,152,108,169,255,220,85,1,255,112,135,227,0,162,26,186,0,207,96,185,254,244,136,107,0,93,153,50,1,198,97,151,0,110,11,86,255,143,117,174,255,115,212,200,0,5,202,183,0,237,164,10,254,185,239,62,0,236,120,18,254,98,123,99,255,168,201,194,254,46,234,214,0,191,133,49,255,99,169,119,0,190,187,35,1,115,21,45,255,249,131,72,0,112,6,123,255,214,49,181,254,166,233,34,0,92,197,102,254,253,228,205,255,3,59,201,1,42,98,46,0,219,37,35,255,169,195,38,0,94,124,193,1,156,43,223,0,95,72,133,254,120,206,191,0,122,197,239,255,177,187,79,255,254,46,2,1,250,167,190,0,84,129,19,0,203,113,166,255,249,31,189,254,72,157,202,255,208,71,73,255,207,24,72,0,10,16,18,1,210,81,76,255,88,208,192,255,126,243,107,255,238,141,120,255,199,121,234,255,137,12,59,255,36,220,123,255,148,179,60,254,240,12,29,0,66,0,97,1,36,30,38,255,115,1,93,255,96,103,231,255,197,158,59,1,192,164,240,0,202,202,57,255,24,174,48,0,89,77,155,1,42,76,215,0,244,151,233,0,23,48,81,0,239,127,52,254,227,130,37,255,248,116,93,1,124,132,118,0,173,254,192,1,6,235,83,255,110,175,231,1,251,28,182,0,129,249,93,254,84,184,128,0,76,181,62,0,175,128,186,0,100,53,136,254,109,29,226,0,221,233,58,1,20,99,74,0,0,22,160,0,134,13,21,0,9,52,55,255,17,89,140,0,175,34,59,0,84,165,119,255,224,226,234,255,7,72,166,255,123,115,255,1,18,214,246,0,250,7,71,1,217,220,185,0,212,35,76,255,38,125,175,0,189,97,210,0,114,238,44,255,41,188,169,254,45,186,154,0,81,92,22,0,132,160,193,0,121,208,98,255,13,81,44,255,203,156,82,0,71,58,21,255,208,114,191,254,50,38,147,0,154,216,195,0,101,25,18,0,60,250,215,255,233,132,235,255,103,175,142,1,16,14,92,0,141,31,110,254,238,241,45,255,153,217,239,1,97,168,47,255,249,85,16,1,28,175,62,255,57,254,54,0,222,231,126,0,166,45,117,254,18,189,96,255,228,76,50,0,200,244,94,0,198,152,120,1,68,34,69,255,12,65,160,254,101,19,90,0,167,197,120,255,68,54,185,255,41,218,188,0,113,168,48,0,88,105,189,1,26,82,32,255,185,93,164,1,228,240,237,255,66,182,53,0,171,197,92,255,107,9,233,1,199,120,144,255,78,49,10,255,109,170,105,255,90,4,31,255,28,244,113,255,74,58,11,0,62,220,246,255,121,154,200,254,144,210,178,255,126,57,129,1,43,250,14,255,101,111,28,1,47,86,241,255,61,70,150,255,53,73,5,255,30,26,158,0,209,26,86,0,138,237,74,0,164,95,188,0,142,60,29,254,162,116,248,255,187,175,160,0,151,18,16,0,209,111,65,254,203,134,39,255,88,108,49,255,131,26,71,255,221,27,215,254,104,105,93,255,31,236,31,254,135,0,211,255,143,127,110,1,212,73,229,0,233,67,167,254,195,1,208,255,132,17,221,255,51,217,90,0,67,235,50,255,223,210,143,0,179,53,130,1,233,106,198,0,217,173,220,255,112,229,24,255,175,154,93,254,71,203,246,255,48,66,133,255,3,136,230,255,23,221,113,254,235,111,213,0,170,120,95,254,251,221,2,0,45,130,158,254,105,94,217,255,242,52,180,254,213,68,45,255,104,38,28,0,244,158,76,0,161,200,96,255,207,53,13,255,187,67,148,0,170,54,248,0,119,162,178,255,83,20,11,0,42,42,192,1,146,159,163,255,183,232,111,0,77,229,21,255,71,53,143,0,27,76,34,0,246,136,47,255,219,39,182,255,92,224,201,1,19,142,14,255,69,182,241,255,163,118,245,0,9,109,106,1,170,181,247,255,78,47,238,255,84,210,176,255,213,107,139,0,39,38,11,0,72,21,150,0,72,130,69,0,205,77,155,254,142,133,21,0,71,111,172,254,226,42,59,255,179,0,215,1,33,128,241,0,234,252,13,1,184,79,8,0,110,30,73,255,246,141,189,0,170,207,218,1,74,154,69,255,138,246,49,255,155,32,100,0,125,74,105,255,90,85,61,255,35,229,177,255,62,125,193,255,153,86,188,1,73,120,212,0,209,123,246,254,135,209,38,255,151,58,44,1,92,69,214,255,14,12,88,255,252,153,166,255,253,207,112,255,60,78,83,255,227,124,110,0,180,96,252,255,53,117,33,254,164,220,82,255,41,1,27,255,38,164,166,255,164,99,169,254,61,144,70,255,192,166,18,0,107,250,66,0,197,65,50,0,1,179,18,255,255,104,1,255,43,153,35,255,80,111,168,0,110,175,168,0,41,105,45,255,219,14,205,255,164,233,140,254,43,1,118,0,233,67,195,0,178,82,159,255,138,87,122,255,212,238,90,255,144,35,124,254,25,140,164,0,251,215,44,254,133,70,107,255,101,227,80,254,92,169,55,0,215,42,49,0,114,180,85,255,33,232,27,1,172,213,25,0,62,176,123,254,32,133,24,255,225,191,62,0,93,70,153,0,181,42,104,1,22,191,224,255,200,200,140,255,249,234,37,0,149,57,141,0,195,56,208,255,254,130,70,255,32,173,240,255,29,220,199,0,110,100,115,255,132,229,249,0,228,233,223,255,37,216,209,254,178,177,209,255,183,45,165,254,224,97,114,0,137,97,168,255,225,222,172,0,165,13,49,1,210,235,204,255,252,4,28,254,70,160,151,0,232,190,52,254,83,248,93,255,62,215,77,1,175,175,179,255,160,50,66,0,121,48,208,0,63,169,209,255,0,210,200,0,224,187,44,1,73,162,82,0,9,176,143,255,19,76,193,255,29,59,167,1,24,43,154,0,28,190,190,0,141,188,129,0,232,235,203,255,234,0,109,255,54,65,159,0,60,88,232,255,121,253,150,254,252,233,131,255,198,110,41,1,83,77,71,255,200,22,59,254,106,253,242,255,21,12,207,255,237,66,189,0,90,198,202,1,225,172,127,0,53,22,202,0,56,230,132,0,1,86,183,0,109,190,42,0,243,68,174,1,109,228,154,0,200,177,122,1,35,160,183,255,177,48,85,255,90,218,169,255,248,152,78,0,202,254,110,0,6,52,43,0,142,98,65,255,63,145,22,0,70,106,93,0,232,138,107,1,110,179,61,255,211,129,218,1,242,209,92,0,35,90,217,1,182,143,106,255,116,101,217,255,114,250,221,255,173,204,6,0,60,150,163,0,73,172,44,255,239,110,80,255,237,76,153,254,161,140,249,0,149,232,229,0,133,31,40,255,174,164,119,0,113,51,214,0,129,228,2,254,64,34,243,0,107,227,244,255,174,106,200,255,84,153,70,1,50,35,16,0,250,74,216,254,236,189,66,255,153,249,13,0,230,178,4,255,221,41,238,0,118,227,121,255,94,87,140,254,254,119,92,0,73,239,246,254,117,87,128,0,19,211,145,255,177,46,252,0,229,91,246,1,69,128,247,255,202,77,54,1,8,11,9,255,153,96,166,0,217,214,173,255,134,192,2,1,0,207,0,0,189,174,107,1,140,134,100,0,158,193,243,1,182,102,171,0,235,154,51,0,142,5,123,255,60,168,89,1,217,14,92,255,19,214,5,1,211,167,254,0,44,6,202,254,120,18,236,255,15,113,184,255,184,223,139,0,40,177,119,254,182,123,90,255,176,165,176,0,247,77,194,0,27,234,120,0,231,0,214,255,59,39,30,0,125,99,145,255,150,68,68,1,141,222,248,0,153,123,210,255,110,127,152,255,229,33,214,1,135,221,197,0,137,97,2,0,12,143,204,255,81,41,188,0,115,79,130,255,94,3,132,0,152,175,187,255,124,141,10,255,126,192,179,255,11,103,198,0,149,6,45,0,219,85,187,1,230,18,178,255,72,182,152,0,3,198,184,255,128,112,224,1,97,161,230,0,254,99,38,255,58,159,197,0,151,66,219,0,59,69,143,255,185,112,249,0,119,136,47,255,123,130,132,0,168,71,95,255,113,176,40,1,232,185,173,0,207,93,117,1,68,157,108,255,102,5,147,254,49,97,33,0,89,65,111,254,247,30,163,255,124,217,221,1,102,250,216,0,198,174,75,254,57,55,18,0,227,5,236,1,229,213,173,0,201,109,218,1,49,233,239,0,30,55,158,1,25,178,106,0,155,111,188,1,94,126,140,0,215,31,238,1,77,240,16,0,213,242,25,1,38,71,168,0,205,186,93,254,49,211,140,255,219,0,180,255,134,118,165,0,160,147,134,255,110,186,35,255,198,243,42,0,243,146,119,0,134,235,163,1,4,241,135,255,193,46,193,254,103,180,79,255,225,4,184,254,242,118,130,0,146,135,176,1,234,111,30,0,69,66,213,254,41,96,123,0,121,94,42,255,178,191,195,255,46,130,42,0,117,84,8,255,233,49,214,254,238,122,109,0,6,71,89,1,236,211,123,0,244,13,48,254,119,148,14,0,114,28,86,255,75,237,25,255,145,229,16,254,129,100,53,255,134,150,120,254,168,157,50,0,23,72,104,255,224,49,14,0,255,123,22,255,151,185,151,255,170,80,184,1,134,182,20,0,41,100,101,1,153,33,16,0,76,154,111,1,86,206,234,255,192,160,164,254,165,123,93,255,1,216,164,254,67,17,175,255,169,11,59,255,158,41,61,255,73,188,14,255,195,6,137,255,22,147,29,255,20,103,3,255,246,130,227,255,122,40,128,0,226,47,24,254,35,36,32,0,152,186,183,255,69,202,20,0,195,133,195,0,222,51,247,0,169,171,94,1,183,0,160,255,64,205,18,1,156,83,15,255,197,58,249,254,251,89,110,255,50,10,88,254,51,43,216,0,98,242,198,1,245,151,113,0,171,236,194,1,197,31,199,255,229,81,38,1,41,59,20,0,253,104,230,0,152,93,14,255,246,242,146,254,214,169,240,255,240,102,108,254,160,167,236,0,154,218,188,0,150,233,202,255,27,19,250,1,2,71,133,255,175,12,63,1,145,183,198,0,104,120,115,255,130,251,247,0,17,212,167,255,62,123,132,255,247,100,189,0,155,223,152,0,143,197,33,0,155,59,44,255,150,93,240,1,127,3,87,255,95,71,207,1,167,85,1,255,188,152,116,255,10,23,23,0,137,195,93,1,54,98,97,0,240,0,168,255,148,188,127,0,134,107,151,0,76,253,171,0,90,132,192,0,146,22,54,0,224,66,54,254,230,186,229,255,39,182,196,0,148,251,130,255,65,131,108,254,128,1,160,0,169,49,167,254,199,254,148,255,251,6,131,0,187,254,129,255,85,82,62,0,178,23,58,255,254,132,5,0,164,213,39,0,134,252,146,254,37,53,81,255,155,134,82,0,205,167,238,255,94,45,180,255,132,40,161,0,254,111,112,1,54,75,217,0,179,230,221,1,235,94,191,255,23,243,48,1,202,145,203,255,39,118,42,255,117,141,253,0,254,0,222,0,43,251,50,0,54,169,234,1,80,68,208,0,148,203,243,254,145,7,135,0,6,254,0,0,252,185,127,0,98,8,129,255,38,35,72,255,211,36,220,1,40,26,89,0,168,64,197,254,3,222,239,255,2,83,215,254,180,159,105,0,58,115,194,0,186,116,106,255,229,247,219,255,129,118,193,0,202,174,183,1,166,161,72,0,201,107,147,254,237,136,74,0,233,230,106,1,105,111,168,0,64,224,30,1,1,229,3,0,102,151,175,255,194,238,228,255,254,250,212,0,187,237,121,0,67,251,96,1,197,30,11,0,183,95,204,0,205,89,138,0,64,221,37,1,255,223,30,255,178,48,211,255,241,200,90,255,167,209,96,255,57,130,221,0,46,114,200,255,61,184,66,0,55,182,24,254,110,182,33,0,171,190,232,255,114,94,31,0,18,221,8,0,47,231,254,0,255,112,83,0,118,15,215,255,173,25,40,254,192,193,31,255,238,21,146,255,171,193,118,255,101,234,53,254,131,212,112,0,89,192,107,1,8,208,27,0,181,217,15,255,231,149,232,0,140,236,126,0,144,9,199,255,12,79,181,254,147,182,202,255,19,109,182,255,49,212,225,0,74,163,203,0,175,233,148,0,26,112,51,0,193,193,9,255,15,135,249,0,150,227,130,0,204,0,219,1,24,242,205,0,238,208,117,255,22,244,112,0,26,229,34,0,37,80,188,255,38,45,206,254,240,90,225,255,29,3,47,255,42,224,76,0,186,243,167,0,32,132,15,255,5,51,125,0,139,135,24,0,6,241,219,0,172,229,133,255,246,214,50,0,231,11,207,255,191,126,83,1,180,163,170,255,245,56,24,1,178,164,211,255,3,16,202,1,98,57,118,255,141,131,89,254,33,51,24,0,243,149,91,255,253,52,14,0,35,169,67,254,49,30,88,255,179,27,36,255,165,140,183,0,58,189,151,0,88,31,0,0,75,169,66,0,66,101,199,255,24,216,199,1,121,196,26,255,14,79,203,254,240,226,81,255,94,28,10,255,83,193,240,255,204,193,131,255,94,15,86,0,218,40,157,0,51,193,209,0,0,242,177,0,102,185,247,0,158,109,116,0,38,135,91,0,223,175,149,0,220,66,1,255,86,60,232,0,25,96,37,255,225,122,162,1,215,187,168,255,158,157,46,0,56,171,162,0,232,240,101,1,122,22,9,0,51,9,21,255,53,25,238,255,217,30,232,254,125,169,148,0,13,232,102,0,148,9,37,0,165,97,141,1,228,131,41,0,222,15,243,255,254,18,17,0,6,60,237,1,106,3,113,0,59,132,189,0,92,112,30,0,105,208,213,0,48,84,179,255,187,121,231,254,27,216,109,255,162,221,107,254,73,239,195,255,250,31,57,255,149,135,89,255,185,23,115,1,3,163,157,255,18,112,250,0,25,57,187,255,161,96,164,0,47,16,243,0,12,141,251,254,67,234,184,255,41,18,161,0,175,6,96,255,160,172,52,254,24,176,183,255,198,193,85,1,124,121,137,255,151,50,114,255,220,203,60,255,207,239,5,1,0,38,107,255,55,238,94,254,70,152,94,0,213,220,77,1,120,17,69,255,85,164,190,255,203,234,81,0,38,49,37,254,61,144,124,0,137,78,49,254,168,247,48,0,95,164,252,0,105,169,135,0,253,228,134,0,64,166,75,0,81,73,20,255,207,210,10,0,234,106,150,255,94,34,90,255,254,159,57,254,220,133,99,0,139,147,180,254,24,23,185,0,41,57,30,255,189,97,76,0,65,187,223,255,224,172,37,255,34,62,95,1,231,144,240,0,77,106,126,254,64,152,91,0,29,98,155,0,226,251,53,255,234,211,5,255,144,203,222,255,164,176,221,254,5,231,24,0,179,122,205,0,36,1,134,255,125,70,151,254,97,228,252,0,172,129,23,254,48,90,209,255,150,224,82,1,84,134,30,0,241,196,46,0,103,113,234,255,46,101,121,254,40,124,250,255,135,45,242,254,9,249,168,255,140,108,131,255,143,163,171,0,50,173,199,255,88,222,142,255,200,95,158,0,142,192,163,255,7,117,135,0,111,124,22,0,236,12,65,254,68,38,65,255,227,174,254,0,244,245,38,0,240,50,208,255,161,63,250,0,60,209,239,0,122,35,19,0,14,33,230,254,2,159,113,0,106,20,127,255,228,205,96,0,137,210,174,254,180,212,144,255,89,98,154,1,34,88,139,0,167,162,112,1,65,110,197,0,241,37,169,0,66,56,131,255,10,201,83,254,133,253,187,255,177,112,45,254,196,251,0,0,196,250,151,255,238,232,214,255,150,209,205,0,28,240,118,0,71,76,83,1,236,99,91,0,42,250,131,1,96,18,64,255,118,222,35,0,113,214,203,255,122,119,184,255,66,19,36,0,204,64,249,0,146,89,139,0,134,62,135,1,104,233,101,0,188,84,26,0,49,249,129,0,208,214,75,255,207,130,77,255,115,175,235,0,171,2,137,255,175,145,186,1,55,245,135,255,154,86,181,1,100,58,246,255,109,199,60,255,82,204,134,255,215,49,230,1,140,229,192,255,222,193,251,255,81,136,15,255,179,149,162,255,23,39,29,255,7,95,75,254,191,81,222,0,241,81,90,255,107,49,201,255,244,211,157,0,222,140,149,255,65,219,56,254,189,246,90,255,178,59,157,1,48,219,52,0,98,34,215,0,28,17,187,255,175,169,24,0,92,79,161,255,236,200,194,1,147,143,234,0,229,225,7,1,197,168,14,0,235,51,53,1,253,120,174,0,197,6,168,255,202,117,171,0,163,21,206,0,114,85,90,255,15,41,10,255,194,19,99,0,65,55,216,254,162,146,116,0,50,206,212,255,64,146,29,255,158,158,131,1,100,165,130,255,172,23,129,255,125,53,9,255,15,193,18,1,26,49,11,255,181,174,201,1,135,201,14,255,100,19,149,0,219,98,79,0,42,99,143,254,96,0,48,255,197,249,83,254,104,149,79,255,235,110,136,254,82,128,44,255,65,41,36,254,88,211,10,0,187,121,187,0,98,134,199,0,171,188,179,254,210,11,238,255,66,123,130,254,52,234,61,0,48,113,23,254,6,86,120,255,119,178,245,0,87,129,201,0,242,141,209,0,202,114,85,0,148,22,161,0,103,195,48,0,25,49,171,255,138,67,130,0,182,73,122,254,148,24,130,0,211,229,154,0,32,155,158,0,84,105,61,0,177,194,9,255,166,89,86,1,54,83,187,0,249,40,117,255,109,3,215,255,53,146,44,1,63,47,179,0,194,216,3,254,14,84,136,0,136,177,13,255,72,243,186,255,117,17,125,255,211,58,211,255,93,79,223,0,90,88,245,255,139,209,111,255,70,222,47,0,10,246,79,255,198,217,178,0,227,225,11,1,78,126,179,255,62,43,126,0,103,148,35,0,129,8,165,254,245,240,148,0,61,51,142,0,81,208,134,0,15,137,115,255,211,119,236,255,159,245,248,255,2,134,136,255,230,139,58,1,160,164,254,0,114,85,141,255,49,166,182,255,144,70,84,1,85,182,7,0,46,53,93,0,9,166,161,255,55,162,178,255,45,184,188,0,146,28,44,254,169,90,49,0,120,178,241,1,14,123,127,255,7,241,199,1,189,66,50,255,198,143,101,254,189,243,135,255,141,24,24,254,75,97,87,0,118,251,154,1,237,54,156,0,171,146,207,255,131,196,246,255,136,64,113,1,151,232,57,0,240,218,115,0,49,61,27,255,64,129,73,1,252,169,27,255,40,132,10,1,90,201,193,255,252,121,240,1,186,206,41,0,43,198,97,0,145,100,183,0,204,216,80,254,172,150,65,0,249,229,196,254,104,123,73,255,77,104,96,254,130,180,8,0,104,123,57,0,220,202,229,255,102,249,211,0,86,14,232,255,182,78,209,0,239,225,164,0,106,13,32,255,120,73,17,255,134,67,233,0,83,254,181,0,183,236,112,1,48,64,131,255,241,216,243,255,65,193,226,0,206,241,100,254,100,134,166,255,237,202,197,0,55,13,81,0,32,124,102,255,40,228,177,0,118,181,31,1,231,160,134,255,119,187,202,0,0,142,60,255,128,38,189,255,166,201,150,0,207,120,26,1,54,184,172,0,12,242,204,254,133,66,230,0,34,38,31,1,184,112,80,0,32,51,165,254,191,243,55,0,58,73,146,254,155,167,205,255,100,104,152,255,197,254,207,255,173,19,247,0,238,10,202,0,239,151,242,0,94,59,39,255,240,29,102,255,10,92,154,255,229,84,219,255,161,129,80,0,208,90,204,1,240,219,174,255,158,102,145,1,53,178,76,255,52,108,168,1,83,222,107,0,211,36,109,0,118,58,56,0,8,29,22,0,237,160,199,0,170,209,157,0,137,71,47,0,143,86,32,0,198,242,2,0,212,48,136,1,92,172,186,0,230,151,105,1,96,191,229,0,138,80,191,254,240,216,130,255,98,43,6,254,168,196,49,0,253,18,91,1,144,73,121,0,61,146,39,1,63,104,24,255,184,165,112,254,126,235,98,0,80,213,98,255,123,60,87,255,82,140,245,1,223,120,173,255,15,198,134,1,206,60,239,0,231,234,92,255,33,238,19,255,165,113,142,1,176,119,38,0,160,43,166,254,239,91,105,0,107,61,194,1,25,4,68,0,15,139,51,0,164,132,106,255,34,116,46,254,168,95,197,0,137,212,23,0,72,156,58,0,137,112,69,254,150,105,154,255,236,201,157,0,23,212,154,255,136,82,227,254,226,59,221,255,95,149,192,0,81,118,52,255,33,43,215,1,14,147,75,255,89,156,121,254,14,18,79,0,147,208,139,1,151,218,62,255,156,88,8,1,210,184,98,255,20,175,123,255,102,83,229,0,220,65,116,1,150,250,4,255,92,142,220,255,34,247,66,255,204,225,179,254,151,81,151,0,71,40,236,255,138,63,62,0,6,79,240,255,183,185,181,0,118,50,27,0,63,227,192,0,123,99,58,1,50,224,155,255,17,225,223,254,220,224,77,255,14,44,123,1,141,128,175,0,248,212,200,0,150,59,183,255,147,97,29,0,150,204,181,0,253,37,71,0,145,85,119,0,154,200,186,0,2,128,249,255,83,24,124,0,14,87,143,0,168,51,245,1,124,151,231,255,208,240,197,1,124,190,185,0,48,58,246,0,20,233,232,0,125,18,98,255,13,254,31,255,245,177,130,255,108,142,35,0,171,125,242,254,140,12,34,255,165,161,162,0,206,205,101,0,247,25,34,1,100,145,57,0,39,70,57,0,118,204,203,255,242,0,162,0,165,244,30,0,198,116,226,0,128,111,153,255,140,54,182,1,60,122,15,255,155,58,57,1,54,50,198,0,171,211,29,255,107,138,167,255,173,107,199,255,109,161,193,0,89,72,242,255,206,115,89,255,250,254,142,254,177,202,94,255,81,89,50,0,7,105,66,255,25,254,255,254,203,64,23,255,79,222,108,255,39,249,75,0,241,124,50,0,239,152,133,0,221,241,105,0,147,151,98,0,213,161,121,254,242,49,137,0,233,37,249,254,42,183,27,0,184,119,230,255,217,32,163,255,208,251,228,1,137,62,131,255,79,64,9,254,94,48,113,0,17,138,50,254,193,255,22,0,247,18,197,1,67,55,104,0,16,205,95,255,48,37,66,0,55,156,63,1,64,82,74,255,200,53,71,254,239,67,125,0,26,224,222,0,223,137,93,255,30,224,202,255,9,220,132,0,198,38,235,1,102,141,86,0,60,43,81,1,136,28,26,0,233,36,8,254,207,242,148,0,164,162,63,0,51,46,224,255,114,48,79,255,9,175,226,0,222,3,193,255,47,160,232,255,255,93,105,254,14,42,230,0,26,138,82,1,208,43,244,0,27,39,38,255,98,208,127,255,64,149,182,255,5,250,209,0,187,60,28,254,49,25,218,255,169,116,205,255,119,18,120,0,156,116,147,255,132,53,109,255,13,10,202,0,110,83,167,0,157,219,137,255,6,3,130,255,50,167,30,255,60,159,47,255,129,128,157,254,94,3,189,0,3,166,68,0,83,223,215,0,150,90,194,1,15,168,65,0,227,83,51,255,205,171,66,255,54,187,60,1,152,102,45,255,119,154,225,0,240,247,136,0,100,197,178,255,139,71,223,255,204,82,16,1,41,206,42,255,156,192,221,255,216,123,244,255,218,218,185,255,187,186,239,255,252,172,160,255,195,52,22,0,144,174,181,254,187,100,115,255,211,78,176,255,27,7,193,0,147,213,104,255,90,201,10,255,80,123,66,1,22,33,186,0,1,7,99,254,30,206,10,0,229,234,5,0,53,30,210,0,138,8,220,254,71,55,167,0,72,225,86,1,118,190,188,0,254,193,101,1,171,249,172,255,94,158,183,254,93,2,108,255,176,93,76,255,73,99,79,255,74,64,129,254,246,46,65,0,99,241,127,254,246,151,102,255,44,53,208,254,59,102,234,0,154,175,164,255,88,242,32,0,111,38,1,0,255,182,190,255,115,176,15,254,169,60,129,0,122,237,241,0,90,76,63,0,62,74,120,255,122,195,110,0,119,4,178,0,222,242,210,0,130,33,46,254,156,40,41,0,167,146,112,1,49,163,111,255,121,176,235,0,76,207,14,255,3,25,198,1,41,235,213,0,85,36,214,1,49,92,109,255,200,24,30,254,168,236,195,0,145,39,124,1,236,195,149,0,90,36,184,255,67,85,170,255,38,35,26,254,131,124,68,255,239,155,35,255,54,201,164,0,196,22,117,255,49,15,205,0,24,224,29,1,126,113,144,0,117,21,182,0,203,159,141,0,223,135,77,0,176,230,176,255,190,229,215,255,99,37,181,255,51,21,138,255,25,189,89,255,49,48,165,254,152,45,247,0,170,108,222,0,80,202,5,0,27,69,103,254,204,22,129,255,180,252,62,254,210,1,91,255,146,110,254,255,219,162,28,0,223,252,213,1,59,8,33,0,206,16,244,0,129,211,48,0,107,160,208,0,112,59,209,0,109,77,216,254,34,21,185,255,246,99,56,255,179,139,19,255,185,29,50,255,84,89,19,0,74,250,98,255,225,42,200,255,192,217,205,255,210,16,167,0,99,132,95,1,43,230,57,0,254,11,203,255,99,188,63,255,119,193,251,254,80,105,54,0,232,181,189,1,183,69,112,255,208,171,165,255,47,109,180,255,123,83,165,0,146,162,52,255,154,11,4,255,151,227,90,255,146,137,97,254,61,233,41,255,94,42,55,255,108,164,236,0,152,68,254,0,10,140,131,255,10,106,79,254,243,158,137,0,67,178,66,254,177,123,198,255,15,62,34,0,197,88,42,255,149,95,177,255,152,0,198,255,149,254,113,255,225,90,163,255,125,217,247,0,18,17,224,0,128,66,120,254,192,25,9,255,50,221,205,0,49,212,70,0,233,255,164,0,2,209,9,0,221,52,219,254,172,224,244,255,94,56,206,1,242,179,2,255,31,91,164,1,230,46,138,255,189,230,220,0,57,47,61,255,111,11,157,0,177,91,152,0,28,230,98,0,97,87,126,0,198,89,145,255,167,79,107,0,249,77,160,1,29,233,230,255,150,21,86,254,60,11,193,0,151,37,36,254,185,150,243,255,228,212,83,1,172,151,180,0,201,169,155,0,244,60,234,0,142,235,4,1,67,218,60,0,192,113,75,1,116,243,207,255,65,172,155,0,81,30,156,255,80,72,33,254,18,231,109,255,142,107,21,254,125,26,132,255,176,16,59,255,150,201,58,0,206,169,201,0,208,121,226,0,40,172,14,255,150,61,94,255,56,57,156,255,141,60,145,255,45,108,149,255,238,145,155,255,209,85,31,254,192,12,210,0,99,98,93,254,152,16,151,0,225,185,220,0,141,235,44,255,160,172,21,254,71,26,31,255,13,64,93,254,28,56,198,0,177,62,248,1,182,8,241,0,166,101,148,255,78,81,133,255,129,222,215,1,188,169,129,255,232,7,97,0,49,112,60,255,217,229,251,0,119,108,138,0,39,19,123,254,131,49,235,0,132,84,145,0,130,230,148,255,25,74,187,0,5,245,54,255,185,219,241,1,18,194,228,255,241,202,102,0,105,113,202,0,155,235,79,0,21,9,178,255,156,1,239,0,200,148,61,0,115,247,210,255,49,221,135,0,58,189,8,1,35,46,9,0,81,65,5,255,52,158,185,255,125,116,46,255,74,140,13,255,210,92,172,254,147,23,71,0,217,224,253,254,115,108,180,255,145,58,48,254,219,177,24,255,156,255,60,1,154,147,242,0,253,134,87,0,53,75,229,0,48,195,222,255,31,175,50,255,156,210,120,255,208,35,222,255,18,248,179,1,2,10,101,255,157,194,248,255,158,204,101,255,104,254,197,255,79,62,4,0,178,172,101,1,96,146,251,255,65,10,156,0,2,137,165,255,116,4,231,0,242,215,1,0,19,35,29,255,43,161,79,0,59,149,246,1,251,66,176,0,200,33,3,255,80,110,142,255,195,161,17,1,228,56,66,255,123,47,145,254,132,4,164,0,67,174,172,0,25,253,114,0,87,97,87,1,250,220,84,0,96,91,200,255,37,125,59,0,19,65,118,0,161,52,241,255,237,172,6,255,176,191,255,255,1,65,130,254,223,190,230,0,101,253,231,255,146,35,109,0,250,29,77,1,49,0,19,0,123,90,155,1,22,86,32,255,218,213,65,0,111,93,127,0,60,93,169,255,8,127,182,0,17,186,14,254,253,137,246,255,213,25,48,254,76,238,0,255,248,92,70,255,99,224,139,0,184,9,255,1,7,164,208,0,205,131,198,1,87,214,199,0,130,214,95,0,221,149,222,0,23,38,171,254,197,110,213,0,43,115,140,254,215,177,118,0,96,52,66,1,117,158,237,0,14,64,182,255,46,63,174,255,158,95,190,255,225,205,177,255,43,5,142,255,172,99,212,255,244,187,147,0,29,51,153,255,228,116,24,254,30,101,207,0,19,246,150,255,134,231,5,0,125,134,226,1,77,65,98,0,236,130,33,255,5,110,62,0,69,108,127,255,7,113,22,0,145,20,83,254,194,161,231,255,131,181,60,0,217,209,177,255,229,148,212,254,3,131,184,0,117,177,187,1,28,14,31,255,176,102,80,0,50,84,151,255,125,31,54,255,21,157,133,255,19,179,139,1,224,232,26,0,34,117,170,255,167,252,171,255,73,141,206,254,129,250,35,0,72,79,236,1,220,229,20,255,41,202,173,255,99,76,238,255,198,22,224,255,108,198,195,255,36,141,96,1,236,158,59,255,106,100,87,0,110,226,2,0,227,234,222,0,154,93,119,255,74,112,164,255,67,91,2,255,21,145,33,255,102,214,137,255,175,230,103,254,163,246,166,0,93,247,116,254,167,224,28,255,220,2,57,1,171,206,84,0,123,228,17,255,27,120,119,0,119,11,147,1,180,47,225,255,104,200,185,254,165,2,114,0,77,78,212,0,45,154,177,255,24,196,121,254,82,157,182,0,90,16,190,1,12,147,197,0,95,239,152,255,11,235,71,0,86,146,119,255,172,134,214,0,60,131,196,0,161,225,129,0,31,130,120,254,95,200,51,0,105,231,210,255,58,9,148,255,43,168,221,255,124,237,142,0,198,211,50,254,46,245,103,0,164,248,84,0,152,70,208,255,180,117,177,0,70,79,185,0,243,74,32,0,149,156,207,0,197,196,161,1,245,53,239,0,15,93,246,254,139,240,49,255,196,88,36,255,162,38,123,0,128,200,157,1,174,76,103,255,173,169,34,254,216,1,171,255,114,51,17,0,136,228,194,0,110,150,56,254,106,246,159,0,19,184,79,255,150,77,240,255,155,80,162,0,0,53,169,255,29,151,86,0,68,94,16,0,92,7,110,254,98,117,149,255,249,77,230,255,253,10,140,0,214,124,92,254,35,118,235,0,89,48,57,1,22,53,166,0,184,144,61,255,179,255,194,0,214,248,61,254,59,110,246,0,121,21,81,254,166,3,228,0,106,64,26,255,69,232,134,255,242,220,53,254,46,220,85,0,113,149,247,255,97,179,103,255,190,127,11,0,135,209,182,0,95,52,129,1,170,144,206,255,122,200,204,255,168,100,146,0,60,144,149,254,70,60,40,0,122,52,177,255,246,211,101,255,174,237,8,0,7,51,120,0,19,31,173,0,126,239,156,255,143,189,203,0,196,128,88,255,233,133,226,255,30,125,173,255,201,108,50,0,123,100,59,255,254,163,3,1,221,148,181,255,214,136,57,254,222,180,137,255,207,88,54,255,28,33,251,255,67,214,52,1,210,208,100,0,81,170,94,0,145,40,53,0,224,111,231,254,35,28,244,255,226,199,195,254,238,17,230,0,217,217,164,254,169,157,221,0,218,46,162,1,199,207,163,255,108,115,162,1,14,96,187,255,118,60,76,0,184,159,152,0,209,231,71,254,42,164,186,255,186,153,51,254,221,171,182,255,162,142,173,0,235,47,193,0,7,139,16,1,95,164,64,255,16,221,166,0,219,197,16,0,132,29,44,255,100,69,117,255,60,235,88,254,40,81,173,0,71,190,61,255,187,88,157,0,231,11,23,0,237,117,164,0,225,168,223,255,154,114,116,255,163,152,242,1,24,32,170,0,125,98,113,254,168,19,76,0,17,157,220,254,155,52,5,0,19,111,161,255,71,90,252,255,173,110,240,0,10,198,121,255,253,255,240,255,66,123,210,0,221,194,215,254,121,163,17,255,225,7,99,0,190,49,182,0,115,9,133,1,232,26,138,255,213,68,132,0,44,119,122,255,179,98,51,0,149,90,106,0,71,50,230,255,10,153,118,255,177,70,25,0,165,87,205,0,55,138,234,0,238,30,97,0,113,155,207,0,98,153,127,0,34,107,219,254,117,114,172,255,76,180,255,254,242,57,179,255,221,34,172,254,56,162,49,255,83,3,255,255,113,221,189,255,188,25,228,254,16,88,89,255,71,28,198,254,22,17,149,255,243,121,254,255,107,202,99,255,9,206,14,1,220,47,153,0,107,137,39,1,97,49,194,255,149,51,197,254,186,58,11,255,107,43,232,1,200,6,14,255,181,133,65,254,221,228,171,255,123,62,231,1,227,234,179,255,34,189,212,254,244,187,249,0,190,13,80,1,130,89,1,0,223,133,173,0,9,222,198,255,66,127,74,0,167,216,93,255,155,168,198,1,66,145,0,0,68,102,46,1,172,90,154,0,216,128,75,255,160,40,51,0,158,17,27,1,124,240,49,0,236,202,176,255,151,124,192,255,38,193,190,0,95,182,61,0,163,147,124,255,255,165,51,255,28,40,17,254,215,96,78,0,86,145,218,254,31,36,202,255,86,9,5,0,111,41,200,255,237,108,97,0,57,62,44,0,117,184,15,1,45,241,116,0,152,1,220,255,157,165,188,0,250,15,131,1,60,44,125,255,65,220,251,255,75,50,184,0,53,90,128,255,231,80,194,255,136,129,127,1,21,18,187,255,45,58,161,255,71,147,34,0,174,249,11,254,35,141,29,0,239,68,177,255,115,110,58,0,238,190,177,1,87,245,166,255,190,49,247,255,146,83,184,255,173,14,39,255,146,215,104,0,142,223,120,0,149,200,155,255,212,207,145,1,16,181,217,0,173,32,87,255,255,35,181,0,119,223,161,1,200,223,94,255,70,6,186,255,192,67,85,255,50,169,152,0,144,26,123,255,56,243,179,254,20,68,136,0,39,140,188,254,253,208,5,255,200,115,135,1,43,172,229,255,156,104,187,0,151,251,167,0,52,135,23,0,151,153,72,0,147,197,107,254,148,158,5,255,238,143,206,0,126,153,137,255,88,152,197,254,7,68,167,0,252,159,165,255,239,78,54,255,24,63,55,255,38,222,94,0,237,183,12,255,206,204,210,0,19,39,246,254,30,74,231,0,135,108,29,1,179,115,0,0,117,118,116,1,132,6,252,255,145,129,161,1,105,67,141,0,82,37,226,255,238,226,228,255,204,214,129,254,162,123,100,255,185,121,234,0,45,108,231,0,66,8,56,255,132,136,128,0,172,224,66,254,175,157,188,0,230,223,226,254,242,219,69,0,184,14,119,1,82,162,56,0,114,123,20,0,162,103,85,255,49,239,99,254,156,135,215,0,111,255,167,254,39,196,214,0,144,38,79,1,249,168,125,0,155,97,156,255,23,52,219,255,150,22,144,0,44,149,165,255,40,127,183,0,196,77,233,255,118,129,210,255,170,135,230,255,214,119,198,0,233,240,35,0,253,52,7,255,117,102,48,255,21,204,154,255,179,136,177,255,23,2,3,1,149,130,89,255,252,17,159,1,70,60,26,0,144,107,17,0,180,190,60,255,56,182,59,255,110,71,54,255,198,18,129,255,149,224,87,255,223,21,152,255,138,22,182,255,250,156,205,0,236,45,208,255,79,148,242,1,101,70,209,0,103,78,174,0,101,144,172,255,152,136,237,1,191,194,136,0,113,80,125,1,152,4,141,0,155,150,53,255,196,116,245,0,239,114,73,254,19,82,17,255,124,125,234,255,40,52,191,0,42,210,158,255,155,132,165,0,178,5,42,1,64,92,40,255,36,85,77,255,178,228,118,0,137,66,96,254,115,226,66,0,110,240,69,254,151,111,80,0,167,174,236,255,227,108,107,255,188,242,65,255,183,81,255,0,57,206,181,255,47,34,181,255,213,240,158,1,71,75,95,0,156,40,24,255,102,210,81,0,171,199,228,255,154,34,41,0,227,175,75,0,21,239,195,0,138,229,95,1,76,192,49,0,117,123,87,1,227,225,130,0,125,62,63,255,2,198,171,0,254,36,13,254,145,186,206,0,148,255,244,255,35,0,166,0,30,150,219,1,92,228,212,0,92,198,60,254,62,133,200,255,201,41,59,0,125,238,109,255,180,163,238,1,140,122,82,0,9,22,88,255,197,157,47,255,153,94,57,0,88,30,182,0,84,161,85,0,178,146,124,0,166,166,7,255,21,208,223,0,156,182,242,0,155,121,185,0,83,156,174,254,154,16,118,255,186,83,232,1,223,58,121,255,29,23,88,0,35,125,127,255,170,5,149,254,164,12,130,255,155,196,29,0,161,96,136,0,7,35,29,1,162,37,251,0,3,46,242,255,0,217,188,0,57,174,226,1,206,233,2,0,57,187,136,254,123,189,9,255,201,117,127,255,186,36,204,0,231,25,216,0,80,78,105,0,19,134,129,255,148,203,68,0,141,81,125,254,248,165,200,255,214,144,135,0,151,55,166,255,38,235,91,0,21,46,154,0,223,254,150,255,35,153,180,255,125,176,29,1,43,98,30,255,216,122,230,255,233,160,12,0,57,185,12,254,240,113,7,255,5,9,16,254,26,91,108,0,109,198,203,0,8,147,40,0,129,134,228,255,124,186,40,255,114,98,132,254,166,132,23,0,99,69,44,0,9,242,238,255,184,53,59,0,132,129,102,255,52,32,243,254,147,223,200,255,123,83,179,254,135,144,201,255,141,37,56,1,151,60,227,255,90,73,156,1,203,172,187,0,80,151,47,255,94,137,231,255,36,191,59,255,225,209,181,255,74,215,213,254,6,118,179,255,153,54,193,1,50,0,231,0,104,157,72,1,140,227,154,255,182,226,16,254,96,225,92,255,115,20,170,254,6,250,78,0,248,75,173,255,53,89,6,255,0,180,118,0,72,173,1,0,64,8,206,1,174,133,223,0,185,62,133,255,214,11,98,0,197,31,208,0,171,167,244,255,22,231,181,1,150,218,185,0,247,169,97,1,165,139,247,255,47,120,149,1,103,248,51,0,60,69,28,254,25,179,196,0,124,7,218,254,58,107,81,0,184,233,156,255,252,74,36,0,118,188,67,0,141,95,53,255,222,94,165,254,46,61,53,0,206,59,115,255,47,236,250,255,74,5,32,1,129,154,238,255,106,32,226,0,121,187,61,255,3,166,241,254,67,170,172,255,29,216,178,255,23,201,252,0,253,110,243,0,200,125,57,0,109,192,96,255,52,115,238,0,38,121,243,255,201,56,33,0,194,118,130,0,75,96,25,255,170,30,230,254,39,63,253,0,36,45,250,255,251,1,239,0,160,212,92,1,45,209,237,0,243,33,87,254,237,84,201,255,212,18,157,254,212,99,127,255,217,98,16,254,139,172,239,0,168,201,130,255,143,193,169,255,238,151,193,1,215,104,41,0,239,61,165,254,2,3,242,0,22,203,177,254,177,204,22,0,149,129,213,254,31,11,41,255,0,159,121,254,160,25,114,255,162,80,200,0,157,151,11,0,154,134,78,1,216,54,252,0,48,103,133,0,105,220,197,0,253,168,77,254,53,179,23,0,24,121,240,1,255,46,96,255,107,60,135,254,98,205,249,255,63,249,119,255,120,59,211,255,114,180,55,254,91,85,237,0,149,212,77,1,56,73,49,0,86,198,150,0,93,209,160,0,69,205,182,255,244,90,43,0,20,36,176,0,122,116,221,0,51,167,39,1,231,1,63,255,13,197,134,0,3,209,34,255,135,59,202,0,167,100,78,0,47,223,76,0,185,60,62,0,178,166,123,1,132,12,161,255,61,174,43,0,195,69,144,0,127,47,191,1,34,44,78,0,57,234,52,1,255,22,40,255,246,94,146,0,83,228,128,0,60,78,224,255,0,96,210,255,153,175,236,0,159,21,73,0,180,115,196,254,131,225,106,0,255,167,134,0,159,8,112,255,120,68,194,255,176,196,198,255,118,48,168,255,93,169,1,0,112,200,102,1,74,24,254,0,19,141,4,254,142,62,63,0,131,179,187,255,77,156,155,255,119,86,164,0,170,208,146,255,208,133,154,255,148,155,58,255,162,120,232,254,252,213,155,0,241,13,42,0,94,50,131,0,179,170,112,0,140,83,151,255,55,119,84,1,140,35,239,255,153,45,67,1,236,175,39,0,54,151,103,255,158,42,65,255,196,239,135,254,86,53,203,0,149,97,47,254,216,35,17,255,70,3,70,1,103,36,90,255,40,26,173,0,184,48,13,0,163,219,217,255,81,6,1,255,221,170,108,254,233,208,93,0,100,201,249,254,86,36,35,255,209,154,30,1,227,201,251,255,2,189,167,254,100,57,3,0,13,128,41,0,197,100,75,0,150,204,235,255,145,174,59,0,120,248,149,255,85,55,225,0,114,210,53,254,199,204,119,0,14,247,74,1,63,251,129,0,67,104,151,1,135,130,80,0,79,89,55,255,117,230,157,255,25,96,143,0,213,145,5,0,69,241,120,1,149,243,95,255,114,42,20,0,131,72,2,0,154,53,20,255,73,62,109,0,196,102,152,0,41,12,204,255,122,38,11,1,250,10,145,0,207,125,148,0,246,244,222,255,41,32,85,1,112,213,126,0,162,249,86,1,71,198,127,255,81,9,21,1,98,39,4,255,204,71,45,1,75,111,137,0,234,59,231,0,32,48,95,255,204,31,114,1,29,196,181,255,51,241,167,254,93,109,142,0,104,144,45,0,235,12,181,255,52,112,164,0,76,254,202,255,174,14,162,0,61,235,147,255,43,64,185,254,233,125,217,0,243,88,167,254,74,49,8,0,156,204,66,0,124,214,123,0,38,221,118,1,146,112,236,0,114,98,177,0,151,89,199,0,87,197,112,0,185,149,161,0,44,96,165,0,248,179,20,255,188,219,216,254,40,62,13,0,243,142,141,0,229,227,206,255,172,202,35,255,117,176,225,255,82,110,38,1,42,245,14,255,20,83,97,0,49,171,10,0,242,119,120,0,25,232,61,0,212,240,147,255,4,115,56,255,145,17,239,254,202,17,251,255,249,18,245,255,99,117,239,0,184,4,179,255,246,237,51,255,37,239,137,255,166,112,166,255,81,188,33,255,185,250,142,255,54,187,173,0,208,112,201,0,246,43,228,1,104,184,88,255,212,52,196,255,51,117,108,255,254,117,155,0,46,91,15,255,87,14,144,255,87,227,204,0,83,26,83,1,159,76,227,0,159,27,213,1,24,151,108,0,117,144,179,254,137,209,82,0,38,159,10,0,115,133,201,0,223,182,156,1,110,196,93,255,57,60,233,0,5,167,105,255,154,197,164,0,96,34,186,255,147,133,37,1,220,99,190,0,1,167,84,255,20,145,171,0,194,197,251,254,95,78,133,255,252,248,243,255,225,93,131,255,187,134,196,255,216,153,170,0,20,118,158,254,140,1,118,0,86,158,15,1,45,211,41,255,147,1,100,254,113,116,76,255,211,127,108,1,103,15,48,0,193,16,102,1,69,51,95,255,107,128,157,0,137,171,233,0,90,124,144,1,106,161,182,0,175,76,236,1,200,141,172,255,163,58,104,0,233,180,52,255,240,253,14,255,162,113,254,255,38,239,138,254,52,46,166,0,241,101,33,254,131,186,156,0,111,208,62,255,124,94,160,255,31,172,254,0,112,174,56,255,188,99,27,255,67,138,251,0,125,58,128,1,156,152,174,255,178,12,247,255,252,84,158,0,82,197,14,254,172,200,83,255,37,39,46,1,106,207,167,0,24,189,34,0,131,178,144,0,206,213,4,0,161,226,210,0,72,51,105,255,97,45,187,255,78,184,223,255,176,29,251,0,79,160,86,255,116,37,178,0,82,77,213,1,82,84,141,255,226,101,212,1,175,88,199,255,245,94,247,1,172,118,109,255,166,185,190,0,131,181,120,0,87,254,93,255,134,240,73,255,32,245,143,255,139,162,103,255,179,98,18,254,217,204,112,0,147,223,120,255,53,10,243,0,166,140,150,0,125,80,200,255,14,109,219,255,91,218,1,255,252,252,47,254,109,156,116,255,115,49,127,1,204,87,211,255,148,202,217,255,26,85,249,255,14,245,134,1,76,89,169,255,242,45,230,0,59,98,172,255,114,73,132,254,78,155,49,255,158,126,84,0,49,175,43,255,16,182,84,255,157,103,35,0,104,193,109,255,67,221,154],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+10240);allocate([201,172,1,254,8,162,88,0,165,1,29,255,125,155,229,255,30,154,220,1,103,239,92,0,220,1,109,255,202,198,1,0,94,2,142,1,36,54,44,0,235,226,158,255,170,251,214,255,185,77,9,0,97,74,242,0,219,163,149,255,240,35,118,255,223,114,88,254,192,199,3,0,106,37,24,255,201,161,118,255,97,89,99,1,224,58,103,255,101,199,147,254,222,60,99,0,234,25,59,1,52,135,27,0,102,3,91,254,168,216,235,0,229,232,136,0,104,60,129,0,46,168,238,0,39,191,67,0,75,163,47,0,143,97,98,255,56,216,168,1,168,233,252,255,35,111,22,255,92,84,43,0,26,200,87,1,91,253,152,0,202,56,70,0,142,8,77,0,80,10,175,1,252,199,76,0,22,110,82,255,129,1,194,0,11,128,61,1,87,14,145,255,253,222,190,1,15,72,174,0,85,163,86,254,58,99,44,255,45,24,188,254,26,205,15,0,19,229,210,254,248,67,195,0,99,71,184,0,154,199,37,255,151,243,121,255,38,51,75,255,201,85,130,254,44,65,250,0,57,147,243,254,146,43,59,255,89,28,53,0,33,84,24,255,179,51,18,254,189,70,83,0,11,156,179,1,98,134,119,0,158,111,111,0,119,154,73,255,200,63,140,254,45,13,13,255,154,192,2,254,81,72,42,0,46,160,185,254,44,112,6,0,146,215,149,1,26,176,104,0,68,28,87,1,236,50,153,255,179,128,250,254,206,193,191,255,166,92,137,254,53,40,239,0,210,1,204,254,168,173,35,0,141,243,45,1,36,50,109,255,15,242,194,255,227,159,122,255,176,175,202,254,70,57,72,0,40,223,56,0,208,162,58,255,183,98,93,0,15,111,12,0,30,8,76,255,132,127,246,255,45,242,103,0,69,181,15,255,10,209,30,0,3,179,121,0,241,232,218,1,123,199,88,255,2,210,202,1,188,130,81,255,94,101,208,1,103,36,45,0,76,193,24,1,95,26,241,255,165,162,187,0,36,114,140,0,202,66,5,255,37,56,147,0,152,11,243,1,127,85,232,255,250,135,212,1,185,177,113,0,90,220,75,255,69,248,146,0,50,111,50,0,92,22,80,0,244,36,115,254,163,100,82,255,25,193,6,1,127,61,36,0,253,67,30,254,65,236,170,255,161,17,215,254,63,175,140,0,55,127,4,0,79,112,233,0,109,160,40,0,143,83,7,255,65,26,238,255,217,169,140,255,78,94,189,255,0,147,190,255,147,71,186,254,106,77,127,255,233,157,233,1,135,87,237,255,208,13,236,1,155,109,36,255,180,100,218,0,180,163,18,0,190,110,9,1,17,63,123,255,179,136,180,255,165,123,123,255,144,188,81,254,71,240,108,255,25,112,11,255,227,218,51,255,167,50,234,255,114,79,108,255,31,19,115,255,183,240,99,0,227,87,143,255,72,217,248,255,102,169,95,1,129,149,149,0,238,133,12,1,227,204,35,0,208,115,26,1,102,8,234,0,112,88,143,1,144,249,14,0,240,158,172,254,100,112,119,0,194,141,153,254,40,56,83,255,121,176,46,0,42,53,76,255,158,191,154,0,91,209,92,0,173,13,16,1,5,72,226,255,204,254,149,0,80,184,207,0,100,9,122,254,118,101,171,255,252,203,0,254,160,207,54,0,56,72,249,1,56,140,13,255,10,64,107,254,91,101,52,255,225,181,248,1,139,255,132,0,230,145,17,0,233,56,23,0,119,1,241,255,213,169,151,255,99,99,9,254,185,15,191,255,173,103,109,1,174,13,251,255,178,88,7,254,27,59,68,255,10,33,2,255,248,97,59,0,26,30,146,1,176,147,10,0,95,121,207,1,188,88,24,0,185,94,254,254,115,55,201,0,24,50,70,0,120,53,6,0,142,66,146,0,228,226,249,255,104,192,222,1,173,68,219,0,162,184,36,255,143,102,137,255,157,11,23,0,125,45,98,0,235,93,225,254,56,112,160,255,70,116,243,1,153,249,55,255,129,39,17,1,241,80,244,0,87,69,21,1,94,228,73,255,78,66,65,255,194,227,231,0,61,146,87,255,173,155,23,255,112,116,219,254,216,38,11,255,131,186,133,0,94,212,187,0,100,47,91,0,204,254,175,255,222,18,215,254,173,68,108,255,227,228,79,255,38,221,213,0,163,227,150,254,31,190,18,0,160,179,11,1,10,90,94,255,220,174,88,0,163,211,229,255,199,136,52,0,130,95,221,255,140,188,231,254,139,113,128,255,117,171,236,254,49,220,20,255,59,20,171,255,228,109,188,0,20,225,32,254,195,16,174,0,227,254,136,1,135,39,105,0,150,77,206,255,210,238,226,0,55,212,132,254,239,57,124,0,170,194,93,255,249,16,247,255,24,151,62,255,10,151,10,0,79,139,178,255,120,242,202,0,26,219,213,0,62,125,35,255,144,2,108,255,230,33,83,255,81,45,216,1,224,62,17,0,214,217,125,0,98,153,153,255,179,176,106,254,131,93,138,255,109,62,36,255,178,121,32,255,120,252,70,0,220,248,37,0,204,88,103,1,128,220,251,255,236,227,7,1,106,49,198,255,60,56,107,0,99,114,238,0,220,204,94,1,73,187,1,0,89,154,34,0,78,217,165,255,14,195,249,255,9,230,253,255,205,135,245,0,26,252,7,255,84,205,27,1,134,2,112,0,37,158,32,0,231,91,237,255,191,170,204,255,152,7,222,0,109,192,49,0,193,166,146,255,232,19,181,255,105,142,52,255,103,16,27,1,253,200,165,0,195,217,4,255,52,189,144,255,123,155,160,254,87,130,54,255,78,120,61,255,14,56,41,0,25,41,125,255,87,168,245,0,214,165,70,0,212,169,6,255,219,211,194,254,72,93,164,255,197,33,103,255,43,142,141,0,131,225,172,0,244,105,28,0,68,68,225,0,136,84,13,255,130,57,40,254,139,77,56,0,84,150,53,0,54,95,157,0,144,13,177,254,95,115,186,0,117,23,118,255,244,166,241,255,11,186,135,0,178,106,203,255,97,218,93,0,43,253,45,0,164,152,4,0,139,118,239,0,96,1,24,254,235,153,211,255,168,110,20,255,50,239,176,0,114,41,232,0,193,250,53,0,254,160,111,254,136,122,41,255,97,108,67,0,215,152,23,255,140,209,212,0,42,189,163,0,202,42,50,255,106,106,189,255,190,68,217,255,233,58,117,0,229,220,243,1,197,3,4,0,37,120,54,254,4,156,134,255,36,61,171,254,165,136,100,255,212,232,14,0,90,174,10,0,216,198,65,255,12,3,64,0,116,113,115,255,248,103,8,0,231,125,18,255,160,28,197,0,30,184,35,1,223,73,249,255,123,20,46,254,135,56,37,255,173,13,229,1,119,161,34,255,245,61,73,0,205,125,112,0,137,104,134,0,217,246,30,255,237,142,143,0,65,159,102,255,108,164,190,0,219,117,173,255,34,37,120,254,200,69,80,0,31,124,218,254,74,27,160,255,186,154,199,255,71,199,252,0,104,81,159,1,17,200,39,0,211,61,192,1,26,238,91,0,148,217,12,0,59,91,213,255,11,81,183,255,129,230,122,255,114,203,145,1,119,180,66,255,72,138,180,0,224,149,106,0,119,82,104,255,208,140,43,0,98,9,182,255,205,101,134,255,18,101,38,0,95,197,166,255,203,241,147,0,62,208,145,255,133,246,251,0,2,169,14,0,13,247,184,0,142,7,254,0,36,200,23,255,88,205,223,0,91,129,52,255,21,186,30,0,143,228,210,1,247,234,248,255,230,69,31,254,176,186,135,255,238,205,52,1,139,79,43,0,17,176,217,254,32,243,67,0,242,111,233,0,44,35,9,255,227,114,81,1,4,71,12,255,38,105,191,0,7,117,50,255,81,79,16,0,63,68,65,255,157,36,110,255,77,241,3,255,226,45,251,1,142,25,206,0,120,123,209,1,28,254,238,255,5,128,126,255,91,222,215,255,162,15,191,0,86,240,73,0,135,185,81,254,44,241,163,0,212,219,210,255,112,162,155,0,207,101,118,0,168,72,56,255,196,5,52,0,72,172,242,255,126,22,157,255,146,96,59,255,162,121,152,254,140,16,95,0,195,254,200,254,82,150,162,0,119,43,145,254,204,172,78,255,166,224,159,0,104,19,237,255,245,126,208,255,226,59,213,0,117,217,197,0,152,72,237,0,220,31,23,254,14,90,231,255,188,212,64,1,60,101,246,255,85,24,86,0,1,177,109,0,146,83,32,1,75,182,192,0,119,241,224,0,185,237,27,255,184,101,82,1,235,37,77,255,253,134,19,0,232,246,122,0,60,106,179,0,195,11,12,0,109,66,235,1,125,113,59,0,61,40,164,0,175,104,240,0,2,47,187,255,50,12,141,0,194,139,181,255,135,250,104,0,97,92,222,255,217,149,201,255,203,241,118,255,79,151,67,0,122,142,218,255,149,245,239,0,138,42,200,254,80,37,97,255,124,112,167,255,36,138,87,255,130,29,147,255,241,87,78,255,204,97,19,1,177,209,22,255,247,227,127,254,99,119,83,255,212,25,198,1,16,179,179,0,145,77,172,254,89,153,14,255,218,189,167,0,107,233,59,255,35,33,243,254,44,112,112,255,161,127,79,1,204,175,10,0,40,21,138,254,104,116,228,0,199,95,137,255,133,190,168,255,146,165,234,1,183,99,39,0,183,220,54,254,255,222,133,0,162,219,121,254,63,239,6,0,225,102,54,255,251,18,246,0,4,34,129,1,135,36,131,0,206,50,59,1,15,97,183,0,171,216,135,255,101,152,43,255,150,251,91,0,38,145,95,0,34,204,38,254,178,140,83,255,25,129,243,255,76,144,37,0,106,36,26,254,118,144,172,255,68,186,229,255,107,161,213,255,46,163,68,255,149,170,253,0,187,17,15,0,218,160,165,255,171,35,246,1,96,13,19,0,165,203,117,0,214,107,192,255,244,123,177,1,100,3,104,0,178,242,97,255,251,76,130,255,211,77,42,1,250,79,70,255,63,244,80,1,105,101,246,0,61,136,58,1,238,91,213,0,14,59,98,255,167,84,77,0,17,132,46,254,57,175,197,255,185,62,184,0,76,64,207,0,172,175,208,254,175,74,37,0,138,27,211,254,148,125,194,0,10,89,81,0,168,203,101,255,43,213,209,1,235,245,54,0,30,35,226,255,9,126,70,0,226,125,94,254,156,117,20,255,57,248,112,1,230,48,64,255,164,92,166,1,224,214,230,255,36,120,143,0,55,8,43,255,251,1,245,1,106,98,165,0,74,107,106,254,53,4,54,255,90,178,150,1,3,120,123,255,244,5,89,1,114,250,61,255,254,153,82,1,77,15,17,0,57,238,90,1,95,223,230,0,236,52,47,254,103,148,164,255,121,207,36,1,18,16,185,255,75,20,74,0,187,11,101,0,46,48,129,255,22,239,210,255,77,236,129,255,111,77,204,255,61,72,97,255,199,217,251,255,42,215,204,0,133,145,201,255,57,230,146,1,235,100,198,0,146,73,35,254,108,198,20,255,182,79,210,255,82,103,136,0,246,108,176,0,34,17,60,255,19,74,114,254,168,170,78,255,157,239,20,255,149,41,168,0,58,121,28,0,79,179,134,255,231,121,135,255,174,209,98,255,243,122,190,0,171,166,205,0,212,116,48,0,29,108,66,255,162,222,182,1,14,119,21,0,213,39,249,255,254,223,228,255,183,165,198,0,133,190,48,0,124,208,109,255,119,175,85,255,9,209,121,1,48,171,189,255,195,71,134,1,136,219,51,255,182,91,141,254,49,159,72,0,35,118,245,255,112,186,227,255,59,137,31,0,137,44,163,0,114,103,60,254,8,213,150,0,162,10,113,255,194,104,72,0,220,131,116,255,178,79,92,0,203,250,213,254,93,193,189,255,130,255,34,254,212,188,151,0,136,17,20,255,20,101,83,255,212,206,166,0,229,238,73,255,151,74,3,255,168,87,215,0,155,188,133,255,166,129,73,0,240,79,133,255,178,211,81,255,203,72,163,254,193,168,165,0,14,164,199,254,30,255,204,0,65,72,91,1,166,74,102,255,200,42,0,255,194,113,227,255,66,23,208,0,229,216,100,255,24,239,26,0,10,233,62,255,123,10,178,1,26,36,174,255,119,219,199,1,45,163,190,0,16,168,42,0,166,57,198,255,28,26,26,0,126,165,231,0,251,108,100,255,61,229,121,255,58,118,138,0,76,207,17,0,13,34,112,254,89,16,168,0,37,208,105,255,35,201,215,255,40,106,101,254,6,239,114,0,40,103,226,254,246,127,110,255,63,167,58,0,132,240,142,0,5,158,88,255,129,73,158,255,94,89,146,0,230,54,146,0,8,45,173,0,79,169,1,0,115,186,247,0,84,64,131,0,67,224,253,255,207,189,64,0,154,28,81,1,45,184,54,255,87,212,224,255,0,96,73,255,129,33,235,1,52,66,80,255,251,174,155,255,4,179,37,0,234,164,93,254,93,175,253,0,198,69,87,255,224,106,46,0,99,29,210,0,62,188,114,255,44,234,8,0,169,175,247,255,23,109,137,255,229,182,39,0,192,165,94,254,245,101,217,0,191,88,96,0,196,94,99,255,106,238,11,254,53,126,243,0,94,1,101,255,46,147,2,0,201,124,124,255,141,12,218,0,13,166,157,1,48,251,237,255,155,250,124,255,106,148,146,255,182,13,202,0,28,61,167,0,217,152,8,254,220,130,45,255,200,230,255,1,55,65,87,255,93,191,97,254,114,251,14,0,32,105,92,1,26,207,141,0,24,207,13,254,21,50,48,255,186,148,116,255,211,43,225,0,37,34,162,254,164,210,42,255,68,23,96,255,182,214,8,255,245,117,137,255,66,195,50,0,75,12,83,254,80,140,164,0,9,165,36,1,228,110,227,0,241,17,90,1,25,52,212,0,6,223,12,255,139,243,57,0,12,113,75,1,246,183,191,255,213,191,69,255,230,15,142,0,1,195,196,255,138,171,47,255,64,63,106,1,16,169,214,255,207,174,56,1,88,73,133,255,182,133,140,0,177,14,25,255,147,184,53,255,10,227,161,255,120,216,244,255,73,77,233,0,157,238,139,1,59,65,233,0,70,251,216,1,41,184,153,255,32,203,112,0,146,147,253,0,87,101,109,1,44,82,133,255,244,150,53,255,94,152,232,255,59,93,39,255,88,147,220,255,78,81,13,1,32,47,252,255,160,19,114,255,93,107,39,255,118,16,211,1,185,119,209,255,227,219,127,254,88,105,236,255,162,110,23,255,36,166,110,255,91,236,221,255,66,234,116,0,111,19,244,254,10,233,26,0,32,183,6,254,2,191,242,0,218,156,53,254,41,60,70,255,168,236,111,0,121,185,126,255,238,142,207,255,55,126,52,0,220,129,208,254,80,204,164,255,67,23,144,254,218,40,108,255,127,202,164,0,203,33,3,255,2,158,0,0,37,96,188,255,192,49,74,0,109,4,0,0,111,167,10,254,91,218,135,255,203,66,173,255,150,194,226,0,201,253,6,255,174,102,121,0,205,191,110,0,53,194,4,0,81,40,45,254,35,102,143,255,12,108,198,255,16,27,232,255,252,71,186,1,176,110,114,0,142,3,117,1,113,77,142,0,19,156,197,1,92,47,252,0,53,232,22,1,54,18,235,0,46,35,189,255,236,212,129,0,2,96,208,254,200,238,199,255,59,175,164,255,146,43,231,0,194,217,52,255,3,223,12,0,138,54,178,254,85,235,207,0,232,207,34,0,49,52,50,255,166,113,89,255,10,45,216,255,62,173,28,0,111,165,246,0,118,115,91,255,128,84,60,0,167,144,203,0,87,13,243,0,22,30,228,1,177,113,146,255,129,170,230,254,252,153,129,255,145,225,43,0,70,231,5,255,122,105,126,254,86,246,148,255,110,37,154,254,209,3,91,0,68,145,62,0,228,16,165,255,55,221,249,254,178,210,91,0,83,146,226,254,69,146,186,0,93,210,104,254,16,25,173,0,231,186,38,0,189,122,140,255,251,13,112,255,105,110,93,0,251,72,170,0,192,23,223,255,24,3,202,1,225,93,228,0,153,147,199,254,109,170,22,0,248,101,246,255,178,124,12,255,178,254,102,254,55,4,65,0,125,214,180,0,183,96,147,0,45,117,23,254,132,191,249,0,143,176,203,254,136,183,54,255,146,234,177,0,146,101,86,255,44,123,143,1,33,209,152,0,192,90,41,254,83,15,125,255,213,172,82,0,215,169,144,0,16,13,34,0,32,209,100,255,84,18,249,1,197,17,236,255,217,186,230,0,49,160,176,255,111,118,97,255,237,104,235,0,79,59,92,254,69,249,11,255,35,172,74,1,19,118,68,0,222,124,165,255,180,66,35,255,86,174,246,0,43,74,111,255,126,144,86,255,228,234,91,0,242,213,24,254,69,44,235,255,220,180,35,0,8,248,7,255,102,47,92,255,240,205,102,255,113,230,171,1,31,185,201,255,194,246,70,255,122,17,187,0,134,70,199,255,149,3,150,255,117,63,103,0,65,104,123,255,212,54,19,1,6,141,88,0,83,134,243,255,136,53,103,0,169,27,180,0,177,49,24,0,111,54,167,0,195,61,215,255,31,1,108,1,60,42,70,0,185,3,162,255,194,149,40,255,246,127,38,254,190,119,38,255,61,119,8,1,96,161,219,255,42,203,221,1,177,242,164,255,245,159,10,0,116,196,0,0,5,93,205,254,128,127,179,0,125,237,246,255,149,162,217,255,87,37,20,254,140,238,192,0,9,9,193,0,97,1,226,0,29,38,10,0,0,136,63,255,229,72,210,254,38,134,92,255,78,218,208,1,104,36,84,255,12,5,193,255,242,175,61,255,191,169,46,1,179,147,147,255,113,190,139,254,125,172,31,0,3,75,252,254,215,36,15,0,193,27,24,1,255,69,149,255,110,129,118,0,203,93,249,0,138,137,64,254,38,70,6,0,153,116,222,0,161,74,123,0,193,99,79,255,118,59,94,255,61,12,43,1,146,177,157,0,46,147,191,0,16,255,38,0,11,51,31,1,60,58,98,255,111,194,77,1,154,91,244,0,140,40,144,1,173,10,251,0,203,209,50,254,108,130,78,0,228,180,90,0,174,7,250,0,31,174,60,0,41,171,30,0,116,99,82,255,118,193,139,255,187,173,198,254,218,111,56,0,185,123,216,0,249,158,52,0,52,180,93,255,201,9,91,255,56,45,166,254,132,155,203,255,58,232,110,0,52,211,89,255,253,0,162,1,9,87,183,0,145,136,44,1,94,122,245,0,85,188,171,1,147,92,198,0,0,8,104,0,30,95,174,0,221,230,52,1,247,247,235,255,137,174,53,255,35,21,204,255,71,227,214,1,232,82,194,0,11,48,227,255,170,73,184,255,198,251,252,254,44,112,34,0,131,101,131,255,72,168,187,0,132,135,125,255,138,104,97,255,238,184,168,255,243,104,84,255,135,216,226,255,139,144,237,0,188,137,150,1,80,56,140,255,86,169,167,255,194,78,25,255,220,17,180,255,17,13,193,0,117,137,212,255,141,224,151,0,49,244,175,0,193,99,175,255,19,99,154,1,255,65,62,255,156,210,55,255,242,244,3,255,250,14,149,0,158,88,217,255,157,207,134,254,251,232,28,0,46,156,251,255,171,56,184,255,239,51,234,0,142,138,131,255,25,254,243,1,10,201,194,0,63,97,75,0,210,239,162,0,192,200,31,1,117,214,243,0,24,71,222,254,54,40,232,255,76,183,111,254,144,14,87,255,214,79,136,255,216,196,212,0,132,27,140,254,131,5,253,0,124,108,19,255,28,215,75,0,76,222,55,254,233,182,63,0,68,171,191,254,52,111,222,255,10,105,77,255,80,170,235,0,143,24,88,255,45,231,121,0,148,129,224,1,61,246,84,0,253,46,219,255,239,76,33,0,49,148,18,254,230,37,69,0,67,134,22,254,142,155,94,0,31,157,211,254,213,42,30,255,4,228,247,254,252,176,13,255,39,0,31,254,241,244,255,255,170,45,10,254,253,222,249,0,222,114,132,0,255,47,6,255,180,163,179,1,84,94,151,255,89,209,82,254,229,52,169,255,213,236,0,1,214,56,228,255,135,119,151,255,112,201,193,0,83,160,53,254,6,151,66,0,18,162,17,0,233,97,91,0,131,5,78,1,181,120,53,255,117,95,63,255,237,117,185,0,191,126,136,255,144,119,233,0,183,57,97,1,47,201,187,255,167,165,119,1,45,100,126,0,21,98,6,254,145,150,95,255,120,54,152,0,209,98,104,0,143,111,30,254,184,148,249,0,235,216,46,0,248,202,148,255,57,95,22,0,242,225,163,0,233,247,232,255,71,171,19,255,103,244,49,255,84,103,93,255,68,121,244,1,82,224,13,0,41,79,43,255,249,206,167,255,215,52,21,254,192,32,22,255,247,111,60,0,101,74,38,255,22,91,84,254,29,28,13,255,198,231,215,254,244,154,200,0,223,137,237,0,211,132,14,0,95,64,206,255,17,62,247,255,233,131,121,1,93,23,77,0,205,204,52,254,81,189,136,0,180,219,138,1,143,18,94,0,204,43,140,254,188,175,219,0,111,98,143,255,151,63,162,255,211,50,71,254,19,146,53,0,146,45,83,254,178,82,238,255,16,133,84,255,226,198,93,255,201,97,20,255,120,118,35,255,114,50,231,255,162,229,156,255,211,26,12,0,114,39,115,255,206,212,134,0,197,217,160,255,116,129,94,254,199,215,219,255,75,223,249,1,253,116,181,255,232,215,104,255,228,130,246,255,185,117,86,0,14,5,8,0,239,29,61,1,237,87,133,255,125,146,137,254,204,168,223,0,46,168,245,0,154,105,22,0,220,212,161,255,107,69,24,255,137,218,181,255,241,84,198,255,130,122,211,255,141,8,153,255,190,177,118,0,96,89,178,0,255,16,48,254,122,96,105,255,117,54,232,255,34,126,105,255,204,67,166,0,232,52,138,255,211,147,12,0,25,54,7,0,44,15,215,254,51,236,45,0,190,68,129,1,106,147,225,0,28,93,45,254,236,141,15,255,17,61,161,0,220,115,192,0,236,145,24,254,111,168,169,0,224,58,63,255,127,164,188,0,82,234,75,1,224,158,134,0,209,68,110,1,217,166,217,0,70,225,166,1,187,193,143,255,16,7,88,255,10,205,140,0,117,192,156,1,17,56,38,0,27,124,108,1,171,215,55,255,95,253,212,0,155,135,168,255,246,178,153,254,154,68,74,0,232,61,96,254,105,132,59,0,33,76,199,1,189,176,130,255,9,104,25,254,75,198,102,255,233,1,112,0,108,220,20,255,114,230,70,0,140,194,133,255,57,158,164,254,146,6,80,255,169,196,97,1,85,183,130,0,70,158,222,1,59,237,234,255,96,25,26,255,232,175,97,255,11,121,248,254,88,35,194,0,219,180,252,254,74,8,227,0,195,227,73,1,184,110,161,255,49,233,164,1,128,53,47,0,82,14,121,255,193,190,58,0,48,174,117,255,132,23,32,0,40,10,134,1,22,51,25,255,240,11,176,255,110,57,146,0,117,143,239,1,157,101,118,255,54,84,76,0,205,184,18,255,47,4,72,255,78,112,85,255,193,50,66,1,93,16,52,255,8,105,134,0,12,109,72,255,58,156,251,0,144,35,204,0,44,160,117,254,50,107,194,0,1,68,165,255,111,110,162,0,158,83,40,254,76,214,234,0,58,216,205,255,171,96,147,255,40,227,114,1,176,227,241,0,70,249,183,1,136,84,139,255,60,122,247,254,143,9,117,255,177,174,137,254,73,247,143,0,236,185,126,255,62,25,247,255,45,64,56,255,161,244,6,0,34,57,56,1,105,202,83,0,128,147,208,0,6,103,10,255,74,138,65,255,97,80,100,255,214,174,33,255,50,134,74,255,110,151,130,254,111,84,172,0,84,199,75,254,248,59,112,255,8,216,178,1,9,183,95,0,238,27,8,254,170,205,220,0,195,229,135,0,98,76,237,255,226,91,26,1,82,219,39,255,225,190,199,1,217,200,121,255,81,179,8,255,140,65,206,0,178,207,87,254,250,252,46,255,104,89,110,1,253,189,158,255,144,214,158,255,160,245,54,255,53,183,92,1,21,200,194,255,146,33,113,1,209,1,255,0,235,106,43,255,167,52,232,0,157,229,221,0,51,30,25,0,250,221,27,1,65,147,87,255,79,123,196,0,65,196,223,255,76,44,17,1,85,241,68,0,202,183,249,255,65,212,212,255,9,33,154,1,71,59,80,0,175,194,59,255,141,72,9,0,100,160,244,0,230,208,56,0,59,25,75,254,80,194,194,0,18,3,200,254,160,159,115,0,132,143,247,1,111,93,57,255,58,237,11,1,134,222,135,255,122,163,108,1,123,43,190,255,251,189,206,254,80,182,72,255,208,246,224,1,17,60,9,0,161,207,38,0,141,109,91,0,216,15,211,255,136,78,110,0,98,163,104,255,21,80,121,255,173,178,183,1,127,143,4,0,104,60,82,254,214,16,13,255,96,238,33,1,158,148,230,255,127,129,62,255,51,255,210,255,62,141,236,254,157,55,224,255,114,39,244,0,192,188,250,255,228,76,53,0,98,84,81,255,173,203,61,254,147,50,55,255,204,235,191,0,52,197,244,0,88,43,211,254,27,191,119,0,188,231,154,0,66,81,161,0,92,193,160,1,250,227,120,0,123,55,226,0,184,17,72,0,133,168,10,254,22,135,156,255,41,25,103,255,48,202,58,0,186,149,81,255,188,134,239,0,235,181,189,254,217,139,188,255,74,48,82,0,46,218,229,0,189,253,251,0,50,229,12,255,211,141,191,1,128,244,25,255,169,231,122,254,86,47,189,255,132,183,23,255,37,178,150,255,51,137,253,0,200,78,31,0,22,105,50,0,130,60,0,0,132,163,91,254,23,231,187,0,192,79,239,0,157,102,164,255,192,82,20,1,24,181,103,255,240,9,234,0,1,123,164,255,133,233,0,255,202,242,242,0,60,186,245,0,241,16,199,255,224,116,158,254,191,125,91,255,224,86,207,0,121,37,231,255,227,9,198,255,15,153,239,255,121,232,217,254,75,112,82,0,95,12,57,254,51,214,105,255,148,220,97,1,199,98,36,0,156,209,12,254,10,212,52,0,217,180,55,254,212,170,232,255,216,20,84,255,157,250,135,0,157,99,127,254,1,206,41,0,149,36,70,1,54,196,201,255,87,116,0,254,235,171,150,0,27,163,234,0,202,135,180,0,208,95,0,254,123,156,93,0,183,62,75,0,137,235,182,0,204,225,255,255,214,139,210,255,2,115,8,255,29,12,111,0,52,156,1,0,253,21,251,255,37,165,31,254,12,130,211,0,106,18,53,254,42,99,154,0,14,217,61,254,216,11,92,255,200,197,112,254,147,38,199,0,36,252,120,254,107,169,77,0,1,123,159,255,207,75,102,0,163,175,196,0,44,1,240,0,120,186,176,254,13,98,76,255,237,124,241,255,232,146,188,255,200,96,224,0,204,31,41,0,208,200,13,0,21,225,96,255,175,156,196,0,247,208,126,0,62,184,244,254,2,171,81,0,85,115,158,0,54,64,45,255,19,138,114,0,135,71,205,0,227,47,147,1,218,231,66,0,253,209,28,0,244,15,173,255,6,15,118,254,16,150,208,255,185,22,50,255,86,112,207,255,75,113,215,1,63,146,43,255,4,225,19,254,227,23,62,255,14,255,214,254,45,8,205,255,87,197,151,254,210,82,215,255,245,248,247,255,128,248,70,0,225,247,87,0,90,120,70,0,213,245,92,0,13,133,226,0,47,181,5,1,92,163,105,255,6,30,133,254,232,178,61,255,230,149,24,255,18,49,158,0,228,100,61,254,116,243,251,255,77,75,92,1,81,219,147,255,76,163,254,254,141,213,246,0,232,37,152,254,97,44,100,0,201,37,50,1,212,244,57,0,174,171,183,255,249,74,112,0,166,156,30,0,222,221,97,255,243,93,73,254,251,101,100,255,216,217,93,255,254,138,187,255,142,190,52,255,59,203,177,255,200,94,52,0,115,114,158,255,165,152,104,1,126,99,226,255,118,157,244,1,107,200,16,0,193,90,229,0,121,6,88,0,156,32,93,254,125,241,211,255,14,237,157,255,165,154,21,255,184,224,22,255,250,24,152,255,113,77,31,0,247,171,23,255,237,177,204,255,52,137,145,255,194,182,114,0,224,234,149,0,10,111,103,1,201,129,4,0,238,142,78,0,52,6,40,255,110,213,165,254,60,207,253,0,62,215,69,0,96,97,0,255,49,45,202,0,120,121,22,255,235,139,48,1,198,45,34,255,182,50,27,1,131,210,91,255,46,54,128,0,175,123,105,255,198,141,78,254,67,244,239,255,245,54,103,254,78,38,242,255,2,92,249,254,251,174,87,255,139,63,144,0,24,108,27,255,34,102,18,1,34,22,152,0,66,229,118,254,50,143,99,0,144,169,149,1,118,30,152,0,178,8,121,1,8,159,18,0,90,101,230,255,129,29,119,0,68,36,11,1,232,183,55,0,23,255,96,255,161,41,193,255,63,139,222,0,15,179,243,0,255,100,15,255,82,53,135,0,137,57,149,1,99,240,170,255,22,230,228,254,49,180,82,255,61,82,43,0,110,245,217,0,199,125,61,0,46,253,52,0,141,197,219,0,211,159,193,0,55,121,105,254,183,20,129,0,169,119,170,255,203,178,139,255,135,40,182,255,172,13,202,255,65,178,148,0,8,207,43,0,122,53,127,1,74,161,48,0,227,214,128,254,86,11,243,255,100,86,7,1,245,68,134,255,61,43,21,1,152,84,94,255,190,60,250,254,239,118,232,255,214,136,37,1,113,76,107,255,93,104,100,1,144,206,23,255,110,150,154,1,228,103,185,0,218,49,50,254,135,77,139,255,185,1,78,0,0,161,148,255,97,29,233,255,207,148,149,255,160,168,0,0,91,128,171,255,6,28,19,254,11,111,247,0,39,187,150,255,138,232,149,0,117,62,68,255,63,216,188,255,235,234,32,254,29,57,160,255,25,12,241,1,169,60,191,0,32,131,141,255,237,159,123,255,94,197,94,254,116,254,3,255,92,179,97,254,121,97,92,255,170,112,14,0,21,149,248,0,248,227,3,0,80,96,109,0,75,192,74,1,12,90,226,255,161,106,68,1,208,114,127,255,114,42,255,254,74,26,74,255,247,179,150,254,121,140,60,0,147,70,200,255,214,40,161,255,161,188,201,255,141,65,135,255,242,115,252,0,62,47,202,0,180,149,255,254,130,55,237,0,165,17,186,255,10,169,194,0,156,109,218,255,112,140,123,255,104,128,223,254,177,142,108,255,121,37,219,255,128,77,18,255,111,108,23,1,91,192,75,0,174,245,22,255,4,236,62,255,43,64,153,1,227,173,254,0,237,122,132,1,127,89,186,255,142,82,128,254,252,84,174,0,90,179,177,1,243,214,87,255,103,60,162,255,208,130,14,255,11,130,139,0,206,129,219,255,94,217,157,255,239,230,230,255,116,115,159,254,164,107,95,0,51,218,2,1,216,125,198,255,140,202,128,254,11,95,68,255,55,9,93,254,174,153,6,255,204,172,96,0,69,160,110,0,213,38,49,254,27,80,213,0,118,125,114,0,70,70,67,255,15,142,73,255,131,122,185,255,243,20,50,254,130,237,40,0,210,159,140,1,197,151,65,255,84,153,66,0,195,126,90,0,16,238,236,1,118,187,102,255,3,24,133,255,187,69,230,0,56,197,92,1,213,69,94,255,80,138,229,1,206,7,230,0,222,111,230,1,91,233,119,255,9,89,7,1,2,98,1,0,148,74,133,255,51,246,180,255,228,177,112,1,58,189,108,255,194,203,237,254,21,209,195,0,147,10,35,1,86,157,226,0,31,163,139,254,56,7,75,255,62,90,116,0,181,60,169,0,138,162,212,254,81,167,31,0,205,90,112,255,33,112,227,0,83,151,117,1,177,224,73,255,174,144,217,255,230,204,79,255,22,77,232,255,114,78,234,0,224,57,126,254,9,49,141,0,242,147,165,1,104,182,140,255,167,132,12,1,123,68,127,0,225,87,39,1,251,108,8,0,198,193,143,1,121,135,207,255,172,22,70,0,50,68,116,255,101,175,40,255,248,105,233,0,166,203,7,0,110,197,218,0,215,254,26,254,168,226,253,0,31,143,96,0,11,103,41,0,183,129,203,254,100,247,74,255,213,126,132,0,210,147,44,0,199,234,27,1,148,47,181,0,155,91,158,1,54,105,175,255,2,78,145,254,102,154,95,0,128,207,127,254,52,124,236,255,130,84,71,0,221,243,211,0,152,170,207,0,222,106,199,0,183,84,94,254,92,200,56,255,138,182,115,1,142,96,146,0,133,136,228,0,97,18,150,0,55,251,66,0,140,102,4,0,202,103,151,0,30,19,248,255,51,184,207,0,202,198,89,0,55,197,225,254,169,95,249,255,66,65,68,255,188,234,126,0,166,223,100,1,112,239,244,0,144,23,194,0,58,39,182,0,244,44,24,254,175,68,179,255,152,118,154,1,176,162,130,0,217,114,204,254,173,126,78,255,33,222,30,255,36,2,91,255,2,143,243,0,9,235,215,0,3,171,151,1,24,215,245,255,168,47,164,254,241,146,207,0,69,129,180,0,68,243,113,0,144,53,72,254,251,45,14,0,23,110,168,0,68,68,79,255,110,70,95,254,174,91,144,255,33,206,95,255,137,41,7,255,19,187,153,254,35,255,112,255,9,145,185,254,50,157,37,0,11,112,49,1,102,8,190,255,234,243,169,1,60,85,23,0,74,39,189,0,116,49,239,0,173,213,210,0,46,161,108,255,159,150,37,0,196,120,185,255,34,98,6,255,153,195,62,255,97,230,71,255,102,61,76,0,26,212,236,255,164,97,16,0,198,59,146,0,163,23,196,0,56,24,61,0,181,98,193,0,251,147,229,255,98,189,24,255,46,54,206,255,234,82,246,0,183,103,38,1,109,62,204,0,10,240,224,0,146,22,117,255,142,154,120,0,69,212,35,0,208,99,118,1,121,255,3,255,72,6,194,0,117,17,197,255,125,15,23,0,154,79,153,0,214,94,197,255,185,55,147,255,62,254,78,254,127,82,153,0,110,102,63,255,108,82,161,255,105,187,212,1,80,138,39,0,60,255,93,255,72,12,186,0,210,251,31,1,190,167,144,255,228,44,19,254,128,67,232,0,214,249,107,254,136,145,86,255,132,46,176,0,189,187,227,255,208,22,140,0,217,211,116,0,50,81,186,254,139,250,31,0,30,64,198,1,135,155,100,0,160,206,23,254,187,162,211,255,16,188,63,0,254,208,49,0,85,84,191,0,241,192,242,255,153,126,145,1,234,162,162,255,230,97,216,1,64,135,126,0,190,148,223,1,52,0,43,255,28,39,189,1,64,136,238,0,175,196,185,0,98,226,213,255,127,159,244,1,226,175,60,0,160,233,142,1,180,243,207,255,69,152,89,1,31,101,21,0,144,25,164,254,139,191,209,0,91,25,121,0,32,147,5,0,39,186,123,255,63,115,230,255,93,167,198,255,143,213,220,255,179,156,19,255,25,66,122,0,214,160,217,255,2,45,62,255,106,79,146,254,51,137,99,255,87,100,231,255,175,145,232,255,101,184,1,255,174,9,125,0,82,37,161,1,36,114,141,255,48,222,142,255,245,186,154,0,5,174,221,254,63,114,155,255,135,55,160,1,80,31,135,0,126,250,179,1,236,218,45,0,20,28,145,1,16,147,73,0,249,189,132,1,17,189,192,255,223,142,198,255,72,20,15,255,250,53,237,254,15,11,18,0,27,211,113,254,213,107,56,255,174,147,146,255,96,126,48,0,23,193,109,1,37,162,94,0,199,157,249,254,24,128,187,255,205,49,178,254,93,164,42,255,43,119,235,1,88,183,237,255,218,210,1,255,107,254,42,0,230,10,99,255,162,0,226,0,219,237,91,0,129,178,203,0,208,50,95,254,206,208,95,255,247,191,89,254,110,234,79,255,165,61,243,0,20,122,112,255,246,246,185,254,103,4,123,0,233,99,230,1,219,91,252,255,199,222,22,255,179,245,233,255,211,241,234,0,111,250,192,255,85,84,136,0,101,58,50,255,131,173,156,254,119,45,51,255,118,233,16,254,242,90,214,0,94,159,219,1,3,3,234,255,98,76,92,254,80,54,230,0,5,228,231,254,53,24,223,255,113,56,118,1,20,132,1,255,171,210,236,0,56,241,158,255,186,115,19,255,8,229,174,0,48,44,0,1,114,114,166,255,6,73,226,255,205,89,244,0,137,227,75,1,248,173,56,0,74,120,246,254,119,3,11,255,81,120,198,255,136,122,98,255,146,241,221,1,109,194,78,255,223,241,70,1,214,200,169,255,97,190,47,255,47,103,174,255,99,92,72,254,118,233,180,255,193,35,233,254,26,229,32,255,222,252,198,0,204,43,71,255,199,84,172,0,134,102,190,0,111,238,97,254,230,40,230,0,227,205,64,254,200,12,225,0,166,25,222,0,113,69,51,255,143,159,24,0,167,184,74,0,29,224,116,254,158,208,233,0,193,116,126,255,212,11,133,255,22,58,140,1,204,36,51,255,232,30,43,0,235,70,181,255,64,56,146,254,169,18,84,255,226,1,13,255,200,50,176,255,52,213,245,254,168,209,97,0,191,71,55,0,34,78,156,0,232,144,58,1,185,74,189,0,186,142,149,254,64,69,127,255,161,203,147,255,176,151,191,0,136,231,203,254,163,182,137,0,161,126,251,254,233,32,66,0,68,207,66,0,30,28,37,0,93,114,96,1,254,92,247,255,44,171,69,0,202,119,11,255,188,118,50,1,255,83,136,255,71,82,26,0,70,227,2,0,32,235,121,1,181,41,154,0,71,134,229,254,202,255,36,0,41,152,5,0,154,63,73,255,34,182,124,0,121,221,150,255,26,204,213,1,41,172,87,0,90,157,146,255,109,130,20,0,71,107,200,255,243,102,189,0,1,195,145,254,46,88,117,0,8,206,227,0,191,110,253,255,109,128,20,254,134,85,51,255,137,177,112,1,216,34,22,255,131,16,208,255,121,149,170,0,114,19,23,1,166,80,31,255,113,240,122,0,232,179,250,0,68,110,180,254,210,170,119,0,223,108,164,255,207,79,233,255,27,229,226,254,209,98,81,255,79,68,7,0,131,185,100,0,170,29,162,255,17,162,107,255,57,21,11,1,100,200,181,255,127,65,166,1,165,134,204,0,104,167,168,0,1,164,79,0,146,135,59,1,70,50,128,255,102,119,13,254,227,6,135,0,162,142,179,255,160,100,222,0,27,224,219,1,158,93,195,255,234,141,137,0,16,24,125,255,238,206,47,255,97,17,98,255,116,110,12,255,96,115,77,0,91,227,232,255,248,254,79,255,92,229,6,254,88,198,139,0,206,75,129,0,250,77,206,255,141,244,123,1,138,69,220,0,32,151,6,1,131,167,22,255,237,68,167,254,199,189,150,0,163,171,138,255,51,188,6,255,95,29,137,254,148,226,179,0,181,107,208,255,134,31,82,255,151,101,45,255,129,202,225,0,224,72,147,0,48,138,151,255,195,64,206,254,237,218,158,0,106,29,137,254,253,189,233,255,103,15,17,255,194,97,255,0,178,45,169,254,198,225,155,0,39,48,117,255,135,106,115,0,97,38,181,0,150,47,65,255,83,130,229,254,246,38,129,0,92,239,154,254,91,99,127,0,161,111,33,255,238,217,242,255,131,185,195,255,213,191,158,255,41,150,218,0,132,169,131,0,89,84,252,1,171,70,128,255,163,248,203,254,1,50,180,255,124,76,85,1,251,111,80,0,99,66,239,255,154,237,182,255,221,126,133,254,74,204,99,255,65,147,119,255,99,56,167,255,79,248,149,255,116,155,228,255,237,43,14,254,69,137,11,255,22,250,241,1,91,122,143,255,205,249,243,0,212,26,60,255,48,182,176,1,48,23,191,255,203,121,152,254,45,74,213,255,62,90,18,254,245,163,230,255,185,106,116,255,83,35,159,0,12,33,2,255,80,34,62,0,16,87,174,255,173,101,85,0,202,36,81,254,160,69,204,255,64,225,187,0,58,206,94,0,86,144,47,0,229,86,245,0,63,145,190,1,37,5,39,0,109,251,26,0,137,147,234,0,162,121,145,255,144,116,206,255,197,232,185,255,183,190,140,255,73,12,254,255,139,20,242,255,170,90,239,255,97,66,187,255,245,181,135,254,222,136,52,0,245,5,51,254,203,47,78,0,152,101,216,0,73,23,125,0,254,96,33,1,235,210,73,255,43,209,88,1,7,129,109,0,122,104,228,254,170,242,203,0,242,204,135,255,202,28,233,255,65,6,127,0,159,144,71,0,100,140,95,0,78,150,13,0,251,107,118,1,182,58,125,255,1,38,108,255,141,189,209,255,8,155,125,1,113,163,91,255,121,79,190,255,134,239,108,255,76,47,248,0,163,228,239,0,17,111,10,0,88,149,75,255,215,235,239,0,167,159,24,255,47,151,108,255,107,209,188,0,233,231,99,254,28,202,148,255,174,35,138,255,110,24,68,255,2,69,181,0,107,102,82,0,102,237,7,0,92,36,237,255,221,162,83,1,55,202,6,255,135,234,135,255,24,250,222,0,65,94,168,254,245,248,210,255,167,108,201,254,255,161,111,0,205,8,254,0,136,13,116,0,100,176,132,255,43,215,126,255,177,133,130,255,158,79,148,0,67,224,37,1,12,206,21,255,62,34,110,1,237,104,175,255,80,132,111,255,142,174,72,0,84,229,180,254,105,179,140,0,64,248,15,255,233,138,16,0,245,67,123,254,218,121,212,255,63,95,218,1,213,133,137,255,143,182,82,255,48,28,11,0,244,114,141,1,209,175,76,255,157,181,150,255,186,229,3,255,164,157,111,1,231,189,139,0,119,202,190,255,218,106,64,255,68,235,63,254,96,26,172,255,187,47,11,1,215,18,251,255,81,84,89,0,68,58,128,0,94,113,5,1,92,129,208,255,97,15,83,254,9,28,188,0,239,9,164,0,60,205,152,0,192,163,98,255,184,18,60,0,217,182,139,0,109,59,120,255,4,192,251,0,169,210,240,255,37,172,92,254,148,211,245,255,179,65,52,0,253,13,115,0,185,174,206,1,114,188,149,255,237,90,173,0,43,199,192,255,88,108,113,0,52,35,76,0,66,25,148,255,221,4,7,255,151,241,114,255,190,209,232,0,98,50,199,0,151,150,213,255,18,74,36,1,53,40,7,0,19,135,65,255,26,172,69,0,174,237,85,0,99,95,41,0,3,56,16,0,39,160,177,255,200,106,218,254,185,68,84,255,91,186,61,254,67,143,141,255,13,244,166,255,99,114,198,0,199,110,163,255,193,18,186,0,124,239,246,1,110,68,22,0,2,235,46,1,212,60,107,0,105,42,105,1,14,230,152,0,7,5,131,0,141,104,154,255,213,3,6,0,131,228,162,255,179,100,28,1,231,123,85,255,206,14,223,1,253,96,230,0,38,152,149,1,98,137,122,0,214,205,3,255,226,152,179,255,6,133,137,0,158,69,140,255,113,162,154,255,180,243,172,255,27,189,115,255,143,46,220,255,213,134,225,255,126,29,69,0,188,43,137,1,242,70,9,0,90,204,255,255,231,170,147,0,23,56,19,254,56,125,157,255,48,179,218,255,79,182,253,255,38,212,191,1,41,235,124,0,96,151,28,0,135,148,190,0,205,249,39,254,52,96,136,255,212,44,136,255,67,209,131,255,252,130,23,255,219,128,20,255,198,129,118,0,108,101,11,0,178,5,146,1,62,7,100,255,181,236,94,254,28,26,164,0,76,22,112,255,120,102,79,0,202,192,229,1,200,176,215,0,41,64,244,255,206,184,78,0,167,45,63,1,160,35,0,255,59,12,142,255,204,9,144,255,219,94,229,1,122,27,112,0,189,105,109,255,64,208,74,255,251,127,55,1,2,226,198,0,44,76,209,0,151,152,77,255,210,23,46,1,201,171,69,255,44,211,231,0,190,37,224,255,245,196,62,255,169,181,222,255,34,211,17,0,119,241,197,255,229,35,152,1,21,69,40,255,178,226,161,0,148,179,193,0,219,194,254,1,40,206,51,255,231,92,250,1,67,153,170,0,21,148,241,0,170,69,82,255,121,18,231,255,92,114,3,0,184,62,230,0,225,201,87,255,146,96,162,255,181,242,220,0,173,187,221,1,226,62,170,255,56,126,217,1,117,13,227,255,179,44,239,0,157,141,155,255,144,221,83,0,235,209,208,0,42,17,165,1,251,81,133,0,124,245,201,254,97,211,24,255,83,214,166,0,154,36,9,255,248,47,127,0,90,219,140,255,161,217,38,254,212,147,63,255,66,84,148,1,207,3,1,0,230,134,89,1,127,78,122,255,224,155,1,255,82,136,74,0,178,156,208,255,186,25,49,255,222,3,210,1,229,150,190,255,85,162,52,255,41,84,141,255,73,123,84,254,93,17,150,0,119,19,28,1,32,22,215,255,28,23,204,255,142,241,52,255,228,52,125,0,29,76,207,0,215,167,250,254,175,164,230,0,55,207,105,1,109,187,245,255,161,44,220,1,41,101,128,255,167,16,94,0,93,214,107,255,118,72,0,254,80,61,234,255,121,175,125,0,139,169,251,0,97,39,147,254,250,196,49,255,165,179,110,254,223,70,187,255,22,142,125,1,154,179,138,255,118,176,42,1,10,174,153,0,156,92,102,0,168,13,161,255,143,16,32,0,250,197,180,255,203,163,44,1,87,32,36,0,161,153,20,255,123,252,15,0,25,227,80,0,60,88,142,0,17,22,201,1,154,205,77,255,39,63,47,0,8,122,141,0,128,23,182,254,204,39,19,255],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+20480);allocate([4,112,29,255,23,36,140,255,210,234,116,254,53,50,63,255,121,171,104,255,160,219,94,0,87,82,14,254,231,42,5,0,165,139,127,254,86,78,38,0,130,60,66,254,203,30,45,255,46,196,122,1,249,53,162,255,136,143,103,254,215,210,114,0,231,7,160,254,169,152,42,255,111,45,246,0,142,131,135,255,131,71,204,255,36,226,11,0,0,28,242,255,225,138,213,255,247,46,216,254,245,3,183,0,108,252,74,1,206,26,48,255,205,54,246,255,211,198,36,255,121,35,50,0,52,216,202,255,38,139,129,254,242,73,148,0,67,231,141,255,42,47,204,0,78,116,25,1,4,225,191,255,6,147,228,0,58,88,177,0,122,165,229,255,252,83,201,255,224,167,96,1,177,184,158,255,242,105,179,1,248,198,240,0,133,66,203,1,254,36,47,0,45,24,115,255,119,62,254,0,196,225,186,254,123,141,172,0,26,85,41,255,226,111,183,0,213,231,151,0,4,59,7,255,238,138,148,0,66,147,33,255,31,246,141,255,209,141,116,255,104,112,31,0,88,161,172,0,83,215,230,254,47,111,151,0,45,38,52,1,132,45,204,0,138,128,109,254,233,117,134,255,243,190,173,254,241,236,240,0,82,127,236,254,40,223,161,255,110,182,225,255,123,174,239,0,135,242,145,1,51,209,154,0,150,3,115,254,217,164,252,255,55,156,69,1,84,94,255,255,232,73,45,1,20,19,212,255,96,197,59,254,96,251,33,0,38,199,73,1,64,172,247,255,117,116,56,255,228,17,18,0,62,138,103,1,246,229,164,255,244,118,201,254,86,32,159,255,109,34,137,1,85,211,186,0,10,193,193,254,122,194,177,0,122,238,102,255,162,218,171,0,108,217,161,1,158,170,34,0,176,47,155,1,181,228,11,255,8,156,0,0,16,75,93,0,206,98,255,1,58,154,35,0,12,243,184,254,67,117,66,255,230,229,123,0,201,42,110,0,134,228,178,254,186,108,118,255,58,19,154,255,82,169,62,255,114,143,115,1,239,196,50,255,173,48,193,255,147,2,84,255,150,134,147,254,95,232,73,0,109,227,52,254,191,137,10,0,40,204,30,254,76,52,97,255,164,235,126,0,254,124,188,0,74,182,21,1,121,29,35,255,241,30,7,254,85,218,214,255,7,84,150,254,81,27,117,255,160,159,152,254,66,24,221,255,227,10,60,1,141,135,102,0,208,189,150,1,117,179,92,0,132,22,136,255,120,199,28,0,21,129,79,254,182,9,65,0,218,163,169,0,246,147,198,255,107,38,144,1,78,175,205,255,214,5,250,254,47,88,29,255,164,47,204,255,43,55,6,255,131,134,207,254,116,100,214,0,96,140,75,1,106,220,144,0,195,32,28,1,172,81,5,255,199,179,52,255,37,84,203,0,170,112,174,0,11,4,91,0,69,244,27,1,117,131,92,0,33,152,175,255,140,153,107,255,251,135,43,254,87,138,4,255,198,234,147,254,121,152,84,255,205,101,155,1,157,9,25,0,72,106,17,254,108,153,0,255,189,229,186,0,193,8,176,255,174,149,209,0,238,130,29,0,233,214,126,1,61,226,102,0,57,163,4,1,198,111,51,255,45,79,78,1,115,210,10,255,218,9,25,255,158,139,198,255,211,82,187,254,80,133,83,0,157,129,230,1,243,133,134,255,40,136,16,0,77,107,79,255,183,85,92,1,177,204,202,0,163,71,147,255,152,69,190,0,172,51,188,1,250,210,172,255,211,242,113,1,89,89,26,255,64,66,111,254,116,152,42,0,161,39,27,255,54,80,254,0,106,209,115,1,103,124,97,0,221,230,98,255,31,231,6,0,178,192,120,254,15,217,203,255,124,158,79,0,112,145,247,0,92,250,48,1,163,181,193,255,37,47,142,254,144,189,165,255,46,146,240,0,6,75,128,0,41,157,200,254,87,121,213,0,1,113,236,0,5,45,250,0,144,12,82,0,31,108,231,0,225,239,119,255,167,7,189,255,187,228,132,255,110,189,34,0,94,44,204,1,162,52,197,0,78,188,241,254,57,20,141,0,244,146,47,1,206,100,51,0,125,107,148,254,27,195,77,0,152,253,90,1,7,143,144,255,51,37,31,0,34,119,38,255,7,197,118,0,153,188,211,0,151,20,116,254,245,65,52,255,180,253,110,1,47,177,209,0,161,99,17,255,118,222,202,0,125,179,252,1,123,54,126,255,145,57,191,0,55,186,121,0,10,243,138,0,205,211,229,255,125,156,241,254,148,156,185,255,227,19,188,255,124,41,32,255,31,34,206,254,17,57,83,0,204,22,37,255,42,96,98,0,119,102,184,1,3,190,28,0,110,82,218,255,200,204,192,255,201,145,118,0,117,204,146,0,132,32,98,1,192,194,121,0,106,161,248,1,237,88,124,0,23,212,26,0,205,171,90,255,248,48,216,1,141,37,230,255,124,203,0,254,158,168,30,255,214,248,21,0,112,187,7,255,75,133,239,255,74,227,243,255,250,147,70,0,214,120,162,0,167,9,179,255,22,158,18,0,218,77,209,1,97,109,81,255,244,33,179,255,57,52,57,255,65,172,210,255,249,71,209,255,142,169,238,0,158,189,153,255,174,254,103,254,98,33,14,0,141,76,230,255,113,139,52,255,15,58,212,0,168,215,201,255,248,204,215,1,223,68,160,255,57,154,183,254,47,231,121,0,106,166,137,0,81,136,138,0,165,43,51,0,231,139,61,0,57,95,59,254,118,98,25,255,151,63,236,1,94,190,250,255,169,185,114,1,5,250,58,255,75,105,97,1,215,223,134,0,113,99,163,1,128,62,112,0,99,106,147,0,163,195,10,0,33,205,182,0,214,14,174,255,129,38,231,255,53,182,223,0,98,42,159,255,247,13,40,0,188,210,177,1,6,21,0,255,255,61,148,254,137,45,129,255,89,26,116,254,126,38,114,0,251,50,242,254,121,134,128,255,204,249,167,254,165,235,215,0,202,177,243,0,133,141,62,0,240,130,190,1,110,175,255,0,0,20,146,1,37,210,121,255,7,39,130,0,142,250,84,255,141,200,207,0,9,95,104,255,11,244,174,0,134,232,126,0,167,1,123,254,16,193,149,255,232,233,239,1,213,70,112,255,252,116,160,254,242,222,220,255,205,85,227,0,7,185,58,0,118,247,63,1,116,77,177,255,62,245,200,254,63,18,37,255,107,53,232,254,50,221,211,0,162,219,7,254,2,94,43,0,182,62,182,254,160,78,200,255,135,140,170,0,235,184,228,0,175,53,138,254,80,58,77,255,152,201,2,1,63,196,34,0,5,30,184,0,171,176,154,0,121,59,206,0,38,99,39,0,172,80,77,254,0,134,151,0,186,33,241,254,94,253,223,255,44,114,252,0,108,126,57,255,201,40,13,255,39,229,27,255,39,239,23,1,151,121,51,255,153,150,248,0,10,234,174,255,118,246,4,254,200,245,38,0,69,161,242,1,16,178,150,0,113,56,130,0,171,31,105,0,26,88,108,255,49,42,106,0,251,169,66,0,69,93,149,0,20,57,254,0,164,25,111,0,90,188,90,255,204,4,197,0,40,213,50,1,212,96,132,255,88,138,180,254,228,146,124,255,184,246,247,0,65,117,86,255,253,102,210,254,254,121,36,0,137,115,3,255,60,24,216,0,134,18,29,0,59,226,97,0,176,142,71,0,7,209,161,0,189,84,51,254,155,250,72,0,213,84,235,255,45,222,224,0,238,148,143,255,170,42,53,255,78,167,117,0,186,0,40,255,125,177,103,255,69,225,66,0,227,7,88,1,75,172,6,0,169,45,227,1,16,36,70,255,50,2,9,255,139,193,22,0,143,183,231,254,218,69,50,0,236,56,161,1,213,131,42,0,138,145,44,254,136,229,40,255,49,63,35,255,61,145,245,255,101,192,2,254,232,167,113,0,152,104,38,1,121,185,218,0,121,139,211,254,119,240,35,0,65,189,217,254,187,179,162,255,160,187,230,0,62,248,14,255,60,78,97,0,255,247,163,255,225,59,91,255,107,71,58,255,241,47,33,1,50,117,236,0,219,177,63,254,244,90,179,0,35,194,215,255,189,67,50,255,23,135,129,0,104,189,37,255,185,57,194,0,35,62,231,255,220,248,108,0,12,231,178,0,143,80,91,1,131,93,101,255,144,39,2,1,255,250,178,0,5,17,236,254,139,32,46,0,204,188,38,254,245,115,52,255,191,113,73,254,191,108,69,255,22,69,245,1,23,203,178,0,170,99,170,0,65,248,111,0,37,108,153,255,64,37,69,0,0,88,62,254,89,148,144,255,191,68,224,1,241,39,53,0,41,203,237,255,145,126,194,255,221,42,253,255,25,99,151,0,97,253,223,1,74,115,49,255,6,175,72,255,59,176,203,0,124,183,249,1,228,228,99,0,129,12,207,254,168,192,195,255,204,176,16,254,152,234,171,0,77,37,85,255,33,120,135,255,142,194,227,1,31,214,58,0,213,187,125,255,232,46,60,255,190,116,42,254,151,178,19,255,51,62,237,254,204,236,193,0,194,232,60,0,172,34,157,255,189,16,184,254,103,3,95,255,141,233,36,254,41,25,11,255,21,195,166,0,118,245,45,0,67,213,149,255,159,12,18,255,187,164,227,1,160,25,5,0,12,78,195,1,43,197,225,0,48,142,41,254,196,155,60,255,223,199,18,1,145,136,156,0,252,117,169,254,145,226,238,0,239,23,107,0,109,181,188,255,230,112,49,254,73,170,237,255,231,183,227,255,80,220,20,0,194,107,127,1,127,205,101,0,46,52,197,1,210,171,36,255,88,3,90,255,56,151,141,0,96,187,255,255,42,78,200,0,254,70,70,1,244,125,168,0,204,68,138,1,124,215,70,0,102,66,200,254,17,52,228,0,117,220,143,254,203,248,123,0,56,18,174,255,186,151,164,255,51,232,208,1,160,228,43,255,249,29,25,1,68,190,63,0,103,230,9,106,133,174,103,187,114,243,110,60,58,245,79,165,127,82,14,81,140,104,5,155,171,217,131,31,25,205,224,91,152,47,138,66,145,68,55,113,207,251,192,181,165,219,181,233,91,194,86,57,241,17,241,89,164,130,63,146,213,94,28,171,152,170,7,216,1,91,131,18,190,133,49,36,195,125,12,85,116,93,190,114,254,177,222,128,167,6,220,155,116,241,155,193,193,105,155,228,134,71,190,239,198,157,193,15,204,161,12,36,111,44,233,45,170,132,116,74,220,169,176,92,218,136,249,118,82,81,62,152,109,198,49,168,200,39,3,176,199,127,89,191,243,11,224,198,71,145,167,213,81,99,202,6,103,41,41,20,133,10,183,39,56,33,27,46,252,109,44,77,19,13,56,83,84,115,10,101,187,10,106,118,46,201,194,129,133,44,114,146,161,232,191,162,75,102,26,168,112,139,75,194,163,81,108,199,25,232,146,209,36,6,153,214,133,53,14,244,112,160,106,16,22,193,164,25,8,108,55,30,76,119,72,39,181,188,176,52,179,12,28,57,74,170,216,78,79,202,156,91,243,111,46,104,238,130,143,116,111,99,165,120,20,120,200,132,8,2,199,140,250,255,190,144,235,108,80,164,247,163,249,190,242,120,113,198,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,48,138,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,104,109,97,99,115,104,97,53,49,50,50,53,54,0,99,117,114,118,101,50,53,53,49,57,120,115,97,108,115,97,50,48,112,111,108,121,49,51,48,53,0,83,45,62,98,117,102,108,101,110,32,60,61,32,66,76,65,75,69,50,66,95,66,76,79,67,75,66,89,84,69,83,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,47,98,108,97,107,101,50,98,47,114,101,102,47,98,108,97,107,101,50,98,45,114,101,102,46,99,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,95,102,105,110,97,108,0,111,117,116,108,101,110,32,60,61,32,85,73,78,84,56,95,77,65,88,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,47,98,108,97,107,101,50,98,47,114,101,102,47,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,46,99,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,0,107,101,121,108,101,110,32,60,61,32,85,73,78,84,56,95,77,65,88,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,115,97,108,116,95,112,101,114,115,111,110,97,108,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,105,110,105,116,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,105,110,105,116,95,115,97,108,116,95,112,101,114,115,111,110,97,108,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,102,105,110,97,108,0,115,104,97,53,49,50,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,98,108,97,107,101,50,98,0,120,50,53,53,49,57,98,108,97,107,101,50,98,0,112,111,108,121,49,51,48,53,0,36,97,114,103,111,110,50,105,0,36,118,61,0,36,109,61,0,44,116,61,0,44,112,61,0,36,97,114,103,111,110,50,105,36,118,61,0,36,97,114,103,111,110,50,105,36,0,97,114,103,111,110,50,105,0,46,47,48,49,50,51,52,53,54,55,56,57,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,0,36,55,36,0,99,117,114,118,101,50,53,53,49,57,0,120,115,97,108,115,97,50,48,112,111,108,121,49,51,48,53,0,115,105,112,104,97,115,104,50,52,0,101,100,50,53,53,49,57,0,237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,83,105,103,69,100,50,53,53,49,57,32,110,111,32,69,100,50,53,53,49,57,32,99,111,108,108,105,115,105,111,110,115,1,0,120,115,97,108,115,97,50,48,0,106,115,0,123,32,114,101,116,117,114,110,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,40,41,59,32,125,0,123,32,105,102,32,40,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,61,61,32,117,110,100,101,102,105,110,101,100,41,32,123,32,116,114,121,32,123,32,118,97,114,32,119,105,110,100,111,119,95,32,61,32,34,111,98,106,101,99,116,34,32,61,61,61,32,116,121,112,101,111,102,32,119,105,110,100,111,119,32,63,32,119,105,110,100,111,119,32,58,32,115,101,108,102,44,32,99,114,121,112,116,111,95,32,61,32,116,121,112,101,111,102,32,119,105,110,100,111,119,95,46,99,114,121,112,116,111,32,33,61,61,32,34,117,110,100,101,102,105,110,101,100,34,32,63,32,119,105,110,100,111,119,95,46,99,114,121,112,116,111,32,58,32,119,105,110,100,111,119,95,46,109,115,67,114,121,112,116,111,44,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,32,61,32,102,117,110,99,116,105,111,110,40,41,32,123,32,118,97,114,32,98,117,102,32,61,32,110,101,119,32,85,105,110,116,51,50,65,114,114,97,121,40,49,41,59,32,99,114,121,112,116,111,95,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,115,40,98,117,102,41,59,32,114,101,116,117,114,110,32,98,117,102,91,48,93,32,62,62,62,32,48,59,32,125,59,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,40,41,59,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,59,32,125,32,99,97,116,99,104,32,40,101,41,32,123,32,116,114,121,32,123,32,118,97,114,32,99,114,121,112,116,111,32,61,32,114,101,113,117,105,114,101,40,39,99,114,121,112,116,111,39,41,44,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,32,61,32,102,117,110,99,116,105,111,110,40,41,32,123,32,118,97,114,32,98,117,102,32,61,32,99,114,121,112,116,111,46,114,97,110,100,111,109,66,121,116,101,115,40,52,41,59,32,114,101,116,117,114,110,32,40,98,117,102,91,48,93,32,60,60,32,50,52,32,124,32,98,117,102,91,49,93,32,60,60,32,49,54,32,124,32,98,117,102,91,50,93,32,60,60,32,56,32,124,32,98,117,102,91,51,93,41,32,62,62,62,32,48,59,32,125,59,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,40,41,59,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,59,32,125,32,99,97,116,99,104,32,40,101,41,32,123,32,116,104,114,111,119,32,39,78,111,32,115,101,99,117,114,101,32,114,97,110,100,111,109,32,110,117,109,98,101,114,32,103,101,110,101,114,97,116,111,114,32,102,111,117,110,100,39,59,32,125,32,125,32,125,32,125,0,76,105,98,115,111,100,105,117,109,68,82,71,98,117,102,95,108,101,110,32,60,61,32,83,73,90,69,95,77,65,88,0,114,97,110,100,111,109,98,121,116,101,115,47,114,97,110,100,111,109,98,121,116,101,115,46,99,0,114,97,110,100,111,109,98,121,116,101,115,0,49,46,48,46,49,50,0,0,0,0,12,0,0,0,0,0,0,0,4,0,0,0,8,15,11,7,3,14,10,6,2,13,9,5,1,12,8,4,0,3,3,3,3,7,7,7,7,11,11,11,11,15,15,15,15,3,2,1,0,7,6,5,4,11,10,9,8,15,14,13,12,12,8,4,0,13,9,5,1,14,10,6,2,15,11,7,3,1,2,3,0,6,7,4,5,11,8,9,10,12,13,14,15,15,10,5,0,14,9,4,3,13,8,7,2,12,11,6,1],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+30720);var tempDoublePtr=STATICTOP;STATICTOP+=16;Module["_bitshift64Ashr"]=_bitshift64Ashr;Module["_i64Subtract"]=_i64Subtract;Module["_i64Add"]=_i64Add;Module["_memset"]=_memset;Module["_bitshift64Lshr"]=_bitshift64Lshr;Module["_bitshift64Shl"]=_bitshift64Shl;function _abort(){Module["abort"]()}function ___assert_fail(condition,filename,line,func){ABORT=true;throw"Assertion failed: "+Pointer_stringify(condition)+", at: "+[filename?Pointer_stringify(filename):"unknown filename",line,func?Pointer_stringify(func):"unknown function"]+" at "+stackTrace()}function _emscripten_memcpy_big(dest,src,num){HEAPU8.set(HEAPU8.subarray(src,src+num),dest);return dest}Module["_memcpy"]=_memcpy;var cttz_i8=allocate([8,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,7,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0],"i8",ALLOC_STATIC);Module["_llvm_cttz_i32"]=_llvm_cttz_i32;Module["___udivmoddi4"]=___udivmoddi4;Module["___udivdi3"]=___udivdi3;Module["___muldsi3"]=___muldsi3;Module["___muldi3"]=___muldi3;function ___setErrNo(value){if(Module["___errno_location"])HEAP32[Module["___errno_location"]()>>2]=value;return value}var ERRNO_CODES={EPERM:1,ENOENT:2,ESRCH:3,EINTR:4,EIO:5,ENXIO:6,E2BIG:7,ENOEXEC:8,EBADF:9,ECHILD:10,EAGAIN:11,EWOULDBLOCK:11,ENOMEM:12,EACCES:13,EFAULT:14,ENOTBLK:15,EBUSY:16,EEXIST:17,EXDEV:18,ENODEV:19,ENOTDIR:20,EISDIR:21,EINVAL:22,ENFILE:23,EMFILE:24,ENOTTY:25,ETXTBSY:26,EFBIG:27,ENOSPC:28,ESPIPE:29,EROFS:30,EMLINK:31,EPIPE:32,EDOM:33,ERANGE:34,ENOMSG:42,EIDRM:43,ECHRNG:44,EL2NSYNC:45,EL3HLT:46,EL3RST:47,ELNRNG:48,EUNATCH:49,ENOCSI:50,EL2HLT:51,EDEADLK:35,ENOLCK:37,EBADE:52,EBADR:53,EXFULL:54,ENOANO:55,EBADRQC:56,EBADSLT:57,EDEADLOCK:35,EBFONT:59,ENOSTR:60,ENODATA:61,ETIME:62,ENOSR:63,ENONET:64,ENOPKG:65,EREMOTE:66,ENOLINK:67,EADV:68,ESRMNT:69,ECOMM:70,EPROTO:71,EMULTIHOP:72,EDOTDOT:73,EBADMSG:74,ENOTUNIQ:76,EBADFD:77,EREMCHG:78,ELIBACC:79,ELIBBAD:80,ELIBSCN:81,ELIBMAX:82,ELIBEXEC:83,ENOSYS:38,ENOTEMPTY:39,ENAMETOOLONG:36,ELOOP:40,EOPNOTSUPP:95,EPFNOSUPPORT:96,ECONNRESET:104,ENOBUFS:105,EAFNOSUPPORT:97,EPROTOTYPE:91,ENOTSOCK:88,ENOPROTOOPT:92,ESHUTDOWN:108,ECONNREFUSED:111,EADDRINUSE:98,ECONNABORTED:103,ENETUNREACH:101,ENETDOWN:100,ETIMEDOUT:110,EHOSTDOWN:112,EHOSTUNREACH:113,EINPROGRESS:115,EALREADY:114,EDESTADDRREQ:89,EMSGSIZE:90,EPROTONOSUPPORT:93,ESOCKTNOSUPPORT:94,EADDRNOTAVAIL:99,ENETRESET:102,EISCONN:106,ENOTCONN:107,ETOOMANYREFS:109,EUSERS:87,EDQUOT:122,ESTALE:116,ENOTSUP:95,ENOMEDIUM:123,EILSEQ:84,EOVERFLOW:75,ECANCELED:125,ENOTRECOVERABLE:131,EOWNERDEAD:130,ESTRPIPE:86};function _sysconf(name){switch(name){case 30:return PAGE_SIZE;case 85:var maxHeapSize=2*1024*1024*1024-16777216;maxHeapSize=HEAPU8.length;return maxHeapSize/PAGE_SIZE;case 132:case 133:case 12:case 137:case 138:case 15:case 235:case 16:case 17:case 18:case 19:case 20:case 149:case 13:case 10:case 236:case 153:case 9:case 21:case 22:case 159:case 154:case 14:case 77:case 78:case 139:case 80:case 81:case 82:case 68:case 67:case 164:case 11:case 29:case 47:case 48:case 95:case 52:case 51:case 46:return 200809;case 79:return 0;case 27:case 246:case 127:case 128:case 23:case 24:case 160:case 161:case 181:case 182:case 242:case 183:case 184:case 243:case 244:case 245:case 165:case 178:case 179:case 49:case 50:case 168:case 169:case 175:case 170:case 171:case 172:case 97:case 76:case 32:case 173:case 35:return-1;case 176:case 177:case 7:case 155:case 8:case 157:case 125:case 126:case 92:case 93:case 129:case 130:case 131:case 94:case 91:return 1;case 74:case 60:case 69:case 70:case 4:return 1024;case 31:case 42:case 72:return 32;case 87:case 26:case 33:return 2147483647;case 34:case 1:return 47839;case 38:case 36:return 99;case 43:case 37:return 2048;case 0:return 2097152;case 3:return 65536;case 28:return 32768;case 44:return 32767;case 75:return 16384;case 39:return 1e3;case 89:return 700;case 71:return 256;case 40:return 255;case 2:return 100;case 180:return 64;case 25:return 20;case 5:return 16;case 6:return 6;case 73:return 4;case 84:{if(typeof navigator==="object")return navigator["hardwareConcurrency"]||1;return 1}}___setErrNo(ERRNO_CODES.EINVAL);return-1}Module["_sbrk"]=_sbrk;Module["_memmove"]=_memmove;Module["___uremdi3"]=___uremdi3;DYNAMICTOP_PTR=allocate(1,"i32",ALLOC_STATIC);STACK_BASE=STACKTOP=Runtime.alignMemory(STATICTOP);STACK_MAX=STACK_BASE+TOTAL_STACK;DYNAMIC_BASE=Runtime.alignMemory(STACK_MAX);HEAP32[DYNAMICTOP_PTR>>2]=DYNAMIC_BASE;staticSealed=true;Module.asmGlobalArg={"Math":Math,"Int8Array":Int8Array,"Int16Array":Int16Array,"Int32Array":Int32Array,"Uint8Array":Uint8Array,"Uint16Array":Uint16Array,"Uint32Array":Uint32Array,"Float32Array":Float32Array,"Float64Array":Float64Array,"NaN":NaN,"Infinity":Infinity};Module.asmLibraryArg={"abort":abort,"assert":assert,"enlargeMemory":enlargeMemory,"getTotalMemory":getTotalMemory,"abortOnCannotGrowMemory":abortOnCannotGrowMemory,"_emscripten_asm_const_i":_emscripten_asm_const_i,"_sysconf":_sysconf,"_abort":_abort,"___setErrNo":___setErrNo,"_emscripten_memcpy_big":_emscripten_memcpy_big,"_emscripten_asm_const_v":_emscripten_asm_const_v,"___assert_fail":___assert_fail,"DYNAMICTOP_PTR":DYNAMICTOP_PTR,"tempDoublePtr":tempDoublePtr,"ABORT":ABORT,"STACKTOP":STACKTOP,"STACK_MAX":STACK_MAX,"cttz_i8":cttz_i8};// EMSCRIPTEN_START_ASM +var asm=(function(global,env,buffer) { +"use asm";var a=new global.Int8Array(buffer);var b=new global.Int16Array(buffer);var c=new global.Int32Array(buffer);var d=new global.Uint8Array(buffer);var e=new global.Uint16Array(buffer);var f=new global.Uint32Array(buffer);var g=new global.Float32Array(buffer);var h=new global.Float64Array(buffer);var i=env.DYNAMICTOP_PTR|0;var j=env.tempDoublePtr|0;var k=env.ABORT|0;var l=env.STACKTOP|0;var m=env.STACK_MAX|0;var n=env.cttz_i8|0;var o=0;var p=0;var q=0;var r=0;var s=global.NaN,t=global.Infinity;var u=0,v=0,w=0,x=0,y=0.0;var z=0;var A=global.Math.floor;var B=global.Math.abs;var C=global.Math.sqrt;var D=global.Math.pow;var E=global.Math.cos;var F=global.Math.sin;var G=global.Math.tan;var H=global.Math.acos;var I=global.Math.asin;var J=global.Math.atan;var K=global.Math.atan2;var L=global.Math.exp;var M=global.Math.log;var N=global.Math.ceil;var O=global.Math.imul;var P=global.Math.min;var Q=global.Math.max;var R=global.Math.clz32;var S=env.abort;var T=env.assert;var U=env.enlargeMemory;var V=env.getTotalMemory;var W=env.abortOnCannotGrowMemory;var X=env._emscripten_asm_const_i;var Y=env._sysconf;var Z=env._abort;var _=env.___setErrNo;var $=env._emscripten_memcpy_big;var aa=env._emscripten_asm_const_v;var ba=env.___assert_fail;var ca=0.0; +// EMSCRIPTEN_START_FUNCS +function ga(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0;f=l;g=l=l+63&-64;l=l+256|0;d=0;do{h=Te(b+(d<<3)|0)|0;e=g+128+(d<<3)|0;c[e>>2]=h;c[e+4>>2]=z;d=d+1|0}while((d|0)!=16);d=g;b=a;e=d+64|0;do{c[d>>2]=c[b>>2];d=d+4|0;b=b+4|0}while((d|0)<(e|0));c[g+88>>2]=1595750129;c[g+88+4>>2]=-1521486534;ca=c[a+64>>2]^-1377402159;r=c[a+64+4>>2]^1359893119;h=c[a+72>>2]^725511199;w=c[a+72+4>>2]^-1694144372;n=c[a+80>>2]^-79577749;s=c[a+80+4>>2]^528734635;K=c[a+88>>2]^327033209;ba=c[a+88+4>>2]^1541459225;c[g+120>>2]=K;c[g+120+4>>2]=ba;u=c[g+32>>2]|0;e=c[g+32+4>>2]|0;N=fg(u|0,e|0,c[g>>2]|0,c[g+4>>2]|0)|0;N=fg(N|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;d=z;r=Ze(ca^N,r^d,32)|0;ca=z;V=fg(r|0,ca|0,-205731576,1779033703)|0;O=z;e=Ze(u^V,e^O,24)|0;u=z;d=fg(N|0,d|0,e|0,u|0)|0;N=g+128+8|0;d=fg(d|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;R=z;c[g>>2]=d;c[g+4>>2]=R;ca=Ze(r^d,ca^R,16)|0;r=z;c[g+96>>2]=ca;c[g+96+4>>2]=r;r=fg(V|0,O|0,ca|0,r|0)|0;ca=z;c[g+64>>2]=r;c[g+64+4>>2]=ca;ca=Ze(e^r,u^ca,63)|0;c[g+32>>2]=ca;c[g+32+4>>2]=z;ca=c[g+40>>2]|0;u=c[g+40+4>>2]|0;r=fg(ca|0,u|0,c[g+8>>2]|0,c[g+8+4>>2]|0)|0;e=g+128+16|0;r=fg(r|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;O=z;w=Ze(h^r,w^O,32)|0;h=z;V=fg(w|0,h|0,-2067093701,-1150833019)|0;D=z;u=Ze(ca^V,u^D,24)|0;ca=z;O=fg(r|0,O|0,u|0,ca|0)|0;r=g+128+24|0;O=fg(O|0,z|0,c[r>>2]|0,c[r+4>>2]|0)|0;x=z;h=Ze(w^O,h^x,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;D=fg(V|0,D|0,h|0,w|0)|0;V=z;c[g+72>>2]=D;c[g+72+4>>2]=V;V=Ze(u^D,ca^V,63)|0;ca=z;D=c[g+48>>2]|0;u=c[g+48+4>>2]|0;t=fg(D|0,u|0,c[g+16>>2]|0,c[g+16+4>>2]|0)|0;X=g+128+32|0;t=fg(t|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;i=z;s=Ze(n^t,s^i,32)|0;n=z;C=fg(s|0,n|0,-23791573,1013904242)|0;b=z;u=Ze(D^C,u^b,24)|0;D=z;i=fg(t|0,i|0,u|0,D|0)|0;t=g+128+40|0;i=fg(i|0,z|0,c[t>>2]|0,c[t+4>>2]|0)|0;P=z;n=Ze(s^i,n^P,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;b=fg(C|0,b|0,n|0,s|0)|0;C=z;D=Ze(u^b,D^C,63)|0;u=z;m=c[g+56>>2]|0;o=c[g+56+4>>2]|0;v=fg(m|0,o|0,c[g+24>>2]|0,c[g+24+4>>2]|0)|0;q=g+128+48|0;v=fg(v|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;aa=z;ba=Ze(K^v,ba^aa,32)|0;K=z;B=fg(c[g+88>>2]|0,c[g+88+4>>2]|0,ba|0,K|0)|0;F=z;o=Ze(m^B,o^F,24)|0;m=z;aa=fg(v|0,aa|0,o|0,m|0)|0;v=g+128+56|0;aa=fg(aa|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;y=z;K=Ze(ba^aa,K^y,16)|0;ba=z;F=fg(B|0,F|0,K|0,ba|0)|0;B=z;m=Ze(o^F,m^B,63)|0;o=z;R=fg(V|0,ca|0,d|0,R|0)|0;d=g+128+64|0;R=fg(R|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;S=z;ba=Ze(K^R,ba^S,32)|0;K=z;C=fg(b|0,C|0,ba|0,K|0)|0;b=z;ca=Ze(V^C,ca^b,24)|0;V=z;S=fg(R|0,S|0,ca|0,V|0)|0;R=g+128+72|0;S=fg(S|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;$=z;K=Ze(ba^S,K^$,16)|0;ba=z;c[g+120>>2]=K;c[g+120+4>>2]=ba;ba=fg(C|0,b|0,K|0,ba|0)|0;K=z;c[g+80>>2]=ba;c[g+80+4>>2]=K;K=Ze(ca^ba,V^K,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;x=fg(D|0,u|0,O|0,x|0)|0;O=g+128+80|0;ba=c[O>>2]|0;ca=c[O+4>>2]|0;x=fg(x|0,z|0,ba|0,ca|0)|0;b=z;C=Ze(c[g+96>>2]^x,c[g+96+4>>2]^b,32)|0;A=z;B=fg(F|0,B|0,C|0,A|0)|0;F=z;u=Ze(D^B,u^F,24)|0;D=z;b=fg(x|0,b|0,u|0,D|0)|0;x=g+128+88|0;b=fg(b|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;M=z;A=Ze(C^b,A^M,16)|0;C=z;F=fg(B|0,F|0,A|0,C|0)|0;B=z;c[g+88>>2]=F;c[g+88+4>>2]=B;B=Ze(u^F,D^B,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;P=fg(m|0,o|0,i|0,P|0)|0;i=g+128+96|0;P=fg(P|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;F=z;w=Ze(h^P,w^F,32)|0;h=z;u=fg(c[g+64>>2]|0,c[g+64+4>>2]|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;F=fg(P|0,F|0,o|0,m|0)|0;P=g+128+104|0;da=c[P>>2]|0;_=c[P+4>>2]|0;F=fg(F|0,z|0,da|0,_|0)|0;E=z;h=Ze(w^F,h^E,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;k=c[g+32>>2]|0;ga=c[g+32+4>>2]|0;y=fg(k|0,ga|0,aa|0,y|0)|0;aa=g+128+112|0;T=c[aa>>2]|0;j=c[aa+4>>2]|0;y=fg(y|0,z|0,T|0,j|0)|0;ia=z;s=Ze(n^y,s^ia,32)|0;n=z;I=fg(c[g+72>>2]|0,c[g+72+4>>2]|0,s|0,n|0)|0;U=z;ga=Ze(k^I,ga^U,24)|0;k=z;ia=fg(y|0,ia|0,ga|0,k|0)|0;y=g+128+120|0;H=c[y>>2]|0;fa=c[y+4>>2]|0;ia=fg(ia|0,z|0,H|0,fa|0)|0;Q=z;n=Ze(s^ia,n^Q,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;k=Ze(ga^U,k^I,63)|0;ga=z;$=fg(S|0,$|0,k|0,ga|0)|0;j=fg($|0,z|0,T|0,j|0)|0;T=z;C=Ze(A^j,C^T,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;ga=Ze(k^u,ga^p,24)|0;k=z;T=fg(j|0,T|0,ga|0,k|0)|0;ca=fg(T|0,z|0,ba|0,ca|0)|0;ba=z;A=Ze(C^ca,A^ba,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;k=Ze(ga^p,k^u,63)|0;c[g+32>>2]=k;c[g+32+4>>2]=z;M=fg(K|0,V|0,b|0,M|0)|0;M=fg(M|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;b=z;w=Ze(h^M,w^b,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;b=fg(M|0,b|0,V|0,K|0)|0;b=fg(b|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;M=z;h=Ze(w^b,h^M,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;E=fg(B|0,D|0,F|0,E|0)|0;E=fg(E|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;F=z;s=Ze(n^E,s^F,32)|0;n=z;k=fg(c[g+80>>2]|0,c[g+80+4>>2]|0,s|0,n|0)|0;ga=z;D=Ze(B^k,D^ga,24)|0;B=z;F=fg(E|0,F|0,D|0,B|0)|0;fa=fg(F|0,z|0,H|0,fa|0)|0;H=z;n=Ze(s^fa,n^H,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;ga=fg(k|0,ga|0,n|0,s|0)|0;k=z;B=Ze(D^ga,B^k,63)|0;D=z;Q=fg(m|0,o|0,ia|0,Q|0)|0;_=fg(Q|0,z|0,da|0,_|0)|0;da=z;Q=Ze(c[g+120>>2]^_,c[g+120+4>>2]^da,32)|0;ia=z;F=fg(c[g+88>>2]|0,c[g+88+4>>2]|0,Q|0,ia|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;da=fg(_|0,da|0,o|0,m|0)|0;da=fg(da|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;_=z;ia=Ze(Q^da,ia^_,16)|0;Q=z;E=fg(F|0,E|0,ia|0,Q|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;ba=fg(K|0,V|0,ca|0,ba|0)|0;ba=fg(ba|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;ca=z;Q=Ze(ia^ba,Q^ca,32)|0;ia=z;k=fg(ga|0,k|0,Q|0,ia|0)|0;ga=z;V=Ze(K^k,V^ga,24)|0;K=z;ca=fg(ba|0,ca|0,V|0,K|0)|0;ba=c[i>>2]|0;T=c[i+4>>2]|0;ca=fg(ca|0,z|0,ba|0,T|0)|0;j=z;ia=Ze(Q^ca,ia^j,16)|0;Q=z;c[g+120>>2]=ia;c[g+120+4>>2]=Q;Q=fg(k|0,ga|0,ia|0,Q|0)|0;ia=z;c[g+80>>2]=Q;c[g+80+4>>2]=ia;K=Ze(V^Q,K^ia,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;M=fg(B|0,D|0,b|0,M|0)|0;b=c[g+128>>2]|0;ga=c[g+128+4>>2]|0;M=fg(M|0,z|0,b|0,ga|0)|0;k=z;C=Ze(A^M,C^k,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;k=fg(M|0,k|0,D|0,B|0)|0;M=c[e>>2]|0;$=c[e+4>>2]|0;k=fg(k|0,z|0,M|0,$|0)|0;S=z;A=Ze(C^k,A^S,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;H=fg(m|0,o|0,fa|0,H|0)|0;fa=c[x>>2]|0;ha=c[x+4>>2]|0;H=fg(H|0,z|0,fa|0,ha|0)|0;L=z;w=Ze(h^H,w^L,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;L=fg(H|0,L|0,o|0,m|0)|0;L=fg(L|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;H=z;h=Ze(w^L,h^H,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;Z=c[g+32>>2]|0;W=c[g+32+4>>2]|0;_=fg(Z|0,W|0,da|0,_|0)|0;da=c[t>>2]|0;G=c[t+4>>2]|0;_=fg(_|0,z|0,da|0,G|0)|0;ea=z;s=Ze(n^_,s^ea,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;W=Ze(Z^I,W^U,24)|0;Z=z;ea=fg(_|0,ea|0,W|0,Z|0)|0;_=c[r>>2]|0;J=c[r+4>>2]|0;ea=fg(ea|0,z|0,_|0,J|0)|0;Y=z;n=Ze(s^ea,n^Y,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;Z=Ze(W^U,Z^I,63)|0;W=z;j=fg(ca|0,j|0,Z|0,W|0)|0;ha=fg(j|0,z|0,fa|0,ha|0)|0;fa=z;C=Ze(A^ha,C^fa,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;W=Ze(Z^u,W^p,24)|0;Z=z;fa=fg(ha|0,fa|0,W|0,Z|0)|0;fa=fg(fa|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;ha=z;A=Ze(C^fa,A^ha,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;Z=Ze(W^p,Z^u,63)|0;c[g+32>>2]=Z;c[g+32+4>>2]=z;S=fg(K|0,V|0,k|0,S|0)|0;T=fg(S|0,z|0,ba|0,T|0)|0;ba=z;w=Ze(h^T,w^ba,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;ba=fg(T|0,ba|0,V|0,K|0)|0;ga=fg(ba|0,z|0,b|0,ga|0)|0;b=z;h=Ze(w^ga,h^b,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;H=fg(B|0,D|0,L|0,H|0)|0;G=fg(H|0,z|0,da|0,G|0)|0;da=z;s=Ze(n^G,s^da,32)|0;n=z;ia=fg(Q|0,ia|0,s|0,n|0)|0;Q=z;D=Ze(B^ia,D^Q,24)|0;B=z;da=fg(G|0,da|0,D|0,B|0)|0;$=fg(da|0,z|0,M|0,$|0)|0;M=z;n=Ze(s^$,n^M,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;Q=fg(ia|0,Q|0,n|0,s|0)|0;ia=z;B=Ze(D^Q,B^ia,63)|0;D=z;Y=fg(m|0,o|0,ea|0,Y|0)|0;Y=fg(Y|0,z|0,c[y>>2]|0,c[y+4>>2]|0)|0;ea=z;da=Ze(c[g+120>>2]^Y,c[g+120+4>>2]^ea,32)|0;G=z;F=fg(E|0,F|0,da|0,G|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;ea=fg(Y|0,ea|0,o|0,m|0)|0;ea=fg(ea|0,z|0,c[P>>2]|0,c[P+4>>2]|0)|0;Y=z;G=Ze(da^ea,G^Y,16)|0;da=z;E=fg(F|0,E|0,G|0,da|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;ha=fg(K|0,V|0,fa|0,ha|0)|0;ha=fg(ha|0,z|0,c[O>>2]|0,c[O+4>>2]|0)|0;fa=z;da=Ze(G^ha,da^fa,32)|0;G=z;ia=fg(Q|0,ia|0,da|0,G|0)|0;Q=z;V=Ze(K^ia,V^Q,24)|0;K=z;fa=fg(ha|0,fa|0,V|0,K|0)|0;fa=fg(fa|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;ha=z;G=Ze(da^fa,G^ha,16)|0;da=z;c[g+120>>2]=G;c[g+120+4>>2]=da;da=fg(ia|0,Q|0,G|0,da|0)|0;G=z;c[g+80>>2]=da;c[g+80+4>>2]=G;K=Ze(V^da,K^G,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;b=fg(B|0,D|0,ga|0,b|0)|0;J=fg(b|0,z|0,_|0,J|0)|0;_=z;C=Ze(A^J,C^_,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;_=fg(J|0,_|0,D|0,B|0)|0;_=fg(_|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;J=z;A=Ze(C^_,A^J,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;M=fg(m|0,o|0,$|0,M|0)|0;$=c[v>>2]|0;b=c[v+4>>2]|0;M=fg(M|0,z|0,$|0,b|0)|0;ga=z;w=Ze(h^M,w^ga,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;ga=fg(M|0,ga|0,o|0,m|0)|0;M=c[N>>2]|0;Q=c[N+4>>2]|0;ga=fg(ga|0,z|0,M|0,Q|0)|0;ia=z;h=Ze(w^ga,h^ia,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;H=c[g+32>>2]|0;L=c[g+32+4>>2]|0;Y=fg(H|0,L|0,ea|0,Y|0)|0;ea=c[R>>2]|0;ba=c[R+4>>2]|0;Y=fg(Y|0,z|0,ea|0,ba|0)|0;T=z;s=Ze(n^Y,s^T,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;L=Ze(H^I,L^U,24)|0;H=z;T=fg(Y|0,T|0,L|0,H|0)|0;T=fg(T|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;Y=z;n=Ze(s^T,n^Y,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;H=Ze(L^U,H^I,63)|0;L=z;ha=fg(fa|0,ha|0,H|0,L|0)|0;b=fg(ha|0,z|0,$|0,b|0)|0;$=z;C=Ze(A^b,C^$,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;L=Ze(H^u,L^p,24)|0;H=z;$=fg(b|0,$|0,L|0,H|0)|0;ba=fg($|0,z|0,ea|0,ba|0)|0;ea=z;A=Ze(C^ba,A^ea,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;H=Ze(L^p,H^u,63)|0;c[g+32>>2]=H;c[g+32+4>>2]=z;J=fg(K|0,V|0,_|0,J|0)|0;J=fg(J|0,z|0,c[r>>2]|0,c[r+4>>2]|0)|0;_=z;w=Ze(h^J,w^_,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;_=fg(J|0,_|0,V|0,K|0)|0;Q=fg(_|0,z|0,M|0,Q|0)|0;M=z;h=Ze(w^Q,h^M,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;ia=fg(B|0,D|0,ga|0,ia|0)|0;ia=fg(ia|0,z|0,c[P>>2]|0,c[P+4>>2]|0)|0;ga=z;s=Ze(n^ia,s^ga,32)|0;n=z;G=fg(da|0,G|0,s|0,n|0)|0;da=z;D=Ze(B^G,D^da,24)|0;B=z;ga=fg(ia|0,ga|0,D|0,B|0)|0;ga=fg(ga|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;ia=z;n=Ze(s^ga,n^ia,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;da=fg(G|0,da|0,n|0,s|0)|0;G=z;B=Ze(D^da,B^G,63)|0;D=z;Y=fg(m|0,o|0,T|0,Y|0)|0;Y=fg(Y|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;T=z;_=Ze(c[g+120>>2]^Y,c[g+120+4>>2]^T,32)|0;J=z;F=fg(E|0,F|0,_|0,J|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;T=fg(Y|0,T|0,o|0,m|0)|0;T=fg(T|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;Y=z;J=Ze(_^T,J^Y,16)|0;_=z;E=fg(F|0,E|0,J|0,_|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;ea=fg(K|0,V|0,ba|0,ea|0)|0;ea=fg(ea|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;ba=z;_=Ze(J^ea,_^ba,32)|0;J=z;G=fg(da|0,G|0,_|0,J|0)|0;da=z;V=Ze(K^G,V^da,24)|0;K=z;ba=fg(ea|0,ba|0,V|0,K|0)|0;ba=fg(ba|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;ea=z;J=Ze(_^ba,J^ea,16)|0;_=z;c[g+120>>2]=J;c[g+120+4>>2]=_;_=fg(G|0,da|0,J|0,_|0)|0;J=z;c[g+80>>2]=_;c[g+80+4>>2]=J;K=Ze(V^_,K^J,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;M=fg(B|0,D|0,Q|0,M|0)|0;Q=c[t>>2]|0;da=c[t+4>>2]|0;M=fg(M|0,z|0,Q|0,da|0)|0;G=z;C=Ze(A^M,C^G,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;G=fg(M|0,G|0,D|0,B|0)|0;M=c[O>>2]|0;H=c[O+4>>2]|0;G=fg(G|0,z|0,M|0,H|0)|0;L=z;A=Ze(C^G,A^L,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;ia=fg(m|0,o|0,ga|0,ia|0)|0;ga=c[X>>2]|0;$=c[X+4>>2]|0;ia=fg(ia|0,z|0,ga|0,$|0)|0;b=z;w=Ze(h^ia,w^b,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;b=fg(ia|0,b|0,o|0,m|0)|0;ia=c[g+128>>2]|0;ha=c[g+128+4>>2]|0;b=fg(b|0,z|0,ia|0,ha|0)|0;fa=z;h=Ze(w^b,h^fa,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;S=c[g+32>>2]|0;k=c[g+32+4>>2]|0;Y=fg(S|0,k|0,T|0,Y|0)|0;T=c[y>>2]|0;Z=c[y+4>>2]|0;Y=fg(Y|0,z|0,T|0,Z|0)|0;W=z;s=Ze(n^Y,s^W,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;k=Ze(S^I,k^U,24)|0;S=z;W=fg(Y|0,W|0,k|0,S|0)|0;W=fg(W|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;Y=z;n=Ze(s^W,n^Y,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;S=Ze(k^U,S^I,63)|0;k=z;ea=fg(ba|0,ea|0,S|0,k|0)|0;ea=fg(ea|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;ba=z;C=Ze(A^ea,C^ba,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;k=Ze(S^u,k^p,24)|0;S=z;ba=fg(ea|0,ba|0,k|0,S|0)|0;ha=fg(ba|0,z|0,ia|0,ha|0)|0;ia=z;A=Ze(C^ha,A^ia,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;S=Ze(k^p,S^u,63)|0;c[g+32>>2]=S;c[g+32+4>>2]=z;L=fg(K|0,V|0,G|0,L|0)|0;da=fg(L|0,z|0,Q|0,da|0)|0;Q=z;w=Ze(h^da,w^Q,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;Q=fg(da|0,Q|0,V|0,K|0)|0;Q=fg(Q|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;da=z;h=Ze(w^Q,h^da,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;fa=fg(B|0,D|0,b|0,fa|0)|0;fa=fg(fa|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;b=z;s=Ze(n^fa,s^b,32)|0;n=z;J=fg(_|0,J|0,s|0,n|0)|0;_=z;D=Ze(B^J,D^_,24)|0;B=z;b=fg(fa|0,b|0,D|0,B|0)|0;$=fg(b|0,z|0,ga|0,$|0)|0;ga=z;n=Ze(s^$,n^ga,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;_=fg(J|0,_|0,n|0,s|0)|0;J=z;B=Ze(D^_,B^J,63)|0;D=z;Y=fg(m|0,o|0,W|0,Y|0)|0;H=fg(Y|0,z|0,M|0,H|0)|0;M=z;Y=Ze(c[g+120>>2]^H,c[g+120+4>>2]^M,32)|0;W=z;F=fg(E|0,F|0,Y|0,W|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;M=fg(H|0,M|0,o|0,m|0)|0;Z=fg(M|0,z|0,T|0,Z|0)|0;T=z;W=Ze(Y^Z,W^T,16)|0;Y=z;E=fg(F|0,E|0,W|0,Y|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;ia=fg(K|0,V|0,ha|0,ia|0)|0;ia=fg(ia|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;ha=z;Y=Ze(W^ia,Y^ha,32)|0;W=z;J=fg(_|0,J|0,Y|0,W|0)|0;_=z;V=Ze(K^J,V^_,24)|0;K=z;ha=fg(ia|0,ha|0,V|0,K|0)|0;ha=fg(ha|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;ia=z;W=Ze(Y^ha,W^ia,16)|0;Y=z;c[g+120>>2]=W;c[g+120+4>>2]=Y;Y=fg(J|0,_|0,W|0,Y|0)|0;W=z;c[g+80>>2]=Y;c[g+80+4>>2]=W;K=Ze(V^Y,K^W,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;da=fg(B|0,D|0,Q|0,da|0)|0;Q=c[x>>2]|0;_=c[x+4>>2]|0;da=fg(da|0,z|0,Q|0,_|0)|0;J=z;C=Ze(A^da,C^J,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;J=fg(da|0,J|0,D|0,B|0)|0;da=c[i>>2]|0;M=c[i+4>>2]|0;J=fg(J|0,z|0,da|0,M|0)|0;H=z;A=Ze(C^J,A^H,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;ga=fg(m|0,o|0,$|0,ga|0)|0;$=c[q>>2]|0;b=c[q+4>>2]|0;ga=fg(ga|0,z|0,$|0,b|0)|0;fa=z;w=Ze(h^ga,w^fa,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;fa=fg(ga|0,fa|0,o|0,m|0)|0;ga=c[d>>2]|0;L=c[d+4>>2]|0;fa=fg(fa|0,z|0,ga|0,L|0)|0;G=z;h=Ze(w^fa,h^G,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;S=c[g+32>>2]|0;k=c[g+32+4>>2]|0;T=fg(S|0,k|0,Z|0,T|0)|0;Z=c[r>>2]|0;ba=c[r+4>>2]|0;T=fg(T|0,z|0,Z|0,ba|0)|0;ea=z;s=Ze(n^T,s^ea,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;k=Ze(S^I,k^U,24)|0;S=z;ea=fg(T|0,ea|0,k|0,S|0)|0;T=c[P>>2]|0;j=c[P+4>>2]|0;ea=fg(ea|0,z|0,T|0,j|0)|0;ca=z;n=Ze(s^ea,n^ca,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;S=Ze(k^U,S^I,63)|0;k=z;ia=fg(ha|0,ia|0,S|0,k|0)|0;ia=fg(ia|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;ha=z;C=Ze(A^ia,C^ha,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;k=Ze(S^u,k^p,24)|0;S=z;ha=fg(ia|0,ha|0,k|0,S|0)|0;M=fg(ha|0,z|0,da|0,M|0)|0;da=z;A=Ze(C^M,A^da,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;S=Ze(k^p,S^u,63)|0;c[g+32>>2]=S;c[g+32+4>>2]=z;H=fg(K|0,V|0,J|0,H|0)|0;b=fg(H|0,z|0,$|0,b|0)|0;$=z;w=Ze(h^b,w^$,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;$=fg(b|0,$|0,V|0,K|0)|0;$=fg($|0,z|0,c[O>>2]|0,c[O+4>>2]|0)|0;b=z;h=Ze(w^$,h^b,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;G=fg(B|0,D|0,fa|0,G|0)|0;G=fg(G|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;fa=z;s=Ze(n^G,s^fa,32)|0;n=z;W=fg(Y|0,W|0,s|0,n|0)|0;Y=z;D=Ze(B^W,D^Y,24)|0;B=z;fa=fg(G|0,fa|0,D|0,B|0)|0;_=fg(fa|0,z|0,Q|0,_|0)|0;Q=z;n=Ze(s^_,n^Q,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;Y=fg(W|0,Y|0,n|0,s|0)|0;W=z;B=Ze(D^Y,B^W,63)|0;D=z;ca=fg(m|0,o|0,ea|0,ca|0)|0;L=fg(ca|0,z|0,ga|0,L|0)|0;ga=z;ca=Ze(c[g+120>>2]^L,c[g+120+4>>2]^ga,32)|0;ea=z;F=fg(E|0,F|0,ca|0,ea|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;ga=fg(L|0,ga|0,o|0,m|0)|0;ba=fg(ga|0,z|0,Z|0,ba|0)|0;Z=z;ea=Ze(ca^ba,ea^Z,16)|0;ca=z;E=fg(F|0,E|0,ea|0,ca|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;da=fg(K|0,V|0,M|0,da|0)|0;da=fg(da|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;M=z;ca=Ze(ea^da,ca^M,32)|0;ea=z;W=fg(Y|0,W|0,ca|0,ea|0)|0;Y=z;V=Ze(K^W,V^Y,24)|0;K=z;M=fg(da|0,M|0,V|0,K|0)|0;j=fg(M|0,z|0,T|0,j|0)|0;T=z;ea=Ze(ca^j,ea^T,16)|0;ca=z;c[g+120>>2]=ea;c[g+120+4>>2]=ca;ca=fg(W|0,Y|0,ea|0,ca|0)|0;ea=z;c[g+80>>2]=ca;c[g+80+4>>2]=ea;K=Ze(V^ca,K^ea,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;b=fg(B|0,D|0,$|0,b|0)|0;b=fg(b|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;$=z;C=Ze(A^b,C^$,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;$=fg(b|0,$|0,D|0,B|0)|0;b=c[t>>2]|0;Y=c[t+4>>2]|0;$=fg($|0,z|0,b|0,Y|0)|0;W=z;A=Ze(C^$,A^W,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;Q=fg(m|0,o|0,_|0,Q|0)|0;_=c[y>>2]|0;M=c[y+4>>2]|0;Q=fg(Q|0,z|0,_|0,M|0)|0;da=z;w=Ze(h^Q,w^da,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;da=fg(Q|0,da|0,o|0,m|0)|0;Q=c[aa>>2]|0;ga=c[aa+4>>2]|0;da=fg(da|0,z|0,Q|0,ga|0)|0;L=z;h=Ze(w^da,h^L,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;fa=c[g+32>>2]|0;G=c[g+32+4>>2]|0;Z=fg(fa|0,G|0,ba|0,Z|0)|0;ba=c[N>>2]|0;H=c[N+4>>2]|0;Z=fg(Z|0,z|0,ba|0,H|0)|0;J=z;s=Ze(n^Z,s^J,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;G=Ze(fa^I,G^U,24)|0;fa=z;J=fg(Z|0,J|0,G|0,fa|0)|0;J=fg(J|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;Z=z;n=Ze(s^J,n^Z,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;fa=Ze(G^U,fa^I,63)|0;G=z;T=fg(j|0,T|0,fa|0,G|0)|0;T=fg(T|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;j=z;C=Ze(A^T,C^j,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;G=Ze(fa^u,G^p,24)|0;fa=z;j=fg(T|0,j|0,G|0,fa|0)|0;Y=fg(j|0,z|0,b|0,Y|0)|0;b=z;A=Ze(C^Y,A^b,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;fa=Ze(G^p,fa^u,63)|0;c[g+32>>2]=fa;c[g+32+4>>2]=z;W=fg(K|0,V|0,$|0,W|0)|0;H=fg(W|0,z|0,ba|0,H|0)|0;ba=z;w=Ze(h^H,w^ba,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;ba=fg(H|0,ba|0,V|0,K|0)|0;M=fg(ba|0,z|0,_|0,M|0)|0;_=z;h=Ze(w^M,h^_,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;L=fg(B|0,D|0,da|0,L|0)|0;ga=fg(L|0,z|0,Q|0,ga|0)|0;Q=z;s=Ze(n^ga,s^Q,32)|0;n=z;ea=fg(ca|0,ea|0,s|0,n|0)|0;ca=z;D=Ze(B^ea,D^ca,24)|0;B=z;Q=fg(ga|0,Q|0,D|0,B|0)|0;ga=c[P>>2]|0;L=c[P+4>>2]|0;Q=fg(Q|0,z|0,ga|0,L|0)|0;da=z;n=Ze(s^Q,n^da,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;ca=fg(ea|0,ca|0,n|0,s|0)|0;ea=z;B=Ze(D^ca,B^ea,63)|0;D=z;Z=fg(m|0,o|0,J|0,Z|0)|0;Z=fg(Z|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;J=z;ba=Ze(c[g+120>>2]^Z,c[g+120+4>>2]^J,32)|0;H=z;F=fg(E|0,F|0,ba|0,H|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;J=fg(Z|0,J|0,o|0,m|0)|0;J=fg(J|0,z|0,c[O>>2]|0,c[O+4>>2]|0)|0;Z=z;H=Ze(ba^J,H^Z,16)|0;ba=z;E=fg(F|0,E|0,H|0,ba|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;b=fg(K|0,V|0,Y|0,b|0)|0;b=fg(b|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;Y=z;ba=Ze(H^b,ba^Y,32)|0;H=z;ea=fg(ca|0,ea|0,ba|0,H|0)|0;ca=z;V=Ze(K^ea,V^ca,24)|0;K=z;Y=fg(b|0,Y|0,V|0,K|0)|0;b=c[v>>2]|0;W=c[v+4>>2]|0;Y=fg(Y|0,z|0,b|0,W|0)|0;$=z;H=Ze(ba^Y,H^$,16)|0;ba=z;c[g+120>>2]=H;c[g+120+4>>2]=ba;ba=fg(ea|0,ca|0,H|0,ba|0)|0;H=z;c[g+80>>2]=ba;c[g+80+4>>2]=H;K=Ze(V^ba,K^H,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;_=fg(B|0,D|0,M|0,_|0)|0;_=fg(_|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;M=z;C=Ze(A^_,C^M,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;M=fg(_|0,M|0,D|0,B|0)|0;_=c[r>>2]|0;ca=c[r+4>>2]|0;M=fg(M|0,z|0,_|0,ca|0)|0;ea=z;A=Ze(C^M,A^ea,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;da=fg(m|0,o|0,Q|0,da|0)|0;Q=c[R>>2]|0;fa=c[R+4>>2]|0;da=fg(da|0,z|0,Q|0,fa|0)|0;G=z;w=Ze(h^da,w^G,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;G=fg(da|0,G|0,o|0,m|0)|0;G=fg(G|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;da=z;h=Ze(w^G,h^da,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;j=c[g+32>>2]|0;T=c[g+32+4>>2]|0;Z=fg(j|0,T|0,J|0,Z|0)|0;Z=fg(Z|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;J=z;s=Ze(n^Z,s^J,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;T=Ze(j^I,T^U,24)|0;j=z;J=fg(Z|0,J|0,T|0,j|0)|0;Z=c[x>>2]|0;S=c[x+4>>2]|0;J=fg(J|0,z|0,Z|0,S|0)|0;k=z;n=Ze(s^J,n^k,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;j=Ze(T^U,j^I,63)|0;T=z;$=fg(Y|0,$|0,j|0,T|0)|0;L=fg($|0,z|0,ga|0,L|0)|0;ga=z;C=Ze(A^L,C^ga,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;T=Ze(j^u,T^p,24)|0;j=z;ga=fg(L|0,ga|0,T|0,j|0)|0;S=fg(ga|0,z|0,Z|0,S|0)|0;Z=z;A=Ze(C^S,A^Z,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;j=Ze(T^p,j^u,63)|0;c[g+32>>2]=j;c[g+32+4>>2]=z;ea=fg(K|0,V|0,M|0,ea|0)|0;W=fg(ea|0,z|0,b|0,W|0)|0;b=z;w=Ze(h^W,w^b,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;b=fg(W|0,b|0,V|0,K|0)|0;b=fg(b|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;W=z;h=Ze(w^b,h^W,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;da=fg(B|0,D|0,G|0,da|0)|0;da=fg(da|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;G=z;s=Ze(n^da,s^G,32)|0;n=z;H=fg(ba|0,H|0,s|0,n|0)|0;ba=z;D=Ze(B^H,D^ba,24)|0;B=z;G=fg(da|0,G|0,D|0,B|0)|0;G=fg(G|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;da=z;n=Ze(s^G,n^da,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;ba=fg(H|0,ba|0,n|0,s|0)|0;H=z;B=Ze(D^ba,B^H,63)|0;D=z;k=fg(m|0,o|0,J|0,k|0)|0;ca=fg(k|0,z|0,_|0,ca|0)|0;_=z;k=Ze(c[g+120>>2]^ca,c[g+120+4>>2]^_,32)|0;J=z;F=fg(E|0,F|0,k|0,J|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;_=fg(ca|0,_|0,o|0,m|0)|0;fa=fg(_|0,z|0,Q|0,fa|0)|0;Q=z;J=Ze(k^fa,J^Q,16)|0;k=z;E=fg(F|0,E|0,J|0,k|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;Z=fg(K|0,V|0,S|0,Z|0)|0;Z=fg(Z|0,z|0,c[t>>2]|0,c[t+4>>2]|0)|0;S=z;k=Ze(J^Z,k^S,32)|0;J=z;H=fg(ba|0,H|0,k|0,J|0)|0;ba=z;V=Ze(K^H,V^ba,24)|0;K=z;S=fg(Z|0,S|0,V|0,K|0)|0;S=fg(S|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;Z=z;J=Ze(k^S,J^Z,16)|0;k=z;c[g+120>>2]=J;c[g+120+4>>2]=k;k=fg(H|0,ba|0,J|0,k|0)|0;J=z;c[g+80>>2]=k;c[g+80+4>>2]=J;K=Ze(V^k,K^J,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;W=fg(B|0,D|0,b|0,W|0)|0;b=c[y>>2]|0;ba=c[y+4>>2]|0;W=fg(W|0,z|0,b|0,ba|0)|0;H=z;C=Ze(A^W,C^H,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;H=fg(W|0,H|0,D|0,B|0)|0;H=fg(H|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;W=z;A=Ze(C^H,A^W,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;da=fg(m|0,o|0,G|0,da|0)|0;G=c[d>>2]|0;_=c[d+4>>2]|0;da=fg(da|0,z|0,G|0,_|0)|0;ca=z;w=Ze(h^da,w^ca,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;ca=fg(da|0,ca|0,o|0,m|0)|0;da=c[q>>2]|0;ea=c[q+4>>2]|0;ca=fg(ca|0,z|0,da|0,ea|0)|0;M=z;h=Ze(w^ca,h^M,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;j=c[g+32>>2]|0;T=c[g+32+4>>2]|0;Q=fg(j|0,T|0,fa|0,Q|0)|0;fa=c[e>>2]|0;ga=c[e+4>>2]|0;Q=fg(Q|0,z|0,fa|0,ga|0)|0;L=z;s=Ze(n^Q,s^L,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;T=Ze(j^I,T^U,24)|0;j=z;L=fg(Q|0,L|0,T|0,j|0)|0;L=fg(L|0,z|0,c[O>>2]|0,c[O+4>>2]|0)|0;Q=z;n=Ze(s^L,n^Q,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;j=Ze(T^U,j^I,63)|0;T=z;Z=fg(S|0,Z|0,j|0,T|0)|0;ea=fg(Z|0,z|0,da|0,ea|0)|0;da=z;C=Ze(A^ea,C^da,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;T=Ze(j^u,T^p,24)|0;j=z;da=fg(ea|0,da|0,T|0,j|0)|0;ba=fg(da|0,z|0,b|0,ba|0)|0;b=z;A=Ze(C^ba,A^b,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;j=Ze(T^p,j^u,63)|0;c[g+32>>2]=j;c[g+32+4>>2]=z;W=fg(K|0,V|0,H|0,W|0)|0;W=fg(W|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;H=z;w=Ze(h^W,w^H,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;H=fg(W|0,H|0,V|0,K|0)|0;H=fg(H|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;W=z;h=Ze(w^H,h^W,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;M=fg(B|0,D|0,ca|0,M|0)|0;M=fg(M|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;ca=z;s=Ze(n^M,s^ca,32)|0;n=z;J=fg(k|0,J|0,s|0,n|0)|0;k=z;D=Ze(B^J,D^k,24)|0;B=z;ca=fg(M|0,ca|0,D|0,B|0)|0;ca=fg(ca|0,z|0,c[r>>2]|0,c[r+4>>2]|0)|0;M=z;n=Ze(s^ca,n^M,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;k=fg(J|0,k|0,n|0,s|0)|0;J=z;B=Ze(D^k,B^J,63)|0;D=z;Q=fg(m|0,o|0,L|0,Q|0)|0;Q=fg(Q|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;L=z;j=Ze(c[g+120>>2]^Q,c[g+120+4>>2]^L,32)|0;T=z;F=fg(E|0,F|0,j|0,T|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;L=fg(Q|0,L|0,o|0,m|0)|0;_=fg(L|0,z|0,G|0,_|0)|0;G=z;T=Ze(j^_,T^G,16)|0;j=z;E=fg(F|0,E|0,T|0,j|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;b=fg(K|0,V|0,ba|0,b|0)|0;b=fg(b|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;ba=z;j=Ze(T^b,j^ba,32)|0;T=z;J=fg(k|0,J|0,j|0,T|0)|0;k=z;V=Ze(K^J,V^k,24)|0;K=z;ba=fg(b|0,ba|0,V|0,K|0)|0;ga=fg(ba|0,z|0,fa|0,ga|0)|0;fa=z;T=Ze(j^ga,T^fa,16)|0;j=z;c[g+120>>2]=T;c[g+120+4>>2]=j;j=fg(J|0,k|0,T|0,j|0)|0;T=z;c[g+80>>2]=j;c[g+80+4>>2]=T;K=Ze(V^j,K^T,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;W=fg(B|0,D|0,H|0,W|0)|0;W=fg(W|0,z|0,c[P>>2]|0,c[P+4>>2]|0)|0;H=z;C=Ze(A^W,C^H,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;H=fg(W|0,H|0,D|0,B|0)|0;W=c[v>>2]|0;k=c[v+4>>2]|0;H=fg(H|0,z|0,W|0,k|0)|0;J=z;A=Ze(C^H,A^J,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;M=fg(m|0,o|0,ca|0,M|0)|0;ca=c[N>>2]|0;ba=c[N+4>>2]|0;M=fg(M|0,z|0,ca|0,ba|0)|0;b=z;w=Ze(h^M,w^b,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;b=fg(M|0,b|0,o|0,m|0)|0;M=c[X>>2]|0;L=c[X+4>>2]|0;b=fg(b|0,z|0,M|0,L|0)|0;Q=z;h=Ze(w^b,h^Q,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;da=c[g+32>>2]|0;ea=c[g+32+4>>2]|0;G=fg(da|0,ea|0,_|0,G|0)|0;_=c[O>>2]|0;Z=c[O+4>>2]|0;G=fg(G|0,z|0,_|0,Z|0)|0;S=z;s=Ze(n^G,s^S,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;ea=Ze(da^I,ea^U,24)|0;da=z;S=fg(G|0,S|0,ea|0,da|0)|0;G=c[t>>2]|0;$=c[t+4>>2]|0;S=fg(S|0,z|0,G|0,$|0)|0;Y=z;n=Ze(s^S,n^Y,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;da=Ze(ea^U,da^I,63)|0;ea=z;fa=fg(ga|0,fa|0,da|0,ea|0)|0;Z=fg(fa|0,z|0,_|0,Z|0)|0;_=z;C=Ze(A^Z,C^_,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;ea=Ze(da^u,ea^p,24)|0;da=z;_=fg(Z|0,_|0,ea|0,da|0)|0;_=fg(_|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;Z=z;A=Ze(C^_,A^Z,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;da=Ze(ea^p,da^u,63)|0;c[g+32>>2]=da;c[g+32+4>>2]=z;J=fg(K|0,V|0,H|0,J|0)|0;J=fg(J|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;H=z;w=Ze(h^J,w^H,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;H=fg(J|0,H|0,V|0,K|0)|0;L=fg(H|0,z|0,M|0,L|0)|0;M=z;h=Ze(w^L,h^M,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;Q=fg(B|0,D|0,b|0,Q|0)|0;k=fg(Q|0,z|0,W|0,k|0)|0;W=z;s=Ze(n^k,s^W,32)|0;n=z;T=fg(j|0,T|0,s|0,n|0)|0;j=z;D=Ze(B^T,D^j,24)|0;B=z;W=fg(k|0,W|0,D|0,B|0)|0;W=fg(W|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;k=z;n=Ze(s^W,n^k,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;j=fg(T|0,j|0,n|0,s|0)|0;T=z;B=Ze(D^j,B^T,63)|0;D=z;Y=fg(m|0,o|0,S|0,Y|0)|0;ba=fg(Y|0,z|0,ca|0,ba|0)|0;ca=z;Y=Ze(c[g+120>>2]^ba,c[g+120+4>>2]^ca,32)|0;S=z;F=fg(E|0,F|0,Y|0,S|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;ca=fg(ba|0,ca|0,o|0,m|0)|0;$=fg(ca|0,z|0,G|0,$|0)|0;G=z;S=Ze(Y^$,S^G,16)|0;Y=z;E=fg(F|0,E|0,S|0,Y|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;Z=fg(K|0,V|0,_|0,Z|0)|0;Z=fg(Z|0,z|0,c[y>>2]|0,c[y+4>>2]|0)|0;_=z;Y=Ze(S^Z,Y^_,32)|0;S=z;T=fg(j|0,T|0,Y|0,S|0)|0;j=z;V=Ze(K^T,V^j,24)|0;K=z;_=fg(Z|0,_|0,V|0,K|0)|0;_=fg(_|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;Z=z;S=Ze(Y^_,S^Z,16)|0;Y=z;c[g+120>>2]=S;c[g+120+4>>2]=Y;Y=fg(T|0,j|0,S|0,Y|0)|0;S=z;c[g+80>>2]=Y;c[g+80+4>>2]=S;K=Ze(V^Y,K^S,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;M=fg(B|0,D|0,L|0,M|0)|0;M=fg(M|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;L=z;C=Ze(A^M,C^L,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;L=fg(M|0,L|0,D|0,B|0)|0;L=fg(L|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;M=z;A=Ze(C^L,A^M,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;k=fg(m|0,o|0,W|0,k|0)|0;W=c[r>>2]|0;j=c[r+4>>2]|0;k=fg(k|0,z|0,W|0,j|0)|0;T=z;w=Ze(h^k,w^T,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;T=fg(k|0,T|0,o|0,m|0)|0;T=fg(T|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;k=z;h=Ze(w^T,h^k,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;ca=c[g+32>>2]|0;ba=c[g+32+4>>2]|0;G=fg(ca|0,ba|0,$|0,G|0)|0;G=fg(G|0,z|0,c[P>>2]|0,c[P+4>>2]|0)|0;$=z;s=Ze(n^G,s^$,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;ba=Ze(ca^I,ba^U,24)|0;ca=z;$=fg(G|0,$|0,ba|0,ca|0)|0;G=c[g+128>>2]|0;Q=c[g+128+4>>2]|0;$=fg($|0,z|0,G|0,Q|0)|0;b=z;n=Ze(s^$,n^b,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;ca=Ze(ba^U,ca^I,63)|0;ba=z;Z=fg(_|0,Z|0,ca|0,ba|0)|0;Q=fg(Z|0,z|0,G|0,Q|0)|0;G=z;C=Ze(A^Q,C^G,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;ba=Ze(ca^u,ba^p,24)|0;ca=z;G=fg(Q|0,G|0,ba|0,ca|0)|0;G=fg(G|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;Q=z;A=Ze(C^G,A^Q,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;ca=Ze(ba^p,ca^u,63)|0;c[g+32>>2]=ca;c[g+32+4>>2]=z;M=fg(K|0,V|0,L|0,M|0)|0;M=fg(M|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;L=z;w=Ze(h^M,w^L,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;L=fg(M|0,L|0,V|0,K|0)|0;j=fg(L|0,z|0,W|0,j|0)|0;W=z;h=Ze(w^j,h^W,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;k=fg(B|0,D|0,T|0,k|0)|0;k=fg(k|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;T=z;s=Ze(n^k,s^T,32)|0;n=z;S=fg(Y|0,S|0,s|0,n|0)|0;Y=z;D=Ze(B^S,D^Y,24)|0;B=z;T=fg(k|0,T|0,D|0,B|0)|0;T=fg(T|0,z|0,c[t>>2]|0,c[t+4>>2]|0)|0;k=z;n=Ze(s^T,n^k,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;Y=fg(S|0,Y|0,n|0,s|0)|0;S=z;B=Ze(D^Y,B^S,63)|0;D=z;b=fg(m|0,o|0,$|0,b|0)|0;b=fg(b|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;$=z;L=Ze(c[g+120>>2]^b,c[g+120+4>>2]^$,32)|0;M=z;F=fg(E|0,F|0,L|0,M|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;$=fg(b|0,$|0,o|0,m|0)|0;$=fg($|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;b=z;M=Ze(L^$,M^b,16)|0;L=z;E=fg(F|0,E|0,M|0,L|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;Q=fg(K|0,V|0,G|0,Q|0)|0;G=c[d>>2]|0;d=c[d+4>>2]|0;Q=fg(Q|0,z|0,G|0,d|0)|0;ca=z;L=Ze(M^Q,L^ca,32)|0;M=z;S=fg(Y|0,S|0,L|0,M|0)|0;Y=z;V=Ze(K^S,V^Y,24)|0;K=z;ca=fg(Q|0,ca|0,V|0,K|0)|0;Q=c[R>>2]|0;R=c[R+4>>2]|0;ca=fg(ca|0,z|0,Q|0,R|0)|0;ba=z;M=Ze(L^ca,M^ba,16)|0;L=z;c[g+120>>2]=M;c[g+120+4>>2]=L;L=fg(S|0,Y|0,M|0,L|0)|0;M=z;c[g+80>>2]=L;c[g+80+4>>2]=M;K=Ze(V^L,K^M,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;W=fg(B|0,D|0,j|0,W|0)|0;j=c[O>>2]|0;O=c[O+4>>2]|0;W=fg(W|0,z|0,j|0,O|0)|0;Y=z;C=Ze(A^W,C^Y,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;Y=fg(W|0,Y|0,D|0,B|0)|0;Y=fg(Y|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;W=z;A=Ze(C^Y,A^W,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;k=fg(m|0,o|0,T|0,k|0)|0;k=fg(k|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;T=z;w=Ze(h^k,w^T,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;T=fg(k|0,T|0,o|0,m|0)|0;k=c[P>>2]|0;P=c[P+4>>2]|0;T=fg(T|0,z|0,k|0,P|0)|0;S=z;h=Ze(w^T,h^S,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;Z=c[g+32>>2]|0;_=c[g+32+4>>2]|0;b=fg(Z|0,_|0,$|0,b|0)|0;$=c[aa>>2]|0;aa=c[aa+4>>2]|0;b=fg(b|0,z|0,$|0,aa|0)|0;H=z;s=Ze(n^b,s^H,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;_=Ze(Z^I,_^U,24)|0;Z=z;H=fg(b|0,H|0,_|0,Z|0)|0;b=c[y>>2]|0;y=c[y+4>>2]|0;H=fg(H|0,z|0,b|0,y|0)|0;J=z;n=Ze(s^H,n^J,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;Z=Ze(_^U,Z^I,63)|0;_=z;ba=fg(ca|0,ba|0,Z|0,_|0)|0;aa=fg(ba|0,z|0,$|0,aa|0)|0;$=z;C=Ze(A^aa,C^$,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;_=Ze(Z^u,_^p,24)|0;Z=z;$=fg(aa|0,$|0,_|0,Z|0)|0;O=fg($|0,z|0,j|0,O|0)|0;j=z;A=Ze(C^O,A^j,16)|0;C=z;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;Z=Ze(_^p,Z^u,63)|0;c[g+32>>2]=Z;c[g+32+4>>2]=z;W=fg(K|0,V|0,Y|0,W|0)|0;X=fg(W|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;W=z;w=Ze(h^X,w^W,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;W=fg(X|0,W|0,V|0,K|0)|0;d=fg(W|0,z|0,G|0,d|0)|0;G=z;h=Ze(w^d,h^G,16)|0;w=z;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;I=Ze(V^U,K^I,63)|0;K=z;S=fg(B|0,D|0,T|0,S|0)|0;R=fg(S|0,z|0,Q|0,R|0)|0;Q=z;s=Ze(n^R,s^Q,32)|0;n=z;M=fg(L|0,M|0,s|0,n|0)|0;L=z;D=Ze(B^M,D^L,24)|0;B=z;Q=fg(R|0,Q|0,D|0,B|0)|0;y=fg(Q|0,z|0,b|0,y|0)|0;b=z;n=Ze(s^y,n^b,16)|0;s=z;L=fg(M|0,L|0,n|0,s|0)|0;M=z;B=Ze(D^L,B^M,63)|0;D=z;J=fg(m|0,o|0,H|0,J|0)|0;P=fg(J|0,z|0,k|0,P|0)|0;k=z;J=Ze(c[g+120>>2]^P,c[g+120+4>>2]^k,32)|0;H=z;F=fg(E|0,F|0,J|0,H|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;k=fg(P|0,k|0,o|0,m|0)|0;q=fg(k|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;k=z;H=Ze(J^q,H^k,16)|0;J=z;E=fg(F|0,E|0,H|0,J|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;j=fg(I|0,K|0,O|0,j|0)|0;N=fg(j|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;j=z;J=Ze(H^N,J^j,32)|0;H=z;M=fg(L|0,M|0,J|0,H|0)|0;L=z;K=Ze(I^M,K^L,24)|0;I=z;j=fg(N|0,j|0,K|0,I|0)|0;i=fg(j|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;j=z;c[g>>2]=i;c[g+4>>2]=j;H=Ze(J^i,H^j,16)|0;J=z;c[g+120>>2]=H;c[g+120+4>>2]=J;J=fg(M|0,L|0,H|0,J|0)|0;H=z;c[g+80>>2]=J;c[g+80+4>>2]=H;H=Ze(K^J,I^H,63)|0;c[g+40>>2]=H;c[g+40+4>>2]=z;G=fg(B|0,D|0,d|0,G|0)|0;G=fg(G|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;d=z;C=Ze(A^G,C^d,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;d=fg(G|0,d|0,D|0,B|0)|0;e=fg(d|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;d=z;c[g+8>>2]=e;c[g+8+4>>2]=d;A=Ze(C^e,A^d,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;C=fg(F|0,E|0,A|0,C|0)|0;A=z;c[g+88>>2]=C;c[g+88+4>>2]=A;A=Ze(D^C,B^A,63)|0;c[g+48>>2]=A;c[g+48+4>>2]=z;b=fg(m|0,o|0,y|0,b|0)|0;x=fg(b|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;b=z;w=Ze(h^x,w^b,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;b=fg(x|0,b|0,o|0,m|0)|0;v=fg(b|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;b=z;c[g+16>>2]=v;c[g+16+4>>2]=b;b=Ze(w^v,h^b,16)|0;h=z;c[g+104>>2]=b;c[g+104+4>>2]=h;h=fg(u|0,p|0,b|0,h|0)|0;b=z;c[g+64>>2]=h;c[g+64+4>>2]=b;m=Ze(o^h,m^b,63)|0;c[g+56>>2]=m;c[g+56+4>>2]=z;m=c[g+32>>2]|0;o=c[g+32+4>>2]|0;k=fg(m|0,o|0,q|0,k|0)|0;t=fg(k|0,z|0,c[t>>2]|0,c[t+4>>2]|0)|0;k=z;s=Ze(n^t,s^k,32)|0;n=z;q=fg(c[g+72>>2]|0,c[g+72+4>>2]|0,s|0,n|0)|0;p=z;o=Ze(m^q,o^p,24)|0;m=z;k=fg(t|0,k|0,o|0,m|0)|0;r=fg(k|0,z|0,c[r>>2]|0,c[r+4>>2]|0)|0;k=z;c[g+24>>2]=r;c[g+24+4>>2]=k;k=Ze(s^r,n^k,16)|0;n=z;c[g+112>>2]=k;c[g+112+4>>2]=n;n=fg(q|0,p|0,k|0,n|0)|0;k=z;c[g+72>>2]=n;c[g+72+4>>2]=k;k=Ze(o^n,m^k,63)|0;c[g+32>>2]=k;c[g+32+4>>2]=z;b=j^c[a+4>>2]^b;c[a>>2]=i^c[a>>2]^h;c[a+4>>2]=b;b=1;while(1){ia=a+(b<<3)|0;ha=g+(b+8<<3)|0;d=d^c[ia+4>>2]^c[ha+4>>2];c[ia>>2]=e^c[ia>>2]^c[ha>>2];c[ia+4>>2]=d;d=b+1|0;if((d|0)==8)break;b=d;e=c[g+(d<<3)>>2]|0;d=c[g+(d<<3)+4>>2]|0}l=f;return}function ha(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0,sa=0,ta=0,ua=0,va=0,wa=0,xa=0,ya=0,za=0,Aa=0,Ba=0,Ca=0,Da=0,Ea=0,Fa=0,Ga=0,Ha=0,Ia=0,Ja=0,Ka=0,La=0,Ma=0,Na=0,Oa=0,Pa=0,Qa=0,Ra=0,Sa=0,Ta=0,Ua=0,Va=0,Wa=0,Xa=0,Ya=0,Za=0,_a=0,$a=0,ab=0,bb=0,cb=0,db=0,eb=0,fb=0,gb=0,hb=0,ib=0,jb=0,kb=0,lb=0,mb=0,nb=0,ob=0,pb=0,qb=0,rb=0,sb=0,tb=0,ub=0,vb=0,wb=0,xb=0,yb=0,zb=0,Ab=0,Bb=0,Cb=0,Db=0,Eb=0,Fb=0,Gb=0,Hb=0,Ib=0,Jb=0,Kb=0,Lb=0,Mb=0,Nb=0,Ob=0,Pb=0,Qb=0,Rb=0,Sb=0,Tb=0,Ub=0,Vb=0,Wb=0,Xb=0,Yb=0,Zb=0,_b=0,$b=0,ac=0,bc=0,cc=0,dc=0,ec=0,fc=0,gc=0,hc=0,ic=0,jc=0,kc=0,lc=0,mc=0,nc=0,oc=0,pc=0,qc=0,rc=0,sc=0;Za=df(a[c>>0]|0,a[c+1>>0]|0,a[c+2>>0]|0)|0;nb=Qd(c+2|0)|0;nb=yf(nb|0,z|0,5)|0;A=df(a[c+5>>0]|0,a[c+6>>0]|0,a[c+7>>0]|0)|0;A=yf(A|0,z|0,2)|0;kb=Qd(c+7|0)|0;kb=yf(kb|0,z|0,7)|0;l=Qd(c+10|0)|0;l=yf(l|0,z|0,4)|0;J=df(a[c+13>>0]|0,a[c+14>>0]|0,a[c+15>>0]|0)|0;J=yf(J|0,z|0,1)|0;F=Qd(c+15|0)|0;F=yf(F|0,z|0,6)|0;ea=df(a[c+18>>0]|0,a[c+19>>0]|0,a[c+20>>0]|0)|0;ea=yf(ea|0,z|0,3)|0;ib=df(a[c+21>>0]|0,a[c+22>>0]|0,a[c+23>>0]|0)|0;I=Qd(c+23|0)|0;I=yf(I|0,z|0,5)|0;qc=df(a[c+26>>0]|0,a[c+27>>0]|0,a[c+28>>0]|0)|0;qc=yf(qc|0,z|0,2)|0;n=Qd(c+28|0)|0;n=yf(n|0,z|0,7)|0;ua=z;ub=df(a[d>>0]|0,a[d+1>>0]|0,a[d+2>>0]|0)|0;Ia=Qd(d+2|0)|0;Ia=yf(Ia|0,z|0,5)|0;Wa=df(a[d+5>>0]|0,a[d+6>>0]|0,a[d+7>>0]|0)|0;Wa=yf(Wa|0,z|0,2)|0;ca=Qd(d+7|0)|0;ca=yf(ca|0,z|0,7)|0;P=Qd(d+10|0)|0;P=yf(P|0,z|0,4)|0;ta=df(a[d+13>>0]|0,a[d+14>>0]|0,a[d+15>>0]|0)|0;ta=yf(ta|0,z|0,1)|0;xa=Qd(d+15|0)|0;xa=yf(xa|0,z|0,6)|0;rb=df(a[d+18>>0]|0,a[d+19>>0]|0,a[d+20>>0]|0)|0;rb=yf(rb|0,z|0,3)|0;na=df(a[d+21>>0]|0,a[d+22>>0]|0,a[d+23>>0]|0)|0;O=Qd(d+23|0)|0;O=yf(O|0,z|0,5)|0;Ja=df(a[d+26>>0]|0,a[d+27>>0]|0,a[d+28>>0]|0)|0;Ja=yf(Ja|0,z|0,2)|0;w=Qd(d+28|0)|0;w=yf(w|0,z|0,7)|0;qa=z;V=df(a[e>>0]|0,a[e+1>>0]|0,a[e+2>>0]|0)|0;oa=Qd(e+2|0)|0;oa=yf(oa|0,z|0,5)|0;sa=df(a[e+5>>0]|0,a[e+6>>0]|0,a[e+7>>0]|0)|0;sa=yf(sa|0,z|0,2)|0;Na=Qd(e+7|0)|0;Na=yf(Na|0,z|0,7)|0;ma=Qd(e+10|0)|0;ma=yf(ma|0,z|0,4)|0;Da=df(a[e+13>>0]|0,a[e+14>>0]|0,a[e+15>>0]|0)|0;Da=yf(Da|0,z|0,1)|0;fb=Qd(e+15|0)|0;fb=yf(fb|0,z|0,6)|0;g=df(a[e+18>>0]|0,a[e+19>>0]|0,a[e+20>>0]|0)|0;g=yf(g|0,z|0,3)|0;Ra=df(a[e+21>>0]|0,a[e+22>>0]|0,a[e+23>>0]|0)|0;E=Qd(e+23|0)|0;E=yf(E|0,z|0,5)|0;Qa=df(a[e+26>>0]|0,a[e+27>>0]|0,a[e+28>>0]|0)|0;Qa=yf(Qa|0,z|0,2)|0;c=Qd(e+28|0)|0;c=yf(c|0,z|0,7)|0;h=z;pa=af(ub&2097151|0,0,Za&2097151|0,0)|0;pa=fg(V&2097151|0,0,pa|0,z|0)|0;V=z;pc=af(Ia&2097151|0,0,Za&2097151|0,0)|0;oc=z;nc=af(ub&2097151|0,0,nb&2097151|0,0)|0;t=z;ja=af(Wa&2097151|0,0,Za&2097151|0,0)|0;ra=z;ka=af(Ia&2097151|0,0,nb&2097151|0,0)|0;ic=z;S=af(ub&2097151|0,0,A&2097151|0,0)|0;S=fg(ka|0,ic|0,S|0,z|0)|0;ra=fg(S|0,z|0,ja|0,ra|0)|0;sa=fg(ra|0,z|0,sa&2097151|0,0)|0;ra=z;ja=af(ca&2097151|0,0,Za&2097151|0,0)|0;S=z;ic=af(Wa&2097151|0,0,nb&2097151|0,0)|0;ka=z;mc=af(Ia&2097151|0,0,A&2097151|0,0)|0;lc=z;kc=af(ub&2097151|0,0,kb&2097151|0,0)|0;jc=z;Ca=af(P&2097151|0,0,Za&2097151|0,0)|0;la=z;$b=af(ca&2097151|0,0,nb&2097151|0,0)|0;_=z;bc=af(Wa&2097151|0,0,A&2097151|0,0)|0;Ba=z;cc=af(Ia&2097151|0,0,kb&2097151|0,0)|0;dc=z;ac=af(ub&2097151|0,0,l&2097151|0,0)|0;ac=fg(cc|0,dc|0,ac|0,z|0)|0;Ba=fg(ac|0,z|0,bc|0,Ba|0)|0;_=fg(Ba|0,z|0,$b|0,_|0)|0;la=fg(_|0,z|0,Ca|0,la|0)|0;ma=fg(la|0,z|0,ma&2097151|0,0)|0;la=z;Ca=af(ta&2097151|0,0,Za&2097151|0,0)|0;_=z;$b=af(P&2097151|0,0,nb&2097151|0,0)|0;Ba=z;bc=af(ca&2097151|0,0,A&2097151|0,0)|0;ac=z;dc=af(Wa&2097151|0,0,kb&2097151|0,0)|0;cc=z;hc=af(Ia&2097151|0,0,l&2097151|0,0)|0;gc=z;fc=af(ub&2097151|0,0,J&2097151|0,0)|0;ec=z;Y=af(xa&2097151|0,0,Za&2097151|0,0)|0;$a=z;Ob=af(ta&2097151|0,0,nb&2097151|0,0)|0;B=z;Qb=af(P&2097151|0,0,A&2097151|0,0)|0;X=z;Sb=af(ca&2097151|0,0,kb&2097151|0,0)|0;Pb=z;Ub=af(Wa&2097151|0,0,l&2097151|0,0)|0;Rb=z;Vb=af(Ia&2097151|0,0,J&2097151|0,0)|0;Wb=z;Tb=af(ub&2097151|0,0,F&2097151|0,0)|0;Tb=fg(Vb|0,Wb|0,Tb|0,z|0)|0;Rb=fg(Tb|0,z|0,Ub|0,Rb|0)|0;Pb=fg(Rb|0,z|0,Sb|0,Pb|0)|0;X=fg(Pb|0,z|0,Qb|0,X|0)|0;B=fg(X|0,z|0,Ob|0,B|0)|0;$a=fg(B|0,z|0,Y|0,$a|0)|0;fb=fg($a|0,z|0,fb&2097151|0,0)|0;$a=z;Y=af(rb&2097151|0,0,Za&2097151|0,0)|0;B=z;Ob=af(xa&2097151|0,0,nb&2097151|0,0)|0;X=z;Qb=af(ta&2097151|0,0,A&2097151|0,0)|0;Pb=z;Sb=af(P&2097151|0,0,kb&2097151|0,0)|0;Rb=z;Ub=af(ca&2097151|0,0,l&2097151|0,0)|0;Tb=z;Wb=af(Wa&2097151|0,0,J&2097151|0,0)|0;Vb=z;_b=af(Ia&2097151|0,0,F&2097151|0,0)|0;Zb=z;Yb=af(ub&2097151|0,0,ea&2097151|0,0)|0;Xb=z;zb=af(na&2097151|0,0,Za&2097151|0,0)|0;e=z;i=af(rb&2097151|0,0,nb&2097151|0,0)|0;Sa=z;xb=af(xa&2097151|0,0,A&2097151|0,0)|0;yb=z;Bb=af(ta&2097151|0,0,kb&2097151|0,0)|0;va=z;Db=af(P&2097151|0,0,l&2097151|0,0)|0;Ab=z;Fb=af(ca&2097151|0,0,J&2097151|0,0)|0;Cb=z;Hb=af(Wa&2097151|0,0,F&2097151|0,0)|0;Eb=z;Ib=af(Ia&2097151|0,0,ea&2097151|0,0)|0;Jb=z;Gb=af(ub&2097151|0,0,ib&2097151|0,0)|0;Gb=fg(Ib|0,Jb|0,Gb|0,z|0)|0;Eb=fg(Gb|0,z|0,Hb|0,Eb|0)|0;Cb=fg(Eb|0,z|0,Fb|0,Cb|0)|0;Ab=fg(Cb|0,z|0,Db|0,Ab|0)|0;va=fg(Ab|0,z|0,Bb|0,va|0)|0;yb=fg(va|0,z|0,xb|0,yb|0)|0;e=fg(yb|0,z|0,zb|0,e|0)|0;Sa=fg(e|0,z|0,i|0,Sa|0)|0;Ra=fg(Sa|0,z|0,Ra&2097151|0,0)|0;Sa=z;i=af(O&2097151|0,0,Za&2097151|0,0)|0;e=z;zb=af(na&2097151|0,0,nb&2097151|0,0)|0;yb=z;xb=af(rb&2097151|0,0,A&2097151|0,0)|0;va=z;Bb=af(xa&2097151|0,0,kb&2097151|0,0)|0;Ab=z;Db=af(ta&2097151|0,0,l&2097151|0,0)|0;Cb=z;Fb=af(P&2097151|0,0,J&2097151|0,0)|0;Eb=z;Hb=af(ca&2097151|0,0,F&2097151|0,0)|0;Gb=z;Jb=af(Wa&2097151|0,0,ea&2097151|0,0)|0;Ib=z;Nb=af(Ia&2097151|0,0,ib&2097151|0,0)|0;Mb=z;Lb=af(ub&2097151|0,0,I&2097151|0,0)|0;Kb=z;_a=af(Ja&2097151|0,0,Za&2097151|0,0)|0;Pa=z;ab=af(O&2097151|0,0,nb&2097151|0,0)|0;gb=z;$=af(na&2097151|0,0,A&2097151|0,0)|0;aa=z;U=af(rb&2097151|0,0,kb&2097151|0,0)|0;T=z;mb=af(xa&2097151|0,0,l&2097151|0,0)|0;lb=z;Ma=af(ta&2097151|0,0,J&2097151|0,0)|0;La=z;eb=af(P&2097151|0,0,F&2097151|0,0)|0;db=z;Ga=af(ca&2097151|0,0,ea&2097151|0,0)|0;Fa=z;Ua=af(Wa&2097151|0,0,ib&2097151|0,0)|0;Ta=z;wb=af(Ia&2097151|0,0,I&2097151|0,0)|0;L=z;Q=af(ub&2097151|0,0,qc&2097151|0,0)|0;Q=fg(wb|0,L|0,Q|0,z|0)|0;Ta=fg(Q|0,z|0,Ua|0,Ta|0)|0;Fa=fg(Ta|0,z|0,Ga|0,Fa|0)|0;db=fg(Fa|0,z|0,eb|0,db|0)|0;La=fg(db|0,z|0,Ma|0,La|0)|0;lb=fg(La|0,z|0,mb|0,lb|0)|0;aa=fg(lb|0,z|0,$|0,aa|0)|0;T=fg(aa|0,z|0,U|0,T|0)|0;gb=fg(T|0,z|0,ab|0,gb|0)|0;Pa=fg(gb|0,z|0,_a|0,Pa|0)|0;Qa=fg(Pa|0,z|0,Qa&2097151|0,0)|0;Pa=z;Za=af(w|0,qa|0,Za&2097151|0,0)|0;_a=z;gb=af(Ja&2097151|0,0,nb&2097151|0,0)|0;ab=z;T=af(O&2097151|0,0,A&2097151|0,0)|0;U=z;aa=af(na&2097151|0,0,kb&2097151|0,0)|0;$=z;lb=af(rb&2097151|0,0,l&2097151|0,0)|0;mb=z;La=af(xa&2097151|0,0,J&2097151|0,0)|0;Ma=z;db=af(ta&2097151|0,0,F&2097151|0,0)|0;eb=z;Fa=af(P&2097151|0,0,ea&2097151|0,0)|0;Ga=z;Ta=af(ca&2097151|0,0,ib&2097151|0,0)|0;Ua=z;Q=af(Wa&2097151|0,0,I&2097151|0,0)|0;L=z;wb=af(Ia&2097151|0,0,qc&2097151|0,0)|0;vb=z;ub=af(ub&2097151|0,0,n|0,ua|0)|0;tb=z;nb=af(w|0,qa|0,nb&2097151|0,0)|0;ob=z;bb=af(Ja&2097151|0,0,A&2097151|0,0)|0;v=z;M=af(O&2097151|0,0,kb&2097151|0,0)|0;cb=z;pb=af(na&2097151|0,0,l&2097151|0,0)|0;u=z;p=af(rb&2097151|0,0,J&2097151|0,0)|0;hb=z;q=af(xa&2097151|0,0,F&2097151|0,0)|0;qb=z;ha=af(ta&2097151|0,0,ea&2097151|0,0)|0;y=z;da=af(P&2097151|0,0,ib&2097151|0,0)|0;ia=z;Ha=af(ca&2097151|0,0,I&2097151|0,0)|0;R=z;jb=af(Wa&2097151|0,0,qc&2097151|0,0)|0;Va=z;Ia=af(Ia&2097151|0,0,n|0,ua|0)|0;Ia=fg(jb|0,Va|0,Ia|0,z|0)|0;R=fg(Ia|0,z|0,Ha|0,R|0)|0;ia=fg(R|0,z|0,da|0,ia|0)|0;y=fg(ia|0,z|0,ha|0,y|0)|0;qb=fg(y|0,z|0,q|0,qb|0)|0;u=fg(qb|0,z|0,pb|0,u|0)|0;hb=fg(u|0,z|0,p|0,hb|0)|0;cb=fg(hb|0,z|0,M|0,cb|0)|0;v=fg(cb|0,z|0,bb|0,v|0)|0;ob=fg(v|0,z|0,nb|0,ob|0)|0;nb=z;A=af(w|0,qa|0,A&2097151|0,0)|0;v=z;bb=af(Ja&2097151|0,0,kb&2097151|0,0)|0;cb=z;M=af(O&2097151|0,0,l&2097151|0,0)|0;hb=z;p=af(na&2097151|0,0,J&2097151|0,0)|0;u=z;pb=af(rb&2097151|0,0,F&2097151|0,0)|0;qb=z;q=af(xa&2097151|0,0,ea&2097151|0,0)|0;y=z;ha=af(ta&2097151|0,0,ib&2097151|0,0)|0;ia=z;da=af(P&2097151|0,0,I&2097151|0,0)|0;R=z;Ha=af(ca&2097151|0,0,qc&2097151|0,0)|0;Ia=z;Wa=af(Wa&2097151|0,0,n|0,ua|0)|0;Va=z;kb=af(w|0,qa|0,kb&2097151|0,0)|0;jb=z;Xa=af(Ja&2097151|0,0,l&2097151|0,0)|0;j=z;m=af(O&2097151|0,0,J&2097151|0,0)|0;Ya=z;W=af(na&2097151|0,0,F&2097151|0,0)|0;G=z;Z=af(rb&2097151|0,0,ea&2097151|0,0)|0;f=z;za=af(xa&2097151|0,0,ib&2097151|0,0)|0;r=z;wa=af(ta&2097151|0,0,I&2097151|0,0)|0;k=z;sb=af(P&2097151|0,0,qc&2097151|0,0)|0;o=z;ca=af(ca&2097151|0,0,n|0,ua|0)|0;ca=fg(sb|0,o|0,ca|0,z|0)|0;k=fg(ca|0,z|0,wa|0,k|0)|0;r=fg(k|0,z|0,za|0,r|0)|0;G=fg(r|0,z|0,W|0,G|0)|0;f=fg(G|0,z|0,Z|0,f|0)|0;Ya=fg(f|0,z|0,m|0,Ya|0)|0;j=fg(Ya|0,z|0,Xa|0,j|0)|0;jb=fg(j|0,z|0,kb|0,jb|0)|0;kb=z;l=af(w|0,qa|0,l&2097151|0,0)|0;j=z;Xa=af(Ja&2097151|0,0,J&2097151|0,0)|0;Ya=z;m=af(O&2097151|0,0,F&2097151|0,0)|0;f=z;Z=af(na&2097151|0,0,ea&2097151|0,0)|0;G=z;W=af(rb&2097151|0,0,ib&2097151|0,0)|0;r=z;za=af(xa&2097151|0,0,I&2097151|0,0)|0;k=z;wa=af(ta&2097151|0,0,qc&2097151|0,0)|0;ca=z;P=af(P&2097151|0,0,n|0,ua|0)|0;o=z;J=af(w|0,qa|0,J&2097151|0,0)|0;sb=z;fa=af(Ja&2097151|0,0,F&2097151|0,0)|0;Ka=z;Ea=af(O&2097151|0,0,ea&2097151|0,0)|0;C=z;ba=af(na&2097151|0,0,ib&2097151|0,0)|0;s=z;D=af(rb&2097151|0,0,I&2097151|0,0)|0;Aa=z;K=af(xa&2097151|0,0,qc&2097151|0,0)|0;ya=z;d=af(ta&2097151|0,0,n|0,ua|0)|0;d=fg(K|0,ya|0,d|0,z|0)|0;s=fg(d|0,z|0,ba|0,s|0)|0;Aa=fg(s|0,z|0,D|0,Aa|0)|0;C=fg(Aa|0,z|0,Ea|0,C|0)|0;Ka=fg(C|0,z|0,fa|0,Ka|0)|0;sb=fg(Ka|0,z|0,J|0,sb|0)|0;J=z;F=af(w|0,qa|0,F&2097151|0,0)|0;Ka=z;fa=af(Ja&2097151|0,0,ea&2097151|0,0)|0;C=z;Ea=af(O&2097151|0,0,ib&2097151|0,0)|0;Aa=z;D=af(na&2097151|0,0,I&2097151|0,0)|0;s=z;ba=af(rb&2097151|0,0,qc&2097151|0,0)|0;d=z;xa=af(xa&2097151|0,0,n|0,ua|0)|0;ya=z;ea=af(w|0,qa|0,ea&2097151|0,0)|0;K=z;ta=af(Ja&2097151|0,0,ib&2097151|0,0)|0;N=z;Oa=af(O&2097151|0,0,I&2097151|0,0)|0;H=z;x=af(na&2097151|0,0,qc&2097151|0,0)|0;ga=z;rb=af(rb&2097151|0,0,n|0,ua|0)|0;ga=fg(rb|0,z|0,x|0,ga|0)|0;H=fg(ga|0,z|0,Oa|0,H|0)|0;N=fg(H|0,z|0,ta|0,N|0)|0;K=fg(N|0,z|0,ea|0,K|0)|0;ea=z;ib=af(w|0,qa|0,ib&2097151|0,0)|0;N=z;ta=af(Ja&2097151|0,0,I&2097151|0,0)|0;H=z;Oa=af(O&2097151|0,0,qc&2097151|0,0)|0;ga=z;na=af(na&2097151|0,0,n|0,ua|0)|0;x=z;I=af(w|0,qa|0,I&2097151|0,0)|0;rb=z;sc=af(Ja&2097151|0,0,qc&2097151|0,0)|0;rc=z;O=af(O&2097151|0,0,n|0,ua|0)|0;O=fg(sc|0,rc|0,O|0,z|0)|0;rb=fg(O|0,z|0,I|0,rb|0)|0;I=z;qc=af(w|0,qa|0,qc&2097151|0,0)|0;O=z;Ja=af(Ja&2097151|0,0,n|0,ua|0)|0;Ja=fg(qc|0,O|0,Ja|0,z|0)|0;O=z;ua=af(w|0,qa|0,n|0,ua|0)|0;n=z;qa=fg(pa|0,V|0,1048576,0)|0;qa=yf(qa|0,z|0,21)|0;w=z;t=fg(pc|0,oc|0,nc|0,t|0)|0;oa=fg(t|0,z|0,oa&2097151|0,0)|0;oa=fg(oa|0,z|0,qa|0,w|0)|0;t=z;w=vf(qa|0,w|0,21)|0;w=cg(pa|0,V|0,w|0,z|0)|0;V=z;pa=fg(sa|0,ra|0,1048576,0)|0;pa=yf(pa|0,z|0,21)|0;qa=z;jc=fg(mc|0,lc|0,kc|0,jc|0)|0;ka=fg(jc|0,z|0,ic|0,ka|0)|0;S=fg(ka|0,z|0,ja|0,S|0)|0;Na=fg(S|0,z|0,Na&2097151|0,0)|0;Na=fg(Na|0,z|0,pa|0,qa|0)|0;S=z;qa=vf(pa|0,qa|0,21)|0;pa=z;ja=fg(ma|0,la|0,1048576,0)|0;ja=Xe(ja|0,z|0,21)|0;ka=z;ec=fg(hc|0,gc|0,fc|0,ec|0)|0;cc=fg(ec|0,z|0,dc|0,cc|0)|0;ac=fg(cc|0,z|0,bc|0,ac|0)|0;Ba=fg(ac|0,z|0,$b|0,Ba|0)|0;_=fg(Ba|0,z|0,Ca|0,_|0)|0;Da=fg(_|0,z|0,Da&2097151|0,0)|0;Da=fg(Da|0,z|0,ja|0,ka|0)|0;_=z;ka=vf(ja|0,ka|0,21)|0;ja=z;Ca=fg(fb|0,$a|0,1048576,0)|0;Ca=Xe(Ca|0,z|0,21)|0;Ba=z;Xb=fg(_b|0,Zb|0,Yb|0,Xb|0)|0;Vb=fg(Xb|0,z|0,Wb|0,Vb|0)|0;Tb=fg(Vb|0,z|0,Ub|0,Tb|0)|0;Rb=fg(Tb|0,z|0,Sb|0,Rb|0)|0;Pb=fg(Rb|0,z|0,Qb|0,Pb|0)|0;X=fg(Pb|0,z|0,Ob|0,X|0)|0;B=fg(X|0,z|0,Y|0,B|0)|0;g=fg(B|0,z|0,g&2097151|0,0)|0;g=fg(g|0,z|0,Ca|0,Ba|0)|0;B=z;Ba=vf(Ca|0,Ba|0,21)|0;Ca=z;Y=fg(Ra|0,Sa|0,1048576,0)|0;Y=Xe(Y|0,z|0,21)|0;X=z;Kb=fg(Nb|0,Mb|0,Lb|0,Kb|0)|0;Ib=fg(Kb|0,z|0,Jb|0,Ib|0)|0;Gb=fg(Ib|0,z|0,Hb|0,Gb|0)|0;Eb=fg(Gb|0,z|0,Fb|0,Eb|0)|0;Cb=fg(Eb|0,z|0,Db|0,Cb|0)|0;Ab=fg(Cb|0,z|0,Bb|0,Ab|0)|0;yb=fg(Ab|0,z|0,zb|0,yb|0)|0;va=fg(yb|0,z|0,xb|0,va|0)|0;e=fg(va|0,z|0,i|0,e|0)|0;e=fg(e|0,z|0,E&2097151|0,0)|0;e=fg(e|0,z|0,Y|0,X|0)|0;E=z;X=vf(Y|0,X|0,21)|0;Y=z;i=fg(Qa|0,Pa|0,1048576,0)|0;i=Xe(i|0,z|0,21)|0;va=z;tb=fg(wb|0,vb|0,ub|0,tb|0)|0;L=fg(tb|0,z|0,Q|0,L|0)|0;Ua=fg(L|0,z|0,Ta|0,Ua|0)|0;Ga=fg(Ua|0,z|0,Fa|0,Ga|0)|0;eb=fg(Ga|0,z|0,db|0,eb|0)|0;Ma=fg(eb|0,z|0,La|0,Ma|0)|0;$=fg(Ma|0,z|0,aa|0,$|0)|0;mb=fg($|0,z|0,lb|0,mb|0)|0;U=fg(mb|0,z|0,T|0,U|0)|0;_a=fg(U|0,z|0,Za|0,_a|0)|0;ab=fg(_a|0,z|0,gb|0,ab|0)|0;h=fg(ab|0,z|0,c|0,h|0)|0;h=fg(h|0,z|0,i|0,va|0)|0;c=z;va=vf(i|0,va|0,21)|0;i=z;ab=fg(ob|0,nb|0,1048576,0)|0;ab=Xe(ab|0,z|0,21)|0;gb=z;Va=fg(Ha|0,Ia|0,Wa|0,Va|0)|0;R=fg(Va|0,z|0,da|0,R|0)|0;ia=fg(R|0,z|0,ha|0,ia|0)|0;y=fg(ia|0,z|0,q|0,y|0)|0;u=fg(y|0,z|0,p|0,u|0)|0;qb=fg(u|0,z|0,pb|0,qb|0)|0;hb=fg(qb|0,z|0,M|0,hb|0)|0;cb=fg(hb|0,z|0,bb|0,cb|0)|0;v=fg(cb|0,z|0,A|0,v|0)|0;v=fg(v|0,z|0,ab|0,gb|0)|0;A=z;gb=vf(ab|0,gb|0,21)|0;ab=z;cb=fg(jb|0,kb|0,1048576,0)|0;cb=Xe(cb|0,z|0,21)|0;bb=z;o=fg(wa|0,ca|0,P|0,o|0)|0;k=fg(o|0,z|0,za|0,k|0)|0;G=fg(k|0,z|0,Z|0,G|0)|0;r=fg(G|0,z|0,W|0,r|0)|0;f=fg(r|0,z|0,m|0,f|0)|0;Ya=fg(f|0,z|0,Xa|0,Ya|0)|0;j=fg(Ya|0,z|0,l|0,j|0)|0;j=fg(j|0,z|0,cb|0,bb|0)|0;l=z;bb=vf(cb|0,bb|0,21)|0;cb=z;Ya=fg(sb|0,J|0,1048576,0)|0;Ya=Xe(Ya|0,z|0,21)|0;Xa=z;ya=fg(D|0,s|0,xa|0,ya|0)|0;d=fg(ya|0,z|0,ba|0,d|0)|0;Aa=fg(d|0,z|0,Ea|0,Aa|0)|0;C=fg(Aa|0,z|0,fa|0,C|0)|0;Ka=fg(C|0,z|0,F|0,Ka|0)|0;Ka=fg(Ka|0,z|0,Ya|0,Xa|0)|0;F=z;Xa=vf(Ya|0,Xa|0,21)|0;Ya=z;C=fg(K|0,ea|0,1048576,0)|0;C=Xe(C|0,z|0,21)|0;fa=z;x=fg(Oa|0,ga|0,na|0,x|0)|0;H=fg(x|0,z|0,ta|0,H|0)|0;N=fg(H|0,z|0,ib|0,N|0)|0;N=fg(N|0,z|0,C|0,fa|0)|0;ib=z;fa=vf(C|0,fa|0,21)|0;fa=cg(K|0,ea|0,fa|0,z|0)|0;ea=z;K=fg(rb|0,I|0,1048576,0)|0;K=Xe(K|0,z|0,21)|0;C=z;O=fg(Ja|0,O|0,K|0,C|0)|0;Ja=z;C=vf(K|0,C|0,21)|0;C=cg(rb|0,I|0,C|0,z|0)|0;I=z;rb=fg(ua|0,n|0,1048576,0)|0;rb=Xe(rb|0,z|0,21)|0;K=z;H=vf(rb|0,K|0,21)|0;H=cg(ua|0,n|0,H|0,z|0)|0;n=z;ua=fg(oa|0,t|0,1048576,0)|0;ua=yf(ua|0,z|0,21)|0;ta=z;x=vf(ua|0,ta|0,21)|0;x=cg(oa|0,t|0,x|0,z|0)|0;t=z;oa=fg(Na|0,S|0,1048576,0)|0;oa=Xe(oa|0,z|0,21)|0;na=z;ga=vf(oa|0,na|0,21)|0;ga=cg(Na|0,S|0,ga|0,z|0)|0;S=z;Na=fg(Da|0,_|0,1048576,0)|0;Na=Xe(Na|0,z|0,21)|0;Oa=z;Aa=vf(Na|0,Oa|0,21)|0;Aa=cg(Da|0,_|0,Aa|0,z|0)|0;_=z;Da=fg(g|0,B|0,1048576,0)|0;Da=Xe(Da|0,z|0,21)|0;Ea=z;d=vf(Da|0,Ea|0,21)|0;ba=z;ya=fg(e|0,E|0,1048576,0)|0;ya=Xe(ya|0,z|0,21)|0;xa=z;s=vf(ya|0,xa|0,21)|0;D=z;f=fg(h|0,c|0,1048576,0)|0;f=Xe(f|0,z|0,21)|0;m=z;r=vf(f|0,m|0,21)|0;W=z;G=fg(v|0,A|0,1048576,0)|0;G=Xe(G|0,z|0,21)|0;Z=z;k=vf(G|0,Z|0,21)|0;za=z;o=fg(j|0,l|0,1048576,0)|0;o=Xe(o|0,z|0,21)|0;P=z;ca=vf(o|0,P|0,21)|0;wa=z;hb=fg(Ka|0,F|0,1048576,0)|0;hb=Xe(hb|0,z|0,21)|0;M=z;ea=fg(hb|0,M|0,fa|0,ea|0)|0;fa=z;M=vf(hb|0,M|0,21)|0;M=cg(Ka|0,F|0,M|0,z|0)|0;F=z;Ka=fg(N|0,ib|0,1048576,0)|0;Ka=Xe(Ka|0,z|0,21)|0;hb=z;I=fg(Ka|0,hb|0,C|0,I|0)|0;C=z;hb=vf(Ka|0,hb|0,21)|0;hb=cg(N|0,ib|0,hb|0,z|0)|0;ib=z;N=fg(O|0,Ja|0,1048576,0)|0;N=Xe(N|0,z|0,21)|0;Ka=z;n=fg(N|0,Ka|0,H|0,n|0)|0;H=z;Ka=vf(N|0,Ka|0,21)|0;Ka=cg(O|0,Ja|0,Ka|0,z|0)|0;Ja=z;O=af(rb|0,K|0,666643,0)|0;N=z;qb=af(rb|0,K|0,470296,0)|0;pb=z;u=af(rb|0,K|0,654183,0)|0;p=z;y=af(rb|0,K|0,-997805,-1)|0;q=z;ia=af(rb|0,K|0,136657,0)|0;ha=z;K=af(rb|0,K|0,-683901,-1)|0;K=fg(sb|0,J|0,K|0,z|0)|0;Ya=cg(K|0,z|0,Xa|0,Ya|0)|0;P=fg(Ya|0,z|0,o|0,P|0)|0;o=z;Ya=af(n|0,H|0,666643,0)|0;Xa=z;K=af(n|0,H|0,470296,0)|0;J=z;sb=af(n|0,H|0,654183,0)|0;rb=z;R=af(n|0,H|0,-997805,-1)|0;da=z;Va=af(n|0,H|0,136657,0)|0;Wa=z;H=af(n|0,H|0,-683901,-1)|0;n=z;Ia=af(Ka|0,Ja|0,666643,0)|0;Ha=z;_a=af(Ka|0,Ja|0,470296,0)|0;Za=z;U=af(Ka|0,Ja|0,654183,0)|0;T=z;mb=af(Ka|0,Ja|0,-997805,-1)|0;lb=z;$=af(Ka|0,Ja|0,136657,0)|0;aa=z;Ja=af(Ka|0,Ja|0,-683901,-1)|0;Ka=z;q=fg(jb|0,kb|0,y|0,q|0)|0;Wa=fg(q|0,z|0,Va|0,Wa|0)|0;Ka=fg(Wa|0,z|0,Ja|0,Ka|0)|0;cb=cg(Ka|0,z|0,bb|0,cb|0)|0;Z=fg(cb|0,z|0,G|0,Z|0)|0;G=z;cb=af(I|0,C|0,666643,0)|0;bb=z;Ka=af(I|0,C|0,470296,0)|0;Ja=z;Wa=af(I|0,C|0,654183,0)|0;Va=z;q=af(I|0,C|0,-997805,-1)|0;y=z;kb=af(I|0,C|0,136657,0)|0;jb=z;C=af(I|0,C|0,-683901,-1)|0;I=z;Ma=af(hb|0,ib|0,666643,0)|0;La=z;eb=af(hb|0,ib|0,470296,0)|0;db=z;Ga=af(hb|0,ib|0,654183,0)|0;Fa=z;Ua=af(hb|0,ib|0,-997805,-1)|0;Ta=z;L=af(hb|0,ib|0,136657,0)|0;Q=z;ib=af(hb|0,ib|0,-683901,-1)|0;hb=z;pb=fg(sb|0,rb|0,qb|0,pb|0)|0;nb=fg(pb|0,z|0,ob|0,nb|0)|0;lb=fg(nb|0,z|0,mb|0,lb|0)|0;jb=fg(lb|0,z|0,kb|0,jb|0)|0;hb=fg(jb|0,z|0,ib|0,hb|0)|0;ab=cg(hb|0,z|0,gb|0,ab|0)|0;m=fg(ab|0,z|0,f|0,m|0)|0;f=z;ab=af(ea|0,fa|0,666643,0)|0;ab=fg(fb|0,$a|0,ab|0,z|0)|0;Oa=fg(ab|0,z|0,Na|0,Oa|0)|0;Ca=cg(Oa|0,z|0,Ba|0,Ca|0)|0;Ba=z;Oa=af(ea|0,fa|0,470296,0)|0;Na=z;ab=af(ea|0,fa|0,654183,0)|0;$a=z;bb=fg(eb|0,db|0,cb|0,bb|0)|0;$a=fg(bb|0,z|0,ab|0,$a|0)|0;Sa=fg($a|0,z|0,Ra|0,Sa|0)|0;Ea=fg(Sa|0,z|0,Da|0,Ea|0)|0;Y=cg(Ea|0,z|0,X|0,Y|0)|0;X=z;Ea=af(ea|0,fa|0,-997805,-1)|0;Da=z;Sa=af(ea|0,fa|0,136657,0)|0;Ra=z;Xa=fg(_a|0,Za|0,Ya|0,Xa|0)|0;Va=fg(Xa|0,z|0,Wa|0,Va|0)|0;Ta=fg(Va|0,z|0,Ua|0,Ta|0)|0;Ra=fg(Ta|0,z|0,Sa|0,Ra|0)|0;Pa=fg(Ra|0,z|0,Qa|0,Pa|0)|0;xa=fg(Pa|0,z|0,ya|0,xa|0)|0;i=cg(xa|0,z|0,va|0,i|0)|0;va=z;fa=af(ea|0,fa|0,-683901,-1)|0;ea=z;xa=fg(Ca|0,Ba|0,1048576,0)|0;xa=Xe(xa|0,z|0,21)|0;ya=z;La=fg(Oa|0,Na|0,Ma|0,La|0)|0;B=fg(La|0,z|0,g|0,B|0)|0;ba=cg(B|0,z|0,d|0,ba|0)|0;ba=fg(ba|0,z|0,xa|0,ya|0)|0;d=z;ya=vf(xa|0,ya|0,21)|0;xa=z;B=fg(Y|0,X|0,1048576,0)|0;B=Xe(B|0,z|0,21)|0;g=z;Ha=fg(Ka|0,Ja|0,Ia|0,Ha|0)|0;Fa=fg(Ha|0,z|0,Ga|0,Fa|0)|0;Da=fg(Fa|0,z|0,Ea|0,Da|0)|0;E=fg(Da|0,z|0,e|0,E|0)|0;D=cg(E|0,z|0,s|0,D|0)|0;D=fg(D|0,z|0,B|0,g|0)|0;s=z;g=vf(B|0,g|0,21)|0;B=z;E=fg(i|0,va|0,1048576,0)|0;E=Xe(E|0,z|0,21)|0;e=z;N=fg(K|0,J|0,O|0,N|0)|0;T=fg(N|0,z|0,U|0,T|0)|0;y=fg(T|0,z|0,q|0,y|0)|0;Q=fg(y|0,z|0,L|0,Q|0)|0;ea=fg(Q|0,z|0,fa|0,ea|0)|0;c=fg(ea|0,z|0,h|0,c|0)|0;W=cg(c|0,z|0,r|0,W|0)|0;W=fg(W|0,z|0,E|0,e|0)|0;r=z;e=vf(E|0,e|0,21)|0;E=z;c=fg(m|0,f|0,1048576,0)|0;c=Xe(c|0,z|0,21)|0;h=z;p=fg(R|0,da|0,u|0,p|0)|0;aa=fg(p|0,z|0,$|0,aa|0)|0;I=fg(aa|0,z|0,C|0,I|0)|0;A=fg(I|0,z|0,v|0,A|0)|0;za=cg(A|0,z|0,k|0,za|0)|0;za=fg(za|0,z|0,c|0,h|0)|0;k=z;h=vf(c|0,h|0,21)|0;h=cg(m|0,f|0,h|0,z|0)|0;f=z;m=fg(Z|0,G|0,1048576,0)|0;m=Xe(m|0,z|0,21)|0;c=z;ha=fg(H|0,n|0,ia|0,ha|0)|0;l=fg(ha|0,z|0,j|0,l|0)|0;wa=cg(l|0,z|0,ca|0,wa|0)|0;wa=fg(wa|0,z|0,m|0,c|0)|0;ca=z;c=vf(m|0,c|0,21)|0;c=cg(Z|0,G|0,c|0,z|0)|0;G=z;Z=fg(P|0,o|0,1048576,0)|0;Z=Xe(Z|0,z|0,21)|0;m=z;F=fg(Z|0,m|0,M|0,F|0)|0;M=z;m=vf(Z|0,m|0,21)|0;m=cg(P|0,o|0,m|0,z|0)|0;o=z;P=fg(ba|0,d|0,1048576,0)|0;P=Xe(P|0,z|0,21)|0;Z=z;l=vf(P|0,Z|0,21)|0;j=z;ha=fg(D|0,s|0,1048576,0)|0;ha=Xe(ha|0,z|0,21)|0;ia=z;n=vf(ha|0,ia|0,21)|0;H=z;A=fg(W|0,r|0,1048576,0)|0;A=Xe(A|0,z|0,21)|0;v=z;f=fg(A|0,v|0,h|0,f|0)|0;h=z;v=vf(A|0,v|0,21)|0;v=cg(W|0,r|0,v|0,z|0)|0;r=z;W=fg(za|0,k|0,1048576,0)|0;W=Xe(W|0,z|0,21)|0;A=z;G=fg(W|0,A|0,c|0,G|0)|0;c=z;A=vf(W|0,A|0,21)|0;A=cg(za|0,k|0,A|0,z|0)|0;k=z;za=fg(wa|0,ca|0,1048576,0)|0;za=Xe(za|0,z|0,21)|0;W=z;o=fg(za|0,W|0,m|0,o|0)|0;m=z;W=vf(za|0,W|0,21)|0;W=cg(wa|0,ca|0,W|0,z|0)|0;ca=z;wa=af(F|0,M|0,666643,0)|0;wa=fg(Aa|0,_|0,wa|0,z|0)|0;_=z;Aa=af(F|0,M|0,470296,0)|0;za=z;I=af(F|0,M|0,654183,0)|0;C=z;aa=af(F|0,M|0,-997805,-1)|0;$=z;p=af(F|0,M|0,136657,0)|0;u=z;M=af(F|0,M|0,-683901,-1)|0;M=fg(i|0,va|0,M|0,z|0)|0;ia=fg(M|0,z|0,ha|0,ia|0)|0;E=cg(ia|0,z|0,e|0,E|0)|0;e=z;ia=af(o|0,m|0,666643,0)|0;ha=z;M=af(o|0,m|0,470296,0)|0;M=fg(wa|0,_|0,M|0,z|0)|0;_=z;wa=af(o|0,m|0,654183,0)|0;va=z;i=af(o|0,m|0,-997805,-1)|0;F=z;da=af(o|0,m|0,136657,0)|0;R=z;m=af(o|0,m|0,-683901,-1)|0;o=z;ea=af(W|0,ca|0,666643,0)|0;ea=fg(ga|0,S|0,ea|0,z|0)|0;S=z;ga=af(W|0,ca|0,470296,0)|0;fa=z;Q=af(W|0,ca|0,654183,0)|0;Q=fg(M|0,_|0,Q|0,z|0)|0;_=z;M=af(W|0,ca|0,-997805,-1)|0;L=z;y=af(W|0,ca|0,136657,0)|0;q=z;ca=af(W|0,ca|0,-683901,-1)|0;W=z;$=fg(Y|0,X|0,aa|0,$|0)|0;Z=fg($|0,z|0,P|0,Z|0)|0;R=fg(Z|0,z|0,da|0,R|0)|0;W=fg(R|0,z|0,ca|0,W|0)|0;B=cg(W|0,z|0,g|0,B|0)|0;g=z;W=af(G|0,c|0,666643,0)|0;ca=z;R=af(G|0,c|0,470296,0)|0;R=fg(ea|0,S|0,R|0,z|0)|0;S=z;ea=af(G|0,c|0,654183,0)|0;da=z;Z=af(G|0,c|0,-997805,-1)|0;Z=fg(Q|0,_|0,Z|0,z|0)|0;_=z;Q=af(G|0,c|0,136657,0)|0;P=z;c=af(G|0,c|0,-683901,-1)|0;G=z;$=af(A|0,k|0,666643,0)|0;aa=z;X=af(A|0,k|0,470296,0)|0;Y=z;T=af(A|0,k|0,654183,0)|0;U=z;N=af(A|0,k|0,-997805,-1)|0;O=z;J=af(A|0,k|0,136657,0)|0;K=z;k=af(A|0,k|0,-683901,-1)|0;A=z;za=fg(Ca|0,Ba|0,Aa|0,za|0)|0;xa=cg(za|0,z|0,ya|0,xa|0)|0;va=fg(xa|0,z|0,wa|0,va|0)|0;L=fg(va|0,z|0,M|0,L|0)|0;P=fg(L|0,z|0,Q|0,P|0)|0;A=fg(P|0,z|0,k|0,A|0)|0;k=z;P=af(f|0,h|0,666643,0)|0;V=fg(P|0,z|0,w|0,V|0)|0;w=z;P=af(f|0,h|0,470296,0)|0;Q=z;L=af(f|0,h|0,654183,0)|0;M=z;ra=fg(ua|0,ta|0,sa|0,ra|0)|0;pa=cg(ra|0,z|0,qa|0,pa|0)|0;ca=fg(pa|0,z|0,W|0,ca|0)|0;M=fg(ca|0,z|0,L|0,M|0)|0;Y=fg(M|0,z|0,X|0,Y|0)|0;X=z;M=af(f|0,h|0,-997805,-1)|0;L=z;ca=af(f|0,h|0,136657,0)|0;W=z;la=fg(oa|0,na|0,ma|0,la|0)|0;ja=cg(la|0,z|0,ka|0,ja|0)|0;ha=fg(ja|0,z|0,ia|0,ha|0)|0;fa=fg(ha|0,z|0,ga|0,fa|0)|0;da=fg(fa|0,z|0,ea|0,da|0)|0;W=fg(da|0,z|0,ca|0,W|0)|0;O=fg(W|0,z|0,N|0,O|0)|0;N=z;h=af(f|0,h|0,-683901,-1)|0;f=z;W=fg(V|0,w|0,1048576,0)|0;W=Xe(W|0,z|0,21)|0;ca=z;Q=fg(x|0,t|0,P|0,Q|0)|0;aa=fg(Q|0,z|0,$|0,aa|0)|0;aa=fg(aa|0,z|0,W|0,ca|0)|0;$=z;ca=vf(W|0,ca|0,21)|0;ca=cg(V|0,w|0,ca|0,z|0)|0;w=z;V=fg(Y|0,X|0,1048576,0)|0;V=Xe(V|0,z|0,21)|0;W=z;L=fg(R|0,S|0,M|0,L|0)|0;U=fg(L|0,z|0,T|0,U|0)|0;U=fg(U|0,z|0,V|0,W|0)|0;T=z;W=vf(V|0,W|0,21)|0;V=z;L=fg(O|0,N|0,1048576,0)|0;L=Xe(L|0,z|0,21)|0;M=z;f=fg(Z|0,_|0,h|0,f|0)|0;K=fg(f|0,z|0,J|0,K|0)|0;K=fg(K|0,z|0,L|0,M|0)|0;J=z;M=vf(L|0,M|0,21)|0;L=z;f=fg(A|0,k|0,1048576,0)|0;f=Xe(f|0,z|0,21)|0;h=z;C=fg(ba|0,d|0,I|0,C|0)|0;F=fg(C|0,z|0,i|0,F|0)|0;j=cg(F|0,z|0,l|0,j|0)|0;q=fg(j|0,z|0,y|0,q|0)|0;G=fg(q|0,z|0,c|0,G|0)|0;G=fg(G|0,z|0,f|0,h|0)|0;c=z;h=vf(f|0,h|0,21)|0;h=cg(A|0,k|0,h|0,z|0)|0;k=z;A=fg(B|0,g|0,1048576,0)|0;A=Xe(A|0,z|0,21)|0;f=z;u=fg(m|0,o|0,p|0,u|0)|0;s=fg(u|0,z|0,D|0,s|0)|0;H=cg(s|0,z|0,n|0,H|0)|0;H=fg(H|0,z|0,A|0,f|0)|0;n=z;f=vf(A|0,f|0,21)|0;f=cg(B|0,g|0,f|0,z|0)|0;g=z;B=fg(E|0,e|0,1048576,0)|0;B=Xe(B|0,z|0,21)|0;A=z;r=fg(v|0,r|0,B|0,A|0)|0;v=z;A=vf(B|0,A|0,21)|0;B=z;s=fg(aa|0,$|0,1048576,0)|0;s=Xe(s|0,z|0,21)|0;D=z;u=vf(s|0,D|0,21)|0;p=z;o=fg(U|0,T|0,1048576,0)|0;o=Xe(o|0,z|0,21)|0;m=z;q=vf(o|0,m|0,21)|0;y=z;j=fg(K|0,J|0,1048576,0)|0;j=Xe(j|0,z|0,21)|0;l=z;k=fg(h|0,k|0,j|0,l|0)|0;h=z;l=vf(j|0,l|0,21)|0;j=z;F=fg(G|0,c|0,1048576,0)|0;F=Xe(F|0,z|0,21)|0;i=z;g=fg(f|0,g|0,F|0,i|0)|0;f=z;i=vf(F|0,i|0,21)|0;i=cg(G|0,c|0,i|0,z|0)|0;c=z;G=fg(H|0,n|0,1048576,0)|0;G=Xe(G|0,z|0,21)|0;F=z;C=vf(G|0,F|0,21)|0;C=cg(H|0,n|0,C|0,z|0)|0;n=z;H=fg(r|0,v|0,1048576,0)|0;H=Xe(H|0,z|0,21)|0;I=z;d=vf(H|0,I|0,21)|0;d=cg(r|0,v|0,d|0,z|0)|0;v=z;r=af(H|0,I|0,666643,0)|0;r=fg(ca|0,w|0,r|0,z|0)|0;w=z;ca=af(H|0,I|0,470296,0)|0;ba=z;_=af(H|0,I|0,654183,0)|0;Z=z;S=af(H|0,I|0,-997805,-1)|0;R=z;Q=af(H|0,I|0,136657,0)|0;P=z;I=af(H|0,I|0,-683901,-1)|0;H=z;t=Xe(r|0,w|0,21)|0;x=z;$=fg(ca|0,ba|0,aa|0,$|0)|0;p=cg($|0,z|0,u|0,p|0)|0;p=fg(p|0,z|0,t|0,x|0)|0;u=z;x=vf(t|0,x|0,21)|0;x=cg(r|0,w|0,x|0,z|0)|0;w=z;r=Xe(p|0,u|0,21)|0;t=z;X=fg(_|0,Z|0,Y|0,X|0)|0;V=cg(X|0,z|0,W|0,V|0)|0;D=fg(V|0,z|0,s|0,D|0)|0;D=fg(D|0,z|0,r|0,t|0)|0;s=z;t=vf(r|0,t|0,21)|0;t=cg(p|0,u|0,t|0,z|0)|0;u=z;p=Xe(D|0,s|0,21)|0;r=z;R=fg(U|0,T|0,S|0,R|0)|0;y=cg(R|0,z|0,q|0,y|0)|0;y=fg(y|0,z|0,p|0,r|0)|0;q=z;r=vf(p|0,r|0,21)|0;r=cg(D|0,s|0,r|0,z|0)|0;s=z;D=Xe(y|0,q|0,21)|0;p=z;N=fg(Q|0,P|0,O|0,N|0)|0;L=cg(N|0,z|0,M|0,L|0)|0;m=fg(L|0,z|0,o|0,m|0)|0;m=fg(m|0,z|0,D|0,p|0)|0;o=z;p=vf(D|0,p|0,21)|0;p=cg(y|0,q|0,p|0,z|0)|0;q=z;y=Xe(m|0,o|0,21)|0;D=z;H=fg(K|0,J|0,I|0,H|0)|0;j=cg(H|0,z|0,l|0,j|0)|0;j=fg(j|0,z|0,y|0,D|0)|0;l=z;D=vf(y|0,D|0,21)|0;D=cg(m|0,o|0,D|0,z|0)|0;o=z;m=Xe(j|0,l|0,21)|0;y=z;h=fg(k|0,h|0,m|0,y|0)|0;k=z;y=vf(m|0,y|0,21)|0;y=cg(j|0,l|0,y|0,z|0)|0;l=z;j=Xe(h|0,k|0,21)|0;m=z;c=fg(j|0,m|0,i|0,c|0)|0;i=z;m=vf(j|0,m|0,21)|0;m=cg(h|0,k|0,m|0,z|0)|0;k=z;h=Xe(c|0,i|0,21)|0;j=z;f=fg(g|0,f|0,h|0,j|0)|0;g=z;j=vf(h|0,j|0,21)|0;j=cg(c|0,i|0,j|0,z|0)|0;i=z;c=Xe(f|0,g|0,21)|0;h=z;n=fg(c|0,h|0,C|0,n|0)|0;C=z;h=vf(c|0,h|0,21)|0;h=cg(f|0,g|0,h|0,z|0)|0;g=z;f=Xe(n|0,C|0,21)|0;c=z;e=fg(G|0,F|0,E|0,e|0)|0;B=cg(e|0,z|0,A|0,B|0)|0;B=fg(B|0,z|0,f|0,c|0)|0;A=z;c=vf(f|0,c|0,21)|0;c=cg(n|0,C|0,c|0,z|0)|0;C=z;n=Xe(B|0,A|0,21)|0;f=z;v=fg(n|0,f|0,d|0,v|0)|0;d=z;f=vf(n|0,f|0,21)|0;f=cg(B|0,A|0,f|0,z|0)|0;A=z;B=Xe(v|0,d|0,21)|0;n=z;e=vf(B|0,n|0,21)|0;e=cg(v|0,d|0,e|0,z|0)|0;d=z;v=af(B|0,n|0,666643,0)|0;w=fg(v|0,z|0,x|0,w|0)|0;x=z;v=af(B|0,n|0,470296,0)|0;v=fg(t|0,u|0,v|0,z|0)|0;u=z;t=af(B|0,n|0,654183,0)|0;t=fg(r|0,s|0,t|0,z|0)|0;s=z;r=af(B|0,n|0,-997805,-1)|0;r=fg(p|0,q|0,r|0,z|0)|0;q=z;p=af(B|0,n|0,136657,0)|0;p=fg(D|0,o|0,p|0,z|0)|0;o=z;n=af(B|0,n|0,-683901,-1)|0;n=fg(y|0,l|0,n|0,z|0)|0;l=z;y=Xe(w|0,x|0,21)|0;B=z;u=fg(v|0,u|0,y|0,B|0)|0;v=z;B=vf(y|0,B|0,21)|0;B=cg(w|0,x|0,B|0,z|0)|0;x=z;w=Xe(u|0,v|0,21)|0;y=z;s=fg(t|0,s|0,w|0,y|0)|0;t=z;y=vf(w|0,y|0,21)|0;y=cg(u|0,v|0,y|0,z|0)|0;v=z;u=Xe(s|0,t|0,21)|0;w=z;q=fg(r|0,q|0,u|0,w|0)|0;r=z;w=vf(u|0,w|0,21)|0;w=cg(s|0,t|0,w|0,z|0)|0;t=z;s=Xe(q|0,r|0,21)|0;u=z;o=fg(p|0,o|0,s|0,u|0)|0;p=z;u=vf(s|0,u|0,21)|0;u=cg(q|0,r|0,u|0,z|0)|0;r=z;q=Xe(o|0,p|0,21)|0;s=z;l=fg(n|0,l|0,q|0,s|0)|0;n=z;s=vf(q|0,s|0,21)|0;s=cg(o|0,p|0,s|0,z|0)|0;p=z;o=Xe(l|0,n|0,21)|0;q=z;k=fg(o|0,q|0,m|0,k|0)|0;m=z;q=vf(o|0,q|0,21)|0;q=cg(l|0,n|0,q|0,z|0)|0;n=z;l=Xe(k|0,m|0,21)|0;o=z;i=fg(l|0,o|0,j|0,i|0)|0;j=z;o=vf(l|0,o|0,21)|0;o=cg(k|0,m|0,o|0,z|0)|0;m=z;k=Xe(i|0,j|0,21)|0;l=z;g=fg(k|0,l|0,h|0,g|0)|0;h=z;l=vf(k|0,l|0,21)|0;l=cg(i|0,j|0,l|0,z|0)|0;j=z;i=Xe(g|0,h|0,21)|0;k=z;C=fg(i|0,k|0,c|0,C|0)|0;c=z;k=vf(i|0,k|0,21)|0;k=cg(g|0,h|0,k|0,z|0)|0;h=z;g=Xe(C|0,c|0,21)|0;i=z;A=fg(g|0,i|0,f|0,A|0)|0;f=z;i=vf(g|0,i|0,21)|0;i=cg(C|0,c|0,i|0,z|0)|0;c=z;C=Xe(A|0,f|0,21)|0;g=z;d=fg(C|0,g|0,e|0,d|0)|0;e=z;g=vf(C|0,g|0,21)|0;g=cg(A|0,f|0,g|0,z|0)|0;f=z;a[b>>0]=B;A=yf(B|0,x|0,8)|0;a[b+1>>0]=A;x=yf(B|0,x|0,16)|0;B=z;A=vf(y|0,v|0,5)|0;a[b+2>>0]=A|x;x=yf(y|0,v|0,3)|0;a[b+3>>0]=x;x=yf(y|0,v|0,11)|0;a[b+4>>0]=x;v=yf(y|0,v|0,19)|0;y=z;x=vf(w|0,t|0,2)|0;a[b+5>>0]=x|v;v=yf(w|0,t|0,6)|0;a[b+6>>0]=v;t=yf(w|0,t|0,14)|0;w=z;v=vf(u|0,r|0,7)|0;a[b+7>>0]=v|t;t=yf(u|0,r|0,1)|0;a[b+8>>0]=t;t=yf(u|0,r|0,9)|0;a[b+9>>0]=t;r=yf(u|0,r|0,17)|0;u=z;t=vf(s|0,p|0,4)|0;a[b+10>>0]=t|r;r=yf(s|0,p|0,4)|0;a[b+11>>0]=r;r=yf(s|0,p|0,12)|0;a[b+12>>0]=r;p=yf(s|0,p|0,20)|0;s=z;r=vf(q|0,n|0,1)|0;a[b+13>>0]=r|p;p=yf(q|0,n|0,7)|0;a[b+14>>0]=p;n=yf(q|0,n|0,15)|0;q=z;p=vf(o|0,m|0,6)|0;a[b+15>>0]=p|n;n=yf(o|0,m|0,2)|0;a[b+16>>0]=n;n=yf(o|0,m|0,10)|0;a[b+17>>0]=n;m=yf(o|0,m|0,18)|0;o=z;n=vf(l|0,j|0,3)|0;a[b+18>>0]=n|m;m=yf(l|0,j|0,5)|0;a[b+19>>0]=m;j=yf(l|0,j|0,13)|0;a[b+20>>0]=j;a[b+21>>0]=k;j=yf(k|0,h|0,8)|0;a[b+22>>0]=j;h=yf(k|0,h|0,16)|0;k=z;j=vf(i|0,c|0,5)|0;a[b+23>>0]=j|h;h=yf(i|0,c|0,3)|0;a[b+24>>0]=h;h=yf(i|0,c|0,11)|0;a[b+25>>0]=h;c=yf(i|0,c|0,19)|0;i=z;h=vf(g|0,f|0,2)|0;a[b+26>>0]=h|c;c=yf(g|0,f|0,6)|0;a[b+27>>0]=c;f=yf(g|0,f|0,14)|0;g=z;c=vf(d|0,e|0,7)|0;a[b+28>>0]=f|c;c=yf(d|0,e|0,1)|0;a[b+29>>0]=c;c=yf(d|0,e|0,9)|0;a[b+30>>0]=c;e=yf(d|0,e|0,17)|0;a[b+31>>0]=e;return}function ia(a){a=a|0;var b=0,d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0;I=l;n=l=l+63&-64;l=l+16|0;do if(a>>>0<245){s=a>>>0<11?16:a+11&-8;r=c[8850]|0;if(r>>>(s>>>3)&3|0){a=35440+((r>>>(s>>>3)&1^1)+(s>>>3)<<1<<2)|0;b=c[a+8>>2]|0;d=c[b+8>>2]|0;do if((a|0)!=(d|0)){if(d>>>0<(c[8854]|0)>>>0)Z();if((c[d+12>>2]|0)==(b|0)){c[d+12>>2]=a;c[a+8>>2]=d;break}else Z()}else c[8850]=r&~(1<<(r>>>(s>>>3)&1^1)+(s>>>3));while(0);H=(r>>>(s>>>3)&1^1)+(s>>>3)<<3;c[b+4>>2]=H|3;c[b+H+4>>2]=c[b+H+4>>2]|1;H=b+8|0;l=I;return H|0}q=c[8852]|0;if(s>>>0>q>>>0){if(r>>>(s>>>3)|0){a=r>>>(s>>>3)<<(s>>>3)&(2<<(s>>>3)|0-(2<<(s>>>3)));e=((a&0-a)+-1|0)>>>(((a&0-a)+-1|0)>>>12&16);d=e>>>(e>>>5&8)>>>(e>>>(e>>>5&8)>>>2&4);d=(e>>>5&8|((a&0-a)+-1|0)>>>12&16|e>>>(e>>>5&8)>>>2&4|d>>>1&2|d>>>(d>>>1&2)>>>1&1)+(d>>>(d>>>1&2)>>>(d>>>(d>>>1&2)>>>1&1))|0;e=c[35440+(d<<1<<2)+8>>2]|0;a=c[e+8>>2]|0;do if((35440+(d<<1<<2)|0)!=(a|0)){if(a>>>0<(c[8854]|0)>>>0)Z();if((c[a+12>>2]|0)==(e|0)){c[a+12>>2]=35440+(d<<1<<2);c[35440+(d<<1<<2)+8>>2]=a;f=r;break}else Z()}else{c[8850]=r&~(1<<d);f=r&~(1<<d)}while(0);c[e+4>>2]=s|3;c[e+s+4>>2]=(d<<3)-s|1;c[e+s+((d<<3)-s)>>2]=(d<<3)-s;if(q|0){b=c[8855]|0;if(f&1<<(q>>>3)){a=c[35440+(q>>>3<<1<<2)+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{h=a;i=35440+(q>>>3<<1<<2)+8|0}}else{c[8850]=f|1<<(q>>>3);h=35440+(q>>>3<<1<<2)|0;i=35440+(q>>>3<<1<<2)+8|0}c[i>>2]=b;c[h+12>>2]=b;c[b+8>>2]=h;c[b+12>>2]=35440+(q>>>3<<1<<2)}c[8852]=(d<<3)-s;c[8855]=e+s;H=e+8|0;l=I;return H|0}k=c[8851]|0;if(k){b=((k&0-k)+-1|0)>>>(((k&0-k)+-1|0)>>>12&16);a=b>>>(b>>>5&8)>>>(b>>>(b>>>5&8)>>>2&4);a=c[35704+((b>>>5&8|((k&0-k)+-1|0)>>>12&16|b>>>(b>>>5&8)>>>2&4|a>>>1&2|a>>>(a>>>1&2)>>>1&1)+(a>>>(a>>>1&2)>>>(a>>>(a>>>1&2)>>>1&1))<<2)>>2]|0;b=(c[a+4>>2]&-8)-s|0;d=c[a+16+(((c[a+16>>2]|0)==0&1)<<2)>>2]|0;if(!d){j=a;h=b}else{do{G=(c[d+4>>2]&-8)-s|0;H=G>>>0<b>>>0;b=H?G:b;a=H?d:a;d=c[d+16+(((c[d+16>>2]|0)==0&1)<<2)>>2]|0}while((d|0)!=0);j=a;h=b}f=c[8854]|0;if(j>>>0<f>>>0)Z();i=j+s|0;if(j>>>0>=i>>>0)Z();g=c[j+24>>2]|0;a=c[j+12>>2]|0;do if((a|0)==(j|0)){b=j+20|0;a=c[b>>2]|0;if(!a){b=j+16|0;a=c[b>>2]|0;if(!a){m=0;break}}while(1){d=a+20|0;e=c[d>>2]|0;if(e|0){a=e;b=d;continue}d=a+16|0;e=c[d>>2]|0;if(!e)break;else{a=e;b=d}}if(b>>>0<f>>>0)Z();else{c[b>>2]=0;m=a;break}}else{b=c[j+8>>2]|0;if(b>>>0<f>>>0)Z();if((c[b+12>>2]|0)!=(j|0))Z();if((c[a+8>>2]|0)==(j|0)){c[b+12>>2]=a;c[a+8>>2]=b;m=a;break}else Z()}while(0);a:do if(g|0){a=c[j+28>>2]|0;do if((j|0)==(c[35704+(a<<2)>>2]|0)){c[35704+(a<<2)>>2]=m;if(!m){c[8851]=k&~(1<<a);break a}}else if(g>>>0>=(c[8854]|0)>>>0){c[g+16+(((c[g+16>>2]|0)!=(j|0)&1)<<2)>>2]=m;if(!m)break a;else break}else Z();while(0);b=c[8854]|0;if(m>>>0<b>>>0)Z();c[m+24>>2]=g;a=c[j+16>>2]|0;do if(a|0)if(a>>>0<b>>>0)Z();else{c[m+16>>2]=a;c[a+24>>2]=m;break}while(0);a=c[j+20>>2]|0;if(a|0)if(a>>>0<(c[8854]|0)>>>0)Z();else{c[m+20>>2]=a;c[a+24>>2]=m;break}}while(0);if(h>>>0<16){H=h+s|0;c[j+4>>2]=H|3;H=j+H+4|0;c[H>>2]=c[H>>2]|1}else{c[j+4>>2]=s|3;c[i+4>>2]=h|1;c[i+h>>2]=h;if(q|0){b=c[8855]|0;if(r&1<<(q>>>3)){a=c[35440+(q>>>3<<1<<2)+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{o=a;p=35440+(q>>>3<<1<<2)+8|0}}else{c[8850]=r|1<<(q>>>3);o=35440+(q>>>3<<1<<2)|0;p=35440+(q>>>3<<1<<2)+8|0}c[p>>2]=b;c[o+12>>2]=b;c[b+8>>2]=o;c[b+12>>2]=35440+(q>>>3<<1<<2)}c[8852]=h;c[8855]=i}H=j+8|0;l=I;return H|0}}}else if(a>>>0<=4294967231){s=a+11&-8;k=c[8851]|0;if(k){if((a+11|0)>>>8)if(s>>>0>16777215)i=31;else{i=(a+11|0)>>>8<<((((a+11|0)>>>8)+1048320|0)>>>16&8);i=14-((i+520192|0)>>>16&4|(((a+11|0)>>>8)+1048320|0)>>>16&8|((i<<((i+520192|0)>>>16&4))+245760|0)>>>16&2)+(i<<((i+520192|0)>>>16&4)<<(((i<<((i+520192|0)>>>16&4))+245760|0)>>>16&2)>>>15)|0;i=s>>>(i+7|0)&1|i<<1}else i=0;b=c[35704+(i<<2)>>2]|0;b:do if(!b){b=0;a=0;d=0-s|0;A=81}else{a=0;d=0-s|0;h=s<<((i|0)==31?0:25-(i>>>1)|0);f=0;while(1){e=(c[b+4>>2]&-8)-s|0;if(e>>>0<d>>>0)if(!e){a=b;d=0;e=b;A=85;break b}else{a=b;d=e}e=c[b+20>>2]|0;b=c[b+16+(h>>>31<<2)>>2]|0;f=(e|0)==0|(e|0)==(b|0)?f:e;e=(b|0)==0;if(e){b=f;A=81;break}else h=h<<((e^1)&1)}}while(0);if((A|0)==81){if((b|0)==0&(a|0)==0){a=2<<i;if(!(k&(a|0-a)))break;o=(k&(a|0-a)&0-(k&(a|0-a)))+-1|0;p=o>>>(o>>>12&16)>>>(o>>>(o>>>12&16)>>>5&8);b=p>>>(p>>>2&4)>>>(p>>>(p>>>2&4)>>>1&2);a=0;b=c[35704+((o>>>(o>>>12&16)>>>5&8|o>>>12&16|p>>>2&4|p>>>(p>>>2&4)>>>1&2|b>>>1&1)+(b>>>(b>>>1&1))<<2)>>2]|0}if(!b){j=a;i=d}else{e=b;A=85}}if((A|0)==85)while(1){A=0;b=(c[e+4>>2]&-8)-s|0;p=b>>>0<d>>>0;b=p?b:d;a=p?e:a;e=c[e+16+(((c[e+16>>2]|0)==0&1)<<2)>>2]|0;if(!e){j=a;i=b;break}else{d=b;A=85}}if((j|0)!=0?i>>>0<((c[8852]|0)-s|0)>>>0:0){f=c[8854]|0;if(j>>>0<f>>>0)Z();h=j+s|0;if(j>>>0>=h>>>0)Z();g=c[j+24>>2]|0;a=c[j+12>>2]|0;do if((a|0)==(j|0)){b=j+20|0;a=c[b>>2]|0;if(!a){b=j+16|0;a=c[b>>2]|0;if(!a){q=0;break}}while(1){d=a+20|0;e=c[d>>2]|0;if(e|0){a=e;b=d;continue}d=a+16|0;e=c[d>>2]|0;if(!e)break;else{a=e;b=d}}if(b>>>0<f>>>0)Z();else{c[b>>2]=0;q=a;break}}else{b=c[j+8>>2]|0;if(b>>>0<f>>>0)Z();if((c[b+12>>2]|0)!=(j|0))Z();if((c[a+8>>2]|0)==(j|0)){c[b+12>>2]=a;c[a+8>>2]=b;q=a;break}else Z()}while(0);c:do if(g){a=c[j+28>>2]|0;do if((j|0)==(c[35704+(a<<2)>>2]|0)){c[35704+(a<<2)>>2]=q;if(!q){c[8851]=k&~(1<<a);x=k&~(1<<a);break c}}else if(g>>>0>=(c[8854]|0)>>>0){c[g+16+(((c[g+16>>2]|0)!=(j|0)&1)<<2)>>2]=q;if(!q){x=k;break c}else break}else Z();while(0);b=c[8854]|0;if(q>>>0<b>>>0)Z();c[q+24>>2]=g;a=c[j+16>>2]|0;do if(a|0)if(a>>>0<b>>>0)Z();else{c[q+16>>2]=a;c[a+24>>2]=q;break}while(0);a=c[j+20>>2]|0;if(a)if(a>>>0<(c[8854]|0)>>>0)Z();else{c[q+20>>2]=a;c[a+24>>2]=q;x=k;break}else x=k}else x=k;while(0);do if(i>>>0>=16){c[j+4>>2]=s|3;c[h+4>>2]=i|1;c[h+i>>2]=i;b=i>>>3;if(i>>>0<256){a=c[8850]|0;if(a&1<<b){a=c[35440+(b<<1<<2)+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{r=a;w=35440+(b<<1<<2)+8|0}}else{c[8850]=a|1<<b;r=35440+(b<<1<<2)|0;w=35440+(b<<1<<2)+8|0}c[w>>2]=h;c[r+12>>2]=h;c[h+8>>2]=r;c[h+12>>2]=35440+(b<<1<<2);break}a=i>>>8;if(a)if(i>>>0>16777215)a=31;else{H=a<<((a+1048320|0)>>>16&8)<<(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4);a=14-(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4|(a+1048320|0)>>>16&8|(H+245760|0)>>>16&2)+(H<<((H+245760|0)>>>16&2)>>>15)|0;a=i>>>(a+7|0)&1|a<<1}else a=0;d=35704+(a<<2)|0;c[h+28>>2]=a;c[h+16+4>>2]=0;c[h+16>>2]=0;b=1<<a;if(!(x&b)){c[8851]=x|b;c[d>>2]=h;c[h+24>>2]=d;c[h+12>>2]=h;c[h+8>>2]=h;break}b=i<<((a|0)==31?0:25-(a>>>1)|0);e=c[d>>2]|0;while(1){if((c[e+4>>2]&-8|0)==(i|0)){A=139;break}d=e+16+(b>>>31<<2)|0;a=c[d>>2]|0;if(!a){A=136;break}else{b=b<<1;e=a}}if((A|0)==136)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[d>>2]=h;c[h+24>>2]=e;c[h+12>>2]=h;c[h+8>>2]=h;break}else if((A|0)==139){a=e+8|0;b=c[a>>2]|0;H=c[8854]|0;if(b>>>0>=H>>>0&e>>>0>=H>>>0){c[b+12>>2]=h;c[a>>2]=h;c[h+8>>2]=b;c[h+12>>2]=e;c[h+24>>2]=0;break}else Z()}}else{H=i+s|0;c[j+4>>2]=H|3;H=j+H+4|0;c[H>>2]=c[H>>2]|1}while(0);H=j+8|0;l=I;return H|0}}}else s=-1;while(0);d=c[8852]|0;if(d>>>0>=s>>>0){a=d-s|0;b=c[8855]|0;if(a>>>0>15){H=b+s|0;c[8855]=H;c[8852]=a;c[H+4>>2]=a|1;c[H+a>>2]=a;c[b+4>>2]=s|3}else{c[8852]=0;c[8855]=0;c[b+4>>2]=d|3;c[b+d+4>>2]=c[b+d+4>>2]|1}H=b+8|0;l=I;return H|0}f=c[8853]|0;if(f>>>0>s>>>0){F=f-s|0;c[8853]=F;H=c[8856]|0;G=H+s|0;c[8856]=G;c[G+4>>2]=F|1;c[H+4>>2]=s|3;H=H+8|0;l=I;return H|0}if(!(c[8968]|0)){c[8970]=4096;c[8969]=4096;c[8971]=-1;c[8972]=-1;c[8973]=0;c[8961]=0;c[n>>2]=n&-16^1431655768;c[8968]=n&-16^1431655768;a=4096}else a=c[8970]|0;h=s+48|0;i=s+47|0;k=a+i|0;j=0-a|0;if((k&j)>>>0<=s>>>0){H=0;l=I;return H|0}a=c[8960]|0;if(a|0?(x=c[8958]|0,(x+(k&j)|0)>>>0<=x>>>0?1:(x+(k&j)|0)>>>0>a>>>0):0){H=0;l=I;return H|0}d:do if(!(c[8961]&4)){d=c[8856]|0;e:do if(d){b=35848;while(1){a=c[b>>2]|0;if(a>>>0<=d>>>0?(t=b+4|0,(a+(c[t>>2]|0)|0)>>>0>d>>>0):0)break;a=c[b+8>>2]|0;if(!a){A=163;break e}else b=a}if((k-f&j)>>>0<2147483647){a=jd(k-f&j|0)|0;if((a|0)==((c[b>>2]|0)+(c[t>>2]|0)|0))if((a|0)==(-1|0))a=k-f&j;else{h=k-f&j;g=a;A=180;break d}else{e=a;d=k-f&j;A=171}}else a=0}else A=163;while(0);do if((A|0)==163){b=jd(0)|0;if((b|0)!=(-1|0)?(v=c[8969]|0,v=((v+-1&b|0)==0?0:(v+-1+b&0-v)-b|0)+(k&j)|0,u=c[8958]|0,v>>>0>s>>>0&v>>>0<2147483647):0){x=c[8960]|0;if(x|0?(v+u|0)>>>0<=u>>>0|(v+u|0)>>>0>x>>>0:0){a=0;break}a=jd(v|0)|0;if((a|0)==(b|0)){h=v;g=b;A=180;break d}else{e=a;d=v;A=171}}else a=0}while(0);do if((A|0)==171){b=0-d|0;if(!(h>>>0>d>>>0&(d>>>0<2147483647&(e|0)!=(-1|0))))if((e|0)==(-1|0)){a=0;break}else{h=d;g=e;A=180;break d}a=c[8970]|0;a=i-d+a&0-a;if(a>>>0>=2147483647){h=d;g=e;A=180;break d}if((jd(a|0)|0)==(-1|0)){jd(b|0)|0;a=0;break}else{h=a+d|0;g=e;A=180;break d}}while(0);c[8961]=c[8961]|4;A=178}else{a=0;A=178}while(0);if(((A|0)==178?(k&j)>>>0<2147483647:0)?(g=jd(k&j|0)|0,y=jd(0)|0,z=(y-g|0)>>>0>(s+40|0)>>>0,!((g|0)==(-1|0)|z^1|g>>>0<y>>>0&((g|0)!=(-1|0)&(y|0)!=(-1|0))^1)):0){h=z?y-g|0:a;A=180}if((A|0)==180){a=(c[8958]|0)+h|0;c[8958]=a;if(a>>>0>(c[8959]|0)>>>0)c[8959]=a;i=c[8856]|0;do if(i){a=35848;while(1){b=c[a>>2]|0;d=a+4|0;e=c[d>>2]|0;if((g|0)==(b+e|0)){A=190;break}f=c[a+8>>2]|0;if(!f)break;else a=f}if(((A|0)==190?(c[a+12>>2]&8|0)==0:0)?i>>>0<g>>>0&i>>>0>=b>>>0:0){c[d>>2]=e+h;G=(i+8&7|0)==0?0:0-(i+8)&7;H=(c[8853]|0)+(h-G)|0;c[8856]=i+G;c[8853]=H;c[i+G+4>>2]=H|1;c[i+G+H+4>>2]=40;c[8857]=c[8972];break}a=c[8854]|0;if(g>>>0<a>>>0){c[8854]=g;j=g}else j=a;d=g+h|0;a=35848;while(1){if((c[a>>2]|0)==(d|0)){A=198;break}b=c[a+8>>2]|0;if(!b)break;else a=b}if((A|0)==198?(c[a+12>>2]&8|0)==0:0){c[a>>2]=g;m=a+4|0;c[m>>2]=(c[m>>2]|0)+h;m=g+8|0;m=g+((m&7|0)==0?0:0-m&7)|0;a=d+((d+8&7|0)==0?0:0-(d+8)&7)|0;k=m+s|0;f=a-m-s|0;c[m+4>>2]=s|3;do if((a|0)!=(i|0)){if((a|0)==(c[8855]|0)){H=(c[8852]|0)+f|0;c[8852]=H;c[8855]=k;c[k+4>>2]=H|1;c[k+H>>2]=H;break}i=c[a+4>>2]|0;if((i&3|0)==1){f:do if(i>>>0>=256){h=c[a+24>>2]|0;b=c[a+12>>2]|0;do if((b|0)==(a|0)){b=c[a+16+4>>2]|0;if(!b){b=c[a+16>>2]|0;if(!b){F=0;break}else g=a+16|0}else g=a+16+4|0;while(1){d=b+20|0;e=c[d>>2]|0;if(e|0){b=e;g=d;continue}d=b+16|0;e=c[d>>2]|0;if(!e)break;else{b=e;g=d}}if(g>>>0<j>>>0)Z();else{c[g>>2]=0;F=b;break}}else{d=c[a+8>>2]|0;if(d>>>0<j>>>0)Z();if((c[d+12>>2]|0)!=(a|0))Z();if((c[b+8>>2]|0)==(a|0)){c[d+12>>2]=b;c[b+8>>2]=d;F=b;break}else Z()}while(0);if(!h)break;b=c[a+28>>2]|0;do if((a|0)!=(c[35704+(b<<2)>>2]|0))if(h>>>0>=(c[8854]|0)>>>0){c[h+16+(((c[h+16>>2]|0)!=(a|0)&1)<<2)>>2]=F;if(!F)break f;else break}else Z();else{c[35704+(b<<2)>>2]=F;if(F|0)break;c[8851]=c[8851]&~(1<<b);break f}while(0);d=c[8854]|0;if(F>>>0<d>>>0)Z();c[F+24>>2]=h;b=c[a+16>>2]|0;do if(b|0)if(b>>>0<d>>>0)Z();else{c[F+16>>2]=b;c[b+24>>2]=F;break}while(0);b=c[a+16+4>>2]|0;if(!b)break;if(b>>>0<(c[8854]|0)>>>0)Z();else{c[F+20>>2]=b;c[b+24>>2]=F;break}}else{b=c[a+8>>2]|0;d=c[a+12>>2]|0;do if((b|0)!=(35440+(i>>>3<<1<<2)|0)){if(b>>>0<j>>>0)Z();if((c[b+12>>2]|0)==(a|0))break;Z()}while(0);if((d|0)==(b|0)){c[8850]=c[8850]&~(1<<(i>>>3));break}do if((d|0)==(35440+(i>>>3<<1<<2)|0))E=d+8|0;else{if(d>>>0<j>>>0)Z();if((c[d+8>>2]|0)==(a|0)){E=d+8|0;break}Z()}while(0);c[b+12>>2]=d;c[E>>2]=b}while(0);a=a+(i&-8)|0;f=(i&-8)+f|0}b=a+4|0;c[b>>2]=c[b>>2]&-2;c[k+4>>2]=f|1;c[k+f>>2]=f;b=f>>>3;if(f>>>0<256){a=c[8850]|0;do if(!(a&1<<b)){c[8850]=a|1<<b;G=35440+(b<<1<<2)|0;H=35440+(b<<1<<2)+8|0}else{a=c[35440+(b<<1<<2)+8>>2]|0;if(a>>>0>=(c[8854]|0)>>>0){G=a;H=35440+(b<<1<<2)+8|0;break}Z()}while(0);c[H>>2]=k;c[G+12>>2]=k;c[k+8>>2]=G;c[k+12>>2]=35440+(b<<1<<2);break}a=f>>>8;do if(!a)a=0;else{if(f>>>0>16777215){a=31;break}H=a<<((a+1048320|0)>>>16&8)<<(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4);a=14-(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4|(a+1048320|0)>>>16&8|(H+245760|0)>>>16&2)+(H<<((H+245760|0)>>>16&2)>>>15)|0;a=f>>>(a+7|0)&1|a<<1}while(0);e=35704+(a<<2)|0;c[k+28>>2]=a;c[k+16+4>>2]=0;c[k+16>>2]=0;b=c[8851]|0;d=1<<a;if(!(b&d)){c[8851]=b|d;c[e>>2]=k;c[k+24>>2]=e;c[k+12>>2]=k;c[k+8>>2]=k;break}b=f<<((a|0)==31?0:25-(a>>>1)|0);e=c[e>>2]|0;while(1){if((c[e+4>>2]&-8|0)==(f|0)){A=265;break}d=e+16+(b>>>31<<2)|0;a=c[d>>2]|0;if(!a){A=262;break}else{b=b<<1;e=a}}if((A|0)==262)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[d>>2]=k;c[k+24>>2]=e;c[k+12>>2]=k;c[k+8>>2]=k;break}else if((A|0)==265){a=e+8|0;b=c[a>>2]|0;H=c[8854]|0;if(b>>>0>=H>>>0&e>>>0>=H>>>0){c[b+12>>2]=k;c[a>>2]=k;c[k+8>>2]=b;c[k+12>>2]=e;c[k+24>>2]=0;break}else Z()}}else{H=(c[8853]|0)+f|0;c[8853]=H;c[8856]=k;c[k+4>>2]=H|1}while(0);H=m+8|0;l=I;return H|0}a=35848;while(1){b=c[a>>2]|0;if(b>>>0<=i>>>0?(B=b+(c[a+4>>2]|0)|0,B>>>0>i>>>0):0)break;a=c[a+8>>2]|0}f=B+-47+((B+-47+8&7|0)==0?0:0-(B+-47+8)&7)|0;f=f>>>0<(i+16|0)>>>0?i:f;a=g+8|0;a=(a&7|0)==0?0:0-a&7;H=g+a|0;a=h+-40-a|0;c[8856]=H;c[8853]=a;c[H+4>>2]=a|1;c[H+a+4>>2]=40;c[8857]=c[8972];c[f+4>>2]=27;c[f+8>>2]=c[8962];c[f+8+4>>2]=c[8963];c[f+8+8>>2]=c[8964];c[f+8+12>>2]=c[8965];c[8962]=g;c[8963]=h;c[8965]=0;c[8964]=f+8;a=f+24|0;do{H=a;a=a+4|0;c[a>>2]=7}while((H+8|0)>>>0<B>>>0);if((f|0)!=(i|0)){c[f+4>>2]=c[f+4>>2]&-2;c[i+4>>2]=f-i|1;c[f>>2]=f-i;if((f-i|0)>>>0<256){b=35440+((f-i|0)>>>3<<1<<2)|0;a=c[8850]|0;if(a&1<<((f-i|0)>>>3)){a=c[b+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{C=a;D=b+8|0}}else{c[8850]=a|1<<((f-i|0)>>>3);C=b;D=b+8|0}c[D>>2]=i;c[C+12>>2]=i;c[i+8>>2]=C;c[i+12>>2]=b;break}if((f-i|0)>>>8)if((f-i|0)>>>0>16777215)a=31;else{a=(f-i|0)>>>8<<((((f-i|0)>>>8)+1048320|0)>>>16&8);a=14-((a+520192|0)>>>16&4|(((f-i|0)>>>8)+1048320|0)>>>16&8|((a<<((a+520192|0)>>>16&4))+245760|0)>>>16&2)+(a<<((a+520192|0)>>>16&4)<<(((a<<((a+520192|0)>>>16&4))+245760|0)>>>16&2)>>>15)|0;a=(f-i|0)>>>(a+7|0)&1|a<<1}else a=0;e=35704+(a<<2)|0;c[i+28>>2]=a;c[i+20>>2]=0;c[i+16>>2]=0;b=c[8851]|0;d=1<<a;if(!(b&d)){c[8851]=b|d;c[e>>2]=i;c[i+24>>2]=e;c[i+12>>2]=i;c[i+8>>2]=i;break}b=f-i<<((a|0)==31?0:25-(a>>>1)|0);e=c[e>>2]|0;while(1){if((c[e+4>>2]&-8|0)==(f-i|0)){A=292;break}d=e+16+(b>>>31<<2)|0;a=c[d>>2]|0;if(!a){A=289;break}else{b=b<<1;e=a}}if((A|0)==289)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[d>>2]=i;c[i+24>>2]=e;c[i+12>>2]=i;c[i+8>>2]=i;break}else if((A|0)==292){a=e+8|0;b=c[a>>2]|0;H=c[8854]|0;if(b>>>0>=H>>>0&e>>>0>=H>>>0){c[b+12>>2]=i;c[a>>2]=i;c[i+8>>2]=b;c[i+12>>2]=e;c[i+24>>2]=0;break}else Z()}}}else{H=c[8854]|0;if((H|0)==0|g>>>0<H>>>0)c[8854]=g;c[8962]=g;c[8963]=h;c[8965]=0;c[8859]=c[8968];c[8858]=-1;a=0;do{H=35440+(a<<1<<2)|0;c[H+12>>2]=H;c[H+8>>2]=H;a=a+1|0}while((a|0)!=32);H=g+8|0;H=(H&7|0)==0?0:0-H&7;G=g+H|0;H=h+-40-H|0;c[8856]=G;c[8853]=H;c[G+4>>2]=H|1;c[G+H+4>>2]=40;c[8857]=c[8972]}while(0);a=c[8853]|0;if(a>>>0>s>>>0){F=a-s|0;c[8853]=F;H=c[8856]|0;G=H+s|0;c[8856]=G;c[G+4>>2]=F|1;c[H+4>>2]=s|3;H=H+8|0;l=I;return H|0}}c[8326]=12;H=0;l=I;return H|0}function ja(a,b,d,e){a=a|0;b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0;De(d,b);b=e;f=a;g=b+64|0;do{c[b>>2]=c[f>>2];b=b+4|0;f=f+4|0}while((b|0)<(g|0));s=0;b=c[d>>2]|0;f=c[d+4>>2]|0;while(1){A=c[e+32>>2]|0;q=c[e+32+4>>2]|0;i=Ze(A,q,14)|0;C=z;y=Ze(A,q,18)|0;C=z^C;D=Ze(A,q,41)|0;r=c[e+40>>2]|0;l=c[e+40+4>>2]|0;k=c[e+48>>2]|0;M=c[e+48+4>>2]|0;o=464+(s<<3)|0;m=c[o>>2]|0;o=c[o+4>>2]|0;w=c[e+56>>2]|0;u=c[e+56+4>>2]|0;C=fg(b|0,f|0,y^i^D|0,C^z|0)|0;o=fg(C|0,z|0,m|0,o|0)|0;o=fg(o|0,z|0,(k^r)&A^k|0,(M^l)&q^M|0)|0;u=fg(o|0,z|0,w|0,u|0)|0;w=z;o=fg(u|0,w|0,c[e+24>>2]|0,c[e+24+4>>2]|0)|0;m=z;c[e+24>>2]=o;c[e+24+4>>2]=m;C=c[e>>2]|0;D=c[e+4>>2]|0;i=Ze(C,D,28)|0;y=z;j=Ze(C,D,34)|0;y=z^y;v=Ze(C,D,39)|0;B=c[e+8>>2]|0;H=c[e+8+4>>2]|0;E=c[e+16>>2]|0;I=c[e+16+4>>2]|0;y=fg(u|0,w|0,j^i^v|0,y^z|0)|0;y=fg(y|0,z|0,(E|B)&C|E&B|0,(I|H)&D|I&H|0)|0;v=z;c[e+56>>2]=y;c[e+56+4>>2]=v;i=Ze(o,m,14)|0;j=z;w=Ze(o,m,18)|0;j=z^j;u=Ze(o,m,41)|0;h=s|1;x=c[464+(h<<3)>>2]|0;L=c[464+(h<<3)+4>>2]|0;j=fg(c[d+(h<<3)>>2]|0,c[d+(h<<3)+4>>2]|0,w^i^u|0,j^z|0)|0;L=fg(j|0,z|0,x|0,L|0)|0;L=fg(L|0,z|0,(r^A)&o^r|0,(l^q)&m^l|0)|0;M=fg(L|0,z|0,k|0,M|0)|0;k=z;I=fg(M|0,k|0,E|0,I|0)|0;E=z;c[e+16>>2]=I;c[e+16+4>>2]=E;L=Ze(y,v,28)|0;x=z;j=Ze(y,v,34)|0;x=z^x;u=Ze(y,v,39)|0;x=fg(M|0,k|0,j^L^u|0,x^z|0)|0;x=fg(x|0,z|0,(B|C)&y|B&C|0,(H|D)&v|H&D|0)|0;u=z;c[e+48>>2]=x;c[e+48+4>>2]=u;L=Ze(I,E,14)|0;j=z;k=Ze(I,E,18)|0;j=z^j;M=Ze(I,E,41)|0;i=s|2;w=c[464+(i<<3)>>2]|0;n=c[464+(i<<3)+4>>2]|0;j=fg(c[d+(i<<3)>>2]|0,c[d+(i<<3)+4>>2]|0,k^L^M|0,j^z|0)|0;n=fg(j|0,z|0,w|0,n|0)|0;q=fg(n|0,z|0,(A^o)&I^A|0,(q^m)&E^q|0)|0;l=fg(q|0,z|0,r|0,l|0)|0;r=z;H=fg(l|0,r|0,B|0,H|0)|0;B=z;c[e+8>>2]=H;c[e+8+4>>2]=B;q=Ze(x,u,28)|0;A=z;n=Ze(x,u,34)|0;A=z^A;w=Ze(x,u,39)|0;A=fg(l|0,r|0,n^q^w|0,A^z|0)|0;A=fg(A|0,z|0,(C|y)&x|C&y|0,(D|v)&u|D&v|0)|0;w=z;c[e+40>>2]=A;c[e+40+4>>2]=w;q=Ze(H,B,14)|0;n=z;r=Ze(H,B,18)|0;n=z^n;l=Ze(H,B,41)|0;j=s|3;M=c[464+(j<<3)>>2]|0;L=c[464+(j<<3)+4>>2]|0;k=c[e+32>>2]|0;p=c[e+32+4>>2]|0;n=fg(c[d+(j<<3)>>2]|0,c[d+(j<<3)+4>>2]|0,r^q^l|0,n^z|0)|0;L=fg(n|0,z|0,M|0,L|0)|0;m=fg(L|0,z|0,(o^I)&H^o|0,(m^E)&B^m|0)|0;p=fg(m|0,z|0,k|0,p|0)|0;k=z;D=fg(p|0,k|0,C|0,D|0)|0;C=z;c[e>>2]=D;c[e+4>>2]=C;m=Ze(A,w,28)|0;o=z;L=Ze(A,w,34)|0;o=z^o;M=Ze(A,w,39)|0;o=fg(p|0,k|0,L^m^M|0,o^z|0)|0;v=fg(o|0,z|0,(y|x)&A|y&x|0,(v|u)&w|v&u|0)|0;y=z;c[e+32>>2]=v;c[e+32+4>>2]=y;o=Ze(D,C,14)|0;M=z;m=Ze(D,C,18)|0;M=z^M;L=Ze(D,C,41)|0;k=s|4;p=c[464+(k<<3)>>2]|0;n=c[464+(k<<3)+4>>2]|0;l=c[e+24>>2]|0;q=c[e+24+4>>2]|0;M=fg(c[d+(k<<3)>>2]|0,c[d+(k<<3)+4>>2]|0,m^o^L|0,M^z|0)|0;n=fg(M|0,z|0,p|0,n|0)|0;E=fg(n|0,z|0,(I^H)&D^I|0,(E^B)&C^E|0)|0;q=fg(E|0,z|0,l|0,q|0)|0;l=z;E=fg(q|0,l|0,c[e+56>>2]|0,c[e+56+4>>2]|0)|0;I=z;c[e+56>>2]=E;c[e+56+4>>2]=I;n=Ze(v,y,28)|0;p=z;M=Ze(v,y,34)|0;p=z^p;L=Ze(v,y,39)|0;p=fg(q|0,l|0,M^n^L|0,p^z|0)|0;u=fg(p|0,z|0,(x|A)&v|x&A|0,(u|w)&y|u&w|0)|0;x=z;c[e+24>>2]=u;c[e+24+4>>2]=x;p=Ze(E,I,14)|0;L=z;n=Ze(E,I,18)|0;L=z^L;M=Ze(E,I,41)|0;l=s|5;q=c[464+(l<<3)>>2]|0;o=c[464+(l<<3)+4>>2]|0;m=c[e+16>>2]|0;r=c[e+16+4>>2]|0;L=fg(c[d+(l<<3)>>2]|0,c[d+(l<<3)+4>>2]|0,n^p^M|0,L^z|0)|0;o=fg(L|0,z|0,q|0,o|0)|0;B=fg(o|0,z|0,(H^D)&E^H|0,(B^C)&I^B|0)|0;r=fg(B|0,z|0,m|0,r|0)|0;m=z;B=fg(r|0,m|0,c[e+48>>2]|0,c[e+48+4>>2]|0)|0;H=z;c[e+48>>2]=B;c[e+48+4>>2]=H;o=Ze(u,x,28)|0;q=z;L=Ze(u,x,34)|0;q=z^q;M=Ze(u,x,39)|0;q=fg(r|0,m|0,L^o^M|0,q^z|0)|0;w=fg(q|0,z|0,(A|v)&u|A&v|0,(w|y)&x|w&y|0)|0;A=z;c[e+16>>2]=w;c[e+16+4>>2]=A;q=Ze(B,H,14)|0;M=z;o=Ze(B,H,18)|0;M=z^M;L=Ze(B,H,41)|0;m=s|6;r=c[464+(m<<3)>>2]|0;p=c[464+(m<<3)+4>>2]|0;n=c[e+8>>2]|0;b=c[e+8+4>>2]|0;M=fg(c[d+(m<<3)>>2]|0,c[d+(m<<3)+4>>2]|0,o^q^L|0,M^z|0)|0;p=fg(M|0,z|0,r|0,p|0)|0;C=fg(p|0,z|0,(D^E)&B^D|0,(C^I)&H^C|0)|0;b=fg(C|0,z|0,n|0,b|0)|0;n=z;C=fg(b|0,n|0,c[e+40>>2]|0,c[e+40+4>>2]|0)|0;D=z;c[e+40>>2]=C;c[e+40+4>>2]=D;p=Ze(w,A,28)|0;r=z;M=Ze(w,A,34)|0;r=z^r;L=Ze(w,A,39)|0;r=fg(b|0,n|0,M^p^L|0,r^z|0)|0;y=fg(r|0,z|0,(v|u)&w|v&u|0,(y|x)&A|y&x|0)|0;v=z;c[e+8>>2]=y;c[e+8+4>>2]=v;r=Ze(C,D,14)|0;L=z;p=Ze(C,D,18)|0;L=z^L;M=Ze(C,D,41)|0;n=s|7;b=c[464+(n<<3)>>2]|0;q=c[464+(n<<3)+4>>2]|0;o=c[e>>2]|0;f=c[e+4>>2]|0;L=fg(c[d+(n<<3)>>2]|0,c[d+(n<<3)+4>>2]|0,p^r^M|0,L^z|0)|0;q=fg(L|0,z|0,b|0,q|0)|0;I=fg(q|0,z|0,(E^B)&C^E|0,(I^H)&D^I|0)|0;f=fg(I|0,z|0,o|0,f|0)|0;o=z;I=fg(f|0,o|0,c[e+32>>2]|0,c[e+32+4>>2]|0)|0;E=z;c[e+32>>2]=I;c[e+32+4>>2]=E;q=Ze(y,v,28)|0;b=z;L=Ze(y,v,34)|0;b=z^b;M=Ze(y,v,39)|0;b=fg(f|0,o|0,L^q^M|0,b^z|0)|0;x=fg(b|0,z|0,(u|w)&y|u&w|0,(x|A)&v|x&A|0)|0;u=z;c[e>>2]=x;c[e+4>>2]=u;b=Ze(I,E,14)|0;M=z;q=Ze(I,E,18)|0;M=z^M;L=Ze(I,E,41)|0;o=s|8;f=c[464+(o<<3)>>2]|0;r=c[464+(o<<3)+4>>2]|0;p=c[e+56>>2]|0;g=c[e+56+4>>2]|0;M=fg(c[d+(o<<3)>>2]|0,c[d+(o<<3)+4>>2]|0,q^b^L|0,M^z|0)|0;r=fg(M|0,z|0,f|0,r|0)|0;H=fg(r|0,z|0,(B^C)&I^B|0,(H^D)&E^H|0)|0;g=fg(H|0,z|0,p|0,g|0)|0;p=z;H=fg(g|0,p|0,c[e+24>>2]|0,c[e+24+4>>2]|0)|0;B=z;c[e+24>>2]=H;c[e+24+4>>2]=B;r=Ze(x,u,28)|0;f=z;M=Ze(x,u,34)|0;f=z^f;L=Ze(x,u,39)|0;f=fg(g|0,p|0,M^r^L|0,f^z|0)|0;A=fg(f|0,z|0,(w|y)&x|w&y|0,(A|v)&u|A&v|0)|0;w=z;c[e+56>>2]=A;c[e+56+4>>2]=w;f=Ze(H,B,14)|0;L=z;r=Ze(H,B,18)|0;L=z^L;M=Ze(H,B,41)|0;p=s|9;g=c[464+(p<<3)>>2]|0;b=c[464+(p<<3)+4>>2]|0;q=c[e+48>>2]|0;t=c[e+48+4>>2]|0;L=fg(c[d+(p<<3)>>2]|0,c[d+(p<<3)+4>>2]|0,r^f^M|0,L^z|0)|0;b=fg(L|0,z|0,g|0,b|0)|0;D=fg(b|0,z|0,(C^I)&H^C|0,(D^E)&B^D|0)|0;t=fg(D|0,z|0,q|0,t|0)|0;q=z;D=fg(t|0,q|0,c[e+16>>2]|0,c[e+16+4>>2]|0)|0;C=z;c[e+16>>2]=D;c[e+16+4>>2]=C;b=Ze(A,w,28)|0;g=z;L=Ze(A,w,34)|0;g=z^g;M=Ze(A,w,39)|0;g=fg(t|0,q|0,L^b^M|0,g^z|0)|0;v=fg(g|0,z|0,(y|x)&A|y&x|0,(v|u)&w|v&u|0)|0;y=z;c[e+48>>2]=v;c[e+48+4>>2]=y;g=Ze(D,C,14)|0;M=z;b=Ze(D,C,18)|0;M=z^M;L=Ze(D,C,41)|0;q=s|10;t=c[464+(q<<3)>>2]|0;f=c[464+(q<<3)+4>>2]|0;r=c[e+40>>2]|0;F=c[e+40+4>>2]|0;M=fg(c[d+(q<<3)>>2]|0,c[d+(q<<3)+4>>2]|0,b^g^L|0,M^z|0)|0;f=fg(M|0,z|0,t|0,f|0)|0;E=fg(f|0,z|0,(I^H)&D^I|0,(E^B)&C^E|0)|0;F=fg(E|0,z|0,r|0,F|0)|0;r=z;E=fg(F|0,r|0,c[e+8>>2]|0,c[e+8+4>>2]|0)|0;I=z;c[e+8>>2]=E;c[e+8+4>>2]=I;f=Ze(v,y,28)|0;t=z;M=Ze(v,y,34)|0;t=z^t;L=Ze(v,y,39)|0;t=fg(F|0,r|0,M^f^L|0,t^z|0)|0;u=fg(t|0,z|0,(x|A)&v|x&A|0,(u|w)&y|u&w|0)|0;x=z;c[e+40>>2]=u;c[e+40+4>>2]=x;t=Ze(E,I,14)|0;L=z;f=Ze(E,I,18)|0;L=z^L;M=Ze(E,I,41)|0;r=s|11;F=c[464+(r<<3)>>2]|0;g=c[464+(r<<3)+4>>2]|0;b=c[e+32>>2]|0;O=c[e+32+4>>2]|0;L=fg(c[d+(r<<3)>>2]|0,c[d+(r<<3)+4>>2]|0,f^t^M|0,L^z|0)|0;g=fg(L|0,z|0,F|0,g|0)|0;B=fg(g|0,z|0,(H^D)&E^H|0,(B^C)&I^B|0)|0;O=fg(B|0,z|0,b|0,O|0)|0;b=z;B=fg(O|0,b|0,c[e>>2]|0,c[e+4>>2]|0)|0;H=z;c[e>>2]=B;c[e+4>>2]=H;g=Ze(u,x,28)|0;F=z;L=Ze(u,x,34)|0;F=z^F;M=Ze(u,x,39)|0;F=fg(O|0,b|0,L^g^M|0,F^z|0)|0;w=fg(F|0,z|0,(A|v)&u|A&v|0,(w|y)&x|w&y|0)|0;A=z;c[e+32>>2]=w;c[e+32+4>>2]=A;F=Ze(B,H,14)|0;M=z;g=Ze(B,H,18)|0;M=z^M;L=Ze(B,H,41)|0;b=s|12;O=c[464+(b<<3)>>2]|0;t=c[464+(b<<3)+4>>2]|0;f=c[e+24>>2]|0;J=c[e+24+4>>2]|0;M=fg(c[d+(b<<3)>>2]|0,c[d+(b<<3)+4>>2]|0,g^F^L|0,M^z|0)|0;t=fg(M|0,z|0,O|0,t|0)|0;C=fg(t|0,z|0,(D^E)&B^D|0,(C^I)&H^C|0)|0;J=fg(C|0,z|0,f|0,J|0)|0;f=z;C=fg(J|0,f|0,c[e+56>>2]|0,c[e+56+4>>2]|0)|0;D=z;c[e+56>>2]=C;c[e+56+4>>2]=D;t=Ze(w,A,28)|0;O=z;M=Ze(w,A,34)|0;O=z^O;L=Ze(w,A,39)|0;O=fg(J|0,f|0,M^t^L|0,O^z|0)|0;y=fg(O|0,z|0,(v|u)&w|v&u|0,(y|x)&A|y&x|0)|0;v=z;c[e+24>>2]=y;c[e+24+4>>2]=v;O=Ze(C,D,14)|0;L=z;t=Ze(C,D,18)|0;L=z^L;M=Ze(C,D,41)|0;f=s|13;J=c[464+(f<<3)>>2]|0;F=c[464+(f<<3)+4>>2]|0;g=c[e+16>>2]|0;N=c[e+16+4>>2]|0;L=fg(c[d+(f<<3)>>2]|0,c[d+(f<<3)+4>>2]|0,t^O^M|0,L^z|0)|0;F=fg(L|0,z|0,J|0,F|0)|0;I=fg(F|0,z|0,(E^B)&C^E|0,(I^H)&D^I|0)|0;N=fg(I|0,z|0,g|0,N|0)|0;g=z;I=fg(N|0,g|0,c[e+48>>2]|0,c[e+48+4>>2]|0)|0;E=z;c[e+48>>2]=I;c[e+48+4>>2]=E;F=Ze(y,v,28)|0;J=z;L=Ze(y,v,34)|0;J=z^J;M=Ze(y,v,39)|0;J=fg(N|0,g|0,L^F^M|0,J^z|0)|0;x=fg(J|0,z|0,(u|w)&y|u&w|0,(x|A)&v|x&A|0)|0;u=z;c[e+16>>2]=x;c[e+16+4>>2]=u;J=Ze(I,E,14)|0;M=z;F=Ze(I,E,18)|0;M=z^M;L=Ze(I,E,41)|0;g=s|14;N=c[464+(g<<3)>>2]|0;O=c[464+(g<<3)+4>>2]|0;t=c[e+8>>2]|0;K=c[e+8+4>>2]|0;M=fg(c[d+(g<<3)>>2]|0,c[d+(g<<3)+4>>2]|0,F^J^L|0,M^z|0)|0;O=fg(M|0,z|0,N|0,O|0)|0;H=fg(O|0,z|0,(B^C)&I^B|0,(H^D)&E^H|0)|0;K=fg(H|0,z|0,t|0,K|0)|0;t=z;H=fg(K|0,t|0,c[e+40>>2]|0,c[e+40+4>>2]|0)|0;B=z;c[e+40>>2]=H;c[e+40+4>>2]=B;O=Ze(x,u,28)|0;N=z;M=Ze(x,u,34)|0;N=z^N;L=Ze(x,u,39)|0;N=fg(K|0,t|0,M^O^L|0,N^z|0)|0;A=fg(N|0,z|0,(w|y)&x|w&y|0,(A|v)&u|A&v|0)|0;w=z;c[e+8>>2]=A;c[e+8+4>>2]=w;N=Ze(H,B,14)|0;L=z;O=Ze(H,B,18)|0;L=z^L;M=Ze(H,B,41)|0;t=s|15;K=c[464+(t<<3)>>2]|0;J=c[464+(t<<3)+4>>2]|0;F=c[e>>2]|0;G=c[e+4>>2]|0;L=fg(c[d+(t<<3)>>2]|0,c[d+(t<<3)+4>>2]|0,O^N^M|0,L^z|0)|0;J=fg(L|0,z|0,K|0,J|0)|0;D=fg(J|0,z|0,(C^I)&H^C|0,(D^E)&B^D|0)|0;G=fg(D|0,z|0,F|0,G|0)|0;F=z;D=fg(G|0,F|0,c[e+32>>2]|0,c[e+32+4>>2]|0)|0;c[e+32>>2]=D;c[e+32+4>>2]=z;D=Ze(A,w,28)|0;B=z;E=Ze(A,w,34)|0;B=z^B;C=Ze(A,w,39)|0;B=fg(G|0,F|0,E^D^C|0,B^z|0)|0;u=fg(B|0,z|0,(y|x)&A|y&x|0,(v|u)&w|v&u|0)|0;c[e>>2]=u;c[e+4>>2]=z;if((s|0)==64){b=0;break}K=c[d+(g<<3)>>2]|0;I=c[d+(g<<3)+4>>2]|0;N=Ze(K,I,19)|0;C=z;H=Ze(K,I,61)|0;J=z;I=yf(K|0,I|0,6)|0;J=fg(I^N^H|0,z^C^J|0,c[d+(p<<3)>>2]|0,c[d+(p<<3)+4>>2]|0)|0;C=z;H=c[d+(h<<3)>>2]|0;N=c[d+(h<<3)+4>>2]|0;I=Ze(H,N,1)|0;K=z;G=Ze(H,N,8)|0;L=z;E=yf(H|0,N|0,7)|0;L=z^K^L;K=d+(s<<3)|0;K=fg(J|0,C|0,c[K>>2]|0,c[K+4>>2]|0)|0;L=fg(K|0,z|0,E^I^G|0,L|0)|0;G=z;s=s+16|0;I=d+(s<<3)|0;c[I>>2]=L;c[I+4>>2]=G;I=c[d+(t<<3)>>2]|0;E=c[d+(t<<3)+4>>2]|0;K=Ze(I,E,19)|0;C=z;J=Ze(I,E,61)|0;F=z;E=yf(I|0,E|0,6)|0;F=fg(E^K^J|0,z^C^F|0,c[d+(h+9<<3)>>2]|0,c[d+(h+9<<3)+4>>2]|0)|0;C=z;J=c[d+(h+1<<3)>>2]|0;K=c[d+(h+1<<3)+4>>2]|0;E=Ze(J,K,1)|0;I=z;O=Ze(J,K,8)|0;M=z;D=yf(J|0,K|0,7)|0;M=z^I^M;N=fg(F|0,C|0,H|0,N|0)|0;M=fg(N|0,z|0,D^E^O|0,M|0)|0;O=z;c[d+(h+16<<3)>>2]=M;c[d+(h+16<<3)+4>>2]=O;E=Ze(L,G,19)|0;D=z;N=Ze(L,G,61)|0;H=z;G=yf(L|0,G|0,6)|0;H=fg(G^E^N|0,z^D^H|0,c[d+(r<<3)>>2]|0,c[d+(r<<3)+4>>2]|0)|0;D=z;N=c[d+(j<<3)>>2]|0;E=c[d+(j<<3)+4>>2]|0;G=Ze(N,E,1)|0;L=z;C=Ze(N,E,8)|0;F=z;I=yf(N|0,E|0,7)|0;F=z^L^F;K=fg(H|0,D|0,J|0,K|0)|0;F=fg(K|0,z|0,I^G^C|0,F|0)|0;C=z;c[d+(i+16<<3)>>2]=F;c[d+(i+16<<3)+4>>2]=C;G=Ze(M,O,19)|0;I=z;K=Ze(M,O,61)|0;J=z;O=yf(M|0,O|0,6)|0;J=fg(O^G^K|0,z^I^J|0,c[d+(j+9<<3)>>2]|0,c[d+(j+9<<3)+4>>2]|0)|0;I=z;K=c[d+(j+1<<3)>>2]|0;G=c[d+(j+1<<3)+4>>2]|0;O=Ze(K,G,1)|0;M=z;D=Ze(K,G,8)|0;H=z;L=yf(K|0,G|0,7)|0;H=z^M^H;E=fg(J|0,I|0,N|0,E|0)|0;H=fg(E|0,z|0,L^O^D|0,H|0)|0;D=z;c[d+(j+16<<3)>>2]=H;c[d+(j+16<<3)+4>>2]=D;O=Ze(F,C,19)|0;L=z;E=Ze(F,C,61)|0;N=z;C=yf(F|0,C|0,6)|0;N=fg(C^O^E|0,z^L^N|0,c[d+(f<<3)>>2]|0,c[d+(f<<3)+4>>2]|0)|0;L=z;E=c[d+(l<<3)>>2]|0;O=c[d+(l<<3)+4>>2]|0;C=Ze(E,O,1)|0;F=z;I=Ze(E,O,8)|0;J=z;M=yf(E|0,O|0,7)|0;J=z^F^J;G=fg(N|0,L|0,K|0,G|0)|0;J=fg(G|0,z|0,M^C^I|0,J|0)|0;I=z;c[d+(k+16<<3)>>2]=J;c[d+(k+16<<3)+4>>2]=I;C=Ze(H,D,19)|0;M=z;G=Ze(H,D,61)|0;K=z;D=yf(H|0,D|0,6)|0;K=fg(D^C^G|0,z^M^K|0,c[d+(l+9<<3)>>2]|0,c[d+(l+9<<3)+4>>2]|0)|0;M=z;G=c[d+(l+1<<3)>>2]|0;C=c[d+(l+1<<3)+4>>2]|0;D=Ze(G,C,1)|0;H=z;L=Ze(G,C,8)|0;N=z;F=yf(G|0,C|0,7)|0;N=z^H^N;O=fg(K|0,M|0,E|0,O|0)|0;N=fg(O|0,z|0,F^D^L|0,N|0)|0;L=z;c[d+(l+16<<3)>>2]=N;c[d+(l+16<<3)+4>>2]=L;D=Ze(J,I,19)|0;F=z;O=Ze(J,I,61)|0;E=z;I=yf(J|0,I|0,6)|0;E=fg(I^D^O|0,z^F^E|0,c[d+(t<<3)>>2]|0,c[d+(t<<3)+4>>2]|0)|0;F=z;O=c[d+(n<<3)>>2]|0;D=c[d+(n<<3)+4>>2]|0;I=Ze(O,D,1)|0;J=z;M=Ze(O,D,8)|0;K=z;H=yf(O|0,D|0,7)|0;K=z^J^K;C=fg(E|0,F|0,G|0,C|0)|0;K=fg(C|0,z|0,H^I^M|0,K|0)|0;M=z;c[d+(m+16<<3)>>2]=K;c[d+(m+16<<3)+4>>2]=M;I=Ze(N,L,19)|0;H=z;C=Ze(N,L,61)|0;G=z;L=yf(N|0,L|0,6)|0;G=fg(L^I^C|0,z^H^G|0,c[d+(n+9<<3)>>2]|0,c[d+(n+9<<3)+4>>2]|0)|0;H=z;C=c[d+(n+1<<3)>>2]|0;I=c[d+(n+1<<3)+4>>2]|0;L=Ze(C,I,1)|0;N=z;F=Ze(C,I,8)|0;E=z;J=yf(C|0,I|0,7)|0;E=z^N^E;D=fg(G|0,H|0,O|0,D|0)|0;E=fg(D|0,z|0,J^L^F|0,E|0)|0;F=z;c[d+(n+16<<3)>>2]=E;c[d+(n+16<<3)+4>>2]=F;L=Ze(K,M,19)|0;J=z;D=Ze(K,M,61)|0;O=z;M=yf(K|0,M|0,6)|0;O=fg(M^L^D|0,z^J^O|0,c[d+(o+9<<3)>>2]|0,c[d+(o+9<<3)+4>>2]|0)|0;J=z;D=c[d+(p<<3)>>2]|0;L=c[d+(p<<3)+4>>2]|0;M=Ze(D,L,1)|0;K=z;H=Ze(D,L,8)|0;G=z;N=yf(D|0,L|0,7)|0;G=z^K^G;I=fg(O|0,J|0,C|0,I|0)|0;G=fg(I|0,z|0,N^M^H|0,G|0)|0;H=z;c[d+(o+16<<3)>>2]=G;c[d+(o+16<<3)+4>>2]=H;M=Ze(E,F,19)|0;N=z;I=Ze(E,F,61)|0;C=z;F=yf(E|0,F|0,6)|0;C=fg(F^M^I|0,z^N^C|0,c[d+(p+9<<3)>>2]|0,c[d+(p+9<<3)+4>>2]|0)|0;N=z;I=c[d+(p+1<<3)>>2]|0;M=c[d+(p+1<<3)+4>>2]|0;F=Ze(I,M,1)|0;E=z;J=Ze(I,M,8)|0;O=z;K=yf(I|0,M|0,7)|0;O=z^E^O;L=fg(C|0,N|0,D|0,L|0)|0;O=fg(L|0,z|0,K^F^J|0,O|0)|0;J=z;c[d+(p+16<<3)>>2]=O;c[d+(p+16<<3)+4>>2]=J;F=Ze(G,H,19)|0;K=z;L=Ze(G,H,61)|0;D=z;H=yf(G|0,H|0,6)|0;D=fg(H^F^L|0,z^K^D|0,c[d+(q+9<<3)>>2]|0,c[d+(q+9<<3)+4>>2]|0)|0;K=z;L=c[d+(r<<3)>>2]|0;F=c[d+(r<<3)+4>>2]|0;H=Ze(L,F,1)|0;G=z;N=Ze(L,F,8)|0;C=z;E=yf(L|0,F|0,7)|0;C=z^G^C;M=fg(D|0,K|0,I|0,M|0)|0;C=fg(M|0,z|0,E^H^N|0,C|0)|0;N=z;c[d+(q+16<<3)>>2]=C;c[d+(q+16<<3)+4>>2]=N;H=Ze(O,J,19)|0;E=z;M=Ze(O,J,61)|0;I=z;J=yf(O|0,J|0,6)|0;I=fg(J^H^M|0,z^E^I|0,c[d+(r+9<<3)>>2]|0,c[d+(r+9<<3)+4>>2]|0)|0;E=z;M=c[d+(r+1<<3)>>2]|0;H=c[d+(r+1<<3)+4>>2]|0;J=Ze(M,H,1)|0;O=z;K=Ze(M,H,8)|0;D=z;G=yf(M|0,H|0,7)|0;D=z^O^D;F=fg(I|0,E|0,L|0,F|0)|0;D=fg(F|0,z|0,G^J^K|0,D|0)|0;K=z;c[d+(r+16<<3)>>2]=D;c[d+(r+16<<3)+4>>2]=K;J=Ze(C,N,19)|0;G=z;F=Ze(C,N,61)|0;L=z;N=yf(C|0,N|0,6)|0;L=fg(N^J^F|0,z^G^L|0,c[d+(b+9<<3)>>2]|0,c[d+(b+9<<3)+4>>2]|0)|0;G=z;F=c[d+(f<<3)>>2]|0;J=c[d+(f<<3)+4>>2]|0;N=Ze(F,J,1)|0;C=z;E=Ze(F,J,8)|0;I=z;O=yf(F|0,J|0,7)|0;I=z^C^I;H=fg(L|0,G|0,M|0,H|0)|0;I=fg(H|0,z|0,O^N^E|0,I|0)|0;E=z;c[d+(b+16<<3)>>2]=I;c[d+(b+16<<3)+4>>2]=E;N=Ze(D,K,19)|0;b=z;O=Ze(D,K,61)|0;H=z;K=yf(D|0,K|0,6)|0;H=fg(K^N^O|0,z^b^H|0,c[d+(f+9<<3)>>2]|0,c[d+(f+9<<3)+4>>2]|0)|0;b=z;O=c[d+(f+1<<3)>>2]|0;N=c[d+(f+1<<3)+4>>2]|0;K=Ze(O,N,1)|0;D=z;M=Ze(O,N,8)|0;G=z;L=yf(O|0,N|0,7)|0;G=z^D^G;J=fg(H|0,b|0,F|0,J|0)|0;G=fg(J|0,z|0,L^K^M|0,G|0)|0;M=z;c[d+(f+16<<3)>>2]=G;c[d+(f+16<<3)+4>>2]=M;K=Ze(I,E,19)|0;L=z;J=Ze(I,E,61)|0;F=z;b=yf(I|0,E|0,6)|0;F=fg(b^K^J|0,z^L^F|0,c[d+(g+9<<3)>>2]|0,c[d+(g+9<<3)+4>>2]|0)|0;L=z;J=c[d+(t<<3)>>2]|0;K=c[d+(t<<3)+4>>2]|0;b=Ze(J,K,1)|0;E=z;I=Ze(J,K,8)|0;f=z;H=yf(J|0,K|0,7)|0;f=z^E^f;N=fg(F|0,L|0,O|0,N|0)|0;f=fg(N|0,z|0,H^b^I|0,f|0)|0;c[d+(g+16<<3)>>2]=f;c[d+(g+16<<3)+4>>2]=z;f=Ze(G,M,19)|0;I=z;b=Ze(G,M,61)|0;H=z;M=yf(G|0,M|0,6)|0;H=fg(M^f^b|0,z^I^H|0,c[d+(t+9<<3)>>2]|0,c[d+(t+9<<3)+4>>2]|0)|0;I=z;b=c[d+(t+1<<3)>>2]|0;f=c[d+(t+1<<3)+4>>2]|0;M=Ze(b,f,1)|0;G=z;N=Ze(b,f,8)|0;O=z;L=yf(b|0,f|0,7)|0;O=z^G^O;K=fg(H|0,I|0,J|0,K|0)|0;O=fg(K|0,z|0,L^M^N|0,O|0)|0;c[d+(t+16<<3)>>2]=O;c[d+(t+16<<3)+4>>2]=z;if((s|0)>=80){b=0;break}}do{N=e+(b<<3)|0;O=a+(b<<3)|0;N=fg(c[O>>2]|0,c[O+4>>2]|0,c[N>>2]|0,c[N+4>>2]|0)|0;c[O>>2]=N;c[O+4>>2]=z;b=b+1|0}while((b|0)!=8);return}function ka(b){b=b|0;var c=0,d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0;R=df(a[b>>0]|0,a[b+1>>0]|0,a[b+2>>0]|0)|0;d=Qd(b+2|0)|0;d=yf(d|0,z|0,5)|0;S=df(a[b+5>>0]|0,a[b+6>>0]|0,a[b+7>>0]|0)|0;S=yf(S|0,z|0,2)|0;V=Qd(b+7|0)|0;V=yf(V|0,z|0,7)|0;w=Qd(b+10|0)|0;w=yf(w|0,z|0,4)|0;X=df(a[b+13>>0]|0,a[b+14>>0]|0,a[b+15>>0]|0)|0;X=yf(X|0,z|0,1)|0;Q=Qd(b+15|0)|0;Q=yf(Q|0,z|0,6)|0;fa=df(a[b+18>>0]|0,a[b+19>>0]|0,a[b+20>>0]|0)|0;fa=yf(fa|0,z|0,3)|0;ma=df(a[b+21>>0]|0,a[b+22>>0]|0,a[b+23>>0]|0)|0;ca=Qd(b+23|0)|0;ca=yf(ca|0,z|0,5)|0;la=df(a[b+26>>0]|0,a[b+27>>0]|0,a[b+28>>0]|0)|0;la=yf(la|0,z|0,2)|0;t=Qd(b+28|0)|0;t=yf(t|0,z|0,7)|0;qa=Qd(b+31|0)|0;qa=yf(qa|0,z|0,4)|0;u=df(a[b+34>>0]|0,a[b+35>>0]|0,a[b+36>>0]|0)|0;u=yf(u|0,z|0,1)|0;A=Qd(b+36|0)|0;A=yf(A|0,z|0,6)|0;o=df(a[b+39>>0]|0,a[b+40>>0]|0,a[b+41>>0]|0)|0;o=yf(o|0,z|0,3)|0;Z=df(a[b+42>>0]|0,a[b+43>>0]|0,a[b+44>>0]|0)|0;O=Qd(b+44|0)|0;O=yf(O|0,z|0,5)|0;$=df(a[b+47>>0]|0,a[b+48>>0]|0,a[b+49>>0]|0)|0;$=yf($|0,z|0,2)|0;ra=Qd(b+49|0)|0;ra=yf(ra|0,z|0,7)|0;v=Qd(b+52|0)|0;v=yf(v|0,z|0,4)|0;s=df(a[b+55>>0]|0,a[b+56>>0]|0,a[b+57>>0]|0)|0;s=yf(s|0,z|0,1)|0;g=Qd(b+57|0)|0;g=yf(g|0,z|0,6)|0;H=Qd(b+60|0)|0;H=yf(H|0,z|0,3)|0;c=z;h=af(H|0,c|0,666643,0)|0;e=z;ha=af(H|0,c|0,470296,0)|0;k=z;P=af(H|0,c|0,654183,0)|0;l=z;F=af(H|0,c|0,-997805,-1)|0;K=z;j=af(H|0,c|0,136657,0)|0;o=fg(j|0,z|0,o&2097151|0,0)|0;j=z;c=af(H|0,c|0,-683901,-1)|0;Z=fg(c|0,z|0,Z&2097151|0,0)|0;c=z;H=af(g&2097151|0,0,666643,0)|0;C=z;r=af(g&2097151|0,0,470296,0)|0;D=z;f=af(g&2097151|0,0,654183,0)|0;n=z;B=af(g&2097151|0,0,-997805,-1)|0;I=z;Y=af(g&2097151|0,0,136657,0)|0;G=z;g=af(g&2097151|0,0,-683901,-1)|0;g=fg(o|0,j|0,g|0,z|0)|0;j=z;o=af(s&2097151|0,0,666643,0)|0;m=z;J=af(s&2097151|0,0,470296,0)|0;x=z;y=af(s&2097151|0,0,654183,0)|0;U=z;na=af(s&2097151|0,0,-997805,-1)|0;ga=z;p=af(s&2097151|0,0,136657,0)|0;_=z;s=af(s&2097151|0,0,-683901,-1)|0;A=fg(s|0,z|0,A&2097151|0,0)|0;K=fg(A|0,z|0,F|0,K|0)|0;G=fg(K|0,z|0,Y|0,G|0)|0;Y=z;K=af(v&2097151|0,0,666643,0)|0;F=z;A=af(v&2097151|0,0,470296,0)|0;s=z;ia=af(v&2097151|0,0,654183,0)|0;i=z;N=af(v&2097151|0,0,-997805,-1)|0;q=z;pa=af(v&2097151|0,0,136657,0)|0;oa=z;v=af(v&2097151|0,0,-683901,-1)|0;W=z;E=af(ra&2097151|0,0,666643,0)|0;T=z;da=af(ra&2097151|0,0,470296,0)|0;ea=z;ba=af(ra&2097151|0,0,654183,0)|0;aa=z;ka=af(ra&2097151|0,0,-997805,-1)|0;ja=z;L=af(ra&2097151|0,0,136657,0)|0;M=z;ra=af(ra&2097151|0,0,-683901,-1)|0;qa=fg(ra|0,z|0,qa&2097151|0,0)|0;oa=fg(qa|0,z|0,pa|0,oa|0)|0;ga=fg(oa|0,z|0,na|0,ga|0)|0;k=fg(ga|0,z|0,ha|0,k|0)|0;n=fg(k|0,z|0,f|0,n|0)|0;f=z;k=af($&2097151|0,0,666643,0)|0;Q=fg(k|0,z|0,Q&2097151|0,0)|0;k=z;ha=af($&2097151|0,0,470296,0)|0;ga=z;na=af($&2097151|0,0,654183,0)|0;ma=fg(na|0,z|0,ma&2097151|0,0)|0;ea=fg(ma|0,z|0,da|0,ea|0)|0;F=fg(ea|0,z|0,K|0,F|0)|0;K=z;ea=af($&2097151|0,0,-997805,-1)|0;da=z;ma=af($&2097151|0,0,136657,0)|0;la=fg(ma|0,z|0,la&2097151|0,0)|0;ja=fg(la|0,z|0,ka|0,ja|0)|0;i=fg(ja|0,z|0,ia|0,i|0)|0;x=fg(i|0,z|0,J|0,x|0)|0;C=fg(x|0,z|0,H|0,C|0)|0;H=z;$=af($&2097151|0,0,-683901,-1)|0;x=z;J=fg(Q|0,k|0,1048576,0)|0;J=yf(J|0,z|0,21)|0;i=z;fa=fg(ha|0,ga|0,fa&2097151|0,0)|0;T=fg(fa|0,z|0,E|0,T|0)|0;T=fg(T|0,z|0,J|0,i|0)|0;E=z;i=vf(J|0,i|0,21)|0;i=cg(Q|0,k|0,i|0,z|0)|0;k=z;Q=fg(F|0,K|0,1048576,0)|0;Q=yf(Q|0,z|0,21)|0;J=z;ca=fg(ea|0,da|0,ca&2097151|0,0)|0;aa=fg(ca|0,z|0,ba|0,aa|0)|0;s=fg(aa|0,z|0,A|0,s|0)|0;m=fg(s|0,z|0,o|0,m|0)|0;m=fg(m|0,z|0,Q|0,J|0)|0;o=z;J=vf(Q|0,J|0,21)|0;Q=z;s=fg(C|0,H|0,1048576,0)|0;s=Xe(s|0,z|0,21)|0;A=z;t=fg($|0,x|0,t&2097151|0,0)|0;M=fg(t|0,z|0,L|0,M|0)|0;q=fg(M|0,z|0,N|0,q|0)|0;U=fg(q|0,z|0,y|0,U|0)|0;e=fg(U|0,z|0,h|0,e|0)|0;D=fg(e|0,z|0,r|0,D|0)|0;D=fg(D|0,z|0,s|0,A|0)|0;r=z;A=vf(s|0,A|0,21)|0;s=z;e=fg(n|0,f|0,1048576,0)|0;e=Xe(e|0,z|0,21)|0;h=z;u=fg(v|0,W|0,u&2097151|0,0)|0;_=fg(u|0,z|0,p|0,_|0)|0;l=fg(_|0,z|0,P|0,l|0)|0;I=fg(l|0,z|0,B|0,I|0)|0;I=fg(I|0,z|0,e|0,h|0)|0;B=z;h=vf(e|0,h|0,21)|0;h=cg(n|0,f|0,h|0,z|0)|0;f=z;n=fg(G|0,Y|0,1048576,0)|0;n=Xe(n|0,z|0,21)|0;e=z;j=fg(g|0,j|0,n|0,e|0)|0;g=z;e=vf(n|0,e|0,21)|0;e=cg(G|0,Y|0,e|0,z|0)|0;Y=z;G=fg(Z|0,c|0,1048576,0)|0;G=Xe(G|0,z|0,21)|0;n=z;O=fg(G|0,n|0,O&2097151|0,0)|0;l=z;n=vf(G|0,n|0,21)|0;n=cg(Z|0,c|0,n|0,z|0)|0;c=z;Z=fg(T|0,E|0,1048576,0)|0;Z=yf(Z|0,z|0,21)|0;G=z;P=vf(Z|0,G|0,21)|0;P=cg(T|0,E|0,P|0,z|0)|0;E=z;T=fg(m|0,o|0,1048576,0)|0;T=Xe(T|0,z|0,21)|0;_=z;p=vf(T|0,_|0,21)|0;u=z;W=fg(D|0,r|0,1048576,0)|0;W=Xe(W|0,z|0,21)|0;v=z;f=fg(W|0,v|0,h|0,f|0)|0;h=z;v=vf(W|0,v|0,21)|0;v=cg(D|0,r|0,v|0,z|0)|0;r=z;D=fg(I|0,B|0,1048576,0)|0;D=Xe(D|0,z|0,21)|0;W=z;Y=fg(D|0,W|0,e|0,Y|0)|0;e=z;W=vf(D|0,W|0,21)|0;W=cg(I|0,B|0,W|0,z|0)|0;B=z;I=fg(j|0,g|0,1048576,0)|0;I=Xe(I|0,z|0,21)|0;D=z;c=fg(I|0,D|0,n|0,c|0)|0;n=z;D=vf(I|0,D|0,21)|0;D=cg(j|0,g|0,D|0,z|0)|0;g=z;j=af(O|0,l|0,666643,0)|0;X=fg(j|0,z|0,X&2097151|0,0)|0;j=z;I=af(O|0,l|0,470296,0)|0;I=fg(i|0,k|0,I|0,z|0)|0;k=z;i=af(O|0,l|0,654183,0)|0;i=fg(P|0,E|0,i|0,z|0)|0;E=z;P=af(O|0,l|0,-997805,-1)|0;U=z;y=af(O|0,l|0,136657,0)|0;q=z;l=af(O|0,l|0,-683901,-1)|0;H=fg(l|0,z|0,C|0,H|0)|0;_=fg(H|0,z|0,T|0,_|0)|0;s=cg(_|0,z|0,A|0,s|0)|0;A=z;_=af(c|0,n|0,666643,0)|0;w=fg(_|0,z|0,w&2097151|0,0)|0;_=z;T=af(c|0,n|0,470296,0)|0;T=fg(X|0,j|0,T|0,z|0)|0;j=z;X=af(c|0,n|0,654183,0)|0;X=fg(I|0,k|0,X|0,z|0)|0;k=z;I=af(c|0,n|0,-997805,-1)|0;I=fg(i|0,E|0,I|0,z|0)|0;E=z;i=af(c|0,n|0,136657,0)|0;H=z;n=af(c|0,n|0,-683901,-1)|0;c=z;C=af(D|0,g|0,666643,0)|0;V=fg(C|0,z|0,V&2097151|0,0)|0;C=z;l=af(D|0,g|0,470296,0)|0;l=fg(w|0,_|0,l|0,z|0)|0;_=z;w=af(D|0,g|0,654183,0)|0;w=fg(T|0,j|0,w|0,z|0)|0;j=z;T=af(D|0,g|0,-997805,-1)|0;T=fg(X|0,k|0,T|0,z|0)|0;k=z;X=af(D|0,g|0,136657,0)|0;X=fg(I|0,E|0,X|0,z|0)|0;E=z;g=af(D|0,g|0,-683901,-1)|0;D=z;K=fg(Z|0,G|0,F|0,K|0)|0;Q=cg(K|0,z|0,J|0,Q|0)|0;U=fg(Q|0,z|0,P|0,U|0)|0;H=fg(U|0,z|0,i|0,H|0)|0;D=fg(H|0,z|0,g|0,D|0)|0;g=z;H=af(Y|0,e|0,666643,0)|0;S=fg(H|0,z|0,S&2097151|0,0)|0;H=z;i=af(Y|0,e|0,470296,0)|0;i=fg(V|0,C|0,i|0,z|0)|0;C=z;V=af(Y|0,e|0,654183,0)|0;V=fg(l|0,_|0,V|0,z|0)|0;_=z;l=af(Y|0,e|0,-997805,-1)|0;l=fg(w|0,j|0,l|0,z|0)|0;j=z;w=af(Y|0,e|0,136657,0)|0;w=fg(T|0,k|0,w|0,z|0)|0;k=z;e=af(Y|0,e|0,-683901,-1)|0;e=fg(X|0,E|0,e|0,z|0)|0;E=z;X=af(W|0,B|0,666643,0)|0;Y=z;T=af(W|0,B|0,470296,0)|0;U=z;P=af(W|0,B|0,654183,0)|0;Q=z;J=af(W|0,B|0,-997805,-1)|0;K=z;F=af(W|0,B|0,136657,0)|0;G=z;B=af(W|0,B|0,-683901,-1)|0;B=fg(w|0,k|0,B|0,z|0)|0;k=z;w=af(f|0,h|0,666643,0)|0;R=fg(w|0,z|0,R&2097151|0,0)|0;w=z;W=af(f|0,h|0,470296,0)|0;Z=z;I=af(f|0,h|0,654183,0)|0;I=fg(S|0,H|0,I|0,z|0)|0;U=fg(I|0,z|0,T|0,U|0)|0;T=z;I=af(f|0,h|0,-997805,-1)|0;H=z;S=af(f|0,h|0,136657,0)|0;S=fg(V|0,_|0,S|0,z|0)|0;K=fg(S|0,z|0,J|0,K|0)|0;J=z;h=af(f|0,h|0,-683901,-1)|0;f=z;S=fg(R|0,w|0,1048576,0)|0;S=Xe(S|0,z|0,21)|0;_=z;d=fg(W|0,Z|0,d&2097151|0,0)|0;Y=fg(d|0,z|0,X|0,Y|0)|0;Y=fg(Y|0,z|0,S|0,_|0)|0;X=z;_=vf(S|0,_|0,21)|0;_=cg(R|0,w|0,_|0,z|0)|0;w=z;R=fg(U|0,T|0,1048576,0)|0;R=Xe(R|0,z|0,21)|0;S=z;H=fg(i|0,C|0,I|0,H|0)|0;Q=fg(H|0,z|0,P|0,Q|0)|0;Q=fg(Q|0,z|0,R|0,S|0)|0;P=z;S=vf(R|0,S|0,21)|0;R=z;H=fg(K|0,J|0,1048576,0)|0;H=Xe(H|0,z|0,21)|0;I=z;f=fg(l|0,j|0,h|0,f|0)|0;G=fg(f|0,z|0,F|0,G|0)|0;G=fg(G|0,z|0,H|0,I|0)|0;F=z;I=vf(H|0,I|0,21)|0;H=z;f=fg(B|0,k|0,1048576,0)|0;f=Xe(f|0,z|0,21)|0;h=z;E=fg(e|0,E|0,f|0,h|0)|0;e=z;h=vf(f|0,h|0,21)|0;h=cg(B|0,k|0,h|0,z|0)|0;k=z;B=fg(D|0,g|0,1048576,0)|0;B=Xe(B|0,z|0,21)|0;f=z;o=fg(y|0,q|0,m|0,o|0)|0;u=cg(o|0,z|0,p|0,u|0)|0;c=fg(u|0,z|0,n|0,c|0)|0;c=fg(c|0,z|0,B|0,f|0)|0;n=z;f=vf(B|0,f|0,21)|0;f=cg(D|0,g|0,f|0,z|0)|0;g=z;D=fg(s|0,A|0,1048576,0)|0;D=Xe(D|0,z|0,21)|0;B=z;r=fg(D|0,B|0,v|0,r|0)|0;v=z;B=vf(D|0,B|0,21)|0;B=cg(s|0,A|0,B|0,z|0)|0;A=z;s=fg(Y|0,X|0,1048576,0)|0;s=Xe(s|0,z|0,21)|0;D=z;u=vf(s|0,D|0,21)|0;p=z;o=fg(Q|0,P|0,1048576,0)|0;o=Xe(o|0,z|0,21)|0;m=z;q=vf(o|0,m|0,21)|0;y=z;j=fg(G|0,F|0,1048576,0)|0;j=Xe(j|0,z|0,21)|0;l=z;k=fg(h|0,k|0,j|0,l|0)|0;h=z;l=vf(j|0,l|0,21)|0;j=z;C=fg(E|0,e|0,1048576,0)|0;C=Xe(C|0,z|0,21)|0;i=z;g=fg(f|0,g|0,C|0,i|0)|0;f=z;i=vf(C|0,i|0,21)|0;i=cg(E|0,e|0,i|0,z|0)|0;e=z;E=fg(c|0,n|0,1048576,0)|0;E=Xe(E|0,z|0,21)|0;C=z;A=fg(B|0,A|0,E|0,C|0)|0;B=z;C=vf(E|0,C|0,21)|0;C=cg(c|0,n|0,C|0,z|0)|0;n=z;c=fg(r|0,v|0,1048576,0)|0;c=Xe(c|0,z|0,21)|0;E=z;d=vf(c|0,E|0,21)|0;d=cg(r|0,v|0,d|0,z|0)|0;v=z;r=af(c|0,E|0,666643,0)|0;r=fg(_|0,w|0,r|0,z|0)|0;w=z;_=af(c|0,E|0,470296,0)|0;Z=z;W=af(c|0,E|0,654183,0)|0;V=z;O=af(c|0,E|0,-997805,-1)|0;N=z;M=af(c|0,E|0,136657,0)|0;L=z;E=af(c|0,E|0,-683901,-1)|0;c=z;t=Xe(r|0,w|0,21)|0;x=z;X=fg(_|0,Z|0,Y|0,X|0)|0;p=cg(X|0,z|0,u|0,p|0)|0;p=fg(p|0,z|0,t|0,x|0)|0;u=z;x=vf(t|0,x|0,21)|0;x=cg(r|0,w|0,x|0,z|0)|0;w=z;r=Xe(p|0,u|0,21)|0;t=z;T=fg(W|0,V|0,U|0,T|0)|0;R=cg(T|0,z|0,S|0,R|0)|0;D=fg(R|0,z|0,s|0,D|0)|0;D=fg(D|0,z|0,r|0,t|0)|0;s=z;t=vf(r|0,t|0,21)|0;t=cg(p|0,u|0,t|0,z|0)|0;u=z;p=Xe(D|0,s|0,21)|0;r=z;N=fg(Q|0,P|0,O|0,N|0)|0;y=cg(N|0,z|0,q|0,y|0)|0;y=fg(y|0,z|0,p|0,r|0)|0;q=z;r=vf(p|0,r|0,21)|0;r=cg(D|0,s|0,r|0,z|0)|0;s=z;D=Xe(y|0,q|0,21)|0;p=z;J=fg(M|0,L|0,K|0,J|0)|0;H=cg(J|0,z|0,I|0,H|0)|0;m=fg(H|0,z|0,o|0,m|0)|0;m=fg(m|0,z|0,D|0,p|0)|0;o=z;p=vf(D|0,p|0,21)|0;p=cg(y|0,q|0,p|0,z|0)|0;q=z;y=Xe(m|0,o|0,21)|0;D=z;c=fg(G|0,F|0,E|0,c|0)|0;j=cg(c|0,z|0,l|0,j|0)|0;j=fg(j|0,z|0,y|0,D|0)|0;l=z;D=vf(y|0,D|0,21)|0;D=cg(m|0,o|0,D|0,z|0)|0;o=z;m=Xe(j|0,l|0,21)|0;y=z;h=fg(k|0,h|0,m|0,y|0)|0;k=z;y=vf(m|0,y|0,21)|0;y=cg(j|0,l|0,y|0,z|0)|0;l=z;j=Xe(h|0,k|0,21)|0;m=z;e=fg(j|0,m|0,i|0,e|0)|0;i=z;m=vf(j|0,m|0,21)|0;m=cg(h|0,k|0,m|0,z|0)|0;k=z;h=Xe(e|0,i|0,21)|0;j=z;f=fg(g|0,f|0,h|0,j|0)|0;g=z;j=vf(h|0,j|0,21)|0;j=cg(e|0,i|0,j|0,z|0)|0;i=z;e=Xe(f|0,g|0,21)|0;h=z;n=fg(e|0,h|0,C|0,n|0)|0;C=z;h=vf(e|0,h|0,21)|0;h=cg(f|0,g|0,h|0,z|0)|0;g=z;f=Xe(n|0,C|0,21)|0;e=z;B=fg(A|0,B|0,f|0,e|0)|0;A=z;e=vf(f|0,e|0,21)|0;e=cg(n|0,C|0,e|0,z|0)|0;C=z;n=Xe(B|0,A|0,21)|0;f=z;v=fg(n|0,f|0,d|0,v|0)|0;d=z;f=vf(n|0,f|0,21)|0;f=cg(B|0,A|0,f|0,z|0)|0;A=z;B=Xe(v|0,d|0,21)|0;n=z;c=vf(B|0,n|0,21)|0;c=cg(v|0,d|0,c|0,z|0)|0;d=z;v=af(B|0,n|0,666643,0)|0;w=fg(v|0,z|0,x|0,w|0)|0;x=z;v=af(B|0,n|0,470296,0)|0;v=fg(t|0,u|0,v|0,z|0)|0;u=z;t=af(B|0,n|0,654183,0)|0;t=fg(r|0,s|0,t|0,z|0)|0;s=z;r=af(B|0,n|0,-997805,-1)|0;r=fg(p|0,q|0,r|0,z|0)|0;q=z;p=af(B|0,n|0,136657,0)|0;p=fg(D|0,o|0,p|0,z|0)|0;o=z;n=af(B|0,n|0,-683901,-1)|0;n=fg(y|0,l|0,n|0,z|0)|0;l=z;y=Xe(w|0,x|0,21)|0;B=z;u=fg(v|0,u|0,y|0,B|0)|0;v=z;B=vf(y|0,B|0,21)|0;B=cg(w|0,x|0,B|0,z|0)|0;x=z;w=Xe(u|0,v|0,21)|0;y=z;s=fg(t|0,s|0,w|0,y|0)|0;t=z;y=vf(w|0,y|0,21)|0;y=cg(u|0,v|0,y|0,z|0)|0;v=z;u=Xe(s|0,t|0,21)|0;w=z;q=fg(r|0,q|0,u|0,w|0)|0;r=z;w=vf(u|0,w|0,21)|0;w=cg(s|0,t|0,w|0,z|0)|0;t=z;s=Xe(q|0,r|0,21)|0;u=z;o=fg(p|0,o|0,s|0,u|0)|0;p=z;u=vf(s|0,u|0,21)|0;u=cg(q|0,r|0,u|0,z|0)|0;r=z;q=Xe(o|0,p|0,21)|0;s=z;l=fg(n|0,l|0,q|0,s|0)|0;n=z;s=vf(q|0,s|0,21)|0;s=cg(o|0,p|0,s|0,z|0)|0;p=z;o=Xe(l|0,n|0,21)|0;q=z;k=fg(o|0,q|0,m|0,k|0)|0;m=z;q=vf(o|0,q|0,21)|0;q=cg(l|0,n|0,q|0,z|0)|0;n=z;l=Xe(k|0,m|0,21)|0;o=z;i=fg(l|0,o|0,j|0,i|0)|0;j=z;o=vf(l|0,o|0,21)|0;o=cg(k|0,m|0,o|0,z|0)|0;m=z;k=Xe(i|0,j|0,21)|0;l=z;g=fg(k|0,l|0,h|0,g|0)|0;h=z;l=vf(k|0,l|0,21)|0;l=cg(i|0,j|0,l|0,z|0)|0;j=z;i=Xe(g|0,h|0,21)|0;k=z;C=fg(i|0,k|0,e|0,C|0)|0;e=z;k=vf(i|0,k|0,21)|0;k=cg(g|0,h|0,k|0,z|0)|0;h=z;g=Xe(C|0,e|0,21)|0;i=z;A=fg(g|0,i|0,f|0,A|0)|0;f=z;i=vf(g|0,i|0,21)|0;i=cg(C|0,e|0,i|0,z|0)|0;e=z;C=Xe(A|0,f|0,21)|0;g=z;d=fg(C|0,g|0,c|0,d|0)|0;c=z;g=vf(C|0,g|0,21)|0;g=cg(A|0,f|0,g|0,z|0)|0;f=z;a[b>>0]=B;A=yf(B|0,x|0,8)|0;a[b+1>>0]=A;x=yf(B|0,x|0,16)|0;B=z;A=vf(y|0,v|0,5)|0;a[b+2>>0]=A|x;x=yf(y|0,v|0,3)|0;a[b+3>>0]=x;x=yf(y|0,v|0,11)|0;a[b+4>>0]=x;v=yf(y|0,v|0,19)|0;y=z;x=vf(w|0,t|0,2)|0;a[b+5>>0]=x|v;v=yf(w|0,t|0,6)|0;a[b+6>>0]=v;t=yf(w|0,t|0,14)|0;w=z;v=vf(u|0,r|0,7)|0;a[b+7>>0]=v|t;t=yf(u|0,r|0,1)|0;a[b+8>>0]=t;t=yf(u|0,r|0,9)|0;a[b+9>>0]=t;r=yf(u|0,r|0,17)|0;u=z;t=vf(s|0,p|0,4)|0;a[b+10>>0]=t|r;r=yf(s|0,p|0,4)|0;a[b+11>>0]=r;r=yf(s|0,p|0,12)|0;a[b+12>>0]=r;p=yf(s|0,p|0,20)|0;s=z;r=vf(q|0,n|0,1)|0;a[b+13>>0]=r|p;p=yf(q|0,n|0,7)|0;a[b+14>>0]=p;n=yf(q|0,n|0,15)|0;q=z;p=vf(o|0,m|0,6)|0;a[b+15>>0]=p|n;n=yf(o|0,m|0,2)|0;a[b+16>>0]=n;n=yf(o|0,m|0,10)|0;a[b+17>>0]=n;m=yf(o|0,m|0,18)|0;o=z;n=vf(l|0,j|0,3)|0;a[b+18>>0]=n|m;m=yf(l|0,j|0,5)|0;a[b+19>>0]=m;j=yf(l|0,j|0,13)|0;a[b+20>>0]=j;a[b+21>>0]=k;j=yf(k|0,h|0,8)|0;a[b+22>>0]=j;h=yf(k|0,h|0,16)|0;k=z;j=vf(i|0,e|0,5)|0;a[b+23>>0]=j|h;h=yf(i|0,e|0,3)|0;a[b+24>>0]=h;h=yf(i|0,e|0,11)|0;a[b+25>>0]=h;e=yf(i|0,e|0,19)|0;i=z;h=vf(g|0,f|0,2)|0;a[b+26>>0]=h|e;e=yf(g|0,f|0,6)|0;a[b+27>>0]=e;f=yf(g|0,f|0,14)|0;g=z;e=vf(d|0,c|0,7)|0;a[b+28>>0]=f|e;e=yf(d|0,c|0,1)|0;a[b+29>>0]=e;e=yf(d|0,c|0,9)|0;a[b+30>>0]=e;c=yf(d|0,c|0,17)|0;a[b+31>>0]=c;return}function la(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0,sa=0,ta=0,ua=0,va=0,wa=0,xa=0,ya=0,za=0,Aa=0,Ba=0,Ca=0,Da=0,Ea=0,Fa=0,Ga=0,Ha=0,Ia=0,Ja=0,Ka=0,La=0,Ma=0,Na=0,Oa=0,Pa=0,Qa=0,Ra=0,Sa=0,Ta=0,Ua=0,Va=0,Wa=0,Xa=0,Ya=0,Za=0,_a=0,$a=0,ab=0,bb=0,cb=0,db=0,eb=0,fb=0,gb=0,hb=0,ib=0,jb=0,kb=0,lb=0,mb=0,nb=0,ob=0,pb=0,qb=0,rb=0,sb=0,tb=0,ub=0,vb=0,wb=0,xb=0,yb=0,zb=0,Ab=0,Bb=0,Cb=0,Db=0,Eb=0,Fb=0,Gb=0,Hb=0,Ib=0,Jb=0,Kb=0,Lb=0,Mb=0,Nb=0,Ob=0,Pb=0,Qb=0,Rb=0,Sb=0,Tb=0,Ub=0,Vb=0,Wb=0,Xb=0,Yb=0,Zb=0,_b=0,$b=0,ac=0,bc=0,cc=0,dc=0,ec=0,fc=0,gc=0,hc=0,ic=0,jc=0,kc=0,lc=0,mc=0,nc=0,oc=0,pc=0,qc=0,rc=0,sc=0,tc=0,uc=0,vc=0,wc=0,xc=0,yc=0,zc=0,Ac=0,Bc=0,Cc=0,Dc=0,Ec=0,Fc=0,Gc=0,Hc=0,Ic=0,Jc=0,Kc=0,Lc=0,Mc=0,Nc=0,Oc=0,Pc=0;o=c[b>>2]|0;n=c[b+4>>2]|0;k=c[b+8>>2]|0;fa=c[b+12>>2]|0;N=c[b+16>>2]|0;M=c[b+20>>2]|0;g=c[b+24>>2]|0;ea=c[b+28>>2]|0;L=c[b+32>>2]|0;q=c[b+36>>2]|0;I=c[d>>2]|0;Oc=c[d+4>>2]|0;cc=c[d+8>>2]|0;sb=c[d+12>>2]|0;Ia=c[d+16>>2]|0;jc=c[d+20>>2]|0;Db=c[d+24>>2]|0;Ta=c[d+28>>2]|0;ga=c[d+32>>2]|0;Pc=c[d+36>>2]|0;Mc=af(I|0,((I|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;Lc=z;wc=af(Oc|0,((Oc|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;vc=z;ub=af(cc|0,((cc|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;tb=z;Ka=af(sb|0,((sb|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;Ja=z;mc=af(Ia|0,((Ia|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;lc=z;Gb=af(jc|0,((jc|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;Fb=z;Wa=af(Db|0,((Db|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;Va=z;ja=af(Ta|0,((Ta|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;ia=z;P=af(ga|0,((ga|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;O=z;o=af(Pc|0,((Pc|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;l=z;dc=af(I|0,((I|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;ec=z;yb=af(Oc|0,((Oc|0)<0)<<31>>31|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;xb=z;Ma=af(cc|0,((cc|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;La=z;oc=af(sb|0,((sb|0)<0)<<31>>31|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;nc=z;Ib=af(Ia|0,((Ia|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;Hb=z;Ya=af(jc|0,((jc|0)<0)<<31>>31|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;Xa=z;la=af(Db|0,((Db|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;ka=z;R=af(Ta|0,((Ta|0)<0)<<31>>31|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;Q=z;t=af(ga|0,((ga|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;s=z;d=((Pc*19|0)<0)<<31>>31;n=af(Pc*19|0,d|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;p=z;wb=af(I|0,((I|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;vb=z;Qa=af(Oc|0,((Oc|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;Pa=z;qc=af(cc|0,((cc|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;pc=z;Kb=af(sb|0,((sb|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;Jb=z;_a=af(Ia|0,((Ia|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;Za=z;na=af(jc|0,((jc|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;ma=z;T=af(Db|0,((Db|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;S=z;v=af(Ta|0,((Ta|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;u=z;ha=((ga*19|0)<0)<<31>>31;yc=af(ga*19|0,ha|0,k|0,((k|0)<0)<<31>>31|0)|0;xc=z;k=af(Pc*19|0,d|0,k|0,((k|0)<0)<<31>>31|0)|0;j=z;Oa=af(I|0,((I|0)<0)<<31>>31|0,fa|0,((fa|0)<0)<<31>>31|0)|0;Na=z;uc=af(Oc|0,((Oc|0)<0)<<31>>31|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;tc=z;Mb=af(cc|0,((cc|0)<0)<<31>>31|0,fa|0,((fa|0)<0)<<31>>31|0)|0;Lb=z;ab=af(sb|0,((sb|0)<0)<<31>>31|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;$a=z;pa=af(Ia|0,((Ia|0)<0)<<31>>31|0,fa|0,((fa|0)<0)<<31>>31|0)|0;oa=z;V=af(jc|0,((jc|0)<0)<<31>>31|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;U=z;x=af(Db|0,((Db|0)<0)<<31>>31|0,fa|0,((fa|0)<0)<<31>>31|0)|0;w=z;Ua=((Ta*19|0)<0)<<31>>31;Ac=af(Ta*19|0,Ua|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;zc=z;Sb=af(ga*19|0,ha|0,fa|0,((fa|0)<0)<<31>>31|0)|0;Rb=z;fa=af(Pc*19|0,d|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;f=z;sc=af(I|0,((I|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;rc=z;Qb=af(Oc|0,((Oc|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;Pb=z;cb=af(cc|0,((cc|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;bb=z;ra=af(sb|0,((sb|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;qa=z;X=af(Ia|0,((Ia|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;W=z;A=af(jc|0,((jc|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;y=z;Eb=((Db*19|0)<0)<<31>>31;Cc=af(Db*19|0,Eb|0,N|0,((N|0)<0)<<31>>31|0)|0;Bc=z;Ub=af(Ta*19|0,Ua|0,N|0,((N|0)<0)<<31>>31|0)|0;Tb=z;ib=af(ga*19|0,ha|0,N|0,((N|0)<0)<<31>>31|0)|0;hb=z;N=af(Pc*19|0,d|0,N|0,((N|0)<0)<<31>>31|0)|0;e=z;Ob=af(I|0,((I|0)<0)<<31>>31|0,M|0,((M|0)<0)<<31>>31|0)|0;Nb=z;gb=af(Oc|0,((Oc|0)<0)<<31>>31|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;fb=z;ta=af(cc|0,((cc|0)<0)<<31>>31|0,M|0,((M|0)<0)<<31>>31|0)|0;sa=z;Z=af(sb|0,((sb|0)<0)<<31>>31|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;Y=z;C=af(Ia|0,((Ia|0)<0)<<31>>31|0,M|0,((M|0)<0)<<31>>31|0)|0;B=z;kc=((jc*19|0)<0)<<31>>31;Ec=af(jc*19|0,kc|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;Dc=z;Wb=af(Db*19|0,Eb|0,M|0,((M|0)<0)<<31>>31|0)|0;Vb=z;kb=af(Ta*19|0,Ua|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;jb=z;Aa=af(ga*19|0,ha|0,M|0,((M|0)<0)<<31>>31|0)|0;za=z;b=af(Pc*19|0,d|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;M=z;eb=af(I|0,((I|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;db=z;xa=af(Oc|0,((Oc|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;wa=z;$=af(cc|0,((cc|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;_=z;E=af(sb|0,((sb|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;D=z;Gc=af(Ia*19|0,((Ia*19|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;Fc=z;Yb=af(jc*19|0,kc|0,g|0,((g|0)<0)<<31>>31|0)|0;Xb=z;mb=af(Db*19|0,Eb|0,g|0,((g|0)<0)<<31>>31|0)|0;lb=z;Ca=af(Ta*19|0,Ua|0,g|0,((g|0)<0)<<31>>31|0)|0;Ba=z;m=af(ga*19|0,ha|0,g|0,((g|0)<0)<<31>>31|0)|0;r=z;g=af(Pc*19|0,d|0,g|0,((g|0)<0)<<31>>31|0)|0;ya=z;va=af(I|0,((I|0)<0)<<31>>31|0,ea|0,((ea|0)<0)<<31>>31|0)|0;ua=z;da=af(Oc|0,((Oc|0)<0)<<31>>31|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;ca=z;G=af(cc|0,((cc|0)<0)<<31>>31|0,ea|0,((ea|0)<0)<<31>>31|0)|0;F=z;Ic=af(sb*19|0,((sb*19|0)<0)<<31>>31|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;Hc=z;_b=af(Ia*19|0,((Ia*19|0)<0)<<31>>31|0,ea|0,((ea|0)<0)<<31>>31|0)|0;Zb=z;ob=af(jc*19|0,kc|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;nb=z;Ea=af(Db*19|0,Eb|0,ea|0,((ea|0)<0)<<31>>31|0)|0;Da=z;gc=af(Ta*19|0,Ua|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;fc=z;Ab=af(ga*19|0,ha|0,ea|0,((ea|0)<0)<<31>>31|0)|0;zb=z;ea=af(Pc*19|0,d|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;i=z;ba=af(I|0,((I|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;aa=z;K=af(Oc|0,((Oc|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;J=z;Kc=af(cc*19|0,((cc*19|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;Jc=z;ac=af(sb*19|0,((sb*19|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;$b=z;qb=af(Ia*19|0,((Ia*19|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;pb=z;Ga=af(jc*19|0,kc|0,L|0,((L|0)<0)<<31>>31|0)|0;Fa=z;ic=af(Db*19|0,Eb|0,L|0,((L|0)<0)<<31>>31|0)|0;hc=z;Cb=af(Ta*19|0,Ua|0,L|0,((L|0)<0)<<31>>31|0)|0;Bb=z;Sa=af(ga*19|0,ha|0,L|0,((L|0)<0)<<31>>31|0)|0;Ra=z;L=af(Pc*19|0,d|0,L|0,((L|0)<0)<<31>>31|0)|0;h=z;I=af(I|0,((I|0)<0)<<31>>31|0,q|0,((q|0)<0)<<31>>31|0)|0;H=z;Oc=af(Oc*19|0,((Oc*19|0)<0)<<31>>31|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;Nc=z;cc=af(cc*19|0,((cc*19|0)<0)<<31>>31|0,q|0,((q|0)<0)<<31>>31|0)|0;bc=z;sb=af(sb*19|0,((sb*19|0)<0)<<31>>31|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;rb=z;Ia=af(Ia*19|0,((Ia*19|0)<0)<<31>>31|0,q|0,((q|0)<0)<<31>>31|0)|0;Ha=z;kc=af(jc*19|0,kc|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;jc=z;Eb=af(Db*19|0,Eb|0,q|0,((q|0)<0)<<31>>31|0)|0;Db=z;Ua=af(Ta*19|0,Ua|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;Ta=z;ha=af(ga*19|0,ha|0,q|0,((q|0)<0)<<31>>31|0)|0;ga=z;q=af(Pc*19|0,d|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;d=z;Lc=fg(Oc|0,Nc|0,Mc|0,Lc|0)|0;Jc=fg(Lc|0,z|0,Kc|0,Jc|0)|0;Hc=fg(Jc|0,z|0,Ic|0,Hc|0)|0;Fc=fg(Hc|0,z|0,Gc|0,Fc|0)|0;Dc=fg(Fc|0,z|0,Ec|0,Dc|0)|0;Bc=fg(Dc|0,z|0,Cc|0,Bc|0)|0;zc=fg(Bc|0,z|0,Ac|0,zc|0)|0;xc=fg(zc|0,z|0,yc|0,xc|0)|0;p=fg(xc|0,z|0,n|0,p|0)|0;n=z;ec=fg(wc|0,vc|0,dc|0,ec|0)|0;dc=z;rc=fg(uc|0,tc|0,sc|0,rc|0)|0;pc=fg(rc|0,z|0,qc|0,pc|0)|0;nc=fg(pc|0,z|0,oc|0,nc|0)|0;lc=fg(nc|0,z|0,mc|0,lc|0)|0;jc=fg(lc|0,z|0,kc|0,jc|0)|0;hc=fg(jc|0,z|0,ic|0,hc|0)|0;fc=fg(hc|0,z|0,gc|0,fc|0)|0;r=fg(fc|0,z|0,m|0,r|0)|0;M=fg(r|0,z|0,b|0,M|0)|0;b=z;r=fg(p|0,n|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;m=z;bc=fg(ec|0,dc|0,cc|0,bc|0)|0;$b=fg(bc|0,z|0,ac|0,$b|0)|0;Zb=fg($b|0,z|0,_b|0,Zb|0)|0;Xb=fg(Zb|0,z|0,Yb|0,Xb|0)|0;Vb=fg(Xb|0,z|0,Wb|0,Vb|0)|0;Tb=fg(Vb|0,z|0,Ub|0,Tb|0)|0;Rb=fg(Tb|0,z|0,Sb|0,Rb|0)|0;j=fg(Rb|0,z|0,k|0,j|0)|0;j=fg(j|0,z|0,r|0,m|0)|0;k=z;m=vf(r|0,m|0,26)|0;m=cg(p|0,n|0,m|0,z|0)|0;n=z;p=fg(M|0,b|0,33554432,0)|0;p=Xe(p|0,z|0,26)|0;r=z;Nb=fg(Qb|0,Pb|0,Ob|0,Nb|0)|0;Lb=fg(Nb|0,z|0,Mb|0,Lb|0)|0;Jb=fg(Lb|0,z|0,Kb|0,Jb|0)|0;Hb=fg(Jb|0,z|0,Ib|0,Hb|0)|0;Fb=fg(Hb|0,z|0,Gb|0,Fb|0)|0;Db=fg(Fb|0,z|0,Eb|0,Db|0)|0;Bb=fg(Db|0,z|0,Cb|0,Bb|0)|0;zb=fg(Bb|0,z|0,Ab|0,zb|0)|0;ya=fg(zb|0,z|0,g|0,ya|0)|0;ya=fg(ya|0,z|0,p|0,r|0)|0;g=z;r=vf(p|0,r|0,26)|0;r=cg(M|0,b|0,r|0,z|0)|0;b=z;M=fg(j|0,k|0,16777216,0)|0;M=Xe(M|0,z|0,25)|0;p=z;vb=fg(yb|0,xb|0,wb|0,vb|0)|0;tb=fg(vb|0,z|0,ub|0,tb|0)|0;rb=fg(tb|0,z|0,sb|0,rb|0)|0;pb=fg(rb|0,z|0,qb|0,pb|0)|0;nb=fg(pb|0,z|0,ob|0,nb|0)|0;lb=fg(nb|0,z|0,mb|0,lb|0)|0;jb=fg(lb|0,z|0,kb|0,jb|0)|0;hb=fg(jb|0,z|0,ib|0,hb|0)|0;f=fg(hb|0,z|0,fa|0,f|0)|0;f=fg(f|0,z|0,M|0,p|0)|0;fa=z;p=vf(M|0,p|0,25)|0;p=cg(j|0,k|0,p|0,z|0)|0;k=z;j=fg(ya|0,g|0,16777216,0)|0;j=Xe(j|0,z|0,25)|0;M=z;db=fg(gb|0,fb|0,eb|0,db|0)|0;bb=fg(db|0,z|0,cb|0,bb|0)|0;$a=fg(bb|0,z|0,ab|0,$a|0)|0;Za=fg($a|0,z|0,_a|0,Za|0)|0;Xa=fg(Za|0,z|0,Ya|0,Xa|0)|0;Va=fg(Xa|0,z|0,Wa|0,Va|0)|0;Ta=fg(Va|0,z|0,Ua|0,Ta|0)|0;Ra=fg(Ta|0,z|0,Sa|0,Ra|0)|0;i=fg(Ra|0,z|0,ea|0,i|0)|0;i=fg(i|0,z|0,j|0,M|0)|0;ea=z;M=vf(j|0,M|0,25)|0;M=cg(ya|0,g|0,M|0,z|0)|0;g=z;ya=fg(f|0,fa|0,33554432,0)|0;ya=Xe(ya|0,z|0,26)|0;j=z;Na=fg(Qa|0,Pa|0,Oa|0,Na|0)|0;La=fg(Na|0,z|0,Ma|0,La|0)|0;Ja=fg(La|0,z|0,Ka|0,Ja|0)|0;Ha=fg(Ja|0,z|0,Ia|0,Ha|0)|0;Fa=fg(Ha|0,z|0,Ga|0,Fa|0)|0;Da=fg(Fa|0,z|0,Ea|0,Da|0)|0;Ba=fg(Da|0,z|0,Ca|0,Ba|0)|0;za=fg(Ba|0,z|0,Aa|0,za|0)|0;e=fg(za|0,z|0,N|0,e|0)|0;e=fg(e|0,z|0,ya|0,j|0)|0;N=z;j=vf(ya|0,j|0,26)|0;j=cg(f|0,fa|0,j|0,z|0)|0;fa=fg(i|0,ea|0,33554432,0)|0;fa=Xe(fa|0,z|0,26)|0;f=z;ua=fg(xa|0,wa|0,va|0,ua|0)|0;sa=fg(ua|0,z|0,ta|0,sa|0)|0;qa=fg(sa|0,z|0,ra|0,qa|0)|0;oa=fg(qa|0,z|0,pa|0,oa|0)|0;ma=fg(oa|0,z|0,na|0,ma|0)|0;ka=fg(ma|0,z|0,la|0,ka|0)|0;ia=fg(ka|0,z|0,ja|0,ia|0)|0;ga=fg(ia|0,z|0,ha|0,ga|0)|0;h=fg(ga|0,z|0,L|0,h|0)|0;h=fg(h|0,z|0,fa|0,f|0)|0;L=z;f=vf(fa|0,f|0,26)|0;f=cg(i|0,ea|0,f|0,z|0)|0;ea=fg(e|0,N|0,16777216,0)|0;ea=Xe(ea|0,z|0,25)|0;i=z;b=fg(ea|0,i|0,r|0,b|0)|0;r=z;i=vf(ea|0,i|0,25)|0;i=cg(e|0,N|0,i|0,z|0)|0;N=fg(h|0,L|0,16777216,0)|0;N=Xe(N|0,z|0,25)|0;e=z;aa=fg(da|0,ca|0,ba|0,aa|0)|0;_=fg(aa|0,z|0,$|0,_|0)|0;Y=fg(_|0,z|0,Z|0,Y|0)|0;W=fg(Y|0,z|0,X|0,W|0)|0;U=fg(W|0,z|0,V|0,U|0)|0;S=fg(U|0,z|0,T|0,S|0)|0;Q=fg(S|0,z|0,R|0,Q|0)|0;O=fg(Q|0,z|0,P|0,O|0)|0;d=fg(O|0,z|0,q|0,d|0)|0;d=fg(d|0,z|0,N|0,e|0)|0;q=z;e=vf(N|0,e|0,25)|0;e=cg(h|0,L|0,e|0,z|0)|0;L=fg(b|0,r|0,33554432,0)|0;L=Xe(L|0,z|0,26)|0;h=z;g=fg(M|0,g|0,L|0,h|0)|0;h=vf(L|0,h|0,26)|0;h=cg(b|0,r|0,h|0,z|0)|0;r=fg(d|0,q|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;b=z;H=fg(K|0,J|0,I|0,H|0)|0;F=fg(H|0,z|0,G|0,F|0)|0;D=fg(F|0,z|0,E|0,D|0)|0;B=fg(D|0,z|0,C|0,B|0)|0;y=fg(B|0,z|0,A|0,y|0)|0;w=fg(y|0,z|0,x|0,w|0)|0;u=fg(w|0,z|0,v|0,u|0)|0;s=fg(u|0,z|0,t|0,s|0)|0;l=fg(s|0,z|0,o|0,l|0)|0;l=fg(l|0,z|0,r|0,b|0)|0;o=z;b=vf(r|0,b|0,26)|0;b=cg(d|0,q|0,b|0,z|0)|0;q=fg(l|0,o|0,16777216,0)|0;q=Xe(q|0,z|0,25)|0;d=z;r=af(q|0,d|0,19,0)|0;n=fg(r|0,z|0,m|0,n|0)|0;m=z;d=vf(q|0,d|0,25)|0;d=cg(l|0,o|0,d|0,z|0)|0;o=fg(n|0,m|0,33554432,0)|0;o=Xe(o|0,z|0,26)|0;l=z;k=fg(p|0,k|0,o|0,l|0)|0;l=vf(o|0,l|0,26)|0;l=cg(n|0,m|0,l|0,z|0)|0;c[a>>2]=l;c[a+4>>2]=k;c[a+8>>2]=j;c[a+12>>2]=i;c[a+16>>2]=h;c[a+20>>2]=g;c[a+24>>2]=f;c[a+28>>2]=e;c[a+32>>2]=b;c[a+36>>2]=d;return}function ma(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0;e=l;f=l=l+63&-64;l=l+2048|0;uh(f+1024|0,b);Ud(f+1024|0,a);uh(f,f+1024|0);Ud(f,d);a=0;do{b=a<<4;u=c[f+1024+((b|4)<<3)>>2]|0;x=c[f+1024+((b|4)<<3)+4>>2]|0;A=ce(c[f+1024+(b<<3)>>2]|0,c[f+1024+(b<<3)+4>>2]|0,u,x)|0;G=z;y=Ze(c[f+1024+((b|12)<<3)>>2]^A,c[f+1024+((b|12)<<3)+4>>2]^G,32)|0;t=z;D=ce(c[f+1024+((b|8)<<3)>>2]|0,c[f+1024+((b|8)<<3)+4>>2]|0,y,t)|0;q=z;x=Ze(u^D,x^q,24)|0;u=z;G=ce(A,G,x,u)|0;A=z;t=Ze(y^G,t^A,16)|0;y=z;c[f+1024+((b|12)<<3)>>2]=t;c[f+1024+((b|12)<<3)+4>>2]=y;q=ce(D,q,t,y)|0;D=z;c[f+1024+((b|8)<<3)>>2]=q;c[f+1024+((b|8)<<3)+4>>2]=D;D=Ze(x^q,u^D,63)|0;c[f+1024+((b|4)<<3)>>2]=D;c[f+1024+((b|4)<<3)+4>>2]=z;D=c[f+1024+((b|5)<<3)>>2]|0;u=c[f+1024+((b|5)<<3)+4>>2]|0;q=ce(c[f+1024+((b|1)<<3)>>2]|0,c[f+1024+((b|1)<<3)+4>>2]|0,D,u)|0;x=z;s=Ze(c[f+1024+((b|13)<<3)>>2]^q,c[f+1024+((b|13)<<3)+4>>2]^x,32)|0;m=z;B=ce(c[f+1024+((b|9)<<3)>>2]|0,c[f+1024+((b|9)<<3)+4>>2]|0,s,m)|0;p=z;u=Ze(D^B,u^p,24)|0;D=z;x=ce(q,x,u,D)|0;q=z;m=Ze(s^x,m^q,16)|0;s=z;p=ce(B,p,m,s)|0;B=z;c[f+1024+((b|9)<<3)>>2]=p;c[f+1024+((b|9)<<3)+4>>2]=B;B=Ze(u^p,D^B,63)|0;D=z;p=c[f+1024+((b|6)<<3)>>2]|0;u=c[f+1024+((b|6)<<3)+4>>2]|0;h=ce(c[f+1024+((b|2)<<3)>>2]|0,c[f+1024+((b|2)<<3)+4>>2]|0,p,u)|0;r=z;o=Ze(c[f+1024+((b|14)<<3)>>2]^h,c[f+1024+((b|14)<<3)+4>>2]^r,32)|0;i=z;F=ce(c[f+1024+((b|10)<<3)>>2]|0,c[f+1024+((b|10)<<3)+4>>2]|0,o,i)|0;E=z;u=Ze(p^F,u^E,24)|0;p=z;r=ce(h,r,u,p)|0;h=z;i=Ze(o^r,i^h,16)|0;o=z;E=ce(F,E,i,o)|0;F=z;p=Ze(u^E,p^F,63)|0;u=z;j=c[f+1024+((b|7)<<3)>>2]|0;k=c[f+1024+((b|7)<<3)+4>>2]|0;g=ce(c[f+1024+((b|3)<<3)>>2]|0,c[f+1024+((b|3)<<3)+4>>2]|0,j,k)|0;n=z;H=Ze(c[f+1024+((b|15)<<3)>>2]^g,c[f+1024+((b|15)<<3)+4>>2]^n,32)|0;C=z;w=ce(c[f+1024+((b|11)<<3)>>2]|0,c[f+1024+((b|11)<<3)+4>>2]|0,H,C)|0;v=z;k=Ze(j^w,k^v,24)|0;j=z;n=ce(g,n,k,j)|0;g=z;C=Ze(H^n,C^g,16)|0;H=z;v=ce(w,v,C,H)|0;w=z;j=Ze(k^v,j^w,63)|0;k=z;A=ce(G,A,B,D)|0;G=z;H=Ze(C^A,H^G,32)|0;C=z;F=ce(E,F,H,C)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;G=ce(A,G,D,B)|0;A=z;c[f+1024+(b<<3)>>2]=G;c[f+1024+(b<<3)+4>>2]=A;A=Ze(H^G,C^A,16)|0;C=z;c[f+1024+((b|15)<<3)>>2]=A;c[f+1024+((b|15)<<3)+4>>2]=C;C=ce(F,E,A,C)|0;A=z;c[f+1024+((b|10)<<3)>>2]=C;c[f+1024+((b|10)<<3)+4>>2]=A;A=Ze(D^C,B^A,63)|0;c[f+1024+((b|5)<<3)>>2]=A;c[f+1024+((b|5)<<3)+4>>2]=z;q=ce(x,q,p,u)|0;x=z;y=Ze(t^q,y^x,32)|0;t=z;w=ce(v,w,y,t)|0;v=z;u=Ze(p^w,u^v,24)|0;p=z;x=ce(q,x,u,p)|0;q=z;c[f+1024+((b|1)<<3)>>2]=x;c[f+1024+((b|1)<<3)+4>>2]=q;q=Ze(y^x,t^q,16)|0;t=z;c[f+1024+((b|12)<<3)>>2]=q;c[f+1024+((b|12)<<3)+4>>2]=t;t=ce(w,v,q,t)|0;q=z;c[f+1024+((b|11)<<3)>>2]=t;c[f+1024+((b|11)<<3)+4>>2]=q;q=Ze(u^t,p^q,63)|0;c[f+1024+((b|6)<<3)>>2]=q;c[f+1024+((b|6)<<3)+4>>2]=z;h=ce(r,h,j,k)|0;r=z;s=Ze(m^h,s^r,32)|0;m=z;q=ce(c[f+1024+((b|8)<<3)>>2]|0,c[f+1024+((b|8)<<3)+4>>2]|0,s,m)|0;p=z;k=Ze(j^q,k^p,24)|0;j=z;r=ce(h,r,k,j)|0;h=z;c[f+1024+((b|2)<<3)>>2]=r;c[f+1024+((b|2)<<3)+4>>2]=h;h=Ze(s^r,m^h,16)|0;m=z;c[f+1024+((b|13)<<3)>>2]=h;c[f+1024+((b|13)<<3)+4>>2]=m;m=ce(q,p,h,m)|0;h=z;c[f+1024+((b|8)<<3)>>2]=m;c[f+1024+((b|8)<<3)+4>>2]=h;h=Ze(k^m,j^h,63)|0;c[f+1024+((b|7)<<3)>>2]=h;c[f+1024+((b|7)<<3)+4>>2]=z;h=c[f+1024+((b|4)<<3)>>2]|0;j=c[f+1024+((b|4)<<3)+4>>2]|0;g=ce(n,g,h,j)|0;n=z;o=Ze(i^g,o^n,32)|0;i=z;m=ce(c[f+1024+((b|9)<<3)>>2]|0,c[f+1024+((b|9)<<3)+4>>2]|0,o,i)|0;k=z;j=Ze(h^m,j^k,24)|0;h=z;n=ce(g,n,j,h)|0;g=z;c[f+1024+((b|3)<<3)>>2]=n;c[f+1024+((b|3)<<3)+4>>2]=g;g=Ze(o^n,i^g,16)|0;i=z;c[f+1024+((b|14)<<3)>>2]=g;c[f+1024+((b|14)<<3)+4>>2]=i;i=ce(m,k,g,i)|0;g=z;c[f+1024+((b|9)<<3)>>2]=i;c[f+1024+((b|9)<<3)+4>>2]=g;g=Ze(j^i,h^g,63)|0;c[f+1024+((b|4)<<3)>>2]=g;c[f+1024+((b|4)<<3)+4>>2]=z;a=a+1|0}while((a|0)!=8);a=0;do{H=a<<1;p=f+1024+(H+32<<3)|0;s=c[p>>2]|0;p=c[p+4>>2]|0;m=ce(c[f+1024+(H<<3)>>2]|0,c[f+1024+(H<<3)+4>>2]|0,s,p)|0;g=z;o=f+1024+(H+96<<3)|0;o=Ze(c[o>>2]^m,c[o+4>>2]^g,32)|0;t=z;j=f+1024+(H+64<<3)|0;j=ce(c[j>>2]|0,c[j+4>>2]|0,o,t)|0;x=z;p=Ze(s^j,p^x,24)|0;s=z;g=ce(m,g,p,s)|0;m=z;t=Ze(o^g,t^m,16)|0;o=z;u=f+1024+(H+96<<3)|0;c[u>>2]=t;c[u+4>>2]=o;x=ce(j,x,t,o)|0;j=z;u=f+1024+(H+64<<3)|0;c[u>>2]=x;c[u+4>>2]=j;j=Ze(p^x,s^j,63)|0;s=f+1024+(H+32<<3)|0;c[s>>2]=j;c[s+4>>2]=z;s=f+1024+(H+33<<3)|0;j=c[s>>2]|0;s=c[s+4>>2]|0;x=ce(c[f+1024+((H|1)<<3)>>2]|0,c[f+1024+((H|1)<<3)+4>>2]|0,j,s)|0;p=z;u=f+1024+(H+97<<3)|0;u=Ze(c[u>>2]^x,c[u+4>>2]^p,32)|0;B=z;n=f+1024+(H+65<<3)|0;n=ce(c[n>>2]|0,c[n+4>>2]|0,u,B)|0;F=z;s=Ze(j^n,s^F,24)|0;j=z;p=ce(x,p,s,j)|0;x=z;B=Ze(u^p,B^x,16)|0;u=z;F=ce(n,F,B,u)|0;n=z;w=f+1024+(H+65<<3)|0;c[w>>2]=F;c[w+4>>2]=n;n=Ze(s^F,j^n,63)|0;j=z;F=f+1024+(H+16<<3)|0;s=f+1024+(H+48<<3)|0;w=c[s>>2]|0;s=c[s+4>>2]|0;F=ce(c[F>>2]|0,c[F+4>>2]|0,w,s)|0;v=z;y=f+1024+(H+112<<3)|0;y=Ze(c[y>>2]^F,c[y+4>>2]^v,32)|0;E=z;h=f+1024+(H+80<<3)|0;h=ce(c[h>>2]|0,c[h+4>>2]|0,y,E)|0;i=z;s=Ze(w^h,s^i,24)|0;w=z;v=ce(F,v,s,w)|0;F=z;E=Ze(y^v,E^F,16)|0;y=z;i=ce(h,i,E,y)|0;h=z;w=Ze(s^i,w^h,63)|0;s=z;G=f+1024+(H+17<<3)|0;C=f+1024+(H+49<<3)|0;D=c[C>>2]|0;C=c[C+4>>2]|0;G=ce(c[G>>2]|0,c[G+4>>2]|0,D,C)|0;A=z;b=f+1024+(H+113<<3)|0;b=Ze(c[b>>2]^G,c[b+4>>2]^A,32)|0;k=z;q=f+1024+(H+81<<3)|0;q=ce(c[q>>2]|0,c[q+4>>2]|0,b,k)|0;r=z;C=Ze(D^q,C^r,24)|0;D=z;A=ce(G,A,C,D)|0;G=z;k=Ze(b^A,k^G,16)|0;b=z;r=ce(q,r,k,b)|0;q=z;D=Ze(C^r,D^q,63)|0;C=z;m=ce(g,m,n,j)|0;g=z;b=Ze(k^m,b^g,32)|0;k=z;h=ce(i,h,b,k)|0;i=z;j=Ze(n^h,j^i,24)|0;n=z;g=ce(m,g,j,n)|0;m=z;c[f+1024+(H<<3)>>2]=g;c[f+1024+(H<<3)+4>>2]=m;m=Ze(b^g,k^m,16)|0;k=z;g=f+1024+(H+113<<3)|0;c[g>>2]=m;c[g+4>>2]=k;k=ce(h,i,m,k)|0;m=z;i=f+1024+(H+80<<3)|0;c[i>>2]=k;c[i+4>>2]=m;m=Ze(j^k,n^m,63)|0;n=f+1024+(H+33<<3)|0;c[n>>2]=m;c[n+4>>2]=z;x=ce(p,x,w,s)|0;p=z;o=Ze(t^x,o^p,32)|0;t=z;q=ce(r,q,o,t)|0;r=z;s=Ze(w^q,s^r,24)|0;w=z;p=ce(x,p,s,w)|0;x=z;c[f+1024+((H|1)<<3)>>2]=p;c[f+1024+((H|1)<<3)+4>>2]=x;x=Ze(o^p,t^x,16)|0;t=z;p=f+1024+(H+96<<3)|0;c[p>>2]=x;c[p+4>>2]=t;t=ce(q,r,x,t)|0;x=z;r=f+1024+(H+81<<3)|0;c[r>>2]=t;c[r+4>>2]=x;x=Ze(s^t,w^x,63)|0;w=f+1024+(H+48<<3)|0;c[w>>2]=x;c[w+4>>2]=z;F=ce(v,F,D,C)|0;v=z;u=Ze(B^F,u^v,32)|0;B=z;w=f+1024+(H+64<<3)|0;w=ce(c[w>>2]|0,c[w+4>>2]|0,u,B)|0;x=z;C=Ze(D^w,C^x,24)|0;D=z;v=ce(F,v,C,D)|0;F=z;t=f+1024+(H+16<<3)|0;c[t>>2]=v;c[t+4>>2]=F;F=Ze(u^v,B^F,16)|0;B=z;v=f+1024+(H+97<<3)|0;c[v>>2]=F;c[v+4>>2]=B;B=ce(w,x,F,B)|0;F=z;x=f+1024+(H+64<<3)|0;c[x>>2]=B;c[x+4>>2]=F;F=Ze(C^B,D^F,63)|0;D=f+1024+(H+49<<3)|0;c[D>>2]=F;c[D+4>>2]=z;D=f+1024+(H+32<<3)|0;F=c[D>>2]|0;D=c[D+4>>2]|0;G=ce(A,G,F,D)|0;A=z;y=Ze(E^G,y^A,32)|0;E=z;B=f+1024+(H+65<<3)|0;B=ce(c[B>>2]|0,c[B+4>>2]|0,y,E)|0;C=z;D=Ze(F^B,D^C,24)|0;F=z;A=ce(G,A,D,F)|0;G=z;x=f+1024+(H+17<<3)|0;c[x>>2]=A;c[x+4>>2]=G;G=Ze(y^A,E^G,16)|0;E=z;A=f+1024+(H+112<<3)|0;c[A>>2]=G;c[A+4>>2]=E;E=ce(B,C,G,E)|0;G=z;C=f+1024+(H+65<<3)|0;c[C>>2]=E;c[C+4>>2]=G;G=Ze(D^E,F^G,63)|0;H=f+1024+(H+32<<3)|0;c[H>>2]=G;c[H+4>>2]=z;a=a+1|0}while((a|0)!=8);uh(d,f);Ud(d,f+1024|0);l=e;return}function na(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0;e=l;f=l=l+63&-64;l=l+2048|0;uh(f+1024|0,b);Ud(f+1024|0,a);uh(f,f+1024|0);a=0;do{b=a<<4;u=c[f+1024+((b|4)<<3)>>2]|0;x=c[f+1024+((b|4)<<3)+4>>2]|0;A=ce(c[f+1024+(b<<3)>>2]|0,c[f+1024+(b<<3)+4>>2]|0,u,x)|0;G=z;y=Ze(c[f+1024+((b|12)<<3)>>2]^A,c[f+1024+((b|12)<<3)+4>>2]^G,32)|0;t=z;D=ce(c[f+1024+((b|8)<<3)>>2]|0,c[f+1024+((b|8)<<3)+4>>2]|0,y,t)|0;q=z;x=Ze(u^D,x^q,24)|0;u=z;G=ce(A,G,x,u)|0;A=z;t=Ze(y^G,t^A,16)|0;y=z;c[f+1024+((b|12)<<3)>>2]=t;c[f+1024+((b|12)<<3)+4>>2]=y;q=ce(D,q,t,y)|0;D=z;c[f+1024+((b|8)<<3)>>2]=q;c[f+1024+((b|8)<<3)+4>>2]=D;D=Ze(x^q,u^D,63)|0;c[f+1024+((b|4)<<3)>>2]=D;c[f+1024+((b|4)<<3)+4>>2]=z;D=c[f+1024+((b|5)<<3)>>2]|0;u=c[f+1024+((b|5)<<3)+4>>2]|0;q=ce(c[f+1024+((b|1)<<3)>>2]|0,c[f+1024+((b|1)<<3)+4>>2]|0,D,u)|0;x=z;s=Ze(c[f+1024+((b|13)<<3)>>2]^q,c[f+1024+((b|13)<<3)+4>>2]^x,32)|0;m=z;B=ce(c[f+1024+((b|9)<<3)>>2]|0,c[f+1024+((b|9)<<3)+4>>2]|0,s,m)|0;p=z;u=Ze(D^B,u^p,24)|0;D=z;x=ce(q,x,u,D)|0;q=z;m=Ze(s^x,m^q,16)|0;s=z;p=ce(B,p,m,s)|0;B=z;c[f+1024+((b|9)<<3)>>2]=p;c[f+1024+((b|9)<<3)+4>>2]=B;B=Ze(u^p,D^B,63)|0;D=z;p=c[f+1024+((b|6)<<3)>>2]|0;u=c[f+1024+((b|6)<<3)+4>>2]|0;h=ce(c[f+1024+((b|2)<<3)>>2]|0,c[f+1024+((b|2)<<3)+4>>2]|0,p,u)|0;r=z;o=Ze(c[f+1024+((b|14)<<3)>>2]^h,c[f+1024+((b|14)<<3)+4>>2]^r,32)|0;i=z;F=ce(c[f+1024+((b|10)<<3)>>2]|0,c[f+1024+((b|10)<<3)+4>>2]|0,o,i)|0;E=z;u=Ze(p^F,u^E,24)|0;p=z;r=ce(h,r,u,p)|0;h=z;i=Ze(o^r,i^h,16)|0;o=z;E=ce(F,E,i,o)|0;F=z;p=Ze(u^E,p^F,63)|0;u=z;j=c[f+1024+((b|7)<<3)>>2]|0;k=c[f+1024+((b|7)<<3)+4>>2]|0;g=ce(c[f+1024+((b|3)<<3)>>2]|0,c[f+1024+((b|3)<<3)+4>>2]|0,j,k)|0;n=z;H=Ze(c[f+1024+((b|15)<<3)>>2]^g,c[f+1024+((b|15)<<3)+4>>2]^n,32)|0;C=z;w=ce(c[f+1024+((b|11)<<3)>>2]|0,c[f+1024+((b|11)<<3)+4>>2]|0,H,C)|0;v=z;k=Ze(j^w,k^v,24)|0;j=z;n=ce(g,n,k,j)|0;g=z;C=Ze(H^n,C^g,16)|0;H=z;v=ce(w,v,C,H)|0;w=z;j=Ze(k^v,j^w,63)|0;k=z;A=ce(G,A,B,D)|0;G=z;H=Ze(C^A,H^G,32)|0;C=z;F=ce(E,F,H,C)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;G=ce(A,G,D,B)|0;A=z;c[f+1024+(b<<3)>>2]=G;c[f+1024+(b<<3)+4>>2]=A;A=Ze(H^G,C^A,16)|0;C=z;c[f+1024+((b|15)<<3)>>2]=A;c[f+1024+((b|15)<<3)+4>>2]=C;C=ce(F,E,A,C)|0;A=z;c[f+1024+((b|10)<<3)>>2]=C;c[f+1024+((b|10)<<3)+4>>2]=A;A=Ze(D^C,B^A,63)|0;c[f+1024+((b|5)<<3)>>2]=A;c[f+1024+((b|5)<<3)+4>>2]=z;q=ce(x,q,p,u)|0;x=z;y=Ze(t^q,y^x,32)|0;t=z;w=ce(v,w,y,t)|0;v=z;u=Ze(p^w,u^v,24)|0;p=z;x=ce(q,x,u,p)|0;q=z;c[f+1024+((b|1)<<3)>>2]=x;c[f+1024+((b|1)<<3)+4>>2]=q;q=Ze(y^x,t^q,16)|0;t=z;c[f+1024+((b|12)<<3)>>2]=q;c[f+1024+((b|12)<<3)+4>>2]=t;t=ce(w,v,q,t)|0;q=z;c[f+1024+((b|11)<<3)>>2]=t;c[f+1024+((b|11)<<3)+4>>2]=q;q=Ze(u^t,p^q,63)|0;c[f+1024+((b|6)<<3)>>2]=q;c[f+1024+((b|6)<<3)+4>>2]=z;h=ce(r,h,j,k)|0;r=z;s=Ze(m^h,s^r,32)|0;m=z;q=ce(c[f+1024+((b|8)<<3)>>2]|0,c[f+1024+((b|8)<<3)+4>>2]|0,s,m)|0;p=z;k=Ze(j^q,k^p,24)|0;j=z;r=ce(h,r,k,j)|0;h=z;c[f+1024+((b|2)<<3)>>2]=r;c[f+1024+((b|2)<<3)+4>>2]=h;h=Ze(s^r,m^h,16)|0;m=z;c[f+1024+((b|13)<<3)>>2]=h;c[f+1024+((b|13)<<3)+4>>2]=m;m=ce(q,p,h,m)|0;h=z;c[f+1024+((b|8)<<3)>>2]=m;c[f+1024+((b|8)<<3)+4>>2]=h;h=Ze(k^m,j^h,63)|0;c[f+1024+((b|7)<<3)>>2]=h;c[f+1024+((b|7)<<3)+4>>2]=z;h=c[f+1024+((b|4)<<3)>>2]|0;j=c[f+1024+((b|4)<<3)+4>>2]|0;g=ce(n,g,h,j)|0;n=z;o=Ze(i^g,o^n,32)|0;i=z;m=ce(c[f+1024+((b|9)<<3)>>2]|0,c[f+1024+((b|9)<<3)+4>>2]|0,o,i)|0;k=z;j=Ze(h^m,j^k,24)|0;h=z;n=ce(g,n,j,h)|0;g=z;c[f+1024+((b|3)<<3)>>2]=n;c[f+1024+((b|3)<<3)+4>>2]=g;g=Ze(o^n,i^g,16)|0;i=z;c[f+1024+((b|14)<<3)>>2]=g;c[f+1024+((b|14)<<3)+4>>2]=i;i=ce(m,k,g,i)|0;g=z;c[f+1024+((b|9)<<3)>>2]=i;c[f+1024+((b|9)<<3)+4>>2]=g;g=Ze(j^i,h^g,63)|0;c[f+1024+((b|4)<<3)>>2]=g;c[f+1024+((b|4)<<3)+4>>2]=z;a=a+1|0}while((a|0)!=8);a=0;do{H=a<<1;p=f+1024+(H+32<<3)|0;s=c[p>>2]|0;p=c[p+4>>2]|0;m=ce(c[f+1024+(H<<3)>>2]|0,c[f+1024+(H<<3)+4>>2]|0,s,p)|0;g=z;o=f+1024+(H+96<<3)|0;o=Ze(c[o>>2]^m,c[o+4>>2]^g,32)|0;t=z;j=f+1024+(H+64<<3)|0;j=ce(c[j>>2]|0,c[j+4>>2]|0,o,t)|0;x=z;p=Ze(s^j,p^x,24)|0;s=z;g=ce(m,g,p,s)|0;m=z;t=Ze(o^g,t^m,16)|0;o=z;u=f+1024+(H+96<<3)|0;c[u>>2]=t;c[u+4>>2]=o;x=ce(j,x,t,o)|0;j=z;u=f+1024+(H+64<<3)|0;c[u>>2]=x;c[u+4>>2]=j;j=Ze(p^x,s^j,63)|0;s=f+1024+(H+32<<3)|0;c[s>>2]=j;c[s+4>>2]=z;s=f+1024+(H+33<<3)|0;j=c[s>>2]|0;s=c[s+4>>2]|0;x=ce(c[f+1024+((H|1)<<3)>>2]|0,c[f+1024+((H|1)<<3)+4>>2]|0,j,s)|0;p=z;u=f+1024+(H+97<<3)|0;u=Ze(c[u>>2]^x,c[u+4>>2]^p,32)|0;B=z;n=f+1024+(H+65<<3)|0;n=ce(c[n>>2]|0,c[n+4>>2]|0,u,B)|0;F=z;s=Ze(j^n,s^F,24)|0;j=z;p=ce(x,p,s,j)|0;x=z;B=Ze(u^p,B^x,16)|0;u=z;F=ce(n,F,B,u)|0;n=z;w=f+1024+(H+65<<3)|0;c[w>>2]=F;c[w+4>>2]=n;n=Ze(s^F,j^n,63)|0;j=z;F=f+1024+(H+16<<3)|0;s=f+1024+(H+48<<3)|0;w=c[s>>2]|0;s=c[s+4>>2]|0;F=ce(c[F>>2]|0,c[F+4>>2]|0,w,s)|0;v=z;y=f+1024+(H+112<<3)|0;y=Ze(c[y>>2]^F,c[y+4>>2]^v,32)|0;E=z;h=f+1024+(H+80<<3)|0;h=ce(c[h>>2]|0,c[h+4>>2]|0,y,E)|0;i=z;s=Ze(w^h,s^i,24)|0;w=z;v=ce(F,v,s,w)|0;F=z;E=Ze(y^v,E^F,16)|0;y=z;i=ce(h,i,E,y)|0;h=z;w=Ze(s^i,w^h,63)|0;s=z;G=f+1024+(H+17<<3)|0;C=f+1024+(H+49<<3)|0;D=c[C>>2]|0;C=c[C+4>>2]|0;G=ce(c[G>>2]|0,c[G+4>>2]|0,D,C)|0;A=z;b=f+1024+(H+113<<3)|0;b=Ze(c[b>>2]^G,c[b+4>>2]^A,32)|0;k=z;q=f+1024+(H+81<<3)|0;q=ce(c[q>>2]|0,c[q+4>>2]|0,b,k)|0;r=z;C=Ze(D^q,C^r,24)|0;D=z;A=ce(G,A,C,D)|0;G=z;k=Ze(b^A,k^G,16)|0;b=z;r=ce(q,r,k,b)|0;q=z;D=Ze(C^r,D^q,63)|0;C=z;m=ce(g,m,n,j)|0;g=z;b=Ze(k^m,b^g,32)|0;k=z;h=ce(i,h,b,k)|0;i=z;j=Ze(n^h,j^i,24)|0;n=z;g=ce(m,g,j,n)|0;m=z;c[f+1024+(H<<3)>>2]=g;c[f+1024+(H<<3)+4>>2]=m;m=Ze(b^g,k^m,16)|0;k=z;g=f+1024+(H+113<<3)|0;c[g>>2]=m;c[g+4>>2]=k;k=ce(h,i,m,k)|0;m=z;i=f+1024+(H+80<<3)|0;c[i>>2]=k;c[i+4>>2]=m;m=Ze(j^k,n^m,63)|0;n=f+1024+(H+33<<3)|0;c[n>>2]=m;c[n+4>>2]=z;x=ce(p,x,w,s)|0;p=z;o=Ze(t^x,o^p,32)|0;t=z;q=ce(r,q,o,t)|0;r=z;s=Ze(w^q,s^r,24)|0;w=z;p=ce(x,p,s,w)|0;x=z;c[f+1024+((H|1)<<3)>>2]=p;c[f+1024+((H|1)<<3)+4>>2]=x;x=Ze(o^p,t^x,16)|0;t=z;p=f+1024+(H+96<<3)|0;c[p>>2]=x;c[p+4>>2]=t;t=ce(q,r,x,t)|0;x=z;r=f+1024+(H+81<<3)|0;c[r>>2]=t;c[r+4>>2]=x;x=Ze(s^t,w^x,63)|0;w=f+1024+(H+48<<3)|0;c[w>>2]=x;c[w+4>>2]=z;F=ce(v,F,D,C)|0;v=z;u=Ze(B^F,u^v,32)|0;B=z;w=f+1024+(H+64<<3)|0;w=ce(c[w>>2]|0,c[w+4>>2]|0,u,B)|0;x=z;C=Ze(D^w,C^x,24)|0;D=z;v=ce(F,v,C,D)|0;F=z;t=f+1024+(H+16<<3)|0;c[t>>2]=v;c[t+4>>2]=F;F=Ze(u^v,B^F,16)|0;B=z;v=f+1024+(H+97<<3)|0;c[v>>2]=F;c[v+4>>2]=B;B=ce(w,x,F,B)|0;F=z;x=f+1024+(H+64<<3)|0;c[x>>2]=B;c[x+4>>2]=F;F=Ze(C^B,D^F,63)|0;D=f+1024+(H+49<<3)|0;c[D>>2]=F;c[D+4>>2]=z;D=f+1024+(H+32<<3)|0;F=c[D>>2]|0;D=c[D+4>>2]|0;G=ce(A,G,F,D)|0;A=z;y=Ze(E^G,y^A,32)|0;E=z;B=f+1024+(H+65<<3)|0;B=ce(c[B>>2]|0,c[B+4>>2]|0,y,E)|0;C=z;D=Ze(F^B,D^C,24)|0;F=z;A=ce(G,A,D,F)|0;G=z;x=f+1024+(H+17<<3)|0;c[x>>2]=A;c[x+4>>2]=G;G=Ze(y^A,E^G,16)|0;E=z;A=f+1024+(H+112<<3)|0;c[A>>2]=G;c[A+4>>2]=E;E=ce(B,C,G,E)|0;G=z;C=f+1024+(H+65<<3)|0;c[C>>2]=E;c[C+4>>2]=G;G=Ze(D^E,F^G,63)|0;H=f+1024+(H+32<<3)|0;c[H>>2]=G;c[H+4>>2]=z;a=a+1|0}while((a|0)!=8);uh(d,f);Ud(d,f+1024|0);l=e;return}function oa(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0,sa=0,ta=0,ua=0,va=0,wa=0,xa=0,ya=0,za=0,Aa=0,Ba=0,Ca=0,Da=0,Ea=0,Fa=0,Ga=0,Ha=0,Ia=0,Ja=0,Ka=0,La=0,Ma=0,Na=0,Oa=0,Pa=0,Qa=0,Ra=0,Sa=0,Ta=0,Ua=0,Va=0,Wa=0,Xa=0,Ya=0,Za=0,_a=0,$a=0,ab=0,bb=0,cb=0,db=0,eb=0;l=c[b>>2]|0;n=c[b+4>>2]|0;k=c[b+8>>2]|0;f=c[b+12>>2]|0;u=c[b+16>>2]|0;t=c[b+20>>2]|0;g=c[b+24>>2]|0;v=c[b+28>>2]|0;s=c[b+32>>2]|0;q=c[b+36>>2]|0;cb=af(l|0,((l|0)<0)<<31>>31|0,l|0,((l|0)<0)<<31>>31|0)|0;bb=z;o=((l<<1|0)<0)<<31>>31;Ua=af(l<<1|0,o|0,n|0,((n|0)<0)<<31>>31|0)|0;Ta=z;Oa=af(k|0,((k|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Na=z;Ea=af(f|0,((f|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Da=z;sa=af(u|0,((u|0)<0)<<31>>31|0,l<<1|0,o|0)|0;ra=z;ia=af(t|0,((t|0)<0)<<31>>31|0,l<<1|0,o|0)|0;ha=z;_=af(g|0,((g|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Z=z;Q=af(v|0,((v|0)<0)<<31>>31|0,l<<1|0,o|0)|0;P=z;G=af(s|0,((s|0)<0)<<31>>31|0,l<<1|0,o|0)|0;F=z;o=af(q|0,((q|0)<0)<<31>>31|0,l<<1|0,o|0)|0;l=z;p=((n<<1|0)<0)<<31>>31;Ma=af(n<<1|0,p|0,n|0,((n|0)<0)<<31>>31|0)|0;La=z;Ca=af(n<<1|0,p|0,k|0,((k|0)<0)<<31>>31|0)|0;Ba=z;w=((f<<1|0)<0)<<31>>31;wa=af(f<<1|0,w|0,n<<1|0,p|0)|0;va=z;ma=af(u|0,((u|0)<0)<<31>>31|0,n<<1|0,p|0)|0;la=z;aa=af(t<<1|0,((t<<1|0)<0)<<31>>31|0,n<<1|0,p|0)|0;$=z;S=af(g|0,((g|0)<0)<<31>>31|0,n<<1|0,p|0)|0;R=z;I=af(v<<1|0,((v<<1|0)<0)<<31>>31|0,n<<1|0,p|0)|0;H=z;m=af(s|0,((s|0)<0)<<31>>31|0,n<<1|0,p|0)|0;r=z;b=((q*38|0)<0)<<31>>31;p=af(q*38|0,b|0,n<<1|0,p|0)|0;n=z;ua=af(k|0,((k|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;ta=z;ka=af(k<<1|0,((k<<1|0)<0)<<31>>31|0,f|0,((f|0)<0)<<31>>31|0)|0;ja=z;ca=af(u|0,((u|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;ba=z;W=af(t|0,((t|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;V=z;O=af(g|0,((g|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;N=z;A=af(v|0,((v|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;y=z;Y=((s*19|0)<0)<<31>>31;Ya=af(s*19|0,Y|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;Xa=z;k=af(q*38|0,b|0,k|0,((k|0)<0)<<31>>31|0)|0;j=z;ea=af(f<<1|0,w|0,f|0,((f|0)<0)<<31>>31|0)|0;da=z;U=af(f<<1|0,w|0,u|0,((u|0)<0)<<31>>31|0)|0;T=z;K=af(t<<1|0,((t<<1|0)<0)<<31>>31|0,f<<1|0,w|0)|0;J=z;E=af(g|0,((g|0)<0)<<31>>31|0,f<<1|0,w|0)|0;D=z;qa=((v*38|0)<0)<<31>>31;_a=af(v*38|0,qa|0,f<<1|0,w|0)|0;Za=z;Qa=af(s*19|0,Y|0,f<<1|0,w|0)|0;Pa=z;w=af(q*38|0,b|0,f<<1|0,w|0)|0;f=z;M=af(u|0,((u|0)<0)<<31>>31|0,u|0,((u|0)<0)<<31>>31|0)|0;L=z;C=af(u<<1|0,((u<<1|0)<0)<<31>>31|0,t|0,((t|0)<0)<<31>>31|0)|0;B=z;ab=af(g*19|0,((g*19|0)<0)<<31>>31|0,u<<1|0,((u<<1|0)<0)<<31>>31|0)|0;$a=z;Sa=af(v*38|0,qa|0,u|0,((u|0)<0)<<31>>31|0)|0;Ra=z;Ga=af(s*19|0,Y|0,u<<1|0,((u<<1|0)<0)<<31>>31|0)|0;Fa=z;u=af(q*38|0,b|0,u|0,((u|0)<0)<<31>>31|0)|0;e=z;eb=af(t*38|0,((t*38|0)<0)<<31>>31|0,t|0,((t|0)<0)<<31>>31|0)|0;db=z;Wa=af(g*19|0,((g*19|0)<0)<<31>>31|0,t<<1|0,((t<<1|0)<0)<<31>>31|0)|0;Va=z;Ia=af(v*38|0,qa|0,t<<1|0,((t<<1|0)<0)<<31>>31|0)|0;Ha=z;ya=af(s*19|0,Y|0,t<<1|0,((t<<1|0)<0)<<31>>31|0)|0;xa=z;t=af(q*38|0,b|0,t<<1|0,((t<<1|0)<0)<<31>>31|0)|0;d=z;Ka=af(g*19|0,((g*19|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;Ja=z;Aa=af(v*38|0,qa|0,g|0,((g|0)<0)<<31>>31|0)|0;za=z;oa=af(s*19|0,Y|0,g<<1|0,((g<<1|0)<0)<<31>>31|0)|0;na=z;g=af(q*38|0,b|0,g|0,((g|0)<0)<<31>>31|0)|0;x=z;qa=af(v*38|0,qa|0,v|0,((v|0)<0)<<31>>31|0)|0;pa=z;ga=af(s*19|0,Y|0,v<<1|0,((v<<1|0)<0)<<31>>31|0)|0;fa=z;v=af(q*38|0,b|0,v<<1|0,((v<<1|0)<0)<<31>>31|0)|0;i=z;Y=af(s*19|0,Y|0,s|0,((s|0)<0)<<31>>31|0)|0;X=z;s=af(q*38|0,b|0,s|0,((s|0)<0)<<31>>31|0)|0;h=z;q=af(q*38|0,b|0,q|0,((q|0)<0)<<31>>31|0)|0;b=z;bb=fg(eb|0,db|0,cb|0,bb|0)|0;$a=fg(bb|0,z|0,ab|0,$a|0)|0;Za=fg($a|0,z|0,_a|0,Za|0)|0;Xa=fg(Za|0,z|0,Ya|0,Xa|0)|0;n=fg(Xa|0,z|0,p|0,n|0)|0;p=z;Ta=fg(Wa|0,Va|0,Ua|0,Ta|0)|0;Ra=fg(Ta|0,z|0,Sa|0,Ra|0)|0;Pa=fg(Ra|0,z|0,Qa|0,Pa|0)|0;j=fg(Pa|0,z|0,k|0,j|0)|0;k=z;La=fg(Oa|0,Na|0,Ma|0,La|0)|0;Ja=fg(La|0,z|0,Ka|0,Ja|0)|0;Ha=fg(Ja|0,z|0,Ia|0,Ha|0)|0;Fa=fg(Ha|0,z|0,Ga|0,Fa|0)|0;f=fg(Fa|0,z|0,w|0,f|0)|0;w=z;Ba=fg(Ea|0,Da|0,Ca|0,Ba|0)|0;za=fg(Ba|0,z|0,Aa|0,za|0)|0;xa=fg(za|0,z|0,ya|0,xa|0)|0;e=fg(xa|0,z|0,u|0,e|0)|0;u=z;ta=fg(wa|0,va|0,ua|0,ta|0)|0;ra=fg(ta|0,z|0,sa|0,ra|0)|0;pa=fg(ra|0,z|0,qa|0,pa|0)|0;na=fg(pa|0,z|0,oa|0,na|0)|0;d=fg(na|0,z|0,t|0,d|0)|0;t=z;ja=fg(ma|0,la|0,ka|0,ja|0)|0;ha=fg(ja|0,z|0,ia|0,ha|0)|0;fa=fg(ha|0,z|0,ga|0,fa|0)|0;x=fg(fa|0,z|0,g|0,x|0)|0;g=z;ba=fg(ea|0,da|0,ca|0,ba|0)|0;$=fg(ba|0,z|0,aa|0,$|0)|0;Z=fg($|0,z|0,_|0,Z|0)|0;X=fg(Z|0,z|0,Y|0,X|0)|0;i=fg(X|0,z|0,v|0,i|0)|0;v=z;T=fg(W|0,V|0,U|0,T|0)|0;R=fg(T|0,z|0,S|0,R|0)|0;P=fg(R|0,z|0,Q|0,P|0)|0;h=fg(P|0,z|0,s|0,h|0)|0;s=z;L=fg(O|0,N|0,M|0,L|0)|0;J=fg(L|0,z|0,K|0,J|0)|0;H=fg(J|0,z|0,I|0,H|0)|0;F=fg(H|0,z|0,G|0,F|0)|0;b=fg(F|0,z|0,q|0,b|0)|0;q=z;B=fg(E|0,D|0,C|0,B|0)|0;y=fg(B|0,z|0,A|0,y|0)|0;r=fg(y|0,z|0,m|0,r|0)|0;l=fg(r|0,z|0,o|0,l|0)|0;o=z;p=vf(n|0,p|0,1)|0;n=z;k=vf(j|0,k|0,1)|0;j=z;w=vf(f|0,w|0,1)|0;f=z;u=vf(e|0,u|0,1)|0;e=z;t=vf(d|0,t|0,1)|0;d=z;g=vf(x|0,g|0,1)|0;x=z;v=vf(i|0,v|0,1)|0;i=z;s=vf(h|0,s|0,1)|0;h=z;q=vf(b|0,q|0,1)|0;b=z;o=vf(l|0,o|0,1)|0;l=z;r=fg(p|0,n|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;m=z;j=fg(r|0,m|0,k|0,j|0)|0;k=z;m=vf(r|0,m|0,26)|0;m=cg(p|0,n|0,m|0,z|0)|0;n=z;p=fg(t|0,d|0,33554432,0)|0;p=Xe(p|0,z|0,26)|0;r=z;x=fg(p|0,r|0,g|0,x|0)|0;g=z;r=vf(p|0,r|0,26)|0;r=cg(t|0,d|0,r|0,z|0)|0;d=z;t=fg(j|0,k|0,16777216,0)|0;t=Xe(t|0,z|0,25)|0;p=z;f=fg(t|0,p|0,w|0,f|0)|0;w=z;p=vf(t|0,p|0,25)|0;p=cg(j|0,k|0,p|0,z|0)|0;k=z;j=fg(x|0,g|0,16777216,0)|0;j=Xe(j|0,z|0,25)|0;t=z;i=fg(j|0,t|0,v|0,i|0)|0;v=z;t=vf(j|0,t|0,25)|0;t=cg(x|0,g|0,t|0,z|0)|0;g=z;x=fg(f|0,w|0,33554432,0)|0;x=Xe(x|0,z|0,26)|0;j=z;e=fg(x|0,j|0,u|0,e|0)|0;u=z;j=vf(x|0,j|0,26)|0;j=cg(f|0,w|0,j|0,z|0)|0;w=fg(i|0,v|0,33554432,0)|0;w=Xe(w|0,z|0,26)|0;f=z;h=fg(w|0,f|0,s|0,h|0)|0;s=z;f=vf(w|0,f|0,26)|0;f=cg(i|0,v|0,f|0,z|0)|0;v=fg(e|0,u|0,16777216,0)|0;v=Xe(v|0,z|0,25)|0;i=z;d=fg(v|0,i|0,r|0,d|0)|0;r=z;i=vf(v|0,i|0,25)|0;i=cg(e|0,u|0,i|0,z|0)|0;u=fg(h|0,s|0,16777216,0)|0;u=Xe(u|0,z|0,25)|0;e=z;b=fg(u|0,e|0,q|0,b|0)|0;q=z;e=vf(u|0,e|0,25)|0;e=cg(h|0,s|0,e|0,z|0)|0;s=fg(d|0,r|0,33554432,0)|0;s=Xe(s|0,z|0,26)|0;h=z;g=fg(t|0,g|0,s|0,h|0)|0;h=vf(s|0,h|0,26)|0;h=cg(d|0,r|0,h|0,z|0)|0;r=fg(b|0,q|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;d=z;l=fg(r|0,d|0,o|0,l|0)|0;o=z;d=vf(r|0,d|0,26)|0;d=cg(b|0,q|0,d|0,z|0)|0;q=fg(l|0,o|0,16777216,0)|0;q=Xe(q|0,z|0,25)|0;b=z;r=af(q|0,b|0,19,0)|0;n=fg(r|0,z|0,m|0,n|0)|0;m=z;b=vf(q|0,b|0,25)|0;b=cg(l|0,o|0,b|0,z|0)|0;o=fg(n|0,m|0,33554432,0)|0;o=Xe(o|0,z|0,26)|0;l=z;k=fg(p|0,k|0,o|0,l|0)|0;l=vf(o|0,l|0,26)|0;l=cg(n|0,m|0,l|0,z|0)|0;c[a>>2]=l;c[a+4>>2]=k;c[a+8>>2]=j;c[a+12>>2]=i;c[a+16>>2]=h;c[a+20>>2]=g;c[a+24>>2]=f;c[a+28>>2]=e;c[a+32>>2]=d;c[a+36>>2]=b;return}function pa(a,b,d,e){a=a|0;b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0;tf(d,b);c[e>>2]=c[a>>2];c[e+4>>2]=c[a+4>>2];c[e+8>>2]=c[a+8>>2];c[e+12>>2]=c[a+12>>2];c[e+16>>2]=c[a+16>>2];c[e+20>>2]=c[a+20>>2];c[e+24>>2]=c[a+24>>2];c[e+28>>2]=c[a+28>>2];s=0;b=c[d>>2]|0;while(1){w=c[e+16>>2]|0;m=Ah(w,6)|0;m=(Ah(w,11)|0)^m;m=m^(Ah(w,25)|0);k=c[e+20>>2]|0;j=c[e+24>>2]|0;m=b+m+(c[32984+(s<<2)>>2]|0)+((j^k)&w^j)+(c[e+28>>2]|0)|0;l=m+(c[e+12>>2]|0)|0;c[e+12>>2]=l;i=c[e>>2]|0;v=Ah(i,2)|0;v=(Ah(i,13)|0)^v;v=v^(Ah(i,22)|0);h=c[e+4>>2]|0;g=c[e+8>>2]|0;c[e+28>>2]=m+v+((g|h)&i|g&h);u=Ah(l,6)|0;u=(Ah(l,11)|0)^u;u=u^(Ah(l,25)|0);q=s|1;j=(c[d+(q<<2)>>2]|0)+u+(c[32984+(q<<2)>>2]|0)+((k^w)&l^k)+j|0;c[e+8>>2]=j+g;u=Ah(m+v+((g|h)&i|g&h)|0,2)|0;u=(Ah(m+v+((g|h)&i|g&h)|0,13)|0)^u;u=j+(u^(Ah(m+v+((g|h)&i|g&h)|0,22)|0))+((h|i)&m+v+((g|h)&i|g&h)|h&i)|0;c[e+24>>2]=u;f=Ah(j+g|0,6)|0;f=(Ah(j+g|0,11)|0)^f;f=f^(Ah(j+g|0,25)|0);r=s|2;k=(c[d+(r<<2)>>2]|0)+f+(c[32984+(r<<2)>>2]|0)+((w^l)&j+g^w)+k|0;c[e+4>>2]=k+h;w=Ah(u,2)|0;w=(Ah(u,13)|0)^w;w=k+(w^(Ah(u,22)|0))+((i|m+v+((g|h)&i|g&h))&u|i&m+v+((g|h)&i|g&h))|0;c[e+20>>2]=w;f=Ah(k+h|0,6)|0;f=(Ah(k+h|0,11)|0)^f;f=f^(Ah(k+h|0,25)|0);b=s|3;l=(c[d+(b<<2)>>2]|0)+f+(c[32984+(b<<2)>>2]|0)+((l^j+g)&k+h^l)+(c[e+16>>2]|0)|0;c[e>>2]=l+i;f=Ah(w,2)|0;f=(Ah(w,13)|0)^f;v=l+(f^(Ah(w,22)|0))+((m+v+((g|h)&i|g&h)|u)&w|m+v+((g|h)&i|g&h)&u)|0;c[e+16>>2]=v;m=Ah(l+i|0,6)|0;m=(Ah(l+i|0,11)|0)^m;m=m^(Ah(l+i|0,25)|0);f=s|4;g=(c[d+(f<<2)>>2]|0)+m+(c[32984+(f<<2)>>2]|0)+((j+g^k+h)&l+i^j+g)+(c[e+12>>2]|0)|0;j=g+(c[e+28>>2]|0)|0;c[e+28>>2]=j;m=Ah(v,2)|0;m=(Ah(v,13)|0)^m;u=g+(m^(Ah(v,22)|0))+((u|w)&v|u&w)|0;c[e+12>>2]=u;m=Ah(j,6)|0;m=(Ah(j,11)|0)^m;m=m^(Ah(j,25)|0);g=s|5;h=(c[d+(g<<2)>>2]|0)+m+(c[32984+(g<<2)>>2]|0)+((k+h^l+i)&j^k+h)+(c[e+8>>2]|0)|0;k=h+(c[e+24>>2]|0)|0;c[e+24>>2]=k;m=Ah(u,2)|0;m=(Ah(u,13)|0)^m;w=h+(m^(Ah(u,22)|0))+((w|v)&u|w&v)|0;c[e+8>>2]=w;m=Ah(k,6)|0;m=(Ah(k,11)|0)^m;m=m^(Ah(k,25)|0);h=s|6;i=(c[d+(h<<2)>>2]|0)+m+(c[32984+(h<<2)>>2]|0)+((l+i^j)&k^l+i)+(c[e+4>>2]|0)|0;l=i+(c[e+20>>2]|0)|0;c[e+20>>2]=l;m=Ah(w,2)|0;m=(Ah(w,13)|0)^m;v=i+(m^(Ah(w,22)|0))+((v|u)&w|v&u)|0;c[e+4>>2]=v;m=Ah(l,6)|0;m=(Ah(l,11)|0)^m;m=m^(Ah(l,25)|0);i=s|7;j=(c[d+(i<<2)>>2]|0)+m+(c[32984+(i<<2)>>2]|0)+((j^k)&l^j)+(c[e>>2]|0)|0;m=j+(c[e+16>>2]|0)|0;c[e+16>>2]=m;n=Ah(v,2)|0;n=(Ah(v,13)|0)^n;u=j+(n^(Ah(v,22)|0))+((u|w)&v|u&w)|0;c[e>>2]=u;n=Ah(m,6)|0;n=(Ah(m,11)|0)^n;n=n^(Ah(m,25)|0);j=s|8;k=(c[d+(j<<2)>>2]|0)+n+(c[32984+(j<<2)>>2]|0)+((k^l)&m^k)+(c[e+28>>2]|0)|0;n=k+(c[e+12>>2]|0)|0;c[e+12>>2]=n;o=Ah(u,2)|0;o=(Ah(u,13)|0)^o;w=k+(o^(Ah(u,22)|0))+((w|v)&u|w&v)|0;c[e+28>>2]=w;o=Ah(n,6)|0;o=(Ah(n,11)|0)^o;o=o^(Ah(n,25)|0);k=s|9;l=(c[d+(k<<2)>>2]|0)+o+(c[32984+(k<<2)>>2]|0)+((l^m)&n^l)+(c[e+24>>2]|0)|0;o=l+(c[e+8>>2]|0)|0;c[e+8>>2]=o;p=Ah(w,2)|0;p=(Ah(w,13)|0)^p;v=l+(p^(Ah(w,22)|0))+((v|u)&w|v&u)|0;c[e+24>>2]=v;p=Ah(o,6)|0;p=(Ah(o,11)|0)^p;p=p^(Ah(o,25)|0);l=s|10;m=(c[d+(l<<2)>>2]|0)+p+(c[32984+(l<<2)>>2]|0)+((m^n)&o^m)+(c[e+20>>2]|0)|0;p=m+(c[e+4>>2]|0)|0;c[e+4>>2]=p;t=Ah(v,2)|0;t=(Ah(v,13)|0)^t;u=m+(t^(Ah(v,22)|0))+((u|w)&v|u&w)|0;c[e+20>>2]=u;t=Ah(p,6)|0;t=(Ah(p,11)|0)^t;t=t^(Ah(p,25)|0);m=s|11;n=(c[d+(m<<2)>>2]|0)+t+(c[32984+(m<<2)>>2]|0)+((n^o)&p^n)+(c[e+16>>2]|0)|0;t=n+(c[e>>2]|0)|0;c[e>>2]=t;y=Ah(u,2)|0;y=(Ah(u,13)|0)^y;w=n+(y^(Ah(u,22)|0))+((w|v)&u|w&v)|0;c[e+16>>2]=w;y=Ah(t,6)|0;y=(Ah(t,11)|0)^y;y=y^(Ah(t,25)|0);n=s|12;o=(c[d+(n<<2)>>2]|0)+y+(c[32984+(n<<2)>>2]|0)+((o^p)&t^o)+(c[e+12>>2]|0)|0;y=o+(c[e+28>>2]|0)|0;c[e+28>>2]=y;z=Ah(w,2)|0;z=(Ah(w,13)|0)^z;v=o+(z^(Ah(w,22)|0))+((v|u)&w|v&u)|0;c[e+12>>2]=v;z=Ah(y,6)|0;z=(Ah(y,11)|0)^z;z=z^(Ah(y,25)|0);o=s|13;p=(c[d+(o<<2)>>2]|0)+z+(c[32984+(o<<2)>>2]|0)+((p^t)&y^p)+(c[e+8>>2]|0)|0;z=p+(c[e+24>>2]|0)|0;c[e+24>>2]=z;x=Ah(v,2)|0;x=(Ah(v,13)|0)^x;u=p+(x^(Ah(v,22)|0))+((u|w)&v|u&w)|0;c[e+8>>2]=u;x=Ah(z,6)|0;x=(Ah(z,11)|0)^x;x=x^(Ah(z,25)|0);p=s|14;t=(c[d+(p<<2)>>2]|0)+x+(c[32984+(p<<2)>>2]|0)+((t^y)&z^t)+(c[e+4>>2]|0)|0;x=t+(c[e+20>>2]|0)|0;c[e+20>>2]=x;A=Ah(u,2)|0;A=(Ah(u,13)|0)^A;w=t+(A^(Ah(u,22)|0))+((w|v)&u|w&v)|0;c[e+4>>2]=w;A=Ah(x,6)|0;A=(Ah(x,11)|0)^A;A=A^(Ah(x,25)|0);t=s|15;y=(c[d+(t<<2)>>2]|0)+A+(c[32984+(t<<2)>>2]|0)+((y^z)&x^y)+(c[e>>2]|0)|0;c[e+16>>2]=y+(c[e+16>>2]|0);x=Ah(w,2)|0;x=(Ah(w,13)|0)^x;c[e>>2]=y+(x^(Ah(w,22)|0))+((v|u)&w|v&u);if((s|0)==48){b=0;break}z=c[d+(p<<2)>>2]|0;y=Ah(z,17)|0;z=z>>>10^y^(Ah(z,19)|0);z=z+(c[d+(k<<2)>>2]|0)|0;y=c[d+(q<<2)>>2]|0;x=Ah(y,7)|0;x=y>>>3^x^(Ah(y,18)|0);x=z+(c[d+(s<<2)>>2]|0)+x|0;s=s+16|0;c[d+(s<<2)>>2]=x;z=c[d+(t<<2)>>2]|0;A=Ah(z,17)|0;z=z>>>10^A^(Ah(z,19)|0);z=z+(c[d+(q+9<<2)>>2]|0)|0;A=c[d+(q+1<<2)>>2]|0;w=Ah(A,7)|0;w=z+y+(A>>>3^w^(Ah(A,18)|0))|0;c[d+(q+16<<2)>>2]=w;y=Ah(x,17)|0;x=x>>>10^y^(Ah(x,19)|0);x=x+(c[d+(m<<2)>>2]|0)|0;y=c[d+(b<<2)>>2]|0;z=Ah(y,7)|0;z=x+A+(y>>>3^z^(Ah(y,18)|0))|0;c[d+(r+16<<2)>>2]=z;A=Ah(w,17)|0;w=w>>>10^A^(Ah(w,19)|0);w=w+(c[d+(b+9<<2)>>2]|0)|0;A=c[d+(b+1<<2)>>2]|0;x=Ah(A,7)|0;x=w+y+(A>>>3^x^(Ah(A,18)|0))|0;c[d+(b+16<<2)>>2]=x;b=Ah(z,17)|0;b=z>>>10^b^(Ah(z,19)|0);b=b+(c[d+(o<<2)>>2]|0)|0;z=c[d+(g<<2)>>2]|0;y=Ah(z,7)|0;y=b+A+(z>>>3^y^(Ah(z,18)|0))|0;c[d+(f+16<<2)>>2]=y;A=Ah(x,17)|0;x=x>>>10^A^(Ah(x,19)|0);x=x+(c[d+(g+9<<2)>>2]|0)|0;A=c[d+(g+1<<2)>>2]|0;b=Ah(A,7)|0;b=x+z+(A>>>3^b^(Ah(A,18)|0))|0;c[d+(g+16<<2)>>2]=b;z=Ah(y,17)|0;y=y>>>10^z^(Ah(y,19)|0);y=y+(c[d+(t<<2)>>2]|0)|0;z=c[d+(i<<2)>>2]|0;x=Ah(z,7)|0;x=y+A+(z>>>3^x^(Ah(z,18)|0))|0;c[d+(h+16<<2)>>2]=x;A=Ah(b,17)|0;b=b>>>10^A^(Ah(b,19)|0);b=b+(c[d+(i+9<<2)>>2]|0)|0;A=c[d+(i+1<<2)>>2]|0;y=Ah(A,7)|0;y=b+z+(A>>>3^y^(Ah(A,18)|0))|0;c[d+(i+16<<2)>>2]=y;z=Ah(x,17)|0;x=x>>>10^z^(Ah(x,19)|0);x=x+(c[d+(j+9<<2)>>2]|0)|0;z=c[d+(k<<2)>>2]|0;b=Ah(z,7)|0;b=x+A+(z>>>3^b^(Ah(z,18)|0))|0;c[d+(j+16<<2)>>2]=b;A=Ah(y,17)|0;y=y>>>10^A^(Ah(y,19)|0);y=y+(c[d+(k+9<<2)>>2]|0)|0;A=c[d+(k+1<<2)>>2]|0;x=Ah(A,7)|0;x=y+z+(A>>>3^x^(Ah(A,18)|0))|0;c[d+(k+16<<2)>>2]=x;z=Ah(b,17)|0;b=b>>>10^z^(Ah(b,19)|0);b=b+(c[d+(l+9<<2)>>2]|0)|0;z=c[d+(m<<2)>>2]|0;y=Ah(z,7)|0;y=b+A+(z>>>3^y^(Ah(z,18)|0))|0;c[d+(l+16<<2)>>2]=y;A=Ah(x,17)|0;x=x>>>10^A^(Ah(x,19)|0);x=x+(c[d+(m+9<<2)>>2]|0)|0;A=c[d+(m+1<<2)>>2]|0;b=Ah(A,7)|0;b=x+z+(A>>>3^b^(Ah(A,18)|0))|0;c[d+(m+16<<2)>>2]=b;z=Ah(y,17)|0;y=y>>>10^z^(Ah(y,19)|0);y=y+(c[d+(n+9<<2)>>2]|0)|0;z=c[d+(o<<2)>>2]|0;x=Ah(z,7)|0;x=y+A+(z>>>3^x^(Ah(z,18)|0))|0;c[d+(n+16<<2)>>2]=x;A=Ah(b,17)|0;b=b>>>10^A^(Ah(b,19)|0);b=b+(c[d+(o+9<<2)>>2]|0)|0;A=c[d+(o+1<<2)>>2]|0;y=Ah(A,7)|0;y=b+z+(A>>>3^y^(Ah(A,18)|0))|0;c[d+(o+16<<2)>>2]=y;z=Ah(x,17)|0;x=x>>>10^z^(Ah(x,19)|0);x=x+(c[d+(p+9<<2)>>2]|0)|0;z=c[d+(t<<2)>>2]|0;b=Ah(z,7)|0;c[d+(p+16<<2)>>2]=x+A+(z>>>3^b^(Ah(z,18)|0));b=Ah(y,17)|0;y=y>>>10^b^(Ah(y,19)|0);y=y+(c[d+(t+9<<2)>>2]|0)|0;b=c[d+(t+1<<2)>>2]|0;A=Ah(b,7)|0;c[d+(t+16<<2)>>2]=y+z+(b>>>3^A^(Ah(b,18)|0));if((s|0)>=64){b=0;break}}do{A=a+(b<<2)|0;c[A>>2]=(c[A>>2]|0)+(c[e+(b<<2)>>2]|0);b=b+1|0}while((b|0)!=8);return}function qa(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0,sa=0,ta=0,ua=0,va=0,wa=0,xa=0,ya=0,za=0,Aa=0,Ba=0,Ca=0,Da=0,Ea=0,Fa=0,Ga=0,Ha=0,Ia=0,Ja=0,Ka=0,La=0,Ma=0,Na=0,Oa=0,Pa=0,Qa=0,Ra=0,Sa=0,Ta=0,Ua=0,Va=0,Wa=0,Xa=0,Ya=0,Za=0,_a=0,$a=0,ab=0,bb=0,cb=0,db=0,eb=0;l=c[b>>2]|0;p=c[b+4>>2]|0;k=c[b+8>>2]|0;f=c[b+12>>2]|0;D=c[b+16>>2]|0;d=c[b+20>>2]|0;g=c[b+24>>2]|0;O=c[b+28>>2]|0;B=c[b+32>>2]|0;q=c[b+36>>2]|0;cb=af(l|0,((l|0)<0)<<31>>31|0,l|0,((l|0)<0)<<31>>31|0)|0;bb=z;o=((l<<1|0)<0)<<31>>31;Ia=af(l<<1|0,o|0,p|0,((p|0)<0)<<31>>31|0)|0;Ha=z;Wa=af(k|0,((k|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Va=z;Ua=af(f|0,((f|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Ta=z;Oa=af(D|0,((D|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Na=z;ya=af(d|0,((d|0)<0)<<31>>31|0,l<<1|0,o|0)|0;xa=z;ga=af(g|0,((g|0)<0)<<31>>31|0,l<<1|0,o|0)|0;fa=z;R=af(O|0,((O|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Q=z;F=af(B|0,((B|0)<0)<<31>>31|0,l<<1|0,o|0)|0;E=z;o=af(q|0,((q|0)<0)<<31>>31|0,l<<1|0,o|0)|0;l=z;n=((p<<1|0)<0)<<31>>31;ta=af(p<<1|0,n|0,p|0,((p|0)<0)<<31>>31|0)|0;ua=z;ba=af(p<<1|0,n|0,k|0,((k|0)<0)<<31>>31|0)|0;ca=z;P=((f<<1|0)<0)<<31>>31;Sa=af(f<<1|0,P|0,p<<1|0,n|0)|0;Ra=z;Ca=af(D|0,((D|0)<0)<<31>>31|0,p<<1|0,n|0)|0;Ba=z;ia=af(d<<1|0,((d<<1|0)<0)<<31>>31|0,p<<1|0,n|0)|0;ha=z;T=af(g|0,((g|0)<0)<<31>>31|0,p<<1|0,n|0)|0;S=z;H=af(O<<1|0,((O<<1|0)<0)<<31>>31|0,p<<1|0,n|0)|0;G=z;t=af(B|0,((B|0)<0)<<31>>31|0,p<<1|0,n|0)|0;s=z;b=((q*38|0)<0)<<31>>31;n=af(q*38|0,b|0,p<<1|0,n|0)|0;p=z;Qa=af(k|0,((k|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;Pa=z;Aa=af(k<<1|0,((k<<1|0)<0)<<31>>31|0,f|0,((f|0)<0)<<31>>31|0)|0;za=z;ka=af(D|0,((D|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;ja=z;X=af(d|0,((d|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;W=z;N=af(g|0,((g|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;M=z;v=af(O|0,((O|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;u=z;ea=((B*19|0)<0)<<31>>31;Ya=af(B*19|0,ea|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;Xa=z;k=af(q*38|0,b|0,k|0,((k|0)<0)<<31>>31|0)|0;j=z;ma=af(f<<1|0,P|0,f|0,((f|0)<0)<<31>>31|0)|0;la=z;V=af(f<<1|0,P|0,D|0,((D|0)<0)<<31>>31|0)|0;U=z;J=af(d<<1|0,((d<<1|0)<0)<<31>>31|0,f<<1|0,P|0)|0;I=z;A=af(g|0,((g|0)<0)<<31>>31|0,f<<1|0,P|0)|0;y=z;Ma=((O*38|0)<0)<<31>>31;_a=af(O*38|0,Ma|0,f<<1|0,P|0)|0;Za=z;Ea=af(B*19|0,ea|0,f<<1|0,P|0)|0;Da=z;P=af(q*38|0,b|0,f<<1|0,P|0)|0;f=z;L=af(D|0,((D|0)<0)<<31>>31|0,D|0,((D|0)<0)<<31>>31|0)|0;K=z;x=af(D<<1|0,((D<<1|0)<0)<<31>>31|0,d|0,((d|0)<0)<<31>>31|0)|0;w=z;ab=af(g*19|0,((g*19|0)<0)<<31>>31|0,D<<1|0,((D<<1|0)<0)<<31>>31|0)|0;$a=z;Ga=af(O*38|0,Ma|0,D|0,((D|0)<0)<<31>>31|0)|0;Fa=z;oa=af(B*19|0,ea|0,D<<1|0,((D<<1|0)<0)<<31>>31|0)|0;na=z;D=af(q*38|0,b|0,D|0,((D|0)<0)<<31>>31|0)|0;e=z;eb=af(d*38|0,((d*38|0)<0)<<31>>31|0,d|0,((d|0)<0)<<31>>31|0)|0;db=z;Ka=af(g*19|0,((g*19|0)<0)<<31>>31|0,d<<1|0,((d<<1|0)<0)<<31>>31|0)|0;Ja=z;qa=af(O*38|0,Ma|0,d<<1|0,((d<<1|0)<0)<<31>>31|0)|0;pa=z;_=af(B*19|0,ea|0,d<<1|0,((d<<1|0)<0)<<31>>31|0)|0;Z=z;d=af(q*38|0,b|0,d<<1|0,((d<<1|0)<0)<<31>>31|0)|0;C=z;sa=af(g*19|0,((g*19|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;ra=z;aa=af(O*38|0,Ma|0,g|0,((g|0)<0)<<31>>31|0)|0;$=z;m=af(B*19|0,ea|0,g<<1|0,((g<<1|0)<0)<<31>>31|0)|0;r=z;g=af(q*38|0,b|0,g|0,((g|0)<0)<<31>>31|0)|0;Y=z;Ma=af(O*38|0,Ma|0,O|0,((O|0)<0)<<31>>31|0)|0;La=z;wa=af(B*19|0,ea|0,O<<1|0,((O<<1|0)<0)<<31>>31|0)|0;va=z;O=af(q*38|0,b|0,O<<1|0,((O<<1|0)<0)<<31>>31|0)|0;i=z;ea=af(B*19|0,ea|0,B|0,((B|0)<0)<<31>>31|0)|0;da=z;B=af(q*38|0,b|0,B|0,((B|0)<0)<<31>>31|0)|0;h=z;q=af(q*38|0,b|0,q|0,((q|0)<0)<<31>>31|0)|0;b=z;bb=fg(eb|0,db|0,cb|0,bb|0)|0;$a=fg(bb|0,z|0,ab|0,$a|0)|0;Za=fg($a|0,z|0,_a|0,Za|0)|0;Xa=fg(Za|0,z|0,Ya|0,Xa|0)|0;p=fg(Xa|0,z|0,n|0,p|0)|0;n=z;ua=fg(Wa|0,Va|0,ta|0,ua|0)|0;ta=z;ca=fg(Ua|0,Ta|0,ba|0,ca|0)|0;ba=z;Pa=fg(Sa|0,Ra|0,Qa|0,Pa|0)|0;Na=fg(Pa|0,z|0,Oa|0,Na|0)|0;La=fg(Na|0,z|0,Ma|0,La|0)|0;r=fg(La|0,z|0,m|0,r|0)|0;C=fg(r|0,z|0,d|0,C|0)|0;d=z;r=fg(p|0,n|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;m=z;Ha=fg(Ka|0,Ja|0,Ia|0,Ha|0)|0;Fa=fg(Ha|0,z|0,Ga|0,Fa|0)|0;Da=fg(Fa|0,z|0,Ea|0,Da|0)|0;j=fg(Da|0,z|0,k|0,j|0)|0;j=fg(j|0,z|0,r|0,m|0)|0;k=z;m=vf(r|0,m|0,26)|0;m=cg(p|0,n|0,m|0,z|0)|0;n=z;p=fg(C|0,d|0,33554432,0)|0;p=Xe(p|0,z|0,26)|0;r=z;za=fg(Ca|0,Ba|0,Aa|0,za|0)|0;xa=fg(za|0,z|0,ya|0,xa|0)|0;va=fg(xa|0,z|0,wa|0,va|0)|0;Y=fg(va|0,z|0,g|0,Y|0)|0;Y=fg(Y|0,z|0,p|0,r|0)|0;g=z;r=vf(p|0,r|0,26)|0;r=cg(C|0,d|0,r|0,z|0)|0;d=z;C=fg(j|0,k|0,16777216,0)|0;C=Xe(C|0,z|0,25)|0;p=z;ra=fg(ua|0,ta|0,sa|0,ra|0)|0;pa=fg(ra|0,z|0,qa|0,pa|0)|0;na=fg(pa|0,z|0,oa|0,na|0)|0;f=fg(na|0,z|0,P|0,f|0)|0;f=fg(f|0,z|0,C|0,p|0)|0;P=z;p=vf(C|0,p|0,25)|0;p=cg(j|0,k|0,p|0,z|0)|0;k=z;j=fg(Y|0,g|0,16777216,0)|0;j=Xe(j|0,z|0,25)|0;C=z;ja=fg(ma|0,la|0,ka|0,ja|0)|0;ha=fg(ja|0,z|0,ia|0,ha|0)|0;fa=fg(ha|0,z|0,ga|0,fa|0)|0;da=fg(fa|0,z|0,ea|0,da|0)|0;i=fg(da|0,z|0,O|0,i|0)|0;i=fg(i|0,z|0,j|0,C|0)|0;O=z;C=vf(j|0,C|0,25)|0;C=cg(Y|0,g|0,C|0,z|0)|0;g=z;Y=fg(f|0,P|0,33554432,0)|0;Y=Xe(Y|0,z|0,26)|0;j=z;$=fg(ca|0,ba|0,aa|0,$|0)|0;Z=fg($|0,z|0,_|0,Z|0)|0;e=fg(Z|0,z|0,D|0,e|0)|0;e=fg(e|0,z|0,Y|0,j|0)|0;D=z;j=vf(Y|0,j|0,26)|0;j=cg(f|0,P|0,j|0,z|0)|0;P=fg(i|0,O|0,33554432,0)|0;P=Xe(P|0,z|0,26)|0;f=z;U=fg(X|0,W|0,V|0,U|0)|0;S=fg(U|0,z|0,T|0,S|0)|0;Q=fg(S|0,z|0,R|0,Q|0)|0;h=fg(Q|0,z|0,B|0,h|0)|0;h=fg(h|0,z|0,P|0,f|0)|0;B=z;f=vf(P|0,f|0,26)|0;f=cg(i|0,O|0,f|0,z|0)|0;O=fg(e|0,D|0,16777216,0)|0;O=Xe(O|0,z|0,25)|0;i=z;d=fg(O|0,i|0,r|0,d|0)|0;r=z;i=vf(O|0,i|0,25)|0;i=cg(e|0,D|0,i|0,z|0)|0;D=fg(h|0,B|0,16777216,0)|0;D=Xe(D|0,z|0,25)|0;e=z;K=fg(N|0,M|0,L|0,K|0)|0;I=fg(K|0,z|0,J|0,I|0)|0;G=fg(I|0,z|0,H|0,G|0)|0;E=fg(G|0,z|0,F|0,E|0)|0;b=fg(E|0,z|0,q|0,b|0)|0;b=fg(b|0,z|0,D|0,e|0)|0;q=z;e=vf(D|0,e|0,25)|0;e=cg(h|0,B|0,e|0,z|0)|0;B=fg(d|0,r|0,33554432,0)|0;B=Xe(B|0,z|0,26)|0;h=z;g=fg(C|0,g|0,B|0,h|0)|0;h=vf(B|0,h|0,26)|0;h=cg(d|0,r|0,h|0,z|0)|0;r=fg(b|0,q|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;d=z;w=fg(A|0,y|0,x|0,w|0)|0;u=fg(w|0,z|0,v|0,u|0)|0;s=fg(u|0,z|0,t|0,s|0)|0;l=fg(s|0,z|0,o|0,l|0)|0;l=fg(l|0,z|0,r|0,d|0)|0;o=z;d=vf(r|0,d|0,26)|0;d=cg(b|0,q|0,d|0,z|0)|0;q=fg(l|0,o|0,16777216,0)|0;q=Xe(q|0,z|0,25)|0;b=z;r=af(q|0,b|0,19,0)|0;n=fg(r|0,z|0,m|0,n|0)|0;m=z;b=vf(q|0,b|0,25)|0;b=cg(l|0,o|0,b|0,z|0)|0;o=fg(n|0,m|0,33554432,0)|0;o=Xe(o|0,z|0,26)|0;l=z;k=fg(p|0,k|0,o|0,l|0)|0;l=vf(o|0,l|0,26)|0;l=cg(n|0,m|0,l|0,z|0)|0;c[a>>2]=l;c[a+4>>2]=k;c[a+8>>2]=j;c[a+12>>2]=i;c[a+16>>2]=h;c[a+20>>2]=g;c[a+24>>2]=f;c[a+28>>2]=e;c[a+32>>2]=d;c[a+36>>2]=b;return}function ra(a){a=a|0;var b=0,d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0;if(!a)return;h=c[8854]|0;if((a+-8|0)>>>0<h>>>0)Z();b=c[a+-4>>2]|0;if((b&3|0)==1)Z();o=a+-8+(b&-8)|0;a:do if(!(b&1)){e=c[a+-8>>2]|0;if(!(b&3))return;k=a+-8+(0-e)|0;j=e+(b&-8)|0;if(k>>>0<h>>>0)Z();if((k|0)==(c[8855]|0)){a=c[o+4>>2]|0;if((a&3|0)!=3){r=k;f=j;m=k;break}c[8852]=j;c[o+4>>2]=a&-2;c[k+4>>2]=j|1;c[k+j>>2]=j;return}if(e>>>0<256){a=c[k+8>>2]|0;b=c[k+12>>2]|0;if((a|0)!=(35440+(e>>>3<<1<<2)|0)){if(a>>>0<h>>>0)Z();if((c[a+12>>2]|0)!=(k|0))Z()}if((b|0)==(a|0)){c[8850]=c[8850]&~(1<<(e>>>3));r=k;f=j;m=k;break}if((b|0)!=(35440+(e>>>3<<1<<2)|0)){if(b>>>0<h>>>0)Z();if((c[b+8>>2]|0)!=(k|0))Z();else d=b+8|0}else d=b+8|0;c[a+12>>2]=b;c[d>>2]=a;r=k;f=j;m=k;break}g=c[k+24>>2]|0;a=c[k+12>>2]|0;do if((a|0)==(k|0)){a=c[k+16+4>>2]|0;if(!a){a=c[k+16>>2]|0;if(!a){i=0;break}else e=k+16|0}else e=k+16+4|0;while(1){b=a+20|0;d=c[b>>2]|0;if(d|0){a=d;e=b;continue}b=a+16|0;d=c[b>>2]|0;if(!d)break;else{a=d;e=b}}if(e>>>0<h>>>0)Z();else{c[e>>2]=0;i=a;break}}else{b=c[k+8>>2]|0;if(b>>>0<h>>>0)Z();if((c[b+12>>2]|0)!=(k|0))Z();if((c[a+8>>2]|0)==(k|0)){c[b+12>>2]=a;c[a+8>>2]=b;i=a;break}else Z()}while(0);if(g){a=c[k+28>>2]|0;do if((k|0)==(c[35704+(a<<2)>>2]|0)){c[35704+(a<<2)>>2]=i;if(!i){c[8851]=c[8851]&~(1<<a);r=k;f=j;m=k;break a}}else if(g>>>0>=(c[8854]|0)>>>0){c[g+16+(((c[g+16>>2]|0)!=(k|0)&1)<<2)>>2]=i;if(!i){r=k;f=j;m=k;break a}else break}else Z();while(0);b=c[8854]|0;if(i>>>0<b>>>0)Z();c[i+24>>2]=g;a=c[k+16>>2]|0;do if(a|0)if(a>>>0<b>>>0)Z();else{c[i+16>>2]=a;c[a+24>>2]=i;break}while(0);a=c[k+16+4>>2]|0;if(a)if(a>>>0<(c[8854]|0)>>>0)Z();else{c[i+20>>2]=a;c[a+24>>2]=i;r=k;f=j;m=k;break}else{r=k;f=j;m=k}}else{r=k;f=j;m=k}}else{r=a+-8|0;f=b&-8;m=a+-8|0}while(0);if(m>>>0>=o>>>0)Z();d=c[o+4>>2]|0;if(!(d&1))Z();if(!(d&2)){a=c[8855]|0;if((o|0)==(c[8856]|0)){q=(c[8853]|0)+f|0;c[8853]=q;c[8856]=r;c[r+4>>2]=q|1;if((r|0)!=(a|0))return;c[8855]=0;c[8852]=0;return}if((o|0)==(a|0)){q=(c[8852]|0)+f|0;c[8852]=q;c[8855]=m;c[r+4>>2]=q|1;c[m+q>>2]=q;return}f=(d&-8)+f|0;b:do if(d>>>0>=256){g=c[o+24>>2]|0;a=c[o+12>>2]|0;do if((a|0)==(o|0)){a=c[o+16+4>>2]|0;if(!a){a=c[o+16>>2]|0;if(!a){n=0;break}else e=o+16|0}else e=o+16+4|0;while(1){b=a+20|0;d=c[b>>2]|0;if(d|0){a=d;e=b;continue}b=a+16|0;d=c[b>>2]|0;if(!d)break;else{a=d;e=b}}if(e>>>0<(c[8854]|0)>>>0)Z();else{c[e>>2]=0;n=a;break}}else{b=c[o+8>>2]|0;if(b>>>0<(c[8854]|0)>>>0)Z();if((c[b+12>>2]|0)!=(o|0))Z();if((c[a+8>>2]|0)==(o|0)){c[b+12>>2]=a;c[a+8>>2]=b;n=a;break}else Z()}while(0);if(g|0){a=c[o+28>>2]|0;do if((o|0)==(c[35704+(a<<2)>>2]|0)){c[35704+(a<<2)>>2]=n;if(!n){c[8851]=c[8851]&~(1<<a);break b}}else if(g>>>0>=(c[8854]|0)>>>0){c[g+16+(((c[g+16>>2]|0)!=(o|0)&1)<<2)>>2]=n;if(!n)break b;else break}else Z();while(0);b=c[8854]|0;if(n>>>0<b>>>0)Z();c[n+24>>2]=g;a=c[o+16>>2]|0;do if(a|0)if(a>>>0<b>>>0)Z();else{c[n+16>>2]=a;c[a+24>>2]=n;break}while(0);a=c[o+16+4>>2]|0;if(a|0)if(a>>>0<(c[8854]|0)>>>0)Z();else{c[n+20>>2]=a;c[a+24>>2]=n;break}}}else{a=c[o+8>>2]|0;b=c[o+12>>2]|0;if((a|0)!=(35440+(d>>>3<<1<<2)|0)){if(a>>>0<(c[8854]|0)>>>0)Z();if((c[a+12>>2]|0)!=(o|0))Z()}if((b|0)==(a|0)){c[8850]=c[8850]&~(1<<(d>>>3));break}if((b|0)!=(35440+(d>>>3<<1<<2)|0)){if(b>>>0<(c[8854]|0)>>>0)Z();if((c[b+8>>2]|0)!=(o|0))Z();else l=b+8|0}else l=b+8|0;c[a+12>>2]=b;c[l>>2]=a}while(0);c[r+4>>2]=f|1;c[m+f>>2]=f;if((r|0)==(c[8855]|0)){c[8852]=f;return}}else{c[o+4>>2]=d&-2;c[r+4>>2]=f|1;c[m+f>>2]=f}b=f>>>3;if(f>>>0<256){a=c[8850]|0;if(a&1<<b){a=c[35440+(b<<1<<2)+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{p=a;q=35440+(b<<1<<2)+8|0}}else{c[8850]=a|1<<b;p=35440+(b<<1<<2)|0;q=35440+(b<<1<<2)+8|0}c[q>>2]=r;c[p+12>>2]=r;c[r+8>>2]=p;c[r+12>>2]=35440+(b<<1<<2);return}a=f>>>8;if(a)if(f>>>0>16777215)a=31;else{q=a<<((a+1048320|0)>>>16&8)<<(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4);a=14-(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4|(a+1048320|0)>>>16&8|(q+245760|0)>>>16&2)+(q<<((q+245760|0)>>>16&2)>>>15)|0;a=f>>>(a+7|0)&1|a<<1}else a=0;e=35704+(a<<2)|0;c[r+28>>2]=a;c[r+20>>2]=0;c[r+16>>2]=0;b=c[8851]|0;d=1<<a;do if(b&d){b=f<<((a|0)==31?0:25-(a>>>1)|0);e=c[e>>2]|0;while(1){if((c[e+4>>2]&-8|0)==(f|0)){a=124;break}d=e+16+(b>>>31<<2)|0;a=c[d>>2]|0;if(!a){a=121;break}else{b=b<<1;e=a}}if((a|0)==121)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[d>>2]=r;c[r+24>>2]=e;c[r+12>>2]=r;c[r+8>>2]=r;break}else if((a|0)==124){a=e+8|0;b=c[a>>2]|0;q=c[8854]|0;if(b>>>0>=q>>>0&e>>>0>=q>>>0){c[b+12>>2]=r;c[a>>2]=r;c[r+8>>2]=b;c[r+12>>2]=e;c[r+24>>2]=0;break}else Z()}}else{c[8851]=b|d;c[e>>2]=r;c[r+24>>2]=e;c[r+12>>2]=r;c[r+8>>2]=r}while(0);r=(c[8858]|0)+-1|0;c[8858]=r;if(!r)a=35856;else return;while(1){a=c[a>>2]|0;if(!a)break;else a=a+8|0}c[8858]=-1;return}function sa(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0;d=c[a+4>>2]|0;a:do if(!(d&1)){l=c[a>>2]|0;if(!(d&3))return;j=c[8854]|0;if((a+(0-l)|0)>>>0<j>>>0)Z();if((a+(0-l)|0)==(c[8855]|0)){d=c[a+b+4>>2]|0;if((d&3|0)!=3){q=a+(0-l)|0;h=l+b|0;break}c[8852]=l+b;c[a+b+4>>2]=d&-2;c[a+(0-l)+4>>2]=l+b|1;c[a+(0-l)+(l+b)>>2]=l+b;return}if(l>>>0<256){d=c[a+(0-l)+8>>2]|0;e=c[a+(0-l)+12>>2]|0;if((d|0)!=(35440+(l>>>3<<1<<2)|0)){if(d>>>0<j>>>0)Z();if((c[d+12>>2]|0)!=(a+(0-l)|0))Z()}if((e|0)==(d|0)){c[8850]=c[8850]&~(1<<(l>>>3));q=a+(0-l)|0;h=l+b|0;break}if((e|0)!=(35440+(l>>>3<<1<<2)|0)){if(e>>>0<j>>>0)Z();if((c[e+8>>2]|0)!=(a+(0-l)|0))Z();else f=e+8|0}else f=e+8|0;c[d+12>>2]=e;c[f>>2]=d;q=a+(0-l)|0;h=l+b|0;break}i=c[a+(0-l)+24>>2]|0;d=c[a+(0-l)+12>>2]|0;do if((d|0)==(a+(0-l)|0)){e=a+(0-l)+16|0;d=c[e+4>>2]|0;if(!d){d=c[e>>2]|0;if(!d){k=0;break}}else e=e+4|0;while(1){f=d+20|0;g=c[f>>2]|0;if(g|0){d=g;e=f;continue}f=d+16|0;g=c[f>>2]|0;if(!g)break;else{d=g;e=f}}if(e>>>0<j>>>0)Z();else{c[e>>2]=0;k=d;break}}else{e=c[a+(0-l)+8>>2]|0;if(e>>>0<j>>>0)Z();if((c[e+12>>2]|0)!=(a+(0-l)|0))Z();if((c[d+8>>2]|0)==(a+(0-l)|0)){c[e+12>>2]=d;c[d+8>>2]=e;k=d;break}else Z()}while(0);if(i){d=c[a+(0-l)+28>>2]|0;do if((a+(0-l)|0)==(c[35704+(d<<2)>>2]|0)){c[35704+(d<<2)>>2]=k;if(!k){c[8851]=c[8851]&~(1<<d);q=a+(0-l)|0;h=l+b|0;break a}}else if(i>>>0>=(c[8854]|0)>>>0){c[i+16+(((c[i+16>>2]|0)!=(a+(0-l)|0)&1)<<2)>>2]=k;if(!k){q=a+(0-l)|0;h=l+b|0;break a}else break}else Z();while(0);e=c[8854]|0;if(k>>>0<e>>>0)Z();c[k+24>>2]=i;d=c[a+(0-l)+16>>2]|0;do if(d|0)if(d>>>0<e>>>0)Z();else{c[k+16>>2]=d;c[d+24>>2]=k;break}while(0);d=c[a+(0-l)+16+4>>2]|0;if(d)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[k+20>>2]=d;c[d+24>>2]=k;q=a+(0-l)|0;h=l+b|0;break}else{q=a+(0-l)|0;h=l+b|0}}else{q=a+(0-l)|0;h=l+b|0}}else{q=a;h=b}while(0);j=c[8854]|0;if((a+b|0)>>>0<j>>>0)Z();f=c[a+b+4>>2]|0;if(!(f&2)){d=c[8855]|0;if((a+b|0)==(c[8856]|0)){p=(c[8853]|0)+h|0;c[8853]=p;c[8856]=q;c[q+4>>2]=p|1;if((q|0)!=(d|0))return;c[8855]=0;c[8852]=0;return}if((a+b|0)==(d|0)){p=(c[8852]|0)+h|0;c[8852]=p;c[8855]=q;c[q+4>>2]=p|1;c[q+p>>2]=p;return}h=(f&-8)+h|0;b:do if(f>>>0>=256){i=c[a+b+24>>2]|0;d=c[a+b+12>>2]|0;do if((d|0)==(a+b|0)){d=c[a+b+16+4>>2]|0;if(!d){d=c[a+b+16>>2]|0;if(!d){n=0;break}else g=a+b+16|0}else g=a+b+16+4|0;while(1){e=d+20|0;f=c[e>>2]|0;if(f|0){d=f;g=e;continue}e=d+16|0;f=c[e>>2]|0;if(!f)break;else{d=f;g=e}}if(g>>>0<j>>>0)Z();else{c[g>>2]=0;n=d;break}}else{e=c[a+b+8>>2]|0;if(e>>>0<j>>>0)Z();if((c[e+12>>2]|0)!=(a+b|0))Z();if((c[d+8>>2]|0)==(a+b|0)){c[e+12>>2]=d;c[d+8>>2]=e;n=d;break}else Z()}while(0);if(i|0){d=c[a+b+28>>2]|0;do if((a+b|0)==(c[35704+(d<<2)>>2]|0)){c[35704+(d<<2)>>2]=n;if(!n){c[8851]=c[8851]&~(1<<d);break b}}else if(i>>>0>=(c[8854]|0)>>>0){c[i+16+(((c[i+16>>2]|0)!=(a+b|0)&1)<<2)>>2]=n;if(!n)break b;else break}else Z();while(0);e=c[8854]|0;if(n>>>0<e>>>0)Z();c[n+24>>2]=i;d=c[a+b+16>>2]|0;do if(d|0)if(d>>>0<e>>>0)Z();else{c[n+16>>2]=d;c[d+24>>2]=n;break}while(0);d=c[a+b+16+4>>2]|0;if(d|0)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[n+20>>2]=d;c[d+24>>2]=n;break}}}else{d=c[a+b+8>>2]|0;e=c[a+b+12>>2]|0;if((d|0)!=(35440+(f>>>3<<1<<2)|0)){if(d>>>0<j>>>0)Z();if((c[d+12>>2]|0)!=(a+b|0))Z()}if((e|0)==(d|0)){c[8850]=c[8850]&~(1<<(f>>>3));break}if((e|0)!=(35440+(f>>>3<<1<<2)|0)){if(e>>>0<j>>>0)Z();if((c[e+8>>2]|0)!=(a+b|0))Z();else m=e+8|0}else m=e+8|0;c[d+12>>2]=e;c[m>>2]=d}while(0);c[q+4>>2]=h|1;c[q+h>>2]=h;if((q|0)==(c[8855]|0)){c[8852]=h;return}}else{c[a+b+4>>2]=f&-2;c[q+4>>2]=h|1;c[q+h>>2]=h}e=h>>>3;if(h>>>0<256){d=c[8850]|0;if(d&1<<e){d=c[35440+(e<<1<<2)+8>>2]|0;if(d>>>0<(c[8854]|0)>>>0)Z();else{o=d;p=35440+(e<<1<<2)+8|0}}else{c[8850]=d|1<<e;o=35440+(e<<1<<2)|0;p=35440+(e<<1<<2)+8|0}c[p>>2]=q;c[o+12>>2]=q;c[q+8>>2]=o;c[q+12>>2]=35440+(e<<1<<2);return}d=h>>>8;if(d)if(h>>>0>16777215)d=31;else{p=d<<((d+1048320|0)>>>16&8)<<(((d<<((d+1048320|0)>>>16&8))+520192|0)>>>16&4);d=14-(((d<<((d+1048320|0)>>>16&8))+520192|0)>>>16&4|(d+1048320|0)>>>16&8|(p+245760|0)>>>16&2)+(p<<((p+245760|0)>>>16&2)>>>15)|0;d=h>>>(d+7|0)&1|d<<1}else d=0;g=35704+(d<<2)|0;c[q+28>>2]=d;c[q+20>>2]=0;c[q+16>>2]=0;e=c[8851]|0;f=1<<d;if(!(e&f)){c[8851]=e|f;c[g>>2]=q;c[q+24>>2]=g;c[q+12>>2]=q;c[q+8>>2]=q;return}e=h<<((d|0)==31?0:25-(d>>>1)|0);g=c[g>>2]|0;while(1){if((c[g+4>>2]&-8|0)==(h|0)){d=121;break}f=g+16+(e>>>31<<2)|0;d=c[f>>2]|0;if(!d){d=118;break}else{e=e<<1;g=d}}if((d|0)==118){if(f>>>0<(c[8854]|0)>>>0)Z();c[f>>2]=q;c[q+24>>2]=g;c[q+12>>2]=q;c[q+8>>2]=q;return}else if((d|0)==121){d=g+8|0;e=c[d>>2]|0;p=c[8854]|0;if(!(e>>>0>=p>>>0&g>>>0>=p>>>0))Z();c[e+12>>2]=q;c[d>>2]=q;c[q+8>>2]=e;c[q+12>>2]=g;c[q+24>>2]=0;return}}function ta(a,b,c,e,f){a=a|0;b=b|0;c=c|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0;m=Te(f)|0;o=z;g=Te(f+8|0)|0;h=z;e=vf(c|0,e|0,56)|0;f=z;if((b+c+(0-(c&7))|0)==(b|0)){q=g^2037671283;j=h^1952801890;n=m^1886610805;k=o^1936682341;i=g^1852075907;r=h^1685025377;h=m^1852142177;g=o^1819895653}else{s=b;q=g^2037671283;j=h^1952801890;n=m^1886610805;l=o^1936682341;k=g^1852075907;i=h^1685025377;h=m^1852142177;g=o^1819895653;while(1){p=Te(s)|0;t=z;v=p^q;j=t^j;l=fg(n|0,l|0,k|0,i|0)|0;r=z;n=_e(k,i,13)|0;k=z^r;r=_e(l,r,32)|0;q=z;m=fg(v|0,j|0,h|0,g|0)|0;o=z;j=_e(v,j,16)|0;i=z^o;q=fg(j^m|0,i|0,r|0,q|0)|0;r=z;i=_e(j^m,i,21)|0;j=r^z;o=fg(m|0,o|0,n^l|0,k|0)|0;m=z;k=_e(n^l,k,17)|0;g=z^m;m=_e(o,m,32)|0;h=z;r=fg(k^o|0,g|0,q|0,r|0)|0;l=z;g=_e(k^o,g,13)|0;o=z^l;l=_e(r,l,32)|0;k=z;h=fg(m|0,h|0,q^i|0,j|0)|0;m=z;j=_e(q^i,j,16)|0;i=z^m;k=fg(j^h|0,i|0,l|0,k|0)|0;l=z;i=_e(j^h,i,21)|0;j=l^z;m=fg(g^r|0,o|0,h|0,m|0)|0;h=z;o=_e(g^r,o,17)|0;r=z^h;h=_e(m,h,32)|0;g=z;s=s+8|0;if((s|0)==(b+c+(0-(c&7))|0)){b=b+c+(0-(c&7))|0;q=k^i;n=k^p;k=l^t;i=o^m;break}else{q=k^i;n=k^p;l=l^t;k=o^m;i=r}}}switch(c&7){case 7:{e=vf(d[b+6>>0]|0|0,0,48)|0|e;f=z|f;u=5;break}case 6:{u=5;break}case 5:{u=6;break}case 4:{u=7;break}case 3:{u=8;break}case 2:{u=9;break}case 1:{u=10;break}default:{}}if((u|0)==5){v=vf(d[b+5>>0]|0|0,0,40)|0;f=z|f;e=v|e;u=6}if((u|0)==6){f=d[b+4>>0]|0|f;u=7}if((u|0)==7){v=vf(d[b+3>>0]|0|0,0,24)|0;e=v|e;f=z|f;u=8}if((u|0)==8){v=vf(d[b+2>>0]|0|0,0,16)|0;e=v|e;f=z|f;u=9}if((u|0)==9){v=vf(d[b+1>>0]|0|0,0,8)|0;e=v|e;f=z|f;u=10}if((u|0)==10)e=d[b>>0]|0|e;t=e^q;c=f^j;b=fg(n|0,k|0,i|0,r|0)|0;v=z;u=_e(i,r,13)|0;o=z^v;v=_e(b,v,32)|0;q=z;s=fg(t|0,c|0,h|0,g|0)|0;p=z;r=_e(t,c,16)|0;c=z^p;q=fg(r^s|0,c|0,v|0,q|0)|0;v=z;c=_e(r^s,c,21)|0;r=v^z;p=fg(s|0,p|0,u^b|0,o|0)|0;s=z;o=_e(u^b,o,17)|0;b=z^s;s=_e(p,s,32)|0;u=z;v=fg(o^p|0,b|0,q|0,v|0)|0;t=z;b=_e(o^p,b,13)|0;p=z^t;t=_e(v,t,32)|0;o=z;u=fg(s|0,u|0,q^c|0,r|0)|0;s=z;r=_e(q^c,r,16)|0;c=z^s;o=fg(r^u|0,c|0,t|0,o|0)|0;t=z;c=_e(r^u,c,21)|0;r=t^z;s=fg(b^v|0,p|0,u|0,s|0)|0;u=z;p=_e(b^v,p,17)|0;v=z^u;u=_e(s,u,32)|0;b=z;t=fg(o^e|0,t^f|0,p^s|0,v|0)|0;q=z;v=_e(p^s,v,13)|0;s=z^q;q=_e(t,q,32)|0;p=z;b=fg(u^238|0,b|0,o^c|0,r|0)|0;u=z;r=_e(o^c,r,16)|0;c=z^u;p=fg(r^b|0,c|0,q|0,p|0)|0;q=z;c=_e(r^b,c,21)|0;r=q^z;u=fg(b|0,u|0,v^t|0,s|0)|0;b=z;s=_e(v^t,s,17)|0;t=z^b;b=_e(u,b,32)|0;v=z;q=fg(s^u|0,t|0,p|0,q|0)|0;o=z;t=_e(s^u,t,13)|0;u=z^o;o=_e(q,o,32)|0;s=z;v=fg(b|0,v|0,p^c|0,r|0)|0;b=z;r=_e(p^c,r,16)|0;c=z^b;s=fg(r^v|0,c|0,o|0,s|0)|0;o=z;c=_e(r^v,c,21)|0;r=o^z;b=fg(t^q|0,u|0,v|0,b|0)|0;v=z;u=_e(t^q,u,17)|0;q=z^v;v=_e(b,v,32)|0;t=z;o=fg(u^b|0,q|0,s|0,o|0)|0;p=z;q=_e(u^b,q,13)|0;b=z^p;p=_e(o,p,32)|0;u=z;t=fg(v|0,t|0,s^c|0,r|0)|0;v=z;r=_e(s^c,r,16)|0;c=z^v;u=fg(r^t|0,c|0,p|0,u|0)|0;p=z;c=_e(r^t,c,21)|0;r=p^z;v=fg(q^o|0,b|0,t|0,v|0)|0;t=z;b=_e(q^o,b,17)|0;o=z^t;t=_e(v,t,32)|0;q=z;p=fg(b^v|0,o|0,u|0,p|0)|0;s=z;o=_e(b^v,o,13)|0;v=z^s;s=_e(p,s,32)|0;b=z;q=fg(t|0,q|0,u^c|0,r|0)|0;t=z;r=_e(u^c,r,16)|0;c=z^t;b=fg(r^q|0,c|0,s|0,b|0)|0;s=z;c=_e(r^q,c,21)|0;r=s^z;t=fg(o^p|0,v|0,q|0,t|0)|0;q=z;v=_e(o^p,v,17)|0;p=z^q;q=_e(t,q,32)|0;o=z;re(a,v^t^b^q^(b^c),p^s^o^r);s=fg(v^t^221|0,p|0,b|0,s|0)|0;u=z;p=_e(v^t^221,p,13)|0;t=z^u;u=_e(s,u,32)|0;v=z;o=fg(q|0,o|0,b^c|0,r|0)|0;q=z;r=_e(b^c,r,16)|0;c=z^q;v=fg(r^o|0,c|0,u|0,v|0)|0;u=z;c=_e(r^o,c,21)|0;r=u^z;q=fg(p^s|0,t|0,o|0,q|0)|0;o=z;t=_e(p^s,t,17)|0;s=z^o;o=_e(q,o,32)|0;p=z;u=fg(t^q|0,s|0,v|0,u|0)|0;b=z;s=_e(t^q,s,13)|0;q=z^b;b=_e(u,b,32)|0;t=z;p=fg(o|0,p|0,v^c|0,r|0)|0;o=z;r=_e(v^c,r,16)|0;c=z^o;t=fg(r^p|0,c|0,b|0,t|0)|0;b=z;c=_e(r^p,c,21)|0;r=b^z;o=fg(s^u|0,q|0,p|0,o|0)|0;p=z;q=_e(s^u,q,17)|0;u=z^p;p=_e(o,p,32)|0;s=z;b=fg(q^o|0,u|0,t|0,b|0)|0;v=z;u=_e(q^o,u,13)|0;o=z^v;v=_e(b,v,32)|0;q=z;s=fg(p|0,s|0,t^c|0,r|0)|0;p=z;r=_e(t^c,r,16)|0;c=z^p;q=fg(r^s|0,c|0,v|0,q|0)|0;v=z;c=_e(r^s,c,21)|0;r=v^z;p=fg(u^b|0,o|0,s|0,p|0)|0;s=z;o=_e(u^b,o,17)|0;b=z^s;s=_e(p,s,32)|0;u=z;v=fg(o^p|0,b|0,q|0,v|0)|0;t=z;b=_e(o^p,b,13)|0;t=z^t;u=fg(s|0,u|0,q^c|0,r|0)|0;s=z;r=_e(q^c,r,16)|0;r=_e(r^u,z^s,21)|0;c=z;s=fg(b^v|0,t|0,u|0,s|0)|0;u=z;t=_e(b^v,t,17)|0;v=z;b=_e(s,u,32)|0;re(a+8|0,r^s^t^b,c^u^v^z);return 0}function ua(a,b,c,e,f){a=a|0;b=b|0;c=c|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0;m=Te(f)|0;o=z;g=Te(f+8|0)|0;h=z;e=vf(c|0,e|0,56)|0;f=z;if((b+c+(0-(c&7))|0)==(b|0)){q=g^2037671283;j=h^1952801890;n=m^1886610805;k=o^1936682341;i=g^1852075885;r=h^1685025377;h=m^1852142177;g=o^1819895653}else{s=b;q=g^2037671283;j=h^1952801890;n=m^1886610805;l=o^1936682341;k=g^1852075885;i=h^1685025377;h=m^1852142177;g=o^1819895653;while(1){p=Te(s)|0;t=z;v=p^q;j=t^j;l=fg(n|0,l|0,k|0,i|0)|0;r=z;n=_e(k,i,13)|0;k=z^r;r=_e(l,r,32)|0;q=z;m=fg(v|0,j|0,h|0,g|0)|0;o=z;j=_e(v,j,16)|0;i=z^o;q=fg(j^m|0,i|0,r|0,q|0)|0;r=z;i=_e(j^m,i,21)|0;j=r^z;o=fg(m|0,o|0,n^l|0,k|0)|0;m=z;k=_e(n^l,k,17)|0;g=z^m;m=_e(o,m,32)|0;h=z;r=fg(k^o|0,g|0,q|0,r|0)|0;l=z;g=_e(k^o,g,13)|0;o=z^l;l=_e(r,l,32)|0;k=z;h=fg(m|0,h|0,q^i|0,j|0)|0;m=z;j=_e(q^i,j,16)|0;i=z^m;k=fg(j^h|0,i|0,l|0,k|0)|0;l=z;i=_e(j^h,i,21)|0;j=l^z;m=fg(g^r|0,o|0,h|0,m|0)|0;h=z;o=_e(g^r,o,17)|0;r=z^h;h=_e(m,h,32)|0;g=z;s=s+8|0;if((s|0)==(b+c+(0-(c&7))|0)){b=b+c+(0-(c&7))|0;q=k^i;n=k^p;k=l^t;i=o^m;break}else{q=k^i;n=k^p;l=l^t;k=o^m;i=r}}}switch(c&7){case 7:{e=vf(d[b+6>>0]|0|0,0,48)|0|e;f=z|f;u=5;break}case 6:{u=5;break}case 5:{u=6;break}case 4:{u=7;break}case 3:{u=8;break}case 2:{u=9;break}case 1:{u=10;break}default:{}}if((u|0)==5){v=vf(d[b+5>>0]|0|0,0,40)|0;f=z|f;e=v|e;u=6}if((u|0)==6){f=d[b+4>>0]|0|f;u=7}if((u|0)==7){v=vf(d[b+3>>0]|0|0,0,24)|0;e=v|e;f=z|f;u=8}if((u|0)==8){v=vf(d[b+2>>0]|0|0,0,16)|0;e=v|e;f=z|f;u=9}if((u|0)==9){v=vf(d[b+1>>0]|0|0,0,8)|0;e=v|e;f=z|f;u=10}if((u|0)==10)e=d[b>>0]|0|e;s=e^q;c=f^j;o=fg(n|0,k|0,i|0,r|0)|0;p=z;q=_e(i,r,13)|0;b=z^p;p=_e(o,p,32)|0;u=z;t=fg(s|0,c|0,h|0,g|0)|0;v=z;r=_e(s,c,16)|0;c=z^v;u=fg(r^t|0,c|0,p|0,u|0)|0;p=z;c=_e(r^t,c,21)|0;r=p^z;v=fg(t|0,v|0,q^o|0,b|0)|0;t=z;b=_e(q^o,b,17)|0;o=z^t;t=_e(v,t,32)|0;q=z;p=fg(b^v|0,o|0,u|0,p|0)|0;s=z;o=_e(b^v,o,13)|0;v=z^s;s=_e(p,s,32)|0;b=z;q=fg(t|0,q|0,u^c|0,r|0)|0;t=z;r=_e(u^c,r,16)|0;c=z^t;b=fg(r^q|0,c|0,s|0,b|0)|0;s=z;c=_e(r^q,c,21)|0;r=s^z;t=fg(o^p|0,v|0,q|0,t|0)|0;q=z;v=_e(o^p,v,17)|0;p=z^q;q=_e(t,q,32)|0;o=z;s=fg(b^e|0,s^f|0,v^t|0,p|0)|0;u=z;p=_e(v^t,p,13)|0;t=z^u;u=_e(s,u,32)|0;v=z;o=fg(q^255|0,o|0,b^c|0,r|0)|0;q=z;r=_e(b^c,r,16)|0;c=z^q;v=fg(r^o|0,c|0,u|0,v|0)|0;u=z;c=_e(r^o,c,21)|0;r=u^z;q=fg(o|0,q|0,p^s|0,t|0)|0;o=z;t=_e(p^s,t,17)|0;s=z^o;o=_e(q,o,32)|0;p=z;u=fg(t^q|0,s|0,v|0,u|0)|0;b=z;s=_e(t^q,s,13)|0;q=z^b;b=_e(u,b,32)|0;t=z;p=fg(o|0,p|0,v^c|0,r|0)|0;o=z;r=_e(v^c,r,16)|0;c=z^o;t=fg(r^p|0,c|0,b|0,t|0)|0;b=z;c=_e(r^p,c,21)|0;r=b^z;o=fg(s^u|0,q|0,p|0,o|0)|0;p=z;q=_e(s^u,q,17)|0;u=z^p;p=_e(o,p,32)|0;s=z;b=fg(q^o|0,u|0,t|0,b|0)|0;v=z;u=_e(q^o,u,13)|0;o=z^v;v=_e(b,v,32)|0;q=z;s=fg(p|0,s|0,t^c|0,r|0)|0;p=z;r=_e(t^c,r,16)|0;c=z^p;q=fg(r^s|0,c|0,v|0,q|0)|0;v=z;c=_e(r^s,c,21)|0;r=v^z;p=fg(u^b|0,o|0,s|0,p|0)|0;s=z;o=_e(u^b,o,17)|0;b=z^s;s=_e(p,s,32)|0;u=z;v=fg(o^p|0,b|0,q|0,v|0)|0;t=z;b=_e(o^p,b,13)|0;t=z^t;u=fg(s|0,u|0,q^c|0,r|0)|0;s=z;r=_e(q^c,r,16)|0;r=_e(r^u,z^s,21)|0;c=z;s=fg(b^v|0,t|0,u|0,s|0)|0;u=z;t=_e(b^v,t,17)|0;v=z;b=_e(s,u,32)|0;re(a,r^s^t^b,c^u^v^z);return 0}function va(b,d,e,f,g){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0;T=l;S=l=l+63&-64;l=l+64|0;if(!((f|0)==0&(g|0)==0)){if(g>>>0>63|(g|0)==63&f>>>0>4294967232)Z();E=c[b>>2]|0;F=c[b+4>>2]|0;G=c[b+8>>2]|0;H=c[b+12>>2]|0;I=c[b+16>>2]|0;J=c[b+20>>2]|0;K=c[b+24>>2]|0;L=c[b+28>>2]|0;M=c[b+32>>2]|0;N=c[b+36>>2]|0;O=c[b+40>>2]|0;P=c[b+44>>2]|0;Q=c[b+56>>2]|0;R=c[b+60>>2]|0;h=0;B=c[b+52>>2]|0;y=c[b+48>>2]|0;C=g;D=f;while(1){A=C>>>0<0|(C|0)==0&D>>>0<64;if(A){g=S;f=g+64|0;do{a[g>>0]=0;g=g+1|0}while((g|0)<(f|0));g=0;do{a[S+g>>0]=a[d+g>>0]|0;g=g+1|0}while(0<C>>>0|0==(C|0)&g>>>0<D>>>0);h=e;d=S;e=S}g=E;f=F;i=G;j=H;k=I;m=J;n=K;o=L;p=M;q=N;r=O;s=R;t=Q;u=B;v=y;w=P;x=20;do{ma=g+k|0;ba=xh(ma^v,16)|0;aa=ba+p|0;na=xh(aa^k,12)|0;ba=xh(na+ma^ba,8)|0;Y=xh(ba+aa^na,7)|0;ia=f+m|0;W=xh(ia^u,16)|0;V=W+q|0;ja=xh(V^m,12)|0;W=xh(ja+ia^W,8)|0;oa=xh(W+V^ja,7)|0;da=i+n|0;X=xh(da^t,16)|0;ca=X+r|0;ea=xh(ca^n,12)|0;X=xh(ea+da^X,8)|0;ka=xh(X+ca^ea,7)|0;_=j+o|0;ga=xh(_^s,16)|0;U=ga+w|0;$=xh(U^o,12)|0;ga=xh($+_^ga,8)|0;fa=xh(ga+U^$,7)|0;la=xh(ga^oa+(na+ma),16)|0;ha=xh(la+(X+ca)^oa,12)|0;g=ha+(oa+(na+ma))|0;s=xh(g^la,8)|0;r=s+(la+(X+ca))|0;m=xh(r^ha,7)|0;ha=xh(ka+(ja+ia)^ba,16)|0;ca=xh(ha+(ga+U)^ka,12)|0;f=ca+(ka+(ja+ia))|0;v=xh(f^ha,8)|0;w=v+(ha+(ga+U))|0;n=xh(w^ca,7)|0;ca=xh(fa+(ea+da)^W,16)|0;U=xh(ca+(ba+aa)^fa,12)|0;i=U+(fa+(ea+da))|0;u=xh(i^ca,8)|0;p=u+(ca+(ba+aa))|0;o=xh(p^U,7)|0;X=xh($+_+Y^X,16)|0;U=xh(X+(W+V)^Y,12)|0;j=U+($+_+Y)|0;t=xh(j^X,8)|0;q=t+(X+(W+V))|0;k=xh(q^U,7)|0;x=x+-2|0}while((x|0)!=0);$=(Rg(d)|0)^g+E;aa=(Rg(d+4|0)|0)^f+F;ba=(Rg(d+8|0)|0)^i+G;ca=(Rg(d+12|0)|0)^j+H;da=(Rg(d+16|0)|0)^k+I;ea=(Rg(d+20|0)|0)^m+J;fa=(Rg(d+24|0)|0)^n+K;ga=(Rg(d+28|0)|0)^o+L;ha=(Rg(d+32|0)|0)^p+M;ia=(Rg(d+36|0)|0)^q+N;ja=(Rg(d+40|0)|0)^r+O;ka=(Rg(d+44|0)|0)^w+P;la=(Rg(d+48|0)|0)^v+y;ma=(Rg(d+52|0)|0)^u+B;na=(Rg(d+56|0)|0)^t+Q;oa=(Rg(d+60|0)|0)^s+R;f=y+1|0;g=((f|0)==0&1)+B|0;jg(e,$);jg(e+4|0,aa);jg(e+8|0,ba);jg(e+12|0,ca);jg(e+16|0,da);jg(e+20|0,ea);jg(e+24|0,fa);jg(e+28|0,ga);jg(e+32|0,ha);jg(e+36|0,ia);jg(e+40|0,ja);jg(e+44|0,ka);jg(e+48|0,la);jg(e+52|0,ma);jg(e+56|0,na);jg(e+60|0,oa);if(C>>>0<0|(C|0)==0&D>>>0<65)break;oa=fg(D|0,C|0,-64,-1)|0;d=d+64|0;e=e+64|0;B=g;y=f;C=z;D=oa}if(A?D|0:0){d=0;do{a[h+d>>0]=a[e+d>>0]|0;d=d+1|0}while((d|0)!=(D|0))}c[b+48>>2]=f;c[b+52>>2]=g}l=T;return}function wa(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0;s=a[b+80>>0]|0?0:16777216;t=c[b+4>>2]|0;o=c[b+8>>2]|0;p=c[b+12>>2]|0;q=c[b+16>>2]|0;k=c[b+20>>2]|0;j=c[b+24>>2]|0;i=c[b+28>>2]|0;h=c[b+32>>2]|0;g=c[b+36>>2]|0;if(f>>>0>0|(f|0)==0&e>>>0>15){r=c[b>>2]|0;m=e;while(1){y=((Rg(d)|0)&67108863)+k|0;A=((Rg(d+3|0)|0)>>>2&67108863)+j|0;x=((Rg(d+6|0)|0)>>>4&67108863)+i|0;w=((Rg(d+9|0)|0)>>>6)+h|0;k=((Rg(d+12|0)|0)>>>8|s)+g|0;g=af(y|0,0,r|0,0)|0;e=z;i=af(A|0,0,q*5|0,0)|0;e=fg(i|0,z|0,g|0,e|0)|0;g=z;i=af(x|0,0,p*5|0,0)|0;i=fg(e|0,g|0,i|0,z|0)|0;g=z;e=af(w|0,0,o*5|0,0)|0;e=fg(i|0,g|0,e|0,z|0)|0;g=z;i=af(k|0,0,t*5|0,0)|0;i=fg(e|0,g|0,i|0,z|0)|0;g=z;e=af(y|0,0,t|0,0)|0;l=z;v=af(A|0,0,r|0,0)|0;l=fg(v|0,z|0,e|0,l|0)|0;e=z;v=af(x|0,0,q*5|0,0)|0;v=fg(l|0,e|0,v|0,z|0)|0;e=z;l=af(w|0,0,p*5|0,0)|0;l=fg(v|0,e|0,l|0,z|0)|0;e=z;v=af(k|0,0,o*5|0,0)|0;v=fg(l|0,e|0,v|0,z|0)|0;e=z;l=af(y|0,0,o|0,0)|0;n=z;u=af(A|0,0,t|0,0)|0;n=fg(u|0,z|0,l|0,n|0)|0;l=z;u=af(x|0,0,r|0,0)|0;u=fg(n|0,l|0,u|0,z|0)|0;l=z;n=af(w|0,0,q*5|0,0)|0;n=fg(u|0,l|0,n|0,z|0)|0;l=z;u=af(k|0,0,p*5|0,0)|0;u=fg(n|0,l|0,u|0,z|0)|0;l=z;n=af(y|0,0,p|0,0)|0;h=z;j=af(A|0,0,o|0,0)|0;h=fg(j|0,z|0,n|0,h|0)|0;n=z;j=af(x|0,0,t|0,0)|0;j=fg(h|0,n|0,j|0,z|0)|0;n=z;h=af(w|0,0,r|0,0)|0;h=fg(j|0,n|0,h|0,z|0)|0;n=z;j=af(k|0,0,q*5|0,0)|0;j=fg(h|0,n|0,j|0,z|0)|0;n=z;h=af(y|0,0,q|0,0)|0;y=z;A=af(A|0,0,p|0,0)|0;y=fg(A|0,z|0,h|0,y|0)|0;h=z;x=af(x|0,0,o|0,0)|0;x=fg(y|0,h|0,x|0,z|0)|0;h=z;w=af(w|0,0,t|0,0)|0;w=fg(x|0,h|0,w|0,z|0)|0;h=z;k=af(k|0,0,r|0,0)|0;k=fg(w|0,h|0,k|0,z|0)|0;h=z;g=yf(i|0,g|0,26)|0;g=fg(v|0,e|0,g|0,0)|0;e=yf(g|0,z|0,26)|0;e=fg(u|0,l|0,e|0,0)|0;l=yf(e|0,z|0,26)|0;l=fg(j|0,n|0,l|0,0)|0;n=yf(l|0,z|0,26)|0;n=fg(k|0,h|0,n|0,0)|0;h=yf(n|0,z|0,26)|0;m=fg(m|0,f|0,-16,-1)|0;f=z;if(!(f>>>0>0|(f|0)==0&m>>>0>15)){k=(h*5|0)+i&67108863;j=(((h*5|0)+(i&67108863)|0)>>>26)+(g&67108863)|0;i=e&67108863;h=l&67108863;g=n&67108863;break}else{k=(h*5|0)+i&67108863;j=(((h*5|0)+(i&67108863)|0)>>>26)+(g&67108863)|0;i=e&67108863;h=l&67108863;g=n&67108863;d=d+16|0}}}c[b+20>>2]=k;c[b+24>>2]=j;c[b+28>>2]=i;c[b+32>>2]=h;c[b+36>>2]=g;return}function xa(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0;y=Qd(d)|0;k=z;x=df(a[d+4>>0]|0,a[d+5>>0]|0,a[d+6>>0]|0)|0;x=vf(x|0,z|0,6)|0;l=z;w=df(a[d+7>>0]|0,a[d+8>>0]|0,a[d+9>>0]|0)|0;w=vf(w|0,z|0,5)|0;i=z;t=df(a[d+10>>0]|0,a[d+11>>0]|0,a[d+12>>0]|0)|0;t=vf(t|0,z|0,3)|0;j=z;s=df(a[d+13>>0]|0,a[d+14>>0]|0,a[d+15>>0]|0)|0;s=vf(s|0,z|0,2)|0;g=z;f=Qd(d+16|0)|0;h=z;p=df(a[d+20>>0]|0,a[d+21>>0]|0,a[d+22>>0]|0)|0;p=vf(p|0,z|0,7)|0;e=z;v=df(a[d+23>>0]|0,a[d+24>>0]|0,a[d+25>>0]|0)|0;v=vf(v|0,z|0,5)|0;u=z;n=df(a[d+26>>0]|0,a[d+27>>0]|0,a[d+28>>0]|0)|0;n=vf(n|0,z|0,4)|0;o=z;r=df(a[d+29>>0]|0,a[d+30>>0]|0,a[d+31>>0]|0)|0;r=vf(r|0,z|0,2)|0;d=fg(r&33554428|0,0,16777216,0)|0;d=yf(d|0,z|0,25)|0;q=z;A=cg(0,0,d|0,q|0)|0;k=fg(A&19|0,0,y|0,k|0)|0;y=z;q=vf(d|0,q|0,25)|0;d=z;A=fg(x|0,l|0,16777216,0)|0;A=Xe(A|0,z|0,25)|0;C=z;i=fg(A|0,C|0,w|0,i|0)|0;w=z;C=vf(A|0,C|0,25)|0;C=cg(x|0,l|0,C|0,z|0)|0;l=z;x=fg(t|0,j|0,16777216,0)|0;x=Xe(x|0,z|0,25)|0;A=z;g=fg(x|0,A|0,s|0,g|0)|0;s=z;A=vf(x|0,A|0,25)|0;A=cg(t|0,j|0,A|0,z|0)|0;j=z;t=fg(f|0,h|0,16777216,0)|0;t=Xe(t|0,z|0,25)|0;x=z;e=fg(p|0,e|0,t|0,x|0)|0;p=z;x=vf(t|0,x|0,25)|0;x=cg(f|0,h|0,x|0,z|0)|0;h=z;f=fg(v|0,u|0,16777216,0)|0;f=Xe(f|0,z|0,25)|0;t=z;o=fg(f|0,t|0,n|0,o|0)|0;n=z;t=vf(f|0,t|0,25)|0;f=z;B=fg(k|0,y|0,33554432,0)|0;B=Xe(B|0,z|0,26)|0;m=z;l=fg(C|0,l|0,B|0,m|0)|0;m=vf(B|0,m|0,26)|0;m=cg(k|0,y|0,m|0,z|0)|0;y=fg(i|0,w|0,33554432,0)|0;y=Xe(y|0,z|0,26)|0;k=z;j=fg(A|0,j|0,y|0,k|0)|0;k=vf(y|0,k|0,26)|0;k=cg(i|0,w|0,k|0,z|0)|0;w=fg(g|0,s|0,33554432,0)|0;w=Xe(w|0,z|0,26)|0;i=z;h=fg(x|0,h|0,w|0,i|0)|0;i=vf(w|0,i|0,26)|0;i=cg(g|0,s|0,i|0,z|0)|0;s=fg(e|0,p|0,33554432,0)|0;s=Xe(s|0,z|0,26)|0;g=z;u=fg(s|0,g|0,v|0,u|0)|0;f=cg(u|0,z|0,t|0,f|0)|0;g=vf(s|0,g|0,26)|0;g=cg(e|0,p|0,g|0,z|0)|0;p=fg(o|0,n|0,33554432,0)|0;p=Xe(p|0,z|0,26)|0;e=z;r=fg(p|0,e|0,r&33554428|0,0)|0;d=cg(r|0,z|0,q|0,d|0)|0;e=vf(p|0,e|0,26)|0;e=cg(o|0,n|0,e|0,z|0)|0;c[b>>2]=m;c[b+4>>2]=l;c[b+8>>2]=k;c[b+12>>2]=j;c[b+16>>2]=i;c[b+20>>2]=h;c[b+24>>2]=g;c[b+28>>2]=f;c[b+32>>2]=e;c[b+36>>2]=d;return}function ya(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0;u=c[b>>2]|0;t=c[b+4>>2]|0;s=c[b+8>>2]|0;r=c[b+12>>2]|0;q=c[b+16>>2]|0;l=c[b+20>>2]|0;o=c[b+24>>2]|0;w=c[b+28>>2]|0;m=c[b+32>>2]|0;v=c[b+36>>2]|0;u=af(u|0,((u|0)<0)<<31>>31|0,121666,0)|0;j=z;t=af(t|0,((t|0)<0)<<31>>31|0,121666,0)|0;k=z;s=af(s|0,((s|0)<0)<<31>>31|0,121666,0)|0;h=z;r=af(r|0,((r|0)<0)<<31>>31|0,121666,0)|0;i=z;q=af(q|0,((q|0)<0)<<31>>31|0,121666,0)|0;f=z;l=af(l|0,((l|0)<0)<<31>>31|0,121666,0)|0;g=z;o=af(o|0,((o|0)<0)<<31>>31|0,121666,0)|0;d=z;w=af(w|0,((w|0)<0)<<31>>31|0,121666,0)|0;e=z;m=af(m|0,((m|0)<0)<<31>>31|0,121666,0)|0;n=z;v=af(v|0,((v|0)<0)<<31>>31|0,121666,0)|0;b=z;x=fg(v|0,b|0,16777216,0)|0;x=Xe(x|0,z|0,25)|0;p=z;y=af(x|0,p|0,19,0)|0;j=fg(y|0,z|0,u|0,j|0)|0;u=z;p=vf(x|0,p|0,25)|0;p=cg(v|0,b|0,p|0,z|0)|0;b=z;v=fg(t|0,k|0,16777216,0)|0;v=Xe(v|0,z|0,25)|0;x=z;h=fg(v|0,x|0,s|0,h|0)|0;s=z;x=vf(v|0,x|0,25)|0;x=cg(t|0,k|0,x|0,z|0)|0;k=z;t=fg(r|0,i|0,16777216,0)|0;t=Xe(t|0,z|0,25)|0;v=z;f=fg(t|0,v|0,q|0,f|0)|0;q=z;v=vf(t|0,v|0,25)|0;v=cg(r|0,i|0,v|0,z|0)|0;i=z;r=fg(l|0,g|0,16777216,0)|0;r=Xe(r|0,z|0,25)|0;t=z;d=fg(r|0,t|0,o|0,d|0)|0;o=z;t=vf(r|0,t|0,25)|0;t=cg(l|0,g|0,t|0,z|0)|0;g=z;l=fg(w|0,e|0,16777216,0)|0;l=Xe(l|0,z|0,25)|0;r=z;n=fg(l|0,r|0,m|0,n|0)|0;m=z;r=vf(l|0,r|0,25)|0;r=cg(w|0,e|0,r|0,z|0)|0;e=z;w=fg(j|0,u|0,33554432,0)|0;w=Xe(w|0,z|0,26)|0;l=z;k=fg(x|0,k|0,w|0,l|0)|0;l=vf(w|0,l|0,26)|0;l=cg(j|0,u|0,l|0,z|0)|0;u=fg(h|0,s|0,33554432,0)|0;u=Xe(u|0,z|0,26)|0;j=z;i=fg(v|0,i|0,u|0,j|0)|0;j=vf(u|0,j|0,26)|0;j=cg(h|0,s|0,j|0,z|0)|0;s=fg(f|0,q|0,33554432,0)|0;s=Xe(s|0,z|0,26)|0;h=z;g=fg(t|0,g|0,s|0,h|0)|0;h=vf(s|0,h|0,26)|0;h=cg(f|0,q|0,h|0,z|0)|0;q=fg(d|0,o|0,33554432,0)|0;q=Xe(q|0,z|0,26)|0;f=z;e=fg(r|0,e|0,q|0,f|0)|0;f=vf(q|0,f|0,26)|0;f=cg(d|0,o|0,f|0,z|0)|0;o=fg(n|0,m|0,33554432,0)|0;o=Xe(o|0,z|0,26)|0;d=z;b=fg(p|0,b|0,o|0,d|0)|0;d=vf(o|0,d|0,26)|0;d=cg(n|0,m|0,d|0,z|0)|0;c[a>>2]=l;c[a+4>>2]=k;c[a+8>>2]=j;c[a+12>>2]=i;c[a+16>>2]=h;c[a+20>>2]=g;c[a+24>>2]=f;c[a+28>>2]=e;c[a+32>>2]=d;c[a+36>>2]=b;return}function za(a,b,d,e,f){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0;if(!b)if(!e){if(f|0){c[f>>2]=(a>>>0)%(d>>>0);c[f+4>>2]=0}e=0;f=(a>>>0)/(d>>>0)>>>0;return (z=e,f)|0}else{if(!f){e=0;f=0;return (z=e,f)|0}c[f>>2]=a|0;c[f+4>>2]=b&0;e=0;f=0;return (z=e,f)|0}do if(d){if(e|0){h=(R(e|0)|0)-(R(b|0)|0)|0;if(h>>>0<=31){n=h+1|0;i=a>>>((h+1|0)>>>0)&h-31>>31|b<<31-h;m=b>>>((h+1|0)>>>0)&h-31>>31;g=0;h=a<<31-h;break}if(!f){e=0;f=0;return (z=e,f)|0}c[f>>2]=a|0;c[f+4>>2]=b|b&0;e=0;f=0;return (z=e,f)|0}if(d-1&d|0){h=(R(d|0)|0)+33-(R(b|0)|0)|0;n=h;i=32-h-1>>31&b>>>((h-32|0)>>>0)|(b<<32-h|a>>>(h>>>0))&h-32>>31;m=h-32>>31&b>>>(h>>>0);g=a<<64-h&32-h>>31;h=(b<<64-h|a>>>((h-32|0)>>>0))&32-h>>31|a<<32-h&h-33>>31;break}if(f|0){c[f>>2]=d-1&a;c[f+4>>2]=0}if((d|0)==1){e=b|b&0;f=a|0|0;return (z=e,f)|0}else{f=Yd(d|0)|0;e=b>>>(f>>>0)|0;f=b<<32-f|a>>>(f>>>0)|0;return (z=e,f)|0}}else{if(!e){if(f|0){c[f>>2]=(b>>>0)%(d>>>0);c[f+4>>2]=0}e=0;f=(b>>>0)/(d>>>0)>>>0;return (z=e,f)|0}if(!a){if(f|0){c[f>>2]=0;c[f+4>>2]=(b>>>0)%(e>>>0)}d=0;f=(b>>>0)/(e>>>0)>>>0;return (z=d,f)|0}if(!(e-1&e)){if(f|0){c[f>>2]=a|0;c[f+4>>2]=e-1&b|b&0}d=0;f=b>>>((Yd(e|0)|0)>>>0);return (z=d,f)|0}h=(R(e|0)|0)-(R(b|0)|0)|0;if(h>>>0<=30){n=h+1|0;i=b<<31-h|a>>>((h+1|0)>>>0);m=b>>>((h+1|0)>>>0);g=0;h=a<<31-h;break}if(!f){e=0;f=0;return (z=e,f)|0}c[f>>2]=a|0;c[f+4>>2]=b|b&0;e=0;f=0;return (z=e,f)|0}while(0);if(!n){j=h;b=m;a=0;h=0}else{k=fg(d|0|0,e|e&0|0,-1,-1)|0;l=z;j=h;b=m;a=n;h=0;do{p=j;j=g>>>31|j<<1;g=h|g<<1;p=i<<1|p>>>31|0;o=i>>>31|b<<1|0;cg(k|0,l|0,p|0,o|0)|0;n=z;m=n>>31|((n|0)<0?-1:0)<<1;h=m&1;i=cg(p|0,o|0,m&(d|0)|0,(((n|0)<0?-1:0)>>31|((n|0)<0?-1:0)<<1)&(e|e&0)|0)|0;b=z;a=a-1|0}while((a|0)!=0);a=0}if(f|0){c[f>>2]=i;c[f+4>>2]=b}o=(g|0)>>>31|j<<1|(0<<1|g>>>31)&0|a;p=(g<<1|0>>>31)&-2|h;return (z=o,p)|0}function Aa(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0;if(!d){G=857760878;H=2036477234;I=1634760805;y=1797285236}else{I=Rg(d)|0;G=Rg(d+4|0)|0;H=Rg(d+8|0)|0;y=Rg(d+12|0)|0}z=Rg(c)|0;A=Rg(c+4|0)|0;B=Rg(c+8|0)|0;C=Rg(c+12|0)|0;D=Rg(c+16|0)|0;E=Rg(c+20|0)|0;F=Rg(c+24|0)|0;u=Rg(c+28|0)|0;v=Rg(b)|0;w=Rg(b+4|0)|0;x=Rg(b+8|0)|0;t=Rg(b+12|0)|0;if((e|0)>0){g=z;i=A;l=B;o=C;r=v;q=w;p=x;n=t;m=D;k=u;j=F;h=E;s=0;b=G;c=H;d=y;f=I;do{o=(xh(f+h|0,7)|0)^o;p=(xh(o+f|0,9)|0)^p;h=(xh(p+o|0,13)|0)^h;f=(xh(h+p|0,18)|0)^f;n=(xh(g+b|0,7)|0)^n;j=(xh(n+b|0,9)|0)^j;g=(xh(j+n|0,13)|0)^g;b=(xh(g+j|0,18)|0)^b;k=(xh(r+c|0,7)|0)^k;i=(xh(k+c|0,9)|0)^i;r=(xh(i+k|0,13)|0)^r;c=(xh(r+i|0,18)|0)^c;l=(xh(m+d|0,7)|0)^l;q=(xh(l+d|0,9)|0)^q;m=(xh(q+l|0,13)|0)^m;d=(xh(m+q|0,18)|0)^d;g=(xh(l+f|0,7)|0)^g;i=(xh(g+f|0,9)|0)^i;l=(xh(i+g|0,13)|0)^l;f=(xh(l+i|0,18)|0)^f;r=(xh(b+o|0,7)|0)^r;q=(xh(r+b|0,9)|0)^q;o=(xh(q+r|0,13)|0)^o;b=(xh(o+q|0,18)|0)^b;m=(xh(c+n|0,7)|0)^m;p=(xh(m+c|0,9)|0)^p;n=(xh(p+m|0,13)|0)^n;c=(xh(n+p|0,18)|0)^c;h=(xh(d+k|0,7)|0)^h;j=(xh(h+d|0,9)|0)^j;k=(xh(j+h|0,13)|0)^k;d=(xh(k+j|0,18)|0)^d;s=s+2|0}while((s|0)<(e|0))}else{g=z;i=A;l=B;o=C;r=v;q=w;p=x;n=t;m=D;k=u;j=F;h=E;f=I;b=G;c=H;d=y}jg(a,f+I|0);jg(a+4|0,g+z|0);jg(a+8|0,i+A|0);jg(a+12|0,l+B|0);jg(a+16|0,o+C|0);jg(a+20|0,b+G|0);jg(a+24|0,r+v|0);jg(a+28|0,q+w|0);jg(a+32|0,p+x|0);jg(a+36|0,n+t|0);jg(a+40|0,c+H|0);jg(a+44|0,m+D|0);jg(a+48|0,h+E|0);jg(a+52|0,j+F|0);jg(a+56|0,k+u|0);jg(a+60|0,d+y|0);return}function Ba(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+2272|0;Ab(g+2016|0,c);Ab(g+1760|0,e);Xd(g+480|0,d);ye(g+320|0,d);Id(g,g+320|0);Rb(g+320|0,g,g+480|0);Id(g+160|0,g+320|0);Xd(g+480+160|0,g+160|0);Rb(g+320|0,g,g+480+160|0);Id(g+160|0,g+320|0);Xd(g+480+320|0,g+160|0);Rb(g+320|0,g,g+480+320|0);Id(g+160|0,g+320|0);Xd(g+480+480|0,g+160|0);Rb(g+320|0,g,g+480+480|0);Id(g+160|0,g+320|0);Xd(g+480+640|0,g+160|0);Rb(g+320|0,g,g+480+640|0);Id(g+160|0,g+320|0);Xd(g+480+800|0,g+160|0);Rb(g+320|0,g,g+480+800|0);Id(g+160|0,g+320|0);Xd(g+480+960|0,g+160|0);Rb(g+320|0,g,g+480+960|0);Id(g+160|0,g+320|0);Xd(g+480+1120|0,g+160|0);Mf(b);c=255;while(1){if(a[g+2016+c>>0]|0)break;if(a[g+1760+c>>0]|0)break;d=c+-1|0;if((c|0)>0)c=d;else{c=d;break}}if((c|0)>-1)while(1){jc(g+320|0,b);d=a[g+2016+c>>0]|0;if(d<<24>>24<=0){if(d<<24>>24<0){Id(g+160|0,g+320|0);Qb(g+320|0,g+160|0,g+480+((((d<<24>>24)/-2|0)<<24>>24)*160|0)|0)}}else{Id(g+160|0,g+320|0);Rb(g+320|0,g+160|0,g+480+(((d&255)>>>1&255)*160|0)|0)}d=a[g+1760+c>>0]|0;if(d<<24>>24<=0){if(d<<24>>24<0){Id(g+160|0,g+320|0);Vb(g+320|0,g+160|0,1272+((((d<<24>>24)/-2|0)<<24>>24)*120|0)|0)}}else{Id(g+160|0,g+320|0);Wb(g+320|0,g+160|0,1272+(((d&255)>>>1&255)*120|0)|0)}ze(b,g+320|0);if((c|0)>0)c=c+-1|0;else break}l=f;return}function Ca(a){a=a|0;var b=0,d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0;u=l;v=l=l+63&-64;l=l+64|0;Ef(v,a);b=0;e=c[v+44>>2]|0;f=c[v+60>>2]|0;g=c[v+12>>2]|0;h=c[v+28>>2]|0;i=c[v+48>>2]|0;j=c[v>>2]|0;k=c[v+16>>2]|0;m=c[v+32>>2]|0;d=c[v+4>>2]|0;n=c[v+20>>2]|0;o=c[v+36>>2]|0;p=c[v+52>>2]|0;q=c[v+24>>2]|0;r=c[v+40>>2]|0;s=c[v+56>>2]|0;t=c[v+8>>2]|0;do{F=i+j|0;F=(F<<7|F>>>25)^k;C=F+j|0;C=(C<<9|C>>>23)^m;z=(C+F<<13|(C+F|0)>>>19)^i;I=(z+C<<18|(z+C|0)>>>14)^j;B=d+n|0;B=(B<<7|B>>>25)^o;y=B+n|0;y=(y<<9|y>>>23)^p;L=(y+B<<13|(y+B|0)>>>19)^d;E=(L+y<<18|(L+y|0)>>>14)^n;x=q+r|0;x=(x<<7|x>>>25)^s;K=x+r|0;K=(K<<9|K>>>23)^t;H=(K+x<<13|(K+x|0)>>>19)^q;A=(H+K<<18|(H+K|0)>>>14)^r;J=e+f|0;J=(J<<7|J>>>25)^g;G=J+f|0;G=(G<<9|G>>>23)^h;D=(G+J<<13|(G+J|0)>>>19)^e;w=(D+G<<18|(D+G|0)>>>14)^f;d=(J+I<<7|(J+I|0)>>>25)^L;L=d+I|0;t=(L<<9|L>>>23)^K;K=t+d|0;g=(K<<13|K>>>19)^J;J=g+t|0;j=(J<<18|J>>>14)^I;q=(F+E<<7|(F+E|0)>>>25)^H;H=q+E|0;h=(H<<9|H>>>23)^G;G=h+q|0;k=(G<<13|G>>>19)^F;F=k+h|0;n=(F<<18|F>>>14)^E;e=(B+A<<7|(B+A|0)>>>25)^D;D=e+A|0;m=(D<<9|D>>>23)^C;C=m+e|0;o=(C<<13|C>>>19)^B;B=o+m|0;r=(B<<18|B>>>14)^A;i=(x+w<<7|(x+w|0)>>>25)^z;z=i+w|0;p=(z<<9|z>>>23)^y;y=p+i|0;s=(y<<13|y>>>19)^x;x=s+p|0;f=(x<<18|x>>>14)^w;b=b+2|0}while(b>>>0<8);c[v>>2]=j;c[v+48>>2]=i;c[v+16>>2]=k;c[v+32>>2]=m;c[v+20>>2]=n;c[v+4>>2]=d;c[v+36>>2]=o;c[v+52>>2]=p;c[v+40>>2]=r;c[v+24>>2]=q;c[v+56>>2]=s;c[v+8>>2]=t;c[v+60>>2]=f;c[v+44>>2]=e;c[v+12>>2]=g;c[v+28>>2]=h;c[a>>2]=(c[a>>2]|0)+j;b=1;while(1){L=a+(b<<2)|0;c[L>>2]=(c[L>>2]|0)+d;b=b+1|0;if((b|0)==16)break;d=c[v+(b<<2)>>2]|0}l=u;return}function Da(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0;if(!d){d=1797285236;e=2036477234;f=857760878;g=1634760805}else{g=Rg(d)|0;f=Rg(d+4|0)|0;e=Rg(d+8|0)|0;d=Rg(d+12|0)|0}r=Rg(c)|0;q=Rg(c+4|0)|0;p=Rg(c+8|0)|0;o=Rg(c+12|0)|0;n=Rg(c+16|0)|0;m=Rg(c+20|0)|0;l=Rg(c+24|0)|0;k=Rg(c+28|0)|0;j=Rg(b)|0;i=Rg(b+4|0)|0;h=Rg(b+8|0)|0;s=0;b=Rg(b+12|0)|0;c=g;do{L=r+c|0;A=xh(j^L,16)|0;z=A+n|0;M=xh(z^r,12)|0;A=xh(M+L^A,8)|0;w=xh(A+z^M,7)|0;H=q+f|0;u=xh(i^H,16)|0;t=u+m|0;I=xh(t^q,12)|0;u=xh(I+H^u,8)|0;N=xh(u+t^I,7)|0;C=p+e|0;v=xh(h^C,16)|0;B=v+l|0;D=xh(B^p,12)|0;v=xh(D+C^v,8)|0;J=xh(v+B^D,7)|0;x=o+d|0;F=xh(b^x,16)|0;g=F+k|0;y=xh(g^o,12)|0;F=xh(y+x^F,8)|0;E=xh(F+g^y,7)|0;K=xh(F^N+(M+L),16)|0;G=xh(K+(v+B)^N,12)|0;c=G+(N+(M+L))|0;b=xh(c^K,8)|0;l=b+(K+(v+B))|0;q=xh(l^G,7)|0;G=xh(J+(I+H)^A,16)|0;B=xh(G+(F+g)^J,12)|0;f=B+(J+(I+H))|0;j=xh(f^G,8)|0;k=j+(G+(F+g))|0;p=xh(k^B,7)|0;B=xh(E+(D+C)^u,16)|0;g=xh(B+(A+z)^E,12)|0;e=g+(E+(D+C))|0;i=xh(e^B,8)|0;n=i+(B+(A+z))|0;o=xh(n^g,7)|0;v=xh(y+x+w^v,16)|0;g=xh(v+(u+t)^w,12)|0;d=g+(y+x+w)|0;h=xh(d^v,8)|0;m=h+(v+(u+t))|0;r=xh(m^g,7)|0;s=s+1|0}while((s|0)!=10);jg(a,c);jg(a+4|0,f);jg(a+8|0,e);jg(a+12|0,d);jg(a+16|0,j);jg(a+20|0,i);jg(a+24|0,h);jg(a+28|0,b);return 0}function Ea(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0;n=l;m=l=l+63&-64;l=l+704|0;a:do if(!((e|0)==0&(f|0)==0)){r=c[b+72>>2]|0;p=c[b+72+4>>2]|0;k=yf(r|0,p|0,3)|0;o=vf(e|0,f|0,3)|0;q=z;i=yf(e|0,f|0,61)|0;j=z;p=fg(r|0,p|0,o|0,q|0)|0;r=z;c[b+72>>2]=p;c[b+72+4>>2]=r;g=c[b+64>>2]|0;h=c[b+64+4>>2]|0;if(r>>>0<q>>>0|(r|0)==(q|0)&p>>>0<o>>>0){g=fg(g|0,h|0,1,0)|0;h=z;c[b+64>>2]=g;c[b+64+4>>2]=h}j=fg(g|0,h|0,i|0,j|0)|0;c[b+64>>2]=j;c[b+64+4>>2]=z;j=cg(128,0,k&127|0,0)|0;g=z;if(g>>>0>f>>>0|(g|0)==(f|0)&j>>>0>e>>>0){g=0;h=0;while(1){q=a[d+g>>0]|0;r=fg(g|0,h|0,k&127|0,0)|0;a[b+80+r>>0]=q;g=fg(g|0,h|0,1,0)|0;h=z;if(!(h>>>0<f>>>0|(h|0)==(f|0)&g>>>0<e>>>0))break a}}if(!((j|0)==0&(g|0)==0)){h=0;i=0;do{q=a[d+h>>0]|0;r=fg(h|0,i|0,k&127|0,0)|0;a[b+80+r>>0]=q;h=fg(h|0,i|0,1,0)|0;i=z}while(i>>>0<g>>>0|(i|0)==(g|0)&h>>>0<j>>>0)}ja(b,b+80|0,m,m+640|0);g=cg(e|0,f|0,j|0,g|0)|0;h=z;if(h>>>0>0|(h|0)==0&g>>>0>127){i=d+j|0;do{ja(b,i,m,m+640|0);i=i+128|0;g=fg(g|0,h|0,-128,-1)|0;h=z}while(h>>>0>0|(h|0)==0&g>>>0>127);j=i}else j=d+j|0;g=g&127;if(!((g|0)==0&0==0)){h=0;i=0;do{a[b+80+h>>0]=a[j+h>>0]|0;h=fg(h|0,i|0,1,0)|0;i=z}while(i>>>0<0|(i|0)==0&h>>>0<g>>>0)}Sd(m,704)}while(0);l=n;return 0}function Fa(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+160|0;qa(d+120|0,b);qa(d+80|0,d+120|0);qa(d+80|0,d+80|0);la(d+80|0,b,d+80|0);la(d+120|0,d+120|0,d+80|0);qa(d+40|0,d+120|0);la(d+80|0,d+80|0,d+40|0);qa(d+40|0,d+80|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=5);la(d+80|0,d+40|0,d+80|0);qa(d+40|0,d+80|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=10);la(d+40|0,d+40|0,d+80|0);qa(d,d+40|0);b=1;do{qa(d,d);b=b+1|0}while((b|0)!=20);la(d+40|0,d,d+40|0);qa(d+40|0,d+40|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=10);la(d+80|0,d+40|0,d+80|0);qa(d+40|0,d+80|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=50);la(d+40|0,d+40|0,d+80|0);qa(d,d+40|0);b=1;do{qa(d,d);b=b+1|0}while((b|0)!=100);la(d+40|0,d,d+40|0);qa(d+40|0,d+40|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=50);la(d+80|0,d+40|0,d+80|0);qa(d+80|0,d+80|0);b=1;do{qa(d+80|0,d+80|0);b=b+1|0}while((b|0)!=5);la(a,d+80|0,d+120|0);l=c;return}function Ga(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0;if(!d){d=1797285236;e=2036477234;f=857760878;o=1634760805}else{o=Rg(d)|0;f=Rg(d+4|0)|0;e=Rg(d+8|0)|0;d=Rg(d+12|0)|0}n=Rg(c)|0;m=Rg(c+4|0)|0;l=Rg(c+8|0)|0;k=Rg(c+12|0)|0;t=Rg(c+16|0)|0;s=Rg(c+20|0)|0;r=Rg(c+24|0)|0;q=Rg(c+28|0)|0;j=Rg(b)|0;i=Rg(b+4|0)|0;h=Rg(b+8|0)|0;g=Rg(b+12|0)|0;p=20;b=f;c=o;while(1){B=(xh(s+c|0,7)|0)^k;y=(xh(B+c|0,9)|0)^h;v=(xh(y+B|0,13)|0)^s;E=(xh(v+y|0,18)|0)^c;x=(xh(b+n|0,7)|0)^g;u=(xh(x+b|0,9)|0)^r;H=(xh(u+x|0,13)|0)^n;A=(xh(H+u|0,18)|0)^b;f=(xh(e+j|0,7)|0)^q;G=(xh(f+e|0,9)|0)^m;D=(xh(G+f|0,13)|0)^j;w=(xh(D+G|0,18)|0)^e;F=(xh(d+t|0,7)|0)^l;C=(xh(F+d|0,9)|0)^i;z=(xh(C+F|0,13)|0)^t;o=(xh(z+C|0,18)|0)^d;n=(xh(F+E|0,7)|0)^H;m=(xh(n+E|0,9)|0)^G;l=(xh(m+n|0,13)|0)^F;c=(xh(l+m|0,18)|0)^E;j=(xh(A+B|0,7)|0)^D;i=(xh(j+A|0,9)|0)^C;k=(xh(i+j|0,13)|0)^B;b=(xh(k+i|0,18)|0)^A;t=(xh(w+x|0,7)|0)^z;h=(xh(t+w|0,9)|0)^y;g=(xh(h+t|0,13)|0)^x;e=(xh(g+h|0,18)|0)^w;s=(xh(o+f|0,7)|0)^v;r=(xh(s+o|0,9)|0)^u;q=(xh(r+s|0,13)|0)^f;d=(xh(q+r|0,18)|0)^o;if((p|0)<=2)break;else p=p+-2|0}jg(a,c);jg(a+4|0,b);jg(a+8|0,e);jg(a+12|0,d);jg(a+16|0,j);jg(a+20|0,i);jg(a+24|0,h);jg(a+28|0,g);return 0}function Ha(a,b){a=a|0;b=b|0;var c=0,d=0,e=0;d=l;e=l=l+63&-64;l=l+128|0;qa(e+80|0,b);qa(e+40|0,e+80|0);qa(e+40|0,e+40|0);la(e+40|0,b,e+40|0);la(e+80|0,e+80|0,e+40|0);qa(e+80|0,e+80|0);la(e+80|0,e+40|0,e+80|0);qa(e+40|0,e+80|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=5);la(e+80|0,e+40|0,e+80|0);qa(e+40|0,e+80|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=10);la(e+40|0,e+40|0,e+80|0);qa(e,e+40|0);c=1;do{qa(e,e);c=c+1|0}while((c|0)!=20);la(e+40|0,e,e+40|0);qa(e+40|0,e+40|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=10);la(e+80|0,e+40|0,e+80|0);qa(e+40|0,e+80|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=50);la(e+40|0,e+40|0,e+80|0);qa(e,e+40|0);c=1;do{qa(e,e);c=c+1|0}while((c|0)!=100);la(e+40|0,e,e+40|0);qa(e+40|0,e+40|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=50);la(e+80|0,e+40|0,e+80|0);qa(e+80|0,e+80|0);qa(e+80|0,e+80|0);la(a,e+80|0,b);l=d;return}function Ia(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0;o=l;k=l=l+63&-64;l=l+16|0;do if(d>>>0>=12){f=b;g=34163;h=f+12|0;do{a[f>>0]=a[g>>0]|0;f=f+1|0;g=g+1|0}while((f|0)<(h|0));f=hb(e)|0;if(!f){fd(k,19);h=uc(k)|0;g=b+11+h|0;if((d+-11|0)>>>0<=h>>>0){f=-31;break}fb(b+11|0,k|0,h+1|0)|0;if((d+-11-h|0)>>>0>=4){a[g>>0]=36;a[g+1>>0]=109;a[g+2>>0]=61;a[g+3>>0]=0;fd(k,c[e+44>>2]|0);f=uc(k)|0;i=g+3+f|0;j=d+-11-h+-3-f|0;if((d+-11-h+-3|0)>>>0<=f>>>0){f=-31;break}fb(g+3|0,k|0,f+1|0)|0;if(j>>>0>=4){a[i>>0]=44;a[i+1>>0]=116;a[i+2>>0]=61;a[i+3>>0]=0;fd(k,c[e+40>>2]|0);f=uc(k)|0;b=i+3+f|0;if((j+-3|0)>>>0<=f>>>0){f=-31;break}fb(i+3|0,k|0,f+1|0)|0;if((j+-3-f|0)>>>0>=4){a[b>>0]=44;a[b+1>>0]=112;a[b+2>>0]=61;a[b+3>>0]=0;fd(k,c[e+48>>2]|0);g=uc(k)|0;h=j+-3-f+-3-g|0;if((j+-3-f+-3|0)>>>0<=g>>>0){f=-31;break}fb(b+3|0,k|0,g+1|0)|0;f=b+3+g+1|0;if(h>>>0>=2?(a[b+3+g>>0]=36,a[b+3+g+1>>0]=0,k=Eb(f,h+-1|0,c[e+16>>2]|0,c[e+20>>2]|0)|0,n=h+-1-((k|0)==-1?0:k)|0,m=(k|0)==-1?f:f+k|0,!((k|0)==-1|n>>>0<2)):0){a[m>>0]=36;a[m+1>>0]=0;e=(Eb(m+1|0,n+-1|0,c[e>>2]|0,c[e+4>>2]|0)|0)!=-1;l=o;return (e?0:-31)|0}else f=-31}else f=-31}else f=-31}else f=-31}}else f=-31;while(0);l=o;return f|0}function Ja(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0;m=c[d>>2]|0;h=c[d+4>>2]|0;i=c[d+8>>2]|0;j=c[d+12>>2]|0;p=c[d+16>>2]|0;f=c[d+20>>2]|0;g=c[d+24>>2]|0;n=c[d+28>>2]|0;e=c[d+32>>2]|0;d=c[d+36>>2]|0;o=((((((((((((((d*19|0)+16777216|0)>>>25)+m>>26)+h>>25)+i>>26)+j>>25)+p>>26)+f>>25)+g>>26)+n>>25)+e>>26)+d>>25)*19|0)+m>>26;m=((((((((((((((d*19|0)+16777216|0)>>>25)+m>>26)+h>>25)+i>>26)+j>>25)+p>>26)+f>>25)+g>>26)+n>>25)+e>>26)+d>>25)*19|0)+m-(o<<26)|0;l=o+h-(o+h>>25<<25)|0;k=(o+h>>25)+i-((o+h>>25)+i>>26<<26)|0;q=((o+h>>25)+i>>26)+j>>25;j=((o+h>>25)+i>>26)+j-(q<<25)|0;i=q+p-(q+p>>26<<26)|0;h=(q+p>>26)+f-((q+p>>26)+f>>25<<25)|0;o=((q+p>>26)+f>>25)+g>>26;g=((q+p>>26)+f>>25)+g-(o<<26)|0;f=o+n-(o+n>>25<<25)|0;d=((o+n>>25)+e>>26)+d|0;e=(o+n>>25)+e-((o+n>>25)+e>>26<<26)|0;a[b>>0]=m;a[b+1>>0]=m>>>8;a[b+2>>0]=m>>>16;a[b+3>>0]=l<<2|m>>>24;a[b+4>>0]=l>>>6;a[b+5>>0]=l>>>14;a[b+6>>0]=k<<3|l>>>22;a[b+7>>0]=k>>>5;a[b+8>>0]=k>>>13;a[b+9>>0]=j<<5|k>>>21;a[b+10>>0]=j>>>3;a[b+11>>0]=j>>>11;a[b+12>>0]=i<<6|j>>>19;a[b+13>>0]=i>>>2;a[b+14>>0]=i>>>10;a[b+15>>0]=i>>>18;a[b+16>>0]=h;a[b+17>>0]=h>>>8;a[b+18>>0]=h>>>16;a[b+19>>0]=g<<1|h>>>24;a[b+20>>0]=g>>>7;a[b+21>>0]=g>>>15;a[b+22>>0]=f<<3|g>>>23;a[b+23>>0]=f>>>5;a[b+24>>0]=f>>>13;a[b+25>>0]=e<<4|f>>>21;a[b+26>>0]=e>>>4;a[b+27>>0]=e>>>12;a[b+28>>0]=e>>>20|(d&33554431)<<6;a[b+29>>0]=d>>>2;a[b+30>>0]=d>>>10;a[b+31>>0]=(d&33554431)>>>18;return}function Ka(b,c,e){b=b|0;c=c|0;e=e|0;var f=0,g=0,h=0,i=0;h=l;i=l=l+63&-64;l=l+320|0;g=i+280|0;f=g+32|0;do{a[g>>0]=a[c>>0]|0;g=g+1|0;c=c+1|0}while((g|0)<(f|0));a[i+280>>0]=a[i+280>>0]&-8;a[i+280+31>>0]=a[i+280+31>>0]&63|64;xa(i+240|0,e);Bf(i+200|0);lg(i+160|0);qc(i+120|0,i+240|0);Bf(i+80|0);c=0;f=254;while(1){g=c;c=(d[i+280+(f>>>3)>>0]|0)>>>(f&7)&1;g=c^g;bb(i+200|0,i+120|0,g);bb(i+160|0,i+80|0,g);Fb(i+40|0,i+120|0,i+80|0);Fb(i,i+200|0,i+160|0);Gb(i+200|0,i+200|0,i+160|0);Gb(i+160|0,i+120|0,i+80|0);la(i+80|0,i+40|0,i+200|0);la(i+160|0,i+160|0,i);qa(i+40|0,i);qa(i,i+200|0);Gb(i+120|0,i+80|0,i+160|0);Fb(i+160|0,i+80|0,i+160|0);la(i+200|0,i,i+40|0);Fb(i,i,i+40|0);qa(i+160|0,i+160|0);ya(i+80|0,i);qa(i+120|0,i+120|0);Gb(i+40|0,i+40|0,i+80|0);la(i+80|0,i+240|0,i+160|0);la(i+160|0,i,i+40|0);if((f|0)<=0)break;else f=f+-1|0}bb(i+200|0,i+120|0,c);bb(i+160|0,i+80|0,c);Fa(i+160|0,i+160|0);la(i+200|0,i+200|0,i+160|0);Ja(b,i+200|0);l=h;return 0}function La(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0;n=l;m=l=l+63&-64;l=l+288|0;a:do if(!((e|0)==0&(f|0)==0)){i=c[b+32>>2]|0;g=c[b+32+4>>2]|0;j=yf(i|0,g|0,3)|0;k=vf(e|0,f|0,3)|0;k=fg(i|0,g|0,k|0,z|0)|0;c[b+32>>2]=k;c[b+32+4>>2]=z;k=cg(64,0,j&63|0,0)|0;g=z;if(g>>>0>f>>>0|(g|0)==(f|0)&k>>>0>e>>>0){g=0;h=0;while(1){k=a[d+g>>0]|0;m=fg(g|0,h|0,j&63|0,0)|0;a[b+40+m>>0]=k;g=fg(g|0,h|0,1,0)|0;h=z;if(!(h>>>0<f>>>0|(h|0)==(f|0)&g>>>0<e>>>0))break a}}if(!((k|0)==0&(g|0)==0)){h=0;i=0;do{p=a[d+h>>0]|0;o=fg(h|0,i|0,j&63|0,0)|0;a[b+40+o>>0]=p;h=fg(h|0,i|0,1,0)|0;i=z}while(i>>>0<g>>>0|(i|0)==(g|0)&h>>>0<k>>>0)}pa(b,b+40|0,m,m+256|0);g=cg(e|0,f|0,k|0,g|0)|0;h=z;if(h>>>0>0|(h|0)==0&g>>>0>63){i=d+k|0;do{pa(b,i,m,m+256|0);i=i+64|0;g=fg(g|0,h|0,-64,-1)|0;h=z}while(h>>>0>0|(h|0)==0&g>>>0>63);j=i}else j=d+k|0;g=g&63;if(!((g|0)==0&0==0)){h=0;i=0;do{a[b+40+h>>0]=a[j+h>>0]|0;h=fg(h|0,i|0,1,0)|0;i=z}while(i>>>0<0|(i|0)==0&h>>>0<g>>>0)}Sd(m,288)}while(0);l=n;return 0}function Ma(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0;h=c[b+56>>2]|0;g=c[b+56+4>>2]|0;if(!((h|0)==0&(g|0)==0)){j=cg(16,0,h|0,g|0)|0;l=z;k=l>>>0>f>>>0|(l|0)==(f|0)&j>>>0>e>>>0?e:j;l=l>>>0>f>>>0|(l|0)==(f|0)&j>>>0>e>>>0?f:l;if(!((k|0)==0&(l|0)==0)){j=0;i=0;do{n=a[d+j>>0]|0;h=fg(h|0,g|0,j|0,i|0)|0;a[b+64+h>>0]=n;j=fg(j|0,i|0,1,0)|0;i=z;h=c[b+56>>2]|0;g=c[b+56+4>>2]|0}while(i>>>0<l>>>0|(i|0)==(l|0)&j>>>0<k>>>0)}n=fg(h|0,g|0,k|0,l|0)|0;j=z;c[b+56>>2]=n;c[b+56+4>>2]=j;if(!(j>>>0<0|(j|0)==0&n>>>0<16)){e=cg(e|0,f|0,k|0,l|0)|0;f=z;wa(b,b+64|0,16,0);c[b+56>>2]=0;c[b+56+4>>2]=0;d=d+k|0;m=6}}else m=6;if((m|0)==6){g=e&-16;if(f>>>0>0|(f|0)==0&e>>>0>15){e=cg(e|0,f|0,g|0,f|0)|0;n=z;wa(b,d,g,f);d=d+g|0;g=n}else g=f;if(!((e|0)==0&(g|0)==0)){f=0;h=c[b+56>>2]|0;i=c[b+56+4>>2]|0;j=0;do{m=a[d+f>>0]|0;n=fg(h|0,i|0,f|0,j|0)|0;a[b+64+n>>0]=m;f=fg(f|0,j|0,1,0)|0;j=z;h=c[b+56>>2]|0;i=c[b+56+4>>2]|0}while(j>>>0<g>>>0|(j|0)==(g|0)&f>>>0<e>>>0);n=fg(h|0,i|0,e|0,g|0)|0;c[b+56>>2]=n;c[b+56+4>>2]=z}}return}function Na(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+400|0;if(!((a|0)==0|(b|0)==0)){Gc(f,0,0,64)|0;jg(f+384|0,c[b+48>>2]|0);og(f,f+384|0,4,0)|0;jg(f+384|0,c[b+4>>2]|0);og(f,f+384|0,4,0)|0;jg(f+384|0,c[b+44>>2]|0);og(f,f+384|0,4,0)|0;jg(f+384|0,c[b+40>>2]|0);og(f,f+384|0,4,0)|0;jg(f+384|0,19);og(f,f+384|0,4,0)|0;jg(f+384|0,d);og(f,f+384|0,4,0)|0;jg(f+384|0,c[b+12>>2]|0);og(f,f+384|0,4,0)|0;d=c[b+8>>2]|0;if(d|0?(og(f,d,c[b+12>>2]|0,0)|0,c[b+56>>2]&1|0):0){Sd(c[b+8>>2]|0,c[b+12>>2]|0);c[b+12>>2]=0}jg(f+384|0,c[b+20>>2]|0);og(f,f+384|0,4,0)|0;d=c[b+16>>2]|0;if(d|0)og(f,d,c[b+20>>2]|0,0)|0;jg(f+384|0,c[b+28>>2]|0);og(f,f+384|0,4,0)|0;d=c[b+24>>2]|0;if(d|0?(og(f,d,c[b+28>>2]|0,0)|0,c[b+56>>2]&2|0):0){Sd(c[b+24>>2]|0,c[b+28>>2]|0);c[b+28>>2]=0}jg(f+384|0,c[b+36>>2]|0);og(f,f+384|0,4,0)|0;d=c[b+32>>2]|0;if(d|0)og(f,d,c[b+36>>2]|0,0)|0;cf(f,a,64)|0}l=e;return}function Oa(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0;j=l;k=l=l+63&-64;l=l+528|0;c[k+384>>2]=0;jg(k+384|0,d);if(d>>>0<65){if((Gc(k,0,0,d)|0)>=0){og(k,k+384|0,4,0)|0;og(k,e,f,0)|0;cf(k,b,d)|0}}else a:do if((Gc(k,0,0,64)|0)>=0?(og(k,k+384|0,4,0)|0,og(k,e,f,0)|0,(cf(k,k+456|0,64)|0)>=0):0){g=b;h=k+456|0;i=g+32|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0));g=k+392|0;h=k+456|0;i=g+64|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0));if((d+-32|0)>>>0>64){f=d+-32|0;e=b+32|0;do{if((Sc(k+456|0,64,k+392|0,64,0,0,0)|0)<0)break a;g=e;h=k+456|0;i=g+32|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0));f=f+-32|0;e=e+32|0;g=k+392|0;h=k+456|0;i=g+64|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0))}while(f>>>0>64)}else{f=d+-32|0;e=b+32|0}if((Sc(k+456|0,f,k+392|0,64,0,0,0)|0)>=0)fb(e|0,k+456|0,f|0)|0}while(0);Sd(k,384);l=j;return}function Pa(b,e,f,g,h,i,j,k){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;var m=0,n=0,o=0,p=0;o=l;p=l=l+63&-64;l=l+112|0;if(!((f|0)==0&(g|0)==0)){n=p+16|0;m=n+32|0;do{a[n>>0]=a[k>>0]|0;n=n+1|0;k=k+1|0}while((n|0)<(m|0));k=d[h+4>>0]|d[h+4+1>>0]<<8|d[h+4+2>>0]<<16|d[h+4+3>>0]<<24;c[p>>2]=d[h>>0]|d[h+1>>0]<<8|d[h+2>>0]<<16|d[h+3>>0]<<24;c[p+4>>2]=k;k=8;while(1){a[p+k>>0]=i;i=yf(i|0,j|0,8)|0;k=k+1|0;if((k|0)==16)break;else j=z}if(g>>>0>0|(g|0)==0&f>>>0>63){k=b;i=f;while(1){Og(p+48|0,p,p+16|0,0)|0;b=0;do{a[k+b>>0]=a[p+48+b>>0]^a[e+b>>0];b=b+1|0}while((b|0)!=64);b=1;j=8;while(1){f=p+j|0;b=(d[f>>0]|0)+b|0;a[f>>0]=b;j=j+1|0;if((j|0)==16)break;else b=b>>>8}j=fg(i|0,g|0,-64,-1)|0;g=z;b=k+64|0;e=e+64|0;if(g>>>0>0|(g|0)==0&j>>>0>63){k=b;i=j}else break}}else j=f;if(!((j|0)==0&(g|0)==0)?(Og(p+48|0,p,p+16|0,0)|0,j|0):0){g=0;do{a[b+g>>0]=a[p+48+g>>0]^a[e+g>>0];g=g+1|0}while((g|0)!=(j|0))}Sd(p+48|0,64);Sd(p+16|0,32)}l=o;return 0}function Qa(b,c,d,e,f,g,h){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0;j=l;k=l=l+63&-64;l=l+352|0;Da(k+256|0,g,h,0)|0;if(b>>>0>d>>>0?0<f>>>0|0==(f|0)&(b-d|0)>>>0<e>>>0:0)i=5;else if(d>>>0>b>>>0?0<f>>>0|0==(f|0)&(d-b|0)>>>0<e>>>0:0)i=5;if((i|0)==5){Ed(b|0,d|0,e|0)|0;d=b}h=k+288|0;i=h+32|0;do{a[h>>0]=0;h=h+1|0}while((h|0)<(i|0));h=f>>>0>0|(f|0)==0&e>>>0>32?32:e;i=f>>>0>0|(f|0)==0&e>>>0>32?0:f;if(!((h|0)==0&(i|0)==0)){m=cg(-2,-1,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~e:-33)|0,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~f:-1)|0)|0;fb(k+288+32|0,d|0,m+1|0)|0}m=fg(h|0,i|0,32,0)|0;Tf(k+288|0,k+288|0,m,z,g+16|0,k+256|0)|0;_g(k,k+288|0)|0;if(!((h|0)==0&(i|0)==0)){m=cg(-2,-1,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~e:-33)|0,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~f:-1)|0)|0;fb(b|0,k+288+32|0,m+1|0)|0}Sd(k+288|0,64);if(f>>>0>0|(f|0)==0&e>>>0>32){m=cg(e|0,f|0,h|0,i|0)|0;jf(b+h|0,d+h|0,m,z,g+16|0,1,0,k+256|0)|0}Sd(k+256|0,32);eg(k,b,e,f)|0;Zg(k,c)|0;Sd(k,256);l=j;return 0}function Ra(b,e,f,g,h,i){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0;q=l;r=l=l+63&-64;l=l+112|0;if(!((f|0)==0&(g|0)==0)){k=r+16|0;j=k+32|0;do{a[k>>0]=a[i>>0]|0;k=k+1|0;i=i+1|0}while((k|0)<(j|0));k=d[h+4>>0]|d[h+4+1>>0]<<8|d[h+4+2>>0]<<16|d[h+4+3>>0]<<24;c[r>>2]=d[h>>0]|d[h+1>>0]<<8|d[h+2>>0]<<16|d[h+3>>0]<<24;c[r+4>>2]=k;c[r+8>>2]=0;c[r+8+4>>2]=0;if(g>>>0>0|(g|0)==0&f>>>0>63){k=e;h=f;do{Lg(r+48|0,r,r+16|0,0)|0;i=0;do{a[b+i>>0]=a[r+48+i>>0]^a[k+i>>0];i=i+1|0}while((i|0)!=64);i=1;j=8;while(1){f=r+j|0;i=(d[f>>0]|0)+i|0;a[f>>0]=i;j=j+1|0;if((j|0)==16)break;else i=i>>>8}h=fg(h|0,g|0,-64,-1)|0;g=z;b=b+64|0;k=k+64|0}while(g>>>0>0|(g|0)==0&h>>>0>63);if(!((h|0)==0&(g|0)==0)){n=b;o=h;p=k;m=8}}else{n=b;o=f;p=e;m=8}if((m|0)==8?(Lg(r+48|0,r,r+16|0,0)|0,o|0):0){i=0;do{a[n+i>>0]=a[r+48+i>>0]^a[p+i>>0];i=i+1|0}while((i|0)!=(o|0))}Sd(r+48|0,64);Sd(r+16|0,32)}l=q;return 0}function Sa(b,e,f,g,h,i){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0;q=l;r=l=l+63&-64;l=l+112|0;if(!((f|0)==0&(g|0)==0)){k=r+16|0;j=k+32|0;do{a[k>>0]=a[i>>0]|0;k=k+1|0;i=i+1|0}while((k|0)<(j|0));k=d[h+4>>0]|d[h+4+1>>0]<<8|d[h+4+2>>0]<<16|d[h+4+3>>0]<<24;c[r>>2]=d[h>>0]|d[h+1>>0]<<8|d[h+2>>0]<<16|d[h+3>>0]<<24;c[r+4>>2]=k;c[r+8>>2]=0;c[r+8+4>>2]=0;if(g>>>0>0|(g|0)==0&f>>>0>63){k=e;h=f;do{Ng(r+48|0,r,r+16|0,0)|0;i=0;do{a[b+i>>0]=a[r+48+i>>0]^a[k+i>>0];i=i+1|0}while((i|0)!=64);i=1;j=8;while(1){f=r+j|0;i=(d[f>>0]|0)+i|0;a[f>>0]=i;j=j+1|0;if((j|0)==16)break;else i=i>>>8}h=fg(h|0,g|0,-64,-1)|0;g=z;b=b+64|0;k=k+64|0}while(g>>>0>0|(g|0)==0&h>>>0>63);if(!((h|0)==0&(g|0)==0)){n=b;o=h;p=k;m=8}}else{n=b;o=f;p=e;m=8}if((m|0)==8?(Ng(r+48|0,r,r+16|0,0)|0,o|0):0){i=0;do{a[n+i>>0]=a[r+48+i>>0]^a[p+i>>0];i=i+1|0}while((i|0)!=(o|0))}Sd(r+48|0,64);Sd(r+16|0,32)}l=q;return 0}function Ta(b,c,d,e,f,g,h){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0;j=l;k=l=l+63&-64;l=l+352|0;Ga(k+256|0,g,h,0)|0;if(b>>>0>d>>>0?0<f>>>0|0==(f|0)&(b-d|0)>>>0<e>>>0:0)i=5;else if(d>>>0>b>>>0?0<f>>>0|0==(f|0)&(d-b|0)>>>0<e>>>0:0)i=5;if((i|0)==5){Ed(b|0,d|0,e|0)|0;d=b}h=k+288|0;i=h+32|0;do{a[h>>0]=0;h=h+1|0}while((h|0)<(i|0));h=f>>>0>0|(f|0)==0&e>>>0>32?32:e;i=f>>>0>0|(f|0)==0&e>>>0>32?0:f;if(!((h|0)==0&(i|0)==0)){m=cg(-2,-1,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~e:-33)|0,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~f:-1)|0)|0;fb(k+288+32|0,d|0,m+1|0)|0}m=fg(h|0,i|0,32,0)|0;Of(k+288|0,k+288|0,m,z,g+16|0,k+256|0)|0;_g(k,k+288|0)|0;if(!((h|0)==0&(i|0)==0)){m=cg(-2,-1,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~e:-33)|0,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~f:-1)|0)|0;fb(b|0,k+288+32|0,m+1|0)|0}Sd(k+288|0,64);if(f>>>0>0|(f|0)==0&e>>>0>32){m=cg(e|0,f|0,h|0,i|0)|0;ef(b+h|0,d+h|0,m,z,g+16|0,1,0,k+256|0)|0}Sd(k+256|0,32);eg(k,b,e,f)|0;Zg(k,c)|0;Sd(k,256);l=j;return 0}function Ua(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0;f=c[b+56>>2]|0;e=c[b+56+4>>2]|0;if(!((f|0)==0&(e|0)==0)){g=1;while(1){a[b+64+f>>0]=g;f=fg(f|0,e|0,1,0)|0;e=z;if(!(e>>>0<0|(e|0)==0&f>>>0<16))break;else g=0}a[b+80>>0]=1;wa(b,b+64|0,16,0)}f=c[b+24>>2]|0;g=(c[b+28>>2]|0)+(f>>>26)|0;k=(g>>>26)+(c[b+32>>2]|0)|0;i=(k>>>26)+(c[b+36>>2]|0)|0;h=((i>>>26)*5|0)+(c[b+20>>2]|0)|0;l=((((h&67108863)+5|0)>>>26)+((h>>>26)+(f&67108863))|0)>>>26;j=(i|-67108864)+((((l+(g&67108863)|0)>>>26)+(k&67108863)|0)>>>26)|0;f=(((h&67108863)+5|0)>>>26)+((h>>>26)+(f&67108863))&67108863&(j>>>31)+-1|j>>31&(h>>>26)+(f&67108863);k=((l+(g&67108863)|0)>>>26)+k&67108863&(j>>>31)+-1|j>>31&(k&67108863);h=fg(h+5&67108863&(j>>>31)+-1|j>>31&(h&67108863)|f<<26|0,0,c[b+40>>2]|0,0)|0;e=z;f=fg(f>>>6|(l+g&67108863&(j>>>31)+-1|j>>31&(g&67108863))<<20|0,0,c[b+44>>2]|0,0)|0;e=fg(f|0,z|0,e|0,0)|0;f=z;g=fg((l+g&67108863&(j>>>31)+-1|j>>31&(g&67108863))>>>12|k<<14|0,0,c[b+48>>2]|0,0)|0;f=fg(g|0,z|0,f|0,0)|0;g=z;i=fg(k>>>18|((j>>>31)+-1&j|j>>31&i)<<8|0,0,c[b+52>>2]|0,0)|0;g=fg(i|0,z|0,g|0,0)|0;jg(d,h);jg(d+4|0,e);jg(d+8|0,f);jg(d+12|0,g);Sd(b,88);return}function Va(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0;p=l;o=l=l+63&-64;l=l+16|0;m=c[b+20>>2]|0;n=c[b+4>>2]|0;c[b+20>>2]=0;c[b+4>>2]=0;q=(fc(d,34138,8)|0)==0;d=q?d+8|0:d;do if((q?(fc(d,34147,3)|0)==0:0)?(g=nc(d+3|0,o)|0,(g|0)!=0):0)if((c[o>>2]|0)==19)if(((((((fc(g,34151,3)|0)==0?(h=nc(g+3|0,o)|0,i=c[o>>2]|0,(h|0)!=0):0)?(c[b+44>>2]=i,(fc(h,34155,3)|0)==0):0)?(j=nc(h+3|0,o)|0,e=(j|0)==0?i:c[o>>2]|0,(j|0)!=0):0)?(c[b+40>>2]=e,(fc(j,34159,3)|0)==0):0)?(k=nc(j+3|0,o)|0,f=(k|0)==0?e:c[o>>2]|0,(k|0)!=0):0)?(c[b+48>>2]=f,c[b+52>>2]=f,(a[k>>0]|0)==36):0){c[o>>2]=m;d=tc(c[b+16>>2]|0,o,k+1|0)|0;if(!d){d=-32;break}c[b+20>>2]=c[o>>2];if((a[d>>0]|0)==36){c[o>>2]=n;e=tc(c[b>>2]|0,o,d+1|0)|0;if(!e){d=-32;break}c[b+4>>2]=c[o>>2];d=hb(b)|0;if(!d)d=(a[e>>0]|0)==0?0:-32}else d=-32}else d=-32;else d=-26;else d=-32;while(0);l=p;return d|0}function Wa(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0;if(b){m=ia(c[b+12>>2]<<3)|0;if(!m)e=-22;else{gb(b,d,m);i=c[d>>2]|0;f=a[d+8>>0]|0;e=(i|0)==0&f<<24>>24==0?2:0;h=c[b+16>>2]|0;k=O(h,c[d+4>>2]|0)|0;l=c[b+12>>2]|0;f=e+k+(O(l,f&255)|0)|0;a:do if(e>>>0<l>>>0){l=f;g=(((f>>>0)%(h>>>0)|0|0)==0?h+-1|0:-1)+f|0;f=h;while(1){k=((l>>>0)%(f>>>0)|0|0)==1?l+-1|0:g;f=m+(e<<3)|0;h=c[f>>2]|0;f=Pe(c[f+4>>2]|0,0,c[b+20>>2]|0,0)|0;g=z;j=(i|0)==0;if(j?(a[d+8>>0]|0)==0:0){f=c[d+4>>2]|0;g=0}c[d+12>>2]=e;h=Cb(b,d,h,((g|0)==0?(f|0)==(c[d+4>>2]|0):0)&1)|0;i=c[(c[b>>2]|0)+4>>2]|0;f=af(c[b+16>>2]|0,0,f|0,g|0)|0;g=i+(l<<10)|0;if(j)na(i+(k<<10)|0,i+(f<<10)+(h<<10)|0,g);else ma(i+(k<<10)|0,i+(f<<10)+(h<<10)|0,g);e=e+1|0;if(e>>>0>=(c[b+12>>2]|0)>>>0)break a;l=l+1|0;g=k+1|0;f=c[b+16>>2]|0;i=c[d>>2]|0}}while(0);ra(m);e=0}}else e=0;return e|0}function Xa(a,b,d,e,f,g){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0,l=0;if(b<<5|0){h=0;do{c[g+(h<<2)>>2]=Rg(a+(h<<2)|0)|0;h=h+1|0}while((h|0)!=(b<<5|0))}if(!((d|0)==0&(e|0)==0)){h=0;i=0;do{k=af(h|0,i|0,b<<5|0,0)|0;Re(f+(k<<2)|0,g,b<<7);Uc(g,g+(b<<5<<2)|0,g+(b<<6<<2)|0,b);k=af(h|1|0,i|0,b<<5|0,0)|0;Re(f+(k<<2)|0,g+(b<<5<<2)|0,b<<7);Uc(g+(b<<5<<2)|0,g,g+(b<<6<<2)|0,b);h=fg(h|0,i|0,2,0)|0;i=z}while(i>>>0<e>>>0|(i|0)==(e|0)&h>>>0<d>>>0);h=fg(d|0,e|0,-1,-1)|0;i=z;j=0;k=0;do{l=Ig(g,b)|0;l=af(l&h|0,z&i|0,b<<5|0,0)|0;we(g,f+(l<<2)|0,b<<7);Uc(g,g+(b<<5<<2)|0,g+(b<<6<<2)|0,b);l=Ig(g+(b<<5<<2)|0,b)|0;l=af(l&h|0,z&i|0,b<<5|0,0)|0;we(g+(b<<5<<2)|0,f+(l<<2)|0,b<<7);Uc(g+(b<<5<<2)|0,g,g+(b<<6<<2)|0,b);j=fg(j|0,k|0,2,0)|0;k=z}while(k>>>0<e>>>0|(k|0)==(e|0)&j>>>0<d>>>0)}if(b<<5|0){h=0;do{jg(a+(h<<2)|0,c[g+(h<<2)>>2]|0);h=h+1|0}while((h|0)!=(b<<5|0))}return}function Ya(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0;j=l;i=l=l+63&-64;l=l+96|0;Da(i,f,g,0)|0;Cg(i+32|0,32,0,f+16|0,i)|0;if(!(Rf(c,b,d,e,i+32|0)|0))if(!a)c=0;else{if(b>>>0>=a>>>0?0<e>>>0|0==(e|0)&(b-a|0)>>>0<d>>>0:0)h=8;else if(a>>>0>=b>>>0?0<e>>>0|0==(e|0)&(a-b|0)>>>0<d>>>0:0)h=8;if((h|0)==8){Ed(a|0,b|0,d|0)|0;b=a}c=e>>>0>0|(e|0)==0&d>>>0>32?32:d;g=e>>>0>0|(e|0)==0&d>>>0>32?0:e;if((c|0)==0&(g|0)==0)Tf(i+32|0,i+32|0,32,0,f+16|0,i)|0;else{h=cg(-2,-1,(~e>>>0>4294967295|(~e|0)==-1&~d>>>0>4294967263?~d:-33)|0,(~e>>>0>4294967295|(~e|0)==-1&~d>>>0>4294967263?~e:-1)|0)|0;fb(i+32+32|0,b|0,h+1|0)|0;k=fg(c|0,g|0,32,0)|0;Tf(i+32|0,i+32|0,k,z,f+16|0,i)|0;fb(a|0,i+32+32|0,h+1|0)|0}if(e>>>0>0|(e|0)==0&d>>>0>32){k=cg(d|0,e|0,c|0,g|0)|0;jf(a+c|0,b+c|0,k,z,f+16|0,1,0,i)|0}Sd(i,32);c=0}else{Sd(i,32);c=-1}l=j;return c|0}function Za(a,b){a=a|0;b=b|0;var c=0,e=0,f=0;f=l;c=l=l+63&-64;l=l+208|0;xa(a+40|0,b);Bf(a+80|0);qa(c+160|0,a+40|0);la(c+120|0,c+160|0,1152);Fb(c+160|0,c+160|0,a+80|0);Gb(c+120|0,c+120|0,a+80|0);qa(c+80|0,c+120|0);la(c+80|0,c+80|0,c+120|0);qa(a,c+80|0);la(a,a,c+120|0);la(a,a,c+160|0);Ha(a,a);la(a,a,c+80|0);la(a,a,c+160|0);qa(c+40|0,a);la(c+40|0,c+40|0,c+120|0);Fb(c,c+40|0,c+160|0);if(Ge(c)|0){Gb(c,c+40|0,c+160|0);if(!(Ge(c)|0)){la(a,a,1192);e=4}else a=-1}else e=4;if((e|0)==4){e=Ve(a)|0;if((e|0)==((d[b+31>>0]|0)>>>7|0))dc(a,a);la(a+120|0,a,a+40|0);a=0}l=f;return a|0}function _a(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;var m=0,n=0,o=0;o=af(j|0,0,i|0,0)|0;n=z;do if(n>>>0>0|(n|0)==0&o>>>0>1073741823){c[8326]=27;a=-1}else{if(h>>>0>0|(h|0)==0&g>>>0>4294967295){c[8326]=27;a=-1;break}o=fg(g|0,h|0,-1,-1)|0;if(h>>>0<0|(h|0)==0&g>>>0<2|((o&g|0)!=0|(z&h|0)!=0)){c[8326]=22;a=-1;break}if((i|0)==0|(j|0)==0){c[8326]=22;a=-1;break}if(!(i>>>0>16777215?1:(33554431/(j>>>0)|0)>>>0<i>>>0)?!(0<h>>>0|(0==(h|0)?(33554431/(i>>>0)|0)>>>0<g>>>0:0)):0){n=O(i<<7,j)|0;o=O(i<<7,g)|0;if((n+o|0)>>>0<o>>>0){c[8326]=12;a=-1;break}m=n+o+(i<<8|64)|0;if(m>>>0<(i<<8|64)>>>0){c[8326]=12;a=-1;break}if((c[a+8>>2]|0)>>>0<m>>>0?($g(a),(od(a,m)|0)==0):0){a=-1;break}m=c[a+4>>2]|0;cc(b,d,e,f,m,n);a=0;do{Xa(m+(O(i<<7,a)|0)|0,i,g,h,m+n|0,m+n+o|0);a=a+1|0}while((a|0)!=(j|0));cc(b,d,m,n,k,l);a=0;break}c[8326]=12;a=-1}while(0);return a|0}function $a(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0;j=l;i=l=l+63&-64;l=l+96|0;Ga(i,f,g,0)|0;xg(i+32|0,32,0,f+16|0,i)|0;if(!(Rf(c,b,d,e,i+32|0)|0))if(!a)c=0;else{if(b>>>0>=a>>>0?0<e>>>0|0==(e|0)&(b-a|0)>>>0<d>>>0:0)h=8;else if(a>>>0>=b>>>0?0<e>>>0|0==(e|0)&(a-b|0)>>>0<d>>>0:0)h=8;if((h|0)==8){Ed(a|0,b|0,d|0)|0;b=a}c=e>>>0>0|(e|0)==0&d>>>0>32?32:d;g=e>>>0>0|(e|0)==0&d>>>0>32?0:e;if((c|0)==0&(g|0)==0)Of(i+32|0,i+32|0,32,0,f+16|0,i)|0;else{h=cg(-2,-1,(~e>>>0>4294967295|(~e|0)==-1&~d>>>0>4294967263?~d:-33)|0,(~e>>>0>4294967295|(~e|0)==-1&~d>>>0>4294967263?~e:-1)|0)|0;fb(i+32+32|0,b|0,h+1|0)|0;k=fg(c|0,g|0,32,0)|0;Of(i+32|0,i+32|0,k,z,f+16|0,i)|0;fb(a|0,i+32+32|0,h+1|0)|0}if(e>>>0>0|(e|0)==0&d>>>0>32){k=cg(d|0,e|0,c|0,g|0)|0;ef(a+c|0,b+c|0,k,z,f+16|0,1,0,i)|0}Sd(i,32);c=0}else{Sd(i,32);c=-1}l=j;return c|0}function ab(b,c){b=b|0;c=c|0;var e=0,f=0,g=0,h=0,i=0;f=l;g=l=l+63&-64;l=l+464|0;e=0;do{i=a[c+e>>0]|0;h=e<<1;a[g+400+h>>0]=i&15;a[g+400+(h|1)>>0]=(i&255)>>>4;e=e+1|0}while((e|0)!=32);e=0;c=0;do{i=g+400+c|0;h=(d[i>>0]|0)+e|0;e=(h<<24)+134217728>>28;a[i>>0]=h-(e<<4);c=c+1|0}while((c|0)!=63);a[g+400+63>>0]=(d[g+400+63>>0]|0)+e;Ye(b);e=1;do{Jb(g,(e|0)/2|0,a[g+400+e>>0]|0);Wb(g+240|0,b,g);Id(b,g+240|0);e=e+2|0}while((e|0)<64);ye(g+240|0,b);ze(g+120|0,g+240|0);jc(g+240|0,g+120|0);ze(g+120|0,g+240|0);jc(g+240|0,g+120|0);ze(g+120|0,g+240|0);jc(g+240|0,g+120|0);Id(b,g+240|0);e=0;do{Jb(g,(e|0)/2|0,a[g+400+e>>0]|0);Wb(g+240|0,b,g);Id(b,g+240|0);e=e+2|0}while((e|0)<64);l=f;return}function bb(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0;x=c[a>>2]|0;v=c[a+4>>2]|0;t=c[a+8>>2]|0;r=c[a+12>>2]|0;p=c[a+16>>2]|0;n=c[a+20>>2]|0;l=c[a+24>>2]|0;j=c[a+28>>2]|0;h=c[a+32>>2]|0;f=c[a+36>>2]|0;w=c[b>>2]|0;u=c[b+4>>2]|0;s=c[b+8>>2]|0;q=c[b+12>>2]|0;o=c[b+16>>2]|0;m=c[b+20>>2]|0;k=c[b+24>>2]|0;i=c[b+28>>2]|0;g=c[b+32>>2]|0;e=c[b+36>>2]|0;c[a>>2]=(w^x)&0-d^x;c[a+4>>2]=(u^v)&0-d^v;c[a+8>>2]=(s^t)&0-d^t;c[a+12>>2]=(q^r)&0-d^r;c[a+16>>2]=(o^p)&0-d^p;c[a+20>>2]=(m^n)&0-d^n;c[a+24>>2]=(k^l)&0-d^l;c[a+28>>2]=(i^j)&0-d^j;c[a+32>>2]=(g^h)&0-d^h;c[a+36>>2]=(e^f)&0-d^f;c[b>>2]=(w^x)&0-d^w;c[b+4>>2]=(u^v)&0-d^u;c[b+8>>2]=(s^t)&0-d^s;c[b+12>>2]=(q^r)&0-d^q;c[b+16>>2]=(o^p)&0-d^o;c[b+20>>2]=(m^n)&0-d^m;c[b+24>>2]=(k^l)&0-d^k;c[b+28>>2]=(i^j)&0-d^i;c[b+32>>2]=(g^h)&0-d^g;c[b+36>>2]=(e^f)&0-d^e;return}function cb(b,e,f,g,h){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0,n=0,o=0,p=0;o=l;p=l=l+63&-64;l=l+112|0;if(!((e|0)==0&(f|0)==0)){j=p+16|0;i=j+32|0;do{a[j>>0]=a[h>>0]|0;j=j+1|0;h=h+1|0}while((j|0)<(i|0));j=d[g+4>>0]|d[g+4+1>>0]<<8|d[g+4+2>>0]<<16|d[g+4+3>>0]<<24;c[p>>2]=d[g>>0]|d[g+1>>0]<<8|d[g+2>>0]<<16|d[g+3>>0]<<24;c[p+4>>2]=j;c[p+8>>2]=0;c[p+8+4>>2]=0;if(f>>>0>0|(f|0)==0&e>>>0>63){do{Lg(b,p,p+16|0,0)|0;h=1;i=8;while(1){j=p+i|0;h=(d[j>>0]|0)+h|0;a[j>>0]=h;i=i+1|0;if((i|0)==16)break;else h=h>>>8}e=fg(e|0,f|0,-64,-1)|0;f=z;b=b+64|0}while(f>>>0>0|(f|0)==0&e>>>0>63);if(!((e|0)==0&(f|0)==0)){m=b;n=e;k=7}}else{m=b;n=e;k=7}if((k|0)==7?(Lg(p+48|0,p,p+16|0,0)|0,n|0):0){h=0;do{a[m+h>>0]=a[p+48+h>>0]|0;h=h+1|0}while((h|0)!=(n|0))}Sd(p+48|0,64);Sd(p+16|0,32)}l=o;return 0}function db(b,e,f,g,h){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0,n=0,o=0,p=0;o=l;p=l=l+63&-64;l=l+112|0;if(!((e|0)==0&(f|0)==0)){j=p+16|0;i=j+32|0;do{a[j>>0]=a[h>>0]|0;j=j+1|0;h=h+1|0}while((j|0)<(i|0));j=d[g+4>>0]|d[g+4+1>>0]<<8|d[g+4+2>>0]<<16|d[g+4+3>>0]<<24;c[p>>2]=d[g>>0]|d[g+1>>0]<<8|d[g+2>>0]<<16|d[g+3>>0]<<24;c[p+4>>2]=j;c[p+8>>2]=0;c[p+8+4>>2]=0;if(f>>>0>0|(f|0)==0&e>>>0>63){do{Ng(b,p,p+16|0,0)|0;h=1;i=8;while(1){j=p+i|0;h=(d[j>>0]|0)+h|0;a[j>>0]=h;i=i+1|0;if((i|0)==16)break;else h=h>>>8}e=fg(e|0,f|0,-64,-1)|0;f=z;b=b+64|0}while(f>>>0>0|(f|0)==0&e>>>0>63);if(!((e|0)==0&(f|0)==0)){m=b;n=e;k=7}}else{m=b;n=e;k=7}if((k|0)==7?(Ng(p+48|0,p,p+16|0,0)|0,n|0):0){h=0;do{a[m+h>>0]=a[p+48+h>>0]|0;h=h+1|0}while((h|0)!=(n|0))}Sd(p+48|0,64);Sd(p+16|0,32)}l=o;return 0}function eb(b,e,f,g,h){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0,n=0,o=0,p=0;o=l;p=l=l+63&-64;l=l+112|0;if(!((e|0)==0&(f|0)==0)){j=p+16|0;i=j+32|0;do{a[j>>0]=a[h>>0]|0;j=j+1|0;h=h+1|0}while((j|0)<(i|0));j=d[g+4>>0]|d[g+4+1>>0]<<8|d[g+4+2>>0]<<16|d[g+4+3>>0]<<24;c[p>>2]=d[g>>0]|d[g+1>>0]<<8|d[g+2>>0]<<16|d[g+3>>0]<<24;c[p+4>>2]=j;c[p+8>>2]=0;c[p+8+4>>2]=0;if(f>>>0>0|(f|0)==0&e>>>0>63){do{Og(b,p,p+16|0,0)|0;h=1;i=8;while(1){j=p+i|0;h=(d[j>>0]|0)+h|0;a[j>>0]=h;i=i+1|0;if((i|0)==16)break;else h=h>>>8}e=fg(e|0,f|0,-64,-1)|0;f=z;b=b+64|0}while(f>>>0>0|(f|0)==0&e>>>0>63);if(!((e|0)==0&(f|0)==0)){m=b;n=e;k=7}}else{m=b;n=e;k=7}if((k|0)==7?(Og(p+48|0,p,p+16|0,0)|0,n|0):0){h=0;do{a[m+h>>0]=a[p+48+h>>0]|0;h=h+1|0}while((h|0)!=(n|0))}Sd(p+48|0,64);Sd(p+16|0,32)}l=o;return 0}function fb(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0;if((e|0)>=8192)return $(b|0,d|0,e|0)|0;h=b|0;g=b+e|0;if((b&3)==(d&3)){while(b&3){if(!e)return h|0;a[b>>0]=a[d>>0]|0;b=b+1|0;d=d+1|0;e=e-1|0}e=g&-4|0;f=e-64|0;while((b|0)<=(f|0)){c[b>>2]=c[d>>2];c[b+4>>2]=c[d+4>>2];c[b+8>>2]=c[d+8>>2];c[b+12>>2]=c[d+12>>2];c[b+16>>2]=c[d+16>>2];c[b+20>>2]=c[d+20>>2];c[b+24>>2]=c[d+24>>2];c[b+28>>2]=c[d+28>>2];c[b+32>>2]=c[d+32>>2];c[b+36>>2]=c[d+36>>2];c[b+40>>2]=c[d+40>>2];c[b+44>>2]=c[d+44>>2];c[b+48>>2]=c[d+48>>2];c[b+52>>2]=c[d+52>>2];c[b+56>>2]=c[d+56>>2];c[b+60>>2]=c[d+60>>2];b=b+64|0;d=d+64|0}while((b|0)<(e|0)){c[b>>2]=c[d>>2];b=b+4|0;d=d+4|0}}else{e=g-4|0;while((b|0)<(e|0)){a[b>>0]=a[d>>0]|0;a[b+1>>0]=a[d+1>>0]|0;a[b+2>>0]=a[d+2>>0]|0;a[b+3>>0]=a[d+3>>0]|0;b=b+4|0;d=d+4|0}}while((b|0)<(g|0)){a[b>>0]=a[d>>0]|0;b=b+1|0;d=d+1|0}return h|0}function gb(a,b,e){a=a|0;b=b|0;e=e|0;var f=0,g=0,h=0,i=0,j=0;g=l;h=l=l+63&-64;l=l+4096|0;Eh(h+3072|0);Eh(h+2048|0);if((a|0)!=0&(b|0)!=0?(c[h+2048>>2]=c[b>>2],c[h+2048+4>>2]=0,c[h+2048+8>>2]=c[b+4>>2],c[h+2048+8+4>>2]=0,c[h+2048+16>>2]=d[b+8>>0],c[h+2048+16+4>>2]=0,c[h+2048+24>>2]=c[a+8>>2],c[h+2048+24+4>>2]=0,c[h+2048+32>>2]=c[a+4>>2],c[h+2048+32+4>>2]=0,c[h+2048+40>>2]=c[a+28>>2],c[h+2048+40+4>>2]=0,c[a+12>>2]|0):0){b=0;do{f=b&127;if(!f){i=fg(c[h+2048+48>>2]|0,c[h+2048+48+4>>2]|0,1,0)|0;c[h+2048+48>>2]=i;c[h+2048+48+4>>2]=z;Eh(h);Eh(h+1024|0);ma(h+3072|0,h+2048|0,h);ma(h+3072|0,h,h+1024|0)}j=c[h+1024+(f<<3)+4>>2]|0;i=e+(b<<3)|0;c[i>>2]=c[h+1024+(f<<3)>>2];c[i+4>>2]=j;b=b+1|0}while(b>>>0<(c[a+12>>2]|0)>>>0)}l=g;return}function hb(a){a=a|0;var b=0,d=0;do if(a)if(c[a>>2]|0)if((c[a+4>>2]|0)>>>0>=16){if((c[a+8>>2]|0)==0?c[a+12>>2]|0:0){b=-18;break}b=c[a+20>>2]|0;if((c[a+16>>2]|0)!=0|(b|0)==0)if(b>>>0>=8){if((c[a+24>>2]|0)==0?c[a+28>>2]|0:0){b=-20;break}if((c[a+32>>2]|0)==0?c[a+36>>2]|0:0){b=-21;break}b=c[a+44>>2]|0;if(b>>>0>=8)if(b>>>0<=2097152){d=c[a+48>>2]|0;if(b>>>0>=d<<3>>>0)if((c[a+40>>2]|0)>>>0>=3)if(d)if(d>>>0>16777215)b=-17;else{a=c[a+52>>2]|0;return ((a|0)==0?-28:a>>>0>16777215?-29:0)|0}else b=-16;else b=-12;else b=-14}else b=-15;else b=-14}else b=-6;else b=-19}else b=-2;else b=-1;else b=-25;while(0);return b|0}function ib(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0;k=l;j=l=l+63&-64;l=l+64|0;e=j+8|0;f=e+52|0;do{c[e>>2]=0;e=e+4|0}while((e|0)<(f|0));e=uc(a)|0;c[j+36>>2]=e;c[j+20>>2]=e;c[j+4>>2]=e;h=ia(e)|0;c[j+32>>2]=h;f=ia(e)|0;c[j+16>>2]=f;g=ia(e)|0;c[j>>2]=g;do if((f|0)==0|(g|0)==0|(h|0)==0){ra(h);ra(f);ra(g);e=-22}else{i=ia(e)|0;if(!i){ra(h);ra(f);ra(g);e=-22;break}e=Va(j,a)|0;if(e|0){ra(c[j+32>>2]|0);ra(c[j+16>>2]|0);ra(c[j>>2]|0);ra(i);break}d=ub(c[j+40>>2]|0,c[j+44>>2]|0,c[j+52>>2]|0,b,d,c[j+16>>2]|0,c[j+20>>2]|0,i,c[j+4>>2]|0,0,0)|0;ra(c[j+32>>2]|0);ra(c[j+16>>2]|0);if((d|0)==0?(Qc(i,c[j>>2]|0,c[j+4>>2]|0)|0)==0:0)e=0;else e=-35;ra(i);ra(c[j>>2]|0)}while(0);l=k;return e|0}function jb(a,b,d,e,f,g){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0;i=b>>>0>0|(b|0)==0&a>>>0>32768?a:32768;h=b>>>0>0|(b|0)==0&a>>>0>32768?b:0;c[g>>2]=8;a:do if(h>>>0<0|(h|0)==0&i>>>0<d>>>5>>>0){c[f>>2]=1;a=ah(i|0,h|0,c[g>>2]<<2|0,0)|0;c[e>>2]=1;a=yf(a|0,z|0,1)|0;b=z;h=1;do{g=vf(1,0,h|0)|0;f=z;h=h+1|0;if(f>>>0>b>>>0|(f|0)==(b|0)&g>>>0>a>>>0)break a;c[e>>2]=h}while(h>>>0<63)}else{c[e>>2]=1;a=1;b=1;while(1){j=vf(1,0,a|0)|0;k=z;b=b+1|0;if(k>>>0>0|(k|0)==0&j>>>0>d>>>11>>>0)break;c[e>>2]=b;if(b>>>0>=63){a=b;break}else a=b}e=yf(i|0,h|0,2)|0;e=yf(e|0,z|0,a|0)|0;j=z;k=j>>>0<0|(j|0)==0&e>>>0<1073741823?e:1073741823;c[f>>2]=(k>>>0)/((c[g>>2]|0)>>>0)|0}while(0);return}function kb(b,e,f,g,h,i,j){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;var k=0,l=0,m=0,n=0,o=0,p=0;a:do if(!g){n=0;l=0;m=0;k=0}else{k=0;n=0;l=0;p=0;while(1){while(1){m=d[f+l>>0]|0;o=(((m&223)+201&255)+65526^((m&223)+201&255)+65520)>>>8;if((o|((m^48)+65526|0)>>>8)&255|0)break;if(!((h|0)!=0&k<<24>>24==0)){m=0;break a}if(!(Kg(h,m)|0)){m=0;k=0;break a}l=l+1|0;if(l>>>0<g>>>0)k=0;else{m=0;k=0;break a}}if(n>>>0>=e>>>0)break;m=(m&223)+201&255&o|((m^48)+65526|0)>>>8&(m^48);if(!(k<<24>>24))m=m<<4&255;else{a[b+n>>0]=m|p&255;n=n+1|0;m=p}k=~k;l=l+1|0;if(l>>>0<g>>>0)p=m;else{m=0;break a}}c[8326]=34;m=-1}while(0);if(j|0)c[j>>2]=f+(((k<<24>>24!=0)<<31>>31)+l);if(i|0)c[i>>2]=n;return m|0}function lb(a,b,c,d,e,f,g,h,i,j,k){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;var m=0;m=l;l=l+352|0;pg(m+280|0,64,0,j,k)|0;_g(m,m+280|0)|0;Sd(m+280|0,64);eg(m,g,h,i)|0;b=cg(0,0,h|0,i|0)|0;eg(m,35896,b&15,0)|0;eg(m,c,d,e)|0;b=cg(0,0,d|0,e|0)|0;eg(m,35896,b&15,0)|0;re(m+272|0,h,i);eg(m,m+272|0,8,0)|0;re(m+272|0,d,e);eg(m,m+272|0,8,0)|0;Zg(m,m+256|0)|0;Sd(m,256);b=Oe(m+256|0,f)|0;Sd(m+256|0,16);do if(a)if(!b){pf(a,c,d,e,j,1,k)|0;b=0;break}else{Pb(a|0,0,d|0)|0;b=-1;break}while(0);l=m;return b|0}function mb(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0;a:do if((e|0)!=0&(b&3|0)!=0){f=e;while(1){if((a[b>>0]|0)==(d&255)<<24>>24)break a;b=b+1|0;e=f+-1|0;if((e|0)!=0&(b&3|0)!=0)f=e;else{f=e;e=(e|0)!=0;g=5;break}}}else{f=e;e=(e|0)!=0;g=5}while(0);b:do if((g|0)==5)if(e){if((a[b>>0]|0)!=(d&255)<<24>>24){e=O(d&255,16843009)|0;c:do if(f>>>0>3)while(1){h=c[b>>2]^e;if((h&-2139062144^-2139062144)&h+-16843009|0)break;b=b+4|0;f=f+-4|0;if(f>>>0<=3){g=11;break c}}else g=11;while(0);if((g|0)==11)if(!f){f=0;break}while(1){if((a[b>>0]|0)==(d&255)<<24>>24)break b;b=b+1|0;f=f+-1|0;if(!f){f=0;break}}}}else f=0;while(0);return (f|0?b:0)|0}function nb(b,c,d,e,f,g){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0;i=l;j=l=l+63&-64;l=l+192|0;if((c+-1&255)>63)Z();if((d|0)!=0&e<<24>>24!=0?(e&255)<=64:0){a[j+128>>0]=c;a[j+128+1>>0]=e;a[j+128+2>>0]=1;a[j+128+3>>0]=1;Vg(j+128+4|0);bf(j+128+8|0);c=j+128+16|0;h=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(h|0));if(!f){c=j+128+32|0;h=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(h|0))}else lf(j+128|0,f);if(!g){c=j+128+48|0;h=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(h|0))}else kf(j+128|0,g);ud(b,j+128|0);Pb(j+(e&255)|0,0,128-(e&255)|0)|0;fb(j|0,d|0,e&255|0)|0;Bb(b,j,128,0);Sd(j,128);l=i;return}Z()}function ob(a){a=a|0;var b=0,d=0,e=0,f=0;if(a>>>0>=4294967168){c[8326]=12;f=0;return f|0}f=a>>>0<11?16:a+11&-8;e=ia(f+76|0)|0;if(!e){f=0;return f|0}do if(e&63){d=((e+63&-64)+-8-(e+-8)|0)>>>0>15?(e+63&-64)+-8|0:(e+63&-64)+56|0;a=d-(e+-8)|0;b=c[e+-4>>2]|0;if(!(b&3)){c[d>>2]=(c[e+-8>>2]|0)+a;c[d+4>>2]=(b&-8)-a;a=d;break}else{c[d+4>>2]=(b&-8)-a|c[d+4>>2]&1|2;c[d+((b&-8)-a)+4>>2]=c[d+((b&-8)-a)+4>>2]|1;c[e+-4>>2]=a|c[e+-4>>2]&1|2;c[d+4>>2]=c[d+4>>2]|1;sa(e+-8|0,a);a=d;break}}else{a=e+-8|0;d=e+-8|0}while(0);a=a+4|0;b=c[a>>2]|0;if(b&3|0?(b&-8)>>>0>(f+16|0)>>>0:0){e=d+f|0;c[a>>2]=f|b&1|2;c[e+4>>2]=(b&-8)-f|3;c[e+((b&-8)-f)+4>>2]=c[e+((b&-8)-f)+4>>2]|1;sa(e,(b&-8)-f|0)}f=d+8|0;return f|0}function pb(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0;h=l;l=l+192|0;if(d>>>0>128){me(b)|0;Ea(b,c,d,0)|0;Be(b,h)|0;d=64;c=h}me(b)|0;e=h+64|0;f=e+128|0;do{a[e>>0]=54;e=e+1|0}while((e|0)<(f|0));g=(d|0)==0;if(!g?(a[h+64>>0]=a[c>>0]^54,(d|0)!=1):0){e=1;do{f=h+64+e|0;a[f>>0]=a[f>>0]^a[c+e>>0];e=e+1|0}while((e|0)!=(d|0))}Ea(b,h+64|0,128,0)|0;me(b+208|0)|0;e=h+64|0;f=e+128|0;do{a[e>>0]=92;e=e+1|0}while((e|0)<(f|0));if(!g?(a[h+64>>0]=a[c>>0]^92,(d|0)!=1):0){e=1;do{g=h+64+e|0;a[g>>0]=a[g>>0]^a[c+e>>0];e=e+1|0}while((e|0)!=(d|0))}Ea(b+208|0,h+64|0,128,0)|0;Sd(h+64|0,128);Sd(h,64);l=h;return 0}function qb(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0;h=l;l=l+96|0;if(d>>>0>64){td(b)|0;La(b,c,d,0)|0;Fe(b,h)|0;d=32;c=h}td(b)|0;e=h+32|0;f=e+64|0;do{a[e>>0]=54;e=e+1|0}while((e|0)<(f|0));g=(d|0)==0;if(!g?(a[h+32>>0]=a[c>>0]^54,(d|0)!=1):0){e=1;do{f=h+32+e|0;a[f>>0]=a[f>>0]^a[c+e>>0];e=e+1|0}while((e|0)!=(d|0))}La(b,h+32|0,64,0)|0;td(b+104|0)|0;e=h+32|0;f=e+64|0;do{a[e>>0]=92;e=e+1|0}while((e|0)<(f|0));if(!g?(a[h+32>>0]=a[c>>0]^92,(d|0)!=1):0){e=1;do{g=h+32+e|0;a[g>>0]=a[g>>0]^a[c+e>>0];e=e+1|0}while((e|0)!=(d|0))}La(b+104|0,h+32|0,64,0)|0;Sd(h+32|0,64);Sd(h,32);l=h;return 0}function rb(b,c){b=b|0;c=c|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+16|0;Ce(f,b);a[b>>0]=a[f+(d[c>>0]|0)>>0]|0;a[b+1>>0]=a[f+(d[c+1>>0]|0)>>0]|0;a[b+2>>0]=a[f+(d[c+2>>0]|0)>>0]|0;a[b+3>>0]=a[f+(d[c+3>>0]|0)>>0]|0;a[b+4>>0]=a[f+(d[c+4>>0]|0)>>0]|0;a[b+5>>0]=a[f+(d[c+5>>0]|0)>>0]|0;a[b+6>>0]=a[f+(d[c+6>>0]|0)>>0]|0;a[b+7>>0]=a[f+(d[c+7>>0]|0)>>0]|0;a[b+8>>0]=a[f+(d[c+8>>0]|0)>>0]|0;a[b+9>>0]=a[f+(d[c+9>>0]|0)>>0]|0;a[b+10>>0]=a[f+(d[c+10>>0]|0)>>0]|0;a[b+11>>0]=a[f+(d[c+11>>0]|0)>>0]|0;a[b+12>>0]=a[f+(d[c+12>>0]|0)>>0]|0;a[b+13>>0]=a[f+(d[c+13>>0]|0)>>0]|0;a[b+14>>0]=a[f+(d[c+14>>0]|0)>>0]|0;a[b+15>>0]=a[f+(d[c+15>>0]|0)>>0]|0;l=e;return}function sb(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0;w=c[a>>2]|0;u=c[a+4>>2]|0;s=c[a+8>>2]|0;q=c[a+12>>2]|0;o=c[a+16>>2]|0;m=c[a+20>>2]|0;k=c[a+24>>2]|0;i=c[a+28>>2]|0;g=c[a+32>>2]|0;e=c[a+36>>2]|0;v=(c[b+4>>2]^u)&0-d;t=(c[b+8>>2]^s)&0-d;r=(c[b+12>>2]^q)&0-d;p=(c[b+16>>2]^o)&0-d;n=(c[b+20>>2]^m)&0-d;l=(c[b+24>>2]^k)&0-d;j=(c[b+28>>2]^i)&0-d;h=(c[b+32>>2]^g)&0-d;f=(c[b+36>>2]^e)&0-d;c[a>>2]=(c[b>>2]^w)&0-d^w;c[a+4>>2]=v^u;c[a+8>>2]=t^s;c[a+12>>2]=r^q;c[a+16>>2]=p^o;c[a+20>>2]=n^m;c[a+24>>2]=l^k;c[a+28>>2]=j^i;c[a+32>>2]=h^g;c[a+36>>2]=f^e;return}function tb(b,d,e,f,g,h,i){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0;j=l;k=l=l+63&-64;l=l+560|0;de(k+496|0,h,32,0)|0;a[k+496>>0]=a[k+496>>0]&-8;a[k+496+31>>0]=a[k+496+31>>0]&63|64;ag(k,i);Ea(k,k+496+32|0,32,0)|0;Ea(k,e,f,g)|0;Be(k,k+432|0)|0;Ed(b+32|0,h+32|0,32)|0;ka(k+432|0);ab(k+208|0,k+432|0);Ic(b,k+208|0);ag(k,i);Ea(k,b,64,0)|0;Ea(k,e,f,g)|0;Be(k,k+368|0)|0;ka(k+368|0);ha(b+32|0,k+368|0,k+496|0,k+432|0);Sd(k+496|0,64);if(d|0){c[d>>2]=64;c[d+4>>2]=0}l=j;return}function ub(a,b,d,e,f,g,h,i,j,k,m){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;var n=0,o=0,p=0;p=l;o=l=l+63&-64;l=l+64|0;n=ia(j)|0;do if(!n)a=-22;else{c[o>>2]=n;c[o+4>>2]=j;c[o+8>>2]=e;c[o+12>>2]=f;c[o+16>>2]=g;c[o+20>>2]=h;c[o+24>>2]=0;c[o+24+4>>2]=0;c[o+24+8>>2]=0;c[o+24+12>>2]=0;c[o+40>>2]=a;c[o+44>>2]=b;c[o+48>>2]=d;c[o+52>>2]=d;c[o+56>>2]=4;a=$b(o)|0;if(a|0){Sd(n,j);ra(n);break}if(i|0)fb(i|0,n|0,j|0)|0;if((k|0)!=0&(m|0)!=0?Ia(k,m,o)|0:0){Sd(n,j);Sd(k,m);ra(n);a=-31;break}Sd(n,j);ra(n);a=0}while(0);l=p;return a|0}function vb(a,b,c,e,f,g){a=a|0;b=b|0;c=c|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0;k=l;j=l=l+63&-64;l=l+592|0;if(((nd(a+32|0)|0)==0?(xd(a)|0)==0:0)?(Za(j+328|0,f)|0)==0:0){h=0;i=0;do{i=d[f+h>>0]|0|i;h=h+1|0}while((h|0)!=32);if(i){ag(j,g);Ea(j,a,32,0)|0;Ea(j,f,32,0)|0;Ea(j,b,c,e)|0;Be(j,j+520|0)|0;ka(j+520|0);Ba(j+208|0,j+520|0,j+328|0,a+32|0);Ic(j+488|0,j+208|0);h=Ne(j+488|0,a)|0;h=((j+488|0)==(a|0)?-1:h)|(Qc(a,j+488|0,32)|0)}else h=-1}else h=-1;l=k;return h|0}function wb(b,d,e,f,g){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0;p=l;o=l=l+63&-64;l=l+48|0;if((((((a[f>>0]|0)==36?(a[f+1>>0]|0)==55:0)?(a[f+2>>0]|0)==36:0)?(_f(o+8|0,a[f+3>>0]|0)|0)==0:0)?(j=vf(1,0,c[o+8>>2]|0)|0,k=z,h=Tc(o+4|0,f+4|0)|0,(h|0)!=0):0)?(m=Tc(o,h)|0,(m|0)!=0):0){h=Bh(m)|0;if(!h)h=uc(m)|0;else h=h-m|0;i=h+(m-f)|0;if((!((i+45|0)>>>0>102|(i+45|0)>>>0<h>>>0)?(_a(b,d,e,m,h,j,k,c[o+4>>2]|0,c[o>>2]|0,o+16|0,32)|0)==0:0)?(fb(g|0,f|0,i|0)|0,a[g+i>>0]=36,n=Rc(g+i+1|0,g+102-(g+i+1)|0,o+16|0)|0,Sd(o+16|0,32),(n|0)!=0&n>>>0<(g+102|0)>>>0):0)a[n>>0]=0;else g=0}else g=0;l=p;return g|0}function xb(b){b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0;j=l;i=l=l+63&-64;l=l+32|0;a:do if(((b|0)!=0?(d=c[b+20>>2]|0,(d|0)!=0):0)?(c[b+4>>2]|0)!=0:0){h=0;while(1){g=0;do{if(!d)d=0;else{f=g&255;e=0;do{c[i>>2]=h;c[i+4>>2]=e;a[i+8>>0]=f;c[i+12>>2]=0;c[i+16>>2]=c[i>>2];c[i+16+4>>2]=c[i+4>>2];c[i+16+8>>2]=c[i+8>>2];c[i+16+12>>2]=c[i+12>>2];d=Wa(b,i+16|0)|0;e=e+1|0;if(d|0)break a;d=c[b+20>>2]|0}while(e>>>0<d>>>0)}g=g+1|0}while(g>>>0<4);h=h+1|0;if(h>>>0>=(c[b+4>>2]|0)>>>0){d=0;break}}}else d=0;while(0);l=j;return d|0}function yb(a,b,d,e,f,g,h,i,j,k,m,n){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;n=n|0;k=l;l=l+336|0;pg(k+264|0,64,0,m,n)|0;_g(k,k+264|0)|0;Sd(k+264|0,64);eg(k,h,i,j)|0;h=cg(0,0,i|0,j|0)|0;eg(k,35896,h&15,0)|0;pf(a,e,f,g,m,1,n)|0;eg(k,a,f,g)|0;h=cg(0,0,f|0,g|0)|0;eg(k,35896,h&15,0)|0;re(k+256|0,i,j);eg(k,k+256|0,8,0)|0;re(k+256|0,f,g);eg(k,k+256|0,8,0)|0;Zg(k,b)|0;Sd(k,256);if(d|0){c[d>>2]=16;c[d+4>>2]=0}l=k;return 0}function zb(a,b,c,d,e,f,g,h,i,j,k){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;var m=0;m=l;l=l+352|0;Cg(m+280|0,64,0,j,k)|0;_g(m,m+280|0)|0;Sd(m+280|0,64);eg(m,g,h,i)|0;re(m+272|0,h,i);eg(m,m+272|0,8,0)|0;eg(m,c,d,e)|0;re(m+272|0,d,e);eg(m,m+272|0,8,0)|0;Zg(m,m+256|0)|0;Sd(m,256);b=Oe(m+256|0,f)|0;Sd(m+256|0,16);do if(a)if(!b){jf(a,c,d,e,j,1,0,k)|0;b=0;break}else{Pb(a|0,0,d|0)|0;b=-1;break}while(0);l=m;return b|0} +function da(a,b){a=a|0;b=b|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+272|0;c[e+256>>2]=c[b>>2];c[e+256+4>>2]=c[b+4>>2];c[e+256+8>>2]=c[b+8>>2];c[e+256+12>>2]=c[b+12>>2];rb(e+256|0,35222);Ce(e+240|0,e+256|0);Ce(e+224|0,e+256|0);Ce(e+208|0,e+256|0);Ce(e+192|0,e+256|0);Ce(e+176|0,e+256|0);Ce(e+160|0,e+256|0);Ce(e+144|0,e+256|0);Ce(e,e+160|0);_d(e,1);Gd(e,e+144|0);Hd(e,1104);Gd(e+144|0,e);ae(e,1);Gd(e+160|0,e);Ce(e,e+192|0);_d(e,1);Gd(e,e+176|0);Hd(e,1104);Gd(e+176|0,e);ae(e,1);Gd(e+192|0,e);Ce(e,e+224|0);_d(e,1);Gd(e,e+208|0);Hd(e,1104);Gd(e+208|0,e);ae(e,1);Gd(e+224|0,e);Ce(e,e+256|0);_d(e,1);Gd(e,e+240|0);Hd(e,1104);Gd(e+240|0,e);ae(e,1);Gd(e+256|0,e);Ce(e,e+176|0);_d(e,2);Gd(e,e+144|0);Hd(e,1120);Gd(e+144|0,e);ae(e,2);Gd(e+176|0,e);Ce(e,e+192|0);_d(e,2);Gd(e,e+160|0);Hd(e,1120);Gd(e+160|0,e);ae(e,2);Gd(e+192|0,e);Ce(e,e+240|0);_d(e,2);Gd(e,e+208|0);Hd(e,1120);Gd(e+208|0,e);ae(e,2);Gd(e+240|0,e);Ce(e,e+256|0);_d(e,2);Gd(e,e+224|0);Hd(e,1120);Gd(e+224|0,e);ae(e,2);Gd(e+256|0,e);Ce(e,e+208|0);_d(e,4);Gd(e,e+144|0);Hd(e,1136);Gd(e+144|0,e);ae(e,4);Gd(e+208|0,e);Ce(e,e+224|0);_d(e,4);Gd(e,e+160|0);Hd(e,1136);Gd(e+160|0,e);ae(e,4);Gd(e+224|0,e);Ce(e,e+240|0);_d(e,4);Gd(e,e+176|0);Hd(e,1136);Gd(e+176|0,e);ae(e,4);Gd(e+240|0,e);Ce(e,e+256|0);_d(e,4);Gd(e,e+192|0);Hd(e,1136);Gd(e+192|0,e);ae(e,4);Gd(e+256|0,e);c[a>>2]=c[e+256>>2];c[a+4>>2]=c[e+256+4>>2];c[a+8>>2]=c[e+256+8>>2];c[a+12>>2]=c[e+256+12>>2];c[a+16>>2]=c[e+240>>2];c[a+16+4>>2]=c[e+240+4>>2];c[a+16+8>>2]=c[e+240+8>>2];c[a+16+12>>2]=c[e+240+12>>2];c[a+32>>2]=c[e+224>>2];c[a+32+4>>2]=c[e+224+4>>2];c[a+32+8>>2]=c[e+224+8>>2];c[a+32+12>>2]=c[e+224+12>>2];c[a+48>>2]=c[e+208>>2];c[a+48+4>>2]=c[e+208+4>>2];c[a+48+8>>2]=c[e+208+8>>2];c[a+48+12>>2]=c[e+208+12>>2];c[a+64>>2]=c[e+192>>2];c[a+64+4>>2]=c[e+192+4>>2];c[a+64+8>>2]=c[e+192+8>>2];c[a+64+12>>2]=c[e+192+12>>2];c[a+80>>2]=c[e+176>>2];c[a+80+4>>2]=c[e+176+4>>2];c[a+80+8>>2]=c[e+176+8>>2];c[a+80+12>>2]=c[e+176+12>>2];c[a+96>>2]=c[e+160>>2];c[a+96+4>>2]=c[e+160+4>>2];c[a+96+8>>2]=c[e+160+8>>2];c[a+96+12>>2]=c[e+160+12>>2];c[a+112>>2]=c[e+144>>2];c[a+112+4>>2]=c[e+144+4>>2];c[a+112+8>>2]=c[e+144+8>>2];c[a+112+12>>2]=c[e+144+12>>2];rb(e+256|0,35206);rb(e+240|0,35206);rb(e+224|0,35206);rb(e+208|0,35206);rb(e+192|0,35206);rb(e+176|0,35206);rb(e+160|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+160|0);Gd(e+224|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+160|0,e+224|0);Gd(e+208|0,e+256|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+144|0);Gd(e+208|0,e+192|0);Gd(e+144|0,e+176|0);Gd(e+208|0,e+240|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+224|0);Ce(e+64|0,e+160|0);Gd(e+80|0,e+192|0);Gd(e+96|0,e+224|0);Gd(e+112|0,e+208|0);Gd(e+48|0,e+192|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+208|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+160|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+224|0);Ce(e+48|0,e+192|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+208|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+160|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+160|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+176|0);Hd(e+160|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+160|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+208|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+208|0);Hd(e+256|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+256|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+160|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+208|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+192|0);Gd(e+128|0,e+224|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+224|0);Hd(e+192|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+192|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+224|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+160|0);Gd(e+192|0,e+144|0);Gd(e+160|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+224|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+208|0);Gd(e+208|0,e+176|0);Gd(e+160|0,e+208|0);dh(e+256|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+192|0,35238);rb(e+160|0,35238);rb(e+208|0,35238);rb(e+144|0,35238);rb(e+224|0,35238);rb(e+176|0,35238);rb(e+256|0,35238);c[e+128>>2]=c[a>>2];c[e+128+4>>2]=c[a+4>>2];c[e+128+8>>2]=c[a+8>>2];c[e+128+12>>2]=c[a+12>>2];c[e+112>>2]=c[a+16>>2];c[e+112+4>>2]=c[a+16+4>>2];c[e+112+8>>2]=c[a+16+8>>2];c[e+112+12>>2]=c[a+16+12>>2];c[e+96>>2]=c[a+32>>2];c[e+96+4>>2]=c[a+32+4>>2];c[e+96+8>>2]=c[a+32+8>>2];c[e+96+12>>2]=c[a+32+12>>2];c[e+80>>2]=c[a+48>>2];c[e+80+4>>2]=c[a+48+4>>2];c[e+80+8>>2]=c[a+48+8>>2];c[e+80+12>>2]=c[a+48+12>>2];c[e+64>>2]=c[a+64>>2];c[e+64+4>>2]=c[a+64+4>>2];c[e+64+8>>2]=c[a+64+8>>2];c[e+64+12>>2]=c[a+64+12>>2];c[e+48>>2]=c[a+80>>2];c[e+48+4>>2]=c[a+80+4>>2];c[e+48+8>>2]=c[a+80+8>>2];c[e+48+12>>2]=c[a+80+12>>2];c[e+32>>2]=c[a+96>>2];c[e+32+4>>2]=c[a+96+4>>2];c[e+32+8>>2]=c[a+96+8>>2];c[e+32+12>>2]=c[a+96+12>>2];c[e+16>>2]=c[a+112>>2];c[e+16+4>>2]=c[a+112+4>>2];c[e+16+8>>2]=c[a+112+8>>2];c[e+16+12>>2]=c[a+112+12>>2];Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);c[a+128>>2]=c[e+256>>2];c[a+128+4>>2]=c[e+256+4>>2];c[a+128+8>>2]=c[e+256+8>>2];c[a+128+12>>2]=c[e+256+12>>2];c[a+144>>2]=c[e+240>>2];c[a+144+4>>2]=c[e+240+4>>2];c[a+144+8>>2]=c[e+240+8>>2];c[a+144+12>>2]=c[e+240+12>>2];c[a+160>>2]=c[e+192>>2];c[a+160+4>>2]=c[e+192+4>>2];c[a+160+8>>2]=c[e+192+8>>2];c[a+160+12>>2]=c[e+192+12>>2];c[a+176>>2]=c[e+160>>2];c[a+176+4>>2]=c[e+160+4>>2];c[a+176+8>>2]=c[e+160+8>>2];c[a+176+12>>2]=c[e+160+12>>2];c[a+192>>2]=c[e+208>>2];c[a+192+4>>2]=c[e+208+4>>2];c[a+192+8>>2]=c[e+208+8>>2];c[a+192+12>>2]=c[e+208+12>>2];c[a+208>>2]=c[e+144>>2];c[a+208+4>>2]=c[e+144+4>>2];c[a+208+8>>2]=c[e+144+8>>2];c[a+208+12>>2]=c[e+144+12>>2];c[a+224>>2]=c[e+224>>2];c[a+224+4>>2]=c[e+224+4>>2];c[a+224+8>>2]=c[e+224+8>>2];c[a+224+12>>2]=c[e+224+12>>2];c[a+240>>2]=c[e+176>>2];c[a+240+4>>2]=c[e+176+4>>2];c[a+240+8>>2]=c[e+176+8>>2];c[a+240+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+224|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+192|0,35206);rb(e+160|0,35206);rb(e+208|0,35206);rb(e+144|0,35206);rb(e+224|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+224|0);Gd(e+192|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+224|0,e+192|0);Gd(e+160|0,e+256|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+176|0);Gd(e+160|0,e+208|0);Gd(e+176|0,e+144|0);Gd(e+160|0,e+240|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+192|0);Ce(e+64|0,e+224|0);Gd(e+80|0,e+208|0);Gd(e+96|0,e+192|0);Gd(e+112|0,e+160|0);Gd(e+48|0,e+208|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+160|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+224|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+192|0);Ce(e+48|0,e+208|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+160|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+224|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+224|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+144|0);Hd(e+224|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+224|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+160|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+160|0);Hd(e+256|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+256|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+224|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+160|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+208|0);Gd(e+128|0,e+192|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+192|0);Hd(e+208|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+208|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+192|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+224|0);Gd(e+208|0,e+176|0);Gd(e+224|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+192|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+160|0);Gd(e+160|0,e+144|0);Gd(e+224|0,e+160|0);dh(e+240|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+208|0,35238);rb(e+224|0,35238);rb(e+160|0,35238);rb(e+176|0,35238);rb(e+192|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+128>>2];c[e+128+4>>2]=c[a+128+4>>2];c[e+128+8>>2]=c[a+128+8>>2];c[e+128+12>>2]=c[a+128+12>>2];c[e+112>>2]=c[a+144>>2];c[e+112+4>>2]=c[a+144+4>>2];c[e+112+8>>2]=c[a+144+8>>2];c[e+112+12>>2]=c[a+144+12>>2];c[e+96>>2]=c[a+160>>2];c[e+96+4>>2]=c[a+160+4>>2];c[e+96+8>>2]=c[a+160+8>>2];c[e+96+12>>2]=c[a+160+12>>2];c[e+80>>2]=c[a+176>>2];c[e+80+4>>2]=c[a+176+4>>2];c[e+80+8>>2]=c[a+176+8>>2];c[e+80+12>>2]=c[a+176+12>>2];c[e+64>>2]=c[a+192>>2];c[e+64+4>>2]=c[a+192+4>>2];c[e+64+8>>2]=c[a+192+8>>2];c[e+64+12>>2]=c[a+192+12>>2];c[e+48>>2]=c[a+208>>2];c[e+48+4>>2]=c[a+208+4>>2];c[e+48+8>>2]=c[a+208+8>>2];c[e+48+12>>2]=c[a+208+12>>2];c[e+32>>2]=c[a+224>>2];c[e+32+4>>2]=c[a+224+4>>2];c[e+32+8>>2]=c[a+224+8>>2];c[e+32+12>>2]=c[a+224+12>>2];c[e+16>>2]=c[a+240>>2];c[e+16+4>>2]=c[a+240+4>>2];c[e+16+8>>2]=c[a+240+8>>2];c[e+16+12>>2]=c[a+240+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);c[a+256>>2]=c[e+256>>2];c[a+256+4>>2]=c[e+256+4>>2];c[a+256+8>>2]=c[e+256+8>>2];c[a+256+12>>2]=c[e+256+12>>2];c[a+272>>2]=c[e+240>>2];c[a+272+4>>2]=c[e+240+4>>2];c[a+272+8>>2]=c[e+240+8>>2];c[a+272+12>>2]=c[e+240+12>>2];c[a+288>>2]=c[e+208>>2];c[a+288+4>>2]=c[e+208+4>>2];c[a+288+8>>2]=c[e+208+8>>2];c[a+288+12>>2]=c[e+208+12>>2];c[a+304>>2]=c[e+224>>2];c[a+304+4>>2]=c[e+224+4>>2];c[a+304+8>>2]=c[e+224+8>>2];c[a+304+12>>2]=c[e+224+12>>2];c[a+320>>2]=c[e+160>>2];c[a+320+4>>2]=c[e+160+4>>2];c[a+320+8>>2]=c[e+160+8>>2];c[a+320+12>>2]=c[e+160+12>>2];c[a+336>>2]=c[e+176>>2];c[a+336+4>>2]=c[e+176+4>>2];c[a+336+8>>2]=c[e+176+8>>2];c[a+336+12>>2]=c[e+176+12>>2];c[a+352>>2]=c[e+192>>2];c[a+352+4>>2]=c[e+192+4>>2];c[a+352+8>>2]=c[e+192+8>>2];c[a+352+12>>2]=c[e+192+12>>2];c[a+368>>2]=c[e+144>>2];c[a+368+4>>2]=c[e+144+4>>2];c[a+368+8>>2]=c[e+144+8>>2];c[a+368+12>>2]=c[e+144+12>>2];Le(e+256|0);Le(e+240|0);Le(e+176|0);Le(e+192|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+208|0,35206);rb(e+224|0,35206);rb(e+160|0,35206);rb(e+176|0,35206);rb(e+192|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+192|0);Gd(e+208|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+192|0,e+208|0);Gd(e+224|0,e+256|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+144|0);Gd(e+224|0,e+160|0);Gd(e+144|0,e+176|0);Gd(e+224|0,e+240|0);Gd(e+160|0,e+176|0);Gd(e+208|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+208|0);Ce(e+64|0,e+192|0);Gd(e+80|0,e+160|0);Gd(e+96|0,e+208|0);Gd(e+112|0,e+224|0);Gd(e+48|0,e+160|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+224|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+192|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+208|0);Ce(e+48|0,e+160|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+224|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+192|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+192|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+176|0);Hd(e+192|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+192|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+224|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+224|0);Hd(e+256|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+256|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+192|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+224|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+160|0);Gd(e+128|0,e+208|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+208|0);Hd(e+160|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+160|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+208|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+192|0);Gd(e+160|0,e+144|0);Gd(e+192|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+208|0);Gd(e+160|0,e+176|0);Gd(e+208|0,e+224|0);Gd(e+224|0,e+176|0);Gd(e+192|0,e+224|0);dh(e+160|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+160|0,35238);rb(e+192|0,35238);rb(e+224|0,35238);rb(e+144|0,35238);rb(e+208|0,35238);rb(e+176|0,35238);c[e+128>>2]=c[a+256>>2];c[e+128+4>>2]=c[a+256+4>>2];c[e+128+8>>2]=c[a+256+8>>2];c[e+128+12>>2]=c[a+256+12>>2];c[e+112>>2]=c[a+272>>2];c[e+112+4>>2]=c[a+272+4>>2];c[e+112+8>>2]=c[a+272+8>>2];c[e+112+12>>2]=c[a+272+12>>2];c[e+96>>2]=c[a+288>>2];c[e+96+4>>2]=c[a+288+4>>2];c[e+96+8>>2]=c[a+288+8>>2];c[e+96+12>>2]=c[a+288+12>>2];c[e+80>>2]=c[a+304>>2];c[e+80+4>>2]=c[a+304+4>>2];c[e+80+8>>2]=c[a+304+8>>2];c[e+80+12>>2]=c[a+304+12>>2];c[e+64>>2]=c[a+320>>2];c[e+64+4>>2]=c[a+320+4>>2];c[e+64+8>>2]=c[a+320+8>>2];c[e+64+12>>2]=c[a+320+12>>2];c[e+48>>2]=c[a+336>>2];c[e+48+4>>2]=c[a+336+4>>2];c[e+48+8>>2]=c[a+336+8>>2];c[e+48+12>>2]=c[a+336+12>>2];c[e+32>>2]=c[a+352>>2];c[e+32+4>>2]=c[a+352+4>>2];c[e+32+8>>2]=c[a+352+8>>2];c[e+32+12>>2]=c[a+352+12>>2];c[e+16>>2]=c[a+368>>2];c[e+16+4>>2]=c[a+368+4>>2];c[e+16+8>>2]=c[a+368+8>>2];c[e+16+12>>2]=c[a+368+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);c[a+384>>2]=c[e+256>>2];c[a+384+4>>2]=c[e+256+4>>2];c[a+384+8>>2]=c[e+256+8>>2];c[a+384+12>>2]=c[e+256+12>>2];c[a+400>>2]=c[e+240>>2];c[a+400+4>>2]=c[e+240+4>>2];c[a+400+8>>2]=c[e+240+8>>2];c[a+400+12>>2]=c[e+240+12>>2];c[a+416>>2]=c[e+160>>2];c[a+416+4>>2]=c[e+160+4>>2];c[a+416+8>>2]=c[e+160+8>>2];c[a+416+12>>2]=c[e+160+12>>2];c[a+432>>2]=c[e+192>>2];c[a+432+4>>2]=c[e+192+4>>2];c[a+432+8>>2]=c[e+192+8>>2];c[a+432+12>>2]=c[e+192+12>>2];c[a+448>>2]=c[e+224>>2];c[a+448+4>>2]=c[e+224+4>>2];c[a+448+8>>2]=c[e+224+8>>2];c[a+448+12>>2]=c[e+224+12>>2];c[a+464>>2]=c[e+144>>2];c[a+464+4>>2]=c[e+144+4>>2];c[a+464+8>>2]=c[e+144+8>>2];c[a+464+12>>2]=c[e+144+12>>2];c[a+480>>2]=c[e+208>>2];c[a+480+4>>2]=c[e+208+4>>2];c[a+480+8>>2]=c[e+208+8>>2];c[a+480+12>>2]=c[e+208+12>>2];c[a+496>>2]=c[e+176>>2];c[a+496+4>>2]=c[e+176+4>>2];c[a+496+8>>2]=c[e+176+8>>2];c[a+496+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+208|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+160|0,35206);rb(e+192|0,35206);rb(e+224|0,35206);rb(e+144|0,35206);rb(e+208|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+208|0);Gd(e+160|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+208|0,e+160|0);Gd(e+192|0,e+256|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+176|0);Gd(e+192|0,e+224|0);Gd(e+176|0,e+144|0);Gd(e+192|0,e+240|0);Gd(e+224|0,e+144|0);Gd(e+160|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+160|0);Ce(e+64|0,e+208|0);Gd(e+80|0,e+224|0);Gd(e+96|0,e+160|0);Gd(e+112|0,e+192|0);Gd(e+48|0,e+224|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+192|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+208|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+160|0);Ce(e+48|0,e+224|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+192|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+208|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+208|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+144|0);Hd(e+208|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+208|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+192|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+192|0);Hd(e+256|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+256|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+208|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+192|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+224|0);Gd(e+128|0,e+160|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+160|0);Hd(e+224|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+224|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+160|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+208|0);Gd(e+224|0,e+176|0);Gd(e+208|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+160|0);Gd(e+224|0,e+144|0);Gd(e+160|0,e+192|0);Gd(e+192|0,e+144|0);Gd(e+208|0,e+192|0);dh(e+208|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+224|0,35238);rb(e+208|0,35238);rb(e+192|0,35238);rb(e+176|0,35238);rb(e+160|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+384>>2];c[e+128+4>>2]=c[a+384+4>>2];c[e+128+8>>2]=c[a+384+8>>2];c[e+128+12>>2]=c[a+384+12>>2];c[e+112>>2]=c[a+400>>2];c[e+112+4>>2]=c[a+400+4>>2];c[e+112+8>>2]=c[a+400+8>>2];c[e+112+12>>2]=c[a+400+12>>2];c[e+96>>2]=c[a+416>>2];c[e+96+4>>2]=c[a+416+4>>2];c[e+96+8>>2]=c[a+416+8>>2];c[e+96+12>>2]=c[a+416+12>>2];c[e+80>>2]=c[a+432>>2];c[e+80+4>>2]=c[a+432+4>>2];c[e+80+8>>2]=c[a+432+8>>2];c[e+80+12>>2]=c[a+432+12>>2];c[e+64>>2]=c[a+448>>2];c[e+64+4>>2]=c[a+448+4>>2];c[e+64+8>>2]=c[a+448+8>>2];c[e+64+12>>2]=c[a+448+12>>2];c[e+48>>2]=c[a+464>>2];c[e+48+4>>2]=c[a+464+4>>2];c[e+48+8>>2]=c[a+464+8>>2];c[e+48+12>>2]=c[a+464+12>>2];c[e+32>>2]=c[a+480>>2];c[e+32+4>>2]=c[a+480+4>>2];c[e+32+8>>2]=c[a+480+8>>2];c[e+32+12>>2]=c[a+480+12>>2];c[e+16>>2]=c[a+496>>2];c[e+16+4>>2]=c[a+496+4>>2];c[e+16+8>>2]=c[a+496+8>>2];c[e+16+12>>2]=c[a+496+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);c[a+512>>2]=c[e+256>>2];c[a+512+4>>2]=c[e+256+4>>2];c[a+512+8>>2]=c[e+256+8>>2];c[a+512+12>>2]=c[e+256+12>>2];c[a+528>>2]=c[e+240>>2];c[a+528+4>>2]=c[e+240+4>>2];c[a+528+8>>2]=c[e+240+8>>2];c[a+528+12>>2]=c[e+240+12>>2];c[a+544>>2]=c[e+224>>2];c[a+544+4>>2]=c[e+224+4>>2];c[a+544+8>>2]=c[e+224+8>>2];c[a+544+12>>2]=c[e+224+12>>2];c[a+560>>2]=c[e+208>>2];c[a+560+4>>2]=c[e+208+4>>2];c[a+560+8>>2]=c[e+208+8>>2];c[a+560+12>>2]=c[e+208+12>>2];c[a+576>>2]=c[e+192>>2];c[a+576+4>>2]=c[e+192+4>>2];c[a+576+8>>2]=c[e+192+8>>2];c[a+576+12>>2]=c[e+192+12>>2];c[a+592>>2]=c[e+176>>2];c[a+592+4>>2]=c[e+176+4>>2];c[a+592+8>>2]=c[e+176+8>>2];c[a+592+12>>2]=c[e+176+12>>2];c[a+608>>2]=c[e+160>>2];c[a+608+4>>2]=c[e+160+4>>2];c[a+608+8>>2]=c[e+160+8>>2];c[a+608+12>>2]=c[e+160+12>>2];c[a+624>>2]=c[e+144>>2];c[a+624+4>>2]=c[e+144+4>>2];c[a+624+8>>2]=c[e+144+8>>2];c[a+624+12>>2]=c[e+144+12>>2];Le(e+256|0);Le(e+240|0);Le(e+176|0);Le(e+160|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+224|0,35206);rb(e+208|0,35206);rb(e+192|0,35206);rb(e+176|0,35206);rb(e+160|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+160|0);Gd(e+224|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+160|0,e+224|0);Gd(e+208|0,e+256|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+144|0);Gd(e+208|0,e+192|0);Gd(e+144|0,e+176|0);Gd(e+208|0,e+240|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+224|0);Ce(e+64|0,e+160|0);Gd(e+80|0,e+192|0);Gd(e+96|0,e+224|0);Gd(e+112|0,e+208|0);Gd(e+48|0,e+192|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+208|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+160|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+224|0);Ce(e+48|0,e+192|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+208|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+160|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+160|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+176|0);Hd(e+160|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+160|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+208|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+208|0);Hd(e+256|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+256|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+160|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+208|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+192|0);Gd(e+128|0,e+224|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+224|0);Hd(e+192|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+192|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+224|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+160|0);Gd(e+192|0,e+144|0);Gd(e+160|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+224|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+208|0);Gd(e+208|0,e+176|0);Gd(e+160|0,e+208|0);dh(e+208|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+192|0,35238);rb(e+160|0,35238);rb(e+208|0,35238);rb(e+144|0,35238);rb(e+224|0,35238);rb(e+176|0,35238);c[e+128>>2]=c[a+512>>2];c[e+128+4>>2]=c[a+512+4>>2];c[e+128+8>>2]=c[a+512+8>>2];c[e+128+12>>2]=c[a+512+12>>2];c[e+112>>2]=c[a+528>>2];c[e+112+4>>2]=c[a+528+4>>2];c[e+112+8>>2]=c[a+528+8>>2];c[e+112+12>>2]=c[a+528+12>>2];c[e+96>>2]=c[a+544>>2];c[e+96+4>>2]=c[a+544+4>>2];c[e+96+8>>2]=c[a+544+8>>2];c[e+96+12>>2]=c[a+544+12>>2];c[e+80>>2]=c[a+560>>2];c[e+80+4>>2]=c[a+560+4>>2];c[e+80+8>>2]=c[a+560+8>>2];c[e+80+12>>2]=c[a+560+12>>2];c[e+64>>2]=c[a+576>>2];c[e+64+4>>2]=c[a+576+4>>2];c[e+64+8>>2]=c[a+576+8>>2];c[e+64+12>>2]=c[a+576+12>>2];c[e+48>>2]=c[a+592>>2];c[e+48+4>>2]=c[a+592+4>>2];c[e+48+8>>2]=c[a+592+8>>2];c[e+48+12>>2]=c[a+592+12>>2];c[e+32>>2]=c[a+608>>2];c[e+32+4>>2]=c[a+608+4>>2];c[e+32+8>>2]=c[a+608+8>>2];c[e+32+12>>2]=c[a+608+12>>2];c[e+16>>2]=c[a+624>>2];c[e+16+4>>2]=c[a+624+4>>2];c[e+16+8>>2]=c[a+624+8>>2];c[e+16+12>>2]=c[a+624+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);c[a+640>>2]=c[e+256>>2];c[a+640+4>>2]=c[e+256+4>>2];c[a+640+8>>2]=c[e+256+8>>2];c[a+640+12>>2]=c[e+256+12>>2];c[a+656>>2]=c[e+240>>2];c[a+656+4>>2]=c[e+240+4>>2];c[a+656+8>>2]=c[e+240+8>>2];c[a+656+12>>2]=c[e+240+12>>2];c[a+672>>2]=c[e+192>>2];c[a+672+4>>2]=c[e+192+4>>2];c[a+672+8>>2]=c[e+192+8>>2];c[a+672+12>>2]=c[e+192+12>>2];c[a+688>>2]=c[e+160>>2];c[a+688+4>>2]=c[e+160+4>>2];c[a+688+8>>2]=c[e+160+8>>2];c[a+688+12>>2]=c[e+160+12>>2];c[a+704>>2]=c[e+208>>2];c[a+704+4>>2]=c[e+208+4>>2];c[a+704+8>>2]=c[e+208+8>>2];c[a+704+12>>2]=c[e+208+12>>2];c[a+720>>2]=c[e+144>>2];c[a+720+4>>2]=c[e+144+4>>2];c[a+720+8>>2]=c[e+144+8>>2];c[a+720+12>>2]=c[e+144+12>>2];c[a+736>>2]=c[e+224>>2];c[a+736+4>>2]=c[e+224+4>>2];c[a+736+8>>2]=c[e+224+8>>2];c[a+736+12>>2]=c[e+224+12>>2];c[a+752>>2]=c[e+176>>2];c[a+752+4>>2]=c[e+176+4>>2];c[a+752+8>>2]=c[e+176+8>>2];c[a+752+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+224|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+192|0,35206);rb(e+160|0,35206);rb(e+208|0,35206);rb(e+144|0,35206);rb(e+224|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+224|0);Gd(e+192|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+224|0,e+192|0);Gd(e+160|0,e+256|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+176|0);Gd(e+160|0,e+208|0);Gd(e+176|0,e+144|0);Gd(e+160|0,e+240|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+192|0);Ce(e+64|0,e+224|0);Gd(e+80|0,e+208|0);Gd(e+96|0,e+192|0);Gd(e+112|0,e+160|0);Gd(e+48|0,e+208|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+160|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+224|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+192|0);Ce(e+48|0,e+208|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+160|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+224|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+224|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+144|0);Hd(e+224|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+224|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+160|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+160|0);Hd(e+256|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+256|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+224|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+160|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+208|0);Gd(e+128|0,e+192|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+192|0);Hd(e+208|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+208|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+192|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+224|0);Gd(e+208|0,e+176|0);Gd(e+224|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+192|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+160|0);Gd(e+160|0,e+144|0);Gd(e+224|0,e+160|0);dh(e+176|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+208|0,35238);rb(e+224|0,35238);rb(e+160|0,35238);rb(e+176|0,35238);rb(e+192|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+640>>2];c[e+128+4>>2]=c[a+640+4>>2];c[e+128+8>>2]=c[a+640+8>>2];c[e+128+12>>2]=c[a+640+12>>2];c[e+112>>2]=c[a+656>>2];c[e+112+4>>2]=c[a+656+4>>2];c[e+112+8>>2]=c[a+656+8>>2];c[e+112+12>>2]=c[a+656+12>>2];c[e+96>>2]=c[a+672>>2];c[e+96+4>>2]=c[a+672+4>>2];c[e+96+8>>2]=c[a+672+8>>2];c[e+96+12>>2]=c[a+672+12>>2];c[e+80>>2]=c[a+688>>2];c[e+80+4>>2]=c[a+688+4>>2];c[e+80+8>>2]=c[a+688+8>>2];c[e+80+12>>2]=c[a+688+12>>2];c[e+64>>2]=c[a+704>>2];c[e+64+4>>2]=c[a+704+4>>2];c[e+64+8>>2]=c[a+704+8>>2];c[e+64+12>>2]=c[a+704+12>>2];c[e+48>>2]=c[a+720>>2];c[e+48+4>>2]=c[a+720+4>>2];c[e+48+8>>2]=c[a+720+8>>2];c[e+48+12>>2]=c[a+720+12>>2];c[e+32>>2]=c[a+736>>2];c[e+32+4>>2]=c[a+736+4>>2];c[e+32+8>>2]=c[a+736+8>>2];c[e+32+12>>2]=c[a+736+12>>2];c[e+16>>2]=c[a+752>>2];c[e+16+4>>2]=c[a+752+4>>2];c[e+16+8>>2]=c[a+752+8>>2];c[e+16+12>>2]=c[a+752+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);c[a+768>>2]=c[e+256>>2];c[a+768+4>>2]=c[e+256+4>>2];c[a+768+8>>2]=c[e+256+8>>2];c[a+768+12>>2]=c[e+256+12>>2];c[a+784>>2]=c[e+240>>2];c[a+784+4>>2]=c[e+240+4>>2];c[a+784+8>>2]=c[e+240+8>>2];c[a+784+12>>2]=c[e+240+12>>2];c[a+800>>2]=c[e+208>>2];c[a+800+4>>2]=c[e+208+4>>2];c[a+800+8>>2]=c[e+208+8>>2];c[a+800+12>>2]=c[e+208+12>>2];c[a+816>>2]=c[e+224>>2];c[a+816+4>>2]=c[e+224+4>>2];c[a+816+8>>2]=c[e+224+8>>2];c[a+816+12>>2]=c[e+224+12>>2];c[a+832>>2]=c[e+160>>2];c[a+832+4>>2]=c[e+160+4>>2];c[a+832+8>>2]=c[e+160+8>>2];c[a+832+12>>2]=c[e+160+12>>2];c[a+848>>2]=c[e+176>>2];c[a+848+4>>2]=c[e+176+4>>2];c[a+848+8>>2]=c[e+176+8>>2];c[a+848+12>>2]=c[e+176+12>>2];c[a+864>>2]=c[e+192>>2];c[a+864+4>>2]=c[e+192+4>>2];c[a+864+8>>2]=c[e+192+8>>2];c[a+864+12>>2]=c[e+192+12>>2];c[a+880>>2]=c[e+144>>2];c[a+880+4>>2]=c[e+144+4>>2];c[a+880+8>>2]=c[e+144+8>>2];c[a+880+12>>2]=c[e+144+12>>2];Le(e+256|0);Le(e+240|0);Le(e+176|0);Le(e+192|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+208|0,35206);rb(e+224|0,35206);rb(e+160|0,35206);rb(e+176|0,35206);rb(e+192|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+192|0);Gd(e+208|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+192|0,e+208|0);Gd(e+224|0,e+256|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+144|0);Gd(e+224|0,e+160|0);Gd(e+144|0,e+176|0);Gd(e+224|0,e+240|0);Gd(e+160|0,e+176|0);Gd(e+208|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+208|0);Ce(e+64|0,e+192|0);Gd(e+80|0,e+160|0);Gd(e+96|0,e+208|0);Gd(e+112|0,e+224|0);Gd(e+48|0,e+160|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+224|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+192|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+208|0);Ce(e+48|0,e+160|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+224|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+192|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+192|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+176|0);Hd(e+192|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+192|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+224|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+224|0);Hd(e+256|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+256|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+192|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+224|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+160|0);Gd(e+128|0,e+208|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+208|0);Hd(e+160|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+160|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+208|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+192|0);Gd(e+160|0,e+144|0);Gd(e+192|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+208|0);Gd(e+160|0,e+176|0);Gd(e+208|0,e+224|0);Gd(e+224|0,e+176|0);Gd(e+192|0,e+224|0);dh(e+208|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+160|0,35238);rb(e+192|0,35238);rb(e+224|0,35238);rb(e+144|0,35238);rb(e+208|0,35238);rb(e+176|0,35238);c[e+128>>2]=c[a+768>>2];c[e+128+4>>2]=c[a+768+4>>2];c[e+128+8>>2]=c[a+768+8>>2];c[e+128+12>>2]=c[a+768+12>>2];c[e+112>>2]=c[a+784>>2];c[e+112+4>>2]=c[a+784+4>>2];c[e+112+8>>2]=c[a+784+8>>2];c[e+112+12>>2]=c[a+784+12>>2];c[e+96>>2]=c[a+800>>2];c[e+96+4>>2]=c[a+800+4>>2];c[e+96+8>>2]=c[a+800+8>>2];c[e+96+12>>2]=c[a+800+12>>2];c[e+80>>2]=c[a+816>>2];c[e+80+4>>2]=c[a+816+4>>2];c[e+80+8>>2]=c[a+816+8>>2];c[e+80+12>>2]=c[a+816+12>>2];c[e+64>>2]=c[a+832>>2];c[e+64+4>>2]=c[a+832+4>>2];c[e+64+8>>2]=c[a+832+8>>2];c[e+64+12>>2]=c[a+832+12>>2];c[e+48>>2]=c[a+848>>2];c[e+48+4>>2]=c[a+848+4>>2];c[e+48+8>>2]=c[a+848+8>>2];c[e+48+12>>2]=c[a+848+12>>2];c[e+32>>2]=c[a+864>>2];c[e+32+4>>2]=c[a+864+4>>2];c[e+32+8>>2]=c[a+864+8>>2];c[e+32+12>>2]=c[a+864+12>>2];c[e+16>>2]=c[a+880>>2];c[e+16+4>>2]=c[a+880+4>>2];c[e+16+8>>2]=c[a+880+8>>2];c[e+16+12>>2]=c[a+880+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);c[a+896>>2]=c[e+256>>2];c[a+896+4>>2]=c[e+256+4>>2];c[a+896+8>>2]=c[e+256+8>>2];c[a+896+12>>2]=c[e+256+12>>2];c[a+912>>2]=c[e+240>>2];c[a+912+4>>2]=c[e+240+4>>2];c[a+912+8>>2]=c[e+240+8>>2];c[a+912+12>>2]=c[e+240+12>>2];c[a+928>>2]=c[e+160>>2];c[a+928+4>>2]=c[e+160+4>>2];c[a+928+8>>2]=c[e+160+8>>2];c[a+928+12>>2]=c[e+160+12>>2];c[a+944>>2]=c[e+192>>2];c[a+944+4>>2]=c[e+192+4>>2];c[a+944+8>>2]=c[e+192+8>>2];c[a+944+12>>2]=c[e+192+12>>2];c[a+960>>2]=c[e+224>>2];c[a+960+4>>2]=c[e+224+4>>2];c[a+960+8>>2]=c[e+224+8>>2];c[a+960+12>>2]=c[e+224+12>>2];c[a+976>>2]=c[e+144>>2];c[a+976+4>>2]=c[e+144+4>>2];c[a+976+8>>2]=c[e+144+8>>2];c[a+976+12>>2]=c[e+144+12>>2];c[a+992>>2]=c[e+208>>2];c[a+992+4>>2]=c[e+208+4>>2];c[a+992+8>>2]=c[e+208+8>>2];c[a+992+12>>2]=c[e+208+12>>2];c[a+1008>>2]=c[e+176>>2];c[a+1008+4>>2]=c[e+176+4>>2];c[a+1008+8>>2]=c[e+176+8>>2];c[a+1008+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+208|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+160|0,35206);rb(e+192|0,35206);rb(e+224|0,35206);rb(e+144|0,35206);rb(e+208|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+208|0);Gd(e+160|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+208|0,e+160|0);Gd(e+192|0,e+256|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+176|0);Gd(e+192|0,e+224|0);Gd(e+176|0,e+144|0);Gd(e+192|0,e+240|0);Gd(e+224|0,e+144|0);Gd(e+160|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+160|0);Ce(e+64|0,e+208|0);Gd(e+80|0,e+224|0);Gd(e+96|0,e+160|0);Gd(e+112|0,e+192|0);Gd(e+48|0,e+224|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+192|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+208|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+160|0);Ce(e+48|0,e+224|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+192|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+208|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+208|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+144|0);Hd(e+208|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+208|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+192|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+192|0);Hd(e+256|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+256|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+208|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+192|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+224|0);Gd(e+128|0,e+160|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+160|0);Hd(e+224|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+224|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+160|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+208|0);Gd(e+224|0,e+176|0);Gd(e+208|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+160|0);Gd(e+224|0,e+144|0);Gd(e+160|0,e+192|0);Gd(e+192|0,e+144|0);Gd(e+208|0,e+192|0);dh(e+144|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+224|0,35238);rb(e+208|0,35238);rb(e+192|0,35238);rb(e+176|0,35238);rb(e+160|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+896>>2];c[e+128+4>>2]=c[a+896+4>>2];c[e+128+8>>2]=c[a+896+8>>2];c[e+128+12>>2]=c[a+896+12>>2];c[e+112>>2]=c[a+912>>2];c[e+112+4>>2]=c[a+912+4>>2];c[e+112+8>>2]=c[a+912+8>>2];c[e+112+12>>2]=c[a+912+12>>2];c[e+96>>2]=c[a+928>>2];c[e+96+4>>2]=c[a+928+4>>2];c[e+96+8>>2]=c[a+928+8>>2];c[e+96+12>>2]=c[a+928+12>>2];c[e+80>>2]=c[a+944>>2];c[e+80+4>>2]=c[a+944+4>>2];c[e+80+8>>2]=c[a+944+8>>2];c[e+80+12>>2]=c[a+944+12>>2];c[e+64>>2]=c[a+960>>2];c[e+64+4>>2]=c[a+960+4>>2];c[e+64+8>>2]=c[a+960+8>>2];c[e+64+12>>2]=c[a+960+12>>2];c[e+48>>2]=c[a+976>>2];c[e+48+4>>2]=c[a+976+4>>2];c[e+48+8>>2]=c[a+976+8>>2];c[e+48+12>>2]=c[a+976+12>>2];c[e+32>>2]=c[a+992>>2];c[e+32+4>>2]=c[a+992+4>>2];c[e+32+8>>2]=c[a+992+8>>2];c[e+32+12>>2]=c[a+992+12>>2];c[e+16>>2]=c[a+1008>>2];c[e+16+4>>2]=c[a+1008+4>>2];c[e+16+8>>2]=c[a+1008+8>>2];c[e+16+12>>2]=c[a+1008+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);c[a+1024>>2]=c[e+256>>2];c[a+1024+4>>2]=c[e+256+4>>2];c[a+1024+8>>2]=c[e+256+8>>2];c[a+1024+12>>2]=c[e+256+12>>2];c[a+1040>>2]=c[e+240>>2];c[a+1040+4>>2]=c[e+240+4>>2];c[a+1040+8>>2]=c[e+240+8>>2];c[a+1040+12>>2]=c[e+240+12>>2];c[a+1056>>2]=c[e+224>>2];c[a+1056+4>>2]=c[e+224+4>>2];c[a+1056+8>>2]=c[e+224+8>>2];c[a+1056+12>>2]=c[e+224+12>>2];c[a+1072>>2]=c[e+208>>2];c[a+1072+4>>2]=c[e+208+4>>2];c[a+1072+8>>2]=c[e+208+8>>2];c[a+1072+12>>2]=c[e+208+12>>2];c[a+1088>>2]=c[e+192>>2];c[a+1088+4>>2]=c[e+192+4>>2];c[a+1088+8>>2]=c[e+192+8>>2];c[a+1088+12>>2]=c[e+192+12>>2];c[a+1104>>2]=c[e+176>>2];c[a+1104+4>>2]=c[e+176+4>>2];c[a+1104+8>>2]=c[e+176+8>>2];c[a+1104+12>>2]=c[e+176+12>>2];c[a+1120>>2]=c[e+160>>2];c[a+1120+4>>2]=c[e+160+4>>2];c[a+1120+8>>2]=c[e+160+8>>2];c[a+1120+12>>2]=c[e+160+12>>2];c[a+1136>>2]=c[e+144>>2];c[a+1136+4>>2]=c[e+144+4>>2];c[a+1136+8>>2]=c[e+144+8>>2];c[a+1136+12>>2]=c[e+144+12>>2];Le(e+256|0);Le(e+240|0);Le(e+176|0);Le(e+160|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+224|0,35206);rb(e+208|0,35206);rb(e+192|0,35206);rb(e+176|0,35206);rb(e+160|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+160|0);Gd(e+224|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+160|0,e+224|0);Gd(e+208|0,e+256|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+144|0);Gd(e+208|0,e+192|0);Gd(e+144|0,e+176|0);Gd(e+208|0,e+240|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+224|0);Ce(e+64|0,e+160|0);Gd(e+80|0,e+192|0);Gd(e+96|0,e+224|0);Gd(e+112|0,e+208|0);Gd(e+48|0,e+192|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+208|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+160|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+224|0);Ce(e+48|0,e+192|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+208|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+160|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+160|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+176|0);Hd(e+160|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+160|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+208|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+208|0);Hd(e+256|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+256|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+160|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+208|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+192|0);Gd(e+128|0,e+224|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+224|0);Hd(e+192|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+192|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+224|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+160|0);Gd(e+192|0,e+144|0);Gd(e+160|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+224|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+208|0);Gd(e+208|0,e+176|0);Gd(e+160|0,e+208|0);dh(e+256|0);dh(e+240|0);dh(e+160|0);dh(e+208|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+192|0,35238);rb(e+160|0,35238);rb(e+208|0,35238);rb(e+144|0,35238);rb(e+224|0,35238);rb(e+176|0,35238);c[e+128>>2]=c[a+1024>>2];c[e+128+4>>2]=c[a+1024+4>>2];c[e+128+8>>2]=c[a+1024+8>>2];c[e+128+12>>2]=c[a+1024+12>>2];c[e+112>>2]=c[a+1040>>2];c[e+112+4>>2]=c[a+1040+4>>2];c[e+112+8>>2]=c[a+1040+8>>2];c[e+112+12>>2]=c[a+1040+12>>2];c[e+96>>2]=c[a+1056>>2];c[e+96+4>>2]=c[a+1056+4>>2];c[e+96+8>>2]=c[a+1056+8>>2];c[e+96+12>>2]=c[a+1056+12>>2];c[e+80>>2]=c[a+1072>>2];c[e+80+4>>2]=c[a+1072+4>>2];c[e+80+8>>2]=c[a+1072+8>>2];c[e+80+12>>2]=c[a+1072+12>>2];c[e+64>>2]=c[a+1088>>2];c[e+64+4>>2]=c[a+1088+4>>2];c[e+64+8>>2]=c[a+1088+8>>2];c[e+64+12>>2]=c[a+1088+12>>2];c[e+48>>2]=c[a+1104>>2];c[e+48+4>>2]=c[a+1104+4>>2];c[e+48+8>>2]=c[a+1104+8>>2];c[e+48+12>>2]=c[a+1104+12>>2];c[e+32>>2]=c[a+1120>>2];c[e+32+4>>2]=c[a+1120+4>>2];c[e+32+8>>2]=c[a+1120+8>>2];c[e+32+12>>2]=c[a+1120+12>>2];c[e+16>>2]=c[a+1136>>2];c[e+16+4>>2]=c[a+1136+4>>2];c[e+16+8>>2]=c[a+1136+8>>2];c[e+16+12>>2]=c[a+1136+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);c[a+1152>>2]=c[e+256>>2];c[a+1152+4>>2]=c[e+256+4>>2];c[a+1152+8>>2]=c[e+256+8>>2];c[a+1152+12>>2]=c[e+256+12>>2];c[a+1168>>2]=c[e+240>>2];c[a+1168+4>>2]=c[e+240+4>>2];c[a+1168+8>>2]=c[e+240+8>>2];c[a+1168+12>>2]=c[e+240+12>>2];c[a+1184>>2]=c[e+192>>2];c[a+1184+4>>2]=c[e+192+4>>2];c[a+1184+8>>2]=c[e+192+8>>2];c[a+1184+12>>2]=c[e+192+12>>2];c[a+1200>>2]=c[e+160>>2];c[a+1200+4>>2]=c[e+160+4>>2];c[a+1200+8>>2]=c[e+160+8>>2];c[a+1200+12>>2]=c[e+160+12>>2];c[a+1216>>2]=c[e+208>>2];c[a+1216+4>>2]=c[e+208+4>>2];c[a+1216+8>>2]=c[e+208+8>>2];c[a+1216+12>>2]=c[e+208+12>>2];c[a+1232>>2]=c[e+144>>2];c[a+1232+4>>2]=c[e+144+4>>2];c[a+1232+8>>2]=c[e+144+8>>2];c[a+1232+12>>2]=c[e+144+12>>2];c[a+1248>>2]=c[e+224>>2];c[a+1248+4>>2]=c[e+224+4>>2];c[a+1248+8>>2]=c[e+224+8>>2];c[a+1248+12>>2]=c[e+224+12>>2];c[a+1264>>2]=c[e+176>>2];c[a+1264+4>>2]=c[e+176+4>>2];c[a+1264+8>>2]=c[e+176+8>>2];c[a+1264+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+224|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+192|0,35206);rb(e+160|0,35206);rb(e+208|0,35206);rb(e+144|0,35206);rb(e+224|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+224|0);Gd(e+192|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+224|0,e+192|0);Gd(e+160|0,e+256|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+176|0);Gd(e+160|0,e+208|0);Gd(e+176|0,e+144|0);Gd(e+160|0,e+240|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+192|0);Ce(e+64|0,e+224|0);Gd(e+80|0,e+208|0);Gd(e+96|0,e+192|0);Gd(e+112|0,e+160|0);Gd(e+48|0,e+208|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+160|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+224|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+192|0);Ce(e+48|0,e+208|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+160|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+224|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+224|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+144|0);Hd(e+224|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+224|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+160|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+160|0);Hd(e+256|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+256|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+224|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+160|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+208|0);Gd(e+128|0,e+192|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+192|0);Hd(e+208|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+208|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+192|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+224|0);Gd(e+208|0,e+176|0);Gd(e+224|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+192|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+160|0);Gd(e+160|0,e+144|0);Gd(e+224|0,e+160|0);dh(e+240|0);dh(e+208|0);dh(e+160|0);dh(e+176|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+208|0,35238);rb(e+224|0,35238);rb(e+160|0,35238);rb(e+176|0,35238);rb(e+192|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+1152>>2];c[e+128+4>>2]=c[a+1152+4>>2];c[e+128+8>>2]=c[a+1152+8>>2];c[e+128+12>>2]=c[a+1152+12>>2];c[e+112>>2]=c[a+1168>>2];c[e+112+4>>2]=c[a+1168+4>>2];c[e+112+8>>2]=c[a+1168+8>>2];c[e+112+12>>2]=c[a+1168+12>>2];c[e+96>>2]=c[a+1184>>2];c[e+96+4>>2]=c[a+1184+4>>2];c[e+96+8>>2]=c[a+1184+8>>2];c[e+96+12>>2]=c[a+1184+12>>2];c[e+80>>2]=c[a+1200>>2];c[e+80+4>>2]=c[a+1200+4>>2];c[e+80+8>>2]=c[a+1200+8>>2];c[e+80+12>>2]=c[a+1200+12>>2];c[e+64>>2]=c[a+1216>>2];c[e+64+4>>2]=c[a+1216+4>>2];c[e+64+8>>2]=c[a+1216+8>>2];c[e+64+12>>2]=c[a+1216+12>>2];c[e+48>>2]=c[a+1232>>2];c[e+48+4>>2]=c[a+1232+4>>2];c[e+48+8>>2]=c[a+1232+8>>2];c[e+48+12>>2]=c[a+1232+12>>2];c[e+32>>2]=c[a+1248>>2];c[e+32+4>>2]=c[a+1248+4>>2];c[e+32+8>>2]=c[a+1248+8>>2];c[e+32+12>>2]=c[a+1248+12>>2];c[e+16>>2]=c[a+1264>>2];c[e+16+4>>2]=c[a+1264+4>>2];c[e+16+8>>2]=c[a+1264+8>>2];c[e+16+12>>2]=c[a+1264+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);rb(e+256|0,35222);rb(e+240|0,35222);rb(e+192|0,35222);rb(e+160|0,35222);rb(e+208|0,35222);rb(e+144|0,35222);rb(e+224|0,35222);rb(e+176|0,35222);c[a+1280>>2]=c[e+256>>2];c[a+1280+4>>2]=c[e+256+4>>2];c[a+1280+8>>2]=c[e+256+8>>2];c[a+1280+12>>2]=c[e+256+12>>2];c[a+1296>>2]=c[e+240>>2];c[a+1296+4>>2]=c[e+240+4>>2];c[a+1296+8>>2]=c[e+240+8>>2];c[a+1296+12>>2]=c[e+240+12>>2];c[a+1312>>2]=c[e+208>>2];c[a+1312+4>>2]=c[e+208+4>>2];c[a+1312+8>>2]=c[e+208+8>>2];c[a+1312+12>>2]=c[e+208+12>>2];c[a+1328>>2]=c[e+224>>2];c[a+1328+4>>2]=c[e+224+4>>2];c[a+1328+8>>2]=c[e+224+8>>2];c[a+1328+12>>2]=c[e+224+12>>2];c[a+1344>>2]=c[e+160>>2];c[a+1344+4>>2]=c[e+160+4>>2];c[a+1344+8>>2]=c[e+160+8>>2];c[a+1344+12>>2]=c[e+160+12>>2];c[a+1360>>2]=c[e+176>>2];c[a+1360+4>>2]=c[e+176+4>>2];c[a+1360+8>>2]=c[e+176+8>>2];c[a+1360+12>>2]=c[e+176+12>>2];c[a+1376>>2]=c[e+192>>2];c[a+1376+4>>2]=c[e+192+4>>2];c[a+1376+8>>2]=c[e+192+8>>2];c[a+1376+12>>2]=c[e+192+12>>2];c[a+1392>>2]=c[e+144>>2];c[a+1392+4>>2]=c[e+144+4>>2];c[a+1392+8>>2]=c[e+144+8>>2];c[a+1392+12>>2]=c[e+144+12>>2];l=d;return 0}function ea(b,d,e,f,g,h){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0;k=l;j=l=l+63&-64;l=l+400|0;Ce(j,g);while(1){c[j+256>>2]=c[j>>2];c[j+256+4>>2]=c[j+4>>2];c[j+256+8>>2]=c[j+8>>2];c[j+256+12>>2]=c[j+12>>2];Ce(j+240|0,j+256|0);rb(j+240|0,35254);Ce(j+224|0,j+240|0);Ce(j+208|0,j+240|0);Ce(j+192|0,j+240|0);Ce(j+176|0,j+240|0);Ce(j+160|0,j+240|0);Ce(j+144|0,j+240|0);Eg(j+240|0,1);Eg(j+224|0,2);Eg(j+208|0,3);Eg(j+192|0,4);Eg(j+176|0,5);Eg(j+160|0,6);Eg(j+144|0,7);rb(j+256|0,35222);rb(j+240|0,35270);rb(j+224|0,35270);rb(j+208|0,35270);rb(j+192|0,35270);rb(j+176|0,35270);rb(j+160|0,35270);rb(j+144|0,35270);Ce(j+128|0,j+160|0);_d(j+128|0,1);Gd(j+128|0,j+144|0);Hd(j+128|0,1104);Gd(j+144|0,j+128|0);ae(j+128|0,1);Gd(j+160|0,j+128|0);Ce(j+128|0,j+192|0);_d(j+128|0,1);Gd(j+128|0,j+176|0);Hd(j+128|0,1104);Gd(j+176|0,j+128|0);ae(j+128|0,1);Gd(j+192|0,j+128|0);Ce(j+128|0,j+224|0);_d(j+128|0,1);Gd(j+128|0,j+208|0);Hd(j+128|0,1104);Gd(j+208|0,j+128|0);ae(j+128|0,1);Gd(j+224|0,j+128|0);Ce(j+128|0,j+256|0);_d(j+128|0,1);Gd(j+128|0,j+240|0);Hd(j+128|0,1104);Gd(j+240|0,j+128|0);ae(j+128|0,1);Gd(j+256|0,j+128|0);Ce(j+128|0,j+176|0);_d(j+128|0,2);Gd(j+128|0,j+144|0);Hd(j+128|0,1120);Gd(j+144|0,j+128|0);ae(j+128|0,2);Gd(j+176|0,j+128|0);Ce(j+128|0,j+192|0);_d(j+128|0,2);Gd(j+128|0,j+160|0);Hd(j+128|0,1120);Gd(j+160|0,j+128|0);ae(j+128|0,2);Gd(j+192|0,j+128|0);Ce(j+128|0,j+240|0);_d(j+128|0,2);Gd(j+128|0,j+208|0);Hd(j+128|0,1120);Gd(j+208|0,j+128|0);ae(j+128|0,2);Gd(j+240|0,j+128|0);Ce(j+128|0,j+256|0);_d(j+128|0,2);Gd(j+128|0,j+224|0);Hd(j+128|0,1120);Gd(j+224|0,j+128|0);ae(j+128|0,2);Gd(j+256|0,j+128|0);Ce(j+128|0,j+208|0);_d(j+128|0,4);Gd(j+128|0,j+144|0);Hd(j+128|0,1136);Gd(j+144|0,j+128|0);ae(j+128|0,4);Gd(j+208|0,j+128|0);Ce(j+128|0,j+224|0);_d(j+128|0,4);Gd(j+128|0,j+160|0);Hd(j+128|0,1136);Gd(j+160|0,j+128|0);ae(j+128|0,4);Gd(j+224|0,j+128|0);Ce(j+128|0,j+240|0);_d(j+128|0,4);Gd(j+128|0,j+176|0);Hd(j+128|0,1136);Gd(j+176|0,j+128|0);ae(j+128|0,4);Gd(j+240|0,j+128|0);Ce(j+128|0,j+256|0);_d(j+128|0,4);Gd(j+128|0,j+192|0);Hd(j+128|0,1136);Gd(j+192|0,j+128|0);ae(j+128|0,4);Gd(j+256|0,j+128|0);Gd(j+256|0,h);rb(j+256|0,35286);Gd(j+240|0,h+16|0);rb(j+240|0,35286);Gd(j+224|0,h+32|0);rb(j+224|0,35286);Gd(j+208|0,h+48|0);rb(j+208|0,35286);Gd(j+192|0,h+64|0);rb(j+192|0,35286);Gd(j+176|0,h+80|0);rb(j+176|0,35286);Gd(j+160|0,h+96|0);rb(j+160|0,35286);Gd(j+144|0,h+112|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+128|0);rb(j+128|0,35286);Gd(j+112|0,h+144|0);rb(j+112|0,35286);Gd(j+96|0,h+160|0);rb(j+96|0,35286);Gd(j+80|0,h+176|0);rb(j+80|0,35286);Gd(j+64|0,h+192|0);rb(j+64|0,35286);Gd(j+48|0,h+208|0);rb(j+48|0,35286);Gd(j+32|0,h+224|0);rb(j+32|0,35286);Gd(j+16|0,h+240|0);rb(j+16|0,35286);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);_c(j+256|0,j+128|0,147);_c(j+240|0,j+112|0,147);_c(j+224|0,j+64|0,147);_c(j+208|0,j+32|0,147);_c(j+192|0,j+80|0,147);_c(j+176|0,j+16|0,147);_c(j+160|0,j+96|0,147);_c(j+144|0,j+48|0,147);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+64|0,j+224|0);Gd(j+32|0,j+208|0);Gd(j+80|0,j+192|0);Gd(j+16|0,j+176|0);Gd(j+96|0,j+160|0);Gd(j+48|0,j+144|0);Gd(j+256|0,j+48|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+112|0);Gd(j+240|0,j+48|0);Gd(j+208|0,j+64|0);Gd(j+192|0,j+32|0);Gd(j+176|0,j+80|0);Gd(j+208|0,j+48|0);Gd(j+160|0,j+16|0);Gd(j+144|0,j+96|0);Gd(j+192|0,j+48|0);_c(j+128|0,j+128|0,78);_c(j+112|0,j+112|0,78);_c(j+64|0,j+64|0,78);_c(j+32|0,j+32|0,78);_c(j+80|0,j+80|0,78);_c(j+16|0,j+16|0,78);_c(j+96|0,j+96|0,78);_c(j+48|0,j+48|0,78);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+224|0,j+64|0);Gd(j+208|0,j+32|0);Gd(j+192|0,j+80|0);Gd(j+176|0,j+16|0);Gd(j+160|0,j+96|0);Gd(j+144|0,j+48|0);Gd(j+256|0,h+256|0);rb(j+256|0,35286);Gd(j+240|0,h+272|0);rb(j+240|0,35286);Gd(j+224|0,h+288|0);rb(j+224|0,35286);Gd(j+208|0,h+304|0);rb(j+208|0,35286);Gd(j+192|0,h+320|0);rb(j+192|0,35286);Gd(j+176|0,h+336|0);rb(j+176|0,35286);Gd(j+160|0,h+352|0);rb(j+160|0,35286);Gd(j+144|0,h+368|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+384|0);rb(j+128|0,35286);Gd(j+112|0,h+400|0);rb(j+112|0,35286);Gd(j+96|0,h+416|0);rb(j+96|0,35286);Gd(j+80|0,h+432|0);rb(j+80|0,35286);Gd(j+64|0,h+448|0);rb(j+64|0,35286);Gd(j+48|0,h+464|0);rb(j+48|0,35286);Gd(j+32|0,h+480|0);rb(j+32|0,35286);Gd(j+16|0,h+496|0);rb(j+16|0,35286);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);_c(j+256|0,j+128|0,147);_c(j+240|0,j+112|0,147);_c(j+224|0,j+64|0,147);_c(j+208|0,j+32|0,147);_c(j+192|0,j+80|0,147);_c(j+176|0,j+16|0,147);_c(j+160|0,j+96|0,147);_c(j+144|0,j+48|0,147);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+64|0,j+224|0);Gd(j+32|0,j+208|0);Gd(j+80|0,j+192|0);Gd(j+16|0,j+176|0);Gd(j+96|0,j+160|0);Gd(j+48|0,j+144|0);Gd(j+256|0,j+48|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+112|0);Gd(j+240|0,j+48|0);Gd(j+208|0,j+64|0);Gd(j+192|0,j+32|0);Gd(j+176|0,j+80|0);Gd(j+208|0,j+48|0);Gd(j+160|0,j+16|0);Gd(j+144|0,j+96|0);Gd(j+192|0,j+48|0);_c(j+128|0,j+128|0,78);_c(j+112|0,j+112|0,78);_c(j+64|0,j+64|0,78);_c(j+32|0,j+32|0,78);_c(j+80|0,j+80|0,78);_c(j+16|0,j+16|0,78);_c(j+96|0,j+96|0,78);_c(j+48|0,j+48|0,78);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+224|0,j+64|0);Gd(j+208|0,j+32|0);Gd(j+192|0,j+80|0);Gd(j+176|0,j+16|0);Gd(j+160|0,j+96|0);Gd(j+144|0,j+48|0);Gd(j+256|0,h+512|0);rb(j+256|0,35286);Gd(j+240|0,h+528|0);rb(j+240|0,35286);Gd(j+224|0,h+544|0);rb(j+224|0,35286);Gd(j+208|0,h+560|0);rb(j+208|0,35286);Gd(j+192|0,h+576|0);rb(j+192|0,35286);Gd(j+176|0,h+592|0);rb(j+176|0,35286);Gd(j+160|0,h+608|0);rb(j+160|0,35286);Gd(j+144|0,h+624|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+640|0);rb(j+128|0,35286);Gd(j+112|0,h+656|0);rb(j+112|0,35286);Gd(j+96|0,h+672|0);rb(j+96|0,35286);Gd(j+80|0,h+688|0);rb(j+80|0,35286);Gd(j+64|0,h+704|0);rb(j+64|0,35286);Gd(j+48|0,h+720|0);rb(j+48|0,35286);Gd(j+32|0,h+736|0);rb(j+32|0,35286);Gd(j+16|0,h+752|0);rb(j+16|0,35286);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);_c(j+256|0,j+128|0,147);_c(j+240|0,j+112|0,147);_c(j+224|0,j+64|0,147);_c(j+208|0,j+32|0,147);_c(j+192|0,j+80|0,147);_c(j+176|0,j+16|0,147);_c(j+160|0,j+96|0,147);_c(j+144|0,j+48|0,147);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+64|0,j+224|0);Gd(j+32|0,j+208|0);Gd(j+80|0,j+192|0);Gd(j+16|0,j+176|0);Gd(j+96|0,j+160|0);Gd(j+48|0,j+144|0);Gd(j+256|0,j+48|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+112|0);Gd(j+240|0,j+48|0);Gd(j+208|0,j+64|0);Gd(j+192|0,j+32|0);Gd(j+176|0,j+80|0);Gd(j+208|0,j+48|0);Gd(j+160|0,j+16|0);Gd(j+144|0,j+96|0);Gd(j+192|0,j+48|0);_c(j+128|0,j+128|0,78);_c(j+112|0,j+112|0,78);_c(j+64|0,j+64|0,78);_c(j+32|0,j+32|0,78);_c(j+80|0,j+80|0,78);_c(j+16|0,j+16|0,78);_c(j+96|0,j+96|0,78);_c(j+48|0,j+48|0,78);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+224|0,j+64|0);Gd(j+208|0,j+32|0);Gd(j+192|0,j+80|0);Gd(j+176|0,j+16|0);Gd(j+160|0,j+96|0);Gd(j+144|0,j+48|0);Gd(j+256|0,h+768|0);rb(j+256|0,35286);Gd(j+240|0,h+784|0);rb(j+240|0,35286);Gd(j+224|0,h+800|0);rb(j+224|0,35286);Gd(j+208|0,h+816|0);rb(j+208|0,35286);Gd(j+192|0,h+832|0);rb(j+192|0,35286);Gd(j+176|0,h+848|0);rb(j+176|0,35286);Gd(j+160|0,h+864|0);rb(j+160|0,35286);Gd(j+144|0,h+880|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+896|0);rb(j+128|0,35286);Gd(j+112|0,h+912|0);rb(j+112|0,35286);Gd(j+96|0,h+928|0);rb(j+96|0,35286);Gd(j+80|0,h+944|0);rb(j+80|0,35286);Gd(j+64|0,h+960|0);rb(j+64|0,35286);Gd(j+48|0,h+976|0);rb(j+48|0,35286);Gd(j+32|0,h+992|0);rb(j+32|0,35286);Gd(j+16|0,h+1008|0);rb(j+16|0,35286);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);_c(j+256|0,j+128|0,147);_c(j+240|0,j+112|0,147);_c(j+224|0,j+64|0,147);_c(j+208|0,j+32|0,147);_c(j+192|0,j+80|0,147);_c(j+176|0,j+16|0,147);_c(j+160|0,j+96|0,147);_c(j+144|0,j+48|0,147);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+64|0,j+224|0);Gd(j+32|0,j+208|0);Gd(j+80|0,j+192|0);Gd(j+16|0,j+176|0);Gd(j+96|0,j+160|0);Gd(j+48|0,j+144|0);Gd(j+256|0,j+48|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+112|0);Gd(j+240|0,j+48|0);Gd(j+208|0,j+64|0);Gd(j+192|0,j+32|0);Gd(j+176|0,j+80|0);Gd(j+208|0,j+48|0);Gd(j+160|0,j+16|0);Gd(j+144|0,j+96|0);Gd(j+192|0,j+48|0);_c(j+128|0,j+128|0,78);_c(j+112|0,j+112|0,78);_c(j+64|0,j+64|0,78);_c(j+32|0,j+32|0,78);_c(j+80|0,j+80|0,78);_c(j+16|0,j+16|0,78);_c(j+96|0,j+96|0,78);_c(j+48|0,j+48|0,78);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+224|0,j+64|0);Gd(j+208|0,j+32|0);Gd(j+192|0,j+80|0);Gd(j+176|0,j+16|0);Gd(j+160|0,j+96|0);Gd(j+144|0,j+48|0);Gd(j+256|0,h+1024|0);rb(j+256|0,35286);Gd(j+240|0,h+1040|0);rb(j+240|0,35286);Gd(j+224|0,h+1056|0);rb(j+224|0,35286);Gd(j+208|0,h+1072|0);rb(j+208|0,35286);Gd(j+192|0,h+1088|0);rb(j+192|0,35286);Gd(j+176|0,h+1104|0);rb(j+176|0,35286);Gd(j+160|0,h+1120|0);rb(j+160|0,35286);Gd(j+144|0,h+1136|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+1152|0);rb(j+128|0,35302);Gd(j+112|0,h+1168|0);rb(j+112|0,35302);Gd(j+96|0,h+1184|0);rb(j+96|0,35302);Gd(j+80|0,h+1200|0);rb(j+80|0,35302);Gd(j+64|0,h+1216|0);rb(j+64|0,35302);Gd(j+48|0,h+1232|0);rb(j+48|0,35302);Gd(j+32|0,h+1248|0);rb(j+32|0,35302);Gd(j+16|0,h+1264|0);rb(j+16|0,35302);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);Gd(j+128|0,h+1280|0);Gd(j+112|0,h+1296|0);Gd(j+64|0,h+1312|0);Gd(j+32|0,h+1328|0);Gd(j+80|0,h+1344|0);Gd(j+16|0,h+1360|0);Gd(j+96|0,h+1376|0);Gd(j+48|0,h+1392|0);Ce(j+256|0,j+96|0);_d(j+256|0,1);Gd(j+256|0,j+48|0);Hd(j+256|0,1104);Gd(j+48|0,j+256|0);ae(j+256|0,1);Gd(j+96|0,j+256|0);Ce(j+256|0,j+80|0);_d(j+256|0,1);Gd(j+256|0,j+16|0);Hd(j+256|0,1104);Gd(j+16|0,j+256|0);ae(j+256|0,1);Gd(j+80|0,j+256|0);Ce(j+256|0,j+64|0);_d(j+256|0,1);Gd(j+256|0,j+32|0);Hd(j+256|0,1104);Gd(j+32|0,j+256|0);ae(j+256|0,1);Gd(j+64|0,j+256|0);Ce(j+256|0,j+128|0);_d(j+256|0,1);Gd(j+256|0,j+112|0);Hd(j+256|0,1104);Gd(j+112|0,j+256|0);ae(j+256|0,1);Gd(j+128|0,j+256|0);Ce(j+256|0,j+16|0);_d(j+256|0,2);Gd(j+256|0,j+48|0);Hd(j+256|0,1120);Gd(j+48|0,j+256|0);ae(j+256|0,2);Gd(j+16|0,j+256|0);Ce(j+256|0,j+80|0);_d(j+256|0,2);Gd(j+256|0,j+96|0);Hd(j+256|0,1120);Gd(j+96|0,j+256|0);ae(j+256|0,2);Gd(j+80|0,j+256|0);Ce(j+256|0,j+112|0);_d(j+256|0,2);Gd(j+256|0,j+32|0);Hd(j+256|0,1120);Gd(j+32|0,j+256|0);ae(j+256|0,2);Gd(j+112|0,j+256|0);Ce(j+256|0,j+128|0);_d(j+256|0,2);Gd(j+256|0,j+64|0);Hd(j+256|0,1120);Gd(j+64|0,j+256|0);ae(j+256|0,2);Gd(j+128|0,j+256|0);Ce(j+256|0,j+32|0);_d(j+256|0,4);Gd(j+256|0,j+48|0);Hd(j+256|0,1136);Gd(j+48|0,j+256|0);ae(j+256|0,4);Gd(j+32|0,j+256|0);Ce(j+256|0,j+64|0);_d(j+256|0,4);Gd(j+256|0,j+96|0);Hd(j+256|0,1136);Gd(j+96|0,j+256|0);ae(j+256|0,4);Gd(j+64|0,j+256|0);Ce(j+256|0,j+112|0);_d(j+256|0,4);Gd(j+256|0,j+16|0);Hd(j+256|0,1136);Gd(j+16|0,j+256|0);ae(j+256|0,4);Gd(j+112|0,j+256|0);Ce(j+256|0,j+128|0);_d(j+256|0,4);Gd(j+256|0,j+80|0);Hd(j+256|0,1136);Gd(j+80|0,j+256|0);ae(j+256|0,4);Gd(j+128|0,j+256|0);if(f>>>0<0|(f|0)==0&e>>>0<128){i=5;break}gg(j+12|0,(ug(j+12|0)|0)+8|0);Gd(j+128|0,d);Gd(j+112|0,d+16|0);Gd(j+64|0,d+32|0);Gd(j+32|0,d+48|0);Gd(j+80|0,d+64|0);Gd(j+16|0,d+80|0);Gd(j+96|0,d+96|0);Gd(j+48|0,d+112|0);c[b>>2]=c[j+128>>2];c[b+4>>2]=c[j+128+4>>2];c[b+8>>2]=c[j+128+8>>2];c[b+12>>2]=c[j+128+12>>2];g=b+16|0;c[g>>2]=c[j+112>>2];c[g+4>>2]=c[j+112+4>>2];c[g+8>>2]=c[j+112+8>>2];c[g+12>>2]=c[j+112+12>>2];g=b+32|0;c[g>>2]=c[j+64>>2];c[g+4>>2]=c[j+64+4>>2];c[g+8>>2]=c[j+64+8>>2];c[g+12>>2]=c[j+64+12>>2];g=b+48|0;c[g>>2]=c[j+32>>2];c[g+4>>2]=c[j+32+4>>2];c[g+8>>2]=c[j+32+8>>2];c[g+12>>2]=c[j+32+12>>2];g=b+64|0;c[g>>2]=c[j+80>>2];c[g+4>>2]=c[j+80+4>>2];c[g+8>>2]=c[j+80+8>>2];c[g+12>>2]=c[j+80+12>>2];g=b+80|0;c[g>>2]=c[j+16>>2];c[g+4>>2]=c[j+16+4>>2];c[g+8>>2]=c[j+16+8>>2];c[g+12>>2]=c[j+16+12>>2];g=b+96|0;c[g>>2]=c[j+96>>2];c[g+4>>2]=c[j+96+4>>2];c[g+8>>2]=c[j+96+8>>2];c[g+12>>2]=c[j+96+12>>2];g=b+112|0;c[g>>2]=c[j+48>>2];c[g+4>>2]=c[j+48+4>>2];c[g+8>>2]=c[j+48+8>>2];c[g+12>>2]=c[j+48+12>>2];if((e|0)==128&(f|0)==0)break;g=fg(e|0,f|0,-128,-1)|0;b=b+128|0;d=d+128|0;f=z;e=g}if((i|0)==5?(h=yf(e|0,f|0,4)|0,i=z,i=fg(ug(j+12|0)|0,0,h|0,i|0)|0,gg(j+12|0,i),c[j+272>>2]=c[j+128>>2],c[j+272+4>>2]=c[j+128+4>>2],c[j+272+8>>2]=c[j+128+8>>2],c[j+272+12>>2]=c[j+128+12>>2],c[j+272+16>>2]=c[j+112>>2],c[j+272+16+4>>2]=c[j+112+4>>2],c[j+272+16+8>>2]=c[j+112+8>>2],c[j+272+16+12>>2]=c[j+112+12>>2],c[j+272+32>>2]=c[j+64>>2],c[j+272+32+4>>2]=c[j+64+4>>2],c[j+272+32+8>>2]=c[j+64+8>>2],c[j+272+32+12>>2]=c[j+64+12>>2],c[j+272+48>>2]=c[j+32>>2],c[j+272+48+4>>2]=c[j+32+4>>2],c[j+272+48+8>>2]=c[j+32+8>>2],c[j+272+48+12>>2]=c[j+32+12>>2],c[j+272+64>>2]=c[j+80>>2],c[j+272+64+4>>2]=c[j+80+4>>2],c[j+272+64+8>>2]=c[j+80+8>>2],c[j+272+64+12>>2]=c[j+80+12>>2],c[j+272+80>>2]=c[j+16>>2],c[j+272+80+4>>2]=c[j+16+4>>2],c[j+272+80+8>>2]=c[j+16+8>>2],c[j+272+80+12>>2]=c[j+16+12>>2],c[j+272+96>>2]=c[j+96>>2],c[j+272+96+4>>2]=c[j+96+4>>2],c[j+272+96+8>>2]=c[j+96+8>>2],c[j+272+96+12>>2]=c[j+96+12>>2],c[j+272+112>>2]=c[j+48>>2],c[j+272+112+4>>2]=c[j+48+4>>2],c[j+272+112+8>>2]=c[j+48+8>>2],c[j+272+112+12>>2]=c[j+48+12>>2],!((e|0)==0&(f|0)==0)):0){g=j+272|0;while(1){a[b>>0]=a[d>>0]^a[g>>0];e=fg(e|0,f|0,-1,-1)|0;f=z;if((e|0)==0&(f|0)==0)break;else{g=g+1|0;d=d+1|0;b=b+1|0}}}l=k;return 0}function fa(b,d,e,f,g){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0;j=l;i=l=l+63&-64;l=l+400|0;Ce(i,f);while(1){c[i+256>>2]=c[i>>2];c[i+256+4>>2]=c[i+4>>2];c[i+256+8>>2]=c[i+8>>2];c[i+256+12>>2]=c[i+12>>2];Ce(i+240|0,i+256|0);rb(i+240|0,35254);Ce(i+224|0,i+240|0);Ce(i+208|0,i+240|0);Ce(i+192|0,i+240|0);Ce(i+176|0,i+240|0);Ce(i+160|0,i+240|0);Ce(i+144|0,i+240|0);Eg(i+240|0,1);Eg(i+224|0,2);Eg(i+208|0,3);Eg(i+192|0,4);Eg(i+176|0,5);Eg(i+160|0,6);Eg(i+144|0,7);rb(i+256|0,35222);rb(i+240|0,35270);rb(i+224|0,35270);rb(i+208|0,35270);rb(i+192|0,35270);rb(i+176|0,35270);rb(i+160|0,35270);rb(i+144|0,35270);Ce(i+128|0,i+160|0);_d(i+128|0,1);Gd(i+128|0,i+144|0);Hd(i+128|0,1104);Gd(i+144|0,i+128|0);ae(i+128|0,1);Gd(i+160|0,i+128|0);Ce(i+128|0,i+192|0);_d(i+128|0,1);Gd(i+128|0,i+176|0);Hd(i+128|0,1104);Gd(i+176|0,i+128|0);ae(i+128|0,1);Gd(i+192|0,i+128|0);Ce(i+128|0,i+224|0);_d(i+128|0,1);Gd(i+128|0,i+208|0);Hd(i+128|0,1104);Gd(i+208|0,i+128|0);ae(i+128|0,1);Gd(i+224|0,i+128|0);Ce(i+128|0,i+256|0);_d(i+128|0,1);Gd(i+128|0,i+240|0);Hd(i+128|0,1104);Gd(i+240|0,i+128|0);ae(i+128|0,1);Gd(i+256|0,i+128|0);Ce(i+128|0,i+176|0);_d(i+128|0,2);Gd(i+128|0,i+144|0);Hd(i+128|0,1120);Gd(i+144|0,i+128|0);ae(i+128|0,2);Gd(i+176|0,i+128|0);Ce(i+128|0,i+192|0);_d(i+128|0,2);Gd(i+128|0,i+160|0);Hd(i+128|0,1120);Gd(i+160|0,i+128|0);ae(i+128|0,2);Gd(i+192|0,i+128|0);Ce(i+128|0,i+240|0);_d(i+128|0,2);Gd(i+128|0,i+208|0);Hd(i+128|0,1120);Gd(i+208|0,i+128|0);ae(i+128|0,2);Gd(i+240|0,i+128|0);Ce(i+128|0,i+256|0);_d(i+128|0,2);Gd(i+128|0,i+224|0);Hd(i+128|0,1120);Gd(i+224|0,i+128|0);ae(i+128|0,2);Gd(i+256|0,i+128|0);Ce(i+128|0,i+208|0);_d(i+128|0,4);Gd(i+128|0,i+144|0);Hd(i+128|0,1136);Gd(i+144|0,i+128|0);ae(i+128|0,4);Gd(i+208|0,i+128|0);Ce(i+128|0,i+224|0);_d(i+128|0,4);Gd(i+128|0,i+160|0);Hd(i+128|0,1136);Gd(i+160|0,i+128|0);ae(i+128|0,4);Gd(i+224|0,i+128|0);Ce(i+128|0,i+240|0);_d(i+128|0,4);Gd(i+128|0,i+176|0);Hd(i+128|0,1136);Gd(i+176|0,i+128|0);ae(i+128|0,4);Gd(i+240|0,i+128|0);Ce(i+128|0,i+256|0);_d(i+128|0,4);Gd(i+128|0,i+192|0);Hd(i+128|0,1136);Gd(i+192|0,i+128|0);ae(i+128|0,4);Gd(i+256|0,i+128|0);Gd(i+256|0,g);rb(i+256|0,35286);Gd(i+240|0,g+16|0);rb(i+240|0,35286);Gd(i+224|0,g+32|0);rb(i+224|0,35286);Gd(i+208|0,g+48|0);rb(i+208|0,35286);Gd(i+192|0,g+64|0);rb(i+192|0,35286);Gd(i+176|0,g+80|0);rb(i+176|0,35286);Gd(i+160|0,g+96|0);rb(i+160|0,35286);Gd(i+144|0,g+112|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+128|0);rb(i+128|0,35286);Gd(i+112|0,g+144|0);rb(i+112|0,35286);Gd(i+96|0,g+160|0);rb(i+96|0,35286);Gd(i+80|0,g+176|0);rb(i+80|0,35286);Gd(i+64|0,g+192|0);rb(i+64|0,35286);Gd(i+48|0,g+208|0);rb(i+48|0,35286);Gd(i+32|0,g+224|0);rb(i+32|0,35286);Gd(i+16|0,g+240|0);rb(i+16|0,35286);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);_c(i+256|0,i+128|0,147);_c(i+240|0,i+112|0,147);_c(i+224|0,i+64|0,147);_c(i+208|0,i+32|0,147);_c(i+192|0,i+80|0,147);_c(i+176|0,i+16|0,147);_c(i+160|0,i+96|0,147);_c(i+144|0,i+48|0,147);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+64|0,i+224|0);Gd(i+32|0,i+208|0);Gd(i+80|0,i+192|0);Gd(i+16|0,i+176|0);Gd(i+96|0,i+160|0);Gd(i+48|0,i+144|0);Gd(i+256|0,i+48|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+112|0);Gd(i+240|0,i+48|0);Gd(i+208|0,i+64|0);Gd(i+192|0,i+32|0);Gd(i+176|0,i+80|0);Gd(i+208|0,i+48|0);Gd(i+160|0,i+16|0);Gd(i+144|0,i+96|0);Gd(i+192|0,i+48|0);_c(i+128|0,i+128|0,78);_c(i+112|0,i+112|0,78);_c(i+64|0,i+64|0,78);_c(i+32|0,i+32|0,78);_c(i+80|0,i+80|0,78);_c(i+16|0,i+16|0,78);_c(i+96|0,i+96|0,78);_c(i+48|0,i+48|0,78);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+224|0,i+64|0);Gd(i+208|0,i+32|0);Gd(i+192|0,i+80|0);Gd(i+176|0,i+16|0);Gd(i+160|0,i+96|0);Gd(i+144|0,i+48|0);Gd(i+256|0,g+256|0);rb(i+256|0,35286);Gd(i+240|0,g+272|0);rb(i+240|0,35286);Gd(i+224|0,g+288|0);rb(i+224|0,35286);Gd(i+208|0,g+304|0);rb(i+208|0,35286);Gd(i+192|0,g+320|0);rb(i+192|0,35286);Gd(i+176|0,g+336|0);rb(i+176|0,35286);Gd(i+160|0,g+352|0);rb(i+160|0,35286);Gd(i+144|0,g+368|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+384|0);rb(i+128|0,35286);Gd(i+112|0,g+400|0);rb(i+112|0,35286);Gd(i+96|0,g+416|0);rb(i+96|0,35286);Gd(i+80|0,g+432|0);rb(i+80|0,35286);Gd(i+64|0,g+448|0);rb(i+64|0,35286);Gd(i+48|0,g+464|0);rb(i+48|0,35286);Gd(i+32|0,g+480|0);rb(i+32|0,35286);Gd(i+16|0,g+496|0);rb(i+16|0,35286);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);_c(i+256|0,i+128|0,147);_c(i+240|0,i+112|0,147);_c(i+224|0,i+64|0,147);_c(i+208|0,i+32|0,147);_c(i+192|0,i+80|0,147);_c(i+176|0,i+16|0,147);_c(i+160|0,i+96|0,147);_c(i+144|0,i+48|0,147);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+64|0,i+224|0);Gd(i+32|0,i+208|0);Gd(i+80|0,i+192|0);Gd(i+16|0,i+176|0);Gd(i+96|0,i+160|0);Gd(i+48|0,i+144|0);Gd(i+256|0,i+48|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+112|0);Gd(i+240|0,i+48|0);Gd(i+208|0,i+64|0);Gd(i+192|0,i+32|0);Gd(i+176|0,i+80|0);Gd(i+208|0,i+48|0);Gd(i+160|0,i+16|0);Gd(i+144|0,i+96|0);Gd(i+192|0,i+48|0);_c(i+128|0,i+128|0,78);_c(i+112|0,i+112|0,78);_c(i+64|0,i+64|0,78);_c(i+32|0,i+32|0,78);_c(i+80|0,i+80|0,78);_c(i+16|0,i+16|0,78);_c(i+96|0,i+96|0,78);_c(i+48|0,i+48|0,78);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+224|0,i+64|0);Gd(i+208|0,i+32|0);Gd(i+192|0,i+80|0);Gd(i+176|0,i+16|0);Gd(i+160|0,i+96|0);Gd(i+144|0,i+48|0);Gd(i+256|0,g+512|0);rb(i+256|0,35286);Gd(i+240|0,g+528|0);rb(i+240|0,35286);Gd(i+224|0,g+544|0);rb(i+224|0,35286);Gd(i+208|0,g+560|0);rb(i+208|0,35286);Gd(i+192|0,g+576|0);rb(i+192|0,35286);Gd(i+176|0,g+592|0);rb(i+176|0,35286);Gd(i+160|0,g+608|0);rb(i+160|0,35286);Gd(i+144|0,g+624|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+640|0);rb(i+128|0,35286);Gd(i+112|0,g+656|0);rb(i+112|0,35286);Gd(i+96|0,g+672|0);rb(i+96|0,35286);Gd(i+80|0,g+688|0);rb(i+80|0,35286);Gd(i+64|0,g+704|0);rb(i+64|0,35286);Gd(i+48|0,g+720|0);rb(i+48|0,35286);Gd(i+32|0,g+736|0);rb(i+32|0,35286);Gd(i+16|0,g+752|0);rb(i+16|0,35286);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);_c(i+256|0,i+128|0,147);_c(i+240|0,i+112|0,147);_c(i+224|0,i+64|0,147);_c(i+208|0,i+32|0,147);_c(i+192|0,i+80|0,147);_c(i+176|0,i+16|0,147);_c(i+160|0,i+96|0,147);_c(i+144|0,i+48|0,147);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+64|0,i+224|0);Gd(i+32|0,i+208|0);Gd(i+80|0,i+192|0);Gd(i+16|0,i+176|0);Gd(i+96|0,i+160|0);Gd(i+48|0,i+144|0);Gd(i+256|0,i+48|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+112|0);Gd(i+240|0,i+48|0);Gd(i+208|0,i+64|0);Gd(i+192|0,i+32|0);Gd(i+176|0,i+80|0);Gd(i+208|0,i+48|0);Gd(i+160|0,i+16|0);Gd(i+144|0,i+96|0);Gd(i+192|0,i+48|0);_c(i+128|0,i+128|0,78);_c(i+112|0,i+112|0,78);_c(i+64|0,i+64|0,78);_c(i+32|0,i+32|0,78);_c(i+80|0,i+80|0,78);_c(i+16|0,i+16|0,78);_c(i+96|0,i+96|0,78);_c(i+48|0,i+48|0,78);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+224|0,i+64|0);Gd(i+208|0,i+32|0);Gd(i+192|0,i+80|0);Gd(i+176|0,i+16|0);Gd(i+160|0,i+96|0);Gd(i+144|0,i+48|0);Gd(i+256|0,g+768|0);rb(i+256|0,35286);Gd(i+240|0,g+784|0);rb(i+240|0,35286);Gd(i+224|0,g+800|0);rb(i+224|0,35286);Gd(i+208|0,g+816|0);rb(i+208|0,35286);Gd(i+192|0,g+832|0);rb(i+192|0,35286);Gd(i+176|0,g+848|0);rb(i+176|0,35286);Gd(i+160|0,g+864|0);rb(i+160|0,35286);Gd(i+144|0,g+880|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+896|0);rb(i+128|0,35286);Gd(i+112|0,g+912|0);rb(i+112|0,35286);Gd(i+96|0,g+928|0);rb(i+96|0,35286);Gd(i+80|0,g+944|0);rb(i+80|0,35286);Gd(i+64|0,g+960|0);rb(i+64|0,35286);Gd(i+48|0,g+976|0);rb(i+48|0,35286);Gd(i+32|0,g+992|0);rb(i+32|0,35286);Gd(i+16|0,g+1008|0);rb(i+16|0,35286);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);_c(i+256|0,i+128|0,147);_c(i+240|0,i+112|0,147);_c(i+224|0,i+64|0,147);_c(i+208|0,i+32|0,147);_c(i+192|0,i+80|0,147);_c(i+176|0,i+16|0,147);_c(i+160|0,i+96|0,147);_c(i+144|0,i+48|0,147);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+64|0,i+224|0);Gd(i+32|0,i+208|0);Gd(i+80|0,i+192|0);Gd(i+16|0,i+176|0);Gd(i+96|0,i+160|0);Gd(i+48|0,i+144|0);Gd(i+256|0,i+48|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+112|0);Gd(i+240|0,i+48|0);Gd(i+208|0,i+64|0);Gd(i+192|0,i+32|0);Gd(i+176|0,i+80|0);Gd(i+208|0,i+48|0);Gd(i+160|0,i+16|0);Gd(i+144|0,i+96|0);Gd(i+192|0,i+48|0);_c(i+128|0,i+128|0,78);_c(i+112|0,i+112|0,78);_c(i+64|0,i+64|0,78);_c(i+32|0,i+32|0,78);_c(i+80|0,i+80|0,78);_c(i+16|0,i+16|0,78);_c(i+96|0,i+96|0,78);_c(i+48|0,i+48|0,78);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+224|0,i+64|0);Gd(i+208|0,i+32|0);Gd(i+192|0,i+80|0);Gd(i+176|0,i+16|0);Gd(i+160|0,i+96|0);Gd(i+144|0,i+48|0);Gd(i+256|0,g+1024|0);rb(i+256|0,35286);Gd(i+240|0,g+1040|0);rb(i+240|0,35286);Gd(i+224|0,g+1056|0);rb(i+224|0,35286);Gd(i+208|0,g+1072|0);rb(i+208|0,35286);Gd(i+192|0,g+1088|0);rb(i+192|0,35286);Gd(i+176|0,g+1104|0);rb(i+176|0,35286);Gd(i+160|0,g+1120|0);rb(i+160|0,35286);Gd(i+144|0,g+1136|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+1152|0);rb(i+128|0,35302);Gd(i+112|0,g+1168|0);rb(i+112|0,35302);Gd(i+96|0,g+1184|0);rb(i+96|0,35302);Gd(i+80|0,g+1200|0);rb(i+80|0,35302);Gd(i+64|0,g+1216|0);rb(i+64|0,35302);Gd(i+48|0,g+1232|0);rb(i+48|0,35302);Gd(i+32|0,g+1248|0);rb(i+32|0,35302);Gd(i+16|0,g+1264|0);rb(i+16|0,35302);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);Gd(i+128|0,g+1280|0);Gd(i+112|0,g+1296|0);Gd(i+64|0,g+1312|0);Gd(i+32|0,g+1328|0);Gd(i+80|0,g+1344|0);Gd(i+16|0,g+1360|0);Gd(i+96|0,g+1376|0);Gd(i+48|0,g+1392|0);Ce(i+256|0,i+96|0);_d(i+256|0,1);Gd(i+256|0,i+48|0);Hd(i+256|0,1104);Gd(i+48|0,i+256|0);ae(i+256|0,1);Gd(i+96|0,i+256|0);Ce(i+256|0,i+80|0);_d(i+256|0,1);Gd(i+256|0,i+16|0);Hd(i+256|0,1104);Gd(i+16|0,i+256|0);ae(i+256|0,1);Gd(i+80|0,i+256|0);Ce(i+256|0,i+64|0);_d(i+256|0,1);Gd(i+256|0,i+32|0);Hd(i+256|0,1104);Gd(i+32|0,i+256|0);ae(i+256|0,1);Gd(i+64|0,i+256|0);Ce(i+256|0,i+128|0);_d(i+256|0,1);Gd(i+256|0,i+112|0);Hd(i+256|0,1104);Gd(i+112|0,i+256|0);ae(i+256|0,1);Gd(i+128|0,i+256|0);Ce(i+256|0,i+16|0);_d(i+256|0,2);Gd(i+256|0,i+48|0);Hd(i+256|0,1120);Gd(i+48|0,i+256|0);ae(i+256|0,2);Gd(i+16|0,i+256|0);Ce(i+256|0,i+80|0);_d(i+256|0,2);Gd(i+256|0,i+96|0);Hd(i+256|0,1120);Gd(i+96|0,i+256|0);ae(i+256|0,2);Gd(i+80|0,i+256|0);Ce(i+256|0,i+112|0);_d(i+256|0,2);Gd(i+256|0,i+32|0);Hd(i+256|0,1120);Gd(i+32|0,i+256|0);ae(i+256|0,2);Gd(i+112|0,i+256|0);Ce(i+256|0,i+128|0);_d(i+256|0,2);Gd(i+256|0,i+64|0);Hd(i+256|0,1120);Gd(i+64|0,i+256|0);ae(i+256|0,2);Gd(i+128|0,i+256|0);Ce(i+256|0,i+32|0);_d(i+256|0,4);Gd(i+256|0,i+48|0);Hd(i+256|0,1136);Gd(i+48|0,i+256|0);ae(i+256|0,4);Gd(i+32|0,i+256|0);Ce(i+256|0,i+64|0);_d(i+256|0,4);Gd(i+256|0,i+96|0);Hd(i+256|0,1136);Gd(i+96|0,i+256|0);ae(i+256|0,4);Gd(i+64|0,i+256|0);Ce(i+256|0,i+112|0);_d(i+256|0,4);Gd(i+256|0,i+16|0);Hd(i+256|0,1136);Gd(i+16|0,i+256|0);ae(i+256|0,4);Gd(i+112|0,i+256|0);Ce(i+256|0,i+128|0);_d(i+256|0,4);Gd(i+256|0,i+80|0);Hd(i+256|0,1136);Gd(i+80|0,i+256|0);ae(i+256|0,4);Gd(i+128|0,i+256|0);if(e>>>0<0|(e|0)==0&d>>>0<128){h=5;break}gg(i+12|0,(ug(i+12|0)|0)+8|0);c[b>>2]=c[i+128>>2];c[b+4>>2]=c[i+128+4>>2];c[b+8>>2]=c[i+128+8>>2];c[b+12>>2]=c[i+128+12>>2];f=b+16|0;c[f>>2]=c[i+112>>2];c[f+4>>2]=c[i+112+4>>2];c[f+8>>2]=c[i+112+8>>2];c[f+12>>2]=c[i+112+12>>2];f=b+32|0;c[f>>2]=c[i+64>>2];c[f+4>>2]=c[i+64+4>>2];c[f+8>>2]=c[i+64+8>>2];c[f+12>>2]=c[i+64+12>>2];f=b+48|0;c[f>>2]=c[i+32>>2];c[f+4>>2]=c[i+32+4>>2];c[f+8>>2]=c[i+32+8>>2];c[f+12>>2]=c[i+32+12>>2];f=b+64|0;c[f>>2]=c[i+80>>2];c[f+4>>2]=c[i+80+4>>2];c[f+8>>2]=c[i+80+8>>2];c[f+12>>2]=c[i+80+12>>2];f=b+80|0;c[f>>2]=c[i+16>>2];c[f+4>>2]=c[i+16+4>>2];c[f+8>>2]=c[i+16+8>>2];c[f+12>>2]=c[i+16+12>>2];f=b+96|0;c[f>>2]=c[i+96>>2];c[f+4>>2]=c[i+96+4>>2];c[f+8>>2]=c[i+96+8>>2];c[f+12>>2]=c[i+96+12>>2];f=b+112|0;c[f>>2]=c[i+48>>2];c[f+4>>2]=c[i+48+4>>2];c[f+8>>2]=c[i+48+8>>2];c[f+12>>2]=c[i+48+12>>2];if((d|0)==128&(e|0)==0)break;f=fg(d|0,e|0,-128,-1)|0;b=b+128|0;e=z;d=f}if((h|0)==5?(g=yf(d|0,e|0,4)|0,h=z,h=fg(ug(i+12|0)|0,0,g|0,h|0)|0,gg(i+12|0,h),c[i+272>>2]=c[i+128>>2],c[i+272+4>>2]=c[i+128+4>>2],c[i+272+8>>2]=c[i+128+8>>2],c[i+272+12>>2]=c[i+128+12>>2],c[i+272+16>>2]=c[i+112>>2],c[i+272+16+4>>2]=c[i+112+4>>2],c[i+272+16+8>>2]=c[i+112+8>>2],c[i+272+16+12>>2]=c[i+112+12>>2],c[i+272+32>>2]=c[i+64>>2],c[i+272+32+4>>2]=c[i+64+4>>2],c[i+272+32+8>>2]=c[i+64+8>>2],c[i+272+32+12>>2]=c[i+64+12>>2],c[i+272+48>>2]=c[i+32>>2],c[i+272+48+4>>2]=c[i+32+4>>2],c[i+272+48+8>>2]=c[i+32+8>>2],c[i+272+48+12>>2]=c[i+32+12>>2],c[i+272+64>>2]=c[i+80>>2],c[i+272+64+4>>2]=c[i+80+4>>2],c[i+272+64+8>>2]=c[i+80+8>>2],c[i+272+64+12>>2]=c[i+80+12>>2],c[i+272+80>>2]=c[i+16>>2],c[i+272+80+4>>2]=c[i+16+4>>2],c[i+272+80+8>>2]=c[i+16+8>>2],c[i+272+80+12>>2]=c[i+16+12>>2],c[i+272+96>>2]=c[i+96>>2],c[i+272+96+4>>2]=c[i+96+4>>2],c[i+272+96+8>>2]=c[i+96+8>>2],c[i+272+96+12>>2]=c[i+96+12>>2],c[i+272+112>>2]=c[i+48>>2],c[i+272+112+4>>2]=c[i+48+4>>2],c[i+272+112+8>>2]=c[i+48+8>>2],c[i+272+112+12>>2]=c[i+48+12>>2],!((d|0)==0&(e|0)==0)):0){f=i+272|0;while(1){a[b>>0]=a[f>>0]|0;d=fg(d|0,e|0,-1,-1)|0;e=z;if((d|0)==0&(e|0)==0)break;else{f=f+1|0;b=b+1|0}}}l=j;return 0} +function Ab(b,c){b=b|0;c=c|0;var e=0,f=0,g=0,h=0,i=0;e=0;do{a[b+e>>0]=(d[c+(e>>3)>>0]|0)>>>(e&7)&1;e=e+1|0}while((e|0)!=256);h=0;do{i=b+h|0;a:do if(a[i>>0]|0){g=1;do{e=g+h|0;if((e|0)>=256)break a;c=a[b+e>>0]|0;b:do if(c<<24>>24){f=a[i>>0]|0;c=c<<24>>24<<g;if((f+c|0)<16){a[i>>0]=f+c;a[b+e>>0]=0;break}if((f-c|0)<=-16)break a;a[i>>0]=f-c;while(1){c=b+e|0;if(!(a[c>>0]|0))break;a[c>>0]=0;e=e+1|0;if((e|0)>=256)break b}a[c>>0]=1}while(0);g=g+1|0}while((g|0)<7)}while(0);h=h+1|0}while((h|0)!=256);return}function Bb(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0;a:do if(!((e|0)==0&(f|0)==0)){g=c[b+352>>2]|0;j=f;while(1){i=256-g|0;f=b+96+g|0;if(!(j>>>0>0|(j|0)==0&e>>>0>i>>>0))break;fb(f|0,d|0,i|0)|0;c[b+352>>2]=(c[b+352>>2]|0)+i;cd(b,128,0);ga(b,b+96|0);f=b+96|0;g=b+224|0;h=f+128|0;do{a[f>>0]=a[g>>0]|0;f=f+1|0;g=g+1|0}while((f|0)<(h|0));g=(c[b+352>>2]|0)+-128|0;c[b+352>>2]=g;e=cg(e|0,j|0,i|0,0)|0;f=z;if((e|0)==0&(f|0)==0)break a;else{d=d+i|0;j=f}}fb(f|0,d|0,e|0)|0;j=fg(c[b+352>>2]|0,0,e|0,j|0)|0;c[b+352>>2]=j}while(0);return}function Cb(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0;j=(c[d>>2]|0)==0;h=c[d+12>>2]|0;do if(j){g=a[d+8>>0]|0;if(!(g<<24>>24)){g=h+-1|0;break}g=O(c[b+12>>2]|0,g&255)|0;if(!f){g=g+(((h|0)==0)<<31>>31)|0;break}else{g=h+-1+g|0;break}}else{g=(c[b+16>>2]|0)-(c[b+12>>2]|0)|0;if(!f){g=g+(((h|0)==0)<<31>>31)|0;break}else{g=h+-1+g|0;break}}while(0);af(e|0,0,e|0,0)|0;af(g|0,0,z|0,0)|0;h=cg(g+-1|0,0,z|0,0)|0;e=z;if(!j?(i=a[d+8>>0]|0,i<<24>>24!=3):0){g=O(c[b+12>>2]|0,(i&255)+1|0)|0;f=0}else{g=0;f=0}j=fg(h|0,e|0,g|0,f|0)|0;b=Pe(j|0,z|0,c[b+16>>2]|0,0)|0;return b|0}function Db(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0;if(d<<24>>24?(d&255)<=64:0){if(!(sh(c[a+80>>2]|0,c[a+80+4>>2]|0)|0)){e=c[a+352>>2]|0;do if(e>>>0>128){cd(a,128,0);ga(a,a+96|0);e=(c[a+352>>2]|0)+-128|0;c[a+352>>2]=e;if(e>>>0<129){fb(a+96|0,a+224|0,e|0)|0;f=a+96|0;g=c[a+352>>2]|0;break}else ba(33525,33557,367,33602)}else{f=a+96|0;g=e}while(0);cd(a,g,0);ig(a);e=c[a+352>>2]|0;Pb(a+96+e|0,0,256-e|0)|0;ga(a,f);fb(b|0,a|0,d&255|0)|0;e=0}else e=-1;return e|0}Z();return 0}function Eb(b,c,e,f){b=b|0;c=c|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0;switch(((f>>>0)%3|0)&3){case 2:{g=((f>>>0)/3|0)<<2|1;h=3;break}case 1:{g=((f>>>0)/3|0)<<2;h=3;break}default:g=((f>>>0)/3|0)<<2}if((h|0)==3)g=g+2|0;if(g>>>0<c>>>0){if(f){i=0;c=0;while(1){i=d[e>>0]|0|i<<8;c=c+8|0;while(1){j=c+-6|0;h=b+1|0;a[b>>0]=xe(i>>>j&63)|0;if(j>>>0>5){b=h;c=j}else break}f=f+-1|0;if(!f)break;else{e=e+1|0;b=h;c=j}}if(!j)b=h;else{a[h>>0]=xe(i<<12-c&63)|0;b=b+2|0}}a[b>>0]=0}else g=-1;return g|0}function Fb(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0;m=(c[b+4>>2]|0)-(c[d+4>>2]|0)|0;l=(c[b+8>>2]|0)-(c[d+8>>2]|0)|0;k=(c[b+12>>2]|0)-(c[d+12>>2]|0)|0;j=(c[b+16>>2]|0)-(c[d+16>>2]|0)|0;i=(c[b+20>>2]|0)-(c[d+20>>2]|0)|0;h=(c[b+24>>2]|0)-(c[d+24>>2]|0)|0;g=(c[b+28>>2]|0)-(c[d+28>>2]|0)|0;f=(c[b+32>>2]|0)-(c[d+32>>2]|0)|0;e=(c[b+36>>2]|0)-(c[d+36>>2]|0)|0;c[a>>2]=(c[b>>2]|0)-(c[d>>2]|0);c[a+4>>2]=m;c[a+8>>2]=l;c[a+12>>2]=k;c[a+16>>2]=j;c[a+20>>2]=i;c[a+24>>2]=h;c[a+28>>2]=g;c[a+32>>2]=f;c[a+36>>2]=e;return}function Gb(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0;m=(c[d+4>>2]|0)+(c[b+4>>2]|0)|0;l=(c[d+8>>2]|0)+(c[b+8>>2]|0)|0;k=(c[d+12>>2]|0)+(c[b+12>>2]|0)|0;j=(c[d+16>>2]|0)+(c[b+16>>2]|0)|0;i=(c[d+20>>2]|0)+(c[b+20>>2]|0)|0;h=(c[d+24>>2]|0)+(c[b+24>>2]|0)|0;g=(c[d+28>>2]|0)+(c[b+28>>2]|0)|0;f=(c[d+32>>2]|0)+(c[b+32>>2]|0)|0;e=(c[d+36>>2]|0)+(c[b+36>>2]|0)|0;c[a>>2]=(c[d>>2]|0)+(c[b>>2]|0);c[a+4>>2]=m;c[a+8>>2]=l;c[a+12>>2]=k;c[a+16>>2]=j;c[a+20>>2]=i;c[a+24>>2]=h;c[a+28>>2]=g;c[a+32>>2]=f;c[a+36>>2]=e;return}function Hb(b,d){b=b|0;d=d|0;var e=0,f=0;a:do if(!(d&255))b=b+(uc(b)|0)|0;else{if(b&3)do{f=a[b>>0]|0;if(f<<24>>24==0?1:f<<24>>24==(d&255)<<24>>24)break a;b=b+1|0}while((b&3|0)!=0);f=O(d&255,16843009)|0;e=c[b>>2]|0;b:do if(!((e&-2139062144^-2139062144)&e+-16843009))do{e=e^f;if((e&-2139062144^-2139062144)&e+-16843009|0)break b;b=b+4|0;e=c[b>>2]|0}while(!((e&-2139062144^-2139062144)&e+-16843009|0));while(0);while(1){f=a[b>>0]|0;if(f<<24>>24==0?1:f<<24>>24==(d&255)<<24>>24)break;else b=b+1|0}}while(0);return b|0}function Ib(b,e,f,g,h,i){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0;k=l;j=l=l+63&-64;l=l+32|0;m=d[h+4>>0]|d[h+4+1>>0]<<8|d[h+4+2>>0]<<16|d[h+4+3>>0]<<24;c[j>>2]=d[h>>0]|d[h+1>>0]<<8|d[h+2>>0]<<16|d[h+3>>0]<<24;c[j+4>>2]=m;c[j+8>>2]=0;c[j+8+4>>2]=0;re(j+16|0,f,g);h=j+16+8|0;a[h>>0]=0;a[h+1>>0]=0;a[h+2>>0]=0;a[h+3>>0]=0;h=j+16+8+4|0;a[h>>0]=0;a[h+1>>0]=0;a[h+2>>0]=0;a[h+3>>0]=0;if((e+-16|0)>>>0>48){c[8326]=22;b=-1}else b=Ec(b,e,0,0,0,i,32,j+16|0,j)|0;l=k;return b|0}function Jb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0,f=0;d=l;f=l=l+63&-64;l=l+128|0;e=Mg(c)|0;c=(c<<24>>24)-((c<<24>>24&0-(e&255))<<1)&255;Ff(a);Ke(a,2232+(b*960|0)|0,th(c,1)|0);Ke(a,2232+(b*960|0)+120|0,th(c,2)|0);Ke(a,2232+(b*960|0)+240|0,th(c,3)|0);Ke(a,2232+(b*960|0)+360|0,th(c,4)|0);Ke(a,2232+(b*960|0)+480|0,th(c,5)|0);Ke(a,2232+(b*960|0)+600|0,th(c,6)|0);Ke(a,2232+(b*960|0)+720|0,th(c,7)|0);Ke(a,2232+(b*960|0)+840|0,th(c,8)|0);qc(f,a+40|0);qc(f+40|0,a);dc(f+80|0,a+80|0);Ke(a,f,e);l=d;return}function Kb(a,b,d,e,f,g,h,i,j,k,m,n){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;n=n|0;k=l;l=l+336|0;Cg(k+264|0,64,0,m,n)|0;_g(k,k+264|0)|0;Sd(k+264|0,64);eg(k,h,i,j)|0;re(k+256|0,i,j);eg(k,k+256|0,8,0)|0;jf(a,e,f,g,m,1,0,n)|0;eg(k,a,f,g)|0;re(k+256|0,f,g);eg(k,k+256|0,8,0)|0;Zg(k,b)|0;Sd(k,256);if(d|0){c[d>>2]=16;c[d+4>>2]=0}l=k;return 0}function Lb(b,d,e,f,g,h,i){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0,n=0,o=0;o=l;k=l=l+63&-64;l=l+128|0;j=b;m=j+102|0;do{a[j>>0]=0;j=j+1|0}while((j|0)<(m|0));if(!(f>>>0>0|(f|0)==0&e>>>0>4294967295)){jb(g,h,i,k+8|0,k+4|0,k);gf(k+88|0,32);if((oc(c[k+8>>2]|0,c[k>>2]|0,c[k+4>>2]|0,k+88|0,k+24|0)|0)!=0?(Ih(k+12|0),m=(wb(k+12|0,d,e,k+24|0,b)|0)==0,Jh(k+12|0),!m):0)b=0;else{b=22;n=4}}else{b=27;n=4}if((n|0)==4){c[8326]=b;b=-1}l=o;return b|0}function Mb(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0;g=l;h=l=l+63&-64;l=l+64|0;if((c+-1&255)>63)Z();a[h>>0]=c;a[h+1>>0]=0;a[h+2>>0]=1;a[h+3>>0]=1;Vg(h+4|0);bf(h+8|0);c=h+16|0;f=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(f|0));if(!d){c=h+32|0;f=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(f|0))}else lf(h,d);if(!e){c=h+48|0;f=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(f|0))}else kf(h,e);ud(b,h);l=g;return}function Nb(b,c,d,e,f){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0;i=l;h=l=l+63&-64;l=l+480|0;g=(b|0)==0?c:b;c=(c|0)==0?g:c;if(!(bh(h+448|0,e,f)|0)){Dg(h,0,0,64)|0;rg(h,h+448|0,32,0)|0;Sd(h+448|0,32);rg(h,f,32,0)|0;rg(h,d,32,0)|0;Tg(h,h+384|0,64)|0;Sd(h,384);b=0;do{a[c+b>>0]=a[h+384+b>>0]|0;a[g+b>>0]=a[h+384+(b+32)>>0]|0;b=b+1|0}while((b|0)!=32);Sd(h+384|0,64);b=0}else b=-1;l=i;return b|0}function Ob(b,c,d,e,f){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0;i=l;h=l=l+63&-64;l=l+480|0;g=(b|0)==0?c:b;c=(c|0)==0?g:c;if(!(bh(h+448|0,e,f)|0)){Dg(h,0,0,64)|0;rg(h,h+448|0,32,0)|0;Sd(h+448|0,32);rg(h,d,32,0)|0;rg(h,f,32,0)|0;Tg(h,h+384|0,64)|0;Sd(h,384);b=0;do{a[g+b>>0]=a[h+384+b>>0]|0;a[c+b>>0]=a[h+384+(b+32)>>0]|0;b=b+1|0}while((b|0)!=32);Sd(h+384|0,64);b=0}else b=-1;l=i;return b|0}function Pb(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0;f=b+e|0;d=d&255;if((e|0)>=67){while(b&3){a[b>>0]=d;b=b+1|0}g=d|d<<8|d<<16|d<<24;while((b|0)<=((f&-4)-64|0)){c[b>>2]=g;c[b+4>>2]=g;c[b+8>>2]=g;c[b+12>>2]=g;c[b+16>>2]=g;c[b+20>>2]=g;c[b+24>>2]=g;c[b+28>>2]=g;c[b+32>>2]=g;c[b+36>>2]=g;c[b+40>>2]=g;c[b+44>>2]=g;c[b+48>>2]=g;c[b+52>>2]=g;c[b+56>>2]=g;c[b+60>>2]=g;b=b+64|0}while((b|0)<(f&-4|0)){c[b>>2]=g;b=b+4|0}}while((b|0)<(f|0)){a[b>>0]=d;b=b+1|0}return f-e|0}function Qb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+48|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);la(a+80|0,a,c+40|0);la(a+40|0,a+40|0,c);la(a+120|0,c+120|0,b+120|0);la(a,b+80|0,c+80|0);Gb(e,a,a);Fb(a,a+80|0,a+40|0);Gb(a+40|0,a+80|0,a+40|0);Fb(a+80|0,e,a+120|0);Gb(a+120|0,e,a+120|0);l=d;return}function Rb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+48|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);la(a+80|0,a,c);la(a+40|0,a+40|0,c+40|0);la(a+120|0,c+120|0,b+120|0);la(a,b+80|0,c+80|0);Gb(e,a,a);Fb(a,a+80|0,a+40|0);Gb(a+40|0,a+80|0,a+40|0);Gb(a+80|0,e,a+120|0);Fb(a+120|0,e,a+120|0);l=d;return}function Sb(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0;g=l;h=l=l+63&-64;l=l+192|0;if((c+-1&255)>63)Z();if((e+-1&255)>63|(d|0)==0)Z();else{a[h+128>>0]=c;a[h+128+1>>0]=e;a[h+128+2>>0]=1;a[h+128+3>>0]=1;Vg(h+128+4|0);bf(h+128+8|0);c=h+128+16|0;f=c+48|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(f|0));ud(b,h+128|0);Pb(h+(e&255)|0,0,(e<<24>>24<0?0:128-(e&255)|0)|0)|0;fb(h|0,d|0,e&255|0)|0;Bb(b,h,128,0);Sd(h,128);l=g;return}}function Tb(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0;e=l;f=l=l+63&-64;l=l+2048|0;if((a|0)!=0&(b|0)!=0){uh(f,(c[(c[b>>2]|0)+4>>2]|0)+(c[b+16>>2]<<10)+-1024|0);if((c[b+20>>2]|0)>>>0>1){d=1;do{g=c[b+16>>2]|0;g=g+-1+(O(g,d)|0)|0;Ud(f,(c[(c[b>>2]|0)+4>>2]|0)+(g<<10)|0);d=d+1|0}while(d>>>0<(c[b+20>>2]|0)>>>0)}Se(f+1024|0,f);Oa(c[a>>2]|0,c[a+4>>2]|0,f+1024|0,1024);Sd(f,1024);Sd(f+1024|0,1024);Gf(b,c[a+56>>2]&1);fh(c[b>>2]|0)}l=e;return}function Ub(a,b,d,e,f,g,h,i,j,k){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;var m=0,n=0;n=l;m=l=l+63&-64;l=l+16|0;Pb(a|0,0,b|0)|0;do if(!((g|d)>>>0>0|(g|d|0)==0&(f|b)>>>0>4294967295))if(d>>>0<0|(d|0)==0&b>>>0<16){c[8326]=22;a=-1;break}else{jb(i,j,k,m+8|0,m+4|0,m);k=vf(1,0,c[m+8>>2]|0)|0;a=dd(e,f,h,32,k,z,c[m>>2]|0,c[m+4>>2]|0,a,b)|0;break}else{c[8326]=27;a=-1}while(0);l=n;return a|0}function Vb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+48|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);la(a+80|0,a,c+40|0);la(a+40|0,a+40|0,c);la(a+120|0,c+80|0,b+120|0);Gb(e,b+80|0,b+80|0);Fb(a,a+80|0,a+40|0);Gb(a+40|0,a+80|0,a+40|0);Fb(a+80|0,e,a+120|0);Gb(a+120|0,e,a+120|0);l=d;return}function Wb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+48|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);la(a+80|0,a,c);la(a+40|0,a+40|0,c+40|0);la(a+120|0,c+80|0,b+120|0);Gb(e,b+80|0,b+80|0);Fb(a,a+80|0,a+40|0);Gb(a+40|0,a+80|0,a+40|0);Gb(a+80|0,e,a+120|0);Fb(a+120|0,e,a+120|0);l=d;return}function Xb(a,b,e,f,g,h,i,j,k,m,n,o){a=a|0;b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;n=n|0;o=o|0;m=l;l=l+48|0;c[m>>2]=0;Da(m+16|0,n,o,0)|0;o=d[n+16+4>>0]|d[n+16+4+1>>0]<<8|d[n+16+4+2>>0]<<16|d[n+16+4+3>>0]<<24;c[m+4>>2]=d[n+16>>0]|d[n+16+1>>0]<<8|d[n+16+2>>0]<<16|d[n+16+3>>0]<<24;c[m+4+4>>2]=o;yb(a,b,e,f,g,h,i,j,k,0,m,m+16|0)|0;Sd(m+16|0,32);l=m;return 0}function Yb(a,b,c,d,e,f,g,h,i){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0;j=l;k=l=l+63&-64;l=l+384|0;if((b|0)==0&((e|0)!=0|(f|0)!=0))Z();if(!a)Z();if((d+-1&255)>63)Z();if(!((c|0)!=0|g<<24>>24!=0^1))Z();if((g&255)>64)Z();if(g<<24>>24)nb(k,d,c,g,h,i);else Mb(k,d,h,i);Bb(k,b,e,f);Db(k,a,d)|0;l=j;return}function Zb(a,b,e,f,g,h,i,j,k,m,n){a=a|0;b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;n=n|0;b=l;l=l+48|0;c[b>>2]=0;Da(b+16|0,m,n,0)|0;n=d[m+16+4>>0]|d[m+16+4+1>>0]<<8|d[m+16+4+2>>0]<<16|d[m+16+4+3>>0]<<24;c[b+4>>2]=d[m+16>>0]|d[m+16+1>>0]<<8|d[m+16+2>>0]<<16|d[m+16+3>>0]<<24;c[b+4+4>>2]=n;m=lb(a,0,e,f,g,h,i,j,k,b,b+16|0)|0;Sd(b+16|0,32);l=b;return m|0}function _b(b,d,e,f,g,h,i){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0,n=0;n=l;k=l=l+63&-64;l=l+16|0;j=b;m=j+128|0;do{a[j>>0]=0;j=j+1|0}while((j|0)<(m|0));do if(!((h|f)>>>0>0|(h|f|0)==0&(g|e)>>>0>4294967295|i>>>0>2147484671))if(h>>>0<0|(h|0)==0&g>>>0<3|i>>>0<8192){c[8326]=22;b=-1;break}else{gf(k,16);b=((Sf(g,i>>>10,d,e,k,b)|0)!=0)<<31>>31;break}else{c[8326]=27;b=-1}while(0);l=n;return b|0}function $b(a){a=a|0;var b=0,d=0,e=0,f=0,g=0;e=l;d=l=l+63&-64;l=l+48|0;b=hb(a)|0;if(!b){f=c[a+44>>2]|0;b=c[a+48>>2]|0;f=((f>>>0<b<<3>>>0?b<<3:f)>>>0)/(b<<2>>>0)|0;g=O(f,b<<2)|0;c[d>>2]=0;c[d+4>>2]=c[a+40>>2];c[d+8>>2]=g;c[d+12>>2]=f;c[d+16>>2]=f<<2;c[d+20>>2]=b;c[d+24>>2]=c[a+52>>2];c[d+28>>2]=1;b=ad(d,a)|0;if(!b){b=xb(d)|0;if(!b){Tb(a,d);b=0}}}l=e;return b|0}function ac(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0;e=c[a+32>>2]|0;i=c[a+32+4>>2]|0;d=yf(e|0,i|0,3)|0;if(0<0|0==0&(d&56)>>>0<56){fb(a+40+(d&63)|0,33915,56-(d&63)|0)|0;f=a+40|0;g=b+256|0;h=a;d=i}else{fb(a+40+(d&63)|0,33915,64-(d&63)|0)|0;pa(a,a+40|0,b,b+256|0);d=a+40|0;e=d+56|0;do{c[d>>2]=0;d=d+4|0}while((d|0)<(e|0));f=a+40|0;g=b+256|0;h=a;e=c[a+32>>2]|0;d=c[a+32+4>>2]|0}Lc(a+96|0,e,d);pa(h,f,b,g);return}function bc(b,d){b=b|0;d=d|0;c[b>>2]=(Rg(d)|0)&67108863;c[b+4>>2]=(Rg(d+3|0)|0)>>>2&67108611;c[b+8>>2]=(Rg(d+6|0)|0)>>>4&67092735;c[b+12>>2]=(Rg(d+9|0)|0)>>>6&66076671;c[b+16>>2]=(Rg(d+12|0)|0)>>>8&1048575;c[b+20>>2]=0;c[b+20+4>>2]=0;c[b+20+8>>2]=0;c[b+20+12>>2]=0;c[b+20+16>>2]=0;c[b+40>>2]=Rg(d+16|0)|0;c[b+44>>2]=Rg(d+20|0)|0;c[b+48>>2]=Rg(d+24|0)|0;c[b+52>>2]=Rg(d+28|0)|0;c[b+56>>2]=0;c[b+56+4>>2]=0;a[b+80>>0]=0;return}function cc(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0;g=l;h=l=l+63&-64;l=l+464|0;qb(h+208|0,a,b)|0;wg(h+208|0,c,d,0)|0;if(f|0){a=0;b=0;do{a=a+1|0;gg(h+448|0,a);fb(h|0,h+208|0,208)|0;wg(h,h+448|0,4,0)|0;qe(h,h+416|0)|0;d=f-b|0;fb(e+b|0,h+416|0,(d>>>0<32?d:32)|0)|0;b=a<<5}while(b>>>0<f>>>0)}Sd(h+208|0,208);l=g;return}function dc(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0;l=0-(c[b+4>>2]|0)|0;k=0-(c[b+8>>2]|0)|0;j=0-(c[b+12>>2]|0)|0;i=0-(c[b+16>>2]|0)|0;h=0-(c[b+20>>2]|0)|0;g=0-(c[b+24>>2]|0)|0;f=0-(c[b+28>>2]|0)|0;e=0-(c[b+32>>2]|0)|0;d=0-(c[b+36>>2]|0)|0;c[a>>2]=0-(c[b>>2]|0);c[a+4>>2]=l;c[a+8>>2]=k;c[a+12>>2]=j;c[a+16>>2]=i;c[a+20>>2]=h;c[a+24>>2]=g;c[a+28>>2]=f;c[a+32>>2]=e;c[a+36>>2]=d;return}function ec(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;Pb(a|0,0,b|0)|0;do if((l|0)==1){if((g|d|j)>>>0>0|(g|d|j|0)==0&(f|b|i)>>>0>4294967295|k>>>0>2147484671){c[8326]=27;a=-1;break}if(d>>>0<0|(d|0)==0&b>>>0<16|(j>>>0<0|(j|0)==0&i>>>0<3)|k>>>0<8192){c[8326]=22;a=-1;break}else{a=((Hf(i,k>>>10,e,f,h,a,b)|0)!=0)<<31>>31;break}}else a=-1;while(0);return a|0}function fc(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0;if(!d)b=0;else{i=a[b>>0]|0;e=a[c>>0]|0;a:do if(!(i<<24>>24)){d=e&255;b=i&255}else{j=b;h=d;f=e;g=i;d=e&255;b=i&255;do{h=h+-1|0;if(!(g<<24>>24==f<<24>>24&((h|0)!=0&f<<24>>24!=0)))break a;j=j+1|0;c=c+1|0;g=a[j>>0]|0;b=g&255;f=a[c>>0]|0;d=f&255}while(g<<24>>24!=0)}while(0);b=b-d|0}return b|0}function gc(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;e=l;f=l=l+63&-64;l=l+1024|0;if(c[b+20>>2]|0){d=0;do{jg(a+64|0,0);jg(a+68|0,d);Oa(f,1024,a,72);Ee((c[(c[b>>2]|0)+4>>2]|0)+((O(c[b+16>>2]|0,d)|0)<<10)|0,f);jg(a+64|0,1);Oa(f,1024,a,72);Ee((c[(c[b>>2]|0)+4>>2]|0)+((O(c[b+16>>2]|0,d)|0)+1<<10)|0,f);d=d+1|0}while(d>>>0<(c[b+20>>2]|0)>>>0)}Sd(f,1024);l=e;return}function hc(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;h=l;i=l=l+63&-64;l=l+384|0;if((b|0)==0&((e|0)!=0|(f|0)!=0))Z();if(!a)Z();if((d+-1&255)>63)Z();if(!((c|0)!=0|g<<24>>24!=0^1))Z();if((g&255)>64)Z();if(g<<24>>24)Sb(i,d,c,g);else Hc(i,d);Bb(i,b,e,f);Db(i,a,d)|0;l=h;return}function ic(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;e=l;d=l=l+63&-64;l=l+16|0;do if((((a|0)!=0?(b|0)!=0:0)?((b<<10>>>0)/(b>>>0)|0|0)==1024:0)?(f=ia(12)|0,c[a>>2]=f,(f|0)!=0):0){f=sf(d,b<<10)|0;c[8326]=f;if(f|0){c[d>>2]=0;d=-22;break}d=c[d>>2]|0;if(d){c[c[a>>2]>>2]=d;c[(c[a>>2]|0)+4>>2]=d;c[(c[a>>2]|0)+8>>2]=b<<10;d=0}else d=-22}else d=-22;while(0);l=e;return d|0}function jc(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+48|0;qa(a,b);qa(a+80|0,b+40|0);oa(a+120|0,b+80|0);Gb(a+40|0,b,b+40|0);qa(d,a+40|0);Gb(a+40|0,a+80|0,a);Fb(a+80|0,a+80|0,a);Fb(a,d,a+40|0);Fb(a+120|0,a+120|0,a+80|0);l=c;return}function kc(a,b,d,e,f,g){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;h=l;i=l=l+63&-64;l=l+16|0;Ed(a+64|0,d|0,e|0)|0;Jf(a,i,a+64|0,e,f,g)|0;if((c[i>>2]|0)==64&(c[i+4>>2]|0)==0)if(b|0){a=fg(e|0,f|0,64,0)|0;c[b>>2]=a;c[b+4>>2]=z;a=0}else a=0;else{if(b|0){c[b>>2]=0;c[b+4>>2]=0}i=fg(e|0,f|0,64,0)|0;Pb(a|0,0,i|0)|0;a=-1}l=h;return a|0}function lc(a,b){a=a|0;b=b|0;var c=0,d=0;d=l;c=l=l+63&-64;l=l+240|0;if(!(Za(c+80|0,b)|0)){Bf(c);Fb(c,c,c+80+40|0);Fa(c,c);Bf(c+40|0);Gb(c+40|0,c+40|0,c+80+40|0);la(c+40|0,c+40|0,c);Ja(a,c+40|0);a=0}else a=-1;l=d;return a|0}function mc(a,b,d,e,f,g){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0;e=fg(e|0,f|0,-64,-1)|0;f=z;do if(f>>>0>0|(f|0)==0&e>>>0>4294967231)h=7;else{if(Pf(d,d+64|0,e,f,g)|0){Pb(a|0,0,e|0)|0;h=7;break}if(b|0){c[b>>2]=e;c[b+4>>2]=f}Ed(a|0,d+64|0,e|0)|0;e=0}while(0);if((h|0)==7)if(!b)e=-1;else{c[b>>2]=0;c[b+4>>2]=0;e=-1}return e|0}function nc(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0;i=a[b>>0]|0;a:do if((i+-48&255)<=9){g=0;h=b;f=i;while(1){e=(f<<24>>24)+-48|0;f=g*10|0;if(!(g>>>0<429496730&(e>>>0>~f>>>0^1))){e=0;break a}g=(e>>>0>~f>>>0?0:e)+f|0;e=h+1|0;f=a[e>>0]|0;if((f+-48&255)>9)break;else h=e}if((e|0)!=(b|0)?(h|0)==(b|0)|i<<24>>24!=48:0)c[d>>2]=g;else e=0}else e=0;while(0);return e|0}function oc(b,c,d,e,f){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0;if((((b>>>0<=63?(j=af(d|0,0,c|0,0)|0,k=z,!(k>>>0>0|(k|0)==0&j>>>0>1073741823)):0)?(a[f>>0]=36,a[f+1>>0]=55,a[f+2>>0]=36,a[f+3>>0]=a[34193+b>>0]|0,g=bd(f+4|0,54,c,30)|0,(g|0)!=0):0)?(h=bd(g,f+58-g|0,d,30)|0,(h|0)!=0):0)?(i=Rc(h,f+58-h|0,e)|0,(i|0)!=0&i>>>0<(f+58|0)>>>0):0)a[i>>0]=0;else f=0;return f|0}function pc(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;d=yf(c[a+72>>2]|0,c[a+72+4>>2]|0,3)|0;if(0<0|0==0&(d&112)>>>0<112){fb(a+80+(d&127)|0,33979,112-(d&127)|0)|0;d=a+80|0;e=b+640|0;f=a}else{fb(a+80+(d&127)|0,33979,128-(d&127)|0)|0;ja(a,a+80|0,b,b+640|0);d=a+80|0;e=d+112|0;do{c[d>>2]=0;d=d+4|0}while((d|0)<(e|0));d=a+80|0;e=b+640|0;f=a}ne(a+192|0,a+64|0,16);ja(f,d,b,e);return}function qc(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0;l=c[b+4>>2]|0;k=c[b+8>>2]|0;j=c[b+12>>2]|0;i=c[b+16>>2]|0;h=c[b+20>>2]|0;g=c[b+24>>2]|0;f=c[b+28>>2]|0;e=c[b+32>>2]|0;d=c[b+36>>2]|0;c[a>>2]=c[b>>2];c[a+4>>2]=l;c[a+8>>2]=k;c[a+12>>2]=j;c[a+16>>2]=i;c[a+20>>2]=h;c[a+24>>2]=g;c[a+28>>2]=f;c[a+32>>2]=e;c[a+36>>2]=d;return}function rc(b,c,d,e,f,g){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0;i=l;h=l=l+63&-64;l=l+32|0;if(!(e>>>0<0|(e|0)==0&d>>>0<32)?(zd(h,32,0,f,g)|0,j=fg(d|0,e|0,-32,-1)|0,(Rf(c+16|0,c+32|0,j,z,h)|0)==0):0){If(b,c,d,e,f,g)|0;c=b+32|0;do{a[b>>0]=0;b=b+1|0}while((b|0)<(c|0));b=0}else b=-1;l=i;return b|0}function sc(a){a=a|0;return ((0-((0-(a^47)|0)>>>8&63^63|(0-(a^43)|0)>>>8&62^62|((a+65439|0)>>>8^255)&a+185&((122-a|0)>>>8&255^255)|((a+-65|0)>>>8^255)&a+-65&((90-a|0)>>>8&255^255)|((a+65488|0)>>>8^255)&a+4&((57-a|0)>>>8&255^255))|0)>>>8&255^255)&(0-(a^65)|0)>>>8|((0-(a^47)|0)>>>8&63^63|(0-(a^43)|0)>>>8&62^62|((a+65439|0)>>>8^255)&a+185&((122-a|0)>>>8&255^255)|((a+-65|0)>>>8^255)&a+-65&((90-a|0)>>>8&255^255)|((a+65488|0)>>>8^255)&a+4&((57-a|0)>>>8&255^255))|0}function tc(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0;f=0;h=0;i=0;a:while(1){while(1){g=sc(a[e>>0]|0)|0;if((g|0)==255){j=7;break a}e=e+1|0;h=g+(h<<6)|0;g=f+6|0;if(g>>>0>7)break;else f=g}f=f+-2|0;if(i>>>0>=(c[d>>2]|0)>>>0){e=0;break}a[b>>0]=h>>>f;b=b+1|0;i=i+1|0}if((j|0)==7)if(f>>>0<=4?((1<<f)+-1&h|0)==0:0)c[d>>2]=i;else e=0;return e|0}function uc(b){b=b|0;var d=0,e=0,f=0;a:do if(!(b&3)){d=b;f=4}else{d=b;e=b;while(1){if(!(a[d>>0]|0)){d=e;break a}d=d+1|0;e=d;if(!(e&3)){f=4;break}}}while(0);if((f|0)==4){while(1){e=c[d>>2]|0;if(!((e&-2139062144^-2139062144)&e+-16843009))d=d+4|0;else break}if((e&255)<<24>>24)do d=d+1|0;while((a[d>>0]|0)!=0)}return d-b|0}function vc(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0;h=l;f=l=l+63&-64;l=l+128|0;if((mb(b,0,102)|0)==(b+101|0)){Ih(f);e=f+12|0;g=e+102|0;do{a[e>>0]=0;e=e+1|0}while((e|0)<(g|0));d=(wb(f,c,d,b,f+12|0)|0)==0;Jh(f);if(!d){e=Qc(f+12|0,b,102)|0;Sd(f+12|0,102)}else e=-1}else e=-1;l=h;return e|0}function wc(b,c,d,e,f){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0;j=l;l=l+96|0;if(!(eh(j+32|0,j)|0)){g=b;h=j+32|0;i=g+32|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0));wd(j+64|0,j+32|0,f);b=se(b+32|0,c,d,e,j+64|0,f,j)|0;Sd(j,32);Sd(j+32|0,32);Sd(j+64|0,24)}else b=-1;l=j;return b|0}function xc(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;do if(!(c>>>0>64|(d+-1|0)>>>0>63)){if(d>>>0>=256)ba(33636,33656,75,33829);if(c>>>0>=256)ba(33736,33656,76,33829);if((b|0)==0|(c|0)==0){Mb(a,d&255,e,f);a=0;break}else{nb(a,d&255,b,c&255,e,f);a=0;break}}else a=-1;while(0);return a|0}function yc(b,c){b=b|0;c=c|0;var d=0,e=0,f=0,g=0;f=l;g=l=l+63&-64;l=l+240|0;e=g+200|0;d=e+32|0;do{a[e>>0]=a[c>>0]|0;e=e+1|0;c=c+1|0}while((e|0)<(d|0));a[g+200>>0]=a[g+200>>0]&-8;a[g+200+31>>0]=a[g+200+31>>0]&63|64;ab(g+40|0,g+200|0);qd(g,g+40+40|0,g+40+80|0);Ja(b,g);l=f;return 0}function zc(a){a=a|0;var b=0,c=0,e=0,f=0,g=0,h=0,i=0;g=d[a+7>>0]|0;h=vf(d[a+6>>0]|0|0,0,8)|0;i=z;f=vf(d[a+5>>0]|0|0,0,16)|0;i=i|z;e=vf(d[a+4>>0]|0|0,0,24)|0;i=i|z|(d[a+3>>0]|0);c=vf(d[a+2>>0]|0|0,0,40)|0;i=i|z;b=vf(d[a+1>>0]|0|0,0,48)|0;i=i|z;a=vf(d[a>>0]|0|0,0,56)|0;z=i|z;return h|g|f|e|c|b|a|0}function Ac(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(g>>>0>0|(g|0)==0&f>>>0>15){d=fg(f|0,g|0,-16,-1)|0;a=Zb(a,0,e,d,z,e+f+-16|0,h,i,j,k,l)|0}else a=-1;if(b|0){k=(a|0)==0;g=fg(f|0,g|0,-16,-1)|0;c[b>>2]=k?g:0;c[b+4>>2]=k?z:0}return a|0}function Bc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(g>>>0>0|(g|0)==0&f>>>0>15){d=fg(f|0,g|0,-16,-1)|0;a=lb(a,0,e,d,z,e+f+-16|0,h,i,j,k,l)|0}else a=-1;if(b|0){k=(a|0)==0;g=fg(f|0,g|0,-16,-1)|0;c[b>>2]=k?g:0;c[b+4>>2]=k?z:0}return a|0}function Cc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(g>>>0>0|(g|0)==0&f>>>0>15){d=fg(f|0,g|0,-16,-1)|0;a=zb(a,0,e,d,z,e+f+-16|0,h,i,j,k,l)|0}else a=-1;if(b|0){k=(a|0)==0;g=fg(f|0,g|0,-16,-1)|0;c[b>>2]=k?g:0;c[b+4>>2]=k?z:0}return a|0}function Dc(b,c,e,f){b=b|0;c=c|0;e=e|0;f=f|0;var g=0,h=0;if(!(f>>>0<2147483647&f<<1>>>0<c>>>0))Z();if(!f)c=0;else{g=0;c=0;while(1){h=d[e+g>>0]|0;a[b+c>>0]=(h>>>4)+87+(((h>>>4)+65526|0)>>>8&217);a[b+(c|1)>>0]=(((h&15)<<8)+22272+((h&15)+65526&55552)|0)>>>8;c=g+1|0;if((c|0)==(f|0)){c=f<<1;break}else{g=c;c=c<<1}}}a[b+c>>0]=0;return b|0}function Ec(a,b,c,d,e,f,g,h,i){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0;do if(!((b+-1|0)>>>0>63|g>>>0>64)){if(b>>>0>=256)ba(33636,33656,35,33756);if(g>>>0<256){Yb(a,c,f,b&255,d,e,g&255,h,i);j=0;break}else ba(33736,33656,36,33756)}else j=-1;while(0);return j|0}function Fc(a,b){a=a|0;b=b|0;c[a>>2]=1634760805;c[a+4>>2]=857760878;c[a+8>>2]=2036477234;c[a+12>>2]=1797285236;c[a+16>>2]=Rg(b)|0;c[a+20>>2]=Rg(b+4|0)|0;c[a+24>>2]=Rg(b+8|0)|0;c[a+28>>2]=Rg(b+12|0)|0;c[a+32>>2]=Rg(b+16|0)|0;c[a+36>>2]=Rg(b+20|0)|0;c[a+40>>2]=Rg(b+24|0)|0;c[a+44>>2]=Rg(b+28|0)|0;return}function Gc(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;do if(!(c>>>0>64|(d+-1|0)>>>0>63)){if(d>>>0>=256)ba(33636,33656,52,33797);if(c>>>0>=256)ba(33736,33656,53,33797);if((b|0)==0|(c|0)==0){Hc(a,d&255);a=0;break}else{Sb(a,d&255,b,c&255);a=0;break}}else a=-1;while(0);return a|0}function Hc(b,c){b=b|0;c=c|0;var d=0,e=0,f=0;e=l;f=l=l+63&-64;l=l+64|0;if((c+-1&255)>63)Z();else{a[f>>0]=c;a[f+1>>0]=0;a[f+2>>0]=1;a[f+3>>0]=1;Vg(f+4|0);bf(f+8|0);c=f+16|0;d=c+48|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(d|0));ud(b,f);l=e;return}}function Ic(b,c){b=b|0;c=c|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+128|0;Fa(f+80|0,c+80|0);la(f+40|0,c,f+80|0);la(f,c+40|0,f+80|0);Ja(b,f);c=(Ve(f+40|0)|0)<<7;a[b+31>>0]=(d[b+31>>0]|0)^c;l=e;return}function Jc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(f>>>0>4294967295|(f|0)==-1&e>>>0>4294967279)Z();Xb(a,a+e|0,0,d,e,f,g,h,i,0,k,l)|0;if(b|0){k=fg(e|0,f|0,16,0)|0;c[b>>2]=k;c[b+4>>2]=z}return 0}function Kc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(f>>>0>4294967295|(f|0)==-1&e>>>0>4294967279)Z();yb(a,a+e|0,0,d,e,f,g,h,i,0,k,l)|0;if(b|0){k=fg(e|0,f|0,16,0)|0;c[b>>2]=k;c[b+4>>2]=z}return 0}function Lc(b,c,d){b=b|0;c=c|0;d=d|0;var e=0;a[b+7>>0]=c;e=yf(c|0,d|0,8)|0;a[b+6>>0]=e;e=yf(c|0,d|0,16)|0;a[b+5>>0]=e;e=yf(c|0,d|0,24)|0;a[b+4>>0]=e;a[b+3>>0]=d;e=yf(c|0,d|0,40)|0;a[b+2>>0]=e;e=yf(c|0,d|0,48)|0;a[b+1>>0]=e;d=yf(c|0,d|0,56)|0;a[b>>0]=d;return}function Mc(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;j=l;i=l=l+63&-64;l=l+32|0;if(!(Ad(i,g,h)|0)){a=Je(a,b,c,d,e,f,i)|0;Sd(i,32)}else a=-1;l=j;return a|0}function Nc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(f>>>0>4294967295|(f|0)==-1&e>>>0>4294967279)Z();Kb(a,a+e|0,0,d,e,f,g,h,i,0,k,l)|0;if(b|0){k=fg(e|0,f|0,16,0)|0;c[b>>2]=k;c[b+4>>2]=z}return 0}function Oc(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;j=l;i=l=l+63&-64;l=l+32|0;if(!(Ad(i,g,h)|0)){Qe(a,b,c,d,e,f,i)|0;Sd(i,32);a=0}else a=-1;l=j;return a|0}function Pc(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;i=l;j=l=l+63&-64;l=l+80|0;if(!((c|0)==0&(d|0)==0)){jg(j+64|0,f);jg(j+64+4|0,g);Fc(j,h);$d(j,e,j+64|0);va(j,b,a,c,d);Sd(j,64)}l=i;return 0}function Qc(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0;g=l;f=l=l+63&-64;l=l+16|0;c[f+4>>2]=b;c[f>>2]=d;if(!e)b=0;else{b=0;d=0;do{d=(a[(c[f>>2]|0)+b>>0]^a[(c[f+4>>2]|0)+b>>0])&255|d;b=b+1|0}while((b|0)!=(e|0));b=((d+511|0)>>>8&1)+-1|0}l=g;return b|0}function Rc(a,b,c){a=a|0;b=b|0;c=c|0;var e=0,f=0,g=0,h=0,i=0;e=0;while(1){if(e>>>0<32){f=0;g=0}else break;do{h=e;e=e+1|0;g=(d[c+h>>0]|0)<<f|g;f=f+8|0}while(e>>>0<32&f>>>0<24);i=a;a=bd(a,b,g,f)|0;h=(a|0)==0;b=(h?0:i-a|0)+b|0;if(h){a=0;break}}return a|0}function Sc(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0;do if(!((b+-1|0)>>>0>63|g>>>0>64)){if(b>>>0>=256)ba(33636,33656,18,33709);if(g>>>0<256){hc(a,c,f,b&255,d,e,g&255);h=0;break}else ba(33736,33656,19,33709)}else h=-1;while(0);return h|0}function Tc(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0;h=l;f=l=l+63&-64;l=l+16|0;g=0;e=0;while(1){if(_f(f,a[d>>0]|0)|0){e=3;break}d=d+1|0;g=c[f>>2]<<e|g;e=e+6|0;if(e>>>0>=30){e=5;break}}if((e|0)==3){c[b>>2]=0;d=0}else if((e|0)==5)c[b>>2]=g;l=h;return d|0}function Uc(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0;Ef(c,a+((d<<5)+-16<<2)|0);if(d<<1|0){e=0;do{g=e<<4;$e(c,a+(g<<2)|0);Ca(c);f=e<<3;Ef(b+(f<<2)|0,c);$e(c,a+((g|16)<<2)|0);Ca(c);Ef(b+(f+(d<<4)<<2)|0,c);e=e+2|0}while(e>>>0<d<<1>>>0)}return}function Vc(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+160|0;de(c,d,32,0)|0;a[c>>0]=a[c>>0]&-8;a[c+31>>0]=a[c+31>>0]&63|64;ab(f,c);Ic(b,f);Ed(c|0,d|0,32)|0;Ed(c+32|0,b|0,32)|0;l=e;return 0}function Wc(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0;g=l;h=l=l+63&-64;l=l+64|0;de(h,d,32,0)|0;d=c;e=h;f=d+32|0;do{a[d>>0]=a[e>>0]|0;d=d+1|0;e=e+1|0}while((d|0)<(f|0));Sd(h,64);h=Yg(b,c)|0;l=g;return h|0}function Xc(b,c,d,e,f,g){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(e>>>0<0|(e|0)==0&d>>>0<32)b=-1;else{If(b,c,d,e,f,g)|0;c=fg(d|0,e|0,-32,-1)|0;Zf(b+16|0,b+32|0,c,z,b)|0;c=b+16|0;do{a[b>>0]=0;b=b+1|0}while((b|0)<(c|0));b=0}return b|0}function Yc(b,c){b=b|0;c=c|0;var d=0,e=0,f=0;e=l;f=l=l+63&-64;l=l+64|0;de(f,c,32,0)|0;a[f>>0]=a[f>>0]&-8;a[f+31>>0]=a[f+31>>0]&63|64;c=f;d=b+32|0;do{a[b>>0]=a[c>>0]|0;b=b+1|0;c=c+1|0}while((b|0)<(d|0));Sd(f,64);l=e;return 0}function Zc(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0;h=l;g=l=l+63&-64;l=l+32|0;if(d>>>0<0|(d|0)==0&c>>>0<48)a=-1;else{c=fg(c|0,d|0,-32,-1)|0;d=z;wd(g,b,e);a=Pd(a,b+32|0,c,d,g,b,f)|0}l=h;return a|0}function _c(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+16|0;c[f>>2]=c[b+((d&3)<<2)>>2];c[f+4>>2]=c[b+((d>>>2&3)<<2)>>2];c[f+8>>2]=c[b+((d>>>4&3)<<2)>>2];c[f+12>>2]=c[b+((d>>>6&3)<<2)>>2];Ce(a,f);l=e;return}function $c(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;h=l;i=l=l+63&-64;l=l+80|0;if(!((c|0)==0&(d|0)==0)){jg(i+64|0,f);Fc(i,g);oe(i,e,i+64|0);va(i,b,a,c,d);Sd(i,64)}l=h;return 0}function ad(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;f=l;e=l=l+63&-64;l=l+80|0;if(!((a|0)==0|(b|0)==0)){d=ic(a,c[a+8>>2]|0)|0;if(!d){Na(e,b,c[a+28>>2]|0);Sd(e+64|0,8);gc(e,a);Sd(e,72);d=0}}else d=-25;l=f;return d|0}function bd(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;a:do if(e){f=0;while(1){if(!c){b=0;break a}g=b+1|0;a[b>>0]=a[34193+(d&63)>>0]|0;f=f+6|0;if(f>>>0>=e>>>0){b=g;break}else{d=d>>>6;c=c+-1|0;b=g}}}while(0);return b|0}function cd(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;e=fg(c[a+64>>2]|0,c[a+64+4>>2]|0,b|0,d|0)|0;f=z;c[a+64>>2]=e;c[a+64+4>>2]=f;d=fg((f>>>0<d>>>0|(f|0)==(d|0)&e>>>0<b>>>0)&1|0,0,c[a+72>>2]|0,c[a+72+4>>2]|0)|0;c[a+72>>2]=d;c[a+72+4>>2]=z;return}function dd(a,b,c,d,e,f,g,h,i,j){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;var k=0,m=0;k=l;m=l=l+63&-64;l=l+16|0;Ih(m);j=_a(m,a,b,c,d,e,f,g,h,i,j)|0;Jh(m);l=k;return j|0}function ed(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;i=l;h=l=l+63&-64;l=l+32|0;if(!(Cd(h,f,g)|0)){a=Lf(a,b,c,d,e,h)|0;Sd(h,32)}else a=-1;l=i;return a|0}function fd(b,c){b=b|0;c=c|0;var d=0,e=0,f=0,g=0;f=l;g=l=l+63&-64;l=l+16|0;e=10;while(1){d=e+-1|0;a[g+d>>0]=(c>>>0)%10|0|48;if(c>>>0>9&(d|0)!=0){e=d;c=(c>>>0)/10|0}else break}e=11-e|0;fb(b|0,g+d|0,e|0)|0;a[b+e>>0]=0;l=f;return}function gd(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;i=l;h=l=l+63&-64;l=l+32|0;if(!(Cd(h,f,g)|0)){a=Uf(a,b,c,d,e,h)|0;Sd(h,32)}else a=-1;l=i;return a|0}function hd(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;i=l;j=l=l+63&-64;l=l+32|0;Ga(j,e,h,0)|0;h=ef(a,b,c,d,e+16|0,f,g,j)|0;Sd(j,32);l=i;return h|0}function id(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+64|0;if(!((b|0)==0&(c|0)==0)){Fc(g,e);oe(g,d,0);Pb(a|0,0,b|0)|0;va(g,a,a,b,c);Sd(g,64)}l=f;return 0}function jd(a){a=a|0;var b=0,d=0;d=a+15&-16|0;b=c[i>>2]|0;a=b+d|0;if((d|0)>0&(a|0)<(b|0)|(a|0)<0){W()|0;_(12);return -1}c[i>>2]=a;if((a|0)>(V()|0)?(U()|0)==0:0){_(12);c[i>>2]=b;return -1}return b|0}function kd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+64|0;if(!((b|0)==0&(c|0)==0)){Fc(g,e);$d(g,d,0);Pb(a|0,0,b|0)|0;va(g,a,a,b,c);Sd(g,64)}l=f;return 0}function ld(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;i=l;j=l=l+63&-64;l=l+32|0;Da(j,e,h,0)|0;h=jf(a,b,c,d,e+16|0,f,g,j)|0;l=i;return h|0}function md(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0;i=l;l=l+32|0;if(!(Jg(i,g,h)|0)){a=mf(a,b,c,d,e,f,i)|0;Sd(i,32)}else a=-1;l=i;return a|0}function nd(b){b=b|0;var c=0,d=0,e=0,f=0,g=0;d=32;c=1;e=0;while(1){d=d+-1|0;f=a[b+d>>0]|0;g=a[34308+d>>0]|0;c=c&255;e=((f&255)-(g&255)|0)>>>8&c|e&255;if(!d)break;else c=(((g^f)&255)+65535|0)>>>8&c}return ((e|0)==0)<<31>>31|0}function od(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;e=l;d=l=l+63&-64;l=l+16|0;f=sf(d,b)|0;c[8326]=f;if(!f)d=c[d>>2]|0;else{c[d>>2]=0;d=0}c[a>>2]=d;c[a+4>>2]=d;c[a+8>>2]=d|0?b:0;l=e;return d|0}function pd(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0;i=l;l=l+32|0;if(!(Jg(i,g,h)|0)){qf(a,b,c,d,e,f,i)|0;Sd(i,32);a=0}else a=-1;l=i;return a|0}function qd(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+80|0;Gb(e+40|0,c,b);Fb(e,c,b);Fa(e,e);la(a,e+40|0,e);l=d;return}function rd(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=Mc(a,b+16|0,b,d,z,e,f,g)|0}return a|0}function sd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=Je(a,b+16|0,b,d,z,e,f)|0}return a|0}function td(a){a=a|0;c[a+32>>2]=0;c[a+32+4>>2]=0;c[a>>2]=c[8238];c[a+4>>2]=c[8239];c[a+8>>2]=c[8240];c[a+12>>2]=c[8241];c[a+16>>2]=c[8242];c[a+20>>2]=c[8243];c[a+24>>2]=c[8244];c[a+28>>2]=c[8245];return 0}function ud(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0;ff(a);d=0;do{g=Te(b+(d<<3)|0)|0;e=a+(d<<3)|0;f=c[e+4>>2]^z;c[e>>2]=c[e>>2]^g;c[e+4>>2]=f;d=d+1|0}while((d|0)!=8);return}function vd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=Ya(a,b+16|0,b,d,z,e,f)|0}return a|0}function wd(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+384|0;Dg(e,0,0,24)|0;rg(e,b,32,0)|0;rg(e,c,32,0)|0;Tg(e,a,24)|0;l=d;return}function xd(b){b=b|0;var c=0,d=0,e=0;d=0;while(1){c=0;e=0;do{e=(a[16+(d<<5)+c>>0]^a[b+c>>0])&255|e;c=c+1|0}while((c|0)!=32);d=d+1|0;if(!e){c=1;break}if(d>>>0>=12){c=0;break}}return c|0}function yd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0;g=l;h=l=l+63&-64;l=l+1408|0;da(h,f)|0;ea(a,b,c,d,e,h)|0;l=g;return 0}function zd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+32|0;Ga(g,d,e,0)|0;e=xg(a,b,c,d+16|0,g)|0;Sd(g,32);l=f;return e|0}function Ad(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;e=l;d=l=l+63&-64;l=l+32|0;if(!(Od(d,c,b)|0)){Da(a,35976,d,0)|0;a=0}else a=-1;l=e;return a|0}function Bd(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if((l|0)==1)a=ec(a,b,d,e,f,g,h,i,j,k,1)|0;else{c[8326]=22;a=-1}return a|0}function Cd(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;e=l;d=l=l+63&-64;l=l+32|0;if(!(Od(d,c,b)|0)){Ga(a,35912,d,0)|0;a=0}else a=-1;l=e;return a|0}function Dd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+32|0;je(f,b,c,d,e)|0;e=Ne(a,f)|0;e=((f|0)==(a|0)?-1:e)|(Qc(f,a,32)|0);l=f;return e|0}function Ed(b,c,d){b=b|0;c=c|0;d=d|0;var e=0;if((c|0)<(b|0)&(b|0)<(c+d|0)){e=b;c=c+d|0;b=b+d|0;while((d|0)>0){b=b-1|0;c=c-1|0;d=d-1|0;a[b>>0]=a[c>>0]|0}b=e}else fb(b,c,d)|0;return b|0}function Fd(a,b){a=a|0;b=b|0;var c=0,d=0,e=0;c=O(b&65535,a&65535)|0;e=(c>>>16)+(O(b&65535,a>>>16)|0)|0;d=O(b>>>16,a&65535)|0;return (z=(e>>>16)+(O(b>>>16,a>>>16)|0)+(((e&65535)+d|0)>>>16)|0,e+d<<16|c&65535|0)|0}function Gd(a,b){a=a|0;b=b|0;var d=0;d=c[a+4>>2]^c[b+4>>2];c[a>>2]=c[a>>2]^c[b>>2];c[a+4>>2]=d;d=c[a+8+4>>2]^c[b+8+4>>2];c[a+8>>2]=c[a+8>>2]^c[b+8>>2];c[a+8+4>>2]=d;return}function Hd(a,b){a=a|0;b=b|0;var d=0;d=c[a+4>>2]&c[b+4>>2];c[a>>2]=c[a>>2]&c[b>>2];c[a+4>>2]=d;d=c[a+8+4>>2]&c[b+8+4>>2];c[a+8>>2]=c[a+8>>2]&c[b+8>>2];c[a+8+4>>2]=d;return}function Id(a,b){a=a|0;b=b|0;la(a,b,b+120|0);la(a+40|0,b+40|0,b+80|0);la(a+80|0,b+80|0,b+120|0);la(a+120|0,b,b+40|0);return}function Jd(a,b){a=a|0;b=b|0;var d=0;d=c[a+4>>2]|c[b+4>>2];c[a>>2]=c[a>>2]|c[b>>2];c[a+4>>2]=d;d=c[a+8+4>>2]|c[b+8+4>>2];c[a+8>>2]=c[a+8>>2]|c[b+8>>2];c[a+8+4>>2]=d;return}function Kd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+64|0;ie(f,b,c,d,e)|0;e=Me(a,f)|0;e=((f|0)==(a|0)?-1:e)|(Qc(f,a,64)|0);l=f;return e|0}function Ld(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+32|0;ge(f,b,c,d,e)|0;e=Ne(a,f)|0;e=((f|0)==(a|0)?-1:e)|(Qc(f,a,32)|0);l=f;return e|0}function Md(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else a=Oc(a+16|0,a,b,c,d,e,f,g)|0;return a|0}function Nd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else{Qe(a+16|0,a,b,c,d,e,f)|0;a=0}return a|0}function Od(a,b,c){a=a|0;b=b|0;c=c|0;if(!(Ka(a,b,c)|0)){b=0;c=0;do{c=d[a+b>>0]|0|c;b=b+1|0}while((b|0)!=32);b=0-((c+511|0)>>>8&1)|0}else b=-1;return b|0}function Pd(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=md(a,b+16|0,b,d,z,e,f,g)|0}return a|0}function Qd(a){a=a|0;var b=0,c=0,e=0,f=0;c=d[a>>0]|0;e=vf(d[a+1>>0]|0|0,0,8)|0;f=z;b=vf(d[a+2>>0]|0|0,0,16)|0;f=f|z;a=vf(d[a+3>>0]|0|0,0,24)|0;z=f|z;return e|c|b|a|0}function Rd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+16|0;he(g,b,c,d,e)|0;e=Oe(a,g)|0;l=f;return e|0}function Sd(b,d){b=b|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+16|0;c[f>>2]=b;if(d|0){b=0;do{a[(c[f>>2]|0)+b>>0]=0;b=b+1|0}while((b|0)!=(d|0))}l=e;return}function Td(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=mf(a,b+16|0,b,d,z,e,f)|0}return a|0}function Ud(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0;d=0;do{g=b+(d<<3)|0;e=a+(d<<3)|0;f=c[e+4>>2]^c[g+4>>2];c[e>>2]=c[e>>2]^c[g>>2];c[e+4>>2]=f;d=d+1|0}while((d|0)!=128);return}function Vd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+32|0;Da(g,d,e,0)|0;e=Cg(a,b,c,d+16|0,g)|0;l=f;return e|0}function Wd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=$a(a,b+16|0,b,d,z,e,f)|0}return a|0}function Xd(a,b){a=a|0;b=b|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);qc(a+80|0,b+80|0);la(a+120|0,b+120|0,1232);return}function Yd(b){b=b|0;var c=0;c=a[n+(b&255)>>0]|0;if((c|0)<8)return c|0;c=a[n+(b>>8&255)>>0]|0;if((c|0)<8)return c+8|0;c=a[n+(b>>16&255)>>0]|0;if((c|0)<8)return c+16|0;return (a[n+(b>>>24)>>0]|0)+24|0}function Zd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+1408|0;da(g,e)|0;fa(a,b,c,d,g)|0;l=f;return 0}function _d(a,b){a=a|0;b=b|0;var c=0;c=Te(a)|0;c=yf(c|0,z|0,b|0)|0;re(a,c,z);c=Te(a+8|0)|0;b=yf(c|0,z|0,b|0)|0;re(a+8|0,b,z);return}function $d(a,b,d){a=a|0;b=b|0;d=d|0;if(!d){c[a+48>>2]=0;d=0}else{c[a+48>>2]=Rg(d)|0;d=Rg(d+4|0)|0}c[a+52>>2]=d;c[a+56>>2]=Rg(b)|0;c[a+60>>2]=Rg(b+4|0)|0;return}function ae(a,b){a=a|0;b=b|0;var c=0;c=Te(a)|0;c=vf(c|0,z|0,b|0)|0;re(a,c,z);c=Te(a+8|0)|0;b=vf(c|0,z|0,b|0)|0;re(a+8|0,b,z);return}function be(b,c){b=b|0;c=c|0;var d=0,e=0;e=l;l=l+64|0;pe(b,e)|0;b=e;d=c+32|0;do{a[c>>0]=a[b>>0]|0;c=c+1|0;b=b+1|0}while((c|0)<(d|0));l=e;return 0}function ce(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;f=fg(c|0,d|0,a|0,b|0)|0;e=z;d=vf(a|0,b|0,1)|0;d=af(d&-2|0,z&1|0,c|0,0)|0;d=fg(f|0,e|0,d|0,z|0)|0;return d|0}function de(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+208|0;me(f)|0;Ea(f,b,c,d)|0;Be(f,a)|0;l=e;return 0}function ee(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+112|0;td(f)|0;La(f,b,c,d)|0;Fe(f,a)|0;l=e;return 0}function fe(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else{Qa(a+16|0,a,b,c,d,e,f)|0;a=0}return a|0}function ge(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+208|0;qb(f,e,32)|0;wg(f,b,c,d)|0;qe(f,a)|0;l=f;return 0}function he(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+96|0;bc(g,e);Ma(g,b,c,d);Ua(g,a);l=f;return 0}function ie(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+416|0;pb(f,e,32)|0;zg(f,b,c,d)|0;pe(f,a)|0;l=f;return 0}function je(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+416|0;Pg(f,e,32)|0;Gg(f,b,c,d)|0;be(f,a)|0;l=f;return 0}function ke(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+64|0;Be(a,f)|0;tb(b,c,f,64,0,d,1);l=e;return 0}function le(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+64|0;Be(a,e)|0;c=vb(b,e,64,0,c,1)|0;l=d;return c|0}function me(a){a=a|0;var b=0,d=0;c[a+64>>2]=0;c[a+64+4>>2]=0;c[a+64+8>>2]=0;c[a+64+12>>2]=0;b=400;d=a+64|0;do{c[a>>2]=c[b>>2];a=a+4|0;b=b+4|0}while((a|0)<(d|0));return 0}function ne(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;if(d>>>3|0){e=0;do{f=b+(e<<3)|0;Lc(a+(e<<3)|0,c[f>>2]|0,c[f+4>>2]|0);e=e+1|0}while((e|0)!=(d>>>3|0))}return}function oe(a,b,d){a=a|0;b=b|0;d=d|0;if(!d)d=0;else d=Rg(d)|0;c[a+48>>2]=d;c[a+52>>2]=Rg(b)|0;c[a+56>>2]=Rg(b+4|0)|0;c[a+60>>2]=Rg(b+8|0)|0;return}function pe(a,b){a=a|0;b=b|0;var c=0;c=l;l=l+64|0;Be(a,c)|0;Ea(a+208|0,c,64,0)|0;Be(a+208|0,b)|0;Sd(c,64);l=c;return 0}function qe(a,b){a=a|0;b=b|0;var c=0;c=l;l=l+32|0;Fe(a,c)|0;La(a+104|0,c,32,0)|0;Fe(a+104|0,b)|0;Sd(c,32);l=c;return 0}function re(b,c,d){b=b|0;c=c|0;d=d|0;a[b>>0]=c;a[b+1>>0]=c>>8;a[b+2>>0]=c>>16;a[b+3>>0]=c>>24;a[b+4>>0]=d;a[b+4+1>>0]=d>>8;a[b+4+2>>0]=d>>16;a[b+4+3>>0]=d>>24;return}function se(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else a=pd(a+16|0,a,b,c,d,e,f,g)|0;return a|0}function te(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else{qf(a+16|0,a,b,c,d,e,f)|0;a=0}return a|0}function ue(a){a=a|0;jg(a,(Rg(a)|0)>>>8);jg(a+4|0,(Rg(a+4|0)|0)>>>8);jg(a+8|0,(Rg(a+8|0)|0)>>>8);jg(a+12|0,(Rg(a+12|0)|0)>>>8);return}function ve(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else{Ta(a+16|0,a,b,c,d,e,f)|0;a=0}return a|0}function we(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;if(d>>>2|0){e=0;do{f=a+(e<<2)|0;c[f>>2]=c[f>>2]^c[b+(e<<2)>>2];e=e+1|0}while((e|0)!=(d>>>2|0))}return}function xe(a){a=a|0;return (0-(a^62)|0)>>>8&43^43|(a+65510|0)>>>8&255&a+65|(0-(a^63)|0)>>>8&47^47|(a+65484|0)>>>8&a+71&((a+65510|0)>>>8&255^255)|(a+65474|0)>>>8&a+252&((a+65484|0)>>>8&255^255)|0}function ye(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+128|0;Ue(d,b);jc(a,d);l=c;return}function ze(a,b){a=a|0;b=b|0;la(a,b,b+120|0);la(a+40|0,b+40|0,b+80|0);la(a+80|0,b+80|0,b+120|0);return}function Ae(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+32|0;gf(d,32);Vc(a,b,d)|0;Sd(d,32);l=c;return 0}function Be(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+704|0;pc(a,d);ne(b,a,64);Sd(d,704);Sd(a,208);l=c;return 0}function Ce(a,b){a=a|0;b=b|0;var d=0;d=c[b+4>>2]|0;c[a>>2]=c[b>>2];c[a+4>>2]=d;d=c[b+8+4>>2]|0;c[a+8>>2]=c[b+8>>2];c[a+8+4>>2]=d;return}function De(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;d=0;do{f=zc(b+(d<<3)|0)|0;e=a+(d<<3)|0;c[e>>2]=f;c[e+4>>2]=z;d=d+1|0}while((d|0)!=16);return}function Ee(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;d=0;do{f=Te(b+(d<<3)|0)|0;e=a+(d<<3)|0;c[e>>2]=f;c[e+4>>2]=z;d=d+1|0}while((d|0)!=128);return}function Fe(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+288|0;ac(a,d);uf(b,a);Sd(d,288);Sd(a,104);l=c;return 0}function Ge(a){a=a|0;var b=0,c=0;b=l;c=l=l+63&-64;l=l+32|0;Ja(c,a);a=Ne(c,35928)|0;l=b;return a|0}function He(a,b,d,e){a=a|0;b=b|0;d=d|0;e=e|0;if(e>>>0>0|(e|0)==0&d>>>0>4294967295){c[8326]=27;a=-1}else a=((qh(a,b,d)|0)!=0)<<31>>31;return a|0}function Ie(a){a=a|0;var b=0;if(a>>>0<2)a=0;else{do b=Mh()|0;while(b>>>0<(((0-a|0)>>>0)%(a>>>0)|0)>>>0);a=(b>>>0)%(a>>>0)|0}return a|0}function Je(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return Ya(a,b,c,d,e,f,g)|0}function Ke(a,b,c){a=a|0;b=b|0;c=c|0;sb(a,b,c&255);sb(a+40|0,b+40|0,c&255);sb(a+80|0,b+80|0,c&255);return}function Le(a){a=a|0;var b=0;b=~c[a+4>>2];c[a>>2]=~c[a>>2];c[a+4>>2]=b;b=~c[a+8+4>>2];c[a+8>>2]=~c[a+8>>2];c[a+8+4>>2]=b;return}function Me(b,c){b=b|0;c=c|0;var d=0,e=0;d=0;e=0;do{d=(a[c+e>>0]^a[b+e>>0])&255|d;e=e+1|0}while((e|0)!=64);return ((d+511|0)>>>8&1)+-1|0}function Ne(b,c){b=b|0;c=c|0;var d=0,e=0;d=0;e=0;do{d=(a[c+e>>0]^a[b+e>>0])&255|d;e=e+1|0}while((e|0)!=32);return ((d+511|0)>>>8&1)+-1|0}function Oe(b,c){b=b|0;c=c|0;var d=0,e=0;d=0;e=0;do{d=(a[c+e>>0]^a[b+e>>0])&255|d;e=e+1|0}while((e|0)!=16);return ((d+511|0)>>>8&1)+-1|0}function Pe(a,b,d,e){a=a|0;b=b|0;d=d|0;e=e|0;var f=0;f=l;l=l+16|0;za(a,b,d,e,f|0)|0;l=f;return (z=c[f+4>>2]|0,c[f>>2]|0)|0}function Qe(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;Qa(a,b,c,d,e,f,g)|0;return 0}function Re(a,b,d){a=a|0;b=b|0;d=d|0;var e=0;if(d>>>2|0){e=0;do{c[a+(e<<2)>>2]=c[b+(e<<2)>>2];e=e+1|0}while((e|0)!=(d>>>2|0))}return}function Se(a,b){a=a|0;b=b|0;var d=0,e=0;d=0;do{e=b+(d<<3)|0;re(a+(d<<3)|0,c[e>>2]|0,c[e+4>>2]|0);d=d+1|0}while((d|0)!=128);return}function Te(a){a=a|0;z=d[a+4>>0]|d[a+4+1>>0]<<8|d[a+4+2>>0]<<16|d[a+4+3>>0]<<24;return d[a>>0]|d[a+1>>0]<<8|d[a+2>>0]<<16|d[a+3>>0]<<24|0}function Ue(a,b){a=a|0;b=b|0;qc(a,b);qc(a+40|0,b+40|0);qc(a+80|0,b+80|0);return}function Ve(b){b=b|0;var c=0,d=0;d=l;c=l=l+63&-64;l=l+32|0;Ja(c,b);l=d;return a[c>>0]&1|0}function We(){}function Xe(a,b,c){a=a|0;b=b|0;c=c|0;if((c|0)<32){z=b>>c;return a>>>c|(b&(1<<c)-1)<<32-c}z=(b|0)<0?-1:0;return b>>c-32|0}function Ye(a){a=a|0;lg(a);Bf(a+40|0);Bf(a+80|0);lg(a+120|0);return}function Ze(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=yf(a|0,b|0,c|0)|0;e=z;c=vf(a|0,b|0,64-c|0)|0;z=z|e;return c|d|0}function _e(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=vf(a|0,b|0,c|0)|0;e=z;c=yf(a|0,b|0,64-c|0)|0;z=z|e;return c|d|0}function $e(a,b){a=a|0;b=b|0;var d=0,e=0;d=0;do{e=a+(d<<2)|0;c[e>>2]=c[e>>2]^c[b+(d<<2)>>2];d=d+1|0}while((d|0)!=16);return}function af(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;e=Fd(a,c)|0;f=z;return (z=(O(b,c)|0)+(O(d,a)|0)+f|f&0,e|0|0)|0}function bf(b){b=b|0;a[b>>0]=0;a[b+1>>0]=0;a[b+2>>0]=0;a[b+3>>0]=0;a[b+4>>0]=0;a[b+4+1>>0]=0;a[b+4+2>>0]=0;a[b+4+3>>0]=0;return}function cf(a,b,c){a=a|0;b=b|0;c=c|0;if(c>>>0<256)return Db(a,b,c&255)|0;else ba(33636,33656,102,33875);return 0}function df(a,b,c){a=a|0;b=b|0;c=c|0;var d=0;b=vf(b&255|0,0,8)|0;d=z;c=vf(c&255|0,0,16)|0;z=d|z;return b|a&255|c|0}function ef(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;return Pa(a,b,c,d,e,f,g,h)|0}function ff(a){a=a|0;var b=0,d=0;Pb(a+64|0,0,320)|0;b=400;d=a+64|0;do{c[a>>2]=c[b>>2];a=a+4|0;b=b+4|0}while((a|0)<(d|0));return}function gf(b,c){b=b|0;c=c|0;var d=0;if(c|0){d=0;do{a[b+d>>0]=Mh()|0;d=d+1|0}while((d|0)!=(c|0))}return}function hf(b,c){b=b|0;c=c|0;var d=0;d=c;do{if(!d){c=0;break}d=d+-1|0;c=b+d|0}while((a[c>>0]|0)!=36);return c|0}function jf(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;return Pc(a,b,c,d,e,f,g,h)|0}function kf(b,c){b=b|0;c=c|0;var d=0;d=b+48|0;b=d+16|0;do{a[d>>0]=a[c>>0]|0;d=d+1|0;c=c+1|0}while((d|0)<(b|0));return}function lf(b,c){b=b|0;c=c|0;var d=0;d=b+32|0;b=d+16|0;do{a[d>>0]=a[c>>0]|0;d=d+1|0;c=c+1|0}while((d|0)<(b|0));return}function mf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return $a(a,b,c,d,e,f,g)|0}function nf(){var a=0,b=0;a=l;b=l=l+63&-64;l=l+16|0;Xg(b);if(c[b>>2]|0)Xg(b);l=a;return}function of(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return ed(a,b,c,d,e,f,g)|0}function pf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return $c(a,b,c,d,e,f,g)|0}function qf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;Ta(a,b,c,d,e,f,g)|0;return 0}function rf(){var a=0;a=Y(30)|0;if((a|0)>0)c[8833]=a;else a=c[8833]|0;if(a>>>0<16)Z();else{gf(35960,16);return}}function sf(a,b){a=a|0;b=b|0;var d=0;if(b>>>0<=4294967168?(d=ob(b)|0,(d|0)!=0):0){c[a>>2]=d;a=0}else a=12;return a|0}function tf(a,b){a=a|0;b=b|0;var d=0;d=0;do{c[a+(d<<2)>>2]=ug(b+(d<<2)|0)|0;d=d+1|0}while((d|0)!=16);return}function uf(a,b){a=a|0;b=b|0;var d=0;d=0;do{gg(a+(d<<2)|0,c[b+(d<<2)>>2]|0);d=d+1|0}while((d|0)!=8);return}function vf(a,b,c){a=a|0;b=b|0;c=c|0;if((c|0)<32){z=b<<c|(a&(1<<c)-1<<32-c)>>>32-c;return a<<c}z=a<<c-32;return 0}function wf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return gd(a,b,c,d,e,f,g)|0}function xf(){var a=0;if(!(c[8832]|0)){zh();Oh();rf();c[8832]=1;a=0}else a=1;return a|0}function yf(a,b,c){a=a|0;b=b|0;c=c|0;if((c|0)<32){z=b>>>c;return a>>>c|(b&(1<<c)-1)<<32-c}z=0;return b>>>c-32|0}function zf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return Sc(a,b,c,d,e,f,g)|0}function Af(a,b,c){a=a|0;b=b|0;c=c|0;if(c>>>0<1|(c|0)==1&b>>>0<0){gf(a,b);return}else ba(35141,35161,200,35187)}function Bf(a){a=a|0;var b=0;c[a>>2]=1;a=a+4|0;b=a+36|0;do{c[a>>2]=0;a=a+4|0}while((a|0)<(b|0));return}function Cf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return _b(a,b,c,d,e,f,g)|0}function Df(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return ld(a,b,c,d,e,0,0,f)|0}function Ef(a,b){a=a|0;b=b|0;var d=0;d=0;do{c[a+(d<<2)>>2]=c[b+(d<<2)>>2];d=d+1|0}while((d|0)!=16);return}function Ff(a){a=a|0;Bf(a);Bf(a+40|0);lg(a+80|0);return}function Gf(a,b){a=a|0;b=b|0;var d=0;d=c[a>>2]|0;if((b|0)!=0&(d|0)!=0)Sd(c[d+4>>2]|0,c[a+8>>2]<<10);return}function Hf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return ub(a,b,1,c,d,e,16,f,g,0,0)|0}function If(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return hd(a,b,c,d,e,0,0,f)|0}function Jf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;tb(a,b,c,d,e,f,0);return 0}function Kf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Ib(a,b,c,d,e,f)|0}function Lf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return rc(a,b,c,d,e,f)|0}function Mf(a){a=a|0;lg(a);Bf(a+40|0);Bf(a+80|0);return}function Nf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return $c(a,b,c,d,e,0,f)|0}function Of(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Pa(a,b,c,d,e,0,0,f)|0}function Pf(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return vb(a,b,c,d,e,0)|0}function Qf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;Jf(a,b,c,d,e,f)|0;return 0}function Rf(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Rd(a,b,c,d,e)|0}function Sf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return ub(a,b,1,c,d,e,16,0,32,f,128)|0}function Tf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Pc(a,b,c,d,e,0,0,f)|0}function Uf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Xc(a,b,c,d,e,f)|0}function Vf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Lf(a,b,c,d,e,f)|0}function Wf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return If(a,b,c,d,e,f)|0}function Xf(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Pf(a,b,c,d,e)|0}function Yf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return mc(a,b,c,d,e,f)|0}function Zf(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return he(a,b,c,d,e)|0}function _f(a,b){a=a|0;b=b|0;b=mb(34193,b&255,65)|0;c[a>>2]=(b|0)==0?0:b-34193|0;return ((b|0)==0)<<31>>31|0}function $f(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Rf(a,b,c,d,e)|0}function ag(a,b){a=a|0;b=b|0;me(a)|0;if(b|0)Ea(a,34340,34,0)|0;return}function bg(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Uf(a,b,c,d,e,f)|0}function cg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;d=b-d-(c>>>0>a>>>0|0)>>>0;return (z=d,a-c>>>0|0)|0}function dg(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return kc(a,b,c,d,e,f)|0}function eg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return Bg(a,b,c,d)|0}function fg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return (z=b+d+(a+c>>>0>>>0<a>>>0|0)>>>0,a+c>>>0|0)|0}function gg(b,c){b=b|0;c=c|0;a[b+3>>0]=c;a[b+2>>0]=c>>>8;a[b+1>>0]=c>>>16;a[b>>0]=c>>>24;return}function hg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Dd(a,b,c,d,e)|0}function ig(b){b=b|0;if(a[b+356>>0]|0)rh(b);c[b+80>>2]=-1;c[b+80+4>>2]=-1;return}function jg(b,c){b=b|0;c=c|0;a[b>>0]=c;a[b+1>>0]=c>>8;a[b+2>>0]=c>>16;a[b+3>>0]=c>>24;return}function kg(a,b,c){a=a|0;b=b|0;c=c|0;zf(b,32,c,32,0,0,0)|0;return ih(a,b)|0}function lg(a){a=a|0;var b=0;b=a+40|0;do{c[a>>2]=0;a=a+4|0}while((a|0)<(b|0));return}function mg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;ua(a,b,c,d,e)|0;return 0}function ng(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Zf(a,b,c,d,e)|0}function og(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Bb(a,b,c,d);return 0}function pg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return id(a,b,c,d,e)|0}function qg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;ke(a,b,c,d)|0;return 0}function rg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;og(a,b,c,d)|0;return 0}function sg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;je(a,b,c,d,e)|0;return 0}function tg(a,b){a=a|0;b=b|0;gf(b,32);return Yg(a,b)|0}function ug(a){a=a|0;return (d[a+2>>0]|0)<<8|(d[a+3>>0]|0)|(d[a+1>>0]|0)<<16|(d[a>>0]|0)<<24|0}function vg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return eg(a,b,c,d)|0}function wg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;La(a,b,c,d)|0;return 0}function xg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return eb(a,b,c,d,e)|0}function yg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return zd(a,b,c,d,e)|0}function zg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Ea(a,b,c,d)|0;return 0}function Ag(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return He(a,b,c,d)|0}function Bg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Ma(a,b,c,d);return 0}function Cg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return kd(a,b,c,d,e)|0}function Dg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return Gc(a,b,c,d)|0}function Eg(a,b){a=a|0;b=b|0;jg(a+12|0,(Rg(a+12|0)|0)+b|0);return}function Fg(a,b,c){a=a|0;b=b|0;c=c|0;return Wc(a,b,c)|0}function Gg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;zg(a,b,c,d)|0;return 0}function Hg(a,b,c){a=a|0;b=b|0;c=c|0;pg(a,b,0,35129,c)|0;return}function Ig(a,b){a=a|0;b=b|0;z=c[a+-64+(b<<7)+4>>2]|0;return c[a+-64+(b<<7)>>2]|0}function Jg(a,b,c){a=a|0;b=b|0;c=c|0;return Cd(a,b,c)|0}function Kg(b,c){b=b|0;c=c|0;b=Hb(b,c)|0;return ((a[b>>0]|0)==(c&255)<<24>>24?b:0)|0}function Lg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Aa(a,b,c,d,12);return 0}function Mg(a){a=a|0;a=yf(a<<24>>24|0,((a<<24>>24|0)<0)<<31>>31|0,63)|0;return a&255|0}function Ng(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Aa(a,b,c,d,8);return 0}function Og(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Aa(a,b,c,d,20);return 0}function Pg(a,b,c){a=a|0;b=b|0;c=c|0;pb(a,b,c)|0;return 0}function Qg(a,b,c){a=a|0;b=b|0;c=c|0;Vc(a,b,c)|0;return 0}function Rg(a){a=a|0;return d[a>>0]|d[a+1>>0]<<8|d[a+2>>0]<<16|d[a+3>>0]<<24|0}function Sg(a,b,c){a=a|0;b=b|0;c=c|0;return le(a,b,c)|0}function Tg(a,b,c){a=a|0;b=b|0;c=c|0;return cf(a,b,c)|0}function Ug(a){a=a|0;var b=0;b=l;l=l+a|0;l=l+15&-16;return b|0}function Vg(b){b=b|0;a[b>>0]=0;a[b+1>>0]=0;a[b+2>>0]=0;a[b+3>>0]=0;return}function Wg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;de(a,b,c,d)|0;return 0}function Xg(a){a=a|0;c[a>>2]=0;c[a+4>>2]=0;c[a+8>>2]=0;c[a+12>>2]=0;return}function Yg(a,b){a=a|0;b=b|0;return yc(a,b)|0}function Zg(a,b){a=a|0;b=b|0;return kh(a,b)|0}function _g(a,b){a=a|0;b=b|0;return oh(a,b)|0}function $g(a){a=a|0;var b=0;b=c[a>>2]|0;if(b|0)ra(b);mh(a);return}function ah(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return za(a,b,c,d,0)|0}function bh(a,b,c){a=a|0;b=b|0;c=c|0;return Od(a,b,c)|0}function ch(a,b){a=a|0;b=b|0;gf(b,32);return ih(a,b)|0}function dh(a){a=a|0;jg(a+12|0,~(Rg(a+12|0)|0));return}function eh(a,b){a=a|0;b=b|0;return tg(a,b)|0}function fh(a){a=a|0;var b=0;b=c[a>>2]|0;if(b|0)ra(b);ra(a);return}function gh(a,b){a=a|0;b=b|0;return Zg(a,b)|0}function hh(a,b){a=a|0;b=b|0;Ed(a|0,b+32|0,32)|0;return 0}function ih(a,b){a=a|0;b=b|0;return Yg(a,b)|0}function jh(a,b){a=a|0;b=b|0;return _g(a,b)|0}function kh(a,b){a=a|0;b=b|0;Ua(a,b);return 0}function lh(a,b){a=a|0;b=b|0;if(!o){o=a;p=b}}function mh(a){a=a|0;c[a+4>>2]=0;c[a>>2]=0;c[a+8>>2]=0;return}function nh(a,b){a=a|0;b=b|0;Ed(a|0,b|0,32)|0;return 0}function oh(a,b){a=a|0;b=b|0;bc(a,b);return 0}function ph(a,b){a=a|0;b=b|0;Ae(a,b)|0;return 0}function qh(a,b,c){a=a|0;b=b|0;c=c|0;return ib(a,b,c)|0}function rh(a){a=a|0;c[a+88>>2]=-1;c[a+88+4>>2]=-1;return}function sh(a,b){a=a|0;b=b|0;return ((a|0)!=0|(b|0)!=0)&1|0}function th(a,b){a=a|0;b=b|0;return (((b^a)&255)+-1|0)>>>31&255|0}function uh(a,b){a=a|0;b=b|0;fb(a|0,b|0,1024)|0;return}function vh(a){a=a|0;me(a)|0;return 0}function wh(a,b){a=a|0;b=b|0;l=a;m=b}function xh(a,b){a=a|0;b=b|0;return a>>>(32-b|0)|a<<b|0}function yh(a){a=a|0;vh(a)|0;return 0}function zh(){nf();return}function Ah(a,b){a=a|0;b=b|0;return a<<32-b|a>>>b|0}function Bh(a){a=a|0;return hf(a,(uc(a)|0)+1|0)|0}function Ch(a){a=a|0;gf(a,16);return}function Dh(){return 1073741824}function Eh(a){a=a|0;Pb(a|0,0,1024)|0;return}function Fh(){return 524288}function Gh(a){a=a|0;gf(a,32);return}function Hh(){return 16777216}function Ih(a){a=a|0;mh(a);return}function Jh(a){a=a|0;$g(a);return}function Kh(){return 32768}function Lh(){return 34258}function Mh(){return X(0)|0}function Nh(){return 102}function Oh(){aa(1);return}function Ph(){return 33554432}function Qh(){return 1408}function Rh(){return 536870912}function Sh(){return 12}function Th(){return 134217728}function Uh(){return -2147483648}function Vh(){return 34383}function Wh(){return 416}function Xh(a){a=a|0;l=a}function Yh(){return 34129}function Zh(a){a=a|0;z=a}function _h(){return 34262}function $h(){return 6}function ai(){return 256}function bi(){return 104}function ci(){return 384}function di(){return 35336}function ei(){return 34290}function fi(){return 34273}function gi(){return 8192}function hi(){return 4}function ii(){return 9}function ji(){return 34374}function ki(){return 34175}function li(){return 34185}function mi(){return 3}function ni(){return 35199}function oi(){return 34300}function pi(){return 1}function qi(){return 33908}function ri(){return 33484}function si(){return 208}function ti(){return 128}function ui(){return -1}function vi(){return 34107}function wi(){return 33498}function xi(){return 34115}function yi(){return 8}function zi(){return 24}function Ai(){return z|0}function Bi(){return 48}function Ci(){return 16}function Di(){return l|0}function Ei(){return 64}function Fi(){return 32}function Gi(){return 0} +// EMSCRIPTEN_END_FUNCS +return{_crypto_onetimeauth_poly1305_init:_g,_crypto_hash_sha512_init:me,_crypto_pwhash_scryptsalsa208sha256:Ub,_crypto_scalarmult_primitive:_h,_crypto_scalarmult_base:ih,_crypto_auth_bytes:Fi,_crypto_stream_chacha20_keybytes:Fi,_crypto_aead_chacha20poly1305_decrypt_detached:zb,_crypto_kdf_blake2b_bytes_min:Ci,_crypto_box_curve25519xchacha20poly1305_open_easy_afternm:sd,_crypto_generichash_blake2b_keybytes_max:Ei,_crypto_box_beforenmbytes:Fi,_crypto_stream_salsa208:db,___udivmoddi4:za,_crypto_sign_ed25519_sk_to_curve25519:Yc,_crypto_stream_chacha20_ietf_xor_ic:pf,_crypto_secretbox_xsalsa20poly1305_open:rc,_crypto_box_zerobytes:Fi,_crypto_secretbox_xchacha20poly1305_open_detached:Ya,_crypto_stream_salsa208_keybytes:Fi,_crypto_hash_sha512_bytes:Ei,stackSave:Di,_crypto_stream_xsalsa20_xor_ic:hd,_crypto_core_hsalsa20_keybytes:Fi,_crypto_sign_primitive:oi,_crypto_scalarmult_curve25519_bytes:Fi,_crypto_scalarmult_curve25519_scalarbytes:Fi,_crypto_pwhash_scryptsalsa208sha256_saltbytes:Fi,_crypto_pwhash_argon2i_str_verify:He,_crypto_box_curve25519xchacha20poly1305_secretkeybytes:Fi,_crypto_auth_hmacsha512_keygen:Gh,_crypto_box_detached_afternm:qf,_crypto_stream_salsa20_xor_ic:ef,_crypto_auth_hmacsha256_init:qb,_crypto_stream_chacha20_ietf_xor:Nf,_crypto_auth_hmacsha512256_final:be,_crypto_stream_aes128ctr_xor_afternm:ea,setThrew:lh,_crypto_aead_chacha20poly1305_ietf_nsecbytes:Gi,_crypto_kdf_blake2b_derive_from_key:Ib,_crypto_box_curve25519xsalsa20poly1305_keypair:tg,_crypto_hash_sha256_init:td,_crypto_stream_xsalsa20_noncebytes:zi,_crypto_generichash_keybytes_max:Ei,_crypto_verify_64:Me,stackAlloc:Ug,_crypto_box_curve25519xchacha20poly1305_keypair:tg,_crypto_box_curve25519xsalsa20poly1305_open:ed,_crypto_pwhash_memlimit_sensitive:Rh,_crypto_box_boxzerobytes:Ci,_crypto_kdf_blake2b_keybytes:Fi,_crypto_hash_sha512_update:Ea,_crypto_core_hchacha20:Da,_crypto_pwhash_bytes_min:Ci,_crypto_secretbox_open:Lf,_crypto_auth_hmacsha256_final:qe,_crypto_verify_16:Oe,_crypto_stream_aes128ctr_xor:yd,_crypto_pwhash_scryptsalsa208sha256_memlimit_max:ui,_crypto_pwhash_scryptsalsa208sha256_ll:dd,_crypto_stream_salsa208_xor:Sa,_crypto_secretbox_xsalsa20poly1305_keygen:Gh,_crypto_aead_chacha20poly1305_abytes:Ci,_crypto_pwhash_argon2i_bytes_max:ui,_crypto_box_curve25519xchacha20poly1305_easy_afternm:Nd,_crypto_onetimeauth_poly1305_update:eg,_crypto_pwhash_memlimit_max:Uh,_crypto_verify_64_bytes:Ei,_crypto_onetimeauth_poly1305_keygen:Gh,_crypto_generichash_blake2b_keygen:Gh,_crypto_pwhash_argon2i_strprefix:ki,_crypto_auth_hmacsha256_update:wg,_crypto_aead_xchacha20poly1305_ietf_encrypt:Jc,_crypto_pwhash_scryptsalsa208sha256_strbytes:Nh,_crypto_stream_xsalsa20_keybytes:Fi,_crypto_generichash_keygen:Gh,_crypto_pwhash_argon2i_str:_b,_crypto_box_sealbytes:Bi,_crypto_onetimeauth:ng,_crypto_secretbox_boxzerobytes:Ci,_crypto_aead_chacha20poly1305_ietf_keygen:Gh,_crypto_stream_chacha20:Cg,_crypto_box_open_afternm:Vf,_crypto_pwhash_opslimit_moderate:$h,_crypto_box_macbytes:Ci,_crypto_shorthash_bytes:yi,_crypto_generichash_primitive:vi,_crypto_sign_ed25519_keypair:Ae,_crypto_sign_ed25519ph_statebytes:si,_crypto_aead_xchacha20poly1305_ietf_keybytes:Fi,_crypto_auth_primitive:ri,_crypto_core_salsa2012_keybytes:Fi,_malloc:ia,_crypto_stream_noncebytes:zi,_crypto_secretbox_xchacha20poly1305_keybytes:Fi,_crypto_secretbox_xsalsa20poly1305_keybytes:Fi,_crypto_pwhash_saltbytes:Ci,_crypto_secretbox_noncebytes:zi,_crypto_secretbox_xsalsa20poly1305_macbytes:Ci,_crypto_pwhash_argon2i_opslimit_max:ui,_crypto_auth_hmacsha512_bytes:Ei,_crypto_generichash_keybytes:Fi,_crypto_sign_publickeybytes:Fi,_crypto_pwhash_argon2i_memlimit_moderate:Th,_crypto_generichash_blake2b:Sc,_crypto_core_hchacha20_keybytes:Fi,___uremdi3:Pe,_crypto_pwhash_argon2i_opslimit_moderate:$h,_randombytes_implementation_name:Vh,_crypto_stream_xchacha20_noncebytes:zi,_crypto_sign_ed25519_verify_detached:Pf,_crypto_hash_sha512_statebytes:si,_crypto_secretbox_zerobytes:Fi,_crypto_verify_32_bytes:Fi,stackRestore:Xh,_crypto_kdf_keygen:Gh,_crypto_stream_xsalsa20_xor:If,_crypto_stream_chacha20_ietf_keygen:Gh,_crypto_stream_chacha20_keygen:Gh,_crypto_box_easy:se,_crypto_hash_sha256:ee,_crypto_sign_ed25519_seedbytes:Fi,_crypto_pwhash_alg_argon2i13:pi,_crypto_shorthash_siphash24_bytes:yi,_crypto_pwhash_opslimit_min:mi,_crypto_box_curve25519xsalsa20poly1305_publickeybytes:Fi,_crypto_kdf_blake2b_bytes_max:Ei,_crypto_generichash_bytes_max:Ei,_crypto_stream_chacha20_ietf_noncebytes:Sh,_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive:Dh,_crypto_box_curve25519xchacha20poly1305_open_easy:rd,_crypto_box_beforenm:Jg,_crypto_box_curve25519xsalsa20poly1305_afternm:Uf,_crypto_sign_statebytes:si,_crypto_sign_open:Yf,_crypto_box_seed_keypair:Fg,_crypto_auth_hmacsha512_init:pb,_crypto_sign_ed25519_sk_to_pk:hh,_crypto_scalarmult_curve25519:Od,_crypto_box_open_easy:Pd,_crypto_auth_hmacsha512:ie,_crypto_stream_keygen:Gh,_crypto_stream_aes128ctr_keybytes:Ci,_crypto_auth_hmacsha512256_keybytes:Fi,_crypto_aead_chacha20poly1305_keybytes:Fi,_free:ra,_crypto_kx_client_session_keys:Ob,_crypto_box_curve25519xchacha20poly1305_seedbytes:Fi,_crypto_onetimeauth_poly1305_keybytes:Fi,_crypto_sign_ed25519_secretkeybytes:Ei,_crypto_kdf_blake2b_contextbytes:yi,_crypto_stream_salsa2012:cb,_crypto_sign_seedbytes:Fi,_crypto_box_curve25519xchacha20poly1305_beforenmbytes:Fi,_randombytes_random:Mh,_crypto_sign_ed25519ph_update:zg,_crypto_auth_hmacsha256_keygen:Gh,_crypto_auth_hmacsha256_statebytes:si,_randombytes_buf_deterministic:Hg,_crypto_aead_chacha20poly1305_encrypt_detached:Kb,_crypto_stream_xsalsa20_keygen:Gh,_crypto_hash_primitive:qi,_crypto_sign_ed25519_pk_to_curve25519:lc,_crypto_shorthash_siphash24:ua,_crypto_box_curve25519xsalsa20poly1305_macbytes:Ci,_crypto_sign_ed25519_bytes:Ei,_crypto_sign_ed25519:kc,_crypto_core_salsa20_constbytes:Ci,_crypto_secretbox_primitive:fi,_crypto_pwhash_argon2i_opslimit_interactive:hi,_crypto_pwhash_argon2i_saltbytes:Ci,_crypto_box_curve25519xchacha20poly1305_open_detached_afternm:Je,_crypto_box_curve25519xsalsa20poly1305_beforenmbytes:Fi,_crypto_stream_xchacha20_keygen:Gh,_crypto_core_hchacha20_constbytes:Ci,_crypto_stream_xchacha20_xor:Df,_randombytes_seedbytes:Fi,_crypto_sign_final_create:qg,_crypto_kx_secretkeybytes:Fi,_crypto_box_detached:pd,_randombytes_buf:gf,_crypto_generichash_blake2b_saltbytes:Ci,_crypto_box_open_detached:md,_crypto_kx_seedbytes:Fi,_crypto_secretbox_xsalsa20poly1305_zerobytes:Fi,_crypto_box_curve25519xchacha20poly1305_open_detached:Mc,_crypto_generichash_blake2b_keybytes:Fi,_crypto_box_curve25519xchacha20poly1305_easy:Md,_crypto_pwhash_argon2i_bytes_min:Ci,_crypto_pwhash_scryptsalsa208sha256_str:Lb,_crypto_hash:Wg,_i64Subtract:cg,_crypto_box_seedbytes:Fi,_crypto_generichash_blake2b_bytes_min:Ci,_crypto_box_curve25519xsalsa20poly1305:gd,_crypto_generichash_blake2b_statebytes:ci,_crypto_sign_ed25519ph_final_create:ke,_crypto_aead_chacha20poly1305_ietf_decrypt_detached:lb,_crypto_generichash_final:Tg,_crypto_auth_hmacsha512_update:zg,_crypto_auth_hmacsha256:ge,_crypto_box_keypair:eh,_crypto_hash_sha256_bytes:Fi,___udivdi3:ah,_crypto_pwhash_argon2i_passwd_max:ui,_sodium_init:xf,_crypto_secretbox_macbytes:Ci,_crypto_aead_xchacha20poly1305_ietf_npubbytes:zi,_bitshift64Shl:vf,_crypto_pwhash_argon2i_opslimit_min:mi,setTempRet0:Zh,_crypto_sign_seed_keypair:Qg,_crypto_core_hchacha20_inputbytes:Ci,___muldi3:af,_crypto_core_salsa2012_constbytes:Ci,_crypto_kx_seed_keypair:kg,_crypto_box_curve25519xchacha20poly1305_detached_afternm:Qe,_crypto_aead_chacha20poly1305_nsecbytes:Gi,_sodium_library_minimal:Gi,_crypto_aead_xchacha20poly1305_ietf_nsecbytes:Gi,_crypto_pwhash_argon2i_strbytes:ti,_crypto_pwhash_argon2i_memlimit_max:Uh,_crypto_generichash_blake2b_salt_personal:Ec,_crypto_stream_aes128ctr_beforenmbytes:Qh,_crypto_kdf_derive_from_key:Kf,_crypto_secretbox_xsalsa20poly1305_noncebytes:zi,_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive:Fh,_crypto_pwhash_argon2i_memlimit_interactive:Ph,_crypto_hash_sha256_final:Fe,_crypto_stream_keybytes:Fi,_crypto_pwhash_memlimit_min:gi,_crypto_aead_chacha20poly1305_ietf_npubbytes:Sh,_crypto_stream_salsa208_noncebytes:yi,_sodium_library_version_minor:hi,_crypto_onetimeauth_bytes:Ci,_crypto_box_open:of,_crypto_secretbox_xchacha20poly1305_open_easy:vd,_crypto_scalarmult_curve25519_base:Yg,_crypto_sign_ed25519_open:mc,_crypto_stream_chacha20_ietf_keybytes:Fi,_crypto_box_noncebytes:zi,_crypto_core_hchacha20_outputbytes:Fi,_crypto_stream_salsa2012_xor:Ra,_crypto_onetimeauth_keygen:Gh,_crypto_pwhash_strbytes:ti,_crypto_auth_hmacsha512256_update:Gg,_crypto_core_salsa208_outputbytes:Ei,_crypto_onetimeauth_poly1305:Zf,_crypto_secretbox_xchacha20poly1305_macbytes:Ci,_crypto_kdf_bytes_min:Ci,_crypto_sign_ed25519_sk_to_seed:nh,_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive:Hh,_crypto_stream_xsalsa20:zd,_crypto_box_open_easy_afternm:Td,_crypto_box_curve25519xsalsa20poly1305_seedbytes:Fi,_crypto_stream_salsa20_keybytes:Fi,_crypto_kdf_primitive:vi,_crypto_sign_ed25519ph_final_verify:le,_crypto_sign_ed25519_publickeybytes:Fi,_crypto_stream_aes128ctr:Zd,_crypto_shorthash:mg,_crypto_auth_keybytes:Fi,_crypto_box_curve25519xsalsa20poly1305_open_afternm:Lf,_crypto_aead_chacha20poly1305_npubbytes:yi,_crypto_aead_xchacha20poly1305_ietf_abytes:Ci,_crypto_onetimeauth_poly1305_final:Zg,_crypto_onetimeauth_poly1305_bytes:Ci,_crypto_box_curve25519xsalsa20poly1305_seed_keypair:Wc,_crypto_box_primitive:wi,_crypto_pwhash_str:Cf,_crypto_auth_hmacsha512_keybytes:Fi,_crypto_auth:sg,_crypto_pwhash_scryptsalsa208sha256_bytes_min:Ci,_crypto_core_salsa20_keybytes:Fi,_crypto_box_afternm:bg,_crypto_core_salsa208_constbytes:Ci,_crypto_onetimeauth_primitive:Yh,_crypto_pwhash_scryptsalsa208sha256_str_verify:vc,_sodium_version_string:ni,_crypto_stream_xchacha20_xor_ic:ld,_crypto_pwhash_scryptsalsa208sha256_passwd_min:Gi,_crypto_stream_chacha20_ietf:pg,_crypto_generichash:zf,_crypto_core_hsalsa20_outputbytes:Fi,_crypto_pwhash_opslimit_interactive:hi,_crypto_stream_aes128ctr_beforenm:da,getTempRet0:Ai,_crypto_box_curve25519xsalsa20poly1305_noncebytes:zi,_crypto_stream_salsa2012_noncebytes:yi,_crypto_core_salsa208_keybytes:Fi,_crypto_aead_chacha20poly1305_ietf_decrypt:Bc,_crypto_auth_hmacsha512256_init:Pg,_crypto_kx_server_session_keys:Nb,_crypto_onetimeauth_poly1305_verify:Rf,_crypto_auth_hmacsha512_final:pe,_crypto_stream_aes128ctr_noncebytes:Ci,_crypto_box_secretkeybytes:Fi,_crypto_stream_salsa2012_keygen:Gh,_crypto_onetimeauth_update:vg,_crypto_core_salsa20:Og,_crypto_pwhash_memlimit_interactive:Ph,_crypto_scalarmult_bytes:Fi,_crypto_secretbox_detached:Ta,_crypto_stream_xor:Wf,_crypto_secretbox_xchacha20poly1305_easy:fe,_crypto_secretbox_easy:ve,_crypto_aead_xchacha20poly1305_ietf_decrypt_detached:Zb,_crypto_stream_salsa20:xg,_sodium_bin2hex:Dc,_crypto_auth_hmacsha512_statebytes:Wh,_crypto_pwhash_argon2i_opslimit_sensitive:yi,_crypto_generichash_blake2b_bytes_max:Ei,_crypto_hash_sha256_update:La,_crypto_core_hsalsa20_constbytes:Ci,_crypto_box_easy_afternm:te,_crypto_auth_hmacsha512256_verify:Dd,_crypto_pwhash_memlimit_moderate:Th,_crypto_core_salsa20_inputbytes:Ci,_crypto_box_publickeybytes:Fi,_crypto_sign_secretkeybytes:Ei,___muldsi3:Fd,_crypto_scalarmult_scalarbytes:Fi,_crypto_verify_32:Ne,_crypto_kx_sessionkeybytes:Fi,_crypto_aead_chacha20poly1305_decrypt:Cc,_crypto_sign:dg,_crypto_pwhash_passwd_max:ui,_crypto_pwhash_scryptsalsa208sha256_opslimit_min:Kh,_sodium_hex2bin:kb,_crypto_pwhash_argon2i_alg_argon2i13:pi,_crypto_secretbox_keybytes:Fi,_randombytes:Af,_crypto_hash_bytes:Ei,_crypto_stream_salsa20_keygen:Gh,_crypto_hash_sha256_statebytes:bi,_crypto_pwhash_argon2i_passwd_min:Gi,_crypto_pwhash_opslimit_sensitive:yi,_crypto_sign_init:yh,_crypto_generichash_blake2b_personalbytes:Ci,_crypto_stream_chacha20_xor_ic:jf,_crypto_sign_verify_detached:Xf,_crypto_onetimeauth_verify:$f,_crypto_sign_ed25519_detached:Jf,_crypto_generichash_init:Dg,_i64Add:fg,_crypto_sign_bytes:Ei,_crypto_generichash_update:rg,_crypto_scalarmult:bh,_crypto_aead_chacha20poly1305_ietf_abytes:Ci,_crypto_sign_detached:Qf,_crypto_generichash_blake2b_update:og,_crypto_box_curve25519xsalsa20poly1305_beforenm:Cd,_crypto_generichash_blake2b_bytes:Fi,_crypto_auth_hmacsha512256_bytes:Fi,_crypto_box_curve25519xchacha20poly1305_noncebytes:zi,_randombytes_uniform:Ie,_crypto_shorthash_siphash24_keybytes:Ci,_crypto_shorthash_keygen:Ch,_crypto_onetimeauth_init:jh,_crypto_generichash_bytes:Fi,_crypto_stream_salsa20_xor:Of,_crypto_auth_hmacsha512_verify:Kd,_crypto_generichash_blake2b_keybytes_min:Ci,_bitshift64Lshr:yf,_crypto_kx_publickeybytes:Fi,_crypto_pwhash_bytes_max:ui,_crypto_aead_chacha20poly1305_ietf_keybytes:Fi,_crypto_aead_chacha20poly1305_ietf_encrypt_detached:yb,_crypto_stream:yg,_sbrk:jd,_crypto_box_curve25519xchacha20poly1305_beforenm:Ad,_memcpy:fb,_crypto_pwhash:Bd,_crypto_auth_hmacsha512256:je,_crypto_secretbox_xsalsa20poly1305:Xc,_crypto_verify_16_bytes:Ci,_crypto_stream_salsa208_keygen:Gh,_emscripten_get_global_libc:di,_crypto_shorthash_siphashx24_bytes:Ci,_crypto_generichash_blake2b_final:cf,_crypto_generichash_blake2b_init_salt_personal:xc,_crypto_box_seal:wc,_crypto_aead_xchacha20poly1305_ietf_keygen:Gh,_crypto_kx_keypair:ch,runPostSets:We,_crypto_pwhash_alg_default:pi,_crypto_box:wf,_crypto_stream_primitive:ji,_crypto_secretbox_xsalsa20poly1305_boxzerobytes:Ci,_crypto_pwhash_str_verify:Ag,_crypto_generichash_keybytes_min:Ci,_crypto_generichash_statebytes:ci,_crypto_onetimeauth_poly1305_statebytes:ai,_crypto_sign_final_verify:Sg,_crypto_pwhash_strprefix:ki,_crypto_secretbox_keygen:Gh,_crypto_secretbox_xchacha20poly1305_noncebytes:zi,_crypto_hash_sha512:de,_llvm_cttz_i32:Yd,_crypto_pwhash_scryptsalsa208sha256_bytes_max:ui,_crypto_box_curve25519xchacha20poly1305_detached:Oc,_sodium_library_version_major:ii,_crypto_aead_chacha20poly1305_ietf_encrypt:Kc,_crypto_generichash_blake2b_init:Gc,_randombytes_close:Gi,_crypto_pwhash_primitive:li,_crypto_onetimeauth_keybytes:Fi,_crypto_pwhash_argon2i:ec,_crypto_stream_aes128ctr_afternm:fa,_crypto_kdf_keybytes:Fi,establishStackSpace:wh,_crypto_aead_chacha20poly1305_encrypt:Nc,_crypto_core_salsa2012_inputbytes:Ci,_crypto_pwhash_scryptsalsa208sha256_memlimit_min:Hh,_crypto_core_salsa208:Ng,_crypto_pwhash_opslimit_max:ui,_crypto_auth_verify:hg,_crypto_sign_ed25519_seed_keypair:Vc,_crypto_auth_hmacsha512256_keygen:Gh,_randombytes_stir:Oh,_memset:Pb,_crypto_box_open_detached_afternm:mf,_crypto_pwhash_argon2i_memlimit_sensitive:Rh,_crypto_kx_primitive:xi,_crypto_stream_salsa2012_keybytes:Fi,_crypto_aead_xchacha20poly1305_ietf_decrypt:Ac,_crypto_pwhash_scryptsalsa208sha256_strprefix:Lh,_crypto_core_salsa20_outputbytes:Ei,_crypto_auth_keygen:Gh,_crypto_secretbox:Uf,_crypto_aead_xchacha20poly1305_ietf_encrypt_detached:Xb,_crypto_pwhash_scryptsalsa208sha256_passwd_max:ui,_crypto_auth_hmacsha256_bytes:Fi,_crypto_auth_hmacsha256_verify:Ld,_crypto_sign_keypair:ph,_crypto_stream_xchacha20:Vd,_crypto_onetimeauth_statebytes:ai,_crypto_sign_ed25519ph_init:vh,_crypto_stream_salsa20_noncebytes:yi,_crypto_shorthash_keybytes:Ci,_crypto_aead_chacha20poly1305_keygen:Gh,_crypto_shorthash_siphashx24:ta,_memmove:Ed,_crypto_hash_sha512_final:Be,_crypto_box_curve25519xsalsa20poly1305_zerobytes:Fi,_crypto_shorthash_siphashx24_keybytes:Ci,_crypto_pwhash_passwd_min:Gi,_crypto_kdf_bytes_max:Ei,_crypto_box_curve25519xsalsa20poly1305_boxzerobytes:Ci,_crypto_generichash_bytes_min:Ci,_crypto_core_salsa2012_outputbytes:Ei,_crypto_auth_hmacsha256_keybytes:Fi,_crypto_core_salsa208_inputbytes:Ci,_crypto_pwhash_scryptsalsa208sha256_opslimit_max:ui,_crypto_sign_update:Gg,_crypto_secretbox_xchacha20poly1305_detached:Qa,_crypto_stream_chacha20_noncebytes:yi,_crypto_secretbox_open_detached:$a,_crypto_box_curve25519xchacha20poly1305_seed_keypair:Wc,_crypto_pwhash_argon2i_memlimit_min:gi,_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive:Ph,_crypto_box_curve25519xsalsa20poly1305_secretkeybytes:Fi,_crypto_kdf_contextbytes:yi,_crypto_stream_xchacha20_keybytes:Fi,_crypto_box_seal_open:Zc,_crypto_shorthash_primitive:ei,_crypto_core_hsalsa20_inputbytes:Ci,_crypto_onetimeauth_final:gh,_crypto_secretbox_open_easy:Wd,_crypto_core_salsa2012:Lg,_crypto_box_curve25519xchacha20poly1305_macbytes:Ci,_crypto_auth_hmacsha512256_statebytes:Wh,_bitshift64Ashr:Xe,_crypto_box_curve25519xchacha20poly1305_publickeybytes:Fi,_crypto_stream_chacha20_xor:Tf,_crypto_core_hsalsa20:Ga,stackAlloc:Ug,stackSave:Di,stackRestore:Xh,establishStackSpace:wh,setThrew:lh,setTempRet0:Zh,getTempRet0:Ai}}) -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ -var _hyphenPattern = /-(.)/g; +// EMSCRIPTEN_END_ASM +(Module.asmGlobalArg,Module.asmLibraryArg,buffer);var _crypto_onetimeauth_poly1305_init=Module["_crypto_onetimeauth_poly1305_init"]=asm["_crypto_onetimeauth_poly1305_init"];var _crypto_hash_sha512_init=Module["_crypto_hash_sha512_init"]=asm["_crypto_hash_sha512_init"];var _crypto_pwhash_scryptsalsa208sha256=Module["_crypto_pwhash_scryptsalsa208sha256"]=asm["_crypto_pwhash_scryptsalsa208sha256"];var _crypto_scalarmult_primitive=Module["_crypto_scalarmult_primitive"]=asm["_crypto_scalarmult_primitive"];var _crypto_scalarmult_base=Module["_crypto_scalarmult_base"]=asm["_crypto_scalarmult_base"];var _crypto_auth_bytes=Module["_crypto_auth_bytes"]=asm["_crypto_auth_bytes"];var _crypto_stream_chacha20_keybytes=Module["_crypto_stream_chacha20_keybytes"]=asm["_crypto_stream_chacha20_keybytes"];var _crypto_aead_chacha20poly1305_decrypt_detached=Module["_crypto_aead_chacha20poly1305_decrypt_detached"]=asm["_crypto_aead_chacha20poly1305_decrypt_detached"];var _crypto_kdf_blake2b_bytes_min=Module["_crypto_kdf_blake2b_bytes_min"]=asm["_crypto_kdf_blake2b_bytes_min"];var _crypto_box_curve25519xchacha20poly1305_open_easy_afternm=Module["_crypto_box_curve25519xchacha20poly1305_open_easy_afternm"]=asm["_crypto_box_curve25519xchacha20poly1305_open_easy_afternm"];var _crypto_generichash_blake2b_keybytes_max=Module["_crypto_generichash_blake2b_keybytes_max"]=asm["_crypto_generichash_blake2b_keybytes_max"];var _crypto_box_beforenmbytes=Module["_crypto_box_beforenmbytes"]=asm["_crypto_box_beforenmbytes"];var _crypto_stream_salsa208=Module["_crypto_stream_salsa208"]=asm["_crypto_stream_salsa208"];var ___udivmoddi4=Module["___udivmoddi4"]=asm["___udivmoddi4"];var _crypto_sign_ed25519_sk_to_curve25519=Module["_crypto_sign_ed25519_sk_to_curve25519"]=asm["_crypto_sign_ed25519_sk_to_curve25519"];var _crypto_stream_chacha20_ietf_xor_ic=Module["_crypto_stream_chacha20_ietf_xor_ic"]=asm["_crypto_stream_chacha20_ietf_xor_ic"];var _crypto_secretbox_xsalsa20poly1305_open=Module["_crypto_secretbox_xsalsa20poly1305_open"]=asm["_crypto_secretbox_xsalsa20poly1305_open"];var _crypto_box_zerobytes=Module["_crypto_box_zerobytes"]=asm["_crypto_box_zerobytes"];var _crypto_secretbox_xchacha20poly1305_open_detached=Module["_crypto_secretbox_xchacha20poly1305_open_detached"]=asm["_crypto_secretbox_xchacha20poly1305_open_detached"];var _crypto_stream_salsa208_keybytes=Module["_crypto_stream_salsa208_keybytes"]=asm["_crypto_stream_salsa208_keybytes"];var _crypto_hash_sha512_bytes=Module["_crypto_hash_sha512_bytes"]=asm["_crypto_hash_sha512_bytes"];var stackSave=Module["stackSave"]=asm["stackSave"];var _crypto_stream_xsalsa20_xor_ic=Module["_crypto_stream_xsalsa20_xor_ic"]=asm["_crypto_stream_xsalsa20_xor_ic"];var _crypto_core_hsalsa20_keybytes=Module["_crypto_core_hsalsa20_keybytes"]=asm["_crypto_core_hsalsa20_keybytes"];var _crypto_sign_primitive=Module["_crypto_sign_primitive"]=asm["_crypto_sign_primitive"];var _crypto_scalarmult_curve25519_bytes=Module["_crypto_scalarmult_curve25519_bytes"]=asm["_crypto_scalarmult_curve25519_bytes"];var _crypto_scalarmult_curve25519_scalarbytes=Module["_crypto_scalarmult_curve25519_scalarbytes"]=asm["_crypto_scalarmult_curve25519_scalarbytes"];var _crypto_pwhash_scryptsalsa208sha256_saltbytes=Module["_crypto_pwhash_scryptsalsa208sha256_saltbytes"]=asm["_crypto_pwhash_scryptsalsa208sha256_saltbytes"];var _crypto_pwhash_argon2i_str_verify=Module["_crypto_pwhash_argon2i_str_verify"]=asm["_crypto_pwhash_argon2i_str_verify"];var _crypto_box_curve25519xchacha20poly1305_secretkeybytes=Module["_crypto_box_curve25519xchacha20poly1305_secretkeybytes"]=asm["_crypto_box_curve25519xchacha20poly1305_secretkeybytes"];var _crypto_auth_hmacsha512_keygen=Module["_crypto_auth_hmacsha512_keygen"]=asm["_crypto_auth_hmacsha512_keygen"];var _crypto_box_detached_afternm=Module["_crypto_box_detached_afternm"]=asm["_crypto_box_detached_afternm"];var _crypto_stream_salsa20_xor_ic=Module["_crypto_stream_salsa20_xor_ic"]=asm["_crypto_stream_salsa20_xor_ic"];var _crypto_auth_hmacsha256_init=Module["_crypto_auth_hmacsha256_init"]=asm["_crypto_auth_hmacsha256_init"];var _crypto_stream_chacha20_ietf_xor=Module["_crypto_stream_chacha20_ietf_xor"]=asm["_crypto_stream_chacha20_ietf_xor"];var _crypto_auth_hmacsha512256_final=Module["_crypto_auth_hmacsha512256_final"]=asm["_crypto_auth_hmacsha512256_final"];var _crypto_stream_aes128ctr_xor_afternm=Module["_crypto_stream_aes128ctr_xor_afternm"]=asm["_crypto_stream_aes128ctr_xor_afternm"];var setThrew=Module["setThrew"]=asm["setThrew"];var _crypto_aead_chacha20poly1305_ietf_nsecbytes=Module["_crypto_aead_chacha20poly1305_ietf_nsecbytes"]=asm["_crypto_aead_chacha20poly1305_ietf_nsecbytes"];var _crypto_kdf_blake2b_derive_from_key=Module["_crypto_kdf_blake2b_derive_from_key"]=asm["_crypto_kdf_blake2b_derive_from_key"];var _crypto_box_curve25519xsalsa20poly1305_keypair=Module["_crypto_box_curve25519xsalsa20poly1305_keypair"]=asm["_crypto_box_curve25519xsalsa20poly1305_keypair"];var _crypto_hash_sha256_init=Module["_crypto_hash_sha256_init"]=asm["_crypto_hash_sha256_init"];var _crypto_stream_xsalsa20_noncebytes=Module["_crypto_stream_xsalsa20_noncebytes"]=asm["_crypto_stream_xsalsa20_noncebytes"];var _crypto_generichash_keybytes_max=Module["_crypto_generichash_keybytes_max"]=asm["_crypto_generichash_keybytes_max"];var _crypto_verify_64=Module["_crypto_verify_64"]=asm["_crypto_verify_64"];var stackAlloc=Module["stackAlloc"]=asm["stackAlloc"];var _crypto_box_curve25519xchacha20poly1305_keypair=Module["_crypto_box_curve25519xchacha20poly1305_keypair"]=asm["_crypto_box_curve25519xchacha20poly1305_keypair"];var _crypto_box_curve25519xsalsa20poly1305_open=Module["_crypto_box_curve25519xsalsa20poly1305_open"]=asm["_crypto_box_curve25519xsalsa20poly1305_open"];var _crypto_pwhash_memlimit_sensitive=Module["_crypto_pwhash_memlimit_sensitive"]=asm["_crypto_pwhash_memlimit_sensitive"];var _crypto_box_boxzerobytes=Module["_crypto_box_boxzerobytes"]=asm["_crypto_box_boxzerobytes"];var _crypto_kdf_blake2b_keybytes=Module["_crypto_kdf_blake2b_keybytes"]=asm["_crypto_kdf_blake2b_keybytes"];var _crypto_hash_sha512_update=Module["_crypto_hash_sha512_update"]=asm["_crypto_hash_sha512_update"];var _crypto_core_hchacha20=Module["_crypto_core_hchacha20"]=asm["_crypto_core_hchacha20"];var _crypto_pwhash_bytes_min=Module["_crypto_pwhash_bytes_min"]=asm["_crypto_pwhash_bytes_min"];var _crypto_secretbox_open=Module["_crypto_secretbox_open"]=asm["_crypto_secretbox_open"];var _crypto_auth_hmacsha256_final=Module["_crypto_auth_hmacsha256_final"]=asm["_crypto_auth_hmacsha256_final"];var _crypto_verify_16=Module["_crypto_verify_16"]=asm["_crypto_verify_16"];var _crypto_stream_aes128ctr_xor=Module["_crypto_stream_aes128ctr_xor"]=asm["_crypto_stream_aes128ctr_xor"];var _crypto_pwhash_scryptsalsa208sha256_memlimit_max=Module["_crypto_pwhash_scryptsalsa208sha256_memlimit_max"]=asm["_crypto_pwhash_scryptsalsa208sha256_memlimit_max"];var _crypto_pwhash_scryptsalsa208sha256_ll=Module["_crypto_pwhash_scryptsalsa208sha256_ll"]=asm["_crypto_pwhash_scryptsalsa208sha256_ll"];var _crypto_stream_salsa208_xor=Module["_crypto_stream_salsa208_xor"]=asm["_crypto_stream_salsa208_xor"];var _crypto_secretbox_xsalsa20poly1305_keygen=Module["_crypto_secretbox_xsalsa20poly1305_keygen"]=asm["_crypto_secretbox_xsalsa20poly1305_keygen"];var _crypto_aead_chacha20poly1305_abytes=Module["_crypto_aead_chacha20poly1305_abytes"]=asm["_crypto_aead_chacha20poly1305_abytes"];var _crypto_pwhash_argon2i_bytes_max=Module["_crypto_pwhash_argon2i_bytes_max"]=asm["_crypto_pwhash_argon2i_bytes_max"];var _crypto_box_curve25519xchacha20poly1305_easy_afternm=Module["_crypto_box_curve25519xchacha20poly1305_easy_afternm"]=asm["_crypto_box_curve25519xchacha20poly1305_easy_afternm"];var _crypto_onetimeauth_poly1305_update=Module["_crypto_onetimeauth_poly1305_update"]=asm["_crypto_onetimeauth_poly1305_update"];var _crypto_pwhash_memlimit_max=Module["_crypto_pwhash_memlimit_max"]=asm["_crypto_pwhash_memlimit_max"];var _crypto_verify_64_bytes=Module["_crypto_verify_64_bytes"]=asm["_crypto_verify_64_bytes"];var _crypto_onetimeauth_poly1305_keygen=Module["_crypto_onetimeauth_poly1305_keygen"]=asm["_crypto_onetimeauth_poly1305_keygen"];var _crypto_generichash_blake2b_keygen=Module["_crypto_generichash_blake2b_keygen"]=asm["_crypto_generichash_blake2b_keygen"];var _crypto_pwhash_argon2i_strprefix=Module["_crypto_pwhash_argon2i_strprefix"]=asm["_crypto_pwhash_argon2i_strprefix"];var _crypto_auth_hmacsha256_update=Module["_crypto_auth_hmacsha256_update"]=asm["_crypto_auth_hmacsha256_update"];var _crypto_aead_xchacha20poly1305_ietf_encrypt=Module["_crypto_aead_xchacha20poly1305_ietf_encrypt"]=asm["_crypto_aead_xchacha20poly1305_ietf_encrypt"];var _crypto_pwhash_scryptsalsa208sha256_strbytes=Module["_crypto_pwhash_scryptsalsa208sha256_strbytes"]=asm["_crypto_pwhash_scryptsalsa208sha256_strbytes"];var _crypto_stream_xsalsa20_keybytes=Module["_crypto_stream_xsalsa20_keybytes"]=asm["_crypto_stream_xsalsa20_keybytes"];var _crypto_generichash_keygen=Module["_crypto_generichash_keygen"]=asm["_crypto_generichash_keygen"];var _crypto_pwhash_argon2i_str=Module["_crypto_pwhash_argon2i_str"]=asm["_crypto_pwhash_argon2i_str"];var _crypto_box_sealbytes=Module["_crypto_box_sealbytes"]=asm["_crypto_box_sealbytes"];var _crypto_onetimeauth=Module["_crypto_onetimeauth"]=asm["_crypto_onetimeauth"];var _crypto_secretbox_boxzerobytes=Module["_crypto_secretbox_boxzerobytes"]=asm["_crypto_secretbox_boxzerobytes"];var _crypto_aead_chacha20poly1305_ietf_keygen=Module["_crypto_aead_chacha20poly1305_ietf_keygen"]=asm["_crypto_aead_chacha20poly1305_ietf_keygen"];var _crypto_stream_chacha20=Module["_crypto_stream_chacha20"]=asm["_crypto_stream_chacha20"];var _crypto_box_open_afternm=Module["_crypto_box_open_afternm"]=asm["_crypto_box_open_afternm"];var _crypto_pwhash_opslimit_moderate=Module["_crypto_pwhash_opslimit_moderate"]=asm["_crypto_pwhash_opslimit_moderate"];var _crypto_box_macbytes=Module["_crypto_box_macbytes"]=asm["_crypto_box_macbytes"];var _crypto_shorthash_bytes=Module["_crypto_shorthash_bytes"]=asm["_crypto_shorthash_bytes"];var _crypto_generichash_primitive=Module["_crypto_generichash_primitive"]=asm["_crypto_generichash_primitive"];var _crypto_sign_ed25519_keypair=Module["_crypto_sign_ed25519_keypair"]=asm["_crypto_sign_ed25519_keypair"];var _crypto_sign_ed25519ph_statebytes=Module["_crypto_sign_ed25519ph_statebytes"]=asm["_crypto_sign_ed25519ph_statebytes"];var _crypto_aead_xchacha20poly1305_ietf_keybytes=Module["_crypto_aead_xchacha20poly1305_ietf_keybytes"]=asm["_crypto_aead_xchacha20poly1305_ietf_keybytes"];var _crypto_auth_primitive=Module["_crypto_auth_primitive"]=asm["_crypto_auth_primitive"];var _crypto_core_salsa2012_keybytes=Module["_crypto_core_salsa2012_keybytes"]=asm["_crypto_core_salsa2012_keybytes"];var _malloc=Module["_malloc"]=asm["_malloc"];var _crypto_stream_noncebytes=Module["_crypto_stream_noncebytes"]=asm["_crypto_stream_noncebytes"];var _crypto_secretbox_xchacha20poly1305_keybytes=Module["_crypto_secretbox_xchacha20poly1305_keybytes"]=asm["_crypto_secretbox_xchacha20poly1305_keybytes"];var _crypto_secretbox_xsalsa20poly1305_keybytes=Module["_crypto_secretbox_xsalsa20poly1305_keybytes"]=asm["_crypto_secretbox_xsalsa20poly1305_keybytes"];var _crypto_pwhash_saltbytes=Module["_crypto_pwhash_saltbytes"]=asm["_crypto_pwhash_saltbytes"];var _crypto_secretbox_noncebytes=Module["_crypto_secretbox_noncebytes"]=asm["_crypto_secretbox_noncebytes"];var _crypto_secretbox_xsalsa20poly1305_macbytes=Module["_crypto_secretbox_xsalsa20poly1305_macbytes"]=asm["_crypto_secretbox_xsalsa20poly1305_macbytes"];var _crypto_pwhash_argon2i_opslimit_max=Module["_crypto_pwhash_argon2i_opslimit_max"]=asm["_crypto_pwhash_argon2i_opslimit_max"];var _crypto_auth_hmacsha512_bytes=Module["_crypto_auth_hmacsha512_bytes"]=asm["_crypto_auth_hmacsha512_bytes"];var _crypto_generichash_keybytes=Module["_crypto_generichash_keybytes"]=asm["_crypto_generichash_keybytes"];var _crypto_sign_publickeybytes=Module["_crypto_sign_publickeybytes"]=asm["_crypto_sign_publickeybytes"];var _crypto_pwhash_argon2i_memlimit_moderate=Module["_crypto_pwhash_argon2i_memlimit_moderate"]=asm["_crypto_pwhash_argon2i_memlimit_moderate"];var _crypto_generichash_blake2b=Module["_crypto_generichash_blake2b"]=asm["_crypto_generichash_blake2b"];var _crypto_core_hchacha20_keybytes=Module["_crypto_core_hchacha20_keybytes"]=asm["_crypto_core_hchacha20_keybytes"];var ___uremdi3=Module["___uremdi3"]=asm["___uremdi3"];var _crypto_pwhash_argon2i_opslimit_moderate=Module["_crypto_pwhash_argon2i_opslimit_moderate"]=asm["_crypto_pwhash_argon2i_opslimit_moderate"];var _randombytes_implementation_name=Module["_randombytes_implementation_name"]=asm["_randombytes_implementation_name"];var _crypto_stream_xchacha20_noncebytes=Module["_crypto_stream_xchacha20_noncebytes"]=asm["_crypto_stream_xchacha20_noncebytes"];var _crypto_sign_ed25519_verify_detached=Module["_crypto_sign_ed25519_verify_detached"]=asm["_crypto_sign_ed25519_verify_detached"];var _crypto_hash_sha512_statebytes=Module["_crypto_hash_sha512_statebytes"]=asm["_crypto_hash_sha512_statebytes"];var _crypto_secretbox_zerobytes=Module["_crypto_secretbox_zerobytes"]=asm["_crypto_secretbox_zerobytes"];var _crypto_verify_32_bytes=Module["_crypto_verify_32_bytes"]=asm["_crypto_verify_32_bytes"];var stackRestore=Module["stackRestore"]=asm["stackRestore"];var _crypto_kdf_keygen=Module["_crypto_kdf_keygen"]=asm["_crypto_kdf_keygen"];var _crypto_stream_xsalsa20_xor=Module["_crypto_stream_xsalsa20_xor"]=asm["_crypto_stream_xsalsa20_xor"];var _crypto_stream_chacha20_ietf_keygen=Module["_crypto_stream_chacha20_ietf_keygen"]=asm["_crypto_stream_chacha20_ietf_keygen"];var _crypto_stream_chacha20_keygen=Module["_crypto_stream_chacha20_keygen"]=asm["_crypto_stream_chacha20_keygen"];var _crypto_box_easy=Module["_crypto_box_easy"]=asm["_crypto_box_easy"];var _crypto_hash_sha256=Module["_crypto_hash_sha256"]=asm["_crypto_hash_sha256"];var _crypto_sign_ed25519_seedbytes=Module["_crypto_sign_ed25519_seedbytes"]=asm["_crypto_sign_ed25519_seedbytes"];var _crypto_pwhash_alg_argon2i13=Module["_crypto_pwhash_alg_argon2i13"]=asm["_crypto_pwhash_alg_argon2i13"];var _crypto_shorthash_siphash24_bytes=Module["_crypto_shorthash_siphash24_bytes"]=asm["_crypto_shorthash_siphash24_bytes"];var _crypto_pwhash_opslimit_min=Module["_crypto_pwhash_opslimit_min"]=asm["_crypto_pwhash_opslimit_min"];var _crypto_box_curve25519xsalsa20poly1305_publickeybytes=Module["_crypto_box_curve25519xsalsa20poly1305_publickeybytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_publickeybytes"];var _crypto_kdf_blake2b_bytes_max=Module["_crypto_kdf_blake2b_bytes_max"]=asm["_crypto_kdf_blake2b_bytes_max"];var _crypto_generichash_bytes_max=Module["_crypto_generichash_bytes_max"]=asm["_crypto_generichash_bytes_max"];var _crypto_stream_chacha20_ietf_noncebytes=Module["_crypto_stream_chacha20_ietf_noncebytes"]=asm["_crypto_stream_chacha20_ietf_noncebytes"];var _crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive=Module["_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive"]=asm["_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive"];var _crypto_box_curve25519xchacha20poly1305_open_easy=Module["_crypto_box_curve25519xchacha20poly1305_open_easy"]=asm["_crypto_box_curve25519xchacha20poly1305_open_easy"];var _crypto_box_beforenm=Module["_crypto_box_beforenm"]=asm["_crypto_box_beforenm"];var _crypto_box_curve25519xsalsa20poly1305_afternm=Module["_crypto_box_curve25519xsalsa20poly1305_afternm"]=asm["_crypto_box_curve25519xsalsa20poly1305_afternm"];var _crypto_sign_statebytes=Module["_crypto_sign_statebytes"]=asm["_crypto_sign_statebytes"];var _crypto_sign_open=Module["_crypto_sign_open"]=asm["_crypto_sign_open"];var _crypto_box_seed_keypair=Module["_crypto_box_seed_keypair"]=asm["_crypto_box_seed_keypair"];var _crypto_auth_hmacsha512_init=Module["_crypto_auth_hmacsha512_init"]=asm["_crypto_auth_hmacsha512_init"];var _crypto_sign_ed25519_sk_to_pk=Module["_crypto_sign_ed25519_sk_to_pk"]=asm["_crypto_sign_ed25519_sk_to_pk"];var _crypto_scalarmult_curve25519=Module["_crypto_scalarmult_curve25519"]=asm["_crypto_scalarmult_curve25519"];var _crypto_box_open_easy=Module["_crypto_box_open_easy"]=asm["_crypto_box_open_easy"];var _crypto_auth_hmacsha512=Module["_crypto_auth_hmacsha512"]=asm["_crypto_auth_hmacsha512"];var _crypto_stream_keygen=Module["_crypto_stream_keygen"]=asm["_crypto_stream_keygen"];var _crypto_stream_aes128ctr_keybytes=Module["_crypto_stream_aes128ctr_keybytes"]=asm["_crypto_stream_aes128ctr_keybytes"];var _crypto_auth_hmacsha512256_keybytes=Module["_crypto_auth_hmacsha512256_keybytes"]=asm["_crypto_auth_hmacsha512256_keybytes"];var _crypto_aead_chacha20poly1305_keybytes=Module["_crypto_aead_chacha20poly1305_keybytes"]=asm["_crypto_aead_chacha20poly1305_keybytes"];var _free=Module["_free"]=asm["_free"];var _crypto_kx_client_session_keys=Module["_crypto_kx_client_session_keys"]=asm["_crypto_kx_client_session_keys"];var _crypto_box_curve25519xchacha20poly1305_seedbytes=Module["_crypto_box_curve25519xchacha20poly1305_seedbytes"]=asm["_crypto_box_curve25519xchacha20poly1305_seedbytes"];var _crypto_onetimeauth_poly1305_keybytes=Module["_crypto_onetimeauth_poly1305_keybytes"]=asm["_crypto_onetimeauth_poly1305_keybytes"];var _crypto_sign_ed25519_secretkeybytes=Module["_crypto_sign_ed25519_secretkeybytes"]=asm["_crypto_sign_ed25519_secretkeybytes"];var _crypto_kdf_blake2b_contextbytes=Module["_crypto_kdf_blake2b_contextbytes"]=asm["_crypto_kdf_blake2b_contextbytes"];var _crypto_stream_salsa2012=Module["_crypto_stream_salsa2012"]=asm["_crypto_stream_salsa2012"];var _crypto_sign_seedbytes=Module["_crypto_sign_seedbytes"]=asm["_crypto_sign_seedbytes"];var _crypto_box_curve25519xchacha20poly1305_beforenmbytes=Module["_crypto_box_curve25519xchacha20poly1305_beforenmbytes"]=asm["_crypto_box_curve25519xchacha20poly1305_beforenmbytes"];var _randombytes_random=Module["_randombytes_random"]=asm["_randombytes_random"];var _crypto_sign_ed25519ph_update=Module["_crypto_sign_ed25519ph_update"]=asm["_crypto_sign_ed25519ph_update"];var _crypto_auth_hmacsha256_keygen=Module["_crypto_auth_hmacsha256_keygen"]=asm["_crypto_auth_hmacsha256_keygen"];var _crypto_auth_hmacsha256_statebytes=Module["_crypto_auth_hmacsha256_statebytes"]=asm["_crypto_auth_hmacsha256_statebytes"];var _randombytes_buf_deterministic=Module["_randombytes_buf_deterministic"]=asm["_randombytes_buf_deterministic"];var _crypto_aead_chacha20poly1305_encrypt_detached=Module["_crypto_aead_chacha20poly1305_encrypt_detached"]=asm["_crypto_aead_chacha20poly1305_encrypt_detached"];var _crypto_stream_xsalsa20_keygen=Module["_crypto_stream_xsalsa20_keygen"]=asm["_crypto_stream_xsalsa20_keygen"];var _crypto_hash_primitive=Module["_crypto_hash_primitive"]=asm["_crypto_hash_primitive"];var _crypto_sign_ed25519_pk_to_curve25519=Module["_crypto_sign_ed25519_pk_to_curve25519"]=asm["_crypto_sign_ed25519_pk_to_curve25519"];var _crypto_shorthash_siphash24=Module["_crypto_shorthash_siphash24"]=asm["_crypto_shorthash_siphash24"];var _crypto_box_curve25519xsalsa20poly1305_macbytes=Module["_crypto_box_curve25519xsalsa20poly1305_macbytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_macbytes"];var _crypto_sign_ed25519_bytes=Module["_crypto_sign_ed25519_bytes"]=asm["_crypto_sign_ed25519_bytes"];var _crypto_sign_ed25519=Module["_crypto_sign_ed25519"]=asm["_crypto_sign_ed25519"];var _crypto_core_salsa20_constbytes=Module["_crypto_core_salsa20_constbytes"]=asm["_crypto_core_salsa20_constbytes"];var _crypto_secretbox_primitive=Module["_crypto_secretbox_primitive"]=asm["_crypto_secretbox_primitive"];var _crypto_pwhash_argon2i_opslimit_interactive=Module["_crypto_pwhash_argon2i_opslimit_interactive"]=asm["_crypto_pwhash_argon2i_opslimit_interactive"];var _crypto_pwhash_argon2i_saltbytes=Module["_crypto_pwhash_argon2i_saltbytes"]=asm["_crypto_pwhash_argon2i_saltbytes"];var _crypto_box_curve25519xchacha20poly1305_open_detached_afternm=Module["_crypto_box_curve25519xchacha20poly1305_open_detached_afternm"]=asm["_crypto_box_curve25519xchacha20poly1305_open_detached_afternm"];var _crypto_box_curve25519xsalsa20poly1305_beforenmbytes=Module["_crypto_box_curve25519xsalsa20poly1305_beforenmbytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_beforenmbytes"];var _crypto_stream_xchacha20_keygen=Module["_crypto_stream_xchacha20_keygen"]=asm["_crypto_stream_xchacha20_keygen"];var _crypto_core_hchacha20_constbytes=Module["_crypto_core_hchacha20_constbytes"]=asm["_crypto_core_hchacha20_constbytes"];var _crypto_stream_xchacha20_xor=Module["_crypto_stream_xchacha20_xor"]=asm["_crypto_stream_xchacha20_xor"];var _randombytes_seedbytes=Module["_randombytes_seedbytes"]=asm["_randombytes_seedbytes"];var _crypto_sign_final_create=Module["_crypto_sign_final_create"]=asm["_crypto_sign_final_create"];var _crypto_kx_secretkeybytes=Module["_crypto_kx_secretkeybytes"]=asm["_crypto_kx_secretkeybytes"];var _crypto_box_detached=Module["_crypto_box_detached"]=asm["_crypto_box_detached"];var _randombytes_buf=Module["_randombytes_buf"]=asm["_randombytes_buf"];var _crypto_generichash_blake2b_saltbytes=Module["_crypto_generichash_blake2b_saltbytes"]=asm["_crypto_generichash_blake2b_saltbytes"];var _crypto_box_open_detached=Module["_crypto_box_open_detached"]=asm["_crypto_box_open_detached"];var _crypto_kx_seedbytes=Module["_crypto_kx_seedbytes"]=asm["_crypto_kx_seedbytes"];var _crypto_secretbox_xsalsa20poly1305_zerobytes=Module["_crypto_secretbox_xsalsa20poly1305_zerobytes"]=asm["_crypto_secretbox_xsalsa20poly1305_zerobytes"];var _crypto_box_curve25519xchacha20poly1305_open_detached=Module["_crypto_box_curve25519xchacha20poly1305_open_detached"]=asm["_crypto_box_curve25519xchacha20poly1305_open_detached"];var _crypto_generichash_blake2b_keybytes=Module["_crypto_generichash_blake2b_keybytes"]=asm["_crypto_generichash_blake2b_keybytes"];var _crypto_box_curve25519xchacha20poly1305_easy=Module["_crypto_box_curve25519xchacha20poly1305_easy"]=asm["_crypto_box_curve25519xchacha20poly1305_easy"];var _crypto_pwhash_argon2i_bytes_min=Module["_crypto_pwhash_argon2i_bytes_min"]=asm["_crypto_pwhash_argon2i_bytes_min"];var _crypto_pwhash_scryptsalsa208sha256_str=Module["_crypto_pwhash_scryptsalsa208sha256_str"]=asm["_crypto_pwhash_scryptsalsa208sha256_str"];var _crypto_hash=Module["_crypto_hash"]=asm["_crypto_hash"];var _i64Subtract=Module["_i64Subtract"]=asm["_i64Subtract"];var _crypto_box_seedbytes=Module["_crypto_box_seedbytes"]=asm["_crypto_box_seedbytes"];var _crypto_generichash_blake2b_bytes_min=Module["_crypto_generichash_blake2b_bytes_min"]=asm["_crypto_generichash_blake2b_bytes_min"];var _crypto_box_curve25519xsalsa20poly1305=Module["_crypto_box_curve25519xsalsa20poly1305"]=asm["_crypto_box_curve25519xsalsa20poly1305"];var _crypto_generichash_blake2b_statebytes=Module["_crypto_generichash_blake2b_statebytes"]=asm["_crypto_generichash_blake2b_statebytes"];var _crypto_sign_ed25519ph_final_create=Module["_crypto_sign_ed25519ph_final_create"]=asm["_crypto_sign_ed25519ph_final_create"];var _crypto_aead_chacha20poly1305_ietf_decrypt_detached=Module["_crypto_aead_chacha20poly1305_ietf_decrypt_detached"]=asm["_crypto_aead_chacha20poly1305_ietf_decrypt_detached"];var _crypto_generichash_final=Module["_crypto_generichash_final"]=asm["_crypto_generichash_final"];var _crypto_auth_hmacsha512_update=Module["_crypto_auth_hmacsha512_update"]=asm["_crypto_auth_hmacsha512_update"];var _crypto_auth_hmacsha256=Module["_crypto_auth_hmacsha256"]=asm["_crypto_auth_hmacsha256"];var _crypto_box_keypair=Module["_crypto_box_keypair"]=asm["_crypto_box_keypair"];var _crypto_hash_sha256_bytes=Module["_crypto_hash_sha256_bytes"]=asm["_crypto_hash_sha256_bytes"];var ___udivdi3=Module["___udivdi3"]=asm["___udivdi3"];var _crypto_pwhash_argon2i_passwd_max=Module["_crypto_pwhash_argon2i_passwd_max"]=asm["_crypto_pwhash_argon2i_passwd_max"];var _sodium_init=Module["_sodium_init"]=asm["_sodium_init"];var _crypto_secretbox_macbytes=Module["_crypto_secretbox_macbytes"]=asm["_crypto_secretbox_macbytes"];var _crypto_aead_xchacha20poly1305_ietf_npubbytes=Module["_crypto_aead_xchacha20poly1305_ietf_npubbytes"]=asm["_crypto_aead_xchacha20poly1305_ietf_npubbytes"];var _bitshift64Shl=Module["_bitshift64Shl"]=asm["_bitshift64Shl"];var _crypto_pwhash_argon2i_opslimit_min=Module["_crypto_pwhash_argon2i_opslimit_min"]=asm["_crypto_pwhash_argon2i_opslimit_min"];var setTempRet0=Module["setTempRet0"]=asm["setTempRet0"];var _crypto_sign_seed_keypair=Module["_crypto_sign_seed_keypair"]=asm["_crypto_sign_seed_keypair"];var _crypto_core_hchacha20_inputbytes=Module["_crypto_core_hchacha20_inputbytes"]=asm["_crypto_core_hchacha20_inputbytes"];var ___muldi3=Module["___muldi3"]=asm["___muldi3"];var _crypto_core_salsa2012_constbytes=Module["_crypto_core_salsa2012_constbytes"]=asm["_crypto_core_salsa2012_constbytes"];var _crypto_kx_seed_keypair=Module["_crypto_kx_seed_keypair"]=asm["_crypto_kx_seed_keypair"];var _crypto_box_curve25519xchacha20poly1305_detached_afternm=Module["_crypto_box_curve25519xchacha20poly1305_detached_afternm"]=asm["_crypto_box_curve25519xchacha20poly1305_detached_afternm"];var _crypto_aead_chacha20poly1305_nsecbytes=Module["_crypto_aead_chacha20poly1305_nsecbytes"]=asm["_crypto_aead_chacha20poly1305_nsecbytes"];var _sodium_library_minimal=Module["_sodium_library_minimal"]=asm["_sodium_library_minimal"];var _crypto_aead_xchacha20poly1305_ietf_nsecbytes=Module["_crypto_aead_xchacha20poly1305_ietf_nsecbytes"]=asm["_crypto_aead_xchacha20poly1305_ietf_nsecbytes"];var _crypto_pwhash_argon2i_strbytes=Module["_crypto_pwhash_argon2i_strbytes"]=asm["_crypto_pwhash_argon2i_strbytes"];var _crypto_pwhash_argon2i_memlimit_max=Module["_crypto_pwhash_argon2i_memlimit_max"]=asm["_crypto_pwhash_argon2i_memlimit_max"];var _crypto_generichash_blake2b_salt_personal=Module["_crypto_generichash_blake2b_salt_personal"]=asm["_crypto_generichash_blake2b_salt_personal"];var _crypto_stream_aes128ctr_beforenmbytes=Module["_crypto_stream_aes128ctr_beforenmbytes"]=asm["_crypto_stream_aes128ctr_beforenmbytes"];var _crypto_kdf_derive_from_key=Module["_crypto_kdf_derive_from_key"]=asm["_crypto_kdf_derive_from_key"];var _crypto_secretbox_xsalsa20poly1305_noncebytes=Module["_crypto_secretbox_xsalsa20poly1305_noncebytes"]=asm["_crypto_secretbox_xsalsa20poly1305_noncebytes"];var _crypto_pwhash_scryptsalsa208sha256_opslimit_interactive=Module["_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive"]=asm["_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive"];var _crypto_pwhash_argon2i_memlimit_interactive=Module["_crypto_pwhash_argon2i_memlimit_interactive"]=asm["_crypto_pwhash_argon2i_memlimit_interactive"];var _crypto_hash_sha256_final=Module["_crypto_hash_sha256_final"]=asm["_crypto_hash_sha256_final"];var _crypto_stream_keybytes=Module["_crypto_stream_keybytes"]=asm["_crypto_stream_keybytes"];var _crypto_pwhash_memlimit_min=Module["_crypto_pwhash_memlimit_min"]=asm["_crypto_pwhash_memlimit_min"];var _crypto_aead_chacha20poly1305_ietf_npubbytes=Module["_crypto_aead_chacha20poly1305_ietf_npubbytes"]=asm["_crypto_aead_chacha20poly1305_ietf_npubbytes"];var _crypto_stream_salsa208_noncebytes=Module["_crypto_stream_salsa208_noncebytes"]=asm["_crypto_stream_salsa208_noncebytes"];var _sodium_library_version_minor=Module["_sodium_library_version_minor"]=asm["_sodium_library_version_minor"];var _crypto_onetimeauth_bytes=Module["_crypto_onetimeauth_bytes"]=asm["_crypto_onetimeauth_bytes"];var _crypto_box_open=Module["_crypto_box_open"]=asm["_crypto_box_open"];var _crypto_secretbox_xchacha20poly1305_open_easy=Module["_crypto_secretbox_xchacha20poly1305_open_easy"]=asm["_crypto_secretbox_xchacha20poly1305_open_easy"];var _crypto_scalarmult_curve25519_base=Module["_crypto_scalarmult_curve25519_base"]=asm["_crypto_scalarmult_curve25519_base"];var _crypto_sign_ed25519_open=Module["_crypto_sign_ed25519_open"]=asm["_crypto_sign_ed25519_open"];var _crypto_stream_chacha20_ietf_keybytes=Module["_crypto_stream_chacha20_ietf_keybytes"]=asm["_crypto_stream_chacha20_ietf_keybytes"];var _crypto_box_noncebytes=Module["_crypto_box_noncebytes"]=asm["_crypto_box_noncebytes"];var _crypto_core_hchacha20_outputbytes=Module["_crypto_core_hchacha20_outputbytes"]=asm["_crypto_core_hchacha20_outputbytes"];var _crypto_stream_salsa2012_xor=Module["_crypto_stream_salsa2012_xor"]=asm["_crypto_stream_salsa2012_xor"];var _crypto_onetimeauth_keygen=Module["_crypto_onetimeauth_keygen"]=asm["_crypto_onetimeauth_keygen"];var _crypto_pwhash_strbytes=Module["_crypto_pwhash_strbytes"]=asm["_crypto_pwhash_strbytes"];var _crypto_auth_hmacsha512256_update=Module["_crypto_auth_hmacsha512256_update"]=asm["_crypto_auth_hmacsha512256_update"];var _crypto_core_salsa208_outputbytes=Module["_crypto_core_salsa208_outputbytes"]=asm["_crypto_core_salsa208_outputbytes"];var _crypto_onetimeauth_poly1305=Module["_crypto_onetimeauth_poly1305"]=asm["_crypto_onetimeauth_poly1305"];var _crypto_secretbox_xchacha20poly1305_macbytes=Module["_crypto_secretbox_xchacha20poly1305_macbytes"]=asm["_crypto_secretbox_xchacha20poly1305_macbytes"];var _crypto_kdf_bytes_min=Module["_crypto_kdf_bytes_min"]=asm["_crypto_kdf_bytes_min"];var _crypto_sign_ed25519_sk_to_seed=Module["_crypto_sign_ed25519_sk_to_seed"]=asm["_crypto_sign_ed25519_sk_to_seed"];var _crypto_pwhash_scryptsalsa208sha256_memlimit_interactive=Module["_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive"]=asm["_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive"];var _crypto_stream_xsalsa20=Module["_crypto_stream_xsalsa20"]=asm["_crypto_stream_xsalsa20"];var _crypto_box_open_easy_afternm=Module["_crypto_box_open_easy_afternm"]=asm["_crypto_box_open_easy_afternm"];var _crypto_box_curve25519xsalsa20poly1305_seedbytes=Module["_crypto_box_curve25519xsalsa20poly1305_seedbytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_seedbytes"];var _crypto_stream_salsa20_keybytes=Module["_crypto_stream_salsa20_keybytes"]=asm["_crypto_stream_salsa20_keybytes"];var _crypto_kdf_primitive=Module["_crypto_kdf_primitive"]=asm["_crypto_kdf_primitive"];var _crypto_sign_ed25519ph_final_verify=Module["_crypto_sign_ed25519ph_final_verify"]=asm["_crypto_sign_ed25519ph_final_verify"];var _crypto_sign_ed25519_publickeybytes=Module["_crypto_sign_ed25519_publickeybytes"]=asm["_crypto_sign_ed25519_publickeybytes"];var _crypto_stream_aes128ctr=Module["_crypto_stream_aes128ctr"]=asm["_crypto_stream_aes128ctr"];var _crypto_shorthash=Module["_crypto_shorthash"]=asm["_crypto_shorthash"];var _crypto_auth_keybytes=Module["_crypto_auth_keybytes"]=asm["_crypto_auth_keybytes"];var _crypto_box_curve25519xsalsa20poly1305_open_afternm=Module["_crypto_box_curve25519xsalsa20poly1305_open_afternm"]=asm["_crypto_box_curve25519xsalsa20poly1305_open_afternm"];var _crypto_aead_chacha20poly1305_npubbytes=Module["_crypto_aead_chacha20poly1305_npubbytes"]=asm["_crypto_aead_chacha20poly1305_npubbytes"];var _crypto_aead_xchacha20poly1305_ietf_abytes=Module["_crypto_aead_xchacha20poly1305_ietf_abytes"]=asm["_crypto_aead_xchacha20poly1305_ietf_abytes"];var _crypto_onetimeauth_poly1305_final=Module["_crypto_onetimeauth_poly1305_final"]=asm["_crypto_onetimeauth_poly1305_final"];var _crypto_onetimeauth_poly1305_bytes=Module["_crypto_onetimeauth_poly1305_bytes"]=asm["_crypto_onetimeauth_poly1305_bytes"];var _crypto_box_curve25519xsalsa20poly1305_seed_keypair=Module["_crypto_box_curve25519xsalsa20poly1305_seed_keypair"]=asm["_crypto_box_curve25519xsalsa20poly1305_seed_keypair"];var _crypto_box_primitive=Module["_crypto_box_primitive"]=asm["_crypto_box_primitive"];var _crypto_pwhash_str=Module["_crypto_pwhash_str"]=asm["_crypto_pwhash_str"];var _crypto_auth_hmacsha512_keybytes=Module["_crypto_auth_hmacsha512_keybytes"]=asm["_crypto_auth_hmacsha512_keybytes"];var _crypto_auth=Module["_crypto_auth"]=asm["_crypto_auth"];var _crypto_pwhash_scryptsalsa208sha256_bytes_min=Module["_crypto_pwhash_scryptsalsa208sha256_bytes_min"]=asm["_crypto_pwhash_scryptsalsa208sha256_bytes_min"];var _crypto_core_salsa20_keybytes=Module["_crypto_core_salsa20_keybytes"]=asm["_crypto_core_salsa20_keybytes"];var _crypto_box_afternm=Module["_crypto_box_afternm"]=asm["_crypto_box_afternm"];var _crypto_core_salsa208_constbytes=Module["_crypto_core_salsa208_constbytes"]=asm["_crypto_core_salsa208_constbytes"];var _crypto_onetimeauth_primitive=Module["_crypto_onetimeauth_primitive"]=asm["_crypto_onetimeauth_primitive"];var _crypto_pwhash_scryptsalsa208sha256_str_verify=Module["_crypto_pwhash_scryptsalsa208sha256_str_verify"]=asm["_crypto_pwhash_scryptsalsa208sha256_str_verify"];var _sodium_version_string=Module["_sodium_version_string"]=asm["_sodium_version_string"];var _crypto_stream_xchacha20_xor_ic=Module["_crypto_stream_xchacha20_xor_ic"]=asm["_crypto_stream_xchacha20_xor_ic"];var _crypto_pwhash_scryptsalsa208sha256_passwd_min=Module["_crypto_pwhash_scryptsalsa208sha256_passwd_min"]=asm["_crypto_pwhash_scryptsalsa208sha256_passwd_min"];var _crypto_stream_chacha20_ietf=Module["_crypto_stream_chacha20_ietf"]=asm["_crypto_stream_chacha20_ietf"];var _crypto_generichash=Module["_crypto_generichash"]=asm["_crypto_generichash"];var _crypto_core_hsalsa20_outputbytes=Module["_crypto_core_hsalsa20_outputbytes"]=asm["_crypto_core_hsalsa20_outputbytes"];var _crypto_pwhash_opslimit_interactive=Module["_crypto_pwhash_opslimit_interactive"]=asm["_crypto_pwhash_opslimit_interactive"];var _crypto_stream_aes128ctr_beforenm=Module["_crypto_stream_aes128ctr_beforenm"]=asm["_crypto_stream_aes128ctr_beforenm"];var getTempRet0=Module["getTempRet0"]=asm["getTempRet0"];var _crypto_box_curve25519xsalsa20poly1305_noncebytes=Module["_crypto_box_curve25519xsalsa20poly1305_noncebytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_noncebytes"];var _crypto_stream_salsa2012_noncebytes=Module["_crypto_stream_salsa2012_noncebytes"]=asm["_crypto_stream_salsa2012_noncebytes"];var _crypto_core_salsa208_keybytes=Module["_crypto_core_salsa208_keybytes"]=asm["_crypto_core_salsa208_keybytes"];var _crypto_aead_chacha20poly1305_ietf_decrypt=Module["_crypto_aead_chacha20poly1305_ietf_decrypt"]=asm["_crypto_aead_chacha20poly1305_ietf_decrypt"];var _crypto_auth_hmacsha512256_init=Module["_crypto_auth_hmacsha512256_init"]=asm["_crypto_auth_hmacsha512256_init"];var _crypto_kx_server_session_keys=Module["_crypto_kx_server_session_keys"]=asm["_crypto_kx_server_session_keys"];var _crypto_onetimeauth_poly1305_verify=Module["_crypto_onetimeauth_poly1305_verify"]=asm["_crypto_onetimeauth_poly1305_verify"];var _crypto_auth_hmacsha512_final=Module["_crypto_auth_hmacsha512_final"]=asm["_crypto_auth_hmacsha512_final"];var _crypto_stream_aes128ctr_noncebytes=Module["_crypto_stream_aes128ctr_noncebytes"]=asm["_crypto_stream_aes128ctr_noncebytes"];var _crypto_box_secretkeybytes=Module["_crypto_box_secretkeybytes"]=asm["_crypto_box_secretkeybytes"];var _crypto_stream_salsa2012_keygen=Module["_crypto_stream_salsa2012_keygen"]=asm["_crypto_stream_salsa2012_keygen"];var _crypto_onetimeauth_update=Module["_crypto_onetimeauth_update"]=asm["_crypto_onetimeauth_update"];var _crypto_core_salsa20=Module["_crypto_core_salsa20"]=asm["_crypto_core_salsa20"];var _crypto_pwhash_memlimit_interactive=Module["_crypto_pwhash_memlimit_interactive"]=asm["_crypto_pwhash_memlimit_interactive"];var _crypto_scalarmult_bytes=Module["_crypto_scalarmult_bytes"]=asm["_crypto_scalarmult_bytes"];var _crypto_secretbox_detached=Module["_crypto_secretbox_detached"]=asm["_crypto_secretbox_detached"];var _crypto_stream_xor=Module["_crypto_stream_xor"]=asm["_crypto_stream_xor"];var _crypto_secretbox_xchacha20poly1305_easy=Module["_crypto_secretbox_xchacha20poly1305_easy"]=asm["_crypto_secretbox_xchacha20poly1305_easy"];var _crypto_secretbox_easy=Module["_crypto_secretbox_easy"]=asm["_crypto_secretbox_easy"];var _crypto_aead_xchacha20poly1305_ietf_decrypt_detached=Module["_crypto_aead_xchacha20poly1305_ietf_decrypt_detached"]=asm["_crypto_aead_xchacha20poly1305_ietf_decrypt_detached"];var _crypto_stream_salsa20=Module["_crypto_stream_salsa20"]=asm["_crypto_stream_salsa20"];var _sodium_bin2hex=Module["_sodium_bin2hex"]=asm["_sodium_bin2hex"];var _crypto_auth_hmacsha512_statebytes=Module["_crypto_auth_hmacsha512_statebytes"]=asm["_crypto_auth_hmacsha512_statebytes"];var _crypto_pwhash_argon2i_opslimit_sensitive=Module["_crypto_pwhash_argon2i_opslimit_sensitive"]=asm["_crypto_pwhash_argon2i_opslimit_sensitive"];var _crypto_generichash_blake2b_bytes_max=Module["_crypto_generichash_blake2b_bytes_max"]=asm["_crypto_generichash_blake2b_bytes_max"];var _crypto_hash_sha256_update=Module["_crypto_hash_sha256_update"]=asm["_crypto_hash_sha256_update"];var _crypto_core_hsalsa20_constbytes=Module["_crypto_core_hsalsa20_constbytes"]=asm["_crypto_core_hsalsa20_constbytes"];var _crypto_box_easy_afternm=Module["_crypto_box_easy_afternm"]=asm["_crypto_box_easy_afternm"];var _crypto_auth_hmacsha512256_verify=Module["_crypto_auth_hmacsha512256_verify"]=asm["_crypto_auth_hmacsha512256_verify"];var _crypto_pwhash_memlimit_moderate=Module["_crypto_pwhash_memlimit_moderate"]=asm["_crypto_pwhash_memlimit_moderate"];var _crypto_core_salsa20_inputbytes=Module["_crypto_core_salsa20_inputbytes"]=asm["_crypto_core_salsa20_inputbytes"];var _crypto_box_publickeybytes=Module["_crypto_box_publickeybytes"]=asm["_crypto_box_publickeybytes"];var _crypto_sign_secretkeybytes=Module["_crypto_sign_secretkeybytes"]=asm["_crypto_sign_secretkeybytes"];var ___muldsi3=Module["___muldsi3"]=asm["___muldsi3"];var _crypto_scalarmult_scalarbytes=Module["_crypto_scalarmult_scalarbytes"]=asm["_crypto_scalarmult_scalarbytes"];var _crypto_verify_32=Module["_crypto_verify_32"]=asm["_crypto_verify_32"];var _crypto_kx_sessionkeybytes=Module["_crypto_kx_sessionkeybytes"]=asm["_crypto_kx_sessionkeybytes"];var _crypto_aead_chacha20poly1305_decrypt=Module["_crypto_aead_chacha20poly1305_decrypt"]=asm["_crypto_aead_chacha20poly1305_decrypt"];var _crypto_sign=Module["_crypto_sign"]=asm["_crypto_sign"];var _crypto_pwhash_passwd_max=Module["_crypto_pwhash_passwd_max"]=asm["_crypto_pwhash_passwd_max"];var _crypto_pwhash_scryptsalsa208sha256_opslimit_min=Module["_crypto_pwhash_scryptsalsa208sha256_opslimit_min"]=asm["_crypto_pwhash_scryptsalsa208sha256_opslimit_min"];var _sodium_hex2bin=Module["_sodium_hex2bin"]=asm["_sodium_hex2bin"];var _crypto_pwhash_argon2i_alg_argon2i13=Module["_crypto_pwhash_argon2i_alg_argon2i13"]=asm["_crypto_pwhash_argon2i_alg_argon2i13"];var _crypto_secretbox_keybytes=Module["_crypto_secretbox_keybytes"]=asm["_crypto_secretbox_keybytes"];var _randombytes=Module["_randombytes"]=asm["_randombytes"];var _crypto_hash_bytes=Module["_crypto_hash_bytes"]=asm["_crypto_hash_bytes"];var _crypto_stream_salsa20_keygen=Module["_crypto_stream_salsa20_keygen"]=asm["_crypto_stream_salsa20_keygen"];var _crypto_hash_sha256_statebytes=Module["_crypto_hash_sha256_statebytes"]=asm["_crypto_hash_sha256_statebytes"];var _crypto_pwhash_argon2i_passwd_min=Module["_crypto_pwhash_argon2i_passwd_min"]=asm["_crypto_pwhash_argon2i_passwd_min"];var _crypto_pwhash_opslimit_sensitive=Module["_crypto_pwhash_opslimit_sensitive"]=asm["_crypto_pwhash_opslimit_sensitive"];var _crypto_sign_init=Module["_crypto_sign_init"]=asm["_crypto_sign_init"];var _crypto_generichash_blake2b_personalbytes=Module["_crypto_generichash_blake2b_personalbytes"]=asm["_crypto_generichash_blake2b_personalbytes"];var _crypto_stream_chacha20_xor_ic=Module["_crypto_stream_chacha20_xor_ic"]=asm["_crypto_stream_chacha20_xor_ic"];var _crypto_sign_verify_detached=Module["_crypto_sign_verify_detached"]=asm["_crypto_sign_verify_detached"];var _crypto_onetimeauth_verify=Module["_crypto_onetimeauth_verify"]=asm["_crypto_onetimeauth_verify"];var _crypto_sign_ed25519_detached=Module["_crypto_sign_ed25519_detached"]=asm["_crypto_sign_ed25519_detached"];var _crypto_generichash_init=Module["_crypto_generichash_init"]=asm["_crypto_generichash_init"];var _i64Add=Module["_i64Add"]=asm["_i64Add"];var _crypto_sign_bytes=Module["_crypto_sign_bytes"]=asm["_crypto_sign_bytes"];var _crypto_generichash_update=Module["_crypto_generichash_update"]=asm["_crypto_generichash_update"];var _crypto_scalarmult=Module["_crypto_scalarmult"]=asm["_crypto_scalarmult"];var _crypto_aead_chacha20poly1305_ietf_abytes=Module["_crypto_aead_chacha20poly1305_ietf_abytes"]=asm["_crypto_aead_chacha20poly1305_ietf_abytes"];var _crypto_sign_detached=Module["_crypto_sign_detached"]=asm["_crypto_sign_detached"];var _crypto_generichash_blake2b_update=Module["_crypto_generichash_blake2b_update"]=asm["_crypto_generichash_blake2b_update"];var _crypto_box_curve25519xsalsa20poly1305_beforenm=Module["_crypto_box_curve25519xsalsa20poly1305_beforenm"]=asm["_crypto_box_curve25519xsalsa20poly1305_beforenm"];var _crypto_generichash_blake2b_bytes=Module["_crypto_generichash_blake2b_bytes"]=asm["_crypto_generichash_blake2b_bytes"];var _crypto_auth_hmacsha512256_bytes=Module["_crypto_auth_hmacsha512256_bytes"]=asm["_crypto_auth_hmacsha512256_bytes"];var _crypto_box_curve25519xchacha20poly1305_noncebytes=Module["_crypto_box_curve25519xchacha20poly1305_noncebytes"]=asm["_crypto_box_curve25519xchacha20poly1305_noncebytes"];var _randombytes_uniform=Module["_randombytes_uniform"]=asm["_randombytes_uniform"];var _crypto_shorthash_siphash24_keybytes=Module["_crypto_shorthash_siphash24_keybytes"]=asm["_crypto_shorthash_siphash24_keybytes"];var _crypto_shorthash_keygen=Module["_crypto_shorthash_keygen"]=asm["_crypto_shorthash_keygen"];var _crypto_onetimeauth_init=Module["_crypto_onetimeauth_init"]=asm["_crypto_onetimeauth_init"];var _crypto_generichash_bytes=Module["_crypto_generichash_bytes"]=asm["_crypto_generichash_bytes"];var _crypto_stream_salsa20_xor=Module["_crypto_stream_salsa20_xor"]=asm["_crypto_stream_salsa20_xor"];var _crypto_auth_hmacsha512_verify=Module["_crypto_auth_hmacsha512_verify"]=asm["_crypto_auth_hmacsha512_verify"];var _crypto_generichash_blake2b_keybytes_min=Module["_crypto_generichash_blake2b_keybytes_min"]=asm["_crypto_generichash_blake2b_keybytes_min"];var _bitshift64Lshr=Module["_bitshift64Lshr"]=asm["_bitshift64Lshr"];var _crypto_kx_publickeybytes=Module["_crypto_kx_publickeybytes"]=asm["_crypto_kx_publickeybytes"];var _crypto_pwhash_bytes_max=Module["_crypto_pwhash_bytes_max"]=asm["_crypto_pwhash_bytes_max"];var _crypto_aead_chacha20poly1305_ietf_keybytes=Module["_crypto_aead_chacha20poly1305_ietf_keybytes"]=asm["_crypto_aead_chacha20poly1305_ietf_keybytes"];var _crypto_aead_chacha20poly1305_ietf_encrypt_detached=Module["_crypto_aead_chacha20poly1305_ietf_encrypt_detached"]=asm["_crypto_aead_chacha20poly1305_ietf_encrypt_detached"];var _crypto_stream=Module["_crypto_stream"]=asm["_crypto_stream"];var _sbrk=Module["_sbrk"]=asm["_sbrk"];var _crypto_box_curve25519xchacha20poly1305_beforenm=Module["_crypto_box_curve25519xchacha20poly1305_beforenm"]=asm["_crypto_box_curve25519xchacha20poly1305_beforenm"];var _memcpy=Module["_memcpy"]=asm["_memcpy"];var _crypto_pwhash=Module["_crypto_pwhash"]=asm["_crypto_pwhash"];var _crypto_auth_hmacsha512256=Module["_crypto_auth_hmacsha512256"]=asm["_crypto_auth_hmacsha512256"];var _crypto_secretbox_xsalsa20poly1305=Module["_crypto_secretbox_xsalsa20poly1305"]=asm["_crypto_secretbox_xsalsa20poly1305"];var _crypto_verify_16_bytes=Module["_crypto_verify_16_bytes"]=asm["_crypto_verify_16_bytes"];var _crypto_stream_salsa208_keygen=Module["_crypto_stream_salsa208_keygen"]=asm["_crypto_stream_salsa208_keygen"];var _emscripten_get_global_libc=Module["_emscripten_get_global_libc"]=asm["_emscripten_get_global_libc"];var _crypto_shorthash_siphashx24_bytes=Module["_crypto_shorthash_siphashx24_bytes"]=asm["_crypto_shorthash_siphashx24_bytes"];var _crypto_generichash_blake2b_final=Module["_crypto_generichash_blake2b_final"]=asm["_crypto_generichash_blake2b_final"];var _crypto_generichash_blake2b_init_salt_personal=Module["_crypto_generichash_blake2b_init_salt_personal"]=asm["_crypto_generichash_blake2b_init_salt_personal"];var _crypto_box_seal=Module["_crypto_box_seal"]=asm["_crypto_box_seal"];var _crypto_aead_xchacha20poly1305_ietf_keygen=Module["_crypto_aead_xchacha20poly1305_ietf_keygen"]=asm["_crypto_aead_xchacha20poly1305_ietf_keygen"];var _crypto_kx_keypair=Module["_crypto_kx_keypair"]=asm["_crypto_kx_keypair"];var runPostSets=Module["runPostSets"]=asm["runPostSets"];var _crypto_pwhash_alg_default=Module["_crypto_pwhash_alg_default"]=asm["_crypto_pwhash_alg_default"];var _crypto_box=Module["_crypto_box"]=asm["_crypto_box"];var _crypto_stream_primitive=Module["_crypto_stream_primitive"]=asm["_crypto_stream_primitive"];var _crypto_secretbox_xsalsa20poly1305_boxzerobytes=Module["_crypto_secretbox_xsalsa20poly1305_boxzerobytes"]=asm["_crypto_secretbox_xsalsa20poly1305_boxzerobytes"];var _crypto_pwhash_str_verify=Module["_crypto_pwhash_str_verify"]=asm["_crypto_pwhash_str_verify"];var _crypto_generichash_keybytes_min=Module["_crypto_generichash_keybytes_min"]=asm["_crypto_generichash_keybytes_min"];var _crypto_generichash_statebytes=Module["_crypto_generichash_statebytes"]=asm["_crypto_generichash_statebytes"];var _crypto_onetimeauth_poly1305_statebytes=Module["_crypto_onetimeauth_poly1305_statebytes"]=asm["_crypto_onetimeauth_poly1305_statebytes"];var _crypto_sign_final_verify=Module["_crypto_sign_final_verify"]=asm["_crypto_sign_final_verify"];var _crypto_pwhash_strprefix=Module["_crypto_pwhash_strprefix"]=asm["_crypto_pwhash_strprefix"];var _crypto_secretbox_keygen=Module["_crypto_secretbox_keygen"]=asm["_crypto_secretbox_keygen"];var _crypto_secretbox_xchacha20poly1305_noncebytes=Module["_crypto_secretbox_xchacha20poly1305_noncebytes"]=asm["_crypto_secretbox_xchacha20poly1305_noncebytes"];var _crypto_hash_sha512=Module["_crypto_hash_sha512"]=asm["_crypto_hash_sha512"];var _llvm_cttz_i32=Module["_llvm_cttz_i32"]=asm["_llvm_cttz_i32"];var _crypto_pwhash_scryptsalsa208sha256_bytes_max=Module["_crypto_pwhash_scryptsalsa208sha256_bytes_max"]=asm["_crypto_pwhash_scryptsalsa208sha256_bytes_max"];var _crypto_box_curve25519xchacha20poly1305_detached=Module["_crypto_box_curve25519xchacha20poly1305_detached"]=asm["_crypto_box_curve25519xchacha20poly1305_detached"];var _sodium_library_version_major=Module["_sodium_library_version_major"]=asm["_sodium_library_version_major"];var _crypto_aead_chacha20poly1305_ietf_encrypt=Module["_crypto_aead_chacha20poly1305_ietf_encrypt"]=asm["_crypto_aead_chacha20poly1305_ietf_encrypt"];var _crypto_generichash_blake2b_init=Module["_crypto_generichash_blake2b_init"]=asm["_crypto_generichash_blake2b_init"];var _randombytes_close=Module["_randombytes_close"]=asm["_randombytes_close"];var _crypto_pwhash_primitive=Module["_crypto_pwhash_primitive"]=asm["_crypto_pwhash_primitive"];var _crypto_onetimeauth_keybytes=Module["_crypto_onetimeauth_keybytes"]=asm["_crypto_onetimeauth_keybytes"];var _crypto_pwhash_argon2i=Module["_crypto_pwhash_argon2i"]=asm["_crypto_pwhash_argon2i"];var _crypto_stream_aes128ctr_afternm=Module["_crypto_stream_aes128ctr_afternm"]=asm["_crypto_stream_aes128ctr_afternm"];var _crypto_kdf_keybytes=Module["_crypto_kdf_keybytes"]=asm["_crypto_kdf_keybytes"];var establishStackSpace=Module["establishStackSpace"]=asm["establishStackSpace"];var _crypto_aead_chacha20poly1305_encrypt=Module["_crypto_aead_chacha20poly1305_encrypt"]=asm["_crypto_aead_chacha20poly1305_encrypt"];var _crypto_core_salsa2012_inputbytes=Module["_crypto_core_salsa2012_inputbytes"]=asm["_crypto_core_salsa2012_inputbytes"];var _crypto_pwhash_scryptsalsa208sha256_memlimit_min=Module["_crypto_pwhash_scryptsalsa208sha256_memlimit_min"]=asm["_crypto_pwhash_scryptsalsa208sha256_memlimit_min"];var _crypto_core_salsa208=Module["_crypto_core_salsa208"]=asm["_crypto_core_salsa208"];var _crypto_pwhash_opslimit_max=Module["_crypto_pwhash_opslimit_max"]=asm["_crypto_pwhash_opslimit_max"];var _crypto_auth_verify=Module["_crypto_auth_verify"]=asm["_crypto_auth_verify"];var _crypto_sign_ed25519_seed_keypair=Module["_crypto_sign_ed25519_seed_keypair"]=asm["_crypto_sign_ed25519_seed_keypair"];var _crypto_auth_hmacsha512256_keygen=Module["_crypto_auth_hmacsha512256_keygen"]=asm["_crypto_auth_hmacsha512256_keygen"];var _randombytes_stir=Module["_randombytes_stir"]=asm["_randombytes_stir"];var _memset=Module["_memset"]=asm["_memset"];var _crypto_box_open_detached_afternm=Module["_crypto_box_open_detached_afternm"]=asm["_crypto_box_open_detached_afternm"];var _crypto_pwhash_argon2i_memlimit_sensitive=Module["_crypto_pwhash_argon2i_memlimit_sensitive"]=asm["_crypto_pwhash_argon2i_memlimit_sensitive"];var _crypto_kx_primitive=Module["_crypto_kx_primitive"]=asm["_crypto_kx_primitive"];var _crypto_stream_salsa2012_keybytes=Module["_crypto_stream_salsa2012_keybytes"]=asm["_crypto_stream_salsa2012_keybytes"];var _crypto_aead_xchacha20poly1305_ietf_decrypt=Module["_crypto_aead_xchacha20poly1305_ietf_decrypt"]=asm["_crypto_aead_xchacha20poly1305_ietf_decrypt"];var _crypto_pwhash_scryptsalsa208sha256_strprefix=Module["_crypto_pwhash_scryptsalsa208sha256_strprefix"]=asm["_crypto_pwhash_scryptsalsa208sha256_strprefix"];var _crypto_core_salsa20_outputbytes=Module["_crypto_core_salsa20_outputbytes"]=asm["_crypto_core_salsa20_outputbytes"];var _crypto_auth_keygen=Module["_crypto_auth_keygen"]=asm["_crypto_auth_keygen"];var _crypto_secretbox=Module["_crypto_secretbox"]=asm["_crypto_secretbox"];var _crypto_aead_xchacha20poly1305_ietf_encrypt_detached=Module["_crypto_aead_xchacha20poly1305_ietf_encrypt_detached"]=asm["_crypto_aead_xchacha20poly1305_ietf_encrypt_detached"];var _crypto_pwhash_scryptsalsa208sha256_passwd_max=Module["_crypto_pwhash_scryptsalsa208sha256_passwd_max"]=asm["_crypto_pwhash_scryptsalsa208sha256_passwd_max"];var _crypto_auth_hmacsha256_bytes=Module["_crypto_auth_hmacsha256_bytes"]=asm["_crypto_auth_hmacsha256_bytes"];var _crypto_auth_hmacsha256_verify=Module["_crypto_auth_hmacsha256_verify"]=asm["_crypto_auth_hmacsha256_verify"];var _crypto_sign_keypair=Module["_crypto_sign_keypair"]=asm["_crypto_sign_keypair"];var _crypto_stream_xchacha20=Module["_crypto_stream_xchacha20"]=asm["_crypto_stream_xchacha20"];var _crypto_onetimeauth_statebytes=Module["_crypto_onetimeauth_statebytes"]=asm["_crypto_onetimeauth_statebytes"];var _crypto_sign_ed25519ph_init=Module["_crypto_sign_ed25519ph_init"]=asm["_crypto_sign_ed25519ph_init"];var _crypto_stream_salsa20_noncebytes=Module["_crypto_stream_salsa20_noncebytes"]=asm["_crypto_stream_salsa20_noncebytes"];var _crypto_shorthash_keybytes=Module["_crypto_shorthash_keybytes"]=asm["_crypto_shorthash_keybytes"];var _crypto_aead_chacha20poly1305_keygen=Module["_crypto_aead_chacha20poly1305_keygen"]=asm["_crypto_aead_chacha20poly1305_keygen"];var _crypto_shorthash_siphashx24=Module["_crypto_shorthash_siphashx24"]=asm["_crypto_shorthash_siphashx24"];var _memmove=Module["_memmove"]=asm["_memmove"];var _crypto_hash_sha512_final=Module["_crypto_hash_sha512_final"]=asm["_crypto_hash_sha512_final"];var _crypto_box_curve25519xsalsa20poly1305_zerobytes=Module["_crypto_box_curve25519xsalsa20poly1305_zerobytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_zerobytes"];var _crypto_shorthash_siphashx24_keybytes=Module["_crypto_shorthash_siphashx24_keybytes"]=asm["_crypto_shorthash_siphashx24_keybytes"];var _crypto_pwhash_passwd_min=Module["_crypto_pwhash_passwd_min"]=asm["_crypto_pwhash_passwd_min"];var _crypto_kdf_bytes_max=Module["_crypto_kdf_bytes_max"]=asm["_crypto_kdf_bytes_max"];var _crypto_box_curve25519xsalsa20poly1305_boxzerobytes=Module["_crypto_box_curve25519xsalsa20poly1305_boxzerobytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_boxzerobytes"];var _crypto_generichash_bytes_min=Module["_crypto_generichash_bytes_min"]=asm["_crypto_generichash_bytes_min"];var _crypto_core_salsa2012_outputbytes=Module["_crypto_core_salsa2012_outputbytes"]=asm["_crypto_core_salsa2012_outputbytes"];var _crypto_auth_hmacsha256_keybytes=Module["_crypto_auth_hmacsha256_keybytes"]=asm["_crypto_auth_hmacsha256_keybytes"];var _crypto_core_salsa208_inputbytes=Module["_crypto_core_salsa208_inputbytes"]=asm["_crypto_core_salsa208_inputbytes"];var _crypto_pwhash_scryptsalsa208sha256_opslimit_max=Module["_crypto_pwhash_scryptsalsa208sha256_opslimit_max"]=asm["_crypto_pwhash_scryptsalsa208sha256_opslimit_max"];var _crypto_sign_update=Module["_crypto_sign_update"]=asm["_crypto_sign_update"];var _crypto_secretbox_xchacha20poly1305_detached=Module["_crypto_secretbox_xchacha20poly1305_detached"]=asm["_crypto_secretbox_xchacha20poly1305_detached"];var _crypto_stream_chacha20_noncebytes=Module["_crypto_stream_chacha20_noncebytes"]=asm["_crypto_stream_chacha20_noncebytes"];var _crypto_secretbox_open_detached=Module["_crypto_secretbox_open_detached"]=asm["_crypto_secretbox_open_detached"];var _crypto_box_curve25519xchacha20poly1305_seed_keypair=Module["_crypto_box_curve25519xchacha20poly1305_seed_keypair"]=asm["_crypto_box_curve25519xchacha20poly1305_seed_keypair"];var _crypto_pwhash_argon2i_memlimit_min=Module["_crypto_pwhash_argon2i_memlimit_min"]=asm["_crypto_pwhash_argon2i_memlimit_min"];var _crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive=Module["_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive"]=asm["_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive"];var _crypto_box_curve25519xsalsa20poly1305_secretkeybytes=Module["_crypto_box_curve25519xsalsa20poly1305_secretkeybytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_secretkeybytes"];var _crypto_kdf_contextbytes=Module["_crypto_kdf_contextbytes"]=asm["_crypto_kdf_contextbytes"];var _crypto_stream_xchacha20_keybytes=Module["_crypto_stream_xchacha20_keybytes"]=asm["_crypto_stream_xchacha20_keybytes"];var _crypto_box_seal_open=Module["_crypto_box_seal_open"]=asm["_crypto_box_seal_open"];var _crypto_shorthash_primitive=Module["_crypto_shorthash_primitive"]=asm["_crypto_shorthash_primitive"];var _crypto_core_hsalsa20_inputbytes=Module["_crypto_core_hsalsa20_inputbytes"]=asm["_crypto_core_hsalsa20_inputbytes"];var _crypto_onetimeauth_final=Module["_crypto_onetimeauth_final"]=asm["_crypto_onetimeauth_final"];var _crypto_secretbox_open_easy=Module["_crypto_secretbox_open_easy"]=asm["_crypto_secretbox_open_easy"];var _crypto_core_salsa2012=Module["_crypto_core_salsa2012"]=asm["_crypto_core_salsa2012"];var _crypto_box_curve25519xchacha20poly1305_macbytes=Module["_crypto_box_curve25519xchacha20poly1305_macbytes"]=asm["_crypto_box_curve25519xchacha20poly1305_macbytes"];var _crypto_auth_hmacsha512256_statebytes=Module["_crypto_auth_hmacsha512256_statebytes"]=asm["_crypto_auth_hmacsha512256_statebytes"];var _bitshift64Ashr=Module["_bitshift64Ashr"]=asm["_bitshift64Ashr"];var _crypto_box_curve25519xchacha20poly1305_publickeybytes=Module["_crypto_box_curve25519xchacha20poly1305_publickeybytes"]=asm["_crypto_box_curve25519xchacha20poly1305_publickeybytes"];var _crypto_stream_chacha20_xor=Module["_crypto_stream_chacha20_xor"]=asm["_crypto_stream_chacha20_xor"];var _crypto_core_hsalsa20=Module["_crypto_core_hsalsa20"]=asm["_crypto_core_hsalsa20"];Runtime.stackAlloc=Module["stackAlloc"];Runtime.stackSave=Module["stackSave"];Runtime.stackRestore=Module["stackRestore"];Runtime.establishStackSpace=Module["establishStackSpace"];Runtime.setTempRet0=Module["setTempRet0"];Runtime.getTempRet0=Module["getTempRet0"];Module["asm"]=asm;function ExitStatus(status){this.name="ExitStatus";this.message="Program terminated with exit("+status+")";this.status=status}ExitStatus.prototype=new Error;ExitStatus.prototype.constructor=ExitStatus;var initialStackTop;var preloadStartTime=null;var calledMain=false;dependenciesFulfilled=function runCaller(){if(!Module["calledRun"])run();if(!Module["calledRun"])dependenciesFulfilled=runCaller};Module["callMain"]=Module.callMain=function callMain(args){args=args||[];ensureInitRuntime();var argc=args.length+1;function pad(){for(var i=0;i<4-1;i++){argv.push(0)}}var argv=[allocate(intArrayFromString(Module["thisProgram"]),"i8",ALLOC_NORMAL)];pad();for(var i=0;i<argc-1;i=i+1){argv.push(allocate(intArrayFromString(args[i]),"i8",ALLOC_NORMAL));pad()}argv.push(0);argv=allocate(argv,"i32",ALLOC_NORMAL);try{var ret=Module["_main"](argc,argv,0);exit(ret,true)}catch(e){if(e instanceof ExitStatus){return}else if(e=="SimulateInfiniteLoop"){Module["noExitRuntime"]=true;return}else{var toLog=e;if(e&&typeof e==="object"&&e.stack){toLog=[e,e.stack]}Module.printErr("exception thrown: "+toLog);Module["quit"](1,e)}}finally{calledMain=true}};function run(args){args=args||Module["arguments"];if(preloadStartTime===null)preloadStartTime=Date.now();if(runDependencies>0){return}preRun();if(runDependencies>0)return;if(Module["calledRun"])return;function doRun(){if(Module["calledRun"])return;Module["calledRun"]=true;if(ABORT)return;ensureInitRuntime();preMain();if(Module["onRuntimeInitialized"])Module["onRuntimeInitialized"]();if(Module["_main"]&&shouldRunNow)Module["callMain"](args);postRun()}if(Module["setStatus"]){Module["setStatus"]("Running...");setTimeout((function(){setTimeout((function(){Module["setStatus"]("")}),1);doRun()}),1)}else{doRun()}}Module["run"]=Module.run=run;function exit(status,implicit){if(implicit&&Module["noExitRuntime"]){return}if(Module["noExitRuntime"]){}else{ABORT=true;EXITSTATUS=status;STACKTOP=initialStackTop;exitRuntime();if(Module["onExit"])Module["onExit"](status)}if(ENVIRONMENT_IS_NODE){process["exit"](status)}Module["quit"](status,new ExitStatus(status))}Module["exit"]=Module.exit=exit;var abortDecorators=[];function abort(what){if(what!==undefined){Module.print(what);Module.printErr(what);what=JSON.stringify(what)}else{what=""}ABORT=true;EXITSTATUS=1;var extra="\nIf this abort() is unexpected, build with -s ASSERTIONS=1 which can give more information.";var output="abort("+what+") at "+stackTrace()+extra;if(abortDecorators){abortDecorators.forEach((function(decorator){output=decorator(output,what)}))}throw output}Module["abort"]=Module.abort=abort;if(Module["preInit"]){if(typeof Module["preInit"]=="function")Module["preInit"]=[Module["preInit"]];while(Module["preInit"].length>0){Module["preInit"].pop()()}}var shouldRunNow=true;if(Module["noInitialRun"]){shouldRunNow=false}run() + -/** - * Camelcases a hyphenated string, for example: - * - * > camelize('background-color') - * < "backgroundColor" - * - * @param {string} string - * @return {string} - */ -function camelize(string) { - return string.replace(_hyphenPattern, function (_, character) { - return character.toUpperCase(); - }); -} -module.exports = camelize; + + ENVIRONMENT_IS_NODE && !process.removeAllListeners("uncaughtException"); + return Module; +})); + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 164 */ -/***/ (function(module, exports, __webpack_require__) { +/* 417 */ +/***/ (function(module, exports) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/***/ }), +/* 418 */ +/***/ (function(module, exports, __webpack_require__) { -var CSSProperty = __webpack_require__(92); -var warning = __webpack_require__(2); +/* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// resolves . and .. elements in a path array with directory names there +// must be no slashes, empty elements, or device names (c:\) in the array +// (so also no leading and trailing slashes - it does not distinguish +// relative and absolute paths) +function normalizeArray(parts, allowAboveRoot) { + // if the path tries to go above the root, `up` ends up > 0 + var up = 0; + for (var i = parts.length - 1; i >= 0; i--) { + var last = parts[i]; + if (last === '.') { + parts.splice(i, 1); + } else if (last === '..') { + parts.splice(i, 1); + up++; + } else if (up) { + parts.splice(i, 1); + up--; + } + } + + // if the path is allowed to go above the root, restore leading ..s + if (allowAboveRoot) { + for (; up--; up) { + parts.unshift('..'); + } + } + + return parts; +} -var isUnitlessNumber = CSSProperty.isUnitlessNumber; -var styleWarnings = {}; +// Split a filename into [root, dir, basename, ext], unix version +// 'root' is just a slash, or nothing. +var splitPathRe = + /^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/; +var splitPath = function(filename) { + return splitPathRe.exec(filename).slice(1); +}; -/** - * Convert a value into the proper css writable value. The style name `name` - * should be logical (no hyphens), as specified - * in `CSSProperty.isUnitlessNumber`. - * - * @param {string} name CSS property name such as `topMargin`. - * @param {*} value CSS property value such as `10px`. - * @param {ReactDOMComponent} component - * @return {string} Normalized style value with dimensions applied. - */ -function dangerousStyleValue(name, value, component, isCustomProperty) { - // Note that we've removed escapeTextForBrowser() calls here since the - // whole string will be escaped when the attribute is injected into - // the markup. If you provide unsafe user data here they can inject - // arbitrary CSS which may be problematic (I couldn't repro this): - // https://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet - // http://www.thespanner.co.uk/2007/11/26/ultimate-xss-css-injection/ - // This is not an XSS hole but instead a potential CSS injection issue - // which has lead to a greater discussion about how we're going to - // trust URLs moving forward. See #2115901 +// path.resolve([from ...], to) +// posix version +exports.resolve = function() { + var resolvedPath = '', + resolvedAbsolute = false; - var isEmpty = value == null || typeof value === 'boolean' || value === ''; - if (isEmpty) { - return ''; - } + for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) { + var path = (i >= 0) ? arguments[i] : process.cwd(); - var isNonNumeric = isNaN(value); - if (isCustomProperty || isNonNumeric || value === 0 || isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name]) { - return '' + value; // cast to string + // Skip empty and invalid entries + if (typeof path !== 'string') { + throw new TypeError('Arguments to path.resolve must be strings'); + } else if (!path) { + continue; + } + + resolvedPath = path + '/' + resolvedPath; + resolvedAbsolute = path.charAt(0) === '/'; } - if (typeof value === 'string') { - if (process.env.NODE_ENV !== 'production') { - // Allow '0' to pass through without warning. 0 is already special and - // doesn't require units, so we don't need to warn about it. - if (component && value !== '0') { - var owner = component._currentElement._owner; - var ownerName = owner ? owner.getName() : null; - if (ownerName && !styleWarnings[ownerName]) { - styleWarnings[ownerName] = {}; - } - var warned = false; - if (ownerName) { - var warnings = styleWarnings[ownerName]; - warned = warnings[name]; - if (!warned) { - warnings[name] = true; - } - } - if (!warned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'a `%s` tag (owner: `%s`) was passed a numeric string value ' + 'for CSS property `%s` (value: `%s`) which will be treated ' + 'as a unitless number in a future version of React.', component._currentElement.type, ownerName || 'unknown', name, value) : void 0; - } - } - } - value = value.trim(); + // At this point the path should be resolved to a full absolute path, but + // handle relative paths to be safe (might happen when process.cwd() fails) + + // Normalize the path + resolvedPath = normalizeArray(filter(resolvedPath.split('/'), function(p) { + return !!p; + }), !resolvedAbsolute).join('/'); + + return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.'; +}; + +// path.normalize(path) +// posix version +exports.normalize = function(path) { + var isAbsolute = exports.isAbsolute(path), + trailingSlash = substr(path, -1) === '/'; + + // Normalize the path + path = normalizeArray(filter(path.split('/'), function(p) { + return !!p; + }), !isAbsolute).join('/'); + + if (!path && !isAbsolute) { + path = '.'; + } + if (path && trailingSlash) { + path += '/'; } - return value + 'px'; -} -module.exports = dangerousStyleValue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return (isAbsolute ? '/' : '') + path; +}; -/***/ }), -/* 165 */ -/***/ (function(module, exports, __webpack_require__) { +// posix version +exports.isAbsolute = function(path) { + return path.charAt(0) === '/'; +}; -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +// posix version +exports.join = function() { + var paths = Array.prototype.slice.call(arguments, 0); + return exports.normalize(filter(paths, function(p, index) { + if (typeof p !== 'string') { + throw new TypeError('Arguments to path.join must be strings'); + } + return p; + }).join('/')); +}; +// path.relative(from, to) +// posix version +exports.relative = function(from, to) { + from = exports.resolve(from).substr(1); + to = exports.resolve(to).substr(1); -var hyphenate = __webpack_require__(166); + function trim(arr) { + var start = 0; + for (; start < arr.length; start++) { + if (arr[start] !== '') break; + } -var msPattern = /^ms-/; + var end = arr.length - 1; + for (; end >= 0; end--) { + if (arr[end] !== '') break; + } -/** - * Hyphenates a camelcased CSS property name, for example: - * - * > hyphenateStyleName('backgroundColor') - * < "background-color" - * > hyphenateStyleName('MozTransition') - * < "-moz-transition" - * > hyphenateStyleName('msTransition') - * < "-ms-transition" - * - * As Modernizr suggests (http://modernizr.com/docs/#prefixed), an `ms` prefix - * is converted to `-ms-`. - * - * @param {string} string - * @return {string} - */ -function hyphenateStyleName(string) { - return hyphenate(string).replace(msPattern, '-ms-'); -} + if (start > end) return []; + return arr.slice(start, end - start + 1); + } -module.exports = hyphenateStyleName; + var fromParts = trim(from.split('/')); + var toParts = trim(to.split('/')); + + var length = Math.min(fromParts.length, toParts.length); + var samePartsLength = length; + for (var i = 0; i < length; i++) { + if (fromParts[i] !== toParts[i]) { + samePartsLength = i; + break; + } + } -/***/ }), -/* 166 */ -/***/ (function(module, exports, __webpack_require__) { + var outputParts = []; + for (var i = samePartsLength; i < fromParts.length; i++) { + outputParts.push('..'); + } -"use strict"; + outputParts = outputParts.concat(toParts.slice(samePartsLength)); + return outputParts.join('/'); +}; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +exports.sep = '/'; +exports.delimiter = ':'; -var _uppercasePattern = /([A-Z])/g; +exports.dirname = function(path) { + var result = splitPath(path), + root = result[0], + dir = result[1]; -/** - * Hyphenates a camelcased string, for example: - * - * > hyphenate('backgroundColor') - * < "background-color" - * - * For CSS style names, use `hyphenateStyleName` instead which works properly - * with all vendor prefixes, including `ms`. - * - * @param {string} string - * @return {string} - */ -function hyphenate(string) { - return string.replace(_uppercasePattern, '-$1').toLowerCase(); -} + if (!root && !dir) { + // No dirname whatsoever + return '.'; + } -module.exports = hyphenate; + if (dir) { + // It has a dirname, strip trailing slash + dir = dir.substr(0, dir.length - 1); + } -/***/ }), -/* 167 */ -/***/ (function(module, exports, __webpack_require__) { + return root + dir; +}; -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - * @typechecks static-only - */ +exports.basename = function(path, ext) { + var f = splitPath(path)[2]; + // TODO: make this comparison case-insensitive on windows? + if (ext && f.substr(-1 * ext.length) === ext) { + f = f.substr(0, f.length - ext.length); + } + return f; +}; -/** - * Memoizes the return value of a function that accepts one string argument. - */ +exports.extname = function(path) { + return splitPath(path)[3]; +}; -function memoizeStringOnly(callback) { - var cache = {}; - return function (string) { - if (!cache.hasOwnProperty(string)) { - cache[string] = callback.call(this, string); +function filter (xs, f) { + if (xs.filter) return xs.filter(f); + var res = []; + for (var i = 0; i < xs.length; i++) { + if (f(xs[i], i, xs)) res.push(xs[i]); } - return cache[string]; - }; + return res; } -module.exports = memoizeStringOnly; +// String.prototype.substr - negative index don't work in IE8 +var substr = 'ab'.substr(-1) === 'b' + ? function (str, start, len) { return str.substr(start, len) } + : function (str, start, len) { + if (start < 0) start = str.length + start; + return str.substr(start, len); + } +; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 168 */ +/* 419 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +exports.randomBytes = exports.rng = exports.pseudoRandomBytes = exports.prng = __webpack_require__(43) +exports.createHash = exports.Hash = __webpack_require__(27) +exports.createHmac = exports.Hmac = __webpack_require__(67) + +var algos = __webpack_require__(421) +var algoKeys = Object.keys(algos) +var hashes = ['sha1', 'sha224', 'sha256', 'sha384', 'sha512', 'md5', 'rmd160'].concat(algoKeys) +exports.getHashes = function () { + return hashes +} -var escapeTextContentForBrowser = __webpack_require__(44); +var p = __webpack_require__(177) +exports.pbkdf2 = p.pbkdf2 +exports.pbkdf2Sync = p.pbkdf2Sync + +var aes = __webpack_require__(423) + +exports.Cipher = aes.Cipher +exports.createCipher = aes.createCipher +exports.Cipheriv = aes.Cipheriv +exports.createCipheriv = aes.createCipheriv +exports.Decipher = aes.Decipher +exports.createDecipher = aes.createDecipher +exports.Decipheriv = aes.Decipheriv +exports.createDecipheriv = aes.createDecipheriv +exports.getCiphers = aes.getCiphers +exports.listCiphers = aes.listCiphers + +var dh = __webpack_require__(434) + +exports.DiffieHellmanGroup = dh.DiffieHellmanGroup +exports.createDiffieHellmanGroup = dh.createDiffieHellmanGroup +exports.getDiffieHellman = dh.getDiffieHellman +exports.createDiffieHellman = dh.createDiffieHellman +exports.DiffieHellman = dh.DiffieHellman + +var sign = __webpack_require__(437) + +exports.createSign = sign.createSign +exports.Sign = sign.Sign +exports.createVerify = sign.createVerify +exports.Verify = sign.Verify + +exports.createECDH = __webpack_require__(454) + +var publicEncrypt = __webpack_require__(455) + +exports.publicEncrypt = publicEncrypt.publicEncrypt +exports.privateEncrypt = publicEncrypt.privateEncrypt +exports.publicDecrypt = publicEncrypt.publicDecrypt +exports.privateDecrypt = publicEncrypt.privateDecrypt + +// the least I can do is make error messages for the rest of the node.js/crypto api. +// ;[ +// 'createCredentials' +// ].forEach(function (name) { +// exports[name] = function () { +// throw new Error([ +// 'sorry, ' + name + ' is not implemented yet', +// 'we accept pull requests', +// 'https://github.com/crypto-browserify/crypto-browserify' +// ].join('\n')) +// } +// }) + +exports.createCredentials = function () { + throw new Error([ + 'sorry, createCredentials is not implemented yet', + 'we accept pull requests', + 'https://github.com/crypto-browserify/crypto-browserify' + ].join('\n')) +} -/** - * Escapes attribute value to prevent scripting attacks. - * - * @param {*} value Value to escape. - * @return {string} An escaped string. - */ -function quoteAttributeValueForBrowser(value) { - return '"' + escapeTextContentForBrowser(value) + '"'; +exports.constants = { + 'DH_CHECK_P_NOT_SAFE_PRIME': 2, + 'DH_CHECK_P_NOT_PRIME': 1, + 'DH_UNABLE_TO_CHECK_GENERATOR': 4, + 'DH_NOT_SUITABLE_GENERATOR': 8, + 'NPN_ENABLED': 1, + 'ALPN_ENABLED': 1, + 'RSA_PKCS1_PADDING': 1, + 'RSA_SSLV23_PADDING': 2, + 'RSA_NO_PADDING': 3, + 'RSA_PKCS1_OAEP_PADDING': 4, + 'RSA_X931_PADDING': 5, + 'RSA_PKCS1_PSS_PADDING': 6, + 'POINT_CONVERSION_COMPRESSED': 2, + 'POINT_CONVERSION_UNCOMPRESSED': 4, + 'POINT_CONVERSION_HYBRID': 6 } -module.exports = quoteAttributeValueForBrowser; /***/ }), -/* 169 */ +/* 420 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var inherits = __webpack_require__(4) +var Buffer = __webpack_require__(7).Buffer +var Base = __webpack_require__(29) -var EventPluginHub = __webpack_require__(32); +var ZEROS = Buffer.alloc(128) +var blocksize = 64 -function runEventQueueInBatch(events) { - EventPluginHub.enqueueEvents(events); - EventPluginHub.processEventQueue(false); -} +function Hmac (alg, key) { + Base.call(this, 'digest') + if (typeof key === 'string') { + key = Buffer.from(key) + } -var ReactEventEmitterMixin = { - /** - * Streams a fired top-level event to `EventPluginHub` where plugins have the - * opportunity to create `ReactEvent`s to be dispatched. - */ - handleTopLevel: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var events = EventPluginHub.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); - runEventQueueInBatch(events); + this._alg = alg + this._key = key + + if (key.length > blocksize) { + key = alg(key) + } else if (key.length < blocksize) { + key = Buffer.concat([key, ZEROS], blocksize) } -}; -module.exports = ReactEventEmitterMixin; + var ipad = this._ipad = Buffer.allocUnsafe(blocksize) + var opad = this._opad = Buffer.allocUnsafe(blocksize) + + for (var i = 0; i < blocksize; i++) { + ipad[i] = key[i] ^ 0x36 + opad[i] = key[i] ^ 0x5C + } + + this._hash = [ipad] +} + +inherits(Hmac, Base) + +Hmac.prototype._update = function (data) { + this._hash.push(data) +} + +Hmac.prototype._final = function () { + var h = this._alg(Buffer.concat(this._hash)) + return this._alg(Buffer.concat([this._opad, h])) +} +module.exports = Hmac + /***/ }), -/* 170 */ +/* 421 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = __webpack_require__(176) +/***/ }), +/* 422 */ +/***/ (function(module, exports, __webpack_require__) { -var ExecutionEnvironment = __webpack_require__(8); +/* WEBPACK VAR INJECTION */(function(global, process) {var checkParameters = __webpack_require__(178) +var defaultEncoding = __webpack_require__(179) +var sync = __webpack_require__(180) +var Buffer = __webpack_require__(7).Buffer + +var ZERO_BUF +var subtle = global.crypto && global.crypto.subtle +var toBrowser = { + 'sha': 'SHA-1', + 'sha-1': 'SHA-1', + 'sha1': 'SHA-1', + 'sha256': 'SHA-256', + 'sha-256': 'SHA-256', + 'sha384': 'SHA-384', + 'sha-384': 'SHA-384', + 'sha-512': 'SHA-512', + 'sha512': 'SHA-512' +} +var checks = [] +function checkNative (algo) { + if (global.process && !global.process.browser) { + return Promise.resolve(false) + } + if (!subtle || !subtle.importKey || !subtle.deriveBits) { + return Promise.resolve(false) + } + if (checks[algo] !== undefined) { + return checks[algo] + } + ZERO_BUF = ZERO_BUF || Buffer.alloc(8) + var prom = browserPbkdf2(ZERO_BUF, ZERO_BUF, 10, 128, algo) + .then(function () { + return true + }).catch(function () { + return false + }) + checks[algo] = prom + return prom +} +function browserPbkdf2 (password, salt, iterations, length, algo) { + return subtle.importKey( + 'raw', password, {name: 'PBKDF2'}, false, ['deriveBits'] + ).then(function (key) { + return subtle.deriveBits({ + name: 'PBKDF2', + salt: salt, + iterations: iterations, + hash: { + name: algo + } + }, key, length << 3) + }).then(function (res) { + return Buffer.from(res) + }) +} +function resolvePromise (promise, callback) { + promise.then(function (out) { + process.nextTick(function () { + callback(null, out) + }) + }, function (e) { + process.nextTick(function () { + callback(e) + }) + }) +} +module.exports = function (password, salt, iterations, keylen, digest, callback) { + if (!Buffer.isBuffer(password)) password = Buffer.from(password, defaultEncoding) + if (!Buffer.isBuffer(salt)) salt = Buffer.from(salt, defaultEncoding) + + checkParameters(iterations, keylen) + if (typeof digest === 'function') { + callback = digest + digest = undefined + } + if (typeof callback !== 'function') throw new Error('No callback provided to pbkdf2') + + digest = digest || 'sha1' + var algo = toBrowser[digest.toLowerCase()] + if (!algo || typeof global.Promise !== 'function') { + return process.nextTick(function () { + var out + try { + out = sync(password, salt, iterations, keylen, digest) + } catch (e) { + return callback(e) + } + callback(null, out) + }) + } + resolvePromise(checkNative(algo).then(function (resp) { + if (resp) { + return browserPbkdf2(password, salt, iterations, keylen, algo) + } else { + return sync(password, salt, iterations, keylen, digest) + } + }), callback) +} -/** - * Generate a mapping of standard vendor prefixes using the defined style property and event name. - * - * @param {string} styleProp - * @param {string} eventName - * @returns {object} - */ -function makePrefixMap(styleProp, eventName) { - var prefixes = {}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) - prefixes[styleProp.toLowerCase()] = eventName.toLowerCase(); - prefixes['Webkit' + styleProp] = 'webkit' + eventName; - prefixes['Moz' + styleProp] = 'moz' + eventName; - prefixes['ms' + styleProp] = 'MS' + eventName; - prefixes['O' + styleProp] = 'o' + eventName.toLowerCase(); +/***/ }), +/* 423 */ +/***/ (function(module, exports, __webpack_require__) { - return prefixes; +var ebtk = __webpack_require__(68) +var aes = __webpack_require__(108) +var DES = __webpack_require__(427) +var desModes = __webpack_require__(433) +var aesModes = __webpack_require__(70) +function createCipher (suite, password) { + var keyLen, ivLen + suite = suite.toLowerCase() + if (aesModes[suite]) { + keyLen = aesModes[suite].key + ivLen = aesModes[suite].iv + } else if (desModes[suite]) { + keyLen = desModes[suite].key * 8 + ivLen = desModes[suite].iv + } else { + throw new TypeError('invalid suite type') + } + var keys = ebtk(password, false, keyLen, ivLen) + return createCipheriv(suite, keys.key, keys.iv) +} +function createDecipher (suite, password) { + var keyLen, ivLen + suite = suite.toLowerCase() + if (aesModes[suite]) { + keyLen = aesModes[suite].key + ivLen = aesModes[suite].iv + } else if (desModes[suite]) { + keyLen = desModes[suite].key * 8 + ivLen = desModes[suite].iv + } else { + throw new TypeError('invalid suite type') + } + var keys = ebtk(password, false, keyLen, ivLen) + return createDecipheriv(suite, keys.key, keys.iv) } -/** - * A list of event names to a configurable list of vendor prefixes. - */ -var vendorPrefixes = { - animationend: makePrefixMap('Animation', 'AnimationEnd'), - animationiteration: makePrefixMap('Animation', 'AnimationIteration'), - animationstart: makePrefixMap('Animation', 'AnimationStart'), - transitionend: makePrefixMap('Transition', 'TransitionEnd') -}; - -/** - * Event names that have already been detected and prefixed (if applicable). - */ -var prefixedEventNames = {}; +function createCipheriv (suite, key, iv) { + suite = suite.toLowerCase() + if (aesModes[suite]) { + return aes.createCipheriv(suite, key, iv) + } else if (desModes[suite]) { + return new DES({ + key: key, + iv: iv, + mode: suite + }) + } else { + throw new TypeError('invalid suite type') + } +} +function createDecipheriv (suite, key, iv) { + suite = suite.toLowerCase() + if (aesModes[suite]) { + return aes.createDecipheriv(suite, key, iv) + } else if (desModes[suite]) { + return new DES({ + key: key, + iv: iv, + mode: suite, + decrypt: true + }) + } else { + throw new TypeError('invalid suite type') + } +} +exports.createCipher = exports.Cipher = createCipher +exports.createCipheriv = exports.Cipheriv = createCipheriv +exports.createDecipher = exports.Decipher = createDecipher +exports.createDecipheriv = exports.Decipheriv = createDecipheriv +function getCiphers () { + return Object.keys(desModes).concat(aes.getCiphers()) +} +exports.listCiphers = exports.getCiphers = getCiphers -/** - * Element to check for prefixes on. - */ -var style = {}; -/** - * Bootstrap if a DOM exists. - */ -if (ExecutionEnvironment.canUseDOM) { - style = document.createElement('div').style; +/***/ }), +/* 424 */ +/***/ (function(module, exports, __webpack_require__) { - // On some platforms, in particular some releases of Android 4.x, - // the un-prefixed "animation" and "transition" properties are defined on the - // style object but the events that fire will still be prefixed, so we need - // to check if the un-prefixed events are usable, and if not remove them from the map. - if (!('AnimationEvent' in window)) { - delete vendorPrefixes.animationend.animation; - delete vendorPrefixes.animationiteration.animation; - delete vendorPrefixes.animationstart.animation; +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var modes = __webpack_require__(70) +var ebtk = __webpack_require__(68) +var StreamCipher = __webpack_require__(181) +var AuthCipher = __webpack_require__(182) +inherits(Cipher, Transform) +function Cipher (mode, key, iv) { + if (!(this instanceof Cipher)) { + return new Cipher(mode, key, iv) + } + Transform.call(this) + this._cache = new Splitter() + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + iv.copy(this._prev) + this._mode = mode + this._autopadding = true +} +Cipher.prototype._update = function (data) { + this._cache.add(data) + var chunk + var thing + var out = [] + while ((chunk = this._cache.get())) { + thing = this._mode.encrypt(this, chunk) + out.push(thing) + } + return Buffer.concat(out) +} +Cipher.prototype._final = function () { + var chunk = this._cache.flush() + if (this._autopadding) { + chunk = this._mode.encrypt(this, chunk) + this._cipher.scrub() + return chunk + } else if (chunk.toString('hex') !== '10101010101010101010101010101010') { + this._cipher.scrub() + throw new Error('data not multiple of block length') } +} +Cipher.prototype.setAutoPadding = function (setTo) { + this._autopadding = !!setTo + return this +} - // Same as above - if (!('TransitionEvent' in window)) { - delete vendorPrefixes.transitionend.transition; +function Splitter () { + if (!(this instanceof Splitter)) { + return new Splitter() } + this.cache = new Buffer('') +} +Splitter.prototype.add = function (data) { + this.cache = Buffer.concat([this.cache, data]) } -/** - * Attempts to determine the correct vendor prefixed event name. - * - * @param {string} eventName - * @returns {string} - */ -function getVendorPrefixedEventName(eventName) { - if (prefixedEventNames[eventName]) { - return prefixedEventNames[eventName]; - } else if (!vendorPrefixes[eventName]) { - return eventName; +Splitter.prototype.get = function () { + if (this.cache.length > 15) { + var out = this.cache.slice(0, 16) + this.cache = this.cache.slice(16) + return out } + return null +} +Splitter.prototype.flush = function () { + var len = 16 - this.cache.length + var padBuff = new Buffer(len) - var prefixMap = vendorPrefixes[eventName]; - - for (var styleProp in prefixMap) { - if (prefixMap.hasOwnProperty(styleProp) && styleProp in style) { - return prefixedEventNames[eventName] = prefixMap[styleProp]; - } + var i = -1 + while (++i < len) { + padBuff.writeUInt8(len, i) } + var out = Buffer.concat([this.cache, padBuff]) + return out +} +var modelist = { + ECB: __webpack_require__(183), + CBC: __webpack_require__(184), + CFB: __webpack_require__(185), + CFB8: __webpack_require__(186), + CFB1: __webpack_require__(187), + OFB: __webpack_require__(188), + CTR: __webpack_require__(71), + GCM: __webpack_require__(71) +} - return ''; +function createCipheriv (suite, password, iv) { + var config = modes[suite.toLowerCase()] + if (!config) { + throw new TypeError('invalid suite type') + } + if (typeof iv === 'string') { + iv = new Buffer(iv) + } + if (typeof password === 'string') { + password = new Buffer(password) + } + if (password.length !== config.key / 8) { + throw new TypeError('invalid key length ' + password.length) + } + if (iv.length !== config.iv) { + throw new TypeError('invalid iv length ' + iv.length) + } + if (config.type === 'stream') { + return new StreamCipher(modelist[config.mode], password, iv) + } else if (config.type === 'auth') { + return new AuthCipher(modelist[config.mode], password, iv) + } + return new Cipher(modelist[config.mode], password, iv) +} +function createCipher (suite, password) { + var config = modes[suite.toLowerCase()] + if (!config) { + throw new TypeError('invalid suite type') + } + var keys = ebtk(password, false, config.key, config.iv) + return createCipheriv(suite, keys.key, keys.iv) } -module.exports = getVendorPrefixedEventName; +exports.createCipheriv = createCipheriv +exports.createCipher = createCipher + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 171 */ +/* 425 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) {var zeros = new Buffer(16) +zeros.fill(0) +module.exports = GHASH +function GHASH (key) { + this.h = key + this.state = new Buffer(16) + this.state.fill(0) + this.cache = new Buffer('') +} +// from http://bitwiseshiftleft.github.io/sjcl/doc/symbols/src/core_gcm.js.html +// by Juho Vähä-Herttua +GHASH.prototype.ghash = function (block) { + var i = -1 + while (++i < block.length) { + this.state[i] ^= block[i] + } + this._multiply() +} +GHASH.prototype._multiply = function () { + var Vi = toArray(this.h) + var Zi = [0, 0, 0, 0] + var j, xi, lsb_Vi + var i = -1 + while (++i < 128) { + xi = (this.state[~~(i / 8)] & (1 << (7 - i % 8))) !== 0 + if (xi) { + // Z_i+1 = Z_i ^ V_i + Zi = xor(Zi, Vi) + } + // Store the value of LSB(V_i) + lsb_Vi = (Vi[3] & 1) !== 0 -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); + // V_i+1 = V_i >> 1 + for (j = 3; j > 0; j--) { + Vi[j] = (Vi[j] >>> 1) | ((Vi[j - 1] & 1) << 31) + } + Vi[0] = Vi[0] >>> 1 -var DOMPropertyOperations = __webpack_require__(93); -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); + // If LSB(V_i) is 1, V_i+1 = (V_i >> 1) ^ R + if (lsb_Vi) { + Vi[0] = Vi[0] ^ (0xe1 << 24) + } + } + this.state = fromArray(Zi) +} +GHASH.prototype.update = function (buf) { + this.cache = Buffer.concat([this.cache, buf]) + var chunk + while (this.cache.length >= 16) { + chunk = this.cache.slice(0, 16) + this.cache = this.cache.slice(16) + this.ghash(chunk) + } +} +GHASH.prototype.final = function (abl, bl) { + if (this.cache.length) { + this.ghash(Buffer.concat([this.cache, zeros], 16)) + } + this.ghash(fromArray([ + 0, abl, + 0, bl + ])) + return this.state +} -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +function toArray (buf) { + return [ + buf.readUInt32BE(0), + buf.readUInt32BE(4), + buf.readUInt32BE(8), + buf.readUInt32BE(12) + ] +} +function fromArray (out) { + out = out.map(fixup_uint32) + var buf = new Buffer(16) + buf.writeUInt32BE(out[0], 0) + buf.writeUInt32BE(out[1], 4) + buf.writeUInt32BE(out[2], 8) + buf.writeUInt32BE(out[3], 12) + return buf +} +var uint_max = Math.pow(2, 32) +function fixup_uint32 (x) { + var ret, x_pos + ret = x > uint_max || x < 0 ? (x_pos = Math.abs(x) % uint_max, x < 0 ? uint_max - x_pos : x_pos) : x + return ret +} +function xor (a, b) { + return [ + a[0] ^ b[0], + a[1] ^ b[1], + a[2] ^ b[2], + a[3] ^ b[3] + ] +} -var didWarnValueLink = false; -var didWarnCheckedLink = false; -var didWarnValueDefaultValue = false; -var didWarnCheckedDefaultChecked = false; -var didWarnControlledToUncontrolled = false; -var didWarnUncontrolledToControlled = false; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -function forceUpdateIfMounted() { - if (this._rootNodeID) { - // DOM component is still mounted; update - ReactDOMInput.updateWrapper(this); +/***/ }), +/* 426 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var modes = __webpack_require__(70) +var StreamCipher = __webpack_require__(181) +var AuthCipher = __webpack_require__(182) +var ebtk = __webpack_require__(68) + +inherits(Decipher, Transform) +function Decipher (mode, key, iv) { + if (!(this instanceof Decipher)) { + return new Decipher(mode, key, iv) + } + Transform.call(this) + this._cache = new Splitter() + this._last = void 0 + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + iv.copy(this._prev) + this._mode = mode + this._autopadding = true +} +Decipher.prototype._update = function (data) { + this._cache.add(data) + var chunk + var thing + var out = [] + while ((chunk = this._cache.get(this._autopadding))) { + thing = this._mode.decrypt(this, chunk) + out.push(thing) + } + return Buffer.concat(out) +} +Decipher.prototype._final = function () { + var chunk = this._cache.flush() + if (this._autopadding) { + return unpad(this._mode.decrypt(this, chunk)) + } else if (chunk) { + throw new Error('data not multiple of block length') } } +Decipher.prototype.setAutoPadding = function (setTo) { + this._autopadding = !!setTo + return this +} +function Splitter () { + if (!(this instanceof Splitter)) { + return new Splitter() + } + this.cache = new Buffer('') +} +Splitter.prototype.add = function (data) { + this.cache = Buffer.concat([this.cache, data]) +} -function isControlled(props) { - var usesChecked = props.type === 'checkbox' || props.type === 'radio'; - return usesChecked ? props.checked != null : props.value != null; +Splitter.prototype.get = function (autoPadding) { + var out + if (autoPadding) { + if (this.cache.length > 16) { + out = this.cache.slice(0, 16) + this.cache = this.cache.slice(16) + return out + } + } else { + if (this.cache.length >= 16) { + out = this.cache.slice(0, 16) + this.cache = this.cache.slice(16) + return out + } + } + return null +} +Splitter.prototype.flush = function () { + if (this.cache.length) { + return this.cache + } +} +function unpad (last) { + var padded = last[15] + var i = -1 + while (++i < padded) { + if (last[(i + (16 - padded))] !== padded) { + throw new Error('unable to decrypt data') + } + } + if (padded === 16) { + return + } + return last.slice(0, 16 - padded) } -/** - * Implements an <input> host component that allows setting these optional - * props: `checked`, `value`, `defaultChecked`, and `defaultValue`. - * - * If `checked` or `value` are not supplied (or null/undefined), user actions - * that affect the checked state or value will trigger updates to the element. - * - * If they are supplied (and not null/undefined), the rendered element will not - * trigger updates to the element. Instead, the props must change in order for - * the rendered element to be updated. - * - * The rendered element will be initialized as unchecked (or `defaultChecked`) - * with an empty value (or `defaultValue`). - * - * @see http://www.w3.org/TR/2012/WD-html5-20121025/the-input-element.html - */ -var ReactDOMInput = { - getHostProps: function (inst, props) { - var value = LinkedValueUtils.getValue(props); - var checked = LinkedValueUtils.getChecked(props); +var modelist = { + ECB: __webpack_require__(183), + CBC: __webpack_require__(184), + CFB: __webpack_require__(185), + CFB8: __webpack_require__(186), + CFB1: __webpack_require__(187), + OFB: __webpack_require__(188), + CTR: __webpack_require__(71), + GCM: __webpack_require__(71) +} - var hostProps = _assign({ - // Make sure we set .type before any other properties (setting .value - // before .type means .value is lost in IE11 and below) - type: undefined, - // Make sure we set .step before .value (setting .value before .step - // means .value is rounded on mount, based upon step precision) - step: undefined, - // Make sure we set .min & .max before .value (to ensure proper order - // in corner cases such as min or max deriving from value, e.g. Issue #7170) - min: undefined, - max: undefined - }, props, { - defaultChecked: undefined, - defaultValue: undefined, - value: value != null ? value : inst._wrapperState.initialValue, - checked: checked != null ? checked : inst._wrapperState.initialChecked, - onChange: inst._wrapperState.onChange - }); +function createDecipheriv (suite, password, iv) { + var config = modes[suite.toLowerCase()] + if (!config) { + throw new TypeError('invalid suite type') + } + if (typeof iv === 'string') { + iv = new Buffer(iv) + } + if (typeof password === 'string') { + password = new Buffer(password) + } + if (password.length !== config.key / 8) { + throw new TypeError('invalid key length ' + password.length) + } + if (iv.length !== config.iv) { + throw new TypeError('invalid iv length ' + iv.length) + } + if (config.type === 'stream') { + return new StreamCipher(modelist[config.mode], password, iv, true) + } else if (config.type === 'auth') { + return new AuthCipher(modelist[config.mode], password, iv, true) + } + return new Decipher(modelist[config.mode], password, iv) +} - return hostProps; - }, +function createDecipher (suite, password) { + var config = modes[suite.toLowerCase()] + if (!config) { + throw new TypeError('invalid suite type') + } + var keys = ebtk(password, false, config.key, config.iv) + return createDecipheriv(suite, keys.key, keys.iv) +} +exports.createDecipher = createDecipher +exports.createDecipheriv = createDecipheriv - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - LinkedValueUtils.checkPropTypes('input', props, inst._currentElement._owner); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - var owner = inst._currentElement._owner; +/***/ }), +/* 427 */ +/***/ (function(module, exports, __webpack_require__) { - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } - if (props.checkedLink !== undefined && !didWarnCheckedLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`checkedLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnCheckedLink = true; - } - if (props.checked !== undefined && props.defaultChecked !== undefined && !didWarnCheckedDefaultChecked) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both checked and defaultChecked props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnCheckedDefaultChecked = true; - } - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both value and defaultValue props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnValueDefaultValue = true; - } - } +/* WEBPACK VAR INJECTION */(function(Buffer) {var CipherBase = __webpack_require__(29) +var des = __webpack_require__(109) +var inherits = __webpack_require__(4) + +var modes = { + 'des-ede3-cbc': des.CBC.instantiate(des.EDE), + 'des-ede3': des.EDE, + 'des-ede-cbc': des.CBC.instantiate(des.EDE), + 'des-ede': des.EDE, + 'des-cbc': des.CBC.instantiate(des.DES), + 'des-ecb': des.DES +} +modes.des = modes['des-cbc'] +modes.des3 = modes['des-ede3-cbc'] +module.exports = DES +inherits(DES, CipherBase) +function DES (opts) { + CipherBase.call(this) + var modeName = opts.mode.toLowerCase() + var mode = modes[modeName] + var type + if (opts.decrypt) { + type = 'decrypt' + } else { + type = 'encrypt' + } + var key = opts.key + if (modeName === 'des-ede' || modeName === 'des-ede-cbc') { + key = Buffer.concat([key, key.slice(0, 8)]) + } + var iv = opts.iv + this._des = mode.create({ + key: key, + iv: iv, + type: type + }) +} +DES.prototype._update = function (data) { + return new Buffer(this._des.update(data)) +} +DES.prototype._final = function () { + return new Buffer(this._des.final()) +} - var defaultValue = props.defaultValue; - inst._wrapperState = { - initialChecked: props.checked != null ? props.checked : props.defaultChecked, - initialValue: props.value != null ? props.value : defaultValue, - listeners: null, - onChange: _handleChange.bind(inst), - controlled: isControlled(props) - }; - }, +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - updateWrapper: function (inst) { - var props = inst._currentElement.props; +/***/ }), +/* 428 */ +/***/ (function(module, exports, __webpack_require__) { - if (process.env.NODE_ENV !== 'production') { - var controlled = isControlled(props); - var owner = inst._currentElement._owner; +"use strict"; - if (!inst._wrapperState.controlled && controlled && !didWarnUncontrolledToControlled) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing an uncontrolled input of type %s to be controlled. ' + 'Input elements should not switch from uncontrolled to controlled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnUncontrolledToControlled = true; - } - if (inst._wrapperState.controlled && !controlled && !didWarnControlledToUncontrolled) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing a controlled input of type %s to be uncontrolled. ' + 'Input elements should not switch from controlled to uncontrolled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnControlledToUncontrolled = true; - } - } - // TODO: Shouldn't this be getChecked(props)? - var checked = props.checked; - if (checked != null) { - DOMPropertyOperations.setValueForProperty(ReactDOMComponentTree.getNodeFromInstance(inst), 'checked', checked || false); - } +exports.readUInt32BE = function readUInt32BE(bytes, off) { + var res = (bytes[0 + off] << 24) | + (bytes[1 + off] << 16) | + (bytes[2 + off] << 8) | + bytes[3 + off]; + return res >>> 0; +}; - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var value = LinkedValueUtils.getValue(props); - if (value != null) { - if (value === 0 && node.value === '') { - node.value = '0'; - // Note: IE9 reports a number inputs as 'text', so check props instead. - } else if (props.type === 'number') { - // Simulate `input.valueAsNumber`. IE9 does not support it - var valueAsNumber = parseFloat(node.value, 10) || 0; +exports.writeUInt32BE = function writeUInt32BE(bytes, value, off) { + bytes[0 + off] = value >>> 24; + bytes[1 + off] = (value >>> 16) & 0xff; + bytes[2 + off] = (value >>> 8) & 0xff; + bytes[3 + off] = value & 0xff; +}; - if ( - // eslint-disable-next-line - value != valueAsNumber || - // eslint-disable-next-line - value == valueAsNumber && node.value != value) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - node.value = '' + value; - } - } else if (node.value !== '' + value) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - node.value = '' + value; - } - } else { - if (props.value == null && props.defaultValue != null) { - // In Chrome, assigning defaultValue to certain input types triggers input validation. - // For number inputs, the display value loses trailing decimal points. For email inputs, - // Chrome raises "The specified value <x> is not a valid email address". - // - // Here we check to see if the defaultValue has actually changed, avoiding these problems - // when the user is inputting text - // - // https://github.com/facebook/react/issues/7253 - if (node.defaultValue !== '' + props.defaultValue) { - node.defaultValue = '' + props.defaultValue; - } - } - if (props.checked == null && props.defaultChecked != null) { - node.defaultChecked = !!props.defaultChecked; - } +exports.ip = function ip(inL, inR, out, off) { + var outL = 0; + var outR = 0; + + for (var i = 6; i >= 0; i -= 2) { + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inR >>> (j + i)) & 1; } - }, + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inL >>> (j + i)) & 1; + } + } - postMountWrapper: function (inst) { - var props = inst._currentElement.props; + for (var i = 6; i >= 0; i -= 2) { + for (var j = 1; j <= 25; j += 8) { + outR <<= 1; + outR |= (inR >>> (j + i)) & 1; + } + for (var j = 1; j <= 25; j += 8) { + outR <<= 1; + outR |= (inL >>> (j + i)) & 1; + } + } - // This is in postMount because we need access to the DOM node, which is not - // available until after the component has mounted. - var node = ReactDOMComponentTree.getNodeFromInstance(inst); + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; - // Detach value from defaultValue. We won't do anything if we're working on - // submit or reset inputs as those values & defaultValues are linked. They - // are not resetable nodes so this operation doesn't matter and actually - // removes browser-default values (eg "Submit Query") when no value is - // provided. +exports.rip = function rip(inL, inR, out, off) { + var outL = 0; + var outR = 0; - switch (props.type) { - case 'submit': - case 'reset': - break; - case 'color': - case 'date': - case 'datetime': - case 'datetime-local': - case 'month': - case 'time': - case 'week': - // This fixes the no-show issue on iOS Safari and Android Chrome: - // https://github.com/facebook/react/issues/7233 - node.value = ''; - node.value = node.defaultValue; - break; - default: - node.value = node.value; - break; + for (var i = 0; i < 4; i++) { + for (var j = 24; j >= 0; j -= 8) { + outL <<= 1; + outL |= (inR >>> (j + i)) & 1; + outL <<= 1; + outL |= (inL >>> (j + i)) & 1; } + } + for (var i = 4; i < 8; i++) { + for (var j = 24; j >= 0; j -= 8) { + outR <<= 1; + outR |= (inR >>> (j + i)) & 1; + outR <<= 1; + outR |= (inL >>> (j + i)) & 1; + } + } - // Normally, we'd just do `node.checked = node.checked` upon initial mount, less this bug - // this is needed to work around a chrome bug where setting defaultChecked - // will sometimes influence the value of checked (even after detachment). - // Reference: https://bugs.chromium.org/p/chromium/issues/detail?id=608416 - // We need to temporarily unset name to avoid disrupting radio button groups. - var name = node.name; - if (name !== '') { - node.name = ''; + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; + +exports.pc1 = function pc1(inL, inR, out, off) { + var outL = 0; + var outR = 0; + + // 7, 15, 23, 31, 39, 47, 55, 63 + // 6, 14, 22, 30, 39, 47, 55, 63 + // 5, 13, 21, 29, 39, 47, 55, 63 + // 4, 12, 20, 28 + for (var i = 7; i >= 5; i--) { + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inR >> (j + i)) & 1; } - node.defaultChecked = !node.defaultChecked; - node.defaultChecked = !node.defaultChecked; - if (name !== '') { - node.name = name; + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inL >> (j + i)) & 1; + } + } + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inR >> (j + i)) & 1; + } + + // 1, 9, 17, 25, 33, 41, 49, 57 + // 2, 10, 18, 26, 34, 42, 50, 58 + // 3, 11, 19, 27, 35, 43, 51, 59 + // 36, 44, 52, 60 + for (var i = 1; i <= 3; i++) { + for (var j = 0; j <= 24; j += 8) { + outR <<= 1; + outR |= (inR >> (j + i)) & 1; } + for (var j = 0; j <= 24; j += 8) { + outR <<= 1; + outR |= (inL >> (j + i)) & 1; + } + } + for (var j = 0; j <= 24; j += 8) { + outR <<= 1; + outR |= (inL >> (j + i)) & 1; } + + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; }; -function _handleChange(event) { - var props = this._currentElement.props; +exports.r28shl = function r28shl(num, shift) { + return ((num << shift) & 0xfffffff) | (num >>> (28 - shift)); +}; - var returnValue = LinkedValueUtils.executeOnChange(props, event); +var pc2table = [ + // inL => outL + 14, 11, 17, 4, 27, 23, 25, 0, + 13, 22, 7, 18, 5, 9, 16, 24, + 2, 20, 12, 21, 1, 8, 15, 26, - // Here we use asap to wait until all updates have propagated, which - // is important when using controlled components within layers: - // https://github.com/facebook/react/issues/1698 - ReactUpdates.asap(forceUpdateIfMounted, this); + // inR => outR + 15, 4, 25, 19, 9, 1, 26, 16, + 5, 11, 23, 8, 12, 7, 17, 0, + 22, 3, 10, 14, 6, 20, 27, 24 +]; - var name = props.name; - if (props.type === 'radio' && name != null) { - var rootNode = ReactDOMComponentTree.getNodeFromInstance(this); - var queryRoot = rootNode; +exports.pc2 = function pc2(inL, inR, out, off) { + var outL = 0; + var outR = 0; - while (queryRoot.parentNode) { - queryRoot = queryRoot.parentNode; - } + var len = pc2table.length >>> 1; + for (var i = 0; i < len; i++) { + outL <<= 1; + outL |= (inL >>> pc2table[i]) & 0x1; + } + for (var i = len; i < pc2table.length; i++) { + outR <<= 1; + outR |= (inR >>> pc2table[i]) & 0x1; + } - // If `rootNode.form` was non-null, then we could try `form.elements`, - // but that sometimes behaves strangely in IE8. We could also try using - // `form.getElementsByName`, but that will only return direct children - // and won't include inputs that use the HTML5 `form=` attribute. Since - // the input might not even be in a form, let's just use the global - // `querySelectorAll` to ensure we don't miss anything. - var group = queryRoot.querySelectorAll('input[name=' + JSON.stringify('' + name) + '][type="radio"]'); + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; - for (var i = 0; i < group.length; i++) { - var otherNode = group[i]; - if (otherNode === rootNode || otherNode.form !== rootNode.form) { - continue; - } - // This will throw if radio buttons rendered by different copies of React - // and the same name are rendered into the same form (same as #1939). - // That's probably okay; we don't support it just as we don't support - // mixing React radio buttons with non-React ones. - var otherInstance = ReactDOMComponentTree.getInstanceFromNode(otherNode); - !otherInstance ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOMInput: Mixing React and non-React radio inputs with the same `name` is not supported.') : _prodInvariant('90') : void 0; - // If this is a controlled radio button group, forcing the input that - // was previously checked to update will cause it to be come re-checked - // as appropriate. - ReactUpdates.asap(forceUpdateIfMounted, otherInstance); - } +exports.expand = function expand(r, out, off) { + var outL = 0; + var outR = 0; + + outL = ((r & 1) << 5) | (r >>> 27); + for (var i = 23; i >= 15; i -= 4) { + outL <<= 6; + outL |= (r >>> i) & 0x3f; } + for (var i = 11; i >= 3; i -= 4) { + outR |= (r >>> i) & 0x3f; + outR <<= 6; + } + outR |= ((r & 0x1f) << 1) | (r >>> 31); - return returnValue; -} + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; + +var sTable = [ + 14, 0, 4, 15, 13, 7, 1, 4, 2, 14, 15, 2, 11, 13, 8, 1, + 3, 10, 10, 6, 6, 12, 12, 11, 5, 9, 9, 5, 0, 3, 7, 8, + 4, 15, 1, 12, 14, 8, 8, 2, 13, 4, 6, 9, 2, 1, 11, 7, + 15, 5, 12, 11, 9, 3, 7, 14, 3, 10, 10, 0, 5, 6, 0, 13, + + 15, 3, 1, 13, 8, 4, 14, 7, 6, 15, 11, 2, 3, 8, 4, 14, + 9, 12, 7, 0, 2, 1, 13, 10, 12, 6, 0, 9, 5, 11, 10, 5, + 0, 13, 14, 8, 7, 10, 11, 1, 10, 3, 4, 15, 13, 4, 1, 2, + 5, 11, 8, 6, 12, 7, 6, 12, 9, 0, 3, 5, 2, 14, 15, 9, + + 10, 13, 0, 7, 9, 0, 14, 9, 6, 3, 3, 4, 15, 6, 5, 10, + 1, 2, 13, 8, 12, 5, 7, 14, 11, 12, 4, 11, 2, 15, 8, 1, + 13, 1, 6, 10, 4, 13, 9, 0, 8, 6, 15, 9, 3, 8, 0, 7, + 11, 4, 1, 15, 2, 14, 12, 3, 5, 11, 10, 5, 14, 2, 7, 12, + + 7, 13, 13, 8, 14, 11, 3, 5, 0, 6, 6, 15, 9, 0, 10, 3, + 1, 4, 2, 7, 8, 2, 5, 12, 11, 1, 12, 10, 4, 14, 15, 9, + 10, 3, 6, 15, 9, 0, 0, 6, 12, 10, 11, 1, 7, 13, 13, 8, + 15, 9, 1, 4, 3, 5, 14, 11, 5, 12, 2, 7, 8, 2, 4, 14, + + 2, 14, 12, 11, 4, 2, 1, 12, 7, 4, 10, 7, 11, 13, 6, 1, + 8, 5, 5, 0, 3, 15, 15, 10, 13, 3, 0, 9, 14, 8, 9, 6, + 4, 11, 2, 8, 1, 12, 11, 7, 10, 1, 13, 14, 7, 2, 8, 13, + 15, 6, 9, 15, 12, 0, 5, 9, 6, 10, 3, 4, 0, 5, 14, 3, + + 12, 10, 1, 15, 10, 4, 15, 2, 9, 7, 2, 12, 6, 9, 8, 5, + 0, 6, 13, 1, 3, 13, 4, 14, 14, 0, 7, 11, 5, 3, 11, 8, + 9, 4, 14, 3, 15, 2, 5, 12, 2, 9, 8, 5, 12, 15, 3, 10, + 7, 11, 0, 14, 4, 1, 10, 7, 1, 6, 13, 0, 11, 8, 6, 13, + + 4, 13, 11, 0, 2, 11, 14, 7, 15, 4, 0, 9, 8, 1, 13, 10, + 3, 14, 12, 3, 9, 5, 7, 12, 5, 2, 10, 15, 6, 8, 1, 6, + 1, 6, 4, 11, 11, 13, 13, 8, 12, 1, 3, 4, 7, 10, 14, 7, + 10, 9, 15, 5, 6, 0, 8, 15, 0, 14, 5, 2, 9, 3, 2, 12, + + 13, 1, 2, 15, 8, 13, 4, 8, 6, 10, 15, 3, 11, 7, 1, 4, + 10, 12, 9, 5, 3, 6, 14, 11, 5, 0, 0, 14, 12, 9, 7, 2, + 7, 2, 11, 1, 4, 14, 1, 7, 9, 4, 12, 10, 14, 8, 2, 13, + 0, 15, 6, 12, 10, 9, 13, 0, 15, 3, 3, 5, 5, 6, 8, 11 +]; + +exports.substitute = function substitute(inL, inR) { + var out = 0; + for (var i = 0; i < 4; i++) { + var b = (inL >>> (18 - i * 6)) & 0x3f; + var sb = sTable[i * 0x40 + b]; + + out <<= 4; + out |= sb; + } + for (var i = 0; i < 4; i++) { + var b = (inR >>> (18 - i * 6)) & 0x3f; + var sb = sTable[4 * 0x40 + i * 0x40 + b]; + + out <<= 4; + out |= sb; + } + return out >>> 0; +}; + +var permuteTable = [ + 16, 25, 12, 11, 3, 20, 4, 15, 31, 17, 9, 6, 27, 14, 1, 22, + 30, 24, 8, 18, 0, 5, 29, 23, 13, 19, 2, 26, 10, 21, 28, 7 +]; + +exports.permute = function permute(num) { + var out = 0; + for (var i = 0; i < permuteTable.length; i++) { + out <<= 1; + out |= (num >>> permuteTable[i]) & 0x1; + } + return out >>> 0; +}; + +exports.padSplit = function padSplit(num, size, group) { + var str = num.toString(2); + while (str.length < size) + str = '0' + str; + + var out = []; + for (var i = 0; i < size; i += group) + out.push(str.slice(i, i + group)); + return out.join(' '); +}; -module.exports = ReactDOMInput; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 172 */ +/* 429 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var assert = __webpack_require__(21); -var _assign = __webpack_require__(5); +function Cipher(options) { + this.options = options; -var React = __webpack_require__(24); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMSelect = __webpack_require__(95); + this.type = this.options.type; + this.blockSize = 8; + this._init(); -var warning = __webpack_require__(2); -var didWarnInvalidOptionChildren = false; + this.buffer = new Array(this.blockSize); + this.bufferOff = 0; +} +module.exports = Cipher; -function flattenChildren(children) { - var content = ''; +Cipher.prototype._init = function _init() { + // Might be overrided +}; - // Flatten children and warn if they aren't strings or numbers; - // invalid types are ignored. - React.Children.forEach(children, function (child) { - if (child == null) { - return; - } - if (typeof child === 'string' || typeof child === 'number') { - content += child; - } else if (!didWarnInvalidOptionChildren) { - didWarnInvalidOptionChildren = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Only strings and numbers are supported as <option> children.') : void 0; - } - }); +Cipher.prototype.update = function update(data) { + if (data.length === 0) + return []; - return content; -} + if (this.type === 'decrypt') + return this._updateDecrypt(data); + else + return this._updateEncrypt(data); +}; -/** - * Implements an <option> host component that warns when `selected` is set. - */ -var ReactDOMOption = { - mountWrapper: function (inst, props, hostParent) { - // TODO (yungsters): Remove support for `selected` in <option>. - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(props.selected == null, 'Use the `defaultValue` or `value` props on <select> instead of ' + 'setting `selected` on <option>.') : void 0; - } +Cipher.prototype._buffer = function _buffer(data, off) { + // Append data to buffer + var min = Math.min(this.buffer.length - this.bufferOff, data.length - off); + for (var i = 0; i < min; i++) + this.buffer[this.bufferOff + i] = data[off + i]; + this.bufferOff += min; - // Look up whether this option is 'selected' - var selectValue = null; - if (hostParent != null) { - var selectParent = hostParent; + // Shift next + return min; +}; - if (selectParent._tag === 'optgroup') { - selectParent = selectParent._hostParent; - } +Cipher.prototype._flushBuffer = function _flushBuffer(out, off) { + this._update(this.buffer, 0, out, off); + this.bufferOff = 0; + return this.blockSize; +}; - if (selectParent != null && selectParent._tag === 'select') { - selectValue = ReactDOMSelect.getSelectValueContext(selectParent); - } - } +Cipher.prototype._updateEncrypt = function _updateEncrypt(data) { + var inputOff = 0; + var outputOff = 0; - // If the value is null (e.g., no specified value or after initial mount) - // or missing (e.g., for <datalist>), we don't change props.selected - var selected = null; - if (selectValue != null) { - var value; - if (props.value != null) { - value = props.value + ''; - } else { - value = flattenChildren(props.children); - } - selected = false; - if (Array.isArray(selectValue)) { - // multiple - for (var i = 0; i < selectValue.length; i++) { - if ('' + selectValue[i] === value) { - selected = true; - break; - } - } - } else { - selected = '' + selectValue === value; - } - } + var count = ((this.bufferOff + data.length) / this.blockSize) | 0; + var out = new Array(count * this.blockSize); - inst._wrapperState = { selected: selected }; - }, + if (this.bufferOff !== 0) { + inputOff += this._buffer(data, inputOff); - postMountWrapper: function (inst) { - // value="" should make a value attribute (#6219) - var props = inst._currentElement.props; - if (props.value != null) { - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - node.setAttribute('value', props.value); - } - }, + if (this.bufferOff === this.buffer.length) + outputOff += this._flushBuffer(out, outputOff); + } - getHostProps: function (inst, props) { - var hostProps = _assign({ selected: undefined, children: undefined }, props); + // Write blocks + var max = data.length - ((data.length - inputOff) % this.blockSize); + for (; inputOff < max; inputOff += this.blockSize) { + this._update(data, inputOff, out, outputOff); + outputOff += this.blockSize; + } - // Read state only from initial mount because <select> updates value - // manually; we need the initial state only for server rendering - if (inst._wrapperState.selected != null) { - hostProps.selected = inst._wrapperState.selected; - } + // Queue rest + for (; inputOff < data.length; inputOff++, this.bufferOff++) + this.buffer[this.bufferOff] = data[inputOff]; - var content = flattenChildren(props.children); + return out; +}; - if (content) { - hostProps.children = content; - } +Cipher.prototype._updateDecrypt = function _updateDecrypt(data) { + var inputOff = 0; + var outputOff = 0; - return hostProps; + var count = Math.ceil((this.bufferOff + data.length) / this.blockSize) - 1; + var out = new Array(count * this.blockSize); + + // TODO(indutny): optimize it, this is far from optimal + for (; count > 0; count--) { + inputOff += this._buffer(data, inputOff); + outputOff += this._flushBuffer(out, outputOff); } + + // Buffer rest of the input + inputOff += this._buffer(data, inputOff); + + return out; +}; + +Cipher.prototype.final = function final(buffer) { + var first; + if (buffer) + first = this.update(buffer); + + var last; + if (this.type === 'encrypt') + last = this._finalEncrypt(); + else + last = this._finalDecrypt(); + + if (first) + return first.concat(last); + else + return last; +}; + +Cipher.prototype._pad = function _pad(buffer, off) { + if (off === 0) + return false; + + while (off < buffer.length) + buffer[off++] = 0; + + return true; +}; + +Cipher.prototype._finalEncrypt = function _finalEncrypt() { + if (!this._pad(this.buffer, this.bufferOff)) + return []; + + var out = new Array(this.blockSize); + this._update(this.buffer, 0, out, 0); + return out; +}; + +Cipher.prototype._unpad = function _unpad(buffer) { + return buffer; +}; + +Cipher.prototype._finalDecrypt = function _finalDecrypt() { + assert.equal(this.bufferOff, this.blockSize, 'Not enough data to decrypt'); + var out = new Array(this.blockSize); + this._flushBuffer(out, 0); + + return this._unpad(out); }; -module.exports = ReactDOMOption; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 173 */ +/* 430 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +var des = __webpack_require__(109); +var utils = des.utils; +var Cipher = des.Cipher; -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); +function DESState() { + this.tmp = new Array(2); + this.keys = null; +} -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +function DES(options) { + Cipher.call(this, options); -var didWarnValueLink = false; -var didWarnValDefaultVal = false; + var state = new DESState(); + this._desState = state; -function forceUpdateIfMounted() { - if (this._rootNodeID) { - // DOM component is still mounted; update - ReactDOMTextarea.updateWrapper(this); - } + this.deriveKeys(state, options.key); } +inherits(DES, Cipher); +module.exports = DES; -/** - * Implements a <textarea> host component that allows setting `value`, and - * `defaultValue`. This differs from the traditional DOM API because value is - * usually set as PCDATA children. - * - * If `value` is not supplied (or null/undefined), user actions that affect the - * value will trigger updates to the element. - * - * If `value` is supplied (and not null/undefined), the rendered element will - * not trigger updates to the element. Instead, the `value` prop must change in - * order for the rendered element to be updated. - * - * The rendered element will be initialized with an empty value, the prop - * `defaultValue` if specified, or the children content (deprecated). - */ -var ReactDOMTextarea = { - getHostProps: function (inst, props) { - !(props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`dangerouslySetInnerHTML` does not make sense on <textarea>.') : _prodInvariant('91') : void 0; +DES.create = function create(options) { + return new DES(options); +}; - // Always set children to the same thing. In IE9, the selection range will - // get reset if `textContent` is mutated. We could add a check in setTextContent - // to only set the value if/when the value differs from the node value (which would - // completely solve this IE9 bug), but Sebastian+Ben seemed to like this solution. - // The value can be a boolean or object so that's why it's forced to be a string. - var hostProps = _assign({}, props, { - value: undefined, - defaultValue: undefined, - children: '' + inst._wrapperState.initialValue, - onChange: inst._wrapperState.onChange - }); +var shiftTable = [ + 1, 1, 2, 2, 2, 2, 2, 2, + 1, 2, 2, 2, 2, 2, 2, 1 +]; - return hostProps; - }, +DES.prototype.deriveKeys = function deriveKeys(state, key) { + state.keys = new Array(16 * 2); - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - LinkedValueUtils.checkPropTypes('textarea', props, inst._currentElement._owner); - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `textarea` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValDefaultVal) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Textarea elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; - didWarnValDefaultVal = true; - } - } + assert.equal(key.length, this.blockSize, 'Invalid key length'); - var value = LinkedValueUtils.getValue(props); - var initialValue = value; + var kL = utils.readUInt32BE(key, 0); + var kR = utils.readUInt32BE(key, 4); - // Only bother fetching default value if we're going to use it - if (value == null) { - var defaultValue = props.defaultValue; - // TODO (yungsters): Remove support for children content in <textarea>. - var children = props.children; - if (children != null) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(false, 'Use the `defaultValue` or `value` props instead of setting ' + 'children on <textarea>.') : void 0; - } - !(defaultValue == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'If you supply `defaultValue` on a <textarea>, do not pass children.') : _prodInvariant('92') : void 0; - if (Array.isArray(children)) { - !(children.length <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, '<textarea> can only have at most one child.') : _prodInvariant('93') : void 0; - children = children[0]; - } + utils.pc1(kL, kR, state.tmp, 0); + kL = state.tmp[0]; + kR = state.tmp[1]; + for (var i = 0; i < state.keys.length; i += 2) { + var shift = shiftTable[i >>> 1]; + kL = utils.r28shl(kL, shift); + kR = utils.r28shl(kR, shift); + utils.pc2(kL, kR, state.keys, i); + } +}; - defaultValue = '' + children; - } - if (defaultValue == null) { - defaultValue = ''; - } - initialValue = defaultValue; - } +DES.prototype._update = function _update(inp, inOff, out, outOff) { + var state = this._desState; - inst._wrapperState = { - initialValue: '' + initialValue, - listeners: null, - onChange: _handleChange.bind(inst) - }; - }, + var l = utils.readUInt32BE(inp, inOff); + var r = utils.readUInt32BE(inp, inOff + 4); - updateWrapper: function (inst) { - var props = inst._currentElement.props; + // Initial Permutation + utils.ip(l, r, state.tmp, 0); + l = state.tmp[0]; + r = state.tmp[1]; - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var value = LinkedValueUtils.getValue(props); - if (value != null) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - var newValue = '' + value; + if (this.type === 'encrypt') + this._encrypt(state, l, r, state.tmp, 0); + else + this._decrypt(state, l, r, state.tmp, 0); - // To avoid side effects (such as losing text selection), only set value if changed - if (newValue !== node.value) { - node.value = newValue; - } - if (props.defaultValue == null) { - node.defaultValue = newValue; - } - } - if (props.defaultValue != null) { - node.defaultValue = props.defaultValue; - } - }, + l = state.tmp[0]; + r = state.tmp[1]; - postMountWrapper: function (inst) { - // This is in postMount because we need access to the DOM node, which is not - // available until after the component has mounted. - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var textContent = node.textContent; + utils.writeUInt32BE(out, l, outOff); + utils.writeUInt32BE(out, r, outOff + 4); +}; - // Only set node.value if textContent is equal to the expected - // initial value. In IE10/IE11 there is a bug where the placeholder attribute - // will populate textContent as well. - // https://developer.microsoft.com/microsoft-edge/platform/issues/101525/ - if (textContent === inst._wrapperState.initialValue) { - node.value = textContent; - } +DES.prototype._pad = function _pad(buffer, off) { + var value = buffer.length - off; + for (var i = off; i < buffer.length; i++) + buffer[i] = value; + + return true; +}; + +DES.prototype._unpad = function _unpad(buffer) { + var pad = buffer[buffer.length - 1]; + for (var i = buffer.length - pad; i < buffer.length; i++) + assert.equal(buffer[i], pad); + + return buffer.slice(0, buffer.length - pad); +}; + +DES.prototype._encrypt = function _encrypt(state, lStart, rStart, out, off) { + var l = lStart; + var r = rStart; + + // Apply f() x16 times + for (var i = 0; i < state.keys.length; i += 2) { + var keyL = state.keys[i]; + var keyR = state.keys[i + 1]; + + // f(r, k) + utils.expand(r, state.tmp, 0); + + keyL ^= state.tmp[0]; + keyR ^= state.tmp[1]; + var s = utils.substitute(keyL, keyR); + var f = utils.permute(s); + + var t = r; + r = (l ^ f) >>> 0; + l = t; } + + // Reverse Initial Permutation + utils.rip(r, l, out, off); }; -function _handleChange(event) { - var props = this._currentElement.props; - var returnValue = LinkedValueUtils.executeOnChange(props, event); - ReactUpdates.asap(forceUpdateIfMounted, this); - return returnValue; -} +DES.prototype._decrypt = function _decrypt(state, lStart, rStart, out, off) { + var l = rStart; + var r = lStart; + + // Apply f() x16 times + for (var i = state.keys.length - 2; i >= 0; i -= 2) { + var keyL = state.keys[i]; + var keyR = state.keys[i + 1]; + + // f(r, k) + utils.expand(l, state.tmp, 0); + + keyL ^= state.tmp[0]; + keyR ^= state.tmp[1]; + var s = utils.substitute(keyL, keyR); + var f = utils.permute(s); + + var t = l; + l = (r ^ f) >>> 0; + r = t; + } + + // Reverse Initial Permutation + utils.rip(l, r, out, off); +}; -module.exports = ReactDOMTextarea; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 174 */ +/* 431 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); -var _prodInvariant = __webpack_require__(3); +var proto = {}; -var ReactComponentEnvironment = __webpack_require__(59); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); +function CBCState(iv) { + assert.equal(iv.length, 8, 'Invalid IV length'); -var ReactCurrentOwner = __webpack_require__(14); -var ReactReconciler = __webpack_require__(26); -var ReactChildReconciler = __webpack_require__(175); + this.iv = new Array(8); + for (var i = 0; i < this.iv.length; i++) + this.iv[i] = iv[i]; +} -var emptyFunction = __webpack_require__(12); -var flattenChildren = __webpack_require__(182); -var invariant = __webpack_require__(1); +function instantiate(Base) { + function CBC(options) { + Base.call(this, options); + this._cbcInit(); + } + inherits(CBC, Base); -/** - * Make an update for markup to be rendered and inserted at a supplied index. - * - * @param {string} markup Markup that renders into an element. - * @param {number} toIndex Destination index. - * @private - */ -function makeInsertMarkup(markup, afterNode, toIndex) { - // NOTE: Null values reduce hidden classes. - return { - type: 'INSERT_MARKUP', - content: markup, - fromIndex: null, - fromNode: null, - toIndex: toIndex, - afterNode: afterNode + var keys = Object.keys(proto); + for (var i = 0; i < keys.length; i++) { + var key = keys[i]; + CBC.prototype[key] = proto[key]; + } + + CBC.create = function create(options) { + return new CBC(options); }; + + return CBC; } -/** - * Make an update for moving an existing element to another index. - * - * @param {number} fromIndex Source index of the existing element. - * @param {number} toIndex Destination index of the element. - * @private - */ -function makeMove(child, afterNode, toIndex) { - // NOTE: Null values reduce hidden classes. - return { - type: 'MOVE_EXISTING', - content: null, - fromIndex: child._mountIndex, - fromNode: ReactReconciler.getHostNode(child), - toIndex: toIndex, - afterNode: afterNode - }; +exports.instantiate = instantiate; + +proto._cbcInit = function _cbcInit() { + var state = new CBCState(this.options.iv); + this._cbcState = state; +}; + +proto._update = function _update(inp, inOff, out, outOff) { + var state = this._cbcState; + var superProto = this.constructor.super_.prototype; + + var iv = state.iv; + if (this.type === 'encrypt') { + for (var i = 0; i < this.blockSize; i++) + iv[i] ^= inp[inOff + i]; + + superProto._update.call(this, iv, 0, out, outOff); + + for (var i = 0; i < this.blockSize; i++) + iv[i] = out[outOff + i]; + } else { + superProto._update.call(this, inp, inOff, out, outOff); + + for (var i = 0; i < this.blockSize; i++) + out[outOff + i] ^= iv[i]; + + for (var i = 0; i < this.blockSize; i++) + iv[i] = inp[inOff + i]; + } +}; + + +/***/ }), +/* 432 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); + +var des = __webpack_require__(109); +var Cipher = des.Cipher; +var DES = des.DES; + +function EDEState(type, key) { + assert.equal(key.length, 24, 'Invalid key length'); + + var k1 = key.slice(0, 8); + var k2 = key.slice(8, 16); + var k3 = key.slice(16, 24); + + if (type === 'encrypt') { + this.ciphers = [ + DES.create({ type: 'encrypt', key: k1 }), + DES.create({ type: 'decrypt', key: k2 }), + DES.create({ type: 'encrypt', key: k3 }) + ]; + } else { + this.ciphers = [ + DES.create({ type: 'decrypt', key: k3 }), + DES.create({ type: 'encrypt', key: k2 }), + DES.create({ type: 'decrypt', key: k1 }) + ]; + } } -/** - * Make an update for removing an element at an index. - * - * @param {number} fromIndex Index of the element to remove. - * @private - */ -function makeRemove(child, node) { - // NOTE: Null values reduce hidden classes. - return { - type: 'REMOVE_NODE', - content: null, - fromIndex: child._mountIndex, - fromNode: node, - toIndex: null, - afterNode: null - }; +function EDE(options) { + Cipher.call(this, options); + + var state = new EDEState(this.type, this.options.key); + this._edeState = state; } +inherits(EDE, Cipher); -/** - * Make an update for setting the markup of a node. - * - * @param {string} markup Markup that renders into an element. - * @private - */ -function makeSetMarkup(markup) { - // NOTE: Null values reduce hidden classes. - return { - type: 'SET_MARKUP', - content: markup, - fromIndex: null, - fromNode: null, - toIndex: null, - afterNode: null - }; +module.exports = EDE; + +EDE.create = function create(options) { + return new EDE(options); +}; + +EDE.prototype._update = function _update(inp, inOff, out, outOff) { + var state = this._edeState; + + state.ciphers[0]._update(inp, inOff, out, outOff); + state.ciphers[1]._update(out, outOff, out, outOff); + state.ciphers[2]._update(out, outOff, out, outOff); +}; + +EDE.prototype._pad = DES.prototype._pad; +EDE.prototype._unpad = DES.prototype._unpad; + + +/***/ }), +/* 433 */ +/***/ (function(module, exports) { + +exports['des-ecb'] = { + key: 8, + iv: 0 +} +exports['des-cbc'] = exports.des = { + key: 8, + iv: 8 +} +exports['des-ede3-cbc'] = exports.des3 = { + key: 24, + iv: 8 +} +exports['des-ede3'] = { + key: 24, + iv: 0 +} +exports['des-ede-cbc'] = { + key: 16, + iv: 8 +} +exports['des-ede'] = { + key: 16, + iv: 0 } -/** - * Make an update for setting the text content. - * - * @param {string} textContent Text content to set. - * @private - */ -function makeTextContent(textContent) { - // NOTE: Null values reduce hidden classes. - return { - type: 'TEXT_CONTENT', - content: textContent, - fromIndex: null, - fromNode: null, - toIndex: null, - afterNode: null - }; + +/***/ }), +/* 434 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var generatePrime = __webpack_require__(189) +var primes = __webpack_require__(435) + +var DH = __webpack_require__(436) + +function getDiffieHellman (mod) { + var prime = new Buffer(primes[mod].prime, 'hex') + var gen = new Buffer(primes[mod].gen, 'hex') + + return new DH(prime, gen) +} + +var ENCODINGS = { + 'binary': true, 'hex': true, 'base64': true +} + +function createDiffieHellman (prime, enc, generator, genc) { + if (Buffer.isBuffer(enc) || ENCODINGS[enc] === undefined) { + return createDiffieHellman(prime, 'binary', enc, generator) + } + + enc = enc || 'binary' + genc = genc || 'binary' + generator = generator || new Buffer([2]) + + if (!Buffer.isBuffer(generator)) { + generator = new Buffer(generator, genc) + } + + if (typeof prime === 'number') { + return new DH(generatePrime(prime, generator), generator, true) + } + + if (!Buffer.isBuffer(prime)) { + prime = new Buffer(prime, enc) + } + + return new DH(prime, generator, true) +} + +exports.DiffieHellmanGroup = exports.createDiffieHellmanGroup = exports.getDiffieHellman = getDiffieHellman +exports.createDiffieHellman = exports.DiffieHellman = createDiffieHellman + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 435 */ +/***/ (function(module, exports) { + +module.exports = { + "modp1": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff" + }, + "modp2": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff" + }, + "modp5": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff" + }, + "modp14": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff" + }, + "modp15": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff" + }, + "modp16": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff" + }, + "modp17": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff" + }, + "modp18": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff" + } +}; + +/***/ }), +/* 436 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var BN = __webpack_require__(11); +var MillerRabin = __webpack_require__(190); +var millerRabin = new MillerRabin(); +var TWENTYFOUR = new BN(24); +var ELEVEN = new BN(11); +var TEN = new BN(10); +var THREE = new BN(3); +var SEVEN = new BN(7); +var primes = __webpack_require__(189); +var randomBytes = __webpack_require__(43); +module.exports = DH; + +function setPublicKey(pub, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(pub)) { + pub = new Buffer(pub, enc); + } + this._pub = new BN(pub); + return this; } -/** - * Push an update, if any, onto the queue. Creates a new queue if none is - * passed and always returns the queue. Mutative. - */ -function enqueue(queue, update) { - if (update) { - queue = queue || []; - queue.push(update); +function setPrivateKey(priv, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(priv)) { + priv = new Buffer(priv, enc); } - return queue; + this._priv = new BN(priv); + return this; } -/** - * Processes any enqueued updates. - * - * @private - */ -function processQueue(inst, updateQueue) { - ReactComponentEnvironment.processChildrenUpdates(inst, updateQueue); +var primeCache = {}; +function checkPrime(prime, generator) { + var gen = generator.toString('hex'); + var hex = [gen, prime.toString(16)].join('_'); + if (hex in primeCache) { + return primeCache[hex]; + } + var error = 0; + + if (prime.isEven() || + !primes.simpleSieve || + !primes.fermatTest(prime) || + !millerRabin.test(prime)) { + //not a prime so +1 + error += 1; + + if (gen === '02' || gen === '05') { + // we'd be able to check the generator + // it would fail so +8 + error += 8; + } else { + //we wouldn't be able to test the generator + // so +4 + error += 4; + } + primeCache[hex] = error; + return error; + } + if (!millerRabin.test(prime.shrn(1))) { + //not a safe prime + error += 2; + } + var rem; + switch (gen) { + case '02': + if (prime.mod(TWENTYFOUR).cmp(ELEVEN)) { + // unsuidable generator + error += 8; + } + break; + case '05': + rem = prime.mod(TEN); + if (rem.cmp(THREE) && rem.cmp(SEVEN)) { + // prime mod 10 needs to equal 3 or 7 + error += 8; + } + break; + default: + error += 4; + } + primeCache[hex] = error; + return error; } -var setChildrenForInstrumentation = emptyFunction; -if (process.env.NODE_ENV !== 'production') { - var getDebugID = function (inst) { - if (!inst._debugID) { - // Check for ART-like instances. TODO: This is silly/gross. - var internal; - if (internal = ReactInstanceMap.get(inst)) { - inst = internal; - } - } - return inst._debugID; - }; - setChildrenForInstrumentation = function (children) { - var debugID = getDebugID(this); - // TODO: React Native empty components are also multichild. - // This means they still get into this method but don't have _debugID. - if (debugID !== 0) { - ReactInstrumentation.debugTool.onSetChildren(debugID, children ? Object.keys(children).map(function (key) { - return children[key]._debugID; - }) : []); +function DH(prime, generator, malleable) { + this.setGenerator(generator); + this.__prime = new BN(prime); + this._prime = BN.mont(this.__prime); + this._primeLen = prime.length; + this._pub = undefined; + this._priv = undefined; + this._primeCode = undefined; + if (malleable) { + this.setPublicKey = setPublicKey; + this.setPrivateKey = setPrivateKey; + } else { + this._primeCode = 8; + } +} +Object.defineProperty(DH.prototype, 'verifyError', { + enumerable: true, + get: function () { + if (typeof this._primeCode !== 'number') { + this._primeCode = checkPrime(this.__prime, this.__gen); } - }; + return this._primeCode; + } +}); +DH.prototype.generateKeys = function () { + if (!this._priv) { + this._priv = new BN(randomBytes(this._primeLen)); + } + this._pub = this._gen.toRed(this._prime).redPow(this._priv).fromRed(); + return this.getPublicKey(); +}; + +DH.prototype.computeSecret = function (other) { + other = new BN(other); + other = other.toRed(this._prime); + var secret = other.redPow(this._priv).fromRed(); + var out = new Buffer(secret.toArray()); + var prime = this.getPrime(); + if (out.length < prime.length) { + var front = new Buffer(prime.length - out.length); + front.fill(0); + out = Buffer.concat([front, out]); + } + return out; +}; + +DH.prototype.getPublicKey = function getPublicKey(enc) { + return formatReturnValue(this._pub, enc); +}; + +DH.prototype.getPrivateKey = function getPrivateKey(enc) { + return formatReturnValue(this._priv, enc); +}; + +DH.prototype.getPrime = function (enc) { + return formatReturnValue(this.__prime, enc); +}; + +DH.prototype.getGenerator = function (enc) { + return formatReturnValue(this._gen, enc); +}; + +DH.prototype.setGenerator = function (gen, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(gen)) { + gen = new Buffer(gen, enc); + } + this.__gen = gen; + this._gen = new BN(gen); + return this; +}; + +function formatReturnValue(bn, enc) { + var buf = new Buffer(bn.toArray()); + if (!enc) { + return buf; + } else { + return buf.toString(enc); + } } -/** - * ReactMultiChild are capable of reconciling multiple children. - * - * @class ReactMultiChild - * @internal - */ -var ReactMultiChild = { - /** - * Provides common functionality for components that must reconcile multiple - * children. This is used by `ReactDOMComponent` to mount, update, and - * unmount child components. - * - * @lends {ReactMultiChild.prototype} - */ - Mixin: { - _reconcilerInstantiateChildren: function (nestedChildren, transaction, context) { - if (process.env.NODE_ENV !== 'production') { - var selfDebugID = getDebugID(this); - if (this._currentElement) { - try { - ReactCurrentOwner.current = this._currentElement._owner; - return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context, selfDebugID); - } finally { - ReactCurrentOwner.current = null; - } - } - } - return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context); - }, +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - _reconcilerUpdateChildren: function (prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context) { - var nextChildren; - var selfDebugID = 0; - if (process.env.NODE_ENV !== 'production') { - selfDebugID = getDebugID(this); - if (this._currentElement) { - try { - ReactCurrentOwner.current = this._currentElement._owner; - nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); - } finally { - ReactCurrentOwner.current = null; - } - ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); - return nextChildren; - } - } - nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); - ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); - return nextChildren; - }, +/***/ }), +/* 437 */ +/***/ (function(module, exports, __webpack_require__) { - /** - * Generates a "mount image" for each of the supplied children. In the case - * of `ReactDOMComponent`, a mount image is a string of markup. - * - * @param {?object} nestedChildren Nested child maps. - * @return {array} An array of mounted representations. - * @internal - */ - mountChildren: function (nestedChildren, transaction, context) { - var children = this._reconcilerInstantiateChildren(nestedChildren, transaction, context); - this._renderedChildren = children; +/* WEBPACK VAR INJECTION */(function(Buffer) {var createHash = __webpack_require__(27) +var stream = __webpack_require__(98) +var inherits = __webpack_require__(4) +var sign = __webpack_require__(438) +var verify = __webpack_require__(453) - var mountImages = []; - var index = 0; - for (var name in children) { - if (children.hasOwnProperty(name)) { - var child = children[name]; - var selfDebugID = 0; - if (process.env.NODE_ENV !== 'production') { - selfDebugID = getDebugID(this); - } - var mountImage = ReactReconciler.mountComponent(child, transaction, this, this._hostContainerInfo, context, selfDebugID); - child._mountIndex = index++; - mountImages.push(mountImage); - } - } +var algorithms = __webpack_require__(176) +Object.keys(algorithms).forEach(function (key) { + algorithms[key].id = new Buffer(algorithms[key].id, 'hex') + algorithms[key.toLowerCase()] = algorithms[key] +}) - if (process.env.NODE_ENV !== 'production') { - setChildrenForInstrumentation.call(this, children); - } +function Sign (algorithm) { + stream.Writable.call(this) - return mountImages; - }, + var data = algorithms[algorithm] + if (!data) throw new Error('Unknown message digest') - /** - * Replaces any rendered children with a text content string. - * - * @param {string} nextContent String of content. - * @internal - */ - updateTextContent: function (nextContent) { - var prevChildren = this._renderedChildren; - // Remove any rendered children. - ReactChildReconciler.unmountChildren(prevChildren, false); - for (var name in prevChildren) { - if (prevChildren.hasOwnProperty(name)) { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; - } - } - // Set new text content. - var updates = [makeTextContent(nextContent)]; - processQueue(this, updates); - }, + this._hashType = data.hash + this._hash = createHash(data.hash) + this._tag = data.id + this._signType = data.sign +} +inherits(Sign, stream.Writable) - /** - * Replaces any rendered children with a markup string. - * - * @param {string} nextMarkup String of markup. - * @internal - */ - updateMarkup: function (nextMarkup) { - var prevChildren = this._renderedChildren; - // Remove any rendered children. - ReactChildReconciler.unmountChildren(prevChildren, false); - for (var name in prevChildren) { - if (prevChildren.hasOwnProperty(name)) { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; - } - } - var updates = [makeSetMarkup(nextMarkup)]; - processQueue(this, updates); - }, +Sign.prototype._write = function _write (data, _, done) { + this._hash.update(data) + done() +} - /** - * Updates the rendered children with new children. - * - * @param {?object} nextNestedChildrenElements Nested child element maps. - * @param {ReactReconcileTransaction} transaction - * @internal - */ - updateChildren: function (nextNestedChildrenElements, transaction, context) { - // Hook used by React ART - this._updateChildren(nextNestedChildrenElements, transaction, context); - }, +Sign.prototype.update = function update (data, enc) { + if (typeof data === 'string') data = new Buffer(data, enc) - /** - * @param {?object} nextNestedChildrenElements Nested child element maps. - * @param {ReactReconcileTransaction} transaction - * @final - * @protected - */ - _updateChildren: function (nextNestedChildrenElements, transaction, context) { - var prevChildren = this._renderedChildren; - var removedNodes = {}; - var mountImages = []; - var nextChildren = this._reconcilerUpdateChildren(prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context); - if (!nextChildren && !prevChildren) { - return; - } - var updates = null; - var name; - // `nextIndex` will increment for each child in `nextChildren`, but - // `lastIndex` will be the last index visited in `prevChildren`. - var nextIndex = 0; - var lastIndex = 0; - // `nextMountIndex` will increment for each newly mounted child. - var nextMountIndex = 0; - var lastPlacedNode = null; - for (name in nextChildren) { - if (!nextChildren.hasOwnProperty(name)) { - continue; - } - var prevChild = prevChildren && prevChildren[name]; - var nextChild = nextChildren[name]; - if (prevChild === nextChild) { - updates = enqueue(updates, this.moveChild(prevChild, lastPlacedNode, nextIndex, lastIndex)); - lastIndex = Math.max(prevChild._mountIndex, lastIndex); - prevChild._mountIndex = nextIndex; - } else { - if (prevChild) { - // Update `lastIndex` before `_mountIndex` gets unset by unmounting. - lastIndex = Math.max(prevChild._mountIndex, lastIndex); - // The `removedNodes` loop below will actually remove the child. - } - // The child must be instantiated before it's mounted. - updates = enqueue(updates, this._mountChildAtIndex(nextChild, mountImages[nextMountIndex], lastPlacedNode, nextIndex, transaction, context)); - nextMountIndex++; - } - nextIndex++; - lastPlacedNode = ReactReconciler.getHostNode(nextChild); - } - // Remove children that are no longer present. - for (name in removedNodes) { - if (removedNodes.hasOwnProperty(name)) { - updates = enqueue(updates, this._unmountChild(prevChildren[name], removedNodes[name])); - } - } - if (updates) { - processQueue(this, updates); - } - this._renderedChildren = nextChildren; + this._hash.update(data) + return this +} - if (process.env.NODE_ENV !== 'production') { - setChildrenForInstrumentation.call(this, nextChildren); - } - }, +Sign.prototype.sign = function signMethod (key, enc) { + this.end() + var hash = this._hash.digest() + var sig = sign(hash, key, this._hashType, this._signType, this._tag) - /** - * Unmounts all rendered children. This should be used to clean up children - * when this component is unmounted. It does not actually perform any - * backend operations. - * - * @internal - */ - unmountChildren: function (safely) { - var renderedChildren = this._renderedChildren; - ReactChildReconciler.unmountChildren(renderedChildren, safely); - this._renderedChildren = null; - }, + return enc ? sig.toString(enc) : sig +} - /** - * Moves a child component to the supplied index. - * - * @param {ReactComponent} child Component to move. - * @param {number} toIndex Destination index of the element. - * @param {number} lastIndex Last index visited of the siblings of `child`. - * @protected - */ - moveChild: function (child, afterNode, toIndex, lastIndex) { - // If the index of `child` is less than `lastIndex`, then it needs to - // be moved. Otherwise, we do not need to move it because a child will be - // inserted or moved before `child`. - if (child._mountIndex < lastIndex) { - return makeMove(child, afterNode, toIndex); - } - }, +function Verify (algorithm) { + stream.Writable.call(this) - /** - * Creates a child component. - * - * @param {ReactComponent} child Component to create. - * @param {string} mountImage Markup to insert. - * @protected - */ - createChild: function (child, afterNode, mountImage) { - return makeInsertMarkup(mountImage, afterNode, child._mountIndex); - }, + var data = algorithms[algorithm] + if (!data) throw new Error('Unknown message digest') - /** - * Removes a child component. - * - * @param {ReactComponent} child Child to remove. - * @protected - */ - removeChild: function (child, node) { - return makeRemove(child, node); - }, + this._hash = createHash(data.hash) + this._tag = data.id + this._signType = data.sign +} +inherits(Verify, stream.Writable) - /** - * Mounts a child with the supplied name. - * - * NOTE: This is part of `updateChildren` and is here for readability. - * - * @param {ReactComponent} child Component to mount. - * @param {string} name Name of the child. - * @param {number} index Index at which to insert the child. - * @param {ReactReconcileTransaction} transaction - * @private - */ - _mountChildAtIndex: function (child, mountImage, afterNode, index, transaction, context) { - child._mountIndex = index; - return this.createChild(child, afterNode, mountImage); - }, +Verify.prototype._write = function _write (data, _, done) { + this._hash.update(data) + done() +} - /** - * Unmounts a rendered child. - * - * NOTE: This is part of `updateChildren` and is here for readability. - * - * @param {ReactComponent} child Component to unmount. - * @private - */ - _unmountChild: function (child, node) { - var update = this.removeChild(child, node); - child._mountIndex = null; - return update; - } - } -}; +Verify.prototype.update = function update (data, enc) { + if (typeof data === 'string') data = new Buffer(data, enc) -module.exports = ReactMultiChild; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + this._hash.update(data) + return this +} + +Verify.prototype.verify = function verifyMethod (key, sig, enc) { + if (typeof sig === 'string') sig = new Buffer(sig, enc) + + this.end() + var hash = this._hash.digest() + return verify(sig, hash, key, this._signType, this._tag) +} + +function createSign (algorithm) { + return new Sign(algorithm) +} + +function createVerify (algorithm) { + return new Verify(algorithm) +} + +module.exports = { + Sign: createSign, + Verify: createVerify, + createSign: createSign, + createVerify: createVerify +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 175 */ +/* 438 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) {// much of this based on https://github.com/indutny/self-signed/blob/gh-pages/lib/rsa.js +var createHmac = __webpack_require__(67) +var crt = __webpack_require__(110) +var EC = __webpack_require__(15).ec +var BN = __webpack_require__(11) +var parseKeys = __webpack_require__(72) +var curves = __webpack_require__(195) + +function sign (hash, key, hashType, signType, tag) { + var priv = parseKeys(key) + if (priv.curve) { + // rsa keys can be interpreted as ecdsa ones in openssl + if (signType !== 'ecdsa' && signType !== 'ecdsa/rsa') throw new Error('wrong private key type') + return ecSign(hash, priv) + } else if (priv.type === 'dsa') { + if (signType !== 'dsa') throw new Error('wrong private key type') + return dsaSign(hash, priv, hashType) + } else { + if (signType !== 'rsa' && signType !== 'ecdsa/rsa') throw new Error('wrong private key type') + } + hash = Buffer.concat([tag, hash]) + var len = priv.modulus.byteLength() + var pad = [ 0, 1 ] + while (hash.length + pad.length + 1 < len) pad.push(0xff) + pad.push(0x00) + var i = -1 + while (++i < hash.length) pad.push(hash[i]) + + var out = crt(pad, priv) + return out +} +function ecSign (hash, priv) { + var curveId = curves[priv.curve.join('.')] + if (!curveId) throw new Error('unknown curve ' + priv.curve.join('.')) + var curve = new EC(curveId) + var key = curve.keyFromPrivate(priv.privateKey) + var out = key.sign(hash) -var ReactReconciler = __webpack_require__(26); + return new Buffer(out.toDER()) +} -var instantiateReactComponent = __webpack_require__(96); -var KeyEscapeUtils = __webpack_require__(62); -var shouldUpdateReactComponent = __webpack_require__(61); -var traverseAllChildren = __webpack_require__(100); -var warning = __webpack_require__(2); +function dsaSign (hash, priv, algo) { + var x = priv.params.priv_key + var p = priv.params.p + var q = priv.params.q + var g = priv.params.g + var r = new BN(0) + var k + var H = bits2int(hash, q).mod(q) + var s = false + var kv = getKey(x, q, hash, algo) + while (s === false) { + k = makeKey(q, kv, algo) + r = makeR(g, k, p, q) + s = k.invm(q).imul(H.add(x.mul(r))).mod(q) + if (s.cmpn(0) === 0) { + s = false + r = new BN(0) + } + } + return toDER(r, s) +} -var ReactComponentTreeHook; +function toDER (r, s) { + r = r.toArray() + s = s.toArray() -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); + // Pad values + if (r[0] & 0x80) r = [ 0 ].concat(r) + if (s[0] & 0x80) s = [ 0 ].concat(s) + + var total = r.length + s.length + 4 + var res = [ 0x30, total, 0x02, r.length ] + res = res.concat(r, [ 0x02, s.length ], s) + return new Buffer(res) } -function instantiateChild(childInstances, child, name, selfDebugID) { - // We found a component instance. - var keyUnique = childInstances[name] === undefined; - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (!keyUnique) { - process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; - } - } - if (child != null && keyUnique) { - childInstances[name] = instantiateReactComponent(child, true); +function getKey (x, q, hash, algo) { + x = new Buffer(x.toArray()) + if (x.length < q.byteLength()) { + var zeros = new Buffer(q.byteLength() - x.length) + zeros.fill(0) + x = Buffer.concat([ zeros, x ]) + } + var hlen = hash.length + var hbits = bits2octets(hash, q) + var v = new Buffer(hlen) + v.fill(1) + var k = new Buffer(hlen) + k.fill(0) + k = createHmac(algo, k).update(v).update(new Buffer([ 0 ])).update(x).update(hbits).digest() + v = createHmac(algo, k).update(v).digest() + k = createHmac(algo, k).update(v).update(new Buffer([ 1 ])).update(x).update(hbits).digest() + v = createHmac(algo, k).update(v).digest() + return { k: k, v: v } +} + +function bits2int (obits, q) { + var bits = new BN(obits) + var shift = (obits.length << 3) - q.bitLength() + if (shift > 0) bits.ishrn(shift) + return bits +} + +function bits2octets (bits, q) { + bits = bits2int(bits, q) + bits = bits.mod(q) + var out = new Buffer(bits.toArray()) + if (out.length < q.byteLength()) { + var zeros = new Buffer(q.byteLength() - out.length) + zeros.fill(0) + out = Buffer.concat([ zeros, out ]) } + return out } -/** - * ReactChildReconciler provides helpers for initializing or updating a set of - * children. Its output is suitable for passing it onto ReactMultiChild which - * does diffed reordering and insertion. - */ -var ReactChildReconciler = { - /** - * Generates a "mount image" for each of the supplied children. In the case - * of `ReactDOMComponent`, a mount image is a string of markup. - * - * @param {?object} nestedChildNodes Nested child maps. - * @return {?object} A set of child instances. - * @internal - */ - instantiateChildren: function (nestedChildNodes, transaction, context, selfDebugID) // 0 in production and for roots - { - if (nestedChildNodes == null) { - return null; - } - var childInstances = {}; +function makeKey (q, kv, algo) { + var t + var k - if (process.env.NODE_ENV !== 'production') { - traverseAllChildren(nestedChildNodes, function (childInsts, child, name) { - return instantiateChild(childInsts, child, name, selfDebugID); - }, childInstances); - } else { - traverseAllChildren(nestedChildNodes, instantiateChild, childInstances); - } - return childInstances; - }, + do { + t = new Buffer(0) - /** - * Updates the rendered children and returns a new set of children. - * - * @param {?object} prevChildren Previously initialized set of children. - * @param {?object} nextChildren Flat child element maps. - * @param {ReactReconcileTransaction} transaction - * @param {object} context - * @return {?object} A new set of child instances. - * @internal - */ - updateChildren: function (prevChildren, nextChildren, mountImages, removedNodes, transaction, hostParent, hostContainerInfo, context, selfDebugID) // 0 in production and for roots - { - // We currently don't have a way to track moves here but if we use iterators - // instead of for..in we can zip the iterators and check if an item has - // moved. - // TODO: If nothing has changed, return the prevChildren object so that we - // can quickly bailout if nothing has changed. - if (!nextChildren && !prevChildren) { - return; - } - var name; - var prevChild; - for (name in nextChildren) { - if (!nextChildren.hasOwnProperty(name)) { - continue; - } - prevChild = prevChildren && prevChildren[name]; - var prevElement = prevChild && prevChild._currentElement; - var nextElement = nextChildren[name]; - if (prevChild != null && shouldUpdateReactComponent(prevElement, nextElement)) { - ReactReconciler.receiveComponent(prevChild, nextElement, transaction, context); - nextChildren[name] = prevChild; - } else { - if (prevChild) { - removedNodes[name] = ReactReconciler.getHostNode(prevChild); - ReactReconciler.unmountComponent(prevChild, false); - } - // The child must be instantiated before it's mounted. - var nextChildInstance = instantiateReactComponent(nextElement, true); - nextChildren[name] = nextChildInstance; - // Creating mount image now ensures refs are resolved in right order - // (see https://github.com/facebook/react/pull/7101 for explanation). - var nextChildMountImage = ReactReconciler.mountComponent(nextChildInstance, transaction, hostParent, hostContainerInfo, context, selfDebugID); - mountImages.push(nextChildMountImage); - } - } - // Unmount children that are no longer present. - for (name in prevChildren) { - if (prevChildren.hasOwnProperty(name) && !(nextChildren && nextChildren.hasOwnProperty(name))) { - prevChild = prevChildren[name]; - removedNodes[name] = ReactReconciler.getHostNode(prevChild); - ReactReconciler.unmountComponent(prevChild, false); - } + while (t.length * 8 < q.bitLength()) { + kv.v = createHmac(algo, kv.k).update(kv.v).digest() + t = Buffer.concat([ t, kv.v ]) } - }, - /** - * Unmounts all rendered children. This should be used to clean up children - * when this component is unmounted. - * - * @param {?object} renderedChildren Previously initialized set of children. - * @internal - */ - unmountChildren: function (renderedChildren, safely) { - for (var name in renderedChildren) { - if (renderedChildren.hasOwnProperty(name)) { - var renderedChild = renderedChildren[name]; - ReactReconciler.unmountComponent(renderedChild, safely); - } - } - } -}; + k = bits2int(t, q) + kv.k = createHmac(algo, kv.k).update(kv.v).update(new Buffer([ 0 ])).digest() + kv.v = createHmac(algo, kv.k).update(kv.v).digest() + } while (k.cmp(q) !== -1) -module.exports = ReactChildReconciler; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return k +} + +function makeR (g, k, p, q) { + return g.toRed(BN.mont(p)).redPow(k).fromRed().mod(q) +} + +module.exports = sign +module.exports.getKey = getKey +module.exports.makeKey = makeKey + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 176 */ +/* 439 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - +// from https://github.com/indutny/self-signed/blob/gh-pages/lib/asn1.js +// Fedor, you are amazing. + + +var asn1 = __webpack_require__(52) + +exports.certificate = __webpack_require__(450) + +var RSAPrivateKey = asn1.define('RSAPrivateKey', function () { + this.seq().obj( + this.key('version').int(), + this.key('modulus').int(), + this.key('publicExponent').int(), + this.key('privateExponent').int(), + this.key('prime1').int(), + this.key('prime2').int(), + this.key('exponent1').int(), + this.key('exponent2').int(), + this.key('coefficient').int() + ) +}) +exports.RSAPrivateKey = RSAPrivateKey + +var RSAPublicKey = asn1.define('RSAPublicKey', function () { + this.seq().obj( + this.key('modulus').int(), + this.key('publicExponent').int() + ) +}) +exports.RSAPublicKey = RSAPublicKey + +var PublicKey = asn1.define('SubjectPublicKeyInfo', function () { + this.seq().obj( + this.key('algorithm').use(AlgorithmIdentifier), + this.key('subjectPublicKey').bitstr() + ) +}) +exports.PublicKey = PublicKey + +var AlgorithmIdentifier = asn1.define('AlgorithmIdentifier', function () { + this.seq().obj( + this.key('algorithm').objid(), + this.key('none').null_().optional(), + this.key('curve').objid().optional(), + this.key('params').seq().obj( + this.key('p').int(), + this.key('q').int(), + this.key('g').int() + ).optional() + ) +}) + +var PrivateKeyInfo = asn1.define('PrivateKeyInfo', function () { + this.seq().obj( + this.key('version').int(), + this.key('algorithm').use(AlgorithmIdentifier), + this.key('subjectPrivateKey').octstr() + ) +}) +exports.PrivateKey = PrivateKeyInfo +var EncryptedPrivateKeyInfo = asn1.define('EncryptedPrivateKeyInfo', function () { + this.seq().obj( + this.key('algorithm').seq().obj( + this.key('id').objid(), + this.key('decrypt').seq().obj( + this.key('kde').seq().obj( + this.key('id').objid(), + this.key('kdeparams').seq().obj( + this.key('salt').octstr(), + this.key('iters').int() + ) + ), + this.key('cipher').seq().obj( + this.key('algo').objid(), + this.key('iv').octstr() + ) + ) + ), + this.key('subjectPrivateKey').octstr() + ) +}) + +exports.EncryptedPrivateKey = EncryptedPrivateKeyInfo + +var DSAPrivateKey = asn1.define('DSAPrivateKey', function () { + this.seq().obj( + this.key('version').int(), + this.key('p').int(), + this.key('q').int(), + this.key('g').int(), + this.key('pub_key').int(), + this.key('priv_key').int() + ) +}) +exports.DSAPrivateKey = DSAPrivateKey + +exports.DSAparam = asn1.define('DSAparam', function () { + this.int() +}) + +var ECPrivateKey = asn1.define('ECPrivateKey', function () { + this.seq().obj( + this.key('version').int(), + this.key('privateKey').octstr(), + this.key('parameters').optional().explicit(0).use(ECParameters), + this.key('publicKey').optional().explicit(1).bitstr() + ) +}) +exports.ECPrivateKey = ECPrivateKey + +var ECParameters = asn1.define('ECParameters', function () { + this.choice({ + namedCurve: this.objid() + }) +}) + +exports.signature = asn1.define('signature', function () { + this.seq().obj( + this.key('r').int(), + this.key('s').int() + ) +}) -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); -var React = __webpack_require__(24); -var ReactComponentEnvironment = __webpack_require__(59); -var ReactCurrentOwner = __webpack_require__(14); -var ReactErrorUtils = __webpack_require__(51); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactNodeTypes = __webpack_require__(97); -var ReactReconciler = __webpack_require__(26); +/***/ }), +/* 440 */ +/***/ (function(module, exports, __webpack_require__) { -if (process.env.NODE_ENV !== 'production') { - var checkReactTypeSpec = __webpack_require__(177); -} +var asn1 = __webpack_require__(52); +var inherits = __webpack_require__(4); -var emptyObject = __webpack_require__(39); -var invariant = __webpack_require__(1); -var shallowEqual = __webpack_require__(60); -var shouldUpdateReactComponent = __webpack_require__(61); -var warning = __webpack_require__(2); +var api = exports; -var CompositeTypes = { - ImpureClass: 0, - PureClass: 1, - StatelessFunctional: 2 +api.define = function define(name, body) { + return new Entity(name, body); }; -function StatelessComponent(Component) {} -StatelessComponent.prototype.render = function () { - var Component = ReactInstanceMap.get(this)._currentElement.type; - var element = Component(this.props, this.context, this.updater); - warnIfInvalidElement(Component, element); - return element; +function Entity(name, body) { + this.name = name; + this.body = body; + + this.decoders = {}; + this.encoders = {}; }; -function warnIfInvalidElement(Component, element) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(element === null || element === false || React.isValidElement(element), '%s(...): A valid React element (or null) must be returned. You may have ' + 'returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!Component.childContextTypes, '%s(...): childContextTypes cannot be defined on a functional component.', Component.displayName || Component.name || 'Component') : void 0; +Entity.prototype._createNamed = function createNamed(base) { + var named; + try { + named = __webpack_require__(441).runInThisContext( + '(function ' + this.name + '(entity) {\n' + + ' this._initNamed(entity);\n' + + '})' + ); + } catch (e) { + named = function (entity) { + this._initNamed(entity); + }; } -} - -function shouldConstruct(Component) { - return !!(Component.prototype && Component.prototype.isReactComponent); -} + inherits(named, base); + named.prototype._initNamed = function initnamed(entity) { + base.call(this, entity); + }; -function isPureComponent(Component) { - return !!(Component.prototype && Component.prototype.isPureReactComponent); -} + return new named(this); +}; -// Separated into a function to contain deoptimizations caused by try/finally. -function measureLifeCyclePerf(fn, debugID, timerType) { - if (debugID === 0) { - // Top-level wrappers (see ReactMount) and empty components (see - // ReactDOMEmptyComponent) are invisible to hooks and devtools. - // Both are implementation details that should go away in the future. - return fn(); - } +Entity.prototype._getDecoder = function _getDecoder(enc) { + enc = enc || 'der'; + // Lazily create decoder + if (!this.decoders.hasOwnProperty(enc)) + this.decoders[enc] = this._createNamed(asn1.decoders[enc]); + return this.decoders[enc]; +}; - ReactInstrumentation.debugTool.onBeginLifeCycleTimer(debugID, timerType); - try { - return fn(); - } finally { - ReactInstrumentation.debugTool.onEndLifeCycleTimer(debugID, timerType); - } -} +Entity.prototype.decode = function decode(data, enc, options) { + return this._getDecoder(enc).decode(data, options); +}; -/** - * ------------------ The Life-Cycle of a Composite Component ------------------ - * - * - constructor: Initialization of state. The instance is now retained. - * - componentWillMount - * - render - * - [children's constructors] - * - [children's componentWillMount and render] - * - [children's componentDidMount] - * - componentDidMount - * - * Update Phases: - * - componentWillReceiveProps (only called if parent updated) - * - shouldComponentUpdate - * - componentWillUpdate - * - render - * - [children's constructors or receive props phases] - * - componentDidUpdate - * - * - componentWillUnmount - * - [children's componentWillUnmount] - * - [children destroyed] - * - (destroyed): The instance is now blank, released by React and ready for GC. - * - * ----------------------------------------------------------------------------- - */ +Entity.prototype._getEncoder = function _getEncoder(enc) { + enc = enc || 'der'; + // Lazily create encoder + if (!this.encoders.hasOwnProperty(enc)) + this.encoders[enc] = this._createNamed(asn1.encoders[enc]); + return this.encoders[enc]; +}; -/** - * An incrementing ID assigned to each component when it is mounted. This is - * used to enforce the order in which `ReactUpdates` updates dirty components. - * - * @private - */ -var nextMountID = 1; +Entity.prototype.encode = function encode(data, enc, /* internal */ reporter) { + return this._getEncoder(enc).encode(data, reporter); +}; -/** - * @lends {ReactCompositeComponent.prototype} - */ -var ReactCompositeComponent = { - /** - * Base constructor for all composite component. - * - * @param {ReactElement} element - * @final - * @internal - */ - construct: function (element) { - this._currentElement = element; - this._rootNodeID = 0; - this._compositeType = null; - this._instance = null; - this._hostParent = null; - this._hostContainerInfo = null; - // See ReactUpdateQueue - this._updateBatchNumber = null; - this._pendingElement = null; - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; +/***/ }), +/* 441 */ +/***/ (function(module, exports, __webpack_require__) { - this._renderedNodeType = null; - this._renderedComponent = null; - this._context = null; - this._mountOrder = 0; - this._topLevelWrapper = null; +var indexOf = __webpack_require__(442); - // See ReactUpdates and ReactUpdateQueue. - this._pendingCallbacks = null; +var Object_keys = function (obj) { + if (Object.keys) return Object.keys(obj) + else { + var res = []; + for (var key in obj) res.push(key) + return res; + } +}; - // ComponentWillUnmount shall only be called once - this._calledComponentWillUnmount = false; +var forEach = function (xs, fn) { + if (xs.forEach) return xs.forEach(fn) + else for (var i = 0; i < xs.length; i++) { + fn(xs[i], i, xs); + } +}; - if (process.env.NODE_ENV !== 'production') { - this._warnedAboutRefsInRender = false; +var defineProp = (function() { + try { + Object.defineProperty({}, '_', {}); + return function(obj, name, value) { + Object.defineProperty(obj, name, { + writable: true, + enumerable: false, + configurable: true, + value: value + }) + }; + } catch(e) { + return function(obj, name, value) { + obj[name] = value; + }; } - }, +}()); - /** - * Initializes the component, renders markup, and registers event listeners. - * - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?object} hostParent - * @param {?object} hostContainerInfo - * @param {?object} context - * @return {?string} Rendered markup to be inserted into the DOM. - * @final - * @internal - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - var _this = this; +var globals = ['Array', 'Boolean', 'Date', 'Error', 'EvalError', 'Function', +'Infinity', 'JSON', 'Math', 'NaN', 'Number', 'Object', 'RangeError', +'ReferenceError', 'RegExp', 'String', 'SyntaxError', 'TypeError', 'URIError', +'decodeURI', 'decodeURIComponent', 'encodeURI', 'encodeURIComponent', 'escape', +'eval', 'isFinite', 'isNaN', 'parseFloat', 'parseInt', 'undefined', 'unescape']; - this._context = context; - this._mountOrder = nextMountID++; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; +function Context() {} +Context.prototype = {}; - var publicProps = this._currentElement.props; - var publicContext = this._processContext(context); +var Script = exports.Script = function NodeScript (code) { + if (!(this instanceof Script)) return new Script(code); + this.code = code; +}; - var Component = this._currentElement.type; +Script.prototype.runInContext = function (context) { + if (!(context instanceof Context)) { + throw new TypeError("needs a 'context' argument."); + } + + var iframe = document.createElement('iframe'); + if (!iframe.style) iframe.style = {}; + iframe.style.display = 'none'; + + document.body.appendChild(iframe); + + var win = iframe.contentWindow; + var wEval = win.eval, wExecScript = win.execScript; + + if (!wEval && wExecScript) { + // win.eval() magically appears when this is called in IE: + wExecScript.call(win, 'null'); + wEval = win.eval; + } + + forEach(Object_keys(context), function (key) { + win[key] = context[key]; + }); + forEach(globals, function (key) { + if (context[key]) { + win[key] = context[key]; + } + }); + + var winKeys = Object_keys(win); + + var res = wEval.call(win, this.code); + + forEach(Object_keys(win), function (key) { + // Avoid copying circular objects like `top` and `window` by only + // updating existing context properties or new properties in the `win` + // that was only introduced after the eval. + if (key in context || indexOf(winKeys, key) === -1) { + context[key] = win[key]; + } + }); - var updateQueue = transaction.getUpdateQueue(); + forEach(globals, function (key) { + if (!(key in context)) { + defineProp(context, key, win[key]); + } + }); + + document.body.removeChild(iframe); + + return res; +}; - // Initialize the public class - var doConstruct = shouldConstruct(Component); - var inst = this._constructComponent(doConstruct, publicProps, publicContext, updateQueue); - var renderedElement; +Script.prototype.runInThisContext = function () { + return eval(this.code); // maybe... +}; - // Support functional components - if (!doConstruct && (inst == null || inst.render == null)) { - renderedElement = inst; - warnIfInvalidElement(Component, renderedElement); - !(inst === null || inst === false || React.isValidElement(inst)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : _prodInvariant('105', Component.displayName || Component.name || 'Component') : void 0; - inst = new StatelessComponent(Component); - this._compositeType = CompositeTypes.StatelessFunctional; - } else { - if (isPureComponent(Component)) { - this._compositeType = CompositeTypes.PureClass; - } else { - this._compositeType = CompositeTypes.ImpureClass; - } - } +Script.prototype.runInNewContext = function (context) { + var ctx = Script.createContext(context); + var res = this.runInContext(ctx); - if (process.env.NODE_ENV !== 'production') { - // This will throw later in _renderValidatedComponent, but add an early - // warning now to help debugging - if (inst.render == null) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): No `render` method found on the returned component ' + 'instance: you may have forgotten to define `render`.', Component.displayName || Component.name || 'Component') : void 0; - } + forEach(Object_keys(ctx), function (key) { + context[key] = ctx[key]; + }); - var propsMutated = inst.props !== publicProps; - var componentName = Component.displayName || Component.name || 'Component'; + return res; +}; - process.env.NODE_ENV !== 'production' ? warning(inst.props === undefined || !propsMutated, '%s(...): When calling super() in `%s`, make sure to pass ' + "up the same props that your component's constructor was passed.", componentName, componentName) : void 0; - } +forEach(Object_keys(Script.prototype), function (name) { + exports[name] = Script[name] = function (code) { + var s = Script(code); + return s[name].apply(s, [].slice.call(arguments, 1)); + }; +}); - // These should be set up in the constructor, but as a convenience for - // simpler class abstractions, we set them up after the fact. - inst.props = publicProps; - inst.context = publicContext; - inst.refs = emptyObject; - inst.updater = updateQueue; +exports.createScript = function (code) { + return exports.Script(code); +}; - this._instance = inst; +exports.createContext = Script.createContext = function (context) { + var copy = new Context(); + if(typeof context === 'object') { + forEach(Object_keys(context), function (key) { + copy[key] = context[key]; + }); + } + return copy; +}; - // Store a reference from the instance back to the internal representation - ReactInstanceMap.set(inst, this); - if (process.env.NODE_ENV !== 'production') { - // Since plain JS classes are defined without any special initialization - // logic, we can not catch common errors early. Therefore, we have to - // catch them here, at initialization time, instead. - process.env.NODE_ENV !== 'production' ? warning(!inst.getInitialState || inst.getInitialState.isReactClassApproved || inst.state, 'getInitialState was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Did you mean to define a state property instead?', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.getDefaultProps || inst.getDefaultProps.isReactClassApproved, 'getDefaultProps was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Use a static property to define defaultProps instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.propTypes, 'propTypes was defined as an instance property on %s. Use a static ' + 'property to define propTypes instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.contextTypes, 'contextTypes was defined as an instance property on %s. Use a ' + 'static property to define contextTypes instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentShouldUpdate !== 'function', '%s has a method called ' + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + 'The name is phrased as a question because the function is ' + 'expected to return a value.', this.getName() || 'A component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentDidUnmount !== 'function', '%s has a method called ' + 'componentDidUnmount(). But there is no such lifecycle method. ' + 'Did you mean componentWillUnmount()?', this.getName() || 'A component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentWillRecieveProps !== 'function', '%s has a method called ' + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', this.getName() || 'A component') : void 0; - } +/***/ }), +/* 442 */ +/***/ (function(module, exports) { - var initialState = inst.state; - if (initialState === undefined) { - inst.state = initialState = null; - } - !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.state: must be set to an object or null', this.getName() || 'ReactCompositeComponent') : _prodInvariant('106', this.getName() || 'ReactCompositeComponent') : void 0; - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; +var indexOf = [].indexOf; - var markup; - if (inst.unstable_handleError) { - markup = this.performInitialMountWithErrorHandling(renderedElement, hostParent, hostContainerInfo, transaction, context); - } else { - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } +module.exports = function(arr, obj){ + if (indexOf) return arr.indexOf(obj); + for (var i = 0; i < arr.length; ++i) { + if (arr[i] === obj) return i; + } + return -1; +}; - if (inst.componentDidMount) { - if (process.env.NODE_ENV !== 'production') { - transaction.getReactMountReady().enqueue(function () { - measureLifeCyclePerf(function () { - return inst.componentDidMount(); - }, _this._debugID, 'componentDidMount'); - }); - } else { - transaction.getReactMountReady().enqueue(inst.componentDidMount, inst); - } - } +/***/ }), +/* 443 */ +/***/ (function(module, exports, __webpack_require__) { - return markup; - }, +var inherits = __webpack_require__(4); - _constructComponent: function (doConstruct, publicProps, publicContext, updateQueue) { - if (process.env.NODE_ENV !== 'production') { - ReactCurrentOwner.current = this; - try { - return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); - } finally { - ReactCurrentOwner.current = null; - } - } else { - return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); - } - }, +function Reporter(options) { + this._reporterState = { + obj: null, + path: [], + options: options || {}, + errors: [] + }; +} +exports.Reporter = Reporter; - _constructComponentWithoutOwner: function (doConstruct, publicProps, publicContext, updateQueue) { - var Component = this._currentElement.type; +Reporter.prototype.isError = function isError(obj) { + return obj instanceof ReporterError; +}; - if (doConstruct) { - if (process.env.NODE_ENV !== 'production') { - return measureLifeCyclePerf(function () { - return new Component(publicProps, publicContext, updateQueue); - }, this._debugID, 'ctor'); - } else { - return new Component(publicProps, publicContext, updateQueue); - } - } +Reporter.prototype.save = function save() { + var state = this._reporterState; - // This can still be an instance in case of factory components - // but we'll count this as time spent rendering as the more common case. - if (process.env.NODE_ENV !== 'production') { - return measureLifeCyclePerf(function () { - return Component(publicProps, publicContext, updateQueue); - }, this._debugID, 'render'); - } else { - return Component(publicProps, publicContext, updateQueue); - } - }, + return { obj: state.obj, pathLen: state.path.length }; +}; - performInitialMountWithErrorHandling: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { - var markup; - var checkpoint = transaction.checkpoint(); - try { - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } catch (e) { - // Roll back to checkpoint, handle error (which may add items to the transaction), and take a new checkpoint - transaction.rollback(checkpoint); - this._instance.unstable_handleError(e); - if (this._pendingStateQueue) { - this._instance.state = this._processPendingState(this._instance.props, this._instance.context); - } - checkpoint = transaction.checkpoint(); +Reporter.prototype.restore = function restore(data) { + var state = this._reporterState; - this._renderedComponent.unmountComponent(true); - transaction.rollback(checkpoint); + state.obj = data.obj; + state.path = state.path.slice(0, data.pathLen); +}; - // Try again - we've informed the component about the error, so they can render an error message this time. - // If this throws again, the error will bubble up (and can be caught by a higher error boundary). - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } - return markup; - }, +Reporter.prototype.enterKey = function enterKey(key) { + return this._reporterState.path.push(key); +}; - performInitialMount: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { - var inst = this._instance; +Reporter.prototype.exitKey = function exitKey(index) { + var state = this._reporterState; - var debugID = 0; - if (process.env.NODE_ENV !== 'production') { - debugID = this._debugID; - } + state.path = state.path.slice(0, index - 1); +}; - if (inst.componentWillMount) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillMount(); - }, debugID, 'componentWillMount'); - } else { - inst.componentWillMount(); - } - // When mounting, calls to `setState` by `componentWillMount` will set - // `this._pendingStateQueue` without triggering a re-render. - if (this._pendingStateQueue) { - inst.state = this._processPendingState(inst.props, inst.context); - } - } +Reporter.prototype.leaveKey = function leaveKey(index, key, value) { + var state = this._reporterState; - // If not a stateless component, we now render - if (renderedElement === undefined) { - renderedElement = this._renderValidatedComponent(); - } + this.exitKey(index); + if (state.obj !== null) + state.obj[key] = value; +}; - var nodeType = ReactNodeTypes.getType(renderedElement); - this._renderedNodeType = nodeType; - var child = this._instantiateReactComponent(renderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ - ); - this._renderedComponent = child; +Reporter.prototype.path = function path() { + return this._reporterState.path.join('/'); +}; - var markup = ReactReconciler.mountComponent(child, transaction, hostParent, hostContainerInfo, this._processChildContext(context), debugID); +Reporter.prototype.enterObject = function enterObject() { + var state = this._reporterState; - if (process.env.NODE_ENV !== 'production') { - if (debugID !== 0) { - var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; - ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); - } - } + var prev = state.obj; + state.obj = {}; + return prev; +}; - return markup; - }, +Reporter.prototype.leaveObject = function leaveObject(prev) { + var state = this._reporterState; - getHostNode: function () { - return ReactReconciler.getHostNode(this._renderedComponent); - }, + var now = state.obj; + state.obj = prev; + return now; +}; - /** - * Releases any resources allocated by `mountComponent`. - * - * @final - * @internal - */ - unmountComponent: function (safely) { - if (!this._renderedComponent) { - return; - } +Reporter.prototype.error = function error(msg) { + var err; + var state = this._reporterState; - var inst = this._instance; + var inherited = msg instanceof ReporterError; + if (inherited) { + err = msg; + } else { + err = new ReporterError(state.path.map(function(elem) { + return '[' + JSON.stringify(elem) + ']'; + }).join(''), msg.message || msg, msg.stack); + } - if (inst.componentWillUnmount && !inst._calledComponentWillUnmount) { - inst._calledComponentWillUnmount = true; + if (!state.options.partial) + throw err; - if (safely) { - var name = this.getName() + '.componentWillUnmount()'; - ReactErrorUtils.invokeGuardedCallback(name, inst.componentWillUnmount.bind(inst)); - } else { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillUnmount(); - }, this._debugID, 'componentWillUnmount'); - } else { - inst.componentWillUnmount(); - } - } - } + if (!inherited) + state.errors.push(err); - if (this._renderedComponent) { - ReactReconciler.unmountComponent(this._renderedComponent, safely); - this._renderedNodeType = null; - this._renderedComponent = null; - this._instance = null; - } + return err; +}; - // Reset pending fields - // Even if this component is scheduled for another update in ReactUpdates, - // it would still be ignored because these fields are reset. - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; - this._pendingCallbacks = null; - this._pendingElement = null; +Reporter.prototype.wrapResult = function wrapResult(result) { + var state = this._reporterState; + if (!state.options.partial) + return result; - // These fields do not really need to be reset since this object is no - // longer accessible. - this._context = null; - this._rootNodeID = 0; - this._topLevelWrapper = null; + return { + result: this.isError(result) ? null : result, + errors: state.errors + }; +}; - // Delete the reference from the instance to this internal representation - // which allow the internals to be properly cleaned up even if the user - // leaks a reference to the public instance. - ReactInstanceMap.remove(inst); +function ReporterError(path, msg) { + this.path = path; + this.rethrow(msg); +}; +inherits(ReporterError, Error); - // Some existing components rely on inst.props even after they've been - // destroyed (in event handlers). - // TODO: inst.props = null; - // TODO: inst.state = null; - // TODO: inst.context = null; - }, +ReporterError.prototype.rethrow = function rethrow(msg) { + this.message = msg + ' at: ' + (this.path || '(shallow)'); + if (Error.captureStackTrace) + Error.captureStackTrace(this, ReporterError); - /** - * Filters the context object to only contain keys specified in - * `contextTypes` - * - * @param {object} context - * @return {?object} - * @private - */ - _maskContext: function (context) { - var Component = this._currentElement.type; - var contextTypes = Component.contextTypes; - if (!contextTypes) { - return emptyObject; - } - var maskedContext = {}; - for (var contextName in contextTypes) { - maskedContext[contextName] = context[contextName]; + if (!this.stack) { + try { + // IE only adds stack when thrown + throw new Error(this.message); + } catch (e) { + this.stack = e.stack; } - return maskedContext; - }, + } + return this; +}; - /** - * Filters the context object to only contain keys specified in - * `contextTypes`, and asserts that they are valid. - * - * @param {object} context - * @return {?object} - * @private - */ - _processContext: function (context) { - var maskedContext = this._maskContext(context); - if (process.env.NODE_ENV !== 'production') { - var Component = this._currentElement.type; - if (Component.contextTypes) { - this._checkContextTypes(Component.contextTypes, maskedContext, 'context'); - } - } - return maskedContext; - }, - /** - * @param {object} currentContext - * @return {object} - * @private - */ - _processChildContext: function (currentContext) { - var Component = this._currentElement.type; - var inst = this._instance; - var childContext; +/***/ }), +/* 444 */ +/***/ (function(module, exports, __webpack_require__) { - if (inst.getChildContext) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onBeginProcessingChildContext(); - try { - childContext = inst.getChildContext(); - } finally { - ReactInstrumentation.debugTool.onEndProcessingChildContext(); - } - } else { - childContext = inst.getChildContext(); - } - } +var Reporter = __webpack_require__(53).Reporter; +var EncoderBuffer = __webpack_require__(53).EncoderBuffer; +var DecoderBuffer = __webpack_require__(53).DecoderBuffer; +var assert = __webpack_require__(21); + +// Supported tags +var tags = [ + 'seq', 'seqof', 'set', 'setof', 'objid', 'bool', + 'gentime', 'utctime', 'null_', 'enum', 'int', 'objDesc', + 'bitstr', 'bmpstr', 'charstr', 'genstr', 'graphstr', 'ia5str', 'iso646str', + 'numstr', 'octstr', 'printstr', 't61str', 'unistr', 'utf8str', 'videostr' +]; + +// Public methods list +var methods = [ + 'key', 'obj', 'use', 'optional', 'explicit', 'implicit', 'def', 'choice', + 'any', 'contains' +].concat(tags); + +// Overrided methods list +var overrided = [ + '_peekTag', '_decodeTag', '_use', + '_decodeStr', '_decodeObjid', '_decodeTime', + '_decodeNull', '_decodeInt', '_decodeBool', '_decodeList', + + '_encodeComposite', '_encodeStr', '_encodeObjid', '_encodeTime', + '_encodeNull', '_encodeInt', '_encodeBool' +]; + +function Node(enc, parent) { + var state = {}; + this._baseState = state; + + state.enc = enc; + + state.parent = parent || null; + state.children = null; + + // State + state.tag = null; + state.args = null; + state.reverseArgs = null; + state.choice = null; + state.optional = false; + state.any = false; + state.obj = false; + state.use = null; + state.useDecoder = null; + state.key = null; + state['default'] = null; + state.explicit = null; + state.implicit = null; + state.contains = null; + + // Should create new instance on each method + if (!state.parent) { + state.children = []; + this._wrap(); + } +} +module.exports = Node; + +var stateProps = [ + 'enc', 'parent', 'children', 'tag', 'args', 'reverseArgs', 'choice', + 'optional', 'any', 'obj', 'use', 'alteredUse', 'key', 'default', 'explicit', + 'implicit', 'contains' +]; + +Node.prototype.clone = function clone() { + var state = this._baseState; + var cstate = {}; + stateProps.forEach(function(prop) { + cstate[prop] = state[prop]; + }); + var res = new this.constructor(cstate.parent); + res._baseState = cstate; + return res; +}; + +Node.prototype._wrap = function wrap() { + var state = this._baseState; + methods.forEach(function(method) { + this[method] = function _wrappedMethod() { + var clone = new this.constructor(this); + state.children.push(clone); + return clone[method].apply(clone, arguments); + }; + }, this); +}; + +Node.prototype._init = function init(body) { + var state = this._baseState; - if (childContext) { - !(typeof Component.childContextTypes === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().', this.getName() || 'ReactCompositeComponent') : _prodInvariant('107', this.getName() || 'ReactCompositeComponent') : void 0; - if (process.env.NODE_ENV !== 'production') { - this._checkContextTypes(Component.childContextTypes, childContext, 'child context'); - } - for (var name in childContext) { - !(name in Component.childContextTypes) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): key "%s" is not defined in childContextTypes.', this.getName() || 'ReactCompositeComponent', name) : _prodInvariant('108', this.getName() || 'ReactCompositeComponent', name) : void 0; - } - return _assign({}, currentContext, childContext); - } - return currentContext; - }, + assert(state.parent === null); + body.call(this); - /** - * Assert that the context types are valid - * - * @param {object} typeSpecs Map of context field to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @private - */ - _checkContextTypes: function (typeSpecs, values, location) { - if (process.env.NODE_ENV !== 'production') { - checkReactTypeSpec(typeSpecs, values, location, this.getName(), null, this._debugID); - } - }, + // Filter children + state.children = state.children.filter(function(child) { + return child._baseState.parent === this; + }, this); + assert.equal(state.children.length, 1, 'Root node can have only one child'); +}; - receiveComponent: function (nextElement, transaction, nextContext) { - var prevElement = this._currentElement; - var prevContext = this._context; +Node.prototype._useArgs = function useArgs(args) { + var state = this._baseState; + + // Filter children and args + var children = args.filter(function(arg) { + return arg instanceof this.constructor; + }, this); + args = args.filter(function(arg) { + return !(arg instanceof this.constructor); + }, this); + + if (children.length !== 0) { + assert(state.children === null); + state.children = children; + + // Replace parent to maintain backward link + children.forEach(function(child) { + child._baseState.parent = this; + }, this); + } + if (args.length !== 0) { + assert(state.args === null); + state.args = args; + state.reverseArgs = args.map(function(arg) { + if (typeof arg !== 'object' || arg.constructor !== Object) + return arg; + + var res = {}; + Object.keys(arg).forEach(function(key) { + if (key == (key | 0)) + key |= 0; + var value = arg[key]; + res[value] = key; + }); + return res; + }); + } +}; - this._pendingElement = null; +// +// Overrided methods +// - this.updateComponent(transaction, prevElement, nextElement, prevContext, nextContext); - }, +overrided.forEach(function(method) { + Node.prototype[method] = function _overrided() { + var state = this._baseState; + throw new Error(method + ' not implemented for encoding: ' + state.enc); + }; +}); - /** - * If any of `_pendingElement`, `_pendingStateQueue`, or `_pendingForceUpdate` - * is set, update the component. - * - * @param {ReactReconcileTransaction} transaction - * @internal - */ - performUpdateIfNecessary: function (transaction) { - if (this._pendingElement != null) { - ReactReconciler.receiveComponent(this, this._pendingElement, transaction, this._context); - } else if (this._pendingStateQueue !== null || this._pendingForceUpdate) { - this.updateComponent(transaction, this._currentElement, this._currentElement, this._context, this._context); - } else { - this._updateBatchNumber = null; - } - }, +// +// Public methods +// - /** - * Perform an update to a mounted component. The componentWillReceiveProps and - * shouldComponentUpdate methods are called, then (assuming the update isn't - * skipped) the remaining update lifecycle methods are called and the DOM - * representation is updated. - * - * By default, this implements React's rendering and reconciliation algorithm. - * Sophisticated clients may wish to override this. - * - * @param {ReactReconcileTransaction} transaction - * @param {ReactElement} prevParentElement - * @param {ReactElement} nextParentElement - * @internal - * @overridable - */ - updateComponent: function (transaction, prevParentElement, nextParentElement, prevUnmaskedContext, nextUnmaskedContext) { - var inst = this._instance; - !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Attempted to update component `%s` that has already been unmounted (or failed to mount).', this.getName() || 'ReactCompositeComponent') : _prodInvariant('136', this.getName() || 'ReactCompositeComponent') : void 0; +tags.forEach(function(tag) { + Node.prototype[tag] = function _tagMethod() { + var state = this._baseState; + var args = Array.prototype.slice.call(arguments); - var willReceive = false; - var nextContext; + assert(state.tag === null); + state.tag = tag; - // Determine if the context has changed or not - if (this._context === nextUnmaskedContext) { - nextContext = inst.context; - } else { - nextContext = this._processContext(nextUnmaskedContext); - willReceive = true; - } + this._useArgs(args); - var prevProps = prevParentElement.props; - var nextProps = nextParentElement.props; + return this; + }; +}); - // Not a simple state update but a props update - if (prevParentElement !== nextParentElement) { - willReceive = true; - } +Node.prototype.use = function use(item) { + assert(item); + var state = this._baseState; - // An update here will schedule an update but immediately set - // _pendingStateQueue which will ensure that any state updates gets - // immediately reconciled instead of waiting for the next batch. - if (willReceive && inst.componentWillReceiveProps) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillReceiveProps(nextProps, nextContext); - }, this._debugID, 'componentWillReceiveProps'); - } else { - inst.componentWillReceiveProps(nextProps, nextContext); - } - } + assert(state.use === null); + state.use = item; - var nextState = this._processPendingState(nextProps, nextContext); - var shouldUpdate = true; + return this; +}; - if (!this._pendingForceUpdate) { - if (inst.shouldComponentUpdate) { - if (process.env.NODE_ENV !== 'production') { - shouldUpdate = measureLifeCyclePerf(function () { - return inst.shouldComponentUpdate(nextProps, nextState, nextContext); - }, this._debugID, 'shouldComponentUpdate'); - } else { - shouldUpdate = inst.shouldComponentUpdate(nextProps, nextState, nextContext); - } - } else { - if (this._compositeType === CompositeTypes.PureClass) { - shouldUpdate = !shallowEqual(prevProps, nextProps) || !shallowEqual(inst.state, nextState); - } - } - } +Node.prototype.optional = function optional() { + var state = this._baseState; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(shouldUpdate !== undefined, '%s.shouldComponentUpdate(): Returned undefined instead of a ' + 'boolean value. Make sure to return true or false.', this.getName() || 'ReactCompositeComponent') : void 0; - } + state.optional = true; - this._updateBatchNumber = null; - if (shouldUpdate) { - this._pendingForceUpdate = false; - // Will set `this.props`, `this.state` and `this.context`. - this._performComponentUpdate(nextParentElement, nextProps, nextState, nextContext, transaction, nextUnmaskedContext); - } else { - // If it's determined that a component should not update, we still want - // to set props and state but we shortcut the rest of the update. - this._currentElement = nextParentElement; - this._context = nextUnmaskedContext; - inst.props = nextProps; - inst.state = nextState; - inst.context = nextContext; - } - }, + return this; +}; - _processPendingState: function (props, context) { - var inst = this._instance; - var queue = this._pendingStateQueue; - var replace = this._pendingReplaceState; - this._pendingReplaceState = false; - this._pendingStateQueue = null; +Node.prototype.def = function def(val) { + var state = this._baseState; - if (!queue) { - return inst.state; - } + assert(state['default'] === null); + state['default'] = val; + state.optional = true; - if (replace && queue.length === 1) { - return queue[0]; - } + return this; +}; - var nextState = _assign({}, replace ? queue[0] : inst.state); - for (var i = replace ? 1 : 0; i < queue.length; i++) { - var partial = queue[i]; - _assign(nextState, typeof partial === 'function' ? partial.call(inst, nextState, props, context) : partial); - } +Node.prototype.explicit = function explicit(num) { + var state = this._baseState; - return nextState; - }, + assert(state.explicit === null && state.implicit === null); + state.explicit = num; - /** - * Merges new props and state, notifies delegate methods of update and - * performs update. - * - * @param {ReactElement} nextElement Next element - * @param {object} nextProps Next public object to set as properties. - * @param {?object} nextState Next object to set as state. - * @param {?object} nextContext Next public object to set as context. - * @param {ReactReconcileTransaction} transaction - * @param {?object} unmaskedContext - * @private - */ - _performComponentUpdate: function (nextElement, nextProps, nextState, nextContext, transaction, unmaskedContext) { - var _this2 = this; + return this; +}; - var inst = this._instance; +Node.prototype.implicit = function implicit(num) { + var state = this._baseState; - var hasComponentDidUpdate = Boolean(inst.componentDidUpdate); - var prevProps; - var prevState; - var prevContext; - if (hasComponentDidUpdate) { - prevProps = inst.props; - prevState = inst.state; - prevContext = inst.context; - } + assert(state.explicit === null && state.implicit === null); + state.implicit = num; - if (inst.componentWillUpdate) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillUpdate(nextProps, nextState, nextContext); - }, this._debugID, 'componentWillUpdate'); - } else { - inst.componentWillUpdate(nextProps, nextState, nextContext); - } - } + return this; +}; - this._currentElement = nextElement; - this._context = unmaskedContext; - inst.props = nextProps; - inst.state = nextState; - inst.context = nextContext; +Node.prototype.obj = function obj() { + var state = this._baseState; + var args = Array.prototype.slice.call(arguments); - this._updateRenderedComponent(transaction, unmaskedContext); + state.obj = true; - if (hasComponentDidUpdate) { - if (process.env.NODE_ENV !== 'production') { - transaction.getReactMountReady().enqueue(function () { - measureLifeCyclePerf(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), _this2._debugID, 'componentDidUpdate'); - }); - } else { - transaction.getReactMountReady().enqueue(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), inst); - } - } - }, + if (args.length !== 0) + this._useArgs(args); - /** - * Call the component's `render` method and update the DOM accordingly. - * - * @param {ReactReconcileTransaction} transaction - * @internal - */ - _updateRenderedComponent: function (transaction, context) { - var prevComponentInstance = this._renderedComponent; - var prevRenderedElement = prevComponentInstance._currentElement; - var nextRenderedElement = this._renderValidatedComponent(); + return this; +}; - var debugID = 0; - if (process.env.NODE_ENV !== 'production') { - debugID = this._debugID; - } +Node.prototype.key = function key(newKey) { + var state = this._baseState; - if (shouldUpdateReactComponent(prevRenderedElement, nextRenderedElement)) { - ReactReconciler.receiveComponent(prevComponentInstance, nextRenderedElement, transaction, this._processChildContext(context)); - } else { - var oldHostNode = ReactReconciler.getHostNode(prevComponentInstance); - ReactReconciler.unmountComponent(prevComponentInstance, false); + assert(state.key === null); + state.key = newKey; - var nodeType = ReactNodeTypes.getType(nextRenderedElement); - this._renderedNodeType = nodeType; - var child = this._instantiateReactComponent(nextRenderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ - ); - this._renderedComponent = child; + return this; +}; - var nextMarkup = ReactReconciler.mountComponent(child, transaction, this._hostParent, this._hostContainerInfo, this._processChildContext(context), debugID); +Node.prototype.any = function any() { + var state = this._baseState; - if (process.env.NODE_ENV !== 'production') { - if (debugID !== 0) { - var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; - ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); - } - } + state.any = true; - this._replaceNodeWithMarkup(oldHostNode, nextMarkup, prevComponentInstance); - } - }, + return this; +}; - /** - * Overridden in shallow rendering. - * - * @protected - */ - _replaceNodeWithMarkup: function (oldHostNode, nextMarkup, prevInstance) { - ReactComponentEnvironment.replaceNodeWithMarkup(oldHostNode, nextMarkup, prevInstance); - }, +Node.prototype.choice = function choice(obj) { + var state = this._baseState; - /** - * @protected - */ - _renderValidatedComponentWithoutOwnerOrContext: function () { - var inst = this._instance; - var renderedElement; + assert(state.choice === null); + state.choice = obj; + this._useArgs(Object.keys(obj).map(function(key) { + return obj[key]; + })); - if (process.env.NODE_ENV !== 'production') { - renderedElement = measureLifeCyclePerf(function () { - return inst.render(); - }, this._debugID, 'render'); - } else { - renderedElement = inst.render(); - } + return this; +}; - if (process.env.NODE_ENV !== 'production') { - // We allow auto-mocks to proceed as if they're returning null. - if (renderedElement === undefined && inst.render._isMockFunction) { - // This is probably bad practice. Consider warning here and - // deprecating this convenience. - renderedElement = null; - } - } +Node.prototype.contains = function contains(item) { + var state = this._baseState; - return renderedElement; - }, + assert(state.use === null); + state.contains = item; - /** - * @private - */ - _renderValidatedComponent: function () { - var renderedElement; - if (process.env.NODE_ENV !== 'production' || this._compositeType !== CompositeTypes.StatelessFunctional) { - ReactCurrentOwner.current = this; + return this; +}; + +// +// Decoding +// + +Node.prototype._decode = function decode(input, options) { + var state = this._baseState; + + // Decode root node + if (state.parent === null) + return input.wrapResult(state.children[0]._decode(input, options)); + + var result = state['default']; + var present = true; + + var prevKey = null; + if (state.key !== null) + prevKey = input.enterKey(state.key); + + // Check if tag is there + if (state.optional) { + var tag = null; + if (state.explicit !== null) + tag = state.explicit; + else if (state.implicit !== null) + tag = state.implicit; + else if (state.tag !== null) + tag = state.tag; + + if (tag === null && !state.any) { + // Trial and Error + var save = input.save(); try { - renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); - } finally { - ReactCurrentOwner.current = null; + if (state.choice === null) + this._decodeGeneric(state.tag, input, options); + else + this._decodeChoice(input, options); + present = true; + } catch (e) { + present = false; } + input.restore(save); } else { - renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); - } - !( - // TODO: An `isValidNode` function would probably be more appropriate - renderedElement === null || renderedElement === false || React.isValidElement(renderedElement)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.render(): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', this.getName() || 'ReactCompositeComponent') : _prodInvariant('109', this.getName() || 'ReactCompositeComponent') : void 0; - - return renderedElement; - }, + present = this._peekTag(input, tag, state.any); - /** - * Lazily allocates the refs object and stores `component` as `ref`. - * - * @param {string} ref Reference name. - * @param {component} component Component to store as `ref`. - * @final - * @private - */ - attachRef: function (ref, component) { - var inst = this.getPublicInstance(); - !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Stateless function components cannot have refs.') : _prodInvariant('110') : void 0; - var publicComponentInstance = component.getPublicInstance(); - if (process.env.NODE_ENV !== 'production') { - var componentName = component && component.getName ? component.getName() : 'a component'; - process.env.NODE_ENV !== 'production' ? warning(publicComponentInstance != null || component._compositeType !== CompositeTypes.StatelessFunctional, 'Stateless function components cannot be given refs ' + '(See ref "%s" in %s created by %s). ' + 'Attempts to access this ref will fail.', ref, componentName, this.getName()) : void 0; + if (input.isError(present)) + return present; } - var refs = inst.refs === emptyObject ? inst.refs = {} : inst.refs; - refs[ref] = publicComponentInstance; - }, - - /** - * Detaches a reference name. - * - * @param {string} ref Name to dereference. - * @final - * @private - */ - detachRef: function (ref) { - var refs = this.getPublicInstance().refs; - delete refs[ref]; - }, + } - /** - * Get a text description of the component that can be used to identify it - * in error messages. - * @return {string} The name or null. - * @internal - */ - getName: function () { - var type = this._currentElement.type; - var constructor = this._instance && this._instance.constructor; - return type.displayName || constructor && constructor.displayName || type.name || constructor && constructor.name || null; - }, + // Push object on stack + var prevObj; + if (state.obj && present) + prevObj = input.enterObject(); - /** - * Get the publicly accessible representation of this component - i.e. what - * is exposed by refs and returned by render. Can be null for stateless - * components. - * - * @return {ReactComponent} the public component instance. - * @internal - */ - getPublicInstance: function () { - var inst = this._instance; - if (this._compositeType === CompositeTypes.StatelessFunctional) { - return null; + if (present) { + // Unwrap explicit values + if (state.explicit !== null) { + var explicit = this._decodeTag(input, state.explicit); + if (input.isError(explicit)) + return explicit; + input = explicit; } - return inst; - }, - - // Stub - _instantiateReactComponent: null -}; -module.exports = ReactCompositeComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var start = input.offset; -/***/ }), -/* 177 */ -/***/ (function(module, exports, __webpack_require__) { + // Unwrap implicit and normal values + if (state.use === null && state.choice === null) { + if (state.any) + var save = input.save(); + var body = this._decodeTag( + input, + state.implicit !== null ? state.implicit : state.tag, + state.any + ); + if (input.isError(body)) + return body; + + if (state.any) + result = input.raw(save); + else + input = body; + } + + if (options && options.track && state.tag !== null) + options.track(input.path(), start, input.length, 'tagged'); + + if (options && options.track && state.tag !== null) + options.track(input.path(), input.offset, input.length, 'content'); + + // Select proper method for tag + if (state.any) + result = result; + else if (state.choice === null) + result = this._decodeGeneric(state.tag, input, options); + else + result = this._decodeChoice(input, options); + + if (input.isError(result)) + return result; + + // Decode children + if (!state.any && state.choice === null && state.children !== null) { + state.children.forEach(function decodeChildren(child) { + // NOTE: We are ignoring errors here, to let parser continue with other + // parts of encoded data + child._decode(input, options); + }); + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // Decode contained/encoded by schema, only in bit or octet strings + if (state.contains && (state.tag === 'octstr' || state.tag === 'bitstr')) { + var data = new DecoderBuffer(result); + result = this._getUse(state.contains, input._reporterState.obj) + ._decode(data, options); + } + } + // Pop object + if (state.obj && present) + result = input.leaveObject(prevObj); + // Set key + if (state.key !== null && (result !== null || present === true)) + input.leaveKey(prevKey, state.key, result); + else if (prevKey !== null) + input.exitKey(prevKey); -var _prodInvariant = __webpack_require__(3); + return result; +}; -var ReactPropTypeLocationNames = __webpack_require__(178); -var ReactPropTypesSecret = __webpack_require__(94); +Node.prototype._decodeGeneric = function decodeGeneric(tag, input, options) { + var state = this._baseState; -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); + if (tag === 'seq' || tag === 'set') + return null; + if (tag === 'seqof' || tag === 'setof') + return this._decodeList(input, tag, state.args[0], options); + else if (/str$/.test(tag)) + return this._decodeStr(input, tag, options); + else if (tag === 'objid' && state.args) + return this._decodeObjid(input, state.args[0], state.args[1], options); + else if (tag === 'objid') + return this._decodeObjid(input, null, null, options); + else if (tag === 'gentime' || tag === 'utctime') + return this._decodeTime(input, tag, options); + else if (tag === 'null_') + return this._decodeNull(input, options); + else if (tag === 'bool') + return this._decodeBool(input, options); + else if (tag === 'objDesc') + return this._decodeStr(input, tag, options); + else if (tag === 'int' || tag === 'enum') + return this._decodeInt(input, state.args && state.args[0], options); + + if (state.use !== null) { + return this._getUse(state.use, input._reporterState.obj) + ._decode(input, options); + } else { + return input.error('unknown tag: ' + tag); + } +}; -var ReactComponentTreeHook; +Node.prototype._getUse = function _getUse(entity, obj) { -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} + var state = this._baseState; + // Create altered use decoder if implicit is set + state.useDecoder = this._use(entity, obj); + assert(state.useDecoder._baseState.parent === null); + state.useDecoder = state.useDecoder._baseState.children[0]; + if (state.implicit !== state.useDecoder._baseState.implicit) { + state.useDecoder = state.useDecoder.clone(); + state.useDecoder._baseState.implicit = state.implicit; + } + return state.useDecoder; +}; -var loggedTypeFailures = {}; +Node.prototype._decodeChoice = function decodeChoice(input, options) { + var state = this._baseState; + var result = null; + var match = false; -/** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. - * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?object} element The React element that is being type-checked - * @param {?number} debugID The React component instance that is being type-checked - * @private - */ -function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; + Object.keys(state.choice).some(function(key) { + var save = input.save(); + var node = state.choice[key]; + try { + var value = node._decode(input, options); + if (input.isError(value)) + return false; - var componentStackInfo = ''; + result = { type: key, value: value }; + match = true; + } catch (e) { + input.restore(save); + return false; + } + return true; + }, this); - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (debugID !== null) { - componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); - } else if (element !== null) { - componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); - } - } + if (!match) + return input.error('Choice not matched'); - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; - } - } - } -} + return result; +}; -module.exports = checkReactTypeSpec; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +// +// Encoding +// -/***/ }), -/* 178 */ -/***/ (function(module, exports, __webpack_require__) { +Node.prototype._createEncoderBuffer = function createEncoderBuffer(data) { + return new EncoderBuffer(data, this.reporter); +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Node.prototype._encode = function encode(data, reporter, parent) { + var state = this._baseState; + if (state['default'] !== null && state['default'] === data) + return; + var result = this._encodeValue(data, reporter, parent); + if (result === undefined) + return; + if (this._skipDefault(result, reporter, parent)) + return; -var ReactPropTypeLocationNames = {}; + return result; +}; -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' - }; -} +Node.prototype._encodeValue = function encode(data, reporter, parent) { + var state = this._baseState; -module.exports = ReactPropTypeLocationNames; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // Decode root node + if (state.parent === null) + return state.children[0]._encode(data, reporter || new Reporter()); -/***/ }), -/* 179 */ -/***/ (function(module, exports, __webpack_require__) { + var result = null; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + // Set reporter to share it with a child class + this.reporter = reporter; + // Check if data is there + if (state.optional && data === undefined) { + if (state['default'] !== null) + data = state['default'] + else + return; + } + // Encode children first + var content = null; + var primitive = false; + if (state.any) { + // Anything that was given is translated to buffer + result = this._createEncoderBuffer(data); + } else if (state.choice) { + result = this._encodeChoice(data, reporter); + } else if (state.contains) { + content = this._getUse(state.contains, parent)._encode(data, reporter); + primitive = true; + } else if (state.children) { + content = state.children.map(function(child) { + if (child._baseState.tag === 'null_') + return child._encode(null, reporter, data); + + if (child._baseState.key === null) + return reporter.error('Child should have a key'); + var prevKey = reporter.enterKey(child._baseState.key); + + if (typeof data !== 'object') + return reporter.error('Child expected, but input is not object'); + + var res = child._encode(data[child._baseState.key], reporter, data); + reporter.leaveKey(prevKey); + + return res; + }, this).filter(function(child) { + return child; + }); + content = this._createEncoderBuffer(content); + } else { + if (state.tag === 'seqof' || state.tag === 'setof') { + // TODO(indutny): this should be thrown on DSL level + if (!(state.args && state.args.length === 1)) + return reporter.error('Too many args for : ' + state.tag); + + if (!Array.isArray(data)) + return reporter.error('seqof/setof, but data is not Array'); + + var child = this.clone(); + child._baseState.implicit = null; + content = this._createEncoderBuffer(data.map(function(item) { + var state = this._baseState; + + return this._getUse(state.args[0], data)._encode(item, reporter); + }, child)); + } else if (state.use !== null) { + result = this._getUse(state.use, parent)._encode(data, reporter); + } else { + content = this._encodePrimitive(state.tag, data); + primitive = true; + } + } -var nextDebugID = 1; + // Encode data itself + var result; + if (!state.any && state.choice === null) { + var tag = state.implicit !== null ? state.implicit : state.tag; + var cls = state.implicit === null ? 'universal' : 'context'; -function getNextDebugID() { - return nextDebugID++; -} + if (tag === null) { + if (state.use === null) + reporter.error('Tag could be ommited only for .use()'); + } else { + if (state.use === null) + result = this._encodeComposite(tag, primitive, cls, content); + } + } -module.exports = getNextDebugID; + // Wrap in explicit + if (state.explicit !== null) + result = this._encodeComposite(state.explicit, false, 'context', result); -/***/ }), -/* 180 */ -/***/ (function(module, exports, __webpack_require__) { + return result; +}; -"use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Node.prototype._encodeChoice = function encodeChoice(data, reporter) { + var state = this._baseState; + var node = state.choice[data.type]; + if (!node) { + assert( + false, + data.type + ' not found in ' + + JSON.stringify(Object.keys(state.choice))); + } + return node._encode(data.value, reporter); +}; +Node.prototype._encodePrimitive = function encodePrimitive(tag, data) { + var state = this._baseState; + + if (/str$/.test(tag)) + return this._encodeStr(data, tag); + else if (tag === 'objid' && state.args) + return this._encodeObjid(data, state.reverseArgs[0], state.args[1]); + else if (tag === 'objid') + return this._encodeObjid(data, null, null); + else if (tag === 'gentime' || tag === 'utctime') + return this._encodeTime(data, tag); + else if (tag === 'null_') + return this._encodeNull(); + else if (tag === 'int' || tag === 'enum') + return this._encodeInt(data, state.args && state.reverseArgs[0]); + else if (tag === 'bool') + return this._encodeBool(data); + else if (tag === 'objDesc') + return this._encodeStr(data, tag); + else + throw new Error('Unsupported tag: ' + tag); +}; -// The Symbol used to tag the ReactElement type. If there is no native Symbol -// nor polyfill, then a plain number is used for performance. +Node.prototype._isNumstr = function isNumstr(str) { + return /^[0-9 ]*$/.test(str); +}; -var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; +Node.prototype._isPrintstr = function isPrintstr(str) { + return /^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(str); +}; -module.exports = REACT_ELEMENT_TYPE; /***/ }), -/* 181 */ +/* 445 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var constants = __webpack_require__(192); +exports.tagClass = { + 0: 'universal', + 1: 'application', + 2: 'context', + 3: 'private' +}; +exports.tagClassByName = constants._reverse(exports.tagClass); + +exports.tag = { + 0x00: 'end', + 0x01: 'bool', + 0x02: 'int', + 0x03: 'bitstr', + 0x04: 'octstr', + 0x05: 'null_', + 0x06: 'objid', + 0x07: 'objDesc', + 0x08: 'external', + 0x09: 'real', + 0x0a: 'enum', + 0x0b: 'embed', + 0x0c: 'utf8str', + 0x0d: 'relativeOid', + 0x10: 'seq', + 0x11: 'set', + 0x12: 'numstr', + 0x13: 'printstr', + 0x14: 't61str', + 0x15: 'videostr', + 0x16: 'ia5str', + 0x17: 'utctime', + 0x18: 'gentime', + 0x19: 'graphstr', + 0x1a: 'iso646str', + 0x1b: 'genstr', + 0x1c: 'unistr', + 0x1d: 'charstr', + 0x1e: 'bmpstr' +}; +exports.tagByName = constants._reverse(exports.tag); -/* global Symbol */ +/***/ }), +/* 446 */ +/***/ (function(module, exports, __webpack_require__) { -var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; -var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. +var decoders = exports; -/** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } - * - * @param {?object} maybeIterable - * @return {?function} - */ -function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; - } -} +decoders.der = __webpack_require__(193); +decoders.pem = __webpack_require__(447); -module.exports = getIteratorFn; /***/ }), -/* 182 */ +/* 447 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var inherits = __webpack_require__(4); +var Buffer = __webpack_require__(1).Buffer; +var DERDecoder = __webpack_require__(193); +function PEMDecoder(entity) { + DERDecoder.call(this, entity); + this.enc = 'pem'; +}; +inherits(PEMDecoder, DERDecoder); +module.exports = PEMDecoder; -var KeyEscapeUtils = __webpack_require__(62); -var traverseAllChildren = __webpack_require__(100); -var warning = __webpack_require__(2); +PEMDecoder.prototype.decode = function decode(data, options) { + var lines = data.toString().split(/[\r\n]+/g); -var ReactComponentTreeHook; + var label = options.label.toUpperCase(); -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} + var re = /^-----(BEGIN|END) ([^-]+)-----$/; + var start = -1; + var end = -1; + for (var i = 0; i < lines.length; i++) { + var match = lines[i].match(re); + if (match === null) + continue; -/** - * @param {function} traverseContext Context passed through traversal. - * @param {?ReactComponent} child React child component. - * @param {!string} name String name of key path to child. - * @param {number=} selfDebugID Optional debugID of the current internal instance. - */ -function flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID) { - // We found a component instance. - if (traverseContext && typeof traverseContext === 'object') { - var result = traverseContext; - var keyUnique = result[name] === undefined; - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (!keyUnique) { - process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; - } - } - if (keyUnique && child != null) { - result[name] = child; + if (match[2] !== label) + continue; + + if (start === -1) { + if (match[1] !== 'BEGIN') + break; + start = i; + } else { + if (match[1] !== 'END') + break; + end = i; + break; } } -} + if (start === -1 || end === -1) + throw new Error('PEM section not found for: ' + label); -/** - * Flattens children that are typically specified as `props.children`. Any null - * children will not be included in the resulting object. - * @return {!object} flattened children keyed by name. - */ -function flattenChildren(children, selfDebugID) { - if (children == null) { - return children; - } - var result = {}; + var base64 = lines.slice(start + 1, end).join(''); + // Remove excessive symbols + base64.replace(/[^a-z0-9\+\/=]+/gi, ''); - if (process.env.NODE_ENV !== 'production') { - traverseAllChildren(children, function (traverseContext, child, name) { - return flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID); - }, result); - } else { - traverseAllChildren(children, flattenSingleChildIntoContext, result); - } - return result; -} + var input = new Buffer(base64, 'base64'); + return DERDecoder.prototype.decode.call(this, input, options); +}; -module.exports = flattenChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 183 */ +/* 448 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +var encoders = exports; +encoders.der = __webpack_require__(194); +encoders.pem = __webpack_require__(449); -var _assign = __webpack_require__(5); -var PooledClass = __webpack_require__(20); -var Transaction = __webpack_require__(41); -var ReactInstrumentation = __webpack_require__(13); -var ReactServerUpdateQueue = __webpack_require__(184); +/***/ }), +/* 449 */ +/***/ (function(module, exports, __webpack_require__) { -/** - * Executed within the scope of the `Transaction` instance. Consider these as - * being member methods, but with an implied ordering while being isolated from - * each other. - */ -var TRANSACTION_WRAPPERS = []; +var inherits = __webpack_require__(4); -if (process.env.NODE_ENV !== 'production') { - TRANSACTION_WRAPPERS.push({ - initialize: ReactInstrumentation.debugTool.onBeginFlush, - close: ReactInstrumentation.debugTool.onEndFlush - }); -} +var DEREncoder = __webpack_require__(194); -var noopCallbackQueue = { - enqueue: function () {} +function PEMEncoder(entity) { + DEREncoder.call(this, entity); + this.enc = 'pem'; +}; +inherits(PEMEncoder, DEREncoder); +module.exports = PEMEncoder; + +PEMEncoder.prototype.encode = function encode(data, options) { + var buf = DEREncoder.prototype.encode.call(this, data); + + var p = buf.toString('base64'); + var out = [ '-----BEGIN ' + options.label + '-----' ]; + for (var i = 0; i < p.length; i += 64) + out.push(p.slice(i, i + 64)); + out.push('-----END ' + options.label + '-----'); + return out.join('\n'); }; -/** - * @class ReactServerRenderingTransaction - * @param {boolean} renderToStaticMarkup - */ -function ReactServerRenderingTransaction(renderToStaticMarkup) { - this.reinitializeTransaction(); - this.renderToStaticMarkup = renderToStaticMarkup; - this.useCreateElement = false; - this.updateQueue = new ReactServerUpdateQueue(this); -} - -var Mixin = { - /** - * @see Transaction - * @abstract - * @final - * @return {array} Empty list of operation wrap procedures. - */ - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, - /** - * @return {object} The queue to collect `onDOMReady` callbacks with. - */ - getReactMountReady: function () { - return noopCallbackQueue; - }, +/***/ }), +/* 450 */ +/***/ (function(module, exports, __webpack_require__) { - /** - * @return {object} The queue to collect React async events. - */ - getUpdateQueue: function () { - return this.updateQueue; - }, +"use strict"; +// from https://github.com/Rantanen/node-dtls/blob/25a7dc861bda38cfeac93a723500eea4f0ac2e86/Certificate.js +// thanks to @Rantanen + + + +var asn = __webpack_require__(52) + +var Time = asn.define('Time', function () { + this.choice({ + utcTime: this.utctime(), + generalTime: this.gentime() + }) +}) + +var AttributeTypeValue = asn.define('AttributeTypeValue', function () { + this.seq().obj( + this.key('type').objid(), + this.key('value').any() + ) +}) + +var AlgorithmIdentifier = asn.define('AlgorithmIdentifier', function () { + this.seq().obj( + this.key('algorithm').objid(), + this.key('parameters').optional() + ) +}) + +var SubjectPublicKeyInfo = asn.define('SubjectPublicKeyInfo', function () { + this.seq().obj( + this.key('algorithm').use(AlgorithmIdentifier), + this.key('subjectPublicKey').bitstr() + ) +}) + +var RelativeDistinguishedName = asn.define('RelativeDistinguishedName', function () { + this.setof(AttributeTypeValue) +}) + +var RDNSequence = asn.define('RDNSequence', function () { + this.seqof(RelativeDistinguishedName) +}) + +var Name = asn.define('Name', function () { + this.choice({ + rdnSequence: this.use(RDNSequence) + }) +}) + +var Validity = asn.define('Validity', function () { + this.seq().obj( + this.key('notBefore').use(Time), + this.key('notAfter').use(Time) + ) +}) + +var Extension = asn.define('Extension', function () { + this.seq().obj( + this.key('extnID').objid(), + this.key('critical').bool().def(false), + this.key('extnValue').octstr() + ) +}) + +var TBSCertificate = asn.define('TBSCertificate', function () { + this.seq().obj( + this.key('version').explicit(0).int(), + this.key('serialNumber').int(), + this.key('signature').use(AlgorithmIdentifier), + this.key('issuer').use(Name), + this.key('validity').use(Validity), + this.key('subject').use(Name), + this.key('subjectPublicKeyInfo').use(SubjectPublicKeyInfo), + this.key('issuerUniqueID').implicit(1).bitstr().optional(), + this.key('subjectUniqueID').implicit(2).bitstr().optional(), + this.key('extensions').explicit(3).seqof(Extension).optional() + ) +}) + +var X509Certificate = asn.define('X509Certificate', function () { + this.seq().obj( + this.key('tbsCertificate').use(TBSCertificate), + this.key('signatureAlgorithm').use(AlgorithmIdentifier), + this.key('signatureValue').bitstr() + ) +}) + +module.exports = X509Certificate - /** - * `PooledClass` looks for this, and will invoke this before allowing this - * instance to be reused. - */ - destructor: function () {}, - checkpoint: function () {}, +/***/ }), +/* 451 */ +/***/ (function(module, exports) { - rollback: function () {} +module.exports = { + "2.16.840.1.101.3.4.1.1": "aes-128-ecb", + "2.16.840.1.101.3.4.1.2": "aes-128-cbc", + "2.16.840.1.101.3.4.1.3": "aes-128-ofb", + "2.16.840.1.101.3.4.1.4": "aes-128-cfb", + "2.16.840.1.101.3.4.1.21": "aes-192-ecb", + "2.16.840.1.101.3.4.1.22": "aes-192-cbc", + "2.16.840.1.101.3.4.1.23": "aes-192-ofb", + "2.16.840.1.101.3.4.1.24": "aes-192-cfb", + "2.16.840.1.101.3.4.1.41": "aes-256-ecb", + "2.16.840.1.101.3.4.1.42": "aes-256-cbc", + "2.16.840.1.101.3.4.1.43": "aes-256-ofb", + "2.16.840.1.101.3.4.1.44": "aes-256-cfb" }; -_assign(ReactServerRenderingTransaction.prototype, Transaction, Mixin); - -PooledClass.addPoolingTo(ReactServerRenderingTransaction); - -module.exports = ReactServerRenderingTransaction; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - /***/ }), -/* 184 */ +/* 452 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ - - - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +/* WEBPACK VAR INJECTION */(function(Buffer) {// adapted from https://github.com/apatil/pemstrip +var findProc = /Proc-Type: 4,ENCRYPTED\n\r?DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)\n\r?\n\r?([0-9A-z\n\r\+\/\=]+)\n\r?/m +var startRegex = /^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----\n/m +var fullRegex = /^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----\n\r?([0-9A-z\n\r\+\/\=]+)\n\r?-----END \1-----$/m +var evp = __webpack_require__(68) +var ciphers = __webpack_require__(108) +module.exports = function (okey, password) { + var key = okey.toString() + var match = key.match(findProc) + var decrypted + if (!match) { + var match2 = key.match(fullRegex) + decrypted = new Buffer(match2[2].replace(/\r?\n/g, ''), 'base64') + } else { + var suite = 'aes' + match[1] + var iv = new Buffer(match[2], 'hex') + var cipherText = new Buffer(match[3].replace(/\r?\n/g, ''), 'base64') + var cipherKey = evp(password, iv.slice(0, 8), parseInt(match[1], 10)).key + var out = [] + var cipher = ciphers.createDecipheriv(suite, cipherKey, iv) + out.push(cipher.update(cipherText)) + out.push(cipher.final()) + decrypted = Buffer.concat(out) + } + var tag = key.match(startRegex)[1] + return { + tag: tag, + data: decrypted + } +} -var ReactUpdateQueue = __webpack_require__(63); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var warning = __webpack_require__(2); +/***/ }), +/* 453 */ +/***/ (function(module, exports, __webpack_require__) { -function warnNoop(publicInstance, callerName) { - if (process.env.NODE_ENV !== 'production') { - var constructor = publicInstance.constructor; - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounting component. ' + 'This usually means you called %s() outside componentWillMount() on the server. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; - } +/* WEBPACK VAR INJECTION */(function(Buffer) {// much of this based on https://github.com/indutny/self-signed/blob/gh-pages/lib/rsa.js +var BN = __webpack_require__(11) +var EC = __webpack_require__(15).ec +var parseKeys = __webpack_require__(72) +var curves = __webpack_require__(195) + +function verify (sig, hash, key, signType, tag) { + var pub = parseKeys(key) + if (pub.type === 'ec') { + // rsa keys can be interpreted as ecdsa ones in openssl + if (signType !== 'ecdsa' && signType !== 'ecdsa/rsa') throw new Error('wrong public key type') + return ecVerify(sig, hash, pub) + } else if (pub.type === 'dsa') { + if (signType !== 'dsa') throw new Error('wrong public key type') + return dsaVerify(sig, hash, pub) + } else { + if (signType !== 'rsa' && signType !== 'ecdsa/rsa') throw new Error('wrong public key type') + } + hash = Buffer.concat([tag, hash]) + var len = pub.modulus.byteLength() + var pad = [ 1 ] + var padNum = 0 + while (hash.length + pad.length + 2 < len) { + pad.push(0xff) + padNum++ + } + pad.push(0x00) + var i = -1 + while (++i < hash.length) { + pad.push(hash[i]) + } + pad = new Buffer(pad) + var red = BN.mont(pub.modulus) + sig = new BN(sig).toRed(red) + + sig = sig.redPow(new BN(pub.publicExponent)) + sig = new Buffer(sig.fromRed().toArray()) + var out = padNum < 8 ? 1 : 0 + len = Math.min(sig.length, pad.length) + if (sig.length !== pad.length) out = 1 + + i = -1 + while (++i < len) out |= sig[i] ^ pad[i] + return out === 0 } -/** - * This is the update queue used for server rendering. - * It delegates to ReactUpdateQueue while server rendering is in progress and - * switches to ReactNoopUpdateQueue after the transaction has completed. - * @class ReactServerUpdateQueue - * @param {Transaction} transaction - */ +function ecVerify (sig, hash, pub) { + var curveId = curves[pub.data.algorithm.curve.join('.')] + if (!curveId) throw new Error('unknown curve ' + pub.data.algorithm.curve.join('.')) -var ReactServerUpdateQueue = function () { - function ReactServerUpdateQueue(transaction) { - _classCallCheck(this, ReactServerUpdateQueue); + var curve = new EC(curveId) + var pubkey = pub.data.subjectPrivateKey.data - this.transaction = transaction; - } + return curve.verify(hash, sig, pubkey) +} - /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ +function dsaVerify (sig, hash, pub) { + var p = pub.data.p + var q = pub.data.q + var g = pub.data.g + var y = pub.data.pub_key + var unpacked = parseKeys.signature.decode(sig, 'der') + var s = unpacked.s + var r = unpacked.r + checkValue(s, q) + checkValue(r, q) + var montp = BN.mont(p) + var w = s.invm(q) + var v = g.toRed(montp) + .redPow(new BN(hash).mul(w).mod(q)) + .fromRed() + .mul(y.toRed(montp).redPow(r.mul(w).mod(q)).fromRed()) + .mod(p) + .mod(q) + return v.cmp(r) === 0 +} +function checkValue (b, q) { + if (b.cmpn(0) <= 0) throw new Error('invalid sig') + if (b.cmp(q) >= q) throw new Error('invalid sig') +} - ReactServerUpdateQueue.prototype.isMounted = function isMounted(publicInstance) { - return false; - }; +module.exports = verify - /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. - * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @internal - */ +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) +/***/ }), +/* 454 */ +/***/ (function(module, exports, __webpack_require__) { - ReactServerUpdateQueue.prototype.enqueueCallback = function enqueueCallback(publicInstance, callback, callerName) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueCallback(publicInstance, callback, callerName); - } - }; +/* WEBPACK VAR INJECTION */(function(Buffer) {var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal - */ +module.exports = function createECDH(curve) { + return new ECDH(curve); +}; +var aliases = { + secp256k1: { + name: 'secp256k1', + byteLength: 32 + }, + secp224r1: { + name: 'p224', + byteLength: 28 + }, + prime256v1: { + name: 'p256', + byteLength: 32 + }, + prime192v1: { + name: 'p192', + byteLength: 24 + }, + ed25519: { + name: 'ed25519', + byteLength: 32 + }, + secp384r1: { + name: 'p384', + byteLength: 48 + }, + secp521r1: { + name: 'p521', + byteLength: 66 + } +}; - ReactServerUpdateQueue.prototype.enqueueForceUpdate = function enqueueForceUpdate(publicInstance) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueForceUpdate(publicInstance); - } else { - warnNoop(publicInstance, 'forceUpdate'); - } - }; +aliases.p224 = aliases.secp224r1; +aliases.p256 = aliases.secp256r1 = aliases.prime256v1; +aliases.p192 = aliases.secp192r1 = aliases.prime192v1; +aliases.p384 = aliases.secp384r1; +aliases.p521 = aliases.secp521r1; + +function ECDH(curve) { + this.curveType = aliases[curve]; + if (!this.curveType ) { + this.curveType = { + name: curve + }; + } + this.curve = new elliptic.ec(this.curveType.name); + this.keys = void 0; +} - /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object|function} completeState Next state. - * @internal - */ +ECDH.prototype.generateKeys = function (enc, format) { + this.keys = this.curve.genKeyPair(); + return this.getPublicKey(enc, format); +}; +ECDH.prototype.computeSecret = function (other, inenc, enc) { + inenc = inenc || 'utf8'; + if (!Buffer.isBuffer(other)) { + other = new Buffer(other, inenc); + } + var otherPub = this.curve.keyFromPublic(other).getPublic(); + var out = otherPub.mul(this.keys.getPrivate()).getX(); + return formatReturnValue(out, enc, this.curveType.byteLength); +}; - ReactServerUpdateQueue.prototype.enqueueReplaceState = function enqueueReplaceState(publicInstance, completeState) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueReplaceState(publicInstance, completeState); - } else { - warnNoop(publicInstance, 'replaceState'); - } - }; +ECDH.prototype.getPublicKey = function (enc, format) { + var key = this.keys.getPublic(format === 'compressed', true); + if (format === 'hybrid') { + if (key[key.length - 1] % 2) { + key[0] = 7; + } else { + key [0] = 6; + } + } + return formatReturnValue(key, enc); +}; - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object|function} partialState Next partial state to be merged with state. - * @internal - */ +ECDH.prototype.getPrivateKey = function (enc) { + return formatReturnValue(this.keys.getPrivate(), enc); +}; +ECDH.prototype.setPublicKey = function (pub, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(pub)) { + pub = new Buffer(pub, enc); + } + this.keys._importPublic(pub); + return this; +}; - ReactServerUpdateQueue.prototype.enqueueSetState = function enqueueSetState(publicInstance, partialState) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueSetState(publicInstance, partialState); - } else { - warnNoop(publicInstance, 'setState'); - } - }; +ECDH.prototype.setPrivateKey = function (priv, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(priv)) { + priv = new Buffer(priv, enc); + } + var _priv = new BN(priv); + _priv = _priv.toString(16); + this.keys._importPrivate(_priv); + return this; +}; - return ReactServerUpdateQueue; -}(); +function formatReturnValue(bn, enc, len) { + if (!Array.isArray(bn)) { + bn = bn.toArray(); + } + var buf = new Buffer(bn); + if (len && buf.length < len) { + var zeros = new Buffer(len - buf.length); + zeros.fill(0); + buf = Buffer.concat([zeros, buf]); + } + if (!enc) { + return buf; + } else { + return buf.toString(enc); + } +} -module.exports = ReactServerUpdateQueue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 185 */ +/* 455 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +exports.publicEncrypt = __webpack_require__(456); +exports.privateDecrypt = __webpack_require__(457); +exports.privateEncrypt = function privateEncrypt(key, buf) { + return exports.publicEncrypt(key, buf, true); +}; -var _assign = __webpack_require__(5); +exports.publicDecrypt = function publicDecrypt(key, buf) { + return exports.privateDecrypt(key, buf, true); +}; -var DOMLazyTree = __webpack_require__(27); -var ReactDOMComponentTree = __webpack_require__(6); +/***/ }), +/* 456 */ +/***/ (function(module, exports, __webpack_require__) { -var ReactDOMEmptyComponent = function (instantiate) { - // ReactCompositeComponent uses this: - this._currentElement = null; - // ReactDOMComponentTree uses these: - this._hostNode = null; - this._hostParent = null; - this._hostContainerInfo = null; - this._domID = 0; +/* WEBPACK VAR INJECTION */(function(Buffer) {var parseKeys = __webpack_require__(72); +var randomBytes = __webpack_require__(43); +var createHash = __webpack_require__(27); +var mgf = __webpack_require__(196); +var xor = __webpack_require__(197); +var bn = __webpack_require__(11); +var withPublic = __webpack_require__(198); +var crt = __webpack_require__(110); + +var constants = { + RSA_PKCS1_OAEP_PADDING: 4, + RSA_PKCS1_PADDIN: 1, + RSA_NO_PADDING: 3 }; -_assign(ReactDOMEmptyComponent.prototype, { - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - var domID = hostContainerInfo._idCounter++; - this._domID = domID; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; - var nodeValue = ' react-empty: ' + this._domID + ' '; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var node = ownerDocument.createComment(nodeValue); - ReactDOMComponentTree.precacheNode(this, node); - return DOMLazyTree(node); - } else { - if (transaction.renderToStaticMarkup) { - // Normally we'd insert a comment node, but since this is a situation - // where React won't take over (static pages), we can simply return - // nothing. - return ''; - } - return '<!--' + nodeValue + '-->'; +module.exports = function publicEncrypt(public_key, msg, reverse) { + var padding; + if (public_key.padding) { + padding = public_key.padding; + } else if (reverse) { + padding = 1; + } else { + padding = 4; + } + var key = parseKeys(public_key); + var paddedMsg; + if (padding === 4) { + paddedMsg = oaep(key, msg); + } else if (padding === 1) { + paddedMsg = pkcs1(key, msg, reverse); + } else if (padding === 3) { + paddedMsg = new bn(msg); + if (paddedMsg.cmp(key.modulus) >= 0) { + throw new Error('data too long for modulus'); } - }, - receiveComponent: function () {}, - getHostNode: function () { - return ReactDOMComponentTree.getNodeFromInstance(this); - }, - unmountComponent: function () { - ReactDOMComponentTree.uncacheNode(this); + } else { + throw new Error('unknown padding'); } -}); + if (reverse) { + return crt(paddedMsg, key); + } else { + return withPublic(paddedMsg, key); + } +}; -module.exports = ReactDOMEmptyComponent; +function oaep(key, msg){ + var k = key.modulus.byteLength(); + var mLen = msg.length; + var iHash = createHash('sha1').update(new Buffer('')).digest(); + var hLen = iHash.length; + var hLen2 = 2 * hLen; + if (mLen > k - hLen2 - 2) { + throw new Error('message too long'); + } + var ps = new Buffer(k - mLen - hLen2 - 2); + ps.fill(0); + var dblen = k - hLen - 1; + var seed = randomBytes(hLen); + var maskedDb = xor(Buffer.concat([iHash, ps, new Buffer([1]), msg], dblen), mgf(seed, dblen)); + var maskedSeed = xor(seed, mgf(maskedDb, hLen)); + return new bn(Buffer.concat([new Buffer([0]), maskedSeed, maskedDb], k)); +} +function pkcs1(key, msg, reverse){ + var mLen = msg.length; + var k = key.modulus.byteLength(); + if (mLen > k - 11) { + throw new Error('message too long'); + } + var ps; + if (reverse) { + ps = new Buffer(k - mLen - 3); + ps.fill(0xff); + } else { + ps = nonZero(k - mLen - 3); + } + return new bn(Buffer.concat([new Buffer([0, reverse?1:2]), ps, new Buffer([0]), msg], k)); +} +function nonZero(len, crypto) { + var out = new Buffer(len); + var i = 0; + var cache = randomBytes(len*2); + var cur = 0; + var num; + while (i < len) { + if (cur === cache.length) { + cache = randomBytes(len*2); + cur = 0; + } + num = cache[cur++]; + if (num) { + out[i++] = num; + } + } + return out; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 186 */ +/* 457 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) {var parseKeys = __webpack_require__(72); +var mgf = __webpack_require__(196); +var xor = __webpack_require__(197); +var bn = __webpack_require__(11); +var crt = __webpack_require__(110); +var createHash = __webpack_require__(27); +var withPublic = __webpack_require__(198); +module.exports = function privateDecrypt(private_key, enc, reverse) { + var padding; + if (private_key.padding) { + padding = private_key.padding; + } else if (reverse) { + padding = 1; + } else { + padding = 4; + } + + var key = parseKeys(private_key); + var k = key.modulus.byteLength(); + if (enc.length > k || new bn(enc).cmp(key.modulus) >= 0) { + throw new Error('decryption error'); + } + var msg; + if (reverse) { + msg = withPublic(new bn(enc), key); + } else { + msg = crt(enc, key); + } + var zBuffer = new Buffer(k - msg.length); + zBuffer.fill(0); + msg = Buffer.concat([zBuffer, msg], k); + if (padding === 4) { + return oaep(key, msg); + } else if (padding === 1) { + return pkcs1(key, msg, reverse); + } else if (padding === 3) { + return msg; + } else { + throw new Error('unknown padding'); + } +}; +function oaep(key, msg){ + var n = key.modulus; + var k = key.modulus.byteLength(); + var mLen = msg.length; + var iHash = createHash('sha1').update(new Buffer('')).digest(); + var hLen = iHash.length; + var hLen2 = 2 * hLen; + if (msg[0] !== 0) { + throw new Error('decryption error'); + } + var maskedSeed = msg.slice(1, hLen + 1); + var maskedDb = msg.slice(hLen + 1); + var seed = xor(maskedSeed, mgf(maskedDb, hLen)); + var db = xor(maskedDb, mgf(seed, k - hLen - 1)); + if (compare(iHash, db.slice(0, hLen))) { + throw new Error('decryption error'); + } + var i = hLen; + while (db[i] === 0) { + i++; + } + if (db[i++] !== 1) { + throw new Error('decryption error'); + } + return db.slice(i); +} +function pkcs1(key, msg, reverse){ + var p1 = msg.slice(0, 2); + var i = 2; + var status = 0; + while (msg[i++] !== 0) { + if (i >= msg.length) { + status++; + break; + } + } + var ps = msg.slice(2, i - 1); + var p2 = msg.slice(i - 1, i); -var _prodInvariant = __webpack_require__(3); + if ((p1.toString('hex') !== '0002' && !reverse) || (p1.toString('hex') !== '0001' && reverse)){ + status++; + } + if (ps.length < 8) { + status++; + } + if (status) { + throw new Error('decryption error'); + } + return msg.slice(i); +} +function compare(a, b){ + a = new Buffer(a); + b = new Buffer(b); + var dif = 0; + var len = a.length; + if (a.length !== b.length) { + dif++; + len = Math.min(a.length, b.length); + } + var i = -1; + while (++i < len) { + dif += (a[i] ^ b[i]); + } + return dif; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var invariant = __webpack_require__(1); +/***/ }), +/* 458 */ +/***/ (function(module, exports, __webpack_require__) { -/** - * Return the lowest common ancestor of A and B, or null if they are in - * different trees. +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33); +var secp256k1 = __webpack_require__(168); +var int64buffer = __webpack_require__(459); +var varuint = __webpack_require__(73); +var zconfig = __webpack_require__(66); +var zbufferutils = __webpack_require__(199); +var zcrypto = __webpack_require__(107); +var zconstants = __webpack_require__(460); +var zaddress = __webpack_require__(96); +var zopcodes = __webpack_require__(461); +var zbufferutils = __webpack_require__(199); + +/* More info: https://github.com/ZencashOfficial/zen/blob/master/src/script/standard.cpp#L377 + * Given an address, generates a pubkeyhash replay type script needed for the transaction + * @param {String} address + * @param {Number} blockHeight + * @param {Number} blockHash + * @param {String} pubKeyHash (optional) + * return {String} pubKeyScript */ -function getLowestCommonAncestor(instA, instB) { - !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; - !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; +function mkPubkeyHashReplayScript(address, blockHeight, blockHash, pubKeyHash) { + // Get lengh of pubKeyHash (so we know where to substr later on) + pubKeyHash = pubKeyHash || zconfig.mainnet.pubKeyHash; - var depthA = 0; - for (var tempA = instA; tempA; tempA = tempA._hostParent) { - depthA++; - } - var depthB = 0; - for (var tempB = instB; tempB; tempB = tempB._hostParent) { - depthB++; - } + var addrHex = bs58check.decode(address).toString('hex'); - // If A is deeper, crawl up. - while (depthA - depthB > 0) { - instA = instA._hostParent; - depthA--; - } + // Cut out pubKeyHash + var subAddrHex = addrHex.substring(pubKeyHash.length, addrHex.length); - // If B is deeper, crawl up. - while (depthB - depthA > 0) { - instB = instB._hostParent; - depthB--; + // Minimal encoding + var blockHeightBuffer = Buffer.alloc(4); + blockHeightBuffer.writeUInt32LE(blockHeight, 0); + if (blockHeightBuffer[3] === 0x00) { + blockHeightBuffer = blockHeightBuffer.slice(0, 3); } + var blockHeightHex = blockHeightBuffer.toString('hex'); - // Walk in lockstep until we find a match. - var depth = depthA; - while (depth--) { - if (instA === instB) { - return instA; - } - instA = instA._hostParent; - instB = instB._hostParent; - } - return null; + // block hash is encoded in little indian + var blockHashHex = Buffer.from(blockHash, 'hex').reverse().toString('hex'); + + // '14' is the length of the subAddrHex (in bytes) + return zopcodes.OP_DUP + zopcodes.OP_HASH160 + zbufferutils.getStringBufferLength(subAddrHex) + subAddrHex + zopcodes.OP_EQUALVERIFY + zopcodes.OP_CHECKSIG + zbufferutils.getStringBufferLength(blockHashHex) + blockHashHex + zbufferutils.getStringBufferLength(blockHeightHex) + blockHeightHex + zopcodes.OP_CHECKBLOCKATHEIGHT; } -/** - * Return if A is an ancestor of B. +/* + * Given an address, generates a script hash replay type script needed for the transaction + * @param {String} address + * @param {Number} blockHeight + * @param {Number} blockHash + * return {String} scriptHash script */ -function isAncestor(instA, instB) { - !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; - !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; +function mkScriptHashReplayScript(address, blockHeight, blockHash) { + var addrHex = bs58check.decode(address).toString('hex'); + var subAddrHex = addrHex.substring(4, addrHex.length); // Cut out the '00' (we also only want 14 bytes instead of 16) - while (instB) { - if (instB === instA) { - return true; - } - instB = instB._hostParent; + var blockHeightBuffer = Buffer.alloc(4); + blockHeightBuffer.writeUInt32LE(blockHeight, 0); + if (blockHeightBuffer[3] === 0x00) { + blockHeightBuffer = blockHeightBuffer.slice(0, 3); } - return false; + var blockHeightHex = blockHeightBuffer.toString('hex'); + + // Need to reverse it + var blockHashHex = Buffer.from(blockHash, 'hex').reverse().toString('hex'); + + // '14' is the length of the subAddrHex (in bytes) + return zopcodes.OP_HASH160 + zbufferutils.getStringBufferLength(subAddrHex) + subAddrHex + zopcodes.OP_EQUAL + zbufferutils.getStringBufferLength(blockHashHex) + blockHashHex + zbufferutils.getStringBufferLength(blockHeightHex) + blockHeightHex + zopcodes.OP_CHECKBLOCKATHEIGHT; } -/** - * Return the parent instance of the passed-in instance. +/* + * Given an address, generates an output script + * @param {String} address + * @param {Number} blockHeight + * @param {Number} blockHash + * return {String} output script */ -function getParentInstance(inst) { - !('_hostNode' in inst) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getParentInstance: Invalid argument.') : _prodInvariant('36') : void 0; +function addressToScript(address, blockHeight, blockHash) { + // P2SH replay starts with a 's', or 't' + if (address[1] === 's' || address[0] === 't') { + return mkScriptHashReplayScript(address, blockHeight, blockHash); + } - return inst._hostParent; + // P2PKH-replay is a replacement for P2PKH + // P2PKH-replay starts with a 0 + return mkPubkeyHashReplayScript(address, blockHeight, blockHash); } -/** - * Simulates the traversal of a two-phase, capture/bubble event dispatch. +/* + * Signature hashing for TXOBJ + * @param {String} address + * @param {Number} i, which transaction input to sign + * @param {String} hex string of script + * @param {String} hash code (SIGHASH_ALL, SIGHASH_NONE...) + * return {String} output script */ -function traverseTwoPhase(inst, fn, arg) { - var path = []; - while (inst) { - path.push(inst); - inst = inst._hostParent; - } - var i; - for (i = path.length; i-- > 0;) { - fn(path[i], 'captured', arg); +function signatureForm(txObj, i, script, hashcode) { + // Copy object so we don't rewrite it + var newTx = JSON.parse(JSON.stringify(txObj)); + + for (var j = 0; j < newTx.ins.length; j++) { + newTx.ins[j].script = ''; } - for (i = 0; i < path.length; i++) { - fn(path[i], 'bubbled', arg); + newTx.ins[i].script = script; + + if (hashcode === zconstants.SIGHASH_NONE) { + newTx.outs = []; + } else if (hashcode === zconstants.SIGHASH_SINGLE) { + newTx.outs = newTx.outs.slice(0, newTx.ins.length); + for (var j = 0; j < newTx.ins.length - 1; ++j) { + newTx.outs[j].satoshis = Math.pow(2, 64) - 1; + newTx.outs[j].script = ''; + } + } else if (hashcode === zconstants.SIGHASH_ANYONECANPAY) { + newTx.ins = [newTx.ins[i]]; } + + return newTx; } -/** - * Traverses the ID hierarchy and invokes the supplied `cb` on any IDs that - * should would receive a `mouseEnter` or `mouseLeave` event. - * - * Does not invoke the callback on the nearest common ancestor because nothing - * "entered" or "left" that element. +/* + * Deserializes a hex string into a TXOBJ + * @param {String} hex string + * @return {Object} txOBJ */ -function traverseEnterLeave(from, to, fn, argFrom, argTo) { - var common = from && to ? getLowestCommonAncestor(from, to) : null; - var pathFrom = []; - while (from && from !== common) { - pathFrom.push(from); - from = from._hostParent; - } - var pathTo = []; - while (to && to !== common) { - pathTo.push(to); - to = to._hostParent; - } - var i; - for (i = 0; i < pathFrom.length; i++) { - fn(pathFrom[i], 'bubbled', argFrom); +function deserializeTx(hexStr) { + const buf = Buffer.from(hexStr, 'hex'); + var offset = 0; + + // Out txobj + var txObj = { version: 0, locktime: 0, ins: [], outs: [] + + // Version + };txObj.version = buf.readUInt32LE(offset); + offset += 4; + + // Vins + var vinLen = varuint.decode(buf, offset); + offset += varuint.decode.bytes; + for (var i = 0; i < vinLen; i++) { + const hash = buf.slice(offset, offset + 32); + offset += 32; + + const vout = buf.readUInt32LE(offset); + offset += 4; + + const scriptLen = varuint.decode(buf, offset); + offset += varuint.decode.bytes; + + const script = buf.slice(offset, offset + scriptLen); + offset += scriptLen; + + const sequence = buf.slice(offset, offset + 4).toString('hex'); + offset += 4; + + txObj.ins.push({ + output: { hash: hash.reverse().toString('hex'), vout: vout }, + script: script.toString('hex'), + sequence: sequence, + prevScriptPubKey: '' + }); } - for (i = pathTo.length; i-- > 0;) { - fn(pathTo[i], 'captured', argTo); + + // Vouts + var voutLen = varuint.decode(buf, offset); + offset += varuint.decode.bytes; + for (var i = 0; i < voutLen; i++) { + const satoshis = zbufferutils.readUInt64LE(buf, offset); + offset += 8; + + const scriptLen = varuint.decode(buf, offset); + offset += varuint.decode.bytes; + + const script = buf.slice(offset, offset + scriptLen); + offset += scriptLen; + + txObj.outs.push({ + satoshis: satoshis, + script: script.toString('hex') + }); } -} -module.exports = { - isAncestor: isAncestor, - getLowestCommonAncestor: getLowestCommonAncestor, - getParentInstance: getParentInstance, - traverseTwoPhase: traverseTwoPhase, - traverseEnterLeave: traverseEnterLeave -}; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // Locktime + txObj.locktime = buf.readInt32LE(offset); + offset += 4; -/***/ }), -/* 187 */ -/***/ (function(module, exports, __webpack_require__) { + return txObj; +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * +/* + * Serializes a TXOBJ into hex string + * @param {Object} txObj + * return {String} hex string of txObj */ +function serializeTx(txObj) { + var serializedTx = ''; + var _buf16 = Buffer.alloc(4); + + // Version + _buf16.writeUInt16LE(txObj.version, 0); + serializedTx += _buf16.toString('hex'); + + // History + serializedTx += zbufferutils.numToVarInt(txObj.ins.length); + txObj.ins.map(function (i) { + // Txids and vouts + _buf16.writeUInt16LE(i.output.vout, 0); + serializedTx += Buffer.from(i.output.hash, 'hex').reverse().toString('hex'); + serializedTx += _buf16.toString('hex'); + + // Script + serializedTx += zbufferutils.getStringBufferLength(i.script); + serializedTx += i.script; + + // Sequence + serializedTx += i.sequence; + }); + // Outputs + serializedTx += zbufferutils.numToVarInt(txObj.outs.length); + txObj.outs.map(function (o) { + // Write 64bit buffers + // JS only supports 56 bit + // https://github.com/bitcoinjs/bitcoinjs-lib/blob/master/src/bufferutils.js#L25 + var _buf32 = Buffer.alloc(8); + _buf32.writeInt32LE(o.satoshis & -1, 0); + _buf32.writeUInt32LE(Math.floor(o.satoshis / 0x100000000), 4); -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); + serializedTx += _buf32.toString('hex'); + serializedTx += zbufferutils.getStringBufferLength(o.script); + serializedTx += o.script; + }); -var DOMChildrenOperations = __webpack_require__(55); -var DOMLazyTree = __webpack_require__(27); -var ReactDOMComponentTree = __webpack_require__(6); + // Locktime + _buf16.writeUInt16LE(txObj.locktime, 0); + serializedTx += _buf16.toString('hex'); -var escapeTextContentForBrowser = __webpack_require__(44); -var invariant = __webpack_require__(1); -var validateDOMNesting = __webpack_require__(64); + return serializedTx; +} -/** - * Text nodes violate a couple assumptions that React makes about components: - * - * - When mounting text into the DOM, adjacent text nodes are merged. - * - Text nodes cannot be assigned a React root ID. - * - * This component is used to wrap strings between comment nodes so that they - * can undergo the same reconciliation that is applied to elements. - * - * TODO: Investigate representing React components in the DOM with text nodes. - * - * @class ReactDOMTextComponent - * @extends ReactComponent - * @internal +/* + * Creates a raw transaction + * @param {[HISTORY]} history type, array of transaction history + * @param {[RECIPIENTS]} recipient type, array of address on where to send coins to + * @param {Number} blockHeight (latest - 300) + * @param {String} blockHash of blockHeight + * @return {TXOBJ} Transction Object (see TXOBJ type for info about structure) */ -var ReactDOMTextComponent = function (text) { - // TODO: This is really a ReactText (ReactNode), not a ReactElement - this._currentElement = text; - this._stringText = '' + text; - // ReactDOMComponentTree uses these: - this._hostNode = null; - this._hostParent = null; +function createRawTx(history, recipients, blockHeight, blockHash) { + var txObj = { locktime: 0, version: 1, ins: [], outs: [] }; - // Properties - this._domID = 0; - this._mountIndex = 0; - this._closingComment = null; - this._commentNodes = null; -}; + txObj.ins = history.map(function (h) { + return { + output: { hash: h.txid, vout: h.vout }, + script: '', + prevScriptPubKey: h.scriptPubKey, + sequence: 'ffffffff' + }; + }); + txObj.outs = recipients.map(function (o) { + return { + script: addressToScript(o.address, blockHeight, blockHash), + satoshis: o.satoshis + }; + }); -_assign(ReactDOMTextComponent.prototype, { - /** - * Creates the markup for this text node. This node is not intended to have - * any features besides containing text content. - * - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @return {string} Markup for this text node. - * @internal - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - if (process.env.NODE_ENV !== 'production') { - var parentInfo; - if (hostParent != null) { - parentInfo = hostParent._ancestorInfo; - } else if (hostContainerInfo != null) { - parentInfo = hostContainerInfo._ancestorInfo; - } - if (parentInfo) { - // parentInfo should always be present except for the top-level - // component when server rendering - validateDOMNesting(null, this._stringText, this, parentInfo); - } - } + return txObj; +} - var domID = hostContainerInfo._idCounter++; - var openingValue = ' react-text: ' + domID + ' '; - var closingValue = ' /react-text '; - this._domID = domID; - this._hostParent = hostParent; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var openingComment = ownerDocument.createComment(openingValue); - var closingComment = ownerDocument.createComment(closingValue); - var lazyTree = DOMLazyTree(ownerDocument.createDocumentFragment()); - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(openingComment)); - if (this._stringText) { - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(ownerDocument.createTextNode(this._stringText))); - } - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(closingComment)); - ReactDOMComponentTree.precacheNode(this, openingComment); - this._closingComment = closingComment; - return lazyTree; - } else { - var escapedText = escapeTextContentForBrowser(this._stringText); +/* + * Signs the raw transaction + * @param {String} rawTx raw transaction + * @param {Int} i + * @param {privKey} privKey (not WIF format) + * @param {compressPubKey} compress public key before appending to scriptSig? (default false) + * @param {hashcode} hashcode (default SIGHASH_ALL) + * return {String} signed transaction + */ +function signTx(_txObj, i, privKey, compressPubKey, hashcode) { + hashcode = hashcode || zconstants.SIGHASH_ALL; + compressPubKey = compressPubKey || false; - if (transaction.renderToStaticMarkup) { - // Normally we'd wrap this between comment nodes for the reasons stated - // above, but since this is a situation where React won't take over - // (static pages), we can simply return the text as it is. - return escapedText; - } + // Make a copy + var txObj = JSON.parse(JSON.stringify(_txObj)); - return '<!--' + openingValue + '-->' + escapedText + '<!--' + closingValue + '-->'; - } - }, + // Buffer + var _buf16 = Buffer.alloc(4); + _buf16.writeUInt16LE(hashcode, 0); - /** - * Updates this component by updating the text content. - * - * @param {ReactText} nextText The next text content - * @param {ReactReconcileTransaction} transaction - * @internal - */ - receiveComponent: function (nextText, transaction) { - if (nextText !== this._currentElement) { - this._currentElement = nextText; - var nextStringText = '' + nextText; - if (nextStringText !== this._stringText) { - // TODO: Save this as pending props and use performUpdateIfNecessary - // and/or updateComponent to do the actual update for consistency with - // other component types? - this._stringText = nextStringText; - var commentNodes = this.getHostNode(); - DOMChildrenOperations.replaceDelimitedText(commentNodes[0], commentNodes[1], nextStringText); - } - } - }, + // Prepare signing + const script = txObj.ins[i].prevScriptPubKey; - getHostNode: function () { - var hostNode = this._commentNodes; - if (hostNode) { - return hostNode; - } - if (!this._closingComment) { - var openingComment = ReactDOMComponentTree.getNodeFromInstance(this); - var node = openingComment.nextSibling; - while (true) { - !(node != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Missing closing comment for text component %s', this._domID) : _prodInvariant('67', this._domID) : void 0; - if (node.nodeType === 8 && node.nodeValue === ' /react-text ') { - this._closingComment = node; - break; - } - node = node.nextSibling; - } - } - hostNode = [this._hostNode, this._closingComment]; - this._commentNodes = hostNode; - return hostNode; - }, + // Prepare our signature + const signingTx = signatureForm(txObj, i, script, hashcode); + const signingTxHex = serializeTx(signingTx); + const signingTxWithHashcode = signingTxHex + _buf16.toString('hex'); - unmountComponent: function () { - this._closingComment = null; - this._commentNodes = null; - ReactDOMComponentTree.uncacheNode(this); - } -}); + // Sha256 it twice, according to spec + const msg = zcrypto.sha256x2(Buffer.from(signingTxWithHashcode, 'hex')); -module.exports = ReactDOMTextComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // Signing it + const rawsig = secp256k1.sign(Buffer.from(msg, 'hex'), Buffer.from(privKey, 'hex')).signature; -/***/ }), -/* 188 */ -/***/ (function(module, exports, __webpack_require__) { + // Convert it to DER format + // Appending 01 to it cause + // ScriptSig = <varint of total sig length> <SIG from code, including appended 01 SIGNHASH> <length of pubkey (0x21 or 0x41)> <pubkey> + // https://bitcoin.stackexchange.com/a/36481 + const signatureDER = secp256k1.signatureExport(rawsig).toString('hex') + '01'; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // Chuck it back into txObj and add pubkey + // WHAT? If it fails, uncompress/compress it and it should work... + const pubKey = zaddress.privKeyToPubKey(privKey, compressPubKey); + + txObj.ins[i].script = zbufferutils.getStringBufferLength(signatureDER) + signatureDER + zbufferutils.getStringBufferLength(pubKey) + pubKey; + + return txObj; +} +module.exports = { + addressToScript: addressToScript, + createRawTx: createRawTx, + mkPubkeyHashReplayScript: mkPubkeyHashReplayScript, + mkScriptHashReplayScript: mkScriptHashReplayScript, + signatureForm: signatureForm, + serializeTx: serializeTx, + deserializeTx: deserializeTx, + signTx: signTx +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) +/***/ }), +/* 459 */ +/***/ (function(module, exports, __webpack_require__) { -var _assign = __webpack_require__(5); +/* WEBPACK VAR INJECTION */(function(Buffer) {// int64-buffer.js -var ReactUpdates = __webpack_require__(15); -var Transaction = __webpack_require__(41); +/*jshint -W018 */ // Confusing use of '!'. +/*jshint -W030 */ // Expected an assignment or function call and instead saw an expression. +/*jshint -W093 */ // Did you mean to return a conditional instead of an assignment? -var emptyFunction = __webpack_require__(12); +var Uint64BE, Int64BE, Uint64LE, Int64LE; -var RESET_BATCHED_UPDATES = { - initialize: emptyFunction, - close: function () { - ReactDefaultBatchingStrategy.isBatchingUpdates = false; - } -}; +!function(exports) { + // constants -var FLUSH_BATCHED_UPDATES = { - initialize: emptyFunction, - close: ReactUpdates.flushBatchedUpdates.bind(ReactUpdates) -}; + var UNDEFINED = "undefined"; + var BUFFER = (UNDEFINED !== typeof Buffer) && Buffer; + var UINT8ARRAY = (UNDEFINED !== typeof Uint8Array) && Uint8Array; + var ARRAYBUFFER = (UNDEFINED !== typeof ArrayBuffer) && ArrayBuffer; + var ZERO = [0, 0, 0, 0, 0, 0, 0, 0]; + var isArray = Array.isArray || _isArray; + var BIT32 = 4294967296; + var BIT24 = 16777216; -var TRANSACTION_WRAPPERS = [FLUSH_BATCHED_UPDATES, RESET_BATCHED_UPDATES]; + // storage class -function ReactDefaultBatchingStrategyTransaction() { - this.reinitializeTransaction(); -} + var storage; // Array; -_assign(ReactDefaultBatchingStrategyTransaction.prototype, Transaction, { - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - } -}); + // generate classes -var transaction = new ReactDefaultBatchingStrategyTransaction(); + Uint64BE = factory("Uint64BE", true, true); + Int64BE = factory("Int64BE", true, false); + Uint64LE = factory("Uint64LE", false, true); + Int64LE = factory("Int64LE", false, false); -var ReactDefaultBatchingStrategy = { - isBatchingUpdates: false, + // class factory - /** - * Call the provided function in a context within which calls to `setState` - * and friends are batched such that components aren't updated unnecessarily. - */ - batchedUpdates: function (callback, a, b, c, d, e) { - var alreadyBatchingUpdates = ReactDefaultBatchingStrategy.isBatchingUpdates; + function factory(name, bigendian, unsigned) { + var posH = bigendian ? 0 : 4; + var posL = bigendian ? 4 : 0; + var pos0 = bigendian ? 0 : 3; + var pos1 = bigendian ? 1 : 2; + var pos2 = bigendian ? 2 : 1; + var pos3 = bigendian ? 3 : 0; + var fromPositive = bigendian ? fromPositiveBE : fromPositiveLE; + var fromNegative = bigendian ? fromNegativeBE : fromNegativeLE; + var proto = Int64.prototype; + var isName = "is" + name; + var _isInt64 = "_" + isName; - ReactDefaultBatchingStrategy.isBatchingUpdates = true; + // properties + proto.buffer = void 0; + proto.offset = 0; + proto[_isInt64] = true; - // The code is written this way to avoid extra allocations - if (alreadyBatchingUpdates) { - return callback(a, b, c, d, e); - } else { - return transaction.perform(callback, null, a, b, c, d, e); - } - } -}; + // methods + proto.toNumber = toNumber; + proto.toString = toString; + proto.toJSON = toNumber; + proto.toArray = toArray; -module.exports = ReactDefaultBatchingStrategy; + // add .toBuffer() method only when Buffer available + if (BUFFER) proto.toBuffer = toBuffer; -/***/ }), -/* 189 */ -/***/ (function(module, exports, __webpack_require__) { + // add .toArrayBuffer() method only when Uint8Array available + if (UINT8ARRAY) proto.toArrayBuffer = toArrayBuffer; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // isUint64BE, isInt64BE + Int64[isName] = isInt64; + // CommonJS + exports[name] = Int64; + return Int64; -var _assign = __webpack_require__(5); + // constructor + function Int64(buffer, offset, value, raddix) { + if (!(this instanceof Int64)) return new Int64(buffer, offset, value, raddix); + return init(this, buffer, offset, value, raddix); + } -var EventListener = __webpack_require__(101); -var ExecutionEnvironment = __webpack_require__(8); -var PooledClass = __webpack_require__(20); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); + // isUint64BE, isInt64BE + function isInt64(b) { + return !!(b && b[_isInt64]); + } -var getEventTarget = __webpack_require__(52); -var getUnboundedScrollPosition = __webpack_require__(190); + // initializer + function init(that, buffer, offset, value, raddix) { + if (UINT8ARRAY && ARRAYBUFFER) { + if (buffer instanceof ARRAYBUFFER) buffer = new UINT8ARRAY(buffer); + if (value instanceof ARRAYBUFFER) value = new UINT8ARRAY(value); + } -/** - * Find the deepest React component completely containing the root of the - * passed-in instance (for use when entire React trees are nested within each - * other). If React trees are not nested, returns null. - */ -function findParent(inst) { - // TODO: It may be a good idea to cache this to prevent unnecessary DOM - // traversal, but caching is difficult to do correctly without using a - // mutation observer to listen for all DOM changes. - while (inst._hostParent) { - inst = inst._hostParent; - } - var rootNode = ReactDOMComponentTree.getNodeFromInstance(inst); - var container = rootNode.parentNode; - return ReactDOMComponentTree.getClosestInstanceFromNode(container); -} + // Int64BE() style + if (!buffer && !offset && !value && !storage) { + // shortcut to initialize with zero + that.buffer = newArray(ZERO, 0); + return; + } -// Used to store ancestor hierarchy in top level callback -function TopLevelCallbackBookKeeping(topLevelType, nativeEvent) { - this.topLevelType = topLevelType; - this.nativeEvent = nativeEvent; - this.ancestors = []; -} -_assign(TopLevelCallbackBookKeeping.prototype, { - destructor: function () { - this.topLevelType = null; - this.nativeEvent = null; - this.ancestors.length = 0; - } -}); -PooledClass.addPoolingTo(TopLevelCallbackBookKeeping, PooledClass.twoArgumentPooler); + // Int64BE(value, raddix) style + if (!isValidBuffer(buffer, offset)) { + var _storage = storage || Array; + raddix = offset; + value = buffer; + offset = 0; + buffer = new _storage(8); + } -function handleTopLevelImpl(bookKeeping) { - var nativeEventTarget = getEventTarget(bookKeeping.nativeEvent); - var targetInst = ReactDOMComponentTree.getClosestInstanceFromNode(nativeEventTarget); + that.buffer = buffer; + that.offset = offset |= 0; + + // Int64BE(buffer, offset) style + if (UNDEFINED === typeof value) return; + + // Int64BE(buffer, offset, value, raddix) style + if ("string" === typeof value) { + fromString(buffer, offset, value, raddix || 10); + } else if (isValidBuffer(value, raddix)) { + fromArray(buffer, offset, value, raddix); + } else if ("number" === typeof raddix) { + writeInt32(buffer, offset + posH, value); // high + writeInt32(buffer, offset + posL, raddix); // low + } else if (value > 0) { + fromPositive(buffer, offset, value); // positive + } else if (value < 0) { + fromNegative(buffer, offset, value); // negative + } else { + fromArray(buffer, offset, ZERO, 0); // zero, NaN and others + } + } - // Loop through the hierarchy, in case there's any nested components. - // It's important that we build the array of ancestors before calling any - // event handlers, because event handlers can modify the DOM, leading to - // inconsistencies with ReactMount's node cache. See #1105. - var ancestor = targetInst; - do { - bookKeeping.ancestors.push(ancestor); - ancestor = ancestor && findParent(ancestor); - } while (ancestor); + function fromString(buffer, offset, str, raddix) { + var pos = 0; + var len = str.length; + var high = 0; + var low = 0; + if (str[0] === "-") pos++; + var sign = pos; + while (pos < len) { + var chr = parseInt(str[pos++], raddix); + if (!(chr >= 0)) break; // NaN + low = low * raddix + chr; + high = high * raddix + Math.floor(low / BIT32); + low %= BIT32; + } + if (sign) { + high = ~high; + if (low) { + low = BIT32 - low; + } else { + high++; + } + } + writeInt32(buffer, offset + posH, high); + writeInt32(buffer, offset + posL, low); + } + + function toNumber() { + var buffer = this.buffer; + var offset = this.offset; + var high = readInt32(buffer, offset + posH); + var low = readInt32(buffer, offset + posL); + if (!unsigned) high |= 0; // a trick to get signed + return high ? (high * BIT32 + low) : low; + } + + function toString(radix) { + var buffer = this.buffer; + var offset = this.offset; + var high = readInt32(buffer, offset + posH); + var low = readInt32(buffer, offset + posL); + var str = ""; + var sign = !unsigned && (high & 0x80000000); + if (sign) { + high = ~high; + low = BIT32 - low; + } + radix = radix || 10; + while (1) { + var mod = (high % radix) * BIT32 + low; + high = Math.floor(high / radix); + low = Math.floor(mod / radix); + str = (mod % radix).toString(radix) + str; + if (!high && !low) break; + } + if (sign) { + str = "-" + str; + } + return str; + } - for (var i = 0; i < bookKeeping.ancestors.length; i++) { - targetInst = bookKeeping.ancestors[i]; - ReactEventListener._handleTopLevel(bookKeeping.topLevelType, targetInst, bookKeeping.nativeEvent, getEventTarget(bookKeeping.nativeEvent)); + function writeInt32(buffer, offset, value) { + buffer[offset + pos3] = value & 255; + value = value >> 8; + buffer[offset + pos2] = value & 255; + value = value >> 8; + buffer[offset + pos1] = value & 255; + value = value >> 8; + buffer[offset + pos0] = value & 255; + } + + function readInt32(buffer, offset) { + return (buffer[offset + pos0] * BIT24) + + (buffer[offset + pos1] << 16) + + (buffer[offset + pos2] << 8) + + buffer[offset + pos3]; + } } -} -function scrollValueMonitor(cb) { - var scrollPosition = getUnboundedScrollPosition(window); - cb(scrollPosition); -} + function toArray(raw) { + var buffer = this.buffer; + var offset = this.offset; + storage = null; // Array + if (raw !== false && offset === 0 && buffer.length === 8 && isArray(buffer)) return buffer; + return newArray(buffer, offset); + } -var ReactEventListener = { - _enabled: true, - _handleTopLevel: null, + function toBuffer(raw) { + var buffer = this.buffer; + var offset = this.offset; + storage = BUFFER; + if (raw !== false && offset === 0 && buffer.length === 8 && Buffer.isBuffer(buffer)) return buffer; + var dest = new BUFFER(8); + fromArray(dest, 0, buffer, offset); + return dest; + } - WINDOW_HANDLE: ExecutionEnvironment.canUseDOM ? window : null, + function toArrayBuffer(raw) { + var buffer = this.buffer; + var offset = this.offset; + var arrbuf = buffer.buffer; + storage = UINT8ARRAY; + if (raw !== false && offset === 0 && (arrbuf instanceof ARRAYBUFFER) && arrbuf.byteLength === 8) return arrbuf; + var dest = new UINT8ARRAY(8); + fromArray(dest, 0, buffer, offset); + return dest.buffer; + } - setHandleTopLevel: function (handleTopLevel) { - ReactEventListener._handleTopLevel = handleTopLevel; - }, + function isValidBuffer(buffer, offset) { + var len = buffer && buffer.length; + offset |= 0; + return len && (offset + 8 <= len) && ("string" !== typeof buffer[offset]); + } - setEnabled: function (enabled) { - ReactEventListener._enabled = !!enabled; - }, + function fromArray(destbuf, destoff, srcbuf, srcoff) { + destoff |= 0; + srcoff |= 0; + for (var i = 0; i < 8; i++) { + destbuf[destoff++] = srcbuf[srcoff++] & 255; + } + } - isEnabled: function () { - return ReactEventListener._enabled; - }, + function newArray(buffer, offset) { + return Array.prototype.slice.call(buffer, offset, offset + 8); + } - /** - * Traps top-level events by using event bubbling. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {string} handlerBaseName Event name (e.g. "click"). - * @param {object} element Element on which to attach listener. - * @return {?object} An object with a remove function which will forcefully - * remove the listener. - * @internal - */ - trapBubbledEvent: function (topLevelType, handlerBaseName, element) { - if (!element) { - return null; + function fromPositiveBE(buffer, offset, value) { + var pos = offset + 8; + while (pos > offset) { + buffer[--pos] = value & 255; + value /= 256; } - return EventListener.listen(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); - }, + } - /** - * Traps a top-level event by using event capturing. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {string} handlerBaseName Event name (e.g. "click"). - * @param {object} element Element on which to attach listener. - * @return {?object} An object with a remove function which will forcefully - * remove the listener. - * @internal - */ - trapCapturedEvent: function (topLevelType, handlerBaseName, element) { - if (!element) { - return null; + function fromNegativeBE(buffer, offset, value) { + var pos = offset + 8; + value++; + while (pos > offset) { + buffer[--pos] = ((-value) & 255) ^ 255; + value /= 256; } - return EventListener.capture(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); - }, - - monitorScrollValue: function (refresh) { - var callback = scrollValueMonitor.bind(null, refresh); - EventListener.listen(window, 'scroll', callback); - }, + } - dispatchEvent: function (topLevelType, nativeEvent) { - if (!ReactEventListener._enabled) { - return; + function fromPositiveLE(buffer, offset, value) { + var end = offset + 8; + while (offset < end) { + buffer[offset++] = value & 255; + value /= 256; } + } - var bookKeeping = TopLevelCallbackBookKeeping.getPooled(topLevelType, nativeEvent); - try { - // Event queue being processed in the same cycle allows - // `preventDefault`. - ReactUpdates.batchedUpdates(handleTopLevelImpl, bookKeeping); - } finally { - TopLevelCallbackBookKeeping.release(bookKeeping); + function fromNegativeLE(buffer, offset, value) { + var end = offset + 8; + value++; + while (offset < end) { + buffer[offset++] = ((-value) & 255) ^ 255; + value /= 256; } } -}; -module.exports = ReactEventListener; + // https://github.com/retrofox/is-array + function _isArray(val) { + return !!val && "[object Array]" == Object.prototype.toString.call(val); + } + +}(typeof exports === 'object' && typeof exports.nodeName !== 'string' ? exports : (this || {})); + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 190 */ -/***/ (function(module, exports, __webpack_require__) { +/* 460 */ +/***/ (function(module, exports) { -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +module.exports = { + /* SIGHASH Codes + * Obtained from: https://github.com/ZencashOfficial/zen/blob/master/src/script/interpreter.h + */ + SIGHASH_ALL: 1, + SIGHASH_NONE: 2, + SIGHASH_SINGLE: 3, + SIGHASH_ANYONECANPAY: 0x80 +}; +/***/ }), +/* 461 */ +/***/ (function(module, exports) { -/** - * Gets the scroll position of the supplied element or window. - * - * The return values are unbounded, unlike `getScrollPosition`. This means they - * may be negative or exceed the element boundaries (which is possible using - * inertial scrolling). - * - * @param {DOMWindow|DOMElement} scrollable - * @return {object} Map with `x` and `y` keys. +/* Useful OP codes for the scripting language + * Obtained from: https://github.com/ZencashOfficial/zen/blob/master/src/script/script.h */ -function getUnboundedScrollPosition(scrollable) { - if (scrollable.Window && scrollable instanceof scrollable.Window) { - return { - x: scrollable.pageXOffset || scrollable.document.documentElement.scrollLeft, - y: scrollable.pageYOffset || scrollable.document.documentElement.scrollTop - }; - } - return { - x: scrollable.scrollLeft, - y: scrollable.scrollTop - }; -} - -module.exports = getUnboundedScrollPosition; +module.exports = { + OP_DUP: '76', + OP_HASH160: 'a9', + OP_EQUALVERIFY: '88', + OP_CHECKSIG: 'ac', + OP_CHECKBLOCKATHEIGHT: 'b4', + OP_EQUAL: '87', + OP_REVERSED: '89' +}; /***/ }), -/* 191 */ +/* 462 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var _bluebird = __webpack_require__(463); + +var _bluebird2 = _interopRequireDefault(_bluebird); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +// Append url +function urlAppend(url, param) { + if (url.substr(-1) !== '/') { + url = url + '/'; + } + + return url + param; +} -var DOMProperty = __webpack_require__(17); -var EventPluginHub = __webpack_require__(32); -var EventPluginUtils = __webpack_require__(50); -var ReactComponentEnvironment = __webpack_require__(59); -var ReactEmptyComponent = __webpack_require__(98); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactHostComponent = __webpack_require__(99); -var ReactUpdates = __webpack_require__(15); +// Debounce promise +function promiseDebounce(fn, delay, count) { + var working = 0, + queue = []; + function work() { + if (queue.length === 0 || working === count) return; + working++; + _bluebird2.default.delay(delay).tap(function () { + working--; + }).then(work); + var next = queue.shift(); + next[2](fn.apply(next[0], next[1])); + } + return function debounced() { + var args = arguments; + return new _bluebird2.default(function (resolve) { + queue.push([this, args, resolve]); + if (working < count) work(); + }.bind(this)); + }; +} -var ReactInjection = { - Component: ReactComponentEnvironment.injection, - DOMProperty: DOMProperty.injection, - EmptyComponent: ReactEmptyComponent.injection, - EventPluginHub: EventPluginHub.injection, - EventPluginUtils: EventPluginUtils.injection, - EventEmitter: ReactBrowserEventEmitter.injection, - HostComponent: ReactHostComponent.injection, - Updates: ReactUpdates.injection +module.exports = { + promiseDebounce: promiseDebounce, + urlAppend: urlAppend }; -module.exports = ReactInjection; - /***/ }), -/* 192 */ +/* 463 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * +/* WEBPACK VAR INJECTION */(function(process, global, setImmediate) {/* @preserve + * The MIT License (MIT) + * + * Copyright (c) 2013-2017 Petka Antonov + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + * */ +/** + * bluebird build version 3.5.0 + * Features enabled: core, race, call_get, generators, map, nodeify, promisify, props, reduce, settle, some, using, timers, filter, any, each +*/ +!function(e){if(true)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.Promise=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof _dereq_=="function"&&_dereq_;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof _dereq_=="function"&&_dereq_;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +var SomePromiseArray = Promise._SomePromiseArray; +function any(promises) { + var ret = new SomePromiseArray(promises); + var promise = ret.promise(); + ret.setHowMany(1); + ret.setUnwrap(); + ret.init(); + return promise; +} +Promise.any = function (promises) { + return any(promises); +}; +Promise.prototype.any = function () { + return any(this); +}; -var _assign = __webpack_require__(5); +}; -var CallbackQueue = __webpack_require__(85); -var PooledClass = __webpack_require__(20); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactInputSelection = __webpack_require__(102); -var ReactInstrumentation = __webpack_require__(13); -var Transaction = __webpack_require__(41); -var ReactUpdateQueue = __webpack_require__(63); +},{}],2:[function(_dereq_,module,exports){ +"use strict"; +var firstLineError; +try {throw new Error(); } catch (e) {firstLineError = e;} +var schedule = _dereq_("./schedule"); +var Queue = _dereq_("./queue"); +var util = _dereq_("./util"); + +function Async() { + this._customScheduler = false; + this._isTickUsed = false; + this._lateQueue = new Queue(16); + this._normalQueue = new Queue(16); + this._haveDrainedQueues = false; + this._trampolineEnabled = true; + var self = this; + this.drainQueues = function () { + self._drainQueues(); + }; + this._schedule = schedule; +} -/** - * Ensures that, when possible, the selection range (currently selected text - * input) is not disturbed by performing the transaction. - */ -var SELECTION_RESTORATION = { - /** - * @return {Selection} Selection information. - */ - initialize: ReactInputSelection.getSelectionInformation, - /** - * @param {Selection} sel Selection information returned from `initialize`. - */ - close: ReactInputSelection.restoreSelection +Async.prototype.setScheduler = function(fn) { + var prev = this._schedule; + this._schedule = fn; + this._customScheduler = true; + return prev; }; -/** - * Suppresses events (blur/focus) that could be inadvertently dispatched due to - * high level DOM manipulations (like temporarily removing a text input from the - * DOM). - */ -var EVENT_SUPPRESSION = { - /** - * @return {boolean} The enabled status of `ReactBrowserEventEmitter` before - * the reconciliation. - */ - initialize: function () { - var currentlyEnabled = ReactBrowserEventEmitter.isEnabled(); - ReactBrowserEventEmitter.setEnabled(false); - return currentlyEnabled; - }, +Async.prototype.hasCustomScheduler = function() { + return this._customScheduler; +}; - /** - * @param {boolean} previouslyEnabled Enabled status of - * `ReactBrowserEventEmitter` before the reconciliation occurred. `close` - * restores the previous value. - */ - close: function (previouslyEnabled) { - ReactBrowserEventEmitter.setEnabled(previouslyEnabled); - } +Async.prototype.enableTrampoline = function() { + this._trampolineEnabled = true; }; -/** - * Provides a queue for collecting `componentDidMount` and - * `componentDidUpdate` callbacks during the transaction. - */ -var ON_DOM_READY_QUEUEING = { - /** - * Initializes the internal `onDOMReady` queue. - */ - initialize: function () { - this.reactMountReady.reset(); - }, +Async.prototype.disableTrampolineIfNecessary = function() { + if (util.hasDevTools) { + this._trampolineEnabled = false; + } +}; - /** - * After DOM is flushed, invoke all registered `onDOMReady` callbacks. - */ - close: function () { - this.reactMountReady.notifyAll(); - } +Async.prototype.haveItemsQueued = function () { + return this._isTickUsed || this._haveDrainedQueues; }; -/** - * Executed within the scope of the `Transaction` instance. Consider these as - * being member methods, but with an implied ordering while being isolated from - * each other. - */ -var TRANSACTION_WRAPPERS = [SELECTION_RESTORATION, EVENT_SUPPRESSION, ON_DOM_READY_QUEUEING]; -if (process.env.NODE_ENV !== 'production') { - TRANSACTION_WRAPPERS.push({ - initialize: ReactInstrumentation.debugTool.onBeginFlush, - close: ReactInstrumentation.debugTool.onEndFlush - }); -} +Async.prototype.fatalError = function(e, isNode) { + if (isNode) { + process.stderr.write("Fatal " + (e instanceof Error ? e.stack : e) + + "\n"); + process.exit(2); + } else { + this.throwLater(e); + } +}; -/** - * Currently: - * - The order that these are listed in the transaction is critical: - * - Suppresses events. - * - Restores selection range. - * - * Future: - * - Restore document/overflow scroll positions that were unintentionally - * modified via DOM insertions above the top viewport boundary. - * - Implement/integrate with customized constraint based layout system and keep - * track of which dimensions must be remeasured. - * - * @class ReactReconcileTransaction - */ -function ReactReconcileTransaction(useCreateElement) { - this.reinitializeTransaction(); - // Only server-side rendering really needs this option (see - // `ReactServerRendering`), but server-side uses - // `ReactServerRenderingTransaction` instead. This option is here so that it's - // accessible and defaults to false when `ReactDOMComponent` and - // `ReactDOMTextComponent` checks it in `mountComponent`.` - this.renderToStaticMarkup = false; - this.reactMountReady = CallbackQueue.getPooled(null); - this.useCreateElement = useCreateElement; +Async.prototype.throwLater = function(fn, arg) { + if (arguments.length === 1) { + arg = fn; + fn = function () { throw arg; }; + } + if (typeof setTimeout !== "undefined") { + setTimeout(function() { + fn(arg); + }, 0); + } else try { + this._schedule(function() { + fn(arg); + }); + } catch (e) { + throw new Error("No async scheduler available\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } +}; + +function AsyncInvokeLater(fn, receiver, arg) { + this._lateQueue.push(fn, receiver, arg); + this._queueTick(); } -var Mixin = { - /** - * @see Transaction - * @abstract - * @final - * @return {array<object>} List of operation wrap procedures. - * TODO: convert to array<TransactionWrapper> - */ - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, +function AsyncInvoke(fn, receiver, arg) { + this._normalQueue.push(fn, receiver, arg); + this._queueTick(); +} - /** - * @return {object} The queue to collect `onDOMReady` callbacks with. - */ - getReactMountReady: function () { - return this.reactMountReady; - }, +function AsyncSettlePromises(promise) { + this._normalQueue._pushOne(promise); + this._queueTick(); +} - /** - * @return {object} The queue to collect React async events. - */ - getUpdateQueue: function () { - return ReactUpdateQueue; - }, +if (!util.hasDevTools) { + Async.prototype.invokeLater = AsyncInvokeLater; + Async.prototype.invoke = AsyncInvoke; + Async.prototype.settlePromises = AsyncSettlePromises; +} else { + Async.prototype.invokeLater = function (fn, receiver, arg) { + if (this._trampolineEnabled) { + AsyncInvokeLater.call(this, fn, receiver, arg); + } else { + this._schedule(function() { + setTimeout(function() { + fn.call(receiver, arg); + }, 100); + }); + } + }; - /** - * Save current transaction state -- if the return value from this method is - * passed to `rollback`, the transaction will be reset to that state. - */ - checkpoint: function () { - // reactMountReady is the our only stateful wrapper - return this.reactMountReady.checkpoint(); - }, + Async.prototype.invoke = function (fn, receiver, arg) { + if (this._trampolineEnabled) { + AsyncInvoke.call(this, fn, receiver, arg); + } else { + this._schedule(function() { + fn.call(receiver, arg); + }); + } + }; - rollback: function (checkpoint) { - this.reactMountReady.rollback(checkpoint); - }, + Async.prototype.settlePromises = function(promise) { + if (this._trampolineEnabled) { + AsyncSettlePromises.call(this, promise); + } else { + this._schedule(function() { + promise._settlePromises(); + }); + } + }; +} - /** - * `PooledClass` looks for this, and will invoke this before allowing this - * instance to be reused. - */ - destructor: function () { - CallbackQueue.release(this.reactMountReady); - this.reactMountReady = null; - } +Async.prototype._drainQueue = function(queue) { + while (queue.length() > 0) { + var fn = queue.shift(); + if (typeof fn !== "function") { + fn._settlePromises(); + continue; + } + var receiver = queue.shift(); + var arg = queue.shift(); + fn.call(receiver, arg); + } }; -_assign(ReactReconcileTransaction.prototype, Transaction, Mixin); +Async.prototype._drainQueues = function () { + this._drainQueue(this._normalQueue); + this._reset(); + this._haveDrainedQueues = true; + this._drainQueue(this._lateQueue); +}; -PooledClass.addPoolingTo(ReactReconcileTransaction); +Async.prototype._queueTick = function () { + if (!this._isTickUsed) { + this._isTickUsed = true; + this._schedule(this.drainQueues); + } +}; -module.exports = ReactReconcileTransaction; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Async.prototype._reset = function () { + this._isTickUsed = false; +}; -/***/ }), -/* 193 */ -/***/ (function(module, exports, __webpack_require__) { +module.exports = Async; +module.exports.firstLineError = firstLineError; +},{"./queue":26,"./schedule":29,"./util":36}],3:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = function(Promise, INTERNAL, tryConvertToPromise, debug) { +var calledBind = false; +var rejectThis = function(_, e) { + this._reject(e); +}; +var targetRejected = function(e, context) { + context.promiseRejectionQueued = true; + context.bindingPromise._then(rejectThis, rejectThis, null, this, e); +}; +var bindingResolved = function(thisArg, context) { + if (((this._bitField & 50397184) === 0)) { + this._resolveCallback(context.target); + } +}; -var ExecutionEnvironment = __webpack_require__(8); +var bindingRejected = function(e, context) { + if (!context.promiseRejectionQueued) this._reject(e); +}; -var getNodeForCharacterOffset = __webpack_require__(194); -var getTextContentAccessor = __webpack_require__(84); +Promise.prototype.bind = function (thisArg) { + if (!calledBind) { + calledBind = true; + Promise.prototype._propagateFrom = debug.propagateFromFunction(); + Promise.prototype._boundValue = debug.boundValueFunction(); + } + var maybePromise = tryConvertToPromise(thisArg); + var ret = new Promise(INTERNAL); + ret._propagateFrom(this, 1); + var target = this._target(); + ret._setBoundTo(maybePromise); + if (maybePromise instanceof Promise) { + var context = { + promiseRejectionQueued: false, + promise: ret, + target: target, + bindingPromise: maybePromise + }; + target._then(INTERNAL, targetRejected, undefined, ret, context); + maybePromise._then( + bindingResolved, bindingRejected, undefined, ret, context); + ret._setOnCancel(maybePromise); + } else { + ret._resolveCallback(target); + } + return ret; +}; -/** - * While `isCollapsed` is available on the Selection object and `collapsed` - * is available on the Range object, IE11 sometimes gets them wrong. - * If the anchor/focus nodes and offsets are the same, the range is collapsed. - */ -function isCollapsed(anchorNode, anchorOffset, focusNode, focusOffset) { - return anchorNode === focusNode && anchorOffset === focusOffset; -} +Promise.prototype._setBoundTo = function (obj) { + if (obj !== undefined) { + this._bitField = this._bitField | 2097152; + this._boundTo = obj; + } else { + this._bitField = this._bitField & (~2097152); + } +}; -/** - * Get the appropriate anchor and focus node/offset pairs for IE. - * - * The catch here is that IE's selection API doesn't provide information - * about whether the selection is forward or backward, so we have to - * behave as though it's always forward. - * - * IE text differs from modern selection in that it behaves as though - * block elements end with a new line. This means character offsets will - * differ between the two APIs. - * - * @param {DOMElement} node - * @return {object} - */ -function getIEOffsets(node) { - var selection = document.selection; - var selectedRange = selection.createRange(); - var selectedLength = selectedRange.text.length; +Promise.prototype._isBound = function () { + return (this._bitField & 2097152) === 2097152; +}; - // Duplicate selection so we can move range without breaking user selection. - var fromStart = selectedRange.duplicate(); - fromStart.moveToElementText(node); - fromStart.setEndPoint('EndToStart', selectedRange); +Promise.bind = function (thisArg, value) { + return Promise.resolve(value).bind(thisArg); +}; +}; - var startOffset = fromStart.text.length; - var endOffset = startOffset + selectedLength; +},{}],4:[function(_dereq_,module,exports){ +"use strict"; +var old; +if (typeof Promise !== "undefined") old = Promise; +function noConflict() { + try { if (Promise === bluebird) Promise = old; } + catch (e) {} + return bluebird; +} +var bluebird = _dereq_("./promise")(); +bluebird.noConflict = noConflict; +module.exports = bluebird; - return { - start: startOffset, - end: endOffset - }; +},{"./promise":22}],5:[function(_dereq_,module,exports){ +"use strict"; +var cr = Object.create; +if (cr) { + var callerCache = cr(null); + var getterCache = cr(null); + callerCache[" size"] = getterCache[" size"] = 0; } -/** - * @param {DOMElement} node - * @return {?object} - */ -function getModernOffsets(node) { - var selection = window.getSelection && window.getSelection(); +module.exports = function(Promise) { +var util = _dereq_("./util"); +var canEvaluate = util.canEvaluate; +var isIdentifier = util.isIdentifier; + +var getMethodCaller; +var getGetter; +if (false) { +var makeMethodCaller = function (methodName) { + return new Function("ensureMethod", " \n\ + return function(obj) { \n\ + 'use strict' \n\ + var len = this.length; \n\ + ensureMethod(obj, 'methodName'); \n\ + switch(len) { \n\ + case 1: return obj.methodName(this[0]); \n\ + case 2: return obj.methodName(this[0], this[1]); \n\ + case 3: return obj.methodName(this[0], this[1], this[2]); \n\ + case 0: return obj.methodName(); \n\ + default: \n\ + return obj.methodName.apply(obj, this); \n\ + } \n\ + }; \n\ + ".replace(/methodName/g, methodName))(ensureMethod); +}; - if (!selection || selection.rangeCount === 0) { - return null; - } +var makeGetter = function (propertyName) { + return new Function("obj", " \n\ + 'use strict'; \n\ + return obj.propertyName; \n\ + ".replace("propertyName", propertyName)); +}; - var anchorNode = selection.anchorNode; - var anchorOffset = selection.anchorOffset; - var focusNode = selection.focusNode; - var focusOffset = selection.focusOffset; +var getCompiled = function(name, compiler, cache) { + var ret = cache[name]; + if (typeof ret !== "function") { + if (!isIdentifier(name)) { + return null; + } + ret = compiler(name); + cache[name] = ret; + cache[" size"]++; + if (cache[" size"] > 512) { + var keys = Object.keys(cache); + for (var i = 0; i < 256; ++i) delete cache[keys[i]]; + cache[" size"] = keys.length - 256; + } + } + return ret; +}; - var currentRange = selection.getRangeAt(0); +getMethodCaller = function(name) { + return getCompiled(name, makeMethodCaller, callerCache); +}; - // In Firefox, range.startContainer and range.endContainer can be "anonymous - // divs", e.g. the up/down buttons on an <input type="number">. Anonymous - // divs do not seem to expose properties, triggering a "Permission denied - // error" if any of its properties are accessed. The only seemingly possible - // way to avoid erroring is to access a property that typically works for - // non-anonymous divs and catch any error that may otherwise arise. See - // https://bugzilla.mozilla.org/show_bug.cgi?id=208427 - try { - /* eslint-disable no-unused-expressions */ - currentRange.startContainer.nodeType; - currentRange.endContainer.nodeType; - /* eslint-enable no-unused-expressions */ - } catch (e) { - return null; - } +getGetter = function(name) { + return getCompiled(name, makeGetter, getterCache); +}; +} - // If the node and offset values are the same, the selection is collapsed. - // `Selection.isCollapsed` is available natively, but IE sometimes gets - // this value wrong. - var isSelectionCollapsed = isCollapsed(selection.anchorNode, selection.anchorOffset, selection.focusNode, selection.focusOffset); +function ensureMethod(obj, methodName) { + var fn; + if (obj != null) fn = obj[methodName]; + if (typeof fn !== "function") { + var message = "Object " + util.classString(obj) + " has no method '" + + util.toString(methodName) + "'"; + throw new Promise.TypeError(message); + } + return fn; +} - var rangeLength = isSelectionCollapsed ? 0 : currentRange.toString().length; +function caller(obj) { + var methodName = this.pop(); + var fn = ensureMethod(obj, methodName); + return fn.apply(obj, this); +} +Promise.prototype.call = function (methodName) { + var args = [].slice.call(arguments, 1);; + if (false) { + if (canEvaluate) { + var maybeCaller = getMethodCaller(methodName); + if (maybeCaller !== null) { + return this._then( + maybeCaller, undefined, undefined, args, undefined); + } + } + } + args.push(methodName); + return this._then(caller, undefined, undefined, args, undefined); +}; - var tempRange = currentRange.cloneRange(); - tempRange.selectNodeContents(node); - tempRange.setEnd(currentRange.startContainer, currentRange.startOffset); +function namedGetter(obj) { + return obj[this]; +} +function indexedGetter(obj) { + var index = +this; + if (index < 0) index = Math.max(0, index + obj.length); + return obj[index]; +} +Promise.prototype.get = function (propertyName) { + var isIndex = (typeof propertyName === "number"); + var getter; + if (!isIndex) { + if (canEvaluate) { + var maybeGetter = getGetter(propertyName); + getter = maybeGetter !== null ? maybeGetter : namedGetter; + } else { + getter = namedGetter; + } + } else { + getter = indexedGetter; + } + return this._then(getter, undefined, undefined, propertyName, undefined); +}; +}; - var isTempRangeCollapsed = isCollapsed(tempRange.startContainer, tempRange.startOffset, tempRange.endContainer, tempRange.endOffset); +},{"./util":36}],6:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, PromiseArray, apiRejection, debug) { +var util = _dereq_("./util"); +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; +var async = Promise._async; + +Promise.prototype["break"] = Promise.prototype.cancel = function() { + if (!debug.cancellation()) return this._warn("cancellation is disabled"); + + var promise = this; + var child = promise; + while (promise._isCancellable()) { + if (!promise._cancelBy(child)) { + if (child._isFollowing()) { + child._followee().cancel(); + } else { + child._cancelBranched(); + } + break; + } - var start = isTempRangeCollapsed ? 0 : tempRange.toString().length; - var end = start + rangeLength; + var parent = promise._cancellationParent; + if (parent == null || !parent._isCancellable()) { + if (promise._isFollowing()) { + promise._followee().cancel(); + } else { + promise._cancelBranched(); + } + break; + } else { + if (promise._isFollowing()) promise._followee().cancel(); + promise._setWillBeCancelled(); + child = promise; + promise = parent; + } + } +}; - // Detect whether the selection is backward. - var detectionRange = document.createRange(); - detectionRange.setStart(anchorNode, anchorOffset); - detectionRange.setEnd(focusNode, focusOffset); - var isBackward = detectionRange.collapsed; +Promise.prototype._branchHasCancelled = function() { + this._branchesRemainingToCancel--; +}; - return { - start: isBackward ? end : start, - end: isBackward ? start : end - }; -} +Promise.prototype._enoughBranchesHaveCancelled = function() { + return this._branchesRemainingToCancel === undefined || + this._branchesRemainingToCancel <= 0; +}; -/** - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ -function setIEOffsets(node, offsets) { - var range = document.selection.createRange().duplicate(); - var start, end; +Promise.prototype._cancelBy = function(canceller) { + if (canceller === this) { + this._branchesRemainingToCancel = 0; + this._invokeOnCancel(); + return true; + } else { + this._branchHasCancelled(); + if (this._enoughBranchesHaveCancelled()) { + this._invokeOnCancel(); + return true; + } + } + return false; +}; - if (offsets.end === undefined) { - start = offsets.start; - end = start; - } else if (offsets.start > offsets.end) { - start = offsets.end; - end = offsets.start; - } else { - start = offsets.start; - end = offsets.end; - } +Promise.prototype._cancelBranched = function() { + if (this._enoughBranchesHaveCancelled()) { + this._cancel(); + } +}; - range.moveToElementText(node); - range.moveStart('character', start); - range.setEndPoint('EndToStart', range); - range.moveEnd('character', end - start); - range.select(); -} +Promise.prototype._cancel = function() { + if (!this._isCancellable()) return; + this._setCancelled(); + async.invoke(this._cancelPromises, this, undefined); +}; -/** - * In modern non-IE browsers, we can support both forward and backward - * selections. - * - * Note: IE10+ supports the Selection object, but it does not support - * the `extend` method, which means that even in modern IE, it's not possible - * to programmatically create a backward selection. Thus, for all IE - * versions, we use the old IE API to create our selections. - * - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ -function setModernOffsets(node, offsets) { - if (!window.getSelection) { - return; - } +Promise.prototype._cancelPromises = function() { + if (this._length() > 0) this._settlePromises(); +}; - var selection = window.getSelection(); - var length = node[getTextContentAccessor()].length; - var start = Math.min(offsets.start, length); - var end = offsets.end === undefined ? start : Math.min(offsets.end, length); +Promise.prototype._unsetOnCancel = function() { + this._onCancelField = undefined; +}; - // IE 11 uses modern selection, but doesn't support the extend method. - // Flip backward selections, so we can set with a single range. - if (!selection.extend && start > end) { - var temp = end; - end = start; - start = temp; - } +Promise.prototype._isCancellable = function() { + return this.isPending() && !this._isCancelled(); +}; - var startMarker = getNodeForCharacterOffset(node, start); - var endMarker = getNodeForCharacterOffset(node, end); +Promise.prototype.isCancellable = function() { + return this.isPending() && !this.isCancelled(); +}; - if (startMarker && endMarker) { - var range = document.createRange(); - range.setStart(startMarker.node, startMarker.offset); - selection.removeAllRanges(); +Promise.prototype._doInvokeOnCancel = function(onCancelCallback, internalOnly) { + if (util.isArray(onCancelCallback)) { + for (var i = 0; i < onCancelCallback.length; ++i) { + this._doInvokeOnCancel(onCancelCallback[i], internalOnly); + } + } else if (onCancelCallback !== undefined) { + if (typeof onCancelCallback === "function") { + if (!internalOnly) { + var e = tryCatch(onCancelCallback).call(this._boundValue()); + if (e === errorObj) { + this._attachExtraTrace(e.e); + async.throwLater(e.e); + } + } + } else { + onCancelCallback._resultCancelled(this); + } + } +}; - if (start > end) { - selection.addRange(range); - selection.extend(endMarker.node, endMarker.offset); - } else { - range.setEnd(endMarker.node, endMarker.offset); - selection.addRange(range); +Promise.prototype._invokeOnCancel = function() { + var onCancelCallback = this._onCancel(); + this._unsetOnCancel(); + async.invoke(this._doInvokeOnCancel, this, onCancelCallback); +}; + +Promise.prototype._invokeInternalOnCancel = function() { + if (this._isCancellable()) { + this._doInvokeOnCancel(this._onCancel(), true); + this._unsetOnCancel(); } - } +}; + +Promise.prototype._resultCancelled = function() { + this.cancel(); +}; + +}; + +},{"./util":36}],7:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(NEXT_FILTER) { +var util = _dereq_("./util"); +var getKeys = _dereq_("./es5").keys; +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; + +function catchFilter(instances, cb, promise) { + return function(e) { + var boundTo = promise._boundValue(); + predicateLoop: for (var i = 0; i < instances.length; ++i) { + var item = instances[i]; + + if (item === Error || + (item != null && item.prototype instanceof Error)) { + if (e instanceof item) { + return tryCatch(cb).call(boundTo, e); + } + } else if (typeof item === "function") { + var matchesPredicate = tryCatch(item).call(boundTo, e); + if (matchesPredicate === errorObj) { + return matchesPredicate; + } else if (matchesPredicate) { + return tryCatch(cb).call(boundTo, e); + } + } else if (util.isObject(e)) { + var keys = getKeys(item); + for (var j = 0; j < keys.length; ++j) { + var key = keys[j]; + if (item[key] != e[key]) { + continue predicateLoop; + } + } + return tryCatch(cb).call(boundTo, e); + } + } + return NEXT_FILTER; + }; } -var useIEOffsets = ExecutionEnvironment.canUseDOM && 'selection' in document && !('getSelection' in window); +return catchFilter; +}; -var ReactDOMSelection = { - /** - * @param {DOMElement} node - */ - getOffsets: useIEOffsets ? getIEOffsets : getModernOffsets, +},{"./es5":13,"./util":36}],8:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +var longStackTraces = false; +var contextStack = []; - /** - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ - setOffsets: useIEOffsets ? setIEOffsets : setModernOffsets +Promise.prototype._promiseCreated = function() {}; +Promise.prototype._pushContext = function() {}; +Promise.prototype._popContext = function() {return null;}; +Promise._peekContext = Promise.prototype._peekContext = function() {}; + +function Context() { + this._trace = new Context.CapturedTrace(peekContext()); +} +Context.prototype._pushContext = function () { + if (this._trace !== undefined) { + this._trace._promiseCreated = null; + contextStack.push(this._trace); + } }; -module.exports = ReactDOMSelection; +Context.prototype._popContext = function () { + if (this._trace !== undefined) { + var trace = contextStack.pop(); + var ret = trace._promiseCreated; + trace._promiseCreated = null; + return ret; + } + return null; +}; -/***/ }), -/* 194 */ -/***/ (function(module, exports, __webpack_require__) { +function createContext() { + if (longStackTraces) return new Context(); +} + +function peekContext() { + var lastIndex = contextStack.length - 1; + if (lastIndex >= 0) { + return contextStack[lastIndex]; + } + return undefined; +} +Context.CapturedTrace = null; +Context.create = createContext; +Context.deactivateLongStackTraces = function() {}; +Context.activateLongStackTraces = function() { + var Promise_pushContext = Promise.prototype._pushContext; + var Promise_popContext = Promise.prototype._popContext; + var Promise_PeekContext = Promise._peekContext; + var Promise_peekContext = Promise.prototype._peekContext; + var Promise_promiseCreated = Promise.prototype._promiseCreated; + Context.deactivateLongStackTraces = function() { + Promise.prototype._pushContext = Promise_pushContext; + Promise.prototype._popContext = Promise_popContext; + Promise._peekContext = Promise_PeekContext; + Promise.prototype._peekContext = Promise_peekContext; + Promise.prototype._promiseCreated = Promise_promiseCreated; + longStackTraces = false; + }; + longStackTraces = true; + Promise.prototype._pushContext = Context.prototype._pushContext; + Promise.prototype._popContext = Context.prototype._popContext; + Promise._peekContext = Promise.prototype._peekContext = peekContext; + Promise.prototype._promiseCreated = function() { + var ctx = this._peekContext(); + if (ctx && ctx._promiseCreated == null) ctx._promiseCreated = this; + }; +}; +return Context; +}; +},{}],9:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = function(Promise, Context) { +var getDomain = Promise._getDomain; +var async = Promise._async; +var Warning = _dereq_("./errors").Warning; +var util = _dereq_("./util"); +var canAttachTrace = util.canAttachTrace; +var unhandledRejectionHandled; +var possiblyUnhandledRejection; +var bluebirdFramePattern = + /[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/; +var nodeFramePattern = /\((?:timers\.js):\d+:\d+\)/; +var parseLinePattern = /[\/<\(](.+?):(\d+):(\d+)\)?\s*$/; +var stackFramePattern = null; +var formatStack = null; +var indentStackFrames = false; +var printWarning; +var debugging = !!(util.env("BLUEBIRD_DEBUG") != 0 && + (true || + util.env("BLUEBIRD_DEBUG") || + util.env("NODE_ENV") === "development")); + +var warnings = !!(util.env("BLUEBIRD_WARNINGS") != 0 && + (debugging || util.env("BLUEBIRD_WARNINGS"))); + +var longStackTraces = !!(util.env("BLUEBIRD_LONG_STACK_TRACES") != 0 && + (debugging || util.env("BLUEBIRD_LONG_STACK_TRACES"))); + +var wForgottenReturn = util.env("BLUEBIRD_W_FORGOTTEN_RETURN") != 0 && + (warnings || !!util.env("BLUEBIRD_W_FORGOTTEN_RETURN")); + +Promise.prototype.suppressUnhandledRejections = function() { + var target = this._target(); + target._bitField = ((target._bitField & (~1048576)) | + 524288); +}; + +Promise.prototype._ensurePossibleRejectionHandled = function () { + if ((this._bitField & 524288) !== 0) return; + this._setRejectionIsUnhandled(); + async.invokeLater(this._notifyUnhandledRejection, this, undefined); +}; + +Promise.prototype._notifyUnhandledRejectionIsHandled = function () { + fireRejectionEvent("rejectionHandled", + unhandledRejectionHandled, undefined, this); +}; + +Promise.prototype._setReturnedNonUndefined = function() { + this._bitField = this._bitField | 268435456; +}; + +Promise.prototype._returnedNonUndefined = function() { + return (this._bitField & 268435456) !== 0; +}; +Promise.prototype._notifyUnhandledRejection = function () { + if (this._isRejectionUnhandled()) { + var reason = this._settledValue(); + this._setUnhandledRejectionIsNotified(); + fireRejectionEvent("unhandledRejection", + possiblyUnhandledRejection, reason, this); + } +}; +Promise.prototype._setUnhandledRejectionIsNotified = function () { + this._bitField = this._bitField | 262144; +}; -/** - * Given any node return the first leaf node without children. - * - * @param {DOMElement|DOMTextNode} node - * @return {DOMElement|DOMTextNode} - */ +Promise.prototype._unsetUnhandledRejectionIsNotified = function () { + this._bitField = this._bitField & (~262144); +}; -function getLeafNode(node) { - while (node && node.firstChild) { - node = node.firstChild; - } - return node; -} +Promise.prototype._isUnhandledRejectionNotified = function () { + return (this._bitField & 262144) > 0; +}; -/** - * Get the next sibling within a container. This will walk up the - * DOM if a node's siblings have been exhausted. - * - * @param {DOMElement|DOMTextNode} node - * @return {?DOMElement|DOMTextNode} - */ -function getSiblingNode(node) { - while (node) { - if (node.nextSibling) { - return node.nextSibling; +Promise.prototype._setRejectionIsUnhandled = function () { + this._bitField = this._bitField | 1048576; +}; + +Promise.prototype._unsetRejectionIsUnhandled = function () { + this._bitField = this._bitField & (~1048576); + if (this._isUnhandledRejectionNotified()) { + this._unsetUnhandledRejectionIsNotified(); + this._notifyUnhandledRejectionIsHandled(); } - node = node.parentNode; - } -} +}; -/** - * Get object describing the nodes which contain characters at offset. - * - * @param {DOMElement|DOMTextNode} root - * @param {number} offset - * @return {?object} - */ -function getNodeForCharacterOffset(root, offset) { - var node = getLeafNode(root); - var nodeStart = 0; - var nodeEnd = 0; +Promise.prototype._isRejectionUnhandled = function () { + return (this._bitField & 1048576) > 0; +}; - while (node) { - if (node.nodeType === 3) { - nodeEnd = nodeStart + node.textContent.length; +Promise.prototype._warn = function(message, shouldUseOwnTrace, promise) { + return warn(message, shouldUseOwnTrace, promise || this); +}; - if (nodeStart <= offset && nodeEnd >= offset) { - return { - node: node, - offset: offset - nodeStart +Promise.onPossiblyUnhandledRejection = function (fn) { + var domain = getDomain(); + possiblyUnhandledRejection = + typeof fn === "function" ? (domain === null ? + fn : util.domainBind(domain, fn)) + : undefined; +}; + +Promise.onUnhandledRejectionHandled = function (fn) { + var domain = getDomain(); + unhandledRejectionHandled = + typeof fn === "function" ? (domain === null ? + fn : util.domainBind(domain, fn)) + : undefined; +}; + +var disableLongStackTraces = function() {}; +Promise.longStackTraces = function () { + if (async.haveItemsQueued() && !config.longStackTraces) { + throw new Error("cannot enable long stack traces after promises have been created\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + if (!config.longStackTraces && longStackTracesIsSupported()) { + var Promise_captureStackTrace = Promise.prototype._captureStackTrace; + var Promise_attachExtraTrace = Promise.prototype._attachExtraTrace; + config.longStackTraces = true; + disableLongStackTraces = function() { + if (async.haveItemsQueued() && !config.longStackTraces) { + throw new Error("cannot enable long stack traces after promises have been created\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + Promise.prototype._captureStackTrace = Promise_captureStackTrace; + Promise.prototype._attachExtraTrace = Promise_attachExtraTrace; + Context.deactivateLongStackTraces(); + async.enableTrampoline(); + config.longStackTraces = false; }; - } + Promise.prototype._captureStackTrace = longStackTracesCaptureStackTrace; + Promise.prototype._attachExtraTrace = longStackTracesAttachExtraTrace; + Context.activateLongStackTraces(); + async.disableTrampolineIfNecessary(); + } +}; - nodeStart = nodeEnd; +Promise.hasLongStackTraces = function () { + return config.longStackTraces && longStackTracesIsSupported(); +}; + +var fireDomEvent = (function() { + try { + if (typeof CustomEvent === "function") { + var event = new CustomEvent("CustomEvent"); + util.global.dispatchEvent(event); + return function(name, event) { + var domEvent = new CustomEvent(name.toLowerCase(), { + detail: event, + cancelable: true + }); + return !util.global.dispatchEvent(domEvent); + }; + } else if (typeof Event === "function") { + var event = new Event("CustomEvent"); + util.global.dispatchEvent(event); + return function(name, event) { + var domEvent = new Event(name.toLowerCase(), { + cancelable: true + }); + domEvent.detail = event; + return !util.global.dispatchEvent(domEvent); + }; + } else { + var event = document.createEvent("CustomEvent"); + event.initCustomEvent("testingtheevent", false, true, {}); + util.global.dispatchEvent(event); + return function(name, event) { + var domEvent = document.createEvent("CustomEvent"); + domEvent.initCustomEvent(name.toLowerCase(), false, true, + event); + return !util.global.dispatchEvent(domEvent); + }; + } + } catch (e) {} + return function() { + return false; + }; +})(); + +var fireGlobalEvent = (function() { + if (util.isNode) { + return function() { + return process.emit.apply(process, arguments); + }; + } else { + if (!util.global) { + return function() { + return false; + }; + } + return function(name) { + var methodName = "on" + name.toLowerCase(); + var method = util.global[methodName]; + if (!method) return false; + method.apply(util.global, [].slice.call(arguments, 1)); + return true; + }; } +})(); - node = getLeafNode(getSiblingNode(node)); - } +function generatePromiseLifecycleEventObject(name, promise) { + return {promise: promise}; } -module.exports = getNodeForCharacterOffset; +var eventToObjectGenerator = { + promiseCreated: generatePromiseLifecycleEventObject, + promiseFulfilled: generatePromiseLifecycleEventObject, + promiseRejected: generatePromiseLifecycleEventObject, + promiseResolved: generatePromiseLifecycleEventObject, + promiseCancelled: generatePromiseLifecycleEventObject, + promiseChained: function(name, promise, child) { + return {promise: promise, child: child}; + }, + warning: function(name, warning) { + return {warning: warning}; + }, + unhandledRejection: function (name, reason, promise) { + return {reason: reason, promise: promise}; + }, + rejectionHandled: generatePromiseLifecycleEventObject +}; -/***/ }), -/* 195 */ -/***/ (function(module, exports, __webpack_require__) { +var activeFireEvent = function (name) { + var globalEventFired = false; + try { + globalEventFired = fireGlobalEvent.apply(null, arguments); + } catch (e) { + async.throwLater(e); + globalEventFired = true; + } -"use strict"; + var domEventFired = false; + try { + domEventFired = fireDomEvent(name, + eventToObjectGenerator[name].apply(null, arguments)); + } catch (e) { + async.throwLater(e); + domEventFired = true; + } + return domEventFired || globalEventFired; +}; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Promise.config = function(opts) { + opts = Object(opts); + if ("longStackTraces" in opts) { + if (opts.longStackTraces) { + Promise.longStackTraces(); + } else if (!opts.longStackTraces && Promise.hasLongStackTraces()) { + disableLongStackTraces(); + } + } + if ("warnings" in opts) { + var warningsOption = opts.warnings; + config.warnings = !!warningsOption; + wForgottenReturn = config.warnings; -var isTextNode = __webpack_require__(196); + if (util.isObject(warningsOption)) { + if ("wForgottenReturn" in warningsOption) { + wForgottenReturn = !!warningsOption.wForgottenReturn; + } + } + } + if ("cancellation" in opts && opts.cancellation && !config.cancellation) { + if (async.haveItemsQueued()) { + throw new Error( + "cannot enable cancellation after promises are in use"); + } + Promise.prototype._clearCancellationData = + cancellationClearCancellationData; + Promise.prototype._propagateFrom = cancellationPropagateFrom; + Promise.prototype._onCancel = cancellationOnCancel; + Promise.prototype._setOnCancel = cancellationSetOnCancel; + Promise.prototype._attachCancellationCallback = + cancellationAttachCancellationCallback; + Promise.prototype._execute = cancellationExecute; + propagateFromFunction = cancellationPropagateFrom; + config.cancellation = true; + } + if ("monitoring" in opts) { + if (opts.monitoring && !config.monitoring) { + config.monitoring = true; + Promise.prototype._fireEvent = activeFireEvent; + } else if (!opts.monitoring && config.monitoring) { + config.monitoring = false; + Promise.prototype._fireEvent = defaultFireEvent; + } + } + return Promise; +}; -/*eslint-disable no-bitwise */ +function defaultFireEvent() { return false; } -/** - * Checks if a given DOM node contains or is another DOM node. - */ -function containsNode(outerNode, innerNode) { - if (!outerNode || !innerNode) { - return false; - } else if (outerNode === innerNode) { - return true; - } else if (isTextNode(outerNode)) { - return false; - } else if (isTextNode(innerNode)) { - return containsNode(outerNode, innerNode.parentNode); - } else if ('contains' in outerNode) { - return outerNode.contains(innerNode); - } else if (outerNode.compareDocumentPosition) { - return !!(outerNode.compareDocumentPosition(innerNode) & 16); - } else { - return false; - } +Promise.prototype._fireEvent = defaultFireEvent; +Promise.prototype._execute = function(executor, resolve, reject) { + try { + executor(resolve, reject); + } catch (e) { + return e; + } +}; +Promise.prototype._onCancel = function () {}; +Promise.prototype._setOnCancel = function (handler) { ; }; +Promise.prototype._attachCancellationCallback = function(onCancel) { + ; +}; +Promise.prototype._captureStackTrace = function () {}; +Promise.prototype._attachExtraTrace = function () {}; +Promise.prototype._clearCancellationData = function() {}; +Promise.prototype._propagateFrom = function (parent, flags) { + ; + ; +}; + +function cancellationExecute(executor, resolve, reject) { + var promise = this; + try { + executor(resolve, reject, function(onCancel) { + if (typeof onCancel !== "function") { + throw new TypeError("onCancel must be a function, got: " + + util.toString(onCancel)); + } + promise._attachCancellationCallback(onCancel); + }); + } catch (e) { + return e; + } } -module.exports = containsNode; +function cancellationAttachCancellationCallback(onCancel) { + if (!this._isCancellable()) return this; -/***/ }), -/* 196 */ -/***/ (function(module, exports, __webpack_require__) { + var previousOnCancel = this._onCancel(); + if (previousOnCancel !== undefined) { + if (util.isArray(previousOnCancel)) { + previousOnCancel.push(onCancel); + } else { + this._setOnCancel([previousOnCancel, onCancel]); + } + } else { + this._setOnCancel(onCancel); + } +} -"use strict"; +function cancellationOnCancel() { + return this._onCancelField; +} +function cancellationSetOnCancel(onCancel) { + this._onCancelField = onCancel; +} -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +function cancellationClearCancellationData() { + this._cancellationParent = undefined; + this._onCancelField = undefined; +} -var isNode = __webpack_require__(197); +function cancellationPropagateFrom(parent, flags) { + if ((flags & 1) !== 0) { + this._cancellationParent = parent; + var branchesRemainingToCancel = parent._branchesRemainingToCancel; + if (branchesRemainingToCancel === undefined) { + branchesRemainingToCancel = 0; + } + parent._branchesRemainingToCancel = branchesRemainingToCancel + 1; + } + if ((flags & 2) !== 0 && parent._isBound()) { + this._setBoundTo(parent._boundTo); + } +} -/** - * @param {*} object The object to check. - * @return {boolean} Whether or not the object is a DOM text node. - */ -function isTextNode(object) { - return isNode(object) && object.nodeType == 3; +function bindingPropagateFrom(parent, flags) { + if ((flags & 2) !== 0 && parent._isBound()) { + this._setBoundTo(parent._boundTo); + } +} +var propagateFromFunction = bindingPropagateFrom; + +function boundValueFunction() { + var ret = this._boundTo; + if (ret !== undefined) { + if (ret instanceof Promise) { + if (ret.isFulfilled()) { + return ret.value(); + } else { + return undefined; + } + } + } + return ret; } -module.exports = isTextNode; +function longStackTracesCaptureStackTrace() { + this._trace = new CapturedTrace(this._peekContext()); +} -/***/ }), -/* 197 */ -/***/ (function(module, exports, __webpack_require__) { +function longStackTracesAttachExtraTrace(error, ignoreSelf) { + if (canAttachTrace(error)) { + var trace = this._trace; + if (trace !== undefined) { + if (ignoreSelf) trace = trace._parent; + } + if (trace !== undefined) { + trace.attachExtraTrace(error); + } else if (!error.__stackCleaned__) { + var parsed = parseStackAndMessage(error); + util.notEnumerableProp(error, "stack", + parsed.message + "\n" + parsed.stack.join("\n")); + util.notEnumerableProp(error, "__stackCleaned__", true); + } + } +} -"use strict"; +function checkForgottenReturns(returnValue, promiseCreated, name, promise, + parent) { + if (returnValue === undefined && promiseCreated !== null && + wForgottenReturn) { + if (parent !== undefined && parent._returnedNonUndefined()) return; + if ((promise._bitField & 65535) === 0) return; + + if (name) name = name + " "; + var handlerLine = ""; + var creatorLine = ""; + if (promiseCreated._trace) { + var traceLines = promiseCreated._trace.stack.split("\n"); + var stack = cleanStack(traceLines); + for (var i = stack.length - 1; i >= 0; --i) { + var line = stack[i]; + if (!nodeFramePattern.test(line)) { + var lineMatches = line.match(parseLinePattern); + if (lineMatches) { + handlerLine = "at " + lineMatches[1] + + ":" + lineMatches[2] + ":" + lineMatches[3] + " "; + } + break; + } + } + if (stack.length > 0) { + var firstUserLine = stack[0]; + for (var i = 0; i < traceLines.length; ++i) { -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + if (traceLines[i] === firstUserLine) { + if (i > 0) { + creatorLine = "\n" + traceLines[i - 1]; + } + break; + } + } -/** - * @param {*} object The object to check. - * @return {boolean} Whether or not the object is a DOM node. - */ -function isNode(object) { - var doc = object ? object.ownerDocument || object : document; - var defaultView = doc.defaultView || window; - return !!(object && (typeof defaultView.Node === 'function' ? object instanceof defaultView.Node : typeof object === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string')); + } + } + var msg = "a promise was created in a " + name + + "handler " + handlerLine + "but was not returned from it, " + + "see http://goo.gl/rRqMUw" + + creatorLine; + promise._warn(msg, true, promiseCreated); + } } -module.exports = isNode; - -/***/ }), -/* 198 */ -/***/ (function(module, exports, __webpack_require__) { +function deprecated(name, replacement) { + var message = name + + " is deprecated and will be removed in a future version."; + if (replacement) message += " Use " + replacement + " instead."; + return warn(message); +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function warn(message, shouldUseOwnTrace, promise) { + if (!config.warnings) return; + var warning = new Warning(message); + var ctx; + if (shouldUseOwnTrace) { + promise._attachExtraTrace(warning); + } else if (config.longStackTraces && (ctx = Promise._peekContext())) { + ctx.attachExtraTrace(warning); + } else { + var parsed = parseStackAndMessage(warning); + warning.stack = parsed.message + "\n" + parsed.stack.join("\n"); + } + if (!activeFireEvent("warning", warning)) { + formatAndLogError(warning, "", true); + } +} +function reconstructStack(message, stacks) { + for (var i = 0; i < stacks.length - 1; ++i) { + stacks[i].push("From previous event:"); + stacks[i] = stacks[i].join("\n"); + } + if (i < stacks.length) { + stacks[i] = stacks[i].join("\n"); + } + return message + "\n" + stacks.join("\n"); +} -var NS = { - xlink: 'http://www.w3.org/1999/xlink', - xml: 'http://www.w3.org/XML/1998/namespace' -}; +function removeDuplicateOrEmptyJumps(stacks) { + for (var i = 0; i < stacks.length; ++i) { + if (stacks[i].length === 0 || + ((i + 1 < stacks.length) && stacks[i][0] === stacks[i+1][0])) { + stacks.splice(i, 1); + i--; + } + } +} -// We use attributes for everything SVG so let's avoid some duplication and run -// code instead. -// The following are all specified in the HTML config already so we exclude here. -// - class (as className) -// - color -// - height -// - id -// - lang -// - max -// - media -// - method -// - min -// - name -// - style -// - target -// - type -// - width -var ATTRS = { - accentHeight: 'accent-height', - accumulate: 0, - additive: 0, - alignmentBaseline: 'alignment-baseline', - allowReorder: 'allowReorder', - alphabetic: 0, - amplitude: 0, - arabicForm: 'arabic-form', - ascent: 0, - attributeName: 'attributeName', - attributeType: 'attributeType', - autoReverse: 'autoReverse', - azimuth: 0, - baseFrequency: 'baseFrequency', - baseProfile: 'baseProfile', - baselineShift: 'baseline-shift', - bbox: 0, - begin: 0, - bias: 0, - by: 0, - calcMode: 'calcMode', - capHeight: 'cap-height', - clip: 0, - clipPath: 'clip-path', - clipRule: 'clip-rule', - clipPathUnits: 'clipPathUnits', - colorInterpolation: 'color-interpolation', - colorInterpolationFilters: 'color-interpolation-filters', - colorProfile: 'color-profile', - colorRendering: 'color-rendering', - contentScriptType: 'contentScriptType', - contentStyleType: 'contentStyleType', - cursor: 0, - cx: 0, - cy: 0, - d: 0, - decelerate: 0, - descent: 0, - diffuseConstant: 'diffuseConstant', - direction: 0, - display: 0, - divisor: 0, - dominantBaseline: 'dominant-baseline', - dur: 0, - dx: 0, - dy: 0, - edgeMode: 'edgeMode', - elevation: 0, - enableBackground: 'enable-background', - end: 0, - exponent: 0, - externalResourcesRequired: 'externalResourcesRequired', - fill: 0, - fillOpacity: 'fill-opacity', - fillRule: 'fill-rule', - filter: 0, - filterRes: 'filterRes', - filterUnits: 'filterUnits', - floodColor: 'flood-color', - floodOpacity: 'flood-opacity', - focusable: 0, - fontFamily: 'font-family', - fontSize: 'font-size', - fontSizeAdjust: 'font-size-adjust', - fontStretch: 'font-stretch', - fontStyle: 'font-style', - fontVariant: 'font-variant', - fontWeight: 'font-weight', - format: 0, - from: 0, - fx: 0, - fy: 0, - g1: 0, - g2: 0, - glyphName: 'glyph-name', - glyphOrientationHorizontal: 'glyph-orientation-horizontal', - glyphOrientationVertical: 'glyph-orientation-vertical', - glyphRef: 'glyphRef', - gradientTransform: 'gradientTransform', - gradientUnits: 'gradientUnits', - hanging: 0, - horizAdvX: 'horiz-adv-x', - horizOriginX: 'horiz-origin-x', - ideographic: 0, - imageRendering: 'image-rendering', - 'in': 0, - in2: 0, - intercept: 0, - k: 0, - k1: 0, - k2: 0, - k3: 0, - k4: 0, - kernelMatrix: 'kernelMatrix', - kernelUnitLength: 'kernelUnitLength', - kerning: 0, - keyPoints: 'keyPoints', - keySplines: 'keySplines', - keyTimes: 'keyTimes', - lengthAdjust: 'lengthAdjust', - letterSpacing: 'letter-spacing', - lightingColor: 'lighting-color', - limitingConeAngle: 'limitingConeAngle', - local: 0, - markerEnd: 'marker-end', - markerMid: 'marker-mid', - markerStart: 'marker-start', - markerHeight: 'markerHeight', - markerUnits: 'markerUnits', - markerWidth: 'markerWidth', - mask: 0, - maskContentUnits: 'maskContentUnits', - maskUnits: 'maskUnits', - mathematical: 0, - mode: 0, - numOctaves: 'numOctaves', - offset: 0, - opacity: 0, - operator: 0, - order: 0, - orient: 0, - orientation: 0, - origin: 0, - overflow: 0, - overlinePosition: 'overline-position', - overlineThickness: 'overline-thickness', - paintOrder: 'paint-order', - panose1: 'panose-1', - pathLength: 'pathLength', - patternContentUnits: 'patternContentUnits', - patternTransform: 'patternTransform', - patternUnits: 'patternUnits', - pointerEvents: 'pointer-events', - points: 0, - pointsAtX: 'pointsAtX', - pointsAtY: 'pointsAtY', - pointsAtZ: 'pointsAtZ', - preserveAlpha: 'preserveAlpha', - preserveAspectRatio: 'preserveAspectRatio', - primitiveUnits: 'primitiveUnits', - r: 0, - radius: 0, - refX: 'refX', - refY: 'refY', - renderingIntent: 'rendering-intent', - repeatCount: 'repeatCount', - repeatDur: 'repeatDur', - requiredExtensions: 'requiredExtensions', - requiredFeatures: 'requiredFeatures', - restart: 0, - result: 0, - rotate: 0, - rx: 0, - ry: 0, - scale: 0, - seed: 0, - shapeRendering: 'shape-rendering', - slope: 0, - spacing: 0, - specularConstant: 'specularConstant', - specularExponent: 'specularExponent', - speed: 0, - spreadMethod: 'spreadMethod', - startOffset: 'startOffset', - stdDeviation: 'stdDeviation', - stemh: 0, - stemv: 0, - stitchTiles: 'stitchTiles', - stopColor: 'stop-color', - stopOpacity: 'stop-opacity', - strikethroughPosition: 'strikethrough-position', - strikethroughThickness: 'strikethrough-thickness', - string: 0, - stroke: 0, - strokeDasharray: 'stroke-dasharray', - strokeDashoffset: 'stroke-dashoffset', - strokeLinecap: 'stroke-linecap', - strokeLinejoin: 'stroke-linejoin', - strokeMiterlimit: 'stroke-miterlimit', - strokeOpacity: 'stroke-opacity', - strokeWidth: 'stroke-width', - surfaceScale: 'surfaceScale', - systemLanguage: 'systemLanguage', - tableValues: 'tableValues', - targetX: 'targetX', - targetY: 'targetY', - textAnchor: 'text-anchor', - textDecoration: 'text-decoration', - textRendering: 'text-rendering', - textLength: 'textLength', - to: 0, - transform: 0, - u1: 0, - u2: 0, - underlinePosition: 'underline-position', - underlineThickness: 'underline-thickness', - unicode: 0, - unicodeBidi: 'unicode-bidi', - unicodeRange: 'unicode-range', - unitsPerEm: 'units-per-em', - vAlphabetic: 'v-alphabetic', - vHanging: 'v-hanging', - vIdeographic: 'v-ideographic', - vMathematical: 'v-mathematical', - values: 0, - vectorEffect: 'vector-effect', - version: 0, - vertAdvY: 'vert-adv-y', - vertOriginX: 'vert-origin-x', - vertOriginY: 'vert-origin-y', - viewBox: 'viewBox', - viewTarget: 'viewTarget', - visibility: 0, - widths: 0, - wordSpacing: 'word-spacing', - writingMode: 'writing-mode', - x: 0, - xHeight: 'x-height', - x1: 0, - x2: 0, - xChannelSelector: 'xChannelSelector', - xlinkActuate: 'xlink:actuate', - xlinkArcrole: 'xlink:arcrole', - xlinkHref: 'xlink:href', - xlinkRole: 'xlink:role', - xlinkShow: 'xlink:show', - xlinkTitle: 'xlink:title', - xlinkType: 'xlink:type', - xmlBase: 'xml:base', - xmlns: 0, - xmlnsXlink: 'xmlns:xlink', - xmlLang: 'xml:lang', - xmlSpace: 'xml:space', - y: 0, - y1: 0, - y2: 0, - yChannelSelector: 'yChannelSelector', - z: 0, - zoomAndPan: 'zoomAndPan' +function removeCommonRoots(stacks) { + var current = stacks[0]; + for (var i = 1; i < stacks.length; ++i) { + var prev = stacks[i]; + var currentLastIndex = current.length - 1; + var currentLastLine = current[currentLastIndex]; + var commonRootMeetPoint = -1; + + for (var j = prev.length - 1; j >= 0; --j) { + if (prev[j] === currentLastLine) { + commonRootMeetPoint = j; + break; + } + } + + for (var j = commonRootMeetPoint; j >= 0; --j) { + var line = prev[j]; + if (current[currentLastIndex] === line) { + current.pop(); + currentLastIndex--; + } else { + break; + } + } + current = prev; + } +} + +function cleanStack(stack) { + var ret = []; + for (var i = 0; i < stack.length; ++i) { + var line = stack[i]; + var isTraceLine = " (No stack trace)" === line || + stackFramePattern.test(line); + var isInternalFrame = isTraceLine && shouldIgnore(line); + if (isTraceLine && !isInternalFrame) { + if (indentStackFrames && line.charAt(0) !== " ") { + line = " " + line; + } + ret.push(line); + } + } + return ret; +} + +function stackFramesAsArray(error) { + var stack = error.stack.replace(/\s+$/g, "").split("\n"); + for (var i = 0; i < stack.length; ++i) { + var line = stack[i]; + if (" (No stack trace)" === line || stackFramePattern.test(line)) { + break; + } + } + if (i > 0 && error.name != "SyntaxError") { + stack = stack.slice(i); + } + return stack; +} + +function parseStackAndMessage(error) { + var stack = error.stack; + var message = error.toString(); + stack = typeof stack === "string" && stack.length > 0 + ? stackFramesAsArray(error) : [" (No stack trace)"]; + return { + message: message, + stack: error.name == "SyntaxError" ? stack : cleanStack(stack) + }; +} + +function formatAndLogError(error, title, isSoft) { + if (typeof console !== "undefined") { + var message; + if (util.isObject(error)) { + var stack = error.stack; + message = title + formatStack(stack, error); + } else { + message = title + String(error); + } + if (typeof printWarning === "function") { + printWarning(message, isSoft); + } else if (typeof console.log === "function" || + typeof console.log === "object") { + console.log(message); + } + } +} + +function fireRejectionEvent(name, localHandler, reason, promise) { + var localEventFired = false; + try { + if (typeof localHandler === "function") { + localEventFired = true; + if (name === "rejectionHandled") { + localHandler(promise); + } else { + localHandler(reason, promise); + } + } + } catch (e) { + async.throwLater(e); + } + + if (name === "unhandledRejection") { + if (!activeFireEvent(name, reason, promise) && !localEventFired) { + formatAndLogError(reason, "Unhandled rejection "); + } + } else { + activeFireEvent(name, promise); + } +} + +function formatNonError(obj) { + var str; + if (typeof obj === "function") { + str = "[function " + + (obj.name || "anonymous") + + "]"; + } else { + str = obj && typeof obj.toString === "function" + ? obj.toString() : util.toString(obj); + var ruselessToString = /\[object [a-zA-Z0-9$_]+\]/; + if (ruselessToString.test(str)) { + try { + var newStr = JSON.stringify(obj); + str = newStr; + } + catch(e) { + + } + } + if (str.length === 0) { + str = "(empty array)"; + } + } + return ("(<" + snip(str) + ">, no stack trace)"); +} + +function snip(str) { + var maxChars = 41; + if (str.length < maxChars) { + return str; + } + return str.substr(0, maxChars - 3) + "..."; +} + +function longStackTracesIsSupported() { + return typeof captureStackTrace === "function"; +} + +var shouldIgnore = function() { return false; }; +var parseLineInfoRegex = /[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/; +function parseLineInfo(line) { + var matches = line.match(parseLineInfoRegex); + if (matches) { + return { + fileName: matches[1], + line: parseInt(matches[2], 10) + }; + } +} + +function setBounds(firstLineError, lastLineError) { + if (!longStackTracesIsSupported()) return; + var firstStackLines = firstLineError.stack.split("\n"); + var lastStackLines = lastLineError.stack.split("\n"); + var firstIndex = -1; + var lastIndex = -1; + var firstFileName; + var lastFileName; + for (var i = 0; i < firstStackLines.length; ++i) { + var result = parseLineInfo(firstStackLines[i]); + if (result) { + firstFileName = result.fileName; + firstIndex = result.line; + break; + } + } + for (var i = 0; i < lastStackLines.length; ++i) { + var result = parseLineInfo(lastStackLines[i]); + if (result) { + lastFileName = result.fileName; + lastIndex = result.line; + break; + } + } + if (firstIndex < 0 || lastIndex < 0 || !firstFileName || !lastFileName || + firstFileName !== lastFileName || firstIndex >= lastIndex) { + return; + } + + shouldIgnore = function(line) { + if (bluebirdFramePattern.test(line)) return true; + var info = parseLineInfo(line); + if (info) { + if (info.fileName === firstFileName && + (firstIndex <= info.line && info.line <= lastIndex)) { + return true; + } + } + return false; + }; +} + +function CapturedTrace(parent) { + this._parent = parent; + this._promisesCreated = 0; + var length = this._length = 1 + (parent === undefined ? 0 : parent._length); + captureStackTrace(this, CapturedTrace); + if (length > 32) this.uncycle(); +} +util.inherits(CapturedTrace, Error); +Context.CapturedTrace = CapturedTrace; + +CapturedTrace.prototype.uncycle = function() { + var length = this._length; + if (length < 2) return; + var nodes = []; + var stackToIndex = {}; + + for (var i = 0, node = this; node !== undefined; ++i) { + nodes.push(node); + node = node._parent; + } + length = this._length = i; + for (var i = length - 1; i >= 0; --i) { + var stack = nodes[i].stack; + if (stackToIndex[stack] === undefined) { + stackToIndex[stack] = i; + } + } + for (var i = 0; i < length; ++i) { + var currentStack = nodes[i].stack; + var index = stackToIndex[currentStack]; + if (index !== undefined && index !== i) { + if (index > 0) { + nodes[index - 1]._parent = undefined; + nodes[index - 1]._length = 1; + } + nodes[i]._parent = undefined; + nodes[i]._length = 1; + var cycleEdgeNode = i > 0 ? nodes[i - 1] : this; + + if (index < length - 1) { + cycleEdgeNode._parent = nodes[index + 1]; + cycleEdgeNode._parent.uncycle(); + cycleEdgeNode._length = + cycleEdgeNode._parent._length + 1; + } else { + cycleEdgeNode._parent = undefined; + cycleEdgeNode._length = 1; + } + var currentChildLength = cycleEdgeNode._length + 1; + for (var j = i - 2; j >= 0; --j) { + nodes[j]._length = currentChildLength; + currentChildLength++; + } + return; + } + } }; -var SVGDOMPropertyConfig = { - Properties: {}, - DOMAttributeNamespaces: { - xlinkActuate: NS.xlink, - xlinkArcrole: NS.xlink, - xlinkHref: NS.xlink, - xlinkRole: NS.xlink, - xlinkShow: NS.xlink, - xlinkTitle: NS.xlink, - xlinkType: NS.xlink, - xmlBase: NS.xml, - xmlLang: NS.xml, - xmlSpace: NS.xml - }, - DOMAttributeNames: {} +CapturedTrace.prototype.attachExtraTrace = function(error) { + if (error.__stackCleaned__) return; + this.uncycle(); + var parsed = parseStackAndMessage(error); + var message = parsed.message; + var stacks = [parsed.stack]; + + var trace = this; + while (trace !== undefined) { + stacks.push(cleanStack(trace.stack.split("\n"))); + trace = trace._parent; + } + removeCommonRoots(stacks); + removeDuplicateOrEmptyJumps(stacks); + util.notEnumerableProp(error, "stack", reconstructStack(message, stacks)); + util.notEnumerableProp(error, "__stackCleaned__", true); }; -Object.keys(ATTRS).forEach(function (key) { - SVGDOMPropertyConfig.Properties[key] = 0; - if (ATTRS[key]) { - SVGDOMPropertyConfig.DOMAttributeNames[key] = ATTRS[key]; - } -}); +var captureStackTrace = (function stackDetection() { + var v8stackFramePattern = /^\s*at\s*/; + var v8stackFormatter = function(stack, error) { + if (typeof stack === "string") return stack; -module.exports = SVGDOMPropertyConfig; + if (error.name !== undefined && + error.message !== undefined) { + return error.toString(); + } + return formatNonError(error); + }; -/***/ }), -/* 199 */ -/***/ (function(module, exports, __webpack_require__) { + if (typeof Error.stackTraceLimit === "number" && + typeof Error.captureStackTrace === "function") { + Error.stackTraceLimit += 6; + stackFramePattern = v8stackFramePattern; + formatStack = v8stackFormatter; + var captureStackTrace = Error.captureStackTrace; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + shouldIgnore = function(line) { + return bluebirdFramePattern.test(line); + }; + return function(receiver, ignoreUntil) { + Error.stackTraceLimit += 6; + captureStackTrace(receiver, ignoreUntil); + Error.stackTraceLimit -= 6; + }; + } + var err = new Error(); + + if (typeof err.stack === "string" && + err.stack.split("\n")[0].indexOf("stackDetection@") >= 0) { + stackFramePattern = /@/; + formatStack = v8stackFormatter; + indentStackFrames = true; + return function captureStackTrace(o) { + o.stack = new Error().stack; + }; + } + + var hasStackAfterThrow; + try { throw new Error(); } + catch(e) { + hasStackAfterThrow = ("stack" in e); + } + if (!("stack" in err) && hasStackAfterThrow && + typeof Error.stackTraceLimit === "number") { + stackFramePattern = v8stackFramePattern; + formatStack = v8stackFormatter; + return function captureStackTrace(o) { + Error.stackTraceLimit += 6; + try { throw new Error(); } + catch(e) { o.stack = e.stack; } + Error.stackTraceLimit -= 6; + }; + } + formatStack = function(stack, error) { + if (typeof stack === "string") return stack; + if ((typeof error === "object" || + typeof error === "function") && + error.name !== undefined && + error.message !== undefined) { + return error.toString(); + } + return formatNonError(error); + }; -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInputSelection = __webpack_require__(102); -var SyntheticEvent = __webpack_require__(16); + return null; -var getActiveElement = __webpack_require__(103); -var isTextInputElement = __webpack_require__(88); -var shallowEqual = __webpack_require__(60); +})([]); -var skipSelectionChangeEvent = ExecutionEnvironment.canUseDOM && 'documentMode' in document && document.documentMode <= 11; +if (typeof console !== "undefined" && typeof console.warn !== "undefined") { + printWarning = function (message) { + console.warn(message); + }; + if (util.isNode && process.stderr.isTTY) { + printWarning = function(message, isSoft) { + var color = isSoft ? "\u001b[33m" : "\u001b[31m"; + console.warn(color + message + "\u001b[0m\n"); + }; + } else if (!util.isNode && typeof (new Error().stack) === "string") { + printWarning = function(message, isSoft) { + console.warn("%c" + message, + isSoft ? "color: darkorange" : "color: red"); + }; + } +} -var eventTypes = { - select: { - phasedRegistrationNames: { - bubbled: 'onSelect', - captured: 'onSelectCapture' +var config = { + warnings: warnings, + longStackTraces: false, + cancellation: false, + monitoring: false +}; + +if (longStackTraces) Promise.longStackTraces(); + +return { + longStackTraces: function() { + return config.longStackTraces; }, - dependencies: ['topBlur', 'topContextMenu', 'topFocus', 'topKeyDown', 'topKeyUp', 'topMouseDown', 'topMouseUp', 'topSelectionChange'] - } + warnings: function() { + return config.warnings; + }, + cancellation: function() { + return config.cancellation; + }, + monitoring: function() { + return config.monitoring; + }, + propagateFromFunction: function() { + return propagateFromFunction; + }, + boundValueFunction: function() { + return boundValueFunction; + }, + checkForgottenReturns: checkForgottenReturns, + setBounds: setBounds, + warn: warn, + deprecated: deprecated, + CapturedTrace: CapturedTrace, + fireDomEvent: fireDomEvent, + fireGlobalEvent: fireGlobalEvent +}; }; -var activeElement = null; -var activeElementInst = null; -var lastSelection = null; -var mouseDown = false; +},{"./errors":12,"./util":36}],10:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +function returner() { + return this.value; +} +function thrower() { + throw this.reason; +} -// Track whether a listener exists for this plugin. If none exist, we do -// not extract events. See #3639. -var hasListener = false; +Promise.prototype["return"] = +Promise.prototype.thenReturn = function (value) { + if (value instanceof Promise) value.suppressUnhandledRejections(); + return this._then( + returner, undefined, undefined, {value: value}, undefined); +}; -/** - * Get an object which is a unique representation of the current selection. - * - * The return value will not be consistent across nodes or browsers, but - * two identical selections on the same node will return identical objects. - * - * @param {DOMElement} node - * @return {object} - */ -function getSelection(node) { - if ('selectionStart' in node && ReactInputSelection.hasSelectionCapabilities(node)) { - return { - start: node.selectionStart, - end: node.selectionEnd +Promise.prototype["throw"] = +Promise.prototype.thenThrow = function (reason) { + return this._then( + thrower, undefined, undefined, {reason: reason}, undefined); +}; + +Promise.prototype.catchThrow = function (reason) { + if (arguments.length <= 1) { + return this._then( + undefined, thrower, undefined, {reason: reason}, undefined); + } else { + var _reason = arguments[1]; + var handler = function() {throw _reason;}; + return this.caught(reason, handler); + } +}; + +Promise.prototype.catchReturn = function (value) { + if (arguments.length <= 1) { + if (value instanceof Promise) value.suppressUnhandledRejections(); + return this._then( + undefined, returner, undefined, {value: value}, undefined); + } else { + var _value = arguments[1]; + if (_value instanceof Promise) _value.suppressUnhandledRejections(); + var handler = function() {return _value;}; + return this.caught(value, handler); + } +}; +}; + +},{}],11:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL) { +var PromiseReduce = Promise.reduce; +var PromiseAll = Promise.all; + +function promiseAllThis() { + return PromiseAll(this); +} + +function PromiseMapSeries(promises, fn) { + return PromiseReduce(promises, fn, INTERNAL, INTERNAL); +} + +Promise.prototype.each = function (fn) { + return PromiseReduce(this, fn, INTERNAL, 0) + ._then(promiseAllThis, undefined, undefined, this, undefined); +}; + +Promise.prototype.mapSeries = function (fn) { + return PromiseReduce(this, fn, INTERNAL, INTERNAL); +}; + +Promise.each = function (promises, fn) { + return PromiseReduce(promises, fn, INTERNAL, 0) + ._then(promiseAllThis, undefined, undefined, promises, undefined); +}; + +Promise.mapSeries = PromiseMapSeries; +}; + + +},{}],12:[function(_dereq_,module,exports){ +"use strict"; +var es5 = _dereq_("./es5"); +var Objectfreeze = es5.freeze; +var util = _dereq_("./util"); +var inherits = util.inherits; +var notEnumerableProp = util.notEnumerableProp; + +function subError(nameProperty, defaultMessage) { + function SubError(message) { + if (!(this instanceof SubError)) return new SubError(message); + notEnumerableProp(this, "message", + typeof message === "string" ? message : defaultMessage); + notEnumerableProp(this, "name", nameProperty); + if (Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } else { + Error.call(this); + } + } + inherits(SubError, Error); + return SubError; +} + +var _TypeError, _RangeError; +var Warning = subError("Warning", "warning"); +var CancellationError = subError("CancellationError", "cancellation error"); +var TimeoutError = subError("TimeoutError", "timeout error"); +var AggregateError = subError("AggregateError", "aggregate error"); +try { + _TypeError = TypeError; + _RangeError = RangeError; +} catch(e) { + _TypeError = subError("TypeError", "type error"); + _RangeError = subError("RangeError", "range error"); +} + +var methods = ("join pop push shift unshift slice filter forEach some " + + "every map indexOf lastIndexOf reduce reduceRight sort reverse").split(" "); + +for (var i = 0; i < methods.length; ++i) { + if (typeof Array.prototype[methods[i]] === "function") { + AggregateError.prototype[methods[i]] = Array.prototype[methods[i]]; + } +} + +es5.defineProperty(AggregateError.prototype, "length", { + value: 0, + configurable: false, + writable: true, + enumerable: true +}); +AggregateError.prototype["isOperational"] = true; +var level = 0; +AggregateError.prototype.toString = function() { + var indent = Array(level * 4 + 1).join(" "); + var ret = "\n" + indent + "AggregateError of:" + "\n"; + level++; + indent = Array(level * 4 + 1).join(" "); + for (var i = 0; i < this.length; ++i) { + var str = this[i] === this ? "[Circular AggregateError]" : this[i] + ""; + var lines = str.split("\n"); + for (var j = 0; j < lines.length; ++j) { + lines[j] = indent + lines[j]; + } + str = lines.join("\n"); + ret += str + "\n"; + } + level--; + return ret; +}; + +function OperationalError(message) { + if (!(this instanceof OperationalError)) + return new OperationalError(message); + notEnumerableProp(this, "name", "OperationalError"); + notEnumerableProp(this, "message", message); + this.cause = message; + this["isOperational"] = true; + + if (message instanceof Error) { + notEnumerableProp(this, "message", message.message); + notEnumerableProp(this, "stack", message.stack); + } else if (Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } + +} +inherits(OperationalError, Error); + +var errorTypes = Error["__BluebirdErrorTypes__"]; +if (!errorTypes) { + errorTypes = Objectfreeze({ + CancellationError: CancellationError, + TimeoutError: TimeoutError, + OperationalError: OperationalError, + RejectionError: OperationalError, + AggregateError: AggregateError + }); + es5.defineProperty(Error, "__BluebirdErrorTypes__", { + value: errorTypes, + writable: false, + enumerable: false, + configurable: false + }); +} + +module.exports = { + Error: Error, + TypeError: _TypeError, + RangeError: _RangeError, + CancellationError: errorTypes.CancellationError, + OperationalError: errorTypes.OperationalError, + TimeoutError: errorTypes.TimeoutError, + AggregateError: errorTypes.AggregateError, + Warning: Warning +}; + +},{"./es5":13,"./util":36}],13:[function(_dereq_,module,exports){ +var isES5 = (function(){ + "use strict"; + return this === undefined; +})(); + +if (isES5) { + module.exports = { + freeze: Object.freeze, + defineProperty: Object.defineProperty, + getDescriptor: Object.getOwnPropertyDescriptor, + keys: Object.keys, + names: Object.getOwnPropertyNames, + getPrototypeOf: Object.getPrototypeOf, + isArray: Array.isArray, + isES5: isES5, + propertyIsWritable: function(obj, prop) { + var descriptor = Object.getOwnPropertyDescriptor(obj, prop); + return !!(!descriptor || descriptor.writable || descriptor.set); + } }; - } else if (window.getSelection) { - var selection = window.getSelection(); - return { - anchorNode: selection.anchorNode, - anchorOffset: selection.anchorOffset, - focusNode: selection.focusNode, - focusOffset: selection.focusOffset +} else { + var has = {}.hasOwnProperty; + var str = {}.toString; + var proto = {}.constructor.prototype; + + var ObjectKeys = function (o) { + var ret = []; + for (var key in o) { + if (has.call(o, key)) { + ret.push(key); + } + } + return ret; }; - } else if (document.selection) { - var range = document.selection.createRange(); - return { - parentElement: range.parentElement(), - text: range.text, - top: range.boundingTop, - left: range.boundingLeft + + var ObjectGetDescriptor = function(o, key) { + return {value: o[key]}; + }; + + var ObjectDefineProperty = function (o, key, desc) { + o[key] = desc.value; + return o; + }; + + var ObjectFreeze = function (obj) { + return obj; + }; + + var ObjectGetPrototypeOf = function (obj) { + try { + return Object(obj).constructor.prototype; + } + catch (e) { + return proto; + } + }; + + var ArrayIsArray = function (obj) { + try { + return str.call(obj) === "[object Array]"; + } + catch(e) { + return false; + } + }; + + module.exports = { + isArray: ArrayIsArray, + keys: ObjectKeys, + names: ObjectKeys, + defineProperty: ObjectDefineProperty, + getDescriptor: ObjectGetDescriptor, + freeze: ObjectFreeze, + getPrototypeOf: ObjectGetPrototypeOf, + isES5: isES5, + propertyIsWritable: function() { + return true; + } }; - } } -/** - * Poll selection to see whether it's changed. - * - * @param {object} nativeEvent - * @return {?SyntheticEvent} - */ -function constructSelectEvent(nativeEvent, nativeEventTarget) { - // Ensure we have the right element, and that the user is not dragging a - // selection (this matches native `select` event behavior). In HTML5, select - // fires only on input and textarea thus if there's no focused element we - // won't dispatch. - if (mouseDown || activeElement == null || activeElement !== getActiveElement()) { - return null; - } +},{}],14:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL) { +var PromiseMap = Promise.map; - // Only fire when selection has actually changed. - var currentSelection = getSelection(activeElement); - if (!lastSelection || !shallowEqual(lastSelection, currentSelection)) { - lastSelection = currentSelection; +Promise.prototype.filter = function (fn, options) { + return PromiseMap(this, fn, options, INTERNAL); +}; - var syntheticEvent = SyntheticEvent.getPooled(eventTypes.select, activeElementInst, nativeEvent, nativeEventTarget); +Promise.filter = function (promises, fn, options) { + return PromiseMap(promises, fn, options, INTERNAL); +}; +}; - syntheticEvent.type = 'select'; - syntheticEvent.target = activeElement; +},{}],15:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, tryConvertToPromise, NEXT_FILTER) { +var util = _dereq_("./util"); +var CancellationError = Promise.CancellationError; +var errorObj = util.errorObj; +var catchFilter = _dereq_("./catch_filter")(NEXT_FILTER); + +function PassThroughHandlerContext(promise, type, handler) { + this.promise = promise; + this.type = type; + this.handler = handler; + this.called = false; + this.cancelPromise = null; +} - EventPropagators.accumulateTwoPhaseDispatches(syntheticEvent); +PassThroughHandlerContext.prototype.isFinallyHandler = function() { + return this.type === 0; +}; - return syntheticEvent; - } +function FinallyHandlerCancelReaction(finallyHandler) { + this.finallyHandler = finallyHandler; +} - return null; +FinallyHandlerCancelReaction.prototype._resultCancelled = function() { + checkCancel(this.finallyHandler); +}; + +function checkCancel(ctx, reason) { + if (ctx.cancelPromise != null) { + if (arguments.length > 1) { + ctx.cancelPromise._reject(reason); + } else { + ctx.cancelPromise._cancel(); + } + ctx.cancelPromise = null; + return true; + } + return false; } -/** - * This plugin creates an `onSelect` event that normalizes select events - * across form elements. - * - * Supported elements are: - * - input (see `isTextInputElement`) - * - textarea - * - contentEditable - * - * This differs from native browser implementations in the following ways: - * - Fires on contentEditable fields as well as inputs. - * - Fires for collapsed selection. - * - Fires after user input. - */ -var SelectEventPlugin = { - eventTypes: eventTypes, +function succeed() { + return finallyHandler.call(this, this.promise._target()._settledValue()); +} +function fail(reason) { + if (checkCancel(this, reason)) return; + errorObj.e = reason; + return errorObj; +} +function finallyHandler(reasonOrValue) { + var promise = this.promise; + var handler = this.handler; + + if (!this.called) { + this.called = true; + var ret = this.isFinallyHandler() + ? handler.call(promise._boundValue()) + : handler.call(promise._boundValue(), reasonOrValue); + if (ret === NEXT_FILTER) { + return ret; + } else if (ret !== undefined) { + promise._setReturnedNonUndefined(); + var maybePromise = tryConvertToPromise(ret, promise); + if (maybePromise instanceof Promise) { + if (this.cancelPromise != null) { + if (maybePromise._isCancelled()) { + var reason = + new CancellationError("late cancellation observer"); + promise._attachExtraTrace(reason); + errorObj.e = reason; + return errorObj; + } else if (maybePromise.isPending()) { + maybePromise._attachCancellationCallback( + new FinallyHandlerCancelReaction(this)); + } + } + return maybePromise._then( + succeed, fail, undefined, this, undefined); + } + } + } - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - if (!hasListener) { - return null; + if (promise.isRejected()) { + checkCancel(this); + errorObj.e = reasonOrValue; + return errorObj; + } else { + checkCancel(this); + return reasonOrValue; } +} - var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; +Promise.prototype._passThrough = function(handler, type, success, fail) { + if (typeof handler !== "function") return this.then(); + return this._then(success, + fail, + undefined, + new PassThroughHandlerContext(this, type, handler), + undefined); +}; - switch (topLevelType) { - // Track the input node that has focus. - case 'topFocus': - if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') { - activeElement = targetNode; - activeElementInst = targetInst; - lastSelection = null; +Promise.prototype.lastly = +Promise.prototype["finally"] = function (handler) { + return this._passThrough(handler, + 0, + finallyHandler, + finallyHandler); +}; + + +Promise.prototype.tap = function (handler) { + return this._passThrough(handler, 1, finallyHandler); +}; + +Promise.prototype.tapCatch = function (handlerOrPredicate) { + var len = arguments.length; + if(len === 1) { + return this._passThrough(handlerOrPredicate, + 1, + undefined, + finallyHandler); + } else { + var catchInstances = new Array(len - 1), + j = 0, i; + for (i = 0; i < len - 1; ++i) { + var item = arguments[i]; + if (util.isObject(item)) { + catchInstances[j++] = item; + } else { + return Promise.reject(new TypeError( + "tapCatch statement predicate: " + + "expecting an object but got " + util.classString(item) + )); + } } - break; - case 'topBlur': - activeElement = null; - activeElementInst = null; - lastSelection = null; - break; - // Don't fire the event while the user is dragging. This matches the - // semantics of the native select event. - case 'topMouseDown': - mouseDown = true; - break; - case 'topContextMenu': - case 'topMouseUp': - mouseDown = false; - return constructSelectEvent(nativeEvent, nativeEventTarget); - // Chrome and IE fire non-standard event when selection is changed (and - // sometimes when it hasn't). IE's event fires out of order with respect - // to key and input events on deletion, so we discard it. - // - // Firefox doesn't support selectionchange, so check selection status - // after each key entry. The selection changes after keydown and before - // keyup, but we check on keydown as well in the case of holding down a - // key, when multiple keydown events are fired but only one keyup is. - // This is also our approach for IE handling, for the reason above. - case 'topSelectionChange': - if (skipSelectionChangeEvent) { - break; + catchInstances.length = j; + var handler = arguments[i]; + return this._passThrough(catchFilter(catchInstances, handler, this), + 1, + undefined, + finallyHandler); + } + +}; + +return PassThroughHandlerContext; +}; + +},{"./catch_filter":7,"./util":36}],16:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, + apiRejection, + INTERNAL, + tryConvertToPromise, + Proxyable, + debug) { +var errors = _dereq_("./errors"); +var TypeError = errors.TypeError; +var util = _dereq_("./util"); +var errorObj = util.errorObj; +var tryCatch = util.tryCatch; +var yieldHandlers = []; + +function promiseFromYieldHandler(value, yieldHandlers, traceParent) { + for (var i = 0; i < yieldHandlers.length; ++i) { + traceParent._pushContext(); + var result = tryCatch(yieldHandlers[i])(value); + traceParent._popContext(); + if (result === errorObj) { + traceParent._pushContext(); + var ret = Promise.reject(errorObj.e); + traceParent._popContext(); + return ret; + } + var maybePromise = tryConvertToPromise(result, traceParent); + if (maybePromise instanceof Promise) return maybePromise; + } + return null; +} + +function PromiseSpawn(generatorFunction, receiver, yieldHandler, stack) { + if (debug.cancellation()) { + var internal = new Promise(INTERNAL); + var _finallyPromise = this._finallyPromise = new Promise(INTERNAL); + this._promise = internal.lastly(function() { + return _finallyPromise; + }); + internal._captureStackTrace(); + internal._setOnCancel(this); + } else { + var promise = this._promise = new Promise(INTERNAL); + promise._captureStackTrace(); + } + this._stack = stack; + this._generatorFunction = generatorFunction; + this._receiver = receiver; + this._generator = undefined; + this._yieldHandlers = typeof yieldHandler === "function" + ? [yieldHandler].concat(yieldHandlers) + : yieldHandlers; + this._yieldedPromise = null; + this._cancellationPhase = false; +} +util.inherits(PromiseSpawn, Proxyable); + +PromiseSpawn.prototype._isResolved = function() { + return this._promise === null; +}; + +PromiseSpawn.prototype._cleanup = function() { + this._promise = this._generator = null; + if (debug.cancellation() && this._finallyPromise !== null) { + this._finallyPromise._fulfill(); + this._finallyPromise = null; + } +}; + +PromiseSpawn.prototype._promiseCancelled = function() { + if (this._isResolved()) return; + var implementsReturn = typeof this._generator["return"] !== "undefined"; + + var result; + if (!implementsReturn) { + var reason = new Promise.CancellationError( + "generator .return() sentinel"); + Promise.coroutine.returnSentinel = reason; + this._promise._attachExtraTrace(reason); + this._promise._pushContext(); + result = tryCatch(this._generator["throw"]).call(this._generator, + reason); + this._promise._popContext(); + } else { + this._promise._pushContext(); + result = tryCatch(this._generator["return"]).call(this._generator, + undefined); + this._promise._popContext(); + } + this._cancellationPhase = true; + this._yieldedPromise = null; + this._continue(result); +}; + +PromiseSpawn.prototype._promiseFulfilled = function(value) { + this._yieldedPromise = null; + this._promise._pushContext(); + var result = tryCatch(this._generator.next).call(this._generator, value); + this._promise._popContext(); + this._continue(result); +}; + +PromiseSpawn.prototype._promiseRejected = function(reason) { + this._yieldedPromise = null; + this._promise._attachExtraTrace(reason); + this._promise._pushContext(); + var result = tryCatch(this._generator["throw"]) + .call(this._generator, reason); + this._promise._popContext(); + this._continue(result); +}; + +PromiseSpawn.prototype._resultCancelled = function() { + if (this._yieldedPromise instanceof Promise) { + var promise = this._yieldedPromise; + this._yieldedPromise = null; + promise.cancel(); + } +}; + +PromiseSpawn.prototype.promise = function () { + return this._promise; +}; + +PromiseSpawn.prototype._run = function () { + this._generator = this._generatorFunction.call(this._receiver); + this._receiver = + this._generatorFunction = undefined; + this._promiseFulfilled(undefined); +}; + +PromiseSpawn.prototype._continue = function (result) { + var promise = this._promise; + if (result === errorObj) { + this._cleanup(); + if (this._cancellationPhase) { + return promise.cancel(); + } else { + return promise._rejectCallback(result.e, false); + } + } + + var value = result.value; + if (result.done === true) { + this._cleanup(); + if (this._cancellationPhase) { + return promise.cancel(); + } else { + return promise._resolveCallback(value); + } + } else { + var maybePromise = tryConvertToPromise(value, this._promise); + if (!(maybePromise instanceof Promise)) { + maybePromise = + promiseFromYieldHandler(maybePromise, + this._yieldHandlers, + this._promise); + if (maybePromise === null) { + this._promiseRejected( + new TypeError( + "A value %s was yielded that could not be treated as a promise\u000a\u000a See http://goo.gl/MqrFmX\u000a\u000a".replace("%s", String(value)) + + "From coroutine:\u000a" + + this._stack.split("\n").slice(1, -7).join("\n") + ) + ); + return; + } + } + maybePromise = maybePromise._target(); + var bitField = maybePromise._bitField; + ; + if (((bitField & 50397184) === 0)) { + this._yieldedPromise = maybePromise; + maybePromise._proxy(this, null); + } else if (((bitField & 33554432) !== 0)) { + Promise._async.invoke( + this._promiseFulfilled, this, maybePromise._value() + ); + } else if (((bitField & 16777216) !== 0)) { + Promise._async.invoke( + this._promiseRejected, this, maybePromise._reason() + ); + } else { + this._promiseCancelled(); + } + } +}; + +Promise.coroutine = function (generatorFunction, options) { + if (typeof generatorFunction !== "function") { + throw new TypeError("generatorFunction must be a function\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + var yieldHandler = Object(options).yieldHandler; + var PromiseSpawn$ = PromiseSpawn; + var stack = new Error().stack; + return function () { + var generator = generatorFunction.apply(this, arguments); + var spawn = new PromiseSpawn$(undefined, undefined, yieldHandler, + stack); + var ret = spawn.promise(); + spawn._generator = generator; + spawn._promiseFulfilled(undefined); + return ret; + }; +}; + +Promise.coroutine.addYieldHandler = function(fn) { + if (typeof fn !== "function") { + throw new TypeError("expecting a function but got " + util.classString(fn)); + } + yieldHandlers.push(fn); +}; + +Promise.spawn = function (generatorFunction) { + debug.deprecated("Promise.spawn()", "Promise.coroutine()"); + if (typeof generatorFunction !== "function") { + return apiRejection("generatorFunction must be a function\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + var spawn = new PromiseSpawn(generatorFunction, this); + var ret = spawn.promise(); + spawn._run(Promise.spawn); + return ret; +}; +}; + +},{"./errors":12,"./util":36}],17:[function(_dereq_,module,exports){ +"use strict"; +module.exports = +function(Promise, PromiseArray, tryConvertToPromise, INTERNAL, async, + getDomain) { +var util = _dereq_("./util"); +var canEvaluate = util.canEvaluate; +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; +var reject; + +if (false) { +if (canEvaluate) { + var thenCallback = function(i) { + return new Function("value", "holder", " \n\ + 'use strict'; \n\ + holder.pIndex = value; \n\ + holder.checkFulfillment(this); \n\ + ".replace(/Index/g, i)); + }; + + var promiseSetter = function(i) { + return new Function("promise", "holder", " \n\ + 'use strict'; \n\ + holder.pIndex = promise; \n\ + ".replace(/Index/g, i)); + }; + + var generateHolderClass = function(total) { + var props = new Array(total); + for (var i = 0; i < props.length; ++i) { + props[i] = "this.p" + (i+1); + } + var assignment = props.join(" = ") + " = null;"; + var cancellationCode= "var promise;\n" + props.map(function(prop) { + return " \n\ + promise = " + prop + "; \n\ + if (promise instanceof Promise) { \n\ + promise.cancel(); \n\ + } \n\ + "; + }).join("\n"); + var passedArguments = props.join(", "); + var name = "Holder$" + total; + + + var code = "return function(tryCatch, errorObj, Promise, async) { \n\ + 'use strict'; \n\ + function [TheName](fn) { \n\ + [TheProperties] \n\ + this.fn = fn; \n\ + this.asyncNeeded = true; \n\ + this.now = 0; \n\ + } \n\ + \n\ + [TheName].prototype._callFunction = function(promise) { \n\ + promise._pushContext(); \n\ + var ret = tryCatch(this.fn)([ThePassedArguments]); \n\ + promise._popContext(); \n\ + if (ret === errorObj) { \n\ + promise._rejectCallback(ret.e, false); \n\ + } else { \n\ + promise._resolveCallback(ret); \n\ + } \n\ + }; \n\ + \n\ + [TheName].prototype.checkFulfillment = function(promise) { \n\ + var now = ++this.now; \n\ + if (now === [TheTotal]) { \n\ + if (this.asyncNeeded) { \n\ + async.invoke(this._callFunction, this, promise); \n\ + } else { \n\ + this._callFunction(promise); \n\ + } \n\ + \n\ + } \n\ + }; \n\ + \n\ + [TheName].prototype._resultCancelled = function() { \n\ + [CancellationCode] \n\ + }; \n\ + \n\ + return [TheName]; \n\ + }(tryCatch, errorObj, Promise, async); \n\ + "; + + code = code.replace(/\[TheName\]/g, name) + .replace(/\[TheTotal\]/g, total) + .replace(/\[ThePassedArguments\]/g, passedArguments) + .replace(/\[TheProperties\]/g, assignment) + .replace(/\[CancellationCode\]/g, cancellationCode); + + return new Function("tryCatch", "errorObj", "Promise", "async", code) + (tryCatch, errorObj, Promise, async); + }; + + var holderClasses = []; + var thenCallbacks = []; + var promiseSetters = []; + + for (var i = 0; i < 8; ++i) { + holderClasses.push(generateHolderClass(i + 1)); + thenCallbacks.push(thenCallback(i + 1)); + promiseSetters.push(promiseSetter(i + 1)); + } + + reject = function (reason) { + this._reject(reason); + }; +}} + +Promise.join = function () { + var last = arguments.length - 1; + var fn; + if (last > 0 && typeof arguments[last] === "function") { + fn = arguments[last]; + if (false) { + if (last <= 8 && canEvaluate) { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + var HolderClass = holderClasses[last - 1]; + var holder = new HolderClass(fn); + var callbacks = thenCallbacks; + + for (var i = 0; i < last; ++i) { + var maybePromise = tryConvertToPromise(arguments[i], ret); + if (maybePromise instanceof Promise) { + maybePromise = maybePromise._target(); + var bitField = maybePromise._bitField; + ; + if (((bitField & 50397184) === 0)) { + maybePromise._then(callbacks[i], reject, + undefined, ret, holder); + promiseSetters[i](maybePromise, holder); + holder.asyncNeeded = false; + } else if (((bitField & 33554432) !== 0)) { + callbacks[i].call(ret, + maybePromise._value(), holder); + } else if (((bitField & 16777216) !== 0)) { + ret._reject(maybePromise._reason()); + } else { + ret._cancel(); + } + } else { + callbacks[i].call(ret, maybePromise, holder); + } + } + + if (!ret._isFateSealed()) { + if (holder.asyncNeeded) { + var domain = getDomain(); + if (domain !== null) { + holder.fn = util.domainBind(domain, holder.fn); + } + } + ret._setAsyncGuaranteed(); + ret._setOnCancel(holder); + } + return ret; + } + } + } + var args = [].slice.call(arguments);; + if (fn) args.pop(); + var ret = new PromiseArray(args).promise(); + return fn !== undefined ? ret.spread(fn) : ret; +}; + +}; + +},{"./util":36}],18:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, + PromiseArray, + apiRejection, + tryConvertToPromise, + INTERNAL, + debug) { +var getDomain = Promise._getDomain; +var util = _dereq_("./util"); +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; +var async = Promise._async; + +function MappingPromiseArray(promises, fn, limit, _filter) { + this.constructor$(promises); + this._promise._captureStackTrace(); + var domain = getDomain(); + this._callback = domain === null ? fn : util.domainBind(domain, fn); + this._preservedValues = _filter === INTERNAL + ? new Array(this.length()) + : null; + this._limit = limit; + this._inFlight = 0; + this._queue = []; + async.invoke(this._asyncInit, this, undefined); +} +util.inherits(MappingPromiseArray, PromiseArray); + +MappingPromiseArray.prototype._asyncInit = function() { + this._init$(undefined, -2); +}; + +MappingPromiseArray.prototype._init = function () {}; + +MappingPromiseArray.prototype._promiseFulfilled = function (value, index) { + var values = this._values; + var length = this.length(); + var preservedValues = this._preservedValues; + var limit = this._limit; + + if (index < 0) { + index = (index * -1) - 1; + values[index] = value; + if (limit >= 1) { + this._inFlight--; + this._drainQueue(); + if (this._isResolved()) return true; + } + } else { + if (limit >= 1 && this._inFlight >= limit) { + values[index] = value; + this._queue.push(index); + return false; + } + if (preservedValues !== null) preservedValues[index] = value; + + var promise = this._promise; + var callback = this._callback; + var receiver = promise._boundValue(); + promise._pushContext(); + var ret = tryCatch(callback).call(receiver, value, index, length); + var promiseCreated = promise._popContext(); + debug.checkForgottenReturns( + ret, + promiseCreated, + preservedValues !== null ? "Promise.filter" : "Promise.map", + promise + ); + if (ret === errorObj) { + this._reject(ret.e); + return true; + } + + var maybePromise = tryConvertToPromise(ret, this._promise); + if (maybePromise instanceof Promise) { + maybePromise = maybePromise._target(); + var bitField = maybePromise._bitField; + ; + if (((bitField & 50397184) === 0)) { + if (limit >= 1) this._inFlight++; + values[index] = maybePromise; + maybePromise._proxy(this, (index + 1) * -1); + return false; + } else if (((bitField & 33554432) !== 0)) { + ret = maybePromise._value(); + } else if (((bitField & 16777216) !== 0)) { + this._reject(maybePromise._reason()); + return true; + } else { + this._cancel(); + return true; + } + } + values[index] = ret; + } + var totalResolved = ++this._totalResolved; + if (totalResolved >= length) { + if (preservedValues !== null) { + this._filter(values, preservedValues); + } else { + this._resolve(values); + } + return true; + } + return false; +}; + +MappingPromiseArray.prototype._drainQueue = function () { + var queue = this._queue; + var limit = this._limit; + var values = this._values; + while (queue.length > 0 && this._inFlight < limit) { + if (this._isResolved()) return; + var index = queue.pop(); + this._promiseFulfilled(values[index], index); + } +}; + +MappingPromiseArray.prototype._filter = function (booleans, values) { + var len = values.length; + var ret = new Array(len); + var j = 0; + for (var i = 0; i < len; ++i) { + if (booleans[i]) ret[j++] = values[i]; + } + ret.length = j; + this._resolve(ret); +}; + +MappingPromiseArray.prototype.preservedValues = function () { + return this._preservedValues; +}; + +function map(promises, fn, options, _filter) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + + var limit = 0; + if (options !== undefined) { + if (typeof options === "object" && options !== null) { + if (typeof options.concurrency !== "number") { + return Promise.reject( + new TypeError("'concurrency' must be a number but it is " + + util.classString(options.concurrency))); + } + limit = options.concurrency; + } else { + return Promise.reject(new TypeError( + "options argument must be an object but it is " + + util.classString(options))); } - // falls through - case 'topKeyDown': - case 'topKeyUp': - return constructSelectEvent(nativeEvent, nativeEventTarget); } + limit = typeof limit === "number" && + isFinite(limit) && limit >= 1 ? limit : 0; + return new MappingPromiseArray(promises, fn, limit, _filter).promise(); +} - return null; - }, +Promise.prototype.map = function (fn, options) { + return map(this, fn, options, null); +}; - didPutListener: function (inst, registrationName, listener) { - if (registrationName === 'onSelect') { - hasListener = true; - } - } +Promise.map = function (promises, fn, options, _filter) { + return map(promises, fn, options, _filter); }; -module.exports = SelectEventPlugin; -/***/ }), -/* 200 */ -/***/ (function(module, exports, __webpack_require__) { +}; +},{"./util":36}],19:[function(_dereq_,module,exports){ "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +module.exports = +function(Promise, INTERNAL, tryConvertToPromise, apiRejection, debug) { +var util = _dereq_("./util"); +var tryCatch = util.tryCatch; + +Promise.method = function (fn) { + if (typeof fn !== "function") { + throw new Promise.TypeError("expecting a function but got " + util.classString(fn)); + } + return function () { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._pushContext(); + var value = tryCatch(fn).apply(this, arguments); + var promiseCreated = ret._popContext(); + debug.checkForgottenReturns( + value, promiseCreated, "Promise.method", ret); + ret._resolveFromSyncValue(value); + return ret; + }; +}; +Promise.attempt = Promise["try"] = function (fn) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._pushContext(); + var value; + if (arguments.length > 1) { + debug.deprecated("calling Promise.try with more than 1 argument"); + var arg = arguments[1]; + var ctx = arguments[2]; + value = util.isArray(arg) ? tryCatch(fn).apply(ctx, arg) + : tryCatch(fn).call(ctx, arg); + } else { + value = tryCatch(fn)(); + } + var promiseCreated = ret._popContext(); + debug.checkForgottenReturns( + value, promiseCreated, "Promise.try", ret); + ret._resolveFromSyncValue(value); + return ret; +}; +Promise.prototype._resolveFromSyncValue = function (value) { + if (value === util.errorObj) { + this._rejectCallback(value.e, false); + } else { + this._resolveCallback(value, true); + } +}; +}; -var _prodInvariant = __webpack_require__(3); +},{"./util":36}],20:[function(_dereq_,module,exports){ +"use strict"; +var util = _dereq_("./util"); +var maybeWrapAsError = util.maybeWrapAsError; +var errors = _dereq_("./errors"); +var OperationalError = errors.OperationalError; +var es5 = _dereq_("./es5"); + +function isUntypedError(obj) { + return obj instanceof Error && + es5.getPrototypeOf(obj) === Error.prototype; +} -var EventListener = __webpack_require__(101); -var EventPropagators = __webpack_require__(31); -var ReactDOMComponentTree = __webpack_require__(6); -var SyntheticAnimationEvent = __webpack_require__(201); -var SyntheticClipboardEvent = __webpack_require__(202); -var SyntheticEvent = __webpack_require__(16); -var SyntheticFocusEvent = __webpack_require__(203); -var SyntheticKeyboardEvent = __webpack_require__(204); -var SyntheticMouseEvent = __webpack_require__(42); -var SyntheticDragEvent = __webpack_require__(206); -var SyntheticTouchEvent = __webpack_require__(207); -var SyntheticTransitionEvent = __webpack_require__(208); -var SyntheticUIEvent = __webpack_require__(33); -var SyntheticWheelEvent = __webpack_require__(209); +var rErrorKey = /^(?:name|message|stack|cause)$/; +function wrapAsOperationalError(obj) { + var ret; + if (isUntypedError(obj)) { + ret = new OperationalError(obj); + ret.name = obj.name; + ret.message = obj.message; + ret.stack = obj.stack; + var keys = es5.keys(obj); + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + if (!rErrorKey.test(key)) { + ret[key] = obj[key]; + } + } + return ret; + } + util.markAsOriginatingFromRejection(obj); + return obj; +} -var emptyFunction = __webpack_require__(12); -var getEventCharCode = __webpack_require__(65); -var invariant = __webpack_require__(1); +function nodebackForPromise(promise, multiArgs) { + return function(err, value) { + if (promise === null) return; + if (err) { + var wrapped = wrapAsOperationalError(maybeWrapAsError(err)); + promise._attachExtraTrace(wrapped); + promise._reject(wrapped); + } else if (!multiArgs) { + promise._fulfill(value); + } else { + var args = [].slice.call(arguments, 1);; + promise._fulfill(args); + } + promise = null; + }; +} -/** - * Turns - * ['abort', ...] - * into - * eventTypes = { - * 'abort': { - * phasedRegistrationNames: { - * bubbled: 'onAbort', - * captured: 'onAbortCapture', - * }, - * dependencies: ['topAbort'], - * }, - * ... - * }; - * topLevelEventsToDispatchConfig = { - * 'topAbort': { sameConfig } - * }; - */ -var eventTypes = {}; -var topLevelEventsToDispatchConfig = {}; -['abort', 'animationEnd', 'animationIteration', 'animationStart', 'blur', 'canPlay', 'canPlayThrough', 'click', 'contextMenu', 'copy', 'cut', 'doubleClick', 'drag', 'dragEnd', 'dragEnter', 'dragExit', 'dragLeave', 'dragOver', 'dragStart', 'drop', 'durationChange', 'emptied', 'encrypted', 'ended', 'error', 'focus', 'input', 'invalid', 'keyDown', 'keyPress', 'keyUp', 'load', 'loadedData', 'loadedMetadata', 'loadStart', 'mouseDown', 'mouseMove', 'mouseOut', 'mouseOver', 'mouseUp', 'paste', 'pause', 'play', 'playing', 'progress', 'rateChange', 'reset', 'scroll', 'seeked', 'seeking', 'stalled', 'submit', 'suspend', 'timeUpdate', 'touchCancel', 'touchEnd', 'touchMove', 'touchStart', 'transitionEnd', 'volumeChange', 'waiting', 'wheel'].forEach(function (event) { - var capitalizedEvent = event[0].toUpperCase() + event.slice(1); - var onEvent = 'on' + capitalizedEvent; - var topEvent = 'top' + capitalizedEvent; +module.exports = nodebackForPromise; - var type = { - phasedRegistrationNames: { - bubbled: onEvent, - captured: onEvent + 'Capture' - }, - dependencies: [topEvent] - }; - eventTypes[event] = type; - topLevelEventsToDispatchConfig[topEvent] = type; -}); +},{"./errors":12,"./es5":13,"./util":36}],21:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +var util = _dereq_("./util"); +var async = Promise._async; +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; + +function spreadAdapter(val, nodeback) { + var promise = this; + if (!util.isArray(val)) return successAdapter.call(promise, val, nodeback); + var ret = + tryCatch(nodeback).apply(promise._boundValue(), [null].concat(val)); + if (ret === errorObj) { + async.throwLater(ret.e); + } +} -var onClickListeners = {}; +function successAdapter(val, nodeback) { + var promise = this; + var receiver = promise._boundValue(); + var ret = val === undefined + ? tryCatch(nodeback).call(receiver, null) + : tryCatch(nodeback).call(receiver, null, val); + if (ret === errorObj) { + async.throwLater(ret.e); + } +} +function errorAdapter(reason, nodeback) { + var promise = this; + if (!reason) { + var newReason = new Error(reason + ""); + newReason.cause = reason; + reason = newReason; + } + var ret = tryCatch(nodeback).call(promise._boundValue(), reason); + if (ret === errorObj) { + async.throwLater(ret.e); + } +} -function getDictionaryKey(inst) { - // Prevents V8 performance issue: - // https://github.com/facebook/react/pull/7232 - return '.' + inst._rootNodeID; +Promise.prototype.asCallback = Promise.prototype.nodeify = function (nodeback, + options) { + if (typeof nodeback == "function") { + var adapter = successAdapter; + if (options !== undefined && Object(options).spread) { + adapter = spreadAdapter; + } + this._then( + adapter, + errorAdapter, + undefined, + this, + nodeback + ); + } + return this; +}; +}; + +},{"./util":36}],22:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function() { +var makeSelfResolutionError = function () { + return new TypeError("circular promise resolution chain\u000a\u000a See http://goo.gl/MqrFmX\u000a"); +}; +var reflectHandler = function() { + return new Promise.PromiseInspection(this._target()); +}; +var apiRejection = function(msg) { + return Promise.reject(new TypeError(msg)); +}; +function Proxyable() {} +var UNDEFINED_BINDING = {}; +var util = _dereq_("./util"); + +var getDomain; +if (util.isNode) { + getDomain = function() { + var ret = process.domain; + if (ret === undefined) ret = null; + return ret; + }; +} else { + getDomain = function() { + return null; + }; } +util.notEnumerableProp(Promise, "_getDomain", getDomain); + +var es5 = _dereq_("./es5"); +var Async = _dereq_("./async"); +var async = new Async(); +es5.defineProperty(Promise, "_async", {value: async}); +var errors = _dereq_("./errors"); +var TypeError = Promise.TypeError = errors.TypeError; +Promise.RangeError = errors.RangeError; +var CancellationError = Promise.CancellationError = errors.CancellationError; +Promise.TimeoutError = errors.TimeoutError; +Promise.OperationalError = errors.OperationalError; +Promise.RejectionError = errors.OperationalError; +Promise.AggregateError = errors.AggregateError; +var INTERNAL = function(){}; +var APPLY = {}; +var NEXT_FILTER = {}; +var tryConvertToPromise = _dereq_("./thenables")(Promise, INTERNAL); +var PromiseArray = + _dereq_("./promise_array")(Promise, INTERNAL, + tryConvertToPromise, apiRejection, Proxyable); +var Context = _dereq_("./context")(Promise); + /*jshint unused:false*/ +var createContext = Context.create; +var debug = _dereq_("./debuggability")(Promise, Context); +var CapturedTrace = debug.CapturedTrace; +var PassThroughHandlerContext = + _dereq_("./finally")(Promise, tryConvertToPromise, NEXT_FILTER); +var catchFilter = _dereq_("./catch_filter")(NEXT_FILTER); +var nodebackForPromise = _dereq_("./nodeback"); +var errorObj = util.errorObj; +var tryCatch = util.tryCatch; +function check(self, executor) { + if (self == null || self.constructor !== Promise) { + throw new TypeError("the promise constructor cannot be invoked directly\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + if (typeof executor !== "function") { + throw new TypeError("expecting a function but got " + util.classString(executor)); + } -function isInteractive(tag) { - return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; } -var SimpleEventPlugin = { - eventTypes: eventTypes, +function Promise(executor) { + if (executor !== INTERNAL) { + check(this, executor); + } + this._bitField = 0; + this._fulfillmentHandler0 = undefined; + this._rejectionHandler0 = undefined; + this._promise0 = undefined; + this._receiver0 = undefined; + this._resolveFromExecutor(executor); + this._promiseCreated(); + this._fireEvent("promiseCreated", this); +} - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var dispatchConfig = topLevelEventsToDispatchConfig[topLevelType]; - if (!dispatchConfig) { - return null; - } - var EventConstructor; - switch (topLevelType) { - case 'topAbort': - case 'topCanPlay': - case 'topCanPlayThrough': - case 'topDurationChange': - case 'topEmptied': - case 'topEncrypted': - case 'topEnded': - case 'topError': - case 'topInput': - case 'topInvalid': - case 'topLoad': - case 'topLoadedData': - case 'topLoadedMetadata': - case 'topLoadStart': - case 'topPause': - case 'topPlay': - case 'topPlaying': - case 'topProgress': - case 'topRateChange': - case 'topReset': - case 'topSeeked': - case 'topSeeking': - case 'topStalled': - case 'topSubmit': - case 'topSuspend': - case 'topTimeUpdate': - case 'topVolumeChange': - case 'topWaiting': - // HTML Events - // @see http://www.w3.org/TR/html5/index.html#events-0 - EventConstructor = SyntheticEvent; - break; - case 'topKeyPress': - // Firefox creates a keypress event for function keys too. This removes - // the unwanted keypress events. Enter is however both printable and - // non-printable. One would expect Tab to be as well (but it isn't). - if (getEventCharCode(nativeEvent) === 0) { - return null; - } - /* falls through */ - case 'topKeyDown': - case 'topKeyUp': - EventConstructor = SyntheticKeyboardEvent; - break; - case 'topBlur': - case 'topFocus': - EventConstructor = SyntheticFocusEvent; - break; - case 'topClick': - // Firefox creates a click event on right mouse clicks. This removes the - // unwanted click events. - if (nativeEvent.button === 2) { - return null; +Promise.prototype.toString = function () { + return "[object Promise]"; +}; + +Promise.prototype.caught = Promise.prototype["catch"] = function (fn) { + var len = arguments.length; + if (len > 1) { + var catchInstances = new Array(len - 1), + j = 0, i; + for (i = 0; i < len - 1; ++i) { + var item = arguments[i]; + if (util.isObject(item)) { + catchInstances[j++] = item; + } else { + return apiRejection("Catch statement predicate: " + + "expecting an object but got " + util.classString(item)); + } } - /* falls through */ - case 'topDoubleClick': - case 'topMouseDown': - case 'topMouseMove': - case 'topMouseUp': - // TODO: Disabled elements should not respond to mouse events - /* falls through */ - case 'topMouseOut': - case 'topMouseOver': - case 'topContextMenu': - EventConstructor = SyntheticMouseEvent; - break; - case 'topDrag': - case 'topDragEnd': - case 'topDragEnter': - case 'topDragExit': - case 'topDragLeave': - case 'topDragOver': - case 'topDragStart': - case 'topDrop': - EventConstructor = SyntheticDragEvent; - break; - case 'topTouchCancel': - case 'topTouchEnd': - case 'topTouchMove': - case 'topTouchStart': - EventConstructor = SyntheticTouchEvent; - break; - case 'topAnimationEnd': - case 'topAnimationIteration': - case 'topAnimationStart': - EventConstructor = SyntheticAnimationEvent; - break; - case 'topTransitionEnd': - EventConstructor = SyntheticTransitionEvent; - break; - case 'topScroll': - EventConstructor = SyntheticUIEvent; - break; - case 'topWheel': - EventConstructor = SyntheticWheelEvent; - break; - case 'topCopy': - case 'topCut': - case 'topPaste': - EventConstructor = SyntheticClipboardEvent; - break; + catchInstances.length = j; + fn = arguments[i]; + return this.then(undefined, catchFilter(catchInstances, fn, this)); } - !EventConstructor ? process.env.NODE_ENV !== 'production' ? invariant(false, 'SimpleEventPlugin: Unhandled event type, `%s`.', topLevelType) : _prodInvariant('86', topLevelType) : void 0; - var event = EventConstructor.getPooled(dispatchConfig, targetInst, nativeEvent, nativeEventTarget); - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; - }, + return this.then(undefined, fn); +}; - didPutListener: function (inst, registrationName, listener) { - // Mobile Safari does not fire properly bubble click events on - // non-interactive elements, which means delegated click listeners do not - // fire. The workaround for this bug involves attaching an empty click - // listener on the target node. - // http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html - if (registrationName === 'onClick' && !isInteractive(inst._tag)) { - var key = getDictionaryKey(inst); - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - if (!onClickListeners[key]) { - onClickListeners[key] = EventListener.listen(node, 'click', emptyFunction); - } - } - }, +Promise.prototype.reflect = function () { + return this._then(reflectHandler, + reflectHandler, undefined, this, undefined); +}; - willDeleteListener: function (inst, registrationName) { - if (registrationName === 'onClick' && !isInteractive(inst._tag)) { - var key = getDictionaryKey(inst); - onClickListeners[key].remove(); - delete onClickListeners[key]; +Promise.prototype.then = function (didFulfill, didReject) { + if (debug.warnings() && arguments.length > 0 && + typeof didFulfill !== "function" && + typeof didReject !== "function") { + var msg = ".then() only accepts functions but was passed: " + + util.classString(didFulfill); + if (arguments.length > 1) { + msg += ", " + util.classString(didReject); + } + this._warn(msg); } - } + return this._then(didFulfill, didReject, undefined, undefined, undefined); }; -module.exports = SimpleEventPlugin; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Promise.prototype.done = function (didFulfill, didReject) { + var promise = + this._then(didFulfill, didReject, undefined, undefined, undefined); + promise._setIsFinal(); +}; -/***/ }), -/* 201 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype.spread = function (fn) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + return this.all()._then(fn, undefined, undefined, APPLY, undefined); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype.toJSON = function () { + var ret = { + isFulfilled: false, + isRejected: false, + fulfillmentValue: undefined, + rejectionReason: undefined + }; + if (this.isFulfilled()) { + ret.fulfillmentValue = this.value(); + ret.isFulfilled = true; + } else if (this.isRejected()) { + ret.rejectionReason = this.reason(); + ret.isRejected = true; + } + return ret; +}; +Promise.prototype.all = function () { + if (arguments.length > 0) { + this._warn(".all() was passed arguments but it does not take any"); + } + return new PromiseArray(this).promise(); +}; +Promise.prototype.error = function (fn) { + return this.caught(util.originatesFromRejection, fn); +}; -var SyntheticEvent = __webpack_require__(16); +Promise.getNewLibraryCopy = module.exports; -/** - * @interface Event - * @see http://www.w3.org/TR/css3-animations/#AnimationEvent-interface - * @see https://developer.mozilla.org/en-US/docs/Web/API/AnimationEvent - */ -var AnimationEventInterface = { - animationName: null, - elapsedTime: null, - pseudoElement: null +Promise.is = function (val) { + return val instanceof Promise; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticAnimationEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.fromNode = Promise.fromCallback = function(fn) { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + var multiArgs = arguments.length > 1 ? !!Object(arguments[1]).multiArgs + : false; + var result = tryCatch(fn)(nodebackForPromise(ret, multiArgs)); + if (result === errorObj) { + ret._rejectCallback(result.e, true); + } + if (!ret._isFateSealed()) ret._setAsyncGuaranteed(); + return ret; +}; -SyntheticEvent.augmentClass(SyntheticAnimationEvent, AnimationEventInterface); +Promise.all = function (promises) { + return new PromiseArray(promises).promise(); +}; -module.exports = SyntheticAnimationEvent; +Promise.cast = function (obj) { + var ret = tryConvertToPromise(obj); + if (!(ret instanceof Promise)) { + ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._setFulfilled(); + ret._rejectionHandler0 = obj; + } + return ret; +}; -/***/ }), -/* 202 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.resolve = Promise.fulfilled = Promise.cast; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.reject = Promise.rejected = function (reason) { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._rejectCallback(reason, true); + return ret; +}; +Promise.setScheduler = function(fn) { + if (typeof fn !== "function") { + throw new TypeError("expecting a function but got " + util.classString(fn)); + } + return async.setScheduler(fn); +}; +Promise.prototype._then = function ( + didFulfill, + didReject, + _, receiver, + internalData +) { + var haveInternalData = internalData !== undefined; + var promise = haveInternalData ? internalData : new Promise(INTERNAL); + var target = this._target(); + var bitField = target._bitField; + + if (!haveInternalData) { + promise._propagateFrom(this, 3); + promise._captureStackTrace(); + if (receiver === undefined && + ((this._bitField & 2097152) !== 0)) { + if (!((bitField & 50397184) === 0)) { + receiver = this._boundValue(); + } else { + receiver = target === this ? undefined : this._boundTo; + } + } + this._fireEvent("promiseChained", this, promise); + } + + var domain = getDomain(); + if (!((bitField & 50397184) === 0)) { + var handler, value, settler = target._settlePromiseCtx; + if (((bitField & 33554432) !== 0)) { + value = target._rejectionHandler0; + handler = didFulfill; + } else if (((bitField & 16777216) !== 0)) { + value = target._fulfillmentHandler0; + handler = didReject; + target._unsetRejectionIsUnhandled(); + } else { + settler = target._settlePromiseLateCancellationObserver; + value = new CancellationError("late cancellation observer"); + target._attachExtraTrace(value); + handler = didReject; + } -var SyntheticEvent = __webpack_require__(16); + async.invoke(settler, target, { + handler: domain === null ? handler + : (typeof handler === "function" && + util.domainBind(domain, handler)), + promise: promise, + receiver: receiver, + value: value + }); + } else { + target._addCallbacks(didFulfill, didReject, promise, receiver, domain); + } -/** - * @interface Event - * @see http://www.w3.org/TR/clipboard-apis/ - */ -var ClipboardEventInterface = { - clipboardData: function (event) { - return 'clipboardData' in event ? event.clipboardData : window.clipboardData; - } + return promise; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticClipboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.prototype._length = function () { + return this._bitField & 65535; +}; -SyntheticEvent.augmentClass(SyntheticClipboardEvent, ClipboardEventInterface); +Promise.prototype._isFateSealed = function () { + return (this._bitField & 117506048) !== 0; +}; -module.exports = SyntheticClipboardEvent; +Promise.prototype._isFollowing = function () { + return (this._bitField & 67108864) === 67108864; +}; -/***/ }), -/* 203 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._setLength = function (len) { + this._bitField = (this._bitField & -65536) | + (len & 65535); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype._setFulfilled = function () { + this._bitField = this._bitField | 33554432; + this._fireEvent("promiseFulfilled", this); +}; +Promise.prototype._setRejected = function () { + this._bitField = this._bitField | 16777216; + this._fireEvent("promiseRejected", this); +}; +Promise.prototype._setFollowing = function () { + this._bitField = this._bitField | 67108864; + this._fireEvent("promiseResolved", this); +}; -var SyntheticUIEvent = __webpack_require__(33); +Promise.prototype._setIsFinal = function () { + this._bitField = this._bitField | 4194304; +}; -/** - * @interface FocusEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var FocusEventInterface = { - relatedTarget: null +Promise.prototype._isFinal = function () { + return (this._bitField & 4194304) > 0; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticFocusEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.prototype._unsetCancelled = function() { + this._bitField = this._bitField & (~65536); +}; -SyntheticUIEvent.augmentClass(SyntheticFocusEvent, FocusEventInterface); +Promise.prototype._setCancelled = function() { + this._bitField = this._bitField | 65536; + this._fireEvent("promiseCancelled", this); +}; -module.exports = SyntheticFocusEvent; +Promise.prototype._setWillBeCancelled = function() { + this._bitField = this._bitField | 8388608; +}; -/***/ }), -/* 204 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._setAsyncGuaranteed = function() { + if (async.hasCustomScheduler()) return; + this._bitField = this._bitField | 134217728; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype._receiverAt = function (index) { + var ret = index === 0 ? this._receiver0 : this[ + index * 4 - 4 + 3]; + if (ret === UNDEFINED_BINDING) { + return undefined; + } else if (ret === undefined && this._isBound()) { + return this._boundValue(); + } + return ret; +}; +Promise.prototype._promiseAt = function (index) { + return this[ + index * 4 - 4 + 2]; +}; +Promise.prototype._fulfillmentHandlerAt = function (index) { + return this[ + index * 4 - 4 + 0]; +}; -var SyntheticUIEvent = __webpack_require__(33); +Promise.prototype._rejectionHandlerAt = function (index) { + return this[ + index * 4 - 4 + 1]; +}; -var getEventCharCode = __webpack_require__(65); -var getEventKey = __webpack_require__(205); -var getEventModifierState = __webpack_require__(54); +Promise.prototype._boundValue = function() {}; -/** - * @interface KeyboardEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var KeyboardEventInterface = { - key: getEventKey, - location: null, - ctrlKey: null, - shiftKey: null, - altKey: null, - metaKey: null, - repeat: null, - locale: null, - getModifierState: getEventModifierState, - // Legacy Interface - charCode: function (event) { - // `charCode` is the result of a KeyPress event and represents the value of - // the actual printable character. +Promise.prototype._migrateCallback0 = function (follower) { + var bitField = follower._bitField; + var fulfill = follower._fulfillmentHandler0; + var reject = follower._rejectionHandler0; + var promise = follower._promise0; + var receiver = follower._receiverAt(0); + if (receiver === undefined) receiver = UNDEFINED_BINDING; + this._addCallbacks(fulfill, reject, promise, receiver, null); +}; - // KeyPress is deprecated, but its replacement is not yet final and not - // implemented in any major browser. Only KeyPress has charCode. - if (event.type === 'keypress') { - return getEventCharCode(event); - } - return 0; - }, - keyCode: function (event) { - // `keyCode` is the result of a KeyDown/Up event and represents the value of - // physical keyboard key. +Promise.prototype._migrateCallbackAt = function (follower, index) { + var fulfill = follower._fulfillmentHandlerAt(index); + var reject = follower._rejectionHandlerAt(index); + var promise = follower._promiseAt(index); + var receiver = follower._receiverAt(index); + if (receiver === undefined) receiver = UNDEFINED_BINDING; + this._addCallbacks(fulfill, reject, promise, receiver, null); +}; - // The actual meaning of the value depends on the users' keyboard layout - // which cannot be detected. Assuming that it is a US keyboard layout - // provides a surprisingly accurate mapping for US and European users. - // Due to this, it is left to the user to implement at this time. - if (event.type === 'keydown' || event.type === 'keyup') { - return event.keyCode; - } - return 0; - }, - which: function (event) { - // `which` is an alias for either `keyCode` or `charCode` depending on the - // type of the event. - if (event.type === 'keypress') { - return getEventCharCode(event); - } - if (event.type === 'keydown' || event.type === 'keyup') { - return event.keyCode; +Promise.prototype._addCallbacks = function ( + fulfill, + reject, + promise, + receiver, + domain +) { + var index = this._length(); + + if (index >= 65535 - 4) { + index = 0; + this._setLength(0); + } + + if (index === 0) { + this._promise0 = promise; + this._receiver0 = receiver; + if (typeof fulfill === "function") { + this._fulfillmentHandler0 = + domain === null ? fulfill : util.domainBind(domain, fulfill); + } + if (typeof reject === "function") { + this._rejectionHandler0 = + domain === null ? reject : util.domainBind(domain, reject); + } + } else { + var base = index * 4 - 4; + this[base + 2] = promise; + this[base + 3] = receiver; + if (typeof fulfill === "function") { + this[base + 0] = + domain === null ? fulfill : util.domainBind(domain, fulfill); + } + if (typeof reject === "function") { + this[base + 1] = + domain === null ? reject : util.domainBind(domain, reject); + } } - return 0; - } + this._setLength(index + 1); + return index; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticKeyboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} - -SyntheticUIEvent.augmentClass(SyntheticKeyboardEvent, KeyboardEventInterface); - -module.exports = SyntheticKeyboardEvent; - -/***/ }), -/* 205 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._proxy = function (proxyable, arg) { + this._addCallbacks(undefined, undefined, arg, proxyable, null); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype._resolveCallback = function(value, shouldBind) { + if (((this._bitField & 117506048) !== 0)) return; + if (value === this) + return this._rejectCallback(makeSelfResolutionError(), false); + var maybePromise = tryConvertToPromise(value, this); + if (!(maybePromise instanceof Promise)) return this._fulfill(value); + if (shouldBind) this._propagateFrom(maybePromise, 2); + var promise = maybePromise._target(); -var getEventCharCode = __webpack_require__(65); + if (promise === this) { + this._reject(makeSelfResolutionError()); + return; + } -/** - * Normalization of deprecated HTML5 `key` values - * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names - */ -var normalizeKey = { - Esc: 'Escape', - Spacebar: ' ', - Left: 'ArrowLeft', - Up: 'ArrowUp', - Right: 'ArrowRight', - Down: 'ArrowDown', - Del: 'Delete', - Win: 'OS', - Menu: 'ContextMenu', - Apps: 'ContextMenu', - Scroll: 'ScrollLock', - MozPrintableKey: 'Unidentified' + var bitField = promise._bitField; + if (((bitField & 50397184) === 0)) { + var len = this._length(); + if (len > 0) promise._migrateCallback0(this); + for (var i = 1; i < len; ++i) { + promise._migrateCallbackAt(this, i); + } + this._setFollowing(); + this._setLength(0); + this._setFollowee(promise); + } else if (((bitField & 33554432) !== 0)) { + this._fulfill(promise._value()); + } else if (((bitField & 16777216) !== 0)) { + this._reject(promise._reason()); + } else { + var reason = new CancellationError("late cancellation observer"); + promise._attachExtraTrace(reason); + this._reject(reason); + } }; -/** - * Translation from legacy `keyCode` to HTML5 `key` - * Only special keys supported, all others depend on keyboard layout or browser - * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names - */ -var translateToKey = { - 8: 'Backspace', - 9: 'Tab', - 12: 'Clear', - 13: 'Enter', - 16: 'Shift', - 17: 'Control', - 18: 'Alt', - 19: 'Pause', - 20: 'CapsLock', - 27: 'Escape', - 32: ' ', - 33: 'PageUp', - 34: 'PageDown', - 35: 'End', - 36: 'Home', - 37: 'ArrowLeft', - 38: 'ArrowUp', - 39: 'ArrowRight', - 40: 'ArrowDown', - 45: 'Insert', - 46: 'Delete', - 112: 'F1', - 113: 'F2', - 114: 'F3', - 115: 'F4', - 116: 'F5', - 117: 'F6', - 118: 'F7', - 119: 'F8', - 120: 'F9', - 121: 'F10', - 122: 'F11', - 123: 'F12', - 144: 'NumLock', - 145: 'ScrollLock', - 224: 'Meta' +Promise.prototype._rejectCallback = +function(reason, synchronous, ignoreNonErrorWarnings) { + var trace = util.ensureErrorObject(reason); + var hasStack = trace === reason; + if (!hasStack && !ignoreNonErrorWarnings && debug.warnings()) { + var message = "a promise was rejected with a non-error: " + + util.classString(reason); + this._warn(message, true); + } + this._attachExtraTrace(trace, synchronous ? hasStack : false); + this._reject(reason); }; -/** - * @param {object} nativeEvent Native browser event. - * @return {string} Normalized `key` property. - */ -function getEventKey(nativeEvent) { - if (nativeEvent.key) { - // Normalize inconsistent values reported by browsers due to - // implementations of a working draft specification. +Promise.prototype._resolveFromExecutor = function (executor) { + if (executor === INTERNAL) return; + var promise = this; + this._captureStackTrace(); + this._pushContext(); + var synchronous = true; + var r = this._execute(executor, function(value) { + promise._resolveCallback(value); + }, function (reason) { + promise._rejectCallback(reason, synchronous); + }); + synchronous = false; + this._popContext(); - // FireFox implements `key` but returns `MozPrintableKey` for all - // printable characters (normalized to `Unidentified`), ignore it. - var key = normalizeKey[nativeEvent.key] || nativeEvent.key; - if (key !== 'Unidentified') { - return key; + if (r !== undefined) { + promise._rejectCallback(r, true); } - } +}; - // Browser does not implement `key`, polyfill as much of it as we can. - if (nativeEvent.type === 'keypress') { - var charCode = getEventCharCode(nativeEvent); +Promise.prototype._settlePromiseFromHandler = function ( + handler, receiver, value, promise +) { + var bitField = promise._bitField; + if (((bitField & 65536) !== 0)) return; + promise._pushContext(); + var x; + if (receiver === APPLY) { + if (!value || typeof value.length !== "number") { + x = errorObj; + x.e = new TypeError("cannot .spread() a non-array: " + + util.classString(value)); + } else { + x = tryCatch(handler).apply(this._boundValue(), value); + } + } else { + x = tryCatch(handler).call(receiver, value); + } + var promiseCreated = promise._popContext(); + bitField = promise._bitField; + if (((bitField & 65536) !== 0)) return; - // The enter-key is technically both printable and non-printable and can - // thus be captured by `keypress`, no other non-printable key should. - return charCode === 13 ? 'Enter' : String.fromCharCode(charCode); - } - if (nativeEvent.type === 'keydown' || nativeEvent.type === 'keyup') { - // While user keyboard layout determines the actual meaning of each - // `keyCode` value, almost all function keys have a universal value. - return translateToKey[nativeEvent.keyCode] || 'Unidentified'; - } - return ''; -} + if (x === NEXT_FILTER) { + promise._reject(value); + } else if (x === errorObj) { + promise._rejectCallback(x.e, false); + } else { + debug.checkForgottenReturns(x, promiseCreated, "", promise, this); + promise._resolveCallback(x); + } +}; -module.exports = getEventKey; +Promise.prototype._target = function() { + var ret = this; + while (ret._isFollowing()) ret = ret._followee(); + return ret; +}; -/***/ }), -/* 206 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._followee = function() { + return this._rejectionHandler0; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype._setFollowee = function(promise) { + this._rejectionHandler0 = promise; +}; +Promise.prototype._settlePromise = function(promise, handler, receiver, value) { + var isPromise = promise instanceof Promise; + var bitField = this._bitField; + var asyncGuaranteed = ((bitField & 134217728) !== 0); + if (((bitField & 65536) !== 0)) { + if (isPromise) promise._invokeInternalOnCancel(); + + if (receiver instanceof PassThroughHandlerContext && + receiver.isFinallyHandler()) { + receiver.cancelPromise = promise; + if (tryCatch(handler).call(receiver, value) === errorObj) { + promise._reject(errorObj.e); + } + } else if (handler === reflectHandler) { + promise._fulfill(reflectHandler.call(receiver)); + } else if (receiver instanceof Proxyable) { + receiver._promiseCancelled(promise); + } else if (isPromise || promise instanceof PromiseArray) { + promise._cancel(); + } else { + receiver.cancel(); + } + } else if (typeof handler === "function") { + if (!isPromise) { + handler.call(receiver, value, promise); + } else { + if (asyncGuaranteed) promise._setAsyncGuaranteed(); + this._settlePromiseFromHandler(handler, receiver, value, promise); + } + } else if (receiver instanceof Proxyable) { + if (!receiver._isResolved()) { + if (((bitField & 33554432) !== 0)) { + receiver._promiseFulfilled(value, promise); + } else { + receiver._promiseRejected(value, promise); + } + } + } else if (isPromise) { + if (asyncGuaranteed) promise._setAsyncGuaranteed(); + if (((bitField & 33554432) !== 0)) { + promise._fulfill(value); + } else { + promise._reject(value); + } + } +}; +Promise.prototype._settlePromiseLateCancellationObserver = function(ctx) { + var handler = ctx.handler; + var promise = ctx.promise; + var receiver = ctx.receiver; + var value = ctx.value; + if (typeof handler === "function") { + if (!(promise instanceof Promise)) { + handler.call(receiver, value, promise); + } else { + this._settlePromiseFromHandler(handler, receiver, value, promise); + } + } else if (promise instanceof Promise) { + promise._reject(value); + } +}; -var SyntheticMouseEvent = __webpack_require__(42); +Promise.prototype._settlePromiseCtx = function(ctx) { + this._settlePromise(ctx.promise, ctx.handler, ctx.receiver, ctx.value); +}; -/** - * @interface DragEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var DragEventInterface = { - dataTransfer: null +Promise.prototype._settlePromise0 = function(handler, value, bitField) { + var promise = this._promise0; + var receiver = this._receiverAt(0); + this._promise0 = undefined; + this._receiver0 = undefined; + this._settlePromise(promise, handler, receiver, value); }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticDragEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.prototype._clearCallbackDataAtIndex = function(index) { + var base = index * 4 - 4; + this[base + 2] = + this[base + 3] = + this[base + 0] = + this[base + 1] = undefined; +}; -SyntheticMouseEvent.augmentClass(SyntheticDragEvent, DragEventInterface); +Promise.prototype._fulfill = function (value) { + var bitField = this._bitField; + if (((bitField & 117506048) >>> 16)) return; + if (value === this) { + var err = makeSelfResolutionError(); + this._attachExtraTrace(err); + return this._reject(err); + } + this._setFulfilled(); + this._rejectionHandler0 = value; -module.exports = SyntheticDragEvent; + if ((bitField & 65535) > 0) { + if (((bitField & 134217728) !== 0)) { + this._settlePromises(); + } else { + async.settlePromises(this); + } + } +}; -/***/ }), -/* 207 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._reject = function (reason) { + var bitField = this._bitField; + if (((bitField & 117506048) >>> 16)) return; + this._setRejected(); + this._fulfillmentHandler0 = reason; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + if (this._isFinal()) { + return async.fatalError(reason, util.isNode); + } + if ((bitField & 65535) > 0) { + async.settlePromises(this); + } else { + this._ensurePossibleRejectionHandled(); + } +}; +Promise.prototype._fulfillPromises = function (len, value) { + for (var i = 1; i < len; i++) { + var handler = this._fulfillmentHandlerAt(i); + var promise = this._promiseAt(i); + var receiver = this._receiverAt(i); + this._clearCallbackDataAtIndex(i); + this._settlePromise(promise, handler, receiver, value); + } +}; -var SyntheticUIEvent = __webpack_require__(33); +Promise.prototype._rejectPromises = function (len, reason) { + for (var i = 1; i < len; i++) { + var handler = this._rejectionHandlerAt(i); + var promise = this._promiseAt(i); + var receiver = this._receiverAt(i); + this._clearCallbackDataAtIndex(i); + this._settlePromise(promise, handler, receiver, reason); + } +}; -var getEventModifierState = __webpack_require__(54); +Promise.prototype._settlePromises = function () { + var bitField = this._bitField; + var len = (bitField & 65535); -/** - * @interface TouchEvent - * @see http://www.w3.org/TR/touch-events/ - */ -var TouchEventInterface = { - touches: null, - targetTouches: null, - changedTouches: null, - altKey: null, - metaKey: null, - ctrlKey: null, - shiftKey: null, - getModifierState: getEventModifierState + if (len > 0) { + if (((bitField & 16842752) !== 0)) { + var reason = this._fulfillmentHandler0; + this._settlePromise0(this._rejectionHandler0, reason, bitField); + this._rejectPromises(len, reason); + } else { + var value = this._rejectionHandler0; + this._settlePromise0(this._fulfillmentHandler0, value, bitField); + this._fulfillPromises(len, value); + } + this._setLength(0); + } + this._clearCancellationData(); }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticTouchEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.prototype._settledValue = function() { + var bitField = this._bitField; + if (((bitField & 33554432) !== 0)) { + return this._rejectionHandler0; + } else if (((bitField & 16777216) !== 0)) { + return this._fulfillmentHandler0; + } +}; -SyntheticUIEvent.augmentClass(SyntheticTouchEvent, TouchEventInterface); +function deferResolve(v) {this.promise._resolveCallback(v);} +function deferReject(v) {this.promise._rejectCallback(v, false);} -module.exports = SyntheticTouchEvent; +Promise.defer = Promise.pending = function() { + debug.deprecated("Promise.defer", "new Promise"); + var promise = new Promise(INTERNAL); + return { + promise: promise, + resolve: deferResolve, + reject: deferReject + }; +}; -/***/ }), -/* 208 */ -/***/ (function(module, exports, __webpack_require__) { +util.notEnumerableProp(Promise, + "_makeSelfResolutionError", + makeSelfResolutionError); + +_dereq_("./method")(Promise, INTERNAL, tryConvertToPromise, apiRejection, + debug); +_dereq_("./bind")(Promise, INTERNAL, tryConvertToPromise, debug); +_dereq_("./cancel")(Promise, PromiseArray, apiRejection, debug); +_dereq_("./direct_resolve")(Promise); +_dereq_("./synchronous_inspection")(Promise); +_dereq_("./join")( + Promise, PromiseArray, tryConvertToPromise, INTERNAL, async, getDomain); +Promise.Promise = Promise; +Promise.version = "3.5.0"; +_dereq_('./map.js')(Promise, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug); +_dereq_('./call_get.js')(Promise); +_dereq_('./using.js')(Promise, apiRejection, tryConvertToPromise, createContext, INTERNAL, debug); +_dereq_('./timers.js')(Promise, INTERNAL, debug); +_dereq_('./generators.js')(Promise, apiRejection, INTERNAL, tryConvertToPromise, Proxyable, debug); +_dereq_('./nodeify.js')(Promise); +_dereq_('./promisify.js')(Promise, INTERNAL); +_dereq_('./props.js')(Promise, PromiseArray, tryConvertToPromise, apiRejection); +_dereq_('./race.js')(Promise, INTERNAL, tryConvertToPromise, apiRejection); +_dereq_('./reduce.js')(Promise, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug); +_dereq_('./settle.js')(Promise, PromiseArray, debug); +_dereq_('./some.js')(Promise, PromiseArray, apiRejection); +_dereq_('./filter.js')(Promise, INTERNAL); +_dereq_('./each.js')(Promise, INTERNAL); +_dereq_('./any.js')(Promise); + + util.toFastProperties(Promise); + util.toFastProperties(Promise.prototype); + function fillTypes(value) { + var p = new Promise(INTERNAL); + p._fulfillmentHandler0 = value; + p._rejectionHandler0 = value; + p._promise0 = value; + p._receiver0 = value; + } + // Complete slack tracking, opt out of field-type tracking and + // stabilize map + fillTypes({a: 1}); + fillTypes({b: 2}); + fillTypes({c: 3}); + fillTypes(1); + fillTypes(function(){}); + fillTypes(undefined); + fillTypes(false); + fillTypes(new Promise(INTERNAL)); + debug.setBounds(Async.firstLineError, util.lastLineError); + return Promise; + +}; +},{"./any.js":1,"./async":2,"./bind":3,"./call_get.js":5,"./cancel":6,"./catch_filter":7,"./context":8,"./debuggability":9,"./direct_resolve":10,"./each.js":11,"./errors":12,"./es5":13,"./filter.js":14,"./finally":15,"./generators.js":16,"./join":17,"./map.js":18,"./method":19,"./nodeback":20,"./nodeify.js":21,"./promise_array":23,"./promisify.js":24,"./props.js":25,"./race.js":27,"./reduce.js":28,"./settle.js":30,"./some.js":31,"./synchronous_inspection":32,"./thenables":33,"./timers.js":34,"./using.js":35,"./util":36}],23:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = function(Promise, INTERNAL, tryConvertToPromise, + apiRejection, Proxyable) { +var util = _dereq_("./util"); +var isArray = util.isArray; +function toResolutionValue(val) { + switch(val) { + case -2: return []; + case -3: return {}; + case -6: return new Map(); + } +} +function PromiseArray(values) { + var promise = this._promise = new Promise(INTERNAL); + if (values instanceof Promise) { + promise._propagateFrom(values, 3); + } + promise._setOnCancel(this); + this._values = values; + this._length = 0; + this._totalResolved = 0; + this._init(undefined, -2); +} +util.inherits(PromiseArray, Proxyable); -var SyntheticEvent = __webpack_require__(16); +PromiseArray.prototype.length = function () { + return this._length; +}; -/** - * @interface Event - * @see http://www.w3.org/TR/2009/WD-css3-transitions-20090320/#transition-events- - * @see https://developer.mozilla.org/en-US/docs/Web/API/TransitionEvent - */ -var TransitionEventInterface = { - propertyName: null, - elapsedTime: null, - pseudoElement: null +PromiseArray.prototype.promise = function () { + return this._promise; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticTransitionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +PromiseArray.prototype._init = function init(_, resolveValueIfEmpty) { + var values = tryConvertToPromise(this._values, this._promise); + if (values instanceof Promise) { + values = values._target(); + var bitField = values._bitField; + ; + this._values = values; + + if (((bitField & 50397184) === 0)) { + this._promise._setAsyncGuaranteed(); + return values._then( + init, + this._reject, + undefined, + this, + resolveValueIfEmpty + ); + } else if (((bitField & 33554432) !== 0)) { + values = values._value(); + } else if (((bitField & 16777216) !== 0)) { + return this._reject(values._reason()); + } else { + return this._cancel(); + } + } + values = util.asArray(values); + if (values === null) { + var err = apiRejection( + "expecting an array or an iterable object but got " + util.classString(values)).reason(); + this._promise._rejectCallback(err, false); + return; + } -SyntheticEvent.augmentClass(SyntheticTransitionEvent, TransitionEventInterface); + if (values.length === 0) { + if (resolveValueIfEmpty === -5) { + this._resolveEmptyArray(); + } + else { + this._resolve(toResolutionValue(resolveValueIfEmpty)); + } + return; + } + this._iterate(values); +}; -module.exports = SyntheticTransitionEvent; +PromiseArray.prototype._iterate = function(values) { + var len = this.getActualLength(values.length); + this._length = len; + this._values = this.shouldCopyValues() ? new Array(len) : this._values; + var result = this._promise; + var isResolved = false; + var bitField = null; + for (var i = 0; i < len; ++i) { + var maybePromise = tryConvertToPromise(values[i], result); + + if (maybePromise instanceof Promise) { + maybePromise = maybePromise._target(); + bitField = maybePromise._bitField; + } else { + bitField = null; + } -/***/ }), -/* 209 */ -/***/ (function(module, exports, __webpack_require__) { + if (isResolved) { + if (bitField !== null) { + maybePromise.suppressUnhandledRejections(); + } + } else if (bitField !== null) { + if (((bitField & 50397184) === 0)) { + maybePromise._proxy(this, i); + this._values[i] = maybePromise; + } else if (((bitField & 33554432) !== 0)) { + isResolved = this._promiseFulfilled(maybePromise._value(), i); + } else if (((bitField & 16777216) !== 0)) { + isResolved = this._promiseRejected(maybePromise._reason(), i); + } else { + isResolved = this._promiseCancelled(i); + } + } else { + isResolved = this._promiseFulfilled(maybePromise, i); + } + } + if (!isResolved) result._setAsyncGuaranteed(); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +PromiseArray.prototype._isResolved = function () { + return this._values === null; +}; +PromiseArray.prototype._resolve = function (value) { + this._values = null; + this._promise._fulfill(value); +}; +PromiseArray.prototype._cancel = function() { + if (this._isResolved() || !this._promise._isCancellable()) return; + this._values = null; + this._promise._cancel(); +}; -var SyntheticMouseEvent = __webpack_require__(42); +PromiseArray.prototype._reject = function (reason) { + this._values = null; + this._promise._rejectCallback(reason, false); +}; -/** - * @interface WheelEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var WheelEventInterface = { - deltaX: function (event) { - return 'deltaX' in event ? event.deltaX : // Fallback to `wheelDeltaX` for Webkit and normalize (right is positive). - 'wheelDeltaX' in event ? -event.wheelDeltaX : 0; - }, - deltaY: function (event) { - return 'deltaY' in event ? event.deltaY : // Fallback to `wheelDeltaY` for Webkit and normalize (down is positive). - 'wheelDeltaY' in event ? -event.wheelDeltaY : // Fallback to `wheelDelta` for IE<9 and normalize (down is positive). - 'wheelDelta' in event ? -event.wheelDelta : 0; - }, - deltaZ: null, +PromiseArray.prototype._promiseFulfilled = function (value, index) { + this._values[index] = value; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + this._resolve(this._values); + return true; + } + return false; +}; - // Browsers without "deltaMode" is reporting in raw wheel delta where one - // notch on the scroll is always +/- 120, roughly equivalent to pixels. - // A good approximation of DOM_DELTA_LINE (1) is 5% of viewport size or - // ~40 pixels, for DOM_DELTA_SCREEN (2) it is 87.5% of viewport size. - deltaMode: null +PromiseArray.prototype._promiseCancelled = function() { + this._cancel(); + return true; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticMouseEvent} - */ -function SyntheticWheelEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +PromiseArray.prototype._promiseRejected = function (reason) { + this._totalResolved++; + this._reject(reason); + return true; +}; -SyntheticMouseEvent.augmentClass(SyntheticWheelEvent, WheelEventInterface); +PromiseArray.prototype._resultCancelled = function() { + if (this._isResolved()) return; + var values = this._values; + this._cancel(); + if (values instanceof Promise) { + values.cancel(); + } else { + for (var i = 0; i < values.length; ++i) { + if (values[i] instanceof Promise) { + values[i].cancel(); + } + } + } +}; -module.exports = SyntheticWheelEvent; +PromiseArray.prototype.shouldCopyValues = function () { + return true; +}; -/***/ }), -/* 210 */ -/***/ (function(module, exports, __webpack_require__) { +PromiseArray.prototype.getActualLength = function (len) { + return len; +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +return PromiseArray; +}; +},{"./util":36}],24:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL) { +var THIS = {}; +var util = _dereq_("./util"); +var nodebackForPromise = _dereq_("./nodeback"); +var withAppended = util.withAppended; +var maybeWrapAsError = util.maybeWrapAsError; +var canEvaluate = util.canEvaluate; +var TypeError = _dereq_("./errors").TypeError; +var defaultSuffix = "Async"; +var defaultPromisified = {__isPromisified__: true}; +var noCopyProps = [ + "arity", "length", + "name", + "arguments", + "caller", + "callee", + "prototype", + "__isPromisified__" +]; +var noCopyPropsPattern = new RegExp("^(?:" + noCopyProps.join("|") + ")$"); + +var defaultFilter = function(name) { + return util.isIdentifier(name) && + name.charAt(0) !== "_" && + name !== "constructor"; +}; +function propsFilter(key) { + return !noCopyPropsPattern.test(key); +} -var validateDOMNesting = __webpack_require__(64); +function isPromisified(fn) { + try { + return fn.__isPromisified__ === true; + } + catch (e) { + return false; + } +} -var DOC_NODE_TYPE = 9; +function hasPromisified(obj, key, suffix) { + var val = util.getDataPropertyOrDefault(obj, key + suffix, + defaultPromisified); + return val ? isPromisified(val) : false; +} +function checkValid(ret, suffix, suffixRegexp) { + for (var i = 0; i < ret.length; i += 2) { + var key = ret[i]; + if (suffixRegexp.test(key)) { + var keyWithoutAsyncSuffix = key.replace(suffixRegexp, ""); + for (var j = 0; j < ret.length; j += 2) { + if (ret[j] === keyWithoutAsyncSuffix) { + throw new TypeError("Cannot promisify an API that has normal methods with '%s'-suffix\u000a\u000a See http://goo.gl/MqrFmX\u000a" + .replace("%s", suffix)); + } + } + } + } +} -function ReactDOMContainerInfo(topLevelWrapper, node) { - var info = { - _topLevelWrapper: topLevelWrapper, - _idCounter: 1, - _ownerDocument: node ? node.nodeType === DOC_NODE_TYPE ? node : node.ownerDocument : null, - _node: node, - _tag: node ? node.nodeName.toLowerCase() : null, - _namespaceURI: node ? node.namespaceURI : null - }; - if (process.env.NODE_ENV !== 'production') { - info._ancestorInfo = node ? validateDOMNesting.updatedAncestorInfo(null, info._tag, null) : null; - } - return info; +function promisifiableMethods(obj, suffix, suffixRegexp, filter) { + var keys = util.inheritedDataKeys(obj); + var ret = []; + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + var value = obj[key]; + var passesDefaultFilter = filter === defaultFilter + ? true : defaultFilter(key, value, obj); + if (typeof value === "function" && + !isPromisified(value) && + !hasPromisified(obj, key, suffix) && + filter(key, value, obj, passesDefaultFilter)) { + ret.push(key, value); + } + } + checkValid(ret, suffix, suffixRegexp); + return ret; } -module.exports = ReactDOMContainerInfo; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var escapeIdentRegex = function(str) { + return str.replace(/([$])/, "\\$"); +}; -/***/ }), -/* 211 */ -/***/ (function(module, exports, __webpack_require__) { +var makeNodePromisifiedEval; +if (false) { +var switchCaseArgumentOrder = function(likelyArgumentCount) { + var ret = [likelyArgumentCount]; + var min = Math.max(0, likelyArgumentCount - 1 - 3); + for(var i = likelyArgumentCount - 1; i >= min; --i) { + ret.push(i); + } + for(var i = likelyArgumentCount + 1; i <= 3; ++i) { + ret.push(i); + } + return ret; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var argumentSequence = function(argumentCount) { + return util.filledRange(argumentCount, "_arg", ""); +}; +var parameterDeclaration = function(parameterCount) { + return util.filledRange( + Math.max(parameterCount, 3), "_arg", ""); +}; +var parameterCount = function(fn) { + if (typeof fn.length === "number") { + return Math.max(Math.min(fn.length, 1023 + 1), 0); + } + return 0; +}; -var ReactDOMFeatureFlags = { - useCreateElement: true, - useFiber: false +makeNodePromisifiedEval = +function(callback, receiver, originalName, fn, _, multiArgs) { + var newParameterCount = Math.max(0, parameterCount(fn) - 1); + var argumentOrder = switchCaseArgumentOrder(newParameterCount); + var shouldProxyThis = typeof callback === "string" || receiver === THIS; + + function generateCallForArgumentCount(count) { + var args = argumentSequence(count).join(", "); + var comma = count > 0 ? ", " : ""; + var ret; + if (shouldProxyThis) { + ret = "ret = callback.call(this, {{args}}, nodeback); break;\n"; + } else { + ret = receiver === undefined + ? "ret = callback({{args}}, nodeback); break;\n" + : "ret = callback.call(receiver, {{args}}, nodeback); break;\n"; + } + return ret.replace("{{args}}", args).replace(", ", comma); + } + + function generateArgumentSwitchCase() { + var ret = ""; + for (var i = 0; i < argumentOrder.length; ++i) { + ret += "case " + argumentOrder[i] +":" + + generateCallForArgumentCount(argumentOrder[i]); + } + + ret += " \n\ + default: \n\ + var args = new Array(len + 1); \n\ + var i = 0; \n\ + for (var i = 0; i < len; ++i) { \n\ + args[i] = arguments[i]; \n\ + } \n\ + args[i] = nodeback; \n\ + [CodeForCall] \n\ + break; \n\ + ".replace("[CodeForCall]", (shouldProxyThis + ? "ret = callback.apply(this, args);\n" + : "ret = callback.apply(receiver, args);\n")); + return ret; + } + + var getFunctionCode = typeof callback === "string" + ? ("this != null ? this['"+callback+"'] : fn") + : "fn"; + var body = "'use strict'; \n\ + var ret = function (Parameters) { \n\ + 'use strict'; \n\ + var len = arguments.length; \n\ + var promise = new Promise(INTERNAL); \n\ + promise._captureStackTrace(); \n\ + var nodeback = nodebackForPromise(promise, " + multiArgs + "); \n\ + var ret; \n\ + var callback = tryCatch([GetFunctionCode]); \n\ + switch(len) { \n\ + [CodeForSwitchCase] \n\ + } \n\ + if (ret === errorObj) { \n\ + promise._rejectCallback(maybeWrapAsError(ret.e), true, true);\n\ + } \n\ + if (!promise._isFateSealed()) promise._setAsyncGuaranteed(); \n\ + return promise; \n\ + }; \n\ + notEnumerableProp(ret, '__isPromisified__', true); \n\ + return ret; \n\ + ".replace("[CodeForSwitchCase]", generateArgumentSwitchCase()) + .replace("[GetFunctionCode]", getFunctionCode); + body = body.replace("Parameters", parameterDeclaration(newParameterCount)); + return new Function("Promise", + "fn", + "receiver", + "withAppended", + "maybeWrapAsError", + "nodebackForPromise", + "tryCatch", + "errorObj", + "notEnumerableProp", + "INTERNAL", + body)( + Promise, + fn, + receiver, + withAppended, + maybeWrapAsError, + nodebackForPromise, + util.tryCatch, + util.errorObj, + util.notEnumerableProp, + INTERNAL); }; +} -module.exports = ReactDOMFeatureFlags; +function makeNodePromisifiedClosure(callback, receiver, _, fn, __, multiArgs) { + var defaultThis = (function() {return this;})(); + var method = callback; + if (typeof method === "string") { + callback = fn; + } + function promisified() { + var _receiver = receiver; + if (receiver === THIS) _receiver = this; + var promise = new Promise(INTERNAL); + promise._captureStackTrace(); + var cb = typeof method === "string" && this !== defaultThis + ? this[method] : callback; + var fn = nodebackForPromise(promise, multiArgs); + try { + cb.apply(_receiver, withAppended(arguments, fn)); + } catch(e) { + promise._rejectCallback(maybeWrapAsError(e), true, true); + } + if (!promise._isFateSealed()) promise._setAsyncGuaranteed(); + return promise; + } + util.notEnumerableProp(promisified, "__isPromisified__", true); + return promisified; +} -/***/ }), -/* 212 */ -/***/ (function(module, exports, __webpack_require__) { +var makeNodePromisified = canEvaluate + ? makeNodePromisifiedEval + : makeNodePromisifiedClosure; + +function promisifyAll(obj, suffix, filter, promisifier, multiArgs) { + var suffixRegexp = new RegExp(escapeIdentRegex(suffix) + "$"); + var methods = + promisifiableMethods(obj, suffix, suffixRegexp, filter); + + for (var i = 0, len = methods.length; i < len; i+= 2) { + var key = methods[i]; + var fn = methods[i+1]; + var promisifiedKey = key + suffix; + if (promisifier === makeNodePromisified) { + obj[promisifiedKey] = + makeNodePromisified(key, THIS, key, fn, suffix, multiArgs); + } else { + var promisified = promisifier(fn, function() { + return makeNodePromisified(key, THIS, key, + fn, suffix, multiArgs); + }); + util.notEnumerableProp(promisified, "__isPromisified__", true); + obj[promisifiedKey] = promisified; + } + } + util.toFastProperties(obj); + return obj; +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function promisify(callback, receiver, multiArgs) { + return makeNodePromisified(callback, receiver, undefined, + callback, null, multiArgs); +} +Promise.promisify = function (fn, options) { + if (typeof fn !== "function") { + throw new TypeError("expecting a function but got " + util.classString(fn)); + } + if (isPromisified(fn)) { + return fn; + } + options = Object(options); + var receiver = options.context === undefined ? THIS : options.context; + var multiArgs = !!options.multiArgs; + var ret = promisify(fn, receiver, multiArgs); + util.copyDescriptors(fn, ret, propsFilter); + return ret; +}; +Promise.promisifyAll = function (target, options) { + if (typeof target !== "function" && typeof target !== "object") { + throw new TypeError("the target of promisifyAll must be an object or a function\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + options = Object(options); + var multiArgs = !!options.multiArgs; + var suffix = options.suffix; + if (typeof suffix !== "string") suffix = defaultSuffix; + var filter = options.filter; + if (typeof filter !== "function") filter = defaultFilter; + var promisifier = options.promisifier; + if (typeof promisifier !== "function") promisifier = makeNodePromisified; + + if (!util.isIdentifier(suffix)) { + throw new RangeError("suffix must be a valid identifier\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + + var keys = util.inheritedDataKeys(target); + for (var i = 0; i < keys.length; ++i) { + var value = target[keys[i]]; + if (keys[i] !== "constructor" && + util.isClass(value)) { + promisifyAll(value.prototype, suffix, filter, promisifier, + multiArgs); + promisifyAll(value, suffix, filter, promisifier, multiArgs); + } + } -var adler32 = __webpack_require__(213); + return promisifyAll(target, suffix, filter, promisifier, multiArgs); +}; +}; -var TAG_END = /\/?>/; -var COMMENT_START = /^<\!\-\-/; -var ReactMarkupChecksum = { - CHECKSUM_ATTR_NAME: 'data-react-checksum', +},{"./errors":12,"./nodeback":20,"./util":36}],25:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function( + Promise, PromiseArray, tryConvertToPromise, apiRejection) { +var util = _dereq_("./util"); +var isObject = util.isObject; +var es5 = _dereq_("./es5"); +var Es6Map; +if (typeof Map === "function") Es6Map = Map; + +var mapToEntries = (function() { + var index = 0; + var size = 0; + + function extractEntry(value, key) { + this[index] = value; + this[index + size] = key; + index++; + } + + return function mapToEntries(map) { + size = map.size; + index = 0; + var ret = new Array(map.size * 2); + map.forEach(extractEntry, ret); + return ret; + }; +})(); - /** - * @param {string} markup Markup string - * @return {string} Markup string with checksum attribute attached - */ - addChecksumToMarkup: function (markup) { - var checksum = adler32(markup); +var entriesToMap = function(entries) { + var ret = new Es6Map(); + var length = entries.length / 2 | 0; + for (var i = 0; i < length; ++i) { + var key = entries[length + i]; + var value = entries[i]; + ret.set(key, value); + } + return ret; +}; - // Add checksum (handle both parent tags, comments and self-closing tags) - if (COMMENT_START.test(markup)) { - return markup; +function PropertiesPromiseArray(obj) { + var isMap = false; + var entries; + if (Es6Map !== undefined && obj instanceof Es6Map) { + entries = mapToEntries(obj); + isMap = true; } else { - return markup.replace(TAG_END, ' ' + ReactMarkupChecksum.CHECKSUM_ATTR_NAME + '="' + checksum + '"$&'); + var keys = es5.keys(obj); + var len = keys.length; + entries = new Array(len * 2); + for (var i = 0; i < len; ++i) { + var key = keys[i]; + entries[i] = obj[key]; + entries[i + len] = key; + } } - }, - - /** - * @param {string} markup to use - * @param {DOMElement} element root React element - * @returns {boolean} whether or not the markup is the same - */ - canReuseMarkup: function (markup, element) { - var existingChecksum = element.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); - existingChecksum = existingChecksum && parseInt(existingChecksum, 10); - var markupChecksum = adler32(markup); - return markupChecksum === existingChecksum; - } -}; + this.constructor$(entries); + this._isMap = isMap; + this._init$(undefined, isMap ? -6 : -3); +} +util.inherits(PropertiesPromiseArray, PromiseArray); -module.exports = ReactMarkupChecksum; +PropertiesPromiseArray.prototype._init = function () {}; -/***/ }), -/* 213 */ -/***/ (function(module, exports, __webpack_require__) { +PropertiesPromiseArray.prototype._promiseFulfilled = function (value, index) { + this._values[index] = value; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + var val; + if (this._isMap) { + val = entriesToMap(this._values); + } else { + val = {}; + var keyOffset = this.length(); + for (var i = 0, len = this.length(); i < len; ++i) { + val[this._values[i + keyOffset]] = this._values[i]; + } + } + this._resolve(val); + return true; + } + return false; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +PropertiesPromiseArray.prototype.shouldCopyValues = function () { + return false; +}; +PropertiesPromiseArray.prototype.getActualLength = function (len) { + return len >> 1; +}; +function props(promises) { + var ret; + var castValue = tryConvertToPromise(promises); -var MOD = 65521; + if (!isObject(castValue)) { + return apiRejection("cannot await properties of a non-object\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } else if (castValue instanceof Promise) { + ret = castValue._then( + Promise.props, undefined, undefined, undefined, undefined); + } else { + ret = new PropertiesPromiseArray(castValue).promise(); + } -// adler32 is not cryptographically strong, and is only used to sanity check that -// markup generated on the server matches the markup generated on the client. -// This implementation (a modified version of the SheetJS version) has been optimized -// for our use case, at the expense of conforming to the adler32 specification -// for non-ascii inputs. -function adler32(data) { - var a = 1; - var b = 0; - var i = 0; - var l = data.length; - var m = l & ~0x3; - while (i < m) { - var n = Math.min(i + 4096, m); - for (; i < n; i += 4) { - b += (a += data.charCodeAt(i)) + (a += data.charCodeAt(i + 1)) + (a += data.charCodeAt(i + 2)) + (a += data.charCodeAt(i + 3)); + if (castValue instanceof Promise) { + ret._propagateFrom(castValue, 2); } - a %= MOD; - b %= MOD; - } - for (; i < l; i++) { - b += a += data.charCodeAt(i); - } - a %= MOD; - b %= MOD; - return a | b << 16; + return ret; } -module.exports = adler32; +Promise.prototype.props = function () { + return props(this); +}; -/***/ }), -/* 214 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.props = function (promises) { + return props(promises); +}; +}; +},{"./es5":13,"./util":36}],26:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +function arrayMove(src, srcIndex, dst, dstIndex, len) { + for (var j = 0; j < len; ++j) { + dst[j + dstIndex] = src[j + srcIndex]; + src[j + srcIndex] = void 0; + } +} +function Queue(capacity) { + this._capacity = capacity; + this._length = 0; + this._front = 0; +} -module.exports = '15.6.1'; +Queue.prototype._willBeOverCapacity = function (size) { + return this._capacity < size; +}; -/***/ }), -/* 215 */ -/***/ (function(module, exports, __webpack_require__) { +Queue.prototype._pushOne = function (arg) { + var length = this.length(); + this._checkCapacity(length + 1); + var i = (this._front + length) & (this._capacity - 1); + this[i] = arg; + this._length = length + 1; +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Queue.prototype.push = function (fn, receiver, arg) { + var length = this.length() + 3; + if (this._willBeOverCapacity(length)) { + this._pushOne(fn); + this._pushOne(receiver); + this._pushOne(arg); + return; + } + var j = this._front + length - 3; + this._checkCapacity(length); + var wrapMask = this._capacity - 1; + this[(j + 0) & wrapMask] = fn; + this[(j + 1) & wrapMask] = receiver; + this[(j + 2) & wrapMask] = arg; + this._length = length; +}; +Queue.prototype.shift = function () { + var front = this._front, + ret = this[front]; + this[front] = undefined; + this._front = (front + 1) & (this._capacity - 1); + this._length--; + return ret; +}; -var _prodInvariant = __webpack_require__(3); +Queue.prototype.length = function () { + return this._length; +}; -var ReactCurrentOwner = __webpack_require__(14); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstanceMap = __webpack_require__(34); +Queue.prototype._checkCapacity = function (size) { + if (this._capacity < size) { + this._resizeTo(this._capacity << 1); + } +}; -var getHostComponentFromComposite = __webpack_require__(105); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +Queue.prototype._resizeTo = function (capacity) { + var oldCapacity = this._capacity; + this._capacity = capacity; + var front = this._front; + var length = this._length; + var moveItemsCount = (front + length) & (oldCapacity - 1); + arrayMove(this, 0, this, oldCapacity, moveItemsCount); +}; -/** - * Returns the DOM node rendered by this element. - * - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.finddomnode - * - * @param {ReactComponent|DOMElement} componentOrElement - * @return {?DOMElement} The root node of this element. - */ -function findDOMNode(componentOrElement) { - if (process.env.NODE_ENV !== 'production') { - var owner = ReactCurrentOwner.current; - if (owner !== null) { - process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing findDOMNode inside its render(). ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; - owner._warnedAboutRefsInRender = true; - } - } - if (componentOrElement == null) { - return null; - } - if (componentOrElement.nodeType === 1) { - return componentOrElement; - } +module.exports = Queue; - var inst = ReactInstanceMap.get(componentOrElement); - if (inst) { - inst = getHostComponentFromComposite(inst); - return inst ? ReactDOMComponentTree.getNodeFromInstance(inst) : null; - } +},{}],27:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function( + Promise, INTERNAL, tryConvertToPromise, apiRejection) { +var util = _dereq_("./util"); - if (typeof componentOrElement.render === 'function') { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'findDOMNode was called on an unmounted component.') : _prodInvariant('44') : void 0; - } else { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element appears to be neither ReactComponent nor DOMNode (keys: %s)', Object.keys(componentOrElement)) : _prodInvariant('45', Object.keys(componentOrElement)) : void 0; - } -} +var raceLater = function (promise) { + return promise.then(function(array) { + return race(array, promise); + }); +}; -module.exports = findDOMNode; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function race(promises, parent) { + var maybePromise = tryConvertToPromise(promises); -/***/ }), -/* 216 */ -/***/ (function(module, exports, __webpack_require__) { + if (maybePromise instanceof Promise) { + return raceLater(maybePromise); + } else { + promises = util.asArray(promises); + if (promises === null) + return apiRejection("expecting an array or an iterable object but got " + util.classString(promises)); + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var ret = new Promise(INTERNAL); + if (parent !== undefined) { + ret._propagateFrom(parent, 3); + } + var fulfill = ret._fulfill; + var reject = ret._reject; + for (var i = 0, len = promises.length; i < len; ++i) { + var val = promises[i]; + if (val === undefined && !(i in promises)) { + continue; + } + Promise.cast(val)._then(fulfill, reject, undefined, ret, null); + } + return ret; +} -var ReactMount = __webpack_require__(104); +Promise.race = function (promises) { + return race(promises, undefined); +}; -module.exports = ReactMount.renderSubtreeIntoContainer; +Promise.prototype.race = function () { + return race(this, undefined); +}; -/***/ }), -/* 217 */ -/***/ (function(module, exports, __webpack_require__) { +}; +},{"./util":36}],28:[function(_dereq_,module,exports){ "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = function(Promise, + PromiseArray, + apiRejection, + tryConvertToPromise, + INTERNAL, + debug) { +var getDomain = Promise._getDomain; +var util = _dereq_("./util"); +var tryCatch = util.tryCatch; + +function ReductionPromiseArray(promises, fn, initialValue, _each) { + this.constructor$(promises); + var domain = getDomain(); + this._fn = domain === null ? fn : util.domainBind(domain, fn); + if (initialValue !== undefined) { + initialValue = Promise.resolve(initialValue); + initialValue._attachCancellationCallback(this); + } + this._initialValue = initialValue; + this._currentCancellable = null; + if(_each === INTERNAL) { + this._eachValues = Array(this._length); + } else if (_each === 0) { + this._eachValues = null; + } else { + this._eachValues = undefined; + } + this._promise._captureStackTrace(); + this._init$(undefined, -5); +} +util.inherits(ReductionPromiseArray, PromiseArray); + +ReductionPromiseArray.prototype._gotAccum = function(accum) { + if (this._eachValues !== undefined && + this._eachValues !== null && + accum !== INTERNAL) { + this._eachValues.push(accum); + } +}; +ReductionPromiseArray.prototype._eachComplete = function(value) { + if (this._eachValues !== null) { + this._eachValues.push(value); + } + return this._eachValues; +}; +ReductionPromiseArray.prototype._init = function() {}; -var DOMProperty = __webpack_require__(17); -var EventPluginRegistry = __webpack_require__(40); -var ReactComponentTreeHook = __webpack_require__(10); +ReductionPromiseArray.prototype._resolveEmptyArray = function() { + this._resolve(this._eachValues !== undefined ? this._eachValues + : this._initialValue); +}; -var warning = __webpack_require__(2); +ReductionPromiseArray.prototype.shouldCopyValues = function () { + return false; +}; -if (process.env.NODE_ENV !== 'production') { - var reactProps = { - children: true, - dangerouslySetInnerHTML: true, - key: true, - ref: true, +ReductionPromiseArray.prototype._resolve = function(value) { + this._promise._resolveCallback(value); + this._values = null; +}; - autoFocus: true, - defaultValue: true, - valueLink: true, - defaultChecked: true, - checkedLink: true, - innerHTML: true, - suppressContentEditableWarning: true, - onFocusIn: true, - onFocusOut: true - }; - var warnedProperties = {}; +ReductionPromiseArray.prototype._resultCancelled = function(sender) { + if (sender === this._initialValue) return this._cancel(); + if (this._isResolved()) return; + this._resultCancelled$(); + if (this._currentCancellable instanceof Promise) { + this._currentCancellable.cancel(); + } + if (this._initialValue instanceof Promise) { + this._initialValue.cancel(); + } +}; - var validateProperty = function (tagName, name, debugID) { - if (DOMProperty.properties.hasOwnProperty(name) || DOMProperty.isCustomAttribute(name)) { - return true; +ReductionPromiseArray.prototype._iterate = function (values) { + this._values = values; + var value; + var i; + var length = values.length; + if (this._initialValue !== undefined) { + value = this._initialValue; + i = 0; + } else { + value = Promise.resolve(values[0]); + i = 1; } - if (reactProps.hasOwnProperty(name) && reactProps[name] || warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { - return true; + + this._currentCancellable = value; + + if (!value.isRejected()) { + for (; i < length; ++i) { + var ctx = { + accum: null, + value: values[i], + index: i, + length: length, + array: this + }; + value = value._then(gotAccum, undefined, undefined, ctx, undefined); + } } - if (EventPluginRegistry.registrationNameModules.hasOwnProperty(name)) { - return true; + + if (this._eachValues !== undefined) { + value = value + ._then(this._eachComplete, undefined, undefined, this, undefined); } - warnedProperties[name] = true; - var lowerCasedName = name.toLowerCase(); + value._then(completed, completed, undefined, value, this); +}; - // data-* attributes should be lowercase; suggest the lowercase version - var standardName = DOMProperty.isCustomAttribute(lowerCasedName) ? lowerCasedName : DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; +Promise.prototype.reduce = function (fn, initialValue) { + return reduce(this, fn, initialValue, null); +}; - var registrationName = EventPluginRegistry.possibleRegistrationNames.hasOwnProperty(lowerCasedName) ? EventPluginRegistry.possibleRegistrationNames[lowerCasedName] : null; +Promise.reduce = function (promises, fn, initialValue, _each) { + return reduce(promises, fn, initialValue, _each); +}; - if (standardName != null) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown DOM property %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - return true; - } else if (registrationName != null) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown event handler property %s. Did you mean `%s`?%s', name, registrationName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - return true; +function completed(valueOrReason, array) { + if (this.isFulfilled()) { + array._resolve(valueOrReason); } else { - // We were unable to guess which prop the user intended. - // It is likely that the user was just blindly spreading/forwarding props - // Components should be careful to only render valid props/attributes. - // Warning will be invoked in warnUnknownProperties to allow grouping. - return false; + array._reject(valueOrReason); } - }; } -var warnUnknownProperties = function (debugID, element) { - var unknownProps = []; - for (var key in element.props) { - var isValid = validateProperty(element.type, key, debugID); - if (!isValid) { - unknownProps.push(key); +function reduce(promises, fn, initialValue, _each) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); } - } - - var unknownPropString = unknownProps.map(function (prop) { - return '`' + prop + '`'; - }).join(', '); + var array = new ReductionPromiseArray(promises, fn, initialValue, _each); + return array.promise(); +} - if (unknownProps.length === 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown prop %s on <%s> tag. Remove this prop from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } else if (unknownProps.length > 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown props %s on <%s> tag. Remove these props from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } -}; +function gotAccum(accum) { + this.accum = accum; + this.array._gotAccum(accum); + var value = tryConvertToPromise(this.value, this.array._promise); + if (value instanceof Promise) { + this.array._currentCancellable = value; + return value._then(gotValue, undefined, undefined, this, undefined); + } else { + return gotValue.call(this, value); + } +} -function handleElement(debugID, element) { - if (element == null || typeof element.type !== 'string') { - return; - } - if (element.type.indexOf('-') >= 0 || element.props.is) { - return; - } - warnUnknownProperties(debugID, element); +function gotValue(value) { + var array = this.array; + var promise = array._promise; + var fn = tryCatch(array._fn); + promise._pushContext(); + var ret; + if (array._eachValues !== undefined) { + ret = fn.call(promise._boundValue(), value, this.index, this.length); + } else { + ret = fn.call(promise._boundValue(), + this.accum, value, this.index, this.length); + } + if (ret instanceof Promise) { + array._currentCancellable = ret; + } + var promiseCreated = promise._popContext(); + debug.checkForgottenReturns( + ret, + promiseCreated, + array._eachValues !== undefined ? "Promise.each" : "Promise.reduce", + promise + ); + return ret; } +}; -var ReactDOMUnknownPropertyHook = { - onBeforeMountComponent: function (debugID, element) { - handleElement(debugID, element); - }, - onBeforeUpdateComponent: function (debugID, element) { - handleElement(debugID, element); - } +},{"./util":36}],29:[function(_dereq_,module,exports){ +"use strict"; +var util = _dereq_("./util"); +var schedule; +var noAsyncScheduler = function() { + throw new Error("No async scheduler available\u000a\u000a See http://goo.gl/MqrFmX\u000a"); }; +var NativePromise = util.getNativePromise(); +if (util.isNode && typeof MutationObserver === "undefined") { + var GlobalSetImmediate = global.setImmediate; + var ProcessNextTick = process.nextTick; + schedule = util.isRecentNode + ? function(fn) { GlobalSetImmediate.call(global, fn); } + : function(fn) { ProcessNextTick.call(process, fn); }; +} else if (typeof NativePromise === "function" && + typeof NativePromise.resolve === "function") { + var nativePromise = NativePromise.resolve(); + schedule = function(fn) { + nativePromise.then(fn); + }; +} else if ((typeof MutationObserver !== "undefined") && + !(typeof window !== "undefined" && + window.navigator && + (window.navigator.standalone || window.cordova))) { + schedule = (function() { + var div = document.createElement("div"); + var opts = {attributes: true}; + var toggleScheduled = false; + var div2 = document.createElement("div"); + var o2 = new MutationObserver(function() { + div.classList.toggle("foo"); + toggleScheduled = false; + }); + o2.observe(div2, opts); -module.exports = ReactDOMUnknownPropertyHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var scheduleToggle = function() { + if (toggleScheduled) return; + toggleScheduled = true; + div2.classList.toggle("foo"); + }; -/***/ }), -/* 218 */ -/***/ (function(module, exports, __webpack_require__) { + return function schedule(fn) { + var o = new MutationObserver(function() { + o.disconnect(); + fn(); + }); + o.observe(div, opts); + scheduleToggle(); + }; + })(); +} else if (typeof setImmediate !== "undefined") { + schedule = function (fn) { + setImmediate(fn); + }; +} else if (typeof setTimeout !== "undefined") { + schedule = function (fn) { + setTimeout(fn, 0); + }; +} else { + schedule = noAsyncScheduler; +} +module.exports = schedule; +},{"./util":36}],30:[function(_dereq_,module,exports){ "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +module.exports = + function(Promise, PromiseArray, debug) { +var PromiseInspection = Promise.PromiseInspection; +var util = _dereq_("./util"); +function SettledPromiseArray(values) { + this.constructor$(values); +} +util.inherits(SettledPromiseArray, PromiseArray); -var ReactComponentTreeHook = __webpack_require__(10); +SettledPromiseArray.prototype._promiseResolved = function (index, inspection) { + this._values[index] = inspection; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + this._resolve(this._values); + return true; + } + return false; +}; -var warning = __webpack_require__(2); +SettledPromiseArray.prototype._promiseFulfilled = function (value, index) { + var ret = new PromiseInspection(); + ret._bitField = 33554432; + ret._settledValueField = value; + return this._promiseResolved(index, ret); +}; +SettledPromiseArray.prototype._promiseRejected = function (reason, index) { + var ret = new PromiseInspection(); + ret._bitField = 16777216; + ret._settledValueField = reason; + return this._promiseResolved(index, ret); +}; -var didWarnValueNull = false; +Promise.settle = function (promises) { + debug.deprecated(".settle()", ".reflect()"); + return new SettledPromiseArray(promises).promise(); +}; -function handleElement(debugID, element) { - if (element == null) { - return; - } - if (element.type !== 'input' && element.type !== 'textarea' && element.type !== 'select') { - return; - } - if (element.props != null && element.props.value === null && !didWarnValueNull) { - process.env.NODE_ENV !== 'production' ? warning(false, '`value` prop on `%s` should not be null. ' + 'Consider using the empty string to clear the component or `undefined` ' + 'for uncontrolled components.%s', element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; +Promise.prototype.settle = function () { + return Promise.settle(this); +}; +}; - didWarnValueNull = true; - } +},{"./util":36}],31:[function(_dereq_,module,exports){ +"use strict"; +module.exports = +function(Promise, PromiseArray, apiRejection) { +var util = _dereq_("./util"); +var RangeError = _dereq_("./errors").RangeError; +var AggregateError = _dereq_("./errors").AggregateError; +var isArray = util.isArray; +var CANCELLATION = {}; + + +function SomePromiseArray(values) { + this.constructor$(values); + this._howMany = 0; + this._unwrap = false; + this._initialized = false; } +util.inherits(SomePromiseArray, PromiseArray); -var ReactDOMNullInputValuePropHook = { - onBeforeMountComponent: function (debugID, element) { - handleElement(debugID, element); - }, - onBeforeUpdateComponent: function (debugID, element) { - handleElement(debugID, element); - } +SomePromiseArray.prototype._init = function () { + if (!this._initialized) { + return; + } + if (this._howMany === 0) { + this._resolve([]); + return; + } + this._init$(undefined, -5); + var isArrayResolved = isArray(this._values); + if (!this._isResolved() && + isArrayResolved && + this._howMany > this._canPossiblyFulfill()) { + this._reject(this._getRangeError(this.length())); + } }; -module.exports = ReactDOMNullInputValuePropHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +SomePromiseArray.prototype.init = function () { + this._initialized = true; + this._init(); +}; -/***/ }), -/* 219 */ -/***/ (function(module, exports, __webpack_require__) { +SomePromiseArray.prototype.setUnwrap = function () { + this._unwrap = true; +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +SomePromiseArray.prototype.howMany = function () { + return this._howMany; +}; +SomePromiseArray.prototype.setHowMany = function (count) { + this._howMany = count; +}; +SomePromiseArray.prototype._promiseFulfilled = function (value) { + this._addFulfilled(value); + if (this._fulfilled() === this.howMany()) { + this._values.length = this.howMany(); + if (this.howMany() === 1 && this._unwrap) { + this._resolve(this._values[0]); + } else { + this._resolve(this._values); + } + return true; + } + return false; -var DOMProperty = __webpack_require__(17); -var ReactComponentTreeHook = __webpack_require__(10); +}; +SomePromiseArray.prototype._promiseRejected = function (reason) { + this._addRejected(reason); + return this._checkOutcome(); +}; -var warning = __webpack_require__(2); +SomePromiseArray.prototype._promiseCancelled = function () { + if (this._values instanceof Promise || this._values == null) { + return this._cancel(); + } + this._addRejected(CANCELLATION); + return this._checkOutcome(); +}; -var warnedProperties = {}; -var rARIA = new RegExp('^(aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); +SomePromiseArray.prototype._checkOutcome = function() { + if (this.howMany() > this._canPossiblyFulfill()) { + var e = new AggregateError(); + for (var i = this.length(); i < this._values.length; ++i) { + if (this._values[i] !== CANCELLATION) { + e.push(this._values[i]); + } + } + if (e.length > 0) { + this._reject(e); + } else { + this._cancel(); + } + return true; + } + return false; +}; -function validateProperty(tagName, name, debugID) { - if (warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { - return true; - } +SomePromiseArray.prototype._fulfilled = function () { + return this._totalResolved; +}; - if (rARIA.test(name)) { - var lowerCasedName = name.toLowerCase(); - var standardName = DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; +SomePromiseArray.prototype._rejected = function () { + return this._values.length - this.length(); +}; - // If this is an aria-* attribute, but is not listed in the known DOM - // DOM properties, then it is an invalid aria-* attribute. - if (standardName == null) { - warnedProperties[name] = true; - return false; - } - // aria-* attributes should be lowercase; suggest the lowercase version. - if (name !== standardName) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown ARIA attribute %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - warnedProperties[name] = true; - return true; - } - } +SomePromiseArray.prototype._addRejected = function (reason) { + this._values.push(reason); +}; - return true; -} +SomePromiseArray.prototype._addFulfilled = function (value) { + this._values[this._totalResolved++] = value; +}; -function warnInvalidARIAProps(debugID, element) { - var invalidProps = []; +SomePromiseArray.prototype._canPossiblyFulfill = function () { + return this.length() - this._rejected(); +}; - for (var key in element.props) { - var isValid = validateProperty(element.type, key, debugID); - if (!isValid) { - invalidProps.push(key); - } - } +SomePromiseArray.prototype._getRangeError = function (count) { + var message = "Input array must contain at least " + + this._howMany + " items but contains only " + count + " items"; + return new RangeError(message); +}; - var unknownPropString = invalidProps.map(function (prop) { - return '`' + prop + '`'; - }).join(', '); +SomePromiseArray.prototype._resolveEmptyArray = function () { + this._reject(this._getRangeError(0)); +}; - if (invalidProps.length === 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria prop %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } else if (invalidProps.length > 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria props %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } +function some(promises, howMany) { + if ((howMany | 0) !== howMany || howMany < 0) { + return apiRejection("expecting a positive integer\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + var ret = new SomePromiseArray(promises); + var promise = ret.promise(); + ret.setHowMany(howMany); + ret.init(); + return promise; } -function handleElement(debugID, element) { - if (element == null || typeof element.type !== 'string') { - return; - } - if (element.type.indexOf('-') >= 0 || element.props.is) { - return; - } +Promise.some = function (promises, howMany) { + return some(promises, howMany); +}; - warnInvalidARIAProps(debugID, element); +Promise.prototype.some = function (howMany) { + return some(this, howMany); +}; + +Promise._SomePromiseArray = SomePromiseArray; +}; + +},{"./errors":12,"./util":36}],32:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +function PromiseInspection(promise) { + if (promise !== undefined) { + promise = promise._target(); + this._bitField = promise._bitField; + this._settledValueField = promise._isFateSealed() + ? promise._settledValue() : undefined; + } + else { + this._bitField = 0; + this._settledValueField = undefined; + } } -var ReactDOMInvalidARIAHook = { - onBeforeMountComponent: function (debugID, element) { - if (process.env.NODE_ENV !== 'production') { - handleElement(debugID, element); +PromiseInspection.prototype._settledValue = function() { + return this._settledValueField; +}; + +var value = PromiseInspection.prototype.value = function () { + if (!this.isFulfilled()) { + throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\u000a\u000a See http://goo.gl/MqrFmX\u000a"); } - }, - onBeforeUpdateComponent: function (debugID, element) { - if (process.env.NODE_ENV !== 'production') { - handleElement(debugID, element); + return this._settledValue(); +}; + +var reason = PromiseInspection.prototype.error = +PromiseInspection.prototype.reason = function () { + if (!this.isRejected()) { + throw new TypeError("cannot get rejection reason of a non-rejected promise\u000a\u000a See http://goo.gl/MqrFmX\u000a"); } - } + return this._settledValue(); }; -module.exports = ReactDOMInvalidARIAHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var isFulfilled = PromiseInspection.prototype.isFulfilled = function() { + return (this._bitField & 33554432) !== 0; +}; -/***/ }), -/* 220 */ -/***/ (function(module, exports, __webpack_require__) { +var isRejected = PromiseInspection.prototype.isRejected = function () { + return (this._bitField & 16777216) !== 0; +}; -"use strict"; +var isPending = PromiseInspection.prototype.isPending = function () { + return (this._bitField & 50397184) === 0; +}; +var isResolved = PromiseInspection.prototype.isResolved = function () { + return (this._bitField & 50331648) !== 0; +}; -Object.defineProperty(exports, "__esModule", { - value: true -}); +PromiseInspection.prototype.isCancelled = function() { + return (this._bitField & 8454144) !== 0; +}; -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +Promise.prototype.__isCancelled = function() { + return (this._bitField & 65536) === 65536; +}; -var _react = __webpack_require__(4); +Promise.prototype._isCancelled = function() { + return this._target().__isCancelled(); +}; -var _react2 = _interopRequireDefault(_react); +Promise.prototype.isCancelled = function() { + return (this._target()._bitField & 8454144) !== 0; +}; -var _reactstrap = __webpack_require__(66); +Promise.prototype.isPending = function() { + return isPending.call(this._target()); +}; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +Promise.prototype.isRejected = function() { + return isRejected.call(this._target()); +}; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +Promise.prototype.isFulfilled = function() { + return isFulfilled.call(this._target()); +}; -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +Promise.prototype.isResolved = function() { + return isResolved.call(this._target()); +}; -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +Promise.prototype.value = function() { + return value.call(this._target()); +}; -var ZNavbar = function (_React$Component) { - _inherits(ZNavbar, _React$Component); +Promise.prototype.reason = function() { + var target = this._target(); + target._unsetRejectionIsUnhandled(); + return reason.call(target); +}; - function ZNavbar(props) { - _classCallCheck(this, ZNavbar); +Promise.prototype._value = function() { + return this._settledValue(); +}; - var _this = _possibleConstructorReturn(this, (ZNavbar.__proto__ || Object.getPrototypeOf(ZNavbar)).call(this, props)); +Promise.prototype._reason = function() { + this._unsetRejectionIsUnhandled(); + return this._settledValue(); +}; - _this.toggleNavbar = _this.toggleNavbar.bind(_this); - _this.state = { - isOpen: false - }; - return _this; - } +Promise.PromiseInspection = PromiseInspection; +}; - _createClass(ZNavbar, [{ - key: 'toggleNavbar', - value: function toggleNavbar() { - this.setState({ - isOpen: !this.state.isOpen - }); +},{}],33:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL) { +var util = _dereq_("./util"); +var errorObj = util.errorObj; +var isObject = util.isObject; + +function tryConvertToPromise(obj, context) { + if (isObject(obj)) { + if (obj instanceof Promise) return obj; + var then = getThen(obj); + if (then === errorObj) { + if (context) context._pushContext(); + var ret = Promise.reject(then.e); + if (context) context._popContext(); + return ret; + } else if (typeof then === "function") { + if (isAnyBluebirdPromise(obj)) { + var ret = new Promise(INTERNAL); + obj._then( + ret._fulfill, + ret._reject, + undefined, + ret, + null + ); + return ret; + } + return doThenable(obj, then, context); + } } - }, { - key: 'render', - value: function render() { - return _react2.default.createElement( - _reactstrap.Navbar, - { color: 'faded', light: true, toggleable: true }, - _react2.default.createElement(_reactstrap.NavbarToggler, { right: true, onClick: this.toggleNavbar }), - _react2.default.createElement( - _reactstrap.NavbarBrand, - { href: '/' }, - 'myzenwallet.io' - ), - _react2.default.createElement( - _reactstrap.Collapse, - { isOpen: this.state.isOpen, navbar: true }, - _react2.default.createElement( - _reactstrap.Nav, - { className: 'ml-auto', navbar: true }, - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: 'http://getzen.cash' }, - 'FREE ZEN' - ) - ), - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: '/faq.html' }, - 'FAQ' - ) - ), - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: '/guide.html' }, - 'GETTING STARTED' - ) - ) - ) - ) - ); + return obj; +} + +function doGetThen(obj) { + return obj.then; +} + +function getThen(obj) { + try { + return doGetThen(obj); + } catch (e) { + errorObj.e = e; + return errorObj; + } +} + +var hasProp = {}.hasOwnProperty; +function isAnyBluebirdPromise(obj) { + try { + return hasProp.call(obj, "_promise0"); + } catch (e) { + return false; + } +} + +function doThenable(x, then, context) { + var promise = new Promise(INTERNAL); + var ret = promise; + if (context) context._pushContext(); + promise._captureStackTrace(); + if (context) context._popContext(); + var synchronous = true; + var result = util.tryCatch(then).call(x, resolve, reject); + synchronous = false; + + if (promise && result === errorObj) { + promise._rejectCallback(result.e, true, true); + promise = null; } - }]); - return ZNavbar; -}(_react2.default.Component); + function resolve(value) { + if (!promise) return; + promise._resolveCallback(value); + promise = null; + } -exports.default = ZNavbar; + function reject(reason) { + if (!promise) return; + promise._rejectCallback(reason, synchronous, true); + promise = null; + } + return ret; +} -/***/ }), -/* 221 */ -/***/ (function(module, exports, __webpack_require__) { +return tryConvertToPromise; +}; +},{"./util":36}],34:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ - +module.exports = function(Promise, INTERNAL, debug) { +var util = _dereq_("./util"); +var TimeoutError = Promise.TimeoutError; +function HandleWrapper(handle) { + this.handle = handle; +} -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); -var ReactPropTypesSecret = __webpack_require__(49); +HandleWrapper.prototype._resultCancelled = function() { + clearTimeout(this.handle); +}; -module.exports = function() { - function shim(props, propName, componentName, location, propFullName, secret) { - if (secret === ReactPropTypesSecret) { - // It is still safe when called from React. - return; +var afterValue = function(value) { return delay(+this).thenReturn(value); }; +var delay = Promise.delay = function (ms, value) { + var ret; + var handle; + if (value !== undefined) { + ret = Promise.resolve(value) + ._then(afterValue, null, null, ms, undefined); + if (debug.cancellation() && value instanceof Promise) { + ret._setOnCancel(value); + } + } else { + ret = new Promise(INTERNAL); + handle = setTimeout(function() { ret._fulfill(); }, +ms); + if (debug.cancellation()) { + ret._setOnCancel(new HandleWrapper(handle)); + } + ret._captureStackTrace(); } - invariant( - false, - 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + - 'Use PropTypes.checkPropTypes() to call them. ' + - 'Read more at http://fb.me/use-check-prop-types' - ); - }; - shim.isRequired = shim; - function getShim() { - return shim; - }; - // Important! - // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`. - var ReactPropTypes = { - array: shim, - bool: shim, - func: shim, - number: shim, - object: shim, - string: shim, - symbol: shim, + ret._setAsyncGuaranteed(); + return ret; +}; - any: shim, - arrayOf: getShim, - element: shim, - instanceOf: getShim, - node: shim, - objectOf: getShim, - oneOf: getShim, - oneOfType: getShim, - shape: getShim - }; +Promise.prototype.delay = function (ms) { + return delay(ms, this); +}; - ReactPropTypes.checkPropTypes = emptyFunction; - ReactPropTypes.PropTypes = ReactPropTypes; +var afterTimeout = function (promise, message, parent) { + var err; + if (typeof message !== "string") { + if (message instanceof Error) { + err = message; + } else { + err = new TimeoutError("operation timed out"); + } + } else { + err = new TimeoutError(message); + } + util.markAsOriginatingFromRejection(err); + promise._attachExtraTrace(err); + promise._reject(err); - return ReactPropTypes; + if (parent != null) { + parent.cancel(); + } }; +function successClear(value) { + clearTimeout(this.handle); + return value; +} -/***/ }), -/* 222 */ -/***/ (function(module, exports) { +function failureClear(reason) { + clearTimeout(this.handle); + throw reason; +} -/** - * lodash 3.0.2 (Custom Build) <https://lodash.com/> - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license <https://lodash.com/license> - */ +Promise.prototype.timeout = function (ms, message) { + ms = +ms; + var ret, parent; -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(1); - * // => false - */ -function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} + var handleWrapper = new HandleWrapper(setTimeout(function timeoutTimeout() { + if (ret.isPending()) { + afterTimeout(ret, message, parent); + } + }, ms)); -module.exports = isObject; + if (debug.cancellation()) { + parent = this.then(); + ret = parent._then(successClear, failureClear, + undefined, handleWrapper, undefined); + ret._setOnCancel(handleWrapper); + } else { + ret = this._then(successClear, failureClear, + undefined, handleWrapper, undefined); + } + return ret; +}; -/***/ }), -/* 223 */ -/***/ (function(module, exports) { +}; -/** - * lodash 3.0.8 (Custom Build) <https://lodash.com/> - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation <http://dojofoundation.org/> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license <https://lodash.com/license> - */ +},{"./util":36}],35:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function (Promise, apiRejection, tryConvertToPromise, + createContext, INTERNAL, debug) { + var util = _dereq_("./util"); + var TypeError = _dereq_("./errors").TypeError; + var inherits = _dereq_("./util").inherits; + var errorObj = util.errorObj; + var tryCatch = util.tryCatch; + var NULL = {}; + + function thrower(e) { + setTimeout(function(){throw e;}, 0); + } + + function castPreservingDisposable(thenable) { + var maybePromise = tryConvertToPromise(thenable); + if (maybePromise !== thenable && + typeof thenable._isDisposable === "function" && + typeof thenable._getDisposer === "function" && + thenable._isDisposable()) { + maybePromise._setDisposable(thenable._getDisposer()); + } + return maybePromise; + } + function dispose(resources, inspection) { + var i = 0; + var len = resources.length; + var ret = new Promise(INTERNAL); + function iterator() { + if (i >= len) return ret._fulfill(); + var maybePromise = castPreservingDisposable(resources[i++]); + if (maybePromise instanceof Promise && + maybePromise._isDisposable()) { + try { + maybePromise = tryConvertToPromise( + maybePromise._getDisposer().tryDispose(inspection), + resources.promise); + } catch (e) { + return thrower(e); + } + if (maybePromise instanceof Promise) { + return maybePromise._then(iterator, thrower, + null, null, null); + } + } + iterator(); + } + iterator(); + return ret; + } -/** `Object#toString` result references. */ -var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + function Disposer(data, promise, context) { + this._data = data; + this._promise = promise; + this._context = context; + } -/** Used for built-in method references. */ -var objectProto = Object.prototype; + Disposer.prototype.data = function () { + return this._data; + }; -/** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; + Disposer.prototype.promise = function () { + return this._promise; + }; -/** - * Checks if `value` is classified as a `Function` object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false - */ -function isFunction(value) { - // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 8 which returns 'object' for typed array constructors, and - // PhantomJS 1.9 which returns 'function' for `NodeList` instances. - var tag = isObject(value) ? objectToString.call(value) : ''; - return tag == funcTag || tag == genTag; -} + Disposer.prototype.resource = function () { + if (this.promise().isFulfilled()) { + return this.promise().value(); + } + return NULL; + }; -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} + Disposer.prototype.tryDispose = function(inspection) { + var resource = this.resource(); + var context = this._context; + if (context !== undefined) context._pushContext(); + var ret = resource !== NULL + ? this.doDispose(resource, inspection) : null; + if (context !== undefined) context._popContext(); + this._promise._unsetDisposable(); + this._data = null; + return ret; + }; -module.exports = isFunction; + Disposer.isDisposer = function (d) { + return (d != null && + typeof d.resource === "function" && + typeof d.tryDispose === "function"); + }; + function FunctionDisposer(fn, promise, context) { + this.constructor$(fn, promise, context); + } + inherits(FunctionDisposer, Disposer); -/***/ }), -/* 224 */ -/***/ (function(module, exports, __webpack_require__) { + FunctionDisposer.prototype.doDispose = function (resource, inspection) { + var fn = this.data(); + return fn.call(resource, resource, inspection); + }; -var require;var require;/*! tether 1.3.4 */ -(function(f){if(true){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Tether = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ -'use strict'; + function maybeUnwrapDisposer(value) { + if (Disposer.isDisposer(value)) { + this.resources[this.index]._setDisposable(value); + return value.promise(); + } + return value; + } -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } + function ResourceList(length) { + this.length = length; + this.promise = null; + this[length-1] = null; + } -var _utils = require('./utils'); + ResourceList.prototype._resultCancelled = function() { + var len = this.length; + for (var i = 0; i < len; ++i) { + var item = this[i]; + if (item instanceof Promise) { + item.cancel(); + } + } + }; -var _utils2 = _interopRequireDefault(_utils); + Promise.using = function () { + var len = arguments.length; + if (len < 2) return apiRejection( + "you must pass at least 2 arguments to Promise.using"); + var fn = arguments[len - 1]; + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + var input; + var spreadArgs = true; + if (len === 2 && Array.isArray(arguments[0])) { + input = arguments[0]; + len = input.length; + spreadArgs = false; + } else { + input = arguments; + len--; + } + var resources = new ResourceList(len); + for (var i = 0; i < len; ++i) { + var resource = input[i]; + if (Disposer.isDisposer(resource)) { + var disposer = resource; + resource = resource.promise(); + resource._setDisposable(disposer); + } else { + var maybePromise = tryConvertToPromise(resource); + if (maybePromise instanceof Promise) { + resource = + maybePromise._then(maybeUnwrapDisposer, null, null, { + resources: resources, + index: i + }, undefined); + } + } + resources[i] = resource; + } -var _TetherBase$Utils = _utils2['default'].Utils; -var getBounds = _TetherBase$Utils.getBounds; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; + var reflectedResources = new Array(resources.length); + for (var i = 0; i < reflectedResources.length; ++i) { + reflectedResources[i] = Promise.resolve(resources[i]).reflect(); + } -_utils2['default'].modules.push({ - position: function position(_ref) { - var _this = this; + var resultPromise = Promise.all(reflectedResources) + .then(function(inspections) { + for (var i = 0; i < inspections.length; ++i) { + var inspection = inspections[i]; + if (inspection.isRejected()) { + errorObj.e = inspection.error(); + return errorObj; + } else if (!inspection.isFulfilled()) { + resultPromise.cancel(); + return; + } + inspections[i] = inspection.value(); + } + promise._pushContext(); + + fn = tryCatch(fn); + var ret = spreadArgs + ? fn.apply(undefined, inspections) : fn(inspections); + var promiseCreated = promise._popContext(); + debug.checkForgottenReturns( + ret, promiseCreated, "Promise.using", promise); + return ret; + }); - var top = _ref.top; - var left = _ref.left; + var promise = resultPromise.lastly(function() { + var inspection = new Promise.PromiseInspection(resultPromise); + return dispose(resources, inspection); + }); + resources.promise = promise; + promise._setOnCancel(resources); + return promise; + }; - var _cache = this.cache('element-bounds', function () { - return getBounds(_this.element); - }); + Promise.prototype._setDisposable = function (disposer) { + this._bitField = this._bitField | 131072; + this._disposer = disposer; + }; - var height = _cache.height; - var width = _cache.width; + Promise.prototype._isDisposable = function () { + return (this._bitField & 131072) > 0; + }; - var targetPos = this.getTargetBounds(); + Promise.prototype._getDisposer = function () { + return this._disposer; + }; - var bottom = top + height; - var right = left + width; + Promise.prototype._unsetDisposable = function () { + this._bitField = this._bitField & (~131072); + this._disposer = undefined; + }; - var abutted = []; - if (top <= targetPos.bottom && bottom >= targetPos.top) { - ['left', 'right'].forEach(function (side) { - var targetPosSide = targetPos[side]; - if (targetPosSide === left || targetPosSide === right) { - abutted.push(side); + Promise.prototype.disposer = function (fn) { + if (typeof fn === "function") { + return new FunctionDisposer(fn, this, createContext()); } - }); - } + throw new TypeError(); + }; - if (left <= targetPos.right && right >= targetPos.left) { - ['top', 'bottom'].forEach(function (side) { - var targetPosSide = targetPos[side]; - if (targetPosSide === top || targetPosSide === bottom) { - abutted.push(side); - } - }); - } +}; - var allClasses = []; - var addClasses = []; +},{"./errors":12,"./util":36}],36:[function(_dereq_,module,exports){ +"use strict"; +var es5 = _dereq_("./es5"); +var canEvaluate = typeof navigator == "undefined"; - var sides = ['left', 'top', 'right', 'bottom']; - allClasses.push(this.getClass('abutted')); - sides.forEach(function (side) { - allClasses.push(_this.getClass('abutted') + '-' + side); - }); +var errorObj = {e: {}}; +var tryCatchTarget; +var globalObject = typeof self !== "undefined" ? self : + typeof window !== "undefined" ? window : + typeof global !== "undefined" ? global : + this !== undefined ? this : null; - if (abutted.length) { - addClasses.push(this.getClass('abutted')); +function tryCatcher() { + try { + var target = tryCatchTarget; + tryCatchTarget = null; + return target.apply(this, arguments); + } catch (e) { + errorObj.e = e; + return errorObj; } +} +function tryCatch(fn) { + tryCatchTarget = fn; + return tryCatcher; +} - abutted.forEach(function (side) { - addClasses.push(_this.getClass('abutted') + '-' + side); - }); +var inherits = function(Child, Parent) { + var hasProp = {}.hasOwnProperty; + + function T() { + this.constructor = Child; + this.constructor$ = Parent; + for (var propertyName in Parent.prototype) { + if (hasProp.call(Parent.prototype, propertyName) && + propertyName.charAt(propertyName.length-1) !== "$" + ) { + this[propertyName + "$"] = Parent.prototype[propertyName]; + } + } + } + T.prototype = Parent.prototype; + Child.prototype = new T(); + return Child.prototype; +}; - defer(function () { - if (!(_this.options.addTargetClasses === false)) { - updateClasses(_this.target, addClasses, allClasses); - } - updateClasses(_this.element, addClasses, allClasses); - }); - return true; - } -}); +function isPrimitive(val) { + return val == null || val === true || val === false || + typeof val === "string" || typeof val === "number"; -},{"./utils":5}],2:[function(require,module,exports){ -'use strict'; +} -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +function isObject(value) { + return typeof value === "function" || + typeof value === "object" && value !== null; +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +function maybeWrapAsError(maybeError) { + if (!isPrimitive(maybeError)) return maybeError; -var _utils = require('./utils'); + return new Error(safeToString(maybeError)); +} -var _utils2 = _interopRequireDefault(_utils); +function withAppended(target, appendee) { + var len = target.length; + var ret = new Array(len + 1); + var i; + for (i = 0; i < len; ++i) { + ret[i] = target[i]; + } + ret[i] = appendee; + return ret; +} -var _TetherBase$Utils = _utils2['default'].Utils; -var getBounds = _TetherBase$Utils.getBounds; -var extend = _TetherBase$Utils.extend; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; +function getDataPropertyOrDefault(obj, key, defaultValue) { + if (es5.isES5) { + var desc = Object.getOwnPropertyDescriptor(obj, key); -var BOUNDS_FORMAT = ['left', 'top', 'right', 'bottom']; + if (desc != null) { + return desc.get == null && desc.set == null + ? desc.value + : defaultValue; + } + } else { + return {}.hasOwnProperty.call(obj, key) ? obj[key] : undefined; + } +} -function getBoundingRect(tether, to) { - if (to === 'scrollParent') { - to = tether.scrollParents[0]; - } else if (to === 'window') { - to = [pageXOffset, pageYOffset, innerWidth + pageXOffset, innerHeight + pageYOffset]; - } +function notEnumerableProp(obj, name, value) { + if (isPrimitive(obj)) return obj; + var descriptor = { + value: value, + configurable: true, + enumerable: false, + writable: true + }; + es5.defineProperty(obj, name, descriptor); + return obj; +} - if (to === document) { - to = to.documentElement; - } +function thrower(r) { + throw r; +} - if (typeof to.nodeType !== 'undefined') { - (function () { - var node = to; - var size = getBounds(to); - var pos = size; - var style = getComputedStyle(to); +var inheritedDataKeys = (function() { + var excludedPrototypes = [ + Array.prototype, + Object.prototype, + Function.prototype + ]; + + var isExcludedProto = function(val) { + for (var i = 0; i < excludedPrototypes.length; ++i) { + if (excludedPrototypes[i] === val) { + return true; + } + } + return false; + }; - to = [pos.left, pos.top, size.width + pos.left, size.height + pos.top]; + if (es5.isES5) { + var getKeys = Object.getOwnPropertyNames; + return function(obj) { + var ret = []; + var visitedKeys = Object.create(null); + while (obj != null && !isExcludedProto(obj)) { + var keys; + try { + keys = getKeys(obj); + } catch (e) { + return ret; + } + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + if (visitedKeys[key]) continue; + visitedKeys[key] = true; + var desc = Object.getOwnPropertyDescriptor(obj, key); + if (desc != null && desc.get == null && desc.set == null) { + ret.push(key); + } + } + obj = es5.getPrototypeOf(obj); + } + return ret; + }; + } else { + var hasProp = {}.hasOwnProperty; + return function(obj) { + if (isExcludedProto(obj)) return []; + var ret = []; + + /*jshint forin:false */ + enumeration: for (var key in obj) { + if (hasProp.call(obj, key)) { + ret.push(key); + } else { + for (var i = 0; i < excludedPrototypes.length; ++i) { + if (hasProp.call(excludedPrototypes[i], key)) { + continue enumeration; + } + } + ret.push(key); + } + } + return ret; + }; + } - // Account any parent Frames scroll offset - if (node.ownerDocument !== document) { - var win = node.ownerDocument.defaultView; - to[0] += win.pageXOffset; - to[1] += win.pageYOffset; - to[2] += win.pageXOffset; - to[3] += win.pageYOffset; - } +})(); - BOUNDS_FORMAT.forEach(function (side, i) { - side = side[0].toUpperCase() + side.substr(1); - if (side === 'Top' || side === 'Left') { - to[i] += parseFloat(style['border' + side + 'Width']); - } else { - to[i] -= parseFloat(style['border' + side + 'Width']); +var thisAssignmentPattern = /this\s*\.\s*\S+\s*=/; +function isClass(fn) { + try { + if (typeof fn === "function") { + var keys = es5.names(fn.prototype); + + var hasMethods = es5.isES5 && keys.length > 1; + var hasMethodsOtherThanConstructor = keys.length > 0 && + !(keys.length === 1 && keys[0] === "constructor"); + var hasThisAssignmentAndStaticMethods = + thisAssignmentPattern.test(fn + "") && es5.names(fn).length > 0; + + if (hasMethods || hasMethodsOtherThanConstructor || + hasThisAssignmentAndStaticMethods) { + return true; + } } - }); - })(); - } + return false; + } catch (e) { + return false; + } +} - return to; +function toFastProperties(obj) { + /*jshint -W027,-W055,-W031*/ + function FakeConstructor() {} + FakeConstructor.prototype = obj; + var l = 8; + while (l--) new FakeConstructor(); + return obj; + eval(obj); } -_utils2['default'].modules.push({ - position: function position(_ref) { - var _this = this; +var rident = /^[a-z$_][a-z$_0-9]*$/i; +function isIdentifier(str) { + return rident.test(str); +} - var top = _ref.top; - var left = _ref.left; - var targetAttachment = _ref.targetAttachment; +function filledRange(count, prefix, suffix) { + var ret = new Array(count); + for(var i = 0; i < count; ++i) { + ret[i] = prefix + i + suffix; + } + return ret; +} - if (!this.options.constraints) { - return true; +function safeToString(obj) { + try { + return obj + ""; + } catch (e) { + return "[no string representation]"; } +} - var _cache = this.cache('element-bounds', function () { - return getBounds(_this.element); - }); +function isError(obj) { + return obj !== null && + typeof obj === "object" && + typeof obj.message === "string" && + typeof obj.name === "string"; +} - var height = _cache.height; - var width = _cache.width; +function markAsOriginatingFromRejection(e) { + try { + notEnumerableProp(e, "isOperational", true); + } + catch(ignore) {} +} - if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { - var _lastSize = this.lastSize; +function originatesFromRejection(e) { + if (e == null) return false; + return ((e instanceof Error["__BluebirdErrorTypes__"].OperationalError) || + e["isOperational"] === true); +} - // Handle the item getting hidden as a result of our positioning without glitching - // the classes in and out - width = _lastSize.width; - height = _lastSize.height; +function canAttachTrace(obj) { + return isError(obj) && es5.propertyIsWritable(obj, "stack"); +} + +var ensureErrorObject = (function() { + if (!("stack" in new Error())) { + return function(value) { + if (canAttachTrace(value)) return value; + try {throw new Error(safeToString(value));} + catch(err) {return err;} + }; + } else { + return function(value) { + if (canAttachTrace(value)) return value; + return new Error(safeToString(value)); + }; } +})(); - var targetSize = this.cache('target-bounds', function () { - return _this.getTargetBounds(); - }); +function classString(obj) { + return {}.toString.call(obj); +} - var targetHeight = targetSize.height; - var targetWidth = targetSize.width; +function copyDescriptors(from, to, filter) { + var keys = es5.names(from); + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + if (filter(key)) { + try { + es5.defineProperty(to, key, es5.getDescriptor(from, key)); + } catch (ignore) {} + } + } +} - var allClasses = [this.getClass('pinned'), this.getClass('out-of-bounds')]; +var asArray = function(v) { + if (es5.isArray(v)) { + return v; + } + return null; +}; - this.options.constraints.forEach(function (constraint) { - var outOfBoundsClass = constraint.outOfBoundsClass; - var pinnedClass = constraint.pinnedClass; +if (typeof Symbol !== "undefined" && Symbol.iterator) { + var ArrayFrom = typeof Array.from === "function" ? function(v) { + return Array.from(v); + } : function(v) { + var ret = []; + var it = v[Symbol.iterator](); + var itResult; + while (!((itResult = it.next()).done)) { + ret.push(itResult.value); + } + return ret; + }; - if (outOfBoundsClass) { - allClasses.push(outOfBoundsClass); - } - if (pinnedClass) { - allClasses.push(pinnedClass); - } - }); + asArray = function(v) { + if (es5.isArray(v)) { + return v; + } else if (v != null && typeof v[Symbol.iterator] === "function") { + return ArrayFrom(v); + } + return null; + }; +} - allClasses.forEach(function (cls) { - ['left', 'top', 'right', 'bottom'].forEach(function (side) { - allClasses.push(cls + '-' + side); - }); - }); +var isNode = typeof process !== "undefined" && + classString(process).toLowerCase() === "[object process]"; - var addClasses = []; +var hasEnvVariables = typeof process !== "undefined" && + typeof process.env !== "undefined"; - var tAttachment = extend({}, targetAttachment); - var eAttachment = extend({}, this.attachment); +function env(key) { + return hasEnvVariables ? process.env[key] : undefined; +} - this.options.constraints.forEach(function (constraint) { - var to = constraint.to; - var attachment = constraint.attachment; - var pin = constraint.pin; +function getNativePromise() { + if (typeof Promise === "function") { + try { + var promise = new Promise(function(){}); + if ({}.toString.call(promise) === "[object Promise]") { + return Promise; + } + } catch (e) {} + } +} - if (typeof attachment === 'undefined') { - attachment = ''; - } +function domainBind(self, cb) { + return self.bind(cb); +} - var changeAttachX = undefined, - changeAttachY = undefined; - if (attachment.indexOf(' ') >= 0) { - var _attachment$split = attachment.split(' '); +var ret = { + isClass: isClass, + isIdentifier: isIdentifier, + inheritedDataKeys: inheritedDataKeys, + getDataPropertyOrDefault: getDataPropertyOrDefault, + thrower: thrower, + isArray: es5.isArray, + asArray: asArray, + notEnumerableProp: notEnumerableProp, + isPrimitive: isPrimitive, + isObject: isObject, + isError: isError, + canEvaluate: canEvaluate, + errorObj: errorObj, + tryCatch: tryCatch, + inherits: inherits, + withAppended: withAppended, + maybeWrapAsError: maybeWrapAsError, + toFastProperties: toFastProperties, + filledRange: filledRange, + toString: safeToString, + canAttachTrace: canAttachTrace, + ensureErrorObject: ensureErrorObject, + originatesFromRejection: originatesFromRejection, + markAsOriginatingFromRejection: markAsOriginatingFromRejection, + classString: classString, + copyDescriptors: copyDescriptors, + hasDevTools: typeof chrome !== "undefined" && chrome && + typeof chrome.loadTimes === "function", + isNode: isNode, + hasEnvVariables: hasEnvVariables, + env: env, + global: globalObject, + getNativePromise: getNativePromise, + domainBind: domainBind +}; +ret.isRecentNode = ret.isNode && (function() { + var version = process.versions.node.split(".").map(Number); + return (version[0] === 0 && version[1] > 10) || (version[0] > 0); +})(); - var _attachment$split2 = _slicedToArray(_attachment$split, 2); +if (ret.isNode) ret.toFastProperties(process); - changeAttachY = _attachment$split2[0]; - changeAttachX = _attachment$split2[1]; - } else { - changeAttachX = changeAttachY = attachment; - } +try {throw new Error(); } catch (e) {ret.lastLineError = e;} +module.exports = ret; - var bounds = getBoundingRect(_this, to); +},{"./es5":13}]},{},[4])(4) +}); ;if (typeof window !== 'undefined' && window !== null) { window.P = window.Promise; } else if (typeof self !== 'undefined' && self !== null) { self.P = self.Promise; } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0), __webpack_require__(24), __webpack_require__(164).setImmediate)) - if (changeAttachY === 'target' || changeAttachY === 'both') { - if (top < bounds[1] && tAttachment.top === 'top') { - top += targetHeight; - tAttachment.top = 'bottom'; - } +/***/ }), +/* 464 */ +/***/ (function(module, exports, __webpack_require__) { - if (top + height > bounds[3] && tAttachment.top === 'bottom') { - top -= targetHeight; - tAttachment.top = 'top'; - } - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { + +var bitcoinjs = __webpack_require__(200); +var bip32utils = __webpack_require__(495); +var zencashjs = __webpack_require__(160); +var bs58check = __webpack_require__(33); + +// Hierarchical Deterministic wallet +function phraseToHDWallet(phraseStr) { + // Seed key, make it fucking strong + // phraseStr: string + var seedHex = Buffer.from(phraseStr).toString('hex'); + + // chains + var hdNode = bitcoinjs.HDNode.fromSeedHex(seedHex); + var chain = new bip32utils.Chain(hdNode); + + // Creates 42 address from the same chain + for (var k = 0; k < 42; k++) { + chain.next(); + } + + // Get private keys from them + var privateKeys = chain.getAll().map(function (x) { + return chain.derive(x).keyPair.toWIF(); + }); + + return privateKeys; +} - if (changeAttachY === 'together') { - if (tAttachment.top === 'top') { - if (eAttachment.top === 'bottom' && top < bounds[1]) { - top += targetHeight; - tAttachment.top = 'bottom'; +module.exports = { + phraseToHDWallet: phraseToHDWallet +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - top += height; - eAttachment.top = 'top'; - } else if (eAttachment.top === 'top' && top + height > bounds[3] && top - (height - targetHeight) >= bounds[1]) { - top -= height - targetHeight; - tAttachment.top = 'bottom'; +/***/ }), +/* 465 */ +/***/ (function(module, exports, __webpack_require__) { - eAttachment.top = 'bottom'; - } - } +var Buffer = __webpack_require__(7).Buffer +var bcrypto = __webpack_require__(44) +var fastMerkleRoot = __webpack_require__(466) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var varuint = __webpack_require__(73) + +var Transaction = __webpack_require__(112) + +function Block () { + this.version = 1 + this.prevHash = null + this.merkleRoot = null + this.timestamp = 0 + this.bits = 0 + this.nonce = 0 +} - if (tAttachment.top === 'bottom') { - if (eAttachment.top === 'top' && top + height > bounds[3]) { - top -= targetHeight; - tAttachment.top = 'top'; +Block.fromBuffer = function (buffer) { + if (buffer.length < 80) throw new Error('Buffer too small (< 80 bytes)') - top -= height; - eAttachment.top = 'bottom'; - } else if (eAttachment.top === 'bottom' && top < bounds[1] && top + (height * 2 - targetHeight) <= bounds[3]) { - top += height - targetHeight; - tAttachment.top = 'top'; + var offset = 0 + function readSlice (n) { + offset += n + return buffer.slice(offset - n, offset) + } - eAttachment.top = 'top'; - } - } + function readUInt32 () { + var i = buffer.readUInt32LE(offset) + offset += 4 + return i + } - if (tAttachment.top === 'middle') { - if (top + height > bounds[3] && eAttachment.top === 'top') { - top -= height; - eAttachment.top = 'bottom'; - } else if (top < bounds[1] && eAttachment.top === 'bottom') { - top += height; - eAttachment.top = 'top'; - } - } - } + function readInt32 () { + var i = buffer.readInt32LE(offset) + offset += 4 + return i + } - if (changeAttachX === 'target' || changeAttachX === 'both') { - if (left < bounds[0] && tAttachment.left === 'left') { - left += targetWidth; - tAttachment.left = 'right'; - } + var block = new Block() + block.version = readInt32() + block.prevHash = readSlice(32) + block.merkleRoot = readSlice(32) + block.timestamp = readUInt32() + block.bits = readUInt32() + block.nonce = readUInt32() - if (left + width > bounds[2] && tAttachment.left === 'right') { - left -= targetWidth; - tAttachment.left = 'left'; - } - } + if (buffer.length === 80) return block - if (changeAttachX === 'together') { - if (left < bounds[0] && tAttachment.left === 'left') { - if (eAttachment.left === 'right') { - left += targetWidth; - tAttachment.left = 'right'; + function readVarInt () { + var vi = varuint.decode(buffer, offset) + offset += varuint.decode.bytes + return vi + } - left += width; - eAttachment.left = 'left'; - } else if (eAttachment.left === 'left') { - left += targetWidth; - tAttachment.left = 'right'; + function readTransaction () { + var tx = Transaction.fromBuffer(buffer.slice(offset), true) + offset += tx.byteLength() + return tx + } - left -= width; - eAttachment.left = 'right'; - } - } else if (left + width > bounds[2] && tAttachment.left === 'right') { - if (eAttachment.left === 'left') { - left -= targetWidth; - tAttachment.left = 'left'; + var nTransactions = readVarInt() + block.transactions = [] - left -= width; - eAttachment.left = 'right'; - } else if (eAttachment.left === 'right') { - left -= targetWidth; - tAttachment.left = 'left'; + for (var i = 0; i < nTransactions; ++i) { + var tx = readTransaction() + block.transactions.push(tx) + } - left += width; - eAttachment.left = 'left'; - } - } else if (tAttachment.left === 'center') { - if (left + width > bounds[2] && eAttachment.left === 'left') { - left -= width; - eAttachment.left = 'right'; - } else if (left < bounds[0] && eAttachment.left === 'right') { - left += width; - eAttachment.left = 'left'; - } - } - } + return block +} - if (changeAttachY === 'element' || changeAttachY === 'both') { - if (top < bounds[1] && eAttachment.top === 'bottom') { - top += height; - eAttachment.top = 'top'; - } +Block.prototype.byteLength = function (headersOnly) { + if (headersOnly || !this.transactions) return 80 - if (top + height > bounds[3] && eAttachment.top === 'top') { - top -= height; - eAttachment.top = 'bottom'; - } - } + return 80 + varuint.encodingLength(this.transactions.length) + this.transactions.reduce(function (a, x) { + return a + x.byteLength() + }, 0) +} - if (changeAttachX === 'element' || changeAttachX === 'both') { - if (left < bounds[0]) { - if (eAttachment.left === 'right') { - left += width; - eAttachment.left = 'left'; - } else if (eAttachment.left === 'center') { - left += width / 2; - eAttachment.left = 'left'; - } - } +Block.fromHex = function (hex) { + return Block.fromBuffer(Buffer.from(hex, 'hex')) +} - if (left + width > bounds[2]) { - if (eAttachment.left === 'left') { - left -= width; - eAttachment.left = 'right'; - } else if (eAttachment.left === 'center') { - left -= width / 2; - eAttachment.left = 'right'; - } - } - } +Block.prototype.getHash = function () { + return bcrypto.hash256(this.toBuffer(true)) +} - if (typeof pin === 'string') { - pin = pin.split(',').map(function (p) { - return p.trim(); - }); - } else if (pin === true) { - pin = ['top', 'left', 'right', 'bottom']; - } +Block.prototype.getId = function () { + return this.getHash().reverse().toString('hex') +} - pin = pin || []; +Block.prototype.getUTCDate = function () { + var date = new Date(0) // epoch + date.setUTCSeconds(this.timestamp) - var pinned = []; - var oob = []; + return date +} - if (top < bounds[1]) { - if (pin.indexOf('top') >= 0) { - top = bounds[1]; - pinned.push('top'); - } else { - oob.push('top'); - } - } +// TODO: buffer, offset compatibility +Block.prototype.toBuffer = function (headersOnly) { + var buffer = Buffer.allocUnsafe(this.byteLength(headersOnly)) - if (top + height > bounds[3]) { - if (pin.indexOf('bottom') >= 0) { - top = bounds[3] - height; - pinned.push('bottom'); - } else { - oob.push('bottom'); - } - } + var offset = 0 + function writeSlice (slice) { + slice.copy(buffer, offset) + offset += slice.length + } - if (left < bounds[0]) { - if (pin.indexOf('left') >= 0) { - left = bounds[0]; - pinned.push('left'); - } else { - oob.push('left'); - } - } + function writeInt32 (i) { + buffer.writeInt32LE(i, offset) + offset += 4 + } + function writeUInt32 (i) { + buffer.writeUInt32LE(i, offset) + offset += 4 + } - if (left + width > bounds[2]) { - if (pin.indexOf('right') >= 0) { - left = bounds[2] - width; - pinned.push('right'); - } else { - oob.push('right'); - } - } + writeInt32(this.version) + writeSlice(this.prevHash) + writeSlice(this.merkleRoot) + writeUInt32(this.timestamp) + writeUInt32(this.bits) + writeUInt32(this.nonce) - if (pinned.length) { - (function () { - var pinnedClass = undefined; - if (typeof _this.options.pinnedClass !== 'undefined') { - pinnedClass = _this.options.pinnedClass; - } else { - pinnedClass = _this.getClass('pinned'); - } + if (headersOnly || !this.transactions) return buffer - addClasses.push(pinnedClass); - pinned.forEach(function (side) { - addClasses.push(pinnedClass + '-' + side); - }); - })(); - } + varuint.encode(this.transactions.length, buffer, offset) + offset += varuint.encode.bytes - if (oob.length) { - (function () { - var oobClass = undefined; - if (typeof _this.options.outOfBoundsClass !== 'undefined') { - oobClass = _this.options.outOfBoundsClass; - } else { - oobClass = _this.getClass('out-of-bounds'); - } + this.transactions.forEach(function (tx) { + var txSize = tx.byteLength() // TODO: extract from toBuffer? + tx.toBuffer(buffer, offset) + offset += txSize + }) - addClasses.push(oobClass); - oob.forEach(function (side) { - addClasses.push(oobClass + '-' + side); - }); - })(); - } + return buffer +} - if (pinned.indexOf('left') >= 0 || pinned.indexOf('right') >= 0) { - eAttachment.left = tAttachment.left = false; - } - if (pinned.indexOf('top') >= 0 || pinned.indexOf('bottom') >= 0) { - eAttachment.top = tAttachment.top = false; - } +Block.prototype.toHex = function (headersOnly) { + return this.toBuffer(headersOnly).toString('hex') +} - if (tAttachment.top !== targetAttachment.top || tAttachment.left !== targetAttachment.left || eAttachment.top !== _this.attachment.top || eAttachment.left !== _this.attachment.left) { - _this.updateAttachClasses(eAttachment, tAttachment); - _this.trigger('update', { - attachment: eAttachment, - targetAttachment: tAttachment - }); - } - }); +Block.calculateTarget = function (bits) { + var exponent = ((bits & 0xff000000) >> 24) - 3 + var mantissa = bits & 0x007fffff + var target = Buffer.alloc(32, 0) + target.writeUInt32BE(mantissa, 28 - exponent) + return target +} - defer(function () { - if (!(_this.options.addTargetClasses === false)) { - updateClasses(_this.target, addClasses, allClasses); - } - updateClasses(_this.element, addClasses, allClasses); - }); +Block.calculateMerkleRoot = function (transactions) { + typeforce([{ getHash: types.Function }], transactions) + if (transactions.length === 0) throw TypeError('Cannot compute merkle root for zero transactions') - return { top: top, left: left }; - } -}); + var hashes = transactions.map(function (transaction) { + return transaction.getHash() + }) -},{"./utils":5}],3:[function(require,module,exports){ -'use strict'; + return fastMerkleRoot(hashes, bcrypto.hash256) +} -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +Block.prototype.checkMerkleRoot = function () { + if (!this.transactions) return false -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } + var actualMerkleRoot = Block.calculateMerkleRoot(this.transactions) + return this.merkleRoot.compare(actualMerkleRoot) === 0 +} -var _utils = require('./utils'); +Block.prototype.checkProofOfWork = function () { + var hash = this.getHash().reverse() + var target = Block.calculateTarget(this.bits) -var _utils2 = _interopRequireDefault(_utils); + return hash.compare(target) <= 0 +} -_utils2['default'].modules.push({ - position: function position(_ref) { - var top = _ref.top; - var left = _ref.left; +module.exports = Block - if (!this.options.shift) { - return; - } - var shift = this.options.shift; - if (typeof this.options.shift === 'function') { - shift = this.options.shift.call(this, { top: top, left: left }); - } +/***/ }), +/* 466 */ +/***/ (function(module, exports, __webpack_require__) { - var shiftTop = undefined, - shiftLeft = undefined; - if (typeof shift === 'string') { - shift = shift.split(' '); - shift[1] = shift[1] || shift[0]; +/* WEBPACK VAR INJECTION */(function(Buffer) {// constant-space merkle root calculation algorithm +module.exports = function fastRoot (values, digestFn) { + if (!Array.isArray(values)) throw TypeError('Expected values Array') + if (typeof digestFn !== 'function') throw TypeError('Expected digest Function') - var _shift = shift; + var length = values.length + var results = values.concat() - var _shift2 = _slicedToArray(_shift, 2); + while (length > 1) { + var j = 0 - shiftTop = _shift2[0]; - shiftLeft = _shift2[1]; + for (var i = 0; i < length; i += 2, ++j) { + var left = results[i] + var right = i + 1 === length ? left : results[i + 1] + var data = Buffer.concat([left, right]) - shiftTop = parseFloat(shiftTop, 10); - shiftLeft = parseFloat(shiftLeft, 10); - } else { - shiftTop = shift.top; - shiftLeft = shift.left; + results[j] = digestFn(data) } - top += shiftTop; - left += shiftLeft; - - return { top: top, left: left }; + length = j } -}); -},{"./utils":5}],4:[function(require,module,exports){ -/* globals performance */ + return results[0] +} -'use strict'; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -Object.defineProperty(exports, '__esModule', { - value: true -}); +/***/ }), +/* 467 */ +/***/ (function(module, exports, __webpack_require__) { -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +/* WEBPACK VAR INJECTION */(function(Buffer) {var NATIVE = __webpack_require__(111) +var ERRORS = __webpack_require__(201) -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); +function _Buffer (value) { + return Buffer.isBuffer(value) +} -var _get = function get(_x6, _x7, _x8) { var _again = true; _function: while (_again) { var object = _x6, property = _x7, receiver = _x8; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x6 = parent; _x7 = property; _x8 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; +function Hex (value) { + return typeof value === 'string' && /^([0-9a-f]{2})+$/i.test(value) +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +function _LengthN (type, length) { + var name = type.toJSON() -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + function Length (value) { + if (!type(value)) return false + if (value.length === length) return true -function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + throw ERRORS.tfCustomError(name + '(Length: ' + length + ')', name + '(Length: ' + value.length + ')') + } + Length.toJSON = function () { return name } -var _utils = require('./utils'); + return Length +} -var _utils2 = _interopRequireDefault(_utils); +var _ArrayN = _LengthN.bind(null, NATIVE.Array) +var _BufferN = _LengthN.bind(null, _Buffer) +var _HexN = _LengthN.bind(null, Hex) -require('./constraint'); +var UINT53_MAX = Math.pow(2, 53) - 1 -require('./abutment'); +function Finite (value) { + return typeof value === 'number' && isFinite(value) +} +function Int8 (value) { return ((value << 24) >> 24) === value } +function Int16 (value) { return ((value << 16) >> 16) === value } +function Int32 (value) { return (value | 0) === value } +function UInt8 (value) { return (value & 0xff) === value } +function UInt16 (value) { return (value & 0xffff) === value } +function UInt32 (value) { return (value >>> 0) === value } +function UInt53 (value) { + return typeof value === 'number' && + value >= 0 && + value <= UINT53_MAX && + Math.floor(value) === value +} -require('./shift'); +var types = { + ArrayN: _ArrayN, + Buffer: _Buffer, + BufferN: _BufferN, + Finite: Finite, + Hex: Hex, + HexN: _HexN, + Int8: Int8, + Int16: Int16, + Int32: Int32, + UInt8: UInt8, + UInt16: UInt16, + UInt32: UInt32, + UInt53: UInt53 +} -var _TetherBase$Utils = _utils2['default'].Utils; -var getScrollParents = _TetherBase$Utils.getScrollParents; -var getBounds = _TetherBase$Utils.getBounds; -var getOffsetParent = _TetherBase$Utils.getOffsetParent; -var extend = _TetherBase$Utils.extend; -var addClass = _TetherBase$Utils.addClass; -var removeClass = _TetherBase$Utils.removeClass; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; -var flush = _TetherBase$Utils.flush; -var getScrollBarSize = _TetherBase$Utils.getScrollBarSize; -var removeUtilElements = _TetherBase$Utils.removeUtilElements; -var Evented = _TetherBase$Utils.Evented; +for (var typeName in types) { + types[typeName].toJSON = function (t) { + return t + }.bind(null, typeName) +} -function within(a, b) { - var diff = arguments.length <= 2 || arguments[2] === undefined ? 1 : arguments[2]; +module.exports = types - return a + diff >= b && b >= a - diff; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 468 */ +/***/ (function(module, exports, __webpack_require__) { + +var OPS = __webpack_require__(16) + +var map = {} +for (var op in OPS) { + var code = OPS[op] + map[code] = op } -var transformKey = (function () { - if (typeof document === 'undefined') { - return ''; - } - var el = document.createElement('div'); +module.exports = map - var transforms = ['transform', 'WebkitTransform', 'OTransform', 'MozTransform', 'msTransform']; - for (var i = 0; i < transforms.length; ++i) { - var key = transforms[i]; - if (el.style[key] !== undefined) { - return key; - } - } -})(); -var tethers = []; +/***/ }), +/* 469 */ +/***/ (function(module, exports, __webpack_require__) { -var position = function position() { - tethers.forEach(function (tether) { - tether.position(false); - }); - flush(); -}; +var decompile = __webpack_require__(14).decompile +var multisig = __webpack_require__(470) +var nullData = __webpack_require__(473) +var pubKey = __webpack_require__(474) +var pubKeyHash = __webpack_require__(477) +var scriptHash = __webpack_require__(479) +var witnessPubKeyHash = __webpack_require__(481) +var witnessScriptHash = __webpack_require__(484) +var witnessCommitment = __webpack_require__(487) + +var types = { + MULTISIG: 'multisig', + NONSTANDARD: 'nonstandard', + NULLDATA: 'nulldata', + P2PK: 'pubkey', + P2PKH: 'pubkeyhash', + P2SH: 'scripthash', + P2WPKH: 'witnesspubkeyhash', + P2WSH: 'witnessscripthash', + WITNESS_COMMITMENT: 'witnesscommitment' +} -function now() { - if (typeof performance !== 'undefined' && typeof performance.now !== 'undefined') { - return performance.now(); - } - return +new Date(); +function classifyOutput (script) { + if (witnessPubKeyHash.output.check(script)) return types.P2WPKH + if (witnessScriptHash.output.check(script)) return types.P2WSH + if (pubKeyHash.output.check(script)) return types.P2PKH + if (scriptHash.output.check(script)) return types.P2SH + + // XXX: optimization, below functions .decompile before use + var chunks = decompile(script) + if (multisig.output.check(chunks)) return types.MULTISIG + if (pubKey.output.check(chunks)) return types.P2PK + if (witnessCommitment.output.check(chunks)) return types.WITNESS_COMMITMENT + if (nullData.output.check(chunks)) return types.NULLDATA + + return types.NONSTANDARD } -(function () { - var lastCall = null; - var lastDuration = null; - var pendingTimeout = null; +function classifyInput (script, allowIncomplete) { + // XXX: optimization, below functions .decompile before use + var chunks = decompile(script) - var tick = function tick() { - if (typeof lastDuration !== 'undefined' && lastDuration > 16) { - // We voluntarily throttle ourselves if we can't manage 60fps - lastDuration = Math.min(lastDuration - 16, 250); + if (pubKeyHash.input.check(chunks)) return types.P2PKH + if (scriptHash.input.check(chunks, allowIncomplete)) return types.P2SH + if (multisig.input.check(chunks, allowIncomplete)) return types.MULTISIG + if (pubKey.input.check(chunks)) return types.P2PK - // Just in case this is the last event, remember to position just once more - pendingTimeout = setTimeout(tick, 250); - return; - } + return types.NONSTANDARD +} - if (typeof lastCall !== 'undefined' && now() - lastCall < 10) { - // Some browsers call events a little too frequently, refuse to run more than is reasonable - return; - } +function classifyWitness (script, allowIncomplete) { + // XXX: optimization, below functions .decompile before use + var chunks = decompile(script) - if (pendingTimeout != null) { - clearTimeout(pendingTimeout); - pendingTimeout = null; - } + if (witnessPubKeyHash.input.check(chunks)) return types.P2WPKH + if (witnessScriptHash.input.check(chunks, allowIncomplete)) return types.P2WSH - lastCall = now(); - position(); - lastDuration = now() - lastCall; - }; + return types.NONSTANDARD +} - if (typeof window !== 'undefined' && typeof window.addEventListener !== 'undefined') { - ['resize', 'scroll', 'touchmove'].forEach(function (event) { - window.addEventListener(event, tick); - }); - } -})(); +module.exports = { + classifyInput: classifyInput, + classifyOutput: classifyOutput, + classifyWitness: classifyWitness, + multisig: multisig, + nullData: nullData, + pubKey: pubKey, + pubKeyHash: pubKeyHash, + scriptHash: scriptHash, + witnessPubKeyHash: witnessPubKeyHash, + witnessScriptHash: witnessScriptHash, + witnessCommitment: witnessCommitment, + types: types +} -var MIRROR_LR = { - center: 'center', - left: 'right', - right: 'left' -}; -var MIRROR_TB = { - middle: 'middle', - top: 'bottom', - bottom: 'top' -}; +/***/ }), +/* 470 */ +/***/ (function(module, exports, __webpack_require__) { -var OFFSET_MAP = { - top: 0, - left: 0, - middle: '50%', - center: '50%', - bottom: '100%', - right: '100%' -}; +module.exports = { + input: __webpack_require__(471), + output: __webpack_require__(472) +} -var autoToFixedAttachment = function autoToFixedAttachment(attachment, relativeToAttachment) { - var left = attachment.left; - var top = attachment.top; - if (left === 'auto') { - left = MIRROR_LR[relativeToAttachment.left]; - } +/***/ }), +/* 471 */ +/***/ (function(module, exports, __webpack_require__) { - if (top === 'auto') { - top = MIRROR_TB[relativeToAttachment.top]; - } +// OP_0 [signatures ...] - return { left: left, top: top }; -}; +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) -var attachmentToOffset = function attachmentToOffset(attachment) { - var left = attachment.left; - var top = attachment.top; +function partialSignature (value) { + return value === OPS.OP_0 || bscript.isCanonicalSignature(value) +} - if (typeof OFFSET_MAP[attachment.left] !== 'undefined') { - left = OFFSET_MAP[attachment.left]; - } +function check (script, allowIncomplete) { + var chunks = bscript.decompile(script) + if (chunks.length < 2) return false + if (chunks[0] !== OPS.OP_0) return false - if (typeof OFFSET_MAP[attachment.top] !== 'undefined') { - top = OFFSET_MAP[attachment.top]; + if (allowIncomplete) { + return chunks.slice(1).every(partialSignature) } - return { left: left, top: top }; -}; + return chunks.slice(1).every(bscript.isCanonicalSignature) +} +check.toJSON = function () { return 'multisig input' } -function addOffset() { - var out = { top: 0, left: 0 }; +var EMPTY_BUFFER = Buffer.allocUnsafe(0) - for (var _len = arguments.length, offsets = Array(_len), _key = 0; _key < _len; _key++) { - offsets[_key] = arguments[_key]; - } +function encodeStack (signatures, scriptPubKey) { + typeforce([partialSignature], signatures) - offsets.forEach(function (_ref) { - var top = _ref.top; - var left = _ref.left; + if (scriptPubKey) { + var scriptData = bscript.multisig.output.decode(scriptPubKey) - if (typeof top === 'string') { - top = parseFloat(top, 10); - } - if (typeof left === 'string') { - left = parseFloat(left, 10); + if (signatures.length < scriptData.m) { + throw new TypeError('Not enough signatures provided') } - out.top += top; - out.left += left; - }); + if (signatures.length > scriptData.pubKeys.length) { + throw new TypeError('Too many signatures provided') + } + } - return out; + return [].concat(EMPTY_BUFFER, signatures) } -function offsetToPx(offset, size) { - if (typeof offset.left === 'string' && offset.left.indexOf('%') !== -1) { - offset.left = parseFloat(offset.left, 10) / 100 * size.width; - } - if (typeof offset.top === 'string' && offset.top.indexOf('%') !== -1) { - offset.top = parseFloat(offset.top, 10) / 100 * size.height; - } +function encode (signatures, scriptPubKey) { + return bscript.compile(encodeStack(signatures, scriptPubKey)) +} - return offset; +function decodeStack (stack, allowIncomplete) { + typeforce(check, stack, allowIncomplete) + return stack.slice(1) } -var parseOffset = function parseOffset(value) { - var _value$split = value.split(' '); +function decode (buffer, allowIncomplete) { + var stack = bscript.decompile(buffer) + return decodeStack(stack, allowIncomplete) +} - var _value$split2 = _slicedToArray(_value$split, 2); +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} - var top = _value$split2[0]; - var left = _value$split2[1]; - return { top: top, left: left }; -}; -var parseAttachment = parseOffset; +/***/ }), +/* 472 */ +/***/ (function(module, exports, __webpack_require__) { -var TetherClass = (function (_Evented) { - _inherits(TetherClass, _Evented); +// m [pubKeys ...] n OP_CHECKMULTISIG - function TetherClass(options) { - var _this = this; +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) +var OP_INT_BASE = OPS.OP_RESERVED // OP_1 - 1 - _classCallCheck(this, TetherClass); +function check (script, allowIncomplete) { + var chunks = bscript.decompile(script) - _get(Object.getPrototypeOf(TetherClass.prototype), 'constructor', this).call(this); - this.position = this.position.bind(this); + if (chunks.length < 4) return false + if (chunks[chunks.length - 1] !== OPS.OP_CHECKMULTISIG) return false + if (!types.Number(chunks[0])) return false + if (!types.Number(chunks[chunks.length - 2])) return false + var m = chunks[0] - OP_INT_BASE + var n = chunks[chunks.length - 2] - OP_INT_BASE - tethers.push(this); + if (m <= 0) return false + if (n > 16) return false + if (m > n) return false + if (n !== chunks.length - 3) return false + if (allowIncomplete) return true - this.history = []; + var keys = chunks.slice(1, -2) + return keys.every(bscript.isCanonicalPubKey) +} +check.toJSON = function () { return 'multi-sig output' } - this.setOptions(options, false); +function encode (m, pubKeys) { + typeforce({ + m: types.Number, + pubKeys: [bscript.isCanonicalPubKey] + }, { + m: m, + pubKeys: pubKeys + }) + + var n = pubKeys.length + if (n < m) throw new TypeError('Not enough pubKeys provided') + + return bscript.compile([].concat( + OP_INT_BASE + m, + pubKeys, + OP_INT_BASE + n, + OPS.OP_CHECKMULTISIG + )) +} - _utils2['default'].modules.forEach(function (module) { - if (typeof module.initialize !== 'undefined') { - module.initialize.call(_this); - } - }); +function decode (buffer, allowIncomplete) { + var chunks = bscript.decompile(buffer) + typeforce(check, chunks, allowIncomplete) - this.position(); + return { + m: chunks[0] - OP_INT_BASE, + pubKeys: chunks.slice(1, -2) } +} - _createClass(TetherClass, [{ - key: 'getClass', - value: function getClass() { - var key = arguments.length <= 0 || arguments[0] === undefined ? '' : arguments[0]; - var classes = this.options.classes; +module.exports = { + check: check, + decode: decode, + encode: encode +} - if (typeof classes !== 'undefined' && classes[key]) { - return this.options.classes[key]; - } else if (this.options.classPrefix) { - return this.options.classPrefix + '-' + key; - } else { - return key; - } - } - }, { - key: 'setOptions', - value: function setOptions(options) { - var _this2 = this; - var pos = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1]; +/***/ }), +/* 473 */ +/***/ (function(module, exports, __webpack_require__) { + +// OP_RETURN {data} + +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - var defaults = { - offset: '0 0', - targetOffset: '0 0', - targetAttachment: 'auto auto', - classPrefix: 'tether' - }; +function check (script) { + var buffer = bscript.compile(script) - this.options = extend(defaults, options); + return buffer.length > 1 && + buffer[0] === OPS.OP_RETURN +} +check.toJSON = function () { return 'null data output' } - var _options = this.options; - var element = _options.element; - var target = _options.target; - var targetModifier = _options.targetModifier; +function encode (data) { + typeforce(types.Buffer, data) - this.element = element; - this.target = target; - this.targetModifier = targetModifier; + return bscript.compile([OPS.OP_RETURN, data]) +} - if (this.target === 'viewport') { - this.target = document.body; - this.targetModifier = 'visible'; - } else if (this.target === 'scroll-handle') { - this.target = document.body; - this.targetModifier = 'scroll-handle'; - } +function decode (buffer) { + typeforce(check, buffer) - ['element', 'target'].forEach(function (key) { - if (typeof _this2[key] === 'undefined') { - throw new Error('Tether Error: Both element and target must be defined'); - } + return buffer.slice(2) +} - if (typeof _this2[key].jquery !== 'undefined') { - _this2[key] = _this2[key][0]; - } else if (typeof _this2[key] === 'string') { - _this2[key] = document.querySelector(_this2[key]); - } - }); +module.exports = { + output: { + check: check, + decode: decode, + encode: encode + } +} - addClass(this.element, this.getClass('element')); - if (!(this.options.addTargetClasses === false)) { - addClass(this.target, this.getClass('target')); - } - if (!this.options.attachment) { - throw new Error('Tether Error: You must provide an attachment'); - } +/***/ }), +/* 474 */ +/***/ (function(module, exports, __webpack_require__) { - this.targetAttachment = parseAttachment(this.options.targetAttachment); - this.attachment = parseAttachment(this.options.attachment); - this.offset = parseOffset(this.options.offset); - this.targetOffset = parseOffset(this.options.targetOffset); +module.exports = { + input: __webpack_require__(475), + output: __webpack_require__(476) +} - if (typeof this.scrollParents !== 'undefined') { - this.disable(); - } - if (this.targetModifier === 'scroll-handle') { - this.scrollParents = [this.target]; - } else { - this.scrollParents = getScrollParents(this.target); - } +/***/ }), +/* 475 */ +/***/ (function(module, exports, __webpack_require__) { - if (!(this.options.enabled === false)) { - this.enable(pos); - } - } - }, { - key: 'getTargetBounds', - value: function getTargetBounds() { - if (typeof this.targetModifier !== 'undefined') { - if (this.targetModifier === 'visible') { - if (this.target === document.body) { - return { top: pageYOffset, left: pageXOffset, height: innerHeight, width: innerWidth }; - } else { - var bounds = getBounds(this.target); +// {signature} - var out = { - height: bounds.height, - width: bounds.width, - top: bounds.top, - left: bounds.left - }; +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) - out.height = Math.min(out.height, bounds.height - (pageYOffset - bounds.top)); - out.height = Math.min(out.height, bounds.height - (bounds.top + bounds.height - (pageYOffset + innerHeight))); - out.height = Math.min(innerHeight, out.height); - out.height -= 2; +function check (script) { + var chunks = bscript.decompile(script) - out.width = Math.min(out.width, bounds.width - (pageXOffset - bounds.left)); - out.width = Math.min(out.width, bounds.width - (bounds.left + bounds.width - (pageXOffset + innerWidth))); - out.width = Math.min(innerWidth, out.width); - out.width -= 2; + return chunks.length === 1 && + bscript.isCanonicalSignature(chunks[0]) +} +check.toJSON = function () { return 'pubKey input' } - if (out.top < pageYOffset) { - out.top = pageYOffset; - } - if (out.left < pageXOffset) { - out.left = pageXOffset; - } +function encodeStack (signature) { + typeforce(types.Buffer, signature) + return [signature] +} - return out; - } - } else if (this.targetModifier === 'scroll-handle') { - var bounds = undefined; - var target = this.target; - if (target === document.body) { - target = document.documentElement; +function encode (signature) { + return bscript.compile(encodeStack(signature)) +} - bounds = { - left: pageXOffset, - top: pageYOffset, - height: innerHeight, - width: innerWidth - }; - } else { - bounds = getBounds(target); - } +function decodeStack (stack) { + typeforce(check, stack) + return stack[0] +} - var style = getComputedStyle(target); +function decode (buffer) { + var stack = bscript.decompile(buffer) + return decodeStack(stack) +} - var hasBottomScroll = target.scrollWidth > target.clientWidth || [style.overflow, style.overflowX].indexOf('scroll') >= 0 || this.target !== document.body; +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} - var scrollBottom = 0; - if (hasBottomScroll) { - scrollBottom = 15; - } - var height = bounds.height - parseFloat(style.borderTopWidth) - parseFloat(style.borderBottomWidth) - scrollBottom; +/***/ }), +/* 476 */ +/***/ (function(module, exports, __webpack_require__) { - var out = { - width: 15, - height: height * 0.975 * (height / target.scrollHeight), - left: bounds.left + bounds.width - parseFloat(style.borderLeftWidth) - 15 - }; +// {pubKey} OP_CHECKSIG - var fitAdj = 0; - if (height < 408 && this.target === document.body) { - fitAdj = -0.00011 * Math.pow(height, 2) - 0.00727 * height + 22.58; - } +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - if (this.target !== document.body) { - out.height = Math.max(out.height, 24); - } +function check (script) { + var chunks = bscript.decompile(script) - var scrollPercentage = this.target.scrollTop / (target.scrollHeight - height); - out.top = scrollPercentage * (height - out.height - fitAdj) + bounds.top + parseFloat(style.borderTopWidth); + return chunks.length === 2 && + bscript.isCanonicalPubKey(chunks[0]) && + chunks[1] === OPS.OP_CHECKSIG +} +check.toJSON = function () { return 'pubKey output' } - if (this.target === document.body) { - out.height = Math.max(out.height, 24); - } +function encode (pubKey) { + typeforce(bscript.isCanonicalPubKey, pubKey) - return out; - } - } else { - return getBounds(this.target); - } - } - }, { - key: 'clearCache', - value: function clearCache() { - this._cache = {}; - } - }, { - key: 'cache', - value: function cache(k, getter) { - // More than one module will often need the same DOM info, so - // we keep a cache which is cleared on each position call - if (typeof this._cache === 'undefined') { - this._cache = {}; - } + return bscript.compile([pubKey, OPS.OP_CHECKSIG]) +} - if (typeof this._cache[k] === 'undefined') { - this._cache[k] = getter.call(this); - } +function decode (buffer) { + var chunks = bscript.decompile(buffer) + typeforce(check, chunks) - return this._cache[k]; - } - }, { - key: 'enable', - value: function enable() { - var _this3 = this; + return chunks[0] +} - var pos = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; +module.exports = { + check: check, + decode: decode, + encode: encode +} - if (!(this.options.addTargetClasses === false)) { - addClass(this.target, this.getClass('enabled')); - } - addClass(this.element, this.getClass('enabled')); - this.enabled = true; - this.scrollParents.forEach(function (parent) { - if (parent !== _this3.target.ownerDocument) { - parent.addEventListener('scroll', _this3.position); - } - }); +/***/ }), +/* 477 */ +/***/ (function(module, exports, __webpack_require__) { - if (pos) { - this.position(); - } - } - }, { - key: 'disable', - value: function disable() { - var _this4 = this; +module.exports = { + input: __webpack_require__(204), + output: __webpack_require__(478) +} - removeClass(this.target, this.getClass('enabled')); - removeClass(this.element, this.getClass('enabled')); - this.enabled = false; - if (typeof this.scrollParents !== 'undefined') { - this.scrollParents.forEach(function (parent) { - parent.removeEventListener('scroll', _this4.position); - }); - } - } - }, { - key: 'destroy', - value: function destroy() { - var _this5 = this; +/***/ }), +/* 478 */ +/***/ (function(module, exports, __webpack_require__) { - this.disable(); +// OP_DUP OP_HASH160 {pubKeyHash} OP_EQUALVERIFY OP_CHECKSIG - tethers.forEach(function (tether, i) { - if (tether === _this5) { - tethers.splice(i, 1); - } - }); +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - // Remove any elements we were using for convenience from the DOM - if (tethers.length === 0) { - removeUtilElements(); - } - } - }, { - key: 'updateAttachClasses', - value: function updateAttachClasses(elementAttach, targetAttach) { - var _this6 = this; +function check (script) { + var buffer = bscript.compile(script) - elementAttach = elementAttach || this.attachment; - targetAttach = targetAttach || this.targetAttachment; - var sides = ['left', 'top', 'bottom', 'right', 'middle', 'center']; + return buffer.length === 25 && + buffer[0] === OPS.OP_DUP && + buffer[1] === OPS.OP_HASH160 && + buffer[2] === 0x14 && + buffer[23] === OPS.OP_EQUALVERIFY && + buffer[24] === OPS.OP_CHECKSIG +} +check.toJSON = function () { return 'pubKeyHash output' } + +function encode (pubKeyHash) { + typeforce(types.Hash160bit, pubKeyHash) + + return bscript.compile([ + OPS.OP_DUP, + OPS.OP_HASH160, + pubKeyHash, + OPS.OP_EQUALVERIFY, + OPS.OP_CHECKSIG + ]) +} - if (typeof this._addAttachClasses !== 'undefined' && this._addAttachClasses.length) { - // updateAttachClasses can be called more than once in a position call, so - // we need to clean up after ourselves such that when the last defer gets - // ran it doesn't add any extra classes from previous calls. - this._addAttachClasses.splice(0, this._addAttachClasses.length); - } +function decode (buffer) { + typeforce(check, buffer) - if (typeof this._addAttachClasses === 'undefined') { - this._addAttachClasses = []; - } - var add = this._addAttachClasses; + return buffer.slice(3, 23) +} - if (elementAttach.top) { - add.push(this.getClass('element-attached') + '-' + elementAttach.top); - } - if (elementAttach.left) { - add.push(this.getClass('element-attached') + '-' + elementAttach.left); - } - if (targetAttach.top) { - add.push(this.getClass('target-attached') + '-' + targetAttach.top); - } - if (targetAttach.left) { - add.push(this.getClass('target-attached') + '-' + targetAttach.left); - } +module.exports = { + check: check, + decode: decode, + encode: encode +} - var all = []; - sides.forEach(function (side) { - all.push(_this6.getClass('element-attached') + '-' + side); - all.push(_this6.getClass('target-attached') + '-' + side); - }); - defer(function () { - if (!(typeof _this6._addAttachClasses !== 'undefined')) { - return; - } +/***/ }), +/* 479 */ +/***/ (function(module, exports, __webpack_require__) { - updateClasses(_this6.element, _this6._addAttachClasses, all); - if (!(_this6.options.addTargetClasses === false)) { - updateClasses(_this6.target, _this6._addAttachClasses, all); - } +module.exports = { + input: __webpack_require__(205), + output: __webpack_require__(480) +} - delete _this6._addAttachClasses; - }); - } - }, { - key: 'position', - value: function position() { - var _this7 = this; - var flushChanges = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; +/***/ }), +/* 480 */ +/***/ (function(module, exports, __webpack_require__) { - // flushChanges commits the changes immediately, leave true unless you are positioning multiple - // tethers (in which case call Tether.Utils.flush yourself when you're done) +// OP_HASH160 {scriptHash} OP_EQUAL - if (!this.enabled) { - return; - } +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - this.clearCache(); +function check (script) { + var buffer = bscript.compile(script) - // Turn 'auto' attachments into the appropriate corner or edge - var targetAttachment = autoToFixedAttachment(this.targetAttachment, this.attachment); + return buffer.length === 23 && + buffer[0] === OPS.OP_HASH160 && + buffer[1] === 0x14 && + buffer[22] === OPS.OP_EQUAL +} +check.toJSON = function () { return 'scriptHash output' } - this.updateAttachClasses(this.attachment, targetAttachment); +function encode (scriptHash) { + typeforce(types.Hash160bit, scriptHash) - var elementPos = this.cache('element-bounds', function () { - return getBounds(_this7.element); - }); + return bscript.compile([OPS.OP_HASH160, scriptHash, OPS.OP_EQUAL]) +} - var width = elementPos.width; - var height = elementPos.height; +function decode (buffer) { + typeforce(check, buffer) - if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { - var _lastSize = this.lastSize; + return buffer.slice(2, 22) +} - // We cache the height and width to make it possible to position elements that are - // getting hidden. - width = _lastSize.width; - height = _lastSize.height; - } else { - this.lastSize = { width: width, height: height }; - } +module.exports = { + check: check, + decode: decode, + encode: encode +} - var targetPos = this.cache('target-bounds', function () { - return _this7.getTargetBounds(); - }); - var targetSize = targetPos; - // Get an actual px offset from the attachment - var offset = offsetToPx(attachmentToOffset(this.attachment), { width: width, height: height }); - var targetOffset = offsetToPx(attachmentToOffset(targetAttachment), targetSize); +/***/ }), +/* 481 */ +/***/ (function(module, exports, __webpack_require__) { - var manualOffset = offsetToPx(this.offset, { width: width, height: height }); - var manualTargetOffset = offsetToPx(this.targetOffset, targetSize); +module.exports = { + input: __webpack_require__(482), + output: __webpack_require__(483) +} - // Add the manually provided offset - offset = addOffset(offset, manualOffset); - targetOffset = addOffset(targetOffset, manualTargetOffset); - // It's now our goal to make (element position + offset) == (target position + target offset) - var left = targetPos.left + targetOffset.left - offset.left; - var top = targetPos.top + targetOffset.top - offset.top; +/***/ }), +/* 482 */ +/***/ (function(module, exports, __webpack_require__) { - for (var i = 0; i < _utils2['default'].modules.length; ++i) { - var _module2 = _utils2['default'].modules[i]; - var ret = _module2.position.call(this, { - left: left, - top: top, - targetAttachment: targetAttachment, - targetPos: targetPos, - elementPos: elementPos, - offset: offset, - targetOffset: targetOffset, - manualOffset: manualOffset, - manualTargetOffset: manualTargetOffset, - scrollbarSize: scrollbarSize, - attachment: this.attachment - }); +// {signature} {pubKey} - if (ret === false) { - return false; - } else if (typeof ret === 'undefined' || typeof ret !== 'object') { - continue; - } else { - top = ret.top; - left = ret.left; - } - } +var pkh = __webpack_require__(204) - // We describe the position three different ways to give the optimizer - // a chance to decide the best possible way to position the element - // with the fewest repaints. - var next = { - // It's position relative to the page (absolute positioning when - // the element is a child of the body) - page: { - top: top, - left: left - }, +module.exports = { + check: pkh.check, + decodeStack: pkh.decodeStack, + encodeStack: pkh.encodeStack +} - // It's position relative to the viewport (fixed positioning) - viewport: { - top: top - pageYOffset, - bottom: pageYOffset - top - height + innerHeight, - left: left - pageXOffset, - right: pageXOffset - left - width + innerWidth - } - }; - var doc = this.target.ownerDocument; - var win = doc.defaultView; +/***/ }), +/* 483 */ +/***/ (function(module, exports, __webpack_require__) { - var scrollbarSize = undefined; - if (doc.body.scrollWidth > win.innerWidth) { - scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); - next.viewport.bottom -= scrollbarSize.height; - } +// OP_0 {pubKeyHash} - if (doc.body.scrollHeight > win.innerHeight) { - scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); - next.viewport.right -= scrollbarSize.width; - } +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - if (['', 'static'].indexOf(doc.body.style.position) === -1 || ['', 'static'].indexOf(doc.body.parentElement.style.position) === -1) { - // Absolute positioning in the body will be relative to the page, not the 'initial containing block' - next.page.bottom = doc.body.scrollHeight - top - height; - next.page.right = doc.body.scrollWidth - left - width; - } +function check (script) { + var buffer = bscript.compile(script) - if (typeof this.options.optimizations !== 'undefined' && this.options.optimizations.moveElement !== false && !(typeof this.targetModifier !== 'undefined')) { - (function () { - var offsetParent = _this7.cache('target-offsetparent', function () { - return getOffsetParent(_this7.target); - }); - var offsetPosition = _this7.cache('target-offsetparent-bounds', function () { - return getBounds(offsetParent); - }); - var offsetParentStyle = getComputedStyle(offsetParent); - var offsetParentSize = offsetPosition; + return buffer.length === 22 && + buffer[0] === OPS.OP_0 && + buffer[1] === 0x14 +} +check.toJSON = function () { return 'Witness pubKeyHash output' } - var offsetBorder = {}; - ['Top', 'Left', 'Bottom', 'Right'].forEach(function (side) { - offsetBorder[side.toLowerCase()] = parseFloat(offsetParentStyle['border' + side + 'Width']); - }); +function encode (pubKeyHash) { + typeforce(types.Hash160bit, pubKeyHash) - offsetPosition.right = doc.body.scrollWidth - offsetPosition.left - offsetParentSize.width + offsetBorder.right; - offsetPosition.bottom = doc.body.scrollHeight - offsetPosition.top - offsetParentSize.height + offsetBorder.bottom; + return bscript.compile([OPS.OP_0, pubKeyHash]) +} - if (next.page.top >= offsetPosition.top + offsetBorder.top && next.page.bottom >= offsetPosition.bottom) { - if (next.page.left >= offsetPosition.left + offsetBorder.left && next.page.right >= offsetPosition.right) { - // We're within the visible part of the target's scroll parent - var scrollTop = offsetParent.scrollTop; - var scrollLeft = offsetParent.scrollLeft; +function decode (buffer) { + typeforce(check, buffer) - // It's position relative to the target's offset parent (absolute positioning when - // the element is moved to be a child of the target's offset parent). - next.offset = { - top: next.page.top - offsetPosition.top + scrollTop - offsetBorder.top, - left: next.page.left - offsetPosition.left + scrollLeft - offsetBorder.left - }; - } - } - })(); - } + return buffer.slice(2) +} - // We could also travel up the DOM and try each containing context, rather than only - // looking at the body, but we're gonna get diminishing returns. +module.exports = { + check: check, + decode: decode, + encode: encode +} - this.move(next); - this.history.unshift(next); +/***/ }), +/* 484 */ +/***/ (function(module, exports, __webpack_require__) { - if (this.history.length > 3) { - this.history.pop(); - } +module.exports = { + input: __webpack_require__(485), + output: __webpack_require__(486) +} - if (flushChanges) { - flush(); - } - return true; - } +/***/ }), +/* 485 */ +/***/ (function(module, exports, __webpack_require__) { - // THE ISSUE - }, { - key: 'move', - value: function move(pos) { - var _this8 = this; +// {signature} {pubKey} - if (!(typeof this.element.parentNode !== 'undefined')) { - return; - } +var p2sh = __webpack_require__(205) - var same = {}; +module.exports = { + check: p2sh.check, + decodeStack: p2sh.decodeStack, + encodeStack: p2sh.encodeStack +} - for (var type in pos) { - same[type] = {}; - for (var key in pos[type]) { - var found = false; +/***/ }), +/* 486 */ +/***/ (function(module, exports, __webpack_require__) { - for (var i = 0; i < this.history.length; ++i) { - var point = this.history[i]; - if (typeof point[type] !== 'undefined' && !within(point[type][key], pos[type][key])) { - found = true; - break; - } - } +// OP_0 {scriptHash} - if (!found) { - same[type][key] = true; - } - } - } +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - var css = { top: '', left: '', right: '', bottom: '' }; +function check (script) { + var buffer = bscript.compile(script) - var transcribe = function transcribe(_same, _pos) { - var hasOptimizations = typeof _this8.options.optimizations !== 'undefined'; - var gpu = hasOptimizations ? _this8.options.optimizations.gpu : null; - if (gpu !== false) { - var yPos = undefined, - xPos = undefined; - if (_same.top) { - css.top = 0; - yPos = _pos.top; - } else { - css.bottom = 0; - yPos = -_pos.bottom; - } + return buffer.length === 34 && + buffer[0] === OPS.OP_0 && + buffer[1] === 0x20 +} +check.toJSON = function () { return 'Witness scriptHash output' } - if (_same.left) { - css.left = 0; - xPos = _pos.left; - } else { - css.right = 0; - xPos = -_pos.right; - } +function encode (scriptHash) { + typeforce(types.Hash256bit, scriptHash) + + return bscript.compile([OPS.OP_0, scriptHash]) +} + +function decode (buffer) { + typeforce(check, buffer) + + return buffer.slice(2) +} + +module.exports = { + check: check, + decode: decode, + encode: encode +} - css[transformKey] = 'translateX(' + Math.round(xPos) + 'px) translateY(' + Math.round(yPos) + 'px)'; - if (transformKey !== 'msTransform') { - // The Z transform will keep this in the GPU (faster, and prevents artifacts), - // but IE9 doesn't support 3d transforms and will choke. - css[transformKey] += " translateZ(0)"; - } - } else { - if (_same.top) { - css.top = _pos.top + 'px'; - } else { - css.bottom = _pos.bottom + 'px'; - } +/***/ }), +/* 487 */ +/***/ (function(module, exports, __webpack_require__) { - if (_same.left) { - css.left = _pos.left + 'px'; - } else { - css.right = _pos.right + 'px'; - } - } - }; +module.exports = { + output: __webpack_require__(488) +} - var moved = false; - if ((same.page.top || same.page.bottom) && (same.page.left || same.page.right)) { - css.position = 'absolute'; - transcribe(same.page, pos.page); - } else if ((same.viewport.top || same.viewport.bottom) && (same.viewport.left || same.viewport.right)) { - css.position = 'fixed'; - transcribe(same.viewport, pos.viewport); - } else if (typeof same.offset !== 'undefined' && same.offset.top && same.offset.left) { - (function () { - css.position = 'absolute'; - var offsetParent = _this8.cache('target-offsetparent', function () { - return getOffsetParent(_this8.target); - }); - if (getOffsetParent(_this8.element) !== offsetParent) { - defer(function () { - _this8.element.parentNode.removeChild(_this8.element); - offsetParent.appendChild(_this8.element); - }); - } +/***/ }), +/* 488 */ +/***/ (function(module, exports, __webpack_require__) { - transcribe(same.offset, pos.offset); - moved = true; - })(); - } else { - css.position = 'absolute'; - transcribe({ top: true, left: true }, pos.page); - } +// OP_RETURN {aa21a9ed} {commitment} - if (!moved) { - var offsetParentIsBody = true; - var currentNode = this.element.parentNode; - while (currentNode && currentNode.nodeType === 1 && currentNode.tagName !== 'BODY') { - if (getComputedStyle(currentNode).position !== 'static') { - offsetParentIsBody = false; - break; - } +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - currentNode = currentNode.parentNode; - } +var HEADER = Buffer.from('aa21a9ed', 'hex') - if (!offsetParentIsBody) { - this.element.parentNode.removeChild(this.element); - this.element.ownerDocument.body.appendChild(this.element); - } - } +function check (script) { + var buffer = bscript.compile(script) - // Any css change will trigger a repaint, so let's avoid one if nothing changed - var writeCSS = {}; - var write = false; - for (var key in css) { - var val = css[key]; - var elVal = this.element.style[key]; + return buffer.length > 37 && + buffer[0] === OPS.OP_RETURN && + buffer[1] === 0x24 && + buffer.slice(2, 6).equals(HEADER) +} - if (elVal !== val) { - write = true; - writeCSS[key] = val; - } - } +check.toJSON = function () { return 'Witness commitment output' } - if (write) { - defer(function () { - extend(_this8.element.style, writeCSS); - _this8.trigger('repositioned'); - }); - } - } - }]); +function encode (commitment) { + typeforce(types.Hash256bit, commitment) - return TetherClass; -})(Evented); + var buffer = Buffer.allocUnsafe(36) + HEADER.copy(buffer, 0) + commitment.copy(buffer, 4) -TetherClass.modules = []; + return bscript.compile([OPS.OP_RETURN, buffer]) +} -_utils2['default'].position = position; +function decode (buffer) { + typeforce(check, buffer) -var Tether = extend(TetherClass, _utils2['default']); + return bscript.decompile(buffer)[1].slice(4, 36) +} -exports['default'] = Tether; -module.exports = exports['default']; +module.exports = { + check: check, + decode: decode, + encode: encode +} -},{"./abutment":1,"./constraint":2,"./shift":3,"./utils":5}],5:[function(require,module,exports){ -'use strict'; -Object.defineProperty(exports, '__esModule', { - value: true -}); +/***/ }), +/* 489 */ +/***/ (function(module, exports, __webpack_require__) { -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); +var Buffer = __webpack_require__(7).Buffer +var createHmac = __webpack_require__(67) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) + +var BigInteger = __webpack_require__(30) +var ECSignature = __webpack_require__(115) + +var ZERO = Buffer.alloc(1, 0) +var ONE = Buffer.alloc(1, 1) + +var ecurve = __webpack_require__(116) +var secp256k1 = ecurve.getCurveByName('secp256k1') + +// https://tools.ietf.org/html/rfc6979#section-3.2 +function deterministicGenerateK (hash, x, checkSig) { + typeforce(types.tuple( + types.Hash256bit, + types.Buffer256bit, + types.Function + ), arguments) + + // Step A, ignored as hash already provided + // Step B + // Step C + var k = Buffer.alloc(32, 0) + var v = Buffer.alloc(32, 1) + + // Step D + k = createHmac('sha256', k) + .update(v) + .update(ZERO) + .update(x) + .update(hash) + .digest() + + // Step E + v = createHmac('sha256', k).update(v).digest() + + // Step F + k = createHmac('sha256', k) + .update(v) + .update(ONE) + .update(x) + .update(hash) + .digest() + + // Step G + v = createHmac('sha256', k).update(v).digest() + + // Step H1/H2a, ignored as tlen === qlen (256 bit) + // Step H2b + v = createHmac('sha256', k).update(v).digest() + + var T = BigInteger.fromBuffer(v) + + // Step H3, repeat until T is within the interval [1, n - 1] and is suitable for ECDSA + while (T.signum() <= 0 || T.compareTo(secp256k1.n) >= 0 || !checkSig(T)) { + k = createHmac('sha256', k) + .update(v) + .update(ZERO) + .digest() + + v = createHmac('sha256', k).update(v).digest() + + // Step H1/H2a, again, ignored as tlen === qlen (256 bit) + // Step H2b again + v = createHmac('sha256', k).update(v).digest() + T = BigInteger.fromBuffer(v) + } + + return T +} -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } +var N_OVER_TWO = secp256k1.n.shiftRight(1) -var TetherBase = { modules: [] }; +function sign (hash, d) { + typeforce(types.tuple(types.Hash256bit, types.BigInt), arguments) -var zeroElement = null; + var x = d.toBuffer(32) + var e = BigInteger.fromBuffer(hash) + var n = secp256k1.n + var G = secp256k1.G -// Same as native getBoundingClientRect, except it takes into account parent <frame> offsets -// if the element lies within a nested document (<frame> or <iframe>-like). -function getActualBoundingClientRect(node) { - var boundingRect = node.getBoundingClientRect(); + var r, s + deterministicGenerateK(hash, x, function (k) { + var Q = G.multiply(k) - // The original object returned by getBoundingClientRect is immutable, so we clone it - // We can't use extend because the properties are not considered part of the object by hasOwnProperty in IE9 - var rect = {}; - for (var k in boundingRect) { - rect[k] = boundingRect[k]; - } + if (secp256k1.isInfinity(Q)) return false - if (node.ownerDocument !== document) { - var _frameElement = node.ownerDocument.defaultView.frameElement; - if (_frameElement) { - var frameRect = getActualBoundingClientRect(_frameElement); - rect.top += frameRect.top; - rect.bottom += frameRect.top; - rect.left += frameRect.left; - rect.right += frameRect.left; - } + r = Q.affineX.mod(n) + if (r.signum() === 0) return false + + s = k.modInverse(n).multiply(e.add(d.multiply(r))).mod(n) + if (s.signum() === 0) return false + + return true + }) + + // enforce low S values, see bip62: 'low s values in signatures' + if (s.compareTo(N_OVER_TWO) > 0) { + s = n.subtract(s) } - return rect; + return new ECSignature(r, s) } -function getScrollParents(el) { - // In firefox if the el is inside an iframe with display: none; window.getComputedStyle() will return null; - // https://bugzilla.mozilla.org/show_bug.cgi?id=548397 - var computedStyle = getComputedStyle(el) || {}; - var position = computedStyle.position; - var parents = []; +function verify (hash, signature, Q) { + typeforce(types.tuple( + types.Hash256bit, + types.ECSignature, + types.ECPoint + ), arguments) - if (position === 'fixed') { - return [el]; - } + var n = secp256k1.n + var G = secp256k1.G - var parent = el; - while ((parent = parent.parentNode) && parent && parent.nodeType === 1) { - var style = undefined; - try { - style = getComputedStyle(parent); - } catch (err) {} + var r = signature.r + var s = signature.s - if (typeof style === 'undefined' || style === null) { - parents.push(parent); - return parents; - } + // 1.4.1 Enforce r and s are both integers in the interval [1, n − 1] + if (r.signum() <= 0 || r.compareTo(n) >= 0) return false + if (s.signum() <= 0 || s.compareTo(n) >= 0) return false - var _style = style; - var overflow = _style.overflow; - var overflowX = _style.overflowX; - var overflowY = _style.overflowY; + // 1.4.2 H = Hash(M), already done by the user + // 1.4.3 e = H + var e = BigInteger.fromBuffer(hash) - if (/(auto|scroll)/.test(overflow + overflowY + overflowX)) { - if (position !== 'absolute' || ['relative', 'absolute', 'fixed'].indexOf(style.position) >= 0) { - parents.push(parent); - } - } - } + // Compute s^-1 + var sInv = s.modInverse(n) - parents.push(el.ownerDocument.body); + // 1.4.4 Compute u1 = es^−1 mod n + // u2 = rs^−1 mod n + var u1 = e.multiply(sInv).mod(n) + var u2 = r.multiply(sInv).mod(n) - // If the node is within a frame, account for the parent window scroll - if (el.ownerDocument !== document) { - parents.push(el.ownerDocument.defaultView); - } + // 1.4.5 Compute R = (xR, yR) + // R = u1G + u2Q + var R = G.multiplyTwo(u1, Q, u2) - return parents; + // 1.4.5 (cont.) Enforce R is not at infinity + if (secp256k1.isInfinity(R)) return false + + // 1.4.6 Convert the field element R.x to an integer + var xR = R.affineX + + // 1.4.7 Set v = xR mod n + var v = xR.mod(n) + + // 1.4.8 If v = r, output "valid", and if v != r, output "invalid" + return v.equals(r) } -var uniqueId = (function () { - var id = 0; - return function () { - return ++id; - }; -})(); +module.exports = { + deterministicGenerateK: deterministicGenerateK, + sign: sign, + verify: verify, -var zeroPosCache = {}; -var getOrigin = function getOrigin() { - // getBoundingClientRect is unfortunately too accurate. It introduces a pixel or two of - // jitter as the user scrolls that messes with our ability to detect if two positions - // are equivilant or not. We place an element at the top left of the page that will - // get the same jitter, so we can cancel the two out. - var node = zeroElement; - if (!node) { - node = document.createElement('div'); - node.setAttribute('data-tether-id', uniqueId()); - extend(node.style, { - top: 0, - left: 0, - position: 'absolute' - }); + // TODO: remove + __curve: secp256k1 +} - document.body.appendChild(node); - zeroElement = node; - } +/***/ }), +/* 490 */ +/***/ (function(module, exports, __webpack_require__) { - var id = node.getAttribute('data-tether-id'); - if (typeof zeroPosCache[id] === 'undefined') { - zeroPosCache[id] = getActualBoundingClientRect(node); +var BigInteger = __webpack_require__(30) - // Clear the cache when this position call is done - defer(function () { - delete zeroPosCache[id]; - }); - } +var curves = __webpack_require__(491) +var Curve = __webpack_require__(208) - return zeroPosCache[id]; -}; +function getCurveByName (name) { + var curve = curves[name] + if (!curve) return null -function removeUtilElements() { - if (zeroElement) { - document.body.removeChild(zeroElement); - } - zeroElement = null; + var p = new BigInteger(curve.p, 16) + var a = new BigInteger(curve.a, 16) + var b = new BigInteger(curve.b, 16) + var n = new BigInteger(curve.n, 16) + var h = new BigInteger(curve.h, 16) + var Gx = new BigInteger(curve.Gx, 16) + var Gy = new BigInteger(curve.Gy, 16) + + return new Curve(p, a, b, Gx, Gy, n, h) +} + +module.exports = getCurveByName + + +/***/ }), +/* 491 */ +/***/ (function(module, exports) { + +module.exports = { + "secp128r1": { + "p": "fffffffdffffffffffffffffffffffff", + "a": "fffffffdfffffffffffffffffffffffc", + "b": "e87579c11079f43dd824993c2cee5ed3", + "n": "fffffffe0000000075a30d1b9038a115", + "h": "01", + "Gx": "161ff7528b899b2d0c28607ca52c5b86", + "Gy": "cf5ac8395bafeb13c02da292dded7a83" + }, + "secp160k1": { + "p": "fffffffffffffffffffffffffffffffeffffac73", + "a": "00", + "b": "07", + "n": "0100000000000000000001b8fa16dfab9aca16b6b3", + "h": "01", + "Gx": "3b4c382ce37aa192a4019e763036f4f5dd4d7ebb", + "Gy": "938cf935318fdced6bc28286531733c3f03c4fee" + }, + "secp160r1": { + "p": "ffffffffffffffffffffffffffffffff7fffffff", + "a": "ffffffffffffffffffffffffffffffff7ffffffc", + "b": "1c97befc54bd7a8b65acf89f81d4d4adc565fa45", + "n": "0100000000000000000001f4c8f927aed3ca752257", + "h": "01", + "Gx": "4a96b5688ef573284664698968c38bb913cbfc82", + "Gy": "23a628553168947d59dcc912042351377ac5fb32" + }, + "secp192k1": { + "p": "fffffffffffffffffffffffffffffffffffffffeffffee37", + "a": "00", + "b": "03", + "n": "fffffffffffffffffffffffe26f2fc170f69466a74defd8d", + "h": "01", + "Gx": "db4ff10ec057e9ae26b07d0280b7f4341da5d1b1eae06c7d", + "Gy": "9b2f2f6d9c5628a7844163d015be86344082aa88d95e2f9d" + }, + "secp192r1": { + "p": "fffffffffffffffffffffffffffffffeffffffffffffffff", + "a": "fffffffffffffffffffffffffffffffefffffffffffffffc", + "b": "64210519e59c80e70fa7e9ab72243049feb8deecc146b9b1", + "n": "ffffffffffffffffffffffff99def836146bc9b1b4d22831", + "h": "01", + "Gx": "188da80eb03090f67cbf20eb43a18800f4ff0afd82ff1012", + "Gy": "07192b95ffc8da78631011ed6b24cdd573f977a11e794811" + }, + "secp256k1": { + "p": "fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f", + "a": "00", + "b": "07", + "n": "fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141", + "h": "01", + "Gx": "79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798", + "Gy": "483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8" + }, + "secp256r1": { + "p": "ffffffff00000001000000000000000000000000ffffffffffffffffffffffff", + "a": "ffffffff00000001000000000000000000000000fffffffffffffffffffffffc", + "b": "5ac635d8aa3a93e7b3ebbd55769886bc651d06b0cc53b0f63bce3c3e27d2604b", + "n": "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", + "h": "01", + "Gx": "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296", + "Gy": "4fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5" + } }; -function getBounds(el) { - var doc = undefined; - if (el === document) { - doc = document; - el = document.documentElement; - } else { - doc = el.ownerDocument; - } +/***/ }), +/* 492 */ +/***/ (function(module, exports, __webpack_require__) { - var docEl = doc.documentElement; +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33) - var box = getActualBoundingClientRect(el); +function decodeRaw (buffer, version) { + // check version only if defined + if (version !== undefined && buffer[0] !== version) throw new Error('Invalid network version') - var origin = getOrigin(); + // uncompressed + if (buffer.length === 33) { + return { + version: buffer[0], + privateKey: buffer.slice(1, 33), + compressed: false + } + } - box.top -= origin.top; - box.left -= origin.left; + // invalid length + if (buffer.length !== 34) throw new Error('Invalid WIF length') - if (typeof box.width === 'undefined') { - box.width = document.body.scrollWidth - box.left - box.right; + // invalid compression flag + if (buffer[33] !== 0x01) throw new Error('Invalid compression flag') + + return { + version: buffer[0], + privateKey: buffer.slice(1, 33), + compressed: true } - if (typeof box.height === 'undefined') { - box.height = document.body.scrollHeight - box.top - box.bottom; +} + +function encodeRaw (version, privateKey, compressed) { + var result = new Buffer(compressed ? 34 : 33) + + result.writeUInt8(version, 0) + privateKey.copy(result, 1) + + if (compressed) { + result[33] = 0x01 } - box.top = box.top - docEl.clientTop; - box.left = box.left - docEl.clientLeft; - box.right = doc.body.clientWidth - box.width - box.left; - box.bottom = doc.body.clientHeight - box.height - box.top; + return result +} - return box; +function decode (string, version) { + return decodeRaw(bs58check.decode(string), version) } -function getOffsetParent(el) { - return el.offsetParent || document.documentElement; +function encode (version, privateKey, compressed) { + if (typeof version === 'number') return bs58check.encode(encodeRaw(version, privateKey, compressed)) + + return bs58check.encode( + encodeRaw( + version.version, + version.privateKey, + version.compressed + ) + ) } -function getScrollBarSize() { - var inner = document.createElement('div'); - inner.style.width = '100%'; - inner.style.height = '200px'; +module.exports = { + decode: decode, + decodeRaw: decodeRaw, + encode: encode, + encodeRaw: encodeRaw +} - var outer = document.createElement('div'); - extend(outer.style, { - position: 'absolute', - top: 0, - left: 0, - pointerEvents: 'none', - visibility: 'hidden', - width: '200px', - height: '150px', - overflow: 'hidden' - }); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - outer.appendChild(inner); +/***/ }), +/* 493 */ +/***/ (function(module, exports, __webpack_require__) { - document.body.appendChild(outer); +var Buffer = __webpack_require__(7).Buffer +var base58check = __webpack_require__(33) +var bcrypto = __webpack_require__(44) +var createHmac = __webpack_require__(67) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var NETWORKS = __webpack_require__(54) - var widthContained = inner.offsetWidth; - outer.style.overflow = 'scroll'; - var widthScroll = inner.offsetWidth; +var BigInteger = __webpack_require__(30) +var ECPair = __webpack_require__(113) - if (widthContained === widthScroll) { - widthScroll = outer.clientWidth; - } +var ecurve = __webpack_require__(116) +var curve = ecurve.getCurveByName('secp256k1') - document.body.removeChild(outer); +function HDNode (keyPair, chainCode) { + typeforce(types.tuple('ECPair', types.Buffer256bit), arguments) - var width = widthContained - widthScroll; + if (!keyPair.compressed) throw new TypeError('BIP32 only allows compressed keyPairs') - return { width: width, height: width }; + this.keyPair = keyPair + this.chainCode = chainCode + this.depth = 0 + this.index = 0 + this.parentFingerprint = 0x00000000 } -function extend() { - var out = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0]; +HDNode.HIGHEST_BIT = 0x80000000 +HDNode.LENGTH = 78 +HDNode.MASTER_SECRET = Buffer.from('Bitcoin seed', 'utf8') - var args = []; +HDNode.fromSeedBuffer = function (seed, network) { + typeforce(types.tuple(types.Buffer, types.maybe(types.Network)), arguments) - Array.prototype.push.apply(args, arguments); + if (seed.length < 16) throw new TypeError('Seed should be at least 128 bits') + if (seed.length > 64) throw new TypeError('Seed should be at most 512 bits') - args.slice(1).forEach(function (obj) { - if (obj) { - for (var key in obj) { - if (({}).hasOwnProperty.call(obj, key)) { - out[key] = obj[key]; - } - } - } - }); + var I = createHmac('sha512', HDNode.MASTER_SECRET).update(seed).digest() + var IL = I.slice(0, 32) + var IR = I.slice(32) - return out; + // In case IL is 0 or >= n, the master key is invalid + // This is handled by the ECPair constructor + var pIL = BigInteger.fromBuffer(IL) + var keyPair = new ECPair(pIL, null, { + network: network + }) + + return new HDNode(keyPair, IR) } -function removeClass(el, name) { - if (typeof el.classList !== 'undefined') { - name.split(' ').forEach(function (cls) { - if (cls.trim()) { - el.classList.remove(cls); - } - }); +HDNode.fromSeedHex = function (hex, network) { + return HDNode.fromSeedBuffer(Buffer.from(hex, 'hex'), network) +} + +HDNode.fromBase58 = function (string, networks) { + var buffer = base58check.decode(string) + if (buffer.length !== 78) throw new Error('Invalid buffer length') + + // 4 bytes: version bytes + var version = buffer.readUInt32BE(0) + var network + + // list of networks? + if (Array.isArray(networks)) { + network = networks.filter(function (x) { + return version === x.bip32.private || + version === x.bip32.public + }).pop() + + if (!network) throw new Error('Unknown network version') + + // otherwise, assume a network object (or default to bitcoin) } else { - var regex = new RegExp('(^| )' + name.split(' ').join('|') + '( |$)', 'gi'); - var className = getClassName(el).replace(regex, ' '); - setClassName(el, className); + network = networks || NETWORKS.bitcoin } -} -function addClass(el, name) { - if (typeof el.classList !== 'undefined') { - name.split(' ').forEach(function (cls) { - if (cls.trim()) { - el.classList.add(cls); - } - }); + if (version !== network.bip32.private && + version !== network.bip32.public) throw new Error('Invalid network version') + + // 1 byte: depth: 0x00 for master nodes, 0x01 for level-1 descendants, ... + var depth = buffer[4] + + // 4 bytes: the fingerprint of the parent's key (0x00000000 if master key) + var parentFingerprint = buffer.readUInt32BE(5) + if (depth === 0) { + if (parentFingerprint !== 0x00000000) throw new Error('Invalid parent fingerprint') + } + + // 4 bytes: child number. This is the number i in xi = xpar/i, with xi the key being serialized. + // This is encoded in MSB order. (0x00000000 if master key) + var index = buffer.readUInt32BE(9) + if (depth === 0 && index !== 0) throw new Error('Invalid index') + + // 32 bytes: the chain code + var chainCode = buffer.slice(13, 45) + var keyPair + + // 33 bytes: private key data (0x00 + k) + if (version === network.bip32.private) { + if (buffer.readUInt8(45) !== 0x00) throw new Error('Invalid private key') + + var d = BigInteger.fromBuffer(buffer.slice(46, 78)) + keyPair = new ECPair(d, null, { network: network }) + + // 33 bytes: public key data (0x02 + X or 0x03 + X) } else { - removeClass(el, name); - var cls = getClassName(el) + (' ' + name); - setClassName(el, cls); + var Q = ecurve.Point.decodeFrom(curve, buffer.slice(45, 78)) + // Q.compressed is assumed, if somehow this assumption is broken, `new HDNode` will throw + + // Verify that the X coordinate in the public point corresponds to a point on the curve. + // If not, the extended public key is invalid. + curve.validate(Q) + + keyPair = new ECPair(null, Q, { network: network }) } + + var hd = new HDNode(keyPair, chainCode) + hd.depth = depth + hd.index = index + hd.parentFingerprint = parentFingerprint + + return hd } -function hasClass(el, name) { - if (typeof el.classList !== 'undefined') { - return el.classList.contains(name); - } - var className = getClassName(el); - return new RegExp('(^| )' + name + '( |$)', 'gi').test(className); +HDNode.prototype.getAddress = function () { + return this.keyPair.getAddress() } -function getClassName(el) { - // Can't use just SVGAnimatedString here since nodes within a Frame in IE have - // completely separately SVGAnimatedString base classes - if (el.className instanceof el.ownerDocument.defaultView.SVGAnimatedString) { - return el.className.baseVal; - } - return el.className; +HDNode.prototype.getIdentifier = function () { + return bcrypto.hash160(this.keyPair.getPublicKeyBuffer()) } -function setClassName(el, className) { - el.setAttribute('class', className); +HDNode.prototype.getFingerprint = function () { + return this.getIdentifier().slice(0, 4) } -function updateClasses(el, add, all) { - // Of the set of 'all' classes, we need the 'add' classes, and only the - // 'add' classes to be set. - all.forEach(function (cls) { - if (add.indexOf(cls) === -1 && hasClass(el, cls)) { - removeClass(el, cls); - } - }); +HDNode.prototype.getNetwork = function () { + return this.keyPair.getNetwork() +} - add.forEach(function (cls) { - if (!hasClass(el, cls)) { - addClass(el, cls); - } - }); +HDNode.prototype.getPublicKeyBuffer = function () { + return this.keyPair.getPublicKeyBuffer() } -var deferred = []; +HDNode.prototype.neutered = function () { + var neuteredKeyPair = new ECPair(null, this.keyPair.Q, { + network: this.keyPair.network + }) -var defer = function defer(fn) { - deferred.push(fn); -}; + var neutered = new HDNode(neuteredKeyPair, this.chainCode) + neutered.depth = this.depth + neutered.index = this.index + neutered.parentFingerprint = this.parentFingerprint -var flush = function flush() { - var fn = undefined; - while (fn = deferred.pop()) { - fn(); + return neutered +} + +HDNode.prototype.sign = function (hash) { + return this.keyPair.sign(hash) +} + +HDNode.prototype.verify = function (hash, signature) { + return this.keyPair.verify(hash, signature) +} + +HDNode.prototype.toBase58 = function (__isPrivate) { + if (__isPrivate !== undefined) throw new TypeError('Unsupported argument in 2.0.0') + + // Version + var network = this.keyPair.network + var version = (!this.isNeutered()) ? network.bip32.private : network.bip32.public + var buffer = Buffer.allocUnsafe(78) + + // 4 bytes: version bytes + buffer.writeUInt32BE(version, 0) + + // 1 byte: depth: 0x00 for master nodes, 0x01 for level-1 descendants, .... + buffer.writeUInt8(this.depth, 4) + + // 4 bytes: the fingerprint of the parent's key (0x00000000 if master key) + buffer.writeUInt32BE(this.parentFingerprint, 5) + + // 4 bytes: child number. This is the number i in xi = xpar/i, with xi the key being serialized. + // This is encoded in big endian. (0x00000000 if master key) + buffer.writeUInt32BE(this.index, 9) + + // 32 bytes: the chain code + this.chainCode.copy(buffer, 13) + + // 33 bytes: the public key or private key data + if (!this.isNeutered()) { + // 0x00 + k for private keys + buffer.writeUInt8(0, 45) + this.keyPair.d.toBuffer(32).copy(buffer, 46) + + // 33 bytes: the public key + } else { + // X9.62 encoding for public keys + this.keyPair.getPublicKeyBuffer().copy(buffer, 45) } -}; -var Evented = (function () { - function Evented() { - _classCallCheck(this, Evented); + return base58check.encode(buffer) +} + +// https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki#child-key-derivation-ckd-functions +HDNode.prototype.derive = function (index) { + typeforce(types.UInt32, index) + + var isHardened = index >= HDNode.HIGHEST_BIT + var data = Buffer.allocUnsafe(37) + + // Hardened child + if (isHardened) { + if (this.isNeutered()) throw new TypeError('Could not derive hardened child key') + + // data = 0x00 || ser256(kpar) || ser32(index) + data[0] = 0x00 + this.keyPair.d.toBuffer(32).copy(data, 1) + data.writeUInt32BE(index, 33) + + // Normal child + } else { + // data = serP(point(kpar)) || ser32(index) + // = serP(Kpar) || ser32(index) + this.keyPair.getPublicKeyBuffer().copy(data, 0) + data.writeUInt32BE(index, 33) } - _createClass(Evented, [{ - key: 'on', - value: function on(event, handler, ctx) { - var once = arguments.length <= 3 || arguments[3] === undefined ? false : arguments[3]; + var I = createHmac('sha512', this.chainCode).update(data).digest() + var IL = I.slice(0, 32) + var IR = I.slice(32) - if (typeof this.bindings === 'undefined') { - this.bindings = {}; - } - if (typeof this.bindings[event] === 'undefined') { - this.bindings[event] = []; - } - this.bindings[event].push({ handler: handler, ctx: ctx, once: once }); - } - }, { - key: 'once', - value: function once(event, handler, ctx) { - this.on(event, handler, ctx, true); - } - }, { - key: 'off', - value: function off(event, handler) { - if (typeof this.bindings === 'undefined' || typeof this.bindings[event] === 'undefined') { - return; - } + var pIL = BigInteger.fromBuffer(IL) - if (typeof handler === 'undefined') { - delete this.bindings[event]; - } else { - var i = 0; - while (i < this.bindings[event].length) { - if (this.bindings[event][i].handler === handler) { - this.bindings[event].splice(i, 1); - } else { - ++i; - } - } - } - } - }, { - key: 'trigger', - value: function trigger(event) { - if (typeof this.bindings !== 'undefined' && this.bindings[event]) { - var i = 0; + // In case parse256(IL) >= n, proceed with the next value for i + if (pIL.compareTo(curve.n) >= 0) { + return this.derive(index + 1) + } - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; - } + // Private parent key -> private child key + var derivedKeyPair + if (!this.isNeutered()) { + // ki = parse256(IL) + kpar (mod n) + var ki = pIL.add(this.keyPair.d).mod(curve.n) - while (i < this.bindings[event].length) { - var _bindings$event$i = this.bindings[event][i]; - var handler = _bindings$event$i.handler; - var ctx = _bindings$event$i.ctx; - var once = _bindings$event$i.once; + // In case ki == 0, proceed with the next value for i + if (ki.signum() === 0) { + return this.derive(index + 1) + } - var context = ctx; - if (typeof context === 'undefined') { - context = this; - } + derivedKeyPair = new ECPair(ki, null, { + network: this.keyPair.network + }) - handler.apply(context, args); + // Public parent key -> public child key + } else { + // Ki = point(parse256(IL)) + Kpar + // = G*IL + Kpar + var Ki = curve.G.multiply(pIL).add(this.keyPair.Q) - if (once) { - this.bindings[event].splice(i, 1); - } else { - ++i; - } - } - } + // In case Ki is the point at infinity, proceed with the next value for i + if (curve.isInfinity(Ki)) { + return this.derive(index + 1) } - }]); - return Evented; -})(); + derivedKeyPair = new ECPair(null, Ki, { + network: this.keyPair.network + }) + } -TetherBase.Utils = { - getActualBoundingClientRect: getActualBoundingClientRect, - getScrollParents: getScrollParents, - getBounds: getBounds, - getOffsetParent: getOffsetParent, - extend: extend, - addClass: addClass, - removeClass: removeClass, - hasClass: hasClass, - updateClasses: updateClasses, - defer: defer, - flush: flush, - uniqueId: uniqueId, - Evented: Evented, - getScrollBarSize: getScrollBarSize, - removeUtilElements: removeUtilElements -}; + var hd = new HDNode(derivedKeyPair, IR) + hd.depth = this.depth + 1 + hd.index = index + hd.parentFingerprint = this.getFingerprint().readUInt32BE(0) -exports['default'] = TetherBase; -module.exports = exports['default']; + return hd +} -},{}]},{},[4])(4) -}); +HDNode.prototype.deriveHardened = function (index) { + typeforce(types.UInt31, index) -/***/ }), -/* 225 */ -/***/ (function(module, exports) { + // Only derives hardened private keys by default + return this.derive(index + HDNode.HIGHEST_BIT) +} -/** - * lodash (Custom Build) <https://lodash.com/> - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors <https://jquery.org/> - * Released under MIT license <https://lodash.com/license> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */ +// Private === not neutered +// Public === neutered +HDNode.prototype.isNeutered = function () { + return !(this.keyPair.d) +} -/** Used as references for various `Number` constants. */ -var NAN = 0 / 0; +HDNode.prototype.derivePath = function (path) { + typeforce(types.BIP32Path, path) -/** `Object#toString` result references. */ -var symbolTag = '[object Symbol]'; + var splitPath = path.split('/') + if (splitPath[0] === 'm') { + if (this.parentFingerprint) { + throw new Error('Not a master node') + } -/** Used to match leading and trailing whitespace. */ -var reTrim = /^\s+|\s+$/g; + splitPath = splitPath.slice(1) + } -/** Used to detect bad signed hexadecimal string values. */ -var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; + return splitPath.reduce(function (prevHd, indexStr) { + var index + if (indexStr.slice(-1) === "'") { + index = parseInt(indexStr.slice(0, -1), 10) + return prevHd.deriveHardened(index) + } else { + index = parseInt(indexStr, 10) + return prevHd.derive(index) + } + }, this) +} -/** Used to detect binary string values. */ -var reIsBinary = /^0b[01]+$/i; +module.exports = HDNode -/** Used to detect octal string values. */ -var reIsOctal = /^0o[0-7]+$/i; -/** Built-in method references without a dependency on `root`. */ -var freeParseInt = parseInt; +/***/ }), +/* 494 */ +/***/ (function(module, exports, __webpack_require__) { -/** Used for built-in method references. */ -var objectProto = Object.prototype; +var Buffer = __webpack_require__(7).Buffer +var baddress = __webpack_require__(114) +var bcrypto = __webpack_require__(44) +var bscript = __webpack_require__(14) +var networks = __webpack_require__(54) +var ops = __webpack_require__(16) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var scriptTypes = bscript.types +var SIGNABLE = [bscript.types.P2PKH, bscript.types.P2PK, bscript.types.MULTISIG] +var P2SH = SIGNABLE.concat([bscript.types.P2WPKH, bscript.types.P2WSH]) + +var ECPair = __webpack_require__(113) +var ECSignature = __webpack_require__(115) +var Transaction = __webpack_require__(112) + +function extractChunks (type, chunks, script) { + var pubKeys = [] + var signatures = [] + switch (type) { + case scriptTypes.P2PKH: + // if (redeemScript) throw new Error('Nonstandard... P2SH(P2PKH)') + pubKeys = chunks.slice(1) + signatures = chunks.slice(0, 1) + break + + case scriptTypes.P2PK: + pubKeys[0] = script ? bscript.pubKey.output.decode(script) : undefined + signatures = chunks.slice(0, 1) + break + + case scriptTypes.MULTISIG: + if (script) { + var multisig = bscript.multisig.output.decode(script) + pubKeys = multisig.pubKeys + } -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; + signatures = chunks.slice(1).map(function (chunk) { + return chunk.length === 0 ? undefined : chunk + }) + break + } -/** - * Checks if `value` is the - * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) - * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); + return { + pubKeys: pubKeys, + signatures: signatures + } } +function expandInput (scriptSig, witnessStack) { + if (scriptSig.length === 0 && witnessStack.length === 0) return {} + + var prevOutScript + var prevOutType + var scriptType + var script + var redeemScript + var witnessScript + var witnessScriptType + var redeemScriptType + var witness = false + var p2wsh = false + var p2sh = false + var witnessProgram + var chunks + + var scriptSigChunks = bscript.decompile(scriptSig) + var sigType = bscript.classifyInput(scriptSigChunks, true) + if (sigType === scriptTypes.P2SH) { + p2sh = true + redeemScript = scriptSigChunks[scriptSigChunks.length - 1] + redeemScriptType = bscript.classifyOutput(redeemScript) + prevOutScript = bscript.scriptHash.output.encode(bcrypto.hash160(redeemScript)) + prevOutType = scriptTypes.P2SH + script = redeemScript + } + + var classifyWitness = bscript.classifyWitness(witnessStack) + if (classifyWitness === scriptTypes.P2WSH) { + witnessScript = witnessStack[witnessStack.length - 1] + witnessScriptType = bscript.classifyOutput(witnessScript) + p2wsh = true + if (scriptSig.length === 0) { + prevOutScript = bscript.witnessScriptHash.output.encode(bcrypto.sha256(witnessScript)) + prevOutType = scriptTypes.P2WSH + if (typeof redeemScript !== 'undefined') { + throw new Error('Redeem script given when unnecessary') + } + // bare witness + } else { + if (!redeemScript) { + throw new Error('No redeemScript provided for P2WSH, but scriptSig non-empty') + } + witnessProgram = bscript.witnessScriptHash.output.encode(bcrypto.sha256(witnessScript)) + if (!redeemScript.equals(witnessProgram)) { + throw new Error('Redeem script didn\'t match witnessScript') + } + } -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; -} + if (SIGNABLE.indexOf(bscript.classifyOutput(witnessScript)) === -1) { + throw new Error('unsupported witness script') + } + script = witnessScript + scriptType = witnessScriptType + chunks = witnessStack.slice(0, -1) + } else if (classifyWitness === scriptTypes.P2WPKH) { + var key = witnessStack[witnessStack.length - 1] + var keyHash = bcrypto.hash160(key) + if (scriptSig.length === 0) { + prevOutScript = bscript.witnessPubKeyHash.output.encode(keyHash) + prevOutType = scriptTypes.P2WPKH + if (typeof redeemScript !== 'undefined') { + throw new Error('Redeem script given when unnecessary') + } + } else { + if (!redeemScript) { + throw new Error('No redeemScript provided for P2WPKH, but scriptSig wasn\'t empty') + } + witnessProgram = bscript.witnessPubKeyHash.output.encode(keyHash) + if (!redeemScript.equals(witnessProgram)) { + throw new Error('Redeem script did not have the right witness program') + } + } -/** - * Checks if `value` is classified as a `Symbol` primitive or object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. - * @example - * - * _.isSymbol(Symbol.iterator); - * // => true - * - * _.isSymbol('abc'); - * // => false - */ -function isSymbol(value) { - return typeof value == 'symbol' || - (isObjectLike(value) && objectToString.call(value) == symbolTag); -} + scriptType = scriptTypes.P2PKH + chunks = witnessStack + } else if (redeemScript) { + if (P2SH.indexOf(redeemScriptType) === -1) { + throw new Error('Bad redeemscript!') + } -/** - * Converts `value` to a number. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to process. - * @returns {number} Returns the number. - * @example - * - * _.toNumber(3.2); - * // => 3.2 - * - * _.toNumber(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toNumber(Infinity); - * // => Infinity - * - * _.toNumber('3.2'); - * // => 3.2 - */ -function toNumber(value) { - if (typeof value == 'number') { - return value; + script = redeemScript + scriptType = redeemScriptType + chunks = scriptSigChunks.slice(0, -1) + } else { + prevOutType = scriptType = bscript.classifyInput(scriptSig) + chunks = scriptSigChunks } - if (isSymbol(value)) { - return NAN; + + var expanded = extractChunks(scriptType, chunks, script) + + var result = { + pubKeys: expanded.pubKeys, + signatures: expanded.signatures, + prevOutScript: prevOutScript, + prevOutType: prevOutType, + signType: scriptType, + signScript: script, + witness: Boolean(witness) } - if (isObject(value)) { - var other = typeof value.valueOf == 'function' ? value.valueOf() : value; - value = isObject(other) ? (other + '') : other; + + if (p2sh) { + result.redeemScript = redeemScript + result.redeemScriptType = redeemScriptType } - if (typeof value != 'string') { - return value === 0 ? value : +value; + + if (p2wsh) { + result.witnessScript = witnessScript + result.witnessScriptType = witnessScriptType } - value = value.replace(reTrim, ''); - var isBinary = reIsBinary.test(value); - return (isBinary || reIsOctal.test(value)) - ? freeParseInt(value.slice(2), isBinary ? 2 : 8) - : (reIsBadHex.test(value) ? NAN : +value); + + return result } -module.exports = toNumber; +// could be done in expandInput, but requires the original Transaction for hashForSignature +function fixMultisigOrder (input, transaction, vin) { + if (input.redeemScriptType !== scriptTypes.MULTISIG || !input.redeemScript) return + if (input.pubKeys.length === input.signatures.length) return + var unmatched = input.signatures.concat() -/***/ }), -/* 226 */ -/***/ (function(module, exports, __webpack_require__) { + input.signatures = input.pubKeys.map(function (pubKey) { + var keyPair = ECPair.fromPublicKeyBuffer(pubKey) + var match -"use strict"; + // check for a signature + unmatched.some(function (signature, i) { + // skip if undefined || OP_0 + if (!signature) return false + // TODO: avoid O(n) hashForSignature + var parsed = ECSignature.parseScriptSignature(signature) + var hash = transaction.hashForSignature(vin, input.redeemScript, parsed.hashType) -var _CSSTransitionGroup = __webpack_require__(227); + // skip if signature does not match pubKey + if (!keyPair.verify(hash, parsed.signature)) return false -var _CSSTransitionGroup2 = _interopRequireDefault(_CSSTransitionGroup); + // remove matched signature from unmatched + unmatched[i] = undefined + match = signature -var _TransitionGroup = __webpack_require__(106); + return true + }) -var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); + return match + }) +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function expandOutput (script, scriptType, ourPubKey) { + typeforce(types.Buffer, script) -module.exports = { - TransitionGroup: _TransitionGroup2.default, - CSSTransitionGroup: _CSSTransitionGroup2.default -}; + var scriptChunks = bscript.decompile(script) + if (!scriptType) { + scriptType = bscript.classifyOutput(script) + } -/***/ }), -/* 227 */ -/***/ (function(module, exports, __webpack_require__) { + var pubKeys = [] -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { + switch (scriptType) { + // does our hash160(pubKey) match the output scripts? + case scriptTypes.P2PKH: + if (!ourPubKey) break -exports.__esModule = true; + var pkh1 = scriptChunks[2] + var pkh2 = bcrypto.hash160(ourPubKey) + if (pkh1.equals(pkh2)) pubKeys = [ourPubKey] + break -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + // does our hash160(pubKey) match the output scripts? + case scriptTypes.P2WPKH: + if (!ourPubKey) break -var _react = __webpack_require__(4); + var wpkh1 = scriptChunks[1] + var wpkh2 = bcrypto.hash160(ourPubKey) + if (wpkh1.equals(wpkh2)) pubKeys = [ourPubKey] + break -var _react2 = _interopRequireDefault(_react); + case scriptTypes.P2PK: + pubKeys = scriptChunks.slice(0, 1) + break -var _propTypes = __webpack_require__(9); + case scriptTypes.MULTISIG: + pubKeys = scriptChunks.slice(1, -2) + break -var _propTypes2 = _interopRequireDefault(_propTypes); + default: return { scriptType: scriptType } + } -var _TransitionGroup = __webpack_require__(106); + return { + pubKeys: pubKeys, + scriptType: scriptType, + signatures: pubKeys.map(function () { return undefined }) + } +} -var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); +function checkP2shInput (input, redeemScriptHash) { + if (input.prevOutType) { + if (input.prevOutType !== scriptTypes.P2SH) throw new Error('PrevOutScript must be P2SH') -var _CSSTransitionGroupChild = __webpack_require__(231); + var prevOutScriptScriptHash = bscript.decompile(input.prevOutScript)[1] + if (!prevOutScriptScriptHash.equals(redeemScriptHash)) throw new Error('Inconsistent hash160(RedeemScript)') + } +} -var _CSSTransitionGroupChild2 = _interopRequireDefault(_CSSTransitionGroupChild); +function checkP2WSHInput (input, witnessScriptHash) { + if (input.prevOutType) { + if (input.prevOutType !== scriptTypes.P2WSH) throw new Error('PrevOutScript must be P2WSH') -var _PropTypes = __webpack_require__(108); + var scriptHash = bscript.decompile(input.prevOutScript)[1] + if (!scriptHash.equals(witnessScriptHash)) throw new Error('Inconsistent sha25(WitnessScript)') + } +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function prepareInput (input, kpPubKey, redeemScript, witnessValue, witnessScript) { + var expanded + var prevOutType + var prevOutScript + + var p2sh = false + var p2shType + var redeemScriptHash + + var witness = false + var p2wsh = false + var witnessType + var witnessScriptHash + + var signType + var signScript + + if (redeemScript && witnessScript) { + redeemScriptHash = bcrypto.hash160(redeemScript) + witnessScriptHash = bcrypto.sha256(witnessScript) + checkP2shInput(input, redeemScriptHash) + + if (!redeemScript.equals(bscript.witnessScriptHash.output.encode(witnessScriptHash))) throw new Error('Witness script inconsistent with redeem script') + + expanded = expandOutput(witnessScript, undefined, kpPubKey) + if (!expanded.pubKeys) throw new Error('WitnessScript not supported "' + bscript.toASM(redeemScript) + '"') + prevOutType = bscript.types.P2SH + prevOutScript = bscript.scriptHash.output.encode(redeemScriptHash) + p2sh = witness = p2wsh = true + p2shType = bscript.types.P2WSH + signType = witnessType = expanded.scriptType + signScript = witnessScript + } else if (redeemScript) { + redeemScriptHash = bcrypto.hash160(redeemScript) + checkP2shInput(input, redeemScriptHash) + + expanded = expandOutput(redeemScript, undefined, kpPubKey) + if (!expanded.pubKeys) throw new Error('RedeemScript not supported "' + bscript.toASM(redeemScript) + '"') + + prevOutType = bscript.types.P2SH + prevOutScript = bscript.scriptHash.output.encode(redeemScriptHash) + p2sh = true + signType = p2shType = expanded.scriptType + signScript = redeemScript + witness = signType === bscript.types.P2WPKH + } else if (witnessScript) { + witnessScriptHash = bcrypto.sha256(witnessScript) + checkP2WSHInput(input, witnessScriptHash) + + expanded = expandOutput(witnessScript, undefined, kpPubKey) + if (!expanded.pubKeys) throw new Error('WitnessScript not supported "' + bscript.toASM(redeemScript) + '"') + + prevOutType = bscript.types.P2WSH + prevOutScript = bscript.witnessScriptHash.output.encode(witnessScriptHash) + witness = p2wsh = true + signType = witnessType = expanded.scriptType + signScript = witnessScript + } else if (input.prevOutType) { + // embedded scripts are not possible without a redeemScript + if (input.prevOutType === scriptTypes.P2SH || + input.prevOutType === scriptTypes.P2WSH) { + throw new Error('PrevOutScript is ' + input.prevOutType + ', requires redeemScript') + } + + prevOutType = input.prevOutType + prevOutScript = input.prevOutScript + expanded = expandOutput(input.prevOutScript, input.prevOutType, kpPubKey) + if (!expanded.pubKeys) return + + witness = (input.prevOutType === scriptTypes.P2WPKH) + signType = prevOutType + signScript = prevOutScript + } else { + prevOutScript = bscript.pubKeyHash.output.encode(bcrypto.hash160(kpPubKey)) + expanded = expandOutput(prevOutScript, scriptTypes.P2PKH, kpPubKey) + prevOutType = scriptTypes.P2PKH + witness = false + signType = prevOutType + signScript = prevOutScript + } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + if (witness && !types.Satoshi(witnessValue)) { + throw new Error('Input was witness but not given witness value') + } -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + if (signType === scriptTypes.P2WPKH) { + signScript = bscript.pubKeyHash.output.encode(bscript.witnessPubKeyHash.output.decode(signScript)) + } -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + if (p2sh) { + input.redeemScript = redeemScript + input.redeemScriptType = p2shType + } -var propTypes = { - transitionName: _PropTypes.nameShape.isRequired, + if (p2wsh) { + input.witnessScript = witnessScript + input.witnessScriptType = witnessType + } - transitionAppear: _propTypes2.default.bool, - transitionEnter: _propTypes2.default.bool, - transitionLeave: _propTypes2.default.bool, - transitionAppearTimeout: (0, _PropTypes.transitionTimeout)('Appear'), - transitionEnterTimeout: (0, _PropTypes.transitionTimeout)('Enter'), - transitionLeaveTimeout: (0, _PropTypes.transitionTimeout)('Leave') -}; + input.pubKeys = expanded.pubKeys + input.signatures = expanded.signatures + input.signScript = signScript + input.signType = signType + input.prevOutScript = prevOutScript + input.prevOutType = prevOutType + input.witness = witness +} -var defaultProps = { - transitionAppear: false, - transitionEnter: true, - transitionLeave: true -}; +function buildStack (type, signatures, pubKeys, allowIncomplete) { + if (type === scriptTypes.P2PKH) { + if (signatures.length === 1 && Buffer.isBuffer(signatures[0]) && pubKeys.length === 1) return bscript.pubKeyHash.input.encodeStack(signatures[0], pubKeys[0]) + } else if (type === scriptTypes.P2PK) { + if (signatures.length === 1 && Buffer.isBuffer(signatures[0])) return bscript.pubKey.input.encodeStack(signatures[0]) + } else if (type === scriptTypes.MULTISIG) { + if (signatures.length > 0) { + signatures = signatures.map(function (signature) { + return signature || ops.OP_0 + }) + if (!allowIncomplete) { + // remove blank signatures + signatures = signatures.filter(function (x) { return x !== ops.OP_0 }) + } -var CSSTransitionGroup = function (_React$Component) { - _inherits(CSSTransitionGroup, _React$Component); + return bscript.multisig.input.encodeStack(signatures /* see if it's necessary first */) + } + } else { + throw new Error('Not yet supported') + } - function CSSTransitionGroup() { - var _temp, _this, _ret; + if (!allowIncomplete) throw new Error('Not enough signatures provided') - _classCallCheck(this, CSSTransitionGroup); + return [] +} - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; +function buildInput (input, allowIncomplete) { + var scriptType = input.prevOutType + var sig = [] + var witness = [] + if (SIGNABLE.indexOf(scriptType) !== -1) { + sig = buildStack(scriptType, input.signatures, input.pubKeys, allowIncomplete) + } + + var p2sh = false + if (scriptType === bscript.types.P2SH) { + // We can remove this error later when we have a guarantee prepareInput + // rejects unsignable scripts - it MUST be signable at this point. + if (P2SH.indexOf(input.redeemScriptType) === -1) { + throw new Error('Impossible to sign this type') + } + p2sh = true + if (SIGNABLE.indexOf(input.redeemScriptType) !== -1) { + sig = buildStack(input.redeemScriptType, input.signatures, input.pubKeys, allowIncomplete) + } + // If it wasn't SIGNABLE, it's witness, defer to that + scriptType = input.redeemScriptType + } + + if (scriptType === bscript.types.P2WPKH) { + // P2WPKH is a special case of P2PKH + witness = buildStack(bscript.types.P2PKH, input.signatures, input.pubKeys, allowIncomplete) + } else if (scriptType === bscript.types.P2WSH) { + // We can remove this check later + if (SIGNABLE.indexOf(input.witnessScriptType) !== -1) { + witness = buildStack(input.witnessScriptType, input.signatures, input.pubKeys, allowIncomplete) + witness.push(input.witnessScript) + } else { + // We can remove this error later when we have a guarantee prepareInput + // rejects unsignble scripts - it MUST be signable at this point. + throw new Error() } - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this._wrapChild = function (child) { - return _react2.default.createElement(_CSSTransitionGroupChild2.default, { - name: _this.props.transitionName, - appear: _this.props.transitionAppear, - enter: _this.props.transitionEnter, - leave: _this.props.transitionLeave, - appearTimeout: _this.props.transitionAppearTimeout, - enterTimeout: _this.props.transitionEnterTimeout, - leaveTimeout: _this.props.transitionLeaveTimeout - }, child); - }, _temp), _possibleConstructorReturn(_this, _ret); + scriptType = input.witnessScriptType } - // We need to provide this childFactory so that - // ReactCSSTransitionGroupChild can receive updates to name, enter, and - // leave while it is leaving. + // append redeemScript if necessary + if (p2sh) { + sig.push(input.redeemScript) + } + return { + type: scriptType, + script: bscript.compile(sig), + witness: witness + } +} - CSSTransitionGroup.prototype.render = function render() { - return _react2.default.createElement(_TransitionGroup2.default, _extends({}, this.props, { childFactory: this._wrapChild })); - }; +function TransactionBuilder (network, maximumFeeRate) { + this.prevTxMap = {} + this.network = network || networks.bitcoin - return CSSTransitionGroup; -}(_react2.default.Component); + // WARNING: This is __NOT__ to be relied on, its just another potential safety mechanism (safety in-depth) + this.maximumFeeRate = maximumFeeRate || 1000 -CSSTransitionGroup.displayName = 'CSSTransitionGroup'; + this.inputs = [] + this.tx = new Transaction() +} +TransactionBuilder.prototype.setLockTime = function (locktime) { + typeforce(types.UInt32, locktime) -CSSTransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; -CSSTransitionGroup.defaultProps = defaultProps; + // if any signatures exist, throw + if (this.inputs.some(function (input) { + if (!input.signatures) return false -exports.default = CSSTransitionGroup; -module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return input.signatures.some(function (s) { return s }) + })) { + throw new Error('No, this would invalidate signatures') + } -/***/ }), -/* 228 */ -/***/ (function(module, exports) { + this.tx.locktime = locktime +} - -module.exports = function chain(){ - var len = arguments.length - var args = []; - - for (var i = 0; i < len; i++) - args[i] = arguments[i] - - args = args.filter(function(fn){ return fn != null }) - - if (args.length === 0) return undefined - if (args.length === 1) return args[0] - - return args.reduce(function(current, next){ - return function chainedFunction() { - current.apply(this, arguments); - next.apply(this, arguments); - }; - }) -} +TransactionBuilder.prototype.setVersion = function (version) { + typeforce(types.UInt32, version) + // XXX: this might eventually become more complex depending on what the versions represent + this.tx.version = version +} -/***/ }), -/* 229 */ -/***/ (function(module, exports, __webpack_require__) { +TransactionBuilder.fromTransaction = function (transaction, network) { + var txb = new TransactionBuilder(network) + + // Copy transaction fields + txb.setVersion(transaction.version) + txb.setLockTime(transaction.locktime) + + // Copy outputs (done first to avoid signature invalidation) + transaction.outs.forEach(function (txOut) { + txb.addOutput(txOut.script, txOut.value) + }) + + // Copy inputs + transaction.ins.forEach(function (txIn) { + txb.__addInputUnsafe(txIn.hash, txIn.index, { + sequence: txIn.sequence, + script: txIn.script, + witness: txIn.witness + }) + }) + + // fix some things not possible through the public API + txb.inputs.forEach(function (input, i) { + fixMultisigOrder(input, transaction, i) + }) + + return txb +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +TransactionBuilder.prototype.addInput = function (txHash, vout, sequence, prevOutScript) { + if (!this.__canModifyInputs()) { + throw new Error('No, this would invalidate signatures') + } + var value + // is it a hex string? + if (typeof txHash === 'string') { + // transaction hashs's are displayed in reverse order, un-reverse it + txHash = Buffer.from(txHash, 'hex').reverse() -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ + // is it a Transaction object? + } else if (txHash instanceof Transaction) { + var txOut = txHash.outs[vout] + prevOutScript = txOut.script + value = txOut.value -var warning = function() {}; + txHash = txHash.getHash() + } -if (process.env.NODE_ENV !== 'production') { - warning = function(condition, format, args) { - var len = arguments.length; - args = new Array(len > 2 ? len - 2 : 0); - for (var key = 2; key < len; key++) { - args[key - 2] = arguments[key]; - } - if (format === undefined) { - throw new Error( - '`warning(condition, format, ...args)` requires a warning ' + - 'message argument' - ); - } + return this.__addInputUnsafe(txHash, vout, { + sequence: sequence, + prevOutScript: prevOutScript, + value: value + }) +} - if (format.length < 10 || (/^[s\W]*$/).test(format)) { - throw new Error( - 'The warning format should be able to uniquely identify this ' + - 'warning. Please, use a more descriptive format than: ' + format - ); - } +TransactionBuilder.prototype.__addInputUnsafe = function (txHash, vout, options) { + if (Transaction.isCoinbaseHash(txHash)) { + throw new Error('coinbase inputs not supported') + } - if (!condition) { - var argIndex = 0; - var message = 'Warning: ' + - format.replace(/%s/g, function() { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch(x) {} - } - }; -} + var prevTxOut = txHash.toString('hex') + ':' + vout + if (this.prevTxMap[prevTxOut] !== undefined) throw new Error('Duplicate TxOut: ' + prevTxOut) -module.exports = warning; + var input = {} -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // derive what we can from the scriptSig + if (options.script !== undefined) { + input = expandInput(options.script, options.witness || []) + } -/***/ }), -/* 230 */ -/***/ (function(module, exports, __webpack_require__) { + // if an input value was given, retain it + if (options.value !== undefined) { + input.value = options.value + } -"use strict"; + // derive what we can from the previous transactions output script + if (!input.prevOutScript && options.prevOutScript) { + var prevOutType + if (!input.pubKeys && !input.signatures) { + var expanded = expandOutput(options.prevOutScript) -exports.__esModule = true; -exports.getChildMapping = getChildMapping; -exports.mergeChildMappings = mergeChildMappings; + if (expanded.pubKeys) { + input.pubKeys = expanded.pubKeys + input.signatures = expanded.signatures + } -var _react = __webpack_require__(4); + prevOutType = expanded.scriptType + } -/** - * Given `this.props.children`, return an object mapping key to child. - * - * @param {*} children `this.props.children` - * @return {object} Mapping of key to child - */ -function getChildMapping(children) { - if (!children) { - return children; + input.prevOutScript = options.prevOutScript + input.prevOutType = prevOutType || bscript.classifyOutput(options.prevOutScript) } - var result = {}; - _react.Children.map(children, function (child) { - return child; - }).forEach(function (child) { - result[child.key] = child; - }); - return result; + + var vin = this.tx.addInput(txHash, vout, options.sequence, options.scriptSig) + this.inputs[vin] = input + this.prevTxMap[prevTxOut] = vin + + return vin } -/** - * When you're adding or removing children some may be added or removed in the - * same render pass. We want to show *both* since we want to simultaneously - * animate elements in and out. This function takes a previous set of keys - * and a new set of keys and merges them with its best guess of the correct - * ordering. In the future we may expose some of the utilities in - * ReactMultiChild to make this easy, but for now React itself does not - * directly have this concept of the union of prevChildren and nextChildren - * so we implement it here. - * - * @param {object} prev prev children as returned from - * `ReactTransitionChildMapping.getChildMapping()`. - * @param {object} next next children as returned from - * `ReactTransitionChildMapping.getChildMapping()`. - * @return {object} a key set that contains all keys in `prev` and all keys - * in `next` in a reasonable order. - */ -function mergeChildMappings(prev, next) { - prev = prev || {}; - next = next || {}; +TransactionBuilder.prototype.addOutput = function (scriptPubKey, value) { + if (!this.__canModifyOutputs()) { + throw new Error('No, this would invalidate signatures') + } - function getValueForKey(key) { - if (next.hasOwnProperty(key)) { - return next[key]; - } + // Attempt to get a script if it's a base58 address string + if (typeof scriptPubKey === 'string') { + scriptPubKey = baddress.toOutputScript(scriptPubKey, this.network) + } - return prev[key]; + return this.tx.addOutput(scriptPubKey, value) +} + +TransactionBuilder.prototype.build = function () { + return this.__build(false) +} +TransactionBuilder.prototype.buildIncomplete = function () { + return this.__build(true) +} + +TransactionBuilder.prototype.__build = function (allowIncomplete) { + if (!allowIncomplete) { + if (!this.tx.ins.length) throw new Error('Transaction has no inputs') + if (!this.tx.outs.length) throw new Error('Transaction has no outputs') } - // For each key of `next`, the list of keys to insert before that key in - // the combined list - var nextKeysPending = {}; + var tx = this.tx.clone() + // Create script signatures from inputs + this.inputs.forEach(function (input, i) { + var scriptType = input.witnessScriptType || input.redeemScriptType || input.prevOutType + if (!scriptType && !allowIncomplete) throw new Error('Transaction is not complete') + var result = buildInput(input, allowIncomplete) - var pendingKeys = []; - for (var prevKey in prev) { - if (next.hasOwnProperty(prevKey)) { - if (pendingKeys.length) { - nextKeysPending[prevKey] = pendingKeys; - pendingKeys = []; + // skip if no result + if (!allowIncomplete) { + if (SIGNABLE.indexOf(result.type) === -1 && result.type !== bscript.types.P2WPKH) { + throw new Error(result.type + ' not supported') } - } else { - pendingKeys.push(prevKey); } - } - var i = void 0; - var childMapping = {}; - for (var nextKey in next) { - if (nextKeysPending.hasOwnProperty(nextKey)) { - for (i = 0; i < nextKeysPending[nextKey].length; i++) { - var pendingNextKey = nextKeysPending[nextKey][i]; - childMapping[nextKeysPending[nextKey][i]] = getValueForKey(pendingNextKey); - } + tx.setInputScript(i, result.script) + tx.setWitness(i, result.witness) + }) + + if (!allowIncomplete) { + // do not rely on this, its merely a last resort + if (this.__overMaximumFees(tx.byteLength())) { + throw new Error('Transaction has absurd fees') } - childMapping[nextKey] = getValueForKey(nextKey); } - // Finally, add the keys which didn't appear before any key in `next` - for (i = 0; i < pendingKeys.length; i++) { - childMapping[pendingKeys[i]] = getValueForKey(pendingKeys[i]); - } + return tx +} - return childMapping; +function canSign (input) { + return input.prevOutScript !== undefined && + input.signScript !== undefined && + input.pubKeys !== undefined && + input.signatures !== undefined && + input.signatures.length === input.pubKeys.length && + input.pubKeys.length > 0 && + input.witness !== undefined } -/***/ }), -/* 231 */ -/***/ (function(module, exports, __webpack_require__) { +TransactionBuilder.prototype.sign = function (vin, keyPair, redeemScript, hashType, witnessValue, witnessScript) { + if (keyPair.network !== this.network) throw new Error('Inconsistent network') + if (!this.inputs[vin]) throw new Error('No input at index: ' + vin) + hashType = hashType || Transaction.SIGHASH_ALL -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { + var input = this.inputs[vin] -exports.__esModule = true; + // if redeemScript was previously provided, enforce consistency + if (input.redeemScript !== undefined && + redeemScript && + !input.redeemScript.equals(redeemScript)) { + throw new Error('Inconsistent redeemScript') + } -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + var kpPubKey = keyPair.getPublicKeyBuffer() + if (!canSign(input)) { + prepareInput(input, kpPubKey, redeemScript, witnessValue, witnessScript) + if (!canSign(input)) throw Error(input.prevOutType + ' not supported') + } -var _addClass = __webpack_require__(232); + // ready to sign + var signatureHash + if (input.witness) { + signatureHash = this.tx.hashForWitnessV0(vin, input.signScript, witnessValue, hashType) + } else { + signatureHash = this.tx.hashForSignature(vin, input.signScript, hashType) + } + // enforce in order signing of public keys + var signed = input.pubKeys.some(function (pubKey, i) { + if (!kpPubKey.equals(pubKey)) return false + if (input.signatures[i]) throw new Error('Signature already exists') -var _addClass2 = _interopRequireDefault(_addClass); + input.signatures[i] = keyPair.sign(signatureHash).toScriptSignature(hashType) + return true + }) -var _removeClass = __webpack_require__(234); + if (!signed) throw new Error('Key pair cannot sign for this input') +} -var _removeClass2 = _interopRequireDefault(_removeClass); +function signatureHashType (buffer) { + return buffer.readUInt8(buffer.length - 1) +} -var _requestAnimationFrame = __webpack_require__(235); +TransactionBuilder.prototype.__canModifyInputs = function () { + return this.inputs.every(function (input) { + // any signatures? + if (input.signatures === undefined) return true -var _requestAnimationFrame2 = _interopRequireDefault(_requestAnimationFrame); + return input.signatures.every(function (signature) { + if (!signature) return true + var hashType = signatureHashType(signature) -var _properties = __webpack_require__(236); + // if SIGHASH_ANYONECANPAY is set, signatures would not + // be invalidated by more inputs + return hashType & Transaction.SIGHASH_ANYONECANPAY + }) + }) +} -var _react = __webpack_require__(4); +TransactionBuilder.prototype.__canModifyOutputs = function () { + var nInputs = this.tx.ins.length + var nOutputs = this.tx.outs.length -var _react2 = _interopRequireDefault(_react); + return this.inputs.every(function (input) { + if (input.signatures === undefined) return true -var _propTypes = __webpack_require__(9); + return input.signatures.every(function (signature) { + if (!signature) return true + var hashType = signatureHashType(signature) -var _propTypes2 = _interopRequireDefault(_propTypes); + var hashTypeMod = hashType & 0x1f + if (hashTypeMod === Transaction.SIGHASH_NONE) return true + if (hashTypeMod === Transaction.SIGHASH_SINGLE) { + // if SIGHASH_SINGLE is set, and nInputs > nOutputs + // some signatures would be invalidated by the addition + // of more outputs + return nInputs <= nOutputs + } + }) + }) +} -var _reactDom = __webpack_require__(28); +TransactionBuilder.prototype.__overMaximumFees = function (bytes) { + // not all inputs will have .value defined + var incoming = this.inputs.reduce(function (a, x) { return a + (x.value >>> 0) }, 0) -var _PropTypes = __webpack_require__(108); + // but all outputs do, and if we have any input value + // we can immediately determine if the outputs are too small + var outgoing = this.tx.outs.reduce(function (a, x) { return a + x.value }, 0) + var fee = incoming - outgoing + var feeRate = fee / bytes -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + return feeRate > this.maximumFeeRate +} -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +module.exports = TransactionBuilder -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +/***/ }), +/* 495 */ +/***/ (function(module, exports, __webpack_require__) { -var events = []; -if (_properties.transitionEnd) events.push(_properties.transitionEnd); -if (_properties.animationEnd) events.push(_properties.animationEnd); +module.exports = { + Account: __webpack_require__(496), + Chain: __webpack_require__(210), + discovery: __webpack_require__(209) +} -function addEndListener(node, listener) { - if (events.length) { - events.forEach(function (e) { - return node.addEventListener(e, listener, false); - }); - } else { - setTimeout(listener, 0); - } - return function () { - if (!events.length) return; - events.forEach(function (e) { - return node.removeEventListener(e, listener, false); - }); - }; +/***/ }), +/* 496 */ +/***/ (function(module, exports, __webpack_require__) { + +var bitcoinjs = __webpack_require__(200) +var discovery = __webpack_require__(209) + +var Chain = __webpack_require__(210) + +function Account (chains) { + this.chains = chains } -var propTypes = { - children: _propTypes2.default.node, - name: _PropTypes.nameShape.isRequired, +Account.fromJSON = function (json, network) { + var chains = json.map(function (j) { + var node = bitcoinjs.HDNode.fromBase58(j.node, network) - // Once we require timeouts to be specified, we can remove the - // boolean flags (appear etc.) and just accept a number - // or a bool for the timeout flags (appearTimeout etc.) - appear: _propTypes2.default.bool, - enter: _propTypes2.default.bool, - leave: _propTypes2.default.bool, - appearTimeout: _propTypes2.default.number, - enterTimeout: _propTypes2.default.number, - leaveTimeout: _propTypes2.default.number -}; + var chain = new Chain(node, j.k) + chain.map = j.map -var CSSTransitionGroupChild = function (_React$Component) { - _inherits(CSSTransitionGroupChild, _React$Component); + // derive from k map + chain.addresses = Object.keys(chain.map).sort(function (a, b) { + return chain.map[a] - chain.map[b] + }) + + return chain + }) + + return new Account(chains) +} + +Account.prototype.containsAddress = function (address) { + return this.chains.some(function (chain) { + return chain.find(address) !== undefined + }) +} - function CSSTransitionGroupChild() { - var _temp, _this, _ret; +// optional parents argument for private key escalation +Account.prototype.derive = function (address, parents) { + var derived - _classCallCheck(this, CSSTransitionGroupChild); + this.chains.some(function (chain, i) { + derived = chain.derive(address, parents && parents[i]) + return derived + }) - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } + return derived +} - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.componentWillAppear = function (done) { - if (_this.props.appear) { - _this.transition('appear', done, _this.props.appearTimeout); - } else { - done(); - } - }, _this.componentWillEnter = function (done) { - if (_this.props.enter) { - _this.transition('enter', done, _this.props.enterTimeout); - } else { - done(); - } - }, _this.componentWillLeave = function (done) { - if (_this.props.leave) { - _this.transition('leave', done, _this.props.leaveTimeout); - } else { - done(); - } - }, _temp), _possibleConstructorReturn(_this, _ret); - } +Account.prototype.discoverChain = function (i, gapLimit, queryCallback, callback) { + var chains = this.chains + var chain = chains[i].clone() - CSSTransitionGroupChild.prototype.componentWillMount = function componentWillMount() { - this.classNameAndNodeQueue = []; - this.transitionTimeouts = []; - }; + discovery(chain, gapLimit, queryCallback, function (err, used, checked) { + if (err) return callback(err) - CSSTransitionGroupChild.prototype.componentWillUnmount = function componentWillUnmount() { - this.unmounted = true; + // throw away EACH unused address AFTER the last unused address + var unused = checked - used + for (var j = 1; j < unused; ++j) chain.pop() - if (this.timeout) { - clearTimeout(this.timeout); - } - this.transitionTimeouts.forEach(function (timeout) { - clearTimeout(timeout); - }); + // override the internal chain + chains[i] = chain - this.classNameAndNodeQueue.length = 0; - }; + callback() + }) +} - CSSTransitionGroupChild.prototype.transition = function transition(animationType, finishCallback, timeout) { - var node = (0, _reactDom.findDOMNode)(this); +Account.prototype.getAllAddresses = function () { + return [].concat.apply([], this.chains.map(function (chain) { + return chain.getAll() + })) +} - if (!node) { - if (finishCallback) { - finishCallback(); - } - return; - } +Account.prototype.getChain = function (i) { return this.chains[i] } +Account.prototype.getChains = function () { return this.chains } +Account.prototype.getChainAddress = function (i) { return this.chains[i].get() } +Account.prototype.getNetwork = function () { return this.chains[0].getParent().keyPair.network } - var className = this.props.name[animationType] || this.props.name + '-' + animationType; - var activeClassName = this.props.name[animationType + 'Active'] || className + '-active'; - var timer = null; - var removeListeners = void 0; +Account.prototype.isChainAddress = function (i, address) { + return this.chains[i].find(address) !== undefined +} - (0, _addClass2.default)(node, className); +Account.prototype.nextChainAddress = function (i) { + return this.chains[i].next() +} - // Need to do this to actually trigger a transition. - this.queueClassAndNode(activeClassName, node); +Account.prototype.toJSON = function () { + return this.chains.map(function (chain) { + return { + k: chain.k, + map: chain.map, + node: chain.getParent().toBase58() + } + }) +} - // Clean-up the animation after the specified delay - var finish = function finish(e) { - if (e && e.target !== node) { - return; - } +module.exports = Account - clearTimeout(timer); - if (removeListeners) removeListeners(); - (0, _removeClass2.default)(node, className); - (0, _removeClass2.default)(node, activeClassName); +/***/ }), +/* 497 */ +/***/ (function(module, exports, __webpack_require__) { - if (removeListeners) removeListeners(); +var __WEBPACK_AMD_DEFINE_RESULT__;/* FileSaver.js + * A saveAs() FileSaver implementation. + * 1.3.2 + * 2016-06-16 18:25:19 + * + * By Eli Grey, http://eligrey.com + * License: MIT + * See https://github.com/eligrey/FileSaver.js/blob/master/LICENSE.md + */ - // Usually this optional callback is used for informing an owner of - // a leave animation and telling it to remove the child. - if (finishCallback) { - finishCallback(); - } - }; +/*global self */ +/*jslint bitwise: true, indent: 4, laxbreak: true, laxcomma: true, smarttabs: true, plusplus: true */ - if (timeout) { - timer = setTimeout(finish, timeout); - this.transitionTimeouts.push(timer); - } else if (_properties.transitionEnd) { - removeListeners = addEndListener(node, finish); - } - }; +/*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */ - CSSTransitionGroupChild.prototype.queueClassAndNode = function queueClassAndNode(className, node) { - var _this2 = this; +var saveAs = saveAs || (function(view) { + "use strict"; + // IE <10 is explicitly unsupported + if (typeof view === "undefined" || typeof navigator !== "undefined" && /MSIE [1-9]\./.test(navigator.userAgent)) { + return; + } + var + doc = view.document + // only get URL when necessary in case Blob.js hasn't overridden it yet + , get_URL = function() { + return view.URL || view.webkitURL || view; + } + , save_link = doc.createElementNS("http://www.w3.org/1999/xhtml", "a") + , can_use_save_link = "download" in save_link + , click = function(node) { + var event = new MouseEvent("click"); + node.dispatchEvent(event); + } + , is_safari = /constructor/i.test(view.HTMLElement) || view.safari + , is_chrome_ios =/CriOS\/[\d]+/.test(navigator.userAgent) + , throw_outside = function(ex) { + (view.setImmediate || view.setTimeout)(function() { + throw ex; + }, 0); + } + , force_saveable_type = "application/octet-stream" + // the Blob API is fundamentally broken as there is no "downloadfinished" event to subscribe to + , arbitrary_revoke_timeout = 1000 * 40 // in ms + , revoke = function(file) { + var revoker = function() { + if (typeof file === "string") { // file is an object URL + get_URL().revokeObjectURL(file); + } else { // file is a File + file.remove(); + } + }; + setTimeout(revoker, arbitrary_revoke_timeout); + } + , dispatch = function(filesaver, event_types, event) { + event_types = [].concat(event_types); + var i = event_types.length; + while (i--) { + var listener = filesaver["on" + event_types[i]]; + if (typeof listener === "function") { + try { + listener.call(filesaver, event || filesaver); + } catch (ex) { + throw_outside(ex); + } + } + } + } + , auto_bom = function(blob) { + // prepend BOM for UTF-8 XML and text/* types (including HTML) + // note: your browser will automatically convert UTF-16 U+FEFF to EF BB BF + if (/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(blob.type)) { + return new Blob([String.fromCharCode(0xFEFF), blob], {type: blob.type}); + } + return blob; + } + , FileSaver = function(blob, name, no_auto_bom) { + if (!no_auto_bom) { + blob = auto_bom(blob); + } + // First try a.download, then web filesystem, then object URLs + var + filesaver = this + , type = blob.type + , force = type === force_saveable_type + , object_url + , dispatch_all = function() { + dispatch(filesaver, "writestart progress write writeend".split(" ")); + } + // on any filesys errors revert to saving with object URLs + , fs_error = function() { + if ((is_chrome_ios || (force && is_safari)) && view.FileReader) { + // Safari doesn't allow downloading of blob urls + var reader = new FileReader(); + reader.onloadend = function() { + var url = is_chrome_ios ? reader.result : reader.result.replace(/^data:[^;]*;/, 'data:attachment/file;'); + var popup = view.open(url, '_blank'); + if(!popup) view.location.href = url; + url=undefined; // release reference before dispatching + filesaver.readyState = filesaver.DONE; + dispatch_all(); + }; + reader.readAsDataURL(blob); + filesaver.readyState = filesaver.INIT; + return; + } + // don't create more object URLs than needed + if (!object_url) { + object_url = get_URL().createObjectURL(blob); + } + if (force) { + view.location.href = object_url; + } else { + var opened = view.open(object_url, "_blank"); + if (!opened) { + // Apple does not allow window.open, see https://developer.apple.com/library/safari/documentation/Tools/Conceptual/SafariExtensionGuide/WorkingwithWindowsandTabs/WorkingwithWindowsandTabs.html + view.location.href = object_url; + } + } + filesaver.readyState = filesaver.DONE; + dispatch_all(); + revoke(object_url); + } + ; + filesaver.readyState = filesaver.INIT; + + if (can_use_save_link) { + object_url = get_URL().createObjectURL(blob); + setTimeout(function() { + save_link.href = object_url; + save_link.download = name; + click(save_link); + dispatch_all(); + revoke(object_url); + filesaver.readyState = filesaver.DONE; + }); + return; + } - this.classNameAndNodeQueue.push({ - className: className, - node: node - }); + fs_error(); + } + , FS_proto = FileSaver.prototype + , saveAs = function(blob, name, no_auto_bom) { + return new FileSaver(blob, name || blob.name || "download", no_auto_bom); + } + ; + // IE 10+ (native saveAs) + if (typeof navigator !== "undefined" && navigator.msSaveOrOpenBlob) { + return function(blob, name, no_auto_bom) { + name = name || blob.name || "download"; + + if (!no_auto_bom) { + blob = auto_bom(blob); + } + return navigator.msSaveOrOpenBlob(blob, name); + }; + } - if (!this.rafHandle) { - this.rafHandle = (0, _requestAnimationFrame2.default)(function () { - return _this2.flushClassNameAndNodeQueue(); - }); - } - }; + FS_proto.abort = function(){}; + FS_proto.readyState = FS_proto.INIT = 0; + FS_proto.WRITING = 1; + FS_proto.DONE = 2; + + FS_proto.error = + FS_proto.onwritestart = + FS_proto.onprogress = + FS_proto.onwrite = + FS_proto.onabort = + FS_proto.onerror = + FS_proto.onwriteend = + null; + + return saveAs; +}( + typeof self !== "undefined" && self + || typeof window !== "undefined" && window + || this.content +)); +// `self` is undefined in Firefox for Android content script context +// while `this` is nsIContentFrameMessageManager +// with an attribute `content` that corresponds to the window + +if (typeof module !== "undefined" && module.exports) { + module.exports.saveAs = saveAs; +} else if (("function" !== "undefined" && __webpack_require__(498) !== null) && (__webpack_require__(499) !== null)) { + !(__WEBPACK_AMD_DEFINE_RESULT__ = function() { + return saveAs; + }.call(exports, __webpack_require__, exports, module), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); +} - CSSTransitionGroupChild.prototype.flushClassNameAndNodeQueue = function flushClassNameAndNodeQueue() { - if (!this.unmounted) { - this.classNameAndNodeQueue.forEach(function (obj) { - // This is for to force a repaint, - // which is necessary in order to transition styles when adding a class name. - /* eslint-disable no-unused-expressions */ - obj.node.scrollTop; - /* eslint-enable no-unused-expressions */ - (0, _addClass2.default)(obj.node, obj.className); - }); - } - this.classNameAndNodeQueue.length = 0; - this.rafHandle = null; - }; - CSSTransitionGroupChild.prototype.render = function render() { - var props = _extends({}, this.props); - delete props.name; - delete props.appear; - delete props.enter; - delete props.leave; - delete props.appearTimeout; - delete props.enterTimeout; - delete props.leaveTimeout; - delete props.children; - return _react2.default.cloneElement(_react2.default.Children.only(this.props.children), props); - }; +/***/ }), +/* 498 */ +/***/ (function(module, exports) { - return CSSTransitionGroupChild; -}(_react2.default.Component); +module.exports = function() { + throw new Error("define cannot be used indirect"); +}; -CSSTransitionGroupChild.displayName = 'CSSTransitionGroupChild'; +/***/ }), +/* 499 */ +/***/ (function(module, exports) { -CSSTransitionGroupChild.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; +/* WEBPACK VAR INJECTION */(function(__webpack_amd_options__) {/* globals __webpack_amd_options__ */ +module.exports = __webpack_amd_options__; -exports.default = CSSTransitionGroupChild; -module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, {})) /***/ }), -/* 232 */ +/* 500 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { - value: true + value: true }); -exports.default = addClass; -var _hasClass = __webpack_require__(233); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); -var _hasClass2 = _interopRequireDefault(_hasClass); +var _react2 = _interopRequireDefault(_react); + +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -function addClass(element, className) { - if (element.classList) element.classList.add(className);else if (!(0, _hasClass2.default)(element)) element.className = element.className + ' ' + className; -} +var MdRefresh = function MdRefresh(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm29.5 10.5l3.9-3.9v11.8h-11.8l5.4-5.4c-1.8-1.8-4.3-3-7-3-5.5 0-10 4.5-10 10s4.5 10 10 10c4.4 0 8.1-2.7 9.5-6.6h3.4c-1.5 5.7-6.6 10-12.9 10-7.3 0-13.3-6.1-13.3-13.4s6-13.4 13.3-13.4c3.7 0 7 1.5 9.5 3.9z' }) + ) + ); +}; + +exports.default = MdRefresh; module.exports = exports['default']; /***/ }), -/* 233 */ +/* 501 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { - value: true + value: true }); -exports.default = hasClass; -function hasClass(element, className) { - if (element.classList) return !!className && element.classList.contains(className);else return (" " + element.className + " ").indexOf(" " + className + " ") !== -1; -} -module.exports = exports["default"]; + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var MdContentCopy = function MdContentCopy(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm31.6 35v-23.4h-18.2v23.4h18.2z m0-26.6c1.8 0 3.4 1.4 3.4 3.2v23.4c0 1.8-1.6 3.4-3.4 3.4h-18.2c-1.8 0-3.4-1.6-3.4-3.4v-23.4c0-1.8 1.6-3.2 3.4-3.2h18.2z m-5-6.8v3.4h-20v23.4h-3.2v-23.4c0-1.8 1.4-3.4 3.2-3.4h20z' }) + ) + ); +}; + +exports.default = MdContentCopy; +module.exports = exports['default']; /***/ }), -/* 234 */ +/* 502 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -module.exports = function removeClass(element, className) { - if (element.classList) element.classList.remove(className);else element.className = element.className.replace(new RegExp('(^|\\s)' + className + '(?:\\s|$)', 'g'), '$1').replace(/\s+/g, ' ').replace(/^\s*|\s*$/g, ''); +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var MdSettings = function MdSettings(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm20 25.9c3.2 0 5.9-2.7 5.9-5.9s-2.7-5.9-5.9-5.9-5.9 2.7-5.9 5.9 2.7 5.9 5.9 5.9z m12.4-4.3l3.5 2.8c0.4 0.2 0.4 0.7 0.2 1.1l-3.4 5.8c-0.2 0.3-0.6 0.4-1 0.3l-4.1-1.7c-0.9 0.7-1.8 1.3-2.8 1.7l-0.7 4.3c0 0.4-0.4 0.7-0.7 0.7h-6.8c-0.4 0-0.7-0.3-0.7-0.7l-0.7-4.3c-1-0.4-1.9-1-2.8-1.7l-4.1 1.7c-0.4 0.1-0.8 0-1-0.3l-3.4-5.8c-0.2-0.4-0.2-0.9 0.2-1.1l3.5-2.8c-0.1-0.5-0.1-1.1-0.1-1.6s0-1.1 0.1-1.6l-3.5-2.8c-0.4-0.2-0.4-0.7-0.2-1.1l3.4-5.7c0.2-0.4 0.6-0.5 1-0.4l4.1 1.7c0.9-0.6 1.8-1.3 2.8-1.7l0.7-4.3c0-0.4 0.3-0.7 0.7-0.7h6.8c0.3 0 0.7 0.3 0.7 0.7l0.7 4.3c1 0.4 1.9 1 2.8 1.7l4.1-1.7c0.4-0.1 0.8 0 1 0.4l3.4 5.7c0.2 0.4 0.2 0.9-0.2 1.1l-3.5 2.8c0.1 0.5 0.1 1.1 0.1 1.6s0 1.1-0.1 1.6z' }) + ) + ); }; +exports.default = MdSettings; +module.exports = exports['default']; + /***/ }), -/* 235 */ +/* 503 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { - value: true + value: true }); -var _inDOM = __webpack_require__(107); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _inDOM2 = _interopRequireDefault(_inDOM); +var _react = __webpack_require__(6); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var _react2 = _interopRequireDefault(_react); -var vendors = ['', 'webkit', 'moz', 'o', 'ms']; -var cancel = 'clearTimeout'; -var raf = fallback; -var compatRaf = void 0; +var _reactIconBase = __webpack_require__(35); -var getKey = function getKey(vendor, k) { - return vendor + (!vendor ? k : k[0].toUpperCase() + k.substr(1)) + 'AnimationFrame'; +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var FaRepeat = function FaRepeat(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm37.3 5.7v10q0 0.6-0.4 1t-1 0.4h-10q-1 0-1.4-0.9-0.3-0.8 0.4-1.5l3-3.1q-3.3-3-7.8-3-2.3 0-4.4 0.9t-3.6 2.4-2.5 3.7-0.9 4.4 0.9 4.4 2.5 3.7 3.6 2.4 4.4 0.9q2.7 0 5.1-1.1t4-3.3q0.1-0.2 0.5-0.3 0.3 0 0.5 0.2l3.1 3.1q0.2 0.2 0.2 0.5t-0.2 0.5q-2.4 2.9-5.9 4.5t-7.3 1.6q-3.4 0-6.6-1.3t-5.5-3.7-3.6-5.4-1.4-6.7 1.4-6.7 3.6-5.4 5.5-3.7 6.6-1.3q3.3 0 6.4 1.2t5.5 3.5l2.9-2.9q0.6-0.7 1.5-0.3 0.9 0.4 0.9 1.3z' }) + ) + ); }; -if (_inDOM2.default) { - vendors.some(function (vendor) { - var rafKey = getKey(vendor, 'request'); +exports.default = FaRepeat; +module.exports = exports['default']; - if (rafKey in window) { - cancel = getKey(vendor, 'cancel'); - return raf = function raf(cb) { - return window[rafKey](cb); - }; - } - }); -} +/***/ }), +/* 504 */ +/***/ (function(module, exports, __webpack_require__) { -/* https://github.com/component/raf */ -var prev = new Date().getTime(); -function fallback(fn) { - var curr = new Date().getTime(), - ms = Math.max(0, 16 - (curr - prev)), - req = setTimeout(fn, ms); +"use strict"; - prev = curr; - return req; -} -compatRaf = function compatRaf(cb) { - return raf(cb); -}; -compatRaf.cancel = function (id) { - window[cancel] && typeof window[cancel] === 'function' && window[cancel](id); +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var FaUnlockAlt = function FaUnlockAlt(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm30.6 17.1q0.9 0 1.5 0.7t0.6 1.5v12.8q0 0.9-0.6 1.6t-1.5 0.6h-21.5q-0.8 0-1.5-0.6t-0.6-1.6v-12.8q0-0.9 0.6-1.5t1.5-0.7h0.8v-7.1q0-4.1 2.9-7.1t7.1-2.9 7 2.9 3 7.1q0 0.6-0.5 1t-1 0.4h-1.4q-0.6 0-1-0.4t-0.4-1q0-2.4-1.7-4t-4-1.7-4.1 1.7-1.7 4v7.1h16.5z' }) + ) + ); }; -exports.default = compatRaf; + +exports.default = FaUnlockAlt; module.exports = exports['default']; /***/ }), -/* 236 */ +/* 505 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { - value: true + value: true }); -exports.animationEnd = exports.animationDelay = exports.animationTiming = exports.animationDuration = exports.animationName = exports.transitionEnd = exports.transitionDuration = exports.transitionDelay = exports.transitionTiming = exports.transitionProperty = exports.transform = undefined; -var _inDOM = __webpack_require__(107); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _inDOM2 = _interopRequireDefault(_inDOM); +var _react = __webpack_require__(6); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var _react2 = _interopRequireDefault(_react); -var transform = 'transform'; -var prefix = void 0, - transitionEnd = void 0, - animationEnd = void 0; -var transitionProperty = void 0, - transitionDuration = void 0, - transitionTiming = void 0, - transitionDelay = void 0; -var animationName = void 0, - animationDuration = void 0, - animationTiming = void 0, - animationDelay = void 0; +var _reactIconBase = __webpack_require__(35); -if (_inDOM2.default) { - var _getTransitionPropert = getTransitionProperties(); +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); - prefix = _getTransitionPropert.prefix; - exports.transitionEnd = transitionEnd = _getTransitionPropert.transitionEnd; - exports.animationEnd = animationEnd = _getTransitionPropert.animationEnd; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var FaEyeSlash = function FaEyeSlash(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm12.4 29.8l1.7-3.1q-1.9-1.5-3-3.6t-1.1-4.5q0-2.7 1.4-5-5.2 2.6-8.5 7.8 3.7 5.8 9.5 8.4z m8.7-16.9q0-0.5-0.3-0.8t-0.8-0.3q-2.8 0-4.8 2t-2 4.8q0 0.4 0.3 0.7t0.8 0.3 0.7-0.3 0.4-0.7q0-1.9 1.3-3.3t3.3-1.4q0.4 0 0.8-0.3t0.3-0.7z m8.1-4.3q0 0.2 0 0.2-2.4 4.2-7.1 12.6t-7 12.7l-1.1 2q-0.2 0.3-0.7 0.3-0.2 0-2.9-1.5-0.4-0.3-0.4-0.7 0-0.2 1-1.9-3.2-1.5-5.9-3.9t-4.7-5.4q-0.4-0.7-0.4-1.6t0.4-1.5q3.5-5.3 8.5-8.3t11.1-3q2 0 4 0.4l1.2-2.2q0.2-0.4 0.6-0.4 0.2 0 0.4 0.2t0.7 0.3 0.8 0.4 0.7 0.4 0.4 0.3q0.4 0.2 0.4 0.6z m0.8 10q0 3.1-1.8 5.6t-4.6 3.7l6.2-11.2q0.2 1 0.2 1.9z m10 2.8q0 0.8-0.4 1.6-0.9 1.4-2.5 3.2-3.3 3.8-7.7 6t-9.4 2.1l1.7-3q4.7-0.4 8.7-3t6.7-6.9q-2.5-4-6.3-6.5l1.5-2.5q2.1 1.4 4 3.4t3.3 4.1q0.4 0.7 0.4 1.5z' }) + ) + ); +}; - exports.transform = transform = prefix + '-' + transform; - exports.transitionProperty = transitionProperty = prefix + '-transition-property'; - exports.transitionDuration = transitionDuration = prefix + '-transition-duration'; - exports.transitionDelay = transitionDelay = prefix + '-transition-delay'; - exports.transitionTiming = transitionTiming = prefix + '-transition-timing-function'; +exports.default = FaEyeSlash; +module.exports = exports['default']; - exports.animationName = animationName = prefix + '-animation-name'; - exports.animationDuration = animationDuration = prefix + '-animation-duration'; - exports.animationTiming = animationTiming = prefix + '-animation-delay'; - exports.animationDelay = animationDelay = prefix + '-animation-timing-function'; -} +/***/ }), +/* 506 */ +/***/ (function(module, exports, __webpack_require__) { -exports.transform = transform; -exports.transitionProperty = transitionProperty; -exports.transitionTiming = transitionTiming; -exports.transitionDelay = transitionDelay; -exports.transitionDuration = transitionDuration; -exports.transitionEnd = transitionEnd; -exports.animationName = animationName; -exports.animationDuration = animationDuration; -exports.animationTiming = animationTiming; -exports.animationDelay = animationDelay; -exports.animationEnd = animationEnd; -exports.default = { - transform: transform, - end: transitionEnd, - property: transitionProperty, - timing: transitionTiming, - delay: transitionDelay, - duration: transitionDuration -}; +"use strict"; -function getTransitionProperties() { - var style = document.createElement('div').style; +Object.defineProperty(exports, "__esModule", { + value: true +}); - var vendorMap = { - O: function O(e) { - return 'o' + e.toLowerCase(); - }, - Moz: function Moz(e) { - return e.toLowerCase(); - }, - Webkit: function Webkit(e) { - return 'webkit' + e; - }, - ms: function ms(e) { - return 'MS' + e; - } - }; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - var vendors = Object.keys(vendorMap); +var _react = __webpack_require__(6); - var transitionEnd = void 0, - animationEnd = void 0; - var prefix = ''; +var _react2 = _interopRequireDefault(_react); - for (var i = 0; i < vendors.length; i++) { - var vendor = vendors[i]; +var _reactIconBase = __webpack_require__(35); - if (vendor + 'TransitionProperty' in style) { - prefix = '-' + vendor.toLowerCase(); - transitionEnd = vendorMap[vendor]('TransitionEnd'); - animationEnd = vendorMap[vendor]('AnimationEnd'); - break; - } - } +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); - if (!transitionEnd && 'transitionProperty' in style) transitionEnd = 'transitionend'; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - if (!animationEnd && 'animationName' in style) animationEnd = 'animationend'; +var FaEye = function FaEye(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm37.1 21.4q-3.3-5.2-8.5-7.8 1.4 2.3 1.4 5 0 4.1-2.9 7t-7.1 3-7.1-3-2.9-7q0-2.7 1.4-5.1-5.1 2.7-8.5 7.9 2.9 4.6 7.4 7.3t9.7 2.7 9.7-2.7 7.4-7.3z m-16-8.5q0-0.5-0.3-0.8t-0.8-0.3q-2.8 0-4.8 2t-2 4.8q0 0.4 0.3 0.7t0.8 0.3 0.7-0.3 0.4-0.7q0-2 1.3-3.3t3.3-1.4q0.4 0 0.8-0.3t0.3-0.7z m18.9 8.5q0 0.8-0.4 1.6-3.2 5.1-8.4 8.2t-11.2 3.1-11.2-3.1-8.4-8.2q-0.4-0.8-0.4-1.6t0.4-1.5q3.2-5.1 8.4-8.2t11.2-3.1 11.1 3.1 8.5 8.2q0.4 0.8 0.4 1.5z' }) + ) + ); +}; - style = null; +exports.default = FaEye; +module.exports = exports['default']; - return { animationEnd: animationEnd, transitionEnd: transitionEnd, prefix: prefix }; -} +/***/ }), +/* 507 */ +/***/ (function(module, exports) { + +module.exports = { + "name": "myzenwallet", + "version": "v2.0.0a", + "description": "Secure ZENCash wallet online", + "main": "index.js", + "repository": "https://github.com/kendricktan/myzenwallet.git", + "author": "Kendrick Tan <kendricktan0814@gmail.com>", + "license": "MIT", + "scripts": { + "start": "webpack-dev-server", + "watch": "webpack --watch" + }, + "dependencies": { + "axios": "^0.16.2", + "babel-preset-env": "^1.6.0", + "bip32-utils": "^0.10.0", + "bitcoinjs-lib": "^3.1.1", + "bluebird": "^3.5.0", + "bootstrap": "^4.0.0-alpha.6", + "bs58": "^4.0.1", + "bs58check": "^2.0.2", + "classnames": "^2.2.5", + "css-loader": "^0.28.4", + "file-loader": "^0.11.2", + "file-saver": "^1.3.3", + "fs": "^0.0.1-security", + "hash.js": "^1.1.3", + "html-webpack-plugin": "^2.29.0", + "path": "^0.12.7", + "react": "^15.6.1", + "react-addons-css-transition-group": "^15.6.0", + "react-addons-transition-group": "^15.6.0", + "react-bootstrap": "^0.31.1", + "react-copy-to-clipboard": "^5.0.0", + "react-dom": "^15.6.1", + "react-icons": "^2.2.5", + "react-table": "^6.5.3", + "reactstrap": "^4.8.0", + "style-loader": "^0.18.2", + "throttled-queue": "^1.0.4", + "webpack": "^3.3.0", + "webpack-dev-server": "^2.5.1", + "zencashjs": "^1.1.4-a" + }, + "devDependencies": { + "babel-core": "^6.25.0", + "babel-loader": "^7.1.1", + "babel-preset-es2015": "^6.24.1", + "babel-preset-react": "^6.24.1", + "css-loader": "^0.28.4" + } +}; /***/ }), -/* 237 */, -/* 238 */, -/* 239 */, -/* 240 */, -/* 241 */, -/* 242 */, -/* 243 */ +/* 508 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -30646,11 +80492,11 @@ Object.defineProperty(exports, "__esModule", { var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactstrap = __webpack_require__(66); +var _reactstrap = __webpack_require__(93); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -30786,496 +80632,42 @@ var ZFooter = function (_React$Component) { exports.default = ZFooter; /***/ }), -/* 244 */, -/* 245 */, -/* 246 */, -/* 247 */, -/* 248 */, -/* 249 */, -/* 250 */, -/* 251 */, -/* 252 */, -/* 253 */, -/* 254 */, -/* 255 */, -/* 256 */, -/* 257 */, -/* 258 */, -/* 259 */, -/* 260 */, -/* 261 */, -/* 262 */, -/* 263 */, -/* 264 */, -/* 265 */, -/* 266 */, -/* 267 */, -/* 268 */, -/* 269 */, -/* 270 */, -/* 271 */, -/* 272 */, -/* 273 */, -/* 274 */, -/* 275 */, -/* 276 */, -/* 277 */, -/* 278 */, -/* 279 */, -/* 280 */, -/* 281 */, -/* 282 */, -/* 283 */, -/* 284 */, -/* 285 */, -/* 286 */, -/* 287 */, -/* 288 */, -/* 289 */, -/* 290 */, -/* 291 */, -/* 292 */, -/* 293 */, -/* 294 */, -/* 295 */, -/* 296 */, -/* 297 */, -/* 298 */, -/* 299 */, -/* 300 */, -/* 301 */, -/* 302 */, -/* 303 */, -/* 304 */, -/* 305 */, -/* 306 */, -/* 307 */, -/* 308 */, -/* 309 */, -/* 310 */, -/* 311 */, -/* 312 */, -/* 313 */, -/* 314 */, -/* 315 */, -/* 316 */, -/* 317 */, -/* 318 */, -/* 319 */, -/* 320 */, -/* 321 */, -/* 322 */, -/* 323 */, -/* 324 */, -/* 325 */, -/* 326 */, -/* 327 */, -/* 328 */, -/* 329 */, -/* 330 */, -/* 331 */, -/* 332 */, -/* 333 */, -/* 334 */, -/* 335 */, -/* 336 */, -/* 337 */, -/* 338 */, -/* 339 */, -/* 340 */, -/* 341 */, -/* 342 */, -/* 343 */, -/* 344 */, -/* 345 */, -/* 346 */, -/* 347 */, -/* 348 */, -/* 349 */, -/* 350 */, -/* 351 */, -/* 352 */, -/* 353 */, -/* 354 */, -/* 355 */, -/* 356 */, -/* 357 */, -/* 358 */, -/* 359 */, -/* 360 */, -/* 361 */, -/* 362 */, -/* 363 */, -/* 364 */, -/* 365 */, -/* 366 */, -/* 367 */, -/* 368 */, -/* 369 */, -/* 370 */, -/* 371 */, -/* 372 */, -/* 373 */, -/* 374 */, -/* 375 */, -/* 376 */, -/* 377 */, -/* 378 */, -/* 379 */, -/* 380 */, -/* 381 */, -/* 382 */, -/* 383 */, -/* 384 */, -/* 385 */, -/* 386 */, -/* 387 */, -/* 388 */, -/* 389 */, -/* 390 */, -/* 391 */, -/* 392 */, -/* 393 */, -/* 394 */, -/* 395 */, -/* 396 */, -/* 397 */, -/* 398 */, -/* 399 */, -/* 400 */, -/* 401 */, -/* 402 */, -/* 403 */, -/* 404 */, -/* 405 */, -/* 406 */, -/* 407 */, -/* 408 */, -/* 409 */, -/* 410 */, -/* 411 */, -/* 412 */, -/* 413 */, -/* 414 */, -/* 415 */, -/* 416 */, -/* 417 */, -/* 418 */, -/* 419 */, -/* 420 */, -/* 421 */, -/* 422 */, -/* 423 */, -/* 424 */, -/* 425 */, -/* 426 */, -/* 427 */, -/* 428 */, -/* 429 */, -/* 430 */, -/* 431 */, -/* 432 */, -/* 433 */, -/* 434 */, -/* 435 */, -/* 436 */, -/* 437 */, -/* 438 */, -/* 439 */, -/* 440 */, -/* 441 */, -/* 442 */, -/* 443 */, -/* 444 */, -/* 445 */, -/* 446 */, -/* 447 */, -/* 448 */, -/* 449 */, -/* 450 */, -/* 451 */, -/* 452 */, -/* 453 */, -/* 454 */, -/* 455 */, -/* 456 */, -/* 457 */, -/* 458 */, -/* 459 */, -/* 460 */, -/* 461 */, -/* 462 */, -/* 463 */, -/* 464 */, -/* 465 */, -/* 466 */, -/* 467 */, -/* 468 */, -/* 469 */, -/* 470 */, -/* 471 */, -/* 472 */, -/* 473 */, -/* 474 */, -/* 475 */, -/* 476 */, -/* 477 */, -/* 478 */, -/* 479 */, -/* 480 */, -/* 481 */, -/* 482 */, -/* 483 */, -/* 484 */, -/* 485 */, -/* 486 */, -/* 487 */, -/* 488 */, -/* 489 */, -/* 490 */, -/* 491 */, -/* 492 */, -/* 493 */, -/* 494 */, -/* 495 */, -/* 496 */, -/* 497 */, -/* 498 */, -/* 499 */, -/* 500 */, -/* 501 */, -/* 502 */, -/* 503 */, -/* 504 */, -/* 505 */, -/* 506 */, -/* 507 */, -/* 508 */, /* 509 */, -/* 510 */, -/* 511 */, -/* 512 */, -/* 513 */, -/* 514 */, -/* 515 */, -/* 516 */, -/* 517 */, -/* 518 */, -/* 519 */, -/* 520 */, -/* 521 */, -/* 522 */, -/* 523 */, -/* 524 */, -/* 525 */, -/* 526 */, -/* 527 */, -/* 528 */, -/* 529 */, -/* 530 */, -/* 531 */, -/* 532 */, -/* 533 */, -/* 534 */, -/* 535 */, -/* 536 */, -/* 537 */, -/* 538 */, -/* 539 */, -/* 540 */, -/* 541 */, -/* 542 */, -/* 543 */, -/* 544 */, -/* 545 */, -/* 546 */, -/* 547 */, -/* 548 */, -/* 549 */, -/* 550 */, -/* 551 */, -/* 552 */, -/* 553 */, -/* 554 */, -/* 555 */, -/* 556 */, -/* 557 */, -/* 558 */, -/* 559 */, -/* 560 */, -/* 561 */, -/* 562 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -__webpack_require__(117); - -__webpack_require__(120); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _reactDom = __webpack_require__(28); - -var _reactDom2 = _interopRequireDefault(_reactDom); - -var _navbar = __webpack_require__(220); - -var _navbar2 = _interopRequireDefault(_navbar); - -var _faq = __webpack_require__(563); - -var _faq2 = _interopRequireDefault(_faq); - -var _footer = __webpack_require__(243); - -var _footer2 = _interopRequireDefault(_footer); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -_reactDom2.default.render(_react2.default.createElement(_navbar2.default, null), document.getElementById('navbar')); -_reactDom2.default.render(_react2.default.createElement(_faq2.default, null), document.getElementById('faq')); -_reactDom2.default.render(_react2.default.createElement(_footer2.default, null), document.getElementById('footer')); - -/***/ }), -/* 563 */ +/* 510 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); +__webpack_require__(211); -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +__webpack_require__(214); -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactstrap = __webpack_require__(66); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var _reactDom = __webpack_require__(76); -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +var _reactDom2 = _interopRequireDefault(_reactDom); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +var _navbar = __webpack_require__(315); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +var _navbar2 = _interopRequireDefault(_navbar); -var ZFaq = function (_React$Component) { - _inherits(ZFaq, _React$Component); +var _wallet = __webpack_require__(332); - function ZFaq() { - _classCallCheck(this, ZFaq); +var _wallet2 = _interopRequireDefault(_wallet); - return _possibleConstructorReturn(this, (ZFaq.__proto__ || Object.getPrototypeOf(ZFaq)).apply(this, arguments)); - } +var _footer = __webpack_require__(508); - _createClass(ZFaq, [{ - key: 'render', - value: function render() { - return _react2.default.createElement( - _reactstrap.Container, - null, - _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - null, - _react2.default.createElement( - 'p', - null, - _react2.default.createElement( - 'b', - null, - 'Q: Are my private keys secured?' - ), - _react2.default.createElement('br', null), - 'A: Yes they are secured, your private keys never leave your browser.' - ), - _react2.default.createElement( - 'p', - null, - _react2.default.createElement( - 'b', - null, - 'Q: How is this secure? Its on a web browser!' - ), - _react2.default.createElement('br', null), - 'A: MyZenWallet has replicated the core features of the ZEN daemon in JavaScript! So the process of creating and signing the transactions are all done within the browser. No sensitive information is sent through the network.' - ), - _react2.default.createElement( - 'p', - null, - _react2.default.createElement( - 'b', - null, - 'Q: Can I have the source code?' - ), - _react2.default.createElement('br', null), - 'A: ', - _react2.default.createElement( - 'a', - { href: 'https://github.com/zencashofficial/myzenwallet' }, - 'Here you go' - ) - ), - _react2.default.createElement( - 'p', - null, - _react2.default.createElement( - 'b', - null, - 'Q: Why are you doing this?' - ), - _react2.default.createElement('br', null), - 'A: MyZenWallet was inspired by ', - _react2.default.createElement( - 'a', - { href: 'https://myetherwallet.com' }, - 'MyEtherWallet\'s' - ), - ' mission statement: to provide the people the ability to interact with the ZEN blockchain easily, without having to run a full node.' - ), - _react2.default.createElement( - 'p', - null, - _react2.default.createElement( - 'b', - null, - 'Q: Can I get free ZEN?' - ), - _react2.default.createElement('br', null), - 'A: Sure! Select an address frm your wallet (check out how to create a wallet via ', - _react2.default.createElement( - 'a', - { href: '/guide.html' }, - 'the guide' - ), - ' if you don\'t have one yet) and enter it into ', - _react2.default.createElement( - 'a', - { href: 'http://getzen.cash' }, - 'getzen.cash' - ), - '.' - ) - ) - ) - ); - } - }]); +var _footer2 = _interopRequireDefault(_footer); - return ZFaq; -}(_react2.default.Component); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -exports.default = ZFaq; +_reactDom2.default.render(_react2.default.createElement(_navbar2.default, null), document.getElementById('navbar')); +_reactDom2.default.render(_react2.default.createElement(ZFaq, null), document.getElementById('faq')); +_reactDom2.default.render(_react2.default.createElement(_footer2.default, null), document.getElementById('footer')); /***/ }) /******/ ]); \ No newline at end of file diff --git a/dist/js/guide.js b/dist/js/guide.js index cc45cfa..369a2b0 100644 --- a/dist/js/guide.js +++ b/dist/js/guide.js @@ -60,7 +60,7 @@ /******/ __webpack_require__.p = ""; /******/ /******/ // Load entry module and return exports -/******/ return __webpack_require__(__webpack_require__.s = 564); +/******/ return __webpack_require__(__webpack_require__.s = 511); /******/ }) /************************************************************************/ /******/ ([ @@ -258,1325 +258,1805 @@ process.umask = function() { return 0; }; /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +/* WEBPACK VAR INJECTION */(function(global) {/*! + * The buffer module from node.js, for the browser. * + * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> + * @license MIT */ +/* eslint-disable no-proto */ + +var base64 = __webpack_require__(333) +var ieee754 = __webpack_require__(334) +var isArray = __webpack_require__(154) + +exports.Buffer = Buffer +exports.SlowBuffer = SlowBuffer +exports.INSPECT_MAX_BYTES = 50 /** - * Use invariant() to assert state which your program assumes to be true. + * If `Buffer.TYPED_ARRAY_SUPPORT`: + * === true Use Uint8Array implementation (fastest) + * === false Use Object implementation (most compatible, even IE6) * - * Provide sprintf-style format (only %s is supported) and arguments - * to provide information about what broke and what you were - * expecting. + * Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+, + * Opera 11.6+, iOS 4.2+. * - * The invariant message will be stripped in production, but the invariant - * will remain to ensure logic does not differ in production. + * Due to various browser bugs, sometimes the Object implementation will be used even + * when the browser supports typed arrays. + * + * Note: + * + * - Firefox 4-29 lacks support for adding new properties to `Uint8Array` instances, + * See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438. + * + * - Chrome 9-10 is missing the `TypedArray.prototype.subarray` function. + * + * - IE10 has a broken `TypedArray.prototype.subarray` function which returns arrays of + * incorrect length in some situations. + + * We detect these buggy browsers and set `Buffer.TYPED_ARRAY_SUPPORT` to `false` so they + * get the Object implementation, which is slower but behaves correctly. */ +Buffer.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== undefined + ? global.TYPED_ARRAY_SUPPORT + : typedArraySupport() -var validateFormat = function validateFormat(format) {}; +/* + * Export kMaxLength after typed array support is determined. + */ +exports.kMaxLength = kMaxLength() -if (process.env.NODE_ENV !== 'production') { - validateFormat = function validateFormat(format) { - if (format === undefined) { - throw new Error('invariant requires an error message argument'); - } - }; +function typedArraySupport () { + try { + var arr = new Uint8Array(1) + arr.__proto__ = {__proto__: Uint8Array.prototype, foo: function () { return 42 }} + return arr.foo() === 42 && // typed array instances can be augmented + typeof arr.subarray === 'function' && // chrome 9-10 lack `subarray` + arr.subarray(1, 1).byteLength === 0 // ie10 has broken `subarray` + } catch (e) { + return false + } } -function invariant(condition, format, a, b, c, d, e, f) { - validateFormat(format); +function kMaxLength () { + return Buffer.TYPED_ARRAY_SUPPORT + ? 0x7fffffff + : 0x3fffffff +} - if (!condition) { - var error; - if (format === undefined) { - error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); - } else { - var args = [a, b, c, d, e, f]; - var argIndex = 0; - error = new Error(format.replace(/%s/g, function () { - return args[argIndex++]; - })); - error.name = 'Invariant Violation'; +function createBuffer (that, length) { + if (kMaxLength() < length) { + throw new RangeError('Invalid typed array length') + } + if (Buffer.TYPED_ARRAY_SUPPORT) { + // Return an augmented `Uint8Array` instance, for best performance + that = new Uint8Array(length) + that.__proto__ = Buffer.prototype + } else { + // Fallback: Return an object instance of the Buffer class + if (that === null) { + that = new Buffer(length) } - - error.framesToPop = 1; // we don't care about invariant's own frame - throw error; + that.length = length } -} -module.exports = invariant; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 2 */ -/***/ (function(module, exports, __webpack_require__) { + return that +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +/** + * The Buffer constructor returns instances of `Uint8Array` that have their + * prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of + * `Uint8Array`, so the returned instances will have all the node `Buffer` methods + * and the `Uint8Array` methods. Square bracket notation works as expected -- it + * returns a single octet. * + * The `Uint8Array` prototype remains unmodified. */ +function Buffer (arg, encodingOrOffset, length) { + if (!Buffer.TYPED_ARRAY_SUPPORT && !(this instanceof Buffer)) { + return new Buffer(arg, encodingOrOffset, length) + } + // Common case. + if (typeof arg === 'number') { + if (typeof encodingOrOffset === 'string') { + throw new Error( + 'If encoding is specified then the first argument must be a string' + ) + } + return allocUnsafe(this, arg) + } + return from(this, arg, encodingOrOffset, length) +} -var emptyFunction = __webpack_require__(12); - -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ +Buffer.poolSize = 8192 // not used by this implementation -var warning = emptyFunction; +// TODO: Legacy, not needed anymore. Remove in next major version. +Buffer._augment = function (arr) { + arr.__proto__ = Buffer.prototype + return arr +} -if (process.env.NODE_ENV !== 'production') { - (function () { - var printWarning = function printWarning(format) { - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; - } +function from (that, value, encodingOrOffset, length) { + if (typeof value === 'number') { + throw new TypeError('"value" argument must not be a number') + } - var argIndex = 0; - var message = 'Warning: ' + format.replace(/%s/g, function () { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // --- Welcome to debugging React --- - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch (x) {} - }; + if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) { + return fromArrayBuffer(that, value, encodingOrOffset, length) + } - warning = function warning(condition, format) { - if (format === undefined) { - throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); - } + if (typeof value === 'string') { + return fromString(that, value, encodingOrOffset) + } - if (format.indexOf('Failed Composite propType: ') === 0) { - return; // Ignore CompositeComponent proptype check. - } + return fromObject(that, value) +} - if (!condition) { - for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { - args[_key2 - 2] = arguments[_key2]; - } +/** + * Functionally equivalent to Buffer(arg, encoding) but throws a TypeError + * if value is a number. + * Buffer.from(str[, encoding]) + * Buffer.from(array) + * Buffer.from(buffer) + * Buffer.from(arrayBuffer[, byteOffset[, length]]) + **/ +Buffer.from = function (value, encodingOrOffset, length) { + return from(null, value, encodingOrOffset, length) +} - printWarning.apply(undefined, [format].concat(args)); - } - }; - })(); +if (Buffer.TYPED_ARRAY_SUPPORT) { + Buffer.prototype.__proto__ = Uint8Array.prototype + Buffer.__proto__ = Uint8Array + if (typeof Symbol !== 'undefined' && Symbol.species && + Buffer[Symbol.species] === Buffer) { + // Fix subarray() in ES2016. See: https://github.com/feross/buffer/pull/97 + Object.defineProperty(Buffer, Symbol.species, { + value: null, + configurable: true + }) + } } -module.exports = warning; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function assertSize (size) { + if (typeof size !== 'number') { + throw new TypeError('"size" argument must be a number') + } else if (size < 0) { + throw new RangeError('"size" argument must not be negative') + } +} -/***/ }), -/* 3 */ -/***/ (function(module, exports, __webpack_require__) { +function alloc (that, size, fill, encoding) { + assertSize(size) + if (size <= 0) { + return createBuffer(that, size) + } + if (fill !== undefined) { + // Only pay attention to encoding if it's a string. This + // prevents accidentally sending in a number that would + // be interpretted as a start offset. + return typeof encoding === 'string' + ? createBuffer(that, size).fill(fill, encoding) + : createBuffer(that, size).fill(fill) + } + return createBuffer(that, size) +} -"use strict"; /** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + * Creates a new filled Buffer instance. + * alloc(size[, fill[, encoding]]) + **/ +Buffer.alloc = function (size, fill, encoding) { + return alloc(null, size, fill, encoding) +} +function allocUnsafe (that, size) { + assertSize(size) + that = createBuffer(that, size < 0 ? 0 : checked(size) | 0) + if (!Buffer.TYPED_ARRAY_SUPPORT) { + for (var i = 0; i < size; ++i) { + that[i] = 0 + } + } + return that +} /** - * WARNING: DO NOT manually require this module. - * This is a replacement for `invariant(...)` used by the error code system - * and will _only_ be required by the corresponding babel pass. - * It always throws. + * Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance. + * */ +Buffer.allocUnsafe = function (size) { + return allocUnsafe(null, size) +} +/** + * Equivalent to SlowBuffer(num), by default creates a non-zero-filled Buffer instance. */ +Buffer.allocUnsafeSlow = function (size) { + return allocUnsafe(null, size) +} -function reactProdInvariant(code) { - var argCount = arguments.length - 1; +function fromString (that, string, encoding) { + if (typeof encoding !== 'string' || encoding === '') { + encoding = 'utf8' + } - var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; + if (!Buffer.isEncoding(encoding)) { + throw new TypeError('"encoding" must be a valid string encoding') + } - for (var argIdx = 0; argIdx < argCount; argIdx++) { - message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); + var length = byteLength(string, encoding) | 0 + that = createBuffer(that, length) + + var actual = that.write(string, encoding) + + if (actual !== length) { + // Writing a hex string, for example, that contains invalid characters will + // cause everything after the first invalid character to be ignored. (e.g. + // 'abxxcd' will be treated as 'ab') + that = that.slice(0, actual) } - message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; + return that +} - var error = new Error(message); - error.name = 'Invariant Violation'; - error.framesToPop = 1; // we don't care about reactProdInvariant's own frame +function fromArrayLike (that, array) { + var length = array.length < 0 ? 0 : checked(array.length) | 0 + that = createBuffer(that, length) + for (var i = 0; i < length; i += 1) { + that[i] = array[i] & 255 + } + return that +} - throw error; +function fromArrayBuffer (that, array, byteOffset, length) { + array.byteLength // this throws if `array` is not a valid ArrayBuffer + + if (byteOffset < 0 || array.byteLength < byteOffset) { + throw new RangeError('\'offset\' is out of bounds') + } + + if (array.byteLength < byteOffset + (length || 0)) { + throw new RangeError('\'length\' is out of bounds') + } + + if (byteOffset === undefined && length === undefined) { + array = new Uint8Array(array) + } else if (length === undefined) { + array = new Uint8Array(array, byteOffset) + } else { + array = new Uint8Array(array, byteOffset, length) + } + + if (Buffer.TYPED_ARRAY_SUPPORT) { + // Return an augmented `Uint8Array` instance, for best performance + that = array + that.__proto__ = Buffer.prototype + } else { + // Fallback: Return an object instance of the Buffer class + that = fromArrayLike(that, array) + } + return that } -module.exports = reactProdInvariant; +function fromObject (that, obj) { + if (Buffer.isBuffer(obj)) { + var len = checked(obj.length) | 0 + that = createBuffer(that, len) -/***/ }), -/* 4 */ -/***/ (function(module, exports, __webpack_require__) { + if (that.length === 0) { + return that + } -"use strict"; + obj.copy(that, 0, 0, len) + return that + } + if (obj) { + if ((typeof ArrayBuffer !== 'undefined' && + obj.buffer instanceof ArrayBuffer) || 'length' in obj) { + if (typeof obj.length !== 'number' || isnan(obj.length)) { + return createBuffer(that, 0) + } + return fromArrayLike(that, obj) + } -module.exports = __webpack_require__(24); + if (obj.type === 'Buffer' && isArray(obj.data)) { + return fromArrayLike(that, obj.data) + } + } + throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.') +} -/***/ }), -/* 5 */ -/***/ (function(module, exports, __webpack_require__) { +function checked (length) { + // Note: cannot use `length < kMaxLength()` here because that fails when + // length is NaN (which is otherwise coerced to zero.) + if (length >= kMaxLength()) { + throw new RangeError('Attempt to allocate Buffer larger than maximum ' + + 'size: 0x' + kMaxLength().toString(16) + ' bytes') + } + return length | 0 +} -"use strict"; -/* -object-assign -(c) Sindre Sorhus -@license MIT -*/ +function SlowBuffer (length) { + if (+length != length) { // eslint-disable-line eqeqeq + length = 0 + } + return Buffer.alloc(+length) +} +Buffer.isBuffer = function isBuffer (b) { + return !!(b != null && b._isBuffer) +} -/* eslint-disable no-unused-vars */ -var getOwnPropertySymbols = Object.getOwnPropertySymbols; -var hasOwnProperty = Object.prototype.hasOwnProperty; -var propIsEnumerable = Object.prototype.propertyIsEnumerable; +Buffer.compare = function compare (a, b) { + if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) { + throw new TypeError('Arguments must be Buffers') + } -function toObject(val) { - if (val === null || val === undefined) { - throw new TypeError('Object.assign cannot be called with null or undefined'); - } + if (a === b) return 0 - return Object(val); + var x = a.length + var y = b.length + + for (var i = 0, len = Math.min(x, y); i < len; ++i) { + if (a[i] !== b[i]) { + x = a[i] + y = b[i] + break + } + } + + if (x < y) return -1 + if (y < x) return 1 + return 0 } -function shouldUseNative() { - try { - if (!Object.assign) { - return false; - } +Buffer.isEncoding = function isEncoding (encoding) { + switch (String(encoding).toLowerCase()) { + case 'hex': + case 'utf8': + case 'utf-8': + case 'ascii': + case 'latin1': + case 'binary': + case 'base64': + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return true + default: + return false + } +} - // Detect buggy property enumeration order in older V8 versions. +Buffer.concat = function concat (list, length) { + if (!isArray(list)) { + throw new TypeError('"list" argument must be an Array of Buffers') + } - // https://bugs.chromium.org/p/v8/issues/detail?id=4118 - var test1 = new String('abc'); // eslint-disable-line no-new-wrappers - test1[5] = 'de'; - if (Object.getOwnPropertyNames(test1)[0] === '5') { - return false; - } + if (list.length === 0) { + return Buffer.alloc(0) + } - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test2 = {}; - for (var i = 0; i < 10; i++) { - test2['_' + String.fromCharCode(i)] = i; - } - var order2 = Object.getOwnPropertyNames(test2).map(function (n) { - return test2[n]; - }); - if (order2.join('') !== '0123456789') { - return false; - } + var i + if (length === undefined) { + length = 0 + for (i = 0; i < list.length; ++i) { + length += list[i].length + } + } - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test3 = {}; - 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { - test3[letter] = letter; - }); - if (Object.keys(Object.assign({}, test3)).join('') !== - 'abcdefghijklmnopqrst') { - return false; - } + var buffer = Buffer.allocUnsafe(length) + var pos = 0 + for (i = 0; i < list.length; ++i) { + var buf = list[i] + if (!Buffer.isBuffer(buf)) { + throw new TypeError('"list" argument must be an Array of Buffers') + } + buf.copy(buffer, pos) + pos += buf.length + } + return buffer +} - return true; - } catch (err) { - // We don't expect any of the above to throw, but better to be safe. - return false; - } +function byteLength (string, encoding) { + if (Buffer.isBuffer(string)) { + return string.length + } + if (typeof ArrayBuffer !== 'undefined' && typeof ArrayBuffer.isView === 'function' && + (ArrayBuffer.isView(string) || string instanceof ArrayBuffer)) { + return string.byteLength + } + if (typeof string !== 'string') { + string = '' + string + } + + var len = string.length + if (len === 0) return 0 + + // Use a for loop to avoid recursion + var loweredCase = false + for (;;) { + switch (encoding) { + case 'ascii': + case 'latin1': + case 'binary': + return len + case 'utf8': + case 'utf-8': + case undefined: + return utf8ToBytes(string).length + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return len * 2 + case 'hex': + return len >>> 1 + case 'base64': + return base64ToBytes(string).length + default: + if (loweredCase) return utf8ToBytes(string).length // assume utf8 + encoding = ('' + encoding).toLowerCase() + loweredCase = true + } + } } +Buffer.byteLength = byteLength -module.exports = shouldUseNative() ? Object.assign : function (target, source) { - var from; - var to = toObject(target); - var symbols; +function slowToString (encoding, start, end) { + var loweredCase = false - for (var s = 1; s < arguments.length; s++) { - from = Object(arguments[s]); + // No need to verify that "this.length <= MAX_UINT32" since it's a read-only + // property of a typed array. - for (var key in from) { - if (hasOwnProperty.call(from, key)) { - to[key] = from[key]; - } - } + // This behaves neither like String nor Uint8Array in that we set start/end + // to their upper/lower bounds if the value passed is out of range. + // undefined is handled specially as per ECMA-262 6th Edition, + // Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization. + if (start === undefined || start < 0) { + start = 0 + } + // Return early if start > this.length. Done here to prevent potential uint32 + // coercion fail below. + if (start > this.length) { + return '' + } - if (getOwnPropertySymbols) { - symbols = getOwnPropertySymbols(from); - for (var i = 0; i < symbols.length; i++) { - if (propIsEnumerable.call(from, symbols[i])) { - to[symbols[i]] = from[symbols[i]]; - } - } - } - } + if (end === undefined || end > this.length) { + end = this.length + } - return to; -}; + if (end <= 0) { + return '' + } + // Force coersion to uint32. This will also coerce falsey/NaN values to 0. + end >>>= 0 + start >>>= 0 -/***/ }), -/* 6 */ -/***/ (function(module, exports, __webpack_require__) { + if (end <= start) { + return '' + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + if (!encoding) encoding = 'utf8' + while (true) { + switch (encoding) { + case 'hex': + return hexSlice(this, start, end) + case 'utf8': + case 'utf-8': + return utf8Slice(this, start, end) -var _prodInvariant = __webpack_require__(3); + case 'ascii': + return asciiSlice(this, start, end) -var DOMProperty = __webpack_require__(17); -var ReactDOMComponentFlags = __webpack_require__(81); + case 'latin1': + case 'binary': + return latin1Slice(this, start, end) -var invariant = __webpack_require__(1); + case 'base64': + return base64Slice(this, start, end) -var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; -var Flags = ReactDOMComponentFlags; + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return utf16leSlice(this, start, end) -var internalInstanceKey = '__reactInternalInstance$' + Math.random().toString(36).slice(2); + default: + if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding) + encoding = (encoding + '').toLowerCase() + loweredCase = true + } + } +} -/** - * Check if a given node should be cached. - */ -function shouldPrecacheNode(node, nodeID) { - return node.nodeType === 1 && node.getAttribute(ATTR_NAME) === String(nodeID) || node.nodeType === 8 && node.nodeValue === ' react-text: ' + nodeID + ' ' || node.nodeType === 8 && node.nodeValue === ' react-empty: ' + nodeID + ' '; +// The property is used by `Buffer.isBuffer` and `is-buffer` (in Safari 5-7) to detect +// Buffer instances. +Buffer.prototype._isBuffer = true + +function swap (b, n, m) { + var i = b[n] + b[n] = b[m] + b[m] = i } -/** - * Drill down (through composites and empty components) until we get a host or - * host text component. - * - * This is pretty polymorphic but unavoidable with the current structure we have - * for `_renderedChildren`. - */ -function getRenderedHostOrTextFromComponent(component) { - var rendered; - while (rendered = component._renderedComponent) { - component = rendered; +Buffer.prototype.swap16 = function swap16 () { + var len = this.length + if (len % 2 !== 0) { + throw new RangeError('Buffer size must be a multiple of 16-bits') } - return component; + for (var i = 0; i < len; i += 2) { + swap(this, i, i + 1) + } + return this } -/** - * Populate `_hostNode` on the rendered host/text component with the given - * DOM node. The passed `inst` can be a composite. - */ -function precacheNode(inst, node) { - var hostInst = getRenderedHostOrTextFromComponent(inst); - hostInst._hostNode = node; - node[internalInstanceKey] = hostInst; +Buffer.prototype.swap32 = function swap32 () { + var len = this.length + if (len % 4 !== 0) { + throw new RangeError('Buffer size must be a multiple of 32-bits') + } + for (var i = 0; i < len; i += 4) { + swap(this, i, i + 3) + swap(this, i + 1, i + 2) + } + return this } -function uncacheNode(inst) { - var node = inst._hostNode; - if (node) { - delete node[internalInstanceKey]; - inst._hostNode = null; +Buffer.prototype.swap64 = function swap64 () { + var len = this.length + if (len % 8 !== 0) { + throw new RangeError('Buffer size must be a multiple of 64-bits') + } + for (var i = 0; i < len; i += 8) { + swap(this, i, i + 7) + swap(this, i + 1, i + 6) + swap(this, i + 2, i + 5) + swap(this, i + 3, i + 4) } + return this } -/** - * Populate `_hostNode` on each child of `inst`, assuming that the children - * match up with the DOM (element) children of `node`. - * - * We cache entire levels at once to avoid an n^2 problem where we access the - * children of a node sequentially and have to walk from the start to our target - * node every time. - * - * Since we update `_renderedChildren` and the actual DOM at (slightly) - * different times, we could race here and see a newer `_renderedChildren` than - * the DOM nodes we see. To avoid this, ReactMultiChild calls - * `prepareToManageChildren` before we change `_renderedChildren`, at which - * time the container's child nodes are always cached (until it unmounts). - */ -function precacheChildNodes(inst, node) { - if (inst._flags & Flags.hasCachedChildNodes) { - return; +Buffer.prototype.toString = function toString () { + var length = this.length | 0 + if (length === 0) return '' + if (arguments.length === 0) return utf8Slice(this, 0, length) + return slowToString.apply(this, arguments) +} + +Buffer.prototype.equals = function equals (b) { + if (!Buffer.isBuffer(b)) throw new TypeError('Argument must be a Buffer') + if (this === b) return true + return Buffer.compare(this, b) === 0 +} + +Buffer.prototype.inspect = function inspect () { + var str = '' + var max = exports.INSPECT_MAX_BYTES + if (this.length > 0) { + str = this.toString('hex', 0, max).match(/.{2}/g).join(' ') + if (this.length > max) str += ' ... ' } - var children = inst._renderedChildren; - var childNode = node.firstChild; - outer: for (var name in children) { - if (!children.hasOwnProperty(name)) { - continue; - } - var childInst = children[name]; - var childID = getRenderedHostOrTextFromComponent(childInst)._domID; - if (childID === 0) { - // We're currently unmounting this child in ReactMultiChild; skip it. - continue; + return '<Buffer ' + str + '>' +} + +Buffer.prototype.compare = function compare (target, start, end, thisStart, thisEnd) { + if (!Buffer.isBuffer(target)) { + throw new TypeError('Argument must be a Buffer') + } + + if (start === undefined) { + start = 0 + } + if (end === undefined) { + end = target ? target.length : 0 + } + if (thisStart === undefined) { + thisStart = 0 + } + if (thisEnd === undefined) { + thisEnd = this.length + } + + if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) { + throw new RangeError('out of range index') + } + + if (thisStart >= thisEnd && start >= end) { + return 0 + } + if (thisStart >= thisEnd) { + return -1 + } + if (start >= end) { + return 1 + } + + start >>>= 0 + end >>>= 0 + thisStart >>>= 0 + thisEnd >>>= 0 + + if (this === target) return 0 + + var x = thisEnd - thisStart + var y = end - start + var len = Math.min(x, y) + + var thisCopy = this.slice(thisStart, thisEnd) + var targetCopy = target.slice(start, end) + + for (var i = 0; i < len; ++i) { + if (thisCopy[i] !== targetCopy[i]) { + x = thisCopy[i] + y = targetCopy[i] + break } - // We assume the child nodes are in the same order as the child instances. - for (; childNode !== null; childNode = childNode.nextSibling) { - if (shouldPrecacheNode(childNode, childID)) { - precacheNode(childInst, childNode); - continue outer; + } + + if (x < y) return -1 + if (y < x) return 1 + return 0 +} + +// Finds either the first index of `val` in `buffer` at offset >= `byteOffset`, +// OR the last index of `val` in `buffer` at offset <= `byteOffset`. +// +// Arguments: +// - buffer - a Buffer to search +// - val - a string, Buffer, or number +// - byteOffset - an index into `buffer`; will be clamped to an int32 +// - encoding - an optional encoding, relevant is val is a string +// - dir - true for indexOf, false for lastIndexOf +function bidirectionalIndexOf (buffer, val, byteOffset, encoding, dir) { + // Empty buffer means no match + if (buffer.length === 0) return -1 + + // Normalize byteOffset + if (typeof byteOffset === 'string') { + encoding = byteOffset + byteOffset = 0 + } else if (byteOffset > 0x7fffffff) { + byteOffset = 0x7fffffff + } else if (byteOffset < -0x80000000) { + byteOffset = -0x80000000 + } + byteOffset = +byteOffset // Coerce to Number. + if (isNaN(byteOffset)) { + // byteOffset: it it's undefined, null, NaN, "foo", etc, search whole buffer + byteOffset = dir ? 0 : (buffer.length - 1) + } + + // Normalize byteOffset: negative offsets start from the end of the buffer + if (byteOffset < 0) byteOffset = buffer.length + byteOffset + if (byteOffset >= buffer.length) { + if (dir) return -1 + else byteOffset = buffer.length - 1 + } else if (byteOffset < 0) { + if (dir) byteOffset = 0 + else return -1 + } + + // Normalize val + if (typeof val === 'string') { + val = Buffer.from(val, encoding) + } + + // Finally, search either indexOf (if dir is true) or lastIndexOf + if (Buffer.isBuffer(val)) { + // Special case: looking for empty string/buffer always fails + if (val.length === 0) { + return -1 + } + return arrayIndexOf(buffer, val, byteOffset, encoding, dir) + } else if (typeof val === 'number') { + val = val & 0xFF // Search for a byte value [0-255] + if (Buffer.TYPED_ARRAY_SUPPORT && + typeof Uint8Array.prototype.indexOf === 'function') { + if (dir) { + return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset) + } else { + return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset) } } - // We reached the end of the DOM children without finding an ID match. - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unable to find element with ID %s.', childID) : _prodInvariant('32', childID) : void 0; + return arrayIndexOf(buffer, [ val ], byteOffset, encoding, dir) } - inst._flags |= Flags.hasCachedChildNodes; + + throw new TypeError('val must be string, number or Buffer') } -/** - * Given a DOM node, return the closest ReactDOMComponent or - * ReactDOMTextComponent instance ancestor. - */ -function getClosestInstanceFromNode(node) { - if (node[internalInstanceKey]) { - return node[internalInstanceKey]; +function arrayIndexOf (arr, val, byteOffset, encoding, dir) { + var indexSize = 1 + var arrLength = arr.length + var valLength = val.length + + if (encoding !== undefined) { + encoding = String(encoding).toLowerCase() + if (encoding === 'ucs2' || encoding === 'ucs-2' || + encoding === 'utf16le' || encoding === 'utf-16le') { + if (arr.length < 2 || val.length < 2) { + return -1 + } + indexSize = 2 + arrLength /= 2 + valLength /= 2 + byteOffset /= 2 + } } - // Walk up the tree until we find an ancestor whose instance we have cached. - var parents = []; - while (!node[internalInstanceKey]) { - parents.push(node); - if (node.parentNode) { - node = node.parentNode; + function read (buf, i) { + if (indexSize === 1) { + return buf[i] } else { - // Top of the tree. This node must not be part of a React tree (or is - // unmounted, potentially). - return null; + return buf.readUInt16BE(i * indexSize) } } - var closest; - var inst; - for (; node && (inst = node[internalInstanceKey]); node = parents.pop()) { - closest = inst; - if (parents.length) { - precacheChildNodes(inst, node); + var i + if (dir) { + var foundIndex = -1 + for (i = byteOffset; i < arrLength; i++) { + if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) { + if (foundIndex === -1) foundIndex = i + if (i - foundIndex + 1 === valLength) return foundIndex * indexSize + } else { + if (foundIndex !== -1) i -= i - foundIndex + foundIndex = -1 + } + } + } else { + if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength + for (i = byteOffset; i >= 0; i--) { + var found = true + for (var j = 0; j < valLength; j++) { + if (read(arr, i + j) !== read(val, j)) { + found = false + break + } + } + if (found) return i } } - return closest; + return -1 } -/** - * Given a DOM node, return the ReactDOMComponent or ReactDOMTextComponent - * instance, or null if the node was not rendered by this React. - */ -function getInstanceFromNode(node) { - var inst = getClosestInstanceFromNode(node); - if (inst != null && inst._hostNode === node) { - return inst; - } else { - return null; - } +Buffer.prototype.includes = function includes (val, byteOffset, encoding) { + return this.indexOf(val, byteOffset, encoding) !== -1 } -/** - * Given a ReactDOMComponent or ReactDOMTextComponent, return the corresponding - * DOM node. - */ -function getNodeFromInstance(inst) { - // Without this first invariant, passing a non-DOM-component triggers the next - // invariant for a missing parent, which is super confusing. - !(inst._hostNode !== undefined) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; +Buffer.prototype.indexOf = function indexOf (val, byteOffset, encoding) { + return bidirectionalIndexOf(this, val, byteOffset, encoding, true) +} - if (inst._hostNode) { - return inst._hostNode; - } +Buffer.prototype.lastIndexOf = function lastIndexOf (val, byteOffset, encoding) { + return bidirectionalIndexOf(this, val, byteOffset, encoding, false) +} - // Walk up the tree until we find an ancestor whose DOM node we have cached. - var parents = []; - while (!inst._hostNode) { - parents.push(inst); - !inst._hostParent ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React DOM tree root should always have a node reference.') : _prodInvariant('34') : void 0; - inst = inst._hostParent; +function hexWrite (buf, string, offset, length) { + offset = Number(offset) || 0 + var remaining = buf.length - offset + if (!length) { + length = remaining + } else { + length = Number(length) + if (length > remaining) { + length = remaining + } } - // Now parents contains each ancestor that does *not* have a cached native - // node, and `inst` is the deepest ancestor that does. - for (; parents.length; inst = parents.pop()) { - precacheChildNodes(inst, inst._hostNode); + // must be an even number of digits + var strLen = string.length + if (strLen % 2 !== 0) throw new TypeError('Invalid hex string') + + if (length > strLen / 2) { + length = strLen / 2 + } + for (var i = 0; i < length; ++i) { + var parsed = parseInt(string.substr(i * 2, 2), 16) + if (isNaN(parsed)) return i + buf[offset + i] = parsed } + return i +} - return inst._hostNode; +function utf8Write (buf, string, offset, length) { + return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length) } -var ReactDOMComponentTree = { - getClosestInstanceFromNode: getClosestInstanceFromNode, - getInstanceFromNode: getInstanceFromNode, - getNodeFromInstance: getNodeFromInstance, - precacheChildNodes: precacheChildNodes, - precacheNode: precacheNode, - uncacheNode: uncacheNode -}; +function asciiWrite (buf, string, offset, length) { + return blitBuffer(asciiToBytes(string), buf, offset, length) +} -module.exports = ReactDOMComponentTree; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function latin1Write (buf, string, offset, length) { + return asciiWrite(buf, string, offset, length) +} -/***/ }), -/* 7 */, -/* 8 */ -/***/ (function(module, exports, __webpack_require__) { +function base64Write (buf, string, offset, length) { + return blitBuffer(base64ToBytes(string), buf, offset, length) +} -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function ucs2Write (buf, string, offset, length) { + return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length) +} +Buffer.prototype.write = function write (string, offset, length, encoding) { + // Buffer#write(string) + if (offset === undefined) { + encoding = 'utf8' + length = this.length + offset = 0 + // Buffer#write(string, encoding) + } else if (length === undefined && typeof offset === 'string') { + encoding = offset + length = this.length + offset = 0 + // Buffer#write(string, offset[, length][, encoding]) + } else if (isFinite(offset)) { + offset = offset | 0 + if (isFinite(length)) { + length = length | 0 + if (encoding === undefined) encoding = 'utf8' + } else { + encoding = length + length = undefined + } + // legacy write(string, encoding, offset, length) - remove in v0.13 + } else { + throw new Error( + 'Buffer.write(string, encoding, offset[, length]) is no longer supported' + ) + } + var remaining = this.length - offset + if (length === undefined || length > remaining) length = remaining -var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); + if ((string.length > 0 && (length < 0 || offset < 0)) || offset > this.length) { + throw new RangeError('Attempt to write outside buffer bounds') + } -/** - * Simple, lightweight module assisting with the detection and context of - * Worker. Helps avoid circular dependencies and allows code to reason about - * whether or not they are in a Worker, even if they never include the main - * `ReactWorker` dependency. - */ -var ExecutionEnvironment = { + if (!encoding) encoding = 'utf8' - canUseDOM: canUseDOM, + var loweredCase = false + for (;;) { + switch (encoding) { + case 'hex': + return hexWrite(this, string, offset, length) - canUseWorkers: typeof Worker !== 'undefined', + case 'utf8': + case 'utf-8': + return utf8Write(this, string, offset, length) - canUseEventListeners: canUseDOM && !!(window.addEventListener || window.attachEvent), + case 'ascii': + return asciiWrite(this, string, offset, length) - canUseViewport: canUseDOM && !!window.screen, + case 'latin1': + case 'binary': + return latin1Write(this, string, offset, length) - isInWorker: !canUseDOM // For now, this is true - might change in the future. + case 'base64': + // Warning: maxLength not taken into account in base64Write + return base64Write(this, string, offset, length) -}; + case 'ucs2': + case 'ucs-2': + case 'utf16le': + case 'utf-16le': + return ucs2Write(this, string, offset, length) -module.exports = ExecutionEnvironment; + default: + if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding) + encoding = ('' + encoding).toLowerCase() + loweredCase = true + } + } +} -/***/ }), -/* 9 */ -/***/ (function(module, exports, __webpack_require__) { +Buffer.prototype.toJSON = function toJSON () { + return { + type: 'Buffer', + data: Array.prototype.slice.call(this._arr || this, 0) + } +} -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +function base64Slice (buf, start, end) { + if (start === 0 && end === buf.length) { + return base64.fromByteArray(buf) + } else { + return base64.fromByteArray(buf.slice(start, end)) + } +} -if (process.env.NODE_ENV !== 'production') { - var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && - Symbol.for && - Symbol.for('react.element')) || - 0xeac7; +function utf8Slice (buf, start, end) { + end = Math.min(buf.length, end) + var res = [] + + var i = start + while (i < end) { + var firstByte = buf[i] + var codePoint = null + var bytesPerSequence = (firstByte > 0xEF) ? 4 + : (firstByte > 0xDF) ? 3 + : (firstByte > 0xBF) ? 2 + : 1 + + if (i + bytesPerSequence <= end) { + var secondByte, thirdByte, fourthByte, tempCodePoint + + switch (bytesPerSequence) { + case 1: + if (firstByte < 0x80) { + codePoint = firstByte + } + break + case 2: + secondByte = buf[i + 1] + if ((secondByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0x1F) << 0x6 | (secondByte & 0x3F) + if (tempCodePoint > 0x7F) { + codePoint = tempCodePoint + } + } + break + case 3: + secondByte = buf[i + 1] + thirdByte = buf[i + 2] + if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | (thirdByte & 0x3F) + if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) { + codePoint = tempCodePoint + } + } + break + case 4: + secondByte = buf[i + 1] + thirdByte = buf[i + 2] + fourthByte = buf[i + 3] + if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) { + tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | (fourthByte & 0x3F) + if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) { + codePoint = tempCodePoint + } + } + } + } - var isValidElement = function(object) { - return typeof object === 'object' && - object !== null && - object.$$typeof === REACT_ELEMENT_TYPE; - }; + if (codePoint === null) { + // we did not generate a valid codePoint so insert a + // replacement char (U+FFFD) and advance only 1 byte + codePoint = 0xFFFD + bytesPerSequence = 1 + } else if (codePoint > 0xFFFF) { + // encode to utf16 (surrogate pair dance) + codePoint -= 0x10000 + res.push(codePoint >>> 10 & 0x3FF | 0xD800) + codePoint = 0xDC00 | codePoint & 0x3FF + } - // By explicitly using `prop-types` you are opting into new development behavior. - // http://fb.me/prop-types-in-prod - var throwOnDirectAccess = true; - module.exports = __webpack_require__(80)(isValidElement, throwOnDirectAccess); -} else { - // By explicitly using `prop-types` you are opting into new production behavior. - // http://fb.me/prop-types-in-prod - module.exports = __webpack_require__(221)(); + res.push(codePoint) + i += bytesPerSequence + } + + return decodeCodePointsArray(res) } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +// Based on http://stackoverflow.com/a/22747272/680742, the browser with +// the lowest limit is Chrome, with 0x10000 args. +// We go 1 magnitude less, for safety +var MAX_ARGUMENTS_LENGTH = 0x1000 -/***/ }), -/* 10 */ -/***/ (function(module, exports, __webpack_require__) { +function decodeCodePointsArray (codePoints) { + var len = codePoints.length + if (len <= MAX_ARGUMENTS_LENGTH) { + return String.fromCharCode.apply(String, codePoints) // avoid extra slice() + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + // Decode in chunks to avoid "call stack size exceeded". + var res = '' + var i = 0 + while (i < len) { + res += String.fromCharCode.apply( + String, + codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH) + ) + } + return res +} +function asciiSlice (buf, start, end) { + var ret = '' + end = Math.min(buf.length, end) + for (var i = start; i < end; ++i) { + ret += String.fromCharCode(buf[i] & 0x7F) + } + return ret +} -var _prodInvariant = __webpack_require__(25); +function latin1Slice (buf, start, end) { + var ret = '' + end = Math.min(buf.length, end) -var ReactCurrentOwner = __webpack_require__(14); + for (var i = start; i < end; ++i) { + ret += String.fromCharCode(buf[i]) + } + return ret +} -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +function hexSlice (buf, start, end) { + var len = buf.length -function isNative(fn) { - // Based on isNative() from Lodash - var funcToString = Function.prototype.toString; - var hasOwnProperty = Object.prototype.hasOwnProperty; - var reIsNative = RegExp('^' + funcToString - // Take an example native function source for comparison - .call(hasOwnProperty - // Strip regex characters so we can use it for regex - ).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&' - // Remove hasOwnProperty from the template to make it generic - ).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'); - try { - var source = funcToString.call(fn); - return reIsNative.test(source); - } catch (err) { - return false; + if (!start || start < 0) start = 0 + if (!end || end < 0 || end > len) end = len + + var out = '' + for (var i = start; i < end; ++i) { + out += toHex(buf[i]) } + return out } -var canUseCollections = -// Array.from -typeof Array.from === 'function' && -// Map -typeof Map === 'function' && isNative(Map) && -// Map.prototype.keys -Map.prototype != null && typeof Map.prototype.keys === 'function' && isNative(Map.prototype.keys) && -// Set -typeof Set === 'function' && isNative(Set) && -// Set.prototype.keys -Set.prototype != null && typeof Set.prototype.keys === 'function' && isNative(Set.prototype.keys); - -var setItem; -var getItem; -var removeItem; -var getItemIDs; -var addRoot; -var removeRoot; -var getRootIDs; +function utf16leSlice (buf, start, end) { + var bytes = buf.slice(start, end) + var res = '' + for (var i = 0; i < bytes.length; i += 2) { + res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256) + } + return res +} -if (canUseCollections) { - var itemMap = new Map(); - var rootIDSet = new Set(); +Buffer.prototype.slice = function slice (start, end) { + var len = this.length + start = ~~start + end = end === undefined ? len : ~~end - setItem = function (id, item) { - itemMap.set(id, item); - }; - getItem = function (id) { - return itemMap.get(id); - }; - removeItem = function (id) { - itemMap['delete'](id); - }; - getItemIDs = function () { - return Array.from(itemMap.keys()); - }; + if (start < 0) { + start += len + if (start < 0) start = 0 + } else if (start > len) { + start = len + } - addRoot = function (id) { - rootIDSet.add(id); - }; - removeRoot = function (id) { - rootIDSet['delete'](id); - }; - getRootIDs = function () { - return Array.from(rootIDSet.keys()); - }; -} else { - var itemByKey = {}; - var rootByKey = {}; + if (end < 0) { + end += len + if (end < 0) end = 0 + } else if (end > len) { + end = len + } - // Use non-numeric keys to prevent V8 performance issues: - // https://github.com/facebook/react/pull/7232 - var getKeyFromID = function (id) { - return '.' + id; - }; - var getIDFromKey = function (key) { - return parseInt(key.substr(1), 10); - }; + if (end < start) end = start - setItem = function (id, item) { - var key = getKeyFromID(id); - itemByKey[key] = item; - }; - getItem = function (id) { - var key = getKeyFromID(id); - return itemByKey[key]; - }; - removeItem = function (id) { - var key = getKeyFromID(id); - delete itemByKey[key]; - }; - getItemIDs = function () { - return Object.keys(itemByKey).map(getIDFromKey); - }; + var newBuf + if (Buffer.TYPED_ARRAY_SUPPORT) { + newBuf = this.subarray(start, end) + newBuf.__proto__ = Buffer.prototype + } else { + var sliceLen = end - start + newBuf = new Buffer(sliceLen, undefined) + for (var i = 0; i < sliceLen; ++i) { + newBuf[i] = this[i + start] + } + } - addRoot = function (id) { - var key = getKeyFromID(id); - rootByKey[key] = true; - }; - removeRoot = function (id) { - var key = getKeyFromID(id); - delete rootByKey[key]; - }; - getRootIDs = function () { - return Object.keys(rootByKey).map(getIDFromKey); - }; + return newBuf } -var unmountedIDs = []; +/* + * Need to make sure that buffer isn't trying to write out of bounds. + */ +function checkOffset (offset, ext, length) { + if ((offset % 1) !== 0 || offset < 0) throw new RangeError('offset is not uint') + if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length') +} -function purgeDeep(id) { - var item = getItem(id); - if (item) { - var childIDs = item.childIDs; +Buffer.prototype.readUIntLE = function readUIntLE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) - removeItem(id); - childIDs.forEach(purgeDeep); + var val = this[offset] + var mul = 1 + var i = 0 + while (++i < byteLength && (mul *= 0x100)) { + val += this[offset + i] * mul } -} -function describeComponentFrame(name, source, ownerName) { - return '\n in ' + (name || 'Unknown') + (source ? ' (at ' + source.fileName.replace(/^.*[\\\/]/, '') + ':' + source.lineNumber + ')' : ownerName ? ' (created by ' + ownerName + ')' : ''); + return val } -function getDisplayName(element) { - if (element == null) { - return '#empty'; - } else if (typeof element === 'string' || typeof element === 'number') { - return '#text'; - } else if (typeof element.type === 'string') { - return element.type; - } else { - return element.type.displayName || element.type.name || 'Unknown'; +Buffer.prototype.readUIntBE = function readUIntBE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + checkOffset(offset, byteLength, this.length) } -} -function describeID(id) { - var name = ReactComponentTreeHook.getDisplayName(id); - var element = ReactComponentTreeHook.getElement(id); - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var ownerName; - if (ownerID) { - ownerName = ReactComponentTreeHook.getDisplayName(ownerID); + var val = this[offset + --byteLength] + var mul = 1 + while (byteLength > 0 && (mul *= 0x100)) { + val += this[offset + --byteLength] * mul } - process.env.NODE_ENV !== 'production' ? warning(element, 'ReactComponentTreeHook: Missing React element for debugID %s when ' + 'building stack', id) : void 0; - return describeComponentFrame(name, element && element._source, ownerName); + + return val } -var ReactComponentTreeHook = { - onSetChildren: function (id, nextChildIDs) { - var item = getItem(id); - !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; - item.childIDs = nextChildIDs; +Buffer.prototype.readUInt8 = function readUInt8 (offset, noAssert) { + if (!noAssert) checkOffset(offset, 1, this.length) + return this[offset] +} - for (var i = 0; i < nextChildIDs.length; i++) { - var nextChildID = nextChildIDs[i]; - var nextChild = getItem(nextChildID); - !nextChild ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected hook events to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('140') : void 0; - !(nextChild.childIDs != null || typeof nextChild.element !== 'object' || nextChild.element == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onSetChildren() to fire for a container child before its parent includes it in onSetChildren().') : _prodInvariant('141') : void 0; - !nextChild.isMounted ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onMountComponent() to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('71') : void 0; - if (nextChild.parentID == null) { - nextChild.parentID = id; - // TODO: This shouldn't be necessary but mounting a new root during in - // componentWillMount currently causes not-yet-mounted components to - // be purged from our tree data so their parent id is missing. - } - !(nextChild.parentID === id) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onBeforeMountComponent() parent and onSetChildren() to be consistent (%s has parents %s and %s).', nextChildID, nextChild.parentID, id) : _prodInvariant('142', nextChildID, nextChild.parentID, id) : void 0; - } - }, - onBeforeMountComponent: function (id, element, parentID) { - var item = { - element: element, - parentID: parentID, - text: null, - childIDs: [], - isMounted: false, - updateCount: 0 - }; - setItem(id, item); - }, - onBeforeUpdateComponent: function (id, element) { - var item = getItem(id); - if (!item || !item.isMounted) { - // We may end up here as a result of setState() in componentWillUnmount(). - // In this case, ignore the element. - return; - } - item.element = element; - }, - onMountComponent: function (id) { - var item = getItem(id); - !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; - item.isMounted = true; - var isRoot = item.parentID === 0; - if (isRoot) { - addRoot(id); - } - }, - onUpdateComponent: function (id) { - var item = getItem(id); - if (!item || !item.isMounted) { - // We may end up here as a result of setState() in componentWillUnmount(). - // In this case, ignore the element. - return; - } - item.updateCount++; - }, - onUnmountComponent: function (id) { - var item = getItem(id); - if (item) { - // We need to check if it exists. - // `item` might not exist if it is inside an error boundary, and a sibling - // error boundary child threw while mounting. Then this instance never - // got a chance to mount, but it still gets an unmounting event during - // the error boundary cleanup. - item.isMounted = false; - var isRoot = item.parentID === 0; - if (isRoot) { - removeRoot(id); - } - } - unmountedIDs.push(id); - }, - purgeUnmountedComponents: function () { - if (ReactComponentTreeHook._preventPurging) { - // Should only be used for testing. - return; - } +Buffer.prototype.readUInt16LE = function readUInt16LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + return this[offset] | (this[offset + 1] << 8) +} - for (var i = 0; i < unmountedIDs.length; i++) { - var id = unmountedIDs[i]; - purgeDeep(id); - } - unmountedIDs.length = 0; - }, - isMounted: function (id) { - var item = getItem(id); - return item ? item.isMounted : false; - }, - getCurrentStackAddendum: function (topElement) { - var info = ''; - if (topElement) { - var name = getDisplayName(topElement); - var owner = topElement._owner; - info += describeComponentFrame(name, topElement._source, owner && owner.getName()); - } +Buffer.prototype.readUInt16BE = function readUInt16BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + return (this[offset] << 8) | this[offset + 1] +} - var currentOwner = ReactCurrentOwner.current; - var id = currentOwner && currentOwner._debugID; +Buffer.prototype.readUInt32LE = function readUInt32LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) - info += ReactComponentTreeHook.getStackAddendumByID(id); - return info; - }, - getStackAddendumByID: function (id) { - var info = ''; - while (id) { - info += describeID(id); - id = ReactComponentTreeHook.getParentID(id); - } - return info; - }, - getChildIDs: function (id) { - var item = getItem(id); - return item ? item.childIDs : []; - }, - getDisplayName: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (!element) { - return null; - } - return getDisplayName(element); - }, - getElement: function (id) { - var item = getItem(id); - return item ? item.element : null; - }, - getOwnerID: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (!element || !element._owner) { - return null; - } - return element._owner._debugID; - }, - getParentID: function (id) { - var item = getItem(id); - return item ? item.parentID : null; - }, - getSource: function (id) { - var item = getItem(id); - var element = item ? item.element : null; - var source = element != null ? element._source : null; - return source; - }, - getText: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (typeof element === 'string') { - return element; - } else if (typeof element === 'number') { - return '' + element; - } else { - return null; - } - }, - getUpdateCount: function (id) { - var item = getItem(id); - return item ? item.updateCount : 0; - }, + return ((this[offset]) | + (this[offset + 1] << 8) | + (this[offset + 2] << 16)) + + (this[offset + 3] * 0x1000000) +} +Buffer.prototype.readUInt32BE = function readUInt32BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) - getRootIDs: getRootIDs, - getRegisteredIDs: getItemIDs, + return (this[offset] * 0x1000000) + + ((this[offset + 1] << 16) | + (this[offset + 2] << 8) | + this[offset + 3]) +} - pushNonStandardWarningStack: function (isCreatingElement, currentSource) { - if (typeof console.reactStack !== 'function') { - return; - } +Buffer.prototype.readIntLE = function readIntLE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) - var stack = []; - var currentOwner = ReactCurrentOwner.current; - var id = currentOwner && currentOwner._debugID; + var val = this[offset] + var mul = 1 + var i = 0 + while (++i < byteLength && (mul *= 0x100)) { + val += this[offset + i] * mul + } + mul *= 0x80 - try { - if (isCreatingElement) { - stack.push({ - name: id ? ReactComponentTreeHook.getDisplayName(id) : null, - fileName: currentSource ? currentSource.fileName : null, - lineNumber: currentSource ? currentSource.lineNumber : null - }); - } + if (val >= mul) val -= Math.pow(2, 8 * byteLength) - while (id) { - var element = ReactComponentTreeHook.getElement(id); - var parentID = ReactComponentTreeHook.getParentID(id); - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var ownerName = ownerID ? ReactComponentTreeHook.getDisplayName(ownerID) : null; - var source = element && element._source; - stack.push({ - name: ownerName, - fileName: source ? source.fileName : null, - lineNumber: source ? source.lineNumber : null - }); - id = parentID; - } - } catch (err) { - // Internal state is messed up. - // Stop building the stack (it's just a nice to have). - } + return val +} - console.reactStack(stack); - }, - popNonStandardWarningStack: function () { - if (typeof console.reactStackEnd !== 'function') { - return; - } - console.reactStackEnd(); +Buffer.prototype.readIntBE = function readIntBE (offset, byteLength, noAssert) { + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) checkOffset(offset, byteLength, this.length) + + var i = byteLength + var mul = 1 + var val = this[offset + --i] + while (i > 0 && (mul *= 0x100)) { + val += this[offset + --i] * mul } -}; + mul *= 0x80 -module.exports = ReactComponentTreeHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + if (val >= mul) val -= Math.pow(2, 8 * byteLength) -/***/ }), -/* 11 */, -/* 12 */ -/***/ (function(module, exports, __webpack_require__) { + return val +} -"use strict"; +Buffer.prototype.readInt8 = function readInt8 (offset, noAssert) { + if (!noAssert) checkOffset(offset, 1, this.length) + if (!(this[offset] & 0x80)) return (this[offset]) + return ((0xff - this[offset] + 1) * -1) +} +Buffer.prototype.readInt16LE = function readInt16LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + var val = this[offset] | (this[offset + 1] << 8) + return (val & 0x8000) ? val | 0xFFFF0000 : val +} -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Buffer.prototype.readInt16BE = function readInt16BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 2, this.length) + var val = this[offset + 1] | (this[offset] << 8) + return (val & 0x8000) ? val | 0xFFFF0000 : val +} -function makeEmptyFunction(arg) { - return function () { - return arg; - }; +Buffer.prototype.readInt32LE = function readInt32LE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + + return (this[offset]) | + (this[offset + 1] << 8) | + (this[offset + 2] << 16) | + (this[offset + 3] << 24) } -/** - * This function accepts and discards inputs; it has no side effects. This is - * primarily useful idiomatically for overridable function endpoints which - * always need to be callable, since JS lacks a null-call idiom ala Cocoa. - */ -var emptyFunction = function emptyFunction() {}; +Buffer.prototype.readInt32BE = function readInt32BE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) -emptyFunction.thatReturns = makeEmptyFunction; -emptyFunction.thatReturnsFalse = makeEmptyFunction(false); -emptyFunction.thatReturnsTrue = makeEmptyFunction(true); -emptyFunction.thatReturnsNull = makeEmptyFunction(null); -emptyFunction.thatReturnsThis = function () { - return this; -}; -emptyFunction.thatReturnsArgument = function (arg) { - return arg; -}; + return (this[offset] << 24) | + (this[offset + 1] << 16) | + (this[offset + 2] << 8) | + (this[offset + 3]) +} -module.exports = emptyFunction; +Buffer.prototype.readFloatLE = function readFloatLE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + return ieee754.read(this, offset, true, 23, 4) +} -/***/ }), -/* 13 */ -/***/ (function(module, exports, __webpack_require__) { +Buffer.prototype.readFloatBE = function readFloatBE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 4, this.length) + return ieee754.read(this, offset, false, 23, 4) +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Buffer.prototype.readDoubleLE = function readDoubleLE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 8, this.length) + return ieee754.read(this, offset, true, 52, 8) +} +Buffer.prototype.readDoubleBE = function readDoubleBE (offset, noAssert) { + if (!noAssert) checkOffset(offset, 8, this.length) + return ieee754.read(this, offset, false, 52, 8) +} +function checkInt (buf, value, offset, ext, max, min) { + if (!Buffer.isBuffer(buf)) throw new TypeError('"buffer" argument must be a Buffer instance') + if (value > max || value < min) throw new RangeError('"value" argument is out of bounds') + if (offset + ext > buf.length) throw new RangeError('Index out of range') +} -// Trust the developer to only use ReactInstrumentation with a __DEV__ check +Buffer.prototype.writeUIntLE = function writeUIntLE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + var maxBytes = Math.pow(2, 8 * byteLength) - 1 + checkInt(this, value, offset, byteLength, maxBytes, 0) + } -var debugTool = null; + var mul = 1 + var i = 0 + this[offset] = value & 0xFF + while (++i < byteLength && (mul *= 0x100)) { + this[offset + i] = (value / mul) & 0xFF + } -if (process.env.NODE_ENV !== 'production') { - var ReactDebugTool = __webpack_require__(145); - debugTool = ReactDebugTool; + return offset + byteLength } -module.exports = { debugTool: debugTool }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 14 */ -/***/ (function(module, exports, __webpack_require__) { +Buffer.prototype.writeUIntBE = function writeUIntBE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + byteLength = byteLength | 0 + if (!noAssert) { + var maxBytes = Math.pow(2, 8 * byteLength) - 1 + checkInt(this, value, offset, byteLength, maxBytes, 0) + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var i = byteLength - 1 + var mul = 1 + this[offset + i] = value & 0xFF + while (--i >= 0 && (mul *= 0x100)) { + this[offset + i] = (value / mul) & 0xFF + } + return offset + byteLength +} +Buffer.prototype.writeUInt8 = function writeUInt8 (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0) + if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value) + this[offset] = (value & 0xff) + return offset + 1 +} -/** - * Keeps track of the current owner. - * - * The current owner is the component who should own any components that are - * currently being constructed. - */ -var ReactCurrentOwner = { - /** - * @internal - * @type {ReactComponent} - */ - current: null -}; +function objectWriteUInt16 (buf, value, offset, littleEndian) { + if (value < 0) value = 0xffff + value + 1 + for (var i = 0, j = Math.min(buf.length - offset, 2); i < j; ++i) { + buf[offset + i] = (value & (0xff << (8 * (littleEndian ? i : 1 - i)))) >>> + (littleEndian ? i : 1 - i) * 8 + } +} -module.exports = ReactCurrentOwner; +Buffer.prototype.writeUInt16LE = function writeUInt16LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + } else { + objectWriteUInt16(this, value, offset, true) + } + return offset + 2 +} -/***/ }), -/* 15 */ -/***/ (function(module, exports, __webpack_require__) { +Buffer.prototype.writeUInt16BE = function writeUInt16BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 8) + this[offset + 1] = (value & 0xff) + } else { + objectWriteUInt16(this, value, offset, false) + } + return offset + 2 +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function objectWriteUInt32 (buf, value, offset, littleEndian) { + if (value < 0) value = 0xffffffff + value + 1 + for (var i = 0, j = Math.min(buf.length - offset, 4); i < j; ++i) { + buf[offset + i] = (value >>> (littleEndian ? i : 3 - i) * 8) & 0xff + } +} +Buffer.prototype.writeUInt32LE = function writeUInt32LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset + 3] = (value >>> 24) + this[offset + 2] = (value >>> 16) + this[offset + 1] = (value >>> 8) + this[offset] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, true) + } + return offset + 4 +} +Buffer.prototype.writeUInt32BE = function writeUInt32BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 24) + this[offset + 1] = (value >>> 16) + this[offset + 2] = (value >>> 8) + this[offset + 3] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, false) + } + return offset + 4 +} -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +Buffer.prototype.writeIntLE = function writeIntLE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) { + var limit = Math.pow(2, 8 * byteLength - 1) -var CallbackQueue = __webpack_require__(85); -var PooledClass = __webpack_require__(20); -var ReactFeatureFlags = __webpack_require__(86); -var ReactReconciler = __webpack_require__(26); -var Transaction = __webpack_require__(41); + checkInt(this, value, offset, byteLength, limit - 1, -limit) + } -var invariant = __webpack_require__(1); + var i = 0 + var mul = 1 + var sub = 0 + this[offset] = value & 0xFF + while (++i < byteLength && (mul *= 0x100)) { + if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) { + sub = 1 + } + this[offset + i] = ((value / mul) >> 0) - sub & 0xFF + } -var dirtyComponents = []; -var updateBatchNumber = 0; -var asapCallbackQueue = CallbackQueue.getPooled(); -var asapEnqueued = false; + return offset + byteLength +} -var batchingStrategy = null; +Buffer.prototype.writeIntBE = function writeIntBE (value, offset, byteLength, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) { + var limit = Math.pow(2, 8 * byteLength - 1) -function ensureInjected() { - !(ReactUpdates.ReactReconcileTransaction && batchingStrategy) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must inject a reconcile transaction class and batching strategy') : _prodInvariant('123') : void 0; -} + checkInt(this, value, offset, byteLength, limit - 1, -limit) + } -var NESTED_UPDATES = { - initialize: function () { - this.dirtyComponentsLength = dirtyComponents.length; - }, - close: function () { - if (this.dirtyComponentsLength !== dirtyComponents.length) { - // Additional updates were enqueued by componentDidUpdate handlers or - // similar; before our own UPDATE_QUEUEING wrapper closes, we want to run - // these new updates so that if A's componentDidUpdate calls setState on - // B, B will update before the callback A's updater provided when calling - // setState. - dirtyComponents.splice(0, this.dirtyComponentsLength); - flushBatchedUpdates(); - } else { - dirtyComponents.length = 0; + var i = byteLength - 1 + var mul = 1 + var sub = 0 + this[offset + i] = value & 0xFF + while (--i >= 0 && (mul *= 0x100)) { + if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) { + sub = 1 } + this[offset + i] = ((value / mul) >> 0) - sub & 0xFF } -}; -var UPDATE_QUEUEING = { - initialize: function () { - this.callbackQueue.reset(); - }, - close: function () { - this.callbackQueue.notifyAll(); + return offset + byteLength +} + +Buffer.prototype.writeInt8 = function writeInt8 (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80) + if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value) + if (value < 0) value = 0xff + value + 1 + this[offset] = (value & 0xff) + return offset + 1 +} + +Buffer.prototype.writeInt16LE = function writeInt16LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + } else { + objectWriteUInt16(this, value, offset, true) } -}; + return offset + 2 +} -var TRANSACTION_WRAPPERS = [NESTED_UPDATES, UPDATE_QUEUEING]; +Buffer.prototype.writeInt16BE = function writeInt16BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 8) + this[offset + 1] = (value & 0xff) + } else { + objectWriteUInt16(this, value, offset, false) + } + return offset + 2 +} -function ReactUpdatesFlushTransaction() { - this.reinitializeTransaction(); - this.dirtyComponentsLength = null; - this.callbackQueue = CallbackQueue.getPooled(); - this.reconcileTransaction = ReactUpdates.ReactReconcileTransaction.getPooled( - /* useCreateElement */true); +Buffer.prototype.writeInt32LE = function writeInt32LE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000) + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value & 0xff) + this[offset + 1] = (value >>> 8) + this[offset + 2] = (value >>> 16) + this[offset + 3] = (value >>> 24) + } else { + objectWriteUInt32(this, value, offset, true) + } + return offset + 4 } -_assign(ReactUpdatesFlushTransaction.prototype, Transaction, { - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, +Buffer.prototype.writeInt32BE = function writeInt32BE (value, offset, noAssert) { + value = +value + offset = offset | 0 + if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000) + if (value < 0) value = 0xffffffff + value + 1 + if (Buffer.TYPED_ARRAY_SUPPORT) { + this[offset] = (value >>> 24) + this[offset + 1] = (value >>> 16) + this[offset + 2] = (value >>> 8) + this[offset + 3] = (value & 0xff) + } else { + objectWriteUInt32(this, value, offset, false) + } + return offset + 4 +} - destructor: function () { - this.dirtyComponentsLength = null; - CallbackQueue.release(this.callbackQueue); - this.callbackQueue = null; - ReactUpdates.ReactReconcileTransaction.release(this.reconcileTransaction); - this.reconcileTransaction = null; - }, +function checkIEEE754 (buf, value, offset, ext, max, min) { + if (offset + ext > buf.length) throw new RangeError('Index out of range') + if (offset < 0) throw new RangeError('Index out of range') +} - perform: function (method, scope, a) { - // Essentially calls `this.reconcileTransaction.perform(method, scope, a)` - // with this transaction's wrappers around it. - return Transaction.perform.call(this, this.reconcileTransaction.perform, this.reconcileTransaction, method, scope, a); +function writeFloat (buf, value, offset, littleEndian, noAssert) { + if (!noAssert) { + checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38) } -}); + ieee754.write(buf, value, offset, littleEndian, 23, 4) + return offset + 4 +} -PooledClass.addPoolingTo(ReactUpdatesFlushTransaction); +Buffer.prototype.writeFloatLE = function writeFloatLE (value, offset, noAssert) { + return writeFloat(this, value, offset, true, noAssert) +} -function batchedUpdates(callback, a, b, c, d, e) { - ensureInjected(); - return batchingStrategy.batchedUpdates(callback, a, b, c, d, e); +Buffer.prototype.writeFloatBE = function writeFloatBE (value, offset, noAssert) { + return writeFloat(this, value, offset, false, noAssert) } -/** - * Array comparator for ReactComponents by mount ordering. - * - * @param {ReactComponent} c1 first component you're comparing - * @param {ReactComponent} c2 second component you're comparing - * @return {number} Return value usable by Array.prototype.sort(). - */ -function mountOrderComparator(c1, c2) { - return c1._mountOrder - c2._mountOrder; +function writeDouble (buf, value, offset, littleEndian, noAssert) { + if (!noAssert) { + checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308) + } + ieee754.write(buf, value, offset, littleEndian, 52, 8) + return offset + 8 } -function runBatchedUpdates(transaction) { - var len = transaction.dirtyComponentsLength; - !(len === dirtyComponents.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected flush transaction\'s stored dirty-components length (%s) to match dirty-components array length (%s).', len, dirtyComponents.length) : _prodInvariant('124', len, dirtyComponents.length) : void 0; +Buffer.prototype.writeDoubleLE = function writeDoubleLE (value, offset, noAssert) { + return writeDouble(this, value, offset, true, noAssert) +} - // Since reconciling a component higher in the owner hierarchy usually (not - // always -- see shouldComponentUpdate()) will reconcile children, reconcile - // them before their children by sorting the array. - dirtyComponents.sort(mountOrderComparator); +Buffer.prototype.writeDoubleBE = function writeDoubleBE (value, offset, noAssert) { + return writeDouble(this, value, offset, false, noAssert) +} - // Any updates enqueued while reconciling must be performed after this entire - // batch. Otherwise, if dirtyComponents is [A, B] where A has children B and - // C, B could update twice in a single batch if C's render enqueues an update - // to B (since B would have already updated, we should skip it, and the only - // way we can know to do so is by checking the batch counter). - updateBatchNumber++; +// copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length) +Buffer.prototype.copy = function copy (target, targetStart, start, end) { + if (!start) start = 0 + if (!end && end !== 0) end = this.length + if (targetStart >= target.length) targetStart = target.length + if (!targetStart) targetStart = 0 + if (end > 0 && end < start) end = start - for (var i = 0; i < len; i++) { - // If a component is unmounted before pending changes apply, it will still - // be here, but we assume that it has cleared its _pendingCallbacks and - // that performUpdateIfNecessary is a noop. - var component = dirtyComponents[i]; + // Copy 0 bytes; we're done + if (end === start) return 0 + if (target.length === 0 || this.length === 0) return 0 - // If performUpdateIfNecessary happens to enqueue any new updates, we - // shouldn't execute the callbacks until the next render happens, so - // stash the callbacks first - var callbacks = component._pendingCallbacks; - component._pendingCallbacks = null; + // Fatal error conditions + if (targetStart < 0) { + throw new RangeError('targetStart out of bounds') + } + if (start < 0 || start >= this.length) throw new RangeError('sourceStart out of bounds') + if (end < 0) throw new RangeError('sourceEnd out of bounds') - var markerName; - if (ReactFeatureFlags.logTopLevelRenders) { - var namedComponent = component; - // Duck type TopLevelWrapper. This is probably always true. - if (component._currentElement.type.isReactTopLevelWrapper) { - namedComponent = component._renderedComponent; - } - markerName = 'React update: ' + namedComponent.getName(); - console.time(markerName); - } + // Are we oob? + if (end > this.length) end = this.length + if (target.length - targetStart < end - start) { + end = target.length - targetStart + start + } - ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction, updateBatchNumber); + var len = end - start + var i - if (markerName) { - console.timeEnd(markerName); + if (this === target && start < targetStart && targetStart < end) { + // descending copy from end + for (i = len - 1; i >= 0; --i) { + target[i + targetStart] = this[i + start] } - - if (callbacks) { - for (var j = 0; j < callbacks.length; j++) { - transaction.callbackQueue.enqueue(callbacks[j], component.getPublicInstance()); - } + } else if (len < 1000 || !Buffer.TYPED_ARRAY_SUPPORT) { + // ascending copy from start + for (i = 0; i < len; ++i) { + target[i + targetStart] = this[i + start] } + } else { + Uint8Array.prototype.set.call( + target, + this.subarray(start, start + len), + targetStart + ) } + + return len } -var flushBatchedUpdates = function () { - // ReactUpdatesFlushTransaction's wrappers will clear the dirtyComponents - // array and perform any updates enqueued by mount-ready handlers (i.e., - // componentDidUpdate) but we need to check here too in order to catch - // updates enqueued by setState callbacks and asap calls. - while (dirtyComponents.length || asapEnqueued) { - if (dirtyComponents.length) { - var transaction = ReactUpdatesFlushTransaction.getPooled(); - transaction.perform(runBatchedUpdates, null, transaction); - ReactUpdatesFlushTransaction.release(transaction); +// Usage: +// buffer.fill(number[, offset[, end]]) +// buffer.fill(buffer[, offset[, end]]) +// buffer.fill(string[, offset[, end]][, encoding]) +Buffer.prototype.fill = function fill (val, start, end, encoding) { + // Handle string cases: + if (typeof val === 'string') { + if (typeof start === 'string') { + encoding = start + start = 0 + end = this.length + } else if (typeof end === 'string') { + encoding = end + end = this.length + } + if (val.length === 1) { + var code = val.charCodeAt(0) + if (code < 256) { + val = code + } + } + if (encoding !== undefined && typeof encoding !== 'string') { + throw new TypeError('encoding must be a string') + } + if (typeof encoding === 'string' && !Buffer.isEncoding(encoding)) { + throw new TypeError('Unknown encoding: ' + encoding) } + } else if (typeof val === 'number') { + val = val & 255 + } - if (asapEnqueued) { - asapEnqueued = false; - var queue = asapCallbackQueue; - asapCallbackQueue = CallbackQueue.getPooled(); - queue.notifyAll(); - CallbackQueue.release(queue); + // Invalid ranges are not set to a default, so can range check early. + if (start < 0 || this.length < start || this.length < end) { + throw new RangeError('Out of range index') + } + + if (end <= start) { + return this + } + + start = start >>> 0 + end = end === undefined ? this.length : end >>> 0 + + if (!val) val = 0 + + var i + if (typeof val === 'number') { + for (i = start; i < end; ++i) { + this[i] = val + } + } else { + var bytes = Buffer.isBuffer(val) + ? val + : utf8ToBytes(new Buffer(val, encoding).toString()) + var len = bytes.length + for (i = 0; i < end - start; ++i) { + this[i + start] = bytes[i % len] } } -}; -/** - * Mark a component as needing a rerender, adding an optional callback to a - * list of functions which will be executed once the rerender occurs. - */ -function enqueueUpdate(component) { - ensureInjected(); + return this +} - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. (This is called by each top-level update - // function, like setState, forceUpdate, etc.; creation and - // destruction of top-level components is guarded in ReactMount.) +// HELPER FUNCTIONS +// ================ - if (!batchingStrategy.isBatchingUpdates) { - batchingStrategy.batchedUpdates(enqueueUpdate, component); - return; +var INVALID_BASE64_RE = /[^+\/0-9A-Za-z-_]/g + +function base64clean (str) { + // Node strips out invalid characters like \n and \t from the string, base64-js does not + str = stringtrim(str).replace(INVALID_BASE64_RE, '') + // Node converts strings with length < 2 to '' + if (str.length < 2) return '' + // Node allows for non-padded base64 strings (missing trailing ===), base64-js does not + while (str.length % 4 !== 0) { + str = str + '=' } + return str +} - dirtyComponents.push(component); - if (component._updateBatchNumber == null) { - component._updateBatchNumber = updateBatchNumber + 1; +function stringtrim (str) { + if (str.trim) return str.trim() + return str.replace(/^\s+|\s+$/g, '') +} + +function toHex (n) { + if (n < 16) return '0' + n.toString(16) + return n.toString(16) +} + +function utf8ToBytes (string, units) { + units = units || Infinity + var codePoint + var length = string.length + var leadSurrogate = null + var bytes = [] + + for (var i = 0; i < length; ++i) { + codePoint = string.charCodeAt(i) + + // is surrogate component + if (codePoint > 0xD7FF && codePoint < 0xE000) { + // last char was a lead + if (!leadSurrogate) { + // no lead yet + if (codePoint > 0xDBFF) { + // unexpected trail + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + continue + } else if (i + 1 === length) { + // unpaired lead + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + continue + } + + // valid lead + leadSurrogate = codePoint + + continue + } + + // 2 leads in a row + if (codePoint < 0xDC00) { + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + leadSurrogate = codePoint + continue + } + + // valid surrogate pair + codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000 + } else if (leadSurrogate) { + // valid bmp char, but last char was a lead + if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD) + } + + leadSurrogate = null + + // encode utf8 + if (codePoint < 0x80) { + if ((units -= 1) < 0) break + bytes.push(codePoint) + } else if (codePoint < 0x800) { + if ((units -= 2) < 0) break + bytes.push( + codePoint >> 0x6 | 0xC0, + codePoint & 0x3F | 0x80 + ) + } else if (codePoint < 0x10000) { + if ((units -= 3) < 0) break + bytes.push( + codePoint >> 0xC | 0xE0, + codePoint >> 0x6 & 0x3F | 0x80, + codePoint & 0x3F | 0x80 + ) + } else if (codePoint < 0x110000) { + if ((units -= 4) < 0) break + bytes.push( + codePoint >> 0x12 | 0xF0, + codePoint >> 0xC & 0x3F | 0x80, + codePoint >> 0x6 & 0x3F | 0x80, + codePoint & 0x3F | 0x80 + ) + } else { + throw new Error('Invalid code point') + } } + + return bytes } -/** - * Enqueue a callback to be run at the end of the current batching cycle. Throws - * if no updates are currently being performed. - */ -function asap(callback, context) { - !batchingStrategy.isBatchingUpdates ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates.asap: Can\'t enqueue an asap callback in a context whereupdates are not being batched.') : _prodInvariant('125') : void 0; - asapCallbackQueue.enqueue(callback, context); - asapEnqueued = true; +function asciiToBytes (str) { + var byteArray = [] + for (var i = 0; i < str.length; ++i) { + // Node's code seems to be doing this and not & 0x7F.. + byteArray.push(str.charCodeAt(i) & 0xFF) + } + return byteArray } -var ReactUpdatesInjection = { - injectReconcileTransaction: function (ReconcileTransaction) { - !ReconcileTransaction ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a reconcile transaction class') : _prodInvariant('126') : void 0; - ReactUpdates.ReactReconcileTransaction = ReconcileTransaction; - }, +function utf16leToBytes (str, units) { + var c, hi, lo + var byteArray = [] + for (var i = 0; i < str.length; ++i) { + if ((units -= 2) < 0) break - injectBatchingStrategy: function (_batchingStrategy) { - !_batchingStrategy ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batching strategy') : _prodInvariant('127') : void 0; - !(typeof _batchingStrategy.batchedUpdates === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batchedUpdates() function') : _prodInvariant('128') : void 0; - !(typeof _batchingStrategy.isBatchingUpdates === 'boolean') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide an isBatchingUpdates boolean attribute') : _prodInvariant('129') : void 0; - batchingStrategy = _batchingStrategy; + c = str.charCodeAt(i) + hi = c >> 8 + lo = c % 256 + byteArray.push(lo) + byteArray.push(hi) } -}; -var ReactUpdates = { - /** - * React references `ReactReconcileTransaction` using this property in order - * to allow dependency injection. - * - * @internal - */ - ReactReconcileTransaction: null, + return byteArray +} - batchedUpdates: batchedUpdates, - enqueueUpdate: enqueueUpdate, - flushBatchedUpdates: flushBatchedUpdates, - injection: ReactUpdatesInjection, - asap: asap -}; +function base64ToBytes (str) { + return base64.toByteArray(base64clean(str)) +} -module.exports = ReactUpdates; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function blitBuffer (src, dst, offset, length) { + for (var i = 0; i < length; ++i) { + if ((i + offset >= dst.length) || (i >= src.length)) break + dst[i + offset] = src[i] + } + return i +} + +function isnan (val) { + return val !== val // eslint-disable-line no-self-compare +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) /***/ }), -/* 16 */ +/* 2 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -1587,826 +2067,613 @@ module.exports = ReactUpdates; -var _assign = __webpack_require__(5); - -var PooledClass = __webpack_require__(20); - -var emptyFunction = __webpack_require__(12); -var warning = __webpack_require__(2); - -var didWarnForAddedNewProperty = false; -var isProxySupported = typeof Proxy === 'function'; - -var shouldBeReleasedProperties = ['dispatchConfig', '_targetInst', 'nativeEvent', 'isDefaultPrevented', 'isPropagationStopped', '_dispatchListeners', '_dispatchInstances']; - -/** - * @interface Event - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var EventInterface = { - type: null, - target: null, - // currentTarget is set when dispatching; no use in copying it here - currentTarget: emptyFunction.thatReturnsNull, - eventPhase: null, - bubbles: null, - cancelable: null, - timeStamp: function (event) { - return event.timeStamp || Date.now(); - }, - defaultPrevented: null, - isTrusted: null -}; - /** - * Synthetic events are dispatched by event plugins, typically in response to a - * top-level event delegation handler. - * - * These systems should generally use pooling to reduce the frequency of garbage - * collection. The system should check `isPersistent` to determine whether the - * event should be released into the pool after being dispatched. Users that - * need a persisted event should invoke `persist`. + * Use invariant() to assert state which your program assumes to be true. * - * Synthetic events (and subclasses) implement the DOM Level 3 Events API by - * normalizing browser quirks. Subclasses do not necessarily have to implement a - * DOM interface; custom application-specific events can also subclass this. + * Provide sprintf-style format (only %s is supported) and arguments + * to provide information about what broke and what you were + * expecting. * - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {*} targetInst Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @param {DOMEventTarget} nativeEventTarget Target node. + * The invariant message will be stripped in production, but the invariant + * will remain to ensure logic does not differ in production. */ -function SyntheticEvent(dispatchConfig, targetInst, nativeEvent, nativeEventTarget) { - if (process.env.NODE_ENV !== 'production') { - // these have a getter/setter for warnings - delete this.nativeEvent; - delete this.preventDefault; - delete this.stopPropagation; - } - this.dispatchConfig = dispatchConfig; - this._targetInst = targetInst; - this.nativeEvent = nativeEvent; +var validateFormat = function validateFormat(format) {}; - var Interface = this.constructor.Interface; - for (var propName in Interface) { - if (!Interface.hasOwnProperty(propName)) { - continue; - } - if (process.env.NODE_ENV !== 'production') { - delete this[propName]; // this has a getter/setter for warnings +if (process.env.NODE_ENV !== 'production') { + validateFormat = function validateFormat(format) { + if (format === undefined) { + throw new Error('invariant requires an error message argument'); } - var normalize = Interface[propName]; - if (normalize) { - this[propName] = normalize(nativeEvent); + }; +} + +function invariant(condition, format, a, b, c, d, e, f) { + validateFormat(format); + + if (!condition) { + var error; + if (format === undefined) { + error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); } else { - if (propName === 'target') { - this.target = nativeEventTarget; - } else { - this[propName] = nativeEvent[propName]; - } + var args = [a, b, c, d, e, f]; + var argIndex = 0; + error = new Error(format.replace(/%s/g, function () { + return args[argIndex++]; + })); + error.name = 'Invariant Violation'; } - } - var defaultPrevented = nativeEvent.defaultPrevented != null ? nativeEvent.defaultPrevented : nativeEvent.returnValue === false; - if (defaultPrevented) { - this.isDefaultPrevented = emptyFunction.thatReturnsTrue; - } else { - this.isDefaultPrevented = emptyFunction.thatReturnsFalse; + error.framesToPop = 1; // we don't care about invariant's own frame + throw error; } - this.isPropagationStopped = emptyFunction.thatReturnsFalse; - return this; } -_assign(SyntheticEvent.prototype, { - preventDefault: function () { - this.defaultPrevented = true; - var event = this.nativeEvent; - if (!event) { - return; - } - - if (event.preventDefault) { - event.preventDefault(); - // eslint-disable-next-line valid-typeof - } else if (typeof event.returnValue !== 'unknown') { - event.returnValue = false; - } - this.isDefaultPrevented = emptyFunction.thatReturnsTrue; - }, +module.exports = invariant; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - stopPropagation: function () { - var event = this.nativeEvent; - if (!event) { - return; - } +/***/ }), +/* 3 */ +/***/ (function(module, exports, __webpack_require__) { - if (event.stopPropagation) { - event.stopPropagation(); - // eslint-disable-next-line valid-typeof - } else if (typeof event.cancelBubble !== 'unknown') { - // The ChangeEventPlugin registers a "propertychange" event for - // IE. This event does not support bubbling or cancelling, and - // any references to cancelBubble throw "Member not found". A - // typeof check of "unknown" circumvents this issue (and is also - // IE specific). - event.cancelBubble = true; - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - this.isPropagationStopped = emptyFunction.thatReturnsTrue; - }, - /** - * We release all dispatched `SyntheticEvent`s after each event loop, adding - * them back into the pool. This allows a way to hold onto a reference that - * won't be added back into the pool. - */ - persist: function () { - this.isPersistent = emptyFunction.thatReturnsTrue; - }, - /** - * Checks if this event should be released back into the pool. - * - * @return {boolean} True if this should not be released, false otherwise. - */ - isPersistent: emptyFunction.thatReturnsFalse, +var emptyFunction = __webpack_require__(18); - /** - * `PooledClass` looks for `destructor` on each instance it releases. - */ - destructor: function () { - var Interface = this.constructor.Interface; - for (var propName in Interface) { - if (process.env.NODE_ENV !== 'production') { - Object.defineProperty(this, propName, getPooledWarningPropertyDefinition(propName, Interface[propName])); - } else { - this[propName] = null; - } - } - for (var i = 0; i < shouldBeReleasedProperties.length; i++) { - this[shouldBeReleasedProperties[i]] = null; - } - if (process.env.NODE_ENV !== 'production') { - Object.defineProperty(this, 'nativeEvent', getPooledWarningPropertyDefinition('nativeEvent', null)); - Object.defineProperty(this, 'preventDefault', getPooledWarningPropertyDefinition('preventDefault', emptyFunction)); - Object.defineProperty(this, 'stopPropagation', getPooledWarningPropertyDefinition('stopPropagation', emptyFunction)); - } - } -}); +/** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ -SyntheticEvent.Interface = EventInterface; +var warning = emptyFunction; if (process.env.NODE_ENV !== 'production') { - if (isProxySupported) { - /*eslint-disable no-func-assign */ - SyntheticEvent = new Proxy(SyntheticEvent, { - construct: function (target, args) { - return this.apply(target, Object.create(target.prototype), args); - }, - apply: function (constructor, that, args) { - return new Proxy(constructor.apply(that, args), { - set: function (target, prop, value) { - if (prop !== 'isPersistent' && !target.constructor.Interface.hasOwnProperty(prop) && shouldBeReleasedProperties.indexOf(prop) === -1) { - process.env.NODE_ENV !== 'production' ? warning(didWarnForAddedNewProperty || target.isPersistent(), "This synthetic event is reused for performance reasons. If you're " + "seeing this, you're adding a new property in the synthetic event object. " + 'The property is never released. See ' + 'https://fb.me/react-event-pooling for more information.') : void 0; - didWarnForAddedNewProperty = true; - } - target[prop] = value; - return true; - } - }); + (function () { + var printWarning = function printWarning(format) { + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; } - }); - /*eslint-enable no-func-assign */ - } -} -/** - * Helper to reduce boilerplate when creating subclasses. - * - * @param {function} Class - * @param {?object} Interface - */ -SyntheticEvent.augmentClass = function (Class, Interface) { - var Super = this; - var E = function () {}; - E.prototype = Super.prototype; - var prototype = new E(); - - _assign(prototype, Class.prototype); - Class.prototype = prototype; - Class.prototype.constructor = Class; - - Class.Interface = _assign({}, Super.Interface, Interface); - Class.augmentClass = Super.augmentClass; + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.error(message); + } + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} + }; - PooledClass.addPoolingTo(Class, PooledClass.fourArgumentPooler); -}; + warning = function warning(condition, format) { + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + } -PooledClass.addPoolingTo(SyntheticEvent, PooledClass.fourArgumentPooler); + if (format.indexOf('Failed Composite propType: ') === 0) { + return; // Ignore CompositeComponent proptype check. + } -module.exports = SyntheticEvent; + if (!condition) { + for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { + args[_key2 - 2] = arguments[_key2]; + } -/** - * Helper to nullify syntheticEvent instance properties when destructing - * - * @param {object} SyntheticEvent - * @param {String} propName - * @return {object} defineProperty object - */ -function getPooledWarningPropertyDefinition(propName, getVal) { - var isFunction = typeof getVal === 'function'; - return { - configurable: true, - set: set, - get: get - }; + printWarning.apply(undefined, [format].concat(args)); + } + }; + })(); +} - function set(val) { - var action = isFunction ? 'setting the method' : 'setting the property'; - warn(action, 'This is effectively a no-op'); - return val; - } +module.exports = warning; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - function get() { - var action = isFunction ? 'accessing the method' : 'accessing the property'; - var result = isFunction ? 'This is a no-op function' : 'This is set to null'; - warn(action, result); - return getVal; - } +/***/ }), +/* 4 */ +/***/ (function(module, exports) { - function warn(action, result) { - var warningCondition = false; - process.env.NODE_ENV !== 'production' ? warning(warningCondition, "This synthetic event is reused for performance reasons. If you're seeing this, " + "you're %s `%s` on a released/nullified synthetic event. %s. " + 'If you must keep the original synthetic event around, use event.persist(). ' + 'See https://fb.me/react-event-pooling for more information.', action, propName, result) : void 0; +if (typeof Object.create === 'function') { + // implementation from standard node.js 'util' module + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + ctor.prototype = Object.create(superCtor.prototype, { + constructor: { + value: ctor, + enumerable: false, + writable: true, + configurable: true + } + }); + }; +} else { + // old school shim for old browsers + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + var TempCtor = function () {} + TempCtor.prototype = superCtor.prototype + ctor.prototype = new TempCtor() + ctor.prototype.constructor = ctor } } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + /***/ }), -/* 17 */ +/* 5 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. +/** + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * + */ + + +/** + * WARNING: DO NOT manually require this module. + * This is a replacement for `invariant(...)` used by the error code system + * and will _only_ be required by the corresponding babel pass. + * It always throws. */ +function reactProdInvariant(code) { + var argCount = arguments.length - 1; + var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; -var _prodInvariant = __webpack_require__(3); + for (var argIdx = 0; argIdx < argCount; argIdx++) { + message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); + } -var invariant = __webpack_require__(1); + message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; -function checkMask(value, bitmask) { - return (value & bitmask) === bitmask; + var error = new Error(message); + error.name = 'Invariant Violation'; + error.framesToPop = 1; // we don't care about reactProdInvariant's own frame + + throw error; } -var DOMPropertyInjection = { - /** - * Mapping from normalized, camelcased property names to a configuration that - * specifies how the associated DOM property should be accessed or rendered. - */ - MUST_USE_PROPERTY: 0x1, - HAS_BOOLEAN_VALUE: 0x4, - HAS_NUMERIC_VALUE: 0x8, - HAS_POSITIVE_NUMERIC_VALUE: 0x10 | 0x8, - HAS_OVERLOADED_BOOLEAN_VALUE: 0x20, +module.exports = reactProdInvariant; - /** - * Inject some specialized knowledge about the DOM. This takes a config object - * with the following properties: - * - * isCustomAttribute: function that given an attribute name will return true - * if it can be inserted into the DOM verbatim. Useful for data-* or aria-* - * attributes where it's impossible to enumerate all of the possible - * attribute names, - * - * Properties: object mapping DOM property name to one of the - * DOMPropertyInjection constants or null. If your attribute isn't in here, - * it won't get written to the DOM. - * - * DOMAttributeNames: object mapping React attribute name to the DOM - * attribute name. Attribute names not specified use the **lowercase** - * normalized name. - * - * DOMAttributeNamespaces: object mapping React attribute name to the DOM - * attribute namespace URL. (Attribute names not specified use no namespace.) - * - * DOMPropertyNames: similar to DOMAttributeNames but for DOM properties. - * Property names not specified use the normalized name. - * - * DOMMutationMethods: Properties that require special mutation methods. If - * `value` is undefined, the mutation method should unset the property. - * - * @param {object} domPropertyConfig the config as described above. - */ - injectDOMPropertyConfig: function (domPropertyConfig) { - var Injection = DOMPropertyInjection; - var Properties = domPropertyConfig.Properties || {}; - var DOMAttributeNamespaces = domPropertyConfig.DOMAttributeNamespaces || {}; - var DOMAttributeNames = domPropertyConfig.DOMAttributeNames || {}; - var DOMPropertyNames = domPropertyConfig.DOMPropertyNames || {}; - var DOMMutationMethods = domPropertyConfig.DOMMutationMethods || {}; +/***/ }), +/* 6 */ +/***/ (function(module, exports, __webpack_require__) { - if (domPropertyConfig.isCustomAttribute) { - DOMProperty._isCustomAttributeFunctions.push(domPropertyConfig.isCustomAttribute); - } +"use strict"; - for (var propName in Properties) { - !!DOMProperty.properties.hasOwnProperty(propName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'injectDOMPropertyConfig(...): You\'re trying to inject DOM property \'%s\' which has already been injected. You may be accidentally injecting the same DOM property config twice, or you may be injecting two configs that have conflicting property names.', propName) : _prodInvariant('48', propName) : void 0; - var lowerCased = propName.toLowerCase(); - var propConfig = Properties[propName]; +module.exports = __webpack_require__(36); - var propertyInfo = { - attributeName: lowerCased, - attributeNamespace: null, - propertyName: propName, - mutationMethod: null, - mustUseProperty: checkMask(propConfig, Injection.MUST_USE_PROPERTY), - hasBooleanValue: checkMask(propConfig, Injection.HAS_BOOLEAN_VALUE), - hasNumericValue: checkMask(propConfig, Injection.HAS_NUMERIC_VALUE), - hasPositiveNumericValue: checkMask(propConfig, Injection.HAS_POSITIVE_NUMERIC_VALUE), - hasOverloadedBooleanValue: checkMask(propConfig, Injection.HAS_OVERLOADED_BOOLEAN_VALUE) - }; - !(propertyInfo.hasBooleanValue + propertyInfo.hasNumericValue + propertyInfo.hasOverloadedBooleanValue <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'DOMProperty: Value can be one of boolean, overloaded boolean, or numeric value, but not a combination: %s', propName) : _prodInvariant('50', propName) : void 0; +/***/ }), +/* 7 */ +/***/ (function(module, exports, __webpack_require__) { - if (process.env.NODE_ENV !== 'production') { - DOMProperty.getPossibleStandardName[lowerCased] = propName; - } +/* eslint-disable node/no-deprecated-api */ +var buffer = __webpack_require__(1) +var Buffer = buffer.Buffer - if (DOMAttributeNames.hasOwnProperty(propName)) { - var attributeName = DOMAttributeNames[propName]; - propertyInfo.attributeName = attributeName; - if (process.env.NODE_ENV !== 'production') { - DOMProperty.getPossibleStandardName[attributeName] = propName; - } - } +// alternative to using Object.keys for old browsers +function copyProps (src, dst) { + for (var key in src) { + dst[key] = src[key] + } +} +if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { + module.exports = buffer +} else { + // Copy properties from require('buffer') + copyProps(buffer, exports) + exports.Buffer = SafeBuffer +} - if (DOMAttributeNamespaces.hasOwnProperty(propName)) { - propertyInfo.attributeNamespace = DOMAttributeNamespaces[propName]; - } +function SafeBuffer (arg, encodingOrOffset, length) { + return Buffer(arg, encodingOrOffset, length) +} - if (DOMPropertyNames.hasOwnProperty(propName)) { - propertyInfo.propertyName = DOMPropertyNames[propName]; - } +// Copy static methods from Buffer +copyProps(Buffer, SafeBuffer) - if (DOMMutationMethods.hasOwnProperty(propName)) { - propertyInfo.mutationMethod = DOMMutationMethods[propName]; - } +SafeBuffer.from = function (arg, encodingOrOffset, length) { + if (typeof arg === 'number') { + throw new TypeError('Argument must not be a number') + } + return Buffer(arg, encodingOrOffset, length) +} - DOMProperty.properties[propName] = propertyInfo; +SafeBuffer.alloc = function (size, fill, encoding) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + var buf = Buffer(size) + if (fill !== undefined) { + if (typeof encoding === 'string') { + buf.fill(fill, encoding) + } else { + buf.fill(fill) } + } else { + buf.fill(0) } -}; + return buf +} -/* eslint-disable max-len */ -var ATTRIBUTE_NAME_START_CHAR = ':A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD'; -/* eslint-enable max-len */ +SafeBuffer.allocUnsafe = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return Buffer(size) +} -/** - * DOMProperty exports lookup objects that can be used like functions: - * - * > DOMProperty.isValid['id'] - * true - * > DOMProperty.isValid['foobar'] - * undefined - * - * Although this may be confusing, it performs better in general. - * - * @see http://jsperf.com/key-exists - * @see http://jsperf.com/key-missing - */ -var DOMProperty = { - ID_ATTRIBUTE_NAME: 'data-reactid', - ROOT_ATTRIBUTE_NAME: 'data-reactroot', +SafeBuffer.allocUnsafeSlow = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return buffer.SlowBuffer(size) +} - ATTRIBUTE_NAME_START_CHAR: ATTRIBUTE_NAME_START_CHAR, - ATTRIBUTE_NAME_CHAR: ATTRIBUTE_NAME_START_CHAR + '\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040', - /** - * Map from property "standard name" to an object with info about how to set - * the property in the DOM. Each object contains: - * - * attributeName: - * Used when rendering markup or with `*Attribute()`. - * attributeNamespace - * propertyName: - * Used on DOM node instances. (This includes properties that mutate due to - * external factors.) - * mutationMethod: - * If non-null, used instead of the property or `setAttribute()` after - * initial render. - * mustUseProperty: - * Whether the property must be accessed and mutated as an object property. - * hasBooleanValue: - * Whether the property should be removed when set to a falsey value. - * hasNumericValue: - * Whether the property must be numeric or parse as a numeric and should be - * removed when set to a falsey value. - * hasPositiveNumericValue: - * Whether the property must be positive numeric or parse as a positive - * numeric and should be removed when set to a falsey value. - * hasOverloadedBooleanValue: - * Whether the property can be used as a flag as well as with a value. - * Removed when strictly equal to false; present without a value when - * strictly equal to true; present with a value otherwise. - */ - properties: {}, +/***/ }), +/* 8 */ +/***/ (function(module, exports, __webpack_require__) { - /** - * Mapping from lowercase property names to the properly cased version, used - * to warn in the case of missing properties. Available only in __DEV__. - * - * autofocus is predefined, because adding it to the property whitelist - * causes unintended side effects. - * - * @type {Object} - */ - getPossibleStandardName: process.env.NODE_ENV !== 'production' ? { autofocus: 'autoFocus' } : null, +"use strict"; +/* +object-assign +(c) Sindre Sorhus +@license MIT +*/ - /** - * All of the isCustomAttribute() functions that have been injected. - */ - _isCustomAttributeFunctions: [], - /** - * Checks whether a property name is a custom attribute. - * @method - */ - isCustomAttribute: function (attributeName) { - for (var i = 0; i < DOMProperty._isCustomAttributeFunctions.length; i++) { - var isCustomAttributeFn = DOMProperty._isCustomAttributeFunctions[i]; - if (isCustomAttributeFn(attributeName)) { - return true; - } - } - return false; - }, +/* eslint-disable no-unused-vars */ +var getOwnPropertySymbols = Object.getOwnPropertySymbols; +var hasOwnProperty = Object.prototype.hasOwnProperty; +var propIsEnumerable = Object.prototype.propertyIsEnumerable; - injection: DOMPropertyInjection +function toObject(val) { + if (val === null || val === undefined) { + throw new TypeError('Object.assign cannot be called with null or undefined'); + } + + return Object(val); +} + +function shouldUseNative() { + try { + if (!Object.assign) { + return false; + } + + // Detect buggy property enumeration order in older V8 versions. + + // https://bugs.chromium.org/p/v8/issues/detail?id=4118 + var test1 = new String('abc'); // eslint-disable-line no-new-wrappers + test1[5] = 'de'; + if (Object.getOwnPropertyNames(test1)[0] === '5') { + return false; + } + + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test2 = {}; + for (var i = 0; i < 10; i++) { + test2['_' + String.fromCharCode(i)] = i; + } + var order2 = Object.getOwnPropertyNames(test2).map(function (n) { + return test2[n]; + }); + if (order2.join('') !== '0123456789') { + return false; + } + + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test3 = {}; + 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { + test3[letter] = letter; + }); + if (Object.keys(Object.assign({}, test3)).join('') !== + 'abcdefghijklmnopqrst') { + return false; + } + + return true; + } catch (err) { + // We don't expect any of the above to throw, but better to be safe. + return false; + } +} + +module.exports = shouldUseNative() ? Object.assign : function (target, source) { + var from; + var to = toObject(target); + var symbols; + + for (var s = 1; s < arguments.length; s++) { + from = Object(arguments[s]); + + for (var key in from) { + if (hasOwnProperty.call(from, key)) { + to[key] = from[key]; + } + } + + if (getOwnPropertySymbols) { + symbols = getOwnPropertySymbols(from); + for (var i = 0; i < symbols.length; i++) { + if (propIsEnumerable.call(from, symbols[i])) { + to[symbols[i]] = from[symbols[i]]; + } + } + } + } + + return to; }; -module.exports = DOMProperty; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 18 */, -/* 19 */ +/* 9 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var ERRORS = __webpack_require__(201) +var NATIVE = __webpack_require__(111) +// short-hand +var tfJSON = ERRORS.tfJSON +var TfTypeError = ERRORS.TfTypeError +var TfPropertyTypeError = ERRORS.TfPropertyTypeError +var tfSubError = ERRORS.tfSubError +var getValueTypeName = ERRORS.getValueTypeName +var TYPES = { + arrayOf: function arrayOf (type) { + type = compile(type) -var _assign = __webpack_require__(5); + function _arrayOf (array, strict) { + if (!NATIVE.Array(array)) return false -var ReactCurrentOwner = __webpack_require__(14); + return array.every(function (value, i) { + try { + return typeforce(type, value, strict) + } catch (e) { + throw tfSubError(e, i) + } + }) + } + _arrayOf.toJSON = function () { return '[' + tfJSON(type) + ']' } -var warning = __webpack_require__(2); -var canDefineProperty = __webpack_require__(38); -var hasOwnProperty = Object.prototype.hasOwnProperty; + return _arrayOf + }, -var REACT_ELEMENT_TYPE = __webpack_require__(76); + maybe: function maybe (type) { + type = compile(type) -var RESERVED_PROPS = { - key: true, - ref: true, - __self: true, - __source: true -}; + function _maybe (value, strict) { + return NATIVE.Nil(value) || type(value, strict, maybe) + } + _maybe.toJSON = function () { return '?' + tfJSON(type) } -var specialPropKeyWarningShown, specialPropRefWarningShown; + return _maybe + }, -function hasValidRef(config) { - if (process.env.NODE_ENV !== 'production') { - if (hasOwnProperty.call(config, 'ref')) { - var getter = Object.getOwnPropertyDescriptor(config, 'ref').get; - if (getter && getter.isReactWarning) { - return false; + map: function map (propertyType, propertyKeyType) { + propertyType = compile(propertyType) + if (propertyKeyType) propertyKeyType = compile(propertyKeyType) + + function _map (value, strict) { + if (!NATIVE.Object(value, strict)) return false + if (NATIVE.Nil(value, strict)) return false + + for (var propertyName in value) { + try { + if (propertyKeyType) { + typeforce(propertyKeyType, propertyName, strict) + } + } catch (e) { + throw tfSubError(e, propertyName, 'key') + } + + try { + var propertyValue = value[propertyName] + typeforce(propertyType, propertyValue, strict) + } catch (e) { + throw tfSubError(e, propertyName) + } } + + return true } - } - return config.ref !== undefined; -} -function hasValidKey(config) { - if (process.env.NODE_ENV !== 'production') { - if (hasOwnProperty.call(config, 'key')) { - var getter = Object.getOwnPropertyDescriptor(config, 'key').get; - if (getter && getter.isReactWarning) { - return false; + if (propertyKeyType) { + _map.toJSON = function () { + return '{' + tfJSON(propertyKeyType) + ': ' + tfJSON(propertyType) + '}' } + } else { + _map.toJSON = function () { return '{' + tfJSON(propertyType) + '}' } } - } - return config.key !== undefined; -} -function defineKeyPropWarningGetter(props, displayName) { - var warnAboutAccessingKey = function () { - if (!specialPropKeyWarningShown) { - specialPropKeyWarningShown = true; - process.env.NODE_ENV !== 'production' ? warning(false, '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; - } - }; - warnAboutAccessingKey.isReactWarning = true; - Object.defineProperty(props, 'key', { - get: warnAboutAccessingKey, - configurable: true - }); -} + return _map + }, -function defineRefPropWarningGetter(props, displayName) { - var warnAboutAccessingRef = function () { - if (!specialPropRefWarningShown) { - specialPropRefWarningShown = true; - process.env.NODE_ENV !== 'production' ? warning(false, '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + object: function object (uncompiled) { + var type = {} + + for (var typePropertyName in uncompiled) { + type[typePropertyName] = compile(uncompiled[typePropertyName]) } - }; - warnAboutAccessingRef.isReactWarning = true; - Object.defineProperty(props, 'ref', { - get: warnAboutAccessingRef, - configurable: true - }); -} -/** - * Factory method to create a new React element. This no longer adheres to - * the class pattern, so do not use new to call it. Also, no instanceof check - * will work. Instead test $$typeof field against Symbol.for('react.element') to check - * if something is a React Element. - * - * @param {*} type - * @param {*} key - * @param {string|object} ref - * @param {*} self A *temporary* helper to detect places where `this` is - * different from the `owner` when React.createElement is called, so that we - * can warn. We want to get rid of owner and replace string `ref`s with arrow - * functions, and as long as `this` and owner are the same, there will be no - * change in behavior. - * @param {*} source An annotation object (added by a transpiler or otherwise) - * indicating filename, line number, and/or other information. - * @param {*} owner - * @param {*} props - * @internal - */ -var ReactElement = function (type, key, ref, self, source, owner, props) { - var element = { - // This tag allow us to uniquely identify this as a React Element - $$typeof: REACT_ELEMENT_TYPE, + function _object (value, strict) { + if (!NATIVE.Object(value)) return false + if (NATIVE.Nil(value)) return false - // Built-in properties that belong on the element - type: type, - key: key, - ref: ref, - props: props, + var propertyName - // Record the component responsible for creating this element. - _owner: owner - }; + try { + for (propertyName in type) { + var propertyType = type[propertyName] + var propertyValue = value[propertyName] - if (process.env.NODE_ENV !== 'production') { - // The validation flag is currently mutative. We put it on - // an external backing store so that we can freeze the whole object. - // This can be replaced with a WeakMap once they are implemented in - // commonly used development environments. - element._store = {}; + typeforce(propertyType, propertyValue, strict) + } + } catch (e) { + throw tfSubError(e, propertyName) + } - // To make comparing ReactElements easier for testing purposes, we make - // the validation flag non-enumerable (where possible, which should - // include every environment we run tests in), so the test framework - // ignores it. - if (canDefineProperty) { - Object.defineProperty(element._store, 'validated', { - configurable: false, - enumerable: false, - writable: true, - value: false - }); - // self and source are DEV only properties. - Object.defineProperty(element, '_self', { - configurable: false, - enumerable: false, - writable: false, - value: self - }); - // Two elements created in two different places should be considered - // equal for testing purposes and therefore we hide it from enumeration. - Object.defineProperty(element, '_source', { - configurable: false, - enumerable: false, - writable: false, - value: source - }); - } else { - element._store.validated = false; - element._self = self; - element._source = source; - } - if (Object.freeze) { - Object.freeze(element.props); - Object.freeze(element); - } - } + if (strict) { + for (propertyName in value) { + if (type[propertyName]) continue - return element; -}; + throw new TfPropertyTypeError(undefined, propertyName) + } + } -/** - * Create and return a new ReactElement of the given type. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createelement - */ -ReactElement.createElement = function (type, config, children) { - var propName; + return true + } + _object.toJSON = function () { return tfJSON(type) } - // Reserved names are extracted - var props = {}; + return _object + }, - var key = null; - var ref = null; - var self = null; - var source = null; + oneOf: function oneOf () { + var types = [].slice.call(arguments).map(compile) - if (config != null) { - if (hasValidRef(config)) { - ref = config.ref; - } - if (hasValidKey(config)) { - key = '' + config.key; + function _oneOf (value, strict) { + return types.some(function (type) { + try { + return typeforce(type, value, strict) + } catch (e) { + return false + } + }) } + _oneOf.toJSON = function () { return types.map(tfJSON).join('|') } - self = config.__self === undefined ? null : config.__self; - source = config.__source === undefined ? null : config.__source; - // Remaining properties are added to a new props object - for (propName in config) { - if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { - props[propName] = config[propName]; - } - } - } + return _oneOf + }, - // Children can be more than one argument, and those are transferred onto - // the newly allocated props object. - var childrenLength = arguments.length - 2; - if (childrenLength === 1) { - props.children = children; - } else if (childrenLength > 1) { - var childArray = Array(childrenLength); - for (var i = 0; i < childrenLength; i++) { - childArray[i] = arguments[i + 2]; + quacksLike: function quacksLike (type) { + function _quacksLike (value) { + return type === getValueTypeName(value) } - if (process.env.NODE_ENV !== 'production') { - if (Object.freeze) { - Object.freeze(childArray); - } + _quacksLike.toJSON = function () { return type } + + return _quacksLike + }, + + tuple: function tuple () { + var types = [].slice.call(arguments).map(compile) + + function _tuple (values, strict) { + return types.every(function (type, i) { + try { + return typeforce(type, values[i], strict) + } catch (e) { + throw tfSubError(e, i) + } + }) && (!strict || values.length === arguments.length) } - props.children = childArray; - } + _tuple.toJSON = function () { return '(' + types.map(tfJSON).join(', ') + ')' } - // Resolve default props - if (type && type.defaultProps) { - var defaultProps = type.defaultProps; - for (propName in defaultProps) { - if (props[propName] === undefined) { - props[propName] = defaultProps[propName]; - } + return _tuple + }, + + value: function value (expected) { + function _value (actual) { + return actual === expected } + _value.toJSON = function () { return expected } + + return _value } - if (process.env.NODE_ENV !== 'production') { - if (key || ref) { - if (typeof props.$$typeof === 'undefined' || props.$$typeof !== REACT_ELEMENT_TYPE) { - var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type; - if (key) { - defineKeyPropWarningGetter(props, displayName); - } - if (ref) { - defineRefPropWarningGetter(props, displayName); - } - } - } +} + +function compile (type) { + if (NATIVE.String(type)) { + if (type[0] === '?') return TYPES.maybe(compile(type.slice(1))) + + return NATIVE[type] || TYPES.quacksLike(type) + } else if (type && NATIVE.Object(type)) { + if (NATIVE.Array(type)) return TYPES.arrayOf(compile(type[0])) + + return TYPES.object(type) + } else if (NATIVE.Function(type)) { + return type } - return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props); -}; -/** - * Return a function that produces ReactElements of a given type. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createfactory - */ -ReactElement.createFactory = function (type) { - var factory = ReactElement.createElement.bind(null, type); - // Expose the type on the factory and the prototype so that it can be - // easily accessed on elements. E.g. `<Foo />.type === Foo`. - // This should not be named `constructor` since this may not be the function - // that created the element, and it may not even be a constructor. - // Legacy hook TODO: Warn if this is accessed - factory.type = type; - return factory; -}; + return TYPES.value(type) +} -ReactElement.cloneAndReplaceKey = function (oldElement, newKey) { - var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props); +function typeforce (type, value, strict, surrogate) { + if (NATIVE.Function(type)) { + if (type(value, strict)) return true - return newElement; -}; + throw new TfTypeError(surrogate || type, value) + } -/** - * Clone and return a new ReactElement using element as the starting point. - * See https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement - */ -ReactElement.cloneElement = function (element, config, children) { - var propName; + // JIT + return typeforce(compile(type), value, strict) +} - // Original props are copied - var props = _assign({}, element.props); +// assign types to typeforce function +for (var typeName in NATIVE) { + typeforce[typeName] = NATIVE[typeName] +} - // Reserved names are extracted - var key = element.key; - var ref = element.ref; - // Self is preserved since the owner is preserved. - var self = element._self; - // Source is preserved since cloneElement is unlikely to be targeted by a - // transpiler, and the original source is probably a better indicator of the - // true owner. - var source = element._source; +for (typeName in TYPES) { + typeforce[typeName] = TYPES[typeName] +} - // Owner will be preserved, unless ref is overridden - var owner = element._owner; +var EXTRA = __webpack_require__(467) +for (typeName in EXTRA) { + typeforce[typeName] = EXTRA[typeName] +} - if (config != null) { - if (hasValidRef(config)) { - // Silently steal the ref from the parent. - ref = config.ref; - owner = ReactCurrentOwner.current; - } - if (hasValidKey(config)) { - key = '' + config.key; - } +// async wrapper +function __async (type, value, strict, callback) { + // default to falsy strict if using shorthand overload + if (typeof strict === 'function') return __async(type, value, false, strict) - // Remaining properties override existing props - var defaultProps; - if (element.type && element.type.defaultProps) { - defaultProps = element.type.defaultProps; - } - for (propName in config) { - if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { - if (config[propName] === undefined && defaultProps !== undefined) { - // Resolve default props - props[propName] = defaultProps[propName]; - } else { - props[propName] = config[propName]; - } - } - } + try { + typeforce(type, value, strict) + } catch (e) { + return callback(e) } - // Children can be more than one argument, and those are transferred onto - // the newly allocated props object. - var childrenLength = arguments.length - 2; - if (childrenLength === 1) { - props.children = children; - } else if (childrenLength > 1) { - var childArray = Array(childrenLength); - for (var i = 0; i < childrenLength; i++) { - childArray[i] = arguments[i + 2]; - } - props.children = childArray; - } + callback() +} - return ReactElement(element.type, key, ref, self, source, owner, props); -}; +typeforce.async = __async +typeforce.compile = compile +typeforce.TfTypeError = TfTypeError +typeforce.TfPropertyTypeError = TfPropertyTypeError -/** - * Verifies the object is a ReactElement. - * See https://facebook.github.io/react/docs/top-level-api.html#react.isvalidelement - * @param {?object} object - * @return {boolean} True if `object` is a valid component. - * @final - */ -ReactElement.isValidElement = function (object) { - return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE; -}; +module.exports = typeforce -module.exports = ReactElement; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 20 */ +/* 10 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -2418,2483 +2685,3695 @@ module.exports = ReactElement; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -var _prodInvariant = __webpack_require__(3); +var _prodInvariant = __webpack_require__(5); + +var DOMProperty = __webpack_require__(28); +var ReactDOMComponentFlags = __webpack_require__(126); + +var invariant = __webpack_require__(2); + +var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; +var Flags = ReactDOMComponentFlags; -var invariant = __webpack_require__(1); +var internalInstanceKey = '__reactInternalInstance$' + Math.random().toString(36).slice(2); /** - * Static poolers. Several custom versions for each potential number of - * arguments. A completely generic pooler is easy to implement, but would - * require accessing the `arguments` object. In each of these, `this` refers to - * the Class itself, not an instance. If any others are needed, simply add them - * here, or in their own files. + * Check if a given node should be cached. */ -var oneArgumentPooler = function (copyFieldsFrom) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, copyFieldsFrom); - return instance; - } else { - return new Klass(copyFieldsFrom); +function shouldPrecacheNode(node, nodeID) { + return node.nodeType === 1 && node.getAttribute(ATTR_NAME) === String(nodeID) || node.nodeType === 8 && node.nodeValue === ' react-text: ' + nodeID + ' ' || node.nodeType === 8 && node.nodeValue === ' react-empty: ' + nodeID + ' '; +} + +/** + * Drill down (through composites and empty components) until we get a host or + * host text component. + * + * This is pretty polymorphic but unavoidable with the current structure we have + * for `_renderedChildren`. + */ +function getRenderedHostOrTextFromComponent(component) { + var rendered; + while (rendered = component._renderedComponent) { + component = rendered; } -}; + return component; +} -var twoArgumentPooler = function (a1, a2) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2); - return instance; - } else { - return new Klass(a1, a2); +/** + * Populate `_hostNode` on the rendered host/text component with the given + * DOM node. The passed `inst` can be a composite. + */ +function precacheNode(inst, node) { + var hostInst = getRenderedHostOrTextFromComponent(inst); + hostInst._hostNode = node; + node[internalInstanceKey] = hostInst; +} + +function uncacheNode(inst) { + var node = inst._hostNode; + if (node) { + delete node[internalInstanceKey]; + inst._hostNode = null; } -}; +} -var threeArgumentPooler = function (a1, a2, a3) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3); - return instance; - } else { - return new Klass(a1, a2, a3); +/** + * Populate `_hostNode` on each child of `inst`, assuming that the children + * match up with the DOM (element) children of `node`. + * + * We cache entire levels at once to avoid an n^2 problem where we access the + * children of a node sequentially and have to walk from the start to our target + * node every time. + * + * Since we update `_renderedChildren` and the actual DOM at (slightly) + * different times, we could race here and see a newer `_renderedChildren` than + * the DOM nodes we see. To avoid this, ReactMultiChild calls + * `prepareToManageChildren` before we change `_renderedChildren`, at which + * time the container's child nodes are always cached (until it unmounts). + */ +function precacheChildNodes(inst, node) { + if (inst._flags & Flags.hasCachedChildNodes) { + return; } -}; + var children = inst._renderedChildren; + var childNode = node.firstChild; + outer: for (var name in children) { + if (!children.hasOwnProperty(name)) { + continue; + } + var childInst = children[name]; + var childID = getRenderedHostOrTextFromComponent(childInst)._domID; + if (childID === 0) { + // We're currently unmounting this child in ReactMultiChild; skip it. + continue; + } + // We assume the child nodes are in the same order as the child instances. + for (; childNode !== null; childNode = childNode.nextSibling) { + if (shouldPrecacheNode(childNode, childID)) { + precacheNode(childInst, childNode); + continue outer; + } + } + // We reached the end of the DOM children without finding an ID match. + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unable to find element with ID %s.', childID) : _prodInvariant('32', childID) : void 0; + } + inst._flags |= Flags.hasCachedChildNodes; +} -var fourArgumentPooler = function (a1, a2, a3, a4) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3, a4); - return instance; - } else { - return new Klass(a1, a2, a3, a4); +/** + * Given a DOM node, return the closest ReactDOMComponent or + * ReactDOMTextComponent instance ancestor. + */ +function getClosestInstanceFromNode(node) { + if (node[internalInstanceKey]) { + return node[internalInstanceKey]; } -}; -var standardReleaser = function (instance) { - var Klass = this; - !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; - instance.destructor(); - if (Klass.instancePool.length < Klass.poolSize) { - Klass.instancePool.push(instance); + // Walk up the tree until we find an ancestor whose instance we have cached. + var parents = []; + while (!node[internalInstanceKey]) { + parents.push(node); + if (node.parentNode) { + node = node.parentNode; + } else { + // Top of the tree. This node must not be part of a React tree (or is + // unmounted, potentially). + return null; + } } -}; -var DEFAULT_POOL_SIZE = 10; -var DEFAULT_POOLER = oneArgumentPooler; + var closest; + var inst; + for (; node && (inst = node[internalInstanceKey]); node = parents.pop()) { + closest = inst; + if (parents.length) { + precacheChildNodes(inst, node); + } + } + + return closest; +} /** - * Augments `CopyConstructor` to be a poolable class, augmenting only the class - * itself (statically) not adding any prototypical fields. Any CopyConstructor - * you give this may have a `poolSize` property, and will look for a - * prototypical `destructor` on instances. - * - * @param {Function} CopyConstructor Constructor that can be used to reset. - * @param {Function} pooler Customizable pooler. + * Given a DOM node, return the ReactDOMComponent or ReactDOMTextComponent + * instance, or null if the node was not rendered by this React. */ -var addPoolingTo = function (CopyConstructor, pooler) { - // Casting as any so that flow ignores the actual implementation and trusts - // it to match the type we declared - var NewKlass = CopyConstructor; - NewKlass.instancePool = []; - NewKlass.getPooled = pooler || DEFAULT_POOLER; - if (!NewKlass.poolSize) { - NewKlass.poolSize = DEFAULT_POOL_SIZE; +function getInstanceFromNode(node) { + var inst = getClosestInstanceFromNode(node); + if (inst != null && inst._hostNode === node) { + return inst; + } else { + return null; } - NewKlass.release = standardReleaser; - return NewKlass; -}; +} -var PooledClass = { - addPoolingTo: addPoolingTo, - oneArgumentPooler: oneArgumentPooler, - twoArgumentPooler: twoArgumentPooler, - threeArgumentPooler: threeArgumentPooler, - fourArgumentPooler: fourArgumentPooler +/** + * Given a ReactDOMComponent or ReactDOMTextComponent, return the corresponding + * DOM node. + */ +function getNodeFromInstance(inst) { + // Without this first invariant, passing a non-DOM-component triggers the next + // invariant for a missing parent, which is super confusing. + !(inst._hostNode !== undefined) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; + + if (inst._hostNode) { + return inst._hostNode; + } + + // Walk up the tree until we find an ancestor whose DOM node we have cached. + var parents = []; + while (!inst._hostNode) { + parents.push(inst); + !inst._hostParent ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React DOM tree root should always have a node reference.') : _prodInvariant('34') : void 0; + inst = inst._hostParent; + } + + // Now parents contains each ancestor that does *not* have a cached native + // node, and `inst` is the deepest ancestor that does. + for (; parents.length; inst = parents.pop()) { + precacheChildNodes(inst, inst._hostNode); + } + + return inst._hostNode; +} + +var ReactDOMComponentTree = { + getClosestInstanceFromNode: getClosestInstanceFromNode, + getInstanceFromNode: getInstanceFromNode, + getNodeFromInstance: getNodeFromInstance, + precacheChildNodes: precacheChildNodes, + precacheNode: precacheNode, + uncacheNode: uncacheNode }; -module.exports = PooledClass; +module.exports = ReactDOMComponentTree; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 21 */, -/* 22 */, -/* 23 */, -/* 24 */ +/* 11 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(module) {(function (module, exports) { + 'use strict'; + // Utils + function assert (val, msg) { + if (!val) throw new Error(msg || 'Assertion failed'); + } + // Could use `inherits` module, but don't want to move from single file + // architecture yet. + function inherits (ctor, superCtor) { + ctor.super_ = superCtor; + var TempCtor = function () {}; + TempCtor.prototype = superCtor.prototype; + ctor.prototype = new TempCtor(); + ctor.prototype.constructor = ctor; + } -var _assign = __webpack_require__(5); + // BN -var ReactBaseClasses = __webpack_require__(74); -var ReactChildren = __webpack_require__(122); -var ReactDOMFactories = __webpack_require__(126); -var ReactElement = __webpack_require__(19); -var ReactPropTypes = __webpack_require__(130); -var ReactVersion = __webpack_require__(132); + function BN (number, base, endian) { + if (BN.isBN(number)) { + return number; + } -var createReactClass = __webpack_require__(133); -var onlyChild = __webpack_require__(134); + this.negative = 0; + this.words = null; + this.length = 0; -var createElement = ReactElement.createElement; -var createFactory = ReactElement.createFactory; -var cloneElement = ReactElement.cloneElement; + // Reduction context + this.red = null; -if (process.env.NODE_ENV !== 'production') { - var lowPriorityWarning = __webpack_require__(48); - var canDefineProperty = __webpack_require__(38); - var ReactElementValidator = __webpack_require__(78); - var didWarnPropTypesDeprecated = false; - createElement = ReactElementValidator.createElement; - createFactory = ReactElementValidator.createFactory; - cloneElement = ReactElementValidator.cloneElement; -} + if (number !== null) { + if (base === 'le' || base === 'be') { + endian = base; + base = 10; + } -var __spread = _assign; -var createMixin = function (mixin) { - return mixin; -}; + this._init(number || 0, base || 10, endian || 'be'); + } + } + if (typeof module === 'object') { + module.exports = BN; + } else { + exports.BN = BN; + } -if (process.env.NODE_ENV !== 'production') { - var warnedForSpread = false; - var warnedForCreateMixin = false; - __spread = function () { - lowPriorityWarning(warnedForSpread, 'React.__spread is deprecated and should not be used. Use ' + 'Object.assign directly or another helper function with similar ' + 'semantics. You may be seeing this warning due to your compiler. ' + 'See https://fb.me/react-spread-deprecation for more details.'); - warnedForSpread = true; - return _assign.apply(null, arguments); - }; + BN.BN = BN; + BN.wordSize = 26; - createMixin = function (mixin) { - lowPriorityWarning(warnedForCreateMixin, 'React.createMixin is deprecated and should not be used. ' + 'In React v16.0, it will be removed. ' + 'You can use this mixin directly instead. ' + 'See https://fb.me/createmixin-was-never-implemented for more info.'); - warnedForCreateMixin = true; - return mixin; - }; -} + var Buffer; + try { + // Obfuscate that we require Buffer, to reduce size + Buffer = __webpack_require__(1).Buffer; + } catch (e) { + } -var React = { - // Modern + BN.isBN = function isBN (num) { + if (num instanceof BN) { + return true; + } - Children: { - map: ReactChildren.map, - forEach: ReactChildren.forEach, - count: ReactChildren.count, - toArray: ReactChildren.toArray, - only: onlyChild - }, + return num !== null && typeof num === 'object' && + num.constructor.wordSize === BN.wordSize && Array.isArray(num.words); + }; - Component: ReactBaseClasses.Component, - PureComponent: ReactBaseClasses.PureComponent, + BN.max = function max (left, right) { + if (left.cmp(right) > 0) return left; + return right; + }; - createElement: createElement, - cloneElement: cloneElement, - isValidElement: ReactElement.isValidElement, + BN.min = function min (left, right) { + if (left.cmp(right) < 0) return left; + return right; + }; - // Classic + BN.prototype._init = function init (number, base, endian) { + if (typeof number === 'number') { + return this._initNumber(number, base, endian); + } - PropTypes: ReactPropTypes, - createClass: createReactClass, - createFactory: createFactory, - createMixin: createMixin, + if (typeof number === 'object') { + return this._initArray(number, base, endian); + } - // This looks DOM specific but these are actually isomorphic helpers - // since they are just generating DOM strings. - DOM: ReactDOMFactories, + if (base === 'hex') { + base = 16; + } + assert(base === (base | 0) && base >= 2 && base <= 36); - version: ReactVersion, + number = number.toString().replace(/\s+/g, ''); + var start = 0; + if (number[0] === '-') { + start++; + } - // Deprecated hook for JSX spread, don't use this for anything. - __spread: __spread -}; + if (base === 16) { + this._parseHex(number, start); + } else { + this._parseBase(number, base, start); + } -if (process.env.NODE_ENV !== 'production') { - var warnedForCreateClass = false; - if (canDefineProperty) { - Object.defineProperty(React, 'PropTypes', { - get: function () { - lowPriorityWarning(didWarnPropTypesDeprecated, 'Accessing PropTypes via the main React package is deprecated,' + ' and will be removed in React v16.0.' + ' Use the latest available v15.* prop-types package from npm instead.' + ' For info on usage, compatibility, migration and more, see ' + 'https://fb.me/prop-types-docs'); - didWarnPropTypesDeprecated = true; - return ReactPropTypes; - } - }); + if (number[0] === '-') { + this.negative = 1; + } - Object.defineProperty(React, 'createClass', { - get: function () { - lowPriorityWarning(warnedForCreateClass, 'Accessing createClass via the main React package is deprecated,' + ' and will be removed in React v16.0.' + " Use a plain JavaScript class instead. If you're not yet " + 'ready to migrate, create-react-class v15.* is available ' + 'on npm as a temporary, drop-in replacement. ' + 'For more info see https://fb.me/react-create-class'); - warnedForCreateClass = true; - return createReactClass; - } - }); - } + this.strip(); - // React.DOM factories are deprecated. Wrap these methods so that - // invocations of the React.DOM namespace and alert users to switch - // to the `react-dom-factories` package. - React.DOM = {}; - var warnedForFactories = false; - Object.keys(ReactDOMFactories).forEach(function (factory) { - React.DOM[factory] = function () { - if (!warnedForFactories) { - lowPriorityWarning(false, 'Accessing factories like React.DOM.%s has been deprecated ' + 'and will be removed in v16.0+. Use the ' + 'react-dom-factories package instead. ' + ' Version 1.0 provides a drop-in replacement.' + ' For more info, see https://fb.me/react-dom-factories', factory); - warnedForFactories = true; - } - return ReactDOMFactories[factory].apply(ReactDOMFactories, arguments); - }; - }); -} + if (endian !== 'le') return; -module.exports = React; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + this._initArray(this.toArray(), base, endian); + }; -/***/ }), -/* 25 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype._initNumber = function _initNumber (number, base, endian) { + if (number < 0) { + this.negative = 1; + number = -number; + } + if (number < 0x4000000) { + this.words = [ number & 0x3ffffff ]; + this.length = 1; + } else if (number < 0x10000000000000) { + this.words = [ + number & 0x3ffffff, + (number / 0x4000000) & 0x3ffffff + ]; + this.length = 2; + } else { + assert(number < 0x20000000000000); // 2 ^ 53 (unsafe) + this.words = [ + number & 0x3ffffff, + (number / 0x4000000) & 0x3ffffff, + 1 + ]; + this.length = 3; + } -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + if (endian !== 'le') return; + // Reverse the bytes + this._initArray(this.toArray(), base, endian); + }; -/** - * WARNING: DO NOT manually require this module. - * This is a replacement for `invariant(...)` used by the error code system - * and will _only_ be required by the corresponding babel pass. - * It always throws. - */ + BN.prototype._initArray = function _initArray (number, base, endian) { + // Perhaps a Uint8Array + assert(typeof number.length === 'number'); + if (number.length <= 0) { + this.words = [ 0 ]; + this.length = 1; + return this; + } + + this.length = Math.ceil(number.length / 3); + this.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + this.words[i] = 0; + } + + var j, w; + var off = 0; + if (endian === 'be') { + for (i = number.length - 1, j = 0; i >= 0; i -= 3) { + w = number[i] | (number[i - 1] << 8) | (number[i - 2] << 16); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] = (w >>> (26 - off)) & 0x3ffffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } + } + } else if (endian === 'le') { + for (i = 0, j = 0; i < number.length; i += 3) { + w = number[i] | (number[i + 1] << 8) | (number[i + 2] << 16); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] = (w >>> (26 - off)) & 0x3ffffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } + } + } + return this.strip(); + }; -function reactProdInvariant(code) { - var argCount = arguments.length - 1; + function parseHex (str, start, end) { + var r = 0; + var len = Math.min(str.length, end); + for (var i = start; i < len; i++) { + var c = str.charCodeAt(i) - 48; - var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; + r <<= 4; - for (var argIdx = 0; argIdx < argCount; argIdx++) { - message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); - } + // 'a' - 'f' + if (c >= 49 && c <= 54) { + r |= c - 49 + 0xa; - message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; + // 'A' - 'F' + } else if (c >= 17 && c <= 22) { + r |= c - 17 + 0xa; - var error = new Error(message); - error.name = 'Invariant Violation'; - error.framesToPop = 1; // we don't care about reactProdInvariant's own frame + // '0' - '9' + } else { + r |= c & 0xf; + } + } + return r; + } + + BN.prototype._parseHex = function _parseHex (number, start) { + // Create possibly bigger array to ensure that it fits the number + this.length = Math.ceil((number.length - start) / 6); + this.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + this.words[i] = 0; + } + + var j, w; + // Scan 24-bit chunks and add them to the number + var off = 0; + for (i = number.length - 6, j = 0; i >= start; i -= 6) { + w = parseHex(number, i, i + 6); + this.words[j] |= (w << off) & 0x3ffffff; + // NOTE: `0x3fffff` is intentional here, 26bits max shift + 24bit hex limb + this.words[j + 1] |= w >>> (26 - off) & 0x3fffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } + } + if (i + 6 !== start) { + w = parseHex(number, start, i + 6); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] |= w >>> (26 - off) & 0x3fffff; + } + this.strip(); + }; - throw error; -} + function parseBase (str, start, end, mul) { + var r = 0; + var len = Math.min(str.length, end); + for (var i = start; i < len; i++) { + var c = str.charCodeAt(i) - 48; -module.exports = reactProdInvariant; + r *= mul; -/***/ }), -/* 26 */ -/***/ (function(module, exports, __webpack_require__) { + // 'a' + if (c >= 49) { + r += c - 49 + 0xa; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // 'A' + } else if (c >= 17) { + r += c - 17 + 0xa; + // '0' - '9' + } else { + r += c; + } + } + return r; + } + BN.prototype._parseBase = function _parseBase (number, base, start) { + // Initialize as zero + this.words = [ 0 ]; + this.length = 1; -var ReactRef = __webpack_require__(143); -var ReactInstrumentation = __webpack_require__(13); + // Find length of limb in base + for (var limbLen = 0, limbPow = 1; limbPow <= 0x3ffffff; limbPow *= base) { + limbLen++; + } + limbLen--; + limbPow = (limbPow / base) | 0; -var warning = __webpack_require__(2); + var total = number.length - start; + var mod = total % limbLen; + var end = Math.min(total, total - mod) + start; -/** - * Helper to call ReactRef.attachRefs with this composite component, split out - * to avoid allocations in the transaction mount-ready queue. - */ -function attachRefs() { - ReactRef.attachRefs(this, this._currentElement); -} + var word = 0; + for (var i = start; i < end; i += limbLen) { + word = parseBase(number, i, i + limbLen, base); -var ReactReconciler = { - /** - * Initializes the component, renders markup, and registers event listeners. - * - * @param {ReactComponent} internalInstance - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?object} the containing host component instance - * @param {?object} info about the host container - * @return {?string} Rendered markup to be inserted into the DOM. - * @final - * @internal - */ - mountComponent: function (internalInstance, transaction, hostParent, hostContainerInfo, context, parentDebugID) // 0 in production and for roots - { - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeMountComponent(internalInstance._debugID, internalInstance._currentElement, parentDebugID); - } - } - var markup = internalInstance.mountComponent(transaction, hostParent, hostContainerInfo, context, parentDebugID); - if (internalInstance._currentElement && internalInstance._currentElement.ref != null) { - transaction.getReactMountReady().enqueue(attachRefs, internalInstance); - } - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onMountComponent(internalInstance._debugID); + this.imuln(limbPow); + if (this.words[0] + word < 0x4000000) { + this.words[0] += word; + } else { + this._iaddn(word); } } - return markup; - }, - /** - * Returns a value that can be passed to - * ReactComponentEnvironment.replaceNodeWithMarkup. - */ - getHostNode: function (internalInstance) { - return internalInstance.getHostNode(); - }, + if (mod !== 0) { + var pow = 1; + word = parseBase(number, i, number.length, base); - /** - * Releases any resources allocated by `mountComponent`. - * - * @final - * @internal - */ - unmountComponent: function (internalInstance, safely) { - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUnmountComponent(internalInstance._debugID); + for (i = 0; i < mod; i++) { + pow *= base; } - } - ReactRef.detachRefs(internalInstance, internalInstance._currentElement); - internalInstance.unmountComponent(safely); - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUnmountComponent(internalInstance._debugID); + + this.imuln(pow); + if (this.words[0] + word < 0x4000000) { + this.words[0] += word; + } else { + this._iaddn(word); } } - }, + }; - /** - * Update a component using a new element. - * - * @param {ReactComponent} internalInstance - * @param {ReactElement} nextElement - * @param {ReactReconcileTransaction} transaction - * @param {object} context - * @internal - */ - receiveComponent: function (internalInstance, nextElement, transaction, context) { - var prevElement = internalInstance._currentElement; + BN.prototype.copy = function copy (dest) { + dest.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + dest.words[i] = this.words[i]; + } + dest.length = this.length; + dest.negative = this.negative; + dest.red = this.red; + }; - if (nextElement === prevElement && context === internalInstance._context) { - // Since elements are immutable after the owner is rendered, - // we can do a cheap identity compare here to determine if this is a - // superfluous reconcile. It's possible for state to be mutable but such - // change should trigger an update of the owner which would recreate - // the element. We explicitly check for the existence of an owner since - // it's possible for an element created outside a composite to be - // deeply mutated and reused. + BN.prototype.clone = function clone () { + var r = new BN(null); + this.copy(r); + return r; + }; - // TODO: Bailing out early is just a perf optimization right? - // TODO: Removing the return statement should affect correctness? - return; + BN.prototype._expand = function _expand (size) { + while (this.length < size) { + this.words[this.length++] = 0; } + return this; + }; - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, nextElement); - } + // Remove leading `0` from `this` + BN.prototype.strip = function strip () { + while (this.length > 1 && this.words[this.length - 1] === 0) { + this.length--; } + return this._normSign(); + }; - var refsChanged = ReactRef.shouldUpdateRefs(prevElement, nextElement); - - if (refsChanged) { - ReactRef.detachRefs(internalInstance, prevElement); + BN.prototype._normSign = function _normSign () { + // -0 = 0 + if (this.length === 1 && this.words[0] === 0) { + this.negative = 0; } + return this; + }; - internalInstance.receiveComponent(nextElement, transaction, context); + BN.prototype.inspect = function inspect () { + return (this.red ? '<BN-R: ' : '<BN: ') + this.toString(16) + '>'; + }; - if (refsChanged && internalInstance._currentElement && internalInstance._currentElement.ref != null) { - transaction.getReactMountReady().enqueue(attachRefs, internalInstance); - } + /* - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); - } - } - }, + var zeros = []; + var groupSizes = []; + var groupBases = []; - /** - * Flush any dirty changes in a component. - * - * @param {ReactComponent} internalInstance - * @param {ReactReconcileTransaction} transaction - * @internal - */ - performUpdateIfNecessary: function (internalInstance, transaction, updateBatchNumber) { - if (internalInstance._updateBatchNumber !== updateBatchNumber) { - // The component's enqueued batch number should always be the current - // batch or the following one. - process.env.NODE_ENV !== 'production' ? warning(internalInstance._updateBatchNumber == null || internalInstance._updateBatchNumber === updateBatchNumber + 1, 'performUpdateIfNecessary: Unexpected batch number (current %s, ' + 'pending %s)', updateBatchNumber, internalInstance._updateBatchNumber) : void 0; - return; + var s = ''; + var i = -1; + while (++i < BN.wordSize) { + zeros[i] = s; + s += '0'; + } + groupSizes[0] = 0; + groupSizes[1] = 0; + groupBases[0] = 0; + groupBases[1] = 0; + var base = 2 - 1; + while (++base < 36 + 1) { + var groupSize = 0; + var groupBase = 1; + while (groupBase < (1 << BN.wordSize) / base) { + groupBase *= base; + groupSize += 1; } - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, internalInstance._currentElement); + groupSizes[base] = groupSize; + groupBases[base] = groupBase; + } + + */ + + var zeros = [ + '', + '0', + '00', + '000', + '0000', + '00000', + '000000', + '0000000', + '00000000', + '000000000', + '0000000000', + '00000000000', + '000000000000', + '0000000000000', + '00000000000000', + '000000000000000', + '0000000000000000', + '00000000000000000', + '000000000000000000', + '0000000000000000000', + '00000000000000000000', + '000000000000000000000', + '0000000000000000000000', + '00000000000000000000000', + '000000000000000000000000', + '0000000000000000000000000' + ]; + + var groupSizes = [ + 0, 0, + 25, 16, 12, 11, 10, 9, 8, + 8, 7, 7, 7, 7, 6, 6, + 6, 6, 6, 6, 6, 5, 5, + 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5 + ]; + + var groupBases = [ + 0, 0, + 33554432, 43046721, 16777216, 48828125, 60466176, 40353607, 16777216, + 43046721, 10000000, 19487171, 35831808, 62748517, 7529536, 11390625, + 16777216, 24137569, 34012224, 47045881, 64000000, 4084101, 5153632, + 6436343, 7962624, 9765625, 11881376, 14348907, 17210368, 20511149, + 24300000, 28629151, 33554432, 39135393, 45435424, 52521875, 60466176 + ]; + + BN.prototype.toString = function toString (base, padding) { + base = base || 10; + padding = padding | 0 || 1; + + var out; + if (base === 16 || base === 'hex') { + out = ''; + var off = 0; + var carry = 0; + for (var i = 0; i < this.length; i++) { + var w = this.words[i]; + var word = (((w << off) | carry) & 0xffffff).toString(16); + carry = (w >>> (24 - off)) & 0xffffff; + if (carry !== 0 || i !== this.length - 1) { + out = zeros[6 - word.length] + word + out; + } else { + out = word + out; + } + off += 2; + if (off >= 26) { + off -= 26; + i--; + } } - } - internalInstance.performUpdateIfNecessary(transaction); - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); + if (carry !== 0) { + out = carry.toString(16) + out; + } + while (out.length % padding !== 0) { + out = '0' + out; + } + if (this.negative !== 0) { + out = '-' + out; } + return out; + } + + if (base === (base | 0) && base >= 2 && base <= 36) { + // var groupSize = Math.floor(BN.wordSize * Math.LN2 / Math.log(base)); + var groupSize = groupSizes[base]; + // var groupBase = Math.pow(base, groupSize); + var groupBase = groupBases[base]; + out = ''; + var c = this.clone(); + c.negative = 0; + while (!c.isZero()) { + var r = c.modn(groupBase).toString(base); + c = c.idivn(groupBase); + + if (!c.isZero()) { + out = zeros[groupSize - r.length] + r + out; + } else { + out = r + out; + } + } + if (this.isZero()) { + out = '0' + out; + } + while (out.length % padding !== 0) { + out = '0' + out; + } + if (this.negative !== 0) { + out = '-' + out; + } + return out; } - } -}; -module.exports = ReactReconciler; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + assert(false, 'Base should be between 2 and 36'); + }; -/***/ }), -/* 27 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.toNumber = function toNumber () { + var ret = this.words[0]; + if (this.length === 2) { + ret += this.words[1] * 0x4000000; + } else if (this.length === 3 && this.words[2] === 0x01) { + // NOTE: at this stage it is known that the top bit is set + ret += 0x10000000000000 + (this.words[1] * 0x4000000); + } else if (this.length > 2) { + assert(false, 'Number can only safely store up to 53 bits'); + } + return (this.negative !== 0) ? -ret : ret; + }; -"use strict"; -/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.toJSON = function toJSON () { + return this.toString(16); + }; + BN.prototype.toBuffer = function toBuffer (endian, length) { + assert(typeof Buffer !== 'undefined'); + return this.toArrayLike(Buffer, endian, length); + }; + BN.prototype.toArray = function toArray (endian, length) { + return this.toArrayLike(Array, endian, length); + }; -var DOMNamespaces = __webpack_require__(56); -var setInnerHTML = __webpack_require__(43); + BN.prototype.toArrayLike = function toArrayLike (ArrayType, endian, length) { + var byteLength = this.byteLength(); + var reqLength = length || Math.max(1, byteLength); + assert(byteLength <= reqLength, 'byte array longer than desired length'); + assert(reqLength > 0, 'Requested array length <= 0'); + + this.strip(); + var littleEndian = endian === 'le'; + var res = new ArrayType(reqLength); + + var b, i; + var q = this.clone(); + if (!littleEndian) { + // Assume big-endian + for (i = 0; i < reqLength - byteLength; i++) { + res[i] = 0; + } -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); -var setTextContent = __webpack_require__(90); + for (i = 0; !q.isZero(); i++) { + b = q.andln(0xff); + q.iushrn(8); -var ELEMENT_NODE_TYPE = 1; -var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + res[reqLength - i - 1] = b; + } + } else { + for (i = 0; !q.isZero(); i++) { + b = q.andln(0xff); + q.iushrn(8); -/** - * In IE (8-11) and Edge, appending nodes with no children is dramatically - * faster than appending a full subtree, so we essentially queue up the - * .appendChild calls here and apply them so each node is added to its parent - * before any children are added. - * - * In other browsers, doing so is slower or neutral compared to the other order - * (in Firefox, twice as slow) so we only do this inversion in IE. - * - * See https://github.com/spicyj/innerhtml-vs-createelement-vs-clonenode. - */ -var enableLazy = typeof document !== 'undefined' && typeof document.documentMode === 'number' || typeof navigator !== 'undefined' && typeof navigator.userAgent === 'string' && /\bEdge\/\d/.test(navigator.userAgent); + res[i] = b; + } -function insertTreeChildren(tree) { - if (!enableLazy) { - return; - } - var node = tree.node; - var children = tree.children; - if (children.length) { - for (var i = 0; i < children.length; i++) { - insertTreeBefore(node, children[i], null); + for (; i < reqLength; i++) { + res[i] = 0; + } } - } else if (tree.html != null) { - setInnerHTML(node, tree.html); - } else if (tree.text != null) { - setTextContent(node, tree.text); - } -} -var insertTreeBefore = createMicrosoftUnsafeLocalFunction(function (parentNode, tree, referenceNode) { - // DocumentFragments aren't actually part of the DOM after insertion so - // appending children won't update the DOM. We need to ensure the fragment - // is properly populated first, breaking out of our lazy approach for just - // this level. Also, some <object> plugins (like Flash Player) will read - // <param> nodes immediately upon insertion into the DOM, so <object> - // must also be populated prior to insertion into the DOM. - if (tree.node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE || tree.node.nodeType === ELEMENT_NODE_TYPE && tree.node.nodeName.toLowerCase() === 'object' && (tree.node.namespaceURI == null || tree.node.namespaceURI === DOMNamespaces.html)) { - insertTreeChildren(tree); - parentNode.insertBefore(tree.node, referenceNode); + return res; + }; + + if (Math.clz32) { + BN.prototype._countBits = function _countBits (w) { + return 32 - Math.clz32(w); + }; } else { - parentNode.insertBefore(tree.node, referenceNode); - insertTreeChildren(tree); + BN.prototype._countBits = function _countBits (w) { + var t = w; + var r = 0; + if (t >= 0x1000) { + r += 13; + t >>>= 13; + } + if (t >= 0x40) { + r += 7; + t >>>= 7; + } + if (t >= 0x8) { + r += 4; + t >>>= 4; + } + if (t >= 0x02) { + r += 2; + t >>>= 2; + } + return r + t; + }; } -}); -function replaceChildWithTree(oldNode, newTree) { - oldNode.parentNode.replaceChild(newTree.node, oldNode); - insertTreeChildren(newTree); -} + BN.prototype._zeroBits = function _zeroBits (w) { + // Short-cut + if (w === 0) return 26; -function queueChild(parentTree, childTree) { - if (enableLazy) { - parentTree.children.push(childTree); - } else { - parentTree.node.appendChild(childTree.node); - } -} + var t = w; + var r = 0; + if ((t & 0x1fff) === 0) { + r += 13; + t >>>= 13; + } + if ((t & 0x7f) === 0) { + r += 7; + t >>>= 7; + } + if ((t & 0xf) === 0) { + r += 4; + t >>>= 4; + } + if ((t & 0x3) === 0) { + r += 2; + t >>>= 2; + } + if ((t & 0x1) === 0) { + r++; + } + return r; + }; -function queueHTML(tree, html) { - if (enableLazy) { - tree.html = html; - } else { - setInnerHTML(tree.node, html); - } -} + // Return number of used bits in a BN + BN.prototype.bitLength = function bitLength () { + var w = this.words[this.length - 1]; + var hi = this._countBits(w); + return (this.length - 1) * 26 + hi; + }; -function queueText(tree, text) { - if (enableLazy) { - tree.text = text; - } else { - setTextContent(tree.node, text); + function toBitArray (num) { + var w = new Array(num.bitLength()); + + for (var bit = 0; bit < w.length; bit++) { + var off = (bit / 26) | 0; + var wbit = bit % 26; + + w[bit] = (num.words[off] & (1 << wbit)) >>> wbit; + } + + return w; } -} -function toString() { - return this.node.nodeName; -} + // Number of trailing zero bits + BN.prototype.zeroBits = function zeroBits () { + if (this.isZero()) return 0; -function DOMLazyTree(node) { - return { - node: node, - children: [], - html: null, - text: null, - toString: toString + var r = 0; + for (var i = 0; i < this.length; i++) { + var b = this._zeroBits(this.words[i]); + r += b; + if (b !== 26) break; + } + return r; }; -} -DOMLazyTree.insertTreeBefore = insertTreeBefore; -DOMLazyTree.replaceChildWithTree = replaceChildWithTree; -DOMLazyTree.queueChild = queueChild; -DOMLazyTree.queueHTML = queueHTML; -DOMLazyTree.queueText = queueText; + BN.prototype.byteLength = function byteLength () { + return Math.ceil(this.bitLength() / 8); + }; -module.exports = DOMLazyTree; + BN.prototype.toTwos = function toTwos (width) { + if (this.negative !== 0) { + return this.abs().inotn(width).iaddn(1); + } + return this.clone(); + }; -/***/ }), -/* 28 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.fromTwos = function fromTwos (width) { + if (this.testn(width - 1)) { + return this.notn(width).iaddn(1).ineg(); + } + return this.clone(); + }; -"use strict"; + BN.prototype.isNeg = function isNeg () { + return this.negative !== 0; + }; + // Return negative clone of `this` + BN.prototype.neg = function neg () { + return this.clone().ineg(); + }; -module.exports = __webpack_require__(135); + BN.prototype.ineg = function ineg () { + if (!this.isZero()) { + this.negative ^= 1; + } + return this; + }; -/***/ }), -/* 29 */ -/***/ (function(module, exports, __webpack_require__) { + // Or `num` with `this` in-place + BN.prototype.iuor = function iuor (num) { + while (this.length < num.length) { + this.words[this.length++] = 0; + } -var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! - Copyright (c) 2016 Jed Watson. - Licensed under the MIT License (MIT), see - http://jedwatson.github.io/classnames -*/ -/* global define */ + for (var i = 0; i < num.length; i++) { + this.words[i] = this.words[i] | num.words[i]; + } -(function () { - 'use strict'; + return this.strip(); + }; - var hasOwn = {}.hasOwnProperty; + BN.prototype.ior = function ior (num) { + assert((this.negative | num.negative) === 0); + return this.iuor(num); + }; - function classNames () { - var classes = []; + // Or `num` with `this` + BN.prototype.or = function or (num) { + if (this.length > num.length) return this.clone().ior(num); + return num.clone().ior(this); + }; - for (var i = 0; i < arguments.length; i++) { - var arg = arguments[i]; - if (!arg) continue; + BN.prototype.uor = function uor (num) { + if (this.length > num.length) return this.clone().iuor(num); + return num.clone().iuor(this); + }; - var argType = typeof arg; + // And `num` with `this` in-place + BN.prototype.iuand = function iuand (num) { + // b = min-length(num, this) + var b; + if (this.length > num.length) { + b = num; + } else { + b = this; + } - if (argType === 'string' || argType === 'number') { - classes.push(arg); - } else if (Array.isArray(arg)) { - classes.push(classNames.apply(null, arg)); - } else if (argType === 'object') { - for (var key in arg) { - if (hasOwn.call(arg, key) && arg[key]) { - classes.push(key); - } - } - } - } + for (var i = 0; i < b.length; i++) { + this.words[i] = this.words[i] & num.words[i]; + } - return classes.join(' '); - } + this.length = b.length; - if (typeof module !== 'undefined' && module.exports) { - module.exports = classNames; - } else if (true) { - // register as 'classnames', consistent with npm package name - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function () { - return classNames; - }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else { - window.classNames = classNames; - } -}()); + return this.strip(); + }; + BN.prototype.iand = function iand (num) { + assert((this.negative | num.negative) === 0); + return this.iuand(num); + }; -/***/ }), -/* 30 */, -/* 31 */ -/***/ (function(module, exports, __webpack_require__) { + // And `num` with `this` + BN.prototype.and = function and (num) { + if (this.length > num.length) return this.clone().iand(num); + return num.clone().iand(this); + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.uand = function uand (num) { + if (this.length > num.length) return this.clone().iuand(num); + return num.clone().iuand(this); + }; + // Xor `num` with `this` in-place + BN.prototype.iuxor = function iuxor (num) { + // a.length > b.length + var a; + var b; + if (this.length > num.length) { + a = this; + b = num; + } else { + a = num; + b = this; + } + for (var i = 0; i < b.length; i++) { + this.words[i] = a.words[i] ^ b.words[i]; + } -var EventPluginHub = __webpack_require__(32); -var EventPluginUtils = __webpack_require__(50); + if (this !== a) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; + } + } -var accumulateInto = __webpack_require__(82); -var forEachAccumulated = __webpack_require__(83); -var warning = __webpack_require__(2); + this.length = a.length; -var getListener = EventPluginHub.getListener; + return this.strip(); + }; -/** - * Some event types have a notion of different registration names for different - * "phases" of propagation. This finds listeners by a given phase. - */ -function listenerAtPhase(inst, event, propagationPhase) { - var registrationName = event.dispatchConfig.phasedRegistrationNames[propagationPhase]; - return getListener(inst, registrationName); -} + BN.prototype.ixor = function ixor (num) { + assert((this.negative | num.negative) === 0); + return this.iuxor(num); + }; -/** - * Tags a `SyntheticEvent` with dispatched listeners. Creating this function - * here, allows us to not have to bind or create functions for each event. - * Mutating the event's members allows us to not have to create a wrapping - * "dispatch" object that pairs the event with the listener. - */ -function accumulateDirectionalDispatches(inst, phase, event) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(inst, 'Dispatching inst must not be null') : void 0; - } - var listener = listenerAtPhase(inst, event, phase); - if (listener) { - event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); - event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); - } -} + // Xor `num` with `this` + BN.prototype.xor = function xor (num) { + if (this.length > num.length) return this.clone().ixor(num); + return num.clone().ixor(this); + }; -/** - * Collect dispatches (must be entirely collected before dispatching - see unit - * tests). Lazily allocate the array to conserve memory. We must loop through - * each event and perform the traversal for each one. We cannot perform a - * single traversal for the entire collection of events because each event may - * have a different target. - */ -function accumulateTwoPhaseDispatchesSingle(event) { - if (event && event.dispatchConfig.phasedRegistrationNames) { - EventPluginUtils.traverseTwoPhase(event._targetInst, accumulateDirectionalDispatches, event); - } -} + BN.prototype.uxor = function uxor (num) { + if (this.length > num.length) return this.clone().iuxor(num); + return num.clone().iuxor(this); + }; -/** - * Same as `accumulateTwoPhaseDispatchesSingle`, but skips over the targetID. - */ -function accumulateTwoPhaseDispatchesSingleSkipTarget(event) { - if (event && event.dispatchConfig.phasedRegistrationNames) { - var targetInst = event._targetInst; - var parentInst = targetInst ? EventPluginUtils.getParentInstance(targetInst) : null; - EventPluginUtils.traverseTwoPhase(parentInst, accumulateDirectionalDispatches, event); - } -} + // Not ``this`` with ``width`` bitwidth + BN.prototype.inotn = function inotn (width) { + assert(typeof width === 'number' && width >= 0); -/** - * Accumulates without regard to direction, does not look for phased - * registration names. Same as `accumulateDirectDispatchesSingle` but without - * requiring that the `dispatchMarker` be the same as the dispatched ID. - */ -function accumulateDispatches(inst, ignoredDirection, event) { - if (event && event.dispatchConfig.registrationName) { - var registrationName = event.dispatchConfig.registrationName; - var listener = getListener(inst, registrationName); - if (listener) { - event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); - event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); + var bytesNeeded = Math.ceil(width / 26) | 0; + var bitsLeft = width % 26; + + // Extend the buffer with leading zeroes + this._expand(bytesNeeded); + + if (bitsLeft > 0) { + bytesNeeded--; } - } -} -/** - * Accumulates dispatches on an `SyntheticEvent`, but only for the - * `dispatchMarker`. - * @param {SyntheticEvent} event - */ -function accumulateDirectDispatchesSingle(event) { - if (event && event.dispatchConfig.registrationName) { - accumulateDispatches(event._targetInst, null, event); - } -} + // Handle complete words + for (var i = 0; i < bytesNeeded; i++) { + this.words[i] = ~this.words[i] & 0x3ffffff; + } -function accumulateTwoPhaseDispatches(events) { - forEachAccumulated(events, accumulateTwoPhaseDispatchesSingle); -} + // Handle the residue + if (bitsLeft > 0) { + this.words[i] = ~this.words[i] & (0x3ffffff >> (26 - bitsLeft)); + } -function accumulateTwoPhaseDispatchesSkipTarget(events) { - forEachAccumulated(events, accumulateTwoPhaseDispatchesSingleSkipTarget); -} + // And remove leading zeroes + return this.strip(); + }; -function accumulateEnterLeaveDispatches(leave, enter, from, to) { - EventPluginUtils.traverseEnterLeave(from, to, accumulateDispatches, leave, enter); -} + BN.prototype.notn = function notn (width) { + return this.clone().inotn(width); + }; -function accumulateDirectDispatches(events) { - forEachAccumulated(events, accumulateDirectDispatchesSingle); -} + // Set `bit` of `this` + BN.prototype.setn = function setn (bit, val) { + assert(typeof bit === 'number' && bit >= 0); -/** - * A small set of propagation patterns, each of which will accept a small amount - * of information, and generate a set of "dispatch ready event objects" - which - * are sets of events that have already been annotated with a set of dispatched - * listener functions/ids. The API is designed this way to discourage these - * propagation strategies from actually executing the dispatches, since we - * always want to collect the entire set of dispatches before executing event a - * single one. - * - * @constructor EventPropagators - */ -var EventPropagators = { - accumulateTwoPhaseDispatches: accumulateTwoPhaseDispatches, - accumulateTwoPhaseDispatchesSkipTarget: accumulateTwoPhaseDispatchesSkipTarget, - accumulateDirectDispatches: accumulateDirectDispatches, - accumulateEnterLeaveDispatches: accumulateEnterLeaveDispatches -}; + var off = (bit / 26) | 0; + var wbit = bit % 26; -module.exports = EventPropagators; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + this._expand(off + 1); -/***/ }), -/* 32 */ -/***/ (function(module, exports, __webpack_require__) { + if (val) { + this.words[off] = this.words[off] | (1 << wbit); + } else { + this.words[off] = this.words[off] & ~(1 << wbit); + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return this.strip(); + }; + // Add `num` to `this` in-place + BN.prototype.iadd = function iadd (num) { + var r; + + // negative + positive + if (this.negative !== 0 && num.negative === 0) { + this.negative = 0; + r = this.isub(num); + this.negative ^= 1; + return this._normSign(); + + // positive + negative + } else if (this.negative === 0 && num.negative !== 0) { + num.negative = 0; + r = this.isub(num); + num.negative = 1; + return r._normSign(); + } + + // a.length > b.length + var a, b; + if (this.length > num.length) { + a = this; + b = num; + } else { + a = num; + b = this; + } + + var carry = 0; + for (var i = 0; i < b.length; i++) { + r = (a.words[i] | 0) + (b.words[i] | 0) + carry; + this.words[i] = r & 0x3ffffff; + carry = r >>> 26; + } + for (; carry !== 0 && i < a.length; i++) { + r = (a.words[i] | 0) + carry; + this.words[i] = r & 0x3ffffff; + carry = r >>> 26; + } + + this.length = a.length; + if (carry !== 0) { + this.words[this.length] = carry; + this.length++; + // Copy the rest of the words + } else if (a !== this) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; + } + } + return this; + }; -var _prodInvariant = __webpack_require__(3); + // Add `num` to `this` + BN.prototype.add = function add (num) { + var res; + if (num.negative !== 0 && this.negative === 0) { + num.negative = 0; + res = this.sub(num); + num.negative ^= 1; + return res; + } else if (num.negative === 0 && this.negative !== 0) { + this.negative = 0; + res = num.sub(this); + this.negative = 1; + return res; + } -var EventPluginRegistry = __webpack_require__(40); -var EventPluginUtils = __webpack_require__(50); -var ReactErrorUtils = __webpack_require__(51); + if (this.length > num.length) return this.clone().iadd(num); -var accumulateInto = __webpack_require__(82); -var forEachAccumulated = __webpack_require__(83); -var invariant = __webpack_require__(1); + return num.clone().iadd(this); + }; -/** - * Internal store for event listeners - */ -var listenerBank = {}; + // Subtract `num` from `this` in-place + BN.prototype.isub = function isub (num) { + // this - (-num) = this + num + if (num.negative !== 0) { + num.negative = 0; + var r = this.iadd(num); + num.negative = 1; + return r._normSign(); + + // -this - num = -(this + num) + } else if (this.negative !== 0) { + this.negative = 0; + this.iadd(num); + this.negative = 1; + return this._normSign(); + } + + // At this point both numbers are positive + var cmp = this.cmp(num); + + // Optimization - zeroify + if (cmp === 0) { + this.negative = 0; + this.length = 1; + this.words[0] = 0; + return this; + } + + // a > b + var a, b; + if (cmp > 0) { + a = this; + b = num; + } else { + a = num; + b = this; + } -/** - * Internal queue of events that have accumulated their dispatches and are - * waiting to have their dispatches executed. - */ -var eventQueue = null; + var carry = 0; + for (var i = 0; i < b.length; i++) { + r = (a.words[i] | 0) - (b.words[i] | 0) + carry; + carry = r >> 26; + this.words[i] = r & 0x3ffffff; + } + for (; carry !== 0 && i < a.length; i++) { + r = (a.words[i] | 0) + carry; + carry = r >> 26; + this.words[i] = r & 0x3ffffff; + } -/** - * Dispatches an event and releases it back into the pool, unless persistent. - * - * @param {?object} event Synthetic event to be dispatched. - * @param {boolean} simulated If the event is simulated (changes exn behavior) - * @private - */ -var executeDispatchesAndRelease = function (event, simulated) { - if (event) { - EventPluginUtils.executeDispatchesInOrder(event, simulated); + // Copy rest of the words + if (carry === 0 && i < a.length && a !== this) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; + } + } - if (!event.isPersistent()) { - event.constructor.release(event); + this.length = Math.max(this.length, i); + + if (a !== this) { + this.negative = 1; } - } -}; -var executeDispatchesAndReleaseSimulated = function (e) { - return executeDispatchesAndRelease(e, true); -}; -var executeDispatchesAndReleaseTopLevel = function (e) { - return executeDispatchesAndRelease(e, false); -}; -var getDictionaryKey = function (inst) { - // Prevents V8 performance issue: - // https://github.com/facebook/react/pull/7232 - return '.' + inst._rootNodeID; -}; + return this.strip(); + }; -function isInteractive(tag) { - return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; -} + // Subtract `num` from `this` + BN.prototype.sub = function sub (num) { + return this.clone().isub(num); + }; -function shouldPreventMouseEvent(name, type, props) { - switch (name) { - case 'onClick': - case 'onClickCapture': - case 'onDoubleClick': - case 'onDoubleClickCapture': - case 'onMouseDown': - case 'onMouseDownCapture': - case 'onMouseMove': - case 'onMouseMoveCapture': - case 'onMouseUp': - case 'onMouseUpCapture': - return !!(props.disabled && isInteractive(type)); - default: - return false; + function smallMulTo (self, num, out) { + out.negative = num.negative ^ self.negative; + var len = (self.length + num.length) | 0; + out.length = len; + len = (len - 1) | 0; + + // Peel one iteration (compiler can't do it, because of code complexity) + var a = self.words[0] | 0; + var b = num.words[0] | 0; + var r = a * b; + + var lo = r & 0x3ffffff; + var carry = (r / 0x4000000) | 0; + out.words[0] = lo; + + for (var k = 1; k < len; k++) { + // Sum all words with the same `i + j = k` and accumulate `ncarry`, + // note that ncarry could be >= 0x3ffffff + var ncarry = carry >>> 26; + var rword = carry & 0x3ffffff; + var maxJ = Math.min(k, num.length - 1); + for (var j = Math.max(0, k - self.length + 1); j <= maxJ; j++) { + var i = (k - j) | 0; + a = self.words[i] | 0; + b = num.words[j] | 0; + r = a * b + rword; + ncarry += (r / 0x4000000) | 0; + rword = r & 0x3ffffff; + } + out.words[k] = rword | 0; + carry = ncarry | 0; + } + if (carry !== 0) { + out.words[k] = carry | 0; + } else { + out.length--; + } + + return out.strip(); + } + + // TODO(indutny): it may be reasonable to omit it for users who don't need + // to work with 256-bit numbers, otherwise it gives 20% improvement for 256-bit + // multiplication (like elliptic secp256k1). + var comb10MulTo = function comb10MulTo (self, num, out) { + var a = self.words; + var b = num.words; + var o = out.words; + var c = 0; + var lo; + var mid; + var hi; + var a0 = a[0] | 0; + var al0 = a0 & 0x1fff; + var ah0 = a0 >>> 13; + var a1 = a[1] | 0; + var al1 = a1 & 0x1fff; + var ah1 = a1 >>> 13; + var a2 = a[2] | 0; + var al2 = a2 & 0x1fff; + var ah2 = a2 >>> 13; + var a3 = a[3] | 0; + var al3 = a3 & 0x1fff; + var ah3 = a3 >>> 13; + var a4 = a[4] | 0; + var al4 = a4 & 0x1fff; + var ah4 = a4 >>> 13; + var a5 = a[5] | 0; + var al5 = a5 & 0x1fff; + var ah5 = a5 >>> 13; + var a6 = a[6] | 0; + var al6 = a6 & 0x1fff; + var ah6 = a6 >>> 13; + var a7 = a[7] | 0; + var al7 = a7 & 0x1fff; + var ah7 = a7 >>> 13; + var a8 = a[8] | 0; + var al8 = a8 & 0x1fff; + var ah8 = a8 >>> 13; + var a9 = a[9] | 0; + var al9 = a9 & 0x1fff; + var ah9 = a9 >>> 13; + var b0 = b[0] | 0; + var bl0 = b0 & 0x1fff; + var bh0 = b0 >>> 13; + var b1 = b[1] | 0; + var bl1 = b1 & 0x1fff; + var bh1 = b1 >>> 13; + var b2 = b[2] | 0; + var bl2 = b2 & 0x1fff; + var bh2 = b2 >>> 13; + var b3 = b[3] | 0; + var bl3 = b3 & 0x1fff; + var bh3 = b3 >>> 13; + var b4 = b[4] | 0; + var bl4 = b4 & 0x1fff; + var bh4 = b4 >>> 13; + var b5 = b[5] | 0; + var bl5 = b5 & 0x1fff; + var bh5 = b5 >>> 13; + var b6 = b[6] | 0; + var bl6 = b6 & 0x1fff; + var bh6 = b6 >>> 13; + var b7 = b[7] | 0; + var bl7 = b7 & 0x1fff; + var bh7 = b7 >>> 13; + var b8 = b[8] | 0; + var bl8 = b8 & 0x1fff; + var bh8 = b8 >>> 13; + var b9 = b[9] | 0; + var bl9 = b9 & 0x1fff; + var bh9 = b9 >>> 13; + + out.negative = self.negative ^ num.negative; + out.length = 19; + /* k = 0 */ + lo = Math.imul(al0, bl0); + mid = Math.imul(al0, bh0); + mid = (mid + Math.imul(ah0, bl0)) | 0; + hi = Math.imul(ah0, bh0); + var w0 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w0 >>> 26)) | 0; + w0 &= 0x3ffffff; + /* k = 1 */ + lo = Math.imul(al1, bl0); + mid = Math.imul(al1, bh0); + mid = (mid + Math.imul(ah1, bl0)) | 0; + hi = Math.imul(ah1, bh0); + lo = (lo + Math.imul(al0, bl1)) | 0; + mid = (mid + Math.imul(al0, bh1)) | 0; + mid = (mid + Math.imul(ah0, bl1)) | 0; + hi = (hi + Math.imul(ah0, bh1)) | 0; + var w1 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w1 >>> 26)) | 0; + w1 &= 0x3ffffff; + /* k = 2 */ + lo = Math.imul(al2, bl0); + mid = Math.imul(al2, bh0); + mid = (mid + Math.imul(ah2, bl0)) | 0; + hi = Math.imul(ah2, bh0); + lo = (lo + Math.imul(al1, bl1)) | 0; + mid = (mid + Math.imul(al1, bh1)) | 0; + mid = (mid + Math.imul(ah1, bl1)) | 0; + hi = (hi + Math.imul(ah1, bh1)) | 0; + lo = (lo + Math.imul(al0, bl2)) | 0; + mid = (mid + Math.imul(al0, bh2)) | 0; + mid = (mid + Math.imul(ah0, bl2)) | 0; + hi = (hi + Math.imul(ah0, bh2)) | 0; + var w2 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w2 >>> 26)) | 0; + w2 &= 0x3ffffff; + /* k = 3 */ + lo = Math.imul(al3, bl0); + mid = Math.imul(al3, bh0); + mid = (mid + Math.imul(ah3, bl0)) | 0; + hi = Math.imul(ah3, bh0); + lo = (lo + Math.imul(al2, bl1)) | 0; + mid = (mid + Math.imul(al2, bh1)) | 0; + mid = (mid + Math.imul(ah2, bl1)) | 0; + hi = (hi + Math.imul(ah2, bh1)) | 0; + lo = (lo + Math.imul(al1, bl2)) | 0; + mid = (mid + Math.imul(al1, bh2)) | 0; + mid = (mid + Math.imul(ah1, bl2)) | 0; + hi = (hi + Math.imul(ah1, bh2)) | 0; + lo = (lo + Math.imul(al0, bl3)) | 0; + mid = (mid + Math.imul(al0, bh3)) | 0; + mid = (mid + Math.imul(ah0, bl3)) | 0; + hi = (hi + Math.imul(ah0, bh3)) | 0; + var w3 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w3 >>> 26)) | 0; + w3 &= 0x3ffffff; + /* k = 4 */ + lo = Math.imul(al4, bl0); + mid = Math.imul(al4, bh0); + mid = (mid + Math.imul(ah4, bl0)) | 0; + hi = Math.imul(ah4, bh0); + lo = (lo + Math.imul(al3, bl1)) | 0; + mid = (mid + Math.imul(al3, bh1)) | 0; + mid = (mid + Math.imul(ah3, bl1)) | 0; + hi = (hi + Math.imul(ah3, bh1)) | 0; + lo = (lo + Math.imul(al2, bl2)) | 0; + mid = (mid + Math.imul(al2, bh2)) | 0; + mid = (mid + Math.imul(ah2, bl2)) | 0; + hi = (hi + Math.imul(ah2, bh2)) | 0; + lo = (lo + Math.imul(al1, bl3)) | 0; + mid = (mid + Math.imul(al1, bh3)) | 0; + mid = (mid + Math.imul(ah1, bl3)) | 0; + hi = (hi + Math.imul(ah1, bh3)) | 0; + lo = (lo + Math.imul(al0, bl4)) | 0; + mid = (mid + Math.imul(al0, bh4)) | 0; + mid = (mid + Math.imul(ah0, bl4)) | 0; + hi = (hi + Math.imul(ah0, bh4)) | 0; + var w4 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w4 >>> 26)) | 0; + w4 &= 0x3ffffff; + /* k = 5 */ + lo = Math.imul(al5, bl0); + mid = Math.imul(al5, bh0); + mid = (mid + Math.imul(ah5, bl0)) | 0; + hi = Math.imul(ah5, bh0); + lo = (lo + Math.imul(al4, bl1)) | 0; + mid = (mid + Math.imul(al4, bh1)) | 0; + mid = (mid + Math.imul(ah4, bl1)) | 0; + hi = (hi + Math.imul(ah4, bh1)) | 0; + lo = (lo + Math.imul(al3, bl2)) | 0; + mid = (mid + Math.imul(al3, bh2)) | 0; + mid = (mid + Math.imul(ah3, bl2)) | 0; + hi = (hi + Math.imul(ah3, bh2)) | 0; + lo = (lo + Math.imul(al2, bl3)) | 0; + mid = (mid + Math.imul(al2, bh3)) | 0; + mid = (mid + Math.imul(ah2, bl3)) | 0; + hi = (hi + Math.imul(ah2, bh3)) | 0; + lo = (lo + Math.imul(al1, bl4)) | 0; + mid = (mid + Math.imul(al1, bh4)) | 0; + mid = (mid + Math.imul(ah1, bl4)) | 0; + hi = (hi + Math.imul(ah1, bh4)) | 0; + lo = (lo + Math.imul(al0, bl5)) | 0; + mid = (mid + Math.imul(al0, bh5)) | 0; + mid = (mid + Math.imul(ah0, bl5)) | 0; + hi = (hi + Math.imul(ah0, bh5)) | 0; + var w5 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w5 >>> 26)) | 0; + w5 &= 0x3ffffff; + /* k = 6 */ + lo = Math.imul(al6, bl0); + mid = Math.imul(al6, bh0); + mid = (mid + Math.imul(ah6, bl0)) | 0; + hi = Math.imul(ah6, bh0); + lo = (lo + Math.imul(al5, bl1)) | 0; + mid = (mid + Math.imul(al5, bh1)) | 0; + mid = (mid + Math.imul(ah5, bl1)) | 0; + hi = (hi + Math.imul(ah5, bh1)) | 0; + lo = (lo + Math.imul(al4, bl2)) | 0; + mid = (mid + Math.imul(al4, bh2)) | 0; + mid = (mid + Math.imul(ah4, bl2)) | 0; + hi = (hi + Math.imul(ah4, bh2)) | 0; + lo = (lo + Math.imul(al3, bl3)) | 0; + mid = (mid + Math.imul(al3, bh3)) | 0; + mid = (mid + Math.imul(ah3, bl3)) | 0; + hi = (hi + Math.imul(ah3, bh3)) | 0; + lo = (lo + Math.imul(al2, bl4)) | 0; + mid = (mid + Math.imul(al2, bh4)) | 0; + mid = (mid + Math.imul(ah2, bl4)) | 0; + hi = (hi + Math.imul(ah2, bh4)) | 0; + lo = (lo + Math.imul(al1, bl5)) | 0; + mid = (mid + Math.imul(al1, bh5)) | 0; + mid = (mid + Math.imul(ah1, bl5)) | 0; + hi = (hi + Math.imul(ah1, bh5)) | 0; + lo = (lo + Math.imul(al0, bl6)) | 0; + mid = (mid + Math.imul(al0, bh6)) | 0; + mid = (mid + Math.imul(ah0, bl6)) | 0; + hi = (hi + Math.imul(ah0, bh6)) | 0; + var w6 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w6 >>> 26)) | 0; + w6 &= 0x3ffffff; + /* k = 7 */ + lo = Math.imul(al7, bl0); + mid = Math.imul(al7, bh0); + mid = (mid + Math.imul(ah7, bl0)) | 0; + hi = Math.imul(ah7, bh0); + lo = (lo + Math.imul(al6, bl1)) | 0; + mid = (mid + Math.imul(al6, bh1)) | 0; + mid = (mid + Math.imul(ah6, bl1)) | 0; + hi = (hi + Math.imul(ah6, bh1)) | 0; + lo = (lo + Math.imul(al5, bl2)) | 0; + mid = (mid + Math.imul(al5, bh2)) | 0; + mid = (mid + Math.imul(ah5, bl2)) | 0; + hi = (hi + Math.imul(ah5, bh2)) | 0; + lo = (lo + Math.imul(al4, bl3)) | 0; + mid = (mid + Math.imul(al4, bh3)) | 0; + mid = (mid + Math.imul(ah4, bl3)) | 0; + hi = (hi + Math.imul(ah4, bh3)) | 0; + lo = (lo + Math.imul(al3, bl4)) | 0; + mid = (mid + Math.imul(al3, bh4)) | 0; + mid = (mid + Math.imul(ah3, bl4)) | 0; + hi = (hi + Math.imul(ah3, bh4)) | 0; + lo = (lo + Math.imul(al2, bl5)) | 0; + mid = (mid + Math.imul(al2, bh5)) | 0; + mid = (mid + Math.imul(ah2, bl5)) | 0; + hi = (hi + Math.imul(ah2, bh5)) | 0; + lo = (lo + Math.imul(al1, bl6)) | 0; + mid = (mid + Math.imul(al1, bh6)) | 0; + mid = (mid + Math.imul(ah1, bl6)) | 0; + hi = (hi + Math.imul(ah1, bh6)) | 0; + lo = (lo + Math.imul(al0, bl7)) | 0; + mid = (mid + Math.imul(al0, bh7)) | 0; + mid = (mid + Math.imul(ah0, bl7)) | 0; + hi = (hi + Math.imul(ah0, bh7)) | 0; + var w7 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w7 >>> 26)) | 0; + w7 &= 0x3ffffff; + /* k = 8 */ + lo = Math.imul(al8, bl0); + mid = Math.imul(al8, bh0); + mid = (mid + Math.imul(ah8, bl0)) | 0; + hi = Math.imul(ah8, bh0); + lo = (lo + Math.imul(al7, bl1)) | 0; + mid = (mid + Math.imul(al7, bh1)) | 0; + mid = (mid + Math.imul(ah7, bl1)) | 0; + hi = (hi + Math.imul(ah7, bh1)) | 0; + lo = (lo + Math.imul(al6, bl2)) | 0; + mid = (mid + Math.imul(al6, bh2)) | 0; + mid = (mid + Math.imul(ah6, bl2)) | 0; + hi = (hi + Math.imul(ah6, bh2)) | 0; + lo = (lo + Math.imul(al5, bl3)) | 0; + mid = (mid + Math.imul(al5, bh3)) | 0; + mid = (mid + Math.imul(ah5, bl3)) | 0; + hi = (hi + Math.imul(ah5, bh3)) | 0; + lo = (lo + Math.imul(al4, bl4)) | 0; + mid = (mid + Math.imul(al4, bh4)) | 0; + mid = (mid + Math.imul(ah4, bl4)) | 0; + hi = (hi + Math.imul(ah4, bh4)) | 0; + lo = (lo + Math.imul(al3, bl5)) | 0; + mid = (mid + Math.imul(al3, bh5)) | 0; + mid = (mid + Math.imul(ah3, bl5)) | 0; + hi = (hi + Math.imul(ah3, bh5)) | 0; + lo = (lo + Math.imul(al2, bl6)) | 0; + mid = (mid + Math.imul(al2, bh6)) | 0; + mid = (mid + Math.imul(ah2, bl6)) | 0; + hi = (hi + Math.imul(ah2, bh6)) | 0; + lo = (lo + Math.imul(al1, bl7)) | 0; + mid = (mid + Math.imul(al1, bh7)) | 0; + mid = (mid + Math.imul(ah1, bl7)) | 0; + hi = (hi + Math.imul(ah1, bh7)) | 0; + lo = (lo + Math.imul(al0, bl8)) | 0; + mid = (mid + Math.imul(al0, bh8)) | 0; + mid = (mid + Math.imul(ah0, bl8)) | 0; + hi = (hi + Math.imul(ah0, bh8)) | 0; + var w8 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w8 >>> 26)) | 0; + w8 &= 0x3ffffff; + /* k = 9 */ + lo = Math.imul(al9, bl0); + mid = Math.imul(al9, bh0); + mid = (mid + Math.imul(ah9, bl0)) | 0; + hi = Math.imul(ah9, bh0); + lo = (lo + Math.imul(al8, bl1)) | 0; + mid = (mid + Math.imul(al8, bh1)) | 0; + mid = (mid + Math.imul(ah8, bl1)) | 0; + hi = (hi + Math.imul(ah8, bh1)) | 0; + lo = (lo + Math.imul(al7, bl2)) | 0; + mid = (mid + Math.imul(al7, bh2)) | 0; + mid = (mid + Math.imul(ah7, bl2)) | 0; + hi = (hi + Math.imul(ah7, bh2)) | 0; + lo = (lo + Math.imul(al6, bl3)) | 0; + mid = (mid + Math.imul(al6, bh3)) | 0; + mid = (mid + Math.imul(ah6, bl3)) | 0; + hi = (hi + Math.imul(ah6, bh3)) | 0; + lo = (lo + Math.imul(al5, bl4)) | 0; + mid = (mid + Math.imul(al5, bh4)) | 0; + mid = (mid + Math.imul(ah5, bl4)) | 0; + hi = (hi + Math.imul(ah5, bh4)) | 0; + lo = (lo + Math.imul(al4, bl5)) | 0; + mid = (mid + Math.imul(al4, bh5)) | 0; + mid = (mid + Math.imul(ah4, bl5)) | 0; + hi = (hi + Math.imul(ah4, bh5)) | 0; + lo = (lo + Math.imul(al3, bl6)) | 0; + mid = (mid + Math.imul(al3, bh6)) | 0; + mid = (mid + Math.imul(ah3, bl6)) | 0; + hi = (hi + Math.imul(ah3, bh6)) | 0; + lo = (lo + Math.imul(al2, bl7)) | 0; + mid = (mid + Math.imul(al2, bh7)) | 0; + mid = (mid + Math.imul(ah2, bl7)) | 0; + hi = (hi + Math.imul(ah2, bh7)) | 0; + lo = (lo + Math.imul(al1, bl8)) | 0; + mid = (mid + Math.imul(al1, bh8)) | 0; + mid = (mid + Math.imul(ah1, bl8)) | 0; + hi = (hi + Math.imul(ah1, bh8)) | 0; + lo = (lo + Math.imul(al0, bl9)) | 0; + mid = (mid + Math.imul(al0, bh9)) | 0; + mid = (mid + Math.imul(ah0, bl9)) | 0; + hi = (hi + Math.imul(ah0, bh9)) | 0; + var w9 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w9 >>> 26)) | 0; + w9 &= 0x3ffffff; + /* k = 10 */ + lo = Math.imul(al9, bl1); + mid = Math.imul(al9, bh1); + mid = (mid + Math.imul(ah9, bl1)) | 0; + hi = Math.imul(ah9, bh1); + lo = (lo + Math.imul(al8, bl2)) | 0; + mid = (mid + Math.imul(al8, bh2)) | 0; + mid = (mid + Math.imul(ah8, bl2)) | 0; + hi = (hi + Math.imul(ah8, bh2)) | 0; + lo = (lo + Math.imul(al7, bl3)) | 0; + mid = (mid + Math.imul(al7, bh3)) | 0; + mid = (mid + Math.imul(ah7, bl3)) | 0; + hi = (hi + Math.imul(ah7, bh3)) | 0; + lo = (lo + Math.imul(al6, bl4)) | 0; + mid = (mid + Math.imul(al6, bh4)) | 0; + mid = (mid + Math.imul(ah6, bl4)) | 0; + hi = (hi + Math.imul(ah6, bh4)) | 0; + lo = (lo + Math.imul(al5, bl5)) | 0; + mid = (mid + Math.imul(al5, bh5)) | 0; + mid = (mid + Math.imul(ah5, bl5)) | 0; + hi = (hi + Math.imul(ah5, bh5)) | 0; + lo = (lo + Math.imul(al4, bl6)) | 0; + mid = (mid + Math.imul(al4, bh6)) | 0; + mid = (mid + Math.imul(ah4, bl6)) | 0; + hi = (hi + Math.imul(ah4, bh6)) | 0; + lo = (lo + Math.imul(al3, bl7)) | 0; + mid = (mid + Math.imul(al3, bh7)) | 0; + mid = (mid + Math.imul(ah3, bl7)) | 0; + hi = (hi + Math.imul(ah3, bh7)) | 0; + lo = (lo + Math.imul(al2, bl8)) | 0; + mid = (mid + Math.imul(al2, bh8)) | 0; + mid = (mid + Math.imul(ah2, bl8)) | 0; + hi = (hi + Math.imul(ah2, bh8)) | 0; + lo = (lo + Math.imul(al1, bl9)) | 0; + mid = (mid + Math.imul(al1, bh9)) | 0; + mid = (mid + Math.imul(ah1, bl9)) | 0; + hi = (hi + Math.imul(ah1, bh9)) | 0; + var w10 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w10 >>> 26)) | 0; + w10 &= 0x3ffffff; + /* k = 11 */ + lo = Math.imul(al9, bl2); + mid = Math.imul(al9, bh2); + mid = (mid + Math.imul(ah9, bl2)) | 0; + hi = Math.imul(ah9, bh2); + lo = (lo + Math.imul(al8, bl3)) | 0; + mid = (mid + Math.imul(al8, bh3)) | 0; + mid = (mid + Math.imul(ah8, bl3)) | 0; + hi = (hi + Math.imul(ah8, bh3)) | 0; + lo = (lo + Math.imul(al7, bl4)) | 0; + mid = (mid + Math.imul(al7, bh4)) | 0; + mid = (mid + Math.imul(ah7, bl4)) | 0; + hi = (hi + Math.imul(ah7, bh4)) | 0; + lo = (lo + Math.imul(al6, bl5)) | 0; + mid = (mid + Math.imul(al6, bh5)) | 0; + mid = (mid + Math.imul(ah6, bl5)) | 0; + hi = (hi + Math.imul(ah6, bh5)) | 0; + lo = (lo + Math.imul(al5, bl6)) | 0; + mid = (mid + Math.imul(al5, bh6)) | 0; + mid = (mid + Math.imul(ah5, bl6)) | 0; + hi = (hi + Math.imul(ah5, bh6)) | 0; + lo = (lo + Math.imul(al4, bl7)) | 0; + mid = (mid + Math.imul(al4, bh7)) | 0; + mid = (mid + Math.imul(ah4, bl7)) | 0; + hi = (hi + Math.imul(ah4, bh7)) | 0; + lo = (lo + Math.imul(al3, bl8)) | 0; + mid = (mid + Math.imul(al3, bh8)) | 0; + mid = (mid + Math.imul(ah3, bl8)) | 0; + hi = (hi + Math.imul(ah3, bh8)) | 0; + lo = (lo + Math.imul(al2, bl9)) | 0; + mid = (mid + Math.imul(al2, bh9)) | 0; + mid = (mid + Math.imul(ah2, bl9)) | 0; + hi = (hi + Math.imul(ah2, bh9)) | 0; + var w11 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w11 >>> 26)) | 0; + w11 &= 0x3ffffff; + /* k = 12 */ + lo = Math.imul(al9, bl3); + mid = Math.imul(al9, bh3); + mid = (mid + Math.imul(ah9, bl3)) | 0; + hi = Math.imul(ah9, bh3); + lo = (lo + Math.imul(al8, bl4)) | 0; + mid = (mid + Math.imul(al8, bh4)) | 0; + mid = (mid + Math.imul(ah8, bl4)) | 0; + hi = (hi + Math.imul(ah8, bh4)) | 0; + lo = (lo + Math.imul(al7, bl5)) | 0; + mid = (mid + Math.imul(al7, bh5)) | 0; + mid = (mid + Math.imul(ah7, bl5)) | 0; + hi = (hi + Math.imul(ah7, bh5)) | 0; + lo = (lo + Math.imul(al6, bl6)) | 0; + mid = (mid + Math.imul(al6, bh6)) | 0; + mid = (mid + Math.imul(ah6, bl6)) | 0; + hi = (hi + Math.imul(ah6, bh6)) | 0; + lo = (lo + Math.imul(al5, bl7)) | 0; + mid = (mid + Math.imul(al5, bh7)) | 0; + mid = (mid + Math.imul(ah5, bl7)) | 0; + hi = (hi + Math.imul(ah5, bh7)) | 0; + lo = (lo + Math.imul(al4, bl8)) | 0; + mid = (mid + Math.imul(al4, bh8)) | 0; + mid = (mid + Math.imul(ah4, bl8)) | 0; + hi = (hi + Math.imul(ah4, bh8)) | 0; + lo = (lo + Math.imul(al3, bl9)) | 0; + mid = (mid + Math.imul(al3, bh9)) | 0; + mid = (mid + Math.imul(ah3, bl9)) | 0; + hi = (hi + Math.imul(ah3, bh9)) | 0; + var w12 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w12 >>> 26)) | 0; + w12 &= 0x3ffffff; + /* k = 13 */ + lo = Math.imul(al9, bl4); + mid = Math.imul(al9, bh4); + mid = (mid + Math.imul(ah9, bl4)) | 0; + hi = Math.imul(ah9, bh4); + lo = (lo + Math.imul(al8, bl5)) | 0; + mid = (mid + Math.imul(al8, bh5)) | 0; + mid = (mid + Math.imul(ah8, bl5)) | 0; + hi = (hi + Math.imul(ah8, bh5)) | 0; + lo = (lo + Math.imul(al7, bl6)) | 0; + mid = (mid + Math.imul(al7, bh6)) | 0; + mid = (mid + Math.imul(ah7, bl6)) | 0; + hi = (hi + Math.imul(ah7, bh6)) | 0; + lo = (lo + Math.imul(al6, bl7)) | 0; + mid = (mid + Math.imul(al6, bh7)) | 0; + mid = (mid + Math.imul(ah6, bl7)) | 0; + hi = (hi + Math.imul(ah6, bh7)) | 0; + lo = (lo + Math.imul(al5, bl8)) | 0; + mid = (mid + Math.imul(al5, bh8)) | 0; + mid = (mid + Math.imul(ah5, bl8)) | 0; + hi = (hi + Math.imul(ah5, bh8)) | 0; + lo = (lo + Math.imul(al4, bl9)) | 0; + mid = (mid + Math.imul(al4, bh9)) | 0; + mid = (mid + Math.imul(ah4, bl9)) | 0; + hi = (hi + Math.imul(ah4, bh9)) | 0; + var w13 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w13 >>> 26)) | 0; + w13 &= 0x3ffffff; + /* k = 14 */ + lo = Math.imul(al9, bl5); + mid = Math.imul(al9, bh5); + mid = (mid + Math.imul(ah9, bl5)) | 0; + hi = Math.imul(ah9, bh5); + lo = (lo + Math.imul(al8, bl6)) | 0; + mid = (mid + Math.imul(al8, bh6)) | 0; + mid = (mid + Math.imul(ah8, bl6)) | 0; + hi = (hi + Math.imul(ah8, bh6)) | 0; + lo = (lo + Math.imul(al7, bl7)) | 0; + mid = (mid + Math.imul(al7, bh7)) | 0; + mid = (mid + Math.imul(ah7, bl7)) | 0; + hi = (hi + Math.imul(ah7, bh7)) | 0; + lo = (lo + Math.imul(al6, bl8)) | 0; + mid = (mid + Math.imul(al6, bh8)) | 0; + mid = (mid + Math.imul(ah6, bl8)) | 0; + hi = (hi + Math.imul(ah6, bh8)) | 0; + lo = (lo + Math.imul(al5, bl9)) | 0; + mid = (mid + Math.imul(al5, bh9)) | 0; + mid = (mid + Math.imul(ah5, bl9)) | 0; + hi = (hi + Math.imul(ah5, bh9)) | 0; + var w14 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w14 >>> 26)) | 0; + w14 &= 0x3ffffff; + /* k = 15 */ + lo = Math.imul(al9, bl6); + mid = Math.imul(al9, bh6); + mid = (mid + Math.imul(ah9, bl6)) | 0; + hi = Math.imul(ah9, bh6); + lo = (lo + Math.imul(al8, bl7)) | 0; + mid = (mid + Math.imul(al8, bh7)) | 0; + mid = (mid + Math.imul(ah8, bl7)) | 0; + hi = (hi + Math.imul(ah8, bh7)) | 0; + lo = (lo + Math.imul(al7, bl8)) | 0; + mid = (mid + Math.imul(al7, bh8)) | 0; + mid = (mid + Math.imul(ah7, bl8)) | 0; + hi = (hi + Math.imul(ah7, bh8)) | 0; + lo = (lo + Math.imul(al6, bl9)) | 0; + mid = (mid + Math.imul(al6, bh9)) | 0; + mid = (mid + Math.imul(ah6, bl9)) | 0; + hi = (hi + Math.imul(ah6, bh9)) | 0; + var w15 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w15 >>> 26)) | 0; + w15 &= 0x3ffffff; + /* k = 16 */ + lo = Math.imul(al9, bl7); + mid = Math.imul(al9, bh7); + mid = (mid + Math.imul(ah9, bl7)) | 0; + hi = Math.imul(ah9, bh7); + lo = (lo + Math.imul(al8, bl8)) | 0; + mid = (mid + Math.imul(al8, bh8)) | 0; + mid = (mid + Math.imul(ah8, bl8)) | 0; + hi = (hi + Math.imul(ah8, bh8)) | 0; + lo = (lo + Math.imul(al7, bl9)) | 0; + mid = (mid + Math.imul(al7, bh9)) | 0; + mid = (mid + Math.imul(ah7, bl9)) | 0; + hi = (hi + Math.imul(ah7, bh9)) | 0; + var w16 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w16 >>> 26)) | 0; + w16 &= 0x3ffffff; + /* k = 17 */ + lo = Math.imul(al9, bl8); + mid = Math.imul(al9, bh8); + mid = (mid + Math.imul(ah9, bl8)) | 0; + hi = Math.imul(ah9, bh8); + lo = (lo + Math.imul(al8, bl9)) | 0; + mid = (mid + Math.imul(al8, bh9)) | 0; + mid = (mid + Math.imul(ah8, bl9)) | 0; + hi = (hi + Math.imul(ah8, bh9)) | 0; + var w17 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w17 >>> 26)) | 0; + w17 &= 0x3ffffff; + /* k = 18 */ + lo = Math.imul(al9, bl9); + mid = Math.imul(al9, bh9); + mid = (mid + Math.imul(ah9, bl9)) | 0; + hi = Math.imul(ah9, bh9); + var w18 = (((c + lo) | 0) + ((mid & 0x1fff) << 13)) | 0; + c = (((hi + (mid >>> 13)) | 0) + (w18 >>> 26)) | 0; + w18 &= 0x3ffffff; + o[0] = w0; + o[1] = w1; + o[2] = w2; + o[3] = w3; + o[4] = w4; + o[5] = w5; + o[6] = w6; + o[7] = w7; + o[8] = w8; + o[9] = w9; + o[10] = w10; + o[11] = w11; + o[12] = w12; + o[13] = w13; + o[14] = w14; + o[15] = w15; + o[16] = w16; + o[17] = w17; + o[18] = w18; + if (c !== 0) { + o[19] = c; + out.length++; + } + return out; + }; + + // Polyfill comb + if (!Math.imul) { + comb10MulTo = smallMulTo; + } + + function bigMulTo (self, num, out) { + out.negative = num.negative ^ self.negative; + out.length = self.length + num.length; + + var carry = 0; + var hncarry = 0; + for (var k = 0; k < out.length - 1; k++) { + // Sum all words with the same `i + j = k` and accumulate `ncarry`, + // note that ncarry could be >= 0x3ffffff + var ncarry = hncarry; + hncarry = 0; + var rword = carry & 0x3ffffff; + var maxJ = Math.min(k, num.length - 1); + for (var j = Math.max(0, k - self.length + 1); j <= maxJ; j++) { + var i = k - j; + var a = self.words[i] | 0; + var b = num.words[j] | 0; + var r = a * b; + + var lo = r & 0x3ffffff; + ncarry = (ncarry + ((r / 0x4000000) | 0)) | 0; + lo = (lo + rword) | 0; + rword = lo & 0x3ffffff; + ncarry = (ncarry + (lo >>> 26)) | 0; + + hncarry += ncarry >>> 26; + ncarry &= 0x3ffffff; + } + out.words[k] = rword; + carry = ncarry; + ncarry = hncarry; + } + if (carry !== 0) { + out.words[k] = carry; + } else { + out.length--; + } + + return out.strip(); } -} -/** - * This is a unified interface for event plugins to be installed and configured. - * - * Event plugins can implement the following properties: - * - * `extractEvents` {function(string, DOMEventTarget, string, object): *} - * Required. When a top-level event is fired, this method is expected to - * extract synthetic events that will in turn be queued and dispatched. - * - * `eventTypes` {object} - * Optional, plugins that fire events must publish a mapping of registration - * names that are used to register listeners. Values of this mapping must - * be objects that contain `registrationName` or `phasedRegistrationNames`. - * - * `executeDispatch` {function(object, function, string)} - * Optional, allows plugins to override how an event gets dispatched. By - * default, the listener is simply invoked. - * - * Each plugin that is injected into `EventsPluginHub` is immediately operable. - * - * @public - */ -var EventPluginHub = { - /** - * Methods for injecting dependencies. - */ - injection: { - /** - * @param {array} InjectedEventPluginOrder - * @public - */ - injectEventPluginOrder: EventPluginRegistry.injectEventPluginOrder, + function jumboMulTo (self, num, out) { + var fftm = new FFTM(); + return fftm.mulp(self, num, out); + } - /** - * @param {object} injectedNamesToPlugins Map from names to plugin modules. - */ - injectEventPluginsByName: EventPluginRegistry.injectEventPluginsByName - }, + BN.prototype.mulTo = function mulTo (num, out) { + var res; + var len = this.length + num.length; + if (this.length === 10 && num.length === 10) { + res = comb10MulTo(this, num, out); + } else if (len < 63) { + res = smallMulTo(this, num, out); + } else if (len < 1024) { + res = bigMulTo(this, num, out); + } else { + res = jumboMulTo(this, num, out); + } - /** - * Stores `listener` at `listenerBank[registrationName][key]`. Is idempotent. - * - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @param {function} listener The callback to store. - */ - putListener: function (inst, registrationName, listener) { - !(typeof listener === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected %s listener to be a function, instead got type %s', registrationName, typeof listener) : _prodInvariant('94', registrationName, typeof listener) : void 0; + return res; + }; - var key = getDictionaryKey(inst); - var bankForRegistrationName = listenerBank[registrationName] || (listenerBank[registrationName] = {}); - bankForRegistrationName[key] = listener; + // Cooley-Tukey algorithm for FFT + // slightly revisited to rely on looping instead of recursion - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.didPutListener) { - PluginModule.didPutListener(inst, registrationName, listener); - } - }, + function FFTM (x, y) { + this.x = x; + this.y = y; + } - /** - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @return {?function} The stored callback. - */ - getListener: function (inst, registrationName) { - // TODO: shouldPreventMouseEvent is DOM-specific and definitely should not - // live here; needs to be moved to a better place soon - var bankForRegistrationName = listenerBank[registrationName]; - if (shouldPreventMouseEvent(registrationName, inst._currentElement.type, inst._currentElement.props)) { - return null; + FFTM.prototype.makeRBT = function makeRBT (N) { + var t = new Array(N); + var l = BN.prototype._countBits(N) - 1; + for (var i = 0; i < N; i++) { + t[i] = this.revBin(i, l, N); } - var key = getDictionaryKey(inst); - return bankForRegistrationName && bankForRegistrationName[key]; - }, - /** - * Deletes a listener from the registration bank. - * - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - */ - deleteListener: function (inst, registrationName) { - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.willDeleteListener) { - PluginModule.willDeleteListener(inst, registrationName); + return t; + }; + + // Returns binary-reversed representation of `x` + FFTM.prototype.revBin = function revBin (x, l, N) { + if (x === 0 || x === N - 1) return x; + + var rb = 0; + for (var i = 0; i < l; i++) { + rb |= (x & 1) << (l - i - 1); + x >>= 1; } - var bankForRegistrationName = listenerBank[registrationName]; - // TODO: This should never be null -- when is it? - if (bankForRegistrationName) { - var key = getDictionaryKey(inst); - delete bankForRegistrationName[key]; + return rb; + }; + + // Performs "tweedling" phase, therefore 'emulating' + // behaviour of the recursive algorithm + FFTM.prototype.permute = function permute (rbt, rws, iws, rtws, itws, N) { + for (var i = 0; i < N; i++) { + rtws[i] = rws[rbt[i]]; + itws[i] = iws[rbt[i]]; } - }, + }; - /** - * Deletes all listeners for the DOM element with the supplied ID. - * - * @param {object} inst The instance, which is the source of events. - */ - deleteAllListeners: function (inst) { - var key = getDictionaryKey(inst); - for (var registrationName in listenerBank) { - if (!listenerBank.hasOwnProperty(registrationName)) { - continue; - } + FFTM.prototype.transform = function transform (rws, iws, rtws, itws, N, rbt) { + this.permute(rbt, rws, iws, rtws, itws, N); - if (!listenerBank[registrationName][key]) { - continue; - } + for (var s = 1; s < N; s <<= 1) { + var l = s << 1; - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.willDeleteListener) { - PluginModule.willDeleteListener(inst, registrationName); - } + var rtwdf = Math.cos(2 * Math.PI / l); + var itwdf = Math.sin(2 * Math.PI / l); - delete listenerBank[registrationName][key]; - } - }, + for (var p = 0; p < N; p += l) { + var rtwdf_ = rtwdf; + var itwdf_ = itwdf; - /** - * Allows registered plugins an opportunity to extract events from top-level - * native browser events. - * - * @return {*} An accumulation of synthetic events. - * @internal - */ - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var events; - var plugins = EventPluginRegistry.plugins; - for (var i = 0; i < plugins.length; i++) { - // Not every plugin in the ordering may be loaded at runtime. - var possiblePlugin = plugins[i]; - if (possiblePlugin) { - var extractedEvents = possiblePlugin.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); - if (extractedEvents) { - events = accumulateInto(events, extractedEvents); + for (var j = 0; j < s; j++) { + var re = rtws[p + j]; + var ie = itws[p + j]; + + var ro = rtws[p + j + s]; + var io = itws[p + j + s]; + + var rx = rtwdf_ * ro - itwdf_ * io; + + io = rtwdf_ * io + itwdf_ * ro; + ro = rx; + + rtws[p + j] = re + ro; + itws[p + j] = ie + io; + + rtws[p + j + s] = re - ro; + itws[p + j + s] = ie - io; + + /* jshint maxdepth : false */ + if (j !== l) { + rx = rtwdf * rtwdf_ - itwdf * itwdf_; + + itwdf_ = rtwdf * itwdf_ + itwdf * rtwdf_; + rtwdf_ = rx; + } } } } - return events; - }, + }; - /** - * Enqueues a synthetic event that should be dispatched when - * `processEventQueue` is invoked. - * - * @param {*} events An accumulation of synthetic events. - * @internal - */ - enqueueEvents: function (events) { - if (events) { - eventQueue = accumulateInto(eventQueue, events); + FFTM.prototype.guessLen13b = function guessLen13b (n, m) { + var N = Math.max(m, n) | 1; + var odd = N & 1; + var i = 0; + for (N = N / 2 | 0; N; N = N >>> 1) { + i++; } - }, - /** - * Dispatches all synthetic events on the event queue. - * - * @internal - */ - processEventQueue: function (simulated) { - // Set `eventQueue` to null before processing it so that we can tell if more - // events get enqueued while processing. - var processingEventQueue = eventQueue; - eventQueue = null; - if (simulated) { - forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseSimulated); - } else { - forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseTopLevel); - } - !!eventQueue ? process.env.NODE_ENV !== 'production' ? invariant(false, 'processEventQueue(): Additional events were enqueued while processing an event queue. Support for this has not yet been implemented.') : _prodInvariant('95') : void 0; - // This would be a good time to rethrow if any of the event handlers threw. - ReactErrorUtils.rethrowCaughtError(); - }, + return 1 << i + 1 + odd; + }; - /** - * These are needed for tests only. Do not use! - */ - __purge: function () { - listenerBank = {}; - }, + FFTM.prototype.conjugate = function conjugate (rws, iws, N) { + if (N <= 1) return; - __getListenerBank: function () { - return listenerBank; - } -}; + for (var i = 0; i < N / 2; i++) { + var t = rws[i]; -module.exports = EventPluginHub; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + rws[i] = rws[N - i - 1]; + rws[N - i - 1] = t; -/***/ }), -/* 33 */ -/***/ (function(module, exports, __webpack_require__) { + t = iws[i]; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + iws[i] = -iws[N - i - 1]; + iws[N - i - 1] = -t; + } + }; + FFTM.prototype.normalize13b = function normalize13b (ws, N) { + var carry = 0; + for (var i = 0; i < N / 2; i++) { + var w = Math.round(ws[2 * i + 1] / N) * 0x2000 + + Math.round(ws[2 * i] / N) + + carry; + ws[i] = w & 0x3ffffff; -var SyntheticEvent = __webpack_require__(16); + if (w < 0x4000000) { + carry = 0; + } else { + carry = w / 0x4000000 | 0; + } + } -var getEventTarget = __webpack_require__(52); + return ws; + }; -/** - * @interface UIEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var UIEventInterface = { - view: function (event) { - if (event.view) { - return event.view; - } + FFTM.prototype.convert13b = function convert13b (ws, len, rws, N) { + var carry = 0; + for (var i = 0; i < len; i++) { + carry = carry + (ws[i] | 0); - var target = getEventTarget(event); - if (target.window === target) { - // target is a window object - return target; + rws[2 * i] = carry & 0x1fff; carry = carry >>> 13; + rws[2 * i + 1] = carry & 0x1fff; carry = carry >>> 13; } - var doc = target.ownerDocument; - // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. - if (doc) { - return doc.defaultView || doc.parentWindow; - } else { - return window; + // Pad with zeroes + for (i = 2 * len; i < N; ++i) { + rws[i] = 0; } - }, - detail: function (event) { - return event.detail || 0; - } -}; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticUIEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} + assert(carry === 0); + assert((carry & ~0x1fff) === 0); + }; -SyntheticEvent.augmentClass(SyntheticUIEvent, UIEventInterface); + FFTM.prototype.stub = function stub (N) { + var ph = new Array(N); + for (var i = 0; i < N; i++) { + ph[i] = 0; + } -module.exports = SyntheticUIEvent; + return ph; + }; -/***/ }), -/* 34 */ -/***/ (function(module, exports, __webpack_require__) { + FFTM.prototype.mulp = function mulp (x, y, out) { + var N = 2 * this.guessLen13b(x.length, y.length); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var rbt = this.makeRBT(N); + var _ = this.stub(N); + var rws = new Array(N); + var rwst = new Array(N); + var iwst = new Array(N); -/** - * `ReactInstanceMap` maintains a mapping from a public facing stateful - * instance (key) and the internal representation (value). This allows public - * methods to accept the user facing instance as an argument and map them back - * to internal methods. - */ + var nrws = new Array(N); + var nrwst = new Array(N); + var niwst = new Array(N); -// TODO: Replace this with ES6: var ReactInstanceMap = new Map(); + var rmws = out.words; + rmws.length = N; -var ReactInstanceMap = { - /** - * This API should be called `delete` but we'd have to make sure to always - * transform these to strings for IE support. When this transform is fully - * supported we can rename it. - */ - remove: function (key) { - key._reactInternalInstance = undefined; - }, + this.convert13b(x.words, x.length, rws, N); + this.convert13b(y.words, y.length, nrws, N); - get: function (key) { - return key._reactInternalInstance; - }, + this.transform(rws, _, rwst, iwst, N, rbt); + this.transform(nrws, _, nrwst, niwst, N, rbt); - has: function (key) { - return key._reactInternalInstance !== undefined; - }, + for (var i = 0; i < N; i++) { + var rx = rwst[i] * nrwst[i] - iwst[i] * niwst[i]; + iwst[i] = rwst[i] * niwst[i] + iwst[i] * nrwst[i]; + rwst[i] = rx; + } - set: function (key, value) { - key._reactInternalInstance = value; - } -}; + this.conjugate(rwst, iwst, N); + this.transform(rwst, iwst, rmws, _, N, rbt); + this.conjugate(rmws, _, N); + this.normalize13b(rmws, N); -module.exports = ReactInstanceMap; + out.negative = x.negative ^ y.negative; + out.length = x.length + y.length; + return out.strip(); + }; -/***/ }), -/* 35 */, -/* 36 */, -/* 37 */, -/* 38 */ -/***/ (function(module, exports, __webpack_require__) { + // Multiply `this` by `num` + BN.prototype.mul = function mul (num) { + var out = new BN(null); + out.words = new Array(this.length + num.length); + return this.mulTo(num, out); + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + // Multiply employing FFT + BN.prototype.mulf = function mulf (num) { + var out = new BN(null); + out.words = new Array(this.length + num.length); + return jumboMulTo(this, num, out); + }; + // In-place Multiplication + BN.prototype.imul = function imul (num) { + return this.clone().mulTo(num, this); + }; + BN.prototype.imuln = function imuln (num) { + assert(typeof num === 'number'); + assert(num < 0x4000000); -var canDefineProperty = false; -if (process.env.NODE_ENV !== 'production') { - try { - // $FlowFixMe https://github.com/facebook/flow/issues/285 - Object.defineProperty({}, 'x', { get: function () {} }); - canDefineProperty = true; - } catch (x) { - // IE will fail on defineProperty - } -} + // Carry + var carry = 0; + for (var i = 0; i < this.length; i++) { + var w = (this.words[i] | 0) * num; + var lo = (w & 0x3ffffff) + (carry & 0x3ffffff); + carry >>= 26; + carry += (w / 0x4000000) | 0; + // NOTE: lo is 27bit maximum + carry += lo >>> 26; + this.words[i] = lo & 0x3ffffff; + } -module.exports = canDefineProperty; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + if (carry !== 0) { + this.words[i] = carry; + this.length++; + } -/***/ }), -/* 39 */ -/***/ (function(module, exports, __webpack_require__) { + return this; + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.muln = function muln (num) { + return this.clone().imuln(num); + }; + // `this` * `this` + BN.prototype.sqr = function sqr () { + return this.mul(this); + }; + // `this` * `this` in-place + BN.prototype.isqr = function isqr () { + return this.imul(this.clone()); + }; -var emptyObject = {}; + // Math.pow(`this`, `num`) + BN.prototype.pow = function pow (num) { + var w = toBitArray(num); + if (w.length === 0) return new BN(1); -if (process.env.NODE_ENV !== 'production') { - Object.freeze(emptyObject); -} + // Skip leading zeroes + var res = this; + for (var i = 0; i < w.length; i++, res = res.sqr()) { + if (w[i] !== 0) break; + } -module.exports = emptyObject; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + if (++i < w.length) { + for (var q = res.sqr(); i < w.length; i++, q = q.sqr()) { + if (w[i] === 0) continue; -/***/ }), -/* 40 */ -/***/ (function(module, exports, __webpack_require__) { + res = res.mul(q); + } + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + return res; + }; + // Shift-left in-place + BN.prototype.iushln = function iushln (bits) { + assert(typeof bits === 'number' && bits >= 0); + var r = bits % 26; + var s = (bits - r) / 26; + var carryMask = (0x3ffffff >>> (26 - r)) << (26 - r); + var i; + + if (r !== 0) { + var carry = 0; + + for (i = 0; i < this.length; i++) { + var newCarry = this.words[i] & carryMask; + var c = ((this.words[i] | 0) - newCarry) << r; + this.words[i] = c | carry; + carry = newCarry >>> (26 - r); + } + if (carry) { + this.words[i] = carry; + this.length++; + } + } -var _prodInvariant = __webpack_require__(3); + if (s !== 0) { + for (i = this.length - 1; i >= 0; i--) { + this.words[i + s] = this.words[i]; + } -var invariant = __webpack_require__(1); + for (i = 0; i < s; i++) { + this.words[i] = 0; + } -/** - * Injectable ordering of event plugins. - */ -var eventPluginOrder = null; + this.length += s; + } -/** - * Injectable mapping from names to event plugin modules. - */ -var namesToPlugins = {}; + return this.strip(); + }; -/** - * Recomputes the plugin list using the injected plugins and plugin ordering. - * - * @private - */ -function recomputePluginOrdering() { - if (!eventPluginOrder) { - // Wait until an `eventPluginOrder` is injected. - return; - } - for (var pluginName in namesToPlugins) { - var pluginModule = namesToPlugins[pluginName]; - var pluginIndex = eventPluginOrder.indexOf(pluginName); - !(pluginIndex > -1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugins that do not exist in the plugin ordering, `%s`.', pluginName) : _prodInvariant('96', pluginName) : void 0; - if (EventPluginRegistry.plugins[pluginIndex]) { - continue; - } - !pluginModule.extractEvents ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Event plugins must implement an `extractEvents` method, but `%s` does not.', pluginName) : _prodInvariant('97', pluginName) : void 0; - EventPluginRegistry.plugins[pluginIndex] = pluginModule; - var publishedEvents = pluginModule.eventTypes; - for (var eventName in publishedEvents) { - !publishEventForPlugin(publishedEvents[eventName], pluginModule, eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Failed to publish event `%s` for plugin `%s`.', eventName, pluginName) : _prodInvariant('98', eventName, pluginName) : void 0; + BN.prototype.ishln = function ishln (bits) { + // TODO(indutny): implement me + assert(this.negative === 0); + return this.iushln(bits); + }; + + // Shift-right in-place + // NOTE: `hint` is a lowest bit before trailing zeroes + // NOTE: if `extended` is present - it will be filled with destroyed bits + BN.prototype.iushrn = function iushrn (bits, hint, extended) { + assert(typeof bits === 'number' && bits >= 0); + var h; + if (hint) { + h = (hint - (hint % 26)) / 26; + } else { + h = 0; } - } -} -/** - * Publishes an event so that it can be dispatched by the supplied plugin. - * - * @param {object} dispatchConfig Dispatch configuration for the event. - * @param {object} PluginModule Plugin publishing the event. - * @return {boolean} True if the event was successfully published. - * @private - */ -function publishEventForPlugin(dispatchConfig, pluginModule, eventName) { - !!EventPluginRegistry.eventNameDispatchConfigs.hasOwnProperty(eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same event name, `%s`.', eventName) : _prodInvariant('99', eventName) : void 0; - EventPluginRegistry.eventNameDispatchConfigs[eventName] = dispatchConfig; + var r = bits % 26; + var s = Math.min((bits - r) / 26, this.length); + var mask = 0x3ffffff ^ ((0x3ffffff >>> r) << r); + var maskedWords = extended; - var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; - if (phasedRegistrationNames) { - for (var phaseName in phasedRegistrationNames) { - if (phasedRegistrationNames.hasOwnProperty(phaseName)) { - var phasedRegistrationName = phasedRegistrationNames[phaseName]; - publishRegistrationName(phasedRegistrationName, pluginModule, eventName); + h -= s; + h = Math.max(0, h); + + // Extended mode, copy masked part + if (maskedWords) { + for (var i = 0; i < s; i++) { + maskedWords.words[i] = this.words[i]; } + maskedWords.length = s; } - return true; - } else if (dispatchConfig.registrationName) { - publishRegistrationName(dispatchConfig.registrationName, pluginModule, eventName); - return true; - } - return false; -} -/** - * Publishes a registration name that is used to identify dispatched events and - * can be used with `EventPluginHub.putListener` to register listeners. - * - * @param {string} registrationName Registration name to add. - * @param {object} PluginModule Plugin publishing the event. - * @private - */ -function publishRegistrationName(registrationName, pluginModule, eventName) { - !!EventPluginRegistry.registrationNameModules[registrationName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same registration name, `%s`.', registrationName) : _prodInvariant('100', registrationName) : void 0; - EventPluginRegistry.registrationNameModules[registrationName] = pluginModule; - EventPluginRegistry.registrationNameDependencies[registrationName] = pluginModule.eventTypes[eventName].dependencies; + if (s === 0) { + // No-op, we should not move anything at all + } else if (this.length > s) { + this.length -= s; + for (i = 0; i < this.length; i++) { + this.words[i] = this.words[i + s]; + } + } else { + this.words[0] = 0; + this.length = 1; + } - if (process.env.NODE_ENV !== 'production') { - var lowerCasedName = registrationName.toLowerCase(); - EventPluginRegistry.possibleRegistrationNames[lowerCasedName] = registrationName; + var carry = 0; + for (i = this.length - 1; i >= 0 && (carry !== 0 || i >= h); i--) { + var word = this.words[i] | 0; + this.words[i] = (carry << (26 - r)) | (word >>> r); + carry = word & mask; + } - if (registrationName === 'onDoubleClick') { - EventPluginRegistry.possibleRegistrationNames.ondblclick = registrationName; + // Push carried bits as a mask + if (maskedWords && carry !== 0) { + maskedWords.words[maskedWords.length++] = carry; } - } -} -/** - * Registers plugins so that they can extract and dispatch events. - * - * @see {EventPluginHub} - */ -var EventPluginRegistry = { - /** - * Ordered list of injected plugins. - */ - plugins: [], + if (this.length === 0) { + this.words[0] = 0; + this.length = 1; + } - /** - * Mapping from event name to dispatch config - */ - eventNameDispatchConfigs: {}, + return this.strip(); + }; - /** - * Mapping from registration name to plugin module - */ - registrationNameModules: {}, + BN.prototype.ishrn = function ishrn (bits, hint, extended) { + // TODO(indutny): implement me + assert(this.negative === 0); + return this.iushrn(bits, hint, extended); + }; - /** - * Mapping from registration name to event name - */ - registrationNameDependencies: {}, + // Shift-left + BN.prototype.shln = function shln (bits) { + return this.clone().ishln(bits); + }; - /** - * Mapping from lowercase registration names to the properly cased version, - * used to warn in the case of missing event handlers. Available - * only in __DEV__. - * @type {Object} - */ - possibleRegistrationNames: process.env.NODE_ENV !== 'production' ? {} : null, - // Trust the developer to only use possibleRegistrationNames in __DEV__ + BN.prototype.ushln = function ushln (bits) { + return this.clone().iushln(bits); + }; - /** - * Injects an ordering of plugins (by plugin name). This allows the ordering - * to be decoupled from injection of the actual plugins so that ordering is - * always deterministic regardless of packaging, on-the-fly injection, etc. - * - * @param {array} InjectedEventPluginOrder - * @internal - * @see {EventPluginHub.injection.injectEventPluginOrder} - */ - injectEventPluginOrder: function (injectedEventPluginOrder) { - !!eventPluginOrder ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugin ordering more than once. You are likely trying to load more than one copy of React.') : _prodInvariant('101') : void 0; - // Clone the ordering so it cannot be dynamically mutated. - eventPluginOrder = Array.prototype.slice.call(injectedEventPluginOrder); - recomputePluginOrdering(); - }, + // Shift-right + BN.prototype.shrn = function shrn (bits) { + return this.clone().ishrn(bits); + }; - /** - * Injects plugins to be used by `EventPluginHub`. The plugin names must be - * in the ordering injected by `injectEventPluginOrder`. - * - * Plugins can be injected as part of page initialization or on-the-fly. - * - * @param {object} injectedNamesToPlugins Map from names to plugin modules. - * @internal - * @see {EventPluginHub.injection.injectEventPluginsByName} - */ - injectEventPluginsByName: function (injectedNamesToPlugins) { - var isOrderingDirty = false; - for (var pluginName in injectedNamesToPlugins) { - if (!injectedNamesToPlugins.hasOwnProperty(pluginName)) { - continue; - } - var pluginModule = injectedNamesToPlugins[pluginName]; - if (!namesToPlugins.hasOwnProperty(pluginName) || namesToPlugins[pluginName] !== pluginModule) { - !!namesToPlugins[pluginName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject two different event plugins using the same name, `%s`.', pluginName) : _prodInvariant('102', pluginName) : void 0; - namesToPlugins[pluginName] = pluginModule; - isOrderingDirty = true; - } - } - if (isOrderingDirty) { - recomputePluginOrdering(); + BN.prototype.ushrn = function ushrn (bits) { + return this.clone().iushrn(bits); + }; + + // Test if n bit is set + BN.prototype.testn = function testn (bit) { + assert(typeof bit === 'number' && bit >= 0); + var r = bit % 26; + var s = (bit - r) / 26; + var q = 1 << r; + + // Fast case: bit is much higher than all existing words + if (this.length <= s) return false; + + // Check bit and return + var w = this.words[s]; + + return !!(w & q); + }; + + // Return only lowers bits of number (in-place) + BN.prototype.imaskn = function imaskn (bits) { + assert(typeof bits === 'number' && bits >= 0); + var r = bits % 26; + var s = (bits - r) / 26; + + assert(this.negative === 0, 'imaskn works only with positive numbers'); + + if (this.length <= s) { + return this; } - }, - /** - * Looks up the plugin for the supplied event. - * - * @param {object} event A synthetic event. - * @return {?object} The plugin that created the supplied event. - * @internal - */ - getPluginModuleForEvent: function (event) { - var dispatchConfig = event.dispatchConfig; - if (dispatchConfig.registrationName) { - return EventPluginRegistry.registrationNameModules[dispatchConfig.registrationName] || null; + if (r !== 0) { + s++; } - if (dispatchConfig.phasedRegistrationNames !== undefined) { - // pulling phasedRegistrationNames out of dispatchConfig helps Flow see - // that it is not undefined. - var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; + this.length = Math.min(s, this.length); - for (var phase in phasedRegistrationNames) { - if (!phasedRegistrationNames.hasOwnProperty(phase)) { - continue; - } - var pluginModule = EventPluginRegistry.registrationNameModules[phasedRegistrationNames[phase]]; - if (pluginModule) { - return pluginModule; - } - } + if (r !== 0) { + var mask = 0x3ffffff ^ ((0x3ffffff >>> r) << r); + this.words[this.length - 1] &= mask; } - return null; - }, - /** - * Exposed for unit testing. - * @private - */ - _resetEventPlugins: function () { - eventPluginOrder = null; - for (var pluginName in namesToPlugins) { - if (namesToPlugins.hasOwnProperty(pluginName)) { - delete namesToPlugins[pluginName]; + return this.strip(); + }; + + // Return only lowers bits of number + BN.prototype.maskn = function maskn (bits) { + return this.clone().imaskn(bits); + }; + + // Add plain number `num` to `this` + BN.prototype.iaddn = function iaddn (num) { + assert(typeof num === 'number'); + assert(num < 0x4000000); + if (num < 0) return this.isubn(-num); + + // Possible sign change + if (this.negative !== 0) { + if (this.length === 1 && (this.words[0] | 0) < num) { + this.words[0] = num - (this.words[0] | 0); + this.negative = 0; + return this; } + + this.negative = 0; + this.isubn(num); + this.negative = 1; + return this; } - EventPluginRegistry.plugins.length = 0; - var eventNameDispatchConfigs = EventPluginRegistry.eventNameDispatchConfigs; - for (var eventName in eventNameDispatchConfigs) { - if (eventNameDispatchConfigs.hasOwnProperty(eventName)) { - delete eventNameDispatchConfigs[eventName]; + // Add without checks + return this._iaddn(num); + }; + + BN.prototype._iaddn = function _iaddn (num) { + this.words[0] += num; + + // Carry + for (var i = 0; i < this.length && this.words[i] >= 0x4000000; i++) { + this.words[i] -= 0x4000000; + if (i === this.length - 1) { + this.words[i + 1] = 1; + } else { + this.words[i + 1]++; } } + this.length = Math.max(this.length, i + 1); - var registrationNameModules = EventPluginRegistry.registrationNameModules; - for (var registrationName in registrationNameModules) { - if (registrationNameModules.hasOwnProperty(registrationName)) { - delete registrationNameModules[registrationName]; - } + return this; + }; + + // Subtract plain number `num` from `this` + BN.prototype.isubn = function isubn (num) { + assert(typeof num === 'number'); + assert(num < 0x4000000); + if (num < 0) return this.iaddn(-num); + + if (this.negative !== 0) { + this.negative = 0; + this.iaddn(num); + this.negative = 1; + return this; } - if (process.env.NODE_ENV !== 'production') { - var possibleRegistrationNames = EventPluginRegistry.possibleRegistrationNames; - for (var lowerCasedName in possibleRegistrationNames) { - if (possibleRegistrationNames.hasOwnProperty(lowerCasedName)) { - delete possibleRegistrationNames[lowerCasedName]; - } + this.words[0] -= num; + + if (this.length === 1 && this.words[0] < 0) { + this.words[0] = -this.words[0]; + this.negative = 1; + } else { + // Carry + for (var i = 0; i < this.length && this.words[i] < 0; i++) { + this.words[i] += 0x4000000; + this.words[i + 1] -= 1; } } - } -}; -module.exports = EventPluginRegistry; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return this.strip(); + }; -/***/ }), -/* 41 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.addn = function addn (num) { + return this.clone().iaddn(num); + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + BN.prototype.subn = function subn (num) { + return this.clone().isubn(num); + }; + BN.prototype.iabs = function iabs () { + this.negative = 0; + return this; + }; -var _prodInvariant = __webpack_require__(3); + BN.prototype.abs = function abs () { + return this.clone().iabs(); + }; -var invariant = __webpack_require__(1); + BN.prototype._ishlnsubmul = function _ishlnsubmul (num, mul, shift) { + var len = num.length + shift; + var i; -var OBSERVED_ERROR = {}; + this._expand(len); -/** - * `Transaction` creates a black box that is able to wrap any method such that - * certain invariants are maintained before and after the method is invoked - * (Even if an exception is thrown while invoking the wrapped method). Whoever - * instantiates a transaction can provide enforcers of the invariants at - * creation time. The `Transaction` class itself will supply one additional - * automatic invariant for you - the invariant that any transaction instance - * should not be run while it is already being run. You would typically create a - * single instance of a `Transaction` for reuse multiple times, that potentially - * is used to wrap several different methods. Wrappers are extremely simple - - * they only require implementing two methods. - * - * <pre> - * wrappers (injected at creation time) - * + + - * | | - * +-----------------|--------|--------------+ - * | v | | - * | +---------------+ | | - * | +--| wrapper1 |---|----+ | - * | | +---------------+ v | | - * | | +-------------+ | | - * | | +----| wrapper2 |--------+ | - * | | | +-------------+ | | | - * | | | | | | - * | v v v v | wrapper - * | +---+ +---+ +---------+ +---+ +---+ | invariants - * perform(anyMethod) | | | | | | | | | | | | maintained - * +----------------->|-|---|-|---|-->|anyMethod|---|---|-|---|-|--------> - * | | | | | | | | | | | | - * | | | | | | | | | | | | - * | | | | | | | | | | | | - * | +---+ +---+ +---------+ +---+ +---+ | - * | initialize close | - * +-----------------------------------------+ - * </pre> - * - * Use cases: - * - Preserving the input selection ranges before/after reconciliation. - * Restoring selection even in the event of an unexpected error. - * - Deactivating events while rearranging the DOM, preventing blurs/focuses, - * while guaranteeing that afterwards, the event system is reactivated. - * - Flushing a queue of collected DOM mutations to the main UI thread after a - * reconciliation takes place in a worker thread. - * - Invoking any collected `componentDidUpdate` callbacks after rendering new - * content. - * - (Future use case): Wrapping particular flushes of the `ReactWorker` queue - * to preserve the `scrollTop` (an automatic scroll aware DOM). - * - (Future use case): Layout calculations before and after DOM updates. - * - * Transactional plugin API: - * - A module that has an `initialize` method that returns any precomputation. - * - and a `close` method that accepts the precomputation. `close` is invoked - * when the wrapped process is completed, or has failed. - * - * @param {Array<TransactionalWrapper>} transactionWrapper Wrapper modules - * that implement `initialize` and `close`. - * @return {Transaction} Single transaction for reuse in thread. - * - * @class Transaction - */ -var TransactionImpl = { - /** - * Sets up this instance so that it is prepared for collecting metrics. Does - * so such that this setup method may be used on an instance that is already - * initialized, in a way that does not consume additional memory upon reuse. - * That can be useful if you decide to make your subclass of this mixin a - * "PooledClass". - */ - reinitializeTransaction: function () { - this.transactionWrappers = this.getTransactionWrappers(); - if (this.wrapperInitData) { - this.wrapperInitData.length = 0; - } else { - this.wrapperInitData = []; + var w; + var carry = 0; + for (i = 0; i < num.length; i++) { + w = (this.words[i + shift] | 0) + carry; + var right = (num.words[i] | 0) * mul; + w -= right & 0x3ffffff; + carry = (w >> 26) - ((right / 0x4000000) | 0); + this.words[i + shift] = w & 0x3ffffff; + } + for (; i < this.length - shift; i++) { + w = (this.words[i + shift] | 0) + carry; + carry = w >> 26; + this.words[i + shift] = w & 0x3ffffff; } - this._isInTransaction = false; - }, - _isInTransaction: false, + if (carry === 0) return this.strip(); - /** - * @abstract - * @return {Array<TransactionWrapper>} Array of transaction wrappers. - */ - getTransactionWrappers: null, + // Subtraction overflow + assert(carry === -1); + carry = 0; + for (i = 0; i < this.length; i++) { + w = -(this.words[i] | 0) + carry; + carry = w >> 26; + this.words[i] = w & 0x3ffffff; + } + this.negative = 1; - isInTransaction: function () { - return !!this._isInTransaction; - }, + return this.strip(); + }; - /* eslint-disable space-before-function-paren */ + BN.prototype._wordDiv = function _wordDiv (num, mode) { + var shift = this.length - num.length; - /** - * Executes the function within a safety window. Use this for the top level - * methods that result in large amounts of computation/mutations that would - * need to be safety checked. The optional arguments helps prevent the need - * to bind in many cases. - * - * @param {function} method Member of scope to call. - * @param {Object} scope Scope to invoke from. - * @param {Object?=} a Argument to pass to the method. - * @param {Object?=} b Argument to pass to the method. - * @param {Object?=} c Argument to pass to the method. - * @param {Object?=} d Argument to pass to the method. - * @param {Object?=} e Argument to pass to the method. - * @param {Object?=} f Argument to pass to the method. - * - * @return {*} Return value from `method`. - */ - perform: function (method, scope, a, b, c, d, e, f) { - /* eslint-enable space-before-function-paren */ - !!this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.perform(...): Cannot initialize a transaction when there is already an outstanding transaction.') : _prodInvariant('27') : void 0; - var errorThrown; - var ret; - try { - this._isInTransaction = true; - // Catching errors makes debugging more difficult, so we start with - // errorThrown set to true before setting it to false after calling - // close -- if it's still set to true in the finally block, it means - // one of these calls threw. - errorThrown = true; - this.initializeAll(0); - ret = method.call(scope, a, b, c, d, e, f); - errorThrown = false; - } finally { - try { - if (errorThrown) { - // If `method` throws, prefer to show that stack trace over any thrown - // by invoking `closeAll`. - try { - this.closeAll(0); - } catch (err) {} - } else { - // Since `method` didn't throw, we don't want to silence the exception - // here. - this.closeAll(0); - } - } finally { - this._isInTransaction = false; + var a = this.clone(); + var b = num; + + // Normalize + var bhi = b.words[b.length - 1] | 0; + var bhiBits = this._countBits(bhi); + shift = 26 - bhiBits; + if (shift !== 0) { + b = b.ushln(shift); + a.iushln(shift); + bhi = b.words[b.length - 1] | 0; + } + + // Initialize quotient + var m = a.length - b.length; + var q; + + if (mode !== 'mod') { + q = new BN(null); + q.length = m + 1; + q.words = new Array(q.length); + for (var i = 0; i < q.length; i++) { + q.words[i] = 0; } } - return ret; - }, - initializeAll: function (startIndex) { - var transactionWrappers = this.transactionWrappers; - for (var i = startIndex; i < transactionWrappers.length; i++) { - var wrapper = transactionWrappers[i]; - try { - // Catching errors makes debugging more difficult, so we start with the - // OBSERVED_ERROR state before overwriting it with the real return value - // of initialize -- if it's still set to OBSERVED_ERROR in the finally - // block, it means wrapper.initialize threw. - this.wrapperInitData[i] = OBSERVED_ERROR; - this.wrapperInitData[i] = wrapper.initialize ? wrapper.initialize.call(this) : null; - } finally { - if (this.wrapperInitData[i] === OBSERVED_ERROR) { - // The initializer for wrapper i threw an error; initialize the - // remaining wrappers but silence any exceptions from them to ensure - // that the first error is the one to bubble up. - try { - this.initializeAll(i + 1); - } catch (err) {} + var diff = a.clone()._ishlnsubmul(b, 1, m); + if (diff.negative === 0) { + a = diff; + if (q) { + q.words[m] = 1; + } + } + + for (var j = m - 1; j >= 0; j--) { + var qj = (a.words[b.length + j] | 0) * 0x4000000 + + (a.words[b.length + j - 1] | 0); + + // NOTE: (qj / bhi) is (0x3ffffff * 0x4000000 + 0x3ffffff) / 0x2000000 max + // (0x7ffffff) + qj = Math.min((qj / bhi) | 0, 0x3ffffff); + + a._ishlnsubmul(b, qj, j); + while (a.negative !== 0) { + qj--; + a.negative = 0; + a._ishlnsubmul(b, 1, j); + if (!a.isZero()) { + a.negative ^= 1; } } + if (q) { + q.words[j] = qj; + } } - }, + if (q) { + q.strip(); + } + a.strip(); - /** - * Invokes each of `this.transactionWrappers.close[i]` functions, passing into - * them the respective return values of `this.transactionWrappers.init[i]` - * (`close`rs that correspond to initializers that failed will not be - * invoked). - */ - closeAll: function (startIndex) { - !this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.closeAll(): Cannot close transaction when none are open.') : _prodInvariant('28') : void 0; - var transactionWrappers = this.transactionWrappers; - for (var i = startIndex; i < transactionWrappers.length; i++) { - var wrapper = transactionWrappers[i]; - var initData = this.wrapperInitData[i]; - var errorThrown; - try { - // Catching errors makes debugging more difficult, so we start with - // errorThrown set to true before setting it to false after calling - // close -- if it's still set to true in the finally block, it means - // wrapper.close threw. - errorThrown = true; - if (initData !== OBSERVED_ERROR && wrapper.close) { - wrapper.close.call(this, initData); + // Denormalize + if (mode !== 'div' && shift !== 0) { + a.iushrn(shift); + } + + return { + div: q || null, + mod: a + }; + }; + + // NOTE: 1) `mode` can be set to `mod` to request mod only, + // to `div` to request div only, or be absent to + // request both div & mod + // 2) `positive` is true if unsigned mod is requested + BN.prototype.divmod = function divmod (num, mode, positive) { + assert(!num.isZero()); + + if (this.isZero()) { + return { + div: new BN(0), + mod: new BN(0) + }; + } + + var div, mod, res; + if (this.negative !== 0 && num.negative === 0) { + res = this.neg().divmod(num, mode); + + if (mode !== 'mod') { + div = res.div.neg(); + } + + if (mode !== 'div') { + mod = res.mod.neg(); + if (positive && mod.negative !== 0) { + mod.iadd(num); } - errorThrown = false; - } finally { - if (errorThrown) { - // The closer for wrapper i threw an error; close the remaining - // wrappers but silence any exceptions from them to ensure that the - // first error is the one to bubble up. - try { - this.closeAll(i + 1); - } catch (e) {} + } + + return { + div: div, + mod: mod + }; + } + + if (this.negative === 0 && num.negative !== 0) { + res = this.divmod(num.neg(), mode); + + if (mode !== 'mod') { + div = res.div.neg(); + } + + return { + div: div, + mod: res.mod + }; + } + + if ((this.negative & num.negative) !== 0) { + res = this.neg().divmod(num.neg(), mode); + + if (mode !== 'div') { + mod = res.mod.neg(); + if (positive && mod.negative !== 0) { + mod.isub(num); } } + + return { + div: res.div, + mod: mod + }; } - this.wrapperInitData.length = 0; - } -}; -module.exports = TransactionImpl; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // Both numbers are positive at this point -/***/ }), -/* 42 */ -/***/ (function(module, exports, __webpack_require__) { + // Strip both numbers to approximate shift value + if (num.length > this.length || this.cmp(num) < 0) { + return { + div: new BN(0), + mod: this + }; + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // Very short reduction + if (num.length === 1) { + if (mode === 'div') { + return { + div: this.divn(num.words[0]), + mod: null + }; + } + if (mode === 'mod') { + return { + div: null, + mod: new BN(this.modn(num.words[0])) + }; + } + return { + div: this.divn(num.words[0]), + mod: new BN(this.modn(num.words[0])) + }; + } -var SyntheticUIEvent = __webpack_require__(33); -var ViewportMetrics = __webpack_require__(89); + return this._wordDiv(num, mode); + }; -var getEventModifierState = __webpack_require__(54); + // Find `this` / `num` + BN.prototype.div = function div (num) { + return this.divmod(num, 'div', false).div; + }; -/** - * @interface MouseEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var MouseEventInterface = { - screenX: null, - screenY: null, - clientX: null, - clientY: null, - ctrlKey: null, - shiftKey: null, - altKey: null, - metaKey: null, - getModifierState: getEventModifierState, - button: function (event) { - // Webkit, Firefox, IE9+ - // which: 1 2 3 - // button: 0 1 2 (standard) - var button = event.button; - if ('which' in event) { - return button; + // Find `this` % `num` + BN.prototype.mod = function mod (num) { + return this.divmod(num, 'mod', false).mod; + }; + + BN.prototype.umod = function umod (num) { + return this.divmod(num, 'mod', true).mod; + }; + + // Find Round(`this` / `num`) + BN.prototype.divRound = function divRound (num) { + var dm = this.divmod(num); + + // Fast case - exact division + if (dm.mod.isZero()) return dm.div; + + var mod = dm.div.negative !== 0 ? dm.mod.isub(num) : dm.mod; + + var half = num.ushrn(1); + var r2 = num.andln(1); + var cmp = mod.cmp(half); + + // Round down + if (cmp < 0 || r2 === 1 && cmp === 0) return dm.div; + + // Round up + return dm.div.negative !== 0 ? dm.div.isubn(1) : dm.div.iaddn(1); + }; + + BN.prototype.modn = function modn (num) { + assert(num <= 0x3ffffff); + var p = (1 << 26) % num; + + var acc = 0; + for (var i = this.length - 1; i >= 0; i--) { + acc = (p * acc + (this.words[i] | 0)) % num; } - // IE<9 - // which: undefined - // button: 0 0 0 - // button: 1 4 2 (onmouseup) - return button === 2 ? 2 : button === 4 ? 1 : 0; - }, - buttons: null, - relatedTarget: function (event) { - return event.relatedTarget || (event.fromElement === event.srcElement ? event.toElement : event.fromElement); - }, - // "Proprietary" Interface. - pageX: function (event) { - return 'pageX' in event ? event.pageX : event.clientX + ViewportMetrics.currentScrollLeft; - }, - pageY: function (event) { - return 'pageY' in event ? event.pageY : event.clientY + ViewportMetrics.currentScrollTop; - } -}; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticMouseEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} + return acc; + }; -SyntheticUIEvent.augmentClass(SyntheticMouseEvent, MouseEventInterface); + // In-place division by number + BN.prototype.idivn = function idivn (num) { + assert(num <= 0x3ffffff); -module.exports = SyntheticMouseEvent; + var carry = 0; + for (var i = this.length - 1; i >= 0; i--) { + var w = (this.words[i] | 0) + carry * 0x4000000; + this.words[i] = (w / num) | 0; + carry = w % num; + } -/***/ }), -/* 43 */ -/***/ (function(module, exports, __webpack_require__) { + return this.strip(); + }; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.divn = function divn (num) { + return this.clone().idivn(num); + }; + BN.prototype.egcd = function egcd (p) { + assert(p.negative === 0); + assert(!p.isZero()); + var x = this; + var y = p.clone(); -var ExecutionEnvironment = __webpack_require__(8); -var DOMNamespaces = __webpack_require__(56); + if (x.negative !== 0) { + x = x.umod(p); + } else { + x = x.clone(); + } -var WHITESPACE_TEST = /^[ \r\n\t\f]/; -var NONVISIBLE_TEST = /<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/; + // A * x + B * y = x + var A = new BN(1); + var B = new BN(0); -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); + // C * x + D * y = y + var C = new BN(0); + var D = new BN(1); -// SVG temp container for IE lacking innerHTML -var reusableSVGContainer; + var g = 0; -/** - * Set the innerHTML property of a node, ensuring that whitespace is preserved - * even in IE8. - * - * @param {DOMElement} node - * @param {string} html - * @internal - */ -var setInnerHTML = createMicrosoftUnsafeLocalFunction(function (node, html) { - // IE does not have innerHTML for SVG nodes, so instead we inject the - // new markup in a temp node and then move the child nodes across into - // the target node - if (node.namespaceURI === DOMNamespaces.svg && !('innerHTML' in node)) { - reusableSVGContainer = reusableSVGContainer || document.createElement('div'); - reusableSVGContainer.innerHTML = '<svg>' + html + '</svg>'; - var svgNode = reusableSVGContainer.firstChild; - while (svgNode.firstChild) { - node.appendChild(svgNode.firstChild); + while (x.isEven() && y.isEven()) { + x.iushrn(1); + y.iushrn(1); + ++g; } - } else { - node.innerHTML = html; - } -}); -if (ExecutionEnvironment.canUseDOM) { - // IE8: When updating a just created node with innerHTML only leading - // whitespace is removed. When updating an existing node with innerHTML - // whitespace in root TextNodes is also collapsed. - // @see quirksmode.org/bugreports/archives/2004/11/innerhtml_and_t.html + var yp = y.clone(); + var xp = x.clone(); - // Feature detection; only IE8 is known to behave improperly like this. - var testElement = document.createElement('div'); - testElement.innerHTML = ' '; - if (testElement.innerHTML === '') { - setInnerHTML = function (node, html) { - // Magic theory: IE8 supposedly differentiates between added and updated - // nodes when processing innerHTML, innerHTML on updated nodes suffers - // from worse whitespace behavior. Re-adding a node like this triggers - // the initial and more favorable whitespace behavior. - // TODO: What to do on a detached node? - if (node.parentNode) { - node.parentNode.replaceChild(node, node); + while (!x.isZero()) { + for (var i = 0, im = 1; (x.words[0] & im) === 0 && i < 26; ++i, im <<= 1); + if (i > 0) { + x.iushrn(i); + while (i-- > 0) { + if (A.isOdd() || B.isOdd()) { + A.iadd(yp); + B.isub(xp); + } + + A.iushrn(1); + B.iushrn(1); + } } - // We also implement a workaround for non-visible tags disappearing into - // thin air on IE8, this only happens if there is no visible text - // in-front of the non-visible tags. Piggyback on the whitespace fix - // and simply check if any non-visible tags appear in the source. - if (WHITESPACE_TEST.test(html) || html[0] === '<' && NONVISIBLE_TEST.test(html)) { - // Recover leading whitespace by temporarily prepending any character. - // \uFEFF has the potential advantage of being zero-width/invisible. - // UglifyJS drops U+FEFF chars when parsing, so use String.fromCharCode - // in hopes that this is preserved even if "\uFEFF" is transformed to - // the actual Unicode character (by Babel, for example). - // https://github.com/mishoo/UglifyJS2/blob/v2.4.20/lib/parse.js#L216 - node.innerHTML = String.fromCharCode(0xfeff) + html; + for (var j = 0, jm = 1; (y.words[0] & jm) === 0 && j < 26; ++j, jm <<= 1); + if (j > 0) { + y.iushrn(j); + while (j-- > 0) { + if (C.isOdd() || D.isOdd()) { + C.iadd(yp); + D.isub(xp); + } - // deleteData leaves an empty `TextNode` which offsets the index of all - // children. Definitely want to avoid this. - var textNode = node.firstChild; - if (textNode.data.length === 1) { - node.removeChild(textNode); - } else { - textNode.deleteData(0, 1); + C.iushrn(1); + D.iushrn(1); } + } + + if (x.cmp(y) >= 0) { + x.isub(y); + A.isub(C); + B.isub(D); } else { - node.innerHTML = html; + y.isub(x); + C.isub(A); + D.isub(B); } + } + + return { + a: C, + b: D, + gcd: y.iushln(g) }; - } - testElement = null; -} + }; -module.exports = setInnerHTML; + // This is reduced incarnation of the binary EEA + // above, designated to invert members of the + // _prime_ fields F(p) at a maximal speed + BN.prototype._invmp = function _invmp (p) { + assert(p.negative === 0); + assert(!p.isZero()); -/***/ }), -/* 44 */ -/***/ (function(module, exports, __webpack_require__) { + var a = this; + var b = p.clone(); -"use strict"; -/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * Based on the escape-html library, which is used under the MIT License below: - * - * Copyright (c) 2012-2013 TJ Holowaychuk - * Copyright (c) 2015 Andreas Lubbe - * Copyright (c) 2015 Tiancheng "Timothy" Gu - * - * Permission is hereby granted, free of charge, to any person obtaining - * a copy of this software and associated documentation files (the - * 'Software'), to deal in the Software without restriction, including - * without limitation the rights to use, copy, modify, merge, publish, - * distribute, sublicense, and/or sell copies of the Software, and to - * permit persons to whom the Software is furnished to do so, subject to - * the following conditions: - * - * The above copyright notice and this permission notice shall be - * included in all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, - * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. - * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY - * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, - * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE - * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - * - */ + if (a.negative !== 0) { + a = a.umod(p); + } else { + a = a.clone(); + } + var x1 = new BN(1); + var x2 = new BN(0); + var delta = b.clone(); -// code copied and modified from escape-html -/** - * Module variables. - * @private - */ + while (a.cmpn(1) > 0 && b.cmpn(1) > 0) { + for (var i = 0, im = 1; (a.words[0] & im) === 0 && i < 26; ++i, im <<= 1); + if (i > 0) { + a.iushrn(i); + while (i-- > 0) { + if (x1.isOdd()) { + x1.iadd(delta); + } -var matchHtmlRegExp = /["'&<>]/; + x1.iushrn(1); + } + } -/** - * Escape special characters in the given string of html. - * - * @param {string} string The string to escape for inserting into HTML - * @return {string} - * @public - */ + for (var j = 0, jm = 1; (b.words[0] & jm) === 0 && j < 26; ++j, jm <<= 1); + if (j > 0) { + b.iushrn(j); + while (j-- > 0) { + if (x2.isOdd()) { + x2.iadd(delta); + } -function escapeHtml(string) { - var str = '' + string; - var match = matchHtmlRegExp.exec(str); + x2.iushrn(1); + } + } - if (!match) { - return str; - } + if (a.cmp(b) >= 0) { + a.isub(b); + x1.isub(x2); + } else { + b.isub(a); + x2.isub(x1); + } + } - var escape; - var html = ''; - var index = 0; - var lastIndex = 0; + var res; + if (a.cmpn(1) === 0) { + res = x1; + } else { + res = x2; + } - for (index = match.index; index < str.length; index++) { - switch (str.charCodeAt(index)) { - case 34: - // " - escape = '"'; - break; - case 38: - // & - escape = '&'; - break; - case 39: - // ' - escape = '''; // modified from escape-html; used to be ''' - break; - case 60: - // < - escape = '<'; - break; - case 62: - // > - escape = '>'; + if (res.cmpn(0) < 0) { + res.iadd(p); + } + + return res; + }; + + BN.prototype.gcd = function gcd (num) { + if (this.isZero()) return num.abs(); + if (num.isZero()) return this.abs(); + + var a = this.clone(); + var b = num.clone(); + a.negative = 0; + b.negative = 0; + + // Remove common factor of two + for (var shift = 0; a.isEven() && b.isEven(); shift++) { + a.iushrn(1); + b.iushrn(1); + } + + do { + while (a.isEven()) { + a.iushrn(1); + } + while (b.isEven()) { + b.iushrn(1); + } + + var r = a.cmp(b); + if (r < 0) { + // Swap `a` and `b` to make `a` always bigger than `b` + var t = a; + a = b; + b = t; + } else if (r === 0 || b.cmpn(1) === 0) { break; - default: - continue; + } + + a.isub(b); + } while (true); + + return b.iushln(shift); + }; + + // Invert number in the field F(num) + BN.prototype.invm = function invm (num) { + return this.egcd(num).a.umod(num); + }; + + BN.prototype.isEven = function isEven () { + return (this.words[0] & 1) === 0; + }; + + BN.prototype.isOdd = function isOdd () { + return (this.words[0] & 1) === 1; + }; + + // And first word and num + BN.prototype.andln = function andln (num) { + return this.words[0] & num; + }; + + // Increment at the bit position in-line + BN.prototype.bincn = function bincn (bit) { + assert(typeof bit === 'number'); + var r = bit % 26; + var s = (bit - r) / 26; + var q = 1 << r; + + // Fast case: bit is much higher than all existing words + if (this.length <= s) { + this._expand(s + 1); + this.words[s] |= q; + return this; + } + + // Add bit and propagate, if needed + var carry = q; + for (var i = s; carry !== 0 && i < this.length; i++) { + var w = this.words[i] | 0; + w += carry; + carry = w >>> 26; + w &= 0x3ffffff; + this.words[i] = w; + } + if (carry !== 0) { + this.words[i] = carry; + this.length++; + } + return this; + }; + + BN.prototype.isZero = function isZero () { + return this.length === 1 && this.words[0] === 0; + }; + + BN.prototype.cmpn = function cmpn (num) { + var negative = num < 0; + + if (this.negative !== 0 && !negative) return -1; + if (this.negative === 0 && negative) return 1; + + this.strip(); + + var res; + if (this.length > 1) { + res = 1; + } else { + if (negative) { + num = -num; + } + + assert(num <= 0x3ffffff, 'Number is too big'); + + var w = this.words[0] | 0; + res = w === num ? 0 : w < num ? -1 : 1; } + if (this.negative !== 0) return -res | 0; + return res; + }; - if (lastIndex !== index) { - html += str.substring(lastIndex, index); + // Compare two numbers and return: + // 1 - if `this` > `num` + // 0 - if `this` == `num` + // -1 - if `this` < `num` + BN.prototype.cmp = function cmp (num) { + if (this.negative !== 0 && num.negative === 0) return -1; + if (this.negative === 0 && num.negative !== 0) return 1; + + var res = this.ucmp(num); + if (this.negative !== 0) return -res | 0; + return res; + }; + + // Unsigned comparison + BN.prototype.ucmp = function ucmp (num) { + // At this point both numbers have the same sign + if (this.length > num.length) return 1; + if (this.length < num.length) return -1; + + var res = 0; + for (var i = this.length - 1; i >= 0; i--) { + var a = this.words[i] | 0; + var b = num.words[i] | 0; + + if (a === b) continue; + if (a < b) { + res = -1; + } else if (a > b) { + res = 1; + } + break; } + return res; + }; - lastIndex = index + 1; - html += escape; - } + BN.prototype.gtn = function gtn (num) { + return this.cmpn(num) === 1; + }; - return lastIndex !== index ? html + str.substring(lastIndex, index) : html; -} -// end code copied and modified from escape-html + BN.prototype.gt = function gt (num) { + return this.cmp(num) === 1; + }; -/** - * Escapes text to prevent scripting attacks. - * - * @param {*} text Text value to escape. - * @return {string} An escaped string. - */ -function escapeTextContentForBrowser(text) { - if (typeof text === 'boolean' || typeof text === 'number') { - // this shortcircuit helps perf for types that we know will never have - // special characters, especially given that this function is used often - // for numeric dom ids. - return '' + text; - } - return escapeHtml(text); -} + BN.prototype.gten = function gten (num) { + return this.cmpn(num) >= 0; + }; -module.exports = escapeTextContentForBrowser; + BN.prototype.gte = function gte (num) { + return this.cmp(num) >= 0; + }; -/***/ }), -/* 45 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.ltn = function ltn (num) { + return this.cmpn(num) === -1; + }; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + BN.prototype.lt = function lt (num) { + return this.cmp(num) === -1; + }; + BN.prototype.lten = function lten (num) { + return this.cmpn(num) <= 0; + }; + BN.prototype.lte = function lte (num) { + return this.cmp(num) <= 0; + }; -var _assign = __webpack_require__(5); + BN.prototype.eqn = function eqn (num) { + return this.cmpn(num) === 0; + }; -var EventPluginRegistry = __webpack_require__(40); -var ReactEventEmitterMixin = __webpack_require__(169); -var ViewportMetrics = __webpack_require__(89); + BN.prototype.eq = function eq (num) { + return this.cmp(num) === 0; + }; -var getVendorPrefixedEventName = __webpack_require__(170); -var isEventSupported = __webpack_require__(53); + // + // A reduce context, could be using montgomery or something better, depending + // on the `m` itself. + // + BN.red = function red (num) { + return new Red(num); + }; -/** - * Summary of `ReactBrowserEventEmitter` event handling: - * - * - Top-level delegation is used to trap most native browser events. This - * may only occur in the main thread and is the responsibility of - * ReactEventListener, which is injected and can therefore support pluggable - * event sources. This is the only work that occurs in the main thread. - * - * - We normalize and de-duplicate events to account for browser quirks. This - * may be done in the worker thread. - * - * - Forward these native events (with the associated top-level type used to - * trap it) to `EventPluginHub`, which in turn will ask plugins if they want - * to extract any synthetic events. - * - * - The `EventPluginHub` will then process each event by annotating them with - * "dispatches", a sequence of listeners and IDs that care about that event. - * - * - The `EventPluginHub` then dispatches the events. - * - * Overview of React and the event system: - * - * +------------+ . - * | DOM | . - * +------------+ . - * | . - * v . - * +------------+ . - * | ReactEvent | . - * | Listener | . - * +------------+ . +-----------+ - * | . +--------+|SimpleEvent| - * | . | |Plugin | - * +-----|------+ . v +-----------+ - * | | | . +--------------+ +------------+ - * | +-----------.--->|EventPluginHub| | Event | - * | | . | | +-----------+ | Propagators| - * | ReactEvent | . | | |TapEvent | |------------| - * | Emitter | . | |<---+|Plugin | |other plugin| - * | | . | | +-----------+ | utilities | - * | +-----------.--->| | +------------+ - * | | | . +--------------+ - * +-----|------+ . ^ +-----------+ - * | . | |Enter/Leave| - * + . +-------+|Plugin | - * +-------------+ . +-----------+ - * | application | . - * |-------------| . - * | | . - * | | . - * +-------------+ . - * . - * React Core . General Purpose Event Plugin System - */ + BN.prototype.toRed = function toRed (ctx) { + assert(!this.red, 'Already a number in reduction context'); + assert(this.negative === 0, 'red works only with positives'); + return ctx.convertTo(this)._forceRed(ctx); + }; -var hasEventPageXY; -var alreadyListeningTo = {}; -var isMonitoringScrollValue = false; -var reactTopListenersCounter = 0; + BN.prototype.fromRed = function fromRed () { + assert(this.red, 'fromRed works only with numbers in reduction context'); + return this.red.convertFrom(this); + }; -// For events like 'submit' which don't consistently bubble (which we trap at a -// lower node than `document`), binding at `document` would cause duplicate -// events so we don't include them here -var topEventMapping = { - topAbort: 'abort', - topAnimationEnd: getVendorPrefixedEventName('animationend') || 'animationend', - topAnimationIteration: getVendorPrefixedEventName('animationiteration') || 'animationiteration', - topAnimationStart: getVendorPrefixedEventName('animationstart') || 'animationstart', - topBlur: 'blur', - topCanPlay: 'canplay', - topCanPlayThrough: 'canplaythrough', - topChange: 'change', - topClick: 'click', - topCompositionEnd: 'compositionend', - topCompositionStart: 'compositionstart', - topCompositionUpdate: 'compositionupdate', - topContextMenu: 'contextmenu', - topCopy: 'copy', - topCut: 'cut', - topDoubleClick: 'dblclick', - topDrag: 'drag', - topDragEnd: 'dragend', - topDragEnter: 'dragenter', - topDragExit: 'dragexit', - topDragLeave: 'dragleave', - topDragOver: 'dragover', - topDragStart: 'dragstart', - topDrop: 'drop', - topDurationChange: 'durationchange', - topEmptied: 'emptied', - topEncrypted: 'encrypted', - topEnded: 'ended', - topError: 'error', - topFocus: 'focus', - topInput: 'input', - topKeyDown: 'keydown', - topKeyPress: 'keypress', - topKeyUp: 'keyup', - topLoadedData: 'loadeddata', - topLoadedMetadata: 'loadedmetadata', - topLoadStart: 'loadstart', - topMouseDown: 'mousedown', - topMouseMove: 'mousemove', - topMouseOut: 'mouseout', - topMouseOver: 'mouseover', - topMouseUp: 'mouseup', - topPaste: 'paste', - topPause: 'pause', - topPlay: 'play', - topPlaying: 'playing', - topProgress: 'progress', - topRateChange: 'ratechange', - topScroll: 'scroll', - topSeeked: 'seeked', - topSeeking: 'seeking', - topSelectionChange: 'selectionchange', - topStalled: 'stalled', - topSuspend: 'suspend', - topTextInput: 'textInput', - topTimeUpdate: 'timeupdate', - topTouchCancel: 'touchcancel', - topTouchEnd: 'touchend', - topTouchMove: 'touchmove', - topTouchStart: 'touchstart', - topTransitionEnd: getVendorPrefixedEventName('transitionend') || 'transitionend', - topVolumeChange: 'volumechange', - topWaiting: 'waiting', - topWheel: 'wheel' -}; + BN.prototype._forceRed = function _forceRed (ctx) { + this.red = ctx; + return this; + }; -/** - * To ensure no conflicts with other potential React instances on the page - */ -var topListenersIDKey = '_reactListenersID' + String(Math.random()).slice(2); + BN.prototype.forceRed = function forceRed (ctx) { + assert(!this.red, 'Already a number in reduction context'); + return this._forceRed(ctx); + }; -function getListeningForDocument(mountAt) { - // In IE8, `mountAt` is a host object and doesn't have `hasOwnProperty` - // directly. - if (!Object.prototype.hasOwnProperty.call(mountAt, topListenersIDKey)) { - mountAt[topListenersIDKey] = reactTopListenersCounter++; - alreadyListeningTo[mountAt[topListenersIDKey]] = {}; + BN.prototype.redAdd = function redAdd (num) { + assert(this.red, 'redAdd works only with red numbers'); + return this.red.add(this, num); + }; + + BN.prototype.redIAdd = function redIAdd (num) { + assert(this.red, 'redIAdd works only with red numbers'); + return this.red.iadd(this, num); + }; + + BN.prototype.redSub = function redSub (num) { + assert(this.red, 'redSub works only with red numbers'); + return this.red.sub(this, num); + }; + + BN.prototype.redISub = function redISub (num) { + assert(this.red, 'redISub works only with red numbers'); + return this.red.isub(this, num); + }; + + BN.prototype.redShl = function redShl (num) { + assert(this.red, 'redShl works only with red numbers'); + return this.red.shl(this, num); + }; + + BN.prototype.redMul = function redMul (num) { + assert(this.red, 'redMul works only with red numbers'); + this.red._verify2(this, num); + return this.red.mul(this, num); + }; + + BN.prototype.redIMul = function redIMul (num) { + assert(this.red, 'redMul works only with red numbers'); + this.red._verify2(this, num); + return this.red.imul(this, num); + }; + + BN.prototype.redSqr = function redSqr () { + assert(this.red, 'redSqr works only with red numbers'); + this.red._verify1(this); + return this.red.sqr(this); + }; + + BN.prototype.redISqr = function redISqr () { + assert(this.red, 'redISqr works only with red numbers'); + this.red._verify1(this); + return this.red.isqr(this); + }; + + // Square root over p + BN.prototype.redSqrt = function redSqrt () { + assert(this.red, 'redSqrt works only with red numbers'); + this.red._verify1(this); + return this.red.sqrt(this); + }; + + BN.prototype.redInvm = function redInvm () { + assert(this.red, 'redInvm works only with red numbers'); + this.red._verify1(this); + return this.red.invm(this); + }; + + // Return negative clone of `this` % `red modulo` + BN.prototype.redNeg = function redNeg () { + assert(this.red, 'redNeg works only with red numbers'); + this.red._verify1(this); + return this.red.neg(this); + }; + + BN.prototype.redPow = function redPow (num) { + assert(this.red && !num.red, 'redPow(normalNum)'); + this.red._verify1(this); + return this.red.pow(this, num); + }; + + // Prime numbers with efficient reduction + var primes = { + k256: null, + p224: null, + p192: null, + p25519: null + }; + + // Pseudo-Mersenne prime + function MPrime (name, p) { + // P = 2 ^ N - K + this.name = name; + this.p = new BN(p, 16); + this.n = this.p.bitLength(); + this.k = new BN(1).iushln(this.n).isub(this.p); + + this.tmp = this._tmp(); } - return alreadyListeningTo[mountAt[topListenersIDKey]]; -} -/** - * `ReactBrowserEventEmitter` is used to attach top-level event listeners. For - * example: - * - * EventPluginHub.putListener('myID', 'onClick', myFunction); - * - * This would allocate a "registration" of `('onClick', myFunction)` on 'myID'. - * - * @internal - */ -var ReactBrowserEventEmitter = _assign({}, ReactEventEmitterMixin, { - /** - * Injectable event backend - */ - ReactEventListener: null, + MPrime.prototype._tmp = function _tmp () { + var tmp = new BN(null); + tmp.words = new Array(Math.ceil(this.n / 13)); + return tmp; + }; - injection: { - /** - * @param {object} ReactEventListener - */ - injectReactEventListener: function (ReactEventListener) { - ReactEventListener.setHandleTopLevel(ReactBrowserEventEmitter.handleTopLevel); - ReactBrowserEventEmitter.ReactEventListener = ReactEventListener; - } - }, + MPrime.prototype.ireduce = function ireduce (num) { + // Assumes that `num` is less than `P^2` + // num = HI * (2 ^ N - K) + HI * K + LO = HI * K + LO (mod P) + var r = num; + var rlen; - /** - * Sets whether or not any created callbacks should be enabled. - * - * @param {boolean} enabled True if callbacks should be enabled. - */ - setEnabled: function (enabled) { - if (ReactBrowserEventEmitter.ReactEventListener) { - ReactBrowserEventEmitter.ReactEventListener.setEnabled(enabled); + do { + this.split(r, this.tmp); + r = this.imulK(r); + r = r.iadd(this.tmp); + rlen = r.bitLength(); + } while (rlen > this.n); + + var cmp = rlen < this.n ? -1 : r.ucmp(this.p); + if (cmp === 0) { + r.words[0] = 0; + r.length = 1; + } else if (cmp > 0) { + r.isub(this.p); + } else { + r.strip(); } - }, - /** - * @return {boolean} True if callbacks are enabled. - */ - isEnabled: function () { - return !!(ReactBrowserEventEmitter.ReactEventListener && ReactBrowserEventEmitter.ReactEventListener.isEnabled()); - }, + return r; + }; - /** - * We listen for bubbled touch events on the document object. - * - * Firefox v8.01 (and possibly others) exhibited strange behavior when - * mounting `onmousemove` events at some node that was not the document - * element. The symptoms were that if your mouse is not moving over something - * contained within that mount point (for example on the background) the - * top-level listeners for `onmousemove` won't be called. However, if you - * register the `mousemove` on the document object, then it will of course - * catch all `mousemove`s. This along with iOS quirks, justifies restricting - * top-level listeners to the document object only, at least for these - * movement types of events and possibly all events. - * - * @see http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html - * - * Also, `keyup`/`keypress`/`keydown` do not bubble to the window on IE, but - * they bubble to document. - * - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @param {object} contentDocumentHandle Document which owns the container - */ - listenTo: function (registrationName, contentDocumentHandle) { - var mountAt = contentDocumentHandle; - var isListening = getListeningForDocument(mountAt); - var dependencies = EventPluginRegistry.registrationNameDependencies[registrationName]; + MPrime.prototype.split = function split (input, out) { + input.iushrn(this.n, 0, out); + }; - for (var i = 0; i < dependencies.length; i++) { - var dependency = dependencies[i]; - if (!(isListening.hasOwnProperty(dependency) && isListening[dependency])) { - if (dependency === 'topWheel') { - if (isEventSupported('wheel')) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'wheel', mountAt); - } else if (isEventSupported('mousewheel')) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'mousewheel', mountAt); - } else { - // Firefox needs to capture a different mouse scroll event. - // @see http://www.quirksmode.org/dom/events/tests/scroll.html - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'DOMMouseScroll', mountAt); - } - } else if (dependency === 'topScroll') { - if (isEventSupported('scroll', true)) { - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topScroll', 'scroll', mountAt); - } else { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topScroll', 'scroll', ReactBrowserEventEmitter.ReactEventListener.WINDOW_HANDLE); - } - } else if (dependency === 'topFocus' || dependency === 'topBlur') { - if (isEventSupported('focus', true)) { - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topFocus', 'focus', mountAt); - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topBlur', 'blur', mountAt); - } else if (isEventSupported('focusin')) { - // IE has `focusin` and `focusout` events which bubble. - // @see http://www.quirksmode.org/blog/archives/2008/04/delegating_the.html - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topFocus', 'focusin', mountAt); - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topBlur', 'focusout', mountAt); - } + MPrime.prototype.imulK = function imulK (num) { + return num.imul(this.k); + }; - // to make sure blur and focus event listeners are only attached once - isListening.topBlur = true; - isListening.topFocus = true; - } else if (topEventMapping.hasOwnProperty(dependency)) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(dependency, topEventMapping[dependency], mountAt); - } + function K256 () { + MPrime.call( + this, + 'k256', + 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f'); + } + inherits(K256, MPrime); - isListening[dependency] = true; + K256.prototype.split = function split (input, output) { + // 256 = 9 * 26 + 22 + var mask = 0x3fffff; + + var outLen = Math.min(input.length, 9); + for (var i = 0; i < outLen; i++) { + output.words[i] = input.words[i]; + } + output.length = outLen; + + if (input.length <= 9) { + input.words[0] = 0; + input.length = 1; + return; + } + + // Shift by 9 limbs + var prev = input.words[9]; + output.words[output.length++] = prev & mask; + + for (i = 10; i < input.length; i++) { + var next = input.words[i] | 0; + input.words[i - 10] = ((next & mask) << 4) | (prev >>> 22); + prev = next; + } + prev >>>= 22; + input.words[i - 10] = prev; + if (prev === 0 && input.length > 10) { + input.length -= 10; + } else { + input.length -= 9; + } + }; + + K256.prototype.imulK = function imulK (num) { + // K = 0x1000003d1 = [ 0x40, 0x3d1 ] + num.words[num.length] = 0; + num.words[num.length + 1] = 0; + num.length += 2; + + // bounded at: 0x40 * 0x3ffffff + 0x3d0 = 0x100000390 + var lo = 0; + for (var i = 0; i < num.length; i++) { + var w = num.words[i] | 0; + lo += w * 0x3d1; + num.words[i] = lo & 0x3ffffff; + lo = w * 0x40 + ((lo / 0x4000000) | 0); + } + + // Fast length reduction + if (num.words[num.length - 1] === 0) { + num.length--; + if (num.words[num.length - 1] === 0) { + num.length--; } } - }, + return num; + }; - trapBubbledEvent: function (topLevelType, handlerBaseName, handle) { - return ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(topLevelType, handlerBaseName, handle); - }, + function P224 () { + MPrime.call( + this, + 'p224', + 'ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001'); + } + inherits(P224, MPrime); - trapCapturedEvent: function (topLevelType, handlerBaseName, handle) { - return ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent(topLevelType, handlerBaseName, handle); - }, + function P192 () { + MPrime.call( + this, + 'p192', + 'ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff'); + } + inherits(P192, MPrime); - /** - * Protect against document.createEvent() returning null - * Some popup blocker extensions appear to do this: - * https://github.com/facebook/react/issues/6887 - */ - supportsEventPageXY: function () { - if (!document.createEvent) { - return false; + function P25519 () { + // 2 ^ 255 - 19 + MPrime.call( + this, + '25519', + '7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed'); + } + inherits(P25519, MPrime); + + P25519.prototype.imulK = function imulK (num) { + // K = 0x13 + var carry = 0; + for (var i = 0; i < num.length; i++) { + var hi = (num.words[i] | 0) * 0x13 + carry; + var lo = hi & 0x3ffffff; + hi >>>= 26; + + num.words[i] = lo; + carry = hi; } - var ev = document.createEvent('MouseEvent'); - return ev != null && 'pageX' in ev; - }, + if (carry !== 0) { + num.words[num.length++] = carry; + } + return num; + }; - /** - * Listens to window scroll and resize events. We cache scroll values so that - * application code can access them without triggering reflows. - * - * ViewportMetrics is only used by SyntheticMouse/TouchEvent and only when - * pageX/pageY isn't supported (legacy browsers). - * - * NOTE: Scroll events do not bubble. - * - * @see http://www.quirksmode.org/dom/events/scroll.html - */ - ensureScrollValueMonitoring: function () { - if (hasEventPageXY === undefined) { - hasEventPageXY = ReactBrowserEventEmitter.supportsEventPageXY(); + // Exported mostly for testing purposes, use plain name instead + BN._prime = function prime (name) { + // Cached version of prime + if (primes[name]) return primes[name]; + + var prime; + if (name === 'k256') { + prime = new K256(); + } else if (name === 'p224') { + prime = new P224(); + } else if (name === 'p192') { + prime = new P192(); + } else if (name === 'p25519') { + prime = new P25519(); + } else { + throw new Error('Unknown prime ' + name); } - if (!hasEventPageXY && !isMonitoringScrollValue) { - var refresh = ViewportMetrics.refreshScrollValues; - ReactBrowserEventEmitter.ReactEventListener.monitorScrollValue(refresh); - isMonitoringScrollValue = true; + primes[name] = prime; + + return prime; + }; + + // + // Base reduction engine + // + function Red (m) { + if (typeof m === 'string') { + var prime = BN._prime(m); + this.m = prime.p; + this.prime = prime; + } else { + assert(m.gtn(1), 'modulus must be greater than 1'); + this.m = m; + this.prime = null; } } -}); -module.exports = ReactBrowserEventEmitter; + Red.prototype._verify1 = function _verify1 (a) { + assert(a.negative === 0, 'red works only with positives'); + assert(a.red, 'red works only with red numbers'); + }; -/***/ }), -/* 46 */, -/* 47 */, -/* 48 */ -/***/ (function(module, exports, __webpack_require__) { + Red.prototype._verify2 = function _verify2 (a, b) { + assert((a.negative | b.negative) === 0, 'red works only with positives'); + assert(a.red && a.red === b.red, + 'red works only with red numbers'); + }; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + Red.prototype.imod = function imod (a) { + if (this.prime) return this.prime.ireduce(a)._forceRed(this); + return a.umod(this.m)._forceRed(this); + }; + Red.prototype.neg = function neg (a) { + if (a.isZero()) { + return a.clone(); + } + return this.m.sub(a)._forceRed(this); + }; -/** - * Forked from fbjs/warning: - * https://github.com/facebook/fbjs/blob/e66ba20ad5be433eb54423f2b097d829324d9de6/packages/fbjs/src/__forks__/warning.js - * - * Only change is we use console.warn instead of console.error, - * and do nothing when 'console' is not supported. - * This really simplifies the code. - * --- - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ + Red.prototype.add = function add (a, b) { + this._verify2(a, b); -var lowPriorityWarning = function () {}; + var res = a.add(b); + if (res.cmp(this.m) >= 0) { + res.isub(this.m); + } + return res._forceRed(this); + }; -if (process.env.NODE_ENV !== 'production') { - var printWarning = function (format) { - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; + Red.prototype.iadd = function iadd (a, b) { + this._verify2(a, b); + + var res = a.iadd(b); + if (res.cmp(this.m) >= 0) { + res.isub(this.m); } + return res; + }; - var argIndex = 0; - var message = 'Warning: ' + format.replace(/%s/g, function () { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.warn(message); + Red.prototype.sub = function sub (a, b) { + this._verify2(a, b); + + var res = a.sub(b); + if (res.cmpn(0) < 0) { + res.iadd(this.m); } - try { - // --- Welcome to debugging React --- - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch (x) {} + return res._forceRed(this); }; - lowPriorityWarning = function (condition, format) { - if (format === undefined) { - throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + Red.prototype.isub = function isub (a, b) { + this._verify2(a, b); + + var res = a.isub(b); + if (res.cmpn(0) < 0) { + res.iadd(this.m); } - if (!condition) { - for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { - args[_key2 - 2] = arguments[_key2]; + return res; + }; + + Red.prototype.shl = function shl (a, num) { + this._verify1(a); + return this.imod(a.ushln(num)); + }; + + Red.prototype.imul = function imul (a, b) { + this._verify2(a, b); + return this.imod(a.imul(b)); + }; + + Red.prototype.mul = function mul (a, b) { + this._verify2(a, b); + return this.imod(a.mul(b)); + }; + + Red.prototype.isqr = function isqr (a) { + return this.imul(a, a.clone()); + }; + + Red.prototype.sqr = function sqr (a) { + return this.mul(a, a); + }; + + Red.prototype.sqrt = function sqrt (a) { + if (a.isZero()) return a.clone(); + + var mod3 = this.m.andln(3); + assert(mod3 % 2 === 1); + + // Fast case + if (mod3 === 3) { + var pow = this.m.add(new BN(1)).iushrn(2); + return this.pow(a, pow); + } + + // Tonelli-Shanks algorithm (Totally unoptimized and slow) + // + // Find Q and S, that Q * 2 ^ S = (P - 1) + var q = this.m.subn(1); + var s = 0; + while (!q.isZero() && q.andln(1) === 0) { + s++; + q.iushrn(1); + } + assert(!q.isZero()); + + var one = new BN(1).toRed(this); + var nOne = one.redNeg(); + + // Find quadratic non-residue + // NOTE: Max is such because of generalized Riemann hypothesis. + var lpow = this.m.subn(1).iushrn(1); + var z = this.m.bitLength(); + z = new BN(2 * z * z).toRed(this); + + while (this.pow(z, lpow).cmp(nOne) !== 0) { + z.redIAdd(nOne); + } + + var c = this.pow(z, q); + var r = this.pow(a, q.addn(1).iushrn(1)); + var t = this.pow(a, q); + var m = s; + while (t.cmp(one) !== 0) { + var tmp = t; + for (var i = 0; tmp.cmp(one) !== 0; i++) { + tmp = tmp.redSqr(); } + assert(i < m); + var b = this.pow(c, new BN(1).iushln(m - i - 1)); - printWarning.apply(undefined, [format].concat(args)); + r = r.redMul(b); + c = b.redSqr(); + t = t.redMul(c); + m = i; } + + return r; }; -} -module.exports = lowPriorityWarning; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + Red.prototype.invm = function invm (a) { + var inv = a._invmp(this.m); + if (inv.negative !== 0) { + inv.negative = 0; + return this.imod(inv).redNeg(); + } else { + return this.imod(inv); + } + }; + + Red.prototype.pow = function pow (a, num) { + if (num.isZero()) return new BN(1).toRed(this); + if (num.cmpn(1) === 0) return a.clone(); + + var windowSize = 4; + var wnd = new Array(1 << windowSize); + wnd[0] = new BN(1).toRed(this); + wnd[1] = a; + for (var i = 2; i < wnd.length; i++) { + wnd[i] = this.mul(wnd[i - 1], a); + } + + var res = wnd[0]; + var current = 0; + var currentLen = 0; + var start = num.bitLength() % 26; + if (start === 0) { + start = 26; + } + + for (i = num.length - 1; i >= 0; i--) { + var word = num.words[i]; + for (var j = start - 1; j >= 0; j--) { + var bit = (word >> j) & 1; + if (res !== wnd[0]) { + res = this.sqr(res); + } + + if (bit === 0 && current === 0) { + currentLen = 0; + continue; + } + + current <<= 1; + current |= bit; + currentLen++; + if (currentLen !== windowSize && (i !== 0 || j !== 0)) continue; + + res = this.mul(res, wnd[current]); + currentLen = 0; + current = 0; + } + start = 26; + } + + return res; + }; + + Red.prototype.convertTo = function convertTo (num) { + var r = num.umod(this.m); + + return r === num ? r.clone() : r; + }; + + Red.prototype.convertFrom = function convertFrom (num) { + var res = num.clone(); + res.red = null; + return res; + }; + + // + // Montgomery method engine + // + + BN.mont = function mont (num) { + return new Mont(num); + }; + + function Mont (m) { + Red.call(this, m); + + this.shift = this.m.bitLength(); + if (this.shift % 26 !== 0) { + this.shift += 26 - (this.shift % 26); + } + + this.r = new BN(1).iushln(this.shift); + this.r2 = this.imod(this.r.sqr()); + this.rinv = this.r._invmp(this.m); + + this.minv = this.rinv.mul(this.r).isubn(1).div(this.m); + this.minv = this.minv.umod(this.r); + this.minv = this.r.sub(this.minv); + } + inherits(Mont, Red); + + Mont.prototype.convertTo = function convertTo (num) { + return this.imod(num.ushln(this.shift)); + }; + + Mont.prototype.convertFrom = function convertFrom (num) { + var r = this.imod(num.mul(this.rinv)); + r.red = null; + return r; + }; + + Mont.prototype.imul = function imul (a, b) { + if (a.isZero() || b.isZero()) { + a.words[0] = 0; + a.length = 1; + return a; + } + + var t = a.imul(b); + var c = t.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m); + var u = t.isub(c).iushrn(this.shift); + var res = u; + + if (u.cmp(this.m) >= 0) { + res = u.isub(this.m); + } else if (u.cmpn(0) < 0) { + res = u.iadd(this.m); + } + + return res._forceRed(this); + }; + + Mont.prototype.mul = function mul (a, b) { + if (a.isZero() || b.isZero()) return new BN(0)._forceRed(this); + + var t = a.mul(b); + var c = t.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m); + var u = t.isub(c).iushrn(this.shift); + var res = u; + if (u.cmp(this.m) >= 0) { + res = u.isub(this.m); + } else if (u.cmpn(0) < 0) { + res = u.iadd(this.m); + } + + return res._forceRed(this); + }; + + Mont.prototype.invm = function invm (a) { + // (AR)^-1 * R^2 = (A^-1 * R^-1) * R^2 = A^-1 * R + var res = this.imod(a._invmp(this.m).mul(this.r2)); + return res._forceRed(this); + }; +})(typeof module === 'undefined' || module, this); + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(384)(module))) /***/ }), -/* 49 */ +/* 12 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +var typeforce = __webpack_require__(9) +var UINT31_MAX = Math.pow(2, 31) - 1 +function UInt31 (value) { + return typeforce.UInt32(value) && value <= UINT31_MAX +} +function BIP32Path (value) { + return typeforce.String(value) && value.match(/^(m\/)?(\d+'?\/)*\d+'?$/) +} +BIP32Path.toJSON = function () { return 'BIP32 derivation path' } -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; +var SATOSHI_MAX = 21 * 1e14 +function Satoshi (value) { + return typeforce.UInt53(value) && value <= SATOSHI_MAX +} -module.exports = ReactPropTypesSecret; +// external dependent types +var BigInt = typeforce.quacksLike('BigInteger') +var ECPoint = typeforce.quacksLike('Point') + +// exposed, external API +var ECSignature = typeforce.compile({ r: BigInt, s: BigInt }) +var Network = typeforce.compile({ + messagePrefix: typeforce.oneOf(typeforce.Buffer, typeforce.String), + bip32: { + public: typeforce.UInt32, + private: typeforce.UInt32 + }, + pubKeyHash: typeforce.UInt8, + scriptHash: typeforce.UInt8, + wif: typeforce.UInt8 +}) + +// extend typeforce types with ours +var types = { + BigInt: BigInt, + BIP32Path: BIP32Path, + Buffer256bit: typeforce.BufferN(32), + ECPoint: ECPoint, + ECSignature: ECSignature, + Hash160bit: typeforce.BufferN(20), + Hash256bit: typeforce.BufferN(32), + Network: Network, + Satoshi: Satoshi, + UInt31: UInt31 +} + +for (var typeName in typeforce) { + types[typeName] = typeforce[typeName] +} + +module.exports = types /***/ }), -/* 50 */ +/* 13 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. +/** + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -4905,1019 +6384,1177 @@ module.exports = ReactPropTypesSecret; -var _prodInvariant = __webpack_require__(3); - -var ReactErrorUtils = __webpack_require__(51); - -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); /** - * Injected dependencies: + * Simple, lightweight module assisting with the detection and context of + * Worker. Helps avoid circular dependencies and allows code to reason about + * whether or not they are in a Worker, even if they never include the main + * `ReactWorker` dependency. */ +var ExecutionEnvironment = { + + canUseDOM: canUseDOM, + + canUseWorkers: typeof Worker !== 'undefined', + + canUseEventListeners: canUseDOM && !!(window.addEventListener || window.attachEvent), + + canUseViewport: canUseDOM && !!window.screen, + + isInWorker: !canUseDOM // For now, this is true - might change in the future. -/** - * - `ComponentTree`: [required] Module that can convert between React instances - * and actual node references. - */ -var ComponentTree; -var TreeTraversal; -var injection = { - injectComponentTree: function (Injected) { - ComponentTree = Injected; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.getNodeFromInstance && Injected.getInstanceFromNode, 'EventPluginUtils.injection.injectComponentTree(...): Injected ' + 'module is missing getNodeFromInstance or getInstanceFromNode.') : void 0; - } - }, - injectTreeTraversal: function (Injected) { - TreeTraversal = Injected; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.isAncestor && Injected.getLowestCommonAncestor, 'EventPluginUtils.injection.injectTreeTraversal(...): Injected ' + 'module is missing isAncestor or getLowestCommonAncestor.') : void 0; - } - } }; -function isEndish(topLevelType) { - return topLevelType === 'topMouseUp' || topLevelType === 'topTouchEnd' || topLevelType === 'topTouchCancel'; +module.exports = ExecutionEnvironment; + +/***/ }), +/* 14 */ +/***/ (function(module, exports, __webpack_require__) { + +var Buffer = __webpack_require__(7).Buffer +var bip66 = __webpack_require__(104) +var pushdata = __webpack_require__(202) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var scriptNumber = __webpack_require__(203) + +var OPS = __webpack_require__(16) +var REVERSE_OPS = __webpack_require__(468) +var OP_INT_BASE = OPS.OP_RESERVED // OP_1 - 1 + +function isOPInt (value) { + return types.Number(value) && + ((value === OPS.OP_0) || + (value >= OPS.OP_1 && value <= OPS.OP_16) || + (value === OPS.OP_1NEGATE)) } -function isMoveish(topLevelType) { - return topLevelType === 'topMouseMove' || topLevelType === 'topTouchMove'; +function isPushOnlyChunk (value) { + return types.Buffer(value) || isOPInt(value) } -function isStartish(topLevelType) { - return topLevelType === 'topMouseDown' || topLevelType === 'topTouchStart'; + +function isPushOnly (value) { + return types.Array(value) && value.every(isPushOnlyChunk) } -var validateEventDispatches; -if (process.env.NODE_ENV !== 'production') { - validateEventDispatches = function (event) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; +function compile (chunks) { + // TODO: remove me + if (Buffer.isBuffer(chunks)) return chunks - var listenersIsArr = Array.isArray(dispatchListeners); - var listenersLen = listenersIsArr ? dispatchListeners.length : dispatchListeners ? 1 : 0; + typeforce(types.Array, chunks) - var instancesIsArr = Array.isArray(dispatchInstances); - var instancesLen = instancesIsArr ? dispatchInstances.length : dispatchInstances ? 1 : 0; + var bufferSize = chunks.reduce(function (accum, chunk) { + // data chunk + if (Buffer.isBuffer(chunk)) { + // adhere to BIP62.3, minimal push policy + if (chunk.length === 1 && (chunk[0] === 0x81 || (chunk[0] >= 1 && chunk[0] <= 16))) { + return accum + 1 + } - process.env.NODE_ENV !== 'production' ? warning(instancesIsArr === listenersIsArr && instancesLen === listenersLen, 'EventPluginUtils: Invalid `event`.') : void 0; - }; -} + return accum + pushdata.encodingLength(chunk.length) + chunk.length + } -/** - * Dispatch the event to the listener. - * @param {SyntheticEvent} event SyntheticEvent to handle - * @param {boolean} simulated If the event is simulated (changes exn behavior) - * @param {function} listener Application-level callback - * @param {*} inst Internal component instance - */ -function executeDispatch(event, simulated, listener, inst) { - var type = event.type || 'unknown-event'; - event.currentTarget = EventPluginUtils.getNodeFromInstance(inst); - if (simulated) { - ReactErrorUtils.invokeGuardedCallbackWithCatch(type, listener, event); - } else { - ReactErrorUtils.invokeGuardedCallback(type, listener, event); - } - event.currentTarget = null; -} + // opcode + return accum + 1 + }, 0.0) -/** - * Standard/simple iteration through an event's collected dispatches. - */ -function executeDispatchesInOrder(event, simulated) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; - if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - if (Array.isArray(dispatchListeners)) { - for (var i = 0; i < dispatchListeners.length; i++) { - if (event.isPropagationStopped()) { - break; - } - // Listeners and Instances are two parallel arrays that are always in sync. - executeDispatch(event, simulated, dispatchListeners[i], dispatchInstances[i]); - } - } else if (dispatchListeners) { - executeDispatch(event, simulated, dispatchListeners, dispatchInstances); - } - event._dispatchListeners = null; - event._dispatchInstances = null; -} + var buffer = Buffer.allocUnsafe(bufferSize) + var offset = 0 -/** - * Standard/simple iteration through an event's collected dispatches, but stops - * at the first dispatch execution returning true, and returns that id. - * - * @return {?string} id of the first dispatch execution who's listener returns - * true, or null if no listener returned true. - */ -function executeDispatchesInOrderStopAtTrueImpl(event) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; - if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - if (Array.isArray(dispatchListeners)) { - for (var i = 0; i < dispatchListeners.length; i++) { - if (event.isPropagationStopped()) { - break; + chunks.forEach(function (chunk) { + // data chunk + if (Buffer.isBuffer(chunk)) { + // adhere to BIP62.3, minimal push policy + if (chunk.length === 1 && chunk[0] >= 1 && chunk[0] <= 16) { + var opcode = OP_INT_BASE + chunk[0] + buffer.writeUInt8(opcode, offset) + offset += 1 + return } - // Listeners and Instances are two parallel arrays that are always in sync. - if (dispatchListeners[i](event, dispatchInstances[i])) { - return dispatchInstances[i]; + + if (chunk.length === 1 && chunk[0] === 0x81) { + buffer.writeUInt8(OPS.OP_1NEGATE, offset) + offset += 1 + return } - } - } else if (dispatchListeners) { - if (dispatchListeners(event, dispatchInstances)) { - return dispatchInstances; - } - } - return null; -} -/** - * @see executeDispatchesInOrderStopAtTrueImpl - */ -function executeDispatchesInOrderStopAtTrue(event) { - var ret = executeDispatchesInOrderStopAtTrueImpl(event); - event._dispatchInstances = null; - event._dispatchListeners = null; - return ret; -} + offset += pushdata.encode(buffer, chunk.length, offset) -/** - * Execution of a "direct" dispatch - there must be at most one dispatch - * accumulated on the event or it is considered an error. It doesn't really make - * sense for an event with multiple dispatches (bubbled) to keep track of the - * return values at each dispatch execution, but it does tend to make sense when - * dealing with "direct" dispatches. - * - * @return {*} The return value of executing the single dispatch. - */ -function executeDirectDispatch(event) { - if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - var dispatchListener = event._dispatchListeners; - var dispatchInstance = event._dispatchInstances; - !!Array.isArray(dispatchListener) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'executeDirectDispatch(...): Invalid `event`.') : _prodInvariant('103') : void 0; - event.currentTarget = dispatchListener ? EventPluginUtils.getNodeFromInstance(dispatchInstance) : null; - var res = dispatchListener ? dispatchListener(event) : null; - event.currentTarget = null; - event._dispatchListeners = null; - event._dispatchInstances = null; - return res; -} + chunk.copy(buffer, offset) + offset += chunk.length -/** - * @param {SyntheticEvent} event - * @return {boolean} True iff number of dispatches accumulated is greater than 0. - */ -function hasDispatches(event) { - return !!event._dispatchListeners; + // opcode + } else { + buffer.writeUInt8(chunk, offset) + offset += 1 + } + }) + + if (offset !== buffer.length) throw new Error('Could not decode chunks') + return buffer } -/** - * General utilities that are useful in creating custom Event Plugins. - */ -var EventPluginUtils = { - isEndish: isEndish, - isMoveish: isMoveish, - isStartish: isStartish, +function decompile (buffer) { + // TODO: remove me + if (types.Array(buffer)) return buffer - executeDirectDispatch: executeDirectDispatch, - executeDispatchesInOrder: executeDispatchesInOrder, - executeDispatchesInOrderStopAtTrue: executeDispatchesInOrderStopAtTrue, - hasDispatches: hasDispatches, + typeforce(types.Buffer, buffer) - getInstanceFromNode: function (node) { - return ComponentTree.getInstanceFromNode(node); - }, - getNodeFromInstance: function (node) { - return ComponentTree.getNodeFromInstance(node); - }, - isAncestor: function (a, b) { - return TreeTraversal.isAncestor(a, b); - }, - getLowestCommonAncestor: function (a, b) { - return TreeTraversal.getLowestCommonAncestor(a, b); - }, - getParentInstance: function (inst) { - return TreeTraversal.getParentInstance(inst); - }, - traverseTwoPhase: function (target, fn, arg) { - return TreeTraversal.traverseTwoPhase(target, fn, arg); - }, - traverseEnterLeave: function (from, to, fn, argFrom, argTo) { - return TreeTraversal.traverseEnterLeave(from, to, fn, argFrom, argTo); - }, + var chunks = [] + var i = 0 - injection: injection -}; + while (i < buffer.length) { + var opcode = buffer[i] -module.exports = EventPluginUtils; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // data chunk + if ((opcode > OPS.OP_0) && (opcode <= OPS.OP_PUSHDATA4)) { + var d = pushdata.decode(buffer, i) -/***/ }), -/* 51 */ -/***/ (function(module, exports, __webpack_require__) { + // did reading a pushDataInt fail? empty script + if (d === null) return [] + i += d.size -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + // attempt to read too much data? empty script + if (i + d.number > buffer.length) return [] + var data = buffer.slice(i, i + d.number) + i += d.number + chunks.push(data) -var caughtError = null; + // opcode + } else { + chunks.push(opcode) -/** - * Call a function while guarding against errors that happens within it. - * - * @param {String} name of the guard to use for logging or debugging - * @param {Function} func The function to invoke - * @param {*} a First argument - * @param {*} b Second argument - */ -function invokeGuardedCallback(name, func, a) { - try { - func(a); - } catch (x) { - if (caughtError === null) { - caughtError = x; + i += 1 } } -} -var ReactErrorUtils = { - invokeGuardedCallback: invokeGuardedCallback, - - /** - * Invoked by ReactTestUtils.Simulate so that any errors thrown by the event - * handler are sure to be rethrown by rethrowCaughtError. - */ - invokeGuardedCallbackWithCatch: invokeGuardedCallback, + return chunks +} - /** - * During execution of guarded functions we will capture the first error which - * we will rethrow to be handled by the top level error handler. - */ - rethrowCaughtError: function () { - if (caughtError) { - var error = caughtError; - caughtError = null; - throw error; - } +function toASM (chunks) { + if (Buffer.isBuffer(chunks)) { + chunks = decompile(chunks) } -}; -if (process.env.NODE_ENV !== 'production') { - /** - * To help development we can get better devtools integration by simulating a - * real browser event. - */ - if (typeof window !== 'undefined' && typeof window.dispatchEvent === 'function' && typeof document !== 'undefined' && typeof document.createEvent === 'function') { - var fakeNode = document.createElement('react'); - ReactErrorUtils.invokeGuardedCallback = function (name, func, a) { - var boundFunc = func.bind(null, a); - var evtType = 'react-' + name; - fakeNode.addEventListener(evtType, boundFunc, false); - var evt = document.createEvent('Event'); - evt.initEvent(evtType, false, false); - fakeNode.dispatchEvent(evt); - fakeNode.removeEventListener(evtType, boundFunc, false); - }; - } + return chunks.map(function (chunk) { + // data? + if (Buffer.isBuffer(chunk)) return chunk.toString('hex') + + // opcode! + return REVERSE_OPS[chunk] + }).join(' ') } -module.exports = ReactErrorUtils; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function fromASM (asm) { + typeforce(types.String, asm) -/***/ }), -/* 52 */ -/***/ (function(module, exports, __webpack_require__) { + return compile(asm.split(' ').map(function (chunkStr) { + // opcode? + if (OPS[chunkStr] !== undefined) return OPS[chunkStr] + typeforce(types.Hex, chunkStr) -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // data! + return Buffer.from(chunkStr, 'hex') + })) +} +function toStack (chunks) { + chunks = decompile(chunks) + typeforce(isPushOnly, chunks) + return chunks.map(function (op) { + if (Buffer.isBuffer(op)) return op + if (op === OPS.OP_0) return Buffer.allocUnsafe(0) -/** - * Gets the target node from a native browser event by accounting for - * inconsistencies in browser DOM APIs. - * - * @param {object} nativeEvent Native browser event. - * @return {DOMEventTarget} Target node. - */ + return scriptNumber.encode(op - OP_INT_BASE) + }) +} -function getEventTarget(nativeEvent) { - var target = nativeEvent.target || nativeEvent.srcElement || window; +function isCanonicalPubKey (buffer) { + if (!Buffer.isBuffer(buffer)) return false + if (buffer.length < 33) return false - // Normalize SVG <use> element events #4963 - if (target.correspondingUseElement) { - target = target.correspondingUseElement; + switch (buffer[0]) { + case 0x02: + case 0x03: + return buffer.length === 33 + case 0x04: + return buffer.length === 65 } - // Safari may fire events on text nodes (Node.TEXT_NODE is 3). - // @see http://www.quirksmode.org/js/events_properties.html - return target.nodeType === 3 ? target.parentNode : target; + return false } -module.exports = getEventTarget; - -/***/ }), -/* 53 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - +function isDefinedHashType (hashType) { + var hashTypeMod = hashType & ~0x80 -var ExecutionEnvironment = __webpack_require__(8); - -var useHasFeature; -if (ExecutionEnvironment.canUseDOM) { - useHasFeature = document.implementation && document.implementation.hasFeature && - // always returns true in newer browsers as per the standard. - // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature - document.implementation.hasFeature('', '') !== true; +// return hashTypeMod > SIGHASH_ALL && hashTypeMod < SIGHASH_SINGLE + return hashTypeMod > 0x00 && hashTypeMod < 0x04 } -/** - * Checks if an event is supported in the current execution environment. - * - * NOTE: This will not work correctly for non-generic events such as `change`, - * `reset`, `load`, `error`, and `select`. - * - * Borrows from Modernizr. - * - * @param {string} eventNameSuffix Event name, e.g. "click". - * @param {?boolean} capture Check if the capture phase is supported. - * @return {boolean} True if the event is supported. - * @internal - * @license Modernizr 3.0.0pre (Custom Build) | MIT - */ -function isEventSupported(eventNameSuffix, capture) { - if (!ExecutionEnvironment.canUseDOM || capture && !('addEventListener' in document)) { - return false; - } - - var eventName = 'on' + eventNameSuffix; - var isSupported = eventName in document; +function isCanonicalSignature (buffer) { + if (!Buffer.isBuffer(buffer)) return false + if (!isDefinedHashType(buffer[buffer.length - 1])) return false - if (!isSupported) { - var element = document.createElement('div'); - element.setAttribute(eventName, 'return;'); - isSupported = typeof element[eventName] === 'function'; - } + return bip66.check(buffer.slice(0, -1)) +} - if (!isSupported && useHasFeature && eventNameSuffix === 'wheel') { - // This is the only way to test support for the `wheel` event in IE9+. - isSupported = document.implementation.hasFeature('Events.wheel', '3.0'); - } +module.exports = { + compile: compile, + decompile: decompile, + fromASM: fromASM, + toASM: toASM, + toStack: toStack, + + number: __webpack_require__(203), + + isCanonicalPubKey: isCanonicalPubKey, + isCanonicalSignature: isCanonicalSignature, + isPushOnly: isPushOnly, + isDefinedHashType: isDefinedHashType +} - return isSupported; +var templates = __webpack_require__(469) +for (var key in templates) { + module.exports[key] = templates[key] } -module.exports = isEventSupported; /***/ }), -/* 54 */ +/* 15 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var elliptic = exports; -/** - * Translation from modifier key to the associated property in the event. - * @see http://www.w3.org/TR/DOM-Level-3-Events/#keys-Modifiers - */ +elliptic.version = __webpack_require__(385).version; +elliptic.utils = __webpack_require__(386); +elliptic.rand = __webpack_require__(171); +elliptic.curve = __webpack_require__(65); +elliptic.curves = __webpack_require__(392); -var modifierKeyToProp = { - Alt: 'altKey', - Control: 'ctrlKey', - Meta: 'metaKey', - Shift: 'shiftKey' -}; +// Protocols +elliptic.ec = __webpack_require__(400); +elliptic.eddsa = __webpack_require__(404); -// IE8 does not implement getModifierState so we simply map it to the only -// modifier keys exposed by the event itself, does not support Lock-keys. -// Currently, all major browsers except Chrome seems to support Lock-keys. -function modifierStateGetter(keyArg) { - var syntheticEvent = this; - var nativeEvent = syntheticEvent.nativeEvent; - if (nativeEvent.getModifierState) { - return nativeEvent.getModifierState(keyArg); - } - var keyProp = modifierKeyToProp[keyArg]; - return keyProp ? !!nativeEvent[keyProp] : false; -} -function getEventModifierState(nativeEvent) { - return modifierStateGetter; -} +/***/ }), +/* 16 */ +/***/ (function(module, exports) { -module.exports = getEventModifierState; +module.exports = { + "OP_FALSE": 0, + "OP_0": 0, + "OP_PUSHDATA1": 76, + "OP_PUSHDATA2": 77, + "OP_PUSHDATA4": 78, + "OP_1NEGATE": 79, + "OP_RESERVED": 80, + "OP_1": 81, + "OP_TRUE": 81, + "OP_2": 82, + "OP_3": 83, + "OP_4": 84, + "OP_5": 85, + "OP_6": 86, + "OP_7": 87, + "OP_8": 88, + "OP_9": 89, + "OP_10": 90, + "OP_11": 91, + "OP_12": 92, + "OP_13": 93, + "OP_14": 94, + "OP_15": 95, + "OP_16": 96, + "OP_NOP": 97, + "OP_VER": 98, + "OP_IF": 99, + "OP_NOTIF": 100, + "OP_VERIF": 101, + "OP_VERNOTIF": 102, + "OP_ELSE": 103, + "OP_ENDIF": 104, + "OP_VERIFY": 105, + "OP_RETURN": 106, + "OP_TOALTSTACK": 107, + "OP_FROMALTSTACK": 108, + "OP_2DROP": 109, + "OP_2DUP": 110, + "OP_3DUP": 111, + "OP_2OVER": 112, + "OP_2ROT": 113, + "OP_2SWAP": 114, + "OP_IFDUP": 115, + "OP_DEPTH": 116, + "OP_DROP": 117, + "OP_DUP": 118, + "OP_NIP": 119, + "OP_OVER": 120, + "OP_PICK": 121, + "OP_ROLL": 122, + "OP_ROT": 123, + "OP_SWAP": 124, + "OP_TUCK": 125, + "OP_CAT": 126, + "OP_SUBSTR": 127, + "OP_LEFT": 128, + "OP_RIGHT": 129, + "OP_SIZE": 130, + "OP_INVERT": 131, + "OP_AND": 132, + "OP_OR": 133, + "OP_XOR": 134, + "OP_EQUAL": 135, + "OP_EQUALVERIFY": 136, + "OP_RESERVED1": 137, + "OP_RESERVED2": 138, + "OP_1ADD": 139, + "OP_1SUB": 140, + "OP_2MUL": 141, + "OP_2DIV": 142, + "OP_NEGATE": 143, + "OP_ABS": 144, + "OP_NOT": 145, + "OP_0NOTEQUAL": 146, + "OP_ADD": 147, + "OP_SUB": 148, + "OP_MUL": 149, + "OP_DIV": 150, + "OP_MOD": 151, + "OP_LSHIFT": 152, + "OP_RSHIFT": 153, + "OP_BOOLAND": 154, + "OP_BOOLOR": 155, + "OP_NUMEQUAL": 156, + "OP_NUMEQUALVERIFY": 157, + "OP_NUMNOTEQUAL": 158, + "OP_LESSTHAN": 159, + "OP_GREATERTHAN": 160, + "OP_LESSTHANOREQUAL": 161, + "OP_GREATERTHANOREQUAL": 162, + "OP_MIN": 163, + "OP_MAX": 164, + "OP_WITHIN": 165, + "OP_RIPEMD160": 166, + "OP_SHA1": 167, + "OP_SHA256": 168, + "OP_HASH160": 169, + "OP_HASH256": 170, + "OP_CODESEPARATOR": 171, + "OP_CHECKSIG": 172, + "OP_CHECKSIGVERIFY": 173, + "OP_CHECKMULTISIG": 174, + "OP_CHECKMULTISIGVERIFY": 175, + "OP_NOP1": 176, + "OP_NOP2": 177, + "OP_CHECKLOCKTIMEVERIFY": 177, + "OP_NOP3": 178, + "OP_NOP4": 179, + "OP_NOP5": 180, + "OP_NOP6": 181, + "OP_NOP7": 182, + "OP_NOP8": 183, + "OP_NOP9": 184, + "OP_NOP10": 185, + "OP_PUBKEYHASH": 253, + "OP_PUBKEY": 254, + "OP_INVALIDOPCODE": 255 +}; /***/ }), -/* 55 */ +/* 17 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. + * Copyright 2016-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -var DOMLazyTree = __webpack_require__(27); -var Danger = __webpack_require__(154); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstrumentation = __webpack_require__(13); +var _prodInvariant = __webpack_require__(37); -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); -var setInnerHTML = __webpack_require__(43); -var setTextContent = __webpack_require__(90); +var ReactCurrentOwner = __webpack_require__(22); -function getNodeAfter(parentNode, node) { - // Special case for text components, which return [open, close] comments - // from getHostNode. - if (Array.isArray(node)) { - node = node[1]; +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +function isNative(fn) { + // Based on isNative() from Lodash + var funcToString = Function.prototype.toString; + var hasOwnProperty = Object.prototype.hasOwnProperty; + var reIsNative = RegExp('^' + funcToString + // Take an example native function source for comparison + .call(hasOwnProperty + // Strip regex characters so we can use it for regex + ).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&' + // Remove hasOwnProperty from the template to make it generic + ).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'); + try { + var source = funcToString.call(fn); + return reIsNative.test(source); + } catch (err) { + return false; } - return node ? node.nextSibling : parentNode.firstChild; } -/** - * Inserts `childNode` as a child of `parentNode` at the `index`. - * - * @param {DOMElement} parentNode Parent node in which to insert. - * @param {DOMElement} childNode Child node to insert. - * @param {number} index Index at which to insert the child. - * @internal - */ -var insertChildAt = createMicrosoftUnsafeLocalFunction(function (parentNode, childNode, referenceNode) { - // We rely exclusively on `insertBefore(node, null)` instead of also using - // `appendChild(node)`. (Using `undefined` is not allowed by all browsers so - // we are careful to use `null`.) - parentNode.insertBefore(childNode, referenceNode); -}); +var canUseCollections = +// Array.from +typeof Array.from === 'function' && +// Map +typeof Map === 'function' && isNative(Map) && +// Map.prototype.keys +Map.prototype != null && typeof Map.prototype.keys === 'function' && isNative(Map.prototype.keys) && +// Set +typeof Set === 'function' && isNative(Set) && +// Set.prototype.keys +Set.prototype != null && typeof Set.prototype.keys === 'function' && isNative(Set.prototype.keys); -function insertLazyTreeChildAt(parentNode, childTree, referenceNode) { - DOMLazyTree.insertTreeBefore(parentNode, childTree, referenceNode); -} +var setItem; +var getItem; +var removeItem; +var getItemIDs; +var addRoot; +var removeRoot; +var getRootIDs; -function moveChild(parentNode, childNode, referenceNode) { - if (Array.isArray(childNode)) { - moveDelimitedText(parentNode, childNode[0], childNode[1], referenceNode); - } else { - insertChildAt(parentNode, childNode, referenceNode); - } +if (canUseCollections) { + var itemMap = new Map(); + var rootIDSet = new Set(); + + setItem = function (id, item) { + itemMap.set(id, item); + }; + getItem = function (id) { + return itemMap.get(id); + }; + removeItem = function (id) { + itemMap['delete'](id); + }; + getItemIDs = function () { + return Array.from(itemMap.keys()); + }; + + addRoot = function (id) { + rootIDSet.add(id); + }; + removeRoot = function (id) { + rootIDSet['delete'](id); + }; + getRootIDs = function () { + return Array.from(rootIDSet.keys()); + }; +} else { + var itemByKey = {}; + var rootByKey = {}; + + // Use non-numeric keys to prevent V8 performance issues: + // https://github.com/facebook/react/pull/7232 + var getKeyFromID = function (id) { + return '.' + id; + }; + var getIDFromKey = function (key) { + return parseInt(key.substr(1), 10); + }; + + setItem = function (id, item) { + var key = getKeyFromID(id); + itemByKey[key] = item; + }; + getItem = function (id) { + var key = getKeyFromID(id); + return itemByKey[key]; + }; + removeItem = function (id) { + var key = getKeyFromID(id); + delete itemByKey[key]; + }; + getItemIDs = function () { + return Object.keys(itemByKey).map(getIDFromKey); + }; + + addRoot = function (id) { + var key = getKeyFromID(id); + rootByKey[key] = true; + }; + removeRoot = function (id) { + var key = getKeyFromID(id); + delete rootByKey[key]; + }; + getRootIDs = function () { + return Object.keys(rootByKey).map(getIDFromKey); + }; } -function removeChild(parentNode, childNode) { - if (Array.isArray(childNode)) { - var closingComment = childNode[1]; - childNode = childNode[0]; - removeDelimitedText(parentNode, childNode, closingComment); - parentNode.removeChild(closingComment); +var unmountedIDs = []; + +function purgeDeep(id) { + var item = getItem(id); + if (item) { + var childIDs = item.childIDs; + + removeItem(id); + childIDs.forEach(purgeDeep); } - parentNode.removeChild(childNode); } -function moveDelimitedText(parentNode, openingComment, closingComment, referenceNode) { - var node = openingComment; - while (true) { - var nextNode = node.nextSibling; - insertChildAt(parentNode, node, referenceNode); - if (node === closingComment) { - break; - } - node = nextNode; - } +function describeComponentFrame(name, source, ownerName) { + return '\n in ' + (name || 'Unknown') + (source ? ' (at ' + source.fileName.replace(/^.*[\\\/]/, '') + ':' + source.lineNumber + ')' : ownerName ? ' (created by ' + ownerName + ')' : ''); } -function removeDelimitedText(parentNode, startNode, closingComment) { - while (true) { - var node = startNode.nextSibling; - if (node === closingComment) { - // The closing comment is removed by ReactMultiChild. - break; - } else { - parentNode.removeChild(node); - } +function getDisplayName(element) { + if (element == null) { + return '#empty'; + } else if (typeof element === 'string' || typeof element === 'number') { + return '#text'; + } else if (typeof element.type === 'string') { + return element.type; + } else { + return element.type.displayName || element.type.name || 'Unknown'; } } -function replaceDelimitedText(openingComment, closingComment, stringText) { - var parentNode = openingComment.parentNode; - var nodeAfterComment = openingComment.nextSibling; - if (nodeAfterComment === closingComment) { - // There are no text nodes between the opening and closing comments; insert - // a new one if stringText isn't empty. - if (stringText) { - insertChildAt(parentNode, document.createTextNode(stringText), nodeAfterComment); +function describeID(id) { + var name = ReactComponentTreeHook.getDisplayName(id); + var element = ReactComponentTreeHook.getElement(id); + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var ownerName; + if (ownerID) { + ownerName = ReactComponentTreeHook.getDisplayName(ownerID); + } + process.env.NODE_ENV !== 'production' ? warning(element, 'ReactComponentTreeHook: Missing React element for debugID %s when ' + 'building stack', id) : void 0; + return describeComponentFrame(name, element && element._source, ownerName); +} + +var ReactComponentTreeHook = { + onSetChildren: function (id, nextChildIDs) { + var item = getItem(id); + !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; + item.childIDs = nextChildIDs; + + for (var i = 0; i < nextChildIDs.length; i++) { + var nextChildID = nextChildIDs[i]; + var nextChild = getItem(nextChildID); + !nextChild ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected hook events to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('140') : void 0; + !(nextChild.childIDs != null || typeof nextChild.element !== 'object' || nextChild.element == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onSetChildren() to fire for a container child before its parent includes it in onSetChildren().') : _prodInvariant('141') : void 0; + !nextChild.isMounted ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onMountComponent() to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('71') : void 0; + if (nextChild.parentID == null) { + nextChild.parentID = id; + // TODO: This shouldn't be necessary but mounting a new root during in + // componentWillMount currently causes not-yet-mounted components to + // be purged from our tree data so their parent id is missing. + } + !(nextChild.parentID === id) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onBeforeMountComponent() parent and onSetChildren() to be consistent (%s has parents %s and %s).', nextChildID, nextChild.parentID, id) : _prodInvariant('142', nextChildID, nextChild.parentID, id) : void 0; } - } else { - if (stringText) { - // Set the text content of the first node after the opening comment, and - // remove all following nodes up until the closing comment. - setTextContent(nodeAfterComment, stringText); - removeDelimitedText(parentNode, nodeAfterComment, closingComment); - } else { - removeDelimitedText(parentNode, openingComment, closingComment); + }, + onBeforeMountComponent: function (id, element, parentID) { + var item = { + element: element, + parentID: parentID, + text: null, + childIDs: [], + isMounted: false, + updateCount: 0 + }; + setItem(id, item); + }, + onBeforeUpdateComponent: function (id, element) { + var item = getItem(id); + if (!item || !item.isMounted) { + // We may end up here as a result of setState() in componentWillUnmount(). + // In this case, ignore the element. + return; + } + item.element = element; + }, + onMountComponent: function (id) { + var item = getItem(id); + !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; + item.isMounted = true; + var isRoot = item.parentID === 0; + if (isRoot) { + addRoot(id); + } + }, + onUpdateComponent: function (id) { + var item = getItem(id); + if (!item || !item.isMounted) { + // We may end up here as a result of setState() in componentWillUnmount(). + // In this case, ignore the element. + return; + } + item.updateCount++; + }, + onUnmountComponent: function (id) { + var item = getItem(id); + if (item) { + // We need to check if it exists. + // `item` might not exist if it is inside an error boundary, and a sibling + // error boundary child threw while mounting. Then this instance never + // got a chance to mount, but it still gets an unmounting event during + // the error boundary cleanup. + item.isMounted = false; + var isRoot = item.parentID === 0; + if (isRoot) { + removeRoot(id); + } + } + unmountedIDs.push(id); + }, + purgeUnmountedComponents: function () { + if (ReactComponentTreeHook._preventPurging) { + // Should only be used for testing. + return; } - } - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(openingComment)._debugID, - type: 'replace text', - payload: stringText - }); - } -} + for (var i = 0; i < unmountedIDs.length; i++) { + var id = unmountedIDs[i]; + purgeDeep(id); + } + unmountedIDs.length = 0; + }, + isMounted: function (id) { + var item = getItem(id); + return item ? item.isMounted : false; + }, + getCurrentStackAddendum: function (topElement) { + var info = ''; + if (topElement) { + var name = getDisplayName(topElement); + var owner = topElement._owner; + info += describeComponentFrame(name, topElement._source, owner && owner.getName()); + } -var dangerouslyReplaceNodeWithMarkup = Danger.dangerouslyReplaceNodeWithMarkup; -if (process.env.NODE_ENV !== 'production') { - dangerouslyReplaceNodeWithMarkup = function (oldChild, markup, prevInstance) { - Danger.dangerouslyReplaceNodeWithMarkup(oldChild, markup); - if (prevInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: prevInstance._debugID, - type: 'replace with', - payload: markup.toString() - }); + var currentOwner = ReactCurrentOwner.current; + var id = currentOwner && currentOwner._debugID; + + info += ReactComponentTreeHook.getStackAddendumByID(id); + return info; + }, + getStackAddendumByID: function (id) { + var info = ''; + while (id) { + info += describeID(id); + id = ReactComponentTreeHook.getParentID(id); + } + return info; + }, + getChildIDs: function (id) { + var item = getItem(id); + return item ? item.childIDs : []; + }, + getDisplayName: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (!element) { + return null; + } + return getDisplayName(element); + }, + getElement: function (id) { + var item = getItem(id); + return item ? item.element : null; + }, + getOwnerID: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (!element || !element._owner) { + return null; + } + return element._owner._debugID; + }, + getParentID: function (id) { + var item = getItem(id); + return item ? item.parentID : null; + }, + getSource: function (id) { + var item = getItem(id); + var element = item ? item.element : null; + var source = element != null ? element._source : null; + return source; + }, + getText: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (typeof element === 'string') { + return element; + } else if (typeof element === 'number') { + return '' + element; } else { - var nextInstance = ReactDOMComponentTree.getInstanceFromNode(markup.node); - if (nextInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: nextInstance._debugID, - type: 'mount', - payload: markup.toString() - }); - } + return null; } - }; -} + }, + getUpdateCount: function (id) { + var item = getItem(id); + return item ? item.updateCount : 0; + }, -/** - * Operations for updating with DOM children. - */ -var DOMChildrenOperations = { - dangerouslyReplaceNodeWithMarkup: dangerouslyReplaceNodeWithMarkup, - replaceDelimitedText: replaceDelimitedText, + getRootIDs: getRootIDs, + getRegisteredIDs: getItemIDs, - /** - * Updates a component's children by processing a series of updates. The - * update configurations are each expected to have a `parentNode` property. - * - * @param {array<object>} updates List of update configurations. - * @internal - */ - processUpdates: function (parentNode, updates) { - if (process.env.NODE_ENV !== 'production') { - var parentNodeDebugID = ReactDOMComponentTree.getInstanceFromNode(parentNode)._debugID; + pushNonStandardWarningStack: function (isCreatingElement, currentSource) { + if (typeof console.reactStack !== 'function') { + return; } - for (var k = 0; k < updates.length; k++) { - var update = updates[k]; - switch (update.type) { - case 'INSERT_MARKUP': - insertLazyTreeChildAt(parentNode, update.content, getNodeAfter(parentNode, update.afterNode)); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'insert child', - payload: { - toIndex: update.toIndex, - content: update.content.toString() - } - }); - } - break; - case 'MOVE_EXISTING': - moveChild(parentNode, update.fromNode, getNodeAfter(parentNode, update.afterNode)); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'move child', - payload: { fromIndex: update.fromIndex, toIndex: update.toIndex } - }); - } - break; - case 'SET_MARKUP': - setInnerHTML(parentNode, update.content); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'replace children', - payload: update.content.toString() - }); - } - break; - case 'TEXT_CONTENT': - setTextContent(parentNode, update.content); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'replace text', - payload: update.content.toString() - }); - } - break; - case 'REMOVE_NODE': - removeChild(parentNode, update.fromNode); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'remove child', - payload: { fromIndex: update.fromIndex } - }); - } - break; + var stack = []; + var currentOwner = ReactCurrentOwner.current; + var id = currentOwner && currentOwner._debugID; + + try { + if (isCreatingElement) { + stack.push({ + name: id ? ReactComponentTreeHook.getDisplayName(id) : null, + fileName: currentSource ? currentSource.fileName : null, + lineNumber: currentSource ? currentSource.lineNumber : null + }); + } + + while (id) { + var element = ReactComponentTreeHook.getElement(id); + var parentID = ReactComponentTreeHook.getParentID(id); + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var ownerName = ownerID ? ReactComponentTreeHook.getDisplayName(ownerID) : null; + var source = element && element._source; + stack.push({ + name: ownerName, + fileName: source ? source.fileName : null, + lineNumber: source ? source.lineNumber : null + }); + id = parentID; } + } catch (err) { + // Internal state is messed up. + // Stop building the stack (it's just a nice to have). } + + console.reactStack(stack); + }, + popNonStandardWarningStack: function () { + if (typeof console.reactStackEnd !== 'function') { + return; + } + console.reactStackEnd(); } }; -module.exports = DOMChildrenOperations; +module.exports = ReactComponentTreeHook; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 56 */ +/* 18 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; + + /** - * Copyright 2013-present, Facebook, Inc. + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ +function makeEmptyFunction(arg) { + return function () { + return arg; + }; +} +/** + * This function accepts and discards inputs; it has no side effects. This is + * primarily useful idiomatically for overridable function endpoints which + * always need to be callable, since JS lacks a null-call idiom ala Cocoa. + */ +var emptyFunction = function emptyFunction() {}; -var DOMNamespaces = { - html: 'http://www.w3.org/1999/xhtml', - mathml: 'http://www.w3.org/1998/Math/MathML', - svg: 'http://www.w3.org/2000/svg' +emptyFunction.thatReturns = makeEmptyFunction; +emptyFunction.thatReturnsFalse = makeEmptyFunction(false); +emptyFunction.thatReturnsTrue = makeEmptyFunction(true); +emptyFunction.thatReturnsNull = makeEmptyFunction(null); +emptyFunction.thatReturnsThis = function () { + return this; +}; +emptyFunction.thatReturnsArgument = function (arg) { + return arg; }; -module.exports = DOMNamespaces; +module.exports = emptyFunction; /***/ }), -/* 57 */ +/* 19 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -/* globals MSApp */ +// Trust the developer to only use ReactInstrumentation with a __DEV__ check -/** - * Create a function which has 'unsafe' privileges (required by windows8 apps) - */ +var debugTool = null; -var createMicrosoftUnsafeLocalFunction = function (func) { - if (typeof MSApp !== 'undefined' && MSApp.execUnsafeLocalFunction) { - return function (arg0, arg1, arg2, arg3) { - MSApp.execUnsafeLocalFunction(function () { - return func(arg0, arg1, arg2, arg3); - }); - }; - } else { - return func; - } -}; +if (process.env.NODE_ENV !== 'production') { + var ReactDebugTool = __webpack_require__(240); + debugTool = ReactDebugTool; +} -module.exports = createMicrosoftUnsafeLocalFunction; +module.exports = { debugTool: debugTool }; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 58 */ +/* 20 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. + + +var bind = __webpack_require__(155); +var isBuffer = __webpack_require__(337); + +/*global toString:true*/ + +// utils is a library of generic helper functions non-specific to axios + +var toString = Object.prototype.toString; + +/** + * Determine if a value is an Array * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * @param {Object} val The value to test + * @returns {boolean} True if value is an Array, otherwise false + */ +function isArray(val) { + return toString.call(val) === '[object Array]'; +} + +/** + * Determine if a value is an ArrayBuffer * + * @param {Object} val The value to test + * @returns {boolean} True if value is an ArrayBuffer, otherwise false */ +function isArrayBuffer(val) { + return toString.call(val) === '[object ArrayBuffer]'; +} +/** + * Determine if a value is a FormData + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an FormData, otherwise false + */ +function isFormData(val) { + return (typeof FormData !== 'undefined') && (val instanceof FormData); +} +/** + * Determine if a value is a view on an ArrayBuffer + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false + */ +function isArrayBufferView(val) { + var result; + if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) { + result = ArrayBuffer.isView(val); + } else { + result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer); + } + return result; +} -var _prodInvariant = __webpack_require__(3); +/** + * Determine if a value is a String + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a String, otherwise false + */ +function isString(val) { + return typeof val === 'string'; +} -var ReactPropTypesSecret = __webpack_require__(94); -var propTypesFactory = __webpack_require__(79); +/** + * Determine if a value is a Number + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Number, otherwise false + */ +function isNumber(val) { + return typeof val === 'number'; +} -var React = __webpack_require__(24); -var PropTypes = propTypesFactory(React.isValidElement); +/** + * Determine if a value is undefined + * + * @param {Object} val The value to test + * @returns {boolean} True if the value is undefined, otherwise false + */ +function isUndefined(val) { + return typeof val === 'undefined'; +} -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +/** + * Determine if a value is an Object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an Object, otherwise false + */ +function isObject(val) { + return val !== null && typeof val === 'object'; +} -var hasReadOnlyValue = { - button: true, - checkbox: true, - image: true, - hidden: true, - radio: true, - reset: true, - submit: true -}; +/** + * Determine if a value is a Date + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Date, otherwise false + */ +function isDate(val) { + return toString.call(val) === '[object Date]'; +} -function _assertSingleLink(inputProps) { - !(inputProps.checkedLink == null || inputProps.valueLink == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a valueLink. If you want to use checkedLink, you probably don\'t want to use valueLink and vice versa.') : _prodInvariant('87') : void 0; +/** + * Determine if a value is a File + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a File, otherwise false + */ +function isFile(val) { + return toString.call(val) === '[object File]'; } -function _assertValueLink(inputProps) { - _assertSingleLink(inputProps); - !(inputProps.value == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a valueLink and a value or onChange event. If you want to use value or onChange, you probably don\'t want to use valueLink.') : _prodInvariant('88') : void 0; + +/** + * Determine if a value is a Blob + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Blob, otherwise false + */ +function isBlob(val) { + return toString.call(val) === '[object Blob]'; } -function _assertCheckedLink(inputProps) { - _assertSingleLink(inputProps); - !(inputProps.checked == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a checked property or onChange event. If you want to use checked or onChange, you probably don\'t want to use checkedLink') : _prodInvariant('89') : void 0; +/** + * Determine if a value is a Function + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Function, otherwise false + */ +function isFunction(val) { + return toString.call(val) === '[object Function]'; } -var propTypes = { - value: function (props, propName, componentName) { - if (!props[propName] || hasReadOnlyValue[props.type] || props.onChange || props.readOnly || props.disabled) { - return null; - } - return new Error('You provided a `value` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultValue`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); - }, - checked: function (props, propName, componentName) { - if (!props[propName] || props.onChange || props.readOnly || props.disabled) { - return null; - } - return new Error('You provided a `checked` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultChecked`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); - }, - onChange: PropTypes.func -}; +/** + * Determine if a value is a Stream + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Stream, otherwise false + */ +function isStream(val) { + return isObject(val) && isFunction(val.pipe); +} -var loggedTypeFailures = {}; -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; +/** + * Determine if a value is a URLSearchParams object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a URLSearchParams object, otherwise false + */ +function isURLSearchParams(val) { + return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams; } /** - * Provide a linked `value` attribute for controlled forms. You should not use - * this outside of the ReactDOM controlled form components. + * Trim excess whitespace off the beginning and end of a string + * + * @param {String} str The String to trim + * @returns {String} The String freed of excess whitespace */ -var LinkedValueUtils = { - checkPropTypes: function (tagName, props, owner) { - for (var propName in propTypes) { - if (propTypes.hasOwnProperty(propName)) { - var error = propTypes[propName](props, propName, tagName, 'prop', null, ReactPropTypesSecret); - } - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; +function trim(str) { + return str.replace(/^\s*/, '').replace(/\s*$/, ''); +} - var addendum = getDeclarationErrorAddendum(owner); - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed form propType: %s%s', error.message, addendum) : void 0; - } - } - }, - - /** - * @param {object} inputProps Props for form component - * @return {*} current value of the input either from value prop or link. - */ - getValue: function (inputProps) { - if (inputProps.valueLink) { - _assertValueLink(inputProps); - return inputProps.valueLink.value; - } - return inputProps.value; - }, - - /** - * @param {object} inputProps Props for form component - * @return {*} current checked status of the input either from checked prop - * or link. - */ - getChecked: function (inputProps) { - if (inputProps.checkedLink) { - _assertCheckedLink(inputProps); - return inputProps.checkedLink.value; - } - return inputProps.checked; - }, - - /** - * @param {object} inputProps Props for form component - * @param {SyntheticEvent} event change event to handle - */ - executeOnChange: function (inputProps, event) { - if (inputProps.valueLink) { - _assertValueLink(inputProps); - return inputProps.valueLink.requestChange(event.target.value); - } else if (inputProps.checkedLink) { - _assertCheckedLink(inputProps); - return inputProps.checkedLink.requestChange(event.target.checked); - } else if (inputProps.onChange) { - return inputProps.onChange.call(undefined, event); - } +/** + * Determine if we're running in a standard browser environment + * + * This allows axios to run in a web worker, and react-native. + * Both environments support XMLHttpRequest, but not fully standard globals. + * + * web workers: + * typeof window -> undefined + * typeof document -> undefined + * + * react-native: + * navigator.product -> 'ReactNative' + */ +function isStandardBrowserEnv() { + if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') { + return false; } -}; - -module.exports = LinkedValueUtils; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 59 */ -/***/ (function(module, exports, __webpack_require__) { + return ( + typeof window !== 'undefined' && + typeof document !== 'undefined' + ); +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. +/** + * Iterate over an Array or an Object invoking a function for each item. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * If `obj` is an Array callback will be called passing + * the value, index, and complete array for each item. * - * + * If 'obj' is an Object callback will be called passing + * the value, key, and complete object for each property. + * + * @param {Object|Array} obj The object to iterate + * @param {Function} fn The callback to invoke for each item */ +function forEach(obj, fn) { + // Don't bother if no value provided + if (obj === null || typeof obj === 'undefined') { + return; + } + // Force an array if not already something iterable + if (typeof obj !== 'object' && !isArray(obj)) { + /*eslint no-param-reassign:0*/ + obj = [obj]; + } - -var _prodInvariant = __webpack_require__(3); - -var invariant = __webpack_require__(1); - -var injected = false; - -var ReactComponentEnvironment = { - /** - * Optionally injectable hook for swapping out mount images in the middle of - * the tree. - */ - replaceNodeWithMarkup: null, - - /** - * Optionally injectable hook for processing a queue of child updates. Will - * later move into MultiChildComponents. - */ - processChildrenUpdates: null, - - injection: { - injectEnvironment: function (environment) { - !!injected ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactCompositeComponent: injectEnvironment() can only be called once.') : _prodInvariant('104') : void 0; - ReactComponentEnvironment.replaceNodeWithMarkup = environment.replaceNodeWithMarkup; - ReactComponentEnvironment.processChildrenUpdates = environment.processChildrenUpdates; - injected = true; + if (isArray(obj)) { + // Iterate over array values + for (var i = 0, l = obj.length; i < l; i++) { + fn.call(null, obj[i], i, obj); + } + } else { + // Iterate over object keys + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key)) { + fn.call(null, obj[key], key, obj); + } } } -}; - -module.exports = ReactComponentEnvironment; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 60 */ -/***/ (function(module, exports, __webpack_require__) { +} -"use strict"; /** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. + * Accepts varargs expecting each argument to be an object, then + * immutably merges the properties of each object and returns result. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * When multiple objects contain the same key the later object in + * the arguments list will take precedence. * - * @typechecks - * + * Example: + * + * ```js + * var result = merge({foo: 123}, {foo: 456}); + * console.log(result.foo); // outputs 456 + * ``` + * + * @param {Object} obj1 Object to merge + * @returns {Object} Result of all merge properties */ +function merge(/* obj1, obj2, obj3, ... */) { + var result = {}; + function assignValue(val, key) { + if (typeof result[key] === 'object' && typeof val === 'object') { + result[key] = merge(result[key], val); + } else { + result[key] = val; + } + } -/*eslint-disable no-self-compare */ - - - -var hasOwnProperty = Object.prototype.hasOwnProperty; - -/** - * inlined Object.is polyfill to avoid requiring consumers ship their own - * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is - */ -function is(x, y) { - // SameValue algorithm - if (x === y) { - // Steps 1-5, 7-10 - // Steps 6.b-6.e: +0 != -0 - // Added the nonzero y check to make Flow happy, but it is redundant - return x !== 0 || y !== 0 || 1 / x === 1 / y; - } else { - // Step 6.a: NaN == NaN - return x !== x && y !== y; + for (var i = 0, l = arguments.length; i < l; i++) { + forEach(arguments[i], assignValue); } + return result; } /** - * Performs equality by iterating through keys on an object and returning false - * when any key has values which are not strictly equal between the arguments. - * Returns true when the values of all keys are strictly equal. + * Extends object a by mutably adding to it the properties of object b. + * + * @param {Object} a The object to be extended + * @param {Object} b The object to copy properties from + * @param {Object} thisArg The object to bind function to + * @return {Object} The resulting value of object a */ -function shallowEqual(objA, objB) { - if (is(objA, objB)) { - return true; - } +function extend(a, b, thisArg) { + forEach(b, function assignValue(val, key) { + if (thisArg && typeof val === 'function') { + a[key] = bind(val, thisArg); + } else { + a[key] = val; + } + }); + return a; +} - if (typeof objA !== 'object' || objA === null || typeof objB !== 'object' || objB === null) { - return false; - } +module.exports = { + isArray: isArray, + isArrayBuffer: isArrayBuffer, + isBuffer: isBuffer, + isFormData: isFormData, + isArrayBufferView: isArrayBufferView, + isString: isString, + isNumber: isNumber, + isObject: isObject, + isUndefined: isUndefined, + isDate: isDate, + isFile: isFile, + isBlob: isBlob, + isFunction: isFunction, + isStream: isStream, + isURLSearchParams: isURLSearchParams, + isStandardBrowserEnv: isStandardBrowserEnv, + forEach: forEach, + merge: merge, + extend: extend, + trim: trim +}; - var keysA = Object.keys(objA); - var keysB = Object.keys(objB); - if (keysA.length !== keysB.length) { - return false; - } +/***/ }), +/* 21 */ +/***/ (function(module, exports) { - // Test for A's keys different from B. - for (var i = 0; i < keysA.length; i++) { - if (!hasOwnProperty.call(objB, keysA[i]) || !is(objA[keysA[i]], objB[keysA[i]])) { - return false; - } - } +module.exports = assert; - return true; +function assert(val, msg) { + if (!val) + throw new Error(msg || 'Assertion failed'); } -module.exports = shallowEqual; +assert.equal = function assertEqual(l, r, msg) { + if (l != r) + throw new Error(msg || ('Assertion failed: ' + l + ' != ' + r)); +}; + /***/ }), -/* 61 */ +/* 22 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -5929,46 +7566,33 @@ module.exports = shallowEqual; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ /** - * Given a `prevElement` and `nextElement`, determines if the existing - * instance should be updated as opposed to being destroyed or replaced by a new - * instance. Both arguments are elements. This ensures that this logic can - * operate on stateless trees without any backing instance. + * Keeps track of the current owner. * - * @param {?object} prevElement - * @param {?object} nextElement - * @return {boolean} True if the existing instance should be updated. - * @protected + * The current owner is the component who should own any components that are + * currently being constructed. */ +var ReactCurrentOwner = { + /** + * @internal + * @type {ReactComponent} + */ + current: null +}; -function shouldUpdateReactComponent(prevElement, nextElement) { - var prevEmpty = prevElement === null || prevElement === false; - var nextEmpty = nextElement === null || nextElement === false; - if (prevEmpty || nextEmpty) { - return prevEmpty === nextEmpty; - } - - var prevType = typeof prevElement; - var nextType = typeof nextElement; - if (prevType === 'string' || prevType === 'number') { - return nextType === 'string' || nextType === 'number'; - } else { - return nextType === 'object' && prevElement.type === nextElement.type && prevElement.key === nextElement.key; - } -} - -module.exports = shouldUpdateReactComponent; +module.exports = ReactCurrentOwner; /***/ }), -/* 62 */ +/* 23 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** +/* WEBPACK VAR INJECTION */(function(process) {/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -5976,304 +7600,544 @@ module.exports = shouldUpdateReactComponent; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -/** - * Escape and wrap key so it is safe to use as a reactid - * - * @param {string} key to be escaped. - * @return {string} the escaped key. - */ +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); -function escape(key) { - var escapeRegex = /[=:]/g; - var escaperLookup = { - '=': '=0', - ':': '=2' - }; - var escapedString = ('' + key).replace(escapeRegex, function (match) { - return escaperLookup[match]; - }); +var CallbackQueue = __webpack_require__(130); +var PooledClass = __webpack_require__(32); +var ReactFeatureFlags = __webpack_require__(131); +var ReactReconciler = __webpack_require__(38); +var Transaction = __webpack_require__(58); - return '$' + escapedString; -} +var invariant = __webpack_require__(2); -/** - * Unescape and unwrap key for human-readable display - * - * @param {string} key to unescape. - * @return {string} the unescaped key. - */ -function unescape(key) { - var unescapeRegex = /(=0|=2)/g; - var unescaperLookup = { - '=0': '=', - '=2': ':' - }; - var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); +var dirtyComponents = []; +var updateBatchNumber = 0; +var asapCallbackQueue = CallbackQueue.getPooled(); +var asapEnqueued = false; - return ('' + keySubstring).replace(unescapeRegex, function (match) { - return unescaperLookup[match]; - }); +var batchingStrategy = null; + +function ensureInjected() { + !(ReactUpdates.ReactReconcileTransaction && batchingStrategy) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must inject a reconcile transaction class and batching strategy') : _prodInvariant('123') : void 0; } -var KeyEscapeUtils = { - escape: escape, - unescape: unescape +var NESTED_UPDATES = { + initialize: function () { + this.dirtyComponentsLength = dirtyComponents.length; + }, + close: function () { + if (this.dirtyComponentsLength !== dirtyComponents.length) { + // Additional updates were enqueued by componentDidUpdate handlers or + // similar; before our own UPDATE_QUEUEING wrapper closes, we want to run + // these new updates so that if A's componentDidUpdate calls setState on + // B, B will update before the callback A's updater provided when calling + // setState. + dirtyComponents.splice(0, this.dirtyComponentsLength); + flushBatchedUpdates(); + } else { + dirtyComponents.length = 0; + } + } }; -module.exports = KeyEscapeUtils; +var UPDATE_QUEUEING = { + initialize: function () { + this.callbackQueue.reset(); + }, + close: function () { + this.callbackQueue.notifyAll(); + } +}; -/***/ }), -/* 63 */ -/***/ (function(module, exports, __webpack_require__) { +var TRANSACTION_WRAPPERS = [NESTED_UPDATES, UPDATE_QUEUEING]; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +function ReactUpdatesFlushTransaction() { + this.reinitializeTransaction(); + this.dirtyComponentsLength = null; + this.callbackQueue = CallbackQueue.getPooled(); + this.reconcileTransaction = ReactUpdates.ReactReconcileTransaction.getPooled( + /* useCreateElement */true); +} + +_assign(ReactUpdatesFlushTransaction.prototype, Transaction, { + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, + + destructor: function () { + this.dirtyComponentsLength = null; + CallbackQueue.release(this.callbackQueue); + this.callbackQueue = null; + ReactUpdates.ReactReconcileTransaction.release(this.reconcileTransaction); + this.reconcileTransaction = null; + }, + + perform: function (method, scope, a) { + // Essentially calls `this.reconcileTransaction.perform(method, scope, a)` + // with this transaction's wrappers around it. + return Transaction.perform.call(this, this.reconcileTransaction.perform, this.reconcileTransaction, method, scope, a); + } +}); + +PooledClass.addPoolingTo(ReactUpdatesFlushTransaction); + +function batchedUpdates(callback, a, b, c, d, e) { + ensureInjected(); + return batchingStrategy.batchedUpdates(callback, a, b, c, d, e); +} + +/** + * Array comparator for ReactComponents by mount ordering. * + * @param {ReactComponent} c1 first component you're comparing + * @param {ReactComponent} c2 second component you're comparing + * @return {number} Return value usable by Array.prototype.sort(). */ +function mountOrderComparator(c1, c2) { + return c1._mountOrder - c2._mountOrder; +} +function runBatchedUpdates(transaction) { + var len = transaction.dirtyComponentsLength; + !(len === dirtyComponents.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected flush transaction\'s stored dirty-components length (%s) to match dirty-components array length (%s).', len, dirtyComponents.length) : _prodInvariant('124', len, dirtyComponents.length) : void 0; + // Since reconciling a component higher in the owner hierarchy usually (not + // always -- see shouldComponentUpdate()) will reconcile children, reconcile + // them before their children by sorting the array. + dirtyComponents.sort(mountOrderComparator); -var _prodInvariant = __webpack_require__(3); + // Any updates enqueued while reconciling must be performed after this entire + // batch. Otherwise, if dirtyComponents is [A, B] where A has children B and + // C, B could update twice in a single batch if C's render enqueues an update + // to B (since B would have already updated, we should skip it, and the only + // way we can know to do so is by checking the batch counter). + updateBatchNumber++; -var ReactCurrentOwner = __webpack_require__(14); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactUpdates = __webpack_require__(15); + for (var i = 0; i < len; i++) { + // If a component is unmounted before pending changes apply, it will still + // be here, but we assume that it has cleared its _pendingCallbacks and + // that performUpdateIfNecessary is a noop. + var component = dirtyComponents[i]; -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); + // If performUpdateIfNecessary happens to enqueue any new updates, we + // shouldn't execute the callbacks until the next render happens, so + // stash the callbacks first + var callbacks = component._pendingCallbacks; + component._pendingCallbacks = null; -function enqueueUpdate(internalInstance) { - ReactUpdates.enqueueUpdate(internalInstance); -} + var markerName; + if (ReactFeatureFlags.logTopLevelRenders) { + var namedComponent = component; + // Duck type TopLevelWrapper. This is probably always true. + if (component._currentElement.type.isReactTopLevelWrapper) { + namedComponent = component._renderedComponent; + } + markerName = 'React update: ' + namedComponent.getName(); + console.time(markerName); + } -function formatUnexpectedArgument(arg) { - var type = typeof arg; - if (type !== 'object') { - return type; - } - var displayName = arg.constructor && arg.constructor.name || type; - var keys = Object.keys(arg); - if (keys.length > 0 && keys.length < 20) { - return displayName + ' (keys: ' + keys.join(', ') + ')'; + ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction, updateBatchNumber); + + if (markerName) { + console.timeEnd(markerName); + } + + if (callbacks) { + for (var j = 0; j < callbacks.length; j++) { + transaction.callbackQueue.enqueue(callbacks[j], component.getPublicInstance()); + } + } } - return displayName; } -function getInternalInstanceReadyForUpdate(publicInstance, callerName) { - var internalInstance = ReactInstanceMap.get(publicInstance); - if (!internalInstance) { - if (process.env.NODE_ENV !== 'production') { - var ctor = publicInstance.constructor; - // Only warn when we have a callerName. Otherwise we should be silent. - // We're probably calling from enqueueCallback. We don't want to warn - // there because we already warned for the corresponding lifecycle method. - process.env.NODE_ENV !== 'production' ? warning(!callerName, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, ctor && (ctor.displayName || ctor.name) || 'ReactClass') : void 0; +var flushBatchedUpdates = function () { + // ReactUpdatesFlushTransaction's wrappers will clear the dirtyComponents + // array and perform any updates enqueued by mount-ready handlers (i.e., + // componentDidUpdate) but we need to check here too in order to catch + // updates enqueued by setState callbacks and asap calls. + while (dirtyComponents.length || asapEnqueued) { + if (dirtyComponents.length) { + var transaction = ReactUpdatesFlushTransaction.getPooled(); + transaction.perform(runBatchedUpdates, null, transaction); + ReactUpdatesFlushTransaction.release(transaction); + } + + if (asapEnqueued) { + asapEnqueued = false; + var queue = asapCallbackQueue; + asapCallbackQueue = CallbackQueue.getPooled(); + queue.notifyAll(); + CallbackQueue.release(queue); } - return null; } +}; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '%s(...): Cannot update during an existing state transition (such as ' + "within `render` or another component's constructor). Render methods " + 'should be a pure function of props and state; constructor ' + 'side-effects are an anti-pattern, but can be moved to ' + '`componentWillMount`.', callerName) : void 0; +/** + * Mark a component as needing a rerender, adding an optional callback to a + * list of functions which will be executed once the rerender occurs. + */ +function enqueueUpdate(component) { + ensureInjected(); + + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. (This is called by each top-level update + // function, like setState, forceUpdate, etc.; creation and + // destruction of top-level components is guarded in ReactMount.) + + if (!batchingStrategy.isBatchingUpdates) { + batchingStrategy.batchedUpdates(enqueueUpdate, component); + return; } - return internalInstance; + dirtyComponents.push(component); + if (component._updateBatchNumber == null) { + component._updateBatchNumber = updateBatchNumber + 1; + } } /** - * ReactUpdateQueue allows for state updates to be scheduled into a later - * reconciliation step. + * Enqueue a callback to be run at the end of the current batching cycle. Throws + * if no updates are currently being performed. */ -var ReactUpdateQueue = { - /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function (publicInstance) { - if (process.env.NODE_ENV !== 'production') { - var owner = ReactCurrentOwner.current; - if (owner !== null) { - process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing isMounted inside its render() function. ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; - owner._warnedAboutRefsInRender = true; - } - } - var internalInstance = ReactInstanceMap.get(publicInstance); - if (internalInstance) { - // During componentWillMount and render this will still be null but after - // that will always render to something. At least for now. So we can use - // this hack. - return !!internalInstance._renderedComponent; - } else { - return false; - } +function asap(callback, context) { + !batchingStrategy.isBatchingUpdates ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates.asap: Can\'t enqueue an asap callback in a context whereupdates are not being batched.') : _prodInvariant('125') : void 0; + asapCallbackQueue.enqueue(callback, context); + asapEnqueued = true; +} + +var ReactUpdatesInjection = { + injectReconcileTransaction: function (ReconcileTransaction) { + !ReconcileTransaction ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a reconcile transaction class') : _prodInvariant('126') : void 0; + ReactUpdates.ReactReconcileTransaction = ReconcileTransaction; }, + injectBatchingStrategy: function (_batchingStrategy) { + !_batchingStrategy ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batching strategy') : _prodInvariant('127') : void 0; + !(typeof _batchingStrategy.batchedUpdates === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batchedUpdates() function') : _prodInvariant('128') : void 0; + !(typeof _batchingStrategy.isBatchingUpdates === 'boolean') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide an isBatchingUpdates boolean attribute') : _prodInvariant('129') : void 0; + batchingStrategy = _batchingStrategy; + } +}; + +var ReactUpdates = { /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. + * React references `ReactReconcileTransaction` using this property in order + * to allow dependency injection. * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @param {string} callerName Name of the calling function in the public API. * @internal */ - enqueueCallback: function (publicInstance, callback, callerName) { - ReactUpdateQueue.validateCallback(callback, callerName); - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance); + ReactReconcileTransaction: null, - // Previously we would throw an error if we didn't have an internal - // instance. Since we want to make it a no-op instead, we mirror the same - // behavior we have in other enqueue* methods. - // We also need to ignore callbacks in componentWillMount. See - // enqueueUpdates. - if (!internalInstance) { - return null; - } + batchedUpdates: batchedUpdates, + enqueueUpdate: enqueueUpdate, + flushBatchedUpdates: flushBatchedUpdates, + injection: ReactUpdatesInjection, + asap: asap +}; - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); - } else { - internalInstance._pendingCallbacks = [callback]; +module.exports = ReactUpdates; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 24 */ +/***/ (function(module, exports) { + +var g; + +// This works in non-strict mode +g = (function() { + return this; +})(); + +try { + // This works if eval is allowed (see CSP) + g = g || Function("return this")() || (1,eval)("this"); +} catch(e) { + // This works if the window reference is available + if(typeof window === "object") + g = window; +} + +// g can still be undefined, but nothing to do about it... +// We return undefined, instead of nothing here, so it's +// easier to handle this case. if(!global) { ...} + +module.exports = g; + + +/***/ }), +/* 25 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); + +exports.inherits = inherits; + +function toArray(msg, enc) { + if (Array.isArray(msg)) + return msg.slice(); + if (!msg) + return []; + var res = []; + if (typeof msg === 'string') { + if (!enc) { + for (var i = 0; i < msg.length; i++) { + var c = msg.charCodeAt(i); + var hi = c >> 8; + var lo = c & 0xff; + if (hi) + res.push(hi, lo); + else + res.push(lo); + } + } else if (enc === 'hex') { + msg = msg.replace(/[^a-z0-9]+/ig, ''); + if (msg.length % 2 !== 0) + msg = '0' + msg; + for (i = 0; i < msg.length; i += 2) + res.push(parseInt(msg[i] + msg[i + 1], 16)); } - // TODO: The callback here is ignored when setState is called from - // componentWillMount. Either fix it or disallow doing so completely in - // favor of getInitialState. Alternatively, we can disallow - // componentWillMount during server-side rendering. - enqueueUpdate(internalInstance); - }, + } else { + for (i = 0; i < msg.length; i++) + res[i] = msg[i] | 0; + } + return res; +} +exports.toArray = toArray; - enqueueCallbackInternal: function (internalInstance, callback) { - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); +function toHex(msg) { + var res = ''; + for (var i = 0; i < msg.length; i++) + res += zero2(msg[i].toString(16)); + return res; +} +exports.toHex = toHex; + +function htonl(w) { + var res = (w >>> 24) | + ((w >>> 8) & 0xff00) | + ((w << 8) & 0xff0000) | + ((w & 0xff) << 24); + return res >>> 0; +} +exports.htonl = htonl; + +function toHex32(msg, endian) { + var res = ''; + for (var i = 0; i < msg.length; i++) { + var w = msg[i]; + if (endian === 'little') + w = htonl(w); + res += zero8(w.toString(16)); + } + return res; +} +exports.toHex32 = toHex32; + +function zero2(word) { + if (word.length === 1) + return '0' + word; + else + return word; +} +exports.zero2 = zero2; + +function zero8(word) { + if (word.length === 7) + return '0' + word; + else if (word.length === 6) + return '00' + word; + else if (word.length === 5) + return '000' + word; + else if (word.length === 4) + return '0000' + word; + else if (word.length === 3) + return '00000' + word; + else if (word.length === 2) + return '000000' + word; + else if (word.length === 1) + return '0000000' + word; + else + return word; +} +exports.zero8 = zero8; + +function join32(msg, start, end, endian) { + var len = end - start; + assert(len % 4 === 0); + var res = new Array(len / 4); + for (var i = 0, k = start; i < res.length; i++, k += 4) { + var w; + if (endian === 'big') + w = (msg[k] << 24) | (msg[k + 1] << 16) | (msg[k + 2] << 8) | msg[k + 3]; + else + w = (msg[k + 3] << 24) | (msg[k + 2] << 16) | (msg[k + 1] << 8) | msg[k]; + res[i] = w >>> 0; + } + return res; +} +exports.join32 = join32; + +function split32(msg, endian) { + var res = new Array(msg.length * 4); + for (var i = 0, k = 0; i < msg.length; i++, k += 4) { + var m = msg[i]; + if (endian === 'big') { + res[k] = m >>> 24; + res[k + 1] = (m >>> 16) & 0xff; + res[k + 2] = (m >>> 8) & 0xff; + res[k + 3] = m & 0xff; } else { - internalInstance._pendingCallbacks = [callback]; + res[k + 3] = m >>> 24; + res[k + 2] = (m >>> 16) & 0xff; + res[k + 1] = (m >>> 8) & 0xff; + res[k] = m & 0xff; } - enqueueUpdate(internalInstance); - }, + } + return res; +} +exports.split32 = split32; - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal - */ - enqueueForceUpdate: function (publicInstance) { - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'forceUpdate'); +function rotr32(w, b) { + return (w >>> b) | (w << (32 - b)); +} +exports.rotr32 = rotr32; - if (!internalInstance) { - return; - } +function rotl32(w, b) { + return (w << b) | (w >>> (32 - b)); +} +exports.rotl32 = rotl32; - internalInstance._pendingForceUpdate = true; +function sum32(a, b) { + return (a + b) >>> 0; +} +exports.sum32 = sum32; - enqueueUpdate(internalInstance); - }, +function sum32_3(a, b, c) { + return (a + b + c) >>> 0; +} +exports.sum32_3 = sum32_3; - /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} completeState Next state. - * @internal - */ - enqueueReplaceState: function (publicInstance, completeState, callback) { - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'replaceState'); +function sum32_4(a, b, c, d) { + return (a + b + c + d) >>> 0; +} +exports.sum32_4 = sum32_4; - if (!internalInstance) { - return; - } +function sum32_5(a, b, c, d, e) { + return (a + b + c + d + e) >>> 0; +} +exports.sum32_5 = sum32_5; - internalInstance._pendingStateQueue = [completeState]; - internalInstance._pendingReplaceState = true; +function sum64(buf, pos, ah, al) { + var bh = buf[pos]; + var bl = buf[pos + 1]; - // Future-proof 15.5 - if (callback !== undefined && callback !== null) { - ReactUpdateQueue.validateCallback(callback, 'replaceState'); - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); - } else { - internalInstance._pendingCallbacks = [callback]; - } - } + var lo = (al + bl) >>> 0; + var hi = (lo < al ? 1 : 0) + ah + bh; + buf[pos] = hi >>> 0; + buf[pos + 1] = lo; +} +exports.sum64 = sum64; - enqueueUpdate(internalInstance); - }, +function sum64_hi(ah, al, bh, bl) { + var lo = (al + bl) >>> 0; + var hi = (lo < al ? 1 : 0) + ah + bh; + return hi >>> 0; +} +exports.sum64_hi = sum64_hi; - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} partialState Next partial state to be merged with state. - * @internal - */ - enqueueSetState: function (publicInstance, partialState) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetState(); - process.env.NODE_ENV !== 'production' ? warning(partialState != null, 'setState(...): You passed an undefined or null state object; ' + 'instead, use forceUpdate().') : void 0; - } +function sum64_lo(ah, al, bh, bl) { + var lo = al + bl; + return lo >>> 0; +} +exports.sum64_lo = sum64_lo; + +function sum64_4_hi(ah, al, bh, bl, ch, cl, dh, dl) { + var carry = 0; + var lo = al; + lo = (lo + bl) >>> 0; + carry += lo < al ? 1 : 0; + lo = (lo + cl) >>> 0; + carry += lo < cl ? 1 : 0; + lo = (lo + dl) >>> 0; + carry += lo < dl ? 1 : 0; + + var hi = ah + bh + ch + dh + carry; + return hi >>> 0; +} +exports.sum64_4_hi = sum64_4_hi; - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'setState'); +function sum64_4_lo(ah, al, bh, bl, ch, cl, dh, dl) { + var lo = al + bl + cl + dl; + return lo >>> 0; +} +exports.sum64_4_lo = sum64_4_lo; + +function sum64_5_hi(ah, al, bh, bl, ch, cl, dh, dl, eh, el) { + var carry = 0; + var lo = al; + lo = (lo + bl) >>> 0; + carry += lo < al ? 1 : 0; + lo = (lo + cl) >>> 0; + carry += lo < cl ? 1 : 0; + lo = (lo + dl) >>> 0; + carry += lo < dl ? 1 : 0; + lo = (lo + el) >>> 0; + carry += lo < el ? 1 : 0; + + var hi = ah + bh + ch + dh + eh + carry; + return hi >>> 0; +} +exports.sum64_5_hi = sum64_5_hi; - if (!internalInstance) { - return; - } +function sum64_5_lo(ah, al, bh, bl, ch, cl, dh, dl, eh, el) { + var lo = al + bl + cl + dl + el; - var queue = internalInstance._pendingStateQueue || (internalInstance._pendingStateQueue = []); - queue.push(partialState); + return lo >>> 0; +} +exports.sum64_5_lo = sum64_5_lo; - enqueueUpdate(internalInstance); - }, +function rotr64_hi(ah, al, num) { + var r = (al << (32 - num)) | (ah >>> num); + return r >>> 0; +} +exports.rotr64_hi = rotr64_hi; - enqueueElementInternal: function (internalInstance, nextElement, nextContext) { - internalInstance._pendingElement = nextElement; - // TODO: introduce _pendingContext instead of setting it directly. - internalInstance._context = nextContext; - enqueueUpdate(internalInstance); - }, +function rotr64_lo(ah, al, num) { + var r = (ah << (32 - num)) | (al >>> num); + return r >>> 0; +} +exports.rotr64_lo = rotr64_lo; - validateCallback: function (callback, callerName) { - !(!callback || typeof callback === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.', callerName, formatUnexpectedArgument(callback)) : _prodInvariant('122', callerName, formatUnexpectedArgument(callback)) : void 0; - } -}; +function shr64_hi(ah, al, num) { + return ah >>> num; +} +exports.shr64_hi = shr64_hi; + +function shr64_lo(ah, al, num) { + var r = (ah << (32 - num)) | (al >>> num); + return r >>> 0; +} +exports.shr64_lo = shr64_lo; -module.exports = ReactUpdateQueue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 64 */ +/* 26 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -6284,372 +8148,327 @@ module.exports = ReactUpdateQueue; -var _assign = __webpack_require__(5); - -var emptyFunction = __webpack_require__(12); -var warning = __webpack_require__(2); - -var validateDOMNesting = emptyFunction; - -if (process.env.NODE_ENV !== 'production') { - // This validation code was written based on the HTML5 parsing spec: - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope - // - // Note: this does not catch all invalid nesting, nor does it try to (as it's - // not clear what practical benefit doing so provides); instead, we warn only - // for cases where the parser will give a parse tree differing from what React - // intended. For example, <b><div></div></b> is invalid but we don't warn - // because it still parses correctly; we do warn for other cases like nested - // <p> tags where the beginning of the second element implicitly closes the - // first, causing a confusing mess. - - // https://html.spec.whatwg.org/multipage/syntax.html#special - var specialTags = ['address', 'applet', 'area', 'article', 'aside', 'base', 'basefont', 'bgsound', 'blockquote', 'body', 'br', 'button', 'caption', 'center', 'col', 'colgroup', 'dd', 'details', 'dir', 'div', 'dl', 'dt', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'frame', 'frameset', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'iframe', 'img', 'input', 'isindex', 'li', 'link', 'listing', 'main', 'marquee', 'menu', 'menuitem', 'meta', 'nav', 'noembed', 'noframes', 'noscript', 'object', 'ol', 'p', 'param', 'plaintext', 'pre', 'script', 'section', 'select', 'source', 'style', 'summary', 'table', 'tbody', 'td', 'template', 'textarea', 'tfoot', 'th', 'thead', 'title', 'tr', 'track', 'ul', 'wbr', 'xmp']; - - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope - var inScopeTags = ['applet', 'caption', 'html', 'table', 'td', 'th', 'marquee', 'object', 'template', +var _assign = __webpack_require__(8); - // https://html.spec.whatwg.org/multipage/syntax.html#html-integration-point - // TODO: Distinguish by namespace here -- for <title>, including it here - // errs on the side of fewer warnings - 'foreignObject', 'desc', 'title']; +var PooledClass = __webpack_require__(32); - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-button-scope - var buttonScopeTags = inScopeTags.concat(['button']); +var emptyFunction = __webpack_require__(18); +var warning = __webpack_require__(3); - // https://html.spec.whatwg.org/multipage/syntax.html#generate-implied-end-tags - var impliedEndTags = ['dd', 'dt', 'li', 'option', 'optgroup', 'p', 'rp', 'rt']; +var didWarnForAddedNewProperty = false; +var isProxySupported = typeof Proxy === 'function'; - var emptyAncestorInfo = { - current: null, +var shouldBeReleasedProperties = ['dispatchConfig', '_targetInst', 'nativeEvent', 'isDefaultPrevented', 'isPropagationStopped', '_dispatchListeners', '_dispatchInstances']; - formTag: null, - aTagInScope: null, - buttonTagInScope: null, - nobrTagInScope: null, - pTagInButtonScope: null, +/** + * @interface Event + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var EventInterface = { + type: null, + target: null, + // currentTarget is set when dispatching; no use in copying it here + currentTarget: emptyFunction.thatReturnsNull, + eventPhase: null, + bubbles: null, + cancelable: null, + timeStamp: function (event) { + return event.timeStamp || Date.now(); + }, + defaultPrevented: null, + isTrusted: null +}; - listItemTagAutoclosing: null, - dlItemTagAutoclosing: null - }; +/** + * Synthetic events are dispatched by event plugins, typically in response to a + * top-level event delegation handler. + * + * These systems should generally use pooling to reduce the frequency of garbage + * collection. The system should check `isPersistent` to determine whether the + * event should be released into the pool after being dispatched. Users that + * need a persisted event should invoke `persist`. + * + * Synthetic events (and subclasses) implement the DOM Level 3 Events API by + * normalizing browser quirks. Subclasses do not necessarily have to implement a + * DOM interface; custom application-specific events can also subclass this. + * + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {*} targetInst Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @param {DOMEventTarget} nativeEventTarget Target node. + */ +function SyntheticEvent(dispatchConfig, targetInst, nativeEvent, nativeEventTarget) { + if (process.env.NODE_ENV !== 'production') { + // these have a getter/setter for warnings + delete this.nativeEvent; + delete this.preventDefault; + delete this.stopPropagation; + } - var updatedAncestorInfo = function (oldInfo, tag, instance) { - var ancestorInfo = _assign({}, oldInfo || emptyAncestorInfo); - var info = { tag: tag, instance: instance }; + this.dispatchConfig = dispatchConfig; + this._targetInst = targetInst; + this.nativeEvent = nativeEvent; - if (inScopeTags.indexOf(tag) !== -1) { - ancestorInfo.aTagInScope = null; - ancestorInfo.buttonTagInScope = null; - ancestorInfo.nobrTagInScope = null; + var Interface = this.constructor.Interface; + for (var propName in Interface) { + if (!Interface.hasOwnProperty(propName)) { + continue; } - if (buttonScopeTags.indexOf(tag) !== -1) { - ancestorInfo.pTagInButtonScope = null; + if (process.env.NODE_ENV !== 'production') { + delete this[propName]; // this has a getter/setter for warnings } - - // See rules for 'li', 'dd', 'dt' start tags in - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody - if (specialTags.indexOf(tag) !== -1 && tag !== 'address' && tag !== 'div' && tag !== 'p') { - ancestorInfo.listItemTagAutoclosing = null; - ancestorInfo.dlItemTagAutoclosing = null; + var normalize = Interface[propName]; + if (normalize) { + this[propName] = normalize(nativeEvent); + } else { + if (propName === 'target') { + this.target = nativeEventTarget; + } else { + this[propName] = nativeEvent[propName]; + } } + } - ancestorInfo.current = info; + var defaultPrevented = nativeEvent.defaultPrevented != null ? nativeEvent.defaultPrevented : nativeEvent.returnValue === false; + if (defaultPrevented) { + this.isDefaultPrevented = emptyFunction.thatReturnsTrue; + } else { + this.isDefaultPrevented = emptyFunction.thatReturnsFalse; + } + this.isPropagationStopped = emptyFunction.thatReturnsFalse; + return this; +} - if (tag === 'form') { - ancestorInfo.formTag = info; - } - if (tag === 'a') { - ancestorInfo.aTagInScope = info; - } - if (tag === 'button') { - ancestorInfo.buttonTagInScope = info; - } - if (tag === 'nobr') { - ancestorInfo.nobrTagInScope = info; +_assign(SyntheticEvent.prototype, { + preventDefault: function () { + this.defaultPrevented = true; + var event = this.nativeEvent; + if (!event) { + return; } - if (tag === 'p') { - ancestorInfo.pTagInButtonScope = info; + + if (event.preventDefault) { + event.preventDefault(); + // eslint-disable-next-line valid-typeof + } else if (typeof event.returnValue !== 'unknown') { + event.returnValue = false; } - if (tag === 'li') { - ancestorInfo.listItemTagAutoclosing = info; + this.isDefaultPrevented = emptyFunction.thatReturnsTrue; + }, + + stopPropagation: function () { + var event = this.nativeEvent; + if (!event) { + return; } - if (tag === 'dd' || tag === 'dt') { - ancestorInfo.dlItemTagAutoclosing = info; + + if (event.stopPropagation) { + event.stopPropagation(); + // eslint-disable-next-line valid-typeof + } else if (typeof event.cancelBubble !== 'unknown') { + // The ChangeEventPlugin registers a "propertychange" event for + // IE. This event does not support bubbling or cancelling, and + // any references to cancelBubble throw "Member not found". A + // typeof check of "unknown" circumvents this issue (and is also + // IE specific). + event.cancelBubble = true; } - return ancestorInfo; - }; + this.isPropagationStopped = emptyFunction.thatReturnsTrue; + }, /** - * Returns whether + * We release all dispatched `SyntheticEvent`s after each event loop, adding + * them back into the pool. This allows a way to hold onto a reference that + * won't be added back into the pool. */ - var isTagValidWithParent = function (tag, parentTag) { - // First, let's check if we're in an unusual parsing mode... - switch (parentTag) { - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inselect - case 'select': - return tag === 'option' || tag === 'optgroup' || tag === '#text'; - case 'optgroup': - return tag === 'option' || tag === '#text'; - // Strictly speaking, seeing an <option> doesn't mean we're in a <select> - // but - case 'option': - return tag === '#text'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intd - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incaption - // No special behavior since these rules fall back to "in body" mode for - // all except special table nodes which cause bad parsing behavior anyway. + persist: function () { + this.isPersistent = emptyFunction.thatReturnsTrue; + }, - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intr - case 'tr': - return tag === 'th' || tag === 'td' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intbody - case 'tbody': - case 'thead': - case 'tfoot': - return tag === 'tr' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incolgroup - case 'colgroup': - return tag === 'col' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intable - case 'table': - return tag === 'caption' || tag === 'colgroup' || tag === 'tbody' || tag === 'tfoot' || tag === 'thead' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inhead - case 'head': - return tag === 'base' || tag === 'basefont' || tag === 'bgsound' || tag === 'link' || tag === 'meta' || tag === 'title' || tag === 'noscript' || tag === 'noframes' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/semantics.html#the-html-element - case 'html': - return tag === 'head' || tag === 'body'; - case '#document': - return tag === 'html'; + /** + * Checks if this event should be released back into the pool. + * + * @return {boolean} True if this should not be released, false otherwise. + */ + isPersistent: emptyFunction.thatReturnsFalse, + + /** + * `PooledClass` looks for `destructor` on each instance it releases. + */ + destructor: function () { + var Interface = this.constructor.Interface; + for (var propName in Interface) { + if (process.env.NODE_ENV !== 'production') { + Object.defineProperty(this, propName, getPooledWarningPropertyDefinition(propName, Interface[propName])); + } else { + this[propName] = null; + } + } + for (var i = 0; i < shouldBeReleasedProperties.length; i++) { + this[shouldBeReleasedProperties[i]] = null; + } + if (process.env.NODE_ENV !== 'production') { + Object.defineProperty(this, 'nativeEvent', getPooledWarningPropertyDefinition('nativeEvent', null)); + Object.defineProperty(this, 'preventDefault', getPooledWarningPropertyDefinition('preventDefault', emptyFunction)); + Object.defineProperty(this, 'stopPropagation', getPooledWarningPropertyDefinition('stopPropagation', emptyFunction)); } + } +}); - // Probably in the "in body" parsing mode, so we outlaw only tag combos - // where the parsing rules cause implicit opens or closes to be added. - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody - switch (tag) { - case 'h1': - case 'h2': - case 'h3': - case 'h4': - case 'h5': - case 'h6': - return parentTag !== 'h1' && parentTag !== 'h2' && parentTag !== 'h3' && parentTag !== 'h4' && parentTag !== 'h5' && parentTag !== 'h6'; +SyntheticEvent.Interface = EventInterface; - case 'rp': - case 'rt': - return impliedEndTags.indexOf(parentTag) === -1; +if (process.env.NODE_ENV !== 'production') { + if (isProxySupported) { + /*eslint-disable no-func-assign */ + SyntheticEvent = new Proxy(SyntheticEvent, { + construct: function (target, args) { + return this.apply(target, Object.create(target.prototype), args); + }, + apply: function (constructor, that, args) { + return new Proxy(constructor.apply(that, args), { + set: function (target, prop, value) { + if (prop !== 'isPersistent' && !target.constructor.Interface.hasOwnProperty(prop) && shouldBeReleasedProperties.indexOf(prop) === -1) { + process.env.NODE_ENV !== 'production' ? warning(didWarnForAddedNewProperty || target.isPersistent(), "This synthetic event is reused for performance reasons. If you're " + "seeing this, you're adding a new property in the synthetic event object. " + 'The property is never released. See ' + 'https://fb.me/react-event-pooling for more information.') : void 0; + didWarnForAddedNewProperty = true; + } + target[prop] = value; + return true; + } + }); + } + }); + /*eslint-enable no-func-assign */ + } +} +/** + * Helper to reduce boilerplate when creating subclasses. + * + * @param {function} Class + * @param {?object} Interface + */ +SyntheticEvent.augmentClass = function (Class, Interface) { + var Super = this; - case 'body': - case 'caption': - case 'col': - case 'colgroup': - case 'frame': - case 'head': - case 'html': - case 'tbody': - case 'td': - case 'tfoot': - case 'th': - case 'thead': - case 'tr': - // These tags are only valid with a few parents that have special child - // parsing rules -- if we're down here, then none of those matched and - // so we allow it only if we don't know what the parent is, as all other - // cases are invalid. - return parentTag == null; - } + var E = function () {}; + E.prototype = Super.prototype; + var prototype = new E(); - return true; - }; + _assign(prototype, Class.prototype); + Class.prototype = prototype; + Class.prototype.constructor = Class; - /** - * Returns whether - */ - var findInvalidAncestorForTag = function (tag, ancestorInfo) { - switch (tag) { - case 'address': - case 'article': - case 'aside': - case 'blockquote': - case 'center': - case 'details': - case 'dialog': - case 'dir': - case 'div': - case 'dl': - case 'fieldset': - case 'figcaption': - case 'figure': - case 'footer': - case 'header': - case 'hgroup': - case 'main': - case 'menu': - case 'nav': - case 'ol': - case 'p': - case 'section': - case 'summary': - case 'ul': - case 'pre': - case 'listing': - case 'table': - case 'hr': - case 'xmp': - case 'h1': - case 'h2': - case 'h3': - case 'h4': - case 'h5': - case 'h6': - return ancestorInfo.pTagInButtonScope; - - case 'form': - return ancestorInfo.formTag || ancestorInfo.pTagInButtonScope; + Class.Interface = _assign({}, Super.Interface, Interface); + Class.augmentClass = Super.augmentClass; - case 'li': - return ancestorInfo.listItemTagAutoclosing; + PooledClass.addPoolingTo(Class, PooledClass.fourArgumentPooler); +}; - case 'dd': - case 'dt': - return ancestorInfo.dlItemTagAutoclosing; +PooledClass.addPoolingTo(SyntheticEvent, PooledClass.fourArgumentPooler); - case 'button': - return ancestorInfo.buttonTagInScope; +module.exports = SyntheticEvent; - case 'a': - // Spec says something about storing a list of markers, but it sounds - // equivalent to this check. - return ancestorInfo.aTagInScope; +/** + * Helper to nullify syntheticEvent instance properties when destructing + * + * @param {object} SyntheticEvent + * @param {String} propName + * @return {object} defineProperty object + */ +function getPooledWarningPropertyDefinition(propName, getVal) { + var isFunction = typeof getVal === 'function'; + return { + configurable: true, + set: set, + get: get + }; - case 'nobr': - return ancestorInfo.nobrTagInScope; - } + function set(val) { + var action = isFunction ? 'setting the method' : 'setting the property'; + warn(action, 'This is effectively a no-op'); + return val; + } - return null; - }; + function get() { + var action = isFunction ? 'accessing the method' : 'accessing the property'; + var result = isFunction ? 'This is a no-op function' : 'This is set to null'; + warn(action, result); + return getVal; + } - /** - * Given a ReactCompositeComponent instance, return a list of its recursive - * owners, starting at the root and ending with the instance itself. - */ - var findOwnerStack = function (instance) { - if (!instance) { - return []; - } + function warn(action, result) { + var warningCondition = false; + process.env.NODE_ENV !== 'production' ? warning(warningCondition, "This synthetic event is reused for performance reasons. If you're seeing this, " + "you're %s `%s` on a released/nullified synthetic event. %s. " + 'If you must keep the original synthetic event around, use event.persist(). ' + 'See https://fb.me/react-event-pooling for more information.', action, propName, result) : void 0; + } +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var stack = []; - do { - stack.push(instance); - } while (instance = instance._currentElement._owner); - stack.reverse(); - return stack; - }; +/***/ }), +/* 27 */ +/***/ (function(module, exports, __webpack_require__) { - var didWarn = {}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var inherits = __webpack_require__(4) +var md5 = __webpack_require__(63) +var RIPEMD160 = __webpack_require__(97) +var sha = __webpack_require__(103) - validateDOMNesting = function (childTag, childText, childInstance, ancestorInfo) { - ancestorInfo = ancestorInfo || emptyAncestorInfo; - var parentInfo = ancestorInfo.current; - var parentTag = parentInfo && parentInfo.tag; +var Base = __webpack_require__(29) - if (childText != null) { - process.env.NODE_ENV !== 'production' ? warning(childTag == null, 'validateDOMNesting: when childText is passed, childTag should be null') : void 0; - childTag = '#text'; - } +function HashNoConstructor (hash) { + Base.call(this, 'digest') - var invalidParent = isTagValidWithParent(childTag, parentTag) ? null : parentInfo; - var invalidAncestor = invalidParent ? null : findInvalidAncestorForTag(childTag, ancestorInfo); - var problematic = invalidParent || invalidAncestor; + this._hash = hash + this.buffers = [] +} - if (problematic) { - var ancestorTag = problematic.tag; - var ancestorInstance = problematic.instance; +inherits(HashNoConstructor, Base) - var childOwner = childInstance && childInstance._currentElement._owner; - var ancestorOwner = ancestorInstance && ancestorInstance._currentElement._owner; +HashNoConstructor.prototype._update = function (data) { + this.buffers.push(data) +} - var childOwners = findOwnerStack(childOwner); - var ancestorOwners = findOwnerStack(ancestorOwner); +HashNoConstructor.prototype._final = function () { + var buf = Buffer.concat(this.buffers) + var r = this._hash(buf) + this.buffers = null - var minStackLen = Math.min(childOwners.length, ancestorOwners.length); - var i; + return r +} - var deepestCommon = -1; - for (i = 0; i < minStackLen; i++) { - if (childOwners[i] === ancestorOwners[i]) { - deepestCommon = i; - } else { - break; - } - } +function Hash (hash) { + Base.call(this, 'digest') - var UNKNOWN = '(unknown)'; - var childOwnerNames = childOwners.slice(deepestCommon + 1).map(function (inst) { - return inst.getName() || UNKNOWN; - }); - var ancestorOwnerNames = ancestorOwners.slice(deepestCommon + 1).map(function (inst) { - return inst.getName() || UNKNOWN; - }); - var ownerInfo = [].concat( - // If the parent and child instances have a common owner ancestor, start - // with that -- otherwise we just start with the parent's owners. - deepestCommon !== -1 ? childOwners[deepestCommon].getName() || UNKNOWN : [], ancestorOwnerNames, ancestorTag, - // If we're warning about an invalid (non-parent) ancestry, add '...' - invalidAncestor ? ['...'] : [], childOwnerNames, childTag).join(' > '); + this._hash = hash +} - var warnKey = !!invalidParent + '|' + childTag + '|' + ancestorTag + '|' + ownerInfo; - if (didWarn[warnKey]) { - return; - } - didWarn[warnKey] = true; +inherits(Hash, Base) - var tagDisplayName = childTag; - var whitespaceInfo = ''; - if (childTag === '#text') { - if (/\S/.test(childText)) { - tagDisplayName = 'Text nodes'; - } else { - tagDisplayName = 'Whitespace text nodes'; - whitespaceInfo = " Make sure you don't have any extra whitespace between tags on " + 'each line of your source code.'; - } - } else { - tagDisplayName = '<' + childTag + '>'; - } +Hash.prototype._update = function (data) { + this._hash.update(data) +} - if (invalidParent) { - var info = ''; - if (ancestorTag === 'table' && childTag === 'tr') { - info += ' Add a <tbody> to your code to match the DOM tree generated by ' + 'the browser.'; - } - process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a child of <%s>.%s ' + 'See %s.%s', tagDisplayName, ancestorTag, whitespaceInfo, ownerInfo, info) : void 0; - } else { - process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a descendant of ' + '<%s>. See %s.', tagDisplayName, ancestorTag, ownerInfo) : void 0; - } - } - }; +Hash.prototype._final = function () { + return this._hash.digest() +} - validateDOMNesting.updatedAncestorInfo = updatedAncestorInfo; +module.exports = function createHash (alg) { + alg = alg.toLowerCase() + if (alg === 'md5') return new HashNoConstructor(md5) + if (alg === 'rmd160' || alg === 'ripemd160') return new Hash(new RIPEMD160()) - // For testing - validateDOMNesting.isTagValidInContext = function (tag, ancestorInfo) { - ancestorInfo = ancestorInfo || emptyAncestorInfo; - var parentInfo = ancestorInfo.current; - var parentTag = parentInfo && parentInfo.tag; - return isTagValidWithParent(tag, parentTag) && !findInvalidAncestorForTag(tag, ancestorInfo); - }; + return new Hash(sha(alg)) } -module.exports = validateDOMNesting; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 65 */ +/* 28 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** +/* WEBPACK VAR INJECTION */(function(process) {/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -6661,8612 +8480,46052 @@ module.exports = validateDOMNesting; +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +function checkMask(value, bitmask) { + return (value & bitmask) === bitmask; +} + +var DOMPropertyInjection = { + /** + * Mapping from normalized, camelcased property names to a configuration that + * specifies how the associated DOM property should be accessed or rendered. + */ + MUST_USE_PROPERTY: 0x1, + HAS_BOOLEAN_VALUE: 0x4, + HAS_NUMERIC_VALUE: 0x8, + HAS_POSITIVE_NUMERIC_VALUE: 0x10 | 0x8, + HAS_OVERLOADED_BOOLEAN_VALUE: 0x20, + + /** + * Inject some specialized knowledge about the DOM. This takes a config object + * with the following properties: + * + * isCustomAttribute: function that given an attribute name will return true + * if it can be inserted into the DOM verbatim. Useful for data-* or aria-* + * attributes where it's impossible to enumerate all of the possible + * attribute names, + * + * Properties: object mapping DOM property name to one of the + * DOMPropertyInjection constants or null. If your attribute isn't in here, + * it won't get written to the DOM. + * + * DOMAttributeNames: object mapping React attribute name to the DOM + * attribute name. Attribute names not specified use the **lowercase** + * normalized name. + * + * DOMAttributeNamespaces: object mapping React attribute name to the DOM + * attribute namespace URL. (Attribute names not specified use no namespace.) + * + * DOMPropertyNames: similar to DOMAttributeNames but for DOM properties. + * Property names not specified use the normalized name. + * + * DOMMutationMethods: Properties that require special mutation methods. If + * `value` is undefined, the mutation method should unset the property. + * + * @param {object} domPropertyConfig the config as described above. + */ + injectDOMPropertyConfig: function (domPropertyConfig) { + var Injection = DOMPropertyInjection; + var Properties = domPropertyConfig.Properties || {}; + var DOMAttributeNamespaces = domPropertyConfig.DOMAttributeNamespaces || {}; + var DOMAttributeNames = domPropertyConfig.DOMAttributeNames || {}; + var DOMPropertyNames = domPropertyConfig.DOMPropertyNames || {}; + var DOMMutationMethods = domPropertyConfig.DOMMutationMethods || {}; + + if (domPropertyConfig.isCustomAttribute) { + DOMProperty._isCustomAttributeFunctions.push(domPropertyConfig.isCustomAttribute); + } + + for (var propName in Properties) { + !!DOMProperty.properties.hasOwnProperty(propName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'injectDOMPropertyConfig(...): You\'re trying to inject DOM property \'%s\' which has already been injected. You may be accidentally injecting the same DOM property config twice, or you may be injecting two configs that have conflicting property names.', propName) : _prodInvariant('48', propName) : void 0; + + var lowerCased = propName.toLowerCase(); + var propConfig = Properties[propName]; + + var propertyInfo = { + attributeName: lowerCased, + attributeNamespace: null, + propertyName: propName, + mutationMethod: null, + + mustUseProperty: checkMask(propConfig, Injection.MUST_USE_PROPERTY), + hasBooleanValue: checkMask(propConfig, Injection.HAS_BOOLEAN_VALUE), + hasNumericValue: checkMask(propConfig, Injection.HAS_NUMERIC_VALUE), + hasPositiveNumericValue: checkMask(propConfig, Injection.HAS_POSITIVE_NUMERIC_VALUE), + hasOverloadedBooleanValue: checkMask(propConfig, Injection.HAS_OVERLOADED_BOOLEAN_VALUE) + }; + !(propertyInfo.hasBooleanValue + propertyInfo.hasNumericValue + propertyInfo.hasOverloadedBooleanValue <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'DOMProperty: Value can be one of boolean, overloaded boolean, or numeric value, but not a combination: %s', propName) : _prodInvariant('50', propName) : void 0; + + if (process.env.NODE_ENV !== 'production') { + DOMProperty.getPossibleStandardName[lowerCased] = propName; + } + + if (DOMAttributeNames.hasOwnProperty(propName)) { + var attributeName = DOMAttributeNames[propName]; + propertyInfo.attributeName = attributeName; + if (process.env.NODE_ENV !== 'production') { + DOMProperty.getPossibleStandardName[attributeName] = propName; + } + } + + if (DOMAttributeNamespaces.hasOwnProperty(propName)) { + propertyInfo.attributeNamespace = DOMAttributeNamespaces[propName]; + } + + if (DOMPropertyNames.hasOwnProperty(propName)) { + propertyInfo.propertyName = DOMPropertyNames[propName]; + } + + if (DOMMutationMethods.hasOwnProperty(propName)) { + propertyInfo.mutationMethod = DOMMutationMethods[propName]; + } + + DOMProperty.properties[propName] = propertyInfo; + } + } +}; + +/* eslint-disable max-len */ +var ATTRIBUTE_NAME_START_CHAR = ':A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD'; +/* eslint-enable max-len */ + /** - * `charCode` represents the actual "character code" and is safe to use with - * `String.fromCharCode`. As such, only keys that correspond to printable - * characters produce a valid `charCode`, the only exception to this is Enter. - * The Tab-key is considered non-printable and does not have a `charCode`, - * presumably because it does not produce a tab-character in browsers. + * DOMProperty exports lookup objects that can be used like functions: * - * @param {object} nativeEvent Native browser event. - * @return {number} Normalized `charCode` property. + * > DOMProperty.isValid['id'] + * true + * > DOMProperty.isValid['foobar'] + * undefined + * + * Although this may be confusing, it performs better in general. + * + * @see http://jsperf.com/key-exists + * @see http://jsperf.com/key-missing */ +var DOMProperty = { + ID_ATTRIBUTE_NAME: 'data-reactid', + ROOT_ATTRIBUTE_NAME: 'data-reactroot', -function getEventCharCode(nativeEvent) { - var charCode; - var keyCode = nativeEvent.keyCode; + ATTRIBUTE_NAME_START_CHAR: ATTRIBUTE_NAME_START_CHAR, + ATTRIBUTE_NAME_CHAR: ATTRIBUTE_NAME_START_CHAR + '\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040', - if ('charCode' in nativeEvent) { - charCode = nativeEvent.charCode; + /** + * Map from property "standard name" to an object with info about how to set + * the property in the DOM. Each object contains: + * + * attributeName: + * Used when rendering markup or with `*Attribute()`. + * attributeNamespace + * propertyName: + * Used on DOM node instances. (This includes properties that mutate due to + * external factors.) + * mutationMethod: + * If non-null, used instead of the property or `setAttribute()` after + * initial render. + * mustUseProperty: + * Whether the property must be accessed and mutated as an object property. + * hasBooleanValue: + * Whether the property should be removed when set to a falsey value. + * hasNumericValue: + * Whether the property must be numeric or parse as a numeric and should be + * removed when set to a falsey value. + * hasPositiveNumericValue: + * Whether the property must be positive numeric or parse as a positive + * numeric and should be removed when set to a falsey value. + * hasOverloadedBooleanValue: + * Whether the property can be used as a flag as well as with a value. + * Removed when strictly equal to false; present without a value when + * strictly equal to true; present with a value otherwise. + */ + properties: {}, - // FF does not set `charCode` for the Enter-key, check against `keyCode`. - if (charCode === 0 && keyCode === 13) { - charCode = 13; - } - } else { - // IE8 does not implement `charCode`, but `keyCode` has the correct value. - charCode = keyCode; - } + /** + * Mapping from lowercase property names to the properly cased version, used + * to warn in the case of missing properties. Available only in __DEV__. + * + * autofocus is predefined, because adding it to the property whitelist + * causes unintended side effects. + * + * @type {Object} + */ + getPossibleStandardName: process.env.NODE_ENV !== 'production' ? { autofocus: 'autoFocus' } : null, - // Some non-printable keys are reported in `charCode`/`keyCode`, discard them. - // Must not discard the (non-)printable Enter-key. - if (charCode >= 32 || charCode === 13) { - return charCode; - } + /** + * All of the isCustomAttribute() functions that have been injected. + */ + _isCustomAttributeFunctions: [], - return 0; -} + /** + * Checks whether a property name is a custom attribute. + * @method + */ + isCustomAttribute: function (attributeName) { + for (var i = 0; i < DOMProperty._isCustomAttributeFunctions.length; i++) { + var isCustomAttributeFn = DOMProperty._isCustomAttributeFunctions[i]; + if (isCustomAttributeFn(attributeName)) { + return true; + } + } + return false; + }, -module.exports = getEventCharCode; + injection: DOMPropertyInjection +}; -/***/ }), -/* 66 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +module.exports = DOMProperty; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -"use strict"; -Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Alert", function() { return Alert; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Container", function() { return Container; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Row", function() { return Row; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Col", function() { return Col; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Navbar", function() { return Navbar; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarBrand", function() { return NavbarBrand; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarToggler", function() { return NavbarToggler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Nav", function() { return Nav; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavItem", function() { return NavItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavDropdown", function() { return NavDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavLink", function() { return NavLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Breadcrumb", function() { return Breadcrumb; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BreadcrumbItem", function() { return BreadcrumbItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Button", function() { return Button; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonDropdown", function() { return ButtonDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonGroup", function() { return ButtonGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonToolbar", function() { return ButtonToolbar; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Dropdown", function() { return Dropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownItem", function() { return DropdownItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownMenu", function() { return DropdownMenu; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownToggle", function() { return DropdownToggle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Fade", function() { return Fade; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Badge", function() { return Badge; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Card", function() { return Card; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardLink", function() { return CardLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardGroup", function() { return CardGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardDeck", function() { return CardDeck; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardColumns", function() { return CardColumns; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardBlock", function() { return CardBlock; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardFooter", function() { return CardFooter; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardHeader", function() { return CardHeader; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImg", function() { return CardImg; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImgOverlay", function() { return CardImgOverlay; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardSubtitle", function() { return CardSubtitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardText", function() { return CardText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardTitle", function() { return CardTitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Popover", function() { return Popover; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverContent", function() { return PopoverContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverTitle", function() { return PopoverTitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Progress", function() { return Progress; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Modal", function() { return Modal; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalHeader", function() { return ModalHeader; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalBody", function() { return ModalBody; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalFooter", function() { return ModalFooter; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TetherContent", function() { return TetherContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Tooltip", function() { return Tooltip; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Table", function() { return Table; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroup", function() { return ListGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Form", function() { return Form; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormFeedback", function() { return FormFeedback; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormGroup", function() { return FormGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormText", function() { return FormText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Input", function() { return Input; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroup", function() { return InputGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupAddon", function() { return InputGroupAddon; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupButton", function() { return InputGroupButton; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Label", function() { return Label; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Media", function() { return Media; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Pagination", function() { return Pagination; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationItem", function() { return PaginationItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationLink", function() { return PaginationLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabContent", function() { return TabContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabPane", function() { return TabPane; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Jumbotron", function() { return Jumbotron; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Collapse", function() { return Collapse; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItem", function() { return ListGroupItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemText", function() { return ListGroupItemText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemHeading", function() { return ListGroupItemHeading; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledAlert", function() { return UncontrolledAlert; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledButtonDropdown", function() { return UncontrolledButtonDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledDropdown", function() { return UncontrolledDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledNavDropdown", function() { return UncontrolledNavDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledTooltip", function() { return UncontrolledTooltip; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_classnames__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject__ = __webpack_require__(222); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_lodash_isobject__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom__ = __webpack_require__(28); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_react_dom__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__ = __webpack_require__(223); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__ = __webpack_require__(224); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__ = __webpack_require__(225); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group__ = __webpack_require__(226); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8_react_transition_group__); +/***/ }), +/* 29 */ +/***/ (function(module, exports, __webpack_require__) { +var Buffer = __webpack_require__(7).Buffer +var Transform = __webpack_require__(98).Transform +var StringDecoder = __webpack_require__(102).StringDecoder +var inherits = __webpack_require__(4) +function CipherBase (hashMode) { + Transform.call(this) + this.hashMode = typeof hashMode === 'string' + if (this.hashMode) { + this[hashMode] = this._finalOrDigest + } else { + this.final = this._finalOrDigest + } + if (this._final) { + this.__final = this._final + this._final = null + } + this._decoder = null + this._encoding = null +} +inherits(CipherBase, Transform) +CipherBase.prototype.update = function (data, inputEnc, outputEnc) { + if (typeof data === 'string') { + data = Buffer.from(data, inputEnc) + } + var outData = this._update(data) + if (this.hashMode) return this + if (outputEnc) { + outData = this._toString(outData, outputEnc) + } + return outData +} +CipherBase.prototype.setAutoPadding = function () {} +CipherBase.prototype.getAuthTag = function () { + throw new Error('trying to get auth tag in unsupported state') +} +CipherBase.prototype.setAuthTag = function () { + throw new Error('trying to set auth tag in unsupported state') +} +CipherBase.prototype.setAAD = function () { + throw new Error('trying to set aad in unsupported state') +} -function getTetherAttachments(placement) { - var attachments = {}; - switch (placement) { - case 'top': - case 'top center': - attachments = { - attachment: 'bottom center', - targetAttachment: 'top center' - }; - break; - case 'bottom': - case 'bottom center': - attachments = { - attachment: 'top center', - targetAttachment: 'bottom center' - }; - break; - case 'left': - case 'left center': - attachments = { - attachment: 'middle right', - targetAttachment: 'middle left' - }; - break; - case 'right': - case 'right center': - attachments = { - attachment: 'middle left', - targetAttachment: 'middle right' - }; - break; - case 'top left': - attachments = { - attachment: 'bottom left', - targetAttachment: 'top left' - }; - break; - case 'top right': - attachments = { - attachment: 'bottom right', - targetAttachment: 'top right' - }; - break; - case 'bottom left': - attachments = { - attachment: 'top left', - targetAttachment: 'bottom left' - }; - break; - case 'bottom right': - attachments = { - attachment: 'top right', - targetAttachment: 'bottom right' - }; - break; - case 'right top': - attachments = { - attachment: 'top left', - targetAttachment: 'top right' - }; - break; - case 'right bottom': - attachments = { - attachment: 'bottom left', - targetAttachment: 'bottom right' - }; - break; - case 'left top': - attachments = { - attachment: 'top right', - targetAttachment: 'top left' - }; - break; - case 'left bottom': - attachments = { - attachment: 'bottom right', - targetAttachment: 'bottom left' - }; - break; - default: - attachments = { - attachment: 'top center', - targetAttachment: 'bottom center' - }; +CipherBase.prototype._transform = function (data, _, next) { + var err + try { + if (this.hashMode) { + this._update(data) + } else { + this.push(this._update(data)) + } + } catch (e) { + err = e + } finally { + next(err) + } +} +CipherBase.prototype._flush = function (done) { + var err + try { + this.push(this.__final()) + } catch (e) { + err = e } - return attachments; + done(err) +} +CipherBase.prototype._finalOrDigest = function (outputEnc) { + var outData = this.__final() || Buffer.alloc(0) + if (outputEnc) { + outData = this._toString(outData, outputEnc, true) + } + return outData } -var tetherAttachements = ['top', 'bottom', 'left', 'right', 'top left', 'top center', 'top right', 'right top', 'right middle', 'right bottom', 'bottom right', 'bottom center', 'bottom left', 'left top', 'left middle', 'left bottom']; +CipherBase.prototype._toString = function (value, enc, fin) { + if (!this._decoder) { + this._decoder = new StringDecoder(enc) + this._encoding = enc + } -// https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L436-L443 -function getScrollbarWidth() { - var scrollDiv = document.createElement('div'); - // .modal-scrollbar-measure styles // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/scss/_modal.scss#L106-L113 - scrollDiv.style.position = 'absolute'; - scrollDiv.style.top = '-9999px'; - scrollDiv.style.width = '50px'; - scrollDiv.style.height = '50px'; - scrollDiv.style.overflow = 'scroll'; - document.body.appendChild(scrollDiv); - var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth; - document.body.removeChild(scrollDiv); - return scrollbarWidth; -} + if (this._encoding !== enc) throw new Error('can\'t switch encodings') -function setScrollbarWidth(padding) { - document.body.style.paddingRight = padding > 0 ? padding + 'px' : null; -} + var out = this._decoder.write(value) + if (fin) { + out += this._decoder.end() + } -function isBodyOverflowing() { - return document.body.clientWidth < window.innerWidth; + return out } -function getOriginalBodyPadding() { - return parseInt(window.getComputedStyle(document.body, null).getPropertyValue('padding-right') || 0, 10); -} +module.exports = CipherBase -function conditionallyUpdateScrollbar() { - var scrollbarWidth = getScrollbarWidth(); - // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L420 - var fixedContent = document.querySelectorAll('.navbar-fixed-top, .navbar-fixed-bottom, .is-fixed')[0]; - var bodyPadding = fixedContent ? parseInt(fixedContent.style.paddingRight || 0, 10) : 0; - if (isBodyOverflowing()) { - setScrollbarWidth(bodyPadding + scrollbarWidth); - } -} +/***/ }), +/* 30 */ +/***/ (function(module, exports, __webpack_require__) { -function mapToCssModules(className, cssModule) { - if (!cssModule) return className; - return className.split(' ').map(function (c) { - return cssModule[c] || c; - }).join(' '); -} +var BigInteger = __webpack_require__(175) -/** - * Returns a new object with the key/value pairs from `obj` that are not in the array `omitKeys`. - */ -function omit(obj, omitKeys) { - var result = {}; - Object.keys(obj).forEach(function (key) { - if (omitKeys.indexOf(key) === -1) { - result[key] = obj[key]; - } - }); - return result; -} +//addons +__webpack_require__(408) -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { - return typeof obj; -} : function (obj) { - return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; -}; +module.exports = BigInteger +/***/ }), +/* 31 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ +var _assign = __webpack_require__(8); +var ReactCurrentOwner = __webpack_require__(22); +var warning = __webpack_require__(3); +var canDefineProperty = __webpack_require__(55); +var hasOwnProperty = Object.prototype.hasOwnProperty; +var REACT_ELEMENT_TYPE = __webpack_require__(121); +var RESERVED_PROPS = { + key: true, + ref: true, + __self: true, + __source: true +}; +var specialPropKeyWarningShown, specialPropRefWarningShown; -var classCallCheck = function (instance, Constructor) { - if (!(instance instanceof Constructor)) { - throw new TypeError("Cannot call a class as a function"); +function hasValidRef(config) { + if (process.env.NODE_ENV !== 'production') { + if (hasOwnProperty.call(config, 'ref')) { + var getter = Object.getOwnPropertyDescriptor(config, 'ref').get; + if (getter && getter.isReactWarning) { + return false; + } + } } -}; + return config.ref !== undefined; +} -var createClass = function () { - function defineProperties(target, props) { - for (var i = 0; i < props.length; i++) { - var descriptor = props[i]; - descriptor.enumerable = descriptor.enumerable || false; - descriptor.configurable = true; - if ("value" in descriptor) descriptor.writable = true; - Object.defineProperty(target, descriptor.key, descriptor); +function hasValidKey(config) { + if (process.env.NODE_ENV !== 'production') { + if (hasOwnProperty.call(config, 'key')) { + var getter = Object.getOwnPropertyDescriptor(config, 'key').get; + if (getter && getter.isReactWarning) { + return false; + } } } + return config.key !== undefined; +} - return function (Constructor, protoProps, staticProps) { - if (protoProps) defineProperties(Constructor.prototype, protoProps); - if (staticProps) defineProperties(Constructor, staticProps); - return Constructor; +function defineKeyPropWarningGetter(props, displayName) { + var warnAboutAccessingKey = function () { + if (!specialPropKeyWarningShown) { + specialPropKeyWarningShown = true; + process.env.NODE_ENV !== 'production' ? warning(false, '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + } }; -}(); + warnAboutAccessingKey.isReactWarning = true; + Object.defineProperty(props, 'key', { + get: warnAboutAccessingKey, + configurable: true + }); +} +function defineRefPropWarningGetter(props, displayName) { + var warnAboutAccessingRef = function () { + if (!specialPropRefWarningShown) { + specialPropRefWarningShown = true; + process.env.NODE_ENV !== 'production' ? warning(false, '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + } + }; + warnAboutAccessingRef.isReactWarning = true; + Object.defineProperty(props, 'ref', { + get: warnAboutAccessingRef, + configurable: true + }); +} + +/** + * Factory method to create a new React element. This no longer adheres to + * the class pattern, so do not use new to call it. Also, no instanceof check + * will work. Instead test $$typeof field against Symbol.for('react.element') to check + * if something is a React Element. + * + * @param {*} type + * @param {*} key + * @param {string|object} ref + * @param {*} self A *temporary* helper to detect places where `this` is + * different from the `owner` when React.createElement is called, so that we + * can warn. We want to get rid of owner and replace string `ref`s with arrow + * functions, and as long as `this` and owner are the same, there will be no + * change in behavior. + * @param {*} source An annotation object (added by a transpiler or otherwise) + * indicating filename, line number, and/or other information. + * @param {*} owner + * @param {*} props + * @internal + */ +var ReactElement = function (type, key, ref, self, source, owner, props) { + var element = { + // This tag allow us to uniquely identify this as a React Element + $$typeof: REACT_ELEMENT_TYPE, + // Built-in properties that belong on the element + type: type, + key: key, + ref: ref, + props: props, + // Record the component responsible for creating this element. + _owner: owner + }; + if (process.env.NODE_ENV !== 'production') { + // The validation flag is currently mutative. We put it on + // an external backing store so that we can freeze the whole object. + // This can be replaced with a WeakMap once they are implemented in + // commonly used development environments. + element._store = {}; -var defineProperty = function (obj, key, value) { - if (key in obj) { - Object.defineProperty(obj, key, { - value: value, - enumerable: true, - configurable: true, - writable: true - }); - } else { - obj[key] = value; + // To make comparing ReactElements easier for testing purposes, we make + // the validation flag non-enumerable (where possible, which should + // include every environment we run tests in), so the test framework + // ignores it. + if (canDefineProperty) { + Object.defineProperty(element._store, 'validated', { + configurable: false, + enumerable: false, + writable: true, + value: false + }); + // self and source are DEV only properties. + Object.defineProperty(element, '_self', { + configurable: false, + enumerable: false, + writable: false, + value: self + }); + // Two elements created in two different places should be considered + // equal for testing purposes and therefore we hide it from enumeration. + Object.defineProperty(element, '_source', { + configurable: false, + enumerable: false, + writable: false, + value: source + }); + } else { + element._store.validated = false; + element._self = self; + element._source = source; + } + if (Object.freeze) { + Object.freeze(element.props); + Object.freeze(element); + } } - return obj; + return element; }; -var _extends = Object.assign || function (target) { - for (var i = 1; i < arguments.length; i++) { - var source = arguments[i]; +/** + * Create and return a new ReactElement of the given type. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createelement + */ +ReactElement.createElement = function (type, config, children) { + var propName; - for (var key in source) { - if (Object.prototype.hasOwnProperty.call(source, key)) { - target[key] = source[key]; - } - } - } + // Reserved names are extracted + var props = {}; - return target; -}; + var key = null; + var ref = null; + var self = null; + var source = null; + if (config != null) { + if (hasValidRef(config)) { + ref = config.ref; + } + if (hasValidKey(config)) { + key = '' + config.key; + } + self = config.__self === undefined ? null : config.__self; + source = config.__source === undefined ? null : config.__source; + // Remaining properties are added to a new props object + for (propName in config) { + if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { + props[propName] = config[propName]; + } + } + } -var inherits = function (subClass, superClass) { - if (typeof superClass !== "function" && superClass !== null) { - throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); + // Children can be more than one argument, and those are transferred onto + // the newly allocated props object. + var childrenLength = arguments.length - 2; + if (childrenLength === 1) { + props.children = children; + } else if (childrenLength > 1) { + var childArray = Array(childrenLength); + for (var i = 0; i < childrenLength; i++) { + childArray[i] = arguments[i + 2]; + } + if (process.env.NODE_ENV !== 'production') { + if (Object.freeze) { + Object.freeze(childArray); + } + } + props.children = childArray; } - subClass.prototype = Object.create(superClass && superClass.prototype, { - constructor: { - value: subClass, - enumerable: false, - writable: true, - configurable: true + // Resolve default props + if (type && type.defaultProps) { + var defaultProps = type.defaultProps; + for (propName in defaultProps) { + if (props[propName] === undefined) { + props[propName] = defaultProps[propName]; + } } - }); - if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; + } + if (process.env.NODE_ENV !== 'production') { + if (key || ref) { + if (typeof props.$$typeof === 'undefined' || props.$$typeof !== REACT_ELEMENT_TYPE) { + var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type; + if (key) { + defineKeyPropWarningGetter(props, displayName); + } + if (ref) { + defineRefPropWarningGetter(props, displayName); + } + } + } + } + return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props); }; +/** + * Return a function that produces ReactElements of a given type. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createfactory + */ +ReactElement.createFactory = function (type) { + var factory = ReactElement.createElement.bind(null, type); + // Expose the type on the factory and the prototype so that it can be + // easily accessed on elements. E.g. `<Foo />.type === Foo`. + // This should not be named `constructor` since this may not be the function + // that created the element, and it may not even be a constructor. + // Legacy hook TODO: Warn if this is accessed + factory.type = type; + return factory; +}; +ReactElement.cloneAndReplaceKey = function (oldElement, newKey) { + var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props); + return newElement; +}; +/** + * Clone and return a new ReactElement using element as the starting point. + * See https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement + */ +ReactElement.cloneElement = function (element, config, children) { + var propName; + // Original props are copied + var props = _assign({}, element.props); + // Reserved names are extracted + var key = element.key; + var ref = element.ref; + // Self is preserved since the owner is preserved. + var self = element._self; + // Source is preserved since cloneElement is unlikely to be targeted by a + // transpiler, and the original source is probably a better indicator of the + // true owner. + var source = element._source; + // Owner will be preserved, unless ref is overridden + var owner = element._owner; + if (config != null) { + if (hasValidRef(config)) { + // Silently steal the ref from the parent. + ref = config.ref; + owner = ReactCurrentOwner.current; + } + if (hasValidKey(config)) { + key = '' + config.key; + } -var objectWithoutProperties = function (obj, keys) { - var target = {}; - - for (var i in obj) { - if (keys.indexOf(i) >= 0) continue; - if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; - target[i] = obj[i]; + // Remaining properties override existing props + var defaultProps; + if (element.type && element.type.defaultProps) { + defaultProps = element.type.defaultProps; + } + for (propName in config) { + if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { + if (config[propName] === undefined && defaultProps !== undefined) { + // Resolve default props + props[propName] = defaultProps[propName]; + } else { + props[propName] = config[propName]; + } + } + } } - return target; -}; - -var possibleConstructorReturn = function (self, call) { - if (!self) { - throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); + // Children can be more than one argument, and those are transferred onto + // the newly allocated props object. + var childrenLength = arguments.length - 2; + if (childrenLength === 1) { + props.children = children; + } else if (childrenLength > 1) { + var childArray = Array(childrenLength); + for (var i = 0; i < childrenLength; i++) { + childArray[i] = arguments[i + 2]; + } + props.children = childArray; } - return call && (typeof call === "object" || typeof call === "function") ? call : self; + return ReactElement(element.type, key, ref, self, source, owner, props); }; -var propTypes = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +/** + * Verifies the object is a ReactElement. + * See https://facebook.github.io/react/docs/top-level-api.html#react.isvalidelement + * @param {?object} object + * @return {boolean} True if `object` is a valid component. + * @final + */ +ReactElement.isValidElement = function (object) { + return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE; }; -var defaultProps = { - tag: 'div' -}; +module.exports = ReactElement; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var Container = function Container(props) { - var className = props.className, - cssModule = props.cssModule, - fluid = props.fluid, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'fluid', 'tag']); +/***/ }), +/* 32 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, fluid ? 'container-fluid' : 'container'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -Container.propTypes = propTypes; -Container.defaultProps = defaultProps; +var _prodInvariant = __webpack_require__(5); -var propTypes$1 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - noGutters: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var invariant = __webpack_require__(2); -var defaultProps$1 = { - tag: 'div' +/** + * Static poolers. Several custom versions for each potential number of + * arguments. A completely generic pooler is easy to implement, but would + * require accessing the `arguments` object. In each of these, `this` refers to + * the Class itself, not an instance. If any others are needed, simply add them + * here, or in their own files. + */ +var oneArgumentPooler = function (copyFieldsFrom) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, copyFieldsFrom); + return instance; + } else { + return new Klass(copyFieldsFrom); + } }; -var Row = function Row(props) { - var className = props.className, - cssModule = props.cssModule, - noGutters = props.noGutters, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'noGutters', 'tag']); - - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, noGutters ? 'no-gutters' : null, 'row'), cssModule); - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +var twoArgumentPooler = function (a1, a2) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2); + return instance; + } else { + return new Klass(a1, a2); + } }; -Row.propTypes = propTypes$1; -Row.defaultProps = defaultProps$1; - -var colWidths = ['xs', 'sm', 'md', 'lg', 'xl']; -var stringOrNumberProp = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); - -var columnProps = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - push: stringOrNumberProp, - pull: stringOrNumberProp, - offset: stringOrNumberProp -})]); +var threeArgumentPooler = function (a1, a2, a3) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3); + return instance; + } else { + return new Klass(a1, a2, a3); + } +}; -var propTypes$2 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - xs: columnProps, - sm: columnProps, - md: columnProps, - lg: columnProps, - xl: columnProps, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - widths: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.array +var fourArgumentPooler = function (a1, a2, a3, a4) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3, a4); + return instance; + } else { + return new Klass(a1, a2, a3, a4); + } }; -var defaultProps$2 = { - tag: 'div', - widths: colWidths +var standardReleaser = function (instance) { + var Klass = this; + !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; + instance.destructor(); + if (Klass.instancePool.length < Klass.poolSize) { + Klass.instancePool.push(instance); + } }; -var getColumnSizeClass = function getColumnSizeClass(isXs, colWidth, colSize) { - if (colSize === true || colSize === '') { - return isXs ? 'col' : 'col-' + colWidth; - } else if (colSize === 'auto') { - return isXs ? 'col-auto' : 'col-' + colWidth + '-auto'; +var DEFAULT_POOL_SIZE = 10; +var DEFAULT_POOLER = oneArgumentPooler; + +/** + * Augments `CopyConstructor` to be a poolable class, augmenting only the class + * itself (statically) not adding any prototypical fields. Any CopyConstructor + * you give this may have a `poolSize` property, and will look for a + * prototypical `destructor` on instances. + * + * @param {Function} CopyConstructor Constructor that can be used to reset. + * @param {Function} pooler Customizable pooler. + */ +var addPoolingTo = function (CopyConstructor, pooler) { + // Casting as any so that flow ignores the actual implementation and trusts + // it to match the type we declared + var NewKlass = CopyConstructor; + NewKlass.instancePool = []; + NewKlass.getPooled = pooler || DEFAULT_POOLER; + if (!NewKlass.poolSize) { + NewKlass.poolSize = DEFAULT_POOL_SIZE; } + NewKlass.release = standardReleaser; + return NewKlass; +}; - return isXs ? 'col-' + colSize : 'col-' + colWidth + '-' + colSize; +var PooledClass = { + addPoolingTo: addPoolingTo, + oneArgumentPooler: oneArgumentPooler, + twoArgumentPooler: twoArgumentPooler, + threeArgumentPooler: threeArgumentPooler, + fourArgumentPooler: fourArgumentPooler }; -var Col = function Col(props) { - var className = props.className, - cssModule = props.cssModule, - widths = props.widths, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'widths', 'tag']); +module.exports = PooledClass; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var colClasses = []; +/***/ }), +/* 33 */ +/***/ (function(module, exports, __webpack_require__) { - widths.forEach(function (colWidth, i) { - var columnProp = props[colWidth]; +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { - if (!i && columnProp === undefined) { - columnProp = true; - } +var base58 = __webpack_require__(363) +var createHash = __webpack_require__(27) - delete attributes[colWidth]; +// SHA256(SHA256(buffer)) +function sha256x2 (buffer) { + var tmp = createHash('sha256').update(buffer).digest() + return createHash('sha256').update(tmp).digest() +} - if (!columnProp) { - return; - } +// Encode a buffer as a base58-check encoded string +function encode (payload) { + var checksum = sha256x2(payload) - var isXs = !i; - var colClass = void 0; + return base58.encode(Buffer.concat([ + payload, + checksum + ], payload.length + 4)) +} - if (__WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default()(columnProp)) { - var _classNames; +function decodeRaw (buffer) { + var payload = buffer.slice(0, -4) + var checksum = buffer.slice(-4) + var newChecksum = sha256x2(payload) - var colSizeInterfix = isXs ? '-' : '-' + colWidth + '-'; - colClass = getColumnSizeClass(isXs, colWidth, columnProp.size); + if (checksum[0] ^ newChecksum[0] | + checksum[1] ^ newChecksum[1] | + checksum[2] ^ newChecksum[2] | + checksum[3] ^ newChecksum[3]) return - colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, colClass, columnProp.size || columnProp.size === ''), defineProperty(_classNames, 'push' + colSizeInterfix + columnProp.push, columnProp.push || columnProp.push === 0), defineProperty(_classNames, 'pull' + colSizeInterfix + columnProp.pull, columnProp.pull || columnProp.pull === 0), defineProperty(_classNames, 'offset' + colSizeInterfix + columnProp.offset, columnProp.offset || columnProp.offset === 0), _classNames))), cssModule); - } else { - colClass = getColumnSizeClass(isXs, colWidth, columnProp); - colClasses.push(colClass); - } - }); + return payload +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, colClasses), cssModule); +// Decode a base58-check encoded string to a buffer, no result if checksum is wrong +function decodeUnsafe (string) { + var buffer = base58.decodeUnsafe(string) + if (!buffer) return - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + return decodeRaw(buffer) +} -Col.propTypes = propTypes$2; -Col.defaultProps = defaultProps$2; +function decode (string) { + var buffer = base58.decode(string) + var payload = decodeRaw(buffer) + if (!payload) throw new Error('Invalid checksum') + return payload +} -var propTypes$3 = { - light: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - full: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - fixed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - sticky: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggleable: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; +module.exports = { + encode: encode, + decode: decode, + decodeUnsafe: decodeUnsafe +} -var defaultProps$3 = { - tag: 'nav', - toggleable: false -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var getToggleableClass = function getToggleableClass(toggleable) { - if (toggleable === false) { - return false; - } else if (toggleable === true || toggleable === 'xs') { - return 'navbar-toggleable'; - } +/***/ }), +/* 34 */ +/***/ (function(module, exports, __webpack_require__) { - return 'navbar-toggleable-' + toggleable; +"use strict"; +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a duplex stream is just a stream that is both readable and writable. +// Since JS doesn't have multiple prototypal inheritance, this class +// prototypally inherits from Readable, and then parasitically from +// Writable. + + + +/*<replacement>*/ + +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +/*<replacement>*/ +var objectKeys = Object.keys || function (obj) { + var keys = []; + for (var key in obj) { + keys.push(key); + }return keys; }; +/*</replacement>*/ -var Navbar = function Navbar(props) { - var _classNames; +module.exports = Duplex; - var toggleable = props.toggleable, - className = props.className, - cssModule = props.cssModule, - light = props.light, - inverse = props.inverse, - full = props.full, - fixed = props.fixed, - sticky = props.sticky, - color = props.color, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['toggleable', 'className', 'cssModule', 'light', 'inverse', 'full', 'fixed', 'sticky', 'color', 'tag']); +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ +var Readable = __webpack_require__(161); +var Writable = __webpack_require__(101); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar', getToggleableClass(toggleable), (_classNames = { - 'navbar-light': light, - 'navbar-inverse': inverse - }, defineProperty(_classNames, 'bg-' + color, color), defineProperty(_classNames, 'navbar-full', full), defineProperty(_classNames, 'fixed-' + fixed, fixed), defineProperty(_classNames, 'sticky-' + sticky, sticky), _classNames)), cssModule); +util.inherits(Duplex, Readable); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var keys = objectKeys(Writable.prototype); +for (var v = 0; v < keys.length; v++) { + var method = keys[v]; + if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method]; +} -Navbar.propTypes = propTypes$3; -Navbar.defaultProps = defaultProps$3; +function Duplex(options) { + if (!(this instanceof Duplex)) return new Duplex(options); -var propTypes$4 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + Readable.call(this, options); + Writable.call(this, options); -var defaultProps$4 = { - tag: 'a' -}; + if (options && options.readable === false) this.readable = false; -var NavbarBrand = function NavbarBrand(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + if (options && options.writable === false) this.writable = false; + this.allowHalfOpen = true; + if (options && options.allowHalfOpen === false) this.allowHalfOpen = false; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-brand'), cssModule); + this.once('end', onend); +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +// the no-half-open enforcer +function onend() { + // if we allow half-open state, or if the writable side ended, + // then we're ok. + if (this.allowHalfOpen || this._writableState.ended) return; -NavbarBrand.propTypes = propTypes$4; -NavbarBrand.defaultProps = defaultProps$4; + // no more data can be written. + // But allow more writes to happen in this tick. + processNextTick(onEndNT, this); +} -var propTypes$5 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +function onEndNT(self) { + self.end(); +} -var defaultProps$5 = { - tag: 'button', - type: 'button' -}; +Object.defineProperty(Duplex.prototype, 'destroyed', { + get: function () { + if (this._readableState === undefined || this._writableState === undefined) { + return false; + } + return this._readableState.destroyed && this._writableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (this._readableState === undefined || this._writableState === undefined) { + return; + } -var navbarToggleIcon = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('span', { className: 'navbar-toggler-icon' }); + // backward compatibility, the user is explicitly + // managing destroyed + this._readableState.destroyed = value; + this._writableState.destroyed = value; + } +}); -var NavbarToggler = function NavbarToggler(props) { - var className = props.className, - cssModule = props.cssModule, - children = props.children, - right = props.right, - left = props.left, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'right', 'left', 'tag']); +Duplex.prototype._destroy = function (err, cb) { + this.push(null); + this.end(); + processNextTick(cb, err); +}; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-toggler', right && 'navbar-toggler-right', left && 'navbar-toggler-left'), cssModule); +function forEach(xs, f) { + for (var i = 0, l = xs.length; i < l; i++) { + f(xs[i], i); + } +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { className: classes }), - children || navbarToggleIcon - ); -}; +/***/ }), +/* 35 */ +/***/ (function(module, exports, __webpack_require__) { -NavbarToggler.propTypes = propTypes$5; -NavbarToggler.defaultProps = defaultProps$5; +"use strict"; -var propTypes$6 = { - tabs: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - pills: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$6 = { - tag: 'ul' -}; +Object.defineProperty(exports, "__esModule", { + value: true +}); -var Nav = function Nav(props) { - var className = props.className, - cssModule = props.cssModule, - tabs = props.tabs, - pills = props.pills, - vertical = props.vertical, - navbar = props.navbar, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabs', 'pills', 'vertical', 'navbar', 'tag']); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +var _react = __webpack_require__(6); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, navbar ? 'navbar-nav' : 'nav', { - 'nav-tabs': tabs, - 'nav-pills': pills, - 'flex-column': vertical - }), cssModule); +var _react2 = _interopRequireDefault(_react); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var _propTypes = __webpack_require__(40); -Nav.propTypes = propTypes$6; -Nav.defaultProps = defaultProps$6; +var _propTypes2 = _interopRequireDefault(_propTypes); -var propTypes$7 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -var defaultProps$7 = { - tag: 'li' -}; +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } -var NavItem = function NavItem(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +var IconBase = function IconBase(_ref, _ref2) { + var children = _ref.children; + var color = _ref.color; + var size = _ref.size; + var style = _ref.style; + var props = _objectWithoutProperties(_ref, ['children', 'color', 'size', 'style']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); + var _ref2$reactIconBase = _ref2.reactIconBase; + var reactIconBase = _ref2$reactIconBase === undefined ? {} : _ref2$reactIconBase; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + var computedSize = size || reactIconBase.size || '1em'; + return _react2.default.createElement('svg', _extends({ + children: children, + fill: 'currentColor', + preserveAspectRatio: 'xMidYMid meet', + height: computedSize, + width: computedSize + }, reactIconBase, props, { + style: _extends({ + verticalAlign: 'middle', + color: color || reactIconBase.color + }, reactIconBase.style || {}, style) + })); }; -NavItem.propTypes = propTypes$7; -NavItem.defaultProps = defaultProps$7; - -var propTypes$10 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - arrow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object.isRequired, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - style: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +IconBase.propTypes = { + color: _propTypes2.default.string, + size: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.number]), + style: _propTypes2.default.object }; -var defaultProps$10 = { - isOpen: false, - tetherRef: function tetherRef() {} +IconBase.contextTypes = { + reactIconBase: _propTypes2.default.shape(IconBase.propTypes) }; -var TetherContent = function (_React$Component) { - inherits(TetherContent, _React$Component); +exports.default = IconBase; +module.exports = exports['default']; - function TetherContent(props) { - classCallCheck(this, TetherContent); +/***/ }), +/* 36 */ +/***/ (function(module, exports, __webpack_require__) { - var _this = possibleConstructorReturn(this, (TetherContent.__proto__ || Object.getPrototypeOf(TetherContent)).call(this, props)); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.toggle = _this.toggle.bind(_this); - return _this; - } - createClass(TetherContent, [{ - key: 'componentDidMount', - value: function componentDidMount() { - this.handleProps(); - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - this.handleProps(); - } else if (this._element) { - // rerender - this.renderIntoSubtree(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.hide(); - } - }, { - key: 'getTarget', - value: function getTarget() { - var target = this.props.tether.target; - if (__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default()(target)) { - return target(); - } +var _assign = __webpack_require__(8); - return target; - } - }, { - key: 'getTetherConfig', - value: function getTetherConfig() { - var config = _extends({}, this.props.tether); +var ReactBaseClasses = __webpack_require__(119); +var ReactChildren = __webpack_require__(216); +var ReactDOMFactories = __webpack_require__(220); +var ReactElement = __webpack_require__(31); +var ReactPropTypes = __webpack_require__(224); +var ReactVersion = __webpack_require__(226); - config.element = this._element; - config.target = this.getTarget(); - return config; - } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - var container = this._element; - if (e.target === container || !container.contains(e.target)) { - this.toggle(); - } - } - }, { - key: 'handleProps', - value: function handleProps() { - if (this.props.isOpen) { - this.show(); - } else { - this.hide(); - } - } - }, { - key: 'hide', - value: function hide() { - document.removeEventListener('click', this.handleDocumentClick, true); +var createReactClass = __webpack_require__(227); +var onlyChild = __webpack_require__(229); - if (this._element) { - document.body.removeChild(this._element); - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); - this._element = null; - } +var createElement = ReactElement.createElement; +var createFactory = ReactElement.createFactory; +var cloneElement = ReactElement.cloneElement; - if (this._tether) { - this._tether.destroy(); - this._tether = null; - this.props.tetherRef(this._tether); - } - } - }, { - key: 'show', - value: function show() { - document.addEventListener('click', this.handleDocumentClick, true); +if (process.env.NODE_ENV !== 'production') { + var lowPriorityWarning = __webpack_require__(74); + var canDefineProperty = __webpack_require__(55); + var ReactElementValidator = __webpack_require__(123); + var didWarnPropTypesDeprecated = false; + createElement = ReactElementValidator.createElement; + createFactory = ReactElementValidator.createFactory; + cloneElement = ReactElementValidator.cloneElement; +} - this._element = document.createElement('div'); - this._element.className = this.props.className; - document.body.appendChild(this._element); - this.renderIntoSubtree(); - this._tether = new __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default.a(this.getTetherConfig()); - this.props.tetherRef(this._tether); - this._tether.position(); - this._element.childNodes[0].focus(); - } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); - } +var __spread = _assign; +var createMixin = function (mixin) { + return mixin; +}; - return this.props.toggle(); - } - }, { - key: 'renderIntoSubtree', - value: function renderIntoSubtree() { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); - } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _props = this.props, - children = _props.children, - style = _props.style; +if (process.env.NODE_ENV !== 'production') { + var warnedForSpread = false; + var warnedForCreateMixin = false; + __spread = function () { + lowPriorityWarning(warnedForSpread, 'React.__spread is deprecated and should not be used. Use ' + 'Object.assign directly or another helper function with similar ' + 'semantics. You may be seeing this warning due to your compiler. ' + 'See https://fb.me/react-spread-deprecation for more details.'); + warnedForSpread = true; + return _assign.apply(null, arguments); + }; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(children, { style: style }); - } - }, { - key: 'render', - value: function render() { - return null; - } - }]); - return TetherContent; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + createMixin = function (mixin) { + lowPriorityWarning(warnedForCreateMixin, 'React.createMixin is deprecated and should not be used. ' + 'In React v16.0, it will be removed. ' + 'You can use this mixin directly instead. ' + 'See https://fb.me/createmixin-was-never-implemented for more info.'); + warnedForCreateMixin = true; + return mixin; + }; +} -TetherContent.propTypes = propTypes$10; -TetherContent.defaultProps = defaultProps$10; +var React = { + // Modern -var propTypes$11 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + Children: { + map: ReactChildren.map, + forEach: ReactChildren.forEach, + count: ReactChildren.count, + toArray: ReactChildren.toArray, + only: onlyChild + }, -var defaultProps$11 = { - tag: 'div' -}; + Component: ReactBaseClasses.Component, + PureComponent: ReactBaseClasses.PureComponent, -var contextTypes = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired -}; + createElement: createElement, + cloneElement: cloneElement, + isValidElement: ReactElement.isValidElement, -var DropdownMenu = function DropdownMenu(props, context) { - var className = props.className, - cssModule = props.cssModule, - right = props.right, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'right', 'tag']); + // Classic - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'dropdown-menu', { 'dropdown-menu-right': right }), cssModule); + PropTypes: ReactPropTypes, + createClass: createReactClass, + createFactory: createFactory, + createMixin: createMixin, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { tabIndex: '-1', 'aria-hidden': !context.isOpen, role: 'menu', className: classes })); + // This looks DOM specific but these are actually isomorphic helpers + // since they are just generating DOM strings. + DOM: ReactDOMFactories, + + version: ReactVersion, + + // Deprecated hook for JSX spread, don't use this for anything. + __spread: __spread }; -DropdownMenu.propTypes = propTypes$11; -DropdownMenu.defaultProps = defaultProps$11; -DropdownMenu.contextTypes = contextTypes; +if (process.env.NODE_ENV !== 'production') { + var warnedForCreateClass = false; + if (canDefineProperty) { + Object.defineProperty(React, 'PropTypes', { + get: function () { + lowPriorityWarning(didWarnPropTypesDeprecated, 'Accessing PropTypes via the main React package is deprecated,' + ' and will be removed in React v16.0.' + ' Use the latest available v15.* prop-types package from npm instead.' + ' For info on usage, compatibility, migration and more, see ' + 'https://fb.me/prop-types-docs'); + didWarnPropTypesDeprecated = true; + return ReactPropTypes; + } + }); -/* eslint react/no-find-dom-node: 0 */ -// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-find-dom-node.md + Object.defineProperty(React, 'createClass', { + get: function () { + lowPriorityWarning(warnedForCreateClass, 'Accessing createClass via the main React package is deprecated,' + ' and will be removed in React v16.0.' + " Use a plain JavaScript class instead. If you're not yet " + 'ready to migrate, create-react-class v15.* is available ' + 'on npm as a temporary, drop-in replacement. ' + 'For more info see https://fb.me/react-create-class'); + warnedForCreateClass = true; + return createReactClass; + } + }); + } -var propTypes$9 = { - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - dropup: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - group: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool]), - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + // React.DOM factories are deprecated. Wrap these methods so that + // invocations of the React.DOM namespace and alert users to switch + // to the `react-dom-factories` package. + React.DOM = {}; + var warnedForFactories = false; + Object.keys(ReactDOMFactories).forEach(function (factory) { + React.DOM[factory] = function () { + if (!warnedForFactories) { + lowPriorityWarning(false, 'Accessing factories like React.DOM.%s has been deprecated ' + 'and will be removed in v16.0+. Use the ' + 'react-dom-factories package instead. ' + ' Version 1.0 provides a drop-in replacement.' + ' For more info, see https://fb.me/react-dom-factories', factory); + warnedForFactories = true; + } + return ReactDOMFactories[factory].apply(ReactDOMFactories, arguments); + }; + }); +} -var defaultProps$9 = { - isOpen: false, - tag: 'div' -}; +module.exports = React; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var childContextTypes = { - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired -}; +/***/ }), +/* 37 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultTetherConfig = { - classPrefix: 'bs-tether', - classes: { element: 'dropdown', enabled: 'show' }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var Dropdown = function (_React$Component) { - inherits(Dropdown, _React$Component); - function Dropdown(props) { - classCallCheck(this, Dropdown); +/** + * WARNING: DO NOT manually require this module. + * This is a replacement for `invariant(...)` used by the error code system + * and will _only_ be required by the corresponding babel pass. + * It always throws. + */ - var _this = possibleConstructorReturn(this, (Dropdown.__proto__ || Object.getPrototypeOf(Dropdown)).call(this, props)); +function reactProdInvariant(code) { + var argCount = arguments.length - 1; - _this.addEvents = _this.addEvents.bind(_this); - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.removeEvents = _this.removeEvents.bind(_this); - _this.toggle = _this.toggle.bind(_this); - return _this; + var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; + + for (var argIdx = 0; argIdx < argCount; argIdx++) { + message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); } - createClass(Dropdown, [{ - key: 'getChildContext', - value: function getChildContext() { - return { - toggle: this.props.toggle, - isOpen: this.props.isOpen - }; - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - this.handleProps(); - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - this.handleProps(); + message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; + + var error = new Error(message); + error.name = 'Invariant Violation'; + error.framesToPop = 1; // we don't care about reactProdInvariant's own frame + + throw error; +} + +module.exports = reactProdInvariant; + +/***/ }), +/* 38 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactRef = __webpack_require__(238); +var ReactInstrumentation = __webpack_require__(19); + +var warning = __webpack_require__(3); + +/** + * Helper to call ReactRef.attachRefs with this composite component, split out + * to avoid allocations in the transaction mount-ready queue. + */ +function attachRefs() { + ReactRef.attachRefs(this, this._currentElement); +} + +var ReactReconciler = { + /** + * Initializes the component, renders markup, and registers event listeners. + * + * @param {ReactComponent} internalInstance + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?object} the containing host component instance + * @param {?object} info about the host container + * @return {?string} Rendered markup to be inserted into the DOM. + * @final + * @internal + */ + mountComponent: function (internalInstance, transaction, hostParent, hostContainerInfo, context, parentDebugID) // 0 in production and for roots + { + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeMountComponent(internalInstance._debugID, internalInstance._currentElement, parentDebugID); } } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.removeEvents(); + var markup = internalInstance.mountComponent(transaction, hostParent, hostContainerInfo, context, parentDebugID); + if (internalInstance._currentElement && internalInstance._currentElement.ref != null) { + transaction.getReactMountReady().enqueue(attachRefs, internalInstance); } - }, { - key: 'getTetherTarget', - value: function getTetherTarget() { - var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); - - return container.querySelector('[data-toggle="dropdown"]'); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onMountComponent(internalInstance._debugID); + } } - }, { - key: 'getTetherConfig', - value: function getTetherConfig(childProps) { - var _this2 = this; + return markup; + }, - var target = function target() { - return _this2.getTetherTarget(); - }; - var vElementAttach = 'top'; - var hElementAttach = 'left'; - var vTargetAttach = 'bottom'; - var hTargetAttach = 'left'; + /** + * Returns a value that can be passed to + * ReactComponentEnvironment.replaceNodeWithMarkup. + */ + getHostNode: function (internalInstance) { + return internalInstance.getHostNode(); + }, - if (childProps.right) { - hElementAttach = 'right'; - hTargetAttach = 'right'; + /** + * Releases any resources allocated by `mountComponent`. + * + * @final + * @internal + */ + unmountComponent: function (internalInstance, safely) { + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUnmountComponent(internalInstance._debugID); } - - if (this.props.dropup) { - vElementAttach = 'bottom'; - vTargetAttach = 'top'; + } + ReactRef.detachRefs(internalInstance, internalInstance._currentElement); + internalInstance.unmountComponent(safely); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUnmountComponent(internalInstance._debugID); } + } + }, - return _extends({}, defaultTetherConfig, { - attachment: vElementAttach + ' ' + hElementAttach, - targetAttachment: vTargetAttach + ' ' + hTargetAttach, - target: target - }, this.props.tether); + /** + * Update a component using a new element. + * + * @param {ReactComponent} internalInstance + * @param {ReactElement} nextElement + * @param {ReactReconcileTransaction} transaction + * @param {object} context + * @internal + */ + receiveComponent: function (internalInstance, nextElement, transaction, context) { + var prevElement = internalInstance._currentElement; + + if (nextElement === prevElement && context === internalInstance._context) { + // Since elements are immutable after the owner is rendered, + // we can do a cheap identity compare here to determine if this is a + // superfluous reconcile. It's possible for state to be mutable but such + // change should trigger an update of the owner which would recreate + // the element. We explicitly check for the existence of an owner since + // it's possible for an element created outside a composite to be + // deeply mutated and reused. + + // TODO: Bailing out early is just a perf optimization right? + // TODO: Removing the return statement should affect correctness? + return; } - }, { - key: 'addEvents', - value: function addEvents() { - document.addEventListener('click', this.handleDocumentClick, true); + + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, nextElement); + } } - }, { - key: 'removeEvents', - value: function removeEvents() { - document.removeEventListener('click', this.handleDocumentClick, true); + + var refsChanged = ReactRef.shouldUpdateRefs(prevElement, nextElement); + + if (refsChanged) { + ReactRef.detachRefs(internalInstance, prevElement); } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); - if (container.contains(e.target) && container !== e.target) { - return; - } + internalInstance.receiveComponent(nextElement, transaction, context); - this.toggle(); + if (refsChanged && internalInstance._currentElement && internalInstance._currentElement.ref != null) { + transaction.getReactMountReady().enqueue(attachRefs, internalInstance); } - }, { - key: 'handleProps', - value: function handleProps() { - if (this.props.tether) { - return; + + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); } + } + }, - if (this.props.isOpen) { - this.addEvents(); - } else { - this.removeEvents(); + /** + * Flush any dirty changes in a component. + * + * @param {ReactComponent} internalInstance + * @param {ReactReconcileTransaction} transaction + * @internal + */ + performUpdateIfNecessary: function (internalInstance, transaction, updateBatchNumber) { + if (internalInstance._updateBatchNumber !== updateBatchNumber) { + // The component's enqueued batch number should always be the current + // batch or the following one. + process.env.NODE_ENV !== 'production' ? warning(internalInstance._updateBatchNumber == null || internalInstance._updateBatchNumber === updateBatchNumber + 1, 'performUpdateIfNecessary: Unexpected batch number (current %s, ' + 'pending %s)', updateBatchNumber, internalInstance._updateBatchNumber) : void 0; + return; + } + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, internalInstance._currentElement); } } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); + internalInstance.performUpdateIfNecessary(transaction); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); } - - return this.props.toggle(); } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _this3 = this; + } +}; - var _props = this.props, - tether = _props.tether, - children = _props.children, - attrs = objectWithoutProperties(_props, ['tether', 'children']); +module.exports = ReactReconciler; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - attrs.toggle = this.toggle; +/***/ }), +/* 39 */ +/***/ (function(module, exports, __webpack_require__) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.map(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children), function (child) { - if (tether && child.type === DropdownMenu) { - var tetherConfig = _this3.getTetherConfig(child.props); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - _extends({}, attrs, { tether: tetherConfig }), - child - ); - } +"use strict"; +/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - return child; - }); - } - }, { - key: 'render', - value: function render() { - var _classNames; - var _omit = omit(this.props, ['toggle', 'tether']), - className = _omit.className, - cssModule = _omit.cssModule, - dropup = _omit.dropup, - group = _omit.group, - size = _omit.size, - Tag = _omit.tag, - isOpen = _omit.isOpen, - attributes = objectWithoutProperties(_omit, ['className', 'cssModule', 'dropup', 'group', 'size', 'tag', 'isOpen']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, (_classNames = { - 'btn-group': group - }, defineProperty(_classNames, 'btn-group-' + size, !!size), defineProperty(_classNames, 'dropdown', !group), defineProperty(_classNames, 'show', isOpen), defineProperty(_classNames, 'dropup', dropup), _classNames)), cssModule); +var DOMNamespaces = __webpack_require__(83); +var setInnerHTML = __webpack_require__(60); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { - className: classes - }), - this.renderChildren() - ); +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); +var setTextContent = __webpack_require__(135); + +var ELEMENT_NODE_TYPE = 1; +var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + +/** + * In IE (8-11) and Edge, appending nodes with no children is dramatically + * faster than appending a full subtree, so we essentially queue up the + * .appendChild calls here and apply them so each node is added to its parent + * before any children are added. + * + * In other browsers, doing so is slower or neutral compared to the other order + * (in Firefox, twice as slow) so we only do this inversion in IE. + * + * See https://github.com/spicyj/innerhtml-vs-createelement-vs-clonenode. + */ +var enableLazy = typeof document !== 'undefined' && typeof document.documentMode === 'number' || typeof navigator !== 'undefined' && typeof navigator.userAgent === 'string' && /\bEdge\/\d/.test(navigator.userAgent); + +function insertTreeChildren(tree) { + if (!enableLazy) { + return; + } + var node = tree.node; + var children = tree.children; + if (children.length) { + for (var i = 0; i < children.length; i++) { + insertTreeBefore(node, children[i], null); } - }]); - return Dropdown; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + } else if (tree.html != null) { + setInnerHTML(node, tree.html); + } else if (tree.text != null) { + setTextContent(node, tree.text); + } +} -Dropdown.propTypes = propTypes$9; -Dropdown.defaultProps = defaultProps$9; -Dropdown.childContextTypes = childContextTypes; +var insertTreeBefore = createMicrosoftUnsafeLocalFunction(function (parentNode, tree, referenceNode) { + // DocumentFragments aren't actually part of the DOM after insertion so + // appending children won't update the DOM. We need to ensure the fragment + // is properly populated first, breaking out of our lazy approach for just + // this level. Also, some <object> plugins (like Flash Player) will read + // <param> nodes immediately upon insertion into the DOM, so <object> + // must also be populated prior to insertion into the DOM. + if (tree.node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE || tree.node.nodeType === ELEMENT_NODE_TYPE && tree.node.nodeName.toLowerCase() === 'object' && (tree.node.namespaceURI == null || tree.node.namespaceURI === DOMNamespaces.html)) { + insertTreeChildren(tree); + parentNode.insertBefore(tree.node, referenceNode); + } else { + parentNode.insertBefore(tree.node, referenceNode); + insertTreeChildren(tree); + } +}); -var propTypes$8 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function replaceChildWithTree(oldNode, newTree) { + oldNode.parentNode.replaceChild(newTree.node, oldNode); + insertTreeChildren(newTree); +} -var defaultProps$8 = { - tag: 'li' -}; +function queueChild(parentTree, childTree) { + if (enableLazy) { + parentTree.children.push(childTree); + } else { + parentTree.node.appendChild(childTree.node); + } +} -var NavDropdown = function NavDropdown(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +function queueHTML(tree, html) { + if (enableLazy) { + tree.html = html; + } else { + setInnerHTML(tree.node, html); + } +} +function queueText(tree, text) { + if (enableLazy) { + tree.text = text; + } else { + setTextContent(tree.node, text); + } +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); +function toString() { + return this.node.nodeName; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({}, attributes, { tag: Tag, className: classes })); -}; +function DOMLazyTree(node) { + return { + node: node, + children: [], + html: null, + text: null, + toString: toString + }; +} -NavDropdown.propTypes = propTypes$8; -NavDropdown.defaultProps = defaultProps$8; +DOMLazyTree.insertTreeBefore = insertTreeBefore; +DOMLazyTree.replaceChildWithTree = replaceChildWithTree; +DOMLazyTree.queueChild = queueChild; +DOMLazyTree.queueHTML = queueHTML; +DOMLazyTree.queueText = queueText; -var propTypes$12 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - href: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; +module.exports = DOMLazyTree; -var defaultProps$12 = { - tag: 'a' -}; +/***/ }), +/* 40 */ +/***/ (function(module, exports, __webpack_require__) { -var NavLink = function (_React$Component) { - inherits(NavLink, _React$Component); +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ - function NavLink(props) { - classCallCheck(this, NavLink); +if (process.env.NODE_ENV !== 'production') { + var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && + Symbol.for && + Symbol.for('react.element')) || + 0xeac7; - var _this = possibleConstructorReturn(this, (NavLink.__proto__ || Object.getPrototypeOf(NavLink)).call(this, props)); + var isValidElement = function(object) { + return typeof object === 'object' && + object !== null && + object.$$typeof === REACT_ELEMENT_TYPE; + }; - _this.onClick = _this.onClick.bind(_this); - return _this; - } + // By explicitly using `prop-types` you are opting into new development behavior. + // http://fb.me/prop-types-in-prod + var throwOnDirectAccess = true; + module.exports = __webpack_require__(125)(isValidElement, throwOnDirectAccess); +} else { + // By explicitly using `prop-types` you are opting into new production behavior. + // http://fb.me/prop-types-in-prod + module.exports = __webpack_require__(316)(); +} - createClass(NavLink, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - if (this.props.href === '#') { - e.preventDefault(); - } +/***/ }), +/* 41 */ +/***/ (function(module, exports, __webpack_require__) { - if (this.props.onClick) { - this.props.onClick(e); - } - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - active = _props.active, - Tag = _props.tag, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'active', 'tag', 'getRef']); +var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! + Copyright (c) 2016 Jed Watson. + Licensed under the MIT License (MIT), see + http://jedwatson.github.io/classnames +*/ +/* global define */ +(function () { + 'use strict'; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-link', { - disabled: attributes.disabled, - active: active - }), cssModule); + var hasOwn = {}.hasOwnProperty; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, onClick: this.onClick, className: classes })); - } - }]); - return NavLink; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + function classNames () { + var classes = []; -NavLink.propTypes = propTypes$12; -NavLink.defaultProps = defaultProps$12; + for (var i = 0; i < arguments.length; i++) { + var arg = arguments[i]; + if (!arg) continue; -var propTypes$13 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var argType = typeof arg; -var defaultProps$13 = { - tag: 'ol' -}; + if (argType === 'string' || argType === 'number') { + classes.push(arg); + } else if (Array.isArray(arg)) { + classes.push(classNames.apply(null, arg)); + } else if (argType === 'object') { + for (var key in arg) { + if (hasOwn.call(arg, key) && arg[key]) { + classes.push(key); + } + } + } + } -var Breadcrumb = function Breadcrumb(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + return classes.join(' '); + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'breadcrumb'), cssModule); + if (typeof module !== 'undefined' && module.exports) { + module.exports = classNames; + } else if (true) { + // register as 'classnames', consistent with npm package name + !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function () { + return classNames; + }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); + } else { + window.classNames = classNames; + } +}()); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -Breadcrumb.propTypes = propTypes$13; -Breadcrumb.defaultProps = defaultProps$13; +/***/ }), +/* 42 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$14 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/* WEBPACK VAR INJECTION */(function(Buffer) {// prototype class for hash functions +function Hash (blockSize, finalSize) { + this._block = new Buffer(blockSize) + this._finalSize = finalSize + this._blockSize = blockSize + this._len = 0 + this._s = 0 +} -var defaultProps$14 = { - tag: 'li' -}; +Hash.prototype.update = function (data, enc) { + if (typeof data === 'string') { + enc = enc || 'utf8' + data = new Buffer(data, enc) + } -var BreadcrumbItem = function BreadcrumbItem(props) { - var className = props.className, - cssModule = props.cssModule, - active = props.active, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'active', 'tag']); + var l = this._len += data.length + var s = this._s || 0 + var f = 0 + var buffer = this._block - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, 'breadcrumb-item'), cssModule); + while (s < l) { + var t = Math.min(data.length, f + this._blockSize - (s % this._blockSize)) + var ch = (t - f) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + for (var i = 0; i < ch; i++) { + buffer[(s % this._blockSize) + i] = data[i + f] + } -BreadcrumbItem.propTypes = propTypes$14; -BreadcrumbItem.defaultProps = defaultProps$14; + s += ch + f += ch -var propTypes$15 = { - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + if ((s % this._blockSize) === 0) { + this._update(buffer) + } + } + this._s = s -var defaultProps$15 = { - color: 'secondary', - tag: 'button' -}; + return this +} -var Button = function (_React$Component) { - inherits(Button, _React$Component); +Hash.prototype.digest = function (enc) { + // Suppose the length of the message M, in bits, is l + var l = this._len * 8 - function Button(props) { - classCallCheck(this, Button); + // Append the bit 1 to the end of the message + this._block[this._len % this._blockSize] = 0x80 - var _this = possibleConstructorReturn(this, (Button.__proto__ || Object.getPrototypeOf(Button)).call(this, props)); + // and then k zero bits, where k is the smallest non-negative solution to the equation (l + 1 + k) === finalSize mod blockSize + this._block.fill(0, this._len % this._blockSize + 1) - _this.onClick = _this.onClick.bind(_this); - return _this; + if (l % (this._blockSize * 8) >= this._finalSize * 8) { + this._update(this._block) + this._block.fill(0) } - createClass(Button, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } + // to this append the block which is equal to the number l written in binary + // TODO: handle case where l is > Math.pow(2, 29) + this._block.writeInt32BE(l, this._blockSize - 4) - if (this.props.onClick) { - this.props.onClick(e); - } - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - active = _props.active, - block = _props.block, - className = _props.className, - cssModule = _props.cssModule, - color = _props.color, - outline = _props.outline, - size = _props.size, - Tag = _props.tag, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['active', 'block', 'className', 'cssModule', 'color', 'outline', 'size', 'tag', 'getRef']); + var hash = this._update(this._block) || this._hash() + return enc ? hash.toString(enc) : hash +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn', 'btn' + (outline ? '-outline' : '') + '-' + color, size ? 'btn-' + size : false, block ? 'btn-block' : false, { active: active, disabled: this.props.disabled }), cssModule); +Hash.prototype._update = function () { + throw new Error('_update must be implemented by subclass') +} - if (attributes.href && Tag === 'button') { - Tag = 'a'; - } +module.exports = Hash - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ - type: Tag === 'button' && attributes.onClick ? 'button' : undefined - }, attributes, { - className: classes, - ref: getRef, - onClick: this.onClick - })); - } - }]); - return Button; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -Button.propTypes = propTypes$15; -Button.defaultProps = defaultProps$15; +/***/ }), +/* 43 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$16 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(global, process) { -var ButtonDropdown = function ButtonDropdown(props) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({ group: true }, props)); -}; +function oldBrowser () { + throw new Error('secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11') +} -ButtonDropdown.propTypes = propTypes$16; +var Buffer = __webpack_require__(7).Buffer +var crypto = global.crypto || global.msCrypto -var propTypes$17 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +if (crypto && crypto.getRandomValues) { + module.exports = randomBytes +} else { + module.exports = oldBrowser +} -var defaultProps$16 = { - tag: 'div', - role: 'group' -}; +function randomBytes (size, cb) { + // phantomjs needs to throw + if (size > 65536) throw new Error('requested too many random bytes') + // in case browserify isn't using the Uint8Array version + var rawBytes = new global.Uint8Array(size) -var ButtonGroup = function ButtonGroup(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - vertical = props.vertical, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'vertical', 'tag']); + // This will not work in older browsers. + // See https://developer.mozilla.org/en-US/docs/Web/API/window.crypto.getRandomValues + if (size > 0) { // getRandomValues fails on IE if size == 0 + crypto.getRandomValues(rawBytes) + } + // XXX: phantomjs doesn't like a buffer being passed here + var bytes = Buffer.from(rawBytes.buffer) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, size ? 'btn-group-' + size : false, vertical ? 'btn-group-vertical' : 'btn-group'), cssModule); + if (typeof cb === 'function') { + return process.nextTick(function () { + cb(null, bytes) + }) + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + return bytes +} -ButtonGroup.propTypes = propTypes$17; -ButtonGroup.defaultProps = defaultProps$16; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) -var propTypes$18 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string -}; +/***/ }), +/* 44 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$17 = { - tag: 'div', - role: 'toolbar' -}; +var createHash = __webpack_require__(27) -var ButtonToolbar = function ButtonToolbar(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +function ripemd160 (buffer) { + return createHash('rmd160').update(buffer).digest() +} +function sha1 (buffer) { + return createHash('sha1').update(buffer).digest() +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn-toolbar'), cssModule); +function sha256 (buffer) { + return createHash('sha256').update(buffer).digest() +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +function hash160 (buffer) { + return ripemd160(sha256(buffer)) +} -ButtonToolbar.propTypes = propTypes$18; -ButtonToolbar.defaultProps = defaultProps$17; +function hash256 (buffer) { + return sha256(sha256(buffer)) +} -var propTypes$19 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - divider: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - header: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +module.exports = { + hash160: hash160, + hash256: hash256, + ripemd160: ripemd160, + sha1: sha1, + sha256: sha256 +} -var contextTypes$1 = { - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; -var defaultProps$18 = { - tag: 'button', - toggle: true -}; +/***/ }), +/* 45 */ +/***/ (function(module, exports, __webpack_require__) { -var DropdownItem = function (_React$Component) { - inherits(DropdownItem, _React$Component); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - function DropdownItem(props) { - classCallCheck(this, DropdownItem); - var _this = possibleConstructorReturn(this, (DropdownItem.__proto__ || Object.getPrototypeOf(DropdownItem)).call(this, props)); - _this.onClick = _this.onClick.bind(_this); - _this.getTabIndex = _this.getTabIndex.bind(_this); - return _this; - } +var EventPluginHub = __webpack_require__(46); +var EventPluginUtils = __webpack_require__(77); - createClass(DropdownItem, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled || this.props.header || this.props.divider) { - e.preventDefault(); - return; - } +var accumulateInto = __webpack_require__(127); +var forEachAccumulated = __webpack_require__(128); +var warning = __webpack_require__(3); - if (this.props.onClick) { - this.props.onClick(e); - } +var getListener = EventPluginHub.getListener; - if (this.props.toggle) { - this.context.toggle(); - } - } - }, { - key: 'getTabIndex', - value: function getTabIndex() { - if (this.props.disabled || this.props.header || this.props.divider) { - return '-1'; - } +/** + * Some event types have a notion of different registration names for different + * "phases" of propagation. This finds listeners by a given phase. + */ +function listenerAtPhase(inst, event, propagationPhase) { + var registrationName = event.dispatchConfig.phasedRegistrationNames[propagationPhase]; + return getListener(inst, registrationName); +} - return '0'; - } - }, { - key: 'render', - value: function render() { - var tabIndex = this.getTabIndex(); - - var _omit = omit(this.props, ['toggle']), - className = _omit.className, - cssModule = _omit.cssModule, - divider = _omit.divider, - Tag = _omit.tag, - header = _omit.header, - active = _omit.active, - props = objectWithoutProperties(_omit, ['className', 'cssModule', 'divider', 'tag', 'header', 'active']); +/** + * Tags a `SyntheticEvent` with dispatched listeners. Creating this function + * here, allows us to not have to bind or create functions for each event. + * Mutating the event's members allows us to not have to create a wrapping + * "dispatch" object that pairs the event with the listener. + */ +function accumulateDirectionalDispatches(inst, phase, event) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(inst, 'Dispatching inst must not be null') : void 0; + } + var listener = listenerAtPhase(inst, event, phase); + if (listener) { + event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); + event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); + } +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - disabled: props.disabled, - 'dropdown-item': !divider && !header, - active: active, - 'dropdown-header': header, - 'dropdown-divider': divider - }), cssModule); +/** + * Collect dispatches (must be entirely collected before dispatching - see unit + * tests). Lazily allocate the array to conserve memory. We must loop through + * each event and perform the traversal for each one. We cannot perform a + * single traversal for the entire collection of events because each event may + * have a different target. + */ +function accumulateTwoPhaseDispatchesSingle(event) { + if (event && event.dispatchConfig.phasedRegistrationNames) { + EventPluginUtils.traverseTwoPhase(event._targetInst, accumulateDirectionalDispatches, event); + } +} - if (Tag === 'button') { - if (header) { - Tag = 'h6'; - } else if (divider) { - Tag = 'div'; - } else if (props.href) { - Tag = 'a'; - } - } +/** + * Same as `accumulateTwoPhaseDispatchesSingle`, but skips over the targetID. + */ +function accumulateTwoPhaseDispatchesSingleSkipTarget(event) { + if (event && event.dispatchConfig.phasedRegistrationNames) { + var targetInst = event._targetInst; + var parentInst = targetInst ? EventPluginUtils.getParentInstance(targetInst) : null; + EventPluginUtils.traverseTwoPhase(parentInst, accumulateDirectionalDispatches, event); + } +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ - type: Tag === 'button' && (props.onClick || this.props.toggle) ? 'button' : undefined - }, props, { - tabIndex: tabIndex, - className: classes, - onClick: this.onClick - })); +/** + * Accumulates without regard to direction, does not look for phased + * registration names. Same as `accumulateDirectDispatchesSingle` but without + * requiring that the `dispatchMarker` be the same as the dispatched ID. + */ +function accumulateDispatches(inst, ignoredDirection, event) { + if (event && event.dispatchConfig.registrationName) { + var registrationName = event.dispatchConfig.registrationName; + var listener = getListener(inst, registrationName); + if (listener) { + event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); + event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); } - }]); - return DropdownItem; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + } +} -DropdownItem.propTypes = propTypes$19; -DropdownItem.defaultProps = defaultProps$18; -DropdownItem.contextTypes = contextTypes$1; +/** + * Accumulates dispatches on an `SyntheticEvent`, but only for the + * `dispatchMarker`. + * @param {SyntheticEvent} event + */ +function accumulateDirectDispatchesSingle(event) { + if (event && event.dispatchConfig.registrationName) { + accumulateDispatches(event._targetInst, null, event); + } +} -var propTypes$20 = { - caret: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - 'data-toggle': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - 'aria-haspopup': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - split: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - nav: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +function accumulateTwoPhaseDispatches(events) { + forEachAccumulated(events, accumulateTwoPhaseDispatchesSingle); +} -var defaultProps$19 = { - 'data-toggle': 'dropdown', - 'aria-haspopup': true, - color: 'secondary' -}; +function accumulateTwoPhaseDispatchesSkipTarget(events) { + forEachAccumulated(events, accumulateTwoPhaseDispatchesSingleSkipTarget); +} -var contextTypes$2 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired -}; +function accumulateEnterLeaveDispatches(leave, enter, from, to) { + EventPluginUtils.traverseEnterLeave(from, to, accumulateDispatches, leave, enter); +} -var DropdownToggle = function (_React$Component) { - inherits(DropdownToggle, _React$Component); +function accumulateDirectDispatches(events) { + forEachAccumulated(events, accumulateDirectDispatchesSingle); +} - function DropdownToggle(props) { - classCallCheck(this, DropdownToggle); +/** + * A small set of propagation patterns, each of which will accept a small amount + * of information, and generate a set of "dispatch ready event objects" - which + * are sets of events that have already been annotated with a set of dispatched + * listener functions/ids. The API is designed this way to discourage these + * propagation strategies from actually executing the dispatches, since we + * always want to collect the entire set of dispatches before executing event a + * single one. + * + * @constructor EventPropagators + */ +var EventPropagators = { + accumulateTwoPhaseDispatches: accumulateTwoPhaseDispatches, + accumulateTwoPhaseDispatchesSkipTarget: accumulateTwoPhaseDispatchesSkipTarget, + accumulateDirectDispatches: accumulateDirectDispatches, + accumulateEnterLeaveDispatches: accumulateEnterLeaveDispatches +}; - var _this = possibleConstructorReturn(this, (DropdownToggle.__proto__ || Object.getPrototypeOf(DropdownToggle)).call(this, props)); +module.exports = EventPropagators; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - _this.onClick = _this.onClick.bind(_this); - return _this; - } +/***/ }), +/* 46 */ +/***/ (function(module, exports, __webpack_require__) { - createClass(DropdownToggle, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if (this.props.nav && !this.props.tag) { - e.preventDefault(); - } - if (this.props.onClick) { - this.props.onClick(e); - } - this.context.toggle(); - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - color = _props.color, - cssModule = _props.cssModule, - caret = _props.caret, - split = _props.split, - nav = _props.nav, - tag = _props.tag, - props = objectWithoutProperties(_props, ['className', 'color', 'cssModule', 'caret', 'split', 'nav', 'tag']); +var _prodInvariant = __webpack_require__(5); - var ariaLabel = props['aria-label'] || 'Toggle Dropdown'; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - 'dropdown-toggle': caret || split, - 'dropdown-toggle-split': split, - active: this.context.isOpen, - 'nav-link': nav - }), cssModule); - var children = props.children || __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { className: 'sr-only' }, - ariaLabel - ); +var EventPluginRegistry = __webpack_require__(57); +var EventPluginUtils = __webpack_require__(77); +var ReactErrorUtils = __webpack_require__(78); - var Tag = void 0; +var accumulateInto = __webpack_require__(127); +var forEachAccumulated = __webpack_require__(128); +var invariant = __webpack_require__(2); - if (nav && !tag) { - Tag = 'a'; - props.href = '#'; - } else if (!tag) { - Tag = Button; - props.color = color; - } else { - Tag = tag; - } +/** + * Internal store for event listeners + */ +var listenerBank = {}; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, props, { - className: classes, - onClick: this.onClick, - 'aria-haspopup': 'true', - 'aria-expanded': this.context.isOpen, - children: children - })); - } - }]); - return DropdownToggle; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +/** + * Internal queue of events that have accumulated their dispatches and are + * waiting to have their dispatches executed. + */ +var eventQueue = null; -DropdownToggle.propTypes = propTypes$20; -DropdownToggle.defaultProps = defaultProps$19; -DropdownToggle.contextTypes = contextTypes$2; +/** + * Dispatches an event and releases it back into the pool, unless persistent. + * + * @param {?object} event Synthetic event to be dispatched. + * @param {boolean} simulated If the event is simulated (changes exn behavior) + * @private + */ +var executeDispatchesAndRelease = function (event, simulated) { + if (event) { + EventPluginUtils.executeDispatchesInOrder(event, simulated); -var propTypes$21 = { - baseClass: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - baseClassIn: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionAppear: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - transitionEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - transitionLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func + if (!event.isPersistent()) { + event.constructor.release(event); + } + } +}; +var executeDispatchesAndReleaseSimulated = function (e) { + return executeDispatchesAndRelease(e, true); +}; +var executeDispatchesAndReleaseTopLevel = function (e) { + return executeDispatchesAndRelease(e, false); }; -var defaultProps$20 = { - tag: 'div', - baseClass: 'fade', - baseClassIn: 'show', - transitionAppearTimeout: 0, - transitionEnterTimeout: 0, - transitionLeaveTimeout: 0, - transitionAppear: true, - transitionEnter: true, - transitionLeave: true +var getDictionaryKey = function (inst) { + // Prevents V8 performance issue: + // https://github.com/facebook/react/pull/7232 + return '.' + inst._rootNodeID; }; -var Fade = function (_React$Component) { - inherits(Fade, _React$Component); +function isInteractive(tag) { + return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; +} - function Fade(props) { - classCallCheck(this, Fade); +function shouldPreventMouseEvent(name, type, props) { + switch (name) { + case 'onClick': + case 'onClickCapture': + case 'onDoubleClick': + case 'onDoubleClickCapture': + case 'onMouseDown': + case 'onMouseDownCapture': + case 'onMouseMove': + case 'onMouseMoveCapture': + case 'onMouseUp': + case 'onMouseUpCapture': + return !!(props.disabled && isInteractive(type)); + default: + return false; + } +} - var _this = possibleConstructorReturn(this, (Fade.__proto__ || Object.getPrototypeOf(Fade)).call(this, props)); +/** + * This is a unified interface for event plugins to be installed and configured. + * + * Event plugins can implement the following properties: + * + * `extractEvents` {function(string, DOMEventTarget, string, object): *} + * Required. When a top-level event is fired, this method is expected to + * extract synthetic events that will in turn be queued and dispatched. + * + * `eventTypes` {object} + * Optional, plugins that fire events must publish a mapping of registration + * names that are used to register listeners. Values of this mapping must + * be objects that contain `registrationName` or `phasedRegistrationNames`. + * + * `executeDispatch` {function(object, function, string)} + * Optional, allows plugins to override how an event gets dispatched. By + * default, the listener is simply invoked. + * + * Each plugin that is injected into `EventsPluginHub` is immediately operable. + * + * @public + */ +var EventPluginHub = { + /** + * Methods for injecting dependencies. + */ + injection: { + /** + * @param {array} InjectedEventPluginOrder + * @public + */ + injectEventPluginOrder: EventPluginRegistry.injectEventPluginOrder, - _this.state = { - mounted: !props.transitionAppear - }; + /** + * @param {object} injectedNamesToPlugins Map from names to plugin modules. + */ + injectEventPluginsByName: EventPluginRegistry.injectEventPluginsByName + }, - _this.onLeave = _this.onLeave.bind(_this); - _this.onEnter = _this.onEnter.bind(_this); - _this.timers = []; - return _this; - } + /** + * Stores `listener` at `listenerBank[registrationName][key]`. Is idempotent. + * + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @param {function} listener The callback to store. + */ + putListener: function (inst, registrationName, listener) { + !(typeof listener === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected %s listener to be a function, instead got type %s', registrationName, typeof listener) : _prodInvariant('94', registrationName, typeof listener) : void 0; - createClass(Fade, [{ - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.timers.forEach(function (timer) { - return clearTimeout(timer); - }); - } - }, { - key: 'onEnter', - value: function onEnter(cb) { - var _this2 = this; + var key = getDictionaryKey(inst); + var bankForRegistrationName = listenerBank[registrationName] || (listenerBank[registrationName] = {}); + bankForRegistrationName[key] = listener; - return function () { - cb(); - if (_this2.props.onEnter) { - _this2.props.onEnter(); - } - }; + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.didPutListener) { + PluginModule.didPutListener(inst, registrationName, listener); } - }, { - key: 'onLeave', - value: function onLeave(cb) { - var _this3 = this; + }, - return function () { - cb(); - if (_this3.props.onLeave) { - _this3.props.onLeave(); - } - }; + /** + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @return {?function} The stored callback. + */ + getListener: function (inst, registrationName) { + // TODO: shouldPreventMouseEvent is DOM-specific and definitely should not + // live here; needs to be moved to a better place soon + var bankForRegistrationName = listenerBank[registrationName]; + if (shouldPreventMouseEvent(registrationName, inst._currentElement.type, inst._currentElement.props)) { + return null; } - }, { - key: 'componentWillAppear', - value: function componentWillAppear(cb) { - if (!this.props.transitionAppear) { - this.onEnter(cb)(); - } + var key = getDictionaryKey(inst); + return bankForRegistrationName && bankForRegistrationName[key]; + }, - this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionAppearTimeout)); - } - }, { - key: 'componentDidAppear', - value: function componentDidAppear() { - this.setState({ - mounted: true - }); + /** + * Deletes a listener from the registration bank. + * + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + */ + deleteListener: function (inst, registrationName) { + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.willDeleteListener) { + PluginModule.willDeleteListener(inst, registrationName); } - }, { - key: 'componentWillEnter', - value: function componentWillEnter(cb) { - if (!this.props.transitionEnter) { - this.onEnter(cb)(); - } - this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionEnterTimeout)); - } - }, { - key: 'componentDidEnter', - value: function componentDidEnter() { - this.setState({ - mounted: true - }); + var bankForRegistrationName = listenerBank[registrationName]; + // TODO: This should never be null -- when is it? + if (bankForRegistrationName) { + var key = getDictionaryKey(inst); + delete bankForRegistrationName[key]; } - }, { - key: 'componentWillLeave', - value: function componentWillLeave(cb) { - this.setState({ - mounted: false - }); + }, - if (!this.props.transitionLeave) { - this.onLeave(cb)(); + /** + * Deletes all listeners for the DOM element with the supplied ID. + * + * @param {object} inst The instance, which is the source of events. + */ + deleteAllListeners: function (inst) { + var key = getDictionaryKey(inst); + for (var registrationName in listenerBank) { + if (!listenerBank.hasOwnProperty(registrationName)) { + continue; } - this.timers.push(setTimeout(this.onLeave(cb), this.props.transitionLeaveTimeout)); - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - baseClass = _props.baseClass, - baseClassIn = _props.baseClassIn, - className = _props.className, - cssModule = _props.cssModule, - Tag = _props.tag; - - var attributes = omit(this.props, Object.keys(propTypes$21)); + if (!listenerBank[registrationName][key]) { + continue; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, baseClass, this.state.mounted ? baseClassIn : false), cssModule); + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.willDeleteListener) { + PluginModule.willDeleteListener(inst, registrationName); + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + delete listenerBank[registrationName][key]; } - }]); - return Fade; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + }, -Fade.propTypes = propTypes$21; -Fade.defaultProps = defaultProps$20; + /** + * Allows registered plugins an opportunity to extract events from top-level + * native browser events. + * + * @return {*} An accumulation of synthetic events. + * @internal + */ + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var events; + var plugins = EventPluginRegistry.plugins; + for (var i = 0; i < plugins.length; i++) { + // Not every plugin in the ordering may be loaded at runtime. + var possiblePlugin = plugins[i]; + if (possiblePlugin) { + var extractedEvents = possiblePlugin.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); + if (extractedEvents) { + events = accumulateInto(events, extractedEvents); + } + } + } + return events; + }, -var propTypes$22 = { - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - pill: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * Enqueues a synthetic event that should be dispatched when + * `processEventQueue` is invoked. + * + * @param {*} events An accumulation of synthetic events. + * @internal + */ + enqueueEvents: function (events) { + if (events) { + eventQueue = accumulateInto(eventQueue, events); + } + }, -var defaultProps$21 = { - color: 'default', - pill: false, - tag: 'span' -}; + /** + * Dispatches all synthetic events on the event queue. + * + * @internal + */ + processEventQueue: function (simulated) { + // Set `eventQueue` to null before processing it so that we can tell if more + // events get enqueued while processing. + var processingEventQueue = eventQueue; + eventQueue = null; + if (simulated) { + forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseSimulated); + } else { + forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseTopLevel); + } + !!eventQueue ? process.env.NODE_ENV !== 'production' ? invariant(false, 'processEventQueue(): Additional events were enqueued while processing an event queue. Support for this has not yet been implemented.') : _prodInvariant('95') : void 0; + // This would be a good time to rethrow if any of the event handlers threw. + ReactErrorUtils.rethrowCaughtError(); + }, -var Badge = function Badge(props) { - var className = props.className, - cssModule = props.cssModule, - color = props.color, - pill = props.pill, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'pill', 'tag']); + /** + * These are needed for tests only. Do not use! + */ + __purge: function () { + listenerBank = {}; + }, + __getListenerBank: function () { + return listenerBank; + } +}; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'badge', 'badge-' + color, pill ? 'badge-pill' : false), cssModule); +module.exports = EventPluginHub; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 47 */ +/***/ (function(module, exports, __webpack_require__) { -Badge.propTypes = propTypes$22; -Badge.defaultProps = defaultProps$21; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var propTypes$23 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$22 = { - tag: 'div' -}; -var Card = function Card(props) { - var className = props.className, - cssModule = props.cssModule, - color = props.color, - block = props.block, - inverse = props.inverse, - outline = props.outline, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'block', 'inverse', 'outline', 'tag']); +var SyntheticEvent = __webpack_require__(26); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card', inverse ? 'card-inverse' : false, block ? 'card-block' : false, color ? 'card' + (outline ? '-outline' : '') + '-' + color : false), cssModule); +var getEventTarget = __webpack_require__(79); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/** + * @interface UIEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var UIEventInterface = { + view: function (event) { + if (event.view) { + return event.view; + } -Card.propTypes = propTypes$23; -Card.defaultProps = defaultProps$22; + var target = getEventTarget(event); + if (target.window === target) { + // target is a window object + return target; + } -var propTypes$24 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object + var doc = target.ownerDocument; + // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. + if (doc) { + return doc.defaultView || doc.parentWindow; + } else { + return window; + } + }, + detail: function (event) { + return event.detail || 0; + } }; -var defaultProps$23 = { - tag: 'div' -}; +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticUIEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} -var CardGroup = function CardGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +SyntheticEvent.augmentClass(SyntheticUIEvent, UIEventInterface); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-group'), cssModule); +module.exports = SyntheticUIEvent; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 48 */ +/***/ (function(module, exports, __webpack_require__) { -CardGroup.propTypes = propTypes$24; -CardGroup.defaultProps = defaultProps$23; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var propTypes$25 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$24 = { - tag: 'div' -}; -var CardDeck = function CardDeck(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/** + * `ReactInstanceMap` maintains a mapping from a public facing stateful + * instance (key) and the internal representation (value). This allows public + * methods to accept the user facing instance as an argument and map them back + * to internal methods. + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-deck'), cssModule); +// TODO: Replace this with ES6: var ReactInstanceMap = new Map(); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var ReactInstanceMap = { + /** + * This API should be called `delete` but we'd have to make sure to always + * transform these to strings for IE support. When this transform is fully + * supported we can rename it. + */ + remove: function (key) { + key._reactInternalInstance = undefined; + }, -CardDeck.propTypes = propTypes$25; -CardDeck.defaultProps = defaultProps$24; + get: function (key) { + return key._reactInternalInstance; + }, -var propTypes$26 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + has: function (key) { + return key._reactInternalInstance !== undefined; + }, -var defaultProps$25 = { - tag: 'div' + set: function (key, value) { + key._reactInternalInstance = value; + } }; -var CardColumns = function CardColumns(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +module.exports = ReactInstanceMap; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-columns'), cssModule); +/***/ }), +/* 49 */ +/***/ (function(module, exports, __webpack_require__) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/* WEBPACK VAR INJECTION */(function(Buffer) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// NOTE: These type checking functions intentionally don't use `instanceof` +// because it is fragile and can be easily faked with `Object.create()`. + +function isArray(arg) { + if (Array.isArray) { + return Array.isArray(arg); + } + return objectToString(arg) === '[object Array]'; +} +exports.isArray = isArray; -CardColumns.propTypes = propTypes$26; -CardColumns.defaultProps = defaultProps$25; +function isBoolean(arg) { + return typeof arg === 'boolean'; +} +exports.isBoolean = isBoolean; -var propTypes$27 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function isNull(arg) { + return arg === null; +} +exports.isNull = isNull; -var defaultProps$26 = { - tag: 'div' -}; +function isNullOrUndefined(arg) { + return arg == null; +} +exports.isNullOrUndefined = isNullOrUndefined; -var CardBlock = function CardBlock(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +function isNumber(arg) { + return typeof arg === 'number'; +} +exports.isNumber = isNumber; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-block'), cssModule); +function isString(arg) { + return typeof arg === 'string'; +} +exports.isString = isString; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +function isSymbol(arg) { + return typeof arg === 'symbol'; +} +exports.isSymbol = isSymbol; -CardBlock.propTypes = propTypes$27; -CardBlock.defaultProps = defaultProps$26; +function isUndefined(arg) { + return arg === void 0; +} +exports.isUndefined = isUndefined; -var propTypes$28 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function isRegExp(re) { + return objectToString(re) === '[object RegExp]'; +} +exports.isRegExp = isRegExp; -var defaultProps$27 = { - tag: 'a' -}; +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} +exports.isObject = isObject; -var CardLink = function CardLink(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - getRef = props.getRef, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'getRef']); +function isDate(d) { + return objectToString(d) === '[object Date]'; +} +exports.isDate = isDate; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-link'), cssModule); +function isError(e) { + return (objectToString(e) === '[object Error]' || e instanceof Error); +} +exports.isError = isError; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); -}; +function isFunction(arg) { + return typeof arg === 'function'; +} +exports.isFunction = isFunction; + +function isPrimitive(arg) { + return arg === null || + typeof arg === 'boolean' || + typeof arg === 'number' || + typeof arg === 'string' || + typeof arg === 'symbol' || // ES6 symbol + typeof arg === 'undefined'; +} +exports.isPrimitive = isPrimitive; -CardLink.propTypes = propTypes$28; -CardLink.defaultProps = defaultProps$27; +exports.isBuffer = Buffer.isBuffer; -var propTypes$29 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function objectToString(o) { + return Object.prototype.toString.call(o); +} -var defaultProps$28 = { - tag: 'div' -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var CardFooter = function CardFooter(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/***/ }), +/* 50 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-footer'), cssModule); +"use strict"; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -CardFooter.propTypes = propTypes$29; -CardFooter.defaultProps = defaultProps$28; +var utils = __webpack_require__(25); +var assert = __webpack_require__(21); -var propTypes$30 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function BlockHash() { + this.pending = null; + this.pendingTotal = 0; + this.blockSize = this.constructor.blockSize; + this.outSize = this.constructor.outSize; + this.hmacStrength = this.constructor.hmacStrength; + this.padLength = this.constructor.padLength / 8; + this.endian = 'big'; -var defaultProps$29 = { - tag: 'div' -}; + this._delta8 = this.blockSize / 8; + this._delta32 = this.blockSize / 32; +} +exports.BlockHash = BlockHash; -var CardHeader = function CardHeader(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +BlockHash.prototype.update = function update(msg, enc) { + // Convert message to array, pad it, and join into 32bit blocks + msg = utils.toArray(msg, enc); + if (!this.pending) + this.pending = msg; + else + this.pending = this.pending.concat(msg); + this.pendingTotal += msg.length; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-header'), cssModule); + // Enough data, try updating + if (this.pending.length >= this._delta8) { + msg = this.pending; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + // Process pending data in blocks + var r = msg.length % this._delta8; + this.pending = msg.slice(msg.length - r, msg.length); + if (this.pending.length === 0) + this.pending = null; -CardHeader.propTypes = propTypes$30; -CardHeader.defaultProps = defaultProps$29; + msg = utils.join32(msg, 0, msg.length - r, this.endian); + for (var i = 0; i < msg.length; i += this._delta32) + this._update(msg, i, i + this._delta32); + } -var propTypes$31 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object + return this; }; -var defaultProps$30 = { - tag: 'img' -}; +BlockHash.prototype.digest = function digest(enc) { + this.update(this._pad()); + assert(this.pending === null); -var CardImg = function CardImg(props) { - var className = props.className, - cssModule = props.cssModule, - top = props.top, - bottom = props.bottom, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'top', 'bottom', 'tag']); + return this._digest(enc); +}; +BlockHash.prototype._pad = function pad() { + var len = this.pendingTotal; + var bytes = this._delta8; + var k = bytes - ((len + this.padLength) % bytes); + var res = new Array(k + this.padLength); + res[0] = 0x80; + for (var i = 1; i < k; i++) + res[i] = 0; + + // Append length + len <<= 3; + if (this.endian === 'big') { + for (var t = 8; t < this.padLength; t++) + res[i++] = 0; + + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = (len >>> 24) & 0xff; + res[i++] = (len >>> 16) & 0xff; + res[i++] = (len >>> 8) & 0xff; + res[i++] = len & 0xff; + } else { + res[i++] = len & 0xff; + res[i++] = (len >>> 8) & 0xff; + res[i++] = (len >>> 16) & 0xff; + res[i++] = (len >>> 24) & 0xff; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; - var cardImgClassName = 'card-img'; - if (top) { - cardImgClassName = 'card-img-top'; + for (t = 8; t < this.padLength; t++) + res[i++] = 0; } - if (bottom) { - cardImgClassName = 'card-img-bottom'; - } - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, cardImgClassName), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + return res; }; -CardImg.propTypes = propTypes$31; -CardImg.defaultProps = defaultProps$30; -var propTypes$32 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 51 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$31 = { - tag: 'div' -}; +/* WEBPACK VAR INJECTION */(function(Buffer) {module.exports = function xor (a, b) { + var length = Math.min(a.length, b.length) + var buffer = new Buffer(length) -var CardImgOverlay = function CardImgOverlay(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + for (var i = 0; i < length; ++i) { + buffer[i] = a[i] ^ b[i] + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-img-overlay'), cssModule); + return buffer +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -CardImgOverlay.propTypes = propTypes$32; -CardImgOverlay.defaultProps = defaultProps$31; +/***/ }), +/* 52 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$33 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var asn1 = exports; -var defaultProps$32 = { - tag: 'h6' -}; +asn1.bignum = __webpack_require__(11); -var CardSubtitle = function CardSubtitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +asn1.define = __webpack_require__(440).define; +asn1.base = __webpack_require__(53); +asn1.constants = __webpack_require__(192); +asn1.decoders = __webpack_require__(446); +asn1.encoders = __webpack_require__(448); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-subtitle'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 53 */ +/***/ (function(module, exports, __webpack_require__) { -CardSubtitle.propTypes = propTypes$33; -CardSubtitle.defaultProps = defaultProps$32; +var base = exports; -var propTypes$34 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +base.Reporter = __webpack_require__(443).Reporter; +base.DecoderBuffer = __webpack_require__(191).DecoderBuffer; +base.EncoderBuffer = __webpack_require__(191).EncoderBuffer; +base.Node = __webpack_require__(444); -var defaultProps$33 = { - tag: 'p' -}; -var CardText = function CardText(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/***/ }), +/* 54 */ +/***/ (function(module, exports) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-text'), cssModule); +// https://en.bitcoin.it/wiki/List_of_address_prefixes +// Dogecoin BIP32 is a proposed standard: https://bitcointalk.org/index.php?topic=409731 - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +module.exports = { + bitcoin: { + messagePrefix: '\x18Bitcoin Signed Message:\n', + bip32: { + public: 0x0488b21e, + private: 0x0488ade4 + }, + pubKeyHash: 0x00, + scriptHash: 0x05, + wif: 0x80 + }, + testnet: { + messagePrefix: '\x18Bitcoin Signed Message:\n', + bip32: { + public: 0x043587cf, + private: 0x04358394 + }, + pubKeyHash: 0x6f, + scriptHash: 0xc4, + wif: 0xef + }, + litecoin: { + messagePrefix: '\x19Litecoin Signed Message:\n', + bip32: { + public: 0x019da462, + private: 0x019d9cfe + }, + pubKeyHash: 0x30, + scriptHash: 0x32, + wif: 0xb0 + } +} -CardText.propTypes = propTypes$34; -CardText.defaultProps = defaultProps$33; -var propTypes$35 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 55 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$34 = { - tag: 'h4' -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var CardTitle = function CardTitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-title'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var canDefineProperty = false; +if (process.env.NODE_ENV !== 'production') { + try { + // $FlowFixMe https://github.com/facebook/flow/issues/285 + Object.defineProperty({}, 'x', { get: function () {} }); + canDefineProperty = true; + } catch (x) { + // IE will fail on defineProperty + } +} -CardTitle.propTypes = propTypes$35; -CardTitle.defaultProps = defaultProps$34; +module.exports = canDefineProperty; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var propTypes$36 = { - placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), - target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string.isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; - -var defaultProps$35 = { - isOpen: false, - placement: 'bottom', - toggle: function toggle() {} -}; - -var defaultTetherConfig$1 = { - classPrefix: 'bs-tether', - classes: { - element: false, - enabled: 'show' - }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; +/***/ }), +/* 56 */ +/***/ (function(module, exports, __webpack_require__) { -var Popover = function (_React$Component) { - inherits(Popover, _React$Component); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - function Popover(props) { - classCallCheck(this, Popover); - var _this = possibleConstructorReturn(this, (Popover.__proto__ || Object.getPrototypeOf(Popover)).call(this, props)); - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - return _this; - } +var emptyObject = {}; - createClass(Popover, [{ - key: 'getTetherConfig', - value: function getTetherConfig() { - var attachments = getTetherAttachments(this.props.placement); - return _extends({}, defaultTetherConfig$1, attachments, { - target: '#' + this.props.target - }, this.props.tether); - } - }, { - key: 'render', - value: function render() { - if (!this.props.isOpen) { - return null; - } +if (process.env.NODE_ENV !== 'production') { + Object.freeze(emptyObject); +} - var tetherConfig = this.getTetherConfig(); +module.exports = emptyObject; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('popover-inner', this.props.className), this.props.cssModule); +/***/ }), +/* 57 */ +/***/ (function(module, exports, __webpack_require__) { - var attributes = omit(this.props, Object.keys(propTypes$36)); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - { - className: mapToCssModules('popover', this.props.cssModule), - tether: tetherConfig, - tetherRef: this.props.tetherRef, - isOpen: this.props.isOpen, - toggle: this.props.toggle - }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { className: classes })) - ); - } - }]); - return Popover; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -Popover.propTypes = propTypes$36; -Popover.defaultProps = defaultProps$35; -var propTypes$37 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var _prodInvariant = __webpack_require__(5); -var defaultProps$36 = { - tag: 'h3' -}; +var invariant = __webpack_require__(2); -var PopoverTitle = function PopoverTitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/** + * Injectable ordering of event plugins. + */ +var eventPluginOrder = null; +/** + * Injectable mapping from names to event plugin modules. + */ +var namesToPlugins = {}; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-title'), cssModule); +/** + * Recomputes the plugin list using the injected plugins and plugin ordering. + * + * @private + */ +function recomputePluginOrdering() { + if (!eventPluginOrder) { + // Wait until an `eventPluginOrder` is injected. + return; + } + for (var pluginName in namesToPlugins) { + var pluginModule = namesToPlugins[pluginName]; + var pluginIndex = eventPluginOrder.indexOf(pluginName); + !(pluginIndex > -1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugins that do not exist in the plugin ordering, `%s`.', pluginName) : _prodInvariant('96', pluginName) : void 0; + if (EventPluginRegistry.plugins[pluginIndex]) { + continue; + } + !pluginModule.extractEvents ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Event plugins must implement an `extractEvents` method, but `%s` does not.', pluginName) : _prodInvariant('97', pluginName) : void 0; + EventPluginRegistry.plugins[pluginIndex] = pluginModule; + var publishedEvents = pluginModule.eventTypes; + for (var eventName in publishedEvents) { + !publishEventForPlugin(publishedEvents[eventName], pluginModule, eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Failed to publish event `%s` for plugin `%s`.', eventName, pluginName) : _prodInvariant('98', eventName, pluginName) : void 0; + } + } +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/** + * Publishes an event so that it can be dispatched by the supplied plugin. + * + * @param {object} dispatchConfig Dispatch configuration for the event. + * @param {object} PluginModule Plugin publishing the event. + * @return {boolean} True if the event was successfully published. + * @private + */ +function publishEventForPlugin(dispatchConfig, pluginModule, eventName) { + !!EventPluginRegistry.eventNameDispatchConfigs.hasOwnProperty(eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same event name, `%s`.', eventName) : _prodInvariant('99', eventName) : void 0; + EventPluginRegistry.eventNameDispatchConfigs[eventName] = dispatchConfig; -PopoverTitle.propTypes = propTypes$37; -PopoverTitle.defaultProps = defaultProps$36; + var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; + if (phasedRegistrationNames) { + for (var phaseName in phasedRegistrationNames) { + if (phasedRegistrationNames.hasOwnProperty(phaseName)) { + var phasedRegistrationName = phasedRegistrationNames[phaseName]; + publishRegistrationName(phasedRegistrationName, pluginModule, eventName); + } + } + return true; + } else if (dispatchConfig.registrationName) { + publishRegistrationName(dispatchConfig.registrationName, pluginModule, eventName); + return true; + } + return false; +} -var propTypes$38 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/** + * Publishes a registration name that is used to identify dispatched events and + * can be used with `EventPluginHub.putListener` to register listeners. + * + * @param {string} registrationName Registration name to add. + * @param {object} PluginModule Plugin publishing the event. + * @private + */ +function publishRegistrationName(registrationName, pluginModule, eventName) { + !!EventPluginRegistry.registrationNameModules[registrationName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same registration name, `%s`.', registrationName) : _prodInvariant('100', registrationName) : void 0; + EventPluginRegistry.registrationNameModules[registrationName] = pluginModule; + EventPluginRegistry.registrationNameDependencies[registrationName] = pluginModule.eventTypes[eventName].dependencies; -var defaultProps$37 = { - tag: 'div' -}; + if (process.env.NODE_ENV !== 'production') { + var lowerCasedName = registrationName.toLowerCase(); + EventPluginRegistry.possibleRegistrationNames[lowerCasedName] = registrationName; -var PopoverContent = function PopoverContent(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + if (registrationName === 'onDoubleClick') { + EventPluginRegistry.possibleRegistrationNames.ondblclick = registrationName; + } + } +} +/** + * Registers plugins so that they can extract and dispatch events. + * + * @see {EventPluginHub} + */ +var EventPluginRegistry = { + /** + * Ordered list of injected plugins. + */ + plugins: [], - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-content'), cssModule); + /** + * Mapping from event name to dispatch config + */ + eventNameDispatchConfigs: {}, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + /** + * Mapping from registration name to plugin module + */ + registrationNameModules: {}, -PopoverContent.propTypes = propTypes$38; -PopoverContent.defaultProps = defaultProps$37; + /** + * Mapping from registration name to event name + */ + registrationNameDependencies: {}, -var propTypes$39 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - bar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - multi: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - value: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - max: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - animated: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - barClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * Mapping from lowercase registration names to the properly cased version, + * used to warn in the case of missing event handlers. Available + * only in __DEV__. + * @type {Object} + */ + possibleRegistrationNames: process.env.NODE_ENV !== 'production' ? {} : null, + // Trust the developer to only use possibleRegistrationNames in __DEV__ -var defaultProps$38 = { - tag: 'div', - value: 0, - max: 100 -}; + /** + * Injects an ordering of plugins (by plugin name). This allows the ordering + * to be decoupled from injection of the actual plugins so that ordering is + * always deterministic regardless of packaging, on-the-fly injection, etc. + * + * @param {array} InjectedEventPluginOrder + * @internal + * @see {EventPluginHub.injection.injectEventPluginOrder} + */ + injectEventPluginOrder: function (injectedEventPluginOrder) { + !!eventPluginOrder ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugin ordering more than once. You are likely trying to load more than one copy of React.') : _prodInvariant('101') : void 0; + // Clone the ordering so it cannot be dynamically mutated. + eventPluginOrder = Array.prototype.slice.call(injectedEventPluginOrder); + recomputePluginOrdering(); + }, -var Progress = function Progress(props) { - var children = props.children, - className = props.className, - barClassName = props.barClassName, - cssModule = props.cssModule, - value = props.value, - max = props.max, - animated = props.animated, - striped = props.striped, - color = props.color, - bar = props.bar, - multi = props.multi, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['children', 'className', 'barClassName', 'cssModule', 'value', 'max', 'animated', 'striped', 'color', 'bar', 'multi', 'tag']); + /** + * Injects plugins to be used by `EventPluginHub`. The plugin names must be + * in the ordering injected by `injectEventPluginOrder`. + * + * Plugins can be injected as part of page initialization or on-the-fly. + * + * @param {object} injectedNamesToPlugins Map from names to plugin modules. + * @internal + * @see {EventPluginHub.injection.injectEventPluginsByName} + */ + injectEventPluginsByName: function (injectedNamesToPlugins) { + var isOrderingDirty = false; + for (var pluginName in injectedNamesToPlugins) { + if (!injectedNamesToPlugins.hasOwnProperty(pluginName)) { + continue; + } + var pluginModule = injectedNamesToPlugins[pluginName]; + if (!namesToPlugins.hasOwnProperty(pluginName) || namesToPlugins[pluginName] !== pluginModule) { + !!namesToPlugins[pluginName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject two different event plugins using the same name, `%s`.', pluginName) : _prodInvariant('102', pluginName) : void 0; + namesToPlugins[pluginName] = pluginModule; + isOrderingDirty = true; + } + } + if (isOrderingDirty) { + recomputePluginOrdering(); + } + }, + /** + * Looks up the plugin for the supplied event. + * + * @param {object} event A synthetic event. + * @return {?object} The plugin that created the supplied event. + * @internal + */ + getPluginModuleForEvent: function (event) { + var dispatchConfig = event.dispatchConfig; + if (dispatchConfig.registrationName) { + return EventPluginRegistry.registrationNameModules[dispatchConfig.registrationName] || null; + } + if (dispatchConfig.phasedRegistrationNames !== undefined) { + // pulling phasedRegistrationNames out of dispatchConfig helps Flow see + // that it is not undefined. + var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; - var percent = __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(value) / __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(max) * 100; + for (var phase in phasedRegistrationNames) { + if (!phasedRegistrationNames.hasOwnProperty(phase)) { + continue; + } + var pluginModule = EventPluginRegistry.registrationNameModules[phasedRegistrationNames[phase]]; + if (pluginModule) { + return pluginModule; + } + } + } + return null; + }, - var progressClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'progress'), cssModule); + /** + * Exposed for unit testing. + * @private + */ + _resetEventPlugins: function () { + eventPluginOrder = null; + for (var pluginName in namesToPlugins) { + if (namesToPlugins.hasOwnProperty(pluginName)) { + delete namesToPlugins[pluginName]; + } + } + EventPluginRegistry.plugins.length = 0; - var progressBarClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('progress-bar', bar ? className || barClassName : barClassName, animated ? 'progress-bar-animated' : null, color ? 'bg-' + color : null, striped || animated ? 'progress-bar-striped' : null), cssModule); + var eventNameDispatchConfigs = EventPluginRegistry.eventNameDispatchConfigs; + for (var eventName in eventNameDispatchConfigs) { + if (eventNameDispatchConfigs.hasOwnProperty(eventName)) { + delete eventNameDispatchConfigs[eventName]; + } + } - var ProgressBar = multi ? children : __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { - className: progressBarClasses, - style: { width: percent + '%' }, - role: 'progressbar', - 'aria-valuenow': value, - 'aria-valuemin': '0', - 'aria-valuemax': max, - children: children - }); + var registrationNameModules = EventPluginRegistry.registrationNameModules; + for (var registrationName in registrationNameModules) { + if (registrationNameModules.hasOwnProperty(registrationName)) { + delete registrationNameModules[registrationName]; + } + } - if (bar) { - return ProgressBar; + if (process.env.NODE_ENV !== 'production') { + var possibleRegistrationNames = EventPluginRegistry.possibleRegistrationNames; + for (var lowerCasedName in possibleRegistrationNames) { + if (possibleRegistrationNames.hasOwnProperty(lowerCasedName)) { + delete possibleRegistrationNames[lowerCasedName]; + } + } + } } - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: progressClasses, children: ProgressBar })); }; -Progress.propTypes = propTypes$39; -Progress.defaultProps = defaultProps$38; - -var propTypes$40 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - autoFocus: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - keyboard: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - backdrop: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(['static'])]), - onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onExit: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - wrapClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - modalClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - backdropClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - contentClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - fade: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - zIndex: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - backdropTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number -}; +module.exports = EventPluginRegistry; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var propsToOmit = Object.keys(propTypes$40); +/***/ }), +/* 58 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$39 = { - isOpen: false, - autoFocus: true, - backdrop: true, - keyboard: true, - zIndex: 1050, - fade: true, - modalTransitionTimeout: 300, - backdropTransitionTimeout: 150 -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var Modal = function (_React$Component) { - inherits(Modal, _React$Component); - function Modal(props) { - classCallCheck(this, Modal); - var _this = possibleConstructorReturn(this, (Modal.__proto__ || Object.getPrototypeOf(Modal)).call(this, props)); +var _prodInvariant = __webpack_require__(5); - _this.originalBodyPadding = null; - _this.isBodyOverflowing = false; - _this.togglePortal = _this.togglePortal.bind(_this); - _this.handleBackdropClick = _this.handleBackdropClick.bind(_this); - _this.handleEscape = _this.handleEscape.bind(_this); - _this.destroy = _this.destroy.bind(_this); - _this.onEnter = _this.onEnter.bind(_this); - _this.onExit = _this.onExit.bind(_this); - return _this; - } +var invariant = __webpack_require__(2); - createClass(Modal, [{ - key: 'componentDidMount', - value: function componentDidMount() { - if (this.props.isOpen) { - this.togglePortal(); - } - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - // handle portal events/dom updates - this.togglePortal(); - } else if (this._element) { - // rerender portal - this.renderIntoSubtree(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.onExit(); - } - }, { - key: 'onEnter', - value: function onEnter() { - if (this.props.onEnter) { - this.props.onEnter(); - } - } - }, { - key: 'onExit', - value: function onExit() { - this.destroy(); - if (this.props.onExit) { - this.props.onExit(); - } - } - }, { - key: 'handleEscape', - value: function handleEscape(e) { - if (this.props.keyboard && e.keyCode === 27 && this.props.toggle) { - this.props.toggle(); - } - } - }, { - key: 'handleBackdropClick', - value: function handleBackdropClick(e) { - if (this.props.backdrop !== true) return; +var OBSERVED_ERROR = {}; - var container = this._dialog; +/** + * `Transaction` creates a black box that is able to wrap any method such that + * certain invariants are maintained before and after the method is invoked + * (Even if an exception is thrown while invoking the wrapped method). Whoever + * instantiates a transaction can provide enforcers of the invariants at + * creation time. The `Transaction` class itself will supply one additional + * automatic invariant for you - the invariant that any transaction instance + * should not be run while it is already being run. You would typically create a + * single instance of a `Transaction` for reuse multiple times, that potentially + * is used to wrap several different methods. Wrappers are extremely simple - + * they only require implementing two methods. + * + * <pre> + * wrappers (injected at creation time) + * + + + * | | + * +-----------------|--------|--------------+ + * | v | | + * | +---------------+ | | + * | +--| wrapper1 |---|----+ | + * | | +---------------+ v | | + * | | +-------------+ | | + * | | +----| wrapper2 |--------+ | + * | | | +-------------+ | | | + * | | | | | | + * | v v v v | wrapper + * | +---+ +---+ +---------+ +---+ +---+ | invariants + * perform(anyMethod) | | | | | | | | | | | | maintained + * +----------------->|-|---|-|---|-->|anyMethod|---|---|-|---|-|--------> + * | | | | | | | | | | | | + * | | | | | | | | | | | | + * | | | | | | | | | | | | + * | +---+ +---+ +---------+ +---+ +---+ | + * | initialize close | + * +-----------------------------------------+ + * </pre> + * + * Use cases: + * - Preserving the input selection ranges before/after reconciliation. + * Restoring selection even in the event of an unexpected error. + * - Deactivating events while rearranging the DOM, preventing blurs/focuses, + * while guaranteeing that afterwards, the event system is reactivated. + * - Flushing a queue of collected DOM mutations to the main UI thread after a + * reconciliation takes place in a worker thread. + * - Invoking any collected `componentDidUpdate` callbacks after rendering new + * content. + * - (Future use case): Wrapping particular flushes of the `ReactWorker` queue + * to preserve the `scrollTop` (an automatic scroll aware DOM). + * - (Future use case): Layout calculations before and after DOM updates. + * + * Transactional plugin API: + * - A module that has an `initialize` method that returns any precomputation. + * - and a `close` method that accepts the precomputation. `close` is invoked + * when the wrapped process is completed, or has failed. + * + * @param {Array<TransactionalWrapper>} transactionWrapper Wrapper modules + * that implement `initialize` and `close`. + * @return {Transaction} Single transaction for reuse in thread. + * + * @class Transaction + */ +var TransactionImpl = { + /** + * Sets up this instance so that it is prepared for collecting metrics. Does + * so such that this setup method may be used on an instance that is already + * initialized, in a way that does not consume additional memory upon reuse. + * That can be useful if you decide to make your subclass of this mixin a + * "PooledClass". + */ + reinitializeTransaction: function () { + this.transactionWrappers = this.getTransactionWrappers(); + if (this.wrapperInitData) { + this.wrapperInitData.length = 0; + } else { + this.wrapperInitData = []; + } + this._isInTransaction = false; + }, + + _isInTransaction: false, + + /** + * @abstract + * @return {Array<TransactionWrapper>} Array of transaction wrappers. + */ + getTransactionWrappers: null, + + isInTransaction: function () { + return !!this._isInTransaction; + }, + + /* eslint-disable space-before-function-paren */ + + /** + * Executes the function within a safety window. Use this for the top level + * methods that result in large amounts of computation/mutations that would + * need to be safety checked. The optional arguments helps prevent the need + * to bind in many cases. + * + * @param {function} method Member of scope to call. + * @param {Object} scope Scope to invoke from. + * @param {Object?=} a Argument to pass to the method. + * @param {Object?=} b Argument to pass to the method. + * @param {Object?=} c Argument to pass to the method. + * @param {Object?=} d Argument to pass to the method. + * @param {Object?=} e Argument to pass to the method. + * @param {Object?=} f Argument to pass to the method. + * + * @return {*} Return value from `method`. + */ + perform: function (method, scope, a, b, c, d, e, f) { + /* eslint-enable space-before-function-paren */ + !!this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.perform(...): Cannot initialize a transaction when there is already an outstanding transaction.') : _prodInvariant('27') : void 0; + var errorThrown; + var ret; + try { + this._isInTransaction = true; + // Catching errors makes debugging more difficult, so we start with + // errorThrown set to true before setting it to false after calling + // close -- if it's still set to true in the finally block, it means + // one of these calls threw. + errorThrown = true; + this.initializeAll(0); + ret = method.call(scope, a, b, c, d, e, f); + errorThrown = false; + } finally { + try { + if (errorThrown) { + // If `method` throws, prefer to show that stack trace over any thrown + // by invoking `closeAll`. + try { + this.closeAll(0); + } catch (err) {} + } else { + // Since `method` didn't throw, we don't want to silence the exception + // here. + this.closeAll(0); + } + } finally { + this._isInTransaction = false; + } + } + return ret; + }, + + initializeAll: function (startIndex) { + var transactionWrappers = this.transactionWrappers; + for (var i = startIndex; i < transactionWrappers.length; i++) { + var wrapper = transactionWrappers[i]; + try { + // Catching errors makes debugging more difficult, so we start with the + // OBSERVED_ERROR state before overwriting it with the real return value + // of initialize -- if it's still set to OBSERVED_ERROR in the finally + // block, it means wrapper.initialize threw. + this.wrapperInitData[i] = OBSERVED_ERROR; + this.wrapperInitData[i] = wrapper.initialize ? wrapper.initialize.call(this) : null; + } finally { + if (this.wrapperInitData[i] === OBSERVED_ERROR) { + // The initializer for wrapper i threw an error; initialize the + // remaining wrappers but silence any exceptions from them to ensure + // that the first error is the one to bubble up. + try { + this.initializeAll(i + 1); + } catch (err) {} + } + } + } + }, + + /** + * Invokes each of `this.transactionWrappers.close[i]` functions, passing into + * them the respective return values of `this.transactionWrappers.init[i]` + * (`close`rs that correspond to initializers that failed will not be + * invoked). + */ + closeAll: function (startIndex) { + !this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.closeAll(): Cannot close transaction when none are open.') : _prodInvariant('28') : void 0; + var transactionWrappers = this.transactionWrappers; + for (var i = startIndex; i < transactionWrappers.length; i++) { + var wrapper = transactionWrappers[i]; + var initData = this.wrapperInitData[i]; + var errorThrown; + try { + // Catching errors makes debugging more difficult, so we start with + // errorThrown set to true before setting it to false after calling + // close -- if it's still set to true in the finally block, it means + // wrapper.close threw. + errorThrown = true; + if (initData !== OBSERVED_ERROR && wrapper.close) { + wrapper.close.call(this, initData); + } + errorThrown = false; + } finally { + if (errorThrown) { + // The closer for wrapper i threw an error; close the remaining + // wrappers but silence any exceptions from them to ensure that the + // first error is the one to bubble up. + try { + this.closeAll(i + 1); + } catch (e) {} + } + } + } + this.wrapperInitData.length = 0; + } +}; + +module.exports = TransactionImpl; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 59 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticUIEvent = __webpack_require__(47); +var ViewportMetrics = __webpack_require__(134); + +var getEventModifierState = __webpack_require__(81); + +/** + * @interface MouseEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var MouseEventInterface = { + screenX: null, + screenY: null, + clientX: null, + clientY: null, + ctrlKey: null, + shiftKey: null, + altKey: null, + metaKey: null, + getModifierState: getEventModifierState, + button: function (event) { + // Webkit, Firefox, IE9+ + // which: 1 2 3 + // button: 0 1 2 (standard) + var button = event.button; + if ('which' in event) { + return button; + } + // IE<9 + // which: undefined + // button: 0 0 0 + // button: 1 4 2 (onmouseup) + return button === 2 ? 2 : button === 4 ? 1 : 0; + }, + buttons: null, + relatedTarget: function (event) { + return event.relatedTarget || (event.fromElement === event.srcElement ? event.toElement : event.fromElement); + }, + // "Proprietary" Interface. + pageX: function (event) { + return 'pageX' in event ? event.pageX : event.clientX + ViewportMetrics.currentScrollLeft; + }, + pageY: function (event) { + return 'pageY' in event ? event.pageY : event.clientY + ViewportMetrics.currentScrollTop; + } +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticMouseEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticUIEvent.augmentClass(SyntheticMouseEvent, MouseEventInterface); + +module.exports = SyntheticMouseEvent; + +/***/ }), +/* 60 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); +var DOMNamespaces = __webpack_require__(83); + +var WHITESPACE_TEST = /^[ \r\n\t\f]/; +var NONVISIBLE_TEST = /<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/; + +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); + +// SVG temp container for IE lacking innerHTML +var reusableSVGContainer; + +/** + * Set the innerHTML property of a node, ensuring that whitespace is preserved + * even in IE8. + * + * @param {DOMElement} node + * @param {string} html + * @internal + */ +var setInnerHTML = createMicrosoftUnsafeLocalFunction(function (node, html) { + // IE does not have innerHTML for SVG nodes, so instead we inject the + // new markup in a temp node and then move the child nodes across into + // the target node + if (node.namespaceURI === DOMNamespaces.svg && !('innerHTML' in node)) { + reusableSVGContainer = reusableSVGContainer || document.createElement('div'); + reusableSVGContainer.innerHTML = '<svg>' + html + '</svg>'; + var svgNode = reusableSVGContainer.firstChild; + while (svgNode.firstChild) { + node.appendChild(svgNode.firstChild); + } + } else { + node.innerHTML = html; + } +}); + +if (ExecutionEnvironment.canUseDOM) { + // IE8: When updating a just created node with innerHTML only leading + // whitespace is removed. When updating an existing node with innerHTML + // whitespace in root TextNodes is also collapsed. + // @see quirksmode.org/bugreports/archives/2004/11/innerhtml_and_t.html + + // Feature detection; only IE8 is known to behave improperly like this. + var testElement = document.createElement('div'); + testElement.innerHTML = ' '; + if (testElement.innerHTML === '') { + setInnerHTML = function (node, html) { + // Magic theory: IE8 supposedly differentiates between added and updated + // nodes when processing innerHTML, innerHTML on updated nodes suffers + // from worse whitespace behavior. Re-adding a node like this triggers + // the initial and more favorable whitespace behavior. + // TODO: What to do on a detached node? + if (node.parentNode) { + node.parentNode.replaceChild(node, node); + } + + // We also implement a workaround for non-visible tags disappearing into + // thin air on IE8, this only happens if there is no visible text + // in-front of the non-visible tags. Piggyback on the whitespace fix + // and simply check if any non-visible tags appear in the source. + if (WHITESPACE_TEST.test(html) || html[0] === '<' && NONVISIBLE_TEST.test(html)) { + // Recover leading whitespace by temporarily prepending any character. + // \uFEFF has the potential advantage of being zero-width/invisible. + // UglifyJS drops U+FEFF chars when parsing, so use String.fromCharCode + // in hopes that this is preserved even if "\uFEFF" is transformed to + // the actual Unicode character (by Babel, for example). + // https://github.com/mishoo/UglifyJS2/blob/v2.4.20/lib/parse.js#L216 + node.innerHTML = String.fromCharCode(0xfeff) + html; + + // deleteData leaves an empty `TextNode` which offsets the index of all + // children. Definitely want to avoid this. + var textNode = node.firstChild; + if (textNode.data.length === 1) { + node.removeChild(textNode); + } else { + textNode.deleteData(0, 1); + } + } else { + node.innerHTML = html; + } + }; + } + testElement = null; +} + +module.exports = setInnerHTML; + +/***/ }), +/* 61 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * Based on the escape-html library, which is used under the MIT License below: + * + * Copyright (c) 2012-2013 TJ Holowaychuk + * Copyright (c) 2015 Andreas Lubbe + * Copyright (c) 2015 Tiancheng "Timothy" Gu + * + * Permission is hereby granted, free of charge, to any person obtaining + * a copy of this software and associated documentation files (the + * 'Software'), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sublicense, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice shall be + * included in all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. + * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY + * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + */ + + + +// code copied and modified from escape-html +/** + * Module variables. + * @private + */ + +var matchHtmlRegExp = /["'&<>]/; + +/** + * Escape special characters in the given string of html. + * + * @param {string} string The string to escape for inserting into HTML + * @return {string} + * @public + */ + +function escapeHtml(string) { + var str = '' + string; + var match = matchHtmlRegExp.exec(str); + + if (!match) { + return str; + } + + var escape; + var html = ''; + var index = 0; + var lastIndex = 0; + + for (index = match.index; index < str.length; index++) { + switch (str.charCodeAt(index)) { + case 34: + // " + escape = '"'; + break; + case 38: + // & + escape = '&'; + break; + case 39: + // ' + escape = '''; // modified from escape-html; used to be ''' + break; + case 60: + // < + escape = '<'; + break; + case 62: + // > + escape = '>'; + break; + default: + continue; + } + + if (lastIndex !== index) { + html += str.substring(lastIndex, index); + } + + lastIndex = index + 1; + html += escape; + } + + return lastIndex !== index ? html + str.substring(lastIndex, index) : html; +} +// end code copied and modified from escape-html + +/** + * Escapes text to prevent scripting attacks. + * + * @param {*} text Text value to escape. + * @return {string} An escaped string. + */ +function escapeTextContentForBrowser(text) { + if (typeof text === 'boolean' || typeof text === 'number') { + // this shortcircuit helps perf for types that we know will never have + // special characters, especially given that this function is used often + // for numeric dom ids. + return '' + text; + } + return escapeHtml(text); +} + +module.exports = escapeTextContentForBrowser; + +/***/ }), +/* 62 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var EventPluginRegistry = __webpack_require__(57); +var ReactEventEmitterMixin = __webpack_require__(264); +var ViewportMetrics = __webpack_require__(134); + +var getVendorPrefixedEventName = __webpack_require__(265); +var isEventSupported = __webpack_require__(80); + +/** + * Summary of `ReactBrowserEventEmitter` event handling: + * + * - Top-level delegation is used to trap most native browser events. This + * may only occur in the main thread and is the responsibility of + * ReactEventListener, which is injected and can therefore support pluggable + * event sources. This is the only work that occurs in the main thread. + * + * - We normalize and de-duplicate events to account for browser quirks. This + * may be done in the worker thread. + * + * - Forward these native events (with the associated top-level type used to + * trap it) to `EventPluginHub`, which in turn will ask plugins if they want + * to extract any synthetic events. + * + * - The `EventPluginHub` will then process each event by annotating them with + * "dispatches", a sequence of listeners and IDs that care about that event. + * + * - The `EventPluginHub` then dispatches the events. + * + * Overview of React and the event system: + * + * +------------+ . + * | DOM | . + * +------------+ . + * | . + * v . + * +------------+ . + * | ReactEvent | . + * | Listener | . + * +------------+ . +-----------+ + * | . +--------+|SimpleEvent| + * | . | |Plugin | + * +-----|------+ . v +-----------+ + * | | | . +--------------+ +------------+ + * | +-----------.--->|EventPluginHub| | Event | + * | | . | | +-----------+ | Propagators| + * | ReactEvent | . | | |TapEvent | |------------| + * | Emitter | . | |<---+|Plugin | |other plugin| + * | | . | | +-----------+ | utilities | + * | +-----------.--->| | +------------+ + * | | | . +--------------+ + * +-----|------+ . ^ +-----------+ + * | . | |Enter/Leave| + * + . +-------+|Plugin | + * +-------------+ . +-----------+ + * | application | . + * |-------------| . + * | | . + * | | . + * +-------------+ . + * . + * React Core . General Purpose Event Plugin System + */ + +var hasEventPageXY; +var alreadyListeningTo = {}; +var isMonitoringScrollValue = false; +var reactTopListenersCounter = 0; + +// For events like 'submit' which don't consistently bubble (which we trap at a +// lower node than `document`), binding at `document` would cause duplicate +// events so we don't include them here +var topEventMapping = { + topAbort: 'abort', + topAnimationEnd: getVendorPrefixedEventName('animationend') || 'animationend', + topAnimationIteration: getVendorPrefixedEventName('animationiteration') || 'animationiteration', + topAnimationStart: getVendorPrefixedEventName('animationstart') || 'animationstart', + topBlur: 'blur', + topCanPlay: 'canplay', + topCanPlayThrough: 'canplaythrough', + topChange: 'change', + topClick: 'click', + topCompositionEnd: 'compositionend', + topCompositionStart: 'compositionstart', + topCompositionUpdate: 'compositionupdate', + topContextMenu: 'contextmenu', + topCopy: 'copy', + topCut: 'cut', + topDoubleClick: 'dblclick', + topDrag: 'drag', + topDragEnd: 'dragend', + topDragEnter: 'dragenter', + topDragExit: 'dragexit', + topDragLeave: 'dragleave', + topDragOver: 'dragover', + topDragStart: 'dragstart', + topDrop: 'drop', + topDurationChange: 'durationchange', + topEmptied: 'emptied', + topEncrypted: 'encrypted', + topEnded: 'ended', + topError: 'error', + topFocus: 'focus', + topInput: 'input', + topKeyDown: 'keydown', + topKeyPress: 'keypress', + topKeyUp: 'keyup', + topLoadedData: 'loadeddata', + topLoadedMetadata: 'loadedmetadata', + topLoadStart: 'loadstart', + topMouseDown: 'mousedown', + topMouseMove: 'mousemove', + topMouseOut: 'mouseout', + topMouseOver: 'mouseover', + topMouseUp: 'mouseup', + topPaste: 'paste', + topPause: 'pause', + topPlay: 'play', + topPlaying: 'playing', + topProgress: 'progress', + topRateChange: 'ratechange', + topScroll: 'scroll', + topSeeked: 'seeked', + topSeeking: 'seeking', + topSelectionChange: 'selectionchange', + topStalled: 'stalled', + topSuspend: 'suspend', + topTextInput: 'textInput', + topTimeUpdate: 'timeupdate', + topTouchCancel: 'touchcancel', + topTouchEnd: 'touchend', + topTouchMove: 'touchmove', + topTouchStart: 'touchstart', + topTransitionEnd: getVendorPrefixedEventName('transitionend') || 'transitionend', + topVolumeChange: 'volumechange', + topWaiting: 'waiting', + topWheel: 'wheel' +}; + +/** + * To ensure no conflicts with other potential React instances on the page + */ +var topListenersIDKey = '_reactListenersID' + String(Math.random()).slice(2); + +function getListeningForDocument(mountAt) { + // In IE8, `mountAt` is a host object and doesn't have `hasOwnProperty` + // directly. + if (!Object.prototype.hasOwnProperty.call(mountAt, topListenersIDKey)) { + mountAt[topListenersIDKey] = reactTopListenersCounter++; + alreadyListeningTo[mountAt[topListenersIDKey]] = {}; + } + return alreadyListeningTo[mountAt[topListenersIDKey]]; +} + +/** + * `ReactBrowserEventEmitter` is used to attach top-level event listeners. For + * example: + * + * EventPluginHub.putListener('myID', 'onClick', myFunction); + * + * This would allocate a "registration" of `('onClick', myFunction)` on 'myID'. + * + * @internal + */ +var ReactBrowserEventEmitter = _assign({}, ReactEventEmitterMixin, { + /** + * Injectable event backend + */ + ReactEventListener: null, + + injection: { + /** + * @param {object} ReactEventListener + */ + injectReactEventListener: function (ReactEventListener) { + ReactEventListener.setHandleTopLevel(ReactBrowserEventEmitter.handleTopLevel); + ReactBrowserEventEmitter.ReactEventListener = ReactEventListener; + } + }, + + /** + * Sets whether or not any created callbacks should be enabled. + * + * @param {boolean} enabled True if callbacks should be enabled. + */ + setEnabled: function (enabled) { + if (ReactBrowserEventEmitter.ReactEventListener) { + ReactBrowserEventEmitter.ReactEventListener.setEnabled(enabled); + } + }, + + /** + * @return {boolean} True if callbacks are enabled. + */ + isEnabled: function () { + return !!(ReactBrowserEventEmitter.ReactEventListener && ReactBrowserEventEmitter.ReactEventListener.isEnabled()); + }, + + /** + * We listen for bubbled touch events on the document object. + * + * Firefox v8.01 (and possibly others) exhibited strange behavior when + * mounting `onmousemove` events at some node that was not the document + * element. The symptoms were that if your mouse is not moving over something + * contained within that mount point (for example on the background) the + * top-level listeners for `onmousemove` won't be called. However, if you + * register the `mousemove` on the document object, then it will of course + * catch all `mousemove`s. This along with iOS quirks, justifies restricting + * top-level listeners to the document object only, at least for these + * movement types of events and possibly all events. + * + * @see http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html + * + * Also, `keyup`/`keypress`/`keydown` do not bubble to the window on IE, but + * they bubble to document. + * + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @param {object} contentDocumentHandle Document which owns the container + */ + listenTo: function (registrationName, contentDocumentHandle) { + var mountAt = contentDocumentHandle; + var isListening = getListeningForDocument(mountAt); + var dependencies = EventPluginRegistry.registrationNameDependencies[registrationName]; + + for (var i = 0; i < dependencies.length; i++) { + var dependency = dependencies[i]; + if (!(isListening.hasOwnProperty(dependency) && isListening[dependency])) { + if (dependency === 'topWheel') { + if (isEventSupported('wheel')) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'wheel', mountAt); + } else if (isEventSupported('mousewheel')) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'mousewheel', mountAt); + } else { + // Firefox needs to capture a different mouse scroll event. + // @see http://www.quirksmode.org/dom/events/tests/scroll.html + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'DOMMouseScroll', mountAt); + } + } else if (dependency === 'topScroll') { + if (isEventSupported('scroll', true)) { + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topScroll', 'scroll', mountAt); + } else { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topScroll', 'scroll', ReactBrowserEventEmitter.ReactEventListener.WINDOW_HANDLE); + } + } else if (dependency === 'topFocus' || dependency === 'topBlur') { + if (isEventSupported('focus', true)) { + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topFocus', 'focus', mountAt); + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topBlur', 'blur', mountAt); + } else if (isEventSupported('focusin')) { + // IE has `focusin` and `focusout` events which bubble. + // @see http://www.quirksmode.org/blog/archives/2008/04/delegating_the.html + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topFocus', 'focusin', mountAt); + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topBlur', 'focusout', mountAt); + } + + // to make sure blur and focus event listeners are only attached once + isListening.topBlur = true; + isListening.topFocus = true; + } else if (topEventMapping.hasOwnProperty(dependency)) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(dependency, topEventMapping[dependency], mountAt); + } + + isListening[dependency] = true; + } + } + }, + + trapBubbledEvent: function (topLevelType, handlerBaseName, handle) { + return ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(topLevelType, handlerBaseName, handle); + }, + + trapCapturedEvent: function (topLevelType, handlerBaseName, handle) { + return ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent(topLevelType, handlerBaseName, handle); + }, + + /** + * Protect against document.createEvent() returning null + * Some popup blocker extensions appear to do this: + * https://github.com/facebook/react/issues/6887 + */ + supportsEventPageXY: function () { + if (!document.createEvent) { + return false; + } + var ev = document.createEvent('MouseEvent'); + return ev != null && 'pageX' in ev; + }, + + /** + * Listens to window scroll and resize events. We cache scroll values so that + * application code can access them without triggering reflows. + * + * ViewportMetrics is only used by SyntheticMouse/TouchEvent and only when + * pageX/pageY isn't supported (legacy browsers). + * + * NOTE: Scroll events do not bubble. + * + * @see http://www.quirksmode.org/dom/events/scroll.html + */ + ensureScrollValueMonitoring: function () { + if (hasEventPageXY === undefined) { + hasEventPageXY = ReactBrowserEventEmitter.supportsEventPageXY(); + } + if (!hasEventPageXY && !isMonitoringScrollValue) { + var refresh = ViewportMetrics.refreshScrollValues; + ReactBrowserEventEmitter.ReactEventListener.monitorScrollValue(refresh); + isMonitoringScrollValue = true; + } + } +}); + +module.exports = ReactBrowserEventEmitter; + +/***/ }), +/* 63 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/* + * A JavaScript implementation of the RSA Data Security, Inc. MD5 Message + * Digest Algorithm, as defined in RFC 1321. + * Version 2.1 Copyright (C) Paul Johnston 1999 - 2002. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * Distributed under the BSD License + * See http://pajhome.org.uk/crypt/md5 for more info. + */ + +var makeHash = __webpack_require__(365) + +/* + * Calculate the MD5 of an array of little-endian words, and a bit length + */ +function core_md5 (x, len) { + /* append padding */ + x[len >> 5] |= 0x80 << ((len) % 32) + x[(((len + 64) >>> 9) << 4) + 14] = len + + var a = 1732584193 + var b = -271733879 + var c = -1732584194 + var d = 271733878 + + for (var i = 0; i < x.length; i += 16) { + var olda = a + var oldb = b + var oldc = c + var oldd = d + + a = md5_ff(a, b, c, d, x[i + 0], 7, -680876936) + d = md5_ff(d, a, b, c, x[i + 1], 12, -389564586) + c = md5_ff(c, d, a, b, x[i + 2], 17, 606105819) + b = md5_ff(b, c, d, a, x[i + 3], 22, -1044525330) + a = md5_ff(a, b, c, d, x[i + 4], 7, -176418897) + d = md5_ff(d, a, b, c, x[i + 5], 12, 1200080426) + c = md5_ff(c, d, a, b, x[i + 6], 17, -1473231341) + b = md5_ff(b, c, d, a, x[i + 7], 22, -45705983) + a = md5_ff(a, b, c, d, x[i + 8], 7, 1770035416) + d = md5_ff(d, a, b, c, x[i + 9], 12, -1958414417) + c = md5_ff(c, d, a, b, x[i + 10], 17, -42063) + b = md5_ff(b, c, d, a, x[i + 11], 22, -1990404162) + a = md5_ff(a, b, c, d, x[i + 12], 7, 1804603682) + d = md5_ff(d, a, b, c, x[i + 13], 12, -40341101) + c = md5_ff(c, d, a, b, x[i + 14], 17, -1502002290) + b = md5_ff(b, c, d, a, x[i + 15], 22, 1236535329) + + a = md5_gg(a, b, c, d, x[i + 1], 5, -165796510) + d = md5_gg(d, a, b, c, x[i + 6], 9, -1069501632) + c = md5_gg(c, d, a, b, x[i + 11], 14, 643717713) + b = md5_gg(b, c, d, a, x[i + 0], 20, -373897302) + a = md5_gg(a, b, c, d, x[i + 5], 5, -701558691) + d = md5_gg(d, a, b, c, x[i + 10], 9, 38016083) + c = md5_gg(c, d, a, b, x[i + 15], 14, -660478335) + b = md5_gg(b, c, d, a, x[i + 4], 20, -405537848) + a = md5_gg(a, b, c, d, x[i + 9], 5, 568446438) + d = md5_gg(d, a, b, c, x[i + 14], 9, -1019803690) + c = md5_gg(c, d, a, b, x[i + 3], 14, -187363961) + b = md5_gg(b, c, d, a, x[i + 8], 20, 1163531501) + a = md5_gg(a, b, c, d, x[i + 13], 5, -1444681467) + d = md5_gg(d, a, b, c, x[i + 2], 9, -51403784) + c = md5_gg(c, d, a, b, x[i + 7], 14, 1735328473) + b = md5_gg(b, c, d, a, x[i + 12], 20, -1926607734) + + a = md5_hh(a, b, c, d, x[i + 5], 4, -378558) + d = md5_hh(d, a, b, c, x[i + 8], 11, -2022574463) + c = md5_hh(c, d, a, b, x[i + 11], 16, 1839030562) + b = md5_hh(b, c, d, a, x[i + 14], 23, -35309556) + a = md5_hh(a, b, c, d, x[i + 1], 4, -1530992060) + d = md5_hh(d, a, b, c, x[i + 4], 11, 1272893353) + c = md5_hh(c, d, a, b, x[i + 7], 16, -155497632) + b = md5_hh(b, c, d, a, x[i + 10], 23, -1094730640) + a = md5_hh(a, b, c, d, x[i + 13], 4, 681279174) + d = md5_hh(d, a, b, c, x[i + 0], 11, -358537222) + c = md5_hh(c, d, a, b, x[i + 3], 16, -722521979) + b = md5_hh(b, c, d, a, x[i + 6], 23, 76029189) + a = md5_hh(a, b, c, d, x[i + 9], 4, -640364487) + d = md5_hh(d, a, b, c, x[i + 12], 11, -421815835) + c = md5_hh(c, d, a, b, x[i + 15], 16, 530742520) + b = md5_hh(b, c, d, a, x[i + 2], 23, -995338651) + + a = md5_ii(a, b, c, d, x[i + 0], 6, -198630844) + d = md5_ii(d, a, b, c, x[i + 7], 10, 1126891415) + c = md5_ii(c, d, a, b, x[i + 14], 15, -1416354905) + b = md5_ii(b, c, d, a, x[i + 5], 21, -57434055) + a = md5_ii(a, b, c, d, x[i + 12], 6, 1700485571) + d = md5_ii(d, a, b, c, x[i + 3], 10, -1894986606) + c = md5_ii(c, d, a, b, x[i + 10], 15, -1051523) + b = md5_ii(b, c, d, a, x[i + 1], 21, -2054922799) + a = md5_ii(a, b, c, d, x[i + 8], 6, 1873313359) + d = md5_ii(d, a, b, c, x[i + 15], 10, -30611744) + c = md5_ii(c, d, a, b, x[i + 6], 15, -1560198380) + b = md5_ii(b, c, d, a, x[i + 13], 21, 1309151649) + a = md5_ii(a, b, c, d, x[i + 4], 6, -145523070) + d = md5_ii(d, a, b, c, x[i + 11], 10, -1120210379) + c = md5_ii(c, d, a, b, x[i + 2], 15, 718787259) + b = md5_ii(b, c, d, a, x[i + 9], 21, -343485551) + + a = safe_add(a, olda) + b = safe_add(b, oldb) + c = safe_add(c, oldc) + d = safe_add(d, oldd) + } + + return [a, b, c, d] +} + +/* + * These functions implement the four basic operations the algorithm uses. + */ +function md5_cmn (q, a, b, x, s, t) { + return safe_add(bit_rol(safe_add(safe_add(a, q), safe_add(x, t)), s), b) +} + +function md5_ff (a, b, c, d, x, s, t) { + return md5_cmn((b & c) | ((~b) & d), a, b, x, s, t) +} + +function md5_gg (a, b, c, d, x, s, t) { + return md5_cmn((b & d) | (c & (~d)), a, b, x, s, t) +} + +function md5_hh (a, b, c, d, x, s, t) { + return md5_cmn(b ^ c ^ d, a, b, x, s, t) +} + +function md5_ii (a, b, c, d, x, s, t) { + return md5_cmn(c ^ (b | (~d)), a, b, x, s, t) +} + +/* + * Add integers, wrapping at 2^32. This uses 16-bit operations internally + * to work around bugs in some JS interpreters. + */ +function safe_add (x, y) { + var lsw = (x & 0xFFFF) + (y & 0xFFFF) + var msw = (x >> 16) + (y >> 16) + (lsw >> 16) + return (msw << 16) | (lsw & 0xFFFF) +} + +/* + * Bitwise rotate a 32-bit number to the left. + */ +function bit_rol (num, cnt) { + return (num << cnt) | (num >>> (32 - cnt)) +} + +module.exports = function md5 (buf) { + return makeHash(buf, core_md5) +} + + +/***/ }), +/* 64 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +if (!process.version || + process.version.indexOf('v0.') === 0 || + process.version.indexOf('v1.') === 0 && process.version.indexOf('v1.8.') !== 0) { + module.exports = nextTick; +} else { + module.exports = process.nextTick; +} + +function nextTick(fn, arg1, arg2, arg3) { + if (typeof fn !== 'function') { + throw new TypeError('"callback" argument must be a function'); + } + var len = arguments.length; + var args, i; + switch (len) { + case 0: + case 1: + return process.nextTick(fn); + case 2: + return process.nextTick(function afterTickOne() { + fn.call(null, arg1); + }); + case 3: + return process.nextTick(function afterTickTwo() { + fn.call(null, arg1, arg2); + }); + case 4: + return process.nextTick(function afterTickThree() { + fn.call(null, arg1, arg2, arg3); + }); + default: + args = new Array(len - 1); + i = 0; + while (i < args.length) { + args[i++] = arguments[i]; + } + return process.nextTick(function afterTick() { + fn.apply(null, args); + }); + } +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 65 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var curve = exports; + +curve.base = __webpack_require__(388); +curve.short = __webpack_require__(389); +curve.mont = __webpack_require__(390); +curve.edwards = __webpack_require__(391); + + +/***/ }), +/* 66 */ +/***/ (function(module, exports) { + +/* +config.js - Configuration for ZENCash Coin +*/ + +module.exports = { + mainnet: { + messagePrefix: 'ZENCash main net', + bip32: { + public: '0488b21e', + private: '0488ade4' + }, + pubKeyHash: '2089', + scriptHash: '2096', + zcPaymentAddressHash: '169a', // Private z-address + zcSpendingKeyHash: 'ab36', // Spending key + wif: '80' + }, + testnet: { + wif: 'ef', + pubKeyHash: '2098' + } +}; + +/***/ }), +/* 67 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var inherits = __webpack_require__(4) +var Legacy = __webpack_require__(420) +var Base = __webpack_require__(29) +var Buffer = __webpack_require__(7).Buffer +var md5 = __webpack_require__(63) +var RIPEMD160 = __webpack_require__(97) + +var sha = __webpack_require__(103) + +var ZEROS = Buffer.alloc(128) + +function Hmac (alg, key) { + Base.call(this, 'digest') + if (typeof key === 'string') { + key = Buffer.from(key) + } + + var blocksize = (alg === 'sha512' || alg === 'sha384') ? 128 : 64 + + this._alg = alg + this._key = key + if (key.length > blocksize) { + var hash = alg === 'rmd160' ? new RIPEMD160() : sha(alg) + key = hash.update(key).digest() + } else if (key.length < blocksize) { + key = Buffer.concat([key, ZEROS], blocksize) + } + + var ipad = this._ipad = Buffer.allocUnsafe(blocksize) + var opad = this._opad = Buffer.allocUnsafe(blocksize) + + for (var i = 0; i < blocksize; i++) { + ipad[i] = key[i] ^ 0x36 + opad[i] = key[i] ^ 0x5C + } + this._hash = alg === 'rmd160' ? new RIPEMD160() : sha(alg) + this._hash.update(ipad) +} + +inherits(Hmac, Base) + +Hmac.prototype._update = function (data) { + this._hash.update(data) +} + +Hmac.prototype._final = function () { + var h = this._hash.digest() + var hash = this._alg === 'rmd160' ? new RIPEMD160() : sha(this._alg) + return hash.update(this._opad).update(h).digest() +} + +module.exports = function createHmac (alg, key) { + alg = alg.toLowerCase() + if (alg === 'rmd160' || alg === 'ripemd160') { + return new Hmac('rmd160', key) + } + if (alg === 'md5') { + return new Legacy(md5, key) + } + return new Hmac(alg, key) +} + + +/***/ }), +/* 68 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var md5 = __webpack_require__(63) +module.exports = EVP_BytesToKey +function EVP_BytesToKey (password, salt, keyLen, ivLen) { + if (!Buffer.isBuffer(password)) { + password = new Buffer(password, 'binary') + } + if (salt && !Buffer.isBuffer(salt)) { + salt = new Buffer(salt, 'binary') + } + keyLen = keyLen / 8 + ivLen = ivLen || 0 + var ki = 0 + var ii = 0 + var key = new Buffer(keyLen) + var iv = new Buffer(ivLen) + var addmd = 0 + var md_buf + var i + var bufs = [] + while (true) { + if (addmd++ > 0) { + bufs.push(md_buf) + } + bufs.push(password) + if (salt) { + bufs.push(salt) + } + md_buf = md5(Buffer.concat(bufs)) + bufs = [] + i = 0 + if (keyLen > 0) { + while (true) { + if (keyLen === 0) { + break + } + if (i === md_buf.length) { + break + } + key[ki++] = md_buf[i] + keyLen-- + i++ + } + } + if (ivLen > 0 && i !== md_buf.length) { + while (true) { + if (ivLen === 0) { + break + } + if (i === md_buf.length) { + break + } + iv[ii++] = md_buf[i] + ivLen-- + i++ + } + } + if (keyLen === 0 && ivLen === 0) { + break + } + } + for (i = 0; i < md_buf.length; i++) { + md_buf[i] = 0 + } + return { + key: key, + iv: iv + } +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 69 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {// based on the aes implimentation in triple sec +// https://github.com/keybase/triplesec + +// which is in turn based on the one from crypto-js +// https://code.google.com/p/crypto-js/ + +var uint_max = Math.pow(2, 32) +function fixup_uint32 (x) { + var ret, x_pos + ret = x > uint_max || x < 0 ? (x_pos = Math.abs(x) % uint_max, x < 0 ? uint_max - x_pos : x_pos) : x + return ret +} +function scrub_vec (v) { + for (var i = 0; i < v.length; v++) { + v[i] = 0 + } + return false +} + +function Global () { + this.SBOX = [] + this.INV_SBOX = [] + this.SUB_MIX = [[], [], [], []] + this.INV_SUB_MIX = [[], [], [], []] + this.init() + this.RCON = [0x00, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x1b, 0x36] +} + +Global.prototype.init = function () { + var d, i, sx, t, x, x2, x4, x8, xi, _i + d = (function () { + var _i, _results + _results = [] + for (i = _i = 0; _i < 256; i = ++_i) { + if (i < 128) { + _results.push(i << 1) + } else { + _results.push((i << 1) ^ 0x11b) + } + } + return _results + })() + x = 0 + xi = 0 + for (i = _i = 0; _i < 256; i = ++_i) { + sx = xi ^ (xi << 1) ^ (xi << 2) ^ (xi << 3) ^ (xi << 4) + sx = (sx >>> 8) ^ (sx & 0xff) ^ 0x63 + this.SBOX[x] = sx + this.INV_SBOX[sx] = x + x2 = d[x] + x4 = d[x2] + x8 = d[x4] + t = (d[sx] * 0x101) ^ (sx * 0x1010100) + this.SUB_MIX[0][x] = (t << 24) | (t >>> 8) + this.SUB_MIX[1][x] = (t << 16) | (t >>> 16) + this.SUB_MIX[2][x] = (t << 8) | (t >>> 24) + this.SUB_MIX[3][x] = t + t = (x8 * 0x1010101) ^ (x4 * 0x10001) ^ (x2 * 0x101) ^ (x * 0x1010100) + this.INV_SUB_MIX[0][sx] = (t << 24) | (t >>> 8) + this.INV_SUB_MIX[1][sx] = (t << 16) | (t >>> 16) + this.INV_SUB_MIX[2][sx] = (t << 8) | (t >>> 24) + this.INV_SUB_MIX[3][sx] = t + if (x === 0) { + x = xi = 1 + } else { + x = x2 ^ d[d[d[x8 ^ x2]]] + xi ^= d[d[xi]] + } + } + return true +} + +var G = new Global() + +AES.blockSize = 4 * 4 + +AES.prototype.blockSize = AES.blockSize + +AES.keySize = 256 / 8 + +AES.prototype.keySize = AES.keySize + +function bufferToArray (buf) { + var len = buf.length / 4 + var out = new Array(len) + var i = -1 + while (++i < len) { + out[i] = buf.readUInt32BE(i * 4) + } + return out +} +function AES (key) { + this._key = bufferToArray(key) + this._doReset() +} + +AES.prototype._doReset = function () { + var invKsRow, keySize, keyWords, ksRow, ksRows, t + keyWords = this._key + keySize = keyWords.length + this._nRounds = keySize + 6 + ksRows = (this._nRounds + 1) * 4 + this._keySchedule = [] + for (ksRow = 0; ksRow < ksRows; ksRow++) { + this._keySchedule[ksRow] = ksRow < keySize ? keyWords[ksRow] : (t = this._keySchedule[ksRow - 1], (ksRow % keySize) === 0 ? (t = (t << 8) | (t >>> 24), t = (G.SBOX[t >>> 24] << 24) | (G.SBOX[(t >>> 16) & 0xff] << 16) | (G.SBOX[(t >>> 8) & 0xff] << 8) | G.SBOX[t & 0xff], t ^= G.RCON[(ksRow / keySize) | 0] << 24) : keySize > 6 && ksRow % keySize === 4 ? t = (G.SBOX[t >>> 24] << 24) | (G.SBOX[(t >>> 16) & 0xff] << 16) | (G.SBOX[(t >>> 8) & 0xff] << 8) | G.SBOX[t & 0xff] : void 0, this._keySchedule[ksRow - keySize] ^ t) + } + this._invKeySchedule = [] + for (invKsRow = 0; invKsRow < ksRows; invKsRow++) { + ksRow = ksRows - invKsRow + t = this._keySchedule[ksRow - (invKsRow % 4 ? 0 : 4)] + this._invKeySchedule[invKsRow] = invKsRow < 4 || ksRow <= 4 ? t : G.INV_SUB_MIX[0][G.SBOX[t >>> 24]] ^ G.INV_SUB_MIX[1][G.SBOX[(t >>> 16) & 0xff]] ^ G.INV_SUB_MIX[2][G.SBOX[(t >>> 8) & 0xff]] ^ G.INV_SUB_MIX[3][G.SBOX[t & 0xff]] + } + return true +} + +AES.prototype.encryptBlock = function (M) { + M = bufferToArray(new Buffer(M)) + var out = this._doCryptBlock(M, this._keySchedule, G.SUB_MIX, G.SBOX) + var buf = new Buffer(16) + buf.writeUInt32BE(out[0], 0) + buf.writeUInt32BE(out[1], 4) + buf.writeUInt32BE(out[2], 8) + buf.writeUInt32BE(out[3], 12) + return buf +} + +AES.prototype.decryptBlock = function (M) { + M = bufferToArray(new Buffer(M)) + var temp = [M[3], M[1]] + M[1] = temp[0] + M[3] = temp[1] + var out = this._doCryptBlock(M, this._invKeySchedule, G.INV_SUB_MIX, G.INV_SBOX) + var buf = new Buffer(16) + buf.writeUInt32BE(out[0], 0) + buf.writeUInt32BE(out[3], 4) + buf.writeUInt32BE(out[2], 8) + buf.writeUInt32BE(out[1], 12) + return buf +} + +AES.prototype.scrub = function () { + scrub_vec(this._keySchedule) + scrub_vec(this._invKeySchedule) + scrub_vec(this._key) +} + +AES.prototype._doCryptBlock = function (M, keySchedule, SUB_MIX, SBOX) { + var ksRow, s0, s1, s2, s3, t0, t1, t2, t3 + + s0 = M[0] ^ keySchedule[0] + s1 = M[1] ^ keySchedule[1] + s2 = M[2] ^ keySchedule[2] + s3 = M[3] ^ keySchedule[3] + ksRow = 4 + for (var round = 1; round < this._nRounds; round++) { + t0 = SUB_MIX[0][s0 >>> 24] ^ SUB_MIX[1][(s1 >>> 16) & 0xff] ^ SUB_MIX[2][(s2 >>> 8) & 0xff] ^ SUB_MIX[3][s3 & 0xff] ^ keySchedule[ksRow++] + t1 = SUB_MIX[0][s1 >>> 24] ^ SUB_MIX[1][(s2 >>> 16) & 0xff] ^ SUB_MIX[2][(s3 >>> 8) & 0xff] ^ SUB_MIX[3][s0 & 0xff] ^ keySchedule[ksRow++] + t2 = SUB_MIX[0][s2 >>> 24] ^ SUB_MIX[1][(s3 >>> 16) & 0xff] ^ SUB_MIX[2][(s0 >>> 8) & 0xff] ^ SUB_MIX[3][s1 & 0xff] ^ keySchedule[ksRow++] + t3 = SUB_MIX[0][s3 >>> 24] ^ SUB_MIX[1][(s0 >>> 16) & 0xff] ^ SUB_MIX[2][(s1 >>> 8) & 0xff] ^ SUB_MIX[3][s2 & 0xff] ^ keySchedule[ksRow++] + s0 = t0 + s1 = t1 + s2 = t2 + s3 = t3 + } + t0 = ((SBOX[s0 >>> 24] << 24) | (SBOX[(s1 >>> 16) & 0xff] << 16) | (SBOX[(s2 >>> 8) & 0xff] << 8) | SBOX[s3 & 0xff]) ^ keySchedule[ksRow++] + t1 = ((SBOX[s1 >>> 24] << 24) | (SBOX[(s2 >>> 16) & 0xff] << 16) | (SBOX[(s3 >>> 8) & 0xff] << 8) | SBOX[s0 & 0xff]) ^ keySchedule[ksRow++] + t2 = ((SBOX[s2 >>> 24] << 24) | (SBOX[(s3 >>> 16) & 0xff] << 16) | (SBOX[(s0 >>> 8) & 0xff] << 8) | SBOX[s1 & 0xff]) ^ keySchedule[ksRow++] + t3 = ((SBOX[s3 >>> 24] << 24) | (SBOX[(s0 >>> 16) & 0xff] << 16) | (SBOX[(s1 >>> 8) & 0xff] << 8) | SBOX[s2 & 0xff]) ^ keySchedule[ksRow++] + return [ + fixup_uint32(t0), + fixup_uint32(t1), + fixup_uint32(t2), + fixup_uint32(t3) + ] +} + +exports.AES = AES + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 70 */ +/***/ (function(module, exports) { + +exports['aes-128-ecb'] = { + cipher: 'AES', + key: 128, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-192-ecb'] = { + cipher: 'AES', + key: 192, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-256-ecb'] = { + cipher: 'AES', + key: 256, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-128-cbc'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes-192-cbc'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes-256-cbc'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes128'] = exports['aes-128-cbc'] +exports['aes192'] = exports['aes-192-cbc'] +exports['aes256'] = exports['aes-256-cbc'] +exports['aes-128-cfb'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-192-cfb'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-256-cfb'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-128-cfb8'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-192-cfb8'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-256-cfb8'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-128-cfb1'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-192-cfb1'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-256-cfb1'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-128-ofb'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-192-ofb'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-256-ofb'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-128-ctr'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-192-ctr'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-256-ctr'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-128-gcm'] = { + cipher: 'AES', + key: 128, + iv: 12, + mode: 'GCM', + type: 'auth' +} +exports['aes-192-gcm'] = { + cipher: 'AES', + key: 192, + iv: 12, + mode: 'GCM', + type: 'auth' +} +exports['aes-256-gcm'] = { + cipher: 'AES', + key: 256, + iv: 12, + mode: 'GCM', + type: 'auth' +} + + +/***/ }), +/* 71 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) + +function incr32 (iv) { + var len = iv.length + var item + while (len--) { + item = iv.readUInt8(len) + if (item === 255) { + iv.writeUInt8(0, len) + } else { + item++ + iv.writeUInt8(item, len) + break + } + } +} + +function getBlock (self) { + var out = self._cipher.encryptBlock(self._prev) + incr32(self._prev) + return out +} + +exports.encrypt = function (self, chunk) { + while (self._cache.length < chunk.length) { + self._cache = Buffer.concat([self._cache, getBlock(self)]) + } + var pad = self._cache.slice(0, chunk.length) + self._cache = self._cache.slice(chunk.length) + return xor(chunk, pad) +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 72 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var asn1 = __webpack_require__(439) +var aesid = __webpack_require__(451) +var fixProc = __webpack_require__(452) +var ciphers = __webpack_require__(108) +var compat = __webpack_require__(177) +module.exports = parseKeys + +function parseKeys (buffer) { + var password + if (typeof buffer === 'object' && !Buffer.isBuffer(buffer)) { + password = buffer.passphrase + buffer = buffer.key + } + if (typeof buffer === 'string') { + buffer = new Buffer(buffer) + } + + var stripped = fixProc(buffer, password) + + var type = stripped.tag + var data = stripped.data + var subtype, ndata + switch (type) { + case 'CERTIFICATE': + ndata = asn1.certificate.decode(data, 'der').tbsCertificate.subjectPublicKeyInfo + // falls through + case 'PUBLIC KEY': + if (!ndata) { + ndata = asn1.PublicKey.decode(data, 'der') + } + subtype = ndata.algorithm.algorithm.join('.') + switch (subtype) { + case '1.2.840.113549.1.1.1': + return asn1.RSAPublicKey.decode(ndata.subjectPublicKey.data, 'der') + case '1.2.840.10045.2.1': + ndata.subjectPrivateKey = ndata.subjectPublicKey + return { + type: 'ec', + data: ndata + } + case '1.2.840.10040.4.1': + ndata.algorithm.params.pub_key = asn1.DSAparam.decode(ndata.subjectPublicKey.data, 'der') + return { + type: 'dsa', + data: ndata.algorithm.params + } + default: throw new Error('unknown key id ' + subtype) + } + throw new Error('unknown key type ' + type) + case 'ENCRYPTED PRIVATE KEY': + data = asn1.EncryptedPrivateKey.decode(data, 'der') + data = decrypt(data, password) + // falls through + case 'PRIVATE KEY': + ndata = asn1.PrivateKey.decode(data, 'der') + subtype = ndata.algorithm.algorithm.join('.') + switch (subtype) { + case '1.2.840.113549.1.1.1': + return asn1.RSAPrivateKey.decode(ndata.subjectPrivateKey, 'der') + case '1.2.840.10045.2.1': + return { + curve: ndata.algorithm.curve, + privateKey: asn1.ECPrivateKey.decode(ndata.subjectPrivateKey, 'der').privateKey + } + case '1.2.840.10040.4.1': + ndata.algorithm.params.priv_key = asn1.DSAparam.decode(ndata.subjectPrivateKey, 'der') + return { + type: 'dsa', + params: ndata.algorithm.params + } + default: throw new Error('unknown key id ' + subtype) + } + throw new Error('unknown key type ' + type) + case 'RSA PUBLIC KEY': + return asn1.RSAPublicKey.decode(data, 'der') + case 'RSA PRIVATE KEY': + return asn1.RSAPrivateKey.decode(data, 'der') + case 'DSA PRIVATE KEY': + return { + type: 'dsa', + params: asn1.DSAPrivateKey.decode(data, 'der') + } + case 'EC PRIVATE KEY': + data = asn1.ECPrivateKey.decode(data, 'der') + return { + curve: data.parameters.value, + privateKey: data.privateKey + } + default: throw new Error('unknown key type ' + type) + } +} +parseKeys.signature = asn1.signature +function decrypt (data, password) { + var salt = data.algorithm.decrypt.kde.kdeparams.salt + var iters = parseInt(data.algorithm.decrypt.kde.kdeparams.iters.toString(), 10) + var algo = aesid[data.algorithm.decrypt.cipher.algo.join('.')] + var iv = data.algorithm.decrypt.cipher.iv + var cipherText = data.subjectPrivateKey + var keylen = parseInt(algo.split('-')[1], 10) / 8 + var key = compat.pbkdf2Sync(password, salt, iters, keylen) + var cipher = ciphers.createDecipheriv(algo, key, iv) + var out = [] + out.push(cipher.update(cipherText)) + out.push(cipher.final()) + return Buffer.concat(out) +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 73 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { + +// Number.MAX_SAFE_INTEGER +var MAX_SAFE_INTEGER = 9007199254740991 + +function checkUInt53 (n) { + if (n < 0 || n > MAX_SAFE_INTEGER || n % 1 !== 0) throw new RangeError('value out of range') +} + +function encode (number, buffer, offset) { + checkUInt53(number) + + if (!buffer) buffer = new Buffer(encodingLength(number)) + if (!Buffer.isBuffer(buffer)) throw new TypeError('buffer must be a Buffer instance') + if (!offset) offset = 0 + + // 8 bit + if (number < 0xfd) { + buffer.writeUInt8(number, offset) + encode.bytes = 1 + + // 16 bit + } else if (number <= 0xffff) { + buffer.writeUInt8(0xfd, offset) + buffer.writeUInt16LE(number, offset + 1) + encode.bytes = 3 + + // 32 bit + } else if (number <= 0xffffffff) { + buffer.writeUInt8(0xfe, offset) + buffer.writeUInt32LE(number, offset + 1) + encode.bytes = 5 + + // 64 bit + } else { + buffer.writeUInt8(0xff, offset) + buffer.writeUInt32LE(number >>> 0, offset + 1) + buffer.writeUInt32LE((number / 0x100000000) | 0, offset + 5) + encode.bytes = 9 + } + + return buffer +} + +function decode (buffer, offset) { + if (!Buffer.isBuffer(buffer)) throw new TypeError('buffer must be a Buffer instance') + if (!offset) offset = 0 + + var first = buffer.readUInt8(offset) + + // 8 bit + if (first < 0xfd) { + decode.bytes = 1 + return first + + // 16 bit + } else if (first === 0xfd) { + decode.bytes = 3 + return buffer.readUInt16LE(offset + 1) + + // 32 bit + } else if (first === 0xfe) { + decode.bytes = 5 + return buffer.readUInt32LE(offset + 1) + + // 64 bit + } else { + decode.bytes = 9 + var lo = buffer.readUInt32LE(offset + 1) + var hi = buffer.readUInt32LE(offset + 5) + var number = hi * 0x0100000000 + lo + checkUInt53(number) + + return number + } +} + +function encodingLength (number) { + checkUInt53(number) + + return ( + number < 0xfd ? 1 + : number <= 0xffff ? 3 + : number <= 0xffffffff ? 5 + : 9 + ) +} + +module.exports = { encode: encode, decode: decode, encodingLength: encodingLength } + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 74 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * Forked from fbjs/warning: + * https://github.com/facebook/fbjs/blob/e66ba20ad5be433eb54423f2b097d829324d9de6/packages/fbjs/src/__forks__/warning.js + * + * Only change is we use console.warn instead of console.error, + * and do nothing when 'console' is not supported. + * This really simplifies the code. + * --- + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ + +var lowPriorityWarning = function () {}; + +if (process.env.NODE_ENV !== 'production') { + var printWarning = function (format) { + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } + + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.warn(message); + } + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} + }; + + lowPriorityWarning = function (condition, format) { + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + } + if (!condition) { + for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { + args[_key2 - 2] = arguments[_key2]; + } + + printWarning.apply(undefined, [format].concat(args)); + } + }; +} + +module.exports = lowPriorityWarning; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 75 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; + +module.exports = ReactPropTypesSecret; + + +/***/ }), +/* 76 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +module.exports = __webpack_require__(230); + + +/***/ }), +/* 77 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactErrorUtils = __webpack_require__(78); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +/** + * Injected dependencies: + */ + +/** + * - `ComponentTree`: [required] Module that can convert between React instances + * and actual node references. + */ +var ComponentTree; +var TreeTraversal; +var injection = { + injectComponentTree: function (Injected) { + ComponentTree = Injected; + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.getNodeFromInstance && Injected.getInstanceFromNode, 'EventPluginUtils.injection.injectComponentTree(...): Injected ' + 'module is missing getNodeFromInstance or getInstanceFromNode.') : void 0; + } + }, + injectTreeTraversal: function (Injected) { + TreeTraversal = Injected; + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.isAncestor && Injected.getLowestCommonAncestor, 'EventPluginUtils.injection.injectTreeTraversal(...): Injected ' + 'module is missing isAncestor or getLowestCommonAncestor.') : void 0; + } + } +}; + +function isEndish(topLevelType) { + return topLevelType === 'topMouseUp' || topLevelType === 'topTouchEnd' || topLevelType === 'topTouchCancel'; +} + +function isMoveish(topLevelType) { + return topLevelType === 'topMouseMove' || topLevelType === 'topTouchMove'; +} +function isStartish(topLevelType) { + return topLevelType === 'topMouseDown' || topLevelType === 'topTouchStart'; +} + +var validateEventDispatches; +if (process.env.NODE_ENV !== 'production') { + validateEventDispatches = function (event) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; + + var listenersIsArr = Array.isArray(dispatchListeners); + var listenersLen = listenersIsArr ? dispatchListeners.length : dispatchListeners ? 1 : 0; + + var instancesIsArr = Array.isArray(dispatchInstances); + var instancesLen = instancesIsArr ? dispatchInstances.length : dispatchInstances ? 1 : 0; + + process.env.NODE_ENV !== 'production' ? warning(instancesIsArr === listenersIsArr && instancesLen === listenersLen, 'EventPluginUtils: Invalid `event`.') : void 0; + }; +} + +/** + * Dispatch the event to the listener. + * @param {SyntheticEvent} event SyntheticEvent to handle + * @param {boolean} simulated If the event is simulated (changes exn behavior) + * @param {function} listener Application-level callback + * @param {*} inst Internal component instance + */ +function executeDispatch(event, simulated, listener, inst) { + var type = event.type || 'unknown-event'; + event.currentTarget = EventPluginUtils.getNodeFromInstance(inst); + if (simulated) { + ReactErrorUtils.invokeGuardedCallbackWithCatch(type, listener, event); + } else { + ReactErrorUtils.invokeGuardedCallback(type, listener, event); + } + event.currentTarget = null; +} + +/** + * Standard/simple iteration through an event's collected dispatches. + */ +function executeDispatchesInOrder(event, simulated) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + if (Array.isArray(dispatchListeners)) { + for (var i = 0; i < dispatchListeners.length; i++) { + if (event.isPropagationStopped()) { + break; + } + // Listeners and Instances are two parallel arrays that are always in sync. + executeDispatch(event, simulated, dispatchListeners[i], dispatchInstances[i]); + } + } else if (dispatchListeners) { + executeDispatch(event, simulated, dispatchListeners, dispatchInstances); + } + event._dispatchListeners = null; + event._dispatchInstances = null; +} + +/** + * Standard/simple iteration through an event's collected dispatches, but stops + * at the first dispatch execution returning true, and returns that id. + * + * @return {?string} id of the first dispatch execution who's listener returns + * true, or null if no listener returned true. + */ +function executeDispatchesInOrderStopAtTrueImpl(event) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + if (Array.isArray(dispatchListeners)) { + for (var i = 0; i < dispatchListeners.length; i++) { + if (event.isPropagationStopped()) { + break; + } + // Listeners and Instances are two parallel arrays that are always in sync. + if (dispatchListeners[i](event, dispatchInstances[i])) { + return dispatchInstances[i]; + } + } + } else if (dispatchListeners) { + if (dispatchListeners(event, dispatchInstances)) { + return dispatchInstances; + } + } + return null; +} + +/** + * @see executeDispatchesInOrderStopAtTrueImpl + */ +function executeDispatchesInOrderStopAtTrue(event) { + var ret = executeDispatchesInOrderStopAtTrueImpl(event); + event._dispatchInstances = null; + event._dispatchListeners = null; + return ret; +} + +/** + * Execution of a "direct" dispatch - there must be at most one dispatch + * accumulated on the event or it is considered an error. It doesn't really make + * sense for an event with multiple dispatches (bubbled) to keep track of the + * return values at each dispatch execution, but it does tend to make sense when + * dealing with "direct" dispatches. + * + * @return {*} The return value of executing the single dispatch. + */ +function executeDirectDispatch(event) { + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + var dispatchListener = event._dispatchListeners; + var dispatchInstance = event._dispatchInstances; + !!Array.isArray(dispatchListener) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'executeDirectDispatch(...): Invalid `event`.') : _prodInvariant('103') : void 0; + event.currentTarget = dispatchListener ? EventPluginUtils.getNodeFromInstance(dispatchInstance) : null; + var res = dispatchListener ? dispatchListener(event) : null; + event.currentTarget = null; + event._dispatchListeners = null; + event._dispatchInstances = null; + return res; +} + +/** + * @param {SyntheticEvent} event + * @return {boolean} True iff number of dispatches accumulated is greater than 0. + */ +function hasDispatches(event) { + return !!event._dispatchListeners; +} + +/** + * General utilities that are useful in creating custom Event Plugins. + */ +var EventPluginUtils = { + isEndish: isEndish, + isMoveish: isMoveish, + isStartish: isStartish, + + executeDirectDispatch: executeDirectDispatch, + executeDispatchesInOrder: executeDispatchesInOrder, + executeDispatchesInOrderStopAtTrue: executeDispatchesInOrderStopAtTrue, + hasDispatches: hasDispatches, + + getInstanceFromNode: function (node) { + return ComponentTree.getInstanceFromNode(node); + }, + getNodeFromInstance: function (node) { + return ComponentTree.getNodeFromInstance(node); + }, + isAncestor: function (a, b) { + return TreeTraversal.isAncestor(a, b); + }, + getLowestCommonAncestor: function (a, b) { + return TreeTraversal.getLowestCommonAncestor(a, b); + }, + getParentInstance: function (inst) { + return TreeTraversal.getParentInstance(inst); + }, + traverseTwoPhase: function (target, fn, arg) { + return TreeTraversal.traverseTwoPhase(target, fn, arg); + }, + traverseEnterLeave: function (from, to, fn, argFrom, argTo) { + return TreeTraversal.traverseEnterLeave(from, to, fn, argFrom, argTo); + }, + + injection: injection +}; + +module.exports = EventPluginUtils; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 78 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var caughtError = null; + +/** + * Call a function while guarding against errors that happens within it. + * + * @param {String} name of the guard to use for logging or debugging + * @param {Function} func The function to invoke + * @param {*} a First argument + * @param {*} b Second argument + */ +function invokeGuardedCallback(name, func, a) { + try { + func(a); + } catch (x) { + if (caughtError === null) { + caughtError = x; + } + } +} + +var ReactErrorUtils = { + invokeGuardedCallback: invokeGuardedCallback, + + /** + * Invoked by ReactTestUtils.Simulate so that any errors thrown by the event + * handler are sure to be rethrown by rethrowCaughtError. + */ + invokeGuardedCallbackWithCatch: invokeGuardedCallback, + + /** + * During execution of guarded functions we will capture the first error which + * we will rethrow to be handled by the top level error handler. + */ + rethrowCaughtError: function () { + if (caughtError) { + var error = caughtError; + caughtError = null; + throw error; + } + } +}; + +if (process.env.NODE_ENV !== 'production') { + /** + * To help development we can get better devtools integration by simulating a + * real browser event. + */ + if (typeof window !== 'undefined' && typeof window.dispatchEvent === 'function' && typeof document !== 'undefined' && typeof document.createEvent === 'function') { + var fakeNode = document.createElement('react'); + ReactErrorUtils.invokeGuardedCallback = function (name, func, a) { + var boundFunc = func.bind(null, a); + var evtType = 'react-' + name; + fakeNode.addEventListener(evtType, boundFunc, false); + var evt = document.createEvent('Event'); + evt.initEvent(evtType, false, false); + fakeNode.dispatchEvent(evt); + fakeNode.removeEventListener(evtType, boundFunc, false); + }; + } +} + +module.exports = ReactErrorUtils; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 79 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * Gets the target node from a native browser event by accounting for + * inconsistencies in browser DOM APIs. + * + * @param {object} nativeEvent Native browser event. + * @return {DOMEventTarget} Target node. + */ + +function getEventTarget(nativeEvent) { + var target = nativeEvent.target || nativeEvent.srcElement || window; + + // Normalize SVG <use> element events #4963 + if (target.correspondingUseElement) { + target = target.correspondingUseElement; + } + + // Safari may fire events on text nodes (Node.TEXT_NODE is 3). + // @see http://www.quirksmode.org/js/events_properties.html + return target.nodeType === 3 ? target.parentNode : target; +} + +module.exports = getEventTarget; + +/***/ }), +/* 80 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +var useHasFeature; +if (ExecutionEnvironment.canUseDOM) { + useHasFeature = document.implementation && document.implementation.hasFeature && + // always returns true in newer browsers as per the standard. + // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature + document.implementation.hasFeature('', '') !== true; +} + +/** + * Checks if an event is supported in the current execution environment. + * + * NOTE: This will not work correctly for non-generic events such as `change`, + * `reset`, `load`, `error`, and `select`. + * + * Borrows from Modernizr. + * + * @param {string} eventNameSuffix Event name, e.g. "click". + * @param {?boolean} capture Check if the capture phase is supported. + * @return {boolean} True if the event is supported. + * @internal + * @license Modernizr 3.0.0pre (Custom Build) | MIT + */ +function isEventSupported(eventNameSuffix, capture) { + if (!ExecutionEnvironment.canUseDOM || capture && !('addEventListener' in document)) { + return false; + } + + var eventName = 'on' + eventNameSuffix; + var isSupported = eventName in document; + + if (!isSupported) { + var element = document.createElement('div'); + element.setAttribute(eventName, 'return;'); + isSupported = typeof element[eventName] === 'function'; + } + + if (!isSupported && useHasFeature && eventNameSuffix === 'wheel') { + // This is the only way to test support for the `wheel` event in IE9+. + isSupported = document.implementation.hasFeature('Events.wheel', '3.0'); + } + + return isSupported; +} + +module.exports = isEventSupported; + +/***/ }), +/* 81 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * Translation from modifier key to the associated property in the event. + * @see http://www.w3.org/TR/DOM-Level-3-Events/#keys-Modifiers + */ + +var modifierKeyToProp = { + Alt: 'altKey', + Control: 'ctrlKey', + Meta: 'metaKey', + Shift: 'shiftKey' +}; + +// IE8 does not implement getModifierState so we simply map it to the only +// modifier keys exposed by the event itself, does not support Lock-keys. +// Currently, all major browsers except Chrome seems to support Lock-keys. +function modifierStateGetter(keyArg) { + var syntheticEvent = this; + var nativeEvent = syntheticEvent.nativeEvent; + if (nativeEvent.getModifierState) { + return nativeEvent.getModifierState(keyArg); + } + var keyProp = modifierKeyToProp[keyArg]; + return keyProp ? !!nativeEvent[keyProp] : false; +} + +function getEventModifierState(nativeEvent) { + return modifierStateGetter; +} + +module.exports = getEventModifierState; + +/***/ }), +/* 82 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMLazyTree = __webpack_require__(39); +var Danger = __webpack_require__(249); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstrumentation = __webpack_require__(19); + +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); +var setInnerHTML = __webpack_require__(60); +var setTextContent = __webpack_require__(135); + +function getNodeAfter(parentNode, node) { + // Special case for text components, which return [open, close] comments + // from getHostNode. + if (Array.isArray(node)) { + node = node[1]; + } + return node ? node.nextSibling : parentNode.firstChild; +} + +/** + * Inserts `childNode` as a child of `parentNode` at the `index`. + * + * @param {DOMElement} parentNode Parent node in which to insert. + * @param {DOMElement} childNode Child node to insert. + * @param {number} index Index at which to insert the child. + * @internal + */ +var insertChildAt = createMicrosoftUnsafeLocalFunction(function (parentNode, childNode, referenceNode) { + // We rely exclusively on `insertBefore(node, null)` instead of also using + // `appendChild(node)`. (Using `undefined` is not allowed by all browsers so + // we are careful to use `null`.) + parentNode.insertBefore(childNode, referenceNode); +}); + +function insertLazyTreeChildAt(parentNode, childTree, referenceNode) { + DOMLazyTree.insertTreeBefore(parentNode, childTree, referenceNode); +} + +function moveChild(parentNode, childNode, referenceNode) { + if (Array.isArray(childNode)) { + moveDelimitedText(parentNode, childNode[0], childNode[1], referenceNode); + } else { + insertChildAt(parentNode, childNode, referenceNode); + } +} + +function removeChild(parentNode, childNode) { + if (Array.isArray(childNode)) { + var closingComment = childNode[1]; + childNode = childNode[0]; + removeDelimitedText(parentNode, childNode, closingComment); + parentNode.removeChild(closingComment); + } + parentNode.removeChild(childNode); +} + +function moveDelimitedText(parentNode, openingComment, closingComment, referenceNode) { + var node = openingComment; + while (true) { + var nextNode = node.nextSibling; + insertChildAt(parentNode, node, referenceNode); + if (node === closingComment) { + break; + } + node = nextNode; + } +} + +function removeDelimitedText(parentNode, startNode, closingComment) { + while (true) { + var node = startNode.nextSibling; + if (node === closingComment) { + // The closing comment is removed by ReactMultiChild. + break; + } else { + parentNode.removeChild(node); + } + } +} + +function replaceDelimitedText(openingComment, closingComment, stringText) { + var parentNode = openingComment.parentNode; + var nodeAfterComment = openingComment.nextSibling; + if (nodeAfterComment === closingComment) { + // There are no text nodes between the opening and closing comments; insert + // a new one if stringText isn't empty. + if (stringText) { + insertChildAt(parentNode, document.createTextNode(stringText), nodeAfterComment); + } + } else { + if (stringText) { + // Set the text content of the first node after the opening comment, and + // remove all following nodes up until the closing comment. + setTextContent(nodeAfterComment, stringText); + removeDelimitedText(parentNode, nodeAfterComment, closingComment); + } else { + removeDelimitedText(parentNode, openingComment, closingComment); + } + } + + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(openingComment)._debugID, + type: 'replace text', + payload: stringText + }); + } +} + +var dangerouslyReplaceNodeWithMarkup = Danger.dangerouslyReplaceNodeWithMarkup; +if (process.env.NODE_ENV !== 'production') { + dangerouslyReplaceNodeWithMarkup = function (oldChild, markup, prevInstance) { + Danger.dangerouslyReplaceNodeWithMarkup(oldChild, markup); + if (prevInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: prevInstance._debugID, + type: 'replace with', + payload: markup.toString() + }); + } else { + var nextInstance = ReactDOMComponentTree.getInstanceFromNode(markup.node); + if (nextInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: nextInstance._debugID, + type: 'mount', + payload: markup.toString() + }); + } + } + }; +} + +/** + * Operations for updating with DOM children. + */ +var DOMChildrenOperations = { + dangerouslyReplaceNodeWithMarkup: dangerouslyReplaceNodeWithMarkup, + + replaceDelimitedText: replaceDelimitedText, + + /** + * Updates a component's children by processing a series of updates. The + * update configurations are each expected to have a `parentNode` property. + * + * @param {array<object>} updates List of update configurations. + * @internal + */ + processUpdates: function (parentNode, updates) { + if (process.env.NODE_ENV !== 'production') { + var parentNodeDebugID = ReactDOMComponentTree.getInstanceFromNode(parentNode)._debugID; + } + + for (var k = 0; k < updates.length; k++) { + var update = updates[k]; + switch (update.type) { + case 'INSERT_MARKUP': + insertLazyTreeChildAt(parentNode, update.content, getNodeAfter(parentNode, update.afterNode)); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'insert child', + payload: { + toIndex: update.toIndex, + content: update.content.toString() + } + }); + } + break; + case 'MOVE_EXISTING': + moveChild(parentNode, update.fromNode, getNodeAfter(parentNode, update.afterNode)); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'move child', + payload: { fromIndex: update.fromIndex, toIndex: update.toIndex } + }); + } + break; + case 'SET_MARKUP': + setInnerHTML(parentNode, update.content); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'replace children', + payload: update.content.toString() + }); + } + break; + case 'TEXT_CONTENT': + setTextContent(parentNode, update.content); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'replace text', + payload: update.content.toString() + }); + } + break; + case 'REMOVE_NODE': + removeChild(parentNode, update.fromNode); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'remove child', + payload: { fromIndex: update.fromIndex } + }); + } + break; + } + } + } +}; + +module.exports = DOMChildrenOperations; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 83 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMNamespaces = { + html: 'http://www.w3.org/1999/xhtml', + mathml: 'http://www.w3.org/1998/Math/MathML', + svg: 'http://www.w3.org/2000/svg' +}; + +module.exports = DOMNamespaces; + +/***/ }), +/* 84 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/* globals MSApp */ + + + +/** + * Create a function which has 'unsafe' privileges (required by windows8 apps) + */ + +var createMicrosoftUnsafeLocalFunction = function (func) { + if (typeof MSApp !== 'undefined' && MSApp.execUnsafeLocalFunction) { + return function (arg0, arg1, arg2, arg3) { + MSApp.execUnsafeLocalFunction(function () { + return func(arg0, arg1, arg2, arg3); + }); + }; + } else { + return func; + } +}; + +module.exports = createMicrosoftUnsafeLocalFunction; + +/***/ }), +/* 85 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactPropTypesSecret = __webpack_require__(139); +var propTypesFactory = __webpack_require__(124); + +var React = __webpack_require__(36); +var PropTypes = propTypesFactory(React.isValidElement); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var hasReadOnlyValue = { + button: true, + checkbox: true, + image: true, + hidden: true, + radio: true, + reset: true, + submit: true +}; + +function _assertSingleLink(inputProps) { + !(inputProps.checkedLink == null || inputProps.valueLink == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a valueLink. If you want to use checkedLink, you probably don\'t want to use valueLink and vice versa.') : _prodInvariant('87') : void 0; +} +function _assertValueLink(inputProps) { + _assertSingleLink(inputProps); + !(inputProps.value == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a valueLink and a value or onChange event. If you want to use value or onChange, you probably don\'t want to use valueLink.') : _prodInvariant('88') : void 0; +} + +function _assertCheckedLink(inputProps) { + _assertSingleLink(inputProps); + !(inputProps.checked == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a checked property or onChange event. If you want to use checked or onChange, you probably don\'t want to use checkedLink') : _prodInvariant('89') : void 0; +} + +var propTypes = { + value: function (props, propName, componentName) { + if (!props[propName] || hasReadOnlyValue[props.type] || props.onChange || props.readOnly || props.disabled) { + return null; + } + return new Error('You provided a `value` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultValue`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); + }, + checked: function (props, propName, componentName) { + if (!props[propName] || props.onChange || props.readOnly || props.disabled) { + return null; + } + return new Error('You provided a `checked` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultChecked`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); + }, + onChange: PropTypes.func +}; + +var loggedTypeFailures = {}; +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} + +/** + * Provide a linked `value` attribute for controlled forms. You should not use + * this outside of the ReactDOM controlled form components. + */ +var LinkedValueUtils = { + checkPropTypes: function (tagName, props, owner) { + for (var propName in propTypes) { + if (propTypes.hasOwnProperty(propName)) { + var error = propTypes[propName](props, propName, tagName, 'prop', null, ReactPropTypesSecret); + } + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var addendum = getDeclarationErrorAddendum(owner); + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed form propType: %s%s', error.message, addendum) : void 0; + } + } + }, + + /** + * @param {object} inputProps Props for form component + * @return {*} current value of the input either from value prop or link. + */ + getValue: function (inputProps) { + if (inputProps.valueLink) { + _assertValueLink(inputProps); + return inputProps.valueLink.value; + } + return inputProps.value; + }, + + /** + * @param {object} inputProps Props for form component + * @return {*} current checked status of the input either from checked prop + * or link. + */ + getChecked: function (inputProps) { + if (inputProps.checkedLink) { + _assertCheckedLink(inputProps); + return inputProps.checkedLink.value; + } + return inputProps.checked; + }, + + /** + * @param {object} inputProps Props for form component + * @param {SyntheticEvent} event change event to handle + */ + executeOnChange: function (inputProps, event) { + if (inputProps.valueLink) { + _assertValueLink(inputProps); + return inputProps.valueLink.requestChange(event.target.value); + } else if (inputProps.checkedLink) { + _assertCheckedLink(inputProps); + return inputProps.checkedLink.requestChange(event.target.checked); + } else if (inputProps.onChange) { + return inputProps.onChange.call(undefined, event); + } + } +}; + +module.exports = LinkedValueUtils; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 86 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +var injected = false; + +var ReactComponentEnvironment = { + /** + * Optionally injectable hook for swapping out mount images in the middle of + * the tree. + */ + replaceNodeWithMarkup: null, + + /** + * Optionally injectable hook for processing a queue of child updates. Will + * later move into MultiChildComponents. + */ + processChildrenUpdates: null, + + injection: { + injectEnvironment: function (environment) { + !!injected ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactCompositeComponent: injectEnvironment() can only be called once.') : _prodInvariant('104') : void 0; + ReactComponentEnvironment.replaceNodeWithMarkup = environment.replaceNodeWithMarkup; + ReactComponentEnvironment.processChildrenUpdates = environment.processChildrenUpdates; + injected = true; + } + } +}; + +module.exports = ReactComponentEnvironment; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 87 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + * + */ + +/*eslint-disable no-self-compare */ + + + +var hasOwnProperty = Object.prototype.hasOwnProperty; + +/** + * inlined Object.is polyfill to avoid requiring consumers ship their own + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is + */ +function is(x, y) { + // SameValue algorithm + if (x === y) { + // Steps 1-5, 7-10 + // Steps 6.b-6.e: +0 != -0 + // Added the nonzero y check to make Flow happy, but it is redundant + return x !== 0 || y !== 0 || 1 / x === 1 / y; + } else { + // Step 6.a: NaN == NaN + return x !== x && y !== y; + } +} + +/** + * Performs equality by iterating through keys on an object and returning false + * when any key has values which are not strictly equal between the arguments. + * Returns true when the values of all keys are strictly equal. + */ +function shallowEqual(objA, objB) { + if (is(objA, objB)) { + return true; + } + + if (typeof objA !== 'object' || objA === null || typeof objB !== 'object' || objB === null) { + return false; + } + + var keysA = Object.keys(objA); + var keysB = Object.keys(objB); + + if (keysA.length !== keysB.length) { + return false; + } + + // Test for A's keys different from B. + for (var i = 0; i < keysA.length; i++) { + if (!hasOwnProperty.call(objB, keysA[i]) || !is(objA[keysA[i]], objB[keysA[i]])) { + return false; + } + } + + return true; +} + +module.exports = shallowEqual; + +/***/ }), +/* 88 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * Given a `prevElement` and `nextElement`, determines if the existing + * instance should be updated as opposed to being destroyed or replaced by a new + * instance. Both arguments are elements. This ensures that this logic can + * operate on stateless trees without any backing instance. + * + * @param {?object} prevElement + * @param {?object} nextElement + * @return {boolean} True if the existing instance should be updated. + * @protected + */ + +function shouldUpdateReactComponent(prevElement, nextElement) { + var prevEmpty = prevElement === null || prevElement === false; + var nextEmpty = nextElement === null || nextElement === false; + if (prevEmpty || nextEmpty) { + return prevEmpty === nextEmpty; + } + + var prevType = typeof prevElement; + var nextType = typeof nextElement; + if (prevType === 'string' || prevType === 'number') { + return nextType === 'string' || nextType === 'number'; + } else { + return nextType === 'object' && prevElement.type === nextElement.type && prevElement.key === nextElement.key; + } +} + +module.exports = shouldUpdateReactComponent; + +/***/ }), +/* 89 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/** + * Escape and wrap key so it is safe to use as a reactid + * + * @param {string} key to be escaped. + * @return {string} the escaped key. + */ + +function escape(key) { + var escapeRegex = /[=:]/g; + var escaperLookup = { + '=': '=0', + ':': '=2' + }; + var escapedString = ('' + key).replace(escapeRegex, function (match) { + return escaperLookup[match]; + }); + + return '$' + escapedString; +} + +/** + * Unescape and unwrap key for human-readable display + * + * @param {string} key to unescape. + * @return {string} the unescaped key. + */ +function unescape(key) { + var unescapeRegex = /(=0|=2)/g; + var unescaperLookup = { + '=0': '=', + '=2': ':' + }; + var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); + + return ('' + keySubstring).replace(unescapeRegex, function (match) { + return unescaperLookup[match]; + }); +} + +var KeyEscapeUtils = { + escape: escape, + unescape: unescape +}; + +module.exports = KeyEscapeUtils; + +/***/ }), +/* 90 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactCurrentOwner = __webpack_require__(22); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactUpdates = __webpack_require__(23); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +function enqueueUpdate(internalInstance) { + ReactUpdates.enqueueUpdate(internalInstance); +} + +function formatUnexpectedArgument(arg) { + var type = typeof arg; + if (type !== 'object') { + return type; + } + var displayName = arg.constructor && arg.constructor.name || type; + var keys = Object.keys(arg); + if (keys.length > 0 && keys.length < 20) { + return displayName + ' (keys: ' + keys.join(', ') + ')'; + } + return displayName; +} + +function getInternalInstanceReadyForUpdate(publicInstance, callerName) { + var internalInstance = ReactInstanceMap.get(publicInstance); + if (!internalInstance) { + if (process.env.NODE_ENV !== 'production') { + var ctor = publicInstance.constructor; + // Only warn when we have a callerName. Otherwise we should be silent. + // We're probably calling from enqueueCallback. We don't want to warn + // there because we already warned for the corresponding lifecycle method. + process.env.NODE_ENV !== 'production' ? warning(!callerName, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, ctor && (ctor.displayName || ctor.name) || 'ReactClass') : void 0; + } + return null; + } + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '%s(...): Cannot update during an existing state transition (such as ' + "within `render` or another component's constructor). Render methods " + 'should be a pure function of props and state; constructor ' + 'side-effects are an anti-pattern, but can be moved to ' + '`componentWillMount`.', callerName) : void 0; + } + + return internalInstance; +} + +/** + * ReactUpdateQueue allows for state updates to be scheduled into a later + * reconciliation step. + */ +var ReactUpdateQueue = { + /** + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + isMounted: function (publicInstance) { + if (process.env.NODE_ENV !== 'production') { + var owner = ReactCurrentOwner.current; + if (owner !== null) { + process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing isMounted inside its render() function. ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; + owner._warnedAboutRefsInRender = true; + } + } + var internalInstance = ReactInstanceMap.get(publicInstance); + if (internalInstance) { + // During componentWillMount and render this will still be null but after + // that will always render to something. At least for now. So we can use + // this hack. + return !!internalInstance._renderedComponent; + } else { + return false; + } + }, + + /** + * Enqueue a callback that will be executed after all the pending updates + * have processed. + * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @param {string} callerName Name of the calling function in the public API. + * @internal + */ + enqueueCallback: function (publicInstance, callback, callerName) { + ReactUpdateQueue.validateCallback(callback, callerName); + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance); + + // Previously we would throw an error if we didn't have an internal + // instance. Since we want to make it a no-op instead, we mirror the same + // behavior we have in other enqueue* methods. + // We also need to ignore callbacks in componentWillMount. See + // enqueueUpdates. + if (!internalInstance) { + return null; + } + + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); + } else { + internalInstance._pendingCallbacks = [callback]; + } + // TODO: The callback here is ignored when setState is called from + // componentWillMount. Either fix it or disallow doing so completely in + // favor of getInitialState. Alternatively, we can disallow + // componentWillMount during server-side rendering. + enqueueUpdate(internalInstance); + }, + + enqueueCallbackInternal: function (internalInstance, callback) { + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); + } else { + internalInstance._pendingCallbacks = [callback]; + } + enqueueUpdate(internalInstance); + }, + + /** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal + */ + enqueueForceUpdate: function (publicInstance) { + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'forceUpdate'); + + if (!internalInstance) { + return; + } + + internalInstance._pendingForceUpdate = true; + + enqueueUpdate(internalInstance); + }, + + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} completeState Next state. + * @internal + */ + enqueueReplaceState: function (publicInstance, completeState, callback) { + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'replaceState'); + + if (!internalInstance) { + return; + } + + internalInstance._pendingStateQueue = [completeState]; + internalInstance._pendingReplaceState = true; + + // Future-proof 15.5 + if (callback !== undefined && callback !== null) { + ReactUpdateQueue.validateCallback(callback, 'replaceState'); + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); + } else { + internalInstance._pendingCallbacks = [callback]; + } + } + + enqueueUpdate(internalInstance); + }, + + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} partialState Next partial state to be merged with state. + * @internal + */ + enqueueSetState: function (publicInstance, partialState) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetState(); + process.env.NODE_ENV !== 'production' ? warning(partialState != null, 'setState(...): You passed an undefined or null state object; ' + 'instead, use forceUpdate().') : void 0; + } + + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'setState'); + + if (!internalInstance) { + return; + } + + var queue = internalInstance._pendingStateQueue || (internalInstance._pendingStateQueue = []); + queue.push(partialState); + + enqueueUpdate(internalInstance); + }, + + enqueueElementInternal: function (internalInstance, nextElement, nextContext) { + internalInstance._pendingElement = nextElement; + // TODO: introduce _pendingContext instead of setting it directly. + internalInstance._context = nextContext; + enqueueUpdate(internalInstance); + }, + + validateCallback: function (callback, callerName) { + !(!callback || typeof callback === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.', callerName, formatUnexpectedArgument(callback)) : _prodInvariant('122', callerName, formatUnexpectedArgument(callback)) : void 0; + } +}; + +module.exports = ReactUpdateQueue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 91 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var emptyFunction = __webpack_require__(18); +var warning = __webpack_require__(3); + +var validateDOMNesting = emptyFunction; + +if (process.env.NODE_ENV !== 'production') { + // This validation code was written based on the HTML5 parsing spec: + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope + // + // Note: this does not catch all invalid nesting, nor does it try to (as it's + // not clear what practical benefit doing so provides); instead, we warn only + // for cases where the parser will give a parse tree differing from what React + // intended. For example, <b><div></div></b> is invalid but we don't warn + // because it still parses correctly; we do warn for other cases like nested + // <p> tags where the beginning of the second element implicitly closes the + // first, causing a confusing mess. + + // https://html.spec.whatwg.org/multipage/syntax.html#special + var specialTags = ['address', 'applet', 'area', 'article', 'aside', 'base', 'basefont', 'bgsound', 'blockquote', 'body', 'br', 'button', 'caption', 'center', 'col', 'colgroup', 'dd', 'details', 'dir', 'div', 'dl', 'dt', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'frame', 'frameset', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'iframe', 'img', 'input', 'isindex', 'li', 'link', 'listing', 'main', 'marquee', 'menu', 'menuitem', 'meta', 'nav', 'noembed', 'noframes', 'noscript', 'object', 'ol', 'p', 'param', 'plaintext', 'pre', 'script', 'section', 'select', 'source', 'style', 'summary', 'table', 'tbody', 'td', 'template', 'textarea', 'tfoot', 'th', 'thead', 'title', 'tr', 'track', 'ul', 'wbr', 'xmp']; + + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope + var inScopeTags = ['applet', 'caption', 'html', 'table', 'td', 'th', 'marquee', 'object', 'template', + + // https://html.spec.whatwg.org/multipage/syntax.html#html-integration-point + // TODO: Distinguish by namespace here -- for <title>, including it here + // errs on the side of fewer warnings + 'foreignObject', 'desc', 'title']; + + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-button-scope + var buttonScopeTags = inScopeTags.concat(['button']); + + // https://html.spec.whatwg.org/multipage/syntax.html#generate-implied-end-tags + var impliedEndTags = ['dd', 'dt', 'li', 'option', 'optgroup', 'p', 'rp', 'rt']; + + var emptyAncestorInfo = { + current: null, + + formTag: null, + aTagInScope: null, + buttonTagInScope: null, + nobrTagInScope: null, + pTagInButtonScope: null, + + listItemTagAutoclosing: null, + dlItemTagAutoclosing: null + }; + + var updatedAncestorInfo = function (oldInfo, tag, instance) { + var ancestorInfo = _assign({}, oldInfo || emptyAncestorInfo); + var info = { tag: tag, instance: instance }; + + if (inScopeTags.indexOf(tag) !== -1) { + ancestorInfo.aTagInScope = null; + ancestorInfo.buttonTagInScope = null; + ancestorInfo.nobrTagInScope = null; + } + if (buttonScopeTags.indexOf(tag) !== -1) { + ancestorInfo.pTagInButtonScope = null; + } + + // See rules for 'li', 'dd', 'dt' start tags in + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody + if (specialTags.indexOf(tag) !== -1 && tag !== 'address' && tag !== 'div' && tag !== 'p') { + ancestorInfo.listItemTagAutoclosing = null; + ancestorInfo.dlItemTagAutoclosing = null; + } + + ancestorInfo.current = info; + + if (tag === 'form') { + ancestorInfo.formTag = info; + } + if (tag === 'a') { + ancestorInfo.aTagInScope = info; + } + if (tag === 'button') { + ancestorInfo.buttonTagInScope = info; + } + if (tag === 'nobr') { + ancestorInfo.nobrTagInScope = info; + } + if (tag === 'p') { + ancestorInfo.pTagInButtonScope = info; + } + if (tag === 'li') { + ancestorInfo.listItemTagAutoclosing = info; + } + if (tag === 'dd' || tag === 'dt') { + ancestorInfo.dlItemTagAutoclosing = info; + } + + return ancestorInfo; + }; + + /** + * Returns whether + */ + var isTagValidWithParent = function (tag, parentTag) { + // First, let's check if we're in an unusual parsing mode... + switch (parentTag) { + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inselect + case 'select': + return tag === 'option' || tag === 'optgroup' || tag === '#text'; + case 'optgroup': + return tag === 'option' || tag === '#text'; + // Strictly speaking, seeing an <option> doesn't mean we're in a <select> + // but + case 'option': + return tag === '#text'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intd + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incaption + // No special behavior since these rules fall back to "in body" mode for + // all except special table nodes which cause bad parsing behavior anyway. + + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intr + case 'tr': + return tag === 'th' || tag === 'td' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intbody + case 'tbody': + case 'thead': + case 'tfoot': + return tag === 'tr' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incolgroup + case 'colgroup': + return tag === 'col' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intable + case 'table': + return tag === 'caption' || tag === 'colgroup' || tag === 'tbody' || tag === 'tfoot' || tag === 'thead' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inhead + case 'head': + return tag === 'base' || tag === 'basefont' || tag === 'bgsound' || tag === 'link' || tag === 'meta' || tag === 'title' || tag === 'noscript' || tag === 'noframes' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/semantics.html#the-html-element + case 'html': + return tag === 'head' || tag === 'body'; + case '#document': + return tag === 'html'; + } + + // Probably in the "in body" parsing mode, so we outlaw only tag combos + // where the parsing rules cause implicit opens or closes to be added. + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody + switch (tag) { + case 'h1': + case 'h2': + case 'h3': + case 'h4': + case 'h5': + case 'h6': + return parentTag !== 'h1' && parentTag !== 'h2' && parentTag !== 'h3' && parentTag !== 'h4' && parentTag !== 'h5' && parentTag !== 'h6'; + + case 'rp': + case 'rt': + return impliedEndTags.indexOf(parentTag) === -1; + + case 'body': + case 'caption': + case 'col': + case 'colgroup': + case 'frame': + case 'head': + case 'html': + case 'tbody': + case 'td': + case 'tfoot': + case 'th': + case 'thead': + case 'tr': + // These tags are only valid with a few parents that have special child + // parsing rules -- if we're down here, then none of those matched and + // so we allow it only if we don't know what the parent is, as all other + // cases are invalid. + return parentTag == null; + } + + return true; + }; + + /** + * Returns whether + */ + var findInvalidAncestorForTag = function (tag, ancestorInfo) { + switch (tag) { + case 'address': + case 'article': + case 'aside': + case 'blockquote': + case 'center': + case 'details': + case 'dialog': + case 'dir': + case 'div': + case 'dl': + case 'fieldset': + case 'figcaption': + case 'figure': + case 'footer': + case 'header': + case 'hgroup': + case 'main': + case 'menu': + case 'nav': + case 'ol': + case 'p': + case 'section': + case 'summary': + case 'ul': + case 'pre': + case 'listing': + case 'table': + case 'hr': + case 'xmp': + case 'h1': + case 'h2': + case 'h3': + case 'h4': + case 'h5': + case 'h6': + return ancestorInfo.pTagInButtonScope; + + case 'form': + return ancestorInfo.formTag || ancestorInfo.pTagInButtonScope; + + case 'li': + return ancestorInfo.listItemTagAutoclosing; + + case 'dd': + case 'dt': + return ancestorInfo.dlItemTagAutoclosing; + + case 'button': + return ancestorInfo.buttonTagInScope; + + case 'a': + // Spec says something about storing a list of markers, but it sounds + // equivalent to this check. + return ancestorInfo.aTagInScope; + + case 'nobr': + return ancestorInfo.nobrTagInScope; + } + + return null; + }; + + /** + * Given a ReactCompositeComponent instance, return a list of its recursive + * owners, starting at the root and ending with the instance itself. + */ + var findOwnerStack = function (instance) { + if (!instance) { + return []; + } + + var stack = []; + do { + stack.push(instance); + } while (instance = instance._currentElement._owner); + stack.reverse(); + return stack; + }; + + var didWarn = {}; + + validateDOMNesting = function (childTag, childText, childInstance, ancestorInfo) { + ancestorInfo = ancestorInfo || emptyAncestorInfo; + var parentInfo = ancestorInfo.current; + var parentTag = parentInfo && parentInfo.tag; + + if (childText != null) { + process.env.NODE_ENV !== 'production' ? warning(childTag == null, 'validateDOMNesting: when childText is passed, childTag should be null') : void 0; + childTag = '#text'; + } + + var invalidParent = isTagValidWithParent(childTag, parentTag) ? null : parentInfo; + var invalidAncestor = invalidParent ? null : findInvalidAncestorForTag(childTag, ancestorInfo); + var problematic = invalidParent || invalidAncestor; + + if (problematic) { + var ancestorTag = problematic.tag; + var ancestorInstance = problematic.instance; + + var childOwner = childInstance && childInstance._currentElement._owner; + var ancestorOwner = ancestorInstance && ancestorInstance._currentElement._owner; + + var childOwners = findOwnerStack(childOwner); + var ancestorOwners = findOwnerStack(ancestorOwner); + + var minStackLen = Math.min(childOwners.length, ancestorOwners.length); + var i; + + var deepestCommon = -1; + for (i = 0; i < minStackLen; i++) { + if (childOwners[i] === ancestorOwners[i]) { + deepestCommon = i; + } else { + break; + } + } + + var UNKNOWN = '(unknown)'; + var childOwnerNames = childOwners.slice(deepestCommon + 1).map(function (inst) { + return inst.getName() || UNKNOWN; + }); + var ancestorOwnerNames = ancestorOwners.slice(deepestCommon + 1).map(function (inst) { + return inst.getName() || UNKNOWN; + }); + var ownerInfo = [].concat( + // If the parent and child instances have a common owner ancestor, start + // with that -- otherwise we just start with the parent's owners. + deepestCommon !== -1 ? childOwners[deepestCommon].getName() || UNKNOWN : [], ancestorOwnerNames, ancestorTag, + // If we're warning about an invalid (non-parent) ancestry, add '...' + invalidAncestor ? ['...'] : [], childOwnerNames, childTag).join(' > '); + + var warnKey = !!invalidParent + '|' + childTag + '|' + ancestorTag + '|' + ownerInfo; + if (didWarn[warnKey]) { + return; + } + didWarn[warnKey] = true; + + var tagDisplayName = childTag; + var whitespaceInfo = ''; + if (childTag === '#text') { + if (/\S/.test(childText)) { + tagDisplayName = 'Text nodes'; + } else { + tagDisplayName = 'Whitespace text nodes'; + whitespaceInfo = " Make sure you don't have any extra whitespace between tags on " + 'each line of your source code.'; + } + } else { + tagDisplayName = '<' + childTag + '>'; + } + + if (invalidParent) { + var info = ''; + if (ancestorTag === 'table' && childTag === 'tr') { + info += ' Add a <tbody> to your code to match the DOM tree generated by ' + 'the browser.'; + } + process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a child of <%s>.%s ' + 'See %s.%s', tagDisplayName, ancestorTag, whitespaceInfo, ownerInfo, info) : void 0; + } else { + process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a descendant of ' + '<%s>. See %s.', tagDisplayName, ancestorTag, ownerInfo) : void 0; + } + } + }; + + validateDOMNesting.updatedAncestorInfo = updatedAncestorInfo; + + // For testing + validateDOMNesting.isTagValidInContext = function (tag, ancestorInfo) { + ancestorInfo = ancestorInfo || emptyAncestorInfo; + var parentInfo = ancestorInfo.current; + var parentTag = parentInfo && parentInfo.tag; + return isTagValidWithParent(tag, parentTag) && !findInvalidAncestorForTag(tag, ancestorInfo); + }; +} + +module.exports = validateDOMNesting; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 92 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * `charCode` represents the actual "character code" and is safe to use with + * `String.fromCharCode`. As such, only keys that correspond to printable + * characters produce a valid `charCode`, the only exception to this is Enter. + * The Tab-key is considered non-printable and does not have a `charCode`, + * presumably because it does not produce a tab-character in browsers. + * + * @param {object} nativeEvent Native browser event. + * @return {number} Normalized `charCode` property. + */ + +function getEventCharCode(nativeEvent) { + var charCode; + var keyCode = nativeEvent.keyCode; + + if ('charCode' in nativeEvent) { + charCode = nativeEvent.charCode; + + // FF does not set `charCode` for the Enter-key, check against `keyCode`. + if (charCode === 0 && keyCode === 13) { + charCode = 13; + } + } else { + // IE8 does not implement `charCode`, but `keyCode` has the correct value. + charCode = keyCode; + } + + // Some non-printable keys are reported in `charCode`/`keyCode`, discard them. + // Must not discard the (non-)printable Enter-key. + if (charCode >= 32 || charCode === 13) { + return charCode; + } + + return 0; +} + +module.exports = getEventCharCode; + +/***/ }), +/* 93 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Alert", function() { return Alert; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Container", function() { return Container; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Row", function() { return Row; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Col", function() { return Col; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Navbar", function() { return Navbar; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarBrand", function() { return NavbarBrand; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarToggler", function() { return NavbarToggler; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Nav", function() { return Nav; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavItem", function() { return NavItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavDropdown", function() { return NavDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavLink", function() { return NavLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Breadcrumb", function() { return Breadcrumb; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BreadcrumbItem", function() { return BreadcrumbItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Button", function() { return Button; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonDropdown", function() { return ButtonDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonGroup", function() { return ButtonGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonToolbar", function() { return ButtonToolbar; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Dropdown", function() { return Dropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownItem", function() { return DropdownItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownMenu", function() { return DropdownMenu; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownToggle", function() { return DropdownToggle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Fade", function() { return Fade; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Badge", function() { return Badge; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Card", function() { return Card; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardLink", function() { return CardLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardGroup", function() { return CardGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardDeck", function() { return CardDeck; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardColumns", function() { return CardColumns; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardBlock", function() { return CardBlock; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardFooter", function() { return CardFooter; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardHeader", function() { return CardHeader; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImg", function() { return CardImg; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImgOverlay", function() { return CardImgOverlay; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardSubtitle", function() { return CardSubtitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardText", function() { return CardText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardTitle", function() { return CardTitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Popover", function() { return Popover; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverContent", function() { return PopoverContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverTitle", function() { return PopoverTitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Progress", function() { return Progress; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Modal", function() { return Modal; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalHeader", function() { return ModalHeader; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalBody", function() { return ModalBody; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalFooter", function() { return ModalFooter; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TetherContent", function() { return TetherContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Tooltip", function() { return Tooltip; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Table", function() { return Table; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroup", function() { return ListGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Form", function() { return Form; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormFeedback", function() { return FormFeedback; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormGroup", function() { return FormGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormText", function() { return FormText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Input", function() { return Input; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroup", function() { return InputGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupAddon", function() { return InputGroupAddon; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupButton", function() { return InputGroupButton; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Label", function() { return Label; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Media", function() { return Media; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Pagination", function() { return Pagination; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationItem", function() { return PaginationItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationLink", function() { return PaginationLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabContent", function() { return TabContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabPane", function() { return TabPane; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Jumbotron", function() { return Jumbotron; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Collapse", function() { return Collapse; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItem", function() { return ListGroupItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemText", function() { return ListGroupItemText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemHeading", function() { return ListGroupItemHeading; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledAlert", function() { return UncontrolledAlert; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledButtonDropdown", function() { return UncontrolledButtonDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledDropdown", function() { return UncontrolledDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledNavDropdown", function() { return UncontrolledNavDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledTooltip", function() { return UncontrolledTooltip; }); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(6); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(40); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames__ = __webpack_require__(41); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_classnames__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject__ = __webpack_require__(317); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_lodash_isobject__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom__ = __webpack_require__(76); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_react_dom__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__ = __webpack_require__(318); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__ = __webpack_require__(319); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__ = __webpack_require__(320); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group__ = __webpack_require__(321); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8_react_transition_group__); + + + + + + + + + + +function getTetherAttachments(placement) { + var attachments = {}; + switch (placement) { + case 'top': + case 'top center': + attachments = { + attachment: 'bottom center', + targetAttachment: 'top center' + }; + break; + case 'bottom': + case 'bottom center': + attachments = { + attachment: 'top center', + targetAttachment: 'bottom center' + }; + break; + case 'left': + case 'left center': + attachments = { + attachment: 'middle right', + targetAttachment: 'middle left' + }; + break; + case 'right': + case 'right center': + attachments = { + attachment: 'middle left', + targetAttachment: 'middle right' + }; + break; + case 'top left': + attachments = { + attachment: 'bottom left', + targetAttachment: 'top left' + }; + break; + case 'top right': + attachments = { + attachment: 'bottom right', + targetAttachment: 'top right' + }; + break; + case 'bottom left': + attachments = { + attachment: 'top left', + targetAttachment: 'bottom left' + }; + break; + case 'bottom right': + attachments = { + attachment: 'top right', + targetAttachment: 'bottom right' + }; + break; + case 'right top': + attachments = { + attachment: 'top left', + targetAttachment: 'top right' + }; + break; + case 'right bottom': + attachments = { + attachment: 'bottom left', + targetAttachment: 'bottom right' + }; + break; + case 'left top': + attachments = { + attachment: 'top right', + targetAttachment: 'top left' + }; + break; + case 'left bottom': + attachments = { + attachment: 'bottom right', + targetAttachment: 'bottom left' + }; + break; + default: + attachments = { + attachment: 'top center', + targetAttachment: 'bottom center' + }; + } + + return attachments; +} + +var tetherAttachements = ['top', 'bottom', 'left', 'right', 'top left', 'top center', 'top right', 'right top', 'right middle', 'right bottom', 'bottom right', 'bottom center', 'bottom left', 'left top', 'left middle', 'left bottom']; + +// https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L436-L443 +function getScrollbarWidth() { + var scrollDiv = document.createElement('div'); + // .modal-scrollbar-measure styles // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/scss/_modal.scss#L106-L113 + scrollDiv.style.position = 'absolute'; + scrollDiv.style.top = '-9999px'; + scrollDiv.style.width = '50px'; + scrollDiv.style.height = '50px'; + scrollDiv.style.overflow = 'scroll'; + document.body.appendChild(scrollDiv); + var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth; + document.body.removeChild(scrollDiv); + return scrollbarWidth; +} + +function setScrollbarWidth(padding) { + document.body.style.paddingRight = padding > 0 ? padding + 'px' : null; +} + +function isBodyOverflowing() { + return document.body.clientWidth < window.innerWidth; +} + +function getOriginalBodyPadding() { + return parseInt(window.getComputedStyle(document.body, null).getPropertyValue('padding-right') || 0, 10); +} + +function conditionallyUpdateScrollbar() { + var scrollbarWidth = getScrollbarWidth(); + // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L420 + var fixedContent = document.querySelectorAll('.navbar-fixed-top, .navbar-fixed-bottom, .is-fixed')[0]; + var bodyPadding = fixedContent ? parseInt(fixedContent.style.paddingRight || 0, 10) : 0; + + if (isBodyOverflowing()) { + setScrollbarWidth(bodyPadding + scrollbarWidth); + } +} + +function mapToCssModules(className, cssModule) { + if (!cssModule) return className; + return className.split(' ').map(function (c) { + return cssModule[c] || c; + }).join(' '); +} + +/** + * Returns a new object with the key/value pairs from `obj` that are not in the array `omitKeys`. + */ +function omit(obj, omitKeys) { + var result = {}; + Object.keys(obj).forEach(function (key) { + if (omitKeys.indexOf(key) === -1) { + result[key] = obj[key]; + } + }); + return result; +} + +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { + return typeof obj; +} : function (obj) { + return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; +}; + + + + + + + + + + + +var classCallCheck = function (instance, Constructor) { + if (!(instance instanceof Constructor)) { + throw new TypeError("Cannot call a class as a function"); + } +}; + +var createClass = function () { + function defineProperties(target, props) { + for (var i = 0; i < props.length; i++) { + var descriptor = props[i]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + + return function (Constructor, protoProps, staticProps) { + if (protoProps) defineProperties(Constructor.prototype, protoProps); + if (staticProps) defineProperties(Constructor, staticProps); + return Constructor; + }; +}(); + + + + + +var defineProperty = function (obj, key, value) { + if (key in obj) { + Object.defineProperty(obj, key, { + value: value, + enumerable: true, + configurable: true, + writable: true + }); + } else { + obj[key] = value; + } + + return obj; +}; + +var _extends = Object.assign || function (target) { + for (var i = 1; i < arguments.length; i++) { + var source = arguments[i]; + + for (var key in source) { + if (Object.prototype.hasOwnProperty.call(source, key)) { + target[key] = source[key]; + } + } + } + + return target; +}; + + + +var inherits = function (subClass, superClass) { + if (typeof superClass !== "function" && superClass !== null) { + throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); + } + + subClass.prototype = Object.create(superClass && superClass.prototype, { + constructor: { + value: subClass, + enumerable: false, + writable: true, + configurable: true + } + }); + if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; +}; + + + + + + + + + +var objectWithoutProperties = function (obj, keys) { + var target = {}; + + for (var i in obj) { + if (keys.indexOf(i) >= 0) continue; + if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; + target[i] = obj[i]; + } + + return target; +}; + +var possibleConstructorReturn = function (self, call) { + if (!self) { + throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); + } + + return call && (typeof call === "object" || typeof call === "function") ? call : self; +}; + +var propTypes = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps = { + tag: 'div' +}; + +var Container = function Container(props) { + var className = props.className, + cssModule = props.cssModule, + fluid = props.fluid, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'fluid', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, fluid ? 'container-fluid' : 'container'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Container.propTypes = propTypes; +Container.defaultProps = defaultProps; + +var propTypes$1 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + noGutters: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$1 = { + tag: 'div' +}; + +var Row = function Row(props) { + var className = props.className, + cssModule = props.cssModule, + noGutters = props.noGutters, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'noGutters', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, noGutters ? 'no-gutters' : null, 'row'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Row.propTypes = propTypes$1; +Row.defaultProps = defaultProps$1; + +var colWidths = ['xs', 'sm', 'md', 'lg', 'xl']; +var stringOrNumberProp = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); + +var columnProps = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + push: stringOrNumberProp, + pull: stringOrNumberProp, + offset: stringOrNumberProp +})]); + +var propTypes$2 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + xs: columnProps, + sm: columnProps, + md: columnProps, + lg: columnProps, + xl: columnProps, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + widths: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.array +}; + +var defaultProps$2 = { + tag: 'div', + widths: colWidths +}; + +var getColumnSizeClass = function getColumnSizeClass(isXs, colWidth, colSize) { + if (colSize === true || colSize === '') { + return isXs ? 'col' : 'col-' + colWidth; + } else if (colSize === 'auto') { + return isXs ? 'col-auto' : 'col-' + colWidth + '-auto'; + } + + return isXs ? 'col-' + colSize : 'col-' + colWidth + '-' + colSize; +}; + +var Col = function Col(props) { + var className = props.className, + cssModule = props.cssModule, + widths = props.widths, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'widths', 'tag']); + + var colClasses = []; + + widths.forEach(function (colWidth, i) { + var columnProp = props[colWidth]; + + if (!i && columnProp === undefined) { + columnProp = true; + } + + delete attributes[colWidth]; + + if (!columnProp) { + return; + } + + var isXs = !i; + var colClass = void 0; + + if (__WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default()(columnProp)) { + var _classNames; + + var colSizeInterfix = isXs ? '-' : '-' + colWidth + '-'; + colClass = getColumnSizeClass(isXs, colWidth, columnProp.size); + + colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, colClass, columnProp.size || columnProp.size === ''), defineProperty(_classNames, 'push' + colSizeInterfix + columnProp.push, columnProp.push || columnProp.push === 0), defineProperty(_classNames, 'pull' + colSizeInterfix + columnProp.pull, columnProp.pull || columnProp.pull === 0), defineProperty(_classNames, 'offset' + colSizeInterfix + columnProp.offset, columnProp.offset || columnProp.offset === 0), _classNames))), cssModule); + } else { + colClass = getColumnSizeClass(isXs, colWidth, columnProp); + colClasses.push(colClass); + } + }); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, colClasses), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Col.propTypes = propTypes$2; +Col.defaultProps = defaultProps$2; + +var propTypes$3 = { + light: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + full: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + fixed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + sticky: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggleable: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; + +var defaultProps$3 = { + tag: 'nav', + toggleable: false +}; + +var getToggleableClass = function getToggleableClass(toggleable) { + if (toggleable === false) { + return false; + } else if (toggleable === true || toggleable === 'xs') { + return 'navbar-toggleable'; + } + + return 'navbar-toggleable-' + toggleable; +}; + +var Navbar = function Navbar(props) { + var _classNames; + + var toggleable = props.toggleable, + className = props.className, + cssModule = props.cssModule, + light = props.light, + inverse = props.inverse, + full = props.full, + fixed = props.fixed, + sticky = props.sticky, + color = props.color, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['toggleable', 'className', 'cssModule', 'light', 'inverse', 'full', 'fixed', 'sticky', 'color', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar', getToggleableClass(toggleable), (_classNames = { + 'navbar-light': light, + 'navbar-inverse': inverse + }, defineProperty(_classNames, 'bg-' + color, color), defineProperty(_classNames, 'navbar-full', full), defineProperty(_classNames, 'fixed-' + fixed, fixed), defineProperty(_classNames, 'sticky-' + sticky, sticky), _classNames)), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Navbar.propTypes = propTypes$3; +Navbar.defaultProps = defaultProps$3; + +var propTypes$4 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$4 = { + tag: 'a' +}; + +var NavbarBrand = function NavbarBrand(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-brand'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +NavbarBrand.propTypes = propTypes$4; +NavbarBrand.defaultProps = defaultProps$4; + +var propTypes$5 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; + +var defaultProps$5 = { + tag: 'button', + type: 'button' +}; + +var navbarToggleIcon = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('span', { className: 'navbar-toggler-icon' }); + +var NavbarToggler = function NavbarToggler(props) { + var className = props.className, + cssModule = props.cssModule, + children = props.children, + right = props.right, + left = props.left, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'right', 'left', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-toggler', right && 'navbar-toggler-right', left && 'navbar-toggler-left'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { className: classes }), + children || navbarToggleIcon + ); +}; + +NavbarToggler.propTypes = propTypes$5; +NavbarToggler.defaultProps = defaultProps$5; + +var propTypes$6 = { + tabs: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + pills: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$6 = { + tag: 'ul' +}; + +var Nav = function Nav(props) { + var className = props.className, + cssModule = props.cssModule, + tabs = props.tabs, + pills = props.pills, + vertical = props.vertical, + navbar = props.navbar, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabs', 'pills', 'vertical', 'navbar', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, navbar ? 'navbar-nav' : 'nav', { + 'nav-tabs': tabs, + 'nav-pills': pills, + 'flex-column': vertical + }), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Nav.propTypes = propTypes$6; +Nav.defaultProps = defaultProps$6; + +var propTypes$7 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$7 = { + tag: 'li' +}; + +var NavItem = function NavItem(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +NavItem.propTypes = propTypes$7; +NavItem.defaultProps = defaultProps$7; + +var propTypes$10 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + arrow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object.isRequired, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + style: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$10 = { + isOpen: false, + tetherRef: function tetherRef() {} +}; + +var TetherContent = function (_React$Component) { + inherits(TetherContent, _React$Component); + + function TetherContent(props) { + classCallCheck(this, TetherContent); + + var _this = possibleConstructorReturn(this, (TetherContent.__proto__ || Object.getPrototypeOf(TetherContent)).call(this, props)); + + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.toggle = _this.toggle.bind(_this); + return _this; + } + + createClass(TetherContent, [{ + key: 'componentDidMount', + value: function componentDidMount() { + this.handleProps(); + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + this.handleProps(); + } else if (this._element) { + // rerender + this.renderIntoSubtree(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.hide(); + } + }, { + key: 'getTarget', + value: function getTarget() { + var target = this.props.tether.target; + + if (__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default()(target)) { + return target(); + } + + return target; + } + }, { + key: 'getTetherConfig', + value: function getTetherConfig() { + var config = _extends({}, this.props.tether); + + config.element = this._element; + config.target = this.getTarget(); + return config; + } + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + var container = this._element; + if (e.target === container || !container.contains(e.target)) { + this.toggle(); + } + } + }, { + key: 'handleProps', + value: function handleProps() { + if (this.props.isOpen) { + this.show(); + } else { + this.hide(); + } + } + }, { + key: 'hide', + value: function hide() { + document.removeEventListener('click', this.handleDocumentClick, true); + + if (this._element) { + document.body.removeChild(this._element); + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); + this._element = null; + } + + if (this._tether) { + this._tether.destroy(); + this._tether = null; + this.props.tetherRef(this._tether); + } + } + }, { + key: 'show', + value: function show() { + document.addEventListener('click', this.handleDocumentClick, true); + + this._element = document.createElement('div'); + this._element.className = this.props.className; + document.body.appendChild(this._element); + this.renderIntoSubtree(); + this._tether = new __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default.a(this.getTetherConfig()); + this.props.tetherRef(this._tether); + this._tether.position(); + this._element.childNodes[0].focus(); + } + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } + + return this.props.toggle(); + } + }, { + key: 'renderIntoSubtree', + value: function renderIntoSubtree() { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _props = this.props, + children = _props.children, + style = _props.style; + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(children, { style: style }); + } + }, { + key: 'render', + value: function render() { + return null; + } + }]); + return TetherContent; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +TetherContent.propTypes = propTypes$10; +TetherContent.defaultProps = defaultProps$10; + +var propTypes$11 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$11 = { + tag: 'div' +}; + +var contextTypes = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired +}; + +var DropdownMenu = function DropdownMenu(props, context) { + var className = props.className, + cssModule = props.cssModule, + right = props.right, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'right', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'dropdown-menu', { 'dropdown-menu-right': right }), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { tabIndex: '-1', 'aria-hidden': !context.isOpen, role: 'menu', className: classes })); +}; + +DropdownMenu.propTypes = propTypes$11; +DropdownMenu.defaultProps = defaultProps$11; +DropdownMenu.contextTypes = contextTypes; + +/* eslint react/no-find-dom-node: 0 */ +// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-find-dom-node.md + +var propTypes$9 = { + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + dropup: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + group: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool]), + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$9 = { + isOpen: false, + tag: 'div' +}; + +var childContextTypes = { + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired +}; + +var defaultTetherConfig = { + classPrefix: 'bs-tether', + classes: { element: 'dropdown', enabled: 'show' }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] +}; + +var Dropdown = function (_React$Component) { + inherits(Dropdown, _React$Component); + + function Dropdown(props) { + classCallCheck(this, Dropdown); + + var _this = possibleConstructorReturn(this, (Dropdown.__proto__ || Object.getPrototypeOf(Dropdown)).call(this, props)); + + _this.addEvents = _this.addEvents.bind(_this); + _this.getTetherConfig = _this.getTetherConfig.bind(_this); + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.removeEvents = _this.removeEvents.bind(_this); + _this.toggle = _this.toggle.bind(_this); + return _this; + } + + createClass(Dropdown, [{ + key: 'getChildContext', + value: function getChildContext() { + return { + toggle: this.props.toggle, + isOpen: this.props.isOpen + }; + } + }, { + key: 'componentDidMount', + value: function componentDidMount() { + this.handleProps(); + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + this.handleProps(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.removeEvents(); + } + }, { + key: 'getTetherTarget', + value: function getTetherTarget() { + var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); + + return container.querySelector('[data-toggle="dropdown"]'); + } + }, { + key: 'getTetherConfig', + value: function getTetherConfig(childProps) { + var _this2 = this; + + var target = function target() { + return _this2.getTetherTarget(); + }; + var vElementAttach = 'top'; + var hElementAttach = 'left'; + var vTargetAttach = 'bottom'; + var hTargetAttach = 'left'; + + if (childProps.right) { + hElementAttach = 'right'; + hTargetAttach = 'right'; + } + + if (this.props.dropup) { + vElementAttach = 'bottom'; + vTargetAttach = 'top'; + } + + return _extends({}, defaultTetherConfig, { + attachment: vElementAttach + ' ' + hElementAttach, + targetAttachment: vTargetAttach + ' ' + hTargetAttach, + target: target + }, this.props.tether); + } + }, { + key: 'addEvents', + value: function addEvents() { + document.addEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'removeEvents', + value: function removeEvents() { + document.removeEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); + + if (container.contains(e.target) && container !== e.target) { + return; + } + + this.toggle(); + } + }, { + key: 'handleProps', + value: function handleProps() { + if (this.props.tether) { + return; + } + + if (this.props.isOpen) { + this.addEvents(); + } else { + this.removeEvents(); + } + } + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } + + return this.props.toggle(); + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _this3 = this; + + var _props = this.props, + tether = _props.tether, + children = _props.children, + attrs = objectWithoutProperties(_props, ['tether', 'children']); + + attrs.toggle = this.toggle; + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.map(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children), function (child) { + if (tether && child.type === DropdownMenu) { + var tetherConfig = _this3.getTetherConfig(child.props); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + _extends({}, attrs, { tether: tetherConfig }), + child + ); + } + + return child; + }); + } + }, { + key: 'render', + value: function render() { + var _classNames; + + var _omit = omit(this.props, ['toggle', 'tether']), + className = _omit.className, + cssModule = _omit.cssModule, + dropup = _omit.dropup, + group = _omit.group, + size = _omit.size, + Tag = _omit.tag, + isOpen = _omit.isOpen, + attributes = objectWithoutProperties(_omit, ['className', 'cssModule', 'dropup', 'group', 'size', 'tag', 'isOpen']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, (_classNames = { + 'btn-group': group + }, defineProperty(_classNames, 'btn-group-' + size, !!size), defineProperty(_classNames, 'dropdown', !group), defineProperty(_classNames, 'show', isOpen), defineProperty(_classNames, 'dropup', dropup), _classNames)), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { + className: classes + }), + this.renderChildren() + ); + } + }]); + return Dropdown; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Dropdown.propTypes = propTypes$9; +Dropdown.defaultProps = defaultProps$9; +Dropdown.childContextTypes = childContextTypes; + +var propTypes$8 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$8 = { + tag: 'li' +}; + +var NavDropdown = function NavDropdown(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({}, attributes, { tag: Tag, className: classes })); +}; + +NavDropdown.propTypes = propTypes$8; +NavDropdown.defaultProps = defaultProps$8; + +var propTypes$12 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + href: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; + +var defaultProps$12 = { + tag: 'a' +}; + +var NavLink = function (_React$Component) { + inherits(NavLink, _React$Component); + + function NavLink(props) { + classCallCheck(this, NavLink); + + var _this = possibleConstructorReturn(this, (NavLink.__proto__ || Object.getPrototypeOf(NavLink)).call(this, props)); + + _this.onClick = _this.onClick.bind(_this); + return _this; + } + + createClass(NavLink, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } + + if (this.props.href === '#') { + e.preventDefault(); + } + + if (this.props.onClick) { + this.props.onClick(e); + } + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + active = _props.active, + Tag = _props.tag, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'active', 'tag', 'getRef']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-link', { + disabled: attributes.disabled, + active: active + }), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, onClick: this.onClick, className: classes })); + } + }]); + return NavLink; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +NavLink.propTypes = propTypes$12; +NavLink.defaultProps = defaultProps$12; + +var propTypes$13 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$13 = { + tag: 'ol' +}; + +var Breadcrumb = function Breadcrumb(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'breadcrumb'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Breadcrumb.propTypes = propTypes$13; +Breadcrumb.defaultProps = defaultProps$13; + +var propTypes$14 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$14 = { + tag: 'li' +}; + +var BreadcrumbItem = function BreadcrumbItem(props) { + var className = props.className, + cssModule = props.cssModule, + active = props.active, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'active', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, 'breadcrumb-item'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +BreadcrumbItem.propTypes = propTypes$14; +BreadcrumbItem.defaultProps = defaultProps$14; + +var propTypes$15 = { + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$15 = { + color: 'secondary', + tag: 'button' +}; + +var Button = function (_React$Component) { + inherits(Button, _React$Component); + + function Button(props) { + classCallCheck(this, Button); + + var _this = possibleConstructorReturn(this, (Button.__proto__ || Object.getPrototypeOf(Button)).call(this, props)); + + _this.onClick = _this.onClick.bind(_this); + return _this; + } + + createClass(Button, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } + + if (this.props.onClick) { + this.props.onClick(e); + } + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + active = _props.active, + block = _props.block, + className = _props.className, + cssModule = _props.cssModule, + color = _props.color, + outline = _props.outline, + size = _props.size, + Tag = _props.tag, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['active', 'block', 'className', 'cssModule', 'color', 'outline', 'size', 'tag', 'getRef']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn', 'btn' + (outline ? '-outline' : '') + '-' + color, size ? 'btn-' + size : false, block ? 'btn-block' : false, { active: active, disabled: this.props.disabled }), cssModule); + + if (attributes.href && Tag === 'button') { + Tag = 'a'; + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ + type: Tag === 'button' && attributes.onClick ? 'button' : undefined + }, attributes, { + className: classes, + ref: getRef, + onClick: this.onClick + })); + } + }]); + return Button; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Button.propTypes = propTypes$15; +Button.defaultProps = defaultProps$15; + +var propTypes$16 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node +}; + +var ButtonDropdown = function ButtonDropdown(props) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({ group: true }, props)); +}; + +ButtonDropdown.propTypes = propTypes$16; + +var propTypes$17 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; + +var defaultProps$16 = { + tag: 'div', + role: 'group' +}; + +var ButtonGroup = function ButtonGroup(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + vertical = props.vertical, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'vertical', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, size ? 'btn-group-' + size : false, vertical ? 'btn-group-vertical' : 'btn-group'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ButtonGroup.propTypes = propTypes$17; +ButtonGroup.defaultProps = defaultProps$16; + +var propTypes$18 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string +}; + +var defaultProps$17 = { + tag: 'div', + role: 'toolbar' +}; + +var ButtonToolbar = function ButtonToolbar(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn-toolbar'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ButtonToolbar.propTypes = propTypes$18; +ButtonToolbar.defaultProps = defaultProps$17; + +var propTypes$19 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + divider: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + header: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; + +var contextTypes$1 = { + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; + +var defaultProps$18 = { + tag: 'button', + toggle: true +}; + +var DropdownItem = function (_React$Component) { + inherits(DropdownItem, _React$Component); + + function DropdownItem(props) { + classCallCheck(this, DropdownItem); + + var _this = possibleConstructorReturn(this, (DropdownItem.__proto__ || Object.getPrototypeOf(DropdownItem)).call(this, props)); + + _this.onClick = _this.onClick.bind(_this); + _this.getTabIndex = _this.getTabIndex.bind(_this); + return _this; + } + + createClass(DropdownItem, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled || this.props.header || this.props.divider) { + e.preventDefault(); + return; + } + + if (this.props.onClick) { + this.props.onClick(e); + } + + if (this.props.toggle) { + this.context.toggle(); + } + } + }, { + key: 'getTabIndex', + value: function getTabIndex() { + if (this.props.disabled || this.props.header || this.props.divider) { + return '-1'; + } + + return '0'; + } + }, { + key: 'render', + value: function render() { + var tabIndex = this.getTabIndex(); + + var _omit = omit(this.props, ['toggle']), + className = _omit.className, + cssModule = _omit.cssModule, + divider = _omit.divider, + Tag = _omit.tag, + header = _omit.header, + active = _omit.active, + props = objectWithoutProperties(_omit, ['className', 'cssModule', 'divider', 'tag', 'header', 'active']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + disabled: props.disabled, + 'dropdown-item': !divider && !header, + active: active, + 'dropdown-header': header, + 'dropdown-divider': divider + }), cssModule); + + if (Tag === 'button') { + if (header) { + Tag = 'h6'; + } else if (divider) { + Tag = 'div'; + } else if (props.href) { + Tag = 'a'; + } + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ + type: Tag === 'button' && (props.onClick || this.props.toggle) ? 'button' : undefined + }, props, { + tabIndex: tabIndex, + className: classes, + onClick: this.onClick + })); + } + }]); + return DropdownItem; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +DropdownItem.propTypes = propTypes$19; +DropdownItem.defaultProps = defaultProps$18; +DropdownItem.contextTypes = contextTypes$1; + +var propTypes$20 = { + caret: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + 'data-toggle': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + 'aria-haspopup': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + split: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + nav: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; + +var defaultProps$19 = { + 'data-toggle': 'dropdown', + 'aria-haspopup': true, + color: 'secondary' +}; + +var contextTypes$2 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired +}; + +var DropdownToggle = function (_React$Component) { + inherits(DropdownToggle, _React$Component); + + function DropdownToggle(props) { + classCallCheck(this, DropdownToggle); + + var _this = possibleConstructorReturn(this, (DropdownToggle.__proto__ || Object.getPrototypeOf(DropdownToggle)).call(this, props)); + + _this.onClick = _this.onClick.bind(_this); + return _this; + } + + createClass(DropdownToggle, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } + + if (this.props.nav && !this.props.tag) { + e.preventDefault(); + } + + if (this.props.onClick) { + this.props.onClick(e); + } + + this.context.toggle(); + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + color = _props.color, + cssModule = _props.cssModule, + caret = _props.caret, + split = _props.split, + nav = _props.nav, + tag = _props.tag, + props = objectWithoutProperties(_props, ['className', 'color', 'cssModule', 'caret', 'split', 'nav', 'tag']); + + var ariaLabel = props['aria-label'] || 'Toggle Dropdown'; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + 'dropdown-toggle': caret || split, + 'dropdown-toggle-split': split, + active: this.context.isOpen, + 'nav-link': nav + }), cssModule); + var children = props.children || __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { className: 'sr-only' }, + ariaLabel + ); + + var Tag = void 0; + + if (nav && !tag) { + Tag = 'a'; + props.href = '#'; + } else if (!tag) { + Tag = Button; + props.color = color; + } else { + Tag = tag; + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, props, { + className: classes, + onClick: this.onClick, + 'aria-haspopup': 'true', + 'aria-expanded': this.context.isOpen, + children: children + })); + } + }]); + return DropdownToggle; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +DropdownToggle.propTypes = propTypes$20; +DropdownToggle.defaultProps = defaultProps$19; +DropdownToggle.contextTypes = contextTypes$2; + +var propTypes$21 = { + baseClass: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + baseClassIn: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionAppear: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + transitionEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + transitionLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; + +var defaultProps$20 = { + tag: 'div', + baseClass: 'fade', + baseClassIn: 'show', + transitionAppearTimeout: 0, + transitionEnterTimeout: 0, + transitionLeaveTimeout: 0, + transitionAppear: true, + transitionEnter: true, + transitionLeave: true +}; + +var Fade = function (_React$Component) { + inherits(Fade, _React$Component); + + function Fade(props) { + classCallCheck(this, Fade); + + var _this = possibleConstructorReturn(this, (Fade.__proto__ || Object.getPrototypeOf(Fade)).call(this, props)); + + _this.state = { + mounted: !props.transitionAppear + }; + + _this.onLeave = _this.onLeave.bind(_this); + _this.onEnter = _this.onEnter.bind(_this); + _this.timers = []; + return _this; + } + + createClass(Fade, [{ + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.timers.forEach(function (timer) { + return clearTimeout(timer); + }); + } + }, { + key: 'onEnter', + value: function onEnter(cb) { + var _this2 = this; + + return function () { + cb(); + if (_this2.props.onEnter) { + _this2.props.onEnter(); + } + }; + } + }, { + key: 'onLeave', + value: function onLeave(cb) { + var _this3 = this; + + return function () { + cb(); + if (_this3.props.onLeave) { + _this3.props.onLeave(); + } + }; + } + }, { + key: 'componentWillAppear', + value: function componentWillAppear(cb) { + if (!this.props.transitionAppear) { + this.onEnter(cb)(); + } + + this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionAppearTimeout)); + } + }, { + key: 'componentDidAppear', + value: function componentDidAppear() { + this.setState({ + mounted: true + }); + } + }, { + key: 'componentWillEnter', + value: function componentWillEnter(cb) { + if (!this.props.transitionEnter) { + this.onEnter(cb)(); + } + + this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionEnterTimeout)); + } + }, { + key: 'componentDidEnter', + value: function componentDidEnter() { + this.setState({ + mounted: true + }); + } + }, { + key: 'componentWillLeave', + value: function componentWillLeave(cb) { + this.setState({ + mounted: false + }); + + if (!this.props.transitionLeave) { + this.onLeave(cb)(); + } + + this.timers.push(setTimeout(this.onLeave(cb), this.props.transitionLeaveTimeout)); + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + baseClass = _props.baseClass, + baseClassIn = _props.baseClassIn, + className = _props.className, + cssModule = _props.cssModule, + Tag = _props.tag; + + var attributes = omit(this.props, Object.keys(propTypes$21)); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, baseClass, this.state.mounted ? baseClassIn : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + } + }]); + return Fade; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Fade.propTypes = propTypes$21; +Fade.defaultProps = defaultProps$20; + +var propTypes$22 = { + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + pill: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$21 = { + color: 'default', + pill: false, + tag: 'span' +}; + +var Badge = function Badge(props) { + var className = props.className, + cssModule = props.cssModule, + color = props.color, + pill = props.pill, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'pill', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'badge', 'badge-' + color, pill ? 'badge-pill' : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Badge.propTypes = propTypes$22; +Badge.defaultProps = defaultProps$21; + +var propTypes$23 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$22 = { + tag: 'div' +}; + +var Card = function Card(props) { + var className = props.className, + cssModule = props.cssModule, + color = props.color, + block = props.block, + inverse = props.inverse, + outline = props.outline, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'block', 'inverse', 'outline', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card', inverse ? 'card-inverse' : false, block ? 'card-block' : false, color ? 'card' + (outline ? '-outline' : '') + '-' + color : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Card.propTypes = propTypes$23; +Card.defaultProps = defaultProps$22; + +var propTypes$24 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$23 = { + tag: 'div' +}; + +var CardGroup = function CardGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-group'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardGroup.propTypes = propTypes$24; +CardGroup.defaultProps = defaultProps$23; + +var propTypes$25 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$24 = { + tag: 'div' +}; + +var CardDeck = function CardDeck(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-deck'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardDeck.propTypes = propTypes$25; +CardDeck.defaultProps = defaultProps$24; + +var propTypes$26 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$25 = { + tag: 'div' +}; + +var CardColumns = function CardColumns(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-columns'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardColumns.propTypes = propTypes$26; +CardColumns.defaultProps = defaultProps$25; + +var propTypes$27 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$26 = { + tag: 'div' +}; + +var CardBlock = function CardBlock(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-block'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardBlock.propTypes = propTypes$27; +CardBlock.defaultProps = defaultProps$26; + +var propTypes$28 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$27 = { + tag: 'a' +}; + +var CardLink = function CardLink(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + getRef = props.getRef, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'getRef']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-link'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); +}; + +CardLink.propTypes = propTypes$28; +CardLink.defaultProps = defaultProps$27; + +var propTypes$29 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$28 = { + tag: 'div' +}; + +var CardFooter = function CardFooter(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-footer'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardFooter.propTypes = propTypes$29; +CardFooter.defaultProps = defaultProps$28; + +var propTypes$30 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$29 = { + tag: 'div' +}; + +var CardHeader = function CardHeader(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-header'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardHeader.propTypes = propTypes$30; +CardHeader.defaultProps = defaultProps$29; + +var propTypes$31 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$30 = { + tag: 'img' +}; + +var CardImg = function CardImg(props) { + var className = props.className, + cssModule = props.cssModule, + top = props.top, + bottom = props.bottom, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'top', 'bottom', 'tag']); + + + var cardImgClassName = 'card-img'; + if (top) { + cardImgClassName = 'card-img-top'; + } + if (bottom) { + cardImgClassName = 'card-img-bottom'; + } + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, cardImgClassName), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardImg.propTypes = propTypes$31; +CardImg.defaultProps = defaultProps$30; + +var propTypes$32 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$31 = { + tag: 'div' +}; + +var CardImgOverlay = function CardImgOverlay(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-img-overlay'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardImgOverlay.propTypes = propTypes$32; +CardImgOverlay.defaultProps = defaultProps$31; + +var propTypes$33 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$32 = { + tag: 'h6' +}; + +var CardSubtitle = function CardSubtitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-subtitle'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardSubtitle.propTypes = propTypes$33; +CardSubtitle.defaultProps = defaultProps$32; + +var propTypes$34 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$33 = { + tag: 'p' +}; + +var CardText = function CardText(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-text'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardText.propTypes = propTypes$34; +CardText.defaultProps = defaultProps$33; + +var propTypes$35 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$34 = { + tag: 'h4' +}; + +var CardTitle = function CardTitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-title'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +CardTitle.propTypes = propTypes$35; +CardTitle.defaultProps = defaultProps$34; + +var propTypes$36 = { + placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), + target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string.isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; + +var defaultProps$35 = { + isOpen: false, + placement: 'bottom', + toggle: function toggle() {} +}; + +var defaultTetherConfig$1 = { + classPrefix: 'bs-tether', + classes: { + element: false, + enabled: 'show' + }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] +}; + +var Popover = function (_React$Component) { + inherits(Popover, _React$Component); + + function Popover(props) { + classCallCheck(this, Popover); + + var _this = possibleConstructorReturn(this, (Popover.__proto__ || Object.getPrototypeOf(Popover)).call(this, props)); + + _this.getTetherConfig = _this.getTetherConfig.bind(_this); + return _this; + } + + createClass(Popover, [{ + key: 'getTetherConfig', + value: function getTetherConfig() { + var attachments = getTetherAttachments(this.props.placement); + return _extends({}, defaultTetherConfig$1, attachments, { + target: '#' + this.props.target + }, this.props.tether); + } + }, { + key: 'render', + value: function render() { + if (!this.props.isOpen) { + return null; + } + + var tetherConfig = this.getTetherConfig(); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('popover-inner', this.props.className), this.props.cssModule); + + var attributes = omit(this.props, Object.keys(propTypes$36)); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + { + className: mapToCssModules('popover', this.props.cssModule), + tether: tetherConfig, + tetherRef: this.props.tetherRef, + isOpen: this.props.isOpen, + toggle: this.props.toggle + }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { className: classes })) + ); + } + }]); + return Popover; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Popover.propTypes = propTypes$36; +Popover.defaultProps = defaultProps$35; + +var propTypes$37 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$36 = { + tag: 'h3' +}; + +var PopoverTitle = function PopoverTitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-title'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +PopoverTitle.propTypes = propTypes$37; +PopoverTitle.defaultProps = defaultProps$36; + +var propTypes$38 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$37 = { + tag: 'div' +}; + +var PopoverContent = function PopoverContent(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-content'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +PopoverContent.propTypes = propTypes$38; +PopoverContent.defaultProps = defaultProps$37; + +var propTypes$39 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + bar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + multi: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + value: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + max: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + animated: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + barClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$38 = { + tag: 'div', + value: 0, + max: 100 +}; + +var Progress = function Progress(props) { + var children = props.children, + className = props.className, + barClassName = props.barClassName, + cssModule = props.cssModule, + value = props.value, + max = props.max, + animated = props.animated, + striped = props.striped, + color = props.color, + bar = props.bar, + multi = props.multi, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['children', 'className', 'barClassName', 'cssModule', 'value', 'max', 'animated', 'striped', 'color', 'bar', 'multi', 'tag']); + + + var percent = __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(value) / __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(max) * 100; + + var progressClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'progress'), cssModule); + + var progressBarClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('progress-bar', bar ? className || barClassName : barClassName, animated ? 'progress-bar-animated' : null, color ? 'bg-' + color : null, striped || animated ? 'progress-bar-striped' : null), cssModule); + + var ProgressBar = multi ? children : __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { + className: progressBarClasses, + style: { width: percent + '%' }, + role: 'progressbar', + 'aria-valuenow': value, + 'aria-valuemin': '0', + 'aria-valuemax': max, + children: children + }); + + if (bar) { + return ProgressBar; + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: progressClasses, children: ProgressBar })); +}; + +Progress.propTypes = propTypes$39; +Progress.defaultProps = defaultProps$38; + +var propTypes$40 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + autoFocus: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + keyboard: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + backdrop: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(['static'])]), + onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onExit: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + wrapClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + modalClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + backdropClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + contentClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + fade: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + zIndex: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + backdropTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number +}; + +var propsToOmit = Object.keys(propTypes$40); + +var defaultProps$39 = { + isOpen: false, + autoFocus: true, + backdrop: true, + keyboard: true, + zIndex: 1050, + fade: true, + modalTransitionTimeout: 300, + backdropTransitionTimeout: 150 +}; + +var Modal = function (_React$Component) { + inherits(Modal, _React$Component); + + function Modal(props) { + classCallCheck(this, Modal); + + var _this = possibleConstructorReturn(this, (Modal.__proto__ || Object.getPrototypeOf(Modal)).call(this, props)); + + _this.originalBodyPadding = null; + _this.isBodyOverflowing = false; + _this.togglePortal = _this.togglePortal.bind(_this); + _this.handleBackdropClick = _this.handleBackdropClick.bind(_this); + _this.handleEscape = _this.handleEscape.bind(_this); + _this.destroy = _this.destroy.bind(_this); + _this.onEnter = _this.onEnter.bind(_this); + _this.onExit = _this.onExit.bind(_this); + return _this; + } + + createClass(Modal, [{ + key: 'componentDidMount', + value: function componentDidMount() { + if (this.props.isOpen) { + this.togglePortal(); + } + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + // handle portal events/dom updates + this.togglePortal(); + } else if (this._element) { + // rerender portal + this.renderIntoSubtree(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.onExit(); + } + }, { + key: 'onEnter', + value: function onEnter() { + if (this.props.onEnter) { + this.props.onEnter(); + } + } + }, { + key: 'onExit', + value: function onExit() { + this.destroy(); + if (this.props.onExit) { + this.props.onExit(); + } + } + }, { + key: 'handleEscape', + value: function handleEscape(e) { + if (this.props.keyboard && e.keyCode === 27 && this.props.toggle) { + this.props.toggle(); + } + } + }, { + key: 'handleBackdropClick', + value: function handleBackdropClick(e) { + if (this.props.backdrop !== true) return; + + var container = this._dialog; + + if (e.target && !container.contains(e.target) && this.props.toggle) { + this.props.toggle(); + } + } + }, { + key: 'hasTransition', + value: function hasTransition() { + if (this.props.fade === false) { + return false; + } + + return this.props.modalTransitionTimeout > 0; + } + }, { + key: 'togglePortal', + value: function togglePortal() { + if (this.props.isOpen) { + if (this.props.autoFocus) { + this._focus = true; + } + this.show(); + if (!this.hasTransition()) { + this.onEnter(); + } + } else { + this.hide(); + if (!this.hasTransition()) { + this.onExit(); + } + } + } + }, { + key: 'destroy', + value: function destroy() { + if (this._element) { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); + document.body.removeChild(this._element); + this._element = null; + } + + // Use regex to prevent matching `modal-open` as part of a different class, e.g. `my-modal-opened` + var classes = document.body.className.replace(/(^| )modal-open( |$)/, ' '); + document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes).trim(), this.props.cssModule); + setScrollbarWidth(this.originalBodyPadding); + } + }, { + key: 'hide', + value: function hide() { + this.renderIntoSubtree(); + } + }, { + key: 'show', + value: function show() { + var classes = document.body.className; + this._element = document.createElement('div'); + this._element.setAttribute('tabindex', '-1'); + this._element.style.position = 'relative'; + this._element.style.zIndex = this.props.zIndex; + this.originalBodyPadding = getOriginalBodyPadding(); + + conditionallyUpdateScrollbar(); + + document.body.appendChild(this._element); + + document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes, 'modal-open'), this.props.cssModule); + + this.renderIntoSubtree(); + } + }, { + key: 'renderModalDialog', + value: function renderModalDialog() { + var _this2 = this; + + var attributes = omit(this.props, propsToOmit); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + _extends({ + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-dialog', this.props.className, defineProperty({}, 'modal-' + this.props.size, this.props.size)), this.props.cssModule), + role: 'document', + ref: function ref(c) { + return _this2._dialog = c; + } + }, attributes), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + { + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-content', this.props.contentClassName), this.props.cssModule) + }, + this.props.children + ) + ); + } + }, { + key: 'renderIntoSubtree', + value: function renderIntoSubtree() { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); + + // check if modal should receive focus + if (this._focus) { + this._dialog.parentNode.focus(); + this._focus = false; + } + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _props = this.props, + wrapClassName = _props.wrapClassName, + modalClassName = _props.modalClassName, + backdropClassName = _props.backdropClassName, + cssModule = _props.cssModule, + isOpen = _props.isOpen, + backdrop = _props.backdrop, + modalTransitionTimeout = _props.modalTransitionTimeout, + backdropTransitionTimeout = _props.backdropTransitionTimeout; + + + var modalAttributes = { + onClickCapture: this.handleBackdropClick, + onKeyUp: this.handleEscape, + style: { display: 'block' }, + tabIndex: '-1' + }; + + if (this.hasTransition()) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["TransitionGroup"], + { component: 'div', className: mapToCssModules(wrapClassName) }, + isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Fade, + _extends({ + key: 'modal-dialog', + onEnter: this.onEnter, + onLeave: this.onExit, + transitionAppearTimeout: typeof this.props.modalTransitionAppearTimeout === 'number' ? this.props.modalTransitionAppearTimeout : modalTransitionTimeout, + transitionEnterTimeout: typeof this.props.modalTransitionEnterTimeout === 'number' ? this.props.modalTransitionEnterTimeout : modalTransitionTimeout, + transitionLeaveTimeout: typeof this.props.modalTransitionLeaveTimeout === 'number' ? this.props.modalTransitionLeaveTimeout : modalTransitionTimeout, + cssModule: cssModule, + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', modalClassName), cssModule) + }, modalAttributes), + this.renderModalDialog() + ), + isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Fade, { + key: 'modal-backdrop', + transitionAppearTimeout: typeof this.props.backdropTransitionAppearTimeout === 'number' ? this.props.backdropTransitionAppearTimeout : backdropTransitionTimeout, + transitionEnterTimeout: typeof this.props.backdropTransitionEnterTimeout === 'number' ? this.props.backdropTransitionEnterTimeout : backdropTransitionTimeout, + transitionLeaveTimeout: typeof this.props.backdropTransitionLeaveTimeout === 'number' ? this.props.backdropTransitionLeaveTimeout : backdropTransitionTimeout, + cssModule: cssModule, + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', backdropClassName), cssModule) + }) + ); + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + { className: mapToCssModules(wrapClassName) }, + isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + _extends({ + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', 'show', modalClassName), cssModule) + }, modalAttributes), + this.renderModalDialog() + ), + isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', 'show', backdropClassName), cssModule) + }) + ); + } + }, { + key: 'render', + value: function render() { + return null; + } + }]); + return Modal; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Modal.propTypes = propTypes$40; +Modal.defaultProps = defaultProps$39; + +var propTypes$41 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + wrapTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node +}; + +var defaultProps$40 = { + tag: 'h4', + wrapTag: 'div' +}; + +var ModalHeader = function ModalHeader(props) { + var closeButton = void 0; + var className = props.className, + cssModule = props.cssModule, + children = props.children, + toggle = props.toggle, + Tag = props.tag, + WrapTag = props.wrapTag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'toggle', 'tag', 'wrapTag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-header'), cssModule); + + if (toggle) { + closeButton = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'button', + { type: 'button', onClick: toggle, className: 'close', 'aria-label': 'Close' }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { 'aria-hidden': 'true' }, + String.fromCharCode(215) + ) + ); + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + WrapTag, + _extends({}, attributes, { className: classes }), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + { className: mapToCssModules('modal-title', cssModule) }, + children + ), + closeButton + ); +}; + +ModalHeader.propTypes = propTypes$41; +ModalHeader.defaultProps = defaultProps$40; + +var propTypes$42 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$41 = { + tag: 'div' +}; + +var ModalBody = function ModalBody(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-body'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ModalBody.propTypes = propTypes$42; +ModalBody.defaultProps = defaultProps$41; + +var propTypes$43 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$42 = { + tag: 'div' +}; + +var ModalFooter = function ModalFooter(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-footer'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ModalFooter.propTypes = propTypes$43; +ModalFooter.defaultProps = defaultProps$42; + +var propTypes$44 = { + placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), + target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + autohide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]) +}; + +var DEFAULT_DELAYS = { + show: 0, + hide: 250 +}; + +var defaultProps$43 = { + isOpen: false, + placement: 'bottom', + delay: DEFAULT_DELAYS, + autohide: true, + toggle: function toggle() {} +}; + +var defaultTetherConfig$2 = { + classPrefix: 'bs-tether', + classes: { + element: false, + enabled: 'show' + }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] +}; + +var Tooltip = function (_React$Component) { + inherits(Tooltip, _React$Component); + + function Tooltip(props) { + classCallCheck(this, Tooltip); + + var _this = possibleConstructorReturn(this, (Tooltip.__proto__ || Object.getPrototypeOf(Tooltip)).call(this, props)); + + _this.addTargetEvents = _this.addTargetEvents.bind(_this); + _this.getTarget = _this.getTarget.bind(_this); + _this.getTetherConfig = _this.getTetherConfig.bind(_this); + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.removeTargetEvents = _this.removeTargetEvents.bind(_this); + _this.toggle = _this.toggle.bind(_this); + _this.onMouseOverTooltip = _this.onMouseOverTooltip.bind(_this); + _this.onMouseLeaveTooltip = _this.onMouseLeaveTooltip.bind(_this); + _this.onMouseOverTooltipContent = _this.onMouseOverTooltipContent.bind(_this); + _this.onMouseLeaveTooltipContent = _this.onMouseLeaveTooltipContent.bind(_this); + _this.show = _this.show.bind(_this); + _this.hide = _this.hide.bind(_this); + return _this; + } + + createClass(Tooltip, [{ + key: 'componentDidMount', + value: function componentDidMount() { + this._target = this.getTarget(); + this.addTargetEvents(); + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.removeTargetEvents(); + } + }, { + key: 'onMouseOverTooltip', + value: function onMouseOverTooltip() { + if (this._hideTimeout) { + this.clearHideTimeout(); + } + this._showTimeout = setTimeout(this.show, this.getDelay('show')); + } + }, { + key: 'onMouseLeaveTooltip', + value: function onMouseLeaveTooltip() { + if (this._showTimeout) { + this.clearShowTimeout(); + } + this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); + } + }, { + key: 'onMouseOverTooltipContent', + value: function onMouseOverTooltipContent() { + if (this.props.autohide) { + return; + } + if (this._hideTimeout) { + this.clearHideTimeout(); + } + } + }, { + key: 'onMouseLeaveTooltipContent', + value: function onMouseLeaveTooltipContent() { + if (this.props.autohide) { + return; + } + if (this._showTimeout) { + this.clearShowTimeout(); + } + this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); + } + }, { + key: 'getDelay', + value: function getDelay(key) { + var delay = this.props.delay; + + if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { + return isNaN(delay[key]) ? DEFAULT_DELAYS[key] : delay[key]; + } + return delay; + } + }, { + key: 'getTarget', + value: function getTarget() { + var target = this.props.target; + + if ((typeof target === 'undefined' ? 'undefined' : _typeof(target)) === 'object') { + return target; + } + return document.getElementById(target); + } + }, { + key: 'getTetherConfig', + value: function getTetherConfig() { + var attachments = getTetherAttachments(this.props.placement); + return _extends({}, defaultTetherConfig$2, attachments, { + target: this.getTarget + }, this.props.tether); + } + }, { + key: 'show', + value: function show() { + if (!this.props.isOpen) { + this.clearShowTimeout(); + this.toggle(); + } + } + }, { + key: 'hide', + value: function hide() { + if (this.props.isOpen) { + this.clearHideTimeout(); + this.toggle(); + } + } + }, { + key: 'clearShowTimeout', + value: function clearShowTimeout() { + clearTimeout(this._showTimeout); + this._showTimeout = undefined; + } + }, { + key: 'clearHideTimeout', + value: function clearHideTimeout() { + clearTimeout(this._hideTimeout); + this._hideTimeout = undefined; + } + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + if (e.target === this._target || this._target.contains(e.target)) { + if (this._hideTimeout) { + this.clearHideTimeout(); + } + + if (!this.props.isOpen) { + this.toggle(); + } + } + } + }, { + key: 'addTargetEvents', + value: function addTargetEvents() { + this._target.addEventListener('mouseover', this.onMouseOverTooltip, true); + this._target.addEventListener('mouseout', this.onMouseLeaveTooltip, true); + document.addEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'removeTargetEvents', + value: function removeTargetEvents() { + this._target.removeEventListener('mouseover', this.onMouseOverTooltip, true); + this._target.removeEventListener('mouseout', this.onMouseLeaveTooltip, true); + document.removeEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } + + return this.props.toggle(); + } + }, { + key: 'render', + value: function render() { + if (!this.props.isOpen) { + return null; + } + + var attributes = omit(this.props, Object.keys(propTypes$44)); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tooltip-inner', this.props.className), this.props.cssModule); + + var tetherConfig = this.getTetherConfig(); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + { + className: 'tooltip', + tether: tetherConfig, + tetherRef: this.props.tetherRef, + isOpen: this.props.isOpen, + toggle: this.toggle + }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { + className: classes, + onMouseOver: this.onMouseOverTooltipContent, + onMouseLeave: this.onMouseLeaveTooltipContent + })) + ); + } + }]); + return Tooltip; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Tooltip.propTypes = propTypes$44; +Tooltip.defaultProps = defaultProps$43; + +var propTypes$45 = { + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + bordered: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + hover: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + reflow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + responsive: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + responsiveTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; + +var defaultProps$44 = { + tag: 'table', + responsiveTag: 'div' +}; + +var Table = function Table(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + bordered = props.bordered, + striped = props.striped, + inverse = props.inverse, + hover = props.hover, + reflow = props.reflow, + responsive = props.responsive, + Tag = props.tag, + ResponsiveTag = props.responsiveTag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'bordered', 'striped', 'inverse', 'hover', 'reflow', 'responsive', 'tag', 'responsiveTag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'table', size ? 'table-' + size : false, bordered ? 'table-bordered' : false, striped ? 'table-striped' : false, inverse ? 'table-inverse' : false, hover ? 'table-hover' : false, reflow ? 'table-reflow' : false), cssModule); + + var table = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + + if (responsive) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + ResponsiveTag, + { className: 'table-responsive' }, + table + ); + } + + return table; +}; + +Table.propTypes = propTypes$45; +Table.defaultProps = defaultProps$44; + +var propTypes$46 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + flush: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$45 = { + tag: 'ul' +}; + +var ListGroup = function ListGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + flush = props.flush, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'flush']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group', flush ? 'list-group-flush' : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ListGroup.propTypes = propTypes$46; +ListGroup.defaultProps = defaultProps$45; + +var propTypes$47 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$46 = { + tag: 'form' +}; + +var Form = function Form(props) { + var className = props.className, + cssModule = props.cssModule, + inline = props.inline, + Tag = props.tag, + getRef = props.getRef, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'tag', 'getRef']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, inline ? 'form-inline' : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); +}; + +Form.propTypes = propTypes$47; +Form.defaultProps = defaultProps$46; + +var propTypes$48 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$47 = { + tag: 'div' +}; + +var FormFeedback = function FormFeedback(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'form-control-feedback'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +FormFeedback.propTypes = propTypes$48; +FormFeedback.defaultProps = defaultProps$47; + +var propTypes$49 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + row: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$48 = { + tag: 'div' +}; + +var FormGroup = function FormGroup(props) { + var className = props.className, + cssModule = props.cssModule, + row = props.row, + disabled = props.disabled, + color = props.color, + check = props.check, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'row', 'disabled', 'color', 'check', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, color ? 'has-' + color : false, row ? 'row' : false, check ? 'form-check' : 'form-group', check && disabled ? 'disabled' : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +FormGroup.propTypes = propTypes$49; +FormGroup.defaultProps = defaultProps$48; + +var propTypes$50 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$49 = { + tag: 'small' +}; + +var FormText = function FormText(props) { + var className = props.className, + cssModule = props.cssModule, + inline = props.inline, + color = props.color, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'color', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, !inline ? 'form-text' : false, color ? 'text-' + color : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +FormText.propTypes = propTypes$50; +FormText.defaultProps = defaultProps$49; + +/* eslint react/prefer-stateless-function: 0 */ + +var propTypes$51 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + state: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + static: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + addon: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$50 = { + tag: 'p', + type: 'text' +}; + +var Input = function (_React$Component) { + inherits(Input, _React$Component); + + function Input() { + classCallCheck(this, Input); + return possibleConstructorReturn(this, (Input.__proto__ || Object.getPrototypeOf(Input)).apply(this, arguments)); + } + + createClass(Input, [{ + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + type = _props.type, + size = _props.size, + state = _props.state, + tag = _props.tag, + addon = _props.addon, + staticInput = _props.static, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'type', 'size', 'state', 'tag', 'addon', 'static', 'getRef']); + + + var checkInput = ['radio', 'checkbox'].indexOf(type) > -1; + + var fileInput = type === 'file'; + var textareaInput = type === 'textarea'; + var selectInput = type === 'select'; + var Tag = selectInput || textareaInput ? type : 'input'; + + var formControlClass = 'form-control'; + + if (staticInput) { + formControlClass = formControlClass + '-static'; + Tag = tag; + } else if (fileInput) { + formControlClass = formControlClass + '-file'; + } else if (checkInput) { + if (addon) { + formControlClass = null; + } else { + formControlClass = 'form-check-input'; + } + } + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, state ? 'form-control-' + state : false, size ? 'form-control-' + size : false, formControlClass), cssModule); + + if (Tag === 'input') { + attributes.type = type; + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); + } + }]); + return Input; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + +Input.propTypes = propTypes$51; +Input.defaultProps = defaultProps$50; + +var propTypes$52 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$51 = { + tag: 'div' +}; + +var InputGroup = function InputGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + size = props.size, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'size']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group', size ? 'input-group-' + size : null), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +InputGroup.propTypes = propTypes$52; +InputGroup.defaultProps = defaultProps$51; + +var propTypes$53 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$52 = { + tag: 'div' +}; + +var InputGroupAddon = function InputGroupAddon(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-addon'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +InputGroupAddon.propTypes = propTypes$53; +InputGroupAddon.defaultProps = defaultProps$52; + +var propTypes$54 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + groupClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + groupAttributes: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$53 = { + tag: 'div' +}; + +var InputGroupButton = function InputGroupButton(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + children = props.children, + groupClassName = props.groupClassName, + groupAttributes = props.groupAttributes, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'children', 'groupClassName', 'groupAttributes']); + + + if (typeof children === 'string') { + var groupClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(groupClassName, 'input-group-btn'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, groupAttributes, { className: groupClasses }), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Button, _extends({}, attributes, { className: className, children: children })) + ); + } + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-btn'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes, children: children })); +}; + +InputGroupButton.propTypes = propTypes$54; +InputGroupButton.defaultProps = defaultProps$53; + +var colSizes = ['xs', 'sm', 'md', 'lg', 'xl']; + +var stringOrNumberProp$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); + +var columnProps$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + size: stringOrNumberProp$1, + push: stringOrNumberProp$1, + pull: stringOrNumberProp$1, + offset: stringOrNumberProp$1 +})]); + +var propTypes$55 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + hidden: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + for: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + xs: columnProps$1, + sm: columnProps$1, + md: columnProps$1, + lg: columnProps$1, + xl: columnProps$1 +}; + +var defaultProps$54 = { + tag: 'label' +}; + +var Label = function Label(props) { + var className = props.className, + cssModule = props.cssModule, + hidden = props.hidden, + Tag = props.tag, + check = props.check, + inline = props.inline, + disabled = props.disabled, + size = props.size, + htmlFor = props.for, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'hidden', 'tag', 'check', 'inline', 'disabled', 'size', 'for']); + + + var colClasses = []; + + colSizes.forEach(function (colSize) { + var columnProp = props[colSize]; + delete attributes[colSize]; + + if (columnProp && columnProp.size) { + var _classNames; + + colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, 'col-' + colSize + '-' + columnProp.size, columnProp.size), defineProperty(_classNames, 'push-' + colSize + '-' + columnProp.push, columnProp.push), defineProperty(_classNames, 'pull-' + colSize + '-' + columnProp.pull, columnProp.pull), defineProperty(_classNames, 'offset-' + colSize + '-' + columnProp.offset, columnProp.offset), _classNames))), cssModule); + } else if (columnProp) { + colClasses.push('col-' + colSize + '-' + columnProp); + } + }); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, hidden ? 'sr-only' : false, check ? 'form-check-' + (inline ? 'inline' : 'label') : false, check && inline && disabled ? 'disabled' : false, size ? 'col-form-label-' + size : false, colClasses, colClasses.length ? 'col-form-label' : false, !check && !colClasses.length ? 'form-control-label' : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ htmlFor: htmlFor }, attributes, { className: classes })); +}; + +Label.propTypes = propTypes$55; +Label.defaultProps = defaultProps$54; + +var propTypes$56 = { + body: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + heading: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + list: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + middle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + object: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; + +var Media = function Media(props) { + var body = props.body, + bottom = props.bottom, + className = props.className, + cssModule = props.cssModule, + heading = props.heading, + left = props.left, + list = props.list, + middle = props.middle, + object = props.object, + right = props.right, + tag = props.tag, + top = props.top, + attributes = objectWithoutProperties(props, ['body', 'bottom', 'className', 'cssModule', 'heading', 'left', 'list', 'middle', 'object', 'right', 'tag', 'top']); + + + var defaultTag = void 0; + if (heading) { + defaultTag = 'h4'; + } else if (left || right) { + defaultTag = 'a'; + } else if (object) { + defaultTag = 'img'; + } else if (list) { + defaultTag = 'ul'; + } else { + defaultTag = 'div'; + } + var Tag = tag || defaultTag; + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + 'media-body': body, + 'media-heading': heading, + 'media-left': left, + 'media-right': right, + 'media-top': top, + 'media-bottom': bottom, + 'media-middle': middle, + 'media-object': object, + 'media-list': list, + media: !body && !heading && !left && !right && !top && !bottom && !middle && !object && !list + }), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Media.propTypes = propTypes$56; + +var propTypes$57 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; + +var defaultProps$55 = { + tag: 'ul' +}; + +var Pagination = function Pagination(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'pagination', defineProperty({}, 'pagination-' + size, !!size)), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Pagination.propTypes = propTypes$57; +Pagination.defaultProps = defaultProps$55; + +var propTypes$58 = { + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; + +var defaultProps$56 = { + tag: 'li' +}; + +var PaginationItem = function PaginationItem(props) { + var active = props.active, + className = props.className, + cssModule = props.cssModule, + disabled = props.disabled, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['active', 'className', 'cssModule', 'disabled', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-item', { + active: active, + disabled: disabled + }), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +PaginationItem.propTypes = propTypes$58; +PaginationItem.defaultProps = defaultProps$56; + +var propTypes$59 = { + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + next: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + previous: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; + +var defaultProps$57 = { + tag: 'a' +}; + +var PaginationLink = function PaginationLink(props) { + var className = props.className, + cssModule = props.cssModule, + next = props.next, + previous = props.previous, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'next', 'previous', 'tag']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-link'), cssModule); + + var defaultAriaLabel = void 0; + if (previous) { + defaultAriaLabel = 'Previous'; + } else if (next) { + defaultAriaLabel = 'Next'; + } + var ariaLabel = props['aria-label'] || defaultAriaLabel; + + var defaultCaret = void 0; + if (previous) { + defaultCaret = '\xAB'; + } else if (next) { + defaultCaret = '\xBB'; + } + + var children = props.children; + if (previous || next) { + children = [__WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { + 'aria-hidden': 'true', + key: 'caret' + }, + children || defaultCaret + ), __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { + className: 'sr-only', + key: 'sr' + }, + ariaLabel + )]; + } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { + className: classes, + 'aria-label': ariaLabel + }), + children + ); +}; + +PaginationLink.propTypes = propTypes$59; +PaginationLink.defaultProps = defaultProps$57; + +var propTypes$60 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + activeTab: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$58 = { + tag: 'div' +}; + +var childContextTypes$1 = { + activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; + +var TabContent = function (_Component) { + inherits(TabContent, _Component); + + function TabContent(props) { + classCallCheck(this, TabContent); + + var _this = possibleConstructorReturn(this, (TabContent.__proto__ || Object.getPrototypeOf(TabContent)).call(this, props)); + + _this.state = { + activeTab: _this.props.activeTab + }; + return _this; + } + + createClass(TabContent, [{ + key: 'getChildContext', + value: function getChildContext() { + return { + activeTabId: this.state.activeTab + }; + } + }, { + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + if (this.state.activeTab !== nextProps.activeTab) { + this.setState({ + activeTab: nextProps.activeTab + }); + } + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + Tag = _props.tag; + + + var attributes = omit(this.props, Object.keys(propTypes$60)); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-content', className), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + } + }]); + return TabContent; +}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); + +TabContent.propTypes = propTypes$60; +TabContent.defaultProps = defaultProps$58; +TabContent.childContextTypes = childContextTypes$1; + +var propTypes$61 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; + +var defaultProps$59 = { + tag: 'div' +}; + +var contextTypes$3 = { + activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; + +function TabPane(props, context) { + var className = props.className, + cssModule = props.cssModule, + tabId = props.tabId, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabId', 'tag']); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-pane', className, { active: tabId === context.activeTabId }), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +} +TabPane.propTypes = propTypes$61; +TabPane.defaultProps = defaultProps$59; +TabPane.contextTypes = contextTypes$3; + +var propTypes$62 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; + +var defaultProps$60 = { + tag: 'div' +}; + +var Jumbotron = function Jumbotron(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + fluid = props.fluid, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'fluid']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'jumbotron', fluid ? 'jumbotron-fluid' : false), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +Jumbotron.propTypes = propTypes$62; +Jumbotron.defaultProps = defaultProps$60; + +var FirstChild = function FirstChild(_ref) { + var children = _ref.children; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children)[0] || null; +}; + +var propTypes$63 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + closeClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number +}; + +var defaultProps$61 = { + color: 'success', + isOpen: true, + tag: 'div', + transitionAppearTimeout: 150, + transitionEnterTimeout: 150, + transitionLeaveTimeout: 150 +}; + +var Alert = function Alert(props) { + var className = props.className, + closeClassName = props.closeClassName, + cssModule = props.cssModule, + Tag = props.tag, + color = props.color, + isOpen = props.isOpen, + toggle = props.toggle, + children = props.children, + transitionAppearTimeout = props.transitionAppearTimeout, + transitionEnterTimeout = props.transitionEnterTimeout, + transitionLeaveTimeout = props.transitionLeaveTimeout, + attributes = objectWithoutProperties(props, ['className', 'closeClassName', 'cssModule', 'tag', 'color', 'isOpen', 'toggle', 'children', 'transitionAppearTimeout', 'transitionEnterTimeout', 'transitionLeaveTimeout']); + + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'alert', 'alert-' + color, { 'alert-dismissible': toggle }), cssModule); + + var closeClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('close', closeClassName), cssModule); + + var alert = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { className: classes, role: 'alert' }), + toggle ? __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'button', + { type: 'button', className: closeClasses, 'aria-label': 'Close', onClick: toggle }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { 'aria-hidden': 'true' }, + '\xD7' + ) + ) : null, + children + ); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["CSSTransitionGroup"], + { + component: FirstChild, + transitionName: { + appear: 'fade', + appearActive: 'show', + enter: 'fade', + enterActive: 'show', + leave: 'fade', + leaveActive: 'out' + }, + transitionAppear: transitionAppearTimeout > 0, + transitionAppearTimeout: transitionAppearTimeout, + transitionEnter: transitionEnterTimeout > 0, + transitionEnterTimeout: transitionEnterTimeout, + transitionLeave: transitionLeaveTimeout > 0, + transitionLeaveTimeout: transitionLeaveTimeout + }, + isOpen ? alert : null + ); +}; + +Alert.propTypes = propTypes$63; +Alert.defaultProps = defaultProps$61; + +var SHOW = 'SHOW'; +var SHOWN = 'SHOWN'; +var HIDE = 'HIDE'; +var HIDDEN = 'HIDDEN'; + +var propTypes$64 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + onOpened: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onClosed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; + +var DEFAULT_DELAYS$1 = { + show: 350, + hide: 350 +}; + +var defaultProps$62 = { + isOpen: false, + tag: 'div', + delay: DEFAULT_DELAYS$1, + onOpened: function onOpened() {}, + onClosed: function onClosed() {} +}; + +var Collapse = function (_Component) { + inherits(Collapse, _Component); + + function Collapse(props) { + classCallCheck(this, Collapse); + + var _this = possibleConstructorReturn(this, (Collapse.__proto__ || Object.getPrototypeOf(Collapse)).call(this, props)); + + _this.state = { + collapse: props.isOpen ? SHOWN : HIDDEN, + height: null + }; + _this.element = null; + return _this; + } + + createClass(Collapse, [{ + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + var _this2 = this; + + var willOpen = nextProps.isOpen; + var collapse = this.state.collapse; + + if (willOpen && collapse === HIDDEN) { + // will open + this.setState({ collapse: SHOW }, function () { + // the height transition will work after class "collapsing" applied + _this2.setState({ height: _this2.getHeight() }); + _this2.transitionTag = setTimeout(function () { + _this2.setState({ + collapse: SHOWN, + height: null + }); + }, _this2.getDelay('show')); + }); + } else if (!willOpen && collapse === SHOWN) { + // will hide + this.setState({ height: this.getHeight() }, function () { + _this2.setState({ + collapse: HIDE, + height: _this2.getHeight() + }, function () { + _this2.setState({ height: 0 }); + }); + }); + + this.transitionTag = setTimeout(function () { + _this2.setState({ + collapse: HIDDEN, + height: null + }); + }, this.getDelay('hide')); + } + // else: do nothing. + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps, prevState) { + if (this.state.collapse === SHOWN && prevState && prevState.collapse !== SHOWN) { + this.props.onOpened(); + } + + if (this.state.collapse === HIDDEN && prevState && prevState.collapse !== HIDDEN) { + this.props.onClosed(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + clearTimeout(this.transitionTag); + } + }, { + key: 'getDelay', + value: function getDelay(key) { + var delay = this.props.delay; + + if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { + return isNaN(delay[key]) ? DEFAULT_DELAYS$1[key] : delay[key]; + } + return delay; + } + }, { + key: 'getHeight', + value: function getHeight() { + return this.element.scrollHeight; + } + }, { + key: 'render', + value: function render() { + var _this3 = this; + + var _omit = omit(this.props, ['isOpen', 'delay', 'onOpened', 'onClosed']), + navbar = _omit.navbar, + className = _omit.className, + cssModule = _omit.cssModule, + Tag = _omit.tag, + attributes = objectWithoutProperties(_omit, ['navbar', 'className', 'cssModule', 'tag']); + + var _state = this.state, + collapse = _state.collapse, + height = _state.height; + + var collapseClass = void 0; + switch (collapse) { + case SHOW: + collapseClass = 'collapsing'; + break; + case SHOWN: + collapseClass = 'collapse show'; + break; + case HIDE: + collapseClass = 'collapsing'; + break; + case HIDDEN: + collapseClass = 'collapse'; + break; + default: + // HIDDEN + collapseClass = 'collapse'; + } + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, collapseClass, navbar && 'navbar-collapse'), cssModule); + var style = height === null ? null : { height: height }; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { + style: _extends({}, attributes.style, style), + className: classes, + ref: function ref(c) { + _this3.element = c; + } + })); + } + }]); + return Collapse; +}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); + +Collapse.propTypes = propTypes$64; +Collapse.defaultProps = defaultProps$62; + +var propTypes$65 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + action: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; + +var defaultProps$63 = { + tag: 'li' +}; + +var handleDisabledOnClick = function handleDisabledOnClick(e) { + e.preventDefault(); +}; + +var ListGroupItem = function ListGroupItem(props) { + var className = props.className, + Tag = props.tag, + active = props.active, + disabled = props.disabled, + action = props.action, + color = props.color, + attributes = objectWithoutProperties(props, ['className', 'tag', 'active', 'disabled', 'action', 'color']); + + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, disabled ? 'disabled' : false, action ? 'list-group-item-action' : false, color ? 'list-group-item-' + color : false, 'list-group-item'); + + // Prevent click event when disabled. + if (disabled) { + attributes.onClick = handleDisabledOnClick; + } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ListGroupItem.propTypes = propTypes$65; +ListGroupItem.defaultProps = defaultProps$63; + +var propTypes$66 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; + +var defaultProps$64 = { + tag: 'h5' +}; + +var ListGroupItemHeading = function ListGroupItemHeading(props) { + var className = props.className, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'tag']); + + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-heading'); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ListGroupItemHeading.propTypes = propTypes$66; +ListGroupItemHeading.defaultProps = defaultProps$64; + +var propTypes$67 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; + +var defaultProps$65 = { + tag: 'p' +}; + +var ListGroupItemText = function ListGroupItemText(props) { + var className = props.className, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'tag']); + + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-text'); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; + +ListGroupItemText.propTypes = propTypes$67; +ListGroupItemText.defaultProps = defaultProps$65; + +var Component$1 = __WEBPACK_IMPORTED_MODULE_0_react___default.a.Component; + +var components = { + UncontrolledAlert: Alert, + UncontrolledButtonDropdown: ButtonDropdown, + UncontrolledDropdown: Dropdown, + UncontrolledNavDropdown: NavDropdown, + UncontrolledTooltip: Tooltip +}; + +Object.keys(components).forEach(function (key) { + var Tag = components[key]; + var defaultValue = Tag === Alert; + + var Uncontrolled = function (_Component) { + inherits(Uncontrolled, _Component); + + function Uncontrolled(props) { + classCallCheck(this, Uncontrolled); + + var _this = possibleConstructorReturn(this, (Uncontrolled.__proto__ || Object.getPrototypeOf(Uncontrolled)).call(this, props)); + + _this.state = { isOpen: defaultValue }; + + _this.toggle = _this.toggle.bind(_this); + return _this; + } + + createClass(Uncontrolled, [{ + key: 'toggle', + value: function toggle() { + this.setState({ isOpen: !this.state.isOpen }); + } + }, { + key: 'render', + value: function render() { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ isOpen: this.state.isOpen, toggle: this.toggle }, this.props)); + } + }]); + return Uncontrolled; + }(Component$1); + + Uncontrolled.displayName = key; + + components[key] = Uncontrolled; +}); + +var UncontrolledAlert = components.UncontrolledAlert; +var UncontrolledButtonDropdown = components.UncontrolledButtonDropdown; +var UncontrolledDropdown = components.UncontrolledDropdown; +var UncontrolledNavDropdown = components.UncontrolledNavDropdown; +var UncontrolledTooltip = components.UncontrolledTooltip; + + +//# sourceMappingURL=reactstrap.es.js.map + + +/***/ }), +/* 94 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +var utils = __webpack_require__(20); +var normalizeHeaderName = __webpack_require__(339); + +var DEFAULT_CONTENT_TYPE = { + 'Content-Type': 'application/x-www-form-urlencoded' +}; + +function setContentTypeIfUnset(headers, value) { + if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) { + headers['Content-Type'] = value; + } +} + +function getDefaultAdapter() { + var adapter; + if (typeof XMLHttpRequest !== 'undefined') { + // For browsers use XHR adapter + adapter = __webpack_require__(156); + } else if (typeof process !== 'undefined') { + // For node use HTTP adapter + adapter = __webpack_require__(156); + } + return adapter; +} + +var defaults = { + adapter: getDefaultAdapter(), + + transformRequest: [function transformRequest(data, headers) { + normalizeHeaderName(headers, 'Content-Type'); + if (utils.isFormData(data) || + utils.isArrayBuffer(data) || + utils.isBuffer(data) || + utils.isStream(data) || + utils.isFile(data) || + utils.isBlob(data) + ) { + return data; + } + if (utils.isArrayBufferView(data)) { + return data.buffer; + } + if (utils.isURLSearchParams(data)) { + setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8'); + return data.toString(); + } + if (utils.isObject(data)) { + setContentTypeIfUnset(headers, 'application/json;charset=utf-8'); + return JSON.stringify(data); + } + return data; + }], + + transformResponse: [function transformResponse(data) { + /*eslint no-param-reassign:0*/ + if (typeof data === 'string') { + try { + data = JSON.parse(data); + } catch (e) { /* Ignore */ } + } + return data; + }], + + timeout: 0, + + xsrfCookieName: 'XSRF-TOKEN', + xsrfHeaderName: 'X-XSRF-TOKEN', + + maxContentLength: -1, + + validateStatus: function validateStatus(status) { + return status >= 200 && status < 300; + } +}; + +defaults.headers = { + common: { + 'Accept': 'application/json, text/plain, */*' + } +}; + +utils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) { + defaults.headers[method] = {}; +}); + +utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE); +}); + +module.exports = defaults; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 95 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _classnames = __webpack_require__(41); + +var _classnames2 = _interopRequireDefault(_classnames); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } + +// +exports.default = { + get: get, + set: set, + takeRight: takeRight, + last: last, + orderBy: orderBy, + range: range, + remove: remove, + clone: clone, + getFirstDefined: getFirstDefined, + sum: sum, + makeTemplateComponent: makeTemplateComponent, + groupBy: groupBy, + isArray: isArray, + splitProps: splitProps, + compactObject: compactObject, + isSortingDesc: isSortingDesc, + normalizeComponent: normalizeComponent, + asPx: asPx +}; + + +function get(obj, path, def) { + if (!path) { + return obj; + } + var pathObj = makePathArray(path); + var val = void 0; + try { + val = pathObj.reduce(function (current, pathPart) { + return current[pathPart]; + }, obj); + } catch (e) {} + return typeof val !== 'undefined' ? val : def; +} + +function set() { + var obj = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + var path = arguments[1]; + var value = arguments[2]; + + var keys = makePathArray(path); + var keyPart = void 0; + var cursor = obj; + while ((keyPart = keys.shift()) && keys.length) { + if (!cursor[keyPart]) { + cursor[keyPart] = {}; + } + cursor = cursor[keyPart]; + } + cursor[keyPart] = value; + return obj; +} + +function takeRight(arr, n) { + var start = n > arr.length ? 0 : arr.length - n; + return arr.slice(start); +} + +function last(arr) { + return arr[arr.length - 1]; +} + +function range(n) { + var arr = []; + for (var i = 0; i < n; i++) { + arr.push(n); + } + return arr; +} + +function orderBy(arr, funcs, dirs, indexKey) { + return arr.sort(function (rowA, rowB) { + for (var i = 0; i < funcs.length; i++) { + var comp = funcs[i]; + var desc = dirs[i] === false || dirs[i] === 'desc'; + var sortInt = comp(rowA, rowB); + if (sortInt) { + return desc ? -sortInt : sortInt; + } + } + // Use the row index for tie breakers + return dirs[0] ? rowA[indexKey] - rowB[indexKey] : rowB[indexKey] - rowA[indexKey]; + }); +} + +function remove(a, b) { + return a.filter(function (o, i) { + var r = b(o); + if (r) { + a.splice(i, 1); + return true; + } + return false; + }); +} + +function clone(a) { + try { + return JSON.parse(JSON.stringify(a, function (key, value) { + if (typeof value === 'function') { + return value.toString(); + } + return value; + })); + } catch (e) { + return a; + } +} + +function getFirstDefined() { + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + for (var i = 0; i < args.length; i++) { + if (typeof args[i] !== 'undefined') { + return args[i]; + } + } +} + +function sum(arr) { + return arr.reduce(function (a, b) { + return a + b; + }, 0); +} + +function makeTemplateComponent(compClass, displayName) { + if (!displayName) { + throw new Error('No displayName found for template component:', compClass); + } + var cmp = function cmp(_ref) { + var children = _ref.children, + className = _ref.className, + rest = _objectWithoutProperties(_ref, ['children', 'className']); + + return _react2.default.createElement( + 'div', + _extends({ className: (0, _classnames2.default)(compClass, className) }, rest), + children + ); + }; + cmp.displayName = displayName; + return cmp; +} + +function groupBy(xs, key) { + return xs.reduce(function (rv, x, i) { + var resKey = typeof key === 'function' ? key(x, i) : x[key]; + rv[resKey] = isArray(rv[resKey]) ? rv[resKey] : []; + rv[resKey].push(x); + return rv; + }, {}); +} + +function asPx(value) { + value = Number(value); + return Number.isNaN(value) ? null : value + 'px'; +} + +function isArray(a) { + return Array.isArray(a); +} + +// ######################################################################## +// Non-exported Helpers +// ######################################################################## + +function makePathArray(obj) { + return flattenDeep(obj).join('.').replace(/\[/g, '.').replace(/\]/g, '').split('.'); +} + +function flattenDeep(arr) { + var newArr = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : []; + + if (!isArray(arr)) { + newArr.push(arr); + } else { + for (var i = 0; i < arr.length; i++) { + flattenDeep(arr[i], newArr); + } + } + return newArr; +} + +function splitProps(_ref2) { + var className = _ref2.className, + style = _ref2.style, + rest = _objectWithoutProperties(_ref2, ['className', 'style']); + + return { + className: className, + style: style, + rest: rest || {} + }; +} + +function compactObject(obj) { + var newObj = {}; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key] !== undefined && typeof obj[key] !== 'undefined') { + newObj[key] = obj[key]; + } + } + return newObj; +} + +function isSortingDesc(d) { + return !!(d.sort === 'desc' || d.desc === true || d.asc === false); +} + +function normalizeComponent(Comp) { + var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; + var fallback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Comp; + + return typeof Comp === 'function' ? Object.getPrototypeOf(Comp).isReactComponent ? _react2.default.createElement(Comp, params) : Comp(params) : fallback; +} +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy91dGlscy5qcyJdLCJuYW1lcyI6WyJnZXQiLCJzZXQiLCJ0YWtlUmlnaHQiLCJsYXN0Iiwib3JkZXJCeSIsInJhbmdlIiwicmVtb3ZlIiwiY2xvbmUiLCJnZXRGaXJzdERlZmluZWQiLCJzdW0iLCJtYWtlVGVtcGxhdGVDb21wb25lbnQiLCJncm91cEJ5IiwiaXNBcnJheSIsInNwbGl0UHJvcHMiLCJjb21wYWN0T2JqZWN0IiwiaXNTb3J0aW5nRGVzYyIsIm5vcm1hbGl6ZUNvbXBvbmVudCIsImFzUHgiLCJvYmoiLCJwYXRoIiwiZGVmIiwicGF0aE9iaiIsIm1ha2VQYXRoQXJyYXkiLCJ2YWwiLCJyZWR1Y2UiLCJjdXJyZW50IiwicGF0aFBhcnQiLCJlIiwidmFsdWUiLCJrZXlzIiwia2V5UGFydCIsImN1cnNvciIsInNoaWZ0IiwibGVuZ3RoIiwiYXJyIiwibiIsInN0YXJ0Iiwic2xpY2UiLCJpIiwicHVzaCIsImZ1bmNzIiwiZGlycyIsImluZGV4S2V5Iiwic29ydCIsInJvd0EiLCJyb3dCIiwiY29tcCIsImRlc2MiLCJzb3J0SW50IiwiYSIsImIiLCJmaWx0ZXIiLCJvIiwiciIsInNwbGljZSIsIkpTT04iLCJwYXJzZSIsInN0cmluZ2lmeSIsImtleSIsInRvU3RyaW5nIiwiYXJncyIsImNvbXBDbGFzcyIsImRpc3BsYXlOYW1lIiwiRXJyb3IiLCJjbXAiLCJjaGlsZHJlbiIsImNsYXNzTmFtZSIsInJlc3QiLCJ4cyIsInJ2IiwieCIsInJlc0tleSIsIk51bWJlciIsImlzTmFOIiwiQXJyYXkiLCJmbGF0dGVuRGVlcCIsImpvaW4iLCJyZXBsYWNlIiwic3BsaXQiLCJuZXdBcnIiLCJzdHlsZSIsIm5ld09iaiIsImhhc093blByb3BlcnR5IiwidW5kZWZpbmVkIiwiZCIsImFzYyIsIkNvbXAiLCJwYXJhbXMiLCJmYWxsYmFjayIsIk9iamVjdCIsImdldFByb3RvdHlwZU9mIiwiaXNSZWFjdENvbXBvbmVudCJdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7Ozs7OztBQUNBO2tCQUNlO0FBQ2JBLFVBRGE7QUFFYkMsVUFGYTtBQUdiQyxzQkFIYTtBQUliQyxZQUphO0FBS2JDLGtCQUxhO0FBTWJDLGNBTmE7QUFPYkMsZ0JBUGE7QUFRYkMsY0FSYTtBQVNiQyxrQ0FUYTtBQVViQyxVQVZhO0FBV2JDLDhDQVhhO0FBWWJDLGtCQVphO0FBYWJDLGtCQWJhO0FBY2JDLHdCQWRhO0FBZWJDLDhCQWZhO0FBZ0JiQyw4QkFoQmE7QUFpQmJDLHdDQWpCYTtBQWtCYkM7QUFsQmEsQzs7O0FBcUJmLFNBQVNqQixHQUFULENBQWNrQixHQUFkLEVBQW1CQyxJQUFuQixFQUF5QkMsR0FBekIsRUFBOEI7QUFDNUIsTUFBSSxDQUFDRCxJQUFMLEVBQVc7QUFDVCxXQUFPRCxHQUFQO0FBQ0Q7QUFDRCxNQUFNRyxVQUFVQyxjQUFjSCxJQUFkLENBQWhCO0FBQ0EsTUFBSUksWUFBSjtBQUNBLE1BQUk7QUFDRkEsVUFBTUYsUUFBUUcsTUFBUixDQUFlLFVBQUNDLE9BQUQsRUFBVUMsUUFBVjtBQUFBLGFBQXVCRCxRQUFRQyxRQUFSLENBQXZCO0FBQUEsS0FBZixFQUF5RFIsR0FBekQsQ0FBTjtBQUNELEdBRkQsQ0FFRSxPQUFPUyxDQUFQLEVBQVUsQ0FBRTtBQUNkLFNBQU8sT0FBT0osR0FBUCxLQUFlLFdBQWYsR0FBNkJBLEdBQTdCLEdBQW1DSCxHQUExQztBQUNEOztBQUVELFNBQVNuQixHQUFULEdBQXFDO0FBQUEsTUFBdkJpQixHQUF1Qix1RUFBakIsRUFBaUI7QUFBQSxNQUFiQyxJQUFhO0FBQUEsTUFBUFMsS0FBTzs7QUFDbkMsTUFBTUMsT0FBT1AsY0FBY0gsSUFBZCxDQUFiO0FBQ0EsTUFBSVcsZ0JBQUo7QUFDQSxNQUFJQyxTQUFTYixHQUFiO0FBQ0EsU0FBTyxDQUFDWSxVQUFVRCxLQUFLRyxLQUFMLEVBQVgsS0FBNEJILEtBQUtJLE1BQXhDLEVBQWdEO0FBQzlDLFFBQUksQ0FBQ0YsT0FBT0QsT0FBUCxDQUFMLEVBQXNCO0FBQ3BCQyxhQUFPRCxPQUFQLElBQWtCLEVBQWxCO0FBQ0Q7QUFDREMsYUFBU0EsT0FBT0QsT0FBUCxDQUFUO0FBQ0Q7QUFDREMsU0FBT0QsT0FBUCxJQUFrQkYsS0FBbEI7QUFDQSxTQUFPVixHQUFQO0FBQ0Q7O0FBRUQsU0FBU2hCLFNBQVQsQ0FBb0JnQyxHQUFwQixFQUF5QkMsQ0FBekIsRUFBNEI7QUFDMUIsTUFBTUMsUUFBUUQsSUFBSUQsSUFBSUQsTUFBUixHQUFpQixDQUFqQixHQUFxQkMsSUFBSUQsTUFBSixHQUFhRSxDQUFoRDtBQUNBLFNBQU9ELElBQUlHLEtBQUosQ0FBVUQsS0FBVixDQUFQO0FBQ0Q7O0FBRUQsU0FBU2pDLElBQVQsQ0FBZStCLEdBQWYsRUFBb0I7QUFDbEIsU0FBT0EsSUFBSUEsSUFBSUQsTUFBSixHQUFhLENBQWpCLENBQVA7QUFDRDs7QUFFRCxTQUFTNUIsS0FBVCxDQUFnQjhCLENBQWhCLEVBQW1CO0FBQ2pCLE1BQU1ELE1BQU0sRUFBWjtBQUNBLE9BQUssSUFBSUksSUFBSSxDQUFiLEVBQWdCQSxJQUFJSCxDQUFwQixFQUF1QkcsR0FBdkIsRUFBNEI7QUFDMUJKLFFBQUlLLElBQUosQ0FBU0osQ0FBVDtBQUNEO0FBQ0QsU0FBT0QsR0FBUDtBQUNEOztBQUVELFNBQVM5QixPQUFULENBQWtCOEIsR0FBbEIsRUFBdUJNLEtBQXZCLEVBQThCQyxJQUE5QixFQUFvQ0MsUUFBcEMsRUFBOEM7QUFDNUMsU0FBT1IsSUFBSVMsSUFBSixDQUFTLFVBQUNDLElBQUQsRUFBT0MsSUFBUCxFQUFnQjtBQUM5QixTQUFLLElBQUlQLElBQUksQ0FBYixFQUFnQkEsSUFBSUUsTUFBTVAsTUFBMUIsRUFBa0NLLEdBQWxDLEVBQXVDO0FBQ3JDLFVBQU1RLE9BQU9OLE1BQU1GLENBQU4sQ0FBYjtBQUNBLFVBQU1TLE9BQU9OLEtBQUtILENBQUwsTUFBWSxLQUFaLElBQXFCRyxLQUFLSCxDQUFMLE1BQVksTUFBOUM7QUFDQSxVQUFNVSxVQUFVRixLQUFLRixJQUFMLEVBQVdDLElBQVgsQ0FBaEI7QUFDQSxVQUFJRyxPQUFKLEVBQWE7QUFDWCxlQUFPRCxPQUFPLENBQUNDLE9BQVIsR0FBa0JBLE9BQXpCO0FBQ0Q7QUFDRjtBQUNEO0FBQ0EsV0FBT1AsS0FBSyxDQUFMLElBQ0hHLEtBQUtGLFFBQUwsSUFBaUJHLEtBQUtILFFBQUwsQ0FEZCxHQUVIRyxLQUFLSCxRQUFMLElBQWlCRSxLQUFLRixRQUFMLENBRnJCO0FBR0QsR0FiTSxDQUFQO0FBY0Q7O0FBRUQsU0FBU3BDLE1BQVQsQ0FBaUIyQyxDQUFqQixFQUFvQkMsQ0FBcEIsRUFBdUI7QUFDckIsU0FBT0QsRUFBRUUsTUFBRixDQUFTLFVBQVVDLENBQVYsRUFBYWQsQ0FBYixFQUFnQjtBQUM5QixRQUFJZSxJQUFJSCxFQUFFRSxDQUFGLENBQVI7QUFDQSxRQUFJQyxDQUFKLEVBQU87QUFDTEosUUFBRUssTUFBRixDQUFTaEIsQ0FBVCxFQUFZLENBQVo7QUFDQSxhQUFPLElBQVA7QUFDRDtBQUNELFdBQU8sS0FBUDtBQUNELEdBUE0sQ0FBUDtBQVFEOztBQUVELFNBQVMvQixLQUFULENBQWdCMEMsQ0FBaEIsRUFBbUI7QUFDakIsTUFBSTtBQUNGLFdBQU9NLEtBQUtDLEtBQUwsQ0FDTEQsS0FBS0UsU0FBTCxDQUFlUixDQUFmLEVBQWtCLFVBQUNTLEdBQUQsRUFBTTlCLEtBQU4sRUFBZ0I7QUFDaEMsVUFBSSxPQUFPQSxLQUFQLEtBQWlCLFVBQXJCLEVBQWlDO0FBQy9CLGVBQU9BLE1BQU0rQixRQUFOLEVBQVA7QUFDRDtBQUNELGFBQU8vQixLQUFQO0FBQ0QsS0FMRCxDQURLLENBQVA7QUFRRCxHQVRELENBU0UsT0FBT0QsQ0FBUCxFQUFVO0FBQ1YsV0FBT3NCLENBQVA7QUFDRDtBQUNGOztBQUVELFNBQVN6QyxlQUFULEdBQW1DO0FBQUEsb0NBQU5vRCxJQUFNO0FBQU5BLFFBQU07QUFBQTs7QUFDakMsT0FBSyxJQUFJdEIsSUFBSSxDQUFiLEVBQWdCQSxJQUFJc0IsS0FBSzNCLE1BQXpCLEVBQWlDSyxHQUFqQyxFQUFzQztBQUNwQyxRQUFJLE9BQU9zQixLQUFLdEIsQ0FBTCxDQUFQLEtBQW1CLFdBQXZCLEVBQW9DO0FBQ2xDLGFBQU9zQixLQUFLdEIsQ0FBTCxDQUFQO0FBQ0Q7QUFDRjtBQUNGOztBQUVELFNBQVM3QixHQUFULENBQWN5QixHQUFkLEVBQW1CO0FBQ2pCLFNBQU9BLElBQUlWLE1BQUosQ0FBVyxVQUFDeUIsQ0FBRCxFQUFJQyxDQUFKLEVBQVU7QUFDMUIsV0FBT0QsSUFBSUMsQ0FBWDtBQUNELEdBRk0sRUFFSixDQUZJLENBQVA7QUFHRDs7QUFFRCxTQUFTeEMscUJBQVQsQ0FBZ0NtRCxTQUFoQyxFQUEyQ0MsV0FBM0MsRUFBd0Q7QUFDdEQsTUFBSSxDQUFDQSxXQUFMLEVBQWtCO0FBQ2hCLFVBQU0sSUFBSUMsS0FBSixDQUFVLDhDQUFWLEVBQTBERixTQUExRCxDQUFOO0FBQ0Q7QUFDRCxNQUFNRyxNQUFNLFNBQU5BLEdBQU07QUFBQSxRQUFHQyxRQUFILFFBQUdBLFFBQUg7QUFBQSxRQUFhQyxTQUFiLFFBQWFBLFNBQWI7QUFBQSxRQUEyQkMsSUFBM0I7O0FBQUEsV0FDVjtBQUFBO0FBQUEsaUJBQUssV0FBVywwQkFBV04sU0FBWCxFQUFzQkssU0FBdEIsQ0FBaEIsSUFBc0RDLElBQXREO0FBQ0dGO0FBREgsS0FEVTtBQUFBLEdBQVo7QUFJQUQsTUFBSUYsV0FBSixHQUFrQkEsV0FBbEI7QUFDQSxTQUFPRSxHQUFQO0FBQ0Q7O0FBRUQsU0FBU3JELE9BQVQsQ0FBa0J5RCxFQUFsQixFQUFzQlYsR0FBdEIsRUFBMkI7QUFDekIsU0FBT1UsR0FBRzVDLE1BQUgsQ0FBVSxVQUFDNkMsRUFBRCxFQUFLQyxDQUFMLEVBQVFoQyxDQUFSLEVBQWM7QUFDN0IsUUFBTWlDLFNBQVMsT0FBT2IsR0FBUCxLQUFlLFVBQWYsR0FBNEJBLElBQUlZLENBQUosRUFBT2hDLENBQVAsQ0FBNUIsR0FBd0NnQyxFQUFFWixHQUFGLENBQXZEO0FBQ0FXLE9BQUdFLE1BQUgsSUFBYTNELFFBQVF5RCxHQUFHRSxNQUFILENBQVIsSUFBc0JGLEdBQUdFLE1BQUgsQ0FBdEIsR0FBbUMsRUFBaEQ7QUFDQUYsT0FBR0UsTUFBSCxFQUFXaEMsSUFBWCxDQUFnQitCLENBQWhCO0FBQ0EsV0FBT0QsRUFBUDtBQUNELEdBTE0sRUFLSixFQUxJLENBQVA7QUFNRDs7QUFFRCxTQUFTcEQsSUFBVCxDQUFlVyxLQUFmLEVBQXNCO0FBQ3BCQSxVQUFRNEMsT0FBTzVDLEtBQVAsQ0FBUjtBQUNBLFNBQU80QyxPQUFPQyxLQUFQLENBQWE3QyxLQUFiLElBQXNCLElBQXRCLEdBQTZCQSxRQUFRLElBQTVDO0FBQ0Q7O0FBRUQsU0FBU2hCLE9BQVQsQ0FBa0JxQyxDQUFsQixFQUFxQjtBQUNuQixTQUFPeUIsTUFBTTlELE9BQU4sQ0FBY3FDLENBQWQsQ0FBUDtBQUNEOztBQUVEO0FBQ0E7QUFDQTs7QUFFQSxTQUFTM0IsYUFBVCxDQUF3QkosR0FBeEIsRUFBNkI7QUFDM0IsU0FBT3lELFlBQVl6RCxHQUFaLEVBQ0owRCxJQURJLENBQ0MsR0FERCxFQUVKQyxPQUZJLENBRUksS0FGSixFQUVXLEdBRlgsRUFHSkEsT0FISSxDQUdJLEtBSEosRUFHVyxFQUhYLEVBSUpDLEtBSkksQ0FJRSxHQUpGLENBQVA7QUFLRDs7QUFFRCxTQUFTSCxXQUFULENBQXNCekMsR0FBdEIsRUFBd0M7QUFBQSxNQUFiNkMsTUFBYSx1RUFBSixFQUFJOztBQUN0QyxNQUFJLENBQUNuRSxRQUFRc0IsR0FBUixDQUFMLEVBQW1CO0FBQ2pCNkMsV0FBT3hDLElBQVAsQ0FBWUwsR0FBWjtBQUNELEdBRkQsTUFFTztBQUNMLFNBQUssSUFBSUksSUFBSSxDQUFiLEVBQWdCQSxJQUFJSixJQUFJRCxNQUF4QixFQUFnQ0ssR0FBaEMsRUFBcUM7QUFDbkNxQyxrQkFBWXpDLElBQUlJLENBQUosQ0FBWixFQUFvQnlDLE1BQXBCO0FBQ0Q7QUFDRjtBQUNELFNBQU9BLE1BQVA7QUFDRDs7QUFFRCxTQUFTbEUsVUFBVCxRQUFvRDtBQUFBLE1BQTdCcUQsU0FBNkIsU0FBN0JBLFNBQTZCO0FBQUEsTUFBbEJjLEtBQWtCLFNBQWxCQSxLQUFrQjtBQUFBLE1BQVJiLElBQVE7O0FBQ2xELFNBQU87QUFDTEQsd0JBREs7QUFFTGMsZ0JBRks7QUFHTGIsVUFBTUEsUUFBUTtBQUhULEdBQVA7QUFLRDs7QUFFRCxTQUFTckQsYUFBVCxDQUF3QkksR0FBeEIsRUFBNkI7QUFDM0IsTUFBTStELFNBQVMsRUFBZjtBQUNBLE9BQUssSUFBSXZCLEdBQVQsSUFBZ0J4QyxHQUFoQixFQUFxQjtBQUNuQixRQUNFQSxJQUFJZ0UsY0FBSixDQUFtQnhCLEdBQW5CLEtBQ0F4QyxJQUFJd0MsR0FBSixNQUFheUIsU0FEYixJQUVBLE9BQU9qRSxJQUFJd0MsR0FBSixDQUFQLEtBQW9CLFdBSHRCLEVBSUU7QUFDQXVCLGFBQU92QixHQUFQLElBQWN4QyxJQUFJd0MsR0FBSixDQUFkO0FBQ0Q7QUFDRjtBQUNELFNBQU91QixNQUFQO0FBQ0Q7O0FBRUQsU0FBU2xFLGFBQVQsQ0FBd0JxRSxDQUF4QixFQUEyQjtBQUN6QixTQUFPLENBQUMsRUFBRUEsRUFBRXpDLElBQUYsS0FBVyxNQUFYLElBQXFCeUMsRUFBRXJDLElBQUYsS0FBVyxJQUFoQyxJQUF3Q3FDLEVBQUVDLEdBQUYsS0FBVSxLQUFwRCxDQUFSO0FBQ0Q7O0FBRUQsU0FBU3JFLGtCQUFULENBQTZCc0UsSUFBN0IsRUFBaUU7QUFBQSxNQUE5QkMsTUFBOEIsdUVBQXJCLEVBQXFCO0FBQUEsTUFBakJDLFFBQWlCLHVFQUFORixJQUFNOztBQUMvRCxTQUFPLE9BQU9BLElBQVAsS0FBZ0IsVUFBaEIsR0FDSEcsT0FBT0MsY0FBUCxDQUFzQkosSUFBdEIsRUFBNEJLLGdCQUE1QixHQUNFLDhCQUFDLElBQUQsRUFBVUosTUFBVixDQURGLEdBRUVELEtBQUtDLE1BQUwsQ0FIQyxHQUlIQyxRQUpKO0FBS0QiLCJmaWxlIjoidXRpbHMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgUmVhY3QgZnJvbSAncmVhY3QnXG5pbXBvcnQgY2xhc3NuYW1lcyBmcm9tICdjbGFzc25hbWVzJ1xuLy9cbmV4cG9ydCBkZWZhdWx0IHtcbiAgZ2V0LFxuICBzZXQsXG4gIHRha2VSaWdodCxcbiAgbGFzdCxcbiAgb3JkZXJCeSxcbiAgcmFuZ2UsXG4gIHJlbW92ZSxcbiAgY2xvbmUsXG4gIGdldEZpcnN0RGVmaW5lZCxcbiAgc3VtLFxuICBtYWtlVGVtcGxhdGVDb21wb25lbnQsXG4gIGdyb3VwQnksXG4gIGlzQXJyYXksXG4gIHNwbGl0UHJvcHMsXG4gIGNvbXBhY3RPYmplY3QsXG4gIGlzU29ydGluZ0Rlc2MsXG4gIG5vcm1hbGl6ZUNvbXBvbmVudCxcbiAgYXNQeCxcbn1cblxuZnVuY3Rpb24gZ2V0IChvYmosIHBhdGgsIGRlZikge1xuICBpZiAoIXBhdGgpIHtcbiAgICByZXR1cm4gb2JqXG4gIH1cbiAgY29uc3QgcGF0aE9iaiA9IG1ha2VQYXRoQXJyYXkocGF0aClcbiAgbGV0IHZhbFxuICB0cnkge1xuICAgIHZhbCA9IHBhdGhPYmoucmVkdWNlKChjdXJyZW50LCBwYXRoUGFydCkgPT4gY3VycmVudFtwYXRoUGFydF0sIG9iailcbiAgfSBjYXRjaCAoZSkge31cbiAgcmV0dXJuIHR5cGVvZiB2YWwgIT09ICd1bmRlZmluZWQnID8gdmFsIDogZGVmXG59XG5cbmZ1bmN0aW9uIHNldCAob2JqID0ge30sIHBhdGgsIHZhbHVlKSB7XG4gIGNvbnN0IGtleXMgPSBtYWtlUGF0aEFycmF5KHBhdGgpXG4gIGxldCBrZXlQYXJ0XG4gIGxldCBjdXJzb3IgPSBvYmpcbiAgd2hpbGUgKChrZXlQYXJ0ID0ga2V5cy5zaGlmdCgpKSAmJiBrZXlzLmxlbmd0aCkge1xuICAgIGlmICghY3Vyc29yW2tleVBhcnRdKSB7XG4gICAgICBjdXJzb3Jba2V5UGFydF0gPSB7fVxuICAgIH1cbiAgICBjdXJzb3IgPSBjdXJzb3Jba2V5UGFydF1cbiAgfVxuICBjdXJzb3Jba2V5UGFydF0gPSB2YWx1ZVxuICByZXR1cm4gb2JqXG59XG5cbmZ1bmN0aW9uIHRha2VSaWdodCAoYXJyLCBuKSB7XG4gIGNvbnN0IHN0YXJ0ID0gbiA+IGFyci5sZW5ndGggPyAwIDogYXJyLmxlbmd0aCAtIG5cbiAgcmV0dXJuIGFyci5zbGljZShzdGFydClcbn1cblxuZnVuY3Rpb24gbGFzdCAoYXJyKSB7XG4gIHJldHVybiBhcnJbYXJyLmxlbmd0aCAtIDFdXG59XG5cbmZ1bmN0aW9uIHJhbmdlIChuKSB7XG4gIGNvbnN0IGFyciA9IFtdXG4gIGZvciAobGV0IGkgPSAwOyBpIDwgbjsgaSsrKSB7XG4gICAgYXJyLnB1c2gobilcbiAgfVxuICByZXR1cm4gYXJyXG59XG5cbmZ1bmN0aW9uIG9yZGVyQnkgKGFyciwgZnVuY3MsIGRpcnMsIGluZGV4S2V5KSB7XG4gIHJldHVybiBhcnIuc29ydCgocm93QSwgcm93QikgPT4ge1xuICAgIGZvciAobGV0IGkgPSAwOyBpIDwgZnVuY3MubGVuZ3RoOyBpKyspIHtcbiAgICAgIGNvbnN0IGNvbXAgPSBmdW5jc1tpXVxuICAgICAgY29uc3QgZGVzYyA9IGRpcnNbaV0gPT09IGZhbHNlIHx8IGRpcnNbaV0gPT09ICdkZXNjJ1xuICAgICAgY29uc3Qgc29ydEludCA9IGNvbXAocm93QSwgcm93QilcbiAgICAgIGlmIChzb3J0SW50KSB7XG4gICAgICAgIHJldHVybiBkZXNjID8gLXNvcnRJbnQgOiBzb3J0SW50XG4gICAgICB9XG4gICAgfVxuICAgIC8vIFVzZSB0aGUgcm93IGluZGV4IGZvciB0aWUgYnJlYWtlcnNcbiAgICByZXR1cm4gZGlyc1swXVxuICAgICAgPyByb3dBW2luZGV4S2V5XSAtIHJvd0JbaW5kZXhLZXldXG4gICAgICA6IHJvd0JbaW5kZXhLZXldIC0gcm93QVtpbmRleEtleV1cbiAgfSlcbn1cblxuZnVuY3Rpb24gcmVtb3ZlIChhLCBiKSB7XG4gIHJldHVybiBhLmZpbHRlcihmdW5jdGlvbiAobywgaSkge1xuICAgIHZhciByID0gYihvKVxuICAgIGlmIChyKSB7XG4gICAgICBhLnNwbGljZShpLCAxKVxuICAgICAgcmV0dXJuIHRydWVcbiAgICB9XG4gICAgcmV0dXJuIGZhbHNlXG4gIH0pXG59XG5cbmZ1bmN0aW9uIGNsb25lIChhKSB7XG4gIHRyeSB7XG4gICAgcmV0dXJuIEpTT04ucGFyc2UoXG4gICAgICBKU09OLnN0cmluZ2lmeShhLCAoa2V5LCB2YWx1ZSkgPT4ge1xuICAgICAgICBpZiAodHlwZW9mIHZhbHVlID09PSAnZnVuY3Rpb24nKSB7XG4gICAgICAgICAgcmV0dXJuIHZhbHVlLnRvU3RyaW5nKClcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gdmFsdWVcbiAgICAgIH0pXG4gICAgKVxuICB9IGNhdGNoIChlKSB7XG4gICAgcmV0dXJuIGFcbiAgfVxufVxuXG5mdW5jdGlvbiBnZXRGaXJzdERlZmluZWQgKC4uLmFyZ3MpIHtcbiAgZm9yICh2YXIgaSA9IDA7IGkgPCBhcmdzLmxlbmd0aDsgaSsrKSB7XG4gICAgaWYgKHR5cGVvZiBhcmdzW2ldICE9PSAndW5kZWZpbmVkJykge1xuICAgICAgcmV0dXJuIGFyZ3NbaV1cbiAgICB9XG4gIH1cbn1cblxuZnVuY3Rpb24gc3VtIChhcnIpIHtcbiAgcmV0dXJuIGFyci5yZWR1Y2UoKGEsIGIpID0+IHtcbiAgICByZXR1cm4gYSArIGJcbiAgfSwgMClcbn1cblxuZnVuY3Rpb24gbWFrZVRlbXBsYXRlQ29tcG9uZW50IChjb21wQ2xhc3MsIGRpc3BsYXlOYW1lKSB7XG4gIGlmICghZGlzcGxheU5hbWUpIHtcbiAgICB0aHJvdyBuZXcgRXJyb3IoJ05vIGRpc3BsYXlOYW1lIGZvdW5kIGZvciB0ZW1wbGF0ZSBjb21wb25lbnQ6JywgY29tcENsYXNzKVxuICB9XG4gIGNvbnN0IGNtcCA9ICh7IGNoaWxkcmVuLCBjbGFzc05hbWUsIC4uLnJlc3QgfSkgPT5cbiAgICA8ZGl2IGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhjb21wQ2xhc3MsIGNsYXNzTmFtZSl9IHsuLi5yZXN0fT5cbiAgICAgIHtjaGlsZHJlbn1cbiAgICA8L2Rpdj5cbiAgY21wLmRpc3BsYXlOYW1lID0gZGlzcGxheU5hbWVcbiAgcmV0dXJuIGNtcFxufVxuXG5mdW5jdGlvbiBncm91cEJ5ICh4cywga2V5KSB7XG4gIHJldHVybiB4cy5yZWR1Y2UoKHJ2LCB4LCBpKSA9PiB7XG4gICAgY29uc3QgcmVzS2V5ID0gdHlwZW9mIGtleSA9PT0gJ2Z1bmN0aW9uJyA/IGtleSh4LCBpKSA6IHhba2V5XVxuICAgIHJ2W3Jlc0tleV0gPSBpc0FycmF5KHJ2W3Jlc0tleV0pID8gcnZbcmVzS2V5XSA6IFtdXG4gICAgcnZbcmVzS2V5XS5wdXNoKHgpXG4gICAgcmV0dXJuIHJ2XG4gIH0sIHt9KVxufVxuXG5mdW5jdGlvbiBhc1B4ICh2YWx1ZSkge1xuICB2YWx1ZSA9IE51bWJlcih2YWx1ZSlcbiAgcmV0dXJuIE51bWJlci5pc05hTih2YWx1ZSkgPyBudWxsIDogdmFsdWUgKyAncHgnXG59XG5cbmZ1bmN0aW9uIGlzQXJyYXkgKGEpIHtcbiAgcmV0dXJuIEFycmF5LmlzQXJyYXkoYSlcbn1cblxuLy8gIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjXG4vLyBOb24tZXhwb3J0ZWQgSGVscGVyc1xuLy8gIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjXG5cbmZ1bmN0aW9uIG1ha2VQYXRoQXJyYXkgKG9iaikge1xuICByZXR1cm4gZmxhdHRlbkRlZXAob2JqKVxuICAgIC5qb2luKCcuJylcbiAgICAucmVwbGFjZSgvXFxbL2csICcuJylcbiAgICAucmVwbGFjZSgvXFxdL2csICcnKVxuICAgIC5zcGxpdCgnLicpXG59XG5cbmZ1bmN0aW9uIGZsYXR0ZW5EZWVwIChhcnIsIG5ld0FyciA9IFtdKSB7XG4gIGlmICghaXNBcnJheShhcnIpKSB7XG4gICAgbmV3QXJyLnB1c2goYXJyKVxuICB9IGVsc2Uge1xuICAgIGZvciAodmFyIGkgPSAwOyBpIDwgYXJyLmxlbmd0aDsgaSsrKSB7XG4gICAgICBmbGF0dGVuRGVlcChhcnJbaV0sIG5ld0FycilcbiAgICB9XG4gIH1cbiAgcmV0dXJuIG5ld0FyclxufVxuXG5mdW5jdGlvbiBzcGxpdFByb3BzICh7IGNsYXNzTmFtZSwgc3R5bGUsIC4uLnJlc3QgfSkge1xuICByZXR1cm4ge1xuICAgIGNsYXNzTmFtZSxcbiAgICBzdHlsZSxcbiAgICByZXN0OiByZXN0IHx8IHt9LFxuICB9XG59XG5cbmZ1bmN0aW9uIGNvbXBhY3RPYmplY3QgKG9iaikge1xuICBjb25zdCBuZXdPYmogPSB7fVxuICBmb3IgKHZhciBrZXkgaW4gb2JqKSB7XG4gICAgaWYgKFxuICAgICAgb2JqLmhhc093blByb3BlcnR5KGtleSkgJiZcbiAgICAgIG9ialtrZXldICE9PSB1bmRlZmluZWQgJiZcbiAgICAgIHR5cGVvZiBvYmpba2V5XSAhPT0gJ3VuZGVmaW5lZCdcbiAgICApIHtcbiAgICAgIG5ld09ialtrZXldID0gb2JqW2tleV1cbiAgICB9XG4gIH1cbiAgcmV0dXJuIG5ld09ialxufVxuXG5mdW5jdGlvbiBpc1NvcnRpbmdEZXNjIChkKSB7XG4gIHJldHVybiAhIShkLnNvcnQgPT09ICdkZXNjJyB8fCBkLmRlc2MgPT09IHRydWUgfHwgZC5hc2MgPT09IGZhbHNlKVxufVxuXG5mdW5jdGlvbiBub3JtYWxpemVDb21wb25lbnQgKENvbXAsIHBhcmFtcyA9IHt9LCBmYWxsYmFjayA9IENvbXApIHtcbiAgcmV0dXJuIHR5cGVvZiBDb21wID09PSAnZnVuY3Rpb24nXG4gICAgPyBPYmplY3QuZ2V0UHJvdG90eXBlT2YoQ29tcCkuaXNSZWFjdENvbXBvbmVudFxuICAgICAgPyA8Q29tcCB7Li4ucGFyYW1zfSAvPlxuICAgICAgOiBDb21wKHBhcmFtcylcbiAgICA6IGZhbGxiYWNrXG59XG4iXX0= + +/***/ }), +/* 96 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33); +var secp256k1 = __webpack_require__(168); +var bigi = __webpack_require__(30); +var zcrypto = __webpack_require__(107); +var zconfig = __webpack_require__(66); + +/* + * Makes a private key + * @param {String} phrase (Password phrase) + * @return {Sting} Private key + */ +function mkPrivKey(phrase) { + return zcrypto.sha256(Buffer.from(phrase, 'utf-8')); +} + +/* + * Converts a private key to WIF format + * @param {String} privKey (private key) + * @param {boolean} toCompressed (Convert to WIF compressed key or nah) + * @param {string} wif (wif hashing bytes (default: 0x80)) + * @return {Sting} WIF format (uncompressed) + */ +function privKeyToWIF(privKey, toCompressed, wif) { + toCompressed = toCompressed || false; + wif = wif || zconfig.mainnet.wif; + + if (toCompressed) privKey = privKey + '01'; + + return bs58check.encode(Buffer.from(wif + privKey, 'hex')); +} + +/* + * Returns private key's public Key + * @param {String} privKey (private key) + * @param {boolean} toCompressed (Convert to public key compressed key or nah) + * @return {Sting} Public Key (default: uncompressed) + */ +function privKeyToPubKey(privKey, toCompressed) { + toCompressed = toCompressed || false; + + const pkBuffer = Buffer.from(privKey, 'hex'); + var publicKey = secp256k1.publicKeyCreate(pkBuffer, toCompressed); + return publicKey.toString('hex'); +} + +/* + * Given a WIF format pk, convert it back to the original pk + * @param {String} privKey (private key) + * @return {Sting} Public Key (uncompressed) + */ +function WIFToPrivKey(wifPk) { + var og = bs58check.decode(wifPk, 'hex').toString('hex'); + og = og.substr(2, og.length); // remove WIF format ('80') + + // remove the '01' at the end to 'compress it' during WIF conversion + if (og.length > 64) { + og = og.substr(0, 64); + } + + return og; +} + +/* + * Converts public key to zencash address + * @param {String} pubKey (public key) + * @param {String} pubKeyHash (public key hash (optional, else use defaul)) + * @return {Sting} zencash address + */ +function pubKeyToAddr(pubKey, pubKeyHash) { + pubKeyHash = pubKeyHash || zconfig.mainnet.pubKeyHash; + + const hash160 = zcrypto.hash160(Buffer.from(pubKey, 'hex')); + return bs58check.encode(Buffer.from(pubKeyHash + hash160, 'hex')).toString('hex'); +} + +module.exports = { + mkPrivKey: mkPrivKey, + privKeyToWIF: privKeyToWIF, + privKeyToPubKey: privKeyToPubKey, + pubKeyToAddr: pubKeyToAddr, + WIFToPrivKey: WIFToPrivKey +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 97 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var inherits = __webpack_require__(4) +var HashBase = __webpack_require__(366) + +function RIPEMD160 () { + HashBase.call(this, 64) + + // state + this._a = 0x67452301 + this._b = 0xefcdab89 + this._c = 0x98badcfe + this._d = 0x10325476 + this._e = 0xc3d2e1f0 +} + +inherits(RIPEMD160, HashBase) + +RIPEMD160.prototype._update = function () { + var m = new Array(16) + for (var i = 0; i < 16; ++i) m[i] = this._block.readInt32LE(i * 4) + + var al = this._a + var bl = this._b + var cl = this._c + var dl = this._d + var el = this._e + + // Mj = 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 + // K = 0x00000000 + // Sj = 11, 14, 15, 12, 5, 8, 7, 9, 11, 13, 14, 15, 6, 7, 9, 8 + al = fn1(al, bl, cl, dl, el, m[0], 0x00000000, 11); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[1], 0x00000000, 14); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[2], 0x00000000, 15); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[3], 0x00000000, 12); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[4], 0x00000000, 5); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[5], 0x00000000, 8); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[6], 0x00000000, 7); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[7], 0x00000000, 9); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[8], 0x00000000, 11); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[9], 0x00000000, 13); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[10], 0x00000000, 14); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[11], 0x00000000, 15); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[12], 0x00000000, 6); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[13], 0x00000000, 7); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[14], 0x00000000, 9); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[15], 0x00000000, 8); cl = rotl(cl, 10) + + // Mj = 7, 4, 13, 1, 10, 6, 15, 3, 12, 0, 9, 5, 2, 14, 11, 8 + // K = 0x5a827999 + // Sj = 7, 6, 8, 13, 11, 9, 7, 15, 7, 12, 15, 9, 11, 7, 13, 12 + el = fn2(el, al, bl, cl, dl, m[7], 0x5a827999, 7); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[4], 0x5a827999, 6); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[13], 0x5a827999, 8); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[1], 0x5a827999, 13); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[10], 0x5a827999, 11); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[6], 0x5a827999, 9); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[15], 0x5a827999, 7); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[3], 0x5a827999, 15); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[12], 0x5a827999, 7); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[0], 0x5a827999, 12); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[9], 0x5a827999, 15); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[5], 0x5a827999, 9); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[2], 0x5a827999, 11); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[14], 0x5a827999, 7); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[11], 0x5a827999, 13); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[8], 0x5a827999, 12); bl = rotl(bl, 10) + + // Mj = 3, 10, 14, 4, 9, 15, 8, 1, 2, 7, 0, 6, 13, 11, 5, 12 + // K = 0x6ed9eba1 + // Sj = 11, 13, 6, 7, 14, 9, 13, 15, 14, 8, 13, 6, 5, 12, 7, 5 + dl = fn3(dl, el, al, bl, cl, m[3], 0x6ed9eba1, 11); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[10], 0x6ed9eba1, 13); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[14], 0x6ed9eba1, 6); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[4], 0x6ed9eba1, 7); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[9], 0x6ed9eba1, 14); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[15], 0x6ed9eba1, 9); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[8], 0x6ed9eba1, 13); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[1], 0x6ed9eba1, 15); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[2], 0x6ed9eba1, 14); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[7], 0x6ed9eba1, 8); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[0], 0x6ed9eba1, 13); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[6], 0x6ed9eba1, 6); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[13], 0x6ed9eba1, 5); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[11], 0x6ed9eba1, 12); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[5], 0x6ed9eba1, 7); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[12], 0x6ed9eba1, 5); al = rotl(al, 10) + + // Mj = 1, 9, 11, 10, 0, 8, 12, 4, 13, 3, 7, 15, 14, 5, 6, 2 + // K = 0x8f1bbcdc + // Sj = 11, 12, 14, 15, 14, 15, 9, 8, 9, 14, 5, 6, 8, 6, 5, 12 + cl = fn4(cl, dl, el, al, bl, m[1], 0x8f1bbcdc, 11); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[9], 0x8f1bbcdc, 12); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[11], 0x8f1bbcdc, 14); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[10], 0x8f1bbcdc, 15); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[0], 0x8f1bbcdc, 14); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[8], 0x8f1bbcdc, 15); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[12], 0x8f1bbcdc, 9); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[4], 0x8f1bbcdc, 8); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[13], 0x8f1bbcdc, 9); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[3], 0x8f1bbcdc, 14); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[7], 0x8f1bbcdc, 5); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[15], 0x8f1bbcdc, 6); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[14], 0x8f1bbcdc, 8); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[5], 0x8f1bbcdc, 6); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[6], 0x8f1bbcdc, 5); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[2], 0x8f1bbcdc, 12); el = rotl(el, 10) + + // Mj = 4, 0, 5, 9, 7, 12, 2, 10, 14, 1, 3, 8, 11, 6, 15, 13 + // K = 0xa953fd4e + // Sj = 9, 15, 5, 11, 6, 8, 13, 12, 5, 12, 13, 14, 11, 8, 5, 6 + bl = fn5(bl, cl, dl, el, al, m[4], 0xa953fd4e, 9); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[0], 0xa953fd4e, 15); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[5], 0xa953fd4e, 5); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[9], 0xa953fd4e, 11); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[7], 0xa953fd4e, 6); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[12], 0xa953fd4e, 8); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[2], 0xa953fd4e, 13); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[10], 0xa953fd4e, 12); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[14], 0xa953fd4e, 5); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[1], 0xa953fd4e, 12); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[3], 0xa953fd4e, 13); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[8], 0xa953fd4e, 14); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[11], 0xa953fd4e, 11); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[6], 0xa953fd4e, 8); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[15], 0xa953fd4e, 5); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[13], 0xa953fd4e, 6); dl = rotl(dl, 10) + + var ar = this._a + var br = this._b + var cr = this._c + var dr = this._d + var er = this._e + + // M'j = 5, 14, 7, 0, 9, 2, 11, 4, 13, 6, 15, 8, 1, 10, 3, 12 + // K' = 0x50a28be6 + // S'j = 8, 9, 9, 11, 13, 15, 15, 5, 7, 7, 8, 11, 14, 14, 12, 6 + ar = fn5(ar, br, cr, dr, er, m[5], 0x50a28be6, 8); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[14], 0x50a28be6, 9); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[7], 0x50a28be6, 9); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[0], 0x50a28be6, 11); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[9], 0x50a28be6, 13); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[2], 0x50a28be6, 15); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[11], 0x50a28be6, 15); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[4], 0x50a28be6, 5); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[13], 0x50a28be6, 7); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[6], 0x50a28be6, 7); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[15], 0x50a28be6, 8); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[8], 0x50a28be6, 11); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[1], 0x50a28be6, 14); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[10], 0x50a28be6, 14); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[3], 0x50a28be6, 12); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[12], 0x50a28be6, 6); cr = rotl(cr, 10) + + // M'j = 6, 11, 3, 7, 0, 13, 5, 10, 14, 15, 8, 12, 4, 9, 1, 2 + // K' = 0x5c4dd124 + // S'j = 9, 13, 15, 7, 12, 8, 9, 11, 7, 7, 12, 7, 6, 15, 13, 11 + er = fn4(er, ar, br, cr, dr, m[6], 0x5c4dd124, 9); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[11], 0x5c4dd124, 13); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[3], 0x5c4dd124, 15); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[7], 0x5c4dd124, 7); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[0], 0x5c4dd124, 12); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[13], 0x5c4dd124, 8); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[5], 0x5c4dd124, 9); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[10], 0x5c4dd124, 11); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[14], 0x5c4dd124, 7); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[15], 0x5c4dd124, 7); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[8], 0x5c4dd124, 12); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[12], 0x5c4dd124, 7); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[4], 0x5c4dd124, 6); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[9], 0x5c4dd124, 15); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[1], 0x5c4dd124, 13); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[2], 0x5c4dd124, 11); br = rotl(br, 10) + + // M'j = 15, 5, 1, 3, 7, 14, 6, 9, 11, 8, 12, 2, 10, 0, 4, 13 + // K' = 0x6d703ef3 + // S'j = 9, 7, 15, 11, 8, 6, 6, 14, 12, 13, 5, 14, 13, 13, 7, 5 + dr = fn3(dr, er, ar, br, cr, m[15], 0x6d703ef3, 9); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[5], 0x6d703ef3, 7); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[1], 0x6d703ef3, 15); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[3], 0x6d703ef3, 11); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[7], 0x6d703ef3, 8); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[14], 0x6d703ef3, 6); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[6], 0x6d703ef3, 6); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[9], 0x6d703ef3, 14); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[11], 0x6d703ef3, 12); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[8], 0x6d703ef3, 13); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[12], 0x6d703ef3, 5); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[2], 0x6d703ef3, 14); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[10], 0x6d703ef3, 13); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[0], 0x6d703ef3, 13); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[4], 0x6d703ef3, 7); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[13], 0x6d703ef3, 5); ar = rotl(ar, 10) + + // M'j = 8, 6, 4, 1, 3, 11, 15, 0, 5, 12, 2, 13, 9, 7, 10, 14 + // K' = 0x7a6d76e9 + // S'j = 15, 5, 8, 11, 14, 14, 6, 14, 6, 9, 12, 9, 12, 5, 15, 8 + cr = fn2(cr, dr, er, ar, br, m[8], 0x7a6d76e9, 15); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[6], 0x7a6d76e9, 5); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[4], 0x7a6d76e9, 8); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[1], 0x7a6d76e9, 11); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[3], 0x7a6d76e9, 14); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[11], 0x7a6d76e9, 14); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[15], 0x7a6d76e9, 6); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[0], 0x7a6d76e9, 14); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[5], 0x7a6d76e9, 6); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[12], 0x7a6d76e9, 9); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[2], 0x7a6d76e9, 12); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[13], 0x7a6d76e9, 9); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[9], 0x7a6d76e9, 12); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[7], 0x7a6d76e9, 5); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[10], 0x7a6d76e9, 15); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[14], 0x7a6d76e9, 8); er = rotl(er, 10) + + // M'j = 12, 15, 10, 4, 1, 5, 8, 7, 6, 2, 13, 14, 0, 3, 9, 11 + // K' = 0x00000000 + // S'j = 8, 5, 12, 9, 12, 5, 14, 6, 8, 13, 6, 5, 15, 13, 11, 11 + br = fn1(br, cr, dr, er, ar, m[12], 0x00000000, 8); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[15], 0x00000000, 5); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[10], 0x00000000, 12); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[4], 0x00000000, 9); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[1], 0x00000000, 12); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[5], 0x00000000, 5); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[8], 0x00000000, 14); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[7], 0x00000000, 6); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[6], 0x00000000, 8); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[2], 0x00000000, 13); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[13], 0x00000000, 6); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[14], 0x00000000, 5); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[0], 0x00000000, 15); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[3], 0x00000000, 13); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[9], 0x00000000, 11); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[11], 0x00000000, 11); dr = rotl(dr, 10) + + // change state + var t = (this._b + cl + dr) | 0 + this._b = (this._c + dl + er) | 0 + this._c = (this._d + el + ar) | 0 + this._d = (this._e + al + br) | 0 + this._e = (this._a + bl + cr) | 0 + this._a = t +} + +RIPEMD160.prototype._digest = function () { + // create padding and handle blocks + this._block[this._blockOffset++] = 0x80 + if (this._blockOffset > 56) { + this._block.fill(0, this._blockOffset, 64) + this._update() + this._blockOffset = 0 + } + + this._block.fill(0, this._blockOffset, 56) + this._block.writeUInt32LE(this._length[0], 56) + this._block.writeUInt32LE(this._length[1], 60) + this._update() + + // produce result + var buffer = new Buffer(20) + buffer.writeInt32LE(this._a, 0) + buffer.writeInt32LE(this._b, 4) + buffer.writeInt32LE(this._c, 8) + buffer.writeInt32LE(this._d, 12) + buffer.writeInt32LE(this._e, 16) + return buffer +} + +function rotl (x, n) { + return (x << n) | (x >>> (32 - n)) +} + +function fn1 (a, b, c, d, e, m, k, s) { + return (rotl((a + (b ^ c ^ d) + m + k) | 0, s) + e) | 0 +} + +function fn2 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b & c) | ((~b) & d)) + m + k) | 0, s) + e) | 0 +} + +function fn3 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b | (~c)) ^ d) + m + k) | 0, s) + e) | 0 +} + +function fn4 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b & d) | (c & (~d))) + m + k) | 0, s) + e) | 0 +} + +function fn5 (a, b, c, d, e, m, k, s) { + return (rotl((a + (b ^ (c | (~d))) + m + k) | 0, s) + e) | 0 +} + +module.exports = RIPEMD160 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 98 */ +/***/ (function(module, exports, __webpack_require__) { + +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +module.exports = Stream; + +var EE = __webpack_require__(99).EventEmitter; +var inherits = __webpack_require__(4); + +inherits(Stream, EE); +Stream.Readable = __webpack_require__(100); +Stream.Writable = __webpack_require__(372); +Stream.Duplex = __webpack_require__(373); +Stream.Transform = __webpack_require__(374); +Stream.PassThrough = __webpack_require__(375); + +// Backwards-compat with node 0.4.x +Stream.Stream = Stream; + + + +// old-style streams. Note that the pipe method (the only relevant +// part of this class) is overridden in the Readable class. + +function Stream() { + EE.call(this); +} + +Stream.prototype.pipe = function(dest, options) { + var source = this; + + function ondata(chunk) { + if (dest.writable) { + if (false === dest.write(chunk) && source.pause) { + source.pause(); + } + } + } + + source.on('data', ondata); + + function ondrain() { + if (source.readable && source.resume) { + source.resume(); + } + } + + dest.on('drain', ondrain); + + // If the 'end' option is not supplied, dest.end() will be called when + // source gets the 'end' or 'close' events. Only dest.end() once. + if (!dest._isStdio && (!options || options.end !== false)) { + source.on('end', onend); + source.on('close', onclose); + } + + var didOnEnd = false; + function onend() { + if (didOnEnd) return; + didOnEnd = true; + + dest.end(); + } + + + function onclose() { + if (didOnEnd) return; + didOnEnd = true; + + if (typeof dest.destroy === 'function') dest.destroy(); + } + + // don't leave dangling pipes when there are errors. + function onerror(er) { + cleanup(); + if (EE.listenerCount(this, 'error') === 0) { + throw er; // Unhandled stream error in pipe. + } + } + + source.on('error', onerror); + dest.on('error', onerror); + + // remove all the event listeners that were added. + function cleanup() { + source.removeListener('data', ondata); + dest.removeListener('drain', ondrain); + + source.removeListener('end', onend); + source.removeListener('close', onclose); + + source.removeListener('error', onerror); + dest.removeListener('error', onerror); + + source.removeListener('end', cleanup); + source.removeListener('close', cleanup); + + dest.removeListener('close', cleanup); + } + + source.on('end', cleanup); + source.on('close', cleanup); + + dest.on('close', cleanup); + + dest.emit('pipe', source); + + // Allow for unix-like usage: A.pipe(B).pipe(C) + return dest; +}; + + +/***/ }), +/* 99 */ +/***/ (function(module, exports) { + +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +function EventEmitter() { + this._events = this._events || {}; + this._maxListeners = this._maxListeners || undefined; +} +module.exports = EventEmitter; + +// Backwards-compat with node 0.10.x +EventEmitter.EventEmitter = EventEmitter; + +EventEmitter.prototype._events = undefined; +EventEmitter.prototype._maxListeners = undefined; + +// By default EventEmitters will print a warning if more than 10 listeners are +// added to it. This is a useful default which helps finding memory leaks. +EventEmitter.defaultMaxListeners = 10; + +// Obviously not all Emitters should be limited to 10. This function allows +// that to be increased. Set to zero for unlimited. +EventEmitter.prototype.setMaxListeners = function(n) { + if (!isNumber(n) || n < 0 || isNaN(n)) + throw TypeError('n must be a positive number'); + this._maxListeners = n; + return this; +}; + +EventEmitter.prototype.emit = function(type) { + var er, handler, len, args, i, listeners; + + if (!this._events) + this._events = {}; + + // If there is no 'error' event listener then throw. + if (type === 'error') { + if (!this._events.error || + (isObject(this._events.error) && !this._events.error.length)) { + er = arguments[1]; + if (er instanceof Error) { + throw er; // Unhandled 'error' event + } else { + // At least give some kind of context to the user + var err = new Error('Uncaught, unspecified "error" event. (' + er + ')'); + err.context = er; + throw err; + } + } + } + + handler = this._events[type]; + + if (isUndefined(handler)) + return false; + + if (isFunction(handler)) { + switch (arguments.length) { + // fast cases + case 1: + handler.call(this); + break; + case 2: + handler.call(this, arguments[1]); + break; + case 3: + handler.call(this, arguments[1], arguments[2]); + break; + // slower + default: + args = Array.prototype.slice.call(arguments, 1); + handler.apply(this, args); + } + } else if (isObject(handler)) { + args = Array.prototype.slice.call(arguments, 1); + listeners = handler.slice(); + len = listeners.length; + for (i = 0; i < len; i++) + listeners[i].apply(this, args); + } + + return true; +}; + +EventEmitter.prototype.addListener = function(type, listener) { + var m; + + if (!isFunction(listener)) + throw TypeError('listener must be a function'); + + if (!this._events) + this._events = {}; + + // To avoid recursion in the case that type === "newListener"! Before + // adding it to the listeners, first emit "newListener". + if (this._events.newListener) + this.emit('newListener', type, + isFunction(listener.listener) ? + listener.listener : listener); + + if (!this._events[type]) + // Optimize the case of one listener. Don't need the extra array object. + this._events[type] = listener; + else if (isObject(this._events[type])) + // If we've already got an array, just append. + this._events[type].push(listener); + else + // Adding the second element, need to change to array. + this._events[type] = [this._events[type], listener]; + + // Check for listener leak + if (isObject(this._events[type]) && !this._events[type].warned) { + if (!isUndefined(this._maxListeners)) { + m = this._maxListeners; + } else { + m = EventEmitter.defaultMaxListeners; + } + + if (m && m > 0 && this._events[type].length > m) { + this._events[type].warned = true; + console.error('(node) warning: possible EventEmitter memory ' + + 'leak detected. %d listeners added. ' + + 'Use emitter.setMaxListeners() to increase limit.', + this._events[type].length); + if (typeof console.trace === 'function') { + // not supported in IE 10 + console.trace(); + } + } + } + + return this; +}; + +EventEmitter.prototype.on = EventEmitter.prototype.addListener; + +EventEmitter.prototype.once = function(type, listener) { + if (!isFunction(listener)) + throw TypeError('listener must be a function'); + + var fired = false; + + function g() { + this.removeListener(type, g); + + if (!fired) { + fired = true; + listener.apply(this, arguments); + } + } + + g.listener = listener; + this.on(type, g); + + return this; +}; + +// emits a 'removeListener' event iff the listener was removed +EventEmitter.prototype.removeListener = function(type, listener) { + var list, position, length, i; + + if (!isFunction(listener)) + throw TypeError('listener must be a function'); + + if (!this._events || !this._events[type]) + return this; + + list = this._events[type]; + length = list.length; + position = -1; + + if (list === listener || + (isFunction(list.listener) && list.listener === listener)) { + delete this._events[type]; + if (this._events.removeListener) + this.emit('removeListener', type, listener); + + } else if (isObject(list)) { + for (i = length; i-- > 0;) { + if (list[i] === listener || + (list[i].listener && list[i].listener === listener)) { + position = i; + break; + } + } + + if (position < 0) + return this; + + if (list.length === 1) { + list.length = 0; + delete this._events[type]; + } else { + list.splice(position, 1); + } + + if (this._events.removeListener) + this.emit('removeListener', type, listener); + } + + return this; +}; + +EventEmitter.prototype.removeAllListeners = function(type) { + var key, listeners; + + if (!this._events) + return this; + + // not listening for removeListener, no need to emit + if (!this._events.removeListener) { + if (arguments.length === 0) + this._events = {}; + else if (this._events[type]) + delete this._events[type]; + return this; + } + + // emit removeListener for all listeners on all events + if (arguments.length === 0) { + for (key in this._events) { + if (key === 'removeListener') continue; + this.removeAllListeners(key); + } + this.removeAllListeners('removeListener'); + this._events = {}; + return this; + } + + listeners = this._events[type]; + + if (isFunction(listeners)) { + this.removeListener(type, listeners); + } else if (listeners) { + // LIFO order + while (listeners.length) + this.removeListener(type, listeners[listeners.length - 1]); + } + delete this._events[type]; + + return this; +}; + +EventEmitter.prototype.listeners = function(type) { + var ret; + if (!this._events || !this._events[type]) + ret = []; + else if (isFunction(this._events[type])) + ret = [this._events[type]]; + else + ret = this._events[type].slice(); + return ret; +}; + +EventEmitter.prototype.listenerCount = function(type) { + if (this._events) { + var evlistener = this._events[type]; + + if (isFunction(evlistener)) + return 1; + else if (evlistener) + return evlistener.length; + } + return 0; +}; + +EventEmitter.listenerCount = function(emitter, type) { + return emitter.listenerCount(type); +}; + +function isFunction(arg) { + return typeof arg === 'function'; +} + +function isNumber(arg) { + return typeof arg === 'number'; +} + +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} + +function isUndefined(arg) { + return arg === void 0; +} + + +/***/ }), +/* 100 */ +/***/ (function(module, exports, __webpack_require__) { + +exports = module.exports = __webpack_require__(161); +exports.Stream = exports; +exports.Readable = exports; +exports.Writable = __webpack_require__(101); +exports.Duplex = __webpack_require__(34); +exports.Transform = __webpack_require__(165); +exports.PassThrough = __webpack_require__(371); + + +/***/ }), +/* 101 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process, setImmediate, global) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// A bit simpler than readable streams. +// Implement an async ._write(chunk, encoding, cb), and it'll handle all +// the drain event emission and buffering. + + + +/*<replacement>*/ + +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +module.exports = Writable; + +/* <replacement> */ +function WriteReq(chunk, encoding, cb) { + this.chunk = chunk; + this.encoding = encoding; + this.callback = cb; + this.next = null; +} + +// It seems a linked list but it is not +// there will be only 2 of these for each stream +function CorkedRequest(state) { + var _this = this; + + this.next = null; + this.entry = null; + this.finish = function () { + onCorkedFinish(_this, state); + }; +} +/* </replacement> */ + +/*<replacement>*/ +var asyncWrite = !process.browser && ['v0.10', 'v0.9.'].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : processNextTick; +/*</replacement>*/ + +/*<replacement>*/ +var Duplex; +/*</replacement>*/ + +Writable.WritableState = WritableState; + +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ + +/*<replacement>*/ +var internalUtil = { + deprecate: __webpack_require__(370) +}; +/*</replacement>*/ + +/*<replacement>*/ +var Stream = __webpack_require__(162); +/*</replacement>*/ + +/*<replacement>*/ +var Buffer = __webpack_require__(7).Buffer; +var OurUint8Array = global.Uint8Array || function () {}; +function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk); +} +function _isUint8Array(obj) { + return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; +} +/*</replacement>*/ + +var destroyImpl = __webpack_require__(163); + +util.inherits(Writable, Stream); + +function nop() {} + +function WritableState(options, stream) { + Duplex = Duplex || __webpack_require__(34); + + options = options || {}; + + // object stream flag to indicate whether or not this stream + // contains buffers or objects. + this.objectMode = !!options.objectMode; + + if (stream instanceof Duplex) this.objectMode = this.objectMode || !!options.writableObjectMode; + + // the point at which write() starts returning false + // Note: 0 is a valid value, means that we always return false if + // the entire buffer is not flushed immediately on write() + var hwm = options.highWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; + this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm; + + // cast to ints. + this.highWaterMark = Math.floor(this.highWaterMark); + + // if _final has been called + this.finalCalled = false; + + // drain event flag. + this.needDrain = false; + // at the start of calling end() + this.ending = false; + // when end() has been called, and returned + this.ended = false; + // when 'finish' is emitted + this.finished = false; + + // has it been destroyed + this.destroyed = false; + + // should we decode strings into buffers before passing to _write? + // this is here so that some node-core streams can optimize string + // handling at a lower level. + var noDecode = options.decodeStrings === false; + this.decodeStrings = !noDecode; + + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; + + // not an actual buffer we keep track of, but a measurement + // of how much we're waiting to get pushed to some underlying + // socket or file. + this.length = 0; + + // a flag to see when we're in the middle of a write. + this.writing = false; + + // when true all writes will be buffered until .uncork() call + this.corked = 0; + + // a flag to be able to tell if the onwrite cb is called immediately, + // or on a later tick. We set this to true at first, because any + // actions that shouldn't happen until "later" should generally also + // not happen before the first write call. + this.sync = true; + + // a flag to know if we're processing previously buffered items, which + // may call the _write() callback in the same tick, so that we don't + // end up in an overlapped onwrite situation. + this.bufferProcessing = false; + + // the callback that's passed to _write(chunk,cb) + this.onwrite = function (er) { + onwrite(stream, er); + }; + + // the callback that the user supplies to write(chunk,encoding,cb) + this.writecb = null; + + // the amount that is being written when _write is called. + this.writelen = 0; + + this.bufferedRequest = null; + this.lastBufferedRequest = null; + + // number of pending user-supplied write callbacks + // this must be 0 before 'finish' can be emitted + this.pendingcb = 0; + + // emit prefinish if the only thing we're waiting for is _write cbs + // This is relevant for synchronous Transform streams + this.prefinished = false; + + // True if the error was already emitted and should not be thrown again + this.errorEmitted = false; + + // count buffered requests + this.bufferedRequestCount = 0; + + // allocate the first CorkedRequest, there is always + // one allocated and free to use, and we maintain at most two + this.corkedRequestsFree = new CorkedRequest(this); +} + +WritableState.prototype.getBuffer = function getBuffer() { + var current = this.bufferedRequest; + var out = []; + while (current) { + out.push(current); + current = current.next; + } + return out; +}; + +(function () { + try { + Object.defineProperty(WritableState.prototype, 'buffer', { + get: internalUtil.deprecate(function () { + return this.getBuffer(); + }, '_writableState.buffer is deprecated. Use _writableState.getBuffer ' + 'instead.', 'DEP0003') + }); + } catch (_) {} +})(); + +// Test _writableState for inheritance to account for Duplex streams, +// whose prototype chain only points to Readable. +var realHasInstance; +if (typeof Symbol === 'function' && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] === 'function') { + realHasInstance = Function.prototype[Symbol.hasInstance]; + Object.defineProperty(Writable, Symbol.hasInstance, { + value: function (object) { + if (realHasInstance.call(this, object)) return true; + + return object && object._writableState instanceof WritableState; + } + }); +} else { + realHasInstance = function (object) { + return object instanceof this; + }; +} + +function Writable(options) { + Duplex = Duplex || __webpack_require__(34); + + // Writable ctor is applied to Duplexes, too. + // `realHasInstance` is necessary because using plain `instanceof` + // would return false, as no `_writableState` property is attached. + + // Trying to use the custom `instanceof` for Writable here will also break the + // Node.js LazyTransform implementation, which has a non-trivial getter for + // `_writableState` that would lead to infinite recursion. + if (!realHasInstance.call(Writable, this) && !(this instanceof Duplex)) { + return new Writable(options); + } + + this._writableState = new WritableState(options, this); + + // legacy. + this.writable = true; + + if (options) { + if (typeof options.write === 'function') this._write = options.write; + + if (typeof options.writev === 'function') this._writev = options.writev; + + if (typeof options.destroy === 'function') this._destroy = options.destroy; + + if (typeof options.final === 'function') this._final = options.final; + } + + Stream.call(this); +} + +// Otherwise people can pipe Writable streams, which is just wrong. +Writable.prototype.pipe = function () { + this.emit('error', new Error('Cannot pipe, not readable')); +}; + +function writeAfterEnd(stream, cb) { + var er = new Error('write after end'); + // TODO: defer error events consistently everywhere, not just the cb + stream.emit('error', er); + processNextTick(cb, er); +} + +// Checks that a user-supplied chunk is valid, especially for the particular +// mode the stream is in. Currently this means that `null` is never accepted +// and undefined/non-string values are only allowed in object mode. +function validChunk(stream, state, chunk, cb) { + var valid = true; + var er = false; + + if (chunk === null) { + er = new TypeError('May not write null values to stream'); + } else if (typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); + } + if (er) { + stream.emit('error', er); + processNextTick(cb, er); + valid = false; + } + return valid; +} + +Writable.prototype.write = function (chunk, encoding, cb) { + var state = this._writableState; + var ret = false; + var isBuf = _isUint8Array(chunk) && !state.objectMode; + + if (isBuf && !Buffer.isBuffer(chunk)) { + chunk = _uint8ArrayToBuffer(chunk); + } + + if (typeof encoding === 'function') { + cb = encoding; + encoding = null; + } + + if (isBuf) encoding = 'buffer';else if (!encoding) encoding = state.defaultEncoding; + + if (typeof cb !== 'function') cb = nop; + + if (state.ended) writeAfterEnd(this, cb);else if (isBuf || validChunk(this, state, chunk, cb)) { + state.pendingcb++; + ret = writeOrBuffer(this, state, isBuf, chunk, encoding, cb); + } + + return ret; +}; + +Writable.prototype.cork = function () { + var state = this._writableState; + + state.corked++; +}; + +Writable.prototype.uncork = function () { + var state = this._writableState; + + if (state.corked) { + state.corked--; + + if (!state.writing && !state.corked && !state.finished && !state.bufferProcessing && state.bufferedRequest) clearBuffer(this, state); + } +}; + +Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) { + // node::ParseEncoding() requires lower case. + if (typeof encoding === 'string') encoding = encoding.toLowerCase(); + if (!(['hex', 'utf8', 'utf-8', 'ascii', 'binary', 'base64', 'ucs2', 'ucs-2', 'utf16le', 'utf-16le', 'raw'].indexOf((encoding + '').toLowerCase()) > -1)) throw new TypeError('Unknown encoding: ' + encoding); + this._writableState.defaultEncoding = encoding; + return this; +}; + +function decodeChunk(state, chunk, encoding) { + if (!state.objectMode && state.decodeStrings !== false && typeof chunk === 'string') { + chunk = Buffer.from(chunk, encoding); + } + return chunk; +} + +// if we're already writing something, then just put this +// in the queue, and wait our turn. Otherwise, call _write +// If we return false, then we need a drain event, so set that flag. +function writeOrBuffer(stream, state, isBuf, chunk, encoding, cb) { + if (!isBuf) { + var newChunk = decodeChunk(state, chunk, encoding); + if (chunk !== newChunk) { + isBuf = true; + encoding = 'buffer'; + chunk = newChunk; + } + } + var len = state.objectMode ? 1 : chunk.length; + + state.length += len; + + var ret = state.length < state.highWaterMark; + // we must ensure that previous needDrain will not be reset to false. + if (!ret) state.needDrain = true; + + if (state.writing || state.corked) { + var last = state.lastBufferedRequest; + state.lastBufferedRequest = { + chunk: chunk, + encoding: encoding, + isBuf: isBuf, + callback: cb, + next: null + }; + if (last) { + last.next = state.lastBufferedRequest; + } else { + state.bufferedRequest = state.lastBufferedRequest; + } + state.bufferedRequestCount += 1; + } else { + doWrite(stream, state, false, len, chunk, encoding, cb); + } + + return ret; +} + +function doWrite(stream, state, writev, len, chunk, encoding, cb) { + state.writelen = len; + state.writecb = cb; + state.writing = true; + state.sync = true; + if (writev) stream._writev(chunk, state.onwrite);else stream._write(chunk, encoding, state.onwrite); + state.sync = false; +} + +function onwriteError(stream, state, sync, er, cb) { + --state.pendingcb; + + if (sync) { + // defer the callback if we are being called synchronously + // to avoid piling up things on the stack + processNextTick(cb, er); + // this can emit finish, and it will always happen + // after error + processNextTick(finishMaybe, stream, state); + stream._writableState.errorEmitted = true; + stream.emit('error', er); + } else { + // the caller expect this to happen before if + // it is async + cb(er); + stream._writableState.errorEmitted = true; + stream.emit('error', er); + // this can emit finish, but finish must + // always follow error + finishMaybe(stream, state); + } +} + +function onwriteStateUpdate(state) { + state.writing = false; + state.writecb = null; + state.length -= state.writelen; + state.writelen = 0; +} + +function onwrite(stream, er) { + var state = stream._writableState; + var sync = state.sync; + var cb = state.writecb; + + onwriteStateUpdate(state); + + if (er) onwriteError(stream, state, sync, er, cb);else { + // Check if we're actually ready to finish, but don't emit yet + var finished = needFinish(state); + + if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) { + clearBuffer(stream, state); + } + + if (sync) { + /*<replacement>*/ + asyncWrite(afterWrite, stream, state, finished, cb); + /*</replacement>*/ + } else { + afterWrite(stream, state, finished, cb); + } + } +} + +function afterWrite(stream, state, finished, cb) { + if (!finished) onwriteDrain(stream, state); + state.pendingcb--; + cb(); + finishMaybe(stream, state); +} + +// Must force callback to be called on nextTick, so that we don't +// emit 'drain' before the write() consumer gets the 'false' return +// value, and has a chance to attach a 'drain' listener. +function onwriteDrain(stream, state) { + if (state.length === 0 && state.needDrain) { + state.needDrain = false; + stream.emit('drain'); + } +} + +// if there's something in the buffer waiting, then process it +function clearBuffer(stream, state) { + state.bufferProcessing = true; + var entry = state.bufferedRequest; + + if (stream._writev && entry && entry.next) { + // Fast case, write everything using _writev() + var l = state.bufferedRequestCount; + var buffer = new Array(l); + var holder = state.corkedRequestsFree; + holder.entry = entry; + + var count = 0; + var allBuffers = true; + while (entry) { + buffer[count] = entry; + if (!entry.isBuf) allBuffers = false; + entry = entry.next; + count += 1; + } + buffer.allBuffers = allBuffers; + + doWrite(stream, state, true, state.length, buffer, '', holder.finish); + + // doWrite is almost always async, defer these to save a bit of time + // as the hot path ends with doWrite + state.pendingcb++; + state.lastBufferedRequest = null; + if (holder.next) { + state.corkedRequestsFree = holder.next; + holder.next = null; + } else { + state.corkedRequestsFree = new CorkedRequest(state); + } + } else { + // Slow case, write chunks one-by-one + while (entry) { + var chunk = entry.chunk; + var encoding = entry.encoding; + var cb = entry.callback; + var len = state.objectMode ? 1 : chunk.length; + + doWrite(stream, state, false, len, chunk, encoding, cb); + entry = entry.next; + // if we didn't call the onwrite immediately, then + // it means that we need to wait until it does. + // also, that means that the chunk and cb are currently + // being processed, so move the buffer counter past them. + if (state.writing) { + break; + } + } + + if (entry === null) state.lastBufferedRequest = null; + } + + state.bufferedRequestCount = 0; + state.bufferedRequest = entry; + state.bufferProcessing = false; +} + +Writable.prototype._write = function (chunk, encoding, cb) { + cb(new Error('_write() is not implemented')); +}; + +Writable.prototype._writev = null; + +Writable.prototype.end = function (chunk, encoding, cb) { + var state = this._writableState; + + if (typeof chunk === 'function') { + cb = chunk; + chunk = null; + encoding = null; + } else if (typeof encoding === 'function') { + cb = encoding; + encoding = null; + } + + if (chunk !== null && chunk !== undefined) this.write(chunk, encoding); + + // .end() fully uncorks + if (state.corked) { + state.corked = 1; + this.uncork(); + } + + // ignore unnecessary end() calls. + if (!state.ending && !state.finished) endWritable(this, state, cb); +}; + +function needFinish(state) { + return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing; +} +function callFinal(stream, state) { + stream._final(function (err) { + state.pendingcb--; + if (err) { + stream.emit('error', err); + } + state.prefinished = true; + stream.emit('prefinish'); + finishMaybe(stream, state); + }); +} +function prefinish(stream, state) { + if (!state.prefinished && !state.finalCalled) { + if (typeof stream._final === 'function') { + state.pendingcb++; + state.finalCalled = true; + processNextTick(callFinal, stream, state); + } else { + state.prefinished = true; + stream.emit('prefinish'); + } + } +} + +function finishMaybe(stream, state) { + var need = needFinish(state); + if (need) { + prefinish(stream, state); + if (state.pendingcb === 0) { + state.finished = true; + stream.emit('finish'); + } + } + return need; +} + +function endWritable(stream, state, cb) { + state.ending = true; + finishMaybe(stream, state); + if (cb) { + if (state.finished) processNextTick(cb);else stream.once('finish', cb); + } + state.ended = true; + stream.writable = false; +} + +function onCorkedFinish(corkReq, state, err) { + var entry = corkReq.entry; + corkReq.entry = null; + while (entry) { + var cb = entry.callback; + state.pendingcb--; + cb(err); + entry = entry.next; + } + if (state.corkedRequestsFree) { + state.corkedRequestsFree.next = corkReq; + } else { + state.corkedRequestsFree = corkReq; + } +} + +Object.defineProperty(Writable.prototype, 'destroyed', { + get: function () { + if (this._writableState === undefined) { + return false; + } + return this._writableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (!this._writableState) { + return; + } + + // backward compatibility, the user is explicitly + // managing destroyed + this._writableState.destroyed = value; + } +}); + +Writable.prototype.destroy = destroyImpl.destroy; +Writable.prototype._undestroy = destroyImpl.undestroy; +Writable.prototype._destroy = function (err, cb) { + this.end(); + cb(err); +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0), __webpack_require__(164).setImmediate, __webpack_require__(24))) + +/***/ }), +/* 102 */ +/***/ (function(module, exports, __webpack_require__) { + +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +var Buffer = __webpack_require__(1).Buffer; + +var isBufferEncoding = Buffer.isEncoding + || function(encoding) { + switch (encoding && encoding.toLowerCase()) { + case 'hex': case 'utf8': case 'utf-8': case 'ascii': case 'binary': case 'base64': case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': case 'raw': return true; + default: return false; + } + } + + +function assertEncoding(encoding) { + if (encoding && !isBufferEncoding(encoding)) { + throw new Error('Unknown encoding: ' + encoding); + } +} + +// StringDecoder provides an interface for efficiently splitting a series of +// buffers into a series of JS strings without breaking apart multi-byte +// characters. CESU-8 is handled as part of the UTF-8 encoding. +// +// @TODO Handling all encodings inside a single object makes it very difficult +// to reason about this code, so it should be split up in the future. +// @TODO There should be a utf8-strict encoding that rejects invalid UTF-8 code +// points as used by CESU-8. +var StringDecoder = exports.StringDecoder = function(encoding) { + this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, ''); + assertEncoding(encoding); + switch (this.encoding) { + case 'utf8': + // CESU-8 represents each of Surrogate Pair by 3-bytes + this.surrogateSize = 3; + break; + case 'ucs2': + case 'utf16le': + // UTF-16 represents each of Surrogate Pair by 2-bytes + this.surrogateSize = 2; + this.detectIncompleteChar = utf16DetectIncompleteChar; + break; + case 'base64': + // Base-64 stores 3 bytes in 4 chars, and pads the remainder. + this.surrogateSize = 3; + this.detectIncompleteChar = base64DetectIncompleteChar; + break; + default: + this.write = passThroughWrite; + return; + } + + // Enough space to store all bytes of a single character. UTF-8 needs 4 + // bytes, but CESU-8 may require up to 6 (3 bytes per surrogate). + this.charBuffer = new Buffer(6); + // Number of bytes received for the current incomplete multi-byte character. + this.charReceived = 0; + // Number of bytes expected for the current incomplete multi-byte character. + this.charLength = 0; +}; + + +// write decodes the given buffer and returns it as JS string that is +// guaranteed to not contain any partial multi-byte characters. Any partial +// character found at the end of the buffer is buffered up, and will be +// returned when calling write again with the remaining bytes. +// +// Note: Converting a Buffer containing an orphan surrogate to a String +// currently works, but converting a String to a Buffer (via `new Buffer`, or +// Buffer#write) will replace incomplete surrogates with the unicode +// replacement character. See https://codereview.chromium.org/121173009/ . +StringDecoder.prototype.write = function(buffer) { + var charStr = ''; + // if our last write ended with an incomplete multibyte character + while (this.charLength) { + // determine how many remaining bytes this buffer has to offer for this char + var available = (buffer.length >= this.charLength - this.charReceived) ? + this.charLength - this.charReceived : + buffer.length; + + // add the new bytes to the char buffer + buffer.copy(this.charBuffer, this.charReceived, 0, available); + this.charReceived += available; + + if (this.charReceived < this.charLength) { + // still not enough chars in this buffer? wait for more ... + return ''; + } + + // remove bytes belonging to the current character from the buffer + buffer = buffer.slice(available, buffer.length); + + // get the character that was split + charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding); + + // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character + var charCode = charStr.charCodeAt(charStr.length - 1); + if (charCode >= 0xD800 && charCode <= 0xDBFF) { + this.charLength += this.surrogateSize; + charStr = ''; + continue; + } + this.charReceived = this.charLength = 0; + + // if there are no more bytes in this buffer, just emit our char + if (buffer.length === 0) { + return charStr; + } + break; + } + + // determine and set charLength / charReceived + this.detectIncompleteChar(buffer); + + var end = buffer.length; + if (this.charLength) { + // buffer the incomplete character bytes we got + buffer.copy(this.charBuffer, 0, buffer.length - this.charReceived, end); + end -= this.charReceived; + } + + charStr += buffer.toString(this.encoding, 0, end); + + var end = charStr.length - 1; + var charCode = charStr.charCodeAt(end); + // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character + if (charCode >= 0xD800 && charCode <= 0xDBFF) { + var size = this.surrogateSize; + this.charLength += size; + this.charReceived += size; + this.charBuffer.copy(this.charBuffer, size, 0, size); + buffer.copy(this.charBuffer, 0, 0, size); + return charStr.substring(0, end); + } + + // or just emit the charStr + return charStr; +}; + +// detectIncompleteChar determines if there is an incomplete UTF-8 character at +// the end of the given buffer. If so, it sets this.charLength to the byte +// length that character, and sets this.charReceived to the number of bytes +// that are available for this character. +StringDecoder.prototype.detectIncompleteChar = function(buffer) { + // determine how many bytes we have to check at the end of this buffer + var i = (buffer.length >= 3) ? 3 : buffer.length; + + // Figure out if one of the last i bytes of our buffer announces an + // incomplete char. + for (; i > 0; i--) { + var c = buffer[buffer.length - i]; + + // See http://en.wikipedia.org/wiki/UTF-8#Description + + // 110XXXXX + if (i == 1 && c >> 5 == 0x06) { + this.charLength = 2; + break; + } + + // 1110XXXX + if (i <= 2 && c >> 4 == 0x0E) { + this.charLength = 3; + break; + } + + // 11110XXX + if (i <= 3 && c >> 3 == 0x1E) { + this.charLength = 4; + break; + } + } + this.charReceived = i; +}; + +StringDecoder.prototype.end = function(buffer) { + var res = ''; + if (buffer && buffer.length) + res = this.write(buffer); + + if (this.charReceived) { + var cr = this.charReceived; + var buf = this.charBuffer; + var enc = this.encoding; + res += buf.slice(0, cr).toString(enc); + } + + return res; +}; + +function passThroughWrite(buffer) { + return buffer.toString(this.encoding); +} + +function utf16DetectIncompleteChar(buffer) { + this.charReceived = buffer.length % 2; + this.charLength = this.charReceived ? 2 : 0; +} + +function base64DetectIncompleteChar(buffer) { + this.charReceived = buffer.length % 3; + this.charLength = this.charReceived ? 3 : 0; +} + + +/***/ }), +/* 103 */ +/***/ (function(module, exports, __webpack_require__) { + +var exports = module.exports = function SHA (algorithm) { + algorithm = algorithm.toLowerCase() + + var Algorithm = exports[algorithm] + if (!Algorithm) throw new Error(algorithm + ' is not supported (we accept pull requests)') + + return new Algorithm() +} + +exports.sha = __webpack_require__(376) +exports.sha1 = __webpack_require__(377) +exports.sha224 = __webpack_require__(378) +exports.sha256 = __webpack_require__(166) +exports.sha384 = __webpack_require__(379) +exports.sha512 = __webpack_require__(167) + + +/***/ }), +/* 104 */ +/***/ (function(module, exports, __webpack_require__) { + +// Reference https://github.com/bitcoin/bips/blob/master/bip-0066.mediawiki +// Format: 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S] +// NOTE: SIGHASH byte ignored AND restricted, truncate before use + +var Buffer = __webpack_require__(7).Buffer + +function check (buffer) { + if (buffer.length < 8) return false + if (buffer.length > 72) return false + if (buffer[0] !== 0x30) return false + if (buffer[1] !== buffer.length - 2) return false + if (buffer[2] !== 0x02) return false + + var lenR = buffer[3] + if (lenR === 0) return false + if (5 + lenR >= buffer.length) return false + if (buffer[4 + lenR] !== 0x02) return false + + var lenS = buffer[5 + lenR] + if (lenS === 0) return false + if ((6 + lenR + lenS) !== buffer.length) return false + + if (buffer[4] & 0x80) return false + if (lenR > 1 && (buffer[4] === 0x00) && !(buffer[5] & 0x80)) return false + + if (buffer[lenR + 6] & 0x80) return false + if (lenS > 1 && (buffer[lenR + 6] === 0x00) && !(buffer[lenR + 7] & 0x80)) return false + return true +} + +function decode (buffer) { + if (buffer.length < 8) throw new Error('DER sequence length is too short') + if (buffer.length > 72) throw new Error('DER sequence length is too long') + if (buffer[0] !== 0x30) throw new Error('Expected DER sequence') + if (buffer[1] !== buffer.length - 2) throw new Error('DER sequence length is invalid') + if (buffer[2] !== 0x02) throw new Error('Expected DER integer') + + var lenR = buffer[3] + if (lenR === 0) throw new Error('R length is zero') + if (5 + lenR >= buffer.length) throw new Error('R length is too long') + if (buffer[4 + lenR] !== 0x02) throw new Error('Expected DER integer (2)') + + var lenS = buffer[5 + lenR] + if (lenS === 0) throw new Error('S length is zero') + if ((6 + lenR + lenS) !== buffer.length) throw new Error('S length is invalid') + + if (buffer[4] & 0x80) throw new Error('R value is negative') + if (lenR > 1 && (buffer[4] === 0x00) && !(buffer[5] & 0x80)) throw new Error('R value excessively padded') + + if (buffer[lenR + 6] & 0x80) throw new Error('S value is negative') + if (lenS > 1 && (buffer[lenR + 6] === 0x00) && !(buffer[lenR + 7] & 0x80)) throw new Error('S value excessively padded') + + // non-BIP66 - extract R, S values + return { + r: buffer.slice(4, 4 + lenR), + s: buffer.slice(6 + lenR) + } +} + +/* + * Expects r and s to be positive DER integers. + * + * The DER format uses the most significant bit as a sign bit (& 0x80). + * If the significant bit is set AND the integer is positive, a 0x00 is prepended. + * + * Examples: + * + * 0 => 0x00 + * 1 => 0x01 + * -1 => 0xff + * 127 => 0x7f + * -127 => 0x81 + * 128 => 0x0080 + * -128 => 0x80 + * 255 => 0x00ff + * -255 => 0xff01 + * 16300 => 0x3fac + * -16300 => 0xc054 + * 62300 => 0x00f35c + * -62300 => 0xff0ca4 +*/ +function encode (r, s) { + var lenR = r.length + var lenS = s.length + if (lenR === 0) throw new Error('R length is zero') + if (lenS === 0) throw new Error('S length is zero') + if (lenR > 33) throw new Error('R length is too long') + if (lenS > 33) throw new Error('S length is too long') + if (r[0] & 0x80) throw new Error('R value is negative') + if (s[0] & 0x80) throw new Error('S value is negative') + if (lenR > 1 && (r[0] === 0x00) && !(r[1] & 0x80)) throw new Error('R value excessively padded') + if (lenS > 1 && (s[0] === 0x00) && !(s[1] & 0x80)) throw new Error('S value excessively padded') + + var signature = Buffer.allocUnsafe(6 + lenR + lenS) + + // 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S] + signature[0] = 0x30 + signature[1] = signature.length - 2 + signature[2] = 0x02 + signature[3] = r.length + r.copy(signature, 4) + signature[4 + lenR] = 0x02 + signature[5 + lenR] = s.length + s.copy(signature, 6 + lenR) + + return signature +} + +module.exports = { + check: check, + decode: decode, + encode: encode +} + + +/***/ }), +/* 105 */ +/***/ (function(module, exports, __webpack_require__) { + +var hash = exports; + +hash.utils = __webpack_require__(25); +hash.common = __webpack_require__(50); +hash.sha = __webpack_require__(393); +hash.ripemd = __webpack_require__(397); +hash.hmac = __webpack_require__(398); + +// Proxy hash functions to the main object +hash.sha1 = hash.sha.sha1; +hash.sha256 = hash.sha.sha256; +hash.sha224 = hash.sha.sha224; +hash.sha384 = hash.sha.sha384; +hash.sha512 = hash.sha.sha512; +hash.ripemd160 = hash.ripemd.ripemd160; + + +/***/ }), +/* 106 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(global) { + +// compare and isBuffer taken from https://github.com/feross/buffer/blob/680e9e5e488f22aac27599a57dc844a6315928dd/index.js +// original notice: + +/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> + * @license MIT + */ +function compare(a, b) { + if (a === b) { + return 0; + } + + var x = a.length; + var y = b.length; + + for (var i = 0, len = Math.min(x, y); i < len; ++i) { + if (a[i] !== b[i]) { + x = a[i]; + y = b[i]; + break; + } + } + + if (x < y) { + return -1; + } + if (y < x) { + return 1; + } + return 0; +} +function isBuffer(b) { + if (global.Buffer && typeof global.Buffer.isBuffer === 'function') { + return global.Buffer.isBuffer(b); + } + return !!(b != null && b._isBuffer); +} + +// based on node assert, original notice: + +// http://wiki.commonjs.org/wiki/Unit_Testing/1.0 +// +// THIS IS NOT TESTED NOR LIKELY TO WORK OUTSIDE V8! +// +// Originally from narwhal.js (http://narwhaljs.org) +// Copyright (c) 2009 Thomas Robinson <280north.com> +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the 'Software'), to +// deal in the Software without restriction, including without limitation the +// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +// sell copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN +// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +var util = __webpack_require__(409); +var hasOwn = Object.prototype.hasOwnProperty; +var pSlice = Array.prototype.slice; +var functionsHaveNames = (function () { + return function foo() {}.name === 'foo'; +}()); +function pToString (obj) { + return Object.prototype.toString.call(obj); +} +function isView(arrbuf) { + if (isBuffer(arrbuf)) { + return false; + } + if (typeof global.ArrayBuffer !== 'function') { + return false; + } + if (typeof ArrayBuffer.isView === 'function') { + return ArrayBuffer.isView(arrbuf); + } + if (!arrbuf) { + return false; + } + if (arrbuf instanceof DataView) { + return true; + } + if (arrbuf.buffer && arrbuf.buffer instanceof ArrayBuffer) { + return true; + } + return false; +} +// 1. The assert module provides functions that throw +// AssertionError's when particular conditions are not met. The +// assert module must conform to the following interface. + +var assert = module.exports = ok; + +// 2. The AssertionError is defined in assert. +// new assert.AssertionError({ message: message, +// actual: actual, +// expected: expected }) + +var regex = /\s*function\s+([^\(\s]*)\s*/; +// based on https://github.com/ljharb/function.prototype.name/blob/adeeeec8bfcc6068b187d7d9fb3d5bb1d3a30899/implementation.js +function getName(func) { + if (!util.isFunction(func)) { + return; + } + if (functionsHaveNames) { + return func.name; + } + var str = func.toString(); + var match = str.match(regex); + return match && match[1]; +} +assert.AssertionError = function AssertionError(options) { + this.name = 'AssertionError'; + this.actual = options.actual; + this.expected = options.expected; + this.operator = options.operator; + if (options.message) { + this.message = options.message; + this.generatedMessage = false; + } else { + this.message = getMessage(this); + this.generatedMessage = true; + } + var stackStartFunction = options.stackStartFunction || fail; + if (Error.captureStackTrace) { + Error.captureStackTrace(this, stackStartFunction); + } else { + // non v8 browsers so we can have a stacktrace + var err = new Error(); + if (err.stack) { + var out = err.stack; + + // try to strip useless frames + var fn_name = getName(stackStartFunction); + var idx = out.indexOf('\n' + fn_name); + if (idx >= 0) { + // once we have located the function frame + // we need to strip out everything before it (and its line) + var next_line = out.indexOf('\n', idx + 1); + out = out.substring(next_line + 1); + } + + this.stack = out; + } + } +}; + +// assert.AssertionError instanceof Error +util.inherits(assert.AssertionError, Error); + +function truncate(s, n) { + if (typeof s === 'string') { + return s.length < n ? s : s.slice(0, n); + } else { + return s; + } +} +function inspect(something) { + if (functionsHaveNames || !util.isFunction(something)) { + return util.inspect(something); + } + var rawname = getName(something); + var name = rawname ? ': ' + rawname : ''; + return '[Function' + name + ']'; +} +function getMessage(self) { + return truncate(inspect(self.actual), 128) + ' ' + + self.operator + ' ' + + truncate(inspect(self.expected), 128); +} + +// At present only the three keys mentioned above are used and +// understood by the spec. Implementations or sub modules can pass +// other keys to the AssertionError's constructor - they will be +// ignored. + +// 3. All of the following functions must throw an AssertionError +// when a corresponding condition is not met, with a message that +// may be undefined if not provided. All assertion methods provide +// both the actual and expected values to the assertion error for +// display purposes. + +function fail(actual, expected, message, operator, stackStartFunction) { + throw new assert.AssertionError({ + message: message, + actual: actual, + expected: expected, + operator: operator, + stackStartFunction: stackStartFunction + }); +} + +// EXTENSION! allows for well behaved errors defined elsewhere. +assert.fail = fail; + +// 4. Pure assertion tests whether a value is truthy, as determined +// by !!guard. +// assert.ok(guard, message_opt); +// This statement is equivalent to assert.equal(true, !!guard, +// message_opt);. To test strictly for the value true, use +// assert.strictEqual(true, guard, message_opt);. + +function ok(value, message) { + if (!value) fail(value, true, message, '==', assert.ok); +} +assert.ok = ok; + +// 5. The equality assertion tests shallow, coercive equality with +// ==. +// assert.equal(actual, expected, message_opt); + +assert.equal = function equal(actual, expected, message) { + if (actual != expected) fail(actual, expected, message, '==', assert.equal); +}; + +// 6. The non-equality assertion tests for whether two objects are not equal +// with != assert.notEqual(actual, expected, message_opt); + +assert.notEqual = function notEqual(actual, expected, message) { + if (actual == expected) { + fail(actual, expected, message, '!=', assert.notEqual); + } +}; + +// 7. The equivalence assertion tests a deep equality relation. +// assert.deepEqual(actual, expected, message_opt); + +assert.deepEqual = function deepEqual(actual, expected, message) { + if (!_deepEqual(actual, expected, false)) { + fail(actual, expected, message, 'deepEqual', assert.deepEqual); + } +}; + +assert.deepStrictEqual = function deepStrictEqual(actual, expected, message) { + if (!_deepEqual(actual, expected, true)) { + fail(actual, expected, message, 'deepStrictEqual', assert.deepStrictEqual); + } +}; + +function _deepEqual(actual, expected, strict, memos) { + // 7.1. All identical values are equivalent, as determined by ===. + if (actual === expected) { + return true; + } else if (isBuffer(actual) && isBuffer(expected)) { + return compare(actual, expected) === 0; + + // 7.2. If the expected value is a Date object, the actual value is + // equivalent if it is also a Date object that refers to the same time. + } else if (util.isDate(actual) && util.isDate(expected)) { + return actual.getTime() === expected.getTime(); + + // 7.3 If the expected value is a RegExp object, the actual value is + // equivalent if it is also a RegExp object with the same source and + // properties (`global`, `multiline`, `lastIndex`, `ignoreCase`). + } else if (util.isRegExp(actual) && util.isRegExp(expected)) { + return actual.source === expected.source && + actual.global === expected.global && + actual.multiline === expected.multiline && + actual.lastIndex === expected.lastIndex && + actual.ignoreCase === expected.ignoreCase; + + // 7.4. Other pairs that do not both pass typeof value == 'object', + // equivalence is determined by ==. + } else if ((actual === null || typeof actual !== 'object') && + (expected === null || typeof expected !== 'object')) { + return strict ? actual === expected : actual == expected; + + // If both values are instances of typed arrays, wrap their underlying + // ArrayBuffers in a Buffer each to increase performance + // This optimization requires the arrays to have the same type as checked by + // Object.prototype.toString (aka pToString). Never perform binary + // comparisons for Float*Arrays, though, since e.g. +0 === -0 but their + // bit patterns are not identical. + } else if (isView(actual) && isView(expected) && + pToString(actual) === pToString(expected) && + !(actual instanceof Float32Array || + actual instanceof Float64Array)) { + return compare(new Uint8Array(actual.buffer), + new Uint8Array(expected.buffer)) === 0; + + // 7.5 For all other Object pairs, including Array objects, equivalence is + // determined by having the same number of owned properties (as verified + // with Object.prototype.hasOwnProperty.call), the same set of keys + // (although not necessarily the same order), equivalent values for every + // corresponding key, and an identical 'prototype' property. Note: this + // accounts for both named and indexed properties on Arrays. + } else if (isBuffer(actual) !== isBuffer(expected)) { + return false; + } else { + memos = memos || {actual: [], expected: []}; + + var actualIndex = memos.actual.indexOf(actual); + if (actualIndex !== -1) { + if (actualIndex === memos.expected.indexOf(expected)) { + return true; + } + } + + memos.actual.push(actual); + memos.expected.push(expected); + + return objEquiv(actual, expected, strict, memos); + } +} + +function isArguments(object) { + return Object.prototype.toString.call(object) == '[object Arguments]'; +} + +function objEquiv(a, b, strict, actualVisitedObjects) { + if (a === null || a === undefined || b === null || b === undefined) + return false; + // if one is a primitive, the other must be same + if (util.isPrimitive(a) || util.isPrimitive(b)) + return a === b; + if (strict && Object.getPrototypeOf(a) !== Object.getPrototypeOf(b)) + return false; + var aIsArgs = isArguments(a); + var bIsArgs = isArguments(b); + if ((aIsArgs && !bIsArgs) || (!aIsArgs && bIsArgs)) + return false; + if (aIsArgs) { + a = pSlice.call(a); + b = pSlice.call(b); + return _deepEqual(a, b, strict); + } + var ka = objectKeys(a); + var kb = objectKeys(b); + var key, i; + // having the same number of owned properties (keys incorporates + // hasOwnProperty) + if (ka.length !== kb.length) + return false; + //the same set of keys (although not necessarily the same order), + ka.sort(); + kb.sort(); + //~~~cheap key test + for (i = ka.length - 1; i >= 0; i--) { + if (ka[i] !== kb[i]) + return false; + } + //equivalent values for every corresponding key, and + //~~~possibly expensive deep test + for (i = ka.length - 1; i >= 0; i--) { + key = ka[i]; + if (!_deepEqual(a[key], b[key], strict, actualVisitedObjects)) + return false; + } + return true; +} + +// 8. The non-equivalence assertion tests for any deep inequality. +// assert.notDeepEqual(actual, expected, message_opt); + +assert.notDeepEqual = function notDeepEqual(actual, expected, message) { + if (_deepEqual(actual, expected, false)) { + fail(actual, expected, message, 'notDeepEqual', assert.notDeepEqual); + } +}; + +assert.notDeepStrictEqual = notDeepStrictEqual; +function notDeepStrictEqual(actual, expected, message) { + if (_deepEqual(actual, expected, true)) { + fail(actual, expected, message, 'notDeepStrictEqual', notDeepStrictEqual); + } +} + + +// 9. The strict equality assertion tests strict equality, as determined by ===. +// assert.strictEqual(actual, expected, message_opt); + +assert.strictEqual = function strictEqual(actual, expected, message) { + if (actual !== expected) { + fail(actual, expected, message, '===', assert.strictEqual); + } +}; + +// 10. The strict non-equality assertion tests for strict inequality, as +// determined by !==. assert.notStrictEqual(actual, expected, message_opt); + +assert.notStrictEqual = function notStrictEqual(actual, expected, message) { + if (actual === expected) { + fail(actual, expected, message, '!==', assert.notStrictEqual); + } +}; + +function expectedException(actual, expected) { + if (!actual || !expected) { + return false; + } + + if (Object.prototype.toString.call(expected) == '[object RegExp]') { + return expected.test(actual); + } + + try { + if (actual instanceof expected) { + return true; + } + } catch (e) { + // Ignore. The instanceof check doesn't work for arrow functions. + } + + if (Error.isPrototypeOf(expected)) { + return false; + } + + return expected.call({}, actual) === true; +} + +function _tryBlock(block) { + var error; + try { + block(); + } catch (e) { + error = e; + } + return error; +} + +function _throws(shouldThrow, block, expected, message) { + var actual; + + if (typeof block !== 'function') { + throw new TypeError('"block" argument must be a function'); + } + + if (typeof expected === 'string') { + message = expected; + expected = null; + } + + actual = _tryBlock(block); + + message = (expected && expected.name ? ' (' + expected.name + ').' : '.') + + (message ? ' ' + message : '.'); + + if (shouldThrow && !actual) { + fail(actual, expected, 'Missing expected exception' + message); + } + + var userProvidedMessage = typeof message === 'string'; + var isUnwantedException = !shouldThrow && util.isError(actual); + var isUnexpectedException = !shouldThrow && actual && !expected; + + if ((isUnwantedException && + userProvidedMessage && + expectedException(actual, expected)) || + isUnexpectedException) { + fail(actual, expected, 'Got unwanted exception' + message); + } + + if ((shouldThrow && actual && expected && + !expectedException(actual, expected)) || (!shouldThrow && actual)) { + throw actual; + } +} + +// 11. Expected to throw an error: +// assert.throws(block, Error_opt, message_opt); + +assert.throws = function(block, /*optional*/error, /*optional*/message) { + _throws(true, block, error, message); +}; + +// EXTENSION! This is annoying to write outside this module. +assert.doesNotThrow = function(block, /*optional*/error, /*optional*/message) { + _throws(false, block, error, message); +}; + +assert.ifError = function(err) { if (err) throw err; }; + +var objectKeys = Object.keys || function (obj) { + var keys = []; + for (var key in obj) { + if (hasOwn.call(obj, key)) keys.push(key); + } + return keys; +}; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) + +/***/ }), +/* 107 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/* + * Obtained from https://github.com/bitcoinjs/bitcoinjs-lib/blob/master/src/crypto.js + * 2017/07/25: No ripemd160 in SJCL, so resorted to this + */ + +var createHash = __webpack_require__(27); + +function ripemd160(buffer) { + return createHash('rmd160').update(buffer).digest('hex'); +} + +function sha1(buffer) { + return createHash('sha1').update(buffer).digest('hex'); +} + +function sha256(buffer) { + return createHash('sha256').update(buffer).digest('hex'); +} + +function sha256x2(buffer) { + return sha256(Buffer.from(sha256(buffer), 'hex')); +} + +function hash160(buffer) { + const sha = sha256(buffer); + const hash160 = ripemd160(Buffer.from(sha, 'hex')); + return hash160; +} + +module.exports = { + hash160: hash160, + ripemd160: ripemd160, + sha1: sha1, + sha256: sha256, + sha256x2: sha256x2 +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 108 */ +/***/ (function(module, exports, __webpack_require__) { + +var ciphers = __webpack_require__(424) +exports.createCipher = exports.Cipher = ciphers.createCipher +exports.createCipheriv = exports.Cipheriv = ciphers.createCipheriv +var deciphers = __webpack_require__(426) +exports.createDecipher = exports.Decipher = deciphers.createDecipher +exports.createDecipheriv = exports.Decipheriv = deciphers.createDecipheriv +var modes = __webpack_require__(70) +function getCiphers () { + return Object.keys(modes) +} +exports.listCiphers = exports.getCiphers = getCiphers + + +/***/ }), +/* 109 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.utils = __webpack_require__(428); +exports.Cipher = __webpack_require__(429); +exports.DES = __webpack_require__(430); +exports.CBC = __webpack_require__(431); +exports.EDE = __webpack_require__(432); + + +/***/ }), +/* 110 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var bn = __webpack_require__(11); +var randomBytes = __webpack_require__(43); +module.exports = crt; +function blind(priv) { + var r = getr(priv); + var blinder = r.toRed(bn.mont(priv.modulus)) + .redPow(new bn(priv.publicExponent)).fromRed(); + return { + blinder: blinder, + unblinder:r.invm(priv.modulus) + }; +} +function crt(msg, priv) { + var blinds = blind(priv); + var len = priv.modulus.byteLength(); + var mod = bn.mont(priv.modulus); + var blinded = new bn(msg).mul(blinds.blinder).umod(priv.modulus); + var c1 = blinded.toRed(bn.mont(priv.prime1)); + var c2 = blinded.toRed(bn.mont(priv.prime2)); + var qinv = priv.coefficient; + var p = priv.prime1; + var q = priv.prime2; + var m1 = c1.redPow(priv.exponent1); + var m2 = c2.redPow(priv.exponent2); + m1 = m1.fromRed(); + m2 = m2.fromRed(); + var h = m1.isub(m2).imul(qinv).umod(p); + h.imul(q); + m2.iadd(h); + return new Buffer(m2.imul(blinds.unblinder).umod(priv.modulus).toArray(false, len)); +} +crt.getr = getr; +function getr(priv) { + var len = priv.modulus.byteLength(); + var r = new bn(randomBytes(len)); + while (r.cmp(priv.modulus) >= 0 || !r.umod(priv.prime1) || !r.umod(priv.prime2)) { + r = new bn(randomBytes(len)); + } + return r; +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 111 */ +/***/ (function(module, exports) { + +var types = { + Array: function (value) { return value !== null && value !== undefined && value.constructor === Array }, + Boolean: function (value) { return typeof value === 'boolean' }, + Function: function (value) { return typeof value === 'function' }, + Nil: function (value) { return value === undefined || value === null }, + Number: function (value) { return typeof value === 'number' }, + Object: function (value) { return typeof value === 'object' }, + String: function (value) { return typeof value === 'string' }, + '': function () { return true } +} + +// TODO: deprecate +types.Null = types.Nil + +for (var typeName in types) { + types[typeName].toJSON = function (t) { + return t + }.bind(null, typeName) +} + +module.exports = types + + +/***/ }), +/* 112 */ +/***/ (function(module, exports, __webpack_require__) { + +var Buffer = __webpack_require__(7).Buffer +var bcrypto = __webpack_require__(44) +var bscript = __webpack_require__(14) +var bufferutils = __webpack_require__(206) +var opcodes = __webpack_require__(16) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var varuint = __webpack_require__(73) + +function varSliceSize (someScript) { + var length = someScript.length + + return varuint.encodingLength(length) + length +} + +function vectorSize (someVector) { + var length = someVector.length + + return varuint.encodingLength(length) + someVector.reduce(function (sum, witness) { + return sum + varSliceSize(witness) + }, 0) +} + +function Transaction () { + this.version = 1 + this.locktime = 0 + this.ins = [] + this.outs = [] +} + +Transaction.DEFAULT_SEQUENCE = 0xffffffff +Transaction.SIGHASH_ALL = 0x01 +Transaction.SIGHASH_NONE = 0x02 +Transaction.SIGHASH_SINGLE = 0x03 +Transaction.SIGHASH_ANYONECANPAY = 0x80 +Transaction.ADVANCED_TRANSACTION_MARKER = 0x00 +Transaction.ADVANCED_TRANSACTION_FLAG = 0x01 + +var EMPTY_SCRIPT = Buffer.allocUnsafe(0) +var EMPTY_WITNESS = [] +var ZERO = Buffer.from('0000000000000000000000000000000000000000000000000000000000000000', 'hex') +var ONE = Buffer.from('0000000000000000000000000000000000000000000000000000000000000001', 'hex') +var VALUE_UINT64_MAX = Buffer.from('ffffffffffffffff', 'hex') +var BLANK_OUTPUT = { + script: EMPTY_SCRIPT, + valueBuffer: VALUE_UINT64_MAX +} + +Transaction.fromBuffer = function (buffer, __noStrict) { + var offset = 0 + function readSlice (n) { + offset += n + return buffer.slice(offset - n, offset) + } + + function readUInt32 () { + var i = buffer.readUInt32LE(offset) + offset += 4 + return i + } + + function readInt32 () { + var i = buffer.readInt32LE(offset) + offset += 4 + return i + } + + function readUInt64 () { + var i = bufferutils.readUInt64LE(buffer, offset) + offset += 8 + return i + } + + function readVarInt () { + var vi = varuint.decode(buffer, offset) + offset += varuint.decode.bytes + return vi + } + + function readVarSlice () { + return readSlice(readVarInt()) + } + + function readVector () { + var count = readVarInt() + var vector = [] + for (var i = 0; i < count; i++) vector.push(readVarSlice()) + return vector + } + + var tx = new Transaction() + tx.version = readInt32() + + var marker = buffer.readUInt8(offset) + var flag = buffer.readUInt8(offset + 1) + + var hasWitnesses = false + if (marker === Transaction.ADVANCED_TRANSACTION_MARKER && + flag === Transaction.ADVANCED_TRANSACTION_FLAG) { + offset += 2 + hasWitnesses = true + } + + var vinLen = readVarInt() + for (var i = 0; i < vinLen; ++i) { + tx.ins.push({ + hash: readSlice(32), + index: readUInt32(), + script: readVarSlice(), + sequence: readUInt32(), + witness: EMPTY_WITNESS + }) + } + + var voutLen = readVarInt() + for (i = 0; i < voutLen; ++i) { + tx.outs.push({ + value: readUInt64(), + script: readVarSlice() + }) + } + + if (hasWitnesses) { + for (i = 0; i < vinLen; ++i) { + tx.ins[i].witness = readVector() + } + + // was this pointless? + if (!tx.hasWitnesses()) throw new Error('Transaction has superfluous witness data') + } + + tx.locktime = readUInt32() + + if (__noStrict) return tx + if (offset !== buffer.length) throw new Error('Transaction has unexpected data') + + return tx +} + +Transaction.fromHex = function (hex) { + return Transaction.fromBuffer(Buffer.from(hex, 'hex')) +} + +Transaction.isCoinbaseHash = function (buffer) { + typeforce(types.Hash256bit, buffer) + for (var i = 0; i < 32; ++i) { + if (buffer[i] !== 0) return false + } + return true +} + +Transaction.prototype.isCoinbase = function () { + return this.ins.length === 1 && Transaction.isCoinbaseHash(this.ins[0].hash) +} + +Transaction.prototype.addInput = function (hash, index, sequence, scriptSig) { + typeforce(types.tuple( + types.Hash256bit, + types.UInt32, + types.maybe(types.UInt32), + types.maybe(types.Buffer) + ), arguments) + + if (types.Null(sequence)) { + sequence = Transaction.DEFAULT_SEQUENCE + } + + // Add the input and return the input's index + return (this.ins.push({ + hash: hash, + index: index, + script: scriptSig || EMPTY_SCRIPT, + sequence: sequence, + witness: EMPTY_WITNESS + }) - 1) +} + +Transaction.prototype.addOutput = function (scriptPubKey, value) { + typeforce(types.tuple(types.Buffer, types.Satoshi), arguments) + + // Add the output and return the output's index + return (this.outs.push({ + script: scriptPubKey, + value: value + }) - 1) +} + +Transaction.prototype.hasWitnesses = function () { + return this.ins.some(function (x) { + return x.witness.length !== 0 + }) +} + +Transaction.prototype.weight = function () { + var base = this.__byteLength(false) + var total = this.__byteLength(true) + return base * 3 + total +} + +Transaction.prototype.virtualSize = function () { + return Math.ceil(this.weight() / 4) +} + +Transaction.prototype.byteLength = function () { + return this.__byteLength(true) +} + +Transaction.prototype.__byteLength = function (__allowWitness) { + var hasWitnesses = __allowWitness && this.hasWitnesses() + + return ( + (hasWitnesses ? 10 : 8) + + varuint.encodingLength(this.ins.length) + + varuint.encodingLength(this.outs.length) + + this.ins.reduce(function (sum, input) { return sum + 40 + varSliceSize(input.script) }, 0) + + this.outs.reduce(function (sum, output) { return sum + 8 + varSliceSize(output.script) }, 0) + + (hasWitnesses ? this.ins.reduce(function (sum, input) { return sum + vectorSize(input.witness) }, 0) : 0) + ) +} + +Transaction.prototype.clone = function () { + var newTx = new Transaction() + newTx.version = this.version + newTx.locktime = this.locktime + + newTx.ins = this.ins.map(function (txIn) { + return { + hash: txIn.hash, + index: txIn.index, + script: txIn.script, + sequence: txIn.sequence, + witness: txIn.witness + } + }) + + newTx.outs = this.outs.map(function (txOut) { + return { + script: txOut.script, + value: txOut.value + } + }) + + return newTx +} + +/** + * Hash transaction for signing a specific input. + * + * Bitcoin uses a different hash for each signed transaction input. + * This method copies the transaction, makes the necessary changes based on the + * hashType, and then hashes the result. + * This hash can then be used to sign the provided transaction input. + */ +Transaction.prototype.hashForSignature = function (inIndex, prevOutScript, hashType) { + typeforce(types.tuple(types.UInt32, types.Buffer, /* types.UInt8 */ types.Number), arguments) + + // https://github.com/bitcoin/bitcoin/blob/master/src/test/sighash_tests.cpp#L29 + if (inIndex >= this.ins.length) return ONE + + // ignore OP_CODESEPARATOR + var ourScript = bscript.compile(bscript.decompile(prevOutScript).filter(function (x) { + return x !== opcodes.OP_CODESEPARATOR + })) + + var txTmp = this.clone() + + // SIGHASH_NONE: ignore all outputs? (wildcard payee) + if ((hashType & 0x1f) === Transaction.SIGHASH_NONE) { + txTmp.outs = [] + + // ignore sequence numbers (except at inIndex) + txTmp.ins.forEach(function (input, i) { + if (i === inIndex) return + + input.sequence = 0 + }) + + // SIGHASH_SINGLE: ignore all outputs, except at the same index? + } else if ((hashType & 0x1f) === Transaction.SIGHASH_SINGLE) { + // https://github.com/bitcoin/bitcoin/blob/master/src/test/sighash_tests.cpp#L60 + if (inIndex >= this.outs.length) return ONE + + // truncate outputs after + txTmp.outs.length = inIndex + 1 + + // "blank" outputs before + for (var i = 0; i < inIndex; i++) { + txTmp.outs[i] = BLANK_OUTPUT + } + + // ignore sequence numbers (except at inIndex) + txTmp.ins.forEach(function (input, y) { + if (y === inIndex) return + + input.sequence = 0 + }) + } + + // SIGHASH_ANYONECANPAY: ignore inputs entirely? + if (hashType & Transaction.SIGHASH_ANYONECANPAY) { + txTmp.ins = [txTmp.ins[inIndex]] + txTmp.ins[0].script = ourScript + + // SIGHASH_ALL: only ignore input scripts + } else { + // "blank" others input scripts + txTmp.ins.forEach(function (input) { input.script = EMPTY_SCRIPT }) + txTmp.ins[inIndex].script = ourScript + } + + // serialize and hash + var buffer = Buffer.allocUnsafe(txTmp.__byteLength(false) + 4) + buffer.writeInt32LE(hashType, buffer.length - 4) + txTmp.__toBuffer(buffer, 0, false) + + return bcrypto.hash256(buffer) +} + +Transaction.prototype.hashForWitnessV0 = function (inIndex, prevOutScript, value, hashType) { + typeforce(types.tuple(types.UInt32, types.Buffer, types.Satoshi, types.UInt32), arguments) + + var tbuffer, toffset + function writeSlice (slice) { toffset += slice.copy(tbuffer, toffset) } + function writeUInt32 (i) { toffset = tbuffer.writeUInt32LE(i, toffset) } + function writeUInt64 (i) { toffset = bufferutils.writeUInt64LE(tbuffer, i, toffset) } + function writeVarInt (i) { + varuint.encode(i, tbuffer, toffset) + toffset += varuint.encode.bytes + } + function writeVarSlice (slice) { writeVarInt(slice.length); writeSlice(slice) } + + var hashOutputs = ZERO + var hashPrevouts = ZERO + var hashSequence = ZERO + + if (!(hashType & Transaction.SIGHASH_ANYONECANPAY)) { + tbuffer = Buffer.allocUnsafe(36 * this.ins.length) + toffset = 0 + + this.ins.forEach(function (txIn) { + writeSlice(txIn.hash) + writeUInt32(txIn.index) + }) + + hashPrevouts = bcrypto.hash256(tbuffer) + } + + if (!(hashType & Transaction.SIGHASH_ANYONECANPAY) && + (hashType & 0x1f) !== Transaction.SIGHASH_SINGLE && + (hashType & 0x1f) !== Transaction.SIGHASH_NONE) { + tbuffer = Buffer.allocUnsafe(4 * this.ins.length) + toffset = 0 + + this.ins.forEach(function (txIn) { + writeUInt32(txIn.sequence) + }) + + hashSequence = bcrypto.hash256(tbuffer) + } + + if ((hashType & 0x1f) !== Transaction.SIGHASH_SINGLE && + (hashType & 0x1f) !== Transaction.SIGHASH_NONE) { + var txOutsSize = this.outs.reduce(function (sum, output) { + return sum + 8 + varSliceSize(output.script) + }, 0) + + tbuffer = Buffer.allocUnsafe(txOutsSize) + toffset = 0 + + this.outs.forEach(function (out) { + writeUInt64(out.value) + writeVarSlice(out.script) + }) + + hashOutputs = bcrypto.hash256(tbuffer) + } else if ((hashType & 0x1f) === Transaction.SIGHASH_SINGLE && inIndex < this.outs.length) { + var output = this.outs[inIndex] + + tbuffer = Buffer.allocUnsafe(8 + varSliceSize(output.script)) + toffset = 0 + writeUInt64(output.value) + writeVarSlice(output.script) + + hashOutputs = bcrypto.hash256(tbuffer) + } + + tbuffer = Buffer.allocUnsafe(156 + varSliceSize(prevOutScript)) + toffset = 0 + + var input = this.ins[inIndex] + writeUInt32(this.version) + writeSlice(hashPrevouts) + writeSlice(hashSequence) + writeSlice(input.hash) + writeUInt32(input.index) + writeVarSlice(prevOutScript) + writeUInt64(value) + writeUInt32(input.sequence) + writeSlice(hashOutputs) + writeUInt32(this.locktime) + writeUInt32(hashType) + return bcrypto.hash256(tbuffer) +} + +Transaction.prototype.getHash = function () { + return bcrypto.hash256(this.__toBuffer(undefined, undefined, false)) +} + +Transaction.prototype.getId = function () { + // transaction hash's are displayed in reverse order + return this.getHash().reverse().toString('hex') +} + +Transaction.prototype.toBuffer = function (buffer, initialOffset) { + return this.__toBuffer(buffer, initialOffset, true) +} + +Transaction.prototype.__toBuffer = function (buffer, initialOffset, __allowWitness) { + if (!buffer) buffer = Buffer.allocUnsafe(this.__byteLength(__allowWitness)) + + var offset = initialOffset || 0 + function writeSlice (slice) { offset += slice.copy(buffer, offset) } + function writeUInt8 (i) { offset = buffer.writeUInt8(i, offset) } + function writeUInt32 (i) { offset = buffer.writeUInt32LE(i, offset) } + function writeInt32 (i) { offset = buffer.writeInt32LE(i, offset) } + function writeUInt64 (i) { offset = bufferutils.writeUInt64LE(buffer, i, offset) } + function writeVarInt (i) { + varuint.encode(i, buffer, offset) + offset += varuint.encode.bytes + } + function writeVarSlice (slice) { writeVarInt(slice.length); writeSlice(slice) } + function writeVector (vector) { writeVarInt(vector.length); vector.forEach(writeVarSlice) } + + writeInt32(this.version) + + var hasWitnesses = __allowWitness && this.hasWitnesses() + + if (hasWitnesses) { + writeUInt8(Transaction.ADVANCED_TRANSACTION_MARKER) + writeUInt8(Transaction.ADVANCED_TRANSACTION_FLAG) + } + + writeVarInt(this.ins.length) + + this.ins.forEach(function (txIn) { + writeSlice(txIn.hash) + writeUInt32(txIn.index) + writeVarSlice(txIn.script) + writeUInt32(txIn.sequence) + }) + + writeVarInt(this.outs.length) + this.outs.forEach(function (txOut) { + if (!txOut.valueBuffer) { + writeUInt64(txOut.value) + } else { + writeSlice(txOut.valueBuffer) + } + + writeVarSlice(txOut.script) + }) + + if (hasWitnesses) { + this.ins.forEach(function (input) { + writeVector(input.witness) + }) + } + + writeUInt32(this.locktime) + + // avoid slicing unless necessary + if (initialOffset !== undefined) return buffer.slice(initialOffset, offset) + return buffer +} + +Transaction.prototype.toHex = function () { + return this.toBuffer().toString('hex') +} + +Transaction.prototype.setInputScript = function (index, scriptSig) { + typeforce(types.tuple(types.Number, types.Buffer), arguments) + + this.ins[index].script = scriptSig +} + +Transaction.prototype.setWitness = function (index, witness) { + typeforce(types.tuple(types.Number, [types.Buffer]), arguments) + + this.ins[index].witness = witness +} + +module.exports = Transaction + + +/***/ }), +/* 113 */ +/***/ (function(module, exports, __webpack_require__) { + +var baddress = __webpack_require__(114) +var bcrypto = __webpack_require__(44) +var ecdsa = __webpack_require__(489) +var randomBytes = __webpack_require__(43) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var wif = __webpack_require__(492) + +var NETWORKS = __webpack_require__(54) +var BigInteger = __webpack_require__(30) + +var ecurve = __webpack_require__(116) +var secp256k1 = ecdsa.__curve + +function ECPair (d, Q, options) { + if (options) { + typeforce({ + compressed: types.maybe(types.Boolean), + network: types.maybe(types.Network) + }, options) + } + + options = options || {} + + if (d) { + if (d.signum() <= 0) throw new Error('Private key must be greater than 0') + if (d.compareTo(secp256k1.n) >= 0) throw new Error('Private key must be less than the curve order') + if (Q) throw new TypeError('Unexpected publicKey parameter') + + this.d = d + } else { + typeforce(types.ECPoint, Q) + + this.__Q = Q + } + + this.compressed = options.compressed === undefined ? true : options.compressed + this.network = options.network || NETWORKS.bitcoin +} + +Object.defineProperty(ECPair.prototype, 'Q', { + get: function () { + if (!this.__Q && this.d) { + this.__Q = secp256k1.G.multiply(this.d) + } + + return this.__Q + } +}) + +ECPair.fromPublicKeyBuffer = function (buffer, network) { + var Q = ecurve.Point.decodeFrom(secp256k1, buffer) + + return new ECPair(null, Q, { + compressed: Q.compressed, + network: network + }) +} + +ECPair.fromWIF = function (string, network) { + var decoded = wif.decode(string) + var version = decoded.version + + // list of networks? + if (types.Array(network)) { + network = network.filter(function (x) { + return version === x.wif + }).pop() + + if (!network) throw new Error('Unknown network version') + + // otherwise, assume a network object (or default to bitcoin) + } else { + network = network || NETWORKS.bitcoin + + if (version !== network.wif) throw new Error('Invalid network version') + } + + var d = BigInteger.fromBuffer(decoded.privateKey) + + return new ECPair(d, null, { + compressed: decoded.compressed, + network: network + }) +} + +ECPair.makeRandom = function (options) { + options = options || {} + + var rng = options.rng || randomBytes + + var d + do { + var buffer = rng(32) + typeforce(types.Buffer256bit, buffer) + + d = BigInteger.fromBuffer(buffer) + } while (d.signum() <= 0 || d.compareTo(secp256k1.n) >= 0) + + return new ECPair(d, null, options) +} + +ECPair.prototype.getAddress = function () { + return baddress.toBase58Check(bcrypto.hash160(this.getPublicKeyBuffer()), this.getNetwork().pubKeyHash) +} + +ECPair.prototype.getNetwork = function () { + return this.network +} + +ECPair.prototype.getPublicKeyBuffer = function () { + return this.Q.getEncoded(this.compressed) +} + +ECPair.prototype.sign = function (hash) { + if (!this.d) throw new Error('Missing private key') + + return ecdsa.sign(hash, this.d) +} + +ECPair.prototype.toWIF = function () { + if (!this.d) throw new Error('Missing private key') + + return wif.encode(this.network.wif, this.d.toBuffer(32), this.compressed) +} + +ECPair.prototype.verify = function (hash, signature) { + return ecdsa.verify(hash, signature, this.Q) +} + +module.exports = ECPair + + +/***/ }), +/* 114 */ +/***/ (function(module, exports, __webpack_require__) { + +var Buffer = __webpack_require__(7).Buffer +var bs58check = __webpack_require__(33) +var bscript = __webpack_require__(14) +var networks = __webpack_require__(54) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) + +function fromBase58Check (address) { + var payload = bs58check.decode(address) + if (payload.length < 21) throw new TypeError(address + ' is too short') + if (payload.length > 21) throw new TypeError(address + ' is too long') + + var version = payload.readUInt8(0) + var hash = payload.slice(1) + + return { hash: hash, version: version } +} + +function toBase58Check (hash, version) { + typeforce(types.tuple(types.Hash160bit, types.UInt8), arguments) + + var payload = Buffer.allocUnsafe(21) + payload.writeUInt8(version, 0) + hash.copy(payload, 1) + + return bs58check.encode(payload) +} + +function fromOutputScript (outputScript, network) { + network = network || networks.bitcoin + + if (bscript.pubKeyHash.output.check(outputScript)) return toBase58Check(bscript.compile(outputScript).slice(3, 23), network.pubKeyHash) + if (bscript.scriptHash.output.check(outputScript)) return toBase58Check(bscript.compile(outputScript).slice(2, 22), network.scriptHash) + + throw new Error(bscript.toASM(outputScript) + ' has no matching Address') +} + +function toOutputScript (address, network) { + network = network || networks.bitcoin + + var decode = fromBase58Check(address) + if (decode.version === network.pubKeyHash) return bscript.pubKeyHash.output.encode(decode.hash) + if (decode.version === network.scriptHash) return bscript.scriptHash.output.encode(decode.hash) + + throw new Error(address + ' has no matching Script') +} + +module.exports = { + fromBase58Check: fromBase58Check, + fromOutputScript: fromOutputScript, + toBase58Check: toBase58Check, + toOutputScript: toOutputScript +} + + +/***/ }), +/* 115 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var bip66 = __webpack_require__(104) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) + +var BigInteger = __webpack_require__(30) + +function ECSignature (r, s) { + typeforce(types.tuple(types.BigInt, types.BigInt), arguments) + + this.r = r + this.s = s +} + +ECSignature.parseCompact = function (buffer) { + if (buffer.length !== 65) throw new Error('Invalid signature length') + + var flagByte = buffer.readUInt8(0) - 27 + if (flagByte !== (flagByte & 7)) throw new Error('Invalid signature parameter') + + var compressed = !!(flagByte & 4) + var recoveryParam = flagByte & 3 + + var r = BigInteger.fromBuffer(buffer.slice(1, 33)) + var s = BigInteger.fromBuffer(buffer.slice(33)) + + return { + compressed: compressed, + i: recoveryParam, + signature: new ECSignature(r, s) + } +} + +ECSignature.fromDER = function (buffer) { + var decode = bip66.decode(buffer) + var r = BigInteger.fromDERInteger(decode.r) + var s = BigInteger.fromDERInteger(decode.s) + + return new ECSignature(r, s) +} + +// BIP62: 1 byte hashType flag (only 0x01, 0x02, 0x03, 0x81, 0x82 and 0x83 are allowed) +ECSignature.parseScriptSignature = function (buffer) { + var hashType = buffer.readUInt8(buffer.length - 1) + var hashTypeMod = hashType & ~0x80 + + if (hashTypeMod <= 0x00 || hashTypeMod >= 0x04) throw new Error('Invalid hashType ' + hashType) + + return { + signature: ECSignature.fromDER(buffer.slice(0, -1)), + hashType: hashType + } +} + +ECSignature.prototype.toCompact = function (i, compressed) { + if (compressed) { + i += 4 + } + + i += 27 + + var buffer = Buffer.alloc(65) + buffer.writeUInt8(i, 0) + this.r.toBuffer(32).copy(buffer, 1) + this.s.toBuffer(32).copy(buffer, 33) + + return buffer +} + +ECSignature.prototype.toDER = function () { + var r = Buffer.from(this.r.toDERInteger()) + var s = Buffer.from(this.s.toDERInteger()) + + return bip66.encode(r, s) +} + +ECSignature.prototype.toScriptSignature = function (hashType) { + var hashTypeMod = hashType & ~0x80 + if (hashTypeMod <= 0 || hashTypeMod >= 4) throw new Error('Invalid hashType ' + hashType) + + var hashTypeBuffer = Buffer.alloc(1) + hashTypeBuffer.writeUInt8(hashType, 0) + + return Buffer.concat([this.toDER(), hashTypeBuffer]) +} + +module.exports = ECSignature + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 116 */ +/***/ (function(module, exports, __webpack_require__) { + +var Point = __webpack_require__(207) +var Curve = __webpack_require__(208) + +var getCurveByName = __webpack_require__(490) + +module.exports = { + Curve: Curve, + Point: Point, + getCurveByName: getCurveByName +} + + +/***/ }), +/* 117 */ +/***/ (function(module, exports) { + +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ +// css base code, injected by the css-loader +module.exports = function(useSourceMap) { + var list = []; + + // return the list of modules as css string + list.toString = function toString() { + return this.map(function (item) { + var content = cssWithMappingToString(item, useSourceMap); + if(item[2]) { + return "@media " + item[2] + "{" + content + "}"; + } else { + return content; + } + }).join(""); + }; + + // import a list of modules into the list + list.i = function(modules, mediaQuery) { + if(typeof modules === "string") + modules = [[null, modules, ""]]; + var alreadyImportedModules = {}; + for(var i = 0; i < this.length; i++) { + var id = this[i][0]; + if(typeof id === "number") + alreadyImportedModules[id] = true; + } + for(i = 0; i < modules.length; i++) { + var item = modules[i]; + // skip already imported module + // this implementation is not 100% perfect for weird media query combinations + // when a module is imported multiple times with different media queries. + // I hope this will never occur (Hey this way we have smaller bundles) + if(typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) { + if(mediaQuery && !item[2]) { + item[2] = mediaQuery; + } else if(mediaQuery) { + item[2] = "(" + item[2] + ") and (" + mediaQuery + ")"; + } + list.push(item); + } + } + }; + return list; +}; + +function cssWithMappingToString(item, useSourceMap) { + var content = item[1] || ''; + var cssMapping = item[3]; + if (!cssMapping) { + return content; + } + + if (useSourceMap && typeof btoa === 'function') { + var sourceMapping = toComment(cssMapping); + var sourceURLs = cssMapping.sources.map(function (source) { + return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */' + }); + + return [content].concat(sourceURLs).concat([sourceMapping]).join('\n'); + } + + return [content].join('\n'); +} + +// Adapted from convert-source-map (MIT) +function toComment(sourceMap) { + // eslint-disable-next-line no-undef + var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))); + var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64; + + return '/*# ' + data + ' */'; +} + + +/***/ }), +/* 118 */ +/***/ (function(module, exports, __webpack_require__) { + +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ + +var stylesInDom = {}; + +var memoize = function (fn) { + var memo; + + return function () { + if (typeof memo === "undefined") memo = fn.apply(this, arguments); + return memo; + }; +}; + +var isOldIE = memoize(function () { + // Test for IE <= 9 as proposed by Browserhacks + // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805 + // Tests for existence of standard globals is to allow style-loader + // to operate correctly into non-standard environments + // @see https://github.com/webpack-contrib/style-loader/issues/177 + return window && document && document.all && !window.atob; +}); + +var getElement = (function (fn) { + var memo = {}; + + return function(selector) { + if (typeof memo[selector] === "undefined") { + memo[selector] = fn.call(this, selector); + } + + return memo[selector] + }; +})(function (target) { + return document.querySelector(target) +}); + +var singleton = null; +var singletonCounter = 0; +var stylesInsertedAtTop = []; + +var fixUrls = __webpack_require__(213); + +module.exports = function(list, options) { + if (typeof DEBUG !== "undefined" && DEBUG) { + if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment"); + } + + options = options || {}; + + options.attrs = typeof options.attrs === "object" ? options.attrs : {}; + + // Force single-tag solution on IE6-9, which has a hard limit on the # of <style> + // tags it will allow on a page + if (!options.singleton) options.singleton = isOldIE(); + + // By default, add <style> tags to the <head> element + if (!options.insertInto) options.insertInto = "head"; + + // By default, add <style> tags to the bottom of the target + if (!options.insertAt) options.insertAt = "bottom"; + + var styles = listToStyles(list, options); + + addStylesToDom(styles, options); + + return function update (newList) { + var mayRemove = []; + + for (var i = 0; i < styles.length; i++) { + var item = styles[i]; + var domStyle = stylesInDom[item.id]; + + domStyle.refs--; + mayRemove.push(domStyle); + } + + if(newList) { + var newStyles = listToStyles(newList, options); + addStylesToDom(newStyles, options); + } + + for (var i = 0; i < mayRemove.length; i++) { + var domStyle = mayRemove[i]; + + if(domStyle.refs === 0) { + for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](); + + delete stylesInDom[domStyle.id]; + } + } + }; +}; + +function addStylesToDom (styles, options) { + for (var i = 0; i < styles.length; i++) { + var item = styles[i]; + var domStyle = stylesInDom[item.id]; + + if(domStyle) { + domStyle.refs++; + + for(var j = 0; j < domStyle.parts.length; j++) { + domStyle.parts[j](item.parts[j]); + } + + for(; j < item.parts.length; j++) { + domStyle.parts.push(addStyle(item.parts[j], options)); + } + } else { + var parts = []; + + for(var j = 0; j < item.parts.length; j++) { + parts.push(addStyle(item.parts[j], options)); + } + + stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts}; + } + } +} + +function listToStyles (list, options) { + var styles = []; + var newStyles = {}; + + for (var i = 0; i < list.length; i++) { + var item = list[i]; + var id = options.base ? item[0] + options.base : item[0]; + var css = item[1]; + var media = item[2]; + var sourceMap = item[3]; + var part = {css: css, media: media, sourceMap: sourceMap}; + + if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]}); + else newStyles[id].parts.push(part); + } + + return styles; +} + +function insertStyleElement (options, style) { + var target = getElement(options.insertInto) + + if (!target) { + throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid."); + } + + var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1]; + + if (options.insertAt === "top") { + if (!lastStyleElementInsertedAtTop) { + target.insertBefore(style, target.firstChild); + } else if (lastStyleElementInsertedAtTop.nextSibling) { + target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling); + } else { + target.appendChild(style); + } + stylesInsertedAtTop.push(style); + } else if (options.insertAt === "bottom") { + target.appendChild(style); + } else { + throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'."); + } +} + +function removeStyleElement (style) { + if (style.parentNode === null) return false; + style.parentNode.removeChild(style); + + var idx = stylesInsertedAtTop.indexOf(style); + if(idx >= 0) { + stylesInsertedAtTop.splice(idx, 1); + } +} + +function createStyleElement (options) { + var style = document.createElement("style"); + + options.attrs.type = "text/css"; + + addAttrs(style, options.attrs); + insertStyleElement(options, style); + + return style; +} + +function createLinkElement (options) { + var link = document.createElement("link"); + + options.attrs.type = "text/css"; + options.attrs.rel = "stylesheet"; + + addAttrs(link, options.attrs); + insertStyleElement(options, link); + + return link; +} + +function addAttrs (el, attrs) { + Object.keys(attrs).forEach(function (key) { + el.setAttribute(key, attrs[key]); + }); +} + +function addStyle (obj, options) { + var style, update, remove, result; + + // If a transform function was defined, run it on the css + if (options.transform && obj.css) { + result = options.transform(obj.css); + + if (result) { + // If transform returns a value, use that instead of the original css. + // This allows running runtime transformations on the css. + obj.css = result; + } else { + // If the transform function returns a falsy value, don't add this css. + // This allows conditional loading of css + return function() { + // noop + }; + } + } + + if (options.singleton) { + var styleIndex = singletonCounter++; + + style = singleton || (singleton = createStyleElement(options)); + + update = applyToSingletonTag.bind(null, style, styleIndex, false); + remove = applyToSingletonTag.bind(null, style, styleIndex, true); + + } else if ( + obj.sourceMap && + typeof URL === "function" && + typeof URL.createObjectURL === "function" && + typeof URL.revokeObjectURL === "function" && + typeof Blob === "function" && + typeof btoa === "function" + ) { + style = createLinkElement(options); + update = updateLink.bind(null, style, options); + remove = function () { + removeStyleElement(style); + + if(style.href) URL.revokeObjectURL(style.href); + }; + } else { + style = createStyleElement(options); + update = applyToTag.bind(null, style); + remove = function () { + removeStyleElement(style); + }; + } + + update(obj); + + return function updateStyle (newObj) { + if (newObj) { + if ( + newObj.css === obj.css && + newObj.media === obj.media && + newObj.sourceMap === obj.sourceMap + ) { + return; + } + + update(obj = newObj); + } else { + remove(); + } + }; +} + +var replaceText = (function () { + var textStore = []; + + return function (index, replacement) { + textStore[index] = replacement; + + return textStore.filter(Boolean).join('\n'); + }; +})(); + +function applyToSingletonTag (style, index, remove, obj) { + var css = remove ? "" : obj.css; + + if (style.styleSheet) { + style.styleSheet.cssText = replaceText(index, css); + } else { + var cssNode = document.createTextNode(css); + var childNodes = style.childNodes; + + if (childNodes[index]) style.removeChild(childNodes[index]); + + if (childNodes.length) { + style.insertBefore(cssNode, childNodes[index]); + } else { + style.appendChild(cssNode); + } + } +} + +function applyToTag (style, obj) { + var css = obj.css; + var media = obj.media; + + if(media) { + style.setAttribute("media", media) + } + + if(style.styleSheet) { + style.styleSheet.cssText = css; + } else { + while(style.firstChild) { + style.removeChild(style.firstChild); + } + + style.appendChild(document.createTextNode(css)); + } +} + +function updateLink (link, options, obj) { + var css = obj.css; + var sourceMap = obj.sourceMap; + + /* + If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled + and there is no publicPath defined then lets turn convertToAbsoluteUrls + on by default. Otherwise default to the convertToAbsoluteUrls option + directly + */ + var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap; + + if (options.convertToAbsoluteUrls || autoFixUrls) { + css = fixUrls(css); + } + + if (sourceMap) { + // http://stackoverflow.com/a/26603875 + css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */"; + } + + var blob = new Blob([css], { type: "text/css" }); + + var oldSrc = link.href; + + link.href = URL.createObjectURL(blob); + + if(oldSrc) URL.revokeObjectURL(oldSrc); +} + + +/***/ }), +/* 119 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(37), + _assign = __webpack_require__(8); + +var ReactNoopUpdateQueue = __webpack_require__(120); + +var canDefineProperty = __webpack_require__(55); +var emptyObject = __webpack_require__(56); +var invariant = __webpack_require__(2); +var lowPriorityWarning = __webpack_require__(74); + +/** + * Base class helpers for the updating state of a component. + */ +function ReactComponent(props, context, updater) { + this.props = props; + this.context = context; + this.refs = emptyObject; + // We initialize the default updater but the real one gets injected by the + // renderer. + this.updater = updater || ReactNoopUpdateQueue; +} + +ReactComponent.prototype.isReactComponent = {}; + +/** + * Sets a subset of the state. Always use this to mutate + * state. You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * There is no guarantee that calls to `setState` will run synchronously, + * as they may eventually be batched together. You can provide an optional + * callback that will be executed when the call to setState is actually + * completed. + * + * When a function is provided to setState, it will be called at some point in + * the future (not synchronously). It will be called with the up to date + * component arguments (state, props, context). These values can be different + * from this.* because your function may be called after receiveProps but before + * shouldComponentUpdate, and this new state, props, and context will not yet be + * assigned to this. + * + * @param {object|function} partialState Next partial state or function to + * produce next partial state to be merged with current state. + * @param {?function} callback Called after state is updated. + * @final + * @protected + */ +ReactComponent.prototype.setState = function (partialState, callback) { + !(typeof partialState === 'object' || typeof partialState === 'function' || partialState == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.') : _prodInvariant('85') : void 0; + this.updater.enqueueSetState(this, partialState); + if (callback) { + this.updater.enqueueCallback(this, callback, 'setState'); + } +}; + +/** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {?function} callback Called after update is complete. + * @final + * @protected + */ +ReactComponent.prototype.forceUpdate = function (callback) { + this.updater.enqueueForceUpdate(this); + if (callback) { + this.updater.enqueueCallback(this, callback, 'forceUpdate'); + } +}; + +/** + * Deprecated APIs. These APIs used to exist on classic React classes but since + * we would like to deprecate them, we're not going to move them over to this + * modern base class. Instead, we define a getter that warns if it's accessed. + */ +if (process.env.NODE_ENV !== 'production') { + var deprecatedAPIs = { + isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'], + replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).'] + }; + var defineDeprecationWarning = function (methodName, info) { + if (canDefineProperty) { + Object.defineProperty(ReactComponent.prototype, methodName, { + get: function () { + lowPriorityWarning(false, '%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]); + return undefined; + } + }); + } + }; + for (var fnName in deprecatedAPIs) { + if (deprecatedAPIs.hasOwnProperty(fnName)) { + defineDeprecationWarning(fnName, deprecatedAPIs[fnName]); + } + } +} + +/** + * Base class helpers for the updating state of a component. + */ +function ReactPureComponent(props, context, updater) { + // Duplicated from ReactComponent. + this.props = props; + this.context = context; + this.refs = emptyObject; + // We initialize the default updater but the real one gets injected by the + // renderer. + this.updater = updater || ReactNoopUpdateQueue; +} + +function ComponentDummy() {} +ComponentDummy.prototype = ReactComponent.prototype; +ReactPureComponent.prototype = new ComponentDummy(); +ReactPureComponent.prototype.constructor = ReactPureComponent; +// Avoid an extra prototype jump for these methods. +_assign(ReactPureComponent.prototype, ReactComponent.prototype); +ReactPureComponent.prototype.isPureReactComponent = true; + +module.exports = { + Component: ReactComponent, + PureComponent: ReactPureComponent +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 120 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var warning = __webpack_require__(3); + +function warnNoop(publicInstance, callerName) { + if (process.env.NODE_ENV !== 'production') { + var constructor = publicInstance.constructor; + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; + } +} + +/** + * This is the abstract API for an update queue. + */ +var ReactNoopUpdateQueue = { + /** + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + isMounted: function (publicInstance) { + return false; + }, + + /** + * Enqueue a callback that will be executed after all the pending updates + * have processed. + * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @internal + */ + enqueueCallback: function (publicInstance, callback) {}, + + /** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal + */ + enqueueForceUpdate: function (publicInstance) { + warnNoop(publicInstance, 'forceUpdate'); + }, + + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} completeState Next state. + * @internal + */ + enqueueReplaceState: function (publicInstance, completeState) { + warnNoop(publicInstance, 'replaceState'); + }, + + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} partialState Next partial state to be merged with state. + * @internal + */ + enqueueSetState: function (publicInstance, partialState) { + warnNoop(publicInstance, 'setState'); + } +}; + +module.exports = ReactNoopUpdateQueue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 121 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +// The Symbol used to tag the ReactElement type. If there is no native Symbol +// nor polyfill, then a plain number is used for performance. + +var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; + +module.exports = REACT_ELEMENT_TYPE; + +/***/ }), +/* 122 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/* global Symbol */ + +var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; +var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. + +/** + * Returns the iterator method function contained on the iterable object. + * + * Be sure to invoke the function with the iterable as context: + * + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} + */ +function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } +} + +module.exports = getIteratorFn; + +/***/ }), +/* 123 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/** + * ReactElementValidator provides a wrapper around a element factory + * which validates the props passed to the element. This is intended to be + * used only in DEV and could be replaced by a static type checker for languages + * that support it. + */ + + + +var ReactCurrentOwner = __webpack_require__(22); +var ReactComponentTreeHook = __webpack_require__(17); +var ReactElement = __webpack_require__(31); + +var checkReactTypeSpec = __webpack_require__(221); + +var canDefineProperty = __webpack_require__(55); +var getIteratorFn = __webpack_require__(122); +var warning = __webpack_require__(3); +var lowPriorityWarning = __webpack_require__(74); + +function getDeclarationErrorAddendum() { + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} + +function getSourceInfoErrorAddendum(elementProps) { + if (elementProps !== null && elementProps !== undefined && elementProps.__source !== undefined) { + var source = elementProps.__source; + var fileName = source.fileName.replace(/^.*[\\\/]/, ''); + var lineNumber = source.lineNumber; + return ' Check your code at ' + fileName + ':' + lineNumber + '.'; + } + return ''; +} + +/** + * Warn if there's no key explicitly set on dynamic arrays of children or + * object keys are not valid. This allows us to keep track of children between + * updates. + */ +var ownerHasKeyUseWarning = {}; + +function getCurrentComponentErrorInfo(parentType) { + var info = getDeclarationErrorAddendum(); + + if (!info) { + var parentName = typeof parentType === 'string' ? parentType : parentType.displayName || parentType.name; + if (parentName) { + info = ' Check the top-level render call using <' + parentName + '>.'; + } + } + return info; +} + +/** + * Warn if the element doesn't have an explicit key assigned to it. + * This element is in an array. The array could grow and shrink or be + * reordered. All children that haven't already been validated are required to + * have a "key" property assigned to it. Error statuses are cached so a warning + * will only be shown once. + * + * @internal + * @param {ReactElement} element Element that requires a key. + * @param {*} parentType element's parent's type. + */ +function validateExplicitKey(element, parentType) { + if (!element._store || element._store.validated || element.key != null) { + return; + } + element._store.validated = true; + + var memoizer = ownerHasKeyUseWarning.uniqueKey || (ownerHasKeyUseWarning.uniqueKey = {}); + + var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType); + if (memoizer[currentComponentErrorInfo]) { + return; + } + memoizer[currentComponentErrorInfo] = true; + + // Usually the current owner is the offender, but if it accepts children as a + // property, it may be the creator of the child that's responsible for + // assigning it a key. + var childOwner = ''; + if (element && element._owner && element._owner !== ReactCurrentOwner.current) { + // Give the component that originally created this child. + childOwner = ' It was passed a child from ' + element._owner.getName() + '.'; + } + + process.env.NODE_ENV !== 'production' ? warning(false, 'Each child in an array or iterator should have a unique "key" prop.' + '%s%s See https://fb.me/react-warning-keys for more information.%s', currentComponentErrorInfo, childOwner, ReactComponentTreeHook.getCurrentStackAddendum(element)) : void 0; +} + +/** + * Ensure that every element either is passed in a static location, in an + * array with an explicit keys property defined, or in an object literal + * with valid key property. + * + * @internal + * @param {ReactNode} node Statically passed child of any type. + * @param {*} parentType node's parent's type. + */ +function validateChildKeys(node, parentType) { + if (typeof node !== 'object') { + return; + } + if (Array.isArray(node)) { + for (var i = 0; i < node.length; i++) { + var child = node[i]; + if (ReactElement.isValidElement(child)) { + validateExplicitKey(child, parentType); + } + } + } else if (ReactElement.isValidElement(node)) { + // This element was passed in a valid location. + if (node._store) { + node._store.validated = true; + } + } else if (node) { + var iteratorFn = getIteratorFn(node); + // Entry iterators provide implicit keys. + if (iteratorFn) { + if (iteratorFn !== node.entries) { + var iterator = iteratorFn.call(node); + var step; + while (!(step = iterator.next()).done) { + if (ReactElement.isValidElement(step.value)) { + validateExplicitKey(step.value, parentType); + } + } + } + } + } +} + +/** + * Given an element, validate that its props follow the propTypes definition, + * provided by the type. + * + * @param {ReactElement} element + */ +function validatePropTypes(element) { + var componentClass = element.type; + if (typeof componentClass !== 'function') { + return; + } + var name = componentClass.displayName || componentClass.name; + if (componentClass.propTypes) { + checkReactTypeSpec(componentClass.propTypes, element.props, 'prop', name, element, null); + } + if (typeof componentClass.getDefaultProps === 'function') { + process.env.NODE_ENV !== 'production' ? warning(componentClass.getDefaultProps.isReactClassApproved, 'getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.') : void 0; + } +} + +var ReactElementValidator = { + createElement: function (type, props, children) { + var validType = typeof type === 'string' || typeof type === 'function'; + // We warn in this case but don't throw. We expect the element creation to + // succeed and there will likely be errors in render. + if (!validType) { + if (typeof type !== 'function' && typeof type !== 'string') { + var info = ''; + if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { + info += ' You likely forgot to export your component from the file ' + "it's defined in."; + } + + var sourceInfo = getSourceInfoErrorAddendum(props); + if (sourceInfo) { + info += sourceInfo; + } else { + info += getDeclarationErrorAddendum(); + } + + info += ReactComponentTreeHook.getCurrentStackAddendum(); + + var currentSource = props !== null && props !== undefined && props.__source !== undefined ? props.__source : null; + ReactComponentTreeHook.pushNonStandardWarningStack(true, currentSource); + process.env.NODE_ENV !== 'production' ? warning(false, 'React.createElement: type is invalid -- expected a string (for ' + 'built-in components) or a class/function (for composite ' + 'components) but got: %s.%s', type == null ? type : typeof type, info) : void 0; + ReactComponentTreeHook.popNonStandardWarningStack(); + } + } + + var element = ReactElement.createElement.apply(this, arguments); + + // The result can be nullish if a mock or a custom function is used. + // TODO: Drop this when these are no longer allowed as the type argument. + if (element == null) { + return element; + } + + // Skip key warning if the type isn't valid since our key validation logic + // doesn't expect a non-string/function type and can throw confusing errors. + // We don't want exception behavior to differ between dev and prod. + // (Rendering will throw with a helpful message and as soon as the type is + // fixed, the key warnings will appear.) + if (validType) { + for (var i = 2; i < arguments.length; i++) { + validateChildKeys(arguments[i], type); + } + } + + validatePropTypes(element); + + return element; + }, + + createFactory: function (type) { + var validatedFactory = ReactElementValidator.createElement.bind(null, type); + // Legacy hook TODO: Warn if this is accessed + validatedFactory.type = type; + + if (process.env.NODE_ENV !== 'production') { + if (canDefineProperty) { + Object.defineProperty(validatedFactory, 'type', { + enumerable: false, + get: function () { + lowPriorityWarning(false, 'Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.'); + Object.defineProperty(this, 'type', { + value: type + }); + return type; + } + }); + } + } + + return validatedFactory; + }, + + cloneElement: function (element, props, children) { + var newElement = ReactElement.cloneElement.apply(this, arguments); + for (var i = 2; i < arguments.length; i++) { + validateChildKeys(arguments[i], newElement.type); + } + validatePropTypes(newElement); + return newElement; + } +}; + +module.exports = ReactElementValidator; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 124 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +// React 15.5 references this module, and assumes PropTypes are still callable in production. +// Therefore we re-export development-only version with all the PropTypes checks here. +// However if one is migrating to the `prop-types` npm library, they will go through the +// `index.js` entry point, and it will branch depending on the environment. +var factory = __webpack_require__(125); +module.exports = function(isValidElement) { + // It is still allowed in 15.5. + var throwOnDirectAccess = false; + return factory(isValidElement, throwOnDirectAccess); +}; + + +/***/ }), +/* 125 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var ReactPropTypesSecret = __webpack_require__(75); +var checkPropTypes = __webpack_require__(225); + +module.exports = function(isValidElement, throwOnDirectAccess) { + /* global Symbol */ + var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; + var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. + + /** + * Returns the iterator method function contained on the iterable object. + * + * Be sure to invoke the function with the iterable as context: + * + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} + */ + function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } + } + + /** + * Collection of methods that allow declaration and validation of props that are + * supplied to React components. Example usage: + * + * var Props = require('ReactPropTypes'); + * var MyArticle = React.createClass({ + * propTypes: { + * // An optional string prop named "description". + * description: Props.string, + * + * // A required enum prop named "category". + * category: Props.oneOf(['News','Photos']).isRequired, + * + * // A prop named "dialog" that requires an instance of Dialog. + * dialog: Props.instanceOf(Dialog).isRequired + * }, + * render: function() { ... } + * }); + * + * A more formal specification of how these methods are used: + * + * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...) + * decl := ReactPropTypes.{type}(.isRequired)? + * + * Each and every declaration produces a function with the same signature. This + * allows the creation of custom validation functions. For example: + * + * var MyLink = React.createClass({ + * propTypes: { + * // An optional string or URI prop named "href". + * href: function(props, propName, componentName) { + * var propValue = props[propName]; + * if (propValue != null && typeof propValue !== 'string' && + * !(propValue instanceof URI)) { + * return new Error( + * 'Expected a string or an URI for ' + propName + ' in ' + + * componentName + * ); + * } + * } + * }, + * render: function() {...} + * }); + * + * @internal + */ + + var ANONYMOUS = '<<anonymous>>'; + + // Important! + // Keep this list in sync with production version in `./factoryWithThrowingShims.js`. + var ReactPropTypes = { + array: createPrimitiveTypeChecker('array'), + bool: createPrimitiveTypeChecker('boolean'), + func: createPrimitiveTypeChecker('function'), + number: createPrimitiveTypeChecker('number'), + object: createPrimitiveTypeChecker('object'), + string: createPrimitiveTypeChecker('string'), + symbol: createPrimitiveTypeChecker('symbol'), + + any: createAnyTypeChecker(), + arrayOf: createArrayOfTypeChecker, + element: createElementTypeChecker(), + instanceOf: createInstanceTypeChecker, + node: createNodeChecker(), + objectOf: createObjectOfTypeChecker, + oneOf: createEnumTypeChecker, + oneOfType: createUnionTypeChecker, + shape: createShapeTypeChecker + }; + + /** + * inlined Object.is polyfill to avoid requiring consumers ship their own + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is + */ + /*eslint-disable no-self-compare*/ + function is(x, y) { + // SameValue algorithm + if (x === y) { + // Steps 1-5, 7-10 + // Steps 6.b-6.e: +0 != -0 + return x !== 0 || 1 / x === 1 / y; + } else { + // Step 6.a: NaN == NaN + return x !== x && y !== y; + } + } + /*eslint-enable no-self-compare*/ + + /** + * We use an Error-like object for backward compatibility as people may call + * PropTypes directly and inspect their output. However, we don't use real + * Errors anymore. We don't inspect their stack anyway, and creating them + * is prohibitively expensive if they are created too often, such as what + * happens in oneOfType() for any type before the one that matched. + */ + function PropTypeError(message) { + this.message = message; + this.stack = ''; + } + // Make `instanceof Error` still work for returned errors. + PropTypeError.prototype = Error.prototype; + + function createChainableTypeChecker(validate) { + if (process.env.NODE_ENV !== 'production') { + var manualPropTypeCallCache = {}; + var manualPropTypeWarningCount = 0; + } + function checkType(isRequired, props, propName, componentName, location, propFullName, secret) { + componentName = componentName || ANONYMOUS; + propFullName = propFullName || propName; + + if (secret !== ReactPropTypesSecret) { + if (throwOnDirectAccess) { + // New behavior only for users of `prop-types` package + invariant( + false, + 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + + 'Use `PropTypes.checkPropTypes()` to call them. ' + + 'Read more at http://fb.me/use-check-prop-types' + ); + } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') { + // Old behavior for people using React.PropTypes + var cacheKey = componentName + ':' + propName; + if ( + !manualPropTypeCallCache[cacheKey] && + // Avoid spamming the console because they are often not actionable except for lib authors + manualPropTypeWarningCount < 3 + ) { + warning( + false, + 'You are manually calling a React.PropTypes validation ' + + 'function for the `%s` prop on `%s`. This is deprecated ' + + 'and will throw in the standalone `prop-types` package. ' + + 'You may be seeing this warning due to a third-party PropTypes ' + + 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.', + propFullName, + componentName + ); + manualPropTypeCallCache[cacheKey] = true; + manualPropTypeWarningCount++; + } + } + } + if (props[propName] == null) { + if (isRequired) { + if (props[propName] === null) { + return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.')); + } + return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.')); + } + return null; + } else { + return validate(props, propName, componentName, location, propFullName); + } + } + + var chainedCheckType = checkType.bind(null, false); + chainedCheckType.isRequired = checkType.bind(null, true); + + return chainedCheckType; + } + + function createPrimitiveTypeChecker(expectedType) { + function validate(props, propName, componentName, location, propFullName, secret) { + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== expectedType) { + // `propValue` being instance of, say, date/regexp, pass the 'object' + // check, but we can offer a more precise error message here rather than + // 'of type `object`'. + var preciseType = getPreciseType(propValue); + + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.')); + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createAnyTypeChecker() { + return createChainableTypeChecker(emptyFunction.thatReturnsNull); + } + + function createArrayOfTypeChecker(typeChecker) { + function validate(props, propName, componentName, location, propFullName) { + if (typeof typeChecker !== 'function') { + return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.'); + } + var propValue = props[propName]; + if (!Array.isArray(propValue)) { + var propType = getPropType(propValue); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.')); + } + for (var i = 0; i < propValue.length; i++) { + var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret); + if (error instanceof Error) { + return error; + } + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createElementTypeChecker() { + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + if (!isValidElement(propValue)) { + var propType = getPropType(propValue); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.')); + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createInstanceTypeChecker(expectedClass) { + function validate(props, propName, componentName, location, propFullName) { + if (!(props[propName] instanceof expectedClass)) { + var expectedClassName = expectedClass.name || ANONYMOUS; + var actualClassName = getClassName(props[propName]); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.')); + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createEnumTypeChecker(expectedValues) { + if (!Array.isArray(expectedValues)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOf, expected an instance of array.') : void 0; + return emptyFunction.thatReturnsNull; + } + + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + for (var i = 0; i < expectedValues.length; i++) { + if (is(propValue, expectedValues[i])) { + return null; + } + } + + var valuesString = JSON.stringify(expectedValues); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + propValue + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.')); + } + return createChainableTypeChecker(validate); + } + + function createObjectOfTypeChecker(typeChecker) { + function validate(props, propName, componentName, location, propFullName) { + if (typeof typeChecker !== 'function') { + return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.'); + } + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== 'object') { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.')); + } + for (var key in propValue) { + if (propValue.hasOwnProperty(key)) { + var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); + if (error instanceof Error) { + return error; + } + } + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createUnionTypeChecker(arrayOfTypeCheckers) { + if (!Array.isArray(arrayOfTypeCheckers)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOfType, expected an instance of array.') : void 0; + return emptyFunction.thatReturnsNull; + } + + for (var i = 0; i < arrayOfTypeCheckers.length; i++) { + var checker = arrayOfTypeCheckers[i]; + if (typeof checker !== 'function') { + warning( + false, + 'Invalid argument supplid to oneOfType. Expected an array of check functions, but ' + + 'received %s at index %s.', + getPostfixForTypeWarning(checker), + i + ); + return emptyFunction.thatReturnsNull; + } + } + + function validate(props, propName, componentName, location, propFullName) { + for (var i = 0; i < arrayOfTypeCheckers.length; i++) { + var checker = arrayOfTypeCheckers[i]; + if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) { + return null; + } + } + + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.')); + } + return createChainableTypeChecker(validate); + } + + function createNodeChecker() { + function validate(props, propName, componentName, location, propFullName) { + if (!isNode(props[propName])) { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.')); + } + return null; + } + return createChainableTypeChecker(validate); + } + + function createShapeTypeChecker(shapeTypes) { + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== 'object') { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.')); + } + for (var key in shapeTypes) { + var checker = shapeTypes[key]; + if (!checker) { + continue; + } + var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); + if (error) { + return error; + } + } + return null; + } + return createChainableTypeChecker(validate); + } + + function isNode(propValue) { + switch (typeof propValue) { + case 'number': + case 'string': + case 'undefined': + return true; + case 'boolean': + return !propValue; + case 'object': + if (Array.isArray(propValue)) { + return propValue.every(isNode); + } + if (propValue === null || isValidElement(propValue)) { + return true; + } + + var iteratorFn = getIteratorFn(propValue); + if (iteratorFn) { + var iterator = iteratorFn.call(propValue); + var step; + if (iteratorFn !== propValue.entries) { + while (!(step = iterator.next()).done) { + if (!isNode(step.value)) { + return false; + } + } + } else { + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + if (!isNode(entry[1])) { + return false; + } + } + } + } + } else { + return false; + } + + return true; + default: + return false; + } + } + + function isSymbol(propType, propValue) { + // Native Symbol. + if (propType === 'symbol') { + return true; + } + + // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol' + if (propValue['@@toStringTag'] === 'Symbol') { + return true; + } + + // Fallback for non-spec compliant Symbols which are polyfilled. + if (typeof Symbol === 'function' && propValue instanceof Symbol) { + return true; + } + + return false; + } + + // Equivalent of `typeof` but with special handling for array and regexp. + function getPropType(propValue) { + var propType = typeof propValue; + if (Array.isArray(propValue)) { + return 'array'; + } + if (propValue instanceof RegExp) { + // Old webkits (at least until Android 4.0) return 'function' rather than + // 'object' for typeof a RegExp. We'll normalize this here so that /bla/ + // passes PropTypes.object. + return 'object'; + } + if (isSymbol(propType, propValue)) { + return 'symbol'; + } + return propType; + } + + // This handles more types than `getPropType`. Only used for error messages. + // See `createPrimitiveTypeChecker`. + function getPreciseType(propValue) { + if (typeof propValue === 'undefined' || propValue === null) { + return '' + propValue; + } + var propType = getPropType(propValue); + if (propType === 'object') { + if (propValue instanceof Date) { + return 'date'; + } else if (propValue instanceof RegExp) { + return 'regexp'; + } + } + return propType; + } + + // Returns a string that is postfixed to a warning about an invalid type. + // For example, "undefined" or "of type array" + function getPostfixForTypeWarning(value) { + var type = getPreciseType(value); + switch (type) { + case 'array': + case 'object': + return 'an ' + type; + case 'boolean': + case 'date': + case 'regexp': + return 'a ' + type; + default: + return type; + } + } + + // Returns class name of the object, if any. + function getClassName(propValue) { + if (!propValue.constructor || !propValue.constructor.name) { + return ANONYMOUS; + } + return propValue.constructor.name; + } + + ReactPropTypes.checkPropTypes = checkPropTypes; + ReactPropTypes.PropTypes = ReactPropTypes; + + return ReactPropTypes; +}; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 126 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMComponentFlags = { + hasCachedChildNodes: 1 << 0 +}; + +module.exports = ReactDOMComponentFlags; + +/***/ }), +/* 127 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +/** + * Accumulates items that must not be null or undefined into the first one. This + * is used to conserve memory by avoiding array allocations, and thus sacrifices + * API cleanness. Since `current` can be null before being passed in and not + * null after this function, make sure to assign it back to `current`: + * + * `a = accumulateInto(a, b);` + * + * This API should be sparingly used. Try `accumulate` for something cleaner. + * + * @return {*|array<*>} An accumulation of items. + */ + +function accumulateInto(current, next) { + !(next != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'accumulateInto(...): Accumulated items must not be null or undefined.') : _prodInvariant('30') : void 0; + + if (current == null) { + return next; + } + + // Both are not empty. Warning: Never call x.concat(y) when you are not + // certain that x is an Array (x could be a string with concat method). + if (Array.isArray(current)) { + if (Array.isArray(next)) { + current.push.apply(current, next); + return current; + } + current.push(next); + return current; + } + + if (Array.isArray(next)) { + // A bit too dangerous to mutate `next`. + return [current].concat(next); + } + + return [current, next]; +} + +module.exports = accumulateInto; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 128 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/** + * @param {array} arr an "accumulation" of items which is either an Array or + * a single item. Useful when paired with the `accumulate` module. This is a + * simple utility that allows us to reason about a collection of items, but + * handling the case when there is exactly one item (and we do not need to + * allocate an array). + */ + +function forEachAccumulated(arr, cb, scope) { + if (Array.isArray(arr)) { + arr.forEach(cb, scope); + } else if (arr) { + cb.call(scope, arr); + } +} + +module.exports = forEachAccumulated; + +/***/ }), +/* 129 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +var contentKey = null; + +/** + * Gets the key used to access text content on a DOM node. + * + * @return {?string} Key used to access text content. + * @internal + */ +function getTextContentAccessor() { + if (!contentKey && ExecutionEnvironment.canUseDOM) { + // Prefer textContent to innerText because many browsers support both but + // SVG <text> elements don't support innerText even when <div> does. + contentKey = 'textContent' in document.documentElement ? 'textContent' : 'innerText'; + } + return contentKey; +} + +module.exports = getTextContentAccessor; + +/***/ }), +/* 130 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +var PooledClass = __webpack_require__(32); + +var invariant = __webpack_require__(2); + +/** + * A specialized pseudo-event module to help keep track of components waiting to + * be notified when their DOM representations are available for use. + * + * This implements `PooledClass`, so you should never need to instantiate this. + * Instead, use `CallbackQueue.getPooled()`. + * + * @class ReactMountReady + * @implements PooledClass + * @internal + */ + +var CallbackQueue = function () { + function CallbackQueue(arg) { + _classCallCheck(this, CallbackQueue); + + this._callbacks = null; + this._contexts = null; + this._arg = arg; + } + + /** + * Enqueues a callback to be invoked when `notifyAll` is invoked. + * + * @param {function} callback Invoked when `notifyAll` is invoked. + * @param {?object} context Context to call `callback` with. + * @internal + */ + + + CallbackQueue.prototype.enqueue = function enqueue(callback, context) { + this._callbacks = this._callbacks || []; + this._callbacks.push(callback); + this._contexts = this._contexts || []; + this._contexts.push(context); + }; + + /** + * Invokes all enqueued callbacks and clears the queue. This is invoked after + * the DOM representation of a component has been created or updated. + * + * @internal + */ + + + CallbackQueue.prototype.notifyAll = function notifyAll() { + var callbacks = this._callbacks; + var contexts = this._contexts; + var arg = this._arg; + if (callbacks && contexts) { + !(callbacks.length === contexts.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Mismatched list of contexts in callback queue') : _prodInvariant('24') : void 0; + this._callbacks = null; + this._contexts = null; + for (var i = 0; i < callbacks.length; i++) { + callbacks[i].call(contexts[i], arg); + } + callbacks.length = 0; + contexts.length = 0; + } + }; + + CallbackQueue.prototype.checkpoint = function checkpoint() { + return this._callbacks ? this._callbacks.length : 0; + }; + + CallbackQueue.prototype.rollback = function rollback(len) { + if (this._callbacks && this._contexts) { + this._callbacks.length = len; + this._contexts.length = len; + } + }; + + /** + * Resets the internal queue. + * + * @internal + */ + + + CallbackQueue.prototype.reset = function reset() { + this._callbacks = null; + this._contexts = null; + }; + + /** + * `PooledClass` looks for this. + */ + + + CallbackQueue.prototype.destructor = function destructor() { + this.reset(); + }; + + return CallbackQueue; +}(); + +module.exports = PooledClass.addPoolingTo(CallbackQueue); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 131 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactFeatureFlags = { + // When true, call console.time() before and .timeEnd() after each top-level + // render (both initial renders and updates). Useful when looking at prod-mode + // timeline profiles in Chrome, for example. + logTopLevelRenders: false +}; + +module.exports = ReactFeatureFlags; + +/***/ }), +/* 132 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMComponentTree = __webpack_require__(10); + +function isCheckable(elem) { + var type = elem.type; + var nodeName = elem.nodeName; + return nodeName && nodeName.toLowerCase() === 'input' && (type === 'checkbox' || type === 'radio'); +} + +function getTracker(inst) { + return inst._wrapperState.valueTracker; +} + +function attachTracker(inst, tracker) { + inst._wrapperState.valueTracker = tracker; +} + +function detachTracker(inst) { + delete inst._wrapperState.valueTracker; +} + +function getValueFromNode(node) { + var value; + if (node) { + value = isCheckable(node) ? '' + node.checked : node.value; + } + return value; +} + +var inputValueTracking = { + // exposed for testing + _getTrackerFromNode: function (node) { + return getTracker(ReactDOMComponentTree.getInstanceFromNode(node)); + }, + + + track: function (inst) { + if (getTracker(inst)) { + return; + } + + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var valueField = isCheckable(node) ? 'checked' : 'value'; + var descriptor = Object.getOwnPropertyDescriptor(node.constructor.prototype, valueField); + + var currentValue = '' + node[valueField]; + + // if someone has already defined a value or Safari, then bail + // and don't track value will cause over reporting of changes, + // but it's better then a hard failure + // (needed for certain tests that spyOn input values and Safari) + if (node.hasOwnProperty(valueField) || typeof descriptor.get !== 'function' || typeof descriptor.set !== 'function') { + return; + } + + Object.defineProperty(node, valueField, { + enumerable: descriptor.enumerable, + configurable: true, + get: function () { + return descriptor.get.call(this); + }, + set: function (value) { + currentValue = '' + value; + descriptor.set.call(this, value); + } + }); + + attachTracker(inst, { + getValue: function () { + return currentValue; + }, + setValue: function (value) { + currentValue = '' + value; + }, + stopTracking: function () { + detachTracker(inst); + delete node[valueField]; + } + }); + }, + + updateValueIfChanged: function (inst) { + if (!inst) { + return false; + } + var tracker = getTracker(inst); + + if (!tracker) { + inputValueTracking.track(inst); + return true; + } + + var lastValue = tracker.getValue(); + var nextValue = getValueFromNode(ReactDOMComponentTree.getNodeFromInstance(inst)); + + if (nextValue !== lastValue) { + tracker.setValue(nextValue); + return true; + } + + return false; + }, + stopTracking: function (inst) { + var tracker = getTracker(inst); + if (tracker) { + tracker.stopTracking(); + } + } +}; + +module.exports = inputValueTracking; + +/***/ }), +/* 133 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/** + * @see http://www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#input-type-attr-summary + */ + +var supportedInputTypes = { + color: true, + date: true, + datetime: true, + 'datetime-local': true, + email: true, + month: true, + number: true, + password: true, + range: true, + search: true, + tel: true, + text: true, + time: true, + url: true, + week: true +}; + +function isTextInputElement(elem) { + var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); + + if (nodeName === 'input') { + return !!supportedInputTypes[elem.type]; + } + + if (nodeName === 'textarea') { + return true; + } + + return false; +} + +module.exports = isTextInputElement; + +/***/ }), +/* 134 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ViewportMetrics = { + currentScrollLeft: 0, + + currentScrollTop: 0, + + refreshScrollValues: function (scrollPosition) { + ViewportMetrics.currentScrollLeft = scrollPosition.x; + ViewportMetrics.currentScrollTop = scrollPosition.y; + } +}; + +module.exports = ViewportMetrics; + +/***/ }), +/* 135 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); +var escapeTextContentForBrowser = __webpack_require__(61); +var setInnerHTML = __webpack_require__(60); + +/** + * Set the textContent property of a node, ensuring that whitespace is preserved + * even in IE8. innerText is a poor substitute for textContent and, among many + * issues, inserts <br> instead of the literal newline chars. innerHTML behaves + * as it should. + * + * @param {DOMElement} node + * @param {string} text + * @internal + */ +var setTextContent = function (node, text) { + if (text) { + var firstChild = node.firstChild; + + if (firstChild && firstChild === node.lastChild && firstChild.nodeType === 3) { + firstChild.nodeValue = text; + return; + } + } + node.textContent = text; +}; + +if (ExecutionEnvironment.canUseDOM) { + if (!('textContent' in document.documentElement)) { + setTextContent = function (node, text) { + if (node.nodeType === 3) { + node.nodeValue = text; + return; + } + setInnerHTML(node, escapeTextContentForBrowser(text)); + }; + } +} + +module.exports = setTextContent; + +/***/ }), +/* 136 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * @param {DOMElement} node input/textarea to focus + */ + +function focusNode(node) { + // IE8 can throw "Can't move focus to the control because it is invisible, + // not enabled, or of a type that does not accept the focus." for all kinds of + // reasons that are too expensive and fragile to test. + try { + node.focus(); + } catch (e) {} +} + +module.exports = focusNode; + +/***/ }), +/* 137 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * CSS properties which accept numbers but are not in units of "px". + */ + +var isUnitlessNumber = { + animationIterationCount: true, + borderImageOutset: true, + borderImageSlice: true, + borderImageWidth: true, + boxFlex: true, + boxFlexGroup: true, + boxOrdinalGroup: true, + columnCount: true, + flex: true, + flexGrow: true, + flexPositive: true, + flexShrink: true, + flexNegative: true, + flexOrder: true, + gridRow: true, + gridRowEnd: true, + gridRowSpan: true, + gridRowStart: true, + gridColumn: true, + gridColumnEnd: true, + gridColumnSpan: true, + gridColumnStart: true, + fontWeight: true, + lineClamp: true, + lineHeight: true, + opacity: true, + order: true, + orphans: true, + tabSize: true, + widows: true, + zIndex: true, + zoom: true, + + // SVG-related properties + fillOpacity: true, + floodOpacity: true, + stopOpacity: true, + strokeDasharray: true, + strokeDashoffset: true, + strokeMiterlimit: true, + strokeOpacity: true, + strokeWidth: true +}; + +/** + * @param {string} prefix vendor-specific prefix, eg: Webkit + * @param {string} key style name, eg: transitionDuration + * @return {string} style name prefixed with `prefix`, properly camelCased, eg: + * WebkitTransitionDuration + */ +function prefixKey(prefix, key) { + return prefix + key.charAt(0).toUpperCase() + key.substring(1); +} + +/** + * Support style names that may come passed in prefixed by adding permutations + * of vendor prefixes. + */ +var prefixes = ['Webkit', 'ms', 'Moz', 'O']; + +// Using Object.keys here, or else the vanilla for-in loop makes IE8 go into an +// infinite loop, because it iterates over the newly added props too. +Object.keys(isUnitlessNumber).forEach(function (prop) { + prefixes.forEach(function (prefix) { + isUnitlessNumber[prefixKey(prefix, prop)] = isUnitlessNumber[prop]; + }); +}); + +/** + * Most style properties can be unset by doing .style[prop] = '' but IE8 + * doesn't like doing that with shorthand properties so for the properties that + * IE8 breaks on, which are listed here, we instead unset each of the + * individual properties. See http://bugs.jquery.com/ticket/12385. + * The 4-value 'clock' properties like margin, padding, border-width seem to + * behave without any problems. Curiously, list-style works too without any + * special prodding. + */ +var shorthandPropertyExpansions = { + background: { + backgroundAttachment: true, + backgroundColor: true, + backgroundImage: true, + backgroundPositionX: true, + backgroundPositionY: true, + backgroundRepeat: true + }, + backgroundPosition: { + backgroundPositionX: true, + backgroundPositionY: true + }, + border: { + borderWidth: true, + borderStyle: true, + borderColor: true + }, + borderBottom: { + borderBottomWidth: true, + borderBottomStyle: true, + borderBottomColor: true + }, + borderLeft: { + borderLeftWidth: true, + borderLeftStyle: true, + borderLeftColor: true + }, + borderRight: { + borderRightWidth: true, + borderRightStyle: true, + borderRightColor: true + }, + borderTop: { + borderTopWidth: true, + borderTopStyle: true, + borderTopColor: true + }, + font: { + fontStyle: true, + fontVariant: true, + fontWeight: true, + fontSize: true, + lineHeight: true, + fontFamily: true + }, + outline: { + outlineWidth: true, + outlineStyle: true, + outlineColor: true + } +}; + +var CSSProperty = { + isUnitlessNumber: isUnitlessNumber, + shorthandPropertyExpansions: shorthandPropertyExpansions +}; + +module.exports = CSSProperty; + +/***/ }), +/* 138 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstrumentation = __webpack_require__(19); + +var quoteAttributeValueForBrowser = __webpack_require__(263); +var warning = __webpack_require__(3); + +var VALID_ATTRIBUTE_NAME_REGEX = new RegExp('^[' + DOMProperty.ATTRIBUTE_NAME_START_CHAR + '][' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); +var illegalAttributeNameCache = {}; +var validatedAttributeNameCache = {}; + +function isAttributeNameSafe(attributeName) { + if (validatedAttributeNameCache.hasOwnProperty(attributeName)) { + return true; + } + if (illegalAttributeNameCache.hasOwnProperty(attributeName)) { + return false; + } + if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) { + validatedAttributeNameCache[attributeName] = true; + return true; + } + illegalAttributeNameCache[attributeName] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid attribute name: `%s`', attributeName) : void 0; + return false; +} + +function shouldIgnoreValue(propertyInfo, value) { + return value == null || propertyInfo.hasBooleanValue && !value || propertyInfo.hasNumericValue && isNaN(value) || propertyInfo.hasPositiveNumericValue && value < 1 || propertyInfo.hasOverloadedBooleanValue && value === false; +} + +/** + * Operations for dealing with DOM properties. + */ +var DOMPropertyOperations = { + /** + * Creates markup for the ID property. + * + * @param {string} id Unescaped ID. + * @return {string} Markup string. + */ + createMarkupForID: function (id) { + return DOMProperty.ID_ATTRIBUTE_NAME + '=' + quoteAttributeValueForBrowser(id); + }, + + setAttributeForID: function (node, id) { + node.setAttribute(DOMProperty.ID_ATTRIBUTE_NAME, id); + }, + + createMarkupForRoot: function () { + return DOMProperty.ROOT_ATTRIBUTE_NAME + '=""'; + }, + + setAttributeForRoot: function (node) { + node.setAttribute(DOMProperty.ROOT_ATTRIBUTE_NAME, ''); + }, + + /** + * Creates markup for a property. + * + * @param {string} name + * @param {*} value + * @return {?string} Markup string, or null if the property was invalid. + */ + createMarkupForProperty: function (name, value) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + if (shouldIgnoreValue(propertyInfo, value)) { + return ''; + } + var attributeName = propertyInfo.attributeName; + if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { + return attributeName + '=""'; + } + return attributeName + '=' + quoteAttributeValueForBrowser(value); + } else if (DOMProperty.isCustomAttribute(name)) { + if (value == null) { + return ''; + } + return name + '=' + quoteAttributeValueForBrowser(value); + } + return null; + }, + + /** + * Creates markup for a custom property. + * + * @param {string} name + * @param {*} value + * @return {string} Markup string, or empty string if the property was invalid. + */ + createMarkupForCustomAttribute: function (name, value) { + if (!isAttributeNameSafe(name) || value == null) { + return ''; + } + return name + '=' + quoteAttributeValueForBrowser(value); + }, + + /** + * Sets the value for a property on a node. + * + * @param {DOMElement} node + * @param {string} name + * @param {*} value + */ + setValueForProperty: function (node, name, value) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + var mutationMethod = propertyInfo.mutationMethod; + if (mutationMethod) { + mutationMethod(node, value); + } else if (shouldIgnoreValue(propertyInfo, value)) { + this.deleteValueForProperty(node, name); + return; + } else if (propertyInfo.mustUseProperty) { + // Contrary to `setAttribute`, object properties are properly + // `toString`ed by IE8/9. + node[propertyInfo.propertyName] = value; + } else { + var attributeName = propertyInfo.attributeName; + var namespace = propertyInfo.attributeNamespace; + // `setAttribute` with objects becomes only `[object]` in IE8/9, + // ('' + value) makes it output the correct toString()-value. + if (namespace) { + node.setAttributeNS(namespace, attributeName, '' + value); + } else if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { + node.setAttribute(attributeName, ''); + } else { + node.setAttribute(attributeName, '' + value); + } + } + } else if (DOMProperty.isCustomAttribute(name)) { + DOMPropertyOperations.setValueForAttribute(node, name, value); + return; + } + + if (process.env.NODE_ENV !== 'production') { + var payload = {}; + payload[name] = value; + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'update attribute', + payload: payload + }); + } + }, + + setValueForAttribute: function (node, name, value) { + if (!isAttributeNameSafe(name)) { + return; + } + if (value == null) { + node.removeAttribute(name); + } else { + node.setAttribute(name, '' + value); + } + + if (process.env.NODE_ENV !== 'production') { + var payload = {}; + payload[name] = value; + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'update attribute', + payload: payload + }); + } + }, + + /** + * Deletes an attributes from a node. + * + * @param {DOMElement} node + * @param {string} name + */ + deleteValueForAttribute: function (node, name) { + node.removeAttribute(name); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'remove attribute', + payload: name + }); + } + }, + + /** + * Deletes the value for a property on a node. + * + * @param {DOMElement} node + * @param {string} name + */ + deleteValueForProperty: function (node, name) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + var mutationMethod = propertyInfo.mutationMethod; + if (mutationMethod) { + mutationMethod(node, undefined); + } else if (propertyInfo.mustUseProperty) { + var propName = propertyInfo.propertyName; + if (propertyInfo.hasBooleanValue) { + node[propName] = false; + } else { + node[propName] = ''; + } + } else { + node.removeAttribute(propertyInfo.attributeName); + } + } else if (DOMProperty.isCustomAttribute(name)) { + node.removeAttribute(name); + } + + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'remove attribute', + payload: name + }); + } + } +}; + +module.exports = DOMPropertyOperations; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 139 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; + +module.exports = ReactPropTypesSecret; + +/***/ }), +/* 140 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); + +var warning = __webpack_require__(3); + +var didWarnValueLink = false; +var didWarnValueDefaultValue = false; + +function updateOptionsIfPendingUpdateAndMounted() { + if (this._rootNodeID && this._wrapperState.pendingUpdate) { + this._wrapperState.pendingUpdate = false; + + var props = this._currentElement.props; + var value = LinkedValueUtils.getValue(props); + + if (value != null) { + updateOptions(this, Boolean(props.multiple), value); + } + } +} + +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} + +var valuePropNames = ['value', 'defaultValue']; + +/** + * Validation function for `value` and `defaultValue`. + * @private + */ +function checkSelectPropTypes(inst, props) { + var owner = inst._currentElement._owner; + LinkedValueUtils.checkPropTypes('select', props, owner); + + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `select` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + + for (var i = 0; i < valuePropNames.length; i++) { + var propName = valuePropNames[i]; + if (props[propName] == null) { + continue; + } + var isArray = Array.isArray(props[propName]); + if (props.multiple && !isArray) { + process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be an array if ' + '`multiple` is true.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; + } else if (!props.multiple && isArray) { + process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be a scalar ' + 'value if `multiple` is false.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; + } + } +} + +/** + * @param {ReactDOMComponent} inst + * @param {boolean} multiple + * @param {*} propValue A stringable (with `multiple`, a list of stringables). + * @private + */ +function updateOptions(inst, multiple, propValue) { + var selectedValue, i; + var options = ReactDOMComponentTree.getNodeFromInstance(inst).options; + + if (multiple) { + selectedValue = {}; + for (i = 0; i < propValue.length; i++) { + selectedValue['' + propValue[i]] = true; + } + for (i = 0; i < options.length; i++) { + var selected = selectedValue.hasOwnProperty(options[i].value); + if (options[i].selected !== selected) { + options[i].selected = selected; + } + } + } else { + // Do not set `select.value` as exact behavior isn't consistent across all + // browsers for all cases. + selectedValue = '' + propValue; + for (i = 0; i < options.length; i++) { + if (options[i].value === selectedValue) { + options[i].selected = true; + return; + } + } + if (options.length) { + options[0].selected = true; + } + } +} + +/** + * Implements a <select> host component that allows optionally setting the + * props `value` and `defaultValue`. If `multiple` is false, the prop must be a + * stringable. If `multiple` is true, the prop must be an array of stringables. + * + * If `value` is not supplied (or null/undefined), user actions that change the + * selected option will trigger updates to the rendered options. + * + * If it is supplied (and not null/undefined), the rendered options will not + * update in response to user actions. Instead, the `value` prop must change in + * order for the rendered options to update. + * + * If `defaultValue` is provided, any options with the supplied values will be + * selected. + */ +var ReactDOMSelect = { + getHostProps: function (inst, props) { + return _assign({}, props, { + onChange: inst._wrapperState.onChange, + value: undefined + }); + }, + + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + checkSelectPropTypes(inst, props); + } + + var value = LinkedValueUtils.getValue(props); + inst._wrapperState = { + pendingUpdate: false, + initialValue: value != null ? value : props.defaultValue, + listeners: null, + onChange: _handleChange.bind(inst), + wasMultiple: Boolean(props.multiple) + }; + + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Select elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; + didWarnValueDefaultValue = true; + } + }, + + getSelectValueContext: function (inst) { + // ReactDOMOption looks at this initial value so the initial generated + // markup has correct `selected` attributes + return inst._wrapperState.initialValue; + }, + + postUpdateWrapper: function (inst) { + var props = inst._currentElement.props; + + // After the initial mount, we control selected-ness manually so don't pass + // this value down + inst._wrapperState.initialValue = undefined; + + var wasMultiple = inst._wrapperState.wasMultiple; + inst._wrapperState.wasMultiple = Boolean(props.multiple); + + var value = LinkedValueUtils.getValue(props); + if (value != null) { + inst._wrapperState.pendingUpdate = false; + updateOptions(inst, Boolean(props.multiple), value); + } else if (wasMultiple !== Boolean(props.multiple)) { + // For simplicity, reapply `defaultValue` if `multiple` is toggled. + if (props.defaultValue != null) { + updateOptions(inst, Boolean(props.multiple), props.defaultValue); + } else { + // Revert the select back to its default unselected state. + updateOptions(inst, Boolean(props.multiple), props.multiple ? [] : ''); + } + } + } +}; + +function _handleChange(event) { + var props = this._currentElement.props; + var returnValue = LinkedValueUtils.executeOnChange(props, event); + + if (this._rootNodeID) { + this._wrapperState.pendingUpdate = true; + } + ReactUpdates.asap(updateOptionsIfPendingUpdateAndMounted, this); + return returnValue; +} + +module.exports = ReactDOMSelect; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 141 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var ReactCompositeComponent = __webpack_require__(271); +var ReactEmptyComponent = __webpack_require__(143); +var ReactHostComponent = __webpack_require__(144); + +var getNextDebugID = __webpack_require__(274); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +// To avoid a cyclic dependency, we create the final class in this module +var ReactCompositeComponentWrapper = function (element) { + this.construct(element); +}; + +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} + +/** + * Check if the type reference is a known internal type. I.e. not a user + * provided composite type. + * + * @param {function} type + * @return {boolean} Returns true if this is a valid internal type. + */ +function isInternalComponentType(type) { + return typeof type === 'function' && typeof type.prototype !== 'undefined' && typeof type.prototype.mountComponent === 'function' && typeof type.prototype.receiveComponent === 'function'; +} + +/** + * Given a ReactNode, create an instance that will actually be mounted. + * + * @param {ReactNode} node + * @param {boolean} shouldHaveDebugID + * @return {object} A new instance of the element's constructor. + * @protected + */ +function instantiateReactComponent(node, shouldHaveDebugID) { + var instance; + + if (node === null || node === false) { + instance = ReactEmptyComponent.create(instantiateReactComponent); + } else if (typeof node === 'object') { + var element = node; + var type = element.type; + if (typeof type !== 'function' && typeof type !== 'string') { + var info = ''; + if (process.env.NODE_ENV !== 'production') { + if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { + info += ' You likely forgot to export your component from the file ' + "it's defined in."; + } + } + info += getDeclarationErrorAddendum(element._owner); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s', type == null ? type : typeof type, info) : _prodInvariant('130', type == null ? type : typeof type, info) : void 0; + } + + // Special case string values + if (typeof element.type === 'string') { + instance = ReactHostComponent.createInternalComponent(element); + } else if (isInternalComponentType(element.type)) { + // This is temporarily available for custom components that are not string + // representations. I.e. ART. Once those are updated to use the string + // representation, we can drop this code path. + instance = new element.type(element); + + // We renamed this. Allow the old name for compat. :( + if (!instance.getHostNode) { + instance.getHostNode = instance.getNativeNode; + } + } else { + instance = new ReactCompositeComponentWrapper(element); + } + } else if (typeof node === 'string' || typeof node === 'number') { + instance = ReactHostComponent.createInstanceForText(node); + } else { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Encountered invalid React node of type %s', typeof node) : _prodInvariant('131', typeof node) : void 0; + } + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(typeof instance.mountComponent === 'function' && typeof instance.receiveComponent === 'function' && typeof instance.getHostNode === 'function' && typeof instance.unmountComponent === 'function', 'Only React Components can be mounted.') : void 0; + } + + // These two fields are used by the DOM and ART diffing algorithms + // respectively. Instead of using expandos on components, we should be + // storing the state needed by the diffing algorithms elsewhere. + instance._mountIndex = 0; + instance._mountImage = null; + + if (process.env.NODE_ENV !== 'production') { + instance._debugID = shouldHaveDebugID ? getNextDebugID() : 0; + } + + // Internal instances should fully constructed at this point, so they should + // not get any new fields added to them at this point. + if (process.env.NODE_ENV !== 'production') { + if (Object.preventExtensions) { + Object.preventExtensions(instance); + } + } + + return instance; +} + +_assign(ReactCompositeComponentWrapper.prototype, ReactCompositeComponent, { + _instantiateReactComponent: instantiateReactComponent +}); + +module.exports = instantiateReactComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 142 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var React = __webpack_require__(36); + +var invariant = __webpack_require__(2); + +var ReactNodeTypes = { + HOST: 0, + COMPOSITE: 1, + EMPTY: 2, + + getType: function (node) { + if (node === null || node === false) { + return ReactNodeTypes.EMPTY; + } else if (React.isValidElement(node)) { + if (typeof node.type === 'function') { + return ReactNodeTypes.COMPOSITE; + } else { + return ReactNodeTypes.HOST; + } + } + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unexpected node: %s', node) : _prodInvariant('26', node) : void 0; + } +}; + +module.exports = ReactNodeTypes; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 143 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var emptyComponentFactory; + +var ReactEmptyComponentInjection = { + injectEmptyComponentFactory: function (factory) { + emptyComponentFactory = factory; + } +}; + +var ReactEmptyComponent = { + create: function (instantiate) { + return emptyComponentFactory(instantiate); + } +}; + +ReactEmptyComponent.injection = ReactEmptyComponentInjection; + +module.exports = ReactEmptyComponent; + +/***/ }), +/* 144 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +var genericComponentClass = null; +var textComponentClass = null; + +var ReactHostComponentInjection = { + // This accepts a class that receives the tag string. This is a catch all + // that can render any kind of tag. + injectGenericComponentClass: function (componentClass) { + genericComponentClass = componentClass; + }, + // This accepts a text component class that takes the text string to be + // rendered as props. + injectTextComponentClass: function (componentClass) { + textComponentClass = componentClass; + } +}; + +/** + * Get a host internal component class for a specific tag. + * + * @param {ReactElement} element The element to create. + * @return {function} The internal class constructor function. + */ +function createInternalComponent(element) { + !genericComponentClass ? process.env.NODE_ENV !== 'production' ? invariant(false, 'There is no registered component for the tag %s', element.type) : _prodInvariant('111', element.type) : void 0; + return new genericComponentClass(element); +} + +/** + * @param {ReactText} text + * @return {ReactComponent} + */ +function createInstanceForText(text) { + return new textComponentClass(text); +} + +/** + * @param {ReactComponent} component + * @return {boolean} + */ +function isTextComponent(component) { + return component instanceof textComponentClass; +} + +var ReactHostComponent = { + createInternalComponent: createInternalComponent, + createInstanceForText: createInstanceForText, + isTextComponent: isTextComponent, + injection: ReactHostComponentInjection +}; + +module.exports = ReactHostComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 145 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactCurrentOwner = __webpack_require__(22); +var REACT_ELEMENT_TYPE = __webpack_require__(275); + +var getIteratorFn = __webpack_require__(276); +var invariant = __webpack_require__(2); +var KeyEscapeUtils = __webpack_require__(89); +var warning = __webpack_require__(3); + +var SEPARATOR = '.'; +var SUBSEPARATOR = ':'; + +/** + * This is inlined from ReactElement since this file is shared between + * isomorphic and renderers. We could extract this to a + * + */ + +/** + * TODO: Test that a single child and an array with one item have the same key + * pattern. + */ + +var didWarnAboutMaps = false; + +/** + * Generate a key string that identifies a component within a set. + * + * @param {*} component A component that could contain a manual key. + * @param {number} index Index that is used if a manual key is not provided. + * @return {string} + */ +function getComponentKey(component, index) { + // Do some typechecking here since we call this blindly. We want to ensure + // that we don't block potential future ES APIs. + if (component && typeof component === 'object' && component.key != null) { + // Explicit key + return KeyEscapeUtils.escape(component.key); + } + // Implicit key determined by the index in the set + return index.toString(36); +} + +/** + * @param {?*} children Children tree container. + * @param {!string} nameSoFar Name of the key path so far. + * @param {!function} callback Callback to invoke with each child found. + * @param {?*} traverseContext Used to pass information throughout the traversal + * process. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { + var type = typeof children; + + if (type === 'undefined' || type === 'boolean') { + // All of the above are perceived as null. + children = null; + } + + if (children === null || type === 'string' || type === 'number' || + // The following is inlined from ReactElement. This means we can optimize + // some checks. React Fiber also inlines this logic for similar purposes. + type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { + callback(traverseContext, children, + // If it's the only child, treat the name as if it was wrapped in an array + // so that it's consistent if the number of children grows. + nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); + return 1; + } + + var child; + var nextName; + var subtreeCount = 0; // Count of children found in the current subtree. + var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; + + if (Array.isArray(children)) { + for (var i = 0; i < children.length; i++) { + child = children[i]; + nextName = nextNamePrefix + getComponentKey(child, i); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + var iteratorFn = getIteratorFn(children); + if (iteratorFn) { + var iterator = iteratorFn.call(children); + var step; + if (iteratorFn !== children.entries) { + var ii = 0; + while (!(step = iterator.next()).done) { + child = step.value; + nextName = nextNamePrefix + getComponentKey(child, ii++); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + if (process.env.NODE_ENV !== 'production') { + var mapsAsChildrenAddendum = ''; + if (ReactCurrentOwner.current) { + var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); + if (mapsAsChildrenOwnerName) { + mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; + } + } + process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; + didWarnAboutMaps = true; + } + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + child = entry[1]; + nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } + } + } else if (type === 'object') { + var addendum = ''; + if (process.env.NODE_ENV !== 'production') { + addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; + if (children._isReactElement) { + addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; + } + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + addendum += ' Check the render method of `' + name + '`.'; + } + } + } + var childrenString = String(children); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; + } + } + + return subtreeCount; +} + +/** + * Traverses children that are typically specified as `props.children`, but + * might also be specified through attributes: + * + * - `traverseAllChildren(this.props.children, ...)` + * - `traverseAllChildren(this.props.leftPanelChildren, ...)` + * + * The `traverseContext` is an optional argument that is passed through the + * entire traversal. It can be used to store accumulations or anything else that + * the callback might find relevant. + * + * @param {?*} children Children tree object. + * @param {!function} callback To invoke upon traversing each child. + * @param {?*} traverseContext Context for traversal. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildren(children, callback, traverseContext) { + if (children == null) { + return 0; + } + + return traverseAllChildrenImpl(children, '', callback, traverseContext); +} + +module.exports = traverseAllChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 146 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * @typechecks + */ + +var emptyFunction = __webpack_require__(18); + +/** + * Upstream version of event listener. Does not take into account specific + * nature of platform. + */ +var EventListener = { + /** + * Listen to DOM events during the bubble phase. + * + * @param {DOMEventTarget} target DOM element to register listener on. + * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. + * @param {function} callback Callback function. + * @return {object} Object with a `remove` method. + */ + listen: function listen(target, eventType, callback) { + if (target.addEventListener) { + target.addEventListener(eventType, callback, false); + return { + remove: function remove() { + target.removeEventListener(eventType, callback, false); + } + }; + } else if (target.attachEvent) { + target.attachEvent('on' + eventType, callback); + return { + remove: function remove() { + target.detachEvent('on' + eventType, callback); + } + }; + } + }, + + /** + * Listen to DOM events during the capture phase. + * + * @param {DOMEventTarget} target DOM element to register listener on. + * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. + * @param {function} callback Callback function. + * @return {object} Object with a `remove` method. + */ + capture: function capture(target, eventType, callback) { + if (target.addEventListener) { + target.addEventListener(eventType, callback, true); + return { + remove: function remove() { + target.removeEventListener(eventType, callback, true); + } + }; + } else { + if (process.env.NODE_ENV !== 'production') { + console.error('Attempted to listen to events during the capture phase on a ' + 'browser that does not support the capture phase. Your application ' + 'will not receive some events.'); + } + return { + remove: emptyFunction + }; + } + }, + + registerDefault: function registerDefault() {} +}; + +module.exports = EventListener; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 147 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMSelection = __webpack_require__(288); + +var containsNode = __webpack_require__(290); +var focusNode = __webpack_require__(136); +var getActiveElement = __webpack_require__(148); + +function isInDocument(node) { + return containsNode(document.documentElement, node); +} + +/** + * @ReactInputSelection: React input selection module. Based on Selection.js, + * but modified to be suitable for react and has a couple of bug fixes (doesn't + * assume buttons have range selections allowed). + * Input selection module for React. + */ +var ReactInputSelection = { + hasSelectionCapabilities: function (elem) { + var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); + return nodeName && (nodeName === 'input' && elem.type === 'text' || nodeName === 'textarea' || elem.contentEditable === 'true'); + }, + + getSelectionInformation: function () { + var focusedElem = getActiveElement(); + return { + focusedElem: focusedElem, + selectionRange: ReactInputSelection.hasSelectionCapabilities(focusedElem) ? ReactInputSelection.getSelection(focusedElem) : null + }; + }, + + /** + * @restoreSelection: If any selection information was potentially lost, + * restore it. This is useful when performing operations that could remove dom + * nodes and place them back in, resulting in focus being lost. + */ + restoreSelection: function (priorSelectionInformation) { + var curFocusedElem = getActiveElement(); + var priorFocusedElem = priorSelectionInformation.focusedElem; + var priorSelectionRange = priorSelectionInformation.selectionRange; + if (curFocusedElem !== priorFocusedElem && isInDocument(priorFocusedElem)) { + if (ReactInputSelection.hasSelectionCapabilities(priorFocusedElem)) { + ReactInputSelection.setSelection(priorFocusedElem, priorSelectionRange); + } + focusNode(priorFocusedElem); + } + }, + + /** + * @getSelection: Gets the selection bounds of a focused textarea, input or + * contentEditable node. + * -@input: Look up selection bounds of this input + * -@return {start: selectionStart, end: selectionEnd} + */ + getSelection: function (input) { + var selection; + + if ('selectionStart' in input) { + // Modern browser with input or textarea. + selection = { + start: input.selectionStart, + end: input.selectionEnd + }; + } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { + // IE8 input. + var range = document.selection.createRange(); + // There can only be one selection per document in IE, so it must + // be in our element. + if (range.parentElement() === input) { + selection = { + start: -range.moveStart('character', -input.value.length), + end: -range.moveEnd('character', -input.value.length) + }; + } + } else { + // Content editable or old IE textarea. + selection = ReactDOMSelection.getOffsets(input); + } + + return selection || { start: 0, end: 0 }; + }, + + /** + * @setSelection: Sets the selection bounds of a textarea or input and focuses + * the input. + * -@input Set selection bounds of this input or textarea + * -@offsets Object of same form that is returned from get* + */ + setSelection: function (input, offsets) { + var start = offsets.start; + var end = offsets.end; + if (end === undefined) { + end = start; + } + + if ('selectionStart' in input) { + input.selectionStart = start; + input.selectionEnd = Math.min(end, input.value.length); + } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { + var range = input.createTextRange(); + range.collapse(true); + range.moveStart('character', start); + range.moveEnd('character', end - start); + range.select(); + } else { + ReactDOMSelection.setOffsets(input, offsets); + } + } +}; + +module.exports = ReactInputSelection; + +/***/ }), +/* 148 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +/* eslint-disable fb-www/typeof-undefined */ + +/** + * Same as document.activeElement but wraps in a try-catch block. In IE it is + * not safe to call document.activeElement if there is nothing focused. + * + * The activeElement will be null only if the document or document body is not + * yet defined. + * + * @param {?DOMDocument} doc Defaults to current document. + * @return {?DOMElement} + */ +function getActiveElement(doc) /*?DOMElement*/{ + doc = doc || (typeof document !== 'undefined' ? document : undefined); + if (typeof doc === 'undefined') { + return null; + } + try { + return doc.activeElement || doc.body; + } catch (e) { + return doc.body; + } +} + +module.exports = getActiveElement; + +/***/ }), +/* 149 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var DOMLazyTree = __webpack_require__(39); +var DOMProperty = __webpack_require__(28); +var React = __webpack_require__(36); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactCurrentOwner = __webpack_require__(22); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMContainerInfo = __webpack_require__(305); +var ReactDOMFeatureFlags = __webpack_require__(306); +var ReactFeatureFlags = __webpack_require__(131); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactMarkupChecksum = __webpack_require__(307); +var ReactReconciler = __webpack_require__(38); +var ReactUpdateQueue = __webpack_require__(90); +var ReactUpdates = __webpack_require__(23); + +var emptyObject = __webpack_require__(56); +var instantiateReactComponent = __webpack_require__(141); +var invariant = __webpack_require__(2); +var setInnerHTML = __webpack_require__(60); +var shouldUpdateReactComponent = __webpack_require__(88); +var warning = __webpack_require__(3); + +var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; +var ROOT_ATTR_NAME = DOMProperty.ROOT_ATTRIBUTE_NAME; + +var ELEMENT_NODE_TYPE = 1; +var DOC_NODE_TYPE = 9; +var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + +var instancesByReactRootID = {}; + +/** + * Finds the index of the first character + * that's not common between the two given strings. + * + * @return {number} the index of the character where the strings diverge + */ +function firstDifferenceIndex(string1, string2) { + var minLen = Math.min(string1.length, string2.length); + for (var i = 0; i < minLen; i++) { + if (string1.charAt(i) !== string2.charAt(i)) { + return i; + } + } + return string1.length === string2.length ? -1 : minLen; +} + +/** + * @param {DOMElement|DOMDocument} container DOM element that may contain + * a React component + * @return {?*} DOM element that may have the reactRoot ID, or null. + */ +function getReactRootElementInContainer(container) { + if (!container) { + return null; + } + + if (container.nodeType === DOC_NODE_TYPE) { + return container.documentElement; + } else { + return container.firstChild; + } +} + +function internalGetID(node) { + // If node is something like a window, document, or text node, none of + // which support attributes or a .getAttribute method, gracefully return + // the empty string, as if the attribute were missing. + return node.getAttribute && node.getAttribute(ATTR_NAME) || ''; +} + +/** + * Mounts this component and inserts it into the DOM. + * + * @param {ReactComponent} componentInstance The instance to mount. + * @param {DOMElement} container DOM element to mount into. + * @param {ReactReconcileTransaction} transaction + * @param {boolean} shouldReuseMarkup If true, do not insert markup + */ +function mountComponentIntoNode(wrapperInstance, container, transaction, shouldReuseMarkup, context) { + var markerName; + if (ReactFeatureFlags.logTopLevelRenders) { + var wrappedElement = wrapperInstance._currentElement.props.child; + var type = wrappedElement.type; + markerName = 'React mount: ' + (typeof type === 'string' ? type : type.displayName || type.name); + console.time(markerName); + } + + var markup = ReactReconciler.mountComponent(wrapperInstance, transaction, null, ReactDOMContainerInfo(wrapperInstance, container), context, 0 /* parentDebugID */ + ); + + if (markerName) { + console.timeEnd(markerName); + } + + wrapperInstance._renderedComponent._topLevelWrapper = wrapperInstance; + ReactMount._mountImageIntoNode(markup, container, wrapperInstance, shouldReuseMarkup, transaction); +} + +/** + * Batched mount. + * + * @param {ReactComponent} componentInstance The instance to mount. + * @param {DOMElement} container DOM element to mount into. + * @param {boolean} shouldReuseMarkup If true, do not insert markup + */ +function batchedMountComponentIntoNode(componentInstance, container, shouldReuseMarkup, context) { + var transaction = ReactUpdates.ReactReconcileTransaction.getPooled( + /* useCreateElement */ + !shouldReuseMarkup && ReactDOMFeatureFlags.useCreateElement); + transaction.perform(mountComponentIntoNode, null, componentInstance, container, transaction, shouldReuseMarkup, context); + ReactUpdates.ReactReconcileTransaction.release(transaction); +} + +/** + * Unmounts a component and removes it from the DOM. + * + * @param {ReactComponent} instance React component instance. + * @param {DOMElement} container DOM element to unmount from. + * @final + * @internal + * @see {ReactMount.unmountComponentAtNode} + */ +function unmountComponentFromNode(instance, container, safely) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onBeginFlush(); + } + ReactReconciler.unmountComponent(instance, safely); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onEndFlush(); + } + + if (container.nodeType === DOC_NODE_TYPE) { + container = container.documentElement; + } + + // http://jsperf.com/emptying-a-node + while (container.lastChild) { + container.removeChild(container.lastChild); + } +} + +/** + * True if the supplied DOM node has a direct React-rendered child that is + * not a React root element. Useful for warning in `render`, + * `unmountComponentAtNode`, etc. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM element contains a direct child that was + * rendered by React but is not a root element. + * @internal + */ +function hasNonRootReactChild(container) { + var rootEl = getReactRootElementInContainer(container); + if (rootEl) { + var inst = ReactDOMComponentTree.getInstanceFromNode(rootEl); + return !!(inst && inst._hostParent); + } +} + +/** + * True if the supplied DOM node is a React DOM element and + * it has been rendered by another copy of React. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM has been rendered by another copy of React + * @internal + */ +function nodeIsRenderedByOtherInstance(container) { + var rootEl = getReactRootElementInContainer(container); + return !!(rootEl && isReactNode(rootEl) && !ReactDOMComponentTree.getInstanceFromNode(rootEl)); +} + +/** + * True if the supplied DOM node is a valid node element. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM is a valid DOM node. + * @internal + */ +function isValidContainer(node) { + return !!(node && (node.nodeType === ELEMENT_NODE_TYPE || node.nodeType === DOC_NODE_TYPE || node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE)); +} + +/** + * True if the supplied DOM node is a valid React node element. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM is a valid React DOM node. + * @internal + */ +function isReactNode(node) { + return isValidContainer(node) && (node.hasAttribute(ROOT_ATTR_NAME) || node.hasAttribute(ATTR_NAME)); +} + +function getHostRootInstanceInContainer(container) { + var rootEl = getReactRootElementInContainer(container); + var prevHostInstance = rootEl && ReactDOMComponentTree.getInstanceFromNode(rootEl); + return prevHostInstance && !prevHostInstance._hostParent ? prevHostInstance : null; +} + +function getTopLevelWrapperInContainer(container) { + var root = getHostRootInstanceInContainer(container); + return root ? root._hostContainerInfo._topLevelWrapper : null; +} + +/** + * Temporary (?) hack so that we can store all top-level pending updates on + * composites instead of having to worry about different types of components + * here. + */ +var topLevelRootCounter = 1; +var TopLevelWrapper = function () { + this.rootID = topLevelRootCounter++; +}; +TopLevelWrapper.prototype.isReactComponent = {}; +if (process.env.NODE_ENV !== 'production') { + TopLevelWrapper.displayName = 'TopLevelWrapper'; +} +TopLevelWrapper.prototype.render = function () { + return this.props.child; +}; +TopLevelWrapper.isReactTopLevelWrapper = true; + +/** + * Mounting is the process of initializing a React component by creating its + * representative DOM elements and inserting them into a supplied `container`. + * Any prior content inside `container` is destroyed in the process. + * + * ReactMount.render( + * component, + * document.getElementById('container') + * ); + * + * <div id="container"> <-- Supplied `container`. + * <div data-reactid=".3"> <-- Rendered reactRoot of React + * // ... component. + * </div> + * </div> + * + * Inside of `container`, the first element rendered is the "reactRoot". + */ +var ReactMount = { + TopLevelWrapper: TopLevelWrapper, + + /** + * Used by devtools. The keys are not important. + */ + _instancesByReactRootID: instancesByReactRootID, + + /** + * This is a hook provided to support rendering React components while + * ensuring that the apparent scroll position of its `container` does not + * change. + * + * @param {DOMElement} container The `container` being rendered into. + * @param {function} renderCallback This must be called once to do the render. + */ + scrollMonitor: function (container, renderCallback) { + renderCallback(); + }, + + /** + * Take a component that's already mounted into the DOM and replace its props + * @param {ReactComponent} prevComponent component instance already in the DOM + * @param {ReactElement} nextElement component instance to render + * @param {DOMElement} container container to render into + * @param {?function} callback function triggered on completion + */ + _updateRootComponent: function (prevComponent, nextElement, nextContext, container, callback) { + ReactMount.scrollMonitor(container, function () { + ReactUpdateQueue.enqueueElementInternal(prevComponent, nextElement, nextContext); + if (callback) { + ReactUpdateQueue.enqueueCallbackInternal(prevComponent, callback); + } + }); + + return prevComponent; + }, + + /** + * Render a new component into the DOM. Hooked by hooks! + * + * @param {ReactElement} nextElement element to render + * @param {DOMElement} container container to render into + * @param {boolean} shouldReuseMarkup if we should skip the markup insertion + * @return {ReactComponent} nextComponent + */ + _renderNewRootComponent: function (nextElement, container, shouldReuseMarkup, context) { + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '_renderNewRootComponent(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from ' + 'render is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; + + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, '_registerComponent(...): Target container is not a DOM element.') : _prodInvariant('37') : void 0; + + ReactBrowserEventEmitter.ensureScrollValueMonitoring(); + var componentInstance = instantiateReactComponent(nextElement, false); + + // The initial render is synchronous but any updates that happen during + // rendering, in componentWillMount or componentDidMount, will be batched + // according to the current batching strategy. + + ReactUpdates.batchedUpdates(batchedMountComponentIntoNode, componentInstance, container, shouldReuseMarkup, context); + + var wrapperID = componentInstance._instance.rootID; + instancesByReactRootID[wrapperID] = componentInstance; + + return componentInstance; + }, + + /** + * Renders a React component into the DOM in the supplied `container`. + * + * If the React component was previously rendered into `container`, this will + * perform an update on it and only mutate the DOM as necessary to reflect the + * latest React component. + * + * @param {ReactComponent} parentComponent The conceptual parent of this render tree. + * @param {ReactElement} nextElement Component element to render. + * @param {DOMElement} container DOM element to render into. + * @param {?function} callback function triggered on completion + * @return {ReactComponent} Component instance rendered in `container`. + */ + renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { + !(parentComponent != null && ReactInstanceMap.has(parentComponent)) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'parentComponent must be a valid React Component') : _prodInvariant('38') : void 0; + return ReactMount._renderSubtreeIntoContainer(parentComponent, nextElement, container, callback); + }, + + _renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { + ReactUpdateQueue.validateCallback(callback, 'ReactDOM.render'); + !React.isValidElement(nextElement) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOM.render(): Invalid component element.%s', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : // Check if it quacks like an element + nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : _prodInvariant('39', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : void 0; + + process.env.NODE_ENV !== 'production' ? warning(!container || !container.tagName || container.tagName.toUpperCase() !== 'BODY', 'render(): Rendering components directly into document.body is ' + 'discouraged, since its children are often manipulated by third-party ' + 'scripts and browser extensions. This may lead to subtle ' + 'reconciliation issues. Try rendering into a container element created ' + 'for your app.') : void 0; + + var nextWrappedElement = React.createElement(TopLevelWrapper, { + child: nextElement + }); + + var nextContext; + if (parentComponent) { + var parentInst = ReactInstanceMap.get(parentComponent); + nextContext = parentInst._processChildContext(parentInst._context); + } else { + nextContext = emptyObject; + } + + var prevComponent = getTopLevelWrapperInContainer(container); + + if (prevComponent) { + var prevWrappedElement = prevComponent._currentElement; + var prevElement = prevWrappedElement.props.child; + if (shouldUpdateReactComponent(prevElement, nextElement)) { + var publicInst = prevComponent._renderedComponent.getPublicInstance(); + var updatedCallback = callback && function () { + callback.call(publicInst); + }; + ReactMount._updateRootComponent(prevComponent, nextWrappedElement, nextContext, container, updatedCallback); + return publicInst; + } else { + ReactMount.unmountComponentAtNode(container); + } + } + + var reactRootElement = getReactRootElementInContainer(container); + var containerHasReactMarkup = reactRootElement && !!internalGetID(reactRootElement); + var containerHasNonRootReactChild = hasNonRootReactChild(container); + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, 'render(...): Replacing React-rendered children with a new root ' + 'component. If you intended to update the children of this node, ' + 'you should instead have the existing children update their state ' + 'and render the new components instead of calling ReactDOM.render.') : void 0; + + if (!containerHasReactMarkup || reactRootElement.nextSibling) { + var rootElementSibling = reactRootElement; + while (rootElementSibling) { + if (internalGetID(rootElementSibling)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'render(): Target node has markup rendered by React, but there ' + 'are unrelated nodes as well. This is most commonly caused by ' + 'white-space inserted around server-rendered markup.') : void 0; + break; + } + rootElementSibling = rootElementSibling.nextSibling; + } + } + } + + var shouldReuseMarkup = containerHasReactMarkup && !prevComponent && !containerHasNonRootReactChild; + var component = ReactMount._renderNewRootComponent(nextWrappedElement, container, shouldReuseMarkup, nextContext)._renderedComponent.getPublicInstance(); + if (callback) { + callback.call(component); + } + return component; + }, + + /** + * Renders a React component into the DOM in the supplied `container`. + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.render + * + * If the React component was previously rendered into `container`, this will + * perform an update on it and only mutate the DOM as necessary to reflect the + * latest React component. + * + * @param {ReactElement} nextElement Component element to render. + * @param {DOMElement} container DOM element to render into. + * @param {?function} callback function triggered on completion + * @return {ReactComponent} Component instance rendered in `container`. + */ + render: function (nextElement, container, callback) { + return ReactMount._renderSubtreeIntoContainer(null, nextElement, container, callback); + }, + + /** + * Unmounts and destroys the React component rendered in the `container`. + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.unmountcomponentatnode + * + * @param {DOMElement} container DOM element containing a React component. + * @return {boolean} True if a component was found in and unmounted from + * `container` + */ + unmountComponentAtNode: function (container) { + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. (Strictly speaking, unmounting won't cause a + // render but we still don't expect to be in a render call here.) + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, 'unmountComponentAtNode(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from render ' + 'is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; + + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'unmountComponentAtNode(...): Target container is not a DOM element.') : _prodInvariant('40') : void 0; + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!nodeIsRenderedByOtherInstance(container), "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by another copy of React.') : void 0; + } + + var prevComponent = getTopLevelWrapperInContainer(container); + if (!prevComponent) { + // Check if the node being unmounted was rendered by React, but isn't a + // root node. + var containerHasNonRootReactChild = hasNonRootReactChild(container); + + // Check if the container itself is a React root node. + var isContainerReactRoot = container.nodeType === 1 && container.hasAttribute(ROOT_ATTR_NAME); + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by React and is not a top-level container. %s', isContainerReactRoot ? 'You may have accidentally passed in a React root node instead ' + 'of its container.' : 'Instead, have the parent component update its state and ' + 'rerender in order to remove this component.') : void 0; + } + + return false; + } + delete instancesByReactRootID[prevComponent._instance.rootID]; + ReactUpdates.batchedUpdates(unmountComponentFromNode, prevComponent, container, false); + return true; + }, + + _mountImageIntoNode: function (markup, container, instance, shouldReuseMarkup, transaction) { + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'mountComponentIntoNode(...): Target container is not valid.') : _prodInvariant('41') : void 0; + + if (shouldReuseMarkup) { + var rootElement = getReactRootElementInContainer(container); + if (ReactMarkupChecksum.canReuseMarkup(markup, rootElement)) { + ReactDOMComponentTree.precacheNode(instance, rootElement); + return; + } else { + var checksum = rootElement.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + rootElement.removeAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + + var rootMarkup = rootElement.outerHTML; + rootElement.setAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME, checksum); + + var normalizedMarkup = markup; + if (process.env.NODE_ENV !== 'production') { + // because rootMarkup is retrieved from the DOM, various normalizations + // will have occurred which will not be present in `markup`. Here, + // insert markup into a <div> or <iframe> depending on the container + // type to perform the same normalizations before comparing. + var normalizer; + if (container.nodeType === ELEMENT_NODE_TYPE) { + normalizer = document.createElement('div'); + normalizer.innerHTML = markup; + normalizedMarkup = normalizer.innerHTML; + } else { + normalizer = document.createElement('iframe'); + document.body.appendChild(normalizer); + normalizer.contentDocument.write(markup); + normalizedMarkup = normalizer.contentDocument.documentElement.outerHTML; + document.body.removeChild(normalizer); + } + } + + var diffIndex = firstDifferenceIndex(normalizedMarkup, rootMarkup); + var difference = ' (client) ' + normalizedMarkup.substring(diffIndex - 20, diffIndex + 20) + '\n (server) ' + rootMarkup.substring(diffIndex - 20, diffIndex + 20); + + !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document using server rendering but the checksum was invalid. This usually means you rendered a different component type or props on the client from the one on the server, or your render() methods are impure. React cannot handle this case due to cross-browser quirks by rendering at the document root. You should look for environment dependent code in your components and ensure the props are the same client and server side:\n%s', difference) : _prodInvariant('42', difference) : void 0; + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(false, 'React attempted to reuse markup in a container but the ' + 'checksum was invalid. This generally means that you are ' + 'using server rendering and the markup generated on the ' + 'server was not what the client was expecting. React injected ' + 'new markup to compensate which works but you have lost many ' + 'of the benefits of server rendering. Instead, figure out ' + 'why the markup being generated is different on the client ' + 'or server:\n%s', difference) : void 0; + } + } + } + + !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document but you didn\'t use server rendering. We can\'t do this without using server rendering due to cross-browser quirks. See ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('43') : void 0; + + if (transaction.useCreateElement) { + while (container.lastChild) { + container.removeChild(container.lastChild); + } + DOMLazyTree.insertTreeBefore(container, markup, null); + } else { + setInnerHTML(container, markup); + ReactDOMComponentTree.precacheNode(instance, container.firstChild); + } + + if (process.env.NODE_ENV !== 'production') { + var hostNode = ReactDOMComponentTree.getInstanceFromNode(container.firstChild); + if (hostNode._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: hostNode._debugID, + type: 'mount', + payload: markup.toString() + }); + } + } + } +}; + +module.exports = ReactMount; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 150 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactNodeTypes = __webpack_require__(142); + +function getHostComponentFromComposite(inst) { + var type; + + while ((type = inst._renderedNodeType) === ReactNodeTypes.COMPOSITE) { + inst = inst._renderedComponent; + } + + if (type === ReactNodeTypes.HOST) { + return inst._renderedComponent; + } else if (type === ReactNodeTypes.EMPTY) { + return null; + } +} + +module.exports = getHostComponentFromComposite; + +/***/ }), +/* 151 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +exports.__esModule = true; + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _chainFunction = __webpack_require__(323); + +var _chainFunction2 = _interopRequireDefault(_chainFunction); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _propTypes = __webpack_require__(40); + +var _propTypes2 = _interopRequireDefault(_propTypes); + +var _warning = __webpack_require__(324); + +var _warning2 = _interopRequireDefault(_warning); + +var _ChildMapping = __webpack_require__(325); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var propTypes = { + component: _propTypes2.default.any, + childFactory: _propTypes2.default.func, + children: _propTypes2.default.node +}; + +var defaultProps = { + component: 'span', + childFactory: function childFactory(child) { + return child; + } +}; + +var TransitionGroup = function (_React$Component) { + _inherits(TransitionGroup, _React$Component); + + function TransitionGroup(props, context) { + _classCallCheck(this, TransitionGroup); + + var _this = _possibleConstructorReturn(this, _React$Component.call(this, props, context)); + + _this.performAppear = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; + + if (component.componentWillAppear) { + component.componentWillAppear(_this._handleDoneAppearing.bind(_this, key, component)); + } else { + _this._handleDoneAppearing(key, component); + } + }; + + _this._handleDoneAppearing = function (key, component) { + if (component.componentDidAppear) { + component.componentDidAppear(); + } + + delete _this.currentlyTransitioningKeys[key]; + + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + + if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { + // This was removed before it had fully appeared. Remove it. + _this.performLeave(key, component); + } + }; + + _this.performEnter = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; + + if (component.componentWillEnter) { + component.componentWillEnter(_this._handleDoneEntering.bind(_this, key, component)); + } else { + _this._handleDoneEntering(key, component); + } + }; + + _this._handleDoneEntering = function (key, component) { + if (component.componentDidEnter) { + component.componentDidEnter(); + } + + delete _this.currentlyTransitioningKeys[key]; + + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + + if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { + // This was removed before it had fully entered. Remove it. + _this.performLeave(key, component); + } + }; + + _this.performLeave = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; + + if (component.componentWillLeave) { + component.componentWillLeave(_this._handleDoneLeaving.bind(_this, key, component)); + } else { + // Note that this is somewhat dangerous b/c it calls setState() + // again, effectively mutating the component before all the work + // is done. + _this._handleDoneLeaving(key, component); + } + }; + + _this._handleDoneLeaving = function (key, component) { + if (component.componentDidLeave) { + component.componentDidLeave(); + } + + delete _this.currentlyTransitioningKeys[key]; + + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + + if (currentChildMapping && currentChildMapping.hasOwnProperty(key)) { + // This entered again before it fully left. Add it again. + _this.keysToEnter.push(key); + } else { + _this.setState(function (state) { + var newChildren = _extends({}, state.children); + delete newChildren[key]; + return { children: newChildren }; + }); + } + }; + + _this.childRefs = Object.create(null); + + _this.state = { + children: (0, _ChildMapping.getChildMapping)(props.children) + }; + return _this; + } + + TransitionGroup.prototype.componentWillMount = function componentWillMount() { + this.currentlyTransitioningKeys = {}; + this.keysToEnter = []; + this.keysToLeave = []; + }; + + TransitionGroup.prototype.componentDidMount = function componentDidMount() { + var initialChildMapping = this.state.children; + for (var key in initialChildMapping) { + if (initialChildMapping[key]) { + this.performAppear(key, this.childRefs[key]); + } + } + }; + + TransitionGroup.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { + var nextChildMapping = (0, _ChildMapping.getChildMapping)(nextProps.children); + var prevChildMapping = this.state.children; + + this.setState({ + children: (0, _ChildMapping.mergeChildMappings)(prevChildMapping, nextChildMapping) + }); + + for (var key in nextChildMapping) { + var hasPrev = prevChildMapping && prevChildMapping.hasOwnProperty(key); + if (nextChildMapping[key] && !hasPrev && !this.currentlyTransitioningKeys[key]) { + this.keysToEnter.push(key); + } + } + + for (var _key in prevChildMapping) { + var hasNext = nextChildMapping && nextChildMapping.hasOwnProperty(_key); + if (prevChildMapping[_key] && !hasNext && !this.currentlyTransitioningKeys[_key]) { + this.keysToLeave.push(_key); + } + } + + // If we want to someday check for reordering, we could do it here. + }; + + TransitionGroup.prototype.componentDidUpdate = function componentDidUpdate() { + var _this2 = this; + + var keysToEnter = this.keysToEnter; + this.keysToEnter = []; + keysToEnter.forEach(function (key) { + return _this2.performEnter(key, _this2.childRefs[key]); + }); + + var keysToLeave = this.keysToLeave; + this.keysToLeave = []; + keysToLeave.forEach(function (key) { + return _this2.performLeave(key, _this2.childRefs[key]); + }); + }; + + TransitionGroup.prototype.render = function render() { + var _this3 = this; + + // TODO: we could get rid of the need for the wrapper node + // by cloning a single child + var childrenToRender = []; + + var _loop = function _loop(key) { + var child = _this3.state.children[key]; + if (child) { + var isCallbackRef = typeof child.ref !== 'string'; + var factoryChild = _this3.props.childFactory(child); + var ref = function ref(r) { + _this3.childRefs[key] = r; + }; + + process.env.NODE_ENV !== 'production' ? (0, _warning2.default)(isCallbackRef, 'string refs are not supported on children of TransitionGroup and will be ignored. ' + 'Please use a callback ref instead: https://facebook.github.io/react/docs/refs-and-the-dom.html#the-ref-callback-attribute') : void 0; + + // Always chaining the refs leads to problems when the childFactory + // wraps the child. The child ref callback gets called twice with the + // wrapper and the child. So we only need to chain the ref if the + // factoryChild is not different from child. + if (factoryChild === child && isCallbackRef) { + ref = (0, _chainFunction2.default)(child.ref, ref); + } + + // You may need to apply reactive updates to a child as it is leaving. + // The normal React way to do it won't work since the child will have + // already been removed. In case you need this behavior you can provide + // a childFactory function to wrap every child, even the ones that are + // leaving. + childrenToRender.push(_react2.default.cloneElement(factoryChild, { + key: key, + ref: ref + })); + } + }; + + for (var key in this.state.children) { + _loop(key); + } + + // Do not forward TransitionGroup props to primitive DOM nodes + var props = _extends({}, this.props); + delete props.transitionLeave; + delete props.transitionName; + delete props.transitionAppear; + delete props.transitionEnter; + delete props.childFactory; + delete props.transitionLeaveTimeout; + delete props.transitionEnterTimeout; + delete props.transitionAppearTimeout; + delete props.component; + + return _react2.default.createElement(this.props.component, props, childrenToRender); + }; + + return TransitionGroup; +}(_react2.default.Component); + +TransitionGroup.displayName = 'TransitionGroup'; + + +TransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; +TransitionGroup.defaultProps = defaultProps; + +exports.default = TransitionGroup; +module.exports = exports['default']; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 152 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = !!(typeof window !== 'undefined' && window.document && window.document.createElement); +module.exports = exports['default']; + +/***/ }), +/* 153 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.__esModule = true; +exports.nameShape = undefined; +exports.transitionTimeout = transitionTimeout; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _propTypes = __webpack_require__(40); + +var _propTypes2 = _interopRequireDefault(_propTypes); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function transitionTimeout(transitionType) { + var timeoutPropName = 'transition' + transitionType + 'Timeout'; + var enabledPropName = 'transition' + transitionType; + + return function (props) { + // If the transition is enabled + if (props[enabledPropName]) { + // If no timeout duration is provided + if (props[timeoutPropName] == null) { + return new Error(timeoutPropName + ' wasn\'t supplied to CSSTransitionGroup: ' + 'this can cause unreliable animations and won\'t be supported in ' + 'a future version of React. See ' + 'https://fb.me/react-animation-transition-group-timeout for more ' + 'information.'); + + // If the duration isn't a number + } else if (typeof props[timeoutPropName] !== 'number') { + return new Error(timeoutPropName + ' must be a number (in milliseconds)'); + } + } + + return null; + }; +} + +var nameShape = exports.nameShape = _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.shape({ + enter: _propTypes2.default.string, + leave: _propTypes2.default.string, + active: _propTypes2.default.string +}), _propTypes2.default.shape({ + enter: _propTypes2.default.string, + enterActive: _propTypes2.default.string, + leave: _propTypes2.default.string, + leaveActive: _propTypes2.default.string, + appear: _propTypes2.default.string, + appearActive: _propTypes2.default.string +})]); + +/***/ }), +/* 154 */ +/***/ (function(module, exports) { + +var toString = {}.toString; + +module.exports = Array.isArray || function (arr) { + return toString.call(arr) == '[object Array]'; +}; + + +/***/ }), +/* 155 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +module.exports = function bind(fn, thisArg) { + return function wrap() { + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; + } + return fn.apply(thisArg, args); + }; +}; + + +/***/ }), +/* 156 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +var utils = __webpack_require__(20); +var settle = __webpack_require__(340); +var buildURL = __webpack_require__(342); +var parseHeaders = __webpack_require__(343); +var isURLSameOrigin = __webpack_require__(344); +var createError = __webpack_require__(157); +var btoa = (typeof window !== 'undefined' && window.btoa && window.btoa.bind(window)) || __webpack_require__(345); + +module.exports = function xhrAdapter(config) { + return new Promise(function dispatchXhrRequest(resolve, reject) { + var requestData = config.data; + var requestHeaders = config.headers; + + if (utils.isFormData(requestData)) { + delete requestHeaders['Content-Type']; // Let the browser set it + } + + var request = new XMLHttpRequest(); + var loadEvent = 'onreadystatechange'; + var xDomain = false; + + // For IE 8/9 CORS support + // Only supports POST and GET calls and doesn't returns the response headers. + // DON'T do this for testing b/c XMLHttpRequest is mocked, not XDomainRequest. + if (process.env.NODE_ENV !== 'test' && + typeof window !== 'undefined' && + window.XDomainRequest && !('withCredentials' in request) && + !isURLSameOrigin(config.url)) { + request = new window.XDomainRequest(); + loadEvent = 'onload'; + xDomain = true; + request.onprogress = function handleProgress() {}; + request.ontimeout = function handleTimeout() {}; + } + + // HTTP basic authentication + if (config.auth) { + var username = config.auth.username || ''; + var password = config.auth.password || ''; + requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password); + } + + request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true); + + // Set the request timeout in MS + request.timeout = config.timeout; + + // Listen for ready state + request[loadEvent] = function handleLoad() { + if (!request || (request.readyState !== 4 && !xDomain)) { + return; + } + + // The request errored out and we didn't get a response, this will be + // handled by onerror instead + // With one exception: request that using file: protocol, most browsers + // will return status as 0 even though it's a successful request + if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) { + return; + } + + // Prepare the response + var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null; + var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response; + var response = { + data: responseData, + // IE sends 1223 instead of 204 (https://github.com/mzabriskie/axios/issues/201) + status: request.status === 1223 ? 204 : request.status, + statusText: request.status === 1223 ? 'No Content' : request.statusText, + headers: responseHeaders, + config: config, + request: request + }; + + settle(resolve, reject, response); + + // Clean up request + request = null; + }; + + // Handle low level network errors + request.onerror = function handleError() { + // Real errors are hidden from us by the browser + // onerror should only fire if it's a network error + reject(createError('Network Error', config, null, request)); + + // Clean up request + request = null; + }; + + // Handle timeout + request.ontimeout = function handleTimeout() { + reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED', + request)); + + // Clean up request + request = null; + }; + + // Add xsrf header + // This is only done if running in a standard browser environment. + // Specifically not if we're in a web worker, or react-native. + if (utils.isStandardBrowserEnv()) { + var cookies = __webpack_require__(346); + + // Add xsrf header + var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ? + cookies.read(config.xsrfCookieName) : + undefined; + + if (xsrfValue) { + requestHeaders[config.xsrfHeaderName] = xsrfValue; + } + } + + // Add headers to the request + if ('setRequestHeader' in request) { + utils.forEach(requestHeaders, function setRequestHeader(val, key) { + if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') { + // Remove Content-Type if data is undefined + delete requestHeaders[key]; + } else { + // Otherwise add header to the request + request.setRequestHeader(key, val); + } + }); + } + + // Add withCredentials to request if needed + if (config.withCredentials) { + request.withCredentials = true; + } + + // Add responseType to request if needed + if (config.responseType) { + try { + request.responseType = config.responseType; + } catch (e) { + // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2. + // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function. + if (config.responseType !== 'json') { + throw e; + } + } + } + + // Handle progress if needed + if (typeof config.onDownloadProgress === 'function') { + request.addEventListener('progress', config.onDownloadProgress); + } + + // Not all browsers support upload events + if (typeof config.onUploadProgress === 'function' && request.upload) { + request.upload.addEventListener('progress', config.onUploadProgress); + } + + if (config.cancelToken) { + // Handle cancellation + config.cancelToken.promise.then(function onCanceled(cancel) { + if (!request) { + return; + } + + request.abort(); + reject(cancel); + // Clean up request + request = null; + }); + } + + if (requestData === undefined) { + requestData = null; + } + + // Send the request + request.send(requestData); + }); +}; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 157 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var enhanceError = __webpack_require__(341); + +/** + * Create an Error with the specified message, config, error code, request and response. + * + * @param {string} message The error message. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The created error. + */ +module.exports = function createError(message, config, code, request, response) { + var error = new Error(message); + return enhanceError(error, config, code, request, response); +}; + + +/***/ }), +/* 158 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +module.exports = function isCancel(value) { + return !!(value && value.__CANCEL__); +}; + + +/***/ }), +/* 159 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * A `Cancel` is an object that is thrown when an operation is canceled. + * + * @class + * @param {string=} message The message. + */ +function Cancel(message) { + this.message = message; +} + +Cancel.prototype.toString = function toString() { + return 'Cancel' + (this.message ? ': ' + this.message : ''); +}; + +Cancel.prototype.__CANCEL__ = true; + +module.exports = Cancel; + + +/***/ }), +/* 160 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = { + address: __webpack_require__(96), + config: __webpack_require__(66), + zaddress: __webpack_require__(412), + crypto: __webpack_require__(107), + transaction: __webpack_require__(458) +}; + +/***/ }), +/* 161 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(global, process) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + + + +/*<replacement>*/ + +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +module.exports = Readable; + +/*<replacement>*/ +var isArray = __webpack_require__(154); +/*</replacement>*/ + +/*<replacement>*/ +var Duplex; +/*</replacement>*/ + +Readable.ReadableState = ReadableState; + +/*<replacement>*/ +var EE = __webpack_require__(99).EventEmitter; + +var EElistenerCount = function (emitter, type) { + return emitter.listeners(type).length; +}; +/*</replacement>*/ + +/*<replacement>*/ +var Stream = __webpack_require__(162); +/*</replacement>*/ + +// TODO(bmeurer): Change this back to const once hole checks are +// properly optimized away early in Ignition+TurboFan. +/*<replacement>*/ +var Buffer = __webpack_require__(7).Buffer; +var OurUint8Array = global.Uint8Array || function () {}; +function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk); +} +function _isUint8Array(obj) { + return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; +} +/*</replacement>*/ + +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ + +/*<replacement>*/ +var debugUtil = __webpack_require__(367); +var debug = void 0; +if (debugUtil && debugUtil.debuglog) { + debug = debugUtil.debuglog('stream'); +} else { + debug = function () {}; +} +/*</replacement>*/ + +var BufferList = __webpack_require__(368); +var destroyImpl = __webpack_require__(163); +var StringDecoder; + +util.inherits(Readable, Stream); + +var kProxyEvents = ['error', 'close', 'destroy', 'pause', 'resume']; + +function prependListener(emitter, event, fn) { + // Sadly this is not cacheable as some libraries bundle their own + // event emitter implementation with them. + if (typeof emitter.prependListener === 'function') { + return emitter.prependListener(event, fn); + } else { + // This is a hack to make sure that our error handler is attached before any + // userland ones. NEVER DO THIS. This is here only because this code needs + // to continue to work with older versions of Node.js that do not include + // the prependListener() method. The goal is to eventually remove this hack. + if (!emitter._events || !emitter._events[event]) emitter.on(event, fn);else if (isArray(emitter._events[event])) emitter._events[event].unshift(fn);else emitter._events[event] = [fn, emitter._events[event]]; + } +} + +function ReadableState(options, stream) { + Duplex = Duplex || __webpack_require__(34); + + options = options || {}; + + // object stream flag. Used to make read(n) ignore n and to + // make all the buffer merging and length checks go away + this.objectMode = !!options.objectMode; + + if (stream instanceof Duplex) this.objectMode = this.objectMode || !!options.readableObjectMode; + + // the point at which it stops calling _read() to fill the buffer + // Note: 0 is a valid value, means "don't call _read preemptively ever" + var hwm = options.highWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; + this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm; + + // cast to ints. + this.highWaterMark = Math.floor(this.highWaterMark); + + // A linked list is used to store data chunks instead of an array because the + // linked list can remove elements from the beginning faster than + // array.shift() + this.buffer = new BufferList(); + this.length = 0; + this.pipes = null; + this.pipesCount = 0; + this.flowing = null; + this.ended = false; + this.endEmitted = false; + this.reading = false; + + // a flag to be able to tell if the event 'readable'/'data' is emitted + // immediately, or on a later tick. We set this to true at first, because + // any actions that shouldn't happen until "later" should generally also + // not happen before the first read call. + this.sync = true; + + // whenever we return null, then we set a flag to say + // that we're awaiting a 'readable' event emission. + this.needReadable = false; + this.emittedReadable = false; + this.readableListening = false; + this.resumeScheduled = false; + + // has it been destroyed + this.destroyed = false; + + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; + + // the number of writers that are awaiting a drain event in .pipe()s + this.awaitDrain = 0; + + // if true, a maybeReadMore has been scheduled + this.readingMore = false; + + this.decoder = null; + this.encoding = null; + if (options.encoding) { + if (!StringDecoder) StringDecoder = __webpack_require__(102).StringDecoder; + this.decoder = new StringDecoder(options.encoding); + this.encoding = options.encoding; + } +} + +function Readable(options) { + Duplex = Duplex || __webpack_require__(34); + + if (!(this instanceof Readable)) return new Readable(options); + + this._readableState = new ReadableState(options, this); + + // legacy + this.readable = true; + + if (options) { + if (typeof options.read === 'function') this._read = options.read; + + if (typeof options.destroy === 'function') this._destroy = options.destroy; + } + + Stream.call(this); +} + +Object.defineProperty(Readable.prototype, 'destroyed', { + get: function () { + if (this._readableState === undefined) { + return false; + } + return this._readableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (!this._readableState) { + return; + } + + // backward compatibility, the user is explicitly + // managing destroyed + this._readableState.destroyed = value; + } +}); + +Readable.prototype.destroy = destroyImpl.destroy; +Readable.prototype._undestroy = destroyImpl.undestroy; +Readable.prototype._destroy = function (err, cb) { + this.push(null); + cb(err); +}; + +// Manually shove something into the read() buffer. +// This returns true if the highWaterMark has not been hit yet, +// similar to how Writable.write() returns true if you should +// write() some more. +Readable.prototype.push = function (chunk, encoding) { + var state = this._readableState; + var skipChunkCheck; + + if (!state.objectMode) { + if (typeof chunk === 'string') { + encoding = encoding || state.defaultEncoding; + if (encoding !== state.encoding) { + chunk = Buffer.from(chunk, encoding); + encoding = ''; + } + skipChunkCheck = true; + } + } else { + skipChunkCheck = true; + } + + return readableAddChunk(this, chunk, encoding, false, skipChunkCheck); +}; + +// Unshift should *always* be something directly out of read() +Readable.prototype.unshift = function (chunk) { + return readableAddChunk(this, chunk, null, true, false); +}; + +function readableAddChunk(stream, chunk, encoding, addToFront, skipChunkCheck) { + var state = stream._readableState; + if (chunk === null) { + state.reading = false; + onEofChunk(stream, state); + } else { + var er; + if (!skipChunkCheck) er = chunkInvalid(state, chunk); + if (er) { + stream.emit('error', er); + } else if (state.objectMode || chunk && chunk.length > 0) { + if (typeof chunk !== 'string' && !state.objectMode && Object.getPrototypeOf(chunk) !== Buffer.prototype) { + chunk = _uint8ArrayToBuffer(chunk); + } + + if (addToFront) { + if (state.endEmitted) stream.emit('error', new Error('stream.unshift() after end event'));else addChunk(stream, state, chunk, true); + } else if (state.ended) { + stream.emit('error', new Error('stream.push() after EOF')); + } else { + state.reading = false; + if (state.decoder && !encoding) { + chunk = state.decoder.write(chunk); + if (state.objectMode || chunk.length !== 0) addChunk(stream, state, chunk, false);else maybeReadMore(stream, state); + } else { + addChunk(stream, state, chunk, false); + } + } + } else if (!addToFront) { + state.reading = false; + } + } + + return needMoreData(state); +} + +function addChunk(stream, state, chunk, addToFront) { + if (state.flowing && state.length === 0 && !state.sync) { + stream.emit('data', chunk); + stream.read(0); + } else { + // update the buffer info. + state.length += state.objectMode ? 1 : chunk.length; + if (addToFront) state.buffer.unshift(chunk);else state.buffer.push(chunk); + + if (state.needReadable) emitReadable(stream); + } + maybeReadMore(stream, state); +} + +function chunkInvalid(state, chunk) { + var er; + if (!_isUint8Array(chunk) && typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); + } + return er; +} + +// if it's past the high water mark, we can push in some more. +// Also, if we have no data yet, we can stand some +// more bytes. This is to work around cases where hwm=0, +// such as the repl. Also, if the push() triggered a +// readable event, and the user called read(largeNumber) such that +// needReadable was set, then we ought to push more, so that another +// 'readable' event will be triggered. +function needMoreData(state) { + return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0); +} + +Readable.prototype.isPaused = function () { + return this._readableState.flowing === false; +}; + +// backwards compatibility. +Readable.prototype.setEncoding = function (enc) { + if (!StringDecoder) StringDecoder = __webpack_require__(102).StringDecoder; + this._readableState.decoder = new StringDecoder(enc); + this._readableState.encoding = enc; + return this; +}; + +// Don't raise the hwm > 8MB +var MAX_HWM = 0x800000; +function computeNewHighWaterMark(n) { + if (n >= MAX_HWM) { + n = MAX_HWM; + } else { + // Get the next highest power of 2 to prevent increasing hwm excessively in + // tiny amounts + n--; + n |= n >>> 1; + n |= n >>> 2; + n |= n >>> 4; + n |= n >>> 8; + n |= n >>> 16; + n++; + } + return n; +} + +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function howMuchToRead(n, state) { + if (n <= 0 || state.length === 0 && state.ended) return 0; + if (state.objectMode) return 1; + if (n !== n) { + // Only flow one buffer at a time + if (state.flowing && state.length) return state.buffer.head.data.length;else return state.length; + } + // If we're asking for more than the current hwm, then raise the hwm. + if (n > state.highWaterMark) state.highWaterMark = computeNewHighWaterMark(n); + if (n <= state.length) return n; + // Don't have enough + if (!state.ended) { + state.needReadable = true; + return 0; + } + return state.length; +} + +// you can override either this method, or the async _read(n) below. +Readable.prototype.read = function (n) { + debug('read', n); + n = parseInt(n, 10); + var state = this._readableState; + var nOrig = n; + + if (n !== 0) state.emittedReadable = false; + + // if we're doing read(0) to trigger a readable event, but we + // already have a bunch of data in the buffer, then just trigger + // the 'readable' event and move on. + if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) { + debug('read: emitReadable', state.length, state.ended); + if (state.length === 0 && state.ended) endReadable(this);else emitReadable(this); + return null; + } + + n = howMuchToRead(n, state); + + // if we've ended, and we're now clear, then finish it up. + if (n === 0 && state.ended) { + if (state.length === 0) endReadable(this); + return null; + } + + // All the actual chunk generation logic needs to be + // *below* the call to _read. The reason is that in certain + // synthetic stream cases, such as passthrough streams, _read + // may be a completely synchronous operation which may change + // the state of the read buffer, providing enough data when + // before there was *not* enough. + // + // So, the steps are: + // 1. Figure out what the state of things will be after we do + // a read from the buffer. + // + // 2. If that resulting state will trigger a _read, then call _read. + // Note that this may be asynchronous, or synchronous. Yes, it is + // deeply ugly to write APIs this way, but that still doesn't mean + // that the Readable class should behave improperly, as streams are + // designed to be sync/async agnostic. + // Take note if the _read call is sync or async (ie, if the read call + // has returned yet), so that we know whether or not it's safe to emit + // 'readable' etc. + // + // 3. Actually pull the requested chunks out of the buffer and return. + + // if we need a readable event, then we need to do some reading. + var doRead = state.needReadable; + debug('need readable', doRead); + + // if we currently have less than the highWaterMark, then also read some + if (state.length === 0 || state.length - n < state.highWaterMark) { + doRead = true; + debug('length less than watermark', doRead); + } + + // however, if we've ended, then there's no point, and if we're already + // reading, then it's unnecessary. + if (state.ended || state.reading) { + doRead = false; + debug('reading or ended', doRead); + } else if (doRead) { + debug('do read'); + state.reading = true; + state.sync = true; + // if the length is currently zero, then we *need* a readable event. + if (state.length === 0) state.needReadable = true; + // call internal read method + this._read(state.highWaterMark); + state.sync = false; + // If _read pushed data synchronously, then `reading` will be false, + // and we need to re-evaluate how much data we can return to the user. + if (!state.reading) n = howMuchToRead(nOrig, state); + } + + var ret; + if (n > 0) ret = fromList(n, state);else ret = null; + + if (ret === null) { + state.needReadable = true; + n = 0; + } else { + state.length -= n; + } + + if (state.length === 0) { + // If we have nothing in the buffer, then we want to know + // as soon as we *do* get something into the buffer. + if (!state.ended) state.needReadable = true; + + // If we tried to read() past the EOF, then emit end on the next tick. + if (nOrig !== n && state.ended) endReadable(this); + } + + if (ret !== null) this.emit('data', ret); + + return ret; +}; + +function onEofChunk(stream, state) { + if (state.ended) return; + if (state.decoder) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) { + state.buffer.push(chunk); + state.length += state.objectMode ? 1 : chunk.length; + } + } + state.ended = true; + + // emit 'readable' now to make sure it gets picked up. + emitReadable(stream); +} + +// Don't emit readable right away in sync mode, because this can trigger +// another read() call => stack overflow. This way, it might trigger +// a nextTick recursion warning, but that's not so bad. +function emitReadable(stream) { + var state = stream._readableState; + state.needReadable = false; + if (!state.emittedReadable) { + debug('emitReadable', state.flowing); + state.emittedReadable = true; + if (state.sync) processNextTick(emitReadable_, stream);else emitReadable_(stream); + } +} + +function emitReadable_(stream) { + debug('emit readable'); + stream.emit('readable'); + flow(stream); +} + +// at this point, the user has presumably seen the 'readable' event, +// and called read() to consume some data. that may have triggered +// in turn another _read(n) call, in which case reading = true if +// it's in progress. +// However, if we're not ended, or reading, and the length < hwm, +// then go ahead and try to read some more preemptively. +function maybeReadMore(stream, state) { + if (!state.readingMore) { + state.readingMore = true; + processNextTick(maybeReadMore_, stream, state); + } +} + +function maybeReadMore_(stream, state) { + var len = state.length; + while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) { + debug('maybeReadMore read 0'); + stream.read(0); + if (len === state.length) + // didn't get any data, stop spinning. + break;else len = state.length; + } + state.readingMore = false; +} + +// abstract method. to be overridden in specific implementation classes. +// call cb(er, data) where data is <= n in length. +// for virtual (non-string, non-buffer) streams, "length" is somewhat +// arbitrary, and perhaps not very meaningful. +Readable.prototype._read = function (n) { + this.emit('error', new Error('_read() is not implemented')); +}; + +Readable.prototype.pipe = function (dest, pipeOpts) { + var src = this; + var state = this._readableState; + + switch (state.pipesCount) { + case 0: + state.pipes = dest; + break; + case 1: + state.pipes = [state.pipes, dest]; + break; + default: + state.pipes.push(dest); + break; + } + state.pipesCount += 1; + debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts); + + var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr; + + var endFn = doEnd ? onend : unpipe; + if (state.endEmitted) processNextTick(endFn);else src.once('end', endFn); + + dest.on('unpipe', onunpipe); + function onunpipe(readable, unpipeInfo) { + debug('onunpipe'); + if (readable === src) { + if (unpipeInfo && unpipeInfo.hasUnpiped === false) { + unpipeInfo.hasUnpiped = true; + cleanup(); + } + } + } + + function onend() { + debug('onend'); + dest.end(); + } + + // when the dest drains, it reduces the awaitDrain counter + // on the source. This would be more elegant with a .once() + // handler in flow(), but adding and removing repeatedly is + // too slow. + var ondrain = pipeOnDrain(src); + dest.on('drain', ondrain); + + var cleanedUp = false; + function cleanup() { + debug('cleanup'); + // cleanup event handlers once the pipe is broken + dest.removeListener('close', onclose); + dest.removeListener('finish', onfinish); + dest.removeListener('drain', ondrain); + dest.removeListener('error', onerror); + dest.removeListener('unpipe', onunpipe); + src.removeListener('end', onend); + src.removeListener('end', unpipe); + src.removeListener('data', ondata); + + cleanedUp = true; + + // if the reader is waiting for a drain event from this + // specific writer, then it would cause it to never start + // flowing again. + // So, if this is awaiting a drain, then we just call it now. + // If we don't know, then assume that we are waiting for one. + if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain)) ondrain(); + } + + // If the user pushes more data while we're writing to dest then we'll end up + // in ondata again. However, we only want to increase awaitDrain once because + // dest will only emit one 'drain' event for the multiple writes. + // => Introduce a guard on increasing awaitDrain. + var increasedAwaitDrain = false; + src.on('data', ondata); + function ondata(chunk) { + debug('ondata'); + increasedAwaitDrain = false; + var ret = dest.write(chunk); + if (false === ret && !increasedAwaitDrain) { + // If the user unpiped during `dest.write()`, it is possible + // to get stuck in a permanently paused state if that write + // also returned false. + // => Check whether `dest` is still a piping destination. + if ((state.pipesCount === 1 && state.pipes === dest || state.pipesCount > 1 && indexOf(state.pipes, dest) !== -1) && !cleanedUp) { + debug('false write response, pause', src._readableState.awaitDrain); + src._readableState.awaitDrain++; + increasedAwaitDrain = true; + } + src.pause(); + } + } + + // if the dest has an error, then stop piping into it. + // however, don't suppress the throwing behavior for this. + function onerror(er) { + debug('onerror', er); + unpipe(); + dest.removeListener('error', onerror); + if (EElistenerCount(dest, 'error') === 0) dest.emit('error', er); + } + + // Make sure our error handler is attached before userland ones. + prependListener(dest, 'error', onerror); + + // Both close and finish should trigger unpipe, but only once. + function onclose() { + dest.removeListener('finish', onfinish); + unpipe(); + } + dest.once('close', onclose); + function onfinish() { + debug('onfinish'); + dest.removeListener('close', onclose); + unpipe(); + } + dest.once('finish', onfinish); + + function unpipe() { + debug('unpipe'); + src.unpipe(dest); + } + + // tell the dest that it's being piped to + dest.emit('pipe', src); + + // start the flow if it hasn't been started already. + if (!state.flowing) { + debug('pipe resume'); + src.resume(); + } + + return dest; +}; + +function pipeOnDrain(src) { + return function () { + var state = src._readableState; + debug('pipeOnDrain', state.awaitDrain); + if (state.awaitDrain) state.awaitDrain--; + if (state.awaitDrain === 0 && EElistenerCount(src, 'data')) { + state.flowing = true; + flow(src); + } + }; +} + +Readable.prototype.unpipe = function (dest) { + var state = this._readableState; + var unpipeInfo = { hasUnpiped: false }; + + // if we're not piping anywhere, then do nothing. + if (state.pipesCount === 0) return this; + + // just one destination. most common case. + if (state.pipesCount === 1) { + // passed in one, but it's not the right one. + if (dest && dest !== state.pipes) return this; + + if (!dest) dest = state.pipes; + + // got a match. + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + if (dest) dest.emit('unpipe', this, unpipeInfo); + return this; + } + + // slow case. multiple pipe destinations. + + if (!dest) { + // remove all. + var dests = state.pipes; + var len = state.pipesCount; + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + + for (var i = 0; i < len; i++) { + dests[i].emit('unpipe', this, unpipeInfo); + }return this; + } + + // try to find the right one. + var index = indexOf(state.pipes, dest); + if (index === -1) return this; + + state.pipes.splice(index, 1); + state.pipesCount -= 1; + if (state.pipesCount === 1) state.pipes = state.pipes[0]; + + dest.emit('unpipe', this, unpipeInfo); + + return this; +}; + +// set up data events if they are asked for +// Ensure readable listeners eventually get something +Readable.prototype.on = function (ev, fn) { + var res = Stream.prototype.on.call(this, ev, fn); + + if (ev === 'data') { + // Start flowing on next tick if stream isn't explicitly paused + if (this._readableState.flowing !== false) this.resume(); + } else if (ev === 'readable') { + var state = this._readableState; + if (!state.endEmitted && !state.readableListening) { + state.readableListening = state.needReadable = true; + state.emittedReadable = false; + if (!state.reading) { + processNextTick(nReadingNextTick, this); + } else if (state.length) { + emitReadable(this); + } + } + } + + return res; +}; +Readable.prototype.addListener = Readable.prototype.on; + +function nReadingNextTick(self) { + debug('readable nexttick read 0'); + self.read(0); +} + +// pause() and resume() are remnants of the legacy readable stream API +// If the user uses them, then switch into old mode. +Readable.prototype.resume = function () { + var state = this._readableState; + if (!state.flowing) { + debug('resume'); + state.flowing = true; + resume(this, state); + } + return this; +}; + +function resume(stream, state) { + if (!state.resumeScheduled) { + state.resumeScheduled = true; + processNextTick(resume_, stream, state); + } +} + +function resume_(stream, state) { + if (!state.reading) { + debug('resume read 0'); + stream.read(0); + } + + state.resumeScheduled = false; + state.awaitDrain = 0; + stream.emit('resume'); + flow(stream); + if (state.flowing && !state.reading) stream.read(0); +} + +Readable.prototype.pause = function () { + debug('call pause flowing=%j', this._readableState.flowing); + if (false !== this._readableState.flowing) { + debug('pause'); + this._readableState.flowing = false; + this.emit('pause'); + } + return this; +}; + +function flow(stream) { + var state = stream._readableState; + debug('flow', state.flowing); + while (state.flowing && stream.read() !== null) {} +} + +// wrap an old-style stream as the async data source. +// This is *not* part of the readable stream interface. +// It is an ugly unfortunate mess of history. +Readable.prototype.wrap = function (stream) { + var state = this._readableState; + var paused = false; + + var self = this; + stream.on('end', function () { + debug('wrapped end'); + if (state.decoder && !state.ended) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) self.push(chunk); + } + + self.push(null); + }); + + stream.on('data', function (chunk) { + debug('wrapped data'); + if (state.decoder) chunk = state.decoder.write(chunk); + + // don't skip over falsy values in objectMode + if (state.objectMode && (chunk === null || chunk === undefined)) return;else if (!state.objectMode && (!chunk || !chunk.length)) return; + + var ret = self.push(chunk); + if (!ret) { + paused = true; + stream.pause(); + } + }); + + // proxy all the other methods. + // important when wrapping filters and duplexes. + for (var i in stream) { + if (this[i] === undefined && typeof stream[i] === 'function') { + this[i] = function (method) { + return function () { + return stream[method].apply(stream, arguments); + }; + }(i); + } + } + + // proxy certain important events. + for (var n = 0; n < kProxyEvents.length; n++) { + stream.on(kProxyEvents[n], self.emit.bind(self, kProxyEvents[n])); + } + + // when we try to consume some more bytes, simply unpause the + // underlying stream. + self._read = function (n) { + debug('wrapped _read', n); + if (paused) { + paused = false; + stream.resume(); + } + }; + + return self; +}; + +// exposed for testing purposes only. +Readable._fromList = fromList; + +// Pluck off n bytes from an array of buffers. +// Length is the combined lengths of all the buffers in the list. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function fromList(n, state) { + // nothing buffered + if (state.length === 0) return null; + + var ret; + if (state.objectMode) ret = state.buffer.shift();else if (!n || n >= state.length) { + // read it all, truncate the list + if (state.decoder) ret = state.buffer.join('');else if (state.buffer.length === 1) ret = state.buffer.head.data;else ret = state.buffer.concat(state.length); + state.buffer.clear(); + } else { + // read part of list + ret = fromListPartial(n, state.buffer, state.decoder); + } + + return ret; +} + +// Extracts only enough buffered data to satisfy the amount requested. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function fromListPartial(n, list, hasStrings) { + var ret; + if (n < list.head.data.length) { + // slice is the same for buffers and strings + ret = list.head.data.slice(0, n); + list.head.data = list.head.data.slice(n); + } else if (n === list.head.data.length) { + // first chunk is a perfect match + ret = list.shift(); + } else { + // result spans more than one buffer + ret = hasStrings ? copyFromBufferString(n, list) : copyFromBuffer(n, list); + } + return ret; +} + +// Copies a specified amount of characters from the list of buffered data +// chunks. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function copyFromBufferString(n, list) { + var p = list.head; + var c = 1; + var ret = p.data; + n -= ret.length; + while (p = p.next) { + var str = p.data; + var nb = n > str.length ? str.length : n; + if (nb === str.length) ret += str;else ret += str.slice(0, n); + n -= nb; + if (n === 0) { + if (nb === str.length) { + ++c; + if (p.next) list.head = p.next;else list.head = list.tail = null; + } else { + list.head = p; + p.data = str.slice(nb); + } + break; + } + ++c; + } + list.length -= c; + return ret; +} + +// Copies a specified amount of bytes from the list of buffered data chunks. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function copyFromBuffer(n, list) { + var ret = Buffer.allocUnsafe(n); + var p = list.head; + var c = 1; + p.data.copy(ret); + n -= p.data.length; + while (p = p.next) { + var buf = p.data; + var nb = n > buf.length ? buf.length : n; + buf.copy(ret, ret.length - n, 0, nb); + n -= nb; + if (n === 0) { + if (nb === buf.length) { + ++c; + if (p.next) list.head = p.next;else list.head = list.tail = null; + } else { + list.head = p; + p.data = buf.slice(nb); + } + break; + } + ++c; + } + list.length -= c; + return ret; +} + +function endReadable(stream) { + var state = stream._readableState; + + // If we get here before consuming all the bytes, then that is a + // bug in node. Should never happen. + if (state.length > 0) throw new Error('"endReadable()" called on non-empty stream'); + + if (!state.endEmitted) { + state.ended = true; + processNextTick(endReadableNT, state, stream); + } +} + +function endReadableNT(state, stream) { + // Check that we didn't get one last unshift. + if (!state.endEmitted && state.length === 0) { + state.endEmitted = true; + stream.readable = false; + stream.emit('end'); + } +} + +function forEach(xs, f) { + for (var i = 0, l = xs.length; i < l; i++) { + f(xs[i], i); + } +} + +function indexOf(xs, x) { + for (var i = 0, l = xs.length; i < l; i++) { + if (xs[i] === x) return i; + } + return -1; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) + +/***/ }), +/* 162 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(99).EventEmitter; + + +/***/ }), +/* 163 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/*<replacement>*/ + +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +// undocumented cb() API, needed for core, not for public API +function destroy(err, cb) { + var _this = this; + + var readableDestroyed = this._readableState && this._readableState.destroyed; + var writableDestroyed = this._writableState && this._writableState.destroyed; + + if (readableDestroyed || writableDestroyed) { + if (cb) { + cb(err); + } else if (err && (!this._writableState || !this._writableState.errorEmitted)) { + processNextTick(emitErrorNT, this, err); + } + return; + } + + // we set destroyed to true before firing error callbacks in order + // to make it re-entrance safe in case destroy() is called within callbacks + + if (this._readableState) { + this._readableState.destroyed = true; + } + + // if this is a duplex stream mark the writable part as destroyed as well + if (this._writableState) { + this._writableState.destroyed = true; + } + + this._destroy(err || null, function (err) { + if (!cb && err) { + processNextTick(emitErrorNT, _this, err); + if (_this._writableState) { + _this._writableState.errorEmitted = true; + } + } else if (cb) { + cb(err); + } + }); +} + +function undestroy() { + if (this._readableState) { + this._readableState.destroyed = false; + this._readableState.reading = false; + this._readableState.ended = false; + this._readableState.endEmitted = false; + } + + if (this._writableState) { + this._writableState.destroyed = false; + this._writableState.ended = false; + this._writableState.ending = false; + this._writableState.finished = false; + this._writableState.errorEmitted = false; + } +} + +function emitErrorNT(self, err) { + self.emit('error', err); +} + +module.exports = { + destroy: destroy, + undestroy: undestroy +}; + +/***/ }), +/* 164 */ +/***/ (function(module, exports, __webpack_require__) { + +var apply = Function.prototype.apply; + +// DOM APIs, for completeness + +exports.setTimeout = function() { + return new Timeout(apply.call(setTimeout, window, arguments), clearTimeout); +}; +exports.setInterval = function() { + return new Timeout(apply.call(setInterval, window, arguments), clearInterval); +}; +exports.clearTimeout = +exports.clearInterval = function(timeout) { + if (timeout) { + timeout.close(); + } +}; + +function Timeout(id, clearFn) { + this._id = id; + this._clearFn = clearFn; +} +Timeout.prototype.unref = Timeout.prototype.ref = function() {}; +Timeout.prototype.close = function() { + this._clearFn.call(window, this._id); +}; + +// Does not start the time, just sets up the members needed. +exports.enroll = function(item, msecs) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = msecs; +}; + +exports.unenroll = function(item) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = -1; +}; + +exports._unrefActive = exports.active = function(item) { + clearTimeout(item._idleTimeoutId); + + var msecs = item._idleTimeout; + if (msecs >= 0) { + item._idleTimeoutId = setTimeout(function onTimeout() { + if (item._onTimeout) + item._onTimeout(); + }, msecs); + } +}; + +// setimmediate attaches itself to the global object +__webpack_require__(369); +exports.setImmediate = setImmediate; +exports.clearImmediate = clearImmediate; + + +/***/ }), +/* 165 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a transform stream is a readable/writable stream where you do +// something with the data. Sometimes it's called a "filter", +// but that's not a great name for it, since that implies a thing where +// some bits pass through, and others are simply ignored. (That would +// be a valid example of a transform, of course.) +// +// While the output is causally related to the input, it's not a +// necessarily symmetric or synchronous transformation. For example, +// a zlib stream might take multiple plain-text writes(), and then +// emit a single compressed chunk some time in the future. +// +// Here's how this works: +// +// The Transform stream has all the aspects of the readable and writable +// stream classes. When you write(chunk), that calls _write(chunk,cb) +// internally, and returns false if there's a lot of pending writes +// buffered up. When you call read(), that calls _read(n) until +// there's enough pending readable data buffered up. +// +// In a transform stream, the written data is placed in a buffer. When +// _read(n) is called, it transforms the queued up data, calling the +// buffered _write cb's as it consumes chunks. If consuming a single +// written chunk would result in multiple output chunks, then the first +// outputted bit calls the readcb, and subsequent chunks just go into +// the read buffer, and will cause it to emit 'readable' if necessary. +// +// This way, back-pressure is actually determined by the reading side, +// since _read has to be called to start processing a new chunk. However, +// a pathological inflate type of transform can cause excessive buffering +// here. For example, imagine a stream where every byte of input is +// interpreted as an integer from 0-255, and then results in that many +// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in +// 1kb of data being output. In this case, you could write a very small +// amount of input, and end up with a very large amount of output. In +// such a pathological inflating mechanism, there'd be no way to tell +// the system to stop doing the transform. A single 4MB write could +// cause the system to run out of memory. +// +// However, even in such a pathological case, only a single written chunk +// would be consumed, and then the rest would wait (un-transformed) until +// the results of the previous transformed chunk were consumed. + + + +module.exports = Transform; + +var Duplex = __webpack_require__(34); + +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ + +util.inherits(Transform, Duplex); + +function TransformState(stream) { + this.afterTransform = function (er, data) { + return afterTransform(stream, er, data); + }; + + this.needTransform = false; + this.transforming = false; + this.writecb = null; + this.writechunk = null; + this.writeencoding = null; +} + +function afterTransform(stream, er, data) { + var ts = stream._transformState; + ts.transforming = false; + + var cb = ts.writecb; + + if (!cb) { + return stream.emit('error', new Error('write callback called multiple times')); + } + + ts.writechunk = null; + ts.writecb = null; + + if (data !== null && data !== undefined) stream.push(data); + + cb(er); + + var rs = stream._readableState; + rs.reading = false; + if (rs.needReadable || rs.length < rs.highWaterMark) { + stream._read(rs.highWaterMark); + } +} + +function Transform(options) { + if (!(this instanceof Transform)) return new Transform(options); + + Duplex.call(this, options); + + this._transformState = new TransformState(this); + + var stream = this; + + // start out asking for a readable event once data is transformed. + this._readableState.needReadable = true; + + // we have implemented the _read method, and done the other things + // that Readable wants before the first _read call, so unset the + // sync guard flag. + this._readableState.sync = false; + + if (options) { + if (typeof options.transform === 'function') this._transform = options.transform; + + if (typeof options.flush === 'function') this._flush = options.flush; + } + + // When the writable side finishes, then flush out anything remaining. + this.once('prefinish', function () { + if (typeof this._flush === 'function') this._flush(function (er, data) { + done(stream, er, data); + });else done(stream); + }); +} + +Transform.prototype.push = function (chunk, encoding) { + this._transformState.needTransform = false; + return Duplex.prototype.push.call(this, chunk, encoding); +}; + +// This is the part where you do stuff! +// override this function in implementation classes. +// 'chunk' is an input chunk. +// +// Call `push(newChunk)` to pass along transformed output +// to the readable side. You may call 'push' zero or more times. +// +// Call `cb(err)` when you are done with this chunk. If you pass +// an error, then that'll put the hurt on the whole operation. If you +// never call cb(), then you'll never get another chunk. +Transform.prototype._transform = function (chunk, encoding, cb) { + throw new Error('_transform() is not implemented'); +}; + +Transform.prototype._write = function (chunk, encoding, cb) { + var ts = this._transformState; + ts.writecb = cb; + ts.writechunk = chunk; + ts.writeencoding = encoding; + if (!ts.transforming) { + var rs = this._readableState; + if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark) this._read(rs.highWaterMark); + } +}; + +// Doesn't matter what the args are here. +// _transform does all the work. +// That we got here means that the readable side wants more data. +Transform.prototype._read = function (n) { + var ts = this._transformState; + + if (ts.writechunk !== null && ts.writecb && !ts.transforming) { + ts.transforming = true; + this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); + } else { + // mark that we need a transform, so that any data that comes in + // will get processed, now that we've asked for it. + ts.needTransform = true; + } +}; + +Transform.prototype._destroy = function (err, cb) { + var _this = this; + + Duplex.prototype._destroy.call(this, err, function (err2) { + cb(err2); + _this.emit('close'); + }); +}; + +function done(stream, er, data) { + if (er) return stream.emit('error', er); + + if (data !== null && data !== undefined) stream.push(data); + + // if there's nothing in the write buffer, then that means + // that nothing more will ever be provided + var ws = stream._writableState; + var ts = stream._transformState; + + if (ws.length) throw new Error('Calling transform done when ws.length != 0'); + + if (ts.transforming) throw new Error('Calling transform done when still transforming'); + + return stream.push(null); +} + +/***/ }), +/* 166 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/** + * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined + * in FIPS 180-2 + * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * + */ + +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) + +var K = [ + 0x428A2F98, 0x71374491, 0xB5C0FBCF, 0xE9B5DBA5, + 0x3956C25B, 0x59F111F1, 0x923F82A4, 0xAB1C5ED5, + 0xD807AA98, 0x12835B01, 0x243185BE, 0x550C7DC3, + 0x72BE5D74, 0x80DEB1FE, 0x9BDC06A7, 0xC19BF174, + 0xE49B69C1, 0xEFBE4786, 0x0FC19DC6, 0x240CA1CC, + 0x2DE92C6F, 0x4A7484AA, 0x5CB0A9DC, 0x76F988DA, + 0x983E5152, 0xA831C66D, 0xB00327C8, 0xBF597FC7, + 0xC6E00BF3, 0xD5A79147, 0x06CA6351, 0x14292967, + 0x27B70A85, 0x2E1B2138, 0x4D2C6DFC, 0x53380D13, + 0x650A7354, 0x766A0ABB, 0x81C2C92E, 0x92722C85, + 0xA2BFE8A1, 0xA81A664B, 0xC24B8B70, 0xC76C51A3, + 0xD192E819, 0xD6990624, 0xF40E3585, 0x106AA070, + 0x19A4C116, 0x1E376C08, 0x2748774C, 0x34B0BCB5, + 0x391C0CB3, 0x4ED8AA4A, 0x5B9CCA4F, 0x682E6FF3, + 0x748F82EE, 0x78A5636F, 0x84C87814, 0x8CC70208, + 0x90BEFFFA, 0xA4506CEB, 0xBEF9A3F7, 0xC67178F2 +] + +var W = new Array(64) + +function Sha256 () { + this.init() + + this._w = W // new Array(64) + + Hash.call(this, 64, 56) +} + +inherits(Sha256, Hash) + +Sha256.prototype.init = function () { + this._a = 0x6a09e667 + this._b = 0xbb67ae85 + this._c = 0x3c6ef372 + this._d = 0xa54ff53a + this._e = 0x510e527f + this._f = 0x9b05688c + this._g = 0x1f83d9ab + this._h = 0x5be0cd19 + + return this +} + +function ch (x, y, z) { + return z ^ (x & (y ^ z)) +} + +function maj (x, y, z) { + return (x & y) | (z & (x | y)) +} + +function sigma0 (x) { + return (x >>> 2 | x << 30) ^ (x >>> 13 | x << 19) ^ (x >>> 22 | x << 10) +} + +function sigma1 (x) { + return (x >>> 6 | x << 26) ^ (x >>> 11 | x << 21) ^ (x >>> 25 | x << 7) +} + +function gamma0 (x) { + return (x >>> 7 | x << 25) ^ (x >>> 18 | x << 14) ^ (x >>> 3) +} + +function gamma1 (x) { + return (x >>> 17 | x << 15) ^ (x >>> 19 | x << 13) ^ (x >>> 10) +} + +Sha256.prototype._update = function (M) { + var W = this._w + + var a = this._a | 0 + var b = this._b | 0 + var c = this._c | 0 + var d = this._d | 0 + var e = this._e | 0 + var f = this._f | 0 + var g = this._g | 0 + var h = this._h | 0 + + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4) + for (; i < 64; ++i) W[i] = (gamma1(W[i - 2]) + W[i - 7] + gamma0(W[i - 15]) + W[i - 16]) | 0 + + for (var j = 0; j < 64; ++j) { + var T1 = (h + sigma1(e) + ch(e, f, g) + K[j] + W[j]) | 0 + var T2 = (sigma0(a) + maj(a, b, c)) | 0 + + h = g + g = f + f = e + e = (d + T1) | 0 + d = c + c = b + b = a + a = (T1 + T2) | 0 + } + + this._a = (a + this._a) | 0 + this._b = (b + this._b) | 0 + this._c = (c + this._c) | 0 + this._d = (d + this._d) | 0 + this._e = (e + this._e) | 0 + this._f = (f + this._f) | 0 + this._g = (g + this._g) | 0 + this._h = (h + this._h) | 0 +} + +Sha256.prototype._hash = function () { + var H = new Buffer(32) + + H.writeInt32BE(this._a, 0) + H.writeInt32BE(this._b, 4) + H.writeInt32BE(this._c, 8) + H.writeInt32BE(this._d, 12) + H.writeInt32BE(this._e, 16) + H.writeInt32BE(this._f, 20) + H.writeInt32BE(this._g, 24) + H.writeInt32BE(this._h, 28) + + return H +} + +module.exports = Sha256 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 167 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) + +var K = [ + 0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd, + 0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc, + 0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019, + 0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118, + 0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe, + 0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2, + 0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1, + 0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694, + 0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3, + 0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65, + 0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483, + 0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5, + 0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210, + 0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4, + 0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725, + 0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70, + 0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926, + 0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df, + 0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8, + 0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b, + 0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001, + 0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30, + 0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910, + 0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8, + 0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53, + 0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8, + 0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb, + 0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3, + 0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60, + 0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec, + 0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9, + 0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b, + 0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207, + 0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178, + 0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6, + 0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b, + 0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493, + 0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c, + 0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a, + 0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817 +] + +var W = new Array(160) + +function Sha512 () { + this.init() + this._w = W + + Hash.call(this, 128, 112) +} + +inherits(Sha512, Hash) + +Sha512.prototype.init = function () { + this._ah = 0x6a09e667 + this._bh = 0xbb67ae85 + this._ch = 0x3c6ef372 + this._dh = 0xa54ff53a + this._eh = 0x510e527f + this._fh = 0x9b05688c + this._gh = 0x1f83d9ab + this._hh = 0x5be0cd19 + + this._al = 0xf3bcc908 + this._bl = 0x84caa73b + this._cl = 0xfe94f82b + this._dl = 0x5f1d36f1 + this._el = 0xade682d1 + this._fl = 0x2b3e6c1f + this._gl = 0xfb41bd6b + this._hl = 0x137e2179 + + return this +} + +function Ch (x, y, z) { + return z ^ (x & (y ^ z)) +} + +function maj (x, y, z) { + return (x & y) | (z & (x | y)) +} + +function sigma0 (x, xl) { + return (x >>> 28 | xl << 4) ^ (xl >>> 2 | x << 30) ^ (xl >>> 7 | x << 25) +} + +function sigma1 (x, xl) { + return (x >>> 14 | xl << 18) ^ (x >>> 18 | xl << 14) ^ (xl >>> 9 | x << 23) +} + +function Gamma0 (x, xl) { + return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7) +} + +function Gamma0l (x, xl) { + return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7 | xl << 25) +} + +function Gamma1 (x, xl) { + return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6) +} + +function Gamma1l (x, xl) { + return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6 | xl << 26) +} + +function getCarry (a, b) { + return (a >>> 0) < (b >>> 0) ? 1 : 0 +} + +Sha512.prototype._update = function (M) { + var W = this._w + + var ah = this._ah | 0 + var bh = this._bh | 0 + var ch = this._ch | 0 + var dh = this._dh | 0 + var eh = this._eh | 0 + var fh = this._fh | 0 + var gh = this._gh | 0 + var hh = this._hh | 0 + + var al = this._al | 0 + var bl = this._bl | 0 + var cl = this._cl | 0 + var dl = this._dl | 0 + var el = this._el | 0 + var fl = this._fl | 0 + var gl = this._gl | 0 + var hl = this._hl | 0 + + for (var i = 0; i < 32; i += 2) { + W[i] = M.readInt32BE(i * 4) + W[i + 1] = M.readInt32BE(i * 4 + 4) + } + for (; i < 160; i += 2) { + var xh = W[i - 15 * 2] + var xl = W[i - 15 * 2 + 1] + var gamma0 = Gamma0(xh, xl) + var gamma0l = Gamma0l(xl, xh) + + xh = W[i - 2 * 2] + xl = W[i - 2 * 2 + 1] + var gamma1 = Gamma1(xh, xl) + var gamma1l = Gamma1l(xl, xh) + + // W[i] = gamma0 + W[i - 7] + gamma1 + W[i - 16] + var Wi7h = W[i - 7 * 2] + var Wi7l = W[i - 7 * 2 + 1] + + var Wi16h = W[i - 16 * 2] + var Wi16l = W[i - 16 * 2 + 1] + + var Wil = (gamma0l + Wi7l) | 0 + var Wih = (gamma0 + Wi7h + getCarry(Wil, gamma0l)) | 0 + Wil = (Wil + gamma1l) | 0 + Wih = (Wih + gamma1 + getCarry(Wil, gamma1l)) | 0 + Wil = (Wil + Wi16l) | 0 + Wih = (Wih + Wi16h + getCarry(Wil, Wi16l)) | 0 + + W[i] = Wih + W[i + 1] = Wil + } + + for (var j = 0; j < 160; j += 2) { + Wih = W[j] + Wil = W[j + 1] + + var majh = maj(ah, bh, ch) + var majl = maj(al, bl, cl) + + var sigma0h = sigma0(ah, al) + var sigma0l = sigma0(al, ah) + var sigma1h = sigma1(eh, el) + var sigma1l = sigma1(el, eh) + + // t1 = h + sigma1 + ch + K[j] + W[j] + var Kih = K[j] + var Kil = K[j + 1] + + var chh = Ch(eh, fh, gh) + var chl = Ch(el, fl, gl) + + var t1l = (hl + sigma1l) | 0 + var t1h = (hh + sigma1h + getCarry(t1l, hl)) | 0 + t1l = (t1l + chl) | 0 + t1h = (t1h + chh + getCarry(t1l, chl)) | 0 + t1l = (t1l + Kil) | 0 + t1h = (t1h + Kih + getCarry(t1l, Kil)) | 0 + t1l = (t1l + Wil) | 0 + t1h = (t1h + Wih + getCarry(t1l, Wil)) | 0 + + // t2 = sigma0 + maj + var t2l = (sigma0l + majl) | 0 + var t2h = (sigma0h + majh + getCarry(t2l, sigma0l)) | 0 + + hh = gh + hl = gl + gh = fh + gl = fl + fh = eh + fl = el + el = (dl + t1l) | 0 + eh = (dh + t1h + getCarry(el, dl)) | 0 + dh = ch + dl = cl + ch = bh + cl = bl + bh = ah + bl = al + al = (t1l + t2l) | 0 + ah = (t1h + t2h + getCarry(al, t1l)) | 0 + } + + this._al = (this._al + al) | 0 + this._bl = (this._bl + bl) | 0 + this._cl = (this._cl + cl) | 0 + this._dl = (this._dl + dl) | 0 + this._el = (this._el + el) | 0 + this._fl = (this._fl + fl) | 0 + this._gl = (this._gl + gl) | 0 + this._hl = (this._hl + hl) | 0 + + this._ah = (this._ah + ah + getCarry(this._al, al)) | 0 + this._bh = (this._bh + bh + getCarry(this._bl, bl)) | 0 + this._ch = (this._ch + ch + getCarry(this._cl, cl)) | 0 + this._dh = (this._dh + dh + getCarry(this._dl, dl)) | 0 + this._eh = (this._eh + eh + getCarry(this._el, el)) | 0 + this._fh = (this._fh + fh + getCarry(this._fl, fl)) | 0 + this._gh = (this._gh + gh + getCarry(this._gl, gl)) | 0 + this._hh = (this._hh + hh + getCarry(this._hl, hl)) | 0 +} + +Sha512.prototype._hash = function () { + var H = new Buffer(64) + + function writeInt64BE (h, l, offset) { + H.writeInt32BE(h, offset) + H.writeInt32BE(l, offset + 4) + } + + writeInt64BE(this._ah, this._al, 0) + writeInt64BE(this._bh, this._bl, 8) + writeInt64BE(this._ch, this._cl, 16) + writeInt64BE(this._dh, this._dl, 24) + writeInt64BE(this._eh, this._el, 32) + writeInt64BE(this._fh, this._fl, 40) + writeInt64BE(this._gh, this._gl, 48) + writeInt64BE(this._hh, this._hl, 56) + + return H +} + +module.exports = Sha512 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 168 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +module.exports = __webpack_require__(380)(__webpack_require__(383)) + + +/***/ }), +/* 169 */ +/***/ (function(module, exports) { + +module.exports = { + "COMPRESSED_TYPE_INVALID": "compressed should be a boolean", + "EC_PRIVATE_KEY_TYPE_INVALID": "private key should be a Buffer", + "EC_PRIVATE_KEY_LENGTH_INVALID": "private key length is invalid", + "EC_PRIVATE_KEY_TWEAK_ADD_FAIL": "tweak out of range or resulting private key is invalid", + "EC_PRIVATE_KEY_TWEAK_MUL_FAIL": "tweak out of range", + "EC_PRIVATE_KEY_EXPORT_DER_FAIL": "couldn't export to DER format", + "EC_PRIVATE_KEY_IMPORT_DER_FAIL": "couldn't import from DER format", + "EC_PUBLIC_KEYS_TYPE_INVALID": "public keys should be an Array", + "EC_PUBLIC_KEYS_LENGTH_INVALID": "public keys Array should have at least 1 element", + "EC_PUBLIC_KEY_TYPE_INVALID": "public key should be a Buffer", + "EC_PUBLIC_KEY_LENGTH_INVALID": "public key length is invalid", + "EC_PUBLIC_KEY_PARSE_FAIL": "the public key could not be parsed or is invalid", + "EC_PUBLIC_KEY_CREATE_FAIL": "private was invalid, try again", + "EC_PUBLIC_KEY_TWEAK_ADD_FAIL": "tweak out of range or resulting public key is invalid", + "EC_PUBLIC_KEY_TWEAK_MUL_FAIL": "tweak out of range", + "EC_PUBLIC_KEY_COMBINE_FAIL": "the sum of the public keys is not valid", + "ECDH_FAIL": "scalar was invalid (zero or overflow)", + "ECDSA_SIGNATURE_TYPE_INVALID": "signature should be a Buffer", + "ECDSA_SIGNATURE_LENGTH_INVALID": "signature length is invalid", + "ECDSA_SIGNATURE_PARSE_FAIL": "couldn't parse signature", + "ECDSA_SIGNATURE_PARSE_DER_FAIL": "couldn't parse DER signature", + "ECDSA_SIGNATURE_SERIALIZE_DER_FAIL": "couldn't serialize signature to DER format", + "ECDSA_SIGN_FAIL": "nonce generation function failed or private key is invalid", + "ECDSA_RECOVER_FAIL": "couldn't recover public key from signature", + "MSG32_TYPE_INVALID": "message should be a Buffer", + "MSG32_LENGTH_INVALID": "message length is invalid", + "OPTIONS_TYPE_INVALID": "options should be an Object", + "OPTIONS_DATA_TYPE_INVALID": "options.data should be a Buffer", + "OPTIONS_DATA_LENGTH_INVALID": "options.data length is invalid", + "OPTIONS_NONCEFN_TYPE_INVALID": "options.noncefn should be a Function", + "RECOVERY_ID_TYPE_INVALID": "recovery should be a Number", + "RECOVERY_ID_VALUE_INVALID": "recovery should have value between -1 and 4", + "TWEAK_TYPE_INVALID": "tweak should be a Buffer", + "TWEAK_LENGTH_INVALID": "tweak length is invalid" +}; + +/***/ }), +/* 170 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = exports; + +function toArray(msg, enc) { + if (Array.isArray(msg)) + return msg.slice(); + if (!msg) + return []; + var res = []; + if (typeof msg !== 'string') { + for (var i = 0; i < msg.length; i++) + res[i] = msg[i] | 0; + return res; + } + if (enc === 'hex') { + msg = msg.replace(/[^a-z0-9]+/ig, ''); + if (msg.length % 2 !== 0) + msg = '0' + msg; + for (var i = 0; i < msg.length; i += 2) + res.push(parseInt(msg[i] + msg[i + 1], 16)); + } else { + for (var i = 0; i < msg.length; i++) { + var c = msg.charCodeAt(i); + var hi = c >> 8; + var lo = c & 0xff; + if (hi) + res.push(hi, lo); + else + res.push(lo); + } + } + return res; +} +utils.toArray = toArray; + +function zero2(word) { + if (word.length === 1) + return '0' + word; + else + return word; +} +utils.zero2 = zero2; + +function toHex(msg) { + var res = ''; + for (var i = 0; i < msg.length; i++) + res += zero2(msg[i].toString(16)); + return res; +} +utils.toHex = toHex; + +utils.encode = function encode(arr, enc) { + if (enc === 'hex') + return toHex(arr); + else + return arr; +}; + + +/***/ }), +/* 171 */ +/***/ (function(module, exports, __webpack_require__) { + +var r; + +module.exports = function rand(len) { + if (!r) + r = new Rand(null); + + return r.generate(len); +}; + +function Rand(rand) { + this.rand = rand; +} +module.exports.Rand = Rand; + +Rand.prototype.generate = function generate(len) { + return this._rand(len); +}; + +// Emulate crypto API using randy +Rand.prototype._rand = function _rand(n) { + if (this.rand.getBytes) + return this.rand.getBytes(n); + + var res = new Uint8Array(n); + for (var i = 0; i < res.length; i++) + res[i] = this.rand.getByte(); + return res; +}; + +if (typeof self === 'object') { + if (self.crypto && self.crypto.getRandomValues) { + // Modern browsers + Rand.prototype._rand = function _rand(n) { + var arr = new Uint8Array(n); + self.crypto.getRandomValues(arr); + return arr; + }; + } else if (self.msCrypto && self.msCrypto.getRandomValues) { + // IE + Rand.prototype._rand = function _rand(n) { + var arr = new Uint8Array(n); + self.msCrypto.getRandomValues(arr); + return arr; + }; + + // Safari's WebWorkers do not have `crypto` + } else if (typeof window === 'object') { + // Old junk + Rand.prototype._rand = function() { + throw new Error('Not implemented yet'); + }; + } +} else { + // Node.js or Web worker with no crypto support + try { + var crypto = __webpack_require__(387); + if (typeof crypto.randomBytes !== 'function') + throw new Error('Not supported'); + + Rand.prototype._rand = function _rand(n) { + return crypto.randomBytes(n); + }; + } catch (e) { + } +} + + +/***/ }), +/* 172 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var rotr32 = utils.rotr32; + +function ft_1(s, x, y, z) { + if (s === 0) + return ch32(x, y, z); + if (s === 1 || s === 3) + return p32(x, y, z); + if (s === 2) + return maj32(x, y, z); +} +exports.ft_1 = ft_1; + +function ch32(x, y, z) { + return (x & y) ^ ((~x) & z); +} +exports.ch32 = ch32; + +function maj32(x, y, z) { + return (x & y) ^ (x & z) ^ (y & z); +} +exports.maj32 = maj32; + +function p32(x, y, z) { + return x ^ y ^ z; +} +exports.p32 = p32; + +function s0_256(x) { + return rotr32(x, 2) ^ rotr32(x, 13) ^ rotr32(x, 22); +} +exports.s0_256 = s0_256; + +function s1_256(x) { + return rotr32(x, 6) ^ rotr32(x, 11) ^ rotr32(x, 25); +} +exports.s1_256 = s1_256; + +function g0_256(x) { + return rotr32(x, 7) ^ rotr32(x, 18) ^ (x >>> 3); +} +exports.g0_256 = g0_256; + +function g1_256(x) { + return rotr32(x, 17) ^ rotr32(x, 19) ^ (x >>> 10); +} +exports.g1_256 = g1_256; + + +/***/ }), +/* 173 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var shaCommon = __webpack_require__(172); +var assert = __webpack_require__(21); + +var sum32 = utils.sum32; +var sum32_4 = utils.sum32_4; +var sum32_5 = utils.sum32_5; +var ch32 = shaCommon.ch32; +var maj32 = shaCommon.maj32; +var s0_256 = shaCommon.s0_256; +var s1_256 = shaCommon.s1_256; +var g0_256 = shaCommon.g0_256; +var g1_256 = shaCommon.g1_256; + +var BlockHash = common.BlockHash; + +var sha256_K = [ + 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, + 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5, + 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, + 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174, + 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, + 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da, + 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, + 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967, + 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, + 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85, + 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, + 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070, + 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, + 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3, + 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, + 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2 +]; + +function SHA256() { + if (!(this instanceof SHA256)) + return new SHA256(); + + BlockHash.call(this); + this.h = [ + 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, + 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19 + ]; + this.k = sha256_K; + this.W = new Array(64); +} +utils.inherits(SHA256, BlockHash); +module.exports = SHA256; + +SHA256.blockSize = 512; +SHA256.outSize = 256; +SHA256.hmacStrength = 192; +SHA256.padLength = 64; + +SHA256.prototype._update = function _update(msg, start) { + var W = this.W; + + for (var i = 0; i < 16; i++) + W[i] = msg[start + i]; + for (; i < W.length; i++) + W[i] = sum32_4(g1_256(W[i - 2]), W[i - 7], g0_256(W[i - 15]), W[i - 16]); + + var a = this.h[0]; + var b = this.h[1]; + var c = this.h[2]; + var d = this.h[3]; + var e = this.h[4]; + var f = this.h[5]; + var g = this.h[6]; + var h = this.h[7]; + + assert(this.k.length === W.length); + for (i = 0; i < W.length; i++) { + var T1 = sum32_5(h, s1_256(e), ch32(e, f, g), this.k[i], W[i]); + var T2 = sum32(s0_256(a), maj32(a, b, c)); + h = g; + g = f; + f = e; + e = sum32(d, T1); + d = c; + c = b; + b = a; + a = sum32(T1, T2); + } + + this.h[0] = sum32(this.h[0], a); + this.h[1] = sum32(this.h[1], b); + this.h[2] = sum32(this.h[2], c); + this.h[3] = sum32(this.h[3], d); + this.h[4] = sum32(this.h[4], e); + this.h[5] = sum32(this.h[5], f); + this.h[6] = sum32(this.h[6], g); + this.h[7] = sum32(this.h[7], h); +}; + +SHA256.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'big'); + else + return utils.split32(this.h, 'big'); +}; + + +/***/ }), +/* 174 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var assert = __webpack_require__(21); + +var rotr64_hi = utils.rotr64_hi; +var rotr64_lo = utils.rotr64_lo; +var shr64_hi = utils.shr64_hi; +var shr64_lo = utils.shr64_lo; +var sum64 = utils.sum64; +var sum64_hi = utils.sum64_hi; +var sum64_lo = utils.sum64_lo; +var sum64_4_hi = utils.sum64_4_hi; +var sum64_4_lo = utils.sum64_4_lo; +var sum64_5_hi = utils.sum64_5_hi; +var sum64_5_lo = utils.sum64_5_lo; + +var BlockHash = common.BlockHash; + +var sha512_K = [ + 0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd, + 0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc, + 0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019, + 0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118, + 0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe, + 0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2, + 0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1, + 0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694, + 0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3, + 0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65, + 0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483, + 0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5, + 0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210, + 0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4, + 0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725, + 0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70, + 0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926, + 0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df, + 0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8, + 0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b, + 0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001, + 0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30, + 0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910, + 0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8, + 0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53, + 0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8, + 0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb, + 0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3, + 0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60, + 0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec, + 0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9, + 0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b, + 0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207, + 0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178, + 0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6, + 0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b, + 0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493, + 0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c, + 0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a, + 0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817 +]; + +function SHA512() { + if (!(this instanceof SHA512)) + return new SHA512(); + + BlockHash.call(this); + this.h = [ + 0x6a09e667, 0xf3bcc908, + 0xbb67ae85, 0x84caa73b, + 0x3c6ef372, 0xfe94f82b, + 0xa54ff53a, 0x5f1d36f1, + 0x510e527f, 0xade682d1, + 0x9b05688c, 0x2b3e6c1f, + 0x1f83d9ab, 0xfb41bd6b, + 0x5be0cd19, 0x137e2179 ]; + this.k = sha512_K; + this.W = new Array(160); +} +utils.inherits(SHA512, BlockHash); +module.exports = SHA512; + +SHA512.blockSize = 1024; +SHA512.outSize = 512; +SHA512.hmacStrength = 192; +SHA512.padLength = 128; + +SHA512.prototype._prepareBlock = function _prepareBlock(msg, start) { + var W = this.W; + + // 32 x 32bit words + for (var i = 0; i < 32; i++) + W[i] = msg[start + i]; + for (; i < W.length; i += 2) { + var c0_hi = g1_512_hi(W[i - 4], W[i - 3]); // i - 2 + var c0_lo = g1_512_lo(W[i - 4], W[i - 3]); + var c1_hi = W[i - 14]; // i - 7 + var c1_lo = W[i - 13]; + var c2_hi = g0_512_hi(W[i - 30], W[i - 29]); // i - 15 + var c2_lo = g0_512_lo(W[i - 30], W[i - 29]); + var c3_hi = W[i - 32]; // i - 16 + var c3_lo = W[i - 31]; + + W[i] = sum64_4_hi( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo); + W[i + 1] = sum64_4_lo( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo); + } +}; + +SHA512.prototype._update = function _update(msg, start) { + this._prepareBlock(msg, start); + + var W = this.W; + + var ah = this.h[0]; + var al = this.h[1]; + var bh = this.h[2]; + var bl = this.h[3]; + var ch = this.h[4]; + var cl = this.h[5]; + var dh = this.h[6]; + var dl = this.h[7]; + var eh = this.h[8]; + var el = this.h[9]; + var fh = this.h[10]; + var fl = this.h[11]; + var gh = this.h[12]; + var gl = this.h[13]; + var hh = this.h[14]; + var hl = this.h[15]; + + assert(this.k.length === W.length); + for (var i = 0; i < W.length; i += 2) { + var c0_hi = hh; + var c0_lo = hl; + var c1_hi = s1_512_hi(eh, el); + var c1_lo = s1_512_lo(eh, el); + var c2_hi = ch64_hi(eh, el, fh, fl, gh, gl); + var c2_lo = ch64_lo(eh, el, fh, fl, gh, gl); + var c3_hi = this.k[i]; + var c3_lo = this.k[i + 1]; + var c4_hi = W[i]; + var c4_lo = W[i + 1]; + + var T1_hi = sum64_5_hi( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo, + c4_hi, c4_lo); + var T1_lo = sum64_5_lo( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo, + c4_hi, c4_lo); + + c0_hi = s0_512_hi(ah, al); + c0_lo = s0_512_lo(ah, al); + c1_hi = maj64_hi(ah, al, bh, bl, ch, cl); + c1_lo = maj64_lo(ah, al, bh, bl, ch, cl); + + var T2_hi = sum64_hi(c0_hi, c0_lo, c1_hi, c1_lo); + var T2_lo = sum64_lo(c0_hi, c0_lo, c1_hi, c1_lo); + + hh = gh; + hl = gl; + + gh = fh; + gl = fl; + + fh = eh; + fl = el; + + eh = sum64_hi(dh, dl, T1_hi, T1_lo); + el = sum64_lo(dl, dl, T1_hi, T1_lo); + + dh = ch; + dl = cl; + + ch = bh; + cl = bl; + + bh = ah; + bl = al; + + ah = sum64_hi(T1_hi, T1_lo, T2_hi, T2_lo); + al = sum64_lo(T1_hi, T1_lo, T2_hi, T2_lo); + } + + sum64(this.h, 0, ah, al); + sum64(this.h, 2, bh, bl); + sum64(this.h, 4, ch, cl); + sum64(this.h, 6, dh, dl); + sum64(this.h, 8, eh, el); + sum64(this.h, 10, fh, fl); + sum64(this.h, 12, gh, gl); + sum64(this.h, 14, hh, hl); +}; + +SHA512.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'big'); + else + return utils.split32(this.h, 'big'); +}; + +function ch64_hi(xh, xl, yh, yl, zh) { + var r = (xh & yh) ^ ((~xh) & zh); + if (r < 0) + r += 0x100000000; + return r; +} + +function ch64_lo(xh, xl, yh, yl, zh, zl) { + var r = (xl & yl) ^ ((~xl) & zl); + if (r < 0) + r += 0x100000000; + return r; +} + +function maj64_hi(xh, xl, yh, yl, zh) { + var r = (xh & yh) ^ (xh & zh) ^ (yh & zh); + if (r < 0) + r += 0x100000000; + return r; +} + +function maj64_lo(xh, xl, yh, yl, zh, zl) { + var r = (xl & yl) ^ (xl & zl) ^ (yl & zl); + if (r < 0) + r += 0x100000000; + return r; +} + +function s0_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 28); + var c1_hi = rotr64_hi(xl, xh, 2); // 34 + var c2_hi = rotr64_hi(xl, xh, 7); // 39 + + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} + +function s0_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 28); + var c1_lo = rotr64_lo(xl, xh, 2); // 34 + var c2_lo = rotr64_lo(xl, xh, 7); // 39 + + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} + +function s1_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 14); + var c1_hi = rotr64_hi(xh, xl, 18); + var c2_hi = rotr64_hi(xl, xh, 9); // 41 + + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} + +function s1_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 14); + var c1_lo = rotr64_lo(xh, xl, 18); + var c2_lo = rotr64_lo(xl, xh, 9); // 41 + + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} + +function g0_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 1); + var c1_hi = rotr64_hi(xh, xl, 8); + var c2_hi = shr64_hi(xh, xl, 7); + + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} + +function g0_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 1); + var c1_lo = rotr64_lo(xh, xl, 8); + var c2_lo = shr64_lo(xh, xl, 7); + + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} + +function g1_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 19); + var c1_hi = rotr64_hi(xl, xh, 29); // 61 + var c2_hi = shr64_hi(xh, xl, 6); + + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} + +function g1_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 19); + var c1_lo = rotr64_lo(xl, xh, 29); // 61 + var c2_lo = shr64_lo(xh, xl, 6); + + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} + + +/***/ }), +/* 175 */ +/***/ (function(module, exports, __webpack_require__) { + +// (public) Constructor +function BigInteger(a, b, c) { + if (!(this instanceof BigInteger)) + return new BigInteger(a, b, c) + + if (a != null) { + if ("number" == typeof a) this.fromNumber(a, b, c) + else if (b == null && "string" != typeof a) this.fromString(a, 256) + else this.fromString(a, b) + } +} + +var proto = BigInteger.prototype + +// duck-typed isBigInteger +proto.__bigi = __webpack_require__(407).version +BigInteger.isBigInteger = function (obj, check_ver) { + return obj && obj.__bigi && (!check_ver || obj.__bigi === proto.__bigi) +} + +// Bits per digit +var dbits + +// am: Compute w_j += (x*this_i), propagate carries, +// c is initial carry, returns final carry. +// c < 3*dvalue, x < 2*dvalue, this_i < dvalue +// We need to select the fastest one that works in this environment. + +// am1: use a single mult and divide to get the high bits, +// max digit bits should be 26 because +// max internal value = 2*dvalue^2-2*dvalue (< 2^53) +function am1(i, x, w, j, c, n) { + while (--n >= 0) { + var v = x * this[i++] + w[j] + c + c = Math.floor(v / 0x4000000) + w[j++] = v & 0x3ffffff + } + return c +} +// am2 avoids a big mult-and-extract completely. +// Max digit bits should be <= 30 because we do bitwise ops +// on values up to 2*hdvalue^2-hdvalue-1 (< 2^31) +function am2(i, x, w, j, c, n) { + var xl = x & 0x7fff, + xh = x >> 15 + while (--n >= 0) { + var l = this[i] & 0x7fff + var h = this[i++] >> 15 + var m = xh * l + h * xl + l = xl * l + ((m & 0x7fff) << 15) + w[j] + (c & 0x3fffffff) + c = (l >>> 30) + (m >>> 15) + xh * h + (c >>> 30) + w[j++] = l & 0x3fffffff + } + return c +} +// Alternately, set max digit bits to 28 since some +// browsers slow down when dealing with 32-bit numbers. +function am3(i, x, w, j, c, n) { + var xl = x & 0x3fff, + xh = x >> 14 + while (--n >= 0) { + var l = this[i] & 0x3fff + var h = this[i++] >> 14 + var m = xh * l + h * xl + l = xl * l + ((m & 0x3fff) << 14) + w[j] + c + c = (l >> 28) + (m >> 14) + xh * h + w[j++] = l & 0xfffffff + } + return c +} + +// wtf? +BigInteger.prototype.am = am1 +dbits = 26 + +BigInteger.prototype.DB = dbits +BigInteger.prototype.DM = ((1 << dbits) - 1) +var DV = BigInteger.prototype.DV = (1 << dbits) + +var BI_FP = 52 +BigInteger.prototype.FV = Math.pow(2, BI_FP) +BigInteger.prototype.F1 = BI_FP - dbits +BigInteger.prototype.F2 = 2 * dbits - BI_FP + +// Digit conversions +var BI_RM = "0123456789abcdefghijklmnopqrstuvwxyz" +var BI_RC = new Array() +var rr, vv +rr = "0".charCodeAt(0) +for (vv = 0; vv <= 9; ++vv) BI_RC[rr++] = vv +rr = "a".charCodeAt(0) +for (vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv +rr = "A".charCodeAt(0) +for (vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv + +function int2char(n) { + return BI_RM.charAt(n) +} + +function intAt(s, i) { + var c = BI_RC[s.charCodeAt(i)] + return (c == null) ? -1 : c +} + +// (protected) copy this to r +function bnpCopyTo(r) { + for (var i = this.t - 1; i >= 0; --i) r[i] = this[i] + r.t = this.t + r.s = this.s +} + +// (protected) set from integer value x, -DV <= x < DV +function bnpFromInt(x) { + this.t = 1 + this.s = (x < 0) ? -1 : 0 + if (x > 0) this[0] = x + else if (x < -1) this[0] = x + DV + else this.t = 0 +} + +// return bigint initialized to value +function nbv(i) { + var r = new BigInteger() + r.fromInt(i) + return r +} + +// (protected) set from string and radix +function bnpFromString(s, b) { + var self = this + + var k + if (b == 16) k = 4 + else if (b == 8) k = 3 + else if (b == 256) k = 8; // byte array + else if (b == 2) k = 1 + else if (b == 32) k = 5 + else if (b == 4) k = 2 + else { + self.fromRadix(s, b) + return + } + self.t = 0 + self.s = 0 + var i = s.length, + mi = false, + sh = 0 + while (--i >= 0) { + var x = (k == 8) ? s[i] & 0xff : intAt(s, i) + if (x < 0) { + if (s.charAt(i) == "-") mi = true + continue + } + mi = false + if (sh == 0) + self[self.t++] = x + else if (sh + k > self.DB) { + self[self.t - 1] |= (x & ((1 << (self.DB - sh)) - 1)) << sh + self[self.t++] = (x >> (self.DB - sh)) + } else + self[self.t - 1] |= x << sh + sh += k + if (sh >= self.DB) sh -= self.DB + } + if (k == 8 && (s[0] & 0x80) != 0) { + self.s = -1 + if (sh > 0) self[self.t - 1] |= ((1 << (self.DB - sh)) - 1) << sh + } + self.clamp() + if (mi) BigInteger.ZERO.subTo(self, self) +} + +// (protected) clamp off excess high words +function bnpClamp() { + var c = this.s & this.DM + while (this.t > 0 && this[this.t - 1] == c)--this.t +} + +// (public) return string representation in given radix +function bnToString(b) { + var self = this + if (self.s < 0) return "-" + self.negate() + .toString(b) + var k + if (b == 16) k = 4 + else if (b == 8) k = 3 + else if (b == 2) k = 1 + else if (b == 32) k = 5 + else if (b == 4) k = 2 + else return self.toRadix(b) + var km = (1 << k) - 1, + d, m = false, + r = "", + i = self.t + var p = self.DB - (i * self.DB) % k + if (i-- > 0) { + if (p < self.DB && (d = self[i] >> p) > 0) { + m = true + r = int2char(d) + } + while (i >= 0) { + if (p < k) { + d = (self[i] & ((1 << p) - 1)) << (k - p) + d |= self[--i] >> (p += self.DB - k) + } else { + d = (self[i] >> (p -= k)) & km + if (p <= 0) { + p += self.DB + --i + } + } + if (d > 0) m = true + if (m) r += int2char(d) + } + } + return m ? r : "0" +} + +// (public) -this +function bnNegate() { + var r = new BigInteger() + BigInteger.ZERO.subTo(this, r) + return r +} + +// (public) |this| +function bnAbs() { + return (this.s < 0) ? this.negate() : this +} + +// (public) return + if this > a, - if this < a, 0 if equal +function bnCompareTo(a) { + var r = this.s - a.s + if (r != 0) return r + var i = this.t + r = i - a.t + if (r != 0) return (this.s < 0) ? -r : r + while (--i >= 0) + if ((r = this[i] - a[i]) != 0) return r + return 0 +} + +// returns bit length of the integer x +function nbits(x) { + var r = 1, + t + if ((t = x >>> 16) != 0) { + x = t + r += 16 + } + if ((t = x >> 8) != 0) { + x = t + r += 8 + } + if ((t = x >> 4) != 0) { + x = t + r += 4 + } + if ((t = x >> 2) != 0) { + x = t + r += 2 + } + if ((t = x >> 1) != 0) { + x = t + r += 1 + } + return r +} + +// (public) return the number of bits in "this" +function bnBitLength() { + if (this.t <= 0) return 0 + return this.DB * (this.t - 1) + nbits(this[this.t - 1] ^ (this.s & this.DM)) +} + +// (public) return the number of bytes in "this" +function bnByteLength() { + return this.bitLength() >> 3 +} + +// (protected) r = this << n*DB +function bnpDLShiftTo(n, r) { + var i + for (i = this.t - 1; i >= 0; --i) r[i + n] = this[i] + for (i = n - 1; i >= 0; --i) r[i] = 0 + r.t = this.t + n + r.s = this.s +} + +// (protected) r = this >> n*DB +function bnpDRShiftTo(n, r) { + for (var i = n; i < this.t; ++i) r[i - n] = this[i] + r.t = Math.max(this.t - n, 0) + r.s = this.s +} + +// (protected) r = this << n +function bnpLShiftTo(n, r) { + var self = this + var bs = n % self.DB + var cbs = self.DB - bs + var bm = (1 << cbs) - 1 + var ds = Math.floor(n / self.DB), + c = (self.s << bs) & self.DM, + i + for (i = self.t - 1; i >= 0; --i) { + r[i + ds + 1] = (self[i] >> cbs) | c + c = (self[i] & bm) << bs + } + for (i = ds - 1; i >= 0; --i) r[i] = 0 + r[ds] = c + r.t = self.t + ds + 1 + r.s = self.s + r.clamp() +} + +// (protected) r = this >> n +function bnpRShiftTo(n, r) { + var self = this + r.s = self.s + var ds = Math.floor(n / self.DB) + if (ds >= self.t) { + r.t = 0 + return + } + var bs = n % self.DB + var cbs = self.DB - bs + var bm = (1 << bs) - 1 + r[0] = self[ds] >> bs + for (var i = ds + 1; i < self.t; ++i) { + r[i - ds - 1] |= (self[i] & bm) << cbs + r[i - ds] = self[i] >> bs + } + if (bs > 0) r[self.t - ds - 1] |= (self.s & bm) << cbs + r.t = self.t - ds + r.clamp() +} + +// (protected) r = this - a +function bnpSubTo(a, r) { + var self = this + var i = 0, + c = 0, + m = Math.min(a.t, self.t) + while (i < m) { + c += self[i] - a[i] + r[i++] = c & self.DM + c >>= self.DB + } + if (a.t < self.t) { + c -= a.s + while (i < self.t) { + c += self[i] + r[i++] = c & self.DM + c >>= self.DB + } + c += self.s + } else { + c += self.s + while (i < a.t) { + c -= a[i] + r[i++] = c & self.DM + c >>= self.DB + } + c -= a.s + } + r.s = (c < 0) ? -1 : 0 + if (c < -1) r[i++] = self.DV + c + else if (c > 0) r[i++] = c + r.t = i + r.clamp() +} + +// (protected) r = this * a, r != this,a (HAC 14.12) +// "this" should be the larger one if appropriate. +function bnpMultiplyTo(a, r) { + var x = this.abs(), + y = a.abs() + var i = x.t + r.t = i + y.t + while (--i >= 0) r[i] = 0 + for (i = 0; i < y.t; ++i) r[i + x.t] = x.am(0, y[i], r, i, 0, x.t) + r.s = 0 + r.clamp() + if (this.s != a.s) BigInteger.ZERO.subTo(r, r) +} + +// (protected) r = this^2, r != this (HAC 14.16) +function bnpSquareTo(r) { + var x = this.abs() + var i = r.t = 2 * x.t + while (--i >= 0) r[i] = 0 + for (i = 0; i < x.t - 1; ++i) { + var c = x.am(i, x[i], r, 2 * i, 0, 1) + if ((r[i + x.t] += x.am(i + 1, 2 * x[i], r, 2 * i + 1, c, x.t - i - 1)) >= x.DV) { + r[i + x.t] -= x.DV + r[i + x.t + 1] = 1 + } + } + if (r.t > 0) r[r.t - 1] += x.am(i, x[i], r, 2 * i, 0, 1) + r.s = 0 + r.clamp() +} + +// (protected) divide this by m, quotient and remainder to q, r (HAC 14.20) +// r != q, this != m. q or r may be null. +function bnpDivRemTo(m, q, r) { + var self = this + var pm = m.abs() + if (pm.t <= 0) return + var pt = self.abs() + if (pt.t < pm.t) { + if (q != null) q.fromInt(0) + if (r != null) self.copyTo(r) + return + } + if (r == null) r = new BigInteger() + var y = new BigInteger(), + ts = self.s, + ms = m.s + var nsh = self.DB - nbits(pm[pm.t - 1]); // normalize modulus + if (nsh > 0) { + pm.lShiftTo(nsh, y) + pt.lShiftTo(nsh, r) + } else { + pm.copyTo(y) + pt.copyTo(r) + } + var ys = y.t + var y0 = y[ys - 1] + if (y0 == 0) return + var yt = y0 * (1 << self.F1) + ((ys > 1) ? y[ys - 2] >> self.F2 : 0) + var d1 = self.FV / yt, + d2 = (1 << self.F1) / yt, + e = 1 << self.F2 + var i = r.t, + j = i - ys, + t = (q == null) ? new BigInteger() : q + y.dlShiftTo(j, t) + if (r.compareTo(t) >= 0) { + r[r.t++] = 1 + r.subTo(t, r) + } + BigInteger.ONE.dlShiftTo(ys, t) + t.subTo(y, y); // "negative" y so we can replace sub with am later + while (y.t < ys) y[y.t++] = 0 + while (--j >= 0) { + // Estimate quotient digit + var qd = (r[--i] == y0) ? self.DM : Math.floor(r[i] * d1 + (r[i - 1] + e) * d2) + if ((r[i] += y.am(0, qd, r, j, 0, ys)) < qd) { // Try it out + y.dlShiftTo(j, t) + r.subTo(t, r) + while (r[i] < --qd) r.subTo(t, r) + } + } + if (q != null) { + r.drShiftTo(ys, q) + if (ts != ms) BigInteger.ZERO.subTo(q, q) + } + r.t = ys + r.clamp() + if (nsh > 0) r.rShiftTo(nsh, r); // Denormalize remainder + if (ts < 0) BigInteger.ZERO.subTo(r, r) +} + +// (public) this mod a +function bnMod(a) { + var r = new BigInteger() + this.abs() + .divRemTo(a, null, r) + if (this.s < 0 && r.compareTo(BigInteger.ZERO) > 0) a.subTo(r, r) + return r +} + +// Modular reduction using "classic" algorithm +function Classic(m) { + this.m = m +} + +function cConvert(x) { + if (x.s < 0 || x.compareTo(this.m) >= 0) return x.mod(this.m) + else return x +} + +function cRevert(x) { + return x +} + +function cReduce(x) { + x.divRemTo(this.m, null, x) +} + +function cMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) +} + +function cSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} + +Classic.prototype.convert = cConvert +Classic.prototype.revert = cRevert +Classic.prototype.reduce = cReduce +Classic.prototype.mulTo = cMulTo +Classic.prototype.sqrTo = cSqrTo + +// (protected) return "-1/this % 2^DB"; useful for Mont. reduction +// justification: +// xy == 1 (mod m) +// xy = 1+km +// xy(2-xy) = (1+km)(1-km) +// x[y(2-xy)] = 1-k^2m^2 +// x[y(2-xy)] == 1 (mod m^2) +// if y is 1/x mod m, then y(2-xy) is 1/x mod m^2 +// should reduce x and y(2-xy) by m^2 at each step to keep size bounded. +// JS multiply "overflows" differently from C/C++, so care is needed here. +function bnpInvDigit() { + if (this.t < 1) return 0 + var x = this[0] + if ((x & 1) == 0) return 0 + var y = x & 3; // y == 1/x mod 2^2 + y = (y * (2 - (x & 0xf) * y)) & 0xf; // y == 1/x mod 2^4 + y = (y * (2 - (x & 0xff) * y)) & 0xff; // y == 1/x mod 2^8 + y = (y * (2 - (((x & 0xffff) * y) & 0xffff))) & 0xffff; // y == 1/x mod 2^16 + // last step - calculate inverse mod DV directly + // assumes 16 < DB <= 32 and assumes ability to handle 48-bit ints + y = (y * (2 - x * y % this.DV)) % this.DV; // y == 1/x mod 2^dbits + // we really want the negative inverse, and -DV < y < DV + return (y > 0) ? this.DV - y : -y +} + +// Montgomery reduction +function Montgomery(m) { + this.m = m + this.mp = m.invDigit() + this.mpl = this.mp & 0x7fff + this.mph = this.mp >> 15 + this.um = (1 << (m.DB - 15)) - 1 + this.mt2 = 2 * m.t +} + +// xR mod m +function montConvert(x) { + var r = new BigInteger() + x.abs() + .dlShiftTo(this.m.t, r) + r.divRemTo(this.m, null, r) + if (x.s < 0 && r.compareTo(BigInteger.ZERO) > 0) this.m.subTo(r, r) + return r +} + +// x/R mod m +function montRevert(x) { + var r = new BigInteger() + x.copyTo(r) + this.reduce(r) + return r +} + +// x = x/R mod m (HAC 14.32) +function montReduce(x) { + while (x.t <= this.mt2) // pad x so am has enough room later + x[x.t++] = 0 + for (var i = 0; i < this.m.t; ++i) { + // faster way of calculating u0 = x[i]*mp mod DV + var j = x[i] & 0x7fff + var u0 = (j * this.mpl + (((j * this.mph + (x[i] >> 15) * this.mpl) & this.um) << 15)) & x.DM + // use am to combine the multiply-shift-add into one call + j = i + this.m.t + x[j] += this.m.am(0, u0, x, i, 0, this.m.t) + // propagate carry + while (x[j] >= x.DV) { + x[j] -= x.DV + x[++j]++ + } + } + x.clamp() + x.drShiftTo(this.m.t, x) + if (x.compareTo(this.m) >= 0) x.subTo(this.m, x) +} + +// r = "x^2/R mod m"; x != r +function montSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} + +// r = "xy/R mod m"; x,y != r +function montMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) +} + +Montgomery.prototype.convert = montConvert +Montgomery.prototype.revert = montRevert +Montgomery.prototype.reduce = montReduce +Montgomery.prototype.mulTo = montMulTo +Montgomery.prototype.sqrTo = montSqrTo + +// (protected) true iff this is even +function bnpIsEven() { + return ((this.t > 0) ? (this[0] & 1) : this.s) == 0 +} + +// (protected) this^e, e < 2^32, doing sqr and mul with "r" (HAC 14.79) +function bnpExp(e, z) { + if (e > 0xffffffff || e < 1) return BigInteger.ONE + var r = new BigInteger(), + r2 = new BigInteger(), + g = z.convert(this), + i = nbits(e) - 1 + g.copyTo(r) + while (--i >= 0) { + z.sqrTo(r, r2) + if ((e & (1 << i)) > 0) z.mulTo(r2, g, r) + else { + var t = r + r = r2 + r2 = t + } + } + return z.revert(r) +} + +// (public) this^e % m, 0 <= e < 2^32 +function bnModPowInt(e, m) { + var z + if (e < 256 || m.isEven()) z = new Classic(m) + else z = new Montgomery(m) + return this.exp(e, z) +} + +// protected +proto.copyTo = bnpCopyTo +proto.fromInt = bnpFromInt +proto.fromString = bnpFromString +proto.clamp = bnpClamp +proto.dlShiftTo = bnpDLShiftTo +proto.drShiftTo = bnpDRShiftTo +proto.lShiftTo = bnpLShiftTo +proto.rShiftTo = bnpRShiftTo +proto.subTo = bnpSubTo +proto.multiplyTo = bnpMultiplyTo +proto.squareTo = bnpSquareTo +proto.divRemTo = bnpDivRemTo +proto.invDigit = bnpInvDigit +proto.isEven = bnpIsEven +proto.exp = bnpExp + +// public +proto.toString = bnToString +proto.negate = bnNegate +proto.abs = bnAbs +proto.compareTo = bnCompareTo +proto.bitLength = bnBitLength +proto.byteLength = bnByteLength +proto.mod = bnMod +proto.modPowInt = bnModPowInt + +// (public) +function bnClone() { + var r = new BigInteger() + this.copyTo(r) + return r +} + +// (public) return value as integer +function bnIntValue() { + if (this.s < 0) { + if (this.t == 1) return this[0] - this.DV + else if (this.t == 0) return -1 + } else if (this.t == 1) return this[0] + else if (this.t == 0) return 0 + // assumes 16 < DB < 32 + return ((this[1] & ((1 << (32 - this.DB)) - 1)) << this.DB) | this[0] +} + +// (public) return value as byte +function bnByteValue() { + return (this.t == 0) ? this.s : (this[0] << 24) >> 24 +} + +// (public) return value as short (assumes DB>=16) +function bnShortValue() { + return (this.t == 0) ? this.s : (this[0] << 16) >> 16 +} + +// (protected) return x s.t. r^x < DV +function bnpChunkSize(r) { + return Math.floor(Math.LN2 * this.DB / Math.log(r)) +} + +// (public) 0 if this == 0, 1 if this > 0 +function bnSigNum() { + if (this.s < 0) return -1 + else if (this.t <= 0 || (this.t == 1 && this[0] <= 0)) return 0 + else return 1 +} + +// (protected) convert to radix string +function bnpToRadix(b) { + if (b == null) b = 10 + if (this.signum() == 0 || b < 2 || b > 36) return "0" + var cs = this.chunkSize(b) + var a = Math.pow(b, cs) + var d = nbv(a), + y = new BigInteger(), + z = new BigInteger(), + r = "" + this.divRemTo(d, y, z) + while (y.signum() > 0) { + r = (a + z.intValue()) + .toString(b) + .substr(1) + r + y.divRemTo(d, y, z) + } + return z.intValue() + .toString(b) + r +} + +// (protected) convert from radix string +function bnpFromRadix(s, b) { + var self = this + self.fromInt(0) + if (b == null) b = 10 + var cs = self.chunkSize(b) + var d = Math.pow(b, cs), + mi = false, + j = 0, + w = 0 + for (var i = 0; i < s.length; ++i) { + var x = intAt(s, i) + if (x < 0) { + if (s.charAt(i) == "-" && self.signum() == 0) mi = true + continue + } + w = b * w + x + if (++j >= cs) { + self.dMultiply(d) + self.dAddOffset(w, 0) + j = 0 + w = 0 + } + } + if (j > 0) { + self.dMultiply(Math.pow(b, j)) + self.dAddOffset(w, 0) + } + if (mi) BigInteger.ZERO.subTo(self, self) +} + +// (protected) alternate constructor +function bnpFromNumber(a, b, c) { + var self = this + if ("number" == typeof b) { + // new BigInteger(int,int,RNG) + if (a < 2) self.fromInt(1) + else { + self.fromNumber(a, c) + if (!self.testBit(a - 1)) // force MSB set + self.bitwiseTo(BigInteger.ONE.shiftLeft(a - 1), op_or, self) + if (self.isEven()) self.dAddOffset(1, 0); // force odd + while (!self.isProbablePrime(b)) { + self.dAddOffset(2, 0) + if (self.bitLength() > a) self.subTo(BigInteger.ONE.shiftLeft(a - 1), self) + } + } + } else { + // new BigInteger(int,RNG) + var x = new Array(), + t = a & 7 + x.length = (a >> 3) + 1 + b.nextBytes(x) + if (t > 0) x[0] &= ((1 << t) - 1) + else x[0] = 0 + self.fromString(x, 256) + } +} + +// (public) convert to bigendian byte array +function bnToByteArray() { + var self = this + var i = self.t, + r = new Array() + r[0] = self.s + var p = self.DB - (i * self.DB) % 8, + d, k = 0 + if (i-- > 0) { + if (p < self.DB && (d = self[i] >> p) != (self.s & self.DM) >> p) + r[k++] = d | (self.s << (self.DB - p)) + while (i >= 0) { + if (p < 8) { + d = (self[i] & ((1 << p) - 1)) << (8 - p) + d |= self[--i] >> (p += self.DB - 8) + } else { + d = (self[i] >> (p -= 8)) & 0xff + if (p <= 0) { + p += self.DB + --i + } + } + if ((d & 0x80) != 0) d |= -256 + if (k === 0 && (self.s & 0x80) != (d & 0x80))++k + if (k > 0 || d != self.s) r[k++] = d + } + } + return r +} + +function bnEquals(a) { + return (this.compareTo(a) == 0) +} + +function bnMin(a) { + return (this.compareTo(a) < 0) ? this : a +} + +function bnMax(a) { + return (this.compareTo(a) > 0) ? this : a +} + +// (protected) r = this op a (bitwise) +function bnpBitwiseTo(a, op, r) { + var self = this + var i, f, m = Math.min(a.t, self.t) + for (i = 0; i < m; ++i) r[i] = op(self[i], a[i]) + if (a.t < self.t) { + f = a.s & self.DM + for (i = m; i < self.t; ++i) r[i] = op(self[i], f) + r.t = self.t + } else { + f = self.s & self.DM + for (i = m; i < a.t; ++i) r[i] = op(f, a[i]) + r.t = a.t + } + r.s = op(self.s, a.s) + r.clamp() +} + +// (public) this & a +function op_and(x, y) { + return x & y +} + +function bnAnd(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_and, r) + return r +} + +// (public) this | a +function op_or(x, y) { + return x | y +} + +function bnOr(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_or, r) + return r +} + +// (public) this ^ a +function op_xor(x, y) { + return x ^ y +} + +function bnXor(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_xor, r) + return r +} + +// (public) this & ~a +function op_andnot(x, y) { + return x & ~y +} + +function bnAndNot(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_andnot, r) + return r +} + +// (public) ~this +function bnNot() { + var r = new BigInteger() + for (var i = 0; i < this.t; ++i) r[i] = this.DM & ~this[i] + r.t = this.t + r.s = ~this.s + return r +} + +// (public) this << n +function bnShiftLeft(n) { + var r = new BigInteger() + if (n < 0) this.rShiftTo(-n, r) + else this.lShiftTo(n, r) + return r +} + +// (public) this >> n +function bnShiftRight(n) { + var r = new BigInteger() + if (n < 0) this.lShiftTo(-n, r) + else this.rShiftTo(n, r) + return r +} + +// return index of lowest 1-bit in x, x < 2^31 +function lbit(x) { + if (x == 0) return -1 + var r = 0 + if ((x & 0xffff) == 0) { + x >>= 16 + r += 16 + } + if ((x & 0xff) == 0) { + x >>= 8 + r += 8 + } + if ((x & 0xf) == 0) { + x >>= 4 + r += 4 + } + if ((x & 3) == 0) { + x >>= 2 + r += 2 + } + if ((x & 1) == 0)++r + return r +} + +// (public) returns index of lowest 1-bit (or -1 if none) +function bnGetLowestSetBit() { + for (var i = 0; i < this.t; ++i) + if (this[i] != 0) return i * this.DB + lbit(this[i]) + if (this.s < 0) return this.t * this.DB + return -1 +} + +// return number of 1 bits in x +function cbit(x) { + var r = 0 + while (x != 0) { + x &= x - 1 + ++r + } + return r +} + +// (public) return number of set bits +function bnBitCount() { + var r = 0, + x = this.s & this.DM + for (var i = 0; i < this.t; ++i) r += cbit(this[i] ^ x) + return r +} + +// (public) true iff nth bit is set +function bnTestBit(n) { + var j = Math.floor(n / this.DB) + if (j >= this.t) return (this.s != 0) + return ((this[j] & (1 << (n % this.DB))) != 0) +} + +// (protected) this op (1<<n) +function bnpChangeBit(n, op) { + var r = BigInteger.ONE.shiftLeft(n) + this.bitwiseTo(r, op, r) + return r +} + +// (public) this | (1<<n) +function bnSetBit(n) { + return this.changeBit(n, op_or) +} + +// (public) this & ~(1<<n) +function bnClearBit(n) { + return this.changeBit(n, op_andnot) +} + +// (public) this ^ (1<<n) +function bnFlipBit(n) { + return this.changeBit(n, op_xor) +} + +// (protected) r = this + a +function bnpAddTo(a, r) { + var self = this + + var i = 0, + c = 0, + m = Math.min(a.t, self.t) + while (i < m) { + c += self[i] + a[i] + r[i++] = c & self.DM + c >>= self.DB + } + if (a.t < self.t) { + c += a.s + while (i < self.t) { + c += self[i] + r[i++] = c & self.DM + c >>= self.DB + } + c += self.s + } else { + c += self.s + while (i < a.t) { + c += a[i] + r[i++] = c & self.DM + c >>= self.DB + } + c += a.s + } + r.s = (c < 0) ? -1 : 0 + if (c > 0) r[i++] = c + else if (c < -1) r[i++] = self.DV + c + r.t = i + r.clamp() +} + +// (public) this + a +function bnAdd(a) { + var r = new BigInteger() + this.addTo(a, r) + return r +} + +// (public) this - a +function bnSubtract(a) { + var r = new BigInteger() + this.subTo(a, r) + return r +} + +// (public) this * a +function bnMultiply(a) { + var r = new BigInteger() + this.multiplyTo(a, r) + return r +} + +// (public) this^2 +function bnSquare() { + var r = new BigInteger() + this.squareTo(r) + return r +} + +// (public) this / a +function bnDivide(a) { + var r = new BigInteger() + this.divRemTo(a, r, null) + return r +} + +// (public) this % a +function bnRemainder(a) { + var r = new BigInteger() + this.divRemTo(a, null, r) + return r +} + +// (public) [this/a,this%a] +function bnDivideAndRemainder(a) { + var q = new BigInteger(), + r = new BigInteger() + this.divRemTo(a, q, r) + return new Array(q, r) +} + +// (protected) this *= n, this >= 0, 1 < n < DV +function bnpDMultiply(n) { + this[this.t] = this.am(0, n - 1, this, 0, 0, this.t) + ++this.t + this.clamp() +} + +// (protected) this += n << w words, this >= 0 +function bnpDAddOffset(n, w) { + if (n == 0) return + while (this.t <= w) this[this.t++] = 0 + this[w] += n + while (this[w] >= this.DV) { + this[w] -= this.DV + if (++w >= this.t) this[this.t++] = 0 + ++this[w] + } +} + +// A "null" reducer +function NullExp() {} + +function nNop(x) { + return x +} + +function nMulTo(x, y, r) { + x.multiplyTo(y, r) +} + +function nSqrTo(x, r) { + x.squareTo(r) +} + +NullExp.prototype.convert = nNop +NullExp.prototype.revert = nNop +NullExp.prototype.mulTo = nMulTo +NullExp.prototype.sqrTo = nSqrTo + +// (public) this^e +function bnPow(e) { + return this.exp(e, new NullExp()) +} + +// (protected) r = lower n words of "this * a", a.t <= n +// "this" should be the larger one if appropriate. +function bnpMultiplyLowerTo(a, n, r) { + var i = Math.min(this.t + a.t, n) + r.s = 0; // assumes a,this >= 0 + r.t = i + while (i > 0) r[--i] = 0 + var j + for (j = r.t - this.t; i < j; ++i) r[i + this.t] = this.am(0, a[i], r, i, 0, this.t) + for (j = Math.min(a.t, n); i < j; ++i) this.am(0, a[i], r, i, 0, n - i) + r.clamp() +} + +// (protected) r = "this * a" without lower n words, n > 0 +// "this" should be the larger one if appropriate. +function bnpMultiplyUpperTo(a, n, r) { + --n + var i = r.t = this.t + a.t - n + r.s = 0; // assumes a,this >= 0 + while (--i >= 0) r[i] = 0 + for (i = Math.max(n - this.t, 0); i < a.t; ++i) + r[this.t + i - n] = this.am(n - i, a[i], r, 0, 0, this.t + i - n) + r.clamp() + r.drShiftTo(1, r) +} + +// Barrett modular reduction +function Barrett(m) { + // setup Barrett + this.r2 = new BigInteger() + this.q3 = new BigInteger() + BigInteger.ONE.dlShiftTo(2 * m.t, this.r2) + this.mu = this.r2.divide(m) + this.m = m +} + +function barrettConvert(x) { + if (x.s < 0 || x.t > 2 * this.m.t) return x.mod(this.m) + else if (x.compareTo(this.m) < 0) return x + else { + var r = new BigInteger() + x.copyTo(r) + this.reduce(r) + return r + } +} + +function barrettRevert(x) { + return x +} + +// x = x mod m (HAC 14.42) +function barrettReduce(x) { + var self = this + x.drShiftTo(self.m.t - 1, self.r2) + if (x.t > self.m.t + 1) { + x.t = self.m.t + 1 + x.clamp() + } + self.mu.multiplyUpperTo(self.r2, self.m.t + 1, self.q3) + self.m.multiplyLowerTo(self.q3, self.m.t + 1, self.r2) + while (x.compareTo(self.r2) < 0) x.dAddOffset(1, self.m.t + 1) + x.subTo(self.r2, x) + while (x.compareTo(self.m) >= 0) x.subTo(self.m, x) +} + +// r = x^2 mod m; x != r +function barrettSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} + +// r = x*y mod m; x,y != r +function barrettMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) +} + +Barrett.prototype.convert = barrettConvert +Barrett.prototype.revert = barrettRevert +Barrett.prototype.reduce = barrettReduce +Barrett.prototype.mulTo = barrettMulTo +Barrett.prototype.sqrTo = barrettSqrTo + +// (public) this^e % m (HAC 14.85) +function bnModPow(e, m) { + var i = e.bitLength(), + k, r = nbv(1), + z + if (i <= 0) return r + else if (i < 18) k = 1 + else if (i < 48) k = 3 + else if (i < 144) k = 4 + else if (i < 768) k = 5 + else k = 6 + if (i < 8) + z = new Classic(m) + else if (m.isEven()) + z = new Barrett(m) + else + z = new Montgomery(m) + + // precomputation + var g = new Array(), + n = 3, + k1 = k - 1, + km = (1 << k) - 1 + g[1] = z.convert(this) + if (k > 1) { + var g2 = new BigInteger() + z.sqrTo(g[1], g2) + while (n <= km) { + g[n] = new BigInteger() + z.mulTo(g2, g[n - 2], g[n]) + n += 2 + } + } + + var j = e.t - 1, + w, is1 = true, + r2 = new BigInteger(), + t + i = nbits(e[j]) - 1 + while (j >= 0) { + if (i >= k1) w = (e[j] >> (i - k1)) & km + else { + w = (e[j] & ((1 << (i + 1)) - 1)) << (k1 - i) + if (j > 0) w |= e[j - 1] >> (this.DB + i - k1) + } + + n = k + while ((w & 1) == 0) { + w >>= 1 + --n + } + if ((i -= n) < 0) { + i += this.DB + --j + } + if (is1) { // ret == 1, don't bother squaring or multiplying it + g[w].copyTo(r) + is1 = false + } else { + while (n > 1) { + z.sqrTo(r, r2) + z.sqrTo(r2, r) + n -= 2 + } + if (n > 0) z.sqrTo(r, r2) + else { + t = r + r = r2 + r2 = t + } + z.mulTo(r2, g[w], r) + } + + while (j >= 0 && (e[j] & (1 << i)) == 0) { + z.sqrTo(r, r2) + t = r + r = r2 + r2 = t + if (--i < 0) { + i = this.DB - 1 + --j + } + } + } + return z.revert(r) +} + +// (public) gcd(this,a) (HAC 14.54) +function bnGCD(a) { + var x = (this.s < 0) ? this.negate() : this.clone() + var y = (a.s < 0) ? a.negate() : a.clone() + if (x.compareTo(y) < 0) { + var t = x + x = y + y = t + } + var i = x.getLowestSetBit(), + g = y.getLowestSetBit() + if (g < 0) return x + if (i < g) g = i + if (g > 0) { + x.rShiftTo(g, x) + y.rShiftTo(g, y) + } + while (x.signum() > 0) { + if ((i = x.getLowestSetBit()) > 0) x.rShiftTo(i, x) + if ((i = y.getLowestSetBit()) > 0) y.rShiftTo(i, y) + if (x.compareTo(y) >= 0) { + x.subTo(y, x) + x.rShiftTo(1, x) + } else { + y.subTo(x, y) + y.rShiftTo(1, y) + } + } + if (g > 0) y.lShiftTo(g, y) + return y +} + +// (protected) this % n, n < 2^26 +function bnpModInt(n) { + if (n <= 0) return 0 + var d = this.DV % n, + r = (this.s < 0) ? n - 1 : 0 + if (this.t > 0) + if (d == 0) r = this[0] % n + else + for (var i = this.t - 1; i >= 0; --i) r = (d * r + this[i]) % n + return r +} + +// (public) 1/this % m (HAC 14.61) +function bnModInverse(m) { + var ac = m.isEven() + if (this.signum() === 0) throw new Error('division by zero') + if ((this.isEven() && ac) || m.signum() == 0) return BigInteger.ZERO + var u = m.clone(), + v = this.clone() + var a = nbv(1), + b = nbv(0), + c = nbv(0), + d = nbv(1) + while (u.signum() != 0) { + while (u.isEven()) { + u.rShiftTo(1, u) + if (ac) { + if (!a.isEven() || !b.isEven()) { + a.addTo(this, a) + b.subTo(m, b) + } + a.rShiftTo(1, a) + } else if (!b.isEven()) b.subTo(m, b) + b.rShiftTo(1, b) + } + while (v.isEven()) { + v.rShiftTo(1, v) + if (ac) { + if (!c.isEven() || !d.isEven()) { + c.addTo(this, c) + d.subTo(m, d) + } + c.rShiftTo(1, c) + } else if (!d.isEven()) d.subTo(m, d) + d.rShiftTo(1, d) + } + if (u.compareTo(v) >= 0) { + u.subTo(v, u) + if (ac) a.subTo(c, a) + b.subTo(d, b) + } else { + v.subTo(u, v) + if (ac) c.subTo(a, c) + d.subTo(b, d) + } + } + if (v.compareTo(BigInteger.ONE) != 0) return BigInteger.ZERO + while (d.compareTo(m) >= 0) d.subTo(m, d) + while (d.signum() < 0) d.addTo(m, d) + return d +} + +var lowprimes = [ + 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, + 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, + 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, + 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307, 311, 313, 317, + 331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409, 419, + 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, + 509, 521, 523, 541, 547, 557, 563, 569, 571, 577, 587, 593, 599, 601, 607, + 613, 617, 619, 631, 641, 643, 647, 653, 659, 661, 673, 677, 683, 691, 701, + 709, 719, 727, 733, 739, 743, 751, 757, 761, 769, 773, 787, 797, 809, 811, + 821, 823, 827, 829, 839, 853, 857, 859, 863, 877, 881, 883, 887, 907, 911, + 919, 929, 937, 941, 947, 953, 967, 971, 977, 983, 991, 997 +] + +var lplim = (1 << 26) / lowprimes[lowprimes.length - 1] + +// (public) test primality with certainty >= 1-.5^t +function bnIsProbablePrime(t) { + var i, x = this.abs() + if (x.t == 1 && x[0] <= lowprimes[lowprimes.length - 1]) { + for (i = 0; i < lowprimes.length; ++i) + if (x[0] == lowprimes[i]) return true + return false + } + if (x.isEven()) return false + i = 1 + while (i < lowprimes.length) { + var m = lowprimes[i], + j = i + 1 + while (j < lowprimes.length && m < lplim) m *= lowprimes[j++] + m = x.modInt(m) + while (i < j) if (m % lowprimes[i++] == 0) return false + } + return x.millerRabin(t) +} + +// (protected) true if probably prime (HAC 4.24, Miller-Rabin) +function bnpMillerRabin(t) { + var n1 = this.subtract(BigInteger.ONE) + var k = n1.getLowestSetBit() + if (k <= 0) return false + var r = n1.shiftRight(k) + t = (t + 1) >> 1 + if (t > lowprimes.length) t = lowprimes.length + var a = new BigInteger(null) + var j, bases = [] + for (var i = 0; i < t; ++i) { + for (;;) { + j = lowprimes[Math.floor(Math.random() * lowprimes.length)] + if (bases.indexOf(j) == -1) break + } + bases.push(j) + a.fromInt(j) + var y = a.modPow(r, this) + if (y.compareTo(BigInteger.ONE) != 0 && y.compareTo(n1) != 0) { + var j = 1 + while (j++ < k && y.compareTo(n1) != 0) { + y = y.modPowInt(2, this) + if (y.compareTo(BigInteger.ONE) == 0) return false + } + if (y.compareTo(n1) != 0) return false + } + } + return true +} + +// protected +proto.chunkSize = bnpChunkSize +proto.toRadix = bnpToRadix +proto.fromRadix = bnpFromRadix +proto.fromNumber = bnpFromNumber +proto.bitwiseTo = bnpBitwiseTo +proto.changeBit = bnpChangeBit +proto.addTo = bnpAddTo +proto.dMultiply = bnpDMultiply +proto.dAddOffset = bnpDAddOffset +proto.multiplyLowerTo = bnpMultiplyLowerTo +proto.multiplyUpperTo = bnpMultiplyUpperTo +proto.modInt = bnpModInt +proto.millerRabin = bnpMillerRabin + +// public +proto.clone = bnClone +proto.intValue = bnIntValue +proto.byteValue = bnByteValue +proto.shortValue = bnShortValue +proto.signum = bnSigNum +proto.toByteArray = bnToByteArray +proto.equals = bnEquals +proto.min = bnMin +proto.max = bnMax +proto.and = bnAnd +proto.or = bnOr +proto.xor = bnXor +proto.andNot = bnAndNot +proto.not = bnNot +proto.shiftLeft = bnShiftLeft +proto.shiftRight = bnShiftRight +proto.getLowestSetBit = bnGetLowestSetBit +proto.bitCount = bnBitCount +proto.testBit = bnTestBit +proto.setBit = bnSetBit +proto.clearBit = bnClearBit +proto.flipBit = bnFlipBit +proto.add = bnAdd +proto.subtract = bnSubtract +proto.multiply = bnMultiply +proto.divide = bnDivide +proto.remainder = bnRemainder +proto.divideAndRemainder = bnDivideAndRemainder +proto.modPow = bnModPow +proto.modInverse = bnModInverse +proto.pow = bnPow +proto.gcd = bnGCD +proto.isProbablePrime = bnIsProbablePrime + +// JSBN-specific extension +proto.square = bnSquare + +// constants +BigInteger.ZERO = nbv(0) +BigInteger.ONE = nbv(1) +BigInteger.valueOf = nbv + +module.exports = BigInteger + + +/***/ }), +/* 176 */ +/***/ (function(module, exports) { + +module.exports = { + "sha224WithRSAEncryption": { + "sign": "rsa", + "hash": "sha224", + "id": "302d300d06096086480165030402040500041c" + }, + "RSA-SHA224": { + "sign": "ecdsa/rsa", + "hash": "sha224", + "id": "302d300d06096086480165030402040500041c" + }, + "sha256WithRSAEncryption": { + "sign": "rsa", + "hash": "sha256", + "id": "3031300d060960864801650304020105000420" + }, + "RSA-SHA256": { + "sign": "ecdsa/rsa", + "hash": "sha256", + "id": "3031300d060960864801650304020105000420" + }, + "sha384WithRSAEncryption": { + "sign": "rsa", + "hash": "sha384", + "id": "3041300d060960864801650304020205000430" + }, + "RSA-SHA384": { + "sign": "ecdsa/rsa", + "hash": "sha384", + "id": "3041300d060960864801650304020205000430" + }, + "sha512WithRSAEncryption": { + "sign": "rsa", + "hash": "sha512", + "id": "3051300d060960864801650304020305000440" + }, + "RSA-SHA512": { + "sign": "ecdsa/rsa", + "hash": "sha512", + "id": "3051300d060960864801650304020305000440" + }, + "RSA-SHA1": { + "sign": "rsa", + "hash": "sha1", + "id": "3021300906052b0e03021a05000414" + }, + "ecdsa-with-SHA1": { + "sign": "ecdsa", + "hash": "sha1", + "id": "" + }, + "sha256": { + "sign": "ecdsa", + "hash": "sha256", + "id": "" + }, + "sha224": { + "sign": "ecdsa", + "hash": "sha224", + "id": "" + }, + "sha384": { + "sign": "ecdsa", + "hash": "sha384", + "id": "" + }, + "sha512": { + "sign": "ecdsa", + "hash": "sha512", + "id": "" + }, + "DSA-SHA": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA-SHA1": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA-WITH-SHA224": { + "sign": "dsa", + "hash": "sha224", + "id": "" + }, + "DSA-SHA224": { + "sign": "dsa", + "hash": "sha224", + "id": "" + }, + "DSA-WITH-SHA256": { + "sign": "dsa", + "hash": "sha256", + "id": "" + }, + "DSA-SHA256": { + "sign": "dsa", + "hash": "sha256", + "id": "" + }, + "DSA-WITH-SHA384": { + "sign": "dsa", + "hash": "sha384", + "id": "" + }, + "DSA-SHA384": { + "sign": "dsa", + "hash": "sha384", + "id": "" + }, + "DSA-WITH-SHA512": { + "sign": "dsa", + "hash": "sha512", + "id": "" + }, + "DSA-SHA512": { + "sign": "dsa", + "hash": "sha512", + "id": "" + }, + "DSA-RIPEMD160": { + "sign": "dsa", + "hash": "rmd160", + "id": "" + }, + "ripemd160WithRSA": { + "sign": "rsa", + "hash": "rmd160", + "id": "3021300906052b2403020105000414" + }, + "RSA-RIPEMD160": { + "sign": "rsa", + "hash": "rmd160", + "id": "3021300906052b2403020105000414" + }, + "md5WithRSAEncryption": { + "sign": "rsa", + "hash": "md5", + "id": "3020300c06082a864886f70d020505000410" + }, + "RSA-MD5": { + "sign": "rsa", + "hash": "md5", + "id": "3020300c06082a864886f70d020505000410" + } +}; + +/***/ }), +/* 177 */ +/***/ (function(module, exports, __webpack_require__) { + + +exports.pbkdf2 = __webpack_require__(422) + +exports.pbkdf2Sync = __webpack_require__(180) + + +/***/ }), +/* 178 */ +/***/ (function(module, exports) { + +var MAX_ALLOC = Math.pow(2, 30) - 1 // default in iojs +module.exports = function (iterations, keylen) { + if (typeof iterations !== 'number') { + throw new TypeError('Iterations not a number') + } + + if (iterations < 0) { + throw new TypeError('Bad iterations') + } + + if (typeof keylen !== 'number') { + throw new TypeError('Key length not a number') + } + + if (keylen < 0 || keylen > MAX_ALLOC || keylen !== keylen) { /* eslint no-self-compare: 0 */ + throw new TypeError('Bad key length') + } +} + + +/***/ }), +/* 179 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(process) {var defaultEncoding +/* istanbul ignore next */ +if (process.browser) { + defaultEncoding = 'utf-8' +} else { + var pVersionMajor = parseInt(process.version.split('.')[0].slice(1), 10) + + defaultEncoding = pVersionMajor >= 6 ? 'utf-8' : 'binary' +} +module.exports = defaultEncoding + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 180 */ +/***/ (function(module, exports, __webpack_require__) { + +var md5 = __webpack_require__(63) +var rmd160 = __webpack_require__(97) +var sha = __webpack_require__(103) + +var checkParameters = __webpack_require__(178) +var defaultEncoding = __webpack_require__(179) +var Buffer = __webpack_require__(7).Buffer +var ZEROS = Buffer.alloc(128) +var sizes = { + md5: 16, + sha1: 20, + sha224: 28, + sha256: 32, + sha384: 48, + sha512: 64, + rmd160: 20, + ripemd160: 20 +} +function Hmac (alg, key, saltLen) { + var hash = getDigest(alg) + var blocksize = (alg === 'sha512' || alg === 'sha384') ? 128 : 64 + + if (key.length > blocksize) { + key = hash(key) + } else if (key.length < blocksize) { + key = Buffer.concat([key, ZEROS], blocksize) + } + + var ipad = Buffer.allocUnsafe(blocksize + sizes[alg]) + var opad = Buffer.allocUnsafe(blocksize + sizes[alg]) + for (var i = 0; i < blocksize; i++) { + ipad[i] = key[i] ^ 0x36 + opad[i] = key[i] ^ 0x5C + } + + var ipad1 = Buffer.allocUnsafe(blocksize + saltLen + 4) + ipad.copy(ipad1, 0, 0, blocksize) + this.ipad1 = ipad1 + this.ipad2 = ipad + this.opad = opad + this.alg = alg + this.blocksize = blocksize + this.hash = hash + this.size = sizes[alg] +} + +Hmac.prototype.run = function (data, ipad) { + data.copy(ipad, this.blocksize) + var h = this.hash(ipad) + h.copy(this.opad, this.blocksize) + return this.hash(this.opad) +} + +function getDigest (alg) { + if (alg === 'rmd160' || alg === 'ripemd160') return rmd160 + if (alg === 'md5') return md5 + return shaFunc + + function shaFunc (data) { + return sha(alg).update(data).digest() + } +} + +module.exports = function (password, salt, iterations, keylen, digest) { + if (!Buffer.isBuffer(password)) password = Buffer.from(password, defaultEncoding) + if (!Buffer.isBuffer(salt)) salt = Buffer.from(salt, defaultEncoding) + + checkParameters(iterations, keylen) + + digest = digest || 'sha1' + + var hmac = new Hmac(digest, password, salt.length) + + var DK = Buffer.allocUnsafe(keylen) + var block1 = Buffer.allocUnsafe(salt.length + 4) + salt.copy(block1, 0, 0, salt.length) + + var U, j, destPos, len + + var hLen = hmac.size + var T = Buffer.allocUnsafe(hLen) + var l = Math.ceil(keylen / hLen) + var r = keylen - (l - 1) * hLen + + for (var i = 1; i <= l; i++) { + block1.writeUInt32BE(i, salt.length) + U = hmac.run(block1, hmac.ipad1) + + U.copy(T, 0, 0, hLen) + + for (j = 1; j < iterations; j++) { + U = hmac.run(U, hmac.ipad2) + for (var k = 0; k < hLen; k++) T[k] ^= U[k] + } + + destPos = (i - 1) * hLen + len = (i === l ? r : hLen) + T.copy(DK, destPos, 0, len) + } + + return DK +} + + +/***/ }), +/* 181 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) + +inherits(StreamCipher, Transform) +module.exports = StreamCipher +function StreamCipher (mode, key, iv, decrypt) { + if (!(this instanceof StreamCipher)) { + return new StreamCipher(mode, key, iv) + } + Transform.call(this) + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + this._cache = new Buffer('') + this._secCache = new Buffer('') + this._decrypt = decrypt + iv.copy(this._prev) + this._mode = mode +} +StreamCipher.prototype._update = function (chunk) { + return this._mode.encrypt(this, chunk, this._decrypt) +} +StreamCipher.prototype._final = function () { + this._cipher.scrub() +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 182 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var GHASH = __webpack_require__(425) +var xor = __webpack_require__(51) +inherits(StreamCipher, Transform) +module.exports = StreamCipher + +function StreamCipher (mode, key, iv, decrypt) { + if (!(this instanceof StreamCipher)) { + return new StreamCipher(mode, key, iv) + } + Transform.call(this) + this._finID = Buffer.concat([iv, new Buffer([0, 0, 0, 1])]) + iv = Buffer.concat([iv, new Buffer([0, 0, 0, 2])]) + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + this._cache = new Buffer('') + this._secCache = new Buffer('') + this._decrypt = decrypt + this._alen = 0 + this._len = 0 + iv.copy(this._prev) + this._mode = mode + var h = new Buffer(4) + h.fill(0) + this._ghash = new GHASH(this._cipher.encryptBlock(h)) + this._authTag = null + this._called = false +} +StreamCipher.prototype._update = function (chunk) { + if (!this._called && this._alen) { + var rump = 16 - (this._alen % 16) + if (rump < 16) { + rump = new Buffer(rump) + rump.fill(0) + this._ghash.update(rump) + } + } + this._called = true + var out = this._mode.encrypt(this, chunk) + if (this._decrypt) { + this._ghash.update(chunk) + } else { + this._ghash.update(out) + } + this._len += chunk.length + return out +} +StreamCipher.prototype._final = function () { + if (this._decrypt && !this._authTag) { + throw new Error('Unsupported state or unable to authenticate data') + } + var tag = xor(this._ghash.final(this._alen * 8, this._len * 8), this._cipher.encryptBlock(this._finID)) + if (this._decrypt) { + if (xorTest(tag, this._authTag)) { + throw new Error('Unsupported state or unable to authenticate data') + } + } else { + this._authTag = tag + } + this._cipher.scrub() +} +StreamCipher.prototype.getAuthTag = function getAuthTag () { + if (!this._decrypt && Buffer.isBuffer(this._authTag)) { + return this._authTag + } else { + throw new Error('Attempting to get auth tag in unsupported state') + } +} +StreamCipher.prototype.setAuthTag = function setAuthTag (tag) { + if (this._decrypt) { + this._authTag = tag + } else { + throw new Error('Attempting to set auth tag in unsupported state') + } +} +StreamCipher.prototype.setAAD = function setAAD (buf) { + if (!this._called) { + this._ghash.update(buf) + this._alen += buf.length + } else { + throw new Error('Attempting to set AAD in unsupported state') + } +} +function xorTest (a, b) { + var out = 0 + if (a.length !== b.length) { + out++ + } + var len = Math.min(a.length, b.length) + var i = -1 + while (++i < len) { + out += (a[i] ^ b[i]) + } + return out +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 183 */ +/***/ (function(module, exports) { + +exports.encrypt = function (self, block) { + return self._cipher.encryptBlock(block) +} +exports.decrypt = function (self, block) { + return self._cipher.decryptBlock(block) +} + + +/***/ }), +/* 184 */ +/***/ (function(module, exports, __webpack_require__) { + +var xor = __webpack_require__(51) + +exports.encrypt = function (self, block) { + var data = xor(block, self._prev) + + self._prev = self._cipher.encryptBlock(data) + return self._prev +} + +exports.decrypt = function (self, block) { + var pad = self._prev + + self._prev = block + var out = self._cipher.decryptBlock(block) + + return xor(out, pad) +} + + +/***/ }), +/* 185 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) + +exports.encrypt = function (self, data, decrypt) { + var out = new Buffer('') + var len + + while (data.length) { + if (self._cache.length === 0) { + self._cache = self._cipher.encryptBlock(self._prev) + self._prev = new Buffer('') + } + + if (self._cache.length <= data.length) { + len = self._cache.length + out = Buffer.concat([out, encryptStart(self, data.slice(0, len), decrypt)]) + data = data.slice(len) + } else { + out = Buffer.concat([out, encryptStart(self, data, decrypt)]) + break + } + } + + return out +} +function encryptStart (self, data, decrypt) { + var len = data.length + var out = xor(data, self._cache) + self._cache = self._cache.slice(len) + self._prev = Buffer.concat([self._prev, decrypt ? data : out]) + return out +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 186 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {function encryptByte (self, byteParam, decrypt) { + var pad = self._cipher.encryptBlock(self._prev) + var out = pad[0] ^ byteParam + self._prev = Buffer.concat([self._prev.slice(1), new Buffer([decrypt ? byteParam : out])]) + return out +} +exports.encrypt = function (self, chunk, decrypt) { + var len = chunk.length + var out = new Buffer(len) + var i = -1 + while (++i < len) { + out[i] = encryptByte(self, chunk[i], decrypt) + } + return out +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 187 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {function encryptByte (self, byteParam, decrypt) { + var pad + var i = -1 + var len = 8 + var out = 0 + var bit, value + while (++i < len) { + pad = self._cipher.encryptBlock(self._prev) + bit = (byteParam & (1 << (7 - i))) ? 0x80 : 0 + value = pad[0] ^ bit + out += ((value & 0x80) >> (i % 8)) + self._prev = shiftIn(self._prev, decrypt ? bit : value) + } + return out +} +exports.encrypt = function (self, chunk, decrypt) { + var len = chunk.length + var out = new Buffer(len) + var i = -1 + while (++i < len) { + out[i] = encryptByte(self, chunk[i], decrypt) + } + return out +} +function shiftIn (buffer, value) { + var len = buffer.length + var i = -1 + var out = new Buffer(buffer.length) + buffer = Buffer.concat([buffer, new Buffer([value])]) + while (++i < len) { + out[i] = buffer[i] << 1 | buffer[i + 1] >> (7) + } + return out +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 188 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) + +function getBlock (self) { + self._prev = self._cipher.encryptBlock(self._prev) + return self._prev +} + +exports.encrypt = function (self, chunk) { + while (self._cache.length < chunk.length) { + self._cache = Buffer.concat([self._cache, getBlock(self)]) + } + + var pad = self._cache.slice(0, chunk.length) + self._cache = self._cache.slice(chunk.length) + return xor(chunk, pad) +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 189 */ +/***/ (function(module, exports, __webpack_require__) { + +var randomBytes = __webpack_require__(43); +module.exports = findPrime; +findPrime.simpleSieve = simpleSieve; +findPrime.fermatTest = fermatTest; +var BN = __webpack_require__(11); +var TWENTYFOUR = new BN(24); +var MillerRabin = __webpack_require__(190); +var millerRabin = new MillerRabin(); +var ONE = new BN(1); +var TWO = new BN(2); +var FIVE = new BN(5); +var SIXTEEN = new BN(16); +var EIGHT = new BN(8); +var TEN = new BN(10); +var THREE = new BN(3); +var SEVEN = new BN(7); +var ELEVEN = new BN(11); +var FOUR = new BN(4); +var TWELVE = new BN(12); +var primes = null; + +function _getPrimes() { + if (primes !== null) + return primes; + + var limit = 0x100000; + var res = []; + res[0] = 2; + for (var i = 1, k = 3; k < limit; k += 2) { + var sqrt = Math.ceil(Math.sqrt(k)); + for (var j = 0; j < i && res[j] <= sqrt; j++) + if (k % res[j] === 0) + break; + + if (i !== j && res[j] <= sqrt) + continue; + + res[i++] = k; + } + primes = res; + return res; +} + +function simpleSieve(p) { + var primes = _getPrimes(); + + for (var i = 0; i < primes.length; i++) + if (p.modn(primes[i]) === 0) { + if (p.cmpn(primes[i]) === 0) { + return true; + } else { + return false; + } + } + + return true; +} + +function fermatTest(p) { + var red = BN.mont(p); + return TWO.toRed(red).redPow(p.subn(1)).fromRed().cmpn(1) === 0; +} + +function findPrime(bits, gen) { + if (bits < 16) { + // this is what openssl does + if (gen === 2 || gen === 5) { + return new BN([0x8c, 0x7b]); + } else { + return new BN([0x8c, 0x27]); + } + } + gen = new BN(gen); + + var num, n2; + + while (true) { + num = new BN(randomBytes(Math.ceil(bits / 8))); + while (num.bitLength() > bits) { + num.ishrn(1); + } + if (num.isEven()) { + num.iadd(ONE); + } + if (!num.testn(1)) { + num.iadd(TWO); + } + if (!gen.cmp(TWO)) { + while (num.mod(TWENTYFOUR).cmp(ELEVEN)) { + num.iadd(FOUR); + } + } else if (!gen.cmp(FIVE)) { + while (num.mod(TEN).cmp(THREE)) { + num.iadd(FOUR); + } + } + n2 = num.shrn(1); + if (simpleSieve(n2) && simpleSieve(num) && + fermatTest(n2) && fermatTest(num) && + millerRabin.test(n2) && millerRabin.test(num)) { + return num; + } + } + +} + + +/***/ }), +/* 190 */ +/***/ (function(module, exports, __webpack_require__) { + +var bn = __webpack_require__(11); +var brorand = __webpack_require__(171); + +function MillerRabin(rand) { + this.rand = rand || new brorand.Rand(); +} +module.exports = MillerRabin; + +MillerRabin.create = function create(rand) { + return new MillerRabin(rand); +}; + +MillerRabin.prototype._rand = function _rand(n) { + var len = n.bitLength(); + var buf = this.rand.generate(Math.ceil(len / 8)); + + // Set low bits + buf[0] |= 3; + + // Mask high bits + var mask = len & 0x7; + if (mask !== 0) + buf[buf.length - 1] >>= 7 - mask; + + return new bn(buf); +} + +MillerRabin.prototype.test = function test(n, k, cb) { + var len = n.bitLength(); + var red = bn.mont(n); + var rone = new bn(1).toRed(red); + + if (!k) + k = Math.max(1, (len / 48) | 0); + + // Find d and s, (n - 1) = (2 ^ s) * d; + var n1 = n.subn(1); + var n2 = n1.subn(1); + for (var s = 0; !n1.testn(s); s++) {} + var d = n.shrn(s); + + var rn1 = n1.toRed(red); + + var prime = true; + for (; k > 0; k--) { + var a = this._rand(n2); + if (cb) + cb(a); + + var x = a.toRed(red).redPow(d); + if (x.cmp(rone) === 0 || x.cmp(rn1) === 0) + continue; + + for (var i = 1; i < s; i++) { + x = x.redSqr(); + + if (x.cmp(rone) === 0) + return false; + if (x.cmp(rn1) === 0) + break; + } + + if (i === s) + return false; + } + + return prime; +}; + +MillerRabin.prototype.getDivisor = function getDivisor(n, k) { + var len = n.bitLength(); + var red = bn.mont(n); + var rone = new bn(1).toRed(red); + + if (!k) + k = Math.max(1, (len / 48) | 0); + + // Find d and s, (n - 1) = (2 ^ s) * d; + var n1 = n.subn(1); + var n2 = n1.subn(1); + for (var s = 0; !n1.testn(s); s++) {} + var d = n.shrn(s); + + var rn1 = n1.toRed(red); + + for (; k > 0; k--) { + var a = this._rand(n2); + + var g = n.gcd(a); + if (g.cmpn(1) !== 0) + return g; + + var x = a.toRed(red).redPow(d); + if (x.cmp(rone) === 0 || x.cmp(rn1) === 0) + continue; + + for (var i = 1; i < s; i++) { + x = x.redSqr(); + + if (x.cmp(rone) === 0) + return x.fromRed().subn(1).gcd(n); + if (x.cmp(rn1) === 0) + break; + } + + if (i === s) { + x = x.redSqr(); + return x.fromRed().subn(1).gcd(n); + } + } + + return false; +}; + + +/***/ }), +/* 191 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4); +var Reporter = __webpack_require__(53).Reporter; +var Buffer = __webpack_require__(1).Buffer; + +function DecoderBuffer(base, options) { + Reporter.call(this, options); + if (!Buffer.isBuffer(base)) { + this.error('Input not Buffer'); + return; + } + + this.base = base; + this.offset = 0; + this.length = base.length; +} +inherits(DecoderBuffer, Reporter); +exports.DecoderBuffer = DecoderBuffer; + +DecoderBuffer.prototype.save = function save() { + return { offset: this.offset, reporter: Reporter.prototype.save.call(this) }; +}; + +DecoderBuffer.prototype.restore = function restore(save) { + // Return skipped data + var res = new DecoderBuffer(this.base); + res.offset = save.offset; + res.length = this.offset; + + this.offset = save.offset; + Reporter.prototype.restore.call(this, save.reporter); + + return res; +}; + +DecoderBuffer.prototype.isEmpty = function isEmpty() { + return this.offset === this.length; +}; + +DecoderBuffer.prototype.readUInt8 = function readUInt8(fail) { + if (this.offset + 1 <= this.length) + return this.base.readUInt8(this.offset++, true); + else + return this.error(fail || 'DecoderBuffer overrun'); +} + +DecoderBuffer.prototype.skip = function skip(bytes, fail) { + if (!(this.offset + bytes <= this.length)) + return this.error(fail || 'DecoderBuffer overrun'); + + var res = new DecoderBuffer(this.base); + + // Share reporter state + res._reporterState = this._reporterState; + + res.offset = this.offset; + res.length = this.offset + bytes; + this.offset += bytes; + return res; +} + +DecoderBuffer.prototype.raw = function raw(save) { + return this.base.slice(save ? save.offset : this.offset, this.length); +} + +function EncoderBuffer(value, reporter) { + if (Array.isArray(value)) { + this.length = 0; + this.value = value.map(function(item) { + if (!(item instanceof EncoderBuffer)) + item = new EncoderBuffer(item, reporter); + this.length += item.length; + return item; + }, this); + } else if (typeof value === 'number') { + if (!(0 <= value && value <= 0xff)) + return reporter.error('non-byte EncoderBuffer value'); + this.value = value; + this.length = 1; + } else if (typeof value === 'string') { + this.value = value; + this.length = Buffer.byteLength(value); + } else if (Buffer.isBuffer(value)) { + this.value = value; + this.length = value.length; + } else { + return reporter.error('Unsupported type: ' + typeof value); + } +} +exports.EncoderBuffer = EncoderBuffer; + +EncoderBuffer.prototype.join = function join(out, offset) { + if (!out) + out = new Buffer(this.length); + if (!offset) + offset = 0; + + if (this.length === 0) + return out; + + if (Array.isArray(this.value)) { + this.value.forEach(function(item) { + item.join(out, offset); + offset += item.length; + }); + } else { + if (typeof this.value === 'number') + out[offset] = this.value; + else if (typeof this.value === 'string') + out.write(this.value, offset); + else if (Buffer.isBuffer(this.value)) + this.value.copy(out, offset); + offset += this.length; + } + + return out; +}; + + +/***/ }), +/* 192 */ +/***/ (function(module, exports, __webpack_require__) { + +var constants = exports; + +// Helper +constants._reverse = function reverse(map) { + var res = {}; + + Object.keys(map).forEach(function(key) { + // Convert key to integer if it is stringified + if ((key | 0) == key) + key = key | 0; + + var value = map[key]; + res[value] = key; + }); + + return res; +}; + +constants.der = __webpack_require__(445); + + +/***/ }), +/* 193 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4); + +var asn1 = __webpack_require__(52); +var base = asn1.base; +var bignum = asn1.bignum; + +// Import DER constants +var der = asn1.constants.der; + +function DERDecoder(entity) { + this.enc = 'der'; + this.name = entity.name; + this.entity = entity; + + // Construct base tree + this.tree = new DERNode(); + this.tree._init(entity.body); +}; +module.exports = DERDecoder; + +DERDecoder.prototype.decode = function decode(data, options) { + if (!(data instanceof base.DecoderBuffer)) + data = new base.DecoderBuffer(data, options); + + return this.tree._decode(data, options); +}; + +// Tree methods + +function DERNode(parent) { + base.Node.call(this, 'der', parent); +} +inherits(DERNode, base.Node); + +DERNode.prototype._peekTag = function peekTag(buffer, tag, any) { + if (buffer.isEmpty()) + return false; + + var state = buffer.save(); + var decodedTag = derDecodeTag(buffer, 'Failed to peek tag: "' + tag + '"'); + if (buffer.isError(decodedTag)) + return decodedTag; + + buffer.restore(state); + + return decodedTag.tag === tag || decodedTag.tagStr === tag || + (decodedTag.tagStr + 'of') === tag || any; +}; + +DERNode.prototype._decodeTag = function decodeTag(buffer, tag, any) { + var decodedTag = derDecodeTag(buffer, + 'Failed to decode tag of "' + tag + '"'); + if (buffer.isError(decodedTag)) + return decodedTag; + + var len = derDecodeLen(buffer, + decodedTag.primitive, + 'Failed to get length of "' + tag + '"'); + + // Failure + if (buffer.isError(len)) + return len; + + if (!any && + decodedTag.tag !== tag && + decodedTag.tagStr !== tag && + decodedTag.tagStr + 'of' !== tag) { + return buffer.error('Failed to match tag: "' + tag + '"'); + } + + if (decodedTag.primitive || len !== null) + return buffer.skip(len, 'Failed to match body of: "' + tag + '"'); + + // Indefinite length... find END tag + var state = buffer.save(); + var res = this._skipUntilEnd( + buffer, + 'Failed to skip indefinite length body: "' + this.tag + '"'); + if (buffer.isError(res)) + return res; + + len = buffer.offset - state.offset; + buffer.restore(state); + return buffer.skip(len, 'Failed to match body of: "' + tag + '"'); +}; + +DERNode.prototype._skipUntilEnd = function skipUntilEnd(buffer, fail) { + while (true) { + var tag = derDecodeTag(buffer, fail); + if (buffer.isError(tag)) + return tag; + var len = derDecodeLen(buffer, tag.primitive, fail); + if (buffer.isError(len)) + return len; + + var res; + if (tag.primitive || len !== null) + res = buffer.skip(len) + else + res = this._skipUntilEnd(buffer, fail); + + // Failure + if (buffer.isError(res)) + return res; + + if (tag.tagStr === 'end') + break; + } +}; + +DERNode.prototype._decodeList = function decodeList(buffer, tag, decoder, + options) { + var result = []; + while (!buffer.isEmpty()) { + var possibleEnd = this._peekTag(buffer, 'end'); + if (buffer.isError(possibleEnd)) + return possibleEnd; + + var res = decoder.decode(buffer, 'der', options); + if (buffer.isError(res) && possibleEnd) + break; + result.push(res); + } + return result; +}; + +DERNode.prototype._decodeStr = function decodeStr(buffer, tag) { + if (tag === 'bitstr') { + var unused = buffer.readUInt8(); + if (buffer.isError(unused)) + return unused; + return { unused: unused, data: buffer.raw() }; + } else if (tag === 'bmpstr') { + var raw = buffer.raw(); + if (raw.length % 2 === 1) + return buffer.error('Decoding of string type: bmpstr length mismatch'); + + var str = ''; + for (var i = 0; i < raw.length / 2; i++) { + str += String.fromCharCode(raw.readUInt16BE(i * 2)); + } + return str; + } else if (tag === 'numstr') { + var numstr = buffer.raw().toString('ascii'); + if (!this._isNumstr(numstr)) { + return buffer.error('Decoding of string type: ' + + 'numstr unsupported characters'); + } + return numstr; + } else if (tag === 'octstr') { + return buffer.raw(); + } else if (tag === 'objDesc') { + return buffer.raw(); + } else if (tag === 'printstr') { + var printstr = buffer.raw().toString('ascii'); + if (!this._isPrintstr(printstr)) { + return buffer.error('Decoding of string type: ' + + 'printstr unsupported characters'); + } + return printstr; + } else if (/str$/.test(tag)) { + return buffer.raw().toString(); + } else { + return buffer.error('Decoding of string type: ' + tag + ' unsupported'); + } +}; + +DERNode.prototype._decodeObjid = function decodeObjid(buffer, values, relative) { + var result; + var identifiers = []; + var ident = 0; + while (!buffer.isEmpty()) { + var subident = buffer.readUInt8(); + ident <<= 7; + ident |= subident & 0x7f; + if ((subident & 0x80) === 0) { + identifiers.push(ident); + ident = 0; + } + } + if (subident & 0x80) + identifiers.push(ident); + + var first = (identifiers[0] / 40) | 0; + var second = identifiers[0] % 40; + + if (relative) + result = identifiers; + else + result = [first, second].concat(identifiers.slice(1)); + + if (values) { + var tmp = values[result.join(' ')]; + if (tmp === undefined) + tmp = values[result.join('.')]; + if (tmp !== undefined) + result = tmp; + } + + return result; +}; + +DERNode.prototype._decodeTime = function decodeTime(buffer, tag) { + var str = buffer.raw().toString(); + if (tag === 'gentime') { + var year = str.slice(0, 4) | 0; + var mon = str.slice(4, 6) | 0; + var day = str.slice(6, 8) | 0; + var hour = str.slice(8, 10) | 0; + var min = str.slice(10, 12) | 0; + var sec = str.slice(12, 14) | 0; + } else if (tag === 'utctime') { + var year = str.slice(0, 2) | 0; + var mon = str.slice(2, 4) | 0; + var day = str.slice(4, 6) | 0; + var hour = str.slice(6, 8) | 0; + var min = str.slice(8, 10) | 0; + var sec = str.slice(10, 12) | 0; + if (year < 70) + year = 2000 + year; + else + year = 1900 + year; + } else { + return buffer.error('Decoding ' + tag + ' time is not supported yet'); + } + + return Date.UTC(year, mon - 1, day, hour, min, sec, 0); +}; + +DERNode.prototype._decodeNull = function decodeNull(buffer) { + return null; +}; + +DERNode.prototype._decodeBool = function decodeBool(buffer) { + var res = buffer.readUInt8(); + if (buffer.isError(res)) + return res; + else + return res !== 0; +}; + +DERNode.prototype._decodeInt = function decodeInt(buffer, values) { + // Bigint, return as it is (assume big endian) + var raw = buffer.raw(); + var res = new bignum(raw); + + if (values) + res = values[res.toString(10)] || res; + + return res; +}; + +DERNode.prototype._use = function use(entity, obj) { + if (typeof entity === 'function') + entity = entity(obj); + return entity._getDecoder('der').tree; +}; + +// Utility methods + +function derDecodeTag(buf, fail) { + var tag = buf.readUInt8(fail); + if (buf.isError(tag)) + return tag; + + var cls = der.tagClass[tag >> 6]; + var primitive = (tag & 0x20) === 0; + + // Multi-octet tag - load + if ((tag & 0x1f) === 0x1f) { + var oct = tag; + tag = 0; + while ((oct & 0x80) === 0x80) { + oct = buf.readUInt8(fail); + if (buf.isError(oct)) + return oct; + + tag <<= 7; + tag |= oct & 0x7f; + } + } else { + tag &= 0x1f; + } + var tagStr = der.tag[tag]; + + return { + cls: cls, + primitive: primitive, + tag: tag, + tagStr: tagStr + }; +} + +function derDecodeLen(buf, primitive, fail) { + var len = buf.readUInt8(fail); + if (buf.isError(len)) + return len; + + // Indefinite form + if (!primitive && len === 0x80) + return null; + + // Definite form + if ((len & 0x80) === 0) { + // Short form + return len; + } + + // Long form + var num = len & 0x7f; + if (num > 4) + return buf.error('length octect is too long'); + + len = 0; + for (var i = 0; i < num; i++) { + len <<= 8; + var j = buf.readUInt8(fail); + if (buf.isError(j)) + return j; + len |= j; + } + + return len; +} + + +/***/ }), +/* 194 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4); +var Buffer = __webpack_require__(1).Buffer; + +var asn1 = __webpack_require__(52); +var base = asn1.base; + +// Import DER constants +var der = asn1.constants.der; + +function DEREncoder(entity) { + this.enc = 'der'; + this.name = entity.name; + this.entity = entity; + + // Construct base tree + this.tree = new DERNode(); + this.tree._init(entity.body); +}; +module.exports = DEREncoder; + +DEREncoder.prototype.encode = function encode(data, reporter) { + return this.tree._encode(data, reporter).join(); +}; + +// Tree methods + +function DERNode(parent) { + base.Node.call(this, 'der', parent); +} +inherits(DERNode, base.Node); + +DERNode.prototype._encodeComposite = function encodeComposite(tag, + primitive, + cls, + content) { + var encodedTag = encodeTag(tag, primitive, cls, this.reporter); + + // Short form + if (content.length < 0x80) { + var header = new Buffer(2); + header[0] = encodedTag; + header[1] = content.length; + return this._createEncoderBuffer([ header, content ]); + } + + // Long form + // Count octets required to store length + var lenOctets = 1; + for (var i = content.length; i >= 0x100; i >>= 8) + lenOctets++; + + var header = new Buffer(1 + 1 + lenOctets); + header[0] = encodedTag; + header[1] = 0x80 | lenOctets; + + for (var i = 1 + lenOctets, j = content.length; j > 0; i--, j >>= 8) + header[i] = j & 0xff; + + return this._createEncoderBuffer([ header, content ]); +}; + +DERNode.prototype._encodeStr = function encodeStr(str, tag) { + if (tag === 'bitstr') { + return this._createEncoderBuffer([ str.unused | 0, str.data ]); + } else if (tag === 'bmpstr') { + var buf = new Buffer(str.length * 2); + for (var i = 0; i < str.length; i++) { + buf.writeUInt16BE(str.charCodeAt(i), i * 2); + } + return this._createEncoderBuffer(buf); + } else if (tag === 'numstr') { + if (!this._isNumstr(str)) { + return this.reporter.error('Encoding of string type: numstr supports ' + + 'only digits and space'); + } + return this._createEncoderBuffer(str); + } else if (tag === 'printstr') { + if (!this._isPrintstr(str)) { + return this.reporter.error('Encoding of string type: printstr supports ' + + 'only latin upper and lower case letters, ' + + 'digits, space, apostrophe, left and rigth ' + + 'parenthesis, plus sign, comma, hyphen, ' + + 'dot, slash, colon, equal sign, ' + + 'question mark'); + } + return this._createEncoderBuffer(str); + } else if (/str$/.test(tag)) { + return this._createEncoderBuffer(str); + } else if (tag === 'objDesc') { + return this._createEncoderBuffer(str); + } else { + return this.reporter.error('Encoding of string type: ' + tag + + ' unsupported'); + } +}; + +DERNode.prototype._encodeObjid = function encodeObjid(id, values, relative) { + if (typeof id === 'string') { + if (!values) + return this.reporter.error('string objid given, but no values map found'); + if (!values.hasOwnProperty(id)) + return this.reporter.error('objid not found in values map'); + id = values[id].split(/[\s\.]+/g); + for (var i = 0; i < id.length; i++) + id[i] |= 0; + } else if (Array.isArray(id)) { + id = id.slice(); + for (var i = 0; i < id.length; i++) + id[i] |= 0; + } + + if (!Array.isArray(id)) { + return this.reporter.error('objid() should be either array or string, ' + + 'got: ' + JSON.stringify(id)); + } + + if (!relative) { + if (id[1] >= 40) + return this.reporter.error('Second objid identifier OOB'); + id.splice(0, 2, id[0] * 40 + id[1]); + } + + // Count number of octets + var size = 0; + for (var i = 0; i < id.length; i++) { + var ident = id[i]; + for (size++; ident >= 0x80; ident >>= 7) + size++; + } + + var objid = new Buffer(size); + var offset = objid.length - 1; + for (var i = id.length - 1; i >= 0; i--) { + var ident = id[i]; + objid[offset--] = ident & 0x7f; + while ((ident >>= 7) > 0) + objid[offset--] = 0x80 | (ident & 0x7f); + } + + return this._createEncoderBuffer(objid); +}; + +function two(num) { + if (num < 10) + return '0' + num; + else + return num; +} + +DERNode.prototype._encodeTime = function encodeTime(time, tag) { + var str; + var date = new Date(time); + + if (tag === 'gentime') { + str = [ + two(date.getFullYear()), + two(date.getUTCMonth() + 1), + two(date.getUTCDate()), + two(date.getUTCHours()), + two(date.getUTCMinutes()), + two(date.getUTCSeconds()), + 'Z' + ].join(''); + } else if (tag === 'utctime') { + str = [ + two(date.getFullYear() % 100), + two(date.getUTCMonth() + 1), + two(date.getUTCDate()), + two(date.getUTCHours()), + two(date.getUTCMinutes()), + two(date.getUTCSeconds()), + 'Z' + ].join(''); + } else { + this.reporter.error('Encoding ' + tag + ' time is not supported yet'); + } + + return this._encodeStr(str, 'octstr'); +}; + +DERNode.prototype._encodeNull = function encodeNull() { + return this._createEncoderBuffer(''); +}; + +DERNode.prototype._encodeInt = function encodeInt(num, values) { + if (typeof num === 'string') { + if (!values) + return this.reporter.error('String int or enum given, but no values map'); + if (!values.hasOwnProperty(num)) { + return this.reporter.error('Values map doesn\'t contain: ' + + JSON.stringify(num)); + } + num = values[num]; + } + + // Bignum, assume big endian + if (typeof num !== 'number' && !Buffer.isBuffer(num)) { + var numArray = num.toArray(); + if (!num.sign && numArray[0] & 0x80) { + numArray.unshift(0); + } + num = new Buffer(numArray); + } + + if (Buffer.isBuffer(num)) { + var size = num.length; + if (num.length === 0) + size++; + + var out = new Buffer(size); + num.copy(out); + if (num.length === 0) + out[0] = 0 + return this._createEncoderBuffer(out); + } + + if (num < 0x80) + return this._createEncoderBuffer(num); + + if (num < 0x100) + return this._createEncoderBuffer([0, num]); + + var size = 1; + for (var i = num; i >= 0x100; i >>= 8) + size++; + + var out = new Array(size); + for (var i = out.length - 1; i >= 0; i--) { + out[i] = num & 0xff; + num >>= 8; + } + if(out[0] & 0x80) { + out.unshift(0); + } + + return this._createEncoderBuffer(new Buffer(out)); +}; + +DERNode.prototype._encodeBool = function encodeBool(value) { + return this._createEncoderBuffer(value ? 0xff : 0); +}; + +DERNode.prototype._use = function use(entity, obj) { + if (typeof entity === 'function') + entity = entity(obj); + return entity._getEncoder('der').tree; +}; + +DERNode.prototype._skipDefault = function skipDefault(dataBuffer, reporter, parent) { + var state = this._baseState; + var i; + if (state['default'] === null) + return false; + + var data = dataBuffer.join(); + if (state.defaultBuffer === undefined) + state.defaultBuffer = this._encodeValue(state['default'], reporter, parent).join(); + + if (data.length !== state.defaultBuffer.length) + return false; + + for (i=0; i < data.length; i++) + if (data[i] !== state.defaultBuffer[i]) + return false; + + return true; +}; + +// Utility methods + +function encodeTag(tag, primitive, cls, reporter) { + var res; + + if (tag === 'seqof') + tag = 'seq'; + else if (tag === 'setof') + tag = 'set'; + + if (der.tagByName.hasOwnProperty(tag)) + res = der.tagByName[tag]; + else if (typeof tag === 'number' && (tag | 0) === tag) + res = tag; + else + return reporter.error('Unknown tag: ' + tag); + + if (res >= 0x1f) + return reporter.error('Multi-octet tag encoding unsupported'); + + if (!primitive) + res |= 0x20; + + res |= (der.tagClassByName[cls || 'universal'] << 6); + + return res; +} + + +/***/ }), +/* 195 */ +/***/ (function(module, exports) { + +module.exports = { + "1.3.132.0.10": "secp256k1", + "1.3.132.0.33": "p224", + "1.2.840.10045.3.1.1": "p192", + "1.2.840.10045.3.1.7": "p256", + "1.3.132.0.34": "p384", + "1.3.132.0.35": "p521" +}; + +/***/ }), +/* 196 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var createHash = __webpack_require__(27); +module.exports = function (seed, len) { + var t = new Buffer(''); + var i = 0, c; + while (t.length < len) { + c = i2ops(i++); + t = Buffer.concat([t, createHash('sha1').update(seed).update(c).digest()]); + } + return t.slice(0, len); +}; + +function i2ops(c) { + var out = new Buffer(4); + out.writeUInt32BE(c,0); + return out; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 197 */ +/***/ (function(module, exports) { + +module.exports = function xor(a, b) { + var len = a.length; + var i = -1; + while (++i < len) { + a[i] ^= b[i]; + } + return a +}; + +/***/ }), +/* 198 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var bn = __webpack_require__(11); +function withPublic(paddedMsg, key) { + return new Buffer(paddedMsg + .toRed(bn.mont(key.modulus)) + .redPow(new bn(key.publicExponent)) + .fromRed() + .toArray()); +} + +module.exports = withPublic; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 199 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) { + +// https://github.com/bitcoinjs/bitcoinjs-lib/issues/14 +function numToBytes(num, bytes) { + if (bytes == 0) return [];else return [num % 256].concat(numToBytes(Math.floor(num / 256), bytes - 1)); +} + +function numToVarInt(num) { + var b; + if (num < 253) b = [num];else if (num < 65536) b = [253].concat(numToBytes(num, 2));else if (num < 4294967296) b = [254].concat(numToBytes(num, 4));else b = [253].concat(numToBytes(num, 8)); + return Buffer.from(b).toString('hex'); +} + +// https://github.com/feross/buffer/blob/master/index.js#L1127 +function verifuint(value, max) { + if (typeof value !== 'number') { + throw new Error('cannot write a non-number as a number'); + } + if (value < 0) { + throw new Error('specified a negative value for writing an unsigned value'); + } + if (value > max) throw new Error('RangeError: value out of range'); + if (Math.floor(value) !== value) { + throw new Error('value has a fractional component'); + } +} + +function readUInt64LE(buffer, offset) { + var a = buffer.readUInt32LE(offset); + var b = buffer.readUInt32LE(offset + 4); + b *= 0x100000000; + + verifuint(b + a, 0x001fffffffffffff); + + return b + a; +} + +function writeUInt64LE(buffer, value, offset) { + verifuint(value, 0x001fffffffffffff); + + buffer.writeInt32LE(value & -1, offset); + buffer.writeUInt32LE(Math.floor(value / 0x100000000), offset + 4); + return offset + 8; +} + +/* + * Given a hex string, get the length of it in bytes + * ** NOT string.length, but convert it into bytes + * and return the length of that in bytes in hex + * @param {String} hexStr + * return {String} Length of hexStr in bytes + */ +function getStringBufferLength(hexStr) { + const _tmpBuf = Buffer.from(hexStr, 'hex').length; + return Buffer.from([_tmpBuf]).toString('hex'); +} + +module.exports = { + readUInt64LE: readUInt64LE, + writeUInt64LE: writeUInt64LE, + getStringBufferLength: getStringBufferLength, + numToVarInt: numToVarInt, + numToBytes: numToBytes +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 200 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = { + Block: __webpack_require__(465), + ECPair: __webpack_require__(113), + ECSignature: __webpack_require__(115), + HDNode: __webpack_require__(493), + Transaction: __webpack_require__(112), + TransactionBuilder: __webpack_require__(494), + + address: __webpack_require__(114), + bufferutils: __webpack_require__(206), // TODO: remove in 4.0.0 + crypto: __webpack_require__(44), + networks: __webpack_require__(54), + opcodes: __webpack_require__(16), + script: __webpack_require__(14) +} + + +/***/ }), +/* 201 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4) +var native = __webpack_require__(111) + +function TfTypeError (type, value, valueTypeName) { + this.__error = Error.call(this) + this.__type = type + this.__value = value + this.__valueTypeName = valueTypeName + + var message + Object.defineProperty(this, 'message', { + enumerable: true, + get: function () { + if (message) return message + + valueTypeName = valueTypeName || getValueTypeName(value) + message = tfErrorString(type, value, valueTypeName) + + return message + } + }) +} + +function TfPropertyTypeError (type, property, label, value, error, valueTypeName) { + this.__error = error || Error.call(this) + this.__label = label + this.__property = property + this.__type = type + this.__value = value + this.__valueTypeName = valueTypeName + + var message + Object.defineProperty(this, 'message', { + enumerable: true, + get: function () { + if (message) return message + if (type) { + valueTypeName = valueTypeName || getValueTypeName(value) + message = tfPropertyErrorString(type, label, property, value, valueTypeName) + } else { + message = 'Unexpected property "' + property + '"' + } + + return message + } + }) +} + +// inherit from Error, assign stack +[TfTypeError, TfPropertyTypeError].forEach(function (tfErrorType) { + inherits(tfErrorType, Error) + Object.defineProperty(tfErrorType, 'stack', { + get: function () { return this.__error.stack } + }) +}) + +function tfCustomError (expected, actual) { + return new TfTypeError(expected, {}, actual) +} + +function tfSubError (e, property, label) { + // sub child? + if (e instanceof TfPropertyTypeError) { + property = property + '.' + e.__property + label = e.__label + + return new TfPropertyTypeError( + e.__type, property, label, e.__value, e.__error, e.__valueTypeName + ) + } + + // child? + if (e instanceof TfTypeError) { + return new TfPropertyTypeError( + e.__type, property, label, e.__value, e.__error, e.__valueTypeName + ) + } + + return e +} + +function getTypeName (fn) { + return fn.name || fn.toString().match(/function (.*?)\s*\(/)[1] +} + +function getValueTypeName (value) { + return native.Nil(value) ? '' : getTypeName(value.constructor) +} + +function getValue (value) { + if (native.Function(value)) return '' + if (native.String(value)) return JSON.stringify(value) + if (value && native.Object(value)) return '' + return value +} + +function tfJSON (type) { + if (native.Function(type)) return type.toJSON ? type.toJSON() : getTypeName(type) + if (native.Array(type)) return 'Array' + if (type && native.Object(type)) return 'Object' + + return type !== undefined ? type : '' +} + +function tfErrorString (type, value, valueTypeName) { + var valueJson = getValue(value) + + return 'Expected ' + tfJSON(type) + ', got' + + (valueTypeName !== '' ? ' ' + valueTypeName : '') + + (valueJson !== '' ? ' ' + valueJson : '') +} + +function tfPropertyErrorString (type, label, name, value, valueTypeName) { + var description = '" of type ' + if (label === 'key') description = '" with key type ' + + return tfErrorString('property "' + tfJSON(name) + description + tfJSON(type), value, valueTypeName) +} + +module.exports = { + TfTypeError: TfTypeError, + TfPropertyTypeError: TfPropertyTypeError, + tfCustomError: tfCustomError, + tfSubError: tfSubError, + tfJSON: tfJSON, + getValueTypeName: getValueTypeName +} + + +/***/ }), +/* 202 */ +/***/ (function(module, exports, __webpack_require__) { + +var OPS = __webpack_require__(16) + +function encodingLength (i) { + return i < OPS.OP_PUSHDATA1 ? 1 + : i <= 0xff ? 2 + : i <= 0xffff ? 3 + : 5 +} + +function encode (buffer, number, offset) { + var size = encodingLength(number) + + // ~6 bit + if (size === 1) { + buffer.writeUInt8(number, offset) + + // 8 bit + } else if (size === 2) { + buffer.writeUInt8(OPS.OP_PUSHDATA1, offset) + buffer.writeUInt8(number, offset + 1) + + // 16 bit + } else if (size === 3) { + buffer.writeUInt8(OPS.OP_PUSHDATA2, offset) + buffer.writeUInt16LE(number, offset + 1) + + // 32 bit + } else { + buffer.writeUInt8(OPS.OP_PUSHDATA4, offset) + buffer.writeUInt32LE(number, offset + 1) + } + + return size +} + +function decode (buffer, offset) { + var opcode = buffer.readUInt8(offset) + var number, size + + // ~6 bit + if (opcode < OPS.OP_PUSHDATA1) { + number = opcode + size = 1 + + // 8 bit + } else if (opcode === OPS.OP_PUSHDATA1) { + if (offset + 2 > buffer.length) return null + number = buffer.readUInt8(offset + 1) + size = 2 + + // 16 bit + } else if (opcode === OPS.OP_PUSHDATA2) { + if (offset + 3 > buffer.length) return null + number = buffer.readUInt16LE(offset + 1) + size = 3 + + // 32 bit + } else { + if (offset + 5 > buffer.length) return null + if (opcode !== OPS.OP_PUSHDATA4) throw new Error('Unexpected opcode') + + number = buffer.readUInt32LE(offset + 1) + size = 5 + } + + return { + opcode: opcode, + number: number, + size: size + } +} + +module.exports = { + encodingLength: encodingLength, + encode: encode, + decode: decode +} + + +/***/ }), +/* 203 */ +/***/ (function(module, exports, __webpack_require__) { + +var Buffer = __webpack_require__(7).Buffer + +function decode (buffer, maxLength, minimal) { + maxLength = maxLength || 4 + minimal = minimal === undefined ? true : minimal + + var length = buffer.length + if (length === 0) return 0 + if (length > maxLength) throw new TypeError('Script number overflow') + if (minimal) { + if ((buffer[length - 1] & 0x7f) === 0) { + if (length <= 1 || (buffer[length - 2] & 0x80) === 0) throw new Error('Non-minimally encoded script number') + } + } + + // 40-bit + if (length === 5) { + var a = buffer.readUInt32LE(0) + var b = buffer.readUInt8(4) + + if (b & 0x80) return -(((b & ~0x80) * 0x100000000) + a) + return (b * 0x100000000) + a + } + + var result = 0 + + // 32-bit / 24-bit / 16-bit / 8-bit + for (var i = 0; i < length; ++i) { + result |= buffer[i] << (8 * i) + } + + if (buffer[length - 1] & 0x80) return -(result & ~(0x80 << (8 * (length - 1)))) + return result +} + +function scriptNumSize (i) { + return i > 0x7fffffff ? 5 + : i > 0x7fffff ? 4 + : i > 0x7fff ? 3 + : i > 0x7f ? 2 + : i > 0x00 ? 1 + : 0 +} + +function encode (number) { + var value = Math.abs(number) + var size = scriptNumSize(value) + var buffer = Buffer.allocUnsafe(size) + var negative = number < 0 + + for (var i = 0; i < size; ++i) { + buffer.writeUInt8(value & 0xff, i) + value >>= 8 + } + + if (buffer[size - 1] & 0x80) { + buffer.writeUInt8(negative ? 0x80 : 0x00, size - 1) + } else if (negative) { + buffer[size - 1] |= 0x80 + } + + return buffer +} + +module.exports = { + decode: decode, + encode: encode +} + + +/***/ }), +/* 204 */ +/***/ (function(module, exports, __webpack_require__) { + +// {signature} {pubKey} + +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) + +function check (script) { + var chunks = bscript.decompile(script) + + return chunks.length === 2 && + bscript.isCanonicalSignature(chunks[0]) && + bscript.isCanonicalPubKey(chunks[1]) +} +check.toJSON = function () { return 'pubKeyHash input' } + +function encodeStack (signature, pubKey) { + typeforce({ + signature: types.Buffer, pubKey: types.Buffer + }, { + signature: signature, pubKey: pubKey + }) + + return [signature, pubKey] +} + +function encode (signature, pubKey) { + return bscript.compile(encodeStack(signature, pubKey)) +} + +function decodeStack (stack) { + typeforce(check, stack) + + return { + signature: stack[0], + pubKey: stack[1] + } +} + +function decode (buffer) { + var stack = bscript.decompile(buffer) + return decodeStack(stack) +} + +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} + + +/***/ }), +/* 205 */ +/***/ (function(module, exports, __webpack_require__) { + +// <scriptSig> {serialized scriptPubKey script} + +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) + +function check (script, allowIncomplete) { + var chunks = bscript.decompile(script) + if (chunks.length < 1) return false + + var lastChunk = chunks[chunks.length - 1] + if (!Buffer.isBuffer(lastChunk)) return false + + var scriptSigChunks = bscript.decompile(bscript.compile(chunks.slice(0, -1))) + var redeemScriptChunks = bscript.decompile(lastChunk) + + // is redeemScript a valid script? + if (redeemScriptChunks.length === 0) return false + + // is redeemScriptSig push only? + if (!bscript.isPushOnly(scriptSigChunks)) return false + + var inputType = bscript.classifyInput(scriptSigChunks, allowIncomplete) + var outputType = bscript.classifyOutput(redeemScriptChunks) + if (chunks.length === 1) { + return outputType === bscript.types.P2WSH || outputType === bscript.types.P2WPKH + } + return inputType === outputType +} +check.toJSON = function () { return 'scriptHash input' } + +function encodeStack (redeemScriptStack, redeemScript) { + var serializedScriptPubKey = bscript.compile(redeemScript) + + return [].concat(redeemScriptStack, serializedScriptPubKey) +} + +function encode (redeemScriptSig, redeemScript) { + var redeemScriptStack = bscript.decompile(redeemScriptSig) + + return bscript.compile(encodeStack(redeemScriptStack, redeemScript)) +} + +function decodeStack (stack) { + typeforce(check, stack) + + return { + redeemScriptStack: stack.slice(0, -1), + redeemScript: stack[stack.length - 1] + } +} + +function decode (buffer) { + var stack = bscript.decompile(buffer) + var result = decodeStack(stack) + result.redeemScriptSig = bscript.compile(result.redeemScriptStack) + delete result.redeemScriptStack + return result +} + +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} + + +/***/ }), +/* 206 */ +/***/ (function(module, exports, __webpack_require__) { + +var pushdata = __webpack_require__(202) +var varuint = __webpack_require__(73) + +// https://github.com/feross/buffer/blob/master/index.js#L1127 +function verifuint (value, max) { + if (typeof value !== 'number') throw new Error('cannot write a non-number as a number') + if (value < 0) throw new Error('specified a negative value for writing an unsigned value') + if (value > max) throw new Error('RangeError: value out of range') + if (Math.floor(value) !== value) throw new Error('value has a fractional component') +} + +function readUInt64LE (buffer, offset) { + var a = buffer.readUInt32LE(offset) + var b = buffer.readUInt32LE(offset + 4) + b *= 0x100000000 + + verifuint(b + a, 0x001fffffffffffff) + + return b + a +} + +function writeUInt64LE (buffer, value, offset) { + verifuint(value, 0x001fffffffffffff) + + buffer.writeInt32LE(value & -1, offset) + buffer.writeUInt32LE(Math.floor(value / 0x100000000), offset + 4) + return offset + 8 +} + +// TODO: remove in 4.0.0? +function readVarInt (buffer, offset) { + var result = varuint.decode(buffer, offset) + + return { + number: result, + size: varuint.decode.bytes + } +} + +// TODO: remove in 4.0.0? +function writeVarInt (buffer, number, offset) { + varuint.encode(number, buffer, offset) + return varuint.encode.bytes +} + +module.exports = { + pushDataSize: pushdata.encodingLength, + readPushDataInt: pushdata.decode, + readUInt64LE: readUInt64LE, + readVarInt: readVarInt, + varIntBuffer: varuint.encode, + varIntSize: varuint.encodingLength, + writePushDataInt: pushdata.encode, + writeUInt64LE: writeUInt64LE, + writeVarInt: writeVarInt +} + + +/***/ }), +/* 207 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(30) + +var THREE = BigInteger.valueOf(3) + +function Point (curve, x, y, z) { + assert.notStrictEqual(z, undefined, 'Missing Z coordinate') + + this.curve = curve + this.x = x + this.y = y + this.z = z + this._zInv = null + + this.compressed = true +} + +Object.defineProperty(Point.prototype, 'zInv', { + get: function () { + if (this._zInv === null) { + this._zInv = this.z.modInverse(this.curve.p) + } + + return this._zInv + } +}) + +Object.defineProperty(Point.prototype, 'affineX', { + get: function () { + return this.x.multiply(this.zInv).mod(this.curve.p) + } +}) + +Object.defineProperty(Point.prototype, 'affineY', { + get: function () { + return this.y.multiply(this.zInv).mod(this.curve.p) + } +}) + +Point.fromAffine = function (curve, x, y) { + return new Point(curve, x, y, BigInteger.ONE) +} + +Point.prototype.equals = function (other) { + if (other === this) return true + if (this.curve.isInfinity(this)) return this.curve.isInfinity(other) + if (this.curve.isInfinity(other)) return this.curve.isInfinity(this) + + // u = Y2 * Z1 - Y1 * Z2 + var u = other.y.multiply(this.z).subtract(this.y.multiply(other.z)).mod(this.curve.p) + + if (u.signum() !== 0) return false + + // v = X2 * Z1 - X1 * Z2 + var v = other.x.multiply(this.z).subtract(this.x.multiply(other.z)).mod(this.curve.p) + + return v.signum() === 0 +} + +Point.prototype.negate = function () { + var y = this.curve.p.subtract(this.y) + + return new Point(this.curve, this.x, y, this.z) +} + +Point.prototype.add = function (b) { + if (this.curve.isInfinity(this)) return b + if (this.curve.isInfinity(b)) return this + + var x1 = this.x + var y1 = this.y + var x2 = b.x + var y2 = b.y + + // u = Y2 * Z1 - Y1 * Z2 + var u = y2.multiply(this.z).subtract(y1.multiply(b.z)).mod(this.curve.p) + // v = X2 * Z1 - X1 * Z2 + var v = x2.multiply(this.z).subtract(x1.multiply(b.z)).mod(this.curve.p) + + if (v.signum() === 0) { + if (u.signum() === 0) { + return this.twice() // this == b, so double + } + + return this.curve.infinity // this = -b, so infinity + } + + var v2 = v.square() + var v3 = v2.multiply(v) + var x1v2 = x1.multiply(v2) + var zu2 = u.square().multiply(this.z) + + // x3 = v * (z2 * (z1 * u^2 - 2 * x1 * v^2) - v^3) + var x3 = zu2.subtract(x1v2.shiftLeft(1)).multiply(b.z).subtract(v3).multiply(v).mod(this.curve.p) + // y3 = z2 * (3 * x1 * u * v^2 - y1 * v^3 - z1 * u^3) + u * v^3 + var y3 = x1v2.multiply(THREE).multiply(u).subtract(y1.multiply(v3)).subtract(zu2.multiply(u)).multiply(b.z).add(u.multiply(v3)).mod(this.curve.p) + // z3 = v^3 * z1 * z2 + var z3 = v3.multiply(this.z).multiply(b.z).mod(this.curve.p) + + return new Point(this.curve, x3, y3, z3) +} + +Point.prototype.twice = function () { + if (this.curve.isInfinity(this)) return this + if (this.y.signum() === 0) return this.curve.infinity + + var x1 = this.x + var y1 = this.y + + var y1z1 = y1.multiply(this.z).mod(this.curve.p) + var y1sqz1 = y1z1.multiply(y1).mod(this.curve.p) + var a = this.curve.a + + // w = 3 * x1^2 + a * z1^2 + var w = x1.square().multiply(THREE) + + if (a.signum() !== 0) { + w = w.add(this.z.square().multiply(a)) + } + + w = w.mod(this.curve.p) + // x3 = 2 * y1 * z1 * (w^2 - 8 * x1 * y1^2 * z1) + var x3 = w.square().subtract(x1.shiftLeft(3).multiply(y1sqz1)).shiftLeft(1).multiply(y1z1).mod(this.curve.p) + // y3 = 4 * y1^2 * z1 * (3 * w * x1 - 2 * y1^2 * z1) - w^3 + var y3 = w.multiply(THREE).multiply(x1).subtract(y1sqz1.shiftLeft(1)).shiftLeft(2).multiply(y1sqz1).subtract(w.pow(3)).mod(this.curve.p) + // z3 = 8 * (y1 * z1)^3 + var z3 = y1z1.pow(3).shiftLeft(3).mod(this.curve.p) + + return new Point(this.curve, x3, y3, z3) +} + +// Simple NAF (Non-Adjacent Form) multiplication algorithm +// TODO: modularize the multiplication algorithm +Point.prototype.multiply = function (k) { + if (this.curve.isInfinity(this)) return this + if (k.signum() === 0) return this.curve.infinity + + var e = k + var h = e.multiply(THREE) + + var neg = this.negate() + var R = this + + for (var i = h.bitLength() - 2; i > 0; --i) { + var hBit = h.testBit(i) + var eBit = e.testBit(i) + + R = R.twice() + + if (hBit !== eBit) { + R = R.add(hBit ? this : neg) + } + } + + return R +} + +// Compute this*j + x*k (simultaneous multiplication) +Point.prototype.multiplyTwo = function (j, x, k) { + var i = Math.max(j.bitLength(), k.bitLength()) - 1 + var R = this.curve.infinity + var both = this.add(x) + + while (i >= 0) { + var jBit = j.testBit(i) + var kBit = k.testBit(i) + + R = R.twice() + + if (jBit) { + if (kBit) { + R = R.add(both) + } else { + R = R.add(this) + } + } else if (kBit) { + R = R.add(x) + } + --i + } + + return R +} + +Point.prototype.getEncoded = function (compressed) { + if (compressed == null) compressed = this.compressed + if (this.curve.isInfinity(this)) return new Buffer('00', 'hex') // Infinity point encoded is simply '00' + + var x = this.affineX + var y = this.affineY + var byteLength = this.curve.pLength + var buffer + + // 0x02/0x03 | X + if (compressed) { + buffer = new Buffer(1 + byteLength) + buffer.writeUInt8(y.isEven() ? 0x02 : 0x03, 0) + + // 0x04 | X | Y + } else { + buffer = new Buffer(1 + byteLength + byteLength) + buffer.writeUInt8(0x04, 0) + + y.toBuffer(byteLength).copy(buffer, 1 + byteLength) + } + + x.toBuffer(byteLength).copy(buffer, 1) + + return buffer +} + +Point.decodeFrom = function (curve, buffer) { + var type = buffer.readUInt8(0) + var compressed = (type !== 4) + + var byteLength = Math.floor((curve.p.bitLength() + 7) / 8) + var x = BigInteger.fromBuffer(buffer.slice(1, 1 + byteLength)) + + var Q + if (compressed) { + assert.equal(buffer.length, byteLength + 1, 'Invalid sequence length') + assert(type === 0x02 || type === 0x03, 'Invalid sequence tag') + + var isOdd = (type === 0x03) + Q = curve.pointFromX(isOdd, x) + } else { + assert.equal(buffer.length, 1 + byteLength + byteLength, 'Invalid sequence length') + + var y = BigInteger.fromBuffer(buffer.slice(1 + byteLength)) + Q = Point.fromAffine(curve, x, y) + } + + Q.compressed = compressed + return Q +} + +Point.prototype.toString = function () { + if (this.curve.isInfinity(this)) return '(INFINITY)' + + return '(' + this.affineX.toString() + ',' + this.affineY.toString() + ')' +} + +module.exports = Point + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 208 */ +/***/ (function(module, exports, __webpack_require__) { + +var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(30) + +var Point = __webpack_require__(207) + +function Curve (p, a, b, Gx, Gy, n, h) { + this.p = p + this.a = a + this.b = b + this.G = Point.fromAffine(this, Gx, Gy) + this.n = n + this.h = h + + this.infinity = new Point(this, null, null, BigInteger.ZERO) + + // result caching + this.pOverFour = p.add(BigInteger.ONE).shiftRight(2) + + // determine size of p in bytes + this.pLength = Math.floor((this.p.bitLength() + 7) / 8) +} + +Curve.prototype.pointFromX = function (isOdd, x) { + var alpha = x.pow(3).add(this.a.multiply(x)).add(this.b).mod(this.p) + var beta = alpha.modPow(this.pOverFour, this.p) // XXX: not compatible with all curves + + var y = beta + if (beta.isEven() ^ !isOdd) { + y = this.p.subtract(y) // -y % p + } + + return Point.fromAffine(this, x, y) +} + +Curve.prototype.isInfinity = function (Q) { + if (Q === this.infinity) return true + + return Q.z.signum() === 0 && Q.y.signum() !== 0 +} + +Curve.prototype.isOnCurve = function (Q) { + if (this.isInfinity(Q)) return true + + var x = Q.affineX + var y = Q.affineY + var a = this.a + var b = this.b + var p = this.p + + // Check that xQ and yQ are integers in the interval [0, p - 1] + if (x.signum() < 0 || x.compareTo(p) >= 0) return false + if (y.signum() < 0 || y.compareTo(p) >= 0) return false + + // and check that y^2 = x^3 + ax + b (mod p) + var lhs = y.square().mod(p) + var rhs = x.pow(3).add(a.multiply(x)).add(b).mod(p) + return lhs.equals(rhs) +} + +/** + * Validate an elliptic curve point. + * + * See SEC 1, section 3.2.2.1: Elliptic Curve Public Key Validation Primitive + */ +Curve.prototype.validate = function (Q) { + // Check Q != O + assert(!this.isInfinity(Q), 'Point is at infinity') + assert(this.isOnCurve(Q), 'Point is not on the curve') + + // Check nQ = O (where Q is a scalar multiple of G) + var nQ = Q.multiply(this.n) + assert(this.isInfinity(nQ), 'Point is not a scalar multiple of G') + + return true +} + +module.exports = Curve + + +/***/ }), +/* 209 */ +/***/ (function(module, exports) { + +// https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki#account-discovery +module.exports = function discovery (chain, gapLimit, queryCb, done) { + var gap = 0 + var checked = 0 + + function cycle () { + var batch = [chain.get()] + checked++ + + while (batch.length < gapLimit) { + chain.next() + batch.push(chain.get()) + + checked++ + } + + queryCb(batch, function (err, results) { + if (err) return done(err) + + results.forEach(function (isUsed) { + if (isUsed) { + gap = 0 + } else { + gap += 1 + } + }) + + if (gap >= gapLimit) { + var used = checked - gap + + return done(undefined, used, checked) + } else { + chain.next() + } + + cycle() + }) + } + + cycle() +} + + +/***/ }), +/* 210 */ +/***/ (function(module, exports) { + +function Chain (parent, k) { + k = k || 0 + this.__parent = parent + + this.addresses = [] + this.k = k + this.map = {} +} + +Chain.prototype.__initialize = function () { + var address = this.__parent.derive(this.k).getAddress() + this.map[address] = this.k + this.addresses.push(address) +} + +Chain.prototype.clone = function () { + var chain = new Chain(this.__parent, this.k) + + for (var k in this.addresses) chain.addresses[k] = this.addresses[k] + for (k in this.map) chain.map[k] = this.map[k] + + return chain +} + +Chain.prototype.derive = function (address, parent) { + var k = this.map[address] + if (k === undefined) return + + parent = parent || this.__parent + return parent.derive(k) +} + +Chain.prototype.find = function (address) { + return this.map[address] +} + +Chain.prototype.get = function () { + if (this.addresses.length === 0) this.__initialize() + + return this.addresses[this.addresses.length - 1] +} + +Chain.prototype.getAll = function () { + if (this.addresses.length === 0) this.__initialize() + + return this.addresses +} + +Chain.prototype.getParent = function () { + return this.__parent +} + +Chain.prototype.next = function () { + if (this.addresses.length === 0) this.__initialize() + var address = this.__parent.derive(this.k + 1).getAddress() + + this.k += 1 + this.map[address] = this.k + this.addresses.push(address) + + return address +} + +Chain.prototype.pop = function () { + var address = this.addresses.pop() + delete this.map[address] + this.k -= 1 + + return address +} + +module.exports = Chain + + +/***/ }), +/* 211 */ +/***/ (function(module, exports, __webpack_require__) { + +// style-loader: Adds some css to the DOM by adding a <style> tag + +// load the styles +var content = __webpack_require__(212); +if(typeof content === 'string') content = [[module.i, content, '']]; +// Prepare cssTransformation +var transform; + +var options = {} +options.transform = transform +// add the styles to the DOM +var update = __webpack_require__(118)(content, options); +if(content.locals) module.exports = content.locals; +// Hot Module Replacement +if(false) { + // When the styles change, update the <style> tags + if(!content.locals) { + module.hot.accept("!!../../../css-loader/index.js!./bootstrap.css", function() { + var newContent = require("!!../../../css-loader/index.js!./bootstrap.css"); + if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; + update(newContent); + }); + } + // When the module is disposed, remove the <style> tags + module.hot.dispose(function() { update(); }); +} + +/***/ }), +/* 212 */ +/***/ (function(module, exports, __webpack_require__) { + +exports = module.exports = __webpack_require__(117)(undefined); +// imports + + +// module +exports.push([module.i, "/*!\n * Bootstrap v4.0.0-alpha.6 (https://getbootstrap.com)\n * Copyright 2011-2017 The Bootstrap Authors\n * Copyright 2011-2017 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n */\n/*! normalize.css v5.0.0 | MIT License | github.com/necolas/normalize.css */\nhtml {\n font-family: sans-serif;\n line-height: 1.15;\n -ms-text-size-adjust: 100%;\n -webkit-text-size-adjust: 100%;\n}\n\nbody {\n margin: 0;\n}\n\narticle,\naside,\nfooter,\nheader,\nnav,\nsection {\n display: block;\n}\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\nfigcaption,\nfigure,\nmain {\n display: block;\n}\n\nfigure {\n margin: 1em 40px;\n}\n\nhr {\n -webkit-box-sizing: content-box;\n box-sizing: content-box;\n height: 0;\n overflow: visible;\n}\n\npre {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\na {\n background-color: transparent;\n -webkit-text-decoration-skip: objects;\n}\n\na:active,\na:hover {\n outline-width: 0;\n}\n\nabbr[title] {\n border-bottom: none;\n text-decoration: underline;\n text-decoration: underline dotted;\n}\n\nb,\nstrong {\n font-weight: inherit;\n}\n\nb,\nstrong {\n font-weight: bolder;\n}\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\ndfn {\n font-style: italic;\n}\n\nmark {\n background-color: #ff0;\n color: #000;\n}\n\nsmall {\n font-size: 80%;\n}\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\naudio,\nvideo {\n display: inline-block;\n}\n\naudio:not([controls]) {\n display: none;\n height: 0;\n}\n\nimg {\n border-style: none;\n}\n\nsvg:not(:root) {\n overflow: hidden;\n}\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: sans-serif;\n font-size: 100%;\n line-height: 1.15;\n margin: 0;\n}\n\nbutton,\ninput {\n overflow: visible;\n}\n\nbutton,\nselect {\n text-transform: none;\n}\n\nbutton,\nhtml [type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\nfieldset {\n border: 1px solid #c0c0c0;\n margin: 0 2px;\n padding: 0.35em 0.625em 0.75em;\n}\n\nlegend {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: inherit;\n display: table;\n max-width: 100%;\n padding: 0;\n white-space: normal;\n}\n\nprogress {\n display: inline-block;\n vertical-align: baseline;\n}\n\ntextarea {\n overflow: auto;\n}\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n padding: 0;\n}\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n[type=\"search\"] {\n -webkit-appearance: textfield;\n outline-offset: -2px;\n}\n\n[type=\"search\"]::-webkit-search-cancel-button,\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n::-webkit-file-upload-button {\n -webkit-appearance: button;\n font: inherit;\n}\n\ndetails,\nmenu {\n display: block;\n}\n\nsummary {\n display: list-item;\n}\n\ncanvas {\n display: inline-block;\n}\n\ntemplate {\n display: none;\n}\n\n[hidden] {\n display: none;\n}\n\n@media print {\n *,\n *::before,\n *::after,\n p::first-letter,\n div::first-letter,\n blockquote::first-letter,\n li::first-letter,\n p::first-line,\n div::first-line,\n blockquote::first-line,\n li::first-line {\n text-shadow: none !important;\n -webkit-box-shadow: none !important;\n box-shadow: none !important;\n }\n a,\n a:visited {\n text-decoration: underline;\n }\n abbr[title]::after {\n content: \" (\" attr(title) \")\";\n }\n pre {\n white-space: pre-wrap !important;\n }\n pre,\n blockquote {\n border: 1px solid #999;\n page-break-inside: avoid;\n }\n thead {\n display: table-header-group;\n }\n tr,\n img {\n page-break-inside: avoid;\n }\n p,\n h2,\n h3 {\n orphans: 3;\n widows: 3;\n }\n h2,\n h3 {\n page-break-after: avoid;\n }\n .navbar {\n display: none;\n }\n .badge {\n border: 1px solid #000;\n }\n .table {\n border-collapse: collapse !important;\n }\n .table td,\n .table th {\n background-color: #fff !important;\n }\n .table-bordered th,\n .table-bordered td {\n border: 1px solid #ddd !important;\n }\n}\n\nhtml {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n}\n\n*,\n*::before,\n*::after {\n -webkit-box-sizing: inherit;\n box-sizing: inherit;\n}\n\n@-ms-viewport {\n width: device-width;\n}\n\nhtml {\n -ms-overflow-style: scrollbar;\n -webkit-tap-highlight-color: transparent;\n}\n\nbody {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.5;\n color: #292b2c;\n background-color: #fff;\n}\n\n[tabindex=\"-1\"]:focus {\n outline: none !important;\n}\n\nh1, h2, h3, h4, h5, h6 {\n margin-top: 0;\n margin-bottom: .5rem;\n}\n\np {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nabbr[title],\nabbr[data-original-title] {\n cursor: help;\n}\n\naddress {\n margin-bottom: 1rem;\n font-style: normal;\n line-height: inherit;\n}\n\nol,\nul,\ndl {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nol ol,\nul ul,\nol ul,\nul ol {\n margin-bottom: 0;\n}\n\ndt {\n font-weight: bold;\n}\n\ndd {\n margin-bottom: .5rem;\n margin-left: 0;\n}\n\nblockquote {\n margin: 0 0 1rem;\n}\n\na {\n color: #0275d8;\n text-decoration: none;\n}\n\na:focus, a:hover {\n color: #014c8c;\n text-decoration: underline;\n}\n\na:not([href]):not([tabindex]) {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus, a:not([href]):not([tabindex]):hover {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus {\n outline: 0;\n}\n\npre {\n margin-top: 0;\n margin-bottom: 1rem;\n overflow: auto;\n}\n\nfigure {\n margin: 0 0 1rem;\n}\n\nimg {\n vertical-align: middle;\n}\n\n[role=\"button\"] {\n cursor: pointer;\n}\n\na,\narea,\nbutton,\n[role=\"button\"],\ninput,\nlabel,\nselect,\nsummary,\ntextarea {\n -ms-touch-action: manipulation;\n touch-action: manipulation;\n}\n\ntable {\n border-collapse: collapse;\n background-color: transparent;\n}\n\ncaption {\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n color: #636c72;\n text-align: left;\n caption-side: bottom;\n}\n\nth {\n text-align: left;\n}\n\nlabel {\n display: inline-block;\n margin-bottom: .5rem;\n}\n\nbutton:focus {\n outline: 1px dotted;\n outline: 5px auto -webkit-focus-ring-color;\n}\n\ninput,\nbutton,\nselect,\ntextarea {\n line-height: inherit;\n}\n\ninput[type=\"radio\"]:disabled,\ninput[type=\"checkbox\"]:disabled {\n cursor: not-allowed;\n}\n\ninput[type=\"date\"],\ninput[type=\"time\"],\ninput[type=\"datetime-local\"],\ninput[type=\"month\"] {\n -webkit-appearance: listbox;\n}\n\ntextarea {\n resize: vertical;\n}\n\nfieldset {\n min-width: 0;\n padding: 0;\n margin: 0;\n border: 0;\n}\n\nlegend {\n display: block;\n width: 100%;\n padding: 0;\n margin-bottom: .5rem;\n font-size: 1.5rem;\n line-height: inherit;\n}\n\ninput[type=\"search\"] {\n -webkit-appearance: none;\n}\n\noutput {\n display: inline-block;\n}\n\n[hidden] {\n display: none !important;\n}\n\nh1, h2, h3, h4, h5, h6,\n.h1, .h2, .h3, .h4, .h5, .h6 {\n margin-bottom: 0.5rem;\n font-family: inherit;\n font-weight: 500;\n line-height: 1.1;\n color: inherit;\n}\n\nh1, .h1 {\n font-size: 2.5rem;\n}\n\nh2, .h2 {\n font-size: 2rem;\n}\n\nh3, .h3 {\n font-size: 1.75rem;\n}\n\nh4, .h4 {\n font-size: 1.5rem;\n}\n\nh5, .h5 {\n font-size: 1.25rem;\n}\n\nh6, .h6 {\n font-size: 1rem;\n}\n\n.lead {\n font-size: 1.25rem;\n font-weight: 300;\n}\n\n.display-1 {\n font-size: 6rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-2 {\n font-size: 5.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-3 {\n font-size: 4.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-4 {\n font-size: 3.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\nhr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n border: 0;\n border-top: 1px solid rgba(0, 0, 0, 0.1);\n}\n\nsmall,\n.small {\n font-size: 80%;\n font-weight: normal;\n}\n\nmark,\n.mark {\n padding: 0.2em;\n background-color: #fcf8e3;\n}\n\n.list-unstyled {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline-item {\n display: inline-block;\n}\n\n.list-inline-item:not(:last-child) {\n margin-right: 5px;\n}\n\n.initialism {\n font-size: 90%;\n text-transform: uppercase;\n}\n\n.blockquote {\n padding: 0.5rem 1rem;\n margin-bottom: 1rem;\n font-size: 1.25rem;\n border-left: 0.25rem solid #eceeef;\n}\n\n.blockquote-footer {\n display: block;\n font-size: 80%;\n color: #636c72;\n}\n\n.blockquote-footer::before {\n content: \"\\2014 \\A0\";\n}\n\n.blockquote-reverse {\n padding-right: 1rem;\n padding-left: 0;\n text-align: right;\n border-right: 0.25rem solid #eceeef;\n border-left: 0;\n}\n\n.blockquote-reverse .blockquote-footer::before {\n content: \"\";\n}\n\n.blockquote-reverse .blockquote-footer::after {\n content: \"\\A0 \\2014\";\n}\n\n.img-fluid {\n max-width: 100%;\n height: auto;\n}\n\n.img-thumbnail {\n padding: 0.25rem;\n background-color: #fff;\n border: 1px solid #ddd;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n max-width: 100%;\n height: auto;\n}\n\n.figure {\n display: inline-block;\n}\n\n.figure-img {\n margin-bottom: 0.5rem;\n line-height: 1;\n}\n\n.figure-caption {\n font-size: 90%;\n color: #636c72;\n}\n\ncode,\nkbd,\npre,\nsamp {\n font-family: Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;\n}\n\ncode {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #bd4147;\n background-color: #f7f7f9;\n border-radius: 0.25rem;\n}\n\na > code {\n padding: 0;\n color: inherit;\n background-color: inherit;\n}\n\nkbd {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #fff;\n background-color: #292b2c;\n border-radius: 0.2rem;\n}\n\nkbd kbd {\n padding: 0;\n font-size: 100%;\n font-weight: bold;\n}\n\npre {\n display: block;\n margin-top: 0;\n margin-bottom: 1rem;\n font-size: 90%;\n color: #292b2c;\n}\n\npre code {\n padding: 0;\n font-size: inherit;\n color: inherit;\n background-color: transparent;\n border-radius: 0;\n}\n\n.pre-scrollable {\n max-height: 340px;\n overflow-y: scroll;\n}\n\n.container {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .container {\n width: 540px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n width: 720px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n width: 960px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n width: 1140px;\n max-width: 100%;\n }\n}\n\n.container-fluid {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.row {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: wrap;\n -ms-flex-wrap: wrap;\n flex-wrap: wrap;\n margin-right: -15px;\n margin-left: -15px;\n}\n\n@media (min-width: 576px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 768px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 992px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 1200px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n.no-gutters {\n margin-right: 0;\n margin-left: 0;\n}\n\n.no-gutters > .col,\n.no-gutters > [class*=\"col-\"] {\n padding-right: 0;\n padding-left: 0;\n}\n\n.col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n position: relative;\n width: 100%;\n min-height: 1px;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.col {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n}\n\n.col-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n}\n\n.col-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n}\n\n.col-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n}\n\n.col-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n}\n\n.col-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n}\n\n.col-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n}\n\n.col-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n}\n\n.col-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n}\n\n.col-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n}\n\n.col-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n}\n\n.col-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n}\n\n.col-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n}\n\n.col-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n}\n\n.pull-0 {\n right: auto;\n}\n\n.pull-1 {\n right: 8.333333%;\n}\n\n.pull-2 {\n right: 16.666667%;\n}\n\n.pull-3 {\n right: 25%;\n}\n\n.pull-4 {\n right: 33.333333%;\n}\n\n.pull-5 {\n right: 41.666667%;\n}\n\n.pull-6 {\n right: 50%;\n}\n\n.pull-7 {\n right: 58.333333%;\n}\n\n.pull-8 {\n right: 66.666667%;\n}\n\n.pull-9 {\n right: 75%;\n}\n\n.pull-10 {\n right: 83.333333%;\n}\n\n.pull-11 {\n right: 91.666667%;\n}\n\n.pull-12 {\n right: 100%;\n}\n\n.push-0 {\n left: auto;\n}\n\n.push-1 {\n left: 8.333333%;\n}\n\n.push-2 {\n left: 16.666667%;\n}\n\n.push-3 {\n left: 25%;\n}\n\n.push-4 {\n left: 33.333333%;\n}\n\n.push-5 {\n left: 41.666667%;\n}\n\n.push-6 {\n left: 50%;\n}\n\n.push-7 {\n left: 58.333333%;\n}\n\n.push-8 {\n left: 66.666667%;\n}\n\n.push-9 {\n left: 75%;\n}\n\n.push-10 {\n left: 83.333333%;\n}\n\n.push-11 {\n left: 91.666667%;\n}\n\n.push-12 {\n left: 100%;\n}\n\n.offset-1 {\n margin-left: 8.333333%;\n}\n\n.offset-2 {\n margin-left: 16.666667%;\n}\n\n.offset-3 {\n margin-left: 25%;\n}\n\n.offset-4 {\n margin-left: 33.333333%;\n}\n\n.offset-5 {\n margin-left: 41.666667%;\n}\n\n.offset-6 {\n margin-left: 50%;\n}\n\n.offset-7 {\n margin-left: 58.333333%;\n}\n\n.offset-8 {\n margin-left: 66.666667%;\n}\n\n.offset-9 {\n margin-left: 75%;\n}\n\n.offset-10 {\n margin-left: 83.333333%;\n}\n\n.offset-11 {\n margin-left: 91.666667%;\n}\n\n@media (min-width: 576px) {\n .col-sm {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-sm-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-sm-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-sm-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-sm-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-sm-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-sm-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-sm-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-sm-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-sm-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-sm-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-sm-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-sm-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-sm-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-sm-0 {\n right: auto;\n }\n .pull-sm-1 {\n right: 8.333333%;\n }\n .pull-sm-2 {\n right: 16.666667%;\n }\n .pull-sm-3 {\n right: 25%;\n }\n .pull-sm-4 {\n right: 33.333333%;\n }\n .pull-sm-5 {\n right: 41.666667%;\n }\n .pull-sm-6 {\n right: 50%;\n }\n .pull-sm-7 {\n right: 58.333333%;\n }\n .pull-sm-8 {\n right: 66.666667%;\n }\n .pull-sm-9 {\n right: 75%;\n }\n .pull-sm-10 {\n right: 83.333333%;\n }\n .pull-sm-11 {\n right: 91.666667%;\n }\n .pull-sm-12 {\n right: 100%;\n }\n .push-sm-0 {\n left: auto;\n }\n .push-sm-1 {\n left: 8.333333%;\n }\n .push-sm-2 {\n left: 16.666667%;\n }\n .push-sm-3 {\n left: 25%;\n }\n .push-sm-4 {\n left: 33.333333%;\n }\n .push-sm-5 {\n left: 41.666667%;\n }\n .push-sm-6 {\n left: 50%;\n }\n .push-sm-7 {\n left: 58.333333%;\n }\n .push-sm-8 {\n left: 66.666667%;\n }\n .push-sm-9 {\n left: 75%;\n }\n .push-sm-10 {\n left: 83.333333%;\n }\n .push-sm-11 {\n left: 91.666667%;\n }\n .push-sm-12 {\n left: 100%;\n }\n .offset-sm-0 {\n margin-left: 0%;\n }\n .offset-sm-1 {\n margin-left: 8.333333%;\n }\n .offset-sm-2 {\n margin-left: 16.666667%;\n }\n .offset-sm-3 {\n margin-left: 25%;\n }\n .offset-sm-4 {\n margin-left: 33.333333%;\n }\n .offset-sm-5 {\n margin-left: 41.666667%;\n }\n .offset-sm-6 {\n margin-left: 50%;\n }\n .offset-sm-7 {\n margin-left: 58.333333%;\n }\n .offset-sm-8 {\n margin-left: 66.666667%;\n }\n .offset-sm-9 {\n margin-left: 75%;\n }\n .offset-sm-10 {\n margin-left: 83.333333%;\n }\n .offset-sm-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 768px) {\n .col-md {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-md-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-md-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-md-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-md-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-md-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-md-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-md-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-md-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-md-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-md-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-md-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-md-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-md-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-md-0 {\n right: auto;\n }\n .pull-md-1 {\n right: 8.333333%;\n }\n .pull-md-2 {\n right: 16.666667%;\n }\n .pull-md-3 {\n right: 25%;\n }\n .pull-md-4 {\n right: 33.333333%;\n }\n .pull-md-5 {\n right: 41.666667%;\n }\n .pull-md-6 {\n right: 50%;\n }\n .pull-md-7 {\n right: 58.333333%;\n }\n .pull-md-8 {\n right: 66.666667%;\n }\n .pull-md-9 {\n right: 75%;\n }\n .pull-md-10 {\n right: 83.333333%;\n }\n .pull-md-11 {\n right: 91.666667%;\n }\n .pull-md-12 {\n right: 100%;\n }\n .push-md-0 {\n left: auto;\n }\n .push-md-1 {\n left: 8.333333%;\n }\n .push-md-2 {\n left: 16.666667%;\n }\n .push-md-3 {\n left: 25%;\n }\n .push-md-4 {\n left: 33.333333%;\n }\n .push-md-5 {\n left: 41.666667%;\n }\n .push-md-6 {\n left: 50%;\n }\n .push-md-7 {\n left: 58.333333%;\n }\n .push-md-8 {\n left: 66.666667%;\n }\n .push-md-9 {\n left: 75%;\n }\n .push-md-10 {\n left: 83.333333%;\n }\n .push-md-11 {\n left: 91.666667%;\n }\n .push-md-12 {\n left: 100%;\n }\n .offset-md-0 {\n margin-left: 0%;\n }\n .offset-md-1 {\n margin-left: 8.333333%;\n }\n .offset-md-2 {\n margin-left: 16.666667%;\n }\n .offset-md-3 {\n margin-left: 25%;\n }\n .offset-md-4 {\n margin-left: 33.333333%;\n }\n .offset-md-5 {\n margin-left: 41.666667%;\n }\n .offset-md-6 {\n margin-left: 50%;\n }\n .offset-md-7 {\n margin-left: 58.333333%;\n }\n .offset-md-8 {\n margin-left: 66.666667%;\n }\n .offset-md-9 {\n margin-left: 75%;\n }\n .offset-md-10 {\n margin-left: 83.333333%;\n }\n .offset-md-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 992px) {\n .col-lg {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-lg-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-lg-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-lg-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-lg-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-lg-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-lg-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-lg-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-lg-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-lg-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-lg-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-lg-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-lg-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-lg-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-lg-0 {\n right: auto;\n }\n .pull-lg-1 {\n right: 8.333333%;\n }\n .pull-lg-2 {\n right: 16.666667%;\n }\n .pull-lg-3 {\n right: 25%;\n }\n .pull-lg-4 {\n right: 33.333333%;\n }\n .pull-lg-5 {\n right: 41.666667%;\n }\n .pull-lg-6 {\n right: 50%;\n }\n .pull-lg-7 {\n right: 58.333333%;\n }\n .pull-lg-8 {\n right: 66.666667%;\n }\n .pull-lg-9 {\n right: 75%;\n }\n .pull-lg-10 {\n right: 83.333333%;\n }\n .pull-lg-11 {\n right: 91.666667%;\n }\n .pull-lg-12 {\n right: 100%;\n }\n .push-lg-0 {\n left: auto;\n }\n .push-lg-1 {\n left: 8.333333%;\n }\n .push-lg-2 {\n left: 16.666667%;\n }\n .push-lg-3 {\n left: 25%;\n }\n .push-lg-4 {\n left: 33.333333%;\n }\n .push-lg-5 {\n left: 41.666667%;\n }\n .push-lg-6 {\n left: 50%;\n }\n .push-lg-7 {\n left: 58.333333%;\n }\n .push-lg-8 {\n left: 66.666667%;\n }\n .push-lg-9 {\n left: 75%;\n }\n .push-lg-10 {\n left: 83.333333%;\n }\n .push-lg-11 {\n left: 91.666667%;\n }\n .push-lg-12 {\n left: 100%;\n }\n .offset-lg-0 {\n margin-left: 0%;\n }\n .offset-lg-1 {\n margin-left: 8.333333%;\n }\n .offset-lg-2 {\n margin-left: 16.666667%;\n }\n .offset-lg-3 {\n margin-left: 25%;\n }\n .offset-lg-4 {\n margin-left: 33.333333%;\n }\n .offset-lg-5 {\n margin-left: 41.666667%;\n }\n .offset-lg-6 {\n margin-left: 50%;\n }\n .offset-lg-7 {\n margin-left: 58.333333%;\n }\n .offset-lg-8 {\n margin-left: 66.666667%;\n }\n .offset-lg-9 {\n margin-left: 75%;\n }\n .offset-lg-10 {\n margin-left: 83.333333%;\n }\n .offset-lg-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 1200px) {\n .col-xl {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-xl-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-xl-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-xl-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-xl-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-xl-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-xl-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-xl-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-xl-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-xl-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-xl-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-xl-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-xl-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-xl-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-xl-0 {\n right: auto;\n }\n .pull-xl-1 {\n right: 8.333333%;\n }\n .pull-xl-2 {\n right: 16.666667%;\n }\n .pull-xl-3 {\n right: 25%;\n }\n .pull-xl-4 {\n right: 33.333333%;\n }\n .pull-xl-5 {\n right: 41.666667%;\n }\n .pull-xl-6 {\n right: 50%;\n }\n .pull-xl-7 {\n right: 58.333333%;\n }\n .pull-xl-8 {\n right: 66.666667%;\n }\n .pull-xl-9 {\n right: 75%;\n }\n .pull-xl-10 {\n right: 83.333333%;\n }\n .pull-xl-11 {\n right: 91.666667%;\n }\n .pull-xl-12 {\n right: 100%;\n }\n .push-xl-0 {\n left: auto;\n }\n .push-xl-1 {\n left: 8.333333%;\n }\n .push-xl-2 {\n left: 16.666667%;\n }\n .push-xl-3 {\n left: 25%;\n }\n .push-xl-4 {\n left: 33.333333%;\n }\n .push-xl-5 {\n left: 41.666667%;\n }\n .push-xl-6 {\n left: 50%;\n }\n .push-xl-7 {\n left: 58.333333%;\n }\n .push-xl-8 {\n left: 66.666667%;\n }\n .push-xl-9 {\n left: 75%;\n }\n .push-xl-10 {\n left: 83.333333%;\n }\n .push-xl-11 {\n left: 91.666667%;\n }\n .push-xl-12 {\n left: 100%;\n }\n .offset-xl-0 {\n margin-left: 0%;\n }\n .offset-xl-1 {\n margin-left: 8.333333%;\n }\n .offset-xl-2 {\n margin-left: 16.666667%;\n }\n .offset-xl-3 {\n margin-left: 25%;\n }\n .offset-xl-4 {\n margin-left: 33.333333%;\n }\n .offset-xl-5 {\n margin-left: 41.666667%;\n }\n .offset-xl-6 {\n margin-left: 50%;\n }\n .offset-xl-7 {\n margin-left: 58.333333%;\n }\n .offset-xl-8 {\n margin-left: 66.666667%;\n }\n .offset-xl-9 {\n margin-left: 75%;\n }\n .offset-xl-10 {\n margin-left: 83.333333%;\n }\n .offset-xl-11 {\n margin-left: 91.666667%;\n }\n}\n\n.table {\n width: 100%;\n max-width: 100%;\n margin-bottom: 1rem;\n}\n\n.table th,\n.table td {\n padding: 0.75rem;\n vertical-align: top;\n border-top: 1px solid #eceeef;\n}\n\n.table thead th {\n vertical-align: bottom;\n border-bottom: 2px solid #eceeef;\n}\n\n.table tbody + tbody {\n border-top: 2px solid #eceeef;\n}\n\n.table .table {\n background-color: #fff;\n}\n\n.table-sm th,\n.table-sm td {\n padding: 0.3rem;\n}\n\n.table-bordered {\n border: 1px solid #eceeef;\n}\n\n.table-bordered th,\n.table-bordered td {\n border: 1px solid #eceeef;\n}\n\n.table-bordered thead th,\n.table-bordered thead td {\n border-bottom-width: 2px;\n}\n\n.table-striped tbody tr:nth-of-type(odd) {\n background-color: rgba(0, 0, 0, 0.05);\n}\n\n.table-hover tbody tr:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-active,\n.table-active > th,\n.table-active > td {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover > td,\n.table-hover .table-active:hover > th {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-success,\n.table-success > th,\n.table-success > td {\n background-color: #dff0d8;\n}\n\n.table-hover .table-success:hover {\n background-color: #d0e9c6;\n}\n\n.table-hover .table-success:hover > td,\n.table-hover .table-success:hover > th {\n background-color: #d0e9c6;\n}\n\n.table-info,\n.table-info > th,\n.table-info > td {\n background-color: #d9edf7;\n}\n\n.table-hover .table-info:hover {\n background-color: #c4e3f3;\n}\n\n.table-hover .table-info:hover > td,\n.table-hover .table-info:hover > th {\n background-color: #c4e3f3;\n}\n\n.table-warning,\n.table-warning > th,\n.table-warning > td {\n background-color: #fcf8e3;\n}\n\n.table-hover .table-warning:hover {\n background-color: #faf2cc;\n}\n\n.table-hover .table-warning:hover > td,\n.table-hover .table-warning:hover > th {\n background-color: #faf2cc;\n}\n\n.table-danger,\n.table-danger > th,\n.table-danger > td {\n background-color: #f2dede;\n}\n\n.table-hover .table-danger:hover {\n background-color: #ebcccc;\n}\n\n.table-hover .table-danger:hover > td,\n.table-hover .table-danger:hover > th {\n background-color: #ebcccc;\n}\n\n.thead-inverse th {\n color: #fff;\n background-color: #292b2c;\n}\n\n.thead-default th {\n color: #464a4c;\n background-color: #eceeef;\n}\n\n.table-inverse {\n color: #fff;\n background-color: #292b2c;\n}\n\n.table-inverse th,\n.table-inverse td,\n.table-inverse thead th {\n border-color: #fff;\n}\n\n.table-inverse.table-bordered {\n border: 0;\n}\n\n.table-responsive {\n display: block;\n width: 100%;\n overflow-x: auto;\n -ms-overflow-style: -ms-autohiding-scrollbar;\n}\n\n.table-responsive.table-bordered {\n border: 0;\n}\n\n.form-control {\n display: block;\n width: 100%;\n padding: 0.5rem 0.75rem;\n font-size: 1rem;\n line-height: 1.25;\n color: #464a4c;\n background-color: #fff;\n background-image: none;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -webkit-transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n -o-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n}\n\n.form-control::-ms-expand {\n background-color: transparent;\n border: 0;\n}\n\n.form-control:focus {\n color: #464a4c;\n background-color: #fff;\n border-color: #5cb3fd;\n outline: none;\n}\n\n.form-control::-webkit-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::-moz-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:-ms-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:disabled, .form-control[readonly] {\n background-color: #eceeef;\n opacity: 1;\n}\n\n.form-control:disabled {\n cursor: not-allowed;\n}\n\nselect.form-control:not([size]):not([multiple]) {\n height: calc(2.25rem + 2px);\n}\n\nselect.form-control:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.form-control-file,\n.form-control-range {\n display: block;\n}\n\n.col-form-label {\n padding-top: calc(0.5rem - 1px * 2);\n padding-bottom: calc(0.5rem - 1px * 2);\n margin-bottom: 0;\n}\n\n.col-form-label-lg {\n padding-top: calc(0.75rem - 1px * 2);\n padding-bottom: calc(0.75rem - 1px * 2);\n font-size: 1.25rem;\n}\n\n.col-form-label-sm {\n padding-top: calc(0.25rem - 1px * 2);\n padding-bottom: calc(0.25rem - 1px * 2);\n font-size: 0.875rem;\n}\n\n.col-form-legend {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n font-size: 1rem;\n}\n\n.form-control-static {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n line-height: 1.25;\n border: solid transparent;\n border-width: 1px 0;\n}\n\n.form-control-static.form-control-sm, .input-group-sm > .form-control-static.form-control,\n.input-group-sm > .form-control-static.input-group-addon,\n.input-group-sm > .input-group-btn > .form-control-static.btn, .form-control-static.form-control-lg, .input-group-lg > .form-control-static.form-control,\n.input-group-lg > .form-control-static.input-group-addon,\n.input-group-lg > .input-group-btn > .form-control-static.btn {\n padding-right: 0;\n padding-left: 0;\n}\n\n.form-control-sm, .input-group-sm > .form-control,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\nselect.form-control-sm:not([size]):not([multiple]), .input-group-sm > select.form-control:not([size]):not([multiple]),\n.input-group-sm > select.input-group-addon:not([size]):not([multiple]),\n.input-group-sm > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 1.8125rem;\n}\n\n.form-control-lg, .input-group-lg > .form-control,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\nselect.form-control-lg:not([size]):not([multiple]), .input-group-lg > select.form-control:not([size]):not([multiple]),\n.input-group-lg > select.input-group-addon:not([size]):not([multiple]),\n.input-group-lg > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 3.166667rem;\n}\n\n.form-group {\n margin-bottom: 1rem;\n}\n\n.form-text {\n display: block;\n margin-top: 0.25rem;\n}\n\n.form-check {\n position: relative;\n display: block;\n margin-bottom: 0.5rem;\n}\n\n.form-check.disabled .form-check-label {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.form-check-label {\n padding-left: 1.25rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.form-check-input {\n position: absolute;\n margin-top: 0.25rem;\n margin-left: -1.25rem;\n}\n\n.form-check-input:only-child {\n position: static;\n}\n\n.form-check-inline {\n display: inline-block;\n}\n\n.form-check-inline .form-check-label {\n vertical-align: middle;\n}\n\n.form-check-inline + .form-check-inline {\n margin-left: 0.75rem;\n}\n\n.form-control-feedback {\n margin-top: 0.25rem;\n}\n\n.form-control-success,\n.form-control-warning,\n.form-control-danger {\n padding-right: 2.25rem;\n background-repeat: no-repeat;\n background-position: center right 0.5625rem;\n -webkit-background-size: 1.125rem 1.125rem;\n background-size: 1.125rem 1.125rem;\n}\n\n.has-success .form-control-feedback,\n.has-success .form-control-label,\n.has-success .col-form-label,\n.has-success .form-check-label,\n.has-success .custom-control {\n color: #5cb85c;\n}\n\n.has-success .form-control {\n border-color: #5cb85c;\n}\n\n.has-success .input-group-addon {\n color: #5cb85c;\n border-color: #5cb85c;\n background-color: #eaf6ea;\n}\n\n.has-success .form-control-success {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%235cb85c' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3E%3C/svg%3E\");\n}\n\n.has-warning .form-control-feedback,\n.has-warning .form-control-label,\n.has-warning .col-form-label,\n.has-warning .form-check-label,\n.has-warning .custom-control {\n color: #f0ad4e;\n}\n\n.has-warning .form-control {\n border-color: #f0ad4e;\n}\n\n.has-warning .input-group-addon {\n color: #f0ad4e;\n border-color: #f0ad4e;\n background-color: white;\n}\n\n.has-warning .form-control-warning {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23f0ad4e' d='M4.4 5.324h-.8v-2.46h.8zm0 1.42h-.8V5.89h.8zM3.76.63L.04 7.075c-.115.2.016.425.26.426h7.397c.242 0 .372-.226.258-.426C6.726 4.924 5.47 2.79 4.253.63c-.113-.174-.39-.174-.494 0z'/%3E%3C/svg%3E\");\n}\n\n.has-danger .form-control-feedback,\n.has-danger .form-control-label,\n.has-danger .col-form-label,\n.has-danger .form-check-label,\n.has-danger .custom-control {\n color: #d9534f;\n}\n\n.has-danger .form-control {\n border-color: #d9534f;\n}\n\n.has-danger .input-group-addon {\n color: #d9534f;\n border-color: #d9534f;\n background-color: #fdf7f7;\n}\n\n.has-danger .form-control-danger {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23d9534f' viewBox='-2 -2 7 7'%3E%3Cpath stroke='%23d9534f' d='M0 0l3 3m0-3L0 3'/%3E%3Ccircle r='.5'/%3E%3Ccircle cx='3' r='.5'/%3E%3Ccircle cy='3' r='.5'/%3E%3Ccircle cx='3' cy='3' r='.5'/%3E%3C/svg%3E\");\n}\n\n.form-inline {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.form-inline .form-check {\n width: 100%;\n}\n\n@media (min-width: 576px) {\n .form-inline label {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n margin-bottom: 0;\n }\n .form-inline .form-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n margin-bottom: 0;\n }\n .form-inline .form-control {\n display: inline-block;\n width: auto;\n vertical-align: middle;\n }\n .form-inline .form-control-static {\n display: inline-block;\n }\n .form-inline .input-group {\n width: auto;\n }\n .form-inline .form-control-label {\n margin-bottom: 0;\n vertical-align: middle;\n }\n .form-inline .form-check {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: auto;\n margin-top: 0;\n margin-bottom: 0;\n }\n .form-inline .form-check-label {\n padding-left: 0;\n }\n .form-inline .form-check-input {\n position: relative;\n margin-top: 0;\n margin-right: 0.25rem;\n margin-left: 0;\n }\n .form-inline .custom-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n }\n .form-inline .custom-control-indicator {\n position: static;\n display: inline-block;\n margin-right: 0.25rem;\n vertical-align: text-bottom;\n }\n .form-inline .has-feedback .form-control-feedback {\n top: 0;\n }\n}\n\n.btn {\n display: inline-block;\n font-weight: normal;\n line-height: 1.25;\n text-align: center;\n white-space: nowrap;\n vertical-align: middle;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n border: 1px solid transparent;\n padding: 0.5rem 1rem;\n font-size: 1rem;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n}\n\n.btn:focus, .btn:hover {\n text-decoration: none;\n}\n\n.btn:focus, .btn.focus {\n outline: 0;\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n}\n\n.btn.disabled, .btn:disabled {\n cursor: not-allowed;\n opacity: .65;\n}\n\n.btn:active, .btn.active {\n background-image: none;\n}\n\na.btn.disabled,\nfieldset[disabled] a.btn {\n pointer-events: none;\n}\n\n.btn-primary {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:hover {\n color: #fff;\n background-color: #025aa5;\n border-color: #01549b;\n}\n\n.btn-primary:focus, .btn-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-primary.disabled, .btn-primary:disabled {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:active, .btn-primary.active,\n.show > .btn-primary.dropdown-toggle {\n color: #fff;\n background-color: #025aa5;\n background-image: none;\n border-color: #01549b;\n}\n\n.btn-secondary {\n color: #292b2c;\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:hover {\n color: #292b2c;\n background-color: #e6e6e6;\n border-color: #adadad;\n}\n\n.btn-secondary:focus, .btn-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-secondary.disabled, .btn-secondary:disabled {\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:active, .btn-secondary.active,\n.show > .btn-secondary.dropdown-toggle {\n color: #292b2c;\n background-color: #e6e6e6;\n background-image: none;\n border-color: #adadad;\n}\n\n.btn-info {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:hover {\n color: #fff;\n background-color: #31b0d5;\n border-color: #2aabd2;\n}\n\n.btn-info:focus, .btn-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-info.disabled, .btn-info:disabled {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:active, .btn-info.active,\n.show > .btn-info.dropdown-toggle {\n color: #fff;\n background-color: #31b0d5;\n background-image: none;\n border-color: #2aabd2;\n}\n\n.btn-success {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:hover {\n color: #fff;\n background-color: #449d44;\n border-color: #419641;\n}\n\n.btn-success:focus, .btn-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-success.disabled, .btn-success:disabled {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:active, .btn-success.active,\n.show > .btn-success.dropdown-toggle {\n color: #fff;\n background-color: #449d44;\n background-image: none;\n border-color: #419641;\n}\n\n.btn-warning {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:hover {\n color: #fff;\n background-color: #ec971f;\n border-color: #eb9316;\n}\n\n.btn-warning:focus, .btn-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-warning.disabled, .btn-warning:disabled {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:active, .btn-warning.active,\n.show > .btn-warning.dropdown-toggle {\n color: #fff;\n background-color: #ec971f;\n background-image: none;\n border-color: #eb9316;\n}\n\n.btn-danger {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:hover {\n color: #fff;\n background-color: #c9302c;\n border-color: #c12e2a;\n}\n\n.btn-danger:focus, .btn-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-danger.disabled, .btn-danger:disabled {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:active, .btn-danger.active,\n.show > .btn-danger.dropdown-toggle {\n color: #fff;\n background-color: #c9302c;\n background-image: none;\n border-color: #c12e2a;\n}\n\n.btn-outline-primary {\n color: #0275d8;\n background-image: none;\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:hover {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:focus, .btn-outline-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-outline-primary.disabled, .btn-outline-primary:disabled {\n color: #0275d8;\n background-color: transparent;\n}\n\n.btn-outline-primary:active, .btn-outline-primary.active,\n.show > .btn-outline-primary.dropdown-toggle {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-secondary {\n color: #ccc;\n background-image: none;\n background-color: transparent;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:hover {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:focus, .btn-outline-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-outline-secondary.disabled, .btn-outline-secondary:disabled {\n color: #ccc;\n background-color: transparent;\n}\n\n.btn-outline-secondary:active, .btn-outline-secondary.active,\n.show > .btn-outline-secondary.dropdown-toggle {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-info {\n color: #5bc0de;\n background-image: none;\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:hover {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:focus, .btn-outline-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-outline-info.disabled, .btn-outline-info:disabled {\n color: #5bc0de;\n background-color: transparent;\n}\n\n.btn-outline-info:active, .btn-outline-info.active,\n.show > .btn-outline-info.dropdown-toggle {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-success {\n color: #5cb85c;\n background-image: none;\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:hover {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:focus, .btn-outline-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-outline-success.disabled, .btn-outline-success:disabled {\n color: #5cb85c;\n background-color: transparent;\n}\n\n.btn-outline-success:active, .btn-outline-success.active,\n.show > .btn-outline-success.dropdown-toggle {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-warning {\n color: #f0ad4e;\n background-image: none;\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:hover {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:focus, .btn-outline-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-outline-warning.disabled, .btn-outline-warning:disabled {\n color: #f0ad4e;\n background-color: transparent;\n}\n\n.btn-outline-warning:active, .btn-outline-warning.active,\n.show > .btn-outline-warning.dropdown-toggle {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-danger {\n color: #d9534f;\n background-image: none;\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:hover {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:focus, .btn-outline-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-outline-danger.disabled, .btn-outline-danger:disabled {\n color: #d9534f;\n background-color: transparent;\n}\n\n.btn-outline-danger:active, .btn-outline-danger.active,\n.show > .btn-outline-danger.dropdown-toggle {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-link {\n font-weight: normal;\n color: #0275d8;\n border-radius: 0;\n}\n\n.btn-link, .btn-link:active, .btn-link.active, .btn-link:disabled {\n background-color: transparent;\n}\n\n.btn-link, .btn-link:focus, .btn-link:active {\n border-color: transparent;\n}\n\n.btn-link:hover {\n border-color: transparent;\n}\n\n.btn-link:focus, .btn-link:hover {\n color: #014c8c;\n text-decoration: underline;\n background-color: transparent;\n}\n\n.btn-link:disabled {\n color: #636c72;\n}\n\n.btn-link:disabled:focus, .btn-link:disabled:hover {\n text-decoration: none;\n}\n\n.btn-lg, .btn-group-lg > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.btn-sm, .btn-group-sm > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.btn-block {\n display: block;\n width: 100%;\n}\n\n.btn-block + .btn-block {\n margin-top: 0.5rem;\n}\n\ninput[type=\"submit\"].btn-block,\ninput[type=\"reset\"].btn-block,\ninput[type=\"button\"].btn-block {\n width: 100%;\n}\n\n.fade {\n opacity: 0;\n -webkit-transition: opacity 0.15s linear;\n -o-transition: opacity 0.15s linear;\n transition: opacity 0.15s linear;\n}\n\n.fade.show {\n opacity: 1;\n}\n\n.collapse {\n display: none;\n}\n\n.collapse.show {\n display: block;\n}\n\ntr.collapse.show {\n display: table-row;\n}\n\ntbody.collapse.show {\n display: table-row-group;\n}\n\n.collapsing {\n position: relative;\n height: 0;\n overflow: hidden;\n -webkit-transition: height 0.35s ease;\n -o-transition: height 0.35s ease;\n transition: height 0.35s ease;\n}\n\n.dropup,\n.dropdown {\n position: relative;\n}\n\n.dropdown-toggle::after {\n display: inline-block;\n width: 0;\n height: 0;\n margin-left: 0.3em;\n vertical-align: middle;\n content: \"\";\n border-top: 0.3em solid;\n border-right: 0.3em solid transparent;\n border-left: 0.3em solid transparent;\n}\n\n.dropdown-toggle:focus {\n outline: 0;\n}\n\n.dropup .dropdown-toggle::after {\n border-top: 0;\n border-bottom: 0.3em solid;\n}\n\n.dropdown-menu {\n position: absolute;\n top: 100%;\n left: 0;\n z-index: 1000;\n display: none;\n float: left;\n min-width: 10rem;\n padding: 0.5rem 0;\n margin: 0.125rem 0 0;\n font-size: 1rem;\n color: #292b2c;\n text-align: left;\n list-style: none;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.dropdown-divider {\n height: 1px;\n margin: 0.5rem 0;\n overflow: hidden;\n background-color: #eceeef;\n}\n\n.dropdown-item {\n display: block;\n width: 100%;\n padding: 3px 1.5rem;\n clear: both;\n font-weight: normal;\n color: #292b2c;\n text-align: inherit;\n white-space: nowrap;\n background: none;\n border: 0;\n}\n\n.dropdown-item:focus, .dropdown-item:hover {\n color: #1d1e1f;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.dropdown-item.active, .dropdown-item:active {\n color: #fff;\n text-decoration: none;\n background-color: #0275d8;\n}\n\n.dropdown-item.disabled, .dropdown-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: transparent;\n}\n\n.show > .dropdown-menu {\n display: block;\n}\n\n.show > a {\n outline: 0;\n}\n\n.dropdown-menu-right {\n right: 0;\n left: auto;\n}\n\n.dropdown-menu-left {\n right: auto;\n left: 0;\n}\n\n.dropdown-header {\n display: block;\n padding: 0.5rem 1.5rem;\n margin-bottom: 0;\n font-size: 0.875rem;\n color: #636c72;\n white-space: nowrap;\n}\n\n.dropdown-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 990;\n}\n\n.dropup .dropdown-menu {\n top: auto;\n bottom: 100%;\n margin-bottom: 0.125rem;\n}\n\n.btn-group,\n.btn-group-vertical {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n vertical-align: middle;\n}\n\n.btn-group > .btn,\n.btn-group-vertical > .btn {\n position: relative;\n -webkit-box-flex: 0;\n -webkit-flex: 0 1 auto;\n -ms-flex: 0 1 auto;\n flex: 0 1 auto;\n}\n\n.btn-group > .btn:hover,\n.btn-group-vertical > .btn:hover {\n z-index: 2;\n}\n\n.btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active,\n.btn-group-vertical > .btn:focus,\n.btn-group-vertical > .btn:active,\n.btn-group-vertical > .btn.active {\n z-index: 2;\n}\n\n.btn-group .btn + .btn,\n.btn-group .btn + .btn-group,\n.btn-group .btn-group + .btn,\n.btn-group .btn-group + .btn-group,\n.btn-group-vertical .btn + .btn,\n.btn-group-vertical .btn + .btn-group,\n.btn-group-vertical .btn-group + .btn,\n.btn-group-vertical .btn-group + .btn-group {\n margin-left: -1px;\n}\n\n.btn-toolbar {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: start;\n -webkit-justify-content: flex-start;\n -ms-flex-pack: start;\n justify-content: flex-start;\n}\n\n.btn-toolbar .input-group {\n width: auto;\n}\n\n.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {\n border-radius: 0;\n}\n\n.btn-group > .btn:first-child {\n margin-left: 0;\n}\n\n.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn:last-child:not(:first-child),\n.btn-group > .dropdown-toggle:not(:first-child) {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group > .btn-group {\n float: left;\n}\n\n.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group .dropdown-toggle:active,\n.btn-group.open .dropdown-toggle {\n outline: 0;\n}\n\n.btn + .dropdown-toggle-split {\n padding-right: 0.75rem;\n padding-left: 0.75rem;\n}\n\n.btn + .dropdown-toggle-split::after {\n margin-left: 0;\n}\n\n.btn-sm + .dropdown-toggle-split, .btn-group-sm > .btn + .dropdown-toggle-split {\n padding-right: 0.375rem;\n padding-left: 0.375rem;\n}\n\n.btn-lg + .dropdown-toggle-split, .btn-group-lg > .btn + .dropdown-toggle-split {\n padding-right: 1.125rem;\n padding-left: 1.125rem;\n}\n\n.btn-group-vertical {\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.btn-group-vertical .btn,\n.btn-group-vertical .btn-group {\n width: 100%;\n}\n\n.btn-group-vertical > .btn + .btn,\n.btn-group-vertical > .btn + .btn-group,\n.btn-group-vertical > .btn-group + .btn,\n.btn-group-vertical > .btn-group + .btn-group {\n margin-top: -1px;\n margin-left: 0;\n}\n\n.btn-group-vertical > .btn:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn:first-child:not(:last-child) {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn:last-child:not(:first-child) {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n[data-toggle=\"buttons\"] > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn input[type=\"checkbox\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"checkbox\"] {\n position: absolute;\n clip: rect(0, 0, 0, 0);\n pointer-events: none;\n}\n\n.input-group {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n width: 100%;\n}\n\n.input-group .form-control {\n position: relative;\n z-index: 2;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n width: 1%;\n margin-bottom: 0;\n}\n\n.input-group .form-control:focus, .input-group .form-control:active, .input-group .form-control:hover {\n z-index: 3;\n}\n\n.input-group-addon,\n.input-group-btn,\n.input-group .form-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.input-group-addon:not(:first-child):not(:last-child),\n.input-group-btn:not(:first-child):not(:last-child),\n.input-group .form-control:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.input-group-addon,\n.input-group-btn {\n white-space: nowrap;\n vertical-align: middle;\n}\n\n.input-group-addon {\n padding: 0.5rem 0.75rem;\n margin-bottom: 0;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.25;\n color: #464a4c;\n text-align: center;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.input-group-addon.form-control-sm,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .input-group-addon.btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.input-group-addon.form-control-lg,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .input-group-addon.btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.input-group-addon input[type=\"radio\"],\n.input-group-addon input[type=\"checkbox\"] {\n margin-top: 0;\n}\n\n.input-group .form-control:not(:last-child),\n.input-group-addon:not(:last-child),\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group > .btn,\n.input-group-btn:not(:last-child) > .dropdown-toggle,\n.input-group-btn:not(:first-child) > .btn:not(:last-child):not(.dropdown-toggle),\n.input-group-btn:not(:first-child) > .btn-group:not(:last-child) > .btn {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.input-group-addon:not(:last-child) {\n border-right: 0;\n}\n\n.input-group .form-control:not(:first-child),\n.input-group-addon:not(:first-child),\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group > .btn,\n.input-group-btn:not(:first-child) > .dropdown-toggle,\n.input-group-btn:not(:last-child) > .btn:not(:first-child),\n.input-group-btn:not(:last-child) > .btn-group:not(:first-child) > .btn {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.form-control + .input-group-addon:not(:first-child) {\n border-left: 0;\n}\n\n.input-group-btn {\n position: relative;\n font-size: 0;\n white-space: nowrap;\n}\n\n.input-group-btn > .btn {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.input-group-btn > .btn + .btn {\n margin-left: -1px;\n}\n\n.input-group-btn > .btn:focus, .input-group-btn > .btn:active, .input-group-btn > .btn:hover {\n z-index: 3;\n}\n\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group {\n margin-right: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group {\n z-index: 2;\n margin-left: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn:focus, .input-group-btn:not(:first-child) > .btn:active, .input-group-btn:not(:first-child) > .btn:hover,\n.input-group-btn:not(:first-child) > .btn-group:focus,\n.input-group-btn:not(:first-child) > .btn-group:active,\n.input-group-btn:not(:first-child) > .btn-group:hover {\n z-index: 3;\n}\n\n.custom-control {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n min-height: 1.5rem;\n padding-left: 1.5rem;\n margin-right: 1rem;\n cursor: pointer;\n}\n\n.custom-control-input {\n position: absolute;\n z-index: -1;\n opacity: 0;\n}\n\n.custom-control-input:checked ~ .custom-control-indicator {\n color: #fff;\n background-color: #0275d8;\n}\n\n.custom-control-input:focus ~ .custom-control-indicator {\n -webkit-box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n}\n\n.custom-control-input:active ~ .custom-control-indicator {\n color: #fff;\n background-color: #8fcafe;\n}\n\n.custom-control-input:disabled ~ .custom-control-indicator {\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-control-input:disabled ~ .custom-control-description {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.custom-control-indicator {\n position: absolute;\n top: 0.25rem;\n left: 0;\n display: block;\n width: 1rem;\n height: 1rem;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #ddd;\n background-repeat: no-repeat;\n background-position: center center;\n -webkit-background-size: 50% 50%;\n background-size: 50% 50%;\n}\n\n.custom-checkbox .custom-control-indicator {\n border-radius: 0.25rem;\n}\n\n.custom-checkbox .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26 2.974 7.25 8 2.193z'/%3E%3C/svg%3E\");\n}\n\n.custom-checkbox .custom-control-input:indeterminate ~ .custom-control-indicator {\n background-color: #0275d8;\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 4'%3E%3Cpath stroke='%23fff' d='M0 2h4'/%3E%3C/svg%3E\");\n}\n\n.custom-radio .custom-control-indicator {\n border-radius: 50%;\n}\n\n.custom-radio .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3E%3Ccircle r='3' fill='%23fff'/%3E%3C/svg%3E\");\n}\n\n.custom-controls-stacked {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n\n.custom-controls-stacked .custom-control {\n margin-bottom: 0.25rem;\n}\n\n.custom-controls-stacked .custom-control + .custom-control {\n margin-left: 0;\n}\n\n.custom-select {\n display: inline-block;\n max-width: 100%;\n height: calc(2.25rem + 2px);\n padding: 0.375rem 1.75rem 0.375rem 0.75rem;\n line-height: 1.25;\n color: #464a4c;\n vertical-align: middle;\n background: #fff url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23333' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E\") no-repeat right 0.75rem center;\n -webkit-background-size: 8px 10px;\n background-size: 8px 10px;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -moz-appearance: none;\n -webkit-appearance: none;\n}\n\n.custom-select:focus {\n border-color: #5cb3fd;\n outline: none;\n}\n\n.custom-select:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.custom-select:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-select::-ms-expand {\n opacity: 0;\n}\n\n.custom-select-sm {\n padding-top: 0.375rem;\n padding-bottom: 0.375rem;\n font-size: 75%;\n}\n\n.custom-file {\n position: relative;\n display: inline-block;\n max-width: 100%;\n height: 2.5rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.custom-file-input {\n min-width: 14rem;\n max-width: 100%;\n height: 2.5rem;\n margin: 0;\n filter: alpha(opacity=0);\n opacity: 0;\n}\n\n.custom-file-control {\n position: absolute;\n top: 0;\n right: 0;\n left: 0;\n z-index: 5;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.custom-file-control:lang(en)::after {\n content: \"Choose file...\";\n}\n\n.custom-file-control::before {\n position: absolute;\n top: -1px;\n right: -1px;\n bottom: -1px;\n z-index: 6;\n display: block;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0 0.25rem 0.25rem 0;\n}\n\n.custom-file-control:lang(en)::before {\n content: \"Browse\";\n}\n\n.nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.nav-link {\n display: block;\n padding: 0.5em 1em;\n}\n\n.nav-link:focus, .nav-link:hover {\n text-decoration: none;\n}\n\n.nav-link.disabled {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.nav-tabs {\n border-bottom: 1px solid #ddd;\n}\n\n.nav-tabs .nav-item {\n margin-bottom: -1px;\n}\n\n.nav-tabs .nav-link {\n border: 1px solid transparent;\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.nav-tabs .nav-link:focus, .nav-tabs .nav-link:hover {\n border-color: #eceeef #eceeef #ddd;\n}\n\n.nav-tabs .nav-link.disabled {\n color: #636c72;\n background-color: transparent;\n border-color: transparent;\n}\n\n.nav-tabs .nav-link.active,\n.nav-tabs .nav-item.show .nav-link {\n color: #464a4c;\n background-color: #fff;\n border-color: #ddd #ddd #fff;\n}\n\n.nav-tabs .dropdown-menu {\n margin-top: -1px;\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.nav-pills .nav-link {\n border-radius: 0.25rem;\n}\n\n.nav-pills .nav-link.active,\n.nav-pills .nav-item.show .nav-link {\n color: #fff;\n cursor: default;\n background-color: #0275d8;\n}\n\n.nav-fill .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n text-align: center;\n}\n\n.nav-justified .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 100%;\n -ms-flex: 1 1 100%;\n flex: 1 1 100%;\n text-align: center;\n}\n\n.tab-content > .tab-pane {\n display: none;\n}\n\n.tab-content > .active {\n display: block;\n}\n\n.navbar {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding: 0.5rem 1rem;\n}\n\n.navbar-brand {\n display: inline-block;\n padding-top: .25rem;\n padding-bottom: .25rem;\n margin-right: 1rem;\n font-size: 1.25rem;\n line-height: inherit;\n white-space: nowrap;\n}\n\n.navbar-brand:focus, .navbar-brand:hover {\n text-decoration: none;\n}\n\n.navbar-nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.navbar-nav .nav-link {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-text {\n display: inline-block;\n padding-top: .425rem;\n padding-bottom: .425rem;\n}\n\n.navbar-toggler {\n -webkit-align-self: flex-start;\n -ms-flex-item-align: start;\n align-self: flex-start;\n padding: 0.25rem 0.75rem;\n font-size: 1.25rem;\n line-height: 1;\n background: transparent;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.navbar-toggler:focus, .navbar-toggler:hover {\n text-decoration: none;\n}\n\n.navbar-toggler-icon {\n display: inline-block;\n width: 1.5em;\n height: 1.5em;\n vertical-align: middle;\n content: \"\";\n background: no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.navbar-toggler-left {\n position: absolute;\n left: 1rem;\n}\n\n.navbar-toggler-right {\n position: absolute;\n right: 1rem;\n}\n\n@media (max-width: 575px) {\n .navbar-toggleable .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 576px) {\n .navbar-toggleable {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 767px) {\n .navbar-toggleable-sm .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-sm > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 768px) {\n .navbar-toggleable-sm {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-sm .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-sm > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-sm .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 991px) {\n .navbar-toggleable-md .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-md > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 992px) {\n .navbar-toggleable-md {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-md .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-md > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-md .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 1199px) {\n .navbar-toggleable-lg .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-lg > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 1200px) {\n .navbar-toggleable-lg {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-lg .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-lg > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-lg .navbar-toggler {\n display: none;\n }\n}\n\n.navbar-toggleable-xl {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n}\n\n.navbar-toggleable-xl > .container {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-toggleable-xl .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n\n.navbar-toggleable-xl .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n}\n\n.navbar-toggleable-xl > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n}\n\n.navbar-toggleable-xl .navbar-toggler {\n display: none;\n}\n\n.navbar-light .navbar-brand,\n.navbar-light .navbar-toggler {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-brand:focus, .navbar-light .navbar-brand:hover,\n.navbar-light .navbar-toggler:focus,\n.navbar-light .navbar-toggler:hover {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-nav .nav-link {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-light .navbar-nav .nav-link:focus, .navbar-light .navbar-nav .nav-link:hover {\n color: rgba(0, 0, 0, 0.7);\n}\n\n.navbar-light .navbar-nav .nav-link.disabled {\n color: rgba(0, 0, 0, 0.3);\n}\n\n.navbar-light .navbar-nav .open > .nav-link,\n.navbar-light .navbar-nav .active > .nav-link,\n.navbar-light .navbar-nav .nav-link.open,\n.navbar-light .navbar-nav .nav-link.active {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-toggler {\n border-color: rgba(0, 0, 0, 0.1);\n}\n\n.navbar-light .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(0, 0, 0, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-light .navbar-text {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-inverse .navbar-brand,\n.navbar-inverse .navbar-toggler {\n color: white;\n}\n\n.navbar-inverse .navbar-brand:focus, .navbar-inverse .navbar-brand:hover,\n.navbar-inverse .navbar-toggler:focus,\n.navbar-inverse .navbar-toggler:hover {\n color: white;\n}\n\n.navbar-inverse .navbar-nav .nav-link {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.navbar-inverse .navbar-nav .nav-link:focus, .navbar-inverse .navbar-nav .nav-link:hover {\n color: rgba(255, 255, 255, 0.75);\n}\n\n.navbar-inverse .navbar-nav .nav-link.disabled {\n color: rgba(255, 255, 255, 0.25);\n}\n\n.navbar-inverse .navbar-nav .open > .nav-link,\n.navbar-inverse .navbar-nav .active > .nav-link,\n.navbar-inverse .navbar-nav .nav-link.open,\n.navbar-inverse .navbar-nav .nav-link.active {\n color: white;\n}\n\n.navbar-inverse .navbar-toggler {\n border-color: rgba(255, 255, 255, 0.1);\n}\n\n.navbar-inverse .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255, 255, 255, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-inverse .navbar-text {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.card {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n border-radius: 0.25rem;\n}\n\n.card-block {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 1.25rem;\n}\n\n.card-title {\n margin-bottom: 0.75rem;\n}\n\n.card-subtitle {\n margin-top: -0.375rem;\n margin-bottom: 0;\n}\n\n.card-text:last-child {\n margin-bottom: 0;\n}\n\n.card-link:hover {\n text-decoration: none;\n}\n\n.card-link + .card-link {\n margin-left: 1.25rem;\n}\n\n.card > .list-group:first-child .list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.card > .list-group:last-child .list-group-item:last-child {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.card-header {\n padding: 0.75rem 1.25rem;\n margin-bottom: 0;\n background-color: #f7f7f9;\n border-bottom: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-header:first-child {\n border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;\n}\n\n.card-footer {\n padding: 0.75rem 1.25rem;\n background-color: #f7f7f9;\n border-top: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-footer:last-child {\n border-radius: 0 0 calc(0.25rem - 1px) calc(0.25rem - 1px);\n}\n\n.card-header-tabs {\n margin-right: -0.625rem;\n margin-bottom: -0.75rem;\n margin-left: -0.625rem;\n border-bottom: 0;\n}\n\n.card-header-pills {\n margin-right: -0.625rem;\n margin-left: -0.625rem;\n}\n\n.card-primary {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.card-primary .card-header,\n.card-primary .card-footer {\n background-color: transparent;\n}\n\n.card-success {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.card-success .card-header,\n.card-success .card-footer {\n background-color: transparent;\n}\n\n.card-info {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.card-info .card-header,\n.card-info .card-footer {\n background-color: transparent;\n}\n\n.card-warning {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.card-warning .card-header,\n.card-warning .card-footer {\n background-color: transparent;\n}\n\n.card-danger {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.card-danger .card-header,\n.card-danger .card-footer {\n background-color: transparent;\n}\n\n.card-outline-primary {\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.card-outline-secondary {\n background-color: transparent;\n border-color: #ccc;\n}\n\n.card-outline-info {\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.card-outline-success {\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.card-outline-warning {\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.card-outline-danger {\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.card-inverse {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer {\n background-color: transparent;\n border-color: rgba(255, 255, 255, 0.2);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer,\n.card-inverse .card-title,\n.card-inverse .card-blockquote {\n color: #fff;\n}\n\n.card-inverse .card-link,\n.card-inverse .card-text,\n.card-inverse .card-subtitle,\n.card-inverse .card-blockquote .blockquote-footer {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-link:focus, .card-inverse .card-link:hover {\n color: #fff;\n}\n\n.card-blockquote {\n padding: 0;\n margin-bottom: 0;\n border-left: 0;\n}\n\n.card-img {\n border-radius: calc(0.25rem - 1px);\n}\n\n.card-img-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n padding: 1.25rem;\n}\n\n.card-img-top {\n border-top-right-radius: calc(0.25rem - 1px);\n border-top-left-radius: calc(0.25rem - 1px);\n}\n\n.card-img-bottom {\n border-bottom-right-radius: calc(0.25rem - 1px);\n border-bottom-left-radius: calc(0.25rem - 1px);\n}\n\n@media (min-width: 576px) {\n .card-deck {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-deck .card {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n }\n .card-deck .card:not(:first-child) {\n margin-left: 15px;\n }\n .card-deck .card:not(:last-child) {\n margin-right: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .card-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-group .card {\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n }\n .card-group .card + .card {\n margin-left: 0;\n border-left: 0;\n }\n .card-group .card:first-child {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-top {\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-bottom {\n border-bottom-right-radius: 0;\n }\n .card-group .card:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-top {\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-bottom {\n border-bottom-left-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) {\n border-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) .card-img-top,\n .card-group .card:not(:first-child):not(:last-child) .card-img-bottom {\n border-radius: 0;\n }\n}\n\n@media (min-width: 576px) {\n .card-columns {\n -webkit-column-count: 3;\n -moz-column-count: 3;\n column-count: 3;\n -webkit-column-gap: 1.25rem;\n -moz-column-gap: 1.25rem;\n column-gap: 1.25rem;\n }\n .card-columns .card {\n display: inline-block;\n width: 100%;\n margin-bottom: 0.75rem;\n }\n}\n\n.breadcrumb {\n padding: 0.75rem 1rem;\n margin-bottom: 1rem;\n list-style: none;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.breadcrumb::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.breadcrumb-item {\n float: left;\n}\n\n.breadcrumb-item + .breadcrumb-item::before {\n display: inline-block;\n padding-right: 0.5rem;\n padding-left: 0.5rem;\n color: #636c72;\n content: \"/\";\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: underline;\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: none;\n}\n\n.breadcrumb-item.active {\n color: #636c72;\n}\n\n.pagination {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n list-style: none;\n border-radius: 0.25rem;\n}\n\n.page-item:first-child .page-link {\n margin-left: 0;\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.page-item:last-child .page-link {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.page-item.active .page-link {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.page-item.disabled .page-link {\n color: #636c72;\n pointer-events: none;\n cursor: not-allowed;\n background-color: #fff;\n border-color: #ddd;\n}\n\n.page-link {\n position: relative;\n display: block;\n padding: 0.5rem 0.75rem;\n margin-left: -1px;\n line-height: 1.25;\n color: #0275d8;\n background-color: #fff;\n border: 1px solid #ddd;\n}\n\n.page-link:focus, .page-link:hover {\n color: #014c8c;\n text-decoration: none;\n background-color: #eceeef;\n border-color: #ddd;\n}\n\n.pagination-lg .page-link {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n}\n\n.pagination-lg .page-item:first-child .page-link {\n border-bottom-left-radius: 0.3rem;\n border-top-left-radius: 0.3rem;\n}\n\n.pagination-lg .page-item:last-child .page-link {\n border-bottom-right-radius: 0.3rem;\n border-top-right-radius: 0.3rem;\n}\n\n.pagination-sm .page-link {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n}\n\n.pagination-sm .page-item:first-child .page-link {\n border-bottom-left-radius: 0.2rem;\n border-top-left-radius: 0.2rem;\n}\n\n.pagination-sm .page-item:last-child .page-link {\n border-bottom-right-radius: 0.2rem;\n border-top-right-radius: 0.2rem;\n}\n\n.badge {\n display: inline-block;\n padding: 0.25em 0.4em;\n font-size: 75%;\n font-weight: bold;\n line-height: 1;\n color: #fff;\n text-align: center;\n white-space: nowrap;\n vertical-align: baseline;\n border-radius: 0.25rem;\n}\n\n.badge:empty {\n display: none;\n}\n\n.btn .badge {\n position: relative;\n top: -1px;\n}\n\na.badge:focus, a.badge:hover {\n color: #fff;\n text-decoration: none;\n cursor: pointer;\n}\n\n.badge-pill {\n padding-right: 0.6em;\n padding-left: 0.6em;\n border-radius: 10rem;\n}\n\n.badge-default {\n background-color: #636c72;\n}\n\n.badge-default[href]:focus, .badge-default[href]:hover {\n background-color: #4b5257;\n}\n\n.badge-primary {\n background-color: #0275d8;\n}\n\n.badge-primary[href]:focus, .badge-primary[href]:hover {\n background-color: #025aa5;\n}\n\n.badge-success {\n background-color: #5cb85c;\n}\n\n.badge-success[href]:focus, .badge-success[href]:hover {\n background-color: #449d44;\n}\n\n.badge-info {\n background-color: #5bc0de;\n}\n\n.badge-info[href]:focus, .badge-info[href]:hover {\n background-color: #31b0d5;\n}\n\n.badge-warning {\n background-color: #f0ad4e;\n}\n\n.badge-warning[href]:focus, .badge-warning[href]:hover {\n background-color: #ec971f;\n}\n\n.badge-danger {\n background-color: #d9534f;\n}\n\n.badge-danger[href]:focus, .badge-danger[href]:hover {\n background-color: #c9302c;\n}\n\n.jumbotron {\n padding: 2rem 1rem;\n margin-bottom: 2rem;\n background-color: #eceeef;\n border-radius: 0.3rem;\n}\n\n@media (min-width: 576px) {\n .jumbotron {\n padding: 4rem 2rem;\n }\n}\n\n.jumbotron-hr {\n border-top-color: #d0d5d8;\n}\n\n.jumbotron-fluid {\n padding-right: 0;\n padding-left: 0;\n border-radius: 0;\n}\n\n.alert {\n padding: 0.75rem 1.25rem;\n margin-bottom: 1rem;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.alert-heading {\n color: inherit;\n}\n\n.alert-link {\n font-weight: bold;\n}\n\n.alert-dismissible .close {\n position: relative;\n top: -0.75rem;\n right: -1.25rem;\n padding: 0.75rem 1.25rem;\n color: inherit;\n}\n\n.alert-success {\n background-color: #dff0d8;\n border-color: #d0e9c6;\n color: #3c763d;\n}\n\n.alert-success hr {\n border-top-color: #c1e2b3;\n}\n\n.alert-success .alert-link {\n color: #2b542c;\n}\n\n.alert-info {\n background-color: #d9edf7;\n border-color: #bcdff1;\n color: #31708f;\n}\n\n.alert-info hr {\n border-top-color: #a6d5ec;\n}\n\n.alert-info .alert-link {\n color: #245269;\n}\n\n.alert-warning {\n background-color: #fcf8e3;\n border-color: #faf2cc;\n color: #8a6d3b;\n}\n\n.alert-warning hr {\n border-top-color: #f7ecb5;\n}\n\n.alert-warning .alert-link {\n color: #66512c;\n}\n\n.alert-danger {\n background-color: #f2dede;\n border-color: #ebcccc;\n color: #a94442;\n}\n\n.alert-danger hr {\n border-top-color: #e4b9b9;\n}\n\n.alert-danger .alert-link {\n color: #843534;\n}\n\n@-webkit-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@-o-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n.progress {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n overflow: hidden;\n font-size: 0.75rem;\n line-height: 1rem;\n text-align: center;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.progress-bar {\n height: 1rem;\n color: #fff;\n background-color: #0275d8;\n}\n\n.progress-bar-striped {\n background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n -webkit-background-size: 1rem 1rem;\n background-size: 1rem 1rem;\n}\n\n.progress-bar-animated {\n -webkit-animation: progress-bar-stripes 1s linear infinite;\n -o-animation: progress-bar-stripes 1s linear infinite;\n animation: progress-bar-stripes 1s linear infinite;\n}\n\n.media {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n}\n\n.media-body {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.list-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n}\n\n.list-group-item-action {\n width: 100%;\n color: #464a4c;\n text-align: inherit;\n}\n\n.list-group-item-action .list-group-item-heading {\n color: #292b2c;\n}\n\n.list-group-item-action:focus, .list-group-item-action:hover {\n color: #464a4c;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.list-group-item-action:active {\n color: #292b2c;\n background-color: #eceeef;\n}\n\n.list-group-item {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n padding: 0.75rem 1.25rem;\n margin-bottom: -1px;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.list-group-item:last-child {\n margin-bottom: 0;\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.list-group-item:focus, .list-group-item:hover {\n text-decoration: none;\n}\n\n.list-group-item.disabled, .list-group-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #fff;\n}\n\n.list-group-item.disabled .list-group-item-heading, .list-group-item:disabled .list-group-item-heading {\n color: inherit;\n}\n\n.list-group-item.disabled .list-group-item-text, .list-group-item:disabled .list-group-item-text {\n color: #636c72;\n}\n\n.list-group-item.active {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.list-group-item.active .list-group-item-heading,\n.list-group-item.active .list-group-item-heading > small,\n.list-group-item.active .list-group-item-heading > .small {\n color: inherit;\n}\n\n.list-group-item.active .list-group-item-text {\n color: #daeeff;\n}\n\n.list-group-flush .list-group-item {\n border-right: 0;\n border-left: 0;\n border-radius: 0;\n}\n\n.list-group-flush:first-child .list-group-item:first-child {\n border-top: 0;\n}\n\n.list-group-flush:last-child .list-group-item:last-child {\n border-bottom: 0;\n}\n\n.list-group-item-success {\n color: #3c763d;\n background-color: #dff0d8;\n}\n\na.list-group-item-success,\nbutton.list-group-item-success {\n color: #3c763d;\n}\n\na.list-group-item-success .list-group-item-heading,\nbutton.list-group-item-success .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-success:focus, a.list-group-item-success:hover,\nbutton.list-group-item-success:focus,\nbutton.list-group-item-success:hover {\n color: #3c763d;\n background-color: #d0e9c6;\n}\n\na.list-group-item-success.active,\nbutton.list-group-item-success.active {\n color: #fff;\n background-color: #3c763d;\n border-color: #3c763d;\n}\n\n.list-group-item-info {\n color: #31708f;\n background-color: #d9edf7;\n}\n\na.list-group-item-info,\nbutton.list-group-item-info {\n color: #31708f;\n}\n\na.list-group-item-info .list-group-item-heading,\nbutton.list-group-item-info .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-info:focus, a.list-group-item-info:hover,\nbutton.list-group-item-info:focus,\nbutton.list-group-item-info:hover {\n color: #31708f;\n background-color: #c4e3f3;\n}\n\na.list-group-item-info.active,\nbutton.list-group-item-info.active {\n color: #fff;\n background-color: #31708f;\n border-color: #31708f;\n}\n\n.list-group-item-warning {\n color: #8a6d3b;\n background-color: #fcf8e3;\n}\n\na.list-group-item-warning,\nbutton.list-group-item-warning {\n color: #8a6d3b;\n}\n\na.list-group-item-warning .list-group-item-heading,\nbutton.list-group-item-warning .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-warning:focus, a.list-group-item-warning:hover,\nbutton.list-group-item-warning:focus,\nbutton.list-group-item-warning:hover {\n color: #8a6d3b;\n background-color: #faf2cc;\n}\n\na.list-group-item-warning.active,\nbutton.list-group-item-warning.active {\n color: #fff;\n background-color: #8a6d3b;\n border-color: #8a6d3b;\n}\n\n.list-group-item-danger {\n color: #a94442;\n background-color: #f2dede;\n}\n\na.list-group-item-danger,\nbutton.list-group-item-danger {\n color: #a94442;\n}\n\na.list-group-item-danger .list-group-item-heading,\nbutton.list-group-item-danger .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-danger:focus, a.list-group-item-danger:hover,\nbutton.list-group-item-danger:focus,\nbutton.list-group-item-danger:hover {\n color: #a94442;\n background-color: #ebcccc;\n}\n\na.list-group-item-danger.active,\nbutton.list-group-item-danger.active {\n color: #fff;\n background-color: #a94442;\n border-color: #a94442;\n}\n\n.embed-responsive {\n position: relative;\n display: block;\n width: 100%;\n padding: 0;\n overflow: hidden;\n}\n\n.embed-responsive::before {\n display: block;\n content: \"\";\n}\n\n.embed-responsive .embed-responsive-item,\n.embed-responsive iframe,\n.embed-responsive embed,\n.embed-responsive object,\n.embed-responsive video {\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 100%;\n border: 0;\n}\n\n.embed-responsive-21by9::before {\n padding-top: 42.857143%;\n}\n\n.embed-responsive-16by9::before {\n padding-top: 56.25%;\n}\n\n.embed-responsive-4by3::before {\n padding-top: 75%;\n}\n\n.embed-responsive-1by1::before {\n padding-top: 100%;\n}\n\n.close {\n float: right;\n font-size: 1.5rem;\n font-weight: bold;\n line-height: 1;\n color: #000;\n text-shadow: 0 1px 0 #fff;\n opacity: .5;\n}\n\n.close:focus, .close:hover {\n color: #000;\n text-decoration: none;\n cursor: pointer;\n opacity: .75;\n}\n\nbutton.close {\n padding: 0;\n cursor: pointer;\n background: transparent;\n border: 0;\n -webkit-appearance: none;\n}\n\n.modal-open {\n overflow: hidden;\n}\n\n.modal {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1050;\n display: none;\n overflow: hidden;\n outline: 0;\n}\n\n.modal.fade .modal-dialog {\n -webkit-transition: -webkit-transform 0.3s ease-out;\n transition: -webkit-transform 0.3s ease-out;\n -o-transition: -o-transform 0.3s ease-out;\n transition: transform 0.3s ease-out;\n transition: transform 0.3s ease-out, -webkit-transform 0.3s ease-out, -o-transform 0.3s ease-out;\n -webkit-transform: translate(0, -25%);\n -o-transform: translate(0, -25%);\n transform: translate(0, -25%);\n}\n\n.modal.show .modal-dialog {\n -webkit-transform: translate(0, 0);\n -o-transform: translate(0, 0);\n transform: translate(0, 0);\n}\n\n.modal-open .modal {\n overflow-x: hidden;\n overflow-y: auto;\n}\n\n.modal-dialog {\n position: relative;\n width: auto;\n margin: 10px;\n}\n\n.modal-content {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n outline: 0;\n}\n\n.modal-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1040;\n background-color: #000;\n}\n\n.modal-backdrop.fade {\n opacity: 0;\n}\n\n.modal-backdrop.show {\n opacity: 0.5;\n}\n\n.modal-header {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n padding: 15px;\n border-bottom: 1px solid #eceeef;\n}\n\n.modal-title {\n margin-bottom: 0;\n line-height: 1.5;\n}\n\n.modal-body {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 15px;\n}\n\n.modal-footer {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: end;\n -webkit-justify-content: flex-end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n padding: 15px;\n border-top: 1px solid #eceeef;\n}\n\n.modal-footer > :not(:first-child) {\n margin-left: .25rem;\n}\n\n.modal-footer > :not(:last-child) {\n margin-right: .25rem;\n}\n\n.modal-scrollbar-measure {\n position: absolute;\n top: -9999px;\n width: 50px;\n height: 50px;\n overflow: scroll;\n}\n\n@media (min-width: 576px) {\n .modal-dialog {\n max-width: 500px;\n margin: 30px auto;\n }\n .modal-sm {\n max-width: 300px;\n }\n}\n\n@media (min-width: 992px) {\n .modal-lg {\n max-width: 800px;\n }\n}\n\n.tooltip {\n position: absolute;\n z-index: 1070;\n display: block;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n opacity: 0;\n}\n\n.tooltip.show {\n opacity: 0.9;\n}\n\n.tooltip.tooltip-top, .tooltip.bs-tether-element-attached-bottom {\n padding: 5px 0;\n margin-top: -3px;\n}\n\n.tooltip.tooltip-top .tooltip-inner::before, .tooltip.bs-tether-element-attached-bottom .tooltip-inner::before {\n bottom: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 5px 5px 0;\n border-top-color: #000;\n}\n\n.tooltip.tooltip-right, .tooltip.bs-tether-element-attached-left {\n padding: 0 5px;\n margin-left: 3px;\n}\n\n.tooltip.tooltip-right .tooltip-inner::before, .tooltip.bs-tether-element-attached-left .tooltip-inner::before {\n top: 50%;\n left: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 5px 5px 0;\n border-right-color: #000;\n}\n\n.tooltip.tooltip-bottom, .tooltip.bs-tether-element-attached-top {\n padding: 5px 0;\n margin-top: 3px;\n}\n\n.tooltip.tooltip-bottom .tooltip-inner::before, .tooltip.bs-tether-element-attached-top .tooltip-inner::before {\n top: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 0 5px 5px;\n border-bottom-color: #000;\n}\n\n.tooltip.tooltip-left, .tooltip.bs-tether-element-attached-right {\n padding: 0 5px;\n margin-left: -3px;\n}\n\n.tooltip.tooltip-left .tooltip-inner::before, .tooltip.bs-tether-element-attached-right .tooltip-inner::before {\n top: 50%;\n right: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 0 5px 5px;\n border-left-color: #000;\n}\n\n.tooltip-inner {\n max-width: 200px;\n padding: 3px 8px;\n color: #fff;\n text-align: center;\n background-color: #000;\n border-radius: 0.25rem;\n}\n\n.tooltip-inner::before {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1060;\n display: block;\n max-width: 276px;\n padding: 1px;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n}\n\n.popover.popover-top, .popover.bs-tether-element-attached-bottom {\n margin-top: -10px;\n}\n\n.popover.popover-top::before, .popover.popover-top::after, .popover.bs-tether-element-attached-bottom::before, .popover.bs-tether-element-attached-bottom::after {\n left: 50%;\n border-bottom-width: 0;\n}\n\n.popover.popover-top::before, .popover.bs-tether-element-attached-bottom::before {\n bottom: -11px;\n margin-left: -11px;\n border-top-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-top::after, .popover.bs-tether-element-attached-bottom::after {\n bottom: -10px;\n margin-left: -10px;\n border-top-color: #fff;\n}\n\n.popover.popover-right, .popover.bs-tether-element-attached-left {\n margin-left: 10px;\n}\n\n.popover.popover-right::before, .popover.popover-right::after, .popover.bs-tether-element-attached-left::before, .popover.bs-tether-element-attached-left::after {\n top: 50%;\n border-left-width: 0;\n}\n\n.popover.popover-right::before, .popover.bs-tether-element-attached-left::before {\n left: -11px;\n margin-top: -11px;\n border-right-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-right::after, .popover.bs-tether-element-attached-left::after {\n left: -10px;\n margin-top: -10px;\n border-right-color: #fff;\n}\n\n.popover.popover-bottom, .popover.bs-tether-element-attached-top {\n margin-top: 10px;\n}\n\n.popover.popover-bottom::before, .popover.popover-bottom::after, .popover.bs-tether-element-attached-top::before, .popover.bs-tether-element-attached-top::after {\n left: 50%;\n border-top-width: 0;\n}\n\n.popover.popover-bottom::before, .popover.bs-tether-element-attached-top::before {\n top: -11px;\n margin-left: -11px;\n border-bottom-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-bottom::after, .popover.bs-tether-element-attached-top::after {\n top: -10px;\n margin-left: -10px;\n border-bottom-color: #f7f7f7;\n}\n\n.popover.popover-bottom .popover-title::before, .popover.bs-tether-element-attached-top .popover-title::before {\n position: absolute;\n top: 0;\n left: 50%;\n display: block;\n width: 20px;\n margin-left: -10px;\n content: \"\";\n border-bottom: 1px solid #f7f7f7;\n}\n\n.popover.popover-left, .popover.bs-tether-element-attached-right {\n margin-left: -10px;\n}\n\n.popover.popover-left::before, .popover.popover-left::after, .popover.bs-tether-element-attached-right::before, .popover.bs-tether-element-attached-right::after {\n top: 50%;\n border-right-width: 0;\n}\n\n.popover.popover-left::before, .popover.bs-tether-element-attached-right::before {\n right: -11px;\n margin-top: -11px;\n border-left-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-left::after, .popover.bs-tether-element-attached-right::after {\n right: -10px;\n margin-top: -10px;\n border-left-color: #fff;\n}\n\n.popover-title {\n padding: 8px 14px;\n margin-bottom: 0;\n font-size: 1rem;\n background-color: #f7f7f7;\n border-bottom: 1px solid #ebebeb;\n border-top-right-radius: calc(0.3rem - 1px);\n border-top-left-radius: calc(0.3rem - 1px);\n}\n\n.popover-title:empty {\n display: none;\n}\n\n.popover-content {\n padding: 9px 14px;\n}\n\n.popover::before,\n.popover::after {\n position: absolute;\n display: block;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover::before {\n content: \"\";\n border-width: 11px;\n}\n\n.popover::after {\n content: \"\";\n border-width: 10px;\n}\n\n.carousel {\n position: relative;\n}\n\n.carousel-inner {\n position: relative;\n width: 100%;\n overflow: hidden;\n}\n\n.carousel-item {\n position: relative;\n display: none;\n width: 100%;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n.carousel-item.active,\n.carousel-item-next,\n.carousel-item-prev {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n}\n\n.carousel-item-next,\n.carousel-item-prev {\n position: absolute;\n top: 0;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n.carousel-control-prev,\n.carousel-control-next {\n position: absolute;\n top: 0;\n bottom: 0;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: 15%;\n color: #fff;\n text-align: center;\n opacity: 0.5;\n}\n\n.carousel-control-prev:focus, .carousel-control-prev:hover,\n.carousel-control-next:focus,\n.carousel-control-next:hover {\n color: #fff;\n text-decoration: none;\n outline: 0;\n opacity: .9;\n}\n\n.carousel-control-prev {\n left: 0;\n}\n\n.carousel-control-next {\n right: 0;\n}\n\n.carousel-control-prev-icon,\n.carousel-control-next-icon {\n display: inline-block;\n width: 20px;\n height: 20px;\n background: transparent no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.carousel-control-prev-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M4 0l-4 4 4 4 1.5-1.5-2.5-2.5 2.5-2.5-1.5-1.5z'/%3E%3C/svg%3E\");\n}\n\n.carousel-control-next-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M1.5 0l-1.5 1.5 2.5 2.5-2.5 2.5 1.5 1.5 4-4-4-4z'/%3E%3C/svg%3E\");\n}\n\n.carousel-indicators {\n position: absolute;\n right: 0;\n bottom: 10px;\n left: 0;\n z-index: 15;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n margin-right: 15%;\n margin-left: 15%;\n list-style: none;\n}\n\n.carousel-indicators li {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 auto;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n max-width: 30px;\n height: 3px;\n margin-right: 3px;\n margin-left: 3px;\n text-indent: -999px;\n cursor: pointer;\n background-color: rgba(255, 255, 255, 0.5);\n}\n\n.carousel-indicators li::before {\n position: absolute;\n top: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators li::after {\n position: absolute;\n bottom: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators .active {\n background-color: #fff;\n}\n\n.carousel-caption {\n position: absolute;\n right: 15%;\n bottom: 20px;\n left: 15%;\n z-index: 10;\n padding-top: 20px;\n padding-bottom: 20px;\n color: #fff;\n text-align: center;\n}\n\n.align-baseline {\n vertical-align: baseline !important;\n}\n\n.align-top {\n vertical-align: top !important;\n}\n\n.align-middle {\n vertical-align: middle !important;\n}\n\n.align-bottom {\n vertical-align: bottom !important;\n}\n\n.align-text-bottom {\n vertical-align: text-bottom !important;\n}\n\n.align-text-top {\n vertical-align: text-top !important;\n}\n\n.bg-faded {\n background-color: #f7f7f7;\n}\n\n.bg-primary {\n background-color: #0275d8 !important;\n}\n\na.bg-primary:focus, a.bg-primary:hover {\n background-color: #025aa5 !important;\n}\n\n.bg-success {\n background-color: #5cb85c !important;\n}\n\na.bg-success:focus, a.bg-success:hover {\n background-color: #449d44 !important;\n}\n\n.bg-info {\n background-color: #5bc0de !important;\n}\n\na.bg-info:focus, a.bg-info:hover {\n background-color: #31b0d5 !important;\n}\n\n.bg-warning {\n background-color: #f0ad4e !important;\n}\n\na.bg-warning:focus, a.bg-warning:hover {\n background-color: #ec971f !important;\n}\n\n.bg-danger {\n background-color: #d9534f !important;\n}\n\na.bg-danger:focus, a.bg-danger:hover {\n background-color: #c9302c !important;\n}\n\n.bg-inverse {\n background-color: #292b2c !important;\n}\n\na.bg-inverse:focus, a.bg-inverse:hover {\n background-color: #101112 !important;\n}\n\n.border-0 {\n border: 0 !important;\n}\n\n.border-top-0 {\n border-top: 0 !important;\n}\n\n.border-right-0 {\n border-right: 0 !important;\n}\n\n.border-bottom-0 {\n border-bottom: 0 !important;\n}\n\n.border-left-0 {\n border-left: 0 !important;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.rounded-top {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-right {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.rounded-bottom {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.rounded-left {\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-circle {\n border-radius: 50%;\n}\n\n.rounded-0 {\n border-radius: 0;\n}\n\n.clearfix::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.d-none {\n display: none !important;\n}\n\n.d-inline {\n display: inline !important;\n}\n\n.d-inline-block {\n display: inline-block !important;\n}\n\n.d-block {\n display: block !important;\n}\n\n.d-table {\n display: table !important;\n}\n\n.d-table-cell {\n display: table-cell !important;\n}\n\n.d-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n}\n\n.d-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n}\n\n@media (min-width: 576px) {\n .d-sm-none {\n display: none !important;\n }\n .d-sm-inline {\n display: inline !important;\n }\n .d-sm-inline-block {\n display: inline-block !important;\n }\n .d-sm-block {\n display: block !important;\n }\n .d-sm-table {\n display: table !important;\n }\n .d-sm-table-cell {\n display: table-cell !important;\n }\n .d-sm-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-sm-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 768px) {\n .d-md-none {\n display: none !important;\n }\n .d-md-inline {\n display: inline !important;\n }\n .d-md-inline-block {\n display: inline-block !important;\n }\n .d-md-block {\n display: block !important;\n }\n .d-md-table {\n display: table !important;\n }\n .d-md-table-cell {\n display: table-cell !important;\n }\n .d-md-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-md-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 992px) {\n .d-lg-none {\n display: none !important;\n }\n .d-lg-inline {\n display: inline !important;\n }\n .d-lg-inline-block {\n display: inline-block !important;\n }\n .d-lg-block {\n display: block !important;\n }\n .d-lg-table {\n display: table !important;\n }\n .d-lg-table-cell {\n display: table-cell !important;\n }\n .d-lg-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-lg-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 1200px) {\n .d-xl-none {\n display: none !important;\n }\n .d-xl-inline {\n display: inline !important;\n }\n .d-xl-inline-block {\n display: inline-block !important;\n }\n .d-xl-block {\n display: block !important;\n }\n .d-xl-table {\n display: table !important;\n }\n .d-xl-table-cell {\n display: table-cell !important;\n }\n .d-xl-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-xl-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n.flex-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n}\n\n.flex-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n}\n\n.flex-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n}\n\n.flex-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n}\n\n.flex-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n}\n\n.flex-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n}\n\n.flex-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n}\n\n.flex-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n}\n\n.flex-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n}\n\n.flex-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n}\n\n.justify-content-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n}\n\n.justify-content-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n}\n\n.justify-content-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n}\n\n.justify-content-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n}\n\n.justify-content-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n}\n\n.align-items-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n}\n\n.align-items-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n}\n\n.align-items-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n}\n\n.align-items-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n}\n\n.align-items-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n}\n\n.align-content-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n}\n\n.align-content-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n}\n\n.align-content-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n}\n\n.align-content-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n}\n\n.align-content-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n}\n\n.align-content-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n}\n\n.align-self-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n}\n\n.align-self-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n}\n\n.align-self-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n}\n\n.align-self-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n}\n\n.align-self-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n}\n\n.align-self-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n}\n\n@media (min-width: 576px) {\n .flex-sm-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-sm-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-sm-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-sm-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-sm-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-sm-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-sm-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-sm-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-sm-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-sm-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-sm-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-sm-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-sm-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-sm-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-sm-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-sm-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-sm-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-sm-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-sm-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-sm-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-sm-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-sm-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-sm-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-sm-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-sm-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-sm-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-sm-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-sm-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-sm-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-sm-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-sm-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-sm-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 768px) {\n .flex-md-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-md-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-md-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-md-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-md-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-md-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-md-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-md-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-md-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-md-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-md-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-md-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-md-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-md-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-md-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-md-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-md-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-md-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-md-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-md-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-md-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-md-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-md-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-md-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-md-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-md-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-md-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-md-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-md-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-md-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-md-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-md-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 992px) {\n .flex-lg-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-lg-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-lg-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-lg-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-lg-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-lg-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-lg-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-lg-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-lg-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-lg-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-lg-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-lg-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-lg-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-lg-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-lg-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-lg-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-lg-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-lg-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-lg-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-lg-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-lg-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-lg-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-lg-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-lg-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-lg-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-lg-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-lg-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-lg-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-lg-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-lg-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-lg-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-lg-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 1200px) {\n .flex-xl-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-xl-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-xl-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-xl-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-xl-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-xl-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-xl-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-xl-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-xl-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-xl-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-xl-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-xl-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-xl-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-xl-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-xl-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-xl-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-xl-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-xl-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-xl-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-xl-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-xl-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-xl-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-xl-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-xl-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-xl-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-xl-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-xl-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-xl-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-xl-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-xl-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-xl-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-xl-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n.float-left {\n float: left !important;\n}\n\n.float-right {\n float: right !important;\n}\n\n.float-none {\n float: none !important;\n}\n\n@media (min-width: 576px) {\n .float-sm-left {\n float: left !important;\n }\n .float-sm-right {\n float: right !important;\n }\n .float-sm-none {\n float: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .float-md-left {\n float: left !important;\n }\n .float-md-right {\n float: right !important;\n }\n .float-md-none {\n float: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .float-lg-left {\n float: left !important;\n }\n .float-lg-right {\n float: right !important;\n }\n .float-lg-none {\n float: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .float-xl-left {\n float: left !important;\n }\n .float-xl-right {\n float: right !important;\n }\n .float-xl-none {\n float: none !important;\n }\n}\n\n.fixed-top {\n position: fixed;\n top: 0;\n right: 0;\n left: 0;\n z-index: 1030;\n}\n\n.fixed-bottom {\n position: fixed;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1030;\n}\n\n.sticky-top {\n position: -webkit-sticky;\n position: sticky;\n top: 0;\n z-index: 1030;\n}\n\n.sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n border: 0;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n position: static;\n width: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n clip: auto;\n}\n\n.w-25 {\n width: 25% !important;\n}\n\n.w-50 {\n width: 50% !important;\n}\n\n.w-75 {\n width: 75% !important;\n}\n\n.w-100 {\n width: 100% !important;\n}\n\n.h-25 {\n height: 25% !important;\n}\n\n.h-50 {\n height: 50% !important;\n}\n\n.h-75 {\n height: 75% !important;\n}\n\n.h-100 {\n height: 100% !important;\n}\n\n.mw-100 {\n max-width: 100% !important;\n}\n\n.mh-100 {\n max-height: 100% !important;\n}\n\n.m-0 {\n margin: 0 0 !important;\n}\n\n.mt-0 {\n margin-top: 0 !important;\n}\n\n.mr-0 {\n margin-right: 0 !important;\n}\n\n.mb-0 {\n margin-bottom: 0 !important;\n}\n\n.ml-0 {\n margin-left: 0 !important;\n}\n\n.mx-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n}\n\n.my-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n}\n\n.m-1 {\n margin: 0.25rem 0.25rem !important;\n}\n\n.mt-1 {\n margin-top: 0.25rem !important;\n}\n\n.mr-1 {\n margin-right: 0.25rem !important;\n}\n\n.mb-1 {\n margin-bottom: 0.25rem !important;\n}\n\n.ml-1 {\n margin-left: 0.25rem !important;\n}\n\n.mx-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n}\n\n.my-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n}\n\n.m-2 {\n margin: 0.5rem 0.5rem !important;\n}\n\n.mt-2 {\n margin-top: 0.5rem !important;\n}\n\n.mr-2 {\n margin-right: 0.5rem !important;\n}\n\n.mb-2 {\n margin-bottom: 0.5rem !important;\n}\n\n.ml-2 {\n margin-left: 0.5rem !important;\n}\n\n.mx-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n}\n\n.my-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n}\n\n.m-3 {\n margin: 1rem 1rem !important;\n}\n\n.mt-3 {\n margin-top: 1rem !important;\n}\n\n.mr-3 {\n margin-right: 1rem !important;\n}\n\n.mb-3 {\n margin-bottom: 1rem !important;\n}\n\n.ml-3 {\n margin-left: 1rem !important;\n}\n\n.mx-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n}\n\n.my-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n}\n\n.m-4 {\n margin: 1.5rem 1.5rem !important;\n}\n\n.mt-4 {\n margin-top: 1.5rem !important;\n}\n\n.mr-4 {\n margin-right: 1.5rem !important;\n}\n\n.mb-4 {\n margin-bottom: 1.5rem !important;\n}\n\n.ml-4 {\n margin-left: 1.5rem !important;\n}\n\n.mx-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n}\n\n.my-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n}\n\n.m-5 {\n margin: 3rem 3rem !important;\n}\n\n.mt-5 {\n margin-top: 3rem !important;\n}\n\n.mr-5 {\n margin-right: 3rem !important;\n}\n\n.mb-5 {\n margin-bottom: 3rem !important;\n}\n\n.ml-5 {\n margin-left: 3rem !important;\n}\n\n.mx-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n}\n\n.my-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n}\n\n.p-0 {\n padding: 0 0 !important;\n}\n\n.pt-0 {\n padding-top: 0 !important;\n}\n\n.pr-0 {\n padding-right: 0 !important;\n}\n\n.pb-0 {\n padding-bottom: 0 !important;\n}\n\n.pl-0 {\n padding-left: 0 !important;\n}\n\n.px-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n}\n\n.py-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n}\n\n.p-1 {\n padding: 0.25rem 0.25rem !important;\n}\n\n.pt-1 {\n padding-top: 0.25rem !important;\n}\n\n.pr-1 {\n padding-right: 0.25rem !important;\n}\n\n.pb-1 {\n padding-bottom: 0.25rem !important;\n}\n\n.pl-1 {\n padding-left: 0.25rem !important;\n}\n\n.px-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n}\n\n.py-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n}\n\n.p-2 {\n padding: 0.5rem 0.5rem !important;\n}\n\n.pt-2 {\n padding-top: 0.5rem !important;\n}\n\n.pr-2 {\n padding-right: 0.5rem !important;\n}\n\n.pb-2 {\n padding-bottom: 0.5rem !important;\n}\n\n.pl-2 {\n padding-left: 0.5rem !important;\n}\n\n.px-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n}\n\n.py-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n}\n\n.p-3 {\n padding: 1rem 1rem !important;\n}\n\n.pt-3 {\n padding-top: 1rem !important;\n}\n\n.pr-3 {\n padding-right: 1rem !important;\n}\n\n.pb-3 {\n padding-bottom: 1rem !important;\n}\n\n.pl-3 {\n padding-left: 1rem !important;\n}\n\n.px-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n}\n\n.py-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n}\n\n.p-4 {\n padding: 1.5rem 1.5rem !important;\n}\n\n.pt-4 {\n padding-top: 1.5rem !important;\n}\n\n.pr-4 {\n padding-right: 1.5rem !important;\n}\n\n.pb-4 {\n padding-bottom: 1.5rem !important;\n}\n\n.pl-4 {\n padding-left: 1.5rem !important;\n}\n\n.px-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n}\n\n.py-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n}\n\n.p-5 {\n padding: 3rem 3rem !important;\n}\n\n.pt-5 {\n padding-top: 3rem !important;\n}\n\n.pr-5 {\n padding-right: 3rem !important;\n}\n\n.pb-5 {\n padding-bottom: 3rem !important;\n}\n\n.pl-5 {\n padding-left: 3rem !important;\n}\n\n.px-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n}\n\n.py-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n}\n\n.m-auto {\n margin: auto !important;\n}\n\n.mt-auto {\n margin-top: auto !important;\n}\n\n.mr-auto {\n margin-right: auto !important;\n}\n\n.mb-auto {\n margin-bottom: auto !important;\n}\n\n.ml-auto {\n margin-left: auto !important;\n}\n\n.mx-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n}\n\n.my-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n}\n\n@media (min-width: 576px) {\n .m-sm-0 {\n margin: 0 0 !important;\n }\n .mt-sm-0 {\n margin-top: 0 !important;\n }\n .mr-sm-0 {\n margin-right: 0 !important;\n }\n .mb-sm-0 {\n margin-bottom: 0 !important;\n }\n .ml-sm-0 {\n margin-left: 0 !important;\n }\n .mx-sm-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-sm-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-sm-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-sm-1 {\n margin-top: 0.25rem !important;\n }\n .mr-sm-1 {\n margin-right: 0.25rem !important;\n }\n .mb-sm-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-sm-1 {\n margin-left: 0.25rem !important;\n }\n .mx-sm-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-sm-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-sm-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-sm-2 {\n margin-top: 0.5rem !important;\n }\n .mr-sm-2 {\n margin-right: 0.5rem !important;\n }\n .mb-sm-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-sm-2 {\n margin-left: 0.5rem !important;\n }\n .mx-sm-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-sm-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-sm-3 {\n margin: 1rem 1rem !important;\n }\n .mt-sm-3 {\n margin-top: 1rem !important;\n }\n .mr-sm-3 {\n margin-right: 1rem !important;\n }\n .mb-sm-3 {\n margin-bottom: 1rem !important;\n }\n .ml-sm-3 {\n margin-left: 1rem !important;\n }\n .mx-sm-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-sm-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-sm-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-sm-4 {\n margin-top: 1.5rem !important;\n }\n .mr-sm-4 {\n margin-right: 1.5rem !important;\n }\n .mb-sm-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-sm-4 {\n margin-left: 1.5rem !important;\n }\n .mx-sm-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-sm-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-sm-5 {\n margin: 3rem 3rem !important;\n }\n .mt-sm-5 {\n margin-top: 3rem !important;\n }\n .mr-sm-5 {\n margin-right: 3rem !important;\n }\n .mb-sm-5 {\n margin-bottom: 3rem !important;\n }\n .ml-sm-5 {\n margin-left: 3rem !important;\n }\n .mx-sm-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-sm-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-sm-0 {\n padding: 0 0 !important;\n }\n .pt-sm-0 {\n padding-top: 0 !important;\n }\n .pr-sm-0 {\n padding-right: 0 !important;\n }\n .pb-sm-0 {\n padding-bottom: 0 !important;\n }\n .pl-sm-0 {\n padding-left: 0 !important;\n }\n .px-sm-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-sm-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-sm-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-sm-1 {\n padding-top: 0.25rem !important;\n }\n .pr-sm-1 {\n padding-right: 0.25rem !important;\n }\n .pb-sm-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-sm-1 {\n padding-left: 0.25rem !important;\n }\n .px-sm-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-sm-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-sm-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-sm-2 {\n padding-top: 0.5rem !important;\n }\n .pr-sm-2 {\n padding-right: 0.5rem !important;\n }\n .pb-sm-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-sm-2 {\n padding-left: 0.5rem !important;\n }\n .px-sm-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-sm-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-sm-3 {\n padding: 1rem 1rem !important;\n }\n .pt-sm-3 {\n padding-top: 1rem !important;\n }\n .pr-sm-3 {\n padding-right: 1rem !important;\n }\n .pb-sm-3 {\n padding-bottom: 1rem !important;\n }\n .pl-sm-3 {\n padding-left: 1rem !important;\n }\n .px-sm-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-sm-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-sm-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-sm-4 {\n padding-top: 1.5rem !important;\n }\n .pr-sm-4 {\n padding-right: 1.5rem !important;\n }\n .pb-sm-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-sm-4 {\n padding-left: 1.5rem !important;\n }\n .px-sm-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-sm-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-sm-5 {\n padding: 3rem 3rem !important;\n }\n .pt-sm-5 {\n padding-top: 3rem !important;\n }\n .pr-sm-5 {\n padding-right: 3rem !important;\n }\n .pb-sm-5 {\n padding-bottom: 3rem !important;\n }\n .pl-sm-5 {\n padding-left: 3rem !important;\n }\n .px-sm-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-sm-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-sm-auto {\n margin: auto !important;\n }\n .mt-sm-auto {\n margin-top: auto !important;\n }\n .mr-sm-auto {\n margin-right: auto !important;\n }\n .mb-sm-auto {\n margin-bottom: auto !important;\n }\n .ml-sm-auto {\n margin-left: auto !important;\n }\n .mx-sm-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-sm-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 768px) {\n .m-md-0 {\n margin: 0 0 !important;\n }\n .mt-md-0 {\n margin-top: 0 !important;\n }\n .mr-md-0 {\n margin-right: 0 !important;\n }\n .mb-md-0 {\n margin-bottom: 0 !important;\n }\n .ml-md-0 {\n margin-left: 0 !important;\n }\n .mx-md-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-md-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-md-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-md-1 {\n margin-top: 0.25rem !important;\n }\n .mr-md-1 {\n margin-right: 0.25rem !important;\n }\n .mb-md-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-md-1 {\n margin-left: 0.25rem !important;\n }\n .mx-md-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-md-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-md-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-md-2 {\n margin-top: 0.5rem !important;\n }\n .mr-md-2 {\n margin-right: 0.5rem !important;\n }\n .mb-md-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-md-2 {\n margin-left: 0.5rem !important;\n }\n .mx-md-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-md-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-md-3 {\n margin: 1rem 1rem !important;\n }\n .mt-md-3 {\n margin-top: 1rem !important;\n }\n .mr-md-3 {\n margin-right: 1rem !important;\n }\n .mb-md-3 {\n margin-bottom: 1rem !important;\n }\n .ml-md-3 {\n margin-left: 1rem !important;\n }\n .mx-md-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-md-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-md-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-md-4 {\n margin-top: 1.5rem !important;\n }\n .mr-md-4 {\n margin-right: 1.5rem !important;\n }\n .mb-md-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-md-4 {\n margin-left: 1.5rem !important;\n }\n .mx-md-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-md-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-md-5 {\n margin: 3rem 3rem !important;\n }\n .mt-md-5 {\n margin-top: 3rem !important;\n }\n .mr-md-5 {\n margin-right: 3rem !important;\n }\n .mb-md-5 {\n margin-bottom: 3rem !important;\n }\n .ml-md-5 {\n margin-left: 3rem !important;\n }\n .mx-md-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-md-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-md-0 {\n padding: 0 0 !important;\n }\n .pt-md-0 {\n padding-top: 0 !important;\n }\n .pr-md-0 {\n padding-right: 0 !important;\n }\n .pb-md-0 {\n padding-bottom: 0 !important;\n }\n .pl-md-0 {\n padding-left: 0 !important;\n }\n .px-md-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-md-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-md-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-md-1 {\n padding-top: 0.25rem !important;\n }\n .pr-md-1 {\n padding-right: 0.25rem !important;\n }\n .pb-md-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-md-1 {\n padding-left: 0.25rem !important;\n }\n .px-md-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-md-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-md-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-md-2 {\n padding-top: 0.5rem !important;\n }\n .pr-md-2 {\n padding-right: 0.5rem !important;\n }\n .pb-md-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-md-2 {\n padding-left: 0.5rem !important;\n }\n .px-md-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-md-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-md-3 {\n padding: 1rem 1rem !important;\n }\n .pt-md-3 {\n padding-top: 1rem !important;\n }\n .pr-md-3 {\n padding-right: 1rem !important;\n }\n .pb-md-3 {\n padding-bottom: 1rem !important;\n }\n .pl-md-3 {\n padding-left: 1rem !important;\n }\n .px-md-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-md-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-md-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-md-4 {\n padding-top: 1.5rem !important;\n }\n .pr-md-4 {\n padding-right: 1.5rem !important;\n }\n .pb-md-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-md-4 {\n padding-left: 1.5rem !important;\n }\n .px-md-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-md-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-md-5 {\n padding: 3rem 3rem !important;\n }\n .pt-md-5 {\n padding-top: 3rem !important;\n }\n .pr-md-5 {\n padding-right: 3rem !important;\n }\n .pb-md-5 {\n padding-bottom: 3rem !important;\n }\n .pl-md-5 {\n padding-left: 3rem !important;\n }\n .px-md-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-md-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-md-auto {\n margin: auto !important;\n }\n .mt-md-auto {\n margin-top: auto !important;\n }\n .mr-md-auto {\n margin-right: auto !important;\n }\n .mb-md-auto {\n margin-bottom: auto !important;\n }\n .ml-md-auto {\n margin-left: auto !important;\n }\n .mx-md-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-md-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 992px) {\n .m-lg-0 {\n margin: 0 0 !important;\n }\n .mt-lg-0 {\n margin-top: 0 !important;\n }\n .mr-lg-0 {\n margin-right: 0 !important;\n }\n .mb-lg-0 {\n margin-bottom: 0 !important;\n }\n .ml-lg-0 {\n margin-left: 0 !important;\n }\n .mx-lg-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-lg-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-lg-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-lg-1 {\n margin-top: 0.25rem !important;\n }\n .mr-lg-1 {\n margin-right: 0.25rem !important;\n }\n .mb-lg-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-lg-1 {\n margin-left: 0.25rem !important;\n }\n .mx-lg-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-lg-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-lg-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-lg-2 {\n margin-top: 0.5rem !important;\n }\n .mr-lg-2 {\n margin-right: 0.5rem !important;\n }\n .mb-lg-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-lg-2 {\n margin-left: 0.5rem !important;\n }\n .mx-lg-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-lg-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-lg-3 {\n margin: 1rem 1rem !important;\n }\n .mt-lg-3 {\n margin-top: 1rem !important;\n }\n .mr-lg-3 {\n margin-right: 1rem !important;\n }\n .mb-lg-3 {\n margin-bottom: 1rem !important;\n }\n .ml-lg-3 {\n margin-left: 1rem !important;\n }\n .mx-lg-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-lg-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-lg-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-lg-4 {\n margin-top: 1.5rem !important;\n }\n .mr-lg-4 {\n margin-right: 1.5rem !important;\n }\n .mb-lg-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-lg-4 {\n margin-left: 1.5rem !important;\n }\n .mx-lg-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-lg-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-lg-5 {\n margin: 3rem 3rem !important;\n }\n .mt-lg-5 {\n margin-top: 3rem !important;\n }\n .mr-lg-5 {\n margin-right: 3rem !important;\n }\n .mb-lg-5 {\n margin-bottom: 3rem !important;\n }\n .ml-lg-5 {\n margin-left: 3rem !important;\n }\n .mx-lg-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-lg-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-lg-0 {\n padding: 0 0 !important;\n }\n .pt-lg-0 {\n padding-top: 0 !important;\n }\n .pr-lg-0 {\n padding-right: 0 !important;\n }\n .pb-lg-0 {\n padding-bottom: 0 !important;\n }\n .pl-lg-0 {\n padding-left: 0 !important;\n }\n .px-lg-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-lg-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-lg-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-lg-1 {\n padding-top: 0.25rem !important;\n }\n .pr-lg-1 {\n padding-right: 0.25rem !important;\n }\n .pb-lg-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-lg-1 {\n padding-left: 0.25rem !important;\n }\n .px-lg-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-lg-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-lg-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-lg-2 {\n padding-top: 0.5rem !important;\n }\n .pr-lg-2 {\n padding-right: 0.5rem !important;\n }\n .pb-lg-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-lg-2 {\n padding-left: 0.5rem !important;\n }\n .px-lg-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-lg-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-lg-3 {\n padding: 1rem 1rem !important;\n }\n .pt-lg-3 {\n padding-top: 1rem !important;\n }\n .pr-lg-3 {\n padding-right: 1rem !important;\n }\n .pb-lg-3 {\n padding-bottom: 1rem !important;\n }\n .pl-lg-3 {\n padding-left: 1rem !important;\n }\n .px-lg-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-lg-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-lg-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-lg-4 {\n padding-top: 1.5rem !important;\n }\n .pr-lg-4 {\n padding-right: 1.5rem !important;\n }\n .pb-lg-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-lg-4 {\n padding-left: 1.5rem !important;\n }\n .px-lg-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-lg-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-lg-5 {\n padding: 3rem 3rem !important;\n }\n .pt-lg-5 {\n padding-top: 3rem !important;\n }\n .pr-lg-5 {\n padding-right: 3rem !important;\n }\n .pb-lg-5 {\n padding-bottom: 3rem !important;\n }\n .pl-lg-5 {\n padding-left: 3rem !important;\n }\n .px-lg-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-lg-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-lg-auto {\n margin: auto !important;\n }\n .mt-lg-auto {\n margin-top: auto !important;\n }\n .mr-lg-auto {\n margin-right: auto !important;\n }\n .mb-lg-auto {\n margin-bottom: auto !important;\n }\n .ml-lg-auto {\n margin-left: auto !important;\n }\n .mx-lg-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-lg-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 1200px) {\n .m-xl-0 {\n margin: 0 0 !important;\n }\n .mt-xl-0 {\n margin-top: 0 !important;\n }\n .mr-xl-0 {\n margin-right: 0 !important;\n }\n .mb-xl-0 {\n margin-bottom: 0 !important;\n }\n .ml-xl-0 {\n margin-left: 0 !important;\n }\n .mx-xl-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-xl-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-xl-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-xl-1 {\n margin-top: 0.25rem !important;\n }\n .mr-xl-1 {\n margin-right: 0.25rem !important;\n }\n .mb-xl-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-xl-1 {\n margin-left: 0.25rem !important;\n }\n .mx-xl-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-xl-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-xl-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-xl-2 {\n margin-top: 0.5rem !important;\n }\n .mr-xl-2 {\n margin-right: 0.5rem !important;\n }\n .mb-xl-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-xl-2 {\n margin-left: 0.5rem !important;\n }\n .mx-xl-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-xl-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-xl-3 {\n margin: 1rem 1rem !important;\n }\n .mt-xl-3 {\n margin-top: 1rem !important;\n }\n .mr-xl-3 {\n margin-right: 1rem !important;\n }\n .mb-xl-3 {\n margin-bottom: 1rem !important;\n }\n .ml-xl-3 {\n margin-left: 1rem !important;\n }\n .mx-xl-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-xl-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-xl-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-xl-4 {\n margin-top: 1.5rem !important;\n }\n .mr-xl-4 {\n margin-right: 1.5rem !important;\n }\n .mb-xl-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-xl-4 {\n margin-left: 1.5rem !important;\n }\n .mx-xl-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-xl-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-xl-5 {\n margin: 3rem 3rem !important;\n }\n .mt-xl-5 {\n margin-top: 3rem !important;\n }\n .mr-xl-5 {\n margin-right: 3rem !important;\n }\n .mb-xl-5 {\n margin-bottom: 3rem !important;\n }\n .ml-xl-5 {\n margin-left: 3rem !important;\n }\n .mx-xl-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-xl-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-xl-0 {\n padding: 0 0 !important;\n }\n .pt-xl-0 {\n padding-top: 0 !important;\n }\n .pr-xl-0 {\n padding-right: 0 !important;\n }\n .pb-xl-0 {\n padding-bottom: 0 !important;\n }\n .pl-xl-0 {\n padding-left: 0 !important;\n }\n .px-xl-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-xl-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-xl-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-xl-1 {\n padding-top: 0.25rem !important;\n }\n .pr-xl-1 {\n padding-right: 0.25rem !important;\n }\n .pb-xl-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-xl-1 {\n padding-left: 0.25rem !important;\n }\n .px-xl-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-xl-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-xl-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-xl-2 {\n padding-top: 0.5rem !important;\n }\n .pr-xl-2 {\n padding-right: 0.5rem !important;\n }\n .pb-xl-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-xl-2 {\n padding-left: 0.5rem !important;\n }\n .px-xl-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-xl-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-xl-3 {\n padding: 1rem 1rem !important;\n }\n .pt-xl-3 {\n padding-top: 1rem !important;\n }\n .pr-xl-3 {\n padding-right: 1rem !important;\n }\n .pb-xl-3 {\n padding-bottom: 1rem !important;\n }\n .pl-xl-3 {\n padding-left: 1rem !important;\n }\n .px-xl-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-xl-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-xl-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-xl-4 {\n padding-top: 1.5rem !important;\n }\n .pr-xl-4 {\n padding-right: 1.5rem !important;\n }\n .pb-xl-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-xl-4 {\n padding-left: 1.5rem !important;\n }\n .px-xl-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-xl-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-xl-5 {\n padding: 3rem 3rem !important;\n }\n .pt-xl-5 {\n padding-top: 3rem !important;\n }\n .pr-xl-5 {\n padding-right: 3rem !important;\n }\n .pb-xl-5 {\n padding-bottom: 3rem !important;\n }\n .pl-xl-5 {\n padding-left: 3rem !important;\n }\n .px-xl-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-xl-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-xl-auto {\n margin: auto !important;\n }\n .mt-xl-auto {\n margin-top: auto !important;\n }\n .mr-xl-auto {\n margin-right: auto !important;\n }\n .mb-xl-auto {\n margin-bottom: auto !important;\n }\n .ml-xl-auto {\n margin-left: auto !important;\n }\n .mx-xl-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-xl-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n.text-justify {\n text-align: justify !important;\n}\n\n.text-nowrap {\n white-space: nowrap !important;\n}\n\n.text-truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.text-left {\n text-align: left !important;\n}\n\n.text-right {\n text-align: right !important;\n}\n\n.text-center {\n text-align: center !important;\n}\n\n@media (min-width: 576px) {\n .text-sm-left {\n text-align: left !important;\n }\n .text-sm-right {\n text-align: right !important;\n }\n .text-sm-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 768px) {\n .text-md-left {\n text-align: left !important;\n }\n .text-md-right {\n text-align: right !important;\n }\n .text-md-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 992px) {\n .text-lg-left {\n text-align: left !important;\n }\n .text-lg-right {\n text-align: right !important;\n }\n .text-lg-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 1200px) {\n .text-xl-left {\n text-align: left !important;\n }\n .text-xl-right {\n text-align: right !important;\n }\n .text-xl-center {\n text-align: center !important;\n }\n}\n\n.text-lowercase {\n text-transform: lowercase !important;\n}\n\n.text-uppercase {\n text-transform: uppercase !important;\n}\n\n.text-capitalize {\n text-transform: capitalize !important;\n}\n\n.font-weight-normal {\n font-weight: normal;\n}\n\n.font-weight-bold {\n font-weight: bold;\n}\n\n.font-italic {\n font-style: italic;\n}\n\n.text-white {\n color: #fff !important;\n}\n\n.text-muted {\n color: #636c72 !important;\n}\n\na.text-muted:focus, a.text-muted:hover {\n color: #4b5257 !important;\n}\n\n.text-primary {\n color: #0275d8 !important;\n}\n\na.text-primary:focus, a.text-primary:hover {\n color: #025aa5 !important;\n}\n\n.text-success {\n color: #5cb85c !important;\n}\n\na.text-success:focus, a.text-success:hover {\n color: #449d44 !important;\n}\n\n.text-info {\n color: #5bc0de !important;\n}\n\na.text-info:focus, a.text-info:hover {\n color: #31b0d5 !important;\n}\n\n.text-warning {\n color: #f0ad4e !important;\n}\n\na.text-warning:focus, a.text-warning:hover {\n color: #ec971f !important;\n}\n\n.text-danger {\n color: #d9534f !important;\n}\n\na.text-danger:focus, a.text-danger:hover {\n color: #c9302c !important;\n}\n\n.text-gray-dark {\n color: #292b2c !important;\n}\n\na.text-gray-dark:focus, a.text-gray-dark:hover {\n color: #101112 !important;\n}\n\n.text-hide {\n font: 0/0 a;\n color: transparent;\n text-shadow: none;\n background-color: transparent;\n border: 0;\n}\n\n.invisible {\n visibility: hidden !important;\n}\n\n.hidden-xs-up {\n display: none !important;\n}\n\n@media (max-width: 575px) {\n .hidden-xs-down {\n display: none !important;\n }\n}\n\n@media (min-width: 576px) {\n .hidden-sm-up {\n display: none !important;\n }\n}\n\n@media (max-width: 767px) {\n .hidden-sm-down {\n display: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .hidden-md-up {\n display: none !important;\n }\n}\n\n@media (max-width: 991px) {\n .hidden-md-down {\n display: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .hidden-lg-up {\n display: none !important;\n }\n}\n\n@media (max-width: 1199px) {\n .hidden-lg-down {\n display: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .hidden-xl-up {\n display: none !important;\n }\n}\n\n.hidden-xl-down {\n display: none !important;\n}\n\n.visible-print-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-block {\n display: block !important;\n }\n}\n\n.visible-print-inline {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline {\n display: inline !important;\n }\n}\n\n.visible-print-inline-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline-block {\n display: inline-block !important;\n }\n}\n\n@media print {\n .hidden-print {\n display: none !important;\n }\n}", ""]); + +// exports + + +/***/ }), +/* 213 */ +/***/ (function(module, exports) { + + +/** + * When source maps are enabled, `style-loader` uses a link element with a data-uri to + * embed the css on the page. This breaks all relative urls because now they are relative to a + * bundle instead of the current page. + * + * One solution is to only use full urls, but that may be impossible. + * + * Instead, this function "fixes" the relative urls to be absolute according to the current page location. + * + * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command. + * + */ + +module.exports = function (css) { + // get current location + var location = typeof window !== "undefined" && window.location; + + if (!location) { + throw new Error("fixUrls requires window.location"); + } + + // blank or null? + if (!css || typeof css !== "string") { + return css; + } + + var baseUrl = location.protocol + "//" + location.host; + var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/"); + + // convert each url(...) + /* + This regular expression is just a way to recursively match brackets within + a string. + + /url\s*\( = Match on the word "url" with any whitespace after it and then a parens + ( = Start a capturing group + (?: = Start a non-capturing group + [^)(] = Match anything that isn't a parentheses + | = OR + \( = Match a start parentheses + (?: = Start another non-capturing groups + [^)(]+ = Match anything that isn't a parentheses + | = OR + \( = Match a start parentheses + [^)(]* = Match anything that isn't a parentheses + \) = Match a end parentheses + ) = End Group + *\) = Match anything and then a close parens + ) = Close non-capturing group + * = Match anything + ) = Close capturing group + \) = Match a close parens + + /gi = Get all matches, not the first. Be case insensitive. + */ + var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) { + // strip quotes (if they exist) + var unquotedOrigUrl = origUrl + .trim() + .replace(/^"(.*)"$/, function(o, $1){ return $1; }) + .replace(/^'(.*)'$/, function(o, $1){ return $1; }); + + // already a full url? no change + if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(unquotedOrigUrl)) { + return fullMatch; + } + + // convert the url to a full url + var newUrl; + + if (unquotedOrigUrl.indexOf("//") === 0) { + //TODO: should we add protocol? + newUrl = unquotedOrigUrl; + } else if (unquotedOrigUrl.indexOf("/") === 0) { + // path should be relative to the base url + newUrl = baseUrl + unquotedOrigUrl; // already starts with '/' + } else { + // path should be relative to current directory + newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './' + } + + // send back the fixed url(...) + return "url(" + JSON.stringify(newUrl) + ")"; + }); + + // send back the fixed css + return fixedCss; +}; + + +/***/ }), +/* 214 */ +/***/ (function(module, exports, __webpack_require__) { + +// style-loader: Adds some css to the DOM by adding a <style> tag + +// load the styles +var content = __webpack_require__(215); +if(typeof content === 'string') content = [[module.i, content, '']]; +// Prepare cssTransformation +var transform; + +var options = {} +options.transform = transform +// add the styles to the DOM +var update = __webpack_require__(118)(content, options); +if(content.locals) module.exports = content.locals; +// Hot Module Replacement +if(false) { + // When the styles change, update the <style> tags + if(!content.locals) { + module.hot.accept("!!../css-loader/index.js!./react-table.css", function() { + var newContent = require("!!../css-loader/index.js!./react-table.css"); + if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; + update(newContent); + }); + } + // When the module is disposed, remove the <style> tags + module.hot.dispose(function() { update(); }); +} + +/***/ }), +/* 215 */ +/***/ (function(module, exports, __webpack_require__) { + +exports = module.exports = __webpack_require__(117)(undefined); +// imports + + +// module +exports.push([module.i, ".ReactTable{position:relative;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;border:1px solid rgba(0,0,0,0.1);}.ReactTable *{box-sizing:border-box}.ReactTable .rt-table{-webkit-box-flex:1;-ms-flex:1;flex:1;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;width:100%;border-collapse:collapse;overflow:auto}.ReactTable .rt-thead{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;}.ReactTable .rt-thead.-headerGroups{background:rgba(0,0,0,0.03);border-bottom:1px solid rgba(0,0,0,0.05)}.ReactTable .rt-thead.-filters{border-bottom:1px solid rgba(0,0,0,0.05);}.ReactTable .rt-thead.-filters .rt-th{border-right:1px solid rgba(0,0,0,0.02)}.ReactTable .rt-thead.-header{box-shadow:0 2px 15px 0 rgba(0,0,0,0.15)}.ReactTable .rt-thead .rt-tr{text-align:center}.ReactTable .rt-thead .rt-th,.ReactTable .rt-thead .rt-td{padding:5px 5px;line-height:normal;position:relative;border-right:1px solid rgba(0,0,0,0.05);-webkit-transition:box-shadow .3s cubic-bezier(.175,.885,.32,1.275);transition:box-shadow .3s cubic-bezier(.175,.885,.32,1.275);box-shadow:inset 0 0 0 0 transparent;}.ReactTable .rt-thead .rt-th.-sort-asc,.ReactTable .rt-thead .rt-td.-sort-asc{box-shadow:inset 0 3px 0 0 rgba(0,0,0,0.6)}.ReactTable .rt-thead .rt-th.-sort-desc,.ReactTable .rt-thead .rt-td.-sort-desc{box-shadow:inset 0 -3px 0 0 rgba(0,0,0,0.6)}.ReactTable .rt-thead .rt-th.-cursor-pointer,.ReactTable .rt-thead .rt-td.-cursor-pointer{cursor:pointer}.ReactTable .rt-thead .rt-th:last-child,.ReactTable .rt-thead .rt-td:last-child{border-right:0}.ReactTable .rt-thead .rt-resizable-header{overflow:visible;}.ReactTable .rt-thead .rt-resizable-header:last-child{overflow:hidden}.ReactTable .rt-thead .rt-resizable-header-content{overflow:hidden;text-overflow:ellipsis}.ReactTable .rt-thead .rt-header-pivot{border-right-color:#f7f7f7}.ReactTable .rt-thead .rt-header-pivot:after,.ReactTable .rt-thead .rt-header-pivot:before{left:100%;top:50%;border:solid transparent;content:\" \";height:0;width:0;position:absolute;pointer-events:none}.ReactTable .rt-thead .rt-header-pivot:after{border-color:rgba(255,255,255,0);border-left-color:#fff;border-width:8px;margin-top:-8px}.ReactTable .rt-thead .rt-header-pivot:before{border-color:rgba(102,102,102,0);border-left-color:#f7f7f7;border-width:10px;margin-top:-10px}.ReactTable .rt-tbody{-webkit-box-flex:99999;-ms-flex:99999 1 auto;flex:99999 1 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;overflow:auto;}.ReactTable .rt-tbody .rt-tr-group{border-bottom:solid 1px rgba(0,0,0,0.05);}.ReactTable .rt-tbody .rt-tr-group:last-child{border-bottom:0}.ReactTable .rt-tbody .rt-td{border-right:1px solid rgba(0,0,0,0.02);}.ReactTable .rt-tbody .rt-td:last-child{border-right:0}.ReactTable .rt-tbody .rt-expandable{cursor:pointer}.ReactTable .rt-tr-group{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch}.ReactTable .rt-tr{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.ReactTable .rt-th,.ReactTable .rt-td{-webkit-box-flex:1;-ms-flex:1 0 0px;flex:1 0 0;white-space:nowrap;text-overflow:ellipsis;padding:7px 5px;overflow:hidden;-webkit-transition:.3s ease;transition:.3s ease;-webkit-transition-property:width,min-width,padding,opacity;transition-property:width,min-width,padding,opacity;}.ReactTable .rt-th.-hidden,.ReactTable .rt-td.-hidden{width:0 !important;min-width:0 !important;padding:0 !important;border:0 !important;opacity:0 !important}.ReactTable .rt-expander{display:inline-block;position:relative;margin:0;color:transparent;margin:0 10px;}.ReactTable .rt-expander:after{content:'';position:absolute;width:0;height:0;top:50%;left:50%;-webkit-transform:translate(-50%,-50%) rotate(-90deg);transform:translate(-50%,-50%) rotate(-90deg);border-left:5.04px solid transparent;border-right:5.04px solid transparent;border-top:7px solid rgba(0,0,0,0.8);-webkit-transition:all .3s cubic-bezier(.175,.885,.32,1.275);transition:all .3s cubic-bezier(.175,.885,.32,1.275);cursor:pointer}.ReactTable .rt-expander.-open:after{-webkit-transform:translate(-50%,-50%) rotate(0);transform:translate(-50%,-50%) rotate(0)}.ReactTable .rt-resizer{display:inline-block;position:absolute;width:36px;top:0;bottom:0;right:-18px;cursor:col-resize;z-index:10}.ReactTable .rt-tfoot{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;box-shadow:0 0 15px 0 rgba(0,0,0,0.15);}.ReactTable .rt-tfoot .rt-td{border-right:1px solid rgba(0,0,0,0.05);}.ReactTable .rt-tfoot .rt-td:last-child{border-right:0}.ReactTable.-striped .rt-tr.-odd{background:rgba(0,0,0,0.03)}.ReactTable.-highlight .rt-tbody .rt-tr:not(.-padRow):hover{background:rgba(0,0,0,0.05)}.ReactTable .-pagination{z-index:1;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;-ms-flex-wrap:wrap;flex-wrap:wrap;padding:3px;box-shadow:0 0 15px 0 rgba(0,0,0,0.1);border-top:2px solid rgba(0,0,0,0.1);}.ReactTable .-pagination .-btn{-webkit-appearance:none;-moz-appearance:none;appearance:none;display:block;width:100%;height:100%;border:0;border-radius:3px;padding:6px;font-size:1em;color:rgba(0,0,0,0.6);background:rgba(0,0,0,0.1);-webkit-transition:all .1s ease;transition:all .1s ease;cursor:pointer;outline:none;}.ReactTable .-pagination .-btn[disabled]{opacity:.5;cursor:default}.ReactTable .-pagination .-btn:not([disabled]):hover{background:rgba(0,0,0,0.3);color:#fff}.ReactTable .-pagination .-previous,.ReactTable .-pagination .-next{-webkit-box-flex:1;-ms-flex:1;flex:1;text-align:center}.ReactTable .-pagination .-center{-webkit-box-flex:1.5;-ms-flex:1.5;flex:1.5;text-align:center;margin-bottom:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-ms-flex-pack:distribute;justify-content:space-around}.ReactTable .-pagination .-pageInfo{display:inline-block;margin:3px 10px;white-space:nowrap}.ReactTable .-pagination .-pageJump{display:inline-block;}.ReactTable .-pagination .-pageJump input{width:70px;text-align:center}.ReactTable .-pagination .-pageSizeOptions{margin:3px 10px}.ReactTable .rt-noData{display:block;position:absolute;left:50%;top:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);background:rgba(255,255,255,0.8);-webkit-transition:all .3s ease;transition:all .3s ease;z-index:1;pointer-events:none;padding:20px;color:rgba(0,0,0,0.5)}.ReactTable .-loading{display:block;position:absolute;left:0;right:0;top:0;bottom:0;background:rgba(255,255,255,0.8);-webkit-transition:all .3s ease;transition:all .3s ease;z-index:-1;opacity:0;pointer-events:none;}.ReactTable .-loading > div{position:absolute;display:block;text-align:center;width:100%;top:50%;left:0;font-size:15px;color:rgba(0,0,0,0.6);-webkit-transform:translateY(-52%);transform:translateY(-52%);-webkit-transition:all .3s cubic-bezier(.25,.46,.45,.94);transition:all .3s cubic-bezier(.25,.46,.45,.94)}.ReactTable .-loading.-active{opacity:1;z-index:2;pointer-events:all;}.ReactTable .-loading.-active > div{-webkit-transform:translateY(50%);transform:translateY(50%)}.ReactTable input,.ReactTable select{border:1px solid rgba(0,0,0,0.1);background:#fff;padding:5px 7px;font-size:inherit;border-radius:3px;font-weight:normal;outline:none}.ReactTable .rt-resizing .rt-th,.ReactTable .rt-resizing .rt-td{-webkit-transition:none !important;transition:none !important;cursor:col-resize;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}", ""]); + +// exports + + +/***/ }), +/* 216 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var PooledClass = __webpack_require__(217); +var ReactElement = __webpack_require__(31); + +var emptyFunction = __webpack_require__(18); +var traverseAllChildren = __webpack_require__(218); + +var twoArgumentPooler = PooledClass.twoArgumentPooler; +var fourArgumentPooler = PooledClass.fourArgumentPooler; + +var userProvidedKeyEscapeRegex = /\/+/g; +function escapeUserProvidedKey(text) { + return ('' + text).replace(userProvidedKeyEscapeRegex, '$&/'); +} + +/** + * PooledClass representing the bookkeeping associated with performing a child + * traversal. Allows avoiding binding callbacks. + * + * @constructor ForEachBookKeeping + * @param {!function} forEachFunction Function to perform traversal with. + * @param {?*} forEachContext Context to perform context with. + */ +function ForEachBookKeeping(forEachFunction, forEachContext) { + this.func = forEachFunction; + this.context = forEachContext; + this.count = 0; +} +ForEachBookKeeping.prototype.destructor = function () { + this.func = null; + this.context = null; + this.count = 0; +}; +PooledClass.addPoolingTo(ForEachBookKeeping, twoArgumentPooler); + +function forEachSingleChild(bookKeeping, child, name) { + var func = bookKeeping.func, + context = bookKeeping.context; + + func.call(context, child, bookKeeping.count++); +} + +/** + * Iterates through children that are typically specified as `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.foreach + * + * The provided forEachFunc(child, index) will be called for each + * leaf child. + * + * @param {?*} children Children tree container. + * @param {function(*, int)} forEachFunc + * @param {*} forEachContext Context for forEachContext. + */ +function forEachChildren(children, forEachFunc, forEachContext) { + if (children == null) { + return children; + } + var traverseContext = ForEachBookKeeping.getPooled(forEachFunc, forEachContext); + traverseAllChildren(children, forEachSingleChild, traverseContext); + ForEachBookKeeping.release(traverseContext); +} + +/** + * PooledClass representing the bookkeeping associated with performing a child + * mapping. Allows avoiding binding callbacks. + * + * @constructor MapBookKeeping + * @param {!*} mapResult Object containing the ordered map of results. + * @param {!function} mapFunction Function to perform mapping with. + * @param {?*} mapContext Context to perform mapping with. + */ +function MapBookKeeping(mapResult, keyPrefix, mapFunction, mapContext) { + this.result = mapResult; + this.keyPrefix = keyPrefix; + this.func = mapFunction; + this.context = mapContext; + this.count = 0; +} +MapBookKeeping.prototype.destructor = function () { + this.result = null; + this.keyPrefix = null; + this.func = null; + this.context = null; + this.count = 0; +}; +PooledClass.addPoolingTo(MapBookKeeping, fourArgumentPooler); + +function mapSingleChildIntoContext(bookKeeping, child, childKey) { + var result = bookKeeping.result, + keyPrefix = bookKeeping.keyPrefix, + func = bookKeeping.func, + context = bookKeeping.context; + + + var mappedChild = func.call(context, child, bookKeeping.count++); + if (Array.isArray(mappedChild)) { + mapIntoWithKeyPrefixInternal(mappedChild, result, childKey, emptyFunction.thatReturnsArgument); + } else if (mappedChild != null) { + if (ReactElement.isValidElement(mappedChild)) { + mappedChild = ReactElement.cloneAndReplaceKey(mappedChild, + // Keep both the (mapped) and old keys if they differ, just as + // traverseAllChildren used to do for objects as children + keyPrefix + (mappedChild.key && (!child || child.key !== mappedChild.key) ? escapeUserProvidedKey(mappedChild.key) + '/' : '') + childKey); + } + result.push(mappedChild); + } +} + +function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) { + var escapedPrefix = ''; + if (prefix != null) { + escapedPrefix = escapeUserProvidedKey(prefix) + '/'; + } + var traverseContext = MapBookKeeping.getPooled(array, escapedPrefix, func, context); + traverseAllChildren(children, mapSingleChildIntoContext, traverseContext); + MapBookKeeping.release(traverseContext); +} + +/** + * Maps children that are typically specified as `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.map + * + * The provided mapFunction(child, key, index) will be called for each + * leaf child. + * + * @param {?*} children Children tree container. + * @param {function(*, int)} func The map function. + * @param {*} context Context for mapFunction. + * @return {object} Object containing the ordered map of results. + */ +function mapChildren(children, func, context) { + if (children == null) { + return children; + } + var result = []; + mapIntoWithKeyPrefixInternal(children, result, null, func, context); + return result; +} + +function forEachSingleChildDummy(traverseContext, child, name) { + return null; +} + +/** + * Count the number of children that are typically specified as + * `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.count + * + * @param {?*} children Children tree container. + * @return {number} The number of children. + */ +function countChildren(children, context) { + return traverseAllChildren(children, forEachSingleChildDummy, null); +} + +/** + * Flatten a children object (typically specified as `props.children`) and + * return an array with appropriately re-keyed children. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.toarray + */ +function toArray(children) { + var result = []; + mapIntoWithKeyPrefixInternal(children, result, null, emptyFunction.thatReturnsArgument); + return result; +} + +var ReactChildren = { + forEach: forEachChildren, + map: mapChildren, + mapIntoWithKeyPrefixInternal: mapIntoWithKeyPrefixInternal, + count: countChildren, + toArray: toArray +}; + +module.exports = ReactChildren; + +/***/ }), +/* 217 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(37); + +var invariant = __webpack_require__(2); + +/** + * Static poolers. Several custom versions for each potential number of + * arguments. A completely generic pooler is easy to implement, but would + * require accessing the `arguments` object. In each of these, `this` refers to + * the Class itself, not an instance. If any others are needed, simply add them + * here, or in their own files. + */ +var oneArgumentPooler = function (copyFieldsFrom) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, copyFieldsFrom); + return instance; + } else { + return new Klass(copyFieldsFrom); + } +}; + +var twoArgumentPooler = function (a1, a2) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2); + return instance; + } else { + return new Klass(a1, a2); + } +}; + +var threeArgumentPooler = function (a1, a2, a3) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3); + return instance; + } else { + return new Klass(a1, a2, a3); + } +}; + +var fourArgumentPooler = function (a1, a2, a3, a4) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3, a4); + return instance; + } else { + return new Klass(a1, a2, a3, a4); + } +}; + +var standardReleaser = function (instance) { + var Klass = this; + !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; + instance.destructor(); + if (Klass.instancePool.length < Klass.poolSize) { + Klass.instancePool.push(instance); + } +}; + +var DEFAULT_POOL_SIZE = 10; +var DEFAULT_POOLER = oneArgumentPooler; + +/** + * Augments `CopyConstructor` to be a poolable class, augmenting only the class + * itself (statically) not adding any prototypical fields. Any CopyConstructor + * you give this may have a `poolSize` property, and will look for a + * prototypical `destructor` on instances. + * + * @param {Function} CopyConstructor Constructor that can be used to reset. + * @param {Function} pooler Customizable pooler. + */ +var addPoolingTo = function (CopyConstructor, pooler) { + // Casting as any so that flow ignores the actual implementation and trusts + // it to match the type we declared + var NewKlass = CopyConstructor; + NewKlass.instancePool = []; + NewKlass.getPooled = pooler || DEFAULT_POOLER; + if (!NewKlass.poolSize) { + NewKlass.poolSize = DEFAULT_POOL_SIZE; + } + NewKlass.release = standardReleaser; + return NewKlass; +}; + +var PooledClass = { + addPoolingTo: addPoolingTo, + oneArgumentPooler: oneArgumentPooler, + twoArgumentPooler: twoArgumentPooler, + threeArgumentPooler: threeArgumentPooler, + fourArgumentPooler: fourArgumentPooler +}; + +module.exports = PooledClass; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 218 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(37); + +var ReactCurrentOwner = __webpack_require__(22); +var REACT_ELEMENT_TYPE = __webpack_require__(121); + +var getIteratorFn = __webpack_require__(122); +var invariant = __webpack_require__(2); +var KeyEscapeUtils = __webpack_require__(219); +var warning = __webpack_require__(3); + +var SEPARATOR = '.'; +var SUBSEPARATOR = ':'; + +/** + * This is inlined from ReactElement since this file is shared between + * isomorphic and renderers. We could extract this to a + * + */ + +/** + * TODO: Test that a single child and an array with one item have the same key + * pattern. + */ + +var didWarnAboutMaps = false; + +/** + * Generate a key string that identifies a component within a set. + * + * @param {*} component A component that could contain a manual key. + * @param {number} index Index that is used if a manual key is not provided. + * @return {string} + */ +function getComponentKey(component, index) { + // Do some typechecking here since we call this blindly. We want to ensure + // that we don't block potential future ES APIs. + if (component && typeof component === 'object' && component.key != null) { + // Explicit key + return KeyEscapeUtils.escape(component.key); + } + // Implicit key determined by the index in the set + return index.toString(36); +} + +/** + * @param {?*} children Children tree container. + * @param {!string} nameSoFar Name of the key path so far. + * @param {!function} callback Callback to invoke with each child found. + * @param {?*} traverseContext Used to pass information throughout the traversal + * process. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { + var type = typeof children; + + if (type === 'undefined' || type === 'boolean') { + // All of the above are perceived as null. + children = null; + } + + if (children === null || type === 'string' || type === 'number' || + // The following is inlined from ReactElement. This means we can optimize + // some checks. React Fiber also inlines this logic for similar purposes. + type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { + callback(traverseContext, children, + // If it's the only child, treat the name as if it was wrapped in an array + // so that it's consistent if the number of children grows. + nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); + return 1; + } + + var child; + var nextName; + var subtreeCount = 0; // Count of children found in the current subtree. + var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; + + if (Array.isArray(children)) { + for (var i = 0; i < children.length; i++) { + child = children[i]; + nextName = nextNamePrefix + getComponentKey(child, i); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + var iteratorFn = getIteratorFn(children); + if (iteratorFn) { + var iterator = iteratorFn.call(children); + var step; + if (iteratorFn !== children.entries) { + var ii = 0; + while (!(step = iterator.next()).done) { + child = step.value; + nextName = nextNamePrefix + getComponentKey(child, ii++); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + if (process.env.NODE_ENV !== 'production') { + var mapsAsChildrenAddendum = ''; + if (ReactCurrentOwner.current) { + var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); + if (mapsAsChildrenOwnerName) { + mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; + } + } + process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; + didWarnAboutMaps = true; + } + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + child = entry[1]; + nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } + } + } else if (type === 'object') { + var addendum = ''; + if (process.env.NODE_ENV !== 'production') { + addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; + if (children._isReactElement) { + addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; + } + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + addendum += ' Check the render method of `' + name + '`.'; + } + } + } + var childrenString = String(children); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; + } + } + + return subtreeCount; +} + +/** + * Traverses children that are typically specified as `props.children`, but + * might also be specified through attributes: + * + * - `traverseAllChildren(this.props.children, ...)` + * - `traverseAllChildren(this.props.leftPanelChildren, ...)` + * + * The `traverseContext` is an optional argument that is passed through the + * entire traversal. It can be used to store accumulations or anything else that + * the callback might find relevant. + * + * @param {?*} children Children tree object. + * @param {!function} callback To invoke upon traversing each child. + * @param {?*} traverseContext Context for traversal. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildren(children, callback, traverseContext) { + if (children == null) { + return 0; + } + + return traverseAllChildrenImpl(children, '', callback, traverseContext); +} + +module.exports = traverseAllChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 219 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/** + * Escape and wrap key so it is safe to use as a reactid + * + * @param {string} key to be escaped. + * @return {string} the escaped key. + */ + +function escape(key) { + var escapeRegex = /[=:]/g; + var escaperLookup = { + '=': '=0', + ':': '=2' + }; + var escapedString = ('' + key).replace(escapeRegex, function (match) { + return escaperLookup[match]; + }); + + return '$' + escapedString; +} + +/** + * Unescape and unwrap key for human-readable display + * + * @param {string} key to unescape. + * @return {string} the unescaped key. + */ +function unescape(key) { + var unescapeRegex = /(=0|=2)/g; + var unescaperLookup = { + '=0': '=', + '=2': ':' + }; + var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); + + return ('' + keySubstring).replace(unescapeRegex, function (match) { + return unescaperLookup[match]; + }); +} + +var KeyEscapeUtils = { + escape: escape, + unescape: unescape +}; + +module.exports = KeyEscapeUtils; + +/***/ }), +/* 220 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactElement = __webpack_require__(31); + +/** + * Create a factory that creates HTML tag elements. + * + * @private + */ +var createDOMFactory = ReactElement.createFactory; +if (process.env.NODE_ENV !== 'production') { + var ReactElementValidator = __webpack_require__(123); + createDOMFactory = ReactElementValidator.createFactory; +} + +/** + * Creates a mapping from supported HTML tags to `ReactDOMComponent` classes. + * + * @public + */ +var ReactDOMFactories = { + a: createDOMFactory('a'), + abbr: createDOMFactory('abbr'), + address: createDOMFactory('address'), + area: createDOMFactory('area'), + article: createDOMFactory('article'), + aside: createDOMFactory('aside'), + audio: createDOMFactory('audio'), + b: createDOMFactory('b'), + base: createDOMFactory('base'), + bdi: createDOMFactory('bdi'), + bdo: createDOMFactory('bdo'), + big: createDOMFactory('big'), + blockquote: createDOMFactory('blockquote'), + body: createDOMFactory('body'), + br: createDOMFactory('br'), + button: createDOMFactory('button'), + canvas: createDOMFactory('canvas'), + caption: createDOMFactory('caption'), + cite: createDOMFactory('cite'), + code: createDOMFactory('code'), + col: createDOMFactory('col'), + colgroup: createDOMFactory('colgroup'), + data: createDOMFactory('data'), + datalist: createDOMFactory('datalist'), + dd: createDOMFactory('dd'), + del: createDOMFactory('del'), + details: createDOMFactory('details'), + dfn: createDOMFactory('dfn'), + dialog: createDOMFactory('dialog'), + div: createDOMFactory('div'), + dl: createDOMFactory('dl'), + dt: createDOMFactory('dt'), + em: createDOMFactory('em'), + embed: createDOMFactory('embed'), + fieldset: createDOMFactory('fieldset'), + figcaption: createDOMFactory('figcaption'), + figure: createDOMFactory('figure'), + footer: createDOMFactory('footer'), + form: createDOMFactory('form'), + h1: createDOMFactory('h1'), + h2: createDOMFactory('h2'), + h3: createDOMFactory('h3'), + h4: createDOMFactory('h4'), + h5: createDOMFactory('h5'), + h6: createDOMFactory('h6'), + head: createDOMFactory('head'), + header: createDOMFactory('header'), + hgroup: createDOMFactory('hgroup'), + hr: createDOMFactory('hr'), + html: createDOMFactory('html'), + i: createDOMFactory('i'), + iframe: createDOMFactory('iframe'), + img: createDOMFactory('img'), + input: createDOMFactory('input'), + ins: createDOMFactory('ins'), + kbd: createDOMFactory('kbd'), + keygen: createDOMFactory('keygen'), + label: createDOMFactory('label'), + legend: createDOMFactory('legend'), + li: createDOMFactory('li'), + link: createDOMFactory('link'), + main: createDOMFactory('main'), + map: createDOMFactory('map'), + mark: createDOMFactory('mark'), + menu: createDOMFactory('menu'), + menuitem: createDOMFactory('menuitem'), + meta: createDOMFactory('meta'), + meter: createDOMFactory('meter'), + nav: createDOMFactory('nav'), + noscript: createDOMFactory('noscript'), + object: createDOMFactory('object'), + ol: createDOMFactory('ol'), + optgroup: createDOMFactory('optgroup'), + option: createDOMFactory('option'), + output: createDOMFactory('output'), + p: createDOMFactory('p'), + param: createDOMFactory('param'), + picture: createDOMFactory('picture'), + pre: createDOMFactory('pre'), + progress: createDOMFactory('progress'), + q: createDOMFactory('q'), + rp: createDOMFactory('rp'), + rt: createDOMFactory('rt'), + ruby: createDOMFactory('ruby'), + s: createDOMFactory('s'), + samp: createDOMFactory('samp'), + script: createDOMFactory('script'), + section: createDOMFactory('section'), + select: createDOMFactory('select'), + small: createDOMFactory('small'), + source: createDOMFactory('source'), + span: createDOMFactory('span'), + strong: createDOMFactory('strong'), + style: createDOMFactory('style'), + sub: createDOMFactory('sub'), + summary: createDOMFactory('summary'), + sup: createDOMFactory('sup'), + table: createDOMFactory('table'), + tbody: createDOMFactory('tbody'), + td: createDOMFactory('td'), + textarea: createDOMFactory('textarea'), + tfoot: createDOMFactory('tfoot'), + th: createDOMFactory('th'), + thead: createDOMFactory('thead'), + time: createDOMFactory('time'), + title: createDOMFactory('title'), + tr: createDOMFactory('tr'), + track: createDOMFactory('track'), + u: createDOMFactory('u'), + ul: createDOMFactory('ul'), + 'var': createDOMFactory('var'), + video: createDOMFactory('video'), + wbr: createDOMFactory('wbr'), + + // SVG + circle: createDOMFactory('circle'), + clipPath: createDOMFactory('clipPath'), + defs: createDOMFactory('defs'), + ellipse: createDOMFactory('ellipse'), + g: createDOMFactory('g'), + image: createDOMFactory('image'), + line: createDOMFactory('line'), + linearGradient: createDOMFactory('linearGradient'), + mask: createDOMFactory('mask'), + path: createDOMFactory('path'), + pattern: createDOMFactory('pattern'), + polygon: createDOMFactory('polygon'), + polyline: createDOMFactory('polyline'), + radialGradient: createDOMFactory('radialGradient'), + rect: createDOMFactory('rect'), + stop: createDOMFactory('stop'), + svg: createDOMFactory('svg'), + text: createDOMFactory('text'), + tspan: createDOMFactory('tspan') +}; + +module.exports = ReactDOMFactories; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 221 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(37); + +var ReactPropTypeLocationNames = __webpack_require__(222); +var ReactPropTypesSecret = __webpack_require__(223); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var ReactComponentTreeHook; + +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} + +var loggedTypeFailures = {}; + +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?object} element The React element that is being type-checked + * @param {?number} debugID The React component instance that is being type-checked + * @private + */ +function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var componentStackInfo = ''; + + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (debugID !== null) { + componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); + } else if (element !== null) { + componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); + } + } + + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; + } + } + } +} + +module.exports = checkReactTypeSpec; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 222 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactPropTypeLocationNames = {}; + +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} + +module.exports = ReactPropTypeLocationNames; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 223 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; + +module.exports = ReactPropTypesSecret; + +/***/ }), +/* 224 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _require = __webpack_require__(31), + isValidElement = _require.isValidElement; + +var factory = __webpack_require__(124); + +module.exports = factory(isValidElement); + +/***/ }), +/* 225 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +if (process.env.NODE_ENV !== 'production') { + var invariant = __webpack_require__(2); + var warning = __webpack_require__(3); + var ReactPropTypesSecret = __webpack_require__(75); + var loggedTypeFailures = {}; +} + +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?Function} getStack Returns the component stack. + * @private + */ +function checkPropTypes(typeSpecs, values, location, componentName, getStack) { + if (process.env.NODE_ENV !== 'production') { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + invariant(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', componentName || 'React class', location, typeSpecName); + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error); + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var stack = getStack ? getStack() : ''; + + warning(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : ''); + } + } + } + } +} + +module.exports = checkPropTypes; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 226 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +module.exports = '15.6.1'; + +/***/ }), +/* 227 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _require = __webpack_require__(119), + Component = _require.Component; + +var _require2 = __webpack_require__(31), + isValidElement = _require2.isValidElement; + +var ReactNoopUpdateQueue = __webpack_require__(120); +var factory = __webpack_require__(228); + +module.exports = factory(Component, isValidElement, ReactNoopUpdateQueue); + +/***/ }), +/* 228 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var emptyObject = __webpack_require__(56); +var _invariant = __webpack_require__(2); + +if (process.env.NODE_ENV !== 'production') { + var warning = __webpack_require__(3); +} + +var MIXINS_KEY = 'mixins'; + +// Helper function to allow the creation of anonymous functions which do not +// have .name set to the name of the variable being assigned to. +function identity(fn) { + return fn; +} + +var ReactPropTypeLocationNames; +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} else { + ReactPropTypeLocationNames = {}; +} + +function factory(ReactComponent, isValidElement, ReactNoopUpdateQueue) { + /** + * Policies that describe methods in `ReactClassInterface`. + */ + + var injectedMixins = []; + + /** + * Composite components are higher-level components that compose other composite + * or host components. + * + * To create a new type of `ReactClass`, pass a specification of + * your new class to `React.createClass`. The only requirement of your class + * specification is that you implement a `render` method. + * + * var MyComponent = React.createClass({ + * render: function() { + * return <div>Hello World</div>; + * } + * }); + * + * The class specification supports a specific protocol of methods that have + * special meaning (e.g. `render`). See `ReactClassInterface` for + * more the comprehensive protocol. Any other properties and methods in the + * class specification will be available on the prototype. + * + * @interface ReactClassInterface + * @internal + */ + var ReactClassInterface = { + /** + * An array of Mixin objects to include when defining your component. + * + * @type {array} + * @optional + */ + mixins: 'DEFINE_MANY', + + /** + * An object containing properties and methods that should be defined on + * the component's constructor instead of its prototype (static methods). + * + * @type {object} + * @optional + */ + statics: 'DEFINE_MANY', + + /** + * Definition of prop types for this component. + * + * @type {object} + * @optional + */ + propTypes: 'DEFINE_MANY', + + /** + * Definition of context types for this component. + * + * @type {object} + * @optional + */ + contextTypes: 'DEFINE_MANY', + + /** + * Definition of context types this component sets for its children. + * + * @type {object} + * @optional + */ + childContextTypes: 'DEFINE_MANY', + + // ==== Definition methods ==== + + /** + * Invoked when the component is mounted. Values in the mapping will be set on + * `this.props` if that prop is not specified (i.e. using an `in` check). + * + * This method is invoked before `getInitialState` and therefore cannot rely + * on `this.state` or use `this.setState`. + * + * @return {object} + * @optional + */ + getDefaultProps: 'DEFINE_MANY_MERGED', + + /** + * Invoked once before the component is mounted. The return value will be used + * as the initial value of `this.state`. + * + * getInitialState: function() { + * return { + * isOn: false, + * fooBaz: new BazFoo() + * } + * } + * + * @return {object} + * @optional + */ + getInitialState: 'DEFINE_MANY_MERGED', + + /** + * @return {object} + * @optional + */ + getChildContext: 'DEFINE_MANY_MERGED', + + /** + * Uses props from `this.props` and state from `this.state` to render the + * structure of the component. + * + * No guarantees are made about when or how often this method is invoked, so + * it must not have side effects. + * + * render: function() { + * var name = this.props.name; + * return <div>Hello, {name}!</div>; + * } + * + * @return {ReactComponent} + * @required + */ + render: 'DEFINE_ONCE', + + // ==== Delegate methods ==== + + /** + * Invoked when the component is initially created and about to be mounted. + * This may have side effects, but any external subscriptions or data created + * by this method must be cleaned up in `componentWillUnmount`. + * + * @optional + */ + componentWillMount: 'DEFINE_MANY', + + /** + * Invoked when the component has been mounted and has a DOM representation. + * However, there is no guarantee that the DOM node is in the document. + * + * Use this as an opportunity to operate on the DOM when the component has + * been mounted (initialized and rendered) for the first time. + * + * @param {DOMElement} rootNode DOM element representing the component. + * @optional + */ + componentDidMount: 'DEFINE_MANY', + + /** + * Invoked before the component receives new props. + * + * Use this as an opportunity to react to a prop transition by updating the + * state using `this.setState`. Current props are accessed via `this.props`. + * + * componentWillReceiveProps: function(nextProps, nextContext) { + * this.setState({ + * likesIncreasing: nextProps.likeCount > this.props.likeCount + * }); + * } + * + * NOTE: There is no equivalent `componentWillReceiveState`. An incoming prop + * transition may cause a state change, but the opposite is not true. If you + * need it, you are probably looking for `componentWillUpdate`. + * + * @param {object} nextProps + * @optional + */ + componentWillReceiveProps: 'DEFINE_MANY', + + /** + * Invoked while deciding if the component should be updated as a result of + * receiving new props, state and/or context. + * + * Use this as an opportunity to `return false` when you're certain that the + * transition to the new props/state/context will not require a component + * update. + * + * shouldComponentUpdate: function(nextProps, nextState, nextContext) { + * return !equal(nextProps, this.props) || + * !equal(nextState, this.state) || + * !equal(nextContext, this.context); + * } + * + * @param {object} nextProps + * @param {?object} nextState + * @param {?object} nextContext + * @return {boolean} True if the component should update. + * @optional + */ + shouldComponentUpdate: 'DEFINE_ONCE', + + /** + * Invoked when the component is about to update due to a transition from + * `this.props`, `this.state` and `this.context` to `nextProps`, `nextState` + * and `nextContext`. + * + * Use this as an opportunity to perform preparation before an update occurs. + * + * NOTE: You **cannot** use `this.setState()` in this method. + * + * @param {object} nextProps + * @param {?object} nextState + * @param {?object} nextContext + * @param {ReactReconcileTransaction} transaction + * @optional + */ + componentWillUpdate: 'DEFINE_MANY', + + /** + * Invoked when the component's DOM representation has been updated. + * + * Use this as an opportunity to operate on the DOM when the component has + * been updated. + * + * @param {object} prevProps + * @param {?object} prevState + * @param {?object} prevContext + * @param {DOMElement} rootNode DOM element representing the component. + * @optional + */ + componentDidUpdate: 'DEFINE_MANY', + + /** + * Invoked when the component is about to be removed from its parent and have + * its DOM representation destroyed. + * + * Use this as an opportunity to deallocate any external resources. + * + * NOTE: There is no `componentDidUnmount` since your component will have been + * destroyed by that point. + * + * @optional + */ + componentWillUnmount: 'DEFINE_MANY', + + // ==== Advanced methods ==== + + /** + * Updates the component's currently mounted DOM representation. + * + * By default, this implements React's rendering and reconciliation algorithm. + * Sophisticated clients may wish to override this. + * + * @param {ReactReconcileTransaction} transaction + * @internal + * @overridable + */ + updateComponent: 'OVERRIDE_BASE' + }; + + /** + * Mapping from class specification keys to special processing functions. + * + * Although these are declared like instance properties in the specification + * when defining classes using `React.createClass`, they are actually static + * and are accessible on the constructor instead of the prototype. Despite + * being static, they must be defined outside of the "statics" key under + * which all other static methods are defined. + */ + var RESERVED_SPEC_KEYS = { + displayName: function(Constructor, displayName) { + Constructor.displayName = displayName; + }, + mixins: function(Constructor, mixins) { + if (mixins) { + for (var i = 0; i < mixins.length; i++) { + mixSpecIntoComponent(Constructor, mixins[i]); + } + } + }, + childContextTypes: function(Constructor, childContextTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, childContextTypes, 'childContext'); + } + Constructor.childContextTypes = _assign( + {}, + Constructor.childContextTypes, + childContextTypes + ); + }, + contextTypes: function(Constructor, contextTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, contextTypes, 'context'); + } + Constructor.contextTypes = _assign( + {}, + Constructor.contextTypes, + contextTypes + ); + }, + /** + * Special case getDefaultProps which should move into statics but requires + * automatic merging. + */ + getDefaultProps: function(Constructor, getDefaultProps) { + if (Constructor.getDefaultProps) { + Constructor.getDefaultProps = createMergedResultFunction( + Constructor.getDefaultProps, + getDefaultProps + ); + } else { + Constructor.getDefaultProps = getDefaultProps; + } + }, + propTypes: function(Constructor, propTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, propTypes, 'prop'); + } + Constructor.propTypes = _assign({}, Constructor.propTypes, propTypes); + }, + statics: function(Constructor, statics) { + mixStaticSpecIntoComponent(Constructor, statics); + }, + autobind: function() {} + }; + + function validateTypeDef(Constructor, typeDef, location) { + for (var propName in typeDef) { + if (typeDef.hasOwnProperty(propName)) { + // use a warning instead of an _invariant so components + // don't show up in prod but only in __DEV__ + if (process.env.NODE_ENV !== 'production') { + warning( + typeof typeDef[propName] === 'function', + '%s: %s type `%s` is invalid; it must be a function, usually from ' + + 'React.PropTypes.', + Constructor.displayName || 'ReactClass', + ReactPropTypeLocationNames[location], + propName + ); + } + } + } + } + + function validateMethodOverride(isAlreadyDefined, name) { + var specPolicy = ReactClassInterface.hasOwnProperty(name) + ? ReactClassInterface[name] + : null; + + // Disallow overriding of base class methods unless explicitly allowed. + if (ReactClassMixin.hasOwnProperty(name)) { + _invariant( + specPolicy === 'OVERRIDE_BASE', + 'ReactClassInterface: You are attempting to override ' + + '`%s` from your class specification. Ensure that your method names ' + + 'do not overlap with React methods.', + name + ); + } + + // Disallow defining methods more than once unless explicitly allowed. + if (isAlreadyDefined) { + _invariant( + specPolicy === 'DEFINE_MANY' || specPolicy === 'DEFINE_MANY_MERGED', + 'ReactClassInterface: You are attempting to define ' + + '`%s` on your component more than once. This conflict may be due ' + + 'to a mixin.', + name + ); + } + } + + /** + * Mixin helper which handles policy validation and reserved + * specification keys when building React classes. + */ + function mixSpecIntoComponent(Constructor, spec) { + if (!spec) { + if (process.env.NODE_ENV !== 'production') { + var typeofSpec = typeof spec; + var isMixinValid = typeofSpec === 'object' && spec !== null; + + if (process.env.NODE_ENV !== 'production') { + warning( + isMixinValid, + "%s: You're attempting to include a mixin that is either null " + + 'or not an object. Check the mixins included by the component, ' + + 'as well as any mixins they include themselves. ' + + 'Expected object but got %s.', + Constructor.displayName || 'ReactClass', + spec === null ? null : typeofSpec + ); + } + } + + return; + } + + _invariant( + typeof spec !== 'function', + "ReactClass: You're attempting to " + + 'use a component class or function as a mixin. Instead, just use a ' + + 'regular object.' + ); + _invariant( + !isValidElement(spec), + "ReactClass: You're attempting to " + + 'use a component as a mixin. Instead, just use a regular object.' + ); + + var proto = Constructor.prototype; + var autoBindPairs = proto.__reactAutoBindPairs; + + // By handling mixins before any other properties, we ensure the same + // chaining order is applied to methods with DEFINE_MANY policy, whether + // mixins are listed before or after these methods in the spec. + if (spec.hasOwnProperty(MIXINS_KEY)) { + RESERVED_SPEC_KEYS.mixins(Constructor, spec.mixins); + } + + for (var name in spec) { + if (!spec.hasOwnProperty(name)) { + continue; + } + + if (name === MIXINS_KEY) { + // We have already handled mixins in a special case above. + continue; + } + + var property = spec[name]; + var isAlreadyDefined = proto.hasOwnProperty(name); + validateMethodOverride(isAlreadyDefined, name); + + if (RESERVED_SPEC_KEYS.hasOwnProperty(name)) { + RESERVED_SPEC_KEYS[name](Constructor, property); + } else { + // Setup methods on prototype: + // The following member methods should not be automatically bound: + // 1. Expected ReactClass methods (in the "interface"). + // 2. Overridden methods (that were mixed in). + var isReactClassMethod = ReactClassInterface.hasOwnProperty(name); + var isFunction = typeof property === 'function'; + var shouldAutoBind = + isFunction && + !isReactClassMethod && + !isAlreadyDefined && + spec.autobind !== false; + + if (shouldAutoBind) { + autoBindPairs.push(name, property); + proto[name] = property; + } else { + if (isAlreadyDefined) { + var specPolicy = ReactClassInterface[name]; + + // These cases should already be caught by validateMethodOverride. + _invariant( + isReactClassMethod && + (specPolicy === 'DEFINE_MANY_MERGED' || + specPolicy === 'DEFINE_MANY'), + 'ReactClass: Unexpected spec policy %s for key %s ' + + 'when mixing in component specs.', + specPolicy, + name + ); + + // For methods which are defined more than once, call the existing + // methods before calling the new property, merging if appropriate. + if (specPolicy === 'DEFINE_MANY_MERGED') { + proto[name] = createMergedResultFunction(proto[name], property); + } else if (specPolicy === 'DEFINE_MANY') { + proto[name] = createChainedFunction(proto[name], property); + } + } else { + proto[name] = property; + if (process.env.NODE_ENV !== 'production') { + // Add verbose displayName to the function, which helps when looking + // at profiling tools. + if (typeof property === 'function' && spec.displayName) { + proto[name].displayName = spec.displayName + '_' + name; + } + } + } + } + } + } + } + + function mixStaticSpecIntoComponent(Constructor, statics) { + if (!statics) { + return; + } + for (var name in statics) { + var property = statics[name]; + if (!statics.hasOwnProperty(name)) { + continue; + } + + var isReserved = name in RESERVED_SPEC_KEYS; + _invariant( + !isReserved, + 'ReactClass: You are attempting to define a reserved ' + + 'property, `%s`, that shouldn\'t be on the "statics" key. Define it ' + + 'as an instance property instead; it will still be accessible on the ' + + 'constructor.', + name + ); + + var isInherited = name in Constructor; + _invariant( + !isInherited, + 'ReactClass: You are attempting to define ' + + '`%s` on your component more than once. This conflict may be ' + + 'due to a mixin.', + name + ); + Constructor[name] = property; + } + } + + /** + * Merge two objects, but throw if both contain the same key. + * + * @param {object} one The first object, which is mutated. + * @param {object} two The second object + * @return {object} one after it has been mutated to contain everything in two. + */ + function mergeIntoWithNoDuplicateKeys(one, two) { + _invariant( + one && two && typeof one === 'object' && typeof two === 'object', + 'mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.' + ); + + for (var key in two) { + if (two.hasOwnProperty(key)) { + _invariant( + one[key] === undefined, + 'mergeIntoWithNoDuplicateKeys(): ' + + 'Tried to merge two objects with the same key: `%s`. This conflict ' + + 'may be due to a mixin; in particular, this may be caused by two ' + + 'getInitialState() or getDefaultProps() methods returning objects ' + + 'with clashing keys.', + key + ); + one[key] = two[key]; + } + } + return one; + } + + /** + * Creates a function that invokes two functions and merges their return values. + * + * @param {function} one Function to invoke first. + * @param {function} two Function to invoke second. + * @return {function} Function that invokes the two argument functions. + * @private + */ + function createMergedResultFunction(one, two) { + return function mergedResult() { + var a = one.apply(this, arguments); + var b = two.apply(this, arguments); + if (a == null) { + return b; + } else if (b == null) { + return a; + } + var c = {}; + mergeIntoWithNoDuplicateKeys(c, a); + mergeIntoWithNoDuplicateKeys(c, b); + return c; + }; + } + + /** + * Creates a function that invokes two functions and ignores their return vales. + * + * @param {function} one Function to invoke first. + * @param {function} two Function to invoke second. + * @return {function} Function that invokes the two argument functions. + * @private + */ + function createChainedFunction(one, two) { + return function chainedFunction() { + one.apply(this, arguments); + two.apply(this, arguments); + }; + } + + /** + * Binds a method to the component. + * + * @param {object} component Component whose method is going to be bound. + * @param {function} method Method to be bound. + * @return {function} The bound method. + */ + function bindAutoBindMethod(component, method) { + var boundMethod = method.bind(component); + if (process.env.NODE_ENV !== 'production') { + boundMethod.__reactBoundContext = component; + boundMethod.__reactBoundMethod = method; + boundMethod.__reactBoundArguments = null; + var componentName = component.constructor.displayName; + var _bind = boundMethod.bind; + boundMethod.bind = function(newThis) { + for ( + var _len = arguments.length, + args = Array(_len > 1 ? _len - 1 : 0), + _key = 1; + _key < _len; + _key++ + ) { + args[_key - 1] = arguments[_key]; + } + + // User is trying to bind() an autobound method; we effectively will + // ignore the value of "this" that the user is trying to use, so + // let's warn. + if (newThis !== component && newThis !== null) { + if (process.env.NODE_ENV !== 'production') { + warning( + false, + 'bind(): React component methods may only be bound to the ' + + 'component instance. See %s', + componentName + ); + } + } else if (!args.length) { + if (process.env.NODE_ENV !== 'production') { + warning( + false, + 'bind(): You are binding a component method to the component. ' + + 'React does this for you automatically in a high-performance ' + + 'way, so you can safely remove this call. See %s', + componentName + ); + } + return boundMethod; + } + var reboundMethod = _bind.apply(boundMethod, arguments); + reboundMethod.__reactBoundContext = component; + reboundMethod.__reactBoundMethod = method; + reboundMethod.__reactBoundArguments = args; + return reboundMethod; + }; + } + return boundMethod; + } + + /** + * Binds all auto-bound methods in a component. + * + * @param {object} component Component whose method is going to be bound. + */ + function bindAutoBindMethods(component) { + var pairs = component.__reactAutoBindPairs; + for (var i = 0; i < pairs.length; i += 2) { + var autoBindKey = pairs[i]; + var method = pairs[i + 1]; + component[autoBindKey] = bindAutoBindMethod(component, method); + } + } + + var IsMountedPreMixin = { + componentDidMount: function() { + this.__isMounted = true; + } + }; + + var IsMountedPostMixin = { + componentWillUnmount: function() { + this.__isMounted = false; + } + }; + + /** + * Add more to the ReactClass base class. These are all legacy features and + * therefore not already part of the modern ReactComponent. + */ + var ReactClassMixin = { + /** + * TODO: This will be deprecated because state should always keep a consistent + * type signature and the only use case for this, is to avoid that. + */ + replaceState: function(newState, callback) { + this.updater.enqueueReplaceState(this, newState, callback); + }, + + /** + * Checks whether or not this composite component is mounted. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + isMounted: function() { + if (process.env.NODE_ENV !== 'production') { + warning( + this.__didWarnIsMounted, + '%s: isMounted is deprecated. Instead, make sure to clean up ' + + 'subscriptions and pending requests in componentWillUnmount to ' + + 'prevent memory leaks.', + (this.constructor && this.constructor.displayName) || + this.name || + 'Component' + ); + this.__didWarnIsMounted = true; + } + return !!this.__isMounted; + } + }; + + var ReactClassComponent = function() {}; + _assign( + ReactClassComponent.prototype, + ReactComponent.prototype, + ReactClassMixin + ); + + /** + * Creates a composite component class given a class specification. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createclass + * + * @param {object} spec Class specification (which must define `render`). + * @return {function} Component constructor function. + * @public + */ + function createClass(spec) { + // To keep our warnings more understandable, we'll use a little hack here to + // ensure that Constructor.name !== 'Constructor'. This makes sure we don't + // unnecessarily identify a class without displayName as 'Constructor'. + var Constructor = identity(function(props, context, updater) { + // This constructor gets overridden by mocks. The argument is used + // by mocks to assert on what gets mounted. + + if (process.env.NODE_ENV !== 'production') { + warning( + this instanceof Constructor, + 'Something is calling a React component directly. Use a factory or ' + + 'JSX instead. See: https://fb.me/react-legacyfactory' + ); + } + + // Wire up auto-binding + if (this.__reactAutoBindPairs.length) { + bindAutoBindMethods(this); + } + + this.props = props; + this.context = context; + this.refs = emptyObject; + this.updater = updater || ReactNoopUpdateQueue; + + this.state = null; + + // ReactClasses doesn't have constructors. Instead, they use the + // getInitialState and componentWillMount methods for initialization. + + var initialState = this.getInitialState ? this.getInitialState() : null; + if (process.env.NODE_ENV !== 'production') { + // We allow auto-mocks to proceed as if they're returning null. + if ( + initialState === undefined && + this.getInitialState._isMockFunction + ) { + // This is probably bad practice. Consider warning here and + // deprecating this convenience. + initialState = null; + } + } + _invariant( + typeof initialState === 'object' && !Array.isArray(initialState), + '%s.getInitialState(): must return an object or null', + Constructor.displayName || 'ReactCompositeComponent' + ); + + this.state = initialState; + }); + Constructor.prototype = new ReactClassComponent(); + Constructor.prototype.constructor = Constructor; + Constructor.prototype.__reactAutoBindPairs = []; + + injectedMixins.forEach(mixSpecIntoComponent.bind(null, Constructor)); + + mixSpecIntoComponent(Constructor, IsMountedPreMixin); + mixSpecIntoComponent(Constructor, spec); + mixSpecIntoComponent(Constructor, IsMountedPostMixin); + + // Initialize the defaultProps property after all mixins have been merged. + if (Constructor.getDefaultProps) { + Constructor.defaultProps = Constructor.getDefaultProps(); + } + + if (process.env.NODE_ENV !== 'production') { + // This is a tag to indicate that the use of these method names is ok, + // since it's used with createClass. If it's not, then it's likely a + // mistake so we'll warn you to use the static property, property + // initializer or constructor respectively. + if (Constructor.getDefaultProps) { + Constructor.getDefaultProps.isReactClassApproved = {}; + } + if (Constructor.prototype.getInitialState) { + Constructor.prototype.getInitialState.isReactClassApproved = {}; + } + } + + _invariant( + Constructor.prototype.render, + 'createClass(...): Class specification must implement a `render` method.' + ); + + if (process.env.NODE_ENV !== 'production') { + warning( + !Constructor.prototype.componentShouldUpdate, + '%s has a method called ' + + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + + 'The name is phrased as a question because the function is ' + + 'expected to return a value.', + spec.displayName || 'A component' + ); + warning( + !Constructor.prototype.componentWillRecieveProps, + '%s has a method called ' + + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', + spec.displayName || 'A component' + ); + } + + // Reduce time spent doing lookups by setting these on the prototype. + for (var methodName in ReactClassInterface) { + if (!Constructor.prototype[methodName]) { + Constructor.prototype[methodName] = null; + } + } + + return Constructor; + } + + return createClass; +} + +module.exports = factory; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 229 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + +var _prodInvariant = __webpack_require__(37); + +var ReactElement = __webpack_require__(31); + +var invariant = __webpack_require__(2); + +/** + * Returns the first child in a collection of children and verifies that there + * is only one child in the collection. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.only + * + * The current implementation of this function assumes that a single child gets + * passed without a wrapper, but the purpose of this helper function is to + * abstract away the particular structure of children. + * + * @param {?object} children Child collection structure. + * @return {ReactElement} The first and only `ReactElement` contained in the + * structure. + */ +function onlyChild(children) { + !ReactElement.isValidElement(children) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React.Children.only expected to receive a single React element child.') : _prodInvariant('143') : void 0; + return children; +} + +module.exports = onlyChild; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 230 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/* globals __REACT_DEVTOOLS_GLOBAL_HOOK__*/ + + + +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDefaultInjection = __webpack_require__(231); +var ReactMount = __webpack_require__(149); +var ReactReconciler = __webpack_require__(38); +var ReactUpdates = __webpack_require__(23); +var ReactVersion = __webpack_require__(309); + +var findDOMNode = __webpack_require__(310); +var getHostComponentFromComposite = __webpack_require__(150); +var renderSubtreeIntoContainer = __webpack_require__(311); +var warning = __webpack_require__(3); + +ReactDefaultInjection.inject(); + +var ReactDOM = { + findDOMNode: findDOMNode, + render: ReactMount.render, + unmountComponentAtNode: ReactMount.unmountComponentAtNode, + version: ReactVersion, + + /* eslint-disable camelcase */ + unstable_batchedUpdates: ReactUpdates.batchedUpdates, + unstable_renderSubtreeIntoContainer: renderSubtreeIntoContainer + /* eslint-enable camelcase */ +}; + +// Inject the runtime into a devtools global hook regardless of browser. +// Allows for debugging when the hook is injected on the page. +if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject === 'function') { + __REACT_DEVTOOLS_GLOBAL_HOOK__.inject({ + ComponentTree: { + getClosestInstanceFromNode: ReactDOMComponentTree.getClosestInstanceFromNode, + getNodeFromInstance: function (inst) { + // inst is an internal instance (but could be a composite) + if (inst._renderedComponent) { + inst = getHostComponentFromComposite(inst); + } + if (inst) { + return ReactDOMComponentTree.getNodeFromInstance(inst); + } else { + return null; + } + } + }, + Mount: ReactMount, + Reconciler: ReactReconciler + }); +} + +if (process.env.NODE_ENV !== 'production') { + var ExecutionEnvironment = __webpack_require__(13); + if (ExecutionEnvironment.canUseDOM && window.top === window.self) { + // First check if devtools is not installed + if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined') { + // If we're in Chrome or Firefox, provide a download link if not installed. + if (navigator.userAgent.indexOf('Chrome') > -1 && navigator.userAgent.indexOf('Edge') === -1 || navigator.userAgent.indexOf('Firefox') > -1) { + // Firefox does not have the issue with devtools loaded over file:// + var showFileUrlMessage = window.location.protocol.indexOf('http') === -1 && navigator.userAgent.indexOf('Firefox') === -1; + console.debug('Download the React DevTools ' + (showFileUrlMessage ? 'and use an HTTP server (instead of a file: URL) ' : '') + 'for a better development experience: ' + 'https://fb.me/react-devtools'); + } + } + + var testFunc = function testFn() {}; + process.env.NODE_ENV !== 'production' ? warning((testFunc.name || testFunc.toString()).indexOf('testFn') !== -1, "It looks like you're using a minified copy of the development build " + 'of React. When deploying React apps to production, make sure to use ' + 'the production build which skips development warnings and is faster. ' + 'See https://fb.me/react-minification for more details.') : void 0; + + // If we're in IE8, check to see if we are in compatibility mode and provide + // information on preventing compatibility mode + var ieCompatibilityMode = document.documentMode && document.documentMode < 8; + + process.env.NODE_ENV !== 'production' ? warning(!ieCompatibilityMode, 'Internet Explorer is running in compatibility mode; please add the ' + 'following tag to your HTML to prevent this from happening: ' + '<meta http-equiv="X-UA-Compatible" content="IE=edge" />') : void 0; + + var expectedFeatures = [ + // shims + Array.isArray, Array.prototype.every, Array.prototype.forEach, Array.prototype.indexOf, Array.prototype.map, Date.now, Function.prototype.bind, Object.keys, String.prototype.trim]; + + for (var i = 0; i < expectedFeatures.length; i++) { + if (!expectedFeatures[i]) { + process.env.NODE_ENV !== 'production' ? warning(false, 'One or more ES5 shims expected by React are not available: ' + 'https://fb.me/react-warning-polyfills') : void 0; + break; + } + } + } +} + +if (process.env.NODE_ENV !== 'production') { + var ReactInstrumentation = __webpack_require__(19); + var ReactDOMUnknownPropertyHook = __webpack_require__(312); + var ReactDOMNullInputValuePropHook = __webpack_require__(313); + var ReactDOMInvalidARIAHook = __webpack_require__(314); + + ReactInstrumentation.debugTool.addHook(ReactDOMUnknownPropertyHook); + ReactInstrumentation.debugTool.addHook(ReactDOMNullInputValuePropHook); + ReactInstrumentation.debugTool.addHook(ReactDOMInvalidARIAHook); +} + +module.exports = ReactDOM; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 231 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ARIADOMPropertyConfig = __webpack_require__(232); +var BeforeInputEventPlugin = __webpack_require__(233); +var ChangeEventPlugin = __webpack_require__(237); +var DefaultEventPluginOrder = __webpack_require__(245); +var EnterLeaveEventPlugin = __webpack_require__(246); +var HTMLDOMPropertyConfig = __webpack_require__(247); +var ReactComponentBrowserEnvironment = __webpack_require__(248); +var ReactDOMComponent = __webpack_require__(254); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMEmptyComponent = __webpack_require__(280); +var ReactDOMTreeTraversal = __webpack_require__(281); +var ReactDOMTextComponent = __webpack_require__(282); +var ReactDefaultBatchingStrategy = __webpack_require__(283); +var ReactEventListener = __webpack_require__(284); +var ReactInjection = __webpack_require__(286); +var ReactReconcileTransaction = __webpack_require__(287); +var SVGDOMPropertyConfig = __webpack_require__(293); +var SelectEventPlugin = __webpack_require__(294); +var SimpleEventPlugin = __webpack_require__(295); + +var alreadyInjected = false; + +function inject() { + if (alreadyInjected) { + // TODO: This is currently true because these injections are shared between + // the client and the server package. They should be built independently + // and not share any injection state. Then this problem will be solved. + return; + } + alreadyInjected = true; + + ReactInjection.EventEmitter.injectReactEventListener(ReactEventListener); + + /** + * Inject modules for resolving DOM hierarchy and plugin ordering. + */ + ReactInjection.EventPluginHub.injectEventPluginOrder(DefaultEventPluginOrder); + ReactInjection.EventPluginUtils.injectComponentTree(ReactDOMComponentTree); + ReactInjection.EventPluginUtils.injectTreeTraversal(ReactDOMTreeTraversal); + + /** + * Some important event plugins included by default (without having to require + * them). + */ + ReactInjection.EventPluginHub.injectEventPluginsByName({ + SimpleEventPlugin: SimpleEventPlugin, + EnterLeaveEventPlugin: EnterLeaveEventPlugin, + ChangeEventPlugin: ChangeEventPlugin, + SelectEventPlugin: SelectEventPlugin, + BeforeInputEventPlugin: BeforeInputEventPlugin + }); + + ReactInjection.HostComponent.injectGenericComponentClass(ReactDOMComponent); + + ReactInjection.HostComponent.injectTextComponentClass(ReactDOMTextComponent); + + ReactInjection.DOMProperty.injectDOMPropertyConfig(ARIADOMPropertyConfig); + ReactInjection.DOMProperty.injectDOMPropertyConfig(HTMLDOMPropertyConfig); + ReactInjection.DOMProperty.injectDOMPropertyConfig(SVGDOMPropertyConfig); + + ReactInjection.EmptyComponent.injectEmptyComponentFactory(function (instantiate) { + return new ReactDOMEmptyComponent(instantiate); + }); + + ReactInjection.Updates.injectReconcileTransaction(ReactReconcileTransaction); + ReactInjection.Updates.injectBatchingStrategy(ReactDefaultBatchingStrategy); + + ReactInjection.Component.injectEnvironment(ReactComponentBrowserEnvironment); +} + +module.exports = { + inject: inject +}; + +/***/ }), +/* 232 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ARIADOMPropertyConfig = { + Properties: { + // Global States and Properties + 'aria-current': 0, // state + 'aria-details': 0, + 'aria-disabled': 0, // state + 'aria-hidden': 0, // state + 'aria-invalid': 0, // state + 'aria-keyshortcuts': 0, + 'aria-label': 0, + 'aria-roledescription': 0, + // Widget Attributes + 'aria-autocomplete': 0, + 'aria-checked': 0, + 'aria-expanded': 0, + 'aria-haspopup': 0, + 'aria-level': 0, + 'aria-modal': 0, + 'aria-multiline': 0, + 'aria-multiselectable': 0, + 'aria-orientation': 0, + 'aria-placeholder': 0, + 'aria-pressed': 0, + 'aria-readonly': 0, + 'aria-required': 0, + 'aria-selected': 0, + 'aria-sort': 0, + 'aria-valuemax': 0, + 'aria-valuemin': 0, + 'aria-valuenow': 0, + 'aria-valuetext': 0, + // Live Region Attributes + 'aria-atomic': 0, + 'aria-busy': 0, + 'aria-live': 0, + 'aria-relevant': 0, + // Drag-and-Drop Attributes + 'aria-dropeffect': 0, + 'aria-grabbed': 0, + // Relationship Attributes + 'aria-activedescendant': 0, + 'aria-colcount': 0, + 'aria-colindex': 0, + 'aria-colspan': 0, + 'aria-controls': 0, + 'aria-describedby': 0, + 'aria-errormessage': 0, + 'aria-flowto': 0, + 'aria-labelledby': 0, + 'aria-owns': 0, + 'aria-posinset': 0, + 'aria-rowcount': 0, + 'aria-rowindex': 0, + 'aria-rowspan': 0, + 'aria-setsize': 0 + }, + DOMAttributeNames: {}, + DOMPropertyNames: {} +}; + +module.exports = ARIADOMPropertyConfig; + +/***/ }), +/* 233 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var FallbackCompositionState = __webpack_require__(234); +var SyntheticCompositionEvent = __webpack_require__(235); +var SyntheticInputEvent = __webpack_require__(236); + +var END_KEYCODES = [9, 13, 27, 32]; // Tab, Return, Esc, Space +var START_KEYCODE = 229; + +var canUseCompositionEvent = ExecutionEnvironment.canUseDOM && 'CompositionEvent' in window; + +var documentMode = null; +if (ExecutionEnvironment.canUseDOM && 'documentMode' in document) { + documentMode = document.documentMode; +} + +// Webkit offers a very useful `textInput` event that can be used to +// directly represent `beforeInput`. The IE `textinput` event is not as +// useful, so we don't use it. +var canUseTextInputEvent = ExecutionEnvironment.canUseDOM && 'TextEvent' in window && !documentMode && !isPresto(); + +// In IE9+, we have access to composition events, but the data supplied +// by the native compositionend event may be incorrect. Japanese ideographic +// spaces, for instance (\u3000) are not recorded correctly. +var useFallbackCompositionData = ExecutionEnvironment.canUseDOM && (!canUseCompositionEvent || documentMode && documentMode > 8 && documentMode <= 11); + +/** + * Opera <= 12 includes TextEvent in window, but does not fire + * text input events. Rely on keypress instead. + */ +function isPresto() { + var opera = window.opera; + return typeof opera === 'object' && typeof opera.version === 'function' && parseInt(opera.version(), 10) <= 12; +} + +var SPACEBAR_CODE = 32; +var SPACEBAR_CHAR = String.fromCharCode(SPACEBAR_CODE); + +// Events and their corresponding property names. +var eventTypes = { + beforeInput: { + phasedRegistrationNames: { + bubbled: 'onBeforeInput', + captured: 'onBeforeInputCapture' + }, + dependencies: ['topCompositionEnd', 'topKeyPress', 'topTextInput', 'topPaste'] + }, + compositionEnd: { + phasedRegistrationNames: { + bubbled: 'onCompositionEnd', + captured: 'onCompositionEndCapture' + }, + dependencies: ['topBlur', 'topCompositionEnd', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + }, + compositionStart: { + phasedRegistrationNames: { + bubbled: 'onCompositionStart', + captured: 'onCompositionStartCapture' + }, + dependencies: ['topBlur', 'topCompositionStart', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + }, + compositionUpdate: { + phasedRegistrationNames: { + bubbled: 'onCompositionUpdate', + captured: 'onCompositionUpdateCapture' + }, + dependencies: ['topBlur', 'topCompositionUpdate', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + } +}; + +// Track whether we've ever handled a keypress on the space key. +var hasSpaceKeypress = false; + +/** + * Return whether a native keypress event is assumed to be a command. + * This is required because Firefox fires `keypress` events for key commands + * (cut, copy, select-all, etc.) even though no character is inserted. + */ +function isKeypressCommand(nativeEvent) { + return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) && + // ctrlKey && altKey is equivalent to AltGr, and is not a command. + !(nativeEvent.ctrlKey && nativeEvent.altKey); +} + +/** + * Translate native top level events into event types. + * + * @param {string} topLevelType + * @return {object} + */ +function getCompositionEventType(topLevelType) { + switch (topLevelType) { + case 'topCompositionStart': + return eventTypes.compositionStart; + case 'topCompositionEnd': + return eventTypes.compositionEnd; + case 'topCompositionUpdate': + return eventTypes.compositionUpdate; + } +} + +/** + * Does our fallback best-guess model think this event signifies that + * composition has begun? + * + * @param {string} topLevelType + * @param {object} nativeEvent + * @return {boolean} + */ +function isFallbackCompositionStart(topLevelType, nativeEvent) { + return topLevelType === 'topKeyDown' && nativeEvent.keyCode === START_KEYCODE; +} + +/** + * Does our fallback mode think that this event is the end of composition? + * + * @param {string} topLevelType + * @param {object} nativeEvent + * @return {boolean} + */ +function isFallbackCompositionEnd(topLevelType, nativeEvent) { + switch (topLevelType) { + case 'topKeyUp': + // Command keys insert or clear IME input. + return END_KEYCODES.indexOf(nativeEvent.keyCode) !== -1; + case 'topKeyDown': + // Expect IME keyCode on each keydown. If we get any other + // code we must have exited earlier. + return nativeEvent.keyCode !== START_KEYCODE; + case 'topKeyPress': + case 'topMouseDown': + case 'topBlur': + // Events are not possible without cancelling IME. + return true; + default: + return false; + } +} + +/** + * Google Input Tools provides composition data via a CustomEvent, + * with the `data` property populated in the `detail` object. If this + * is available on the event object, use it. If not, this is a plain + * composition event and we have nothing special to extract. + * + * @param {object} nativeEvent + * @return {?string} + */ +function getDataFromCustomEvent(nativeEvent) { + var detail = nativeEvent.detail; + if (typeof detail === 'object' && 'data' in detail) { + return detail.data; + } + return null; +} + +// Track the current IME composition fallback object, if any. +var currentComposition = null; + +/** + * @return {?object} A SyntheticCompositionEvent. + */ +function extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var eventType; + var fallbackData; + + if (canUseCompositionEvent) { + eventType = getCompositionEventType(topLevelType); + } else if (!currentComposition) { + if (isFallbackCompositionStart(topLevelType, nativeEvent)) { + eventType = eventTypes.compositionStart; + } + } else if (isFallbackCompositionEnd(topLevelType, nativeEvent)) { + eventType = eventTypes.compositionEnd; + } + + if (!eventType) { + return null; + } + + if (useFallbackCompositionData) { + // The current composition is stored statically and must not be + // overwritten while composition continues. + if (!currentComposition && eventType === eventTypes.compositionStart) { + currentComposition = FallbackCompositionState.getPooled(nativeEventTarget); + } else if (eventType === eventTypes.compositionEnd) { + if (currentComposition) { + fallbackData = currentComposition.getData(); + } + } + } + + var event = SyntheticCompositionEvent.getPooled(eventType, targetInst, nativeEvent, nativeEventTarget); + + if (fallbackData) { + // Inject data generated from fallback path into the synthetic event. + // This matches the property of native CompositionEventInterface. + event.data = fallbackData; + } else { + var customData = getDataFromCustomEvent(nativeEvent); + if (customData !== null) { + event.data = customData; + } + } + + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} + +/** + * @param {string} topLevelType Record from `EventConstants`. + * @param {object} nativeEvent Native browser event. + * @return {?string} The string corresponding to this `beforeInput` event. + */ +function getNativeBeforeInputChars(topLevelType, nativeEvent) { + switch (topLevelType) { + case 'topCompositionEnd': + return getDataFromCustomEvent(nativeEvent); + case 'topKeyPress': + /** + * If native `textInput` events are available, our goal is to make + * use of them. However, there is a special case: the spacebar key. + * In Webkit, preventing default on a spacebar `textInput` event + * cancels character insertion, but it *also* causes the browser + * to fall back to its default spacebar behavior of scrolling the + * page. + * + * Tracking at: + * https://code.google.com/p/chromium/issues/detail?id=355103 + * + * To avoid this issue, use the keypress event as if no `textInput` + * event is available. + */ + var which = nativeEvent.which; + if (which !== SPACEBAR_CODE) { + return null; + } + + hasSpaceKeypress = true; + return SPACEBAR_CHAR; + + case 'topTextInput': + // Record the characters to be added to the DOM. + var chars = nativeEvent.data; + + // If it's a spacebar character, assume that we have already handled + // it at the keypress level and bail immediately. Android Chrome + // doesn't give us keycodes, so we need to blacklist it. + if (chars === SPACEBAR_CHAR && hasSpaceKeypress) { + return null; + } + + return chars; + + default: + // For other native event types, do nothing. + return null; + } +} + +/** + * For browsers that do not provide the `textInput` event, extract the + * appropriate string to use for SyntheticInputEvent. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {object} nativeEvent Native browser event. + * @return {?string} The fallback string for this `beforeInput` event. + */ +function getFallbackBeforeInputChars(topLevelType, nativeEvent) { + // If we are currently composing (IME) and using a fallback to do so, + // try to extract the composed characters from the fallback object. + // If composition event is available, we extract a string only at + // compositionevent, otherwise extract it at fallback events. + if (currentComposition) { + if (topLevelType === 'topCompositionEnd' || !canUseCompositionEvent && isFallbackCompositionEnd(topLevelType, nativeEvent)) { + var chars = currentComposition.getData(); + FallbackCompositionState.release(currentComposition); + currentComposition = null; + return chars; + } + return null; + } + + switch (topLevelType) { + case 'topPaste': + // If a paste event occurs after a keypress, throw out the input + // chars. Paste events should not lead to BeforeInput events. + return null; + case 'topKeyPress': + /** + * As of v27, Firefox may fire keypress events even when no character + * will be inserted. A few possibilities: + * + * - `which` is `0`. Arrow keys, Esc key, etc. + * + * - `which` is the pressed key code, but no char is available. + * Ex: 'AltGr + d` in Polish. There is no modified character for + * this key combination and no character is inserted into the + * document, but FF fires the keypress for char code `100` anyway. + * No `input` event will occur. + * + * - `which` is the pressed key code, but a command combination is + * being used. Ex: `Cmd+C`. No character is inserted, and no + * `input` event will occur. + */ + if (nativeEvent.which && !isKeypressCommand(nativeEvent)) { + return String.fromCharCode(nativeEvent.which); + } + return null; + case 'topCompositionEnd': + return useFallbackCompositionData ? null : nativeEvent.data; + default: + return null; + } +} + +/** + * Extract a SyntheticInputEvent for `beforeInput`, based on either native + * `textInput` or fallback behavior. + * + * @return {?object} A SyntheticInputEvent. + */ +function extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var chars; + + if (canUseTextInputEvent) { + chars = getNativeBeforeInputChars(topLevelType, nativeEvent); + } else { + chars = getFallbackBeforeInputChars(topLevelType, nativeEvent); + } + + // If no characters are being inserted, no BeforeInput event should + // be fired. + if (!chars) { + return null; + } + + var event = SyntheticInputEvent.getPooled(eventTypes.beforeInput, targetInst, nativeEvent, nativeEventTarget); + + event.data = chars; + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} + +/** + * Create an `onBeforeInput` event to match + * http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105/#events-inputevents. + * + * This event plugin is based on the native `textInput` event + * available in Chrome, Safari, Opera, and IE. This event fires after + * `onKeyPress` and `onCompositionEnd`, but before `onInput`. + * + * `beforeInput` is spec'd but not implemented in any browsers, and + * the `input` event does not provide any useful information about what has + * actually been added, contrary to the spec. Thus, `textInput` is the best + * available event to identify the characters that have actually been inserted + * into the target node. + * + * This plugin is also responsible for emitting `composition` events, thus + * allowing us to share composition fallback code for both `beforeInput` and + * `composition` event types. + */ +var BeforeInputEventPlugin = { + eventTypes: eventTypes, + + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + return [extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget), extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget)]; + } +}; + +module.exports = BeforeInputEventPlugin; + +/***/ }), +/* 234 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var PooledClass = __webpack_require__(32); + +var getTextContentAccessor = __webpack_require__(129); + +/** + * This helper class stores information about text content of a target node, + * allowing comparison of content before and after a given event. + * + * Identify the node where selection currently begins, then observe + * both its text content and its current position in the DOM. Since the + * browser may natively replace the target node during composition, we can + * use its position to find its replacement. + * + * @param {DOMEventTarget} root + */ +function FallbackCompositionState(root) { + this._root = root; + this._startText = this.getText(); + this._fallbackText = null; +} + +_assign(FallbackCompositionState.prototype, { + destructor: function () { + this._root = null; + this._startText = null; + this._fallbackText = null; + }, + + /** + * Get current text of input. + * + * @return {string} + */ + getText: function () { + if ('value' in this._root) { + return this._root.value; + } + return this._root[getTextContentAccessor()]; + }, + + /** + * Determine the differing substring between the initially stored + * text content and the current content. + * + * @return {string} + */ + getData: function () { + if (this._fallbackText) { + return this._fallbackText; + } + + var start; + var startValue = this._startText; + var startLength = startValue.length; + var end; + var endValue = this.getText(); + var endLength = endValue.length; + + for (start = 0; start < startLength; start++) { + if (startValue[start] !== endValue[start]) { + break; + } + } + + var minEnd = startLength - start; + for (end = 1; end <= minEnd; end++) { + if (startValue[startLength - end] !== endValue[endLength - end]) { + break; + } + } + + var sliceTail = end > 1 ? 1 - end : undefined; + this._fallbackText = endValue.slice(start, sliceTail); + return this._fallbackText; + } +}); + +PooledClass.addPoolingTo(FallbackCompositionState); + +module.exports = FallbackCompositionState; + +/***/ }), +/* 235 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/DOM-Level-3-Events/#events-compositionevents + */ +var CompositionEventInterface = { + data: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticCompositionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticCompositionEvent, CompositionEventInterface); + +module.exports = SyntheticCompositionEvent; + +/***/ }), +/* 236 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105 + * /#events-inputevents + */ +var InputEventInterface = { + data: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticInputEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticInputEvent, InputEventInterface); + +module.exports = SyntheticInputEvent; + +/***/ }), +/* 237 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPluginHub = __webpack_require__(46); +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); +var SyntheticEvent = __webpack_require__(26); + +var inputValueTracking = __webpack_require__(132); +var getEventTarget = __webpack_require__(79); +var isEventSupported = __webpack_require__(80); +var isTextInputElement = __webpack_require__(133); + +var eventTypes = { + change: { + phasedRegistrationNames: { + bubbled: 'onChange', + captured: 'onChangeCapture' + }, + dependencies: ['topBlur', 'topChange', 'topClick', 'topFocus', 'topInput', 'topKeyDown', 'topKeyUp', 'topSelectionChange'] + } +}; + +function createAndAccumulateChangeEvent(inst, nativeEvent, target) { + var event = SyntheticEvent.getPooled(eventTypes.change, inst, nativeEvent, target); + event.type = 'change'; + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} +/** + * For IE shims + */ +var activeElement = null; +var activeElementInst = null; + +/** + * SECTION: handle `change` event + */ +function shouldUseChangeEvent(elem) { + var nodeName = elem.nodeName && elem.nodeName.toLowerCase(); + return nodeName === 'select' || nodeName === 'input' && elem.type === 'file'; +} + +var doesChangeEventBubble = false; +if (ExecutionEnvironment.canUseDOM) { + // See `handleChange` comment below + doesChangeEventBubble = isEventSupported('change') && (!document.documentMode || document.documentMode > 8); +} + +function manualDispatchChangeEvent(nativeEvent) { + var event = createAndAccumulateChangeEvent(activeElementInst, nativeEvent, getEventTarget(nativeEvent)); + + // If change and propertychange bubbled, we'd just bind to it like all the + // other events and have it go through ReactBrowserEventEmitter. Since it + // doesn't, we manually listen for the events and so we have to enqueue and + // process the abstract event manually. + // + // Batching is necessary here in order to ensure that all event handlers run + // before the next rerender (including event handlers attached to ancestor + // elements instead of directly on the input). Without this, controlled + // components don't work properly in conjunction with event bubbling because + // the component is rerendered and the value reverted before all the event + // handlers can run. See https://github.com/facebook/react/issues/708. + ReactUpdates.batchedUpdates(runEventInBatch, event); +} + +function runEventInBatch(event) { + EventPluginHub.enqueueEvents(event); + EventPluginHub.processEventQueue(false); +} + +function startWatchingForChangeEventIE8(target, targetInst) { + activeElement = target; + activeElementInst = targetInst; + activeElement.attachEvent('onchange', manualDispatchChangeEvent); +} + +function stopWatchingForChangeEventIE8() { + if (!activeElement) { + return; + } + activeElement.detachEvent('onchange', manualDispatchChangeEvent); + activeElement = null; + activeElementInst = null; +} + +function getInstIfValueChanged(targetInst, nativeEvent) { + var updated = inputValueTracking.updateValueIfChanged(targetInst); + var simulated = nativeEvent.simulated === true && ChangeEventPlugin._allowSimulatedPassThrough; + + if (updated || simulated) { + return targetInst; + } +} + +function getTargetInstForChangeEvent(topLevelType, targetInst) { + if (topLevelType === 'topChange') { + return targetInst; + } +} + +function handleEventsForChangeEventIE8(topLevelType, target, targetInst) { + if (topLevelType === 'topFocus') { + // stopWatching() should be a noop here but we call it just in case we + // missed a blur event somehow. + stopWatchingForChangeEventIE8(); + startWatchingForChangeEventIE8(target, targetInst); + } else if (topLevelType === 'topBlur') { + stopWatchingForChangeEventIE8(); + } +} + +/** + * SECTION: handle `input` event + */ +var isInputEventSupported = false; +if (ExecutionEnvironment.canUseDOM) { + // IE9 claims to support the input event but fails to trigger it when + // deleting text, so we ignore its input events. + + isInputEventSupported = isEventSupported('input') && (!('documentMode' in document) || document.documentMode > 9); +} + +/** + * (For IE <=9) Starts tracking propertychange events on the passed-in element + * and override the value property so that we can distinguish user events from + * value changes in JS. + */ +function startWatchingForValueChange(target, targetInst) { + activeElement = target; + activeElementInst = targetInst; + activeElement.attachEvent('onpropertychange', handlePropertyChange); +} + +/** + * (For IE <=9) Removes the event listeners from the currently-tracked element, + * if any exists. + */ +function stopWatchingForValueChange() { + if (!activeElement) { + return; + } + activeElement.detachEvent('onpropertychange', handlePropertyChange); + + activeElement = null; + activeElementInst = null; +} + +/** + * (For IE <=9) Handles a propertychange event, sending a `change` event if + * the value of the active element has changed. + */ +function handlePropertyChange(nativeEvent) { + if (nativeEvent.propertyName !== 'value') { + return; + } + if (getInstIfValueChanged(activeElementInst, nativeEvent)) { + manualDispatchChangeEvent(nativeEvent); + } +} + +function handleEventsForInputEventPolyfill(topLevelType, target, targetInst) { + if (topLevelType === 'topFocus') { + // In IE8, we can capture almost all .value changes by adding a + // propertychange handler and looking for events with propertyName + // equal to 'value' + // In IE9, propertychange fires for most input events but is buggy and + // doesn't fire when text is deleted, but conveniently, selectionchange + // appears to fire in all of the remaining cases so we catch those and + // forward the event if the value has changed + // In either case, we don't want to call the event handler if the value + // is changed from JS so we redefine a setter for `.value` that updates + // our activeElementValue variable, allowing us to ignore those changes + // + // stopWatching() should be a noop here but we call it just in case we + // missed a blur event somehow. + stopWatchingForValueChange(); + startWatchingForValueChange(target, targetInst); + } else if (topLevelType === 'topBlur') { + stopWatchingForValueChange(); + } +} + +// For IE8 and IE9. +function getTargetInstForInputEventPolyfill(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topSelectionChange' || topLevelType === 'topKeyUp' || topLevelType === 'topKeyDown') { + // On the selectionchange event, the target is just document which isn't + // helpful for us so just check activeElement instead. + // + // 99% of the time, keydown and keyup aren't necessary. IE8 fails to fire + // propertychange on the first input event after setting `value` from a + // script and fires only keydown, keypress, keyup. Catching keyup usually + // gets it and catching keydown lets us fire an event for the first + // keystroke if user does a key repeat (it'll be a little delayed: right + // before the second keystroke). Other input methods (e.g., paste) seem to + // fire selectionchange normally. + return getInstIfValueChanged(activeElementInst, nativeEvent); + } +} + +/** + * SECTION: handle `click` event + */ +function shouldUseClickEvent(elem) { + // Use the `click` event to detect changes to checkbox and radio inputs. + // This approach works across all browsers, whereas `change` does not fire + // until `blur` in IE8. + var nodeName = elem.nodeName; + return nodeName && nodeName.toLowerCase() === 'input' && (elem.type === 'checkbox' || elem.type === 'radio'); +} + +function getTargetInstForClickEvent(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topClick') { + return getInstIfValueChanged(targetInst, nativeEvent); + } +} + +function getTargetInstForInputOrChangeEvent(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topInput' || topLevelType === 'topChange') { + return getInstIfValueChanged(targetInst, nativeEvent); + } +} + +function handleControlledInputBlur(inst, node) { + // TODO: In IE, inst is occasionally null. Why? + if (inst == null) { + return; + } + + // Fiber and ReactDOM keep wrapper state in separate places + var state = inst._wrapperState || node._wrapperState; + + if (!state || !state.controlled || node.type !== 'number') { + return; + } + + // If controlled, assign the value attribute to the current value on blur + var value = '' + node.value; + if (node.getAttribute('value') !== value) { + node.setAttribute('value', value); + } +} + +/** + * This plugin creates an `onChange` event that normalizes change events + * across form elements. This event fires at a time when it's possible to + * change the element's value without seeing a flicker. + * + * Supported elements are: + * - input (see `isTextInputElement`) + * - textarea + * - select + */ +var ChangeEventPlugin = { + eventTypes: eventTypes, + + _allowSimulatedPassThrough: true, + _isInputEventSupported: isInputEventSupported, + + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; + + var getTargetInstFunc, handleEventFunc; + if (shouldUseChangeEvent(targetNode)) { + if (doesChangeEventBubble) { + getTargetInstFunc = getTargetInstForChangeEvent; + } else { + handleEventFunc = handleEventsForChangeEventIE8; + } + } else if (isTextInputElement(targetNode)) { + if (isInputEventSupported) { + getTargetInstFunc = getTargetInstForInputOrChangeEvent; + } else { + getTargetInstFunc = getTargetInstForInputEventPolyfill; + handleEventFunc = handleEventsForInputEventPolyfill; + } + } else if (shouldUseClickEvent(targetNode)) { + getTargetInstFunc = getTargetInstForClickEvent; + } + + if (getTargetInstFunc) { + var inst = getTargetInstFunc(topLevelType, targetInst, nativeEvent); + if (inst) { + var event = createAndAccumulateChangeEvent(inst, nativeEvent, nativeEventTarget); + return event; + } + } + + if (handleEventFunc) { + handleEventFunc(topLevelType, targetNode, targetInst); + } + + // When blurring, set the value attribute for number inputs + if (topLevelType === 'topBlur') { + handleControlledInputBlur(targetInst, targetNode); + } + } +}; + +module.exports = ChangeEventPlugin; + +/***/ }), +/* 238 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactOwner = __webpack_require__(239); + +var ReactRef = {}; + +function attachRef(ref, component, owner) { + if (typeof ref === 'function') { + ref(component.getPublicInstance()); + } else { + // Legacy ref + ReactOwner.addComponentAsRefTo(component, ref, owner); + } +} + +function detachRef(ref, component, owner) { + if (typeof ref === 'function') { + ref(null); + } else { + // Legacy ref + ReactOwner.removeComponentAsRefFrom(component, ref, owner); + } +} + +ReactRef.attachRefs = function (instance, element) { + if (element === null || typeof element !== 'object') { + return; + } + var ref = element.ref; + if (ref != null) { + attachRef(ref, instance, element._owner); + } +}; + +ReactRef.shouldUpdateRefs = function (prevElement, nextElement) { + // If either the owner or a `ref` has changed, make sure the newest owner + // has stored a reference to `this`, and the previous owner (if different) + // has forgotten the reference to `this`. We use the element instead + // of the public this.props because the post processing cannot determine + // a ref. The ref conceptually lives on the element. + + // TODO: Should this even be possible? The owner cannot change because + // it's forbidden by shouldUpdateReactComponent. The ref can change + // if you swap the keys of but not the refs. Reconsider where this check + // is made. It probably belongs where the key checking and + // instantiateReactComponent is done. + + var prevRef = null; + var prevOwner = null; + if (prevElement !== null && typeof prevElement === 'object') { + prevRef = prevElement.ref; + prevOwner = prevElement._owner; + } + + var nextRef = null; + var nextOwner = null; + if (nextElement !== null && typeof nextElement === 'object') { + nextRef = nextElement.ref; + nextOwner = nextElement._owner; + } + + return prevRef !== nextRef || + // If owner changes but we have an unchanged function ref, don't update refs + typeof nextRef === 'string' && nextOwner !== prevOwner; +}; + +ReactRef.detachRefs = function (instance, element) { + if (element === null || typeof element !== 'object') { + return; + } + var ref = element.ref; + if (ref != null) { + detachRef(ref, instance, element._owner); + } +}; + +module.exports = ReactRef; + +/***/ }), +/* 239 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +/** + * @param {?object} object + * @return {boolean} True if `object` is a valid owner. + * @final + */ +function isValidOwner(object) { + return !!(object && typeof object.attachRef === 'function' && typeof object.detachRef === 'function'); +} + +/** + * ReactOwners are capable of storing references to owned components. + * + * All components are capable of //being// referenced by owner components, but + * only ReactOwner components are capable of //referencing// owned components. + * The named reference is known as a "ref". + * + * Refs are available when mounted and updated during reconciliation. + * + * var MyComponent = React.createClass({ + * render: function() { + * return ( + * <div onClick={this.handleClick}> + * <CustomComponent ref="custom" /> + * </div> + * ); + * }, + * handleClick: function() { + * this.refs.custom.handleClick(); + * }, + * componentDidMount: function() { + * this.refs.custom.initialize(); + * } + * }); + * + * Refs should rarely be used. When refs are used, they should only be done to + * control data that is not handled by React's data flow. + * + * @class ReactOwner + */ +var ReactOwner = { + /** + * Adds a component by ref to an owner component. + * + * @param {ReactComponent} component Component to reference. + * @param {string} ref Name by which to refer to the component. + * @param {ReactOwner} owner Component on which to record the ref. + * @final + * @internal + */ + addComponentAsRefTo: function (component, ref, owner) { + !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('119') : void 0; + owner.attachRef(ref, component); + }, + + /** + * Removes a component by ref from an owner component. + * + * @param {ReactComponent} component Component to dereference. + * @param {string} ref Name of the ref to remove. + * @param {ReactOwner} owner Component on which the ref is recorded. + * @final + * @internal + */ + removeComponentAsRefFrom: function (component, ref, owner) { + !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'removeComponentAsRefFrom(...): Only a ReactOwner can have refs. You might be removing a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('120') : void 0; + var ownerPublicInstance = owner.getPublicInstance(); + // Check that `component`'s owner is still alive and that `component` is still the current ref + // because we do not want to detach the ref if another component stole it. + if (ownerPublicInstance && ownerPublicInstance.refs[ref] === component.getPublicInstance()) { + owner.detachRef(ref); + } + } +}; + +module.exports = ReactOwner; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 240 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactInvalidSetStateWarningHook = __webpack_require__(241); +var ReactHostOperationHistoryHook = __webpack_require__(242); +var ReactComponentTreeHook = __webpack_require__(17); +var ExecutionEnvironment = __webpack_require__(13); + +var performanceNow = __webpack_require__(243); +var warning = __webpack_require__(3); + +var hooks = []; +var didHookThrowForEvent = {}; + +function callHook(event, fn, context, arg1, arg2, arg3, arg4, arg5) { + try { + fn.call(context, arg1, arg2, arg3, arg4, arg5); + } catch (e) { + process.env.NODE_ENV !== 'production' ? warning(didHookThrowForEvent[event], 'Exception thrown by hook while handling %s: %s', event, e + '\n' + e.stack) : void 0; + didHookThrowForEvent[event] = true; + } +} + +function emitEvent(event, arg1, arg2, arg3, arg4, arg5) { + for (var i = 0; i < hooks.length; i++) { + var hook = hooks[i]; + var fn = hook[event]; + if (fn) { + callHook(event, fn, hook, arg1, arg2, arg3, arg4, arg5); + } + } +} + +var isProfiling = false; +var flushHistory = []; +var lifeCycleTimerStack = []; +var currentFlushNesting = 0; +var currentFlushMeasurements = []; +var currentFlushStartTime = 0; +var currentTimerDebugID = null; +var currentTimerStartTime = 0; +var currentTimerNestedFlushDuration = 0; +var currentTimerType = null; + +var lifeCycleTimerHasWarned = false; + +function clearHistory() { + ReactComponentTreeHook.purgeUnmountedComponents(); + ReactHostOperationHistoryHook.clearHistory(); +} + +function getTreeSnapshot(registeredIDs) { + return registeredIDs.reduce(function (tree, id) { + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var parentID = ReactComponentTreeHook.getParentID(id); + tree[id] = { + displayName: ReactComponentTreeHook.getDisplayName(id), + text: ReactComponentTreeHook.getText(id), + updateCount: ReactComponentTreeHook.getUpdateCount(id), + childIDs: ReactComponentTreeHook.getChildIDs(id), + // Text nodes don't have owners but this is close enough. + ownerID: ownerID || parentID && ReactComponentTreeHook.getOwnerID(parentID) || 0, + parentID: parentID + }; + return tree; + }, {}); +} + +function resetMeasurements() { + var previousStartTime = currentFlushStartTime; + var previousMeasurements = currentFlushMeasurements; + var previousOperations = ReactHostOperationHistoryHook.getHistory(); + + if (currentFlushNesting === 0) { + currentFlushStartTime = 0; + currentFlushMeasurements = []; + clearHistory(); + return; + } + + if (previousMeasurements.length || previousOperations.length) { + var registeredIDs = ReactComponentTreeHook.getRegisteredIDs(); + flushHistory.push({ + duration: performanceNow() - previousStartTime, + measurements: previousMeasurements || [], + operations: previousOperations || [], + treeSnapshot: getTreeSnapshot(registeredIDs) + }); + } + + clearHistory(); + currentFlushStartTime = performanceNow(); + currentFlushMeasurements = []; +} + +function checkDebugID(debugID) { + var allowRoot = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; + + if (allowRoot && debugID === 0) { + return; + } + if (!debugID) { + process.env.NODE_ENV !== 'production' ? warning(false, 'ReactDebugTool: debugID may not be empty.') : void 0; + } +} + +function beginLifeCycleTimer(debugID, timerType) { + if (currentFlushNesting === 0) { + return; + } + if (currentTimerType && !lifeCycleTimerHasWarned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'Did not expect %s timer to start while %s timer is still in ' + 'progress for %s instance.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; + lifeCycleTimerHasWarned = true; + } + currentTimerStartTime = performanceNow(); + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = debugID; + currentTimerType = timerType; +} + +function endLifeCycleTimer(debugID, timerType) { + if (currentFlushNesting === 0) { + return; + } + if (currentTimerType !== timerType && !lifeCycleTimerHasWarned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'We did not expect %s timer to stop while %s timer is still in ' + 'progress for %s instance. Please report this as a bug in React.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; + lifeCycleTimerHasWarned = true; + } + if (isProfiling) { + currentFlushMeasurements.push({ + timerType: timerType, + instanceID: debugID, + duration: performanceNow() - currentTimerStartTime - currentTimerNestedFlushDuration + }); + } + currentTimerStartTime = 0; + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = null; + currentTimerType = null; +} + +function pauseCurrentLifeCycleTimer() { + var currentTimer = { + startTime: currentTimerStartTime, + nestedFlushStartTime: performanceNow(), + debugID: currentTimerDebugID, + timerType: currentTimerType + }; + lifeCycleTimerStack.push(currentTimer); + currentTimerStartTime = 0; + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = null; + currentTimerType = null; +} + +function resumeCurrentLifeCycleTimer() { + var _lifeCycleTimerStack$ = lifeCycleTimerStack.pop(), + startTime = _lifeCycleTimerStack$.startTime, + nestedFlushStartTime = _lifeCycleTimerStack$.nestedFlushStartTime, + debugID = _lifeCycleTimerStack$.debugID, + timerType = _lifeCycleTimerStack$.timerType; + + var nestedFlushDuration = performanceNow() - nestedFlushStartTime; + currentTimerStartTime = startTime; + currentTimerNestedFlushDuration += nestedFlushDuration; + currentTimerDebugID = debugID; + currentTimerType = timerType; +} + +var lastMarkTimeStamp = 0; +var canUsePerformanceMeasure = typeof performance !== 'undefined' && typeof performance.mark === 'function' && typeof performance.clearMarks === 'function' && typeof performance.measure === 'function' && typeof performance.clearMeasures === 'function'; + +function shouldMark(debugID) { + if (!isProfiling || !canUsePerformanceMeasure) { + return false; + } + var element = ReactComponentTreeHook.getElement(debugID); + if (element == null || typeof element !== 'object') { + return false; + } + var isHostElement = typeof element.type === 'string'; + if (isHostElement) { + return false; + } + return true; +} + +function markBegin(debugID, markType) { + if (!shouldMark(debugID)) { + return; + } + + var markName = debugID + '::' + markType; + lastMarkTimeStamp = performanceNow(); + performance.mark(markName); +} + +function markEnd(debugID, markType) { + if (!shouldMark(debugID)) { + return; + } + + var markName = debugID + '::' + markType; + var displayName = ReactComponentTreeHook.getDisplayName(debugID) || 'Unknown'; + + // Chrome has an issue of dropping markers recorded too fast: + // https://bugs.chromium.org/p/chromium/issues/detail?id=640652 + // To work around this, we will not report very small measurements. + // I determined the magic number by tweaking it back and forth. + // 0.05ms was enough to prevent the issue, but I set it to 0.1ms to be safe. + // When the bug is fixed, we can `measure()` unconditionally if we want to. + var timeStamp = performanceNow(); + if (timeStamp - lastMarkTimeStamp > 0.1) { + var measurementName = displayName + ' [' + markType + ']'; + performance.measure(measurementName, markName); + } + + performance.clearMarks(markName); + if (measurementName) { + performance.clearMeasures(measurementName); + } +} + +var ReactDebugTool = { + addHook: function (hook) { + hooks.push(hook); + }, + removeHook: function (hook) { + for (var i = 0; i < hooks.length; i++) { + if (hooks[i] === hook) { + hooks.splice(i, 1); + i--; + } + } + }, + isProfiling: function () { + return isProfiling; + }, + beginProfiling: function () { + if (isProfiling) { + return; + } + + isProfiling = true; + flushHistory.length = 0; + resetMeasurements(); + ReactDebugTool.addHook(ReactHostOperationHistoryHook); + }, + endProfiling: function () { + if (!isProfiling) { + return; + } + + isProfiling = false; + resetMeasurements(); + ReactDebugTool.removeHook(ReactHostOperationHistoryHook); + }, + getFlushHistory: function () { + return flushHistory; + }, + onBeginFlush: function () { + currentFlushNesting++; + resetMeasurements(); + pauseCurrentLifeCycleTimer(); + emitEvent('onBeginFlush'); + }, + onEndFlush: function () { + resetMeasurements(); + currentFlushNesting--; + resumeCurrentLifeCycleTimer(); + emitEvent('onEndFlush'); + }, + onBeginLifeCycleTimer: function (debugID, timerType) { + checkDebugID(debugID); + emitEvent('onBeginLifeCycleTimer', debugID, timerType); + markBegin(debugID, timerType); + beginLifeCycleTimer(debugID, timerType); + }, + onEndLifeCycleTimer: function (debugID, timerType) { + checkDebugID(debugID); + endLifeCycleTimer(debugID, timerType); + markEnd(debugID, timerType); + emitEvent('onEndLifeCycleTimer', debugID, timerType); + }, + onBeginProcessingChildContext: function () { + emitEvent('onBeginProcessingChildContext'); + }, + onEndProcessingChildContext: function () { + emitEvent('onEndProcessingChildContext'); + }, + onHostOperation: function (operation) { + checkDebugID(operation.instanceID); + emitEvent('onHostOperation', operation); + }, + onSetState: function () { + emitEvent('onSetState'); + }, + onSetChildren: function (debugID, childDebugIDs) { + checkDebugID(debugID); + childDebugIDs.forEach(checkDebugID); + emitEvent('onSetChildren', debugID, childDebugIDs); + }, + onBeforeMountComponent: function (debugID, element, parentDebugID) { + checkDebugID(debugID); + checkDebugID(parentDebugID, true); + emitEvent('onBeforeMountComponent', debugID, element, parentDebugID); + markBegin(debugID, 'mount'); + }, + onMountComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'mount'); + emitEvent('onMountComponent', debugID); + }, + onBeforeUpdateComponent: function (debugID, element) { + checkDebugID(debugID); + emitEvent('onBeforeUpdateComponent', debugID, element); + markBegin(debugID, 'update'); + }, + onUpdateComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'update'); + emitEvent('onUpdateComponent', debugID); + }, + onBeforeUnmountComponent: function (debugID) { + checkDebugID(debugID); + emitEvent('onBeforeUnmountComponent', debugID); + markBegin(debugID, 'unmount'); + }, + onUnmountComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'unmount'); + emitEvent('onUnmountComponent', debugID); + }, + onTestEvent: function () { + emitEvent('onTestEvent'); + } +}; + +// TODO remove these when RN/www gets updated +ReactDebugTool.addDevtool = ReactDebugTool.addHook; +ReactDebugTool.removeDevtool = ReactDebugTool.removeHook; + +ReactDebugTool.addHook(ReactInvalidSetStateWarningHook); +ReactDebugTool.addHook(ReactComponentTreeHook); +var url = ExecutionEnvironment.canUseDOM && window.location.href || ''; +if (/[?&]react_perf\b/.test(url)) { + ReactDebugTool.beginProfiling(); +} + +module.exports = ReactDebugTool; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 241 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var warning = __webpack_require__(3); + +if (process.env.NODE_ENV !== 'production') { + var processingChildContext = false; + + var warnInvalidSetState = function () { + process.env.NODE_ENV !== 'production' ? warning(!processingChildContext, 'setState(...): Cannot call setState() inside getChildContext()') : void 0; + }; +} + +var ReactInvalidSetStateWarningHook = { + onBeginProcessingChildContext: function () { + processingChildContext = true; + }, + onEndProcessingChildContext: function () { + processingChildContext = false; + }, + onSetState: function () { + warnInvalidSetState(); + } +}; + +module.exports = ReactInvalidSetStateWarningHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 242 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var history = []; + +var ReactHostOperationHistoryHook = { + onHostOperation: function (operation) { + history.push(operation); + }, + clearHistory: function () { + if (ReactHostOperationHistoryHook._preventClearing) { + // Should only be used for tests. + return; + } + + history = []; + }, + getHistory: function () { + return history; + } +}; + +module.exports = ReactHostOperationHistoryHook; + +/***/ }), +/* 243 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var performance = __webpack_require__(244); + +var performanceNow; + +/** + * Detect if we can use `window.performance.now()` and gracefully fallback to + * `Date.now()` if it doesn't exist. We need to support Firefox < 15 for now + * because of Facebook's testing infrastructure. + */ +if (performance.now) { + performanceNow = function performanceNow() { + return performance.now(); + }; +} else { + performanceNow = function performanceNow() { + return Date.now(); + }; +} + +module.exports = performanceNow; + +/***/ }), +/* 244 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +var performance; + +if (ExecutionEnvironment.canUseDOM) { + performance = window.performance || window.msPerformance || window.webkitPerformance; +} + +module.exports = performance || {}; + +/***/ }), +/* 245 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * Module that is injectable into `EventPluginHub`, that specifies a + * deterministic ordering of `EventPlugin`s. A convenient way to reason about + * plugins, without having to package every one of them. This is better than + * having plugins be ordered in the same order that they are injected because + * that ordering would be influenced by the packaging order. + * `ResponderEventPlugin` must occur before `SimpleEventPlugin` so that + * preventing default on events is convenient in `SimpleEventPlugin` handlers. + */ + +var DefaultEventPluginOrder = ['ResponderEventPlugin', 'SimpleEventPlugin', 'TapEventPlugin', 'EnterLeaveEventPlugin', 'ChangeEventPlugin', 'SelectEventPlugin', 'BeforeInputEventPlugin']; + +module.exports = DefaultEventPluginOrder; + +/***/ }), +/* 246 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPropagators = __webpack_require__(45); +var ReactDOMComponentTree = __webpack_require__(10); +var SyntheticMouseEvent = __webpack_require__(59); + +var eventTypes = { + mouseEnter: { + registrationName: 'onMouseEnter', + dependencies: ['topMouseOut', 'topMouseOver'] + }, + mouseLeave: { + registrationName: 'onMouseLeave', + dependencies: ['topMouseOut', 'topMouseOver'] + } +}; + +var EnterLeaveEventPlugin = { + eventTypes: eventTypes, + + /** + * For almost every interaction we care about, there will be both a top-level + * `mouseover` and `mouseout` event that occurs. Only use `mouseout` so that + * we do not extract duplicate events. However, moving the mouse into the + * browser from outside will not fire a `mouseout` event. In this case, we use + * the `mouseover` top-level event. + */ + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + if (topLevelType === 'topMouseOver' && (nativeEvent.relatedTarget || nativeEvent.fromElement)) { + return null; + } + if (topLevelType !== 'topMouseOut' && topLevelType !== 'topMouseOver') { + // Must not be a mouse in or mouse out - ignoring. + return null; + } + + var win; + if (nativeEventTarget.window === nativeEventTarget) { + // `nativeEventTarget` is probably a window object. + win = nativeEventTarget; + } else { + // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. + var doc = nativeEventTarget.ownerDocument; + if (doc) { + win = doc.defaultView || doc.parentWindow; + } else { + win = window; + } + } + + var from; + var to; + if (topLevelType === 'topMouseOut') { + from = targetInst; + var related = nativeEvent.relatedTarget || nativeEvent.toElement; + to = related ? ReactDOMComponentTree.getClosestInstanceFromNode(related) : null; + } else { + // Moving to a node from outside the window. + from = null; + to = targetInst; + } + + if (from === to) { + // Nothing pertains to our managed components. + return null; + } + + var fromNode = from == null ? win : ReactDOMComponentTree.getNodeFromInstance(from); + var toNode = to == null ? win : ReactDOMComponentTree.getNodeFromInstance(to); + + var leave = SyntheticMouseEvent.getPooled(eventTypes.mouseLeave, from, nativeEvent, nativeEventTarget); + leave.type = 'mouseleave'; + leave.target = fromNode; + leave.relatedTarget = toNode; + + var enter = SyntheticMouseEvent.getPooled(eventTypes.mouseEnter, to, nativeEvent, nativeEventTarget); + enter.type = 'mouseenter'; + enter.target = toNode; + enter.relatedTarget = fromNode; + + EventPropagators.accumulateEnterLeaveDispatches(leave, enter, from, to); + + return [leave, enter]; + } +}; + +module.exports = EnterLeaveEventPlugin; + +/***/ }), +/* 247 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); + +var MUST_USE_PROPERTY = DOMProperty.injection.MUST_USE_PROPERTY; +var HAS_BOOLEAN_VALUE = DOMProperty.injection.HAS_BOOLEAN_VALUE; +var HAS_NUMERIC_VALUE = DOMProperty.injection.HAS_NUMERIC_VALUE; +var HAS_POSITIVE_NUMERIC_VALUE = DOMProperty.injection.HAS_POSITIVE_NUMERIC_VALUE; +var HAS_OVERLOADED_BOOLEAN_VALUE = DOMProperty.injection.HAS_OVERLOADED_BOOLEAN_VALUE; + +var HTMLDOMPropertyConfig = { + isCustomAttribute: RegExp.prototype.test.bind(new RegExp('^(data|aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$')), + Properties: { + /** + * Standard Properties + */ + accept: 0, + acceptCharset: 0, + accessKey: 0, + action: 0, + allowFullScreen: HAS_BOOLEAN_VALUE, + allowTransparency: 0, + alt: 0, + // specifies target context for links with `preload` type + as: 0, + async: HAS_BOOLEAN_VALUE, + autoComplete: 0, + // autoFocus is polyfilled/normalized by AutoFocusUtils + // autoFocus: HAS_BOOLEAN_VALUE, + autoPlay: HAS_BOOLEAN_VALUE, + capture: HAS_BOOLEAN_VALUE, + cellPadding: 0, + cellSpacing: 0, + charSet: 0, + challenge: 0, + checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + cite: 0, + classID: 0, + className: 0, + cols: HAS_POSITIVE_NUMERIC_VALUE, + colSpan: 0, + content: 0, + contentEditable: 0, + contextMenu: 0, + controls: HAS_BOOLEAN_VALUE, + coords: 0, + crossOrigin: 0, + data: 0, // For `<object />` acts as `src`. + dateTime: 0, + 'default': HAS_BOOLEAN_VALUE, + defer: HAS_BOOLEAN_VALUE, + dir: 0, + disabled: HAS_BOOLEAN_VALUE, + download: HAS_OVERLOADED_BOOLEAN_VALUE, + draggable: 0, + encType: 0, + form: 0, + formAction: 0, + formEncType: 0, + formMethod: 0, + formNoValidate: HAS_BOOLEAN_VALUE, + formTarget: 0, + frameBorder: 0, + headers: 0, + height: 0, + hidden: HAS_BOOLEAN_VALUE, + high: 0, + href: 0, + hrefLang: 0, + htmlFor: 0, + httpEquiv: 0, + icon: 0, + id: 0, + inputMode: 0, + integrity: 0, + is: 0, + keyParams: 0, + keyType: 0, + kind: 0, + label: 0, + lang: 0, + list: 0, + loop: HAS_BOOLEAN_VALUE, + low: 0, + manifest: 0, + marginHeight: 0, + marginWidth: 0, + max: 0, + maxLength: 0, + media: 0, + mediaGroup: 0, + method: 0, + min: 0, + minLength: 0, + // Caution; `option.selected` is not updated if `select.multiple` is + // disabled with `removeAttribute`. + multiple: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + muted: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + name: 0, + nonce: 0, + noValidate: HAS_BOOLEAN_VALUE, + open: HAS_BOOLEAN_VALUE, + optimum: 0, + pattern: 0, + placeholder: 0, + playsInline: HAS_BOOLEAN_VALUE, + poster: 0, + preload: 0, + profile: 0, + radioGroup: 0, + readOnly: HAS_BOOLEAN_VALUE, + referrerPolicy: 0, + rel: 0, + required: HAS_BOOLEAN_VALUE, + reversed: HAS_BOOLEAN_VALUE, + role: 0, + rows: HAS_POSITIVE_NUMERIC_VALUE, + rowSpan: HAS_NUMERIC_VALUE, + sandbox: 0, + scope: 0, + scoped: HAS_BOOLEAN_VALUE, + scrolling: 0, + seamless: HAS_BOOLEAN_VALUE, + selected: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + shape: 0, + size: HAS_POSITIVE_NUMERIC_VALUE, + sizes: 0, + span: HAS_POSITIVE_NUMERIC_VALUE, + spellCheck: 0, + src: 0, + srcDoc: 0, + srcLang: 0, + srcSet: 0, + start: HAS_NUMERIC_VALUE, + step: 0, + style: 0, + summary: 0, + tabIndex: 0, + target: 0, + title: 0, + // Setting .type throws on non-<input> tags + type: 0, + useMap: 0, + value: 0, + width: 0, + wmode: 0, + wrap: 0, + + /** + * RDFa Properties + */ + about: 0, + datatype: 0, + inlist: 0, + prefix: 0, + // property is also supported for OpenGraph in meta tags. + property: 0, + resource: 0, + 'typeof': 0, + vocab: 0, + + /** + * Non-standard Properties + */ + // autoCapitalize and autoCorrect are supported in Mobile Safari for + // keyboard hints. + autoCapitalize: 0, + autoCorrect: 0, + // autoSave allows WebKit/Blink to persist values of input fields on page reloads + autoSave: 0, + // color is for Safari mask-icon link + color: 0, + // itemProp, itemScope, itemType are for + // Microdata support. See http://schema.org/docs/gs.html + itemProp: 0, + itemScope: HAS_BOOLEAN_VALUE, + itemType: 0, + // itemID and itemRef are for Microdata support as well but + // only specified in the WHATWG spec document. See + // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api + itemID: 0, + itemRef: 0, + // results show looking glass icon and recent searches on input + // search fields in WebKit/Blink + results: 0, + // IE-only attribute that specifies security restrictions on an iframe + // as an alternative to the sandbox attribute on IE<10 + security: 0, + // IE-only attribute that controls focus behavior + unselectable: 0 + }, + DOMAttributeNames: { + acceptCharset: 'accept-charset', + className: 'class', + htmlFor: 'for', + httpEquiv: 'http-equiv' + }, + DOMPropertyNames: {}, + DOMMutationMethods: { + value: function (node, value) { + if (value == null) { + return node.removeAttribute('value'); + } + + // Number inputs get special treatment due to some edge cases in + // Chrome. Let everything else assign the value attribute as normal. + // https://github.com/facebook/react/issues/7253#issuecomment-236074326 + if (node.type !== 'number' || node.hasAttribute('value') === false) { + node.setAttribute('value', '' + value); + } else if (node.validity && !node.validity.badInput && node.ownerDocument.activeElement !== node) { + // Don't assign an attribute if validation reports bad + // input. Chrome will clear the value. Additionally, don't + // operate on inputs that have focus, otherwise Chrome might + // strip off trailing decimal places and cause the user's + // cursor position to jump to the beginning of the input. + // + // In ReactDOMInput, we have an onBlur event that will trigger + // this function again when focus is lost. + node.setAttribute('value', '' + value); + } + } + } +}; + +module.exports = HTMLDOMPropertyConfig; + +/***/ }), +/* 248 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMChildrenOperations = __webpack_require__(82); +var ReactDOMIDOperations = __webpack_require__(253); + +/** + * Abstracts away all functionality of the reconciler that requires knowledge of + * the browser context. TODO: These callers should be refactored to avoid the + * need for this injection. + */ +var ReactComponentBrowserEnvironment = { + processChildrenUpdates: ReactDOMIDOperations.dangerouslyProcessChildrenUpdates, + + replaceNodeWithMarkup: DOMChildrenOperations.dangerouslyReplaceNodeWithMarkup +}; + +module.exports = ReactComponentBrowserEnvironment; + +/***/ }), +/* 249 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var DOMLazyTree = __webpack_require__(39); +var ExecutionEnvironment = __webpack_require__(13); + +var createNodesFromMarkup = __webpack_require__(250); +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); + +var Danger = { + /** + * Replaces a node with a string of markup at its current position within its + * parent. The markup must render into a single root node. + * + * @param {DOMElement} oldChild Child node to replace. + * @param {string} markup Markup to render in place of the child node. + * @internal + */ + dangerouslyReplaceNodeWithMarkup: function (oldChild, markup) { + !ExecutionEnvironment.canUseDOM ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot render markup in a worker thread. Make sure `window` and `document` are available globally before requiring React when unit testing or use ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('56') : void 0; + !markup ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Missing markup.') : _prodInvariant('57') : void 0; + !(oldChild.nodeName !== 'HTML') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot replace markup of the <html> node. This is because browser quirks make this unreliable and/or slow. If you want to render to the root you must use server rendering. See ReactDOMServer.renderToString().') : _prodInvariant('58') : void 0; + + if (typeof markup === 'string') { + var newChild = createNodesFromMarkup(markup, emptyFunction)[0]; + oldChild.parentNode.replaceChild(newChild, oldChild); + } else { + DOMLazyTree.replaceChildWithTree(oldChild, markup); + } + } +}; + +module.exports = Danger; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 250 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +/*eslint-disable fb-www/unsafe-html*/ + +var ExecutionEnvironment = __webpack_require__(13); + +var createArrayFromMixed = __webpack_require__(251); +var getMarkupWrap = __webpack_require__(252); +var invariant = __webpack_require__(2); + +/** + * Dummy container used to render all markup. + */ +var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; + +/** + * Pattern used by `getNodeName`. + */ +var nodeNamePattern = /^\s*<(\w+)/; + +/** + * Extracts the `nodeName` of the first element in a string of markup. + * + * @param {string} markup String of markup. + * @return {?string} Node name of the supplied markup. + */ +function getNodeName(markup) { + var nodeNameMatch = markup.match(nodeNamePattern); + return nodeNameMatch && nodeNameMatch[1].toLowerCase(); +} + +/** + * Creates an array containing the nodes rendered from the supplied markup. The + * optionally supplied `handleScript` function will be invoked once for each + * <script> element that is rendered. If no `handleScript` function is supplied, + * an exception is thrown if any <script> elements are rendered. + * + * @param {string} markup A string of valid HTML markup. + * @param {?function} handleScript Invoked once for each rendered <script>. + * @return {array<DOMElement|DOMTextNode>} An array of rendered nodes. + */ +function createNodesFromMarkup(markup, handleScript) { + var node = dummyNode; + !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup dummy not initialized') : invariant(false) : void 0; + var nodeName = getNodeName(markup); + + var wrap = nodeName && getMarkupWrap(nodeName); + if (wrap) { + node.innerHTML = wrap[1] + markup + wrap[2]; + + var wrapDepth = wrap[0]; + while (wrapDepth--) { + node = node.lastChild; + } + } else { + node.innerHTML = markup; + } + + var scripts = node.getElementsByTagName('script'); + if (scripts.length) { + !handleScript ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup(...): Unexpected <script> element rendered.') : invariant(false) : void 0; + createArrayFromMixed(scripts).forEach(handleScript); + } + + var nodes = Array.from(node.childNodes); + while (node.lastChild) { + node.removeChild(node.lastChild); + } + return nodes; +} + +module.exports = createNodesFromMarkup; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 251 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var invariant = __webpack_require__(2); + +/** + * Convert array-like objects to arrays. + * + * This API assumes the caller knows the contents of the data type. For less + * well defined inputs use createArrayFromMixed. + * + * @param {object|function|filelist} obj + * @return {array} + */ +function toArray(obj) { + var length = obj.length; + + // Some browsers builtin objects can report typeof 'function' (e.g. NodeList + // in old versions of Safari). + !(!Array.isArray(obj) && (typeof obj === 'object' || typeof obj === 'function')) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Array-like object expected') : invariant(false) : void 0; + + !(typeof length === 'number') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object needs a length property') : invariant(false) : void 0; + + !(length === 0 || length - 1 in obj) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object should have keys for indices') : invariant(false) : void 0; + + !(typeof obj.callee !== 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object can\'t be `arguments`. Use rest params ' + '(function(...args) {}) or Array.from() instead.') : invariant(false) : void 0; + + // Old IE doesn't give collections access to hasOwnProperty. Assume inputs + // without method will throw during the slice call and skip straight to the + // fallback. + if (obj.hasOwnProperty) { + try { + return Array.prototype.slice.call(obj); + } catch (e) { + // IE < 9 does not support Array#slice on collections objects + } + } + + // Fall back to copying key by key. This assumes all keys have a value, + // so will not preserve sparsely populated inputs. + var ret = Array(length); + for (var ii = 0; ii < length; ii++) { + ret[ii] = obj[ii]; + } + return ret; +} + +/** + * Perform a heuristic test to determine if an object is "array-like". + * + * A monk asked Joshu, a Zen master, "Has a dog Buddha nature?" + * Joshu replied: "Mu." + * + * This function determines if its argument has "array nature": it returns + * true if the argument is an actual array, an `arguments' object, or an + * HTMLCollection (e.g. node.childNodes or node.getElementsByTagName()). + * + * It will return false for other array-like objects like Filelist. + * + * @param {*} obj + * @return {boolean} + */ +function hasArrayNature(obj) { + return ( + // not null/false + !!obj && ( + // arrays are objects, NodeLists are functions in Safari + typeof obj == 'object' || typeof obj == 'function') && + // quacks like an array + 'length' in obj && + // not window + !('setInterval' in obj) && + // no DOM node should be considered an array-like + // a 'select' element has 'length' and 'item' properties on IE8 + typeof obj.nodeType != 'number' && ( + // a real array + Array.isArray(obj) || + // arguments + 'callee' in obj || + // HTMLCollection/NodeList + 'item' in obj) + ); +} + +/** + * Ensure that the argument is an array by wrapping it in an array if it is not. + * Creates a copy of the argument if it is already an array. + * + * This is mostly useful idiomatically: + * + * var createArrayFromMixed = require('createArrayFromMixed'); + * + * function takesOneOrMoreThings(things) { + * things = createArrayFromMixed(things); + * ... + * } + * + * This allows you to treat `things' as an array, but accept scalars in the API. + * + * If you need to convert an array-like object, like `arguments`, into an array + * use toArray instead. + * + * @param {*} obj + * @return {array} + */ +function createArrayFromMixed(obj) { + if (!hasArrayNature(obj)) { + return [obj]; + } else if (Array.isArray(obj)) { + return obj.slice(); + } else { + return toArray(obj); + } +} + +module.exports = createArrayFromMixed; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 252 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/*eslint-disable fb-www/unsafe-html */ + +var ExecutionEnvironment = __webpack_require__(13); + +var invariant = __webpack_require__(2); + +/** + * Dummy container used to detect which wraps are necessary. + */ +var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; + +/** + * Some browsers cannot use `innerHTML` to render certain elements standalone, + * so we wrap them, render the wrapped nodes, then extract the desired node. + * + * In IE8, certain elements cannot render alone, so wrap all elements ('*'). + */ + +var shouldWrap = {}; + +var selectWrap = [1, '<select multiple="true">', '</select>']; +var tableWrap = [1, '<table>', '</table>']; +var trWrap = [3, '<table><tbody><tr>', '</tr></tbody></table>']; + +var svgWrap = [1, '<svg xmlns="http://www.w3.org/2000/svg">', '</svg>']; + +var markupWrap = { + '*': [1, '?<div>', '</div>'], + + 'area': [1, '<map>', '</map>'], + 'col': [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>'], + 'legend': [1, '<fieldset>', '</fieldset>'], + 'param': [1, '<object>', '</object>'], + 'tr': [2, '<table><tbody>', '</tbody></table>'], + + 'optgroup': selectWrap, + 'option': selectWrap, + + 'caption': tableWrap, + 'colgroup': tableWrap, + 'tbody': tableWrap, + 'tfoot': tableWrap, + 'thead': tableWrap, + + 'td': trWrap, + 'th': trWrap +}; + +// Initialize the SVG elements since we know they'll always need to be wrapped +// consistently. If they are created inside a <div> they will be initialized in +// the wrong namespace (and will not display). +var svgElements = ['circle', 'clipPath', 'defs', 'ellipse', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'text', 'tspan']; +svgElements.forEach(function (nodeName) { + markupWrap[nodeName] = svgWrap; + shouldWrap[nodeName] = true; +}); + +/** + * Gets the markup wrap configuration for the supplied `nodeName`. + * + * NOTE: This lazily detects which wraps are necessary for the current browser. + * + * @param {string} nodeName Lowercase `nodeName`. + * @return {?array} Markup wrap configuration, if applicable. + */ +function getMarkupWrap(nodeName) { + !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Markup wrapping node not initialized') : invariant(false) : void 0; + if (!markupWrap.hasOwnProperty(nodeName)) { + nodeName = '*'; + } + if (!shouldWrap.hasOwnProperty(nodeName)) { + if (nodeName === '*') { + dummyNode.innerHTML = '<link />'; + } else { + dummyNode.innerHTML = '<' + nodeName + '></' + nodeName + '>'; + } + shouldWrap[nodeName] = !dummyNode.firstChild; + } + return shouldWrap[nodeName] ? markupWrap[nodeName] : null; +} + +module.exports = getMarkupWrap; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 253 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMChildrenOperations = __webpack_require__(82); +var ReactDOMComponentTree = __webpack_require__(10); + +/** + * Operations used to process updates to DOM nodes. + */ +var ReactDOMIDOperations = { + /** + * Updates a component's children by processing a series of updates. + * + * @param {array<object>} updates List of update configurations. + * @internal + */ + dangerouslyProcessChildrenUpdates: function (parentInst, updates) { + var node = ReactDOMComponentTree.getNodeFromInstance(parentInst); + DOMChildrenOperations.processUpdates(node, updates); + } +}; + +module.exports = ReactDOMIDOperations; + +/***/ }), +/* 254 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + +/* global hasOwnProperty:true */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var AutoFocusUtils = __webpack_require__(255); +var CSSPropertyOperations = __webpack_require__(256); +var DOMLazyTree = __webpack_require__(39); +var DOMNamespaces = __webpack_require__(83); +var DOMProperty = __webpack_require__(28); +var DOMPropertyOperations = __webpack_require__(138); +var EventPluginHub = __webpack_require__(46); +var EventPluginRegistry = __webpack_require__(57); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactDOMComponentFlags = __webpack_require__(126); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMInput = __webpack_require__(266); +var ReactDOMOption = __webpack_require__(267); +var ReactDOMSelect = __webpack_require__(140); +var ReactDOMTextarea = __webpack_require__(268); +var ReactInstrumentation = __webpack_require__(19); +var ReactMultiChild = __webpack_require__(269); +var ReactServerRenderingTransaction = __webpack_require__(278); + +var emptyFunction = __webpack_require__(18); +var escapeTextContentForBrowser = __webpack_require__(61); +var invariant = __webpack_require__(2); +var isEventSupported = __webpack_require__(80); +var shallowEqual = __webpack_require__(87); +var inputValueTracking = __webpack_require__(132); +var validateDOMNesting = __webpack_require__(91); +var warning = __webpack_require__(3); + +var Flags = ReactDOMComponentFlags; +var deleteListener = EventPluginHub.deleteListener; +var getNode = ReactDOMComponentTree.getNodeFromInstance; +var listenTo = ReactBrowserEventEmitter.listenTo; +var registrationNameModules = EventPluginRegistry.registrationNameModules; + +// For quickly matching children type, to test if can be treated as content. +var CONTENT_TYPES = { string: true, number: true }; + +var STYLE = 'style'; +var HTML = '__html'; +var RESERVED_PROPS = { + children: null, + dangerouslySetInnerHTML: null, + suppressContentEditableWarning: null +}; + +// Node type for document fragments (Node.DOCUMENT_FRAGMENT_NODE). +var DOC_FRAGMENT_TYPE = 11; + +function getDeclarationErrorAddendum(internalInstance) { + if (internalInstance) { + var owner = internalInstance._currentElement._owner || null; + if (owner) { + var name = owner.getName(); + if (name) { + return ' This DOM node was rendered by `' + name + '`.'; + } + } + } + return ''; +} + +function friendlyStringify(obj) { + if (typeof obj === 'object') { + if (Array.isArray(obj)) { + return '[' + obj.map(friendlyStringify).join(', ') + ']'; + } else { + var pairs = []; + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key)) { + var keyEscaped = /^[a-z$_][\w$_]*$/i.test(key) ? key : JSON.stringify(key); + pairs.push(keyEscaped + ': ' + friendlyStringify(obj[key])); + } + } + return '{' + pairs.join(', ') + '}'; + } + } else if (typeof obj === 'string') { + return JSON.stringify(obj); + } else if (typeof obj === 'function') { + return '[function object]'; + } + // Differs from JSON.stringify in that undefined because undefined and that + // inf and nan don't become null + return String(obj); +} + +var styleMutationWarning = {}; + +function checkAndWarnForMutatedStyle(style1, style2, component) { + if (style1 == null || style2 == null) { + return; + } + if (shallowEqual(style1, style2)) { + return; + } + + var componentName = component._tag; + var owner = component._currentElement._owner; + var ownerName; + if (owner) { + ownerName = owner.getName(); + } + + var hash = ownerName + '|' + componentName; + + if (styleMutationWarning.hasOwnProperty(hash)) { + return; + } + + styleMutationWarning[hash] = true; + + process.env.NODE_ENV !== 'production' ? warning(false, '`%s` was passed a style object that has previously been mutated. ' + 'Mutating `style` is deprecated. Consider cloning it beforehand. Check ' + 'the `render` %s. Previous style: %s. Mutated style: %s.', componentName, owner ? 'of `' + ownerName + '`' : 'using <' + componentName + '>', friendlyStringify(style1), friendlyStringify(style2)) : void 0; +} + +/** + * @param {object} component + * @param {?object} props + */ +function assertValidProps(component, props) { + if (!props) { + return; + } + // Note the use of `==` which checks for null or undefined. + if (voidElementTags[component._tag]) { + !(props.children == null && props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.%s', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : _prodInvariant('137', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : void 0; + } + if (props.dangerouslySetInnerHTML != null) { + !(props.children == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Can only set one of `children` or `props.dangerouslySetInnerHTML`.') : _prodInvariant('60') : void 0; + !(typeof props.dangerouslySetInnerHTML === 'object' && HTML in props.dangerouslySetInnerHTML) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.') : _prodInvariant('61') : void 0; + } + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(props.innerHTML == null, 'Directly setting property `innerHTML` is not permitted. ' + 'For more information, lookup documentation on `dangerouslySetInnerHTML`.') : void 0; + process.env.NODE_ENV !== 'production' ? warning(props.suppressContentEditableWarning || !props.contentEditable || props.children == null, 'A component is `contentEditable` and contains `children` managed by ' + 'React. It is now your responsibility to guarantee that none of ' + 'those nodes are unexpectedly modified or duplicated. This is ' + 'probably not intentional.') : void 0; + process.env.NODE_ENV !== 'production' ? warning(props.onFocusIn == null && props.onFocusOut == null, 'React uses onFocus and onBlur instead of onFocusIn and onFocusOut. ' + 'All React events are normalized to bubble, so onFocusIn and onFocusOut ' + 'are not needed/supported by React.') : void 0; + } + !(props.style == null || typeof props.style === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + \'em\'}} when using JSX.%s', getDeclarationErrorAddendum(component)) : _prodInvariant('62', getDeclarationErrorAddendum(component)) : void 0; +} + +function enqueuePutListener(inst, registrationName, listener, transaction) { + if (transaction instanceof ReactServerRenderingTransaction) { + return; + } + if (process.env.NODE_ENV !== 'production') { + // IE8 has no API for event capturing and the `onScroll` event doesn't + // bubble. + process.env.NODE_ENV !== 'production' ? warning(registrationName !== 'onScroll' || isEventSupported('scroll', true), "This browser doesn't support the `onScroll` event") : void 0; + } + var containerInfo = inst._hostContainerInfo; + var isDocumentFragment = containerInfo._node && containerInfo._node.nodeType === DOC_FRAGMENT_TYPE; + var doc = isDocumentFragment ? containerInfo._node : containerInfo._ownerDocument; + listenTo(registrationName, doc); + transaction.getReactMountReady().enqueue(putListener, { + inst: inst, + registrationName: registrationName, + listener: listener + }); +} + +function putListener() { + var listenerToPut = this; + EventPluginHub.putListener(listenerToPut.inst, listenerToPut.registrationName, listenerToPut.listener); +} + +function inputPostMount() { + var inst = this; + ReactDOMInput.postMountWrapper(inst); +} + +function textareaPostMount() { + var inst = this; + ReactDOMTextarea.postMountWrapper(inst); +} + +function optionPostMount() { + var inst = this; + ReactDOMOption.postMountWrapper(inst); +} + +var setAndValidateContentChildDev = emptyFunction; +if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev = function (content) { + var hasExistingContent = this._contentDebugID != null; + var debugID = this._debugID; + // This ID represents the inlined child that has no backing instance: + var contentDebugID = -debugID; + + if (content == null) { + if (hasExistingContent) { + ReactInstrumentation.debugTool.onUnmountComponent(this._contentDebugID); + } + this._contentDebugID = null; + return; + } + + validateDOMNesting(null, String(content), this, this._ancestorInfo); + this._contentDebugID = contentDebugID; + if (hasExistingContent) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(contentDebugID, content); + ReactInstrumentation.debugTool.onUpdateComponent(contentDebugID); + } else { + ReactInstrumentation.debugTool.onBeforeMountComponent(contentDebugID, content, debugID); + ReactInstrumentation.debugTool.onMountComponent(contentDebugID); + ReactInstrumentation.debugTool.onSetChildren(debugID, [contentDebugID]); + } + }; +} + +// There are so many media events, it makes sense to just +// maintain a list rather than create a `trapBubbledEvent` for each +var mediaEvents = { + topAbort: 'abort', + topCanPlay: 'canplay', + topCanPlayThrough: 'canplaythrough', + topDurationChange: 'durationchange', + topEmptied: 'emptied', + topEncrypted: 'encrypted', + topEnded: 'ended', + topError: 'error', + topLoadedData: 'loadeddata', + topLoadedMetadata: 'loadedmetadata', + topLoadStart: 'loadstart', + topPause: 'pause', + topPlay: 'play', + topPlaying: 'playing', + topProgress: 'progress', + topRateChange: 'ratechange', + topSeeked: 'seeked', + topSeeking: 'seeking', + topStalled: 'stalled', + topSuspend: 'suspend', + topTimeUpdate: 'timeupdate', + topVolumeChange: 'volumechange', + topWaiting: 'waiting' +}; + +function trackInputValue() { + inputValueTracking.track(this); +} + +function trapBubbledEventsLocal() { + var inst = this; + // If a component renders to null or if another component fatals and causes + // the state of the tree to be corrupted, `node` here can be null. + !inst._rootNodeID ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Must be mounted to trap events') : _prodInvariant('63') : void 0; + var node = getNode(inst); + !node ? process.env.NODE_ENV !== 'production' ? invariant(false, 'trapBubbledEvent(...): Requires node to be rendered.') : _prodInvariant('64') : void 0; + + switch (inst._tag) { + case 'iframe': + case 'object': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; + break; + case 'video': + case 'audio': + inst._wrapperState.listeners = []; + // Create listener for each media event + for (var event in mediaEvents) { + if (mediaEvents.hasOwnProperty(event)) { + inst._wrapperState.listeners.push(ReactBrowserEventEmitter.trapBubbledEvent(event, mediaEvents[event], node)); + } + } + break; + case 'source': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node)]; + break; + case 'img': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node), ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; + break; + case 'form': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topReset', 'reset', node), ReactBrowserEventEmitter.trapBubbledEvent('topSubmit', 'submit', node)]; + break; + case 'input': + case 'select': + case 'textarea': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topInvalid', 'invalid', node)]; + break; + } +} + +function postUpdateSelectWrapper() { + ReactDOMSelect.postUpdateWrapper(this); +} + +// For HTML, certain tags should omit their close tag. We keep a whitelist for +// those special-case tags. + +var omittedCloseTags = { + area: true, + base: true, + br: true, + col: true, + embed: true, + hr: true, + img: true, + input: true, + keygen: true, + link: true, + meta: true, + param: true, + source: true, + track: true, + wbr: true + // NOTE: menuitem's close tag should be omitted, but that causes problems. +}; + +var newlineEatingTags = { + listing: true, + pre: true, + textarea: true +}; + +// For HTML, certain tags cannot have children. This has the same purpose as +// `omittedCloseTags` except that `menuitem` should still have its closing tag. + +var voidElementTags = _assign({ + menuitem: true +}, omittedCloseTags); + +// We accept any tag to be rendered but since this gets injected into arbitrary +// HTML, we want to make sure that it's a safe tag. +// http://www.w3.org/TR/REC-xml/#NT-Name + +var VALID_TAG_REGEX = /^[a-zA-Z][a-zA-Z:_\.\-\d]*$/; // Simplified subset +var validatedTagCache = {}; +var hasOwnProperty = {}.hasOwnProperty; + +function validateDangerousTag(tag) { + if (!hasOwnProperty.call(validatedTagCache, tag)) { + !VALID_TAG_REGEX.test(tag) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Invalid tag: %s', tag) : _prodInvariant('65', tag) : void 0; + validatedTagCache[tag] = true; + } +} + +function isCustomComponent(tagName, props) { + return tagName.indexOf('-') >= 0 || props.is != null; +} + +var globalIdCounter = 1; + +/** + * Creates a new React class that is idempotent and capable of containing other + * React components. It accepts event listeners and DOM properties that are + * valid according to `DOMProperty`. + * + * - Event listeners: `onClick`, `onMouseDown`, etc. + * - DOM properties: `className`, `name`, `title`, etc. + * + * The `style` property functions differently from the DOM API. It accepts an + * object mapping of style properties to values. + * + * @constructor ReactDOMComponent + * @extends ReactMultiChild + */ +function ReactDOMComponent(element) { + var tag = element.type; + validateDangerousTag(tag); + this._currentElement = element; + this._tag = tag.toLowerCase(); + this._namespaceURI = null; + this._renderedChildren = null; + this._previousStyle = null; + this._previousStyleCopy = null; + this._hostNode = null; + this._hostParent = null; + this._rootNodeID = 0; + this._domID = 0; + this._hostContainerInfo = null; + this._wrapperState = null; + this._topLevelWrapper = null; + this._flags = 0; + if (process.env.NODE_ENV !== 'production') { + this._ancestorInfo = null; + setAndValidateContentChildDev.call(this, null); + } +} + +ReactDOMComponent.displayName = 'ReactDOMComponent'; + +ReactDOMComponent.Mixin = { + /** + * Generates root tag markup then recurses. This method has side effects and + * is not idempotent. + * + * @internal + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?ReactDOMComponent} the parent component instance + * @param {?object} info about the host container + * @param {object} context + * @return {string} The computed markup. + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + this._rootNodeID = globalIdCounter++; + this._domID = hostContainerInfo._idCounter++; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; + + var props = this._currentElement.props; + + switch (this._tag) { + case 'audio': + case 'form': + case 'iframe': + case 'img': + case 'link': + case 'object': + case 'source': + case 'video': + this._wrapperState = { + listeners: null + }; + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'input': + ReactDOMInput.mountWrapper(this, props, hostParent); + props = ReactDOMInput.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trackInputValue, this); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'option': + ReactDOMOption.mountWrapper(this, props, hostParent); + props = ReactDOMOption.getHostProps(this, props); + break; + case 'select': + ReactDOMSelect.mountWrapper(this, props, hostParent); + props = ReactDOMSelect.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'textarea': + ReactDOMTextarea.mountWrapper(this, props, hostParent); + props = ReactDOMTextarea.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trackInputValue, this); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + } + + assertValidProps(this, props); + + // We create tags in the namespace of their parent container, except HTML + // tags get no namespace. + var namespaceURI; + var parentTag; + if (hostParent != null) { + namespaceURI = hostParent._namespaceURI; + parentTag = hostParent._tag; + } else if (hostContainerInfo._tag) { + namespaceURI = hostContainerInfo._namespaceURI; + parentTag = hostContainerInfo._tag; + } + if (namespaceURI == null || namespaceURI === DOMNamespaces.svg && parentTag === 'foreignobject') { + namespaceURI = DOMNamespaces.html; + } + if (namespaceURI === DOMNamespaces.html) { + if (this._tag === 'svg') { + namespaceURI = DOMNamespaces.svg; + } else if (this._tag === 'math') { + namespaceURI = DOMNamespaces.mathml; + } + } + this._namespaceURI = namespaceURI; + + if (process.env.NODE_ENV !== 'production') { + var parentInfo; + if (hostParent != null) { + parentInfo = hostParent._ancestorInfo; + } else if (hostContainerInfo._tag) { + parentInfo = hostContainerInfo._ancestorInfo; + } + if (parentInfo) { + // parentInfo should always be present except for the top-level + // component when server rendering + validateDOMNesting(this._tag, null, this, parentInfo); + } + this._ancestorInfo = validateDOMNesting.updatedAncestorInfo(parentInfo, this._tag, this); + } + + var mountImage; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var el; + if (namespaceURI === DOMNamespaces.html) { + if (this._tag === 'script') { + // Create the script via .innerHTML so its "parser-inserted" flag is + // set to true and it does not execute + var div = ownerDocument.createElement('div'); + var type = this._currentElement.type; + div.innerHTML = '<' + type + '></' + type + '>'; + el = div.removeChild(div.firstChild); + } else if (props.is) { + el = ownerDocument.createElement(this._currentElement.type, props.is); + } else { + // Separate else branch instead of using `props.is || undefined` above becuase of a Firefox bug. + // See discussion in https://github.com/facebook/react/pull/6896 + // and discussion in https://bugzilla.mozilla.org/show_bug.cgi?id=1276240 + el = ownerDocument.createElement(this._currentElement.type); + } + } else { + el = ownerDocument.createElementNS(namespaceURI, this._currentElement.type); + } + ReactDOMComponentTree.precacheNode(this, el); + this._flags |= Flags.hasCachedChildNodes; + if (!this._hostParent) { + DOMPropertyOperations.setAttributeForRoot(el); + } + this._updateDOMProperties(null, props, transaction); + var lazyTree = DOMLazyTree(el); + this._createInitialChildren(transaction, props, context, lazyTree); + mountImage = lazyTree; + } else { + var tagOpen = this._createOpenTagMarkupAndPutListeners(transaction, props); + var tagContent = this._createContentMarkup(transaction, props, context); + if (!tagContent && omittedCloseTags[this._tag]) { + mountImage = tagOpen + '/>'; + } else { + mountImage = tagOpen + '>' + tagContent + '</' + this._currentElement.type + '>'; + } + } + + switch (this._tag) { + case 'input': + transaction.getReactMountReady().enqueue(inputPostMount, this); + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'textarea': + transaction.getReactMountReady().enqueue(textareaPostMount, this); + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'select': + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'button': + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'option': + transaction.getReactMountReady().enqueue(optionPostMount, this); + break; + } + + return mountImage; + }, + + /** + * Creates markup for the open tag and all attributes. + * + * This method has side effects because events get registered. + * + * Iterating over object properties is faster than iterating over arrays. + * @see http://jsperf.com/obj-vs-arr-iteration + * + * @private + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} props + * @return {string} Markup of opening tag. + */ + _createOpenTagMarkupAndPutListeners: function (transaction, props) { + var ret = '<' + this._currentElement.type; + + for (var propKey in props) { + if (!props.hasOwnProperty(propKey)) { + continue; + } + var propValue = props[propKey]; + if (propValue == null) { + continue; + } + if (registrationNameModules.hasOwnProperty(propKey)) { + if (propValue) { + enqueuePutListener(this, propKey, propValue, transaction); + } + } else { + if (propKey === STYLE) { + if (propValue) { + if (process.env.NODE_ENV !== 'production') { + // See `_updateDOMProperties`. style block + this._previousStyle = propValue; + } + propValue = this._previousStyleCopy = _assign({}, props.style); + } + propValue = CSSPropertyOperations.createMarkupForStyles(propValue, this); + } + var markup = null; + if (this._tag != null && isCustomComponent(this._tag, props)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + markup = DOMPropertyOperations.createMarkupForCustomAttribute(propKey, propValue); + } + } else { + markup = DOMPropertyOperations.createMarkupForProperty(propKey, propValue); + } + if (markup) { + ret += ' ' + markup; + } + } + } + + // For static pages, no need to put React ID and checksum. Saves lots of + // bytes. + if (transaction.renderToStaticMarkup) { + return ret; + } + + if (!this._hostParent) { + ret += ' ' + DOMPropertyOperations.createMarkupForRoot(); + } + ret += ' ' + DOMPropertyOperations.createMarkupForID(this._domID); + return ret; + }, + + /** + * Creates markup for the content between the tags. + * + * @private + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} props + * @param {object} context + * @return {string} Content markup. + */ + _createContentMarkup: function (transaction, props, context) { + var ret = ''; + + // Intentional use of != to avoid catching zero/false. + var innerHTML = props.dangerouslySetInnerHTML; + if (innerHTML != null) { + if (innerHTML.__html != null) { + ret = innerHTML.__html; + } + } else { + var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; + var childrenToUse = contentToUse != null ? null : props.children; + if (contentToUse != null) { + // TODO: Validate that text is allowed as a child of this node + ret = escapeTextContentForBrowser(contentToUse); + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, contentToUse); + } + } else if (childrenToUse != null) { + var mountImages = this.mountChildren(childrenToUse, transaction, context); + ret = mountImages.join(''); + } + } + if (newlineEatingTags[this._tag] && ret.charAt(0) === '\n') { + // text/html ignores the first character in these tags if it's a newline + // Prefer to break application/xml over text/html (for now) by adding + // a newline specifically to get eaten by the parser. (Alternately for + // textareas, replacing "^\n" with "\r\n" doesn't get eaten, and the first + // \r is normalized out by HTMLTextAreaElement#value.) + // See: <http://www.w3.org/TR/html-polyglot/#newlines-in-textarea-and-pre> + // See: <http://www.w3.org/TR/html5/syntax.html#element-restrictions> + // See: <http://www.w3.org/TR/html5/syntax.html#newlines> + // See: Parsing of "textarea" "listing" and "pre" elements + // from <http://www.w3.org/TR/html5/syntax.html#parsing-main-inbody> + return '\n' + ret; + } else { + return ret; + } + }, + + _createInitialChildren: function (transaction, props, context, lazyTree) { + // Intentional use of != to avoid catching zero/false. + var innerHTML = props.dangerouslySetInnerHTML; + if (innerHTML != null) { + if (innerHTML.__html != null) { + DOMLazyTree.queueHTML(lazyTree, innerHTML.__html); + } + } else { + var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; + var childrenToUse = contentToUse != null ? null : props.children; + // TODO: Validate that text is allowed as a child of this node + if (contentToUse != null) { + // Avoid setting textContent when the text is empty. In IE11 setting + // textContent on a text area will cause the placeholder to not + // show within the textarea until it has been focused and blurred again. + // https://github.com/facebook/react/issues/6731#issuecomment-254874553 + if (contentToUse !== '') { + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, contentToUse); + } + DOMLazyTree.queueText(lazyTree, contentToUse); + } + } else if (childrenToUse != null) { + var mountImages = this.mountChildren(childrenToUse, transaction, context); + for (var i = 0; i < mountImages.length; i++) { + DOMLazyTree.queueChild(lazyTree, mountImages[i]); + } + } + } + }, + + /** + * Receives a next element and updates the component. + * + * @internal + * @param {ReactElement} nextElement + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} context + */ + receiveComponent: function (nextElement, transaction, context) { + var prevElement = this._currentElement; + this._currentElement = nextElement; + this.updateComponent(transaction, prevElement, nextElement, context); + }, + + /** + * Updates a DOM component after it has already been allocated and + * attached to the DOM. Reconciles the root DOM node, then recurses. + * + * @param {ReactReconcileTransaction} transaction + * @param {ReactElement} prevElement + * @param {ReactElement} nextElement + * @internal + * @overridable + */ + updateComponent: function (transaction, prevElement, nextElement, context) { + var lastProps = prevElement.props; + var nextProps = this._currentElement.props; + + switch (this._tag) { + case 'input': + lastProps = ReactDOMInput.getHostProps(this, lastProps); + nextProps = ReactDOMInput.getHostProps(this, nextProps); + break; + case 'option': + lastProps = ReactDOMOption.getHostProps(this, lastProps); + nextProps = ReactDOMOption.getHostProps(this, nextProps); + break; + case 'select': + lastProps = ReactDOMSelect.getHostProps(this, lastProps); + nextProps = ReactDOMSelect.getHostProps(this, nextProps); + break; + case 'textarea': + lastProps = ReactDOMTextarea.getHostProps(this, lastProps); + nextProps = ReactDOMTextarea.getHostProps(this, nextProps); + break; + } + + assertValidProps(this, nextProps); + this._updateDOMProperties(lastProps, nextProps, transaction); + this._updateDOMChildren(lastProps, nextProps, transaction, context); + + switch (this._tag) { + case 'input': + // Update the wrapper around inputs *after* updating props. This has to + // happen after `_updateDOMProperties`. Otherwise HTML5 input validations + // raise warnings and prevent the new value from being assigned. + ReactDOMInput.updateWrapper(this); + break; + case 'textarea': + ReactDOMTextarea.updateWrapper(this); + break; + case 'select': + // <select> value update needs to occur after <option> children + // reconciliation + transaction.getReactMountReady().enqueue(postUpdateSelectWrapper, this); + break; + } + }, + + /** + * Reconciles the properties by detecting differences in property values and + * updating the DOM as necessary. This function is probably the single most + * critical path for performance optimization. + * + * TODO: Benchmark whether checking for changed values in memory actually + * improves performance (especially statically positioned elements). + * TODO: Benchmark the effects of putting this at the top since 99% of props + * do not change for a given reconciliation. + * TODO: Benchmark areas that can be improved with caching. + * + * @private + * @param {object} lastProps + * @param {object} nextProps + * @param {?DOMElement} node + */ + _updateDOMProperties: function (lastProps, nextProps, transaction) { + var propKey; + var styleName; + var styleUpdates; + for (propKey in lastProps) { + if (nextProps.hasOwnProperty(propKey) || !lastProps.hasOwnProperty(propKey) || lastProps[propKey] == null) { + continue; + } + if (propKey === STYLE) { + var lastStyle = this._previousStyleCopy; + for (styleName in lastStyle) { + if (lastStyle.hasOwnProperty(styleName)) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = ''; + } + } + this._previousStyleCopy = null; + } else if (registrationNameModules.hasOwnProperty(propKey)) { + if (lastProps[propKey]) { + // Only call deleteListener if there was a listener previously or + // else willDeleteListener gets called when there wasn't actually a + // listener (e.g., onClick={null}) + deleteListener(this, propKey); + } + } else if (isCustomComponent(this._tag, lastProps)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + DOMPropertyOperations.deleteValueForAttribute(getNode(this), propKey); + } + } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { + DOMPropertyOperations.deleteValueForProperty(getNode(this), propKey); + } + } + for (propKey in nextProps) { + var nextProp = nextProps[propKey]; + var lastProp = propKey === STYLE ? this._previousStyleCopy : lastProps != null ? lastProps[propKey] : undefined; + if (!nextProps.hasOwnProperty(propKey) || nextProp === lastProp || nextProp == null && lastProp == null) { + continue; + } + if (propKey === STYLE) { + if (nextProp) { + if (process.env.NODE_ENV !== 'production') { + checkAndWarnForMutatedStyle(this._previousStyleCopy, this._previousStyle, this); + this._previousStyle = nextProp; + } + nextProp = this._previousStyleCopy = _assign({}, nextProp); + } else { + this._previousStyleCopy = null; + } + if (lastProp) { + // Unset styles on `lastProp` but not on `nextProp`. + for (styleName in lastProp) { + if (lastProp.hasOwnProperty(styleName) && (!nextProp || !nextProp.hasOwnProperty(styleName))) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = ''; + } + } + // Update styles that changed since `lastProp`. + for (styleName in nextProp) { + if (nextProp.hasOwnProperty(styleName) && lastProp[styleName] !== nextProp[styleName]) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = nextProp[styleName]; + } + } + } else { + // Relies on `updateStylesByID` not mutating `styleUpdates`. + styleUpdates = nextProp; + } + } else if (registrationNameModules.hasOwnProperty(propKey)) { + if (nextProp) { + enqueuePutListener(this, propKey, nextProp, transaction); + } else if (lastProp) { + deleteListener(this, propKey); + } + } else if (isCustomComponent(this._tag, nextProps)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + DOMPropertyOperations.setValueForAttribute(getNode(this), propKey, nextProp); + } + } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { + var node = getNode(this); + // If we're updating to null or undefined, we should remove the property + // from the DOM node instead of inadvertently setting to a string. This + // brings us in line with the same behavior we have on initial render. + if (nextProp != null) { + DOMPropertyOperations.setValueForProperty(node, propKey, nextProp); + } else { + DOMPropertyOperations.deleteValueForProperty(node, propKey); + } + } + } + if (styleUpdates) { + CSSPropertyOperations.setValueForStyles(getNode(this), styleUpdates, this); + } + }, + + /** + * Reconciles the children with the various properties that affect the + * children content. + * + * @param {object} lastProps + * @param {object} nextProps + * @param {ReactReconcileTransaction} transaction + * @param {object} context + */ + _updateDOMChildren: function (lastProps, nextProps, transaction, context) { + var lastContent = CONTENT_TYPES[typeof lastProps.children] ? lastProps.children : null; + var nextContent = CONTENT_TYPES[typeof nextProps.children] ? nextProps.children : null; + + var lastHtml = lastProps.dangerouslySetInnerHTML && lastProps.dangerouslySetInnerHTML.__html; + var nextHtml = nextProps.dangerouslySetInnerHTML && nextProps.dangerouslySetInnerHTML.__html; + + // Note the use of `!=` which checks for null or undefined. + var lastChildren = lastContent != null ? null : lastProps.children; + var nextChildren = nextContent != null ? null : nextProps.children; + + // If we're switching from children to content/html or vice versa, remove + // the old content + var lastHasContentOrHtml = lastContent != null || lastHtml != null; + var nextHasContentOrHtml = nextContent != null || nextHtml != null; + if (lastChildren != null && nextChildren == null) { + this.updateChildren(null, transaction, context); + } else if (lastHasContentOrHtml && !nextHasContentOrHtml) { + this.updateTextContent(''); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); + } + } + + if (nextContent != null) { + if (lastContent !== nextContent) { + this.updateTextContent('' + nextContent); + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, nextContent); + } + } + } else if (nextHtml != null) { + if (lastHtml !== nextHtml) { + this.updateMarkup('' + nextHtml); + } + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); + } + } else if (nextChildren != null) { + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, null); + } + + this.updateChildren(nextChildren, transaction, context); + } + }, + + getHostNode: function () { + return getNode(this); + }, + + /** + * Destroys all event registrations for this instance. Does not remove from + * the DOM. That must be done by the parent. + * + * @internal + */ + unmountComponent: function (safely) { + switch (this._tag) { + case 'audio': + case 'form': + case 'iframe': + case 'img': + case 'link': + case 'object': + case 'source': + case 'video': + var listeners = this._wrapperState.listeners; + if (listeners) { + for (var i = 0; i < listeners.length; i++) { + listeners[i].remove(); + } + } + break; + case 'input': + case 'textarea': + inputValueTracking.stopTracking(this); + break; + case 'html': + case 'head': + case 'body': + /** + * Components like <html> <head> and <body> can't be removed or added + * easily in a cross-browser way, however it's valuable to be able to + * take advantage of React's reconciliation for styling and <title> + * management. So we just document it and throw in dangerous cases. + */ + true ? process.env.NODE_ENV !== 'production' ? invariant(false, '<%s> tried to unmount. Because of cross-browser quirks it is impossible to unmount some top-level components (eg <html>, <head>, and <body>) reliably and efficiently. To fix this, have a single top-level component that never unmounts render these elements.', this._tag) : _prodInvariant('66', this._tag) : void 0; + break; + } + + this.unmountChildren(safely); + ReactDOMComponentTree.uncacheNode(this); + EventPluginHub.deleteAllListeners(this); + this._rootNodeID = 0; + this._domID = 0; + this._wrapperState = null; + + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, null); + } + }, + + getPublicInstance: function () { + return getNode(this); + } +}; + +_assign(ReactDOMComponent.prototype, ReactDOMComponent.Mixin, ReactMultiChild.Mixin); + +module.exports = ReactDOMComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 255 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMComponentTree = __webpack_require__(10); + +var focusNode = __webpack_require__(136); + +var AutoFocusUtils = { + focusDOMComponent: function () { + focusNode(ReactDOMComponentTree.getNodeFromInstance(this)); + } +}; + +module.exports = AutoFocusUtils; + +/***/ }), +/* 256 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var CSSProperty = __webpack_require__(137); +var ExecutionEnvironment = __webpack_require__(13); +var ReactInstrumentation = __webpack_require__(19); + +var camelizeStyleName = __webpack_require__(257); +var dangerousStyleValue = __webpack_require__(259); +var hyphenateStyleName = __webpack_require__(260); +var memoizeStringOnly = __webpack_require__(262); +var warning = __webpack_require__(3); + +var processStyleName = memoizeStringOnly(function (styleName) { + return hyphenateStyleName(styleName); +}); + +var hasShorthandPropertyBug = false; +var styleFloatAccessor = 'cssFloat'; +if (ExecutionEnvironment.canUseDOM) { + var tempStyle = document.createElement('div').style; + try { + // IE8 throws "Invalid argument." if resetting shorthand style properties. + tempStyle.font = ''; + } catch (e) { + hasShorthandPropertyBug = true; + } + // IE8 only supports accessing cssFloat (standard) as styleFloat + if (document.documentElement.style.cssFloat === undefined) { + styleFloatAccessor = 'styleFloat'; + } +} + +if (process.env.NODE_ENV !== 'production') { + // 'msTransform' is correct, but the other prefixes should be capitalized + var badVendoredStyleNamePattern = /^(?:webkit|moz|o)[A-Z]/; + + // style values shouldn't contain a semicolon + var badStyleValueWithSemicolonPattern = /;\s*$/; + + var warnedStyleNames = {}; + var warnedStyleValues = {}; + var warnedForNaNValue = false; + + var warnHyphenatedStyleName = function (name, owner) { + if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { + return; + } + + warnedStyleNames[name] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported style property %s. Did you mean %s?%s', name, camelizeStyleName(name), checkRenderMessage(owner)) : void 0; + }; + + var warnBadVendoredStyleName = function (name, owner) { + if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { + return; + } + + warnedStyleNames[name] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported vendor-prefixed style property %s. Did you mean %s?%s', name, name.charAt(0).toUpperCase() + name.slice(1), checkRenderMessage(owner)) : void 0; + }; + + var warnStyleValueWithSemicolon = function (name, value, owner) { + if (warnedStyleValues.hasOwnProperty(value) && warnedStyleValues[value]) { + return; + } + + warnedStyleValues[value] = true; + process.env.NODE_ENV !== 'production' ? warning(false, "Style property values shouldn't contain a semicolon.%s " + 'Try "%s: %s" instead.', checkRenderMessage(owner), name, value.replace(badStyleValueWithSemicolonPattern, '')) : void 0; + }; + + var warnStyleValueIsNaN = function (name, value, owner) { + if (warnedForNaNValue) { + return; + } + + warnedForNaNValue = true; + process.env.NODE_ENV !== 'production' ? warning(false, '`NaN` is an invalid value for the `%s` css style property.%s', name, checkRenderMessage(owner)) : void 0; + }; + + var checkRenderMessage = function (owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; + }; + + /** + * @param {string} name + * @param {*} value + * @param {ReactDOMComponent} component + */ + var warnValidStyle = function (name, value, component) { + var owner; + if (component) { + owner = component._currentElement._owner; + } + if (name.indexOf('-') > -1) { + warnHyphenatedStyleName(name, owner); + } else if (badVendoredStyleNamePattern.test(name)) { + warnBadVendoredStyleName(name, owner); + } else if (badStyleValueWithSemicolonPattern.test(value)) { + warnStyleValueWithSemicolon(name, value, owner); + } + + if (typeof value === 'number' && isNaN(value)) { + warnStyleValueIsNaN(name, value, owner); + } + }; +} + +/** + * Operations for dealing with CSS properties. + */ +var CSSPropertyOperations = { + /** + * Serializes a mapping of style properties for use as inline styles: + * + * > createMarkupForStyles({width: '200px', height: 0}) + * "width:200px;height:0;" + * + * Undefined values are ignored so that declarative programming is easier. + * The result should be HTML-escaped before insertion into the DOM. + * + * @param {object} styles + * @param {ReactDOMComponent} component + * @return {?string} + */ + createMarkupForStyles: function (styles, component) { + var serialized = ''; + for (var styleName in styles) { + if (!styles.hasOwnProperty(styleName)) { + continue; + } + var isCustomProperty = styleName.indexOf('--') === 0; + var styleValue = styles[styleName]; + if (process.env.NODE_ENV !== 'production') { + if (!isCustomProperty) { + warnValidStyle(styleName, styleValue, component); + } + } + if (styleValue != null) { + serialized += processStyleName(styleName) + ':'; + serialized += dangerousStyleValue(styleName, styleValue, component, isCustomProperty) + ';'; + } + } + return serialized || null; + }, + + /** + * Sets the value for multiple styles on a node. If a value is specified as + * '' (empty string), the corresponding style property will be unset. + * + * @param {DOMElement} node + * @param {object} styles + * @param {ReactDOMComponent} component + */ + setValueForStyles: function (node, styles, component) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: component._debugID, + type: 'update styles', + payload: styles + }); + } + + var style = node.style; + for (var styleName in styles) { + if (!styles.hasOwnProperty(styleName)) { + continue; + } + var isCustomProperty = styleName.indexOf('--') === 0; + if (process.env.NODE_ENV !== 'production') { + if (!isCustomProperty) { + warnValidStyle(styleName, styles[styleName], component); + } + } + var styleValue = dangerousStyleValue(styleName, styles[styleName], component, isCustomProperty); + if (styleName === 'float' || styleName === 'cssFloat') { + styleName = styleFloatAccessor; + } + if (isCustomProperty) { + style.setProperty(styleName, styleValue); + } else if (styleValue) { + style[styleName] = styleValue; + } else { + var expansion = hasShorthandPropertyBug && CSSProperty.shorthandPropertyExpansions[styleName]; + if (expansion) { + // Shorthand property that IE8 won't like unsetting, so unset each + // component to placate it + for (var individualStyleName in expansion) { + style[individualStyleName] = ''; + } + } else { + style[styleName] = ''; + } + } + } + } +}; + +module.exports = CSSPropertyOperations; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 257 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + + + +var camelize = __webpack_require__(258); + +var msPattern = /^-ms-/; + +/** + * Camelcases a hyphenated CSS property name, for example: + * + * > camelizeStyleName('background-color') + * < "backgroundColor" + * > camelizeStyleName('-moz-transition') + * < "MozTransition" + * > camelizeStyleName('-ms-transition') + * < "msTransition" + * + * As Andi Smith suggests + * (http://www.andismith.com/blog/2012/02/modernizr-prefixed/), an `-ms` prefix + * is converted to lowercase `ms`. + * + * @param {string} string + * @return {string} + */ +function camelizeStyleName(string) { + return camelize(string.replace(msPattern, 'ms-')); +} + +module.exports = camelizeStyleName; + +/***/ }), +/* 258 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var _hyphenPattern = /-(.)/g; + +/** + * Camelcases a hyphenated string, for example: + * + * > camelize('background-color') + * < "backgroundColor" + * + * @param {string} string + * @return {string} + */ +function camelize(string) { + return string.replace(_hyphenPattern, function (_, character) { + return character.toUpperCase(); + }); +} + +module.exports = camelize; + +/***/ }), +/* 259 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var CSSProperty = __webpack_require__(137); +var warning = __webpack_require__(3); + +var isUnitlessNumber = CSSProperty.isUnitlessNumber; +var styleWarnings = {}; + +/** + * Convert a value into the proper css writable value. The style name `name` + * should be logical (no hyphens), as specified + * in `CSSProperty.isUnitlessNumber`. + * + * @param {string} name CSS property name such as `topMargin`. + * @param {*} value CSS property value such as `10px`. + * @param {ReactDOMComponent} component + * @return {string} Normalized style value with dimensions applied. + */ +function dangerousStyleValue(name, value, component, isCustomProperty) { + // Note that we've removed escapeTextForBrowser() calls here since the + // whole string will be escaped when the attribute is injected into + // the markup. If you provide unsafe user data here they can inject + // arbitrary CSS which may be problematic (I couldn't repro this): + // https://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet + // http://www.thespanner.co.uk/2007/11/26/ultimate-xss-css-injection/ + // This is not an XSS hole but instead a potential CSS injection issue + // which has lead to a greater discussion about how we're going to + // trust URLs moving forward. See #2115901 + + var isEmpty = value == null || typeof value === 'boolean' || value === ''; + if (isEmpty) { + return ''; + } + + var isNonNumeric = isNaN(value); + if (isCustomProperty || isNonNumeric || value === 0 || isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name]) { + return '' + value; // cast to string + } + + if (typeof value === 'string') { + if (process.env.NODE_ENV !== 'production') { + // Allow '0' to pass through without warning. 0 is already special and + // doesn't require units, so we don't need to warn about it. + if (component && value !== '0') { + var owner = component._currentElement._owner; + var ownerName = owner ? owner.getName() : null; + if (ownerName && !styleWarnings[ownerName]) { + styleWarnings[ownerName] = {}; + } + var warned = false; + if (ownerName) { + var warnings = styleWarnings[ownerName]; + warned = warnings[name]; + if (!warned) { + warnings[name] = true; + } + } + if (!warned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'a `%s` tag (owner: `%s`) was passed a numeric string value ' + 'for CSS property `%s` (value: `%s`) which will be treated ' + 'as a unitless number in a future version of React.', component._currentElement.type, ownerName || 'unknown', name, value) : void 0; + } + } + } + value = value.trim(); + } + return value + 'px'; +} + +module.exports = dangerousStyleValue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 260 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + + + +var hyphenate = __webpack_require__(261); + +var msPattern = /^ms-/; + +/** + * Hyphenates a camelcased CSS property name, for example: + * + * > hyphenateStyleName('backgroundColor') + * < "background-color" + * > hyphenateStyleName('MozTransition') + * < "-moz-transition" + * > hyphenateStyleName('msTransition') + * < "-ms-transition" + * + * As Modernizr suggests (http://modernizr.com/docs/#prefixed), an `ms` prefix + * is converted to `-ms-`. + * + * @param {string} string + * @return {string} + */ +function hyphenateStyleName(string) { + return hyphenate(string).replace(msPattern, '-ms-'); +} + +module.exports = hyphenateStyleName; + +/***/ }), +/* 261 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var _uppercasePattern = /([A-Z])/g; + +/** + * Hyphenates a camelcased string, for example: + * + * > hyphenate('backgroundColor') + * < "background-color" + * + * For CSS style names, use `hyphenateStyleName` instead which works properly + * with all vendor prefixes, including `ms`. + * + * @param {string} string + * @return {string} + */ +function hyphenate(string) { + return string.replace(_uppercasePattern, '-$1').toLowerCase(); +} + +module.exports = hyphenate; + +/***/ }), +/* 262 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + * @typechecks static-only + */ + + + +/** + * Memoizes the return value of a function that accepts one string argument. + */ + +function memoizeStringOnly(callback) { + var cache = {}; + return function (string) { + if (!cache.hasOwnProperty(string)) { + cache[string] = callback.call(this, string); + } + return cache[string]; + }; +} + +module.exports = memoizeStringOnly; + +/***/ }), +/* 263 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var escapeTextContentForBrowser = __webpack_require__(61); + +/** + * Escapes attribute value to prevent scripting attacks. + * + * @param {*} value Value to escape. + * @return {string} An escaped string. + */ +function quoteAttributeValueForBrowser(value) { + return '"' + escapeTextContentForBrowser(value) + '"'; +} + +module.exports = quoteAttributeValueForBrowser; + +/***/ }), +/* 264 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPluginHub = __webpack_require__(46); + +function runEventQueueInBatch(events) { + EventPluginHub.enqueueEvents(events); + EventPluginHub.processEventQueue(false); +} + +var ReactEventEmitterMixin = { + /** + * Streams a fired top-level event to `EventPluginHub` where plugins have the + * opportunity to create `ReactEvent`s to be dispatched. + */ + handleTopLevel: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var events = EventPluginHub.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); + runEventQueueInBatch(events); + } +}; + +module.exports = ReactEventEmitterMixin; + +/***/ }), +/* 265 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +/** + * Generate a mapping of standard vendor prefixes using the defined style property and event name. + * + * @param {string} styleProp + * @param {string} eventName + * @returns {object} + */ +function makePrefixMap(styleProp, eventName) { + var prefixes = {}; + + prefixes[styleProp.toLowerCase()] = eventName.toLowerCase(); + prefixes['Webkit' + styleProp] = 'webkit' + eventName; + prefixes['Moz' + styleProp] = 'moz' + eventName; + prefixes['ms' + styleProp] = 'MS' + eventName; + prefixes['O' + styleProp] = 'o' + eventName.toLowerCase(); + + return prefixes; +} + +/** + * A list of event names to a configurable list of vendor prefixes. + */ +var vendorPrefixes = { + animationend: makePrefixMap('Animation', 'AnimationEnd'), + animationiteration: makePrefixMap('Animation', 'AnimationIteration'), + animationstart: makePrefixMap('Animation', 'AnimationStart'), + transitionend: makePrefixMap('Transition', 'TransitionEnd') +}; + +/** + * Event names that have already been detected and prefixed (if applicable). + */ +var prefixedEventNames = {}; + +/** + * Element to check for prefixes on. + */ +var style = {}; + +/** + * Bootstrap if a DOM exists. + */ +if (ExecutionEnvironment.canUseDOM) { + style = document.createElement('div').style; + + // On some platforms, in particular some releases of Android 4.x, + // the un-prefixed "animation" and "transition" properties are defined on the + // style object but the events that fire will still be prefixed, so we need + // to check if the un-prefixed events are usable, and if not remove them from the map. + if (!('AnimationEvent' in window)) { + delete vendorPrefixes.animationend.animation; + delete vendorPrefixes.animationiteration.animation; + delete vendorPrefixes.animationstart.animation; + } + + // Same as above + if (!('TransitionEvent' in window)) { + delete vendorPrefixes.transitionend.transition; + } +} + +/** + * Attempts to determine the correct vendor prefixed event name. + * + * @param {string} eventName + * @returns {string} + */ +function getVendorPrefixedEventName(eventName) { + if (prefixedEventNames[eventName]) { + return prefixedEventNames[eventName]; + } else if (!vendorPrefixes[eventName]) { + return eventName; + } + + var prefixMap = vendorPrefixes[eventName]; + + for (var styleProp in prefixMap) { + if (prefixMap.hasOwnProperty(styleProp) && styleProp in style) { + return prefixedEventNames[eventName] = prefixMap[styleProp]; + } + } + + return ''; +} + +module.exports = getVendorPrefixedEventName; + +/***/ }), +/* 266 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var DOMPropertyOperations = __webpack_require__(138); +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var didWarnValueLink = false; +var didWarnCheckedLink = false; +var didWarnValueDefaultValue = false; +var didWarnCheckedDefaultChecked = false; +var didWarnControlledToUncontrolled = false; +var didWarnUncontrolledToControlled = false; + +function forceUpdateIfMounted() { + if (this._rootNodeID) { + // DOM component is still mounted; update + ReactDOMInput.updateWrapper(this); + } +} + +function isControlled(props) { + var usesChecked = props.type === 'checkbox' || props.type === 'radio'; + return usesChecked ? props.checked != null : props.value != null; +} + +/** + * Implements an <input> host component that allows setting these optional + * props: `checked`, `value`, `defaultChecked`, and `defaultValue`. + * + * If `checked` or `value` are not supplied (or null/undefined), user actions + * that affect the checked state or value will trigger updates to the element. + * + * If they are supplied (and not null/undefined), the rendered element will not + * trigger updates to the element. Instead, the props must change in order for + * the rendered element to be updated. + * + * The rendered element will be initialized as unchecked (or `defaultChecked`) + * with an empty value (or `defaultValue`). + * + * @see http://www.w3.org/TR/2012/WD-html5-20121025/the-input-element.html + */ +var ReactDOMInput = { + getHostProps: function (inst, props) { + var value = LinkedValueUtils.getValue(props); + var checked = LinkedValueUtils.getChecked(props); + + var hostProps = _assign({ + // Make sure we set .type before any other properties (setting .value + // before .type means .value is lost in IE11 and below) + type: undefined, + // Make sure we set .step before .value (setting .value before .step + // means .value is rounded on mount, based upon step precision) + step: undefined, + // Make sure we set .min & .max before .value (to ensure proper order + // in corner cases such as min or max deriving from value, e.g. Issue #7170) + min: undefined, + max: undefined + }, props, { + defaultChecked: undefined, + defaultValue: undefined, + value: value != null ? value : inst._wrapperState.initialValue, + checked: checked != null ? checked : inst._wrapperState.initialChecked, + onChange: inst._wrapperState.onChange + }); + + return hostProps; + }, + + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + LinkedValueUtils.checkPropTypes('input', props, inst._currentElement._owner); + + var owner = inst._currentElement._owner; + + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + if (props.checkedLink !== undefined && !didWarnCheckedLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`checkedLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnCheckedLink = true; + } + if (props.checked !== undefined && props.defaultChecked !== undefined && !didWarnCheckedDefaultChecked) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both checked and defaultChecked props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnCheckedDefaultChecked = true; + } + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both value and defaultValue props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnValueDefaultValue = true; + } + } + + var defaultValue = props.defaultValue; + inst._wrapperState = { + initialChecked: props.checked != null ? props.checked : props.defaultChecked, + initialValue: props.value != null ? props.value : defaultValue, + listeners: null, + onChange: _handleChange.bind(inst), + controlled: isControlled(props) + }; + }, + + updateWrapper: function (inst) { + var props = inst._currentElement.props; + + if (process.env.NODE_ENV !== 'production') { + var controlled = isControlled(props); + var owner = inst._currentElement._owner; + + if (!inst._wrapperState.controlled && controlled && !didWarnUncontrolledToControlled) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing an uncontrolled input of type %s to be controlled. ' + 'Input elements should not switch from uncontrolled to controlled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnUncontrolledToControlled = true; + } + if (inst._wrapperState.controlled && !controlled && !didWarnControlledToUncontrolled) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing a controlled input of type %s to be uncontrolled. ' + 'Input elements should not switch from controlled to uncontrolled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnControlledToUncontrolled = true; + } + } + + // TODO: Shouldn't this be getChecked(props)? + var checked = props.checked; + if (checked != null) { + DOMPropertyOperations.setValueForProperty(ReactDOMComponentTree.getNodeFromInstance(inst), 'checked', checked || false); + } + + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var value = LinkedValueUtils.getValue(props); + if (value != null) { + if (value === 0 && node.value === '') { + node.value = '0'; + // Note: IE9 reports a number inputs as 'text', so check props instead. + } else if (props.type === 'number') { + // Simulate `input.valueAsNumber`. IE9 does not support it + var valueAsNumber = parseFloat(node.value, 10) || 0; + + if ( + // eslint-disable-next-line + value != valueAsNumber || + // eslint-disable-next-line + value == valueAsNumber && node.value != value) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + node.value = '' + value; + } + } else if (node.value !== '' + value) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + node.value = '' + value; + } + } else { + if (props.value == null && props.defaultValue != null) { + // In Chrome, assigning defaultValue to certain input types triggers input validation. + // For number inputs, the display value loses trailing decimal points. For email inputs, + // Chrome raises "The specified value <x> is not a valid email address". + // + // Here we check to see if the defaultValue has actually changed, avoiding these problems + // when the user is inputting text + // + // https://github.com/facebook/react/issues/7253 + if (node.defaultValue !== '' + props.defaultValue) { + node.defaultValue = '' + props.defaultValue; + } + } + if (props.checked == null && props.defaultChecked != null) { + node.defaultChecked = !!props.defaultChecked; + } + } + }, + + postMountWrapper: function (inst) { + var props = inst._currentElement.props; + + // This is in postMount because we need access to the DOM node, which is not + // available until after the component has mounted. + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + + // Detach value from defaultValue. We won't do anything if we're working on + // submit or reset inputs as those values & defaultValues are linked. They + // are not resetable nodes so this operation doesn't matter and actually + // removes browser-default values (eg "Submit Query") when no value is + // provided. + + switch (props.type) { + case 'submit': + case 'reset': + break; + case 'color': + case 'date': + case 'datetime': + case 'datetime-local': + case 'month': + case 'time': + case 'week': + // This fixes the no-show issue on iOS Safari and Android Chrome: + // https://github.com/facebook/react/issues/7233 + node.value = ''; + node.value = node.defaultValue; + break; + default: + node.value = node.value; + break; + } + + // Normally, we'd just do `node.checked = node.checked` upon initial mount, less this bug + // this is needed to work around a chrome bug where setting defaultChecked + // will sometimes influence the value of checked (even after detachment). + // Reference: https://bugs.chromium.org/p/chromium/issues/detail?id=608416 + // We need to temporarily unset name to avoid disrupting radio button groups. + var name = node.name; + if (name !== '') { + node.name = ''; + } + node.defaultChecked = !node.defaultChecked; + node.defaultChecked = !node.defaultChecked; + if (name !== '') { + node.name = name; + } + } +}; + +function _handleChange(event) { + var props = this._currentElement.props; + + var returnValue = LinkedValueUtils.executeOnChange(props, event); + + // Here we use asap to wait until all updates have propagated, which + // is important when using controlled components within layers: + // https://github.com/facebook/react/issues/1698 + ReactUpdates.asap(forceUpdateIfMounted, this); + + var name = props.name; + if (props.type === 'radio' && name != null) { + var rootNode = ReactDOMComponentTree.getNodeFromInstance(this); + var queryRoot = rootNode; + + while (queryRoot.parentNode) { + queryRoot = queryRoot.parentNode; + } + + // If `rootNode.form` was non-null, then we could try `form.elements`, + // but that sometimes behaves strangely in IE8. We could also try using + // `form.getElementsByName`, but that will only return direct children + // and won't include inputs that use the HTML5 `form=` attribute. Since + // the input might not even be in a form, let's just use the global + // `querySelectorAll` to ensure we don't miss anything. + var group = queryRoot.querySelectorAll('input[name=' + JSON.stringify('' + name) + '][type="radio"]'); + + for (var i = 0; i < group.length; i++) { + var otherNode = group[i]; + if (otherNode === rootNode || otherNode.form !== rootNode.form) { + continue; + } + // This will throw if radio buttons rendered by different copies of React + // and the same name are rendered into the same form (same as #1939). + // That's probably okay; we don't support it just as we don't support + // mixing React radio buttons with non-React ones. + var otherInstance = ReactDOMComponentTree.getInstanceFromNode(otherNode); + !otherInstance ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOMInput: Mixing React and non-React radio inputs with the same `name` is not supported.') : _prodInvariant('90') : void 0; + // If this is a controlled radio button group, forcing the input that + // was previously checked to update will cause it to be come re-checked + // as appropriate. + ReactUpdates.asap(forceUpdateIfMounted, otherInstance); + } + } + + return returnValue; +} + +module.exports = ReactDOMInput; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 267 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var React = __webpack_require__(36); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMSelect = __webpack_require__(140); + +var warning = __webpack_require__(3); +var didWarnInvalidOptionChildren = false; + +function flattenChildren(children) { + var content = ''; + + // Flatten children and warn if they aren't strings or numbers; + // invalid types are ignored. + React.Children.forEach(children, function (child) { + if (child == null) { + return; + } + if (typeof child === 'string' || typeof child === 'number') { + content += child; + } else if (!didWarnInvalidOptionChildren) { + didWarnInvalidOptionChildren = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Only strings and numbers are supported as <option> children.') : void 0; + } + }); + + return content; +} + +/** + * Implements an <option> host component that warns when `selected` is set. + */ +var ReactDOMOption = { + mountWrapper: function (inst, props, hostParent) { + // TODO (yungsters): Remove support for `selected` in <option>. + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(props.selected == null, 'Use the `defaultValue` or `value` props on <select> instead of ' + 'setting `selected` on <option>.') : void 0; + } + + // Look up whether this option is 'selected' + var selectValue = null; + if (hostParent != null) { + var selectParent = hostParent; + + if (selectParent._tag === 'optgroup') { + selectParent = selectParent._hostParent; + } + + if (selectParent != null && selectParent._tag === 'select') { + selectValue = ReactDOMSelect.getSelectValueContext(selectParent); + } + } + + // If the value is null (e.g., no specified value or after initial mount) + // or missing (e.g., for <datalist>), we don't change props.selected + var selected = null; + if (selectValue != null) { + var value; + if (props.value != null) { + value = props.value + ''; + } else { + value = flattenChildren(props.children); + } + selected = false; + if (Array.isArray(selectValue)) { + // multiple + for (var i = 0; i < selectValue.length; i++) { + if ('' + selectValue[i] === value) { + selected = true; + break; + } + } + } else { + selected = '' + selectValue === value; + } + } + + inst._wrapperState = { selected: selected }; + }, + + postMountWrapper: function (inst) { + // value="" should make a value attribute (#6219) + var props = inst._currentElement.props; + if (props.value != null) { + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + node.setAttribute('value', props.value); + } + }, + + getHostProps: function (inst, props) { + var hostProps = _assign({ selected: undefined, children: undefined }, props); + + // Read state only from initial mount because <select> updates value + // manually; we need the initial state only for server rendering + if (inst._wrapperState.selected != null) { + hostProps.selected = inst._wrapperState.selected; + } + + var content = flattenChildren(props.children); + + if (content) { + hostProps.children = content; + } + + return hostProps; + } +}; + +module.exports = ReactDOMOption; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 268 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var didWarnValueLink = false; +var didWarnValDefaultVal = false; + +function forceUpdateIfMounted() { + if (this._rootNodeID) { + // DOM component is still mounted; update + ReactDOMTextarea.updateWrapper(this); + } +} + +/** + * Implements a <textarea> host component that allows setting `value`, and + * `defaultValue`. This differs from the traditional DOM API because value is + * usually set as PCDATA children. + * + * If `value` is not supplied (or null/undefined), user actions that affect the + * value will trigger updates to the element. + * + * If `value` is supplied (and not null/undefined), the rendered element will + * not trigger updates to the element. Instead, the `value` prop must change in + * order for the rendered element to be updated. + * + * The rendered element will be initialized with an empty value, the prop + * `defaultValue` if specified, or the children content (deprecated). + */ +var ReactDOMTextarea = { + getHostProps: function (inst, props) { + !(props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`dangerouslySetInnerHTML` does not make sense on <textarea>.') : _prodInvariant('91') : void 0; + + // Always set children to the same thing. In IE9, the selection range will + // get reset if `textContent` is mutated. We could add a check in setTextContent + // to only set the value if/when the value differs from the node value (which would + // completely solve this IE9 bug), but Sebastian+Ben seemed to like this solution. + // The value can be a boolean or object so that's why it's forced to be a string. + var hostProps = _assign({}, props, { + value: undefined, + defaultValue: undefined, + children: '' + inst._wrapperState.initialValue, + onChange: inst._wrapperState.onChange + }); + + return hostProps; + }, + + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + LinkedValueUtils.checkPropTypes('textarea', props, inst._currentElement._owner); + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `textarea` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValDefaultVal) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Textarea elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; + didWarnValDefaultVal = true; + } + } + + var value = LinkedValueUtils.getValue(props); + var initialValue = value; + + // Only bother fetching default value if we're going to use it + if (value == null) { + var defaultValue = props.defaultValue; + // TODO (yungsters): Remove support for children content in <textarea>. + var children = props.children; + if (children != null) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(false, 'Use the `defaultValue` or `value` props instead of setting ' + 'children on <textarea>.') : void 0; + } + !(defaultValue == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'If you supply `defaultValue` on a <textarea>, do not pass children.') : _prodInvariant('92') : void 0; + if (Array.isArray(children)) { + !(children.length <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, '<textarea> can only have at most one child.') : _prodInvariant('93') : void 0; + children = children[0]; + } + + defaultValue = '' + children; + } + if (defaultValue == null) { + defaultValue = ''; + } + initialValue = defaultValue; + } + + inst._wrapperState = { + initialValue: '' + initialValue, + listeners: null, + onChange: _handleChange.bind(inst) + }; + }, + + updateWrapper: function (inst) { + var props = inst._currentElement.props; + + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var value = LinkedValueUtils.getValue(props); + if (value != null) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + var newValue = '' + value; + + // To avoid side effects (such as losing text selection), only set value if changed + if (newValue !== node.value) { + node.value = newValue; + } + if (props.defaultValue == null) { + node.defaultValue = newValue; + } + } + if (props.defaultValue != null) { + node.defaultValue = props.defaultValue; + } + }, + + postMountWrapper: function (inst) { + // This is in postMount because we need access to the DOM node, which is not + // available until after the component has mounted. + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var textContent = node.textContent; + + // Only set node.value if textContent is equal to the expected + // initial value. In IE10/IE11 there is a bug where the placeholder attribute + // will populate textContent as well. + // https://developer.microsoft.com/microsoft-edge/platform/issues/101525/ + if (textContent === inst._wrapperState.initialValue) { + node.value = textContent; + } + } +}; + +function _handleChange(event) { + var props = this._currentElement.props; + var returnValue = LinkedValueUtils.executeOnChange(props, event); + ReactUpdates.asap(forceUpdateIfMounted, this); + return returnValue; +} + +module.exports = ReactDOMTextarea; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 269 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactComponentEnvironment = __webpack_require__(86); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); + +var ReactCurrentOwner = __webpack_require__(22); +var ReactReconciler = __webpack_require__(38); +var ReactChildReconciler = __webpack_require__(270); + +var emptyFunction = __webpack_require__(18); +var flattenChildren = __webpack_require__(277); +var invariant = __webpack_require__(2); + +/** + * Make an update for markup to be rendered and inserted at a supplied index. + * + * @param {string} markup Markup that renders into an element. + * @param {number} toIndex Destination index. + * @private + */ +function makeInsertMarkup(markup, afterNode, toIndex) { + // NOTE: Null values reduce hidden classes. + return { + type: 'INSERT_MARKUP', + content: markup, + fromIndex: null, + fromNode: null, + toIndex: toIndex, + afterNode: afterNode + }; +} + +/** + * Make an update for moving an existing element to another index. + * + * @param {number} fromIndex Source index of the existing element. + * @param {number} toIndex Destination index of the element. + * @private + */ +function makeMove(child, afterNode, toIndex) { + // NOTE: Null values reduce hidden classes. + return { + type: 'MOVE_EXISTING', + content: null, + fromIndex: child._mountIndex, + fromNode: ReactReconciler.getHostNode(child), + toIndex: toIndex, + afterNode: afterNode + }; +} + +/** + * Make an update for removing an element at an index. + * + * @param {number} fromIndex Index of the element to remove. + * @private + */ +function makeRemove(child, node) { + // NOTE: Null values reduce hidden classes. + return { + type: 'REMOVE_NODE', + content: null, + fromIndex: child._mountIndex, + fromNode: node, + toIndex: null, + afterNode: null + }; +} + +/** + * Make an update for setting the markup of a node. + * + * @param {string} markup Markup that renders into an element. + * @private + */ +function makeSetMarkup(markup) { + // NOTE: Null values reduce hidden classes. + return { + type: 'SET_MARKUP', + content: markup, + fromIndex: null, + fromNode: null, + toIndex: null, + afterNode: null + }; +} + +/** + * Make an update for setting the text content. + * + * @param {string} textContent Text content to set. + * @private + */ +function makeTextContent(textContent) { + // NOTE: Null values reduce hidden classes. + return { + type: 'TEXT_CONTENT', + content: textContent, + fromIndex: null, + fromNode: null, + toIndex: null, + afterNode: null + }; +} + +/** + * Push an update, if any, onto the queue. Creates a new queue if none is + * passed and always returns the queue. Mutative. + */ +function enqueue(queue, update) { + if (update) { + queue = queue || []; + queue.push(update); + } + return queue; +} + +/** + * Processes any enqueued updates. + * + * @private + */ +function processQueue(inst, updateQueue) { + ReactComponentEnvironment.processChildrenUpdates(inst, updateQueue); +} + +var setChildrenForInstrumentation = emptyFunction; +if (process.env.NODE_ENV !== 'production') { + var getDebugID = function (inst) { + if (!inst._debugID) { + // Check for ART-like instances. TODO: This is silly/gross. + var internal; + if (internal = ReactInstanceMap.get(inst)) { + inst = internal; + } + } + return inst._debugID; + }; + setChildrenForInstrumentation = function (children) { + var debugID = getDebugID(this); + // TODO: React Native empty components are also multichild. + // This means they still get into this method but don't have _debugID. + if (debugID !== 0) { + ReactInstrumentation.debugTool.onSetChildren(debugID, children ? Object.keys(children).map(function (key) { + return children[key]._debugID; + }) : []); + } + }; +} + +/** + * ReactMultiChild are capable of reconciling multiple children. + * + * @class ReactMultiChild + * @internal + */ +var ReactMultiChild = { + /** + * Provides common functionality for components that must reconcile multiple + * children. This is used by `ReactDOMComponent` to mount, update, and + * unmount child components. + * + * @lends {ReactMultiChild.prototype} + */ + Mixin: { + _reconcilerInstantiateChildren: function (nestedChildren, transaction, context) { + if (process.env.NODE_ENV !== 'production') { + var selfDebugID = getDebugID(this); + if (this._currentElement) { + try { + ReactCurrentOwner.current = this._currentElement._owner; + return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context, selfDebugID); + } finally { + ReactCurrentOwner.current = null; + } + } + } + return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context); + }, + + _reconcilerUpdateChildren: function (prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context) { + var nextChildren; + var selfDebugID = 0; + if (process.env.NODE_ENV !== 'production') { + selfDebugID = getDebugID(this); + if (this._currentElement) { + try { + ReactCurrentOwner.current = this._currentElement._owner; + nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); + } finally { + ReactCurrentOwner.current = null; + } + ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); + return nextChildren; + } + } + nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); + ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); + return nextChildren; + }, + + /** + * Generates a "mount image" for each of the supplied children. In the case + * of `ReactDOMComponent`, a mount image is a string of markup. + * + * @param {?object} nestedChildren Nested child maps. + * @return {array} An array of mounted representations. + * @internal + */ + mountChildren: function (nestedChildren, transaction, context) { + var children = this._reconcilerInstantiateChildren(nestedChildren, transaction, context); + this._renderedChildren = children; + + var mountImages = []; + var index = 0; + for (var name in children) { + if (children.hasOwnProperty(name)) { + var child = children[name]; + var selfDebugID = 0; + if (process.env.NODE_ENV !== 'production') { + selfDebugID = getDebugID(this); + } + var mountImage = ReactReconciler.mountComponent(child, transaction, this, this._hostContainerInfo, context, selfDebugID); + child._mountIndex = index++; + mountImages.push(mountImage); + } + } + + if (process.env.NODE_ENV !== 'production') { + setChildrenForInstrumentation.call(this, children); + } + + return mountImages; + }, + + /** + * Replaces any rendered children with a text content string. + * + * @param {string} nextContent String of content. + * @internal + */ + updateTextContent: function (nextContent) { + var prevChildren = this._renderedChildren; + // Remove any rendered children. + ReactChildReconciler.unmountChildren(prevChildren, false); + for (var name in prevChildren) { + if (prevChildren.hasOwnProperty(name)) { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; + } + } + // Set new text content. + var updates = [makeTextContent(nextContent)]; + processQueue(this, updates); + }, + + /** + * Replaces any rendered children with a markup string. + * + * @param {string} nextMarkup String of markup. + * @internal + */ + updateMarkup: function (nextMarkup) { + var prevChildren = this._renderedChildren; + // Remove any rendered children. + ReactChildReconciler.unmountChildren(prevChildren, false); + for (var name in prevChildren) { + if (prevChildren.hasOwnProperty(name)) { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; + } + } + var updates = [makeSetMarkup(nextMarkup)]; + processQueue(this, updates); + }, + + /** + * Updates the rendered children with new children. + * + * @param {?object} nextNestedChildrenElements Nested child element maps. + * @param {ReactReconcileTransaction} transaction + * @internal + */ + updateChildren: function (nextNestedChildrenElements, transaction, context) { + // Hook used by React ART + this._updateChildren(nextNestedChildrenElements, transaction, context); + }, + + /** + * @param {?object} nextNestedChildrenElements Nested child element maps. + * @param {ReactReconcileTransaction} transaction + * @final + * @protected + */ + _updateChildren: function (nextNestedChildrenElements, transaction, context) { + var prevChildren = this._renderedChildren; + var removedNodes = {}; + var mountImages = []; + var nextChildren = this._reconcilerUpdateChildren(prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context); + if (!nextChildren && !prevChildren) { + return; + } + var updates = null; + var name; + // `nextIndex` will increment for each child in `nextChildren`, but + // `lastIndex` will be the last index visited in `prevChildren`. + var nextIndex = 0; + var lastIndex = 0; + // `nextMountIndex` will increment for each newly mounted child. + var nextMountIndex = 0; + var lastPlacedNode = null; + for (name in nextChildren) { + if (!nextChildren.hasOwnProperty(name)) { + continue; + } + var prevChild = prevChildren && prevChildren[name]; + var nextChild = nextChildren[name]; + if (prevChild === nextChild) { + updates = enqueue(updates, this.moveChild(prevChild, lastPlacedNode, nextIndex, lastIndex)); + lastIndex = Math.max(prevChild._mountIndex, lastIndex); + prevChild._mountIndex = nextIndex; + } else { + if (prevChild) { + // Update `lastIndex` before `_mountIndex` gets unset by unmounting. + lastIndex = Math.max(prevChild._mountIndex, lastIndex); + // The `removedNodes` loop below will actually remove the child. + } + // The child must be instantiated before it's mounted. + updates = enqueue(updates, this._mountChildAtIndex(nextChild, mountImages[nextMountIndex], lastPlacedNode, nextIndex, transaction, context)); + nextMountIndex++; + } + nextIndex++; + lastPlacedNode = ReactReconciler.getHostNode(nextChild); + } + // Remove children that are no longer present. + for (name in removedNodes) { + if (removedNodes.hasOwnProperty(name)) { + updates = enqueue(updates, this._unmountChild(prevChildren[name], removedNodes[name])); + } + } + if (updates) { + processQueue(this, updates); + } + this._renderedChildren = nextChildren; + + if (process.env.NODE_ENV !== 'production') { + setChildrenForInstrumentation.call(this, nextChildren); + } + }, + + /** + * Unmounts all rendered children. This should be used to clean up children + * when this component is unmounted. It does not actually perform any + * backend operations. + * + * @internal + */ + unmountChildren: function (safely) { + var renderedChildren = this._renderedChildren; + ReactChildReconciler.unmountChildren(renderedChildren, safely); + this._renderedChildren = null; + }, + + /** + * Moves a child component to the supplied index. + * + * @param {ReactComponent} child Component to move. + * @param {number} toIndex Destination index of the element. + * @param {number} lastIndex Last index visited of the siblings of `child`. + * @protected + */ + moveChild: function (child, afterNode, toIndex, lastIndex) { + // If the index of `child` is less than `lastIndex`, then it needs to + // be moved. Otherwise, we do not need to move it because a child will be + // inserted or moved before `child`. + if (child._mountIndex < lastIndex) { + return makeMove(child, afterNode, toIndex); + } + }, + + /** + * Creates a child component. + * + * @param {ReactComponent} child Component to create. + * @param {string} mountImage Markup to insert. + * @protected + */ + createChild: function (child, afterNode, mountImage) { + return makeInsertMarkup(mountImage, afterNode, child._mountIndex); + }, + + /** + * Removes a child component. + * + * @param {ReactComponent} child Child to remove. + * @protected + */ + removeChild: function (child, node) { + return makeRemove(child, node); + }, + + /** + * Mounts a child with the supplied name. + * + * NOTE: This is part of `updateChildren` and is here for readability. + * + * @param {ReactComponent} child Component to mount. + * @param {string} name Name of the child. + * @param {number} index Index at which to insert the child. + * @param {ReactReconcileTransaction} transaction + * @private + */ + _mountChildAtIndex: function (child, mountImage, afterNode, index, transaction, context) { + child._mountIndex = index; + return this.createChild(child, afterNode, mountImage); + }, + + /** + * Unmounts a rendered child. + * + * NOTE: This is part of `updateChildren` and is here for readability. + * + * @param {ReactComponent} child Component to unmount. + * @private + */ + _unmountChild: function (child, node) { + var update = this.removeChild(child, node); + child._mountIndex = null; + return update; + } + } +}; + +module.exports = ReactMultiChild; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 270 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactReconciler = __webpack_require__(38); + +var instantiateReactComponent = __webpack_require__(141); +var KeyEscapeUtils = __webpack_require__(89); +var shouldUpdateReactComponent = __webpack_require__(88); +var traverseAllChildren = __webpack_require__(145); +var warning = __webpack_require__(3); + +var ReactComponentTreeHook; + +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} + +function instantiateChild(childInstances, child, name, selfDebugID) { + // We found a component instance. + var keyUnique = childInstances[name] === undefined; + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (!keyUnique) { + process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; + } + } + if (child != null && keyUnique) { + childInstances[name] = instantiateReactComponent(child, true); + } +} + +/** + * ReactChildReconciler provides helpers for initializing or updating a set of + * children. Its output is suitable for passing it onto ReactMultiChild which + * does diffed reordering and insertion. + */ +var ReactChildReconciler = { + /** + * Generates a "mount image" for each of the supplied children. In the case + * of `ReactDOMComponent`, a mount image is a string of markup. + * + * @param {?object} nestedChildNodes Nested child maps. + * @return {?object} A set of child instances. + * @internal + */ + instantiateChildren: function (nestedChildNodes, transaction, context, selfDebugID) // 0 in production and for roots + { + if (nestedChildNodes == null) { + return null; + } + var childInstances = {}; + + if (process.env.NODE_ENV !== 'production') { + traverseAllChildren(nestedChildNodes, function (childInsts, child, name) { + return instantiateChild(childInsts, child, name, selfDebugID); + }, childInstances); + } else { + traverseAllChildren(nestedChildNodes, instantiateChild, childInstances); + } + return childInstances; + }, + + /** + * Updates the rendered children and returns a new set of children. + * + * @param {?object} prevChildren Previously initialized set of children. + * @param {?object} nextChildren Flat child element maps. + * @param {ReactReconcileTransaction} transaction + * @param {object} context + * @return {?object} A new set of child instances. + * @internal + */ + updateChildren: function (prevChildren, nextChildren, mountImages, removedNodes, transaction, hostParent, hostContainerInfo, context, selfDebugID) // 0 in production and for roots + { + // We currently don't have a way to track moves here but if we use iterators + // instead of for..in we can zip the iterators and check if an item has + // moved. + // TODO: If nothing has changed, return the prevChildren object so that we + // can quickly bailout if nothing has changed. + if (!nextChildren && !prevChildren) { + return; + } + var name; + var prevChild; + for (name in nextChildren) { + if (!nextChildren.hasOwnProperty(name)) { + continue; + } + prevChild = prevChildren && prevChildren[name]; + var prevElement = prevChild && prevChild._currentElement; + var nextElement = nextChildren[name]; + if (prevChild != null && shouldUpdateReactComponent(prevElement, nextElement)) { + ReactReconciler.receiveComponent(prevChild, nextElement, transaction, context); + nextChildren[name] = prevChild; + } else { + if (prevChild) { + removedNodes[name] = ReactReconciler.getHostNode(prevChild); + ReactReconciler.unmountComponent(prevChild, false); + } + // The child must be instantiated before it's mounted. + var nextChildInstance = instantiateReactComponent(nextElement, true); + nextChildren[name] = nextChildInstance; + // Creating mount image now ensures refs are resolved in right order + // (see https://github.com/facebook/react/pull/7101 for explanation). + var nextChildMountImage = ReactReconciler.mountComponent(nextChildInstance, transaction, hostParent, hostContainerInfo, context, selfDebugID); + mountImages.push(nextChildMountImage); + } + } + // Unmount children that are no longer present. + for (name in prevChildren) { + if (prevChildren.hasOwnProperty(name) && !(nextChildren && nextChildren.hasOwnProperty(name))) { + prevChild = prevChildren[name]; + removedNodes[name] = ReactReconciler.getHostNode(prevChild); + ReactReconciler.unmountComponent(prevChild, false); + } + } + }, + + /** + * Unmounts all rendered children. This should be used to clean up children + * when this component is unmounted. + * + * @param {?object} renderedChildren Previously initialized set of children. + * @internal + */ + unmountChildren: function (renderedChildren, safely) { + for (var name in renderedChildren) { + if (renderedChildren.hasOwnProperty(name)) { + var renderedChild = renderedChildren[name]; + ReactReconciler.unmountComponent(renderedChild, safely); + } + } + } +}; + +module.exports = ReactChildReconciler; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 271 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var React = __webpack_require__(36); +var ReactComponentEnvironment = __webpack_require__(86); +var ReactCurrentOwner = __webpack_require__(22); +var ReactErrorUtils = __webpack_require__(78); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactNodeTypes = __webpack_require__(142); +var ReactReconciler = __webpack_require__(38); + +if (process.env.NODE_ENV !== 'production') { + var checkReactTypeSpec = __webpack_require__(272); +} + +var emptyObject = __webpack_require__(56); +var invariant = __webpack_require__(2); +var shallowEqual = __webpack_require__(87); +var shouldUpdateReactComponent = __webpack_require__(88); +var warning = __webpack_require__(3); + +var CompositeTypes = { + ImpureClass: 0, + PureClass: 1, + StatelessFunctional: 2 +}; + +function StatelessComponent(Component) {} +StatelessComponent.prototype.render = function () { + var Component = ReactInstanceMap.get(this)._currentElement.type; + var element = Component(this.props, this.context, this.updater); + warnIfInvalidElement(Component, element); + return element; +}; + +function warnIfInvalidElement(Component, element) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(element === null || element === false || React.isValidElement(element), '%s(...): A valid React element (or null) must be returned. You may have ' + 'returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!Component.childContextTypes, '%s(...): childContextTypes cannot be defined on a functional component.', Component.displayName || Component.name || 'Component') : void 0; + } +} + +function shouldConstruct(Component) { + return !!(Component.prototype && Component.prototype.isReactComponent); +} + +function isPureComponent(Component) { + return !!(Component.prototype && Component.prototype.isPureReactComponent); +} + +// Separated into a function to contain deoptimizations caused by try/finally. +function measureLifeCyclePerf(fn, debugID, timerType) { + if (debugID === 0) { + // Top-level wrappers (see ReactMount) and empty components (see + // ReactDOMEmptyComponent) are invisible to hooks and devtools. + // Both are implementation details that should go away in the future. + return fn(); + } + + ReactInstrumentation.debugTool.onBeginLifeCycleTimer(debugID, timerType); + try { + return fn(); + } finally { + ReactInstrumentation.debugTool.onEndLifeCycleTimer(debugID, timerType); + } +} + +/** + * ------------------ The Life-Cycle of a Composite Component ------------------ + * + * - constructor: Initialization of state. The instance is now retained. + * - componentWillMount + * - render + * - [children's constructors] + * - [children's componentWillMount and render] + * - [children's componentDidMount] + * - componentDidMount + * + * Update Phases: + * - componentWillReceiveProps (only called if parent updated) + * - shouldComponentUpdate + * - componentWillUpdate + * - render + * - [children's constructors or receive props phases] + * - componentDidUpdate + * + * - componentWillUnmount + * - [children's componentWillUnmount] + * - [children destroyed] + * - (destroyed): The instance is now blank, released by React and ready for GC. + * + * ----------------------------------------------------------------------------- + */ + +/** + * An incrementing ID assigned to each component when it is mounted. This is + * used to enforce the order in which `ReactUpdates` updates dirty components. + * + * @private + */ +var nextMountID = 1; + +/** + * @lends {ReactCompositeComponent.prototype} + */ +var ReactCompositeComponent = { + /** + * Base constructor for all composite component. + * + * @param {ReactElement} element + * @final + * @internal + */ + construct: function (element) { + this._currentElement = element; + this._rootNodeID = 0; + this._compositeType = null; + this._instance = null; + this._hostParent = null; + this._hostContainerInfo = null; + + // See ReactUpdateQueue + this._updateBatchNumber = null; + this._pendingElement = null; + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; + + this._renderedNodeType = null; + this._renderedComponent = null; + this._context = null; + this._mountOrder = 0; + this._topLevelWrapper = null; + + // See ReactUpdates and ReactUpdateQueue. + this._pendingCallbacks = null; + + // ComponentWillUnmount shall only be called once + this._calledComponentWillUnmount = false; + + if (process.env.NODE_ENV !== 'production') { + this._warnedAboutRefsInRender = false; + } + }, + + /** + * Initializes the component, renders markup, and registers event listeners. + * + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?object} hostParent + * @param {?object} hostContainerInfo + * @param {?object} context + * @return {?string} Rendered markup to be inserted into the DOM. + * @final + * @internal + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + var _this = this; + + this._context = context; + this._mountOrder = nextMountID++; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; + + var publicProps = this._currentElement.props; + var publicContext = this._processContext(context); + + var Component = this._currentElement.type; + + var updateQueue = transaction.getUpdateQueue(); + + // Initialize the public class + var doConstruct = shouldConstruct(Component); + var inst = this._constructComponent(doConstruct, publicProps, publicContext, updateQueue); + var renderedElement; + + // Support functional components + if (!doConstruct && (inst == null || inst.render == null)) { + renderedElement = inst; + warnIfInvalidElement(Component, renderedElement); + !(inst === null || inst === false || React.isValidElement(inst)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : _prodInvariant('105', Component.displayName || Component.name || 'Component') : void 0; + inst = new StatelessComponent(Component); + this._compositeType = CompositeTypes.StatelessFunctional; + } else { + if (isPureComponent(Component)) { + this._compositeType = CompositeTypes.PureClass; + } else { + this._compositeType = CompositeTypes.ImpureClass; + } + } + + if (process.env.NODE_ENV !== 'production') { + // This will throw later in _renderValidatedComponent, but add an early + // warning now to help debugging + if (inst.render == null) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): No `render` method found on the returned component ' + 'instance: you may have forgotten to define `render`.', Component.displayName || Component.name || 'Component') : void 0; + } + + var propsMutated = inst.props !== publicProps; + var componentName = Component.displayName || Component.name || 'Component'; + + process.env.NODE_ENV !== 'production' ? warning(inst.props === undefined || !propsMutated, '%s(...): When calling super() in `%s`, make sure to pass ' + "up the same props that your component's constructor was passed.", componentName, componentName) : void 0; + } + + // These should be set up in the constructor, but as a convenience for + // simpler class abstractions, we set them up after the fact. + inst.props = publicProps; + inst.context = publicContext; + inst.refs = emptyObject; + inst.updater = updateQueue; + + this._instance = inst; + + // Store a reference from the instance back to the internal representation + ReactInstanceMap.set(inst, this); + + if (process.env.NODE_ENV !== 'production') { + // Since plain JS classes are defined without any special initialization + // logic, we can not catch common errors early. Therefore, we have to + // catch them here, at initialization time, instead. + process.env.NODE_ENV !== 'production' ? warning(!inst.getInitialState || inst.getInitialState.isReactClassApproved || inst.state, 'getInitialState was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Did you mean to define a state property instead?', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.getDefaultProps || inst.getDefaultProps.isReactClassApproved, 'getDefaultProps was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Use a static property to define defaultProps instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.propTypes, 'propTypes was defined as an instance property on %s. Use a static ' + 'property to define propTypes instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.contextTypes, 'contextTypes was defined as an instance property on %s. Use a ' + 'static property to define contextTypes instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentShouldUpdate !== 'function', '%s has a method called ' + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + 'The name is phrased as a question because the function is ' + 'expected to return a value.', this.getName() || 'A component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentDidUnmount !== 'function', '%s has a method called ' + 'componentDidUnmount(). But there is no such lifecycle method. ' + 'Did you mean componentWillUnmount()?', this.getName() || 'A component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentWillRecieveProps !== 'function', '%s has a method called ' + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', this.getName() || 'A component') : void 0; + } + + var initialState = inst.state; + if (initialState === undefined) { + inst.state = initialState = null; + } + !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.state: must be set to an object or null', this.getName() || 'ReactCompositeComponent') : _prodInvariant('106', this.getName() || 'ReactCompositeComponent') : void 0; + + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; + + var markup; + if (inst.unstable_handleError) { + markup = this.performInitialMountWithErrorHandling(renderedElement, hostParent, hostContainerInfo, transaction, context); + } else { + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); + } + + if (inst.componentDidMount) { + if (process.env.NODE_ENV !== 'production') { + transaction.getReactMountReady().enqueue(function () { + measureLifeCyclePerf(function () { + return inst.componentDidMount(); + }, _this._debugID, 'componentDidMount'); + }); + } else { + transaction.getReactMountReady().enqueue(inst.componentDidMount, inst); + } + } + + return markup; + }, + + _constructComponent: function (doConstruct, publicProps, publicContext, updateQueue) { + if (process.env.NODE_ENV !== 'production') { + ReactCurrentOwner.current = this; + try { + return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); + } finally { + ReactCurrentOwner.current = null; + } + } else { + return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); + } + }, + + _constructComponentWithoutOwner: function (doConstruct, publicProps, publicContext, updateQueue) { + var Component = this._currentElement.type; + + if (doConstruct) { + if (process.env.NODE_ENV !== 'production') { + return measureLifeCyclePerf(function () { + return new Component(publicProps, publicContext, updateQueue); + }, this._debugID, 'ctor'); + } else { + return new Component(publicProps, publicContext, updateQueue); + } + } + + // This can still be an instance in case of factory components + // but we'll count this as time spent rendering as the more common case. + if (process.env.NODE_ENV !== 'production') { + return measureLifeCyclePerf(function () { + return Component(publicProps, publicContext, updateQueue); + }, this._debugID, 'render'); + } else { + return Component(publicProps, publicContext, updateQueue); + } + }, + + performInitialMountWithErrorHandling: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { + var markup; + var checkpoint = transaction.checkpoint(); + try { + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); + } catch (e) { + // Roll back to checkpoint, handle error (which may add items to the transaction), and take a new checkpoint + transaction.rollback(checkpoint); + this._instance.unstable_handleError(e); + if (this._pendingStateQueue) { + this._instance.state = this._processPendingState(this._instance.props, this._instance.context); + } + checkpoint = transaction.checkpoint(); + + this._renderedComponent.unmountComponent(true); + transaction.rollback(checkpoint); + + // Try again - we've informed the component about the error, so they can render an error message this time. + // If this throws again, the error will bubble up (and can be caught by a higher error boundary). + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); + } + return markup; + }, + + performInitialMount: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { + var inst = this._instance; + + var debugID = 0; + if (process.env.NODE_ENV !== 'production') { + debugID = this._debugID; + } + + if (inst.componentWillMount) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillMount(); + }, debugID, 'componentWillMount'); + } else { + inst.componentWillMount(); + } + // When mounting, calls to `setState` by `componentWillMount` will set + // `this._pendingStateQueue` without triggering a re-render. + if (this._pendingStateQueue) { + inst.state = this._processPendingState(inst.props, inst.context); + } + } + + // If not a stateless component, we now render + if (renderedElement === undefined) { + renderedElement = this._renderValidatedComponent(); + } + + var nodeType = ReactNodeTypes.getType(renderedElement); + this._renderedNodeType = nodeType; + var child = this._instantiateReactComponent(renderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ + ); + this._renderedComponent = child; + + var markup = ReactReconciler.mountComponent(child, transaction, hostParent, hostContainerInfo, this._processChildContext(context), debugID); + + if (process.env.NODE_ENV !== 'production') { + if (debugID !== 0) { + var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; + ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); + } + } + + return markup; + }, + + getHostNode: function () { + return ReactReconciler.getHostNode(this._renderedComponent); + }, + + /** + * Releases any resources allocated by `mountComponent`. + * + * @final + * @internal + */ + unmountComponent: function (safely) { + if (!this._renderedComponent) { + return; + } + + var inst = this._instance; + + if (inst.componentWillUnmount && !inst._calledComponentWillUnmount) { + inst._calledComponentWillUnmount = true; + + if (safely) { + var name = this.getName() + '.componentWillUnmount()'; + ReactErrorUtils.invokeGuardedCallback(name, inst.componentWillUnmount.bind(inst)); + } else { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillUnmount(); + }, this._debugID, 'componentWillUnmount'); + } else { + inst.componentWillUnmount(); + } + } + } + + if (this._renderedComponent) { + ReactReconciler.unmountComponent(this._renderedComponent, safely); + this._renderedNodeType = null; + this._renderedComponent = null; + this._instance = null; + } + + // Reset pending fields + // Even if this component is scheduled for another update in ReactUpdates, + // it would still be ignored because these fields are reset. + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; + this._pendingCallbacks = null; + this._pendingElement = null; + + // These fields do not really need to be reset since this object is no + // longer accessible. + this._context = null; + this._rootNodeID = 0; + this._topLevelWrapper = null; + + // Delete the reference from the instance to this internal representation + // which allow the internals to be properly cleaned up even if the user + // leaks a reference to the public instance. + ReactInstanceMap.remove(inst); + + // Some existing components rely on inst.props even after they've been + // destroyed (in event handlers). + // TODO: inst.props = null; + // TODO: inst.state = null; + // TODO: inst.context = null; + }, + + /** + * Filters the context object to only contain keys specified in + * `contextTypes` + * + * @param {object} context + * @return {?object} + * @private + */ + _maskContext: function (context) { + var Component = this._currentElement.type; + var contextTypes = Component.contextTypes; + if (!contextTypes) { + return emptyObject; + } + var maskedContext = {}; + for (var contextName in contextTypes) { + maskedContext[contextName] = context[contextName]; + } + return maskedContext; + }, + + /** + * Filters the context object to only contain keys specified in + * `contextTypes`, and asserts that they are valid. + * + * @param {object} context + * @return {?object} + * @private + */ + _processContext: function (context) { + var maskedContext = this._maskContext(context); + if (process.env.NODE_ENV !== 'production') { + var Component = this._currentElement.type; + if (Component.contextTypes) { + this._checkContextTypes(Component.contextTypes, maskedContext, 'context'); + } + } + return maskedContext; + }, + + /** + * @param {object} currentContext + * @return {object} + * @private + */ + _processChildContext: function (currentContext) { + var Component = this._currentElement.type; + var inst = this._instance; + var childContext; + + if (inst.getChildContext) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onBeginProcessingChildContext(); + try { + childContext = inst.getChildContext(); + } finally { + ReactInstrumentation.debugTool.onEndProcessingChildContext(); + } + } else { + childContext = inst.getChildContext(); + } + } + + if (childContext) { + !(typeof Component.childContextTypes === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().', this.getName() || 'ReactCompositeComponent') : _prodInvariant('107', this.getName() || 'ReactCompositeComponent') : void 0; + if (process.env.NODE_ENV !== 'production') { + this._checkContextTypes(Component.childContextTypes, childContext, 'child context'); + } + for (var name in childContext) { + !(name in Component.childContextTypes) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): key "%s" is not defined in childContextTypes.', this.getName() || 'ReactCompositeComponent', name) : _prodInvariant('108', this.getName() || 'ReactCompositeComponent', name) : void 0; + } + return _assign({}, currentContext, childContext); + } + return currentContext; + }, + + /** + * Assert that the context types are valid + * + * @param {object} typeSpecs Map of context field to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @private + */ + _checkContextTypes: function (typeSpecs, values, location) { + if (process.env.NODE_ENV !== 'production') { + checkReactTypeSpec(typeSpecs, values, location, this.getName(), null, this._debugID); + } + }, + + receiveComponent: function (nextElement, transaction, nextContext) { + var prevElement = this._currentElement; + var prevContext = this._context; + + this._pendingElement = null; + + this.updateComponent(transaction, prevElement, nextElement, prevContext, nextContext); + }, + + /** + * If any of `_pendingElement`, `_pendingStateQueue`, or `_pendingForceUpdate` + * is set, update the component. + * + * @param {ReactReconcileTransaction} transaction + * @internal + */ + performUpdateIfNecessary: function (transaction) { + if (this._pendingElement != null) { + ReactReconciler.receiveComponent(this, this._pendingElement, transaction, this._context); + } else if (this._pendingStateQueue !== null || this._pendingForceUpdate) { + this.updateComponent(transaction, this._currentElement, this._currentElement, this._context, this._context); + } else { + this._updateBatchNumber = null; + } + }, + + /** + * Perform an update to a mounted component. The componentWillReceiveProps and + * shouldComponentUpdate methods are called, then (assuming the update isn't + * skipped) the remaining update lifecycle methods are called and the DOM + * representation is updated. + * + * By default, this implements React's rendering and reconciliation algorithm. + * Sophisticated clients may wish to override this. + * + * @param {ReactReconcileTransaction} transaction + * @param {ReactElement} prevParentElement + * @param {ReactElement} nextParentElement + * @internal + * @overridable + */ + updateComponent: function (transaction, prevParentElement, nextParentElement, prevUnmaskedContext, nextUnmaskedContext) { + var inst = this._instance; + !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Attempted to update component `%s` that has already been unmounted (or failed to mount).', this.getName() || 'ReactCompositeComponent') : _prodInvariant('136', this.getName() || 'ReactCompositeComponent') : void 0; + + var willReceive = false; + var nextContext; + + // Determine if the context has changed or not + if (this._context === nextUnmaskedContext) { + nextContext = inst.context; + } else { + nextContext = this._processContext(nextUnmaskedContext); + willReceive = true; + } + + var prevProps = prevParentElement.props; + var nextProps = nextParentElement.props; + + // Not a simple state update but a props update + if (prevParentElement !== nextParentElement) { + willReceive = true; + } + + // An update here will schedule an update but immediately set + // _pendingStateQueue which will ensure that any state updates gets + // immediately reconciled instead of waiting for the next batch. + if (willReceive && inst.componentWillReceiveProps) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillReceiveProps(nextProps, nextContext); + }, this._debugID, 'componentWillReceiveProps'); + } else { + inst.componentWillReceiveProps(nextProps, nextContext); + } + } + + var nextState = this._processPendingState(nextProps, nextContext); + var shouldUpdate = true; + + if (!this._pendingForceUpdate) { + if (inst.shouldComponentUpdate) { + if (process.env.NODE_ENV !== 'production') { + shouldUpdate = measureLifeCyclePerf(function () { + return inst.shouldComponentUpdate(nextProps, nextState, nextContext); + }, this._debugID, 'shouldComponentUpdate'); + } else { + shouldUpdate = inst.shouldComponentUpdate(nextProps, nextState, nextContext); + } + } else { + if (this._compositeType === CompositeTypes.PureClass) { + shouldUpdate = !shallowEqual(prevProps, nextProps) || !shallowEqual(inst.state, nextState); + } + } + } + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(shouldUpdate !== undefined, '%s.shouldComponentUpdate(): Returned undefined instead of a ' + 'boolean value. Make sure to return true or false.', this.getName() || 'ReactCompositeComponent') : void 0; + } + + this._updateBatchNumber = null; + if (shouldUpdate) { + this._pendingForceUpdate = false; + // Will set `this.props`, `this.state` and `this.context`. + this._performComponentUpdate(nextParentElement, nextProps, nextState, nextContext, transaction, nextUnmaskedContext); + } else { + // If it's determined that a component should not update, we still want + // to set props and state but we shortcut the rest of the update. + this._currentElement = nextParentElement; + this._context = nextUnmaskedContext; + inst.props = nextProps; + inst.state = nextState; + inst.context = nextContext; + } + }, + + _processPendingState: function (props, context) { + var inst = this._instance; + var queue = this._pendingStateQueue; + var replace = this._pendingReplaceState; + this._pendingReplaceState = false; + this._pendingStateQueue = null; + + if (!queue) { + return inst.state; + } + + if (replace && queue.length === 1) { + return queue[0]; + } + + var nextState = _assign({}, replace ? queue[0] : inst.state); + for (var i = replace ? 1 : 0; i < queue.length; i++) { + var partial = queue[i]; + _assign(nextState, typeof partial === 'function' ? partial.call(inst, nextState, props, context) : partial); + } + + return nextState; + }, + + /** + * Merges new props and state, notifies delegate methods of update and + * performs update. + * + * @param {ReactElement} nextElement Next element + * @param {object} nextProps Next public object to set as properties. + * @param {?object} nextState Next object to set as state. + * @param {?object} nextContext Next public object to set as context. + * @param {ReactReconcileTransaction} transaction + * @param {?object} unmaskedContext + * @private + */ + _performComponentUpdate: function (nextElement, nextProps, nextState, nextContext, transaction, unmaskedContext) { + var _this2 = this; + + var inst = this._instance; + + var hasComponentDidUpdate = Boolean(inst.componentDidUpdate); + var prevProps; + var prevState; + var prevContext; + if (hasComponentDidUpdate) { + prevProps = inst.props; + prevState = inst.state; + prevContext = inst.context; + } + + if (inst.componentWillUpdate) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillUpdate(nextProps, nextState, nextContext); + }, this._debugID, 'componentWillUpdate'); + } else { + inst.componentWillUpdate(nextProps, nextState, nextContext); + } + } + + this._currentElement = nextElement; + this._context = unmaskedContext; + inst.props = nextProps; + inst.state = nextState; + inst.context = nextContext; + + this._updateRenderedComponent(transaction, unmaskedContext); + + if (hasComponentDidUpdate) { + if (process.env.NODE_ENV !== 'production') { + transaction.getReactMountReady().enqueue(function () { + measureLifeCyclePerf(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), _this2._debugID, 'componentDidUpdate'); + }); + } else { + transaction.getReactMountReady().enqueue(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), inst); + } + } + }, + + /** + * Call the component's `render` method and update the DOM accordingly. + * + * @param {ReactReconcileTransaction} transaction + * @internal + */ + _updateRenderedComponent: function (transaction, context) { + var prevComponentInstance = this._renderedComponent; + var prevRenderedElement = prevComponentInstance._currentElement; + var nextRenderedElement = this._renderValidatedComponent(); + + var debugID = 0; + if (process.env.NODE_ENV !== 'production') { + debugID = this._debugID; + } + + if (shouldUpdateReactComponent(prevRenderedElement, nextRenderedElement)) { + ReactReconciler.receiveComponent(prevComponentInstance, nextRenderedElement, transaction, this._processChildContext(context)); + } else { + var oldHostNode = ReactReconciler.getHostNode(prevComponentInstance); + ReactReconciler.unmountComponent(prevComponentInstance, false); + + var nodeType = ReactNodeTypes.getType(nextRenderedElement); + this._renderedNodeType = nodeType; + var child = this._instantiateReactComponent(nextRenderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ + ); + this._renderedComponent = child; + + var nextMarkup = ReactReconciler.mountComponent(child, transaction, this._hostParent, this._hostContainerInfo, this._processChildContext(context), debugID); + + if (process.env.NODE_ENV !== 'production') { + if (debugID !== 0) { + var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; + ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); + } + } + + this._replaceNodeWithMarkup(oldHostNode, nextMarkup, prevComponentInstance); + } + }, + + /** + * Overridden in shallow rendering. + * + * @protected + */ + _replaceNodeWithMarkup: function (oldHostNode, nextMarkup, prevInstance) { + ReactComponentEnvironment.replaceNodeWithMarkup(oldHostNode, nextMarkup, prevInstance); + }, + + /** + * @protected + */ + _renderValidatedComponentWithoutOwnerOrContext: function () { + var inst = this._instance; + var renderedElement; + + if (process.env.NODE_ENV !== 'production') { + renderedElement = measureLifeCyclePerf(function () { + return inst.render(); + }, this._debugID, 'render'); + } else { + renderedElement = inst.render(); + } + + if (process.env.NODE_ENV !== 'production') { + // We allow auto-mocks to proceed as if they're returning null. + if (renderedElement === undefined && inst.render._isMockFunction) { + // This is probably bad practice. Consider warning here and + // deprecating this convenience. + renderedElement = null; + } + } + + return renderedElement; + }, + + /** + * @private + */ + _renderValidatedComponent: function () { + var renderedElement; + if (process.env.NODE_ENV !== 'production' || this._compositeType !== CompositeTypes.StatelessFunctional) { + ReactCurrentOwner.current = this; + try { + renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); + } finally { + ReactCurrentOwner.current = null; + } + } else { + renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); + } + !( + // TODO: An `isValidNode` function would probably be more appropriate + renderedElement === null || renderedElement === false || React.isValidElement(renderedElement)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.render(): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', this.getName() || 'ReactCompositeComponent') : _prodInvariant('109', this.getName() || 'ReactCompositeComponent') : void 0; + + return renderedElement; + }, + + /** + * Lazily allocates the refs object and stores `component` as `ref`. + * + * @param {string} ref Reference name. + * @param {component} component Component to store as `ref`. + * @final + * @private + */ + attachRef: function (ref, component) { + var inst = this.getPublicInstance(); + !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Stateless function components cannot have refs.') : _prodInvariant('110') : void 0; + var publicComponentInstance = component.getPublicInstance(); + if (process.env.NODE_ENV !== 'production') { + var componentName = component && component.getName ? component.getName() : 'a component'; + process.env.NODE_ENV !== 'production' ? warning(publicComponentInstance != null || component._compositeType !== CompositeTypes.StatelessFunctional, 'Stateless function components cannot be given refs ' + '(See ref "%s" in %s created by %s). ' + 'Attempts to access this ref will fail.', ref, componentName, this.getName()) : void 0; + } + var refs = inst.refs === emptyObject ? inst.refs = {} : inst.refs; + refs[ref] = publicComponentInstance; + }, + + /** + * Detaches a reference name. + * + * @param {string} ref Name to dereference. + * @final + * @private + */ + detachRef: function (ref) { + var refs = this.getPublicInstance().refs; + delete refs[ref]; + }, + + /** + * Get a text description of the component that can be used to identify it + * in error messages. + * @return {string} The name or null. + * @internal + */ + getName: function () { + var type = this._currentElement.type; + var constructor = this._instance && this._instance.constructor; + return type.displayName || constructor && constructor.displayName || type.name || constructor && constructor.name || null; + }, + + /** + * Get the publicly accessible representation of this component - i.e. what + * is exposed by refs and returned by render. Can be null for stateless + * components. + * + * @return {ReactComponent} the public component instance. + * @internal + */ + getPublicInstance: function () { + var inst = this._instance; + if (this._compositeType === CompositeTypes.StatelessFunctional) { + return null; + } + return inst; + }, + + // Stub + _instantiateReactComponent: null +}; + +module.exports = ReactCompositeComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 272 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactPropTypeLocationNames = __webpack_require__(273); +var ReactPropTypesSecret = __webpack_require__(139); + +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +var ReactComponentTreeHook; + +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} + +var loggedTypeFailures = {}; + +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?object} element The React element that is being type-checked + * @param {?number} debugID The React component instance that is being type-checked + * @private + */ +function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var componentStackInfo = ''; + + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (debugID !== null) { + componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); + } else if (element !== null) { + componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); + } + } + + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; + } + } + } +} + +module.exports = checkReactTypeSpec; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 273 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var ReactPropTypeLocationNames = {}; + +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} + +module.exports = ReactPropTypeLocationNames; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 274 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var nextDebugID = 1; + +function getNextDebugID() { + return nextDebugID++; +} + +module.exports = getNextDebugID; + +/***/ }), +/* 275 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +// The Symbol used to tag the ReactElement type. If there is no native Symbol +// nor polyfill, then a plain number is used for performance. + +var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; + +module.exports = REACT_ELEMENT_TYPE; + +/***/ }), +/* 276 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +/* global Symbol */ + +var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; +var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. + +/** + * Returns the iterator method function contained on the iterable object. + * + * Be sure to invoke the function with the iterable as context: + * + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} + */ +function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } +} + +module.exports = getIteratorFn; + +/***/ }), +/* 277 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var KeyEscapeUtils = __webpack_require__(89); +var traverseAllChildren = __webpack_require__(145); +var warning = __webpack_require__(3); + +var ReactComponentTreeHook; + +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} + +/** + * @param {function} traverseContext Context passed through traversal. + * @param {?ReactComponent} child React child component. + * @param {!string} name String name of key path to child. + * @param {number=} selfDebugID Optional debugID of the current internal instance. + */ +function flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID) { + // We found a component instance. + if (traverseContext && typeof traverseContext === 'object') { + var result = traverseContext; + var keyUnique = result[name] === undefined; + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (!keyUnique) { + process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; + } + } + if (keyUnique && child != null) { + result[name] = child; + } + } +} + +/** + * Flattens children that are typically specified as `props.children`. Any null + * children will not be included in the resulting object. + * @return {!object} flattened children keyed by name. + */ +function flattenChildren(children, selfDebugID) { + if (children == null) { + return children; + } + var result = {}; + + if (process.env.NODE_ENV !== 'production') { + traverseAllChildren(children, function (traverseContext, child, name) { + return flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID); + }, result); + } else { + traverseAllChildren(children, flattenSingleChildIntoContext, result); + } + return result; +} + +module.exports = flattenChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 278 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var PooledClass = __webpack_require__(32); +var Transaction = __webpack_require__(58); +var ReactInstrumentation = __webpack_require__(19); +var ReactServerUpdateQueue = __webpack_require__(279); + +/** + * Executed within the scope of the `Transaction` instance. Consider these as + * being member methods, but with an implied ordering while being isolated from + * each other. + */ +var TRANSACTION_WRAPPERS = []; + +if (process.env.NODE_ENV !== 'production') { + TRANSACTION_WRAPPERS.push({ + initialize: ReactInstrumentation.debugTool.onBeginFlush, + close: ReactInstrumentation.debugTool.onEndFlush + }); +} + +var noopCallbackQueue = { + enqueue: function () {} +}; + +/** + * @class ReactServerRenderingTransaction + * @param {boolean} renderToStaticMarkup + */ +function ReactServerRenderingTransaction(renderToStaticMarkup) { + this.reinitializeTransaction(); + this.renderToStaticMarkup = renderToStaticMarkup; + this.useCreateElement = false; + this.updateQueue = new ReactServerUpdateQueue(this); +} + +var Mixin = { + /** + * @see Transaction + * @abstract + * @final + * @return {array} Empty list of operation wrap procedures. + */ + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, + + /** + * @return {object} The queue to collect `onDOMReady` callbacks with. + */ + getReactMountReady: function () { + return noopCallbackQueue; + }, + + /** + * @return {object} The queue to collect React async events. + */ + getUpdateQueue: function () { + return this.updateQueue; + }, + + /** + * `PooledClass` looks for this, and will invoke this before allowing this + * instance to be reused. + */ + destructor: function () {}, + + checkpoint: function () {}, + + rollback: function () {} +}; + +_assign(ReactServerRenderingTransaction.prototype, Transaction, Mixin); + +PooledClass.addPoolingTo(ReactServerRenderingTransaction); + +module.exports = ReactServerRenderingTransaction; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 279 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +var ReactUpdateQueue = __webpack_require__(90); + +var warning = __webpack_require__(3); + +function warnNoop(publicInstance, callerName) { + if (process.env.NODE_ENV !== 'production') { + var constructor = publicInstance.constructor; + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounting component. ' + 'This usually means you called %s() outside componentWillMount() on the server. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; + } +} + +/** + * This is the update queue used for server rendering. + * It delegates to ReactUpdateQueue while server rendering is in progress and + * switches to ReactNoopUpdateQueue after the transaction has completed. + * @class ReactServerUpdateQueue + * @param {Transaction} transaction + */ + +var ReactServerUpdateQueue = function () { + function ReactServerUpdateQueue(transaction) { + _classCallCheck(this, ReactServerUpdateQueue); + + this.transaction = transaction; + } + + /** + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + + + ReactServerUpdateQueue.prototype.isMounted = function isMounted(publicInstance) { + return false; + }; + + /** + * Enqueue a callback that will be executed after all the pending updates + * have processed. + * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @internal + */ + + + ReactServerUpdateQueue.prototype.enqueueCallback = function enqueueCallback(publicInstance, callback, callerName) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueCallback(publicInstance, callback, callerName); + } + }; + + /** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal + */ + + + ReactServerUpdateQueue.prototype.enqueueForceUpdate = function enqueueForceUpdate(publicInstance) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueForceUpdate(publicInstance); + } else { + warnNoop(publicInstance, 'forceUpdate'); + } + }; + + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object|function} completeState Next state. + * @internal + */ + + + ReactServerUpdateQueue.prototype.enqueueReplaceState = function enqueueReplaceState(publicInstance, completeState) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueReplaceState(publicInstance, completeState); + } else { + warnNoop(publicInstance, 'replaceState'); + } + }; + + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object|function} partialState Next partial state to be merged with state. + * @internal + */ + + + ReactServerUpdateQueue.prototype.enqueueSetState = function enqueueSetState(publicInstance, partialState) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueSetState(publicInstance, partialState); + } else { + warnNoop(publicInstance, 'setState'); + } + }; + + return ReactServerUpdateQueue; +}(); + +module.exports = ReactServerUpdateQueue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 280 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var DOMLazyTree = __webpack_require__(39); +var ReactDOMComponentTree = __webpack_require__(10); + +var ReactDOMEmptyComponent = function (instantiate) { + // ReactCompositeComponent uses this: + this._currentElement = null; + // ReactDOMComponentTree uses these: + this._hostNode = null; + this._hostParent = null; + this._hostContainerInfo = null; + this._domID = 0; +}; +_assign(ReactDOMEmptyComponent.prototype, { + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + var domID = hostContainerInfo._idCounter++; + this._domID = domID; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; + + var nodeValue = ' react-empty: ' + this._domID + ' '; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var node = ownerDocument.createComment(nodeValue); + ReactDOMComponentTree.precacheNode(this, node); + return DOMLazyTree(node); + } else { + if (transaction.renderToStaticMarkup) { + // Normally we'd insert a comment node, but since this is a situation + // where React won't take over (static pages), we can simply return + // nothing. + return ''; + } + return '<!--' + nodeValue + '-->'; + } + }, + receiveComponent: function () {}, + getHostNode: function () { + return ReactDOMComponentTree.getNodeFromInstance(this); + }, + unmountComponent: function () { + ReactDOMComponentTree.uncacheNode(this); + } +}); + +module.exports = ReactDOMEmptyComponent; + +/***/ }), +/* 281 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); + +/** + * Return the lowest common ancestor of A and B, or null if they are in + * different trees. + */ +function getLowestCommonAncestor(instA, instB) { + !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; + !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; + + var depthA = 0; + for (var tempA = instA; tempA; tempA = tempA._hostParent) { + depthA++; + } + var depthB = 0; + for (var tempB = instB; tempB; tempB = tempB._hostParent) { + depthB++; + } + + // If A is deeper, crawl up. + while (depthA - depthB > 0) { + instA = instA._hostParent; + depthA--; + } + + // If B is deeper, crawl up. + while (depthB - depthA > 0) { + instB = instB._hostParent; + depthB--; + } + + // Walk in lockstep until we find a match. + var depth = depthA; + while (depth--) { + if (instA === instB) { + return instA; + } + instA = instA._hostParent; + instB = instB._hostParent; + } + return null; +} + +/** + * Return if A is an ancestor of B. + */ +function isAncestor(instA, instB) { + !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; + !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; + + while (instB) { + if (instB === instA) { + return true; + } + instB = instB._hostParent; + } + return false; +} + +/** + * Return the parent instance of the passed-in instance. + */ +function getParentInstance(inst) { + !('_hostNode' in inst) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getParentInstance: Invalid argument.') : _prodInvariant('36') : void 0; + + return inst._hostParent; +} + +/** + * Simulates the traversal of a two-phase, capture/bubble event dispatch. + */ +function traverseTwoPhase(inst, fn, arg) { + var path = []; + while (inst) { + path.push(inst); + inst = inst._hostParent; + } + var i; + for (i = path.length; i-- > 0;) { + fn(path[i], 'captured', arg); + } + for (i = 0; i < path.length; i++) { + fn(path[i], 'bubbled', arg); + } +} + +/** + * Traverses the ID hierarchy and invokes the supplied `cb` on any IDs that + * should would receive a `mouseEnter` or `mouseLeave` event. + * + * Does not invoke the callback on the nearest common ancestor because nothing + * "entered" or "left" that element. + */ +function traverseEnterLeave(from, to, fn, argFrom, argTo) { + var common = from && to ? getLowestCommonAncestor(from, to) : null; + var pathFrom = []; + while (from && from !== common) { + pathFrom.push(from); + from = from._hostParent; + } + var pathTo = []; + while (to && to !== common) { + pathTo.push(to); + to = to._hostParent; + } + var i; + for (i = 0; i < pathFrom.length; i++) { + fn(pathFrom[i], 'bubbled', argFrom); + } + for (i = pathTo.length; i-- > 0;) { + fn(pathTo[i], 'captured', argTo); + } +} + +module.exports = { + isAncestor: isAncestor, + getLowestCommonAncestor: getLowestCommonAncestor, + getParentInstance: getParentInstance, + traverseTwoPhase: traverseTwoPhase, + traverseEnterLeave: traverseEnterLeave +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 282 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var DOMChildrenOperations = __webpack_require__(82); +var DOMLazyTree = __webpack_require__(39); +var ReactDOMComponentTree = __webpack_require__(10); + +var escapeTextContentForBrowser = __webpack_require__(61); +var invariant = __webpack_require__(2); +var validateDOMNesting = __webpack_require__(91); + +/** + * Text nodes violate a couple assumptions that React makes about components: + * + * - When mounting text into the DOM, adjacent text nodes are merged. + * - Text nodes cannot be assigned a React root ID. + * + * This component is used to wrap strings between comment nodes so that they + * can undergo the same reconciliation that is applied to elements. + * + * TODO: Investigate representing React components in the DOM with text nodes. + * + * @class ReactDOMTextComponent + * @extends ReactComponent + * @internal + */ +var ReactDOMTextComponent = function (text) { + // TODO: This is really a ReactText (ReactNode), not a ReactElement + this._currentElement = text; + this._stringText = '' + text; + // ReactDOMComponentTree uses these: + this._hostNode = null; + this._hostParent = null; + + // Properties + this._domID = 0; + this._mountIndex = 0; + this._closingComment = null; + this._commentNodes = null; +}; + +_assign(ReactDOMTextComponent.prototype, { + /** + * Creates the markup for this text node. This node is not intended to have + * any features besides containing text content. + * + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @return {string} Markup for this text node. + * @internal + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + if (process.env.NODE_ENV !== 'production') { + var parentInfo; + if (hostParent != null) { + parentInfo = hostParent._ancestorInfo; + } else if (hostContainerInfo != null) { + parentInfo = hostContainerInfo._ancestorInfo; + } + if (parentInfo) { + // parentInfo should always be present except for the top-level + // component when server rendering + validateDOMNesting(null, this._stringText, this, parentInfo); + } + } + + var domID = hostContainerInfo._idCounter++; + var openingValue = ' react-text: ' + domID + ' '; + var closingValue = ' /react-text '; + this._domID = domID; + this._hostParent = hostParent; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var openingComment = ownerDocument.createComment(openingValue); + var closingComment = ownerDocument.createComment(closingValue); + var lazyTree = DOMLazyTree(ownerDocument.createDocumentFragment()); + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(openingComment)); + if (this._stringText) { + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(ownerDocument.createTextNode(this._stringText))); + } + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(closingComment)); + ReactDOMComponentTree.precacheNode(this, openingComment); + this._closingComment = closingComment; + return lazyTree; + } else { + var escapedText = escapeTextContentForBrowser(this._stringText); + + if (transaction.renderToStaticMarkup) { + // Normally we'd wrap this between comment nodes for the reasons stated + // above, but since this is a situation where React won't take over + // (static pages), we can simply return the text as it is. + return escapedText; + } + + return '<!--' + openingValue + '-->' + escapedText + '<!--' + closingValue + '-->'; + } + }, + + /** + * Updates this component by updating the text content. + * + * @param {ReactText} nextText The next text content + * @param {ReactReconcileTransaction} transaction + * @internal + */ + receiveComponent: function (nextText, transaction) { + if (nextText !== this._currentElement) { + this._currentElement = nextText; + var nextStringText = '' + nextText; + if (nextStringText !== this._stringText) { + // TODO: Save this as pending props and use performUpdateIfNecessary + // and/or updateComponent to do the actual update for consistency with + // other component types? + this._stringText = nextStringText; + var commentNodes = this.getHostNode(); + DOMChildrenOperations.replaceDelimitedText(commentNodes[0], commentNodes[1], nextStringText); + } + } + }, + + getHostNode: function () { + var hostNode = this._commentNodes; + if (hostNode) { + return hostNode; + } + if (!this._closingComment) { + var openingComment = ReactDOMComponentTree.getNodeFromInstance(this); + var node = openingComment.nextSibling; + while (true) { + !(node != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Missing closing comment for text component %s', this._domID) : _prodInvariant('67', this._domID) : void 0; + if (node.nodeType === 8 && node.nodeValue === ' /react-text ') { + this._closingComment = node; + break; + } + node = node.nextSibling; + } + } + hostNode = [this._hostNode, this._closingComment]; + this._commentNodes = hostNode; + return hostNode; + }, + + unmountComponent: function () { + this._closingComment = null; + this._commentNodes = null; + ReactDOMComponentTree.uncacheNode(this); + } +}); + +module.exports = ReactDOMTextComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 283 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var ReactUpdates = __webpack_require__(23); +var Transaction = __webpack_require__(58); + +var emptyFunction = __webpack_require__(18); + +var RESET_BATCHED_UPDATES = { + initialize: emptyFunction, + close: function () { + ReactDefaultBatchingStrategy.isBatchingUpdates = false; + } +}; + +var FLUSH_BATCHED_UPDATES = { + initialize: emptyFunction, + close: ReactUpdates.flushBatchedUpdates.bind(ReactUpdates) +}; + +var TRANSACTION_WRAPPERS = [FLUSH_BATCHED_UPDATES, RESET_BATCHED_UPDATES]; + +function ReactDefaultBatchingStrategyTransaction() { + this.reinitializeTransaction(); +} + +_assign(ReactDefaultBatchingStrategyTransaction.prototype, Transaction, { + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + } +}); + +var transaction = new ReactDefaultBatchingStrategyTransaction(); + +var ReactDefaultBatchingStrategy = { + isBatchingUpdates: false, + + /** + * Call the provided function in a context within which calls to `setState` + * and friends are batched such that components aren't updated unnecessarily. + */ + batchedUpdates: function (callback, a, b, c, d, e) { + var alreadyBatchingUpdates = ReactDefaultBatchingStrategy.isBatchingUpdates; + + ReactDefaultBatchingStrategy.isBatchingUpdates = true; + + // The code is written this way to avoid extra allocations + if (alreadyBatchingUpdates) { + return callback(a, b, c, d, e); + } else { + return transaction.perform(callback, null, a, b, c, d, e); + } + } +}; + +module.exports = ReactDefaultBatchingStrategy; + +/***/ }), +/* 284 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var EventListener = __webpack_require__(146); +var ExecutionEnvironment = __webpack_require__(13); +var PooledClass = __webpack_require__(32); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); + +var getEventTarget = __webpack_require__(79); +var getUnboundedScrollPosition = __webpack_require__(285); + +/** + * Find the deepest React component completely containing the root of the + * passed-in instance (for use when entire React trees are nested within each + * other). If React trees are not nested, returns null. + */ +function findParent(inst) { + // TODO: It may be a good idea to cache this to prevent unnecessary DOM + // traversal, but caching is difficult to do correctly without using a + // mutation observer to listen for all DOM changes. + while (inst._hostParent) { + inst = inst._hostParent; + } + var rootNode = ReactDOMComponentTree.getNodeFromInstance(inst); + var container = rootNode.parentNode; + return ReactDOMComponentTree.getClosestInstanceFromNode(container); +} + +// Used to store ancestor hierarchy in top level callback +function TopLevelCallbackBookKeeping(topLevelType, nativeEvent) { + this.topLevelType = topLevelType; + this.nativeEvent = nativeEvent; + this.ancestors = []; +} +_assign(TopLevelCallbackBookKeeping.prototype, { + destructor: function () { + this.topLevelType = null; + this.nativeEvent = null; + this.ancestors.length = 0; + } +}); +PooledClass.addPoolingTo(TopLevelCallbackBookKeeping, PooledClass.twoArgumentPooler); + +function handleTopLevelImpl(bookKeeping) { + var nativeEventTarget = getEventTarget(bookKeeping.nativeEvent); + var targetInst = ReactDOMComponentTree.getClosestInstanceFromNode(nativeEventTarget); + + // Loop through the hierarchy, in case there's any nested components. + // It's important that we build the array of ancestors before calling any + // event handlers, because event handlers can modify the DOM, leading to + // inconsistencies with ReactMount's node cache. See #1105. + var ancestor = targetInst; + do { + bookKeeping.ancestors.push(ancestor); + ancestor = ancestor && findParent(ancestor); + } while (ancestor); + + for (var i = 0; i < bookKeeping.ancestors.length; i++) { + targetInst = bookKeeping.ancestors[i]; + ReactEventListener._handleTopLevel(bookKeeping.topLevelType, targetInst, bookKeeping.nativeEvent, getEventTarget(bookKeeping.nativeEvent)); + } +} + +function scrollValueMonitor(cb) { + var scrollPosition = getUnboundedScrollPosition(window); + cb(scrollPosition); +} + +var ReactEventListener = { + _enabled: true, + _handleTopLevel: null, + + WINDOW_HANDLE: ExecutionEnvironment.canUseDOM ? window : null, + + setHandleTopLevel: function (handleTopLevel) { + ReactEventListener._handleTopLevel = handleTopLevel; + }, + + setEnabled: function (enabled) { + ReactEventListener._enabled = !!enabled; + }, + + isEnabled: function () { + return ReactEventListener._enabled; + }, + + /** + * Traps top-level events by using event bubbling. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {string} handlerBaseName Event name (e.g. "click"). + * @param {object} element Element on which to attach listener. + * @return {?object} An object with a remove function which will forcefully + * remove the listener. + * @internal + */ + trapBubbledEvent: function (topLevelType, handlerBaseName, element) { + if (!element) { + return null; + } + return EventListener.listen(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); + }, + + /** + * Traps a top-level event by using event capturing. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {string} handlerBaseName Event name (e.g. "click"). + * @param {object} element Element on which to attach listener. + * @return {?object} An object with a remove function which will forcefully + * remove the listener. + * @internal + */ + trapCapturedEvent: function (topLevelType, handlerBaseName, element) { + if (!element) { + return null; + } + return EventListener.capture(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); + }, + + monitorScrollValue: function (refresh) { + var callback = scrollValueMonitor.bind(null, refresh); + EventListener.listen(window, 'scroll', callback); + }, + + dispatchEvent: function (topLevelType, nativeEvent) { + if (!ReactEventListener._enabled) { + return; + } + + var bookKeeping = TopLevelCallbackBookKeeping.getPooled(topLevelType, nativeEvent); + try { + // Event queue being processed in the same cycle allows + // `preventDefault`. + ReactUpdates.batchedUpdates(handleTopLevelImpl, bookKeeping); + } finally { + TopLevelCallbackBookKeeping.release(bookKeeping); + } + } +}; + +module.exports = ReactEventListener; + +/***/ }), +/* 285 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + + + +/** + * Gets the scroll position of the supplied element or window. + * + * The return values are unbounded, unlike `getScrollPosition`. This means they + * may be negative or exceed the element boundaries (which is possible using + * inertial scrolling). + * + * @param {DOMWindow|DOMElement} scrollable + * @return {object} Map with `x` and `y` keys. + */ + +function getUnboundedScrollPosition(scrollable) { + if (scrollable.Window && scrollable instanceof scrollable.Window) { + return { + x: scrollable.pageXOffset || scrollable.document.documentElement.scrollLeft, + y: scrollable.pageYOffset || scrollable.document.documentElement.scrollTop + }; + } + return { + x: scrollable.scrollLeft, + y: scrollable.scrollTop + }; +} + +module.exports = getUnboundedScrollPosition; + +/***/ }), +/* 286 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var EventPluginHub = __webpack_require__(46); +var EventPluginUtils = __webpack_require__(77); +var ReactComponentEnvironment = __webpack_require__(86); +var ReactEmptyComponent = __webpack_require__(143); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactHostComponent = __webpack_require__(144); +var ReactUpdates = __webpack_require__(23); + +var ReactInjection = { + Component: ReactComponentEnvironment.injection, + DOMProperty: DOMProperty.injection, + EmptyComponent: ReactEmptyComponent.injection, + EventPluginHub: EventPluginHub.injection, + EventPluginUtils: EventPluginUtils.injection, + EventEmitter: ReactBrowserEventEmitter.injection, + HostComponent: ReactHostComponent.injection, + Updates: ReactUpdates.injection +}; + +module.exports = ReactInjection; + +/***/ }), +/* 287 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var CallbackQueue = __webpack_require__(130); +var PooledClass = __webpack_require__(32); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactInputSelection = __webpack_require__(147); +var ReactInstrumentation = __webpack_require__(19); +var Transaction = __webpack_require__(58); +var ReactUpdateQueue = __webpack_require__(90); + +/** + * Ensures that, when possible, the selection range (currently selected text + * input) is not disturbed by performing the transaction. + */ +var SELECTION_RESTORATION = { + /** + * @return {Selection} Selection information. + */ + initialize: ReactInputSelection.getSelectionInformation, + /** + * @param {Selection} sel Selection information returned from `initialize`. + */ + close: ReactInputSelection.restoreSelection +}; + +/** + * Suppresses events (blur/focus) that could be inadvertently dispatched due to + * high level DOM manipulations (like temporarily removing a text input from the + * DOM). + */ +var EVENT_SUPPRESSION = { + /** + * @return {boolean} The enabled status of `ReactBrowserEventEmitter` before + * the reconciliation. + */ + initialize: function () { + var currentlyEnabled = ReactBrowserEventEmitter.isEnabled(); + ReactBrowserEventEmitter.setEnabled(false); + return currentlyEnabled; + }, + + /** + * @param {boolean} previouslyEnabled Enabled status of + * `ReactBrowserEventEmitter` before the reconciliation occurred. `close` + * restores the previous value. + */ + close: function (previouslyEnabled) { + ReactBrowserEventEmitter.setEnabled(previouslyEnabled); + } +}; + +/** + * Provides a queue for collecting `componentDidMount` and + * `componentDidUpdate` callbacks during the transaction. + */ +var ON_DOM_READY_QUEUEING = { + /** + * Initializes the internal `onDOMReady` queue. + */ + initialize: function () { + this.reactMountReady.reset(); + }, + + /** + * After DOM is flushed, invoke all registered `onDOMReady` callbacks. + */ + close: function () { + this.reactMountReady.notifyAll(); + } +}; + +/** + * Executed within the scope of the `Transaction` instance. Consider these as + * being member methods, but with an implied ordering while being isolated from + * each other. + */ +var TRANSACTION_WRAPPERS = [SELECTION_RESTORATION, EVENT_SUPPRESSION, ON_DOM_READY_QUEUEING]; + +if (process.env.NODE_ENV !== 'production') { + TRANSACTION_WRAPPERS.push({ + initialize: ReactInstrumentation.debugTool.onBeginFlush, + close: ReactInstrumentation.debugTool.onEndFlush + }); +} + +/** + * Currently: + * - The order that these are listed in the transaction is critical: + * - Suppresses events. + * - Restores selection range. + * + * Future: + * - Restore document/overflow scroll positions that were unintentionally + * modified via DOM insertions above the top viewport boundary. + * - Implement/integrate with customized constraint based layout system and keep + * track of which dimensions must be remeasured. + * + * @class ReactReconcileTransaction + */ +function ReactReconcileTransaction(useCreateElement) { + this.reinitializeTransaction(); + // Only server-side rendering really needs this option (see + // `ReactServerRendering`), but server-side uses + // `ReactServerRenderingTransaction` instead. This option is here so that it's + // accessible and defaults to false when `ReactDOMComponent` and + // `ReactDOMTextComponent` checks it in `mountComponent`.` + this.renderToStaticMarkup = false; + this.reactMountReady = CallbackQueue.getPooled(null); + this.useCreateElement = useCreateElement; +} + +var Mixin = { + /** + * @see Transaction + * @abstract + * @final + * @return {array<object>} List of operation wrap procedures. + * TODO: convert to array<TransactionWrapper> + */ + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, + + /** + * @return {object} The queue to collect `onDOMReady` callbacks with. + */ + getReactMountReady: function () { + return this.reactMountReady; + }, + + /** + * @return {object} The queue to collect React async events. + */ + getUpdateQueue: function () { + return ReactUpdateQueue; + }, + + /** + * Save current transaction state -- if the return value from this method is + * passed to `rollback`, the transaction will be reset to that state. + */ + checkpoint: function () { + // reactMountReady is the our only stateful wrapper + return this.reactMountReady.checkpoint(); + }, + + rollback: function (checkpoint) { + this.reactMountReady.rollback(checkpoint); + }, + + /** + * `PooledClass` looks for this, and will invoke this before allowing this + * instance to be reused. + */ + destructor: function () { + CallbackQueue.release(this.reactMountReady); + this.reactMountReady = null; + } +}; + +_assign(ReactReconcileTransaction.prototype, Transaction, Mixin); + +PooledClass.addPoolingTo(ReactReconcileTransaction); + +module.exports = ReactReconcileTransaction; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 288 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ExecutionEnvironment = __webpack_require__(13); + +var getNodeForCharacterOffset = __webpack_require__(289); +var getTextContentAccessor = __webpack_require__(129); + +/** + * While `isCollapsed` is available on the Selection object and `collapsed` + * is available on the Range object, IE11 sometimes gets them wrong. + * If the anchor/focus nodes and offsets are the same, the range is collapsed. + */ +function isCollapsed(anchorNode, anchorOffset, focusNode, focusOffset) { + return anchorNode === focusNode && anchorOffset === focusOffset; +} + +/** + * Get the appropriate anchor and focus node/offset pairs for IE. + * + * The catch here is that IE's selection API doesn't provide information + * about whether the selection is forward or backward, so we have to + * behave as though it's always forward. + * + * IE text differs from modern selection in that it behaves as though + * block elements end with a new line. This means character offsets will + * differ between the two APIs. + * + * @param {DOMElement} node + * @return {object} + */ +function getIEOffsets(node) { + var selection = document.selection; + var selectedRange = selection.createRange(); + var selectedLength = selectedRange.text.length; + + // Duplicate selection so we can move range without breaking user selection. + var fromStart = selectedRange.duplicate(); + fromStart.moveToElementText(node); + fromStart.setEndPoint('EndToStart', selectedRange); + + var startOffset = fromStart.text.length; + var endOffset = startOffset + selectedLength; + + return { + start: startOffset, + end: endOffset + }; +} + +/** + * @param {DOMElement} node + * @return {?object} + */ +function getModernOffsets(node) { + var selection = window.getSelection && window.getSelection(); + + if (!selection || selection.rangeCount === 0) { + return null; + } + + var anchorNode = selection.anchorNode; + var anchorOffset = selection.anchorOffset; + var focusNode = selection.focusNode; + var focusOffset = selection.focusOffset; + + var currentRange = selection.getRangeAt(0); + + // In Firefox, range.startContainer and range.endContainer can be "anonymous + // divs", e.g. the up/down buttons on an <input type="number">. Anonymous + // divs do not seem to expose properties, triggering a "Permission denied + // error" if any of its properties are accessed. The only seemingly possible + // way to avoid erroring is to access a property that typically works for + // non-anonymous divs and catch any error that may otherwise arise. See + // https://bugzilla.mozilla.org/show_bug.cgi?id=208427 + try { + /* eslint-disable no-unused-expressions */ + currentRange.startContainer.nodeType; + currentRange.endContainer.nodeType; + /* eslint-enable no-unused-expressions */ + } catch (e) { + return null; + } + + // If the node and offset values are the same, the selection is collapsed. + // `Selection.isCollapsed` is available natively, but IE sometimes gets + // this value wrong. + var isSelectionCollapsed = isCollapsed(selection.anchorNode, selection.anchorOffset, selection.focusNode, selection.focusOffset); + + var rangeLength = isSelectionCollapsed ? 0 : currentRange.toString().length; + + var tempRange = currentRange.cloneRange(); + tempRange.selectNodeContents(node); + tempRange.setEnd(currentRange.startContainer, currentRange.startOffset); + + var isTempRangeCollapsed = isCollapsed(tempRange.startContainer, tempRange.startOffset, tempRange.endContainer, tempRange.endOffset); + + var start = isTempRangeCollapsed ? 0 : tempRange.toString().length; + var end = start + rangeLength; + + // Detect whether the selection is backward. + var detectionRange = document.createRange(); + detectionRange.setStart(anchorNode, anchorOffset); + detectionRange.setEnd(focusNode, focusOffset); + var isBackward = detectionRange.collapsed; + + return { + start: isBackward ? end : start, + end: isBackward ? start : end + }; +} + +/** + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ +function setIEOffsets(node, offsets) { + var range = document.selection.createRange().duplicate(); + var start, end; + + if (offsets.end === undefined) { + start = offsets.start; + end = start; + } else if (offsets.start > offsets.end) { + start = offsets.end; + end = offsets.start; + } else { + start = offsets.start; + end = offsets.end; + } + + range.moveToElementText(node); + range.moveStart('character', start); + range.setEndPoint('EndToStart', range); + range.moveEnd('character', end - start); + range.select(); +} + +/** + * In modern non-IE browsers, we can support both forward and backward + * selections. + * + * Note: IE10+ supports the Selection object, but it does not support + * the `extend` method, which means that even in modern IE, it's not possible + * to programmatically create a backward selection. Thus, for all IE + * versions, we use the old IE API to create our selections. + * + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ +function setModernOffsets(node, offsets) { + if (!window.getSelection) { + return; + } + + var selection = window.getSelection(); + var length = node[getTextContentAccessor()].length; + var start = Math.min(offsets.start, length); + var end = offsets.end === undefined ? start : Math.min(offsets.end, length); + + // IE 11 uses modern selection, but doesn't support the extend method. + // Flip backward selections, so we can set with a single range. + if (!selection.extend && start > end) { + var temp = end; + end = start; + start = temp; + } + + var startMarker = getNodeForCharacterOffset(node, start); + var endMarker = getNodeForCharacterOffset(node, end); + + if (startMarker && endMarker) { + var range = document.createRange(); + range.setStart(startMarker.node, startMarker.offset); + selection.removeAllRanges(); + + if (start > end) { + selection.addRange(range); + selection.extend(endMarker.node, endMarker.offset); + } else { + range.setEnd(endMarker.node, endMarker.offset); + selection.addRange(range); + } + } +} + +var useIEOffsets = ExecutionEnvironment.canUseDOM && 'selection' in document && !('getSelection' in window); + +var ReactDOMSelection = { + /** + * @param {DOMElement} node + */ + getOffsets: useIEOffsets ? getIEOffsets : getModernOffsets, + + /** + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ + setOffsets: useIEOffsets ? setIEOffsets : setModernOffsets +}; + +module.exports = ReactDOMSelection; + +/***/ }), +/* 289 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +/** + * Given any node return the first leaf node without children. + * + * @param {DOMElement|DOMTextNode} node + * @return {DOMElement|DOMTextNode} + */ + +function getLeafNode(node) { + while (node && node.firstChild) { + node = node.firstChild; + } + return node; +} + +/** + * Get the next sibling within a container. This will walk up the + * DOM if a node's siblings have been exhausted. + * + * @param {DOMElement|DOMTextNode} node + * @return {?DOMElement|DOMTextNode} + */ +function getSiblingNode(node) { + while (node) { + if (node.nextSibling) { + return node.nextSibling; + } + node = node.parentNode; + } +} + +/** + * Get object describing the nodes which contain characters at offset. + * + * @param {DOMElement|DOMTextNode} root + * @param {number} offset + * @return {?object} + */ +function getNodeForCharacterOffset(root, offset) { + var node = getLeafNode(root); + var nodeStart = 0; + var nodeEnd = 0; + + while (node) { + if (node.nodeType === 3) { + nodeEnd = nodeStart + node.textContent.length; + + if (nodeStart <= offset && nodeEnd >= offset) { + return { + node: node, + offset: offset - nodeStart + }; + } + + nodeStart = nodeEnd; + } + + node = getLeafNode(getSiblingNode(node)); + } +} + +module.exports = getNodeForCharacterOffset; + +/***/ }), +/* 290 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + +var isTextNode = __webpack_require__(291); + +/*eslint-disable no-bitwise */ + +/** + * Checks if a given DOM node contains or is another DOM node. + */ +function containsNode(outerNode, innerNode) { + if (!outerNode || !innerNode) { + return false; + } else if (outerNode === innerNode) { + return true; + } else if (isTextNode(outerNode)) { + return false; + } else if (isTextNode(innerNode)) { + return containsNode(outerNode, innerNode.parentNode); + } else if ('contains' in outerNode) { + return outerNode.contains(innerNode); + } else if (outerNode.compareDocumentPosition) { + return !!(outerNode.compareDocumentPosition(innerNode) & 16); + } else { + return false; + } +} + +module.exports = containsNode; + +/***/ }), +/* 291 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +var isNode = __webpack_require__(292); + +/** + * @param {*} object The object to check. + * @return {boolean} Whether or not the object is a DOM text node. + */ +function isTextNode(object) { + return isNode(object) && object.nodeType == 3; +} + +module.exports = isTextNode; + +/***/ }), +/* 292 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +/** + * @param {*} object The object to check. + * @return {boolean} Whether or not the object is a DOM node. + */ +function isNode(object) { + var doc = object ? object.ownerDocument || object : document; + var defaultView = doc.defaultView || window; + return !!(object && (typeof defaultView.Node === 'function' ? object instanceof defaultView.Node : typeof object === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string')); +} + +module.exports = isNode; + +/***/ }), +/* 293 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var NS = { + xlink: 'http://www.w3.org/1999/xlink', + xml: 'http://www.w3.org/XML/1998/namespace' +}; + +// We use attributes for everything SVG so let's avoid some duplication and run +// code instead. +// The following are all specified in the HTML config already so we exclude here. +// - class (as className) +// - color +// - height +// - id +// - lang +// - max +// - media +// - method +// - min +// - name +// - style +// - target +// - type +// - width +var ATTRS = { + accentHeight: 'accent-height', + accumulate: 0, + additive: 0, + alignmentBaseline: 'alignment-baseline', + allowReorder: 'allowReorder', + alphabetic: 0, + amplitude: 0, + arabicForm: 'arabic-form', + ascent: 0, + attributeName: 'attributeName', + attributeType: 'attributeType', + autoReverse: 'autoReverse', + azimuth: 0, + baseFrequency: 'baseFrequency', + baseProfile: 'baseProfile', + baselineShift: 'baseline-shift', + bbox: 0, + begin: 0, + bias: 0, + by: 0, + calcMode: 'calcMode', + capHeight: 'cap-height', + clip: 0, + clipPath: 'clip-path', + clipRule: 'clip-rule', + clipPathUnits: 'clipPathUnits', + colorInterpolation: 'color-interpolation', + colorInterpolationFilters: 'color-interpolation-filters', + colorProfile: 'color-profile', + colorRendering: 'color-rendering', + contentScriptType: 'contentScriptType', + contentStyleType: 'contentStyleType', + cursor: 0, + cx: 0, + cy: 0, + d: 0, + decelerate: 0, + descent: 0, + diffuseConstant: 'diffuseConstant', + direction: 0, + display: 0, + divisor: 0, + dominantBaseline: 'dominant-baseline', + dur: 0, + dx: 0, + dy: 0, + edgeMode: 'edgeMode', + elevation: 0, + enableBackground: 'enable-background', + end: 0, + exponent: 0, + externalResourcesRequired: 'externalResourcesRequired', + fill: 0, + fillOpacity: 'fill-opacity', + fillRule: 'fill-rule', + filter: 0, + filterRes: 'filterRes', + filterUnits: 'filterUnits', + floodColor: 'flood-color', + floodOpacity: 'flood-opacity', + focusable: 0, + fontFamily: 'font-family', + fontSize: 'font-size', + fontSizeAdjust: 'font-size-adjust', + fontStretch: 'font-stretch', + fontStyle: 'font-style', + fontVariant: 'font-variant', + fontWeight: 'font-weight', + format: 0, + from: 0, + fx: 0, + fy: 0, + g1: 0, + g2: 0, + glyphName: 'glyph-name', + glyphOrientationHorizontal: 'glyph-orientation-horizontal', + glyphOrientationVertical: 'glyph-orientation-vertical', + glyphRef: 'glyphRef', + gradientTransform: 'gradientTransform', + gradientUnits: 'gradientUnits', + hanging: 0, + horizAdvX: 'horiz-adv-x', + horizOriginX: 'horiz-origin-x', + ideographic: 0, + imageRendering: 'image-rendering', + 'in': 0, + in2: 0, + intercept: 0, + k: 0, + k1: 0, + k2: 0, + k3: 0, + k4: 0, + kernelMatrix: 'kernelMatrix', + kernelUnitLength: 'kernelUnitLength', + kerning: 0, + keyPoints: 'keyPoints', + keySplines: 'keySplines', + keyTimes: 'keyTimes', + lengthAdjust: 'lengthAdjust', + letterSpacing: 'letter-spacing', + lightingColor: 'lighting-color', + limitingConeAngle: 'limitingConeAngle', + local: 0, + markerEnd: 'marker-end', + markerMid: 'marker-mid', + markerStart: 'marker-start', + markerHeight: 'markerHeight', + markerUnits: 'markerUnits', + markerWidth: 'markerWidth', + mask: 0, + maskContentUnits: 'maskContentUnits', + maskUnits: 'maskUnits', + mathematical: 0, + mode: 0, + numOctaves: 'numOctaves', + offset: 0, + opacity: 0, + operator: 0, + order: 0, + orient: 0, + orientation: 0, + origin: 0, + overflow: 0, + overlinePosition: 'overline-position', + overlineThickness: 'overline-thickness', + paintOrder: 'paint-order', + panose1: 'panose-1', + pathLength: 'pathLength', + patternContentUnits: 'patternContentUnits', + patternTransform: 'patternTransform', + patternUnits: 'patternUnits', + pointerEvents: 'pointer-events', + points: 0, + pointsAtX: 'pointsAtX', + pointsAtY: 'pointsAtY', + pointsAtZ: 'pointsAtZ', + preserveAlpha: 'preserveAlpha', + preserveAspectRatio: 'preserveAspectRatio', + primitiveUnits: 'primitiveUnits', + r: 0, + radius: 0, + refX: 'refX', + refY: 'refY', + renderingIntent: 'rendering-intent', + repeatCount: 'repeatCount', + repeatDur: 'repeatDur', + requiredExtensions: 'requiredExtensions', + requiredFeatures: 'requiredFeatures', + restart: 0, + result: 0, + rotate: 0, + rx: 0, + ry: 0, + scale: 0, + seed: 0, + shapeRendering: 'shape-rendering', + slope: 0, + spacing: 0, + specularConstant: 'specularConstant', + specularExponent: 'specularExponent', + speed: 0, + spreadMethod: 'spreadMethod', + startOffset: 'startOffset', + stdDeviation: 'stdDeviation', + stemh: 0, + stemv: 0, + stitchTiles: 'stitchTiles', + stopColor: 'stop-color', + stopOpacity: 'stop-opacity', + strikethroughPosition: 'strikethrough-position', + strikethroughThickness: 'strikethrough-thickness', + string: 0, + stroke: 0, + strokeDasharray: 'stroke-dasharray', + strokeDashoffset: 'stroke-dashoffset', + strokeLinecap: 'stroke-linecap', + strokeLinejoin: 'stroke-linejoin', + strokeMiterlimit: 'stroke-miterlimit', + strokeOpacity: 'stroke-opacity', + strokeWidth: 'stroke-width', + surfaceScale: 'surfaceScale', + systemLanguage: 'systemLanguage', + tableValues: 'tableValues', + targetX: 'targetX', + targetY: 'targetY', + textAnchor: 'text-anchor', + textDecoration: 'text-decoration', + textRendering: 'text-rendering', + textLength: 'textLength', + to: 0, + transform: 0, + u1: 0, + u2: 0, + underlinePosition: 'underline-position', + underlineThickness: 'underline-thickness', + unicode: 0, + unicodeBidi: 'unicode-bidi', + unicodeRange: 'unicode-range', + unitsPerEm: 'units-per-em', + vAlphabetic: 'v-alphabetic', + vHanging: 'v-hanging', + vIdeographic: 'v-ideographic', + vMathematical: 'v-mathematical', + values: 0, + vectorEffect: 'vector-effect', + version: 0, + vertAdvY: 'vert-adv-y', + vertOriginX: 'vert-origin-x', + vertOriginY: 'vert-origin-y', + viewBox: 'viewBox', + viewTarget: 'viewTarget', + visibility: 0, + widths: 0, + wordSpacing: 'word-spacing', + writingMode: 'writing-mode', + x: 0, + xHeight: 'x-height', + x1: 0, + x2: 0, + xChannelSelector: 'xChannelSelector', + xlinkActuate: 'xlink:actuate', + xlinkArcrole: 'xlink:arcrole', + xlinkHref: 'xlink:href', + xlinkRole: 'xlink:role', + xlinkShow: 'xlink:show', + xlinkTitle: 'xlink:title', + xlinkType: 'xlink:type', + xmlBase: 'xml:base', + xmlns: 0, + xmlnsXlink: 'xmlns:xlink', + xmlLang: 'xml:lang', + xmlSpace: 'xml:space', + y: 0, + y1: 0, + y2: 0, + yChannelSelector: 'yChannelSelector', + z: 0, + zoomAndPan: 'zoomAndPan' +}; + +var SVGDOMPropertyConfig = { + Properties: {}, + DOMAttributeNamespaces: { + xlinkActuate: NS.xlink, + xlinkArcrole: NS.xlink, + xlinkHref: NS.xlink, + xlinkRole: NS.xlink, + xlinkShow: NS.xlink, + xlinkTitle: NS.xlink, + xlinkType: NS.xlink, + xmlBase: NS.xml, + xmlLang: NS.xml, + xmlSpace: NS.xml + }, + DOMAttributeNames: {} +}; + +Object.keys(ATTRS).forEach(function (key) { + SVGDOMPropertyConfig.Properties[key] = 0; + if (ATTRS[key]) { + SVGDOMPropertyConfig.DOMAttributeNames[key] = ATTRS[key]; + } +}); + +module.exports = SVGDOMPropertyConfig; + +/***/ }), +/* 294 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInputSelection = __webpack_require__(147); +var SyntheticEvent = __webpack_require__(26); + +var getActiveElement = __webpack_require__(148); +var isTextInputElement = __webpack_require__(133); +var shallowEqual = __webpack_require__(87); + +var skipSelectionChangeEvent = ExecutionEnvironment.canUseDOM && 'documentMode' in document && document.documentMode <= 11; + +var eventTypes = { + select: { + phasedRegistrationNames: { + bubbled: 'onSelect', + captured: 'onSelectCapture' + }, + dependencies: ['topBlur', 'topContextMenu', 'topFocus', 'topKeyDown', 'topKeyUp', 'topMouseDown', 'topMouseUp', 'topSelectionChange'] + } +}; + +var activeElement = null; +var activeElementInst = null; +var lastSelection = null; +var mouseDown = false; + +// Track whether a listener exists for this plugin. If none exist, we do +// not extract events. See #3639. +var hasListener = false; + +/** + * Get an object which is a unique representation of the current selection. + * + * The return value will not be consistent across nodes or browsers, but + * two identical selections on the same node will return identical objects. + * + * @param {DOMElement} node + * @return {object} + */ +function getSelection(node) { + if ('selectionStart' in node && ReactInputSelection.hasSelectionCapabilities(node)) { + return { + start: node.selectionStart, + end: node.selectionEnd + }; + } else if (window.getSelection) { + var selection = window.getSelection(); + return { + anchorNode: selection.anchorNode, + anchorOffset: selection.anchorOffset, + focusNode: selection.focusNode, + focusOffset: selection.focusOffset + }; + } else if (document.selection) { + var range = document.selection.createRange(); + return { + parentElement: range.parentElement(), + text: range.text, + top: range.boundingTop, + left: range.boundingLeft + }; + } +} + +/** + * Poll selection to see whether it's changed. + * + * @param {object} nativeEvent + * @return {?SyntheticEvent} + */ +function constructSelectEvent(nativeEvent, nativeEventTarget) { + // Ensure we have the right element, and that the user is not dragging a + // selection (this matches native `select` event behavior). In HTML5, select + // fires only on input and textarea thus if there's no focused element we + // won't dispatch. + if (mouseDown || activeElement == null || activeElement !== getActiveElement()) { + return null; + } + + // Only fire when selection has actually changed. + var currentSelection = getSelection(activeElement); + if (!lastSelection || !shallowEqual(lastSelection, currentSelection)) { + lastSelection = currentSelection; + + var syntheticEvent = SyntheticEvent.getPooled(eventTypes.select, activeElementInst, nativeEvent, nativeEventTarget); + + syntheticEvent.type = 'select'; + syntheticEvent.target = activeElement; + + EventPropagators.accumulateTwoPhaseDispatches(syntheticEvent); + + return syntheticEvent; + } + + return null; +} + +/** + * This plugin creates an `onSelect` event that normalizes select events + * across form elements. + * + * Supported elements are: + * - input (see `isTextInputElement`) + * - textarea + * - contentEditable + * + * This differs from native browser implementations in the following ways: + * - Fires on contentEditable fields as well as inputs. + * - Fires for collapsed selection. + * - Fires after user input. + */ +var SelectEventPlugin = { + eventTypes: eventTypes, + + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + if (!hasListener) { + return null; + } + + var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; + + switch (topLevelType) { + // Track the input node that has focus. + case 'topFocus': + if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') { + activeElement = targetNode; + activeElementInst = targetInst; + lastSelection = null; + } + break; + case 'topBlur': + activeElement = null; + activeElementInst = null; + lastSelection = null; + break; + // Don't fire the event while the user is dragging. This matches the + // semantics of the native select event. + case 'topMouseDown': + mouseDown = true; + break; + case 'topContextMenu': + case 'topMouseUp': + mouseDown = false; + return constructSelectEvent(nativeEvent, nativeEventTarget); + // Chrome and IE fire non-standard event when selection is changed (and + // sometimes when it hasn't). IE's event fires out of order with respect + // to key and input events on deletion, so we discard it. + // + // Firefox doesn't support selectionchange, so check selection status + // after each key entry. The selection changes after keydown and before + // keyup, but we check on keydown as well in the case of holding down a + // key, when multiple keydown events are fired but only one keyup is. + // This is also our approach for IE handling, for the reason above. + case 'topSelectionChange': + if (skipSelectionChangeEvent) { + break; + } + // falls through + case 'topKeyDown': + case 'topKeyUp': + return constructSelectEvent(nativeEvent, nativeEventTarget); + } + + return null; + }, + + didPutListener: function (inst, registrationName, listener) { + if (registrationName === 'onSelect') { + hasListener = true; + } + } +}; + +module.exports = SelectEventPlugin; + +/***/ }), +/* 295 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var EventListener = __webpack_require__(146); +var EventPropagators = __webpack_require__(45); +var ReactDOMComponentTree = __webpack_require__(10); +var SyntheticAnimationEvent = __webpack_require__(296); +var SyntheticClipboardEvent = __webpack_require__(297); +var SyntheticEvent = __webpack_require__(26); +var SyntheticFocusEvent = __webpack_require__(298); +var SyntheticKeyboardEvent = __webpack_require__(299); +var SyntheticMouseEvent = __webpack_require__(59); +var SyntheticDragEvent = __webpack_require__(301); +var SyntheticTouchEvent = __webpack_require__(302); +var SyntheticTransitionEvent = __webpack_require__(303); +var SyntheticUIEvent = __webpack_require__(47); +var SyntheticWheelEvent = __webpack_require__(304); + +var emptyFunction = __webpack_require__(18); +var getEventCharCode = __webpack_require__(92); +var invariant = __webpack_require__(2); + +/** + * Turns + * ['abort', ...] + * into + * eventTypes = { + * 'abort': { + * phasedRegistrationNames: { + * bubbled: 'onAbort', + * captured: 'onAbortCapture', + * }, + * dependencies: ['topAbort'], + * }, + * ... + * }; + * topLevelEventsToDispatchConfig = { + * 'topAbort': { sameConfig } + * }; + */ +var eventTypes = {}; +var topLevelEventsToDispatchConfig = {}; +['abort', 'animationEnd', 'animationIteration', 'animationStart', 'blur', 'canPlay', 'canPlayThrough', 'click', 'contextMenu', 'copy', 'cut', 'doubleClick', 'drag', 'dragEnd', 'dragEnter', 'dragExit', 'dragLeave', 'dragOver', 'dragStart', 'drop', 'durationChange', 'emptied', 'encrypted', 'ended', 'error', 'focus', 'input', 'invalid', 'keyDown', 'keyPress', 'keyUp', 'load', 'loadedData', 'loadedMetadata', 'loadStart', 'mouseDown', 'mouseMove', 'mouseOut', 'mouseOver', 'mouseUp', 'paste', 'pause', 'play', 'playing', 'progress', 'rateChange', 'reset', 'scroll', 'seeked', 'seeking', 'stalled', 'submit', 'suspend', 'timeUpdate', 'touchCancel', 'touchEnd', 'touchMove', 'touchStart', 'transitionEnd', 'volumeChange', 'waiting', 'wheel'].forEach(function (event) { + var capitalizedEvent = event[0].toUpperCase() + event.slice(1); + var onEvent = 'on' + capitalizedEvent; + var topEvent = 'top' + capitalizedEvent; + + var type = { + phasedRegistrationNames: { + bubbled: onEvent, + captured: onEvent + 'Capture' + }, + dependencies: [topEvent] + }; + eventTypes[event] = type; + topLevelEventsToDispatchConfig[topEvent] = type; +}); + +var onClickListeners = {}; + +function getDictionaryKey(inst) { + // Prevents V8 performance issue: + // https://github.com/facebook/react/pull/7232 + return '.' + inst._rootNodeID; +} + +function isInteractive(tag) { + return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; +} + +var SimpleEventPlugin = { + eventTypes: eventTypes, + + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var dispatchConfig = topLevelEventsToDispatchConfig[topLevelType]; + if (!dispatchConfig) { + return null; + } + var EventConstructor; + switch (topLevelType) { + case 'topAbort': + case 'topCanPlay': + case 'topCanPlayThrough': + case 'topDurationChange': + case 'topEmptied': + case 'topEncrypted': + case 'topEnded': + case 'topError': + case 'topInput': + case 'topInvalid': + case 'topLoad': + case 'topLoadedData': + case 'topLoadedMetadata': + case 'topLoadStart': + case 'topPause': + case 'topPlay': + case 'topPlaying': + case 'topProgress': + case 'topRateChange': + case 'topReset': + case 'topSeeked': + case 'topSeeking': + case 'topStalled': + case 'topSubmit': + case 'topSuspend': + case 'topTimeUpdate': + case 'topVolumeChange': + case 'topWaiting': + // HTML Events + // @see http://www.w3.org/TR/html5/index.html#events-0 + EventConstructor = SyntheticEvent; + break; + case 'topKeyPress': + // Firefox creates a keypress event for function keys too. This removes + // the unwanted keypress events. Enter is however both printable and + // non-printable. One would expect Tab to be as well (but it isn't). + if (getEventCharCode(nativeEvent) === 0) { + return null; + } + /* falls through */ + case 'topKeyDown': + case 'topKeyUp': + EventConstructor = SyntheticKeyboardEvent; + break; + case 'topBlur': + case 'topFocus': + EventConstructor = SyntheticFocusEvent; + break; + case 'topClick': + // Firefox creates a click event on right mouse clicks. This removes the + // unwanted click events. + if (nativeEvent.button === 2) { + return null; + } + /* falls through */ + case 'topDoubleClick': + case 'topMouseDown': + case 'topMouseMove': + case 'topMouseUp': + // TODO: Disabled elements should not respond to mouse events + /* falls through */ + case 'topMouseOut': + case 'topMouseOver': + case 'topContextMenu': + EventConstructor = SyntheticMouseEvent; + break; + case 'topDrag': + case 'topDragEnd': + case 'topDragEnter': + case 'topDragExit': + case 'topDragLeave': + case 'topDragOver': + case 'topDragStart': + case 'topDrop': + EventConstructor = SyntheticDragEvent; + break; + case 'topTouchCancel': + case 'topTouchEnd': + case 'topTouchMove': + case 'topTouchStart': + EventConstructor = SyntheticTouchEvent; + break; + case 'topAnimationEnd': + case 'topAnimationIteration': + case 'topAnimationStart': + EventConstructor = SyntheticAnimationEvent; + break; + case 'topTransitionEnd': + EventConstructor = SyntheticTransitionEvent; + break; + case 'topScroll': + EventConstructor = SyntheticUIEvent; + break; + case 'topWheel': + EventConstructor = SyntheticWheelEvent; + break; + case 'topCopy': + case 'topCut': + case 'topPaste': + EventConstructor = SyntheticClipboardEvent; + break; + } + !EventConstructor ? process.env.NODE_ENV !== 'production' ? invariant(false, 'SimpleEventPlugin: Unhandled event type, `%s`.', topLevelType) : _prodInvariant('86', topLevelType) : void 0; + var event = EventConstructor.getPooled(dispatchConfig, targetInst, nativeEvent, nativeEventTarget); + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; + }, + + didPutListener: function (inst, registrationName, listener) { + // Mobile Safari does not fire properly bubble click events on + // non-interactive elements, which means delegated click listeners do not + // fire. The workaround for this bug involves attaching an empty click + // listener on the target node. + // http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html + if (registrationName === 'onClick' && !isInteractive(inst._tag)) { + var key = getDictionaryKey(inst); + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + if (!onClickListeners[key]) { + onClickListeners[key] = EventListener.listen(node, 'click', emptyFunction); + } + } + }, + + willDeleteListener: function (inst, registrationName) { + if (registrationName === 'onClick' && !isInteractive(inst._tag)) { + var key = getDictionaryKey(inst); + onClickListeners[key].remove(); + delete onClickListeners[key]; + } + } +}; + +module.exports = SimpleEventPlugin; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 296 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/css3-animations/#AnimationEvent-interface + * @see https://developer.mozilla.org/en-US/docs/Web/API/AnimationEvent + */ +var AnimationEventInterface = { + animationName: null, + elapsedTime: null, + pseudoElement: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticAnimationEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticAnimationEvent, AnimationEventInterface); + +module.exports = SyntheticAnimationEvent; + +/***/ }), +/* 297 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/clipboard-apis/ + */ +var ClipboardEventInterface = { + clipboardData: function (event) { + return 'clipboardData' in event ? event.clipboardData : window.clipboardData; + } +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticClipboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticClipboardEvent, ClipboardEventInterface); + +module.exports = SyntheticClipboardEvent; + +/***/ }), +/* 298 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticUIEvent = __webpack_require__(47); + +/** + * @interface FocusEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var FocusEventInterface = { + relatedTarget: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticFocusEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticUIEvent.augmentClass(SyntheticFocusEvent, FocusEventInterface); + +module.exports = SyntheticFocusEvent; + +/***/ }), +/* 299 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticUIEvent = __webpack_require__(47); + +var getEventCharCode = __webpack_require__(92); +var getEventKey = __webpack_require__(300); +var getEventModifierState = __webpack_require__(81); + +/** + * @interface KeyboardEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var KeyboardEventInterface = { + key: getEventKey, + location: null, + ctrlKey: null, + shiftKey: null, + altKey: null, + metaKey: null, + repeat: null, + locale: null, + getModifierState: getEventModifierState, + // Legacy Interface + charCode: function (event) { + // `charCode` is the result of a KeyPress event and represents the value of + // the actual printable character. + + // KeyPress is deprecated, but its replacement is not yet final and not + // implemented in any major browser. Only KeyPress has charCode. + if (event.type === 'keypress') { + return getEventCharCode(event); + } + return 0; + }, + keyCode: function (event) { + // `keyCode` is the result of a KeyDown/Up event and represents the value of + // physical keyboard key. + + // The actual meaning of the value depends on the users' keyboard layout + // which cannot be detected. Assuming that it is a US keyboard layout + // provides a surprisingly accurate mapping for US and European users. + // Due to this, it is left to the user to implement at this time. + if (event.type === 'keydown' || event.type === 'keyup') { + return event.keyCode; + } + return 0; + }, + which: function (event) { + // `which` is an alias for either `keyCode` or `charCode` depending on the + // type of the event. + if (event.type === 'keypress') { + return getEventCharCode(event); + } + if (event.type === 'keydown' || event.type === 'keyup') { + return event.keyCode; + } + return 0; + } +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticKeyboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticUIEvent.augmentClass(SyntheticKeyboardEvent, KeyboardEventInterface); + +module.exports = SyntheticKeyboardEvent; + +/***/ }), +/* 300 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var getEventCharCode = __webpack_require__(92); + +/** + * Normalization of deprecated HTML5 `key` values + * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names + */ +var normalizeKey = { + Esc: 'Escape', + Spacebar: ' ', + Left: 'ArrowLeft', + Up: 'ArrowUp', + Right: 'ArrowRight', + Down: 'ArrowDown', + Del: 'Delete', + Win: 'OS', + Menu: 'ContextMenu', + Apps: 'ContextMenu', + Scroll: 'ScrollLock', + MozPrintableKey: 'Unidentified' +}; + +/** + * Translation from legacy `keyCode` to HTML5 `key` + * Only special keys supported, all others depend on keyboard layout or browser + * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names + */ +var translateToKey = { + 8: 'Backspace', + 9: 'Tab', + 12: 'Clear', + 13: 'Enter', + 16: 'Shift', + 17: 'Control', + 18: 'Alt', + 19: 'Pause', + 20: 'CapsLock', + 27: 'Escape', + 32: ' ', + 33: 'PageUp', + 34: 'PageDown', + 35: 'End', + 36: 'Home', + 37: 'ArrowLeft', + 38: 'ArrowUp', + 39: 'ArrowRight', + 40: 'ArrowDown', + 45: 'Insert', + 46: 'Delete', + 112: 'F1', + 113: 'F2', + 114: 'F3', + 115: 'F4', + 116: 'F5', + 117: 'F6', + 118: 'F7', + 119: 'F8', + 120: 'F9', + 121: 'F10', + 122: 'F11', + 123: 'F12', + 144: 'NumLock', + 145: 'ScrollLock', + 224: 'Meta' +}; + +/** + * @param {object} nativeEvent Native browser event. + * @return {string} Normalized `key` property. + */ +function getEventKey(nativeEvent) { + if (nativeEvent.key) { + // Normalize inconsistent values reported by browsers due to + // implementations of a working draft specification. + + // FireFox implements `key` but returns `MozPrintableKey` for all + // printable characters (normalized to `Unidentified`), ignore it. + var key = normalizeKey[nativeEvent.key] || nativeEvent.key; + if (key !== 'Unidentified') { + return key; + } + } + + // Browser does not implement `key`, polyfill as much of it as we can. + if (nativeEvent.type === 'keypress') { + var charCode = getEventCharCode(nativeEvent); + + // The enter-key is technically both printable and non-printable and can + // thus be captured by `keypress`, no other non-printable key should. + return charCode === 13 ? 'Enter' : String.fromCharCode(charCode); + } + if (nativeEvent.type === 'keydown' || nativeEvent.type === 'keyup') { + // While user keyboard layout determines the actual meaning of each + // `keyCode` value, almost all function keys have a universal value. + return translateToKey[nativeEvent.keyCode] || 'Unidentified'; + } + return ''; +} + +module.exports = getEventKey; + +/***/ }), +/* 301 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticMouseEvent = __webpack_require__(59); + +/** + * @interface DragEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var DragEventInterface = { + dataTransfer: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticDragEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticMouseEvent.augmentClass(SyntheticDragEvent, DragEventInterface); + +module.exports = SyntheticDragEvent; + +/***/ }), +/* 302 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticUIEvent = __webpack_require__(47); + +var getEventModifierState = __webpack_require__(81); + +/** + * @interface TouchEvent + * @see http://www.w3.org/TR/touch-events/ + */ +var TouchEventInterface = { + touches: null, + targetTouches: null, + changedTouches: null, + altKey: null, + metaKey: null, + ctrlKey: null, + shiftKey: null, + getModifierState: getEventModifierState +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticTouchEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticUIEvent.augmentClass(SyntheticTouchEvent, TouchEventInterface); + +module.exports = SyntheticTouchEvent; + +/***/ }), +/* 303 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticEvent = __webpack_require__(26); + +/** + * @interface Event + * @see http://www.w3.org/TR/2009/WD-css3-transitions-20090320/#transition-events- + * @see https://developer.mozilla.org/en-US/docs/Web/API/TransitionEvent + */ +var TransitionEventInterface = { + propertyName: null, + elapsedTime: null, + pseudoElement: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticTransitionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticEvent.augmentClass(SyntheticTransitionEvent, TransitionEventInterface); + +module.exports = SyntheticTransitionEvent; + +/***/ }), +/* 304 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var SyntheticMouseEvent = __webpack_require__(59); + +/** + * @interface WheelEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var WheelEventInterface = { + deltaX: function (event) { + return 'deltaX' in event ? event.deltaX : // Fallback to `wheelDeltaX` for Webkit and normalize (right is positive). + 'wheelDeltaX' in event ? -event.wheelDeltaX : 0; + }, + deltaY: function (event) { + return 'deltaY' in event ? event.deltaY : // Fallback to `wheelDeltaY` for Webkit and normalize (down is positive). + 'wheelDeltaY' in event ? -event.wheelDeltaY : // Fallback to `wheelDelta` for IE<9 and normalize (down is positive). + 'wheelDelta' in event ? -event.wheelDelta : 0; + }, + deltaZ: null, + + // Browsers without "deltaMode" is reporting in raw wheel delta where one + // notch on the scroll is always +/- 120, roughly equivalent to pixels. + // A good approximation of DOM_DELTA_LINE (1) is 5% of viewport size or + // ~40 pixels, for DOM_DELTA_SCREEN (2) it is 87.5% of viewport size. + deltaMode: null +}; + +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticMouseEvent} + */ +function SyntheticWheelEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} + +SyntheticMouseEvent.augmentClass(SyntheticWheelEvent, WheelEventInterface); + +module.exports = SyntheticWheelEvent; + +/***/ }), +/* 305 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var validateDOMNesting = __webpack_require__(91); + +var DOC_NODE_TYPE = 9; + +function ReactDOMContainerInfo(topLevelWrapper, node) { + var info = { + _topLevelWrapper: topLevelWrapper, + _idCounter: 1, + _ownerDocument: node ? node.nodeType === DOC_NODE_TYPE ? node : node.ownerDocument : null, + _node: node, + _tag: node ? node.nodeName.toLowerCase() : null, + _namespaceURI: node ? node.namespaceURI : null + }; + if (process.env.NODE_ENV !== 'production') { + info._ancestorInfo = node ? validateDOMNesting.updatedAncestorInfo(null, info._tag, null) : null; + } + return info; +} + +module.exports = ReactDOMContainerInfo; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 306 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactDOMFeatureFlags = { + useCreateElement: true, + useFiber: false +}; + +module.exports = ReactDOMFeatureFlags; + +/***/ }), +/* 307 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var adler32 = __webpack_require__(308); + +var TAG_END = /\/?>/; +var COMMENT_START = /^<\!\-\-/; + +var ReactMarkupChecksum = { + CHECKSUM_ATTR_NAME: 'data-react-checksum', + + /** + * @param {string} markup Markup string + * @return {string} Markup string with checksum attribute attached + */ + addChecksumToMarkup: function (markup) { + var checksum = adler32(markup); + + // Add checksum (handle both parent tags, comments and self-closing tags) + if (COMMENT_START.test(markup)) { + return markup; + } else { + return markup.replace(TAG_END, ' ' + ReactMarkupChecksum.CHECKSUM_ATTR_NAME + '="' + checksum + '"$&'); + } + }, + + /** + * @param {string} markup to use + * @param {DOMElement} element root React element + * @returns {boolean} whether or not the markup is the same + */ + canReuseMarkup: function (markup, element) { + var existingChecksum = element.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + existingChecksum = existingChecksum && parseInt(existingChecksum, 10); + var markupChecksum = adler32(markup); + return markupChecksum === existingChecksum; + } +}; + +module.exports = ReactMarkupChecksum; + +/***/ }), +/* 308 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ + + + +var MOD = 65521; + +// adler32 is not cryptographically strong, and is only used to sanity check that +// markup generated on the server matches the markup generated on the client. +// This implementation (a modified version of the SheetJS version) has been optimized +// for our use case, at the expense of conforming to the adler32 specification +// for non-ascii inputs. +function adler32(data) { + var a = 1; + var b = 0; + var i = 0; + var l = data.length; + var m = l & ~0x3; + while (i < m) { + var n = Math.min(i + 4096, m); + for (; i < n; i += 4) { + b += (a += data.charCodeAt(i)) + (a += data.charCodeAt(i + 1)) + (a += data.charCodeAt(i + 2)) + (a += data.charCodeAt(i + 3)); + } + a %= MOD; + b %= MOD; + } + for (; i < l; i++) { + b += a += data.charCodeAt(i); + } + a %= MOD; + b %= MOD; + return a | b << 16; +} + +module.exports = adler32; + +/***/ }), +/* 309 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +module.exports = '15.6.1'; + +/***/ }), +/* 310 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactCurrentOwner = __webpack_require__(22); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstanceMap = __webpack_require__(48); + +var getHostComponentFromComposite = __webpack_require__(150); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +/** + * Returns the DOM node rendered by this element. + * + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.finddomnode + * + * @param {ReactComponent|DOMElement} componentOrElement + * @return {?DOMElement} The root node of this element. + */ +function findDOMNode(componentOrElement) { + if (process.env.NODE_ENV !== 'production') { + var owner = ReactCurrentOwner.current; + if (owner !== null) { + process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing findDOMNode inside its render(). ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; + owner._warnedAboutRefsInRender = true; + } + } + if (componentOrElement == null) { + return null; + } + if (componentOrElement.nodeType === 1) { + return componentOrElement; + } + + var inst = ReactInstanceMap.get(componentOrElement); + if (inst) { + inst = getHostComponentFromComposite(inst); + return inst ? ReactDOMComponentTree.getNodeFromInstance(inst) : null; + } + + if (typeof componentOrElement.render === 'function') { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'findDOMNode was called on an unmounted component.') : _prodInvariant('44') : void 0; + } else { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element appears to be neither ReactComponent nor DOMNode (keys: %s)', Object.keys(componentOrElement)) : _prodInvariant('45', Object.keys(componentOrElement)) : void 0; + } +} + +module.exports = findDOMNode; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 311 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactMount = __webpack_require__(149); + +module.exports = ReactMount.renderSubtreeIntoContainer; + +/***/ }), +/* 312 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var EventPluginRegistry = __webpack_require__(57); +var ReactComponentTreeHook = __webpack_require__(17); + +var warning = __webpack_require__(3); + +if (process.env.NODE_ENV !== 'production') { + var reactProps = { + children: true, + dangerouslySetInnerHTML: true, + key: true, + ref: true, + + autoFocus: true, + defaultValue: true, + valueLink: true, + defaultChecked: true, + checkedLink: true, + innerHTML: true, + suppressContentEditableWarning: true, + onFocusIn: true, + onFocusOut: true + }; + var warnedProperties = {}; - if (e.target && !container.contains(e.target) && this.props.toggle) { - this.props.toggle(); - } + var validateProperty = function (tagName, name, debugID) { + if (DOMProperty.properties.hasOwnProperty(name) || DOMProperty.isCustomAttribute(name)) { + return true; } - }, { - key: 'hasTransition', - value: function hasTransition() { - if (this.props.fade === false) { - return false; - } - - return this.props.modalTransitionTimeout > 0; + if (reactProps.hasOwnProperty(name) && reactProps[name] || warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { + return true; } - }, { - key: 'togglePortal', - value: function togglePortal() { - if (this.props.isOpen) { - if (this.props.autoFocus) { - this._focus = true; - } - this.show(); - if (!this.hasTransition()) { - this.onEnter(); - } - } else { - this.hide(); - if (!this.hasTransition()) { - this.onExit(); - } - } + if (EventPluginRegistry.registrationNameModules.hasOwnProperty(name)) { + return true; } - }, { - key: 'destroy', - value: function destroy() { - if (this._element) { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); - document.body.removeChild(this._element); - this._element = null; - } + warnedProperties[name] = true; + var lowerCasedName = name.toLowerCase(); - // Use regex to prevent matching `modal-open` as part of a different class, e.g. `my-modal-opened` - var classes = document.body.className.replace(/(^| )modal-open( |$)/, ' '); - document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes).trim(), this.props.cssModule); - setScrollbarWidth(this.originalBodyPadding); + // data-* attributes should be lowercase; suggest the lowercase version + var standardName = DOMProperty.isCustomAttribute(lowerCasedName) ? lowerCasedName : DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; + + var registrationName = EventPluginRegistry.possibleRegistrationNames.hasOwnProperty(lowerCasedName) ? EventPluginRegistry.possibleRegistrationNames[lowerCasedName] : null; + + if (standardName != null) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown DOM property %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + return true; + } else if (registrationName != null) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown event handler property %s. Did you mean `%s`?%s', name, registrationName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + return true; + } else { + // We were unable to guess which prop the user intended. + // It is likely that the user was just blindly spreading/forwarding props + // Components should be careful to only render valid props/attributes. + // Warning will be invoked in warnUnknownProperties to allow grouping. + return false; } - }, { - key: 'hide', - value: function hide() { - this.renderIntoSubtree(); + }; +} + +var warnUnknownProperties = function (debugID, element) { + var unknownProps = []; + for (var key in element.props) { + var isValid = validateProperty(element.type, key, debugID); + if (!isValid) { + unknownProps.push(key); } - }, { - key: 'show', - value: function show() { - var classes = document.body.className; - this._element = document.createElement('div'); - this._element.setAttribute('tabindex', '-1'); - this._element.style.position = 'relative'; - this._element.style.zIndex = this.props.zIndex; - this.originalBodyPadding = getOriginalBodyPadding(); + } - conditionallyUpdateScrollbar(); + var unknownPropString = unknownProps.map(function (prop) { + return '`' + prop + '`'; + }).join(', '); - document.body.appendChild(this._element); + if (unknownProps.length === 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown prop %s on <%s> tag. Remove this prop from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } else if (unknownProps.length > 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown props %s on <%s> tag. Remove these props from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } +}; - document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes, 'modal-open'), this.props.cssModule); +function handleElement(debugID, element) { + if (element == null || typeof element.type !== 'string') { + return; + } + if (element.type.indexOf('-') >= 0 || element.props.is) { + return; + } + warnUnknownProperties(debugID, element); +} - this.renderIntoSubtree(); +var ReactDOMUnknownPropertyHook = { + onBeforeMountComponent: function (debugID, element) { + handleElement(debugID, element); + }, + onBeforeUpdateComponent: function (debugID, element) { + handleElement(debugID, element); + } +}; + +module.exports = ReactDOMUnknownPropertyHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 313 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var ReactComponentTreeHook = __webpack_require__(17); + +var warning = __webpack_require__(3); + +var didWarnValueNull = false; + +function handleElement(debugID, element) { + if (element == null) { + return; + } + if (element.type !== 'input' && element.type !== 'textarea' && element.type !== 'select') { + return; + } + if (element.props != null && element.props.value === null && !didWarnValueNull) { + process.env.NODE_ENV !== 'production' ? warning(false, '`value` prop on `%s` should not be null. ' + 'Consider using the empty string to clear the component or `undefined` ' + 'for uncontrolled components.%s', element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + + didWarnValueNull = true; + } +} + +var ReactDOMNullInputValuePropHook = { + onBeforeMountComponent: function (debugID, element) { + handleElement(debugID, element); + }, + onBeforeUpdateComponent: function (debugID, element) { + handleElement(debugID, element); + } +}; + +module.exports = ReactDOMNullInputValuePropHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 314 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var ReactComponentTreeHook = __webpack_require__(17); + +var warning = __webpack_require__(3); + +var warnedProperties = {}; +var rARIA = new RegExp('^(aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); + +function validateProperty(tagName, name, debugID) { + if (warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { + return true; + } + + if (rARIA.test(name)) { + var lowerCasedName = name.toLowerCase(); + var standardName = DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; + + // If this is an aria-* attribute, but is not listed in the known DOM + // DOM properties, then it is an invalid aria-* attribute. + if (standardName == null) { + warnedProperties[name] = true; + return false; } - }, { - key: 'renderModalDialog', - value: function renderModalDialog() { - var _this2 = this; + // aria-* attributes should be lowercase; suggest the lowercase version. + if (name !== standardName) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown ARIA attribute %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + warnedProperties[name] = true; + return true; + } + } - var attributes = omit(this.props, propsToOmit); + return true; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - _extends({ - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-dialog', this.props.className, defineProperty({}, 'modal-' + this.props.size, this.props.size)), this.props.cssModule), - role: 'document', - ref: function ref(c) { - return _this2._dialog = c; - } - }, attributes), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - { - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-content', this.props.contentClassName), this.props.cssModule) - }, - this.props.children - ) - ); +function warnInvalidARIAProps(debugID, element) { + var invalidProps = []; + + for (var key in element.props) { + var isValid = validateProperty(element.type, key, debugID); + if (!isValid) { + invalidProps.push(key); } - }, { - key: 'renderIntoSubtree', - value: function renderIntoSubtree() { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); + } - // check if modal should receive focus - if (this._focus) { - this._dialog.parentNode.focus(); - this._focus = false; - } + var unknownPropString = invalidProps.map(function (prop) { + return '`' + prop + '`'; + }).join(', '); + + if (invalidProps.length === 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria prop %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } else if (invalidProps.length > 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria props %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } +} + +function handleElement(debugID, element) { + if (element == null || typeof element.type !== 'string') { + return; + } + if (element.type.indexOf('-') >= 0 || element.props.is) { + return; + } + + warnInvalidARIAProps(debugID, element); +} + +var ReactDOMInvalidARIAHook = { + onBeforeMountComponent: function (debugID, element) { + if (process.env.NODE_ENV !== 'production') { + handleElement(debugID, element); } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _props = this.props, - wrapClassName = _props.wrapClassName, - modalClassName = _props.modalClassName, - backdropClassName = _props.backdropClassName, - cssModule = _props.cssModule, - isOpen = _props.isOpen, - backdrop = _props.backdrop, - modalTransitionTimeout = _props.modalTransitionTimeout, - backdropTransitionTimeout = _props.backdropTransitionTimeout; + }, + onBeforeUpdateComponent: function (debugID, element) { + if (process.env.NODE_ENV !== 'production') { + handleElement(debugID, element); + } + } +}; +module.exports = ReactDOMInvalidARIAHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var modalAttributes = { - onClickCapture: this.handleBackdropClick, - onKeyUp: this.handleEscape, - style: { display: 'block' }, - tabIndex: '-1' - }; +/***/ }), +/* 315 */ +/***/ (function(module, exports, __webpack_require__) { - if (this.hasTransition()) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["TransitionGroup"], - { component: 'div', className: mapToCssModules(wrapClassName) }, - isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Fade, - _extends({ - key: 'modal-dialog', - onEnter: this.onEnter, - onLeave: this.onExit, - transitionAppearTimeout: typeof this.props.modalTransitionAppearTimeout === 'number' ? this.props.modalTransitionAppearTimeout : modalTransitionTimeout, - transitionEnterTimeout: typeof this.props.modalTransitionEnterTimeout === 'number' ? this.props.modalTransitionEnterTimeout : modalTransitionTimeout, - transitionLeaveTimeout: typeof this.props.modalTransitionLeaveTimeout === 'number' ? this.props.modalTransitionLeaveTimeout : modalTransitionTimeout, - cssModule: cssModule, - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', modalClassName), cssModule) - }, modalAttributes), - this.renderModalDialog() - ), - isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Fade, { - key: 'modal-backdrop', - transitionAppearTimeout: typeof this.props.backdropTransitionAppearTimeout === 'number' ? this.props.backdropTransitionAppearTimeout : backdropTransitionTimeout, - transitionEnterTimeout: typeof this.props.backdropTransitionEnterTimeout === 'number' ? this.props.backdropTransitionEnterTimeout : backdropTransitionTimeout, - transitionLeaveTimeout: typeof this.props.backdropTransitionLeaveTimeout === 'number' ? this.props.backdropTransitionLeaveTimeout : backdropTransitionTimeout, - cssModule: cssModule, - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', backdropClassName), cssModule) - }) - ); - } +"use strict"; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - { className: mapToCssModules(wrapClassName) }, - isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - _extends({ - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', 'show', modalClassName), cssModule) - }, modalAttributes), - this.renderModalDialog() - ), - isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', 'show', backdropClassName), cssModule) - }) - ); + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactstrap = __webpack_require__(93); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var ZNavbar = function (_React$Component) { + _inherits(ZNavbar, _React$Component); + + function ZNavbar(props) { + _classCallCheck(this, ZNavbar); + + var _this = _possibleConstructorReturn(this, (ZNavbar.__proto__ || Object.getPrototypeOf(ZNavbar)).call(this, props)); + + _this.toggleNavbar = _this.toggleNavbar.bind(_this); + _this.state = { + isOpen: false + }; + return _this; + } + + _createClass(ZNavbar, [{ + key: 'toggleNavbar', + value: function toggleNavbar() { + this.setState({ + isOpen: !this.state.isOpen + }); } }, { key: 'render', value: function render() { - return null; + return _react2.default.createElement( + _reactstrap.Navbar, + { color: 'faded', light: true, toggleable: true }, + _react2.default.createElement(_reactstrap.NavbarToggler, { right: true, onClick: this.toggleNavbar }), + _react2.default.createElement( + _reactstrap.NavbarBrand, + { href: '/' }, + _react2.default.createElement('img', { src: '/favicon.ico', height: 42 }), + '\xA0myzenwallet.io' + ), + _react2.default.createElement( + _reactstrap.Collapse, + { isOpen: this.state.isOpen, navbar: true }, + _react2.default.createElement( + _reactstrap.Nav, + { className: 'ml-auto', navbar: true }, + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: 'http://getzen.cash' }, + 'FREE ZEN' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: '/faq.html' }, + 'FAQ' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: '/guide.html' }, + 'GETTING STARTED' + ) + ) + ) + ) + ); } }]); - return Modal; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -Modal.propTypes = propTypes$40; -Modal.defaultProps = defaultProps$39; + return ZNavbar; +}(_react2.default.Component); -var propTypes$41 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - wrapTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node -}; +exports.default = ZNavbar; + +/***/ }), +/* 316 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ + + + +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); +var ReactPropTypesSecret = __webpack_require__(75); + +module.exports = function() { + function shim(props, propName, componentName, location, propFullName, secret) { + if (secret === ReactPropTypesSecret) { + // It is still safe when called from React. + return; + } + invariant( + false, + 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + + 'Use PropTypes.checkPropTypes() to call them. ' + + 'Read more at http://fb.me/use-check-prop-types' + ); + }; + shim.isRequired = shim; + function getShim() { + return shim; + }; + // Important! + // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`. + var ReactPropTypes = { + array: shim, + bool: shim, + func: shim, + number: shim, + object: shim, + string: shim, + symbol: shim, + + any: shim, + arrayOf: getShim, + element: shim, + instanceOf: getShim, + node: shim, + objectOf: getShim, + oneOf: getShim, + oneOfType: getShim, + shape: getShim + }; -var defaultProps$40 = { - tag: 'h4', - wrapTag: 'div' -}; + ReactPropTypes.checkPropTypes = emptyFunction; + ReactPropTypes.PropTypes = ReactPropTypes; -var ModalHeader = function ModalHeader(props) { - var closeButton = void 0; - var className = props.className, - cssModule = props.cssModule, - children = props.children, - toggle = props.toggle, - Tag = props.tag, - WrapTag = props.wrapTag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'toggle', 'tag', 'wrapTag']); + return ReactPropTypes; +}; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-header'), cssModule); +/***/ }), +/* 317 */ +/***/ (function(module, exports) { - if (toggle) { - closeButton = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'button', - { type: 'button', onClick: toggle, className: 'close', 'aria-label': 'Close' }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { 'aria-hidden': 'true' }, - String.fromCharCode(215) - ) - ); - } +/** + * lodash 3.0.2 (Custom Build) <https://lodash.com/> + * Build: `lodash modern modularize exports="npm" -o ./` + * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license <https://lodash.com/license> + */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - WrapTag, - _extends({}, attributes, { className: classes }), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - { className: mapToCssModules('modal-title', cssModule) }, - children - ), - closeButton - ); -}; +/** + * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. + * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(1); + * // => false + */ +function isObject(value) { + // Avoid a V8 JIT bug in Chrome 19-20. + // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} -ModalHeader.propTypes = propTypes$41; -ModalHeader.defaultProps = defaultProps$40; +module.exports = isObject; -var propTypes$42 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$41 = { - tag: 'div' -}; +/***/ }), +/* 318 */ +/***/ (function(module, exports) { -var ModalBody = function ModalBody(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/** + * lodash 3.0.8 (Custom Build) <https://lodash.com/> + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation <http://dojofoundation.org/> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license <https://lodash.com/license> + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-body'), cssModule); +/** `Object#toString` result references. */ +var funcTag = '[object Function]', + genTag = '[object GeneratorFunction]'; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/** Used for built-in method references. */ +var objectProto = Object.prototype; -ModalBody.propTypes = propTypes$42; -ModalBody.defaultProps = defaultProps$41; +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; -var propTypes$43 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/** + * Checks if `value` is classified as a `Function` object. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isFunction(_); + * // => true + * + * _.isFunction(/abc/); + * // => false + */ +function isFunction(value) { + // The use of `Object#toString` avoids issues with the `typeof` operator + // in Safari 8 which returns 'object' for typed array constructors, and + // PhantomJS 1.9 which returns 'function' for `NodeList` instances. + var tag = isObject(value) ? objectToString.call(value) : ''; + return tag == funcTag || tag == genTag; +} -var defaultProps$42 = { - tag: 'div' -}; +/** + * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. + * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} -var ModalFooter = function ModalFooter(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +module.exports = isFunction; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-footer'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 319 */ +/***/ (function(module, exports, __webpack_require__) { -ModalFooter.propTypes = propTypes$43; -ModalFooter.defaultProps = defaultProps$42; +var require;var require;/*! tether 1.3.4 */ +(function(f){if(true){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Tether = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ +'use strict'; -var propTypes$44 = { - placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), - target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - autohide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]) -}; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } -var DEFAULT_DELAYS = { - show: 0, - hide: 250 -}; +var _utils = require('./utils'); -var defaultProps$43 = { - isOpen: false, - placement: 'bottom', - delay: DEFAULT_DELAYS, - autohide: true, - toggle: function toggle() {} -}; +var _utils2 = _interopRequireDefault(_utils); -var defaultTetherConfig$2 = { - classPrefix: 'bs-tether', - classes: { - element: false, - enabled: 'show' - }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; +var _TetherBase$Utils = _utils2['default'].Utils; +var getBounds = _TetherBase$Utils.getBounds; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; -var Tooltip = function (_React$Component) { - inherits(Tooltip, _React$Component); +_utils2['default'].modules.push({ + position: function position(_ref) { + var _this = this; - function Tooltip(props) { - classCallCheck(this, Tooltip); + var top = _ref.top; + var left = _ref.left; - var _this = possibleConstructorReturn(this, (Tooltip.__proto__ || Object.getPrototypeOf(Tooltip)).call(this, props)); + var _cache = this.cache('element-bounds', function () { + return getBounds(_this.element); + }); - _this.addTargetEvents = _this.addTargetEvents.bind(_this); - _this.getTarget = _this.getTarget.bind(_this); - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.removeTargetEvents = _this.removeTargetEvents.bind(_this); - _this.toggle = _this.toggle.bind(_this); - _this.onMouseOverTooltip = _this.onMouseOverTooltip.bind(_this); - _this.onMouseLeaveTooltip = _this.onMouseLeaveTooltip.bind(_this); - _this.onMouseOverTooltipContent = _this.onMouseOverTooltipContent.bind(_this); - _this.onMouseLeaveTooltipContent = _this.onMouseLeaveTooltipContent.bind(_this); - _this.show = _this.show.bind(_this); - _this.hide = _this.hide.bind(_this); - return _this; - } + var height = _cache.height; + var width = _cache.width; - createClass(Tooltip, [{ - key: 'componentDidMount', - value: function componentDidMount() { - this._target = this.getTarget(); - this.addTargetEvents(); - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.removeTargetEvents(); - } - }, { - key: 'onMouseOverTooltip', - value: function onMouseOverTooltip() { - if (this._hideTimeout) { - this.clearHideTimeout(); - } - this._showTimeout = setTimeout(this.show, this.getDelay('show')); - } - }, { - key: 'onMouseLeaveTooltip', - value: function onMouseLeaveTooltip() { - if (this._showTimeout) { - this.clearShowTimeout(); - } - this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); - } - }, { - key: 'onMouseOverTooltipContent', - value: function onMouseOverTooltipContent() { - if (this.props.autohide) { - return; - } - if (this._hideTimeout) { - this.clearHideTimeout(); - } - } - }, { - key: 'onMouseLeaveTooltipContent', - value: function onMouseLeaveTooltipContent() { - if (this.props.autohide) { - return; - } - if (this._showTimeout) { - this.clearShowTimeout(); - } - this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); - } - }, { - key: 'getDelay', - value: function getDelay(key) { - var delay = this.props.delay; + var targetPos = this.getTargetBounds(); - if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { - return isNaN(delay[key]) ? DEFAULT_DELAYS[key] : delay[key]; - } - return delay; - } - }, { - key: 'getTarget', - value: function getTarget() { - var target = this.props.target; + var bottom = top + height; + var right = left + width; - if ((typeof target === 'undefined' ? 'undefined' : _typeof(target)) === 'object') { - return target; - } - return document.getElementById(target); - } - }, { - key: 'getTetherConfig', - value: function getTetherConfig() { - var attachments = getTetherAttachments(this.props.placement); - return _extends({}, defaultTetherConfig$2, attachments, { - target: this.getTarget - }, this.props.tether); - } - }, { - key: 'show', - value: function show() { - if (!this.props.isOpen) { - this.clearShowTimeout(); - this.toggle(); - } - } - }, { - key: 'hide', - value: function hide() { - if (this.props.isOpen) { - this.clearHideTimeout(); - this.toggle(); - } - } - }, { - key: 'clearShowTimeout', - value: function clearShowTimeout() { - clearTimeout(this._showTimeout); - this._showTimeout = undefined; - } - }, { - key: 'clearHideTimeout', - value: function clearHideTimeout() { - clearTimeout(this._hideTimeout); - this._hideTimeout = undefined; - } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - if (e.target === this._target || this._target.contains(e.target)) { - if (this._hideTimeout) { - this.clearHideTimeout(); + var abutted = []; + if (top <= targetPos.bottom && bottom >= targetPos.top) { + ['left', 'right'].forEach(function (side) { + var targetPosSide = targetPos[side]; + if (targetPosSide === left || targetPosSide === right) { + abutted.push(side); } + }); + } - if (!this.props.isOpen) { - this.toggle(); + if (left <= targetPos.right && right >= targetPos.left) { + ['top', 'bottom'].forEach(function (side) { + var targetPosSide = targetPos[side]; + if (targetPosSide === top || targetPosSide === bottom) { + abutted.push(side); } - } - } - }, { - key: 'addTargetEvents', - value: function addTargetEvents() { - this._target.addEventListener('mouseover', this.onMouseOverTooltip, true); - this._target.addEventListener('mouseout', this.onMouseLeaveTooltip, true); - document.addEventListener('click', this.handleDocumentClick, true); - } - }, { - key: 'removeTargetEvents', - value: function removeTargetEvents() { - this._target.removeEventListener('mouseover', this.onMouseOverTooltip, true); - this._target.removeEventListener('mouseout', this.onMouseLeaveTooltip, true); - document.removeEventListener('click', this.handleDocumentClick, true); + }); } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); - } - return this.props.toggle(); + var allClasses = []; + var addClasses = []; + + var sides = ['left', 'top', 'right', 'bottom']; + allClasses.push(this.getClass('abutted')); + sides.forEach(function (side) { + allClasses.push(_this.getClass('abutted') + '-' + side); + }); + + if (abutted.length) { + addClasses.push(this.getClass('abutted')); } - }, { - key: 'render', - value: function render() { - if (!this.props.isOpen) { - return null; + + abutted.forEach(function (side) { + addClasses.push(_this.getClass('abutted') + '-' + side); + }); + + defer(function () { + if (!(_this.options.addTargetClasses === false)) { + updateClasses(_this.target, addClasses, allClasses); } + updateClasses(_this.element, addClasses, allClasses); + }); - var attributes = omit(this.props, Object.keys(propTypes$44)); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tooltip-inner', this.props.className), this.props.cssModule); + return true; + } +}); - var tetherConfig = this.getTetherConfig(); +},{"./utils":5}],2:[function(require,module,exports){ +'use strict'; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - { - className: 'tooltip', - tether: tetherConfig, - tetherRef: this.props.tetherRef, - isOpen: this.props.isOpen, - toggle: this.toggle - }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { - className: classes, - onMouseOver: this.onMouseOverTooltipContent, - onMouseLeave: this.onMouseLeaveTooltipContent - })) - ); - } - }]); - return Tooltip; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); -Tooltip.propTypes = propTypes$44; -Tooltip.defaultProps = defaultProps$43; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } -var propTypes$45 = { - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - bordered: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - hover: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - reflow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - responsive: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - responsiveTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; +var _utils = require('./utils'); -var defaultProps$44 = { - tag: 'table', - responsiveTag: 'div' -}; +var _utils2 = _interopRequireDefault(_utils); -var Table = function Table(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - bordered = props.bordered, - striped = props.striped, - inverse = props.inverse, - hover = props.hover, - reflow = props.reflow, - responsive = props.responsive, - Tag = props.tag, - ResponsiveTag = props.responsiveTag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'bordered', 'striped', 'inverse', 'hover', 'reflow', 'responsive', 'tag', 'responsiveTag']); +var _TetherBase$Utils = _utils2['default'].Utils; +var getBounds = _TetherBase$Utils.getBounds; +var extend = _TetherBase$Utils.extend; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; + +var BOUNDS_FORMAT = ['left', 'top', 'right', 'bottom']; + +function getBoundingRect(tether, to) { + if (to === 'scrollParent') { + to = tether.scrollParents[0]; + } else if (to === 'window') { + to = [pageXOffset, pageYOffset, innerWidth + pageXOffset, innerHeight + pageYOffset]; + } + if (to === document) { + to = to.documentElement; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'table', size ? 'table-' + size : false, bordered ? 'table-bordered' : false, striped ? 'table-striped' : false, inverse ? 'table-inverse' : false, hover ? 'table-hover' : false, reflow ? 'table-reflow' : false), cssModule); + if (typeof to.nodeType !== 'undefined') { + (function () { + var node = to; + var size = getBounds(to); + var pos = size; + var style = getComputedStyle(to); - var table = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + to = [pos.left, pos.top, size.width + pos.left, size.height + pos.top]; - if (responsive) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - ResponsiveTag, - { className: 'table-responsive' }, - table - ); + // Account any parent Frames scroll offset + if (node.ownerDocument !== document) { + var win = node.ownerDocument.defaultView; + to[0] += win.pageXOffset; + to[1] += win.pageYOffset; + to[2] += win.pageXOffset; + to[3] += win.pageYOffset; + } + + BOUNDS_FORMAT.forEach(function (side, i) { + side = side[0].toUpperCase() + side.substr(1); + if (side === 'Top' || side === 'Left') { + to[i] += parseFloat(style['border' + side + 'Width']); + } else { + to[i] -= parseFloat(style['border' + side + 'Width']); + } + }); + })(); } - return table; -}; + return to; +} -Table.propTypes = propTypes$45; -Table.defaultProps = defaultProps$44; +_utils2['default'].modules.push({ + position: function position(_ref) { + var _this = this; -var propTypes$46 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - flush: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var top = _ref.top; + var left = _ref.left; + var targetAttachment = _ref.targetAttachment; -var defaultProps$45 = { - tag: 'ul' -}; + if (!this.options.constraints) { + return true; + } -var ListGroup = function ListGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - flush = props.flush, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'flush']); + var _cache = this.cache('element-bounds', function () { + return getBounds(_this.element); + }); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group', flush ? 'list-group-flush' : false), cssModule); + var height = _cache.height; + var width = _cache.width; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { + var _lastSize = this.lastSize; -ListGroup.propTypes = propTypes$46; -ListGroup.defaultProps = defaultProps$45; + // Handle the item getting hidden as a result of our positioning without glitching + // the classes in and out + width = _lastSize.width; + height = _lastSize.height; + } -var propTypes$47 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var targetSize = this.cache('target-bounds', function () { + return _this.getTargetBounds(); + }); -var defaultProps$46 = { - tag: 'form' -}; + var targetHeight = targetSize.height; + var targetWidth = targetSize.width; -var Form = function Form(props) { - var className = props.className, - cssModule = props.cssModule, - inline = props.inline, - Tag = props.tag, - getRef = props.getRef, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'tag', 'getRef']); + var allClasses = [this.getClass('pinned'), this.getClass('out-of-bounds')]; + this.options.constraints.forEach(function (constraint) { + var outOfBoundsClass = constraint.outOfBoundsClass; + var pinnedClass = constraint.pinnedClass; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, inline ? 'form-inline' : false), cssModule); + if (outOfBoundsClass) { + allClasses.push(outOfBoundsClass); + } + if (pinnedClass) { + allClasses.push(pinnedClass); + } + }); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); -}; + allClasses.forEach(function (cls) { + ['left', 'top', 'right', 'bottom'].forEach(function (side) { + allClasses.push(cls + '-' + side); + }); + }); -Form.propTypes = propTypes$47; -Form.defaultProps = defaultProps$46; + var addClasses = []; -var propTypes$48 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var tAttachment = extend({}, targetAttachment); + var eAttachment = extend({}, this.attachment); -var defaultProps$47 = { - tag: 'div' -}; + this.options.constraints.forEach(function (constraint) { + var to = constraint.to; + var attachment = constraint.attachment; + var pin = constraint.pin; -var FormFeedback = function FormFeedback(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + if (typeof attachment === 'undefined') { + attachment = ''; + } + var changeAttachX = undefined, + changeAttachY = undefined; + if (attachment.indexOf(' ') >= 0) { + var _attachment$split = attachment.split(' '); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'form-control-feedback'), cssModule); + var _attachment$split2 = _slicedToArray(_attachment$split, 2); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + changeAttachY = _attachment$split2[0]; + changeAttachX = _attachment$split2[1]; + } else { + changeAttachX = changeAttachY = attachment; + } -FormFeedback.propTypes = propTypes$48; -FormFeedback.defaultProps = defaultProps$47; + var bounds = getBoundingRect(_this, to); -var propTypes$49 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - row: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + if (changeAttachY === 'target' || changeAttachY === 'both') { + if (top < bounds[1] && tAttachment.top === 'top') { + top += targetHeight; + tAttachment.top = 'bottom'; + } -var defaultProps$48 = { - tag: 'div' -}; + if (top + height > bounds[3] && tAttachment.top === 'bottom') { + top -= targetHeight; + tAttachment.top = 'top'; + } + } -var FormGroup = function FormGroup(props) { - var className = props.className, - cssModule = props.cssModule, - row = props.row, - disabled = props.disabled, - color = props.color, - check = props.check, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'row', 'disabled', 'color', 'check', 'tag']); + if (changeAttachY === 'together') { + if (tAttachment.top === 'top') { + if (eAttachment.top === 'bottom' && top < bounds[1]) { + top += targetHeight; + tAttachment.top = 'bottom'; + top += height; + eAttachment.top = 'top'; + } else if (eAttachment.top === 'top' && top + height > bounds[3] && top - (height - targetHeight) >= bounds[1]) { + top -= height - targetHeight; + tAttachment.top = 'bottom'; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, color ? 'has-' + color : false, row ? 'row' : false, check ? 'form-check' : 'form-group', check && disabled ? 'disabled' : false), cssModule); + eAttachment.top = 'bottom'; + } + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + if (tAttachment.top === 'bottom') { + if (eAttachment.top === 'top' && top + height > bounds[3]) { + top -= targetHeight; + tAttachment.top = 'top'; -FormGroup.propTypes = propTypes$49; -FormGroup.defaultProps = defaultProps$48; + top -= height; + eAttachment.top = 'bottom'; + } else if (eAttachment.top === 'bottom' && top < bounds[1] && top + (height * 2 - targetHeight) <= bounds[3]) { + top += height - targetHeight; + tAttachment.top = 'top'; -var propTypes$50 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + eAttachment.top = 'top'; + } + } -var defaultProps$49 = { - tag: 'small' -}; + if (tAttachment.top === 'middle') { + if (top + height > bounds[3] && eAttachment.top === 'top') { + top -= height; + eAttachment.top = 'bottom'; + } else if (top < bounds[1] && eAttachment.top === 'bottom') { + top += height; + eAttachment.top = 'top'; + } + } + } -var FormText = function FormText(props) { - var className = props.className, - cssModule = props.cssModule, - inline = props.inline, - color = props.color, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'color', 'tag']); + if (changeAttachX === 'target' || changeAttachX === 'both') { + if (left < bounds[0] && tAttachment.left === 'left') { + left += targetWidth; + tAttachment.left = 'right'; + } + if (left + width > bounds[2] && tAttachment.left === 'right') { + left -= targetWidth; + tAttachment.left = 'left'; + } + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, !inline ? 'form-text' : false, color ? 'text-' + color : false), cssModule); + if (changeAttachX === 'together') { + if (left < bounds[0] && tAttachment.left === 'left') { + if (eAttachment.left === 'right') { + left += targetWidth; + tAttachment.left = 'right'; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + left += width; + eAttachment.left = 'left'; + } else if (eAttachment.left === 'left') { + left += targetWidth; + tAttachment.left = 'right'; -FormText.propTypes = propTypes$50; -FormText.defaultProps = defaultProps$49; + left -= width; + eAttachment.left = 'right'; + } + } else if (left + width > bounds[2] && tAttachment.left === 'right') { + if (eAttachment.left === 'left') { + left -= targetWidth; + tAttachment.left = 'left'; -/* eslint react/prefer-stateless-function: 0 */ + left -= width; + eAttachment.left = 'right'; + } else if (eAttachment.left === 'right') { + left -= targetWidth; + tAttachment.left = 'left'; -var propTypes$51 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - state: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - static: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - addon: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + left += width; + eAttachment.left = 'left'; + } + } else if (tAttachment.left === 'center') { + if (left + width > bounds[2] && eAttachment.left === 'left') { + left -= width; + eAttachment.left = 'right'; + } else if (left < bounds[0] && eAttachment.left === 'right') { + left += width; + eAttachment.left = 'left'; + } + } + } -var defaultProps$50 = { - tag: 'p', - type: 'text' -}; + if (changeAttachY === 'element' || changeAttachY === 'both') { + if (top < bounds[1] && eAttachment.top === 'bottom') { + top += height; + eAttachment.top = 'top'; + } -var Input = function (_React$Component) { - inherits(Input, _React$Component); + if (top + height > bounds[3] && eAttachment.top === 'top') { + top -= height; + eAttachment.top = 'bottom'; + } + } - function Input() { - classCallCheck(this, Input); - return possibleConstructorReturn(this, (Input.__proto__ || Object.getPrototypeOf(Input)).apply(this, arguments)); - } + if (changeAttachX === 'element' || changeAttachX === 'both') { + if (left < bounds[0]) { + if (eAttachment.left === 'right') { + left += width; + eAttachment.left = 'left'; + } else if (eAttachment.left === 'center') { + left += width / 2; + eAttachment.left = 'left'; + } + } - createClass(Input, [{ - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - type = _props.type, - size = _props.size, - state = _props.state, - tag = _props.tag, - addon = _props.addon, - staticInput = _props.static, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'type', 'size', 'state', 'tag', 'addon', 'static', 'getRef']); + if (left + width > bounds[2]) { + if (eAttachment.left === 'left') { + left -= width; + eAttachment.left = 'right'; + } else if (eAttachment.left === 'center') { + left -= width / 2; + eAttachment.left = 'right'; + } + } + } + if (typeof pin === 'string') { + pin = pin.split(',').map(function (p) { + return p.trim(); + }); + } else if (pin === true) { + pin = ['top', 'left', 'right', 'bottom']; + } - var checkInput = ['radio', 'checkbox'].indexOf(type) > -1; + pin = pin || []; - var fileInput = type === 'file'; - var textareaInput = type === 'textarea'; - var selectInput = type === 'select'; - var Tag = selectInput || textareaInput ? type : 'input'; + var pinned = []; + var oob = []; - var formControlClass = 'form-control'; + if (top < bounds[1]) { + if (pin.indexOf('top') >= 0) { + top = bounds[1]; + pinned.push('top'); + } else { + oob.push('top'); + } + } - if (staticInput) { - formControlClass = formControlClass + '-static'; - Tag = tag; - } else if (fileInput) { - formControlClass = formControlClass + '-file'; - } else if (checkInput) { - if (addon) { - formControlClass = null; + if (top + height > bounds[3]) { + if (pin.indexOf('bottom') >= 0) { + top = bounds[3] - height; + pinned.push('bottom'); } else { - formControlClass = 'form-check-input'; + oob.push('bottom'); } } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, state ? 'form-control-' + state : false, size ? 'form-control-' + size : false, formControlClass), cssModule); + if (left < bounds[0]) { + if (pin.indexOf('left') >= 0) { + left = bounds[0]; + pinned.push('left'); + } else { + oob.push('left'); + } + } - if (Tag === 'input') { - attributes.type = type; + if (left + width > bounds[2]) { + if (pin.indexOf('right') >= 0) { + left = bounds[2] - width; + pinned.push('right'); + } else { + oob.push('right'); + } } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); - } - }]); - return Input; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + if (pinned.length) { + (function () { + var pinnedClass = undefined; + if (typeof _this.options.pinnedClass !== 'undefined') { + pinnedClass = _this.options.pinnedClass; + } else { + pinnedClass = _this.getClass('pinned'); + } -Input.propTypes = propTypes$51; -Input.defaultProps = defaultProps$50; + addClasses.push(pinnedClass); + pinned.forEach(function (side) { + addClasses.push(pinnedClass + '-' + side); + }); + })(); + } -var propTypes$52 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + if (oob.length) { + (function () { + var oobClass = undefined; + if (typeof _this.options.outOfBoundsClass !== 'undefined') { + oobClass = _this.options.outOfBoundsClass; + } else { + oobClass = _this.getClass('out-of-bounds'); + } -var defaultProps$51 = { - tag: 'div' -}; + addClasses.push(oobClass); + oob.forEach(function (side) { + addClasses.push(oobClass + '-' + side); + }); + })(); + } -var InputGroup = function InputGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - size = props.size, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'size']); + if (pinned.indexOf('left') >= 0 || pinned.indexOf('right') >= 0) { + eAttachment.left = tAttachment.left = false; + } + if (pinned.indexOf('top') >= 0 || pinned.indexOf('bottom') >= 0) { + eAttachment.top = tAttachment.top = false; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group', size ? 'input-group-' + size : null), cssModule); + if (tAttachment.top !== targetAttachment.top || tAttachment.left !== targetAttachment.left || eAttachment.top !== _this.attachment.top || eAttachment.left !== _this.attachment.left) { + _this.updateAttachClasses(eAttachment, tAttachment); + _this.trigger('update', { + attachment: eAttachment, + targetAttachment: tAttachment + }); + } + }); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + defer(function () { + if (!(_this.options.addTargetClasses === false)) { + updateClasses(_this.target, addClasses, allClasses); + } + updateClasses(_this.element, addClasses, allClasses); + }); -InputGroup.propTypes = propTypes$52; -InputGroup.defaultProps = defaultProps$51; + return { top: top, left: left }; + } +}); + +},{"./utils":5}],3:[function(require,module,exports){ +'use strict'; -var propTypes$53 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); -var defaultProps$52 = { - tag: 'div' -}; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } -var InputGroupAddon = function InputGroupAddon(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +var _utils = require('./utils'); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-addon'), cssModule); +var _utils2 = _interopRequireDefault(_utils); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +_utils2['default'].modules.push({ + position: function position(_ref) { + var top = _ref.top; + var left = _ref.left; -InputGroupAddon.propTypes = propTypes$53; -InputGroupAddon.defaultProps = defaultProps$52; + if (!this.options.shift) { + return; + } -var propTypes$54 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - groupClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - groupAttributes: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var shift = this.options.shift; + if (typeof this.options.shift === 'function') { + shift = this.options.shift.call(this, { top: top, left: left }); + } -var defaultProps$53 = { - tag: 'div' -}; + var shiftTop = undefined, + shiftLeft = undefined; + if (typeof shift === 'string') { + shift = shift.split(' '); + shift[1] = shift[1] || shift[0]; -var InputGroupButton = function InputGroupButton(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - children = props.children, - groupClassName = props.groupClassName, - groupAttributes = props.groupAttributes, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'children', 'groupClassName', 'groupAttributes']); + var _shift = shift; + var _shift2 = _slicedToArray(_shift, 2); - if (typeof children === 'string') { - var groupClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(groupClassName, 'input-group-btn'), cssModule); + shiftTop = _shift2[0]; + shiftLeft = _shift2[1]; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, groupAttributes, { className: groupClasses }), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Button, _extends({}, attributes, { className: className, children: children })) - ); - } + shiftTop = parseFloat(shiftTop, 10); + shiftLeft = parseFloat(shiftLeft, 10); + } else { + shiftTop = shift.top; + shiftLeft = shift.left; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-btn'), cssModule); + top += shiftTop; + left += shiftLeft; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes, children: children })); -}; + return { top: top, left: left }; + } +}); -InputGroupButton.propTypes = propTypes$54; -InputGroupButton.defaultProps = defaultProps$53; +},{"./utils":5}],4:[function(require,module,exports){ +/* globals performance */ -var colSizes = ['xs', 'sm', 'md', 'lg', 'xl']; +'use strict'; -var stringOrNumberProp$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); +Object.defineProperty(exports, '__esModule', { + value: true +}); -var columnProps$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ - size: stringOrNumberProp$1, - push: stringOrNumberProp$1, - pull: stringOrNumberProp$1, - offset: stringOrNumberProp$1 -})]); +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); -var propTypes$55 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - hidden: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - for: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - xs: columnProps$1, - sm: columnProps$1, - md: columnProps$1, - lg: columnProps$1, - xl: columnProps$1 -}; +var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var defaultProps$54 = { - tag: 'label' -}; +var _get = function get(_x6, _x7, _x8) { var _again = true; _function: while (_again) { var object = _x6, property = _x7, receiver = _x8; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x6 = parent; _x7 = property; _x8 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; -var Label = function Label(props) { - var className = props.className, - cssModule = props.cssModule, - hidden = props.hidden, - Tag = props.tag, - check = props.check, - inline = props.inline, - disabled = props.disabled, - size = props.size, - htmlFor = props.for, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'hidden', 'tag', 'check', 'inline', 'disabled', 'size', 'for']); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } - var colClasses = []; +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - colSizes.forEach(function (colSize) { - var columnProp = props[colSize]; - delete attributes[colSize]; +var _utils = require('./utils'); - if (columnProp && columnProp.size) { - var _classNames; +var _utils2 = _interopRequireDefault(_utils); - colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, 'col-' + colSize + '-' + columnProp.size, columnProp.size), defineProperty(_classNames, 'push-' + colSize + '-' + columnProp.push, columnProp.push), defineProperty(_classNames, 'pull-' + colSize + '-' + columnProp.pull, columnProp.pull), defineProperty(_classNames, 'offset-' + colSize + '-' + columnProp.offset, columnProp.offset), _classNames))), cssModule); - } else if (columnProp) { - colClasses.push('col-' + colSize + '-' + columnProp); - } - }); +require('./constraint'); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, hidden ? 'sr-only' : false, check ? 'form-check-' + (inline ? 'inline' : 'label') : false, check && inline && disabled ? 'disabled' : false, size ? 'col-form-label-' + size : false, colClasses, colClasses.length ? 'col-form-label' : false, !check && !colClasses.length ? 'form-control-label' : false), cssModule); +require('./abutment'); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ htmlFor: htmlFor }, attributes, { className: classes })); -}; +require('./shift'); -Label.propTypes = propTypes$55; -Label.defaultProps = defaultProps$54; +var _TetherBase$Utils = _utils2['default'].Utils; +var getScrollParents = _TetherBase$Utils.getScrollParents; +var getBounds = _TetherBase$Utils.getBounds; +var getOffsetParent = _TetherBase$Utils.getOffsetParent; +var extend = _TetherBase$Utils.extend; +var addClass = _TetherBase$Utils.addClass; +var removeClass = _TetherBase$Utils.removeClass; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; +var flush = _TetherBase$Utils.flush; +var getScrollBarSize = _TetherBase$Utils.getScrollBarSize; +var removeUtilElements = _TetherBase$Utils.removeUtilElements; +var Evented = _TetherBase$Utils.Evented; -var propTypes$56 = { - body: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - heading: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - list: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - middle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - object: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +function within(a, b) { + var diff = arguments.length <= 2 || arguments[2] === undefined ? 1 : arguments[2]; -var Media = function Media(props) { - var body = props.body, - bottom = props.bottom, - className = props.className, - cssModule = props.cssModule, - heading = props.heading, - left = props.left, - list = props.list, - middle = props.middle, - object = props.object, - right = props.right, - tag = props.tag, - top = props.top, - attributes = objectWithoutProperties(props, ['body', 'bottom', 'className', 'cssModule', 'heading', 'left', 'list', 'middle', 'object', 'right', 'tag', 'top']); + return a + diff >= b && b >= a - diff; +} +var transformKey = (function () { + if (typeof document === 'undefined') { + return ''; + } + var el = document.createElement('div'); - var defaultTag = void 0; - if (heading) { - defaultTag = 'h4'; - } else if (left || right) { - defaultTag = 'a'; - } else if (object) { - defaultTag = 'img'; - } else if (list) { - defaultTag = 'ul'; - } else { - defaultTag = 'div'; + var transforms = ['transform', 'WebkitTransform', 'OTransform', 'MozTransform', 'msTransform']; + for (var i = 0; i < transforms.length; ++i) { + var key = transforms[i]; + if (el.style[key] !== undefined) { + return key; + } } - var Tag = tag || defaultTag; +})(); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - 'media-body': body, - 'media-heading': heading, - 'media-left': left, - 'media-right': right, - 'media-top': top, - 'media-bottom': bottom, - 'media-middle': middle, - 'media-object': object, - 'media-list': list, - media: !body && !heading && !left && !right && !top && !bottom && !middle && !object && !list - }), cssModule); +var tethers = []; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +var position = function position() { + tethers.forEach(function (tether) { + tether.position(false); + }); + flush(); }; -Media.propTypes = propTypes$56; +function now() { + if (typeof performance !== 'undefined' && typeof performance.now !== 'undefined') { + return performance.now(); + } + return +new Date(); +} -var propTypes$57 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; +(function () { + var lastCall = null; + var lastDuration = null; + var pendingTimeout = null; -var defaultProps$55 = { - tag: 'ul' -}; + var tick = function tick() { + if (typeof lastDuration !== 'undefined' && lastDuration > 16) { + // We voluntarily throttle ourselves if we can't manage 60fps + lastDuration = Math.min(lastDuration - 16, 250); -var Pagination = function Pagination(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'tag']); + // Just in case this is the last event, remember to position just once more + pendingTimeout = setTimeout(tick, 250); + return; + } + if (typeof lastCall !== 'undefined' && now() - lastCall < 10) { + // Some browsers call events a little too frequently, refuse to run more than is reasonable + return; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'pagination', defineProperty({}, 'pagination-' + size, !!size)), cssModule); + if (pendingTimeout != null) { + clearTimeout(pendingTimeout); + pendingTimeout = null; + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + lastCall = now(); + position(); + lastDuration = now() - lastCall; + }; -Pagination.propTypes = propTypes$57; -Pagination.defaultProps = defaultProps$55; + if (typeof window !== 'undefined' && typeof window.addEventListener !== 'undefined') { + ['resize', 'scroll', 'touchmove'].forEach(function (event) { + window.addEventListener(event, tick); + }); + } +})(); -var propTypes$58 = { - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +var MIRROR_LR = { + center: 'center', + left: 'right', + right: 'left' }; -var defaultProps$56 = { - tag: 'li' +var MIRROR_TB = { + middle: 'middle', + top: 'bottom', + bottom: 'top' }; -var PaginationItem = function PaginationItem(props) { - var active = props.active, - className = props.className, - cssModule = props.cssModule, - disabled = props.disabled, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['active', 'className', 'cssModule', 'disabled', 'tag']); - +var OFFSET_MAP = { + top: 0, + left: 0, + middle: '50%', + center: '50%', + bottom: '100%', + right: '100%' +}; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-item', { - active: active, - disabled: disabled - }), cssModule); +var autoToFixedAttachment = function autoToFixedAttachment(attachment, relativeToAttachment) { + var left = attachment.left; + var top = attachment.top; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + if (left === 'auto') { + left = MIRROR_LR[relativeToAttachment.left]; + } -PaginationItem.propTypes = propTypes$58; -PaginationItem.defaultProps = defaultProps$56; + if (top === 'auto') { + top = MIRROR_TB[relativeToAttachment.top]; + } -var propTypes$59 = { - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - next: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - previous: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) + return { left: left, top: top }; }; -var defaultProps$57 = { - tag: 'a' -}; +var attachmentToOffset = function attachmentToOffset(attachment) { + var left = attachment.left; + var top = attachment.top; -var PaginationLink = function PaginationLink(props) { - var className = props.className, - cssModule = props.cssModule, - next = props.next, - previous = props.previous, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'next', 'previous', 'tag']); + if (typeof OFFSET_MAP[attachment.left] !== 'undefined') { + left = OFFSET_MAP[attachment.left]; + } + if (typeof OFFSET_MAP[attachment.top] !== 'undefined') { + top = OFFSET_MAP[attachment.top]; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-link'), cssModule); + return { left: left, top: top }; +}; - var defaultAriaLabel = void 0; - if (previous) { - defaultAriaLabel = 'Previous'; - } else if (next) { - defaultAriaLabel = 'Next'; - } - var ariaLabel = props['aria-label'] || defaultAriaLabel; +function addOffset() { + var out = { top: 0, left: 0 }; - var defaultCaret = void 0; - if (previous) { - defaultCaret = '\xAB'; - } else if (next) { - defaultCaret = '\xBB'; + for (var _len = arguments.length, offsets = Array(_len), _key = 0; _key < _len; _key++) { + offsets[_key] = arguments[_key]; } - var children = props.children; - if (previous || next) { - children = [__WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { - 'aria-hidden': 'true', - key: 'caret' - }, - children || defaultCaret - ), __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { - className: 'sr-only', - key: 'sr' - }, - ariaLabel - )]; - } + offsets.forEach(function (_ref) { + var top = _ref.top; + var left = _ref.left; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { - className: classes, - 'aria-label': ariaLabel - }), - children - ); -}; + if (typeof top === 'string') { + top = parseFloat(top, 10); + } + if (typeof left === 'string') { + left = parseFloat(left, 10); + } -PaginationLink.propTypes = propTypes$59; -PaginationLink.defaultProps = defaultProps$57; + out.top += top; + out.left += left; + }); -var propTypes$60 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - activeTab: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + return out; +} -var defaultProps$58 = { - tag: 'div' -}; +function offsetToPx(offset, size) { + if (typeof offset.left === 'string' && offset.left.indexOf('%') !== -1) { + offset.left = parseFloat(offset.left, 10) / 100 * size.width; + } + if (typeof offset.top === 'string' && offset.top.indexOf('%') !== -1) { + offset.top = parseFloat(offset.top, 10) / 100 * size.height; + } -var childContextTypes$1 = { - activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + return offset; +} -var TabContent = function (_Component) { - inherits(TabContent, _Component); +var parseOffset = function parseOffset(value) { + var _value$split = value.split(' '); - function TabContent(props) { - classCallCheck(this, TabContent); + var _value$split2 = _slicedToArray(_value$split, 2); - var _this = possibleConstructorReturn(this, (TabContent.__proto__ || Object.getPrototypeOf(TabContent)).call(this, props)); + var top = _value$split2[0]; + var left = _value$split2[1]; - _this.state = { - activeTab: _this.props.activeTab - }; - return _this; - } + return { top: top, left: left }; +}; +var parseAttachment = parseOffset; - createClass(TabContent, [{ - key: 'getChildContext', - value: function getChildContext() { - return { - activeTabId: this.state.activeTab - }; - } - }, { - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - if (this.state.activeTab !== nextProps.activeTab) { - this.setState({ - activeTab: nextProps.activeTab - }); - } - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - Tag = _props.tag; +var TetherClass = (function (_Evented) { + _inherits(TetherClass, _Evented); + function TetherClass(options) { + var _this = this; - var attributes = omit(this.props, Object.keys(propTypes$60)); + _classCallCheck(this, TetherClass); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-content', className), cssModule); + _get(Object.getPrototypeOf(TetherClass.prototype), 'constructor', this).call(this); + this.position = this.position.bind(this); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); - } - }]); - return TabContent; -}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); + tethers.push(this); -TabContent.propTypes = propTypes$60; -TabContent.defaultProps = defaultProps$58; -TabContent.childContextTypes = childContextTypes$1; + this.history = []; -var propTypes$61 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + this.setOptions(options, false); -var defaultProps$59 = { - tag: 'div' -}; + _utils2['default'].modules.forEach(function (module) { + if (typeof module.initialize !== 'undefined') { + module.initialize.call(_this); + } + }); -var contextTypes$3 = { - activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + this.position(); + } -function TabPane(props, context) { - var className = props.className, - cssModule = props.cssModule, - tabId = props.tabId, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabId', 'tag']); + _createClass(TetherClass, [{ + key: 'getClass', + value: function getClass() { + var key = arguments.length <= 0 || arguments[0] === undefined ? '' : arguments[0]; + var classes = this.options.classes; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-pane', className, { active: tabId === context.activeTabId }), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -} -TabPane.propTypes = propTypes$61; -TabPane.defaultProps = defaultProps$59; -TabPane.contextTypes = contextTypes$3; + if (typeof classes !== 'undefined' && classes[key]) { + return this.options.classes[key]; + } else if (this.options.classPrefix) { + return this.options.classPrefix + '-' + key; + } else { + return key; + } + } + }, { + key: 'setOptions', + value: function setOptions(options) { + var _this2 = this; -var propTypes$62 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var pos = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1]; -var defaultProps$60 = { - tag: 'div' -}; + var defaults = { + offset: '0 0', + targetOffset: '0 0', + targetAttachment: 'auto auto', + classPrefix: 'tether' + }; -var Jumbotron = function Jumbotron(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - fluid = props.fluid, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'fluid']); + this.options = extend(defaults, options); + var _options = this.options; + var element = _options.element; + var target = _options.target; + var targetModifier = _options.targetModifier; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'jumbotron', fluid ? 'jumbotron-fluid' : false), cssModule); + this.element = element; + this.target = target; + this.targetModifier = targetModifier; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + if (this.target === 'viewport') { + this.target = document.body; + this.targetModifier = 'visible'; + } else if (this.target === 'scroll-handle') { + this.target = document.body; + this.targetModifier = 'scroll-handle'; + } -Jumbotron.propTypes = propTypes$62; -Jumbotron.defaultProps = defaultProps$60; + ['element', 'target'].forEach(function (key) { + if (typeof _this2[key] === 'undefined') { + throw new Error('Tether Error: Both element and target must be defined'); + } -var FirstChild = function FirstChild(_ref) { - var children = _ref.children; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children)[0] || null; -}; + if (typeof _this2[key].jquery !== 'undefined') { + _this2[key] = _this2[key][0]; + } else if (typeof _this2[key] === 'string') { + _this2[key] = document.querySelector(_this2[key]); + } + }); -var propTypes$63 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - closeClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number -}; + addClass(this.element, this.getClass('element')); + if (!(this.options.addTargetClasses === false)) { + addClass(this.target, this.getClass('target')); + } -var defaultProps$61 = { - color: 'success', - isOpen: true, - tag: 'div', - transitionAppearTimeout: 150, - transitionEnterTimeout: 150, - transitionLeaveTimeout: 150 -}; + if (!this.options.attachment) { + throw new Error('Tether Error: You must provide an attachment'); + } -var Alert = function Alert(props) { - var className = props.className, - closeClassName = props.closeClassName, - cssModule = props.cssModule, - Tag = props.tag, - color = props.color, - isOpen = props.isOpen, - toggle = props.toggle, - children = props.children, - transitionAppearTimeout = props.transitionAppearTimeout, - transitionEnterTimeout = props.transitionEnterTimeout, - transitionLeaveTimeout = props.transitionLeaveTimeout, - attributes = objectWithoutProperties(props, ['className', 'closeClassName', 'cssModule', 'tag', 'color', 'isOpen', 'toggle', 'children', 'transitionAppearTimeout', 'transitionEnterTimeout', 'transitionLeaveTimeout']); + this.targetAttachment = parseAttachment(this.options.targetAttachment); + this.attachment = parseAttachment(this.options.attachment); + this.offset = parseOffset(this.options.offset); + this.targetOffset = parseOffset(this.options.targetOffset); + if (typeof this.scrollParents !== 'undefined') { + this.disable(); + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'alert', 'alert-' + color, { 'alert-dismissible': toggle }), cssModule); + if (this.targetModifier === 'scroll-handle') { + this.scrollParents = [this.target]; + } else { + this.scrollParents = getScrollParents(this.target); + } - var closeClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('close', closeClassName), cssModule); + if (!(this.options.enabled === false)) { + this.enable(pos); + } + } + }, { + key: 'getTargetBounds', + value: function getTargetBounds() { + if (typeof this.targetModifier !== 'undefined') { + if (this.targetModifier === 'visible') { + if (this.target === document.body) { + return { top: pageYOffset, left: pageXOffset, height: innerHeight, width: innerWidth }; + } else { + var bounds = getBounds(this.target); - var alert = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { className: classes, role: 'alert' }), - toggle ? __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'button', - { type: 'button', className: closeClasses, 'aria-label': 'Close', onClick: toggle }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { 'aria-hidden': 'true' }, - '\xD7' - ) - ) : null, - children - ); + var out = { + height: bounds.height, + width: bounds.width, + top: bounds.top, + left: bounds.left + }; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["CSSTransitionGroup"], - { - component: FirstChild, - transitionName: { - appear: 'fade', - appearActive: 'show', - enter: 'fade', - enterActive: 'show', - leave: 'fade', - leaveActive: 'out' - }, - transitionAppear: transitionAppearTimeout > 0, - transitionAppearTimeout: transitionAppearTimeout, - transitionEnter: transitionEnterTimeout > 0, - transitionEnterTimeout: transitionEnterTimeout, - transitionLeave: transitionLeaveTimeout > 0, - transitionLeaveTimeout: transitionLeaveTimeout - }, - isOpen ? alert : null - ); -}; + out.height = Math.min(out.height, bounds.height - (pageYOffset - bounds.top)); + out.height = Math.min(out.height, bounds.height - (bounds.top + bounds.height - (pageYOffset + innerHeight))); + out.height = Math.min(innerHeight, out.height); + out.height -= 2; -Alert.propTypes = propTypes$63; -Alert.defaultProps = defaultProps$61; + out.width = Math.min(out.width, bounds.width - (pageXOffset - bounds.left)); + out.width = Math.min(out.width, bounds.width - (bounds.left + bounds.width - (pageXOffset + innerWidth))); + out.width = Math.min(innerWidth, out.width); + out.width -= 2; -var SHOW = 'SHOW'; -var SHOWN = 'SHOWN'; -var HIDE = 'HIDE'; -var HIDDEN = 'HIDDEN'; + if (out.top < pageYOffset) { + out.top = pageYOffset; + } + if (out.left < pageXOffset) { + out.left = pageXOffset; + } -var propTypes$64 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - onOpened: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onClosed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; + return out; + } + } else if (this.targetModifier === 'scroll-handle') { + var bounds = undefined; + var target = this.target; + if (target === document.body) { + target = document.documentElement; -var DEFAULT_DELAYS$1 = { - show: 350, - hide: 350 -}; + bounds = { + left: pageXOffset, + top: pageYOffset, + height: innerHeight, + width: innerWidth + }; + } else { + bounds = getBounds(target); + } -var defaultProps$62 = { - isOpen: false, - tag: 'div', - delay: DEFAULT_DELAYS$1, - onOpened: function onOpened() {}, - onClosed: function onClosed() {} -}; + var style = getComputedStyle(target); -var Collapse = function (_Component) { - inherits(Collapse, _Component); + var hasBottomScroll = target.scrollWidth > target.clientWidth || [style.overflow, style.overflowX].indexOf('scroll') >= 0 || this.target !== document.body; - function Collapse(props) { - classCallCheck(this, Collapse); + var scrollBottom = 0; + if (hasBottomScroll) { + scrollBottom = 15; + } - var _this = possibleConstructorReturn(this, (Collapse.__proto__ || Object.getPrototypeOf(Collapse)).call(this, props)); + var height = bounds.height - parseFloat(style.borderTopWidth) - parseFloat(style.borderBottomWidth) - scrollBottom; - _this.state = { - collapse: props.isOpen ? SHOWN : HIDDEN, - height: null - }; - _this.element = null; - return _this; - } + var out = { + width: 15, + height: height * 0.975 * (height / target.scrollHeight), + left: bounds.left + bounds.width - parseFloat(style.borderLeftWidth) - 15 + }; - createClass(Collapse, [{ - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - var _this2 = this; + var fitAdj = 0; + if (height < 408 && this.target === document.body) { + fitAdj = -0.00011 * Math.pow(height, 2) - 0.00727 * height + 22.58; + } - var willOpen = nextProps.isOpen; - var collapse = this.state.collapse; + if (this.target !== document.body) { + out.height = Math.max(out.height, 24); + } - if (willOpen && collapse === HIDDEN) { - // will open - this.setState({ collapse: SHOW }, function () { - // the height transition will work after class "collapsing" applied - _this2.setState({ height: _this2.getHeight() }); - _this2.transitionTag = setTimeout(function () { - _this2.setState({ - collapse: SHOWN, - height: null - }); - }, _this2.getDelay('show')); - }); - } else if (!willOpen && collapse === SHOWN) { - // will hide - this.setState({ height: this.getHeight() }, function () { - _this2.setState({ - collapse: HIDE, - height: _this2.getHeight() - }, function () { - _this2.setState({ height: 0 }); - }); - }); + var scrollPercentage = this.target.scrollTop / (target.scrollHeight - height); + out.top = scrollPercentage * (height - out.height - fitAdj) + bounds.top + parseFloat(style.borderTopWidth); - this.transitionTag = setTimeout(function () { - _this2.setState({ - collapse: HIDDEN, - height: null - }); - }, this.getDelay('hide')); - } - // else: do nothing. - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps, prevState) { - if (this.state.collapse === SHOWN && prevState && prevState.collapse !== SHOWN) { - this.props.onOpened(); - } + if (this.target === document.body) { + out.height = Math.max(out.height, 24); + } - if (this.state.collapse === HIDDEN && prevState && prevState.collapse !== HIDDEN) { - this.props.onClosed(); + return out; + } + } else { + return getBounds(this.target); } } }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - clearTimeout(this.transitionTag); + key: 'clearCache', + value: function clearCache() { + this._cache = {}; } }, { - key: 'getDelay', - value: function getDelay(key) { - var delay = this.props.delay; + key: 'cache', + value: function cache(k, getter) { + // More than one module will often need the same DOM info, so + // we keep a cache which is cleared on each position call + if (typeof this._cache === 'undefined') { + this._cache = {}; + } - if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { - return isNaN(delay[key]) ? DEFAULT_DELAYS$1[key] : delay[key]; + if (typeof this._cache[k] === 'undefined') { + this._cache[k] = getter.call(this); } - return delay; - } - }, { - key: 'getHeight', - value: function getHeight() { - return this.element.scrollHeight; + + return this._cache[k]; } }, { - key: 'render', - value: function render() { + key: 'enable', + value: function enable() { var _this3 = this; - var _omit = omit(this.props, ['isOpen', 'delay', 'onOpened', 'onClosed']), - navbar = _omit.navbar, - className = _omit.className, - cssModule = _omit.cssModule, - Tag = _omit.tag, - attributes = objectWithoutProperties(_omit, ['navbar', 'className', 'cssModule', 'tag']); - - var _state = this.state, - collapse = _state.collapse, - height = _state.height; + var pos = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; - var collapseClass = void 0; - switch (collapse) { - case SHOW: - collapseClass = 'collapsing'; - break; - case SHOWN: - collapseClass = 'collapse show'; - break; - case HIDE: - collapseClass = 'collapsing'; - break; - case HIDDEN: - collapseClass = 'collapse'; - break; - default: - // HIDDEN - collapseClass = 'collapse'; + if (!(this.options.addTargetClasses === false)) { + addClass(this.target, this.getClass('enabled')); } + addClass(this.element, this.getClass('enabled')); + this.enabled = true; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, collapseClass, navbar && 'navbar-collapse'), cssModule); - var style = height === null ? null : { height: height }; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { - style: _extends({}, attributes.style, style), - className: classes, - ref: function ref(c) { - _this3.element = c; + this.scrollParents.forEach(function (parent) { + if (parent !== _this3.target.ownerDocument) { + parent.addEventListener('scroll', _this3.position); } - })); + }); + + if (pos) { + this.position(); + } } - }]); - return Collapse; -}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); + }, { + key: 'disable', + value: function disable() { + var _this4 = this; -Collapse.propTypes = propTypes$64; -Collapse.defaultProps = defaultProps$62; + removeClass(this.target, this.getClass('enabled')); + removeClass(this.element, this.getClass('enabled')); + this.enabled = false; -var propTypes$65 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - action: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + if (typeof this.scrollParents !== 'undefined') { + this.scrollParents.forEach(function (parent) { + parent.removeEventListener('scroll', _this4.position); + }); + } + } + }, { + key: 'destroy', + value: function destroy() { + var _this5 = this; -var defaultProps$63 = { - tag: 'li' -}; + this.disable(); -var handleDisabledOnClick = function handleDisabledOnClick(e) { - e.preventDefault(); -}; + tethers.forEach(function (tether, i) { + if (tether === _this5) { + tethers.splice(i, 1); + } + }); -var ListGroupItem = function ListGroupItem(props) { - var className = props.className, - Tag = props.tag, - active = props.active, - disabled = props.disabled, - action = props.action, - color = props.color, - attributes = objectWithoutProperties(props, ['className', 'tag', 'active', 'disabled', 'action', 'color']); + // Remove any elements we were using for convenience from the DOM + if (tethers.length === 0) { + removeUtilElements(); + } + } + }, { + key: 'updateAttachClasses', + value: function updateAttachClasses(elementAttach, targetAttach) { + var _this6 = this; + + elementAttach = elementAttach || this.attachment; + targetAttach = targetAttach || this.targetAttachment; + var sides = ['left', 'top', 'bottom', 'right', 'middle', 'center']; - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, disabled ? 'disabled' : false, action ? 'list-group-item-action' : false, color ? 'list-group-item-' + color : false, 'list-group-item'); + if (typeof this._addAttachClasses !== 'undefined' && this._addAttachClasses.length) { + // updateAttachClasses can be called more than once in a position call, so + // we need to clean up after ourselves such that when the last defer gets + // ran it doesn't add any extra classes from previous calls. + this._addAttachClasses.splice(0, this._addAttachClasses.length); + } - // Prevent click event when disabled. - if (disabled) { - attributes.onClick = handleDisabledOnClick; - } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + if (typeof this._addAttachClasses === 'undefined') { + this._addAttachClasses = []; + } + var add = this._addAttachClasses; -ListGroupItem.propTypes = propTypes$65; -ListGroupItem.defaultProps = defaultProps$63; + if (elementAttach.top) { + add.push(this.getClass('element-attached') + '-' + elementAttach.top); + } + if (elementAttach.left) { + add.push(this.getClass('element-attached') + '-' + elementAttach.left); + } + if (targetAttach.top) { + add.push(this.getClass('target-attached') + '-' + targetAttach.top); + } + if (targetAttach.left) { + add.push(this.getClass('target-attached') + '-' + targetAttach.left); + } -var propTypes$66 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + var all = []; + sides.forEach(function (side) { + all.push(_this6.getClass('element-attached') + '-' + side); + all.push(_this6.getClass('target-attached') + '-' + side); + }); -var defaultProps$64 = { - tag: 'h5' -}; + defer(function () { + if (!(typeof _this6._addAttachClasses !== 'undefined')) { + return; + } -var ListGroupItemHeading = function ListGroupItemHeading(props) { - var className = props.className, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'tag']); + updateClasses(_this6.element, _this6._addAttachClasses, all); + if (!(_this6.options.addTargetClasses === false)) { + updateClasses(_this6.target, _this6._addAttachClasses, all); + } - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-heading'); + delete _this6._addAttachClasses; + }); + } + }, { + key: 'position', + value: function position() { + var _this7 = this; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + var flushChanges = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; -ListGroupItemHeading.propTypes = propTypes$66; -ListGroupItemHeading.defaultProps = defaultProps$64; + // flushChanges commits the changes immediately, leave true unless you are positioning multiple + // tethers (in which case call Tether.Utils.flush yourself when you're done) -var propTypes$67 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + if (!this.enabled) { + return; + } -var defaultProps$65 = { - tag: 'p' -}; + this.clearCache(); -var ListGroupItemText = function ListGroupItemText(props) { - var className = props.className, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'tag']); + // Turn 'auto' attachments into the appropriate corner or edge + var targetAttachment = autoToFixedAttachment(this.targetAttachment, this.attachment); - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-text'); + this.updateAttachClasses(this.attachment, targetAttachment); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + var elementPos = this.cache('element-bounds', function () { + return getBounds(_this7.element); + }); -ListGroupItemText.propTypes = propTypes$67; -ListGroupItemText.defaultProps = defaultProps$65; + var width = elementPos.width; + var height = elementPos.height; -var Component$1 = __WEBPACK_IMPORTED_MODULE_0_react___default.a.Component; + if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { + var _lastSize = this.lastSize; -var components = { - UncontrolledAlert: Alert, - UncontrolledButtonDropdown: ButtonDropdown, - UncontrolledDropdown: Dropdown, - UncontrolledNavDropdown: NavDropdown, - UncontrolledTooltip: Tooltip -}; + // We cache the height and width to make it possible to position elements that are + // getting hidden. + width = _lastSize.width; + height = _lastSize.height; + } else { + this.lastSize = { width: width, height: height }; + } -Object.keys(components).forEach(function (key) { - var Tag = components[key]; - var defaultValue = Tag === Alert; + var targetPos = this.cache('target-bounds', function () { + return _this7.getTargetBounds(); + }); + var targetSize = targetPos; - var Uncontrolled = function (_Component) { - inherits(Uncontrolled, _Component); + // Get an actual px offset from the attachment + var offset = offsetToPx(attachmentToOffset(this.attachment), { width: width, height: height }); + var targetOffset = offsetToPx(attachmentToOffset(targetAttachment), targetSize); - function Uncontrolled(props) { - classCallCheck(this, Uncontrolled); + var manualOffset = offsetToPx(this.offset, { width: width, height: height }); + var manualTargetOffset = offsetToPx(this.targetOffset, targetSize); - var _this = possibleConstructorReturn(this, (Uncontrolled.__proto__ || Object.getPrototypeOf(Uncontrolled)).call(this, props)); + // Add the manually provided offset + offset = addOffset(offset, manualOffset); + targetOffset = addOffset(targetOffset, manualTargetOffset); - _this.state = { isOpen: defaultValue }; + // It's now our goal to make (element position + offset) == (target position + target offset) + var left = targetPos.left + targetOffset.left - offset.left; + var top = targetPos.top + targetOffset.top - offset.top; - _this.toggle = _this.toggle.bind(_this); - return _this; - } + for (var i = 0; i < _utils2['default'].modules.length; ++i) { + var _module2 = _utils2['default'].modules[i]; + var ret = _module2.position.call(this, { + left: left, + top: top, + targetAttachment: targetAttachment, + targetPos: targetPos, + elementPos: elementPos, + offset: offset, + targetOffset: targetOffset, + manualOffset: manualOffset, + manualTargetOffset: manualTargetOffset, + scrollbarSize: scrollbarSize, + attachment: this.attachment + }); - createClass(Uncontrolled, [{ - key: 'toggle', - value: function toggle() { - this.setState({ isOpen: !this.state.isOpen }); - } - }, { - key: 'render', - value: function render() { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ isOpen: this.state.isOpen, toggle: this.toggle }, this.props)); + if (ret === false) { + return false; + } else if (typeof ret === 'undefined' || typeof ret !== 'object') { + continue; + } else { + top = ret.top; + left = ret.left; + } } - }]); - return Uncontrolled; - }(Component$1); - Uncontrolled.displayName = key; + // We describe the position three different ways to give the optimizer + // a chance to decide the best possible way to position the element + // with the fewest repaints. + var next = { + // It's position relative to the page (absolute positioning when + // the element is a child of the body) + page: { + top: top, + left: left + }, - components[key] = Uncontrolled; -}); + // It's position relative to the viewport (fixed positioning) + viewport: { + top: top - pageYOffset, + bottom: pageYOffset - top - height + innerHeight, + left: left - pageXOffset, + right: pageXOffset - left - width + innerWidth + } + }; -var UncontrolledAlert = components.UncontrolledAlert; -var UncontrolledButtonDropdown = components.UncontrolledButtonDropdown; -var UncontrolledDropdown = components.UncontrolledDropdown; -var UncontrolledNavDropdown = components.UncontrolledNavDropdown; -var UncontrolledTooltip = components.UncontrolledTooltip; + var doc = this.target.ownerDocument; + var win = doc.defaultView; + var scrollbarSize = undefined; + if (doc.body.scrollWidth > win.innerWidth) { + scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); + next.viewport.bottom -= scrollbarSize.height; + } -//# sourceMappingURL=reactstrap.es.js.map + if (doc.body.scrollHeight > win.innerHeight) { + scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); + next.viewport.right -= scrollbarSize.width; + } + if (['', 'static'].indexOf(doc.body.style.position) === -1 || ['', 'static'].indexOf(doc.body.parentElement.style.position) === -1) { + // Absolute positioning in the body will be relative to the page, not the 'initial containing block' + next.page.bottom = doc.body.scrollHeight - top - height; + next.page.right = doc.body.scrollWidth - left - width; + } -/***/ }), -/* 67 */, -/* 68 */, -/* 69 */, -/* 70 */ -/***/ (function(module, exports, __webpack_require__) { + if (typeof this.options.optimizations !== 'undefined' && this.options.optimizations.moveElement !== false && !(typeof this.targetModifier !== 'undefined')) { + (function () { + var offsetParent = _this7.cache('target-offsetparent', function () { + return getOffsetParent(_this7.target); + }); + var offsetPosition = _this7.cache('target-offsetparent-bounds', function () { + return getBounds(offsetParent); + }); + var offsetParentStyle = getComputedStyle(offsetParent); + var offsetParentSize = offsetPosition; -"use strict"; + var offsetBorder = {}; + ['Top', 'Left', 'Bottom', 'Right'].forEach(function (side) { + offsetBorder[side.toLowerCase()] = parseFloat(offsetParentStyle['border' + side + 'Width']); + }); + offsetPosition.right = doc.body.scrollWidth - offsetPosition.left - offsetParentSize.width + offsetBorder.right; + offsetPosition.bottom = doc.body.scrollHeight - offsetPosition.top - offsetParentSize.height + offsetBorder.bottom; -Object.defineProperty(exports, "__esModule", { - value: true -}); + if (next.page.top >= offsetPosition.top + offsetBorder.top && next.page.bottom >= offsetPosition.bottom) { + if (next.page.left >= offsetPosition.left + offsetBorder.left && next.page.right >= offsetPosition.right) { + // We're within the visible part of the target's scroll parent + var scrollTop = offsetParent.scrollTop; + var scrollLeft = offsetParent.scrollLeft; -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + // It's position relative to the target's offset parent (absolute positioning when + // the element is moved to be a child of the target's offset parent). + next.offset = { + top: next.page.top - offsetPosition.top + scrollTop - offsetBorder.top, + left: next.page.left - offsetPosition.left + scrollLeft - offsetBorder.left + }; + } + } + })(); + } -var _react = __webpack_require__(4); + // We could also travel up the DOM and try each containing context, rather than only + // looking at the body, but we're gonna get diminishing returns. -var _react2 = _interopRequireDefault(_react); + this.move(next); -var _propTypes = __webpack_require__(9); + this.history.unshift(next); -var _propTypes2 = _interopRequireDefault(_propTypes); + if (this.history.length > 3) { + this.history.pop(); + } -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + if (flushChanges) { + flush(); + } -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } + return true; + } -var IconBase = function IconBase(_ref, _ref2) { - var children = _ref.children; - var color = _ref.color; - var size = _ref.size; - var style = _ref.style; + // THE ISSUE + }, { + key: 'move', + value: function move(pos) { + var _this8 = this; - var props = _objectWithoutProperties(_ref, ['children', 'color', 'size', 'style']); + if (!(typeof this.element.parentNode !== 'undefined')) { + return; + } - var _ref2$reactIconBase = _ref2.reactIconBase; - var reactIconBase = _ref2$reactIconBase === undefined ? {} : _ref2$reactIconBase; + var same = {}; - var computedSize = size || reactIconBase.size || '1em'; - return _react2.default.createElement('svg', _extends({ - children: children, - fill: 'currentColor', - preserveAspectRatio: 'xMidYMid meet', - height: computedSize, - width: computedSize - }, reactIconBase, props, { - style: _extends({ - verticalAlign: 'middle', - color: color || reactIconBase.color - }, reactIconBase.style || {}, style) - })); -}; + for (var type in pos) { + same[type] = {}; -IconBase.propTypes = { - color: _propTypes2.default.string, - size: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.number]), - style: _propTypes2.default.object -}; + for (var key in pos[type]) { + var found = false; -IconBase.contextTypes = { - reactIconBase: _propTypes2.default.shape(IconBase.propTypes) -}; + for (var i = 0; i < this.history.length; ++i) { + var point = this.history[i]; + if (typeof point[type] !== 'undefined' && !within(point[type][key], pos[type][key])) { + found = true; + break; + } + } -exports.default = IconBase; -module.exports = exports['default']; + if (!found) { + same[type][key] = true; + } + } + } -/***/ }), -/* 71 */, -/* 72 */ -/***/ (function(module, exports) { + var css = { top: '', left: '', right: '', bottom: '' }; -/* - MIT License http://www.opensource.org/licenses/mit-license.php - Author Tobias Koppers @sokra -*/ -// css base code, injected by the css-loader -module.exports = function(useSourceMap) { - var list = []; + var transcribe = function transcribe(_same, _pos) { + var hasOptimizations = typeof _this8.options.optimizations !== 'undefined'; + var gpu = hasOptimizations ? _this8.options.optimizations.gpu : null; + if (gpu !== false) { + var yPos = undefined, + xPos = undefined; + if (_same.top) { + css.top = 0; + yPos = _pos.top; + } else { + css.bottom = 0; + yPos = -_pos.bottom; + } - // return the list of modules as css string - list.toString = function toString() { - return this.map(function (item) { - var content = cssWithMappingToString(item, useSourceMap); - if(item[2]) { - return "@media " + item[2] + "{" + content + "}"; - } else { - return content; - } - }).join(""); - }; + if (_same.left) { + css.left = 0; + xPos = _pos.left; + } else { + css.right = 0; + xPos = -_pos.right; + } - // import a list of modules into the list - list.i = function(modules, mediaQuery) { - if(typeof modules === "string") - modules = [[null, modules, ""]]; - var alreadyImportedModules = {}; - for(var i = 0; i < this.length; i++) { - var id = this[i][0]; - if(typeof id === "number") - alreadyImportedModules[id] = true; - } - for(i = 0; i < modules.length; i++) { - var item = modules[i]; - // skip already imported module - // this implementation is not 100% perfect for weird media query combinations - // when a module is imported multiple times with different media queries. - // I hope this will never occur (Hey this way we have smaller bundles) - if(typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) { - if(mediaQuery && !item[2]) { - item[2] = mediaQuery; - } else if(mediaQuery) { - item[2] = "(" + item[2] + ") and (" + mediaQuery + ")"; - } - list.push(item); - } - } - }; - return list; -}; + css[transformKey] = 'translateX(' + Math.round(xPos) + 'px) translateY(' + Math.round(yPos) + 'px)'; -function cssWithMappingToString(item, useSourceMap) { - var content = item[1] || ''; - var cssMapping = item[3]; - if (!cssMapping) { - return content; - } + if (transformKey !== 'msTransform') { + // The Z transform will keep this in the GPU (faster, and prevents artifacts), + // but IE9 doesn't support 3d transforms and will choke. + css[transformKey] += " translateZ(0)"; + } + } else { + if (_same.top) { + css.top = _pos.top + 'px'; + } else { + css.bottom = _pos.bottom + 'px'; + } - if (useSourceMap && typeof btoa === 'function') { - var sourceMapping = toComment(cssMapping); - var sourceURLs = cssMapping.sources.map(function (source) { - return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */' - }); + if (_same.left) { + css.left = _pos.left + 'px'; + } else { + css.right = _pos.right + 'px'; + } + } + }; - return [content].concat(sourceURLs).concat([sourceMapping]).join('\n'); - } + var moved = false; + if ((same.page.top || same.page.bottom) && (same.page.left || same.page.right)) { + css.position = 'absolute'; + transcribe(same.page, pos.page); + } else if ((same.viewport.top || same.viewport.bottom) && (same.viewport.left || same.viewport.right)) { + css.position = 'fixed'; + transcribe(same.viewport, pos.viewport); + } else if (typeof same.offset !== 'undefined' && same.offset.top && same.offset.left) { + (function () { + css.position = 'absolute'; + var offsetParent = _this8.cache('target-offsetparent', function () { + return getOffsetParent(_this8.target); + }); - return [content].join('\n'); -} + if (getOffsetParent(_this8.element) !== offsetParent) { + defer(function () { + _this8.element.parentNode.removeChild(_this8.element); + offsetParent.appendChild(_this8.element); + }); + } -// Adapted from convert-source-map (MIT) -function toComment(sourceMap) { - // eslint-disable-next-line no-undef - var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))); - var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64; + transcribe(same.offset, pos.offset); + moved = true; + })(); + } else { + css.position = 'absolute'; + transcribe({ top: true, left: true }, pos.page); + } - return '/*# ' + data + ' */'; -} + if (!moved) { + var offsetParentIsBody = true; + var currentNode = this.element.parentNode; + while (currentNode && currentNode.nodeType === 1 && currentNode.tagName !== 'BODY') { + if (getComputedStyle(currentNode).position !== 'static') { + offsetParentIsBody = false; + break; + } + + currentNode = currentNode.parentNode; + } + if (!offsetParentIsBody) { + this.element.parentNode.removeChild(this.element); + this.element.ownerDocument.body.appendChild(this.element); + } + } -/***/ }), -/* 73 */ -/***/ (function(module, exports, __webpack_require__) { + // Any css change will trigger a repaint, so let's avoid one if nothing changed + var writeCSS = {}; + var write = false; + for (var key in css) { + var val = css[key]; + var elVal = this.element.style[key]; -/* - MIT License http://www.opensource.org/licenses/mit-license.php - Author Tobias Koppers @sokra -*/ + if (elVal !== val) { + write = true; + writeCSS[key] = val; + } + } + + if (write) { + defer(function () { + extend(_this8.element.style, writeCSS); + _this8.trigger('repositioned'); + }); + } + } + }]); -var stylesInDom = {}; + return TetherClass; +})(Evented); -var memoize = function (fn) { - var memo; +TetherClass.modules = []; - return function () { - if (typeof memo === "undefined") memo = fn.apply(this, arguments); - return memo; - }; -}; +_utils2['default'].position = position; -var isOldIE = memoize(function () { - // Test for IE <= 9 as proposed by Browserhacks - // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805 - // Tests for existence of standard globals is to allow style-loader - // to operate correctly into non-standard environments - // @see https://github.com/webpack-contrib/style-loader/issues/177 - return window && document && document.all && !window.atob; -}); +var Tether = extend(TetherClass, _utils2['default']); -var getElement = (function (fn) { - var memo = {}; +exports['default'] = Tether; +module.exports = exports['default']; - return function(selector) { - if (typeof memo[selector] === "undefined") { - memo[selector] = fn.call(this, selector); - } +},{"./abutment":1,"./constraint":2,"./shift":3,"./utils":5}],5:[function(require,module,exports){ +'use strict'; - return memo[selector] - }; -})(function (target) { - return document.querySelector(target) +Object.defineProperty(exports, '__esModule', { + value: true }); -var singleton = null; -var singletonCounter = 0; -var stylesInsertedAtTop = []; +var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -var fixUrls = __webpack_require__(119); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } -module.exports = function(list, options) { - if (typeof DEBUG !== "undefined" && DEBUG) { - if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment"); - } +var TetherBase = { modules: [] }; - options = options || {}; +var zeroElement = null; - options.attrs = typeof options.attrs === "object" ? options.attrs : {}; +// Same as native getBoundingClientRect, except it takes into account parent <frame> offsets +// if the element lies within a nested document (<frame> or <iframe>-like). +function getActualBoundingClientRect(node) { + var boundingRect = node.getBoundingClientRect(); - // Force single-tag solution on IE6-9, which has a hard limit on the # of <style> - // tags it will allow on a page - if (!options.singleton) options.singleton = isOldIE(); + // The original object returned by getBoundingClientRect is immutable, so we clone it + // We can't use extend because the properties are not considered part of the object by hasOwnProperty in IE9 + var rect = {}; + for (var k in boundingRect) { + rect[k] = boundingRect[k]; + } - // By default, add <style> tags to the <head> element - if (!options.insertInto) options.insertInto = "head"; + if (node.ownerDocument !== document) { + var _frameElement = node.ownerDocument.defaultView.frameElement; + if (_frameElement) { + var frameRect = getActualBoundingClientRect(_frameElement); + rect.top += frameRect.top; + rect.bottom += frameRect.top; + rect.left += frameRect.left; + rect.right += frameRect.left; + } + } - // By default, add <style> tags to the bottom of the target - if (!options.insertAt) options.insertAt = "bottom"; + return rect; +} - var styles = listToStyles(list, options); +function getScrollParents(el) { + // In firefox if the el is inside an iframe with display: none; window.getComputedStyle() will return null; + // https://bugzilla.mozilla.org/show_bug.cgi?id=548397 + var computedStyle = getComputedStyle(el) || {}; + var position = computedStyle.position; + var parents = []; - addStylesToDom(styles, options); + if (position === 'fixed') { + return [el]; + } - return function update (newList) { - var mayRemove = []; + var parent = el; + while ((parent = parent.parentNode) && parent && parent.nodeType === 1) { + var style = undefined; + try { + style = getComputedStyle(parent); + } catch (err) {} - for (var i = 0; i < styles.length; i++) { - var item = styles[i]; - var domStyle = stylesInDom[item.id]; + if (typeof style === 'undefined' || style === null) { + parents.push(parent); + return parents; + } - domStyle.refs--; - mayRemove.push(domStyle); - } + var _style = style; + var overflow = _style.overflow; + var overflowX = _style.overflowX; + var overflowY = _style.overflowY; - if(newList) { - var newStyles = listToStyles(newList, options); - addStylesToDom(newStyles, options); - } + if (/(auto|scroll)/.test(overflow + overflowY + overflowX)) { + if (position !== 'absolute' || ['relative', 'absolute', 'fixed'].indexOf(style.position) >= 0) { + parents.push(parent); + } + } + } - for (var i = 0; i < mayRemove.length; i++) { - var domStyle = mayRemove[i]; + parents.push(el.ownerDocument.body); - if(domStyle.refs === 0) { - for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](); + // If the node is within a frame, account for the parent window scroll + if (el.ownerDocument !== document) { + parents.push(el.ownerDocument.defaultView); + } - delete stylesInDom[domStyle.id]; - } - } - }; -}; + return parents; +} -function addStylesToDom (styles, options) { - for (var i = 0; i < styles.length; i++) { - var item = styles[i]; - var domStyle = stylesInDom[item.id]; +var uniqueId = (function () { + var id = 0; + return function () { + return ++id; + }; +})(); - if(domStyle) { - domStyle.refs++; +var zeroPosCache = {}; +var getOrigin = function getOrigin() { + // getBoundingClientRect is unfortunately too accurate. It introduces a pixel or two of + // jitter as the user scrolls that messes with our ability to detect if two positions + // are equivilant or not. We place an element at the top left of the page that will + // get the same jitter, so we can cancel the two out. + var node = zeroElement; + if (!node) { + node = document.createElement('div'); + node.setAttribute('data-tether-id', uniqueId()); + extend(node.style, { + top: 0, + left: 0, + position: 'absolute' + }); - for(var j = 0; j < domStyle.parts.length; j++) { - domStyle.parts[j](item.parts[j]); - } + document.body.appendChild(node); - for(; j < item.parts.length; j++) { - domStyle.parts.push(addStyle(item.parts[j], options)); - } - } else { - var parts = []; + zeroElement = node; + } - for(var j = 0; j < item.parts.length; j++) { - parts.push(addStyle(item.parts[j], options)); - } + var id = node.getAttribute('data-tether-id'); + if (typeof zeroPosCache[id] === 'undefined') { + zeroPosCache[id] = getActualBoundingClientRect(node); - stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts}; - } - } -} + // Clear the cache when this position call is done + defer(function () { + delete zeroPosCache[id]; + }); + } -function listToStyles (list, options) { - var styles = []; - var newStyles = {}; + return zeroPosCache[id]; +}; - for (var i = 0; i < list.length; i++) { - var item = list[i]; - var id = options.base ? item[0] + options.base : item[0]; - var css = item[1]; - var media = item[2]; - var sourceMap = item[3]; - var part = {css: css, media: media, sourceMap: sourceMap}; +function removeUtilElements() { + if (zeroElement) { + document.body.removeChild(zeroElement); + } + zeroElement = null; +}; - if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]}); - else newStyles[id].parts.push(part); - } +function getBounds(el) { + var doc = undefined; + if (el === document) { + doc = document; + el = document.documentElement; + } else { + doc = el.ownerDocument; + } - return styles; -} + var docEl = doc.documentElement; -function insertStyleElement (options, style) { - var target = getElement(options.insertInto) + var box = getActualBoundingClientRect(el); - if (!target) { - throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid."); - } + var origin = getOrigin(); - var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1]; + box.top -= origin.top; + box.left -= origin.left; - if (options.insertAt === "top") { - if (!lastStyleElementInsertedAtTop) { - target.insertBefore(style, target.firstChild); - } else if (lastStyleElementInsertedAtTop.nextSibling) { - target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling); - } else { - target.appendChild(style); - } - stylesInsertedAtTop.push(style); - } else if (options.insertAt === "bottom") { - target.appendChild(style); - } else { - throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'."); - } -} + if (typeof box.width === 'undefined') { + box.width = document.body.scrollWidth - box.left - box.right; + } + if (typeof box.height === 'undefined') { + box.height = document.body.scrollHeight - box.top - box.bottom; + } -function removeStyleElement (style) { - if (style.parentNode === null) return false; - style.parentNode.removeChild(style); + box.top = box.top - docEl.clientTop; + box.left = box.left - docEl.clientLeft; + box.right = doc.body.clientWidth - box.width - box.left; + box.bottom = doc.body.clientHeight - box.height - box.top; - var idx = stylesInsertedAtTop.indexOf(style); - if(idx >= 0) { - stylesInsertedAtTop.splice(idx, 1); - } + return box; } -function createStyleElement (options) { - var style = document.createElement("style"); - - options.attrs.type = "text/css"; - - addAttrs(style, options.attrs); - insertStyleElement(options, style); - - return style; +function getOffsetParent(el) { + return el.offsetParent || document.documentElement; } -function createLinkElement (options) { - var link = document.createElement("link"); +function getScrollBarSize() { + var inner = document.createElement('div'); + inner.style.width = '100%'; + inner.style.height = '200px'; - options.attrs.type = "text/css"; - options.attrs.rel = "stylesheet"; + var outer = document.createElement('div'); + extend(outer.style, { + position: 'absolute', + top: 0, + left: 0, + pointerEvents: 'none', + visibility: 'hidden', + width: '200px', + height: '150px', + overflow: 'hidden' + }); - addAttrs(link, options.attrs); - insertStyleElement(options, link); + outer.appendChild(inner); - return link; -} + document.body.appendChild(outer); -function addAttrs (el, attrs) { - Object.keys(attrs).forEach(function (key) { - el.setAttribute(key, attrs[key]); - }); -} + var widthContained = inner.offsetWidth; + outer.style.overflow = 'scroll'; + var widthScroll = inner.offsetWidth; -function addStyle (obj, options) { - var style, update, remove, result; + if (widthContained === widthScroll) { + widthScroll = outer.clientWidth; + } - // If a transform function was defined, run it on the css - if (options.transform && obj.css) { - result = options.transform(obj.css); + document.body.removeChild(outer); - if (result) { - // If transform returns a value, use that instead of the original css. - // This allows running runtime transformations on the css. - obj.css = result; - } else { - // If the transform function returns a falsy value, don't add this css. - // This allows conditional loading of css - return function() { - // noop - }; - } - } + var width = widthContained - widthScroll; - if (options.singleton) { - var styleIndex = singletonCounter++; + return { width: width, height: width }; +} - style = singleton || (singleton = createStyleElement(options)); +function extend() { + var out = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0]; - update = applyToSingletonTag.bind(null, style, styleIndex, false); - remove = applyToSingletonTag.bind(null, style, styleIndex, true); + var args = []; - } else if ( - obj.sourceMap && - typeof URL === "function" && - typeof URL.createObjectURL === "function" && - typeof URL.revokeObjectURL === "function" && - typeof Blob === "function" && - typeof btoa === "function" - ) { - style = createLinkElement(options); - update = updateLink.bind(null, style, options); - remove = function () { - removeStyleElement(style); + Array.prototype.push.apply(args, arguments); - if(style.href) URL.revokeObjectURL(style.href); - }; - } else { - style = createStyleElement(options); - update = applyToTag.bind(null, style); - remove = function () { - removeStyleElement(style); - }; - } + args.slice(1).forEach(function (obj) { + if (obj) { + for (var key in obj) { + if (({}).hasOwnProperty.call(obj, key)) { + out[key] = obj[key]; + } + } + } + }); - update(obj); + return out; +} - return function updateStyle (newObj) { - if (newObj) { - if ( - newObj.css === obj.css && - newObj.media === obj.media && - newObj.sourceMap === obj.sourceMap - ) { - return; - } +function removeClass(el, name) { + if (typeof el.classList !== 'undefined') { + name.split(' ').forEach(function (cls) { + if (cls.trim()) { + el.classList.remove(cls); + } + }); + } else { + var regex = new RegExp('(^| )' + name.split(' ').join('|') + '( |$)', 'gi'); + var className = getClassName(el).replace(regex, ' '); + setClassName(el, className); + } +} - update(obj = newObj); - } else { - remove(); - } - }; +function addClass(el, name) { + if (typeof el.classList !== 'undefined') { + name.split(' ').forEach(function (cls) { + if (cls.trim()) { + el.classList.add(cls); + } + }); + } else { + removeClass(el, name); + var cls = getClassName(el) + (' ' + name); + setClassName(el, cls); + } } -var replaceText = (function () { - var textStore = []; +function hasClass(el, name) { + if (typeof el.classList !== 'undefined') { + return el.classList.contains(name); + } + var className = getClassName(el); + return new RegExp('(^| )' + name + '( |$)', 'gi').test(className); +} - return function (index, replacement) { - textStore[index] = replacement; +function getClassName(el) { + // Can't use just SVGAnimatedString here since nodes within a Frame in IE have + // completely separately SVGAnimatedString base classes + if (el.className instanceof el.ownerDocument.defaultView.SVGAnimatedString) { + return el.className.baseVal; + } + return el.className; +} - return textStore.filter(Boolean).join('\n'); - }; -})(); +function setClassName(el, className) { + el.setAttribute('class', className); +} -function applyToSingletonTag (style, index, remove, obj) { - var css = remove ? "" : obj.css; +function updateClasses(el, add, all) { + // Of the set of 'all' classes, we need the 'add' classes, and only the + // 'add' classes to be set. + all.forEach(function (cls) { + if (add.indexOf(cls) === -1 && hasClass(el, cls)) { + removeClass(el, cls); + } + }); - if (style.styleSheet) { - style.styleSheet.cssText = replaceText(index, css); - } else { - var cssNode = document.createTextNode(css); - var childNodes = style.childNodes; + add.forEach(function (cls) { + if (!hasClass(el, cls)) { + addClass(el, cls); + } + }); +} - if (childNodes[index]) style.removeChild(childNodes[index]); +var deferred = []; - if (childNodes.length) { - style.insertBefore(cssNode, childNodes[index]); - } else { - style.appendChild(cssNode); - } - } -} +var defer = function defer(fn) { + deferred.push(fn); +}; -function applyToTag (style, obj) { - var css = obj.css; - var media = obj.media; +var flush = function flush() { + var fn = undefined; + while (fn = deferred.pop()) { + fn(); + } +}; - if(media) { - style.setAttribute("media", media) - } +var Evented = (function () { + function Evented() { + _classCallCheck(this, Evented); + } - if(style.styleSheet) { - style.styleSheet.cssText = css; - } else { - while(style.firstChild) { - style.removeChild(style.firstChild); - } + _createClass(Evented, [{ + key: 'on', + value: function on(event, handler, ctx) { + var once = arguments.length <= 3 || arguments[3] === undefined ? false : arguments[3]; + + if (typeof this.bindings === 'undefined') { + this.bindings = {}; + } + if (typeof this.bindings[event] === 'undefined') { + this.bindings[event] = []; + } + this.bindings[event].push({ handler: handler, ctx: ctx, once: once }); + } + }, { + key: 'once', + value: function once(event, handler, ctx) { + this.on(event, handler, ctx, true); + } + }, { + key: 'off', + value: function off(event, handler) { + if (typeof this.bindings === 'undefined' || typeof this.bindings[event] === 'undefined') { + return; + } - style.appendChild(document.createTextNode(css)); - } -} + if (typeof handler === 'undefined') { + delete this.bindings[event]; + } else { + var i = 0; + while (i < this.bindings[event].length) { + if (this.bindings[event][i].handler === handler) { + this.bindings[event].splice(i, 1); + } else { + ++i; + } + } + } + } + }, { + key: 'trigger', + value: function trigger(event) { + if (typeof this.bindings !== 'undefined' && this.bindings[event]) { + var i = 0; -function updateLink (link, options, obj) { - var css = obj.css; - var sourceMap = obj.sourceMap; + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } - /* - If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled - and there is no publicPath defined then lets turn convertToAbsoluteUrls - on by default. Otherwise default to the convertToAbsoluteUrls option - directly - */ - var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap; + while (i < this.bindings[event].length) { + var _bindings$event$i = this.bindings[event][i]; + var handler = _bindings$event$i.handler; + var ctx = _bindings$event$i.ctx; + var once = _bindings$event$i.once; - if (options.convertToAbsoluteUrls || autoFixUrls) { - css = fixUrls(css); - } + var context = ctx; + if (typeof context === 'undefined') { + context = this; + } - if (sourceMap) { - // http://stackoverflow.com/a/26603875 - css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */"; - } + handler.apply(context, args); - var blob = new Blob([css], { type: "text/css" }); + if (once) { + this.bindings[event].splice(i, 1); + } else { + ++i; + } + } + } + } + }]); - var oldSrc = link.href; + return Evented; +})(); - link.href = URL.createObjectURL(blob); +TetherBase.Utils = { + getActualBoundingClientRect: getActualBoundingClientRect, + getScrollParents: getScrollParents, + getBounds: getBounds, + getOffsetParent: getOffsetParent, + extend: extend, + addClass: addClass, + removeClass: removeClass, + hasClass: hasClass, + updateClasses: updateClasses, + defer: defer, + flush: flush, + uniqueId: uniqueId, + Evented: Evented, + getScrollBarSize: getScrollBarSize, + removeUtilElements: removeUtilElements +}; - if(oldSrc) URL.revokeObjectURL(oldSrc); -} +exports['default'] = TetherBase; +module.exports = exports['default']; +},{}]},{},[4])(4) +}); /***/ }), -/* 74 */ -/***/ (function(module, exports, __webpack_require__) { +/* 320 */ +/***/ (function(module, exports) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * +/** + * lodash (Custom Build) <https://lodash.com/> + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors <https://jquery.org/> + * Released under MIT license <https://lodash.com/license> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ +/** Used as references for various `Number` constants. */ +var NAN = 0 / 0; + +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; + +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; + +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; -var _prodInvariant = __webpack_require__(25), - _assign = __webpack_require__(5); +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; -var ReactNoopUpdateQueue = __webpack_require__(75); +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; -var canDefineProperty = __webpack_require__(38); -var emptyObject = __webpack_require__(39); -var invariant = __webpack_require__(1); -var lowPriorityWarning = __webpack_require__(48); +/** Used for built-in method references. */ +var objectProto = Object.prototype; /** - * Base class helpers for the updating state of a component. + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. */ -function ReactComponent(props, context, updater) { - this.props = props; - this.context = context; - this.refs = emptyObject; - // We initialize the default updater but the real one gets injected by the - // renderer. - this.updater = updater || ReactNoopUpdateQueue; -} - -ReactComponent.prototype.isReactComponent = {}; +var objectToString = objectProto.toString; /** - * Sets a subset of the state. Always use this to mutate - * state. You should treat `this.state` as immutable. + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example * - * There is no guarantee that calls to `setState` will run synchronously, - * as they may eventually be batched together. You can provide an optional - * callback that will be executed when the call to setState is actually - * completed. + * _.isObject({}); + * // => true * - * When a function is provided to setState, it will be called at some point in - * the future (not synchronously). It will be called with the up to date - * component arguments (state, props, context). These values can be different - * from this.* because your function may be called after receiveProps but before - * shouldComponentUpdate, and this new state, props, and context will not yet be - * assigned to this. + * _.isObject([1, 2, 3]); + * // => true * - * @param {object|function} partialState Next partial state or function to - * produce next partial state to be merged with current state. - * @param {?function} callback Called after state is updated. - * @final - * @protected + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false */ -ReactComponent.prototype.setState = function (partialState, callback) { - !(typeof partialState === 'object' || typeof partialState === 'function' || partialState == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.') : _prodInvariant('85') : void 0; - this.updater.enqueueSetState(this, partialState); - if (callback) { - this.updater.enqueueCallback(this, callback, 'setState'); - } -}; +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. + * _.isObjectLike({}); + * // => true * - * @param {?function} callback Called after update is complete. - * @final - * @protected + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false */ -ReactComponent.prototype.forceUpdate = function (callback) { - this.updater.enqueueForceUpdate(this); - if (callback) { - this.updater.enqueueCallback(this, callback, 'forceUpdate'); - } -}; +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} /** - * Deprecated APIs. These APIs used to exist on classic React classes but since - * we would like to deprecate them, we're not going to move them over to this - * modern base class. Instead, we define a getter that warns if it's accessed. + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false */ -if (process.env.NODE_ENV !== 'production') { - var deprecatedAPIs = { - isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'], - replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).'] - }; - var defineDeprecationWarning = function (methodName, info) { - if (canDefineProperty) { - Object.defineProperty(ReactComponent.prototype, methodName, { - get: function () { - lowPriorityWarning(false, '%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]); - return undefined; - } - }); - } - }; - for (var fnName in deprecatedAPIs) { - if (deprecatedAPIs.hasOwnProperty(fnName)) { - defineDeprecationWarning(fnName, deprecatedAPIs[fnName]); - } - } +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); } /** - * Base class helpers for the updating state of a component. + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 */ -function ReactPureComponent(props, context, updater) { - // Duplicated from ReactComponent. - this.props = props; - this.context = context; - this.refs = emptyObject; - // We initialize the default updater but the real one gets injected by the - // renderer. - this.updater = updater || ReactNoopUpdateQueue; +function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); } -function ComponentDummy() {} -ComponentDummy.prototype = ReactComponent.prototype; -ReactPureComponent.prototype = new ComponentDummy(); -ReactPureComponent.prototype.constructor = ReactPureComponent; -// Avoid an extra prototype jump for these methods. -_assign(ReactPureComponent.prototype, ReactComponent.prototype); -ReactPureComponent.prototype.isPureReactComponent = true; +module.exports = toNumber; + + +/***/ }), +/* 321 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var _CSSTransitionGroup = __webpack_require__(322); + +var _CSSTransitionGroup2 = _interopRequireDefault(_CSSTransitionGroup); + +var _TransitionGroup = __webpack_require__(151); + +var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } module.exports = { - Component: ReactComponent, - PureComponent: ReactPureComponent + TransitionGroup: _TransitionGroup2.default, + CSSTransitionGroup: _CSSTransitionGroup2.default }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 75 */ +/* 322 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(process) { +exports.__esModule = true; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var warning = __webpack_require__(2); +var _react = __webpack_require__(6); -function warnNoop(publicInstance, callerName) { - if (process.env.NODE_ENV !== 'production') { - var constructor = publicInstance.constructor; - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; - } -} +var _react2 = _interopRequireDefault(_react); -/** - * This is the abstract API for an update queue. - */ -var ReactNoopUpdateQueue = { - /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function (publicInstance) { - return false; - }, +var _propTypes = __webpack_require__(40); - /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. - * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @internal - */ - enqueueCallback: function (publicInstance, callback) {}, +var _propTypes2 = _interopRequireDefault(_propTypes); - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal - */ - enqueueForceUpdate: function (publicInstance) { - warnNoop(publicInstance, 'forceUpdate'); - }, +var _TransitionGroup = __webpack_require__(151); - /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} completeState Next state. - * @internal - */ - enqueueReplaceState: function (publicInstance, completeState) { - warnNoop(publicInstance, 'replaceState'); - }, +var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} partialState Next partial state to be merged with state. - * @internal - */ - enqueueSetState: function (publicInstance, partialState) { - warnNoop(publicInstance, 'setState'); - } +var _CSSTransitionGroupChild = __webpack_require__(326); + +var _CSSTransitionGroupChild2 = _interopRequireDefault(_CSSTransitionGroupChild); + +var _PropTypes = __webpack_require__(153); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var propTypes = { + transitionName: _PropTypes.nameShape.isRequired, + + transitionAppear: _propTypes2.default.bool, + transitionEnter: _propTypes2.default.bool, + transitionLeave: _propTypes2.default.bool, + transitionAppearTimeout: (0, _PropTypes.transitionTimeout)('Appear'), + transitionEnterTimeout: (0, _PropTypes.transitionTimeout)('Enter'), + transitionLeaveTimeout: (0, _PropTypes.transitionTimeout)('Leave') }; -module.exports = ReactNoopUpdateQueue; +var defaultProps = { + transitionAppear: false, + transitionEnter: true, + transitionLeave: true +}; + +var CSSTransitionGroup = function (_React$Component) { + _inherits(CSSTransitionGroup, _React$Component); + + function CSSTransitionGroup() { + var _temp, _this, _ret; + + _classCallCheck(this, CSSTransitionGroup); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this._wrapChild = function (child) { + return _react2.default.createElement(_CSSTransitionGroupChild2.default, { + name: _this.props.transitionName, + appear: _this.props.transitionAppear, + enter: _this.props.transitionEnter, + leave: _this.props.transitionLeave, + appearTimeout: _this.props.transitionAppearTimeout, + enterTimeout: _this.props.transitionEnterTimeout, + leaveTimeout: _this.props.transitionLeaveTimeout + }, child); + }, _temp), _possibleConstructorReturn(_this, _ret); + } + + // We need to provide this childFactory so that + // ReactCSSTransitionGroupChild can receive updates to name, enter, and + // leave while it is leaving. + + + CSSTransitionGroup.prototype.render = function render() { + return _react2.default.createElement(_TransitionGroup2.default, _extends({}, this.props, { childFactory: this._wrapChild })); + }; + + return CSSTransitionGroup; +}(_react2.default.Component); + +CSSTransitionGroup.displayName = 'CSSTransitionGroup'; + + +CSSTransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; +CSSTransitionGroup.defaultProps = defaultProps; + +exports.default = CSSTransitionGroup; +module.exports = exports['default']; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 76 */ +/* 323 */ +/***/ (function(module, exports) { + + +module.exports = function chain(){ + var len = arguments.length + var args = []; + + for (var i = 0; i < len; i++) + args[i] = arguments[i] + + args = args.filter(function(fn){ return fn != null }) + + if (args.length === 0) return undefined + if (args.length === 1) return args[0] + + return args.reduce(function(current, next){ + return function chainedFunction() { + current.apply(this, arguments); + next.apply(this, arguments); + }; + }) +} + + +/***/ }), +/* 324 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2014-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-2015, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. - * - * */ -// The Symbol used to tag the ReactElement type. If there is no native Symbol -// nor polyfill, then a plain number is used for performance. +/** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ -var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; +var warning = function() {}; -module.exports = REACT_ELEMENT_TYPE; +if (process.env.NODE_ENV !== 'production') { + warning = function(condition, format, args) { + var len = arguments.length; + args = new Array(len > 2 ? len - 2 : 0); + for (var key = 2; key < len; key++) { + args[key - 2] = arguments[key]; + } + if (format === undefined) { + throw new Error( + '`warning(condition, format, ...args)` requires a warning ' + + 'message argument' + ); + } + + if (format.length < 10 || (/^[s\W]*$/).test(format)) { + throw new Error( + 'The warning format should be able to uniquely identify this ' + + 'warning. Please, use a more descriptive format than: ' + format + ); + } + + if (!condition) { + var argIndex = 0; + var message = 'Warning: ' + + format.replace(/%s/g, function() { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.error(message); + } + try { + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch(x) {} + } + }; +} + +module.exports = warning; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 77 */ +/* 325 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; + + +exports.__esModule = true; +exports.getChildMapping = getChildMapping; +exports.mergeChildMappings = mergeChildMappings; + +var _react = __webpack_require__(6); + /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. + * Given `this.props.children`, return an object mapping key to child. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * @param {*} children `this.props.children` + * @return {object} Mapping of key to child + */ +function getChildMapping(children) { + if (!children) { + return children; + } + var result = {}; + _react.Children.map(children, function (child) { + return child; + }).forEach(function (child) { + result[child.key] = child; + }); + return result; +} + +/** + * When you're adding or removing children some may be added or removed in the + * same render pass. We want to show *both* since we want to simultaneously + * animate elements in and out. This function takes a previous set of keys + * and a new set of keys and merges them with its best guess of the correct + * ordering. In the future we may expose some of the utilities in + * ReactMultiChild to make this easy, but for now React itself does not + * directly have this concept of the union of prevChildren and nextChildren + * so we implement it here. * - * + * @param {object} prev prev children as returned from + * `ReactTransitionChildMapping.getChildMapping()`. + * @param {object} next next children as returned from + * `ReactTransitionChildMapping.getChildMapping()`. + * @return {object} a key set that contains all keys in `prev` and all keys + * in `next` in a reasonable order. */ +function mergeChildMappings(prev, next) { + prev = prev || {}; + next = next || {}; + function getValueForKey(key) { + if (next.hasOwnProperty(key)) { + return next[key]; + } + return prev[key]; + } -/* global Symbol */ + // For each key of `next`, the list of keys to insert before that key in + // the combined list + var nextKeysPending = {}; -var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; -var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. + var pendingKeys = []; + for (var prevKey in prev) { + if (next.hasOwnProperty(prevKey)) { + if (pendingKeys.length) { + nextKeysPending[prevKey] = pendingKeys; + pendingKeys = []; + } + } else { + pendingKeys.push(prevKey); + } + } -/** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } - * - * @param {?object} maybeIterable - * @return {?function} - */ -function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; + var i = void 0; + var childMapping = {}; + for (var nextKey in next) { + if (nextKeysPending.hasOwnProperty(nextKey)) { + for (i = 0; i < nextKeysPending[nextKey].length; i++) { + var pendingNextKey = nextKeysPending[nextKey][i]; + childMapping[nextKeysPending[nextKey][i]] = getValueForKey(pendingNextKey); + } + } + childMapping[nextKey] = getValueForKey(nextKey); } -} -module.exports = getIteratorFn; + // Finally, add the keys which didn't appear before any key in `next` + for (i = 0; i < pendingKeys.length; i++) { + childMapping[pendingKeys[i]] = getValueForKey(pendingKeys[i]); + } + + return childMapping; +} /***/ }), -/* 78 */ +/* 326 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(process) { -/** - * ReactElementValidator provides a wrapper around a element factory - * which validates the props passed to the element. This is intended to be - * used only in DEV and could be replaced by a static type checker for languages - * that support it. - */ +exports.__esModule = true; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +var _addClass = __webpack_require__(327); -var ReactCurrentOwner = __webpack_require__(14); -var ReactComponentTreeHook = __webpack_require__(10); -var ReactElement = __webpack_require__(19); +var _addClass2 = _interopRequireDefault(_addClass); -var checkReactTypeSpec = __webpack_require__(127); +var _removeClass = __webpack_require__(329); -var canDefineProperty = __webpack_require__(38); -var getIteratorFn = __webpack_require__(77); -var warning = __webpack_require__(2); -var lowPriorityWarning = __webpack_require__(48); +var _removeClass2 = _interopRequireDefault(_removeClass); -function getDeclarationErrorAddendum() { - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; -} +var _requestAnimationFrame = __webpack_require__(330); -function getSourceInfoErrorAddendum(elementProps) { - if (elementProps !== null && elementProps !== undefined && elementProps.__source !== undefined) { - var source = elementProps.__source; - var fileName = source.fileName.replace(/^.*[\\\/]/, ''); - var lineNumber = source.lineNumber; - return ' Check your code at ' + fileName + ':' + lineNumber + '.'; +var _requestAnimationFrame2 = _interopRequireDefault(_requestAnimationFrame); + +var _properties = __webpack_require__(331); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _propTypes = __webpack_require__(40); + +var _propTypes2 = _interopRequireDefault(_propTypes); + +var _reactDom = __webpack_require__(76); + +var _PropTypes = __webpack_require__(153); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var events = []; +if (_properties.transitionEnd) events.push(_properties.transitionEnd); +if (_properties.animationEnd) events.push(_properties.animationEnd); + +function addEndListener(node, listener) { + if (events.length) { + events.forEach(function (e) { + return node.addEventListener(e, listener, false); + }); + } else { + setTimeout(listener, 0); } - return ''; + + return function () { + if (!events.length) return; + events.forEach(function (e) { + return node.removeEventListener(e, listener, false); + }); + }; } -/** - * Warn if there's no key explicitly set on dynamic arrays of children or - * object keys are not valid. This allows us to keep track of children between - * updates. - */ -var ownerHasKeyUseWarning = {}; +var propTypes = { + children: _propTypes2.default.node, + name: _PropTypes.nameShape.isRequired, -function getCurrentComponentErrorInfo(parentType) { - var info = getDeclarationErrorAddendum(); + // Once we require timeouts to be specified, we can remove the + // boolean flags (appear etc.) and just accept a number + // or a bool for the timeout flags (appearTimeout etc.) + appear: _propTypes2.default.bool, + enter: _propTypes2.default.bool, + leave: _propTypes2.default.bool, + appearTimeout: _propTypes2.default.number, + enterTimeout: _propTypes2.default.number, + leaveTimeout: _propTypes2.default.number +}; - if (!info) { - var parentName = typeof parentType === 'string' ? parentType : parentType.displayName || parentType.name; - if (parentName) { - info = ' Check the top-level render call using <' + parentName + '>.'; +var CSSTransitionGroupChild = function (_React$Component) { + _inherits(CSSTransitionGroupChild, _React$Component); + + function CSSTransitionGroupChild() { + var _temp, _this, _ret; + + _classCallCheck(this, CSSTransitionGroupChild); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; } - } - return info; -} -/** - * Warn if the element doesn't have an explicit key assigned to it. - * This element is in an array. The array could grow and shrink or be - * reordered. All children that haven't already been validated are required to - * have a "key" property assigned to it. Error statuses are cached so a warning - * will only be shown once. - * - * @internal - * @param {ReactElement} element Element that requires a key. - * @param {*} parentType element's parent's type. - */ -function validateExplicitKey(element, parentType) { - if (!element._store || element._store.validated || element.key != null) { - return; + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.componentWillAppear = function (done) { + if (_this.props.appear) { + _this.transition('appear', done, _this.props.appearTimeout); + } else { + done(); + } + }, _this.componentWillEnter = function (done) { + if (_this.props.enter) { + _this.transition('enter', done, _this.props.enterTimeout); + } else { + done(); + } + }, _this.componentWillLeave = function (done) { + if (_this.props.leave) { + _this.transition('leave', done, _this.props.leaveTimeout); + } else { + done(); + } + }, _temp), _possibleConstructorReturn(_this, _ret); } - element._store.validated = true; - var memoizer = ownerHasKeyUseWarning.uniqueKey || (ownerHasKeyUseWarning.uniqueKey = {}); + CSSTransitionGroupChild.prototype.componentWillMount = function componentWillMount() { + this.classNameAndNodeQueue = []; + this.transitionTimeouts = []; + }; - var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType); - if (memoizer[currentComponentErrorInfo]) { - return; - } - memoizer[currentComponentErrorInfo] = true; + CSSTransitionGroupChild.prototype.componentWillUnmount = function componentWillUnmount() { + this.unmounted = true; - // Usually the current owner is the offender, but if it accepts children as a - // property, it may be the creator of the child that's responsible for - // assigning it a key. - var childOwner = ''; - if (element && element._owner && element._owner !== ReactCurrentOwner.current) { - // Give the component that originally created this child. - childOwner = ' It was passed a child from ' + element._owner.getName() + '.'; - } + if (this.timeout) { + clearTimeout(this.timeout); + } + this.transitionTimeouts.forEach(function (timeout) { + clearTimeout(timeout); + }); - process.env.NODE_ENV !== 'production' ? warning(false, 'Each child in an array or iterator should have a unique "key" prop.' + '%s%s See https://fb.me/react-warning-keys for more information.%s', currentComponentErrorInfo, childOwner, ReactComponentTreeHook.getCurrentStackAddendum(element)) : void 0; -} + this.classNameAndNodeQueue.length = 0; + }; -/** - * Ensure that every element either is passed in a static location, in an - * array with an explicit keys property defined, or in an object literal - * with valid key property. - * - * @internal - * @param {ReactNode} node Statically passed child of any type. - * @param {*} parentType node's parent's type. - */ -function validateChildKeys(node, parentType) { - if (typeof node !== 'object') { - return; - } - if (Array.isArray(node)) { - for (var i = 0; i < node.length; i++) { - var child = node[i]; - if (ReactElement.isValidElement(child)) { - validateExplicitKey(child, parentType); + CSSTransitionGroupChild.prototype.transition = function transition(animationType, finishCallback, timeout) { + var node = (0, _reactDom.findDOMNode)(this); + + if (!node) { + if (finishCallback) { + finishCallback(); } + return; } - } else if (ReactElement.isValidElement(node)) { - // This element was passed in a valid location. - if (node._store) { - node._store.validated = true; - } - } else if (node) { - var iteratorFn = getIteratorFn(node); - // Entry iterators provide implicit keys. - if (iteratorFn) { - if (iteratorFn !== node.entries) { - var iterator = iteratorFn.call(node); - var step; - while (!(step = iterator.next()).done) { - if (ReactElement.isValidElement(step.value)) { - validateExplicitKey(step.value, parentType); - } - } + + var className = this.props.name[animationType] || this.props.name + '-' + animationType; + var activeClassName = this.props.name[animationType + 'Active'] || className + '-active'; + var timer = null; + var removeListeners = void 0; + + (0, _addClass2.default)(node, className); + + // Need to do this to actually trigger a transition. + this.queueClassAndNode(activeClassName, node); + + // Clean-up the animation after the specified delay + var finish = function finish(e) { + if (e && e.target !== node) { + return; + } + + clearTimeout(timer); + if (removeListeners) removeListeners(); + + (0, _removeClass2.default)(node, className); + (0, _removeClass2.default)(node, activeClassName); + + if (removeListeners) removeListeners(); + + // Usually this optional callback is used for informing an owner of + // a leave animation and telling it to remove the child. + if (finishCallback) { + finishCallback(); } + }; + + if (timeout) { + timer = setTimeout(finish, timeout); + this.transitionTimeouts.push(timer); + } else if (_properties.transitionEnd) { + removeListeners = addEndListener(node, finish); } - } -} + }; + + CSSTransitionGroupChild.prototype.queueClassAndNode = function queueClassAndNode(className, node) { + var _this2 = this; + + this.classNameAndNodeQueue.push({ + className: className, + node: node + }); + + if (!this.rafHandle) { + this.rafHandle = (0, _requestAnimationFrame2.default)(function () { + return _this2.flushClassNameAndNodeQueue(); + }); + } + }; + + CSSTransitionGroupChild.prototype.flushClassNameAndNodeQueue = function flushClassNameAndNodeQueue() { + if (!this.unmounted) { + this.classNameAndNodeQueue.forEach(function (obj) { + // This is for to force a repaint, + // which is necessary in order to transition styles when adding a class name. + /* eslint-disable no-unused-expressions */ + obj.node.scrollTop; + /* eslint-enable no-unused-expressions */ + (0, _addClass2.default)(obj.node, obj.className); + }); + } + this.classNameAndNodeQueue.length = 0; + this.rafHandle = null; + }; + + CSSTransitionGroupChild.prototype.render = function render() { + var props = _extends({}, this.props); + delete props.name; + delete props.appear; + delete props.enter; + delete props.leave; + delete props.appearTimeout; + delete props.enterTimeout; + delete props.leaveTimeout; + delete props.children; + return _react2.default.cloneElement(_react2.default.Children.only(this.props.children), props); + }; + + return CSSTransitionGroupChild; +}(_react2.default.Component); + +CSSTransitionGroupChild.displayName = 'CSSTransitionGroupChild'; + + +CSSTransitionGroupChild.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; + +exports.default = CSSTransitionGroupChild; +module.exports = exports['default']; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 327 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; -/** - * Given an element, validate that its props follow the propTypes definition, - * provided by the type. - * - * @param {ReactElement} element - */ -function validatePropTypes(element) { - var componentClass = element.type; - if (typeof componentClass !== 'function') { - return; - } - var name = componentClass.displayName || componentClass.name; - if (componentClass.propTypes) { - checkReactTypeSpec(componentClass.propTypes, element.props, 'prop', name, element, null); - } - if (typeof componentClass.getDefaultProps === 'function') { - process.env.NODE_ENV !== 'production' ? warning(componentClass.getDefaultProps.isReactClassApproved, 'getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.') : void 0; - } -} -var ReactElementValidator = { - createElement: function (type, props, children) { - var validType = typeof type === 'string' || typeof type === 'function'; - // We warn in this case but don't throw. We expect the element creation to - // succeed and there will likely be errors in render. - if (!validType) { - if (typeof type !== 'function' && typeof type !== 'string') { - var info = ''; - if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { - info += ' You likely forgot to export your component from the file ' + "it's defined in."; - } +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = addClass; - var sourceInfo = getSourceInfoErrorAddendum(props); - if (sourceInfo) { - info += sourceInfo; - } else { - info += getDeclarationErrorAddendum(); - } +var _hasClass = __webpack_require__(328); - info += ReactComponentTreeHook.getCurrentStackAddendum(); +var _hasClass2 = _interopRequireDefault(_hasClass); - var currentSource = props !== null && props !== undefined && props.__source !== undefined ? props.__source : null; - ReactComponentTreeHook.pushNonStandardWarningStack(true, currentSource); - process.env.NODE_ENV !== 'production' ? warning(false, 'React.createElement: type is invalid -- expected a string (for ' + 'built-in components) or a class/function (for composite ' + 'components) but got: %s.%s', type == null ? type : typeof type, info) : void 0; - ReactComponentTreeHook.popNonStandardWarningStack(); - } - } +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - var element = ReactElement.createElement.apply(this, arguments); +function addClass(element, className) { + if (element.classList) element.classList.add(className);else if (!(0, _hasClass2.default)(element)) element.className = element.className + ' ' + className; +} +module.exports = exports['default']; - // The result can be nullish if a mock or a custom function is used. - // TODO: Drop this when these are no longer allowed as the type argument. - if (element == null) { - return element; - } +/***/ }), +/* 328 */ +/***/ (function(module, exports, __webpack_require__) { - // Skip key warning if the type isn't valid since our key validation logic - // doesn't expect a non-string/function type and can throw confusing errors. - // We don't want exception behavior to differ between dev and prod. - // (Rendering will throw with a helpful message and as soon as the type is - // fixed, the key warnings will appear.) - if (validType) { - for (var i = 2; i < arguments.length; i++) { - validateChildKeys(arguments[i], type); - } - } +"use strict"; - validatePropTypes(element); - return element; - }, +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = hasClass; +function hasClass(element, className) { + if (element.classList) return !!className && element.classList.contains(className);else return (" " + element.className + " ").indexOf(" " + className + " ") !== -1; +} +module.exports = exports["default"]; - createFactory: function (type) { - var validatedFactory = ReactElementValidator.createElement.bind(null, type); - // Legacy hook TODO: Warn if this is accessed - validatedFactory.type = type; +/***/ }), +/* 329 */ +/***/ (function(module, exports, __webpack_require__) { - if (process.env.NODE_ENV !== 'production') { - if (canDefineProperty) { - Object.defineProperty(validatedFactory, 'type', { - enumerable: false, - get: function () { - lowPriorityWarning(false, 'Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.'); - Object.defineProperty(this, 'type', { - value: type - }); - return type; - } - }); - } - } +"use strict"; - return validatedFactory; - }, - cloneElement: function (element, props, children) { - var newElement = ReactElement.cloneElement.apply(this, arguments); - for (var i = 2; i < arguments.length; i++) { - validateChildKeys(arguments[i], newElement.type); - } - validatePropTypes(newElement); - return newElement; - } +module.exports = function removeClass(element, className) { + if (element.classList) element.classList.remove(className);else element.className = element.className.replace(new RegExp('(^|\\s)' + className + '(?:\\s|$)', 'g'), '$1').replace(/\s+/g, ' ').replace(/^\s*|\s*$/g, ''); }; -module.exports = ReactElementValidator; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - /***/ }), -/* 79 */ +/* 330 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +Object.defineProperty(exports, "__esModule", { + value: true +}); -// React 15.5 references this module, and assumes PropTypes are still callable in production. -// Therefore we re-export development-only version with all the PropTypes checks here. -// However if one is migrating to the `prop-types` npm library, they will go through the -// `index.js` entry point, and it will branch depending on the environment. -var factory = __webpack_require__(80); -module.exports = function(isValidElement) { - // It is still allowed in 15.5. - var throwOnDirectAccess = false; - return factory(isValidElement, throwOnDirectAccess); +var _inDOM = __webpack_require__(152); + +var _inDOM2 = _interopRequireDefault(_inDOM); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var vendors = ['', 'webkit', 'moz', 'o', 'ms']; +var cancel = 'clearTimeout'; +var raf = fallback; +var compatRaf = void 0; + +var getKey = function getKey(vendor, k) { + return vendor + (!vendor ? k : k[0].toUpperCase() + k.substr(1)) + 'AnimationFrame'; }; +if (_inDOM2.default) { + vendors.some(function (vendor) { + var rafKey = getKey(vendor, 'request'); + + if (rafKey in window) { + cancel = getKey(vendor, 'cancel'); + return raf = function raf(cb) { + return window[rafKey](cb); + }; + } + }); +} + +/* https://github.com/component/raf */ +var prev = new Date().getTime(); +function fallback(fn) { + var curr = new Date().getTime(), + ms = Math.max(0, 16 - (curr - prev)), + req = setTimeout(fn, ms); + + prev = curr; + return req; +} + +compatRaf = function compatRaf(cb) { + return raf(cb); +}; +compatRaf.cancel = function (id) { + window[cancel] && typeof window[cancel] === 'function' && window[cancel](id); +}; +exports.default = compatRaf; +module.exports = exports['default']; /***/ }), -/* 80 */ +/* 331 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.animationEnd = exports.animationDelay = exports.animationTiming = exports.animationDuration = exports.animationName = exports.transitionEnd = exports.transitionDuration = exports.transitionDelay = exports.transitionTiming = exports.transitionProperty = exports.transform = undefined; -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +var _inDOM = __webpack_require__(152); -var ReactPropTypesSecret = __webpack_require__(49); -var checkPropTypes = __webpack_require__(131); +var _inDOM2 = _interopRequireDefault(_inDOM); -module.exports = function(isValidElement, throwOnDirectAccess) { - /* global Symbol */ - var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; - var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - /** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } - * - * @param {?object} maybeIterable - * @return {?function} - */ - function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; - } - } +var transform = 'transform'; +var prefix = void 0, + transitionEnd = void 0, + animationEnd = void 0; +var transitionProperty = void 0, + transitionDuration = void 0, + transitionTiming = void 0, + transitionDelay = void 0; +var animationName = void 0, + animationDuration = void 0, + animationTiming = void 0, + animationDelay = void 0; - /** - * Collection of methods that allow declaration and validation of props that are - * supplied to React components. Example usage: - * - * var Props = require('ReactPropTypes'); - * var MyArticle = React.createClass({ - * propTypes: { - * // An optional string prop named "description". - * description: Props.string, - * - * // A required enum prop named "category". - * category: Props.oneOf(['News','Photos']).isRequired, - * - * // A prop named "dialog" that requires an instance of Dialog. - * dialog: Props.instanceOf(Dialog).isRequired - * }, - * render: function() { ... } - * }); - * - * A more formal specification of how these methods are used: - * - * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...) - * decl := ReactPropTypes.{type}(.isRequired)? - * - * Each and every declaration produces a function with the same signature. This - * allows the creation of custom validation functions. For example: - * - * var MyLink = React.createClass({ - * propTypes: { - * // An optional string or URI prop named "href". - * href: function(props, propName, componentName) { - * var propValue = props[propName]; - * if (propValue != null && typeof propValue !== 'string' && - * !(propValue instanceof URI)) { - * return new Error( - * 'Expected a string or an URI for ' + propName + ' in ' + - * componentName - * ); - * } - * } - * }, - * render: function() {...} - * }); - * - * @internal - */ +if (_inDOM2.default) { + var _getTransitionPropert = getTransitionProperties(); - var ANONYMOUS = '<<anonymous>>'; + prefix = _getTransitionPropert.prefix; + exports.transitionEnd = transitionEnd = _getTransitionPropert.transitionEnd; + exports.animationEnd = animationEnd = _getTransitionPropert.animationEnd; - // Important! - // Keep this list in sync with production version in `./factoryWithThrowingShims.js`. - var ReactPropTypes = { - array: createPrimitiveTypeChecker('array'), - bool: createPrimitiveTypeChecker('boolean'), - func: createPrimitiveTypeChecker('function'), - number: createPrimitiveTypeChecker('number'), - object: createPrimitiveTypeChecker('object'), - string: createPrimitiveTypeChecker('string'), - symbol: createPrimitiveTypeChecker('symbol'), - any: createAnyTypeChecker(), - arrayOf: createArrayOfTypeChecker, - element: createElementTypeChecker(), - instanceOf: createInstanceTypeChecker, - node: createNodeChecker(), - objectOf: createObjectOfTypeChecker, - oneOf: createEnumTypeChecker, - oneOfType: createUnionTypeChecker, - shape: createShapeTypeChecker - }; + exports.transform = transform = prefix + '-' + transform; + exports.transitionProperty = transitionProperty = prefix + '-transition-property'; + exports.transitionDuration = transitionDuration = prefix + '-transition-duration'; + exports.transitionDelay = transitionDelay = prefix + '-transition-delay'; + exports.transitionTiming = transitionTiming = prefix + '-transition-timing-function'; - /** - * inlined Object.is polyfill to avoid requiring consumers ship their own - * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is - */ - /*eslint-disable no-self-compare*/ - function is(x, y) { - // SameValue algorithm - if (x === y) { - // Steps 1-5, 7-10 - // Steps 6.b-6.e: +0 != -0 - return x !== 0 || 1 / x === 1 / y; - } else { - // Step 6.a: NaN == NaN - return x !== x && y !== y; - } - } - /*eslint-enable no-self-compare*/ + exports.animationName = animationName = prefix + '-animation-name'; + exports.animationDuration = animationDuration = prefix + '-animation-duration'; + exports.animationTiming = animationTiming = prefix + '-animation-delay'; + exports.animationDelay = animationDelay = prefix + '-animation-timing-function'; +} - /** - * We use an Error-like object for backward compatibility as people may call - * PropTypes directly and inspect their output. However, we don't use real - * Errors anymore. We don't inspect their stack anyway, and creating them - * is prohibitively expensive if they are created too often, such as what - * happens in oneOfType() for any type before the one that matched. - */ - function PropTypeError(message) { - this.message = message; - this.stack = ''; - } - // Make `instanceof Error` still work for returned errors. - PropTypeError.prototype = Error.prototype; +exports.transform = transform; +exports.transitionProperty = transitionProperty; +exports.transitionTiming = transitionTiming; +exports.transitionDelay = transitionDelay; +exports.transitionDuration = transitionDuration; +exports.transitionEnd = transitionEnd; +exports.animationName = animationName; +exports.animationDuration = animationDuration; +exports.animationTiming = animationTiming; +exports.animationDelay = animationDelay; +exports.animationEnd = animationEnd; +exports.default = { + transform: transform, + end: transitionEnd, + property: transitionProperty, + timing: transitionTiming, + delay: transitionDelay, + duration: transitionDuration +}; - function createChainableTypeChecker(validate) { - if (process.env.NODE_ENV !== 'production') { - var manualPropTypeCallCache = {}; - var manualPropTypeWarningCount = 0; - } - function checkType(isRequired, props, propName, componentName, location, propFullName, secret) { - componentName = componentName || ANONYMOUS; - propFullName = propFullName || propName; - if (secret !== ReactPropTypesSecret) { - if (throwOnDirectAccess) { - // New behavior only for users of `prop-types` package - invariant( - false, - 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + - 'Use `PropTypes.checkPropTypes()` to call them. ' + - 'Read more at http://fb.me/use-check-prop-types' - ); - } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') { - // Old behavior for people using React.PropTypes - var cacheKey = componentName + ':' + propName; - if ( - !manualPropTypeCallCache[cacheKey] && - // Avoid spamming the console because they are often not actionable except for lib authors - manualPropTypeWarningCount < 3 - ) { - warning( - false, - 'You are manually calling a React.PropTypes validation ' + - 'function for the `%s` prop on `%s`. This is deprecated ' + - 'and will throw in the standalone `prop-types` package. ' + - 'You may be seeing this warning due to a third-party PropTypes ' + - 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.', - propFullName, - componentName - ); - manualPropTypeCallCache[cacheKey] = true; - manualPropTypeWarningCount++; - } - } - } - if (props[propName] == null) { - if (isRequired) { - if (props[propName] === null) { - return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.')); - } - return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.')); - } - return null; - } else { - return validate(props, propName, componentName, location, propFullName); - } +function getTransitionProperties() { + var style = document.createElement('div').style; + + var vendorMap = { + O: function O(e) { + return 'o' + e.toLowerCase(); + }, + Moz: function Moz(e) { + return e.toLowerCase(); + }, + Webkit: function Webkit(e) { + return 'webkit' + e; + }, + ms: function ms(e) { + return 'MS' + e; } + }; - var chainedCheckType = checkType.bind(null, false); - chainedCheckType.isRequired = checkType.bind(null, true); + var vendors = Object.keys(vendorMap); - return chainedCheckType; - } + var transitionEnd = void 0, + animationEnd = void 0; + var prefix = ''; - function createPrimitiveTypeChecker(expectedType) { - function validate(props, propName, componentName, location, propFullName, secret) { - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== expectedType) { - // `propValue` being instance of, say, date/regexp, pass the 'object' - // check, but we can offer a more precise error message here rather than - // 'of type `object`'. - var preciseType = getPreciseType(propValue); + for (var i = 0; i < vendors.length; i++) { + var vendor = vendors[i]; - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.')); - } - return null; + if (vendor + 'TransitionProperty' in style) { + prefix = '-' + vendor.toLowerCase(); + transitionEnd = vendorMap[vendor]('TransitionEnd'); + animationEnd = vendorMap[vendor]('AnimationEnd'); + break; } - return createChainableTypeChecker(validate); } - function createAnyTypeChecker() { - return createChainableTypeChecker(emptyFunction.thatReturnsNull); - } + if (!transitionEnd && 'transitionProperty' in style) transitionEnd = 'transitionend'; - function createArrayOfTypeChecker(typeChecker) { - function validate(props, propName, componentName, location, propFullName) { - if (typeof typeChecker !== 'function') { - return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.'); - } - var propValue = props[propName]; - if (!Array.isArray(propValue)) { - var propType = getPropType(propValue); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.')); - } - for (var i = 0; i < propValue.length; i++) { - var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret); - if (error instanceof Error) { - return error; - } - } - return null; - } - return createChainableTypeChecker(validate); - } + if (!animationEnd && 'animationName' in style) animationEnd = 'animationend'; - function createElementTypeChecker() { - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - if (!isValidElement(propValue)) { - var propType = getPropType(propValue); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.')); - } - return null; - } - return createChainableTypeChecker(validate); - } + style = null; + + return { animationEnd: animationEnd, transitionEnd: transitionEnd, prefix: prefix }; +} + +/***/ }), +/* 332 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - function createInstanceTypeChecker(expectedClass) { - function validate(props, propName, componentName, location, propFullName) { - if (!(props[propName] instanceof expectedClass)) { - var expectedClassName = expectedClass.name || ANONYMOUS; - var actualClassName = getClassName(props[propName]); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.')); - } - return null; - } - return createChainableTypeChecker(validate); - } +var _reactstrap = __webpack_require__(93); - function createEnumTypeChecker(expectedValues) { - if (!Array.isArray(expectedValues)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOf, expected an instance of array.') : void 0; - return emptyFunction.thatReturnsNull; - } +var _axios = __webpack_require__(335); - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - for (var i = 0; i < expectedValues.length; i++) { - if (is(propValue, expectedValues[i])) { - return null; - } - } +var _axios2 = _interopRequireDefault(_axios); - var valuesString = JSON.stringify(expectedValues); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + propValue + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.')); - } - return createChainableTypeChecker(validate); - } +var _react = __webpack_require__(6); - function createObjectOfTypeChecker(typeChecker) { - function validate(props, propName, componentName, location, propFullName) { - if (typeof typeChecker !== 'function') { - return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.'); - } - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== 'object') { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.')); - } - for (var key in propValue) { - if (propValue.hasOwnProperty(key)) { - var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); - if (error instanceof Error) { - return error; - } - } - } - return null; - } - return createChainableTypeChecker(validate); - } +var _react2 = _interopRequireDefault(_react); - function createUnionTypeChecker(arrayOfTypeCheckers) { - if (!Array.isArray(arrayOfTypeCheckers)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOfType, expected an instance of array.') : void 0; - return emptyFunction.thatReturnsNull; - } +var _classnames = __webpack_require__(41); - for (var i = 0; i < arrayOfTypeCheckers.length; i++) { - var checker = arrayOfTypeCheckers[i]; - if (typeof checker !== 'function') { - warning( - false, - 'Invalid argument supplid to oneOfType. Expected an array of check functions, but ' + - 'received %s at index %s.', - getPostfixForTypeWarning(checker), - i - ); - return emptyFunction.thatReturnsNull; - } - } +var _classnames2 = _interopRequireDefault(_classnames); - function validate(props, propName, componentName, location, propFullName) { - for (var i = 0; i < arrayOfTypeCheckers.length; i++) { - var checker = arrayOfTypeCheckers[i]; - if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) { - return null; - } - } +var _reactCopyToClipboard = __webpack_require__(354); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.')); - } - return createChainableTypeChecker(validate); - } +var _reactCopyToClipboard2 = _interopRequireDefault(_reactCopyToClipboard); - function createNodeChecker() { - function validate(props, propName, componentName, location, propFullName) { - if (!isNode(props[propName])) { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.')); - } - return null; - } - return createChainableTypeChecker(validate); - } +var _reactTable = __webpack_require__(358); - function createShapeTypeChecker(shapeTypes) { - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== 'object') { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.')); - } - for (var key in shapeTypes) { - var checker = shapeTypes[key]; - if (!checker) { - continue; - } - var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); - if (error) { - return error; - } - } - return null; - } - return createChainableTypeChecker(validate); - } +var _reactTable2 = _interopRequireDefault(_reactTable); - function isNode(propValue) { - switch (typeof propValue) { - case 'number': - case 'string': - case 'undefined': - return true; - case 'boolean': - return !propValue; - case 'object': - if (Array.isArray(propValue)) { - return propValue.every(isNode); - } - if (propValue === null || isValidElement(propValue)) { - return true; - } +var _zencashjs = __webpack_require__(160); - var iteratorFn = getIteratorFn(propValue); - if (iteratorFn) { - var iterator = iteratorFn.call(propValue); - var step; - if (iteratorFn !== propValue.entries) { - while (!(step = iterator.next()).done) { - if (!isNode(step.value)) { - return false; - } - } - } else { - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - if (!isNode(entry[1])) { - return false; - } - } - } - } - } else { - return false; - } +var _zencashjs2 = _interopRequireDefault(_zencashjs); - return true; - default: - return false; - } - } +var _utils = __webpack_require__(462); - function isSymbol(propType, propValue) { - // Native Symbol. - if (propType === 'symbol') { - return true; - } +var _utils2 = _interopRequireDefault(_utils); - // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol' - if (propValue['@@toStringTag'] === 'Symbol') { - return true; - } +var _hdwallet = __webpack_require__(464); - // Fallback for non-spec compliant Symbols which are polyfilled. - if (typeof Symbol === 'function' && propValue instanceof Symbol) { - return true; - } +var _hdwallet2 = _interopRequireDefault(_hdwallet); - return false; - } +var _fileSaver = __webpack_require__(497); - // Equivalent of `typeof` but with special handling for array and regexp. - function getPropType(propValue) { - var propType = typeof propValue; - if (Array.isArray(propValue)) { - return 'array'; - } - if (propValue instanceof RegExp) { - // Old webkits (at least until Android 4.0) return 'function' rather than - // 'object' for typeof a RegExp. We'll normalize this here so that /bla/ - // passes PropTypes.object. - return 'object'; - } - if (isSymbol(propType, propValue)) { - return 'symbol'; - } - return propType; - } +var _fileSaver2 = _interopRequireDefault(_fileSaver); - // This handles more types than `getPropType`. Only used for error messages. - // See `createPrimitiveTypeChecker`. - function getPreciseType(propValue) { - if (typeof propValue === 'undefined' || propValue === null) { - return '' + propValue; - } - var propType = getPropType(propValue); - if (propType === 'object') { - if (propValue instanceof Date) { - return 'date'; - } else if (propValue instanceof RegExp) { - return 'regexp'; - } - } - return propType; - } +var _refresh = __webpack_require__(500); - // Returns a string that is postfixed to a warning about an invalid type. - // For example, "undefined" or "of type array" - function getPostfixForTypeWarning(value) { - var type = getPreciseType(value); - switch (type) { - case 'array': - case 'object': - return 'an ' + type; - case 'boolean': - case 'date': - case 'regexp': - return 'a ' + type; - default: - return type; - } - } +var _refresh2 = _interopRequireDefault(_refresh); - // Returns class name of the object, if any. - function getClassName(propValue) { - if (!propValue.constructor || !propValue.constructor.name) { - return ANONYMOUS; - } - return propValue.constructor.name; - } +var _contentCopy = __webpack_require__(501); - ReactPropTypes.checkPropTypes = checkPropTypes; - ReactPropTypes.PropTypes = ReactPropTypes; +var _contentCopy2 = _interopRequireDefault(_contentCopy); - return ReactPropTypes; -}; +var _settings2 = __webpack_require__(502); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var _settings3 = _interopRequireDefault(_settings2); -/***/ }), -/* 81 */ -/***/ (function(module, exports, __webpack_require__) { +var _repeat = __webpack_require__(503); -"use strict"; -/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var _repeat2 = _interopRequireDefault(_repeat); +var _unlockAlt = __webpack_require__(504); +var _unlockAlt2 = _interopRequireDefault(_unlockAlt); -var ReactDOMComponentFlags = { - hasCachedChildNodes: 1 << 0 -}; +var _eyeSlash = __webpack_require__(505); -module.exports = ReactDOMComponentFlags; +var _eyeSlash2 = _interopRequireDefault(_eyeSlash); -/***/ }), -/* 82 */ -/***/ (function(module, exports, __webpack_require__) { +var _eye = __webpack_require__(506); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var _eye2 = _interopRequireDefault(_eye); +var _package = __webpack_require__(507); +var _package2 = _interopRequireDefault(_package); -var _prodInvariant = __webpack_require__(3); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -var invariant = __webpack_require__(1); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -/** - * Accumulates items that must not be null or undefined into the first one. This - * is used to conserve memory by avoiding array allocations, and thus sacrifices - * API cleanness. Since `current` can be null before being passed in and not - * null after this function, make sure to assign it back to `current`: - * - * `a = accumulateInto(a, b);` - * - * This API should be sparingly used. Try `accumulate` for something cleaner. - * - * @return {*|array<*>} An accumulation of items. - */ +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } -function accumulateInto(current, next) { - !(next != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'accumulateInto(...): Accumulated items must not be null or undefined.') : _prodInvariant('30') : void 0; +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - if (current == null) { - return next; +// Throttled GET request to prevent unusable lag +var throttledAxiosGet = _utils2.default.promiseDebounce(_axios2.default.get, 1000, 5); + +// Unlock wallet enum +var UNLOCK_WALLET_TYPE = { + IMPORT_WALLET: 0, + HD_WALLET: 1, + PASTE_PRIV_KEY: 2 + + // Components +}; +var ToolTipButton = function (_React$Component) { + _inherits(ToolTipButton, _React$Component); + + function ToolTipButton(props) { + _classCallCheck(this, ToolTipButton); + + var _this = _possibleConstructorReturn(this, (ToolTipButton.__proto__ || Object.getPrototypeOf(ToolTipButton)).call(this, props)); + + _this.toggle = _this.toggle.bind(_this); + _this.state = { + tooltipOpen: false + }; + return _this; } - // Both are not empty. Warning: Never call x.concat(y) when you are not - // certain that x is an Array (x could be a string with concat method). - if (Array.isArray(current)) { - if (Array.isArray(next)) { - current.push.apply(current, next); - return current; + _createClass(ToolTipButton, [{ + key: 'toggle', + value: function toggle() { + this.setState({ + tooltipOpen: !this.state.tooltipOpen + }); } - current.push(next); - return current; - } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + 'span', + null, + _react2.default.createElement( + _reactstrap.Button, + { disabled: this.props.disabled, onClick: this.props.onClick, className: 'mr-1', color: 'secondary', id: 'Tooltip-' + this.props.id }, + this.props.buttonText + ), + _react2.default.createElement( + _reactstrap.Tooltip, + { placement: 'top', isOpen: this.state.tooltipOpen, target: 'Tooltip-' + this.props.id, toggle: this.toggle }, + this.props.tooltipText + ) + ); + } + }]); - if (Array.isArray(next)) { - // A bit too dangerous to mutate `next`. - return [current].concat(next); + return ToolTipButton; +}(_react2.default.Component); + +var ZWalletGenerator = function (_React$Component2) { + _inherits(ZWalletGenerator, _React$Component2); + + function ZWalletGenerator(props) { + _classCallCheck(this, ZWalletGenerator); + + var _this2 = _possibleConstructorReturn(this, (ZWalletGenerator.__proto__ || Object.getPrototypeOf(ZWalletGenerator)).call(this, props)); + + _this2.handlePasswordPhrase = _this2.handlePasswordPhrase.bind(_this2); + _this2.state = { + passwordPhrase: '', + privateKey: '' + }; + return _this2; } - return [current, next]; -} + _createClass(ZWalletGenerator, [{ + key: 'handlePasswordPhrase', + value: function handlePasswordPhrase(e) { + // What wif format do we use? + var wifHash = this.props.settings.useTestNet ? _zencashjs2.default.config.testnet.wif : _zencashjs2.default.config.mainnet.wif; -module.exports = accumulateInto; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var pk = _zencashjs2.default.address.mkPrivKey(e.target.value); + var pkwif = _zencashjs2.default.address.privKeyToWIF(pk, true, wifHash); -/***/ }), -/* 83 */ -/***/ (function(module, exports, __webpack_require__) { + if (e.target.value === '') { + pkwif = ''; + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + this.setState({ + privateKey: pkwif + }); + } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + 'h3', + { className: 'display-6' }, + 'Generate New Address' + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement(_reactstrap.Input, { onChange: this.handlePasswordPhrase, placeholder: 'Password phrase. Do NOT forget to save this! Use >15 words to be safe.' }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement(_reactstrap.Input, { value: this.state.privateKey, placeholder: 'Private key generated from password phrase' }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement( + _reactCopyToClipboard2.default, + { text: this.state.privateKey }, + _react2.default.createElement( + _reactstrap.Button, + null, + _react2.default.createElement(_contentCopy2.default, null) + ) + ) + ) + ) + ); + } + }]); + return ZWalletGenerator; +}(_react2.default.Component); +var ZWalletUnlockKey = function (_React$Component3) { + _inherits(ZWalletUnlockKey, _React$Component3); -/** - * @param {array} arr an "accumulation" of items which is either an Array or - * a single item. Useful when paired with the `accumulate` module. This is a - * simple utility that allows us to reason about a collection of items, but - * handling the case when there is exactly one item (and we do not need to - * allocate an array). - */ + function ZWalletUnlockKey(props) { + _classCallCheck(this, ZWalletUnlockKey); -function forEachAccumulated(arr, cb, scope) { - if (Array.isArray(arr)) { - arr.forEach(cb, scope); - } else if (arr) { - cb.call(scope, arr); - } -} + var _this3 = _possibleConstructorReturn(this, (ZWalletUnlockKey.__proto__ || Object.getPrototypeOf(ZWalletUnlockKey)).call(this, props)); -module.exports = forEachAccumulated; + _this3.unlockHDWallet = _this3.unlockHDWallet.bind(_this3); + _this3.loadWalletDat = _this3.loadWalletDat.bind(_this3); + _this3.toggleShowPassword = _this3.toggleShowPassword.bind(_this3); + _this3.unlockPrivateKeys = _this3.unlockPrivateKeys.bind(_this3); -/***/ }), -/* 84 */ -/***/ (function(module, exports, __webpack_require__) { + _this3.state = { + showPassword: false, + secretPhrase: '', + invalidPrivateKey: false, + secretPhraseTooShort: false, -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // Style for input button + inputFileStyle: { + WebkitAppearance: 'button', + cursor: 'pointer' + } + }; + return _this3; + } + _createClass(ZWalletUnlockKey, [{ + key: 'toggleShowPassword', + value: function toggleShowPassword() { + this.setState({ + showPassword: !this.state.showPassword + }); + } + }, { + key: 'unlockPrivateKeys', + value: function unlockPrivateKeys() { + // Success = return 0 + var success = this.props.handleUnlockPrivateKeys() === 0; + if (!success) { + this.setState({ + invalidPrivateKey: true + }); + } + } + }, { + key: 'unlockHDWallet', + value: function unlockHDWallet() { + try { + // Generate private keys from secret phrase + var pk = _hdwallet2.default.phraseToHDWallet(this.state.secretPhrase); -var ExecutionEnvironment = __webpack_require__(8); + this.setState({ + secretPhraseTooShort: false + }); -var contentKey = null; + // Set private key and unlock them (we know it'll work so no need to validate) + this.props.setPrivateKeys(pk, true); + } catch (err) { + this.setState({ + secretPhraseTooShort: true + }); + } + } + }, { + key: 'loadWalletDat', + value: function loadWalletDat(e) { + var _this4 = this; -/** - * Gets the key used to access text content on a DOM node. - * - * @return {?string} Key used to access text content. - * @internal - */ -function getTextContentAccessor() { - if (!contentKey && ExecutionEnvironment.canUseDOM) { - // Prefer textContent to innerText because many browsers support both but - // SVG <text> elements don't support innerText even when <div> does. - contentKey = 'textContent' in document.documentElement ? 'textContent' : 'innerText'; - } - return contentKey; -} + var reader = new FileReader(); + var file = e.target.files[0]; + + // Read file callback function + reader.onloadend = function () { + // Get reader results in bytes + var dataHexStr = reader.result; + + // Retrieve private keys from wallet.dat + // Source: https://gist.github.com/moocowmoo/a715c80399bb202a65955771c465530c + var re = /\x30\x81\xD3\x02\x01\x01\x04\x20(.{32})/gm; + var privateKeys = dataHexStr.match(re); + privateKeys = privateKeys.map(function (x) { + x = x.replace('\x30\x81\xD3\x02\x01\x01\x04\x20', ''); + x = Buffer.from(x, 'latin1').toString('hex'); + return x; + }); -module.exports = getTextContentAccessor; + // Set private key + _this4.props.setPrivateKeys(privateKeys); -/***/ }), -/* 85 */ -/***/ (function(module, exports, __webpack_require__) { + // Unlock private key + var success = _this4.props.handleUnlockPrivateKeys() === 0; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + if (!success) { + _this4.setState({ + invalidPrivateKey: true + }); + } + }; + + // Read file + reader.readAsBinaryString(file); + } + }, { + key: 'render', + value: function render() { + var _this5 = this; + + if (this.props.unlockType == UNLOCK_WALLET_TYPE.IMPORT_WALLET) { + return _react2.default.createElement( + _reactstrap.Form, + null, + _react2.default.createElement( + _reactstrap.FormGroup, + { row: true }, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.invalidPrivateKey ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Keys in files are corrupted' + ) : '', + _react2.default.createElement( + _reactstrap.Label, + { 'for': 'walletDatFile', className: 'btn btn-block btn-secondary', style: this.state.inputFileStyle }, + 'Select wallet.dat file', + _react2.default.createElement(_reactstrap.Input, { + style: { display: 'none' }, + type: 'file', + name: 'file', + id: 'walletDatFile', + onChange: this.loadWalletDat + }) + ), + _react2.default.createElement( + _reactstrap.FormText, + { color: 'muted' }, + 'For Windows, it should be in %APPDATA%/zen', + _react2.default.createElement('br', null), + 'For Mac/Linux, it should be in ~/.zen' + ) + ) + ) + ); + } else if (this.props.unlockType == UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY) { + return _react2.default.createElement( + 'div', + null, + this.state.invalidPrivateKey ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Invalid private key' + ) : '', + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { id: 4, + onClick: this.toggleShowPassword, + buttonText: this.state.showPassword ? _react2.default.createElement(_eye2.default, null) : _react2.default.createElement(_eyeSlash2.default, null), + tooltipText: this.state.showPassword ? 'show password' : 'hide password' + }) + ), + _react2.default.createElement(_reactstrap.Input, { + type: this.state.showPassword ? "text" : "password", + onChange: function onChange(e) { + return _this5.props.setPrivateKeys([e.target.value]); + } // Set it in a list so we can map over it later + , placeholder: 'Private key' + }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { onClick: this.unlockPrivateKeys, id: 3, buttonText: _react2.default.createElement(_unlockAlt2.default, null), tooltipText: 'unlock' }) + ) + ) + ); + } else if (this.props.unlockType == UNLOCK_WALLET_TYPE.HD_WALLET) { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + _reactstrap.Alert, + { color: 'warning' }, + _react2.default.createElement( + 'strong', + null, + 'Warning.' + ), + '\xA0Make sure you have saved your secret phrase somewhere.' + ), + this.state.secretPhraseTooShort ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Secret phrase too short' + ) : '', + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { id: 7, + onClick: this.toggleShowPassword, + buttonText: this.state.showPassword ? _react2.default.createElement(_eye2.default, null) : _react2.default.createElement(_eyeSlash2.default, null), + tooltipText: this.state.showPassword ? 'show phrase' : 'hide phrase' + }) + ), + _react2.default.createElement(_reactstrap.Input, { + type: this.state.showPassword ? "text" : "password", + maxLength: '64', + onChange: function onChange(e) { + return _this5.setState({ secretPhrase: e.target.value }); + }, + placeholder: 'Secret phrase. e.g. cash cow money heros cardboard money bag late green' + }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { onClick: this.unlockHDWallet, id: 8, buttonText: _react2.default.createElement(_unlockAlt2.default, null), tooltipText: 'unlock HD wallet' }) + ) + ) + ); + } + } + }]); + return ZWalletUnlockKey; +}(_react2.default.Component); +var ZWalletSettings = function (_React$Component4) { + _inherits(ZWalletSettings, _React$Component4); -var _prodInvariant = __webpack_require__(3); + function ZWalletSettings() { + _classCallCheck(this, ZWalletSettings); -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + return _possibleConstructorReturn(this, (ZWalletSettings.__proto__ || Object.getPrototypeOf(ZWalletSettings)).apply(this, arguments)); + } -var PooledClass = __webpack_require__(20); + _createClass(ZWalletSettings, [{ + key: 'render', + value: function render() { + var _this7 = this; -var invariant = __webpack_require__(1); + return _react2.default.createElement( + _reactstrap.Modal, + { isOpen: this.props.settings.showSettings, toggle: this.props.toggleModalSettings }, + _react2.default.createElement( + _reactstrap.ModalHeader, + { toggle: this.props.toggleShowSettings }, + 'ZenCash Wallet Settings' + ), + _react2.default.createElement( + _reactstrap.ModalBody, + null, + _react2.default.createElement(ZWalletSelectUnlockType, { + setUnlockType: this.props.setUnlockType, + unlockType: this.props.settings.unlockType + }) + ), + _react2.default.createElement( + _reactstrap.ModalBody, + null, + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Insight API' + ), + _react2.default.createElement(_reactstrap.Input, { + value: this.props.settings.insightAPI, + onChange: function onChange(e) { + return _this7.props.setInsightAPI(e.target.value); + } + }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + { sm: '6' }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { + disabled: !(this.props.publicAddresses === null), + defaultChecked: this.props.settings.compressPubKey, type: 'checkbox', + onChange: this.props.toggleCompressPubKey + }), + ' ', + 'Compress Public Key' + ) + ), + _react2.default.createElement( + _reactstrap.Col, + { sm: '6' }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { + defaultChecked: this.props.settings.showWalletGen, type: 'checkbox', + onChange: this.props.toggleShowWalletGen + }), + ' ', + 'Show Address Generator' + ) + ) + ) + ), + _react2.default.createElement( + _reactstrap.ModalFooter, + null, + _react2.default.createElement( + _reactstrap.Label, + null, + _react2.default.createElement(_reactstrap.Input, { + disabled: !(this.props.publicAddresses === null), + defaultChecked: this.props.settings.useTestNet, type: 'checkbox', + onChange: this.props.toggleUseTestNet + }), + ' ', + 'testnet' + ) + ) + ); + } + }]); -/** - * A specialized pseudo-event module to help keep track of components waiting to - * be notified when their DOM representations are available for use. - * - * This implements `PooledClass`, so you should never need to instantiate this. - * Instead, use `CallbackQueue.getPooled()`. - * - * @class ReactMountReady - * @implements PooledClass - * @internal - */ + return ZWalletSettings; +}(_react2.default.Component); -var CallbackQueue = function () { - function CallbackQueue(arg) { - _classCallCheck(this, CallbackQueue); +var ZAddressInfo = function (_React$Component5) { + _inherits(ZAddressInfo, _React$Component5); - this._callbacks = null; - this._contexts = null; - this._arg = arg; - } + function ZAddressInfo(props) { + _classCallCheck(this, ZAddressInfo); - /** - * Enqueues a callback to be invoked when `notifyAll` is invoked. - * - * @param {function} callback Invoked when `notifyAll` is invoked. - * @param {?object} context Context to call `callback` with. - * @internal - */ + var _this8 = _possibleConstructorReturn(this, (ZAddressInfo.__proto__ || Object.getPrototypeOf(ZAddressInfo)).call(this, props)); + _this8.updateAddressInfo = _this8.updateAddressInfo.bind(_this8); + _this8.updateAddressesInfo = _this8.updateAddressesInfo.bind(_this8); + _this8.getAddressBlockExplorerURL = _this8.getAddressBlockExplorerURL.bind(_this8); - CallbackQueue.prototype.enqueue = function enqueue(callback, context) { - this._callbacks = this._callbacks || []; - this._callbacks.push(callback); - this._contexts = this._contexts || []; - this._contexts.push(context); - }; + _this8.state = { + retrieveAddressError: false + }; + return _this8; + } - /** - * Invokes all enqueued callbacks and clears the queue. This is invoked after - * the DOM representation of a component has been created or updated. - * - * @internal - */ + // Updates all address info - CallbackQueue.prototype.notifyAll = function notifyAll() { - var callbacks = this._callbacks; - var contexts = this._contexts; - var arg = this._arg; - if (callbacks && contexts) { - !(callbacks.length === contexts.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Mismatched list of contexts in callback queue') : _prodInvariant('24') : void 0; - this._callbacks = null; - this._contexts = null; - for (var i = 0; i < callbacks.length; i++) { - callbacks[i].call(contexts[i], arg); - } - callbacks.length = 0; - contexts.length = 0; + _createClass(ZAddressInfo, [{ + key: 'updateAddressesInfo', + value: function updateAddressesInfo() { + // The key is the address + // Value is the private key + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + this.updateAddressInfo(key); + } + }.bind(this)); } - }; - CallbackQueue.prototype.checkpoint = function checkpoint() { - return this._callbacks ? this._callbacks.length : 0; - }; + // Gets the blockchain explorer URL for an address - CallbackQueue.prototype.rollback = function rollback(len) { - if (this._callbacks && this._contexts) { - this._callbacks.length = len; - this._contexts.length = len; + }, { + key: 'getAddressBlockExplorerURL', + value: function getAddressBlockExplorerURL(address) { + return _utils2.default.urlAppend(this.props.settings.explorerURL, 'address/') + address; } - }; - - /** - * Resets the internal queue. - * - * @internal - */ + // Updates a address info - CallbackQueue.prototype.reset = function reset() { - this._callbacks = null; - this._contexts = null; - }; + }, { + key: 'updateAddressInfo', + value: function updateAddressInfo(address) { + // GET request to URL + var info_url = _utils2.default.urlAppend(this.props.settings.insightAPI, 'addr/'); + info_url = _utils2.default.urlAppend(info_url, address + '?noTxList=1'); - /** - * `PooledClass` looks for this. - */ + throttledAxiosGet(info_url).then(function (response) { + var data = response.data; + this.props.setPublicAddressesKeyValue(address, 'confirmedBalance', data.balance); + this.props.setPublicAddressesKeyValue(address, 'unconfirmedBalance', data.unconfirmedBalance); + this.setState({ + retrieveAddressError: false + }); + }.bind(this)).catch(function (error) { + this.setState({ + retrieveAddressError: true + }); + }.bind(this)); + } + }, { + key: 'componentDidMount', + value: function componentDidMount() { + // Run immediately + this.updateAddressesInfo(); - CallbackQueue.prototype.destructor = function destructor() { - this.reset(); - }; + // Update every 30 seconds + this.interval = setInterval(this.updateAddressesInfo, 300000); + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + clearInterval(this.interval); + } + }, { + key: 'render', + value: function render() { + var _this9 = this; + + // Key is the address + var addresses = []; + var totalConfirmed = 0.0; + var totalUnconfirmed = 0.0; + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + // Add to address + addresses.push({ + address: key, + privateKeyWIF: this.props.publicAddresses[key].privateKeyWIF, + confirmedBalance: this.props.publicAddresses[key].confirmedBalance, + unconfirmedBalance: this.props.publicAddresses[key].unconfirmedBalance + }); - return CallbackQueue; -}(); + var c_confirmed = Number(this.props.publicAddresses[key].confirmedBalance); + var c_unconfirmed = Number(this.props.publicAddresses[key].unconfirmedBalance); + if (!isNaN(c_confirmed)) { + totalConfirmed += c_confirmed; + } -module.exports = PooledClass.addPoolingTo(CallbackQueue); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + if (!isNaN(c_unconfirmed)) { + totalUnconfirmed += c_unconfirmed; + } + } + }.bind(this)); + + var addressColumns = [{ + Header: 'Address', + accessor: 'address', + resizable: true, + Cell: function Cell(props) { + return _react2.default.createElement( + 'a', + { href: _this9.getAddressBlockExplorerURL(props.value) }, + props.value + ); + } + }, { + Header: 'Confirmed', + accessor: 'confirmedBalance', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }, { + Header: 'Unconfirmed', + accessor: 'unconfirmedBalance', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }]; -/***/ }), -/* 86 */ -/***/ (function(module, exports, __webpack_require__) { + return _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + this.state.retrieveAddressError ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + 'Error connecting to the Insight API. Double check the Insight API supplied in settings.' + ) : _react2.default.createElement( + _reactstrap.Alert, + { color: 'warning' }, + 'The balance displayed here is dependent on the insight node.', + _react2.default.createElement('br', null), + 'Automatically updates every 5 minutes. Alternatively, you can ', + _react2.default.createElement( + 'a', + { href: '#', onClick: function onClick() { + return _this9.updateAddressesInfo(); + } }, + 'forcefully refresh' + ), + ' them.' + ) + ) + ), + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement(_reactTable2.default, { + columns: [{ + Header: 'Total Confirmed', + accessor: 'totalConfirmed', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }, { + Header: 'Total Unconfirmed', + accessor: 'totalUnconfirmed', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }], + + data: [{ + totalConfirmed: totalConfirmed, + totalUnconfirmed: totalUnconfirmed + }], + + showPagination: false, + + minRows: 1 + }) + ) + ), + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement(_reactTable2.default, { + data: addresses, columns: addressColumns, + minRows: addresses.length > 20 ? 20 : addresses.length, + showPagination: addresses.length > 20 + }) + ) + ) + ) + ); + } + }]); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + return ZAddressInfo; +}(_react2.default.Component); +var ZSendZEN = function (_React$Component6) { + _inherits(ZSendZEN, _React$Component6); + + function ZSendZEN(props) { + _classCallCheck(this, ZSendZEN); + + var _this10 = _possibleConstructorReturn(this, (ZSendZEN.__proto__ || Object.getPrototypeOf(ZSendZEN)).call(this, props)); + + _this10.setProgressValue = _this10.setProgressValue.bind(_this10); + _this10.setSendErrorMessage = _this10.setSendErrorMessage.bind(_this10); + _this10.handleUpdateSelectedAddress = _this10.handleUpdateSelectedAddress.bind(_this10); + _this10.handleUpdateRecipientAddress = _this10.handleUpdateRecipientAddress.bind(_this10); + _this10.handleUpdateAmount = _this10.handleUpdateAmount.bind(_this10); + _this10.handleCheckChanged = _this10.handleCheckChanged.bind(_this10); + _this10.handleUpdateFee = _this10.handleUpdateFee.bind(_this10); + _this10.handleSendZEN = _this10.handleSendZEN.bind(_this10); + + _this10.state = { + selectedAddress: '', // which address did we select + recipientAddress: '', + fee: '', + amount: '', + sentTxid: '', // Whats the send txid + sendProgress: 0, // Progress bar, 100 to indicate complete + sendErrorMessage: '', + confirmSend: false + }; + return _this10; + } + _createClass(ZSendZEN, [{ + key: 'handleUpdateSelectedAddress', + value: function handleUpdateSelectedAddress(e) { + this.setState({ + selectedAddress: e.target.value + }); + } + }, { + key: 'handleUpdateRecipientAddress', + value: function handleUpdateRecipientAddress(e) { + this.setState({ + recipientAddress: e.target.value + }); + } + }, { + key: 'handleUpdateFee', + value: function handleUpdateFee(e) { + this.setState({ + fee: e.target.value + }); + } + }, { + key: 'handleUpdateAmount', + value: function handleUpdateAmount(e) { + this.setState({ + amount: e.target.value + }); + } + }, { + key: 'handleCheckChanged', + value: function handleCheckChanged(e) { + this.setState({ + confirmSend: e.target.checked + }); + } + }, { + key: 'setProgressValue', + value: function setProgressValue(v) { + this.setState({ + sendProgress: v + }); + } + }, { + key: 'setSendErrorMessage', + value: function setSendErrorMessage(msg) { + this.setState({ + sendErrorMessage: msg + }); + } + }, { + key: 'handleSendZEN', + value: function handleSendZEN() { + var value = this.state.amount; + var fee = this.state.fee; + var recipientAddress = this.state.recipientAddress; + var senderAddress = this.state.selectedAddress; + + // Convert how much we wanna send + // to satoshis + var satoshisToSend = Math.round(value * 100000000); + var satoshisfeesToSend = Math.round(fee * 100000000); + + // Reset zen send progress and error message + this.setProgressValue(1); + this.setSendErrorMessage(''); + + // Error strings + var errString = ''; + + // Validation + if (senderAddress === '') { + errString += '`From Address` field can\'t be empty.;'; + } -var ReactFeatureFlags = { - // When true, call console.time() before and .timeEnd() after each top-level - // render (both initial renders and updates). Useful when looking at prod-mode - // timeline profiles in Chrome, for example. - logTopLevelRenders: false -}; + if (recipientAddress.length !== 35) { + errString += 'Invalid address. Only transparent addresses are supported at this point in time.;'; + } -module.exports = ReactFeatureFlags; + if (typeof parseInt(value) !== 'number' || value === '') { + errString += 'Invalid amount.;'; + } -/***/ }), -/* 87 */ -/***/ (function(module, exports, __webpack_require__) { + // Can't send 0 satoshis + if (satoshisToSend <= 0) { + errString += 'Amount must be greater than 0.;'; + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + if (typeof parseInt(fee) !== 'number' || fee === '') { + errString += 'Invalid fee.;'; + } + if (errString !== '') { + this.setSendErrorMessage(errString); + this.setProgressValue(0); + return; + } + // Private key + var senderPrivateKey = this.props.publicAddresses[senderAddress].privateKey; -var ReactDOMComponentTree = __webpack_require__(6); + // Get previous transactions + var prevTxURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'addr/') + senderAddress + '/utxo'; + var infoURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'status?q=getInfo'); + var sendRawTxURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'tx/send'); -function isCheckable(elem) { - var type = elem.type; - var nodeName = elem.nodeName; - return nodeName && nodeName.toLowerCase() === 'input' && (type === 'checkbox' || type === 'radio'); -} + // Building our transaction TXOBJ + // How many satoshis do we have so far + var satoshisSoFar = 0; + var history = []; + var recipients = [{ address: recipientAddress, satoshis: satoshisToSend }]; -function getTracker(inst) { - return inst._wrapperState.valueTracker; -} + // Get transactions and info + _axios2.default.get(prevTxURL).then(function (tx_resp) { + this.setProgressValue(25); -function attachTracker(inst, tracker) { - inst._wrapperState.valueTracker = tracker; -} + var tx_data = tx_resp.data; -function detachTracker(inst) { - delete inst._wrapperState.valueTracker; -} + _axios2.default.get(infoURL).then(function (info_resp) { + this.setProgressValue(50); + var info_data = info_resp.data; -function getValueFromNode(node) { - var value; - if (node) { - value = isCheckable(node) ? '' + node.checked : node.value; - } - return value; -} + var blockHeight = info_data.info.blocks - 300; + var blockHashURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'block-index/') + blockHeight; -var inputValueTracking = { - // exposed for testing - _getTrackerFromNode: function (node) { - return getTracker(ReactDOMComponentTree.getInstanceFromNode(node)); - }, + // Get block hash + _axios2.default.get(blockHashURL).then(function (response_bhash) { + this.setProgressValue(75); + var blockHash = response_bhash.data.blockHash; - track: function (inst) { - if (getTracker(inst)) { - return; - } + // Iterate through each utxo + // append it to history + for (var i = 0; i < tx_data.length; i++) { + if (tx_data[i].confirmations == 0) { + continue; + } - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var valueField = isCheckable(node) ? 'checked' : 'value'; - var descriptor = Object.getOwnPropertyDescriptor(node.constructor.prototype, valueField); + history = history.concat({ + txid: tx_data[i].txid, + vout: tx_data[i].vout, + scriptPubKey: tx_data[i].scriptPubKey + }); - var currentValue = '' + node[valueField]; + // How many satoshis do we have so far + satoshisSoFar = satoshisSoFar + tx_data[i].satoshis; + if (satoshisSoFar >= satoshisToSend + satoshisfeesToSend) { + break; + } + } - // if someone has already defined a value or Safari, then bail - // and don't track value will cause over reporting of changes, - // but it's better then a hard failure - // (needed for certain tests that spyOn input values and Safari) - if (node.hasOwnProperty(valueField) || typeof descriptor.get !== 'function' || typeof descriptor.set !== 'function') { - return; - } + // If we don't have enough address + // fail and tell user + if (satoshisSoFar < satoshisToSend + satoshisfeesToSend) { + this.setSendErrorMessage('Not enough confirmed ZEN in account to perform transaction'); + this.setProgressValue(0); + } - Object.defineProperty(node, valueField, { - enumerable: descriptor.enumerable, - configurable: true, - get: function () { - return descriptor.get.call(this); - }, - set: function (value) { - currentValue = '' + value; - descriptor.set.call(this, value); - } - }); + // If we don't have exact amount + // Refund remaining to current address + if (satoshisSoFar !== satoshisToSend + satoshisfeesToSend) { + var refundSatoshis = satoshisSoFar - satoshisToSend - satoshisfeesToSend; + recipients = recipients.concat({ address: senderAddress, satoshis: refundSatoshis }); + } - attachTracker(inst, { - getValue: function () { - return currentValue; - }, - setValue: function (value) { - currentValue = '' + value; - }, - stopTracking: function () { - detachTracker(inst); - delete node[valueField]; - } - }); - }, + // Create transaction + var txObj = _zencashjs2.default.transaction.createRawTx(history, recipients, blockHeight, blockHash); - updateValueIfChanged: function (inst) { - if (!inst) { - return false; - } - var tracker = getTracker(inst); + // Sign each history transcation + for (var i = 0; i < history.length; i++) { + txObj = _zencashjs2.default.transaction.signTx(txObj, i, senderPrivateKey, this.props.settings.compressPubKey); + } - if (!tracker) { - inputValueTracking.track(inst); - return true; + // Convert it to hex string + var txHexString = _zencashjs2.default.transaction.serializeTx(txObj); + + _axios2.default.post(sendRawTxURL, { rawtx: txHexString }).then(function (sendtx_resp) { + this.setState({ + sendProgress: 100, + sentTxid: sendtx_resp.data.txid + }); + }.bind(this)).catch(function (error) { + this.setSendErrorMessage(error + ''); + this.setProgressValue(0); + return; + }.bind(this)); + }.bind(this)); + }.bind(this)); + }.bind(this)).catch(function (error) { + this.setSendErrorMessage(error); + this.setProgressValue(0); + return; + }.bind(this)); } + }, { + key: 'render', + value: function render() { + // If send was successful + var zenTxLink; + if (this.state.sendProgress === 100) { + var zentx = _utils2.default.urlAppend(this.props.settings.explorerURL, 'tx/') + this.state.sentTxid; + zenTxLink = _react2.default.createElement( + _reactstrap.Alert, + { color: 'success' }, + _react2.default.createElement( + 'strong', + null, + 'ZEN successfully sent!' + ), + ' ', + _react2.default.createElement( + 'a', + { href: zentx }, + 'Click here to view your transaction' + ) + ); + } - var lastValue = tracker.getValue(); - var nextValue = getValueFromNode(ReactDOMComponentTree.getNodeFromInstance(inst)); + // Else show error why + else if (this.state.sendErrorMessage !== '') { + zenTxLink = this.state.sendErrorMessage.split(';').map(function (s) { + if (s !== '') { + return _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + ' ', + s + ); + } + }); + } - if (nextValue !== lastValue) { - tracker.setValue(nextValue); - return true; - } + // Send addresses + // Key is the address btw + var sendAddresses = []; + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + sendAddresses.push(_react2.default.createElement( + 'option', + { value: key }, + '[', + this.props.publicAddresses[key].confirmedBalance, + '] - ', + key + )); + } + }.bind(this)); - return false; - }, - stopTracking: function (inst) { - var tracker = getTracker(inst); - if (tracker) { - tracker.stopTracking(); + return _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + 'ALWAYS VALIDATE YOUR DESINATION ADDRESS BY SENDING SMALL AMOUNTS OF ZEN FIRST' + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'From Address' + ), + _react2.default.createElement( + _reactstrap.Input, + { type: 'select', onChange: this.handleUpdateSelectedAddress }, + _react2.default.createElement('option', { value: '' }), + sendAddresses + ) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'To Address' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateRecipientAddress, placeholder: 'e.g znSDvF9nA5VCdse5HbEKmsoNbjCbsEA3VAH' }) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Amount' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateAmount, placeholder: 'e.g 42' }) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Fee' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateFee, placeholder: 'e.g 0.001' }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.FormGroup, + { check: true }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleCheckChanged, type: 'checkbox' }), + ' ', + 'Yes, I would like to send these ZEN' + ) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.Button, + { + color: 'warning', className: 'btn-block', + disabled: !this.state.confirmSend || this.state.sendProgress > 0 && this.state.sendProgress < 100, + onClick: this.handleSendZEN + }, + 'Send' + ) + ), + _react2.default.createElement( + _reactstrap.CardFooter, + null, + zenTxLink, + _react2.default.createElement(_reactstrap.Progress, { value: this.state.sendProgress }) + ) + ) + ) + ); } - } -}; - -module.exports = inputValueTracking; - -/***/ }), -/* 88 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ - - + }]); -/** - * @see http://www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#input-type-attr-summary - */ + return ZSendZEN; +}(_react2.default.Component); -var supportedInputTypes = { - color: true, - date: true, - datetime: true, - 'datetime-local': true, - email: true, - month: true, - number: true, - password: true, - range: true, - search: true, - tel: true, - text: true, - time: true, - url: true, - week: true -}; +var ZWalletSelectUnlockType = function (_React$Component7) { + _inherits(ZWalletSelectUnlockType, _React$Component7); -function isTextInputElement(elem) { - var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); + function ZWalletSelectUnlockType(props) { + _classCallCheck(this, ZWalletSelectUnlockType); - if (nodeName === 'input') { - return !!supportedInputTypes[elem.type]; - } + var _this11 = _possibleConstructorReturn(this, (ZWalletSelectUnlockType.__proto__ || Object.getPrototypeOf(ZWalletSelectUnlockType)).call(this, props)); - if (nodeName === 'textarea') { - return true; + _this11.state = { cSelected: _this11.props.unlockType }; + return _this11; } - return false; -} - -module.exports = isTextInputElement; + _createClass(ZWalletSelectUnlockType, [{ + key: 'onRadioBtnClick', + value: function onRadioBtnClick(s) { + this.setState({ + cSelected: s + }); -/***/ }), -/* 89 */ -/***/ (function(module, exports, __webpack_require__) { + this.props.setUnlockType(s); + } + }, { + key: 'render', + value: function render() { + var _this12 = this; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return _react2.default.createElement( + 'div', + { style: { textAlign: 'center' } }, + _react2.default.createElement( + _reactstrap.ButtonGroup, + { vertical: true }, + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.HD_WALLET); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.HD_WALLET }, + 'Enter secret phrase' + ), + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.IMPORT_WALLET); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.IMPORT_WALLET }, + 'Load wallet.dat' + ), + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY }, + 'Paste private key' + ) + ) + ); + } + }]); + return ZWalletSelectUnlockType; +}(_react2.default.Component); +var ZWalletTabs = function (_React$Component8) { + _inherits(ZWalletTabs, _React$Component8); -var ViewportMetrics = { - currentScrollLeft: 0, + function ZWalletTabs(props) { + _classCallCheck(this, ZWalletTabs); - currentScrollTop: 0, + var _this13 = _possibleConstructorReturn(this, (ZWalletTabs.__proto__ || Object.getPrototypeOf(ZWalletTabs)).call(this, props)); - refreshScrollValues: function (scrollPosition) { - ViewportMetrics.currentScrollLeft = scrollPosition.x; - ViewportMetrics.currentScrollTop = scrollPosition.y; + _this13.toggleTabs = _this13.toggleTabs.bind(_this13); + _this13.savePrivateKeys = _this13.savePrivateKeys.bind(_this13); + _this13.state = { + activeTab: '1' + }; + return _this13; } -}; - -module.exports = ViewportMetrics; - -/***/ }), -/* 90 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + _createClass(ZWalletTabs, [{ + key: 'toggleTabs', + value: function toggleTabs(tab) { + if (this.state.activeTab !== tab) { + this.setState({ + activeTab: tab + }); + } + } + }, { + key: 'savePrivateKeys', + value: function savePrivateKeys() { + // ISO 8601 + var now = new Date(); + now = now.toISOString().split('.')[0] + 'Z'; + var fileStr = '# Wallet dump created by myzenwallet ' + _package2.default.version + '\n'; + fileStr += '# Created on ' + now + '\n\n\n'; -var ExecutionEnvironment = __webpack_require__(8); -var escapeTextContentForBrowser = __webpack_require__(44); -var setInnerHTML = __webpack_require__(43); + Object.keys(this.props.publicAddresses).forEach(function (key) { + fileStr += this.props.publicAddresses[key].privateKeyWIF; + fileStr += ' ' + now + ' ' + 'label=' + ' ' + '# addr=' + key; + fileStr += '\n'; + }.bind(this)); -/** - * Set the textContent property of a node, ensuring that whitespace is preserved - * even in IE8. innerText is a poor substitute for textContent and, among many - * issues, inserts <br> instead of the literal newline chars. innerHTML behaves - * as it should. - * - * @param {DOMElement} node - * @param {string} text - * @internal - */ -var setTextContent = function (node, text) { - if (text) { - var firstChild = node.firstChild; + var pkBlob = new Blob([fileStr], { type: 'text/plain;charset=utf-8' }); + _fileSaver2.default.saveAs(pkBlob, now + '_myzenwallet_private_keys.txt'); + } + }, { + key: 'render', + value: function render() { + var _this14 = this; - if (firstChild && firstChild === node.lastChild && firstChild.nodeType === 3) { - firstChild.nodeValue = text; - return; + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + _reactstrap.Nav, + { tabs: true }, + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '1' }), + onClick: function onClick() { + _this14.toggleTabs('1'); + } + }, + 'Info' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '2' }), + onClick: function onClick() { + _this14.toggleTabs('2'); + } + }, + 'Send ZEN' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '3' }), + onClick: function onClick() { + _this14.toggleTabs('3'); + } + }, + 'Export' + ) + ) + ), + _react2.default.createElement( + _reactstrap.TabContent, + { activeTab: this.state.activeTab }, + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '1' }, + _react2.default.createElement(ZAddressInfo, { + publicAddresses: this.props.publicAddresses, + settings: this.props.settings, + setPublicAddressesKeyValue: this.props.setPublicAddressesKeyValue + }) + ), + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '2' }, + _react2.default.createElement(ZSendZEN, { + settings: this.props.settings, + publicAddresses: this.props.publicAddresses + }) + ), + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '3' }, + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement( + _reactstrap.Button, + { + color: 'secondary', className: 'btn-block', + onClick: this.savePrivateKeys + }, + 'Download Private Keys' + ) + ) + ) + ) + ) + ) + ) + ); } - } - node.textContent = text; -}; + }]); -if (ExecutionEnvironment.canUseDOM) { - if (!('textContent' in document.documentElement)) { - setTextContent = function (node, text) { - if (node.nodeType === 3) { - node.nodeValue = text; - return; + return ZWalletTabs; +}(_react2.default.Component); + +var ZWallet = function (_React$Component9) { + _inherits(ZWallet, _React$Component9); + + function ZWallet(props) { + _classCallCheck(this, ZWallet); + + var _this15 = _possibleConstructorReturn(this, (ZWallet.__proto__ || Object.getPrototypeOf(ZWallet)).call(this, props)); + + _this15.resetKeys = _this15.resetKeys.bind(_this15); + _this15.handleUnlockPrivateKeys = _this15.handleUnlockPrivateKeys.bind(_this15); + _this15.setPrivateKeys = _this15.setPrivateKeys.bind(_this15); + _this15.setInsightAPI = _this15.setInsightAPI.bind(_this15); + _this15.setUnlockType = _this15.setUnlockType.bind(_this15); + _this15.setPublicAddressesKeyValue = _this15.setPublicAddressesKeyValue.bind(_this15); + _this15.toggleUseTestNet = _this15.toggleUseTestNet.bind(_this15); + _this15.toggleCompressPubKey = _this15.toggleCompressPubKey.bind(_this15); + _this15.toggleShowSettings = _this15.toggleShowSettings.bind(_this15); + _this15.toggleShowWalletGen = _this15.toggleShowWalletGen.bind(_this15); + + _this15.state = { + privateKeys: '', + publicAddresses: null, // Public address will be {address: {privateKey: '', transactionURL: '', privateKeyWIF: ''} + settings: { + showSettings: false, + showWalletGen: false, + compressPubKey: true, + insightAPI: 'https://explorer.zensystem.io/insight-api-zen/', + explorerURL: 'https://explorer.zensystem.io/', + useTestNet: false, + unlockType: UNLOCK_WALLET_TYPE.HD_WALLET } - setInnerHTML(node, escapeTextContentForBrowser(text)); }; + return _this15; } -} -module.exports = setTextContent; + _createClass(ZWallet, [{ + key: 'handleUnlockPrivateKeys', + value: function handleUnlockPrivateKeys() { + if (this.state.privateKeys.length === 0) { + return -2; + } -/***/ }), -/* 91 */ -/***/ (function(module, exports, __webpack_require__) { + try { + var _privKeyToAddr = function _privKeyToAddr(pk, compressPubKey, useTestNet) { + // If not 64 length, probs WIF format + if (pk.length !== 64) { + pk = _zencashjs2.default.address.WIFToPrivKey(pk); + } -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // Convert public key to public address + var pubKey = _zencashjs2.default.address.privKeyToPubKey(pk, compressPubKey); + // Testnet or nah + var pubKeyHash = useTestNet ? _zencashjs2.default.config.testnet.pubKeyHash : _zencashjs2.default.config.mainnet.pubKeyHash; + var publicAddr = _zencashjs2.default.address.pubKeyToAddr(pubKey, pubKeyHash); + return publicAddr; + }; -/** - * @param {DOMElement} node input/textarea to focus - */ + var publicAddresses = {}; -function focusNode(node) { - // IE8 can throw "Can't move focus to the control because it is invisible, - // not enabled, or of a type that does not accept the focus." for all kinds of - // reasons that are too expensive and fragile to test. - try { - node.focus(); - } catch (e) {} -} + for (var i = 0; i < this.state.privateKeys.length; i++) { + var pubKeyHash = this.state.settings.useTestNet ? _zencashjs2.default.config.testnet.wif : _zencashjs2.default.config.mainnet.wif; -module.exports = focusNode; + var c_pk_wif; + var c_pk = this.state.privateKeys[i]; -/***/ }), -/* 92 */ -/***/ (function(module, exports, __webpack_require__) { + // If not 64 length, probs WIF format + if (c_pk.length !== 64) { + c_pk_wif = c_pk; + c_pk = _zencashjs2.default.address.WIFToPrivKey(c_pk); + } else { + c_pk_wif = _zencashjs2.default.address.privKeyToWIF(c_pk); + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var c_pk_wif = _zencashjs2.default.address.privKeyToWIF(c_pk, true, pubKeyHash); + var c_addr = _privKeyToAddr(c_pk, this.state.settings.compressPubKey, this.state.settings.useTestNet); + publicAddresses[c_addr] = { + privateKey: c_pk, + privateKeyWIF: c_pk_wif, + confirmedBalance: 'loading...', + unconfirmedBalance: 'loading...' + }; + } + // Set public address + this.setPublicAddresses(publicAddresses); -/** - * CSS properties which accept numbers but are not in units of "px". - */ + // Return success + return 0; + } catch (err) { + this.setPublicAddresses(null); + return -1; + } + } + }, { + key: 'resetKeys', + value: function resetKeys() { + this.setState({ + privateKeys: '', + publicAddresses: null + }); + } -var isUnitlessNumber = { - animationIterationCount: true, - borderImageOutset: true, - borderImageSlice: true, - borderImageWidth: true, - boxFlex: true, - boxFlexGroup: true, - boxOrdinalGroup: true, - columnCount: true, - flex: true, - flexGrow: true, - flexPositive: true, - flexShrink: true, - flexNegative: true, - flexOrder: true, - gridRow: true, - gridRowEnd: true, - gridRowSpan: true, - gridRowStart: true, - gridColumn: true, - gridColumnEnd: true, - gridColumnSpan: true, - gridColumnStart: true, - fontWeight: true, - lineClamp: true, - lineHeight: true, - opacity: true, - order: true, - orphans: true, - tabSize: true, - widows: true, - zIndex: true, - zoom: true, + // Only used for bip32 gen wallet because + // of the async nature - // SVG-related properties - fillOpacity: true, - floodOpacity: true, - stopOpacity: true, - strokeDasharray: true, - strokeDashoffset: true, - strokeMiterlimit: true, - strokeOpacity: true, - strokeWidth: true -}; + }, { + key: 'setPrivateKeys', + value: function setPrivateKeys(pk, handleUnlockingKeys) { + if (handleUnlockingKeys === undefined) { + handleUnlockingKeys = false; + } + this.setState({ + privateKeys: pk + }, handleUnlockingKeys ? this.handleUnlockPrivateKeys : undefined); + } + }, { + key: 'setPublicAddresses', + value: function setPublicAddresses(pa) { + this.setState({ + publicAddresses: pa + }); + } + }, { + key: 'setPublicAddressesKeyValue', + value: function setPublicAddressesKeyValue(address, key, value) { + var newPublicAddresses = this.state.publicAddresses; + newPublicAddresses[address][key] = value; -/** - * @param {string} prefix vendor-specific prefix, eg: Webkit - * @param {string} key style name, eg: transitionDuration - * @return {string} style name prefixed with `prefix`, properly camelCased, eg: - * WebkitTransitionDuration - */ -function prefixKey(prefix, key) { - return prefix + key.charAt(0).toUpperCase() + key.substring(1); -} + this.setState({ + publicAddresses: newPublicAddresses + }); + } + }, { + key: 'setInsightAPI', + value: function setInsightAPI(uri) { + var _settings = this.state.settings; + _settings.insightAPI = uri; -/** - * Support style names that may come passed in prefixed by adding permutations - * of vendor prefixes. - */ -var prefixes = ['Webkit', 'ms', 'Moz', 'O']; + this.setState({ + _settings: _settings + }); + } + }, { + key: 'setUnlockType', + value: function setUnlockType(t) { + var _settings = this.state.settings; + _settings.unlockType = t; -// Using Object.keys here, or else the vanilla for-in loop makes IE8 go into an -// infinite loop, because it iterates over the newly added props too. -Object.keys(isUnitlessNumber).forEach(function (prop) { - prefixes.forEach(function (prefix) { - isUnitlessNumber[prefixKey(prefix, prop)] = isUnitlessNumber[prop]; - }); -}); + this.setState({ + _settings: _settings + }); + } + }, { + key: 'toggleCompressPubKey', + value: function toggleCompressPubKey(b) { + var _settings = this.state.settings; + _settings.compressPubKey = !_settings.compressPubKey; -/** - * Most style properties can be unset by doing .style[prop] = '' but IE8 - * doesn't like doing that with shorthand properties so for the properties that - * IE8 breaks on, which are listed here, we instead unset each of the - * individual properties. See http://bugs.jquery.com/ticket/12385. - * The 4-value 'clock' properties like margin, padding, border-width seem to - * behave without any problems. Curiously, list-style works too without any - * special prodding. - */ -var shorthandPropertyExpansions = { - background: { - backgroundAttachment: true, - backgroundColor: true, - backgroundImage: true, - backgroundPositionX: true, - backgroundPositionY: true, - backgroundRepeat: true - }, - backgroundPosition: { - backgroundPositionX: true, - backgroundPositionY: true - }, - border: { - borderWidth: true, - borderStyle: true, - borderColor: true - }, - borderBottom: { - borderBottomWidth: true, - borderBottomStyle: true, - borderBottomColor: true - }, - borderLeft: { - borderLeftWidth: true, - borderLeftStyle: true, - borderLeftColor: true - }, - borderRight: { - borderRightWidth: true, - borderRightStyle: true, - borderRightColor: true - }, - borderTop: { - borderTopWidth: true, - borderTopStyle: true, - borderTopColor: true - }, - font: { - fontStyle: true, - fontVariant: true, - fontWeight: true, - fontSize: true, - lineHeight: true, - fontFamily: true - }, - outline: { - outlineWidth: true, - outlineStyle: true, - outlineColor: true - } -}; + this.setState({ + _settings: _settings + }); + } + }, { + key: 'toggleUseTestNet', + value: function toggleUseTestNet() { + var _settings = this.state.settings; + _settings.useTestNet = !_settings.useTestNet; + + if (_settings.useTestNet) { + _settings.insightAPI = 'http://aayanl.tech:8081/insight-api-zen/'; + _settings.explorerURL = 'http://aayanl.tech:8081/'; + } else { + _settings.insightAPI = 'https://explorer.zensystem.io/insight-api-zen/'; + _settings.explorerURL = 'https://explorer.zensystem.io/insight/'; + } -var CSSProperty = { - isUnitlessNumber: isUnitlessNumber, - shorthandPropertyExpansions: shorthandPropertyExpansions -}; + this.setState({ + settings: _settings + }); + } + }, { + key: 'toggleShowSettings', + value: function toggleShowSettings() { + var _settings = this.state.settings; + _settings.showSettings = !_settings.showSettings; -module.exports = CSSProperty; + this.setState({ + settings: _settings + }); + } + }, { + key: 'toggleShowWalletGen', + value: function toggleShowWalletGen() { + var _settings = this.state.settings; + _settings.showWalletGen = !_settings.showWalletGen; + + this.setState({ + settings: _settings + }); + } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + _reactstrap.Container, + null, + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + 'h1', + { className: 'display-6' }, + 'ZenCash Wallet\xA0', + _react2.default.createElement(ToolTipButton, { onClick: this.toggleShowSettings, id: 1, buttonText: _react2.default.createElement(_settings3.default, null), tooltipText: 'settings' }), + '\xA0', + _react2.default.createElement(ToolTipButton, { disabled: this.state.publicAddresses === null, onClick: this.resetKeys, id: 2, buttonText: _react2.default.createElement(_repeat2.default, null), tooltipText: 'reset wallet' }) + ), + _react2.default.createElement(ZWalletSettings, { + setUnlockType: this.setUnlockType, + toggleShowSettings: this.toggleShowSettings, + toggleCompressPubKey: this.toggleCompressPubKey, + toggleShowWalletGen: this.toggleShowWalletGen, + toggleUseTestNet: this.toggleUseTestNet, + setInsightAPI: this.setInsightAPI, + settings: this.state.settings, + publicAddresses: this.state.publicAddresses + }), + _react2.default.createElement('br', null) + ) + ), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.publicAddresses === null ? _react2.default.createElement(ZWalletUnlockKey, { + handleUnlockPrivateKeys: this.handleUnlockPrivateKeys, + setPrivateKeys: this.setPrivateKeys, + unlockType: this.state.settings.unlockType + }) : _react2.default.createElement(ZWalletTabs, { + publicAddresses: this.state.publicAddresses, + settings: this.state.settings, + setPublicAddressesKeyValue: this.setPublicAddressesKeyValue, + privateKeys: this.state.privateKeys + }) + ) + ), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.settings.showWalletGen ? _react2.default.createElement( + 'div', + null, + _react2.default.createElement('br', null), + _react2.default.createElement('hr', null), + _react2.default.createElement(ZWalletGenerator, { settings: this.state.settings }) + ) : null + ) + ) + ); + } + }]); + + return ZWallet; +}(_react2.default.Component); + +exports.default = ZWallet; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 93 */ +/* 333 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +exports.byteLength = byteLength +exports.toByteArray = toByteArray +exports.fromByteArray = fromByteArray -var DOMProperty = __webpack_require__(17); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstrumentation = __webpack_require__(13); +var lookup = [] +var revLookup = [] +var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array -var quoteAttributeValueForBrowser = __webpack_require__(168); -var warning = __webpack_require__(2); +var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' +for (var i = 0, len = code.length; i < len; ++i) { + lookup[i] = code[i] + revLookup[code.charCodeAt(i)] = i +} -var VALID_ATTRIBUTE_NAME_REGEX = new RegExp('^[' + DOMProperty.ATTRIBUTE_NAME_START_CHAR + '][' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); -var illegalAttributeNameCache = {}; -var validatedAttributeNameCache = {}; +revLookup['-'.charCodeAt(0)] = 62 +revLookup['_'.charCodeAt(0)] = 63 -function isAttributeNameSafe(attributeName) { - if (validatedAttributeNameCache.hasOwnProperty(attributeName)) { - return true; - } - if (illegalAttributeNameCache.hasOwnProperty(attributeName)) { - return false; - } - if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) { - validatedAttributeNameCache[attributeName] = true; - return true; +function placeHoldersCount (b64) { + var len = b64.length + if (len % 4 > 0) { + throw new Error('Invalid string. Length must be a multiple of 4') } - illegalAttributeNameCache[attributeName] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid attribute name: `%s`', attributeName) : void 0; - return false; + + // the number of equal signs (place holders) + // if there are two placeholders, than the two characters before it + // represent one byte + // if there is only one, then the three characters before it represent 2 bytes + // this is just a cheap hack to not do indexOf twice + return b64[len - 2] === '=' ? 2 : b64[len - 1] === '=' ? 1 : 0 } -function shouldIgnoreValue(propertyInfo, value) { - return value == null || propertyInfo.hasBooleanValue && !value || propertyInfo.hasNumericValue && isNaN(value) || propertyInfo.hasPositiveNumericValue && value < 1 || propertyInfo.hasOverloadedBooleanValue && value === false; +function byteLength (b64) { + // base64 is 4/3 + up to two characters of the original data + return (b64.length * 3 / 4) - placeHoldersCount(b64) } -/** - * Operations for dealing with DOM properties. - */ -var DOMPropertyOperations = { - /** - * Creates markup for the ID property. - * - * @param {string} id Unescaped ID. - * @return {string} Markup string. - */ - createMarkupForID: function (id) { - return DOMProperty.ID_ATTRIBUTE_NAME + '=' + quoteAttributeValueForBrowser(id); - }, +function toByteArray (b64) { + var i, l, tmp, placeHolders, arr + var len = b64.length + placeHolders = placeHoldersCount(b64) - setAttributeForID: function (node, id) { - node.setAttribute(DOMProperty.ID_ATTRIBUTE_NAME, id); - }, + arr = new Arr((len * 3 / 4) - placeHolders) - createMarkupForRoot: function () { - return DOMProperty.ROOT_ATTRIBUTE_NAME + '=""'; - }, + // if there are placeholders, only get up to the last complete 4 chars + l = placeHolders > 0 ? len - 4 : len - setAttributeForRoot: function (node) { - node.setAttribute(DOMProperty.ROOT_ATTRIBUTE_NAME, ''); - }, + var L = 0 - /** - * Creates markup for a property. - * - * @param {string} name - * @param {*} value - * @return {?string} Markup string, or null if the property was invalid. - */ - createMarkupForProperty: function (name, value) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - if (shouldIgnoreValue(propertyInfo, value)) { - return ''; - } - var attributeName = propertyInfo.attributeName; - if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { - return attributeName + '=""'; - } - return attributeName + '=' + quoteAttributeValueForBrowser(value); - } else if (DOMProperty.isCustomAttribute(name)) { - if (value == null) { - return ''; - } - return name + '=' + quoteAttributeValueForBrowser(value); - } - return null; - }, + for (i = 0; i < l; i += 4) { + tmp = (revLookup[b64.charCodeAt(i)] << 18) | (revLookup[b64.charCodeAt(i + 1)] << 12) | (revLookup[b64.charCodeAt(i + 2)] << 6) | revLookup[b64.charCodeAt(i + 3)] + arr[L++] = (tmp >> 16) & 0xFF + arr[L++] = (tmp >> 8) & 0xFF + arr[L++] = tmp & 0xFF + } - /** - * Creates markup for a custom property. - * - * @param {string} name - * @param {*} value - * @return {string} Markup string, or empty string if the property was invalid. - */ - createMarkupForCustomAttribute: function (name, value) { - if (!isAttributeNameSafe(name) || value == null) { - return ''; - } - return name + '=' + quoteAttributeValueForBrowser(value); - }, + if (placeHolders === 2) { + tmp = (revLookup[b64.charCodeAt(i)] << 2) | (revLookup[b64.charCodeAt(i + 1)] >> 4) + arr[L++] = tmp & 0xFF + } else if (placeHolders === 1) { + tmp = (revLookup[b64.charCodeAt(i)] << 10) | (revLookup[b64.charCodeAt(i + 1)] << 4) | (revLookup[b64.charCodeAt(i + 2)] >> 2) + arr[L++] = (tmp >> 8) & 0xFF + arr[L++] = tmp & 0xFF + } - /** - * Sets the value for a property on a node. - * - * @param {DOMElement} node - * @param {string} name - * @param {*} value - */ - setValueForProperty: function (node, name, value) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - var mutationMethod = propertyInfo.mutationMethod; - if (mutationMethod) { - mutationMethod(node, value); - } else if (shouldIgnoreValue(propertyInfo, value)) { - this.deleteValueForProperty(node, name); - return; - } else if (propertyInfo.mustUseProperty) { - // Contrary to `setAttribute`, object properties are properly - // `toString`ed by IE8/9. - node[propertyInfo.propertyName] = value; - } else { - var attributeName = propertyInfo.attributeName; - var namespace = propertyInfo.attributeNamespace; - // `setAttribute` with objects becomes only `[object]` in IE8/9, - // ('' + value) makes it output the correct toString()-value. - if (namespace) { - node.setAttributeNS(namespace, attributeName, '' + value); - } else if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { - node.setAttribute(attributeName, ''); - } else { - node.setAttribute(attributeName, '' + value); - } - } - } else if (DOMProperty.isCustomAttribute(name)) { - DOMPropertyOperations.setValueForAttribute(node, name, value); - return; - } + return arr +} + +function tripletToBase64 (num) { + return lookup[num >> 18 & 0x3F] + lookup[num >> 12 & 0x3F] + lookup[num >> 6 & 0x3F] + lookup[num & 0x3F] +} + +function encodeChunk (uint8, start, end) { + var tmp + var output = [] + for (var i = start; i < end; i += 3) { + tmp = (uint8[i] << 16) + (uint8[i + 1] << 8) + (uint8[i + 2]) + output.push(tripletToBase64(tmp)) + } + return output.join('') +} - if (process.env.NODE_ENV !== 'production') { - var payload = {}; - payload[name] = value; - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'update attribute', - payload: payload - }); - } - }, +function fromByteArray (uint8) { + var tmp + var len = uint8.length + var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes + var output = '' + var parts = [] + var maxChunkLength = 16383 // must be multiple of 3 - setValueForAttribute: function (node, name, value) { - if (!isAttributeNameSafe(name)) { - return; + // go through the array every three bytes, we'll deal with trailing stuff later + for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) { + parts.push(encodeChunk(uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength))) + } + + // pad the end with zeros, but make sure to not forget the extra bytes + if (extraBytes === 1) { + tmp = uint8[len - 1] + output += lookup[tmp >> 2] + output += lookup[(tmp << 4) & 0x3F] + output += '==' + } else if (extraBytes === 2) { + tmp = (uint8[len - 2] << 8) + (uint8[len - 1]) + output += lookup[tmp >> 10] + output += lookup[(tmp >> 4) & 0x3F] + output += lookup[(tmp << 2) & 0x3F] + output += '=' + } + + parts.push(output) + + return parts.join('') +} + + +/***/ }), +/* 334 */ +/***/ (function(module, exports) { + +exports.read = function (buffer, offset, isLE, mLen, nBytes) { + var e, m + var eLen = nBytes * 8 - mLen - 1 + var eMax = (1 << eLen) - 1 + var eBias = eMax >> 1 + var nBits = -7 + var i = isLE ? (nBytes - 1) : 0 + var d = isLE ? -1 : 1 + var s = buffer[offset + i] + + i += d + + e = s & ((1 << (-nBits)) - 1) + s >>= (-nBits) + nBits += eLen + for (; nBits > 0; e = e * 256 + buffer[offset + i], i += d, nBits -= 8) {} + + m = e & ((1 << (-nBits)) - 1) + e >>= (-nBits) + nBits += mLen + for (; nBits > 0; m = m * 256 + buffer[offset + i], i += d, nBits -= 8) {} + + if (e === 0) { + e = 1 - eBias + } else if (e === eMax) { + return m ? NaN : ((s ? -1 : 1) * Infinity) + } else { + m = m + Math.pow(2, mLen) + e = e - eBias + } + return (s ? -1 : 1) * m * Math.pow(2, e - mLen) +} + +exports.write = function (buffer, value, offset, isLE, mLen, nBytes) { + var e, m, c + var eLen = nBytes * 8 - mLen - 1 + var eMax = (1 << eLen) - 1 + var eBias = eMax >> 1 + var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0) + var i = isLE ? 0 : (nBytes - 1) + var d = isLE ? 1 : -1 + var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0 + + value = Math.abs(value) + + if (isNaN(value) || value === Infinity) { + m = isNaN(value) ? 1 : 0 + e = eMax + } else { + e = Math.floor(Math.log(value) / Math.LN2) + if (value * (c = Math.pow(2, -e)) < 1) { + e-- + c *= 2 } - if (value == null) { - node.removeAttribute(name); + if (e + eBias >= 1) { + value += rt / c } else { - node.setAttribute(name, '' + value); + value += rt * Math.pow(2, 1 - eBias) } - - if (process.env.NODE_ENV !== 'production') { - var payload = {}; - payload[name] = value; - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'update attribute', - payload: payload - }); + if (value * c >= 2) { + e++ + c /= 2 } - }, - /** - * Deletes an attributes from a node. - * - * @param {DOMElement} node - * @param {string} name - */ - deleteValueForAttribute: function (node, name) { - node.removeAttribute(name); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'remove attribute', - payload: name - }); + if (e + eBias >= eMax) { + m = 0 + e = eMax + } else if (e + eBias >= 1) { + m = (value * c - 1) * Math.pow(2, mLen) + e = e + eBias + } else { + m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen) + e = 0 } - }, + } - /** - * Deletes the value for a property on a node. - * - * @param {DOMElement} node - * @param {string} name - */ - deleteValueForProperty: function (node, name) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - var mutationMethod = propertyInfo.mutationMethod; - if (mutationMethod) { - mutationMethod(node, undefined); - } else if (propertyInfo.mustUseProperty) { - var propName = propertyInfo.propertyName; - if (propertyInfo.hasBooleanValue) { - node[propName] = false; - } else { - node[propName] = ''; - } - } else { - node.removeAttribute(propertyInfo.attributeName); - } - } else if (DOMProperty.isCustomAttribute(name)) { - node.removeAttribute(name); - } + for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {} - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'remove attribute', - payload: name - }); - } - } -}; + e = (e << mLen) | m + eLen += mLen + for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {} + + buffer[offset + i - d] |= s * 128 +} -module.exports = DOMPropertyOperations; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 94 */ +/* 335 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(336); + +/***/ }), +/* 336 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; + + +var utils = __webpack_require__(20); +var bind = __webpack_require__(155); +var Axios = __webpack_require__(338); +var defaults = __webpack_require__(94); + /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. + * Create an instance of Axios * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * @param {Object} defaultConfig The default config for the instance + * @return {Axios} A new instance of Axios + */ +function createInstance(defaultConfig) { + var context = new Axios(defaultConfig); + var instance = bind(Axios.prototype.request, context); + + // Copy axios.prototype to instance + utils.extend(instance, Axios.prototype, context); + + // Copy context to instance + utils.extend(instance, context); + + return instance; +} + +// Create the default instance to be exported +var axios = createInstance(defaults); + +// Expose Axios class to allow class inheritance +axios.Axios = Axios; + +// Factory for creating new instances +axios.create = function create(instanceConfig) { + return createInstance(utils.merge(defaults, instanceConfig)); +}; + +// Expose Cancel & CancelToken +axios.Cancel = __webpack_require__(159); +axios.CancelToken = __webpack_require__(352); +axios.isCancel = __webpack_require__(158); + +// Expose all/spread +axios.all = function all(promises) { + return Promise.all(promises); +}; +axios.spread = __webpack_require__(353); + +module.exports = axios; + +// Allow use of default import syntax in TypeScript +module.exports.default = axios; + + +/***/ }), +/* 337 */ +/***/ (function(module, exports) { + +/*! + * Determine if an object is a Buffer * - * + * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> + * @license MIT */ +// The _isBuffer check is for Safari 5-7 support, because it's missing +// Object.prototype.constructor. Remove this eventually +module.exports = function (obj) { + return obj != null && (isBuffer(obj) || isSlowBuffer(obj) || !!obj._isBuffer) +} +function isBuffer (obj) { + return !!obj.constructor && typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj) +} -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; +// For Node v0.10 support. Remove this eventually. +function isSlowBuffer (obj) { + return typeof obj.readFloatLE === 'function' && typeof obj.slice === 'function' && isBuffer(obj.slice(0, 0)) +} -module.exports = ReactPropTypesSecret; /***/ }), -/* 95 */ +/* 338 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. + + +var defaults = __webpack_require__(94); +var utils = __webpack_require__(20); +var InterceptorManager = __webpack_require__(347); +var dispatchRequest = __webpack_require__(348); +var isAbsoluteURL = __webpack_require__(350); +var combineURLs = __webpack_require__(351); + +/** + * Create a new instance of Axios * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * @param {Object} instanceConfig The default config for the instance + */ +function Axios(instanceConfig) { + this.defaults = instanceConfig; + this.interceptors = { + request: new InterceptorManager(), + response: new InterceptorManager() + }; +} + +/** + * Dispatch a request * + * @param {Object} config The config specific for this request (merged with this.defaults) */ +Axios.prototype.request = function request(config) { + /*eslint no-param-reassign:0*/ + // Allow for axios('example/url'[, config]) a la fetch API + if (typeof config === 'string') { + config = utils.merge({ + url: arguments[0] + }, arguments[1]); + } + config = utils.merge(defaults, this.defaults, { method: 'get' }, config); + config.method = config.method.toLowerCase(); + // Support baseURL config + if (config.baseURL && !isAbsoluteURL(config.url)) { + config.url = combineURLs(config.baseURL, config.url); + } -var _assign = __webpack_require__(5); + // Hook up interceptors middleware + var chain = [dispatchRequest, undefined]; + var promise = Promise.resolve(config); -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); + this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) { + chain.unshift(interceptor.fulfilled, interceptor.rejected); + }); -var warning = __webpack_require__(2); + this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) { + chain.push(interceptor.fulfilled, interceptor.rejected); + }); -var didWarnValueLink = false; -var didWarnValueDefaultValue = false; + while (chain.length) { + promise = promise.then(chain.shift(), chain.shift()); + } -function updateOptionsIfPendingUpdateAndMounted() { - if (this._rootNodeID && this._wrapperState.pendingUpdate) { - this._wrapperState.pendingUpdate = false; + return promise; +}; - var props = this._currentElement.props; - var value = LinkedValueUtils.getValue(props); +// Provide aliases for supported request methods +utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url + })); + }; +}); - if (value != null) { - updateOptions(this, Boolean(props.multiple), value); - } - } -} +utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, data, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url, + data: data + })); + }; +}); -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; +module.exports = Axios; + + +/***/ }), +/* 339 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +module.exports = function normalizeHeaderName(headers, normalizedName) { + utils.forEach(headers, function processHeader(value, name) { + if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) { + headers[normalizedName] = value; + delete headers[name]; } + }); +}; + + +/***/ }), +/* 340 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var createError = __webpack_require__(157); + +/** + * Resolve or reject a Promise based on response status. + * + * @param {Function} resolve A function that resolves the promise. + * @param {Function} reject A function that rejects the promise. + * @param {object} response The response. + */ +module.exports = function settle(resolve, reject, response) { + var validateStatus = response.config.validateStatus; + // Note: status is not exposed by XDomainRequest + if (!response.status || !validateStatus || validateStatus(response.status)) { + resolve(response); + } else { + reject(createError( + 'Request failed with status code ' + response.status, + response.config, + null, + response.request, + response + )); } - return ''; -} +}; + + +/***/ }), +/* 341 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; -var valuePropNames = ['value', 'defaultValue']; /** - * Validation function for `value` and `defaultValue`. - * @private + * Update an Error with the specified config, error code, and response. + * + * @param {Error} error The error to update. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The error. */ -function checkSelectPropTypes(inst, props) { - var owner = inst._currentElement._owner; - LinkedValueUtils.checkPropTypes('select', props, owner); +module.exports = function enhanceError(error, config, code, request, response) { + error.config = config; + if (code) { + error.code = code; + } + error.request = request; + error.response = response; + return error; +}; - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `select` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } - for (var i = 0; i < valuePropNames.length; i++) { - var propName = valuePropNames[i]; - if (props[propName] == null) { - continue; - } - var isArray = Array.isArray(props[propName]); - if (props.multiple && !isArray) { - process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be an array if ' + '`multiple` is true.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; - } else if (!props.multiple && isArray) { - process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be a scalar ' + 'value if `multiple` is false.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; - } - } +/***/ }), +/* 342 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); + +function encode(val) { + return encodeURIComponent(val). + replace(/%40/gi, '@'). + replace(/%3A/gi, ':'). + replace(/%24/g, '$'). + replace(/%2C/gi, ','). + replace(/%20/g, '+'). + replace(/%5B/gi, '['). + replace(/%5D/gi, ']'); } /** - * @param {ReactDOMComponent} inst - * @param {boolean} multiple - * @param {*} propValue A stringable (with `multiple`, a list of stringables). - * @private + * Build a URL by appending params to the end + * + * @param {string} url The base of the url (e.g., http://www.google.com) + * @param {object} [params] The params to be appended + * @returns {string} The formatted url */ -function updateOptions(inst, multiple, propValue) { - var selectedValue, i; - var options = ReactDOMComponentTree.getNodeFromInstance(inst).options; +module.exports = function buildURL(url, params, paramsSerializer) { + /*eslint no-param-reassign:0*/ + if (!params) { + return url; + } - if (multiple) { - selectedValue = {}; - for (i = 0; i < propValue.length; i++) { - selectedValue['' + propValue[i]] = true; - } - for (i = 0; i < options.length; i++) { - var selected = selectedValue.hasOwnProperty(options[i].value); - if (options[i].selected !== selected) { - options[i].selected = selected; - } - } + var serializedParams; + if (paramsSerializer) { + serializedParams = paramsSerializer(params); + } else if (utils.isURLSearchParams(params)) { + serializedParams = params.toString(); } else { - // Do not set `select.value` as exact behavior isn't consistent across all - // browsers for all cases. - selectedValue = '' + propValue; - for (i = 0; i < options.length; i++) { - if (options[i].value === selectedValue) { - options[i].selected = true; + var parts = []; + + utils.forEach(params, function serialize(val, key) { + if (val === null || typeof val === 'undefined') { return; } - } - if (options.length) { - options[0].selected = true; - } + + if (utils.isArray(val)) { + key = key + '[]'; + } + + if (!utils.isArray(val)) { + val = [val]; + } + + utils.forEach(val, function parseValue(v) { + if (utils.isDate(v)) { + v = v.toISOString(); + } else if (utils.isObject(v)) { + v = JSON.stringify(v); + } + parts.push(encode(key) + '=' + encode(v)); + }); + }); + + serializedParams = parts.join('&'); } -} + + if (serializedParams) { + url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams; + } + + return url; +}; + + +/***/ }), +/* 343 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var utils = __webpack_require__(20); /** - * Implements a <select> host component that allows optionally setting the - * props `value` and `defaultValue`. If `multiple` is false, the prop must be a - * stringable. If `multiple` is true, the prop must be an array of stringables. - * - * If `value` is not supplied (or null/undefined), user actions that change the - * selected option will trigger updates to the rendered options. + * Parse headers into an object * - * If it is supplied (and not null/undefined), the rendered options will not - * update in response to user actions. Instead, the `value` prop must change in - * order for the rendered options to update. + * ``` + * Date: Wed, 27 Aug 2014 08:58:49 GMT + * Content-Type: application/json + * Connection: keep-alive + * Transfer-Encoding: chunked + * ``` * - * If `defaultValue` is provided, any options with the supplied values will be - * selected. + * @param {String} headers Headers needing to be parsed + * @returns {Object} Headers parsed into an object */ -var ReactDOMSelect = { - getHostProps: function (inst, props) { - return _assign({}, props, { - onChange: inst._wrapperState.onChange, - value: undefined - }); - }, +module.exports = function parseHeaders(headers) { + var parsed = {}; + var key; + var val; + var i; - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - checkSelectPropTypes(inst, props); - } + if (!headers) { return parsed; } - var value = LinkedValueUtils.getValue(props); - inst._wrapperState = { - pendingUpdate: false, - initialValue: value != null ? value : props.defaultValue, - listeners: null, - onChange: _handleChange.bind(inst), - wasMultiple: Boolean(props.multiple) - }; + utils.forEach(headers.split('\n'), function parser(line) { + i = line.indexOf(':'); + key = utils.trim(line.substr(0, i)).toLowerCase(); + val = utils.trim(line.substr(i + 1)); - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Select elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; - didWarnValueDefaultValue = true; + if (key) { + parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val; } - }, + }); - getSelectValueContext: function (inst) { - // ReactDOMOption looks at this initial value so the initial generated - // markup has correct `selected` attributes - return inst._wrapperState.initialValue; - }, + return parsed; +}; - postUpdateWrapper: function (inst) { - var props = inst._currentElement.props; - // After the initial mount, we control selected-ness manually so don't pass - // this value down - inst._wrapperState.initialValue = undefined; +/***/ }), +/* 344 */ +/***/ (function(module, exports, __webpack_require__) { - var wasMultiple = inst._wrapperState.wasMultiple; - inst._wrapperState.wasMultiple = Boolean(props.multiple); +"use strict"; - var value = LinkedValueUtils.getValue(props); - if (value != null) { - inst._wrapperState.pendingUpdate = false; - updateOptions(inst, Boolean(props.multiple), value); - } else if (wasMultiple !== Boolean(props.multiple)) { - // For simplicity, reapply `defaultValue` if `multiple` is toggled. - if (props.defaultValue != null) { - updateOptions(inst, Boolean(props.multiple), props.defaultValue); - } else { - // Revert the select back to its default unselected state. - updateOptions(inst, Boolean(props.multiple), props.multiple ? [] : ''); + +var utils = __webpack_require__(20); + +module.exports = ( + utils.isStandardBrowserEnv() ? + + // Standard browser envs have full support of the APIs needed to test + // whether the request URL is of the same origin as current location. + (function standardBrowserEnv() { + var msie = /(msie|trident)/i.test(navigator.userAgent); + var urlParsingNode = document.createElement('a'); + var originURL; + + /** + * Parse a URL to discover it's components + * + * @param {String} url The URL to be parsed + * @returns {Object} + */ + function resolveURL(url) { + var href = url; + + if (msie) { + // IE needs attribute set twice to normalize properties + urlParsingNode.setAttribute('href', href); + href = urlParsingNode.href; } + + urlParsingNode.setAttribute('href', href); + + // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils + return { + href: urlParsingNode.href, + protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '', + host: urlParsingNode.host, + search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '', + hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '', + hostname: urlParsingNode.hostname, + port: urlParsingNode.port, + pathname: (urlParsingNode.pathname.charAt(0) === '/') ? + urlParsingNode.pathname : + '/' + urlParsingNode.pathname + }; } - } -}; -function _handleChange(event) { - var props = this._currentElement.props; - var returnValue = LinkedValueUtils.executeOnChange(props, event); + originURL = resolveURL(window.location.href); - if (this._rootNodeID) { - this._wrapperState.pendingUpdate = true; - } - ReactUpdates.asap(updateOptionsIfPendingUpdateAndMounted, this); - return returnValue; -} + /** + * Determine if a URL shares the same origin as the current location + * + * @param {String} requestURL The URL to test + * @returns {boolean} True if URL shares the same origin, otherwise false + */ + return function isURLSameOrigin(requestURL) { + var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL; + return (parsed.protocol === originURL.protocol && + parsed.host === originURL.host); + }; + })() : + + // Non standard browser envs (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return function isURLSameOrigin() { + return true; + }; + })() +); -module.exports = ReactDOMSelect; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 96 */ +/* 345 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +// btoa polyfill for IE<10 courtesy https://github.com/davidchambers/Base64.js -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='; -var ReactCompositeComponent = __webpack_require__(176); -var ReactEmptyComponent = __webpack_require__(98); -var ReactHostComponent = __webpack_require__(99); +function E() { + this.message = 'String contains an invalid character'; +} +E.prototype = new Error; +E.prototype.code = 5; +E.prototype.name = 'InvalidCharacterError'; + +function btoa(input) { + var str = String(input); + var output = ''; + for ( + // initialize result and counter + var block, charCode, idx = 0, map = chars; + // if the next str index does not exist: + // change the mapping table to "=" + // check if d has no fractional digits + str.charAt(idx | 0) || (map = '=', idx % 1); + // "8 - idx % 1 * 8" generates the sequence 2, 4, 6, 8 + output += map.charAt(63 & block >> 8 - idx % 1 * 8) + ) { + charCode = str.charCodeAt(idx += 3 / 4); + if (charCode > 0xFF) { + throw new E(); + } + block = block << 8 | charCode; + } + return output; +} -var getNextDebugID = __webpack_require__(179); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +module.exports = btoa; -// To avoid a cyclic dependency, we create the final class in this module -var ReactCompositeComponentWrapper = function (element) { - this.construct(element); -}; -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; -} +/***/ }), +/* 346 */ +/***/ (function(module, exports, __webpack_require__) { -/** - * Check if the type reference is a known internal type. I.e. not a user - * provided composite type. - * - * @param {function} type - * @return {boolean} Returns true if this is a valid internal type. - */ -function isInternalComponentType(type) { - return typeof type === 'function' && typeof type.prototype !== 'undefined' && typeof type.prototype.mountComponent === 'function' && typeof type.prototype.receiveComponent === 'function'; -} +"use strict"; -/** - * Given a ReactNode, create an instance that will actually be mounted. - * - * @param {ReactNode} node - * @param {boolean} shouldHaveDebugID - * @return {object} A new instance of the element's constructor. - * @protected - */ -function instantiateReactComponent(node, shouldHaveDebugID) { - var instance; - if (node === null || node === false) { - instance = ReactEmptyComponent.create(instantiateReactComponent); - } else if (typeof node === 'object') { - var element = node; - var type = element.type; - if (typeof type !== 'function' && typeof type !== 'string') { - var info = ''; - if (process.env.NODE_ENV !== 'production') { - if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { - info += ' You likely forgot to export your component from the file ' + "it's defined in."; +var utils = __webpack_require__(20); + +module.exports = ( + utils.isStandardBrowserEnv() ? + + // Standard browser envs support document.cookie + (function standardBrowserEnv() { + return { + write: function write(name, value, expires, path, domain, secure) { + var cookie = []; + cookie.push(name + '=' + encodeURIComponent(value)); + + if (utils.isNumber(expires)) { + cookie.push('expires=' + new Date(expires).toGMTString()); } - } - info += getDeclarationErrorAddendum(element._owner); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s', type == null ? type : typeof type, info) : _prodInvariant('130', type == null ? type : typeof type, info) : void 0; - } - // Special case string values - if (typeof element.type === 'string') { - instance = ReactHostComponent.createInternalComponent(element); - } else if (isInternalComponentType(element.type)) { - // This is temporarily available for custom components that are not string - // representations. I.e. ART. Once those are updated to use the string - // representation, we can drop this code path. - instance = new element.type(element); + if (utils.isString(path)) { + cookie.push('path=' + path); + } - // We renamed this. Allow the old name for compat. :( - if (!instance.getHostNode) { - instance.getHostNode = instance.getNativeNode; + if (utils.isString(domain)) { + cookie.push('domain=' + domain); + } + + if (secure === true) { + cookie.push('secure'); + } + + document.cookie = cookie.join('; '); + }, + + read: function read(name) { + var match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)')); + return (match ? decodeURIComponent(match[3]) : null); + }, + + remove: function remove(name) { + this.write(name, '', Date.now() - 86400000); } - } else { - instance = new ReactCompositeComponentWrapper(element); - } - } else if (typeof node === 'string' || typeof node === 'number') { - instance = ReactHostComponent.createInstanceForText(node); - } else { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Encountered invalid React node of type %s', typeof node) : _prodInvariant('131', typeof node) : void 0; - } + }; + })() : - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(typeof instance.mountComponent === 'function' && typeof instance.receiveComponent === 'function' && typeof instance.getHostNode === 'function' && typeof instance.unmountComponent === 'function', 'Only React Components can be mounted.') : void 0; - } + // Non standard browser env (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return { + write: function write() {}, + read: function read() { return null; }, + remove: function remove() {} + }; + })() +); - // These two fields are used by the DOM and ART diffing algorithms - // respectively. Instead of using expandos on components, we should be - // storing the state needed by the diffing algorithms elsewhere. - instance._mountIndex = 0; - instance._mountImage = null; - if (process.env.NODE_ENV !== 'production') { - instance._debugID = shouldHaveDebugID ? getNextDebugID() : 0; - } +/***/ }), +/* 347 */ +/***/ (function(module, exports, __webpack_require__) { - // Internal instances should fully constructed at this point, so they should - // not get any new fields added to them at this point. - if (process.env.NODE_ENV !== 'production') { - if (Object.preventExtensions) { - Object.preventExtensions(instance); - } +"use strict"; + + +var utils = __webpack_require__(20); + +function InterceptorManager() { + this.handlers = []; +} + +/** + * Add a new interceptor to the stack + * + * @param {Function} fulfilled The function to handle `then` for a `Promise` + * @param {Function} rejected The function to handle `reject` for a `Promise` + * + * @return {Number} An ID used to remove interceptor later + */ +InterceptorManager.prototype.use = function use(fulfilled, rejected) { + this.handlers.push({ + fulfilled: fulfilled, + rejected: rejected + }); + return this.handlers.length - 1; +}; + +/** + * Remove an interceptor from the stack + * + * @param {Number} id The ID that was returned by `use` + */ +InterceptorManager.prototype.eject = function eject(id) { + if (this.handlers[id]) { + this.handlers[id] = null; } +}; - return instance; -} +/** + * Iterate over all the registered interceptors + * + * This method is particularly useful for skipping over any + * interceptors that may have become `null` calling `eject`. + * + * @param {Function} fn The function to call for each interceptor + */ +InterceptorManager.prototype.forEach = function forEach(fn) { + utils.forEach(this.handlers, function forEachHandler(h) { + if (h !== null) { + fn(h); + } + }); +}; -_assign(ReactCompositeComponentWrapper.prototype, ReactCompositeComponent, { - _instantiateReactComponent: instantiateReactComponent -}); +module.exports = InterceptorManager; -module.exports = instantiateReactComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 97 */ +/* 348 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + + +var utils = __webpack_require__(20); +var transformData = __webpack_require__(349); +var isCancel = __webpack_require__(158); +var defaults = __webpack_require__(94); + +/** + * Throws a `Cancel` if cancellation has been requested. + */ +function throwIfCancellationRequested(config) { + if (config.cancelToken) { + config.cancelToken.throwIfRequested(); + } +} + +/** + * Dispatch a request to the server using the configured adapter. * - * + * @param {object} config The config that is to be used for the request + * @returns {Promise} The Promise to be fulfilled */ +module.exports = function dispatchRequest(config) { + throwIfCancellationRequested(config); + // Ensure headers exist + config.headers = config.headers || {}; + // Transform request data + config.data = transformData( + config.data, + config.headers, + config.transformRequest + ); -var _prodInvariant = __webpack_require__(3); + // Flatten headers + config.headers = utils.merge( + config.headers.common || {}, + config.headers[config.method] || {}, + config.headers || {} + ); -var React = __webpack_require__(24); + utils.forEach( + ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], + function cleanHeaderConfig(method) { + delete config.headers[method]; + } + ); -var invariant = __webpack_require__(1); + var adapter = config.adapter || defaults.adapter; -var ReactNodeTypes = { - HOST: 0, - COMPOSITE: 1, - EMPTY: 2, + return adapter(config).then(function onAdapterResolution(response) { + throwIfCancellationRequested(config); - getType: function (node) { - if (node === null || node === false) { - return ReactNodeTypes.EMPTY; - } else if (React.isValidElement(node)) { - if (typeof node.type === 'function') { - return ReactNodeTypes.COMPOSITE; - } else { - return ReactNodeTypes.HOST; + // Transform response data + response.data = transformData( + response.data, + response.headers, + config.transformResponse + ); + + return response; + }, function onAdapterRejection(reason) { + if (!isCancel(reason)) { + throwIfCancellationRequested(config); + + // Transform response data + if (reason && reason.response) { + reason.response.data = transformData( + reason.response.data, + reason.response.headers, + config.transformResponse + ); } } - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unexpected node: %s', node) : _prodInvariant('26', node) : void 0; - } + + return Promise.reject(reason); + }); }; -module.exports = ReactNodeTypes; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 98 */ +/* 349 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; + + +var utils = __webpack_require__(20); + /** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Transform the data for a request or a response * + * @param {Object|String} data The data to be transformed + * @param {Array} headers The headers for the request or response + * @param {Array|Function} fns A single function or Array of functions + * @returns {*} The resulting transformed data */ +module.exports = function transformData(data, headers, fns) { + /*eslint no-param-reassign:0*/ + utils.forEach(fns, function transform(fn) { + data = fn(data, headers); + }); + return data; +}; -var emptyComponentFactory; +/***/ }), +/* 350 */ +/***/ (function(module, exports, __webpack_require__) { -var ReactEmptyComponentInjection = { - injectEmptyComponentFactory: function (factory) { - emptyComponentFactory = factory; - } -}; +"use strict"; -var ReactEmptyComponent = { - create: function (instantiate) { - return emptyComponentFactory(instantiate); - } -}; -ReactEmptyComponent.injection = ReactEmptyComponentInjection; +/** + * Determines whether the specified URL is absolute + * + * @param {string} url The URL to test + * @returns {boolean} True if the specified URL is absolute, otherwise false + */ +module.exports = function isAbsoluteURL(url) { + // A URL is considered absolute if it begins with "<scheme>://" or "//" (protocol-relative URL). + // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed + // by any combination of letters, digits, plus, period, or hyphen. + return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url); +}; -module.exports = ReactEmptyComponent; /***/ }), -/* 99 */ +/* 351 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + + +/** + * Creates a new URL by combining the specified URLs * + * @param {string} baseURL The base URL + * @param {string} relativeURL The relative URL + * @returns {string} The combined URL */ +module.exports = function combineURLs(baseURL, relativeURL) { + return relativeURL + ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '') + : baseURL; +}; +/***/ }), +/* 352 */ +/***/ (function(module, exports, __webpack_require__) { -var _prodInvariant = __webpack_require__(3); - -var invariant = __webpack_require__(1); +"use strict"; -var genericComponentClass = null; -var textComponentClass = null; -var ReactHostComponentInjection = { - // This accepts a class that receives the tag string. This is a catch all - // that can render any kind of tag. - injectGenericComponentClass: function (componentClass) { - genericComponentClass = componentClass; - }, - // This accepts a text component class that takes the text string to be - // rendered as props. - injectTextComponentClass: function (componentClass) { - textComponentClass = componentClass; - } -}; +var Cancel = __webpack_require__(159); /** - * Get a host internal component class for a specific tag. + * A `CancelToken` is an object that can be used to request cancellation of an operation. * - * @param {ReactElement} element The element to create. - * @return {function} The internal class constructor function. + * @class + * @param {Function} executor The executor function. */ -function createInternalComponent(element) { - !genericComponentClass ? process.env.NODE_ENV !== 'production' ? invariant(false, 'There is no registered component for the tag %s', element.type) : _prodInvariant('111', element.type) : void 0; - return new genericComponentClass(element); +function CancelToken(executor) { + if (typeof executor !== 'function') { + throw new TypeError('executor must be a function.'); + } + + var resolvePromise; + this.promise = new Promise(function promiseExecutor(resolve) { + resolvePromise = resolve; + }); + + var token = this; + executor(function cancel(message) { + if (token.reason) { + // Cancellation has already been requested + return; + } + + token.reason = new Cancel(message); + resolvePromise(token.reason); + }); } /** - * @param {ReactText} text - * @return {ReactComponent} + * Throws a `Cancel` if cancellation has been requested. */ -function createInstanceForText(text) { - return new textComponentClass(text); -} +CancelToken.prototype.throwIfRequested = function throwIfRequested() { + if (this.reason) { + throw this.reason; + } +}; /** - * @param {ReactComponent} component - * @return {boolean} + * Returns an object that contains a new `CancelToken` and a function that, when called, + * cancels the `CancelToken`. */ -function isTextComponent(component) { - return component instanceof textComponentClass; -} - -var ReactHostComponent = { - createInternalComponent: createInternalComponent, - createInstanceForText: createInstanceForText, - isTextComponent: isTextComponent, - injection: ReactHostComponentInjection +CancelToken.source = function source() { + var cancel; + var token = new CancelToken(function executor(c) { + cancel = c; + }); + return { + token: token, + cancel: cancel + }; }; -module.exports = ReactHostComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = CancelToken; + /***/ }), -/* 100 */ +/* 353 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. + + +/** + * Syntactic sugar for invoking a function and expanding an array for arguments. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Common use case would be to use `Function.prototype.apply`. + * + * ```js + * function f(x, y, z) {} + * var args = [1, 2, 3]; + * f.apply(null, args); + * ``` + * + * With `spread` this example can be re-written. + * + * ```js + * spread(function(x, y, z) {})([1, 2, 3]); + * ``` * + * @param {Function} callback + * @returns {Function} */ +module.exports = function spread(callback) { + return function wrap(arr) { + return callback.apply(null, arr); + }; +}; +/***/ }), +/* 354 */ +/***/ (function(module, exports, __webpack_require__) { -var _prodInvariant = __webpack_require__(3); +"use strict"; -var ReactCurrentOwner = __webpack_require__(14); -var REACT_ELEMENT_TYPE = __webpack_require__(180); -var getIteratorFn = __webpack_require__(181); -var invariant = __webpack_require__(1); -var KeyEscapeUtils = __webpack_require__(62); -var warning = __webpack_require__(2); +var _require = __webpack_require__(355), + CopyToClipboard = _require.CopyToClipboard; -var SEPARATOR = '.'; -var SUBSEPARATOR = ':'; +module.exports = CopyToClipboard; -/** - * This is inlined from ReactElement since this file is shared between - * isomorphic and renderers. We could extract this to a - * - */ +/***/ }), +/* 355 */ +/***/ (function(module, exports, __webpack_require__) { -/** - * TODO: Test that a single child and an array with one item have the same key - * pattern. - */ +"use strict"; -var didWarnAboutMaps = false; -/** - * Generate a key string that identifies a component within a set. - * - * @param {*} component A component that could contain a manual key. - * @param {number} index Index that is used if a manual key is not provided. - * @return {string} - */ -function getComponentKey(component, index) { - // Do some typechecking here since we call this blindly. We want to ensure - // that we don't block potential future ES APIs. - if (component && typeof component === 'object' && component.key != null) { - // Explicit key - return KeyEscapeUtils.escape(component.key); - } - // Implicit key determined by the index in the set - return index.toString(36); -} +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.CopyToClipboard = undefined; -/** - * @param {?*} children Children tree container. - * @param {!string} nameSoFar Name of the key path so far. - * @param {!function} callback Callback to invoke with each child found. - * @param {?*} traverseContext Used to pass information throughout the traversal - * process. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { - var type = typeof children; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - if (type === 'undefined' || type === 'boolean') { - // All of the above are perceived as null. - children = null; - } +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - if (children === null || type === 'string' || type === 'number' || - // The following is inlined from ReactElement. This means we can optimize - // some checks. React Fiber also inlines this logic for similar purposes. - type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { - callback(traverseContext, children, - // If it's the only child, treat the name as if it was wrapped in an array - // so that it's consistent if the number of children grows. - nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); - return 1; - } +var _react = __webpack_require__(6); - var child; - var nextName; - var subtreeCount = 0; // Count of children found in the current subtree. - var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; +var _react2 = _interopRequireDefault(_react); - if (Array.isArray(children)) { - for (var i = 0; i < children.length; i++) { - child = children[i]; - nextName = nextNamePrefix + getComponentKey(child, i); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); +var _copyToClipboard = __webpack_require__(356); + +var _copyToClipboard2 = _interopRequireDefault(_copyToClipboard); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var CopyToClipboard = exports.CopyToClipboard = function (_React$PureComponent) { + _inherits(CopyToClipboard, _React$PureComponent); + + function CopyToClipboard() { + var _ref; + + var _temp, _this, _ret; + + _classCallCheck(this, CopyToClipboard); + + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; } - } else { - var iteratorFn = getIteratorFn(children); - if (iteratorFn) { - var iterator = iteratorFn.call(children); - var step; - if (iteratorFn !== children.entries) { - var ii = 0; - while (!(step = iterator.next()).done) { - child = step.value; - nextName = nextNamePrefix + getComponentKey(child, ii++); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - if (process.env.NODE_ENV !== 'production') { - var mapsAsChildrenAddendum = ''; - if (ReactCurrentOwner.current) { - var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); - if (mapsAsChildrenOwnerName) { - mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; - } - } - process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; - didWarnAboutMaps = true; - } - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - child = entry[1]; - nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } + + return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = CopyToClipboard.__proto__ || Object.getPrototypeOf(CopyToClipboard)).call.apply(_ref, [this].concat(args))), _this), _this.onClick = function (event) { + var _this$props = _this.props, + text = _this$props.text, + onCopy = _this$props.onCopy, + children = _this$props.children, + options = _this$props.options; + + + var elem = _react2.default.Children.only(children); + + var result = (0, _copyToClipboard2.default)(text, options); + + if (onCopy) { + onCopy(text, result); } - } else if (type === 'object') { - var addendum = ''; - if (process.env.NODE_ENV !== 'production') { - addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; - if (children._isReactElement) { - addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; - } - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - addendum += ' Check the render method of `' + name + '`.'; - } - } + + // Bypass onClick if it was present + if (elem && elem.props && typeof elem.props.onClick === 'function') { + elem.props.onClick(event); } - var childrenString = String(children); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; - } + }, _temp), _possibleConstructorReturn(_this, _ret); } - return subtreeCount; -} + _createClass(CopyToClipboard, [{ + key: 'render', + value: function render() { + var _props = this.props, + _text = _props.text, + _onCopy = _props.onCopy, + _options = _props.options, + children = _props.children, + props = _objectWithoutProperties(_props, ['text', 'onCopy', 'options', 'children']); -/** - * Traverses children that are typically specified as `props.children`, but - * might also be specified through attributes: - * - * - `traverseAllChildren(this.props.children, ...)` - * - `traverseAllChildren(this.props.leftPanelChildren, ...)` - * - * The `traverseContext` is an optional argument that is passed through the - * entire traversal. It can be used to store accumulations or anything else that - * the callback might find relevant. - * - * @param {?*} children Children tree object. - * @param {!function} callback To invoke upon traversing each child. - * @param {?*} traverseContext Context for traversal. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildren(children, callback, traverseContext) { - if (children == null) { - return 0; - } + var elem = _react2.default.Children.only(children); - return traverseAllChildrenImpl(children, '', callback, traverseContext); -} + return _react2.default.cloneElement(elem, _extends({}, props, { onClick: this.onClick })); + } + }]); -module.exports = traverseAllChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return CopyToClipboard; +}(_react2.default.PureComponent); /***/ }), -/* 101 */ +/* 356 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) { -/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * @typechecks - */ -var emptyFunction = __webpack_require__(12); +var deselectCurrent = __webpack_require__(357); -/** - * Upstream version of event listener. Does not take into account specific - * nature of platform. - */ -var EventListener = { - /** - * Listen to DOM events during the bubble phase. - * - * @param {DOMEventTarget} target DOM element to register listener on. - * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. - * @param {function} callback Callback function. - * @return {object} Object with a `remove` method. - */ - listen: function listen(target, eventType, callback) { - if (target.addEventListener) { - target.addEventListener(eventType, callback, false); - return { - remove: function remove() { - target.removeEventListener(eventType, callback, false); - } - }; - } else if (target.attachEvent) { - target.attachEvent('on' + eventType, callback); - return { - remove: function remove() { - target.detachEvent('on' + eventType, callback); - } - }; - } - }, +var defaultMessage = 'Copy to clipboard: #{key}, Enter'; - /** - * Listen to DOM events during the capture phase. - * - * @param {DOMEventTarget} target DOM element to register listener on. - * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. - * @param {function} callback Callback function. - * @return {object} Object with a `remove` method. - */ - capture: function capture(target, eventType, callback) { - if (target.addEventListener) { - target.addEventListener(eventType, callback, true); - return { - remove: function remove() { - target.removeEventListener(eventType, callback, true); - } - }; - } else { - if (process.env.NODE_ENV !== 'production') { - console.error('Attempted to listen to events during the capture phase on a ' + 'browser that does not support the capture phase. Your application ' + 'will not receive some events.'); +function format(message) { + var copyKey = (/mac os x/i.test(navigator.userAgent) ? '⌘' : 'Ctrl') + '+C'; + return message.replace(/#{\s*key\s*}/g, copyKey); +} + +function copy(text, options) { + var debug, message, reselectPrevious, range, selection, mark, success = false; + if (!options) { options = {}; } + debug = options.debug || false; + try { + reselectPrevious = deselectCurrent(); + + range = document.createRange(); + selection = document.getSelection(); + + mark = document.createElement('span'); + mark.textContent = text; + // reset user styles for span element + mark.style.all = 'unset'; + // prevents scrolling to the end of the page + mark.style.position = 'fixed'; + mark.style.top = 0; + mark.style.clip = 'rect(0, 0, 0, 0)'; + // used to preserve spaces and line breaks + mark.style.whiteSpace = 'pre'; + // do not inherit user-select (it may be `none`) + mark.style.webkitUserSelect = 'text'; + mark.style.MozUserSelect = 'text'; + mark.style.msUserSelect = 'text'; + mark.style.userSelect = 'text'; + + document.body.appendChild(mark); + + range.selectNode(mark); + selection.addRange(range); + + var successful = document.execCommand('copy'); + if (!successful) { + throw new Error('copy command was unsuccessful'); + } + success = true; + } catch (err) { + debug && console.error('unable to copy using execCommand: ', err); + debug && console.warn('trying IE specific stuff'); + try { + window.clipboardData.setData('text', text); + success = true; + } catch (err) { + debug && console.error('unable to copy using clipboardData: ', err); + debug && console.error('falling back to prompt'); + message = format('message' in options ? options.message : defaultMessage); + window.prompt(message, text); + } + } finally { + if (selection) { + if (typeof selection.removeRange == 'function') { + selection.removeRange(range); + } else { + selection.removeAllRanges(); } - return { - remove: emptyFunction - }; } - }, - registerDefault: function registerDefault() {} + if (mark) { + document.body.removeChild(mark); + } + reselectPrevious(); + } + + return success; +} + +module.exports = copy; + + +/***/ }), +/* 357 */ +/***/ (function(module, exports) { + + +module.exports = function () { + var selection = document.getSelection(); + if (!selection.rangeCount) { + return function () {}; + } + var active = document.activeElement; + + var ranges = []; + for (var i = 0; i < selection.rangeCount; i++) { + ranges.push(selection.getRangeAt(i)); + } + + switch (active.tagName.toUpperCase()) { // .toUpperCase handles XHTML + case 'INPUT': + case 'TEXTAREA': + active.blur(); + break; + + default: + active = null; + break; + } + + selection.removeAllRanges(); + return function () { + selection.type === 'Caret' && + selection.removeAllRanges(); + + if (!selection.rangeCount) { + ranges.forEach(function(range) { + selection.addRange(range); + }); + } + + active && + active.focus(); + }; }; -module.exports = EventListener; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 102 */ +/* 358 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.ReactTableDefaults = undefined; + +var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _classnames = __webpack_require__(41); + +var _classnames2 = _interopRequireDefault(_classnames); + +var _utils = __webpack_require__(95); + +var _utils2 = _interopRequireDefault(_utils); + +var _lifecycle = __webpack_require__(359); + +var _lifecycle2 = _interopRequireDefault(_lifecycle); + +var _methods = __webpack_require__(360); + +var _methods2 = _interopRequireDefault(_methods); + +var _defaultProps = __webpack_require__(361); + +var _defaultProps2 = _interopRequireDefault(_defaultProps); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +// + + +var ReactTableDefaults = exports.ReactTableDefaults = _defaultProps2.default; -var ReactDOMSelection = __webpack_require__(193); +var ReactTable = function (_Methods) { + _inherits(ReactTable, _Methods); -var containsNode = __webpack_require__(195); -var focusNode = __webpack_require__(91); -var getActiveElement = __webpack_require__(103); + function ReactTable(props) { + _classCallCheck(this, ReactTable); -function isInDocument(node) { - return containsNode(document.documentElement, node); -} + var _this = _possibleConstructorReturn(this, (ReactTable.__proto__ || Object.getPrototypeOf(ReactTable)).call(this)); -/** - * @ReactInputSelection: React input selection module. Based on Selection.js, - * but modified to be suitable for react and has a couple of bug fixes (doesn't - * assume buttons have range selections allowed). - * Input selection module for React. - */ -var ReactInputSelection = { - hasSelectionCapabilities: function (elem) { - var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); - return nodeName && (nodeName === 'input' && elem.type === 'text' || nodeName === 'textarea' || elem.contentEditable === 'true'); - }, + _this.getResolvedState = _this.getResolvedState.bind(_this); + _this.getDataModel = _this.getDataModel.bind(_this); + _this.getSortedData = _this.getSortedData.bind(_this); + _this.fireFetchData = _this.fireFetchData.bind(_this); + _this.getPropOrState = _this.getPropOrState.bind(_this); + _this.getStateOrProp = _this.getStateOrProp.bind(_this); + _this.filterData = _this.filterData.bind(_this); + _this.sortData = _this.sortData.bind(_this); + _this.getMinRows = _this.getMinRows.bind(_this); + _this.onPageChange = _this.onPageChange.bind(_this); + _this.onPageSizeChange = _this.onPageSizeChange.bind(_this); + _this.sortColumn = _this.sortColumn.bind(_this); + _this.filterColumn = _this.filterColumn.bind(_this); + _this.resizeColumnStart = _this.resizeColumnStart.bind(_this); + _this.resizeColumnEnd = _this.resizeColumnEnd.bind(_this); + _this.resizeColumnMoving = _this.resizeColumnMoving.bind(_this); - getSelectionInformation: function () { - var focusedElem = getActiveElement(); - return { - focusedElem: focusedElem, - selectionRange: ReactInputSelection.hasSelectionCapabilities(focusedElem) ? ReactInputSelection.getSelection(focusedElem) : null + _this.state = { + page: 0, + pageSize: props.defaultPageSize, + sorted: props.defaultSorted, + expanded: props.defaultExpanded, + filtered: props.defaultFiltered, + resized: props.defaultResized, + currentlyResizing: false, + skipNextSort: false }; - }, + return _this; + } - /** - * @restoreSelection: If any selection information was potentially lost, - * restore it. This is useful when performing operations that could remove dom - * nodes and place them back in, resulting in focus being lost. - */ - restoreSelection: function (priorSelectionInformation) { - var curFocusedElem = getActiveElement(); - var priorFocusedElem = priorSelectionInformation.focusedElem; - var priorSelectionRange = priorSelectionInformation.selectionRange; - if (curFocusedElem !== priorFocusedElem && isInDocument(priorFocusedElem)) { - if (ReactInputSelection.hasSelectionCapabilities(priorFocusedElem)) { - ReactInputSelection.setSelection(priorFocusedElem, priorSelectionRange); - } - focusNode(priorFocusedElem); - } - }, + _createClass(ReactTable, [{ + key: 'render', + value: function render() { + var _this2 = this; - /** - * @getSelection: Gets the selection bounds of a focused textarea, input or - * contentEditable node. - * -@input: Look up selection bounds of this input - * -@return {start: selectionStart, end: selectionEnd} - */ - getSelection: function (input) { - var selection; + var resolvedState = this.getResolvedState(); + var children = resolvedState.children, + className = resolvedState.className, + style = resolvedState.style, + getProps = resolvedState.getProps, + getTableProps = resolvedState.getTableProps, + getTheadGroupProps = resolvedState.getTheadGroupProps, + getTheadGroupTrProps = resolvedState.getTheadGroupTrProps, + getTheadGroupThProps = resolvedState.getTheadGroupThProps, + getTheadProps = resolvedState.getTheadProps, + getTheadTrProps = resolvedState.getTheadTrProps, + getTheadThProps = resolvedState.getTheadThProps, + getTheadFilterProps = resolvedState.getTheadFilterProps, + getTheadFilterTrProps = resolvedState.getTheadFilterTrProps, + getTheadFilterThProps = resolvedState.getTheadFilterThProps, + getTbodyProps = resolvedState.getTbodyProps, + getTrGroupProps = resolvedState.getTrGroupProps, + getTrProps = resolvedState.getTrProps, + getTdProps = resolvedState.getTdProps, + getTfootProps = resolvedState.getTfootProps, + getTfootTrProps = resolvedState.getTfootTrProps, + getTfootTdProps = resolvedState.getTfootTdProps, + getPaginationProps = resolvedState.getPaginationProps, + getLoadingProps = resolvedState.getLoadingProps, + getNoDataProps = resolvedState.getNoDataProps, + getResizerProps = resolvedState.getResizerProps, + showPagination = resolvedState.showPagination, + showPaginationTop = resolvedState.showPaginationTop, + showPaginationBottom = resolvedState.showPaginationBottom, + manual = resolvedState.manual, + loadingText = resolvedState.loadingText, + noDataText = resolvedState.noDataText, + sortable = resolvedState.sortable, + resizable = resolvedState.resizable, + filterable = resolvedState.filterable, + pivotIDKey = resolvedState.pivotIDKey, + pivotValKey = resolvedState.pivotValKey, + pivotBy = resolvedState.pivotBy, + subRowsKey = resolvedState.subRowsKey, + aggregatedKey = resolvedState.aggregatedKey, + originalKey = resolvedState.originalKey, + indexKey = resolvedState.indexKey, + groupedByPivotKey = resolvedState.groupedByPivotKey, + loading = resolvedState.loading, + pageSize = resolvedState.pageSize, + page = resolvedState.page, + sorted = resolvedState.sorted, + filtered = resolvedState.filtered, + resized = resolvedState.resized, + expanded = resolvedState.expanded, + pages = resolvedState.pages, + onExpandedChange = resolvedState.onExpandedChange, + TableComponent = resolvedState.TableComponent, + TheadComponent = resolvedState.TheadComponent, + TbodyComponent = resolvedState.TbodyComponent, + TrGroupComponent = resolvedState.TrGroupComponent, + TrComponent = resolvedState.TrComponent, + ThComponent = resolvedState.ThComponent, + TdComponent = resolvedState.TdComponent, + TfootComponent = resolvedState.TfootComponent, + PaginationComponent = resolvedState.PaginationComponent, + LoadingComponent = resolvedState.LoadingComponent, + SubComponent = resolvedState.SubComponent, + NoDataComponent = resolvedState.NoDataComponent, + ResizerComponent = resolvedState.ResizerComponent, + ExpanderComponent = resolvedState.ExpanderComponent, + PivotValueComponent = resolvedState.PivotValueComponent, + PivotComponent = resolvedState.PivotComponent, + AggregatedComponent = resolvedState.AggregatedComponent, + FilterComponent = resolvedState.FilterComponent, + PadRowComponent = resolvedState.PadRowComponent, + resolvedData = resolvedState.resolvedData, + allVisibleColumns = resolvedState.allVisibleColumns, + headerGroups = resolvedState.headerGroups, + hasHeaderGroups = resolvedState.hasHeaderGroups, + sortedData = resolvedState.sortedData, + currentlyResizing = resolvedState.currentlyResizing; + + // Pagination + + var startRow = pageSize * page; + var endRow = startRow + pageSize; + var pageRows = manual ? resolvedData : sortedData.slice(startRow, endRow); + var minRows = this.getMinRows(); + var padRows = _utils2.default.range(Math.max(minRows - pageRows.length, 0)); + + var hasColumnFooter = allVisibleColumns.some(function (d) { + return d.Footer; + }); + var hasFilters = filterable || allVisibleColumns.some(function (d) { + return d.filterable; + }); - if ('selectionStart' in input) { - // Modern browser with input or textarea. - selection = { - start: input.selectionStart, - end: input.selectionEnd - }; - } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { - // IE8 input. - var range = document.selection.createRange(); - // There can only be one selection per document in IE, so it must - // be in our element. - if (range.parentElement() === input) { - selection = { - start: -range.moveStart('character', -input.value.length), - end: -range.moveEnd('character', -input.value.length) - }; - } - } else { - // Content editable or old IE textarea. - selection = ReactDOMSelection.getOffsets(input); - } + var recurseRowsViewIndex = function recurseRowsViewIndex(rows) { + var path = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : []; + var index = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : -1; - return selection || { start: 0, end: 0 }; - }, + return [rows.map(function (row, i) { + index++; + var rowWithViewIndex = _extends({}, row, { + _viewIndex: index + }); + var newPath = path.concat([i]); + if (rowWithViewIndex[subRowsKey] && _utils2.default.get(expanded, newPath)) { + ; + var _recurseRowsViewIndex = recurseRowsViewIndex(rowWithViewIndex[subRowsKey], newPath, index); - /** - * @setSelection: Sets the selection bounds of a textarea or input and focuses - * the input. - * -@input Set selection bounds of this input or textarea - * -@offsets Object of same form that is returned from get* - */ - setSelection: function (input, offsets) { - var start = offsets.start; - var end = offsets.end; - if (end === undefined) { - end = start; - } + var _recurseRowsViewIndex2 = _slicedToArray(_recurseRowsViewIndex, 2); - if ('selectionStart' in input) { - input.selectionStart = start; - input.selectionEnd = Math.min(end, input.value.length); - } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { - var range = input.createTextRange(); - range.collapse(true); - range.moveStart('character', start); - range.moveEnd('character', end - start); - range.select(); - } else { - ReactDOMSelection.setOffsets(input, offsets); - } - } -}; + rowWithViewIndex[subRowsKey] = _recurseRowsViewIndex2[0]; + index = _recurseRowsViewIndex2[1]; + } + return rowWithViewIndex; + }), index]; + }; + var _recurseRowsViewIndex3 = recurseRowsViewIndex(pageRows); -module.exports = ReactInputSelection; + var _recurseRowsViewIndex4 = _slicedToArray(_recurseRowsViewIndex3, 1); -/***/ }), -/* 103 */ -/***/ (function(module, exports, __webpack_require__) { + pageRows = _recurseRowsViewIndex4[0]; -"use strict"; + var canPrevious = page > 0; + var canNext = page + 1 < pages; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + var rowMinWidth = _utils2.default.sum(allVisibleColumns.map(function (d) { + var resizedColumn = resized.find(function (x) { + return x.id === d.id; + }) || {}; + return _utils2.default.getFirstDefined(resizedColumn.value, d.width, d.minWidth); + })); -/* eslint-disable fb-www/typeof-undefined */ + var rowIndex = -1; + + var finalState = _extends({}, resolvedState, { + startRow: startRow, + endRow: endRow, + pageRows: pageRows, + minRows: minRows, + padRows: padRows, + hasColumnFooter: hasColumnFooter, + canPrevious: canPrevious, + canNext: canNext, + rowMinWidth: rowMinWidth + }); -/** - * Same as document.activeElement but wraps in a try-catch block. In IE it is - * not safe to call document.activeElement if there is nothing focused. - * - * The activeElement will be null only if the document or document body is not - * yet defined. - * - * @param {?DOMDocument} doc Defaults to current document. - * @return {?DOMElement} - */ -function getActiveElement(doc) /*?DOMElement*/{ - doc = doc || (typeof document !== 'undefined' ? document : undefined); - if (typeof doc === 'undefined') { - return null; - } - try { - return doc.activeElement || doc.body; - } catch (e) { - return doc.body; - } -} + // Visual Components -module.exports = getActiveElement; + var makeHeaderGroups = function makeHeaderGroups() { + var theadGroupProps = _utils2.default.splitProps(getTheadGroupProps(finalState, undefined, undefined, _this2)); + var theadGroupTrProps = _utils2.default.splitProps(getTheadGroupTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-headerGroups', theadGroupProps.className), + style: _extends({}, theadGroupProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadGroupProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadGroupTrProps.className, + style: theadGroupTrProps.style + }, theadGroupTrProps.rest), + headerGroups.map(makeHeaderGroup) + ) + ); + }; -/***/ }), -/* 104 */ -/***/ (function(module, exports, __webpack_require__) { + var makeHeaderGroup = function makeHeaderGroup(column, i) { + var resizedValue = function resizedValue(col) { + return (resized.find(function (x) { + return x.id === col.id; + }) || {}).value; + }; + var flex = _utils2.default.sum(column.columns.map(function (col) { + return col.width || resizedValue(col) ? 0 : col.minWidth; + })); + var width = _utils2.default.sum(column.columns.map(function (col) { + return _utils2.default.getFirstDefined(resizedValue(col), col.width, col.minWidth); + })); + var maxWidth = _utils2.default.sum(column.columns.map(function (col) { + return _utils2.default.getFirstDefined(resizedValue(col), col.width, col.maxWidth); + })); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var theadGroupThProps = _utils2.default.splitProps(getTheadGroupThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); + var classes = [column.headerClassName, theadGroupThProps.className, columnHeaderProps.className]; + var styles = _extends({}, column.headerStyle, theadGroupThProps.style, columnHeaderProps.style); -var _prodInvariant = __webpack_require__(3); + var rest = _extends({}, theadGroupThProps.rest, columnHeaderProps.rest); -var DOMLazyTree = __webpack_require__(27); -var DOMProperty = __webpack_require__(17); -var React = __webpack_require__(24); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactCurrentOwner = __webpack_require__(14); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMContainerInfo = __webpack_require__(210); -var ReactDOMFeatureFlags = __webpack_require__(211); -var ReactFeatureFlags = __webpack_require__(86); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactMarkupChecksum = __webpack_require__(212); -var ReactReconciler = __webpack_require__(26); -var ReactUpdateQueue = __webpack_require__(63); -var ReactUpdates = __webpack_require__(15); + var flexStyles = { + flex: flex + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }; -var emptyObject = __webpack_require__(39); -var instantiateReactComponent = __webpack_require__(96); -var invariant = __webpack_require__(1); -var setInnerHTML = __webpack_require__(43); -var shouldUpdateReactComponent = __webpack_require__(61); -var warning = __webpack_require__(2); + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes), + style: _extends({}, styles, flexStyles) + }, rest), + _utils2.default.normalizeComponent(column.Header, { + data: sortedData, + column: column + }) + ); + }; -var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; -var ROOT_ATTR_NAME = DOMProperty.ROOT_ATTRIBUTE_NAME; + var makeHeaders = function makeHeaders() { + var theadProps = _utils2.default.splitProps(getTheadProps(finalState, undefined, undefined, _this2)); + var theadTrProps = _utils2.default.splitProps(getTheadTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-header', theadProps.className), + style: _extends({}, theadProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadTrProps.className, + style: theadTrProps.style + }, theadTrProps.rest), + allVisibleColumns.map(makeHeader) + ) + ); + }; -var ELEMENT_NODE_TYPE = 1; -var DOC_NODE_TYPE = 9; -var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + var makeHeader = function makeHeader(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var sort = sorted.find(function (d) { + return d.id === column.id; + }); + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var theadThProps = _utils2.default.splitProps(getTheadThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); -var instancesByReactRootID = {}; + var classes = [column.headerClassName, theadThProps.className, columnHeaderProps.className]; -/** - * Finds the index of the first character - * that's not common between the two given strings. - * - * @return {number} the index of the character where the strings diverge - */ -function firstDifferenceIndex(string1, string2) { - var minLen = Math.min(string1.length, string2.length); - for (var i = 0; i < minLen; i++) { - if (string1.charAt(i) !== string2.charAt(i)) { - return i; - } - } - return string1.length === string2.length ? -1 : minLen; -} + var styles = _extends({}, column.headerStyle, theadThProps.style, columnHeaderProps.style); -/** - * @param {DOMElement|DOMDocument} container DOM element that may contain - * a React component - * @return {?*} DOM element that may have the reactRoot ID, or null. - */ -function getReactRootElementInContainer(container) { - if (!container) { - return null; - } + var rest = _extends({}, theadThProps.rest, columnHeaderProps.rest); - if (container.nodeType === DOC_NODE_TYPE) { - return container.documentElement; - } else { - return container.firstChild; - } -} + var isResizable = _utils2.default.getFirstDefined(column.resizable, resizable, false); + var resizer = isResizable ? _react2.default.createElement(ResizerComponent, _extends({ + onMouseDown: function onMouseDown(e) { + return _this2.resizeColumnStart(e, column, false); + }, + onTouchStart: function onTouchStart(e) { + return _this2.resizeColumnStart(e, column, true); + } + }, resizerProps)) : null; -function internalGetID(node) { - // If node is something like a window, document, or text node, none of - // which support attributes or a .getAttribute method, gracefully return - // the empty string, as if the attribute were missing. - return node.getAttribute && node.getAttribute(ATTR_NAME) || ''; -} + var isSortable = _utils2.default.getFirstDefined(column.sortable, sortable, false); -/** - * Mounts this component and inserts it into the DOM. - * - * @param {ReactComponent} componentInstance The instance to mount. - * @param {DOMElement} container DOM element to mount into. - * @param {ReactReconcileTransaction} transaction - * @param {boolean} shouldReuseMarkup If true, do not insert markup - */ -function mountComponentIntoNode(wrapperInstance, container, transaction, shouldReuseMarkup, context) { - var markerName; - if (ReactFeatureFlags.logTopLevelRenders) { - var wrappedElement = wrapperInstance._currentElement.props.child; - var type = wrappedElement.type; - markerName = 'React mount: ' + (typeof type === 'string' ? type : type.displayName || type.name); - console.time(markerName); - } + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, 'rt-resizable-header', sort ? sort.desc ? '-sort-desc' : '-sort-asc' : '', isSortable && '-cursor-pointer', !show && '-hidden', pivotBy && pivotBy.slice(0, -1).includes(column.id) && 'rt-header-pivot'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }), + toggleSort: function toggleSort(e) { + isSortable && _this2.sortColumn(column, e.shiftKey); + } + }, rest), + _react2.default.createElement( + 'div', + { className: 'rt-resizable-header-content' }, + _utils2.default.normalizeComponent(column.Header, { + data: sortedData, + column: column + }) + ), + resizer + ); + }; - var markup = ReactReconciler.mountComponent(wrapperInstance, transaction, null, ReactDOMContainerInfo(wrapperInstance, container), context, 0 /* parentDebugID */ - ); + var makeFilters = function makeFilters() { + var theadFilterProps = _utils2.default.splitProps(getTheadFilterProps(finalState, undefined, undefined, _this2)); + var theadFilterTrProps = _utils2.default.splitProps(getTheadFilterTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-filters', theadFilterProps.className), + style: _extends({}, theadFilterProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadFilterProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadFilterTrProps.className, + style: theadFilterTrProps.style + }, theadFilterTrProps.rest), + allVisibleColumns.map(makeFilter) + ) + ); + }; - if (markerName) { - console.timeEnd(markerName); - } + var makeFilter = function makeFilter(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var theadFilterThProps = _utils2.default.splitProps(getTheadFilterThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); - wrapperInstance._renderedComponent._topLevelWrapper = wrapperInstance; - ReactMount._mountImageIntoNode(markup, container, wrapperInstance, shouldReuseMarkup, transaction); -} + var classes = [column.headerClassName, theadFilterThProps.className, columnHeaderProps.className]; -/** - * Batched mount. - * - * @param {ReactComponent} componentInstance The instance to mount. - * @param {DOMElement} container DOM element to mount into. - * @param {boolean} shouldReuseMarkup If true, do not insert markup - */ -function batchedMountComponentIntoNode(componentInstance, container, shouldReuseMarkup, context) { - var transaction = ReactUpdates.ReactReconcileTransaction.getPooled( - /* useCreateElement */ - !shouldReuseMarkup && ReactDOMFeatureFlags.useCreateElement); - transaction.perform(mountComponentIntoNode, null, componentInstance, container, transaction, shouldReuseMarkup, context); - ReactUpdates.ReactReconcileTransaction.release(transaction); -} + var styles = _extends({}, column.headerStyle, theadFilterThProps.style, columnHeaderProps.style); -/** - * Unmounts a component and removes it from the DOM. - * - * @param {ReactComponent} instance React component instance. - * @param {DOMElement} container DOM element to unmount from. - * @final - * @internal - * @see {ReactMount.unmountComponentAtNode} - */ -function unmountComponentFromNode(instance, container, safely) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onBeginFlush(); - } - ReactReconciler.unmountComponent(instance, safely); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onEndFlush(); - } + var rest = _extends({}, theadFilterThProps.rest, columnHeaderProps.rest); - if (container.nodeType === DOC_NODE_TYPE) { - container = container.documentElement; - } + var filter = filtered.find(function (filter) { + return filter.id === column.id; + }); - // http://jsperf.com/emptying-a-node - while (container.lastChild) { - container.removeChild(container.lastChild); - } -} + var ResolvedFilterComponent = column.Filter || FilterComponent; -/** - * True if the supplied DOM node has a direct React-rendered child that is - * not a React root element. Useful for warning in `render`, - * `unmountComponentAtNode`, etc. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM element contains a direct child that was - * rendered by React but is not a root element. - * @internal - */ -function hasNonRootReactChild(container) { - var rootEl = getReactRootElementInContainer(container); - if (rootEl) { - var inst = ReactDOMComponentTree.getInstanceFromNode(rootEl); - return !!(inst && inst._hostParent); - } -} + var isFilterable = _utils2.default.getFirstDefined(column.filterable, filterable, false); -/** - * True if the supplied DOM node is a React DOM element and - * it has been rendered by another copy of React. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM has been rendered by another copy of React - * @internal - */ -function nodeIsRenderedByOtherInstance(container) { - var rootEl = getReactRootElementInContainer(container); - return !!(rootEl && isReactNode(rootEl) && !ReactDOMComponentTree.getInstanceFromNode(rootEl)); -} + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, rest), + isFilterable ? _utils2.default.normalizeComponent(ResolvedFilterComponent, { + column: column, + filter: filter, + onChange: function onChange(value) { + return _this2.filterColumn(column, value); + } + }, _defaultProps2.default.column.Filter) : null + ); + }; -/** - * True if the supplied DOM node is a valid node element. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM is a valid DOM node. - * @internal - */ -function isValidContainer(node) { - return !!(node && (node.nodeType === ELEMENT_NODE_TYPE || node.nodeType === DOC_NODE_TYPE || node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE)); -} + var makePageRow = function makePageRow(row, i) { + var path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : []; + + var rowInfo = { + original: row[originalKey], + row: row, + index: row[indexKey], + viewIndex: ++rowIndex, + level: path.length, + nestingPath: path.concat([i]), + aggregated: row[aggregatedKey], + groupedByPivot: row[groupedByPivotKey], + subRows: row[subRowsKey] + }; + var isExpanded = _utils2.default.get(expanded, rowInfo.nestingPath); + var trGroupProps = getTrGroupProps(finalState, rowInfo, undefined, _this2); + var trProps = _utils2.default.splitProps(getTrProps(finalState, rowInfo, undefined, _this2)); + return _react2.default.createElement( + TrGroupComponent, + _extends({ key: rowInfo.nestingPath.join('_') }, trGroupProps), + _react2.default.createElement( + TrComponent, + _extends({ + className: (0, _classnames2.default)(trProps.className, row._viewIndex % 2 ? '-even' : '-odd'), + style: trProps.style + }, trProps.rest), + allVisibleColumns.map(function (column, i2) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tdProps = _utils2.default.splitProps(getTdProps(finalState, rowInfo, column, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, rowInfo, column, _this2)); + + var classes = [tdProps.className, column.className, columnProps.className]; + + var styles = _extends({}, tdProps.style, column.style, columnProps.style); + + var cellInfo = _extends({}, rowInfo, { + isExpanded: isExpanded, + column: _extends({}, column), + value: rowInfo.row[column.id], + pivoted: column.pivoted, + expander: column.expander, + resized: resized, + show: show, + width: width, + maxWidth: maxWidth, + tdProps: tdProps, + columnProps: columnProps, + classes: classes, + styles: styles + }); + + var value = cellInfo.value; + + var useOnExpanderClick = void 0; + var isBranch = void 0; + var isPreview = void 0; + + var onExpanderClick = function onExpanderClick(e) { + var newExpanded = _utils2.default.clone(expanded); + if (isExpanded) { + newExpanded = _utils2.default.set(newExpanded, cellInfo.nestingPath, false); + } else { + newExpanded = _utils2.default.set(newExpanded, cellInfo.nestingPath, {}); + } -/** - * True if the supplied DOM node is a valid React node element. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM is a valid React DOM node. - * @internal - */ -function isReactNode(node) { - return isValidContainer(node) && (node.hasAttribute(ROOT_ATTR_NAME) || node.hasAttribute(ATTR_NAME)); -} + return _this2.setStateWithData({ + expanded: newExpanded + }, function () { + onExpandedChange && onExpandedChange(newExpanded, cellInfo.nestingPath, e); + }); + }; -function getHostRootInstanceInContainer(container) { - var rootEl = getReactRootElementInContainer(container); - var prevHostInstance = rootEl && ReactDOMComponentTree.getInstanceFromNode(rootEl); - return prevHostInstance && !prevHostInstance._hostParent ? prevHostInstance : null; -} + // Default to a standard cell + var resolvedCell = _utils2.default.normalizeComponent(column.Cell, cellInfo, value); -function getTopLevelWrapperInContainer(container) { - var root = getHostRootInstanceInContainer(container); - return root ? root._hostContainerInfo._topLevelWrapper : null; -} + // Resolve Renderers + var ResolvedAggregatedComponent = column.Aggregated || (!column.aggregate ? AggregatedComponent : column.Cell); + var ResolvedExpanderComponent = column.Expander || ExpanderComponent; + var ResolvedPivotValueComponent = column.PivotValue || PivotValueComponent; + var DefaultResolvedPivotComponent = PivotComponent || function (props) { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement(ResolvedExpanderComponent, props), + _react2.default.createElement(ResolvedPivotValueComponent, props) + ); + }; + var ResolvedPivotComponent = column.Pivot || DefaultResolvedPivotComponent; + + // Is this cell expandable? + if (cellInfo.pivoted || cellInfo.expander) { + // Make it expandable by defualt + cellInfo.expandable = true; + useOnExpanderClick = true; + // If pivoted, has no subRows, and does not have a subComponent, do not make expandable + if (cellInfo.pivoted && !cellInfo.subRows && !SubComponent) { + cellInfo.expandable = false; + } + } -/** - * Temporary (?) hack so that we can store all top-level pending updates on - * composites instead of having to worry about different types of components - * here. - */ -var topLevelRootCounter = 1; -var TopLevelWrapper = function () { - this.rootID = topLevelRootCounter++; -}; -TopLevelWrapper.prototype.isReactComponent = {}; -if (process.env.NODE_ENV !== 'production') { - TopLevelWrapper.displayName = 'TopLevelWrapper'; -} -TopLevelWrapper.prototype.render = function () { - return this.props.child; -}; -TopLevelWrapper.isReactTopLevelWrapper = true; + if (cellInfo.pivoted) { + // Is this column a branch? + isBranch = rowInfo.row[pivotIDKey] === column.id && cellInfo.subRows; + // Should this column be blank? + isPreview = pivotBy.indexOf(column.id) > pivotBy.indexOf(rowInfo.row[pivotIDKey]) && cellInfo.subRows; + // Pivot Cell Render Override + if (isBranch) { + // isPivot + resolvedCell = _utils2.default.normalizeComponent(ResolvedPivotComponent, _extends({}, cellInfo, { + value: row[pivotValKey] + }), row[pivotValKey]); + } else if (isPreview) { + // Show the pivot preview + resolvedCell = _utils2.default.normalizeComponent(ResolvedAggregatedComponent, cellInfo, value); + } else { + resolvedCell = null; + } + } else if (cellInfo.aggregated) { + resolvedCell = _utils2.default.normalizeComponent(ResolvedAggregatedComponent, cellInfo, value); + } -/** - * Mounting is the process of initializing a React component by creating its - * representative DOM elements and inserting them into a supplied `container`. - * Any prior content inside `container` is destroyed in the process. - * - * ReactMount.render( - * component, - * document.getElementById('container') - * ); - * - * <div id="container"> <-- Supplied `container`. - * <div data-reactid=".3"> <-- Rendered reactRoot of React - * // ... component. - * </div> - * </div> - * - * Inside of `container`, the first element rendered is the "reactRoot". - */ -var ReactMount = { - TopLevelWrapper: TopLevelWrapper, + if (cellInfo.expander) { + resolvedCell = _utils2.default.normalizeComponent(ResolvedExpanderComponent, cellInfo, row[pivotValKey]); + if (pivotBy) { + if (cellInfo.groupedByPivot) { + resolvedCell = null; + } + if (!cellInfo.subRows && !SubComponent) { + resolvedCell = null; + } + } + } - /** - * Used by devtools. The keys are not important. - */ - _instancesByReactRootID: instancesByReactRootID, + var resolvedOnExpanderClick = useOnExpanderClick ? onExpanderClick : function () {}; - /** - * This is a hook provided to support rendering React components while - * ensuring that the apparent scroll position of its `container` does not - * change. - * - * @param {DOMElement} container The `container` being rendered into. - * @param {function} renderCallback This must be called once to do the render. - */ - scrollMonitor: function (container, renderCallback) { - renderCallback(); - }, + // If there are multiple onClick events, make sure they don't override eachother. This should maybe be expanded to handle all function attributes + var interactionProps = { + onClick: resolvedOnExpanderClick + }; - /** - * Take a component that's already mounted into the DOM and replace its props - * @param {ReactComponent} prevComponent component instance already in the DOM - * @param {ReactElement} nextElement component instance to render - * @param {DOMElement} container container to render into - * @param {?function} callback function triggered on completion - */ - _updateRootComponent: function (prevComponent, nextElement, nextContext, container, callback) { - ReactMount.scrollMonitor(container, function () { - ReactUpdateQueue.enqueueElementInternal(prevComponent, nextElement, nextContext); - if (callback) { - ReactUpdateQueue.enqueueCallbackInternal(prevComponent, callback); - } - }); + if (tdProps.rest.onClick) { + interactionProps.onClick = function (e) { + tdProps.rest.onClick(e, function () { + return resolvedOnExpanderClick(e); + }); + }; + } - return prevComponent; - }, + if (columnProps.rest.onClick) { + interactionProps.onClick = function (e) { + columnProps.rest.onClick(e, function () { + return resolvedOnExpanderClick(e); + }); + }; + } - /** - * Render a new component into the DOM. Hooked by hooks! - * - * @param {ReactElement} nextElement element to render - * @param {DOMElement} container container to render into - * @param {boolean} shouldReuseMarkup if we should skip the markup insertion - * @return {ReactComponent} nextComponent - */ - _renderNewRootComponent: function (nextElement, container, shouldReuseMarkup, context) { - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '_renderNewRootComponent(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from ' + 'render is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; + // Return the cell + return _react2.default.createElement( + TdComponent, + _extends({ + key: i2 + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden', cellInfo.expandable && 'rt-expandable', (isBranch || isPreview) && 'rt-pivot'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, tdProps.rest, columnProps.rest, interactionProps), + resolvedCell + ); + }) + ), + rowInfo.subRows && isExpanded && rowInfo.subRows.map(function (d, i) { + return makePageRow(d, i, rowInfo.nestingPath); + }), + SubComponent && !rowInfo.subRows && isExpanded && SubComponent(rowInfo) + ); + }; - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, '_registerComponent(...): Target container is not a DOM element.') : _prodInvariant('37') : void 0; + var makePadRow = function makePadRow(row, i) { + var trGroupProps = getTrGroupProps(finalState, undefined, undefined, _this2); + var trProps = _utils2.default.splitProps(getTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TrGroupComponent, + _extends({ key: i }, trGroupProps), + _react2.default.createElement( + TrComponent, + { + className: (0, _classnames2.default)('-padRow', (pageRows.length + i) % 2 ? '-even' : '-odd', trProps.className), + style: trProps.style || {} + }, + allVisibleColumns.map(makePadColumn) + ) + ); + }; - ReactBrowserEventEmitter.ensureScrollValueMonitoring(); - var componentInstance = instantiateReactComponent(nextElement, false); + var makePadColumn = function makePadColumn(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var flex = width; + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tdProps = _utils2.default.splitProps(getTdProps(finalState, undefined, column, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, undefined, column, _this2)); - // The initial render is synchronous but any updates that happen during - // rendering, in componentWillMount or componentDidMount, will be batched - // according to the current batching strategy. + var classes = [tdProps.className, column.className, columnProps.className]; - ReactUpdates.batchedUpdates(batchedMountComponentIntoNode, componentInstance, container, shouldReuseMarkup, context); + var styles = _extends({}, tdProps.style, column.style, columnProps.style); - var wrapperID = componentInstance._instance.rootID; - instancesByReactRootID[wrapperID] = componentInstance; + return _react2.default.createElement( + TdComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden'), + style: _extends({}, styles, { + flex: flex + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, tdProps.rest), + _utils2.default.normalizeComponent(PadRowComponent) + ); + }; - return componentInstance; - }, + var makeColumnFooters = function makeColumnFooters() { + var tFootProps = getTfootProps(finalState, undefined, undefined, _this2); + var tFootTrProps = _utils2.default.splitProps(getTfootTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TfootComponent, + _extends({ + className: tFootProps.className, + style: _extends({}, tFootProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, tFootProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: (0, _classnames2.default)(tFootTrProps.className), + style: tFootTrProps.style + }, tFootTrProps.rest), + allVisibleColumns.map(makeColumnFooter) + ) + ); + }; - /** - * Renders a React component into the DOM in the supplied `container`. - * - * If the React component was previously rendered into `container`, this will - * perform an update on it and only mutate the DOM as necessary to reflect the - * latest React component. - * - * @param {ReactComponent} parentComponent The conceptual parent of this render tree. - * @param {ReactElement} nextElement Component element to render. - * @param {DOMElement} container DOM element to render into. - * @param {?function} callback function triggered on completion - * @return {ReactComponent} Component instance rendered in `container`. - */ - renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { - !(parentComponent != null && ReactInstanceMap.has(parentComponent)) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'parentComponent must be a valid React Component') : _prodInvariant('38') : void 0; - return ReactMount._renderSubtreeIntoContainer(parentComponent, nextElement, container, callback); - }, + var makeColumnFooter = function makeColumnFooter(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tFootTdProps = _utils2.default.splitProps(getTfootTdProps(finalState, undefined, undefined, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, undefined, column, _this2)); + var columnFooterProps = _utils2.default.splitProps(column.getFooterProps(finalState, undefined, column, _this2)); - _renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { - ReactUpdateQueue.validateCallback(callback, 'ReactDOM.render'); - !React.isValidElement(nextElement) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOM.render(): Invalid component element.%s', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : // Check if it quacks like an element - nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : _prodInvariant('39', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : void 0; + var classes = [tFootTdProps.className, column.className, columnProps.className, columnFooterProps.className]; + + var styles = _extends({}, tFootTdProps.style, column.style, columnProps.style, columnFooterProps.style); + + return _react2.default.createElement( + TdComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, columnProps.rest, tFootTdProps.rest, columnFooterProps.rest), + _utils2.default.normalizeComponent(column.Footer, { + data: sortedData, + column: column + }) + ); + }; - process.env.NODE_ENV !== 'production' ? warning(!container || !container.tagName || container.tagName.toUpperCase() !== 'BODY', 'render(): Rendering components directly into document.body is ' + 'discouraged, since its children are often manipulated by third-party ' + 'scripts and browser extensions. This may lead to subtle ' + 'reconciliation issues. Try rendering into a container element created ' + 'for your app.') : void 0; + var makePagination = function makePagination() { + var paginationProps = _utils2.default.splitProps(getPaginationProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement(PaginationComponent, _extends({}, resolvedState, { + pages: pages, + canPrevious: canPrevious, + canNext: canNext, + onPageChange: _this2.onPageChange, + onPageSizeChange: _this2.onPageSizeChange, + className: paginationProps.className, + style: paginationProps.style + }, paginationProps.rest)); + }; - var nextWrappedElement = React.createElement(TopLevelWrapper, { - child: nextElement - }); + var rootProps = _utils2.default.splitProps(getProps(finalState, undefined, undefined, this)); + var tableProps = _utils2.default.splitProps(getTableProps(finalState, undefined, undefined, this)); + var tBodyProps = _utils2.default.splitProps(getTbodyProps(finalState, undefined, undefined, this)); + var loadingProps = getLoadingProps(finalState, undefined, undefined, this); + var noDataProps = getNoDataProps(finalState, undefined, undefined, this); + var resizerProps = getResizerProps(finalState, undefined, undefined, this); - var nextContext; - if (parentComponent) { - var parentInst = ReactInstanceMap.get(parentComponent); - nextContext = parentInst._processChildContext(parentInst._context); - } else { - nextContext = emptyObject; + var makeTable = function makeTable() { + var pagination = makePagination(); + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)('ReactTable', className, rootProps.className), + style: _extends({}, style, rootProps.style) + }, rootProps.rest), + showPagination && showPaginationTop ? _react2.default.createElement( + 'div', + { className: 'pagination-top' }, + pagination + ) : null, + _react2.default.createElement( + TableComponent, + _extends({ + className: (0, _classnames2.default)(tableProps.className, currentlyResizing ? 'rt-resizing' : ''), + style: tableProps.style + }, tableProps.rest), + hasHeaderGroups ? makeHeaderGroups() : null, + makeHeaders(), + hasFilters ? makeFilters() : null, + _react2.default.createElement( + TbodyComponent, + _extends({ + className: (0, _classnames2.default)(tBodyProps.className), + style: _extends({}, tBodyProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, tBodyProps.rest), + pageRows.map(function (d, i) { + return makePageRow(d, i); + }), + padRows.map(makePadRow) + ), + hasColumnFooter ? makeColumnFooters() : null + ), + showPagination && showPaginationBottom ? _react2.default.createElement( + 'div', + { className: 'pagination-bottom' }, + pagination + ) : null, + !pageRows.length && _react2.default.createElement( + NoDataComponent, + noDataProps, + _utils2.default.normalizeComponent(noDataText) + ), + _react2.default.createElement(LoadingComponent, _extends({ + loading: loading, + loadingText: loadingText + }, loadingProps)) + ); + }; + + // childProps are optionally passed to a function-as-a-child + return children ? children(finalState, makeTable, this) : makeTable(); } + }]); - var prevComponent = getTopLevelWrapperInContainer(container); + return ReactTable; +}((0, _methods2.default)((0, _lifecycle2.default)(_react.Component))); - if (prevComponent) { - var prevWrappedElement = prevComponent._currentElement; - var prevElement = prevWrappedElement.props.child; - if (shouldUpdateReactComponent(prevElement, nextElement)) { - var publicInst = prevComponent._renderedComponent.getPublicInstance(); - var updatedCallback = callback && function () { - callback.call(publicInst); - }; - ReactMount._updateRootComponent(prevComponent, nextWrappedElement, nextContext, container, updatedCallback); - return publicInst; - } else { - ReactMount.unmountComponentAtNode(container); - } - } +ReactTable.defaultProps = _defaultProps2.default; +exports.default = ReactTable; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC5qcyJdLCJuYW1lcyI6WyJSZWFjdFRhYmxlRGVmYXVsdHMiLCJSZWFjdFRhYmxlIiwicHJvcHMiLCJnZXRSZXNvbHZlZFN0YXRlIiwiYmluZCIsImdldERhdGFNb2RlbCIsImdldFNvcnRlZERhdGEiLCJmaXJlRmV0Y2hEYXRhIiwiZ2V0UHJvcE9yU3RhdGUiLCJnZXRTdGF0ZU9yUHJvcCIsImZpbHRlckRhdGEiLCJzb3J0RGF0YSIsImdldE1pblJvd3MiLCJvblBhZ2VDaGFuZ2UiLCJvblBhZ2VTaXplQ2hhbmdlIiwic29ydENvbHVtbiIsImZpbHRlckNvbHVtbiIsInJlc2l6ZUNvbHVtblN0YXJ0IiwicmVzaXplQ29sdW1uRW5kIiwicmVzaXplQ29sdW1uTW92aW5nIiwic3RhdGUiLCJwYWdlIiwicGFnZVNpemUiLCJkZWZhdWx0UGFnZVNpemUiLCJzb3J0ZWQiLCJkZWZhdWx0U29ydGVkIiwiZXhwYW5kZWQiLCJkZWZhdWx0RXhwYW5kZWQiLCJmaWx0ZXJlZCIsImRlZmF1bHRGaWx0ZXJlZCIsInJlc2l6ZWQiLCJkZWZhdWx0UmVzaXplZCIsImN1cnJlbnRseVJlc2l6aW5nIiwic2tpcE5leHRTb3J0IiwicmVzb2x2ZWRTdGF0ZSIsImNoaWxkcmVuIiwiY2xhc3NOYW1lIiwic3R5bGUiLCJnZXRQcm9wcyIsImdldFRhYmxlUHJvcHMiLCJnZXRUaGVhZEdyb3VwUHJvcHMiLCJnZXRUaGVhZEdyb3VwVHJQcm9wcyIsImdldFRoZWFkR3JvdXBUaFByb3BzIiwiZ2V0VGhlYWRQcm9wcyIsImdldFRoZWFkVHJQcm9wcyIsImdldFRoZWFkVGhQcm9wcyIsImdldFRoZWFkRmlsdGVyUHJvcHMiLCJnZXRUaGVhZEZpbHRlclRyUHJvcHMiLCJnZXRUaGVhZEZpbHRlclRoUHJvcHMiLCJnZXRUYm9keVByb3BzIiwiZ2V0VHJHcm91cFByb3BzIiwiZ2V0VHJQcm9wcyIsImdldFRkUHJvcHMiLCJnZXRUZm9vdFByb3BzIiwiZ2V0VGZvb3RUclByb3BzIiwiZ2V0VGZvb3RUZFByb3BzIiwiZ2V0UGFnaW5hdGlvblByb3BzIiwiZ2V0TG9hZGluZ1Byb3BzIiwiZ2V0Tm9EYXRhUHJvcHMiLCJnZXRSZXNpemVyUHJvcHMiLCJzaG93UGFnaW5hdGlvbiIsInNob3dQYWdpbmF0aW9uVG9wIiwic2hvd1BhZ2luYXRpb25Cb3R0b20iLCJtYW51YWwiLCJsb2FkaW5nVGV4dCIsIm5vRGF0YVRleHQiLCJzb3J0YWJsZSIsInJlc2l6YWJsZSIsImZpbHRlcmFibGUiLCJwaXZvdElES2V5IiwicGl2b3RWYWxLZXkiLCJwaXZvdEJ5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJsb2FkaW5nIiwicGFnZXMiLCJvbkV4cGFuZGVkQ2hhbmdlIiwiVGFibGVDb21wb25lbnQiLCJUaGVhZENvbXBvbmVudCIsIlRib2R5Q29tcG9uZW50IiwiVHJHcm91cENvbXBvbmVudCIsIlRyQ29tcG9uZW50IiwiVGhDb21wb25lbnQiLCJUZENvbXBvbmVudCIsIlRmb290Q29tcG9uZW50IiwiUGFnaW5hdGlvbkNvbXBvbmVudCIsIkxvYWRpbmdDb21wb25lbnQiLCJTdWJDb21wb25lbnQiLCJOb0RhdGFDb21wb25lbnQiLCJSZXNpemVyQ29tcG9uZW50IiwiRXhwYW5kZXJDb21wb25lbnQiLCJQaXZvdFZhbHVlQ29tcG9uZW50IiwiUGl2b3RDb21wb25lbnQiLCJBZ2dyZWdhdGVkQ29tcG9uZW50IiwiRmlsdGVyQ29tcG9uZW50IiwiUGFkUm93Q29tcG9uZW50IiwicmVzb2x2ZWREYXRhIiwiYWxsVmlzaWJsZUNvbHVtbnMiLCJoZWFkZXJHcm91cHMiLCJoYXNIZWFkZXJHcm91cHMiLCJzb3J0ZWREYXRhIiwic3RhcnRSb3ciLCJlbmRSb3ciLCJwYWdlUm93cyIsInNsaWNlIiwibWluUm93cyIsInBhZFJvd3MiLCJyYW5nZSIsIk1hdGgiLCJtYXgiLCJsZW5ndGgiLCJoYXNDb2x1bW5Gb290ZXIiLCJzb21lIiwiZCIsIkZvb3RlciIsImhhc0ZpbHRlcnMiLCJyZWN1cnNlUm93c1ZpZXdJbmRleCIsInJvd3MiLCJwYXRoIiwiaW5kZXgiLCJtYXAiLCJyb3ciLCJpIiwicm93V2l0aFZpZXdJbmRleCIsIl92aWV3SW5kZXgiLCJuZXdQYXRoIiwiY29uY2F0IiwiZ2V0IiwiY2FuUHJldmlvdXMiLCJjYW5OZXh0Iiwicm93TWluV2lkdGgiLCJzdW0iLCJyZXNpemVkQ29sdW1uIiwiZmluZCIsIngiLCJpZCIsImdldEZpcnN0RGVmaW5lZCIsInZhbHVlIiwid2lkdGgiLCJtaW5XaWR0aCIsInJvd0luZGV4IiwiZmluYWxTdGF0ZSIsIm1ha2VIZWFkZXJHcm91cHMiLCJ0aGVhZEdyb3VwUHJvcHMiLCJzcGxpdFByb3BzIiwidW5kZWZpbmVkIiwidGhlYWRHcm91cFRyUHJvcHMiLCJyZXN0IiwibWFrZUhlYWRlckdyb3VwIiwiY29sdW1uIiwicmVzaXplZFZhbHVlIiwiY29sIiwiZmxleCIsImNvbHVtbnMiLCJtYXhXaWR0aCIsInRoZWFkR3JvdXBUaFByb3BzIiwiY29sdW1uSGVhZGVyUHJvcHMiLCJnZXRIZWFkZXJQcm9wcyIsImNsYXNzZXMiLCJoZWFkZXJDbGFzc05hbWUiLCJzdHlsZXMiLCJoZWFkZXJTdHlsZSIsImZsZXhTdHlsZXMiLCJhc1B4Iiwibm9ybWFsaXplQ29tcG9uZW50IiwiSGVhZGVyIiwiZGF0YSIsIm1ha2VIZWFkZXJzIiwidGhlYWRQcm9wcyIsInRoZWFkVHJQcm9wcyIsIm1ha2VIZWFkZXIiLCJyZXNpemVkQ29sIiwic29ydCIsInNob3ciLCJ0aGVhZFRoUHJvcHMiLCJpc1Jlc2l6YWJsZSIsInJlc2l6ZXIiLCJlIiwicmVzaXplclByb3BzIiwiaXNTb3J0YWJsZSIsImRlc2MiLCJpbmNsdWRlcyIsInNoaWZ0S2V5IiwibWFrZUZpbHRlcnMiLCJ0aGVhZEZpbHRlclByb3BzIiwidGhlYWRGaWx0ZXJUclByb3BzIiwibWFrZUZpbHRlciIsInRoZWFkRmlsdGVyVGhQcm9wcyIsImZpbHRlciIsIlJlc29sdmVkRmlsdGVyQ29tcG9uZW50IiwiRmlsdGVyIiwiaXNGaWx0ZXJhYmxlIiwib25DaGFuZ2UiLCJtYWtlUGFnZVJvdyIsInJvd0luZm8iLCJvcmlnaW5hbCIsInZpZXdJbmRleCIsImxldmVsIiwibmVzdGluZ1BhdGgiLCJhZ2dyZWdhdGVkIiwiZ3JvdXBlZEJ5UGl2b3QiLCJzdWJSb3dzIiwiaXNFeHBhbmRlZCIsInRyR3JvdXBQcm9wcyIsInRyUHJvcHMiLCJqb2luIiwiaTIiLCJ0ZFByb3BzIiwiY29sdW1uUHJvcHMiLCJjZWxsSW5mbyIsInBpdm90ZWQiLCJleHBhbmRlciIsInVzZU9uRXhwYW5kZXJDbGljayIsImlzQnJhbmNoIiwiaXNQcmV2aWV3Iiwib25FeHBhbmRlckNsaWNrIiwibmV3RXhwYW5kZWQiLCJjbG9uZSIsInNldCIsInNldFN0YXRlV2l0aERhdGEiLCJyZXNvbHZlZENlbGwiLCJDZWxsIiwiUmVzb2x2ZWRBZ2dyZWdhdGVkQ29tcG9uZW50IiwiQWdncmVnYXRlZCIsImFnZ3JlZ2F0ZSIsIlJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQiLCJFeHBhbmRlciIsIlJlc29sdmVkUGl2b3RWYWx1ZUNvbXBvbmVudCIsIlBpdm90VmFsdWUiLCJEZWZhdWx0UmVzb2x2ZWRQaXZvdENvbXBvbmVudCIsIlJlc29sdmVkUGl2b3RDb21wb25lbnQiLCJQaXZvdCIsImV4cGFuZGFibGUiLCJpbmRleE9mIiwicmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2siLCJpbnRlcmFjdGlvblByb3BzIiwib25DbGljayIsIm1ha2VQYWRSb3ciLCJtYWtlUGFkQ29sdW1uIiwibWFrZUNvbHVtbkZvb3RlcnMiLCJ0Rm9vdFByb3BzIiwidEZvb3RUclByb3BzIiwibWFrZUNvbHVtbkZvb3RlciIsInRGb290VGRQcm9wcyIsImNvbHVtbkZvb3RlclByb3BzIiwiZ2V0Rm9vdGVyUHJvcHMiLCJtYWtlUGFnaW5hdGlvbiIsInBhZ2luYXRpb25Qcm9wcyIsInJvb3RQcm9wcyIsInRhYmxlUHJvcHMiLCJ0Qm9keVByb3BzIiwibG9hZGluZ1Byb3BzIiwibm9EYXRhUHJvcHMiLCJtYWtlVGFibGUiLCJwYWdpbmF0aW9uIiwiZGVmYXVsdFByb3BzIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7O0FBQUE7Ozs7QUFDQTs7OztBQUVBOzs7O0FBQ0E7Ozs7QUFDQTs7OztBQUNBOzs7Ozs7Ozs7OztBQUpBOzs7QUFNTyxJQUFNQSx3RUFBTjs7SUFFY0MsVTs7O0FBR25CLHNCQUFhQyxLQUFiLEVBQW9CO0FBQUE7O0FBQUE7O0FBR2xCLFVBQUtDLGdCQUFMLEdBQXdCLE1BQUtBLGdCQUFMLENBQXNCQyxJQUF0QixPQUF4QjtBQUNBLFVBQUtDLFlBQUwsR0FBb0IsTUFBS0EsWUFBTCxDQUFrQkQsSUFBbEIsT0FBcEI7QUFDQSxVQUFLRSxhQUFMLEdBQXFCLE1BQUtBLGFBQUwsQ0FBbUJGLElBQW5CLE9BQXJCO0FBQ0EsVUFBS0csYUFBTCxHQUFxQixNQUFLQSxhQUFMLENBQW1CSCxJQUFuQixPQUFyQjtBQUNBLFVBQUtJLGNBQUwsR0FBc0IsTUFBS0EsY0FBTCxDQUFvQkosSUFBcEIsT0FBdEI7QUFDQSxVQUFLSyxjQUFMLEdBQXNCLE1BQUtBLGNBQUwsQ0FBb0JMLElBQXBCLE9BQXRCO0FBQ0EsVUFBS00sVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCTixJQUFoQixPQUFsQjtBQUNBLFVBQUtPLFFBQUwsR0FBZ0IsTUFBS0EsUUFBTCxDQUFjUCxJQUFkLE9BQWhCO0FBQ0EsVUFBS1EsVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCUixJQUFoQixPQUFsQjtBQUNBLFVBQUtTLFlBQUwsR0FBb0IsTUFBS0EsWUFBTCxDQUFrQlQsSUFBbEIsT0FBcEI7QUFDQSxVQUFLVSxnQkFBTCxHQUF3QixNQUFLQSxnQkFBTCxDQUFzQlYsSUFBdEIsT0FBeEI7QUFDQSxVQUFLVyxVQUFMLEdBQWtCLE1BQUtBLFVBQUwsQ0FBZ0JYLElBQWhCLE9BQWxCO0FBQ0EsVUFBS1ksWUFBTCxHQUFvQixNQUFLQSxZQUFMLENBQWtCWixJQUFsQixPQUFwQjtBQUNBLFVBQUthLGlCQUFMLEdBQXlCLE1BQUtBLGlCQUFMLENBQXVCYixJQUF2QixPQUF6QjtBQUNBLFVBQUtjLGVBQUwsR0FBdUIsTUFBS0EsZUFBTCxDQUFxQmQsSUFBckIsT0FBdkI7QUFDQSxVQUFLZSxrQkFBTCxHQUEwQixNQUFLQSxrQkFBTCxDQUF3QmYsSUFBeEIsT0FBMUI7O0FBRUEsVUFBS2dCLEtBQUwsR0FBYTtBQUNYQyxZQUFNLENBREs7QUFFWEMsZ0JBQVVwQixNQUFNcUIsZUFGTDtBQUdYQyxjQUFRdEIsTUFBTXVCLGFBSEg7QUFJWEMsZ0JBQVV4QixNQUFNeUIsZUFKTDtBQUtYQyxnQkFBVTFCLE1BQU0yQixlQUxMO0FBTVhDLGVBQVM1QixNQUFNNkIsY0FOSjtBQU9YQyx5QkFBbUIsS0FQUjtBQVFYQyxvQkFBYztBQVJILEtBQWI7QUFwQmtCO0FBOEJuQjs7Ozs2QkFFUztBQUFBOztBQUNSLFVBQU1DLGdCQUFnQixLQUFLL0IsZ0JBQUwsRUFBdEI7QUFEUSxVQUdOZ0MsUUFITSxHQW9GSkQsYUFwRkksQ0FHTkMsUUFITTtBQUFBLFVBSU5DLFNBSk0sR0FvRkpGLGFBcEZJLENBSU5FLFNBSk07QUFBQSxVQUtOQyxLQUxNLEdBb0ZKSCxhQXBGSSxDQUtORyxLQUxNO0FBQUEsVUFNTkMsUUFOTSxHQW9GSkosYUFwRkksQ0FNTkksUUFOTTtBQUFBLFVBT05DLGFBUE0sR0FvRkpMLGFBcEZJLENBT05LLGFBUE07QUFBQSxVQVFOQyxrQkFSTSxHQW9GSk4sYUFwRkksQ0FRTk0sa0JBUk07QUFBQSxVQVNOQyxvQkFUTSxHQW9GSlAsYUFwRkksQ0FTTk8sb0JBVE07QUFBQSxVQVVOQyxvQkFWTSxHQW9GSlIsYUFwRkksQ0FVTlEsb0JBVk07QUFBQSxVQVdOQyxhQVhNLEdBb0ZKVCxhQXBGSSxDQVdOUyxhQVhNO0FBQUEsVUFZTkMsZUFaTSxHQW9GSlYsYUFwRkksQ0FZTlUsZUFaTTtBQUFBLFVBYU5DLGVBYk0sR0FvRkpYLGFBcEZJLENBYU5XLGVBYk07QUFBQSxVQWNOQyxtQkFkTSxHQW9GSlosYUFwRkksQ0FjTlksbUJBZE07QUFBQSxVQWVOQyxxQkFmTSxHQW9GSmIsYUFwRkksQ0FlTmEscUJBZk07QUFBQSxVQWdCTkMscUJBaEJNLEdBb0ZKZCxhQXBGSSxDQWdCTmMscUJBaEJNO0FBQUEsVUFpQk5DLGFBakJNLEdBb0ZKZixhQXBGSSxDQWlCTmUsYUFqQk07QUFBQSxVQWtCTkMsZUFsQk0sR0FvRkpoQixhQXBGSSxDQWtCTmdCLGVBbEJNO0FBQUEsVUFtQk5DLFVBbkJNLEdBb0ZKakIsYUFwRkksQ0FtQk5pQixVQW5CTTtBQUFBLFVBb0JOQyxVQXBCTSxHQW9GSmxCLGFBcEZJLENBb0JOa0IsVUFwQk07QUFBQSxVQXFCTkMsYUFyQk0sR0FvRkpuQixhQXBGSSxDQXFCTm1CLGFBckJNO0FBQUEsVUFzQk5DLGVBdEJNLEdBb0ZKcEIsYUFwRkksQ0FzQk5vQixlQXRCTTtBQUFBLFVBdUJOQyxlQXZCTSxHQW9GSnJCLGFBcEZJLENBdUJOcUIsZUF2Qk07QUFBQSxVQXdCTkMsa0JBeEJNLEdBb0ZKdEIsYUFwRkksQ0F3Qk5zQixrQkF4Qk07QUFBQSxVQXlCTkMsZUF6Qk0sR0FvRkp2QixhQXBGSSxDQXlCTnVCLGVBekJNO0FBQUEsVUEwQk5DLGNBMUJNLEdBb0ZKeEIsYUFwRkksQ0EwQk53QixjQTFCTTtBQUFBLFVBMkJOQyxlQTNCTSxHQW9GSnpCLGFBcEZJLENBMkJOeUIsZUEzQk07QUFBQSxVQTRCTkMsY0E1Qk0sR0FvRkoxQixhQXBGSSxDQTRCTjBCLGNBNUJNO0FBQUEsVUE2Qk5DLGlCQTdCTSxHQW9GSjNCLGFBcEZJLENBNkJOMkIsaUJBN0JNO0FBQUEsVUE4Qk5DLG9CQTlCTSxHQW9GSjVCLGFBcEZJLENBOEJONEIsb0JBOUJNO0FBQUEsVUErQk5DLE1BL0JNLEdBb0ZKN0IsYUFwRkksQ0ErQk42QixNQS9CTTtBQUFBLFVBZ0NOQyxXQWhDTSxHQW9GSjlCLGFBcEZJLENBZ0NOOEIsV0FoQ007QUFBQSxVQWlDTkMsVUFqQ00sR0FvRkovQixhQXBGSSxDQWlDTitCLFVBakNNO0FBQUEsVUFrQ05DLFFBbENNLEdBb0ZKaEMsYUFwRkksQ0FrQ05nQyxRQWxDTTtBQUFBLFVBbUNOQyxTQW5DTSxHQW9GSmpDLGFBcEZJLENBbUNOaUMsU0FuQ007QUFBQSxVQW9DTkMsVUFwQ00sR0FvRkpsQyxhQXBGSSxDQW9DTmtDLFVBcENNO0FBQUEsVUFzQ05DLFVBdENNLEdBb0ZKbkMsYUFwRkksQ0FzQ05tQyxVQXRDTTtBQUFBLFVBdUNOQyxXQXZDTSxHQW9GSnBDLGFBcEZJLENBdUNOb0MsV0F2Q007QUFBQSxVQXdDTkMsT0F4Q00sR0FvRkpyQyxhQXBGSSxDQXdDTnFDLE9BeENNO0FBQUEsVUF5Q05DLFVBekNNLEdBb0ZKdEMsYUFwRkksQ0F5Q05zQyxVQXpDTTtBQUFBLFVBMENOQyxhQTFDTSxHQW9GSnZDLGFBcEZJLENBMENOdUMsYUExQ007QUFBQSxVQTJDTkMsV0EzQ00sR0FvRkp4QyxhQXBGSSxDQTJDTndDLFdBM0NNO0FBQUEsVUE0Q05DLFFBNUNNLEdBb0ZKekMsYUFwRkksQ0E0Q055QyxRQTVDTTtBQUFBLFVBNkNOQyxpQkE3Q00sR0FvRkoxQyxhQXBGSSxDQTZDTjBDLGlCQTdDTTtBQUFBLFVBK0NOQyxPQS9DTSxHQW9GSjNDLGFBcEZJLENBK0NOMkMsT0EvQ007QUFBQSxVQWdETnZELFFBaERNLEdBb0ZKWSxhQXBGSSxDQWdETlosUUFoRE07QUFBQSxVQWlETkQsSUFqRE0sR0FvRkphLGFBcEZJLENBaUROYixJQWpETTtBQUFBLFVBa0RORyxNQWxETSxHQW9GSlUsYUFwRkksQ0FrRE5WLE1BbERNO0FBQUEsVUFtRE5JLFFBbkRNLEdBb0ZKTSxhQXBGSSxDQW1ETk4sUUFuRE07QUFBQSxVQW9ETkUsT0FwRE0sR0FvRkpJLGFBcEZJLENBb0ROSixPQXBETTtBQUFBLFVBcUROSixRQXJETSxHQW9GSlEsYUFwRkksQ0FxRE5SLFFBckRNO0FBQUEsVUFzRE5vRCxLQXRETSxHQW9GSjVDLGFBcEZJLENBc0RONEMsS0F0RE07QUFBQSxVQXVETkMsZ0JBdkRNLEdBb0ZKN0MsYUFwRkksQ0F1RE42QyxnQkF2RE07QUFBQSxVQXlETkMsY0F6RE0sR0FvRko5QyxhQXBGSSxDQXlETjhDLGNBekRNO0FBQUEsVUEwRE5DLGNBMURNLEdBb0ZKL0MsYUFwRkksQ0EwRE4rQyxjQTFETTtBQUFBLFVBMkROQyxjQTNETSxHQW9GSmhELGFBcEZJLENBMkROZ0QsY0EzRE07QUFBQSxVQTRETkMsZ0JBNURNLEdBb0ZKakQsYUFwRkksQ0E0RE5pRCxnQkE1RE07QUFBQSxVQTZETkMsV0E3RE0sR0FvRkpsRCxhQXBGSSxDQTZETmtELFdBN0RNO0FBQUEsVUE4RE5DLFdBOURNLEdBb0ZKbkQsYUFwRkksQ0E4RE5tRCxXQTlETTtBQUFBLFVBK0ROQyxXQS9ETSxHQW9GSnBELGFBcEZJLENBK0ROb0QsV0EvRE07QUFBQSxVQWdFTkMsY0FoRU0sR0FvRkpyRCxhQXBGSSxDQWdFTnFELGNBaEVNO0FBQUEsVUFpRU5DLG1CQWpFTSxHQW9GSnRELGFBcEZJLENBaUVOc0QsbUJBakVNO0FBQUEsVUFrRU5DLGdCQWxFTSxHQW9GSnZELGFBcEZJLENBa0VOdUQsZ0JBbEVNO0FBQUEsVUFtRU5DLFlBbkVNLEdBb0ZKeEQsYUFwRkksQ0FtRU53RCxZQW5FTTtBQUFBLFVBb0VOQyxlQXBFTSxHQW9GSnpELGFBcEZJLENBb0VOeUQsZUFwRU07QUFBQSxVQXFFTkMsZ0JBckVNLEdBb0ZKMUQsYUFwRkksQ0FxRU4wRCxnQkFyRU07QUFBQSxVQXNFTkMsaUJBdEVNLEdBb0ZKM0QsYUFwRkksQ0FzRU4yRCxpQkF0RU07QUFBQSxVQXVFTkMsbUJBdkVNLEdBb0ZKNUQsYUFwRkksQ0F1RU40RCxtQkF2RU07QUFBQSxVQXdFTkMsY0F4RU0sR0FvRko3RCxhQXBGSSxDQXdFTjZELGNBeEVNO0FBQUEsVUF5RU5DLG1CQXpFTSxHQW9GSjlELGFBcEZJLENBeUVOOEQsbUJBekVNO0FBQUEsVUEwRU5DLGVBMUVNLEdBb0ZKL0QsYUFwRkksQ0EwRU4rRCxlQTFFTTtBQUFBLFVBMkVOQyxlQTNFTSxHQW9GSmhFLGFBcEZJLENBMkVOZ0UsZUEzRU07QUFBQSxVQTZFTkMsWUE3RU0sR0FvRkpqRSxhQXBGSSxDQTZFTmlFLFlBN0VNO0FBQUEsVUE4RU5DLGlCQTlFTSxHQW9GSmxFLGFBcEZJLENBOEVOa0UsaUJBOUVNO0FBQUEsVUErRU5DLFlBL0VNLEdBb0ZKbkUsYUFwRkksQ0ErRU5tRSxZQS9FTTtBQUFBLFVBZ0ZOQyxlQWhGTSxHQW9GSnBFLGFBcEZJLENBZ0ZOb0UsZUFoRk07QUFBQSxVQWtGTkMsVUFsRk0sR0FvRkpyRSxhQXBGSSxDQWtGTnFFLFVBbEZNO0FBQUEsVUFtRk52RSxpQkFuRk0sR0FvRkpFLGFBcEZJLENBbUZORixpQkFuRk07O0FBc0ZSOztBQUNBLFVBQU13RSxXQUFXbEYsV0FBV0QsSUFBNUI7QUFDQSxVQUFNb0YsU0FBU0QsV0FBV2xGLFFBQTFCO0FBQ0EsVUFBSW9GLFdBQVczQyxTQUFTb0MsWUFBVCxHQUF3QkksV0FBV0ksS0FBWCxDQUFpQkgsUUFBakIsRUFBMkJDLE1BQTNCLENBQXZDO0FBQ0EsVUFBTUcsVUFBVSxLQUFLaEcsVUFBTCxFQUFoQjtBQUNBLFVBQU1pRyxVQUFVLGdCQUFFQyxLQUFGLENBQVFDLEtBQUtDLEdBQUwsQ0FBU0osVUFBVUYsU0FBU08sTUFBNUIsRUFBb0MsQ0FBcEMsQ0FBUixDQUFoQjs7QUFFQSxVQUFNQyxrQkFBa0JkLGtCQUFrQmUsSUFBbEIsQ0FBdUI7QUFBQSxlQUFLQyxFQUFFQyxNQUFQO0FBQUEsT0FBdkIsQ0FBeEI7QUFDQSxVQUFNQyxhQUFhbEQsY0FBY2dDLGtCQUFrQmUsSUFBbEIsQ0FBdUI7QUFBQSxlQUFLQyxFQUFFaEQsVUFBUDtBQUFBLE9BQXZCLENBQWpDOztBQUVBLFVBQU1tRCx1QkFBdUIsU0FBdkJBLG9CQUF1QixDQUFDQyxJQUFELEVBQWlDO0FBQUEsWUFBMUJDLElBQTBCLHVFQUFuQixFQUFtQjtBQUFBLFlBQWZDLEtBQWUsdUVBQVAsQ0FBQyxDQUFNOztBQUM1RCxlQUFPLENBQ0xGLEtBQUtHLEdBQUwsQ0FBUyxVQUFDQyxHQUFELEVBQU1DLENBQU4sRUFBWTtBQUNuQkg7QUFDQSxjQUFNSSxnQ0FDREYsR0FEQztBQUVKRyx3QkFBWUw7QUFGUixZQUFOO0FBSUEsY0FBTU0sVUFBVVAsS0FBS1EsTUFBTCxDQUFZLENBQUNKLENBQUQsQ0FBWixDQUFoQjtBQUNBLGNBQUlDLGlCQUFpQnRELFVBQWpCLEtBQWdDLGdCQUFFMEQsR0FBRixDQUFNeEcsUUFBTixFQUFnQnNHLE9BQWhCLENBQXBDLEVBQThEO0FBQzVEO0FBRDRELHdDQUNuQlQscUJBQ3ZDTyxpQkFBaUJ0RCxVQUFqQixDQUR1QyxFQUV2Q3dELE9BRnVDLEVBR3ZDTixLQUh1QyxDQURtQjs7QUFBQTs7QUFDMURJLDZCQUFpQnRELFVBQWpCLENBRDBEO0FBQzVCa0QsaUJBRDRCO0FBTTdEO0FBQ0QsaUJBQU9JLGdCQUFQO0FBQ0QsU0FmRCxDQURLLEVBaUJMSixLQWpCSyxDQUFQO0FBbUJELE9BcEJEO0FBaEdRLG1DQXFITUgscUJBQXFCYixRQUFyQixDQXJITjs7QUFBQTs7QUFxSE5BLGNBckhNOzs7QUF1SFIsVUFBTXlCLGNBQWM5RyxPQUFPLENBQTNCO0FBQ0EsVUFBTStHLFVBQVUvRyxPQUFPLENBQVAsR0FBV3lELEtBQTNCOztBQUVBLFVBQU11RCxjQUFjLGdCQUFFQyxHQUFGLENBQ2xCbEMsa0JBQWtCdUIsR0FBbEIsQ0FBc0IsYUFBSztBQUN6QixZQUFNWSxnQkFBZ0J6RyxRQUFRMEcsSUFBUixDQUFhO0FBQUEsaUJBQUtDLEVBQUVDLEVBQUYsS0FBU3RCLEVBQUVzQixFQUFoQjtBQUFBLFNBQWIsS0FBb0MsRUFBMUQ7QUFDQSxlQUFPLGdCQUFFQyxlQUFGLENBQWtCSixjQUFjSyxLQUFoQyxFQUF1Q3hCLEVBQUV5QixLQUF6QyxFQUFnRHpCLEVBQUUwQixRQUFsRCxDQUFQO0FBQ0QsT0FIRCxDQURrQixDQUFwQjs7QUFPQSxVQUFJQyxXQUFXLENBQUMsQ0FBaEI7O0FBRUEsVUFBTUMsMEJBQ0Q5RyxhQURDO0FBRUpzRSwwQkFGSTtBQUdKQyxzQkFISTtBQUlKQywwQkFKSTtBQUtKRSx3QkFMSTtBQU1KQyx3QkFOSTtBQU9KSyx3Q0FQSTtBQVFKaUIsZ0NBUkk7QUFTSkMsd0JBVEk7QUFVSkM7QUFWSSxRQUFOOztBQWFBOztBQUVBLFVBQU1ZLG1CQUFtQixTQUFuQkEsZ0JBQW1CLEdBQU07QUFDN0IsWUFBTUMsa0JBQWtCLGdCQUFFQyxVQUFGLENBQ3RCM0csbUJBQW1Cd0csVUFBbkIsRUFBK0JJLFNBQS9CLEVBQTBDQSxTQUExQyxTQURzQixDQUF4QjtBQUdBLFlBQU1DLG9CQUFvQixnQkFBRUYsVUFBRixDQUN4QjFHLHFCQUFxQnVHLFVBQXJCLEVBQWlDSSxTQUFqQyxFQUE0Q0EsU0FBNUMsU0FEd0IsQ0FBMUI7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXLDBCQUFXLGVBQVgsRUFBNEJGLGdCQUFnQjlHLFNBQTVDLENBRGI7QUFFRSxnQ0FDSzhHLGdCQUFnQjdHLEtBRHJCO0FBRUV5Ryx3QkFBYVQsV0FBYjtBQUZGO0FBRkYsYUFNTWEsZ0JBQWdCSSxJQU50QjtBQVFFO0FBQUMsdUJBQUQ7QUFBQTtBQUNFLHlCQUFXRCxrQkFBa0JqSCxTQUQvQjtBQUVFLHFCQUFPaUgsa0JBQWtCaEg7QUFGM0IsZUFHTWdILGtCQUFrQkMsSUFIeEI7QUFLR2pELHlCQUFhc0IsR0FBYixDQUFpQjRCLGVBQWpCO0FBTEg7QUFSRixTQURGO0FBa0JELE9BekJEOztBQTJCQSxVQUFNQSxrQkFBa0IsU0FBbEJBLGVBQWtCLENBQUNDLE1BQUQsRUFBUzNCLENBQVQsRUFBZTtBQUNyQyxZQUFNNEIsZUFBZSxTQUFmQSxZQUFlO0FBQUEsaUJBQ25CLENBQUMzSCxRQUFRMEcsSUFBUixDQUFhO0FBQUEsbUJBQUtDLEVBQUVDLEVBQUYsS0FBU2dCLElBQUloQixFQUFsQjtBQUFBLFdBQWIsS0FBc0MsRUFBdkMsRUFBMkNFLEtBRHhCO0FBQUEsU0FBckI7QUFFQSxZQUFNZSxPQUFPLGdCQUFFckIsR0FBRixDQUNYa0IsT0FBT0ksT0FBUCxDQUFlakMsR0FBZixDQUNFO0FBQUEsaUJBQVErQixJQUFJYixLQUFKLElBQWFZLGFBQWFDLEdBQWIsQ0FBYixHQUFpQyxDQUFqQyxHQUFxQ0EsSUFBSVosUUFBakQ7QUFBQSxTQURGLENBRFcsQ0FBYjtBQUtBLFlBQU1ELFFBQVEsZ0JBQUVQLEdBQUYsQ0FDWmtCLE9BQU9JLE9BQVAsQ0FBZWpDLEdBQWYsQ0FBbUI7QUFBQSxpQkFDakIsZ0JBQUVnQixlQUFGLENBQWtCYyxhQUFhQyxHQUFiLENBQWxCLEVBQXFDQSxJQUFJYixLQUF6QyxFQUFnRGEsSUFBSVosUUFBcEQsQ0FEaUI7QUFBQSxTQUFuQixDQURZLENBQWQ7QUFLQSxZQUFNZSxXQUFXLGdCQUFFdkIsR0FBRixDQUNma0IsT0FBT0ksT0FBUCxDQUFlakMsR0FBZixDQUFtQjtBQUFBLGlCQUNqQixnQkFBRWdCLGVBQUYsQ0FBa0JjLGFBQWFDLEdBQWIsQ0FBbEIsRUFBcUNBLElBQUliLEtBQXpDLEVBQWdEYSxJQUFJRyxRQUFwRCxDQURpQjtBQUFBLFNBQW5CLENBRGUsQ0FBakI7O0FBTUEsWUFBTUMsb0JBQW9CLGdCQUFFWCxVQUFGLENBQ3hCekcscUJBQXFCc0csVUFBckIsRUFBaUNJLFNBQWpDLEVBQTRDSSxNQUE1QyxTQUR3QixDQUExQjtBQUdBLFlBQU1PLG9CQUFvQixnQkFBRVosVUFBRixDQUN4QkssT0FBT1EsY0FBUCxDQUFzQmhCLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0ksTUFBN0MsU0FEd0IsQ0FBMUI7O0FBSUEsWUFBTVMsVUFBVSxDQUNkVCxPQUFPVSxlQURPLEVBRWRKLGtCQUFrQjFILFNBRkosRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRUROLGtCQUFrQnpILEtBRmpCLEVBR0QwSCxrQkFBa0IxSCxLQUhqQixDQUFOOztBQU1BLFlBQU1pSCxvQkFDRFEsa0JBQWtCUixJQURqQixFQUVEUyxrQkFBa0JULElBRmpCLENBQU47O0FBS0EsWUFBTWUsYUFBYTtBQUNqQlYsZ0JBQVNBLElBQVQsWUFEaUI7QUFFakJkLGlCQUFPLGdCQUFFeUIsSUFBRixDQUFPekIsS0FBUCxDQUZVO0FBR2pCZ0Isb0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUhPLFNBQW5COztBQU1BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUtoQyxJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLENBRmI7QUFHRSxnQ0FDS0UsTUFETCxFQUVLRSxVQUZMO0FBSEYsYUFPTWYsSUFQTjtBQVNHLDBCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9nQixNQUE1QixFQUFvQztBQUNuQ0Msa0JBQU1sRSxVQUQ2QjtBQUVuQ2lELG9CQUFRQTtBQUYyQixXQUFwQztBQVRILFNBREY7QUFnQkQsT0FqRUQ7O0FBbUVBLFVBQU1rQixjQUFjLFNBQWRBLFdBQWMsR0FBTTtBQUN4QixZQUFNQyxhQUFhLGdCQUFFeEIsVUFBRixDQUNqQnhHLGNBQWNxRyxVQUFkLEVBQTBCSSxTQUExQixFQUFxQ0EsU0FBckMsU0FEaUIsQ0FBbkI7QUFHQSxZQUFNd0IsZUFBZSxnQkFBRXpCLFVBQUYsQ0FDbkJ2RyxnQkFBZ0JvRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNBLFNBQXZDLFNBRG1CLENBQXJCO0FBR0EsZUFDRTtBQUFDLHdCQUFEO0FBQUE7QUFDRSx1QkFBVywwQkFBVyxTQUFYLEVBQXNCdUIsV0FBV3ZJLFNBQWpDLENBRGI7QUFFRSxnQ0FDS3VJLFdBQVd0SSxLQURoQjtBQUVFeUcsd0JBQWFULFdBQWI7QUFGRjtBQUZGLGFBTU1zQyxXQUFXckIsSUFOakI7QUFRRTtBQUFDLHVCQUFEO0FBQUE7QUFDRSx5QkFBV3NCLGFBQWF4SSxTQUQxQjtBQUVFLHFCQUFPd0ksYUFBYXZJO0FBRnRCLGVBR011SSxhQUFhdEIsSUFIbkI7QUFLR2xELDhCQUFrQnVCLEdBQWxCLENBQXNCa0QsVUFBdEI7QUFMSDtBQVJGLFNBREY7QUFrQkQsT0F6QkQ7O0FBMkJBLFVBQU1BLGFBQWEsU0FBYkEsVUFBYSxDQUFDckIsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ2hDLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1xQyxPQUFPdkosT0FBT2dILElBQVAsQ0FBWTtBQUFBLGlCQUFLcEIsRUFBRXNCLEVBQUYsS0FBU2MsT0FBT2QsRUFBckI7QUFBQSxTQUFaLENBQWI7QUFDQSxZQUFNc0MsT0FDSixPQUFPeEIsT0FBT3dCLElBQWQsS0FBdUIsVUFBdkIsR0FBb0N4QixPQUFPd0IsSUFBUCxFQUFwQyxHQUFvRHhCLE9BQU93QixJQUQ3RDtBQUVBLFlBQU1uQyxRQUFRLGdCQUFFRixlQUFGLENBQ1ptQyxXQUFXbEMsS0FEQyxFQUVaWSxPQUFPWCxLQUZLLEVBR1pXLE9BQU9WLFFBSEssQ0FBZDtBQUtBLFlBQU1lLFdBQVcsZ0JBQUVsQixlQUFGLENBQ2ZtQyxXQUFXbEMsS0FESSxFQUVmWSxPQUFPWCxLQUZRLEVBR2ZXLE9BQU9LLFFBSFEsQ0FBakI7QUFLQSxZQUFNb0IsZUFBZSxnQkFBRTlCLFVBQUYsQ0FDbkJ0RyxnQkFBZ0JtRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNJLE1BQXZDLFNBRG1CLENBQXJCO0FBR0EsWUFBTU8sb0JBQW9CLGdCQUFFWixVQUFGLENBQ3hCSyxPQUFPUSxjQUFQLENBQXNCaEIsVUFBdEIsRUFBa0NJLFNBQWxDLEVBQTZDSSxNQUE3QyxTQUR3QixDQUExQjs7QUFJQSxZQUFNUyxVQUFVLENBQ2RULE9BQU9VLGVBRE8sRUFFZGUsYUFBYTdJLFNBRkMsRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRURhLGFBQWE1SSxLQUZaLEVBR0QwSCxrQkFBa0IxSCxLQUhqQixDQUFOOztBQU1BLFlBQU1pSCxvQkFDRDJCLGFBQWEzQixJQURaLEVBRURTLGtCQUFrQlQsSUFGakIsQ0FBTjs7QUFLQSxZQUFNNEIsY0FBYyxnQkFBRXZDLGVBQUYsQ0FBa0JhLE9BQU9yRixTQUF6QixFQUFvQ0EsU0FBcEMsRUFBK0MsS0FBL0MsQ0FBcEI7QUFDQSxZQUFNZ0gsVUFBVUQsY0FDWCw4QkFBQyxnQkFBRDtBQUNELHVCQUFhO0FBQUEsbUJBQUssT0FBS2pLLGlCQUFMLENBQXVCbUssQ0FBdkIsRUFBMEI1QixNQUExQixFQUFrQyxLQUFsQyxDQUFMO0FBQUEsV0FEWjtBQUVELHdCQUFjO0FBQUEsbUJBQUssT0FBS3ZJLGlCQUFMLENBQXVCbUssQ0FBdkIsRUFBMEI1QixNQUExQixFQUFrQyxJQUFsQyxDQUFMO0FBQUE7QUFGYixXQUdHNkIsWUFISCxFQURXLEdBTVosSUFOSjs7QUFRQSxZQUFNQyxhQUFhLGdCQUFFM0MsZUFBRixDQUFrQmEsT0FBT3RGLFFBQXpCLEVBQW1DQSxRQUFuQyxFQUE2QyxLQUE3QyxDQUFuQjs7QUFFQSxlQUNFO0FBQUMscUJBQUQ7QUFBQTtBQUNFLGlCQUFLMkQsSUFBSSxHQUFKLEdBQVUyQixPQUFPZCxFQUR4QjtBQUVFLHVCQUFXLDBCQUNUdUIsT0FEUyxFQUVULHFCQUZTLEVBR1RjLE9BQVFBLEtBQUtRLElBQUwsR0FBWSxZQUFaLEdBQTJCLFdBQW5DLEdBQWtELEVBSHpDLEVBSVRELGNBQWMsaUJBSkwsRUFLVCxDQUFDTixJQUFELElBQVMsU0FMQSxFQU1UekcsV0FDRUEsUUFBUW9DLEtBQVIsQ0FBYyxDQUFkLEVBQWlCLENBQUMsQ0FBbEIsRUFBcUI2RSxRQUFyQixDQUE4QmhDLE9BQU9kLEVBQXJDLENBREYsSUFFRSxpQkFSTyxDQUZiO0FBWUUsZ0NBQ0t5QixNQURMO0FBRUVSLG9CQUFTZCxLQUFULFlBRkY7QUFHRUEscUJBQU8sZ0JBQUV5QixJQUFGLENBQU96QixLQUFQLENBSFQ7QUFJRWdCLHdCQUFVLGdCQUFFUyxJQUFGLENBQU9ULFFBQVA7QUFKWixjQVpGO0FBa0JFLHdCQUFZLHVCQUFLO0FBQ2Z5Qiw0QkFBYyxPQUFLdkssVUFBTCxDQUFnQnlJLE1BQWhCLEVBQXdCNEIsRUFBRUssUUFBMUIsQ0FBZDtBQUNEO0FBcEJILGFBcUJNbkMsSUFyQk47QUF1QkU7QUFBQTtBQUFBLGNBQUssV0FBVSw2QkFBZjtBQUNHLDRCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9nQixNQUE1QixFQUFvQztBQUNuQ0Msb0JBQU1sRSxVQUQ2QjtBQUVuQ2lELHNCQUFRQTtBQUYyQixhQUFwQztBQURILFdBdkJGO0FBNkJHMkI7QUE3QkgsU0FERjtBQWlDRCxPQW5GRDs7QUFxRkEsVUFBTU8sY0FBYyxTQUFkQSxXQUFjLEdBQU07QUFDeEIsWUFBTUMsbUJBQW1CLGdCQUFFeEMsVUFBRixDQUN2QnJHLG9CQUFvQmtHLFVBQXBCLEVBQWdDSSxTQUFoQyxFQUEyQ0EsU0FBM0MsU0FEdUIsQ0FBekI7QUFHQSxZQUFNd0MscUJBQXFCLGdCQUFFekMsVUFBRixDQUN6QnBHLHNCQUFzQmlHLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0EsU0FBN0MsU0FEeUIsQ0FBM0I7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXLDBCQUFXLFVBQVgsRUFBdUJ1QyxpQkFBaUJ2SixTQUF4QyxDQURiO0FBRUUsZ0NBQ0t1SixpQkFBaUJ0SixLQUR0QjtBQUVFeUcsd0JBQWFULFdBQWI7QUFGRjtBQUZGLGFBTU1zRCxpQkFBaUJyQyxJQU52QjtBQVFFO0FBQUMsdUJBQUQ7QUFBQTtBQUNFLHlCQUFXc0MsbUJBQW1CeEosU0FEaEM7QUFFRSxxQkFBT3dKLG1CQUFtQnZKO0FBRjVCLGVBR011SixtQkFBbUJ0QyxJQUh6QjtBQUtHbEQsOEJBQWtCdUIsR0FBbEIsQ0FBc0JrRSxVQUF0QjtBQUxIO0FBUkYsU0FERjtBQWtCRCxPQXpCRDs7QUEyQkEsVUFBTUEsYUFBYSxTQUFiQSxVQUFhLENBQUNyQyxNQUFELEVBQVMzQixDQUFULEVBQWU7QUFDaEMsWUFBTWlELGFBQWFoSixRQUFRMEcsSUFBUixDQUFhO0FBQUEsaUJBQUtDLEVBQUVDLEVBQUYsS0FBU2MsT0FBT2QsRUFBckI7QUFBQSxTQUFiLEtBQXlDLEVBQTVEO0FBQ0EsWUFBTUcsUUFBUSxnQkFBRUYsZUFBRixDQUNabUMsV0FBV2xDLEtBREMsRUFFWlksT0FBT1gsS0FGSyxFQUdaVyxPQUFPVixRQUhLLENBQWQ7QUFLQSxZQUFNZSxXQUFXLGdCQUFFbEIsZUFBRixDQUNmbUMsV0FBV2xDLEtBREksRUFFZlksT0FBT1gsS0FGUSxFQUdmVyxPQUFPSyxRQUhRLENBQWpCO0FBS0EsWUFBTWlDLHFCQUFxQixnQkFBRTNDLFVBQUYsQ0FDekJuRyxzQkFBc0JnRyxVQUF0QixFQUFrQ0ksU0FBbEMsRUFBNkNJLE1BQTdDLFNBRHlCLENBQTNCO0FBR0EsWUFBTU8sb0JBQW9CLGdCQUFFWixVQUFGLENBQ3hCSyxPQUFPUSxjQUFQLENBQXNCaEIsVUFBdEIsRUFBa0NJLFNBQWxDLEVBQTZDSSxNQUE3QyxTQUR3QixDQUExQjs7QUFJQSxZQUFNUyxVQUFVLENBQ2RULE9BQU9VLGVBRE8sRUFFZDRCLG1CQUFtQjFKLFNBRkwsRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRUQwQixtQkFBbUJ6SixLQUZsQixFQUdEMEgsa0JBQWtCMUgsS0FIakIsQ0FBTjs7QUFNQSxZQUFNaUgsb0JBQ0R3QyxtQkFBbUJ4QyxJQURsQixFQUVEUyxrQkFBa0JULElBRmpCLENBQU47O0FBS0EsWUFBTXlDLFNBQVNuSyxTQUFTNEcsSUFBVCxDQUFjO0FBQUEsaUJBQVV1RCxPQUFPckQsRUFBUCxLQUFjYyxPQUFPZCxFQUEvQjtBQUFBLFNBQWQsQ0FBZjs7QUFFQSxZQUFNc0QsMEJBQTBCeEMsT0FBT3lDLE1BQVAsSUFBaUJoRyxlQUFqRDs7QUFFQSxZQUFNaUcsZUFBZSxnQkFBRXZELGVBQUYsQ0FDbkJhLE9BQU9wRixVQURZLEVBRW5CQSxVQUZtQixFQUduQixLQUhtQixDQUFyQjs7QUFNQSxlQUNFO0FBQUMscUJBQUQ7QUFBQTtBQUNFLGlCQUFLeUQsSUFBSSxHQUFKLEdBQVUyQixPQUFPZCxFQUR4QjtBQUVFLHVCQUFXLDBCQUFXdUIsT0FBWCxDQUZiO0FBR0UsZ0NBQ0tFLE1BREw7QUFFRVIsb0JBQVNkLEtBQVQsWUFGRjtBQUdFQSxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTVAsSUFUTjtBQVdHNEMseUJBQ0csZ0JBQUUzQixrQkFBRixDQUNBeUIsdUJBREEsRUFFQTtBQUNFeEMsMEJBREY7QUFFRXVDLDBCQUZGO0FBR0VJLHNCQUFVO0FBQUEscUJBQVMsT0FBS25MLFlBQUwsQ0FBa0J3SSxNQUFsQixFQUEwQlosS0FBMUIsQ0FBVDtBQUFBO0FBSFosV0FGQSxFQU9BLHVCQUFhWSxNQUFiLENBQW9CeUMsTUFQcEIsQ0FESCxHQVVHO0FBckJOLFNBREY7QUF5QkQsT0F2RUQ7O0FBeUVBLFVBQU1HLGNBQWMsU0FBZEEsV0FBYyxDQUFDeEUsR0FBRCxFQUFNQyxDQUFOLEVBQXVCO0FBQUEsWUFBZEosSUFBYyx1RUFBUCxFQUFPOztBQUN6QyxZQUFNNEUsVUFBVTtBQUNkQyxvQkFBVTFFLElBQUlsRCxXQUFKLENBREk7QUFFZGtELGVBQUtBLEdBRlM7QUFHZEYsaUJBQU9FLElBQUlqRCxRQUFKLENBSE87QUFJZDRILHFCQUFXLEVBQUV4RCxRQUpDO0FBS2R5RCxpQkFBTy9FLEtBQUtSLE1BTEU7QUFNZHdGLHVCQUFhaEYsS0FBS1EsTUFBTCxDQUFZLENBQUNKLENBQUQsQ0FBWixDQU5DO0FBT2Q2RSxzQkFBWTlFLElBQUluRCxhQUFKLENBUEU7QUFRZGtJLDBCQUFnQi9FLElBQUloRCxpQkFBSixDQVJGO0FBU2RnSSxtQkFBU2hGLElBQUlwRCxVQUFKO0FBVEssU0FBaEI7QUFXQSxZQUFNcUksYUFBYSxnQkFBRTNFLEdBQUYsQ0FBTXhHLFFBQU4sRUFBZ0IySyxRQUFRSSxXQUF4QixDQUFuQjtBQUNBLFlBQU1LLGVBQWU1SixnQkFBZ0I4RixVQUFoQixFQUE0QnFELE9BQTVCLEVBQXFDakQsU0FBckMsU0FBckI7QUFDQSxZQUFNMkQsVUFBVSxnQkFBRTVELFVBQUYsQ0FDZGhHLFdBQVc2RixVQUFYLEVBQXVCcUQsT0FBdkIsRUFBZ0NqRCxTQUFoQyxTQURjLENBQWhCO0FBR0EsZUFDRTtBQUFDLDBCQUFEO0FBQUEscUJBQWtCLEtBQUtpRCxRQUFRSSxXQUFSLENBQW9CTyxJQUFwQixDQUF5QixHQUF6QixDQUF2QixJQUEwREYsWUFBMUQ7QUFDRTtBQUFDLHVCQUFEO0FBQUE7QUFDRSx5QkFBVywwQkFDVEMsUUFBUTNLLFNBREMsRUFFVHdGLElBQUlHLFVBQUosR0FBaUIsQ0FBakIsR0FBcUIsT0FBckIsR0FBK0IsTUFGdEIsQ0FEYjtBQUtFLHFCQUFPZ0YsUUFBUTFLO0FBTGpCLGVBTU0wSyxRQUFRekQsSUFOZDtBQVFHbEQsOEJBQWtCdUIsR0FBbEIsQ0FBc0IsVUFBQzZCLE1BQUQsRUFBU3lELEVBQVQsRUFBZ0I7QUFDckMsa0JBQU1uQyxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLHVCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsZUFBYixLQUF5QyxFQUE1RDtBQUNBLGtCQUFNc0MsT0FDSixPQUFPeEIsT0FBT3dCLElBQWQsS0FBdUIsVUFBdkIsR0FBb0N4QixPQUFPd0IsSUFBUCxFQUFwQyxHQUFvRHhCLE9BQU93QixJQUQ3RDtBQUVBLGtCQUFNbkMsUUFBUSxnQkFBRUYsZUFBRixDQUNabUMsV0FBV2xDLEtBREMsRUFFWlksT0FBT1gsS0FGSyxFQUdaVyxPQUFPVixRQUhLLENBQWQ7QUFLQSxrQkFBTWUsV0FBVyxnQkFBRWxCLGVBQUYsQ0FDZm1DLFdBQVdsQyxLQURJLEVBRWZZLE9BQU9YLEtBRlEsRUFHZlcsT0FBT0ssUUFIUSxDQUFqQjtBQUtBLGtCQUFNcUQsVUFBVSxnQkFBRS9ELFVBQUYsQ0FDZC9GLFdBQVc0RixVQUFYLEVBQXVCcUQsT0FBdkIsRUFBZ0M3QyxNQUFoQyxTQURjLENBQWhCO0FBR0Esa0JBQU0yRCxjQUFjLGdCQUFFaEUsVUFBRixDQUNsQkssT0FBT2xILFFBQVAsQ0FBZ0IwRyxVQUFoQixFQUE0QnFELE9BQTVCLEVBQXFDN0MsTUFBckMsU0FEa0IsQ0FBcEI7O0FBSUEsa0JBQU1TLFVBQVUsQ0FDZGlELFFBQVE5SyxTQURNLEVBRWRvSCxPQUFPcEgsU0FGTyxFQUdkK0ssWUFBWS9LLFNBSEUsQ0FBaEI7O0FBTUEsa0JBQU0rSCxzQkFDRCtDLFFBQVE3SyxLQURQLEVBRURtSCxPQUFPbkgsS0FGTixFQUdEOEssWUFBWTlLLEtBSFgsQ0FBTjs7QUFNQSxrQkFBTStLLHdCQUNEZixPQURDO0FBRUpRLHNDQUZJO0FBR0pyRCxxQ0FBYUEsTUFBYixDQUhJO0FBSUpaLHVCQUFPeUQsUUFBUXpFLEdBQVIsQ0FBWTRCLE9BQU9kLEVBQW5CLENBSkg7QUFLSjJFLHlCQUFTN0QsT0FBTzZELE9BTFo7QUFNSkMsMEJBQVU5RCxPQUFPOEQsUUFOYjtBQU9KeEwsZ0NBUEk7QUFRSmtKLDBCQVJJO0FBU0puQyw0QkFUSTtBQVVKZ0Isa0NBVkk7QUFXSnFELGdDQVhJO0FBWUpDLHdDQVpJO0FBYUpsRCxnQ0FiSTtBQWNKRTtBQWRJLGdCQUFOOztBQWlCQSxrQkFBTXZCLFFBQVF3RSxTQUFTeEUsS0FBdkI7O0FBRUEsa0JBQUkyRSwyQkFBSjtBQUNBLGtCQUFJQyxpQkFBSjtBQUNBLGtCQUFJQyxrQkFBSjs7QUFFQSxrQkFBTUMsa0JBQWtCLFNBQWxCQSxlQUFrQixJQUFLO0FBQzNCLG9CQUFJQyxjQUFjLGdCQUFFQyxLQUFGLENBQVFsTSxRQUFSLENBQWxCO0FBQ0Esb0JBQUltTCxVQUFKLEVBQWdCO0FBQ2RjLGdDQUFjLGdCQUFFRSxHQUFGLENBQU1GLFdBQU4sRUFBbUJQLFNBQVNYLFdBQTVCLEVBQXlDLEtBQXpDLENBQWQ7QUFDRCxpQkFGRCxNQUVPO0FBQ0xrQixnQ0FBYyxnQkFBRUUsR0FBRixDQUFNRixXQUFOLEVBQW1CUCxTQUFTWCxXQUE1QixFQUF5QyxFQUF6QyxDQUFkO0FBQ0Q7O0FBRUQsdUJBQU8sT0FBS3FCLGdCQUFMLENBQ0w7QUFDRXBNLDRCQUFVaU07QUFEWixpQkFESyxFQUlMLFlBQU07QUFDSjVJLHNDQUNFQSxpQkFBaUI0SSxXQUFqQixFQUE4QlAsU0FBU1gsV0FBdkMsRUFBb0RyQixDQUFwRCxDQURGO0FBRUQsaUJBUEksQ0FBUDtBQVNELGVBakJEOztBQW1CQTtBQUNBLGtCQUFJMkMsZUFBZSxnQkFBRXhELGtCQUFGLENBQ2pCZixPQUFPd0UsSUFEVSxFQUVqQlosUUFGaUIsRUFHakJ4RSxLQUhpQixDQUFuQjs7QUFNQTtBQUNBLGtCQUFNcUYsOEJBQ0p6RSxPQUFPMEUsVUFBUCxLQUNDLENBQUMxRSxPQUFPMkUsU0FBUixHQUFvQm5JLG1CQUFwQixHQUEwQ3dELE9BQU93RSxJQURsRCxDQURGO0FBR0Esa0JBQU1JLDRCQUNKNUUsT0FBTzZFLFFBQVAsSUFBbUJ4SSxpQkFEckI7QUFFQSxrQkFBTXlJLDhCQUNKOUUsT0FBTytFLFVBQVAsSUFBcUJ6SSxtQkFEdkI7QUFFQSxrQkFBTTBJLGdDQUNKekksa0JBQ0M7QUFBQSx1QkFDQztBQUFBO0FBQUE7QUFDRSxnREFBQyx5QkFBRCxFQUErQjdGLEtBQS9CLENBREY7QUFFRSxnREFBQywyQkFBRCxFQUFpQ0EsS0FBakM7QUFGRixpQkFERDtBQUFBLGVBRkg7QUFPQSxrQkFBTXVPLHlCQUNKakYsT0FBT2tGLEtBQVAsSUFBZ0JGLDZCQURsQjs7QUFHQTtBQUNBLGtCQUFJcEIsU0FBU0MsT0FBVCxJQUFvQkQsU0FBU0UsUUFBakMsRUFBMkM7QUFDekM7QUFDQUYseUJBQVN1QixVQUFULEdBQXNCLElBQXRCO0FBQ0FwQixxQ0FBcUIsSUFBckI7QUFDQTtBQUNBLG9CQUFJSCxTQUFTQyxPQUFULElBQW9CLENBQUNELFNBQVNSLE9BQTlCLElBQXlDLENBQUNsSCxZQUE5QyxFQUE0RDtBQUMxRDBILDJCQUFTdUIsVUFBVCxHQUFzQixLQUF0QjtBQUNEO0FBQ0Y7O0FBRUQsa0JBQUl2QixTQUFTQyxPQUFiLEVBQXNCO0FBQ3BCO0FBQ0FHLDJCQUNFbkIsUUFBUXpFLEdBQVIsQ0FBWXZELFVBQVosTUFBNEJtRixPQUFPZCxFQUFuQyxJQUF5QzBFLFNBQVNSLE9BRHBEO0FBRUE7QUFDQWEsNEJBQ0VsSixRQUFRcUssT0FBUixDQUFnQnBGLE9BQU9kLEVBQXZCLElBQ0VuRSxRQUFRcUssT0FBUixDQUFnQnZDLFFBQVF6RSxHQUFSLENBQVl2RCxVQUFaLENBQWhCLENBREYsSUFDOEMrSSxTQUFTUixPQUZ6RDtBQUdBO0FBQ0Esb0JBQUlZLFFBQUosRUFBYztBQUNaO0FBQ0FPLGlDQUFlLGdCQUFFeEQsa0JBQUYsQ0FDYmtFLHNCQURhLGVBR1JyQixRQUhRO0FBSVh4RSwyQkFBT2hCLElBQUl0RCxXQUFKO0FBSkksc0JBTWJzRCxJQUFJdEQsV0FBSixDQU5hLENBQWY7QUFRRCxpQkFWRCxNQVVPLElBQUltSixTQUFKLEVBQWU7QUFDcEI7QUFDQU0saUNBQWUsZ0JBQUV4RCxrQkFBRixDQUNiMEQsMkJBRGEsRUFFYmIsUUFGYSxFQUdieEUsS0FIYSxDQUFmO0FBS0QsaUJBUE0sTUFPQTtBQUNMbUYsaUNBQWUsSUFBZjtBQUNEO0FBQ0YsZUE3QkQsTUE2Qk8sSUFBSVgsU0FBU1YsVUFBYixFQUF5QjtBQUM5QnFCLCtCQUFlLGdCQUFFeEQsa0JBQUYsQ0FDYjBELDJCQURhLEVBRWJiLFFBRmEsRUFHYnhFLEtBSGEsQ0FBZjtBQUtEOztBQUVELGtCQUFJd0UsU0FBU0UsUUFBYixFQUF1QjtBQUNyQlMsK0JBQWUsZ0JBQUV4RCxrQkFBRixDQUNiNkQseUJBRGEsRUFFYmhCLFFBRmEsRUFHYnhGLElBQUl0RCxXQUFKLENBSGEsQ0FBZjtBQUtBLG9CQUFJQyxPQUFKLEVBQWE7QUFDWCxzQkFBSTZJLFNBQVNULGNBQWIsRUFBNkI7QUFDM0JvQixtQ0FBZSxJQUFmO0FBQ0Q7QUFDRCxzQkFBSSxDQUFDWCxTQUFTUixPQUFWLElBQXFCLENBQUNsSCxZQUExQixFQUF3QztBQUN0Q3FJLG1DQUFlLElBQWY7QUFDRDtBQUNGO0FBQ0Y7O0FBRUQsa0JBQU1jLDBCQUEwQnRCLHFCQUM1QkcsZUFENEIsR0FFNUIsWUFBTSxDQUFFLENBRlo7O0FBSUE7QUFDQSxrQkFBTW9CLG1CQUFtQjtBQUN2QkMseUJBQVNGO0FBRGMsZUFBekI7O0FBSUEsa0JBQUkzQixRQUFRNUQsSUFBUixDQUFheUYsT0FBakIsRUFBMEI7QUFDeEJELGlDQUFpQkMsT0FBakIsR0FBMkIsYUFBSztBQUM5QjdCLDBCQUFRNUQsSUFBUixDQUFheUYsT0FBYixDQUFxQjNELENBQXJCLEVBQXdCO0FBQUEsMkJBQU15RCx3QkFBd0J6RCxDQUF4QixDQUFOO0FBQUEsbUJBQXhCO0FBQ0QsaUJBRkQ7QUFHRDs7QUFFRCxrQkFBSStCLFlBQVk3RCxJQUFaLENBQWlCeUYsT0FBckIsRUFBOEI7QUFDNUJELGlDQUFpQkMsT0FBakIsR0FBMkIsYUFBSztBQUM5QjVCLDhCQUFZN0QsSUFBWixDQUFpQnlGLE9BQWpCLENBQXlCM0QsQ0FBekIsRUFBNEI7QUFBQSwyQkFBTXlELHdCQUF3QnpELENBQXhCLENBQU47QUFBQSxtQkFBNUI7QUFDRCxpQkFGRDtBQUdEOztBQUVEO0FBQ0EscUJBQ0U7QUFBQywyQkFBRDtBQUFBO0FBQ0UsdUJBQUs2QixLQUFLLEdBQUwsR0FBV3pELE9BQU9kLEVBRHpCO0FBRUUsNkJBQVcsMEJBQ1R1QixPQURTLEVBRVQsQ0FBQ2UsSUFBRCxJQUFTLFFBRkEsRUFHVG9DLFNBQVN1QixVQUFULElBQXVCLGVBSGQsRUFJVCxDQUFDbkIsWUFBWUMsU0FBYixLQUEyQixVQUpsQixDQUZiO0FBUUUsc0NBQ0t0RCxNQURMO0FBRUVSLDBCQUFTZCxLQUFULFlBRkY7QUFHRUEsMkJBQU8sZ0JBQUV5QixJQUFGLENBQU96QixLQUFQLENBSFQ7QUFJRWdCLDhCQUFVLGdCQUFFUyxJQUFGLENBQU9ULFFBQVA7QUFKWjtBQVJGLG1CQWNNcUQsUUFBUTVELElBZGQsRUFlTTZELFlBQVk3RCxJQWZsQixFQWdCTXdGLGdCQWhCTjtBQWtCR2Y7QUFsQkgsZUFERjtBQXNCRCxhQWhOQTtBQVJILFdBREY7QUEyTkcxQixrQkFBUU8sT0FBUixJQUNDQyxVQURELElBRUNSLFFBQVFPLE9BQVIsQ0FBZ0JqRixHQUFoQixDQUFvQixVQUFDUCxDQUFELEVBQUlTLENBQUo7QUFBQSxtQkFDbEJ1RSxZQUFZaEYsQ0FBWixFQUFlUyxDQUFmLEVBQWtCd0UsUUFBUUksV0FBMUIsQ0FEa0I7QUFBQSxXQUFwQixDQTdOSjtBQWdPRy9HLDBCQUNDLENBQUMyRyxRQUFRTyxPQURWLElBRUNDLFVBRkQsSUFHQ25ILGFBQWEyRyxPQUFiO0FBbk9KLFNBREY7QUF1T0QsT0F4UEQ7O0FBMFBBLFVBQU0yQyxhQUFhLFNBQWJBLFVBQWEsQ0FBQ3BILEdBQUQsRUFBTUMsQ0FBTixFQUFZO0FBQzdCLFlBQU1pRixlQUFlNUosZ0JBQ25COEYsVUFEbUIsRUFFbkJJLFNBRm1CLEVBR25CQSxTQUhtQixTQUFyQjtBQU1BLFlBQU0yRCxVQUFVLGdCQUFFNUQsVUFBRixDQUNkaEcsV0FBVzZGLFVBQVgsRUFBdUJJLFNBQXZCLEVBQWtDQSxTQUFsQyxTQURjLENBQWhCO0FBR0EsZUFDRTtBQUFDLDBCQUFEO0FBQUEscUJBQWtCLEtBQUt2QixDQUF2QixJQUE4QmlGLFlBQTlCO0FBQ0U7QUFBQyx1QkFBRDtBQUFBO0FBQ0UseUJBQVcsMEJBQ1QsU0FEUyxFQUVULENBQUNwRyxTQUFTTyxNQUFULEdBQWtCWSxDQUFuQixJQUF3QixDQUF4QixHQUE0QixPQUE1QixHQUFzQyxNQUY3QixFQUdUa0YsUUFBUTNLLFNBSEMsQ0FEYjtBQU1FLHFCQUFPMkssUUFBUTFLLEtBQVIsSUFBaUI7QUFOMUI7QUFRRytELDhCQUFrQnVCLEdBQWxCLENBQXNCc0gsYUFBdEI7QUFSSDtBQURGLFNBREY7QUFjRCxPQXhCRDs7QUEwQkEsVUFBTUEsZ0JBQWdCLFNBQWhCQSxhQUFnQixDQUFDekYsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ25DLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1zQyxPQUNKLE9BQU94QixPQUFPd0IsSUFBZCxLQUF1QixVQUF2QixHQUFvQ3hCLE9BQU93QixJQUFQLEVBQXBDLEdBQW9EeEIsT0FBT3dCLElBRDdEO0FBRUEsWUFBSW5DLFFBQVEsZ0JBQUVGLGVBQUYsQ0FDVm1DLFdBQVdsQyxLQURELEVBRVZZLE9BQU9YLEtBRkcsRUFHVlcsT0FBT1YsUUFIRyxDQUFaO0FBS0EsWUFBSWEsT0FBT2QsS0FBWDtBQUNBLFlBQUlnQixXQUFXLGdCQUFFbEIsZUFBRixDQUNibUMsV0FBV2xDLEtBREUsRUFFYlksT0FBT1gsS0FGTSxFQUdiVyxPQUFPSyxRQUhNLENBQWY7QUFLQSxZQUFNcUQsVUFBVSxnQkFBRS9ELFVBQUYsQ0FDZC9GLFdBQVc0RixVQUFYLEVBQXVCSSxTQUF2QixFQUFrQ0ksTUFBbEMsU0FEYyxDQUFoQjtBQUdBLFlBQU0yRCxjQUFjLGdCQUFFaEUsVUFBRixDQUNsQkssT0FBT2xILFFBQVAsQ0FBZ0IwRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNJLE1BQXZDLFNBRGtCLENBQXBCOztBQUlBLFlBQU1TLFVBQVUsQ0FDZGlELFFBQVE5SyxTQURNLEVBRWRvSCxPQUFPcEgsU0FGTyxFQUdkK0ssWUFBWS9LLFNBSEUsQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEK0MsUUFBUTdLLEtBRFAsRUFFRG1ILE9BQU9uSCxLQUZOLEVBR0Q4SyxZQUFZOUssS0FIWCxDQUFOOztBQU1BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUt3RixJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLEVBQW9CLENBQUNlLElBQUQsSUFBUyxRQUE3QixDQUZiO0FBR0UsZ0NBQ0tiLE1BREw7QUFFRVIsb0JBQVNBLElBQVQsWUFGRjtBQUdFZCxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTXFELFFBQVE1RCxJQVRkO0FBV0csMEJBQUVpQixrQkFBRixDQUFxQnJFLGVBQXJCO0FBWEgsU0FERjtBQWVELE9BakREOztBQW1EQSxVQUFNZ0osb0JBQW9CLFNBQXBCQSxpQkFBb0IsR0FBTTtBQUM5QixZQUFNQyxhQUFhOUwsY0FBYzJGLFVBQWQsRUFBMEJJLFNBQTFCLEVBQXFDQSxTQUFyQyxTQUFuQjtBQUNBLFlBQU1nRyxlQUFlLGdCQUFFakcsVUFBRixDQUNuQjdGLGdCQUFnQjBGLFVBQWhCLEVBQTRCSSxTQUE1QixFQUF1Q0EsU0FBdkMsU0FEbUIsQ0FBckI7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXK0YsV0FBVy9NLFNBRHhCO0FBRUUsZ0NBQ0srTSxXQUFXOU0sS0FEaEI7QUFFRXlHLHdCQUFhVCxXQUFiO0FBRkY7QUFGRixhQU1NOEcsV0FBVzdGLElBTmpCO0FBUUU7QUFBQyx1QkFBRDtBQUFBO0FBQ0UseUJBQVcsMEJBQVc4RixhQUFhaE4sU0FBeEIsQ0FEYjtBQUVFLHFCQUFPZ04sYUFBYS9NO0FBRnRCLGVBR00rTSxhQUFhOUYsSUFIbkI7QUFLR2xELDhCQUFrQnVCLEdBQWxCLENBQXNCMEgsZ0JBQXRCO0FBTEg7QUFSRixTQURGO0FBa0JELE9BdkJEOztBQXlCQSxVQUFNQSxtQkFBbUIsU0FBbkJBLGdCQUFtQixDQUFDN0YsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ3RDLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1zQyxPQUNKLE9BQU94QixPQUFPd0IsSUFBZCxLQUF1QixVQUF2QixHQUFvQ3hCLE9BQU93QixJQUFQLEVBQXBDLEdBQW9EeEIsT0FBT3dCLElBRDdEO0FBRUEsWUFBTW5DLFFBQVEsZ0JBQUVGLGVBQUYsQ0FDWm1DLFdBQVdsQyxLQURDLEVBRVpZLE9BQU9YLEtBRkssRUFHWlcsT0FBT1YsUUFISyxDQUFkO0FBS0EsWUFBTWUsV0FBVyxnQkFBRWxCLGVBQUYsQ0FDZm1DLFdBQVdsQyxLQURJLEVBRWZZLE9BQU9YLEtBRlEsRUFHZlcsT0FBT0ssUUFIUSxDQUFqQjtBQUtBLFlBQU15RixlQUFlLGdCQUFFbkcsVUFBRixDQUNuQjVGLGdCQUFnQnlGLFVBQWhCLEVBQTRCSSxTQUE1QixFQUF1Q0EsU0FBdkMsU0FEbUIsQ0FBckI7QUFHQSxZQUFNK0QsY0FBYyxnQkFBRWhFLFVBQUYsQ0FDbEJLLE9BQU9sSCxRQUFQLENBQWdCMEcsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDSSxNQUF2QyxTQURrQixDQUFwQjtBQUdBLFlBQU0rRixvQkFBb0IsZ0JBQUVwRyxVQUFGLENBQ3hCSyxPQUFPZ0csY0FBUCxDQUFzQnhHLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0ksTUFBN0MsU0FEd0IsQ0FBMUI7O0FBSUEsWUFBTVMsVUFBVSxDQUNkcUYsYUFBYWxOLFNBREMsRUFFZG9ILE9BQU9wSCxTQUZPLEVBR2QrSyxZQUFZL0ssU0FIRSxFQUlkbU4sa0JBQWtCbk4sU0FKSixDQUFoQjs7QUFPQSxZQUFNK0gsc0JBQ0RtRixhQUFhak4sS0FEWixFQUVEbUgsT0FBT25ILEtBRk4sRUFHRDhLLFlBQVk5SyxLQUhYLEVBSURrTixrQkFBa0JsTixLQUpqQixDQUFOOztBQU9BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUt3RixJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLEVBQW9CLENBQUNlLElBQUQsSUFBUyxRQUE3QixDQUZiO0FBR0UsZ0NBQ0tiLE1BREw7QUFFRVIsb0JBQVNkLEtBQVQsWUFGRjtBQUdFQSxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTXNELFlBQVk3RCxJQVRsQixFQVVNZ0csYUFBYWhHLElBVm5CLEVBV01pRyxrQkFBa0JqRyxJQVh4QjtBQWFHLDBCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9uQyxNQUE1QixFQUFvQztBQUNuQ29ELGtCQUFNbEUsVUFENkI7QUFFbkNpRCxvQkFBUUE7QUFGMkIsV0FBcEM7QUFiSCxTQURGO0FBb0JELE9BMUREOztBQTREQSxVQUFNaUcsaUJBQWlCLFNBQWpCQSxjQUFpQixHQUFNO0FBQzNCLFlBQU1DLGtCQUFrQixnQkFBRXZHLFVBQUYsQ0FDdEIzRixtQkFBbUJ3RixVQUFuQixFQUErQkksU0FBL0IsRUFBMENBLFNBQTFDLFNBRHNCLENBQXhCO0FBR0EsZUFDRSw4QkFBQyxtQkFBRCxlQUNNbEgsYUFETjtBQUVFLGlCQUFPNEMsS0FGVDtBQUdFLHVCQUFhcUQsV0FIZjtBQUlFLG1CQUFTQyxPQUpYO0FBS0Usd0JBQWMsT0FBS3ZILFlBTHJCO0FBTUUsNEJBQWtCLE9BQUtDLGdCQU56QjtBQU9FLHFCQUFXNE8sZ0JBQWdCdE4sU0FQN0I7QUFRRSxpQkFBT3NOLGdCQUFnQnJOO0FBUnpCLFdBU01xTixnQkFBZ0JwRyxJQVR0QixFQURGO0FBYUQsT0FqQkQ7O0FBbUJBLFVBQU1xRyxZQUFZLGdCQUFFeEcsVUFBRixDQUNoQjdHLFNBQVMwRyxVQUFULEVBQXFCSSxTQUFyQixFQUFnQ0EsU0FBaEMsRUFBMkMsSUFBM0MsQ0FEZ0IsQ0FBbEI7QUFHQSxVQUFNd0csYUFBYSxnQkFBRXpHLFVBQUYsQ0FDakI1RyxjQUFjeUcsVUFBZCxFQUEwQkksU0FBMUIsRUFBcUNBLFNBQXJDLEVBQWdELElBQWhELENBRGlCLENBQW5CO0FBR0EsVUFBTXlHLGFBQWEsZ0JBQUUxRyxVQUFGLENBQ2pCbEcsY0FBYytGLFVBQWQsRUFBMEJJLFNBQTFCLEVBQXFDQSxTQUFyQyxFQUFnRCxJQUFoRCxDQURpQixDQUFuQjtBQUdBLFVBQU0wRyxlQUFlck0sZ0JBQWdCdUYsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDQSxTQUF2QyxFQUFrRCxJQUFsRCxDQUFyQjtBQUNBLFVBQU0yRyxjQUFjck0sZUFBZXNGLFVBQWYsRUFBMkJJLFNBQTNCLEVBQXNDQSxTQUF0QyxFQUFpRCxJQUFqRCxDQUFwQjtBQUNBLFVBQU1pQyxlQUFlMUgsZ0JBQWdCcUYsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDQSxTQUF2QyxFQUFrRCxJQUFsRCxDQUFyQjs7QUFFQSxVQUFNNEcsWUFBWSxTQUFaQSxTQUFZLEdBQU07QUFDdEIsWUFBTUMsYUFBYVIsZ0JBQW5CO0FBQ0EsZUFDRTtBQUFBO0FBQUE7QUFDRSx1QkFBVywwQkFBVyxZQUFYLEVBQXlCck4sU0FBekIsRUFBb0N1TixVQUFVdk4sU0FBOUMsQ0FEYjtBQUVFLGdDQUNLQyxLQURMLEVBRUtzTixVQUFVdE4sS0FGZjtBQUZGLGFBTU1zTixVQUFVckcsSUFOaEI7QUFRRzFGLDRCQUFrQkMsaUJBQWxCLEdBQ0c7QUFBQTtBQUFBLGNBQUssV0FBVSxnQkFBZjtBQUNDb007QUFERCxXQURILEdBSUcsSUFaTjtBQWFFO0FBQUMsMEJBQUQ7QUFBQTtBQUNFLHlCQUFXLDBCQUNUTCxXQUFXeE4sU0FERixFQUVUSixvQkFBb0IsYUFBcEIsR0FBb0MsRUFGM0IsQ0FEYjtBQUtFLHFCQUFPNE4sV0FBV3ZOO0FBTHBCLGVBTU11TixXQUFXdEcsSUFOakI7QUFRR2hELDhCQUFrQjJDLGtCQUFsQixHQUF1QyxJQVIxQztBQVNHeUIseUJBVEg7QUFVR3BELHlCQUFhb0UsYUFBYixHQUE2QixJQVZoQztBQVdFO0FBQUMsNEJBQUQ7QUFBQTtBQUNFLDJCQUFXLDBCQUFXbUUsV0FBV3pOLFNBQXRCLENBRGI7QUFFRSxvQ0FDS3lOLFdBQVd4TixLQURoQjtBQUVFeUcsNEJBQWFULFdBQWI7QUFGRjtBQUZGLGlCQU1Nd0gsV0FBV3ZHLElBTmpCO0FBUUc1Qyx1QkFBU2lCLEdBQVQsQ0FBYSxVQUFDUCxDQUFELEVBQUlTLENBQUo7QUFBQSx1QkFBVXVFLFlBQVloRixDQUFaLEVBQWVTLENBQWYsQ0FBVjtBQUFBLGVBQWIsQ0FSSDtBQVNHaEIsc0JBQVFjLEdBQVIsQ0FBWXFILFVBQVo7QUFUSCxhQVhGO0FBc0JHOUgsOEJBQWtCZ0ksbUJBQWxCLEdBQXdDO0FBdEIzQyxXQWJGO0FBcUNHdEwsNEJBQWtCRSxvQkFBbEIsR0FDRztBQUFBO0FBQUEsY0FBSyxXQUFVLG1CQUFmO0FBQ0NtTTtBQURELFdBREgsR0FJRyxJQXpDTjtBQTBDRyxXQUFDdkosU0FBU08sTUFBVixJQUNDO0FBQUMsMkJBQUQ7QUFBcUI4SSx1QkFBckI7QUFDRyw0QkFBRXhGLGtCQUFGLENBQXFCdEcsVUFBckI7QUFESCxXQTNDSjtBQThDRSx3Q0FBQyxnQkFBRDtBQUNFLHFCQUFTWSxPQURYO0FBRUUseUJBQWFiO0FBRmYsYUFHTThMLFlBSE47QUE5Q0YsU0FERjtBQXNERCxPQXhERDs7QUEwREE7QUFDQSxhQUFPM04sV0FBV0EsU0FBUzZHLFVBQVQsRUFBcUJnSCxTQUFyQixFQUFnQyxJQUFoQyxDQUFYLEdBQW1EQSxXQUExRDtBQUNEOzs7O0VBLzlCcUMsdUJBQVEsMENBQVIsQzs7QUFBbkIvUCxVLENBQ1ppUSxZO2tCQURZalEsVSIsImZpbGUiOiJpbmRleC5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBSZWFjdCwgeyBDb21wb25lbnQgfSBmcm9tICdyZWFjdCdcbmltcG9ydCBjbGFzc25hbWVzIGZyb20gJ2NsYXNzbmFtZXMnXG4vL1xuaW1wb3J0IF8gZnJvbSAnLi91dGlscydcbmltcG9ydCBMaWZlY3ljbGUgZnJvbSAnLi9saWZlY3ljbGUnXG5pbXBvcnQgTWV0aG9kcyBmcm9tICcuL21ldGhvZHMnXG5pbXBvcnQgZGVmYXVsdFByb3BzIGZyb20gJy4vZGVmYXVsdFByb3BzJ1xuXG5leHBvcnQgY29uc3QgUmVhY3RUYWJsZURlZmF1bHRzID0gZGVmYXVsdFByb3BzXG5cbmV4cG9ydCBkZWZhdWx0IGNsYXNzIFJlYWN0VGFibGUgZXh0ZW5kcyBNZXRob2RzKExpZmVjeWNsZShDb21wb25lbnQpKSB7XG4gIHN0YXRpYyBkZWZhdWx0UHJvcHMgPSBkZWZhdWx0UHJvcHNcblxuICBjb25zdHJ1Y3RvciAocHJvcHMpIHtcbiAgICBzdXBlcigpXG5cbiAgICB0aGlzLmdldFJlc29sdmVkU3RhdGUgPSB0aGlzLmdldFJlc29sdmVkU3RhdGUuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0RGF0YU1vZGVsID0gdGhpcy5nZXREYXRhTW9kZWwuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0U29ydGVkRGF0YSA9IHRoaXMuZ2V0U29ydGVkRGF0YS5iaW5kKHRoaXMpXG4gICAgdGhpcy5maXJlRmV0Y2hEYXRhID0gdGhpcy5maXJlRmV0Y2hEYXRhLmJpbmQodGhpcylcbiAgICB0aGlzLmdldFByb3BPclN0YXRlID0gdGhpcy5nZXRQcm9wT3JTdGF0ZS5iaW5kKHRoaXMpXG4gICAgdGhpcy5nZXRTdGF0ZU9yUHJvcCA9IHRoaXMuZ2V0U3RhdGVPclByb3AuYmluZCh0aGlzKVxuICAgIHRoaXMuZmlsdGVyRGF0YSA9IHRoaXMuZmlsdGVyRGF0YS5iaW5kKHRoaXMpXG4gICAgdGhpcy5zb3J0RGF0YSA9IHRoaXMuc29ydERhdGEuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0TWluUm93cyA9IHRoaXMuZ2V0TWluUm93cy5iaW5kKHRoaXMpXG4gICAgdGhpcy5vblBhZ2VDaGFuZ2UgPSB0aGlzLm9uUGFnZUNoYW5nZS5iaW5kKHRoaXMpXG4gICAgdGhpcy5vblBhZ2VTaXplQ2hhbmdlID0gdGhpcy5vblBhZ2VTaXplQ2hhbmdlLmJpbmQodGhpcylcbiAgICB0aGlzLnNvcnRDb2x1bW4gPSB0aGlzLnNvcnRDb2x1bW4uYmluZCh0aGlzKVxuICAgIHRoaXMuZmlsdGVyQ29sdW1uID0gdGhpcy5maWx0ZXJDb2x1bW4uYmluZCh0aGlzKVxuICAgIHRoaXMucmVzaXplQ29sdW1uU3RhcnQgPSB0aGlzLnJlc2l6ZUNvbHVtblN0YXJ0LmJpbmQodGhpcylcbiAgICB0aGlzLnJlc2l6ZUNvbHVtbkVuZCA9IHRoaXMucmVzaXplQ29sdW1uRW5kLmJpbmQodGhpcylcbiAgICB0aGlzLnJlc2l6ZUNvbHVtbk1vdmluZyA9IHRoaXMucmVzaXplQ29sdW1uTW92aW5nLmJpbmQodGhpcylcblxuICAgIHRoaXMuc3RhdGUgPSB7XG4gICAgICBwYWdlOiAwLFxuICAgICAgcGFnZVNpemU6IHByb3BzLmRlZmF1bHRQYWdlU2l6ZSxcbiAgICAgIHNvcnRlZDogcHJvcHMuZGVmYXVsdFNvcnRlZCxcbiAgICAgIGV4cGFuZGVkOiBwcm9wcy5kZWZhdWx0RXhwYW5kZWQsXG4gICAgICBmaWx0ZXJlZDogcHJvcHMuZGVmYXVsdEZpbHRlcmVkLFxuICAgICAgcmVzaXplZDogcHJvcHMuZGVmYXVsdFJlc2l6ZWQsXG4gICAgICBjdXJyZW50bHlSZXNpemluZzogZmFsc2UsXG4gICAgICBza2lwTmV4dFNvcnQ6IGZhbHNlLFxuICAgIH1cbiAgfVxuXG4gIHJlbmRlciAoKSB7XG4gICAgY29uc3QgcmVzb2x2ZWRTdGF0ZSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpXG4gICAgY29uc3Qge1xuICAgICAgY2hpbGRyZW4sXG4gICAgICBjbGFzc05hbWUsXG4gICAgICBzdHlsZSxcbiAgICAgIGdldFByb3BzLFxuICAgICAgZ2V0VGFibGVQcm9wcyxcbiAgICAgIGdldFRoZWFkR3JvdXBQcm9wcyxcbiAgICAgIGdldFRoZWFkR3JvdXBUclByb3BzLFxuICAgICAgZ2V0VGhlYWRHcm91cFRoUHJvcHMsXG4gICAgICBnZXRUaGVhZFByb3BzLFxuICAgICAgZ2V0VGhlYWRUclByb3BzLFxuICAgICAgZ2V0VGhlYWRUaFByb3BzLFxuICAgICAgZ2V0VGhlYWRGaWx0ZXJQcm9wcyxcbiAgICAgIGdldFRoZWFkRmlsdGVyVHJQcm9wcyxcbiAgICAgIGdldFRoZWFkRmlsdGVyVGhQcm9wcyxcbiAgICAgIGdldFRib2R5UHJvcHMsXG4gICAgICBnZXRUckdyb3VwUHJvcHMsXG4gICAgICBnZXRUclByb3BzLFxuICAgICAgZ2V0VGRQcm9wcyxcbiAgICAgIGdldFRmb290UHJvcHMsXG4gICAgICBnZXRUZm9vdFRyUHJvcHMsXG4gICAgICBnZXRUZm9vdFRkUHJvcHMsXG4gICAgICBnZXRQYWdpbmF0aW9uUHJvcHMsXG4gICAgICBnZXRMb2FkaW5nUHJvcHMsXG4gICAgICBnZXROb0RhdGFQcm9wcyxcbiAgICAgIGdldFJlc2l6ZXJQcm9wcyxcbiAgICAgIHNob3dQYWdpbmF0aW9uLFxuICAgICAgc2hvd1BhZ2luYXRpb25Ub3AsXG4gICAgICBzaG93UGFnaW5hdGlvbkJvdHRvbSxcbiAgICAgIG1hbnVhbCxcbiAgICAgIGxvYWRpbmdUZXh0LFxuICAgICAgbm9EYXRhVGV4dCxcbiAgICAgIHNvcnRhYmxlLFxuICAgICAgcmVzaXphYmxlLFxuICAgICAgZmlsdGVyYWJsZSxcbiAgICAgIC8vIFBpdm90aW5nIFN0YXRlXG4gICAgICBwaXZvdElES2V5LFxuICAgICAgcGl2b3RWYWxLZXksXG4gICAgICBwaXZvdEJ5LFxuICAgICAgc3ViUm93c0tleSxcbiAgICAgIGFnZ3JlZ2F0ZWRLZXksXG4gICAgICBvcmlnaW5hbEtleSxcbiAgICAgIGluZGV4S2V5LFxuICAgICAgZ3JvdXBlZEJ5UGl2b3RLZXksXG4gICAgICAvLyBTdGF0ZVxuICAgICAgbG9hZGluZyxcbiAgICAgIHBhZ2VTaXplLFxuICAgICAgcGFnZSxcbiAgICAgIHNvcnRlZCxcbiAgICAgIGZpbHRlcmVkLFxuICAgICAgcmVzaXplZCxcbiAgICAgIGV4cGFuZGVkLFxuICAgICAgcGFnZXMsXG4gICAgICBvbkV4cGFuZGVkQ2hhbmdlLFxuICAgICAgLy8gQ29tcG9uZW50c1xuICAgICAgVGFibGVDb21wb25lbnQsXG4gICAgICBUaGVhZENvbXBvbmVudCxcbiAgICAgIFRib2R5Q29tcG9uZW50LFxuICAgICAgVHJHcm91cENvbXBvbmVudCxcbiAgICAgIFRyQ29tcG9uZW50LFxuICAgICAgVGhDb21wb25lbnQsXG4gICAgICBUZENvbXBvbmVudCxcbiAgICAgIFRmb290Q29tcG9uZW50LFxuICAgICAgUGFnaW5hdGlvbkNvbXBvbmVudCxcbiAgICAgIExvYWRpbmdDb21wb25lbnQsXG4gICAgICBTdWJDb21wb25lbnQsXG4gICAgICBOb0RhdGFDb21wb25lbnQsXG4gICAgICBSZXNpemVyQ29tcG9uZW50LFxuICAgICAgRXhwYW5kZXJDb21wb25lbnQsXG4gICAgICBQaXZvdFZhbHVlQ29tcG9uZW50LFxuICAgICAgUGl2b3RDb21wb25lbnQsXG4gICAgICBBZ2dyZWdhdGVkQ29tcG9uZW50LFxuICAgICAgRmlsdGVyQ29tcG9uZW50LFxuICAgICAgUGFkUm93Q29tcG9uZW50LFxuICAgICAgLy8gRGF0YSBtb2RlbFxuICAgICAgcmVzb2x2ZWREYXRhLFxuICAgICAgYWxsVmlzaWJsZUNvbHVtbnMsXG4gICAgICBoZWFkZXJHcm91cHMsXG4gICAgICBoYXNIZWFkZXJHcm91cHMsXG4gICAgICAvLyBTb3J0ZWQgRGF0YVxuICAgICAgc29ydGVkRGF0YSxcbiAgICAgIGN1cnJlbnRseVJlc2l6aW5nLFxuICAgIH0gPSByZXNvbHZlZFN0YXRlXG5cbiAgICAvLyBQYWdpbmF0aW9uXG4gICAgY29uc3Qgc3RhcnRSb3cgPSBwYWdlU2l6ZSAqIHBhZ2VcbiAgICBjb25zdCBlbmRSb3cgPSBzdGFydFJvdyArIHBhZ2VTaXplXG4gICAgbGV0IHBhZ2VSb3dzID0gbWFudWFsID8gcmVzb2x2ZWREYXRhIDogc29ydGVkRGF0YS5zbGljZShzdGFydFJvdywgZW5kUm93KVxuICAgIGNvbnN0IG1pblJvd3MgPSB0aGlzLmdldE1pblJvd3MoKVxuICAgIGNvbnN0IHBhZFJvd3MgPSBfLnJhbmdlKE1hdGgubWF4KG1pblJvd3MgLSBwYWdlUm93cy5sZW5ndGgsIDApKVxuXG4gICAgY29uc3QgaGFzQ29sdW1uRm9vdGVyID0gYWxsVmlzaWJsZUNvbHVtbnMuc29tZShkID0+IGQuRm9vdGVyKVxuICAgIGNvbnN0IGhhc0ZpbHRlcnMgPSBmaWx0ZXJhYmxlIHx8IGFsbFZpc2libGVDb2x1bW5zLnNvbWUoZCA9PiBkLmZpbHRlcmFibGUpXG5cbiAgICBjb25zdCByZWN1cnNlUm93c1ZpZXdJbmRleCA9IChyb3dzLCBwYXRoID0gW10sIGluZGV4ID0gLTEpID0+IHtcbiAgICAgIHJldHVybiBbXG4gICAgICAgIHJvd3MubWFwKChyb3csIGkpID0+IHtcbiAgICAgICAgICBpbmRleCsrXG4gICAgICAgICAgY29uc3Qgcm93V2l0aFZpZXdJbmRleCA9IHtcbiAgICAgICAgICAgIC4uLnJvdyxcbiAgICAgICAgICAgIF92aWV3SW5kZXg6IGluZGV4LFxuICAgICAgICAgIH1cbiAgICAgICAgICBjb25zdCBuZXdQYXRoID0gcGF0aC5jb25jYXQoW2ldKVxuICAgICAgICAgIGlmIChyb3dXaXRoVmlld0luZGV4W3N1YlJvd3NLZXldICYmIF8uZ2V0KGV4cGFuZGVkLCBuZXdQYXRoKSkge1xuICAgICAgICAgICAgO1tyb3dXaXRoVmlld0luZGV4W3N1YlJvd3NLZXldLCBpbmRleF0gPSByZWN1cnNlUm93c1ZpZXdJbmRleChcbiAgICAgICAgICAgICAgcm93V2l0aFZpZXdJbmRleFtzdWJSb3dzS2V5XSxcbiAgICAgICAgICAgICAgbmV3UGF0aCxcbiAgICAgICAgICAgICAgaW5kZXhcbiAgICAgICAgICAgIClcbiAgICAgICAgICB9XG4gICAgICAgICAgcmV0dXJuIHJvd1dpdGhWaWV3SW5kZXhcbiAgICAgICAgfSksXG4gICAgICAgIGluZGV4LFxuICAgICAgXVxuICAgIH1cbiAgICA7W3BhZ2VSb3dzXSA9IHJlY3Vyc2VSb3dzVmlld0luZGV4KHBhZ2VSb3dzKVxuXG4gICAgY29uc3QgY2FuUHJldmlvdXMgPSBwYWdlID4gMFxuICAgIGNvbnN0IGNhbk5leHQgPSBwYWdlICsgMSA8IHBhZ2VzXG5cbiAgICBjb25zdCByb3dNaW5XaWR0aCA9IF8uc3VtKFxuICAgICAgYWxsVmlzaWJsZUNvbHVtbnMubWFwKGQgPT4ge1xuICAgICAgICBjb25zdCByZXNpemVkQ29sdW1uID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gZC5pZCkgfHwge31cbiAgICAgICAgcmV0dXJuIF8uZ2V0Rmlyc3REZWZpbmVkKHJlc2l6ZWRDb2x1bW4udmFsdWUsIGQud2lkdGgsIGQubWluV2lkdGgpXG4gICAgICB9KVxuICAgIClcblxuICAgIGxldCByb3dJbmRleCA9IC0xXG5cbiAgICBjb25zdCBmaW5hbFN0YXRlID0ge1xuICAgICAgLi4ucmVzb2x2ZWRTdGF0ZSxcbiAgICAgIHN0YXJ0Um93LFxuICAgICAgZW5kUm93LFxuICAgICAgcGFnZVJvd3MsXG4gICAgICBtaW5Sb3dzLFxuICAgICAgcGFkUm93cyxcbiAgICAgIGhhc0NvbHVtbkZvb3RlcixcbiAgICAgIGNhblByZXZpb3VzLFxuICAgICAgY2FuTmV4dCxcbiAgICAgIHJvd01pbldpZHRoLFxuICAgIH1cblxuICAgIC8vIFZpc3VhbCBDb21wb25lbnRzXG5cbiAgICBjb25zdCBtYWtlSGVhZGVyR3JvdXBzID0gKCkgPT4ge1xuICAgICAgY29uc3QgdGhlYWRHcm91cFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEdyb3VwUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCB0aGVhZEdyb3VwVHJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VGhlYWRHcm91cFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1oZWFkZXJHcm91cHMnLCB0aGVhZEdyb3VwUHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4udGhlYWRHcm91cFByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50aGVhZEdyb3VwUHJvcHMucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXt0aGVhZEdyb3VwVHJQcm9wcy5jbGFzc05hbWV9XG4gICAgICAgICAgICBzdHlsZT17dGhlYWRHcm91cFRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGhlYWRHcm91cFRyUHJvcHMucmVzdH1cbiAgICAgICAgICA+XG4gICAgICAgICAgICB7aGVhZGVyR3JvdXBzLm1hcChtYWtlSGVhZGVyR3JvdXApfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgIDwvVGhlYWRDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlckdyb3VwID0gKGNvbHVtbiwgaSkgPT4ge1xuICAgICAgY29uc3QgcmVzaXplZFZhbHVlID0gY29sID0+XG4gICAgICAgIChyZXNpemVkLmZpbmQoeCA9PiB4LmlkID09PSBjb2wuaWQpIHx8IHt9KS52YWx1ZVxuICAgICAgY29uc3QgZmxleCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoXG4gICAgICAgICAgY29sID0+IChjb2wud2lkdGggfHwgcmVzaXplZFZhbHVlKGNvbCkgPyAwIDogY29sLm1pbldpZHRoKVxuICAgICAgICApXG4gICAgICApXG4gICAgICBjb25zdCB3aWR0aCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoY29sID0+XG4gICAgICAgICAgXy5nZXRGaXJzdERlZmluZWQocmVzaXplZFZhbHVlKGNvbCksIGNvbC53aWR0aCwgY29sLm1pbldpZHRoKVxuICAgICAgICApXG4gICAgICApXG4gICAgICBjb25zdCBtYXhXaWR0aCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoY29sID0+XG4gICAgICAgICAgXy5nZXRGaXJzdERlZmluZWQocmVzaXplZFZhbHVlKGNvbCksIGNvbC53aWR0aCwgY29sLm1heFdpZHRoKVxuICAgICAgICApXG4gICAgICApXG5cbiAgICAgIGNvbnN0IHRoZWFkR3JvdXBUaFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEdyb3VwVGhQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtbkhlYWRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0SGVhZGVyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG5cbiAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgIGNvbHVtbi5oZWFkZXJDbGFzc05hbWUsXG4gICAgICAgIHRoZWFkR3JvdXBUaFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uSGVhZGVyUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLmNvbHVtbi5oZWFkZXJTdHlsZSxcbiAgICAgICAgLi4udGhlYWRHcm91cFRoUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbkhlYWRlclByb3BzLnN0eWxlLFxuICAgICAgfVxuXG4gICAgICBjb25zdCByZXN0ID0ge1xuICAgICAgICAuLi50aGVhZEdyb3VwVGhQcm9wcy5yZXN0LFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5yZXN0LFxuICAgICAgfVxuXG4gICAgICBjb25zdCBmbGV4U3R5bGVzID0ge1xuICAgICAgICBmbGV4OiBgJHtmbGV4fSAwIGF1dG9gLFxuICAgICAgICB3aWR0aDogXy5hc1B4KHdpZHRoKSxcbiAgICAgICAgbWF4V2lkdGg6IF8uYXNQeChtYXhXaWR0aCksXG4gICAgICB9XG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUaENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3Nlcyl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIC4uLmZsZXhTdHlsZXMsXG4gICAgICAgICAgfX1cbiAgICAgICAgICB7Li4ucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIHtfLm5vcm1hbGl6ZUNvbXBvbmVudChjb2x1bW4uSGVhZGVyLCB7XG4gICAgICAgICAgICBkYXRhOiBzb3J0ZWREYXRhLFxuICAgICAgICAgICAgY29sdW1uOiBjb2x1bW4sXG4gICAgICAgICAgfSl9XG4gICAgICAgIDwvVGhDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlcnMgPSAoKSA9PiB7XG4gICAgICBjb25zdCB0aGVhZFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgdGhlYWRUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1oZWFkZXInLCB0aGVhZFByb3BzLmNsYXNzTmFtZSl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnRoZWFkUHJvcHMuc3R5bGUsXG4gICAgICAgICAgICBtaW5XaWR0aDogYCR7cm93TWluV2lkdGh9cHhgLFxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLnRoZWFkUHJvcHMucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXt0aGVhZFRyUHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgICAgc3R5bGU9e3RoZWFkVHJQcm9wcy5zdHlsZX1cbiAgICAgICAgICAgIHsuLi50aGVhZFRyUHJvcHMucmVzdH1cbiAgICAgICAgICA+XG4gICAgICAgICAgICB7YWxsVmlzaWJsZUNvbHVtbnMubWFwKG1ha2VIZWFkZXIpfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgIDwvVGhlYWRDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlciA9IChjb2x1bW4sIGkpID0+IHtcbiAgICAgIGNvbnN0IHJlc2l6ZWRDb2wgPSByZXNpemVkLmZpbmQoeCA9PiB4LmlkID09PSBjb2x1bW4uaWQpIHx8IHt9XG4gICAgICBjb25zdCBzb3J0ID0gc29ydGVkLmZpbmQoZCA9PiBkLmlkID09PSBjb2x1bW4uaWQpXG4gICAgICBjb25zdCBzaG93ID1cbiAgICAgICAgdHlwZW9mIGNvbHVtbi5zaG93ID09PSAnZnVuY3Rpb24nID8gY29sdW1uLnNob3coKSA6IGNvbHVtbi5zaG93XG4gICAgICBjb25zdCB3aWR0aCA9IF8uZ2V0Rmlyc3REZWZpbmVkKFxuICAgICAgICByZXNpemVkQ29sLnZhbHVlLFxuICAgICAgICBjb2x1bW4ud2lkdGgsXG4gICAgICAgIGNvbHVtbi5taW5XaWR0aFxuICAgICAgKVxuICAgICAgY29uc3QgbWF4V2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWF4V2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IHRoZWFkVGhQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VGhlYWRUaFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgY29sdW1uSGVhZGVyUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGNvbHVtbi5nZXRIZWFkZXJQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcblxuICAgICAgY29uc3QgY2xhc3NlcyA9IFtcbiAgICAgICAgY29sdW1uLmhlYWRlckNsYXNzTmFtZSxcbiAgICAgICAgdGhlYWRUaFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uSGVhZGVyUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLmNvbHVtbi5oZWFkZXJTdHlsZSxcbiAgICAgICAgLi4udGhlYWRUaFByb3BzLnN0eWxlLFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5zdHlsZSxcbiAgICAgIH1cblxuICAgICAgY29uc3QgcmVzdCA9IHtcbiAgICAgICAgLi4udGhlYWRUaFByb3BzLnJlc3QsXG4gICAgICAgIC4uLmNvbHVtbkhlYWRlclByb3BzLnJlc3QsXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IGlzUmVzaXphYmxlID0gXy5nZXRGaXJzdERlZmluZWQoY29sdW1uLnJlc2l6YWJsZSwgcmVzaXphYmxlLCBmYWxzZSlcbiAgICAgIGNvbnN0IHJlc2l6ZXIgPSBpc1Jlc2l6YWJsZVxuICAgICAgICA/ICg8UmVzaXplckNvbXBvbmVudFxuICAgICAgICAgIG9uTW91c2VEb3duPXtlID0+IHRoaXMucmVzaXplQ29sdW1uU3RhcnQoZSwgY29sdW1uLCBmYWxzZSl9XG4gICAgICAgICAgb25Ub3VjaFN0YXJ0PXtlID0+IHRoaXMucmVzaXplQ29sdW1uU3RhcnQoZSwgY29sdW1uLCB0cnVlKX1cbiAgICAgICAgICB7Li4ucmVzaXplclByb3BzfVxuICAgICAgICAvPilcbiAgICAgICAgOiBudWxsXG5cbiAgICAgIGNvbnN0IGlzU29ydGFibGUgPSBfLmdldEZpcnN0RGVmaW5lZChjb2x1bW4uc29ydGFibGUsIHNvcnRhYmxlLCBmYWxzZSlcblxuICAgICAgcmV0dXJuIChcbiAgICAgICAgPFRoQ29tcG9uZW50XG4gICAgICAgICAga2V5PXtpICsgJy0nICsgY29sdW1uLmlkfVxuICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgIGNsYXNzZXMsXG4gICAgICAgICAgICAncnQtcmVzaXphYmxlLWhlYWRlcicsXG4gICAgICAgICAgICBzb3J0ID8gKHNvcnQuZGVzYyA/ICctc29ydC1kZXNjJyA6ICctc29ydC1hc2MnKSA6ICcnLFxuICAgICAgICAgICAgaXNTb3J0YWJsZSAmJiAnLWN1cnNvci1wb2ludGVyJyxcbiAgICAgICAgICAgICFzaG93ICYmICctaGlkZGVuJyxcbiAgICAgICAgICAgIHBpdm90QnkgJiZcbiAgICAgICAgICAgICAgcGl2b3RCeS5zbGljZSgwLCAtMSkuaW5jbHVkZXMoY29sdW1uLmlkKSAmJlxuICAgICAgICAgICAgICAncnQtaGVhZGVyLXBpdm90J1xuICAgICAgICAgICl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIGZsZXg6IGAke3dpZHRofSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHRvZ2dsZVNvcnQ9e2UgPT4ge1xuICAgICAgICAgICAgaXNTb3J0YWJsZSAmJiB0aGlzLnNvcnRDb2x1bW4oY29sdW1uLCBlLnNoaWZ0S2V5KVxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8ZGl2IGNsYXNzTmFtZT0ncnQtcmVzaXphYmxlLWhlYWRlci1jb250ZW50Jz5cbiAgICAgICAgICAgIHtfLm5vcm1hbGl6ZUNvbXBvbmVudChjb2x1bW4uSGVhZGVyLCB7XG4gICAgICAgICAgICAgIGRhdGE6IHNvcnRlZERhdGEsXG4gICAgICAgICAgICAgIGNvbHVtbjogY29sdW1uLFxuICAgICAgICAgICAgfSl9XG4gICAgICAgICAgPC9kaXY+XG4gICAgICAgICAge3Jlc2l6ZXJ9XG4gICAgICAgIDwvVGhDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUZpbHRlcnMgPSAoKSA9PiB7XG4gICAgICBjb25zdCB0aGVhZEZpbHRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEZpbHRlclByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgdGhlYWRGaWx0ZXJUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEZpbHRlclRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1maWx0ZXJzJywgdGhlYWRGaWx0ZXJQcm9wcy5jbGFzc05hbWUpfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi50aGVhZEZpbHRlclByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50aGVhZEZpbHRlclByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17dGhlYWRGaWx0ZXJUclByb3BzLmNsYXNzTmFtZX1cbiAgICAgICAgICAgIHN0eWxlPXt0aGVhZEZpbHRlclRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGhlYWRGaWx0ZXJUclByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcChtYWtlRmlsdGVyKX1cbiAgICAgICAgICA8L1RyQ29tcG9uZW50PlxuICAgICAgICA8L1RoZWFkQ29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VGaWx0ZXIgPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IG1heFdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1heFdpZHRoXG4gICAgICApXG4gICAgICBjb25zdCB0aGVhZEZpbHRlclRoUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRoZWFkRmlsdGVyVGhQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtbkhlYWRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0SGVhZGVyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG5cbiAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgIGNvbHVtbi5oZWFkZXJDbGFzc05hbWUsXG4gICAgICAgIHRoZWFkRmlsdGVyVGhQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgIGNvbHVtbkhlYWRlclByb3BzLmNsYXNzTmFtZSxcbiAgICAgIF1cblxuICAgICAgY29uc3Qgc3R5bGVzID0ge1xuICAgICAgICAuLi5jb2x1bW4uaGVhZGVyU3R5bGUsXG4gICAgICAgIC4uLnRoZWFkRmlsdGVyVGhQcm9wcy5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uSGVhZGVyUHJvcHMuc3R5bGUsXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IHJlc3QgPSB7XG4gICAgICAgIC4uLnRoZWFkRmlsdGVyVGhQcm9wcy5yZXN0LFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5yZXN0LFxuICAgICAgfVxuXG4gICAgICBjb25zdCBmaWx0ZXIgPSBmaWx0ZXJlZC5maW5kKGZpbHRlciA9PiBmaWx0ZXIuaWQgPT09IGNvbHVtbi5pZClcblxuICAgICAgY29uc3QgUmVzb2x2ZWRGaWx0ZXJDb21wb25lbnQgPSBjb2x1bW4uRmlsdGVyIHx8IEZpbHRlckNvbXBvbmVudFxuXG4gICAgICBjb25zdCBpc0ZpbHRlcmFibGUgPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgY29sdW1uLmZpbHRlcmFibGUsXG4gICAgICAgIGZpbHRlcmFibGUsXG4gICAgICAgIGZhbHNlXG4gICAgICApXG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUaENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3Nlcyl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIGZsZXg6IGAke3dpZHRofSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi5yZXN0fVxuICAgICAgICA+XG4gICAgICAgICAge2lzRmlsdGVyYWJsZVxuICAgICAgICAgICAgPyBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgUmVzb2x2ZWRGaWx0ZXJDb21wb25lbnQsXG4gICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICBjb2x1bW4sXG4gICAgICAgICAgICAgICAgZmlsdGVyLFxuICAgICAgICAgICAgICAgIG9uQ2hhbmdlOiB2YWx1ZSA9PiB0aGlzLmZpbHRlckNvbHVtbihjb2x1bW4sIHZhbHVlKSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgZGVmYXVsdFByb3BzLmNvbHVtbi5GaWx0ZXJcbiAgICAgICAgICAgIClcbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgPC9UaENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlUGFnZVJvdyA9IChyb3csIGksIHBhdGggPSBbXSkgPT4ge1xuICAgICAgY29uc3Qgcm93SW5mbyA9IHtcbiAgICAgICAgb3JpZ2luYWw6IHJvd1tvcmlnaW5hbEtleV0sXG4gICAgICAgIHJvdzogcm93LFxuICAgICAgICBpbmRleDogcm93W2luZGV4S2V5XSxcbiAgICAgICAgdmlld0luZGV4OiArK3Jvd0luZGV4LFxuICAgICAgICBsZXZlbDogcGF0aC5sZW5ndGgsXG4gICAgICAgIG5lc3RpbmdQYXRoOiBwYXRoLmNvbmNhdChbaV0pLFxuICAgICAgICBhZ2dyZWdhdGVkOiByb3dbYWdncmVnYXRlZEtleV0sXG4gICAgICAgIGdyb3VwZWRCeVBpdm90OiByb3dbZ3JvdXBlZEJ5UGl2b3RLZXldLFxuICAgICAgICBzdWJSb3dzOiByb3dbc3ViUm93c0tleV0sXG4gICAgICB9XG4gICAgICBjb25zdCBpc0V4cGFuZGVkID0gXy5nZXQoZXhwYW5kZWQsIHJvd0luZm8ubmVzdGluZ1BhdGgpXG4gICAgICBjb25zdCB0ckdyb3VwUHJvcHMgPSBnZXRUckdyb3VwUHJvcHMoZmluYWxTdGF0ZSwgcm93SW5mbywgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgY29uc3QgdHJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VHJQcm9wcyhmaW5hbFN0YXRlLCByb3dJbmZvLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VHJHcm91cENvbXBvbmVudCBrZXk9e3Jvd0luZm8ubmVzdGluZ1BhdGguam9pbignXycpfSB7Li4udHJHcm91cFByb3BzfT5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgICAgdHJQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIHJvdy5fdmlld0luZGV4ICUgMiA/ICctZXZlbicgOiAnLW9kZCdcbiAgICAgICAgICAgICl9XG4gICAgICAgICAgICBzdHlsZT17dHJQcm9wcy5zdHlsZX1cbiAgICAgICAgICAgIHsuLi50clByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcCgoY29sdW1uLCBpMikgPT4ge1xuICAgICAgICAgICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgICAgICAgICBjb25zdCBzaG93ID1cbiAgICAgICAgICAgICAgICB0eXBlb2YgY29sdW1uLnNob3cgPT09ICdmdW5jdGlvbicgPyBjb2x1bW4uc2hvdygpIDogY29sdW1uLnNob3dcbiAgICAgICAgICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgICAgICAgICByZXNpemVkQ29sLnZhbHVlLFxuICAgICAgICAgICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgICAgICAgICAgKVxuICAgICAgICAgICAgICBjb25zdCBtYXhXaWR0aCA9IF8uZ2V0Rmlyc3REZWZpbmVkKFxuICAgICAgICAgICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgICAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICAgICAgICAgIGNvbHVtbi5tYXhXaWR0aFxuICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIGNvbnN0IHRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgICAgICAgICAgZ2V0VGRQcm9wcyhmaW5hbFN0YXRlLCByb3dJbmZvLCBjb2x1bW4sIHRoaXMpXG4gICAgICAgICAgICAgIClcbiAgICAgICAgICAgICAgY29uc3QgY29sdW1uUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgICAgICAgICAgY29sdW1uLmdldFByb3BzKGZpbmFsU3RhdGUsIHJvd0luZm8sIGNvbHVtbiwgdGhpcylcbiAgICAgICAgICAgICAgKVxuXG4gICAgICAgICAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgICAgICAgICAgdGRQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgICAgY29sdW1uLmNsYXNzTmFtZSxcbiAgICAgICAgICAgICAgICBjb2x1bW5Qcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIF1cblxuICAgICAgICAgICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgICAgICAgICAgLi4udGRQcm9wcy5zdHlsZSxcbiAgICAgICAgICAgICAgICAuLi5jb2x1bW4uc3R5bGUsXG4gICAgICAgICAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBjb25zdCBjZWxsSW5mbyA9IHtcbiAgICAgICAgICAgICAgICAuLi5yb3dJbmZvLFxuICAgICAgICAgICAgICAgIGlzRXhwYW5kZWQsXG4gICAgICAgICAgICAgICAgY29sdW1uOiB7IC4uLmNvbHVtbiB9LFxuICAgICAgICAgICAgICAgIHZhbHVlOiByb3dJbmZvLnJvd1tjb2x1bW4uaWRdLFxuICAgICAgICAgICAgICAgIHBpdm90ZWQ6IGNvbHVtbi5waXZvdGVkLFxuICAgICAgICAgICAgICAgIGV4cGFuZGVyOiBjb2x1bW4uZXhwYW5kZXIsXG4gICAgICAgICAgICAgICAgcmVzaXplZCxcbiAgICAgICAgICAgICAgICBzaG93LFxuICAgICAgICAgICAgICAgIHdpZHRoLFxuICAgICAgICAgICAgICAgIG1heFdpZHRoLFxuICAgICAgICAgICAgICAgIHRkUHJvcHMsXG4gICAgICAgICAgICAgICAgY29sdW1uUHJvcHMsXG4gICAgICAgICAgICAgICAgY2xhc3NlcyxcbiAgICAgICAgICAgICAgICBzdHlsZXMsXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBjb25zdCB2YWx1ZSA9IGNlbGxJbmZvLnZhbHVlXG5cbiAgICAgICAgICAgICAgbGV0IHVzZU9uRXhwYW5kZXJDbGlja1xuICAgICAgICAgICAgICBsZXQgaXNCcmFuY2hcbiAgICAgICAgICAgICAgbGV0IGlzUHJldmlld1xuXG4gICAgICAgICAgICAgIGNvbnN0IG9uRXhwYW5kZXJDbGljayA9IGUgPT4ge1xuICAgICAgICAgICAgICAgIGxldCBuZXdFeHBhbmRlZCA9IF8uY2xvbmUoZXhwYW5kZWQpXG4gICAgICAgICAgICAgICAgaWYgKGlzRXhwYW5kZWQpIHtcbiAgICAgICAgICAgICAgICAgIG5ld0V4cGFuZGVkID0gXy5zZXQobmV3RXhwYW5kZWQsIGNlbGxJbmZvLm5lc3RpbmdQYXRoLCBmYWxzZSlcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgbmV3RXhwYW5kZWQgPSBfLnNldChuZXdFeHBhbmRlZCwgY2VsbEluZm8ubmVzdGluZ1BhdGgsIHt9KVxuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLnNldFN0YXRlV2l0aERhdGEoXG4gICAgICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgICAgIGV4cGFuZGVkOiBuZXdFeHBhbmRlZCxcbiAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICAoKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIG9uRXhwYW5kZWRDaGFuZ2UgJiZcbiAgICAgICAgICAgICAgICAgICAgICBvbkV4cGFuZGVkQ2hhbmdlKG5ld0V4cGFuZGVkLCBjZWxsSW5mby5uZXN0aW5nUGF0aCwgZSlcbiAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAvLyBEZWZhdWx0IHRvIGEgc3RhbmRhcmQgY2VsbFxuICAgICAgICAgICAgICBsZXQgcmVzb2x2ZWRDZWxsID0gXy5ub3JtYWxpemVDb21wb25lbnQoXG4gICAgICAgICAgICAgICAgY29sdW1uLkNlbGwsXG4gICAgICAgICAgICAgICAgY2VsbEluZm8sXG4gICAgICAgICAgICAgICAgdmFsdWVcbiAgICAgICAgICAgICAgKVxuXG4gICAgICAgICAgICAgIC8vIFJlc29sdmUgUmVuZGVyZXJzXG4gICAgICAgICAgICAgIGNvbnN0IFJlc29sdmVkQWdncmVnYXRlZENvbXBvbmVudCA9XG4gICAgICAgICAgICAgICAgY29sdW1uLkFnZ3JlZ2F0ZWQgfHxcbiAgICAgICAgICAgICAgICAoIWNvbHVtbi5hZ2dyZWdhdGUgPyBBZ2dyZWdhdGVkQ29tcG9uZW50IDogY29sdW1uLkNlbGwpXG4gICAgICAgICAgICAgIGNvbnN0IFJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIGNvbHVtbi5FeHBhbmRlciB8fCBFeHBhbmRlckNvbXBvbmVudFxuICAgICAgICAgICAgICBjb25zdCBSZXNvbHZlZFBpdm90VmFsdWVDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIGNvbHVtbi5QaXZvdFZhbHVlIHx8IFBpdm90VmFsdWVDb21wb25lbnRcbiAgICAgICAgICAgICAgY29uc3QgRGVmYXVsdFJlc29sdmVkUGl2b3RDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIFBpdm90Q29tcG9uZW50IHx8XG4gICAgICAgICAgICAgICAgKHByb3BzID0+XG4gICAgICAgICAgICAgICAgICA8ZGl2PlxuICAgICAgICAgICAgICAgICAgICA8UmVzb2x2ZWRFeHBhbmRlckNvbXBvbmVudCB7Li4ucHJvcHN9IC8+XG4gICAgICAgICAgICAgICAgICAgIDxSZXNvbHZlZFBpdm90VmFsdWVDb21wb25lbnQgey4uLnByb3BzfSAvPlxuICAgICAgICAgICAgICAgICAgPC9kaXY+KVxuICAgICAgICAgICAgICBjb25zdCBSZXNvbHZlZFBpdm90Q29tcG9uZW50ID1cbiAgICAgICAgICAgICAgICBjb2x1bW4uUGl2b3QgfHwgRGVmYXVsdFJlc29sdmVkUGl2b3RDb21wb25lbnRcblxuICAgICAgICAgICAgICAvLyBJcyB0aGlzIGNlbGwgZXhwYW5kYWJsZT9cbiAgICAgICAgICAgICAgaWYgKGNlbGxJbmZvLnBpdm90ZWQgfHwgY2VsbEluZm8uZXhwYW5kZXIpIHtcbiAgICAgICAgICAgICAgICAvLyBNYWtlIGl0IGV4cGFuZGFibGUgYnkgZGVmdWFsdFxuICAgICAgICAgICAgICAgIGNlbGxJbmZvLmV4cGFuZGFibGUgPSB0cnVlXG4gICAgICAgICAgICAgICAgdXNlT25FeHBhbmRlckNsaWNrID0gdHJ1ZVxuICAgICAgICAgICAgICAgIC8vIElmIHBpdm90ZWQsIGhhcyBubyBzdWJSb3dzLCBhbmQgZG9lcyBub3QgaGF2ZSBhIHN1YkNvbXBvbmVudCwgZG8gbm90IG1ha2UgZXhwYW5kYWJsZVxuICAgICAgICAgICAgICAgIGlmIChjZWxsSW5mby5waXZvdGVkICYmICFjZWxsSW5mby5zdWJSb3dzICYmICFTdWJDb21wb25lbnQpIHtcbiAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLmV4cGFuZGFibGUgPSBmYWxzZVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgIGlmIChjZWxsSW5mby5waXZvdGVkKSB7XG4gICAgICAgICAgICAgICAgLy8gSXMgdGhpcyBjb2x1bW4gYSBicmFuY2g/XG4gICAgICAgICAgICAgICAgaXNCcmFuY2ggPVxuICAgICAgICAgICAgICAgICAgcm93SW5mby5yb3dbcGl2b3RJREtleV0gPT09IGNvbHVtbi5pZCAmJiBjZWxsSW5mby5zdWJSb3dzXG4gICAgICAgICAgICAgICAgLy8gU2hvdWxkIHRoaXMgY29sdW1uIGJlIGJsYW5rP1xuICAgICAgICAgICAgICAgIGlzUHJldmlldyA9XG4gICAgICAgICAgICAgICAgICBwaXZvdEJ5LmluZGV4T2YoY29sdW1uLmlkKSA+XG4gICAgICAgICAgICAgICAgICAgIHBpdm90QnkuaW5kZXhPZihyb3dJbmZvLnJvd1twaXZvdElES2V5XSkgJiYgY2VsbEluZm8uc3ViUm93c1xuICAgICAgICAgICAgICAgIC8vIFBpdm90IENlbGwgUmVuZGVyIE92ZXJyaWRlXG4gICAgICAgICAgICAgICAgaWYgKGlzQnJhbmNoKSB7XG4gICAgICAgICAgICAgICAgICAvLyBpc1Bpdm90XG4gICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgICAgUmVzb2x2ZWRQaXZvdENvbXBvbmVudCxcbiAgICAgICAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICAgICAgIC4uLmNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiByb3dbcGl2b3RWYWxLZXldLFxuICAgICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgICAgICByb3dbcGl2b3RWYWxLZXldXG4gICAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpc1ByZXZpZXcpIHtcbiAgICAgICAgICAgICAgICAgIC8vIFNob3cgdGhlIHBpdm90IHByZXZpZXdcbiAgICAgICAgICAgICAgICAgIHJlc29sdmVkQ2VsbCA9IF8ubm9ybWFsaXplQ29tcG9uZW50KFxuICAgICAgICAgICAgICAgICAgICBSZXNvbHZlZEFnZ3JlZ2F0ZWRDb21wb25lbnQsXG4gICAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgICB2YWx1ZVxuICAgICAgICAgICAgICAgICAgKVxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICB9IGVsc2UgaWYgKGNlbGxJbmZvLmFnZ3JlZ2F0ZWQpIHtcbiAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgIFJlc29sdmVkQWdncmVnYXRlZENvbXBvbmVudCxcbiAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgdmFsdWVcbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBpZiAoY2VsbEluZm8uZXhwYW5kZXIpIHtcbiAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgIFJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQsXG4gICAgICAgICAgICAgICAgICBjZWxsSW5mbyxcbiAgICAgICAgICAgICAgICAgIHJvd1twaXZvdFZhbEtleV1cbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgICAgaWYgKHBpdm90QnkpIHtcbiAgICAgICAgICAgICAgICAgIGlmIChjZWxsSW5mby5ncm91cGVkQnlQaXZvdCkge1xuICAgICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICBpZiAoIWNlbGxJbmZvLnN1YlJvd3MgJiYgIVN1YkNvbXBvbmVudCkge1xuICAgICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgY29uc3QgcmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2sgPSB1c2VPbkV4cGFuZGVyQ2xpY2tcbiAgICAgICAgICAgICAgICA/IG9uRXhwYW5kZXJDbGlja1xuICAgICAgICAgICAgICAgIDogKCkgPT4ge31cblxuICAgICAgICAgICAgICAvLyBJZiB0aGVyZSBhcmUgbXVsdGlwbGUgb25DbGljayBldmVudHMsIG1ha2Ugc3VyZSB0aGV5IGRvbid0IG92ZXJyaWRlIGVhY2hvdGhlci4gVGhpcyBzaG91bGQgbWF5YmUgYmUgZXhwYW5kZWQgdG8gaGFuZGxlIGFsbCBmdW5jdGlvbiBhdHRyaWJ1dGVzXG4gICAgICAgICAgICAgIGNvbnN0IGludGVyYWN0aW9uUHJvcHMgPSB7XG4gICAgICAgICAgICAgICAgb25DbGljazogcmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2ssXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBpZiAodGRQcm9wcy5yZXN0Lm9uQ2xpY2spIHtcbiAgICAgICAgICAgICAgICBpbnRlcmFjdGlvblByb3BzLm9uQ2xpY2sgPSBlID0+IHtcbiAgICAgICAgICAgICAgICAgIHRkUHJvcHMucmVzdC5vbkNsaWNrKGUsICgpID0+IHJlc29sdmVkT25FeHBhbmRlckNsaWNrKGUpKVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgIGlmIChjb2x1bW5Qcm9wcy5yZXN0Lm9uQ2xpY2spIHtcbiAgICAgICAgICAgICAgICBpbnRlcmFjdGlvblByb3BzLm9uQ2xpY2sgPSBlID0+IHtcbiAgICAgICAgICAgICAgICAgIGNvbHVtblByb3BzLnJlc3Qub25DbGljayhlLCAoKSA9PiByZXNvbHZlZE9uRXhwYW5kZXJDbGljayhlKSlcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAvLyBSZXR1cm4gdGhlIGNlbGxcbiAgICAgICAgICAgICAgcmV0dXJuIChcbiAgICAgICAgICAgICAgICA8VGRDb21wb25lbnRcbiAgICAgICAgICAgICAgICAgIGtleT17aTIgKyAnLScgKyBjb2x1bW4uaWR9XG4gICAgICAgICAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoXG4gICAgICAgICAgICAgICAgICAgIGNsYXNzZXMsXG4gICAgICAgICAgICAgICAgICAgICFzaG93ICYmICdoaWRkZW4nLFxuICAgICAgICAgICAgICAgICAgICBjZWxsSW5mby5leHBhbmRhYmxlICYmICdydC1leHBhbmRhYmxlJyxcbiAgICAgICAgICAgICAgICAgICAgKGlzQnJhbmNoIHx8IGlzUHJldmlldykgJiYgJ3J0LXBpdm90J1xuICAgICAgICAgICAgICAgICAgKX1cbiAgICAgICAgICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgICAgICAgICAgZmxleDogYCR7d2lkdGh9IDAgYXV0b2AsXG4gICAgICAgICAgICAgICAgICAgIHdpZHRoOiBfLmFzUHgod2lkdGgpLFxuICAgICAgICAgICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICAgICAgICAgIH19XG4gICAgICAgICAgICAgICAgICB7Li4udGRQcm9wcy5yZXN0fVxuICAgICAgICAgICAgICAgICAgey4uLmNvbHVtblByb3BzLnJlc3R9XG4gICAgICAgICAgICAgICAgICB7Li4uaW50ZXJhY3Rpb25Qcm9wc31cbiAgICAgICAgICAgICAgICA+XG4gICAgICAgICAgICAgICAgICB7cmVzb2x2ZWRDZWxsfVxuICAgICAgICAgICAgICAgIDwvVGRDb21wb25lbnQ+XG4gICAgICAgICAgICAgIClcbiAgICAgICAgICAgIH0pfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgICAge3Jvd0luZm8uc3ViUm93cyAmJlxuICAgICAgICAgICAgaXNFeHBhbmRlZCAmJlxuICAgICAgICAgICAgcm93SW5mby5zdWJSb3dzLm1hcCgoZCwgaSkgPT5cbiAgICAgICAgICAgICAgbWFrZVBhZ2VSb3coZCwgaSwgcm93SW5mby5uZXN0aW5nUGF0aClcbiAgICAgICAgICAgICl9XG4gICAgICAgICAge1N1YkNvbXBvbmVudCAmJlxuICAgICAgICAgICAgIXJvd0luZm8uc3ViUm93cyAmJlxuICAgICAgICAgICAgaXNFeHBhbmRlZCAmJlxuICAgICAgICAgICAgU3ViQ29tcG9uZW50KHJvd0luZm8pfVxuICAgICAgICA8L1RyR3JvdXBDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZVBhZFJvdyA9IChyb3csIGkpID0+IHtcbiAgICAgIGNvbnN0IHRyR3JvdXBQcm9wcyA9IGdldFRyR3JvdXBQcm9wcyhcbiAgICAgICAgZmluYWxTdGF0ZSxcbiAgICAgICAgdW5kZWZpbmVkLFxuICAgICAgICB1bmRlZmluZWQsXG4gICAgICAgIHRoaXNcbiAgICAgIClcbiAgICAgIGNvbnN0IHRyUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VHJHcm91cENvbXBvbmVudCBrZXk9e2l9IHsuLi50ckdyb3VwUHJvcHN9PlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKFxuICAgICAgICAgICAgICAnLXBhZFJvdycsXG4gICAgICAgICAgICAgIChwYWdlUm93cy5sZW5ndGggKyBpKSAlIDIgPyAnLWV2ZW4nIDogJy1vZGQnLFxuICAgICAgICAgICAgICB0clByb3BzLmNsYXNzTmFtZVxuICAgICAgICAgICAgKX1cbiAgICAgICAgICAgIHN0eWxlPXt0clByb3BzLnN0eWxlIHx8IHt9fVxuICAgICAgICAgID5cbiAgICAgICAgICAgIHthbGxWaXNpYmxlQ29sdW1ucy5tYXAobWFrZVBhZENvbHVtbil9XG4gICAgICAgICAgPC9UckNvbXBvbmVudD5cbiAgICAgICAgPC9Uckdyb3VwQ29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VQYWRDb2x1bW4gPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgc2hvdyA9XG4gICAgICAgIHR5cGVvZiBjb2x1bW4uc2hvdyA9PT0gJ2Z1bmN0aW9uJyA/IGNvbHVtbi5zaG93KCkgOiBjb2x1bW4uc2hvd1xuICAgICAgbGV0IHdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1pbldpZHRoXG4gICAgICApXG4gICAgICBsZXQgZmxleCA9IHdpZHRoXG4gICAgICBsZXQgbWF4V2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWF4V2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IHRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRkUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCBjb2x1bW5Qcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgY29sdW1uLmdldFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuXG4gICAgICBjb25zdCBjbGFzc2VzID0gW1xuICAgICAgICB0ZFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLnRkUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbi5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICB9XG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUZENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NlcywgIXNob3cgJiYgJ2hpZGRlbicpfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi5zdHlsZXMsXG4gICAgICAgICAgICBmbGV4OiBgJHtmbGV4fSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50ZFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICB7Xy5ub3JtYWxpemVDb21wb25lbnQoUGFkUm93Q29tcG9uZW50KX1cbiAgICAgICAgPC9UZENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlQ29sdW1uRm9vdGVycyA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHRGb290UHJvcHMgPSBnZXRUZm9vdFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgY29uc3QgdEZvb3RUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUZm9vdFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGZvb3RDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e3RGb290UHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi50Rm9vdFByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50Rm9vdFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyh0Rm9vdFRyUHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICAgIHN0eWxlPXt0Rm9vdFRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udEZvb3RUclByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcChtYWtlQ29sdW1uRm9vdGVyKX1cbiAgICAgICAgICA8L1RyQ29tcG9uZW50PlxuICAgICAgICA8L1Rmb290Q29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VDb2x1bW5Gb290ZXIgPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgc2hvdyA9XG4gICAgICAgIHR5cGVvZiBjb2x1bW4uc2hvdyA9PT0gJ2Z1bmN0aW9uJyA/IGNvbHVtbi5zaG93KCkgOiBjb2x1bW4uc2hvd1xuICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IG1heFdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1heFdpZHRoXG4gICAgICApXG4gICAgICBjb25zdCB0Rm9vdFRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRmb290VGRQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtblByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0UHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCBjb2x1bW5Gb290ZXJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgY29sdW1uLmdldEZvb3RlclByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuXG4gICAgICBjb25zdCBjbGFzc2VzID0gW1xuICAgICAgICB0Rm9vdFRkUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgICBjb2x1bW4uY2xhc3NOYW1lLFxuICAgICAgICBjb2x1bW5Qcm9wcy5jbGFzc05hbWUsXG4gICAgICAgIGNvbHVtbkZvb3RlclByb3BzLmNsYXNzTmFtZSxcbiAgICAgIF1cblxuICAgICAgY29uc3Qgc3R5bGVzID0ge1xuICAgICAgICAuLi50Rm9vdFRkUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbi5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbkZvb3RlclByb3BzLnN0eWxlLFxuICAgICAgfVxuXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGRDb21wb25lbnRcbiAgICAgICAgICBrZXk9e2kgKyAnLScgKyBjb2x1bW4uaWR9XG4gICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKGNsYXNzZXMsICFzaG93ICYmICdoaWRkZW4nKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4uc3R5bGVzLFxuICAgICAgICAgICAgZmxleDogYCR7d2lkdGh9IDAgYXV0b2AsXG4gICAgICAgICAgICB3aWR0aDogXy5hc1B4KHdpZHRoKSxcbiAgICAgICAgICAgIG1heFdpZHRoOiBfLmFzUHgobWF4V2lkdGgpLFxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLmNvbHVtblByb3BzLnJlc3R9XG4gICAgICAgICAgey4uLnRGb290VGRQcm9wcy5yZXN0fVxuICAgICAgICAgIHsuLi5jb2x1bW5Gb290ZXJQcm9wcy5yZXN0fVxuICAgICAgICA+XG4gICAgICAgICAge18ubm9ybWFsaXplQ29tcG9uZW50KGNvbHVtbi5Gb290ZXIsIHtcbiAgICAgICAgICAgIGRhdGE6IHNvcnRlZERhdGEsXG4gICAgICAgICAgICBjb2x1bW46IGNvbHVtbixcbiAgICAgICAgICB9KX1cbiAgICAgICAgPC9UZENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlUGFnaW5hdGlvbiA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHBhZ2luYXRpb25Qcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0UGFnaW5hdGlvblByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgcmV0dXJuIChcbiAgICAgICAgPFBhZ2luYXRpb25Db21wb25lbnRcbiAgICAgICAgICB7Li4ucmVzb2x2ZWRTdGF0ZX1cbiAgICAgICAgICBwYWdlcz17cGFnZXN9XG4gICAgICAgICAgY2FuUHJldmlvdXM9e2NhblByZXZpb3VzfVxuICAgICAgICAgIGNhbk5leHQ9e2Nhbk5leHR9XG4gICAgICAgICAgb25QYWdlQ2hhbmdlPXt0aGlzLm9uUGFnZUNoYW5nZX1cbiAgICAgICAgICBvblBhZ2VTaXplQ2hhbmdlPXt0aGlzLm9uUGFnZVNpemVDaGFuZ2V9XG4gICAgICAgICAgY2xhc3NOYW1lPXtwYWdpbmF0aW9uUHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgIHN0eWxlPXtwYWdpbmF0aW9uUHJvcHMuc3R5bGV9XG4gICAgICAgICAgey4uLnBhZ2luYXRpb25Qcm9wcy5yZXN0fVxuICAgICAgICAvPlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IHJvb3RQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgIGdldFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgIClcbiAgICBjb25zdCB0YWJsZVByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgZ2V0VGFibGVQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICApXG4gICAgY29uc3QgdEJvZHlQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgIGdldFRib2R5UHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgKVxuICAgIGNvbnN0IGxvYWRpbmdQcm9wcyA9IGdldExvYWRpbmdQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICBjb25zdCBub0RhdGFQcm9wcyA9IGdldE5vRGF0YVByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgIGNvbnN0IHJlc2l6ZXJQcm9wcyA9IGdldFJlc2l6ZXJQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcblxuICAgIGNvbnN0IG1ha2VUYWJsZSA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHBhZ2luYXRpb24gPSBtYWtlUGFnaW5hdGlvbigpXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8ZGl2XG4gICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCdSZWFjdFRhYmxlJywgY2xhc3NOYW1lLCByb290UHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4uc3R5bGUsXG4gICAgICAgICAgICAuLi5yb290UHJvcHMuc3R5bGUsXG4gICAgICAgICAgfX1cbiAgICAgICAgICB7Li4ucm9vdFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICB7c2hvd1BhZ2luYXRpb24gJiYgc2hvd1BhZ2luYXRpb25Ub3BcbiAgICAgICAgICAgID8gPGRpdiBjbGFzc05hbWU9J3BhZ2luYXRpb24tdG9wJz5cbiAgICAgICAgICAgICAge3BhZ2luYXRpb259XG4gICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgICA8VGFibGVDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgICAgdGFibGVQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIGN1cnJlbnRseVJlc2l6aW5nID8gJ3J0LXJlc2l6aW5nJyA6ICcnXG4gICAgICAgICAgICApfVxuICAgICAgICAgICAgc3R5bGU9e3RhYmxlUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGFibGVQcm9wcy5yZXN0fVxuICAgICAgICAgID5cbiAgICAgICAgICAgIHtoYXNIZWFkZXJHcm91cHMgPyBtYWtlSGVhZGVyR3JvdXBzKCkgOiBudWxsfVxuICAgICAgICAgICAge21ha2VIZWFkZXJzKCl9XG4gICAgICAgICAgICB7aGFzRmlsdGVycyA/IG1ha2VGaWx0ZXJzKCkgOiBudWxsfVxuICAgICAgICAgICAgPFRib2R5Q29tcG9uZW50XG4gICAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyh0Qm9keVByb3BzLmNsYXNzTmFtZSl9XG4gICAgICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAgICAgLi4udEJvZHlQcm9wcy5zdHlsZSxcbiAgICAgICAgICAgICAgICBtaW5XaWR0aDogYCR7cm93TWluV2lkdGh9cHhgLFxuICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICB7Li4udEJvZHlQcm9wcy5yZXN0fVxuICAgICAgICAgICAgPlxuICAgICAgICAgICAgICB7cGFnZVJvd3MubWFwKChkLCBpKSA9PiBtYWtlUGFnZVJvdyhkLCBpKSl9XG4gICAgICAgICAgICAgIHtwYWRSb3dzLm1hcChtYWtlUGFkUm93KX1cbiAgICAgICAgICAgIDwvVGJvZHlDb21wb25lbnQ+XG4gICAgICAgICAgICB7aGFzQ29sdW1uRm9vdGVyID8gbWFrZUNvbHVtbkZvb3RlcnMoKSA6IG51bGx9XG4gICAgICAgICAgPC9UYWJsZUNvbXBvbmVudD5cbiAgICAgICAgICB7c2hvd1BhZ2luYXRpb24gJiYgc2hvd1BhZ2luYXRpb25Cb3R0b21cbiAgICAgICAgICAgID8gPGRpdiBjbGFzc05hbWU9J3BhZ2luYXRpb24tYm90dG9tJz5cbiAgICAgICAgICAgICAge3BhZ2luYXRpb259XG4gICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgICB7IXBhZ2VSb3dzLmxlbmd0aCAmJlxuICAgICAgICAgICAgPE5vRGF0YUNvbXBvbmVudCB7Li4ubm9EYXRhUHJvcHN9PlxuICAgICAgICAgICAgICB7Xy5ub3JtYWxpemVDb21wb25lbnQobm9EYXRhVGV4dCl9XG4gICAgICAgICAgICA8L05vRGF0YUNvbXBvbmVudD59XG4gICAgICAgICAgPExvYWRpbmdDb21wb25lbnRcbiAgICAgICAgICAgIGxvYWRpbmc9e2xvYWRpbmd9XG4gICAgICAgICAgICBsb2FkaW5nVGV4dD17bG9hZGluZ1RleHR9XG4gICAgICAgICAgICB7Li4ubG9hZGluZ1Byb3BzfVxuICAgICAgICAgIC8+XG4gICAgICAgIDwvZGl2PlxuICAgICAgKVxuICAgIH1cblxuICAgIC8vIGNoaWxkUHJvcHMgYXJlIG9wdGlvbmFsbHkgcGFzc2VkIHRvIGEgZnVuY3Rpb24tYXMtYS1jaGlsZFxuICAgIHJldHVybiBjaGlsZHJlbiA/IGNoaWxkcmVuKGZpbmFsU3RhdGUsIG1ha2VUYWJsZSwgdGhpcykgOiBtYWtlVGFibGUoKVxuICB9XG59XG4iXX0= - var reactRootElement = getReactRootElementInContainer(container); - var containerHasReactMarkup = reactRootElement && !!internalGetID(reactRootElement); - var containerHasNonRootReactChild = hasNonRootReactChild(container); +/***/ }), +/* 359 */ +/***/ (function(module, exports, __webpack_require__) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, 'render(...): Replacing React-rendered children with a new root ' + 'component. If you intended to update the children of this node, ' + 'you should instead have the existing children update their state ' + 'and render the new components instead of calling ReactDOM.render.') : void 0; +"use strict"; - if (!containerHasReactMarkup || reactRootElement.nextSibling) { - var rootElementSibling = reactRootElement; - while (rootElementSibling) { - if (internalGetID(rootElementSibling)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'render(): Target node has markup rendered by React, but there ' + 'are unrelated nodes as well. This is most commonly caused by ' + 'white-space inserted around server-rendered markup.') : void 0; - break; - } - rootElementSibling = rootElementSibling.nextSibling; - } - } - } - var shouldReuseMarkup = containerHasReactMarkup && !prevComponent && !containerHasNonRootReactChild; - var component = ReactMount._renderNewRootComponent(nextWrappedElement, container, shouldReuseMarkup, nextContext)._renderedComponent.getPublicInstance(); - if (callback) { - callback.call(component); - } - return component; - }, +Object.defineProperty(exports, "__esModule", { + value: true +}); - /** - * Renders a React component into the DOM in the supplied `container`. - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.render - * - * If the React component was previously rendered into `container`, this will - * perform an update on it and only mutate the DOM as necessary to reflect the - * latest React component. - * - * @param {ReactElement} nextElement Component element to render. - * @param {DOMElement} container DOM element to render into. - * @param {?function} callback function triggered on completion - * @return {ReactComponent} Component instance rendered in `container`. - */ - render: function (nextElement, container, callback) { - return ReactMount._renderSubtreeIntoContainer(null, nextElement, container, callback); - }, +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - /** - * Unmounts and destroys the React component rendered in the `container`. - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.unmountcomponentatnode - * - * @param {DOMElement} container DOM element containing a React component. - * @return {boolean} True if a component was found in and unmounted from - * `container` - */ - unmountComponentAtNode: function (container) { - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. (Strictly speaking, unmounting won't cause a - // render but we still don't expect to be in a render call here.) - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, 'unmountComponentAtNode(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from render ' + 'is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'unmountComponentAtNode(...): Target container is not a DOM element.') : _prodInvariant('40') : void 0; +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!nodeIsRenderedByOtherInstance(container), "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by another copy of React.') : void 0; - } +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - var prevComponent = getTopLevelWrapperInContainer(container); - if (!prevComponent) { - // Check if the node being unmounted was rendered by React, but isn't a - // root node. - var containerHasNonRootReactChild = hasNonRootReactChild(container); +exports.default = function (Base) { + return function (_Base) { + _inherits(_class, _Base); - // Check if the container itself is a React root node. - var isContainerReactRoot = container.nodeType === 1 && container.hasAttribute(ROOT_ATTR_NAME); + function _class() { + _classCallCheck(this, _class); - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by React and is not a top-level container. %s', isContainerReactRoot ? 'You may have accidentally passed in a React root node instead ' + 'of its container.' : 'Instead, have the parent component update its state and ' + 'rerender in order to remove this component.') : void 0; + return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments)); + } + + _createClass(_class, [{ + key: 'componentWillMount', + value: function componentWillMount() { + this.setStateWithData(this.getDataModel(this.getResolvedState())); + } + }, { + key: 'componentDidMount', + value: function componentDidMount() { + this.fireFetchData(); } + }, { + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps, nextState) { + var oldState = this.getResolvedState(); + var newState = this.getResolvedState(nextProps, nextState); + + // Do a deep compare of new and old `defaultOption` and + // if they are different reset `option = defaultOption` + var defaultableOptions = ['sorted', 'filtered', 'resized', 'expanded']; + defaultableOptions.forEach(function (x) { + var defaultName = 'default' + (x.charAt(0).toUpperCase() + x.slice(1)); + if (JSON.stringify(oldState[defaultName]) !== JSON.stringify(newState[defaultName])) { + newState[x] = newState[defaultName]; + } + }); - return false; - } - delete instancesByReactRootID[prevComponent._instance.rootID]; - ReactUpdates.batchedUpdates(unmountComponentFromNode, prevComponent, container, false); - return true; - }, + // If they change these table options, we need to reset defaults + // or else we could get into a state where the user has changed the UI + // and then disabled the ability to change it back. + // e.g. If `filterable` has changed, set `filtered = defaultFiltered` + var resettableOptions = ['sortable', 'filterable', 'resizable']; + resettableOptions.forEach(function (x) { + if (oldState[x] !== newState[x]) { + var baseName = x.replace('able', ''); + var optionName = baseName + 'ed'; + var defaultName = 'default' + (optionName.charAt(0).toUpperCase() + optionName.slice(1)); + newState[optionName] = newState[defaultName]; + } + }); - _mountImageIntoNode: function (markup, container, instance, shouldReuseMarkup, transaction) { - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'mountComponentIntoNode(...): Target container is not valid.') : _prodInvariant('41') : void 0; + // Props that trigger a data update + if (oldState.data !== newState.data || oldState.columns !== newState.columns || oldState.pivotBy !== newState.pivotBy || oldState.sorted !== newState.sorted || oldState.filtered !== newState.filtered) { + this.setStateWithData(this.getDataModel(newState)); + } + } + }, { + key: 'setStateWithData', + value: function setStateWithData(newState, cb) { + var _this2 = this; - if (shouldReuseMarkup) { - var rootElement = getReactRootElementInContainer(container); - if (ReactMarkupChecksum.canReuseMarkup(markup, rootElement)) { - ReactDOMComponentTree.precacheNode(instance, rootElement); - return; - } else { - var checksum = rootElement.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); - rootElement.removeAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + var oldState = this.getResolvedState(); + var newResolvedState = this.getResolvedState({}, newState); + var freezeWhenExpanded = newResolvedState.freezeWhenExpanded; - var rootMarkup = rootElement.outerHTML; - rootElement.setAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME, checksum); + // Default to unfrozen state - var normalizedMarkup = markup; - if (process.env.NODE_ENV !== 'production') { - // because rootMarkup is retrieved from the DOM, various normalizations - // will have occurred which will not be present in `markup`. Here, - // insert markup into a <div> or <iframe> depending on the container - // type to perform the same normalizations before comparing. - var normalizer; - if (container.nodeType === ELEMENT_NODE_TYPE) { - normalizer = document.createElement('div'); - normalizer.innerHTML = markup; - normalizedMarkup = normalizer.innerHTML; - } else { - normalizer = document.createElement('iframe'); - document.body.appendChild(normalizer); - normalizer.contentDocument.write(markup); - normalizedMarkup = normalizer.contentDocument.documentElement.outerHTML; - document.body.removeChild(normalizer); + newResolvedState.frozen = false; + + // If freezeWhenExpanded is set, check for frozen conditions + if (freezeWhenExpanded) { + // if any rows are expanded, freeze the existing data and sorting + var keys = Object.keys(newResolvedState.expanded); + for (var i = 0; i < keys.length; i++) { + if (newResolvedState.expanded[keys[i]]) { + newResolvedState.frozen = true; + break; + } } } - var diffIndex = firstDifferenceIndex(normalizedMarkup, rootMarkup); - var difference = ' (client) ' + normalizedMarkup.substring(diffIndex - 20, diffIndex + 20) + '\n (server) ' + rootMarkup.substring(diffIndex - 20, diffIndex + 20); - - !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document using server rendering but the checksum was invalid. This usually means you rendered a different component type or props on the client from the one on the server, or your render() methods are impure. React cannot handle this case due to cross-browser quirks by rendering at the document root. You should look for environment dependent code in your components and ensure the props are the same client and server side:\n%s', difference) : _prodInvariant('42', difference) : void 0; + // If the data isn't frozen and either the data or + // sorting model has changed, update the data + if (oldState.frozen && !newResolvedState.frozen || oldState.sorted !== newResolvedState.sorted || oldState.filtered !== newResolvedState.filtered || oldState.showFilters !== newResolvedState.showFilters || !newResolvedState.frozen && oldState.resolvedData !== newResolvedState.resolvedData) { + // Handle collapseOnsortedChange & collapseOnDataChange + if (oldState.sorted !== newResolvedState.sorted && this.props.collapseOnSortingChange || oldState.filtered !== newResolvedState.filtered || oldState.showFilters !== newResolvedState.showFilters || oldState.sortedData && !newResolvedState.frozen && oldState.resolvedData !== newResolvedState.resolvedData && this.props.collapseOnDataChange) { + newResolvedState.expanded = {}; + } - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(false, 'React attempted to reuse markup in a container but the ' + 'checksum was invalid. This generally means that you are ' + 'using server rendering and the markup generated on the ' + 'server was not what the client was expecting. React injected ' + 'new markup to compensate which works but you have lost many ' + 'of the benefits of server rendering. Instead, figure out ' + 'why the markup being generated is different on the client ' + 'or server:\n%s', difference) : void 0; + Object.assign(newResolvedState, this.getSortedData(newResolvedState)); } - } - } - !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document but you didn\'t use server rendering. We can\'t do this without using server rendering due to cross-browser quirks. See ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('43') : void 0; + // Set page to 0 if filters change + if (oldState.filtered !== newResolvedState.filtered) { + newResolvedState.page = 0; + } - if (transaction.useCreateElement) { - while (container.lastChild) { - container.removeChild(container.lastChild); - } - DOMLazyTree.insertTreeBefore(container, markup, null); - } else { - setInnerHTML(container, markup); - ReactDOMComponentTree.precacheNode(instance, container.firstChild); - } + // Calculate pageSize all the time + if (newResolvedState.sortedData) { + newResolvedState.pages = newResolvedState.manual ? newResolvedState.pages : Math.ceil(newResolvedState.sortedData.length / newResolvedState.pageSize); + newResolvedState.page = Math.max(newResolvedState.page >= newResolvedState.pages ? newResolvedState.pages - 1 : newResolvedState.page, 0); + } - if (process.env.NODE_ENV !== 'production') { - var hostNode = ReactDOMComponentTree.getInstanceFromNode(container.firstChild); - if (hostNode._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: hostNode._debugID, - type: 'mount', - payload: markup.toString() + return this.setState(newResolvedState, function () { + cb && cb(); + if (oldState.page !== newResolvedState.page || oldState.pageSize !== newResolvedState.pageSize || oldState.sorted !== newResolvedState.sorted || oldState.filtered !== newResolvedState.filtered) { + _this2.fireFetchData(); + } }); } - } - } -}; + }]); -module.exports = ReactMount; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return _class; + }(Base); +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9saWZlY3ljbGUuanMiXSwibmFtZXMiOlsic2V0U3RhdGVXaXRoRGF0YSIsImdldERhdGFNb2RlbCIsImdldFJlc29sdmVkU3RhdGUiLCJmaXJlRmV0Y2hEYXRhIiwibmV4dFByb3BzIiwibmV4dFN0YXRlIiwib2xkU3RhdGUiLCJuZXdTdGF0ZSIsImRlZmF1bHRhYmxlT3B0aW9ucyIsImZvckVhY2giLCJkZWZhdWx0TmFtZSIsIngiLCJjaGFyQXQiLCJ0b1VwcGVyQ2FzZSIsInNsaWNlIiwiSlNPTiIsInN0cmluZ2lmeSIsInJlc2V0dGFibGVPcHRpb25zIiwiYmFzZU5hbWUiLCJyZXBsYWNlIiwib3B0aW9uTmFtZSIsImRhdGEiLCJjb2x1bW5zIiwicGl2b3RCeSIsInNvcnRlZCIsImZpbHRlcmVkIiwiY2IiLCJuZXdSZXNvbHZlZFN0YXRlIiwiZnJlZXplV2hlbkV4cGFuZGVkIiwiZnJvemVuIiwia2V5cyIsIk9iamVjdCIsImV4cGFuZGVkIiwiaSIsImxlbmd0aCIsInNob3dGaWx0ZXJzIiwicmVzb2x2ZWREYXRhIiwicHJvcHMiLCJjb2xsYXBzZU9uU29ydGluZ0NoYW5nZSIsInNvcnRlZERhdGEiLCJjb2xsYXBzZU9uRGF0YUNoYW5nZSIsImFzc2lnbiIsImdldFNvcnRlZERhdGEiLCJwYWdlIiwicGFnZXMiLCJtYW51YWwiLCJNYXRoIiwiY2VpbCIsInBhZ2VTaXplIiwibWF4Iiwic2V0U3RhdGUiLCJCYXNlIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7OztrQkFBZTtBQUFBO0FBQUE7O0FBQUE7QUFBQTs7QUFBQTtBQUFBOztBQUFBO0FBQUE7QUFBQSwyQ0FFVztBQUNwQixhQUFLQSxnQkFBTCxDQUFzQixLQUFLQyxZQUFMLENBQWtCLEtBQUtDLGdCQUFMLEVBQWxCLENBQXRCO0FBQ0Q7QUFKVTtBQUFBO0FBQUEsMENBTVU7QUFDbkIsYUFBS0MsYUFBTDtBQUNEO0FBUlU7QUFBQTtBQUFBLGdEQVVnQkMsU0FWaEIsRUFVMkJDLFNBVjNCLEVBVXNDO0FBQy9DLFlBQU1DLFdBQVcsS0FBS0osZ0JBQUwsRUFBakI7QUFDQSxZQUFNSyxXQUFXLEtBQUtMLGdCQUFMLENBQXNCRSxTQUF0QixFQUFpQ0MsU0FBakMsQ0FBakI7O0FBRUE7QUFDQTtBQUNBLFlBQU1HLHFCQUFxQixDQUFDLFFBQUQsRUFBVyxVQUFYLEVBQXVCLFNBQXZCLEVBQWtDLFVBQWxDLENBQTNCO0FBQ0FBLDJCQUFtQkMsT0FBbkIsQ0FBMkIsYUFBSztBQUM5QixjQUFNQywyQkFBd0JDLEVBQUVDLE1BQUYsQ0FBUyxDQUFULEVBQVlDLFdBQVosS0FBNEJGLEVBQUVHLEtBQUYsQ0FBUSxDQUFSLENBQXBELENBQU47QUFDQSxjQUNFQyxLQUFLQyxTQUFMLENBQWVWLFNBQVNJLFdBQVQsQ0FBZixNQUNBSyxLQUFLQyxTQUFMLENBQWVULFNBQVNHLFdBQVQsQ0FBZixDQUZGLEVBR0U7QUFDQUgscUJBQVNJLENBQVQsSUFBY0osU0FBU0csV0FBVCxDQUFkO0FBQ0Q7QUFDRixTQVJEOztBQVVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsWUFBTU8sb0JBQW9CLENBQUMsVUFBRCxFQUFhLFlBQWIsRUFBMkIsV0FBM0IsQ0FBMUI7QUFDQUEsMEJBQWtCUixPQUFsQixDQUEwQixhQUFLO0FBQzdCLGNBQUlILFNBQVNLLENBQVQsTUFBZ0JKLFNBQVNJLENBQVQsQ0FBcEIsRUFBaUM7QUFDL0IsZ0JBQU1PLFdBQVdQLEVBQUVRLE9BQUYsQ0FBVSxNQUFWLEVBQWtCLEVBQWxCLENBQWpCO0FBQ0EsZ0JBQU1DLGFBQWdCRixRQUFoQixPQUFOO0FBQ0EsZ0JBQU1SLDJCQUF3QlUsV0FBV1IsTUFBWCxDQUFrQixDQUFsQixFQUFxQkMsV0FBckIsS0FDNUJPLFdBQVdOLEtBQVgsQ0FBaUIsQ0FBakIsQ0FESSxDQUFOO0FBRUFQLHFCQUFTYSxVQUFULElBQXVCYixTQUFTRyxXQUFULENBQXZCO0FBQ0Q7QUFDRixTQVJEOztBQVVBO0FBQ0EsWUFDRUosU0FBU2UsSUFBVCxLQUFrQmQsU0FBU2MsSUFBM0IsSUFDQWYsU0FBU2dCLE9BQVQsS0FBcUJmLFNBQVNlLE9BRDlCLElBRUFoQixTQUFTaUIsT0FBVCxLQUFxQmhCLFNBQVNnQixPQUY5QixJQUdBakIsU0FBU2tCLE1BQVQsS0FBb0JqQixTQUFTaUIsTUFIN0IsSUFJQWxCLFNBQVNtQixRQUFULEtBQXNCbEIsU0FBU2tCLFFBTGpDLEVBTUU7QUFDQSxlQUFLekIsZ0JBQUwsQ0FBc0IsS0FBS0MsWUFBTCxDQUFrQk0sUUFBbEIsQ0FBdEI7QUFDRDtBQUNGO0FBcERVO0FBQUE7QUFBQSx1Q0FzRE9BLFFBdERQLEVBc0RpQm1CLEVBdERqQixFQXNEcUI7QUFBQTs7QUFDOUIsWUFBTXBCLFdBQVcsS0FBS0osZ0JBQUwsRUFBakI7QUFDQSxZQUFNeUIsbUJBQW1CLEtBQUt6QixnQkFBTCxDQUFzQixFQUF0QixFQUEwQkssUUFBMUIsQ0FBekI7QUFGOEIsWUFHdEJxQixrQkFIc0IsR0FHQ0QsZ0JBSEQsQ0FHdEJDLGtCQUhzQjs7QUFLOUI7O0FBQ0FELHlCQUFpQkUsTUFBakIsR0FBMEIsS0FBMUI7O0FBRUE7QUFDQSxZQUFJRCxrQkFBSixFQUF3QjtBQUN0QjtBQUNBLGNBQU1FLE9BQU9DLE9BQU9ELElBQVAsQ0FBWUgsaUJBQWlCSyxRQUE3QixDQUFiO0FBQ0EsZUFBSyxJQUFJQyxJQUFJLENBQWIsRUFBZ0JBLElBQUlILEtBQUtJLE1BQXpCLEVBQWlDRCxHQUFqQyxFQUFzQztBQUNwQyxnQkFBSU4saUJBQWlCSyxRQUFqQixDQUEwQkYsS0FBS0csQ0FBTCxDQUExQixDQUFKLEVBQXdDO0FBQ3RDTiwrQkFBaUJFLE1BQWpCLEdBQTBCLElBQTFCO0FBQ0E7QUFDRDtBQUNGO0FBQ0Y7O0FBRUQ7QUFDQTtBQUNBLFlBQ0d2QixTQUFTdUIsTUFBVCxJQUFtQixDQUFDRixpQkFBaUJFLE1BQXRDLElBQ0F2QixTQUFTa0IsTUFBVCxLQUFvQkcsaUJBQWlCSCxNQURyQyxJQUVBbEIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFGdkMsSUFHQW5CLFNBQVM2QixXQUFULEtBQXlCUixpQkFBaUJRLFdBSDFDLElBSUMsQ0FBQ1IsaUJBQWlCRSxNQUFsQixJQUNDdkIsU0FBUzhCLFlBQVQsS0FBMEJULGlCQUFpQlMsWUFOL0MsRUFPRTtBQUNBO0FBQ0EsY0FDRzlCLFNBQVNrQixNQUFULEtBQW9CRyxpQkFBaUJILE1BQXJDLElBQ0MsS0FBS2EsS0FBTCxDQUFXQyx1QkFEYixJQUVBaEMsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFGdkMsSUFHQW5CLFNBQVM2QixXQUFULEtBQXlCUixpQkFBaUJRLFdBSDFDLElBSUM3QixTQUFTaUMsVUFBVCxJQUNDLENBQUNaLGlCQUFpQkUsTUFEbkIsSUFFQ3ZCLFNBQVM4QixZQUFULEtBQTBCVCxpQkFBaUJTLFlBRjVDLElBR0MsS0FBS0MsS0FBTCxDQUFXRyxvQkFSZixFQVNFO0FBQ0FiLDZCQUFpQkssUUFBakIsR0FBNEIsRUFBNUI7QUFDRDs7QUFFREQsaUJBQU9VLE1BQVAsQ0FBY2QsZ0JBQWQsRUFBZ0MsS0FBS2UsYUFBTCxDQUFtQmYsZ0JBQW5CLENBQWhDO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJckIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFBM0MsRUFBcUQ7QUFDbkRFLDJCQUFpQmdCLElBQWpCLEdBQXdCLENBQXhCO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJaEIsaUJBQWlCWSxVQUFyQixFQUFpQztBQUMvQlosMkJBQWlCaUIsS0FBakIsR0FBeUJqQixpQkFBaUJrQixNQUFqQixHQUNyQmxCLGlCQUFpQmlCLEtBREksR0FFckJFLEtBQUtDLElBQUwsQ0FDQXBCLGlCQUFpQlksVUFBakIsQ0FBNEJMLE1BQTVCLEdBQXFDUCxpQkFBaUJxQixRQUR0RCxDQUZKO0FBS0FyQiwyQkFBaUJnQixJQUFqQixHQUF3QkcsS0FBS0csR0FBTCxDQUN0QnRCLGlCQUFpQmdCLElBQWpCLElBQXlCaEIsaUJBQWlCaUIsS0FBMUMsR0FDSWpCLGlCQUFpQmlCLEtBQWpCLEdBQXlCLENBRDdCLEdBRUlqQixpQkFBaUJnQixJQUhDLEVBSXRCLENBSnNCLENBQXhCO0FBTUQ7O0FBRUQsZUFBTyxLQUFLTyxRQUFMLENBQWN2QixnQkFBZCxFQUFnQyxZQUFNO0FBQzNDRCxnQkFBTUEsSUFBTjtBQUNBLGNBQ0VwQixTQUFTcUMsSUFBVCxLQUFrQmhCLGlCQUFpQmdCLElBQW5DLElBQ0FyQyxTQUFTMEMsUUFBVCxLQUFzQnJCLGlCQUFpQnFCLFFBRHZDLElBRUExQyxTQUFTa0IsTUFBVCxLQUFvQkcsaUJBQWlCSCxNQUZyQyxJQUdBbEIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFKekMsRUFLRTtBQUNBLG1CQUFLdEIsYUFBTDtBQUNEO0FBQ0YsU0FWTSxDQUFQO0FBV0Q7QUFwSVU7O0FBQUE7QUFBQSxJQUNDZ0QsSUFERDtBQUFBLEMiLCJmaWxlIjoibGlmZWN5Y2xlLmpzIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0IGRlZmF1bHQgQmFzZSA9PlxuICBjbGFzcyBleHRlbmRzIEJhc2Uge1xuICAgIGNvbXBvbmVudFdpbGxNb3VudCAoKSB7XG4gICAgICB0aGlzLnNldFN0YXRlV2l0aERhdGEodGhpcy5nZXREYXRhTW9kZWwodGhpcy5nZXRSZXNvbHZlZFN0YXRlKCkpKVxuICAgIH1cblxuICAgIGNvbXBvbmVudERpZE1vdW50ICgpIHtcbiAgICAgIHRoaXMuZmlyZUZldGNoRGF0YSgpXG4gICAgfVxuXG4gICAgY29tcG9uZW50V2lsbFJlY2VpdmVQcm9wcyAobmV4dFByb3BzLCBuZXh0U3RhdGUpIHtcbiAgICAgIGNvbnN0IG9sZFN0YXRlID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKClcbiAgICAgIGNvbnN0IG5ld1N0YXRlID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKG5leHRQcm9wcywgbmV4dFN0YXRlKVxuXG4gICAgICAvLyBEbyBhIGRlZXAgY29tcGFyZSBvZiBuZXcgYW5kIG9sZCBgZGVmYXVsdE9wdGlvbmAgYW5kXG4gICAgICAvLyBpZiB0aGV5IGFyZSBkaWZmZXJlbnQgcmVzZXQgYG9wdGlvbiA9IGRlZmF1bHRPcHRpb25gXG4gICAgICBjb25zdCBkZWZhdWx0YWJsZU9wdGlvbnMgPSBbJ3NvcnRlZCcsICdmaWx0ZXJlZCcsICdyZXNpemVkJywgJ2V4cGFuZGVkJ11cbiAgICAgIGRlZmF1bHRhYmxlT3B0aW9ucy5mb3JFYWNoKHggPT4ge1xuICAgICAgICBjb25zdCBkZWZhdWx0TmFtZSA9IGBkZWZhdWx0JHt4LmNoYXJBdCgwKS50b1VwcGVyQ2FzZSgpICsgeC5zbGljZSgxKX1gXG4gICAgICAgIGlmIChcbiAgICAgICAgICBKU09OLnN0cmluZ2lmeShvbGRTdGF0ZVtkZWZhdWx0TmFtZV0pICE9PVxuICAgICAgICAgIEpTT04uc3RyaW5naWZ5KG5ld1N0YXRlW2RlZmF1bHROYW1lXSlcbiAgICAgICAgKSB7XG4gICAgICAgICAgbmV3U3RhdGVbeF0gPSBuZXdTdGF0ZVtkZWZhdWx0TmFtZV1cbiAgICAgICAgfVxuICAgICAgfSlcblxuICAgICAgLy8gSWYgdGhleSBjaGFuZ2UgdGhlc2UgdGFibGUgb3B0aW9ucywgd2UgbmVlZCB0byByZXNldCBkZWZhdWx0c1xuICAgICAgLy8gb3IgZWxzZSB3ZSBjb3VsZCBnZXQgaW50byBhIHN0YXRlIHdoZXJlIHRoZSB1c2VyIGhhcyBjaGFuZ2VkIHRoZSBVSVxuICAgICAgLy8gYW5kIHRoZW4gZGlzYWJsZWQgdGhlIGFiaWxpdHkgdG8gY2hhbmdlIGl0IGJhY2suXG4gICAgICAvLyBlLmcuIElmIGBmaWx0ZXJhYmxlYCBoYXMgY2hhbmdlZCwgc2V0IGBmaWx0ZXJlZCA9IGRlZmF1bHRGaWx0ZXJlZGBcbiAgICAgIGNvbnN0IHJlc2V0dGFibGVPcHRpb25zID0gWydzb3J0YWJsZScsICdmaWx0ZXJhYmxlJywgJ3Jlc2l6YWJsZSddXG4gICAgICByZXNldHRhYmxlT3B0aW9ucy5mb3JFYWNoKHggPT4ge1xuICAgICAgICBpZiAob2xkU3RhdGVbeF0gIT09IG5ld1N0YXRlW3hdKSB7XG4gICAgICAgICAgY29uc3QgYmFzZU5hbWUgPSB4LnJlcGxhY2UoJ2FibGUnLCAnJylcbiAgICAgICAgICBjb25zdCBvcHRpb25OYW1lID0gYCR7YmFzZU5hbWV9ZWRgXG4gICAgICAgICAgY29uc3QgZGVmYXVsdE5hbWUgPSBgZGVmYXVsdCR7b3B0aW9uTmFtZS5jaGFyQXQoMCkudG9VcHBlckNhc2UoKSArXG4gICAgICAgICAgICBvcHRpb25OYW1lLnNsaWNlKDEpfWBcbiAgICAgICAgICBuZXdTdGF0ZVtvcHRpb25OYW1lXSA9IG5ld1N0YXRlW2RlZmF1bHROYW1lXVxuICAgICAgICB9XG4gICAgICB9KVxuXG4gICAgICAvLyBQcm9wcyB0aGF0IHRyaWdnZXIgYSBkYXRhIHVwZGF0ZVxuICAgICAgaWYgKFxuICAgICAgICBvbGRTdGF0ZS5kYXRhICE9PSBuZXdTdGF0ZS5kYXRhIHx8XG4gICAgICAgIG9sZFN0YXRlLmNvbHVtbnMgIT09IG5ld1N0YXRlLmNvbHVtbnMgfHxcbiAgICAgICAgb2xkU3RhdGUucGl2b3RCeSAhPT0gbmV3U3RhdGUucGl2b3RCeSB8fFxuICAgICAgICBvbGRTdGF0ZS5zb3J0ZWQgIT09IG5ld1N0YXRlLnNvcnRlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3U3RhdGUuZmlsdGVyZWRcbiAgICAgICkge1xuICAgICAgICB0aGlzLnNldFN0YXRlV2l0aERhdGEodGhpcy5nZXREYXRhTW9kZWwobmV3U3RhdGUpKVxuICAgICAgfVxuICAgIH1cblxuICAgIHNldFN0YXRlV2l0aERhdGEgKG5ld1N0YXRlLCBjYikge1xuICAgICAgY29uc3Qgb2xkU3RhdGUgPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuICAgICAgY29uc3QgbmV3UmVzb2x2ZWRTdGF0ZSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSh7fSwgbmV3U3RhdGUpXG4gICAgICBjb25zdCB7IGZyZWV6ZVdoZW5FeHBhbmRlZCB9ID0gbmV3UmVzb2x2ZWRTdGF0ZVxuXG4gICAgICAvLyBEZWZhdWx0IHRvIHVuZnJvemVuIHN0YXRlXG4gICAgICBuZXdSZXNvbHZlZFN0YXRlLmZyb3plbiA9IGZhbHNlXG5cbiAgICAgIC8vIElmIGZyZWV6ZVdoZW5FeHBhbmRlZCBpcyBzZXQsIGNoZWNrIGZvciBmcm96ZW4gY29uZGl0aW9uc1xuICAgICAgaWYgKGZyZWV6ZVdoZW5FeHBhbmRlZCkge1xuICAgICAgICAvLyBpZiBhbnkgcm93cyBhcmUgZXhwYW5kZWQsIGZyZWV6ZSB0aGUgZXhpc3RpbmcgZGF0YSBhbmQgc29ydGluZ1xuICAgICAgICBjb25zdCBrZXlzID0gT2JqZWN0LmtleXMobmV3UmVzb2x2ZWRTdGF0ZS5leHBhbmRlZClcbiAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBrZXlzLmxlbmd0aDsgaSsrKSB7XG4gICAgICAgICAgaWYgKG5ld1Jlc29sdmVkU3RhdGUuZXhwYW5kZWRba2V5c1tpXV0pIHtcbiAgICAgICAgICAgIG5ld1Jlc29sdmVkU3RhdGUuZnJvemVuID0gdHJ1ZVxuICAgICAgICAgICAgYnJlYWtcbiAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICAgIH1cblxuICAgICAgLy8gSWYgdGhlIGRhdGEgaXNuJ3QgZnJvemVuIGFuZCBlaXRoZXIgdGhlIGRhdGEgb3JcbiAgICAgIC8vIHNvcnRpbmcgbW9kZWwgaGFzIGNoYW5nZWQsIHVwZGF0ZSB0aGUgZGF0YVxuICAgICAgaWYgKFxuICAgICAgICAob2xkU3RhdGUuZnJvemVuICYmICFuZXdSZXNvbHZlZFN0YXRlLmZyb3plbikgfHxcbiAgICAgICAgb2xkU3RhdGUuc29ydGVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNvcnRlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5maWx0ZXJlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5zaG93RmlsdGVycyAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5zaG93RmlsdGVycyB8fFxuICAgICAgICAoIW5ld1Jlc29sdmVkU3RhdGUuZnJvemVuICYmXG4gICAgICAgICAgb2xkU3RhdGUucmVzb2x2ZWREYXRhICE9PSBuZXdSZXNvbHZlZFN0YXRlLnJlc29sdmVkRGF0YSlcbiAgICAgICkge1xuICAgICAgICAvLyBIYW5kbGUgY29sbGFwc2VPbnNvcnRlZENoYW5nZSAmIGNvbGxhcHNlT25EYXRhQ2hhbmdlXG4gICAgICAgIGlmIChcbiAgICAgICAgICAob2xkU3RhdGUuc29ydGVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNvcnRlZCAmJlxuICAgICAgICAgICAgdGhpcy5wcm9wcy5jb2xsYXBzZU9uU29ydGluZ0NoYW5nZSkgfHxcbiAgICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5maWx0ZXJlZCB8fFxuICAgICAgICAgIG9sZFN0YXRlLnNob3dGaWx0ZXJzICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNob3dGaWx0ZXJzIHx8XG4gICAgICAgICAgKG9sZFN0YXRlLnNvcnRlZERhdGEgJiZcbiAgICAgICAgICAgICFuZXdSZXNvbHZlZFN0YXRlLmZyb3plbiAmJlxuICAgICAgICAgICAgb2xkU3RhdGUucmVzb2x2ZWREYXRhICE9PSBuZXdSZXNvbHZlZFN0YXRlLnJlc29sdmVkRGF0YSAmJlxuICAgICAgICAgICAgdGhpcy5wcm9wcy5jb2xsYXBzZU9uRGF0YUNoYW5nZSlcbiAgICAgICAgKSB7XG4gICAgICAgICAgbmV3UmVzb2x2ZWRTdGF0ZS5leHBhbmRlZCA9IHt9XG4gICAgICAgIH1cblxuICAgICAgICBPYmplY3QuYXNzaWduKG5ld1Jlc29sdmVkU3RhdGUsIHRoaXMuZ2V0U29ydGVkRGF0YShuZXdSZXNvbHZlZFN0YXRlKSlcbiAgICAgIH1cblxuICAgICAgLy8gU2V0IHBhZ2UgdG8gMCBpZiBmaWx0ZXJzIGNoYW5nZVxuICAgICAgaWYgKG9sZFN0YXRlLmZpbHRlcmVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLmZpbHRlcmVkKSB7XG4gICAgICAgIG5ld1Jlc29sdmVkU3RhdGUucGFnZSA9IDBcbiAgICAgIH1cblxuICAgICAgLy8gQ2FsY3VsYXRlIHBhZ2VTaXplIGFsbCB0aGUgdGltZVxuICAgICAgaWYgKG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkRGF0YSkge1xuICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VzID0gbmV3UmVzb2x2ZWRTdGF0ZS5tYW51YWxcbiAgICAgICAgICA/IG5ld1Jlc29sdmVkU3RhdGUucGFnZXNcbiAgICAgICAgICA6IE1hdGguY2VpbChcbiAgICAgICAgICAgIG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkRGF0YS5sZW5ndGggLyBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VTaXplXG4gICAgICAgICAgKVxuICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UgPSBNYXRoLm1heChcbiAgICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UgPj0gbmV3UmVzb2x2ZWRTdGF0ZS5wYWdlc1xuICAgICAgICAgICAgPyBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VzIC0gMVxuICAgICAgICAgICAgOiBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UsXG4gICAgICAgICAgMFxuICAgICAgICApXG4gICAgICB9XG5cbiAgICAgIHJldHVybiB0aGlzLnNldFN0YXRlKG5ld1Jlc29sdmVkU3RhdGUsICgpID0+IHtcbiAgICAgICAgY2IgJiYgY2IoKVxuICAgICAgICBpZiAoXG4gICAgICAgICAgb2xkU3RhdGUucGFnZSAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5wYWdlIHx8XG4gICAgICAgICAgb2xkU3RhdGUucGFnZVNpemUgIT09IG5ld1Jlc29sdmVkU3RhdGUucGFnZVNpemUgfHxcbiAgICAgICAgICBvbGRTdGF0ZS5zb3J0ZWQgIT09IG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkIHx8XG4gICAgICAgICAgb2xkU3RhdGUuZmlsdGVyZWQgIT09IG5ld1Jlc29sdmVkU3RhdGUuZmlsdGVyZWRcbiAgICAgICAgKSB7XG4gICAgICAgICAgdGhpcy5maXJlRmV0Y2hEYXRhKClcbiAgICAgICAgfVxuICAgICAgfSlcbiAgICB9XG4gIH1cbiJdfQ== /***/ }), -/* 105 */ +/* 360 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Object.defineProperty(exports, "__esModule", { + value: true +}); -var ReactNodeTypes = __webpack_require__(97); +var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); -function getHostComponentFromComposite(inst) { - var type; +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; - while ((type = inst._renderedNodeType) === ReactNodeTypes.COMPOSITE) { - inst = inst._renderedComponent; - } +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - if (type === ReactNodeTypes.HOST) { - return inst._renderedComponent; - } else if (type === ReactNodeTypes.EMPTY) { - return null; - } -} +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); -module.exports = getHostComponentFromComposite; +var _react = __webpack_require__(6); -/***/ }), -/* 106 */ -/***/ (function(module, exports, __webpack_require__) { +var _react2 = _interopRequireDefault(_react); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +var _utils = __webpack_require__(95); -exports.__esModule = true; +var _utils2 = _interopRequireDefault(_utils); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -var _chainFunction = __webpack_require__(228); +function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } -var _chainFunction2 = _interopRequireDefault(_chainFunction); +function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } } -var _react = __webpack_require__(4); +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -var _react2 = _interopRequireDefault(_react); +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } -var _propTypes = __webpack_require__(9); +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -var _propTypes2 = _interopRequireDefault(_propTypes); +exports.default = function (Base) { + return function (_Base) { + _inherits(_class, _Base); -var _warning = __webpack_require__(229); + function _class() { + _classCallCheck(this, _class); -var _warning2 = _interopRequireDefault(_warning); + return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments)); + } -var _ChildMapping = __webpack_require__(230); + _createClass(_class, [{ + key: 'getResolvedState', + value: function getResolvedState(props, state) { + var resolvedState = _extends({}, _utils2.default.compactObject(this.state), _utils2.default.compactObject(this.props), _utils2.default.compactObject(state), _utils2.default.compactObject(props)); + return resolvedState; + } + }, { + key: 'getDataModel', + value: function getDataModel(newState) { + var _this2 = this; + + var columns = newState.columns, + _newState$pivotBy = newState.pivotBy, + pivotBy = _newState$pivotBy === undefined ? [] : _newState$pivotBy, + data = newState.data, + pivotIDKey = newState.pivotIDKey, + pivotValKey = newState.pivotValKey, + subRowsKey = newState.subRowsKey, + aggregatedKey = newState.aggregatedKey, + nestingLevelKey = newState.nestingLevelKey, + originalKey = newState.originalKey, + indexKey = newState.indexKey, + groupedByPivotKey = newState.groupedByPivotKey, + SubComponent = newState.SubComponent; + + // Determine Header Groups + + var hasHeaderGroups = false; + columns.forEach(function (column) { + if (column.columns) { + hasHeaderGroups = true; + } + }); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + var columnsWithExpander = [].concat(_toConsumableArray(columns)); -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + var expanderColumn = columns.find(function (col) { + return col.expander || col.columns && col.columns.some(function (col2) { + return col2.expander; + }); + }); + // The actual expander might be in the columns field of a group column + if (expanderColumn && !expanderColumn.expander) { + expanderColumn = expanderColumn.columns.find(function (col) { + return col.expander; + }); + } -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + // If we have SubComponent's we need to make sure we have an expander column + if (SubComponent && !expanderColumn) { + expanderColumn = { expander: true }; + columnsWithExpander = [expanderColumn].concat(_toConsumableArray(columnsWithExpander)); + } -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + var makeDecoratedColumn = function makeDecoratedColumn(column, parentColumn) { + var dcol = void 0; + if (column.expander) { + dcol = _extends({}, _this2.props.column, _this2.props.expanderDefaults, column); + } else { + dcol = _extends({}, _this2.props.column, column); + } -var propTypes = { - component: _propTypes2.default.any, - childFactory: _propTypes2.default.func, - children: _propTypes2.default.node -}; + // Ensure minWidth is not greater than maxWidth if set + if (dcol.maxWidth < dcol.minWidth) { + dcol.minWidth = dcol.maxWidth; + } -var defaultProps = { - component: 'span', - childFactory: function childFactory(child) { - return child; - } -}; + if (parentColumn) { + dcol.parentColumn = parentColumn; + } -var TransitionGroup = function (_React$Component) { - _inherits(TransitionGroup, _React$Component); + // First check for string accessor + if (typeof dcol.accessor === 'string') { + var _ret = function () { + dcol.id = dcol.id || dcol.accessor; + var accessorString = dcol.accessor; + dcol.accessor = function (row) { + return _utils2.default.get(row, accessorString); + }; + return { + v: dcol + }; + }(); - function TransitionGroup(props, context) { - _classCallCheck(this, TransitionGroup); + if ((typeof _ret === 'undefined' ? 'undefined' : _typeof(_ret)) === "object") return _ret.v; + } - var _this = _possibleConstructorReturn(this, _React$Component.call(this, props, context)); + // Fall back to functional accessor (but require an ID) + if (dcol.accessor && !dcol.id) { + console.warn(dcol); + throw new Error('A column id is required if using a non-string accessor for column above.'); + } - _this.performAppear = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; + // Fall back to an undefined accessor + if (!dcol.accessor) { + dcol.accessor = function (d) { + return undefined; + }; + } - if (component.componentWillAppear) { - component.componentWillAppear(_this._handleDoneAppearing.bind(_this, key, component)); - } else { - _this._handleDoneAppearing(key, component); - } - }; + return dcol; + }; - _this._handleDoneAppearing = function (key, component) { - if (component.componentDidAppear) { - component.componentDidAppear(); - } + // Decorate the columns + var decorateAndAddToAll = function decorateAndAddToAll(column, parentColumn) { + var decoratedColumn = makeDecoratedColumn(column, parentColumn); + allDecoratedColumns.push(decoratedColumn); + return decoratedColumn; + }; + var allDecoratedColumns = []; + var decoratedColumns = columnsWithExpander.map(function (column, i) { + if (column.columns) { + return _extends({}, column, { + columns: column.columns.map(function (d) { + return decorateAndAddToAll(d, column); + }) + }); + } else { + return decorateAndAddToAll(column); + } + }); - delete _this.currentlyTransitioningKeys[key]; + // Build the visible columns, headers and flat column list + var visibleColumns = decoratedColumns.slice(); + var allVisibleColumns = []; - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + visibleColumns = visibleColumns.map(function (column, i) { + if (column.columns) { + var visibleSubColumns = column.columns.filter(function (d) { + return pivotBy.indexOf(d.id) > -1 ? false : _utils2.default.getFirstDefined(d.show, true); + }); + return _extends({}, column, { + columns: visibleSubColumns + }); + } + return column; + }); - if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { - // This was removed before it had fully appeared. Remove it. - _this.performLeave(key, component); - } - }; + visibleColumns = visibleColumns.filter(function (column) { + return column.columns ? column.columns.length : pivotBy.indexOf(column.id) > -1 ? false : _utils2.default.getFirstDefined(column.show, true); + }); - _this.performEnter = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; + // Find any custom pivot location + var pivotIndex = visibleColumns.findIndex(function (col) { + return col.pivot; + }); - if (component.componentWillEnter) { - component.componentWillEnter(_this._handleDoneEntering.bind(_this, key, component)); - } else { - _this._handleDoneEntering(key, component); + // Handle Pivot Columns + if (pivotBy.length) { + (function () { + // Retrieve the pivot columns in the correct pivot order + var pivotColumns = []; + pivotBy.forEach(function (pivotID) { + var found = allDecoratedColumns.find(function (d) { + return d.id === pivotID; + }); + if (found) { + pivotColumns.push(found); + } + }); + + var PivotParentColumn = pivotColumns.reduce(function (prev, current) { + return prev && prev === current.parentColumn && current.parentColumn; + }, pivotColumns[0].parentColumn); + + var PivotGroupHeader = hasHeaderGroups && PivotParentColumn.Header; + PivotGroupHeader = PivotGroupHeader || function () { + return _react2.default.createElement( + 'strong', + null, + 'Pivoted' + ); + }; + + var pivotColumnGroup = { + Header: PivotGroupHeader, + columns: pivotColumns.map(function (col) { + return _extends({}, _this2.props.pivotDefaults, col, { + pivoted: true + }); + }) + }; + + // Place the pivotColumns back into the visibleColumns + if (pivotIndex >= 0) { + pivotColumnGroup = _extends({}, visibleColumns[pivotIndex], pivotColumnGroup); + visibleColumns.splice(pivotIndex, 1, pivotColumnGroup); + } else { + visibleColumns.unshift(pivotColumnGroup); + } + })(); + } + + // Build Header Groups + var headerGroups = []; + var currentSpan = []; + + // A convenience function to add a header and reset the currentSpan + var addHeader = function addHeader(columns, column) { + headerGroups.push(_extends({}, _this2.props.column, column, { + columns: columns + })); + currentSpan = []; + }; + + // Build flast list of allVisibleColumns and HeaderGroups + visibleColumns.forEach(function (column, i) { + if (column.columns) { + allVisibleColumns = allVisibleColumns.concat(column.columns); + if (currentSpan.length > 0) { + addHeader(currentSpan); + } + addHeader(column.columns, column); + return; + } + allVisibleColumns.push(column); + currentSpan.push(column); + }); + if (hasHeaderGroups && currentSpan.length > 0) { + addHeader(currentSpan); + } + + // Access the data + var accessRow = function accessRow(d, i) { + var _row; + + var level = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0; + + var row = (_row = {}, _defineProperty(_row, originalKey, d), _defineProperty(_row, indexKey, i), _defineProperty(_row, subRowsKey, d[subRowsKey]), _defineProperty(_row, nestingLevelKey, level), _row); + allDecoratedColumns.forEach(function (column) { + if (column.expander) return; + row[column.id] = column.accessor(d); + }); + if (row[subRowsKey]) { + row[subRowsKey] = row[subRowsKey].map(function (d, i) { + return accessRow(d, i, level + 1); + }); + } + return row; + }; + var resolvedData = data.map(function (d, i) { + return accessRow(d, i); + }); + + // If pivoting, recursively group the data + var aggregate = function aggregate(rows) { + var aggregationValues = {}; + aggregatingColumns.forEach(function (column) { + var values = rows.map(function (d) { + return d[column.id]; + }); + aggregationValues[column.id] = column.aggregate(values, rows); + }); + return aggregationValues; + }; + + // TODO: Make it possible to fabricate nested rows without pivoting + var aggregatingColumns = allVisibleColumns.filter(function (d) { + return !d.expander && d.aggregate; + }); + if (pivotBy.length) { + (function () { + var groupRecursively = function groupRecursively(rows, keys) { + var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0; + + // This is the last level, just return the rows + if (i === keys.length) { + return rows; + } + // Group the rows together for this level + var groupedRows = Object.entries(_utils2.default.groupBy(rows, keys[i])).map(function (_ref) { + var _ref3; + + var _ref2 = _slicedToArray(_ref, 2), + key = _ref2[0], + value = _ref2[1]; + + return _ref3 = {}, _defineProperty(_ref3, pivotIDKey, keys[i]), _defineProperty(_ref3, pivotValKey, key), _defineProperty(_ref3, keys[i], key), _defineProperty(_ref3, subRowsKey, value), _defineProperty(_ref3, nestingLevelKey, i), _defineProperty(_ref3, groupedByPivotKey, true), _ref3; + }); + // Recurse into the subRows + groupedRows = groupedRows.map(function (rowGroup) { + var _extends2; + + var subRows = groupRecursively(rowGroup[subRowsKey], keys, i + 1); + return _extends({}, rowGroup, (_extends2 = {}, _defineProperty(_extends2, subRowsKey, subRows), _defineProperty(_extends2, aggregatedKey, true), _extends2), aggregate(subRows)); + }); + return groupedRows; + }; + resolvedData = groupRecursively(resolvedData, pivotBy); + })(); + } + + return _extends({}, newState, { + resolvedData: resolvedData, + allVisibleColumns: allVisibleColumns, + headerGroups: headerGroups, + allDecoratedColumns: allDecoratedColumns, + hasHeaderGroups: hasHeaderGroups + }); } - }; + }, { + key: 'getSortedData', + value: function getSortedData(resolvedState) { + var manual = resolvedState.manual, + sorted = resolvedState.sorted, + filtered = resolvedState.filtered, + defaultFilterMethod = resolvedState.defaultFilterMethod, + resolvedData = resolvedState.resolvedData, + allVisibleColumns = resolvedState.allVisibleColumns, + allDecoratedColumns = resolvedState.allDecoratedColumns; + + + var sortMethodsByColumnID = {}; + + allDecoratedColumns.filter(function (col) { + return col.sortMethod; + }).forEach(function (col) { + sortMethodsByColumnID[col.id] = col.sortMethod; + }); - _this._handleDoneEntering = function (key, component) { - if (component.componentDidEnter) { - component.componentDidEnter(); + // Resolve the data from either manual data or sorted data + return { + sortedData: manual ? resolvedData : this.sortData(this.filterData(resolvedData, filtered, defaultFilterMethod, allVisibleColumns), sorted, sortMethodsByColumnID) + }; } + }, { + key: 'fireFetchData', + value: function fireFetchData() { + this.props.onFetchData(this.getResolvedState(), this); + } + }, { + key: 'getPropOrState', + value: function getPropOrState(key) { + return _utils2.default.getFirstDefined(this.props[key], this.state[key]); + } + }, { + key: 'getStateOrProp', + value: function getStateOrProp(key) { + return _utils2.default.getFirstDefined(this.state[key], this.props[key]); + } + }, { + key: 'filterData', + value: function filterData(data, filtered, defaultFilterMethod, allVisibleColumns) { + var _this3 = this; - delete _this.currentlyTransitioningKeys[key]; + var filteredData = data; - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + if (filtered.length) { + filteredData = filtered.reduce(function (filteredSoFar, nextFilter) { + var column = allVisibleColumns.find(function (x) { + return x.id === nextFilter.id; + }); - if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { - // This was removed before it had fully entered. Remove it. - _this.performLeave(key, component); - } - }; + // Don't filter hidden columns or columns that have had their filters disabled + if (!column || column.filterable === false) { + return filteredSoFar; + } - _this.performLeave = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; + var filterMethod = column.filterMethod || defaultFilterMethod; - if (component.componentWillLeave) { - component.componentWillLeave(_this._handleDoneLeaving.bind(_this, key, component)); - } else { - // Note that this is somewhat dangerous b/c it calls setState() - // again, effectively mutating the component before all the work - // is done. - _this._handleDoneLeaving(key, component); - } - }; + // If 'filterAll' is set to true, pass the entire dataset to the filter method + if (column.filterAll) { + return filterMethod(nextFilter, filteredSoFar, column); + } else { + return filteredSoFar.filter(function (row) { + return filterMethod(nextFilter, row, column); + }); + } + }, filteredData); - _this._handleDoneLeaving = function (key, component) { - if (component.componentDidLeave) { - component.componentDidLeave(); + // Apply the filter to the subrows if we are pivoting, and then + // filter any rows without subcolumns because it would be strange to show + filteredData = filteredData.map(function (row) { + if (!row[_this3.props.subRowsKey]) { + return row; + } + return _extends({}, row, _defineProperty({}, _this3.props.subRowsKey, _this3.filterData(row[_this3.props.subRowsKey], filtered, defaultFilterMethod, allVisibleColumns))); + }).filter(function (row) { + if (!row[_this3.props.subRowsKey]) { + return true; + } + return row[_this3.props.subRowsKey].length > 0; + }); + } + + return filteredData; } + }, { + key: 'sortData', + value: function sortData(data, sorted) { + var _this4 = this; - delete _this.currentlyTransitioningKeys[key]; + var sortMethodsByColumnID = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {}; - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + if (!sorted.length) { + return data; + } - if (currentChildMapping && currentChildMapping.hasOwnProperty(key)) { - // This entered again before it fully left. Add it again. - _this.keysToEnter.push(key); - } else { - _this.setState(function (state) { - var newChildren = _extends({}, state.children); - delete newChildren[key]; - return { children: newChildren }; + var sortedData = (this.props.orderByMethod || _utils2.default.orderBy)(data, sorted.map(function (sort) { + // Support custom sorting methods for each column + if (sortMethodsByColumnID[sort.id]) { + return function (a, b) { + return sortMethodsByColumnID[sort.id](a[sort.id], b[sort.id]); + }; + } + return function (a, b) { + return _this4.props.defaultSortMethod(a[sort.id], b[sort.id]); + }; + }), sorted.map(function (d) { + return !d.desc; + }), this.props.indexKey); + + sortedData.forEach(function (row) { + if (!row[_this4.props.subRowsKey]) { + return; + } + row[_this4.props.subRowsKey] = _this4.sortData(row[_this4.props.subRowsKey], sorted, sortMethodsByColumnID); }); + + return sortedData; + } + }, { + key: 'getMinRows', + value: function getMinRows() { + return _utils2.default.getFirstDefined(this.props.minRows, this.getStateOrProp('pageSize')); } - }; - _this.childRefs = Object.create(null); + // User actions - _this.state = { - children: (0, _ChildMapping.getChildMapping)(props.children) - }; - return _this; - } + }, { + key: 'onPageChange', + value: function onPageChange(page) { + var _props = this.props, + onPageChange = _props.onPageChange, + collapseOnPageChange = _props.collapseOnPageChange; - TransitionGroup.prototype.componentWillMount = function componentWillMount() { - this.currentlyTransitioningKeys = {}; - this.keysToEnter = []; - this.keysToLeave = []; - }; - TransitionGroup.prototype.componentDidMount = function componentDidMount() { - var initialChildMapping = this.state.children; - for (var key in initialChildMapping) { - if (initialChildMapping[key]) { - this.performAppear(key, this.childRefs[key]); + var newState = { page: page }; + if (collapseOnPageChange) { + newState.expanded = {}; + } + this.setStateWithData(newState, function () { + onPageChange && onPageChange(page); + }); } - } - }; + }, { + key: 'onPageSizeChange', + value: function onPageSizeChange(newPageSize) { + var onPageSizeChange = this.props.onPageSizeChange; - TransitionGroup.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { - var nextChildMapping = (0, _ChildMapping.getChildMapping)(nextProps.children); - var prevChildMapping = this.state.children; + var _getResolvedState = this.getResolvedState(), + pageSize = _getResolvedState.pageSize, + page = _getResolvedState.page; - this.setState({ - children: (0, _ChildMapping.mergeChildMappings)(prevChildMapping, nextChildMapping) - }); + // Normalize the page to display - for (var key in nextChildMapping) { - var hasPrev = prevChildMapping && prevChildMapping.hasOwnProperty(key); - if (nextChildMapping[key] && !hasPrev && !this.currentlyTransitioningKeys[key]) { - this.keysToEnter.push(key); - } - } - for (var _key in prevChildMapping) { - var hasNext = nextChildMapping && nextChildMapping.hasOwnProperty(_key); - if (prevChildMapping[_key] && !hasNext && !this.currentlyTransitioningKeys[_key]) { - this.keysToLeave.push(_key); + var currentRow = pageSize * page; + var newPage = Math.floor(currentRow / newPageSize); + + this.setStateWithData({ + pageSize: newPageSize, + page: newPage + }, function () { + onPageSizeChange && onPageSizeChange(newPageSize, newPage); + }); } - } + }, { + key: 'sortColumn', + value: function sortColumn(column, additive) { + var _getResolvedState2 = this.getResolvedState(), + sorted = _getResolvedState2.sorted, + skipNextSort = _getResolvedState2.skipNextSort, + defaultSortDesc = _getResolvedState2.defaultSortDesc; + + var firstSortDirection = column.hasOwnProperty('defaultSortDesc') ? column.defaultSortDesc : defaultSortDesc; + var secondSortDirection = !firstSortDirection; + + // we can't stop event propagation from the column resize move handlers + // attached to the document because of react's synthetic events + // so we have to prevent the sort function from actually sorting + // if we click on the column resize element within a header. + if (skipNextSort) { + this.setStateWithData({ + skipNextSort: false + }); + return; + } - // If we want to someday check for reordering, we could do it here. - }; + var onSortedChange = this.props.onSortedChange; - TransitionGroup.prototype.componentDidUpdate = function componentDidUpdate() { - var _this2 = this; - var keysToEnter = this.keysToEnter; - this.keysToEnter = []; - keysToEnter.forEach(function (key) { - return _this2.performEnter(key, _this2.childRefs[key]); - }); + var newSorted = _utils2.default.clone(sorted || []).map(function (d) { + d.desc = _utils2.default.isSortingDesc(d); + return d; + }); + if (!_utils2.default.isArray(column)) { + // Single-Sort + var existingIndex = newSorted.findIndex(function (d) { + return d.id === column.id; + }); + if (existingIndex > -1) { + var existing = newSorted[existingIndex]; + if (existing.desc === secondSortDirection) { + if (additive) { + newSorted.splice(existingIndex, 1); + } else { + existing.desc = firstSortDirection; + newSorted = [existing]; + } + } else { + existing.desc = secondSortDirection; + if (!additive) { + newSorted = [existing]; + } + } + } else { + if (additive) { + newSorted.push({ + id: column.id, + desc: firstSortDirection + }); + } else { + newSorted = [{ + id: column.id, + desc: firstSortDirection + }]; + } + } + } else { + (function () { + // Multi-Sort + var existingIndex = newSorted.findIndex(function (d) { + return d.id === column[0].id; + }); + // Existing Sorted Column + if (existingIndex > -1) { + var _existing = newSorted[existingIndex]; + if (_existing.desc === secondSortDirection) { + if (additive) { + newSorted.splice(existingIndex, column.length); + } else { + column.forEach(function (d, i) { + newSorted[existingIndex + i].desc = firstSortDirection; + }); + } + } else { + column.forEach(function (d, i) { + newSorted[existingIndex + i].desc = secondSortDirection; + }); + } + if (!additive) { + newSorted = newSorted.slice(existingIndex, column.length); + } + } else { + // New Sort Column + if (additive) { + newSorted = newSorted.concat(column.map(function (d) { + return { + id: d.id, + desc: firstSortDirection + }; + })); + } else { + newSorted = column.map(function (d) { + return { + id: d.id, + desc: firstSortDirection + }; + }); + } + } + })(); + } - var keysToLeave = this.keysToLeave; - this.keysToLeave = []; - keysToLeave.forEach(function (key) { - return _this2.performLeave(key, _this2.childRefs[key]); - }); - }; + this.setStateWithData({ + page: !sorted.length && newSorted.length || !additive ? 0 : this.state.page, + sorted: newSorted + }, function () { + onSortedChange && onSortedChange(newSorted, column, additive); + }); + } + }, { + key: 'filterColumn', + value: function filterColumn(column, value) { + var _getResolvedState3 = this.getResolvedState(), + filtered = _getResolvedState3.filtered; - TransitionGroup.prototype.render = function render() { - var _this3 = this; + var onFilteredChange = this.props.onFilteredChange; - // TODO: we could get rid of the need for the wrapper node - // by cloning a single child - var childrenToRender = []; + // Remove old filter first if it exists + + var newFiltering = (filtered || []).filter(function (x) { + if (x.id !== column.id) { + return true; + } + }); - var _loop = function _loop(key) { - var child = _this3.state.children[key]; - if (child) { - var isCallbackRef = typeof child.ref !== 'string'; - var factoryChild = _this3.props.childFactory(child); - var ref = function ref(r) { - _this3.childRefs[key] = r; - }; + if (value !== '') { + newFiltering.push({ + id: column.id, + value: value + }); + } - process.env.NODE_ENV !== 'production' ? (0, _warning2.default)(isCallbackRef, 'string refs are not supported on children of TransitionGroup and will be ignored. ' + 'Please use a callback ref instead: https://facebook.github.io/react/docs/refs-and-the-dom.html#the-ref-callback-attribute') : void 0; + this.setStateWithData({ + filtered: newFiltering + }, function () { + onFilteredChange && onFilteredChange(newFiltering, column, value); + }); + } + }, { + key: 'resizeColumnStart', + value: function resizeColumnStart(event, column, isTouch) { + var _this5 = this; - // Always chaining the refs leads to problems when the childFactory - // wraps the child. The child ref callback gets called twice with the - // wrapper and the child. So we only need to chain the ref if the - // factoryChild is not different from child. - if (factoryChild === child && isCallbackRef) { - ref = (0, _chainFunction2.default)(child.ref, ref); + event.stopPropagation(); + var parentWidth = event.target.parentElement.getBoundingClientRect().width; + + var pageX = void 0; + if (isTouch) { + pageX = event.changedTouches[0].pageX; + } else { + pageX = event.pageX; } - // You may need to apply reactive updates to a child as it is leaving. - // The normal React way to do it won't work since the child will have - // already been removed. In case you need this behavior you can provide - // a childFactory function to wrap every child, even the ones that are - // leaving. - childrenToRender.push(_react2.default.cloneElement(factoryChild, { - key: key, - ref: ref - })); + this.trapEvents = true; + this.setStateWithData({ + currentlyResizing: { + id: column.id, + startX: pageX, + parentWidth: parentWidth + } + }, function () { + if (isTouch) { + document.addEventListener('touchmove', _this5.resizeColumnMoving); + document.addEventListener('touchcancel', _this5.resizeColumnEnd); + document.addEventListener('touchend', _this5.resizeColumnEnd); + } else { + document.addEventListener('mousemove', _this5.resizeColumnMoving); + document.addEventListener('mouseup', _this5.resizeColumnEnd); + document.addEventListener('mouseleave', _this5.resizeColumnEnd); + } + }); } - }; + }, { + key: 'resizeColumnMoving', + value: function resizeColumnMoving(event) { + event.stopPropagation(); + var onResizedChange = this.props.onResizedChange; - for (var key in this.state.children) { - _loop(key); - } + var _getResolvedState4 = this.getResolvedState(), + resized = _getResolvedState4.resized, + currentlyResizing = _getResolvedState4.currentlyResizing; - // Do not forward TransitionGroup props to primitive DOM nodes - var props = _extends({}, this.props); - delete props.transitionLeave; - delete props.transitionName; - delete props.transitionAppear; - delete props.transitionEnter; - delete props.childFactory; - delete props.transitionLeaveTimeout; - delete props.transitionEnterTimeout; - delete props.transitionAppearTimeout; - delete props.component; + // Delete old value - return _react2.default.createElement(this.props.component, props, childrenToRender); - }; - return TransitionGroup; -}(_react2.default.Component); + var newResized = resized.filter(function (x) { + return x.id !== currentlyResizing.id; + }); -TransitionGroup.displayName = 'TransitionGroup'; + var pageX = void 0; + if (event.type === 'touchmove') { + pageX = event.changedTouches[0].pageX; + } else if (event.type === 'mousemove') { + pageX = event.pageX; + } -TransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; -TransitionGroup.defaultProps = defaultProps; + // Set the min size to 10 to account for margin and border or else the group headers don't line up correctly + var newWidth = Math.max(currentlyResizing.parentWidth + pageX - currentlyResizing.startX, 11); -exports.default = TransitionGroup; -module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + newResized.push({ + id: currentlyResizing.id, + value: newWidth + }); + + this.setStateWithData({ + resized: newResized + }, function () { + onResizedChange && onResizedChange(newResized, event); + }); + } + }, { + key: 'resizeColumnEnd', + value: function resizeColumnEnd(event) { + event.stopPropagation(); + var isTouch = event.type === 'touchend' || event.type === 'touchcancel'; + + if (isTouch) { + document.removeEventListener('touchmove', this.resizeColumnMoving); + document.removeEventListener('touchcancel', this.resizeColumnEnd); + document.removeEventListener('touchend', this.resizeColumnEnd); + } + + // If its a touch event clear the mouse one's as well because sometimes + // the mouseDown event gets called as well, but the mouseUp event doesn't + document.removeEventListener('mousemove', this.resizeColumnMoving); + document.removeEventListener('mouseup', this.resizeColumnEnd); + document.removeEventListener('mouseleave', this.resizeColumnEnd); + + // The touch events don't propagate up to the sorting's onMouseDown event so + // no need to prevent it from happening or else the first click after a touch + // event resize will not sort the column. + if (!isTouch) { + this.setStateWithData({ + skipNextSort: true, + currentlyResizing: false + }); + } + } + }]); + + return _class; + }(Base); +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9tZXRob2RzLmpzIl0sIm5hbWVzIjpbInByb3BzIiwic3RhdGUiLCJyZXNvbHZlZFN0YXRlIiwiY29tcGFjdE9iamVjdCIsIm5ld1N0YXRlIiwiY29sdW1ucyIsInBpdm90QnkiLCJkYXRhIiwicGl2b3RJREtleSIsInBpdm90VmFsS2V5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJuZXN0aW5nTGV2ZWxLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJTdWJDb21wb25lbnQiLCJoYXNIZWFkZXJHcm91cHMiLCJmb3JFYWNoIiwiY29sdW1uIiwiY29sdW1uc1dpdGhFeHBhbmRlciIsImV4cGFuZGVyQ29sdW1uIiwiZmluZCIsImNvbCIsImV4cGFuZGVyIiwic29tZSIsImNvbDIiLCJtYWtlRGVjb3JhdGVkQ29sdW1uIiwicGFyZW50Q29sdW1uIiwiZGNvbCIsImV4cGFuZGVyRGVmYXVsdHMiLCJtYXhXaWR0aCIsIm1pbldpZHRoIiwiYWNjZXNzb3IiLCJpZCIsImFjY2Vzc29yU3RyaW5nIiwiZ2V0Iiwicm93IiwiY29uc29sZSIsIndhcm4iLCJFcnJvciIsInVuZGVmaW5lZCIsImRlY29yYXRlQW5kQWRkVG9BbGwiLCJkZWNvcmF0ZWRDb2x1bW4iLCJhbGxEZWNvcmF0ZWRDb2x1bW5zIiwicHVzaCIsImRlY29yYXRlZENvbHVtbnMiLCJtYXAiLCJpIiwiZCIsInZpc2libGVDb2x1bW5zIiwic2xpY2UiLCJhbGxWaXNpYmxlQ29sdW1ucyIsInZpc2libGVTdWJDb2x1bW5zIiwiZmlsdGVyIiwiaW5kZXhPZiIsImdldEZpcnN0RGVmaW5lZCIsInNob3ciLCJsZW5ndGgiLCJwaXZvdEluZGV4IiwiZmluZEluZGV4IiwicGl2b3QiLCJwaXZvdENvbHVtbnMiLCJmb3VuZCIsInBpdm90SUQiLCJQaXZvdFBhcmVudENvbHVtbiIsInJlZHVjZSIsInByZXYiLCJjdXJyZW50IiwiUGl2b3RHcm91cEhlYWRlciIsIkhlYWRlciIsInBpdm90Q29sdW1uR3JvdXAiLCJwaXZvdERlZmF1bHRzIiwicGl2b3RlZCIsInNwbGljZSIsInVuc2hpZnQiLCJoZWFkZXJHcm91cHMiLCJjdXJyZW50U3BhbiIsImFkZEhlYWRlciIsImNvbmNhdCIsImFjY2Vzc1JvdyIsImxldmVsIiwicmVzb2x2ZWREYXRhIiwiYWdncmVnYXRlIiwiYWdncmVnYXRpb25WYWx1ZXMiLCJhZ2dyZWdhdGluZ0NvbHVtbnMiLCJ2YWx1ZXMiLCJyb3dzIiwiZ3JvdXBSZWN1cnNpdmVseSIsImtleXMiLCJncm91cGVkUm93cyIsIk9iamVjdCIsImVudHJpZXMiLCJncm91cEJ5Iiwia2V5IiwidmFsdWUiLCJzdWJSb3dzIiwicm93R3JvdXAiLCJtYW51YWwiLCJzb3J0ZWQiLCJmaWx0ZXJlZCIsImRlZmF1bHRGaWx0ZXJNZXRob2QiLCJzb3J0TWV0aG9kc0J5Q29sdW1uSUQiLCJzb3J0TWV0aG9kIiwic29ydGVkRGF0YSIsInNvcnREYXRhIiwiZmlsdGVyRGF0YSIsIm9uRmV0Y2hEYXRhIiwiZ2V0UmVzb2x2ZWRTdGF0ZSIsImZpbHRlcmVkRGF0YSIsImZpbHRlcmVkU29GYXIiLCJuZXh0RmlsdGVyIiwieCIsImZpbHRlcmFibGUiLCJmaWx0ZXJNZXRob2QiLCJmaWx0ZXJBbGwiLCJvcmRlckJ5TWV0aG9kIiwib3JkZXJCeSIsInNvcnQiLCJhIiwiYiIsImRlZmF1bHRTb3J0TWV0aG9kIiwiZGVzYyIsIm1pblJvd3MiLCJnZXRTdGF0ZU9yUHJvcCIsInBhZ2UiLCJvblBhZ2VDaGFuZ2UiLCJjb2xsYXBzZU9uUGFnZUNoYW5nZSIsImV4cGFuZGVkIiwic2V0U3RhdGVXaXRoRGF0YSIsIm5ld1BhZ2VTaXplIiwib25QYWdlU2l6ZUNoYW5nZSIsInBhZ2VTaXplIiwiY3VycmVudFJvdyIsIm5ld1BhZ2UiLCJNYXRoIiwiZmxvb3IiLCJhZGRpdGl2ZSIsInNraXBOZXh0U29ydCIsImRlZmF1bHRTb3J0RGVzYyIsImZpcnN0U29ydERpcmVjdGlvbiIsImhhc093blByb3BlcnR5Iiwic2Vjb25kU29ydERpcmVjdGlvbiIsIm9uU29ydGVkQ2hhbmdlIiwibmV3U29ydGVkIiwiY2xvbmUiLCJpc1NvcnRpbmdEZXNjIiwiaXNBcnJheSIsImV4aXN0aW5nSW5kZXgiLCJleGlzdGluZyIsIm9uRmlsdGVyZWRDaGFuZ2UiLCJuZXdGaWx0ZXJpbmciLCJldmVudCIsImlzVG91Y2giLCJzdG9wUHJvcGFnYXRpb24iLCJwYXJlbnRXaWR0aCIsInRhcmdldCIsInBhcmVudEVsZW1lbnQiLCJnZXRCb3VuZGluZ0NsaWVudFJlY3QiLCJ3aWR0aCIsInBhZ2VYIiwiY2hhbmdlZFRvdWNoZXMiLCJ0cmFwRXZlbnRzIiwiY3VycmVudGx5UmVzaXppbmciLCJzdGFydFgiLCJkb2N1bWVudCIsImFkZEV2ZW50TGlzdGVuZXIiLCJyZXNpemVDb2x1bW5Nb3ZpbmciLCJyZXNpemVDb2x1bW5FbmQiLCJvblJlc2l6ZWRDaGFuZ2UiLCJyZXNpemVkIiwibmV3UmVzaXplZCIsInR5cGUiLCJuZXdXaWR0aCIsIm1heCIsInJlbW92ZUV2ZW50TGlzdGVuZXIiLCJCYXNlIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7OztBQUFBOzs7O0FBQ0E7Ozs7Ozs7Ozs7Ozs7Ozs7a0JBRWU7QUFBQTtBQUFBOztBQUFBO0FBQUE7O0FBQUE7QUFBQTs7QUFBQTtBQUFBO0FBQUEsdUNBRU9BLEtBRlAsRUFFY0MsS0FGZCxFQUVxQjtBQUM5QixZQUFNQyw2QkFDRCxnQkFBRUMsYUFBRixDQUFnQixLQUFLRixLQUFyQixDQURDLEVBRUQsZ0JBQUVFLGFBQUYsQ0FBZ0IsS0FBS0gsS0FBckIsQ0FGQyxFQUdELGdCQUFFRyxhQUFGLENBQWdCRixLQUFoQixDQUhDLEVBSUQsZ0JBQUVFLGFBQUYsQ0FBZ0JILEtBQWhCLENBSkMsQ0FBTjtBQU1BLGVBQU9FLGFBQVA7QUFDRDtBQVZVO0FBQUE7QUFBQSxtQ0FZR0UsUUFaSCxFQVlhO0FBQUE7O0FBQUEsWUFFcEJDLE9BRm9CLEdBY2xCRCxRQWRrQixDQUVwQkMsT0FGb0I7QUFBQSxnQ0FjbEJELFFBZGtCLENBR3BCRSxPQUhvQjtBQUFBLFlBR3BCQSxPQUhvQixxQ0FHVixFQUhVO0FBQUEsWUFJcEJDLElBSm9CLEdBY2xCSCxRQWRrQixDQUlwQkcsSUFKb0I7QUFBQSxZQUtwQkMsVUFMb0IsR0FjbEJKLFFBZGtCLENBS3BCSSxVQUxvQjtBQUFBLFlBTXBCQyxXQU5vQixHQWNsQkwsUUFka0IsQ0FNcEJLLFdBTm9CO0FBQUEsWUFPcEJDLFVBUG9CLEdBY2xCTixRQWRrQixDQU9wQk0sVUFQb0I7QUFBQSxZQVFwQkMsYUFSb0IsR0FjbEJQLFFBZGtCLENBUXBCTyxhQVJvQjtBQUFBLFlBU3BCQyxlQVRvQixHQWNsQlIsUUFka0IsQ0FTcEJRLGVBVG9CO0FBQUEsWUFVcEJDLFdBVm9CLEdBY2xCVCxRQWRrQixDQVVwQlMsV0FWb0I7QUFBQSxZQVdwQkMsUUFYb0IsR0FjbEJWLFFBZGtCLENBV3BCVSxRQVhvQjtBQUFBLFlBWXBCQyxpQkFab0IsR0FjbEJYLFFBZGtCLENBWXBCVyxpQkFab0I7QUFBQSxZQWFwQkMsWUFib0IsR0FjbEJaLFFBZGtCLENBYXBCWSxZQWJvQjs7QUFnQnRCOztBQUNBLFlBQUlDLGtCQUFrQixLQUF0QjtBQUNBWixnQkFBUWEsT0FBUixDQUFnQixrQkFBVTtBQUN4QixjQUFJQyxPQUFPZCxPQUFYLEVBQW9CO0FBQ2xCWSw4QkFBa0IsSUFBbEI7QUFDRDtBQUNGLFNBSkQ7O0FBTUEsWUFBSUcsbURBQTBCZixPQUExQixFQUFKOztBQUVBLFlBQUlnQixpQkFBaUJoQixRQUFRaUIsSUFBUixDQUNuQjtBQUFBLGlCQUNFQyxJQUFJQyxRQUFKLElBQ0NELElBQUlsQixPQUFKLElBQWVrQixJQUFJbEIsT0FBSixDQUFZb0IsSUFBWixDQUFpQjtBQUFBLG1CQUFRQyxLQUFLRixRQUFiO0FBQUEsV0FBakIsQ0FGbEI7QUFBQSxTQURtQixDQUFyQjtBQUtBO0FBQ0EsWUFBSUgsa0JBQWtCLENBQUNBLGVBQWVHLFFBQXRDLEVBQWdEO0FBQzlDSCwyQkFBaUJBLGVBQWVoQixPQUFmLENBQXVCaUIsSUFBdkIsQ0FBNEI7QUFBQSxtQkFBT0MsSUFBSUMsUUFBWDtBQUFBLFdBQTVCLENBQWpCO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJUixnQkFBZ0IsQ0FBQ0ssY0FBckIsRUFBcUM7QUFDbkNBLDJCQUFpQixFQUFFRyxVQUFVLElBQVosRUFBakI7QUFDQUosaUNBQXVCQyxjQUF2Qiw0QkFBMENELG1CQUExQztBQUNEOztBQUVELFlBQU1PLHNCQUFzQixTQUF0QkEsbUJBQXNCLENBQUNSLE1BQUQsRUFBU1MsWUFBVCxFQUEwQjtBQUNwRCxjQUFJQyxhQUFKO0FBQ0EsY0FBSVYsT0FBT0ssUUFBWCxFQUFxQjtBQUNuQkssZ0NBQ0ssT0FBSzdCLEtBQUwsQ0FBV21CLE1BRGhCLEVBRUssT0FBS25CLEtBQUwsQ0FBVzhCLGdCQUZoQixFQUdLWCxNQUhMO0FBS0QsV0FORCxNQU1PO0FBQ0xVLGdDQUNLLE9BQUs3QixLQUFMLENBQVdtQixNQURoQixFQUVLQSxNQUZMO0FBSUQ7O0FBRUQ7QUFDQSxjQUFJVSxLQUFLRSxRQUFMLEdBQWdCRixLQUFLRyxRQUF6QixFQUFtQztBQUNqQ0gsaUJBQUtHLFFBQUwsR0FBZ0JILEtBQUtFLFFBQXJCO0FBQ0Q7O0FBRUQsY0FBSUgsWUFBSixFQUFrQjtBQUNoQkMsaUJBQUtELFlBQUwsR0FBb0JBLFlBQXBCO0FBQ0Q7O0FBRUQ7QUFDQSxjQUFJLE9BQU9DLEtBQUtJLFFBQVosS0FBeUIsUUFBN0IsRUFBdUM7QUFBQTtBQUNyQ0osbUJBQUtLLEVBQUwsR0FBVUwsS0FBS0ssRUFBTCxJQUFXTCxLQUFLSSxRQUExQjtBQUNBLGtCQUFNRSxpQkFBaUJOLEtBQUtJLFFBQTVCO0FBQ0FKLG1CQUFLSSxRQUFMLEdBQWdCO0FBQUEsdUJBQU8sZ0JBQUVHLEdBQUYsQ0FBTUMsR0FBTixFQUFXRixjQUFYLENBQVA7QUFBQSxlQUFoQjtBQUNBO0FBQUEsbUJBQU9OO0FBQVA7QUFKcUM7O0FBQUE7QUFLdEM7O0FBRUQ7QUFDQSxjQUFJQSxLQUFLSSxRQUFMLElBQWlCLENBQUNKLEtBQUtLLEVBQTNCLEVBQStCO0FBQzdCSSxvQkFBUUMsSUFBUixDQUFhVixJQUFiO0FBQ0Esa0JBQU0sSUFBSVcsS0FBSixDQUNKLDBFQURJLENBQU47QUFHRDs7QUFFRDtBQUNBLGNBQUksQ0FBQ1gsS0FBS0ksUUFBVixFQUFvQjtBQUNsQkosaUJBQUtJLFFBQUwsR0FBZ0I7QUFBQSxxQkFBS1EsU0FBTDtBQUFBLGFBQWhCO0FBQ0Q7O0FBRUQsaUJBQU9aLElBQVA7QUFDRCxTQTlDRDs7QUFnREE7QUFDQSxZQUFNYSxzQkFBc0IsU0FBdEJBLG1CQUFzQixDQUFDdkIsTUFBRCxFQUFTUyxZQUFULEVBQTBCO0FBQ3BELGNBQU1lLGtCQUFrQmhCLG9CQUFvQlIsTUFBcEIsRUFBNEJTLFlBQTVCLENBQXhCO0FBQ0FnQiw4QkFBb0JDLElBQXBCLENBQXlCRixlQUF6QjtBQUNBLGlCQUFPQSxlQUFQO0FBQ0QsU0FKRDtBQUtBLFlBQU1DLHNCQUFzQixFQUE1QjtBQUNBLFlBQU1FLG1CQUFtQjFCLG9CQUFvQjJCLEdBQXBCLENBQXdCLFVBQUM1QixNQUFELEVBQVM2QixDQUFULEVBQWU7QUFDOUQsY0FBSTdCLE9BQU9kLE9BQVgsRUFBb0I7QUFDbEIsZ0NBQ0tjLE1BREw7QUFFRWQsdUJBQVNjLE9BQU9kLE9BQVAsQ0FBZTBDLEdBQWYsQ0FBbUI7QUFBQSx1QkFBS0wsb0JBQW9CTyxDQUFwQixFQUF1QjlCLE1BQXZCLENBQUw7QUFBQSxlQUFuQjtBQUZYO0FBSUQsV0FMRCxNQUtPO0FBQ0wsbUJBQU91QixvQkFBb0J2QixNQUFwQixDQUFQO0FBQ0Q7QUFDRixTQVR3QixDQUF6Qjs7QUFXQTtBQUNBLFlBQUkrQixpQkFBaUJKLGlCQUFpQkssS0FBakIsRUFBckI7QUFDQSxZQUFJQyxvQkFBb0IsRUFBeEI7O0FBRUFGLHlCQUFpQkEsZUFBZUgsR0FBZixDQUFtQixVQUFDNUIsTUFBRCxFQUFTNkIsQ0FBVCxFQUFlO0FBQ2pELGNBQUk3QixPQUFPZCxPQUFYLEVBQW9CO0FBQ2xCLGdCQUFNZ0Qsb0JBQW9CbEMsT0FBT2QsT0FBUCxDQUFlaUQsTUFBZixDQUN4QjtBQUFBLHFCQUNFaEQsUUFBUWlELE9BQVIsQ0FBZ0JOLEVBQUVmLEVBQWxCLElBQXdCLENBQUMsQ0FBekIsR0FDSSxLQURKLEdBRUksZ0JBQUVzQixlQUFGLENBQWtCUCxFQUFFUSxJQUFwQixFQUEwQixJQUExQixDQUhOO0FBQUEsYUFEd0IsQ0FBMUI7QUFNQSxnQ0FDS3RDLE1BREw7QUFFRWQsdUJBQVNnRDtBQUZYO0FBSUQ7QUFDRCxpQkFBT2xDLE1BQVA7QUFDRCxTQWRnQixDQUFqQjs7QUFnQkErQix5QkFBaUJBLGVBQWVJLE1BQWYsQ0FBc0Isa0JBQVU7QUFDL0MsaUJBQU9uQyxPQUFPZCxPQUFQLEdBQ0hjLE9BQU9kLE9BQVAsQ0FBZXFELE1BRFosR0FFSHBELFFBQVFpRCxPQUFSLENBQWdCcEMsT0FBT2UsRUFBdkIsSUFBNkIsQ0FBQyxDQUE5QixHQUNFLEtBREYsR0FFRSxnQkFBRXNCLGVBQUYsQ0FBa0JyQyxPQUFPc0MsSUFBekIsRUFBK0IsSUFBL0IsQ0FKTjtBQUtELFNBTmdCLENBQWpCOztBQVFBO0FBQ0EsWUFBTUUsYUFBYVQsZUFBZVUsU0FBZixDQUF5QjtBQUFBLGlCQUFPckMsSUFBSXNDLEtBQVg7QUFBQSxTQUF6QixDQUFuQjs7QUFFQTtBQUNBLFlBQUl2RCxRQUFRb0QsTUFBWixFQUFvQjtBQUFBO0FBQ2xCO0FBQ0EsZ0JBQU1JLGVBQWUsRUFBckI7QUFDQXhELG9CQUFRWSxPQUFSLENBQWdCLG1CQUFXO0FBQ3pCLGtCQUFNNkMsUUFBUW5CLG9CQUFvQnRCLElBQXBCLENBQXlCO0FBQUEsdUJBQUsyQixFQUFFZixFQUFGLEtBQVM4QixPQUFkO0FBQUEsZUFBekIsQ0FBZDtBQUNBLGtCQUFJRCxLQUFKLEVBQVc7QUFDVEQsNkJBQWFqQixJQUFiLENBQWtCa0IsS0FBbEI7QUFDRDtBQUNGLGFBTEQ7O0FBT0EsZ0JBQUlFLG9CQUFvQkgsYUFBYUksTUFBYixDQUN0QixVQUFDQyxJQUFELEVBQU9DLE9BQVA7QUFBQSxxQkFDRUQsUUFBUUEsU0FBU0MsUUFBUXhDLFlBQXpCLElBQXlDd0MsUUFBUXhDLFlBRG5EO0FBQUEsYUFEc0IsRUFHdEJrQyxhQUFhLENBQWIsRUFBZ0JsQyxZQUhNLENBQXhCOztBQU1BLGdCQUFJeUMsbUJBQW1CcEQsbUJBQW1CZ0Qsa0JBQWtCSyxNQUE1RDtBQUNBRCwrQkFBbUJBLG9CQUFxQjtBQUFBLHFCQUFNO0FBQUE7QUFBQTtBQUFBO0FBQUEsZUFBTjtBQUFBLGFBQXhDOztBQUVBLGdCQUFJRSxtQkFBbUI7QUFDckJELHNCQUFRRCxnQkFEYTtBQUVyQmhFLHVCQUFTeUQsYUFBYWYsR0FBYixDQUFpQjtBQUFBLG9DQUNyQixPQUFLL0MsS0FBTCxDQUFXd0UsYUFEVSxFQUVyQmpELEdBRnFCO0FBR3hCa0QsMkJBQVM7QUFIZTtBQUFBLGVBQWpCO0FBRlksYUFBdkI7O0FBU0E7QUFDQSxnQkFBSWQsY0FBYyxDQUFsQixFQUFxQjtBQUNuQlksOENBQ0tyQixlQUFlUyxVQUFmLENBREwsRUFFS1ksZ0JBRkw7QUFJQXJCLDZCQUFld0IsTUFBZixDQUFzQmYsVUFBdEIsRUFBa0MsQ0FBbEMsRUFBcUNZLGdCQUFyQztBQUNELGFBTkQsTUFNTztBQUNMckIsNkJBQWV5QixPQUFmLENBQXVCSixnQkFBdkI7QUFDRDtBQXJDaUI7QUFzQ25COztBQUVEO0FBQ0EsWUFBTUssZUFBZSxFQUFyQjtBQUNBLFlBQUlDLGNBQWMsRUFBbEI7O0FBRUE7QUFDQSxZQUFNQyxZQUFZLFNBQVpBLFNBQVksQ0FBQ3pFLE9BQUQsRUFBVWMsTUFBVixFQUFxQjtBQUNyQ3lELHVCQUFhL0IsSUFBYixjQUNLLE9BQUs3QyxLQUFMLENBQVdtQixNQURoQixFQUVLQSxNQUZMO0FBR0VkLHFCQUFTQTtBQUhYO0FBS0F3RSx3QkFBYyxFQUFkO0FBQ0QsU0FQRDs7QUFTQTtBQUNBM0IsdUJBQWVoQyxPQUFmLENBQXVCLFVBQUNDLE1BQUQsRUFBUzZCLENBQVQsRUFBZTtBQUNwQyxjQUFJN0IsT0FBT2QsT0FBWCxFQUFvQjtBQUNsQitDLGdDQUFvQkEsa0JBQWtCMkIsTUFBbEIsQ0FBeUI1RCxPQUFPZCxPQUFoQyxDQUFwQjtBQUNBLGdCQUFJd0UsWUFBWW5CLE1BQVosR0FBcUIsQ0FBekIsRUFBNEI7QUFDMUJvQix3QkFBVUQsV0FBVjtBQUNEO0FBQ0RDLHNCQUFVM0QsT0FBT2QsT0FBakIsRUFBMEJjLE1BQTFCO0FBQ0E7QUFDRDtBQUNEaUMsNEJBQWtCUCxJQUFsQixDQUF1QjFCLE1BQXZCO0FBQ0EwRCxzQkFBWWhDLElBQVosQ0FBaUIxQixNQUFqQjtBQUNELFNBWEQ7QUFZQSxZQUFJRixtQkFBbUI0RCxZQUFZbkIsTUFBWixHQUFxQixDQUE1QyxFQUErQztBQUM3Q29CLG9CQUFVRCxXQUFWO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFNRyxZQUFZLFNBQVpBLFNBQVksQ0FBQy9CLENBQUQsRUFBSUQsQ0FBSixFQUFxQjtBQUFBOztBQUFBLGNBQWRpQyxLQUFjLHVFQUFOLENBQU07O0FBQ3JDLGNBQU01Qyx3Q0FDSHhCLFdBREcsRUFDV29DLENBRFgseUJBRUhuQyxRQUZHLEVBRVFrQyxDQUZSLHlCQUdIdEMsVUFIRyxFQUdVdUMsRUFBRXZDLFVBQUYsQ0FIVix5QkFJSEUsZUFKRyxFQUllcUUsS0FKZixRQUFOO0FBTUFyQyw4QkFBb0IxQixPQUFwQixDQUE0QixrQkFBVTtBQUNwQyxnQkFBSUMsT0FBT0ssUUFBWCxFQUFxQjtBQUNyQmEsZ0JBQUlsQixPQUFPZSxFQUFYLElBQWlCZixPQUFPYyxRQUFQLENBQWdCZ0IsQ0FBaEIsQ0FBakI7QUFDRCxXQUhEO0FBSUEsY0FBSVosSUFBSTNCLFVBQUosQ0FBSixFQUFxQjtBQUNuQjJCLGdCQUFJM0IsVUFBSixJQUFrQjJCLElBQUkzQixVQUFKLEVBQWdCcUMsR0FBaEIsQ0FBb0IsVUFBQ0UsQ0FBRCxFQUFJRCxDQUFKO0FBQUEscUJBQ3BDZ0MsVUFBVS9CLENBQVYsRUFBYUQsQ0FBYixFQUFnQmlDLFFBQVEsQ0FBeEIsQ0FEb0M7QUFBQSxhQUFwQixDQUFsQjtBQUdEO0FBQ0QsaUJBQU81QyxHQUFQO0FBQ0QsU0FqQkQ7QUFrQkEsWUFBSTZDLGVBQWUzRSxLQUFLd0MsR0FBTCxDQUFTLFVBQUNFLENBQUQsRUFBSUQsQ0FBSjtBQUFBLGlCQUFVZ0MsVUFBVS9CLENBQVYsRUFBYUQsQ0FBYixDQUFWO0FBQUEsU0FBVCxDQUFuQjs7QUFFQTtBQUNBLFlBQU1tQyxZQUFZLFNBQVpBLFNBQVksT0FBUTtBQUN4QixjQUFNQyxvQkFBb0IsRUFBMUI7QUFDQUMsNkJBQW1CbkUsT0FBbkIsQ0FBMkIsa0JBQVU7QUFDbkMsZ0JBQU1vRSxTQUFTQyxLQUFLeEMsR0FBTCxDQUFTO0FBQUEscUJBQUtFLEVBQUU5QixPQUFPZSxFQUFULENBQUw7QUFBQSxhQUFULENBQWY7QUFDQWtELDhCQUFrQmpFLE9BQU9lLEVBQXpCLElBQStCZixPQUFPZ0UsU0FBUCxDQUFpQkcsTUFBakIsRUFBeUJDLElBQXpCLENBQS9CO0FBQ0QsV0FIRDtBQUlBLGlCQUFPSCxpQkFBUDtBQUNELFNBUEQ7O0FBU0E7QUFDQSxZQUFNQyxxQkFBcUJqQyxrQkFBa0JFLE1BQWxCLENBQ3pCO0FBQUEsaUJBQUssQ0FBQ0wsRUFBRXpCLFFBQUgsSUFBZXlCLEVBQUVrQyxTQUF0QjtBQUFBLFNBRHlCLENBQTNCO0FBR0EsWUFBSTdFLFFBQVFvRCxNQUFaLEVBQW9CO0FBQUE7QUFDbEIsZ0JBQU04QixtQkFBbUIsU0FBbkJBLGdCQUFtQixDQUFDRCxJQUFELEVBQU9FLElBQVAsRUFBdUI7QUFBQSxrQkFBVnpDLENBQVUsdUVBQU4sQ0FBTTs7QUFDOUM7QUFDQSxrQkFBSUEsTUFBTXlDLEtBQUsvQixNQUFmLEVBQXVCO0FBQ3JCLHVCQUFPNkIsSUFBUDtBQUNEO0FBQ0Q7QUFDQSxrQkFBSUcsY0FBY0MsT0FBT0MsT0FBUCxDQUNoQixnQkFBRUMsT0FBRixDQUFVTixJQUFWLEVBQWdCRSxLQUFLekMsQ0FBTCxDQUFoQixDQURnQixFQUVoQkQsR0FGZ0IsQ0FFWixnQkFBa0I7QUFBQTs7QUFBQTtBQUFBLG9CQUFoQitDLEdBQWdCO0FBQUEsb0JBQVhDLEtBQVc7O0FBQ3RCLDBEQUNHdkYsVUFESCxFQUNnQmlGLEtBQUt6QyxDQUFMLENBRGhCLDBCQUVHdkMsV0FGSCxFQUVpQnFGLEdBRmpCLDBCQUdHTCxLQUFLekMsQ0FBTCxDQUhILEVBR2E4QyxHQUhiLDBCQUlHcEYsVUFKSCxFQUlnQnFGLEtBSmhCLDBCQUtHbkYsZUFMSCxFQUtxQm9DLENBTHJCLDBCQU1HakMsaUJBTkgsRUFNdUIsSUFOdkI7QUFRRCxlQVhpQixDQUFsQjtBQVlBO0FBQ0EyRSw0QkFBY0EsWUFBWTNDLEdBQVosQ0FBZ0Isb0JBQVk7QUFBQTs7QUFDeEMsb0JBQUlpRCxVQUFVUixpQkFBaUJTLFNBQVN2RixVQUFULENBQWpCLEVBQXVDK0UsSUFBdkMsRUFBNkN6QyxJQUFJLENBQWpELENBQWQ7QUFDQSxvQ0FDS2lELFFBREwsOENBRUd2RixVQUZILEVBRWdCc0YsT0FGaEIsOEJBR0dyRixhQUhILEVBR21CLElBSG5CLGVBSUt3RSxVQUFVYSxPQUFWLENBSkw7QUFNRCxlQVJhLENBQWQ7QUFTQSxxQkFBT04sV0FBUDtBQUNELGFBN0JEO0FBOEJBUiwyQkFBZU0saUJBQWlCTixZQUFqQixFQUErQjVFLE9BQS9CLENBQWY7QUEvQmtCO0FBZ0NuQjs7QUFFRCw0QkFDS0YsUUFETDtBQUVFOEUsb0NBRkY7QUFHRTlCLDhDQUhGO0FBSUV3QixvQ0FKRjtBQUtFaEMsa0RBTEY7QUFNRTNCO0FBTkY7QUFRRDtBQTVTVTtBQUFBO0FBQUEsb0NBOFNJZixhQTlTSixFQThTbUI7QUFBQSxZQUUxQmdHLE1BRjBCLEdBU3hCaEcsYUFUd0IsQ0FFMUJnRyxNQUYwQjtBQUFBLFlBRzFCQyxNQUgwQixHQVN4QmpHLGFBVHdCLENBRzFCaUcsTUFIMEI7QUFBQSxZQUkxQkMsUUFKMEIsR0FTeEJsRyxhQVR3QixDQUkxQmtHLFFBSjBCO0FBQUEsWUFLMUJDLG1CQUwwQixHQVN4Qm5HLGFBVHdCLENBSzFCbUcsbUJBTDBCO0FBQUEsWUFNMUJuQixZQU4wQixHQVN4QmhGLGFBVHdCLENBTTFCZ0YsWUFOMEI7QUFBQSxZQU8xQjlCLGlCQVAwQixHQVN4QmxELGFBVHdCLENBTzFCa0QsaUJBUDBCO0FBQUEsWUFRMUJSLG1CQVIwQixHQVN4QjFDLGFBVHdCLENBUTFCMEMsbUJBUjBCOzs7QUFXNUIsWUFBTTBELHdCQUF3QixFQUE5Qjs7QUFFQTFELDRCQUFvQlUsTUFBcEIsQ0FBMkI7QUFBQSxpQkFBTy9CLElBQUlnRixVQUFYO0FBQUEsU0FBM0IsRUFBa0RyRixPQUFsRCxDQUEwRCxlQUFPO0FBQy9Eb0YsZ0NBQXNCL0UsSUFBSVcsRUFBMUIsSUFBZ0NYLElBQUlnRixVQUFwQztBQUNELFNBRkQ7O0FBSUE7QUFDQSxlQUFPO0FBQ0xDLHNCQUFZTixTQUNSaEIsWUFEUSxHQUVSLEtBQUt1QixRQUFMLENBQ0EsS0FBS0MsVUFBTCxDQUNFeEIsWUFERixFQUVFa0IsUUFGRixFQUdFQyxtQkFIRixFQUlFakQsaUJBSkYsQ0FEQSxFQU9BK0MsTUFQQSxFQVFBRyxxQkFSQTtBQUhDLFNBQVA7QUFjRDtBQTlVVTtBQUFBO0FBQUEsc0NBZ1ZNO0FBQ2YsYUFBS3RHLEtBQUwsQ0FBVzJHLFdBQVgsQ0FBdUIsS0FBS0MsZ0JBQUwsRUFBdkIsRUFBZ0QsSUFBaEQ7QUFDRDtBQWxWVTtBQUFBO0FBQUEscUNBb1ZLZCxHQXBWTCxFQW9WVTtBQUNuQixlQUFPLGdCQUFFdEMsZUFBRixDQUFrQixLQUFLeEQsS0FBTCxDQUFXOEYsR0FBWCxDQUFsQixFQUFtQyxLQUFLN0YsS0FBTCxDQUFXNkYsR0FBWCxDQUFuQyxDQUFQO0FBQ0Q7QUF0VlU7QUFBQTtBQUFBLHFDQXdWS0EsR0F4VkwsRUF3VlU7QUFDbkIsZUFBTyxnQkFBRXRDLGVBQUYsQ0FBa0IsS0FBS3ZELEtBQUwsQ0FBVzZGLEdBQVgsQ0FBbEIsRUFBbUMsS0FBSzlGLEtBQUwsQ0FBVzhGLEdBQVgsQ0FBbkMsQ0FBUDtBQUNEO0FBMVZVO0FBQUE7QUFBQSxpQ0E0VkN2RixJQTVWRCxFQTRWTzZGLFFBNVZQLEVBNFZpQkMsbUJBNVZqQixFQTRWc0NqRCxpQkE1VnRDLEVBNFZ5RDtBQUFBOztBQUNsRSxZQUFJeUQsZUFBZXRHLElBQW5COztBQUVBLFlBQUk2RixTQUFTMUMsTUFBYixFQUFxQjtBQUNuQm1ELHlCQUFlVCxTQUFTbEMsTUFBVCxDQUFnQixVQUFDNEMsYUFBRCxFQUFnQkMsVUFBaEIsRUFBK0I7QUFDNUQsZ0JBQU01RixTQUFTaUMsa0JBQWtCOUIsSUFBbEIsQ0FBdUI7QUFBQSxxQkFBSzBGLEVBQUU5RSxFQUFGLEtBQVM2RSxXQUFXN0UsRUFBekI7QUFBQSxhQUF2QixDQUFmOztBQUVBO0FBQ0EsZ0JBQUksQ0FBQ2YsTUFBRCxJQUFXQSxPQUFPOEYsVUFBUCxLQUFzQixLQUFyQyxFQUE0QztBQUMxQyxxQkFBT0gsYUFBUDtBQUNEOztBQUVELGdCQUFNSSxlQUFlL0YsT0FBTytGLFlBQVAsSUFBdUJiLG1CQUE1Qzs7QUFFQTtBQUNBLGdCQUFJbEYsT0FBT2dHLFNBQVgsRUFBc0I7QUFDcEIscUJBQU9ELGFBQWFILFVBQWIsRUFBeUJELGFBQXpCLEVBQXdDM0YsTUFBeEMsQ0FBUDtBQUNELGFBRkQsTUFFTztBQUNMLHFCQUFPMkYsY0FBY3hELE1BQWQsQ0FBcUIsZUFBTztBQUNqQyx1QkFBTzRELGFBQWFILFVBQWIsRUFBeUIxRSxHQUF6QixFQUE4QmxCLE1BQTlCLENBQVA7QUFDRCxlQUZNLENBQVA7QUFHRDtBQUNGLFdBbEJjLEVBa0JaMEYsWUFsQlksQ0FBZjs7QUFvQkE7QUFDQTtBQUNBQSx5QkFBZUEsYUFDWjlELEdBRFksQ0FDUixlQUFPO0FBQ1YsZ0JBQUksQ0FBQ1YsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBQUwsRUFBaUM7QUFDL0IscUJBQU8yQixHQUFQO0FBQ0Q7QUFDRCxnQ0FDS0EsR0FETCxzQkFFRyxPQUFLckMsS0FBTCxDQUFXVSxVQUZkLEVBRTJCLE9BQUtnRyxVQUFMLENBQ3ZCckUsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBRHVCLEVBRXZCMEYsUUFGdUIsRUFHdkJDLG1CQUh1QixFQUl2QmpELGlCQUp1QixDQUYzQjtBQVNELFdBZFksRUFlWkUsTUFmWSxDQWVMLGVBQU87QUFDYixnQkFBSSxDQUFDakIsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBQUwsRUFBaUM7QUFDL0IscUJBQU8sSUFBUDtBQUNEO0FBQ0QsbUJBQU8yQixJQUFJLE9BQUtyQyxLQUFMLENBQVdVLFVBQWYsRUFBMkJnRCxNQUEzQixHQUFvQyxDQUEzQztBQUNELFdBcEJZLENBQWY7QUFxQkQ7O0FBRUQsZUFBT21ELFlBQVA7QUFDRDtBQTlZVTtBQUFBO0FBQUEsK0JBZ1pEdEcsSUFoWkMsRUFnWks0RixNQWhaTCxFQWdaeUM7QUFBQTs7QUFBQSxZQUE1QkcscUJBQTRCLHVFQUFKLEVBQUk7O0FBQ2xELFlBQUksQ0FBQ0gsT0FBT3pDLE1BQVosRUFBb0I7QUFDbEIsaUJBQU9uRCxJQUFQO0FBQ0Q7O0FBRUQsWUFBTWlHLGFBQWEsQ0FBQyxLQUFLeEcsS0FBTCxDQUFXb0gsYUFBWCxJQUE0QixnQkFBRUMsT0FBL0IsRUFDakI5RyxJQURpQixFQUVqQjRGLE9BQU9wRCxHQUFQLENBQVcsZ0JBQVE7QUFDakI7QUFDQSxjQUFJdUQsc0JBQXNCZ0IsS0FBS3BGLEVBQTNCLENBQUosRUFBb0M7QUFDbEMsbUJBQU8sVUFBQ3FGLENBQUQsRUFBSUMsQ0FBSixFQUFVO0FBQ2YscUJBQU9sQixzQkFBc0JnQixLQUFLcEYsRUFBM0IsRUFBK0JxRixFQUFFRCxLQUFLcEYsRUFBUCxDQUEvQixFQUEyQ3NGLEVBQUVGLEtBQUtwRixFQUFQLENBQTNDLENBQVA7QUFDRCxhQUZEO0FBR0Q7QUFDRCxpQkFBTyxVQUFDcUYsQ0FBRCxFQUFJQyxDQUFKLEVBQVU7QUFDZixtQkFBTyxPQUFLeEgsS0FBTCxDQUFXeUgsaUJBQVgsQ0FBNkJGLEVBQUVELEtBQUtwRixFQUFQLENBQTdCLEVBQXlDc0YsRUFBRUYsS0FBS3BGLEVBQVAsQ0FBekMsQ0FBUDtBQUNELFdBRkQ7QUFHRCxTQVZELENBRmlCLEVBYWpCaUUsT0FBT3BELEdBQVAsQ0FBVztBQUFBLGlCQUFLLENBQUNFLEVBQUV5RSxJQUFSO0FBQUEsU0FBWCxDQWJpQixFQWNqQixLQUFLMUgsS0FBTCxDQUFXYyxRQWRNLENBQW5COztBQWlCQTBGLG1CQUFXdEYsT0FBWCxDQUFtQixlQUFPO0FBQ3hCLGNBQUksQ0FBQ21CLElBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixDQUFMLEVBQWlDO0FBQy9CO0FBQ0Q7QUFDRDJCLGNBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixJQUE2QixPQUFLK0YsUUFBTCxDQUMzQnBFLElBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixDQUQyQixFQUUzQnlGLE1BRjJCLEVBRzNCRyxxQkFIMkIsQ0FBN0I7QUFLRCxTQVREOztBQVdBLGVBQU9FLFVBQVA7QUFDRDtBQWxiVTtBQUFBO0FBQUEsbUNBb2JHO0FBQ1osZUFBTyxnQkFBRWhELGVBQUYsQ0FDTCxLQUFLeEQsS0FBTCxDQUFXMkgsT0FETixFQUVMLEtBQUtDLGNBQUwsQ0FBb0IsVUFBcEIsQ0FGSyxDQUFQO0FBSUQ7O0FBRUQ7O0FBM2JXO0FBQUE7QUFBQSxtQ0E0YkdDLElBNWJILEVBNGJTO0FBQUEscUJBQzZCLEtBQUs3SCxLQURsQztBQUFBLFlBQ1Y4SCxZQURVLFVBQ1ZBLFlBRFU7QUFBQSxZQUNJQyxvQkFESixVQUNJQSxvQkFESjs7O0FBR2xCLFlBQU0zSCxXQUFXLEVBQUV5SCxVQUFGLEVBQWpCO0FBQ0EsWUFBSUUsb0JBQUosRUFBMEI7QUFDeEIzSCxtQkFBUzRILFFBQVQsR0FBb0IsRUFBcEI7QUFDRDtBQUNELGFBQUtDLGdCQUFMLENBQXNCN0gsUUFBdEIsRUFBZ0MsWUFBTTtBQUNwQzBILDBCQUFnQkEsYUFBYUQsSUFBYixDQUFoQjtBQUNELFNBRkQ7QUFHRDtBQXRjVTtBQUFBO0FBQUEsdUNBd2NPSyxXQXhjUCxFQXdjb0I7QUFBQSxZQUNyQkMsZ0JBRHFCLEdBQ0EsS0FBS25JLEtBREwsQ0FDckJtSSxnQkFEcUI7O0FBQUEsZ0NBRUYsS0FBS3ZCLGdCQUFMLEVBRkU7QUFBQSxZQUVyQndCLFFBRnFCLHFCQUVyQkEsUUFGcUI7QUFBQSxZQUVYUCxJQUZXLHFCQUVYQSxJQUZXOztBQUk3Qjs7O0FBQ0EsWUFBTVEsYUFBYUQsV0FBV1AsSUFBOUI7QUFDQSxZQUFNUyxVQUFVQyxLQUFLQyxLQUFMLENBQVdILGFBQWFILFdBQXhCLENBQWhCOztBQUVBLGFBQUtELGdCQUFMLENBQ0U7QUFDRUcsb0JBQVVGLFdBRFo7QUFFRUwsZ0JBQU1TO0FBRlIsU0FERixFQUtFLFlBQU07QUFDSkgsOEJBQW9CQSxpQkFBaUJELFdBQWpCLEVBQThCSSxPQUE5QixDQUFwQjtBQUNELFNBUEg7QUFTRDtBQXpkVTtBQUFBO0FBQUEsaUNBMmRDbkgsTUEzZEQsRUEyZFNzSCxRQTNkVCxFQTJkbUI7QUFBQSxpQ0FDc0IsS0FBSzdCLGdCQUFMLEVBRHRCO0FBQUEsWUFDcEJULE1BRG9CLHNCQUNwQkEsTUFEb0I7QUFBQSxZQUNadUMsWUFEWSxzQkFDWkEsWUFEWTtBQUFBLFlBQ0VDLGVBREYsc0JBQ0VBLGVBREY7O0FBRzVCLFlBQU1DLHFCQUFxQnpILE9BQU8wSCxjQUFQLENBQXNCLGlCQUF0QixJQUN2QjFILE9BQU93SCxlQURnQixHQUV2QkEsZUFGSjtBQUdBLFlBQU1HLHNCQUFzQixDQUFDRixrQkFBN0I7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7QUFDQSxZQUFJRixZQUFKLEVBQWtCO0FBQ2hCLGVBQUtULGdCQUFMLENBQXNCO0FBQ3BCUywwQkFBYztBQURNLFdBQXRCO0FBR0E7QUFDRDs7QUFqQjJCLFlBbUJwQkssY0FuQm9CLEdBbUJELEtBQUsvSSxLQW5CSixDQW1CcEIrSSxjQW5Cb0I7OztBQXFCNUIsWUFBSUMsWUFBWSxnQkFBRUMsS0FBRixDQUFROUMsVUFBVSxFQUFsQixFQUFzQnBELEdBQXRCLENBQTBCLGFBQUs7QUFDN0NFLFlBQUV5RSxJQUFGLEdBQVMsZ0JBQUV3QixhQUFGLENBQWdCakcsQ0FBaEIsQ0FBVDtBQUNBLGlCQUFPQSxDQUFQO0FBQ0QsU0FIZSxDQUFoQjtBQUlBLFlBQUksQ0FBQyxnQkFBRWtHLE9BQUYsQ0FBVWhJLE1BQVYsQ0FBTCxFQUF3QjtBQUN0QjtBQUNBLGNBQU1pSSxnQkFBZ0JKLFVBQVVwRixTQUFWLENBQW9CO0FBQUEsbUJBQUtYLEVBQUVmLEVBQUYsS0FBU2YsT0FBT2UsRUFBckI7QUFBQSxXQUFwQixDQUF0QjtBQUNBLGNBQUlrSCxnQkFBZ0IsQ0FBQyxDQUFyQixFQUF3QjtBQUN0QixnQkFBTUMsV0FBV0wsVUFBVUksYUFBVixDQUFqQjtBQUNBLGdCQUFJQyxTQUFTM0IsSUFBVCxLQUFrQm9CLG1CQUF0QixFQUEyQztBQUN6QyxrQkFBSUwsUUFBSixFQUFjO0FBQ1pPLDBCQUFVdEUsTUFBVixDQUFpQjBFLGFBQWpCLEVBQWdDLENBQWhDO0FBQ0QsZUFGRCxNQUVPO0FBQ0xDLHlCQUFTM0IsSUFBVCxHQUFnQmtCLGtCQUFoQjtBQUNBSSw0QkFBWSxDQUFDSyxRQUFELENBQVo7QUFDRDtBQUNGLGFBUEQsTUFPTztBQUNMQSx1QkFBUzNCLElBQVQsR0FBZ0JvQixtQkFBaEI7QUFDQSxrQkFBSSxDQUFDTCxRQUFMLEVBQWU7QUFDYk8sNEJBQVksQ0FBQ0ssUUFBRCxDQUFaO0FBQ0Q7QUFDRjtBQUNGLFdBZkQsTUFlTztBQUNMLGdCQUFJWixRQUFKLEVBQWM7QUFDWk8sd0JBQVVuRyxJQUFWLENBQWU7QUFDYlgsb0JBQUlmLE9BQU9lLEVBREU7QUFFYndGLHNCQUFNa0I7QUFGTyxlQUFmO0FBSUQsYUFMRCxNQUtPO0FBQ0xJLDBCQUFZLENBQ1Y7QUFDRTlHLG9CQUFJZixPQUFPZSxFQURiO0FBRUV3RixzQkFBTWtCO0FBRlIsZUFEVSxDQUFaO0FBTUQ7QUFDRjtBQUNGLFNBakNELE1BaUNPO0FBQUE7QUFDTDtBQUNBLGdCQUFNUSxnQkFBZ0JKLFVBQVVwRixTQUFWLENBQW9CO0FBQUEscUJBQUtYLEVBQUVmLEVBQUYsS0FBU2YsT0FBTyxDQUFQLEVBQVVlLEVBQXhCO0FBQUEsYUFBcEIsQ0FBdEI7QUFDQTtBQUNBLGdCQUFJa0gsZ0JBQWdCLENBQUMsQ0FBckIsRUFBd0I7QUFDdEIsa0JBQU1DLFlBQVdMLFVBQVVJLGFBQVYsQ0FBakI7QUFDQSxrQkFBSUMsVUFBUzNCLElBQVQsS0FBa0JvQixtQkFBdEIsRUFBMkM7QUFDekMsb0JBQUlMLFFBQUosRUFBYztBQUNaTyw0QkFBVXRFLE1BQVYsQ0FBaUIwRSxhQUFqQixFQUFnQ2pJLE9BQU91QyxNQUF2QztBQUNELGlCQUZELE1BRU87QUFDTHZDLHlCQUFPRCxPQUFQLENBQWUsVUFBQytCLENBQUQsRUFBSUQsQ0FBSixFQUFVO0FBQ3ZCZ0csOEJBQVVJLGdCQUFnQnBHLENBQTFCLEVBQTZCMEUsSUFBN0IsR0FBb0NrQixrQkFBcEM7QUFDRCxtQkFGRDtBQUdEO0FBQ0YsZUFSRCxNQVFPO0FBQ0x6SCx1QkFBT0QsT0FBUCxDQUFlLFVBQUMrQixDQUFELEVBQUlELENBQUosRUFBVTtBQUN2QmdHLDRCQUFVSSxnQkFBZ0JwRyxDQUExQixFQUE2QjBFLElBQTdCLEdBQW9Db0IsbUJBQXBDO0FBQ0QsaUJBRkQ7QUFHRDtBQUNELGtCQUFJLENBQUNMLFFBQUwsRUFBZTtBQUNiTyw0QkFBWUEsVUFBVTdGLEtBQVYsQ0FBZ0JpRyxhQUFoQixFQUErQmpJLE9BQU91QyxNQUF0QyxDQUFaO0FBQ0Q7QUFDRixhQWxCRCxNQWtCTztBQUNMO0FBQ0Esa0JBQUkrRSxRQUFKLEVBQWM7QUFDWk8sNEJBQVlBLFVBQVVqRSxNQUFWLENBQ1Y1RCxPQUFPNEIsR0FBUCxDQUFXO0FBQUEseUJBQU07QUFDZmIsd0JBQUllLEVBQUVmLEVBRFM7QUFFZndGLDBCQUFNa0I7QUFGUyxtQkFBTjtBQUFBLGlCQUFYLENBRFUsQ0FBWjtBQU1ELGVBUEQsTUFPTztBQUNMSSw0QkFBWTdILE9BQU80QixHQUFQLENBQVc7QUFBQSx5QkFBTTtBQUMzQmIsd0JBQUllLEVBQUVmLEVBRHFCO0FBRTNCd0YsMEJBQU1rQjtBQUZxQixtQkFBTjtBQUFBLGlCQUFYLENBQVo7QUFJRDtBQUNGO0FBckNJO0FBc0NOOztBQUVELGFBQUtYLGdCQUFMLENBQ0U7QUFDRUosZ0JBQ0csQ0FBQzFCLE9BQU96QyxNQUFSLElBQWtCc0YsVUFBVXRGLE1BQTdCLElBQXdDLENBQUMrRSxRQUF6QyxHQUNJLENBREosR0FFSSxLQUFLeEksS0FBTCxDQUFXNEgsSUFKbkI7QUFLRTFCLGtCQUFRNkM7QUFMVixTQURGLEVBUUUsWUFBTTtBQUNKRCw0QkFBa0JBLGVBQWVDLFNBQWYsRUFBMEI3SCxNQUExQixFQUFrQ3NILFFBQWxDLENBQWxCO0FBQ0QsU0FWSDtBQVlEO0FBemtCVTtBQUFBO0FBQUEsbUNBMmtCR3RILE1BM2tCSCxFQTJrQlc0RSxLQTNrQlgsRUEya0JrQjtBQUFBLGlDQUNOLEtBQUthLGdCQUFMLEVBRE07QUFBQSxZQUNuQlIsUUFEbUIsc0JBQ25CQSxRQURtQjs7QUFBQSxZQUVuQmtELGdCQUZtQixHQUVFLEtBQUt0SixLQUZQLENBRW5Cc0osZ0JBRm1COztBQUkzQjs7QUFDQSxZQUFNQyxlQUFlLENBQUNuRCxZQUFZLEVBQWIsRUFBaUI5QyxNQUFqQixDQUF3QixhQUFLO0FBQ2hELGNBQUkwRCxFQUFFOUUsRUFBRixLQUFTZixPQUFPZSxFQUFwQixFQUF3QjtBQUN0QixtQkFBTyxJQUFQO0FBQ0Q7QUFDRixTQUpvQixDQUFyQjs7QUFNQSxZQUFJNkQsVUFBVSxFQUFkLEVBQWtCO0FBQ2hCd0QsdUJBQWExRyxJQUFiLENBQWtCO0FBQ2hCWCxnQkFBSWYsT0FBT2UsRUFESztBQUVoQjZELG1CQUFPQTtBQUZTLFdBQWxCO0FBSUQ7O0FBRUQsYUFBS2tDLGdCQUFMLENBQ0U7QUFDRTdCLG9CQUFVbUQ7QUFEWixTQURGLEVBSUUsWUFBTTtBQUNKRCw4QkFBb0JBLGlCQUFpQkMsWUFBakIsRUFBK0JwSSxNQUEvQixFQUF1QzRFLEtBQXZDLENBQXBCO0FBQ0QsU0FOSDtBQVFEO0FBcm1CVTtBQUFBO0FBQUEsd0NBdW1CUXlELEtBdm1CUixFQXVtQmVySSxNQXZtQmYsRUF1bUJ1QnNJLE9Bdm1CdkIsRUF1bUJnQztBQUFBOztBQUN6Q0QsY0FBTUUsZUFBTjtBQUNBLFlBQU1DLGNBQWNILE1BQU1JLE1BQU4sQ0FBYUMsYUFBYixDQUEyQkMscUJBQTNCLEdBQ2pCQyxLQURIOztBQUdBLFlBQUlDLGNBQUo7QUFDQSxZQUFJUCxPQUFKLEVBQWE7QUFDWE8sa0JBQVFSLE1BQU1TLGNBQU4sQ0FBcUIsQ0FBckIsRUFBd0JELEtBQWhDO0FBQ0QsU0FGRCxNQUVPO0FBQ0xBLGtCQUFRUixNQUFNUSxLQUFkO0FBQ0Q7O0FBRUQsYUFBS0UsVUFBTCxHQUFrQixJQUFsQjtBQUNBLGFBQUtqQyxnQkFBTCxDQUNFO0FBQ0VrQyw2QkFBbUI7QUFDakJqSSxnQkFBSWYsT0FBT2UsRUFETTtBQUVqQmtJLG9CQUFRSixLQUZTO0FBR2pCTCx5QkFBYUE7QUFISTtBQURyQixTQURGLEVBUUUsWUFBTTtBQUNKLGNBQUlGLE9BQUosRUFBYTtBQUNYWSxxQkFBU0MsZ0JBQVQsQ0FBMEIsV0FBMUIsRUFBdUMsT0FBS0Msa0JBQTVDO0FBQ0FGLHFCQUFTQyxnQkFBVCxDQUEwQixhQUExQixFQUF5QyxPQUFLRSxlQUE5QztBQUNBSCxxQkFBU0MsZ0JBQVQsQ0FBMEIsVUFBMUIsRUFBc0MsT0FBS0UsZUFBM0M7QUFDRCxXQUpELE1BSU87QUFDTEgscUJBQVNDLGdCQUFULENBQTBCLFdBQTFCLEVBQXVDLE9BQUtDLGtCQUE1QztBQUNBRixxQkFBU0MsZ0JBQVQsQ0FBMEIsU0FBMUIsRUFBcUMsT0FBS0UsZUFBMUM7QUFDQUgscUJBQVNDLGdCQUFULENBQTBCLFlBQTFCLEVBQXdDLE9BQUtFLGVBQTdDO0FBQ0Q7QUFDRixTQWxCSDtBQW9CRDtBQXhvQlU7QUFBQTtBQUFBLHlDQTBvQlNoQixLQTFvQlQsRUEwb0JnQjtBQUN6QkEsY0FBTUUsZUFBTjtBQUR5QixZQUVqQmUsZUFGaUIsR0FFRyxLQUFLekssS0FGUixDQUVqQnlLLGVBRmlCOztBQUFBLGlDQUdjLEtBQUs3RCxnQkFBTCxFQUhkO0FBQUEsWUFHakI4RCxPQUhpQixzQkFHakJBLE9BSGlCO0FBQUEsWUFHUlAsaUJBSFEsc0JBR1JBLGlCQUhROztBQUt6Qjs7O0FBQ0EsWUFBTVEsYUFBYUQsUUFBUXBILE1BQVIsQ0FBZTtBQUFBLGlCQUFLMEQsRUFBRTlFLEVBQUYsS0FBU2lJLGtCQUFrQmpJLEVBQWhDO0FBQUEsU0FBZixDQUFuQjs7QUFFQSxZQUFJOEgsY0FBSjs7QUFFQSxZQUFJUixNQUFNb0IsSUFBTixLQUFlLFdBQW5CLEVBQWdDO0FBQzlCWixrQkFBUVIsTUFBTVMsY0FBTixDQUFxQixDQUFyQixFQUF3QkQsS0FBaEM7QUFDRCxTQUZELE1BRU8sSUFBSVIsTUFBTW9CLElBQU4sS0FBZSxXQUFuQixFQUFnQztBQUNyQ1osa0JBQVFSLE1BQU1RLEtBQWQ7QUFDRDs7QUFFRDtBQUNBLFlBQU1hLFdBQVd0QyxLQUFLdUMsR0FBTCxDQUNmWCxrQkFBa0JSLFdBQWxCLEdBQWdDSyxLQUFoQyxHQUF3Q0csa0JBQWtCQyxNQUQzQyxFQUVmLEVBRmUsQ0FBakI7O0FBS0FPLG1CQUFXOUgsSUFBWCxDQUFnQjtBQUNkWCxjQUFJaUksa0JBQWtCakksRUFEUjtBQUVkNkQsaUJBQU84RTtBQUZPLFNBQWhCOztBQUtBLGFBQUs1QyxnQkFBTCxDQUNFO0FBQ0V5QyxtQkFBU0M7QUFEWCxTQURGLEVBSUUsWUFBTTtBQUNKRiw2QkFBbUJBLGdCQUFnQkUsVUFBaEIsRUFBNEJuQixLQUE1QixDQUFuQjtBQUNELFNBTkg7QUFRRDtBQTdxQlU7QUFBQTtBQUFBLHNDQStxQk1BLEtBL3FCTixFQStxQmE7QUFDdEJBLGNBQU1FLGVBQU47QUFDQSxZQUFJRCxVQUFVRCxNQUFNb0IsSUFBTixLQUFlLFVBQWYsSUFBNkJwQixNQUFNb0IsSUFBTixLQUFlLGFBQTFEOztBQUVBLFlBQUluQixPQUFKLEVBQWE7QUFDWFksbUJBQVNVLG1CQUFULENBQTZCLFdBQTdCLEVBQTBDLEtBQUtSLGtCQUEvQztBQUNBRixtQkFBU1UsbUJBQVQsQ0FBNkIsYUFBN0IsRUFBNEMsS0FBS1AsZUFBakQ7QUFDQUgsbUJBQVNVLG1CQUFULENBQTZCLFVBQTdCLEVBQXlDLEtBQUtQLGVBQTlDO0FBQ0Q7O0FBRUQ7QUFDQTtBQUNBSCxpQkFBU1UsbUJBQVQsQ0FBNkIsV0FBN0IsRUFBMEMsS0FBS1Isa0JBQS9DO0FBQ0FGLGlCQUFTVSxtQkFBVCxDQUE2QixTQUE3QixFQUF3QyxLQUFLUCxlQUE3QztBQUNBSCxpQkFBU1UsbUJBQVQsQ0FBNkIsWUFBN0IsRUFBMkMsS0FBS1AsZUFBaEQ7O0FBRUE7QUFDQTtBQUNBO0FBQ0EsWUFBSSxDQUFDZixPQUFMLEVBQWM7QUFDWixlQUFLeEIsZ0JBQUwsQ0FBc0I7QUFDcEJTLDBCQUFjLElBRE07QUFFcEJ5QiwrQkFBbUI7QUFGQyxXQUF0QjtBQUlEO0FBQ0Y7QUF4c0JVOztBQUFBO0FBQUEsSUFDQ2EsSUFERDtBQUFBLEMiLCJmaWxlIjoibWV0aG9kcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBSZWFjdCBmcm9tICdyZWFjdCdcbmltcG9ydCBfIGZyb20gJy4vdXRpbHMnXG5cbmV4cG9ydCBkZWZhdWx0IEJhc2UgPT5cbiAgY2xhc3MgZXh0ZW5kcyBCYXNlIHtcbiAgICBnZXRSZXNvbHZlZFN0YXRlIChwcm9wcywgc3RhdGUpIHtcbiAgICAgIGNvbnN0IHJlc29sdmVkU3RhdGUgPSB7XG4gICAgICAgIC4uLl8uY29tcGFjdE9iamVjdCh0aGlzLnN0YXRlKSxcbiAgICAgICAgLi4uXy5jb21wYWN0T2JqZWN0KHRoaXMucHJvcHMpLFxuICAgICAgICAuLi5fLmNvbXBhY3RPYmplY3Qoc3RhdGUpLFxuICAgICAgICAuLi5fLmNvbXBhY3RPYmplY3QocHJvcHMpLFxuICAgICAgfVxuICAgICAgcmV0dXJuIHJlc29sdmVkU3RhdGVcbiAgICB9XG5cbiAgICBnZXREYXRhTW9kZWwgKG5ld1N0YXRlKSB7XG4gICAgICBjb25zdCB7XG4gICAgICAgIGNvbHVtbnMsXG4gICAgICAgIHBpdm90QnkgPSBbXSxcbiAgICAgICAgZGF0YSxcbiAgICAgICAgcGl2b3RJREtleSxcbiAgICAgICAgcGl2b3RWYWxLZXksXG4gICAgICAgIHN1YlJvd3NLZXksXG4gICAgICAgIGFnZ3JlZ2F0ZWRLZXksXG4gICAgICAgIG5lc3RpbmdMZXZlbEtleSxcbiAgICAgICAgb3JpZ2luYWxLZXksXG4gICAgICAgIGluZGV4S2V5LFxuICAgICAgICBncm91cGVkQnlQaXZvdEtleSxcbiAgICAgICAgU3ViQ29tcG9uZW50LFxuICAgICAgfSA9IG5ld1N0YXRlXG5cbiAgICAgIC8vIERldGVybWluZSBIZWFkZXIgR3JvdXBzXG4gICAgICBsZXQgaGFzSGVhZGVyR3JvdXBzID0gZmFsc2VcbiAgICAgIGNvbHVtbnMuZm9yRWFjaChjb2x1bW4gPT4ge1xuICAgICAgICBpZiAoY29sdW1uLmNvbHVtbnMpIHtcbiAgICAgICAgICBoYXNIZWFkZXJHcm91cHMgPSB0cnVlXG4gICAgICAgIH1cbiAgICAgIH0pXG5cbiAgICAgIGxldCBjb2x1bW5zV2l0aEV4cGFuZGVyID0gWy4uLmNvbHVtbnNdXG5cbiAgICAgIGxldCBleHBhbmRlckNvbHVtbiA9IGNvbHVtbnMuZmluZChcbiAgICAgICAgY29sID0+XG4gICAgICAgICAgY29sLmV4cGFuZGVyIHx8XG4gICAgICAgICAgKGNvbC5jb2x1bW5zICYmIGNvbC5jb2x1bW5zLnNvbWUoY29sMiA9PiBjb2wyLmV4cGFuZGVyKSlcbiAgICAgIClcbiAgICAgIC8vIFRoZSBhY3R1YWwgZXhwYW5kZXIgbWlnaHQgYmUgaW4gdGhlIGNvbHVtbnMgZmllbGQgb2YgYSBncm91cCBjb2x1bW5cbiAgICAgIGlmIChleHBhbmRlckNvbHVtbiAmJiAhZXhwYW5kZXJDb2x1bW4uZXhwYW5kZXIpIHtcbiAgICAgICAgZXhwYW5kZXJDb2x1bW4gPSBleHBhbmRlckNvbHVtbi5jb2x1bW5zLmZpbmQoY29sID0+IGNvbC5leHBhbmRlcilcbiAgICAgIH1cblxuICAgICAgLy8gSWYgd2UgaGF2ZSBTdWJDb21wb25lbnQncyB3ZSBuZWVkIHRvIG1ha2Ugc3VyZSB3ZSBoYXZlIGFuIGV4cGFuZGVyIGNvbHVtblxuICAgICAgaWYgKFN1YkNvbXBvbmVudCAmJiAhZXhwYW5kZXJDb2x1bW4pIHtcbiAgICAgICAgZXhwYW5kZXJDb2x1bW4gPSB7IGV4cGFuZGVyOiB0cnVlIH1cbiAgICAgICAgY29sdW1uc1dpdGhFeHBhbmRlciA9IFtleHBhbmRlckNvbHVtbiwgLi4uY29sdW1uc1dpdGhFeHBhbmRlcl1cbiAgICAgIH1cblxuICAgICAgY29uc3QgbWFrZURlY29yYXRlZENvbHVtbiA9IChjb2x1bW4sIHBhcmVudENvbHVtbikgPT4ge1xuICAgICAgICBsZXQgZGNvbFxuICAgICAgICBpZiAoY29sdW1uLmV4cGFuZGVyKSB7XG4gICAgICAgICAgZGNvbCA9IHtcbiAgICAgICAgICAgIC4uLnRoaXMucHJvcHMuY29sdW1uLFxuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5leHBhbmRlckRlZmF1bHRzLFxuICAgICAgICAgICAgLi4uY29sdW1uLFxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBkY29sID0ge1xuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5jb2x1bW4sXG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgfVxuICAgICAgICB9XG5cbiAgICAgICAgLy8gRW5zdXJlIG1pbldpZHRoIGlzIG5vdCBncmVhdGVyIHRoYW4gbWF4V2lkdGggaWYgc2V0XG4gICAgICAgIGlmIChkY29sLm1heFdpZHRoIDwgZGNvbC5taW5XaWR0aCkge1xuICAgICAgICAgIGRjb2wubWluV2lkdGggPSBkY29sLm1heFdpZHRoXG4gICAgICAgIH1cblxuICAgICAgICBpZiAocGFyZW50Q29sdW1uKSB7XG4gICAgICAgICAgZGNvbC5wYXJlbnRDb2x1bW4gPSBwYXJlbnRDb2x1bW5cbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZpcnN0IGNoZWNrIGZvciBzdHJpbmcgYWNjZXNzb3JcbiAgICAgICAgaWYgKHR5cGVvZiBkY29sLmFjY2Vzc29yID09PSAnc3RyaW5nJykge1xuICAgICAgICAgIGRjb2wuaWQgPSBkY29sLmlkIHx8IGRjb2wuYWNjZXNzb3JcbiAgICAgICAgICBjb25zdCBhY2Nlc3NvclN0cmluZyA9IGRjb2wuYWNjZXNzb3JcbiAgICAgICAgICBkY29sLmFjY2Vzc29yID0gcm93ID0+IF8uZ2V0KHJvdywgYWNjZXNzb3JTdHJpbmcpXG4gICAgICAgICAgcmV0dXJuIGRjb2xcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZhbGwgYmFjayB0byBmdW5jdGlvbmFsIGFjY2Vzc29yIChidXQgcmVxdWlyZSBhbiBJRClcbiAgICAgICAgaWYgKGRjb2wuYWNjZXNzb3IgJiYgIWRjb2wuaWQpIHtcbiAgICAgICAgICBjb25zb2xlLndhcm4oZGNvbClcbiAgICAgICAgICB0aHJvdyBuZXcgRXJyb3IoXG4gICAgICAgICAgICAnQSBjb2x1bW4gaWQgaXMgcmVxdWlyZWQgaWYgdXNpbmcgYSBub24tc3RyaW5nIGFjY2Vzc29yIGZvciBjb2x1bW4gYWJvdmUuJ1xuICAgICAgICAgIClcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZhbGwgYmFjayB0byBhbiB1bmRlZmluZWQgYWNjZXNzb3JcbiAgICAgICAgaWYgKCFkY29sLmFjY2Vzc29yKSB7XG4gICAgICAgICAgZGNvbC5hY2Nlc3NvciA9IGQgPT4gdW5kZWZpbmVkXG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gZGNvbFxuICAgICAgfVxuXG4gICAgICAvLyBEZWNvcmF0ZSB0aGUgY29sdW1uc1xuICAgICAgY29uc3QgZGVjb3JhdGVBbmRBZGRUb0FsbCA9IChjb2x1bW4sIHBhcmVudENvbHVtbikgPT4ge1xuICAgICAgICBjb25zdCBkZWNvcmF0ZWRDb2x1bW4gPSBtYWtlRGVjb3JhdGVkQ29sdW1uKGNvbHVtbiwgcGFyZW50Q29sdW1uKVxuICAgICAgICBhbGxEZWNvcmF0ZWRDb2x1bW5zLnB1c2goZGVjb3JhdGVkQ29sdW1uKVxuICAgICAgICByZXR1cm4gZGVjb3JhdGVkQ29sdW1uXG4gICAgICB9XG4gICAgICBjb25zdCBhbGxEZWNvcmF0ZWRDb2x1bW5zID0gW11cbiAgICAgIGNvbnN0IGRlY29yYXRlZENvbHVtbnMgPSBjb2x1bW5zV2l0aEV4cGFuZGVyLm1hcCgoY29sdW1uLCBpKSA9PiB7XG4gICAgICAgIGlmIChjb2x1bW4uY29sdW1ucykge1xuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgICBjb2x1bW5zOiBjb2x1bW4uY29sdW1ucy5tYXAoZCA9PiBkZWNvcmF0ZUFuZEFkZFRvQWxsKGQsIGNvbHVtbikpLFxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICByZXR1cm4gZGVjb3JhdGVBbmRBZGRUb0FsbChjb2x1bW4pXG4gICAgICAgIH1cbiAgICAgIH0pXG5cbiAgICAgIC8vIEJ1aWxkIHRoZSB2aXNpYmxlIGNvbHVtbnMsIGhlYWRlcnMgYW5kIGZsYXQgY29sdW1uIGxpc3RcbiAgICAgIGxldCB2aXNpYmxlQ29sdW1ucyA9IGRlY29yYXRlZENvbHVtbnMuc2xpY2UoKVxuICAgICAgbGV0IGFsbFZpc2libGVDb2x1bW5zID0gW11cblxuICAgICAgdmlzaWJsZUNvbHVtbnMgPSB2aXNpYmxlQ29sdW1ucy5tYXAoKGNvbHVtbiwgaSkgPT4ge1xuICAgICAgICBpZiAoY29sdW1uLmNvbHVtbnMpIHtcbiAgICAgICAgICBjb25zdCB2aXNpYmxlU3ViQ29sdW1ucyA9IGNvbHVtbi5jb2x1bW5zLmZpbHRlcihcbiAgICAgICAgICAgIGQgPT5cbiAgICAgICAgICAgICAgcGl2b3RCeS5pbmRleE9mKGQuaWQpID4gLTFcbiAgICAgICAgICAgICAgICA/IGZhbHNlXG4gICAgICAgICAgICAgICAgOiBfLmdldEZpcnN0RGVmaW5lZChkLnNob3csIHRydWUpXG4gICAgICAgICAgKVxuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgICBjb2x1bW5zOiB2aXNpYmxlU3ViQ29sdW1ucyxcbiAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGNvbHVtblxuICAgICAgfSlcblxuICAgICAgdmlzaWJsZUNvbHVtbnMgPSB2aXNpYmxlQ29sdW1ucy5maWx0ZXIoY29sdW1uID0+IHtcbiAgICAgICAgcmV0dXJuIGNvbHVtbi5jb2x1bW5zXG4gICAgICAgICAgPyBjb2x1bW4uY29sdW1ucy5sZW5ndGhcbiAgICAgICAgICA6IHBpdm90QnkuaW5kZXhPZihjb2x1bW4uaWQpID4gLTFcbiAgICAgICAgICAgID8gZmFsc2VcbiAgICAgICAgICAgIDogXy5nZXRGaXJzdERlZmluZWQoY29sdW1uLnNob3csIHRydWUpXG4gICAgICB9KVxuXG4gICAgICAvLyBGaW5kIGFueSBjdXN0b20gcGl2b3QgbG9jYXRpb25cbiAgICAgIGNvbnN0IHBpdm90SW5kZXggPSB2aXNpYmxlQ29sdW1ucy5maW5kSW5kZXgoY29sID0+IGNvbC5waXZvdClcblxuICAgICAgLy8gSGFuZGxlIFBpdm90IENvbHVtbnNcbiAgICAgIGlmIChwaXZvdEJ5Lmxlbmd0aCkge1xuICAgICAgICAvLyBSZXRyaWV2ZSB0aGUgcGl2b3QgY29sdW1ucyBpbiB0aGUgY29ycmVjdCBwaXZvdCBvcmRlclxuICAgICAgICBjb25zdCBwaXZvdENvbHVtbnMgPSBbXVxuICAgICAgICBwaXZvdEJ5LmZvckVhY2gocGl2b3RJRCA9PiB7XG4gICAgICAgICAgY29uc3QgZm91bmQgPSBhbGxEZWNvcmF0ZWRDb2x1bW5zLmZpbmQoZCA9PiBkLmlkID09PSBwaXZvdElEKVxuICAgICAgICAgIGlmIChmb3VuZCkge1xuICAgICAgICAgICAgcGl2b3RDb2x1bW5zLnB1c2goZm91bmQpXG4gICAgICAgICAgfVxuICAgICAgICB9KVxuXG4gICAgICAgIGxldCBQaXZvdFBhcmVudENvbHVtbiA9IHBpdm90Q29sdW1ucy5yZWR1Y2UoXG4gICAgICAgICAgKHByZXYsIGN1cnJlbnQpID0+XG4gICAgICAgICAgICBwcmV2ICYmIHByZXYgPT09IGN1cnJlbnQucGFyZW50Q29sdW1uICYmIGN1cnJlbnQucGFyZW50Q29sdW1uLFxuICAgICAgICAgIHBpdm90Q29sdW1uc1swXS5wYXJlbnRDb2x1bW5cbiAgICAgICAgKVxuXG4gICAgICAgIGxldCBQaXZvdEdyb3VwSGVhZGVyID0gaGFzSGVhZGVyR3JvdXBzICYmIFBpdm90UGFyZW50Q29sdW1uLkhlYWRlclxuICAgICAgICBQaXZvdEdyb3VwSGVhZGVyID0gUGl2b3RHcm91cEhlYWRlciB8fCAoKCkgPT4gPHN0cm9uZz5QaXZvdGVkPC9zdHJvbmc+KVxuXG4gICAgICAgIGxldCBwaXZvdENvbHVtbkdyb3VwID0ge1xuICAgICAgICAgIEhlYWRlcjogUGl2b3RHcm91cEhlYWRlcixcbiAgICAgICAgICBjb2x1bW5zOiBwaXZvdENvbHVtbnMubWFwKGNvbCA9PiAoe1xuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5waXZvdERlZmF1bHRzLFxuICAgICAgICAgICAgLi4uY29sLFxuICAgICAgICAgICAgcGl2b3RlZDogdHJ1ZSxcbiAgICAgICAgICB9KSksXG4gICAgICAgIH1cblxuICAgICAgICAvLyBQbGFjZSB0aGUgcGl2b3RDb2x1bW5zIGJhY2sgaW50byB0aGUgdmlzaWJsZUNvbHVtbnNcbiAgICAgICAgaWYgKHBpdm90SW5kZXggPj0gMCkge1xuICAgICAgICAgIHBpdm90Q29sdW1uR3JvdXAgPSB7XG4gICAgICAgICAgICAuLi52aXNpYmxlQ29sdW1uc1twaXZvdEluZGV4XSxcbiAgICAgICAgICAgIC4uLnBpdm90Q29sdW1uR3JvdXAsXG4gICAgICAgICAgfVxuICAgICAgICAgIHZpc2libGVDb2x1bW5zLnNwbGljZShwaXZvdEluZGV4LCAxLCBwaXZvdENvbHVtbkdyb3VwKVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgIHZpc2libGVDb2x1bW5zLnVuc2hpZnQocGl2b3RDb2x1bW5Hcm91cClcbiAgICAgICAgfVxuICAgICAgfVxuXG4gICAgICAvLyBCdWlsZCBIZWFkZXIgR3JvdXBzXG4gICAgICBjb25zdCBoZWFkZXJHcm91cHMgPSBbXVxuICAgICAgbGV0IGN1cnJlbnRTcGFuID0gW11cblxuICAgICAgLy8gQSBjb252ZW5pZW5jZSBmdW5jdGlvbiB0byBhZGQgYSBoZWFkZXIgYW5kIHJlc2V0IHRoZSBjdXJyZW50U3BhblxuICAgICAgY29uc3QgYWRkSGVhZGVyID0gKGNvbHVtbnMsIGNvbHVtbikgPT4ge1xuICAgICAgICBoZWFkZXJHcm91cHMucHVzaCh7XG4gICAgICAgICAgLi4udGhpcy5wcm9wcy5jb2x1bW4sXG4gICAgICAgICAgLi4uY29sdW1uLFxuICAgICAgICAgIGNvbHVtbnM6IGNvbHVtbnMsXG4gICAgICAgIH0pXG4gICAgICAgIGN1cnJlbnRTcGFuID0gW11cbiAgICAgIH1cblxuICAgICAgLy8gQnVpbGQgZmxhc3QgbGlzdCBvZiBhbGxWaXNpYmxlQ29sdW1ucyBhbmQgSGVhZGVyR3JvdXBzXG4gICAgICB2aXNpYmxlQ29sdW1ucy5mb3JFYWNoKChjb2x1bW4sIGkpID0+IHtcbiAgICAgICAgaWYgKGNvbHVtbi5jb2x1bW5zKSB7XG4gICAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMgPSBhbGxWaXNpYmxlQ29sdW1ucy5jb25jYXQoY29sdW1uLmNvbHVtbnMpXG4gICAgICAgICAgaWYgKGN1cnJlbnRTcGFuLmxlbmd0aCA+IDApIHtcbiAgICAgICAgICAgIGFkZEhlYWRlcihjdXJyZW50U3BhbilcbiAgICAgICAgICB9XG4gICAgICAgICAgYWRkSGVhZGVyKGNvbHVtbi5jb2x1bW5zLCBjb2x1bW4pXG4gICAgICAgICAgcmV0dXJuXG4gICAgICAgIH1cbiAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMucHVzaChjb2x1bW4pXG4gICAgICAgIGN1cnJlbnRTcGFuLnB1c2goY29sdW1uKVxuICAgICAgfSlcbiAgICAgIGlmIChoYXNIZWFkZXJHcm91cHMgJiYgY3VycmVudFNwYW4ubGVuZ3RoID4gMCkge1xuICAgICAgICBhZGRIZWFkZXIoY3VycmVudFNwYW4pXG4gICAgICB9XG5cbiAgICAgIC8vIEFjY2VzcyB0aGUgZGF0YVxuICAgICAgY29uc3QgYWNjZXNzUm93ID0gKGQsIGksIGxldmVsID0gMCkgPT4ge1xuICAgICAgICBjb25zdCByb3cgPSB7XG4gICAgICAgICAgW29yaWdpbmFsS2V5XTogZCxcbiAgICAgICAgICBbaW5kZXhLZXldOiBpLFxuICAgICAgICAgIFtzdWJSb3dzS2V5XTogZFtzdWJSb3dzS2V5XSxcbiAgICAgICAgICBbbmVzdGluZ0xldmVsS2V5XTogbGV2ZWwsXG4gICAgICAgIH1cbiAgICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucy5mb3JFYWNoKGNvbHVtbiA9PiB7XG4gICAgICAgICAgaWYgKGNvbHVtbi5leHBhbmRlcikgcmV0dXJuXG4gICAgICAgICAgcm93W2NvbHVtbi5pZF0gPSBjb2x1bW4uYWNjZXNzb3IoZClcbiAgICAgICAgfSlcbiAgICAgICAgaWYgKHJvd1tzdWJSb3dzS2V5XSkge1xuICAgICAgICAgIHJvd1tzdWJSb3dzS2V5XSA9IHJvd1tzdWJSb3dzS2V5XS5tYXAoKGQsIGkpID0+XG4gICAgICAgICAgICBhY2Nlc3NSb3coZCwgaSwgbGV2ZWwgKyAxKVxuICAgICAgICAgIClcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gcm93XG4gICAgICB9XG4gICAgICBsZXQgcmVzb2x2ZWREYXRhID0gZGF0YS5tYXAoKGQsIGkpID0+IGFjY2Vzc1JvdyhkLCBpKSlcblxuICAgICAgLy8gSWYgcGl2b3RpbmcsIHJlY3Vyc2l2ZWx5IGdyb3VwIHRoZSBkYXRhXG4gICAgICBjb25zdCBhZ2dyZWdhdGUgPSByb3dzID0+IHtcbiAgICAgICAgY29uc3QgYWdncmVnYXRpb25WYWx1ZXMgPSB7fVxuICAgICAgICBhZ2dyZWdhdGluZ0NvbHVtbnMuZm9yRWFjaChjb2x1bW4gPT4ge1xuICAgICAgICAgIGNvbnN0IHZhbHVlcyA9IHJvd3MubWFwKGQgPT4gZFtjb2x1bW4uaWRdKVxuICAgICAgICAgIGFnZ3JlZ2F0aW9uVmFsdWVzW2NvbHVtbi5pZF0gPSBjb2x1bW4uYWdncmVnYXRlKHZhbHVlcywgcm93cylcbiAgICAgICAgfSlcbiAgICAgICAgcmV0dXJuIGFnZ3JlZ2F0aW9uVmFsdWVzXG4gICAgICB9XG5cbiAgICAgIC8vIFRPRE86IE1ha2UgaXQgcG9zc2libGUgdG8gZmFicmljYXRlIG5lc3RlZCByb3dzIHdpdGhvdXQgcGl2b3RpbmdcbiAgICAgIGNvbnN0IGFnZ3JlZ2F0aW5nQ29sdW1ucyA9IGFsbFZpc2libGVDb2x1bW5zLmZpbHRlcihcbiAgICAgICAgZCA9PiAhZC5leHBhbmRlciAmJiBkLmFnZ3JlZ2F0ZVxuICAgICAgKVxuICAgICAgaWYgKHBpdm90QnkubGVuZ3RoKSB7XG4gICAgICAgIGNvbnN0IGdyb3VwUmVjdXJzaXZlbHkgPSAocm93cywga2V5cywgaSA9IDApID0+IHtcbiAgICAgICAgICAvLyBUaGlzIGlzIHRoZSBsYXN0IGxldmVsLCBqdXN0IHJldHVybiB0aGUgcm93c1xuICAgICAgICAgIGlmIChpID09PSBrZXlzLmxlbmd0aCkge1xuICAgICAgICAgICAgcmV0dXJuIHJvd3NcbiAgICAgICAgICB9XG4gICAgICAgICAgLy8gR3JvdXAgdGhlIHJvd3MgdG9nZXRoZXIgZm9yIHRoaXMgbGV2ZWxcbiAgICAgICAgICBsZXQgZ3JvdXBlZFJvd3MgPSBPYmplY3QuZW50cmllcyhcbiAgICAgICAgICAgIF8uZ3JvdXBCeShyb3dzLCBrZXlzW2ldKVxuICAgICAgICAgICkubWFwKChba2V5LCB2YWx1ZV0pID0+IHtcbiAgICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAgIFtwaXZvdElES2V5XToga2V5c1tpXSxcbiAgICAgICAgICAgICAgW3Bpdm90VmFsS2V5XToga2V5LFxuICAgICAgICAgICAgICBba2V5c1tpXV06IGtleSxcbiAgICAgICAgICAgICAgW3N1YlJvd3NLZXldOiB2YWx1ZSxcbiAgICAgICAgICAgICAgW25lc3RpbmdMZXZlbEtleV06IGksXG4gICAgICAgICAgICAgIFtncm91cGVkQnlQaXZvdEtleV06IHRydWUsXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcbiAgICAgICAgICAvLyBSZWN1cnNlIGludG8gdGhlIHN1YlJvd3NcbiAgICAgICAgICBncm91cGVkUm93cyA9IGdyb3VwZWRSb3dzLm1hcChyb3dHcm91cCA9PiB7XG4gICAgICAgICAgICBsZXQgc3ViUm93cyA9IGdyb3VwUmVjdXJzaXZlbHkocm93R3JvdXBbc3ViUm93c0tleV0sIGtleXMsIGkgKyAxKVxuICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgLi4ucm93R3JvdXAsXG4gICAgICAgICAgICAgIFtzdWJSb3dzS2V5XTogc3ViUm93cyxcbiAgICAgICAgICAgICAgW2FnZ3JlZ2F0ZWRLZXldOiB0cnVlLFxuICAgICAgICAgICAgICAuLi5hZ2dyZWdhdGUoc3ViUm93cyksXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcbiAgICAgICAgICByZXR1cm4gZ3JvdXBlZFJvd3NcbiAgICAgICAgfVxuICAgICAgICByZXNvbHZlZERhdGEgPSBncm91cFJlY3Vyc2l2ZWx5KHJlc29sdmVkRGF0YSwgcGl2b3RCeSlcbiAgICAgIH1cblxuICAgICAgcmV0dXJuIHtcbiAgICAgICAgLi4ubmV3U3RhdGUsXG4gICAgICAgIHJlc29sdmVkRGF0YSxcbiAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMsXG4gICAgICAgIGhlYWRlckdyb3VwcyxcbiAgICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucyxcbiAgICAgICAgaGFzSGVhZGVyR3JvdXBzLFxuICAgICAgfVxuICAgIH1cblxuICAgIGdldFNvcnRlZERhdGEgKHJlc29sdmVkU3RhdGUpIHtcbiAgICAgIGNvbnN0IHtcbiAgICAgICAgbWFudWFsLFxuICAgICAgICBzb3J0ZWQsXG4gICAgICAgIGZpbHRlcmVkLFxuICAgICAgICBkZWZhdWx0RmlsdGVyTWV0aG9kLFxuICAgICAgICByZXNvbHZlZERhdGEsXG4gICAgICAgIGFsbFZpc2libGVDb2x1bW5zLFxuICAgICAgICBhbGxEZWNvcmF0ZWRDb2x1bW5zLFxuICAgICAgfSA9IHJlc29sdmVkU3RhdGVcblxuICAgICAgY29uc3Qgc29ydE1ldGhvZHNCeUNvbHVtbklEID0ge31cblxuICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucy5maWx0ZXIoY29sID0+IGNvbC5zb3J0TWV0aG9kKS5mb3JFYWNoKGNvbCA9PiB7XG4gICAgICAgIHNvcnRNZXRob2RzQnlDb2x1bW5JRFtjb2wuaWRdID0gY29sLnNvcnRNZXRob2RcbiAgICAgIH0pXG5cbiAgICAgIC8vIFJlc29sdmUgdGhlIGRhdGEgZnJvbSBlaXRoZXIgbWFudWFsIGRhdGEgb3Igc29ydGVkIGRhdGFcbiAgICAgIHJldHVybiB7XG4gICAgICAgIHNvcnRlZERhdGE6IG1hbnVhbFxuICAgICAgICAgID8gcmVzb2x2ZWREYXRhXG4gICAgICAgICAgOiB0aGlzLnNvcnREYXRhKFxuICAgICAgICAgICAgdGhpcy5maWx0ZXJEYXRhKFxuICAgICAgICAgICAgICByZXNvbHZlZERhdGEsXG4gICAgICAgICAgICAgIGZpbHRlcmVkLFxuICAgICAgICAgICAgICBkZWZhdWx0RmlsdGVyTWV0aG9kLFxuICAgICAgICAgICAgICBhbGxWaXNpYmxlQ29sdW1uc1xuICAgICAgICAgICAgKSxcbiAgICAgICAgICAgIHNvcnRlZCxcbiAgICAgICAgICAgIHNvcnRNZXRob2RzQnlDb2x1bW5JRFxuICAgICAgICAgICksXG4gICAgICB9XG4gICAgfVxuXG4gICAgZmlyZUZldGNoRGF0YSAoKSB7XG4gICAgICB0aGlzLnByb3BzLm9uRmV0Y2hEYXRhKHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpLCB0aGlzKVxuICAgIH1cblxuICAgIGdldFByb3BPclN0YXRlIChrZXkpIHtcbiAgICAgIHJldHVybiBfLmdldEZpcnN0RGVmaW5lZCh0aGlzLnByb3BzW2tleV0sIHRoaXMuc3RhdGVba2V5XSlcbiAgICB9XG5cbiAgICBnZXRTdGF0ZU9yUHJvcCAoa2V5KSB7XG4gICAgICByZXR1cm4gXy5nZXRGaXJzdERlZmluZWQodGhpcy5zdGF0ZVtrZXldLCB0aGlzLnByb3BzW2tleV0pXG4gICAgfVxuXG4gICAgZmlsdGVyRGF0YSAoZGF0YSwgZmlsdGVyZWQsIGRlZmF1bHRGaWx0ZXJNZXRob2QsIGFsbFZpc2libGVDb2x1bW5zKSB7XG4gICAgICBsZXQgZmlsdGVyZWREYXRhID0gZGF0YVxuXG4gICAgICBpZiAoZmlsdGVyZWQubGVuZ3RoKSB7XG4gICAgICAgIGZpbHRlcmVkRGF0YSA9IGZpbHRlcmVkLnJlZHVjZSgoZmlsdGVyZWRTb0ZhciwgbmV4dEZpbHRlcikgPT4ge1xuICAgICAgICAgIGNvbnN0IGNvbHVtbiA9IGFsbFZpc2libGVDb2x1bW5zLmZpbmQoeCA9PiB4LmlkID09PSBuZXh0RmlsdGVyLmlkKVxuXG4gICAgICAgICAgLy8gRG9uJ3QgZmlsdGVyIGhpZGRlbiBjb2x1bW5zIG9yIGNvbHVtbnMgdGhhdCBoYXZlIGhhZCB0aGVpciBmaWx0ZXJzIGRpc2FibGVkXG4gICAgICAgICAgaWYgKCFjb2x1bW4gfHwgY29sdW1uLmZpbHRlcmFibGUgPT09IGZhbHNlKSB7XG4gICAgICAgICAgICByZXR1cm4gZmlsdGVyZWRTb0ZhclxuICAgICAgICAgIH1cblxuICAgICAgICAgIGNvbnN0IGZpbHRlck1ldGhvZCA9IGNvbHVtbi5maWx0ZXJNZXRob2QgfHwgZGVmYXVsdEZpbHRlck1ldGhvZFxuXG4gICAgICAgICAgLy8gSWYgJ2ZpbHRlckFsbCcgaXMgc2V0IHRvIHRydWUsIHBhc3MgdGhlIGVudGlyZSBkYXRhc2V0IHRvIHRoZSBmaWx0ZXIgbWV0aG9kXG4gICAgICAgICAgaWYgKGNvbHVtbi5maWx0ZXJBbGwpIHtcbiAgICAgICAgICAgIHJldHVybiBmaWx0ZXJNZXRob2QobmV4dEZpbHRlciwgZmlsdGVyZWRTb0ZhciwgY29sdW1uKVxuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICByZXR1cm4gZmlsdGVyZWRTb0Zhci5maWx0ZXIocm93ID0+IHtcbiAgICAgICAgICAgICAgcmV0dXJuIGZpbHRlck1ldGhvZChuZXh0RmlsdGVyLCByb3csIGNvbHVtbilcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICB9LCBmaWx0ZXJlZERhdGEpXG5cbiAgICAgICAgLy8gQXBwbHkgdGhlIGZpbHRlciB0byB0aGUgc3Vicm93cyBpZiB3ZSBhcmUgcGl2b3RpbmcsIGFuZCB0aGVuXG4gICAgICAgIC8vIGZpbHRlciBhbnkgcm93cyB3aXRob3V0IHN1YmNvbHVtbnMgYmVjYXVzZSBpdCB3b3VsZCBiZSBzdHJhbmdlIHRvIHNob3dcbiAgICAgICAgZmlsdGVyZWREYXRhID0gZmlsdGVyZWREYXRhXG4gICAgICAgICAgLm1hcChyb3cgPT4ge1xuICAgICAgICAgICAgaWYgKCFyb3dbdGhpcy5wcm9wcy5zdWJSb3dzS2V5XSkge1xuICAgICAgICAgICAgICByZXR1cm4gcm93XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICAuLi5yb3csXG4gICAgICAgICAgICAgIFt0aGlzLnByb3BzLnN1YlJvd3NLZXldOiB0aGlzLmZpbHRlckRhdGEoXG4gICAgICAgICAgICAgICAgcm93W3RoaXMucHJvcHMuc3ViUm93c0tleV0sXG4gICAgICAgICAgICAgICAgZmlsdGVyZWQsXG4gICAgICAgICAgICAgICAgZGVmYXVsdEZpbHRlck1ldGhvZCxcbiAgICAgICAgICAgICAgICBhbGxWaXNpYmxlQ29sdW1uc1xuICAgICAgICAgICAgICApLFxuICAgICAgICAgICAgfVxuICAgICAgICAgIH0pXG4gICAgICAgICAgLmZpbHRlcihyb3cgPT4ge1xuICAgICAgICAgICAgaWYgKCFyb3dbdGhpcy5wcm9wcy5zdWJSb3dzS2V5XSkge1xuICAgICAgICAgICAgICByZXR1cm4gdHJ1ZVxuICAgICAgICAgICAgfVxuICAgICAgICAgICAgcmV0dXJuIHJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldLmxlbmd0aCA+IDBcbiAgICAgICAgICB9KVxuICAgICAgfVxuXG4gICAgICByZXR1cm4gZmlsdGVyZWREYXRhXG4gICAgfVxuXG4gICAgc29ydERhdGEgKGRhdGEsIHNvcnRlZCwgc29ydE1ldGhvZHNCeUNvbHVtbklEID0ge30pIHtcbiAgICAgIGlmICghc29ydGVkLmxlbmd0aCkge1xuICAgICAgICByZXR1cm4gZGF0YVxuICAgICAgfVxuXG4gICAgICBjb25zdCBzb3J0ZWREYXRhID0gKHRoaXMucHJvcHMub3JkZXJCeU1ldGhvZCB8fCBfLm9yZGVyQnkpKFxuICAgICAgICBkYXRhLFxuICAgICAgICBzb3J0ZWQubWFwKHNvcnQgPT4ge1xuICAgICAgICAgIC8vIFN1cHBvcnQgY3VzdG9tIHNvcnRpbmcgbWV0aG9kcyBmb3IgZWFjaCBjb2x1bW5cbiAgICAgICAgICBpZiAoc29ydE1ldGhvZHNCeUNvbHVtbklEW3NvcnQuaWRdKSB7XG4gICAgICAgICAgICByZXR1cm4gKGEsIGIpID0+IHtcbiAgICAgICAgICAgICAgcmV0dXJuIHNvcnRNZXRob2RzQnlDb2x1bW5JRFtzb3J0LmlkXShhW3NvcnQuaWRdLCBiW3NvcnQuaWRdKVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH1cbiAgICAgICAgICByZXR1cm4gKGEsIGIpID0+IHtcbiAgICAgICAgICAgIHJldHVybiB0aGlzLnByb3BzLmRlZmF1bHRTb3J0TWV0aG9kKGFbc29ydC5pZF0sIGJbc29ydC5pZF0pXG4gICAgICAgICAgfVxuICAgICAgICB9KSxcbiAgICAgICAgc29ydGVkLm1hcChkID0+ICFkLmRlc2MpLFxuICAgICAgICB0aGlzLnByb3BzLmluZGV4S2V5XG4gICAgICApXG5cbiAgICAgIHNvcnRlZERhdGEuZm9yRWFjaChyb3cgPT4ge1xuICAgICAgICBpZiAoIXJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldKSB7XG4gICAgICAgICAgcmV0dXJuXG4gICAgICAgIH1cbiAgICAgICAgcm93W3RoaXMucHJvcHMuc3ViUm93c0tleV0gPSB0aGlzLnNvcnREYXRhKFxuICAgICAgICAgIHJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldLFxuICAgICAgICAgIHNvcnRlZCxcbiAgICAgICAgICBzb3J0TWV0aG9kc0J5Q29sdW1uSURcbiAgICAgICAgKVxuICAgICAgfSlcblxuICAgICAgcmV0dXJuIHNvcnRlZERhdGFcbiAgICB9XG5cbiAgICBnZXRNaW5Sb3dzICgpIHtcbiAgICAgIHJldHVybiBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgdGhpcy5wcm9wcy5taW5Sb3dzLFxuICAgICAgICB0aGlzLmdldFN0YXRlT3JQcm9wKCdwYWdlU2l6ZScpXG4gICAgICApXG4gICAgfVxuXG4gICAgLy8gVXNlciBhY3Rpb25zXG4gICAgb25QYWdlQ2hhbmdlIChwYWdlKSB7XG4gICAgICBjb25zdCB7IG9uUGFnZUNoYW5nZSwgY29sbGFwc2VPblBhZ2VDaGFuZ2UgfSA9IHRoaXMucHJvcHNcblxuICAgICAgY29uc3QgbmV3U3RhdGUgPSB7IHBhZ2UgfVxuICAgICAgaWYgKGNvbGxhcHNlT25QYWdlQ2hhbmdlKSB7XG4gICAgICAgIG5ld1N0YXRlLmV4cGFuZGVkID0ge31cbiAgICAgIH1cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShuZXdTdGF0ZSwgKCkgPT4ge1xuICAgICAgICBvblBhZ2VDaGFuZ2UgJiYgb25QYWdlQ2hhbmdlKHBhZ2UpXG4gICAgICB9KVxuICAgIH1cblxuICAgIG9uUGFnZVNpemVDaGFuZ2UgKG5ld1BhZ2VTaXplKSB7XG4gICAgICBjb25zdCB7IG9uUGFnZVNpemVDaGFuZ2UgfSA9IHRoaXMucHJvcHNcbiAgICAgIGNvbnN0IHsgcGFnZVNpemUsIHBhZ2UgfSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpXG5cbiAgICAgIC8vIE5vcm1hbGl6ZSB0aGUgcGFnZSB0byBkaXNwbGF5XG4gICAgICBjb25zdCBjdXJyZW50Um93ID0gcGFnZVNpemUgKiBwYWdlXG4gICAgICBjb25zdCBuZXdQYWdlID0gTWF0aC5mbG9vcihjdXJyZW50Um93IC8gbmV3UGFnZVNpemUpXG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHBhZ2VTaXplOiBuZXdQYWdlU2l6ZSxcbiAgICAgICAgICBwYWdlOiBuZXdQYWdlLFxuICAgICAgICB9LFxuICAgICAgICAoKSA9PiB7XG4gICAgICAgICAgb25QYWdlU2l6ZUNoYW5nZSAmJiBvblBhZ2VTaXplQ2hhbmdlKG5ld1BhZ2VTaXplLCBuZXdQYWdlKVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgc29ydENvbHVtbiAoY29sdW1uLCBhZGRpdGl2ZSkge1xuICAgICAgY29uc3QgeyBzb3J0ZWQsIHNraXBOZXh0U29ydCwgZGVmYXVsdFNvcnREZXNjIH0gPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuXG4gICAgICBjb25zdCBmaXJzdFNvcnREaXJlY3Rpb24gPSBjb2x1bW4uaGFzT3duUHJvcGVydHkoJ2RlZmF1bHRTb3J0RGVzYycpXG4gICAgICAgID8gY29sdW1uLmRlZmF1bHRTb3J0RGVzY1xuICAgICAgICA6IGRlZmF1bHRTb3J0RGVzY1xuICAgICAgY29uc3Qgc2Vjb25kU29ydERpcmVjdGlvbiA9ICFmaXJzdFNvcnREaXJlY3Rpb25cblxuICAgICAgLy8gd2UgY2FuJ3Qgc3RvcCBldmVudCBwcm9wYWdhdGlvbiBmcm9tIHRoZSBjb2x1bW4gcmVzaXplIG1vdmUgaGFuZGxlcnNcbiAgICAgIC8vIGF0dGFjaGVkIHRvIHRoZSBkb2N1bWVudCBiZWNhdXNlIG9mIHJlYWN0J3Mgc3ludGhldGljIGV2ZW50c1xuICAgICAgLy8gc28gd2UgaGF2ZSB0byBwcmV2ZW50IHRoZSBzb3J0IGZ1bmN0aW9uIGZyb20gYWN0dWFsbHkgc29ydGluZ1xuICAgICAgLy8gaWYgd2UgY2xpY2sgb24gdGhlIGNvbHVtbiByZXNpemUgZWxlbWVudCB3aXRoaW4gYSBoZWFkZXIuXG4gICAgICBpZiAoc2tpcE5leHRTb3J0KSB7XG4gICAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YSh7XG4gICAgICAgICAgc2tpcE5leHRTb3J0OiBmYWxzZSxcbiAgICAgICAgfSlcbiAgICAgICAgcmV0dXJuXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IHsgb25Tb3J0ZWRDaGFuZ2UgfSA9IHRoaXMucHJvcHNcblxuICAgICAgbGV0IG5ld1NvcnRlZCA9IF8uY2xvbmUoc29ydGVkIHx8IFtdKS5tYXAoZCA9PiB7XG4gICAgICAgIGQuZGVzYyA9IF8uaXNTb3J0aW5nRGVzYyhkKVxuICAgICAgICByZXR1cm4gZFxuICAgICAgfSlcbiAgICAgIGlmICghXy5pc0FycmF5KGNvbHVtbikpIHtcbiAgICAgICAgLy8gU2luZ2xlLVNvcnRcbiAgICAgICAgY29uc3QgZXhpc3RpbmdJbmRleCA9IG5ld1NvcnRlZC5maW5kSW5kZXgoZCA9PiBkLmlkID09PSBjb2x1bW4uaWQpXG4gICAgICAgIGlmIChleGlzdGluZ0luZGV4ID4gLTEpIHtcbiAgICAgICAgICBjb25zdCBleGlzdGluZyA9IG5ld1NvcnRlZFtleGlzdGluZ0luZGV4XVxuICAgICAgICAgIGlmIChleGlzdGluZy5kZXNjID09PSBzZWNvbmRTb3J0RGlyZWN0aW9uKSB7XG4gICAgICAgICAgICBpZiAoYWRkaXRpdmUpIHtcbiAgICAgICAgICAgICAgbmV3U29ydGVkLnNwbGljZShleGlzdGluZ0luZGV4LCAxKVxuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgZXhpc3RpbmcuZGVzYyA9IGZpcnN0U29ydERpcmVjdGlvblxuICAgICAgICAgICAgICBuZXdTb3J0ZWQgPSBbZXhpc3RpbmddXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGV4aXN0aW5nLmRlc2MgPSBzZWNvbmRTb3J0RGlyZWN0aW9uXG4gICAgICAgICAgICBpZiAoIWFkZGl0aXZlKSB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZCA9IFtleGlzdGluZ11cbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgaWYgKGFkZGl0aXZlKSB7XG4gICAgICAgICAgICBuZXdTb3J0ZWQucHVzaCh7XG4gICAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICAgIGRlc2M6IGZpcnN0U29ydERpcmVjdGlvbixcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IFtcbiAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICAgICAgZGVzYzogZmlyc3RTb3J0RGlyZWN0aW9uLFxuICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgXVxuICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgfSBlbHNlIHtcbiAgICAgICAgLy8gTXVsdGktU29ydFxuICAgICAgICBjb25zdCBleGlzdGluZ0luZGV4ID0gbmV3U29ydGVkLmZpbmRJbmRleChkID0+IGQuaWQgPT09IGNvbHVtblswXS5pZClcbiAgICAgICAgLy8gRXhpc3RpbmcgU29ydGVkIENvbHVtblxuICAgICAgICBpZiAoZXhpc3RpbmdJbmRleCA+IC0xKSB7XG4gICAgICAgICAgY29uc3QgZXhpc3RpbmcgPSBuZXdTb3J0ZWRbZXhpc3RpbmdJbmRleF1cbiAgICAgICAgICBpZiAoZXhpc3RpbmcuZGVzYyA9PT0gc2Vjb25kU29ydERpcmVjdGlvbikge1xuICAgICAgICAgICAgaWYgKGFkZGl0aXZlKSB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZC5zcGxpY2UoZXhpc3RpbmdJbmRleCwgY29sdW1uLmxlbmd0aClcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIGNvbHVtbi5mb3JFYWNoKChkLCBpKSA9PiB7XG4gICAgICAgICAgICAgICAgbmV3U29ydGVkW2V4aXN0aW5nSW5kZXggKyBpXS5kZXNjID0gZmlyc3RTb3J0RGlyZWN0aW9uXG4gICAgICAgICAgICAgIH0pXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGNvbHVtbi5mb3JFYWNoKChkLCBpKSA9PiB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZFtleGlzdGluZ0luZGV4ICsgaV0uZGVzYyA9IHNlY29uZFNvcnREaXJlY3Rpb25cbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICAgIGlmICghYWRkaXRpdmUpIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IG5ld1NvcnRlZC5zbGljZShleGlzdGluZ0luZGV4LCBjb2x1bW4ubGVuZ3RoKVxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAvLyBOZXcgU29ydCBDb2x1bW5cbiAgICAgICAgICBpZiAoYWRkaXRpdmUpIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IG5ld1NvcnRlZC5jb25jYXQoXG4gICAgICAgICAgICAgIGNvbHVtbi5tYXAoZCA9PiAoe1xuICAgICAgICAgICAgICAgIGlkOiBkLmlkLFxuICAgICAgICAgICAgICAgIGRlc2M6IGZpcnN0U29ydERpcmVjdGlvbixcbiAgICAgICAgICAgICAgfSkpXG4gICAgICAgICAgICApXG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IGNvbHVtbi5tYXAoZCA9PiAoe1xuICAgICAgICAgICAgICBpZDogZC5pZCxcbiAgICAgICAgICAgICAgZGVzYzogZmlyc3RTb3J0RGlyZWN0aW9uLFxuICAgICAgICAgICAgfSkpXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICB9XG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHBhZ2U6XG4gICAgICAgICAgICAoIXNvcnRlZC5sZW5ndGggJiYgbmV3U29ydGVkLmxlbmd0aCkgfHwgIWFkZGl0aXZlXG4gICAgICAgICAgICAgID8gMFxuICAgICAgICAgICAgICA6IHRoaXMuc3RhdGUucGFnZSxcbiAgICAgICAgICBzb3J0ZWQ6IG5ld1NvcnRlZCxcbiAgICAgICAgfSxcbiAgICAgICAgKCkgPT4ge1xuICAgICAgICAgIG9uU29ydGVkQ2hhbmdlICYmIG9uU29ydGVkQ2hhbmdlKG5ld1NvcnRlZCwgY29sdW1uLCBhZGRpdGl2ZSlcbiAgICAgICAgfVxuICAgICAgKVxuICAgIH1cblxuICAgIGZpbHRlckNvbHVtbiAoY29sdW1uLCB2YWx1ZSkge1xuICAgICAgY29uc3QgeyBmaWx0ZXJlZCB9ID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKClcbiAgICAgIGNvbnN0IHsgb25GaWx0ZXJlZENoYW5nZSB9ID0gdGhpcy5wcm9wc1xuXG4gICAgICAvLyBSZW1vdmUgb2xkIGZpbHRlciBmaXJzdCBpZiBpdCBleGlzdHNcbiAgICAgIGNvbnN0IG5ld0ZpbHRlcmluZyA9IChmaWx0ZXJlZCB8fCBbXSkuZmlsdGVyKHggPT4ge1xuICAgICAgICBpZiAoeC5pZCAhPT0gY29sdW1uLmlkKSB7XG4gICAgICAgICAgcmV0dXJuIHRydWVcbiAgICAgICAgfVxuICAgICAgfSlcblxuICAgICAgaWYgKHZhbHVlICE9PSAnJykge1xuICAgICAgICBuZXdGaWx0ZXJpbmcucHVzaCh7XG4gICAgICAgICAgaWQ6IGNvbHVtbi5pZCxcbiAgICAgICAgICB2YWx1ZTogdmFsdWUsXG4gICAgICAgIH0pXG4gICAgICB9XG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIGZpbHRlcmVkOiBuZXdGaWx0ZXJpbmcsXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBvbkZpbHRlcmVkQ2hhbmdlICYmIG9uRmlsdGVyZWRDaGFuZ2UobmV3RmlsdGVyaW5nLCBjb2x1bW4sIHZhbHVlKVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uU3RhcnQgKGV2ZW50LCBjb2x1bW4sIGlzVG91Y2gpIHtcbiAgICAgIGV2ZW50LnN0b3BQcm9wYWdhdGlvbigpXG4gICAgICBjb25zdCBwYXJlbnRXaWR0aCA9IGV2ZW50LnRhcmdldC5wYXJlbnRFbGVtZW50LmdldEJvdW5kaW5nQ2xpZW50UmVjdCgpXG4gICAgICAgIC53aWR0aFxuXG4gICAgICBsZXQgcGFnZVhcbiAgICAgIGlmIChpc1RvdWNoKSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQuY2hhbmdlZFRvdWNoZXNbMF0ucGFnZVhcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQucGFnZVhcbiAgICAgIH1cblxuICAgICAgdGhpcy50cmFwRXZlbnRzID0gdHJ1ZVxuICAgICAgdGhpcy5zZXRTdGF0ZVdpdGhEYXRhKFxuICAgICAgICB7XG4gICAgICAgICAgY3VycmVudGx5UmVzaXppbmc6IHtcbiAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICBzdGFydFg6IHBhZ2VYLFxuICAgICAgICAgICAgcGFyZW50V2lkdGg6IHBhcmVudFdpZHRoLFxuICAgICAgICAgIH0sXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBpZiAoaXNUb3VjaCkge1xuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcigndG91Y2htb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCd0b3VjaGNhbmNlbCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcigndG91Y2hlbmQnLCB0aGlzLnJlc2l6ZUNvbHVtbkVuZClcbiAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcignbW91c2Vtb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCdtb3VzZXVwJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCdtb3VzZWxlYXZlJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uTW92aW5nIChldmVudCkge1xuICAgICAgZXZlbnQuc3RvcFByb3BhZ2F0aW9uKClcbiAgICAgIGNvbnN0IHsgb25SZXNpemVkQ2hhbmdlIH0gPSB0aGlzLnByb3BzXG4gICAgICBjb25zdCB7IHJlc2l6ZWQsIGN1cnJlbnRseVJlc2l6aW5nIH0gPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuXG4gICAgICAvLyBEZWxldGUgb2xkIHZhbHVlXG4gICAgICBjb25zdCBuZXdSZXNpemVkID0gcmVzaXplZC5maWx0ZXIoeCA9PiB4LmlkICE9PSBjdXJyZW50bHlSZXNpemluZy5pZClcblxuICAgICAgbGV0IHBhZ2VYXG5cbiAgICAgIGlmIChldmVudC50eXBlID09PSAndG91Y2htb3ZlJykge1xuICAgICAgICBwYWdlWCA9IGV2ZW50LmNoYW5nZWRUb3VjaGVzWzBdLnBhZ2VYXG4gICAgICB9IGVsc2UgaWYgKGV2ZW50LnR5cGUgPT09ICdtb3VzZW1vdmUnKSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQucGFnZVhcbiAgICAgIH1cblxuICAgICAgLy8gU2V0IHRoZSBtaW4gc2l6ZSB0byAxMCB0byBhY2NvdW50IGZvciBtYXJnaW4gYW5kIGJvcmRlciBvciBlbHNlIHRoZSBncm91cCBoZWFkZXJzIGRvbid0IGxpbmUgdXAgY29ycmVjdGx5XG4gICAgICBjb25zdCBuZXdXaWR0aCA9IE1hdGgubWF4KFxuICAgICAgICBjdXJyZW50bHlSZXNpemluZy5wYXJlbnRXaWR0aCArIHBhZ2VYIC0gY3VycmVudGx5UmVzaXppbmcuc3RhcnRYLFxuICAgICAgICAxMVxuICAgICAgKVxuXG4gICAgICBuZXdSZXNpemVkLnB1c2goe1xuICAgICAgICBpZDogY3VycmVudGx5UmVzaXppbmcuaWQsXG4gICAgICAgIHZhbHVlOiBuZXdXaWR0aCxcbiAgICAgIH0pXG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHJlc2l6ZWQ6IG5ld1Jlc2l6ZWQsXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBvblJlc2l6ZWRDaGFuZ2UgJiYgb25SZXNpemVkQ2hhbmdlKG5ld1Jlc2l6ZWQsIGV2ZW50KVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uRW5kIChldmVudCkge1xuICAgICAgZXZlbnQuc3RvcFByb3BhZ2F0aW9uKClcbiAgICAgIGxldCBpc1RvdWNoID0gZXZlbnQudHlwZSA9PT0gJ3RvdWNoZW5kJyB8fCBldmVudC50eXBlID09PSAndG91Y2hjYW5jZWwnXG5cbiAgICAgIGlmIChpc1RvdWNoKSB7XG4gICAgICAgIGRvY3VtZW50LnJlbW92ZUV2ZW50TGlzdGVuZXIoJ3RvdWNobW92ZScsIHRoaXMucmVzaXplQ29sdW1uTW92aW5nKVxuICAgICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCd0b3VjaGNhbmNlbCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCd0b3VjaGVuZCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgfVxuXG4gICAgICAvLyBJZiBpdHMgYSB0b3VjaCBldmVudCBjbGVhciB0aGUgbW91c2Ugb25lJ3MgYXMgd2VsbCBiZWNhdXNlIHNvbWV0aW1lc1xuICAgICAgLy8gdGhlIG1vdXNlRG93biBldmVudCBnZXRzIGNhbGxlZCBhcyB3ZWxsLCBidXQgdGhlIG1vdXNlVXAgZXZlbnQgZG9lc24ndFxuICAgICAgZG9jdW1lbnQucmVtb3ZlRXZlbnRMaXN0ZW5lcignbW91c2Vtb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCdtb3VzZXVwJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCdtb3VzZWxlYXZlJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG5cbiAgICAgIC8vIFRoZSB0b3VjaCBldmVudHMgZG9uJ3QgcHJvcGFnYXRlIHVwIHRvIHRoZSBzb3J0aW5nJ3Mgb25Nb3VzZURvd24gZXZlbnQgc29cbiAgICAgIC8vIG5vIG5lZWQgdG8gcHJldmVudCBpdCBmcm9tIGhhcHBlbmluZyBvciBlbHNlIHRoZSBmaXJzdCBjbGljayBhZnRlciBhIHRvdWNoXG4gICAgICAvLyBldmVudCByZXNpemUgd2lsbCBub3Qgc29ydCB0aGUgY29sdW1uLlxuICAgICAgaWYgKCFpc1RvdWNoKSB7XG4gICAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YSh7XG4gICAgICAgICAgc2tpcE5leHRTb3J0OiB0cnVlLFxuICAgICAgICAgIGN1cnJlbnRseVJlc2l6aW5nOiBmYWxzZSxcbiAgICAgICAgfSlcbiAgICAgIH1cbiAgICB9XG4gIH1cbiJdfQ== /***/ }), -/* 107 */ +/* 361 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -15275,15429 +54534,25953 @@ module.exports = exports['default']; Object.defineProperty(exports, "__esModule", { value: true }); -exports.default = !!(typeof window !== 'undefined' && window.document && window.document.createElement); -module.exports = exports['default']; -/***/ }), -/* 108 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -exports.__esModule = true; -exports.nameShape = undefined; -exports.transitionTimeout = transitionTimeout; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function transitionTimeout(transitionType) { - var timeoutPropName = 'transition' + transitionType + 'Timeout'; - var enabledPropName = 'transition' + transitionType; - - return function (props) { - // If the transition is enabled - if (props[enabledPropName]) { - // If no timeout duration is provided - if (props[timeoutPropName] == null) { - return new Error(timeoutPropName + ' wasn\'t supplied to CSSTransitionGroup: ' + 'this can cause unreliable animations and won\'t be supported in ' + 'a future version of React. See ' + 'https://fb.me/react-animation-transition-group-timeout for more ' + 'information.'); - - // If the duration isn't a number - } else if (typeof props[timeoutPropName] !== 'number') { - return new Error(timeoutPropName + ' must be a number (in milliseconds)'); - } - } +var _classnames = __webpack_require__(41); - return null; - }; -} +var _classnames2 = _interopRequireDefault(_classnames); -var nameShape = exports.nameShape = _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.shape({ - enter: _propTypes2.default.string, - leave: _propTypes2.default.string, - active: _propTypes2.default.string -}), _propTypes2.default.shape({ - enter: _propTypes2.default.string, - enterActive: _propTypes2.default.string, - leave: _propTypes2.default.string, - leaveActive: _propTypes2.default.string, - appear: _propTypes2.default.string, - appearActive: _propTypes2.default.string -})]); +var _utils = __webpack_require__(95); -/***/ }), -/* 109 */, -/* 110 */, -/* 111 */, -/* 112 */, -/* 113 */ -/***/ (function(module, exports, __webpack_require__) { +var _utils2 = _interopRequireDefault(_utils); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var _pagination = __webpack_require__(362); +var _pagination2 = _interopRequireDefault(_pagination); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -var _assign = __webpack_require__(5); +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } +// -var emptyObject = __webpack_require__(39); -var _invariant = __webpack_require__(1); -if (process.env.NODE_ENV !== 'production') { - var warning = __webpack_require__(2); -} +var emptyObj = function emptyObj() { + return {}; +}; -var MIXINS_KEY = 'mixins'; +exports.default = { + // General + data: [], + loading: false, + showPagination: true, + showPaginationTop: false, + showPaginationBottom: true, + showPageSizeOptions: true, + pageSizeOptions: [5, 10, 20, 25, 50, 100], + defaultPageSize: 20, + showPageJump: true, + collapseOnSortingChange: true, + collapseOnPageChange: true, + collapseOnDataChange: true, + freezeWhenExpanded: false, + sortable: true, + resizable: true, + filterable: false, + defaultSortDesc: false, + defaultSorted: [], + defaultFiltered: [], + defaultResized: [], + defaultExpanded: {}, + defaultFilterMethod: function defaultFilterMethod(filter, row, column) { + var id = filter.pivotId || filter.id; + return row[id] !== undefined ? String(row[id]).startsWith(filter.value) : true; + }, + defaultSortMethod: function defaultSortMethod(a, b) { + // force null and undefined to the bottom + a = a === null || a === undefined ? '' : a; + b = b === null || b === undefined ? '' : b; + // force any string values to lowercase + a = typeof a === 'string' ? a.toLowerCase() : a; + b = typeof b === 'string' ? b.toLowerCase() : b; + // Return either 1 or -1 to indicate a sort priority + if (a > b) { + return 1; + } + if (a < b) { + return -1; + } + // returning 0, undefined or any falsey value will use subsequent sorts or the index as a tiebreaker + return 0; + }, -// Helper function to allow the creation of anonymous functions which do not -// have .name set to the name of the variable being assigned to. -function identity(fn) { - return fn; -} + // Controlled State Props + // page: undefined, + // pageSize: undefined, + // sorted: [], + // filtered: [], + // resized: [], + // expanded: {}, + + // Controlled State Callbacks + onPageChange: undefined, + onPageSizeChange: undefined, + onSortedChange: undefined, + onFilteredChange: undefined, + onResizedChange: undefined, + onExpandedChange: undefined, + + // Pivoting + pivotBy: undefined, + + // Key Constants + pivotValKey: '_pivotVal', + pivotIDKey: '_pivotID', + subRowsKey: '_subRows', + aggregatedKey: '_aggregated', + nestingLevelKey: '_nestingLevel', + originalKey: '_original', + indexKey: '_index', + groupedByPivotKey: '_groupedByPivot', + + // Server-side Callbacks + onFetchData: function onFetchData() { + return null; + }, -var ReactPropTypeLocationNames; -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' - }; -} else { - ReactPropTypeLocationNames = {}; -} + // Classes + className: '', + style: {}, + + // Component decorators + getProps: emptyObj, + getTableProps: emptyObj, + getTheadGroupProps: emptyObj, + getTheadGroupTrProps: emptyObj, + getTheadGroupThProps: emptyObj, + getTheadProps: emptyObj, + getTheadTrProps: emptyObj, + getTheadThProps: emptyObj, + getTheadFilterProps: emptyObj, + getTheadFilterTrProps: emptyObj, + getTheadFilterThProps: emptyObj, + getTbodyProps: emptyObj, + getTrGroupProps: emptyObj, + getTrProps: emptyObj, + getTdProps: emptyObj, + getTfootProps: emptyObj, + getTfootTrProps: emptyObj, + getTfootTdProps: emptyObj, + getPaginationProps: emptyObj, + getLoadingProps: emptyObj, + getNoDataProps: emptyObj, + getResizerProps: emptyObj, + + // Global Column Defaults + column: { + // Renderers + Cell: undefined, + Header: undefined, + Footer: undefined, + Aggregated: undefined, + Pivot: undefined, + PivotValue: undefined, + Expander: undefined, + Filter: undefined, + // All Columns + sortable: undefined, // use table default + resizable: undefined, // use table default + filterable: undefined, // use table default + show: true, + minWidth: 100, + // Cells only + className: '', + style: {}, + getProps: emptyObj, + // Pivot only + aggregate: undefined, + // Headers only + headerClassName: '', + headerStyle: {}, + getHeaderProps: emptyObj, + // Footers only + footerClassName: '', + footerStyle: {}, + getFooterProps: emptyObj, + filterMethod: undefined, + filterAll: false, + sortMethod: undefined + }, -function factory(ReactComponent, isValidElement, ReactNoopUpdateQueue) { - /** - * Policies that describe methods in `ReactClassInterface`. - */ + // Global Expander Column Defaults + expanderDefaults: { + sortable: false, + resizable: false, + filterable: false, + width: 35 + }, - var injectedMixins = []; + pivotDefaults: { + // extend the defaults for pivoted columns here + }, - /** - * Composite components are higher-level components that compose other composite - * or host components. - * - * To create a new type of `ReactClass`, pass a specification of - * your new class to `React.createClass`. The only requirement of your class - * specification is that you implement a `render` method. - * - * var MyComponent = React.createClass({ - * render: function() { - * return <div>Hello World</div>; - * } - * }); - * - * The class specification supports a specific protocol of methods that have - * special meaning (e.g. `render`). See `ReactClassInterface` for - * more the comprehensive protocol. Any other properties and methods in the - * class specification will be available on the prototype. - * - * @interface ReactClassInterface - * @internal - */ - var ReactClassInterface = { - /** - * An array of Mixin objects to include when defining your component. - * - * @type {array} - * @optional - */ - mixins: 'DEFINE_MANY', + // Text + previousText: 'Previous', + nextText: 'Next', + loadingText: 'Loading...', + noDataText: 'No rows found', + pageText: 'Page', + ofText: 'of', + rowsText: 'rows', + + // Components + TableComponent: _utils2.default.makeTemplateComponent('rt-table', 'Table'), + TheadComponent: _utils2.default.makeTemplateComponent('rt-thead', 'Thead'), + TbodyComponent: _utils2.default.makeTemplateComponent('rt-tbody', 'Tbody'), + TrGroupComponent: _utils2.default.makeTemplateComponent('rt-tr-group', 'TrGroup'), + TrComponent: _utils2.default.makeTemplateComponent('rt-tr', 'Tr'), + ThComponent: function ThComponent(_ref) { + var toggleSort = _ref.toggleSort, + className = _ref.className, + children = _ref.children, + rest = _objectWithoutProperties(_ref, ['toggleSort', 'className', 'children']); - /** - * An object containing properties and methods that should be defined on - * the component's constructor instead of its prototype (static methods). - * - * @type {object} - * @optional - */ - statics: 'DEFINE_MANY', + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)(className, 'rt-th'), + onClick: function onClick(e) { + toggleSort && toggleSort(e); + } + }, rest), + children + ); + }, + TdComponent: _utils2.default.makeTemplateComponent('rt-td', 'Td'), + TfootComponent: _utils2.default.makeTemplateComponent('rt-tfoot', 'Tfoot'), + FilterComponent: function FilterComponent(_ref2) { + var filter = _ref2.filter, + _onChange = _ref2.onChange; + return _react2.default.createElement('input', { + type: 'text', + style: { + width: '100%' + }, + value: filter ? filter.value : '', + onChange: function onChange(event) { + return _onChange(event.target.value); + } + }); + }, + ExpanderComponent: function ExpanderComponent(_ref3) { + var isExpanded = _ref3.isExpanded; + return _react2.default.createElement( + 'div', + { className: (0, _classnames2.default)('rt-expander', isExpanded && '-open') }, + '\u2022' + ); + }, + PivotValueComponent: function PivotValueComponent(_ref4) { + var subRows = _ref4.subRows, + value = _ref4.value; + return _react2.default.createElement( + 'span', + null, + value, + ' ', + subRows && '(' + subRows.length + ')' + ); + }, + AggregatedComponent: function AggregatedComponent(_ref5) { + var subRows = _ref5.subRows, + column = _ref5.column; - /** - * Definition of prop types for this component. - * - * @type {object} - * @optional - */ - propTypes: 'DEFINE_MANY', + var previewValues = subRows.filter(function (d) { + return typeof d[column.id] !== 'undefined'; + }).map(function (row, i) { + return _react2.default.createElement( + 'span', + { key: i }, + row[column.id], + i < subRows.length - 1 ? ', ' : '' + ); + }); + return _react2.default.createElement( + 'span', + null, + previewValues + ); + }, + PivotComponent: undefined, // this is a computed default generated using + // the ExpanderComponent and PivotValueComponent at run-time in methods.js + PaginationComponent: _pagination2.default, + PreviousComponent: undefined, + NextComponent: undefined, + LoadingComponent: function LoadingComponent(_ref6) { + var className = _ref6.className, + loading = _ref6.loading, + loadingText = _ref6.loadingText, + rest = _objectWithoutProperties(_ref6, ['className', 'loading', 'loadingText']); - /** - * Definition of context types for this component. - * - * @type {object} - * @optional - */ - contextTypes: 'DEFINE_MANY', + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)('-loading', { '-active': loading }, className) + }, rest), + _react2.default.createElement( + 'div', + { className: '-loading-inner' }, + loadingText + ) + ); + }, + NoDataComponent: _utils2.default.makeTemplateComponent('rt-noData', 'NoData'), + ResizerComponent: _utils2.default.makeTemplateComponent('rt-resizer', 'Resizer'), + PadRowComponent: function PadRowComponent() { + return _react2.default.createElement( + 'span', + null, + '\xA0' + ); + } +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9kZWZhdWx0UHJvcHMuanMiXSwibmFtZXMiOlsiZW1wdHlPYmoiLCJkYXRhIiwibG9hZGluZyIsInNob3dQYWdpbmF0aW9uIiwic2hvd1BhZ2luYXRpb25Ub3AiLCJzaG93UGFnaW5hdGlvbkJvdHRvbSIsInNob3dQYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZU9wdGlvbnMiLCJkZWZhdWx0UGFnZVNpemUiLCJzaG93UGFnZUp1bXAiLCJjb2xsYXBzZU9uU29ydGluZ0NoYW5nZSIsImNvbGxhcHNlT25QYWdlQ2hhbmdlIiwiY29sbGFwc2VPbkRhdGFDaGFuZ2UiLCJmcmVlemVXaGVuRXhwYW5kZWQiLCJzb3J0YWJsZSIsInJlc2l6YWJsZSIsImZpbHRlcmFibGUiLCJkZWZhdWx0U29ydERlc2MiLCJkZWZhdWx0U29ydGVkIiwiZGVmYXVsdEZpbHRlcmVkIiwiZGVmYXVsdFJlc2l6ZWQiLCJkZWZhdWx0RXhwYW5kZWQiLCJkZWZhdWx0RmlsdGVyTWV0aG9kIiwiZmlsdGVyIiwicm93IiwiY29sdW1uIiwiaWQiLCJwaXZvdElkIiwidW5kZWZpbmVkIiwiU3RyaW5nIiwic3RhcnRzV2l0aCIsInZhbHVlIiwiZGVmYXVsdFNvcnRNZXRob2QiLCJhIiwiYiIsInRvTG93ZXJDYXNlIiwib25QYWdlQ2hhbmdlIiwib25QYWdlU2l6ZUNoYW5nZSIsIm9uU29ydGVkQ2hhbmdlIiwib25GaWx0ZXJlZENoYW5nZSIsIm9uUmVzaXplZENoYW5nZSIsIm9uRXhwYW5kZWRDaGFuZ2UiLCJwaXZvdEJ5IiwicGl2b3RWYWxLZXkiLCJwaXZvdElES2V5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJuZXN0aW5nTGV2ZWxLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJvbkZldGNoRGF0YSIsImNsYXNzTmFtZSIsInN0eWxlIiwiZ2V0UHJvcHMiLCJnZXRUYWJsZVByb3BzIiwiZ2V0VGhlYWRHcm91cFByb3BzIiwiZ2V0VGhlYWRHcm91cFRyUHJvcHMiLCJnZXRUaGVhZEdyb3VwVGhQcm9wcyIsImdldFRoZWFkUHJvcHMiLCJnZXRUaGVhZFRyUHJvcHMiLCJnZXRUaGVhZFRoUHJvcHMiLCJnZXRUaGVhZEZpbHRlclByb3BzIiwiZ2V0VGhlYWRGaWx0ZXJUclByb3BzIiwiZ2V0VGhlYWRGaWx0ZXJUaFByb3BzIiwiZ2V0VGJvZHlQcm9wcyIsImdldFRyR3JvdXBQcm9wcyIsImdldFRyUHJvcHMiLCJnZXRUZFByb3BzIiwiZ2V0VGZvb3RQcm9wcyIsImdldFRmb290VHJQcm9wcyIsImdldFRmb290VGRQcm9wcyIsImdldFBhZ2luYXRpb25Qcm9wcyIsImdldExvYWRpbmdQcm9wcyIsImdldE5vRGF0YVByb3BzIiwiZ2V0UmVzaXplclByb3BzIiwiQ2VsbCIsIkhlYWRlciIsIkZvb3RlciIsIkFnZ3JlZ2F0ZWQiLCJQaXZvdCIsIlBpdm90VmFsdWUiLCJFeHBhbmRlciIsIkZpbHRlciIsInNob3ciLCJtaW5XaWR0aCIsImFnZ3JlZ2F0ZSIsImhlYWRlckNsYXNzTmFtZSIsImhlYWRlclN0eWxlIiwiZ2V0SGVhZGVyUHJvcHMiLCJmb290ZXJDbGFzc05hbWUiLCJmb290ZXJTdHlsZSIsImdldEZvb3RlclByb3BzIiwiZmlsdGVyTWV0aG9kIiwiZmlsdGVyQWxsIiwic29ydE1ldGhvZCIsImV4cGFuZGVyRGVmYXVsdHMiLCJ3aWR0aCIsInBpdm90RGVmYXVsdHMiLCJwcmV2aW91c1RleHQiLCJuZXh0VGV4dCIsImxvYWRpbmdUZXh0Iiwibm9EYXRhVGV4dCIsInBhZ2VUZXh0Iiwib2ZUZXh0Iiwicm93c1RleHQiLCJUYWJsZUNvbXBvbmVudCIsIm1ha2VUZW1wbGF0ZUNvbXBvbmVudCIsIlRoZWFkQ29tcG9uZW50IiwiVGJvZHlDb21wb25lbnQiLCJUckdyb3VwQ29tcG9uZW50IiwiVHJDb21wb25lbnQiLCJUaENvbXBvbmVudCIsInRvZ2dsZVNvcnQiLCJjaGlsZHJlbiIsInJlc3QiLCJlIiwiVGRDb21wb25lbnQiLCJUZm9vdENvbXBvbmVudCIsIkZpbHRlckNvbXBvbmVudCIsIm9uQ2hhbmdlIiwiZXZlbnQiLCJ0YXJnZXQiLCJFeHBhbmRlckNvbXBvbmVudCIsImlzRXhwYW5kZWQiLCJQaXZvdFZhbHVlQ29tcG9uZW50Iiwic3ViUm93cyIsImxlbmd0aCIsIkFnZ3JlZ2F0ZWRDb21wb25lbnQiLCJwcmV2aWV3VmFsdWVzIiwiZCIsIm1hcCIsImkiLCJQaXZvdENvbXBvbmVudCIsIlBhZ2luYXRpb25Db21wb25lbnQiLCJQcmV2aW91c0NvbXBvbmVudCIsIk5leHRDb21wb25lbnQiLCJMb2FkaW5nQ29tcG9uZW50IiwiTm9EYXRhQ29tcG9uZW50IiwiUmVzaXplckNvbXBvbmVudCIsIlBhZFJvd0NvbXBvbmVudCJdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7O0FBRUE7Ozs7QUFDQTs7Ozs7OztBQUZBOzs7QUFJQSxJQUFNQSxXQUFXLFNBQVhBLFFBQVc7QUFBQSxTQUFPLEVBQVA7QUFBQSxDQUFqQjs7a0JBRWU7QUFDYjtBQUNBQyxRQUFNLEVBRk87QUFHYkMsV0FBUyxLQUhJO0FBSWJDLGtCQUFnQixJQUpIO0FBS2JDLHFCQUFtQixLQUxOO0FBTWJDLHdCQUFzQixJQU5UO0FBT2JDLHVCQUFxQixJQVBSO0FBUWJDLG1CQUFpQixDQUFDLENBQUQsRUFBSSxFQUFKLEVBQVEsRUFBUixFQUFZLEVBQVosRUFBZ0IsRUFBaEIsRUFBb0IsR0FBcEIsQ0FSSjtBQVNiQyxtQkFBaUIsRUFUSjtBQVViQyxnQkFBYyxJQVZEO0FBV2JDLDJCQUF5QixJQVhaO0FBWWJDLHdCQUFzQixJQVpUO0FBYWJDLHdCQUFzQixJQWJUO0FBY2JDLHNCQUFvQixLQWRQO0FBZWJDLFlBQVUsSUFmRztBQWdCYkMsYUFBVyxJQWhCRTtBQWlCYkMsY0FBWSxLQWpCQztBQWtCYkMsbUJBQWlCLEtBbEJKO0FBbUJiQyxpQkFBZSxFQW5CRjtBQW9CYkMsbUJBQWlCLEVBcEJKO0FBcUJiQyxrQkFBZ0IsRUFyQkg7QUFzQmJDLG1CQUFpQixFQXRCSjtBQXVCYkMsdUJBQXFCLDZCQUFDQyxNQUFELEVBQVNDLEdBQVQsRUFBY0MsTUFBZCxFQUF5QjtBQUM1QyxRQUFNQyxLQUFLSCxPQUFPSSxPQUFQLElBQWtCSixPQUFPRyxFQUFwQztBQUNBLFdBQU9GLElBQUlFLEVBQUosTUFBWUUsU0FBWixHQUNIQyxPQUFPTCxJQUFJRSxFQUFKLENBQVAsRUFBZ0JJLFVBQWhCLENBQTJCUCxPQUFPUSxLQUFsQyxDQURHLEdBRUgsSUFGSjtBQUdELEdBNUJZO0FBNkJiQyxxQkFBbUIsMkJBQUNDLENBQUQsRUFBSUMsQ0FBSixFQUFVO0FBQzNCO0FBQ0FELFFBQUlBLE1BQU0sSUFBTixJQUFjQSxNQUFNTCxTQUFwQixHQUFnQyxFQUFoQyxHQUFxQ0ssQ0FBekM7QUFDQUMsUUFBSUEsTUFBTSxJQUFOLElBQWNBLE1BQU1OLFNBQXBCLEdBQWdDLEVBQWhDLEdBQXFDTSxDQUF6QztBQUNBO0FBQ0FELFFBQUksT0FBT0EsQ0FBUCxLQUFhLFFBQWIsR0FBd0JBLEVBQUVFLFdBQUYsRUFBeEIsR0FBMENGLENBQTlDO0FBQ0FDLFFBQUksT0FBT0EsQ0FBUCxLQUFhLFFBQWIsR0FBd0JBLEVBQUVDLFdBQUYsRUFBeEIsR0FBMENELENBQTlDO0FBQ0E7QUFDQSxRQUFJRCxJQUFJQyxDQUFSLEVBQVc7QUFDVCxhQUFPLENBQVA7QUFDRDtBQUNELFFBQUlELElBQUlDLENBQVIsRUFBVztBQUNULGFBQU8sQ0FBQyxDQUFSO0FBQ0Q7QUFDRDtBQUNBLFdBQU8sQ0FBUDtBQUNELEdBN0NZOztBQStDYjtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBRSxnQkFBY1IsU0F4REQ7QUF5RGJTLG9CQUFrQlQsU0F6REw7QUEwRGJVLGtCQUFnQlYsU0ExREg7QUEyRGJXLG9CQUFrQlgsU0EzREw7QUE0RGJZLG1CQUFpQlosU0E1REo7QUE2RGJhLG9CQUFrQmIsU0E3REw7O0FBK0RiO0FBQ0FjLFdBQVNkLFNBaEVJOztBQWtFYjtBQUNBZSxlQUFhLFdBbkVBO0FBb0ViQyxjQUFZLFVBcEVDO0FBcUViQyxjQUFZLFVBckVDO0FBc0ViQyxpQkFBZSxhQXRFRjtBQXVFYkMsbUJBQWlCLGVBdkVKO0FBd0ViQyxlQUFhLFdBeEVBO0FBeUViQyxZQUFVLFFBekVHO0FBMEViQyxxQkFBbUIsaUJBMUVOOztBQTRFYjtBQUNBQyxlQUFhO0FBQUEsV0FBTSxJQUFOO0FBQUEsR0E3RUE7O0FBK0ViO0FBQ0FDLGFBQVcsRUFoRkU7QUFpRmJDLFNBQU8sRUFqRk07O0FBbUZiO0FBQ0FDLFlBQVV0RCxRQXBGRztBQXFGYnVELGlCQUFldkQsUUFyRkY7QUFzRmJ3RCxzQkFBb0J4RCxRQXRGUDtBQXVGYnlELHdCQUFzQnpELFFBdkZUO0FBd0ZiMEQsd0JBQXNCMUQsUUF4RlQ7QUF5RmIyRCxpQkFBZTNELFFBekZGO0FBMEZiNEQsbUJBQWlCNUQsUUExRko7QUEyRmI2RCxtQkFBaUI3RCxRQTNGSjtBQTRGYjhELHVCQUFxQjlELFFBNUZSO0FBNkZiK0QseUJBQXVCL0QsUUE3RlY7QUE4RmJnRSx5QkFBdUJoRSxRQTlGVjtBQStGYmlFLGlCQUFlakUsUUEvRkY7QUFnR2JrRSxtQkFBaUJsRSxRQWhHSjtBQWlHYm1FLGNBQVluRSxRQWpHQztBQWtHYm9FLGNBQVlwRSxRQWxHQztBQW1HYnFFLGlCQUFlckUsUUFuR0Y7QUFvR2JzRSxtQkFBaUJ0RSxRQXBHSjtBQXFHYnVFLG1CQUFpQnZFLFFBckdKO0FBc0did0Usc0JBQW9CeEUsUUF0R1A7QUF1R2J5RSxtQkFBaUJ6RSxRQXZHSjtBQXdHYjBFLGtCQUFnQjFFLFFBeEdIO0FBeUdiMkUsbUJBQWlCM0UsUUF6R0o7O0FBMkdiO0FBQ0F5QixVQUFRO0FBQ047QUFDQW1ELFVBQU1oRCxTQUZBO0FBR05pRCxZQUFRakQsU0FIRjtBQUlOa0QsWUFBUWxELFNBSkY7QUFLTm1ELGdCQUFZbkQsU0FMTjtBQU1Ob0QsV0FBT3BELFNBTkQ7QUFPTnFELGdCQUFZckQsU0FQTjtBQVFOc0QsY0FBVXRELFNBUko7QUFTTnVELFlBQVF2RCxTQVRGO0FBVU47QUFDQWQsY0FBVWMsU0FYSixFQVdlO0FBQ3JCYixlQUFXYSxTQVpMLEVBWWdCO0FBQ3RCWixnQkFBWVksU0FiTixFQWFpQjtBQUN2QndELFVBQU0sSUFkQTtBQWVOQyxjQUFVLEdBZko7QUFnQk47QUFDQWpDLGVBQVcsRUFqQkw7QUFrQk5DLFdBQU8sRUFsQkQ7QUFtQk5DLGNBQVV0RCxRQW5CSjtBQW9CTjtBQUNBc0YsZUFBVzFELFNBckJMO0FBc0JOO0FBQ0EyRCxxQkFBaUIsRUF2Qlg7QUF3Qk5DLGlCQUFhLEVBeEJQO0FBeUJOQyxvQkFBZ0J6RixRQXpCVjtBQTBCTjtBQUNBMEYscUJBQWlCLEVBM0JYO0FBNEJOQyxpQkFBYSxFQTVCUDtBQTZCTkMsb0JBQWdCNUYsUUE3QlY7QUE4Qk42RixrQkFBY2pFLFNBOUJSO0FBK0JOa0UsZUFBVyxLQS9CTDtBQWdDTkMsZ0JBQVluRTtBQWhDTixHQTVHSzs7QUErSWI7QUFDQW9FLG9CQUFrQjtBQUNoQmxGLGNBQVUsS0FETTtBQUVoQkMsZUFBVyxLQUZLO0FBR2hCQyxnQkFBWSxLQUhJO0FBSWhCaUYsV0FBTztBQUpTLEdBaEpMOztBQXVKYkMsaUJBQWU7QUFDYjtBQURhLEdBdkpGOztBQTJKYjtBQUNBQyxnQkFBYyxVQTVKRDtBQTZKYkMsWUFBVSxNQTdKRztBQThKYkMsZUFBYSxZQTlKQTtBQStKYkMsY0FBWSxlQS9KQztBQWdLYkMsWUFBVSxNQWhLRztBQWlLYkMsVUFBUSxJQWpLSztBQWtLYkMsWUFBVSxNQWxLRzs7QUFvS2I7QUFDQUMsa0JBQWdCLGdCQUFFQyxxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXJLSDtBQXNLYkMsa0JBQWdCLGdCQUFFRCxxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXRLSDtBQXVLYkUsa0JBQWdCLGdCQUFFRixxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXZLSDtBQXdLYkcsb0JBQWtCLGdCQUFFSCxxQkFBRixDQUF3QixhQUF4QixFQUF1QyxTQUF2QyxDQXhLTDtBQXlLYkksZUFBYSxnQkFBRUoscUJBQUYsQ0FBd0IsT0FBeEIsRUFBaUMsSUFBakMsQ0F6S0E7QUEwS2JLLGVBQWEsMkJBQWtEO0FBQUEsUUFBL0NDLFVBQStDLFFBQS9DQSxVQUErQztBQUFBLFFBQW5DN0QsU0FBbUMsUUFBbkNBLFNBQW1DO0FBQUEsUUFBeEI4RCxRQUF3QixRQUF4QkEsUUFBd0I7QUFBQSxRQUFYQyxJQUFXOztBQUM3RCxXQUNFO0FBQUE7QUFBQTtBQUNFLG1CQUFXLDBCQUFXL0QsU0FBWCxFQUFzQixPQUF0QixDQURiO0FBRUUsaUJBQVMsb0JBQUs7QUFDWjZELHdCQUFjQSxXQUFXRyxDQUFYLENBQWQ7QUFDRDtBQUpILFNBS01ELElBTE47QUFPR0Q7QUFQSCxLQURGO0FBV0QsR0F0TFk7QUF1TGJHLGVBQWEsZ0JBQUVWLHFCQUFGLENBQXdCLE9BQXhCLEVBQWlDLElBQWpDLENBdkxBO0FBd0xiVyxrQkFBZ0IsZ0JBQUVYLHFCQUFGLENBQXdCLFVBQXhCLEVBQW9DLE9BQXBDLENBeExIO0FBeUxiWSxtQkFBaUI7QUFBQSxRQUFHaEcsTUFBSCxTQUFHQSxNQUFIO0FBQUEsUUFBV2lHLFNBQVgsU0FBV0EsUUFBWDtBQUFBLFdBQ2Y7QUFDRSxZQUFLLE1BRFA7QUFFRSxhQUFPO0FBQ0x2QixlQUFPO0FBREYsT0FGVDtBQUtFLGFBQU8xRSxTQUFTQSxPQUFPUSxLQUFoQixHQUF3QixFQUxqQztBQU1FLGdCQUFVO0FBQUEsZUFBU3lGLFVBQVNDLE1BQU1DLE1BQU4sQ0FBYTNGLEtBQXRCLENBQVQ7QUFBQTtBQU5aLE1BRGU7QUFBQSxHQXpMSjtBQWtNYjRGLHFCQUFtQjtBQUFBLFFBQUdDLFVBQUgsU0FBR0EsVUFBSDtBQUFBLFdBQ2pCO0FBQUE7QUFBQSxRQUFLLFdBQVcsMEJBQVcsYUFBWCxFQUEwQkEsY0FBYyxPQUF4QyxDQUFoQjtBQUFBO0FBQUEsS0FEaUI7QUFBQSxHQWxNTjtBQXNNYkMsdUJBQXFCO0FBQUEsUUFBR0MsT0FBSCxTQUFHQSxPQUFIO0FBQUEsUUFBWS9GLEtBQVosU0FBWUEsS0FBWjtBQUFBLFdBQ25CO0FBQUE7QUFBQTtBQUNHQSxXQURIO0FBQUE7QUFDVytGLHVCQUFlQSxRQUFRQyxNQUF2QjtBQURYLEtBRG1CO0FBQUEsR0F0TVI7QUEwTWJDLHVCQUFxQixvQ0FBeUI7QUFBQSxRQUF0QkYsT0FBc0IsU0FBdEJBLE9BQXNCO0FBQUEsUUFBYnJHLE1BQWEsU0FBYkEsTUFBYTs7QUFDNUMsUUFBTXdHLGdCQUFnQkgsUUFDbkJ2RyxNQURtQixDQUNaO0FBQUEsYUFBSyxPQUFPMkcsRUFBRXpHLE9BQU9DLEVBQVQsQ0FBUCxLQUF3QixXQUE3QjtBQUFBLEtBRFksRUFFbkJ5RyxHQUZtQixDQUVmLFVBQUMzRyxHQUFELEVBQU00RyxDQUFOO0FBQUEsYUFDSDtBQUFBO0FBQUEsVUFBTSxLQUFLQSxDQUFYO0FBQ0c1RyxZQUFJQyxPQUFPQyxFQUFYLENBREg7QUFFRzBHLFlBQUlOLFFBQVFDLE1BQVIsR0FBaUIsQ0FBckIsR0FBeUIsSUFBekIsR0FBZ0M7QUFGbkMsT0FERztBQUFBLEtBRmUsQ0FBdEI7QUFRQSxXQUNFO0FBQUE7QUFBQTtBQUNHRTtBQURILEtBREY7QUFLRCxHQXhOWTtBQXlOYkksa0JBQWdCekcsU0F6TkgsRUF5TmM7QUFDM0I7QUFDQTBHLDJDQTNOYTtBQTROYkMscUJBQW1CM0csU0E1Tk47QUE2TmI0RyxpQkFBZTVHLFNBN05GO0FBOE5iNkcsb0JBQWtCO0FBQUEsUUFBR3JGLFNBQUgsU0FBR0EsU0FBSDtBQUFBLFFBQWNsRCxPQUFkLFNBQWNBLE9BQWQ7QUFBQSxRQUF1Qm1HLFdBQXZCLFNBQXVCQSxXQUF2QjtBQUFBLFFBQXVDYyxJQUF2Qzs7QUFBQSxXQUNoQjtBQUFBO0FBQUE7QUFDRSxtQkFBVywwQkFBVyxVQUFYLEVBQXVCLEVBQUUsV0FBV2pILE9BQWIsRUFBdkIsRUFBK0NrRCxTQUEvQztBQURiLFNBRU0rRCxJQUZOO0FBSUU7QUFBQTtBQUFBLFVBQUssV0FBVSxnQkFBZjtBQUNHZDtBQURIO0FBSkYsS0FEZ0I7QUFBQSxHQTlOTDtBQXVPYnFDLG1CQUFpQixnQkFBRS9CLHFCQUFGLENBQXdCLFdBQXhCLEVBQXFDLFFBQXJDLENBdk9KO0FBd09iZ0Msb0JBQWtCLGdCQUFFaEMscUJBQUYsQ0FBd0IsWUFBeEIsRUFBc0MsU0FBdEMsQ0F4T0w7QUF5T2JpQyxtQkFBaUI7QUFBQSxXQUFNO0FBQUE7QUFBQTtBQUFBO0FBQUEsS0FBTjtBQUFBO0FBek9KLEMiLCJmaWxlIjoiZGVmYXVsdFByb3BzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IFJlYWN0IGZyb20gJ3JlYWN0J1xuaW1wb3J0IGNsYXNzbmFtZXMgZnJvbSAnY2xhc3NuYW1lcydcbi8vXG5pbXBvcnQgXyBmcm9tICcuL3V0aWxzJ1xuaW1wb3J0IFBhZ2luYXRpb24gZnJvbSAnLi9wYWdpbmF0aW9uJ1xuXG5jb25zdCBlbXB0eU9iaiA9ICgpID0+ICh7fSlcblxuZXhwb3J0IGRlZmF1bHQge1xuICAvLyBHZW5lcmFsXG4gIGRhdGE6IFtdLFxuICBsb2FkaW5nOiBmYWxzZSxcbiAgc2hvd1BhZ2luYXRpb246IHRydWUsXG4gIHNob3dQYWdpbmF0aW9uVG9wOiBmYWxzZSxcbiAgc2hvd1BhZ2luYXRpb25Cb3R0b206IHRydWUsXG4gIHNob3dQYWdlU2l6ZU9wdGlvbnM6IHRydWUsXG4gIHBhZ2VTaXplT3B0aW9uczogWzUsIDEwLCAyMCwgMjUsIDUwLCAxMDBdLFxuICBkZWZhdWx0UGFnZVNpemU6IDIwLFxuICBzaG93UGFnZUp1bXA6IHRydWUsXG4gIGNvbGxhcHNlT25Tb3J0aW5nQ2hhbmdlOiB0cnVlLFxuICBjb2xsYXBzZU9uUGFnZUNoYW5nZTogdHJ1ZSxcbiAgY29sbGFwc2VPbkRhdGFDaGFuZ2U6IHRydWUsXG4gIGZyZWV6ZVdoZW5FeHBhbmRlZDogZmFsc2UsXG4gIHNvcnRhYmxlOiB0cnVlLFxuICByZXNpemFibGU6IHRydWUsXG4gIGZpbHRlcmFibGU6IGZhbHNlLFxuICBkZWZhdWx0U29ydERlc2M6IGZhbHNlLFxuICBkZWZhdWx0U29ydGVkOiBbXSxcbiAgZGVmYXVsdEZpbHRlcmVkOiBbXSxcbiAgZGVmYXVsdFJlc2l6ZWQ6IFtdLFxuICBkZWZhdWx0RXhwYW5kZWQ6IHt9LFxuICBkZWZhdWx0RmlsdGVyTWV0aG9kOiAoZmlsdGVyLCByb3csIGNvbHVtbikgPT4ge1xuICAgIGNvbnN0IGlkID0gZmlsdGVyLnBpdm90SWQgfHwgZmlsdGVyLmlkXG4gICAgcmV0dXJuIHJvd1tpZF0gIT09IHVuZGVmaW5lZFxuICAgICAgPyBTdHJpbmcocm93W2lkXSkuc3RhcnRzV2l0aChmaWx0ZXIudmFsdWUpXG4gICAgICA6IHRydWVcbiAgfSxcbiAgZGVmYXVsdFNvcnRNZXRob2Q6IChhLCBiKSA9PiB7XG4gICAgLy8gZm9yY2UgbnVsbCBhbmQgdW5kZWZpbmVkIHRvIHRoZSBib3R0b21cbiAgICBhID0gYSA9PT0gbnVsbCB8fCBhID09PSB1bmRlZmluZWQgPyAnJyA6IGFcbiAgICBiID0gYiA9PT0gbnVsbCB8fCBiID09PSB1bmRlZmluZWQgPyAnJyA6IGJcbiAgICAvLyBmb3JjZSBhbnkgc3RyaW5nIHZhbHVlcyB0byBsb3dlcmNhc2VcbiAgICBhID0gdHlwZW9mIGEgPT09ICdzdHJpbmcnID8gYS50b0xvd2VyQ2FzZSgpIDogYVxuICAgIGIgPSB0eXBlb2YgYiA9PT0gJ3N0cmluZycgPyBiLnRvTG93ZXJDYXNlKCkgOiBiXG4gICAgLy8gUmV0dXJuIGVpdGhlciAxIG9yIC0xIHRvIGluZGljYXRlIGEgc29ydCBwcmlvcml0eVxuICAgIGlmIChhID4gYikge1xuICAgICAgcmV0dXJuIDFcbiAgICB9XG4gICAgaWYgKGEgPCBiKSB7XG4gICAgICByZXR1cm4gLTFcbiAgICB9XG4gICAgLy8gcmV0dXJuaW5nIDAsIHVuZGVmaW5lZCBvciBhbnkgZmFsc2V5IHZhbHVlIHdpbGwgdXNlIHN1YnNlcXVlbnQgc29ydHMgb3IgdGhlIGluZGV4IGFzIGEgdGllYnJlYWtlclxuICAgIHJldHVybiAwXG4gIH0sXG5cbiAgLy8gQ29udHJvbGxlZCBTdGF0ZSBQcm9wc1xuICAvLyBwYWdlOiB1bmRlZmluZWQsXG4gIC8vIHBhZ2VTaXplOiB1bmRlZmluZWQsXG4gIC8vIHNvcnRlZDogW10sXG4gIC8vIGZpbHRlcmVkOiBbXSxcbiAgLy8gcmVzaXplZDogW10sXG4gIC8vIGV4cGFuZGVkOiB7fSxcblxuICAvLyBDb250cm9sbGVkIFN0YXRlIENhbGxiYWNrc1xuICBvblBhZ2VDaGFuZ2U6IHVuZGVmaW5lZCxcbiAgb25QYWdlU2l6ZUNoYW5nZTogdW5kZWZpbmVkLFxuICBvblNvcnRlZENoYW5nZTogdW5kZWZpbmVkLFxuICBvbkZpbHRlcmVkQ2hhbmdlOiB1bmRlZmluZWQsXG4gIG9uUmVzaXplZENoYW5nZTogdW5kZWZpbmVkLFxuICBvbkV4cGFuZGVkQ2hhbmdlOiB1bmRlZmluZWQsXG5cbiAgLy8gUGl2b3RpbmdcbiAgcGl2b3RCeTogdW5kZWZpbmVkLFxuXG4gIC8vIEtleSBDb25zdGFudHNcbiAgcGl2b3RWYWxLZXk6ICdfcGl2b3RWYWwnLFxuICBwaXZvdElES2V5OiAnX3Bpdm90SUQnLFxuICBzdWJSb3dzS2V5OiAnX3N1YlJvd3MnLFxuICBhZ2dyZWdhdGVkS2V5OiAnX2FnZ3JlZ2F0ZWQnLFxuICBuZXN0aW5nTGV2ZWxLZXk6ICdfbmVzdGluZ0xldmVsJyxcbiAgb3JpZ2luYWxLZXk6ICdfb3JpZ2luYWwnLFxuICBpbmRleEtleTogJ19pbmRleCcsXG4gIGdyb3VwZWRCeVBpdm90S2V5OiAnX2dyb3VwZWRCeVBpdm90JyxcblxuICAvLyBTZXJ2ZXItc2lkZSBDYWxsYmFja3NcbiAgb25GZXRjaERhdGE6ICgpID0+IG51bGwsXG5cbiAgLy8gQ2xhc3Nlc1xuICBjbGFzc05hbWU6ICcnLFxuICBzdHlsZToge30sXG5cbiAgLy8gQ29tcG9uZW50IGRlY29yYXRvcnNcbiAgZ2V0UHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUYWJsZVByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRHcm91cFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRHcm91cFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZEdyb3VwVGhQcm9wczogZW1wdHlPYmosXG4gIGdldFRoZWFkUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZFRoUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZEZpbHRlclByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRGaWx0ZXJUclByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRGaWx0ZXJUaFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGJvZHlQcm9wczogZW1wdHlPYmosXG4gIGdldFRyR3JvdXBQcm9wczogZW1wdHlPYmosXG4gIGdldFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUZFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGZvb3RQcm9wczogZW1wdHlPYmosXG4gIGdldFRmb290VHJQcm9wczogZW1wdHlPYmosXG4gIGdldFRmb290VGRQcm9wczogZW1wdHlPYmosXG4gIGdldFBhZ2luYXRpb25Qcm9wczogZW1wdHlPYmosXG4gIGdldExvYWRpbmdQcm9wczogZW1wdHlPYmosXG4gIGdldE5vRGF0YVByb3BzOiBlbXB0eU9iaixcbiAgZ2V0UmVzaXplclByb3BzOiBlbXB0eU9iaixcblxuICAvLyBHbG9iYWwgQ29sdW1uIERlZmF1bHRzXG4gIGNvbHVtbjoge1xuICAgIC8vIFJlbmRlcmVyc1xuICAgIENlbGw6IHVuZGVmaW5lZCxcbiAgICBIZWFkZXI6IHVuZGVmaW5lZCxcbiAgICBGb290ZXI6IHVuZGVmaW5lZCxcbiAgICBBZ2dyZWdhdGVkOiB1bmRlZmluZWQsXG4gICAgUGl2b3Q6IHVuZGVmaW5lZCxcbiAgICBQaXZvdFZhbHVlOiB1bmRlZmluZWQsXG4gICAgRXhwYW5kZXI6IHVuZGVmaW5lZCxcbiAgICBGaWx0ZXI6IHVuZGVmaW5lZCxcbiAgICAvLyBBbGwgQ29sdW1uc1xuICAgIHNvcnRhYmxlOiB1bmRlZmluZWQsIC8vIHVzZSB0YWJsZSBkZWZhdWx0XG4gICAgcmVzaXphYmxlOiB1bmRlZmluZWQsIC8vIHVzZSB0YWJsZSBkZWZhdWx0XG4gICAgZmlsdGVyYWJsZTogdW5kZWZpbmVkLCAvLyB1c2UgdGFibGUgZGVmYXVsdFxuICAgIHNob3c6IHRydWUsXG4gICAgbWluV2lkdGg6IDEwMCxcbiAgICAvLyBDZWxscyBvbmx5XG4gICAgY2xhc3NOYW1lOiAnJyxcbiAgICBzdHlsZToge30sXG4gICAgZ2V0UHJvcHM6IGVtcHR5T2JqLFxuICAgIC8vIFBpdm90IG9ubHlcbiAgICBhZ2dyZWdhdGU6IHVuZGVmaW5lZCxcbiAgICAvLyBIZWFkZXJzIG9ubHlcbiAgICBoZWFkZXJDbGFzc05hbWU6ICcnLFxuICAgIGhlYWRlclN0eWxlOiB7fSxcbiAgICBnZXRIZWFkZXJQcm9wczogZW1wdHlPYmosXG4gICAgLy8gRm9vdGVycyBvbmx5XG4gICAgZm9vdGVyQ2xhc3NOYW1lOiAnJyxcbiAgICBmb290ZXJTdHlsZToge30sXG4gICAgZ2V0Rm9vdGVyUHJvcHM6IGVtcHR5T2JqLFxuICAgIGZpbHRlck1ldGhvZDogdW5kZWZpbmVkLFxuICAgIGZpbHRlckFsbDogZmFsc2UsXG4gICAgc29ydE1ldGhvZDogdW5kZWZpbmVkLFxuICB9LFxuXG4gIC8vIEdsb2JhbCBFeHBhbmRlciBDb2x1bW4gRGVmYXVsdHNcbiAgZXhwYW5kZXJEZWZhdWx0czoge1xuICAgIHNvcnRhYmxlOiBmYWxzZSxcbiAgICByZXNpemFibGU6IGZhbHNlLFxuICAgIGZpbHRlcmFibGU6IGZhbHNlLFxuICAgIHdpZHRoOiAzNSxcbiAgfSxcblxuICBwaXZvdERlZmF1bHRzOiB7XG4gICAgLy8gZXh0ZW5kIHRoZSBkZWZhdWx0cyBmb3IgcGl2b3RlZCBjb2x1bW5zIGhlcmVcbiAgfSxcblxuICAvLyBUZXh0XG4gIHByZXZpb3VzVGV4dDogJ1ByZXZpb3VzJyxcbiAgbmV4dFRleHQ6ICdOZXh0JyxcbiAgbG9hZGluZ1RleHQ6ICdMb2FkaW5nLi4uJyxcbiAgbm9EYXRhVGV4dDogJ05vIHJvd3MgZm91bmQnLFxuICBwYWdlVGV4dDogJ1BhZ2UnLFxuICBvZlRleHQ6ICdvZicsXG4gIHJvd3NUZXh0OiAncm93cycsXG5cbiAgLy8gQ29tcG9uZW50c1xuICBUYWJsZUNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXRhYmxlJywgJ1RhYmxlJyksXG4gIFRoZWFkQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdGhlYWQnLCAnVGhlYWQnKSxcbiAgVGJvZHlDb21wb25lbnQ6IF8ubWFrZVRlbXBsYXRlQ29tcG9uZW50KCdydC10Ym9keScsICdUYm9keScpLFxuICBUckdyb3VwQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdHItZ3JvdXAnLCAnVHJHcm91cCcpLFxuICBUckNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXRyJywgJ1RyJyksXG4gIFRoQ29tcG9uZW50OiAoeyB0b2dnbGVTb3J0LCBjbGFzc05hbWUsIGNoaWxkcmVuLCAuLi5yZXN0IH0pID0+IHtcbiAgICByZXR1cm4gKFxuICAgICAgPGRpdlxuICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NOYW1lLCAncnQtdGgnKX1cbiAgICAgICAgb25DbGljaz17ZSA9PiB7XG4gICAgICAgICAgdG9nZ2xlU29ydCAmJiB0b2dnbGVTb3J0KGUpXG4gICAgICAgIH19XG4gICAgICAgIHsuLi5yZXN0fVxuICAgICAgPlxuICAgICAgICB7Y2hpbGRyZW59XG4gICAgICA8L2Rpdj5cbiAgICApXG4gIH0sXG4gIFRkQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdGQnLCAnVGQnKSxcbiAgVGZvb3RDb21wb25lbnQ6IF8ubWFrZVRlbXBsYXRlQ29tcG9uZW50KCdydC10Zm9vdCcsICdUZm9vdCcpLFxuICBGaWx0ZXJDb21wb25lbnQ6ICh7IGZpbHRlciwgb25DaGFuZ2UgfSkgPT5cbiAgICA8aW5wdXRcbiAgICAgIHR5cGU9J3RleHQnXG4gICAgICBzdHlsZT17e1xuICAgICAgICB3aWR0aDogJzEwMCUnLFxuICAgICAgfX1cbiAgICAgIHZhbHVlPXtmaWx0ZXIgPyBmaWx0ZXIudmFsdWUgOiAnJ31cbiAgICAgIG9uQ2hhbmdlPXtldmVudCA9PiBvbkNoYW5nZShldmVudC50YXJnZXQudmFsdWUpfVxuICAgIC8+LFxuICBFeHBhbmRlckNvbXBvbmVudDogKHsgaXNFeHBhbmRlZCB9KSA9PlxuICAgIDxkaXYgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCdydC1leHBhbmRlcicsIGlzRXhwYW5kZWQgJiYgJy1vcGVuJyl9PlxuICAgICAgJmJ1bGw7XG4gICAgPC9kaXY+LFxuICBQaXZvdFZhbHVlQ29tcG9uZW50OiAoeyBzdWJSb3dzLCB2YWx1ZSB9KSA9PlxuICAgIDxzcGFuPlxuICAgICAge3ZhbHVlfSB7c3ViUm93cyAmJiBgKCR7c3ViUm93cy5sZW5ndGh9KWB9XG4gICAgPC9zcGFuPixcbiAgQWdncmVnYXRlZENvbXBvbmVudDogKHsgc3ViUm93cywgY29sdW1uIH0pID0+IHtcbiAgICBjb25zdCBwcmV2aWV3VmFsdWVzID0gc3ViUm93c1xuICAgICAgLmZpbHRlcihkID0+IHR5cGVvZiBkW2NvbHVtbi5pZF0gIT09ICd1bmRlZmluZWQnKVxuICAgICAgLm1hcCgocm93LCBpKSA9PlxuICAgICAgICA8c3BhbiBrZXk9e2l9PlxuICAgICAgICAgIHtyb3dbY29sdW1uLmlkXX1cbiAgICAgICAgICB7aSA8IHN1YlJvd3MubGVuZ3RoIC0gMSA/ICcsICcgOiAnJ31cbiAgICAgICAgPC9zcGFuPlxuICAgICAgKVxuICAgIHJldHVybiAoXG4gICAgICA8c3Bhbj5cbiAgICAgICAge3ByZXZpZXdWYWx1ZXN9XG4gICAgICA8L3NwYW4+XG4gICAgKVxuICB9LFxuICBQaXZvdENvbXBvbmVudDogdW5kZWZpbmVkLCAvLyB0aGlzIGlzIGEgY29tcHV0ZWQgZGVmYXVsdCBnZW5lcmF0ZWQgdXNpbmdcbiAgLy8gdGhlIEV4cGFuZGVyQ29tcG9uZW50IGFuZCBQaXZvdFZhbHVlQ29tcG9uZW50IGF0IHJ1bi10aW1lIGluIG1ldGhvZHMuanNcbiAgUGFnaW5hdGlvbkNvbXBvbmVudDogUGFnaW5hdGlvbixcbiAgUHJldmlvdXNDb21wb25lbnQ6IHVuZGVmaW5lZCxcbiAgTmV4dENvbXBvbmVudDogdW5kZWZpbmVkLFxuICBMb2FkaW5nQ29tcG9uZW50OiAoeyBjbGFzc05hbWUsIGxvYWRpbmcsIGxvYWRpbmdUZXh0LCAuLi5yZXN0IH0pID0+XG4gICAgPGRpdlxuICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCctbG9hZGluZycsIHsgJy1hY3RpdmUnOiBsb2FkaW5nIH0sIGNsYXNzTmFtZSl9XG4gICAgICB7Li4ucmVzdH1cbiAgICA+XG4gICAgICA8ZGl2IGNsYXNzTmFtZT0nLWxvYWRpbmctaW5uZXInPlxuICAgICAgICB7bG9hZGluZ1RleHR9XG4gICAgICA8L2Rpdj5cbiAgICA8L2Rpdj4sXG4gIE5vRGF0YUNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LW5vRGF0YScsICdOb0RhdGEnKSxcbiAgUmVzaXplckNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXJlc2l6ZXInLCAnUmVzaXplcicpLFxuICBQYWRSb3dDb21wb25lbnQ6ICgpID0+IDxzcGFuPiZuYnNwOzwvc3Bhbj4sXG59XG4iXX0= - /** - * Definition of context types this component sets for its children. - * - * @type {object} - * @optional - */ - childContextTypes: 'DEFINE_MANY', +/***/ }), +/* 362 */ +/***/ (function(module, exports, __webpack_require__) { - // ==== Definition methods ==== +"use strict"; - /** - * Invoked when the component is mounted. Values in the mapping will be set on - * `this.props` if that prop is not specified (i.e. using an `in` check). - * - * This method is invoked before `getInitialState` and therefore cannot rely - * on `this.state` or use `this.setState`. - * - * @return {object} - * @optional - */ - getDefaultProps: 'DEFINE_MANY_MERGED', - /** - * Invoked once before the component is mounted. The return value will be used - * as the initial value of `this.state`. - * - * getInitialState: function() { - * return { - * isOn: false, - * fooBaz: new BazFoo() - * } - * } - * - * @return {object} - * @optional - */ - getInitialState: 'DEFINE_MANY_MERGED', +Object.defineProperty(exports, "__esModule", { + value: true +}); - /** - * @return {object} - * @optional - */ - getChildContext: 'DEFINE_MANY_MERGED', +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - /** - * Uses props from `this.props` and state from `this.state` to render the - * structure of the component. - * - * No guarantees are made about when or how often this method is invoked, so - * it must not have side effects. - * - * render: function() { - * var name = this.props.name; - * return <div>Hello, {name}!</div>; - * } - * - * @return {ReactComponent} - * @required - */ - render: 'DEFINE_ONCE', +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - // ==== Delegate methods ==== +var _react = __webpack_require__(6); - /** - * Invoked when the component is initially created and about to be mounted. - * This may have side effects, but any external subscriptions or data created - * by this method must be cleaned up in `componentWillUnmount`. - * - * @optional - */ - componentWillMount: 'DEFINE_MANY', +var _react2 = _interopRequireDefault(_react); - /** - * Invoked when the component has been mounted and has a DOM representation. - * However, there is no guarantee that the DOM node is in the document. - * - * Use this as an opportunity to operate on the DOM when the component has - * been mounted (initialized and rendered) for the first time. - * - * @param {DOMElement} rootNode DOM element representing the component. - * @optional - */ - componentDidMount: 'DEFINE_MANY', +var _classnames = __webpack_require__(41); - /** - * Invoked before the component receives new props. - * - * Use this as an opportunity to react to a prop transition by updating the - * state using `this.setState`. Current props are accessed via `this.props`. - * - * componentWillReceiveProps: function(nextProps, nextContext) { - * this.setState({ - * likesIncreasing: nextProps.likeCount > this.props.likeCount - * }); - * } - * - * NOTE: There is no equivalent `componentWillReceiveState`. An incoming prop - * transition may cause a state change, but the opposite is not true. If you - * need it, you are probably looking for `componentWillUpdate`. - * - * @param {object} nextProps - * @optional - */ - componentWillReceiveProps: 'DEFINE_MANY', +var _classnames2 = _interopRequireDefault(_classnames); - /** - * Invoked while deciding if the component should be updated as a result of - * receiving new props, state and/or context. - * - * Use this as an opportunity to `return false` when you're certain that the - * transition to the new props/state/context will not require a component - * update. - * - * shouldComponentUpdate: function(nextProps, nextState, nextContext) { - * return !equal(nextProps, this.props) || - * !equal(nextState, this.state) || - * !equal(nextContext, this.context); - * } - * - * @param {object} nextProps - * @param {?object} nextState - * @param {?object} nextContext - * @return {boolean} True if the component should update. - * @optional - */ - shouldComponentUpdate: 'DEFINE_ONCE', +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - /** - * Invoked when the component is about to update due to a transition from - * `this.props`, `this.state` and `this.context` to `nextProps`, `nextState` - * and `nextContext`. - * - * Use this as an opportunity to perform preparation before an update occurs. - * - * NOTE: You **cannot** use `this.setState()` in this method. - * - * @param {object} nextProps - * @param {?object} nextState - * @param {?object} nextContext - * @param {ReactReconcileTransaction} transaction - * @optional - */ - componentWillUpdate: 'DEFINE_MANY', +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - /** - * Invoked when the component's DOM representation has been updated. - * - * Use this as an opportunity to operate on the DOM when the component has - * been updated. - * - * @param {object} prevProps - * @param {?object} prevState - * @param {?object} prevContext - * @param {DOMElement} rootNode DOM element representing the component. - * @optional - */ - componentDidUpdate: 'DEFINE_MANY', +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - /** - * Invoked when the component is about to be removed from its parent and have - * its DOM representation destroyed. - * - * Use this as an opportunity to deallocate any external resources. - * - * NOTE: There is no `componentDidUnmount` since your component will have been - * destroyed by that point. - * - * @optional - */ - componentWillUnmount: 'DEFINE_MANY', +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - // ==== Advanced methods ==== +// +// import _ from './utils' - /** - * Updates the component's currently mounted DOM representation. - * - * By default, this implements React's rendering and reconciliation algorithm. - * Sophisticated clients may wish to override this. - * - * @param {ReactReconcileTransaction} transaction - * @internal - * @overridable - */ - updateComponent: 'OVERRIDE_BASE' - }; +var defaultButton = function defaultButton(props) { + return _react2.default.createElement( + 'button', + _extends({ type: 'button' }, props, { className: '-btn' }), + props.children + ); +}; - /** - * Mapping from class specification keys to special processing functions. - * - * Although these are declared like instance properties in the specification - * when defining classes using `React.createClass`, they are actually static - * and are accessible on the constructor instead of the prototype. Despite - * being static, they must be defined outside of the "statics" key under - * which all other static methods are defined. - */ - var RESERVED_SPEC_KEYS = { - displayName: function(Constructor, displayName) { - Constructor.displayName = displayName; - }, - mixins: function(Constructor, mixins) { - if (mixins) { - for (var i = 0; i < mixins.length; i++) { - mixSpecIntoComponent(Constructor, mixins[i]); - } - } - }, - childContextTypes: function(Constructor, childContextTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, childContextTypes, 'childContext'); - } - Constructor.childContextTypes = _assign( - {}, - Constructor.childContextTypes, - childContextTypes - ); - }, - contextTypes: function(Constructor, contextTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, contextTypes, 'context'); - } - Constructor.contextTypes = _assign( - {}, - Constructor.contextTypes, - contextTypes - ); - }, - /** - * Special case getDefaultProps which should move into statics but requires - * automatic merging. - */ - getDefaultProps: function(Constructor, getDefaultProps) { - if (Constructor.getDefaultProps) { - Constructor.getDefaultProps = createMergedResultFunction( - Constructor.getDefaultProps, - getDefaultProps - ); - } else { - Constructor.getDefaultProps = getDefaultProps; - } - }, - propTypes: function(Constructor, propTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, propTypes, 'prop'); - } - Constructor.propTypes = _assign({}, Constructor.propTypes, propTypes); - }, - statics: function(Constructor, statics) { - mixStaticSpecIntoComponent(Constructor, statics); - }, - autobind: function() {} - }; +var ReactTablePagination = function (_Component) { + _inherits(ReactTablePagination, _Component); - function validateTypeDef(Constructor, typeDef, location) { - for (var propName in typeDef) { - if (typeDef.hasOwnProperty(propName)) { - // use a warning instead of an _invariant so components - // don't show up in prod but only in __DEV__ - if (process.env.NODE_ENV !== 'production') { - warning( - typeof typeDef[propName] === 'function', - '%s: %s type `%s` is invalid; it must be a function, usually from ' + - 'React.PropTypes.', - Constructor.displayName || 'ReactClass', - ReactPropTypeLocationNames[location], - propName - ); - } + function ReactTablePagination(props) { + _classCallCheck(this, ReactTablePagination); + + var _this = _possibleConstructorReturn(this, (ReactTablePagination.__proto__ || Object.getPrototypeOf(ReactTablePagination)).call(this)); + + _this.getSafePage = _this.getSafePage.bind(_this); + _this.changePage = _this.changePage.bind(_this); + _this.applyPage = _this.applyPage.bind(_this); + + _this.state = { + page: props.page + }; + return _this; + } + + _createClass(ReactTablePagination, [{ + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + this.setState({ page: nextProps.page }); + } + }, { + key: 'getSafePage', + value: function getSafePage(page) { + if (isNaN(page)) { + page = this.props.page; } + return Math.min(Math.max(page, 0), this.props.pages - 1); } - } + }, { + key: 'changePage', + value: function changePage(page) { + page = this.getSafePage(page); + this.setState({ page: page }); + if (this.props.page !== page) { + this.props.onPageChange(page); + } + } + }, { + key: 'applyPage', + value: function applyPage(e) { + e && e.preventDefault(); + var page = this.state.page; + this.changePage(page === '' ? this.props.page : page); + } + }, { + key: 'render', + value: function render() { + var _this2 = this; - function validateMethodOverride(isAlreadyDefined, name) { - var specPolicy = ReactClassInterface.hasOwnProperty(name) - ? ReactClassInterface[name] - : null; + var _props = this.props, + pages = _props.pages, + page = _props.page, + showPageSizeOptions = _props.showPageSizeOptions, + pageSizeOptions = _props.pageSizeOptions, + pageSize = _props.pageSize, + showPageJump = _props.showPageJump, + canPrevious = _props.canPrevious, + canNext = _props.canNext, + onPageSizeChange = _props.onPageSizeChange, + className = _props.className, + _props$PreviousCompon = _props.PreviousComponent, + PreviousComponent = _props$PreviousCompon === undefined ? defaultButton : _props$PreviousCompon, + _props$NextComponent = _props.NextComponent, + NextComponent = _props$NextComponent === undefined ? defaultButton : _props$NextComponent; - // Disallow overriding of base class methods unless explicitly allowed. - if (ReactClassMixin.hasOwnProperty(name)) { - _invariant( - specPolicy === 'OVERRIDE_BASE', - 'ReactClassInterface: You are attempting to override ' + - '`%s` from your class specification. Ensure that your method names ' + - 'do not overlap with React methods.', - name - ); - } - // Disallow defining methods more than once unless explicitly allowed. - if (isAlreadyDefined) { - _invariant( - specPolicy === 'DEFINE_MANY' || specPolicy === 'DEFINE_MANY_MERGED', - 'ReactClassInterface: You are attempting to define ' + - '`%s` on your component more than once. This conflict may be due ' + - 'to a mixin.', - name + return _react2.default.createElement( + 'div', + { + className: (0, _classnames2.default)(className, '-pagination'), + style: this.props.paginationStyle + }, + _react2.default.createElement( + 'div', + { className: '-previous' }, + _react2.default.createElement( + PreviousComponent, + { + onClick: function onClick(e) { + if (!canPrevious) return; + _this2.changePage(page - 1); + }, + disabled: !canPrevious + }, + this.props.previousText + ) + ), + _react2.default.createElement( + 'div', + { className: '-center' }, + _react2.default.createElement( + 'span', + { className: '-pageInfo' }, + this.props.pageText, + ' ', + showPageJump ? _react2.default.createElement( + 'div', + { className: '-pageJump' }, + _react2.default.createElement('input', { + type: this.state.page === '' ? 'text' : 'number', + onChange: function onChange(e) { + var val = e.target.value; + var page = val - 1; + if (val === '') { + return _this2.setState({ page: val }); + } + _this2.setState({ page: _this2.getSafePage(page) }); + }, + value: this.state.page === '' ? '' : this.state.page + 1, + onBlur: this.applyPage, + onKeyPress: function onKeyPress(e) { + if (e.which === 13 || e.keyCode === 13) { + _this2.applyPage(); + } + } + }) + ) : _react2.default.createElement( + 'span', + { className: '-currentPage' }, + page + 1 + ), + ' ', + this.props.ofText, + ' ', + _react2.default.createElement( + 'span', + { className: '-totalPages' }, + pages || 1 + ) + ), + showPageSizeOptions && _react2.default.createElement( + 'span', + { className: 'select-wrap -pageSizeOptions' }, + _react2.default.createElement( + 'select', + { + onChange: function onChange(e) { + return onPageSizeChange(Number(e.target.value)); + }, + value: pageSize + }, + pageSizeOptions.map(function (option, i) { + return _react2.default.createElement( + 'option', + { key: i, value: option }, + option, + ' ', + _this2.props.rowsText + ); + }) + ) + ) + ), + _react2.default.createElement( + 'div', + { className: '-next' }, + _react2.default.createElement( + NextComponent, + { + onClick: function onClick(e) { + if (!canNext) return; + _this2.changePage(page + 1); + }, + disabled: !canNext + }, + this.props.nextText + ) + ) ); } + }]); + + return ReactTablePagination; +}(_react.Component); + +exports.default = ReactTablePagination; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9wYWdpbmF0aW9uLmpzIl0sIm5hbWVzIjpbImRlZmF1bHRCdXR0b24iLCJwcm9wcyIsImNoaWxkcmVuIiwiUmVhY3RUYWJsZVBhZ2luYXRpb24iLCJnZXRTYWZlUGFnZSIsImJpbmQiLCJjaGFuZ2VQYWdlIiwiYXBwbHlQYWdlIiwic3RhdGUiLCJwYWdlIiwibmV4dFByb3BzIiwic2V0U3RhdGUiLCJpc05hTiIsIk1hdGgiLCJtaW4iLCJtYXgiLCJwYWdlcyIsIm9uUGFnZUNoYW5nZSIsImUiLCJwcmV2ZW50RGVmYXVsdCIsInNob3dQYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZSIsInNob3dQYWdlSnVtcCIsImNhblByZXZpb3VzIiwiY2FuTmV4dCIsIm9uUGFnZVNpemVDaGFuZ2UiLCJjbGFzc05hbWUiLCJQcmV2aW91c0NvbXBvbmVudCIsIk5leHRDb21wb25lbnQiLCJwYWdpbmF0aW9uU3R5bGUiLCJwcmV2aW91c1RleHQiLCJwYWdlVGV4dCIsInZhbCIsInRhcmdldCIsInZhbHVlIiwid2hpY2giLCJrZXlDb2RlIiwib2ZUZXh0IiwiTnVtYmVyIiwibWFwIiwib3B0aW9uIiwiaSIsInJvd3NUZXh0IiwibmV4dFRleHQiXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7Ozs7Ozs7Ozs7QUFDQTtBQUNBOztBQUVBLElBQU1BLGdCQUFnQixTQUFoQkEsYUFBZ0I7QUFBQSxTQUNwQjtBQUFBO0FBQUEsZUFBUSxNQUFLLFFBQWIsSUFBMEJDLEtBQTFCLElBQWlDLFdBQVUsTUFBM0M7QUFDR0EsVUFBTUM7QUFEVCxHQURvQjtBQUFBLENBQXRCOztJQUtxQkMsb0I7OztBQUNuQixnQ0FBYUYsS0FBYixFQUFvQjtBQUFBOztBQUFBOztBQUdsQixVQUFLRyxXQUFMLEdBQW1CLE1BQUtBLFdBQUwsQ0FBaUJDLElBQWpCLE9BQW5CO0FBQ0EsVUFBS0MsVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCRCxJQUFoQixPQUFsQjtBQUNBLFVBQUtFLFNBQUwsR0FBaUIsTUFBS0EsU0FBTCxDQUFlRixJQUFmLE9BQWpCOztBQUVBLFVBQUtHLEtBQUwsR0FBYTtBQUNYQyxZQUFNUixNQUFNUTtBQURELEtBQWI7QUFQa0I7QUFVbkI7Ozs7OENBRTBCQyxTLEVBQVc7QUFDcEMsV0FBS0MsUUFBTCxDQUFjLEVBQUVGLE1BQU1DLFVBQVVELElBQWxCLEVBQWQ7QUFDRDs7O2dDQUVZQSxJLEVBQU07QUFDakIsVUFBSUcsTUFBTUgsSUFBTixDQUFKLEVBQWlCO0FBQ2ZBLGVBQU8sS0FBS1IsS0FBTCxDQUFXUSxJQUFsQjtBQUNEO0FBQ0QsYUFBT0ksS0FBS0MsR0FBTCxDQUFTRCxLQUFLRSxHQUFMLENBQVNOLElBQVQsRUFBZSxDQUFmLENBQVQsRUFBNEIsS0FBS1IsS0FBTCxDQUFXZSxLQUFYLEdBQW1CLENBQS9DLENBQVA7QUFDRDs7OytCQUVXUCxJLEVBQU07QUFDaEJBLGFBQU8sS0FBS0wsV0FBTCxDQUFpQkssSUFBakIsQ0FBUDtBQUNBLFdBQUtFLFFBQUwsQ0FBYyxFQUFFRixVQUFGLEVBQWQ7QUFDQSxVQUFJLEtBQUtSLEtBQUwsQ0FBV1EsSUFBWCxLQUFvQkEsSUFBeEIsRUFBOEI7QUFDNUIsYUFBS1IsS0FBTCxDQUFXZ0IsWUFBWCxDQUF3QlIsSUFBeEI7QUFDRDtBQUNGOzs7OEJBRVVTLEMsRUFBRztBQUNaQSxXQUFLQSxFQUFFQyxjQUFGLEVBQUw7QUFDQSxVQUFNVixPQUFPLEtBQUtELEtBQUwsQ0FBV0MsSUFBeEI7QUFDQSxXQUFLSCxVQUFMLENBQWdCRyxTQUFTLEVBQVQsR0FBYyxLQUFLUixLQUFMLENBQVdRLElBQXpCLEdBQWdDQSxJQUFoRDtBQUNEOzs7NkJBRVM7QUFBQTs7QUFBQSxtQkFnQkosS0FBS1IsS0FoQkQ7QUFBQSxVQUdOZSxLQUhNLFVBR05BLEtBSE07QUFBQSxVQUtOUCxJQUxNLFVBS05BLElBTE07QUFBQSxVQU1OVyxtQkFOTSxVQU1OQSxtQkFOTTtBQUFBLFVBT05DLGVBUE0sVUFPTkEsZUFQTTtBQUFBLFVBUU5DLFFBUk0sVUFRTkEsUUFSTTtBQUFBLFVBU05DLFlBVE0sVUFTTkEsWUFUTTtBQUFBLFVBVU5DLFdBVk0sVUFVTkEsV0FWTTtBQUFBLFVBV05DLE9BWE0sVUFXTkEsT0FYTTtBQUFBLFVBWU5DLGdCQVpNLFVBWU5BLGdCQVpNO0FBQUEsVUFhTkMsU0FiTSxVQWFOQSxTQWJNO0FBQUEseUNBY05DLGlCQWRNO0FBQUEsVUFjTkEsaUJBZE0seUNBY2M1QixhQWRkO0FBQUEsd0NBZU42QixhQWZNO0FBQUEsVUFlTkEsYUFmTSx3Q0FlVTdCLGFBZlY7OztBQWtCUixhQUNFO0FBQUE7QUFBQTtBQUNFLHFCQUFXLDBCQUFXMkIsU0FBWCxFQUFzQixhQUF0QixDQURiO0FBRUUsaUJBQU8sS0FBSzFCLEtBQUwsQ0FBVzZCO0FBRnBCO0FBSUU7QUFBQTtBQUFBLFlBQUssV0FBVSxXQUFmO0FBQ0U7QUFBQyw2QkFBRDtBQUFBO0FBQ0UsdUJBQVMsb0JBQUs7QUFDWixvQkFBSSxDQUFDTixXQUFMLEVBQWtCO0FBQ2xCLHVCQUFLbEIsVUFBTCxDQUFnQkcsT0FBTyxDQUF2QjtBQUNELGVBSkg7QUFLRSx3QkFBVSxDQUFDZTtBQUxiO0FBT0csaUJBQUt2QixLQUFMLENBQVc4QjtBQVBkO0FBREYsU0FKRjtBQWVFO0FBQUE7QUFBQSxZQUFLLFdBQVUsU0FBZjtBQUNFO0FBQUE7QUFBQSxjQUFNLFdBQVUsV0FBaEI7QUFDRyxpQkFBSzlCLEtBQUwsQ0FBVytCLFFBRGQ7QUFDd0IsZUFEeEI7QUFFR1QsMkJBQ0c7QUFBQTtBQUFBLGdCQUFLLFdBQVUsV0FBZjtBQUNBO0FBQ0Usc0JBQU0sS0FBS2YsS0FBTCxDQUFXQyxJQUFYLEtBQW9CLEVBQXBCLEdBQXlCLE1BQXpCLEdBQWtDLFFBRDFDO0FBRUUsMEJBQVUscUJBQUs7QUFDYixzQkFBTXdCLE1BQU1mLEVBQUVnQixNQUFGLENBQVNDLEtBQXJCO0FBQ0Esc0JBQU0xQixPQUFPd0IsTUFBTSxDQUFuQjtBQUNBLHNCQUFJQSxRQUFRLEVBQVosRUFBZ0I7QUFDZCwyQkFBTyxPQUFLdEIsUUFBTCxDQUFjLEVBQUVGLE1BQU13QixHQUFSLEVBQWQsQ0FBUDtBQUNEO0FBQ0QseUJBQUt0QixRQUFMLENBQWMsRUFBRUYsTUFBTSxPQUFLTCxXQUFMLENBQWlCSyxJQUFqQixDQUFSLEVBQWQ7QUFDRCxpQkFUSDtBQVVFLHVCQUFPLEtBQUtELEtBQUwsQ0FBV0MsSUFBWCxLQUFvQixFQUFwQixHQUF5QixFQUF6QixHQUE4QixLQUFLRCxLQUFMLENBQVdDLElBQVgsR0FBa0IsQ0FWekQ7QUFXRSx3QkFBUSxLQUFLRixTQVhmO0FBWUUsNEJBQVksdUJBQUs7QUFDZixzQkFBSVcsRUFBRWtCLEtBQUYsS0FBWSxFQUFaLElBQWtCbEIsRUFBRW1CLE9BQUYsS0FBYyxFQUFwQyxFQUF3QztBQUN0QywyQkFBSzlCLFNBQUw7QUFDRDtBQUNGO0FBaEJIO0FBREEsYUFESCxHQXFCRztBQUFBO0FBQUEsZ0JBQU0sV0FBVSxjQUFoQjtBQUNDRSxxQkFBTztBQURSLGFBdkJOO0FBeUJhLGVBekJiO0FBMEJHLGlCQUFLUixLQUFMLENBQVdxQyxNQTFCZDtBQTBCc0IsZUExQnRCO0FBMkJFO0FBQUE7QUFBQSxnQkFBTSxXQUFVLGFBQWhCO0FBQStCdEIsdUJBQVM7QUFBeEM7QUEzQkYsV0FERjtBQThCR0ksaUNBQ0M7QUFBQTtBQUFBLGNBQU0sV0FBVSw4QkFBaEI7QUFDRTtBQUFBO0FBQUE7QUFDRSwwQkFBVTtBQUFBLHlCQUFLTSxpQkFBaUJhLE9BQU9yQixFQUFFZ0IsTUFBRixDQUFTQyxLQUFoQixDQUFqQixDQUFMO0FBQUEsaUJBRFo7QUFFRSx1QkFBT2I7QUFGVDtBQUlHRCw4QkFBZ0JtQixHQUFoQixDQUFvQixVQUFDQyxNQUFELEVBQVNDLENBQVQsRUFBZTtBQUNsQyx1QkFDRTtBQUFBO0FBQUEsb0JBQVEsS0FBS0EsQ0FBYixFQUFnQixPQUFPRCxNQUF2QjtBQUNHQSx3QkFESDtBQUFBO0FBQ1kseUJBQUt4QyxLQUFMLENBQVcwQztBQUR2QixpQkFERjtBQUtELGVBTkE7QUFKSDtBQURGO0FBL0JKLFNBZkY7QUE2REU7QUFBQTtBQUFBLFlBQUssV0FBVSxPQUFmO0FBQ0U7QUFBQyx5QkFBRDtBQUFBO0FBQ0UsdUJBQVMsb0JBQUs7QUFDWixvQkFBSSxDQUFDbEIsT0FBTCxFQUFjO0FBQ2QsdUJBQUtuQixVQUFMLENBQWdCRyxPQUFPLENBQXZCO0FBQ0QsZUFKSDtBQUtFLHdCQUFVLENBQUNnQjtBQUxiO0FBT0csaUJBQUt4QixLQUFMLENBQVcyQztBQVBkO0FBREY7QUE3REYsT0FERjtBQTJFRDs7Ozs7O2tCQW5Ja0J6QyxvQiIsImZpbGUiOiJwYWdpbmF0aW9uLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IFJlYWN0LCB7IENvbXBvbmVudCB9IGZyb20gJ3JlYWN0J1xuaW1wb3J0IGNsYXNzbmFtZXMgZnJvbSAnY2xhc3NuYW1lcydcbi8vXG4vLyBpbXBvcnQgXyBmcm9tICcuL3V0aWxzJ1xuXG5jb25zdCBkZWZhdWx0QnV0dG9uID0gcHJvcHMgPT5cbiAgPGJ1dHRvbiB0eXBlPSdidXR0b24nIHsuLi5wcm9wc30gY2xhc3NOYW1lPSctYnRuJz5cbiAgICB7cHJvcHMuY2hpbGRyZW59XG4gIDwvYnV0dG9uPlxuXG5leHBvcnQgZGVmYXVsdCBjbGFzcyBSZWFjdFRhYmxlUGFnaW5hdGlvbiBleHRlbmRzIENvbXBvbmVudCB7XG4gIGNvbnN0cnVjdG9yIChwcm9wcykge1xuICAgIHN1cGVyKClcblxuICAgIHRoaXMuZ2V0U2FmZVBhZ2UgPSB0aGlzLmdldFNhZmVQYWdlLmJpbmQodGhpcylcbiAgICB0aGlzLmNoYW5nZVBhZ2UgPSB0aGlzLmNoYW5nZVBhZ2UuYmluZCh0aGlzKVxuICAgIHRoaXMuYXBwbHlQYWdlID0gdGhpcy5hcHBseVBhZ2UuYmluZCh0aGlzKVxuXG4gICAgdGhpcy5zdGF0ZSA9IHtcbiAgICAgIHBhZ2U6IHByb3BzLnBhZ2UsXG4gICAgfVxuICB9XG5cbiAgY29tcG9uZW50V2lsbFJlY2VpdmVQcm9wcyAobmV4dFByb3BzKSB7XG4gICAgdGhpcy5zZXRTdGF0ZSh7IHBhZ2U6IG5leHRQcm9wcy5wYWdlIH0pXG4gIH1cblxuICBnZXRTYWZlUGFnZSAocGFnZSkge1xuICAgIGlmIChpc05hTihwYWdlKSkge1xuICAgICAgcGFnZSA9IHRoaXMucHJvcHMucGFnZVxuICAgIH1cbiAgICByZXR1cm4gTWF0aC5taW4oTWF0aC5tYXgocGFnZSwgMCksIHRoaXMucHJvcHMucGFnZXMgLSAxKVxuICB9XG5cbiAgY2hhbmdlUGFnZSAocGFnZSkge1xuICAgIHBhZ2UgPSB0aGlzLmdldFNhZmVQYWdlKHBhZ2UpXG4gICAgdGhpcy5zZXRTdGF0ZSh7IHBhZ2UgfSlcbiAgICBpZiAodGhpcy5wcm9wcy5wYWdlICE9PSBwYWdlKSB7XG4gICAgICB0aGlzLnByb3BzLm9uUGFnZUNoYW5nZShwYWdlKVxuICAgIH1cbiAgfVxuXG4gIGFwcGx5UGFnZSAoZSkge1xuICAgIGUgJiYgZS5wcmV2ZW50RGVmYXVsdCgpXG4gICAgY29uc3QgcGFnZSA9IHRoaXMuc3RhdGUucGFnZVxuICAgIHRoaXMuY2hhbmdlUGFnZShwYWdlID09PSAnJyA/IHRoaXMucHJvcHMucGFnZSA6IHBhZ2UpXG4gIH1cblxuICByZW5kZXIgKCkge1xuICAgIGNvbnN0IHtcbiAgICAgIC8vIENvbXB1dGVkXG4gICAgICBwYWdlcyxcbiAgICAgIC8vIFByb3BzXG4gICAgICBwYWdlLFxuICAgICAgc2hvd1BhZ2VTaXplT3B0aW9ucyxcbiAgICAgIHBhZ2VTaXplT3B0aW9ucyxcbiAgICAgIHBhZ2VTaXplLFxuICAgICAgc2hvd1BhZ2VKdW1wLFxuICAgICAgY2FuUHJldmlvdXMsXG4gICAgICBjYW5OZXh0LFxuICAgICAgb25QYWdlU2l6ZUNoYW5nZSxcbiAgICAgIGNsYXNzTmFtZSxcbiAgICAgIFByZXZpb3VzQ29tcG9uZW50ID0gZGVmYXVsdEJ1dHRvbixcbiAgICAgIE5leHRDb21wb25lbnQgPSBkZWZhdWx0QnV0dG9uLFxuICAgIH0gPSB0aGlzLnByb3BzXG5cbiAgICByZXR1cm4gKFxuICAgICAgPGRpdlxuICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NOYW1lLCAnLXBhZ2luYXRpb24nKX1cbiAgICAgICAgc3R5bGU9e3RoaXMucHJvcHMucGFnaW5hdGlvblN0eWxlfVxuICAgICAgPlxuICAgICAgICA8ZGl2IGNsYXNzTmFtZT0nLXByZXZpb3VzJz5cbiAgICAgICAgICA8UHJldmlvdXNDb21wb25lbnRcbiAgICAgICAgICAgIG9uQ2xpY2s9e2UgPT4ge1xuICAgICAgICAgICAgICBpZiAoIWNhblByZXZpb3VzKSByZXR1cm5cbiAgICAgICAgICAgICAgdGhpcy5jaGFuZ2VQYWdlKHBhZ2UgLSAxKVxuICAgICAgICAgICAgfX1cbiAgICAgICAgICAgIGRpc2FibGVkPXshY2FuUHJldmlvdXN9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge3RoaXMucHJvcHMucHJldmlvdXNUZXh0fVxuICAgICAgICAgIDwvUHJldmlvdXNDb21wb25lbnQ+XG4gICAgICAgIDwvZGl2PlxuICAgICAgICA8ZGl2IGNsYXNzTmFtZT0nLWNlbnRlcic+XG4gICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSctcGFnZUluZm8nPlxuICAgICAgICAgICAge3RoaXMucHJvcHMucGFnZVRleHR9eycgJ31cbiAgICAgICAgICAgIHtzaG93UGFnZUp1bXBcbiAgICAgICAgICAgICAgPyA8ZGl2IGNsYXNzTmFtZT0nLXBhZ2VKdW1wJz5cbiAgICAgICAgICAgICAgICA8aW5wdXRcbiAgICAgICAgICAgICAgICAgIHR5cGU9e3RoaXMuc3RhdGUucGFnZSA9PT0gJycgPyAndGV4dCcgOiAnbnVtYmVyJ31cbiAgICAgICAgICAgICAgICAgIG9uQ2hhbmdlPXtlID0+IHtcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgdmFsID0gZS50YXJnZXQudmFsdWVcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgcGFnZSA9IHZhbCAtIDFcbiAgICAgICAgICAgICAgICAgICAgaWYgKHZhbCA9PT0gJycpIHtcbiAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdGhpcy5zZXRTdGF0ZSh7IHBhZ2U6IHZhbCB9KVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuc2V0U3RhdGUoeyBwYWdlOiB0aGlzLmdldFNhZmVQYWdlKHBhZ2UpIH0pXG4gICAgICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICAgICAgdmFsdWU9e3RoaXMuc3RhdGUucGFnZSA9PT0gJycgPyAnJyA6IHRoaXMuc3RhdGUucGFnZSArIDF9XG4gICAgICAgICAgICAgICAgICBvbkJsdXI9e3RoaXMuYXBwbHlQYWdlfVxuICAgICAgICAgICAgICAgICAgb25LZXlQcmVzcz17ZSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChlLndoaWNoID09PSAxMyB8fCBlLmtleUNvZGUgPT09IDEzKSB7XG4gICAgICAgICAgICAgICAgICAgICAgdGhpcy5hcHBseVBhZ2UoKVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICAgIC8+XG4gICAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgICAgICA6IDxzcGFuIGNsYXNzTmFtZT0nLWN1cnJlbnRQYWdlJz5cbiAgICAgICAgICAgICAgICB7cGFnZSArIDF9XG4gICAgICAgICAgICAgIDwvc3Bhbj59eycgJ31cbiAgICAgICAgICAgIHt0aGlzLnByb3BzLm9mVGV4dH17JyAnfVxuICAgICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSctdG90YWxQYWdlcyc+e3BhZ2VzIHx8IDF9PC9zcGFuPlxuICAgICAgICAgIDwvc3Bhbj5cbiAgICAgICAgICB7c2hvd1BhZ2VTaXplT3B0aW9ucyAmJlxuICAgICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSdzZWxlY3Qtd3JhcCAtcGFnZVNpemVPcHRpb25zJz5cbiAgICAgICAgICAgICAgPHNlbGVjdFxuICAgICAgICAgICAgICAgIG9uQ2hhbmdlPXtlID0+IG9uUGFnZVNpemVDaGFuZ2UoTnVtYmVyKGUudGFyZ2V0LnZhbHVlKSl9XG4gICAgICAgICAgICAgICAgdmFsdWU9e3BhZ2VTaXplfVxuICAgICAgICAgICAgICA+XG4gICAgICAgICAgICAgICAge3BhZ2VTaXplT3B0aW9ucy5tYXAoKG9wdGlvbiwgaSkgPT4ge1xuICAgICAgICAgICAgICAgICAgcmV0dXJuIChcbiAgICAgICAgICAgICAgICAgICAgPG9wdGlvbiBrZXk9e2l9IHZhbHVlPXtvcHRpb259PlxuICAgICAgICAgICAgICAgICAgICAgIHtvcHRpb259IHt0aGlzLnByb3BzLnJvd3NUZXh0fVxuICAgICAgICAgICAgICAgICAgICA8L29wdGlvbj5cbiAgICAgICAgICAgICAgICAgIClcbiAgICAgICAgICAgICAgICB9KX1cbiAgICAgICAgICAgICAgPC9zZWxlY3Q+XG4gICAgICAgICAgICA8L3NwYW4+fVxuICAgICAgICA8L2Rpdj5cbiAgICAgICAgPGRpdiBjbGFzc05hbWU9Jy1uZXh0Jz5cbiAgICAgICAgICA8TmV4dENvbXBvbmVudFxuICAgICAgICAgICAgb25DbGljaz17ZSA9PiB7XG4gICAgICAgICAgICAgIGlmICghY2FuTmV4dCkgcmV0dXJuXG4gICAgICAgICAgICAgIHRoaXMuY2hhbmdlUGFnZShwYWdlICsgMSlcbiAgICAgICAgICAgIH19XG4gICAgICAgICAgICBkaXNhYmxlZD17IWNhbk5leHR9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge3RoaXMucHJvcHMubmV4dFRleHR9XG4gICAgICAgICAgPC9OZXh0Q29tcG9uZW50PlxuICAgICAgICA8L2Rpdj5cbiAgICAgIDwvZGl2PlxuICAgIClcbiAgfVxufVxuIl19 + +/***/ }), +/* 363 */ +/***/ (function(module, exports, __webpack_require__) { + +var basex = __webpack_require__(364) +var ALPHABET = '123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz' + +module.exports = basex(ALPHABET) + + +/***/ }), +/* 364 */ +/***/ (function(module, exports, __webpack_require__) { + +// base-x encoding +// Forked from https://github.com/cryptocoinjs/bs58 +// Originally written by Mike Hearn for BitcoinJ +// Copyright (c) 2011 Google Inc +// Ported to JavaScript by Stefan Thomas +// Merged Buffer refactorings from base58-native by Stephen Pair +// Copyright (c) 2013 BitPay Inc + +var Buffer = __webpack_require__(7).Buffer + +module.exports = function base (ALPHABET) { + var ALPHABET_MAP = {} + var BASE = ALPHABET.length + var LEADER = ALPHABET.charAt(0) + + // pre-compute lookup table + for (var z = 0; z < ALPHABET.length; z++) { + var x = ALPHABET.charAt(z) + + if (ALPHABET_MAP[x] !== undefined) throw new TypeError(x + ' is ambiguous') + ALPHABET_MAP[x] = z } - /** - * Mixin helper which handles policy validation and reserved - * specification keys when building React classes. - */ - function mixSpecIntoComponent(Constructor, spec) { - if (!spec) { - if (process.env.NODE_ENV !== 'production') { - var typeofSpec = typeof spec; - var isMixinValid = typeofSpec === 'object' && spec !== null; + function encode (source) { + if (source.length === 0) return '' - if (process.env.NODE_ENV !== 'production') { - warning( - isMixinValid, - "%s: You're attempting to include a mixin that is either null " + - 'or not an object. Check the mixins included by the component, ' + - 'as well as any mixins they include themselves. ' + - 'Expected object but got %s.', - Constructor.displayName || 'ReactClass', - spec === null ? null : typeofSpec - ); - } + var digits = [0] + for (var i = 0; i < source.length; ++i) { + for (var j = 0, carry = source[i]; j < digits.length; ++j) { + carry += digits[j] << 8 + digits[j] = carry % BASE + carry = (carry / BASE) | 0 } - return; + while (carry > 0) { + digits.push(carry % BASE) + carry = (carry / BASE) | 0 + } } - _invariant( - typeof spec !== 'function', - "ReactClass: You're attempting to " + - 'use a component class or function as a mixin. Instead, just use a ' + - 'regular object.' - ); - _invariant( - !isValidElement(spec), - "ReactClass: You're attempting to " + - 'use a component as a mixin. Instead, just use a regular object.' - ); + var string = '' - var proto = Constructor.prototype; - var autoBindPairs = proto.__reactAutoBindPairs; + // deal with leading zeros + for (var k = 0; source[k] === 0 && k < source.length - 1; ++k) string += ALPHABET[0] + // convert digits to a string + for (var q = digits.length - 1; q >= 0; --q) string += ALPHABET[digits[q]] - // By handling mixins before any other properties, we ensure the same - // chaining order is applied to methods with DEFINE_MANY policy, whether - // mixins are listed before or after these methods in the spec. - if (spec.hasOwnProperty(MIXINS_KEY)) { - RESERVED_SPEC_KEYS.mixins(Constructor, spec.mixins); - } + return string + } - for (var name in spec) { - if (!spec.hasOwnProperty(name)) { - continue; + function decodeUnsafe (string) { + if (string.length === 0) return Buffer.allocUnsafe(0) + + var bytes = [0] + for (var i = 0; i < string.length; i++) { + var value = ALPHABET_MAP[string[i]] + if (value === undefined) return + + for (var j = 0, carry = value; j < bytes.length; ++j) { + carry += bytes[j] * BASE + bytes[j] = carry & 0xff + carry >>= 8 } - if (name === MIXINS_KEY) { - // We have already handled mixins in a special case above. - continue; + while (carry > 0) { + bytes.push(carry & 0xff) + carry >>= 8 } + } - var property = spec[name]; - var isAlreadyDefined = proto.hasOwnProperty(name); - validateMethodOverride(isAlreadyDefined, name); + // deal with leading zeros + for (var k = 0; string[k] === LEADER && k < string.length - 1; ++k) { + bytes.push(0) + } - if (RESERVED_SPEC_KEYS.hasOwnProperty(name)) { - RESERVED_SPEC_KEYS[name](Constructor, property); - } else { - // Setup methods on prototype: - // The following member methods should not be automatically bound: - // 1. Expected ReactClass methods (in the "interface"). - // 2. Overridden methods (that were mixed in). - var isReactClassMethod = ReactClassInterface.hasOwnProperty(name); - var isFunction = typeof property === 'function'; - var shouldAutoBind = - isFunction && - !isReactClassMethod && - !isAlreadyDefined && - spec.autobind !== false; + return Buffer.from(bytes.reverse()) + } - if (shouldAutoBind) { - autoBindPairs.push(name, property); - proto[name] = property; - } else { - if (isAlreadyDefined) { - var specPolicy = ReactClassInterface[name]; + function decode (string) { + var buffer = decodeUnsafe(string) + if (buffer) return buffer - // These cases should already be caught by validateMethodOverride. - _invariant( - isReactClassMethod && - (specPolicy === 'DEFINE_MANY_MERGED' || - specPolicy === 'DEFINE_MANY'), - 'ReactClass: Unexpected spec policy %s for key %s ' + - 'when mixing in component specs.', - specPolicy, - name - ); + throw new Error('Non-base' + BASE + ' character') + } - // For methods which are defined more than once, call the existing - // methods before calling the new property, merging if appropriate. - if (specPolicy === 'DEFINE_MANY_MERGED') { - proto[name] = createMergedResultFunction(proto[name], property); - } else if (specPolicy === 'DEFINE_MANY') { - proto[name] = createChainedFunction(proto[name], property); - } - } else { - proto[name] = property; - if (process.env.NODE_ENV !== 'production') { - // Add verbose displayName to the function, which helps when looking - // at profiling tools. - if (typeof property === 'function' && spec.displayName) { - proto[name].displayName = spec.displayName + '_' + name; - } - } - } - } - } - } + return { + encode: encode, + decodeUnsafe: decodeUnsafe, + decode: decode } +} - function mixStaticSpecIntoComponent(Constructor, statics) { - if (!statics) { - return; - } - for (var name in statics) { - var property = statics[name]; - if (!statics.hasOwnProperty(name)) { - continue; - } - var isReserved = name in RESERVED_SPEC_KEYS; - _invariant( - !isReserved, - 'ReactClass: You are attempting to define a reserved ' + - 'property, `%s`, that shouldn\'t be on the "statics" key. Define it ' + - 'as an instance property instead; it will still be accessible on the ' + - 'constructor.', - name - ); +/***/ }), +/* 365 */ +/***/ (function(module, exports, __webpack_require__) { - var isInherited = name in Constructor; - _invariant( - !isInherited, - 'ReactClass: You are attempting to define ' + - '`%s` on your component more than once. This conflict may be ' + - 'due to a mixin.', - name - ); - Constructor[name] = property; - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var intSize = 4 +var zeroBuffer = new Buffer(intSize) +zeroBuffer.fill(0) + +var charSize = 8 +var hashSize = 16 + +function toArray (buf) { + if ((buf.length % intSize) !== 0) { + var len = buf.length + (intSize - (buf.length % intSize)) + buf = Buffer.concat([buf, zeroBuffer], len) } - /** - * Merge two objects, but throw if both contain the same key. - * - * @param {object} one The first object, which is mutated. - * @param {object} two The second object - * @return {object} one after it has been mutated to contain everything in two. - */ - function mergeIntoWithNoDuplicateKeys(one, two) { - _invariant( - one && two && typeof one === 'object' && typeof two === 'object', - 'mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.' - ); + var arr = new Array(buf.length >>> 2) + for (var i = 0, j = 0; i < buf.length; i += intSize, j++) { + arr[j] = buf.readInt32LE(i) + } - for (var key in two) { - if (two.hasOwnProperty(key)) { - _invariant( - one[key] === undefined, - 'mergeIntoWithNoDuplicateKeys(): ' + - 'Tried to merge two objects with the same key: `%s`. This conflict ' + - 'may be due to a mixin; in particular, this may be caused by two ' + - 'getInitialState() or getDefaultProps() methods returning objects ' + - 'with clashing keys.', - key - ); - one[key] = two[key]; - } - } - return one; + return arr +} + +module.exports = function hash (buf, fn) { + var arr = fn(toArray(buf), buf.length * charSize) + buf = new Buffer(hashSize) + for (var i = 0; i < arr.length; i++) { + buf.writeInt32LE(arr[i], i << 2, true) } + return buf +} - /** - * Creates a function that invokes two functions and merges their return values. - * - * @param {function} one Function to invoke first. - * @param {function} two Function to invoke second. - * @return {function} Function that invokes the two argument functions. - * @private - */ - function createMergedResultFunction(one, two) { - return function mergedResult() { - var a = one.apply(this, arguments); - var b = two.apply(this, arguments); - if (a == null) { - return b; - } else if (b == null) { - return a; - } - var c = {}; - mergeIntoWithNoDuplicateKeys(c, a); - mergeIntoWithNoDuplicateKeys(c, b); - return c; - }; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 366 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var Transform = __webpack_require__(98).Transform +var inherits = __webpack_require__(4) + +function HashBase (blockSize) { + Transform.call(this) + + this._block = new Buffer(blockSize) + this._blockSize = blockSize + this._blockOffset = 0 + this._length = [0, 0, 0, 0] + + this._finalized = false +} + +inherits(HashBase, Transform) + +HashBase.prototype._transform = function (chunk, encoding, callback) { + var error = null + try { + if (encoding !== 'buffer') chunk = new Buffer(chunk, encoding) + this.update(chunk) + } catch (err) { + error = err } - /** - * Creates a function that invokes two functions and ignores their return vales. - * - * @param {function} one Function to invoke first. - * @param {function} two Function to invoke second. - * @return {function} Function that invokes the two argument functions. - * @private - */ - function createChainedFunction(one, two) { - return function chainedFunction() { - one.apply(this, arguments); - two.apply(this, arguments); - }; + callback(error) +} + +HashBase.prototype._flush = function (callback) { + var error = null + try { + this.push(this._digest()) + } catch (err) { + error = err } - /** - * Binds a method to the component. - * - * @param {object} component Component whose method is going to be bound. - * @param {function} method Method to be bound. - * @return {function} The bound method. - */ - function bindAutoBindMethod(component, method) { - var boundMethod = method.bind(component); - if (process.env.NODE_ENV !== 'production') { - boundMethod.__reactBoundContext = component; - boundMethod.__reactBoundMethod = method; - boundMethod.__reactBoundArguments = null; - var componentName = component.constructor.displayName; - var _bind = boundMethod.bind; - boundMethod.bind = function(newThis) { - for ( - var _len = arguments.length, - args = Array(_len > 1 ? _len - 1 : 0), - _key = 1; - _key < _len; - _key++ - ) { - args[_key - 1] = arguments[_key]; - } + callback(error) +} - // User is trying to bind() an autobound method; we effectively will - // ignore the value of "this" that the user is trying to use, so - // let's warn. - if (newThis !== component && newThis !== null) { - if (process.env.NODE_ENV !== 'production') { - warning( - false, - 'bind(): React component methods may only be bound to the ' + - 'component instance. See %s', - componentName - ); - } - } else if (!args.length) { - if (process.env.NODE_ENV !== 'production') { - warning( - false, - 'bind(): You are binding a component method to the component. ' + - 'React does this for you automatically in a high-performance ' + - 'way, so you can safely remove this call. See %s', - componentName - ); - } - return boundMethod; - } - var reboundMethod = _bind.apply(boundMethod, arguments); - reboundMethod.__reactBoundContext = component; - reboundMethod.__reactBoundMethod = method; - reboundMethod.__reactBoundArguments = args; - return reboundMethod; - }; - } - return boundMethod; +HashBase.prototype.update = function (data, encoding) { + if (!Buffer.isBuffer(data) && typeof data !== 'string') throw new TypeError('Data must be a string or a buffer') + if (this._finalized) throw new Error('Digest already called') + if (!Buffer.isBuffer(data)) data = new Buffer(data, encoding || 'binary') + + // consume data + var block = this._block + var offset = 0 + while (this._blockOffset + data.length - offset >= this._blockSize) { + for (var i = this._blockOffset; i < this._blockSize;) block[i++] = data[offset++] + this._update() + this._blockOffset = 0 } + while (offset < data.length) block[this._blockOffset++] = data[offset++] - /** - * Binds all auto-bound methods in a component. - * - * @param {object} component Component whose method is going to be bound. - */ - function bindAutoBindMethods(component) { - var pairs = component.__reactAutoBindPairs; - for (var i = 0; i < pairs.length; i += 2) { - var autoBindKey = pairs[i]; - var method = pairs[i + 1]; - component[autoBindKey] = bindAutoBindMethod(component, method); - } + // update length + for (var j = 0, carry = data.length * 8; carry > 0; ++j) { + this._length[j] += carry + carry = (this._length[j] / 0x0100000000) | 0 + if (carry > 0) this._length[j] -= 0x0100000000 * carry } - var IsMountedPreMixin = { - componentDidMount: function() { - this.__isMounted = true; - } - }; + return this +} - var IsMountedPostMixin = { - componentWillUnmount: function() { - this.__isMounted = false; - } - }; +HashBase.prototype._update = function (data) { + throw new Error('_update is not implemented') +} - /** - * Add more to the ReactClass base class. These are all legacy features and - * therefore not already part of the modern ReactComponent. - */ - var ReactClassMixin = { - /** - * TODO: This will be deprecated because state should always keep a consistent - * type signature and the only use case for this, is to avoid that. - */ - replaceState: function(newState, callback) { - this.updater.enqueueReplaceState(this, newState, callback); - }, +HashBase.prototype.digest = function (encoding) { + if (this._finalized) throw new Error('Digest already called') + this._finalized = true - /** - * Checks whether or not this composite component is mounted. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function() { - if (process.env.NODE_ENV !== 'production') { - warning( - this.__didWarnIsMounted, - '%s: isMounted is deprecated. Instead, make sure to clean up ' + - 'subscriptions and pending requests in componentWillUnmount to ' + - 'prevent memory leaks.', - (this.constructor && this.constructor.displayName) || - this.name || - 'Component' - ); - this.__didWarnIsMounted = true; - } - return !!this.__isMounted; - } - }; + var digest = this._digest() + if (encoding !== undefined) digest = digest.toString(encoding) + return digest +} - var ReactClassComponent = function() {}; - _assign( - ReactClassComponent.prototype, - ReactComponent.prototype, - ReactClassMixin - ); +HashBase.prototype._digest = function () { + throw new Error('_digest is not implemented') +} - /** - * Creates a composite component class given a class specification. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createclass - * - * @param {object} spec Class specification (which must define `render`). - * @return {function} Component constructor function. - * @public - */ - function createClass(spec) { - // To keep our warnings more understandable, we'll use a little hack here to - // ensure that Constructor.name !== 'Constructor'. This makes sure we don't - // unnecessarily identify a class without displayName as 'Constructor'. - var Constructor = identity(function(props, context, updater) { - // This constructor gets overridden by mocks. The argument is used - // by mocks to assert on what gets mounted. +module.exports = HashBase - if (process.env.NODE_ENV !== 'production') { - warning( - this instanceof Constructor, - 'Something is calling a React component directly. Use a factory or ' + - 'JSX instead. See: https://fb.me/react-legacyfactory' - ); - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - // Wire up auto-binding - if (this.__reactAutoBindPairs.length) { - bindAutoBindMethods(this); - } +/***/ }), +/* 367 */ +/***/ (function(module, exports) { - this.props = props; - this.context = context; - this.refs = emptyObject; - this.updater = updater || ReactNoopUpdateQueue; +/* (ignored) */ - this.state = null; +/***/ }), +/* 368 */ +/***/ (function(module, exports, __webpack_require__) { - // ReactClasses doesn't have constructors. Instead, they use the - // getInitialState and componentWillMount methods for initialization. +"use strict"; + + +/*<replacement>*/ + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +var Buffer = __webpack_require__(7).Buffer; +/*</replacement>*/ + +function copyBuffer(src, target, offset) { + src.copy(target, offset); +} + +module.exports = function () { + function BufferList() { + _classCallCheck(this, BufferList); + + this.head = null; + this.tail = null; + this.length = 0; + } + + BufferList.prototype.push = function push(v) { + var entry = { data: v, next: null }; + if (this.length > 0) this.tail.next = entry;else this.head = entry; + this.tail = entry; + ++this.length; + }; + + BufferList.prototype.unshift = function unshift(v) { + var entry = { data: v, next: this.head }; + if (this.length === 0) this.tail = entry; + this.head = entry; + ++this.length; + }; + + BufferList.prototype.shift = function shift() { + if (this.length === 0) return; + var ret = this.head.data; + if (this.length === 1) this.head = this.tail = null;else this.head = this.head.next; + --this.length; + return ret; + }; + + BufferList.prototype.clear = function clear() { + this.head = this.tail = null; + this.length = 0; + }; + + BufferList.prototype.join = function join(s) { + if (this.length === 0) return ''; + var p = this.head; + var ret = '' + p.data; + while (p = p.next) { + ret += s + p.data; + }return ret; + }; - var initialState = this.getInitialState ? this.getInitialState() : null; - if (process.env.NODE_ENV !== 'production') { - // We allow auto-mocks to proceed as if they're returning null. - if ( - initialState === undefined && - this.getInitialState._isMockFunction - ) { - // This is probably bad practice. Consider warning here and - // deprecating this convenience. - initialState = null; - } - } - _invariant( - typeof initialState === 'object' && !Array.isArray(initialState), - '%s.getInitialState(): must return an object or null', - Constructor.displayName || 'ReactCompositeComponent' - ); + BufferList.prototype.concat = function concat(n) { + if (this.length === 0) return Buffer.alloc(0); + if (this.length === 1) return this.head.data; + var ret = Buffer.allocUnsafe(n >>> 0); + var p = this.head; + var i = 0; + while (p) { + copyBuffer(p.data, ret, i); + i += p.data.length; + p = p.next; + } + return ret; + }; - this.state = initialState; - }); - Constructor.prototype = new ReactClassComponent(); - Constructor.prototype.constructor = Constructor; - Constructor.prototype.__reactAutoBindPairs = []; + return BufferList; +}(); - injectedMixins.forEach(mixSpecIntoComponent.bind(null, Constructor)); +/***/ }), +/* 369 */ +/***/ (function(module, exports, __webpack_require__) { - mixSpecIntoComponent(Constructor, IsMountedPreMixin); - mixSpecIntoComponent(Constructor, spec); - mixSpecIntoComponent(Constructor, IsMountedPostMixin); +/* WEBPACK VAR INJECTION */(function(global, process) {(function (global, undefined) { + "use strict"; - // Initialize the defaultProps property after all mixins have been merged. - if (Constructor.getDefaultProps) { - Constructor.defaultProps = Constructor.getDefaultProps(); + if (global.setImmediate) { + return; } - if (process.env.NODE_ENV !== 'production') { - // This is a tag to indicate that the use of these method names is ok, - // since it's used with createClass. If it's not, then it's likely a - // mistake so we'll warn you to use the static property, property - // initializer or constructor respectively. - if (Constructor.getDefaultProps) { - Constructor.getDefaultProps.isReactClassApproved = {}; + var nextHandle = 1; // Spec says greater than zero + var tasksByHandle = {}; + var currentlyRunningATask = false; + var doc = global.document; + var registerImmediate; + + function setImmediate(callback) { + // Callback can either be a function or a string + if (typeof callback !== "function") { + callback = new Function("" + callback); } - if (Constructor.prototype.getInitialState) { - Constructor.prototype.getInitialState.isReactClassApproved = {}; + // Copy function arguments + var args = new Array(arguments.length - 1); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i + 1]; } + // Store and register the task + var task = { callback: callback, args: args }; + tasksByHandle[nextHandle] = task; + registerImmediate(nextHandle); + return nextHandle++; } - _invariant( - Constructor.prototype.render, - 'createClass(...): Class specification must implement a `render` method.' - ); + function clearImmediate(handle) { + delete tasksByHandle[handle]; + } - if (process.env.NODE_ENV !== 'production') { - warning( - !Constructor.prototype.componentShouldUpdate, - '%s has a method called ' + - 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + - 'The name is phrased as a question because the function is ' + - 'expected to return a value.', - spec.displayName || 'A component' - ); - warning( - !Constructor.prototype.componentWillRecieveProps, - '%s has a method called ' + - 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', - spec.displayName || 'A component' - ); + function run(task) { + var callback = task.callback; + var args = task.args; + switch (args.length) { + case 0: + callback(); + break; + case 1: + callback(args[0]); + break; + case 2: + callback(args[0], args[1]); + break; + case 3: + callback(args[0], args[1], args[2]); + break; + default: + callback.apply(undefined, args); + break; + } } - // Reduce time spent doing lookups by setting these on the prototype. - for (var methodName in ReactClassInterface) { - if (!Constructor.prototype[methodName]) { - Constructor.prototype[methodName] = null; - } + function runIfPresent(handle) { + // From the spec: "Wait until any invocations of this algorithm started before this one have completed." + // So if we're currently running a task, we'll need to delay this invocation. + if (currentlyRunningATask) { + // Delay by doing a setTimeout. setImmediate was tried instead, but in Firefox 7 it generated a + // "too much recursion" error. + setTimeout(runIfPresent, 0, handle); + } else { + var task = tasksByHandle[handle]; + if (task) { + currentlyRunningATask = true; + try { + run(task); + } finally { + clearImmediate(handle); + currentlyRunningATask = false; + } + } + } } - return Constructor; - } + function installNextTickImplementation() { + registerImmediate = function(handle) { + process.nextTick(function () { runIfPresent(handle); }); + }; + } - return createClass; -} + function canUsePostMessage() { + // The test against `importScripts` prevents this implementation from being installed inside a web worker, + // where `global.postMessage` means something completely different and can't be used for this purpose. + if (global.postMessage && !global.importScripts) { + var postMessageIsAsynchronous = true; + var oldOnMessage = global.onmessage; + global.onmessage = function() { + postMessageIsAsynchronous = false; + }; + global.postMessage("", "*"); + global.onmessage = oldOnMessage; + return postMessageIsAsynchronous; + } + } -module.exports = factory; + function installPostMessageImplementation() { + // Installs an event handler on `global` for the `message` event: see + // * https://developer.mozilla.org/en/DOM/window.postMessage + // * http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#crossDocumentMessages -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var messagePrefix = "setImmediate$" + Math.random() + "$"; + var onGlobalMessage = function(event) { + if (event.source === global && + typeof event.data === "string" && + event.data.indexOf(messagePrefix) === 0) { + runIfPresent(+event.data.slice(messagePrefix.length)); + } + }; -/***/ }), -/* 114 */, -/* 115 */, -/* 116 */, -/* 117 */ -/***/ (function(module, exports, __webpack_require__) { + if (global.addEventListener) { + global.addEventListener("message", onGlobalMessage, false); + } else { + global.attachEvent("onmessage", onGlobalMessage); + } -// style-loader: Adds some css to the DOM by adding a <style> tag + registerImmediate = function(handle) { + global.postMessage(messagePrefix + handle, "*"); + }; + } -// load the styles -var content = __webpack_require__(118); -if(typeof content === 'string') content = [[module.i, content, '']]; -// Prepare cssTransformation -var transform; + function installMessageChannelImplementation() { + var channel = new MessageChannel(); + channel.port1.onmessage = function(event) { + var handle = event.data; + runIfPresent(handle); + }; -var options = {} -options.transform = transform -// add the styles to the DOM -var update = __webpack_require__(73)(content, options); -if(content.locals) module.exports = content.locals; -// Hot Module Replacement -if(false) { - // When the styles change, update the <style> tags - if(!content.locals) { - module.hot.accept("!!../../../css-loader/index.js!./bootstrap.css", function() { - var newContent = require("!!../../../css-loader/index.js!./bootstrap.css"); - if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; - update(newContent); - }); - } - // When the module is disposed, remove the <style> tags - module.hot.dispose(function() { update(); }); -} + registerImmediate = function(handle) { + channel.port2.postMessage(handle); + }; + } -/***/ }), -/* 118 */ -/***/ (function(module, exports, __webpack_require__) { + function installReadyStateChangeImplementation() { + var html = doc.documentElement; + registerImmediate = function(handle) { + // Create a <script> element; its readystatechange event will be fired asynchronously once it is inserted + // into the document. Do so, thus queuing up the task. Remember to clean up once it's been called. + var script = doc.createElement("script"); + script.onreadystatechange = function () { + runIfPresent(handle); + script.onreadystatechange = null; + html.removeChild(script); + script = null; + }; + html.appendChild(script); + }; + } -exports = module.exports = __webpack_require__(72)(undefined); -// imports + function installSetTimeoutImplementation() { + registerImmediate = function(handle) { + setTimeout(runIfPresent, 0, handle); + }; + } + // If supported, we should attach to the prototype of global, since that is where setTimeout et al. live. + var attachTo = Object.getPrototypeOf && Object.getPrototypeOf(global); + attachTo = attachTo && attachTo.setTimeout ? attachTo : global; -// module -exports.push([module.i, "/*!\n * Bootstrap v4.0.0-alpha.6 (https://getbootstrap.com)\n * Copyright 2011-2017 The Bootstrap Authors\n * Copyright 2011-2017 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n */\n/*! normalize.css v5.0.0 | MIT License | github.com/necolas/normalize.css */\nhtml {\n font-family: sans-serif;\n line-height: 1.15;\n -ms-text-size-adjust: 100%;\n -webkit-text-size-adjust: 100%;\n}\n\nbody {\n margin: 0;\n}\n\narticle,\naside,\nfooter,\nheader,\nnav,\nsection {\n display: block;\n}\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\nfigcaption,\nfigure,\nmain {\n display: block;\n}\n\nfigure {\n margin: 1em 40px;\n}\n\nhr {\n -webkit-box-sizing: content-box;\n box-sizing: content-box;\n height: 0;\n overflow: visible;\n}\n\npre {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\na {\n background-color: transparent;\n -webkit-text-decoration-skip: objects;\n}\n\na:active,\na:hover {\n outline-width: 0;\n}\n\nabbr[title] {\n border-bottom: none;\n text-decoration: underline;\n text-decoration: underline dotted;\n}\n\nb,\nstrong {\n font-weight: inherit;\n}\n\nb,\nstrong {\n font-weight: bolder;\n}\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\ndfn {\n font-style: italic;\n}\n\nmark {\n background-color: #ff0;\n color: #000;\n}\n\nsmall {\n font-size: 80%;\n}\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\naudio,\nvideo {\n display: inline-block;\n}\n\naudio:not([controls]) {\n display: none;\n height: 0;\n}\n\nimg {\n border-style: none;\n}\n\nsvg:not(:root) {\n overflow: hidden;\n}\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: sans-serif;\n font-size: 100%;\n line-height: 1.15;\n margin: 0;\n}\n\nbutton,\ninput {\n overflow: visible;\n}\n\nbutton,\nselect {\n text-transform: none;\n}\n\nbutton,\nhtml [type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\nfieldset {\n border: 1px solid #c0c0c0;\n margin: 0 2px;\n padding: 0.35em 0.625em 0.75em;\n}\n\nlegend {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: inherit;\n display: table;\n max-width: 100%;\n padding: 0;\n white-space: normal;\n}\n\nprogress {\n display: inline-block;\n vertical-align: baseline;\n}\n\ntextarea {\n overflow: auto;\n}\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n padding: 0;\n}\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n[type=\"search\"] {\n -webkit-appearance: textfield;\n outline-offset: -2px;\n}\n\n[type=\"search\"]::-webkit-search-cancel-button,\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n::-webkit-file-upload-button {\n -webkit-appearance: button;\n font: inherit;\n}\n\ndetails,\nmenu {\n display: block;\n}\n\nsummary {\n display: list-item;\n}\n\ncanvas {\n display: inline-block;\n}\n\ntemplate {\n display: none;\n}\n\n[hidden] {\n display: none;\n}\n\n@media print {\n *,\n *::before,\n *::after,\n p::first-letter,\n div::first-letter,\n blockquote::first-letter,\n li::first-letter,\n p::first-line,\n div::first-line,\n blockquote::first-line,\n li::first-line {\n text-shadow: none !important;\n -webkit-box-shadow: none !important;\n box-shadow: none !important;\n }\n a,\n a:visited {\n text-decoration: underline;\n }\n abbr[title]::after {\n content: \" (\" attr(title) \")\";\n }\n pre {\n white-space: pre-wrap !important;\n }\n pre,\n blockquote {\n border: 1px solid #999;\n page-break-inside: avoid;\n }\n thead {\n display: table-header-group;\n }\n tr,\n img {\n page-break-inside: avoid;\n }\n p,\n h2,\n h3 {\n orphans: 3;\n widows: 3;\n }\n h2,\n h3 {\n page-break-after: avoid;\n }\n .navbar {\n display: none;\n }\n .badge {\n border: 1px solid #000;\n }\n .table {\n border-collapse: collapse !important;\n }\n .table td,\n .table th {\n background-color: #fff !important;\n }\n .table-bordered th,\n .table-bordered td {\n border: 1px solid #ddd !important;\n }\n}\n\nhtml {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n}\n\n*,\n*::before,\n*::after {\n -webkit-box-sizing: inherit;\n box-sizing: inherit;\n}\n\n@-ms-viewport {\n width: device-width;\n}\n\nhtml {\n -ms-overflow-style: scrollbar;\n -webkit-tap-highlight-color: transparent;\n}\n\nbody {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.5;\n color: #292b2c;\n background-color: #fff;\n}\n\n[tabindex=\"-1\"]:focus {\n outline: none !important;\n}\n\nh1, h2, h3, h4, h5, h6 {\n margin-top: 0;\n margin-bottom: .5rem;\n}\n\np {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nabbr[title],\nabbr[data-original-title] {\n cursor: help;\n}\n\naddress {\n margin-bottom: 1rem;\n font-style: normal;\n line-height: inherit;\n}\n\nol,\nul,\ndl {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nol ol,\nul ul,\nol ul,\nul ol {\n margin-bottom: 0;\n}\n\ndt {\n font-weight: bold;\n}\n\ndd {\n margin-bottom: .5rem;\n margin-left: 0;\n}\n\nblockquote {\n margin: 0 0 1rem;\n}\n\na {\n color: #0275d8;\n text-decoration: none;\n}\n\na:focus, a:hover {\n color: #014c8c;\n text-decoration: underline;\n}\n\na:not([href]):not([tabindex]) {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus, a:not([href]):not([tabindex]):hover {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus {\n outline: 0;\n}\n\npre {\n margin-top: 0;\n margin-bottom: 1rem;\n overflow: auto;\n}\n\nfigure {\n margin: 0 0 1rem;\n}\n\nimg {\n vertical-align: middle;\n}\n\n[role=\"button\"] {\n cursor: pointer;\n}\n\na,\narea,\nbutton,\n[role=\"button\"],\ninput,\nlabel,\nselect,\nsummary,\ntextarea {\n -ms-touch-action: manipulation;\n touch-action: manipulation;\n}\n\ntable {\n border-collapse: collapse;\n background-color: transparent;\n}\n\ncaption {\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n color: #636c72;\n text-align: left;\n caption-side: bottom;\n}\n\nth {\n text-align: left;\n}\n\nlabel {\n display: inline-block;\n margin-bottom: .5rem;\n}\n\nbutton:focus {\n outline: 1px dotted;\n outline: 5px auto -webkit-focus-ring-color;\n}\n\ninput,\nbutton,\nselect,\ntextarea {\n line-height: inherit;\n}\n\ninput[type=\"radio\"]:disabled,\ninput[type=\"checkbox\"]:disabled {\n cursor: not-allowed;\n}\n\ninput[type=\"date\"],\ninput[type=\"time\"],\ninput[type=\"datetime-local\"],\ninput[type=\"month\"] {\n -webkit-appearance: listbox;\n}\n\ntextarea {\n resize: vertical;\n}\n\nfieldset {\n min-width: 0;\n padding: 0;\n margin: 0;\n border: 0;\n}\n\nlegend {\n display: block;\n width: 100%;\n padding: 0;\n margin-bottom: .5rem;\n font-size: 1.5rem;\n line-height: inherit;\n}\n\ninput[type=\"search\"] {\n -webkit-appearance: none;\n}\n\noutput {\n display: inline-block;\n}\n\n[hidden] {\n display: none !important;\n}\n\nh1, h2, h3, h4, h5, h6,\n.h1, .h2, .h3, .h4, .h5, .h6 {\n margin-bottom: 0.5rem;\n font-family: inherit;\n font-weight: 500;\n line-height: 1.1;\n color: inherit;\n}\n\nh1, .h1 {\n font-size: 2.5rem;\n}\n\nh2, .h2 {\n font-size: 2rem;\n}\n\nh3, .h3 {\n font-size: 1.75rem;\n}\n\nh4, .h4 {\n font-size: 1.5rem;\n}\n\nh5, .h5 {\n font-size: 1.25rem;\n}\n\nh6, .h6 {\n font-size: 1rem;\n}\n\n.lead {\n font-size: 1.25rem;\n font-weight: 300;\n}\n\n.display-1 {\n font-size: 6rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-2 {\n font-size: 5.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-3 {\n font-size: 4.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-4 {\n font-size: 3.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\nhr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n border: 0;\n border-top: 1px solid rgba(0, 0, 0, 0.1);\n}\n\nsmall,\n.small {\n font-size: 80%;\n font-weight: normal;\n}\n\nmark,\n.mark {\n padding: 0.2em;\n background-color: #fcf8e3;\n}\n\n.list-unstyled {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline-item {\n display: inline-block;\n}\n\n.list-inline-item:not(:last-child) {\n margin-right: 5px;\n}\n\n.initialism {\n font-size: 90%;\n text-transform: uppercase;\n}\n\n.blockquote {\n padding: 0.5rem 1rem;\n margin-bottom: 1rem;\n font-size: 1.25rem;\n border-left: 0.25rem solid #eceeef;\n}\n\n.blockquote-footer {\n display: block;\n font-size: 80%;\n color: #636c72;\n}\n\n.blockquote-footer::before {\n content: \"\\2014 \\A0\";\n}\n\n.blockquote-reverse {\n padding-right: 1rem;\n padding-left: 0;\n text-align: right;\n border-right: 0.25rem solid #eceeef;\n border-left: 0;\n}\n\n.blockquote-reverse .blockquote-footer::before {\n content: \"\";\n}\n\n.blockquote-reverse .blockquote-footer::after {\n content: \"\\A0 \\2014\";\n}\n\n.img-fluid {\n max-width: 100%;\n height: auto;\n}\n\n.img-thumbnail {\n padding: 0.25rem;\n background-color: #fff;\n border: 1px solid #ddd;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n max-width: 100%;\n height: auto;\n}\n\n.figure {\n display: inline-block;\n}\n\n.figure-img {\n margin-bottom: 0.5rem;\n line-height: 1;\n}\n\n.figure-caption {\n font-size: 90%;\n color: #636c72;\n}\n\ncode,\nkbd,\npre,\nsamp {\n font-family: Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;\n}\n\ncode {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #bd4147;\n background-color: #f7f7f9;\n border-radius: 0.25rem;\n}\n\na > code {\n padding: 0;\n color: inherit;\n background-color: inherit;\n}\n\nkbd {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #fff;\n background-color: #292b2c;\n border-radius: 0.2rem;\n}\n\nkbd kbd {\n padding: 0;\n font-size: 100%;\n font-weight: bold;\n}\n\npre {\n display: block;\n margin-top: 0;\n margin-bottom: 1rem;\n font-size: 90%;\n color: #292b2c;\n}\n\npre code {\n padding: 0;\n font-size: inherit;\n color: inherit;\n background-color: transparent;\n border-radius: 0;\n}\n\n.pre-scrollable {\n max-height: 340px;\n overflow-y: scroll;\n}\n\n.container {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .container {\n width: 540px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n width: 720px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n width: 960px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n width: 1140px;\n max-width: 100%;\n }\n}\n\n.container-fluid {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.row {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: wrap;\n -ms-flex-wrap: wrap;\n flex-wrap: wrap;\n margin-right: -15px;\n margin-left: -15px;\n}\n\n@media (min-width: 576px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 768px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 992px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 1200px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n.no-gutters {\n margin-right: 0;\n margin-left: 0;\n}\n\n.no-gutters > .col,\n.no-gutters > [class*=\"col-\"] {\n padding-right: 0;\n padding-left: 0;\n}\n\n.col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n position: relative;\n width: 100%;\n min-height: 1px;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.col {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n}\n\n.col-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n}\n\n.col-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n}\n\n.col-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n}\n\n.col-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n}\n\n.col-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n}\n\n.col-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n}\n\n.col-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n}\n\n.col-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n}\n\n.col-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n}\n\n.col-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n}\n\n.col-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n}\n\n.col-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n}\n\n.col-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n}\n\n.pull-0 {\n right: auto;\n}\n\n.pull-1 {\n right: 8.333333%;\n}\n\n.pull-2 {\n right: 16.666667%;\n}\n\n.pull-3 {\n right: 25%;\n}\n\n.pull-4 {\n right: 33.333333%;\n}\n\n.pull-5 {\n right: 41.666667%;\n}\n\n.pull-6 {\n right: 50%;\n}\n\n.pull-7 {\n right: 58.333333%;\n}\n\n.pull-8 {\n right: 66.666667%;\n}\n\n.pull-9 {\n right: 75%;\n}\n\n.pull-10 {\n right: 83.333333%;\n}\n\n.pull-11 {\n right: 91.666667%;\n}\n\n.pull-12 {\n right: 100%;\n}\n\n.push-0 {\n left: auto;\n}\n\n.push-1 {\n left: 8.333333%;\n}\n\n.push-2 {\n left: 16.666667%;\n}\n\n.push-3 {\n left: 25%;\n}\n\n.push-4 {\n left: 33.333333%;\n}\n\n.push-5 {\n left: 41.666667%;\n}\n\n.push-6 {\n left: 50%;\n}\n\n.push-7 {\n left: 58.333333%;\n}\n\n.push-8 {\n left: 66.666667%;\n}\n\n.push-9 {\n left: 75%;\n}\n\n.push-10 {\n left: 83.333333%;\n}\n\n.push-11 {\n left: 91.666667%;\n}\n\n.push-12 {\n left: 100%;\n}\n\n.offset-1 {\n margin-left: 8.333333%;\n}\n\n.offset-2 {\n margin-left: 16.666667%;\n}\n\n.offset-3 {\n margin-left: 25%;\n}\n\n.offset-4 {\n margin-left: 33.333333%;\n}\n\n.offset-5 {\n margin-left: 41.666667%;\n}\n\n.offset-6 {\n margin-left: 50%;\n}\n\n.offset-7 {\n margin-left: 58.333333%;\n}\n\n.offset-8 {\n margin-left: 66.666667%;\n}\n\n.offset-9 {\n margin-left: 75%;\n}\n\n.offset-10 {\n margin-left: 83.333333%;\n}\n\n.offset-11 {\n margin-left: 91.666667%;\n}\n\n@media (min-width: 576px) {\n .col-sm {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-sm-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-sm-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-sm-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-sm-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-sm-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-sm-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-sm-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-sm-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-sm-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-sm-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-sm-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-sm-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-sm-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-sm-0 {\n right: auto;\n }\n .pull-sm-1 {\n right: 8.333333%;\n }\n .pull-sm-2 {\n right: 16.666667%;\n }\n .pull-sm-3 {\n right: 25%;\n }\n .pull-sm-4 {\n right: 33.333333%;\n }\n .pull-sm-5 {\n right: 41.666667%;\n }\n .pull-sm-6 {\n right: 50%;\n }\n .pull-sm-7 {\n right: 58.333333%;\n }\n .pull-sm-8 {\n right: 66.666667%;\n }\n .pull-sm-9 {\n right: 75%;\n }\n .pull-sm-10 {\n right: 83.333333%;\n }\n .pull-sm-11 {\n right: 91.666667%;\n }\n .pull-sm-12 {\n right: 100%;\n }\n .push-sm-0 {\n left: auto;\n }\n .push-sm-1 {\n left: 8.333333%;\n }\n .push-sm-2 {\n left: 16.666667%;\n }\n .push-sm-3 {\n left: 25%;\n }\n .push-sm-4 {\n left: 33.333333%;\n }\n .push-sm-5 {\n left: 41.666667%;\n }\n .push-sm-6 {\n left: 50%;\n }\n .push-sm-7 {\n left: 58.333333%;\n }\n .push-sm-8 {\n left: 66.666667%;\n }\n .push-sm-9 {\n left: 75%;\n }\n .push-sm-10 {\n left: 83.333333%;\n }\n .push-sm-11 {\n left: 91.666667%;\n }\n .push-sm-12 {\n left: 100%;\n }\n .offset-sm-0 {\n margin-left: 0%;\n }\n .offset-sm-1 {\n margin-left: 8.333333%;\n }\n .offset-sm-2 {\n margin-left: 16.666667%;\n }\n .offset-sm-3 {\n margin-left: 25%;\n }\n .offset-sm-4 {\n margin-left: 33.333333%;\n }\n .offset-sm-5 {\n margin-left: 41.666667%;\n }\n .offset-sm-6 {\n margin-left: 50%;\n }\n .offset-sm-7 {\n margin-left: 58.333333%;\n }\n .offset-sm-8 {\n margin-left: 66.666667%;\n }\n .offset-sm-9 {\n margin-left: 75%;\n }\n .offset-sm-10 {\n margin-left: 83.333333%;\n }\n .offset-sm-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 768px) {\n .col-md {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-md-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-md-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-md-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-md-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-md-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-md-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-md-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-md-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-md-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-md-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-md-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-md-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-md-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-md-0 {\n right: auto;\n }\n .pull-md-1 {\n right: 8.333333%;\n }\n .pull-md-2 {\n right: 16.666667%;\n }\n .pull-md-3 {\n right: 25%;\n }\n .pull-md-4 {\n right: 33.333333%;\n }\n .pull-md-5 {\n right: 41.666667%;\n }\n .pull-md-6 {\n right: 50%;\n }\n .pull-md-7 {\n right: 58.333333%;\n }\n .pull-md-8 {\n right: 66.666667%;\n }\n .pull-md-9 {\n right: 75%;\n }\n .pull-md-10 {\n right: 83.333333%;\n }\n .pull-md-11 {\n right: 91.666667%;\n }\n .pull-md-12 {\n right: 100%;\n }\n .push-md-0 {\n left: auto;\n }\n .push-md-1 {\n left: 8.333333%;\n }\n .push-md-2 {\n left: 16.666667%;\n }\n .push-md-3 {\n left: 25%;\n }\n .push-md-4 {\n left: 33.333333%;\n }\n .push-md-5 {\n left: 41.666667%;\n }\n .push-md-6 {\n left: 50%;\n }\n .push-md-7 {\n left: 58.333333%;\n }\n .push-md-8 {\n left: 66.666667%;\n }\n .push-md-9 {\n left: 75%;\n }\n .push-md-10 {\n left: 83.333333%;\n }\n .push-md-11 {\n left: 91.666667%;\n }\n .push-md-12 {\n left: 100%;\n }\n .offset-md-0 {\n margin-left: 0%;\n }\n .offset-md-1 {\n margin-left: 8.333333%;\n }\n .offset-md-2 {\n margin-left: 16.666667%;\n }\n .offset-md-3 {\n margin-left: 25%;\n }\n .offset-md-4 {\n margin-left: 33.333333%;\n }\n .offset-md-5 {\n margin-left: 41.666667%;\n }\n .offset-md-6 {\n margin-left: 50%;\n }\n .offset-md-7 {\n margin-left: 58.333333%;\n }\n .offset-md-8 {\n margin-left: 66.666667%;\n }\n .offset-md-9 {\n margin-left: 75%;\n }\n .offset-md-10 {\n margin-left: 83.333333%;\n }\n .offset-md-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 992px) {\n .col-lg {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-lg-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-lg-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-lg-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-lg-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-lg-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-lg-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-lg-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-lg-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-lg-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-lg-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-lg-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-lg-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-lg-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-lg-0 {\n right: auto;\n }\n .pull-lg-1 {\n right: 8.333333%;\n }\n .pull-lg-2 {\n right: 16.666667%;\n }\n .pull-lg-3 {\n right: 25%;\n }\n .pull-lg-4 {\n right: 33.333333%;\n }\n .pull-lg-5 {\n right: 41.666667%;\n }\n .pull-lg-6 {\n right: 50%;\n }\n .pull-lg-7 {\n right: 58.333333%;\n }\n .pull-lg-8 {\n right: 66.666667%;\n }\n .pull-lg-9 {\n right: 75%;\n }\n .pull-lg-10 {\n right: 83.333333%;\n }\n .pull-lg-11 {\n right: 91.666667%;\n }\n .pull-lg-12 {\n right: 100%;\n }\n .push-lg-0 {\n left: auto;\n }\n .push-lg-1 {\n left: 8.333333%;\n }\n .push-lg-2 {\n left: 16.666667%;\n }\n .push-lg-3 {\n left: 25%;\n }\n .push-lg-4 {\n left: 33.333333%;\n }\n .push-lg-5 {\n left: 41.666667%;\n }\n .push-lg-6 {\n left: 50%;\n }\n .push-lg-7 {\n left: 58.333333%;\n }\n .push-lg-8 {\n left: 66.666667%;\n }\n .push-lg-9 {\n left: 75%;\n }\n .push-lg-10 {\n left: 83.333333%;\n }\n .push-lg-11 {\n left: 91.666667%;\n }\n .push-lg-12 {\n left: 100%;\n }\n .offset-lg-0 {\n margin-left: 0%;\n }\n .offset-lg-1 {\n margin-left: 8.333333%;\n }\n .offset-lg-2 {\n margin-left: 16.666667%;\n }\n .offset-lg-3 {\n margin-left: 25%;\n }\n .offset-lg-4 {\n margin-left: 33.333333%;\n }\n .offset-lg-5 {\n margin-left: 41.666667%;\n }\n .offset-lg-6 {\n margin-left: 50%;\n }\n .offset-lg-7 {\n margin-left: 58.333333%;\n }\n .offset-lg-8 {\n margin-left: 66.666667%;\n }\n .offset-lg-9 {\n margin-left: 75%;\n }\n .offset-lg-10 {\n margin-left: 83.333333%;\n }\n .offset-lg-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 1200px) {\n .col-xl {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-xl-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-xl-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-xl-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-xl-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-xl-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-xl-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-xl-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-xl-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-xl-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-xl-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-xl-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-xl-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-xl-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-xl-0 {\n right: auto;\n }\n .pull-xl-1 {\n right: 8.333333%;\n }\n .pull-xl-2 {\n right: 16.666667%;\n }\n .pull-xl-3 {\n right: 25%;\n }\n .pull-xl-4 {\n right: 33.333333%;\n }\n .pull-xl-5 {\n right: 41.666667%;\n }\n .pull-xl-6 {\n right: 50%;\n }\n .pull-xl-7 {\n right: 58.333333%;\n }\n .pull-xl-8 {\n right: 66.666667%;\n }\n .pull-xl-9 {\n right: 75%;\n }\n .pull-xl-10 {\n right: 83.333333%;\n }\n .pull-xl-11 {\n right: 91.666667%;\n }\n .pull-xl-12 {\n right: 100%;\n }\n .push-xl-0 {\n left: auto;\n }\n .push-xl-1 {\n left: 8.333333%;\n }\n .push-xl-2 {\n left: 16.666667%;\n }\n .push-xl-3 {\n left: 25%;\n }\n .push-xl-4 {\n left: 33.333333%;\n }\n .push-xl-5 {\n left: 41.666667%;\n }\n .push-xl-6 {\n left: 50%;\n }\n .push-xl-7 {\n left: 58.333333%;\n }\n .push-xl-8 {\n left: 66.666667%;\n }\n .push-xl-9 {\n left: 75%;\n }\n .push-xl-10 {\n left: 83.333333%;\n }\n .push-xl-11 {\n left: 91.666667%;\n }\n .push-xl-12 {\n left: 100%;\n }\n .offset-xl-0 {\n margin-left: 0%;\n }\n .offset-xl-1 {\n margin-left: 8.333333%;\n }\n .offset-xl-2 {\n margin-left: 16.666667%;\n }\n .offset-xl-3 {\n margin-left: 25%;\n }\n .offset-xl-4 {\n margin-left: 33.333333%;\n }\n .offset-xl-5 {\n margin-left: 41.666667%;\n }\n .offset-xl-6 {\n margin-left: 50%;\n }\n .offset-xl-7 {\n margin-left: 58.333333%;\n }\n .offset-xl-8 {\n margin-left: 66.666667%;\n }\n .offset-xl-9 {\n margin-left: 75%;\n }\n .offset-xl-10 {\n margin-left: 83.333333%;\n }\n .offset-xl-11 {\n margin-left: 91.666667%;\n }\n}\n\n.table {\n width: 100%;\n max-width: 100%;\n margin-bottom: 1rem;\n}\n\n.table th,\n.table td {\n padding: 0.75rem;\n vertical-align: top;\n border-top: 1px solid #eceeef;\n}\n\n.table thead th {\n vertical-align: bottom;\n border-bottom: 2px solid #eceeef;\n}\n\n.table tbody + tbody {\n border-top: 2px solid #eceeef;\n}\n\n.table .table {\n background-color: #fff;\n}\n\n.table-sm th,\n.table-sm td {\n padding: 0.3rem;\n}\n\n.table-bordered {\n border: 1px solid #eceeef;\n}\n\n.table-bordered th,\n.table-bordered td {\n border: 1px solid #eceeef;\n}\n\n.table-bordered thead th,\n.table-bordered thead td {\n border-bottom-width: 2px;\n}\n\n.table-striped tbody tr:nth-of-type(odd) {\n background-color: rgba(0, 0, 0, 0.05);\n}\n\n.table-hover tbody tr:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-active,\n.table-active > th,\n.table-active > td {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover > td,\n.table-hover .table-active:hover > th {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-success,\n.table-success > th,\n.table-success > td {\n background-color: #dff0d8;\n}\n\n.table-hover .table-success:hover {\n background-color: #d0e9c6;\n}\n\n.table-hover .table-success:hover > td,\n.table-hover .table-success:hover > th {\n background-color: #d0e9c6;\n}\n\n.table-info,\n.table-info > th,\n.table-info > td {\n background-color: #d9edf7;\n}\n\n.table-hover .table-info:hover {\n background-color: #c4e3f3;\n}\n\n.table-hover .table-info:hover > td,\n.table-hover .table-info:hover > th {\n background-color: #c4e3f3;\n}\n\n.table-warning,\n.table-warning > th,\n.table-warning > td {\n background-color: #fcf8e3;\n}\n\n.table-hover .table-warning:hover {\n background-color: #faf2cc;\n}\n\n.table-hover .table-warning:hover > td,\n.table-hover .table-warning:hover > th {\n background-color: #faf2cc;\n}\n\n.table-danger,\n.table-danger > th,\n.table-danger > td {\n background-color: #f2dede;\n}\n\n.table-hover .table-danger:hover {\n background-color: #ebcccc;\n}\n\n.table-hover .table-danger:hover > td,\n.table-hover .table-danger:hover > th {\n background-color: #ebcccc;\n}\n\n.thead-inverse th {\n color: #fff;\n background-color: #292b2c;\n}\n\n.thead-default th {\n color: #464a4c;\n background-color: #eceeef;\n}\n\n.table-inverse {\n color: #fff;\n background-color: #292b2c;\n}\n\n.table-inverse th,\n.table-inverse td,\n.table-inverse thead th {\n border-color: #fff;\n}\n\n.table-inverse.table-bordered {\n border: 0;\n}\n\n.table-responsive {\n display: block;\n width: 100%;\n overflow-x: auto;\n -ms-overflow-style: -ms-autohiding-scrollbar;\n}\n\n.table-responsive.table-bordered {\n border: 0;\n}\n\n.form-control {\n display: block;\n width: 100%;\n padding: 0.5rem 0.75rem;\n font-size: 1rem;\n line-height: 1.25;\n color: #464a4c;\n background-color: #fff;\n background-image: none;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -webkit-transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n -o-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n}\n\n.form-control::-ms-expand {\n background-color: transparent;\n border: 0;\n}\n\n.form-control:focus {\n color: #464a4c;\n background-color: #fff;\n border-color: #5cb3fd;\n outline: none;\n}\n\n.form-control::-webkit-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::-moz-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:-ms-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:disabled, .form-control[readonly] {\n background-color: #eceeef;\n opacity: 1;\n}\n\n.form-control:disabled {\n cursor: not-allowed;\n}\n\nselect.form-control:not([size]):not([multiple]) {\n height: calc(2.25rem + 2px);\n}\n\nselect.form-control:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.form-control-file,\n.form-control-range {\n display: block;\n}\n\n.col-form-label {\n padding-top: calc(0.5rem - 1px * 2);\n padding-bottom: calc(0.5rem - 1px * 2);\n margin-bottom: 0;\n}\n\n.col-form-label-lg {\n padding-top: calc(0.75rem - 1px * 2);\n padding-bottom: calc(0.75rem - 1px * 2);\n font-size: 1.25rem;\n}\n\n.col-form-label-sm {\n padding-top: calc(0.25rem - 1px * 2);\n padding-bottom: calc(0.25rem - 1px * 2);\n font-size: 0.875rem;\n}\n\n.col-form-legend {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n font-size: 1rem;\n}\n\n.form-control-static {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n line-height: 1.25;\n border: solid transparent;\n border-width: 1px 0;\n}\n\n.form-control-static.form-control-sm, .input-group-sm > .form-control-static.form-control,\n.input-group-sm > .form-control-static.input-group-addon,\n.input-group-sm > .input-group-btn > .form-control-static.btn, .form-control-static.form-control-lg, .input-group-lg > .form-control-static.form-control,\n.input-group-lg > .form-control-static.input-group-addon,\n.input-group-lg > .input-group-btn > .form-control-static.btn {\n padding-right: 0;\n padding-left: 0;\n}\n\n.form-control-sm, .input-group-sm > .form-control,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\nselect.form-control-sm:not([size]):not([multiple]), .input-group-sm > select.form-control:not([size]):not([multiple]),\n.input-group-sm > select.input-group-addon:not([size]):not([multiple]),\n.input-group-sm > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 1.8125rem;\n}\n\n.form-control-lg, .input-group-lg > .form-control,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\nselect.form-control-lg:not([size]):not([multiple]), .input-group-lg > select.form-control:not([size]):not([multiple]),\n.input-group-lg > select.input-group-addon:not([size]):not([multiple]),\n.input-group-lg > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 3.166667rem;\n}\n\n.form-group {\n margin-bottom: 1rem;\n}\n\n.form-text {\n display: block;\n margin-top: 0.25rem;\n}\n\n.form-check {\n position: relative;\n display: block;\n margin-bottom: 0.5rem;\n}\n\n.form-check.disabled .form-check-label {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.form-check-label {\n padding-left: 1.25rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.form-check-input {\n position: absolute;\n margin-top: 0.25rem;\n margin-left: -1.25rem;\n}\n\n.form-check-input:only-child {\n position: static;\n}\n\n.form-check-inline {\n display: inline-block;\n}\n\n.form-check-inline .form-check-label {\n vertical-align: middle;\n}\n\n.form-check-inline + .form-check-inline {\n margin-left: 0.75rem;\n}\n\n.form-control-feedback {\n margin-top: 0.25rem;\n}\n\n.form-control-success,\n.form-control-warning,\n.form-control-danger {\n padding-right: 2.25rem;\n background-repeat: no-repeat;\n background-position: center right 0.5625rem;\n -webkit-background-size: 1.125rem 1.125rem;\n background-size: 1.125rem 1.125rem;\n}\n\n.has-success .form-control-feedback,\n.has-success .form-control-label,\n.has-success .col-form-label,\n.has-success .form-check-label,\n.has-success .custom-control {\n color: #5cb85c;\n}\n\n.has-success .form-control {\n border-color: #5cb85c;\n}\n\n.has-success .input-group-addon {\n color: #5cb85c;\n border-color: #5cb85c;\n background-color: #eaf6ea;\n}\n\n.has-success .form-control-success {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%235cb85c' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3E%3C/svg%3E\");\n}\n\n.has-warning .form-control-feedback,\n.has-warning .form-control-label,\n.has-warning .col-form-label,\n.has-warning .form-check-label,\n.has-warning .custom-control {\n color: #f0ad4e;\n}\n\n.has-warning .form-control {\n border-color: #f0ad4e;\n}\n\n.has-warning .input-group-addon {\n color: #f0ad4e;\n border-color: #f0ad4e;\n background-color: white;\n}\n\n.has-warning .form-control-warning {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23f0ad4e' d='M4.4 5.324h-.8v-2.46h.8zm0 1.42h-.8V5.89h.8zM3.76.63L.04 7.075c-.115.2.016.425.26.426h7.397c.242 0 .372-.226.258-.426C6.726 4.924 5.47 2.79 4.253.63c-.113-.174-.39-.174-.494 0z'/%3E%3C/svg%3E\");\n}\n\n.has-danger .form-control-feedback,\n.has-danger .form-control-label,\n.has-danger .col-form-label,\n.has-danger .form-check-label,\n.has-danger .custom-control {\n color: #d9534f;\n}\n\n.has-danger .form-control {\n border-color: #d9534f;\n}\n\n.has-danger .input-group-addon {\n color: #d9534f;\n border-color: #d9534f;\n background-color: #fdf7f7;\n}\n\n.has-danger .form-control-danger {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23d9534f' viewBox='-2 -2 7 7'%3E%3Cpath stroke='%23d9534f' d='M0 0l3 3m0-3L0 3'/%3E%3Ccircle r='.5'/%3E%3Ccircle cx='3' r='.5'/%3E%3Ccircle cy='3' r='.5'/%3E%3Ccircle cx='3' cy='3' r='.5'/%3E%3C/svg%3E\");\n}\n\n.form-inline {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.form-inline .form-check {\n width: 100%;\n}\n\n@media (min-width: 576px) {\n .form-inline label {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n margin-bottom: 0;\n }\n .form-inline .form-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n margin-bottom: 0;\n }\n .form-inline .form-control {\n display: inline-block;\n width: auto;\n vertical-align: middle;\n }\n .form-inline .form-control-static {\n display: inline-block;\n }\n .form-inline .input-group {\n width: auto;\n }\n .form-inline .form-control-label {\n margin-bottom: 0;\n vertical-align: middle;\n }\n .form-inline .form-check {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: auto;\n margin-top: 0;\n margin-bottom: 0;\n }\n .form-inline .form-check-label {\n padding-left: 0;\n }\n .form-inline .form-check-input {\n position: relative;\n margin-top: 0;\n margin-right: 0.25rem;\n margin-left: 0;\n }\n .form-inline .custom-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n }\n .form-inline .custom-control-indicator {\n position: static;\n display: inline-block;\n margin-right: 0.25rem;\n vertical-align: text-bottom;\n }\n .form-inline .has-feedback .form-control-feedback {\n top: 0;\n }\n}\n\n.btn {\n display: inline-block;\n font-weight: normal;\n line-height: 1.25;\n text-align: center;\n white-space: nowrap;\n vertical-align: middle;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n border: 1px solid transparent;\n padding: 0.5rem 1rem;\n font-size: 1rem;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n}\n\n.btn:focus, .btn:hover {\n text-decoration: none;\n}\n\n.btn:focus, .btn.focus {\n outline: 0;\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n}\n\n.btn.disabled, .btn:disabled {\n cursor: not-allowed;\n opacity: .65;\n}\n\n.btn:active, .btn.active {\n background-image: none;\n}\n\na.btn.disabled,\nfieldset[disabled] a.btn {\n pointer-events: none;\n}\n\n.btn-primary {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:hover {\n color: #fff;\n background-color: #025aa5;\n border-color: #01549b;\n}\n\n.btn-primary:focus, .btn-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-primary.disabled, .btn-primary:disabled {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:active, .btn-primary.active,\n.show > .btn-primary.dropdown-toggle {\n color: #fff;\n background-color: #025aa5;\n background-image: none;\n border-color: #01549b;\n}\n\n.btn-secondary {\n color: #292b2c;\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:hover {\n color: #292b2c;\n background-color: #e6e6e6;\n border-color: #adadad;\n}\n\n.btn-secondary:focus, .btn-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-secondary.disabled, .btn-secondary:disabled {\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:active, .btn-secondary.active,\n.show > .btn-secondary.dropdown-toggle {\n color: #292b2c;\n background-color: #e6e6e6;\n background-image: none;\n border-color: #adadad;\n}\n\n.btn-info {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:hover {\n color: #fff;\n background-color: #31b0d5;\n border-color: #2aabd2;\n}\n\n.btn-info:focus, .btn-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-info.disabled, .btn-info:disabled {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:active, .btn-info.active,\n.show > .btn-info.dropdown-toggle {\n color: #fff;\n background-color: #31b0d5;\n background-image: none;\n border-color: #2aabd2;\n}\n\n.btn-success {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:hover {\n color: #fff;\n background-color: #449d44;\n border-color: #419641;\n}\n\n.btn-success:focus, .btn-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-success.disabled, .btn-success:disabled {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:active, .btn-success.active,\n.show > .btn-success.dropdown-toggle {\n color: #fff;\n background-color: #449d44;\n background-image: none;\n border-color: #419641;\n}\n\n.btn-warning {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:hover {\n color: #fff;\n background-color: #ec971f;\n border-color: #eb9316;\n}\n\n.btn-warning:focus, .btn-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-warning.disabled, .btn-warning:disabled {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:active, .btn-warning.active,\n.show > .btn-warning.dropdown-toggle {\n color: #fff;\n background-color: #ec971f;\n background-image: none;\n border-color: #eb9316;\n}\n\n.btn-danger {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:hover {\n color: #fff;\n background-color: #c9302c;\n border-color: #c12e2a;\n}\n\n.btn-danger:focus, .btn-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-danger.disabled, .btn-danger:disabled {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:active, .btn-danger.active,\n.show > .btn-danger.dropdown-toggle {\n color: #fff;\n background-color: #c9302c;\n background-image: none;\n border-color: #c12e2a;\n}\n\n.btn-outline-primary {\n color: #0275d8;\n background-image: none;\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:hover {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:focus, .btn-outline-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-outline-primary.disabled, .btn-outline-primary:disabled {\n color: #0275d8;\n background-color: transparent;\n}\n\n.btn-outline-primary:active, .btn-outline-primary.active,\n.show > .btn-outline-primary.dropdown-toggle {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-secondary {\n color: #ccc;\n background-image: none;\n background-color: transparent;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:hover {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:focus, .btn-outline-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-outline-secondary.disabled, .btn-outline-secondary:disabled {\n color: #ccc;\n background-color: transparent;\n}\n\n.btn-outline-secondary:active, .btn-outline-secondary.active,\n.show > .btn-outline-secondary.dropdown-toggle {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-info {\n color: #5bc0de;\n background-image: none;\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:hover {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:focus, .btn-outline-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-outline-info.disabled, .btn-outline-info:disabled {\n color: #5bc0de;\n background-color: transparent;\n}\n\n.btn-outline-info:active, .btn-outline-info.active,\n.show > .btn-outline-info.dropdown-toggle {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-success {\n color: #5cb85c;\n background-image: none;\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:hover {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:focus, .btn-outline-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-outline-success.disabled, .btn-outline-success:disabled {\n color: #5cb85c;\n background-color: transparent;\n}\n\n.btn-outline-success:active, .btn-outline-success.active,\n.show > .btn-outline-success.dropdown-toggle {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-warning {\n color: #f0ad4e;\n background-image: none;\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:hover {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:focus, .btn-outline-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-outline-warning.disabled, .btn-outline-warning:disabled {\n color: #f0ad4e;\n background-color: transparent;\n}\n\n.btn-outline-warning:active, .btn-outline-warning.active,\n.show > .btn-outline-warning.dropdown-toggle {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-danger {\n color: #d9534f;\n background-image: none;\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:hover {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:focus, .btn-outline-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-outline-danger.disabled, .btn-outline-danger:disabled {\n color: #d9534f;\n background-color: transparent;\n}\n\n.btn-outline-danger:active, .btn-outline-danger.active,\n.show > .btn-outline-danger.dropdown-toggle {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-link {\n font-weight: normal;\n color: #0275d8;\n border-radius: 0;\n}\n\n.btn-link, .btn-link:active, .btn-link.active, .btn-link:disabled {\n background-color: transparent;\n}\n\n.btn-link, .btn-link:focus, .btn-link:active {\n border-color: transparent;\n}\n\n.btn-link:hover {\n border-color: transparent;\n}\n\n.btn-link:focus, .btn-link:hover {\n color: #014c8c;\n text-decoration: underline;\n background-color: transparent;\n}\n\n.btn-link:disabled {\n color: #636c72;\n}\n\n.btn-link:disabled:focus, .btn-link:disabled:hover {\n text-decoration: none;\n}\n\n.btn-lg, .btn-group-lg > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.btn-sm, .btn-group-sm > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.btn-block {\n display: block;\n width: 100%;\n}\n\n.btn-block + .btn-block {\n margin-top: 0.5rem;\n}\n\ninput[type=\"submit\"].btn-block,\ninput[type=\"reset\"].btn-block,\ninput[type=\"button\"].btn-block {\n width: 100%;\n}\n\n.fade {\n opacity: 0;\n -webkit-transition: opacity 0.15s linear;\n -o-transition: opacity 0.15s linear;\n transition: opacity 0.15s linear;\n}\n\n.fade.show {\n opacity: 1;\n}\n\n.collapse {\n display: none;\n}\n\n.collapse.show {\n display: block;\n}\n\ntr.collapse.show {\n display: table-row;\n}\n\ntbody.collapse.show {\n display: table-row-group;\n}\n\n.collapsing {\n position: relative;\n height: 0;\n overflow: hidden;\n -webkit-transition: height 0.35s ease;\n -o-transition: height 0.35s ease;\n transition: height 0.35s ease;\n}\n\n.dropup,\n.dropdown {\n position: relative;\n}\n\n.dropdown-toggle::after {\n display: inline-block;\n width: 0;\n height: 0;\n margin-left: 0.3em;\n vertical-align: middle;\n content: \"\";\n border-top: 0.3em solid;\n border-right: 0.3em solid transparent;\n border-left: 0.3em solid transparent;\n}\n\n.dropdown-toggle:focus {\n outline: 0;\n}\n\n.dropup .dropdown-toggle::after {\n border-top: 0;\n border-bottom: 0.3em solid;\n}\n\n.dropdown-menu {\n position: absolute;\n top: 100%;\n left: 0;\n z-index: 1000;\n display: none;\n float: left;\n min-width: 10rem;\n padding: 0.5rem 0;\n margin: 0.125rem 0 0;\n font-size: 1rem;\n color: #292b2c;\n text-align: left;\n list-style: none;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.dropdown-divider {\n height: 1px;\n margin: 0.5rem 0;\n overflow: hidden;\n background-color: #eceeef;\n}\n\n.dropdown-item {\n display: block;\n width: 100%;\n padding: 3px 1.5rem;\n clear: both;\n font-weight: normal;\n color: #292b2c;\n text-align: inherit;\n white-space: nowrap;\n background: none;\n border: 0;\n}\n\n.dropdown-item:focus, .dropdown-item:hover {\n color: #1d1e1f;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.dropdown-item.active, .dropdown-item:active {\n color: #fff;\n text-decoration: none;\n background-color: #0275d8;\n}\n\n.dropdown-item.disabled, .dropdown-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: transparent;\n}\n\n.show > .dropdown-menu {\n display: block;\n}\n\n.show > a {\n outline: 0;\n}\n\n.dropdown-menu-right {\n right: 0;\n left: auto;\n}\n\n.dropdown-menu-left {\n right: auto;\n left: 0;\n}\n\n.dropdown-header {\n display: block;\n padding: 0.5rem 1.5rem;\n margin-bottom: 0;\n font-size: 0.875rem;\n color: #636c72;\n white-space: nowrap;\n}\n\n.dropdown-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 990;\n}\n\n.dropup .dropdown-menu {\n top: auto;\n bottom: 100%;\n margin-bottom: 0.125rem;\n}\n\n.btn-group,\n.btn-group-vertical {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n vertical-align: middle;\n}\n\n.btn-group > .btn,\n.btn-group-vertical > .btn {\n position: relative;\n -webkit-box-flex: 0;\n -webkit-flex: 0 1 auto;\n -ms-flex: 0 1 auto;\n flex: 0 1 auto;\n}\n\n.btn-group > .btn:hover,\n.btn-group-vertical > .btn:hover {\n z-index: 2;\n}\n\n.btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active,\n.btn-group-vertical > .btn:focus,\n.btn-group-vertical > .btn:active,\n.btn-group-vertical > .btn.active {\n z-index: 2;\n}\n\n.btn-group .btn + .btn,\n.btn-group .btn + .btn-group,\n.btn-group .btn-group + .btn,\n.btn-group .btn-group + .btn-group,\n.btn-group-vertical .btn + .btn,\n.btn-group-vertical .btn + .btn-group,\n.btn-group-vertical .btn-group + .btn,\n.btn-group-vertical .btn-group + .btn-group {\n margin-left: -1px;\n}\n\n.btn-toolbar {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: start;\n -webkit-justify-content: flex-start;\n -ms-flex-pack: start;\n justify-content: flex-start;\n}\n\n.btn-toolbar .input-group {\n width: auto;\n}\n\n.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {\n border-radius: 0;\n}\n\n.btn-group > .btn:first-child {\n margin-left: 0;\n}\n\n.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn:last-child:not(:first-child),\n.btn-group > .dropdown-toggle:not(:first-child) {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group > .btn-group {\n float: left;\n}\n\n.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group .dropdown-toggle:active,\n.btn-group.open .dropdown-toggle {\n outline: 0;\n}\n\n.btn + .dropdown-toggle-split {\n padding-right: 0.75rem;\n padding-left: 0.75rem;\n}\n\n.btn + .dropdown-toggle-split::after {\n margin-left: 0;\n}\n\n.btn-sm + .dropdown-toggle-split, .btn-group-sm > .btn + .dropdown-toggle-split {\n padding-right: 0.375rem;\n padding-left: 0.375rem;\n}\n\n.btn-lg + .dropdown-toggle-split, .btn-group-lg > .btn + .dropdown-toggle-split {\n padding-right: 1.125rem;\n padding-left: 1.125rem;\n}\n\n.btn-group-vertical {\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.btn-group-vertical .btn,\n.btn-group-vertical .btn-group {\n width: 100%;\n}\n\n.btn-group-vertical > .btn + .btn,\n.btn-group-vertical > .btn + .btn-group,\n.btn-group-vertical > .btn-group + .btn,\n.btn-group-vertical > .btn-group + .btn-group {\n margin-top: -1px;\n margin-left: 0;\n}\n\n.btn-group-vertical > .btn:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn:first-child:not(:last-child) {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn:last-child:not(:first-child) {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n[data-toggle=\"buttons\"] > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn input[type=\"checkbox\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"checkbox\"] {\n position: absolute;\n clip: rect(0, 0, 0, 0);\n pointer-events: none;\n}\n\n.input-group {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n width: 100%;\n}\n\n.input-group .form-control {\n position: relative;\n z-index: 2;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n width: 1%;\n margin-bottom: 0;\n}\n\n.input-group .form-control:focus, .input-group .form-control:active, .input-group .form-control:hover {\n z-index: 3;\n}\n\n.input-group-addon,\n.input-group-btn,\n.input-group .form-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.input-group-addon:not(:first-child):not(:last-child),\n.input-group-btn:not(:first-child):not(:last-child),\n.input-group .form-control:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.input-group-addon,\n.input-group-btn {\n white-space: nowrap;\n vertical-align: middle;\n}\n\n.input-group-addon {\n padding: 0.5rem 0.75rem;\n margin-bottom: 0;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.25;\n color: #464a4c;\n text-align: center;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.input-group-addon.form-control-sm,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .input-group-addon.btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.input-group-addon.form-control-lg,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .input-group-addon.btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.input-group-addon input[type=\"radio\"],\n.input-group-addon input[type=\"checkbox\"] {\n margin-top: 0;\n}\n\n.input-group .form-control:not(:last-child),\n.input-group-addon:not(:last-child),\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group > .btn,\n.input-group-btn:not(:last-child) > .dropdown-toggle,\n.input-group-btn:not(:first-child) > .btn:not(:last-child):not(.dropdown-toggle),\n.input-group-btn:not(:first-child) > .btn-group:not(:last-child) > .btn {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.input-group-addon:not(:last-child) {\n border-right: 0;\n}\n\n.input-group .form-control:not(:first-child),\n.input-group-addon:not(:first-child),\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group > .btn,\n.input-group-btn:not(:first-child) > .dropdown-toggle,\n.input-group-btn:not(:last-child) > .btn:not(:first-child),\n.input-group-btn:not(:last-child) > .btn-group:not(:first-child) > .btn {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.form-control + .input-group-addon:not(:first-child) {\n border-left: 0;\n}\n\n.input-group-btn {\n position: relative;\n font-size: 0;\n white-space: nowrap;\n}\n\n.input-group-btn > .btn {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.input-group-btn > .btn + .btn {\n margin-left: -1px;\n}\n\n.input-group-btn > .btn:focus, .input-group-btn > .btn:active, .input-group-btn > .btn:hover {\n z-index: 3;\n}\n\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group {\n margin-right: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group {\n z-index: 2;\n margin-left: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn:focus, .input-group-btn:not(:first-child) > .btn:active, .input-group-btn:not(:first-child) > .btn:hover,\n.input-group-btn:not(:first-child) > .btn-group:focus,\n.input-group-btn:not(:first-child) > .btn-group:active,\n.input-group-btn:not(:first-child) > .btn-group:hover {\n z-index: 3;\n}\n\n.custom-control {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n min-height: 1.5rem;\n padding-left: 1.5rem;\n margin-right: 1rem;\n cursor: pointer;\n}\n\n.custom-control-input {\n position: absolute;\n z-index: -1;\n opacity: 0;\n}\n\n.custom-control-input:checked ~ .custom-control-indicator {\n color: #fff;\n background-color: #0275d8;\n}\n\n.custom-control-input:focus ~ .custom-control-indicator {\n -webkit-box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n}\n\n.custom-control-input:active ~ .custom-control-indicator {\n color: #fff;\n background-color: #8fcafe;\n}\n\n.custom-control-input:disabled ~ .custom-control-indicator {\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-control-input:disabled ~ .custom-control-description {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.custom-control-indicator {\n position: absolute;\n top: 0.25rem;\n left: 0;\n display: block;\n width: 1rem;\n height: 1rem;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #ddd;\n background-repeat: no-repeat;\n background-position: center center;\n -webkit-background-size: 50% 50%;\n background-size: 50% 50%;\n}\n\n.custom-checkbox .custom-control-indicator {\n border-radius: 0.25rem;\n}\n\n.custom-checkbox .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26 2.974 7.25 8 2.193z'/%3E%3C/svg%3E\");\n}\n\n.custom-checkbox .custom-control-input:indeterminate ~ .custom-control-indicator {\n background-color: #0275d8;\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 4'%3E%3Cpath stroke='%23fff' d='M0 2h4'/%3E%3C/svg%3E\");\n}\n\n.custom-radio .custom-control-indicator {\n border-radius: 50%;\n}\n\n.custom-radio .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3E%3Ccircle r='3' fill='%23fff'/%3E%3C/svg%3E\");\n}\n\n.custom-controls-stacked {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n\n.custom-controls-stacked .custom-control {\n margin-bottom: 0.25rem;\n}\n\n.custom-controls-stacked .custom-control + .custom-control {\n margin-left: 0;\n}\n\n.custom-select {\n display: inline-block;\n max-width: 100%;\n height: calc(2.25rem + 2px);\n padding: 0.375rem 1.75rem 0.375rem 0.75rem;\n line-height: 1.25;\n color: #464a4c;\n vertical-align: middle;\n background: #fff url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23333' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E\") no-repeat right 0.75rem center;\n -webkit-background-size: 8px 10px;\n background-size: 8px 10px;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -moz-appearance: none;\n -webkit-appearance: none;\n}\n\n.custom-select:focus {\n border-color: #5cb3fd;\n outline: none;\n}\n\n.custom-select:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.custom-select:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-select::-ms-expand {\n opacity: 0;\n}\n\n.custom-select-sm {\n padding-top: 0.375rem;\n padding-bottom: 0.375rem;\n font-size: 75%;\n}\n\n.custom-file {\n position: relative;\n display: inline-block;\n max-width: 100%;\n height: 2.5rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.custom-file-input {\n min-width: 14rem;\n max-width: 100%;\n height: 2.5rem;\n margin: 0;\n filter: alpha(opacity=0);\n opacity: 0;\n}\n\n.custom-file-control {\n position: absolute;\n top: 0;\n right: 0;\n left: 0;\n z-index: 5;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.custom-file-control:lang(en)::after {\n content: \"Choose file...\";\n}\n\n.custom-file-control::before {\n position: absolute;\n top: -1px;\n right: -1px;\n bottom: -1px;\n z-index: 6;\n display: block;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0 0.25rem 0.25rem 0;\n}\n\n.custom-file-control:lang(en)::before {\n content: \"Browse\";\n}\n\n.nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.nav-link {\n display: block;\n padding: 0.5em 1em;\n}\n\n.nav-link:focus, .nav-link:hover {\n text-decoration: none;\n}\n\n.nav-link.disabled {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.nav-tabs {\n border-bottom: 1px solid #ddd;\n}\n\n.nav-tabs .nav-item {\n margin-bottom: -1px;\n}\n\n.nav-tabs .nav-link {\n border: 1px solid transparent;\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.nav-tabs .nav-link:focus, .nav-tabs .nav-link:hover {\n border-color: #eceeef #eceeef #ddd;\n}\n\n.nav-tabs .nav-link.disabled {\n color: #636c72;\n background-color: transparent;\n border-color: transparent;\n}\n\n.nav-tabs .nav-link.active,\n.nav-tabs .nav-item.show .nav-link {\n color: #464a4c;\n background-color: #fff;\n border-color: #ddd #ddd #fff;\n}\n\n.nav-tabs .dropdown-menu {\n margin-top: -1px;\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.nav-pills .nav-link {\n border-radius: 0.25rem;\n}\n\n.nav-pills .nav-link.active,\n.nav-pills .nav-item.show .nav-link {\n color: #fff;\n cursor: default;\n background-color: #0275d8;\n}\n\n.nav-fill .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n text-align: center;\n}\n\n.nav-justified .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 100%;\n -ms-flex: 1 1 100%;\n flex: 1 1 100%;\n text-align: center;\n}\n\n.tab-content > .tab-pane {\n display: none;\n}\n\n.tab-content > .active {\n display: block;\n}\n\n.navbar {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding: 0.5rem 1rem;\n}\n\n.navbar-brand {\n display: inline-block;\n padding-top: .25rem;\n padding-bottom: .25rem;\n margin-right: 1rem;\n font-size: 1.25rem;\n line-height: inherit;\n white-space: nowrap;\n}\n\n.navbar-brand:focus, .navbar-brand:hover {\n text-decoration: none;\n}\n\n.navbar-nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.navbar-nav .nav-link {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-text {\n display: inline-block;\n padding-top: .425rem;\n padding-bottom: .425rem;\n}\n\n.navbar-toggler {\n -webkit-align-self: flex-start;\n -ms-flex-item-align: start;\n align-self: flex-start;\n padding: 0.25rem 0.75rem;\n font-size: 1.25rem;\n line-height: 1;\n background: transparent;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.navbar-toggler:focus, .navbar-toggler:hover {\n text-decoration: none;\n}\n\n.navbar-toggler-icon {\n display: inline-block;\n width: 1.5em;\n height: 1.5em;\n vertical-align: middle;\n content: \"\";\n background: no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.navbar-toggler-left {\n position: absolute;\n left: 1rem;\n}\n\n.navbar-toggler-right {\n position: absolute;\n right: 1rem;\n}\n\n@media (max-width: 575px) {\n .navbar-toggleable .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 576px) {\n .navbar-toggleable {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 767px) {\n .navbar-toggleable-sm .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-sm > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 768px) {\n .navbar-toggleable-sm {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-sm .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-sm > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-sm .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 991px) {\n .navbar-toggleable-md .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-md > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 992px) {\n .navbar-toggleable-md {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-md .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-md > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-md .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 1199px) {\n .navbar-toggleable-lg .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-lg > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 1200px) {\n .navbar-toggleable-lg {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-lg .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-lg > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-lg .navbar-toggler {\n display: none;\n }\n}\n\n.navbar-toggleable-xl {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n}\n\n.navbar-toggleable-xl > .container {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-toggleable-xl .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n\n.navbar-toggleable-xl .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n}\n\n.navbar-toggleable-xl > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n}\n\n.navbar-toggleable-xl .navbar-toggler {\n display: none;\n}\n\n.navbar-light .navbar-brand,\n.navbar-light .navbar-toggler {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-brand:focus, .navbar-light .navbar-brand:hover,\n.navbar-light .navbar-toggler:focus,\n.navbar-light .navbar-toggler:hover {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-nav .nav-link {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-light .navbar-nav .nav-link:focus, .navbar-light .navbar-nav .nav-link:hover {\n color: rgba(0, 0, 0, 0.7);\n}\n\n.navbar-light .navbar-nav .nav-link.disabled {\n color: rgba(0, 0, 0, 0.3);\n}\n\n.navbar-light .navbar-nav .open > .nav-link,\n.navbar-light .navbar-nav .active > .nav-link,\n.navbar-light .navbar-nav .nav-link.open,\n.navbar-light .navbar-nav .nav-link.active {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-toggler {\n border-color: rgba(0, 0, 0, 0.1);\n}\n\n.navbar-light .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(0, 0, 0, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-light .navbar-text {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-inverse .navbar-brand,\n.navbar-inverse .navbar-toggler {\n color: white;\n}\n\n.navbar-inverse .navbar-brand:focus, .navbar-inverse .navbar-brand:hover,\n.navbar-inverse .navbar-toggler:focus,\n.navbar-inverse .navbar-toggler:hover {\n color: white;\n}\n\n.navbar-inverse .navbar-nav .nav-link {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.navbar-inverse .navbar-nav .nav-link:focus, .navbar-inverse .navbar-nav .nav-link:hover {\n color: rgba(255, 255, 255, 0.75);\n}\n\n.navbar-inverse .navbar-nav .nav-link.disabled {\n color: rgba(255, 255, 255, 0.25);\n}\n\n.navbar-inverse .navbar-nav .open > .nav-link,\n.navbar-inverse .navbar-nav .active > .nav-link,\n.navbar-inverse .navbar-nav .nav-link.open,\n.navbar-inverse .navbar-nav .nav-link.active {\n color: white;\n}\n\n.navbar-inverse .navbar-toggler {\n border-color: rgba(255, 255, 255, 0.1);\n}\n\n.navbar-inverse .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255, 255, 255, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-inverse .navbar-text {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.card {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n border-radius: 0.25rem;\n}\n\n.card-block {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 1.25rem;\n}\n\n.card-title {\n margin-bottom: 0.75rem;\n}\n\n.card-subtitle {\n margin-top: -0.375rem;\n margin-bottom: 0;\n}\n\n.card-text:last-child {\n margin-bottom: 0;\n}\n\n.card-link:hover {\n text-decoration: none;\n}\n\n.card-link + .card-link {\n margin-left: 1.25rem;\n}\n\n.card > .list-group:first-child .list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.card > .list-group:last-child .list-group-item:last-child {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.card-header {\n padding: 0.75rem 1.25rem;\n margin-bottom: 0;\n background-color: #f7f7f9;\n border-bottom: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-header:first-child {\n border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;\n}\n\n.card-footer {\n padding: 0.75rem 1.25rem;\n background-color: #f7f7f9;\n border-top: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-footer:last-child {\n border-radius: 0 0 calc(0.25rem - 1px) calc(0.25rem - 1px);\n}\n\n.card-header-tabs {\n margin-right: -0.625rem;\n margin-bottom: -0.75rem;\n margin-left: -0.625rem;\n border-bottom: 0;\n}\n\n.card-header-pills {\n margin-right: -0.625rem;\n margin-left: -0.625rem;\n}\n\n.card-primary {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.card-primary .card-header,\n.card-primary .card-footer {\n background-color: transparent;\n}\n\n.card-success {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.card-success .card-header,\n.card-success .card-footer {\n background-color: transparent;\n}\n\n.card-info {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.card-info .card-header,\n.card-info .card-footer {\n background-color: transparent;\n}\n\n.card-warning {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.card-warning .card-header,\n.card-warning .card-footer {\n background-color: transparent;\n}\n\n.card-danger {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.card-danger .card-header,\n.card-danger .card-footer {\n background-color: transparent;\n}\n\n.card-outline-primary {\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.card-outline-secondary {\n background-color: transparent;\n border-color: #ccc;\n}\n\n.card-outline-info {\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.card-outline-success {\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.card-outline-warning {\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.card-outline-danger {\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.card-inverse {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer {\n background-color: transparent;\n border-color: rgba(255, 255, 255, 0.2);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer,\n.card-inverse .card-title,\n.card-inverse .card-blockquote {\n color: #fff;\n}\n\n.card-inverse .card-link,\n.card-inverse .card-text,\n.card-inverse .card-subtitle,\n.card-inverse .card-blockquote .blockquote-footer {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-link:focus, .card-inverse .card-link:hover {\n color: #fff;\n}\n\n.card-blockquote {\n padding: 0;\n margin-bottom: 0;\n border-left: 0;\n}\n\n.card-img {\n border-radius: calc(0.25rem - 1px);\n}\n\n.card-img-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n padding: 1.25rem;\n}\n\n.card-img-top {\n border-top-right-radius: calc(0.25rem - 1px);\n border-top-left-radius: calc(0.25rem - 1px);\n}\n\n.card-img-bottom {\n border-bottom-right-radius: calc(0.25rem - 1px);\n border-bottom-left-radius: calc(0.25rem - 1px);\n}\n\n@media (min-width: 576px) {\n .card-deck {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-deck .card {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n }\n .card-deck .card:not(:first-child) {\n margin-left: 15px;\n }\n .card-deck .card:not(:last-child) {\n margin-right: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .card-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-group .card {\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n }\n .card-group .card + .card {\n margin-left: 0;\n border-left: 0;\n }\n .card-group .card:first-child {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-top {\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-bottom {\n border-bottom-right-radius: 0;\n }\n .card-group .card:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-top {\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-bottom {\n border-bottom-left-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) {\n border-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) .card-img-top,\n .card-group .card:not(:first-child):not(:last-child) .card-img-bottom {\n border-radius: 0;\n }\n}\n\n@media (min-width: 576px) {\n .card-columns {\n -webkit-column-count: 3;\n -moz-column-count: 3;\n column-count: 3;\n -webkit-column-gap: 1.25rem;\n -moz-column-gap: 1.25rem;\n column-gap: 1.25rem;\n }\n .card-columns .card {\n display: inline-block;\n width: 100%;\n margin-bottom: 0.75rem;\n }\n}\n\n.breadcrumb {\n padding: 0.75rem 1rem;\n margin-bottom: 1rem;\n list-style: none;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.breadcrumb::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.breadcrumb-item {\n float: left;\n}\n\n.breadcrumb-item + .breadcrumb-item::before {\n display: inline-block;\n padding-right: 0.5rem;\n padding-left: 0.5rem;\n color: #636c72;\n content: \"/\";\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: underline;\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: none;\n}\n\n.breadcrumb-item.active {\n color: #636c72;\n}\n\n.pagination {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n list-style: none;\n border-radius: 0.25rem;\n}\n\n.page-item:first-child .page-link {\n margin-left: 0;\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.page-item:last-child .page-link {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.page-item.active .page-link {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.page-item.disabled .page-link {\n color: #636c72;\n pointer-events: none;\n cursor: not-allowed;\n background-color: #fff;\n border-color: #ddd;\n}\n\n.page-link {\n position: relative;\n display: block;\n padding: 0.5rem 0.75rem;\n margin-left: -1px;\n line-height: 1.25;\n color: #0275d8;\n background-color: #fff;\n border: 1px solid #ddd;\n}\n\n.page-link:focus, .page-link:hover {\n color: #014c8c;\n text-decoration: none;\n background-color: #eceeef;\n border-color: #ddd;\n}\n\n.pagination-lg .page-link {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n}\n\n.pagination-lg .page-item:first-child .page-link {\n border-bottom-left-radius: 0.3rem;\n border-top-left-radius: 0.3rem;\n}\n\n.pagination-lg .page-item:last-child .page-link {\n border-bottom-right-radius: 0.3rem;\n border-top-right-radius: 0.3rem;\n}\n\n.pagination-sm .page-link {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n}\n\n.pagination-sm .page-item:first-child .page-link {\n border-bottom-left-radius: 0.2rem;\n border-top-left-radius: 0.2rem;\n}\n\n.pagination-sm .page-item:last-child .page-link {\n border-bottom-right-radius: 0.2rem;\n border-top-right-radius: 0.2rem;\n}\n\n.badge {\n display: inline-block;\n padding: 0.25em 0.4em;\n font-size: 75%;\n font-weight: bold;\n line-height: 1;\n color: #fff;\n text-align: center;\n white-space: nowrap;\n vertical-align: baseline;\n border-radius: 0.25rem;\n}\n\n.badge:empty {\n display: none;\n}\n\n.btn .badge {\n position: relative;\n top: -1px;\n}\n\na.badge:focus, a.badge:hover {\n color: #fff;\n text-decoration: none;\n cursor: pointer;\n}\n\n.badge-pill {\n padding-right: 0.6em;\n padding-left: 0.6em;\n border-radius: 10rem;\n}\n\n.badge-default {\n background-color: #636c72;\n}\n\n.badge-default[href]:focus, .badge-default[href]:hover {\n background-color: #4b5257;\n}\n\n.badge-primary {\n background-color: #0275d8;\n}\n\n.badge-primary[href]:focus, .badge-primary[href]:hover {\n background-color: #025aa5;\n}\n\n.badge-success {\n background-color: #5cb85c;\n}\n\n.badge-success[href]:focus, .badge-success[href]:hover {\n background-color: #449d44;\n}\n\n.badge-info {\n background-color: #5bc0de;\n}\n\n.badge-info[href]:focus, .badge-info[href]:hover {\n background-color: #31b0d5;\n}\n\n.badge-warning {\n background-color: #f0ad4e;\n}\n\n.badge-warning[href]:focus, .badge-warning[href]:hover {\n background-color: #ec971f;\n}\n\n.badge-danger {\n background-color: #d9534f;\n}\n\n.badge-danger[href]:focus, .badge-danger[href]:hover {\n background-color: #c9302c;\n}\n\n.jumbotron {\n padding: 2rem 1rem;\n margin-bottom: 2rem;\n background-color: #eceeef;\n border-radius: 0.3rem;\n}\n\n@media (min-width: 576px) {\n .jumbotron {\n padding: 4rem 2rem;\n }\n}\n\n.jumbotron-hr {\n border-top-color: #d0d5d8;\n}\n\n.jumbotron-fluid {\n padding-right: 0;\n padding-left: 0;\n border-radius: 0;\n}\n\n.alert {\n padding: 0.75rem 1.25rem;\n margin-bottom: 1rem;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.alert-heading {\n color: inherit;\n}\n\n.alert-link {\n font-weight: bold;\n}\n\n.alert-dismissible .close {\n position: relative;\n top: -0.75rem;\n right: -1.25rem;\n padding: 0.75rem 1.25rem;\n color: inherit;\n}\n\n.alert-success {\n background-color: #dff0d8;\n border-color: #d0e9c6;\n color: #3c763d;\n}\n\n.alert-success hr {\n border-top-color: #c1e2b3;\n}\n\n.alert-success .alert-link {\n color: #2b542c;\n}\n\n.alert-info {\n background-color: #d9edf7;\n border-color: #bcdff1;\n color: #31708f;\n}\n\n.alert-info hr {\n border-top-color: #a6d5ec;\n}\n\n.alert-info .alert-link {\n color: #245269;\n}\n\n.alert-warning {\n background-color: #fcf8e3;\n border-color: #faf2cc;\n color: #8a6d3b;\n}\n\n.alert-warning hr {\n border-top-color: #f7ecb5;\n}\n\n.alert-warning .alert-link {\n color: #66512c;\n}\n\n.alert-danger {\n background-color: #f2dede;\n border-color: #ebcccc;\n color: #a94442;\n}\n\n.alert-danger hr {\n border-top-color: #e4b9b9;\n}\n\n.alert-danger .alert-link {\n color: #843534;\n}\n\n@-webkit-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@-o-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n.progress {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n overflow: hidden;\n font-size: 0.75rem;\n line-height: 1rem;\n text-align: center;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.progress-bar {\n height: 1rem;\n color: #fff;\n background-color: #0275d8;\n}\n\n.progress-bar-striped {\n background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n -webkit-background-size: 1rem 1rem;\n background-size: 1rem 1rem;\n}\n\n.progress-bar-animated {\n -webkit-animation: progress-bar-stripes 1s linear infinite;\n -o-animation: progress-bar-stripes 1s linear infinite;\n animation: progress-bar-stripes 1s linear infinite;\n}\n\n.media {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n}\n\n.media-body {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.list-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n}\n\n.list-group-item-action {\n width: 100%;\n color: #464a4c;\n text-align: inherit;\n}\n\n.list-group-item-action .list-group-item-heading {\n color: #292b2c;\n}\n\n.list-group-item-action:focus, .list-group-item-action:hover {\n color: #464a4c;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.list-group-item-action:active {\n color: #292b2c;\n background-color: #eceeef;\n}\n\n.list-group-item {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n padding: 0.75rem 1.25rem;\n margin-bottom: -1px;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.list-group-item:last-child {\n margin-bottom: 0;\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.list-group-item:focus, .list-group-item:hover {\n text-decoration: none;\n}\n\n.list-group-item.disabled, .list-group-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #fff;\n}\n\n.list-group-item.disabled .list-group-item-heading, .list-group-item:disabled .list-group-item-heading {\n color: inherit;\n}\n\n.list-group-item.disabled .list-group-item-text, .list-group-item:disabled .list-group-item-text {\n color: #636c72;\n}\n\n.list-group-item.active {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.list-group-item.active .list-group-item-heading,\n.list-group-item.active .list-group-item-heading > small,\n.list-group-item.active .list-group-item-heading > .small {\n color: inherit;\n}\n\n.list-group-item.active .list-group-item-text {\n color: #daeeff;\n}\n\n.list-group-flush .list-group-item {\n border-right: 0;\n border-left: 0;\n border-radius: 0;\n}\n\n.list-group-flush:first-child .list-group-item:first-child {\n border-top: 0;\n}\n\n.list-group-flush:last-child .list-group-item:last-child {\n border-bottom: 0;\n}\n\n.list-group-item-success {\n color: #3c763d;\n background-color: #dff0d8;\n}\n\na.list-group-item-success,\nbutton.list-group-item-success {\n color: #3c763d;\n}\n\na.list-group-item-success .list-group-item-heading,\nbutton.list-group-item-success .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-success:focus, a.list-group-item-success:hover,\nbutton.list-group-item-success:focus,\nbutton.list-group-item-success:hover {\n color: #3c763d;\n background-color: #d0e9c6;\n}\n\na.list-group-item-success.active,\nbutton.list-group-item-success.active {\n color: #fff;\n background-color: #3c763d;\n border-color: #3c763d;\n}\n\n.list-group-item-info {\n color: #31708f;\n background-color: #d9edf7;\n}\n\na.list-group-item-info,\nbutton.list-group-item-info {\n color: #31708f;\n}\n\na.list-group-item-info .list-group-item-heading,\nbutton.list-group-item-info .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-info:focus, a.list-group-item-info:hover,\nbutton.list-group-item-info:focus,\nbutton.list-group-item-info:hover {\n color: #31708f;\n background-color: #c4e3f3;\n}\n\na.list-group-item-info.active,\nbutton.list-group-item-info.active {\n color: #fff;\n background-color: #31708f;\n border-color: #31708f;\n}\n\n.list-group-item-warning {\n color: #8a6d3b;\n background-color: #fcf8e3;\n}\n\na.list-group-item-warning,\nbutton.list-group-item-warning {\n color: #8a6d3b;\n}\n\na.list-group-item-warning .list-group-item-heading,\nbutton.list-group-item-warning .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-warning:focus, a.list-group-item-warning:hover,\nbutton.list-group-item-warning:focus,\nbutton.list-group-item-warning:hover {\n color: #8a6d3b;\n background-color: #faf2cc;\n}\n\na.list-group-item-warning.active,\nbutton.list-group-item-warning.active {\n color: #fff;\n background-color: #8a6d3b;\n border-color: #8a6d3b;\n}\n\n.list-group-item-danger {\n color: #a94442;\n background-color: #f2dede;\n}\n\na.list-group-item-danger,\nbutton.list-group-item-danger {\n color: #a94442;\n}\n\na.list-group-item-danger .list-group-item-heading,\nbutton.list-group-item-danger .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-danger:focus, a.list-group-item-danger:hover,\nbutton.list-group-item-danger:focus,\nbutton.list-group-item-danger:hover {\n color: #a94442;\n background-color: #ebcccc;\n}\n\na.list-group-item-danger.active,\nbutton.list-group-item-danger.active {\n color: #fff;\n background-color: #a94442;\n border-color: #a94442;\n}\n\n.embed-responsive {\n position: relative;\n display: block;\n width: 100%;\n padding: 0;\n overflow: hidden;\n}\n\n.embed-responsive::before {\n display: block;\n content: \"\";\n}\n\n.embed-responsive .embed-responsive-item,\n.embed-responsive iframe,\n.embed-responsive embed,\n.embed-responsive object,\n.embed-responsive video {\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 100%;\n border: 0;\n}\n\n.embed-responsive-21by9::before {\n padding-top: 42.857143%;\n}\n\n.embed-responsive-16by9::before {\n padding-top: 56.25%;\n}\n\n.embed-responsive-4by3::before {\n padding-top: 75%;\n}\n\n.embed-responsive-1by1::before {\n padding-top: 100%;\n}\n\n.close {\n float: right;\n font-size: 1.5rem;\n font-weight: bold;\n line-height: 1;\n color: #000;\n text-shadow: 0 1px 0 #fff;\n opacity: .5;\n}\n\n.close:focus, .close:hover {\n color: #000;\n text-decoration: none;\n cursor: pointer;\n opacity: .75;\n}\n\nbutton.close {\n padding: 0;\n cursor: pointer;\n background: transparent;\n border: 0;\n -webkit-appearance: none;\n}\n\n.modal-open {\n overflow: hidden;\n}\n\n.modal {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1050;\n display: none;\n overflow: hidden;\n outline: 0;\n}\n\n.modal.fade .modal-dialog {\n -webkit-transition: -webkit-transform 0.3s ease-out;\n transition: -webkit-transform 0.3s ease-out;\n -o-transition: -o-transform 0.3s ease-out;\n transition: transform 0.3s ease-out;\n transition: transform 0.3s ease-out, -webkit-transform 0.3s ease-out, -o-transform 0.3s ease-out;\n -webkit-transform: translate(0, -25%);\n -o-transform: translate(0, -25%);\n transform: translate(0, -25%);\n}\n\n.modal.show .modal-dialog {\n -webkit-transform: translate(0, 0);\n -o-transform: translate(0, 0);\n transform: translate(0, 0);\n}\n\n.modal-open .modal {\n overflow-x: hidden;\n overflow-y: auto;\n}\n\n.modal-dialog {\n position: relative;\n width: auto;\n margin: 10px;\n}\n\n.modal-content {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n outline: 0;\n}\n\n.modal-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1040;\n background-color: #000;\n}\n\n.modal-backdrop.fade {\n opacity: 0;\n}\n\n.modal-backdrop.show {\n opacity: 0.5;\n}\n\n.modal-header {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n padding: 15px;\n border-bottom: 1px solid #eceeef;\n}\n\n.modal-title {\n margin-bottom: 0;\n line-height: 1.5;\n}\n\n.modal-body {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 15px;\n}\n\n.modal-footer {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: end;\n -webkit-justify-content: flex-end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n padding: 15px;\n border-top: 1px solid #eceeef;\n}\n\n.modal-footer > :not(:first-child) {\n margin-left: .25rem;\n}\n\n.modal-footer > :not(:last-child) {\n margin-right: .25rem;\n}\n\n.modal-scrollbar-measure {\n position: absolute;\n top: -9999px;\n width: 50px;\n height: 50px;\n overflow: scroll;\n}\n\n@media (min-width: 576px) {\n .modal-dialog {\n max-width: 500px;\n margin: 30px auto;\n }\n .modal-sm {\n max-width: 300px;\n }\n}\n\n@media (min-width: 992px) {\n .modal-lg {\n max-width: 800px;\n }\n}\n\n.tooltip {\n position: absolute;\n z-index: 1070;\n display: block;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n opacity: 0;\n}\n\n.tooltip.show {\n opacity: 0.9;\n}\n\n.tooltip.tooltip-top, .tooltip.bs-tether-element-attached-bottom {\n padding: 5px 0;\n margin-top: -3px;\n}\n\n.tooltip.tooltip-top .tooltip-inner::before, .tooltip.bs-tether-element-attached-bottom .tooltip-inner::before {\n bottom: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 5px 5px 0;\n border-top-color: #000;\n}\n\n.tooltip.tooltip-right, .tooltip.bs-tether-element-attached-left {\n padding: 0 5px;\n margin-left: 3px;\n}\n\n.tooltip.tooltip-right .tooltip-inner::before, .tooltip.bs-tether-element-attached-left .tooltip-inner::before {\n top: 50%;\n left: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 5px 5px 0;\n border-right-color: #000;\n}\n\n.tooltip.tooltip-bottom, .tooltip.bs-tether-element-attached-top {\n padding: 5px 0;\n margin-top: 3px;\n}\n\n.tooltip.tooltip-bottom .tooltip-inner::before, .tooltip.bs-tether-element-attached-top .tooltip-inner::before {\n top: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 0 5px 5px;\n border-bottom-color: #000;\n}\n\n.tooltip.tooltip-left, .tooltip.bs-tether-element-attached-right {\n padding: 0 5px;\n margin-left: -3px;\n}\n\n.tooltip.tooltip-left .tooltip-inner::before, .tooltip.bs-tether-element-attached-right .tooltip-inner::before {\n top: 50%;\n right: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 0 5px 5px;\n border-left-color: #000;\n}\n\n.tooltip-inner {\n max-width: 200px;\n padding: 3px 8px;\n color: #fff;\n text-align: center;\n background-color: #000;\n border-radius: 0.25rem;\n}\n\n.tooltip-inner::before {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1060;\n display: block;\n max-width: 276px;\n padding: 1px;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n}\n\n.popover.popover-top, .popover.bs-tether-element-attached-bottom {\n margin-top: -10px;\n}\n\n.popover.popover-top::before, .popover.popover-top::after, .popover.bs-tether-element-attached-bottom::before, .popover.bs-tether-element-attached-bottom::after {\n left: 50%;\n border-bottom-width: 0;\n}\n\n.popover.popover-top::before, .popover.bs-tether-element-attached-bottom::before {\n bottom: -11px;\n margin-left: -11px;\n border-top-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-top::after, .popover.bs-tether-element-attached-bottom::after {\n bottom: -10px;\n margin-left: -10px;\n border-top-color: #fff;\n}\n\n.popover.popover-right, .popover.bs-tether-element-attached-left {\n margin-left: 10px;\n}\n\n.popover.popover-right::before, .popover.popover-right::after, .popover.bs-tether-element-attached-left::before, .popover.bs-tether-element-attached-left::after {\n top: 50%;\n border-left-width: 0;\n}\n\n.popover.popover-right::before, .popover.bs-tether-element-attached-left::before {\n left: -11px;\n margin-top: -11px;\n border-right-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-right::after, .popover.bs-tether-element-attached-left::after {\n left: -10px;\n margin-top: -10px;\n border-right-color: #fff;\n}\n\n.popover.popover-bottom, .popover.bs-tether-element-attached-top {\n margin-top: 10px;\n}\n\n.popover.popover-bottom::before, .popover.popover-bottom::after, .popover.bs-tether-element-attached-top::before, .popover.bs-tether-element-attached-top::after {\n left: 50%;\n border-top-width: 0;\n}\n\n.popover.popover-bottom::before, .popover.bs-tether-element-attached-top::before {\n top: -11px;\n margin-left: -11px;\n border-bottom-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-bottom::after, .popover.bs-tether-element-attached-top::after {\n top: -10px;\n margin-left: -10px;\n border-bottom-color: #f7f7f7;\n}\n\n.popover.popover-bottom .popover-title::before, .popover.bs-tether-element-attached-top .popover-title::before {\n position: absolute;\n top: 0;\n left: 50%;\n display: block;\n width: 20px;\n margin-left: -10px;\n content: \"\";\n border-bottom: 1px solid #f7f7f7;\n}\n\n.popover.popover-left, .popover.bs-tether-element-attached-right {\n margin-left: -10px;\n}\n\n.popover.popover-left::before, .popover.popover-left::after, .popover.bs-tether-element-attached-right::before, .popover.bs-tether-element-attached-right::after {\n top: 50%;\n border-right-width: 0;\n}\n\n.popover.popover-left::before, .popover.bs-tether-element-attached-right::before {\n right: -11px;\n margin-top: -11px;\n border-left-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-left::after, .popover.bs-tether-element-attached-right::after {\n right: -10px;\n margin-top: -10px;\n border-left-color: #fff;\n}\n\n.popover-title {\n padding: 8px 14px;\n margin-bottom: 0;\n font-size: 1rem;\n background-color: #f7f7f7;\n border-bottom: 1px solid #ebebeb;\n border-top-right-radius: calc(0.3rem - 1px);\n border-top-left-radius: calc(0.3rem - 1px);\n}\n\n.popover-title:empty {\n display: none;\n}\n\n.popover-content {\n padding: 9px 14px;\n}\n\n.popover::before,\n.popover::after {\n position: absolute;\n display: block;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover::before {\n content: \"\";\n border-width: 11px;\n}\n\n.popover::after {\n content: \"\";\n border-width: 10px;\n}\n\n.carousel {\n position: relative;\n}\n\n.carousel-inner {\n position: relative;\n width: 100%;\n overflow: hidden;\n}\n\n.carousel-item {\n position: relative;\n display: none;\n width: 100%;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n.carousel-item.active,\n.carousel-item-next,\n.carousel-item-prev {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n}\n\n.carousel-item-next,\n.carousel-item-prev {\n position: absolute;\n top: 0;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n.carousel-control-prev,\n.carousel-control-next {\n position: absolute;\n top: 0;\n bottom: 0;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: 15%;\n color: #fff;\n text-align: center;\n opacity: 0.5;\n}\n\n.carousel-control-prev:focus, .carousel-control-prev:hover,\n.carousel-control-next:focus,\n.carousel-control-next:hover {\n color: #fff;\n text-decoration: none;\n outline: 0;\n opacity: .9;\n}\n\n.carousel-control-prev {\n left: 0;\n}\n\n.carousel-control-next {\n right: 0;\n}\n\n.carousel-control-prev-icon,\n.carousel-control-next-icon {\n display: inline-block;\n width: 20px;\n height: 20px;\n background: transparent no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.carousel-control-prev-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M4 0l-4 4 4 4 1.5-1.5-2.5-2.5 2.5-2.5-1.5-1.5z'/%3E%3C/svg%3E\");\n}\n\n.carousel-control-next-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M1.5 0l-1.5 1.5 2.5 2.5-2.5 2.5 1.5 1.5 4-4-4-4z'/%3E%3C/svg%3E\");\n}\n\n.carousel-indicators {\n position: absolute;\n right: 0;\n bottom: 10px;\n left: 0;\n z-index: 15;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n margin-right: 15%;\n margin-left: 15%;\n list-style: none;\n}\n\n.carousel-indicators li {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 auto;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n max-width: 30px;\n height: 3px;\n margin-right: 3px;\n margin-left: 3px;\n text-indent: -999px;\n cursor: pointer;\n background-color: rgba(255, 255, 255, 0.5);\n}\n\n.carousel-indicators li::before {\n position: absolute;\n top: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators li::after {\n position: absolute;\n bottom: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators .active {\n background-color: #fff;\n}\n\n.carousel-caption {\n position: absolute;\n right: 15%;\n bottom: 20px;\n left: 15%;\n z-index: 10;\n padding-top: 20px;\n padding-bottom: 20px;\n color: #fff;\n text-align: center;\n}\n\n.align-baseline {\n vertical-align: baseline !important;\n}\n\n.align-top {\n vertical-align: top !important;\n}\n\n.align-middle {\n vertical-align: middle !important;\n}\n\n.align-bottom {\n vertical-align: bottom !important;\n}\n\n.align-text-bottom {\n vertical-align: text-bottom !important;\n}\n\n.align-text-top {\n vertical-align: text-top !important;\n}\n\n.bg-faded {\n background-color: #f7f7f7;\n}\n\n.bg-primary {\n background-color: #0275d8 !important;\n}\n\na.bg-primary:focus, a.bg-primary:hover {\n background-color: #025aa5 !important;\n}\n\n.bg-success {\n background-color: #5cb85c !important;\n}\n\na.bg-success:focus, a.bg-success:hover {\n background-color: #449d44 !important;\n}\n\n.bg-info {\n background-color: #5bc0de !important;\n}\n\na.bg-info:focus, a.bg-info:hover {\n background-color: #31b0d5 !important;\n}\n\n.bg-warning {\n background-color: #f0ad4e !important;\n}\n\na.bg-warning:focus, a.bg-warning:hover {\n background-color: #ec971f !important;\n}\n\n.bg-danger {\n background-color: #d9534f !important;\n}\n\na.bg-danger:focus, a.bg-danger:hover {\n background-color: #c9302c !important;\n}\n\n.bg-inverse {\n background-color: #292b2c !important;\n}\n\na.bg-inverse:focus, a.bg-inverse:hover {\n background-color: #101112 !important;\n}\n\n.border-0 {\n border: 0 !important;\n}\n\n.border-top-0 {\n border-top: 0 !important;\n}\n\n.border-right-0 {\n border-right: 0 !important;\n}\n\n.border-bottom-0 {\n border-bottom: 0 !important;\n}\n\n.border-left-0 {\n border-left: 0 !important;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.rounded-top {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-right {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.rounded-bottom {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.rounded-left {\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-circle {\n border-radius: 50%;\n}\n\n.rounded-0 {\n border-radius: 0;\n}\n\n.clearfix::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.d-none {\n display: none !important;\n}\n\n.d-inline {\n display: inline !important;\n}\n\n.d-inline-block {\n display: inline-block !important;\n}\n\n.d-block {\n display: block !important;\n}\n\n.d-table {\n display: table !important;\n}\n\n.d-table-cell {\n display: table-cell !important;\n}\n\n.d-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n}\n\n.d-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n}\n\n@media (min-width: 576px) {\n .d-sm-none {\n display: none !important;\n }\n .d-sm-inline {\n display: inline !important;\n }\n .d-sm-inline-block {\n display: inline-block !important;\n }\n .d-sm-block {\n display: block !important;\n }\n .d-sm-table {\n display: table !important;\n }\n .d-sm-table-cell {\n display: table-cell !important;\n }\n .d-sm-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-sm-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 768px) {\n .d-md-none {\n display: none !important;\n }\n .d-md-inline {\n display: inline !important;\n }\n .d-md-inline-block {\n display: inline-block !important;\n }\n .d-md-block {\n display: block !important;\n }\n .d-md-table {\n display: table !important;\n }\n .d-md-table-cell {\n display: table-cell !important;\n }\n .d-md-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-md-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 992px) {\n .d-lg-none {\n display: none !important;\n }\n .d-lg-inline {\n display: inline !important;\n }\n .d-lg-inline-block {\n display: inline-block !important;\n }\n .d-lg-block {\n display: block !important;\n }\n .d-lg-table {\n display: table !important;\n }\n .d-lg-table-cell {\n display: table-cell !important;\n }\n .d-lg-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-lg-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 1200px) {\n .d-xl-none {\n display: none !important;\n }\n .d-xl-inline {\n display: inline !important;\n }\n .d-xl-inline-block {\n display: inline-block !important;\n }\n .d-xl-block {\n display: block !important;\n }\n .d-xl-table {\n display: table !important;\n }\n .d-xl-table-cell {\n display: table-cell !important;\n }\n .d-xl-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-xl-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n.flex-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n}\n\n.flex-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n}\n\n.flex-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n}\n\n.flex-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n}\n\n.flex-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n}\n\n.flex-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n}\n\n.flex-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n}\n\n.flex-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n}\n\n.flex-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n}\n\n.flex-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n}\n\n.justify-content-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n}\n\n.justify-content-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n}\n\n.justify-content-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n}\n\n.justify-content-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n}\n\n.justify-content-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n}\n\n.align-items-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n}\n\n.align-items-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n}\n\n.align-items-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n}\n\n.align-items-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n}\n\n.align-items-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n}\n\n.align-content-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n}\n\n.align-content-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n}\n\n.align-content-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n}\n\n.align-content-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n}\n\n.align-content-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n}\n\n.align-content-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n}\n\n.align-self-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n}\n\n.align-self-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n}\n\n.align-self-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n}\n\n.align-self-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n}\n\n.align-self-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n}\n\n.align-self-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n}\n\n@media (min-width: 576px) {\n .flex-sm-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-sm-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-sm-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-sm-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-sm-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-sm-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-sm-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-sm-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-sm-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-sm-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-sm-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-sm-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-sm-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-sm-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-sm-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-sm-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-sm-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-sm-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-sm-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-sm-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-sm-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-sm-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-sm-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-sm-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-sm-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-sm-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-sm-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-sm-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-sm-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-sm-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-sm-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-sm-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 768px) {\n .flex-md-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-md-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-md-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-md-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-md-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-md-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-md-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-md-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-md-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-md-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-md-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-md-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-md-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-md-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-md-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-md-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-md-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-md-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-md-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-md-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-md-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-md-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-md-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-md-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-md-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-md-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-md-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-md-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-md-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-md-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-md-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-md-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 992px) {\n .flex-lg-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-lg-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-lg-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-lg-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-lg-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-lg-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-lg-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-lg-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-lg-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-lg-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-lg-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-lg-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-lg-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-lg-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-lg-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-lg-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-lg-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-lg-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-lg-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-lg-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-lg-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-lg-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-lg-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-lg-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-lg-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-lg-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-lg-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-lg-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-lg-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-lg-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-lg-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-lg-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 1200px) {\n .flex-xl-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-xl-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-xl-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-xl-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-xl-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-xl-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-xl-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-xl-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-xl-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-xl-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-xl-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-xl-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-xl-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-xl-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-xl-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-xl-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-xl-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-xl-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-xl-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-xl-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-xl-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-xl-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-xl-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-xl-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-xl-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-xl-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-xl-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-xl-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-xl-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-xl-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-xl-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-xl-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n.float-left {\n float: left !important;\n}\n\n.float-right {\n float: right !important;\n}\n\n.float-none {\n float: none !important;\n}\n\n@media (min-width: 576px) {\n .float-sm-left {\n float: left !important;\n }\n .float-sm-right {\n float: right !important;\n }\n .float-sm-none {\n float: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .float-md-left {\n float: left !important;\n }\n .float-md-right {\n float: right !important;\n }\n .float-md-none {\n float: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .float-lg-left {\n float: left !important;\n }\n .float-lg-right {\n float: right !important;\n }\n .float-lg-none {\n float: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .float-xl-left {\n float: left !important;\n }\n .float-xl-right {\n float: right !important;\n }\n .float-xl-none {\n float: none !important;\n }\n}\n\n.fixed-top {\n position: fixed;\n top: 0;\n right: 0;\n left: 0;\n z-index: 1030;\n}\n\n.fixed-bottom {\n position: fixed;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1030;\n}\n\n.sticky-top {\n position: -webkit-sticky;\n position: sticky;\n top: 0;\n z-index: 1030;\n}\n\n.sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n border: 0;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n position: static;\n width: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n clip: auto;\n}\n\n.w-25 {\n width: 25% !important;\n}\n\n.w-50 {\n width: 50% !important;\n}\n\n.w-75 {\n width: 75% !important;\n}\n\n.w-100 {\n width: 100% !important;\n}\n\n.h-25 {\n height: 25% !important;\n}\n\n.h-50 {\n height: 50% !important;\n}\n\n.h-75 {\n height: 75% !important;\n}\n\n.h-100 {\n height: 100% !important;\n}\n\n.mw-100 {\n max-width: 100% !important;\n}\n\n.mh-100 {\n max-height: 100% !important;\n}\n\n.m-0 {\n margin: 0 0 !important;\n}\n\n.mt-0 {\n margin-top: 0 !important;\n}\n\n.mr-0 {\n margin-right: 0 !important;\n}\n\n.mb-0 {\n margin-bottom: 0 !important;\n}\n\n.ml-0 {\n margin-left: 0 !important;\n}\n\n.mx-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n}\n\n.my-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n}\n\n.m-1 {\n margin: 0.25rem 0.25rem !important;\n}\n\n.mt-1 {\n margin-top: 0.25rem !important;\n}\n\n.mr-1 {\n margin-right: 0.25rem !important;\n}\n\n.mb-1 {\n margin-bottom: 0.25rem !important;\n}\n\n.ml-1 {\n margin-left: 0.25rem !important;\n}\n\n.mx-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n}\n\n.my-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n}\n\n.m-2 {\n margin: 0.5rem 0.5rem !important;\n}\n\n.mt-2 {\n margin-top: 0.5rem !important;\n}\n\n.mr-2 {\n margin-right: 0.5rem !important;\n}\n\n.mb-2 {\n margin-bottom: 0.5rem !important;\n}\n\n.ml-2 {\n margin-left: 0.5rem !important;\n}\n\n.mx-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n}\n\n.my-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n}\n\n.m-3 {\n margin: 1rem 1rem !important;\n}\n\n.mt-3 {\n margin-top: 1rem !important;\n}\n\n.mr-3 {\n margin-right: 1rem !important;\n}\n\n.mb-3 {\n margin-bottom: 1rem !important;\n}\n\n.ml-3 {\n margin-left: 1rem !important;\n}\n\n.mx-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n}\n\n.my-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n}\n\n.m-4 {\n margin: 1.5rem 1.5rem !important;\n}\n\n.mt-4 {\n margin-top: 1.5rem !important;\n}\n\n.mr-4 {\n margin-right: 1.5rem !important;\n}\n\n.mb-4 {\n margin-bottom: 1.5rem !important;\n}\n\n.ml-4 {\n margin-left: 1.5rem !important;\n}\n\n.mx-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n}\n\n.my-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n}\n\n.m-5 {\n margin: 3rem 3rem !important;\n}\n\n.mt-5 {\n margin-top: 3rem !important;\n}\n\n.mr-5 {\n margin-right: 3rem !important;\n}\n\n.mb-5 {\n margin-bottom: 3rem !important;\n}\n\n.ml-5 {\n margin-left: 3rem !important;\n}\n\n.mx-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n}\n\n.my-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n}\n\n.p-0 {\n padding: 0 0 !important;\n}\n\n.pt-0 {\n padding-top: 0 !important;\n}\n\n.pr-0 {\n padding-right: 0 !important;\n}\n\n.pb-0 {\n padding-bottom: 0 !important;\n}\n\n.pl-0 {\n padding-left: 0 !important;\n}\n\n.px-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n}\n\n.py-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n}\n\n.p-1 {\n padding: 0.25rem 0.25rem !important;\n}\n\n.pt-1 {\n padding-top: 0.25rem !important;\n}\n\n.pr-1 {\n padding-right: 0.25rem !important;\n}\n\n.pb-1 {\n padding-bottom: 0.25rem !important;\n}\n\n.pl-1 {\n padding-left: 0.25rem !important;\n}\n\n.px-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n}\n\n.py-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n}\n\n.p-2 {\n padding: 0.5rem 0.5rem !important;\n}\n\n.pt-2 {\n padding-top: 0.5rem !important;\n}\n\n.pr-2 {\n padding-right: 0.5rem !important;\n}\n\n.pb-2 {\n padding-bottom: 0.5rem !important;\n}\n\n.pl-2 {\n padding-left: 0.5rem !important;\n}\n\n.px-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n}\n\n.py-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n}\n\n.p-3 {\n padding: 1rem 1rem !important;\n}\n\n.pt-3 {\n padding-top: 1rem !important;\n}\n\n.pr-3 {\n padding-right: 1rem !important;\n}\n\n.pb-3 {\n padding-bottom: 1rem !important;\n}\n\n.pl-3 {\n padding-left: 1rem !important;\n}\n\n.px-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n}\n\n.py-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n}\n\n.p-4 {\n padding: 1.5rem 1.5rem !important;\n}\n\n.pt-4 {\n padding-top: 1.5rem !important;\n}\n\n.pr-4 {\n padding-right: 1.5rem !important;\n}\n\n.pb-4 {\n padding-bottom: 1.5rem !important;\n}\n\n.pl-4 {\n padding-left: 1.5rem !important;\n}\n\n.px-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n}\n\n.py-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n}\n\n.p-5 {\n padding: 3rem 3rem !important;\n}\n\n.pt-5 {\n padding-top: 3rem !important;\n}\n\n.pr-5 {\n padding-right: 3rem !important;\n}\n\n.pb-5 {\n padding-bottom: 3rem !important;\n}\n\n.pl-5 {\n padding-left: 3rem !important;\n}\n\n.px-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n}\n\n.py-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n}\n\n.m-auto {\n margin: auto !important;\n}\n\n.mt-auto {\n margin-top: auto !important;\n}\n\n.mr-auto {\n margin-right: auto !important;\n}\n\n.mb-auto {\n margin-bottom: auto !important;\n}\n\n.ml-auto {\n margin-left: auto !important;\n}\n\n.mx-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n}\n\n.my-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n}\n\n@media (min-width: 576px) {\n .m-sm-0 {\n margin: 0 0 !important;\n }\n .mt-sm-0 {\n margin-top: 0 !important;\n }\n .mr-sm-0 {\n margin-right: 0 !important;\n }\n .mb-sm-0 {\n margin-bottom: 0 !important;\n }\n .ml-sm-0 {\n margin-left: 0 !important;\n }\n .mx-sm-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-sm-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-sm-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-sm-1 {\n margin-top: 0.25rem !important;\n }\n .mr-sm-1 {\n margin-right: 0.25rem !important;\n }\n .mb-sm-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-sm-1 {\n margin-left: 0.25rem !important;\n }\n .mx-sm-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-sm-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-sm-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-sm-2 {\n margin-top: 0.5rem !important;\n }\n .mr-sm-2 {\n margin-right: 0.5rem !important;\n }\n .mb-sm-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-sm-2 {\n margin-left: 0.5rem !important;\n }\n .mx-sm-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-sm-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-sm-3 {\n margin: 1rem 1rem !important;\n }\n .mt-sm-3 {\n margin-top: 1rem !important;\n }\n .mr-sm-3 {\n margin-right: 1rem !important;\n }\n .mb-sm-3 {\n margin-bottom: 1rem !important;\n }\n .ml-sm-3 {\n margin-left: 1rem !important;\n }\n .mx-sm-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-sm-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-sm-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-sm-4 {\n margin-top: 1.5rem !important;\n }\n .mr-sm-4 {\n margin-right: 1.5rem !important;\n }\n .mb-sm-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-sm-4 {\n margin-left: 1.5rem !important;\n }\n .mx-sm-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-sm-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-sm-5 {\n margin: 3rem 3rem !important;\n }\n .mt-sm-5 {\n margin-top: 3rem !important;\n }\n .mr-sm-5 {\n margin-right: 3rem !important;\n }\n .mb-sm-5 {\n margin-bottom: 3rem !important;\n }\n .ml-sm-5 {\n margin-left: 3rem !important;\n }\n .mx-sm-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-sm-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-sm-0 {\n padding: 0 0 !important;\n }\n .pt-sm-0 {\n padding-top: 0 !important;\n }\n .pr-sm-0 {\n padding-right: 0 !important;\n }\n .pb-sm-0 {\n padding-bottom: 0 !important;\n }\n .pl-sm-0 {\n padding-left: 0 !important;\n }\n .px-sm-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-sm-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-sm-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-sm-1 {\n padding-top: 0.25rem !important;\n }\n .pr-sm-1 {\n padding-right: 0.25rem !important;\n }\n .pb-sm-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-sm-1 {\n padding-left: 0.25rem !important;\n }\n .px-sm-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-sm-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-sm-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-sm-2 {\n padding-top: 0.5rem !important;\n }\n .pr-sm-2 {\n padding-right: 0.5rem !important;\n }\n .pb-sm-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-sm-2 {\n padding-left: 0.5rem !important;\n }\n .px-sm-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-sm-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-sm-3 {\n padding: 1rem 1rem !important;\n }\n .pt-sm-3 {\n padding-top: 1rem !important;\n }\n .pr-sm-3 {\n padding-right: 1rem !important;\n }\n .pb-sm-3 {\n padding-bottom: 1rem !important;\n }\n .pl-sm-3 {\n padding-left: 1rem !important;\n }\n .px-sm-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-sm-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-sm-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-sm-4 {\n padding-top: 1.5rem !important;\n }\n .pr-sm-4 {\n padding-right: 1.5rem !important;\n }\n .pb-sm-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-sm-4 {\n padding-left: 1.5rem !important;\n }\n .px-sm-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-sm-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-sm-5 {\n padding: 3rem 3rem !important;\n }\n .pt-sm-5 {\n padding-top: 3rem !important;\n }\n .pr-sm-5 {\n padding-right: 3rem !important;\n }\n .pb-sm-5 {\n padding-bottom: 3rem !important;\n }\n .pl-sm-5 {\n padding-left: 3rem !important;\n }\n .px-sm-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-sm-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-sm-auto {\n margin: auto !important;\n }\n .mt-sm-auto {\n margin-top: auto !important;\n }\n .mr-sm-auto {\n margin-right: auto !important;\n }\n .mb-sm-auto {\n margin-bottom: auto !important;\n }\n .ml-sm-auto {\n margin-left: auto !important;\n }\n .mx-sm-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-sm-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 768px) {\n .m-md-0 {\n margin: 0 0 !important;\n }\n .mt-md-0 {\n margin-top: 0 !important;\n }\n .mr-md-0 {\n margin-right: 0 !important;\n }\n .mb-md-0 {\n margin-bottom: 0 !important;\n }\n .ml-md-0 {\n margin-left: 0 !important;\n }\n .mx-md-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-md-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-md-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-md-1 {\n margin-top: 0.25rem !important;\n }\n .mr-md-1 {\n margin-right: 0.25rem !important;\n }\n .mb-md-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-md-1 {\n margin-left: 0.25rem !important;\n }\n .mx-md-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-md-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-md-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-md-2 {\n margin-top: 0.5rem !important;\n }\n .mr-md-2 {\n margin-right: 0.5rem !important;\n }\n .mb-md-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-md-2 {\n margin-left: 0.5rem !important;\n }\n .mx-md-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-md-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-md-3 {\n margin: 1rem 1rem !important;\n }\n .mt-md-3 {\n margin-top: 1rem !important;\n }\n .mr-md-3 {\n margin-right: 1rem !important;\n }\n .mb-md-3 {\n margin-bottom: 1rem !important;\n }\n .ml-md-3 {\n margin-left: 1rem !important;\n }\n .mx-md-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-md-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-md-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-md-4 {\n margin-top: 1.5rem !important;\n }\n .mr-md-4 {\n margin-right: 1.5rem !important;\n }\n .mb-md-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-md-4 {\n margin-left: 1.5rem !important;\n }\n .mx-md-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-md-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-md-5 {\n margin: 3rem 3rem !important;\n }\n .mt-md-5 {\n margin-top: 3rem !important;\n }\n .mr-md-5 {\n margin-right: 3rem !important;\n }\n .mb-md-5 {\n margin-bottom: 3rem !important;\n }\n .ml-md-5 {\n margin-left: 3rem !important;\n }\n .mx-md-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-md-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-md-0 {\n padding: 0 0 !important;\n }\n .pt-md-0 {\n padding-top: 0 !important;\n }\n .pr-md-0 {\n padding-right: 0 !important;\n }\n .pb-md-0 {\n padding-bottom: 0 !important;\n }\n .pl-md-0 {\n padding-left: 0 !important;\n }\n .px-md-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-md-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-md-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-md-1 {\n padding-top: 0.25rem !important;\n }\n .pr-md-1 {\n padding-right: 0.25rem !important;\n }\n .pb-md-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-md-1 {\n padding-left: 0.25rem !important;\n }\n .px-md-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-md-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-md-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-md-2 {\n padding-top: 0.5rem !important;\n }\n .pr-md-2 {\n padding-right: 0.5rem !important;\n }\n .pb-md-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-md-2 {\n padding-left: 0.5rem !important;\n }\n .px-md-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-md-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-md-3 {\n padding: 1rem 1rem !important;\n }\n .pt-md-3 {\n padding-top: 1rem !important;\n }\n .pr-md-3 {\n padding-right: 1rem !important;\n }\n .pb-md-3 {\n padding-bottom: 1rem !important;\n }\n .pl-md-3 {\n padding-left: 1rem !important;\n }\n .px-md-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-md-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-md-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-md-4 {\n padding-top: 1.5rem !important;\n }\n .pr-md-4 {\n padding-right: 1.5rem !important;\n }\n .pb-md-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-md-4 {\n padding-left: 1.5rem !important;\n }\n .px-md-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-md-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-md-5 {\n padding: 3rem 3rem !important;\n }\n .pt-md-5 {\n padding-top: 3rem !important;\n }\n .pr-md-5 {\n padding-right: 3rem !important;\n }\n .pb-md-5 {\n padding-bottom: 3rem !important;\n }\n .pl-md-5 {\n padding-left: 3rem !important;\n }\n .px-md-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-md-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-md-auto {\n margin: auto !important;\n }\n .mt-md-auto {\n margin-top: auto !important;\n }\n .mr-md-auto {\n margin-right: auto !important;\n }\n .mb-md-auto {\n margin-bottom: auto !important;\n }\n .ml-md-auto {\n margin-left: auto !important;\n }\n .mx-md-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-md-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 992px) {\n .m-lg-0 {\n margin: 0 0 !important;\n }\n .mt-lg-0 {\n margin-top: 0 !important;\n }\n .mr-lg-0 {\n margin-right: 0 !important;\n }\n .mb-lg-0 {\n margin-bottom: 0 !important;\n }\n .ml-lg-0 {\n margin-left: 0 !important;\n }\n .mx-lg-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-lg-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-lg-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-lg-1 {\n margin-top: 0.25rem !important;\n }\n .mr-lg-1 {\n margin-right: 0.25rem !important;\n }\n .mb-lg-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-lg-1 {\n margin-left: 0.25rem !important;\n }\n .mx-lg-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-lg-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-lg-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-lg-2 {\n margin-top: 0.5rem !important;\n }\n .mr-lg-2 {\n margin-right: 0.5rem !important;\n }\n .mb-lg-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-lg-2 {\n margin-left: 0.5rem !important;\n }\n .mx-lg-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-lg-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-lg-3 {\n margin: 1rem 1rem !important;\n }\n .mt-lg-3 {\n margin-top: 1rem !important;\n }\n .mr-lg-3 {\n margin-right: 1rem !important;\n }\n .mb-lg-3 {\n margin-bottom: 1rem !important;\n }\n .ml-lg-3 {\n margin-left: 1rem !important;\n }\n .mx-lg-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-lg-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-lg-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-lg-4 {\n margin-top: 1.5rem !important;\n }\n .mr-lg-4 {\n margin-right: 1.5rem !important;\n }\n .mb-lg-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-lg-4 {\n margin-left: 1.5rem !important;\n }\n .mx-lg-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-lg-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-lg-5 {\n margin: 3rem 3rem !important;\n }\n .mt-lg-5 {\n margin-top: 3rem !important;\n }\n .mr-lg-5 {\n margin-right: 3rem !important;\n }\n .mb-lg-5 {\n margin-bottom: 3rem !important;\n }\n .ml-lg-5 {\n margin-left: 3rem !important;\n }\n .mx-lg-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-lg-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-lg-0 {\n padding: 0 0 !important;\n }\n .pt-lg-0 {\n padding-top: 0 !important;\n }\n .pr-lg-0 {\n padding-right: 0 !important;\n }\n .pb-lg-0 {\n padding-bottom: 0 !important;\n }\n .pl-lg-0 {\n padding-left: 0 !important;\n }\n .px-lg-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-lg-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-lg-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-lg-1 {\n padding-top: 0.25rem !important;\n }\n .pr-lg-1 {\n padding-right: 0.25rem !important;\n }\n .pb-lg-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-lg-1 {\n padding-left: 0.25rem !important;\n }\n .px-lg-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-lg-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-lg-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-lg-2 {\n padding-top: 0.5rem !important;\n }\n .pr-lg-2 {\n padding-right: 0.5rem !important;\n }\n .pb-lg-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-lg-2 {\n padding-left: 0.5rem !important;\n }\n .px-lg-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-lg-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-lg-3 {\n padding: 1rem 1rem !important;\n }\n .pt-lg-3 {\n padding-top: 1rem !important;\n }\n .pr-lg-3 {\n padding-right: 1rem !important;\n }\n .pb-lg-3 {\n padding-bottom: 1rem !important;\n }\n .pl-lg-3 {\n padding-left: 1rem !important;\n }\n .px-lg-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-lg-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-lg-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-lg-4 {\n padding-top: 1.5rem !important;\n }\n .pr-lg-4 {\n padding-right: 1.5rem !important;\n }\n .pb-lg-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-lg-4 {\n padding-left: 1.5rem !important;\n }\n .px-lg-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-lg-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-lg-5 {\n padding: 3rem 3rem !important;\n }\n .pt-lg-5 {\n padding-top: 3rem !important;\n }\n .pr-lg-5 {\n padding-right: 3rem !important;\n }\n .pb-lg-5 {\n padding-bottom: 3rem !important;\n }\n .pl-lg-5 {\n padding-left: 3rem !important;\n }\n .px-lg-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-lg-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-lg-auto {\n margin: auto !important;\n }\n .mt-lg-auto {\n margin-top: auto !important;\n }\n .mr-lg-auto {\n margin-right: auto !important;\n }\n .mb-lg-auto {\n margin-bottom: auto !important;\n }\n .ml-lg-auto {\n margin-left: auto !important;\n }\n .mx-lg-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-lg-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 1200px) {\n .m-xl-0 {\n margin: 0 0 !important;\n }\n .mt-xl-0 {\n margin-top: 0 !important;\n }\n .mr-xl-0 {\n margin-right: 0 !important;\n }\n .mb-xl-0 {\n margin-bottom: 0 !important;\n }\n .ml-xl-0 {\n margin-left: 0 !important;\n }\n .mx-xl-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-xl-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-xl-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-xl-1 {\n margin-top: 0.25rem !important;\n }\n .mr-xl-1 {\n margin-right: 0.25rem !important;\n }\n .mb-xl-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-xl-1 {\n margin-left: 0.25rem !important;\n }\n .mx-xl-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-xl-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-xl-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-xl-2 {\n margin-top: 0.5rem !important;\n }\n .mr-xl-2 {\n margin-right: 0.5rem !important;\n }\n .mb-xl-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-xl-2 {\n margin-left: 0.5rem !important;\n }\n .mx-xl-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-xl-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-xl-3 {\n margin: 1rem 1rem !important;\n }\n .mt-xl-3 {\n margin-top: 1rem !important;\n }\n .mr-xl-3 {\n margin-right: 1rem !important;\n }\n .mb-xl-3 {\n margin-bottom: 1rem !important;\n }\n .ml-xl-3 {\n margin-left: 1rem !important;\n }\n .mx-xl-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-xl-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-xl-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-xl-4 {\n margin-top: 1.5rem !important;\n }\n .mr-xl-4 {\n margin-right: 1.5rem !important;\n }\n .mb-xl-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-xl-4 {\n margin-left: 1.5rem !important;\n }\n .mx-xl-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-xl-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-xl-5 {\n margin: 3rem 3rem !important;\n }\n .mt-xl-5 {\n margin-top: 3rem !important;\n }\n .mr-xl-5 {\n margin-right: 3rem !important;\n }\n .mb-xl-5 {\n margin-bottom: 3rem !important;\n }\n .ml-xl-5 {\n margin-left: 3rem !important;\n }\n .mx-xl-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-xl-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-xl-0 {\n padding: 0 0 !important;\n }\n .pt-xl-0 {\n padding-top: 0 !important;\n }\n .pr-xl-0 {\n padding-right: 0 !important;\n }\n .pb-xl-0 {\n padding-bottom: 0 !important;\n }\n .pl-xl-0 {\n padding-left: 0 !important;\n }\n .px-xl-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-xl-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-xl-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-xl-1 {\n padding-top: 0.25rem !important;\n }\n .pr-xl-1 {\n padding-right: 0.25rem !important;\n }\n .pb-xl-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-xl-1 {\n padding-left: 0.25rem !important;\n }\n .px-xl-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-xl-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-xl-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-xl-2 {\n padding-top: 0.5rem !important;\n }\n .pr-xl-2 {\n padding-right: 0.5rem !important;\n }\n .pb-xl-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-xl-2 {\n padding-left: 0.5rem !important;\n }\n .px-xl-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-xl-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-xl-3 {\n padding: 1rem 1rem !important;\n }\n .pt-xl-3 {\n padding-top: 1rem !important;\n }\n .pr-xl-3 {\n padding-right: 1rem !important;\n }\n .pb-xl-3 {\n padding-bottom: 1rem !important;\n }\n .pl-xl-3 {\n padding-left: 1rem !important;\n }\n .px-xl-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-xl-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-xl-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-xl-4 {\n padding-top: 1.5rem !important;\n }\n .pr-xl-4 {\n padding-right: 1.5rem !important;\n }\n .pb-xl-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-xl-4 {\n padding-left: 1.5rem !important;\n }\n .px-xl-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-xl-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-xl-5 {\n padding: 3rem 3rem !important;\n }\n .pt-xl-5 {\n padding-top: 3rem !important;\n }\n .pr-xl-5 {\n padding-right: 3rem !important;\n }\n .pb-xl-5 {\n padding-bottom: 3rem !important;\n }\n .pl-xl-5 {\n padding-left: 3rem !important;\n }\n .px-xl-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-xl-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-xl-auto {\n margin: auto !important;\n }\n .mt-xl-auto {\n margin-top: auto !important;\n }\n .mr-xl-auto {\n margin-right: auto !important;\n }\n .mb-xl-auto {\n margin-bottom: auto !important;\n }\n .ml-xl-auto {\n margin-left: auto !important;\n }\n .mx-xl-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-xl-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n.text-justify {\n text-align: justify !important;\n}\n\n.text-nowrap {\n white-space: nowrap !important;\n}\n\n.text-truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.text-left {\n text-align: left !important;\n}\n\n.text-right {\n text-align: right !important;\n}\n\n.text-center {\n text-align: center !important;\n}\n\n@media (min-width: 576px) {\n .text-sm-left {\n text-align: left !important;\n }\n .text-sm-right {\n text-align: right !important;\n }\n .text-sm-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 768px) {\n .text-md-left {\n text-align: left !important;\n }\n .text-md-right {\n text-align: right !important;\n }\n .text-md-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 992px) {\n .text-lg-left {\n text-align: left !important;\n }\n .text-lg-right {\n text-align: right !important;\n }\n .text-lg-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 1200px) {\n .text-xl-left {\n text-align: left !important;\n }\n .text-xl-right {\n text-align: right !important;\n }\n .text-xl-center {\n text-align: center !important;\n }\n}\n\n.text-lowercase {\n text-transform: lowercase !important;\n}\n\n.text-uppercase {\n text-transform: uppercase !important;\n}\n\n.text-capitalize {\n text-transform: capitalize !important;\n}\n\n.font-weight-normal {\n font-weight: normal;\n}\n\n.font-weight-bold {\n font-weight: bold;\n}\n\n.font-italic {\n font-style: italic;\n}\n\n.text-white {\n color: #fff !important;\n}\n\n.text-muted {\n color: #636c72 !important;\n}\n\na.text-muted:focus, a.text-muted:hover {\n color: #4b5257 !important;\n}\n\n.text-primary {\n color: #0275d8 !important;\n}\n\na.text-primary:focus, a.text-primary:hover {\n color: #025aa5 !important;\n}\n\n.text-success {\n color: #5cb85c !important;\n}\n\na.text-success:focus, a.text-success:hover {\n color: #449d44 !important;\n}\n\n.text-info {\n color: #5bc0de !important;\n}\n\na.text-info:focus, a.text-info:hover {\n color: #31b0d5 !important;\n}\n\n.text-warning {\n color: #f0ad4e !important;\n}\n\na.text-warning:focus, a.text-warning:hover {\n color: #ec971f !important;\n}\n\n.text-danger {\n color: #d9534f !important;\n}\n\na.text-danger:focus, a.text-danger:hover {\n color: #c9302c !important;\n}\n\n.text-gray-dark {\n color: #292b2c !important;\n}\n\na.text-gray-dark:focus, a.text-gray-dark:hover {\n color: #101112 !important;\n}\n\n.text-hide {\n font: 0/0 a;\n color: transparent;\n text-shadow: none;\n background-color: transparent;\n border: 0;\n}\n\n.invisible {\n visibility: hidden !important;\n}\n\n.hidden-xs-up {\n display: none !important;\n}\n\n@media (max-width: 575px) {\n .hidden-xs-down {\n display: none !important;\n }\n}\n\n@media (min-width: 576px) {\n .hidden-sm-up {\n display: none !important;\n }\n}\n\n@media (max-width: 767px) {\n .hidden-sm-down {\n display: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .hidden-md-up {\n display: none !important;\n }\n}\n\n@media (max-width: 991px) {\n .hidden-md-down {\n display: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .hidden-lg-up {\n display: none !important;\n }\n}\n\n@media (max-width: 1199px) {\n .hidden-lg-down {\n display: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .hidden-xl-up {\n display: none !important;\n }\n}\n\n.hidden-xl-down {\n display: none !important;\n}\n\n.visible-print-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-block {\n display: block !important;\n }\n}\n\n.visible-print-inline {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline {\n display: inline !important;\n }\n}\n\n.visible-print-inline-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline-block {\n display: inline-block !important;\n }\n}\n\n@media print {\n .hidden-print {\n display: none !important;\n }\n}", ""]); + // Don't get fooled by e.g. browserify environments. + if ({}.toString.call(global.process) === "[object process]") { + // For Node.js before 0.9 + installNextTickImplementation(); -// exports + } else if (canUsePostMessage()) { + // For non-IE10 modern browsers + installPostMessageImplementation(); + + } else if (global.MessageChannel) { + // For web workers, where supported + installMessageChannelImplementation(); + + } else if (doc && "onreadystatechange" in doc.createElement("script")) { + // For IE 6–8 + installReadyStateChangeImplementation(); + + } else { + // For older browsers + installSetTimeoutImplementation(); + } + + attachTo.setImmediate = setImmediate; + attachTo.clearImmediate = clearImmediate; +}(typeof self === "undefined" ? typeof global === "undefined" ? this : global : self)); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) /***/ }), -/* 119 */ -/***/ (function(module, exports) { +/* 370 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(global) { +/** + * Module exports. + */ +module.exports = deprecate; /** - * When source maps are enabled, `style-loader` uses a link element with a data-uri to - * embed the css on the page. This breaks all relative urls because now they are relative to a - * bundle instead of the current page. + * Mark that a method should not be used. + * Returns a modified function which warns once by default. * - * One solution is to only use full urls, but that may be impossible. + * If `localStorage.noDeprecation = true` is set, then it is a no-op. * - * Instead, this function "fixes" the relative urls to be absolute according to the current page location. + * If `localStorage.throwDeprecation = true` is set, then deprecated functions + * will throw an Error when invoked. * - * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command. + * If `localStorage.traceDeprecation = true` is set, then deprecated functions + * will invoke `console.trace()` instead of `console.error()`. * + * @param {Function} fn - the function to deprecate + * @param {String} msg - the string to print to the console when `fn` is invoked + * @returns {Function} a new "deprecated" version of `fn` + * @api public */ -module.exports = function (css) { - // get current location - var location = typeof window !== "undefined" && window.location; - - if (!location) { - throw new Error("fixUrls requires window.location"); +function deprecate (fn, msg) { + if (config('noDeprecation')) { + return fn; } - // blank or null? - if (!css || typeof css !== "string") { - return css; + var warned = false; + function deprecated() { + if (!warned) { + if (config('throwDeprecation')) { + throw new Error(msg); + } else if (config('traceDeprecation')) { + console.trace(msg); + } else { + console.warn(msg); + } + warned = true; + } + return fn.apply(this, arguments); } - var baseUrl = location.protocol + "//" + location.host; - var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/"); + return deprecated; +} - // convert each url(...) - /* - This regular expression is just a way to recursively match brackets within - a string. +/** + * Checks `localStorage` for boolean values for the given `name`. + * + * @param {String} name + * @returns {Boolean} + * @api private + */ - /url\s*\( = Match on the word "url" with any whitespace after it and then a parens - ( = Start a capturing group - (?: = Start a non-capturing group - [^)(] = Match anything that isn't a parentheses - | = OR - \( = Match a start parentheses - (?: = Start another non-capturing groups - [^)(]+ = Match anything that isn't a parentheses - | = OR - \( = Match a start parentheses - [^)(]* = Match anything that isn't a parentheses - \) = Match a end parentheses - ) = End Group - *\) = Match anything and then a close parens - ) = Close non-capturing group - * = Match anything - ) = Close capturing group - \) = Match a close parens +function config (name) { + // accessing global.localStorage can trigger a DOMException in sandboxed iframes + try { + if (!global.localStorage) return false; + } catch (_) { + return false; + } + var val = global.localStorage[name]; + if (null == val) return false; + return String(val).toLowerCase() === 'true'; +} - /gi = Get all matches, not the first. Be case insensitive. - */ - var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) { - // strip quotes (if they exist) - var unquotedOrigUrl = origUrl - .trim() - .replace(/^"(.*)"$/, function(o, $1){ return $1; }) - .replace(/^'(.*)'$/, function(o, $1){ return $1; }); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) - // already a full url? no change - if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(unquotedOrigUrl)) { - return fullMatch; - } +/***/ }), +/* 371 */ +/***/ (function(module, exports, __webpack_require__) { - // convert the url to a full url - var newUrl; +"use strict"; +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a passthrough stream. +// basically just the most minimal sort of Transform stream. +// Every written chunk gets output as-is. + + + +module.exports = PassThrough; + +var Transform = __webpack_require__(165); + +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ + +util.inherits(PassThrough, Transform); + +function PassThrough(options) { + if (!(this instanceof PassThrough)) return new PassThrough(options); + + Transform.call(this, options); +} - if (unquotedOrigUrl.indexOf("//") === 0) { - //TODO: should we add protocol? - newUrl = unquotedOrigUrl; - } else if (unquotedOrigUrl.indexOf("/") === 0) { - // path should be relative to the base url - newUrl = baseUrl + unquotedOrigUrl; // already starts with '/' - } else { - // path should be relative to current directory - newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './' - } +PassThrough.prototype._transform = function (chunk, encoding, cb) { + cb(null, chunk); +}; - // send back the fixed url(...) - return "url(" + JSON.stringify(newUrl) + ")"; - }); +/***/ }), +/* 372 */ +/***/ (function(module, exports, __webpack_require__) { - // send back the fixed css - return fixedCss; -}; +module.exports = __webpack_require__(101); /***/ }), -/* 120 */ +/* 373 */ /***/ (function(module, exports, __webpack_require__) { -// style-loader: Adds some css to the DOM by adding a <style> tag - -// load the styles -var content = __webpack_require__(121); -if(typeof content === 'string') content = [[module.i, content, '']]; -// Prepare cssTransformation -var transform; +module.exports = __webpack_require__(34); -var options = {} -options.transform = transform -// add the styles to the DOM -var update = __webpack_require__(73)(content, options); -if(content.locals) module.exports = content.locals; -// Hot Module Replacement -if(false) { - // When the styles change, update the <style> tags - if(!content.locals) { - module.hot.accept("!!../../css-loader/index.js!./react-bootstrap-table-all.min.css", function() { - var newContent = require("!!../../css-loader/index.js!./react-bootstrap-table-all.min.css"); - if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; - update(newContent); - }); - } - // When the module is disposed, remove the <style> tags - module.hot.dispose(function() { update(); }); -} /***/ }), -/* 121 */ +/* 374 */ /***/ (function(module, exports, __webpack_require__) { -exports = module.exports = __webpack_require__(72)(undefined); -// imports +module.exports = __webpack_require__(100).Transform -// module -exports.push([module.i, ".react-bs-table .react-bs-container-header .sort-column,.s-alert-close,td.react-bs-table-expand-cell{cursor:pointer}.react-bs-table-container .react-bs-table-search-form{margin-bottom:0}.react-bs-table-bordered{border:1px solid #ddd;border-radius:5px}.react-bs-table table{margin-bottom:0;table-layout:fixed}.react-bs-table table td,.react-bs-table table th{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.react-bs-table-pagination{margin-top:10px}.react-bs-table-tool-bar{margin-bottom:5px}.react-bs-container-header{overflow:hidden;width:100%}.react-bs-container-body{overflow:auto;width:100%}.react-bootstrap-table-page-btns-ul{float:right;margin-top:0}.react-bs-table .table-bordered{border:0;outline:0!important}.react-bs-table .table-bordered>thead>tr>td,.react-bs-table .table-bordered>thead>tr>th{border-bottom-width:2px}.react-bs-table .table-bordered>tbody>tr>td{outline:0!important}.react-bs-table .table-bordered>tbody>tr>td.default-focus-cell{outline:#6495ed solid 3px!important;outline-offset:-1px}.react-bs-table .table-bordered>tfoot>tr>td,.react-bs-table .table-bordered>tfoot>tr>th{border-top-width:2px;border-bottom-width:0}.react-bs-table .table-bordered>tbody>tr>td:first-child,.react-bs-table .table-bordered>tbody>tr>th:first-child,.react-bs-table .table-bordered>tfoot>tr>td:first-child,.react-bs-table .table-bordered>tfoot>tr>th:first-child,.react-bs-table .table-bordered>thead>tr>td:first-child,.react-bs-table .table-bordered>thead>tr>th:first-child{border-left-width:0}.react-bs-table .table-bordered>tbody>tr>td:last-child,.react-bs-table .table-bordered>tbody>tr>th:last-child,.react-bs-table .table-bordered>tfoot>tr>td:last-child,.react-bs-table .table-bordered>tfoot>tr>th:last-child,.react-bs-table .table-bordered>thead>tr>td:last-child,.react-bs-table .table-bordered>thead>tr>th:last-child{border-right-width:0}.react-bs-table .table-bordered>thead>tr:first-child>td,.react-bs-table .table-bordered>thead>tr:first-child>th{border-top-width:0}.react-bs-table .table-bordered>tfoot>tr:last-child>td,.react-bs-table .table-bordered>tfoot>tr:last-child>th{border-bottom-width:0}.react-bs-table .react-bs-container-header>table>thead>tr>th{vertical-align:middle}.react-bs-table .react-bs-container-header>table>thead>tr>th .filter{font-weight:400}.react-bs-table .react-bs-container-header>table>thead>tr>th .filter::-webkit-input-placeholder,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-input::-webkit-input-placeholder,.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter option[value=''],.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter.placeholder-selected{color:#d3d3d3;font-style:italic}.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter.placeholder-selected option:not([value='']){color:initial;font-style:initial}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter{display:flex}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter-input,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-input{margin-left:5px;float:left;width:calc(100% - 67px - 5px)}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter-comparator,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-comparator{width:67px;float:left}.react-bs-container .textarea-save-btn{position:absolute;z-index:100;right:0;top:-21px}.react-bs-table-no-data{text-align:center}.ReactModal__Overlay{-webkit-perspective:600;perspective:600;opacity:0;overflow-x:hidden;overflow-y:auto;background-color:rgba(0,0,0,.5);z-index:101}.ReactModal__Overlay--after-open{opacity:1;transition:opacity 150ms ease-out}.ReactModal__Content{-webkit-transform:scale(.5) rotateX(-30deg);transform:scale(.5) rotateX(-30deg)}.ReactModal__Content--after-open{-webkit-transform:scale(1) rotateX(0);transform:scale(1) rotateX(0);transition:all 150ms ease-in}.ReactModal__Overlay--before-close{opacity:0}.ReactModal__Content--before-close{-webkit-transform:scale(.5) rotateX(30deg);transform:scale(.5) rotateX(30deg);transition:all 150ms ease-in}.ReactModal__Content.modal-dialog{border:none;background-color:transparent}.animated{animation-fill-mode:both}.animated.bounceIn,.animated.bounceOut{animation-duration:.75s}.animated.shake{animation-duration:.3s}@keyframes shake{from,to{transform:translate3d(0,0,0)}10%,50%,90%{transform:translate3d(-10px,0,0)}30%,70%{transform:translate3d(10px,0,0)}}.shake{animation-name:shake}@keyframes bounceIn{20%,40%,60%,80%,from,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:scale3d(.3,.3,.3)}20%{transform:scale3d(1.1,1.1,1.1)}40%{transform:scale3d(.9,.9,.9)}60%{opacity:1;transform:scale3d(1.03,1.03,1.03)}80%{transform:scale3d(.97,.97,.97)}to{opacity:1;transform:scale3d(1,1,1)}}.bounceIn{animation-name:bounceIn}@keyframes bounceOut{20%{transform:scale3d(.9,.9,.9)}50%,55%{opacity:1;transform:scale3d(1.1,1.1,1.1)}to{opacity:0;transform:scale3d(.3,.3,.3)}}.bounceOut{animation-name:bounceOut}.s-alert-box,.s-alert-box *{box-sizing:border-box}.s-alert-box{position:fixed;background:rgba(42,45,50,.85);padding:22px;line-height:1.4;z-index:1000;pointer-events:none;color:rgba(250,251,255,.95);font-size:100%;font-family:'Helvetica Neue','Segoe UI',Helvetica,Arial,sans-serif;max-width:300px;-webkit-transition:top .4s,bottom .4s;transition:top .4s,bottom .4s}.s-alert-box.s-alert-show,.s-alert-box.s-alert-visible{pointer-events:auto}.s-alert-box a{color:inherit;opacity:.7;font-weight:700}.s-alert-box a:focus,.s-alert-box a:hover{opacity:1}.s-alert-box p{margin:0}.s-alert-close{width:20px;height:20px;position:absolute;right:4px;top:4px;overflow:hidden;text-indent:100%;-webkit-backface-visibility:hidden;backface-visibility:hidden}.s-alert-close:focus,.s-alert-close:hover{outline:0}.s-alert-close::after,.s-alert-close::before{content:'';position:absolute;width:3px;height:60%;top:50%;left:50%;background:#fff}.s-alert-close:hover::after,.s-alert-close:hover::before{background:#fff}.s-alert-close::before{-webkit-transform:translate(-50%,-50%) rotate(45deg);transform:translate(-50%,-50%) rotate(45deg)}.s-alert-close::after{-webkit-transform:translate(-50%,-50%) rotate(-45deg);transform:translate(-50%,-50%) rotate(-45deg)}.s-alert-bottom-left{top:auto;right:auto;bottom:30px;left:30px}.s-alert-top-left{top:30px;right:auto;bottom:auto;left:30px}.s-alert-top-right{top:30px;right:30px;bottom:auto;left:auto}.s-alert-bottom-right{top:auto;right:30px;bottom:30px;left:auto}.s-alert-bottom,.s-alert-top{width:100%;max-width:100%;left:0;right:0}.s-alert-bottom{bottom:0;top:auto}.s-alert-top{top:0;bottom:auto}.s-alert-info{background:#00A2D3;color:#fff}.s-alert-success{background:#27AE60;color:#fff}.s-alert-warning{background:#F1C40F;color:#fff}.s-alert-error{background:#E74C3C;color:#fff}[class*=\" s-alert-effect-\"].s-alert-hide,[class^=s-alert-effect-].s-alert-hide{-webkit-animation-direction:reverse;animation-direction:reverse}.s-alert-box-height{visibility:hidden;position:fixed}.s-alert-effect-scale a,.s-alert-effect-scale a:focus,.s-alert-effect-scale a:hover{color:#fff}.s-alert-effect-scale .s-alert-close::after,.s-alert-effect-scale .s-alert-close::before,.s-alert-effect-scale .s-alert-close:hover::after,.s-alert-effect-scale .s-alert-close:hover::before{background:#fff}.s-alert-effect-scale.s-alert-hide,.s-alert-effect-scale.s-alert-show{-webkit-animation-name:animScale;animation-name:animScale;-webkit-animation-duration:.25s;animation-duration:.25s}@-webkit-keyframes animScale{0%{opacity:0;-webkit-transform:translate3d(0,40px,0) scale3d(.1,.6,1)}100%{opacity:1;-webkit-transform:translate3d(0,0,0) scale3d(1,1,1)}}@keyframes animScale{0%{opacity:0;-webkit-transform:translate3d(0,40px,0) scale3d(.1,.6,1);transform:translate3d(0,40px,0) scale3d(.1,.6,1)}100%{opacity:1;-webkit-transform:translate3d(0,0,0) scale3d(1,1,1);transform:translate3d(0,0,0) scale3d(1,1,1)}}", ""]); +/***/ }), +/* 375 */ +/***/ (function(module, exports, __webpack_require__) { -// exports +module.exports = __webpack_require__(100).PassThrough /***/ }), -/* 122 */ +/* 376 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * +/* WEBPACK VAR INJECTION */(function(Buffer) {/* + * A JavaScript implementation of the Secure Hash Algorithm, SHA-0, as defined + * in FIPS PUB 180-1 + * This source code is derived from sha1.js of the same repository. + * The difference between SHA-0 and SHA-1 is just a bitwise rotate left + * operation was added. */ +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) +var K = [ + 0x5a827999, 0x6ed9eba1, 0x8f1bbcdc | 0, 0xca62c1d6 | 0 +] -var PooledClass = __webpack_require__(123); -var ReactElement = __webpack_require__(19); +var W = new Array(80) -var emptyFunction = __webpack_require__(12); -var traverseAllChildren = __webpack_require__(124); +function Sha () { + this.init() + this._w = W -var twoArgumentPooler = PooledClass.twoArgumentPooler; -var fourArgumentPooler = PooledClass.fourArgumentPooler; + Hash.call(this, 64, 56) +} -var userProvidedKeyEscapeRegex = /\/+/g; -function escapeUserProvidedKey(text) { - return ('' + text).replace(userProvidedKeyEscapeRegex, '$&/'); +inherits(Sha, Hash) + +Sha.prototype.init = function () { + this._a = 0x67452301 + this._b = 0xefcdab89 + this._c = 0x98badcfe + this._d = 0x10325476 + this._e = 0xc3d2e1f0 + + return this } -/** - * PooledClass representing the bookkeeping associated with performing a child - * traversal. Allows avoiding binding callbacks. - * - * @constructor ForEachBookKeeping - * @param {!function} forEachFunction Function to perform traversal with. - * @param {?*} forEachContext Context to perform context with. - */ -function ForEachBookKeeping(forEachFunction, forEachContext) { - this.func = forEachFunction; - this.context = forEachContext; - this.count = 0; +function rotl5 (num) { + return (num << 5) | (num >>> 27) } -ForEachBookKeeping.prototype.destructor = function () { - this.func = null; - this.context = null; - this.count = 0; -}; -PooledClass.addPoolingTo(ForEachBookKeeping, twoArgumentPooler); -function forEachSingleChild(bookKeeping, child, name) { - var func = bookKeeping.func, - context = bookKeeping.context; +function rotl30 (num) { + return (num << 30) | (num >>> 2) +} - func.call(context, child, bookKeeping.count++); +function ft (s, b, c, d) { + if (s === 0) return (b & c) | ((~b) & d) + if (s === 2) return (b & c) | (b & d) | (c & d) + return b ^ c ^ d } -/** - * Iterates through children that are typically specified as `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.foreach - * - * The provided forEachFunc(child, index) will be called for each - * leaf child. - * - * @param {?*} children Children tree container. - * @param {function(*, int)} forEachFunc - * @param {*} forEachContext Context for forEachContext. - */ -function forEachChildren(children, forEachFunc, forEachContext) { - if (children == null) { - return children; +Sha.prototype._update = function (M) { + var W = this._w + + var a = this._a | 0 + var b = this._b | 0 + var c = this._c | 0 + var d = this._d | 0 + var e = this._e | 0 + + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4) + for (; i < 80; ++i) W[i] = W[i - 3] ^ W[i - 8] ^ W[i - 14] ^ W[i - 16] + + for (var j = 0; j < 80; ++j) { + var s = ~~(j / 20) + var t = (rotl5(a) + ft(s, b, c, d) + e + W[j] + K[s]) | 0 + + e = d + d = c + c = rotl30(b) + b = a + a = t } - var traverseContext = ForEachBookKeeping.getPooled(forEachFunc, forEachContext); - traverseAllChildren(children, forEachSingleChild, traverseContext); - ForEachBookKeeping.release(traverseContext); + + this._a = (a + this._a) | 0 + this._b = (b + this._b) | 0 + this._c = (c + this._c) | 0 + this._d = (d + this._d) | 0 + this._e = (e + this._e) | 0 } -/** - * PooledClass representing the bookkeeping associated with performing a child - * mapping. Allows avoiding binding callbacks. - * - * @constructor MapBookKeeping - * @param {!*} mapResult Object containing the ordered map of results. - * @param {!function} mapFunction Function to perform mapping with. - * @param {?*} mapContext Context to perform mapping with. +Sha.prototype._hash = function () { + var H = new Buffer(20) + + H.writeInt32BE(this._a | 0, 0) + H.writeInt32BE(this._b | 0, 4) + H.writeInt32BE(this._c | 0, 8) + H.writeInt32BE(this._d | 0, 12) + H.writeInt32BE(this._e | 0, 16) + + return H +} + +module.exports = Sha + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 377 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/* + * A JavaScript implementation of the Secure Hash Algorithm, SHA-1, as defined + * in FIPS PUB 180-1 + * Version 2.1a Copyright Paul Johnston 2000 - 2002. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * Distributed under the BSD License + * See http://pajhome.org.uk/crypt/md5 for details. */ -function MapBookKeeping(mapResult, keyPrefix, mapFunction, mapContext) { - this.result = mapResult; - this.keyPrefix = keyPrefix; - this.func = mapFunction; - this.context = mapContext; - this.count = 0; + +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) + +var K = [ + 0x5a827999, 0x6ed9eba1, 0x8f1bbcdc | 0, 0xca62c1d6 | 0 +] + +var W = new Array(80) + +function Sha1 () { + this.init() + this._w = W + + Hash.call(this, 64, 56) } -MapBookKeeping.prototype.destructor = function () { - this.result = null; - this.keyPrefix = null; - this.func = null; - this.context = null; - this.count = 0; -}; -PooledClass.addPoolingTo(MapBookKeeping, fourArgumentPooler); -function mapSingleChildIntoContext(bookKeeping, child, childKey) { - var result = bookKeeping.result, - keyPrefix = bookKeeping.keyPrefix, - func = bookKeeping.func, - context = bookKeeping.context; +inherits(Sha1, Hash) +Sha1.prototype.init = function () { + this._a = 0x67452301 + this._b = 0xefcdab89 + this._c = 0x98badcfe + this._d = 0x10325476 + this._e = 0xc3d2e1f0 - var mappedChild = func.call(context, child, bookKeeping.count++); - if (Array.isArray(mappedChild)) { - mapIntoWithKeyPrefixInternal(mappedChild, result, childKey, emptyFunction.thatReturnsArgument); - } else if (mappedChild != null) { - if (ReactElement.isValidElement(mappedChild)) { - mappedChild = ReactElement.cloneAndReplaceKey(mappedChild, - // Keep both the (mapped) and old keys if they differ, just as - // traverseAllChildren used to do for objects as children - keyPrefix + (mappedChild.key && (!child || child.key !== mappedChild.key) ? escapeUserProvidedKey(mappedChild.key) + '/' : '') + childKey); - } - result.push(mappedChild); - } + return this } -function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) { - var escapedPrefix = ''; - if (prefix != null) { - escapedPrefix = escapeUserProvidedKey(prefix) + '/'; - } - var traverseContext = MapBookKeeping.getPooled(array, escapedPrefix, func, context); - traverseAllChildren(children, mapSingleChildIntoContext, traverseContext); - MapBookKeeping.release(traverseContext); +function rotl1 (num) { + return (num << 1) | (num >>> 31) } -/** - * Maps children that are typically specified as `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.map - * - * The provided mapFunction(child, key, index) will be called for each - * leaf child. - * - * @param {?*} children Children tree container. - * @param {function(*, int)} func The map function. - * @param {*} context Context for mapFunction. - * @return {object} Object containing the ordered map of results. - */ -function mapChildren(children, func, context) { - if (children == null) { - return children; +function rotl5 (num) { + return (num << 5) | (num >>> 27) +} + +function rotl30 (num) { + return (num << 30) | (num >>> 2) +} + +function ft (s, b, c, d) { + if (s === 0) return (b & c) | ((~b) & d) + if (s === 2) return (b & c) | (b & d) | (c & d) + return b ^ c ^ d +} + +Sha1.prototype._update = function (M) { + var W = this._w + + var a = this._a | 0 + var b = this._b | 0 + var c = this._c | 0 + var d = this._d | 0 + var e = this._e | 0 + + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4) + for (; i < 80; ++i) W[i] = rotl1(W[i - 3] ^ W[i - 8] ^ W[i - 14] ^ W[i - 16]) + + for (var j = 0; j < 80; ++j) { + var s = ~~(j / 20) + var t = (rotl5(a) + ft(s, b, c, d) + e + W[j] + K[s]) | 0 + + e = d + d = c + c = rotl30(b) + b = a + a = t } - var result = []; - mapIntoWithKeyPrefixInternal(children, result, null, func, context); - return result; + + this._a = (a + this._a) | 0 + this._b = (b + this._b) | 0 + this._c = (c + this._c) | 0 + this._d = (d + this._d) | 0 + this._e = (e + this._e) | 0 } -function forEachSingleChildDummy(traverseContext, child, name) { - return null; +Sha1.prototype._hash = function () { + var H = new Buffer(20) + + H.writeInt32BE(this._a | 0, 0) + H.writeInt32BE(this._b | 0, 4) + H.writeInt32BE(this._c | 0, 8) + H.writeInt32BE(this._d | 0, 12) + H.writeInt32BE(this._e | 0, 16) + + return H } -/** - * Count the number of children that are typically specified as - * `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.count +module.exports = Sha1 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 378 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {/** + * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined + * in FIPS 180-2 + * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet * - * @param {?*} children Children tree container. - * @return {number} The number of children. */ -function countChildren(children, context) { - return traverseAllChildren(children, forEachSingleChildDummy, null); + +var inherits = __webpack_require__(4) +var Sha256 = __webpack_require__(166) +var Hash = __webpack_require__(42) + +var W = new Array(64) + +function Sha224 () { + this.init() + + this._w = W // new Array(64) + + Hash.call(this, 64, 56) } -/** - * Flatten a children object (typically specified as `props.children`) and - * return an array with appropriately re-keyed children. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.toarray - */ -function toArray(children) { - var result = []; - mapIntoWithKeyPrefixInternal(children, result, null, emptyFunction.thatReturnsArgument); - return result; +inherits(Sha224, Sha256) + +Sha224.prototype.init = function () { + this._a = 0xc1059ed8 + this._b = 0x367cd507 + this._c = 0x3070dd17 + this._d = 0xf70e5939 + this._e = 0xffc00b31 + this._f = 0x68581511 + this._g = 0x64f98fa7 + this._h = 0xbefa4fa4 + + return this } -var ReactChildren = { - forEach: forEachChildren, - map: mapChildren, - mapIntoWithKeyPrefixInternal: mapIntoWithKeyPrefixInternal, - count: countChildren, - toArray: toArray -}; +Sha224.prototype._hash = function () { + var H = new Buffer(28) -module.exports = ReactChildren; + H.writeInt32BE(this._a, 0) + H.writeInt32BE(this._b, 4) + H.writeInt32BE(this._c, 8) + H.writeInt32BE(this._d, 12) + H.writeInt32BE(this._e, 16) + H.writeInt32BE(this._f, 20) + H.writeInt32BE(this._g, 24) + + return H +} + +module.exports = Sha224 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 123 */ +/* 379 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var inherits = __webpack_require__(4) +var SHA512 = __webpack_require__(167) +var Hash = __webpack_require__(42) + +var W = new Array(160) + +function Sha384 () { + this.init() + this._w = W + + Hash.call(this, 128, 112) +} + +inherits(Sha384, SHA512) + +Sha384.prototype.init = function () { + this._ah = 0xcbbb9d5d + this._bh = 0x629a292a + this._ch = 0x9159015a + this._dh = 0x152fecd8 + this._eh = 0x67332667 + this._fh = 0x8eb44a87 + this._gh = 0xdb0c2e0d + this._hh = 0x47b5481d + + this._al = 0xc1059ed8 + this._bl = 0x367cd507 + this._cl = 0x3070dd17 + this._dl = 0xf70e5939 + this._el = 0xffc00b31 + this._fl = 0x68581511 + this._gl = 0x64f98fa7 + this._hl = 0xbefa4fa4 + + return this +} + +Sha384.prototype._hash = function () { + var H = new Buffer(48) + + function writeInt64BE (h, l, offset) { + H.writeInt32BE(h, offset) + H.writeInt32BE(l, offset + 4) + } + + writeInt64BE(this._ah, this._al, 0) + writeInt64BE(this._bh, this._bl, 8) + writeInt64BE(this._ch, this._cl, 16) + writeInt64BE(this._dh, this._dl, 24) + writeInt64BE(this._eh, this._el, 32) + writeInt64BE(this._fh, this._fl, 40) + + return H +} + +module.exports = Sha384 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 380 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +"use strict"; + +var assert = __webpack_require__(381) +var der = __webpack_require__(382) +var messages = __webpack_require__(169) + +function initCompressedValue (value, defaultValue) { + if (value === undefined) return defaultValue + + assert.isBoolean(value, messages.COMPRESSED_TYPE_INVALID) + return value +} + +module.exports = function (secp256k1) { + return { + privateKeyVerify: function (privateKey) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + return privateKey.length === 32 && secp256k1.privateKeyVerify(privateKey) + }, + + privateKeyExport: function (privateKey, compressed) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + compressed = initCompressedValue(compressed, true) + var publicKey = secp256k1.privateKeyExport(privateKey, compressed) + + return der.privateKeyExport(privateKey, publicKey, compressed) + }, + + privateKeyImport: function (privateKey) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + + privateKey = der.privateKeyImport(privateKey) + if (privateKey && privateKey.length === 32 && secp256k1.privateKeyVerify(privateKey)) return privateKey + + throw new Error(messages.EC_PRIVATE_KEY_IMPORT_DER_FAIL) + }, + + privateKeyTweakAdd: function (privateKey, tweak) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + assert.isBuffer(tweak, messages.TWEAK_TYPE_INVALID) + assert.isBufferLength(tweak, 32, messages.TWEAK_LENGTH_INVALID) + + return secp256k1.privateKeyTweakAdd(privateKey, tweak) + }, + + privateKeyTweakMul: function (privateKey, tweak) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + assert.isBuffer(tweak, messages.TWEAK_TYPE_INVALID) + assert.isBufferLength(tweak, 32, messages.TWEAK_LENGTH_INVALID) + + return secp256k1.privateKeyTweakMul(privateKey, tweak) + }, + + publicKeyCreate: function (privateKey, compressed) { + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + compressed = initCompressedValue(compressed, true) + return secp256k1.publicKeyCreate(privateKey, compressed) + }, -var _prodInvariant = __webpack_require__(25); + publicKeyConvert: function (publicKey, compressed) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) -var invariant = __webpack_require__(1); + compressed = initCompressedValue(compressed, true) -/** - * Static poolers. Several custom versions for each potential number of - * arguments. A completely generic pooler is easy to implement, but would - * require accessing the `arguments` object. In each of these, `this` refers to - * the Class itself, not an instance. If any others are needed, simply add them - * here, or in their own files. - */ -var oneArgumentPooler = function (copyFieldsFrom) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, copyFieldsFrom); - return instance; - } else { - return new Klass(copyFieldsFrom); - } -}; + return secp256k1.publicKeyConvert(publicKey, compressed) + }, -var twoArgumentPooler = function (a1, a2) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2); - return instance; - } else { - return new Klass(a1, a2); - } -}; + publicKeyVerify: function (publicKey) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + return secp256k1.publicKeyVerify(publicKey) + }, -var threeArgumentPooler = function (a1, a2, a3) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3); - return instance; - } else { - return new Klass(a1, a2, a3); - } -}; + publicKeyTweakAdd: function (publicKey, tweak, compressed) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) -var fourArgumentPooler = function (a1, a2, a3, a4) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3, a4); - return instance; - } else { - return new Klass(a1, a2, a3, a4); - } -}; + assert.isBuffer(tweak, messages.TWEAK_TYPE_INVALID) + assert.isBufferLength(tweak, 32, messages.TWEAK_LENGTH_INVALID) -var standardReleaser = function (instance) { - var Klass = this; - !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; - instance.destructor(); - if (Klass.instancePool.length < Klass.poolSize) { - Klass.instancePool.push(instance); - } -}; + compressed = initCompressedValue(compressed, true) -var DEFAULT_POOL_SIZE = 10; -var DEFAULT_POOLER = oneArgumentPooler; + return secp256k1.publicKeyTweakAdd(publicKey, tweak, compressed) + }, -/** - * Augments `CopyConstructor` to be a poolable class, augmenting only the class - * itself (statically) not adding any prototypical fields. Any CopyConstructor - * you give this may have a `poolSize` property, and will look for a - * prototypical `destructor` on instances. - * - * @param {Function} CopyConstructor Constructor that can be used to reset. - * @param {Function} pooler Customizable pooler. - */ -var addPoolingTo = function (CopyConstructor, pooler) { - // Casting as any so that flow ignores the actual implementation and trusts - // it to match the type we declared - var NewKlass = CopyConstructor; - NewKlass.instancePool = []; - NewKlass.getPooled = pooler || DEFAULT_POOLER; - if (!NewKlass.poolSize) { - NewKlass.poolSize = DEFAULT_POOL_SIZE; - } - NewKlass.release = standardReleaser; - return NewKlass; -}; + publicKeyTweakMul: function (publicKey, tweak, compressed) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) -var PooledClass = { - addPoolingTo: addPoolingTo, - oneArgumentPooler: oneArgumentPooler, - twoArgumentPooler: twoArgumentPooler, - threeArgumentPooler: threeArgumentPooler, - fourArgumentPooler: fourArgumentPooler -}; + assert.isBuffer(tweak, messages.TWEAK_TYPE_INVALID) + assert.isBufferLength(tweak, 32, messages.TWEAK_LENGTH_INVALID) -module.exports = PooledClass; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + compressed = initCompressedValue(compressed, true) -/***/ }), -/* 124 */ -/***/ (function(module, exports, __webpack_require__) { + return secp256k1.publicKeyTweakMul(publicKey, tweak, compressed) + }, -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + publicKeyCombine: function (publicKeys, compressed) { + assert.isArray(publicKeys, messages.EC_PUBLIC_KEYS_TYPE_INVALID) + assert.isLengthGTZero(publicKeys, messages.EC_PUBLIC_KEYS_LENGTH_INVALID) + for (var i = 0; i < publicKeys.length; ++i) { + assert.isBuffer(publicKeys[i], messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKeys[i], 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + } + compressed = initCompressedValue(compressed, true) + return secp256k1.publicKeyCombine(publicKeys, compressed) + }, -var _prodInvariant = __webpack_require__(25); + signatureNormalize: function (signature) { + assert.isBuffer(signature, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isBufferLength(signature, 64, messages.ECDSA_SIGNATURE_LENGTH_INVALID) -var ReactCurrentOwner = __webpack_require__(14); -var REACT_ELEMENT_TYPE = __webpack_require__(76); + return secp256k1.signatureNormalize(signature) + }, -var getIteratorFn = __webpack_require__(77); -var invariant = __webpack_require__(1); -var KeyEscapeUtils = __webpack_require__(125); -var warning = __webpack_require__(2); + signatureExport: function (signature) { + assert.isBuffer(signature, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isBufferLength(signature, 64, messages.ECDSA_SIGNATURE_LENGTH_INVALID) -var SEPARATOR = '.'; -var SUBSEPARATOR = ':'; + var sigObj = secp256k1.signatureExport(signature) + return der.signatureExport(sigObj) + }, -/** - * This is inlined from ReactElement since this file is shared between - * isomorphic and renderers. We could extract this to a - * - */ + signatureImport: function (sig) { + assert.isBuffer(sig, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isLengthGTZero(sig, messages.ECDSA_SIGNATURE_LENGTH_INVALID) -/** - * TODO: Test that a single child and an array with one item have the same key - * pattern. - */ + var sigObj = der.signatureImport(sig) + if (sigObj) return secp256k1.signatureImport(sigObj) -var didWarnAboutMaps = false; + throw new Error(messages.ECDSA_SIGNATURE_PARSE_DER_FAIL) + }, -/** - * Generate a key string that identifies a component within a set. - * - * @param {*} component A component that could contain a manual key. - * @param {number} index Index that is used if a manual key is not provided. - * @return {string} - */ -function getComponentKey(component, index) { - // Do some typechecking here since we call this blindly. We want to ensure - // that we don't block potential future ES APIs. - if (component && typeof component === 'object' && component.key != null) { - // Explicit key - return KeyEscapeUtils.escape(component.key); - } - // Implicit key determined by the index in the set - return index.toString(36); -} + signatureImportLax: function (sig) { + assert.isBuffer(sig, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isLengthGTZero(sig, messages.ECDSA_SIGNATURE_LENGTH_INVALID) -/** - * @param {?*} children Children tree container. - * @param {!string} nameSoFar Name of the key path so far. - * @param {!function} callback Callback to invoke with each child found. - * @param {?*} traverseContext Used to pass information throughout the traversal - * process. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { - var type = typeof children; + var sigObj = der.signatureImportLax(sig) + if (sigObj) return secp256k1.signatureImport(sigObj) - if (type === 'undefined' || type === 'boolean') { - // All of the above are perceived as null. - children = null; - } + throw new Error(messages.ECDSA_SIGNATURE_PARSE_DER_FAIL) + }, - if (children === null || type === 'string' || type === 'number' || - // The following is inlined from ReactElement. This means we can optimize - // some checks. React Fiber also inlines this logic for similar purposes. - type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { - callback(traverseContext, children, - // If it's the only child, treat the name as if it was wrapped in an array - // so that it's consistent if the number of children grows. - nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); - return 1; - } + sign: function (message, privateKey, options) { + assert.isBuffer(message, messages.MSG32_TYPE_INVALID) + assert.isBufferLength(message, 32, messages.MSG32_LENGTH_INVALID) - var child; - var nextName; - var subtreeCount = 0; // Count of children found in the current subtree. - var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) - if (Array.isArray(children)) { - for (var i = 0; i < children.length; i++) { - child = children[i]; - nextName = nextNamePrefix + getComponentKey(child, i); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - var iteratorFn = getIteratorFn(children); - if (iteratorFn) { - var iterator = iteratorFn.call(children); - var step; - if (iteratorFn !== children.entries) { - var ii = 0; - while (!(step = iterator.next()).done) { - child = step.value; - nextName = nextNamePrefix + getComponentKey(child, ii++); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - if (process.env.NODE_ENV !== 'production') { - var mapsAsChildrenAddendum = ''; - if (ReactCurrentOwner.current) { - var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); - if (mapsAsChildrenOwnerName) { - mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; - } - } - process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; - didWarnAboutMaps = true; - } - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - child = entry[1]; - nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } - } - } else if (type === 'object') { - var addendum = ''; - if (process.env.NODE_ENV !== 'production') { - addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; - if (children._isReactElement) { - addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; + var data = null + var noncefn = null + if (options !== undefined) { + assert.isObject(options, messages.OPTIONS_TYPE_INVALID) + + if (options.data !== undefined) { + assert.isBuffer(options.data, messages.OPTIONS_DATA_TYPE_INVALID) + assert.isBufferLength(options.data, 32, messages.OPTIONS_DATA_LENGTH_INVALID) + data = options.data } - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - addendum += ' Check the render method of `' + name + '`.'; - } + + if (options.noncefn !== undefined) { + assert.isFunction(options.noncefn, messages.OPTIONS_NONCEFN_TYPE_INVALID) + noncefn = options.noncefn } } - var childrenString = String(children); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; - } - } - return subtreeCount; -} + return secp256k1.sign(message, privateKey, noncefn, data) + }, -/** - * Traverses children that are typically specified as `props.children`, but - * might also be specified through attributes: - * - * - `traverseAllChildren(this.props.children, ...)` - * - `traverseAllChildren(this.props.leftPanelChildren, ...)` - * - * The `traverseContext` is an optional argument that is passed through the - * entire traversal. It can be used to store accumulations or anything else that - * the callback might find relevant. - * - * @param {?*} children Children tree object. - * @param {!function} callback To invoke upon traversing each child. - * @param {?*} traverseContext Context for traversal. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildren(children, callback, traverseContext) { - if (children == null) { - return 0; - } + verify: function (message, signature, publicKey) { + assert.isBuffer(message, messages.MSG32_TYPE_INVALID) + assert.isBufferLength(message, 32, messages.MSG32_LENGTH_INVALID) - return traverseAllChildrenImpl(children, '', callback, traverseContext); + assert.isBuffer(signature, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isBufferLength(signature, 64, messages.ECDSA_SIGNATURE_LENGTH_INVALID) + + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + return secp256k1.verify(message, signature, publicKey) + }, + + recover: function (message, signature, recovery, compressed) { + assert.isBuffer(message, messages.MSG32_TYPE_INVALID) + assert.isBufferLength(message, 32, messages.MSG32_LENGTH_INVALID) + + assert.isBuffer(signature, messages.ECDSA_SIGNATURE_TYPE_INVALID) + assert.isBufferLength(signature, 64, messages.ECDSA_SIGNATURE_LENGTH_INVALID) + + assert.isNumber(recovery, messages.RECOVERY_ID_TYPE_INVALID) + assert.isNumberInInterval(recovery, -1, 4, messages.RECOVERY_ID_VALUE_INVALID) + + compressed = initCompressedValue(compressed, true) + + return secp256k1.recover(message, signature, recovery, compressed) + }, + + ecdh: function (publicKey, privateKey) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + return secp256k1.ecdh(publicKey, privateKey) + }, + + ecdhUnsafe: function (publicKey, privateKey, compressed) { + assert.isBuffer(publicKey, messages.EC_PUBLIC_KEY_TYPE_INVALID) + assert.isBufferLength2(publicKey, 33, 65, messages.EC_PUBLIC_KEY_LENGTH_INVALID) + + assert.isBuffer(privateKey, messages.EC_PRIVATE_KEY_TYPE_INVALID) + assert.isBufferLength(privateKey, 32, messages.EC_PRIVATE_KEY_LENGTH_INVALID) + + compressed = initCompressedValue(compressed, true) + + return secp256k1.ecdhUnsafe(publicKey, privateKey, compressed) + } + } } -module.exports = traverseAllChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 125 */ +/* 381 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) { +var toString = Object.prototype.toString +// TypeError +exports.isArray = function (value, message) { + if (!Array.isArray(value)) throw TypeError(message) +} +exports.isBoolean = function (value, message) { + if (toString.call(value) !== '[object Boolean]') throw TypeError(message) +} -/** - * Escape and wrap key so it is safe to use as a reactid - * - * @param {string} key to be escaped. - * @return {string} the escaped key. - */ +exports.isBuffer = function (value, message) { + if (!Buffer.isBuffer(value)) throw TypeError(message) +} -function escape(key) { - var escapeRegex = /[=:]/g; - var escaperLookup = { - '=': '=0', - ':': '=2' - }; - var escapedString = ('' + key).replace(escapeRegex, function (match) { - return escaperLookup[match]; - }); +exports.isFunction = function (value, message) { + if (toString.call(value) !== '[object Function]') throw TypeError(message) +} - return '$' + escapedString; +exports.isNumber = function (value, message) { + if (toString.call(value) !== '[object Number]') throw TypeError(message) } -/** - * Unescape and unwrap key for human-readable display - * - * @param {string} key to unescape. - * @return {string} the unescaped key. - */ -function unescape(key) { - var unescapeRegex = /(=0|=2)/g; - var unescaperLookup = { - '=0': '=', - '=2': ':' - }; - var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); +exports.isObject = function (value, message) { + if (toString.call(value) !== '[object Object]') throw TypeError(message) +} - return ('' + keySubstring).replace(unescapeRegex, function (match) { - return unescaperLookup[match]; - }); +// RangeError +exports.isBufferLength = function (buffer, length, message) { + if (buffer.length !== length) throw RangeError(message) } -var KeyEscapeUtils = { - escape: escape, - unescape: unescape -}; +exports.isBufferLength2 = function (buffer, length1, length2, message) { + if (buffer.length !== length1 && buffer.length !== length2) throw RangeError(message) +} -module.exports = KeyEscapeUtils; +exports.isLengthGTZero = function (value, message) { + if (value.length === 0) throw RangeError(message) +} + +exports.isNumberInInterval = function (number, x, y, message) { + if (number <= x || number >= y) throw RangeError(message) +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 126 */ +/* 382 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Buffer = __webpack_require__(7).Buffer +var bip66 = __webpack_require__(104) + +var EC_PRIVKEY_EXPORT_DER_COMPRESSED = Buffer.from([ + // begin + 0x30, 0x81, 0xd3, 0x02, 0x01, 0x01, 0x04, 0x20, + // private key + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + // middle + 0xa0, 0x81, 0x85, 0x30, 0x81, 0x82, 0x02, 0x01, 0x01, 0x30, 0x2c, 0x06, 0x07, 0x2a, 0x86, 0x48, + 0xcE, 0x3d, 0x01, 0x01, 0x02, 0x21, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xfE, 0xff, 0xff, 0xfc, 0x2f, 0x30, 0x06, 0x04, 0x01, 0x00, 0x04, 0x01, 0x07, 0x04, + 0x21, 0x02, 0x79, 0xbE, 0x66, 0x7E, 0xf9, 0xdc, 0xbb, 0xac, 0x55, 0xa0, 0x62, 0x95, 0xcE, 0x87, + 0x0b, 0x07, 0x02, 0x9b, 0xfc, 0xdb, 0x2d, 0xcE, 0x28, 0xd9, 0x59, 0xf2, 0x81, 0x5b, 0x16, 0xf8, + 0x17, 0x98, 0x02, 0x21, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xfE, 0xba, 0xaE, 0xdc, 0xE6, 0xaf, 0x48, 0xa0, 0x3b, 0xbf, 0xd2, 0x5E, + 0x8c, 0xd0, 0x36, 0x41, 0x41, 0x02, 0x01, 0x01, 0xa1, 0x24, 0x03, 0x22, 0x00, + // public key + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00 +]) + +var EC_PRIVKEY_EXPORT_DER_UNCOMPRESSED = Buffer.from([ + // begin + 0x30, 0x82, 0x01, 0x13, 0x02, 0x01, 0x01, 0x04, 0x20, + // private key + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + // middle + 0xa0, 0x81, 0xa5, 0x30, 0x81, 0xa2, 0x02, 0x01, 0x01, 0x30, 0x2c, 0x06, 0x07, 0x2a, 0x86, 0x48, + 0xcE, 0x3d, 0x01, 0x01, 0x02, 0x21, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xfE, 0xff, 0xff, 0xfc, 0x2f, 0x30, 0x06, 0x04, 0x01, 0x00, 0x04, 0x01, 0x07, 0x04, + 0x41, 0x04, 0x79, 0xbE, 0x66, 0x7E, 0xf9, 0xdc, 0xbb, 0xac, 0x55, 0xa0, 0x62, 0x95, 0xcE, 0x87, + 0x0b, 0x07, 0x02, 0x9b, 0xfc, 0xdb, 0x2d, 0xcE, 0x28, 0xd9, 0x59, 0xf2, 0x81, 0x5b, 0x16, 0xf8, + 0x17, 0x98, 0x48, 0x3a, 0xda, 0x77, 0x26, 0xa3, 0xc4, 0x65, 0x5d, 0xa4, 0xfb, 0xfc, 0x0E, 0x11, + 0x08, 0xa8, 0xfd, 0x17, 0xb4, 0x48, 0xa6, 0x85, 0x54, 0x19, 0x9c, 0x47, 0xd0, 0x8f, 0xfb, 0x10, + 0xd4, 0xb8, 0x02, 0x21, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xfE, 0xba, 0xaE, 0xdc, 0xE6, 0xaf, 0x48, 0xa0, 0x3b, 0xbf, 0xd2, 0x5E, + 0x8c, 0xd0, 0x36, 0x41, 0x41, 0x02, 0x01, 0x01, 0xa1, 0x44, 0x03, 0x42, 0x00, + // public key + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00 +]) + +var ZERO_BUFFER_32 = Buffer.from([ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 +]) + +exports.privateKeyExport = function (privateKey, publicKey, compressed) { + var result = Buffer.from(compressed ? EC_PRIVKEY_EXPORT_DER_COMPRESSED : EC_PRIVKEY_EXPORT_DER_UNCOMPRESSED) + privateKey.copy(result, compressed ? 8 : 9) + publicKey.copy(result, compressed ? 181 : 214) + return result +} +exports.privateKeyImport = function (privateKey) { + var length = privateKey.length -var ReactElement = __webpack_require__(19); + // sequence header + var index = 0 + if (length < index + 1 || privateKey[index] !== 0x30) return + index += 1 -/** - * Create a factory that creates HTML tag elements. - * - * @private - */ -var createDOMFactory = ReactElement.createFactory; -if (process.env.NODE_ENV !== 'production') { - var ReactElementValidator = __webpack_require__(78); - createDOMFactory = ReactElementValidator.createFactory; + // sequence length constructor + if (length < index + 1 || !(privateKey[index] & 0x80)) return + + var lenb = privateKey[index] & 0x7f + index += 1 + if (lenb < 1 || lenb > 2) return + if (length < index + lenb) return + + // sequence length + var len = privateKey[index + lenb - 1] | (lenb > 1 ? privateKey[index + lenb - 2] << 8 : 0) + index += lenb + if (length < index + len) return + + // sequence element 0: version number (=1) + if (length < index + 3 || + privateKey[index] !== 0x02 || + privateKey[index + 1] !== 0x01 || + privateKey[index + 2] !== 0x01) { + return + } + index += 3 + + // sequence element 1: octet string, up to 32 bytes + if (length < index + 2 || + privateKey[index] !== 0x04 || + privateKey[index + 1] > 0x20 || + length < index + 2 + privateKey[index + 1]) { + return + } + + return privateKey.slice(index + 2, index + 2 + privateKey[index + 1]) } -/** - * Creates a mapping from supported HTML tags to `ReactDOMComponent` classes. - * - * @public - */ -var ReactDOMFactories = { - a: createDOMFactory('a'), - abbr: createDOMFactory('abbr'), - address: createDOMFactory('address'), - area: createDOMFactory('area'), - article: createDOMFactory('article'), - aside: createDOMFactory('aside'), - audio: createDOMFactory('audio'), - b: createDOMFactory('b'), - base: createDOMFactory('base'), - bdi: createDOMFactory('bdi'), - bdo: createDOMFactory('bdo'), - big: createDOMFactory('big'), - blockquote: createDOMFactory('blockquote'), - body: createDOMFactory('body'), - br: createDOMFactory('br'), - button: createDOMFactory('button'), - canvas: createDOMFactory('canvas'), - caption: createDOMFactory('caption'), - cite: createDOMFactory('cite'), - code: createDOMFactory('code'), - col: createDOMFactory('col'), - colgroup: createDOMFactory('colgroup'), - data: createDOMFactory('data'), - datalist: createDOMFactory('datalist'), - dd: createDOMFactory('dd'), - del: createDOMFactory('del'), - details: createDOMFactory('details'), - dfn: createDOMFactory('dfn'), - dialog: createDOMFactory('dialog'), - div: createDOMFactory('div'), - dl: createDOMFactory('dl'), - dt: createDOMFactory('dt'), - em: createDOMFactory('em'), - embed: createDOMFactory('embed'), - fieldset: createDOMFactory('fieldset'), - figcaption: createDOMFactory('figcaption'), - figure: createDOMFactory('figure'), - footer: createDOMFactory('footer'), - form: createDOMFactory('form'), - h1: createDOMFactory('h1'), - h2: createDOMFactory('h2'), - h3: createDOMFactory('h3'), - h4: createDOMFactory('h4'), - h5: createDOMFactory('h5'), - h6: createDOMFactory('h6'), - head: createDOMFactory('head'), - header: createDOMFactory('header'), - hgroup: createDOMFactory('hgroup'), - hr: createDOMFactory('hr'), - html: createDOMFactory('html'), - i: createDOMFactory('i'), - iframe: createDOMFactory('iframe'), - img: createDOMFactory('img'), - input: createDOMFactory('input'), - ins: createDOMFactory('ins'), - kbd: createDOMFactory('kbd'), - keygen: createDOMFactory('keygen'), - label: createDOMFactory('label'), - legend: createDOMFactory('legend'), - li: createDOMFactory('li'), - link: createDOMFactory('link'), - main: createDOMFactory('main'), - map: createDOMFactory('map'), - mark: createDOMFactory('mark'), - menu: createDOMFactory('menu'), - menuitem: createDOMFactory('menuitem'), - meta: createDOMFactory('meta'), - meter: createDOMFactory('meter'), - nav: createDOMFactory('nav'), - noscript: createDOMFactory('noscript'), - object: createDOMFactory('object'), - ol: createDOMFactory('ol'), - optgroup: createDOMFactory('optgroup'), - option: createDOMFactory('option'), - output: createDOMFactory('output'), - p: createDOMFactory('p'), - param: createDOMFactory('param'), - picture: createDOMFactory('picture'), - pre: createDOMFactory('pre'), - progress: createDOMFactory('progress'), - q: createDOMFactory('q'), - rp: createDOMFactory('rp'), - rt: createDOMFactory('rt'), - ruby: createDOMFactory('ruby'), - s: createDOMFactory('s'), - samp: createDOMFactory('samp'), - script: createDOMFactory('script'), - section: createDOMFactory('section'), - select: createDOMFactory('select'), - small: createDOMFactory('small'), - source: createDOMFactory('source'), - span: createDOMFactory('span'), - strong: createDOMFactory('strong'), - style: createDOMFactory('style'), - sub: createDOMFactory('sub'), - summary: createDOMFactory('summary'), - sup: createDOMFactory('sup'), - table: createDOMFactory('table'), - tbody: createDOMFactory('tbody'), - td: createDOMFactory('td'), - textarea: createDOMFactory('textarea'), - tfoot: createDOMFactory('tfoot'), - th: createDOMFactory('th'), - thead: createDOMFactory('thead'), - time: createDOMFactory('time'), - title: createDOMFactory('title'), - tr: createDOMFactory('tr'), - track: createDOMFactory('track'), - u: createDOMFactory('u'), - ul: createDOMFactory('ul'), - 'var': createDOMFactory('var'), - video: createDOMFactory('video'), - wbr: createDOMFactory('wbr'), +exports.signatureExport = function (sigObj) { + var r = Buffer.concat([Buffer.from([0]), sigObj.r]) + for (var lenR = 33, posR = 0; lenR > 1 && r[posR] === 0x00 && !(r[posR + 1] & 0x80); --lenR, ++posR); - // SVG - circle: createDOMFactory('circle'), - clipPath: createDOMFactory('clipPath'), - defs: createDOMFactory('defs'), - ellipse: createDOMFactory('ellipse'), - g: createDOMFactory('g'), - image: createDOMFactory('image'), - line: createDOMFactory('line'), - linearGradient: createDOMFactory('linearGradient'), - mask: createDOMFactory('mask'), - path: createDOMFactory('path'), - pattern: createDOMFactory('pattern'), - polygon: createDOMFactory('polygon'), - polyline: createDOMFactory('polyline'), - radialGradient: createDOMFactory('radialGradient'), - rect: createDOMFactory('rect'), - stop: createDOMFactory('stop'), - svg: createDOMFactory('svg'), - text: createDOMFactory('text'), - tspan: createDOMFactory('tspan') -}; + var s = Buffer.concat([Buffer.from([0]), sigObj.s]) + for (var lenS = 33, posS = 0; lenS > 1 && s[posS] === 0x00 && !(s[posS + 1] & 0x80); --lenS, ++posS); + + return bip66.encode(r.slice(posR), s.slice(posS)) +} + +exports.signatureImport = function (sig) { + var r = Buffer.from(ZERO_BUFFER_32) + var s = Buffer.from(ZERO_BUFFER_32) + + try { + var sigObj = bip66.decode(sig) + if (sigObj.r.length === 33 && sigObj.r[0] === 0x00) sigObj.r = sigObj.r.slice(1) + if (sigObj.r.length > 32) throw new Error('R length is too long') + if (sigObj.s.length === 33 && sigObj.s[0] === 0x00) sigObj.s = sigObj.s.slice(1) + if (sigObj.s.length > 32) throw new Error('S length is too long') + } catch (err) { + return + } + + sigObj.r.copy(r, 32 - sigObj.r.length) + sigObj.s.copy(s, 32 - sigObj.s.length) + + return { r: r, s: s } +} + +exports.signatureImportLax = function (sig) { + var r = Buffer.from(ZERO_BUFFER_32) + var s = Buffer.from(ZERO_BUFFER_32) + + var length = sig.length + var index = 0 + + // sequence tag byte + if (sig[index++] !== 0x30) return + + // sequence length byte + var lenbyte = sig[index++] + if (lenbyte & 0x80) { + index += lenbyte - 0x80 + if (index > length) return + } + + // sequence tag byte for r + if (sig[index++] !== 0x02) return + + // length for r + var rlen = sig[index++] + if (rlen & 0x80) { + lenbyte = rlen - 0x80 + if (index + lenbyte > length) return + for (; lenbyte > 0 && sig[index] === 0x00; index += 1, lenbyte -= 1); + for (rlen = 0; lenbyte > 0; index += 1, lenbyte -= 1) rlen = (rlen << 8) + sig[index] + } + if (rlen > length - index) return + var rindex = index + index += rlen + + // sequence tag byte for s + if (sig[index++] !== 0x02) return + + // length for s + var slen = sig[index++] + if (slen & 0x80) { + lenbyte = slen - 0x80 + if (index + lenbyte > length) return + for (; lenbyte > 0 && sig[index] === 0x00; index += 1, lenbyte -= 1); + for (slen = 0; lenbyte > 0; index += 1, lenbyte -= 1) slen = (slen << 8) + sig[index] + } + if (slen > length - index) return + var sindex = index + index += slen + + // ignore leading zeros in r + for (; rlen > 0 && sig[rindex] === 0x00; rlen -= 1, rindex += 1); + // copy r value + if (rlen > 32) return + var rvalue = sig.slice(rindex, rindex + rlen) + rvalue.copy(r, 32 - rvalue.length) + + // ignore leading zeros in s + for (; slen > 0 && sig[sindex] === 0x00; slen -= 1, sindex += 1); + // copy s value + if (slen > 32) return + var svalue = sig.slice(sindex, sindex + slen) + svalue.copy(s, 32 - svalue.length) + + return { r: r, s: s } +} -module.exports = ReactDOMFactories; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 127 */ +/* 383 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Buffer = __webpack_require__(7).Buffer +var createHash = __webpack_require__(27) +var BN = __webpack_require__(11) +var EC = __webpack_require__(15).ec +var messages = __webpack_require__(169) -var _prodInvariant = __webpack_require__(25); +var ec = new EC('secp256k1') +var ecparams = ec.curve -var ReactPropTypeLocationNames = __webpack_require__(128); -var ReactPropTypesSecret = __webpack_require__(129); +function loadCompressedPublicKey (first, xBuffer) { + var x = new BN(xBuffer) -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); + // overflow + if (x.cmp(ecparams.p) >= 0) return null + x = x.toRed(ecparams.red) -var ReactComponentTreeHook; + // compute corresponding Y + var y = x.redSqr().redIMul(x).redIAdd(ecparams.b).redSqrt() + if ((first === 0x03) !== y.isOdd()) y = y.redNeg() -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); + return ec.keyPair({ pub: { x: x, y: y } }) } -var loggedTypeFailures = {}; +function loadUncompressedPublicKey (first, xBuffer, yBuffer) { + var x = new BN(xBuffer) + var y = new BN(yBuffer) -/** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. - * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?object} element The React element that is being type-checked - * @param {?number} debugID The React component instance that is being type-checked - * @private - */ -function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; + // overflow + if (x.cmp(ecparams.p) >= 0 || y.cmp(ecparams.p) >= 0) return null - var componentStackInfo = ''; + x = x.toRed(ecparams.red) + y = y.toRed(ecparams.red) - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (debugID !== null) { - componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); - } else if (element !== null) { - componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); - } - } + // is odd flag + if ((first === 0x06 || first === 0x07) && y.isOdd() !== (first === 0x07)) return null - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; - } - } + // x*x*x + b = y*y + var x3 = x.redSqr().redIMul(x) + if (!y.redSqr().redISub(x3.redIAdd(ecparams.b)).isZero()) return null + + return ec.keyPair({ pub: { x: x, y: y } }) +} + +function loadPublicKey (publicKey) { + var first = publicKey[0] + switch (first) { + case 0x02: + case 0x03: + if (publicKey.length !== 33) return null + return loadCompressedPublicKey(first, publicKey.slice(1, 33)) + case 0x04: + case 0x06: + case 0x07: + if (publicKey.length !== 65) return null + return loadUncompressedPublicKey(first, publicKey.slice(1, 33), publicKey.slice(33, 65)) + default: + return null } } -module.exports = checkReactTypeSpec; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +exports.privateKeyVerify = function (privateKey) { + var bn = new BN(privateKey) + return bn.cmp(ecparams.n) < 0 && !bn.isZero() +} -/***/ }), -/* 128 */ -/***/ (function(module, exports, __webpack_require__) { +exports.privateKeyExport = function (privateKey, compressed) { + var d = new BN(privateKey) + if (d.cmp(ecparams.n) >= 0 || d.isZero()) throw new Error(messages.EC_PRIVATE_KEY_EXPORT_DER_FAIL) -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + return Buffer.from(ec.keyFromPrivate(privateKey).getPublic(compressed, true)) +} +exports.privateKeyTweakAdd = function (privateKey, tweak) { + var bn = new BN(tweak) + if (bn.cmp(ecparams.n) >= 0) throw new Error(messages.EC_PRIVATE_KEY_TWEAK_ADD_FAIL) + bn.iadd(new BN(privateKey)) + if (bn.cmp(ecparams.n) >= 0) bn.isub(ecparams.n) + if (bn.isZero()) throw new Error(messages.EC_PRIVATE_KEY_TWEAK_ADD_FAIL) -var ReactPropTypeLocationNames = {}; + return bn.toArrayLike(Buffer, 'be', 32) +} -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' - }; +exports.privateKeyTweakMul = function (privateKey, tweak) { + var bn = new BN(tweak) + if (bn.cmp(ecparams.n) >= 0 || bn.isZero()) throw new Error(messages.EC_PRIVATE_KEY_TWEAK_MUL_FAIL) + + bn.imul(new BN(privateKey)) + if (bn.cmp(ecparams.n)) bn = bn.umod(ecparams.n) + + return bn.toArrayLike(Buffer, 'be', 32) } -module.exports = ReactPropTypeLocationNames; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +exports.publicKeyCreate = function (privateKey, compressed) { + var d = new BN(privateKey) + if (d.cmp(ecparams.n) >= 0 || d.isZero()) throw new Error(messages.EC_PUBLIC_KEY_CREATE_FAIL) -/***/ }), -/* 129 */ -/***/ (function(module, exports, __webpack_require__) { + return Buffer.from(ec.keyFromPrivate(privateKey).getPublic(compressed, true)) +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +exports.publicKeyConvert = function (publicKey, compressed) { + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + return Buffer.from(pair.getPublic(compressed, true)) +} +exports.publicKeyVerify = function (publicKey) { + return loadPublicKey(publicKey) !== null +} -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; +exports.publicKeyTweakAdd = function (publicKey, tweak, compressed) { + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) -module.exports = ReactPropTypesSecret; + tweak = new BN(tweak) + if (tweak.cmp(ecparams.n) >= 0) throw new Error(messages.EC_PUBLIC_KEY_TWEAK_ADD_FAIL) -/***/ }), -/* 130 */ -/***/ (function(module, exports, __webpack_require__) { + return Buffer.from(ecparams.g.mul(tweak).add(pair.pub).encode(true, compressed)) +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +exports.publicKeyTweakMul = function (publicKey, tweak, compressed) { + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + tweak = new BN(tweak) + if (tweak.cmp(ecparams.n) >= 0 || tweak.isZero()) throw new Error(messages.EC_PUBLIC_KEY_TWEAK_MUL_FAIL) + return Buffer.from(pair.pub.mul(tweak).encode(true, compressed)) +} -var _require = __webpack_require__(19), - isValidElement = _require.isValidElement; +exports.publicKeyCombine = function (publicKeys, compressed) { + var pairs = new Array(publicKeys.length) + for (var i = 0; i < publicKeys.length; ++i) { + pairs[i] = loadPublicKey(publicKeys[i]) + if (pairs[i] === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + } -var factory = __webpack_require__(79); + var point = pairs[0].pub + for (var j = 1; j < pairs.length; ++j) point = point.add(pairs[j].pub) + if (point.isInfinity()) throw new Error(messages.EC_PUBLIC_KEY_COMBINE_FAIL) -module.exports = factory(isValidElement); + return Buffer.from(point.encode(true, compressed)) +} -/***/ }), -/* 131 */ -/***/ (function(module, exports, __webpack_require__) { +exports.signatureNormalize = function (signature) { + var r = new BN(signature.slice(0, 32)) + var s = new BN(signature.slice(32, 64)) + if (r.cmp(ecparams.n) >= 0 || s.cmp(ecparams.n) >= 0) throw new Error(messages.ECDSA_SIGNATURE_PARSE_FAIL) -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ + var result = Buffer.from(signature) + if (s.cmp(ec.nh) === 1) ecparams.n.sub(s).toArrayLike(Buffer, 'be', 32).copy(result, 32) + return result +} +exports.signatureExport = function (signature) { + var r = signature.slice(0, 32) + var s = signature.slice(32, 64) + if (new BN(r).cmp(ecparams.n) >= 0 || new BN(s).cmp(ecparams.n) >= 0) throw new Error(messages.ECDSA_SIGNATURE_PARSE_FAIL) -if (process.env.NODE_ENV !== 'production') { - var invariant = __webpack_require__(1); - var warning = __webpack_require__(2); - var ReactPropTypesSecret = __webpack_require__(49); - var loggedTypeFailures = {}; + return { r: r, s: s } } -/** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. - * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?Function} getStack Returns the component stack. - * @private - */ -function checkPropTypes(typeSpecs, values, location, componentName, getStack) { - if (process.env.NODE_ENV !== 'production') { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - invariant(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', componentName || 'React class', location, typeSpecName); - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error); - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; +exports.signatureImport = function (sigObj) { + var r = new BN(sigObj.r) + if (r.cmp(ecparams.n) >= 0) r = new BN(0) - var stack = getStack ? getStack() : ''; + var s = new BN(sigObj.s) + if (s.cmp(ecparams.n) >= 0) s = new BN(0) - warning(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : ''); - } - } + return Buffer.concat([ + r.toArrayLike(Buffer, 'be', 32), + s.toArrayLike(Buffer, 'be', 32) + ]) +} + +exports.sign = function (message, privateKey, noncefn, data) { + if (typeof noncefn === 'function') { + var getNonce = noncefn + noncefn = function (counter) { + var nonce = getNonce(message, privateKey, null, data, counter) + if (!Buffer.isBuffer(nonce) || nonce.length !== 32) throw new Error(messages.ECDSA_SIGN_FAIL) + + return new BN(nonce) } } + + var d = new BN(privateKey) + if (d.cmp(ecparams.n) >= 0 || d.isZero()) throw new Error(messages.ECDSA_SIGN_FAIL) + + var result = ec.sign(message, privateKey, { canonical: true, k: noncefn, pers: data }) + return { + signature: Buffer.concat([ + result.r.toArrayLike(Buffer, 'be', 32), + result.s.toArrayLike(Buffer, 'be', 32) + ]), + recovery: result.recoveryParam + } } -module.exports = checkPropTypes; +exports.verify = function (message, signature, publicKey) { + var sigObj = {r: signature.slice(0, 32), s: signature.slice(32, 64)} + + var sigr = new BN(sigObj.r) + var sigs = new BN(sigObj.s) + if (sigr.cmp(ecparams.n) >= 0 || sigs.cmp(ecparams.n) >= 0) throw new Error(messages.ECDSA_SIGNATURE_PARSE_FAIL) + if (sigs.cmp(ec.nh) === 1 || sigr.isZero() || sigs.isZero()) return false + + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + + return ec.verify(message, sigObj, {x: pair.pub.x, y: pair.pub.y}) +} + +exports.recover = function (message, signature, recovery, compressed) { + var sigObj = {r: signature.slice(0, 32), s: signature.slice(32, 64)} + + var sigr = new BN(sigObj.r) + var sigs = new BN(sigObj.s) + if (sigr.cmp(ecparams.n) >= 0 || sigs.cmp(ecparams.n) >= 0) throw new Error(messages.ECDSA_SIGNATURE_PARSE_FAIL) + + try { + if (sigr.isZero() || sigs.isZero()) throw new Error() + + var point = ec.recoverPubKey(message, sigObj, recovery) + return Buffer.from(point.encode(true, compressed)) + } catch (err) { + throw new Error(messages.ECDSA_RECOVER_FAIL) + } +} + +exports.ecdh = function (publicKey, privateKey) { + var shared = exports.ecdhUnsafe(publicKey, privateKey, true) + return createHash('sha256').update(shared).digest() +} + +exports.ecdhUnsafe = function (publicKey, privateKey, compressed) { + var pair = loadPublicKey(publicKey) + if (pair === null) throw new Error(messages.EC_PUBLIC_KEY_PARSE_FAIL) + + var scalar = new BN(privateKey) + if (scalar.cmp(ecparams.n) >= 0 || scalar.isZero()) throw new Error(messages.ECDH_FAIL) + + return Buffer.from(pair.pub.mul(scalar).encode(true, compressed)) +} -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 132 */ -/***/ (function(module, exports, __webpack_require__) { +/* 384 */ +/***/ (function(module, exports) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = function(module) { + if(!module.webpackPolyfill) { + module.deprecate = function() {}; + module.paths = []; + // module.parent = undefined by default + if(!module.children) module.children = []; + Object.defineProperty(module, "loaded", { + enumerable: true, + get: function() { + return module.l; + } + }); + Object.defineProperty(module, "id", { + enumerable: true, + get: function() { + return module.i; + } + }); + module.webpackPolyfill = 1; + } + return module; +}; +/***/ }), +/* 385 */ +/***/ (function(module, exports) { -module.exports = '15.6.1'; +module.exports = { + "name": "elliptic", + "version": "6.4.0", + "description": "EC cryptography", + "main": "lib/elliptic.js", + "files": [ + "lib" + ], + "scripts": { + "jscs": "jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js", + "jshint": "jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js", + "lint": "npm run jscs && npm run jshint", + "unit": "istanbul test _mocha --reporter=spec test/index.js", + "test": "npm run lint && npm run unit", + "version": "grunt dist && git add dist/" + }, + "repository": { + "type": "git", + "url": "git@github.com:indutny/elliptic" + }, + "keywords": [ + "EC", + "Elliptic", + "curve", + "Cryptography" + ], + "author": "Fedor Indutny <fedor@indutny.com>", + "license": "MIT", + "bugs": { + "url": "https://github.com/indutny/elliptic/issues" + }, + "homepage": "https://github.com/indutny/elliptic", + "devDependencies": { + "brfs": "^1.4.3", + "coveralls": "^2.11.3", + "grunt": "^0.4.5", + "grunt-browserify": "^5.0.0", + "grunt-cli": "^1.2.0", + "grunt-contrib-connect": "^1.0.0", + "grunt-contrib-copy": "^1.0.0", + "grunt-contrib-uglify": "^1.0.1", + "grunt-mocha-istanbul": "^3.0.1", + "grunt-saucelabs": "^8.6.2", + "istanbul": "^0.4.2", + "jscs": "^2.9.0", + "jshint": "^2.6.0", + "mocha": "^2.1.0" + }, + "dependencies": { + "bn.js": "^4.4.0", + "brorand": "^1.0.1", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.0" + } +}; /***/ }), -/* 133 */ +/* 386 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var utils = exports; +var BN = __webpack_require__(11); +var minAssert = __webpack_require__(21); +var minUtils = __webpack_require__(170); + +utils.assert = minAssert; +utils.toArray = minUtils.toArray; +utils.zero2 = minUtils.zero2; +utils.toHex = minUtils.toHex; +utils.encode = minUtils.encode; + +// Represent num in a w-NAF form +function getNAF(num, w) { + var naf = []; + var ws = 1 << (w + 1); + var k = num.clone(); + while (k.cmpn(1) >= 0) { + var z; + if (k.isOdd()) { + var mod = k.andln(ws - 1); + if (mod > (ws >> 1) - 1) + z = (ws >> 1) - mod; + else + z = mod; + k.isubn(z); + } else { + z = 0; + } + naf.push(z); -var _require = __webpack_require__(74), - Component = _require.Component; + // Optimization, shift by word if possible + var shift = (k.cmpn(0) !== 0 && k.andln(ws - 1) === 0) ? (w + 1) : 1; + for (var i = 1; i < shift; i++) + naf.push(0); + k.iushrn(shift); + } -var _require2 = __webpack_require__(19), - isValidElement = _require2.isValidElement; + return naf; +} +utils.getNAF = getNAF; + +// Represent k1, k2 in a Joint Sparse Form +function getJSF(k1, k2) { + var jsf = [ + [], + [] + ]; + + k1 = k1.clone(); + k2 = k2.clone(); + var d1 = 0; + var d2 = 0; + while (k1.cmpn(-d1) > 0 || k2.cmpn(-d2) > 0) { + + // First phase + var m14 = (k1.andln(3) + d1) & 3; + var m24 = (k2.andln(3) + d2) & 3; + if (m14 === 3) + m14 = -1; + if (m24 === 3) + m24 = -1; + var u1; + if ((m14 & 1) === 0) { + u1 = 0; + } else { + var m8 = (k1.andln(7) + d1) & 7; + if ((m8 === 3 || m8 === 5) && m24 === 2) + u1 = -m14; + else + u1 = m14; + } + jsf[0].push(u1); + + var u2; + if ((m24 & 1) === 0) { + u2 = 0; + } else { + var m8 = (k2.andln(7) + d2) & 7; + if ((m8 === 3 || m8 === 5) && m14 === 2) + u2 = -m24; + else + u2 = m24; + } + jsf[1].push(u2); + + // Second phase + if (2 * d1 === u1 + 1) + d1 = 1 - d1; + if (2 * d2 === u2 + 1) + d2 = 1 - d2; + k1.iushrn(1); + k2.iushrn(1); + } + + return jsf; +} +utils.getJSF = getJSF; + +function cachedProperty(obj, name, computer) { + var key = '_' + name; + obj.prototype[name] = function cachedProperty() { + return this[key] !== undefined ? this[key] : + this[key] = computer.call(this); + }; +} +utils.cachedProperty = cachedProperty; + +function parseBytes(bytes) { + return typeof bytes === 'string' ? utils.toArray(bytes, 'hex') : + bytes; +} +utils.parseBytes = parseBytes; + +function intFromLE(bytes) { + return new BN(bytes, 'hex', 'le'); +} +utils.intFromLE = intFromLE; -var ReactNoopUpdateQueue = __webpack_require__(75); -var factory = __webpack_require__(113); -module.exports = factory(Component, isValidElement, ReactNoopUpdateQueue); /***/ }), -/* 134 */ +/* 387 */ +/***/ (function(module, exports) { + +/* (ignored) */ + +/***/ }), +/* 388 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ -var _prodInvariant = __webpack_require__(25); +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var getNAF = utils.getNAF; +var getJSF = utils.getJSF; +var assert = utils.assert; -var ReactElement = __webpack_require__(19); +function BaseCurve(type, conf) { + this.type = type; + this.p = new BN(conf.p, 16); -var invariant = __webpack_require__(1); + // Use Montgomery, when there is no fast reduction for the prime + this.red = conf.prime ? BN.red(conf.prime) : BN.mont(this.p); -/** - * Returns the first child in a collection of children and verifies that there - * is only one child in the collection. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.only - * - * The current implementation of this function assumes that a single child gets - * passed without a wrapper, but the purpose of this helper function is to - * abstract away the particular structure of children. - * - * @param {?object} children Child collection structure. - * @return {ReactElement} The first and only `ReactElement` contained in the - * structure. - */ -function onlyChild(children) { - !ReactElement.isValidElement(children) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React.Children.only expected to receive a single React element child.') : _prodInvariant('143') : void 0; - return children; + // Useful for many curves + this.zero = new BN(0).toRed(this.red); + this.one = new BN(1).toRed(this.red); + this.two = new BN(2).toRed(this.red); + + // Curve configuration, optional + this.n = conf.n && new BN(conf.n, 16); + this.g = conf.g && this.pointFromJSON(conf.g, conf.gRed); + + // Temporary arrays + this._wnafT1 = new Array(4); + this._wnafT2 = new Array(4); + this._wnafT3 = new Array(4); + this._wnafT4 = new Array(4); + + // Generalized Greg Maxwell's trick + var adjustCount = this.n && this.p.div(this.n); + if (!adjustCount || adjustCount.cmpn(100) > 0) { + this.redN = null; + } else { + this._maxwellTrick = true; + this.redN = this.n.toRed(this.red); + } } +module.exports = BaseCurve; + +BaseCurve.prototype.point = function point() { + throw new Error('Not implemented'); +}; + +BaseCurve.prototype.validate = function validate() { + throw new Error('Not implemented'); +}; + +BaseCurve.prototype._fixedNafMul = function _fixedNafMul(p, k) { + assert(p.precomputed); + var doubles = p._getDoubles(); + + var naf = getNAF(k, 1); + var I = (1 << (doubles.step + 1)) - (doubles.step % 2 === 0 ? 2 : 1); + I /= 3; + + // Translate into more windowed form + var repr = []; + for (var j = 0; j < naf.length; j += doubles.step) { + var nafW = 0; + for (var k = j + doubles.step - 1; k >= j; k--) + nafW = (nafW << 1) + naf[k]; + repr.push(nafW); + } + + var a = this.jpoint(null, null, null); + var b = this.jpoint(null, null, null); + for (var i = I; i > 0; i--) { + for (var j = 0; j < repr.length; j++) { + var nafW = repr[j]; + if (nafW === i) + b = b.mixedAdd(doubles.points[j]); + else if (nafW === -i) + b = b.mixedAdd(doubles.points[j].neg()); + } + a = a.add(b); + } + return a.toP(); +}; + +BaseCurve.prototype._wnafMul = function _wnafMul(p, k) { + var w = 4; + + // Precompute window + var nafPoints = p._getNAFPoints(w); + w = nafPoints.wnd; + var wnd = nafPoints.points; + + // Get NAF form + var naf = getNAF(k, w); + + // Add `this`*(N+1) for every w-NAF index + var acc = this.jpoint(null, null, null); + for (var i = naf.length - 1; i >= 0; i--) { + // Count zeroes + for (var k = 0; i >= 0 && naf[i] === 0; i--) + k++; + if (i >= 0) + k++; + acc = acc.dblp(k); + + if (i < 0) + break; + var z = naf[i]; + assert(z !== 0); + if (p.type === 'affine') { + // J +- P + if (z > 0) + acc = acc.mixedAdd(wnd[(z - 1) >> 1]); + else + acc = acc.mixedAdd(wnd[(-z - 1) >> 1].neg()); + } else { + // J +- J + if (z > 0) + acc = acc.add(wnd[(z - 1) >> 1]); + else + acc = acc.add(wnd[(-z - 1) >> 1].neg()); + } + } + return p.type === 'affine' ? acc.toP() : acc; +}; + +BaseCurve.prototype._wnafMulAdd = function _wnafMulAdd(defW, + points, + coeffs, + len, + jacobianResult) { + var wndWidth = this._wnafT1; + var wnd = this._wnafT2; + var naf = this._wnafT3; + + // Fill all arrays + var max = 0; + for (var i = 0; i < len; i++) { + var p = points[i]; + var nafPoints = p._getNAFPoints(defW); + wndWidth[i] = nafPoints.wnd; + wnd[i] = nafPoints.points; + } + + // Comb small window NAFs + for (var i = len - 1; i >= 1; i -= 2) { + var a = i - 1; + var b = i; + if (wndWidth[a] !== 1 || wndWidth[b] !== 1) { + naf[a] = getNAF(coeffs[a], wndWidth[a]); + naf[b] = getNAF(coeffs[b], wndWidth[b]); + max = Math.max(naf[a].length, max); + max = Math.max(naf[b].length, max); + continue; + } + + var comb = [ + points[a], /* 1 */ + null, /* 3 */ + null, /* 5 */ + points[b] /* 7 */ + ]; + + // Try to avoid Projective points, if possible + if (points[a].y.cmp(points[b].y) === 0) { + comb[1] = points[a].add(points[b]); + comb[2] = points[a].toJ().mixedAdd(points[b].neg()); + } else if (points[a].y.cmp(points[b].y.redNeg()) === 0) { + comb[1] = points[a].toJ().mixedAdd(points[b]); + comb[2] = points[a].add(points[b].neg()); + } else { + comb[1] = points[a].toJ().mixedAdd(points[b]); + comb[2] = points[a].toJ().mixedAdd(points[b].neg()); + } + + var index = [ + -3, /* -1 -1 */ + -1, /* -1 0 */ + -5, /* -1 1 */ + -7, /* 0 -1 */ + 0, /* 0 0 */ + 7, /* 0 1 */ + 5, /* 1 -1 */ + 1, /* 1 0 */ + 3 /* 1 1 */ + ]; + + var jsf = getJSF(coeffs[a], coeffs[b]); + max = Math.max(jsf[0].length, max); + naf[a] = new Array(max); + naf[b] = new Array(max); + for (var j = 0; j < max; j++) { + var ja = jsf[0][j] | 0; + var jb = jsf[1][j] | 0; + + naf[a][j] = index[(ja + 1) * 3 + (jb + 1)]; + naf[b][j] = 0; + wnd[a] = comb; + } + } + + var acc = this.jpoint(null, null, null); + var tmp = this._wnafT4; + for (var i = max; i >= 0; i--) { + var k = 0; + + while (i >= 0) { + var zero = true; + for (var j = 0; j < len; j++) { + tmp[j] = naf[j][i] | 0; + if (tmp[j] !== 0) + zero = false; + } + if (!zero) + break; + k++; + i--; + } + if (i >= 0) + k++; + acc = acc.dblp(k); + if (i < 0) + break; + + for (var j = 0; j < len; j++) { + var z = tmp[j]; + var p; + if (z === 0) + continue; + else if (z > 0) + p = wnd[j][(z - 1) >> 1]; + else if (z < 0) + p = wnd[j][(-z - 1) >> 1].neg(); + + if (p.type === 'affine') + acc = acc.mixedAdd(p); + else + acc = acc.add(p); + } + } + // Zeroify references + for (var i = 0; i < len; i++) + wnd[i] = null; + + if (jacobianResult) + return acc; + else + return acc.toP(); +}; + +function BasePoint(curve, type) { + this.curve = curve; + this.type = type; + this.precomputed = null; +} +BaseCurve.BasePoint = BasePoint; + +BasePoint.prototype.eq = function eq(/*other*/) { + throw new Error('Not implemented'); +}; + +BasePoint.prototype.validate = function validate() { + return this.curve.validate(this); +}; + +BaseCurve.prototype.decodePoint = function decodePoint(bytes, enc) { + bytes = utils.toArray(bytes, enc); + + var len = this.p.byteLength(); + + // uncompressed, hybrid-odd, hybrid-even + if ((bytes[0] === 0x04 || bytes[0] === 0x06 || bytes[0] === 0x07) && + bytes.length - 1 === 2 * len) { + if (bytes[0] === 0x06) + assert(bytes[bytes.length - 1] % 2 === 0); + else if (bytes[0] === 0x07) + assert(bytes[bytes.length - 1] % 2 === 1); + + var res = this.point(bytes.slice(1, 1 + len), + bytes.slice(1 + len, 1 + 2 * len)); + + return res; + } else if ((bytes[0] === 0x02 || bytes[0] === 0x03) && + bytes.length - 1 === len) { + return this.pointFromX(bytes.slice(1, 1 + len), bytes[0] === 0x03); + } + throw new Error('Unknown point format'); +}; + +BasePoint.prototype.encodeCompressed = function encodeCompressed(enc) { + return this.encode(enc, true); +}; + +BasePoint.prototype._encode = function _encode(compact) { + var len = this.curve.p.byteLength(); + var x = this.getX().toArray('be', len); + + if (compact) + return [ this.getY().isEven() ? 0x02 : 0x03 ].concat(x); + + return [ 0x04 ].concat(x, this.getY().toArray('be', len)) ; +}; + +BasePoint.prototype.encode = function encode(enc, compact) { + return utils.encode(this._encode(compact), enc); +}; + +BasePoint.prototype.precompute = function precompute(power) { + if (this.precomputed) + return this; + + var precomputed = { + doubles: null, + naf: null, + beta: null + }; + precomputed.naf = this._getNAFPoints(8); + precomputed.doubles = this._getDoubles(4, power); + precomputed.beta = this._getBeta(); + this.precomputed = precomputed; + + return this; +}; + +BasePoint.prototype._hasDoubles = function _hasDoubles(k) { + if (!this.precomputed) + return false; + + var doubles = this.precomputed.doubles; + if (!doubles) + return false; + + return doubles.points.length >= Math.ceil((k.bitLength() + 1) / doubles.step); +}; + +BasePoint.prototype._getDoubles = function _getDoubles(step, power) { + if (this.precomputed && this.precomputed.doubles) + return this.precomputed.doubles; + + var doubles = [ this ]; + var acc = this; + for (var i = 0; i < power; i += step) { + for (var j = 0; j < step; j++) + acc = acc.dbl(); + doubles.push(acc); + } + return { + step: step, + points: doubles + }; +}; + +BasePoint.prototype._getNAFPoints = function _getNAFPoints(wnd) { + if (this.precomputed && this.precomputed.naf) + return this.precomputed.naf; + + var res = [ this ]; + var max = (1 << wnd) - 1; + var dbl = max === 1 ? null : this.dbl(); + for (var i = 1; i < max; i++) + res[i] = res[i - 1].add(dbl); + return { + wnd: wnd, + points: res + }; +}; + +BasePoint.prototype._getBeta = function _getBeta() { + return null; +}; + +BasePoint.prototype.dblp = function dblp(k) { + var r = this; + for (var i = 0; i < k; i++) + r = r.dbl(); + return r; +}; -module.exports = onlyChild; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 135 */ +/* 389 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ -/* globals __REACT_DEVTOOLS_GLOBAL_HOOK__*/ +var curve = __webpack_require__(65); +var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); +var Base = curve.base; +var assert = elliptic.utils.assert; -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDefaultInjection = __webpack_require__(136); -var ReactMount = __webpack_require__(104); -var ReactReconciler = __webpack_require__(26); -var ReactUpdates = __webpack_require__(15); -var ReactVersion = __webpack_require__(214); +function ShortCurve(conf) { + Base.call(this, 'short', conf); -var findDOMNode = __webpack_require__(215); -var getHostComponentFromComposite = __webpack_require__(105); -var renderSubtreeIntoContainer = __webpack_require__(216); -var warning = __webpack_require__(2); + this.a = new BN(conf.a, 16).toRed(this.red); + this.b = new BN(conf.b, 16).toRed(this.red); + this.tinv = this.two.redInvm(); -ReactDefaultInjection.inject(); + this.zeroA = this.a.fromRed().cmpn(0) === 0; + this.threeA = this.a.fromRed().sub(this.p).cmpn(-3) === 0; -var ReactDOM = { - findDOMNode: findDOMNode, - render: ReactMount.render, - unmountComponentAtNode: ReactMount.unmountComponentAtNode, - version: ReactVersion, + // If the curve is endomorphic, precalculate beta and lambda + this.endo = this._getEndomorphism(conf); + this._endoWnafT1 = new Array(4); + this._endoWnafT2 = new Array(4); +} +inherits(ShortCurve, Base); +module.exports = ShortCurve; - /* eslint-disable camelcase */ - unstable_batchedUpdates: ReactUpdates.batchedUpdates, - unstable_renderSubtreeIntoContainer: renderSubtreeIntoContainer - /* eslint-enable camelcase */ +ShortCurve.prototype._getEndomorphism = function _getEndomorphism(conf) { + // No efficient endomorphism + if (!this.zeroA || !this.g || !this.n || this.p.modn(3) !== 1) + return; + + // Compute beta and lambda, that lambda * P = (beta * Px; Py) + var beta; + var lambda; + if (conf.beta) { + beta = new BN(conf.beta, 16).toRed(this.red); + } else { + var betas = this._getEndoRoots(this.p); + // Choose the smallest beta + beta = betas[0].cmp(betas[1]) < 0 ? betas[0] : betas[1]; + beta = beta.toRed(this.red); + } + if (conf.lambda) { + lambda = new BN(conf.lambda, 16); + } else { + // Choose the lambda that is matching selected beta + var lambdas = this._getEndoRoots(this.n); + if (this.g.mul(lambdas[0]).x.cmp(this.g.x.redMul(beta)) === 0) { + lambda = lambdas[0]; + } else { + lambda = lambdas[1]; + assert(this.g.mul(lambda).x.cmp(this.g.x.redMul(beta)) === 0); + } + } + + // Get basis vectors, used for balanced length-two representation + var basis; + if (conf.basis) { + basis = conf.basis.map(function(vec) { + return { + a: new BN(vec.a, 16), + b: new BN(vec.b, 16) + }; + }); + } else { + basis = this._getEndoBasis(lambda); + } + + return { + beta: beta, + lambda: lambda, + basis: basis + }; }; -// Inject the runtime into a devtools global hook regardless of browser. -// Allows for debugging when the hook is injected on the page. -if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject === 'function') { - __REACT_DEVTOOLS_GLOBAL_HOOK__.inject({ - ComponentTree: { - getClosestInstanceFromNode: ReactDOMComponentTree.getClosestInstanceFromNode, - getNodeFromInstance: function (inst) { - // inst is an internal instance (but could be a composite) - if (inst._renderedComponent) { - inst = getHostComponentFromComposite(inst); - } - if (inst) { - return ReactDOMComponentTree.getNodeFromInstance(inst); - } else { - return null; - } - } - }, - Mount: ReactMount, - Reconciler: ReactReconciler - }); -} +ShortCurve.prototype._getEndoRoots = function _getEndoRoots(num) { + // Find roots of for x^2 + x + 1 in F + // Root = (-1 +- Sqrt(-3)) / 2 + // + var red = num === this.p ? this.red : BN.mont(num); + var tinv = new BN(2).toRed(red).redInvm(); + var ntinv = tinv.redNeg(); -if (process.env.NODE_ENV !== 'production') { - var ExecutionEnvironment = __webpack_require__(8); - if (ExecutionEnvironment.canUseDOM && window.top === window.self) { - // First check if devtools is not installed - if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined') { - // If we're in Chrome or Firefox, provide a download link if not installed. - if (navigator.userAgent.indexOf('Chrome') > -1 && navigator.userAgent.indexOf('Edge') === -1 || navigator.userAgent.indexOf('Firefox') > -1) { - // Firefox does not have the issue with devtools loaded over file:// - var showFileUrlMessage = window.location.protocol.indexOf('http') === -1 && navigator.userAgent.indexOf('Firefox') === -1; - console.debug('Download the React DevTools ' + (showFileUrlMessage ? 'and use an HTTP server (instead of a file: URL) ' : '') + 'for a better development experience: ' + 'https://fb.me/react-devtools'); - } + var s = new BN(3).toRed(red).redNeg().redSqrt().redMul(tinv); + + var l1 = ntinv.redAdd(s).fromRed(); + var l2 = ntinv.redSub(s).fromRed(); + return [ l1, l2 ]; +}; + +ShortCurve.prototype._getEndoBasis = function _getEndoBasis(lambda) { + // aprxSqrt >= sqrt(this.n) + var aprxSqrt = this.n.ushrn(Math.floor(this.n.bitLength() / 2)); + + // 3.74 + // Run EGCD, until r(L + 1) < aprxSqrt + var u = lambda; + var v = this.n.clone(); + var x1 = new BN(1); + var y1 = new BN(0); + var x2 = new BN(0); + var y2 = new BN(1); + + // NOTE: all vectors are roots of: a + b * lambda = 0 (mod n) + var a0; + var b0; + // First vector + var a1; + var b1; + // Second vector + var a2; + var b2; + + var prevR; + var i = 0; + var r; + var x; + while (u.cmpn(0) !== 0) { + var q = v.div(u); + r = v.sub(q.mul(u)); + x = x2.sub(q.mul(x1)); + var y = y2.sub(q.mul(y1)); + + if (!a1 && r.cmp(aprxSqrt) < 0) { + a0 = prevR.neg(); + b0 = x1; + a1 = r.neg(); + b1 = x; + } else if (a1 && ++i === 2) { + break; } + prevR = r; - var testFunc = function testFn() {}; - process.env.NODE_ENV !== 'production' ? warning((testFunc.name || testFunc.toString()).indexOf('testFn') !== -1, "It looks like you're using a minified copy of the development build " + 'of React. When deploying React apps to production, make sure to use ' + 'the production build which skips development warnings and is faster. ' + 'See https://fb.me/react-minification for more details.') : void 0; + v = u; + u = r; + x2 = x1; + x1 = x; + y2 = y1; + y1 = y; + } + a2 = r.neg(); + b2 = x; - // If we're in IE8, check to see if we are in compatibility mode and provide - // information on preventing compatibility mode - var ieCompatibilityMode = document.documentMode && document.documentMode < 8; + var len1 = a1.sqr().add(b1.sqr()); + var len2 = a2.sqr().add(b2.sqr()); + if (len2.cmp(len1) >= 0) { + a2 = a0; + b2 = b0; + } - process.env.NODE_ENV !== 'production' ? warning(!ieCompatibilityMode, 'Internet Explorer is running in compatibility mode; please add the ' + 'following tag to your HTML to prevent this from happening: ' + '<meta http-equiv="X-UA-Compatible" content="IE=edge" />') : void 0; + // Normalize signs + if (a1.negative) { + a1 = a1.neg(); + b1 = b1.neg(); + } + if (a2.negative) { + a2 = a2.neg(); + b2 = b2.neg(); + } - var expectedFeatures = [ - // shims - Array.isArray, Array.prototype.every, Array.prototype.forEach, Array.prototype.indexOf, Array.prototype.map, Date.now, Function.prototype.bind, Object.keys, String.prototype.trim]; + return [ + { a: a1, b: b1 }, + { a: a2, b: b2 } + ]; +}; - for (var i = 0; i < expectedFeatures.length; i++) { - if (!expectedFeatures[i]) { - process.env.NODE_ENV !== 'production' ? warning(false, 'One or more ES5 shims expected by React are not available: ' + 'https://fb.me/react-warning-polyfills') : void 0; - break; - } +ShortCurve.prototype._endoSplit = function _endoSplit(k) { + var basis = this.endo.basis; + var v1 = basis[0]; + var v2 = basis[1]; + + var c1 = v2.b.mul(k).divRound(this.n); + var c2 = v1.b.neg().mul(k).divRound(this.n); + + var p1 = c1.mul(v1.a); + var p2 = c2.mul(v2.a); + var q1 = c1.mul(v1.b); + var q2 = c2.mul(v2.b); + + // Calculate answer + var k1 = k.sub(p1).sub(p2); + var k2 = q1.add(q2).neg(); + return { k1: k1, k2: k2 }; +}; + +ShortCurve.prototype.pointFromX = function pointFromX(x, odd) { + x = new BN(x, 16); + if (!x.red) + x = x.toRed(this.red); + + var y2 = x.redSqr().redMul(x).redIAdd(x.redMul(this.a)).redIAdd(this.b); + var y = y2.redSqrt(); + if (y.redSqr().redSub(y2).cmp(this.zero) !== 0) + throw new Error('invalid point'); + + // XXX Is there any way to tell if the number is odd without converting it + // to non-red form? + var isOdd = y.fromRed().isOdd(); + if (odd && !isOdd || !odd && isOdd) + y = y.redNeg(); + + return this.point(x, y); +}; + +ShortCurve.prototype.validate = function validate(point) { + if (point.inf) + return true; + + var x = point.x; + var y = point.y; + + var ax = this.a.redMul(x); + var rhs = x.redSqr().redMul(x).redIAdd(ax).redIAdd(this.b); + return y.redSqr().redISub(rhs).cmpn(0) === 0; +}; + +ShortCurve.prototype._endoWnafMulAdd = + function _endoWnafMulAdd(points, coeffs, jacobianResult) { + var npoints = this._endoWnafT1; + var ncoeffs = this._endoWnafT2; + for (var i = 0; i < points.length; i++) { + var split = this._endoSplit(coeffs[i]); + var p = points[i]; + var beta = p._getBeta(); + + if (split.k1.negative) { + split.k1.ineg(); + p = p.neg(true); + } + if (split.k2.negative) { + split.k2.ineg(); + beta = beta.neg(true); } + + npoints[i * 2] = p; + npoints[i * 2 + 1] = beta; + ncoeffs[i * 2] = split.k1; + ncoeffs[i * 2 + 1] = split.k2; } -} + var res = this._wnafMulAdd(1, npoints, ncoeffs, i * 2, jacobianResult); -if (process.env.NODE_ENV !== 'production') { - var ReactInstrumentation = __webpack_require__(13); - var ReactDOMUnknownPropertyHook = __webpack_require__(217); - var ReactDOMNullInputValuePropHook = __webpack_require__(218); - var ReactDOMInvalidARIAHook = __webpack_require__(219); + // Clean-up references to points and coefficients + for (var j = 0; j < i * 2; j++) { + npoints[j] = null; + ncoeffs[j] = null; + } + return res; +}; - ReactInstrumentation.debugTool.addHook(ReactDOMUnknownPropertyHook); - ReactInstrumentation.debugTool.addHook(ReactDOMNullInputValuePropHook); - ReactInstrumentation.debugTool.addHook(ReactDOMInvalidARIAHook); +function Point(curve, x, y, isRed) { + Base.BasePoint.call(this, curve, 'affine'); + if (x === null && y === null) { + this.x = null; + this.y = null; + this.inf = true; + } else { + this.x = new BN(x, 16); + this.y = new BN(y, 16); + // Force redgomery representation when loading from JSON + if (isRed) { + this.x.forceRed(this.curve.red); + this.y.forceRed(this.curve.red); + } + if (!this.x.red) + this.x = this.x.toRed(this.curve.red); + if (!this.y.red) + this.y = this.y.toRed(this.curve.red); + this.inf = false; + } } +inherits(Point, Base.BasePoint); -module.exports = ReactDOM; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +ShortCurve.prototype.point = function point(x, y, isRed) { + return new Point(this, x, y, isRed); +}; -/***/ }), -/* 136 */ -/***/ (function(module, exports, __webpack_require__) { +ShortCurve.prototype.pointFromJSON = function pointFromJSON(obj, red) { + return Point.fromJSON(this, obj, red); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Point.prototype._getBeta = function _getBeta() { + if (!this.curve.endo) + return; + + var pre = this.precomputed; + if (pre && pre.beta) + return pre.beta; + var beta = this.curve.point(this.x.redMul(this.curve.endo.beta), this.y); + if (pre) { + var curve = this.curve; + var endoMul = function(p) { + return curve.point(p.x.redMul(curve.endo.beta), p.y); + }; + pre.beta = beta; + beta.precomputed = { + beta: null, + naf: pre.naf && { + wnd: pre.naf.wnd, + points: pre.naf.points.map(endoMul) + }, + doubles: pre.doubles && { + step: pre.doubles.step, + points: pre.doubles.points.map(endoMul) + } + }; + } + return beta; +}; +Point.prototype.toJSON = function toJSON() { + if (!this.precomputed) + return [ this.x, this.y ]; -var ARIADOMPropertyConfig = __webpack_require__(137); -var BeforeInputEventPlugin = __webpack_require__(138); -var ChangeEventPlugin = __webpack_require__(142); -var DefaultEventPluginOrder = __webpack_require__(150); -var EnterLeaveEventPlugin = __webpack_require__(151); -var HTMLDOMPropertyConfig = __webpack_require__(152); -var ReactComponentBrowserEnvironment = __webpack_require__(153); -var ReactDOMComponent = __webpack_require__(159); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMEmptyComponent = __webpack_require__(185); -var ReactDOMTreeTraversal = __webpack_require__(186); -var ReactDOMTextComponent = __webpack_require__(187); -var ReactDefaultBatchingStrategy = __webpack_require__(188); -var ReactEventListener = __webpack_require__(189); -var ReactInjection = __webpack_require__(191); -var ReactReconcileTransaction = __webpack_require__(192); -var SVGDOMPropertyConfig = __webpack_require__(198); -var SelectEventPlugin = __webpack_require__(199); -var SimpleEventPlugin = __webpack_require__(200); + return [ this.x, this.y, this.precomputed && { + doubles: this.precomputed.doubles && { + step: this.precomputed.doubles.step, + points: this.precomputed.doubles.points.slice(1) + }, + naf: this.precomputed.naf && { + wnd: this.precomputed.naf.wnd, + points: this.precomputed.naf.points.slice(1) + } + } ]; +}; -var alreadyInjected = false; +Point.fromJSON = function fromJSON(curve, obj, red) { + if (typeof obj === 'string') + obj = JSON.parse(obj); + var res = curve.point(obj[0], obj[1], red); + if (!obj[2]) + return res; -function inject() { - if (alreadyInjected) { - // TODO: This is currently true because these injections are shared between - // the client and the server package. They should be built independently - // and not share any injection state. Then this problem will be solved. - return; + function obj2point(obj) { + return curve.point(obj[0], obj[1], red); } - alreadyInjected = true; - ReactInjection.EventEmitter.injectReactEventListener(ReactEventListener); + var pre = obj[2]; + res.precomputed = { + beta: null, + doubles: pre.doubles && { + step: pre.doubles.step, + points: [ res ].concat(pre.doubles.points.map(obj2point)) + }, + naf: pre.naf && { + wnd: pre.naf.wnd, + points: [ res ].concat(pre.naf.points.map(obj2point)) + } + }; + return res; +}; - /** - * Inject modules for resolving DOM hierarchy and plugin ordering. - */ - ReactInjection.EventPluginHub.injectEventPluginOrder(DefaultEventPluginOrder); - ReactInjection.EventPluginUtils.injectComponentTree(ReactDOMComponentTree); - ReactInjection.EventPluginUtils.injectTreeTraversal(ReactDOMTreeTraversal); +Point.prototype.inspect = function inspect() { + if (this.isInfinity()) + return '<EC Point Infinity>'; + return '<EC Point x: ' + this.x.fromRed().toString(16, 2) + + ' y: ' + this.y.fromRed().toString(16, 2) + '>'; +}; - /** - * Some important event plugins included by default (without having to require - * them). - */ - ReactInjection.EventPluginHub.injectEventPluginsByName({ - SimpleEventPlugin: SimpleEventPlugin, - EnterLeaveEventPlugin: EnterLeaveEventPlugin, - ChangeEventPlugin: ChangeEventPlugin, - SelectEventPlugin: SelectEventPlugin, - BeforeInputEventPlugin: BeforeInputEventPlugin - }); +Point.prototype.isInfinity = function isInfinity() { + return this.inf; +}; - ReactInjection.HostComponent.injectGenericComponentClass(ReactDOMComponent); +Point.prototype.add = function add(p) { + // O + P = P + if (this.inf) + return p; + + // P + O = P + if (p.inf) + return this; + + // P + P = 2P + if (this.eq(p)) + return this.dbl(); + + // P + (-P) = O + if (this.neg().eq(p)) + return this.curve.point(null, null); + + // P + Q = O + if (this.x.cmp(p.x) === 0) + return this.curve.point(null, null); + + var c = this.y.redSub(p.y); + if (c.cmpn(0) !== 0) + c = c.redMul(this.x.redSub(p.x).redInvm()); + var nx = c.redSqr().redISub(this.x).redISub(p.x); + var ny = c.redMul(this.x.redSub(nx)).redISub(this.y); + return this.curve.point(nx, ny); +}; - ReactInjection.HostComponent.injectTextComponentClass(ReactDOMTextComponent); +Point.prototype.dbl = function dbl() { + if (this.inf) + return this; - ReactInjection.DOMProperty.injectDOMPropertyConfig(ARIADOMPropertyConfig); - ReactInjection.DOMProperty.injectDOMPropertyConfig(HTMLDOMPropertyConfig); - ReactInjection.DOMProperty.injectDOMPropertyConfig(SVGDOMPropertyConfig); + // 2P = O + var ys1 = this.y.redAdd(this.y); + if (ys1.cmpn(0) === 0) + return this.curve.point(null, null); - ReactInjection.EmptyComponent.injectEmptyComponentFactory(function (instantiate) { - return new ReactDOMEmptyComponent(instantiate); - }); + var a = this.curve.a; - ReactInjection.Updates.injectReconcileTransaction(ReactReconcileTransaction); - ReactInjection.Updates.injectBatchingStrategy(ReactDefaultBatchingStrategy); + var x2 = this.x.redSqr(); + var dyinv = ys1.redInvm(); + var c = x2.redAdd(x2).redIAdd(x2).redIAdd(a).redMul(dyinv); - ReactInjection.Component.injectEnvironment(ReactComponentBrowserEnvironment); -} + var nx = c.redSqr().redISub(this.x.redAdd(this.x)); + var ny = c.redMul(this.x.redSub(nx)).redISub(this.y); + return this.curve.point(nx, ny); +}; -module.exports = { - inject: inject +Point.prototype.getX = function getX() { + return this.x.fromRed(); }; -/***/ }), -/* 137 */ -/***/ (function(module, exports, __webpack_require__) { +Point.prototype.getY = function getY() { + return this.y.fromRed(); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Point.prototype.mul = function mul(k) { + k = new BN(k, 16); + if (this._hasDoubles(k)) + return this.curve._fixedNafMul(this, k); + else if (this.curve.endo) + return this.curve._endoWnafMulAdd([ this ], [ k ]); + else + return this.curve._wnafMul(this, k); +}; +Point.prototype.mulAdd = function mulAdd(k1, p2, k2) { + var points = [ this, p2 ]; + var coeffs = [ k1, k2 ]; + if (this.curve.endo) + return this.curve._endoWnafMulAdd(points, coeffs); + else + return this.curve._wnafMulAdd(1, points, coeffs, 2); +}; -var ARIADOMPropertyConfig = { - Properties: { - // Global States and Properties - 'aria-current': 0, // state - 'aria-details': 0, - 'aria-disabled': 0, // state - 'aria-hidden': 0, // state - 'aria-invalid': 0, // state - 'aria-keyshortcuts': 0, - 'aria-label': 0, - 'aria-roledescription': 0, - // Widget Attributes - 'aria-autocomplete': 0, - 'aria-checked': 0, - 'aria-expanded': 0, - 'aria-haspopup': 0, - 'aria-level': 0, - 'aria-modal': 0, - 'aria-multiline': 0, - 'aria-multiselectable': 0, - 'aria-orientation': 0, - 'aria-placeholder': 0, - 'aria-pressed': 0, - 'aria-readonly': 0, - 'aria-required': 0, - 'aria-selected': 0, - 'aria-sort': 0, - 'aria-valuemax': 0, - 'aria-valuemin': 0, - 'aria-valuenow': 0, - 'aria-valuetext': 0, - // Live Region Attributes - 'aria-atomic': 0, - 'aria-busy': 0, - 'aria-live': 0, - 'aria-relevant': 0, - // Drag-and-Drop Attributes - 'aria-dropeffect': 0, - 'aria-grabbed': 0, - // Relationship Attributes - 'aria-activedescendant': 0, - 'aria-colcount': 0, - 'aria-colindex': 0, - 'aria-colspan': 0, - 'aria-controls': 0, - 'aria-describedby': 0, - 'aria-errormessage': 0, - 'aria-flowto': 0, - 'aria-labelledby': 0, - 'aria-owns': 0, - 'aria-posinset': 0, - 'aria-rowcount': 0, - 'aria-rowindex': 0, - 'aria-rowspan': 0, - 'aria-setsize': 0 - }, - DOMAttributeNames: {}, - DOMPropertyNames: {} +Point.prototype.jmulAdd = function jmulAdd(k1, p2, k2) { + var points = [ this, p2 ]; + var coeffs = [ k1, k2 ]; + if (this.curve.endo) + return this.curve._endoWnafMulAdd(points, coeffs, true); + else + return this.curve._wnafMulAdd(1, points, coeffs, 2, true); }; -module.exports = ARIADOMPropertyConfig; +Point.prototype.eq = function eq(p) { + return this === p || + this.inf === p.inf && + (this.inf || this.x.cmp(p.x) === 0 && this.y.cmp(p.y) === 0); +}; -/***/ }), -/* 138 */ -/***/ (function(module, exports, __webpack_require__) { +Point.prototype.neg = function neg(_precompute) { + if (this.inf) + return this; -"use strict"; -/** - * Copyright 2013-present Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var res = this.curve.point(this.x, this.y.redNeg()); + if (_precompute && this.precomputed) { + var pre = this.precomputed; + var negate = function(p) { + return p.neg(); + }; + res.precomputed = { + naf: pre.naf && { + wnd: pre.naf.wnd, + points: pre.naf.points.map(negate) + }, + doubles: pre.doubles && { + step: pre.doubles.step, + points: pre.doubles.points.map(negate) + } + }; + } + return res; +}; +Point.prototype.toJ = function toJ() { + if (this.inf) + return this.curve.jpoint(null, null, null); + var res = this.curve.jpoint(this.x, this.y, this.curve.one); + return res; +}; -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var FallbackCompositionState = __webpack_require__(139); -var SyntheticCompositionEvent = __webpack_require__(140); -var SyntheticInputEvent = __webpack_require__(141); +function JPoint(curve, x, y, z) { + Base.BasePoint.call(this, curve, 'jacobian'); + if (x === null && y === null && z === null) { + this.x = this.curve.one; + this.y = this.curve.one; + this.z = new BN(0); + } else { + this.x = new BN(x, 16); + this.y = new BN(y, 16); + this.z = new BN(z, 16); + } + if (!this.x.red) + this.x = this.x.toRed(this.curve.red); + if (!this.y.red) + this.y = this.y.toRed(this.curve.red); + if (!this.z.red) + this.z = this.z.toRed(this.curve.red); + + this.zOne = this.z === this.curve.one; +} +inherits(JPoint, Base.BasePoint); -var END_KEYCODES = [9, 13, 27, 32]; // Tab, Return, Esc, Space -var START_KEYCODE = 229; +ShortCurve.prototype.jpoint = function jpoint(x, y, z) { + return new JPoint(this, x, y, z); +}; -var canUseCompositionEvent = ExecutionEnvironment.canUseDOM && 'CompositionEvent' in window; +JPoint.prototype.toP = function toP() { + if (this.isInfinity()) + return this.curve.point(null, null); -var documentMode = null; -if (ExecutionEnvironment.canUseDOM && 'documentMode' in document) { - documentMode = document.documentMode; -} + var zinv = this.z.redInvm(); + var zinv2 = zinv.redSqr(); + var ax = this.x.redMul(zinv2); + var ay = this.y.redMul(zinv2).redMul(zinv); -// Webkit offers a very useful `textInput` event that can be used to -// directly represent `beforeInput`. The IE `textinput` event is not as -// useful, so we don't use it. -var canUseTextInputEvent = ExecutionEnvironment.canUseDOM && 'TextEvent' in window && !documentMode && !isPresto(); + return this.curve.point(ax, ay); +}; -// In IE9+, we have access to composition events, but the data supplied -// by the native compositionend event may be incorrect. Japanese ideographic -// spaces, for instance (\u3000) are not recorded correctly. -var useFallbackCompositionData = ExecutionEnvironment.canUseDOM && (!canUseCompositionEvent || documentMode && documentMode > 8 && documentMode <= 11); +JPoint.prototype.neg = function neg() { + return this.curve.jpoint(this.x, this.y.redNeg(), this.z); +}; -/** - * Opera <= 12 includes TextEvent in window, but does not fire - * text input events. Rely on keypress instead. - */ -function isPresto() { - var opera = window.opera; - return typeof opera === 'object' && typeof opera.version === 'function' && parseInt(opera.version(), 10) <= 12; -} +JPoint.prototype.add = function add(p) { + // O + P = P + if (this.isInfinity()) + return p; + + // P + O = P + if (p.isInfinity()) + return this; + + // 12M + 4S + 7A + var pz2 = p.z.redSqr(); + var z2 = this.z.redSqr(); + var u1 = this.x.redMul(pz2); + var u2 = p.x.redMul(z2); + var s1 = this.y.redMul(pz2.redMul(p.z)); + var s2 = p.y.redMul(z2.redMul(this.z)); + + var h = u1.redSub(u2); + var r = s1.redSub(s2); + if (h.cmpn(0) === 0) { + if (r.cmpn(0) !== 0) + return this.curve.jpoint(null, null, null); + else + return this.dbl(); + } + + var h2 = h.redSqr(); + var h3 = h2.redMul(h); + var v = u1.redMul(h2); + + var nx = r.redSqr().redIAdd(h3).redISub(v).redISub(v); + var ny = r.redMul(v.redISub(nx)).redISub(s1.redMul(h3)); + var nz = this.z.redMul(p.z).redMul(h); + + return this.curve.jpoint(nx, ny, nz); +}; -var SPACEBAR_CODE = 32; -var SPACEBAR_CHAR = String.fromCharCode(SPACEBAR_CODE); +JPoint.prototype.mixedAdd = function mixedAdd(p) { + // O + P = P + if (this.isInfinity()) + return p.toJ(); -// Events and their corresponding property names. -var eventTypes = { - beforeInput: { - phasedRegistrationNames: { - bubbled: 'onBeforeInput', - captured: 'onBeforeInputCapture' - }, - dependencies: ['topCompositionEnd', 'topKeyPress', 'topTextInput', 'topPaste'] - }, - compositionEnd: { - phasedRegistrationNames: { - bubbled: 'onCompositionEnd', - captured: 'onCompositionEndCapture' - }, - dependencies: ['topBlur', 'topCompositionEnd', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] - }, - compositionStart: { - phasedRegistrationNames: { - bubbled: 'onCompositionStart', - captured: 'onCompositionStartCapture' - }, - dependencies: ['topBlur', 'topCompositionStart', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] - }, - compositionUpdate: { - phasedRegistrationNames: { - bubbled: 'onCompositionUpdate', - captured: 'onCompositionUpdateCapture' - }, - dependencies: ['topBlur', 'topCompositionUpdate', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + // P + O = P + if (p.isInfinity()) + return this; + + // 8M + 3S + 7A + var z2 = this.z.redSqr(); + var u1 = this.x; + var u2 = p.x.redMul(z2); + var s1 = this.y; + var s2 = p.y.redMul(z2).redMul(this.z); + + var h = u1.redSub(u2); + var r = s1.redSub(s2); + if (h.cmpn(0) === 0) { + if (r.cmpn(0) !== 0) + return this.curve.jpoint(null, null, null); + else + return this.dbl(); } + + var h2 = h.redSqr(); + var h3 = h2.redMul(h); + var v = u1.redMul(h2); + + var nx = r.redSqr().redIAdd(h3).redISub(v).redISub(v); + var ny = r.redMul(v.redISub(nx)).redISub(s1.redMul(h3)); + var nz = this.z.redMul(h); + + return this.curve.jpoint(nx, ny, nz); }; -// Track whether we've ever handled a keypress on the space key. -var hasSpaceKeypress = false; +JPoint.prototype.dblp = function dblp(pow) { + if (pow === 0) + return this; + if (this.isInfinity()) + return this; + if (!pow) + return this.dbl(); + + if (this.curve.zeroA || this.curve.threeA) { + var r = this; + for (var i = 0; i < pow; i++) + r = r.dbl(); + return r; + } + + // 1M + 2S + 1A + N * (4S + 5M + 8A) + // N = 1 => 6M + 6S + 9A + var a = this.curve.a; + var tinv = this.curve.tinv; + + var jx = this.x; + var jy = this.y; + var jz = this.z; + var jz4 = jz.redSqr().redSqr(); + + // Reuse results + var jyd = jy.redAdd(jy); + for (var i = 0; i < pow; i++) { + var jx2 = jx.redSqr(); + var jyd2 = jyd.redSqr(); + var jyd4 = jyd2.redSqr(); + var c = jx2.redAdd(jx2).redIAdd(jx2).redIAdd(a.redMul(jz4)); + + var t1 = jx.redMul(jyd2); + var nx = c.redSqr().redISub(t1.redAdd(t1)); + var t2 = t1.redISub(nx); + var dny = c.redMul(t2); + dny = dny.redIAdd(dny).redISub(jyd4); + var nz = jyd.redMul(jz); + if (i + 1 < pow) + jz4 = jz4.redMul(jyd4); + + jx = nx; + jz = nz; + jyd = dny; + } + + return this.curve.jpoint(jx, jyd.redMul(tinv), jz); +}; -/** - * Return whether a native keypress event is assumed to be a command. - * This is required because Firefox fires `keypress` events for key commands - * (cut, copy, select-all, etc.) even though no character is inserted. - */ -function isKeypressCommand(nativeEvent) { - return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) && - // ctrlKey && altKey is equivalent to AltGr, and is not a command. - !(nativeEvent.ctrlKey && nativeEvent.altKey); -} +JPoint.prototype.dbl = function dbl() { + if (this.isInfinity()) + return this; -/** - * Translate native top level events into event types. - * - * @param {string} topLevelType - * @return {object} - */ -function getCompositionEventType(topLevelType) { - switch (topLevelType) { - case 'topCompositionStart': - return eventTypes.compositionStart; - case 'topCompositionEnd': - return eventTypes.compositionEnd; - case 'topCompositionUpdate': - return eventTypes.compositionUpdate; - } -} + if (this.curve.zeroA) + return this._zeroDbl(); + else if (this.curve.threeA) + return this._threeDbl(); + else + return this._dbl(); +}; -/** - * Does our fallback best-guess model think this event signifies that - * composition has begun? - * - * @param {string} topLevelType - * @param {object} nativeEvent - * @return {boolean} - */ -function isFallbackCompositionStart(topLevelType, nativeEvent) { - return topLevelType === 'topKeyDown' && nativeEvent.keyCode === START_KEYCODE; -} +JPoint.prototype._zeroDbl = function _zeroDbl() { + var nx; + var ny; + var nz; + // Z = 1 + if (this.zOne) { + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html + // #doubling-mdbl-2007-bl + // 1M + 5S + 14A + + // XX = X1^2 + var xx = this.x.redSqr(); + // YY = Y1^2 + var yy = this.y.redSqr(); + // YYYY = YY^2 + var yyyy = yy.redSqr(); + // S = 2 * ((X1 + YY)^2 - XX - YYYY) + var s = this.x.redAdd(yy).redSqr().redISub(xx).redISub(yyyy); + s = s.redIAdd(s); + // M = 3 * XX + a; a = 0 + var m = xx.redAdd(xx).redIAdd(xx); + // T = M ^ 2 - 2*S + var t = m.redSqr().redISub(s).redISub(s); + + // 8 * YYYY + var yyyy8 = yyyy.redIAdd(yyyy); + yyyy8 = yyyy8.redIAdd(yyyy8); + yyyy8 = yyyy8.redIAdd(yyyy8); + + // X3 = T + nx = t; + // Y3 = M * (S - T) - 8 * YYYY + ny = m.redMul(s.redISub(t)).redISub(yyyy8); + // Z3 = 2*Y1 + nz = this.y.redAdd(this.y); + } else { + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html + // #doubling-dbl-2009-l + // 2M + 5S + 13A + + // A = X1^2 + var a = this.x.redSqr(); + // B = Y1^2 + var b = this.y.redSqr(); + // C = B^2 + var c = b.redSqr(); + // D = 2 * ((X1 + B)^2 - A - C) + var d = this.x.redAdd(b).redSqr().redISub(a).redISub(c); + d = d.redIAdd(d); + // E = 3 * A + var e = a.redAdd(a).redIAdd(a); + // F = E^2 + var f = e.redSqr(); + + // 8 * C + var c8 = c.redIAdd(c); + c8 = c8.redIAdd(c8); + c8 = c8.redIAdd(c8); + + // X3 = F - 2 * D + nx = f.redISub(d).redISub(d); + // Y3 = E * (D - X3) - 8 * C + ny = e.redMul(d.redISub(nx)).redISub(c8); + // Z3 = 2 * Y1 * Z1 + nz = this.y.redMul(this.z); + nz = nz.redIAdd(nz); + } + + return this.curve.jpoint(nx, ny, nz); +}; -/** - * Does our fallback mode think that this event is the end of composition? - * - * @param {string} topLevelType - * @param {object} nativeEvent - * @return {boolean} - */ -function isFallbackCompositionEnd(topLevelType, nativeEvent) { - switch (topLevelType) { - case 'topKeyUp': - // Command keys insert or clear IME input. - return END_KEYCODES.indexOf(nativeEvent.keyCode) !== -1; - case 'topKeyDown': - // Expect IME keyCode on each keydown. If we get any other - // code we must have exited earlier. - return nativeEvent.keyCode !== START_KEYCODE; - case 'topKeyPress': - case 'topMouseDown': - case 'topBlur': - // Events are not possible without cancelling IME. - return true; - default: - return false; - } -} +JPoint.prototype._threeDbl = function _threeDbl() { + var nx; + var ny; + var nz; + // Z = 1 + if (this.zOne) { + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-3.html + // #doubling-mdbl-2007-bl + // 1M + 5S + 15A + + // XX = X1^2 + var xx = this.x.redSqr(); + // YY = Y1^2 + var yy = this.y.redSqr(); + // YYYY = YY^2 + var yyyy = yy.redSqr(); + // S = 2 * ((X1 + YY)^2 - XX - YYYY) + var s = this.x.redAdd(yy).redSqr().redISub(xx).redISub(yyyy); + s = s.redIAdd(s); + // M = 3 * XX + a + var m = xx.redAdd(xx).redIAdd(xx).redIAdd(this.curve.a); + // T = M^2 - 2 * S + var t = m.redSqr().redISub(s).redISub(s); + // X3 = T + nx = t; + // Y3 = M * (S - T) - 8 * YYYY + var yyyy8 = yyyy.redIAdd(yyyy); + yyyy8 = yyyy8.redIAdd(yyyy8); + yyyy8 = yyyy8.redIAdd(yyyy8); + ny = m.redMul(s.redISub(t)).redISub(yyyy8); + // Z3 = 2 * Y1 + nz = this.y.redAdd(this.y); + } else { + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-3.html#doubling-dbl-2001-b + // 3M + 5S + + // delta = Z1^2 + var delta = this.z.redSqr(); + // gamma = Y1^2 + var gamma = this.y.redSqr(); + // beta = X1 * gamma + var beta = this.x.redMul(gamma); + // alpha = 3 * (X1 - delta) * (X1 + delta) + var alpha = this.x.redSub(delta).redMul(this.x.redAdd(delta)); + alpha = alpha.redAdd(alpha).redIAdd(alpha); + // X3 = alpha^2 - 8 * beta + var beta4 = beta.redIAdd(beta); + beta4 = beta4.redIAdd(beta4); + var beta8 = beta4.redAdd(beta4); + nx = alpha.redSqr().redISub(beta8); + // Z3 = (Y1 + Z1)^2 - gamma - delta + nz = this.y.redAdd(this.z).redSqr().redISub(gamma).redISub(delta); + // Y3 = alpha * (4 * beta - X3) - 8 * gamma^2 + var ggamma8 = gamma.redSqr(); + ggamma8 = ggamma8.redIAdd(ggamma8); + ggamma8 = ggamma8.redIAdd(ggamma8); + ggamma8 = ggamma8.redIAdd(ggamma8); + ny = alpha.redMul(beta4.redISub(nx)).redISub(ggamma8); + } + + return this.curve.jpoint(nx, ny, nz); +}; -/** - * Google Input Tools provides composition data via a CustomEvent, - * with the `data` property populated in the `detail` object. If this - * is available on the event object, use it. If not, this is a plain - * composition event and we have nothing special to extract. - * - * @param {object} nativeEvent - * @return {?string} - */ -function getDataFromCustomEvent(nativeEvent) { - var detail = nativeEvent.detail; - if (typeof detail === 'object' && 'data' in detail) { - return detail.data; - } - return null; -} +JPoint.prototype._dbl = function _dbl() { + var a = this.curve.a; -// Track the current IME composition fallback object, if any. -var currentComposition = null; + // 4M + 6S + 10A + var jx = this.x; + var jy = this.y; + var jz = this.z; + var jz4 = jz.redSqr().redSqr(); -/** - * @return {?object} A SyntheticCompositionEvent. - */ -function extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var eventType; - var fallbackData; + var jx2 = jx.redSqr(); + var jy2 = jy.redSqr(); - if (canUseCompositionEvent) { - eventType = getCompositionEventType(topLevelType); - } else if (!currentComposition) { - if (isFallbackCompositionStart(topLevelType, nativeEvent)) { - eventType = eventTypes.compositionStart; - } - } else if (isFallbackCompositionEnd(topLevelType, nativeEvent)) { - eventType = eventTypes.compositionEnd; - } + var c = jx2.redAdd(jx2).redIAdd(jx2).redIAdd(a.redMul(jz4)); - if (!eventType) { - return null; - } + var jxd4 = jx.redAdd(jx); + jxd4 = jxd4.redIAdd(jxd4); + var t1 = jxd4.redMul(jy2); + var nx = c.redSqr().redISub(t1.redAdd(t1)); + var t2 = t1.redISub(nx); - if (useFallbackCompositionData) { - // The current composition is stored statically and must not be - // overwritten while composition continues. - if (!currentComposition && eventType === eventTypes.compositionStart) { - currentComposition = FallbackCompositionState.getPooled(nativeEventTarget); - } else if (eventType === eventTypes.compositionEnd) { - if (currentComposition) { - fallbackData = currentComposition.getData(); - } - } - } + var jyd8 = jy2.redSqr(); + jyd8 = jyd8.redIAdd(jyd8); + jyd8 = jyd8.redIAdd(jyd8); + jyd8 = jyd8.redIAdd(jyd8); + var ny = c.redMul(t2).redISub(jyd8); + var nz = jy.redAdd(jy).redMul(jz); - var event = SyntheticCompositionEvent.getPooled(eventType, targetInst, nativeEvent, nativeEventTarget); + return this.curve.jpoint(nx, ny, nz); +}; - if (fallbackData) { - // Inject data generated from fallback path into the synthetic event. - // This matches the property of native CompositionEventInterface. - event.data = fallbackData; - } else { - var customData = getDataFromCustomEvent(nativeEvent); - if (customData !== null) { - event.data = customData; - } - } +JPoint.prototype.trpl = function trpl() { + if (!this.curve.zeroA) + return this.dbl().add(this); + + // hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html#tripling-tpl-2007-bl + // 5M + 10S + ... + + // XX = X1^2 + var xx = this.x.redSqr(); + // YY = Y1^2 + var yy = this.y.redSqr(); + // ZZ = Z1^2 + var zz = this.z.redSqr(); + // YYYY = YY^2 + var yyyy = yy.redSqr(); + // M = 3 * XX + a * ZZ2; a = 0 + var m = xx.redAdd(xx).redIAdd(xx); + // MM = M^2 + var mm = m.redSqr(); + // E = 6 * ((X1 + YY)^2 - XX - YYYY) - MM + var e = this.x.redAdd(yy).redSqr().redISub(xx).redISub(yyyy); + e = e.redIAdd(e); + e = e.redAdd(e).redIAdd(e); + e = e.redISub(mm); + // EE = E^2 + var ee = e.redSqr(); + // T = 16*YYYY + var t = yyyy.redIAdd(yyyy); + t = t.redIAdd(t); + t = t.redIAdd(t); + t = t.redIAdd(t); + // U = (M + E)^2 - MM - EE - T + var u = m.redIAdd(e).redSqr().redISub(mm).redISub(ee).redISub(t); + // X3 = 4 * (X1 * EE - 4 * YY * U) + var yyu4 = yy.redMul(u); + yyu4 = yyu4.redIAdd(yyu4); + yyu4 = yyu4.redIAdd(yyu4); + var nx = this.x.redMul(ee).redISub(yyu4); + nx = nx.redIAdd(nx); + nx = nx.redIAdd(nx); + // Y3 = 8 * Y1 * (U * (T - U) - E * EE) + var ny = this.y.redMul(u.redMul(t.redISub(u)).redISub(e.redMul(ee))); + ny = ny.redIAdd(ny); + ny = ny.redIAdd(ny); + ny = ny.redIAdd(ny); + // Z3 = (Z1 + E)^2 - ZZ - EE + var nz = this.z.redAdd(e).redSqr().redISub(zz).redISub(ee); + + return this.curve.jpoint(nx, ny, nz); +}; - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; -} +JPoint.prototype.mul = function mul(k, kbase) { + k = new BN(k, kbase); -/** - * @param {string} topLevelType Record from `EventConstants`. - * @param {object} nativeEvent Native browser event. - * @return {?string} The string corresponding to this `beforeInput` event. - */ -function getNativeBeforeInputChars(topLevelType, nativeEvent) { - switch (topLevelType) { - case 'topCompositionEnd': - return getDataFromCustomEvent(nativeEvent); - case 'topKeyPress': - /** - * If native `textInput` events are available, our goal is to make - * use of them. However, there is a special case: the spacebar key. - * In Webkit, preventing default on a spacebar `textInput` event - * cancels character insertion, but it *also* causes the browser - * to fall back to its default spacebar behavior of scrolling the - * page. - * - * Tracking at: - * https://code.google.com/p/chromium/issues/detail?id=355103 - * - * To avoid this issue, use the keypress event as if no `textInput` - * event is available. - */ - var which = nativeEvent.which; - if (which !== SPACEBAR_CODE) { - return null; - } + return this.curve._wnafMul(this, k); +}; - hasSpaceKeypress = true; - return SPACEBAR_CHAR; +JPoint.prototype.eq = function eq(p) { + if (p.type === 'affine') + return this.eq(p.toJ()); - case 'topTextInput': - // Record the characters to be added to the DOM. - var chars = nativeEvent.data; + if (this === p) + return true; - // If it's a spacebar character, assume that we have already handled - // it at the keypress level and bail immediately. Android Chrome - // doesn't give us keycodes, so we need to blacklist it. - if (chars === SPACEBAR_CHAR && hasSpaceKeypress) { - return null; - } + // x1 * z2^2 == x2 * z1^2 + var z2 = this.z.redSqr(); + var pz2 = p.z.redSqr(); + if (this.x.redMul(pz2).redISub(p.x.redMul(z2)).cmpn(0) !== 0) + return false; - return chars; + // y1 * z2^3 == y2 * z1^3 + var z3 = z2.redMul(this.z); + var pz3 = pz2.redMul(p.z); + return this.y.redMul(pz3).redISub(p.y.redMul(z3)).cmpn(0) === 0; +}; - default: - // For other native event types, do nothing. - return null; - } -} +JPoint.prototype.eqXToP = function eqXToP(x) { + var zs = this.z.redSqr(); + var rx = x.toRed(this.curve.red).redMul(zs); + if (this.x.cmp(rx) === 0) + return true; -/** - * For browsers that do not provide the `textInput` event, extract the - * appropriate string to use for SyntheticInputEvent. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {object} nativeEvent Native browser event. - * @return {?string} The fallback string for this `beforeInput` event. - */ -function getFallbackBeforeInputChars(topLevelType, nativeEvent) { - // If we are currently composing (IME) and using a fallback to do so, - // try to extract the composed characters from the fallback object. - // If composition event is available, we extract a string only at - // compositionevent, otherwise extract it at fallback events. - if (currentComposition) { - if (topLevelType === 'topCompositionEnd' || !canUseCompositionEvent && isFallbackCompositionEnd(topLevelType, nativeEvent)) { - var chars = currentComposition.getData(); - FallbackCompositionState.release(currentComposition); - currentComposition = null; - return chars; - } - return null; - } + var xc = x.clone(); + var t = this.curve.redN.redMul(zs); + for (;;) { + xc.iadd(this.curve.n); + if (xc.cmp(this.curve.p) >= 0) + return false; - switch (topLevelType) { - case 'topPaste': - // If a paste event occurs after a keypress, throw out the input - // chars. Paste events should not lead to BeforeInput events. - return null; - case 'topKeyPress': - /** - * As of v27, Firefox may fire keypress events even when no character - * will be inserted. A few possibilities: - * - * - `which` is `0`. Arrow keys, Esc key, etc. - * - * - `which` is the pressed key code, but no char is available. - * Ex: 'AltGr + d` in Polish. There is no modified character for - * this key combination and no character is inserted into the - * document, but FF fires the keypress for char code `100` anyway. - * No `input` event will occur. - * - * - `which` is the pressed key code, but a command combination is - * being used. Ex: `Cmd+C`. No character is inserted, and no - * `input` event will occur. - */ - if (nativeEvent.which && !isKeypressCommand(nativeEvent)) { - return String.fromCharCode(nativeEvent.which); - } - return null; - case 'topCompositionEnd': - return useFallbackCompositionData ? null : nativeEvent.data; - default: - return null; + rx.redIAdd(t); + if (this.x.cmp(rx) === 0) + return true; } -} + return false; +}; -/** - * Extract a SyntheticInputEvent for `beforeInput`, based on either native - * `textInput` or fallback behavior. - * - * @return {?object} A SyntheticInputEvent. - */ -function extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var chars; +JPoint.prototype.inspect = function inspect() { + if (this.isInfinity()) + return '<EC JPoint Infinity>'; + return '<EC JPoint x: ' + this.x.toString(16, 2) + + ' y: ' + this.y.toString(16, 2) + + ' z: ' + this.z.toString(16, 2) + '>'; +}; - if (canUseTextInputEvent) { - chars = getNativeBeforeInputChars(topLevelType, nativeEvent); - } else { - chars = getFallbackBeforeInputChars(topLevelType, nativeEvent); - } +JPoint.prototype.isInfinity = function isInfinity() { + // XXX This code assumes that zero is always zero in red + return this.z.cmpn(0) === 0; +}; + + +/***/ }), +/* 390 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; - // If no characters are being inserted, no BeforeInput event should - // be fired. - if (!chars) { - return null; - } - var event = SyntheticInputEvent.getPooled(eventTypes.beforeInput, targetInst, nativeEvent, nativeEventTarget); +var curve = __webpack_require__(65); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); +var Base = curve.base; - event.data = chars; - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; + +function MontCurve(conf) { + Base.call(this, 'mont', conf); + + this.a = new BN(conf.a, 16).toRed(this.red); + this.b = new BN(conf.b, 16).toRed(this.red); + this.i4 = new BN(4).toRed(this.red).redInvm(); + this.two = new BN(2).toRed(this.red); + this.a24 = this.i4.redMul(this.a.redAdd(this.two)); } +inherits(MontCurve, Base); +module.exports = MontCurve; -/** - * Create an `onBeforeInput` event to match - * http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105/#events-inputevents. - * - * This event plugin is based on the native `textInput` event - * available in Chrome, Safari, Opera, and IE. This event fires after - * `onKeyPress` and `onCompositionEnd`, but before `onInput`. - * - * `beforeInput` is spec'd but not implemented in any browsers, and - * the `input` event does not provide any useful information about what has - * actually been added, contrary to the spec. Thus, `textInput` is the best - * available event to identify the characters that have actually been inserted - * into the target node. - * - * This plugin is also responsible for emitting `composition` events, thus - * allowing us to share composition fallback code for both `beforeInput` and - * `composition` event types. - */ -var BeforeInputEventPlugin = { - eventTypes: eventTypes, +MontCurve.prototype.validate = function validate(point) { + var x = point.normalize().x; + var x2 = x.redSqr(); + var rhs = x2.redMul(x).redAdd(x2.redMul(this.a)).redAdd(x); + var y = rhs.redSqrt(); - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - return [extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget), extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget)]; + return y.redSqr().cmp(rhs) === 0; +}; + +function Point(curve, x, z) { + Base.BasePoint.call(this, curve, 'projective'); + if (x === null && z === null) { + this.x = this.curve.one; + this.z = this.curve.zero; + } else { + this.x = new BN(x, 16); + this.z = new BN(z, 16); + if (!this.x.red) + this.x = this.x.toRed(this.curve.red); + if (!this.z.red) + this.z = this.z.toRed(this.curve.red); } +} +inherits(Point, Base.BasePoint); + +MontCurve.prototype.decodePoint = function decodePoint(bytes, enc) { + return this.point(utils.toArray(bytes, enc), 1); }; -module.exports = BeforeInputEventPlugin; +MontCurve.prototype.point = function point(x, z) { + return new Point(this, x, z); +}; -/***/ }), -/* 139 */ -/***/ (function(module, exports, __webpack_require__) { +MontCurve.prototype.pointFromJSON = function pointFromJSON(obj) { + return Point.fromJSON(this, obj); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Point.prototype.precompute = function precompute() { + // No-op +}; +Point.prototype._encode = function _encode() { + return this.getX().toArray('be', this.curve.p.byteLength()); +}; +Point.fromJSON = function fromJSON(curve, obj) { + return new Point(curve, obj[0], obj[1] || curve.one); +}; -var _assign = __webpack_require__(5); +Point.prototype.inspect = function inspect() { + if (this.isInfinity()) + return '<EC Point Infinity>'; + return '<EC Point x: ' + this.x.fromRed().toString(16, 2) + + ' z: ' + this.z.fromRed().toString(16, 2) + '>'; +}; -var PooledClass = __webpack_require__(20); +Point.prototype.isInfinity = function isInfinity() { + // XXX This code assumes that zero is always zero in red + return this.z.cmpn(0) === 0; +}; -var getTextContentAccessor = __webpack_require__(84); +Point.prototype.dbl = function dbl() { + // http://hyperelliptic.org/EFD/g1p/auto-montgom-xz.html#doubling-dbl-1987-m-3 + // 2M + 2S + 4A + + // A = X1 + Z1 + var a = this.x.redAdd(this.z); + // AA = A^2 + var aa = a.redSqr(); + // B = X1 - Z1 + var b = this.x.redSub(this.z); + // BB = B^2 + var bb = b.redSqr(); + // C = AA - BB + var c = aa.redSub(bb); + // X3 = AA * BB + var nx = aa.redMul(bb); + // Z3 = C * (BB + A24 * C) + var nz = c.redMul(bb.redAdd(this.curve.a24.redMul(c))); + return this.curve.point(nx, nz); +}; -/** - * This helper class stores information about text content of a target node, - * allowing comparison of content before and after a given event. - * - * Identify the node where selection currently begins, then observe - * both its text content and its current position in the DOM. Since the - * browser may natively replace the target node during composition, we can - * use its position to find its replacement. - * - * @param {DOMEventTarget} root - */ -function FallbackCompositionState(root) { - this._root = root; - this._startText = this.getText(); - this._fallbackText = null; -} +Point.prototype.add = function add() { + throw new Error('Not supported on Montgomery curve'); +}; -_assign(FallbackCompositionState.prototype, { - destructor: function () { - this._root = null; - this._startText = null; - this._fallbackText = null; - }, +Point.prototype.diffAdd = function diffAdd(p, diff) { + // http://hyperelliptic.org/EFD/g1p/auto-montgom-xz.html#diffadd-dadd-1987-m-3 + // 4M + 2S + 6A + + // A = X2 + Z2 + var a = this.x.redAdd(this.z); + // B = X2 - Z2 + var b = this.x.redSub(this.z); + // C = X3 + Z3 + var c = p.x.redAdd(p.z); + // D = X3 - Z3 + var d = p.x.redSub(p.z); + // DA = D * A + var da = d.redMul(a); + // CB = C * B + var cb = c.redMul(b); + // X5 = Z1 * (DA + CB)^2 + var nx = diff.z.redMul(da.redAdd(cb).redSqr()); + // Z5 = X1 * (DA - CB)^2 + var nz = diff.x.redMul(da.redISub(cb).redSqr()); + return this.curve.point(nx, nz); +}; - /** - * Get current text of input. - * - * @return {string} - */ - getText: function () { - if ('value' in this._root) { - return this._root.value; +Point.prototype.mul = function mul(k) { + var t = k.clone(); + var a = this; // (N / 2) * Q + Q + var b = this.curve.point(null, null); // (N / 2) * Q + var c = this; // Q + + for (var bits = []; t.cmpn(0) !== 0; t.iushrn(1)) + bits.push(t.andln(1)); + + for (var i = bits.length - 1; i >= 0; i--) { + if (bits[i] === 0) { + // N * Q + Q = ((N / 2) * Q + Q)) + (N / 2) * Q + a = a.diffAdd(b, c); + // N * Q = 2 * ((N / 2) * Q + Q)) + b = b.dbl(); + } else { + // N * Q = ((N / 2) * Q + Q) + ((N / 2) * Q) + b = a.diffAdd(b, c); + // N * Q + Q = 2 * ((N / 2) * Q + Q) + a = a.dbl(); } - return this._root[getTextContentAccessor()]; - }, + } + return b; +}; - /** - * Determine the differing substring between the initially stored - * text content and the current content. - * - * @return {string} - */ - getData: function () { - if (this._fallbackText) { - return this._fallbackText; - } +Point.prototype.mulAdd = function mulAdd() { + throw new Error('Not supported on Montgomery curve'); +}; - var start; - var startValue = this._startText; - var startLength = startValue.length; - var end; - var endValue = this.getText(); - var endLength = endValue.length; +Point.prototype.jumlAdd = function jumlAdd() { + throw new Error('Not supported on Montgomery curve'); +}; - for (start = 0; start < startLength; start++) { - if (startValue[start] !== endValue[start]) { - break; - } - } +Point.prototype.eq = function eq(other) { + return this.getX().cmp(other.getX()) === 0; +}; - var minEnd = startLength - start; - for (end = 1; end <= minEnd; end++) { - if (startValue[startLength - end] !== endValue[endLength - end]) { - break; - } - } +Point.prototype.normalize = function normalize() { + this.x = this.x.redMul(this.z.redInvm()); + this.z = this.curve.one; + return this; +}; - var sliceTail = end > 1 ? 1 - end : undefined; - this._fallbackText = endValue.slice(start, sliceTail); - return this._fallbackText; - } -}); +Point.prototype.getX = function getX() { + // Normalize coordinates + this.normalize(); -PooledClass.addPoolingTo(FallbackCompositionState); + return this.x.fromRed(); +}; -module.exports = FallbackCompositionState; /***/ }), -/* 140 */ +/* 391 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var curve = __webpack_require__(65); +var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); +var Base = curve.base; -var SyntheticEvent = __webpack_require__(16); +var assert = elliptic.utils.assert; -/** - * @interface Event - * @see http://www.w3.org/TR/DOM-Level-3-Events/#events-compositionevents - */ -var CompositionEventInterface = { - data: null -}; +function EdwardsCurve(conf) { + // NOTE: Important as we are creating point in Base.call() + this.twisted = (conf.a | 0) !== 1; + this.mOneA = this.twisted && (conf.a | 0) === -1; + this.extended = this.mOneA; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticCompositionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); + Base.call(this, 'edwards', conf); + + this.a = new BN(conf.a, 16).umod(this.red.m); + this.a = this.a.toRed(this.red); + this.c = new BN(conf.c, 16).toRed(this.red); + this.c2 = this.c.redSqr(); + this.d = new BN(conf.d, 16).toRed(this.red); + this.dd = this.d.redAdd(this.d); + + assert(!this.twisted || this.c.fromRed().cmpn(1) === 0); + this.oneC = (conf.c | 0) === 1; } +inherits(EdwardsCurve, Base); +module.exports = EdwardsCurve; + +EdwardsCurve.prototype._mulA = function _mulA(num) { + if (this.mOneA) + return num.redNeg(); + else + return this.a.redMul(num); +}; -SyntheticEvent.augmentClass(SyntheticCompositionEvent, CompositionEventInterface); +EdwardsCurve.prototype._mulC = function _mulC(num) { + if (this.oneC) + return num; + else + return this.c.redMul(num); +}; -module.exports = SyntheticCompositionEvent; +// Just for compatibility with Short curve +EdwardsCurve.prototype.jpoint = function jpoint(x, y, z, t) { + return this.point(x, y, z, t); +}; -/***/ }), -/* 141 */ -/***/ (function(module, exports, __webpack_require__) { +EdwardsCurve.prototype.pointFromX = function pointFromX(x, odd) { + x = new BN(x, 16); + if (!x.red) + x = x.toRed(this.red); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var x2 = x.redSqr(); + var rhs = this.c2.redSub(this.a.redMul(x2)); + var lhs = this.one.redSub(this.c2.redMul(this.d).redMul(x2)); + var y2 = rhs.redMul(lhs.redInvm()); + var y = y2.redSqrt(); + if (y.redSqr().redSub(y2).cmp(this.zero) !== 0) + throw new Error('invalid point'); + var isOdd = y.fromRed().isOdd(); + if (odd && !isOdd || !odd && isOdd) + y = y.redNeg(); -var SyntheticEvent = __webpack_require__(16); + return this.point(x, y); +}; -/** - * @interface Event - * @see http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105 - * /#events-inputevents - */ -var InputEventInterface = { - data: null +EdwardsCurve.prototype.pointFromY = function pointFromY(y, odd) { + y = new BN(y, 16); + if (!y.red) + y = y.toRed(this.red); + + // x^2 = (y^2 - 1) / (d y^2 + 1) + var y2 = y.redSqr(); + var lhs = y2.redSub(this.one); + var rhs = y2.redMul(this.d).redAdd(this.one); + var x2 = lhs.redMul(rhs.redInvm()); + + if (x2.cmp(this.zero) === 0) { + if (odd) + throw new Error('invalid point'); + else + return this.point(this.zero, y); + } + + var x = x2.redSqrt(); + if (x.redSqr().redSub(x2).cmp(this.zero) !== 0) + throw new Error('invalid point'); + + if (x.isOdd() !== odd) + x = x.redNeg(); + + return this.point(x, y); }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticInputEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +EdwardsCurve.prototype.validate = function validate(point) { + if (point.isInfinity()) + return true; + + // Curve: A * X^2 + Y^2 = C^2 * (1 + D * X^2 * Y^2) + point.normalize(); + + var x2 = point.x.redSqr(); + var y2 = point.y.redSqr(); + var lhs = x2.redMul(this.a).redAdd(y2); + var rhs = this.c2.redMul(this.one.redAdd(this.d.redMul(x2).redMul(y2))); + + return lhs.cmp(rhs) === 0; +}; + +function Point(curve, x, y, z, t) { + Base.BasePoint.call(this, curve, 'projective'); + if (x === null && y === null && z === null) { + this.x = this.curve.zero; + this.y = this.curve.one; + this.z = this.curve.one; + this.t = this.curve.zero; + this.zOne = true; + } else { + this.x = new BN(x, 16); + this.y = new BN(y, 16); + this.z = z ? new BN(z, 16) : this.curve.one; + this.t = t && new BN(t, 16); + if (!this.x.red) + this.x = this.x.toRed(this.curve.red); + if (!this.y.red) + this.y = this.y.toRed(this.curve.red); + if (!this.z.red) + this.z = this.z.toRed(this.curve.red); + if (this.t && !this.t.red) + this.t = this.t.toRed(this.curve.red); + this.zOne = this.z === this.curve.one; + + // Use extended coordinates + if (this.curve.extended && !this.t) { + this.t = this.x.redMul(this.y); + if (!this.zOne) + this.t = this.t.redMul(this.z.redInvm()); + } + } } +inherits(Point, Base.BasePoint); -SyntheticEvent.augmentClass(SyntheticInputEvent, InputEventInterface); +EdwardsCurve.prototype.pointFromJSON = function pointFromJSON(obj) { + return Point.fromJSON(this, obj); +}; -module.exports = SyntheticInputEvent; +EdwardsCurve.prototype.point = function point(x, y, z, t) { + return new Point(this, x, y, z, t); +}; -/***/ }), -/* 142 */ -/***/ (function(module, exports, __webpack_require__) { +Point.fromJSON = function fromJSON(curve, obj) { + return new Point(curve, obj[0], obj[1], obj[2]); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Point.prototype.inspect = function inspect() { + if (this.isInfinity()) + return '<EC Point Infinity>'; + return '<EC Point x: ' + this.x.fromRed().toString(16, 2) + + ' y: ' + this.y.fromRed().toString(16, 2) + + ' z: ' + this.z.fromRed().toString(16, 2) + '>'; +}; +Point.prototype.isInfinity = function isInfinity() { + // XXX This code assumes that zero is always zero in red + return this.x.cmpn(0) === 0 && + this.y.cmp(this.z) === 0; +}; +Point.prototype._extDbl = function _extDbl() { + // hyperelliptic.org/EFD/g1p/auto-twisted-extended-1.html + // #doubling-dbl-2008-hwcd + // 4M + 4S + + // A = X1^2 + var a = this.x.redSqr(); + // B = Y1^2 + var b = this.y.redSqr(); + // C = 2 * Z1^2 + var c = this.z.redSqr(); + c = c.redIAdd(c); + // D = a * A + var d = this.curve._mulA(a); + // E = (X1 + Y1)^2 - A - B + var e = this.x.redAdd(this.y).redSqr().redISub(a).redISub(b); + // G = D + B + var g = d.redAdd(b); + // F = G - C + var f = g.redSub(c); + // H = D - B + var h = d.redSub(b); + // X3 = E * F + var nx = e.redMul(f); + // Y3 = G * H + var ny = g.redMul(h); + // T3 = E * H + var nt = e.redMul(h); + // Z3 = F * G + var nz = f.redMul(g); + return this.curve.point(nx, ny, nz, nt); +}; -var EventPluginHub = __webpack_require__(32); -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); -var SyntheticEvent = __webpack_require__(16); +Point.prototype._projDbl = function _projDbl() { + // hyperelliptic.org/EFD/g1p/auto-twisted-projective.html + // #doubling-dbl-2008-bbjlp + // #doubling-dbl-2007-bl + // and others + // Generally 3M + 4S or 2M + 4S + + // B = (X1 + Y1)^2 + var b = this.x.redAdd(this.y).redSqr(); + // C = X1^2 + var c = this.x.redSqr(); + // D = Y1^2 + var d = this.y.redSqr(); + + var nx; + var ny; + var nz; + if (this.curve.twisted) { + // E = a * C + var e = this.curve._mulA(c); + // F = E + D + var f = e.redAdd(d); + if (this.zOne) { + // X3 = (B - C - D) * (F - 2) + nx = b.redSub(c).redSub(d).redMul(f.redSub(this.curve.two)); + // Y3 = F * (E - D) + ny = f.redMul(e.redSub(d)); + // Z3 = F^2 - 2 * F + nz = f.redSqr().redSub(f).redSub(f); + } else { + // H = Z1^2 + var h = this.z.redSqr(); + // J = F - 2 * H + var j = f.redSub(h).redISub(h); + // X3 = (B-C-D)*J + nx = b.redSub(c).redISub(d).redMul(j); + // Y3 = F * (E - D) + ny = f.redMul(e.redSub(d)); + // Z3 = F * J + nz = f.redMul(j); + } + } else { + // E = C + D + var e = c.redAdd(d); + // H = (c * Z1)^2 + var h = this.curve._mulC(this.c.redMul(this.z)).redSqr(); + // J = E - 2 * H + var j = e.redSub(h).redSub(h); + // X3 = c * (B - E) * J + nx = this.curve._mulC(b.redISub(e)).redMul(j); + // Y3 = c * E * (C - D) + ny = this.curve._mulC(e).redMul(c.redISub(d)); + // Z3 = E * J + nz = e.redMul(j); + } + return this.curve.point(nx, ny, nz); +}; -var inputValueTracking = __webpack_require__(87); -var getEventTarget = __webpack_require__(52); -var isEventSupported = __webpack_require__(53); -var isTextInputElement = __webpack_require__(88); +Point.prototype.dbl = function dbl() { + if (this.isInfinity()) + return this; -var eventTypes = { - change: { - phasedRegistrationNames: { - bubbled: 'onChange', - captured: 'onChangeCapture' - }, - dependencies: ['topBlur', 'topChange', 'topClick', 'topFocus', 'topInput', 'topKeyDown', 'topKeyUp', 'topSelectionChange'] + // Double in extended coordinates + if (this.curve.extended) + return this._extDbl(); + else + return this._projDbl(); +}; + +Point.prototype._extAdd = function _extAdd(p) { + // hyperelliptic.org/EFD/g1p/auto-twisted-extended-1.html + // #addition-add-2008-hwcd-3 + // 8M + + // A = (Y1 - X1) * (Y2 - X2) + var a = this.y.redSub(this.x).redMul(p.y.redSub(p.x)); + // B = (Y1 + X1) * (Y2 + X2) + var b = this.y.redAdd(this.x).redMul(p.y.redAdd(p.x)); + // C = T1 * k * T2 + var c = this.t.redMul(this.curve.dd).redMul(p.t); + // D = Z1 * 2 * Z2 + var d = this.z.redMul(p.z.redAdd(p.z)); + // E = B - A + var e = b.redSub(a); + // F = D - C + var f = d.redSub(c); + // G = D + C + var g = d.redAdd(c); + // H = B + A + var h = b.redAdd(a); + // X3 = E * F + var nx = e.redMul(f); + // Y3 = G * H + var ny = g.redMul(h); + // T3 = E * H + var nt = e.redMul(h); + // Z3 = F * G + var nz = f.redMul(g); + return this.curve.point(nx, ny, nz, nt); +}; + +Point.prototype._projAdd = function _projAdd(p) { + // hyperelliptic.org/EFD/g1p/auto-twisted-projective.html + // #addition-add-2008-bbjlp + // #addition-add-2007-bl + // 10M + 1S + + // A = Z1 * Z2 + var a = this.z.redMul(p.z); + // B = A^2 + var b = a.redSqr(); + // C = X1 * X2 + var c = this.x.redMul(p.x); + // D = Y1 * Y2 + var d = this.y.redMul(p.y); + // E = d * C * D + var e = this.curve.d.redMul(c).redMul(d); + // F = B - E + var f = b.redSub(e); + // G = B + E + var g = b.redAdd(e); + // X3 = A * F * ((X1 + Y1) * (X2 + Y2) - C - D) + var tmp = this.x.redAdd(this.y).redMul(p.x.redAdd(p.y)).redISub(c).redISub(d); + var nx = a.redMul(f).redMul(tmp); + var ny; + var nz; + if (this.curve.twisted) { + // Y3 = A * G * (D - a * C) + ny = a.redMul(g).redMul(d.redSub(this.curve._mulA(c))); + // Z3 = F * G + nz = f.redMul(g); + } else { + // Y3 = A * G * (D - C) + ny = a.redMul(g).redMul(d.redSub(c)); + // Z3 = c * F * G + nz = this.curve._mulC(f).redMul(g); } + return this.curve.point(nx, ny, nz); }; -function createAndAccumulateChangeEvent(inst, nativeEvent, target) { - var event = SyntheticEvent.getPooled(eventTypes.change, inst, nativeEvent, target); - event.type = 'change'; - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; -} -/** - * For IE shims - */ -var activeElement = null; -var activeElementInst = null; +Point.prototype.add = function add(p) { + if (this.isInfinity()) + return p; + if (p.isInfinity()) + return this; -/** - * SECTION: handle `change` event - */ -function shouldUseChangeEvent(elem) { - var nodeName = elem.nodeName && elem.nodeName.toLowerCase(); - return nodeName === 'select' || nodeName === 'input' && elem.type === 'file'; -} + if (this.curve.extended) + return this._extAdd(p); + else + return this._projAdd(p); +}; -var doesChangeEventBubble = false; -if (ExecutionEnvironment.canUseDOM) { - // See `handleChange` comment below - doesChangeEventBubble = isEventSupported('change') && (!document.documentMode || document.documentMode > 8); -} +Point.prototype.mul = function mul(k) { + if (this._hasDoubles(k)) + return this.curve._fixedNafMul(this, k); + else + return this.curve._wnafMul(this, k); +}; -function manualDispatchChangeEvent(nativeEvent) { - var event = createAndAccumulateChangeEvent(activeElementInst, nativeEvent, getEventTarget(nativeEvent)); +Point.prototype.mulAdd = function mulAdd(k1, p, k2) { + return this.curve._wnafMulAdd(1, [ this, p ], [ k1, k2 ], 2, false); +}; - // If change and propertychange bubbled, we'd just bind to it like all the - // other events and have it go through ReactBrowserEventEmitter. Since it - // doesn't, we manually listen for the events and so we have to enqueue and - // process the abstract event manually. - // - // Batching is necessary here in order to ensure that all event handlers run - // before the next rerender (including event handlers attached to ancestor - // elements instead of directly on the input). Without this, controlled - // components don't work properly in conjunction with event bubbling because - // the component is rerendered and the value reverted before all the event - // handlers can run. See https://github.com/facebook/react/issues/708. - ReactUpdates.batchedUpdates(runEventInBatch, event); -} +Point.prototype.jmulAdd = function jmulAdd(k1, p, k2) { + return this.curve._wnafMulAdd(1, [ this, p ], [ k1, k2 ], 2, true); +}; -function runEventInBatch(event) { - EventPluginHub.enqueueEvents(event); - EventPluginHub.processEventQueue(false); -} +Point.prototype.normalize = function normalize() { + if (this.zOne) + return this; + + // Normalize coordinates + var zi = this.z.redInvm(); + this.x = this.x.redMul(zi); + this.y = this.y.redMul(zi); + if (this.t) + this.t = this.t.redMul(zi); + this.z = this.curve.one; + this.zOne = true; + return this; +}; -function startWatchingForChangeEventIE8(target, targetInst) { - activeElement = target; - activeElementInst = targetInst; - activeElement.attachEvent('onchange', manualDispatchChangeEvent); -} +Point.prototype.neg = function neg() { + return this.curve.point(this.x.redNeg(), + this.y, + this.z, + this.t && this.t.redNeg()); +}; -function stopWatchingForChangeEventIE8() { - if (!activeElement) { - return; - } - activeElement.detachEvent('onchange', manualDispatchChangeEvent); - activeElement = null; - activeElementInst = null; -} +Point.prototype.getX = function getX() { + this.normalize(); + return this.x.fromRed(); +}; -function getInstIfValueChanged(targetInst, nativeEvent) { - var updated = inputValueTracking.updateValueIfChanged(targetInst); - var simulated = nativeEvent.simulated === true && ChangeEventPlugin._allowSimulatedPassThrough; +Point.prototype.getY = function getY() { + this.normalize(); + return this.y.fromRed(); +}; - if (updated || simulated) { - return targetInst; - } -} +Point.prototype.eq = function eq(other) { + return this === other || + this.getX().cmp(other.getX()) === 0 && + this.getY().cmp(other.getY()) === 0; +}; -function getTargetInstForChangeEvent(topLevelType, targetInst) { - if (topLevelType === 'topChange') { - return targetInst; - } -} +Point.prototype.eqXToP = function eqXToP(x) { + var rx = x.toRed(this.curve.red).redMul(this.z); + if (this.x.cmp(rx) === 0) + return true; -function handleEventsForChangeEventIE8(topLevelType, target, targetInst) { - if (topLevelType === 'topFocus') { - // stopWatching() should be a noop here but we call it just in case we - // missed a blur event somehow. - stopWatchingForChangeEventIE8(); - startWatchingForChangeEventIE8(target, targetInst); - } else if (topLevelType === 'topBlur') { - stopWatchingForChangeEventIE8(); + var xc = x.clone(); + var t = this.curve.redN.redMul(this.z); + for (;;) { + xc.iadd(this.curve.n); + if (xc.cmp(this.curve.p) >= 0) + return false; + + rx.redIAdd(t); + if (this.x.cmp(rx) === 0) + return true; } -} + return false; +}; -/** - * SECTION: handle `input` event - */ -var isInputEventSupported = false; -if (ExecutionEnvironment.canUseDOM) { - // IE9 claims to support the input event but fails to trigger it when - // deleting text, so we ignore its input events. +// Compatibility with BaseCurve +Point.prototype.toP = Point.prototype.normalize; +Point.prototype.mixedAdd = Point.prototype.add; - isInputEventSupported = isEventSupported('input') && (!('documentMode' in document) || document.documentMode > 9); -} -/** - * (For IE <=9) Starts tracking propertychange events on the passed-in element - * and override the value property so that we can distinguish user events from - * value changes in JS. - */ -function startWatchingForValueChange(target, targetInst) { - activeElement = target; - activeElementInst = targetInst; - activeElement.attachEvent('onpropertychange', handlePropertyChange); -} +/***/ }), +/* 392 */ +/***/ (function(module, exports, __webpack_require__) { -/** - * (For IE <=9) Removes the event listeners from the currently-tracked element, - * if any exists. - */ -function stopWatchingForValueChange() { - if (!activeElement) { - return; - } - activeElement.detachEvent('onpropertychange', handlePropertyChange); +"use strict"; - activeElement = null; - activeElementInst = null; -} -/** - * (For IE <=9) Handles a propertychange event, sending a `change` event if - * the value of the active element has changed. - */ -function handlePropertyChange(nativeEvent) { - if (nativeEvent.propertyName !== 'value') { - return; - } - if (getInstIfValueChanged(activeElementInst, nativeEvent)) { - manualDispatchChangeEvent(nativeEvent); - } -} +var curves = exports; -function handleEventsForInputEventPolyfill(topLevelType, target, targetInst) { - if (topLevelType === 'topFocus') { - // In IE8, we can capture almost all .value changes by adding a - // propertychange handler and looking for events with propertyName - // equal to 'value' - // In IE9, propertychange fires for most input events but is buggy and - // doesn't fire when text is deleted, but conveniently, selectionchange - // appears to fire in all of the remaining cases so we catch those and - // forward the event if the value has changed - // In either case, we don't want to call the event handler if the value - // is changed from JS so we redefine a setter for `.value` that updates - // our activeElementValue variable, allowing us to ignore those changes - // - // stopWatching() should be a noop here but we call it just in case we - // missed a blur event somehow. - stopWatchingForValueChange(); - startWatchingForValueChange(target, targetInst); - } else if (topLevelType === 'topBlur') { - stopWatchingForValueChange(); - } -} +var hash = __webpack_require__(105); +var elliptic = __webpack_require__(15); -// For IE8 and IE9. -function getTargetInstForInputEventPolyfill(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topSelectionChange' || topLevelType === 'topKeyUp' || topLevelType === 'topKeyDown') { - // On the selectionchange event, the target is just document which isn't - // helpful for us so just check activeElement instead. - // - // 99% of the time, keydown and keyup aren't necessary. IE8 fails to fire - // propertychange on the first input event after setting `value` from a - // script and fires only keydown, keypress, keyup. Catching keyup usually - // gets it and catching keydown lets us fire an event for the first - // keystroke if user does a key repeat (it'll be a little delayed: right - // before the second keystroke). Other input methods (e.g., paste) seem to - // fire selectionchange normally. - return getInstIfValueChanged(activeElementInst, nativeEvent); - } -} +var assert = elliptic.utils.assert; -/** - * SECTION: handle `click` event - */ -function shouldUseClickEvent(elem) { - // Use the `click` event to detect changes to checkbox and radio inputs. - // This approach works across all browsers, whereas `change` does not fire - // until `blur` in IE8. - var nodeName = elem.nodeName; - return nodeName && nodeName.toLowerCase() === 'input' && (elem.type === 'checkbox' || elem.type === 'radio'); -} +function PresetCurve(options) { + if (options.type === 'short') + this.curve = new elliptic.curve.short(options); + else if (options.type === 'edwards') + this.curve = new elliptic.curve.edwards(options); + else + this.curve = new elliptic.curve.mont(options); + this.g = this.curve.g; + this.n = this.curve.n; + this.hash = options.hash; -function getTargetInstForClickEvent(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topClick') { - return getInstIfValueChanged(targetInst, nativeEvent); - } + assert(this.g.validate(), 'Invalid curve'); + assert(this.g.mul(this.n).isInfinity(), 'Invalid curve, G*N != O'); } +curves.PresetCurve = PresetCurve; -function getTargetInstForInputOrChangeEvent(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topInput' || topLevelType === 'topChange') { - return getInstIfValueChanged(targetInst, nativeEvent); - } +function defineCurve(name, options) { + Object.defineProperty(curves, name, { + configurable: true, + enumerable: true, + get: function() { + var curve = new PresetCurve(options); + Object.defineProperty(curves, name, { + configurable: true, + enumerable: true, + value: curve + }); + return curve; + } + }); } -function handleControlledInputBlur(inst, node) { - // TODO: In IE, inst is occasionally null. Why? - if (inst == null) { - return; - } +defineCurve('p192', { + type: 'short', + prime: 'p192', + p: 'ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff', + a: 'ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc', + b: '64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1', + n: 'ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831', + hash: hash.sha256, + gRed: false, + g: [ + '188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012', + '07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811' + ] +}); - // Fiber and ReactDOM keep wrapper state in separate places - var state = inst._wrapperState || node._wrapperState; +defineCurve('p224', { + type: 'short', + prime: 'p224', + p: 'ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001', + a: 'ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe', + b: 'b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4', + n: 'ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d', + hash: hash.sha256, + gRed: false, + g: [ + 'b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21', + 'bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34' + ] +}); - if (!state || !state.controlled || node.type !== 'number') { - return; - } +defineCurve('p256', { + type: 'short', + prime: null, + p: 'ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff', + a: 'ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc', + b: '5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b', + n: 'ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551', + hash: hash.sha256, + gRed: false, + g: [ + '6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296', + '4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5' + ] +}); - // If controlled, assign the value attribute to the current value on blur - var value = '' + node.value; - if (node.getAttribute('value') !== value) { - node.setAttribute('value', value); - } -} +defineCurve('p384', { + type: 'short', + prime: null, + p: 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'fffffffe ffffffff 00000000 00000000 ffffffff', + a: 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'fffffffe ffffffff 00000000 00000000 fffffffc', + b: 'b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f ' + + '5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef', + n: 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 ' + + 'f4372ddf 581a0db2 48b0a77a ecec196a ccc52973', + hash: hash.sha384, + gRed: false, + g: [ + 'aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 ' + + '5502f25d bf55296c 3a545e38 72760ab7', + '3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 ' + + '0a60b1ce 1d7e819d 7a431d7c 90ea0e5f' + ] +}); -/** - * This plugin creates an `onChange` event that normalizes change events - * across form elements. This event fires at a time when it's possible to - * change the element's value without seeing a flicker. - * - * Supported elements are: - * - input (see `isTextInputElement`) - * - textarea - * - select - */ -var ChangeEventPlugin = { - eventTypes: eventTypes, +defineCurve('p521', { + type: 'short', + prime: null, + p: '000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff ffffffff ffffffff ffffffff', + a: '000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff ffffffff ffffffff fffffffc', + b: '00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b ' + + '99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd ' + + '3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00', + n: '000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ' + + 'ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 ' + + 'f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409', + hash: hash.sha512, + gRed: false, + g: [ + '000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 ' + + '053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 ' + + 'a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66', + '00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 ' + + '579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 ' + + '3fad0761 353c7086 a272c240 88be9476 9fd16650' + ] +}); - _allowSimulatedPassThrough: true, - _isInputEventSupported: isInputEventSupported, +defineCurve('curve25519', { + type: 'mont', + prime: 'p25519', + p: '7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed', + a: '76d06', + b: '1', + n: '1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed', + hash: hash.sha256, + gRed: false, + g: [ + '9' + ] +}); - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; +defineCurve('ed25519', { + type: 'edwards', + prime: 'p25519', + p: '7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed', + a: '-1', + c: '1', + // -121665 * (121666^(-1)) (mod P) + d: '52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3', + n: '1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed', + hash: hash.sha256, + gRed: false, + g: [ + '216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a', + + // 4/5 + '6666666666666666666666666666666666666666666666666666666666666658' + ] +}); - var getTargetInstFunc, handleEventFunc; - if (shouldUseChangeEvent(targetNode)) { - if (doesChangeEventBubble) { - getTargetInstFunc = getTargetInstForChangeEvent; - } else { - handleEventFunc = handleEventsForChangeEventIE8; - } - } else if (isTextInputElement(targetNode)) { - if (isInputEventSupported) { - getTargetInstFunc = getTargetInstForInputOrChangeEvent; - } else { - getTargetInstFunc = getTargetInstForInputEventPolyfill; - handleEventFunc = handleEventsForInputEventPolyfill; - } - } else if (shouldUseClickEvent(targetNode)) { - getTargetInstFunc = getTargetInstForClickEvent; - } +var pre; +try { + pre = __webpack_require__(399); +} catch (e) { + pre = undefined; +} - if (getTargetInstFunc) { - var inst = getTargetInstFunc(topLevelType, targetInst, nativeEvent); - if (inst) { - var event = createAndAccumulateChangeEvent(inst, nativeEvent, nativeEventTarget); - return event; - } +defineCurve('secp256k1', { + type: 'short', + prime: 'k256', + p: 'ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f', + a: '0', + b: '7', + n: 'ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141', + h: '1', + hash: hash.sha256, + + // Precomputed endomorphism + beta: '7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee', + lambda: '5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72', + basis: [ + { + a: '3086d221a7d46bcde86c90e49284eb15', + b: '-e4437ed6010e88286f547fa90abfe4c3' + }, + { + a: '114ca50f7a8e2f3f657c1108d9d44cfd8', + b: '3086d221a7d46bcde86c90e49284eb15' } + ], - if (handleEventFunc) { - handleEventFunc(topLevelType, targetNode, targetInst); - } + gRed: false, + g: [ + '79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798', + '483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8', + pre + ] +}); - // When blurring, set the value attribute for number inputs - if (topLevelType === 'topBlur') { - handleControlledInputBlur(targetInst, targetNode); - } - } -}; -module.exports = ChangeEventPlugin; +/***/ }), +/* 393 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +exports.sha1 = __webpack_require__(394); +exports.sha224 = __webpack_require__(395); +exports.sha256 = __webpack_require__(173); +exports.sha384 = __webpack_require__(396); +exports.sha512 = __webpack_require__(174); + /***/ }), -/* 143 */ +/* 394 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var shaCommon = __webpack_require__(172); -var ReactOwner = __webpack_require__(144); +var rotl32 = utils.rotl32; +var sum32 = utils.sum32; +var sum32_5 = utils.sum32_5; +var ft_1 = shaCommon.ft_1; +var BlockHash = common.BlockHash; -var ReactRef = {}; +var sha1_K = [ + 0x5A827999, 0x6ED9EBA1, + 0x8F1BBCDC, 0xCA62C1D6 +]; -function attachRef(ref, component, owner) { - if (typeof ref === 'function') { - ref(component.getPublicInstance()); - } else { - // Legacy ref - ReactOwner.addComponentAsRefTo(component, ref, owner); - } -} +function SHA1() { + if (!(this instanceof SHA1)) + return new SHA1(); -function detachRef(ref, component, owner) { - if (typeof ref === 'function') { - ref(null); - } else { - // Legacy ref - ReactOwner.removeComponentAsRefFrom(component, ref, owner); - } + BlockHash.call(this); + this.h = [ + 0x67452301, 0xefcdab89, 0x98badcfe, + 0x10325476, 0xc3d2e1f0 ]; + this.W = new Array(80); } -ReactRef.attachRefs = function (instance, element) { - if (element === null || typeof element !== 'object') { - return; - } - var ref = element.ref; - if (ref != null) { - attachRef(ref, instance, element._owner); - } -}; +utils.inherits(SHA1, BlockHash); +module.exports = SHA1; -ReactRef.shouldUpdateRefs = function (prevElement, nextElement) { - // If either the owner or a `ref` has changed, make sure the newest owner - // has stored a reference to `this`, and the previous owner (if different) - // has forgotten the reference to `this`. We use the element instead - // of the public this.props because the post processing cannot determine - // a ref. The ref conceptually lives on the element. +SHA1.blockSize = 512; +SHA1.outSize = 160; +SHA1.hmacStrength = 80; +SHA1.padLength = 64; - // TODO: Should this even be possible? The owner cannot change because - // it's forbidden by shouldUpdateReactComponent. The ref can change - // if you swap the keys of but not the refs. Reconsider where this check - // is made. It probably belongs where the key checking and - // instantiateReactComponent is done. +SHA1.prototype._update = function _update(msg, start) { + var W = this.W; - var prevRef = null; - var prevOwner = null; - if (prevElement !== null && typeof prevElement === 'object') { - prevRef = prevElement.ref; - prevOwner = prevElement._owner; - } + for (var i = 0; i < 16; i++) + W[i] = msg[start + i]; - var nextRef = null; - var nextOwner = null; - if (nextElement !== null && typeof nextElement === 'object') { - nextRef = nextElement.ref; - nextOwner = nextElement._owner; + for(; i < W.length; i++) + W[i] = rotl32(W[i - 3] ^ W[i - 8] ^ W[i - 14] ^ W[i - 16], 1); + + var a = this.h[0]; + var b = this.h[1]; + var c = this.h[2]; + var d = this.h[3]; + var e = this.h[4]; + + for (i = 0; i < W.length; i++) { + var s = ~~(i / 20); + var t = sum32_5(rotl32(a, 5), ft_1(s, b, c, d), e, W[i], sha1_K[s]); + e = d; + d = c; + c = rotl32(b, 30); + b = a; + a = t; } - return prevRef !== nextRef || - // If owner changes but we have an unchanged function ref, don't update refs - typeof nextRef === 'string' && nextOwner !== prevOwner; + this.h[0] = sum32(this.h[0], a); + this.h[1] = sum32(this.h[1], b); + this.h[2] = sum32(this.h[2], c); + this.h[3] = sum32(this.h[3], d); + this.h[4] = sum32(this.h[4], e); }; -ReactRef.detachRefs = function (instance, element) { - if (element === null || typeof element !== 'object') { - return; - } - var ref = element.ref; - if (ref != null) { - detachRef(ref, instance, element._owner); - } +SHA1.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'big'); + else + return utils.split32(this.h, 'big'); }; -module.exports = ReactRef; /***/ }), -/* 144 */ +/* 395 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var utils = __webpack_require__(25); +var SHA256 = __webpack_require__(173); -var _prodInvariant = __webpack_require__(3); +function SHA224() { + if (!(this instanceof SHA224)) + return new SHA224(); -var invariant = __webpack_require__(1); - -/** - * @param {?object} object - * @return {boolean} True if `object` is a valid owner. - * @final - */ -function isValidOwner(object) { - return !!(object && typeof object.attachRef === 'function' && typeof object.detachRef === 'function'); + SHA256.call(this); + this.h = [ + 0xc1059ed8, 0x367cd507, 0x3070dd17, 0xf70e5939, + 0xffc00b31, 0x68581511, 0x64f98fa7, 0xbefa4fa4 ]; } - -/** - * ReactOwners are capable of storing references to owned components. - * - * All components are capable of //being// referenced by owner components, but - * only ReactOwner components are capable of //referencing// owned components. - * The named reference is known as a "ref". - * - * Refs are available when mounted and updated during reconciliation. - * - * var MyComponent = React.createClass({ - * render: function() { - * return ( - * <div onClick={this.handleClick}> - * <CustomComponent ref="custom" /> - * </div> - * ); - * }, - * handleClick: function() { - * this.refs.custom.handleClick(); - * }, - * componentDidMount: function() { - * this.refs.custom.initialize(); - * } - * }); - * - * Refs should rarely be used. When refs are used, they should only be done to - * control data that is not handled by React's data flow. - * - * @class ReactOwner - */ -var ReactOwner = { - /** - * Adds a component by ref to an owner component. - * - * @param {ReactComponent} component Component to reference. - * @param {string} ref Name by which to refer to the component. - * @param {ReactOwner} owner Component on which to record the ref. - * @final - * @internal - */ - addComponentAsRefTo: function (component, ref, owner) { - !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('119') : void 0; - owner.attachRef(ref, component); - }, - - /** - * Removes a component by ref from an owner component. - * - * @param {ReactComponent} component Component to dereference. - * @param {string} ref Name of the ref to remove. - * @param {ReactOwner} owner Component on which the ref is recorded. - * @final - * @internal - */ - removeComponentAsRefFrom: function (component, ref, owner) { - !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'removeComponentAsRefFrom(...): Only a ReactOwner can have refs. You might be removing a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('120') : void 0; - var ownerPublicInstance = owner.getPublicInstance(); - // Check that `component`'s owner is still alive and that `component` is still the current ref - // because we do not want to detach the ref if another component stole it. - if (ownerPublicInstance && ownerPublicInstance.refs[ref] === component.getPublicInstance()) { - owner.detachRef(ref); - } - } +utils.inherits(SHA224, SHA256); +module.exports = SHA224; + +SHA224.blockSize = 512; +SHA224.outSize = 224; +SHA224.hmacStrength = 192; +SHA224.padLength = 64; + +SHA224.prototype._digest = function digest(enc) { + // Just truncate output + if (enc === 'hex') + return utils.toHex32(this.h.slice(0, 7), 'big'); + else + return utils.split32(this.h.slice(0, 7), 'big'); }; -module.exports = ReactOwner; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + /***/ }), -/* 145 */ +/* 396 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var utils = __webpack_require__(25); -var ReactInvalidSetStateWarningHook = __webpack_require__(146); -var ReactHostOperationHistoryHook = __webpack_require__(147); -var ReactComponentTreeHook = __webpack_require__(10); -var ExecutionEnvironment = __webpack_require__(8); +var SHA512 = __webpack_require__(174); -var performanceNow = __webpack_require__(148); -var warning = __webpack_require__(2); +function SHA384() { + if (!(this instanceof SHA384)) + return new SHA384(); -var hooks = []; -var didHookThrowForEvent = {}; - -function callHook(event, fn, context, arg1, arg2, arg3, arg4, arg5) { - try { - fn.call(context, arg1, arg2, arg3, arg4, arg5); - } catch (e) { - process.env.NODE_ENV !== 'production' ? warning(didHookThrowForEvent[event], 'Exception thrown by hook while handling %s: %s', event, e + '\n' + e.stack) : void 0; - didHookThrowForEvent[event] = true; - } + SHA512.call(this); + this.h = [ + 0xcbbb9d5d, 0xc1059ed8, + 0x629a292a, 0x367cd507, + 0x9159015a, 0x3070dd17, + 0x152fecd8, 0xf70e5939, + 0x67332667, 0xffc00b31, + 0x8eb44a87, 0x68581511, + 0xdb0c2e0d, 0x64f98fa7, + 0x47b5481d, 0xbefa4fa4 ]; } +utils.inherits(SHA384, SHA512); +module.exports = SHA384; + +SHA384.blockSize = 1024; +SHA384.outSize = 384; +SHA384.hmacStrength = 192; +SHA384.padLength = 128; + +SHA384.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h.slice(0, 12), 'big'); + else + return utils.split32(this.h.slice(0, 12), 'big'); +}; -function emitEvent(event, arg1, arg2, arg3, arg4, arg5) { - for (var i = 0; i < hooks.length; i++) { - var hook = hooks[i]; - var fn = hook[event]; - if (fn) { - callHook(event, fn, hook, arg1, arg2, arg3, arg4, arg5); - } - } -} -var isProfiling = false; -var flushHistory = []; -var lifeCycleTimerStack = []; -var currentFlushNesting = 0; -var currentFlushMeasurements = []; -var currentFlushStartTime = 0; -var currentTimerDebugID = null; -var currentTimerStartTime = 0; -var currentTimerNestedFlushDuration = 0; -var currentTimerType = null; +/***/ }), +/* 397 */ +/***/ (function(module, exports, __webpack_require__) { -var lifeCycleTimerHasWarned = false; +"use strict"; -function clearHistory() { - ReactComponentTreeHook.purgeUnmountedComponents(); - ReactHostOperationHistoryHook.clearHistory(); -} -function getTreeSnapshot(registeredIDs) { - return registeredIDs.reduce(function (tree, id) { - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var parentID = ReactComponentTreeHook.getParentID(id); - tree[id] = { - displayName: ReactComponentTreeHook.getDisplayName(id), - text: ReactComponentTreeHook.getText(id), - updateCount: ReactComponentTreeHook.getUpdateCount(id), - childIDs: ReactComponentTreeHook.getChildIDs(id), - // Text nodes don't have owners but this is close enough. - ownerID: ownerID || parentID && ReactComponentTreeHook.getOwnerID(parentID) || 0, - parentID: parentID - }; - return tree; - }, {}); -} +var utils = __webpack_require__(25); +var common = __webpack_require__(50); -function resetMeasurements() { - var previousStartTime = currentFlushStartTime; - var previousMeasurements = currentFlushMeasurements; - var previousOperations = ReactHostOperationHistoryHook.getHistory(); +var rotl32 = utils.rotl32; +var sum32 = utils.sum32; +var sum32_3 = utils.sum32_3; +var sum32_4 = utils.sum32_4; +var BlockHash = common.BlockHash; - if (currentFlushNesting === 0) { - currentFlushStartTime = 0; - currentFlushMeasurements = []; - clearHistory(); - return; - } +function RIPEMD160() { + if (!(this instanceof RIPEMD160)) + return new RIPEMD160(); - if (previousMeasurements.length || previousOperations.length) { - var registeredIDs = ReactComponentTreeHook.getRegisteredIDs(); - flushHistory.push({ - duration: performanceNow() - previousStartTime, - measurements: previousMeasurements || [], - operations: previousOperations || [], - treeSnapshot: getTreeSnapshot(registeredIDs) - }); - } + BlockHash.call(this); - clearHistory(); - currentFlushStartTime = performanceNow(); - currentFlushMeasurements = []; + this.h = [ 0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476, 0xc3d2e1f0 ]; + this.endian = 'little'; } +utils.inherits(RIPEMD160, BlockHash); +exports.ripemd160 = RIPEMD160; + +RIPEMD160.blockSize = 512; +RIPEMD160.outSize = 160; +RIPEMD160.hmacStrength = 192; +RIPEMD160.padLength = 64; + +RIPEMD160.prototype._update = function update(msg, start) { + var A = this.h[0]; + var B = this.h[1]; + var C = this.h[2]; + var D = this.h[3]; + var E = this.h[4]; + var Ah = A; + var Bh = B; + var Ch = C; + var Dh = D; + var Eh = E; + for (var j = 0; j < 80; j++) { + var T = sum32( + rotl32( + sum32_4(A, f(j, B, C, D), msg[r[j] + start], K(j)), + s[j]), + E); + A = E; + E = D; + D = rotl32(C, 10); + C = B; + B = T; + T = sum32( + rotl32( + sum32_4(Ah, f(79 - j, Bh, Ch, Dh), msg[rh[j] + start], Kh(j)), + sh[j]), + Eh); + Ah = Eh; + Eh = Dh; + Dh = rotl32(Ch, 10); + Ch = Bh; + Bh = T; + } + T = sum32_3(this.h[1], C, Dh); + this.h[1] = sum32_3(this.h[2], D, Eh); + this.h[2] = sum32_3(this.h[3], E, Ah); + this.h[3] = sum32_3(this.h[4], A, Bh); + this.h[4] = sum32_3(this.h[0], B, Ch); + this.h[0] = T; +}; -function checkDebugID(debugID) { - var allowRoot = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; +RIPEMD160.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'little'); + else + return utils.split32(this.h, 'little'); +}; - if (allowRoot && debugID === 0) { - return; - } - if (!debugID) { - process.env.NODE_ENV !== 'production' ? warning(false, 'ReactDebugTool: debugID may not be empty.') : void 0; - } +function f(j, x, y, z) { + if (j <= 15) + return x ^ y ^ z; + else if (j <= 31) + return (x & y) | ((~x) & z); + else if (j <= 47) + return (x | (~y)) ^ z; + else if (j <= 63) + return (x & z) | (y & (~z)); + else + return x ^ (y | (~z)); } -function beginLifeCycleTimer(debugID, timerType) { - if (currentFlushNesting === 0) { - return; - } - if (currentTimerType && !lifeCycleTimerHasWarned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'Did not expect %s timer to start while %s timer is still in ' + 'progress for %s instance.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; - lifeCycleTimerHasWarned = true; - } - currentTimerStartTime = performanceNow(); - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = debugID; - currentTimerType = timerType; +function K(j) { + if (j <= 15) + return 0x00000000; + else if (j <= 31) + return 0x5a827999; + else if (j <= 47) + return 0x6ed9eba1; + else if (j <= 63) + return 0x8f1bbcdc; + else + return 0xa953fd4e; } -function endLifeCycleTimer(debugID, timerType) { - if (currentFlushNesting === 0) { - return; - } - if (currentTimerType !== timerType && !lifeCycleTimerHasWarned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'We did not expect %s timer to stop while %s timer is still in ' + 'progress for %s instance. Please report this as a bug in React.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; - lifeCycleTimerHasWarned = true; - } - if (isProfiling) { - currentFlushMeasurements.push({ - timerType: timerType, - instanceID: debugID, - duration: performanceNow() - currentTimerStartTime - currentTimerNestedFlushDuration - }); - } - currentTimerStartTime = 0; - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = null; - currentTimerType = null; +function Kh(j) { + if (j <= 15) + return 0x50a28be6; + else if (j <= 31) + return 0x5c4dd124; + else if (j <= 47) + return 0x6d703ef3; + else if (j <= 63) + return 0x7a6d76e9; + else + return 0x00000000; } -function pauseCurrentLifeCycleTimer() { - var currentTimer = { - startTime: currentTimerStartTime, - nestedFlushStartTime: performanceNow(), - debugID: currentTimerDebugID, - timerType: currentTimerType - }; - lifeCycleTimerStack.push(currentTimer); - currentTimerStartTime = 0; - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = null; - currentTimerType = null; -} +var r = [ + 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, + 7, 4, 13, 1, 10, 6, 15, 3, 12, 0, 9, 5, 2, 14, 11, 8, + 3, 10, 14, 4, 9, 15, 8, 1, 2, 7, 0, 6, 13, 11, 5, 12, + 1, 9, 11, 10, 0, 8, 12, 4, 13, 3, 7, 15, 14, 5, 6, 2, + 4, 0, 5, 9, 7, 12, 2, 10, 14, 1, 3, 8, 11, 6, 15, 13 +]; + +var rh = [ + 5, 14, 7, 0, 9, 2, 11, 4, 13, 6, 15, 8, 1, 10, 3, 12, + 6, 11, 3, 7, 0, 13, 5, 10, 14, 15, 8, 12, 4, 9, 1, 2, + 15, 5, 1, 3, 7, 14, 6, 9, 11, 8, 12, 2, 10, 0, 4, 13, + 8, 6, 4, 1, 3, 11, 15, 0, 5, 12, 2, 13, 9, 7, 10, 14, + 12, 15, 10, 4, 1, 5, 8, 7, 6, 2, 13, 14, 0, 3, 9, 11 +]; + +var s = [ + 11, 14, 15, 12, 5, 8, 7, 9, 11, 13, 14, 15, 6, 7, 9, 8, + 7, 6, 8, 13, 11, 9, 7, 15, 7, 12, 15, 9, 11, 7, 13, 12, + 11, 13, 6, 7, 14, 9, 13, 15, 14, 8, 13, 6, 5, 12, 7, 5, + 11, 12, 14, 15, 14, 15, 9, 8, 9, 14, 5, 6, 8, 6, 5, 12, + 9, 15, 5, 11, 6, 8, 13, 12, 5, 12, 13, 14, 11, 8, 5, 6 +]; + +var sh = [ + 8, 9, 9, 11, 13, 15, 15, 5, 7, 7, 8, 11, 14, 14, 12, 6, + 9, 13, 15, 7, 12, 8, 9, 11, 7, 7, 12, 7, 6, 15, 13, 11, + 9, 7, 15, 11, 8, 6, 6, 14, 12, 13, 5, 14, 13, 13, 7, 5, + 15, 5, 8, 11, 14, 14, 6, 14, 6, 9, 12, 9, 12, 5, 15, 8, + 8, 5, 12, 9, 12, 5, 14, 6, 8, 13, 6, 5, 15, 13, 11, 11 +]; -function resumeCurrentLifeCycleTimer() { - var _lifeCycleTimerStack$ = lifeCycleTimerStack.pop(), - startTime = _lifeCycleTimerStack$.startTime, - nestedFlushStartTime = _lifeCycleTimerStack$.nestedFlushStartTime, - debugID = _lifeCycleTimerStack$.debugID, - timerType = _lifeCycleTimerStack$.timerType; - var nestedFlushDuration = performanceNow() - nestedFlushStartTime; - currentTimerStartTime = startTime; - currentTimerNestedFlushDuration += nestedFlushDuration; - currentTimerDebugID = debugID; - currentTimerType = timerType; -} +/***/ }), +/* 398 */ +/***/ (function(module, exports, __webpack_require__) { -var lastMarkTimeStamp = 0; -var canUsePerformanceMeasure = typeof performance !== 'undefined' && typeof performance.mark === 'function' && typeof performance.clearMarks === 'function' && typeof performance.measure === 'function' && typeof performance.clearMeasures === 'function'; +"use strict"; -function shouldMark(debugID) { - if (!isProfiling || !canUsePerformanceMeasure) { - return false; - } - var element = ReactComponentTreeHook.getElement(debugID); - if (element == null || typeof element !== 'object') { - return false; - } - var isHostElement = typeof element.type === 'string'; - if (isHostElement) { - return false; - } - return true; -} -function markBegin(debugID, markType) { - if (!shouldMark(debugID)) { - return; - } +var utils = __webpack_require__(25); +var assert = __webpack_require__(21); - var markName = debugID + '::' + markType; - lastMarkTimeStamp = performanceNow(); - performance.mark(markName); +function Hmac(hash, key, enc) { + if (!(this instanceof Hmac)) + return new Hmac(hash, key, enc); + this.Hash = hash; + this.blockSize = hash.blockSize / 8; + this.outSize = hash.outSize / 8; + this.inner = null; + this.outer = null; + + this._init(utils.toArray(key, enc)); } +module.exports = Hmac; + +Hmac.prototype._init = function init(key) { + // Shorten key, if needed + if (key.length > this.blockSize) + key = new this.Hash().update(key).digest(); + assert(key.length <= this.blockSize); + + // Add padding to key + for (var i = key.length; i < this.blockSize; i++) + key.push(0); + + for (i = 0; i < key.length; i++) + key[i] ^= 0x36; + this.inner = new this.Hash().update(key); + + // 0x36 ^ 0x5c = 0x6a + for (i = 0; i < key.length; i++) + key[i] ^= 0x6a; + this.outer = new this.Hash().update(key); +}; -function markEnd(debugID, markType) { - if (!shouldMark(debugID)) { - return; - } +Hmac.prototype.update = function update(msg, enc) { + this.inner.update(msg, enc); + return this; +}; - var markName = debugID + '::' + markType; - var displayName = ReactComponentTreeHook.getDisplayName(debugID) || 'Unknown'; +Hmac.prototype.digest = function digest(enc) { + this.outer.update(this.inner.digest()); + return this.outer.digest(enc); +}; - // Chrome has an issue of dropping markers recorded too fast: - // https://bugs.chromium.org/p/chromium/issues/detail?id=640652 - // To work around this, we will not report very small measurements. - // I determined the magic number by tweaking it back and forth. - // 0.05ms was enough to prevent the issue, but I set it to 0.1ms to be safe. - // When the bug is fixed, we can `measure()` unconditionally if we want to. - var timeStamp = performanceNow(); - if (timeStamp - lastMarkTimeStamp > 0.1) { - var measurementName = displayName + ' [' + markType + ']'; - performance.measure(measurementName, markName); - } - performance.clearMarks(markName); - if (measurementName) { - performance.clearMeasures(measurementName); - } -} +/***/ }), +/* 399 */ +/***/ (function(module, exports) { -var ReactDebugTool = { - addHook: function (hook) { - hooks.push(hook); - }, - removeHook: function (hook) { - for (var i = 0; i < hooks.length; i++) { - if (hooks[i] === hook) { - hooks.splice(i, 1); - i--; - } - } - }, - isProfiling: function () { - return isProfiling; +module.exports = { + doubles: { + step: 4, + points: [ + [ + 'e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a', + 'f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821' + ], + [ + '8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508', + '11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf' + ], + [ + '175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739', + 'd3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695' + ], + [ + '363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640', + '4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9' + ], + [ + '8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c', + '4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36' + ], + [ + '723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda', + '96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f' + ], + [ + 'eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa', + '5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999' + ], + [ + '100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0', + 'cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09' + ], + [ + 'e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d', + '9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d' + ], + [ + 'feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d', + 'e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088' + ], + [ + 'da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1', + '9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d' + ], + [ + '53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0', + '5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8' + ], + [ + '8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047', + '10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a' + ], + [ + '385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862', + '283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453' + ], + [ + '6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7', + '7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160' + ], + [ + '3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd', + '56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0' + ], + [ + '85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83', + '7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6' + ], + [ + '948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a', + '53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589' + ], + [ + '6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8', + 'bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17' + ], + [ + 'e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d', + '4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda' + ], + [ + 'e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725', + '7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd' + ], + [ + '213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754', + '4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2' + ], + [ + '4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c', + '17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6' + ], + [ + 'fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6', + '6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f' + ], + [ + '76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39', + 'c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01' + ], + [ + 'c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891', + '893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3' + ], + [ + 'd895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b', + 'febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f' + ], + [ + 'b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03', + '2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7' + ], + [ + 'e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d', + 'eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78' + ], + [ + 'a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070', + '7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1' + ], + [ + '90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4', + 'e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150' + ], + [ + '8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da', + '662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82' + ], + [ + 'e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11', + '1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc' + ], + [ + '8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e', + 'efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b' + ], + [ + 'e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41', + '2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51' + ], + [ + 'b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef', + '67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45' + ], + [ + 'd68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8', + 'db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120' + ], + [ + '324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d', + '648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84' + ], + [ + '4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96', + '35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d' + ], + [ + '9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd', + 'ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d' + ], + [ + '6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5', + '9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8' + ], + [ + 'a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266', + '40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8' + ], + [ + '7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71', + '34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac' + ], + [ + '928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac', + 'c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f' + ], + [ + '85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751', + '1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962' + ], + [ + 'ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e', + '493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907' + ], + [ + '827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241', + 'c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec' + ], + [ + 'eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3', + 'be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d' + ], + [ + 'e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f', + '4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414' + ], + [ + '1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19', + 'aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd' + ], + [ + '146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be', + 'b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0' + ], + [ + 'fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9', + '6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811' + ], + [ + 'da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2', + '8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1' + ], + [ + 'a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13', + '7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c' + ], + [ + '174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c', + 'ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73' + ], + [ + '959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba', + '2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd' + ], + [ + 'd2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151', + 'e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405' + ], + [ + '64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073', + 'd99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589' + ], + [ + '8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458', + '38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e' + ], + [ + '13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b', + '69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27' + ], + [ + 'bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366', + 'd3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1' + ], + [ + '8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa', + '40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482' + ], + [ + '8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0', + '620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945' + ], + [ + 'dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787', + '7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573' + ], + [ + 'f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e', + 'ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82' + ] + ] }, - beginProfiling: function () { - if (isProfiling) { - return; - } + naf: { + wnd: 7, + points: [ + [ + 'f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9', + '388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672' + ], + [ + '2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4', + 'd8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6' + ], + [ + '5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc', + '6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da' + ], + [ + 'acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe', + 'cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37' + ], + [ + '774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb', + 'd984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b' + ], + [ + 'f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8', + 'ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81' + ], + [ + 'd7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e', + '581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58' + ], + [ + 'defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34', + '4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77' + ], + [ + '2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c', + '85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a' + ], + [ + '352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5', + '321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c' + ], + [ + '2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f', + '2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67' + ], + [ + '9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714', + '73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402' + ], + [ + 'daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729', + 'a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55' + ], + [ + 'c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db', + '2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482' + ], + [ + '6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4', + 'e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82' + ], + [ + '1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5', + 'b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396' + ], + [ + '605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479', + '2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49' + ], + [ + '62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d', + '80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf' + ], + [ + '80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f', + '1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a' + ], + [ + '7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb', + 'd0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7' + ], + [ + 'd528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9', + 'eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933' + ], + [ + '49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963', + '758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a' + ], + [ + '77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74', + '958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6' + ], + [ + 'f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530', + 'e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37' + ], + [ + '463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b', + '5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e' + ], + [ + 'f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247', + 'cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6' + ], + [ + 'caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1', + 'cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476' + ], + [ + '2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120', + '4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40' + ], + [ + '7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435', + '91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61' + ], + [ + '754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18', + '673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683' + ], + [ + 'e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8', + '59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5' + ], + [ + '186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb', + '3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b' + ], + [ + 'df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f', + '55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417' + ], + [ + '5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143', + 'efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868' + ], + [ + '290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba', + 'e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a' + ], + [ + 'af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45', + 'f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6' + ], + [ + '766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a', + '744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996' + ], + [ + '59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e', + 'c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e' + ], + [ + 'f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8', + 'e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d' + ], + [ + '7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c', + '30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2' + ], + [ + '948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519', + 'e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e' + ], + [ + '7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab', + '100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437' + ], + [ + '3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca', + 'ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311' + ], + [ + 'd3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf', + '8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4' + ], + [ + '1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610', + '68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575' + ], + [ + '733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4', + 'f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d' + ], + [ + '15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c', + 'd56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d' + ], + [ + 'a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940', + 'edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629' + ], + [ + 'e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980', + 'a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06' + ], + [ + '311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3', + '66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374' + ], + [ + '34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf', + '9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee' + ], + [ + 'f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63', + '4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1' + ], + [ + 'd7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448', + 'fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b' + ], + [ + '32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf', + '5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661' + ], + [ + '7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5', + '8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6' + ], + [ + 'ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6', + '8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e' + ], + [ + '16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5', + '5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d' + ], + [ + 'eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99', + 'f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc' + ], + [ + '78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51', + 'f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4' + ], + [ + '494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5', + '42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c' + ], + [ + 'a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5', + '204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b' + ], + [ + 'c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997', + '4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913' + ], + [ + '841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881', + '73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154' + ], + [ + '5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5', + '39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865' + ], + [ + '36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66', + 'd2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc' + ], + [ + '336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726', + 'ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224' + ], + [ + '8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede', + '6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e' + ], + [ + '1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94', + '60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6' + ], + [ + '85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31', + '3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511' + ], + [ + '29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51', + 'b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b' + ], + [ + 'a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252', + 'ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2' + ], + [ + '4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5', + 'cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c' + ], + [ + 'd24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b', + '6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3' + ], + [ + 'ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4', + '322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d' + ], + [ + 'af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f', + '6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700' + ], + [ + 'e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889', + '2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4' + ], + [ + '591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246', + 'b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196' + ], + [ + '11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984', + '998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4' + ], + [ + '3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a', + 'b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257' + ], + [ + 'cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030', + 'bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13' + ], + [ + 'c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197', + '6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096' + ], + [ + 'c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593', + 'c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38' + ], + [ + 'a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef', + '21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f' + ], + [ + '347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38', + '60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448' + ], + [ + 'da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a', + '49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a' + ], + [ + 'c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111', + '5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4' + ], + [ + '4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502', + '7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437' + ], + [ + '3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea', + 'be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7' + ], + [ + 'cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26', + '8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d' + ], + [ + 'b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986', + '39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a' + ], + [ + 'd4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e', + '62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54' + ], + [ + '48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4', + '25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77' + ], + [ + 'dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda', + 'ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517' + ], + [ + '6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859', + 'cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10' + ], + [ + 'e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f', + 'f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125' + ], + [ + 'eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c', + '6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e' + ], + [ + '13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942', + 'fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1' + ], + [ + 'ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a', + '1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2' + ], + [ + 'b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80', + '5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423' + ], + [ + 'ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d', + '438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8' + ], + [ + '8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1', + 'cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758' + ], + [ + '52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63', + 'c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375' + ], + [ + 'e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352', + '6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d' + ], + [ + '7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193', + 'ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec' + ], + [ + '5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00', + '9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0' + ], + [ + '32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58', + 'ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c' + ], + [ + 'e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7', + 'd3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4' + ], + [ + '8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8', + 'c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f' + ], + [ + '4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e', + '67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649' + ], + [ + '3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d', + 'cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826' + ], + [ + '674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b', + '299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5' + ], + [ + 'd32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f', + 'f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87' + ], + [ + '30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6', + '462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b' + ], + [ + 'be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297', + '62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc' + ], + [ + '93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a', + '7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c' + ], + [ + 'b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c', + 'ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f' + ], + [ + 'd5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52', + '4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a' + ], + [ + 'd3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb', + 'bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46' + ], + [ + '463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065', + 'bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f' + ], + [ + '7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917', + '603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03' + ], + [ + '74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9', + 'cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08' + ], + [ + '30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3', + '553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8' + ], + [ + '9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57', + '712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373' + ], + [ + '176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66', + 'ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3' + ], + [ + '75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8', + '9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8' + ], + [ + '809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721', + '9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1' + ], + [ + '1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180', + '4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9' + ] + ] + } +}; - isProfiling = true; - flushHistory.length = 0; - resetMeasurements(); - ReactDebugTool.addHook(ReactHostOperationHistoryHook); - }, - endProfiling: function () { - if (!isProfiling) { - return; - } - isProfiling = false; - resetMeasurements(); - ReactDebugTool.removeHook(ReactHostOperationHistoryHook); - }, - getFlushHistory: function () { - return flushHistory; - }, - onBeginFlush: function () { - currentFlushNesting++; - resetMeasurements(); - pauseCurrentLifeCycleTimer(); - emitEvent('onBeginFlush'); - }, - onEndFlush: function () { - resetMeasurements(); - currentFlushNesting--; - resumeCurrentLifeCycleTimer(); - emitEvent('onEndFlush'); - }, - onBeginLifeCycleTimer: function (debugID, timerType) { - checkDebugID(debugID); - emitEvent('onBeginLifeCycleTimer', debugID, timerType); - markBegin(debugID, timerType); - beginLifeCycleTimer(debugID, timerType); - }, - onEndLifeCycleTimer: function (debugID, timerType) { - checkDebugID(debugID); - endLifeCycleTimer(debugID, timerType); - markEnd(debugID, timerType); - emitEvent('onEndLifeCycleTimer', debugID, timerType); - }, - onBeginProcessingChildContext: function () { - emitEvent('onBeginProcessingChildContext'); - }, - onEndProcessingChildContext: function () { - emitEvent('onEndProcessingChildContext'); - }, - onHostOperation: function (operation) { - checkDebugID(operation.instanceID); - emitEvent('onHostOperation', operation); - }, - onSetState: function () { - emitEvent('onSetState'); - }, - onSetChildren: function (debugID, childDebugIDs) { - checkDebugID(debugID); - childDebugIDs.forEach(checkDebugID); - emitEvent('onSetChildren', debugID, childDebugIDs); - }, - onBeforeMountComponent: function (debugID, element, parentDebugID) { - checkDebugID(debugID); - checkDebugID(parentDebugID, true); - emitEvent('onBeforeMountComponent', debugID, element, parentDebugID); - markBegin(debugID, 'mount'); - }, - onMountComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'mount'); - emitEvent('onMountComponent', debugID); - }, - onBeforeUpdateComponent: function (debugID, element) { - checkDebugID(debugID); - emitEvent('onBeforeUpdateComponent', debugID, element); - markBegin(debugID, 'update'); - }, - onUpdateComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'update'); - emitEvent('onUpdateComponent', debugID); - }, - onBeforeUnmountComponent: function (debugID) { - checkDebugID(debugID); - emitEvent('onBeforeUnmountComponent', debugID); - markBegin(debugID, 'unmount'); - }, - onUnmountComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'unmount'); - emitEvent('onUnmountComponent', debugID); - }, - onTestEvent: function () { - emitEvent('onTestEvent'); +/***/ }), +/* 400 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var BN = __webpack_require__(11); +var HmacDRBG = __webpack_require__(401); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; + +var KeyPair = __webpack_require__(402); +var Signature = __webpack_require__(403); + +function EC(options) { + if (!(this instanceof EC)) + return new EC(options); + + // Shortcut `elliptic.ec(curve-name)` + if (typeof options === 'string') { + assert(elliptic.curves.hasOwnProperty(options), 'Unknown curve ' + options); + + options = elliptic.curves[options]; } + + // Shortcut for `elliptic.ec(elliptic.curves.curveName)` + if (options instanceof elliptic.curves.PresetCurve) + options = { curve: options }; + + this.curve = options.curve.curve; + this.n = this.curve.n; + this.nh = this.n.ushrn(1); + this.g = this.curve.g; + + // Point on curve + this.g = options.curve.g; + this.g.precompute(options.curve.n.bitLength() + 1); + + // Hash for function for DRBG + this.hash = options.hash || options.curve.hash; +} +module.exports = EC; + +EC.prototype.keyPair = function keyPair(options) { + return new KeyPair(this, options); }; -// TODO remove these when RN/www gets updated -ReactDebugTool.addDevtool = ReactDebugTool.addHook; -ReactDebugTool.removeDevtool = ReactDebugTool.removeHook; +EC.prototype.keyFromPrivate = function keyFromPrivate(priv, enc) { + return KeyPair.fromPrivate(this, priv, enc); +}; -ReactDebugTool.addHook(ReactInvalidSetStateWarningHook); -ReactDebugTool.addHook(ReactComponentTreeHook); -var url = ExecutionEnvironment.canUseDOM && window.location.href || ''; -if (/[?&]react_perf\b/.test(url)) { - ReactDebugTool.beginProfiling(); -} +EC.prototype.keyFromPublic = function keyFromPublic(pub, enc) { + return KeyPair.fromPublic(this, pub, enc); +}; -module.exports = ReactDebugTool; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +EC.prototype.genKeyPair = function genKeyPair(options) { + if (!options) + options = {}; + + // Instantiate Hmac_DRBG + var drbg = new HmacDRBG({ + hash: this.hash, + pers: options.pers, + persEnc: options.persEnc || 'utf8', + entropy: options.entropy || elliptic.rand(this.hash.hmacStrength), + entropyEnc: options.entropy && options.entropyEnc || 'utf8', + nonce: this.n.toArray() + }); -/***/ }), -/* 146 */ -/***/ (function(module, exports, __webpack_require__) { + var bytes = this.n.byteLength(); + var ns2 = this.n.sub(new BN(2)); + do { + var priv = new BN(drbg.generate(bytes)); + if (priv.cmp(ns2) > 0) + continue; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + priv.iaddn(1); + return this.keyFromPrivate(priv); + } while (true); +}; +EC.prototype._truncateToN = function truncateToN(msg, truncOnly) { + var delta = msg.byteLength() * 8 - this.n.bitLength(); + if (delta > 0) + msg = msg.ushrn(delta); + if (!truncOnly && msg.cmp(this.n) >= 0) + return msg.sub(this.n); + else + return msg; +}; +EC.prototype.sign = function sign(msg, key, enc, options) { + if (typeof enc === 'object') { + options = enc; + enc = null; + } + if (!options) + options = {}; -var warning = __webpack_require__(2); + key = this.keyFromPrivate(key, enc); + msg = this._truncateToN(new BN(msg, 16)); -if (process.env.NODE_ENV !== 'production') { - var processingChildContext = false; + // Zero-extend key to provide enough entropy + var bytes = this.n.byteLength(); + var bkey = key.getPrivate().toArray('be', bytes); - var warnInvalidSetState = function () { - process.env.NODE_ENV !== 'production' ? warning(!processingChildContext, 'setState(...): Cannot call setState() inside getChildContext()') : void 0; - }; -} + // Zero-extend nonce to have the same byte size as N + var nonce = msg.toArray('be', bytes); -var ReactInvalidSetStateWarningHook = { - onBeginProcessingChildContext: function () { - processingChildContext = true; - }, - onEndProcessingChildContext: function () { - processingChildContext = false; - }, - onSetState: function () { - warnInvalidSetState(); + // Instantiate Hmac_DRBG + var drbg = new HmacDRBG({ + hash: this.hash, + entropy: bkey, + nonce: nonce, + pers: options.pers, + persEnc: options.persEnc || 'utf8' + }); + + // Number of bytes to generate + var ns1 = this.n.sub(new BN(1)); + + for (var iter = 0; true; iter++) { + var k = options.k ? + options.k(iter) : + new BN(drbg.generate(this.n.byteLength())); + k = this._truncateToN(k, true); + if (k.cmpn(1) <= 0 || k.cmp(ns1) >= 0) + continue; + + var kp = this.g.mul(k); + if (kp.isInfinity()) + continue; + + var kpX = kp.getX(); + var r = kpX.umod(this.n); + if (r.cmpn(0) === 0) + continue; + + var s = k.invm(this.n).mul(r.mul(key.getPrivate()).iadd(msg)); + s = s.umod(this.n); + if (s.cmpn(0) === 0) + continue; + + var recoveryParam = (kp.getY().isOdd() ? 1 : 0) | + (kpX.cmp(r) !== 0 ? 2 : 0); + + // Use complement of `s`, if it is > `n / 2` + if (options.canonical && s.cmp(this.nh) > 0) { + s = this.n.sub(s); + recoveryParam ^= 1; + } + + return new Signature({ r: r, s: s, recoveryParam: recoveryParam }); } }; -module.exports = ReactInvalidSetStateWarningHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +EC.prototype.verify = function verify(msg, signature, key, enc) { + msg = this._truncateToN(new BN(msg, 16)); + key = this.keyFromPublic(key, enc); + signature = new Signature(signature, 'hex'); -/***/ }), -/* 147 */ -/***/ (function(module, exports, __webpack_require__) { + // Perform primitive values validation + var r = signature.r; + var s = signature.s; + if (r.cmpn(1) < 0 || r.cmp(this.n) >= 0) + return false; + if (s.cmpn(1) < 0 || s.cmp(this.n) >= 0) + return false; -"use strict"; -/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + // Validate signature + var sinv = s.invm(this.n); + var u1 = sinv.mul(msg).umod(this.n); + var u2 = sinv.mul(r).umod(this.n); + if (!this.curve._maxwellTrick) { + var p = this.g.mulAdd(u1, key.getPublic(), u2); + if (p.isInfinity()) + return false; + return p.getX().umod(this.n).cmp(r) === 0; + } -var history = []; + // NOTE: Greg Maxwell's trick, inspired by: + // https://git.io/vad3K -var ReactHostOperationHistoryHook = { - onHostOperation: function (operation) { - history.push(operation); - }, - clearHistory: function () { - if (ReactHostOperationHistoryHook._preventClearing) { - // Should only be used for tests. - return; + var p = this.g.jmulAdd(u1, key.getPublic(), u2); + if (p.isInfinity()) + return false; + + // Compare `p.x` of Jacobian point with `r`, + // this will do `p.x == r * p.z^2` instead of multiplying `p.x` by the + // inverse of `p.z^2` + return p.eqXToP(r); +}; + +EC.prototype.recoverPubKey = function(msg, signature, j, enc) { + assert((3 & j) === j, 'The recovery param is more than two bits'); + signature = new Signature(signature, enc); + + var n = this.n; + var e = new BN(msg); + var r = signature.r; + var s = signature.s; + + // A set LSB signifies that the y-coordinate is odd + var isYOdd = j & 1; + var isSecondKey = j >> 1; + if (r.cmp(this.curve.p.umod(this.curve.n)) >= 0 && isSecondKey) + throw new Error('Unable to find sencond key candinate'); + + // 1.1. Let x = r + jn. + if (isSecondKey) + r = this.curve.pointFromX(r.add(this.curve.n), isYOdd); + else + r = this.curve.pointFromX(r, isYOdd); + + var rInv = signature.r.invm(n); + var s1 = n.sub(e).mul(rInv).umod(n); + var s2 = s.mul(rInv).umod(n); + + // 1.6.1 Compute Q = r^-1 (sR - eG) + // Q = r^-1 (sR + -eG) + return this.g.mulAdd(s1, r, s2); +}; + +EC.prototype.getKeyRecoveryParam = function(e, signature, Q, enc) { + signature = new Signature(signature, enc); + if (signature.recoveryParam !== null) + return signature.recoveryParam; + + for (var i = 0; i < 4; i++) { + var Qprime; + try { + Qprime = this.recoverPubKey(e, signature, i); + } catch (e) { + continue; } - history = []; - }, - getHistory: function () { - return history; + if (Qprime.eq(Q)) + return i; } + throw new Error('Unable to find valid recovery factor'); }; -module.exports = ReactHostOperationHistoryHook; /***/ }), -/* 148 */ +/* 401 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +var hash = __webpack_require__(105); +var utils = __webpack_require__(170); +var assert = __webpack_require__(21); -var performance = __webpack_require__(149); +function HmacDRBG(options) { + if (!(this instanceof HmacDRBG)) + return new HmacDRBG(options); + this.hash = options.hash; + this.predResist = !!options.predResist; -var performanceNow; + this.outLen = this.hash.outSize; + this.minEntropy = options.minEntropy || this.hash.hmacStrength; -/** - * Detect if we can use `window.performance.now()` and gracefully fallback to - * `Date.now()` if it doesn't exist. We need to support Firefox < 15 for now - * because of Facebook's testing infrastructure. - */ -if (performance.now) { - performanceNow = function performanceNow() { - return performance.now(); - }; -} else { - performanceNow = function performanceNow() { - return Date.now(); - }; + this._reseed = null; + this.reseedInterval = null; + this.K = null; + this.V = null; + + var entropy = utils.toArray(options.entropy, options.entropyEnc || 'hex'); + var nonce = utils.toArray(options.nonce, options.nonceEnc || 'hex'); + var pers = utils.toArray(options.pers, options.persEnc || 'hex'); + assert(entropy.length >= (this.minEntropy / 8), + 'Not enough entropy. Minimum is: ' + this.minEntropy + ' bits'); + this._init(entropy, nonce, pers); } +module.exports = HmacDRBG; -module.exports = performanceNow; +HmacDRBG.prototype._init = function init(entropy, nonce, pers) { + var seed = entropy.concat(nonce).concat(pers); -/***/ }), -/* 149 */ -/***/ (function(module, exports, __webpack_require__) { + this.K = new Array(this.outLen / 8); + this.V = new Array(this.outLen / 8); + for (var i = 0; i < this.V.length; i++) { + this.K[i] = 0x00; + this.V[i] = 0x01; + } -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + this._update(seed); + this._reseed = 1; + this.reseedInterval = 0x1000000000000; // 2^48 +}; +HmacDRBG.prototype._hmac = function hmac() { + return new hash.hmac(this.hash, this.K); +}; +HmacDRBG.prototype._update = function update(seed) { + var kmac = this._hmac() + .update(this.V) + .update([ 0x00 ]); + if (seed) + kmac = kmac.update(seed); + this.K = kmac.digest(); + this.V = this._hmac().update(this.V).digest(); + if (!seed) + return; -var ExecutionEnvironment = __webpack_require__(8); + this.K = this._hmac() + .update(this.V) + .update([ 0x01 ]) + .update(seed) + .digest(); + this.V = this._hmac().update(this.V).digest(); +}; -var performance; +HmacDRBG.prototype.reseed = function reseed(entropy, entropyEnc, add, addEnc) { + // Optional entropy enc + if (typeof entropyEnc !== 'string') { + addEnc = add; + add = entropyEnc; + entropyEnc = null; + } -if (ExecutionEnvironment.canUseDOM) { - performance = window.performance || window.msPerformance || window.webkitPerformance; -} + entropy = utils.toArray(entropy, entropyEnc); + add = utils.toArray(add, addEnc); -module.exports = performance || {}; + assert(entropy.length >= (this.minEntropy / 8), + 'Not enough entropy. Minimum is: ' + this.minEntropy + ' bits'); -/***/ }), -/* 150 */ -/***/ (function(module, exports, __webpack_require__) { + this._update(entropy.concat(add || [])); + this._reseed = 1; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +HmacDRBG.prototype.generate = function generate(len, enc, add, addEnc) { + if (this._reseed > this.reseedInterval) + throw new Error('Reseed is required'); + // Optional encoding + if (typeof enc !== 'string') { + addEnc = add; + add = enc; + enc = null; + } + // Optional additional data + if (add) { + add = utils.toArray(add, addEnc || 'hex'); + this._update(add); + } -/** - * Module that is injectable into `EventPluginHub`, that specifies a - * deterministic ordering of `EventPlugin`s. A convenient way to reason about - * plugins, without having to package every one of them. This is better than - * having plugins be ordered in the same order that they are injected because - * that ordering would be influenced by the packaging order. - * `ResponderEventPlugin` must occur before `SimpleEventPlugin` so that - * preventing default on events is convenient in `SimpleEventPlugin` handlers. - */ + var temp = []; + while (temp.length < len) { + this.V = this._hmac().update(this.V).digest(); + temp = temp.concat(this.V); + } -var DefaultEventPluginOrder = ['ResponderEventPlugin', 'SimpleEventPlugin', 'TapEventPlugin', 'EnterLeaveEventPlugin', 'ChangeEventPlugin', 'SelectEventPlugin', 'BeforeInputEventPlugin']; + var res = temp.slice(0, len); + this._update(add); + this._reseed++; + return utils.encode(res, enc); +}; -module.exports = DefaultEventPluginOrder; /***/ }), -/* 151 */ +/* 402 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; -var EventPropagators = __webpack_require__(31); -var ReactDOMComponentTree = __webpack_require__(6); -var SyntheticMouseEvent = __webpack_require__(42); +function KeyPair(ec, options) { + this.ec = ec; + this.priv = null; + this.pub = null; -var eventTypes = { - mouseEnter: { - registrationName: 'onMouseEnter', - dependencies: ['topMouseOut', 'topMouseOver'] - }, - mouseLeave: { - registrationName: 'onMouseLeave', - dependencies: ['topMouseOut', 'topMouseOver'] - } + // KeyPair(ec, { priv: ..., pub: ... }) + if (options.priv) + this._importPrivate(options.priv, options.privEnc); + if (options.pub) + this._importPublic(options.pub, options.pubEnc); +} +module.exports = KeyPair; + +KeyPair.fromPublic = function fromPublic(ec, pub, enc) { + if (pub instanceof KeyPair) + return pub; + + return new KeyPair(ec, { + pub: pub, + pubEnc: enc + }); }; -var EnterLeaveEventPlugin = { - eventTypes: eventTypes, +KeyPair.fromPrivate = function fromPrivate(ec, priv, enc) { + if (priv instanceof KeyPair) + return priv; - /** - * For almost every interaction we care about, there will be both a top-level - * `mouseover` and `mouseout` event that occurs. Only use `mouseout` so that - * we do not extract duplicate events. However, moving the mouse into the - * browser from outside will not fire a `mouseout` event. In this case, we use - * the `mouseover` top-level event. - */ - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - if (topLevelType === 'topMouseOver' && (nativeEvent.relatedTarget || nativeEvent.fromElement)) { - return null; - } - if (topLevelType !== 'topMouseOut' && topLevelType !== 'topMouseOver') { - // Must not be a mouse in or mouse out - ignoring. - return null; - } + return new KeyPair(ec, { + priv: priv, + privEnc: enc + }); +}; - var win; - if (nativeEventTarget.window === nativeEventTarget) { - // `nativeEventTarget` is probably a window object. - win = nativeEventTarget; - } else { - // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. - var doc = nativeEventTarget.ownerDocument; - if (doc) { - win = doc.defaultView || doc.parentWindow; - } else { - win = window; - } - } +KeyPair.prototype.validate = function validate() { + var pub = this.getPublic(); - var from; - var to; - if (topLevelType === 'topMouseOut') { - from = targetInst; - var related = nativeEvent.relatedTarget || nativeEvent.toElement; - to = related ? ReactDOMComponentTree.getClosestInstanceFromNode(related) : null; - } else { - // Moving to a node from outside the window. - from = null; - to = targetInst; - } + if (pub.isInfinity()) + return { result: false, reason: 'Invalid public key' }; + if (!pub.validate()) + return { result: false, reason: 'Public key is not a point' }; + if (!pub.mul(this.ec.curve.n).isInfinity()) + return { result: false, reason: 'Public key * N != O' }; - if (from === to) { - // Nothing pertains to our managed components. - return null; - } + return { result: true, reason: null }; +}; - var fromNode = from == null ? win : ReactDOMComponentTree.getNodeFromInstance(from); - var toNode = to == null ? win : ReactDOMComponentTree.getNodeFromInstance(to); +KeyPair.prototype.getPublic = function getPublic(compact, enc) { + // compact is optional argument + if (typeof compact === 'string') { + enc = compact; + compact = null; + } - var leave = SyntheticMouseEvent.getPooled(eventTypes.mouseLeave, from, nativeEvent, nativeEventTarget); - leave.type = 'mouseleave'; - leave.target = fromNode; - leave.relatedTarget = toNode; + if (!this.pub) + this.pub = this.ec.g.mul(this.priv); - var enter = SyntheticMouseEvent.getPooled(eventTypes.mouseEnter, to, nativeEvent, nativeEventTarget); - enter.type = 'mouseenter'; - enter.target = toNode; - enter.relatedTarget = fromNode; + if (!enc) + return this.pub; - EventPropagators.accumulateEnterLeaveDispatches(leave, enter, from, to); + return this.pub.encode(enc, compact); +}; - return [leave, enter]; +KeyPair.prototype.getPrivate = function getPrivate(enc) { + if (enc === 'hex') + return this.priv.toString(16, 2); + else + return this.priv; +}; + +KeyPair.prototype._importPrivate = function _importPrivate(key, enc) { + this.priv = new BN(key, enc || 16); + + // Ensure that the priv won't be bigger than n, otherwise we may fail + // in fixed multiplication method + this.priv = this.priv.umod(this.ec.curve.n); +}; + +KeyPair.prototype._importPublic = function _importPublic(key, enc) { + if (key.x || key.y) { + // Montgomery points only have an `x` coordinate. + // Weierstrass/Edwards points on the other hand have both `x` and + // `y` coordinates. + if (this.ec.curve.type === 'mont') { + assert(key.x, 'Need x coordinate'); + } else if (this.ec.curve.type === 'short' || + this.ec.curve.type === 'edwards') { + assert(key.x && key.y, 'Need both x and y coordinate'); + } + this.pub = this.ec.curve.point(key.x, key.y); + return; } + this.pub = this.ec.curve.decodePoint(key, enc); +}; + +// ECDH +KeyPair.prototype.derive = function derive(pub) { + return pub.mul(this.priv).getX(); +}; + +// ECDSA +KeyPair.prototype.sign = function sign(msg, enc, options) { + return this.ec.sign(msg, this, enc, options); +}; + +KeyPair.prototype.verify = function verify(msg, signature) { + return this.ec.verify(msg, signature, this); +}; + +KeyPair.prototype.inspect = function inspect() { + return '<Key priv: ' + (this.priv && this.priv.toString(16, 2)) + + ' pub: ' + (this.pub && this.pub.inspect()) + ' >'; }; -module.exports = EnterLeaveEventPlugin; /***/ }), -/* 152 */ +/* 403 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var BN = __webpack_require__(11); -var DOMProperty = __webpack_require__(17); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; -var MUST_USE_PROPERTY = DOMProperty.injection.MUST_USE_PROPERTY; -var HAS_BOOLEAN_VALUE = DOMProperty.injection.HAS_BOOLEAN_VALUE; -var HAS_NUMERIC_VALUE = DOMProperty.injection.HAS_NUMERIC_VALUE; -var HAS_POSITIVE_NUMERIC_VALUE = DOMProperty.injection.HAS_POSITIVE_NUMERIC_VALUE; -var HAS_OVERLOADED_BOOLEAN_VALUE = DOMProperty.injection.HAS_OVERLOADED_BOOLEAN_VALUE; +function Signature(options, enc) { + if (options instanceof Signature) + return options; -var HTMLDOMPropertyConfig = { - isCustomAttribute: RegExp.prototype.test.bind(new RegExp('^(data|aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$')), - Properties: { - /** - * Standard Properties - */ - accept: 0, - acceptCharset: 0, - accessKey: 0, - action: 0, - allowFullScreen: HAS_BOOLEAN_VALUE, - allowTransparency: 0, - alt: 0, - // specifies target context for links with `preload` type - as: 0, - async: HAS_BOOLEAN_VALUE, - autoComplete: 0, - // autoFocus is polyfilled/normalized by AutoFocusUtils - // autoFocus: HAS_BOOLEAN_VALUE, - autoPlay: HAS_BOOLEAN_VALUE, - capture: HAS_BOOLEAN_VALUE, - cellPadding: 0, - cellSpacing: 0, - charSet: 0, - challenge: 0, - checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - cite: 0, - classID: 0, - className: 0, - cols: HAS_POSITIVE_NUMERIC_VALUE, - colSpan: 0, - content: 0, - contentEditable: 0, - contextMenu: 0, - controls: HAS_BOOLEAN_VALUE, - coords: 0, - crossOrigin: 0, - data: 0, // For `<object />` acts as `src`. - dateTime: 0, - 'default': HAS_BOOLEAN_VALUE, - defer: HAS_BOOLEAN_VALUE, - dir: 0, - disabled: HAS_BOOLEAN_VALUE, - download: HAS_OVERLOADED_BOOLEAN_VALUE, - draggable: 0, - encType: 0, - form: 0, - formAction: 0, - formEncType: 0, - formMethod: 0, - formNoValidate: HAS_BOOLEAN_VALUE, - formTarget: 0, - frameBorder: 0, - headers: 0, - height: 0, - hidden: HAS_BOOLEAN_VALUE, - high: 0, - href: 0, - hrefLang: 0, - htmlFor: 0, - httpEquiv: 0, - icon: 0, - id: 0, - inputMode: 0, - integrity: 0, - is: 0, - keyParams: 0, - keyType: 0, - kind: 0, - label: 0, - lang: 0, - list: 0, - loop: HAS_BOOLEAN_VALUE, - low: 0, - manifest: 0, - marginHeight: 0, - marginWidth: 0, - max: 0, - maxLength: 0, - media: 0, - mediaGroup: 0, - method: 0, - min: 0, - minLength: 0, - // Caution; `option.selected` is not updated if `select.multiple` is - // disabled with `removeAttribute`. - multiple: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - muted: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - name: 0, - nonce: 0, - noValidate: HAS_BOOLEAN_VALUE, - open: HAS_BOOLEAN_VALUE, - optimum: 0, - pattern: 0, - placeholder: 0, - playsInline: HAS_BOOLEAN_VALUE, - poster: 0, - preload: 0, - profile: 0, - radioGroup: 0, - readOnly: HAS_BOOLEAN_VALUE, - referrerPolicy: 0, - rel: 0, - required: HAS_BOOLEAN_VALUE, - reversed: HAS_BOOLEAN_VALUE, - role: 0, - rows: HAS_POSITIVE_NUMERIC_VALUE, - rowSpan: HAS_NUMERIC_VALUE, - sandbox: 0, - scope: 0, - scoped: HAS_BOOLEAN_VALUE, - scrolling: 0, - seamless: HAS_BOOLEAN_VALUE, - selected: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - shape: 0, - size: HAS_POSITIVE_NUMERIC_VALUE, - sizes: 0, - span: HAS_POSITIVE_NUMERIC_VALUE, - spellCheck: 0, - src: 0, - srcDoc: 0, - srcLang: 0, - srcSet: 0, - start: HAS_NUMERIC_VALUE, - step: 0, - style: 0, - summary: 0, - tabIndex: 0, - target: 0, - title: 0, - // Setting .type throws on non-<input> tags - type: 0, - useMap: 0, - value: 0, - width: 0, - wmode: 0, - wrap: 0, + if (this._importDER(options, enc)) + return; - /** - * RDFa Properties - */ - about: 0, - datatype: 0, - inlist: 0, - prefix: 0, - // property is also supported for OpenGraph in meta tags. - property: 0, - resource: 0, - 'typeof': 0, - vocab: 0, + assert(options.r && options.s, 'Signature without r or s'); + this.r = new BN(options.r, 16); + this.s = new BN(options.s, 16); + if (options.recoveryParam === undefined) + this.recoveryParam = null; + else + this.recoveryParam = options.recoveryParam; +} +module.exports = Signature; - /** - * Non-standard Properties - */ - // autoCapitalize and autoCorrect are supported in Mobile Safari for - // keyboard hints. - autoCapitalize: 0, - autoCorrect: 0, - // autoSave allows WebKit/Blink to persist values of input fields on page reloads - autoSave: 0, - // color is for Safari mask-icon link - color: 0, - // itemProp, itemScope, itemType are for - // Microdata support. See http://schema.org/docs/gs.html - itemProp: 0, - itemScope: HAS_BOOLEAN_VALUE, - itemType: 0, - // itemID and itemRef are for Microdata support as well but - // only specified in the WHATWG spec document. See - // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api - itemID: 0, - itemRef: 0, - // results show looking glass icon and recent searches on input - // search fields in WebKit/Blink - results: 0, - // IE-only attribute that specifies security restrictions on an iframe - // as an alternative to the sandbox attribute on IE<10 - security: 0, - // IE-only attribute that controls focus behavior - unselectable: 0 - }, - DOMAttributeNames: { - acceptCharset: 'accept-charset', - className: 'class', - htmlFor: 'for', - httpEquiv: 'http-equiv' - }, - DOMPropertyNames: {}, - DOMMutationMethods: { - value: function (node, value) { - if (value == null) { - return node.removeAttribute('value'); - } +function Position() { + this.place = 0; +} + +function getLength(buf, p) { + var initial = buf[p.place++]; + if (!(initial & 0x80)) { + return initial; + } + var octetLen = initial & 0xf; + var val = 0; + for (var i = 0, off = p.place; i < octetLen; i++, off++) { + val <<= 8; + val |= buf[off]; + } + p.place = off; + return val; +} + +function rmPadding(buf) { + var i = 0; + var len = buf.length - 1; + while (!buf[i] && !(buf[i + 1] & 0x80) && i < len) { + i++; + } + if (i === 0) { + return buf; + } + return buf.slice(i); +} + +Signature.prototype._importDER = function _importDER(data, enc) { + data = utils.toArray(data, enc); + var p = new Position(); + if (data[p.place++] !== 0x30) { + return false; + } + var len = getLength(data, p); + if ((len + p.place) !== data.length) { + return false; + } + if (data[p.place++] !== 0x02) { + return false; + } + var rlen = getLength(data, p); + var r = data.slice(p.place, rlen + p.place); + p.place += rlen; + if (data[p.place++] !== 0x02) { + return false; + } + var slen = getLength(data, p); + if (data.length !== slen + p.place) { + return false; + } + var s = data.slice(p.place, slen + p.place); + if (r[0] === 0 && (r[1] & 0x80)) { + r = r.slice(1); + } + if (s[0] === 0 && (s[1] & 0x80)) { + s = s.slice(1); + } - // Number inputs get special treatment due to some edge cases in - // Chrome. Let everything else assign the value attribute as normal. - // https://github.com/facebook/react/issues/7253#issuecomment-236074326 - if (node.type !== 'number' || node.hasAttribute('value') === false) { - node.setAttribute('value', '' + value); - } else if (node.validity && !node.validity.badInput && node.ownerDocument.activeElement !== node) { - // Don't assign an attribute if validation reports bad - // input. Chrome will clear the value. Additionally, don't - // operate on inputs that have focus, otherwise Chrome might - // strip off trailing decimal places and cause the user's - // cursor position to jump to the beginning of the input. - // - // In ReactDOMInput, we have an onBlur event that will trigger - // this function again when focus is lost. - node.setAttribute('value', '' + value); - } - } + this.r = new BN(r); + this.s = new BN(s); + this.recoveryParam = null; + + return true; +}; + +function constructLength(arr, len) { + if (len < 0x80) { + arr.push(len); + return; } + var octets = 1 + (Math.log(len) / Math.LN2 >>> 3); + arr.push(octets | 0x80); + while (--octets) { + arr.push((len >>> (octets << 3)) & 0xff); + } + arr.push(len); +} + +Signature.prototype.toDER = function toDER(enc) { + var r = this.r.toArray(); + var s = this.s.toArray(); + + // Pad values + if (r[0] & 0x80) + r = [ 0 ].concat(r); + // Pad values + if (s[0] & 0x80) + s = [ 0 ].concat(s); + + r = rmPadding(r); + s = rmPadding(s); + + while (!s[0] && !(s[1] & 0x80)) { + s = s.slice(1); + } + var arr = [ 0x02 ]; + constructLength(arr, r.length); + arr = arr.concat(r); + arr.push(0x02); + constructLength(arr, s.length); + var backHalf = arr.concat(s); + var res = [ 0x30 ]; + constructLength(res, backHalf.length); + res = res.concat(backHalf); + return utils.encode(res, enc); }; -module.exports = HTMLDOMPropertyConfig; /***/ }), -/* 153 */ +/* 404 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; + + +var hash = __webpack_require__(105); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; +var parseBytes = utils.parseBytes; +var KeyPair = __webpack_require__(405); +var Signature = __webpack_require__(406); + +function EDDSA(curve) { + assert(curve === 'ed25519', 'only tested with ed25519 so far'); + + if (!(this instanceof EDDSA)) + return new EDDSA(curve); + + var curve = elliptic.curves[curve].curve; + this.curve = curve; + this.g = curve.g; + this.g.precompute(curve.n.bitLength() + 1); + + this.pointClass = curve.point().constructor; + this.encodingLength = Math.ceil(curve.n.bitLength() / 8); + this.hash = hash.sha512; +} + +module.exports = EDDSA; + /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +* @param {Array|String} message - message bytes +* @param {Array|String|KeyPair} secret - secret bytes or a keypair +* @returns {Signature} - signature +*/ +EDDSA.prototype.sign = function sign(message, secret) { + message = parseBytes(message); + var key = this.keyFromSecret(secret); + var r = this.hashInt(key.messagePrefix(), message); + var R = this.g.mul(r); + var Rencoded = this.encodePoint(R); + var s_ = this.hashInt(Rencoded, key.pubBytes(), message) + .mul(key.priv()); + var S = r.add(s_).umod(this.curve.n); + return this.makeSignature({ R: R, S: S, Rencoded: Rencoded }); +}; + +/** +* @param {Array} message - message bytes +* @param {Array|String|Signature} sig - sig bytes +* @param {Array|String|Point|KeyPair} pub - public key +* @returns {Boolean} - true if public key matches sig of message +*/ +EDDSA.prototype.verify = function verify(message, sig, pub) { + message = parseBytes(message); + sig = this.makeSignature(sig); + var key = this.keyFromPublic(pub); + var h = this.hashInt(sig.Rencoded(), key.pubBytes(), message); + var SG = this.g.mul(sig.S()); + var RplusAh = sig.R().add(key.pub().mul(h)); + return RplusAh.eq(SG); +}; + +EDDSA.prototype.hashInt = function hashInt() { + var hash = this.hash(); + for (var i = 0; i < arguments.length; i++) + hash.update(arguments[i]); + return utils.intFromLE(hash.digest()).umod(this.curve.n); +}; +EDDSA.prototype.keyFromPublic = function keyFromPublic(pub) { + return KeyPair.fromPublic(this, pub); +}; +EDDSA.prototype.keyFromSecret = function keyFromSecret(secret) { + return KeyPair.fromSecret(this, secret); +}; -var DOMChildrenOperations = __webpack_require__(55); -var ReactDOMIDOperations = __webpack_require__(158); +EDDSA.prototype.makeSignature = function makeSignature(sig) { + if (sig instanceof Signature) + return sig; + return new Signature(this, sig); +}; /** - * Abstracts away all functionality of the reconciler that requires knowledge of - * the browser context. TODO: These callers should be refactored to avoid the - * need for this injection. - */ -var ReactComponentBrowserEnvironment = { - processChildrenUpdates: ReactDOMIDOperations.dangerouslyProcessChildrenUpdates, +* * https://tools.ietf.org/html/draft-josefsson-eddsa-ed25519-03#section-5.2 +* +* EDDSA defines methods for encoding and decoding points and integers. These are +* helper convenience methods, that pass along to utility functions implied +* parameters. +* +*/ +EDDSA.prototype.encodePoint = function encodePoint(point) { + var enc = point.getY().toArray('le', this.encodingLength); + enc[this.encodingLength - 1] |= point.getX().isOdd() ? 0x80 : 0; + return enc; +}; - replaceNodeWithMarkup: DOMChildrenOperations.dangerouslyReplaceNodeWithMarkup +EDDSA.prototype.decodePoint = function decodePoint(bytes) { + bytes = utils.parseBytes(bytes); + + var lastIx = bytes.length - 1; + var normed = bytes.slice(0, lastIx).concat(bytes[lastIx] & ~0x80); + var xIsOdd = (bytes[lastIx] & 0x80) !== 0; + + var y = utils.intFromLE(normed); + return this.curve.pointFromY(y, xIsOdd); +}; + +EDDSA.prototype.encodeInt = function encodeInt(num) { + return num.toArray('le', this.encodingLength); +}; + +EDDSA.prototype.decodeInt = function decodeInt(bytes) { + return utils.intFromLE(bytes); +}; + +EDDSA.prototype.isPoint = function isPoint(val) { + return val instanceof this.pointClass; }; -module.exports = ReactComponentBrowserEnvironment; /***/ }), -/* 154 */ +/* 405 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; +var parseBytes = utils.parseBytes; +var cachedProperty = utils.cachedProperty; + +/** +* @param {EDDSA} eddsa - instance +* @param {Object} params - public/private key parameters +* +* @param {Array<Byte>} [params.secret] - secret seed bytes +* @param {Point} [params.pub] - public key point (aka `A` in eddsa terms) +* @param {Array<Byte>} [params.pub] - public key point encoded as bytes +* +*/ +function KeyPair(eddsa, params) { + this.eddsa = eddsa; + this._secret = parseBytes(params.secret); + if (eddsa.isPoint(params.pub)) + this._pub = params.pub; + else + this._pubBytes = parseBytes(params.pub); +} + +KeyPair.fromPublic = function fromPublic(eddsa, pub) { + if (pub instanceof KeyPair) + return pub; + return new KeyPair(eddsa, { pub: pub }); +}; + +KeyPair.fromSecret = function fromSecret(eddsa, secret) { + if (secret instanceof KeyPair) + return secret; + return new KeyPair(eddsa, { secret: secret }); +}; -var _prodInvariant = __webpack_require__(3); +KeyPair.prototype.secret = function secret() { + return this._secret; +}; -var DOMLazyTree = __webpack_require__(27); -var ExecutionEnvironment = __webpack_require__(8); +cachedProperty(KeyPair, 'pubBytes', function pubBytes() { + return this.eddsa.encodePoint(this.pub()); +}); -var createNodesFromMarkup = __webpack_require__(155); -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); +cachedProperty(KeyPair, 'pub', function pub() { + if (this._pubBytes) + return this.eddsa.decodePoint(this._pubBytes); + return this.eddsa.g.mul(this.priv()); +}); -var Danger = { - /** - * Replaces a node with a string of markup at its current position within its - * parent. The markup must render into a single root node. - * - * @param {DOMElement} oldChild Child node to replace. - * @param {string} markup Markup to render in place of the child node. - * @internal - */ - dangerouslyReplaceNodeWithMarkup: function (oldChild, markup) { - !ExecutionEnvironment.canUseDOM ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot render markup in a worker thread. Make sure `window` and `document` are available globally before requiring React when unit testing or use ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('56') : void 0; - !markup ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Missing markup.') : _prodInvariant('57') : void 0; - !(oldChild.nodeName !== 'HTML') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot replace markup of the <html> node. This is because browser quirks make this unreliable and/or slow. If you want to render to the root you must use server rendering. See ReactDOMServer.renderToString().') : _prodInvariant('58') : void 0; +cachedProperty(KeyPair, 'privBytes', function privBytes() { + var eddsa = this.eddsa; + var hash = this.hash(); + var lastIx = eddsa.encodingLength - 1; - if (typeof markup === 'string') { - var newChild = createNodesFromMarkup(markup, emptyFunction)[0]; - oldChild.parentNode.replaceChild(newChild, oldChild); - } else { - DOMLazyTree.replaceChildWithTree(oldChild, markup); - } - } + var a = hash.slice(0, eddsa.encodingLength); + a[0] &= 248; + a[lastIx] &= 127; + a[lastIx] |= 64; + + return a; +}); + +cachedProperty(KeyPair, 'priv', function priv() { + return this.eddsa.decodeInt(this.privBytes()); +}); + +cachedProperty(KeyPair, 'hash', function hash() { + return this.eddsa.hash().update(this.secret()).digest(); +}); + +cachedProperty(KeyPair, 'messagePrefix', function messagePrefix() { + return this.hash().slice(this.eddsa.encodingLength); +}); + +KeyPair.prototype.sign = function sign(message) { + assert(this._secret, 'KeyPair can only verify'); + return this.eddsa.sign(message, this); }; -module.exports = Danger; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +KeyPair.prototype.verify = function verify(message, sig) { + return this.eddsa.verify(message, sig, this); +}; + +KeyPair.prototype.getSecret = function getSecret(enc) { + assert(this._secret, 'KeyPair is public only'); + return utils.encode(this.secret(), enc); +}; + +KeyPair.prototype.getPublic = function getPublic(enc) { + return utils.encode(this.pubBytes(), enc); +}; + +module.exports = KeyPair; + /***/ }), -/* 155 */ +/* 406 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) { + + +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); +var utils = elliptic.utils; +var assert = utils.assert; +var cachedProperty = utils.cachedProperty; +var parseBytes = utils.parseBytes; /** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +* @param {EDDSA} eddsa - eddsa instance +* @param {Array<Bytes>|Object} sig - +* @param {Array<Bytes>|Point} [sig.R] - R point as Point or bytes +* @param {Array<Bytes>|bn} [sig.S] - S scalar as bn or bytes +* @param {Array<Bytes>} [sig.Rencoded] - R point encoded +* @param {Array<Bytes>} [sig.Sencoded] - S scalar encoded +*/ +function Signature(eddsa, sig) { + this.eddsa = eddsa; -/*eslint-disable fb-www/unsafe-html*/ + if (typeof sig !== 'object') + sig = parseBytes(sig); -var ExecutionEnvironment = __webpack_require__(8); + if (Array.isArray(sig)) { + sig = { + R: sig.slice(0, eddsa.encodingLength), + S: sig.slice(eddsa.encodingLength) + }; + } -var createArrayFromMixed = __webpack_require__(156); -var getMarkupWrap = __webpack_require__(157); -var invariant = __webpack_require__(1); + assert(sig.R && sig.S, 'Signature without R or S'); -/** - * Dummy container used to render all markup. - */ -var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; + if (eddsa.isPoint(sig.R)) + this._R = sig.R; + if (sig.S instanceof BN) + this._S = sig.S; -/** - * Pattern used by `getNodeName`. - */ -var nodeNamePattern = /^\s*<(\w+)/; + this._Rencoded = Array.isArray(sig.R) ? sig.R : sig.Rencoded; + this._Sencoded = Array.isArray(sig.S) ? sig.S : sig.Sencoded; +} + +cachedProperty(Signature, 'S', function S() { + return this.eddsa.decodeInt(this.Sencoded()); +}); + +cachedProperty(Signature, 'R', function R() { + return this.eddsa.decodePoint(this.Rencoded()); +}); + +cachedProperty(Signature, 'Rencoded', function Rencoded() { + return this.eddsa.encodePoint(this.R()); +}); + +cachedProperty(Signature, 'Sencoded', function Sencoded() { + return this.eddsa.encodeInt(this.S()); +}); + +Signature.prototype.toBytes = function toBytes() { + return this.Rencoded().concat(this.Sencoded()); +}; + +Signature.prototype.toHex = function toHex() { + return utils.encode(this.toBytes(), 'hex').toUpperCase(); +}; + +module.exports = Signature; + + +/***/ }), +/* 407 */ +/***/ (function(module, exports) { + +module.exports = { + "name": "bigi", + "version": "1.4.2", + "description": "Big integers.", + "keywords": [ + "cryptography", + "math", + "bitcoin", + "arbitrary", + "precision", + "arithmetic", + "big", + "integer", + "int", + "number", + "biginteger", + "bigint", + "bignumber", + "decimal", + "float" + ], + "devDependencies": { + "coveralls": "^2.11.2", + "istanbul": "^0.3.5", + "jshint": "^2.5.1", + "mocha": "^2.1.0", + "mochify": "^2.1.0" + }, + "repository": { + "url": "https://github.com/cryptocoinjs/bigi", + "type": "git" + }, + "main": "./lib/index.js", + "scripts": { + "browser-test": "./node_modules/.bin/mochify --wd -R spec", + "test": "./node_modules/.bin/_mocha -- test/*.js", + "jshint": "./node_modules/.bin/jshint --config jshint.json lib/*.js ; true", + "unit": "./node_modules/.bin/mocha", + "coverage": "./node_modules/.bin/istanbul cover ./node_modules/.bin/_mocha -- --reporter list test/*.js", + "coveralls": "npm run-script coverage && node ./node_modules/.bin/coveralls < coverage/lcov.info" + }, + "dependencies": {}, + "testling": { + "files": "test/*.js", + "harness": "mocha", + "browsers": [ + "ie/9..latest", + "firefox/latest", + "chrome/latest", + "safari/6.0..latest", + "iphone/6.0..latest", + "android-browser/4.2..latest" + ] + } +}; + +/***/ }), +/* 408 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {// FIXME: Kind of a weird way to throw exceptions, consider removing +var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(175) /** - * Extracts the `nodeName` of the first element in a string of markup. + * Turns a byte array into a big integer. * - * @param {string} markup String of markup. - * @return {?string} Node name of the supplied markup. + * This function will interpret a byte array as a big integer in big + * endian notation. */ -function getNodeName(markup) { - var nodeNameMatch = markup.match(nodeNamePattern); - return nodeNameMatch && nodeNameMatch[1].toLowerCase(); +BigInteger.fromByteArrayUnsigned = function(byteArray) { + // BigInteger expects a DER integer conformant byte array + if (byteArray[0] & 0x80) { + return new BigInteger([0].concat(byteArray)) + } + + return new BigInteger(byteArray) } /** - * Creates an array containing the nodes rendered from the supplied markup. The - * optionally supplied `handleScript` function will be invoked once for each - * <script> element that is rendered. If no `handleScript` function is supplied, - * an exception is thrown if any <script> elements are rendered. + * Returns a byte array representation of the big integer. * - * @param {string} markup A string of valid HTML markup. - * @param {?function} handleScript Invoked once for each rendered <script>. - * @return {array<DOMElement|DOMTextNode>} An array of rendered nodes. + * This returns the absolute of the contained value in big endian + * form. A value of zero results in an empty array. */ -function createNodesFromMarkup(markup, handleScript) { - var node = dummyNode; - !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup dummy not initialized') : invariant(false) : void 0; - var nodeName = getNodeName(markup); +BigInteger.prototype.toByteArrayUnsigned = function() { + var byteArray = this.toByteArray() + return byteArray[0] === 0 ? byteArray.slice(1) : byteArray +} - var wrap = nodeName && getMarkupWrap(nodeName); - if (wrap) { - node.innerHTML = wrap[1] + markup + wrap[2]; +BigInteger.fromDERInteger = function(byteArray) { + return new BigInteger(byteArray) +} - var wrapDepth = wrap[0]; - while (wrapDepth--) { - node = node.lastChild; - } - } else { - node.innerHTML = markup; - } +/* + * Converts BigInteger to a DER integer representation. + * + * The format for this value uses the most significant bit as a sign + * bit. If the most significant bit is already set and the integer is + * positive, a 0x00 is prepended. + * + * Examples: + * + * 0 => 0x00 + * 1 => 0x01 + * -1 => 0xff + * 127 => 0x7f + * -127 => 0x81 + * 128 => 0x0080 + * -128 => 0x80 + * 255 => 0x00ff + * -255 => 0xff01 + * 16300 => 0x3fac + * -16300 => 0xc054 + * 62300 => 0x00f35c + * -62300 => 0xff0ca4 +*/ +BigInteger.prototype.toDERInteger = BigInteger.prototype.toByteArray - var scripts = node.getElementsByTagName('script'); - if (scripts.length) { - !handleScript ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup(...): Unexpected <script> element rendered.') : invariant(false) : void 0; - createArrayFromMixed(scripts).forEach(handleScript); - } +BigInteger.fromBuffer = function(buffer) { + // BigInteger expects a DER integer conformant byte array + if (buffer[0] & 0x80) { + var byteArray = Array.prototype.slice.call(buffer) - var nodes = Array.from(node.childNodes); - while (node.lastChild) { - node.removeChild(node.lastChild); + return new BigInteger([0].concat(byteArray)) } - return nodes; + + return new BigInteger(buffer) } -module.exports = createNodesFromMarkup; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +BigInteger.fromHex = function(hex) { + if (hex === '') return BigInteger.ZERO + + assert.equal(hex, hex.match(/^[A-Fa-f0-9]+/), 'Invalid hex string') + assert.equal(hex.length % 2, 0, 'Incomplete hex') + return new BigInteger(hex, 16) +} + +BigInteger.prototype.toBuffer = function(size) { + var byteArray = this.toByteArrayUnsigned() + var zeros = [] + + var padding = size - byteArray.length + while (zeros.length < padding) zeros.push(0) + + return new Buffer(zeros.concat(byteArray)) +} + +BigInteger.prototype.toHex = function(size) { + return this.toBuffer(size).toString('hex') +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 156 */ +/* 409 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +/* WEBPACK VAR INJECTION */(function(global, process) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +var formatRegExp = /%[sdj%]/g; +exports.format = function(f) { + if (!isString(f)) { + var objects = []; + for (var i = 0; i < arguments.length; i++) { + objects.push(inspect(arguments[i])); + } + return objects.join(' '); + } + + var i = 1; + var args = arguments; + var len = args.length; + var str = String(f).replace(formatRegExp, function(x) { + if (x === '%%') return '%'; + if (i >= len) return x; + switch (x) { + case '%s': return String(args[i++]); + case '%d': return Number(args[i++]); + case '%j': + try { + return JSON.stringify(args[i++]); + } catch (_) { + return '[Circular]'; + } + default: + return x; + } + }); + for (var x = args[i]; i < len; x = args[++i]) { + if (isNull(x) || !isObject(x)) { + str += ' ' + x; + } else { + str += ' ' + inspect(x); + } + } + return str; +}; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ -var invariant = __webpack_require__(1); +// Mark that a method should not be used. +// Returns a modified function which warns once by default. +// If --no-deprecation is set, then it is a no-op. +exports.deprecate = function(fn, msg) { + // Allow for deprecating things in the process of starting up. + if (isUndefined(global.process)) { + return function() { + return exports.deprecate(fn, msg).apply(this, arguments); + }; + } + + if (process.noDeprecation === true) { + return fn; + } + + var warned = false; + function deprecated() { + if (!warned) { + if (process.throwDeprecation) { + throw new Error(msg); + } else if (process.traceDeprecation) { + console.trace(msg); + } else { + console.error(msg); + } + warned = true; + } + return fn.apply(this, arguments); + } + + return deprecated; +}; + + +var debugs = {}; +var debugEnviron; +exports.debuglog = function(set) { + if (isUndefined(debugEnviron)) + debugEnviron = process.env.NODE_DEBUG || ''; + set = set.toUpperCase(); + if (!debugs[set]) { + if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) { + var pid = process.pid; + debugs[set] = function() { + var msg = exports.format.apply(exports, arguments); + console.error('%s %d: %s', set, pid, msg); + }; + } else { + debugs[set] = function() {}; + } + } + return debugs[set]; +}; + /** - * Convert array-like objects to arrays. - * - * This API assumes the caller knows the contents of the data type. For less - * well defined inputs use createArrayFromMixed. + * Echos the value of a value. Trys to print the value out + * in the best way possible given the different types. * - * @param {object|function|filelist} obj - * @return {array} + * @param {Object} obj The object to print out. + * @param {Object} opts Optional options object that alters the output. */ -function toArray(obj) { - var length = obj.length; +/* legacy: obj, showHidden, depth, colors*/ +function inspect(obj, opts) { + // default options + var ctx = { + seen: [], + stylize: stylizeNoColor + }; + // legacy... + if (arguments.length >= 3) ctx.depth = arguments[2]; + if (arguments.length >= 4) ctx.colors = arguments[3]; + if (isBoolean(opts)) { + // legacy... + ctx.showHidden = opts; + } else if (opts) { + // got an "options" object + exports._extend(ctx, opts); + } + // set default options + if (isUndefined(ctx.showHidden)) ctx.showHidden = false; + if (isUndefined(ctx.depth)) ctx.depth = 2; + if (isUndefined(ctx.colors)) ctx.colors = false; + if (isUndefined(ctx.customInspect)) ctx.customInspect = true; + if (ctx.colors) ctx.stylize = stylizeWithColor; + return formatValue(ctx, obj, ctx.depth); +} +exports.inspect = inspect; + + +// http://en.wikipedia.org/wiki/ANSI_escape_code#graphics +inspect.colors = { + 'bold' : [1, 22], + 'italic' : [3, 23], + 'underline' : [4, 24], + 'inverse' : [7, 27], + 'white' : [37, 39], + 'grey' : [90, 39], + 'black' : [30, 39], + 'blue' : [34, 39], + 'cyan' : [36, 39], + 'green' : [32, 39], + 'magenta' : [35, 39], + 'red' : [31, 39], + 'yellow' : [33, 39] +}; - // Some browsers builtin objects can report typeof 'function' (e.g. NodeList - // in old versions of Safari). - !(!Array.isArray(obj) && (typeof obj === 'object' || typeof obj === 'function')) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Array-like object expected') : invariant(false) : void 0; +// Don't use 'blue' not visible on cmd.exe +inspect.styles = { + 'special': 'cyan', + 'number': 'yellow', + 'boolean': 'yellow', + 'undefined': 'grey', + 'null': 'bold', + 'string': 'green', + 'date': 'magenta', + // "name": intentionally not styling + 'regexp': 'red' +}; - !(typeof length === 'number') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object needs a length property') : invariant(false) : void 0; - !(length === 0 || length - 1 in obj) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object should have keys for indices') : invariant(false) : void 0; +function stylizeWithColor(str, styleType) { + var style = inspect.styles[styleType]; - !(typeof obj.callee !== 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object can\'t be `arguments`. Use rest params ' + '(function(...args) {}) or Array.from() instead.') : invariant(false) : void 0; + if (style) { + return '\u001b[' + inspect.colors[style][0] + 'm' + str + + '\u001b[' + inspect.colors[style][1] + 'm'; + } else { + return str; + } +} - // Old IE doesn't give collections access to hasOwnProperty. Assume inputs - // without method will throw during the slice call and skip straight to the - // fallback. - if (obj.hasOwnProperty) { - try { - return Array.prototype.slice.call(obj); - } catch (e) { - // IE < 9 does not support Array#slice on collections objects + +function stylizeNoColor(str, styleType) { + return str; +} + + +function arrayToHash(array) { + var hash = {}; + + array.forEach(function(val, idx) { + hash[val] = true; + }); + + return hash; +} + + +function formatValue(ctx, value, recurseTimes) { + // Provide a hook for user-specified inspect functions. + // Check that value is an object with an inspect function on it + if (ctx.customInspect && + value && + isFunction(value.inspect) && + // Filter out the util module, it's inspect function is special + value.inspect !== exports.inspect && + // Also filter out any prototype objects using the circular check. + !(value.constructor && value.constructor.prototype === value)) { + var ret = value.inspect(recurseTimes, ctx); + if (!isString(ret)) { + ret = formatValue(ctx, ret, recurseTimes); } + return ret; } - // Fall back to copying key by key. This assumes all keys have a value, - // so will not preserve sparsely populated inputs. - var ret = Array(length); - for (var ii = 0; ii < length; ii++) { - ret[ii] = obj[ii]; + // Primitive types cannot have properties + var primitive = formatPrimitive(ctx, value); + if (primitive) { + return primitive; } - return ret; + + // Look up the keys of the object. + var keys = Object.keys(value); + var visibleKeys = arrayToHash(keys); + + if (ctx.showHidden) { + keys = Object.getOwnPropertyNames(value); + } + + // IE doesn't make error fields non-enumerable + // http://msdn.microsoft.com/en-us/library/ie/dww52sbt(v=vs.94).aspx + if (isError(value) + && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) { + return formatError(value); + } + + // Some type of object without properties can be shortcutted. + if (keys.length === 0) { + if (isFunction(value)) { + var name = value.name ? ': ' + value.name : ''; + return ctx.stylize('[Function' + name + ']', 'special'); + } + if (isRegExp(value)) { + return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp'); + } + if (isDate(value)) { + return ctx.stylize(Date.prototype.toString.call(value), 'date'); + } + if (isError(value)) { + return formatError(value); + } + } + + var base = '', array = false, braces = ['{', '}']; + + // Make Array say that they are Array + if (isArray(value)) { + array = true; + braces = ['[', ']']; + } + + // Make functions say that they are functions + if (isFunction(value)) { + var n = value.name ? ': ' + value.name : ''; + base = ' [Function' + n + ']'; + } + + // Make RegExps say that they are RegExps + if (isRegExp(value)) { + base = ' ' + RegExp.prototype.toString.call(value); + } + + // Make dates with properties first say the date + if (isDate(value)) { + base = ' ' + Date.prototype.toUTCString.call(value); + } + + // Make error with message first say the error + if (isError(value)) { + base = ' ' + formatError(value); + } + + if (keys.length === 0 && (!array || value.length == 0)) { + return braces[0] + base + braces[1]; + } + + if (recurseTimes < 0) { + if (isRegExp(value)) { + return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp'); + } else { + return ctx.stylize('[Object]', 'special'); + } + } + + ctx.seen.push(value); + + var output; + if (array) { + output = formatArray(ctx, value, recurseTimes, visibleKeys, keys); + } else { + output = keys.map(function(key) { + return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array); + }); + } + + ctx.seen.pop(); + + return reduceToSingleString(output, base, braces); } -/** - * Perform a heuristic test to determine if an object is "array-like". - * - * A monk asked Joshu, a Zen master, "Has a dog Buddha nature?" - * Joshu replied: "Mu." - * - * This function determines if its argument has "array nature": it returns - * true if the argument is an actual array, an `arguments' object, or an - * HTMLCollection (e.g. node.childNodes or node.getElementsByTagName()). - * - * It will return false for other array-like objects like Filelist. - * - * @param {*} obj - * @return {boolean} - */ -function hasArrayNature(obj) { - return ( - // not null/false - !!obj && ( - // arrays are objects, NodeLists are functions in Safari - typeof obj == 'object' || typeof obj == 'function') && - // quacks like an array - 'length' in obj && - // not window - !('setInterval' in obj) && - // no DOM node should be considered an array-like - // a 'select' element has 'length' and 'item' properties on IE8 - typeof obj.nodeType != 'number' && ( - // a real array - Array.isArray(obj) || - // arguments - 'callee' in obj || - // HTMLCollection/NodeList - 'item' in obj) - ); + +function formatPrimitive(ctx, value) { + if (isUndefined(value)) + return ctx.stylize('undefined', 'undefined'); + if (isString(value)) { + var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '') + .replace(/'/g, "\\'") + .replace(/\\"/g, '"') + '\''; + return ctx.stylize(simple, 'string'); + } + if (isNumber(value)) + return ctx.stylize('' + value, 'number'); + if (isBoolean(value)) + return ctx.stylize('' + value, 'boolean'); + // For some reason typeof null is "object", so special case here. + if (isNull(value)) + return ctx.stylize('null', 'null'); } -/** - * Ensure that the argument is an array by wrapping it in an array if it is not. - * Creates a copy of the argument if it is already an array. - * - * This is mostly useful idiomatically: - * - * var createArrayFromMixed = require('createArrayFromMixed'); - * - * function takesOneOrMoreThings(things) { - * things = createArrayFromMixed(things); - * ... - * } - * - * This allows you to treat `things' as an array, but accept scalars in the API. - * - * If you need to convert an array-like object, like `arguments`, into an array - * use toArray instead. - * - * @param {*} obj - * @return {array} - */ -function createArrayFromMixed(obj) { - if (!hasArrayNature(obj)) { - return [obj]; - } else if (Array.isArray(obj)) { - return obj.slice(); + +function formatError(value) { + return '[' + Error.prototype.toString.call(value) + ']'; +} + + +function formatArray(ctx, value, recurseTimes, visibleKeys, keys) { + var output = []; + for (var i = 0, l = value.length; i < l; ++i) { + if (hasOwnProperty(value, String(i))) { + output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, + String(i), true)); + } else { + output.push(''); + } + } + keys.forEach(function(key) { + if (!key.match(/^\d+$/)) { + output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, + key, true)); + } + }); + return output; +} + + +function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) { + var name, str, desc; + desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] }; + if (desc.get) { + if (desc.set) { + str = ctx.stylize('[Getter/Setter]', 'special'); + } else { + str = ctx.stylize('[Getter]', 'special'); + } } else { - return toArray(obj); + if (desc.set) { + str = ctx.stylize('[Setter]', 'special'); + } + } + if (!hasOwnProperty(visibleKeys, key)) { + name = '[' + key + ']'; + } + if (!str) { + if (ctx.seen.indexOf(desc.value) < 0) { + if (isNull(recurseTimes)) { + str = formatValue(ctx, desc.value, null); + } else { + str = formatValue(ctx, desc.value, recurseTimes - 1); + } + if (str.indexOf('\n') > -1) { + if (array) { + str = str.split('\n').map(function(line) { + return ' ' + line; + }).join('\n').substr(2); + } else { + str = '\n' + str.split('\n').map(function(line) { + return ' ' + line; + }).join('\n'); + } + } + } else { + str = ctx.stylize('[Circular]', 'special'); + } + } + if (isUndefined(name)) { + if (array && key.match(/^\d+$/)) { + return str; + } + name = JSON.stringify('' + key); + if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) { + name = name.substr(1, name.length - 2); + name = ctx.stylize(name, 'name'); + } else { + name = name.replace(/'/g, "\\'") + .replace(/\\"/g, '"') + .replace(/(^"|"$)/g, "'"); + name = ctx.stylize(name, 'string'); + } + } + + return name + ': ' + str; +} + + +function reduceToSingleString(output, base, braces) { + var numLinesEst = 0; + var length = output.reduce(function(prev, cur) { + numLinesEst++; + if (cur.indexOf('\n') >= 0) numLinesEst++; + return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1; + }, 0); + + if (length > 60) { + return braces[0] + + (base === '' ? '' : base + '\n ') + + ' ' + + output.join(',\n ') + + ' ' + + braces[1]; + } + + return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1]; +} + + +// NOTE: These type checking functions intentionally don't use `instanceof` +// because it is fragile and can be easily faked with `Object.create()`. +function isArray(ar) { + return Array.isArray(ar); +} +exports.isArray = isArray; + +function isBoolean(arg) { + return typeof arg === 'boolean'; +} +exports.isBoolean = isBoolean; + +function isNull(arg) { + return arg === null; +} +exports.isNull = isNull; + +function isNullOrUndefined(arg) { + return arg == null; +} +exports.isNullOrUndefined = isNullOrUndefined; + +function isNumber(arg) { + return typeof arg === 'number'; +} +exports.isNumber = isNumber; + +function isString(arg) { + return typeof arg === 'string'; +} +exports.isString = isString; + +function isSymbol(arg) { + return typeof arg === 'symbol'; +} +exports.isSymbol = isSymbol; + +function isUndefined(arg) { + return arg === void 0; +} +exports.isUndefined = isUndefined; + +function isRegExp(re) { + return isObject(re) && objectToString(re) === '[object RegExp]'; +} +exports.isRegExp = isRegExp; + +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} +exports.isObject = isObject; + +function isDate(d) { + return isObject(d) && objectToString(d) === '[object Date]'; +} +exports.isDate = isDate; + +function isError(e) { + return isObject(e) && + (objectToString(e) === '[object Error]' || e instanceof Error); +} +exports.isError = isError; + +function isFunction(arg) { + return typeof arg === 'function'; +} +exports.isFunction = isFunction; + +function isPrimitive(arg) { + return arg === null || + typeof arg === 'boolean' || + typeof arg === 'number' || + typeof arg === 'string' || + typeof arg === 'symbol' || // ES6 symbol + typeof arg === 'undefined'; +} +exports.isPrimitive = isPrimitive; + +exports.isBuffer = __webpack_require__(410); + +function objectToString(o) { + return Object.prototype.toString.call(o); +} + + +function pad(n) { + return n < 10 ? '0' + n.toString(10) : n.toString(10); +} + + +var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', + 'Oct', 'Nov', 'Dec']; + +// 26 Feb 16:19:34 +function timestamp() { + var d = new Date(); + var time = [pad(d.getHours()), + pad(d.getMinutes()), + pad(d.getSeconds())].join(':'); + return [d.getDate(), months[d.getMonth()], time].join(' '); +} + + +// log is just a thin wrapper to console.log that prepends a timestamp +exports.log = function() { + console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments)); +}; + + +/** + * Inherit the prototype methods from one constructor into another. + * + * The Function.prototype.inherits from lang.js rewritten as a standalone + * function (not on Function.prototype). NOTE: If this file is to be loaded + * during bootstrapping this function needs to be rewritten using some native + * functions as prototype setup using normal JavaScript does not work as + * expected during bootstrapping (see mirror.js in r114903). + * + * @param {function} ctor Constructor function which needs to inherit the + * prototype. + * @param {function} superCtor Constructor function to inherit prototype from. + */ +exports.inherits = __webpack_require__(411); + +exports._extend = function(origin, add) { + // Don't do anything if add isn't an object + if (!add || !isObject(add)) return origin; + + var keys = Object.keys(add); + var i = keys.length; + while (i--) { + origin[keys[i]] = add[keys[i]]; } + return origin; +}; + +function hasOwnProperty(obj, prop) { + return Object.prototype.hasOwnProperty.call(obj, prop); } -module.exports = createArrayFromMixed; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) /***/ }), -/* 157 */ +/* 410 */ +/***/ (function(module, exports) { + +module.exports = function isBuffer(arg) { + return arg && typeof arg === 'object' + && typeof arg.copy === 'function' + && typeof arg.fill === 'function' + && typeof arg.readUInt8 === 'function'; +} + +/***/ }), +/* 411 */ +/***/ (function(module, exports) { + +if (typeof Object.create === 'function') { + // implementation from standard node.js 'util' module + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + ctor.prototype = Object.create(superCtor.prototype, { + constructor: { + value: ctor, + enumerable: false, + writable: true, + configurable: true + } + }); + }; +} else { + // old school shim for old browsers + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + var TempCtor = function () {} + TempCtor.prototype = superCtor.prototype + ctor.prototype = new TempCtor() + ctor.prototype.constructor = ctor + } +} + + +/***/ }), +/* 412 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +/* WEBPACK VAR INJECTION */(function(Buffer) {var prf = __webpack_require__(413); +var address = __webpack_require__(96); +var bs58check = __webpack_require__(33); +var sodium = __webpack_require__(415); +var zconfig = __webpack_require__(66); -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * +/* + * Creates a Z secret key (a_sk) + * @param {String} phrase (Password phrase) + * @return {Sting} Z secret key (a_sk) */ +function mkZSecretKey(phrase) { + const a_sk = address.mkPrivKey(phrase); + var baddr = Buffer.from(a_sk, 'hex'); + baddr[0] &= 0x0f; + return baddr.toString('hex'); +} -/*eslint-disable fb-www/unsafe-html */ +/* + * Converts the secret key to a spending key + * @param {String} a_sk (secret key) + * @param {String} zcSpendingKeyHash (secret key hash,optional) + * @return {Sting} sk (spending key) + */ +function zSecretKeyToSpendingKey(a_sk, zcSpendingKeyHash) { + zcSpendingKeyHash = zcSpendingKeyHash || zconfig.mainnet.zcSpendingKeyHash; -var ExecutionEnvironment = __webpack_require__(8); + const buf = Buffer.from(zcSpendingKeyHash + a_sk, 'hex'); + return bs58check.encode(buf).toString('hex'); +} -var invariant = __webpack_require__(1); +/* + * Converts a Z secret key to a paying key + * @param {String} a_sk (secret key) + * @return {Sting} a_pk key (paying key) + */ +function zSecretKeyToPayingKey(a_sk) { + return prf.PRF_addr_a_pk(Buffer.from(a_sk, 'hex')).toString('hex'); +} -/** - * Dummy container used to detect which wraps are necessary. +/* + * Converts a Z secret key to a transmission key + * @param {String} a_sk (secret key) + * @return {Sting} pk_enc key (transmisison key) */ -var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; +function zSecretKeyToTransmissionKey(a_sk) { + var sk_enc = prf.PRF_addr_sk_enc(Buffer.from(a_sk, 'hex')); -/** - * Some browsers cannot use `innerHTML` to render certain elements standalone, - * so we wrap them, render the wrapped nodes, then extract the desired node. - * - * In IE8, certain elements cannot render alone, so wrap all elements ('*'). + // Curve 25519 clamping + sk_enc[0] &= 248; + sk_enc[32] &= 127; + sk_enc[31] |= 64; + + return Buffer.from(sodium.crypto_scalarmult_base(sk_enc)).toString('hex'); +} + +/* + * Makes a Z address given: + * @param {String} a_pk (paying key) + * @param {String} pk_enc key (transmission key) + * @param {String} zcPaymentAddressHash (hash for payment address, optional) + * @return {String} Zaddress */ +function mkZAddress(a_pk, pk_enc, zcPaymentAddressHash) { + zcPaymentAddressHash = zcPaymentAddressHash || zconfig.mainnet.zcPaymentAddressHash; -var shouldWrap = {}; + const buf = Buffer.from(zcPaymentAddressHash + a_pk + pk_enc, 'hex'); + return bs58check.encode(buf).toString('hex'); +} -var selectWrap = [1, '<select multiple="true">', '</select>']; -var tableWrap = [1, '<table>', '</table>']; -var trWrap = [3, '<table><tbody><tr>', '</tr></tbody></table>']; +module.exports = { + mkZSecretKey: mkZSecretKey, + zSecretKeyToTransmissionKey: zSecretKeyToTransmissionKey, + zSecretKeyToPayingKey: zSecretKeyToPayingKey, + zSecretKeyToSpendingKey: zSecretKeyToSpendingKey, + mkZAddress: mkZAddress +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var svgWrap = [1, '<svg xmlns="http://www.w3.org/2000/svg">', '</svg>']; +/***/ }), +/* 413 */ +/***/ (function(module, exports, __webpack_require__) { -var markupWrap = { - '*': [1, '?<div>', '</div>'], +/* WEBPACK VAR INJECTION */(function(Buffer) {var SHA256Compress = __webpack_require__(414); - 'area': [1, '<map>', '</map>'], - 'col': [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>'], - 'legend': [1, '<fieldset>', '</fieldset>'], - 'param': [1, '<object>', '</object>'], - 'tr': [2, '<table><tbody>', '</tbody></table>'], +function prf(a, b, c, d, x, y) { - 'optgroup': selectWrap, - 'option': selectWrap, + var blob = Buffer.alloc(64); - 'caption': tableWrap, - 'colgroup': tableWrap, - 'tbody': tableWrap, - 'tfoot': tableWrap, - 'thead': tableWrap, + x.copy(blob, 0); + y.copy(blob, 32); - 'td': trWrap, - 'th': trWrap -}; + blob[0] &= 0x0F; + blob[0] |= (a ? 1 << 7 : 0) | (b ? 1 << 6 : 0) | (c ? 1 << 5 : 0) | (d ? 1 << 4 : 0); -// Initialize the SVG elements since we know they'll always need to be wrapped -// consistently. If they are created inside a <div> they will be initialized in -// the wrong namespace (and will not display). -var svgElements = ['circle', 'clipPath', 'defs', 'ellipse', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'text', 'tspan']; -svgElements.forEach(function (nodeName) { - markupWrap[nodeName] = svgWrap; - shouldWrap[nodeName] = true; -}); + var hasher = new SHA256Compress(); + hasher.update(blob); + return hasher.hash(); +} -/** - * Gets the markup wrap configuration for the supplied `nodeName`. - * - * NOTE: This lazily detects which wraps are necessary for the current browser. - * - * @param {string} nodeName Lowercase `nodeName`. - * @return {?array} Markup wrap configuration, if applicable. - */ -function getMarkupWrap(nodeName) { - !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Markup wrapping node not initialized') : invariant(false) : void 0; - if (!markupWrap.hasOwnProperty(nodeName)) { - nodeName = '*'; +function prfAddr(aSk, t) { + var y = Buffer.alloc(32); + y.fill(0); + y[0] = t; + + return prf(1, 1, 0, 0, aSk, y); +} + +function prfAddrAPk(aSk) { + return prfAddr(aSk, 0); +} + +function prfAddrSkEnc(aSk) { + return prfAddr(aSk, 1); +} + +function prfNf(aSk, rho) { + return prf(1, 1, 1, 0, aSk, rho); +} + +function prfPk(aSk, i0, hSig) { + if (i0 !== 0 && i0 !== 1) { + throw new Error('PRF_pk invoked with index out of bounds'); } - if (!shouldWrap.hasOwnProperty(nodeName)) { - if (nodeName === '*') { - dummyNode.innerHTML = '<link />'; - } else { - dummyNode.innerHTML = '<' + nodeName + '></' + nodeName + '>'; - } - shouldWrap[nodeName] = !dummyNode.firstChild; + + return prf(0, i0, 0, 0, aSk, hSig); +} + +function prfRho(phi, i0, hSig) { + if (i0 !== 0 && i0 !== 1) { + throw new Error('PRF_rho invoked with index out of bounds'); } - return shouldWrap[nodeName] ? markupWrap[nodeName] : null; + + return prf(0, i0, 1, 0, phi, hSig); } -module.exports = getMarkupWrap; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = { + PRF_addr_a_pk: prfAddrAPk, + PRF_addr_sk_enc: prfAddrSkEnc, + PRF_nf: prfNf, + PRF_pk: prfPk, + PRF_rho: prfRho +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 158 */ +/* 414 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +/* WEBPACK VAR INJECTION */(function(Buffer) {/** + * Adapted from https://github.com/crypto-browserify/sha.js/blob/master/sha256.js + * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined + * in FIPS 180-2 + * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet * */ +var K = [0x428A2F98, 0x71374491, 0xB5C0FBCF, 0xE9B5DBA5, 0x3956C25B, 0x59F111F1, 0x923F82A4, 0xAB1C5ED5, 0xD807AA98, 0x12835B01, 0x243185BE, 0x550C7DC3, 0x72BE5D74, 0x80DEB1FE, 0x9BDC06A7, 0xC19BF174, 0xE49B69C1, 0xEFBE4786, 0x0FC19DC6, 0x240CA1CC, 0x2DE92C6F, 0x4A7484AA, 0x5CB0A9DC, 0x76F988DA, 0x983E5152, 0xA831C66D, 0xB00327C8, 0xBF597FC7, 0xC6E00BF3, 0xD5A79147, 0x06CA6351, 0x14292967, 0x27B70A85, 0x2E1B2138, 0x4D2C6DFC, 0x53380D13, 0x650A7354, 0x766A0ABB, 0x81C2C92E, 0x92722C85, 0xA2BFE8A1, 0xA81A664B, 0xC24B8B70, 0xC76C51A3, 0xD192E819, 0xD6990624, 0xF40E3585, 0x106AA070, 0x19A4C116, 0x1E376C08, 0x2748774C, 0x34B0BCB5, 0x391C0CB3, 0x4ED8AA4A, 0x5B9CCA4F, 0x682E6FF3, 0x748F82EE, 0x78A5636F, 0x84C87814, 0x8CC70208, 0x90BEFFFA, 0xA4506CEB, 0xBEF9A3F7, 0xC67178F2]; +var W = new Array(64); -var DOMChildrenOperations = __webpack_require__(55); -var ReactDOMComponentTree = __webpack_require__(6); +function Sha256Compress() { + this.init(); -/** - * Operations used to process updates to DOM nodes. - */ -var ReactDOMIDOperations = { - /** - * Updates a component's children by processing a series of updates. - * - * @param {array<object>} updates List of update configurations. - * @internal - */ - dangerouslyProcessChildrenUpdates: function (parentInst, updates) { - var node = ReactDOMComponentTree.getNodeFromInstance(parentInst); - DOMChildrenOperations.processUpdates(node, updates); - } + this._w = W; // new Array(64) +} + +Sha256Compress.prototype.init = function () { + this._a = 0x6a09e667; + this._b = 0xbb67ae85; + this._c = 0x3c6ef372; + this._d = 0xa54ff53a; + this._e = 0x510e527f; + this._f = 0x9b05688c; + this._g = 0x1f83d9ab; + this._h = 0x5be0cd19; + + return this; }; -module.exports = ReactDOMIDOperations; +function ch(x, y, z) { + return z ^ x & (y ^ z); +} + +function maj(x, y, z) { + return x & y | z & (x | y); +} + +function sigma0(x) { + return (x >>> 2 | x << 30) ^ (x >>> 13 | x << 19) ^ (x >>> 22 | x << 10); +} + +function sigma1(x) { + return (x >>> 6 | x << 26) ^ (x >>> 11 | x << 21) ^ (x >>> 25 | x << 7); +} + +function gamma0(x) { + return (x >>> 7 | x << 25) ^ (x >>> 18 | x << 14) ^ x >>> 3; +} + +function gamma1(x) { + return (x >>> 17 | x << 15) ^ (x >>> 19 | x << 13) ^ x >>> 10; +} + +Sha256Compress.prototype.update = function (M) { + var W = this._w; + + var a = this._a | 0; + var b = this._b | 0; + var c = this._c | 0; + var d = this._d | 0; + var e = this._e | 0; + var f = this._f | 0; + var g = this._g | 0; + var h = this._h | 0; + + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4); + for (; i < 64; ++i) W[i] = gamma1(W[i - 2]) + W[i - 7] + gamma0(W[i - 15]) + W[i - 16] | 0; + + for (var j = 0; j < 64; ++j) { + var T1 = h + sigma1(e) + ch(e, f, g) + K[j] + W[j] | 0; + var T2 = sigma0(a) + maj(a, b, c) | 0; + + h = g; + g = f; + f = e; + e = d + T1 | 0; + d = c; + c = b; + b = a; + a = T1 + T2 | 0; + } + + this._a = a + this._a | 0; + this._b = b + this._b | 0; + this._c = c + this._c | 0; + this._d = d + this._d | 0; + this._e = e + this._e | 0; + this._f = f + this._f | 0; + this._g = g + this._g | 0; + this._h = h + this._h | 0; +}; + +Sha256Compress.prototype.hash = function () { + var H = Buffer.alloc(32); + + H.writeInt32BE(this._a, 0); + H.writeInt32BE(this._b, 4); + H.writeInt32BE(this._c, 8); + H.writeInt32BE(this._d, 12); + H.writeInt32BE(this._e, 16); + H.writeInt32BE(this._f, 20); + H.writeInt32BE(this._g, 24); + H.writeInt32BE(this._h, 28); + + return H; +}; + +module.exports = Sha256Compress; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 159 */ +/* 415 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(process) {var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (root, factory) { + if (typeof process === "object" && typeof process.stdout === "undefined") { + process.stderr = process.stdout = { write: function() { } }; + } + if (true) { + !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports, __webpack_require__(416)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), + __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? + (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); + } else if (typeof exports !== "undefined") { + factory(exports, require("libsodium-sumo")); + } else { + var cb = root.sodium && root.sodium.onload; + factory((root.sodium = {}), root.libsodium); + if (typeof cb === "function") { + cb(root.sodium); + } + } +}(this, (function (exports, libsodium) { + "use strict"; -/* global hasOwnProperty:true */ + var output_format = "uint8array"; + if (libsodium._sodium_init() !== 0) { + throw new Error("libsodium was not correctly initialized."); + } + // List of functions and constants defined in the wrapped libsodium + function symbols() { + return Object.keys(exports).sort(); + } -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); - -var AutoFocusUtils = __webpack_require__(160); -var CSSPropertyOperations = __webpack_require__(161); -var DOMLazyTree = __webpack_require__(27); -var DOMNamespaces = __webpack_require__(56); -var DOMProperty = __webpack_require__(17); -var DOMPropertyOperations = __webpack_require__(93); -var EventPluginHub = __webpack_require__(32); -var EventPluginRegistry = __webpack_require__(40); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactDOMComponentFlags = __webpack_require__(81); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMInput = __webpack_require__(171); -var ReactDOMOption = __webpack_require__(172); -var ReactDOMSelect = __webpack_require__(95); -var ReactDOMTextarea = __webpack_require__(173); -var ReactInstrumentation = __webpack_require__(13); -var ReactMultiChild = __webpack_require__(174); -var ReactServerRenderingTransaction = __webpack_require__(183); - -var emptyFunction = __webpack_require__(12); -var escapeTextContentForBrowser = __webpack_require__(44); -var invariant = __webpack_require__(1); -var isEventSupported = __webpack_require__(53); -var shallowEqual = __webpack_require__(60); -var inputValueTracking = __webpack_require__(87); -var validateDOMNesting = __webpack_require__(64); -var warning = __webpack_require__(2); + function increment(bytes) { + if (! bytes instanceof Uint8Array) { + throw new TypeError("Only Uint8Array instances can be incremented"); + } + var c = 1 << 8; + for (var i = 0 | 0, j = bytes.length; i < j; i++) { + c >>= 8; + c += bytes[i]; + bytes[i] = c & 0xff; + } + } -var Flags = ReactDOMComponentFlags; -var deleteListener = EventPluginHub.deleteListener; -var getNode = ReactDOMComponentTree.getNodeFromInstance; -var listenTo = ReactBrowserEventEmitter.listenTo; -var registrationNameModules = EventPluginRegistry.registrationNameModules; + function add(a, b) { + if (! a instanceof Uint8Array || ! b instanceof Uint8Array) { + throw new TypeError("Only Uint8Array instances can added"); + } + var j = a.length, c = 0 | 0, i = 0 | 0; + if (b.length != a.length) { + throw new TypeError("Arguments must have the same length"); + } + for (i = 0; i < j; i++) { + c >>= 8; + c += (a[i] + b[j]); + a[i] = c & 0xff; + } + } -// For quickly matching children type, to test if can be treated as content. -var CONTENT_TYPES = { string: true, number: true }; + function is_zero(bytes) { + if (! bytes instanceof Uint8Array) { + throw new TypeError("Only Uint8Array instances can be checked"); + } + var d = 0 | 0; + for (var i = 0 | 0, j = bytes.length; i < j; i++) { + d |= bytes[i]; + } + return d === 0; + } -var STYLE = 'style'; -var HTML = '__html'; -var RESERVED_PROPS = { - children: null, - dangerouslySetInnerHTML: null, - suppressContentEditableWarning: null -}; + function memzero(bytes) { + if (! bytes instanceof Uint8Array) { + throw new TypeError("Only Uint8Array instances can be wiped"); + } + for (var i = 0 | 0, j = bytes.length; i < j; i++) { + bytes[i] = 0; + } + } -// Node type for document fragments (Node.DOCUMENT_FRAGMENT_NODE). -var DOC_FRAGMENT_TYPE = 11; + function memcmp(b1, b2) { + if (!(b1 instanceof Uint8Array && b2 instanceof Uint8Array)) { + throw new TypeError("Only Uint8Array instances can be compared"); + } + if (b1.length !== b2.length) { + throw new TypeError("Only instances of identical length can be compared"); + } + for (var d = 0 | 0, i = 0 | 0, j = b1.length; i < j; i++) { + d |= b1[i] ^ b2[i]; + } + return d === 0; + } -function getDeclarationErrorAddendum(internalInstance) { - if (internalInstance) { - var owner = internalInstance._currentElement._owner || null; - if (owner) { - var name = owner.getName(); - if (name) { - return ' This DOM node was rendered by `' + name + '`.'; - } + function compare(b1, b2) { + if (!(b1 instanceof Uint8Array && b2 instanceof Uint8Array)) { + throw new TypeError("Only Uint8Array instances can be compared"); + } + if (b1.length !== b2.length) { + throw new TypeError("Only instances of identical length can be compared"); + } + for (var gt = 0 | 0, eq = 1 | 1, i = b1.length; i-- > 0;) { + gt |= ((b2[i] - b1[i]) >> 8) & eq; + eq &= ((b2[i] ^ b1[i]) - 1) >> 8; + } + return (gt + gt + eq) - 1; } - } - return ''; -} -function friendlyStringify(obj) { - if (typeof obj === 'object') { - if (Array.isArray(obj)) { - return '[' + obj.map(friendlyStringify).join(', ') + ']'; - } else { - var pairs = []; - for (var key in obj) { - if (Object.prototype.hasOwnProperty.call(obj, key)) { - var keyEscaped = /^[a-z$_][\w$_]*$/i.test(key) ? key : JSON.stringify(key); - pairs.push(keyEscaped + ': ' + friendlyStringify(obj[key])); + //--------------------------------------------------------------------------- + // Codecs + // + function from_string(str) { + if (typeof TextEncoder === "function") { + return new TextEncoder("utf-8").encode(str); } - } - return '{' + pairs.join(', ') + '}'; + str = unescape(encodeURIComponent(str)); + var bytes = new Uint8Array(str.length); + for (var i = 0; i < str.length; i++) { + bytes[i] = str.charCodeAt(i); + } + return bytes; } - } else if (typeof obj === 'string') { - return JSON.stringify(obj); - } else if (typeof obj === 'function') { - return '[function object]'; - } - // Differs from JSON.stringify in that undefined because undefined and that - // inf and nan don't become null - return String(obj); -} -var styleMutationWarning = {}; + function to_string(bytes) { + if (typeof TextDecoder === "function") { + return new TextDecoder("utf-8", {fatal: true}).decode(bytes); + } -function checkAndWarnForMutatedStyle(style1, style2, component) { - if (style1 == null || style2 == null) { - return; - } - if (shallowEqual(style1, style2)) { - return; - } + var toStringChunkSize = 8192, + numChunks = Math.ceil(bytes.length / toStringChunkSize); + if (numChunks <= 1) { + try { + return decodeURIComponent(escape(String.fromCharCode.apply(null, bytes))); + } + catch (_) { + throw new TypeError("The encoded data was not valid."); + } + } + var totalString = ''; + var sequenceReadOffset = 0; + for (var i = 0; i < numChunks; i++) { + var currentChunk = + Array.prototype.slice.call(bytes, + i * toStringChunkSize + sequenceReadOffset, + (i + 1) * toStringChunkSize + sequenceReadOffset); + //Depending on how much we have shifted + if (currentChunk.length == 0) { + continue; + } - var componentName = component._tag; - var owner = component._currentElement._owner; - var ownerName; - if (owner) { - ownerName = owner.getName(); - } + //Checking that we didn't cut the buffer in the middle of a UTF8 sequence. + //If we did, remove the bytes of the "cut" sequence and + //decrement sequenceReadOffset for each removed byte + var sequenceDetectionComplete, + sequenceIndex = currentChunk.length, + sequenceLength = 0; + + //This loop will read the chunk from its end, looking for sequence start bytes + do { + sequenceIndex--; + var currentByte = currentChunk[sequenceIndex]; + + if (currentByte >= 240) { //Beginning of a 4-byte UTF-8 sequence + sequenceLength = 4; + sequenceDetectionComplete = true; + } else if (currentByte >= 224) { //Beginning of a 3-byte UTF-8 sequence + sequenceLength = 3; + sequenceDetectionComplete = true; + } else if (currentByte >= 192) { //Beginning of a 2-byte UTF-8 sequence + sequenceLength = 2; + sequenceDetectionComplete = true; + } else if (currentByte < 128) { //A one byte UTF-8 char + sequenceLength = 1; + sequenceDetectionComplete = true; + } + //The values between [128, 192[ are part of a UTF-8 sequence. + //The loop will not exit in that case, and will iterate one byte backwards instead + } while (!sequenceDetectionComplete); + + var extraBytes = sequenceLength - (currentChunk.length - sequenceIndex); + for (var j = 0; j < extraBytes; j++) { + sequenceReadOffset--; + currentChunk.pop(); + } - var hash = ownerName + '|' + componentName; + totalString += to_string(currentChunk); + } + return totalString; + } - if (styleMutationWarning.hasOwnProperty(hash)) { - return; - } + /* not constant-time */ + function from_hex(str) { + if (!is_hex(str)) { + throw new TypeError("The provided string doesn't look like hex data"); + } + var result = new Uint8Array(str.length / 2); + for (var i = 0; i < str.length; i += 2) { + result[i >>> 1] = parseInt(str.substr(i, 2), 16); + } + return result; + } - styleMutationWarning[hash] = true; + function to_hex(bytes) { + var str = "", b, c, x; + for (var i = 0; i < bytes.length; i++) { + c = bytes[i] & 0xf; + b = bytes[i] >>> 4; + x = (87 + c + (((c - 10) >> 8) & ~38)) << 8 | + (87 + b + (((b - 10) >> 8) & ~38)); + str += String.fromCharCode(x & 0xff) + String.fromCharCode(x >>> 8); + } + return str; + } - process.env.NODE_ENV !== 'production' ? warning(false, '`%s` was passed a style object that has previously been mutated. ' + 'Mutating `style` is deprecated. Consider cloning it beforehand. Check ' + 'the `render` %s. Previous style: %s. Mutated style: %s.', componentName, owner ? 'of `' + ownerName + '`' : 'using <' + componentName + '>', friendlyStringify(style1), friendlyStringify(style2)) : void 0; -} + function is_hex(str) { + return (typeof str === "string" && /^[0-9a-f]+$/i.test(str) && str.length % 2 === 0); + } -/** - * @param {object} component - * @param {?object} props - */ -function assertValidProps(component, props) { - if (!props) { - return; - } - // Note the use of `==` which checks for null or undefined. - if (voidElementTags[component._tag]) { - !(props.children == null && props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.%s', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : _prodInvariant('137', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : void 0; - } - if (props.dangerouslySetInnerHTML != null) { - !(props.children == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Can only set one of `children` or `props.dangerouslySetInnerHTML`.') : _prodInvariant('60') : void 0; - !(typeof props.dangerouslySetInnerHTML === 'object' && HTML in props.dangerouslySetInnerHTML) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.') : _prodInvariant('61') : void 0; - } - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(props.innerHTML == null, 'Directly setting property `innerHTML` is not permitted. ' + 'For more information, lookup documentation on `dangerouslySetInnerHTML`.') : void 0; - process.env.NODE_ENV !== 'production' ? warning(props.suppressContentEditableWarning || !props.contentEditable || props.children == null, 'A component is `contentEditable` and contains `children` managed by ' + 'React. It is now your responsibility to guarantee that none of ' + 'those nodes are unexpectedly modified or duplicated. This is ' + 'probably not intentional.') : void 0; - process.env.NODE_ENV !== 'production' ? warning(props.onFocusIn == null && props.onFocusOut == null, 'React uses onFocus and onBlur instead of onFocusIn and onFocusOut. ' + 'All React events are normalized to bubble, so onFocusIn and onFocusOut ' + 'are not needed/supported by React.') : void 0; - } - !(props.style == null || typeof props.style === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + \'em\'}} when using JSX.%s', getDeclarationErrorAddendum(component)) : _prodInvariant('62', getDeclarationErrorAddendum(component)) : void 0; -} + function from_base64(sBase64, nBlocksSize) { + function _b64ToUint6(nChr) { + return nChr > 64 && nChr < 91 ? + nChr - 65 : nChr > 96 && nChr < 123 ? + nChr - 71 : nChr > 47 && nChr < 58 ? + nChr + 4 : nChr === 43 ? + 62 : nChr === 47 ? + 63 : + 0; + } -function enqueuePutListener(inst, registrationName, listener, transaction) { - if (transaction instanceof ReactServerRenderingTransaction) { - return; - } - if (process.env.NODE_ENV !== 'production') { - // IE8 has no API for event capturing and the `onScroll` event doesn't - // bubble. - process.env.NODE_ENV !== 'production' ? warning(registrationName !== 'onScroll' || isEventSupported('scroll', true), "This browser doesn't support the `onScroll` event") : void 0; - } - var containerInfo = inst._hostContainerInfo; - var isDocumentFragment = containerInfo._node && containerInfo._node.nodeType === DOC_FRAGMENT_TYPE; - var doc = isDocumentFragment ? containerInfo._node : containerInfo._ownerDocument; - listenTo(registrationName, doc); - transaction.getReactMountReady().enqueue(putListener, { - inst: inst, - registrationName: registrationName, - listener: listener - }); -} + var sB64Enc = sBase64.replace(/[^A-Za-z0-9\+\/]/g, ""), + nInLen = sB64Enc.length, + nOutLen = nBlocksSize ? Math.ceil((nInLen * 3 + 1 >> 2) / nBlocksSize) * nBlocksSize : nInLen * 3 + 1 >> 2, + taBytes = new Uint8Array(nOutLen); + + for (var nMod3, nMod4, nUint24 = 0, nOutIdx = 0, nInIdx = 0; nInIdx < nInLen; nInIdx++) { + nMod4 = nInIdx & 3; + nUint24 |= _b64ToUint6(sB64Enc.charCodeAt(nInIdx)) << 18 - 6 * nMod4; + if (nMod4 === 3 || nInLen - nInIdx === 1) { + for (nMod3 = 0; nMod3 < 3 && nOutIdx < nOutLen; nMod3++, nOutIdx++) { + taBytes[nOutIdx] = nUint24 >>> (16 >>> nMod3 & 24) & 255; + } + nUint24 = 0; + } + } + return taBytes; + } + + function to_base64(aBytes, noNewLine) { + if (typeof noNewLine === "undefined") { + noNewLine = true; + } + function _uint6ToB64(nUint6) { + return nUint6 < 26 ? + nUint6 + 65 : nUint6 < 52 ? + nUint6 + 71 : nUint6 < 62 ? + nUint6 - 4 : nUint6 === 62 ? + 43 : nUint6 === 63 ? + 47 : + 65; + } + if (typeof aBytes === "string") { + throw new Error("input has to be an array"); + } + var nMod3 = 2, + sB64Enc = ""; + for (var nLen = aBytes.length, nUint24 = 0, nIdx = 0; nIdx < nLen; nIdx++) { + nMod3 = nIdx % 3; + if (nIdx > 0 && (nIdx * 4 / 3) % 76 === 0 && !noNewLine) { + sB64Enc += "\r\n"; + } + nUint24 |= aBytes[nIdx] << (16 >>> nMod3 & 24); + if (nMod3 === 2 || aBytes.length - nIdx === 1) { + sB64Enc += String.fromCharCode(_uint6ToB64(nUint24 >>> 18 & 63), + _uint6ToB64(nUint24 >>> 12 & 63), + _uint6ToB64(nUint24 >>> 6 & 63), + _uint6ToB64(nUint24 & 63)); + nUint24 = 0; + } + } + return sB64Enc.substr(0, sB64Enc.length - 2 + nMod3) + + (nMod3 === 2 ? "" : nMod3 === 1 ? "=" : "=="); + } + + function output_formats() { + return ["uint8array", "text", "hex", "base64"]; + } + + function _format_output(output, optionalOutputFormat) { + var selectedOutputFormat = optionalOutputFormat || output_format; + if (!_is_output_format(selectedOutputFormat)) { + throw new Error(selectedOutputFormat + " output format is not available"); + } + if (output instanceof AllocatedBuf) { + if (selectedOutputFormat === "uint8array") { + return output.to_Uint8Array(); + } else if (selectedOutputFormat === "text") { + return to_string(output.to_Uint8Array()); + } else if (selectedOutputFormat === "hex") { + return to_hex(output.to_Uint8Array()); + } else if (selectedOutputFormat === "base64") { + return to_base64(output.to_Uint8Array()); + } else { + throw new Error("What is output format \"" + selectedOutputFormat + "\"?"); + } + } else if (typeof output === "object") { //Composed output. Example : key pairs + var props = Object.keys(output); + var formattedOutput = {}; + for (var i = 0; i < props.length; i++) { + formattedOutput[props[i]] = _format_output(output[props[i]], selectedOutputFormat); + } + return formattedOutput; + } else if (typeof output === "string") { + return output; + } else { + throw new TypeError("Cannot format output"); + } + } + + function _is_output_format(format) { + var formats = output_formats(); + for (var i = 0; i < formats.length; i++) { + if (formats[i] === format) { + return true; + } + } + return false; + } + + function _check_output_format(format) { + if (!format) { + return; + } else if (typeof format !== "string") { + throw new TypeError("When defined, the output format must be a string"); + } else if (!_is_output_format(format)) { + throw new Error(format + " is not a supported output format"); + } + } + + //--------------------------------------------------------------------------- + // Memory management + // + // AllocatedBuf: address allocated using _malloc() + length + function AllocatedBuf(length) { + this.length = length; + this.address = _malloc(length); + } + + // Copy the content of a AllocatedBuf (_malloc()'d memory) into a Uint8Array + AllocatedBuf.prototype.to_Uint8Array = function () { + var result = new Uint8Array(this.length); + result.set(libsodium.HEAPU8.subarray(this.address, this.address + this.length)); + return result; + }; + + // _malloc() a region and initialize it with the content of a Uint8Array + function _to_allocated_buf_address(bytes) { + var address = _malloc(bytes.length); + libsodium.HEAPU8.set(bytes, address); + return address; + } + + function _malloc(length) { + var result = libsodium._malloc(length); + if (result === 0) { + throw { + message: "_malloc() failed", + length: length + }; + } + return result; + } + + function _free(address) { + libsodium._free(address); + } + + function _free_all(addresses) { + for (var i = 0; i < addresses.length; i++) { + _free(addresses[i]); + } + } + + function _free_and_throw_error(address_pool, err) { + _free_all(address_pool); + throw new Error(err); + } + + function _free_and_throw_type_error(address_pool, err) { + _free_all(address_pool); + throw new TypeError(err); + } + + function _require_defined(address_pool, varValue, varName) { + if (varValue == undefined) { + _free_and_throw_type_error(address_pool, varName + " cannot be null or undefined"); + } + } + + function _any_to_Uint8Array(address_pool, varValue, varName) { + _require_defined(address_pool, varValue, varName); + if (varValue instanceof Uint8Array) { + return varValue; + } else if (typeof varValue === "string") { + return from_string(varValue); + } + _free_and_throw_type_error(address_pool, "unsupported input type for " + varName); + } + + + function crypto_aead_chacha20poly1305_decrypt(secret_nonce, ciphertext, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length - libsodium._crypto_aead_chacha20poly1305_abytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_chacha20poly1305_decrypt(message_address, null, secret_nonce_address, ciphertext_address, ciphertext_length, 0, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_decrypt_detached(secret_nonce, ciphertext, mac, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_box_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_chacha20poly1305_decrypt_detached(message_address, secret_nonce_address, ciphertext_address, ciphertext_length, 0, mac_address, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_encrypt(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_aead_chacha20poly1305_abytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_aead_chacha20poly1305_encrypt(ciphertext_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_encrypt_detached(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_aead_chacha20poly1305_abytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_aead_chacha20poly1305_encrypt_detached(ciphertext_address, mac_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output({ciphertext: ciphertext, mac: mac}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_decrypt(secret_nonce, ciphertext, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length - libsodium._crypto_aead_chacha20poly1305_ietf_abytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_chacha20poly1305_ietf_decrypt(message_address, null, secret_nonce_address, ciphertext_address, ciphertext_length, 0, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_decrypt_detached(secret_nonce, ciphertext, mac, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_box_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_chacha20poly1305_ietf_decrypt_detached(message_address, secret_nonce_address, ciphertext_address, ciphertext_length, 0, mac_address, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_encrypt(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_aead_chacha20poly1305_ietf_abytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_aead_chacha20poly1305_ietf_encrypt(ciphertext_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_encrypt_detached(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_chacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_aead_chacha20poly1305_ietf_abytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_aead_chacha20poly1305_ietf_encrypt_detached(ciphertext_address, mac_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output({ciphertext: ciphertext, mac: mac}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_chacha20poly1305_ietf_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_aead_chacha20poly1305_ietf_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_aead_chacha20poly1305_ietf_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_aead_chacha20poly1305_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_aead_chacha20poly1305_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_aead_chacha20poly1305_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_aead_xchacha20poly1305_ietf_decrypt(secret_nonce, ciphertext, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length - libsodium._crypto_aead_xchacha20poly1305_ietf_abytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_xchacha20poly1305_ietf_decrypt(message_address, null, secret_nonce_address, ciphertext_address, ciphertext_length, 0, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_xchacha20poly1305_ietf_decrypt_detached(secret_nonce, ciphertext, mac, additional_data, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_box_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_aead_xchacha20poly1305_ietf_decrypt_detached(message_address, secret_nonce_address, ciphertext_address, ciphertext_length, 0, mac_address, additional_data_address, additional_data_length, 0, public_nonce_address, key_address)) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_xchacha20poly1305_ietf_encrypt(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_aead_xchacha20poly1305_ietf_abytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_aead_xchacha20poly1305_ietf_encrypt(ciphertext_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_xchacha20poly1305_ietf_encrypt_detached(message, additional_data, secret_nonce, public_nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: additional_data (unsized_buf_optional) + + var additional_data_address = null, additional_data_length = 0; + if (additional_data != undefined) { + additional_data = _any_to_Uint8Array(address_pool, additional_data, "additional_data"); + additional_data_address = _to_allocated_buf_address(additional_data); + additional_data_length = additional_data.length; + address_pool.push(additional_data_address); + } + + // ---------- input: secret_nonce (unsized_buf_optional) + + var secret_nonce_address = null, secret_nonce_length = 0; + if (secret_nonce != undefined) { + secret_nonce = _any_to_Uint8Array(address_pool, secret_nonce, "secret_nonce"); + secret_nonce_address = _to_allocated_buf_address(secret_nonce); + secret_nonce_length = secret_nonce.length; + address_pool.push(secret_nonce_address); + } + + // ---------- input: public_nonce (buf) + + public_nonce = _any_to_Uint8Array(address_pool, public_nonce, "public_nonce"); + var public_nonce_address, public_nonce_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_npubbytes()) | 0; + if (public_nonce.length !== public_nonce_length) { + _free_and_throw_type_error(address_pool, "invalid public_nonce length"); + } + public_nonce_address = _to_allocated_buf_address(public_nonce); + address_pool.push(public_nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_abytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_aead_xchacha20poly1305_ietf_encrypt_detached(ciphertext_address, mac_address, null, message_address, message_length, 0, additional_data_address, additional_data_length, 0, secret_nonce_address, public_nonce_address, key_address)) === 0) { + var ret = _format_output({ciphertext: ciphertext, mac: mac}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_aead_xchacha20poly1305_ietf_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_aead_xchacha20poly1305_ietf_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_aead_xchacha20poly1305_ietf_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_auth(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output tag (buf) + + var tag_length = (libsodium._crypto_auth_bytes()) | 0, + tag = new AllocatedBuf(tag_length), + tag_address = tag.address; + + address_pool.push(tag_address); + + if ((libsodium._crypto_auth(tag_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(tag, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_auth_hmacsha256(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_hmacsha256_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_auth_hmacsha256_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_auth_hmacsha256(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_auth_hmacsha256_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_auth_hmacsha256_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_auth_hmacsha256_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } + + function crypto_auth_hmacsha256_verify(tag, message, key) { + var address_pool = []; + + // ---------- input: tag (buf) + + tag = _any_to_Uint8Array(address_pool, tag, "tag"); + var tag_address, tag_length = (libsodium._crypto_auth_hmacsha256_bytes()) | 0; + if (tag.length !== tag_length) { + _free_and_throw_type_error(address_pool, "invalid tag length"); + } + tag_address = _to_allocated_buf_address(tag); + address_pool.push(tag_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_hmacsha256_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + var result = libsodium._crypto_auth_hmacsha256_verify(tag_address, message_address, message_length, 0, key_address) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } + + function crypto_auth_hmacsha512(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_hmacsha512_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_auth_hmacsha512_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_auth_hmacsha512(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -function putListener() { - var listenerToPut = this; - EventPluginHub.putListener(listenerToPut.inst, listenerToPut.registrationName, listenerToPut.listener); -} + function crypto_auth_hmacsha512_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_auth_hmacsha512_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_auth_hmacsha512_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } -function inputPostMount() { - var inst = this; - ReactDOMInput.postMountWrapper(inst); -} + function crypto_auth_hmacsha512_verify(tag, message, key) { + var address_pool = []; -function textareaPostMount() { - var inst = this; - ReactDOMTextarea.postMountWrapper(inst); -} + // ---------- input: tag (buf) + + tag = _any_to_Uint8Array(address_pool, tag, "tag"); + var tag_address, tag_length = (libsodium._crypto_auth_hmacsha512_bytes()) | 0; + if (tag.length !== tag_length) { + _free_and_throw_type_error(address_pool, "invalid tag length"); + } + tag_address = _to_allocated_buf_address(tag); + address_pool.push(tag_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_hmacsha512_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + var result = libsodium._crypto_auth_hmacsha512_verify(tag_address, message_address, message_length, 0, key_address) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } -function optionPostMount() { - var inst = this; - ReactDOMOption.postMountWrapper(inst); -} + function crypto_auth_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_auth_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_auth_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } -var setAndValidateContentChildDev = emptyFunction; -if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev = function (content) { - var hasExistingContent = this._contentDebugID != null; - var debugID = this._debugID; - // This ID represents the inlined child that has no backing instance: - var contentDebugID = -debugID; + function crypto_auth_verify(tag, message, key) { + var address_pool = []; - if (content == null) { - if (hasExistingContent) { - ReactInstrumentation.debugTool.onUnmountComponent(this._contentDebugID); - } - this._contentDebugID = null; - return; - } + // ---------- input: tag (buf) + + tag = _any_to_Uint8Array(address_pool, tag, "tag"); + var tag_address, tag_length = (libsodium._crypto_auth_bytes()) | 0; + if (tag.length !== tag_length) { + _free_and_throw_type_error(address_pool, "invalid tag length"); + } + tag_address = _to_allocated_buf_address(tag); + address_pool.push(tag_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_auth_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + var result = libsodium._crypto_auth_verify(tag_address, message_address, message_length, 0, key_address) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } - validateDOMNesting(null, String(content), this, this._ancestorInfo); - this._contentDebugID = contentDebugID; - if (hasExistingContent) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(contentDebugID, content); - ReactInstrumentation.debugTool.onUpdateComponent(contentDebugID); - } else { - ReactInstrumentation.debugTool.onBeforeMountComponent(contentDebugID, content, debugID); - ReactInstrumentation.debugTool.onMountComponent(contentDebugID); - ReactInstrumentation.debugTool.onSetChildren(debugID, [contentDebugID]); - } - }; -} + function crypto_box_beforenm(publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -// There are so many media events, it makes sense to just -// maintain a list rather than create a `trapBubbledEvent` for each -var mediaEvents = { - topAbort: 'abort', - topCanPlay: 'canplay', - topCanPlayThrough: 'canplaythrough', - topDurationChange: 'durationchange', - topEmptied: 'emptied', - topEncrypted: 'encrypted', - topEnded: 'ended', - topError: 'error', - topLoadedData: 'loadeddata', - topLoadedMetadata: 'loadedmetadata', - topLoadStart: 'loadstart', - topPause: 'pause', - topPlay: 'play', - topPlaying: 'playing', - topProgress: 'progress', - topRateChange: 'ratechange', - topSeeked: 'seeked', - topSeeking: 'seeking', - topStalled: 'stalled', - topSuspend: 'suspend', - topTimeUpdate: 'timeupdate', - topVolumeChange: 'volumechange', - topWaiting: 'waiting' -}; + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output sharedKey (buf) + + var sharedKey_length = (libsodium._crypto_box_beforenmbytes()) | 0, + sharedKey = new AllocatedBuf(sharedKey_length), + sharedKey_address = sharedKey.address; + + address_pool.push(sharedKey_address); + + if ((libsodium._crypto_box_beforenm(sharedKey_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(sharedKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -function trackInputValue() { - inputValueTracking.track(this); -} + function crypto_box_detached(message, nonce, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_box_macbytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_box_detached(ciphertext_address, mac_address, message_address, message_length, 0, nonce_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output({ciphertext: ciphertext, mac: mac}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -function trapBubbledEventsLocal() { - var inst = this; - // If a component renders to null or if another component fatals and causes - // the state of the tree to be corrupted, `node` here can be null. - !inst._rootNodeID ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Must be mounted to trap events') : _prodInvariant('63') : void 0; - var node = getNode(inst); - !node ? process.env.NODE_ENV !== 'production' ? invariant(false, 'trapBubbledEvent(...): Requires node to be rendered.') : _prodInvariant('64') : void 0; + function crypto_box_easy(message, nonce, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_box_macbytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_box_easy(ciphertext_address, message_address, message_length, 0, nonce_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - switch (inst._tag) { - case 'iframe': - case 'object': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; - break; - case 'video': - case 'audio': - inst._wrapperState.listeners = []; - // Create listener for each media event - for (var event in mediaEvents) { - if (mediaEvents.hasOwnProperty(event)) { - inst._wrapperState.listeners.push(ReactBrowserEventEmitter.trapBubbledEvent(event, mediaEvents[event], node)); - } - } - break; - case 'source': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node)]; - break; - case 'img': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node), ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; - break; - case 'form': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topReset', 'reset', node), ReactBrowserEventEmitter.trapBubbledEvent('topSubmit', 'submit', node)]; - break; - case 'input': - case 'select': - case 'textarea': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topInvalid', 'invalid', node)]; - break; - } -} + function crypto_box_easy_afternm(message, nonce, sharedKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: sharedKey (buf) + + sharedKey = _any_to_Uint8Array(address_pool, sharedKey, "sharedKey"); + var sharedKey_address, sharedKey_length = (libsodium._crypto_box_beforenmbytes()) | 0; + if (sharedKey.length !== sharedKey_length) { + _free_and_throw_type_error(address_pool, "invalid sharedKey length"); + } + sharedKey_address = _to_allocated_buf_address(sharedKey); + address_pool.push(sharedKey_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_box_macbytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_box_easy_afternm(ciphertext_address, message_address, message_length, 0, nonce_address, sharedKey_address) | 0) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -function postUpdateSelectWrapper() { - ReactDOMSelect.postUpdateWrapper(this); -} + function crypto_box_keypair(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output secretKey (buf) + + var secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0, + secretKey = new AllocatedBuf(secretKey_length), + secretKey_address = secretKey.address; + + address_pool.push(secretKey_address); + + if ((libsodium._crypto_box_keypair(publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: secretKey, keyType: "curve25519"}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -// For HTML, certain tags should omit their close tag. We keep a whitelist for -// those special-case tags. + function crypto_box_open_detached(ciphertext, mac, nonce, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_box_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output plaintext (buf) + + var plaintext_length = (ciphertext_length) | 0, + plaintext = new AllocatedBuf(plaintext_length), + plaintext_address = plaintext.address; + + address_pool.push(plaintext_address); + + if ((libsodium._crypto_box_open_detached(plaintext_address, ciphertext_address, mac_address, ciphertext_length, 0, nonce_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(plaintext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var omittedCloseTags = { - area: true, - base: true, - br: true, - col: true, - embed: true, - hr: true, - img: true, - input: true, - keygen: true, - link: true, - meta: true, - param: true, - source: true, - track: true, - wbr: true - // NOTE: menuitem's close tag should be omitted, but that causes problems. -}; + function crypto_box_open_easy(ciphertext, nonce, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output plaintext (buf) + + var plaintext_length = (ciphertext_length - libsodium._crypto_box_macbytes()) | 0, + plaintext = new AllocatedBuf(plaintext_length), + plaintext_address = plaintext.address; + + address_pool.push(plaintext_address); + + if ((libsodium._crypto_box_open_easy(plaintext_address, ciphertext_address, ciphertext_length, 0, nonce_address, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(plaintext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var newlineEatingTags = { - listing: true, - pre: true, - textarea: true -}; + function crypto_box_open_easy_afternm(ciphertext, nonce, sharedKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_box_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: sharedKey (buf) + + sharedKey = _any_to_Uint8Array(address_pool, sharedKey, "sharedKey"); + var sharedKey_address, sharedKey_length = (libsodium._crypto_box_beforenmbytes()) | 0; + if (sharedKey.length !== sharedKey_length) { + _free_and_throw_type_error(address_pool, "invalid sharedKey length"); + } + sharedKey_address = _to_allocated_buf_address(sharedKey); + address_pool.push(sharedKey_address); + + // ---------- output plaintext (buf) + + var plaintext_length = (ciphertext_length - libsodium._crypto_box_macbytes()) | 0, + plaintext = new AllocatedBuf(plaintext_length), + plaintext_address = plaintext.address; + + address_pool.push(plaintext_address); + + if ((libsodium._crypto_box_open_easy_afternm(plaintext_address, ciphertext_address, ciphertext_length, 0, nonce_address, sharedKey_address) | 0) === 0) { + var ret = _format_output(plaintext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -// For HTML, certain tags cannot have children. This has the same purpose as -// `omittedCloseTags` except that `menuitem` should still have its closing tag. + function crypto_box_seal(message, publicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- output ciphertext (buf) + + var ciphertext_length = (message_length + libsodium._crypto_box_sealbytes()) | 0, + ciphertext = new AllocatedBuf(ciphertext_length), + ciphertext_address = ciphertext.address; + + address_pool.push(ciphertext_address); + + if ((libsodium._crypto_box_seal(ciphertext_address, message_address, message_length, 0, publicKey_address) | 0) === 0) { + var ret = _format_output(ciphertext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var voidElementTags = _assign({ - menuitem: true -}, omittedCloseTags); + function crypto_box_seal_open(ciphertext, publicKey, secretKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- input: secretKey (buf) + + secretKey = _any_to_Uint8Array(address_pool, secretKey, "secretKey"); + var secretKey_address, secretKey_length = (libsodium._crypto_box_secretkeybytes()) | 0; + if (secretKey.length !== secretKey_length) { + _free_and_throw_type_error(address_pool, "invalid secretKey length"); + } + secretKey_address = _to_allocated_buf_address(secretKey); + address_pool.push(secretKey_address); + + // ---------- output plaintext (buf) + + var plaintext_length = (ciphertext_length - libsodium._crypto_box_sealbytes()) | 0, + plaintext = new AllocatedBuf(plaintext_length), + plaintext_address = plaintext.address; + + address_pool.push(plaintext_address); + + if ((libsodium._crypto_box_seal_open(plaintext_address, ciphertext_address, ciphertext_length, 0, publicKey_address, secretKey_address) | 0) === 0) { + var ret = _format_output(plaintext, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -// We accept any tag to be rendered but since this gets injected into arbitrary -// HTML, we want to make sure that it's a safe tag. -// http://www.w3.org/TR/REC-xml/#NT-Name + function crypto_box_seed_keypair(seed, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -var VALID_TAG_REGEX = /^[a-zA-Z][a-zA-Z:_\.\-\d]*$/; // Simplified subset -var validatedTagCache = {}; -var hasOwnProperty = {}.hasOwnProperty; + // ---------- input: seed (buf) + + seed = _any_to_Uint8Array(address_pool, seed, "seed"); + var seed_address, seed_length = (libsodium._crypto_box_seedbytes()) | 0; + if (seed.length !== seed_length) { + _free_and_throw_type_error(address_pool, "invalid seed length"); + } + seed_address = _to_allocated_buf_address(seed); + address_pool.push(seed_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_box_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_box_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_box_seed_keypair(publicKey_address, privateKey_address, seed_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -function validateDangerousTag(tag) { - if (!hasOwnProperty.call(validatedTagCache, tag)) { - !VALID_TAG_REGEX.test(tag) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Invalid tag: %s', tag) : _prodInvariant('65', tag) : void 0; - validatedTagCache[tag] = true; - } -} + function crypto_generichash(hash_length, message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -function isCustomComponent(tagName, props) { - return tagName.indexOf('-') >= 0 || props.is != null; -} + // ---------- input: hash_length (uint) + + _require_defined(address_pool, hash_length, "hash_length"); + + if (!(typeof hash_length === "number" && (hash_length | 0) === hash_length) && (hash_length | 0) > 0) { + _free_and_throw_type_error(address_pool, "hash_length must be an unsigned integer"); + } + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (unsized_buf_optional) + + var key_address = null, key_length = 0; + if (key != undefined) { + key = _any_to_Uint8Array(address_pool, key, "key"); + key_address = _to_allocated_buf_address(key); + key_length = key.length; + address_pool.push(key_address); + } + + // ---------- output hash (buf) + + var hash_length = (hash_length) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_generichash(hash_address, hash_length, message_address, message_length, 0, key_address, key_length) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var globalIdCounter = 1; + function crypto_generichash_final(state_address, hash_length, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (generichash_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: hash_length (uint) + + _require_defined(address_pool, hash_length, "hash_length"); + + if (!(typeof hash_length === "number" && (hash_length | 0) === hash_length) && (hash_length | 0) > 0) { + _free_and_throw_type_error(address_pool, "hash_length must be an unsigned integer"); + } + + // ---------- output hash (buf) + + var hash_length = (hash_length) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_generichash_final(state_address, hash_address, hash_length) | 0) === 0) { + var ret = (libsodium._free(state_address), _format_output(hash, outputFormat)); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -/** - * Creates a new React class that is idempotent and capable of containing other - * React components. It accepts event listeners and DOM properties that are - * valid according to `DOMProperty`. - * - * - Event listeners: `onClick`, `onMouseDown`, etc. - * - DOM properties: `className`, `name`, `title`, etc. - * - * The `style` property functions differently from the DOM API. It accepts an - * object mapping of style properties to values. - * - * @constructor ReactDOMComponent - * @extends ReactMultiChild - */ -function ReactDOMComponent(element) { - var tag = element.type; - validateDangerousTag(tag); - this._currentElement = element; - this._tag = tag.toLowerCase(); - this._namespaceURI = null; - this._renderedChildren = null; - this._previousStyle = null; - this._previousStyleCopy = null; - this._hostNode = null; - this._hostParent = null; - this._rootNodeID = 0; - this._domID = 0; - this._hostContainerInfo = null; - this._wrapperState = null; - this._topLevelWrapper = null; - this._flags = 0; - if (process.env.NODE_ENV !== 'production') { - this._ancestorInfo = null; - setAndValidateContentChildDev.call(this, null); - } -} + function crypto_generichash_init(key, hash_length, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: key (unsized_buf_optional) + + var key_address = null, key_length = 0; + if (key != undefined) { + key = _any_to_Uint8Array(address_pool, key, "key"); + key_address = _to_allocated_buf_address(key); + key_length = key.length; + address_pool.push(key_address); + } + + // ---------- input: hash_length (uint) + + _require_defined(address_pool, hash_length, "hash_length"); + + if (!(typeof hash_length === "number" && (hash_length | 0) === hash_length) && (hash_length | 0) > 0) { + _free_and_throw_type_error(address_pool, "hash_length must be an unsigned integer"); + } + + // ---------- output state (generichash_state) + + var state_address = new AllocatedBuf(357).address; + + if ((libsodium._crypto_generichash_init(state_address, key_address, key_length, hash_length) | 0) === 0) { + var ret = state_address; + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -ReactDOMComponent.displayName = 'ReactDOMComponent'; + function crypto_generichash_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_generichash_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_generichash_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } -ReactDOMComponent.Mixin = { - /** - * Generates root tag markup then recurses. This method has side effects and - * is not idempotent. - * - * @internal - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?ReactDOMComponent} the parent component instance - * @param {?object} info about the host container - * @param {object} context - * @return {string} The computed markup. - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - this._rootNodeID = globalIdCounter++; - this._domID = hostContainerInfo._idCounter++; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; + function crypto_generichash_update(state_address, message_chunk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (generichash_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: message_chunk (unsized_buf) + + message_chunk = _any_to_Uint8Array(address_pool, message_chunk, "message_chunk"); + var message_chunk_address = _to_allocated_buf_address(message_chunk), + message_chunk_length = message_chunk.length; + address_pool.push(message_chunk_address); + + if ((libsodium._crypto_generichash_update(state_address, message_chunk_address, message_chunk_length) | 0) === 0) { + _free_all(address_pool); + return; + } + _free_and_throw_error(address_pool); + + } - var props = this._currentElement.props; + function crypto_hash(message, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_hash_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_hash(hash_address, message_address, message_length, 0) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - switch (this._tag) { - case 'audio': - case 'form': - case 'iframe': - case 'img': - case 'link': - case 'object': - case 'source': - case 'video': - this._wrapperState = { - listeners: null - }; - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'input': - ReactDOMInput.mountWrapper(this, props, hostParent); - props = ReactDOMInput.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trackInputValue, this); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'option': - ReactDOMOption.mountWrapper(this, props, hostParent); - props = ReactDOMOption.getHostProps(this, props); - break; - case 'select': - ReactDOMSelect.mountWrapper(this, props, hostParent); - props = ReactDOMSelect.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'textarea': - ReactDOMTextarea.mountWrapper(this, props, hostParent); - props = ReactDOMTextarea.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trackInputValue, this); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - } + function crypto_hash_sha256(message, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_hash_sha256_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_hash_sha256(hash_address, message_address, message_length, 0) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - assertValidProps(this, props); + function crypto_hash_sha512(message, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_hash_sha512_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_hash_sha512(hash_address, message_address, message_length, 0) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - // We create tags in the namespace of their parent container, except HTML - // tags get no namespace. - var namespaceURI; - var parentTag; - if (hostParent != null) { - namespaceURI = hostParent._namespaceURI; - parentTag = hostParent._tag; - } else if (hostContainerInfo._tag) { - namespaceURI = hostContainerInfo._namespaceURI; - parentTag = hostContainerInfo._tag; - } - if (namespaceURI == null || namespaceURI === DOMNamespaces.svg && parentTag === 'foreignobject') { - namespaceURI = DOMNamespaces.html; - } - if (namespaceURI === DOMNamespaces.html) { - if (this._tag === 'svg') { - namespaceURI = DOMNamespaces.svg; - } else if (this._tag === 'math') { - namespaceURI = DOMNamespaces.mathml; - } - } - this._namespaceURI = namespaceURI; + function crypto_kdf_derive_from_key(subkey_len, subkey_id, ctx, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - if (process.env.NODE_ENV !== 'production') { - var parentInfo; - if (hostParent != null) { - parentInfo = hostParent._ancestorInfo; - } else if (hostContainerInfo._tag) { - parentInfo = hostContainerInfo._ancestorInfo; - } - if (parentInfo) { - // parentInfo should always be present except for the top-level - // component when server rendering - validateDOMNesting(this._tag, null, this, parentInfo); - } - this._ancestorInfo = validateDOMNesting.updatedAncestorInfo(parentInfo, this._tag, this); - } + // ---------- input: subkey_len (uint) + + _require_defined(address_pool, subkey_len, "subkey_len"); + + if (!(typeof subkey_len === "number" && (subkey_len | 0) === subkey_len) && (subkey_len | 0) > 0) { + _free_and_throw_type_error(address_pool, "subkey_len must be an unsigned integer"); + } + + // ---------- input: subkey_id (uint) + + _require_defined(address_pool, subkey_id, "subkey_id"); + + if (!(typeof subkey_id === "number" && (subkey_id | 0) === subkey_id) && (subkey_id | 0) > 0) { + _free_and_throw_type_error(address_pool, "subkey_id must be an unsigned integer"); + } + + // ---------- input: ctx (string) + + ctx = from_string(ctx + "\0"); + var ctx_address = _to_allocated_buf_address(ctx), + ctx_length = ctx.length - 1; + address_pool.push(ctx_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_kdf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output subkey (buf) + + var subkey_length = (subkey_len) | 0, + subkey = new AllocatedBuf(subkey_length), + subkey_address = subkey.address; + + address_pool.push(subkey_address); + + libsodium._crypto_kdf_derive_from_key(subkey_address, subkey_len, 0, subkey_id, 0, ctx_address, key_address); + var ret = (_format_output(subkey, outputFormat)); + _free_all(address_pool); + return ret; + + } - var mountImage; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var el; - if (namespaceURI === DOMNamespaces.html) { - if (this._tag === 'script') { - // Create the script via .innerHTML so its "parser-inserted" flag is - // set to true and it does not execute - var div = ownerDocument.createElement('div'); - var type = this._currentElement.type; - div.innerHTML = '<' + type + '></' + type + '>'; - el = div.removeChild(div.firstChild); - } else if (props.is) { - el = ownerDocument.createElement(this._currentElement.type, props.is); - } else { - // Separate else branch instead of using `props.is || undefined` above becuase of a Firefox bug. - // See discussion in https://github.com/facebook/react/pull/6896 - // and discussion in https://bugzilla.mozilla.org/show_bug.cgi?id=1276240 - el = ownerDocument.createElement(this._currentElement.type); - } - } else { - el = ownerDocument.createElementNS(namespaceURI, this._currentElement.type); - } - ReactDOMComponentTree.precacheNode(this, el); - this._flags |= Flags.hasCachedChildNodes; - if (!this._hostParent) { - DOMPropertyOperations.setAttributeForRoot(el); - } - this._updateDOMProperties(null, props, transaction); - var lazyTree = DOMLazyTree(el); - this._createInitialChildren(transaction, props, context, lazyTree); - mountImage = lazyTree; - } else { - var tagOpen = this._createOpenTagMarkupAndPutListeners(transaction, props); - var tagContent = this._createContentMarkup(transaction, props, context); - if (!tagContent && omittedCloseTags[this._tag]) { - mountImage = tagOpen + '/>'; - } else { - mountImage = tagOpen + '>' + tagContent + '</' + this._currentElement.type + '>'; - } - } + function crypto_kdf_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_kdf_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_kdf_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - switch (this._tag) { - case 'input': - transaction.getReactMountReady().enqueue(inputPostMount, this); - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'textarea': - transaction.getReactMountReady().enqueue(textareaPostMount, this); - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'select': - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'button': - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'option': - transaction.getReactMountReady().enqueue(optionPostMount, this); - break; - } + function crypto_kx_client_session_keys(clientPublicKey, clientSecretKey, serverPublicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - return mountImage; - }, + // ---------- input: clientPublicKey (buf) + + clientPublicKey = _any_to_Uint8Array(address_pool, clientPublicKey, "clientPublicKey"); + var clientPublicKey_address, clientPublicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0; + if (clientPublicKey.length !== clientPublicKey_length) { + _free_and_throw_type_error(address_pool, "invalid clientPublicKey length"); + } + clientPublicKey_address = _to_allocated_buf_address(clientPublicKey); + address_pool.push(clientPublicKey_address); + + // ---------- input: clientSecretKey (buf) + + clientSecretKey = _any_to_Uint8Array(address_pool, clientSecretKey, "clientSecretKey"); + var clientSecretKey_address, clientSecretKey_length = (libsodium._crypto_kx_secretkeybytes()) | 0; + if (clientSecretKey.length !== clientSecretKey_length) { + _free_and_throw_type_error(address_pool, "invalid clientSecretKey length"); + } + clientSecretKey_address = _to_allocated_buf_address(clientSecretKey); + address_pool.push(clientSecretKey_address); + + // ---------- input: serverPublicKey (buf) + + serverPublicKey = _any_to_Uint8Array(address_pool, serverPublicKey, "serverPublicKey"); + var serverPublicKey_address, serverPublicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0; + if (serverPublicKey.length !== serverPublicKey_length) { + _free_and_throw_type_error(address_pool, "invalid serverPublicKey length"); + } + serverPublicKey_address = _to_allocated_buf_address(serverPublicKey); + address_pool.push(serverPublicKey_address); + + // ---------- output sharedRx (buf) + + var sharedRx_length = (libsodium._crypto_kx_sessionkeybytes()) | 0, + sharedRx = new AllocatedBuf(sharedRx_length), + sharedRx_address = sharedRx.address; + + address_pool.push(sharedRx_address); + + // ---------- output sharedTx (buf) + + var sharedTx_length = (libsodium._crypto_kx_sessionkeybytes()) | 0, + sharedTx = new AllocatedBuf(sharedTx_length), + sharedTx_address = sharedTx.address; + + address_pool.push(sharedTx_address); + + if ((libsodium._crypto_kx_client_session_keys(sharedRx_address, sharedTx_address, clientPublicKey_address, clientSecretKey_address, serverPublicKey_address) | 0) === 0) { + var ret = _format_output({sharedRx: sharedRx, sharedTx: sharedTx}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - /** - * Creates markup for the open tag and all attributes. - * - * This method has side effects because events get registered. - * - * Iterating over object properties is faster than iterating over arrays. - * @see http://jsperf.com/obj-vs-arr-iteration - * - * @private - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} props - * @return {string} Markup of opening tag. - */ - _createOpenTagMarkupAndPutListeners: function (transaction, props) { - var ret = '<' + this._currentElement.type; + function crypto_kx_keypair(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_kx_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_kx_keypair(publicKey_address, privateKey_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - for (var propKey in props) { - if (!props.hasOwnProperty(propKey)) { - continue; - } - var propValue = props[propKey]; - if (propValue == null) { - continue; - } - if (registrationNameModules.hasOwnProperty(propKey)) { - if (propValue) { - enqueuePutListener(this, propKey, propValue, transaction); - } - } else { - if (propKey === STYLE) { - if (propValue) { - if (process.env.NODE_ENV !== 'production') { - // See `_updateDOMProperties`. style block - this._previousStyle = propValue; - } - propValue = this._previousStyleCopy = _assign({}, props.style); - } - propValue = CSSPropertyOperations.createMarkupForStyles(propValue, this); - } - var markup = null; - if (this._tag != null && isCustomComponent(this._tag, props)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - markup = DOMPropertyOperations.createMarkupForCustomAttribute(propKey, propValue); - } - } else { - markup = DOMPropertyOperations.createMarkupForProperty(propKey, propValue); - } - if (markup) { - ret += ' ' + markup; - } - } - } + function crypto_kx_seed_keypair(seed, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: seed (buf) + + seed = _any_to_Uint8Array(address_pool, seed, "seed"); + var seed_address, seed_length = (libsodium._crypto_kx_seedbytes()) | 0; + if (seed.length !== seed_length) { + _free_and_throw_type_error(address_pool, "invalid seed length"); + } + seed_address = _to_allocated_buf_address(seed); + address_pool.push(seed_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_kx_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_kx_seed_keypair(publicKey_address, privateKey_address, seed_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_kx_server_session_keys(serverPublicKey, serverSecretKey, clientPublicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: serverPublicKey (buf) + + serverPublicKey = _any_to_Uint8Array(address_pool, serverPublicKey, "serverPublicKey"); + var serverPublicKey_address, serverPublicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0; + if (serverPublicKey.length !== serverPublicKey_length) { + _free_and_throw_type_error(address_pool, "invalid serverPublicKey length"); + } + serverPublicKey_address = _to_allocated_buf_address(serverPublicKey); + address_pool.push(serverPublicKey_address); + + // ---------- input: serverSecretKey (buf) + + serverSecretKey = _any_to_Uint8Array(address_pool, serverSecretKey, "serverSecretKey"); + var serverSecretKey_address, serverSecretKey_length = (libsodium._crypto_kx_secretkeybytes()) | 0; + if (serverSecretKey.length !== serverSecretKey_length) { + _free_and_throw_type_error(address_pool, "invalid serverSecretKey length"); + } + serverSecretKey_address = _to_allocated_buf_address(serverSecretKey); + address_pool.push(serverSecretKey_address); + + // ---------- input: clientPublicKey (buf) + + clientPublicKey = _any_to_Uint8Array(address_pool, clientPublicKey, "clientPublicKey"); + var clientPublicKey_address, clientPublicKey_length = (libsodium._crypto_kx_publickeybytes()) | 0; + if (clientPublicKey.length !== clientPublicKey_length) { + _free_and_throw_type_error(address_pool, "invalid clientPublicKey length"); + } + clientPublicKey_address = _to_allocated_buf_address(clientPublicKey); + address_pool.push(clientPublicKey_address); + + // ---------- output sharedRx (buf) + + var sharedRx_length = (libsodium._crypto_kx_sessionkeybytes()) | 0, + sharedRx = new AllocatedBuf(sharedRx_length), + sharedRx_address = sharedRx.address; + + address_pool.push(sharedRx_address); + + // ---------- output sharedTx (buf) + + var sharedTx_length = (libsodium._crypto_kx_sessionkeybytes()) | 0, + sharedTx = new AllocatedBuf(sharedTx_length), + sharedTx_address = sharedTx.address; + + address_pool.push(sharedTx_address); + + if ((libsodium._crypto_kx_server_session_keys(sharedRx_address, sharedTx_address, serverPublicKey_address, serverSecretKey_address, clientPublicKey_address) | 0) === 0) { + var ret = _format_output({sharedRx: sharedRx, sharedTx: sharedTx}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_onetimeauth(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_onetimeauth_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_onetimeauth_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_onetimeauth(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_onetimeauth_final(state_address, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (onetimeauth_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_onetimeauth_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_onetimeauth_final(state_address, hash_address) | 0) === 0) { + var ret = (libsodium._free(state_address), _format_output(hash, outputFormat)); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_onetimeauth_init(key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: key (unsized_buf_optional) + + var key_address = null, key_length = 0; + if (key != undefined) { + key = _any_to_Uint8Array(address_pool, key, "key"); + key_address = _to_allocated_buf_address(key); + key_length = key.length; + address_pool.push(key_address); + } + + // ---------- output state (onetimeauth_state) + + var state_address = new AllocatedBuf(144).address; + + if ((libsodium._crypto_onetimeauth_init(state_address, key_address) | 0) === 0) { + var ret = state_address; + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - // For static pages, no need to put React ID and checksum. Saves lots of - // bytes. - if (transaction.renderToStaticMarkup) { - return ret; - } + function crypto_onetimeauth_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_onetimeauth_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_onetimeauth_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - if (!this._hostParent) { - ret += ' ' + DOMPropertyOperations.createMarkupForRoot(); - } - ret += ' ' + DOMPropertyOperations.createMarkupForID(this._domID); - return ret; - }, + function crypto_onetimeauth_update(state_address, message_chunk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (onetimeauth_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: message_chunk (unsized_buf) + + message_chunk = _any_to_Uint8Array(address_pool, message_chunk, "message_chunk"); + var message_chunk_address = _to_allocated_buf_address(message_chunk), + message_chunk_length = message_chunk.length; + address_pool.push(message_chunk_address); + + if ((libsodium._crypto_onetimeauth_update(state_address, message_chunk_address, message_chunk_length) | 0) === 0) { + _free_all(address_pool); + return; + } + _free_and_throw_error(address_pool); + + } - /** - * Creates markup for the content between the tags. - * - * @private - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} props - * @param {object} context - * @return {string} Content markup. - */ - _createContentMarkup: function (transaction, props, context) { - var ret = ''; + function crypto_onetimeauth_verify(hash, message, key) { + var address_pool = []; - // Intentional use of != to avoid catching zero/false. - var innerHTML = props.dangerouslySetInnerHTML; - if (innerHTML != null) { - if (innerHTML.__html != null) { - ret = innerHTML.__html; - } - } else { - var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; - var childrenToUse = contentToUse != null ? null : props.children; - if (contentToUse != null) { - // TODO: Validate that text is allowed as a child of this node - ret = escapeTextContentForBrowser(contentToUse); - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, contentToUse); - } - } else if (childrenToUse != null) { - var mountImages = this.mountChildren(childrenToUse, transaction, context); - ret = mountImages.join(''); - } - } - if (newlineEatingTags[this._tag] && ret.charAt(0) === '\n') { - // text/html ignores the first character in these tags if it's a newline - // Prefer to break application/xml over text/html (for now) by adding - // a newline specifically to get eaten by the parser. (Alternately for - // textareas, replacing "^\n" with "\r\n" doesn't get eaten, and the first - // \r is normalized out by HTMLTextAreaElement#value.) - // See: <http://www.w3.org/TR/html-polyglot/#newlines-in-textarea-and-pre> - // See: <http://www.w3.org/TR/html5/syntax.html#element-restrictions> - // See: <http://www.w3.org/TR/html5/syntax.html#newlines> - // See: Parsing of "textarea" "listing" and "pre" elements - // from <http://www.w3.org/TR/html5/syntax.html#parsing-main-inbody> - return '\n' + ret; - } else { - return ret; - } - }, + // ---------- input: hash (buf) + + hash = _any_to_Uint8Array(address_pool, hash, "hash"); + var hash_address, hash_length = (libsodium._crypto_onetimeauth_bytes()) | 0; + if (hash.length !== hash_length) { + _free_and_throw_type_error(address_pool, "invalid hash length"); + } + hash_address = _to_allocated_buf_address(hash); + address_pool.push(hash_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_onetimeauth_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + var result = libsodium._crypto_onetimeauth_verify(hash_address, message_address, message_length, 0, key_address) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } - _createInitialChildren: function (transaction, props, context, lazyTree) { - // Intentional use of != to avoid catching zero/false. - var innerHTML = props.dangerouslySetInnerHTML; - if (innerHTML != null) { - if (innerHTML.__html != null) { - DOMLazyTree.queueHTML(lazyTree, innerHTML.__html); - } - } else { - var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; - var childrenToUse = contentToUse != null ? null : props.children; - // TODO: Validate that text is allowed as a child of this node - if (contentToUse != null) { - // Avoid setting textContent when the text is empty. In IE11 setting - // textContent on a text area will cause the placeholder to not - // show within the textarea until it has been focused and blurred again. - // https://github.com/facebook/react/issues/6731#issuecomment-254874553 - if (contentToUse !== '') { - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, contentToUse); - } - DOMLazyTree.queueText(lazyTree, contentToUse); - } - } else if (childrenToUse != null) { - var mountImages = this.mountChildren(childrenToUse, transaction, context); - for (var i = 0; i < mountImages.length; i++) { - DOMLazyTree.queueChild(lazyTree, mountImages[i]); - } - } - } - }, + function crypto_pwhash(keyLength, password, salt, opsLimit, memLimit, algorithm, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - /** - * Receives a next element and updates the component. - * - * @internal - * @param {ReactElement} nextElement - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} context - */ - receiveComponent: function (nextElement, transaction, context) { - var prevElement = this._currentElement; - this._currentElement = nextElement; - this.updateComponent(transaction, prevElement, nextElement, context); - }, + // ---------- input: keyLength (uint) + + _require_defined(address_pool, keyLength, "keyLength"); + + if (!(typeof keyLength === "number" && (keyLength | 0) === keyLength) && (keyLength | 0) > 0) { + _free_and_throw_type_error(address_pool, "keyLength must be an unsigned integer"); + } + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: salt (buf) + + salt = _any_to_Uint8Array(address_pool, salt, "salt"); + var salt_address, salt_length = (libsodium._crypto_pwhash_saltbytes()) | 0; + if (salt.length !== salt_length) { + _free_and_throw_type_error(address_pool, "invalid salt length"); + } + salt_address = _to_allocated_buf_address(salt); + address_pool.push(salt_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: memLimit (uint) + + _require_defined(address_pool, memLimit, "memLimit"); + + if (!(typeof memLimit === "number" && (memLimit | 0) === memLimit) && (memLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "memLimit must be an unsigned integer"); + } + + // ---------- input: algorithm (uint) + + _require_defined(address_pool, algorithm, "algorithm"); + + if (!(typeof algorithm === "number" && (algorithm | 0) === algorithm) && (algorithm | 0) > 0) { + _free_and_throw_type_error(address_pool, "algorithm must be an unsigned integer"); + } + + // ---------- output derivedKey (buf) + + var derivedKey_length = (keyLength) | 0, + derivedKey = new AllocatedBuf(derivedKey_length), + derivedKey_address = derivedKey.address; + + address_pool.push(derivedKey_address); + + if ((libsodium._crypto_pwhash(derivedKey_address, keyLength, 0, password_address, password_length, 0, salt_address, opsLimit, 0, memLimit, algorithm) | 0) === 0) { + var ret = _format_output(derivedKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - /** - * Updates a DOM component after it has already been allocated and - * attached to the DOM. Reconciles the root DOM node, then recurses. - * - * @param {ReactReconcileTransaction} transaction - * @param {ReactElement} prevElement - * @param {ReactElement} nextElement - * @internal - * @overridable - */ - updateComponent: function (transaction, prevElement, nextElement, context) { - var lastProps = prevElement.props; - var nextProps = this._currentElement.props; + function crypto_pwhash_scryptsalsa208sha256(keyLength, password, salt, opsLimit, memLimit, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - switch (this._tag) { - case 'input': - lastProps = ReactDOMInput.getHostProps(this, lastProps); - nextProps = ReactDOMInput.getHostProps(this, nextProps); - break; - case 'option': - lastProps = ReactDOMOption.getHostProps(this, lastProps); - nextProps = ReactDOMOption.getHostProps(this, nextProps); - break; - case 'select': - lastProps = ReactDOMSelect.getHostProps(this, lastProps); - nextProps = ReactDOMSelect.getHostProps(this, nextProps); - break; - case 'textarea': - lastProps = ReactDOMTextarea.getHostProps(this, lastProps); - nextProps = ReactDOMTextarea.getHostProps(this, nextProps); - break; - } + // ---------- input: keyLength (uint) + + _require_defined(address_pool, keyLength, "keyLength"); + + if (!(typeof keyLength === "number" && (keyLength | 0) === keyLength) && (keyLength | 0) > 0) { + _free_and_throw_type_error(address_pool, "keyLength must be an unsigned integer"); + } + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: salt (buf) + + salt = _any_to_Uint8Array(address_pool, salt, "salt"); + var salt_address, salt_length = (libsodium._crypto_pwhash_scryptsalsa208sha256_saltbytes()) | 0; + if (salt.length !== salt_length) { + _free_and_throw_type_error(address_pool, "invalid salt length"); + } + salt_address = _to_allocated_buf_address(salt); + address_pool.push(salt_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: memLimit (uint) + + _require_defined(address_pool, memLimit, "memLimit"); + + if (!(typeof memLimit === "number" && (memLimit | 0) === memLimit) && (memLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "memLimit must be an unsigned integer"); + } + + // ---------- output derivedKey (buf) + + var derivedKey_length = (keyLength) | 0, + derivedKey = new AllocatedBuf(derivedKey_length), + derivedKey_address = derivedKey.address; + + address_pool.push(derivedKey_address); + + if ((libsodium._crypto_pwhash_scryptsalsa208sha256(derivedKey_address, keyLength, 0, password_address, password_length, 0, salt_address, opsLimit, 0, memLimit) | 0) === 0) { + var ret = _format_output(derivedKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - assertValidProps(this, nextProps); - this._updateDOMProperties(lastProps, nextProps, transaction); - this._updateDOMChildren(lastProps, nextProps, transaction, context); + function crypto_pwhash_scryptsalsa208sha256_ll(password, salt, opsLimit, r, p, keyLength, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: salt (unsized_buf) + + salt = _any_to_Uint8Array(address_pool, salt, "salt"); + var salt_address = _to_allocated_buf_address(salt), + salt_length = salt.length; + address_pool.push(salt_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: r (uint) + + _require_defined(address_pool, r, "r"); + + if (!(typeof r === "number" && (r | 0) === r) && (r | 0) > 0) { + _free_and_throw_type_error(address_pool, "r must be an unsigned integer"); + } + + // ---------- input: p (uint) + + _require_defined(address_pool, p, "p"); + + if (!(typeof p === "number" && (p | 0) === p) && (p | 0) > 0) { + _free_and_throw_type_error(address_pool, "p must be an unsigned integer"); + } + + // ---------- input: keyLength (uint) + + _require_defined(address_pool, keyLength, "keyLength"); + + if (!(typeof keyLength === "number" && (keyLength | 0) === keyLength) && (keyLength | 0) > 0) { + _free_and_throw_type_error(address_pool, "keyLength must be an unsigned integer"); + } + + // ---------- output derivedKey (buf) + + var derivedKey_length = (keyLength) | 0, + derivedKey = new AllocatedBuf(derivedKey_length), + derivedKey_address = derivedKey.address; + + address_pool.push(derivedKey_address); + + if ((libsodium._crypto_pwhash_scryptsalsa208sha256_ll(password_address, password_length, salt_address, salt_length, opsLimit, 0, r, p, derivedKey_address, keyLength) | 0) === 0) { + var ret = _format_output(derivedKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - switch (this._tag) { - case 'input': - // Update the wrapper around inputs *after* updating props. This has to - // happen after `_updateDOMProperties`. Otherwise HTML5 input validations - // raise warnings and prevent the new value from being assigned. - ReactDOMInput.updateWrapper(this); - break; - case 'textarea': - ReactDOMTextarea.updateWrapper(this); - break; - case 'select': - // <select> value update needs to occur after <option> children - // reconciliation - transaction.getReactMountReady().enqueue(postUpdateSelectWrapper, this); - break; - } - }, + function crypto_pwhash_scryptsalsa208sha256_str(password, opsLimit, memLimit, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: memLimit (uint) + + _require_defined(address_pool, memLimit, "memLimit"); + + if (!(typeof memLimit === "number" && (memLimit | 0) === memLimit) && (memLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "memLimit must be an unsigned integer"); + } + + // ---------- output hashed_password (buf) + + var hashed_password_length = (libsodium._crypto_pwhash_scryptsalsa208sha256_strbytes()) | 0, + hashed_password = new AllocatedBuf(hashed_password_length), + hashed_password_address = hashed_password.address; + + address_pool.push(hashed_password_address); + + if ((libsodium._crypto_pwhash_scryptsalsa208sha256_str(hashed_password_address, password_address, password_length, 0, opsLimit, 0, memLimit) | 0) === 0) { + var ret = libsodium.Pointer_stringify(hashed_password_address); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - /** - * Reconciles the properties by detecting differences in property values and - * updating the DOM as necessary. This function is probably the single most - * critical path for performance optimization. - * - * TODO: Benchmark whether checking for changed values in memory actually - * improves performance (especially statically positioned elements). - * TODO: Benchmark the effects of putting this at the top since 99% of props - * do not change for a given reconciliation. - * TODO: Benchmark areas that can be improved with caching. - * - * @private - * @param {object} lastProps - * @param {object} nextProps - * @param {?DOMElement} node - */ - _updateDOMProperties: function (lastProps, nextProps, transaction) { - var propKey; - var styleName; - var styleUpdates; - for (propKey in lastProps) { - if (nextProps.hasOwnProperty(propKey) || !lastProps.hasOwnProperty(propKey) || lastProps[propKey] == null) { - continue; - } - if (propKey === STYLE) { - var lastStyle = this._previousStyleCopy; - for (styleName in lastStyle) { - if (lastStyle.hasOwnProperty(styleName)) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = ''; - } - } - this._previousStyleCopy = null; - } else if (registrationNameModules.hasOwnProperty(propKey)) { - if (lastProps[propKey]) { - // Only call deleteListener if there was a listener previously or - // else willDeleteListener gets called when there wasn't actually a - // listener (e.g., onClick={null}) - deleteListener(this, propKey); - } - } else if (isCustomComponent(this._tag, lastProps)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - DOMPropertyOperations.deleteValueForAttribute(getNode(this), propKey); - } - } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { - DOMPropertyOperations.deleteValueForProperty(getNode(this), propKey); - } - } - for (propKey in nextProps) { - var nextProp = nextProps[propKey]; - var lastProp = propKey === STYLE ? this._previousStyleCopy : lastProps != null ? lastProps[propKey] : undefined; - if (!nextProps.hasOwnProperty(propKey) || nextProp === lastProp || nextProp == null && lastProp == null) { - continue; - } - if (propKey === STYLE) { - if (nextProp) { - if (process.env.NODE_ENV !== 'production') { - checkAndWarnForMutatedStyle(this._previousStyleCopy, this._previousStyle, this); - this._previousStyle = nextProp; - } - nextProp = this._previousStyleCopy = _assign({}, nextProp); - } else { - this._previousStyleCopy = null; - } - if (lastProp) { - // Unset styles on `lastProp` but not on `nextProp`. - for (styleName in lastProp) { - if (lastProp.hasOwnProperty(styleName) && (!nextProp || !nextProp.hasOwnProperty(styleName))) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = ''; - } - } - // Update styles that changed since `lastProp`. - for (styleName in nextProp) { - if (nextProp.hasOwnProperty(styleName) && lastProp[styleName] !== nextProp[styleName]) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = nextProp[styleName]; - } - } - } else { - // Relies on `updateStylesByID` not mutating `styleUpdates`. - styleUpdates = nextProp; - } - } else if (registrationNameModules.hasOwnProperty(propKey)) { - if (nextProp) { - enqueuePutListener(this, propKey, nextProp, transaction); - } else if (lastProp) { - deleteListener(this, propKey); - } - } else if (isCustomComponent(this._tag, nextProps)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - DOMPropertyOperations.setValueForAttribute(getNode(this), propKey, nextProp); - } - } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { - var node = getNode(this); - // If we're updating to null or undefined, we should remove the property - // from the DOM node instead of inadvertently setting to a string. This - // brings us in line with the same behavior we have on initial render. - if (nextProp != null) { - DOMPropertyOperations.setValueForProperty(node, propKey, nextProp); - } else { - DOMPropertyOperations.deleteValueForProperty(node, propKey); - } - } - } - if (styleUpdates) { - CSSPropertyOperations.setValueForStyles(getNode(this), styleUpdates, this); - } - }, + function crypto_pwhash_scryptsalsa208sha256_str_verify(hashed_password, password, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: hashed_password (string) + + hashed_password = from_string(hashed_password + "\0"); + var hashed_password_address = _to_allocated_buf_address(hashed_password), + hashed_password_length = hashed_password.length - 1; + address_pool.push(hashed_password_address); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + var result = libsodium._crypto_pwhash_scryptsalsa208sha256_str_verify(hashed_password_address, password_address, password_length, 0) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } - /** - * Reconciles the children with the various properties that affect the - * children content. - * - * @param {object} lastProps - * @param {object} nextProps - * @param {ReactReconcileTransaction} transaction - * @param {object} context - */ - _updateDOMChildren: function (lastProps, nextProps, transaction, context) { - var lastContent = CONTENT_TYPES[typeof lastProps.children] ? lastProps.children : null; - var nextContent = CONTENT_TYPES[typeof nextProps.children] ? nextProps.children : null; + function crypto_pwhash_str(password, opsLimit, memLimit, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + // ---------- input: opsLimit (uint) + + _require_defined(address_pool, opsLimit, "opsLimit"); + + if (!(typeof opsLimit === "number" && (opsLimit | 0) === opsLimit) && (opsLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "opsLimit must be an unsigned integer"); + } + + // ---------- input: memLimit (uint) + + _require_defined(address_pool, memLimit, "memLimit"); + + if (!(typeof memLimit === "number" && (memLimit | 0) === memLimit) && (memLimit | 0) > 0) { + _free_and_throw_type_error(address_pool, "memLimit must be an unsigned integer"); + } + + // ---------- output hashed_password (buf) + + var hashed_password_length = (libsodium._crypto_pwhash_strbytes()) | 0, + hashed_password = new AllocatedBuf(hashed_password_length), + hashed_password_address = hashed_password.address; + + address_pool.push(hashed_password_address); + + if ((libsodium._crypto_pwhash_str(hashed_password_address, password_address, password_length, 0, opsLimit, 0, memLimit) | 0) === 0) { + var ret = libsodium.Pointer_stringify(hashed_password_address); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - var lastHtml = lastProps.dangerouslySetInnerHTML && lastProps.dangerouslySetInnerHTML.__html; - var nextHtml = nextProps.dangerouslySetInnerHTML && nextProps.dangerouslySetInnerHTML.__html; + function crypto_pwhash_str_verify(hashed_password, password, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: hashed_password (string) + + hashed_password = from_string(hashed_password + "\0"); + var hashed_password_address = _to_allocated_buf_address(hashed_password), + hashed_password_length = hashed_password.length - 1; + address_pool.push(hashed_password_address); + + // ---------- input: password (unsized_buf) + + password = _any_to_Uint8Array(address_pool, password, "password"); + var password_address = _to_allocated_buf_address(password), + password_length = password.length; + address_pool.push(password_address); + + var result = libsodium._crypto_pwhash_str_verify(hashed_password_address, password_address, password_length, 0) | 0; + var ret = (result === 0); + _free_all(address_pool); + return ret; + + } - // Note the use of `!=` which checks for null or undefined. - var lastChildren = lastContent != null ? null : lastProps.children; - var nextChildren = nextContent != null ? null : nextProps.children; + function crypto_scalarmult(privateKey, publicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - // If we're switching from children to content/html or vice versa, remove - // the old content - var lastHasContentOrHtml = lastContent != null || lastHtml != null; - var nextHasContentOrHtml = nextContent != null || nextHtml != null; - if (lastChildren != null && nextChildren == null) { - this.updateChildren(null, transaction, context); - } else if (lastHasContentOrHtml && !nextHasContentOrHtml) { - this.updateTextContent(''); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); - } - } + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- output sharedSecret (buf) + + var sharedSecret_length = (libsodium._crypto_scalarmult_bytes()) | 0, + sharedSecret = new AllocatedBuf(sharedSecret_length), + sharedSecret_address = sharedSecret.address; + + address_pool.push(sharedSecret_address); + + if ((libsodium._crypto_scalarmult(sharedSecret_address, privateKey_address, publicKey_address) | 0) === 0) { + var ret = _format_output(sharedSecret, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - if (nextContent != null) { - if (lastContent !== nextContent) { - this.updateTextContent('' + nextContent); - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, nextContent); - } - } - } else if (nextHtml != null) { - if (lastHtml !== nextHtml) { - this.updateMarkup('' + nextHtml); - } - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); - } - } else if (nextChildren != null) { - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, null); - } + function crypto_scalarmult_base(privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - this.updateChildren(nextChildren, transaction, context); - } - }, + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + if ((libsodium._crypto_scalarmult_base(publicKey_address, privateKey_address) | 0) === 0) { + var ret = _format_output(publicKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - getHostNode: function () { - return getNode(this); - }, + function crypto_secretbox_detached(message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_secretbox_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_secretbox_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output cipher (buf) + + var cipher_length = (message_length) | 0, + cipher = new AllocatedBuf(cipher_length), + cipher_address = cipher.address; + + address_pool.push(cipher_address); + + // ---------- output mac (buf) + + var mac_length = (libsodium._crypto_secretbox_macbytes()) | 0, + mac = new AllocatedBuf(mac_length), + mac_address = mac.address; + + address_pool.push(mac_address); + + if ((libsodium._crypto_secretbox_detached(cipher_address, mac_address, message_address, message_length, 0, nonce_address, key_address) | 0) === 0) { + var ret = _format_output({mac: mac, cipher: cipher}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - /** - * Destroys all event registrations for this instance. Does not remove from - * the DOM. That must be done by the parent. - * - * @internal - */ - unmountComponent: function (safely) { - switch (this._tag) { - case 'audio': - case 'form': - case 'iframe': - case 'img': - case 'link': - case 'object': - case 'source': - case 'video': - var listeners = this._wrapperState.listeners; - if (listeners) { - for (var i = 0; i < listeners.length; i++) { - listeners[i].remove(); - } - } - break; - case 'input': - case 'textarea': - inputValueTracking.stopTracking(this); - break; - case 'html': - case 'head': - case 'body': - /** - * Components like <html> <head> and <body> can't be removed or added - * easily in a cross-browser way, however it's valuable to be able to - * take advantage of React's reconciliation for styling and <title> - * management. So we just document it and throw in dangerous cases. - */ - true ? process.env.NODE_ENV !== 'production' ? invariant(false, '<%s> tried to unmount. Because of cross-browser quirks it is impossible to unmount some top-level components (eg <html>, <head>, and <body>) reliably and efficiently. To fix this, have a single top-level component that never unmounts render these elements.', this._tag) : _prodInvariant('66', this._tag) : void 0; - break; - } + function crypto_secretbox_easy(message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_secretbox_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_secretbox_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output cipher (buf) + + var cipher_length = (message_length + libsodium._crypto_secretbox_macbytes()) | 0, + cipher = new AllocatedBuf(cipher_length), + cipher_address = cipher.address; + + address_pool.push(cipher_address); + + if ((libsodium._crypto_secretbox_easy(cipher_address, message_address, message_length, 0, nonce_address, key_address) | 0) === 0) { + var ret = _format_output(cipher, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - this.unmountChildren(safely); - ReactDOMComponentTree.uncacheNode(this); - EventPluginHub.deleteAllListeners(this); - this._rootNodeID = 0; - this._domID = 0; - this._wrapperState = null; + function crypto_secretbox_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_secretbox_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_secretbox_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, null); - } - }, + function crypto_secretbox_open_detached(ciphertext, mac, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: mac (buf) + + mac = _any_to_Uint8Array(address_pool, mac, "mac"); + var mac_address, mac_length = (libsodium._crypto_secretbox_macbytes()) | 0; + if (mac.length !== mac_length) { + _free_and_throw_type_error(address_pool, "invalid mac length"); + } + mac_address = _to_allocated_buf_address(mac); + address_pool.push(mac_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_secretbox_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_secretbox_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_secretbox_open_detached(message_address, ciphertext_address, mac_address, ciphertext_length, 0, nonce_address, key_address) | 0) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - getPublicInstance: function () { - return getNode(this); - } -}; + function crypto_secretbox_open_easy(ciphertext, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: ciphertext (unsized_buf) + + ciphertext = _any_to_Uint8Array(address_pool, ciphertext, "ciphertext"); + var ciphertext_address = _to_allocated_buf_address(ciphertext), + ciphertext_length = ciphertext.length; + address_pool.push(ciphertext_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_secretbox_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_secretbox_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output message (buf) + + var message_length = (ciphertext_length - libsodium._crypto_secretbox_macbytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_secretbox_open_easy(message_address, ciphertext_address, ciphertext_length, 0, nonce_address, key_address) | 0) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -_assign(ReactDOMComponent.prototype, ReactDOMComponent.Mixin, ReactMultiChild.Mixin); + function crypto_shorthash(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_shorthash_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_shorthash_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_shorthash(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -module.exports = ReactDOMComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + function crypto_shorthash_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_shorthash_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_shorthash_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } -/***/ }), -/* 160 */ -/***/ (function(module, exports, __webpack_require__) { + function crypto_shorthash_siphashx24(message, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_shorthash_siphashx24_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output hash (buf) + + var hash_length = (libsodium._crypto_shorthash_siphashx24_bytes()) | 0, + hash = new AllocatedBuf(hash_length), + hash_address = hash.address; + + address_pool.push(hash_address); + + if ((libsodium._crypto_shorthash_siphashx24(hash_address, message_address, message_length, 0, key_address) | 0) === 0) { + var ret = _format_output(hash, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + function crypto_sign(message, privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output signature (buf) + + var signature_length = (message.length + libsodium._crypto_sign_bytes()) | 0, + signature = new AllocatedBuf(signature_length), + signature_address = signature.address; + + address_pool.push(signature_address); + + if ((libsodium._crypto_sign(signature_address, null, message_address, message_length, 0, privateKey_address) | 0) === 0) { + var ret = _format_output(signature, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + function crypto_sign_detached(message, privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output signature (buf) + + var signature_length = (libsodium._crypto_sign_bytes()) | 0, + signature = new AllocatedBuf(signature_length), + signature_address = signature.address; + + address_pool.push(signature_address); + + if ((libsodium._crypto_sign_detached(signature_address, null, message_address, message_length, 0, privateKey_address) | 0) === 0) { + var ret = _format_output(signature, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + function crypto_sign_ed25519_pk_to_curve25519(edPk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -var ReactDOMComponentTree = __webpack_require__(6); + // ---------- input: edPk (buf) + + edPk = _any_to_Uint8Array(address_pool, edPk, "edPk"); + var edPk_address, edPk_length = (libsodium._crypto_sign_publickeybytes()) | 0; + if (edPk.length !== edPk_length) { + _free_and_throw_type_error(address_pool, "invalid edPk length"); + } + edPk_address = _to_allocated_buf_address(edPk); + address_pool.push(edPk_address); + + // ---------- output cPk (buf) + + var cPk_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0, + cPk = new AllocatedBuf(cPk_length), + cPk_address = cPk.address; + + address_pool.push(cPk_address); + + if ((libsodium._crypto_sign_ed25519_pk_to_curve25519(cPk_address, edPk_address) | 0) === 0) { + var ret = _format_output(cPk, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var focusNode = __webpack_require__(91); + function crypto_sign_ed25519_sk_to_curve25519(edSk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -var AutoFocusUtils = { - focusDOMComponent: function () { - focusNode(ReactDOMComponentTree.getNodeFromInstance(this)); - } -}; + // ---------- input: edSk (buf) + + edSk = _any_to_Uint8Array(address_pool, edSk, "edSk"); + var edSk_address, edSk_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (edSk.length !== edSk_length) { + _free_and_throw_type_error(address_pool, "invalid edSk length"); + } + edSk_address = _to_allocated_buf_address(edSk); + address_pool.push(edSk_address); + + // ---------- output cSk (buf) + + var cSk_length = (libsodium._crypto_scalarmult_scalarbytes()) | 0, + cSk = new AllocatedBuf(cSk_length), + cSk_address = cSk.address; + + address_pool.push(cSk_address); + + if ((libsodium._crypto_sign_ed25519_sk_to_curve25519(cSk_address, edSk_address) | 0) === 0) { + var ret = _format_output(cSk, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -module.exports = AutoFocusUtils; + function crypto_sign_ed25519_sk_to_pk(privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -/***/ }), -/* 161 */ -/***/ (function(module, exports, __webpack_require__) { + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + if ((libsodium._crypto_sign_ed25519_sk_to_pk(publicKey_address, privateKey_address) | 0) === 0) { + var ret = _format_output(publicKey, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + function crypto_sign_ed25519_sk_to_seed(privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output seed (buf) + + var seed_length = (libsodium._crypto_sign_seedbytes()) | 0, + seed = new AllocatedBuf(seed_length), + seed_address = seed.address; + + address_pool.push(seed_address); + + if ((libsodium._crypto_sign_ed25519_sk_to_seed(seed_address, privateKey_address) | 0) === 0) { + var ret = _format_output(seed, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_sign_final_create(state_address, privateKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (sign_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: privateKey (buf) + + privateKey = _any_to_Uint8Array(address_pool, privateKey, "privateKey"); + var privateKey_address, privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0; + if (privateKey.length !== privateKey_length) { + _free_and_throw_type_error(address_pool, "invalid privateKey length"); + } + privateKey_address = _to_allocated_buf_address(privateKey); + address_pool.push(privateKey_address); + + // ---------- output signature (buf) + + var signature_length = (libsodium._crypto_sign_bytes()) | 0, + signature = new AllocatedBuf(signature_length), + signature_address = signature.address; + + address_pool.push(signature_address); + + if ((libsodium._crypto_sign_final_create(state_address, signature_address, null, privateKey_address) | 0) === 0) { + var ret = (libsodium._free(state_address), _format_output(signature, outputFormat)); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_sign_final_verify(state_address, signature, publicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (sign_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: signature (buf) + + signature = _any_to_Uint8Array(address_pool, signature, "signature"); + var signature_address, signature_length = (libsodium._crypto_sign_bytes()) | 0; + if (signature.length !== signature_length) { + _free_and_throw_type_error(address_pool, "invalid signature length"); + } + signature_address = _to_allocated_buf_address(signature); + address_pool.push(signature_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + var verificationResult = libsodium._crypto_sign_final_verify(state_address, signature_address, publicKey_address) | 0; + var ret = (verificationResult === 0); + _free_all(address_pool); + return ret; + + } + + function crypto_sign_init(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output state (sign_state) + + var state_address = new AllocatedBuf(208).address; + + if ((libsodium._crypto_sign_init(state_address) | 0) === 0) { + var ret = state_address; + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_sign_keypair(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_sign_keypair(publicKey_address, privateKey_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey, keyType: 'ed25519'}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_sign_open(signedMessage, publicKey, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: signedMessage (unsized_buf) + + signedMessage = _any_to_Uint8Array(address_pool, signedMessage, "signedMessage"); + var signedMessage_address = _to_allocated_buf_address(signedMessage), + signedMessage_length = signedMessage.length; + address_pool.push(signedMessage_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + // ---------- output message (buf) + + var message_length = (signedMessage_length - libsodium._crypto_sign_bytes()) | 0, + message = new AllocatedBuf(message_length), + message_address = message.address; + + address_pool.push(message_address); + + if ((libsodium._crypto_sign_open(message_address, null, signedMessage_address, signedMessage_length, 0, publicKey_address) | 0) === 0) { + var ret = _format_output(message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + + function crypto_sign_seed_keypair(seed, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + // ---------- input: seed (buf) + + seed = _any_to_Uint8Array(address_pool, seed, "seed"); + var seed_address, seed_length = (libsodium._crypto_sign_seedbytes()) | 0; + if (seed.length !== seed_length) { + _free_and_throw_type_error(address_pool, "invalid seed length"); + } + seed_address = _to_allocated_buf_address(seed); + address_pool.push(seed_address); + + // ---------- output publicKey (buf) + + var publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0, + publicKey = new AllocatedBuf(publicKey_length), + publicKey_address = publicKey.address; + + address_pool.push(publicKey_address); + + // ---------- output privateKey (buf) + + var privateKey_length = (libsodium._crypto_sign_secretkeybytes()) | 0, + privateKey = new AllocatedBuf(privateKey_length), + privateKey_address = privateKey.address; + + address_pool.push(privateKey_address); + + if ((libsodium._crypto_sign_seed_keypair(publicKey_address, privateKey_address, seed_address) | 0) === 0) { + var ret = _format_output({publicKey: publicKey, privateKey: privateKey, keyType: "ed25519"}, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } + function crypto_sign_update(state_address, message_chunk, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: state_address (sign_state_address) + + _require_defined(address_pool, state_address, "state_address"); + + // ---------- input: message_chunk (unsized_buf) + + message_chunk = _any_to_Uint8Array(address_pool, message_chunk, "message_chunk"); + var message_chunk_address = _to_allocated_buf_address(message_chunk), + message_chunk_length = message_chunk.length; + address_pool.push(message_chunk_address); + + if ((libsodium._crypto_sign_update(state_address, message_chunk_address, message_chunk_length) | 0) === 0) { + _free_all(address_pool); + return; + } + _free_and_throw_error(address_pool); + + } -var CSSProperty = __webpack_require__(92); -var ExecutionEnvironment = __webpack_require__(8); -var ReactInstrumentation = __webpack_require__(13); + function crypto_sign_verify_detached(signature, message, publicKey) { + var address_pool = []; -var camelizeStyleName = __webpack_require__(162); -var dangerousStyleValue = __webpack_require__(164); -var hyphenateStyleName = __webpack_require__(165); -var memoizeStringOnly = __webpack_require__(167); -var warning = __webpack_require__(2); + // ---------- input: signature (buf) + + signature = _any_to_Uint8Array(address_pool, signature, "signature"); + var signature_address, signature_length = (libsodium._crypto_sign_bytes()) | 0; + if (signature.length !== signature_length) { + _free_and_throw_type_error(address_pool, "invalid signature length"); + } + signature_address = _to_allocated_buf_address(signature); + address_pool.push(signature_address); + + // ---------- input: message (unsized_buf) + + message = _any_to_Uint8Array(address_pool, message, "message"); + var message_address = _to_allocated_buf_address(message), + message_length = message.length; + address_pool.push(message_address); + + // ---------- input: publicKey (buf) + + publicKey = _any_to_Uint8Array(address_pool, publicKey, "publicKey"); + var publicKey_address, publicKey_length = (libsodium._crypto_sign_publickeybytes()) | 0; + if (publicKey.length !== publicKey_length) { + _free_and_throw_type_error(address_pool, "invalid publicKey length"); + } + publicKey_address = _to_allocated_buf_address(publicKey); + address_pool.push(publicKey_address); + + var verificationResult = libsodium._crypto_sign_verify_detached(signature_address, message_address, message_length, 0, publicKey_address) | 0; + var ret = (verificationResult === 0); + _free_all(address_pool); + return ret; + + } -var processStyleName = memoizeStringOnly(function (styleName) { - return hyphenateStyleName(styleName); -}); + function crypto_stream_chacha20_ietf_xor(input_message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_chacha20_ietf_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_chacha20_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_chacha20_ietf_xor(output_message_address, input_message_address, input_message_length, 0, nonce_address, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -var hasShorthandPropertyBug = false; -var styleFloatAccessor = 'cssFloat'; -if (ExecutionEnvironment.canUseDOM) { - var tempStyle = document.createElement('div').style; - try { - // IE8 throws "Invalid argument." if resetting shorthand style properties. - tempStyle.font = ''; - } catch (e) { - hasShorthandPropertyBug = true; - } - // IE8 only supports accessing cssFloat (standard) as styleFloat - if (document.documentElement.style.cssFloat === undefined) { - styleFloatAccessor = 'styleFloat'; - } -} + function crypto_stream_chacha20_ietf_xor_ic(input_message, nonce, nonce_increment, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_chacha20_ietf_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: nonce_increment (uint) + + _require_defined(address_pool, nonce_increment, "nonce_increment"); + + if (!(typeof nonce_increment === "number" && (nonce_increment | 0) === nonce_increment) && (nonce_increment | 0) > 0) { + _free_and_throw_type_error(address_pool, "nonce_increment must be an unsigned integer"); + } + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_chacha20_ietf_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_chacha20_ietf_xor_ic(output_message_address, input_message_address, input_message_length, 0, nonce_address, nonce_increment, 0, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } -if (process.env.NODE_ENV !== 'production') { - // 'msTransform' is correct, but the other prefixes should be capitalized - var badVendoredStyleNamePattern = /^(?:webkit|moz|o)[A-Z]/; + function crypto_stream_chacha20_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_stream_chacha20_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_stream_chacha20_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - // style values shouldn't contain a semicolon - var badStyleValueWithSemicolonPattern = /;\s*$/; + function crypto_stream_chacha20_xor(input_message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_chacha20_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_chacha20_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_chacha20_xor(output_message_address, input_message_address, input_message_length, 0, nonce_address, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - var warnedStyleNames = {}; - var warnedStyleValues = {}; - var warnedForNaNValue = false; + function crypto_stream_chacha20_xor_ic(input_message, nonce, nonce_increment, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_chacha20_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: nonce_increment (uint) + + _require_defined(address_pool, nonce_increment, "nonce_increment"); + + if (!(typeof nonce_increment === "number" && (nonce_increment | 0) === nonce_increment) && (nonce_increment | 0) > 0) { + _free_and_throw_type_error(address_pool, "nonce_increment must be an unsigned integer"); + } + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_chacha20_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_chacha20_xor_ic(output_message_address, input_message_address, input_message_length, 0, nonce_address, nonce_increment, 0, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - var warnHyphenatedStyleName = function (name, owner) { - if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { - return; - } + function crypto_stream_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_stream_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_stream_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - warnedStyleNames[name] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported style property %s. Did you mean %s?%s', name, camelizeStyleName(name), checkRenderMessage(owner)) : void 0; - }; + function crypto_stream_xchacha20_keygen(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- output output (buf) + + var output_length = (libsodium._crypto_stream_xchacha20_keybytes()) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._crypto_stream_xchacha20_keygen(output_address); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - var warnBadVendoredStyleName = function (name, owner) { - if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { - return; - } + function crypto_stream_xchacha20_xor(input_message, nonce, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_xchacha20_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_xchacha20_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_xchacha20_xor(output_message_address, input_message_address, input_message_length, 0, nonce_address, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - warnedStyleNames[name] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported vendor-prefixed style property %s. Did you mean %s?%s', name, name.charAt(0).toUpperCase() + name.slice(1), checkRenderMessage(owner)) : void 0; - }; + function crypto_stream_xchacha20_xor_ic(input_message, nonce, nonce_increment, key, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: input_message (unsized_buf) + + input_message = _any_to_Uint8Array(address_pool, input_message, "input_message"); + var input_message_address = _to_allocated_buf_address(input_message), + input_message_length = input_message.length; + address_pool.push(input_message_address); + + // ---------- input: nonce (buf) + + nonce = _any_to_Uint8Array(address_pool, nonce, "nonce"); + var nonce_address, nonce_length = (libsodium._crypto_stream_xchacha20_noncebytes()) | 0; + if (nonce.length !== nonce_length) { + _free_and_throw_type_error(address_pool, "invalid nonce length"); + } + nonce_address = _to_allocated_buf_address(nonce); + address_pool.push(nonce_address); + + // ---------- input: nonce_increment (uint) + + _require_defined(address_pool, nonce_increment, "nonce_increment"); + + if (!(typeof nonce_increment === "number" && (nonce_increment | 0) === nonce_increment) && (nonce_increment | 0) > 0) { + _free_and_throw_type_error(address_pool, "nonce_increment must be an unsigned integer"); + } + + // ---------- input: key (buf) + + key = _any_to_Uint8Array(address_pool, key, "key"); + var key_address, key_length = (libsodium._crypto_stream_xchacha20_keybytes()) | 0; + if (key.length !== key_length) { + _free_and_throw_type_error(address_pool, "invalid key length"); + } + key_address = _to_allocated_buf_address(key); + address_pool.push(key_address); + + // ---------- output output_message (buf) + + var output_message_length = (input_message_length) | 0, + output_message = new AllocatedBuf(output_message_length), + output_message_address = output_message.address; + + address_pool.push(output_message_address); + + if ((libsodium._crypto_stream_xchacha20_xor_ic(output_message_address, input_message_address, input_message_length, 0, nonce_address, nonce_increment, 0, key_address)) === 0) { + var ret = _format_output(output_message, outputFormat); + _free_all(address_pool); + return ret; + } + _free_and_throw_error(address_pool); + + } - var warnStyleValueWithSemicolon = function (name, value, owner) { - if (warnedStyleValues.hasOwnProperty(value) && warnedStyleValues[value]) { - return; - } + function randombytes_buf(length, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - warnedStyleValues[value] = true; - process.env.NODE_ENV !== 'production' ? warning(false, "Style property values shouldn't contain a semicolon.%s " + 'Try "%s: %s" instead.', checkRenderMessage(owner), name, value.replace(badStyleValueWithSemicolonPattern, '')) : void 0; - }; + // ---------- input: length (uint) + + _require_defined(address_pool, length, "length"); + + if (!(typeof length === "number" && (length | 0) === length) && (length | 0) > 0) { + _free_and_throw_type_error(address_pool, "length must be an unsigned integer"); + } + + // ---------- output output (buf) + + var output_length = (length) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._randombytes_buf(output_address, length); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - var warnStyleValueIsNaN = function (name, value, owner) { - if (warnedForNaNValue) { - return; - } + function randombytes_buf_deterministic(length, seed, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - warnedForNaNValue = true; - process.env.NODE_ENV !== 'production' ? warning(false, '`NaN` is an invalid value for the `%s` css style property.%s', name, checkRenderMessage(owner)) : void 0; - }; + // ---------- input: length (uint) + + _require_defined(address_pool, length, "length"); + + if (!(typeof length === "number" && (length | 0) === length) && (length | 0) > 0) { + _free_and_throw_type_error(address_pool, "length must be an unsigned integer"); + } + + // ---------- input: seed (buf) + + seed = _any_to_Uint8Array(address_pool, seed, "seed"); + var seed_address, seed_length = (libsodium._randombytes_seedbytes()) | 0; + if (seed.length !== seed_length) { + _free_and_throw_type_error(address_pool, "invalid seed length"); + } + seed_address = _to_allocated_buf_address(seed); + address_pool.push(seed_address); + + // ---------- output output (buf) + + var output_length = (length) | 0, + output = new AllocatedBuf(output_length), + output_address = output.address; + + address_pool.push(output_address); + + libsodium._randombytes_buf_deterministic(output_address, length, 0, seed); + var ret = (_format_output(output, outputFormat)); + _free_all(address_pool); + return ret; + + } - var checkRenderMessage = function (owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; - }; + function randombytes_close(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); - /** - * @param {string} name - * @param {*} value - * @param {ReactDOMComponent} component - */ - var warnValidStyle = function (name, value, component) { - var owner; - if (component) { - owner = component._currentElement._owner; - } - if (name.indexOf('-') > -1) { - warnHyphenatedStyleName(name, owner); - } else if (badVendoredStyleNamePattern.test(name)) { - warnBadVendoredStyleName(name, owner); - } else if (badStyleValueWithSemicolonPattern.test(value)) { - warnStyleValueWithSemicolon(name, value, owner); - } + libsodium._randombytes_close(); + + } - if (typeof value === 'number' && isNaN(value)) { - warnStyleValueIsNaN(name, value, owner); - } - }; -} + function randombytes_random(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -/** - * Operations for dealing with CSS properties. - */ -var CSSPropertyOperations = { - /** - * Serializes a mapping of style properties for use as inline styles: - * - * > createMarkupForStyles({width: '200px', height: 0}) - * "width:200px;height:0;" - * - * Undefined values are ignored so that declarative programming is easier. - * The result should be HTML-escaped before insertion into the DOM. - * - * @param {object} styles - * @param {ReactDOMComponent} component - * @return {?string} - */ - createMarkupForStyles: function (styles, component) { - var serialized = ''; - for (var styleName in styles) { - if (!styles.hasOwnProperty(styleName)) { - continue; - } - var isCustomProperty = styleName.indexOf('--') === 0; - var styleValue = styles[styleName]; - if (process.env.NODE_ENV !== 'production') { - if (!isCustomProperty) { - warnValidStyle(styleName, styleValue, component); - } - } - if (styleValue != null) { - serialized += processStyleName(styleName) + ':'; - serialized += dangerousStyleValue(styleName, styleValue, component, isCustomProperty) + ';'; - } - } - return serialized || null; - }, + var random_value = libsodium._randombytes_random() >>> 0; + var ret = (random_value); + _free_all(address_pool); + return ret; + + } - /** - * Sets the value for multiple styles on a node. If a value is specified as - * '' (empty string), the corresponding style property will be unset. - * - * @param {DOMElement} node - * @param {object} styles - * @param {ReactDOMComponent} component - */ - setValueForStyles: function (node, styles, component) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: component._debugID, - type: 'update styles', - payload: styles - }); - } + function randombytes_set_implementation(implementation, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); + + // ---------- input: implementation (randombytes_implementation) + + var implementation_address = libsodium._malloc(6 * 4); + for (var i = 0; i < 6; i++) { + libsodium.setValue(implementation_address + i * 4, + libsodium.Runtime.addFunction(implementation + [["implementation_name", "random", "stir", "uniform", "buf", "close"][i]]), + "i32"); + } + + if ((libsodium._randombytes_set_implementation(implementation_address) | 0) === 0) { + _free_all(address_pool); + return; + } + _free_and_throw_error(address_pool); + + } - var style = node.style; - for (var styleName in styles) { - if (!styles.hasOwnProperty(styleName)) { - continue; - } - var isCustomProperty = styleName.indexOf('--') === 0; - if (process.env.NODE_ENV !== 'production') { - if (!isCustomProperty) { - warnValidStyle(styleName, styles[styleName], component); - } - } - var styleValue = dangerousStyleValue(styleName, styles[styleName], component, isCustomProperty); - if (styleName === 'float' || styleName === 'cssFloat') { - styleName = styleFloatAccessor; - } - if (isCustomProperty) { - style.setProperty(styleName, styleValue); - } else if (styleValue) { - style[styleName] = styleValue; - } else { - var expansion = hasShorthandPropertyBug && CSSProperty.shorthandPropertyExpansions[styleName]; - if (expansion) { - // Shorthand property that IE8 won't like unsetting, so unset each - // component to placate it - for (var individualStyleName in expansion) { - style[individualStyleName] = ''; - } - } else { - style[styleName] = ''; - } - } - } - } -}; + function randombytes_stir(outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -module.exports = CSSPropertyOperations; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + libsodium._randombytes_stir(); + + } -/***/ }), -/* 162 */ -/***/ (function(module, exports, __webpack_require__) { + function randombytes_uniform(upper_bound, outputFormat) { + var address_pool = []; + _check_output_format(outputFormat); -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + // ---------- input: upper_bound (uint) + + _require_defined(address_pool, upper_bound, "upper_bound"); + + if (!(typeof upper_bound === "number" && (upper_bound | 0) === upper_bound) && (upper_bound | 0) > 0) { + _free_and_throw_type_error(address_pool, "upper_bound must be an unsigned integer"); + } + + var random_value = libsodium._randombytes_uniform(upper_bound) >>> 0; + var ret = (random_value); + _free_all(address_pool); + return ret; + + } + function sodium_version_string() { + var address_pool = []; + var version = libsodium._sodium_version_string(); + var ret = (libsodium.Pointer_stringify(version)); + _free_all(address_pool); + return ret; + + } -var camelize = __webpack_require__(163); -var msPattern = /^-ms-/; + exports.add = add; + exports.compare = compare; + exports.from_base64 = from_base64; + exports.from_hex = from_hex; + exports.from_string = from_string; + exports.increment = increment; + exports.is_zero = is_zero; + exports.libsodium = libsodium; + exports.memcmp = memcmp; + exports.memzero = memzero; + exports.output_formats = output_formats; + exports.symbols = symbols; + exports.to_base64 = to_base64; + exports.to_hex = to_hex; + exports.to_string = to_string; + + + var exported_functions = ["crypto_aead_chacha20poly1305_decrypt", "crypto_aead_chacha20poly1305_decrypt_detached", "crypto_aead_chacha20poly1305_encrypt", "crypto_aead_chacha20poly1305_encrypt_detached", "crypto_aead_chacha20poly1305_ietf_decrypt", "crypto_aead_chacha20poly1305_ietf_decrypt_detached", "crypto_aead_chacha20poly1305_ietf_encrypt", "crypto_aead_chacha20poly1305_ietf_encrypt_detached", "crypto_aead_chacha20poly1305_ietf_keygen", "crypto_aead_chacha20poly1305_keygen", "crypto_aead_xchacha20poly1305_ietf_decrypt", "crypto_aead_xchacha20poly1305_ietf_decrypt_detached", "crypto_aead_xchacha20poly1305_ietf_encrypt", "crypto_aead_xchacha20poly1305_ietf_encrypt_detached", "crypto_aead_xchacha20poly1305_ietf_keygen", "crypto_auth", "crypto_auth_hmacsha256", "crypto_auth_hmacsha256_keygen", "crypto_auth_hmacsha256_verify", "crypto_auth_hmacsha512", "crypto_auth_hmacsha512_keygen", "crypto_auth_hmacsha512_verify", "crypto_auth_keygen", "crypto_auth_verify", "crypto_box_beforenm", "crypto_box_detached", "crypto_box_easy", "crypto_box_easy_afternm", "crypto_box_keypair", "crypto_box_open_detached", "crypto_box_open_easy", "crypto_box_open_easy_afternm", "crypto_box_seal", "crypto_box_seal_open", "crypto_box_seed_keypair", "crypto_generichash", "crypto_generichash_final", "crypto_generichash_init", "crypto_generichash_keygen", "crypto_generichash_update", "crypto_hash", "crypto_hash_sha256", "crypto_hash_sha512", "crypto_kdf_derive_from_key", "crypto_kdf_keygen", "crypto_kx_client_session_keys", "crypto_kx_keypair", "crypto_kx_seed_keypair", "crypto_kx_server_session_keys", "crypto_onetimeauth", "crypto_onetimeauth_final", "crypto_onetimeauth_init", "crypto_onetimeauth_keygen", "crypto_onetimeauth_update", "crypto_onetimeauth_verify", "crypto_pwhash", "crypto_pwhash_scryptsalsa208sha256", "crypto_pwhash_scryptsalsa208sha256_ll", "crypto_pwhash_scryptsalsa208sha256_str", "crypto_pwhash_scryptsalsa208sha256_str_verify", "crypto_pwhash_str", "crypto_pwhash_str_verify", "crypto_scalarmult", "crypto_scalarmult_base", "crypto_secretbox_detached", "crypto_secretbox_easy", "crypto_secretbox_keygen", "crypto_secretbox_open_detached", "crypto_secretbox_open_easy", "crypto_shorthash", "crypto_shorthash_keygen", "crypto_shorthash_siphashx24", "crypto_sign", "crypto_sign_detached", "crypto_sign_ed25519_pk_to_curve25519", "crypto_sign_ed25519_sk_to_curve25519", "crypto_sign_ed25519_sk_to_pk", "crypto_sign_ed25519_sk_to_seed", "crypto_sign_final_create", "crypto_sign_final_verify", "crypto_sign_init", "crypto_sign_keypair", "crypto_sign_open", "crypto_sign_seed_keypair", "crypto_sign_update", "crypto_sign_verify_detached", "crypto_stream_chacha20_ietf_xor", "crypto_stream_chacha20_ietf_xor_ic", "crypto_stream_chacha20_keygen", "crypto_stream_chacha20_xor", "crypto_stream_chacha20_xor_ic", "crypto_stream_keygen", "crypto_stream_xchacha20_keygen", "crypto_stream_xchacha20_xor", "crypto_stream_xchacha20_xor_ic", "randombytes_buf", "randombytes_buf_deterministic", "randombytes_close", "randombytes_random", "randombytes_set_implementation", "randombytes_stir", "randombytes_uniform", "sodium_version_string"], + functions = [crypto_aead_chacha20poly1305_decrypt, crypto_aead_chacha20poly1305_decrypt_detached, crypto_aead_chacha20poly1305_encrypt, crypto_aead_chacha20poly1305_encrypt_detached, crypto_aead_chacha20poly1305_ietf_decrypt, crypto_aead_chacha20poly1305_ietf_decrypt_detached, crypto_aead_chacha20poly1305_ietf_encrypt, crypto_aead_chacha20poly1305_ietf_encrypt_detached, crypto_aead_chacha20poly1305_ietf_keygen, crypto_aead_chacha20poly1305_keygen, crypto_aead_xchacha20poly1305_ietf_decrypt, crypto_aead_xchacha20poly1305_ietf_decrypt_detached, crypto_aead_xchacha20poly1305_ietf_encrypt, crypto_aead_xchacha20poly1305_ietf_encrypt_detached, crypto_aead_xchacha20poly1305_ietf_keygen, crypto_auth, crypto_auth_hmacsha256, crypto_auth_hmacsha256_keygen, crypto_auth_hmacsha256_verify, crypto_auth_hmacsha512, crypto_auth_hmacsha512_keygen, crypto_auth_hmacsha512_verify, crypto_auth_keygen, crypto_auth_verify, crypto_box_beforenm, crypto_box_detached, crypto_box_easy, crypto_box_easy_afternm, crypto_box_keypair, crypto_box_open_detached, crypto_box_open_easy, crypto_box_open_easy_afternm, crypto_box_seal, crypto_box_seal_open, crypto_box_seed_keypair, crypto_generichash, crypto_generichash_final, crypto_generichash_init, crypto_generichash_keygen, crypto_generichash_update, crypto_hash, crypto_hash_sha256, crypto_hash_sha512, crypto_kdf_derive_from_key, crypto_kdf_keygen, crypto_kx_client_session_keys, crypto_kx_keypair, crypto_kx_seed_keypair, crypto_kx_server_session_keys, crypto_onetimeauth, crypto_onetimeauth_final, crypto_onetimeauth_init, crypto_onetimeauth_keygen, crypto_onetimeauth_update, crypto_onetimeauth_verify, crypto_pwhash, crypto_pwhash_scryptsalsa208sha256, crypto_pwhash_scryptsalsa208sha256_ll, crypto_pwhash_scryptsalsa208sha256_str, crypto_pwhash_scryptsalsa208sha256_str_verify, crypto_pwhash_str, crypto_pwhash_str_verify, crypto_scalarmult, crypto_scalarmult_base, crypto_secretbox_detached, crypto_secretbox_easy, crypto_secretbox_keygen, crypto_secretbox_open_detached, crypto_secretbox_open_easy, crypto_shorthash, crypto_shorthash_keygen, crypto_shorthash_siphashx24, crypto_sign, crypto_sign_detached, crypto_sign_ed25519_pk_to_curve25519, crypto_sign_ed25519_sk_to_curve25519, crypto_sign_ed25519_sk_to_pk, crypto_sign_ed25519_sk_to_seed, crypto_sign_final_create, crypto_sign_final_verify, crypto_sign_init, crypto_sign_keypair, crypto_sign_open, crypto_sign_seed_keypair, crypto_sign_update, crypto_sign_verify_detached, crypto_stream_chacha20_ietf_xor, crypto_stream_chacha20_ietf_xor_ic, crypto_stream_chacha20_keygen, crypto_stream_chacha20_xor, crypto_stream_chacha20_xor_ic, crypto_stream_keygen, crypto_stream_xchacha20_keygen, crypto_stream_xchacha20_xor, crypto_stream_xchacha20_xor_ic, randombytes_buf, randombytes_buf_deterministic, randombytes_close, randombytes_random, randombytes_set_implementation, randombytes_stir, randombytes_uniform, sodium_version_string]; + for (var i = 0; i < functions.length; i++) { + if (typeof libsodium["_" + exported_functions[i]] === "function") { + exports[exported_functions[i]] = functions[i]; + } + } + var constants = ["SODIUM_LIBRARY_VERSION_MAJOR", "SODIUM_LIBRARY_VERSION_MINOR", "crypto_aead_chacha20poly1305_ABYTES", "crypto_aead_chacha20poly1305_KEYBYTES", "crypto_aead_chacha20poly1305_NPUBBYTES", "crypto_aead_chacha20poly1305_NSECBYTES", "crypto_aead_chacha20poly1305_ietf_ABYTES", "crypto_aead_chacha20poly1305_ietf_KEYBYTES", "crypto_aead_chacha20poly1305_ietf_NPUBBYTES", "crypto_aead_chacha20poly1305_ietf_NSECBYTES", "crypto_aead_xchacha20poly1305_ietf_ABYTES", "crypto_aead_xchacha20poly1305_ietf_KEYBYTES", "crypto_aead_xchacha20poly1305_ietf_NPUBBYTES", "crypto_aead_xchacha20poly1305_ietf_NSECBYTES", "crypto_auth_BYTES", "crypto_auth_KEYBYTES", "crypto_auth_hmacsha256_BYTES", "crypto_auth_hmacsha256_KEYBYTES", "crypto_auth_hmacsha512_BYTES", "crypto_auth_hmacsha512_KEYBYTES", "crypto_box_BEFORENMBYTES", "crypto_box_MACBYTES", "crypto_box_NONCEBYTES", "crypto_box_PUBLICKEYBYTES", "crypto_box_SEALBYTES", "crypto_box_SECRETKEYBYTES", "crypto_box_SEEDBYTES", "crypto_generichash_BYTES", "crypto_generichash_BYTES_MAX", "crypto_generichash_BYTES_MIN", "crypto_generichash_KEYBYTES", "crypto_generichash_KEYBYTES_MAX", "crypto_generichash_KEYBYTES_MIN", "crypto_hash_BYTES", "crypto_kdf_BYTES_MAX", "crypto_kdf_BYTES_MIN", "crypto_kdf_CONTEXTBYTES", "crypto_kdf_KEYBYTES", "crypto_kx_PUBLICKEYBYTES", "crypto_kx_SECRETKEYBYTES", "crypto_kx_SEEDBYTES", "crypto_kx_SESSSIONKEYBYTES", "crypto_onetimeauth_BYTES", "crypto_onetimeauth_KEYBYTES", "crypto_pwhash_ALG_ARGON2I13", "crypto_pwhash_ALG_DEFAULT", "crypto_pwhash_BYTES_MAX", "crypto_pwhash_BYTES_MIN", "crypto_pwhash_MEMLIMIT_INTERACTIVE", "crypto_pwhash_MEMLIMIT_MAX", "crypto_pwhash_MEMLIMIT_MIN", "crypto_pwhash_MEMLIMIT_MODERATE", "crypto_pwhash_MEMLIMIT_SENSITIVE", "crypto_pwhash_OPSLIMIT_INTERACTIVE", "crypto_pwhash_OPSLIMIT_MAX", "crypto_pwhash_OPSLIMIT_MIN", "crypto_pwhash_OPSLIMIT_MODERATE", "crypto_pwhash_OPSLIMIT_SENSITIVE", "crypto_pwhash_PASSWD_MAX", "crypto_pwhash_PASSWD_MIN", "crypto_pwhash_SALTBYTES", "crypto_pwhash_STRBYTES", "crypto_pwhash_STR_VERIFY", "crypto_pwhash_scryptsalsa208sha256_BYTES_MAX", "crypto_pwhash_scryptsalsa208sha256_BYTES_MIN", "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_INTERACTIVE", "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_MAX", "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_MIN", "crypto_pwhash_scryptsalsa208sha256_MEMLIMIT_SENSITIVE", "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_INTERACTIVE", "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_MAX", "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_MIN", "crypto_pwhash_scryptsalsa208sha256_OPSLIMIT_SENSITIVE", "crypto_pwhash_scryptsalsa208sha256_SALTBYTES", "crypto_pwhash_scryptsalsa208sha256_STRBYTES", "crypto_pwhash_scryptsalsa208sha256_STR_VERIFY", "crypto_scalarmult_BYTES", "crypto_scalarmult_SCALARBYTES", "crypto_secretbox_KEYBYTES", "crypto_secretbox_MACBYTES", "crypto_secretbox_NONCEBYTES", "crypto_shorthash_BYTES", "crypto_shorthash_KEYBYTES", "crypto_shorthash_siphashx24_BYTES", "crypto_shorthash_siphashx24_KEYBYTES", "crypto_sign_BYTES", "crypto_sign_PUBLICKEYBYTES", "crypto_sign_SECRETKEYBYTES", "crypto_sign_SEEDBYTES", "crypto_stream_chacha20_KEYBYTES", "crypto_stream_chacha20_NONCEBYTES", "crypto_stream_chacha20_ietf_KEYBYTES", "crypto_stream_chacha20_ietf_NONCEBYTES", "crypto_stream_xchacha20_ietf_KEYBYTES", "crypto_stream_xchacha20_ietf_NONCEBYTES", "randombytes_SEEDBYTES"]; + for (var i = 0; i < constants.length; i++) { + var raw = libsodium["_" + constants[i].toLowerCase()]; + if (typeof raw === "function") exports[constants[i]] = raw()|0; + } + var constants_str = ["SODIUM_VERSION_STRING", "crypto_pwhash_STRPREFIX", "crypto_pwhash_scryptsalsa208sha256_STRPREFIX"]; + for (var i = 0; i < constants_str.length; i++) { + var raw = libsodium["_" + constants_str[i].toLowerCase()]; + if (typeof raw === "function") exports[constants_str[i]] = libsodium.Pointer_stringify(raw()); + } -/** - * Camelcases a hyphenated CSS property name, for example: - * - * > camelizeStyleName('background-color') - * < "backgroundColor" - * > camelizeStyleName('-moz-transition') - * < "MozTransition" - * > camelizeStyleName('-ms-transition') - * < "msTransition" - * - * As Andi Smith suggests - * (http://www.andismith.com/blog/2012/02/modernizr-prefixed/), an `-ms` prefix - * is converted to lowercase `ms`. - * - * @param {string} string - * @return {string} - */ -function camelizeStyleName(string) { - return camelize(string.replace(msPattern, 'ms-')); -} + return exports; +}))); -module.exports = camelizeStyleName; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 163 */ +/* 416 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; - - -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +/* WEBPACK VAR INJECTION */(function(process) {var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (root, factory) { + if (true) { + !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), + __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? + (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); + } else if (typeof exports === 'object' && + typeof exports.nodeName !== 'string') { + factory(exports); + } else { + factory(root.libsodium = {}); + } +})(this, (function (exports) { + var Module = exports; +var Module;if(!Module)Module=(typeof Module!=="undefined"?Module:null)||{};var moduleOverrides={};for(var key in Module){if(Module.hasOwnProperty(key)){moduleOverrides[key]=Module[key]}}var ENVIRONMENT_IS_WEB=false;var ENVIRONMENT_IS_WORKER=false;var ENVIRONMENT_IS_NODE=false;var ENVIRONMENT_IS_SHELL=false;if(Module["ENVIRONMENT"]){if(Module["ENVIRONMENT"]==="WEB"){ENVIRONMENT_IS_WEB=true}else if(Module["ENVIRONMENT"]==="WORKER"){ENVIRONMENT_IS_WORKER=true}else if(Module["ENVIRONMENT"]==="NODE"){ENVIRONMENT_IS_NODE=true}else if(Module["ENVIRONMENT"]==="SHELL"){ENVIRONMENT_IS_SHELL=true}else{throw new Error("The provided Module['ENVIRONMENT'] value is not valid. It must be one of: WEB|WORKER|NODE|SHELL.")}}else{ENVIRONMENT_IS_WEB=typeof window==="object";ENVIRONMENT_IS_WORKER=typeof importScripts==="function";ENVIRONMENT_IS_NODE=typeof process==="object"&&"function"==="function"&&!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_WORKER;ENVIRONMENT_IS_SHELL=!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_NODE&&!ENVIRONMENT_IS_WORKER}if(ENVIRONMENT_IS_NODE){if(!Module["print"])Module["print"]=console.log;if(!Module["printErr"])Module["printErr"]=console.warn;var nodeFS;var nodePath;Module["read"]=function shell_read(filename,binary){if(!nodeFS)nodeFS=__webpack_require__(417);if(!nodePath)nodePath=__webpack_require__(418);filename=nodePath["normalize"](filename);var ret=nodeFS["readFileSync"](filename);return binary?ret:ret.toString()};Module["readBinary"]=function readBinary(filename){var ret=Module["read"](filename,true);if(!ret.buffer){ret=new Uint8Array(ret)}assert(ret.buffer);return ret};Module["load"]=function load(f){globalEval(read(f))};if(!Module["thisProgram"]){if(process["argv"].length>1){Module["thisProgram"]=process["argv"][1].replace(/\\/g,"/")}else{Module["thisProgram"]="unknown-program"}}Module["arguments"]=process["argv"].slice(2);if(true){module["exports"]=Module}process["on"]("uncaughtException",(function(ex){if(!(ex instanceof ExitStatus)){throw ex}}));Module["inspect"]=(function(){return"[Emscripten Module object]"})}else if(ENVIRONMENT_IS_SHELL){if(!Module["print"])Module["print"]=print;if(typeof printErr!="undefined")Module["printErr"]=printErr;if(typeof read!="undefined"){Module["read"]=read}else{Module["read"]=function shell_read(){throw"no read() available"}}Module["readBinary"]=function readBinary(f){if(typeof readbuffer==="function"){return new Uint8Array(readbuffer(f))}var data=read(f,"binary");assert(typeof data==="object");return data};if(typeof scriptArgs!="undefined"){Module["arguments"]=scriptArgs}else if(typeof arguments!="undefined"){Module["arguments"]=arguments}if(typeof quit==="function"){Module["quit"]=(function(status,toThrow){quit(status)})}}else if(ENVIRONMENT_IS_WEB||ENVIRONMENT_IS_WORKER){Module["read"]=function shell_read(url){var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.send(null);return xhr.responseText};if(ENVIRONMENT_IS_WORKER){Module["readBinary"]=function readBinary(url){var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.responseType="arraybuffer";xhr.send(null);return xhr.response}}Module["readAsync"]=function readAsync(url,onload,onerror){var xhr=new XMLHttpRequest;xhr.open("GET",url,true);xhr.responseType="arraybuffer";xhr.onload=function xhr_onload(){if(xhr.status==200||xhr.status==0&&xhr.response){onload(xhr.response)}else{onerror()}};xhr.onerror=onerror;xhr.send(null)};if(typeof arguments!="undefined"){Module["arguments"]=arguments}if(typeof console!=="undefined"){if(!Module["print"])Module["print"]=function shell_print(x){console.log(x)};if(!Module["printErr"])Module["printErr"]=function shell_printErr(x){console.warn(x)}}else{var TRY_USE_DUMP=false;if(!Module["print"])Module["print"]=TRY_USE_DUMP&&typeof dump!=="undefined"?(function(x){dump(x)}):(function(x){})}if(ENVIRONMENT_IS_WORKER){Module["load"]=importScripts}if(typeof Module["setWindowTitle"]==="undefined"){Module["setWindowTitle"]=(function(title){document.title=title})}}else{throw"Unknown runtime environment. Where are we?"}function globalEval(x){abort("NO_DYNAMIC_EXECUTION=1 was set, cannot eval")}if(!Module["load"]&&Module["read"]){Module["load"]=function load(f){globalEval(Module["read"](f))}}if(!Module["print"]){Module["print"]=(function(){})}if(!Module["printErr"]){Module["printErr"]=Module["print"]}if(!Module["arguments"]){Module["arguments"]=[]}if(!Module["thisProgram"]){Module["thisProgram"]="./this.program"}if(!Module["quit"]){Module["quit"]=(function(status,toThrow){throw toThrow})}Module.print=Module["print"];Module.printErr=Module["printErr"];Module["preRun"]=[];Module["postRun"]=[];for(var key in moduleOverrides){if(moduleOverrides.hasOwnProperty(key)){Module[key]=moduleOverrides[key]}}moduleOverrides=undefined;var Runtime={setTempRet0:(function(value){tempRet0=value;return value}),getTempRet0:(function(){return tempRet0}),stackSave:(function(){return STACKTOP}),stackRestore:(function(stackTop){STACKTOP=stackTop}),getNativeTypeSize:(function(type){switch(type){case"i1":case"i8":return 1;case"i16":return 2;case"i32":return 4;case"i64":return 8;case"float":return 4;case"double":return 8;default:{if(type[type.length-1]==="*"){return Runtime.QUANTUM_SIZE}else if(type[0]==="i"){var bits=parseInt(type.substr(1));assert(bits%8===0);return bits/8}else{return 0}}}}),getNativeFieldSize:(function(type){return Math.max(Runtime.getNativeTypeSize(type),Runtime.QUANTUM_SIZE)}),STACK_ALIGN:16,prepVararg:(function(ptr,type){if(type==="double"||type==="i64"){if(ptr&7){assert((ptr&7)===4);ptr+=4}}else{assert((ptr&3)===0)}return ptr}),getAlignSize:(function(type,size,vararg){if(!vararg&&(type=="i64"||type=="double"))return 8;if(!type)return Math.min(size,8);return Math.min(size||(type?Runtime.getNativeFieldSize(type):0),Runtime.QUANTUM_SIZE)}),dynCall:(function(sig,ptr,args){if(args&&args.length){return Module["dynCall_"+sig].apply(null,[ptr].concat(args))}else{return Module["dynCall_"+sig].call(null,ptr)}}),functionPointers:[null,null,null,null,null,null,null,null],addFunction:(function(func){for(var i=0;i<Runtime.functionPointers.length;i++){if(!Runtime.functionPointers[i]){Runtime.functionPointers[i]=func;return 1*(1+i)}}throw"Finished up all reserved function pointers. Use a higher value for RESERVED_FUNCTION_POINTERS."}),removeFunction:(function(index){Runtime.functionPointers[(index-1)/1]=null}),warnOnce:(function(text){if(!Runtime.warnOnce.shown)Runtime.warnOnce.shown={};if(!Runtime.warnOnce.shown[text]){Runtime.warnOnce.shown[text]=1;Module.printErr(text)}}),funcWrappers:{},getFuncWrapper:(function(func,sig){assert(sig);if(!Runtime.funcWrappers[sig]){Runtime.funcWrappers[sig]={}}var sigCache=Runtime.funcWrappers[sig];if(!sigCache[func]){if(sig.length===1){sigCache[func]=function dynCall_wrapper(){return Runtime.dynCall(sig,func)}}else if(sig.length===2){sigCache[func]=function dynCall_wrapper(arg){return Runtime.dynCall(sig,func,[arg])}}else{sigCache[func]=function dynCall_wrapper(){return Runtime.dynCall(sig,func,Array.prototype.slice.call(arguments))}}}return sigCache[func]}),getCompilerSetting:(function(name){throw"You must build with -s RETAIN_COMPILER_SETTINGS=1 for Runtime.getCompilerSetting or emscripten_get_compiler_setting to work"}),stackAlloc:(function(size){var ret=STACKTOP;STACKTOP=STACKTOP+size|0;STACKTOP=STACKTOP+15&-16;return ret}),staticAlloc:(function(size){var ret=STATICTOP;STATICTOP=STATICTOP+size|0;STATICTOP=STATICTOP+15&-16;return ret}),dynamicAlloc:(function(size){var ret=HEAP32[DYNAMICTOP_PTR>>2];var end=(ret+size+15|0)&-16;HEAP32[DYNAMICTOP_PTR>>2]=end;if(end>=TOTAL_MEMORY){var success=enlargeMemory();if(!success){HEAP32[DYNAMICTOP_PTR>>2]=ret;return 0}}return ret}),alignMemory:(function(size,quantum){var ret=size=Math.ceil(size/(quantum?quantum:16))*(quantum?quantum:16);return ret}),makeBigInt:(function(low,high,unsigned){var ret=unsigned?+(low>>>0)+ +(high>>>0)*+4294967296:+(low>>>0)+ +(high|0)*+4294967296;return ret}),GLOBAL_BASE:8,QUANTUM_SIZE:4,__dummy__:0};Module["Runtime"]=Runtime;var ABORT=0;var EXITSTATUS=0;function assert(condition,text){if(!condition){abort("Assertion failed: "+text)}}function getCFunc(ident){var func=Module["_"+ident];if(!func){abort("NO_DYNAMIC_EXECUTION=1 was set, cannot eval")}assert(func,"Cannot call unknown function "+ident+" (perhaps LLVM optimizations or closure removed it?)");return func}var cwrap,ccall;((function(){var JSfuncs={"stackSave":(function(){Runtime.stackSave()}),"stackRestore":(function(){Runtime.stackRestore()}),"arrayToC":(function(arr){var ret=Runtime.stackAlloc(arr.length);writeArrayToMemory(arr,ret);return ret}),"stringToC":(function(str){var ret=0;if(str!==null&&str!==undefined&&str!==0){var len=(str.length<<2)+1;ret=Runtime.stackAlloc(len);stringToUTF8(str,ret,len)}return ret})};var toC={"string":JSfuncs["stringToC"],"array":JSfuncs["arrayToC"]};ccall=function ccallFunc(ident,returnType,argTypes,args,opts){var func=getCFunc(ident);var cArgs=[];var stack=0;if(args){for(var i=0;i<args.length;i++){var converter=toC[argTypes[i]];if(converter){if(stack===0)stack=Runtime.stackSave();cArgs[i]=converter(args[i])}else{cArgs[i]=args[i]}}}var ret=func.apply(null,cArgs);if(returnType==="string")ret=Pointer_stringify(ret);if(stack!==0){if(opts&&opts.async){EmterpreterAsync.asyncFinalizers.push((function(){Runtime.stackRestore(stack)}));return}Runtime.stackRestore(stack)}return ret};cwrap=function cwrap(ident,returnType,argTypes){return(function(){return ccall(ident,returnType,argTypes,arguments)})}}))();Module["ccall"]=ccall;Module["cwrap"]=cwrap;function setValue(ptr,value,type,noSafe){type=type||"i8";if(type.charAt(type.length-1)==="*")type="i32";switch(type){case"i1":HEAP8[ptr>>0]=value;break;case"i8":HEAP8[ptr>>0]=value;break;case"i16":HEAP16[ptr>>1]=value;break;case"i32":HEAP32[ptr>>2]=value;break;case"i64":tempI64=[value>>>0,(tempDouble=value,+Math_abs(tempDouble)>=+1?tempDouble>+0?(Math_min(+Math_floor(tempDouble/+4294967296),+4294967295)|0)>>>0:~~+Math_ceil((tempDouble- +(~~tempDouble>>>0))/+4294967296)>>>0:0)],HEAP32[ptr>>2]=tempI64[0],HEAP32[ptr+4>>2]=tempI64[1];break;case"float":HEAPF32[ptr>>2]=value;break;case"double":HEAPF64[ptr>>3]=value;break;default:abort("invalid type for setValue: "+type)}}Module["setValue"]=setValue;function getValue(ptr,type,noSafe){type=type||"i8";if(type.charAt(type.length-1)==="*")type="i32";switch(type){case"i1":return HEAP8[ptr>>0];case"i8":return HEAP8[ptr>>0];case"i16":return HEAP16[ptr>>1];case"i32":return HEAP32[ptr>>2];case"i64":return HEAP32[ptr>>2];case"float":return HEAPF32[ptr>>2];case"double":return HEAPF64[ptr>>3];default:abort("invalid type for setValue: "+type)}return null}Module["getValue"]=getValue;var ALLOC_NORMAL=0;var ALLOC_STACK=1;var ALLOC_STATIC=2;var ALLOC_DYNAMIC=3;var ALLOC_NONE=4;Module["ALLOC_NORMAL"]=ALLOC_NORMAL;Module["ALLOC_STACK"]=ALLOC_STACK;Module["ALLOC_STATIC"]=ALLOC_STATIC;Module["ALLOC_DYNAMIC"]=ALLOC_DYNAMIC;Module["ALLOC_NONE"]=ALLOC_NONE;function allocate(slab,types,allocator,ptr){var zeroinit,size;if(typeof slab==="number"){zeroinit=true;size=slab}else{zeroinit=false;size=slab.length}var singleType=typeof types==="string"?types:null;var ret;if(allocator==ALLOC_NONE){ret=ptr}else{ret=[typeof _malloc==="function"?_malloc:Runtime.staticAlloc,Runtime.stackAlloc,Runtime.staticAlloc,Runtime.dynamicAlloc][allocator===undefined?ALLOC_STATIC:allocator](Math.max(size,singleType?1:types.length))}if(zeroinit){var ptr=ret,stop;assert((ret&3)==0);stop=ret+(size&~3);for(;ptr<stop;ptr+=4){HEAP32[ptr>>2]=0}stop=ret+size;while(ptr<stop){HEAP8[ptr++>>0]=0}return ret}if(singleType==="i8"){if(slab.subarray||slab.slice){HEAPU8.set(slab,ret)}else{HEAPU8.set(new Uint8Array(slab),ret)}return ret}var i=0,type,typeSize,previousType;while(i<size){var curr=slab[i];if(typeof curr==="function"){curr=Runtime.getFunctionIndex(curr)}type=singleType||types[i];if(type===0){i++;continue}if(type=="i64")type="i32";setValue(ret+i,curr,type);if(previousType!==type){typeSize=Runtime.getNativeTypeSize(type);previousType=type}i+=typeSize}return ret}Module["allocate"]=allocate;function getMemory(size){if(!staticSealed)return Runtime.staticAlloc(size);if(!runtimeInitialized)return Runtime.dynamicAlloc(size);return _malloc(size)}Module["getMemory"]=getMemory;function Pointer_stringify(ptr,length){if(length===0||!ptr)return"";var hasUtf=0;var t;var i=0;while(1){t=HEAPU8[ptr+i>>0];hasUtf|=t;if(t==0&&!length)break;i++;if(length&&i==length)break}if(!length)length=i;var ret="";if(hasUtf<128){var MAX_CHUNK=1024;var curr;while(length>0){curr=String.fromCharCode.apply(String,HEAPU8.subarray(ptr,ptr+Math.min(length,MAX_CHUNK)));ret=ret?ret+curr:curr;ptr+=MAX_CHUNK;length-=MAX_CHUNK}return ret}return Module["UTF8ToString"](ptr)}Module["Pointer_stringify"]=Pointer_stringify;function AsciiToString(ptr){var str="";while(1){var ch=HEAP8[ptr++>>0];if(!ch)return str;str+=String.fromCharCode(ch)}}Module["AsciiToString"]=AsciiToString;function stringToAscii(str,outPtr){return writeAsciiToMemory(str,outPtr,false)}Module["stringToAscii"]=stringToAscii;var UTF8Decoder=typeof TextDecoder!=="undefined"?new TextDecoder("utf8"):undefined;function UTF8ArrayToString(u8Array,idx){var endPtr=idx;while(u8Array[endPtr])++endPtr;if(endPtr-idx>16&&u8Array.subarray&&UTF8Decoder){return UTF8Decoder.decode(u8Array.subarray(idx,endPtr))}else{var u0,u1,u2,u3,u4,u5;var str="";while(1){u0=u8Array[idx++];if(!u0)return str;if(!(u0&128)){str+=String.fromCharCode(u0);continue}u1=u8Array[idx++]&63;if((u0&224)==192){str+=String.fromCharCode((u0&31)<<6|u1);continue}u2=u8Array[idx++]&63;if((u0&240)==224){u0=(u0&15)<<12|u1<<6|u2}else{u3=u8Array[idx++]&63;if((u0&248)==240){u0=(u0&7)<<18|u1<<12|u2<<6|u3}else{u4=u8Array[idx++]&63;if((u0&252)==248){u0=(u0&3)<<24|u1<<18|u2<<12|u3<<6|u4}else{u5=u8Array[idx++]&63;u0=(u0&1)<<30|u1<<24|u2<<18|u3<<12|u4<<6|u5}}}if(u0<65536){str+=String.fromCharCode(u0)}else{var ch=u0-65536;str+=String.fromCharCode(55296|ch>>10,56320|ch&1023)}}}}Module["UTF8ArrayToString"]=UTF8ArrayToString;function UTF8ToString(ptr){return UTF8ArrayToString(HEAPU8,ptr)}Module["UTF8ToString"]=UTF8ToString;function stringToUTF8Array(str,outU8Array,outIdx,maxBytesToWrite){if(!(maxBytesToWrite>0))return 0;var startIdx=outIdx;var endIdx=outIdx+maxBytesToWrite-1;for(var i=0;i<str.length;++i){var u=str.charCodeAt(i);if(u>=55296&&u<=57343)u=65536+((u&1023)<<10)|str.charCodeAt(++i)&1023;if(u<=127){if(outIdx>=endIdx)break;outU8Array[outIdx++]=u}else if(u<=2047){if(outIdx+1>=endIdx)break;outU8Array[outIdx++]=192|u>>6;outU8Array[outIdx++]=128|u&63}else if(u<=65535){if(outIdx+2>=endIdx)break;outU8Array[outIdx++]=224|u>>12;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else if(u<=2097151){if(outIdx+3>=endIdx)break;outU8Array[outIdx++]=240|u>>18;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else if(u<=67108863){if(outIdx+4>=endIdx)break;outU8Array[outIdx++]=248|u>>24;outU8Array[outIdx++]=128|u>>18&63;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else{if(outIdx+5>=endIdx)break;outU8Array[outIdx++]=252|u>>30;outU8Array[outIdx++]=128|u>>24&63;outU8Array[outIdx++]=128|u>>18&63;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}}outU8Array[outIdx]=0;return outIdx-startIdx}Module["stringToUTF8Array"]=stringToUTF8Array;function stringToUTF8(str,outPtr,maxBytesToWrite){return stringToUTF8Array(str,HEAPU8,outPtr,maxBytesToWrite)}Module["stringToUTF8"]=stringToUTF8;function lengthBytesUTF8(str){var len=0;for(var i=0;i<str.length;++i){var u=str.charCodeAt(i);if(u>=55296&&u<=57343)u=65536+((u&1023)<<10)|str.charCodeAt(++i)&1023;if(u<=127){++len}else if(u<=2047){len+=2}else if(u<=65535){len+=3}else if(u<=2097151){len+=4}else if(u<=67108863){len+=5}else{len+=6}}return len}Module["lengthBytesUTF8"]=lengthBytesUTF8;var UTF16Decoder=typeof TextDecoder!=="undefined"?new TextDecoder("utf-16le"):undefined;function demangle(func){var __cxa_demangle_func=Module["___cxa_demangle"]||Module["__cxa_demangle"];if(__cxa_demangle_func){try{var s=func.substr(1);var len=lengthBytesUTF8(s)+1;var buf=_malloc(len);stringToUTF8(s,buf,len);var status=_malloc(4);var ret=__cxa_demangle_func(buf,0,0,status);if(getValue(status,"i32")===0&&ret){return Pointer_stringify(ret)}}catch(e){}finally{if(buf)_free(buf);if(status)_free(status);if(ret)_free(ret)}return func}Runtime.warnOnce("warning: build with -s DEMANGLE_SUPPORT=1 to link in libcxxabi demangling");return func}function demangleAll(text){var regex=/__Z[\w\d_]+/g;return text.replace(regex,(function(x){var y=demangle(x);return x===y?x:x+" ["+y+"]"}))}function jsStackTrace(){var err=new Error;if(!err.stack){try{throw new Error(0)}catch(e){err=e}if(!err.stack){return"(no stack trace available)"}}return err.stack.toString()}function stackTrace(){var js=jsStackTrace();if(Module["extraStackTrace"])js+="\n"+Module["extraStackTrace"]();return demangleAll(js)}Module["stackTrace"]=stackTrace;var PAGE_SIZE=16384;var HEAP,buffer,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64;function updateGlobalBufferViews(){Module["HEAP8"]=HEAP8=new Int8Array(buffer);Module["HEAP16"]=HEAP16=new Int16Array(buffer);Module["HEAP32"]=HEAP32=new Int32Array(buffer);Module["HEAPU8"]=HEAPU8=new Uint8Array(buffer);Module["HEAPU16"]=HEAPU16=new Uint16Array(buffer);Module["HEAPU32"]=HEAPU32=new Uint32Array(buffer);Module["HEAPF32"]=HEAPF32=new Float32Array(buffer);Module["HEAPF64"]=HEAPF64=new Float64Array(buffer)}var STATIC_BASE,STATICTOP,staticSealed;var STACK_BASE,STACKTOP,STACK_MAX;var DYNAMIC_BASE,DYNAMICTOP_PTR;STATIC_BASE=STATICTOP=STACK_BASE=STACKTOP=STACK_MAX=DYNAMIC_BASE=DYNAMICTOP_PTR=0;staticSealed=false;function abortOnCannotGrowMemory(){abort("Cannot enlarge memory arrays. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value "+TOTAL_MEMORY+", (2) compile with -s ALLOW_MEMORY_GROWTH=1 which allows increasing the size at runtime but prevents some optimizations, (3) set Module.TOTAL_MEMORY to a higher value before the program runs, or (4) if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 ")}function enlargeMemory(){abortOnCannotGrowMemory()}var TOTAL_STACK=Module["TOTAL_STACK"]||5242880;var TOTAL_MEMORY=Module["TOTAL_MEMORY"]||67108864;if(TOTAL_MEMORY<TOTAL_STACK)Module.printErr("TOTAL_MEMORY should be larger than TOTAL_STACK, was "+TOTAL_MEMORY+"! (TOTAL_STACK="+TOTAL_STACK+")");if(Module["buffer"]){buffer=Module["buffer"]}else{{buffer=new ArrayBuffer(TOTAL_MEMORY)}}updateGlobalBufferViews();function getTotalMemory(){return TOTAL_MEMORY}HEAP32[0]=1668509029;HEAP16[1]=25459;if(HEAPU8[2]!==115||HEAPU8[3]!==99)throw"Runtime error: expected the system to be little-endian!";Module["HEAP"]=HEAP;Module["buffer"]=buffer;Module["HEAP8"]=HEAP8;Module["HEAP16"]=HEAP16;Module["HEAP32"]=HEAP32;Module["HEAPU8"]=HEAPU8;Module["HEAPU16"]=HEAPU16;Module["HEAPU32"]=HEAPU32;Module["HEAPF32"]=HEAPF32;Module["HEAPF64"]=HEAPF64;function callRuntimeCallbacks(callbacks){while(callbacks.length>0){var callback=callbacks.shift();if(typeof callback=="function"){callback();continue}var func=callback.func;if(typeof func==="number"){if(callback.arg===undefined){Module["dynCall_v"](func)}else{Module["dynCall_vi"](func,callback.arg)}}else{func(callback.arg===undefined?null:callback.arg)}}}var __ATPRERUN__=[];var __ATINIT__=[];var __ATMAIN__=[];var __ATEXIT__=[];var __ATPOSTRUN__=[];var runtimeInitialized=false;var runtimeExited=false;function preRun(){if(Module["preRun"]){if(typeof Module["preRun"]=="function")Module["preRun"]=[Module["preRun"]];while(Module["preRun"].length){addOnPreRun(Module["preRun"].shift())}}callRuntimeCallbacks(__ATPRERUN__)}function ensureInitRuntime(){if(runtimeInitialized)return;runtimeInitialized=true;callRuntimeCallbacks(__ATINIT__)}function preMain(){callRuntimeCallbacks(__ATMAIN__)}function exitRuntime(){callRuntimeCallbacks(__ATEXIT__);runtimeExited=true}function postRun(){if(Module["postRun"]){if(typeof Module["postRun"]=="function")Module["postRun"]=[Module["postRun"]];while(Module["postRun"].length){addOnPostRun(Module["postRun"].shift())}}callRuntimeCallbacks(__ATPOSTRUN__)}function addOnPreRun(cb){__ATPRERUN__.unshift(cb)}Module["addOnPreRun"]=addOnPreRun;function addOnInit(cb){__ATINIT__.unshift(cb)}Module["addOnInit"]=addOnInit;function addOnPreMain(cb){__ATMAIN__.unshift(cb)}Module["addOnPreMain"]=addOnPreMain;function addOnExit(cb){__ATEXIT__.unshift(cb)}Module["addOnExit"]=addOnExit;function addOnPostRun(cb){__ATPOSTRUN__.unshift(cb)}Module["addOnPostRun"]=addOnPostRun;function intArrayFromString(stringy,dontAddNull,length){var len=length>0?length:lengthBytesUTF8(stringy)+1;var u8array=new Array(len);var numBytesWritten=stringToUTF8Array(stringy,u8array,0,u8array.length);if(dontAddNull)u8array.length=numBytesWritten;return u8array}Module["intArrayFromString"]=intArrayFromString;function intArrayToString(array){var ret=[];for(var i=0;i<array.length;i++){var chr=array[i];if(chr>255){chr&=255}ret.push(String.fromCharCode(chr))}return ret.join("")}Module["intArrayToString"]=intArrayToString;function writeStringToMemory(string,buffer,dontAddNull){Runtime.warnOnce("writeStringToMemory is deprecated and should not be called! Use stringToUTF8() instead!");var lastChar,end;if(dontAddNull){end=buffer+lengthBytesUTF8(string);lastChar=HEAP8[end]}stringToUTF8(string,buffer,Infinity);if(dontAddNull)HEAP8[end]=lastChar}Module["writeStringToMemory"]=writeStringToMemory;function writeArrayToMemory(array,buffer){HEAP8.set(array,buffer)}Module["writeArrayToMemory"]=writeArrayToMemory;function writeAsciiToMemory(str,buffer,dontAddNull){for(var i=0;i<str.length;++i){HEAP8[buffer++>>0]=str.charCodeAt(i)}if(!dontAddNull)HEAP8[buffer>>0]=0}Module["writeAsciiToMemory"]=writeAsciiToMemory;if(!Math["imul"]||Math["imul"](4294967295,5)!==-5)Math["imul"]=function imul(a,b){var ah=a>>>16;var al=a&65535;var bh=b>>>16;var bl=b&65535;return al*bl+(ah*bl+al*bh<<16)|0};Math.imul=Math["imul"];if(!Math["clz32"])Math["clz32"]=(function(x){x=x>>>0;for(var i=0;i<32;i++){if(x&1<<31-i)return i}return 32});Math.clz32=Math["clz32"];if(!Math["trunc"])Math["trunc"]=(function(x){return x<0?Math.ceil(x):Math.floor(x)});Math.trunc=Math["trunc"];var Math_abs=Math.abs;var Math_cos=Math.cos;var Math_sin=Math.sin;var Math_tan=Math.tan;var Math_acos=Math.acos;var Math_asin=Math.asin;var Math_atan=Math.atan;var Math_atan2=Math.atan2;var Math_exp=Math.exp;var Math_log=Math.log;var Math_sqrt=Math.sqrt;var Math_ceil=Math.ceil;var Math_floor=Math.floor;var Math_pow=Math.pow;var Math_imul=Math.imul;var Math_fround=Math.fround;var Math_round=Math.round;var Math_min=Math.min;var Math_clz32=Math.clz32;var Math_trunc=Math.trunc;var runDependencies=0;var runDependencyWatcher=null;var dependenciesFulfilled=null;function addRunDependency(id){runDependencies++;if(Module["monitorRunDependencies"]){Module["monitorRunDependencies"](runDependencies)}}Module["addRunDependency"]=addRunDependency;function removeRunDependency(id){runDependencies--;if(Module["monitorRunDependencies"]){Module["monitorRunDependencies"](runDependencies)}if(runDependencies==0){if(runDependencyWatcher!==null){clearInterval(runDependencyWatcher);runDependencyWatcher=null}if(dependenciesFulfilled){var callback=dependenciesFulfilled;dependenciesFulfilled=null;callback()}}}Module["removeRunDependency"]=removeRunDependency;Module["preloadedImages"]={};Module["preloadedAudios"]={};var ASM_CONSTS=[(function(){{return Module.getRandomValue()}}),(function(){{if(Module.getRandomValue===undefined){try{var window_="object"===typeof window?window:self,crypto_=typeof window_.crypto!=="undefined"?window_.crypto:window_.msCrypto,randomValuesStandard=(function(){var buf=new Uint32Array(1);crypto_.getRandomValues(buf);return buf[0]>>>0});randomValuesStandard();Module.getRandomValue=randomValuesStandard}catch(e){try{var crypto=__webpack_require__(419),randomValueNodeJS=(function(){var buf=crypto.randomBytes(4);return(buf[0]<<24|buf[1]<<16|buf[2]<<8|buf[3])>>>0});randomValueNodeJS();Module.getRandomValue=randomValueNodeJS}catch(e){throw"No secure random number generator found"}}}}})];function _emscripten_asm_const_i(code){return ASM_CONSTS[code]()}function _emscripten_asm_const_v(code){return ASM_CONSTS[code]()}STATIC_BASE=Runtime.GLOBAL_BASE;STATICTOP=STATIC_BASE+36e3;__ATINIT__.push();allocate([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,38,232,149,143,194,178,39,176,69,195,244,137,242,239,152,240,213,223,172,5,211,198,51,57,177,56,2,136,109,83,252,5,199,23,106,112,61,77,216,79,186,60,11,118,13,16,103,15,42,32,83,250,44,57,204,198,78,199,253,119,146,172,3,122,19,232,149,143,194,178,39,176,69,195,244,137,242,239,152,240,213,223,172,5,211,198,51,57,177,56,2,136,109,83,252,133,180,23,106,112,61,77,216,79,186,60,11,118,13,16,103,15,42,32,83,250,44,57,204,198,78,199,253,119,146,172,3,250,236,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,237,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,238,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,217,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,218,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,219,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,8,201,188,243,103,230,9,106,59,167,202,132,133,174,103,187,43,248,148,254,114,243,110,60,241,54,29,95,58,245,79,165,209,130,230,173,127,82,14,81,31,108,62,43,140,104,5,155,107,189,65,251,171,217,131,31,121,33,126,19,25,205,224,91,34,174,40,215,152,47,138,66,205,101,239,35,145,68,55,113,47,59,77,236,207,251,192,181,188,219,137,129,165,219,181,233,56,181,72,243,91,194,86,57,25,208,5,182,241,17,241,89,155,79,25,175,164,130,63,146,24,129,109,218,213,94,28,171,66,2,3,163,152,170,7,216,190,111,112,69,1,91,131,18,140,178,228,78,190,133,49,36,226,180,255,213,195,125,12,85,111,137,123,242,116,93,190,114,177,150,22,59,254,177,222,128,53,18,199,37,167,6,220,155,148,38,105,207,116,241,155,193,210,74,241,158,193,105,155,228,227,37,79,56,134,71,190,239,181,213,140,139,198,157,193,15,101,156,172,119,204,161,12,36,117,2,43,89,111,44,233,45,131,228,166,110,170,132,116,74,212,251,65,189,220,169,176,92,181,83,17,131,218,136,249,118,171,223,102,238,82,81,62,152,16,50,180,45,109,198,49,168,63,33,251,152,200,39,3,176,228,14,239,190,199,127,89,191,194,143,168,61,243,11,224,198,37,167,10,147,71,145,167,213,111,130,3,224,81,99,202,6,112,110,14,10,103,41,41,20,252,47,210,70,133,10,183,39,38,201,38,92,56,33,27,46,237,42,196,90,252,109,44,77,223,179,149,157,19,13,56,83,222,99,175,139,84,115,10,101,168,178,119,60,187,10,106,118,230,174,237,71,46,201,194,129,59,53,130,20,133,44,114,146,100,3,241,76,161,232,191,162,1,48,66,188,75,102,26,168,145,151,248,208,112,139,75,194,48,190,84,6,163,81,108,199,24,82,239,214,25,232,146,209,16,169,101,85,36,6,153,214,42,32,113,87,133,53,14,244,184,209,187,50,112,160,106,16,200,208,210,184,22,193,164,25,83,171,65,81,8,108,55,30,153,235,142,223,76,119,72,39,168,72,155,225,181,188,176,52,99,90,201,197,179,12,28,57,203,138,65,227,74,170,216,78,115,227,99,119,79,202,156,91,163,184,178,214,243,111,46,104,252,178,239,93,238,130,143,116,96,47,23,67,111,99,165,120,114,171,240,161,20,120,200,132,236,57,100,26,8,2,199,140,40,30,99,35,250,255,190,144,233,189,130,222,235,108,80,164,21,121,198,178,247,163,249,190,43,83,114,227,242,120,113,198,156,97,38,234,206,62,39,202,7,194,192,33,199,184,134,209,30,235,224,205,214,125,218,234,120,209,110,238,127,79,125,245,186,111,23,114,170,103,240,6,166,152,200,162,197,125,99,10,174,13,249,190,4,152,63,17,27,71,28,19,53,11,113,27,132,125,4,35,245,119,219,40,147,36,199,64,123,171,202,50,188,190,201,21,10,190,158,60,76,13,16,156,196,103,29,67,182,66,62,203,190,212,197,76,42,126,101,252,156,41,127,89,236,250,214,58,171,111,203,95,23,88,71,74,140,25,68,108,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,51,51,51,51,51,51,51,51,51,51,51,51,51,51,51,51,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,182,120,89,255,133,114,211,0,189,110,21,255,15,10,106,0,41,192,1,0,152,232,121,255,188,60,160,255,153,113,206,255,0,183,226,254,180,13,72,255,176,160,14,254,211,201,134,255,158,24,143,0,127,105,53,0,96,12,189,0,167,215,251,255,159,76,128,254,106,101,225,255,30,252,4,0,146,12,174,0,89,241,178,254,10,229,166,255,123,221,42,254,30,20,212,0,82,128,3,0,48,209,243,0,119,121,64,255,50,227,156,255,0,110,197,1,103,27,144,0,133,59,140,1,189,241,36,255,248,37,195,1,96,220,55,0,183,76,62,255,195,66,61,0,50,76,164,1,225,164,76,255,76,61,163,255,117,62,31,0,81,145,64,255,118,65,14,0,162,115,214,255,6,138,46,0,124,230,244,255,10,138,143,0,52,26,194,0,184,244,76,0,129,143,41,1,190,244,19,255,123,170,122,255,98,129,68,0,121,213,147,0,86,101,30,255,161,103,155,0,140,89,67,255,239,229,190,1,67,11,181,0,198,240,137,254,238,69,188,255,67,151,238,0,19,42,108,255,229,85,113,1,50,68,135,255,17,106,9,0,50,103,1,255,80,1,168,1,35,152,30,255,16,168,185,1,56,89,232,255,101,210,252,0,41,250,71,0,204,170,79,255,14,46,239,255,80,77,239,0,189,214,75,255,17,141,249,0,38,80,76,255,190,85,117,0,86,228,170,0,156,216,208,1,195,207,164,255,150,66,76,255,175,225,16,255,141,80,98,1,76,219,242,0,198,162,114,0,46,218,152,0,155,43,241,254,155,160,104,255,51,187,165,0,2,17,175,0,66,84,160,1,247,58,30,0,35,65,53,254,69,236,191,0,45,134,245,1,163,123,221,0,32,110,20,255,52,23,165,0,186,214,71,0,233,176,96,0,242,239,54,1,57,89,138,0,83,0,84,255,136,160,100,0,92,142,120,254,104,124,190,0,181,177,62,255,250,41,85,0,152,130,42,1,96,252,246,0,151,151,63,254,239,133,62,0,32,56,156,0,45,167,189,255,142,133,179,1,131,86,211,0,187,179,150,254,250,170,14,255,210,163,78,0,37,52,151,0,99,77,26,0,238,156,213,255,213,192,209,1,73,46,84,0,20,65,41,1,54,206,79,0,201,131,146,254,170,111,24,255,177,33,50,254,171,38,203,255,78,247,116,0,209,221,153,0,133,128,178,1,58,44,25,0,201,39,59,1,189,19,252,0,49,229,210,1,117,187,117,0,181,179,184,1,0,114,219,0,48,94,147,0,245,41,56,0,125,13,204,254,244,173,119,0,44,221,32,254,84,234,20,0,249,160,198,1,236,126,234,255,47,99,168,254,170,226,153,255,102,179,216,0,226,141,122,255,122,66,153,254,182,245,134,0,227,228,25,1,214,57,235,255,216,173,56,255,181,231,210,0,119,128,157,255,129,95,136,255,110,126,51,0,2,169,183,255,7,130,98,254,69,176,94,255,116,4,227,1,217,242,145,255,202,173,31,1,105,1,39,255,46,175,69,0,228,47,58,255,215,224,69,254,207,56,69,255,16,254,139,255,23,207,212,255,202,20,126,255,95,213,96,255,9,176,33,0,200,5,207,255,241,42,128,254,35,33,192,255,248,229,196,1,129,17,120,0,251,103,151,255,7,52,112,255,140,56,66,255,40,226,245,255,217,70,37,254,172,214,9,255,72,67,134,1,146,192,214,255,44,38,112,0,68,184,75,255,206,90,251,0,149,235,141,0,181,170,58,0,116,244,239,0,92,157,2,0,102,173,98,0,233,137,96,1,127,49,203,0,5,155,148,0,23,148,9,255,211,122,12,0,34,134,26,255,219,204,136,0,134,8,41,255,224,83,43,254,85,25,247,0,109,127,0,254,169,136,48,0,238,119,219,255,231,173,213,0,206,18,254,254,8,186,7,255,126,9,7,1,111,42,72,0,111,52,236,254,96,63,141,0,147,191,127,254,205,78,192,255,14,106,237,1,187,219,76,0,175,243,187,254,105,89,173,0,85,25,89,1,162,243,148,0,2,118,209,254,33,158,9,0,139,163,46,255,93,70,40,0,108,42,142,254,111,252,142,255,155,223,144,0,51,229,167,255,73,252,155,255,94,116,12,255,152,160,218,255,156,238,37,255,179,234,207,255,197,0,179,255,154,164,141,0,225,196,104,0,10,35,25,254,209,212,242,255,97,253,222,254,184,101,229,0,222,18,127,1,164,136,135,255,30,207,140,254,146,97,243,0,129,192,26,254,201,84,33,255,111,10,78,255,147,81,178,255,4,4,24,0,161,238,215,255,6,141,33,0,53,215,14,255,41,181,208,255,231,139,157,0,179,203,221,255,255,185,113,0,189,226,172,255,113,66,214,255,202,62,45,255,102,64,8,255,78,174,16,254,133,117,68,255,133,59,140,1,189,241,36,255,248,37,195,1,96,220,55,0,183,76,62,255,195,66,61,0,50,76,164,1,225,164,76,255,76,61,163,255,117,62,31,0,81,145,64,255,118,65,14,0,162,115,214,255,6,138,46,0,124,230,244,255,10,138,143,0,52,26,194,0,184,244,76,0,129,143,41,1,190,244,19,255,123,170,122,255,98,129,68,0,121,213,147,0,86,101,30,255,161,103,155,0,140,89,67,255,239,229,190,1,67,11,181,0,198,240,137,254,238,69,188,255,234,113,60,255,37,255,57,255,69,178,182,254,128,208,179,0,118,26,125,254,3,7,214,255,241,50,77,255,85,203,197,255,211,135,250,255,25,48,100,255,187,213,180,254,17,88,105,0,83,209,158,1,5,115,98,0,4,174,60,254,171,55,110,255,217,181,17,255,20,188,170,0,146,156,102,254,87,214,174,255,114,122,155,1,233,44,170,0,127,8,239,1,214,236,234,0,175,5,219,0,49,106,61,255,6,66,208,255,2,106,110,255,81,234,19,255,215,107,192,255,67,151,238,0,19,42,108,255,229,85,113,1,50,68,135,255,17,106,9,0,50,103,1,255,80,1,168,1,35,152,30,255,16,168,185,1,56,89,232,255,101,210,252,0,41,250,71,0,204,170,79,255,14,46,239,255,80,77,239,0,189,214,75,255,17,141,249,0,38,80,76,255,190,85,117,0,86,228,170,0,156,216,208,1,195,207,164,255,150,66,76,255,175,225,16,255,141,80,98,1,76,219,242,0,198,162,114,0,46,218,152,0,155,43,241,254,155,160,104,255,178,9,252,254,100,110,212,0,14,5,167,0,233,239,163,255,28,151,157,1,101,146,10,255,254,158,70,254,71,249,228,0,88,30,50,0,68,58,160,255,191,24,104,1,129,66,129,255,192,50,85,255,8,179,138,255,38,250,201,0,115,80,160,0,131,230,113,0,125,88,147,0,90,68,199,0,253,76,158,0,28,255,118,0,113,250,254,0,66,75,46,0,230,218,43,0,229,120,186,1,148,68,43,0,136,124,238,1,187,107,197,255,84,53,246,255,51,116,254,255,51,187,165,0,2,17,175,0,66,84,160,1,247,58,30,0,35,65,53,254,69,236,191,0,45,134,245,1,163,123,221,0,32,110,20,255,52,23,165,0,186,214,71,0,233,176,96,0,242,239,54,1,57,89,138,0,83,0,84,255,136,160,100,0,92,142,120,254,104,124,190,0,181,177,62,255,250,41,85,0,152,130,42,1,96,252,246,0,151,151,63,254,239,133,62,0,32,56,156,0,45,167,189,255,142,133,179,1,131,86,211,0,187,179,150,254,250,170,14,255,68,113,21,255,222,186,59,255,66,7,241,1,69,6,72,0,86,156,108,254,55,167,89,0,109,52,219,254,13,176,23,255,196,44,106,255,239,149,71,255,164,140,125,255,159,173,1,0,51,41,231,0,145,62,33,0,138,111,93,1,185,83,69,0,144,115,46,0,97,151,16,255,24,228,26,0,49,217,226,0,113,75,234,254,193,153,12,255,182,48,96,255,14,13,26,0,128,195,249,254,69,193,59,0,132,37,81,254,125,106,60,0,214,240,169,1,164,227,66,0,210,163,78,0,37,52,151,0,99,77,26,0,238,156,213,255,213,192,209,1,73,46,84,0,20,65,41,1,54,206,79,0,201,131,146,254,170,111,24,255,177,33,50,254,171,38,203,255,78,247,116,0,209,221,153,0,133,128,178,1,58,44,25,0,201,39,59,1,189,19,252,0,49,229,210,1,117,187,117,0,181,179,184,1,0,114,219,0,48,94,147,0,245,41,56,0,125,13,204,254,244,173,119,0,44,221,32,254,84,234,20,0,249,160,198,1,236,126,234,255,143,62,221,0,129,89,214,255,55,139,5,254,68,20,191,255,14,204,178,1,35,195,217,0,47,51,206,1,38,246,165,0,206,27,6,254,158,87,36,0,217,52,146,255,125,123,215,255,85,60,31,255,171,13,7,0,218,245,88,254,252,35,60,0,55,214,160,255,133,101,56,0,224,32,19,254,147,64,234,0,26,145,162,1,114,118,125,0,248,252,250,0,101,94,196,255,198,141,226,254,51,42,182,0,135,12,9,254,109,172,210,255,197,236,194,1,241,65,154,0,48,156,47,255,153,67,55,255,218,165,34,254,74,180,179,0,218,66,71,1,88,122,99,0,212,181,219,255,92,42,231,255,239,0,154,0,245,77,183,255,94,81,170,1,18,213,216,0,171,93,71,0,52,94,248,0,18,151,161,254,197,209,66,255,174,244,15,254,162,48,183,0,49,61,240,254,182,93,195,0,199,228,6,1,200,5,17,255,137,45,237,255,108,148,4,0,90,79,237,255,39,63,77,255,53,82,207,1,142,22,118,255,101,232,18,1,92,26,67,0,5,200,88,255,33,168,138,255,149,225,72,0,2,209,27,255,44,245,168,1,220,237,17,255,30,211,105,254,141,238,221,0,128,80,245,254,111,254,14,0,222,95,190,1,223,9,241,0,146,76,212,255,108,205,104,255,63,117,153,0,144,69,48,0,35,228,111,0,192,33,193,255,112,214,190,254,115,152,151,0,23,102,88,0,51,74,248,0,226,199,143,254,204,162,101,255,208,97,189,1,245,104,18,0,230,246,30,255,23,148,69,0,110,88,52,254,226,181,89,255,208,47,90,254,114,161,80,255,33,116,248,0,179,152,87,255,69,144,177,1,88,238,26,255,58,32,113,1,1,77,69,0,59,121,52,255,152,238,83,0,52,8,193,0,231,39,233,255,199,34,138,0,222,68,173,0,91,57,242,254,220,210,127,255,192,7,246,254,151,35,187,0,195,236,165,0,111,93,206,0,212,247,133,1,154,133,209,255,155,231,10,0,64,78,38,0,122,249,100,1,30,19,97,255,62,91,249,1,248,133,77,0,197,63,168,254,116,10,82,0,184,236,113,254,212,203,194,255,61,100,252,254,36,5,202,255,119,91,153,255,129,79,29,0,103,103,171,254,237,215,111,255,216,53,69,0,239,240,23,0,194,149,221,255,38,225,222,0,232,255,180,254,118,82,133,255,57,209,177,1,139,232,133,0,158,176,46,254,194,115,46,0,88,247,229,1,28,103,191,0,221,222,175,254,149,235,44,0,151,228,25,254,218,105,103,0,142,85,210,0,149,129,190,255,213,65,94,254,117,134,224,255,82,198,117,0,157,221,220,0,163,101,36,0,197,114,37,0,104,172,166,254,11,182,0,0,81,72,188,255,97,188,16,255,69,6,10,0,199,147,145,255,8,9,115,1,65,214,175,255,217,173,209,0,80,127,166,0,247,229,4,254,167,183,124,255,90,28,204,254,175,59,240,255,11,41,248,1,108,40,51,255,144,177,195,254,150,250,126,0,138,91,65,1,120,60,222,255,245,193,239,0,29,214,189,255,128,2,25,0,80,154,162,0,77,220,107,1,234,205,74,255,54,166,103,255,116,72,9,0,228,94,47,255,30,200,25,255,35,214,89,255,61,176,140,255,83,226,163,255,75,130,172,0,128,38,17,0,95,137,152,255,215,124,159,1,79,93,0,0,148,82,157,254,195,130,251,255,40,202,76,255,251,126,224,0,157,99,62,254,207,7,225,255,96,68,195,0,140,186,157,255,131,19,231,255,42,128,254,0,52,219,61,254,102,203,72,0,141,7,11,255,186,164,213,0,31,122,119,0,133,242,145,0,208,252,232,255,91,213,182,255,143,4,250,254,249,215,74,0,165,30,111,1,171,9,223,0,229,123,34,1,92,130,26,255,77,155,45,1,195,139,28,255,59,224,78,0,136,17,247,0,108,121,32,0,79,250,189,255,96,227,252,254,38,241,62,0,62,174,125,255,155,111,93,255,10,230,206,1,97,197,40,255,0,49,57,254,65,250,13,0,18,251,150,255,220,109,210,255,5,174,166,254,44,129,189,0,235,35,147,255,37,247,141,255,72,141,4,255,103,107,255,0,247,90,4,0,53,44,42,0,2,30,240,0,4,59,63,0,88,78,36,0,113,167,180,0,190,71,193,255,199,158,164,255,58,8,172,0,77,33,12,0,65,63,3,0,153,77,33,255,172,254,102,1,228,221,4,255,87,30,254,1,146,41,86,255,138,204,239,254,108,141,17,255,187,242,135,0,210,208,127,0,68,45,14,254,73,96,62,0,81,60,24,255,170,6,36,255,3,249,26,0,35,213,109,0,22,129,54,255,21,35,225,255,234,61,56,255,58,217,6,0,143,124,88,0,236,126,66,0,209,38,183,255,34,238,6,255,174,145,102,0,95,22,211,0,196,15,153,254,46,84,232,255,117,34,146,1,231,250,74,255,27,134,100,1,92,187,195,255,170,198,112,0,120,28,42,0,209,70,67,0,29,81,31,0,29,168,100,1,169,173,160,0,107,35,117,0,62,96,59,255,81,12,69,1,135,239,190,255,220,252,18,0,163,220,58,255,137,137,188,255,83,102,109,0,96,6,76,0,234,222,210,255,185,174,205,1,60,158,213,255,13,241,214,0,172,129,140,0,93,104,242,0,192,156,251,0,43,117,30,0,225,81,158,0,127,232,218,0,226,28,203,0,233,27,151,255,117,43,5,255,242,14,47,255,33,20,6,0,137,251,44,254,27,31,245,255,183,214,125,254,40,121,149,0,186,158,213,255,89,8,227,0,69,88,0,254,203,135,225,0,201,174,203,0,147,71,184,0,18,121,41,254,94,5,78,0,224,214,240,254,36,5,180,0,251,135,231,1,163,138,212,0,210,249,116,254,88,129,187,0,19,8,49,254,62,14,144,255,159,76,211,0,214,51,82,0,109,117,228,254,103,223,203,255,75,252,15,1,154,71,220,255,23,13,91,1,141,168,96,255,181,182,133,0,250,51,55,0,234,234,212,254,175,63,158,0,39,240,52,1,158,189,36,255,213,40,85,1,32,180,247,255,19,102,26,1,84,24,97,255,69,21,222,0,148,139,122,255,220,213,235,1,232,203,255,0,121,57,147,0,227,7,154,0,53,22,147,1,72,1,225,0,82,134,48,254,83,60,157,255,145,72,169,0,34,103,239,0,198,233,47,0,116,19,4,255,184,106,9,255,183,129,83,0,36,176,230,1,34,103,72,0,219,162,134,0,245,42,158,0,32,149,96,254,165,44,144,0,202,239,72,254,215,150,5,0,42,66,36,1,132,215,175,0,86,174,86,255,26,197,156,255,49,232,135,254,103,182,82,0,253,128,176,1,153,178,122,0,245,250,10,0,236,24,178,0,137,106,132,0,40,29,41,0,50,30,152,255,124,105,38,0,230,191,75,0,143,43,170,0,44,131,20,255,44,13,23,255,237,255,155,1,159,109,100,255,112,181,24,255,104,220,108,0,55,211,131,0,99,12,213,255,152,151,145,255,238,5,159,0,97,155,8,0,33,108,81,0,1,3,103,0,62,109,34,255,250,155,180,0,32,71,195,255,38,70,145,1,159,95,245,0,69,229,101,1,136,28,240,0,79,224,25,0,78,110,121,255,248,168,124,0,187,128,247,0,2,147,235,254,79,11,132,0,70,58,12,1,181,8,163,255,79,137,133,255,37,170,11,255,141,243,85,255,176,231,215,255,204,150,164,255,239,215,39,255,46,87,156,254,8,163,88,255,172,34,232,0,66,44,102,255,27,54,41,254,236,99,87,255,41,123,169,1,52,114,43,0,117,134,40,0,155,134,26,0,231,207,91,254,35,132,38,255,19,102,125,254,36,227,133,255,118,3,113,255,29,13,124,0,152,96,74,1,88,146,206,255,167,191,220,254,162,18,88,255,182,100,23,0,31,117,52,0,81,46,106,1,12,2,7,0,69,80,201,1,209,246,172,0,12,48,141,1,224,211,88,0,116,226,159,0,122,98,130,0,65,236,234,1,225,226,9,255,207,226,123,1,89,214,59,0,112,135,88,1,90,244,203,255,49,11,38,1,129,108,186,0,89,112,15,1,101,46,204,255,127,204,45,254,79,255,221,255,51,73,18,255,127,42,101,255,241,21,202,0,160,227,7,0,105,50,236,0,79,52,197,255,104,202,208,1,180,15,16,0,101,197,78,255,98,77,203,0,41,185,241,1,35,193,124,0,35,155,23,255,207,53,192,0,11,125,163,1,249,158,185,255,4,131,48,0,21,93,111,255,61,121,231,1,69,200,36,255,185,48,185,255,111,238,21,255,39,50,25,255,99,215,163,255,87,212,30,255,164,147,5,255,128,6,35,1,108,223,110,255,194,76,178,0,74,101,180,0,243,47,48,0,174,25,43,255,82,173,253,1,54,114,192,255,40,55,91,0,215,108,176,255,11,56,7,0,224,233,76,0,209,98,202,254,242,25,125,0,44,193,93,254,203,8,177,0,135,176,19,0,112,71,213,255,206,59,176,1,4,67,26,0,14,143,213,254,42,55,208,255,60,67,120,0,193,21,163,0,99,164,115,0,10,20,118,0,156,212,222,254,160,7,217,255,114,245,76,1,117,59,123,0,176,194,86,254,213,15,176,0,78,206,207,254,213,129,59,0,233,251,22,1,96,55,152,255,236,255,15,255,197,89,84,255,93,149,133,0,174,160,113,0,234,99,169,255,152,116,88,0,144,164,83,255,95,29,198,255,34,47,15,255,99,120,134,255,5,236,193,0,249,247,126,255,147,187,30,0,50,230,117,255,108,217,219,255,163,81,166,255,72,25,169,254,155,121,79,255,28,155,89,254,7,126,17,0,147,65,33,1,47,234,253,0,26,51,18,0,105,83,199,255,163,196,230,0,113,248,164,0,226,254,218,0,189,209,203,255,164,247,222,254,255,35,165,0,4,188,243,1,127,179,71,0,37,237,254,255,100,186,240,0,5,57,71,254,103,72,73,255,244,18,81,254,229,210,132,255,238,6,180,255,11,229,174,255,227,221,192,1,17,49,28,0,163,215,196,254,9,118,4,255,51,240,71,0,113,129,109,255,76,240,231,0,188,177,127,0,125,71,44,1,26,175,243,0,94,169,25,254,27,230,29,0,15,139,119,1,168,170,186,255,172,197,76,255,252,75,188,0,137,124,196,0,72,22,96,255,45,151,249,1,220,145,100,0,64,192,159,255,120,239,226,0,129,178,146,0,0,192,125,0,235,138,234,0,183,157,146,0,83,199,192,255,184,172,72,255,73,225,128,0,77,6,250,255,186,65,67,0,104,246,207,0,188,32,138,255,218,24,242,0,67,138,81,254,237,129,121,255,20,207,150,1,41,199,16,255,6,20,128,0,159,118,5,0,181,16,143,255,220,38,15,0,23,64,147,254,73,26,13,0,87,228,57,1,204,124,128,0,43,24,223,0,219,99,199,0,22,75,20,255,19,27,126,0,157,62,215,0,110,29,230,0,179,167,255,1,54,252,190,0,221,204,182,254,179,158,65,255,81,157,3,0,194,218,159,0,170,223,0,0,224,11,32,255,38,197,98,0,168,164,37,0,23,88,7,1,164,186,110,0,96,36,134,0,234,242,229,0,250,121,19,0,242,254,112,255,3,47,94,1,9,239,6,255,81,134,153,254,214,253,168,255,67,124,224,0,245,95,74,0,28,30,44,254,1,109,220,255,178,89,89,0,252,36,76,0,24,198,46,255,76,77,111,0,134,234,136,255,39,94,29,0,185,72,234,255,70,68,135,255,231,102,7,254,77,231,140,0,167,47,58,1,148,97,118,255,16,27,225,1,166,206,143,255,110,178,214,255,180,131,162,0,143,141,225,1,13,218,78,255,114,153,33,1,98,104,204,0,175,114,117,1,167,206,75,0,202,196,83,1,58,64,67,0,138,47,111,1,196,247,128,255,137,224,224,254,158,112,207,0,154,100,255,1,134,37,107,0,198,128,79,255,127,209,155,255,163,254,185,254,60,14,243,0,31,219,112,254,29,217,65,0,200,13,116,254,123,60,196,255,224,59,184,254,242,89,196,0,123,16,75,254,149,16,206,0,69,254,48,1,231,116,223,255,209,160,65,1,200,80,98,0,37,194,184,254,148,63,34,0,139,240,65,255,217,144,132,255,56,38,45,254,199,120,210,0,108,177,166,255,160,222,4,0,220,126,119,254,165,107,160,255,82,220,248,1,241,175,136,0,144,141,23,255,169,138,84,0,160,137,78,255,226,118,80,255,52,27,132,255,63,96,139,255,152,250,39,0,188,155,15,0,232,51,150,254,40,15,232,255,240,229,9,255,137,175,27,255,75,73,97,1,218,212,11,0,135,5,162,1,107,185,213,0,2,249,107,255,40,242,70,0,219,200,25,0,25,157,13,0,67,82,80,255,196,249,23,255,145,20,149,0,50,72,146,0,94,76,148,1,24,251,65,0,31,192,23,0,184,212,201,255,123,233,162,1,247,173,72,0,162,87,219,254,126,134,89,0,159,11,12,254,166,105,29,0,73,27,228,1,113,120,183,255,66,163,109,1,212,143,11,255,159,231,168,1,255,128,90,0,57,14,58,254,89,52,10,255,253,8,163,1,0,145,210,255,10,129,85,1,46,181,27,0,103,136,160,254,126,188,209,255,34,35,111,0,215,219,24,255,212,11,214,254,101,5,118,0,232,197,133,255,223,167,109,255,237,80,86,255,70,139,94,0,158,193,191,1,155,15,51,255,15,190,115,0,78,135,207,255,249,10,27,1,181,125,233,0,95,172,13,254,170,213,161,255,39,236,138,255,95,93,87,255,190,128,95,0,125,15,206,0,166,150,159,0,227,15,158,255,206,158,120,255,42,141,128,0,101,178,120,1,156,109,131,0,218,14,44,254,247,168,206,255,212,112,28,0,112,17,228,255,90,16,37,1,197,222,108,0,254,207,83,255,9,90,243,255,243,244,172,0,26,88,115,255,205,116,122,0,191,230,193,0,180,100,11,1,217,37,96,255,154,78,156,0,235,234,31,255,206,178,178,255,149,192,251,0,182,250,135,0,246,22,105,0,124,193,109,255,2,210,149,255,169,17,170,0,0,96,110,255,117,9,8,1,50,123,40,255,193,189,99,0,34,227,160,0,48,80,70,254,211,51,236,0,45,122,245,254,44,174,8,0,173,37,233,255,158,65,171,0,122,69,215,255,90,80,2,255,131,106,96,254,227,114,135,0,205,49,119,254,176,62,64,255,82,51,17,255,241,20,243,255,130,13,8,254,128,217,243,255,162,27,1,254,90,118,241,0,246,198,246,255,55,16,118,255,200,159,157,0,163,17,1,0,140,107,121,0,85,161,118,255,38,0,149,0,156,47,238,0,9,166,166,1,75,98,181,255,50,74,25,0,66,15,47,0,139,225,159,0,76,3,142,255,14,238,184,0,11,207,53,255,183,192,186,1,171,32,174,255,191,76,221,1,247,170,219,0,25,172,50,254,217,9,233,0,203,126,68,255,183,92,48,0,127,167,183,1,65,49,254,0,16,63,127,1,254,21,170,255,59,224,127,254,22,48,63,255,27,78,130,254,40,195,29,0,250,132,112,254,35,203,144,0,104,169,168,0,207,253,30,255,104,40,38,254,94,228,88,0,206,16,128,255,212,55,122,255,223,22,234,0,223,197,127,0,253,181,181,1,145,102,118,0,236,153,36,255,212,217,72,255,20,38,24,254,138,62,62,0,152,140,4,0,230,220,99,255,1,21,212,255,148,201,231,0,244,123,9,254,0,171,210,0,51,58,37,255,1,255,14,255,244,183,145,254,0,242,166,0,22,74,132,0,121,216,41,0,95,195,114,254,133,24,151,255,156,226,231,255,247,5,77,255,246,148,115,254,225,92,81,255,222,80,246,254,170,123,89,255,74,199,141,0,29,20,8,255,138,136,70,255,93,75,92,0,221,147,49,254,52,126,226,0,229,124,23,0,46,9,181,0,205,64,52,1,131,254,28,0,151,158,212,0,131,64,78,0,206,25,171,0,0,230,139,0,191,253,110,254,103,247,167,0,64,40,40,1,42,165,241,255,59,75,228,254,124,243,189,255,196,92,178,255,130,140,86,255,141,89,56,1,147,198,5,255,203,248,158,254,144,162,141,0,11,172,226,0,130,42,21,255,1,167,143,255,144,36,36,255,48,88,164,254,168,170,220,0,98,71,214,0,91,208,79,0,159,76,201,1,166,42,214,255,69,255,0,255,6,128,125,255,190,1,140,0,146,83,218,255,215,238,72,1,122,127,53,0,189,116,165,255,84,8,66,255,214,3,208,255,213,110,133,0,195,168,44,1,158,231,69,0,162,64,200,254,91,58,104,0,182,58,187,254,249,228,136,0,203,134,76,254,99,221,233,0,75,254,214,254,80,69,154,0,64,152,248,254,236,136,202,255,157,105,153,254,149,175,20,0,22,35,19,255,124,121,233,0,186,250,198,254,132,229,139,0,137,80,174,255,165,125,68,0,144,202,148,254,235,239,248,0,135,184,118,0,101,94,17,255,122,72,70,254,69,130,146,0,127,222,248,1,69,127,118,255,30,82,215,254,188,74,19,255,229,167,194,254,117,25,66,255,65,234,56,254,213,22,156,0,151,59,93,254,45,28,27,255,186,126,164,255,32,6,239,0,127,114,99,1,219,52,2,255,99,96,166,254,62,190,126,255,108,222,168,1,75,226,174,0,230,226,199,0,60,117,218,255,252,248,20,1,214,188,204,0,31,194,134,254,123,69,192,255,169,173,36,254,55,98,91,0,223,42,102,254,137,1,102,0,157,90,25,0,239,122,64,255,252,6,233,0,7,54,20,255,82,116,174,0,135,37,54,255,15,186,125,0,227,112,175,255,100,180,225,255,42,237,244,255,244,173,226,254,248,18,33,0,171,99,150,255,74,235,50,255,117,82,32,254,106,168,237,0,207,109,208,1,228,9,186,0,135,60,169,254,179,92,143,0,244,170,104,255,235,45,124,255,70,99,186,0,117,137,183,0,224,31,215,0,40,9,100,0,26,16,95,1,68,217,87,0,8,151,20,255,26,100,58,255,176,165,203,1,52,118,70,0,7,32,254,254,244,254,245,255,167,144,194,255,125,113,23,255,176,121,181,0,136,84,209,0,138,6,30,255,89,48,28,0,33,155,14,255,25,240,154,0,141,205,109,1,70,115,62,255,20,40,107,254,138,154,199,255,94,223,226,255,157,171,38,0,163,177,25,254,45,118,3,255,14,222,23,1,209,190,81,255,118,123,232,1,13,213,101,255,123,55,123,254,27,246,165,0,50,99,76,255,140,214,32,255,97,65,67,255,24,12,28,0,174,86,78,1,64,247,96,0,160,135,67,0,66,55,243,255,147,204,96,255,26,6,33,255,98,51,83,1,153,213,208,255,2,184,54,255,25,218,11,0,49,67,246,254,18,149,72,255,13,25,72,0,42,79,214,0,42,4,38,1,27,139,144,255,149,187,23,0,18,164,132,0,245,84,184,254,120,198,104,255,126,218,96,0,56,117,234,255,13,29,214,254,68,47,10,255,167,154,132,254,152,38,198,0,66,178,89,255,200,46,171,255,13,99,83,255,210,187,253,255,170,45,42,1,138,209,124,0,214,162,141,0,12,230,156,0,102,36,112,254,3,147,67,0,52,215,123,255,233,171,54,255,98,137,62,0,247,218,39,255,231,218,236,0,247,191,127,0,195,146,84,0,165,176,92,255,19,212,94,255,17,74,227,0,88,40,153,1,198,147,1,255,206,67,245,254,240,3,218,255,61,141,213,255,97,183,106,0,195,232,235,254,95,86,154,0,209,48,205,254,118,209,241,255,240,120,223,1,213,29,159,0,163,127,147,255,13,218,93,0,85,24,68,254,70,20,80,255,189,5,140,1,82,97,254,255,99,99,191,255,132,84,133,255,107,218,116,255,112,122,46,0,105,17,32,0,194,160,63,255,68,222,39,1,216,253,92,0,177,105,205,255,149,201,195,0,42,225,11,255,40,162,115,0,9,7,81,0,165,218,219,0,180,22,0,254,29,146,252,255,146,207,225,1,180,135,96,0,31,163,112,0,177,11,219,255,133,12,193,254,43,78,50,0,65,113,121,1,59,217,6,255,110,94,24,1,112,172,111,0,7,15,96,0,36,85,123,0,71,150,21,255,208,73,188,0,192,11,167,1,213,245,34,0,9,230,92,0,162,142,39,255,215,90,27,0,98,97,89,0,94,79,211,0,90,157,240,0,95,220,126,1,102,176,226,0,36,30,224,254,35,31,127,0,231,232,115,1,85,83,130,0,210,73,245,255,47,143,114,255,68,65,197,0,59,72,62,255,183,133,173,254,93,121,118,255,59,177,81,255,234,69,173,255,205,128,177,0,220,244,51,0,26,244,209,1,73,222,77,255,163,8,96,254,150,149,211,0,158,254,203,1,54,127,139,0,161,224,59,0,4,109,22,255,222,42,45,255,208,146,102,255,236,142,187,0,50,205,245,255,10,74,89,254,48,79,142,0,222,76,130,255,30,166,63,0,236,12,13,255,49,184,244,0,187,113,102,0,218,101,253,0,153,57,182,254,32,150,42,0,25,198,146,1,237,241,56,0,140,68,5,0,91,164,172,255,78,145,186,254,67,52,205,0,219,207,129,1,109,115,17,0,54,143,58,1,21,248,120,255,179,255,30,0,193,236,66,255,1,255,7,255,253,192,48,255,19,69,217,1,3,214,0,255,64,101,146,1,223,125,35,255,235,73,179,255,249,167,226,0,225,175,10,1,97,162,58,0,106,112,171,1,84,172,5,255,133,140,178,255,134,245,142,0,97,90,125,255,186,203,185,255,223,77,23,255,192,92,106,0,15,198,115,255,217,152,248,0,171,178,120,255,228,134,53,0,176,54,193,1,250,251,53,0,213,10,100,1,34,199,106,0,151,31,244,254,172,224,87,255,14,237,23,255,253,85,26,255,127,39,116,255,172,104,100,0,251,14,70,255,212,208,138,255,253,211,250,0,176,49,165,0,15,76,123,255,37,218,160,255,92,135,16,1,10,126,114,255,70,5,224,255,247,249,141,0,68,20,60,1,241,210,189,255,195,217,187,1,151,3,113,0,151,92,174,0,231,62,178,255,219,183,225,0,23,23,33,255,205,181,80,0,57,184,248,255,67,180,1,255,90,123,93,255,39,0,162,255,96,248,52,255,84,66,140,0,34,127,228,255,194,138,7,1,166,110,188,0,21,17,155,1,154,190,198,255,214,80,59,255,18,7,143,0,72,29,226,1,199,217,249,0,232,161,71,1,149,190,201,0,217,175,95,254,113,147,67,255,138,143,199,255,127,204,1,0,29,182,83,1,206,230,155,255,186,204,60,0,10,125,85,255,232,96,25,255,255,89,247,255,213,254,175,1,232,193,81,0,28,43,156,254,12,69,8,0,147,24,248,0,18,198,49,0,134,60,35,0,118,246,18,255,49,88,254,254,228,21,186,255,182,65,112,1,219,22,1,255,22,126,52,255,189,53,49,255,112,25,143,0,38,127,55,255,226,101,163,254,208,133,61,255,137,69,174,1,190,118,145,255,60,98,219,255,217,13,245,255,250,136,10,0,84,254,226,0,201,31,125,1,240,51,251,255,31,131,130,255,2,138,50,255,215,215,177,1,223,12,238,255,252,149,56,255,124,91,68,255,72,126,170,254,119,255,100,0,130,135,232,255,14,79,178,0,250,131,197,0,138,198,208,0,121,216,139,254,119,18,36,255,29,193,122,0,16,42,45,255,213,240,235,1,230,190,169,255,198,35,228,254,110,173,72,0,214,221,241,255,56,148,135,0,192,117,78,254,141,93,207,255,143,65,149,0,21,18,98,255,95,44,244,1,106,191,77,0,254,85,8,254,214,110,176,255,73,173,19,254,160,196,199,255,237,90,144,0,193,172,113,255,200,155,136,254,228,90,221,0,137,49,74,1,164,221,215,255,209,189,5,255,105,236,55,255,42,31,129,1,193,255,236,0,46,217,60,0,138,88,187,255,226,82,236,255,81,69,151,255,142,190,16,1,13,134,8,0,127,122,48,255,81,64,156,0,171,243,139,0,237,35,246,0,122,143,193,254,212,122,146,0,95,41,255,1,87,132,77,0,4,212,31,0,17,31,78,0,39,45,173,254,24,142,217,255,95,9,6,255,227,83,6,0,98,59,130,254,62,30,33,0,8,115,211,1,162,97,128,255,7,184,23,254,116,28,168,255,248,138,151,255,98,244,240,0,186,118,130,0,114,248,235,255,105,173,200,1,160,124,71,255,94,36,164,1,175,65,146,255,238,241,170,254,202,198,197,0,228,71,138,254,45,246,109,255,194,52,158,0,133,187,176,0,83,252,154,254,89,189,221,255,170,73,252,0,148,58,125,0,36,68,51,254,42,69,177,255,168,76,86,255,38,100,204,255,38,53,35,0,175,19,97,0,225,238,253,255,81,81,135,0,210,27,255,254,235,73,107,0,8,207,115,0,82,127,136,0,84,99,21,254,207,19,136,0,100,164,101,0,80,208,77,255,132,207,237,255,15,3,15,255,33,166,110,0,156,95,85,255,37,185,111,1,150,106,35,255,166,151,76,0,114,87,135,255,159,194,64,0,12,122,31,255,232,7,101,254,173,119,98,0,154,71,220,254,191,57,53,255,168,232,160,255,224,32,99,255,218,156,165,0,151,153,163,0,217,13,148,1,197,113,89,0,149,28,161,254,207,23,30,0,105,132,227,255,54,230,94,255,133,173,204,255,92,183,157,255,88,144,252,254,102,33,90,0,159,97,3,0,181,218,155,255,240,114,119,0,106,214,53,255,165,190,115,1,152,91,225,255,88,106,44,255,208,61,113,0,151,52,124,0,191,27,156,255,110,54,236,1,14,30,166,255,39,127,207,1,229,199,28,0,188,228,188,254,100,157,235,0,246,218,183,1,107,22,193,255,206,160,95,0,76,239,147,0,207,161,117,0,51,166,2,255,52,117,10,254,73,56,227,255,152,193,225,0,132,94,136,255,101,191,209,0,32,107,229,255,198,43,180,1,100,210,118,0,114,67,153,255,23,88,26,255,89,154,92,1,220,120,140,255,144,114,207,255,252,115,250,255,34,206,72,0,138,133,127,255,8,178,124,1,87,75,97,0,15,229,92,254,240,67,131,255,118,123,227,254,146,120,104,255,145,213,255,1,129,187,70,255,219,119,54,0,1,19,173,0,45,150,148,1,248,83,72,0,203,233,169,1,142,107,56,0,247,249,38,1,45,242,80,255,30,233,103,0,96,82,70,0,23,201,111,0,81,39,30,255,161,183,78,255,194,234,33,255,68,227,140,254,216,206,116,0,70,27,235,255,104,144,79,0,164,230,93,254,214,135,156,0,154,187,242,254,188,20,131,255,36,109,174,0,159,112,241,0,5,110,149,1,36,165,218,0,166,29,19,1,178,46,73,0,93,43,32,254,248,189,237,0,102,155,141,0,201,93,195,255,241,139,253,255,15,111,98,255,108,65,163,254,155,79,190,255,73,174,193,254,246,40,48,255,107,88,11,254,202,97,85,255,253,204,18,255,113,242,66,0,110,160,194,254,208,18,186,0,81,21,60,0,188,104,167,255,124,166,97,254,210,133,142,0,56,242,137,254,41,111,130,0,111,151,58,1,111,213,141,255,183,172,241,255,38,6,196,255,185,7,123,255,46,11,246,0,245,105,119,1,15,2,161,255,8,206,45,255,18,202,74,255,83,124,115,1,212,141,157,0,83,8,209,254,139,15,232,255,172,54,173,254,50,247,132,0,214,189,213,0,144,184,105,0,223,254,248,0,255,147,240,255,23,188,72,0,7,51,54,0,188,25,180,254,220,180,0,255,83,160,20,0,163,189,243,255,58,209,194,255,87,73,60,0,106,24,49,0,245,249,220,0,22,173,167,0,118,11,195,255,19,126,237,0,110,159,37,255,59,82,47,0,180,187,86,0,188,148,208,1,100,37,133,255,7,112,193,0,129,188,156,255,84,106,129,255,133,225,202,0,14,236,111,255,40,20,101,0,172,172,49,254,51,54,74,255,251,185,184,255,93,155,224,255,180,249,224,1,230,178,146,0,72,57,54,254,178,62,184,0,119,205,72,0,185,239,253,255,61,15,218,0,196,67,56,255,234,32,171,1,46,219,228,0,208,108,234,255,20,63,232,255,165,53,199,1,133,228,5,255,52,205,107,0,74,238,140,255,150,156,219,254,239,172,178,255,251,189,223,254,32,142,211,255,218,15,138,1,241,196,80,0,28,36,98,254,22,234,199,0,61,237,220,255,246,57,37,0,142,17,142,255,157,62,26,0,43,238,95,254,3,217,6,255,213,25,240,1,39,220,174,255,154,205,48,254,19,13,192,255,244,34,54,254,140,16,155,0,240,181,5,254,155,193,60,0,166,128,4,255,36,145,56,255,150,240,219,0,120,51,145,0,82,153,42,1,140,236,146,0,107,92,248,1,189,10,3,0,63,136,242,0,211,39,24,0,19,202,161,1,173,27,186,255,210,204,239,254,41,209,162,255,182,254,159,255,172,116,52,0,195,103,222,254,205,69,59,0,53,22,41,1,218,48,194,0,80,210,242,0,210,188,207,0,187,161,161,254,216,17,1,0,136,225,113,0,250,184,63,0,223,30,98,254,77,168,162,0,59,53,175,0,19,201,10,255,139,224,194,0,147,193,154,255,212,189,12,254,1,200,174,255,50,133,113,1,94,179,90,0,173,182,135,0,94,177,113,0,43,89,215,255,136,252,106,255,123,134,83,254,5,245,66,255,82,49,39,1,220,2,224,0,97,129,177,0,77,59,89,0,61,29,155,1,203,171,220,255,92,78,139,0,145,33,181,255,169,24,141,1,55,150,179,0,139,60,80,255,218,39,97,0,2,147,107,255,60,248,72,0,173,230,47,1,6,83,182,255,16,105,162,254,137,212,81,255,180,184,134,1,39,222,164,255,221,105,251,1,239,112,125,0,63,7,97,0,63,104,227,255,148,58,12,0,90,60,224,255,84,212,252,0,79,215,168,0,248,221,199,1,115,121,1,0,36,172,120,0,32,162,187,255,57,107,49,255,147,42,21,0,106,198,43,1,57,74,87,0,126,203,81,255,129,135,195,0,140,31,177,0,221,139,194,0,3,222,215,0,131,68,231,0,177,86,178,254,124,151,180,0,184,124,38,1,70,163,17,0,249,251,181,1,42,55,227,0,226,161,44,0,23,236,110,0,51,149,142,1,93,5,236,0,218,183,106,254,67,24,77,0,40,245,209,255,222,121,153,0,165,57,30,0,83,125,60,0,70,38,82,1,229,6,188,0,109,222,157,255,55,118,63,255,205,151,186,0,227,33,149,255,254,176,246,1,227,177,227,0,34,106,163,254,176,43,79,0,106,95,78,1,185,241,122,255,185,14,61,0,36,1,202,0,13,178,162,255,247,11,132,0,161,230,92,1,65,1,185,255,212,50,165,1,141,146,64,255,158,242,218,0,21,164,125,0,213,139,122,1,67,71,87,0,203,158,178,1,151,92,43,0,152,111,5,255,39,3,239,255,217,255,250,255,176,63,71,255,74,245,77,1,250,174,18,255,34,49,227,255,246,46,251,255,154,35,48,1,125,157,61,255,106,36,78,255,97,236,153,0,136,187,120,255,113,134,171,255,19,213,217,254,216,94,209,255,252,5,61,0,94,3,202,0,3,26,183,255,64,191,43,255,30,23,21,0,129,141,77,255,102,120,7,1,194,76,140,0,188,175,52,255,17,81,148,0,232,86,55,1,225,48,172,0,134,42,42,255,238,50,47,0,169,18,254,0,20,147,87,255,14,195,239,255,69,247,23,0,238,229,128,255,177,49,112,0,168,98,251,255,121,71,248,0,243,8,145,254,246,227,153,255,219,169,177,254,251,139,165,255,12,163,185,255,164,40,171,255,153,159,27,254,243,109,91,255,222,24,112,1,18,214,231,0,107,157,181,254,195,147,0,255,194,99,104,255,89,140,190,255,177,66,126,254,106,185,66],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE);allocate([49,218,31,0,252,174,158,0,188,79,230,1,238,41,224,0,212,234,8,1,136,11,181,0,166,117,83,255,68,195,94,0,46,132,201,0,240,152,88,0,164,57,69,254,160,224,42,255,59,215,67,255,119,195,141,255,36,180,121,254,207,47,8,255,174,210,223,0,101,197,68,255,255,82,141,1,250,137,233,0,97,86,133,1,16,80,69,0,132,131,159,0,116,93,100,0,45,141,139,0,152,172,157,255,90,43,91,0,71,153,46,0,39,16,112,255,217,136,97,255,220,198,25,254,177,53,49,0,222,88,134,255,128,15,60,0,207,192,169,255,192,116,209,255,106,78,211,1,200,213,183,255,7,12,122,254,222,203,60,255,33,110,199,254,251,106,117,0,228,225,4,1,120,58,7,255,221,193,84,254,112,133,27,0,189,200,201,255,139,135,150,0,234,55,176,255,61,50,65,0,152,108,169,255,220,85,1,255,112,135,227,0,162,26,186,0,207,96,185,254,244,136,107,0,93,153,50,1,198,97,151,0,110,11,86,255,143,117,174,255,115,212,200,0,5,202,183,0,237,164,10,254,185,239,62,0,236,120,18,254,98,123,99,255,168,201,194,254,46,234,214,0,191,133,49,255,99,169,119,0,190,187,35,1,115,21,45,255,249,131,72,0,112,6,123,255,214,49,181,254,166,233,34,0,92,197,102,254,253,228,205,255,3,59,201,1,42,98,46,0,219,37,35,255,169,195,38,0,94,124,193,1,156,43,223,0,95,72,133,254,120,206,191,0,122,197,239,255,177,187,79,255,254,46,2,1,250,167,190,0,84,129,19,0,203,113,166,255,249,31,189,254,72,157,202,255,208,71,73,255,207,24,72,0,10,16,18,1,210,81,76,255,88,208,192,255,126,243,107,255,238,141,120,255,199,121,234,255,137,12,59,255,36,220,123,255,148,179,60,254,240,12,29,0,66,0,97,1,36,30,38,255,115,1,93,255,96,103,231,255,197,158,59,1,192,164,240,0,202,202,57,255,24,174,48,0,89,77,155,1,42,76,215,0,244,151,233,0,23,48,81,0,239,127,52,254,227,130,37,255,248,116,93,1,124,132,118,0,173,254,192,1,6,235,83,255,110,175,231,1,251,28,182,0,129,249,93,254,84,184,128,0,76,181,62,0,175,128,186,0,100,53,136,254,109,29,226,0,221,233,58,1,20,99,74,0,0,22,160,0,134,13,21,0,9,52,55,255,17,89,140,0,175,34,59,0,84,165,119,255,224,226,234,255,7,72,166,255,123,115,255,1,18,214,246,0,250,7,71,1,217,220,185,0,212,35,76,255,38,125,175,0,189,97,210,0,114,238,44,255,41,188,169,254,45,186,154,0,81,92,22,0,132,160,193,0,121,208,98,255,13,81,44,255,203,156,82,0,71,58,21,255,208,114,191,254,50,38,147,0,154,216,195,0,101,25,18,0,60,250,215,255,233,132,235,255,103,175,142,1,16,14,92,0,141,31,110,254,238,241,45,255,153,217,239,1,97,168,47,255,249,85,16,1,28,175,62,255,57,254,54,0,222,231,126,0,166,45,117,254,18,189,96,255,228,76,50,0,200,244,94,0,198,152,120,1,68,34,69,255,12,65,160,254,101,19,90,0,167,197,120,255,68,54,185,255,41,218,188,0,113,168,48,0,88,105,189,1,26,82,32,255,185,93,164,1,228,240,237,255,66,182,53,0,171,197,92,255,107,9,233,1,199,120,144,255,78,49,10,255,109,170,105,255,90,4,31,255,28,244,113,255,74,58,11,0,62,220,246,255,121,154,200,254,144,210,178,255,126,57,129,1,43,250,14,255,101,111,28,1,47,86,241,255,61,70,150,255,53,73,5,255,30,26,158,0,209,26,86,0,138,237,74,0,164,95,188,0,142,60,29,254,162,116,248,255,187,175,160,0,151,18,16,0,209,111,65,254,203,134,39,255,88,108,49,255,131,26,71,255,221,27,215,254,104,105,93,255,31,236,31,254,135,0,211,255,143,127,110,1,212,73,229,0,233,67,167,254,195,1,208,255,132,17,221,255,51,217,90,0,67,235,50,255,223,210,143,0,179,53,130,1,233,106,198,0,217,173,220,255,112,229,24,255,175,154,93,254,71,203,246,255,48,66,133,255,3,136,230,255,23,221,113,254,235,111,213,0,170,120,95,254,251,221,2,0,45,130,158,254,105,94,217,255,242,52,180,254,213,68,45,255,104,38,28,0,244,158,76,0,161,200,96,255,207,53,13,255,187,67,148,0,170,54,248,0,119,162,178,255,83,20,11,0,42,42,192,1,146,159,163,255,183,232,111,0,77,229,21,255,71,53,143,0,27,76,34,0,246,136,47,255,219,39,182,255,92,224,201,1,19,142,14,255,69,182,241,255,163,118,245,0,9,109,106,1,170,181,247,255,78,47,238,255,84,210,176,255,213,107,139,0,39,38,11,0,72,21,150,0,72,130,69,0,205,77,155,254,142,133,21,0,71,111,172,254,226,42,59,255,179,0,215,1,33,128,241,0,234,252,13,1,184,79,8,0,110,30,73,255,246,141,189,0,170,207,218,1,74,154,69,255,138,246,49,255,155,32,100,0,125,74,105,255,90,85,61,255,35,229,177,255,62,125,193,255,153,86,188,1,73,120,212,0,209,123,246,254,135,209,38,255,151,58,44,1,92,69,214,255,14,12,88,255,252,153,166,255,253,207,112,255,60,78,83,255,227,124,110,0,180,96,252,255,53,117,33,254,164,220,82,255,41,1,27,255,38,164,166,255,164,99,169,254,61,144,70,255,192,166,18,0,107,250,66,0,197,65,50,0,1,179,18,255,255,104,1,255,43,153,35,255,80,111,168,0,110,175,168,0,41,105,45,255,219,14,205,255,164,233,140,254,43,1,118,0,233,67,195,0,178,82,159,255,138,87,122,255,212,238,90,255,144,35,124,254,25,140,164,0,251,215,44,254,133,70,107,255,101,227,80,254,92,169,55,0,215,42,49,0,114,180,85,255,33,232,27,1,172,213,25,0,62,176,123,254,32,133,24,255,225,191,62,0,93,70,153,0,181,42,104,1,22,191,224,255,200,200,140,255,249,234,37,0,149,57,141,0,195,56,208,255,254,130,70,255,32,173,240,255,29,220,199,0,110,100,115,255,132,229,249,0,228,233,223,255,37,216,209,254,178,177,209,255,183,45,165,254,224,97,114,0,137,97,168,255,225,222,172,0,165,13,49,1,210,235,204,255,252,4,28,254,70,160,151,0,232,190,52,254,83,248,93,255,62,215,77,1,175,175,179,255,160,50,66,0,121,48,208,0,63,169,209,255,0,210,200,0,224,187,44,1,73,162,82,0,9,176,143,255,19,76,193,255,29,59,167,1,24,43,154,0,28,190,190,0,141,188,129,0,232,235,203,255,234,0,109,255,54,65,159,0,60,88,232,255,121,253,150,254,252,233,131,255,198,110,41,1,83,77,71,255,200,22,59,254,106,253,242,255,21,12,207,255,237,66,189,0,90,198,202,1,225,172,127,0,53,22,202,0,56,230,132,0,1,86,183,0,109,190,42,0,243,68,174,1,109,228,154,0,200,177,122,1,35,160,183,255,177,48,85,255,90,218,169,255,248,152,78,0,202,254,110,0,6,52,43,0,142,98,65,255,63,145,22,0,70,106,93,0,232,138,107,1,110,179,61,255,211,129,218,1,242,209,92,0,35,90,217,1,182,143,106,255,116,101,217,255,114,250,221,255,173,204,6,0,60,150,163,0,73,172,44,255,239,110,80,255,237,76,153,254,161,140,249,0,149,232,229,0,133,31,40,255,174,164,119,0,113,51,214,0,129,228,2,254,64,34,243,0,107,227,244,255,174,106,200,255,84,153,70,1,50,35,16,0,250,74,216,254,236,189,66,255,153,249,13,0,230,178,4,255,221,41,238,0,118,227,121,255,94,87,140,254,254,119,92,0,73,239,246,254,117,87,128,0,19,211,145,255,177,46,252,0,229,91,246,1,69,128,247,255,202,77,54,1,8,11,9,255,153,96,166,0,217,214,173,255,134,192,2,1,0,207,0,0,189,174,107,1,140,134,100,0,158,193,243,1,182,102,171,0,235,154,51,0,142,5,123,255,60,168,89,1,217,14,92,255,19,214,5,1,211,167,254,0,44,6,202,254,120,18,236,255,15,113,184,255,184,223,139,0,40,177,119,254,182,123,90,255,176,165,176,0,247,77,194,0,27,234,120,0,231,0,214,255,59,39,30,0,125,99,145,255,150,68,68,1,141,222,248,0,153,123,210,255,110,127,152,255,229,33,214,1,135,221,197,0,137,97,2,0,12,143,204,255,81,41,188,0,115,79,130,255,94,3,132,0,152,175,187,255,124,141,10,255,126,192,179,255,11,103,198,0,149,6,45,0,219,85,187,1,230,18,178,255,72,182,152,0,3,198,184,255,128,112,224,1,97,161,230,0,254,99,38,255,58,159,197,0,151,66,219,0,59,69,143,255,185,112,249,0,119,136,47,255,123,130,132,0,168,71,95,255,113,176,40,1,232,185,173,0,207,93,117,1,68,157,108,255,102,5,147,254,49,97,33,0,89,65,111,254,247,30,163,255,124,217,221,1,102,250,216,0,198,174,75,254,57,55,18,0,227,5,236,1,229,213,173,0,201,109,218,1,49,233,239,0,30,55,158,1,25,178,106,0,155,111,188,1,94,126,140,0,215,31,238,1,77,240,16,0,213,242,25,1,38,71,168,0,205,186,93,254,49,211,140,255,219,0,180,255,134,118,165,0,160,147,134,255,110,186,35,255,198,243,42,0,243,146,119,0,134,235,163,1,4,241,135,255,193,46,193,254,103,180,79,255,225,4,184,254,242,118,130,0,146,135,176,1,234,111,30,0,69,66,213,254,41,96,123,0,121,94,42,255,178,191,195,255,46,130,42,0,117,84,8,255,233,49,214,254,238,122,109,0,6,71,89,1,236,211,123,0,244,13,48,254,119,148,14,0,114,28,86,255,75,237,25,255,145,229,16,254,129,100,53,255,134,150,120,254,168,157,50,0,23,72,104,255,224,49,14,0,255,123,22,255,151,185,151,255,170,80,184,1,134,182,20,0,41,100,101,1,153,33,16,0,76,154,111,1,86,206,234,255,192,160,164,254,165,123,93,255,1,216,164,254,67,17,175,255,169,11,59,255,158,41,61,255,73,188,14,255,195,6,137,255,22,147,29,255,20,103,3,255,246,130,227,255,122,40,128,0,226,47,24,254,35,36,32,0,152,186,183,255,69,202,20,0,195,133,195,0,222,51,247,0,169,171,94,1,183,0,160,255,64,205,18,1,156,83,15,255,197,58,249,254,251,89,110,255,50,10,88,254,51,43,216,0,98,242,198,1,245,151,113,0,171,236,194,1,197,31,199,255,229,81,38,1,41,59,20,0,253,104,230,0,152,93,14,255,246,242,146,254,214,169,240,255,240,102,108,254,160,167,236,0,154,218,188,0,150,233,202,255,27,19,250,1,2,71,133,255,175,12,63,1,145,183,198,0,104,120,115,255,130,251,247,0,17,212,167,255,62,123,132,255,247,100,189,0,155,223,152,0,143,197,33,0,155,59,44,255,150,93,240,1,127,3,87,255,95,71,207,1,167,85,1,255,188,152,116,255,10,23,23,0,137,195,93,1,54,98,97,0,240,0,168,255,148,188,127,0,134,107,151,0,76,253,171,0,90,132,192,0,146,22,54,0,224,66,54,254,230,186,229,255,39,182,196,0,148,251,130,255,65,131,108,254,128,1,160,0,169,49,167,254,199,254,148,255,251,6,131,0,187,254,129,255,85,82,62,0,178,23,58,255,254,132,5,0,164,213,39,0,134,252,146,254,37,53,81,255,155,134,82,0,205,167,238,255,94,45,180,255,132,40,161,0,254,111,112,1,54,75,217,0,179,230,221,1,235,94,191,255,23,243,48,1,202,145,203,255,39,118,42,255,117,141,253,0,254,0,222,0,43,251,50,0,54,169,234,1,80,68,208,0,148,203,243,254,145,7,135,0,6,254,0,0,252,185,127,0,98,8,129,255,38,35,72,255,211,36,220,1,40,26,89,0,168,64,197,254,3,222,239,255,2,83,215,254,180,159,105,0,58,115,194,0,186,116,106,255,229,247,219,255,129,118,193,0,202,174,183,1,166,161,72,0,201,107,147,254,237,136,74,0,233,230,106,1,105,111,168,0,64,224,30,1,1,229,3,0,102,151,175,255,194,238,228,255,254,250,212,0,187,237,121,0,67,251,96,1,197,30,11,0,183,95,204,0,205,89,138,0,64,221,37,1,255,223,30,255,178,48,211,255,241,200,90,255,167,209,96,255,57,130,221,0,46,114,200,255,61,184,66,0,55,182,24,254,110,182,33,0,171,190,232,255,114,94,31,0,18,221,8,0,47,231,254,0,255,112,83,0,118,15,215,255,173,25,40,254,192,193,31,255,238,21,146,255,171,193,118,255,101,234,53,254,131,212,112,0,89,192,107,1,8,208,27,0,181,217,15,255,231,149,232,0,140,236,126,0,144,9,199,255,12,79,181,254,147,182,202,255,19,109,182,255,49,212,225,0,74,163,203,0,175,233,148,0,26,112,51,0,193,193,9,255,15,135,249,0,150,227,130,0,204,0,219,1,24,242,205,0,238,208,117,255,22,244,112,0,26,229,34,0,37,80,188,255,38,45,206,254,240,90,225,255,29,3,47,255,42,224,76,0,186,243,167,0,32,132,15,255,5,51,125,0,139,135,24,0,6,241,219,0,172,229,133,255,246,214,50,0,231,11,207,255,191,126,83,1,180,163,170,255,245,56,24,1,178,164,211,255,3,16,202,1,98,57,118,255,141,131,89,254,33,51,24,0,243,149,91,255,253,52,14,0,35,169,67,254,49,30,88,255,179,27,36,255,165,140,183,0,58,189,151,0,88,31,0,0,75,169,66,0,66,101,199,255,24,216,199,1,121,196,26,255,14,79,203,254,240,226,81,255,94,28,10,255,83,193,240,255,204,193,131,255,94,15,86,0,218,40,157,0,51,193,209,0,0,242,177,0,102,185,247,0,158,109,116,0,38,135,91,0,223,175,149,0,220,66,1,255,86,60,232,0,25,96,37,255,225,122,162,1,215,187,168,255,158,157,46,0,56,171,162,0,232,240,101,1,122,22,9,0,51,9,21,255,53,25,238,255,217,30,232,254,125,169,148,0,13,232,102,0,148,9,37,0,165,97,141,1,228,131,41,0,222,15,243,255,254,18,17,0,6,60,237,1,106,3,113,0,59,132,189,0,92,112,30,0,105,208,213,0,48,84,179,255,187,121,231,254,27,216,109,255,162,221,107,254,73,239,195,255,250,31,57,255,149,135,89,255,185,23,115,1,3,163,157,255,18,112,250,0,25,57,187,255,161,96,164,0,47,16,243,0,12,141,251,254,67,234,184,255,41,18,161,0,175,6,96,255,160,172,52,254,24,176,183,255,198,193,85,1,124,121,137,255,151,50,114,255,220,203,60,255,207,239,5,1,0,38,107,255,55,238,94,254,70,152,94,0,213,220,77,1,120,17,69,255,85,164,190,255,203,234,81,0,38,49,37,254,61,144,124,0,137,78,49,254,168,247,48,0,95,164,252,0,105,169,135,0,253,228,134,0,64,166,75,0,81,73,20,255,207,210,10,0,234,106,150,255,94,34,90,255,254,159,57,254,220,133,99,0,139,147,180,254,24,23,185,0,41,57,30,255,189,97,76,0,65,187,223,255,224,172,37,255,34,62,95,1,231,144,240,0,77,106,126,254,64,152,91,0,29,98,155,0,226,251,53,255,234,211,5,255,144,203,222,255,164,176,221,254,5,231,24,0,179,122,205,0,36,1,134,255,125,70,151,254,97,228,252,0,172,129,23,254,48,90,209,255,150,224,82,1,84,134,30,0,241,196,46,0,103,113,234,255,46,101,121,254,40,124,250,255,135,45,242,254,9,249,168,255,140,108,131,255,143,163,171,0,50,173,199,255,88,222,142,255,200,95,158,0,142,192,163,255,7,117,135,0,111,124,22,0,236,12,65,254,68,38,65,255,227,174,254,0,244,245,38,0,240,50,208,255,161,63,250,0,60,209,239,0,122,35,19,0,14,33,230,254,2,159,113,0,106,20,127,255,228,205,96,0,137,210,174,254,180,212,144,255,89,98,154,1,34,88,139,0,167,162,112,1,65,110,197,0,241,37,169,0,66,56,131,255,10,201,83,254,133,253,187,255,177,112,45,254,196,251,0,0,196,250,151,255,238,232,214,255,150,209,205,0,28,240,118,0,71,76,83,1,236,99,91,0,42,250,131,1,96,18,64,255,118,222,35,0,113,214,203,255,122,119,184,255,66,19,36,0,204,64,249,0,146,89,139,0,134,62,135,1,104,233,101,0,188,84,26,0,49,249,129,0,208,214,75,255,207,130,77,255,115,175,235,0,171,2,137,255,175,145,186,1,55,245,135,255,154,86,181,1,100,58,246,255,109,199,60,255,82,204,134,255,215,49,230,1,140,229,192,255,222,193,251,255,81,136,15,255,179,149,162,255,23,39,29,255,7,95,75,254,191,81,222,0,241,81,90,255,107,49,201,255,244,211,157,0,222,140,149,255,65,219,56,254,189,246,90,255,178,59,157,1,48,219,52,0,98,34,215,0,28,17,187,255,175,169,24,0,92,79,161,255,236,200,194,1,147,143,234,0,229,225,7,1,197,168,14,0,235,51,53,1,253,120,174,0,197,6,168,255,202,117,171,0,163,21,206,0,114,85,90,255,15,41,10,255,194,19,99,0,65,55,216,254,162,146,116,0,50,206,212,255,64,146,29,255,158,158,131,1,100,165,130,255,172,23,129,255,125,53,9,255,15,193,18,1,26,49,11,255,181,174,201,1,135,201,14,255,100,19,149,0,219,98,79,0,42,99,143,254,96,0,48,255,197,249,83,254,104,149,79,255,235,110,136,254,82,128,44,255,65,41,36,254,88,211,10,0,187,121,187,0,98,134,199,0,171,188,179,254,210,11,238,255,66,123,130,254,52,234,61,0,48,113,23,254,6,86,120,255,119,178,245,0,87,129,201,0,242,141,209,0,202,114,85,0,148,22,161,0,103,195,48,0,25,49,171,255,138,67,130,0,182,73,122,254,148,24,130,0,211,229,154,0,32,155,158,0,84,105,61,0,177,194,9,255,166,89,86,1,54,83,187,0,249,40,117,255,109,3,215,255,53,146,44,1,63,47,179,0,194,216,3,254,14,84,136,0,136,177,13,255,72,243,186,255,117,17,125,255,211,58,211,255,93,79,223,0,90,88,245,255,139,209,111,255,70,222,47,0,10,246,79,255,198,217,178,0,227,225,11,1,78,126,179,255,62,43,126,0,103,148,35,0,129,8,165,254,245,240,148,0,61,51,142,0,81,208,134,0,15,137,115,255,211,119,236,255,159,245,248,255,2,134,136,255,230,139,58,1,160,164,254,0,114,85,141,255,49,166,182,255,144,70,84,1,85,182,7,0,46,53,93,0,9,166,161,255,55,162,178,255,45,184,188,0,146,28,44,254,169,90,49,0,120,178,241,1,14,123,127,255,7,241,199,1,189,66,50,255,198,143,101,254,189,243,135,255,141,24,24,254,75,97,87,0,118,251,154,1,237,54,156,0,171,146,207,255,131,196,246,255,136,64,113,1,151,232,57,0,240,218,115,0,49,61,27,255,64,129,73,1,252,169,27,255,40,132,10,1,90,201,193,255,252,121,240,1,186,206,41,0,43,198,97,0,145,100,183,0,204,216,80,254,172,150,65,0,249,229,196,254,104,123,73,255,77,104,96,254,130,180,8,0,104,123,57,0,220,202,229,255,102,249,211,0,86,14,232,255,182,78,209,0,239,225,164,0,106,13,32,255,120,73,17,255,134,67,233,0,83,254,181,0,183,236,112,1,48,64,131,255,241,216,243,255,65,193,226,0,206,241,100,254,100,134,166,255,237,202,197,0,55,13,81,0,32,124,102,255,40,228,177,0,118,181,31,1,231,160,134,255,119,187,202,0,0,142,60,255,128,38,189,255,166,201,150,0,207,120,26,1,54,184,172,0,12,242,204,254,133,66,230,0,34,38,31,1,184,112,80,0,32,51,165,254,191,243,55,0,58,73,146,254,155,167,205,255,100,104,152,255,197,254,207,255,173,19,247,0,238,10,202,0,239,151,242,0,94,59,39,255,240,29,102,255,10,92,154,255,229,84,219,255,161,129,80,0,208,90,204,1,240,219,174,255,158,102,145,1,53,178,76,255,52,108,168,1,83,222,107,0,211,36,109,0,118,58,56,0,8,29,22,0,237,160,199,0,170,209,157,0,137,71,47,0,143,86,32,0,198,242,2,0,212,48,136,1,92,172,186,0,230,151,105,1,96,191,229,0,138,80,191,254,240,216,130,255,98,43,6,254,168,196,49,0,253,18,91,1,144,73,121,0,61,146,39,1,63,104,24,255,184,165,112,254,126,235,98,0,80,213,98,255,123,60,87,255,82,140,245,1,223,120,173,255,15,198,134,1,206,60,239,0,231,234,92,255,33,238,19,255,165,113,142,1,176,119,38,0,160,43,166,254,239,91,105,0,107,61,194,1,25,4,68,0,15,139,51,0,164,132,106,255,34,116,46,254,168,95,197,0,137,212,23,0,72,156,58,0,137,112,69,254,150,105,154,255,236,201,157,0,23,212,154,255,136,82,227,254,226,59,221,255,95,149,192,0,81,118,52,255,33,43,215,1,14,147,75,255,89,156,121,254,14,18,79,0,147,208,139,1,151,218,62,255,156,88,8,1,210,184,98,255,20,175,123,255,102,83,229,0,220,65,116,1,150,250,4,255,92,142,220,255,34,247,66,255,204,225,179,254,151,81,151,0,71,40,236,255,138,63,62,0,6,79,240,255,183,185,181,0,118,50,27,0,63,227,192,0,123,99,58,1,50,224,155,255,17,225,223,254,220,224,77,255,14,44,123,1,141,128,175,0,248,212,200,0,150,59,183,255,147,97,29,0,150,204,181,0,253,37,71,0,145,85,119,0,154,200,186,0,2,128,249,255,83,24,124,0,14,87,143,0,168,51,245,1,124,151,231,255,208,240,197,1,124,190,185,0,48,58,246,0,20,233,232,0,125,18,98,255,13,254,31,255,245,177,130,255,108,142,35,0,171,125,242,254,140,12,34,255,165,161,162,0,206,205,101,0,247,25,34,1,100,145,57,0,39,70,57,0,118,204,203,255,242,0,162,0,165,244,30,0,198,116,226,0,128,111,153,255,140,54,182,1,60,122,15,255,155,58,57,1,54,50,198,0,171,211,29,255,107,138,167,255,173,107,199,255,109,161,193,0,89,72,242,255,206,115,89,255,250,254,142,254,177,202,94,255,81,89,50,0,7,105,66,255,25,254,255,254,203,64,23,255,79,222,108,255,39,249,75,0,241,124,50,0,239,152,133,0,221,241,105,0,147,151,98,0,213,161,121,254,242,49,137,0,233,37,249,254,42,183,27,0,184,119,230,255,217,32,163,255,208,251,228,1,137,62,131,255,79,64,9,254,94,48,113,0,17,138,50,254,193,255,22,0,247,18,197,1,67,55,104,0,16,205,95,255,48,37,66,0,55,156,63,1,64,82,74,255,200,53,71,254,239,67,125,0,26,224,222,0,223,137,93,255,30,224,202,255,9,220,132,0,198,38,235,1,102,141,86,0,60,43,81,1,136,28,26,0,233,36,8,254,207,242,148,0,164,162,63,0,51,46,224,255,114,48,79,255,9,175,226,0,222,3,193,255,47,160,232,255,255,93,105,254,14,42,230,0,26,138,82,1,208,43,244,0,27,39,38,255,98,208,127,255,64,149,182,255,5,250,209,0,187,60,28,254,49,25,218,255,169,116,205,255,119,18,120,0,156,116,147,255,132,53,109,255,13,10,202,0,110,83,167,0,157,219,137,255,6,3,130,255,50,167,30,255,60,159,47,255,129,128,157,254,94,3,189,0,3,166,68,0,83,223,215,0,150,90,194,1,15,168,65,0,227,83,51,255,205,171,66,255,54,187,60,1,152,102,45,255,119,154,225,0,240,247,136,0,100,197,178,255,139,71,223,255,204,82,16,1,41,206,42,255,156,192,221,255,216,123,244,255,218,218,185,255,187,186,239,255,252,172,160,255,195,52,22,0,144,174,181,254,187,100,115,255,211,78,176,255,27,7,193,0,147,213,104,255,90,201,10,255,80,123,66,1,22,33,186,0,1,7,99,254,30,206,10,0,229,234,5,0,53,30,210,0,138,8,220,254,71,55,167,0,72,225,86,1,118,190,188,0,254,193,101,1,171,249,172,255,94,158,183,254,93,2,108,255,176,93,76,255,73,99,79,255,74,64,129,254,246,46,65,0,99,241,127,254,246,151,102,255,44,53,208,254,59,102,234,0,154,175,164,255,88,242,32,0,111,38,1,0,255,182,190,255,115,176,15,254,169,60,129,0,122,237,241,0,90,76,63,0,62,74,120,255,122,195,110,0,119,4,178,0,222,242,210,0,130,33,46,254,156,40,41,0,167,146,112,1,49,163,111,255,121,176,235,0,76,207,14,255,3,25,198,1,41,235,213,0,85,36,214,1,49,92,109,255,200,24,30,254,168,236,195,0,145,39,124,1,236,195,149,0,90,36,184,255,67,85,170,255,38,35,26,254,131,124,68,255,239,155,35,255,54,201,164,0,196,22,117,255,49,15,205,0,24,224,29,1,126,113,144,0,117,21,182,0,203,159,141,0,223,135,77,0,176,230,176,255,190,229,215,255,99,37,181,255,51,21,138,255,25,189,89,255,49,48,165,254,152,45,247,0,170,108,222,0,80,202,5,0,27,69,103,254,204,22,129,255,180,252,62,254,210,1,91,255,146,110,254,255,219,162,28,0,223,252,213,1,59,8,33,0,206,16,244,0,129,211,48,0,107,160,208,0,112,59,209,0,109,77,216,254,34,21,185,255,246,99,56,255,179,139,19,255,185,29,50,255,84,89,19,0,74,250,98,255,225,42,200,255,192,217,205,255,210,16,167,0,99,132,95,1,43,230,57,0,254,11,203,255,99,188,63,255,119,193,251,254,80,105,54,0,232,181,189,1,183,69,112,255,208,171,165,255,47,109,180,255,123,83,165,0,146,162,52,255,154,11,4,255,151,227,90,255,146,137,97,254,61,233,41,255,94,42,55,255,108,164,236,0,152,68,254,0,10,140,131,255,10,106,79,254,243,158,137,0,67,178,66,254,177,123,198,255,15,62,34,0,197,88,42,255,149,95,177,255,152,0,198,255,149,254,113,255,225,90,163,255,125,217,247,0,18,17,224,0,128,66,120,254,192,25,9,255,50,221,205,0,49,212,70,0,233,255,164,0,2,209,9,0,221,52,219,254,172,224,244,255,94,56,206,1,242,179,2,255,31,91,164,1,230,46,138,255,189,230,220,0,57,47,61,255,111,11,157,0,177,91,152,0,28,230,98,0,97,87,126,0,198,89,145,255,167,79,107,0,249,77,160,1,29,233,230,255,150,21,86,254,60,11,193,0,151,37,36,254,185,150,243,255,228,212,83,1,172,151,180,0,201,169,155,0,244,60,234,0,142,235,4,1,67,218,60,0,192,113,75,1,116,243,207,255,65,172,155,0,81,30,156,255,80,72,33,254,18,231,109,255,142,107,21,254,125,26,132,255,176,16,59,255,150,201,58,0,206,169,201,0,208,121,226,0,40,172,14,255,150,61,94,255,56,57,156,255,141,60,145,255,45,108,149,255,238,145,155,255,209,85,31,254,192,12,210,0,99,98,93,254,152,16,151,0,225,185,220,0,141,235,44,255,160,172,21,254,71,26,31,255,13,64,93,254,28,56,198,0,177,62,248,1,182,8,241,0,166,101,148,255,78,81,133,255,129,222,215,1,188,169,129,255,232,7,97,0,49,112,60,255,217,229,251,0,119,108,138,0,39,19,123,254,131,49,235,0,132,84,145,0,130,230,148,255,25,74,187,0,5,245,54,255,185,219,241,1,18,194,228,255,241,202,102,0,105,113,202,0,155,235,79,0,21,9,178,255,156,1,239,0,200,148,61,0,115,247,210,255,49,221,135,0,58,189,8,1,35,46,9,0,81,65,5,255,52,158,185,255,125,116,46,255,74,140,13,255,210,92,172,254,147,23,71,0,217,224,253,254,115,108,180,255,145,58,48,254,219,177,24,255,156,255,60,1,154,147,242,0,253,134,87,0,53,75,229,0,48,195,222,255,31,175,50,255,156,210,120,255,208,35,222,255,18,248,179,1,2,10,101,255,157,194,248,255,158,204,101,255,104,254,197,255,79,62,4,0,178,172,101,1,96,146,251,255,65,10,156,0,2,137,165,255,116,4,231,0,242,215,1,0,19,35,29,255,43,161,79,0,59,149,246,1,251,66,176,0,200,33,3,255,80,110,142,255,195,161,17,1,228,56,66,255,123,47,145,254,132,4,164,0,67,174,172,0,25,253,114,0,87,97,87,1,250,220,84,0,96,91,200,255,37,125,59,0,19,65,118,0,161,52,241,255,237,172,6,255,176,191,255,255,1,65,130,254,223,190,230,0,101,253,231,255,146,35,109,0,250,29,77,1,49,0,19,0,123,90,155,1,22,86,32,255,218,213,65,0,111,93,127,0,60,93,169,255,8,127,182,0,17,186,14,254,253,137,246,255,213,25,48,254,76,238,0,255,248,92,70,255,99,224,139,0,184,9,255,1,7,164,208,0,205,131,198,1,87,214,199,0,130,214,95,0,221,149,222,0,23,38,171,254,197,110,213,0,43,115,140,254,215,177,118,0,96,52,66,1,117,158,237,0,14,64,182,255,46,63,174,255,158,95,190,255,225,205,177,255,43,5,142,255,172,99,212,255,244,187,147,0,29,51,153,255,228,116,24,254,30,101,207,0,19,246,150,255,134,231,5,0,125,134,226,1,77,65,98,0,236,130,33,255,5,110,62,0,69,108,127,255,7,113,22,0,145,20,83,254,194,161,231,255,131,181,60,0,217,209,177,255,229,148,212,254,3,131,184,0,117,177,187,1,28,14,31,255,176,102,80,0,50,84,151,255,125,31,54,255,21,157,133,255,19,179,139,1,224,232,26,0,34,117,170,255,167,252,171,255,73,141,206,254,129,250,35,0,72,79,236,1,220,229,20,255,41,202,173,255,99,76,238,255,198,22,224,255,108,198,195,255,36,141,96,1,236,158,59,255,106,100,87,0,110,226,2,0,227,234,222,0,154,93,119,255,74,112,164,255,67,91,2,255,21,145,33,255,102,214,137,255,175,230,103,254,163,246,166,0,93,247,116,254,167,224,28,255,220,2,57,1,171,206,84,0,123,228,17,255,27,120,119,0,119,11,147,1,180,47,225,255,104,200,185,254,165,2,114,0,77,78,212,0,45,154,177,255,24,196,121,254,82,157,182,0,90,16,190,1,12,147,197,0,95,239,152,255,11,235,71,0,86,146,119,255,172,134,214,0,60,131,196,0,161,225,129,0,31,130,120,254,95,200,51,0,105,231,210,255,58,9,148,255,43,168,221,255,124,237,142,0,198,211,50,254,46,245,103,0,164,248,84,0,152,70,208,255,180,117,177,0,70,79,185,0,243,74,32,0,149,156,207,0,197,196,161,1,245,53,239,0,15,93,246,254,139,240,49,255,196,88,36,255,162,38,123,0,128,200,157,1,174,76,103,255,173,169,34,254,216,1,171,255,114,51,17,0,136,228,194,0,110,150,56,254,106,246,159,0,19,184,79,255,150,77,240,255,155,80,162,0,0,53,169,255,29,151,86,0,68,94,16,0,92,7,110,254,98,117,149,255,249,77,230,255,253,10,140,0,214,124,92,254,35,118,235,0,89,48,57,1,22,53,166,0,184,144,61,255,179,255,194,0,214,248,61,254,59,110,246,0,121,21,81,254,166,3,228,0,106,64,26,255,69,232,134,255,242,220,53,254,46,220,85,0,113,149,247,255,97,179,103,255,190,127,11,0,135,209,182,0,95,52,129,1,170,144,206,255,122,200,204,255,168,100,146,0,60,144,149,254,70,60,40,0,122,52,177,255,246,211,101,255,174,237,8,0,7,51,120,0,19,31,173,0,126,239,156,255,143,189,203,0,196,128,88,255,233,133,226,255,30,125,173,255,201,108,50,0,123,100,59,255,254,163,3,1,221,148,181,255,214,136,57,254,222,180,137,255,207,88,54,255,28,33,251,255,67,214,52,1,210,208,100,0,81,170,94,0,145,40,53,0,224,111,231,254,35,28,244,255,226,199,195,254,238,17,230,0,217,217,164,254,169,157,221,0,218,46,162,1,199,207,163,255,108,115,162,1,14,96,187,255,118,60,76,0,184,159,152,0,209,231,71,254,42,164,186,255,186,153,51,254,221,171,182,255,162,142,173,0,235,47,193,0,7,139,16,1,95,164,64,255,16,221,166,0,219,197,16,0,132,29,44,255,100,69,117,255,60,235,88,254,40,81,173,0,71,190,61,255,187,88,157,0,231,11,23,0,237,117,164,0,225,168,223,255,154,114,116,255,163,152,242,1,24,32,170,0,125,98,113,254,168,19,76,0,17,157,220,254,155,52,5,0,19,111,161,255,71,90,252,255,173,110,240,0,10,198,121,255,253,255,240,255,66,123,210,0,221,194,215,254,121,163,17,255,225,7,99,0,190,49,182,0,115,9,133,1,232,26,138,255,213,68,132,0,44,119,122,255,179,98,51,0,149,90,106,0,71,50,230,255,10,153,118,255,177,70,25,0,165,87,205,0,55,138,234,0,238,30,97,0,113,155,207,0,98,153,127,0,34,107,219,254,117,114,172,255,76,180,255,254,242,57,179,255,221,34,172,254,56,162,49,255,83,3,255,255,113,221,189,255,188,25,228,254,16,88,89,255,71,28,198,254,22,17,149,255,243,121,254,255,107,202,99,255,9,206,14,1,220,47,153,0,107,137,39,1,97,49,194,255,149,51,197,254,186,58,11,255,107,43,232,1,200,6,14,255,181,133,65,254,221,228,171,255,123,62,231,1,227,234,179,255,34,189,212,254,244,187,249,0,190,13,80,1,130,89,1,0,223,133,173,0,9,222,198,255,66,127,74,0,167,216,93,255,155,168,198,1,66,145,0,0,68,102,46,1,172,90,154,0,216,128,75,255,160,40,51,0,158,17,27,1,124,240,49,0,236,202,176,255,151,124,192,255,38,193,190,0,95,182,61,0,163,147,124,255,255,165,51,255,28,40,17,254,215,96,78,0,86,145,218,254,31,36,202,255,86,9,5,0,111,41,200,255,237,108,97,0,57,62,44,0,117,184,15,1,45,241,116,0,152,1,220,255,157,165,188,0,250,15,131,1,60,44,125,255,65,220,251,255,75,50,184,0,53,90,128,255,231,80,194,255,136,129,127,1,21,18,187,255,45,58,161,255,71,147,34,0,174,249,11,254,35,141,29,0,239,68,177,255,115,110,58,0,238,190,177,1,87,245,166,255,190,49,247,255,146,83,184,255,173,14,39,255,146,215,104,0,142,223,120,0,149,200,155,255,212,207,145,1,16,181,217,0,173,32,87,255,255,35,181,0,119,223,161,1,200,223,94,255,70,6,186,255,192,67,85,255,50,169,152,0,144,26,123,255,56,243,179,254,20,68,136,0,39,140,188,254,253,208,5,255,200,115,135,1,43,172,229,255,156,104,187,0,151,251,167,0,52,135,23,0,151,153,72,0,147,197,107,254,148,158,5,255,238,143,206,0,126,153,137,255,88,152,197,254,7,68,167,0,252,159,165,255,239,78,54,255,24,63,55,255,38,222,94,0,237,183,12,255,206,204,210,0,19,39,246,254,30,74,231,0,135,108,29,1,179,115,0,0,117,118,116,1,132,6,252,255,145,129,161,1,105,67,141,0,82,37,226,255,238,226,228,255,204,214,129,254,162,123,100,255,185,121,234,0,45,108,231,0,66,8,56,255,132,136,128,0,172,224,66,254,175,157,188,0,230,223,226,254,242,219,69,0,184,14,119,1,82,162,56,0,114,123,20,0,162,103,85,255,49,239,99,254,156,135,215,0,111,255,167,254,39,196,214,0,144,38,79,1,249,168,125,0,155,97,156,255,23,52,219,255,150,22,144,0,44,149,165,255,40,127,183,0,196,77,233,255,118,129,210,255,170,135,230,255,214,119,198,0,233,240,35,0,253,52,7,255,117,102,48,255,21,204,154,255,179,136,177,255,23,2,3,1,149,130,89,255,252,17,159,1,70,60,26,0,144,107,17,0,180,190,60,255,56,182,59,255,110,71,54,255,198,18,129,255,149,224,87,255,223,21,152,255,138,22,182,255,250,156,205,0,236,45,208,255,79,148,242,1,101,70,209,0,103,78,174,0,101,144,172,255,152,136,237,1,191,194,136,0,113,80,125,1,152,4,141,0,155,150,53,255,196,116,245,0,239,114,73,254,19,82,17,255,124,125,234,255,40,52,191,0,42,210,158,255,155,132,165,0,178,5,42,1,64,92,40,255,36,85,77,255,178,228,118,0,137,66,96,254,115,226,66,0,110,240,69,254,151,111,80,0,167,174,236,255,227,108,107,255,188,242,65,255,183,81,255,0,57,206,181,255,47,34,181,255,213,240,158,1,71,75,95,0,156,40,24,255,102,210,81,0,171,199,228,255,154,34,41,0,227,175,75,0,21,239,195,0,138,229,95,1,76,192,49,0,117,123,87,1,227,225,130,0,125,62,63,255,2,198,171,0,254,36,13,254,145,186,206,0,148,255,244,255,35,0,166,0,30,150,219,1,92,228,212,0,92,198,60,254,62,133,200,255,201,41,59,0,125,238,109,255,180,163,238,1,140,122,82,0,9,22,88,255,197,157,47,255,153,94,57,0,88,30,182,0,84,161,85,0,178,146,124,0,166,166,7,255,21,208,223,0,156,182,242,0,155,121,185,0,83,156,174,254,154,16,118,255,186,83,232,1,223,58,121,255,29,23,88,0,35,125,127,255,170,5,149,254,164,12,130,255,155,196,29,0,161,96,136,0,7,35,29,1,162,37,251,0,3,46,242,255,0,217,188,0,57,174,226,1,206,233,2,0,57,187,136,254,123,189,9,255,201,117,127,255,186,36,204,0,231,25,216,0,80,78,105,0,19,134,129,255,148,203,68,0,141,81,125,254,248,165,200,255,214,144,135,0,151,55,166,255,38,235,91,0,21,46,154,0,223,254,150,255,35,153,180,255,125,176,29,1,43,98,30,255,216,122,230,255,233,160,12,0,57,185,12,254,240,113,7,255,5,9,16,254,26,91,108,0,109,198,203,0,8,147,40,0,129,134,228,255,124,186,40,255,114,98,132,254,166,132,23,0,99,69,44,0,9,242,238,255,184,53,59,0,132,129,102,255,52,32,243,254,147,223,200,255,123,83,179,254,135,144,201,255,141,37,56,1,151,60,227,255,90,73,156,1,203,172,187,0,80,151,47,255,94,137,231,255,36,191,59,255,225,209,181,255,74,215,213,254,6,118,179,255,153,54,193,1,50,0,231,0,104,157,72,1,140,227,154,255,182,226,16,254,96,225,92,255,115,20,170,254,6,250,78,0,248,75,173,255,53,89,6,255,0,180,118,0,72,173,1,0,64,8,206,1,174,133,223,0,185,62,133,255,214,11,98,0,197,31,208,0,171,167,244,255,22,231,181,1,150,218,185,0,247,169,97,1,165,139,247,255,47,120,149,1,103,248,51,0,60,69,28,254,25,179,196,0,124,7,218,254,58,107,81,0,184,233,156,255,252,74,36,0,118,188,67,0,141,95,53,255,222,94,165,254,46,61,53,0,206,59,115,255,47,236,250,255,74,5,32,1,129,154,238,255,106,32,226,0,121,187,61,255,3,166,241,254,67,170,172,255,29,216,178,255,23,201,252,0,253,110,243,0,200,125,57,0,109,192,96,255,52,115,238,0,38,121,243,255,201,56,33,0,194,118,130,0,75,96,25,255,170,30,230,254,39,63,253,0,36,45,250,255,251,1,239,0,160,212,92,1,45,209,237,0,243,33,87,254,237,84,201,255,212,18,157,254,212,99,127,255,217,98,16,254,139,172,239,0,168,201,130,255,143,193,169,255,238,151,193,1,215,104,41,0,239,61,165,254,2,3,242,0,22,203,177,254,177,204,22,0,149,129,213,254,31,11,41,255,0,159,121,254,160,25,114,255,162,80,200,0,157,151,11,0,154,134,78,1,216,54,252,0,48,103,133,0,105,220,197,0,253,168,77,254,53,179,23,0,24,121,240,1,255,46,96,255,107,60,135,254,98,205,249,255,63,249,119,255,120,59,211,255,114,180,55,254,91,85,237,0,149,212,77,1,56,73,49,0,86,198,150,0,93,209,160,0,69,205,182,255,244,90,43,0,20,36,176,0,122,116,221,0,51,167,39,1,231,1,63,255,13,197,134,0,3,209,34,255,135,59,202,0,167,100,78,0,47,223,76,0,185,60,62,0,178,166,123,1,132,12,161,255,61,174,43,0,195,69,144,0,127,47,191,1,34,44,78,0,57,234,52,1,255,22,40,255,246,94,146,0,83,228,128,0,60,78,224,255,0,96,210,255,153,175,236,0,159,21,73,0,180,115,196,254,131,225,106,0,255,167,134,0,159,8,112,255,120,68,194,255,176,196,198,255,118,48,168,255,93,169,1,0,112,200,102,1,74,24,254,0,19,141,4,254,142,62,63,0,131,179,187,255,77,156,155,255,119,86,164,0,170,208,146,255,208,133,154,255,148,155,58,255,162,120,232,254,252,213,155,0,241,13,42,0,94,50,131,0,179,170,112,0,140,83,151,255,55,119,84,1,140,35,239,255,153,45,67,1,236,175,39,0,54,151,103,255,158,42,65,255,196,239,135,254,86,53,203,0,149,97,47,254,216,35,17,255,70,3,70,1,103,36,90,255,40,26,173,0,184,48,13,0,163,219,217,255,81,6,1,255,221,170,108,254,233,208,93,0,100,201,249,254,86,36,35,255,209,154,30,1,227,201,251,255,2,189,167,254,100,57,3,0,13,128,41,0,197,100,75,0,150,204,235,255,145,174,59,0,120,248,149,255,85,55,225,0,114,210,53,254,199,204,119,0,14,247,74,1,63,251,129,0,67,104,151,1,135,130,80,0,79,89,55,255,117,230,157,255,25,96,143,0,213,145,5,0,69,241,120,1,149,243,95,255,114,42,20,0,131,72,2,0,154,53,20,255,73,62,109,0,196,102,152,0,41,12,204,255,122,38,11,1,250,10,145,0,207,125,148,0,246,244,222,255,41,32,85,1,112,213,126,0,162,249,86,1,71,198,127,255,81,9,21,1,98,39,4,255,204,71,45,1,75,111,137,0,234,59,231,0,32,48,95,255,204,31,114,1,29,196,181,255,51,241,167,254,93,109,142,0,104,144,45,0,235,12,181,255,52,112,164,0,76,254,202,255,174,14,162,0,61,235,147,255,43,64,185,254,233,125,217,0,243,88,167,254,74,49,8,0,156,204,66,0,124,214,123,0,38,221,118,1,146,112,236,0,114,98,177,0,151,89,199,0,87,197,112,0,185,149,161,0,44,96,165,0,248,179,20,255,188,219,216,254,40,62,13,0,243,142,141,0,229,227,206,255,172,202,35,255,117,176,225,255,82,110,38,1,42,245,14,255,20,83,97,0,49,171,10,0,242,119,120,0,25,232,61,0,212,240,147,255,4,115,56,255,145,17,239,254,202,17,251,255,249,18,245,255,99,117,239,0,184,4,179,255,246,237,51,255,37,239,137,255,166,112,166,255,81,188,33,255,185,250,142,255,54,187,173,0,208,112,201,0,246,43,228,1,104,184,88,255,212,52,196,255,51,117,108,255,254,117,155,0,46,91,15,255,87,14,144,255,87,227,204,0,83,26,83,1,159,76,227,0,159,27,213,1,24,151,108,0,117,144,179,254,137,209,82,0,38,159,10,0,115,133,201,0,223,182,156,1,110,196,93,255,57,60,233,0,5,167,105,255,154,197,164,0,96,34,186,255,147,133,37,1,220,99,190,0,1,167,84,255,20,145,171,0,194,197,251,254,95,78,133,255,252,248,243,255,225,93,131,255,187,134,196,255,216,153,170,0,20,118,158,254,140,1,118,0,86,158,15,1,45,211,41,255,147,1,100,254,113,116,76,255,211,127,108,1,103,15,48,0,193,16,102,1,69,51,95,255,107,128,157,0,137,171,233,0,90,124,144,1,106,161,182,0,175,76,236,1,200,141,172,255,163,58,104,0,233,180,52,255,240,253,14,255,162,113,254,255,38,239,138,254,52,46,166,0,241,101,33,254,131,186,156,0,111,208,62,255,124,94,160,255,31,172,254,0,112,174,56,255,188,99,27,255,67,138,251,0,125,58,128,1,156,152,174,255,178,12,247,255,252,84,158,0,82,197,14,254,172,200,83,255,37,39,46,1,106,207,167,0,24,189,34,0,131,178,144,0,206,213,4,0,161,226,210,0,72,51,105,255,97,45,187,255,78,184,223,255,176,29,251,0,79,160,86,255,116,37,178,0,82,77,213,1,82,84,141,255,226,101,212,1,175,88,199,255,245,94,247,1,172,118,109,255,166,185,190,0,131,181,120,0,87,254,93,255,134,240,73,255,32,245,143,255,139,162,103,255,179,98,18,254,217,204,112,0,147,223,120,255,53,10,243,0,166,140,150,0,125,80,200,255,14,109,219,255,91,218,1,255,252,252,47,254,109,156,116,255,115,49,127,1,204,87,211,255,148,202,217,255,26,85,249,255,14,245,134,1,76,89,169,255,242,45,230,0,59,98,172,255,114,73,132,254,78,155,49,255,158,126,84,0,49,175,43,255,16,182,84,255,157,103,35,0,104,193,109,255,67,221,154],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+10240);allocate([201,172,1,254,8,162,88,0,165,1,29,255,125,155,229,255,30,154,220,1,103,239,92,0,220,1,109,255,202,198,1,0,94,2,142,1,36,54,44,0,235,226,158,255,170,251,214,255,185,77,9,0,97,74,242,0,219,163,149,255,240,35,118,255,223,114,88,254,192,199,3,0,106,37,24,255,201,161,118,255,97,89,99,1,224,58,103,255,101,199,147,254,222,60,99,0,234,25,59,1,52,135,27,0,102,3,91,254,168,216,235,0,229,232,136,0,104,60,129,0,46,168,238,0,39,191,67,0,75,163,47,0,143,97,98,255,56,216,168,1,168,233,252,255,35,111,22,255,92,84,43,0,26,200,87,1,91,253,152,0,202,56,70,0,142,8,77,0,80,10,175,1,252,199,76,0,22,110,82,255,129,1,194,0,11,128,61,1,87,14,145,255,253,222,190,1,15,72,174,0,85,163,86,254,58,99,44,255,45,24,188,254,26,205,15,0,19,229,210,254,248,67,195,0,99,71,184,0,154,199,37,255,151,243,121,255,38,51,75,255,201,85,130,254,44,65,250,0,57,147,243,254,146,43,59,255,89,28,53,0,33,84,24,255,179,51,18,254,189,70,83,0,11,156,179,1,98,134,119,0,158,111,111,0,119,154,73,255,200,63,140,254,45,13,13,255,154,192,2,254,81,72,42,0,46,160,185,254,44,112,6,0,146,215,149,1,26,176,104,0,68,28,87,1,236,50,153,255,179,128,250,254,206,193,191,255,166,92,137,254,53,40,239,0,210,1,204,254,168,173,35,0,141,243,45,1,36,50,109,255,15,242,194,255,227,159,122,255,176,175,202,254,70,57,72,0,40,223,56,0,208,162,58,255,183,98,93,0,15,111,12,0,30,8,76,255,132,127,246,255,45,242,103,0,69,181,15,255,10,209,30,0,3,179,121,0,241,232,218,1,123,199,88,255,2,210,202,1,188,130,81,255,94,101,208,1,103,36,45,0,76,193,24,1,95,26,241,255,165,162,187,0,36,114,140,0,202,66,5,255,37,56,147,0,152,11,243,1,127,85,232,255,250,135,212,1,185,177,113,0,90,220,75,255,69,248,146,0,50,111,50,0,92,22,80,0,244,36,115,254,163,100,82,255,25,193,6,1,127,61,36,0,253,67,30,254,65,236,170,255,161,17,215,254,63,175,140,0,55,127,4,0,79,112,233,0,109,160,40,0,143,83,7,255,65,26,238,255,217,169,140,255,78,94,189,255,0,147,190,255,147,71,186,254,106,77,127,255,233,157,233,1,135,87,237,255,208,13,236,1,155,109,36,255,180,100,218,0,180,163,18,0,190,110,9,1,17,63,123,255,179,136,180,255,165,123,123,255,144,188,81,254,71,240,108,255,25,112,11,255,227,218,51,255,167,50,234,255,114,79,108,255,31,19,115,255,183,240,99,0,227,87,143,255,72,217,248,255,102,169,95,1,129,149,149,0,238,133,12,1,227,204,35,0,208,115,26,1,102,8,234,0,112,88,143,1,144,249,14,0,240,158,172,254,100,112,119,0,194,141,153,254,40,56,83,255,121,176,46,0,42,53,76,255,158,191,154,0,91,209,92,0,173,13,16,1,5,72,226,255,204,254,149,0,80,184,207,0,100,9,122,254,118,101,171,255,252,203,0,254,160,207,54,0,56,72,249,1,56,140,13,255,10,64,107,254,91,101,52,255,225,181,248,1,139,255,132,0,230,145,17,0,233,56,23,0,119,1,241,255,213,169,151,255,99,99,9,254,185,15,191,255,173,103,109,1,174,13,251,255,178,88,7,254,27,59,68,255,10,33,2,255,248,97,59,0,26,30,146,1,176,147,10,0,95,121,207,1,188,88,24,0,185,94,254,254,115,55,201,0,24,50,70,0,120,53,6,0,142,66,146,0,228,226,249,255,104,192,222,1,173,68,219,0,162,184,36,255,143,102,137,255,157,11,23,0,125,45,98,0,235,93,225,254,56,112,160,255,70,116,243,1,153,249,55,255,129,39,17,1,241,80,244,0,87,69,21,1,94,228,73,255,78,66,65,255,194,227,231,0,61,146,87,255,173,155,23,255,112,116,219,254,216,38,11,255,131,186,133,0,94,212,187,0,100,47,91,0,204,254,175,255,222,18,215,254,173,68,108,255,227,228,79,255,38,221,213,0,163,227,150,254,31,190,18,0,160,179,11,1,10,90,94,255,220,174,88,0,163,211,229,255,199,136,52,0,130,95,221,255,140,188,231,254,139,113,128,255,117,171,236,254,49,220,20,255,59,20,171,255,228,109,188,0,20,225,32,254,195,16,174,0,227,254,136,1,135,39,105,0,150,77,206,255,210,238,226,0,55,212,132,254,239,57,124,0,170,194,93,255,249,16,247,255,24,151,62,255,10,151,10,0,79,139,178,255,120,242,202,0,26,219,213,0,62,125,35,255,144,2,108,255,230,33,83,255,81,45,216,1,224,62,17,0,214,217,125,0,98,153,153,255,179,176,106,254,131,93,138,255,109,62,36,255,178,121,32,255,120,252,70,0,220,248,37,0,204,88,103,1,128,220,251,255,236,227,7,1,106,49,198,255,60,56,107,0,99,114,238,0,220,204,94,1,73,187,1,0,89,154,34,0,78,217,165,255,14,195,249,255,9,230,253,255,205,135,245,0,26,252,7,255,84,205,27,1,134,2,112,0,37,158,32,0,231,91,237,255,191,170,204,255,152,7,222,0,109,192,49,0,193,166,146,255,232,19,181,255,105,142,52,255,103,16,27,1,253,200,165,0,195,217,4,255,52,189,144,255,123,155,160,254,87,130,54,255,78,120,61,255,14,56,41,0,25,41,125,255,87,168,245,0,214,165,70,0,212,169,6,255,219,211,194,254,72,93,164,255,197,33,103,255,43,142,141,0,131,225,172,0,244,105,28,0,68,68,225,0,136,84,13,255,130,57,40,254,139,77,56,0,84,150,53,0,54,95,157,0,144,13,177,254,95,115,186,0,117,23,118,255,244,166,241,255,11,186,135,0,178,106,203,255,97,218,93,0,43,253,45,0,164,152,4,0,139,118,239,0,96,1,24,254,235,153,211,255,168,110,20,255,50,239,176,0,114,41,232,0,193,250,53,0,254,160,111,254,136,122,41,255,97,108,67,0,215,152,23,255,140,209,212,0,42,189,163,0,202,42,50,255,106,106,189,255,190,68,217,255,233,58,117,0,229,220,243,1,197,3,4,0,37,120,54,254,4,156,134,255,36,61,171,254,165,136,100,255,212,232,14,0,90,174,10,0,216,198,65,255,12,3,64,0,116,113,115,255,248,103,8,0,231,125,18,255,160,28,197,0,30,184,35,1,223,73,249,255,123,20,46,254,135,56,37,255,173,13,229,1,119,161,34,255,245,61,73,0,205,125,112,0,137,104,134,0,217,246,30,255,237,142,143,0,65,159,102,255,108,164,190,0,219,117,173,255,34,37,120,254,200,69,80,0,31,124,218,254,74,27,160,255,186,154,199,255,71,199,252,0,104,81,159,1,17,200,39,0,211,61,192,1,26,238,91,0,148,217,12,0,59,91,213,255,11,81,183,255,129,230,122,255,114,203,145,1,119,180,66,255,72,138,180,0,224,149,106,0,119,82,104,255,208,140,43,0,98,9,182,255,205,101,134,255,18,101,38,0,95,197,166,255,203,241,147,0,62,208,145,255,133,246,251,0,2,169,14,0,13,247,184,0,142,7,254,0,36,200,23,255,88,205,223,0,91,129,52,255,21,186,30,0,143,228,210,1,247,234,248,255,230,69,31,254,176,186,135,255,238,205,52,1,139,79,43,0,17,176,217,254,32,243,67,0,242,111,233,0,44,35,9,255,227,114,81,1,4,71,12,255,38,105,191,0,7,117,50,255,81,79,16,0,63,68,65,255,157,36,110,255,77,241,3,255,226,45,251,1,142,25,206,0,120,123,209,1,28,254,238,255,5,128,126,255,91,222,215,255,162,15,191,0,86,240,73,0,135,185,81,254,44,241,163,0,212,219,210,255,112,162,155,0,207,101,118,0,168,72,56,255,196,5,52,0,72,172,242,255,126,22,157,255,146,96,59,255,162,121,152,254,140,16,95,0,195,254,200,254,82,150,162,0,119,43,145,254,204,172,78,255,166,224,159,0,104,19,237,255,245,126,208,255,226,59,213,0,117,217,197,0,152,72,237,0,220,31,23,254,14,90,231,255,188,212,64,1,60,101,246,255,85,24,86,0,1,177,109,0,146,83,32,1,75,182,192,0,119,241,224,0,185,237,27,255,184,101,82,1,235,37,77,255,253,134,19,0,232,246,122,0,60,106,179,0,195,11,12,0,109,66,235,1,125,113,59,0,61,40,164,0,175,104,240,0,2,47,187,255,50,12,141,0,194,139,181,255,135,250,104,0,97,92,222,255,217,149,201,255,203,241,118,255,79,151,67,0,122,142,218,255,149,245,239,0,138,42,200,254,80,37,97,255,124,112,167,255,36,138,87,255,130,29,147,255,241,87,78,255,204,97,19,1,177,209,22,255,247,227,127,254,99,119,83,255,212,25,198,1,16,179,179,0,145,77,172,254,89,153,14,255,218,189,167,0,107,233,59,255,35,33,243,254,44,112,112,255,161,127,79,1,204,175,10,0,40,21,138,254,104,116,228,0,199,95,137,255,133,190,168,255,146,165,234,1,183,99,39,0,183,220,54,254,255,222,133,0,162,219,121,254,63,239,6,0,225,102,54,255,251,18,246,0,4,34,129,1,135,36,131,0,206,50,59,1,15,97,183,0,171,216,135,255,101,152,43,255,150,251,91,0,38,145,95,0,34,204,38,254,178,140,83,255,25,129,243,255,76,144,37,0,106,36,26,254,118,144,172,255,68,186,229,255,107,161,213,255,46,163,68,255,149,170,253,0,187,17,15,0,218,160,165,255,171,35,246,1,96,13,19,0,165,203,117,0,214,107,192,255,244,123,177,1,100,3,104,0,178,242,97,255,251,76,130,255,211,77,42,1,250,79,70,255,63,244,80,1,105,101,246,0,61,136,58,1,238,91,213,0,14,59,98,255,167,84,77,0,17,132,46,254,57,175,197,255,185,62,184,0,76,64,207,0,172,175,208,254,175,74,37,0,138,27,211,254,148,125,194,0,10,89,81,0,168,203,101,255,43,213,209,1,235,245,54,0,30,35,226,255,9,126,70,0,226,125,94,254,156,117,20,255,57,248,112,1,230,48,64,255,164,92,166,1,224,214,230,255,36,120,143,0,55,8,43,255,251,1,245,1,106,98,165,0,74,107,106,254,53,4,54,255,90,178,150,1,3,120,123,255,244,5,89,1,114,250,61,255,254,153,82,1,77,15,17,0,57,238,90,1,95,223,230,0,236,52,47,254,103,148,164,255,121,207,36,1,18,16,185,255,75,20,74,0,187,11,101,0,46,48,129,255,22,239,210,255,77,236,129,255,111,77,204,255,61,72,97,255,199,217,251,255,42,215,204,0,133,145,201,255,57,230,146,1,235,100,198,0,146,73,35,254,108,198,20,255,182,79,210,255,82,103,136,0,246,108,176,0,34,17,60,255,19,74,114,254,168,170,78,255,157,239,20,255,149,41,168,0,58,121,28,0,79,179,134,255,231,121,135,255,174,209,98,255,243,122,190,0,171,166,205,0,212,116,48,0,29,108,66,255,162,222,182,1,14,119,21,0,213,39,249,255,254,223,228,255,183,165,198,0,133,190,48,0,124,208,109,255,119,175,85,255,9,209,121,1,48,171,189,255,195,71,134,1,136,219,51,255,182,91,141,254,49,159,72,0,35,118,245,255,112,186,227,255,59,137,31,0,137,44,163,0,114,103,60,254,8,213,150,0,162,10,113,255,194,104,72,0,220,131,116,255,178,79,92,0,203,250,213,254,93,193,189,255,130,255,34,254,212,188,151,0,136,17,20,255,20,101,83,255,212,206,166,0,229,238,73,255,151,74,3,255,168,87,215,0,155,188,133,255,166,129,73,0,240,79,133,255,178,211,81,255,203,72,163,254,193,168,165,0,14,164,199,254,30,255,204,0,65,72,91,1,166,74,102,255,200,42,0,255,194,113,227,255,66,23,208,0,229,216,100,255,24,239,26,0,10,233,62,255,123,10,178,1,26,36,174,255,119,219,199,1,45,163,190,0,16,168,42,0,166,57,198,255,28,26,26,0,126,165,231,0,251,108,100,255,61,229,121,255,58,118,138,0,76,207,17,0,13,34,112,254,89,16,168,0,37,208,105,255,35,201,215,255,40,106,101,254,6,239,114,0,40,103,226,254,246,127,110,255,63,167,58,0,132,240,142,0,5,158,88,255,129,73,158,255,94,89,146,0,230,54,146,0,8,45,173,0,79,169,1,0,115,186,247,0,84,64,131,0,67,224,253,255,207,189,64,0,154,28,81,1,45,184,54,255,87,212,224,255,0,96,73,255,129,33,235,1,52,66,80,255,251,174,155,255,4,179,37,0,234,164,93,254,93,175,253,0,198,69,87,255,224,106,46,0,99,29,210,0,62,188,114,255,44,234,8,0,169,175,247,255,23,109,137,255,229,182,39,0,192,165,94,254,245,101,217,0,191,88,96,0,196,94,99,255,106,238,11,254,53,126,243,0,94,1,101,255,46,147,2,0,201,124,124,255,141,12,218,0,13,166,157,1,48,251,237,255,155,250,124,255,106,148,146,255,182,13,202,0,28,61,167,0,217,152,8,254,220,130,45,255,200,230,255,1,55,65,87,255,93,191,97,254,114,251,14,0,32,105,92,1,26,207,141,0,24,207,13,254,21,50,48,255,186,148,116,255,211,43,225,0,37,34,162,254,164,210,42,255,68,23,96,255,182,214,8,255,245,117,137,255,66,195,50,0,75,12,83,254,80,140,164,0,9,165,36,1,228,110,227,0,241,17,90,1,25,52,212,0,6,223,12,255,139,243,57,0,12,113,75,1,246,183,191,255,213,191,69,255,230,15,142,0,1,195,196,255,138,171,47,255,64,63,106,1,16,169,214,255,207,174,56,1,88,73,133,255,182,133,140,0,177,14,25,255,147,184,53,255,10,227,161,255,120,216,244,255,73,77,233,0,157,238,139,1,59,65,233,0,70,251,216,1,41,184,153,255,32,203,112,0,146,147,253,0,87,101,109,1,44,82,133,255,244,150,53,255,94,152,232,255,59,93,39,255,88,147,220,255,78,81,13,1,32,47,252,255,160,19,114,255,93,107,39,255,118,16,211,1,185,119,209,255,227,219,127,254,88,105,236,255,162,110,23,255,36,166,110,255,91,236,221,255,66,234,116,0,111,19,244,254,10,233,26,0,32,183,6,254,2,191,242,0,218,156,53,254,41,60,70,255,168,236,111,0,121,185,126,255,238,142,207,255,55,126,52,0,220,129,208,254,80,204,164,255,67,23,144,254,218,40,108,255,127,202,164,0,203,33,3,255,2,158,0,0,37,96,188,255,192,49,74,0,109,4,0,0,111,167,10,254,91,218,135,255,203,66,173,255,150,194,226,0,201,253,6,255,174,102,121,0,205,191,110,0,53,194,4,0,81,40,45,254,35,102,143,255,12,108,198,255,16,27,232,255,252,71,186,1,176,110,114,0,142,3,117,1,113,77,142,0,19,156,197,1,92,47,252,0,53,232,22,1,54,18,235,0,46,35,189,255,236,212,129,0,2,96,208,254,200,238,199,255,59,175,164,255,146,43,231,0,194,217,52,255,3,223,12,0,138,54,178,254,85,235,207,0,232,207,34,0,49,52,50,255,166,113,89,255,10,45,216,255,62,173,28,0,111,165,246,0,118,115,91,255,128,84,60,0,167,144,203,0,87,13,243,0,22,30,228,1,177,113,146,255,129,170,230,254,252,153,129,255,145,225,43,0,70,231,5,255,122,105,126,254,86,246,148,255,110,37,154,254,209,3,91,0,68,145,62,0,228,16,165,255,55,221,249,254,178,210,91,0,83,146,226,254,69,146,186,0,93,210,104,254,16,25,173,0,231,186,38,0,189,122,140,255,251,13,112,255,105,110,93,0,251,72,170,0,192,23,223,255,24,3,202,1,225,93,228,0,153,147,199,254,109,170,22,0,248,101,246,255,178,124,12,255,178,254,102,254,55,4,65,0,125,214,180,0,183,96,147,0,45,117,23,254,132,191,249,0,143,176,203,254,136,183,54,255,146,234,177,0,146,101,86,255,44,123,143,1,33,209,152,0,192,90,41,254,83,15,125,255,213,172,82,0,215,169,144,0,16,13,34,0,32,209,100,255,84,18,249,1,197,17,236,255,217,186,230,0,49,160,176,255,111,118,97,255,237,104,235,0,79,59,92,254,69,249,11,255,35,172,74,1,19,118,68,0,222,124,165,255,180,66,35,255,86,174,246,0,43,74,111,255,126,144,86,255,228,234,91,0,242,213,24,254,69,44,235,255,220,180,35,0,8,248,7,255,102,47,92,255,240,205,102,255,113,230,171,1,31,185,201,255,194,246,70,255,122,17,187,0,134,70,199,255,149,3,150,255,117,63,103,0,65,104,123,255,212,54,19,1,6,141,88,0,83,134,243,255,136,53,103,0,169,27,180,0,177,49,24,0,111,54,167,0,195,61,215,255,31,1,108,1,60,42,70,0,185,3,162,255,194,149,40,255,246,127,38,254,190,119,38,255,61,119,8,1,96,161,219,255,42,203,221,1,177,242,164,255,245,159,10,0,116,196,0,0,5,93,205,254,128,127,179,0,125,237,246,255,149,162,217,255,87,37,20,254,140,238,192,0,9,9,193,0,97,1,226,0,29,38,10,0,0,136,63,255,229,72,210,254,38,134,92,255,78,218,208,1,104,36,84,255,12,5,193,255,242,175,61,255,191,169,46,1,179,147,147,255,113,190,139,254,125,172,31,0,3,75,252,254,215,36,15,0,193,27,24,1,255,69,149,255,110,129,118,0,203,93,249,0,138,137,64,254,38,70,6,0,153,116,222,0,161,74,123,0,193,99,79,255,118,59,94,255,61,12,43,1,146,177,157,0,46,147,191,0,16,255,38,0,11,51,31,1,60,58,98,255,111,194,77,1,154,91,244,0,140,40,144,1,173,10,251,0,203,209,50,254,108,130,78,0,228,180,90,0,174,7,250,0,31,174,60,0,41,171,30,0,116,99,82,255,118,193,139,255,187,173,198,254,218,111,56,0,185,123,216,0,249,158,52,0,52,180,93,255,201,9,91,255,56,45,166,254,132,155,203,255,58,232,110,0,52,211,89,255,253,0,162,1,9,87,183,0,145,136,44,1,94,122,245,0,85,188,171,1,147,92,198,0,0,8,104,0,30,95,174,0,221,230,52,1,247,247,235,255,137,174,53,255,35,21,204,255,71,227,214,1,232,82,194,0,11,48,227,255,170,73,184,255,198,251,252,254,44,112,34,0,131,101,131,255,72,168,187,0,132,135,125,255,138,104,97,255,238,184,168,255,243,104,84,255,135,216,226,255,139,144,237,0,188,137,150,1,80,56,140,255,86,169,167,255,194,78,25,255,220,17,180,255,17,13,193,0,117,137,212,255,141,224,151,0,49,244,175,0,193,99,175,255,19,99,154,1,255,65,62,255,156,210,55,255,242,244,3,255,250,14,149,0,158,88,217,255,157,207,134,254,251,232,28,0,46,156,251,255,171,56,184,255,239,51,234,0,142,138,131,255,25,254,243,1,10,201,194,0,63,97,75,0,210,239,162,0,192,200,31,1,117,214,243,0,24,71,222,254,54,40,232,255,76,183,111,254,144,14,87,255,214,79,136,255,216,196,212,0,132,27,140,254,131,5,253,0,124,108,19,255,28,215,75,0,76,222,55,254,233,182,63,0,68,171,191,254,52,111,222,255,10,105,77,255,80,170,235,0,143,24,88,255,45,231,121,0,148,129,224,1,61,246,84,0,253,46,219,255,239,76,33,0,49,148,18,254,230,37,69,0,67,134,22,254,142,155,94,0,31,157,211,254,213,42,30,255,4,228,247,254,252,176,13,255,39,0,31,254,241,244,255,255,170,45,10,254,253,222,249,0,222,114,132,0,255,47,6,255,180,163,179,1,84,94,151,255,89,209,82,254,229,52,169,255,213,236,0,1,214,56,228,255,135,119,151,255,112,201,193,0,83,160,53,254,6,151,66,0,18,162,17,0,233,97,91,0,131,5,78,1,181,120,53,255,117,95,63,255,237,117,185,0,191,126,136,255,144,119,233,0,183,57,97,1,47,201,187,255,167,165,119,1,45,100,126,0,21,98,6,254,145,150,95,255,120,54,152,0,209,98,104,0,143,111,30,254,184,148,249,0,235,216,46,0,248,202,148,255,57,95,22,0,242,225,163,0,233,247,232,255,71,171,19,255,103,244,49,255,84,103,93,255,68,121,244,1,82,224,13,0,41,79,43,255,249,206,167,255,215,52,21,254,192,32,22,255,247,111,60,0,101,74,38,255,22,91,84,254,29,28,13,255,198,231,215,254,244,154,200,0,223,137,237,0,211,132,14,0,95,64,206,255,17,62,247,255,233,131,121,1,93,23,77,0,205,204,52,254,81,189,136,0,180,219,138,1,143,18,94,0,204,43,140,254,188,175,219,0,111,98,143,255,151,63,162,255,211,50,71,254,19,146,53,0,146,45,83,254,178,82,238,255,16,133,84,255,226,198,93,255,201,97,20,255,120,118,35,255,114,50,231,255,162,229,156,255,211,26,12,0,114,39,115,255,206,212,134,0,197,217,160,255,116,129,94,254,199,215,219,255,75,223,249,1,253,116,181,255,232,215,104,255,228,130,246,255,185,117,86,0,14,5,8,0,239,29,61,1,237,87,133,255,125,146,137,254,204,168,223,0,46,168,245,0,154,105,22,0,220,212,161,255,107,69,24,255,137,218,181,255,241,84,198,255,130,122,211,255,141,8,153,255,190,177,118,0,96,89,178,0,255,16,48,254,122,96,105,255,117,54,232,255,34,126,105,255,204,67,166,0,232,52,138,255,211,147,12,0,25,54,7,0,44,15,215,254,51,236,45,0,190,68,129,1,106,147,225,0,28,93,45,254,236,141,15,255,17,61,161,0,220,115,192,0,236,145,24,254,111,168,169,0,224,58,63,255,127,164,188,0,82,234,75,1,224,158,134,0,209,68,110,1,217,166,217,0,70,225,166,1,187,193,143,255,16,7,88,255,10,205,140,0,117,192,156,1,17,56,38,0,27,124,108,1,171,215,55,255,95,253,212,0,155,135,168,255,246,178,153,254,154,68,74,0,232,61,96,254,105,132,59,0,33,76,199,1,189,176,130,255,9,104,25,254,75,198,102,255,233,1,112,0,108,220,20,255,114,230,70,0,140,194,133,255,57,158,164,254,146,6,80,255,169,196,97,1,85,183,130,0,70,158,222,1,59,237,234,255,96,25,26,255,232,175,97,255,11,121,248,254,88,35,194,0,219,180,252,254,74,8,227,0,195,227,73,1,184,110,161,255,49,233,164,1,128,53,47,0,82,14,121,255,193,190,58,0,48,174,117,255,132,23,32,0,40,10,134,1,22,51,25,255,240,11,176,255,110,57,146,0,117,143,239,1,157,101,118,255,54,84,76,0,205,184,18,255,47,4,72,255,78,112,85,255,193,50,66,1,93,16,52,255,8,105,134,0,12,109,72,255,58,156,251,0,144,35,204,0,44,160,117,254,50,107,194,0,1,68,165,255,111,110,162,0,158,83,40,254,76,214,234,0,58,216,205,255,171,96,147,255,40,227,114,1,176,227,241,0,70,249,183,1,136,84,139,255,60,122,247,254,143,9,117,255,177,174,137,254,73,247,143,0,236,185,126,255,62,25,247,255,45,64,56,255,161,244,6,0,34,57,56,1,105,202,83,0,128,147,208,0,6,103,10,255,74,138,65,255,97,80,100,255,214,174,33,255,50,134,74,255,110,151,130,254,111,84,172,0,84,199,75,254,248,59,112,255,8,216,178,1,9,183,95,0,238,27,8,254,170,205,220,0,195,229,135,0,98,76,237,255,226,91,26,1,82,219,39,255,225,190,199,1,217,200,121,255,81,179,8,255,140,65,206,0,178,207,87,254,250,252,46,255,104,89,110,1,253,189,158,255,144,214,158,255,160,245,54,255,53,183,92,1,21,200,194,255,146,33,113,1,209,1,255,0,235,106,43,255,167,52,232,0,157,229,221,0,51,30,25,0,250,221,27,1,65,147,87,255,79,123,196,0,65,196,223,255,76,44,17,1,85,241,68,0,202,183,249,255,65,212,212,255,9,33,154,1,71,59,80,0,175,194,59,255,141,72,9,0,100,160,244,0,230,208,56,0,59,25,75,254,80,194,194,0,18,3,200,254,160,159,115,0,132,143,247,1,111,93,57,255,58,237,11,1,134,222,135,255,122,163,108,1,123,43,190,255,251,189,206,254,80,182,72,255,208,246,224,1,17,60,9,0,161,207,38,0,141,109,91,0,216,15,211,255,136,78,110,0,98,163,104,255,21,80,121,255,173,178,183,1,127,143,4,0,104,60,82,254,214,16,13,255,96,238,33,1,158,148,230,255,127,129,62,255,51,255,210,255,62,141,236,254,157,55,224,255,114,39,244,0,192,188,250,255,228,76,53,0,98,84,81,255,173,203,61,254,147,50,55,255,204,235,191,0,52,197,244,0,88,43,211,254,27,191,119,0,188,231,154,0,66,81,161,0,92,193,160,1,250,227,120,0,123,55,226,0,184,17,72,0,133,168,10,254,22,135,156,255,41,25,103,255,48,202,58,0,186,149,81,255,188,134,239,0,235,181,189,254,217,139,188,255,74,48,82,0,46,218,229,0,189,253,251,0,50,229,12,255,211,141,191,1,128,244,25,255,169,231,122,254,86,47,189,255,132,183,23,255,37,178,150,255,51,137,253,0,200,78,31,0,22,105,50,0,130,60,0,0,132,163,91,254,23,231,187,0,192,79,239,0,157,102,164,255,192,82,20,1,24,181,103,255,240,9,234,0,1,123,164,255,133,233,0,255,202,242,242,0,60,186,245,0,241,16,199,255,224,116,158,254,191,125,91,255,224,86,207,0,121,37,231,255,227,9,198,255,15,153,239,255,121,232,217,254,75,112,82,0,95,12,57,254,51,214,105,255,148,220,97,1,199,98,36,0,156,209,12,254,10,212,52,0,217,180,55,254,212,170,232,255,216,20,84,255,157,250,135,0,157,99,127,254,1,206,41,0,149,36,70,1,54,196,201,255,87,116,0,254,235,171,150,0,27,163,234,0,202,135,180,0,208,95,0,254,123,156,93,0,183,62,75,0,137,235,182,0,204,225,255,255,214,139,210,255,2,115,8,255,29,12,111,0,52,156,1,0,253,21,251,255,37,165,31,254,12,130,211,0,106,18,53,254,42,99,154,0,14,217,61,254,216,11,92,255,200,197,112,254,147,38,199,0,36,252,120,254,107,169,77,0,1,123,159,255,207,75,102,0,163,175,196,0,44,1,240,0,120,186,176,254,13,98,76,255,237,124,241,255,232,146,188,255,200,96,224,0,204,31,41,0,208,200,13,0,21,225,96,255,175,156,196,0,247,208,126,0,62,184,244,254,2,171,81,0,85,115,158,0,54,64,45,255,19,138,114,0,135,71,205,0,227,47,147,1,218,231,66,0,253,209,28,0,244,15,173,255,6,15,118,254,16,150,208,255,185,22,50,255,86,112,207,255,75,113,215,1,63,146,43,255,4,225,19,254,227,23,62,255,14,255,214,254,45,8,205,255,87,197,151,254,210,82,215,255,245,248,247,255,128,248,70,0,225,247,87,0,90,120,70,0,213,245,92,0,13,133,226,0,47,181,5,1,92,163,105,255,6,30,133,254,232,178,61,255,230,149,24,255,18,49,158,0,228,100,61,254,116,243,251,255,77,75,92,1,81,219,147,255,76,163,254,254,141,213,246,0,232,37,152,254,97,44,100,0,201,37,50,1,212,244,57,0,174,171,183,255,249,74,112,0,166,156,30,0,222,221,97,255,243,93,73,254,251,101,100,255,216,217,93,255,254,138,187,255,142,190,52,255,59,203,177,255,200,94,52,0,115,114,158,255,165,152,104,1,126,99,226,255,118,157,244,1,107,200,16,0,193,90,229,0,121,6,88,0,156,32,93,254,125,241,211,255,14,237,157,255,165,154,21,255,184,224,22,255,250,24,152,255,113,77,31,0,247,171,23,255,237,177,204,255,52,137,145,255,194,182,114,0,224,234,149,0,10,111,103,1,201,129,4,0,238,142,78,0,52,6,40,255,110,213,165,254,60,207,253,0,62,215,69,0,96,97,0,255,49,45,202,0,120,121,22,255,235,139,48,1,198,45,34,255,182,50,27,1,131,210,91,255,46,54,128,0,175,123,105,255,198,141,78,254,67,244,239,255,245,54,103,254,78,38,242,255,2,92,249,254,251,174,87,255,139,63,144,0,24,108,27,255,34,102,18,1,34,22,152,0,66,229,118,254,50,143,99,0,144,169,149,1,118,30,152,0,178,8,121,1,8,159,18,0,90,101,230,255,129,29,119,0,68,36,11,1,232,183,55,0,23,255,96,255,161,41,193,255,63,139,222,0,15,179,243,0,255,100,15,255,82,53,135,0,137,57,149,1,99,240,170,255,22,230,228,254,49,180,82,255,61,82,43,0,110,245,217,0,199,125,61,0,46,253,52,0,141,197,219,0,211,159,193,0,55,121,105,254,183,20,129,0,169,119,170,255,203,178,139,255,135,40,182,255,172,13,202,255,65,178,148,0,8,207,43,0,122,53,127,1,74,161,48,0,227,214,128,254,86,11,243,255,100,86,7,1,245,68,134,255,61,43,21,1,152,84,94,255,190,60,250,254,239,118,232,255,214,136,37,1,113,76,107,255,93,104,100,1,144,206,23,255,110,150,154,1,228,103,185,0,218,49,50,254,135,77,139,255,185,1,78,0,0,161,148,255,97,29,233,255,207,148,149,255,160,168,0,0,91,128,171,255,6,28,19,254,11,111,247,0,39,187,150,255,138,232,149,0,117,62,68,255,63,216,188,255,235,234,32,254,29,57,160,255,25,12,241,1,169,60,191,0,32,131,141,255,237,159,123,255,94,197,94,254,116,254,3,255,92,179,97,254,121,97,92,255,170,112,14,0,21,149,248,0,248,227,3,0,80,96,109,0,75,192,74,1,12,90,226,255,161,106,68,1,208,114,127,255,114,42,255,254,74,26,74,255,247,179,150,254,121,140,60,0,147,70,200,255,214,40,161,255,161,188,201,255,141,65,135,255,242,115,252,0,62,47,202,0,180,149,255,254,130,55,237,0,165,17,186,255,10,169,194,0,156,109,218,255,112,140,123,255,104,128,223,254,177,142,108,255,121,37,219,255,128,77,18,255,111,108,23,1,91,192,75,0,174,245,22,255,4,236,62,255,43,64,153,1,227,173,254,0,237,122,132,1,127,89,186,255,142,82,128,254,252,84,174,0,90,179,177,1,243,214,87,255,103,60,162,255,208,130,14,255,11,130,139,0,206,129,219,255,94,217,157,255,239,230,230,255,116,115,159,254,164,107,95,0,51,218,2,1,216,125,198,255,140,202,128,254,11,95,68,255,55,9,93,254,174,153,6,255,204,172,96,0,69,160,110,0,213,38,49,254,27,80,213,0,118,125,114,0,70,70,67,255,15,142,73,255,131,122,185,255,243,20,50,254,130,237,40,0,210,159,140,1,197,151,65,255,84,153,66,0,195,126,90,0,16,238,236,1,118,187,102,255,3,24,133,255,187,69,230,0,56,197,92,1,213,69,94,255,80,138,229,1,206,7,230,0,222,111,230,1,91,233,119,255,9,89,7,1,2,98,1,0,148,74,133,255,51,246,180,255,228,177,112,1,58,189,108,255,194,203,237,254,21,209,195,0,147,10,35,1,86,157,226,0,31,163,139,254,56,7,75,255,62,90,116,0,181,60,169,0,138,162,212,254,81,167,31,0,205,90,112,255,33,112,227,0,83,151,117,1,177,224,73,255,174,144,217,255,230,204,79,255,22,77,232,255,114,78,234,0,224,57,126,254,9,49,141,0,242,147,165,1,104,182,140,255,167,132,12,1,123,68,127,0,225,87,39,1,251,108,8,0,198,193,143,1,121,135,207,255,172,22,70,0,50,68,116,255,101,175,40,255,248,105,233,0,166,203,7,0,110,197,218,0,215,254,26,254,168,226,253,0,31,143,96,0,11,103,41,0,183,129,203,254,100,247,74,255,213,126,132,0,210,147,44,0,199,234,27,1,148,47,181,0,155,91,158,1,54,105,175,255,2,78,145,254,102,154,95,0,128,207,127,254,52,124,236,255,130,84,71,0,221,243,211,0,152,170,207,0,222,106,199,0,183,84,94,254,92,200,56,255,138,182,115,1,142,96,146,0,133,136,228,0,97,18,150,0,55,251,66,0,140,102,4,0,202,103,151,0,30,19,248,255,51,184,207,0,202,198,89,0,55,197,225,254,169,95,249,255,66,65,68,255,188,234,126,0,166,223,100,1,112,239,244,0,144,23,194,0,58,39,182,0,244,44,24,254,175,68,179,255,152,118,154,1,176,162,130,0,217,114,204,254,173,126,78,255,33,222,30,255,36,2,91,255,2,143,243,0,9,235,215,0,3,171,151,1,24,215,245,255,168,47,164,254,241,146,207,0,69,129,180,0,68,243,113,0,144,53,72,254,251,45,14,0,23,110,168,0,68,68,79,255,110,70,95,254,174,91,144,255,33,206,95,255,137,41,7,255,19,187,153,254,35,255,112,255,9,145,185,254,50,157,37,0,11,112,49,1,102,8,190,255,234,243,169,1,60,85,23,0,74,39,189,0,116,49,239,0,173,213,210,0,46,161,108,255,159,150,37,0,196,120,185,255,34,98,6,255,153,195,62,255,97,230,71,255,102,61,76,0,26,212,236,255,164,97,16,0,198,59,146,0,163,23,196,0,56,24,61,0,181,98,193,0,251,147,229,255,98,189,24,255,46,54,206,255,234,82,246,0,183,103,38,1,109,62,204,0,10,240,224,0,146,22,117,255,142,154,120,0,69,212,35,0,208,99,118,1,121,255,3,255,72,6,194,0,117,17,197,255,125,15,23,0,154,79,153,0,214,94,197,255,185,55,147,255,62,254,78,254,127,82,153,0,110,102,63,255,108,82,161,255,105,187,212,1,80,138,39,0,60,255,93,255,72,12,186,0,210,251,31,1,190,167,144,255,228,44,19,254,128,67,232,0,214,249,107,254,136,145,86,255,132,46,176,0,189,187,227,255,208,22,140,0,217,211,116,0,50,81,186,254,139,250,31,0,30,64,198,1,135,155,100,0,160,206,23,254,187,162,211,255,16,188,63,0,254,208,49,0,85,84,191,0,241,192,242,255,153,126,145,1,234,162,162,255,230,97,216,1,64,135,126,0,190,148,223,1,52,0,43,255,28,39,189,1,64,136,238,0,175,196,185,0,98,226,213,255,127,159,244,1,226,175,60,0,160,233,142,1,180,243,207,255,69,152,89,1,31,101,21,0,144,25,164,254,139,191,209,0,91,25,121,0,32,147,5,0,39,186,123,255,63,115,230,255,93,167,198,255,143,213,220,255,179,156,19,255,25,66,122,0,214,160,217,255,2,45,62,255,106,79,146,254,51,137,99,255,87,100,231,255,175,145,232,255,101,184,1,255,174,9,125,0,82,37,161,1,36,114,141,255,48,222,142,255,245,186,154,0,5,174,221,254,63,114,155,255,135,55,160,1,80,31,135,0,126,250,179,1,236,218,45,0,20,28,145,1,16,147,73,0,249,189,132,1,17,189,192,255,223,142,198,255,72,20,15,255,250,53,237,254,15,11,18,0,27,211,113,254,213,107,56,255,174,147,146,255,96,126,48,0,23,193,109,1,37,162,94,0,199,157,249,254,24,128,187,255,205,49,178,254,93,164,42,255,43,119,235,1,88,183,237,255,218,210,1,255,107,254,42,0,230,10,99,255,162,0,226,0,219,237,91,0,129,178,203,0,208,50,95,254,206,208,95,255,247,191,89,254,110,234,79,255,165,61,243,0,20,122,112,255,246,246,185,254,103,4,123,0,233,99,230,1,219,91,252,255,199,222,22,255,179,245,233,255,211,241,234,0,111,250,192,255,85,84,136,0,101,58,50,255,131,173,156,254,119,45,51,255,118,233,16,254,242,90,214,0,94,159,219,1,3,3,234,255,98,76,92,254,80,54,230,0,5,228,231,254,53,24,223,255,113,56,118,1,20,132,1,255,171,210,236,0,56,241,158,255,186,115,19,255,8,229,174,0,48,44,0,1,114,114,166,255,6,73,226,255,205,89,244,0,137,227,75,1,248,173,56,0,74,120,246,254,119,3,11,255,81,120,198,255,136,122,98,255,146,241,221,1,109,194,78,255,223,241,70,1,214,200,169,255,97,190,47,255,47,103,174,255,99,92,72,254,118,233,180,255,193,35,233,254,26,229,32,255,222,252,198,0,204,43,71,255,199,84,172,0,134,102,190,0,111,238,97,254,230,40,230,0,227,205,64,254,200,12,225,0,166,25,222,0,113,69,51,255,143,159,24,0,167,184,74,0,29,224,116,254,158,208,233,0,193,116,126,255,212,11,133,255,22,58,140,1,204,36,51,255,232,30,43,0,235,70,181,255,64,56,146,254,169,18,84,255,226,1,13,255,200,50,176,255,52,213,245,254,168,209,97,0,191,71,55,0,34,78,156,0,232,144,58,1,185,74,189,0,186,142,149,254,64,69,127,255,161,203,147,255,176,151,191,0,136,231,203,254,163,182,137,0,161,126,251,254,233,32,66,0,68,207,66,0,30,28,37,0,93,114,96,1,254,92,247,255,44,171,69,0,202,119,11,255,188,118,50,1,255,83,136,255,71,82,26,0,70,227,2,0,32,235,121,1,181,41,154,0,71,134,229,254,202,255,36,0,41,152,5,0,154,63,73,255,34,182,124,0,121,221,150,255,26,204,213,1,41,172,87,0,90,157,146,255,109,130,20,0,71,107,200,255,243,102,189,0,1,195,145,254,46,88,117,0,8,206,227,0,191,110,253,255,109,128,20,254,134,85,51,255,137,177,112,1,216,34,22,255,131,16,208,255,121,149,170,0,114,19,23,1,166,80,31,255,113,240,122,0,232,179,250,0,68,110,180,254,210,170,119,0,223,108,164,255,207,79,233,255,27,229,226,254,209,98,81,255,79,68,7,0,131,185,100,0,170,29,162,255,17,162,107,255,57,21,11,1,100,200,181,255,127,65,166,1,165,134,204,0,104,167,168,0,1,164,79,0,146,135,59,1,70,50,128,255,102,119,13,254,227,6,135,0,162,142,179,255,160,100,222,0,27,224,219,1,158,93,195,255,234,141,137,0,16,24,125,255,238,206,47,255,97,17,98,255,116,110,12,255,96,115,77,0,91,227,232,255,248,254,79,255,92,229,6,254,88,198,139,0,206,75,129,0,250,77,206,255,141,244,123,1,138,69,220,0,32,151,6,1,131,167,22,255,237,68,167,254,199,189,150,0,163,171,138,255,51,188,6,255,95,29,137,254,148,226,179,0,181,107,208,255,134,31,82,255,151,101,45,255,129,202,225,0,224,72,147,0,48,138,151,255,195,64,206,254,237,218,158,0,106,29,137,254,253,189,233,255,103,15,17,255,194,97,255,0,178,45,169,254,198,225,155,0,39,48,117,255,135,106,115,0,97,38,181,0,150,47,65,255,83,130,229,254,246,38,129,0,92,239,154,254,91,99,127,0,161,111,33,255,238,217,242,255,131,185,195,255,213,191,158,255,41,150,218,0,132,169,131,0,89,84,252,1,171,70,128,255,163,248,203,254,1,50,180,255,124,76,85,1,251,111,80,0,99,66,239,255,154,237,182,255,221,126,133,254,74,204,99,255,65,147,119,255,99,56,167,255,79,248,149,255,116,155,228,255,237,43,14,254,69,137,11,255,22,250,241,1,91,122,143,255,205,249,243,0,212,26,60,255,48,182,176,1,48,23,191,255,203,121,152,254,45,74,213,255,62,90,18,254,245,163,230,255,185,106,116,255,83,35,159,0,12,33,2,255,80,34,62,0,16,87,174,255,173,101,85,0,202,36,81,254,160,69,204,255,64,225,187,0,58,206,94,0,86,144,47,0,229,86,245,0,63,145,190,1,37,5,39,0,109,251,26,0,137,147,234,0,162,121,145,255,144,116,206,255,197,232,185,255,183,190,140,255,73,12,254,255,139,20,242,255,170,90,239,255,97,66,187,255,245,181,135,254,222,136,52,0,245,5,51,254,203,47,78,0,152,101,216,0,73,23,125,0,254,96,33,1,235,210,73,255,43,209,88,1,7,129,109,0,122,104,228,254,170,242,203,0,242,204,135,255,202,28,233,255,65,6,127,0,159,144,71,0,100,140,95,0,78,150,13,0,251,107,118,1,182,58,125,255,1,38,108,255,141,189,209,255,8,155,125,1,113,163,91,255,121,79,190,255,134,239,108,255,76,47,248,0,163,228,239,0,17,111,10,0,88,149,75,255,215,235,239,0,167,159,24,255,47,151,108,255,107,209,188,0,233,231,99,254,28,202,148,255,174,35,138,255,110,24,68,255,2,69,181,0,107,102,82,0,102,237,7,0,92,36,237,255,221,162,83,1,55,202,6,255,135,234,135,255,24,250,222,0,65,94,168,254,245,248,210,255,167,108,201,254,255,161,111,0,205,8,254,0,136,13,116,0,100,176,132,255,43,215,126,255,177,133,130,255,158,79,148,0,67,224,37,1,12,206,21,255,62,34,110,1,237,104,175,255,80,132,111,255,142,174,72,0,84,229,180,254,105,179,140,0,64,248,15,255,233,138,16,0,245,67,123,254,218,121,212,255,63,95,218,1,213,133,137,255,143,182,82,255,48,28,11,0,244,114,141,1,209,175,76,255,157,181,150,255,186,229,3,255,164,157,111,1,231,189,139,0,119,202,190,255,218,106,64,255,68,235,63,254,96,26,172,255,187,47,11,1,215,18,251,255,81,84,89,0,68,58,128,0,94,113,5,1,92,129,208,255,97,15,83,254,9,28,188,0,239,9,164,0,60,205,152,0,192,163,98,255,184,18,60,0,217,182,139,0,109,59,120,255,4,192,251,0,169,210,240,255,37,172,92,254,148,211,245,255,179,65,52,0,253,13,115,0,185,174,206,1,114,188,149,255,237,90,173,0,43,199,192,255,88,108,113,0,52,35,76,0,66,25,148,255,221,4,7,255,151,241,114,255,190,209,232,0,98,50,199,0,151,150,213,255,18,74,36,1,53,40,7,0,19,135,65,255,26,172,69,0,174,237,85,0,99,95,41,0,3,56,16,0,39,160,177,255,200,106,218,254,185,68,84,255,91,186,61,254,67,143,141,255,13,244,166,255,99,114,198,0,199,110,163,255,193,18,186,0,124,239,246,1,110,68,22,0,2,235,46,1,212,60,107,0,105,42,105,1,14,230,152,0,7,5,131,0,141,104,154,255,213,3,6,0,131,228,162,255,179,100,28,1,231,123,85,255,206,14,223,1,253,96,230,0,38,152,149,1,98,137,122,0,214,205,3,255,226,152,179,255,6,133,137,0,158,69,140,255,113,162,154,255,180,243,172,255,27,189,115,255,143,46,220,255,213,134,225,255,126,29,69,0,188,43,137,1,242,70,9,0,90,204,255,255,231,170,147,0,23,56,19,254,56,125,157,255,48,179,218,255,79,182,253,255,38,212,191,1,41,235,124,0,96,151,28,0,135,148,190,0,205,249,39,254,52,96,136,255,212,44,136,255,67,209,131,255,252,130,23,255,219,128,20,255,198,129,118,0,108,101,11,0,178,5,146,1,62,7,100,255,181,236,94,254,28,26,164,0,76,22,112,255,120,102,79,0,202,192,229,1,200,176,215,0,41,64,244,255,206,184,78,0,167,45,63,1,160,35,0,255,59,12,142,255,204,9,144,255,219,94,229,1,122,27,112,0,189,105,109,255,64,208,74,255,251,127,55,1,2,226,198,0,44,76,209,0,151,152,77,255,210,23,46,1,201,171,69,255,44,211,231,0,190,37,224,255,245,196,62,255,169,181,222,255,34,211,17,0,119,241,197,255,229,35,152,1,21,69,40,255,178,226,161,0,148,179,193,0,219,194,254,1,40,206,51,255,231,92,250,1,67,153,170,0,21,148,241,0,170,69,82,255,121,18,231,255,92,114,3,0,184,62,230,0,225,201,87,255,146,96,162,255,181,242,220,0,173,187,221,1,226,62,170,255,56,126,217,1,117,13,227,255,179,44,239,0,157,141,155,255,144,221,83,0,235,209,208,0,42,17,165,1,251,81,133,0,124,245,201,254,97,211,24,255,83,214,166,0,154,36,9,255,248,47,127,0,90,219,140,255,161,217,38,254,212,147,63,255,66,84,148,1,207,3,1,0,230,134,89,1,127,78,122,255,224,155,1,255,82,136,74,0,178,156,208,255,186,25,49,255,222,3,210,1,229,150,190,255,85,162,52,255,41,84,141,255,73,123,84,254,93,17,150,0,119,19,28,1,32,22,215,255,28,23,204,255,142,241,52,255,228,52,125,0,29,76,207,0,215,167,250,254,175,164,230,0,55,207,105,1,109,187,245,255,161,44,220,1,41,101,128,255,167,16,94,0,93,214,107,255,118,72,0,254,80,61,234,255,121,175,125,0,139,169,251,0,97,39,147,254,250,196,49,255,165,179,110,254,223,70,187,255,22,142,125,1,154,179,138,255,118,176,42,1,10,174,153,0,156,92,102,0,168,13,161,255,143,16,32,0,250,197,180,255,203,163,44,1,87,32,36,0,161,153,20,255,123,252,15,0,25,227,80,0,60,88,142,0,17,22,201,1,154,205,77,255,39,63,47,0,8,122,141,0,128,23,182,254,204,39,19,255],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+20480);allocate([4,112,29,255,23,36,140,255,210,234,116,254,53,50,63,255,121,171,104,255,160,219,94,0,87,82,14,254,231,42,5,0,165,139,127,254,86,78,38,0,130,60,66,254,203,30,45,255,46,196,122,1,249,53,162,255,136,143,103,254,215,210,114,0,231,7,160,254,169,152,42,255,111,45,246,0,142,131,135,255,131,71,204,255,36,226,11,0,0,28,242,255,225,138,213,255,247,46,216,254,245,3,183,0,108,252,74,1,206,26,48,255,205,54,246,255,211,198,36,255,121,35,50,0,52,216,202,255,38,139,129,254,242,73,148,0,67,231,141,255,42,47,204,0,78,116,25,1,4,225,191,255,6,147,228,0,58,88,177,0,122,165,229,255,252,83,201,255,224,167,96,1,177,184,158,255,242,105,179,1,248,198,240,0,133,66,203,1,254,36,47,0,45,24,115,255,119,62,254,0,196,225,186,254,123,141,172,0,26,85,41,255,226,111,183,0,213,231,151,0,4,59,7,255,238,138,148,0,66,147,33,255,31,246,141,255,209,141,116,255,104,112,31,0,88,161,172,0,83,215,230,254,47,111,151,0,45,38,52,1,132,45,204,0,138,128,109,254,233,117,134,255,243,190,173,254,241,236,240,0,82,127,236,254,40,223,161,255,110,182,225,255,123,174,239,0,135,242,145,1,51,209,154,0,150,3,115,254,217,164,252,255,55,156,69,1,84,94,255,255,232,73,45,1,20,19,212,255,96,197,59,254,96,251,33,0,38,199,73,1,64,172,247,255,117,116,56,255,228,17,18,0,62,138,103,1,246,229,164,255,244,118,201,254,86,32,159,255,109,34,137,1,85,211,186,0,10,193,193,254,122,194,177,0,122,238,102,255,162,218,171,0,108,217,161,1,158,170,34,0,176,47,155,1,181,228,11,255,8,156,0,0,16,75,93,0,206,98,255,1,58,154,35,0,12,243,184,254,67,117,66,255,230,229,123,0,201,42,110,0,134,228,178,254,186,108,118,255,58,19,154,255,82,169,62,255,114,143,115,1,239,196,50,255,173,48,193,255,147,2,84,255,150,134,147,254,95,232,73,0,109,227,52,254,191,137,10,0,40,204,30,254,76,52,97,255,164,235,126,0,254,124,188,0,74,182,21,1,121,29,35,255,241,30,7,254,85,218,214,255,7,84,150,254,81,27,117,255,160,159,152,254,66,24,221,255,227,10,60,1,141,135,102,0,208,189,150,1,117,179,92,0,132,22,136,255,120,199,28,0,21,129,79,254,182,9,65,0,218,163,169,0,246,147,198,255,107,38,144,1,78,175,205,255,214,5,250,254,47,88,29,255,164,47,204,255,43,55,6,255,131,134,207,254,116,100,214,0,96,140,75,1,106,220,144,0,195,32,28,1,172,81,5,255,199,179,52,255,37,84,203,0,170,112,174,0,11,4,91,0,69,244,27,1,117,131,92,0,33,152,175,255,140,153,107,255,251,135,43,254,87,138,4,255,198,234,147,254,121,152,84,255,205,101,155,1,157,9,25,0,72,106,17,254,108,153,0,255,189,229,186,0,193,8,176,255,174,149,209,0,238,130,29,0,233,214,126,1,61,226,102,0,57,163,4,1,198,111,51,255,45,79,78,1,115,210,10,255,218,9,25,255,158,139,198,255,211,82,187,254,80,133,83,0,157,129,230,1,243,133,134,255,40,136,16,0,77,107,79,255,183,85,92,1,177,204,202,0,163,71,147,255,152,69,190,0,172,51,188,1,250,210,172,255,211,242,113,1,89,89,26,255,64,66,111,254,116,152,42,0,161,39,27,255,54,80,254,0,106,209,115,1,103,124,97,0,221,230,98,255,31,231,6,0,178,192,120,254,15,217,203,255,124,158,79,0,112,145,247,0,92,250,48,1,163,181,193,255,37,47,142,254,144,189,165,255,46,146,240,0,6,75,128,0,41,157,200,254,87,121,213,0,1,113,236,0,5,45,250,0,144,12,82,0,31,108,231,0,225,239,119,255,167,7,189,255,187,228,132,255,110,189,34,0,94,44,204,1,162,52,197,0,78,188,241,254,57,20,141,0,244,146,47,1,206,100,51,0,125,107,148,254,27,195,77,0,152,253,90,1,7,143,144,255,51,37,31,0,34,119,38,255,7,197,118,0,153,188,211,0,151,20,116,254,245,65,52,255,180,253,110,1,47,177,209,0,161,99,17,255,118,222,202,0,125,179,252,1,123,54,126,255,145,57,191,0,55,186,121,0,10,243,138,0,205,211,229,255,125,156,241,254,148,156,185,255,227,19,188,255,124,41,32,255,31,34,206,254,17,57,83,0,204,22,37,255,42,96,98,0,119,102,184,1,3,190,28,0,110,82,218,255,200,204,192,255,201,145,118,0,117,204,146,0,132,32,98,1,192,194,121,0,106,161,248,1,237,88,124,0,23,212,26,0,205,171,90,255,248,48,216,1,141,37,230,255,124,203,0,254,158,168,30,255,214,248,21,0,112,187,7,255,75,133,239,255,74,227,243,255,250,147,70,0,214,120,162,0,167,9,179,255,22,158,18,0,218,77,209,1,97,109,81,255,244,33,179,255,57,52,57,255,65,172,210,255,249,71,209,255,142,169,238,0,158,189,153,255,174,254,103,254,98,33,14,0,141,76,230,255,113,139,52,255,15,58,212,0,168,215,201,255,248,204,215,1,223,68,160,255,57,154,183,254,47,231,121,0,106,166,137,0,81,136,138,0,165,43,51,0,231,139,61,0,57,95,59,254,118,98,25,255,151,63,236,1,94,190,250,255,169,185,114,1,5,250,58,255,75,105,97,1,215,223,134,0,113,99,163,1,128,62,112,0,99,106,147,0,163,195,10,0,33,205,182,0,214,14,174,255,129,38,231,255,53,182,223,0,98,42,159,255,247,13,40,0,188,210,177,1,6,21,0,255,255,61,148,254,137,45,129,255,89,26,116,254,126,38,114,0,251,50,242,254,121,134,128,255,204,249,167,254,165,235,215,0,202,177,243,0,133,141,62,0,240,130,190,1,110,175,255,0,0,20,146,1,37,210,121,255,7,39,130,0,142,250,84,255,141,200,207,0,9,95,104,255,11,244,174,0,134,232,126,0,167,1,123,254,16,193,149,255,232,233,239,1,213,70,112,255,252,116,160,254,242,222,220,255,205,85,227,0,7,185,58,0,118,247,63,1,116,77,177,255,62,245,200,254,63,18,37,255,107,53,232,254,50,221,211,0,162,219,7,254,2,94,43,0,182,62,182,254,160,78,200,255,135,140,170,0,235,184,228,0,175,53,138,254,80,58,77,255,152,201,2,1,63,196,34,0,5,30,184,0,171,176,154,0,121,59,206,0,38,99,39,0,172,80,77,254,0,134,151,0,186,33,241,254,94,253,223,255,44,114,252,0,108,126,57,255,201,40,13,255,39,229,27,255,39,239,23,1,151,121,51,255,153,150,248,0,10,234,174,255,118,246,4,254,200,245,38,0,69,161,242,1,16,178,150,0,113,56,130,0,171,31,105,0,26,88,108,255,49,42,106,0,251,169,66,0,69,93,149,0,20,57,254,0,164,25,111,0,90,188,90,255,204,4,197,0,40,213,50,1,212,96,132,255,88,138,180,254,228,146,124,255,184,246,247,0,65,117,86,255,253,102,210,254,254,121,36,0,137,115,3,255,60,24,216,0,134,18,29,0,59,226,97,0,176,142,71,0,7,209,161,0,189,84,51,254,155,250,72,0,213,84,235,255,45,222,224,0,238,148,143,255,170,42,53,255,78,167,117,0,186,0,40,255,125,177,103,255,69,225,66,0,227,7,88,1,75,172,6,0,169,45,227,1,16,36,70,255,50,2,9,255,139,193,22,0,143,183,231,254,218,69,50,0,236,56,161,1,213,131,42,0,138,145,44,254,136,229,40,255,49,63,35,255,61,145,245,255,101,192,2,254,232,167,113,0,152,104,38,1,121,185,218,0,121,139,211,254,119,240,35,0,65,189,217,254,187,179,162,255,160,187,230,0,62,248,14,255,60,78,97,0,255,247,163,255,225,59,91,255,107,71,58,255,241,47,33,1,50,117,236,0,219,177,63,254,244,90,179,0,35,194,215,255,189,67,50,255,23,135,129,0,104,189,37,255,185,57,194,0,35,62,231,255,220,248,108,0,12,231,178,0,143,80,91,1,131,93,101,255,144,39,2,1,255,250,178,0,5,17,236,254,139,32,46,0,204,188,38,254,245,115,52,255,191,113,73,254,191,108,69,255,22,69,245,1,23,203,178,0,170,99,170,0,65,248,111,0,37,108,153,255,64,37,69,0,0,88,62,254,89,148,144,255,191,68,224,1,241,39,53,0,41,203,237,255,145,126,194,255,221,42,253,255,25,99,151,0,97,253,223,1,74,115,49,255,6,175,72,255,59,176,203,0,124,183,249,1,228,228,99,0,129,12,207,254,168,192,195,255,204,176,16,254,152,234,171,0,77,37,85,255,33,120,135,255,142,194,227,1,31,214,58,0,213,187,125,255,232,46,60,255,190,116,42,254,151,178,19,255,51,62,237,254,204,236,193,0,194,232,60,0,172,34,157,255,189,16,184,254,103,3,95,255,141,233,36,254,41,25,11,255,21,195,166,0,118,245,45,0,67,213,149,255,159,12,18,255,187,164,227,1,160,25,5,0,12,78,195,1,43,197,225,0,48,142,41,254,196,155,60,255,223,199,18,1,145,136,156,0,252,117,169,254,145,226,238,0,239,23,107,0,109,181,188,255,230,112,49,254,73,170,237,255,231,183,227,255,80,220,20,0,194,107,127,1,127,205,101,0,46,52,197,1,210,171,36,255,88,3,90,255,56,151,141,0,96,187,255,255,42,78,200,0,254,70,70,1,244,125,168,0,204,68,138,1,124,215,70,0,102,66,200,254,17,52,228,0,117,220,143,254,203,248,123,0,56,18,174,255,186,151,164,255,51,232,208,1,160,228,43,255,249,29,25,1,68,190,63,0,103,230,9,106,133,174,103,187,114,243,110,60,58,245,79,165,127,82,14,81,140,104,5,155,171,217,131,31,25,205,224,91,152,47,138,66,145,68,55,113,207,251,192,181,165,219,181,233,91,194,86,57,241,17,241,89,164,130,63,146,213,94,28,171,152,170,7,216,1,91,131,18,190,133,49,36,195,125,12,85,116,93,190,114,254,177,222,128,167,6,220,155,116,241,155,193,193,105,155,228,134,71,190,239,198,157,193,15,204,161,12,36,111,44,233,45,170,132,116,74,220,169,176,92,218,136,249,118,82,81,62,152,109,198,49,168,200,39,3,176,199,127,89,191,243,11,224,198,71,145,167,213,81,99,202,6,103,41,41,20,133,10,183,39,56,33,27,46,252,109,44,77,19,13,56,83,84,115,10,101,187,10,106,118,46,201,194,129,133,44,114,146,161,232,191,162,75,102,26,168,112,139,75,194,163,81,108,199,25,232,146,209,36,6,153,214,133,53,14,244,112,160,106,16,22,193,164,25,8,108,55,30,76,119,72,39,181,188,176,52,179,12,28,57,74,170,216,78,79,202,156,91,243,111,46,104,238,130,143,116,111,99,165,120,20,120,200,132,8,2,199,140,250,255,190,144,235,108,80,164,247,163,249,190,242,120,113,198,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,48,138,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,104,109,97,99,115,104,97,53,49,50,50,53,54,0,99,117,114,118,101,50,53,53,49,57,120,115,97,108,115,97,50,48,112,111,108,121,49,51,48,53,0,83,45,62,98,117,102,108,101,110,32,60,61,32,66,76,65,75,69,50,66,95,66,76,79,67,75,66,89,84,69,83,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,47,98,108,97,107,101,50,98,47,114,101,102,47,98,108,97,107,101,50,98,45,114,101,102,46,99,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,95,102,105,110,97,108,0,111,117,116,108,101,110,32,60,61,32,85,73,78,84,56,95,77,65,88,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,47,98,108,97,107,101,50,98,47,114,101,102,47,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,46,99,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,0,107,101,121,108,101,110,32,60,61,32,85,73,78,84,56,95,77,65,88,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,115,97,108,116,95,112,101,114,115,111,110,97,108,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,105,110,105,116,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,105,110,105,116,95,115,97,108,116,95,112,101,114,115,111,110,97,108,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,102,105,110,97,108,0,115,104,97,53,49,50,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,98,108,97,107,101,50,98,0,120,50,53,53,49,57,98,108,97,107,101,50,98,0,112,111,108,121,49,51,48,53,0,36,97,114,103,111,110,50,105,0,36,118,61,0,36,109,61,0,44,116,61,0,44,112,61,0,36,97,114,103,111,110,50,105,36,118,61,0,36,97,114,103,111,110,50,105,36,0,97,114,103,111,110,50,105,0,46,47,48,49,50,51,52,53,54,55,56,57,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,0,36,55,36,0,99,117,114,118,101,50,53,53,49,57,0,120,115,97,108,115,97,50,48,112,111,108,121,49,51,48,53,0,115,105,112,104,97,115,104,50,52,0,101,100,50,53,53,49,57,0,237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,83,105,103,69,100,50,53,53,49,57,32,110,111,32,69,100,50,53,53,49,57,32,99,111,108,108,105,115,105,111,110,115,1,0,120,115,97,108,115,97,50,48,0,106,115,0,123,32,114,101,116,117,114,110,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,40,41,59,32,125,0,123,32,105,102,32,40,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,61,61,32,117,110,100,101,102,105,110,101,100,41,32,123,32,116,114,121,32,123,32,118,97,114,32,119,105,110,100,111,119,95,32,61,32,34,111,98,106,101,99,116,34,32,61,61,61,32,116,121,112,101,111,102,32,119,105,110,100,111,119,32,63,32,119,105,110,100,111,119,32,58,32,115,101,108,102,44,32,99,114,121,112,116,111,95,32,61,32,116,121,112,101,111,102,32,119,105,110,100,111,119,95,46,99,114,121,112,116,111,32,33,61,61,32,34,117,110,100,101,102,105,110,101,100,34,32,63,32,119,105,110,100,111,119,95,46,99,114,121,112,116,111,32,58,32,119,105,110,100,111,119,95,46,109,115,67,114,121,112,116,111,44,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,32,61,32,102,117,110,99,116,105,111,110,40,41,32,123,32,118,97,114,32,98,117,102,32,61,32,110,101,119,32,85,105,110,116,51,50,65,114,114,97,121,40,49,41,59,32,99,114,121,112,116,111,95,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,115,40,98,117,102,41,59,32,114,101,116,117,114,110,32,98,117,102,91,48,93,32,62,62,62,32,48,59,32,125,59,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,40,41,59,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,59,32,125,32,99,97,116,99,104,32,40,101,41,32,123,32,116,114,121,32,123,32,118,97,114,32,99,114,121,112,116,111,32,61,32,114,101,113,117,105,114,101,40,39,99,114,121,112,116,111,39,41,44,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,32,61,32,102,117,110,99,116,105,111,110,40,41,32,123,32,118,97,114,32,98,117,102,32,61,32,99,114,121,112,116,111,46,114,97,110,100,111,109,66,121,116,101,115,40,52,41,59,32,114,101,116,117,114,110,32,40,98,117,102,91,48,93,32,60,60,32,50,52,32,124,32,98,117,102,91,49,93,32,60,60,32,49,54,32,124,32,98,117,102,91,50,93,32,60,60,32,56,32,124,32,98,117,102,91,51,93,41,32,62,62,62,32,48,59,32,125,59,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,40,41,59,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,59,32,125,32,99,97,116,99,104,32,40,101,41,32,123,32,116,104,114,111,119,32,39,78,111,32,115,101,99,117,114,101,32,114,97,110,100,111,109,32,110,117,109,98,101,114,32,103,101,110,101,114,97,116,111,114,32,102,111,117,110,100,39,59,32,125,32,125,32,125,32,125,0,76,105,98,115,111,100,105,117,109,68,82,71,98,117,102,95,108,101,110,32,60,61,32,83,73,90,69,95,77,65,88,0,114,97,110,100,111,109,98,121,116,101,115,47,114,97,110,100,111,109,98,121,116,101,115,46,99,0,114,97,110,100,111,109,98,121,116,101,115,0,49,46,48,46,49,50,0,0,0,0,12,0,0,0,0,0,0,0,4,0,0,0,8,15,11,7,3,14,10,6,2,13,9,5,1,12,8,4,0,3,3,3,3,7,7,7,7,11,11,11,11,15,15,15,15,3,2,1,0,7,6,5,4,11,10,9,8,15,14,13,12,12,8,4,0,13,9,5,1,14,10,6,2,15,11,7,3,1,2,3,0,6,7,4,5,11,8,9,10,12,13,14,15,15,10,5,0,14,9,4,3,13,8,7,2,12,11,6,1],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+30720);var tempDoublePtr=STATICTOP;STATICTOP+=16;Module["_bitshift64Ashr"]=_bitshift64Ashr;Module["_i64Subtract"]=_i64Subtract;Module["_i64Add"]=_i64Add;Module["_memset"]=_memset;Module["_bitshift64Lshr"]=_bitshift64Lshr;Module["_bitshift64Shl"]=_bitshift64Shl;function _abort(){Module["abort"]()}function ___assert_fail(condition,filename,line,func){ABORT=true;throw"Assertion failed: "+Pointer_stringify(condition)+", at: "+[filename?Pointer_stringify(filename):"unknown filename",line,func?Pointer_stringify(func):"unknown function"]+" at "+stackTrace()}function _emscripten_memcpy_big(dest,src,num){HEAPU8.set(HEAPU8.subarray(src,src+num),dest);return dest}Module["_memcpy"]=_memcpy;var cttz_i8=allocate([8,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,7,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0],"i8",ALLOC_STATIC);Module["_llvm_cttz_i32"]=_llvm_cttz_i32;Module["___udivmoddi4"]=___udivmoddi4;Module["___udivdi3"]=___udivdi3;Module["___muldsi3"]=___muldsi3;Module["___muldi3"]=___muldi3;function ___setErrNo(value){if(Module["___errno_location"])HEAP32[Module["___errno_location"]()>>2]=value;return value}var ERRNO_CODES={EPERM:1,ENOENT:2,ESRCH:3,EINTR:4,EIO:5,ENXIO:6,E2BIG:7,ENOEXEC:8,EBADF:9,ECHILD:10,EAGAIN:11,EWOULDBLOCK:11,ENOMEM:12,EACCES:13,EFAULT:14,ENOTBLK:15,EBUSY:16,EEXIST:17,EXDEV:18,ENODEV:19,ENOTDIR:20,EISDIR:21,EINVAL:22,ENFILE:23,EMFILE:24,ENOTTY:25,ETXTBSY:26,EFBIG:27,ENOSPC:28,ESPIPE:29,EROFS:30,EMLINK:31,EPIPE:32,EDOM:33,ERANGE:34,ENOMSG:42,EIDRM:43,ECHRNG:44,EL2NSYNC:45,EL3HLT:46,EL3RST:47,ELNRNG:48,EUNATCH:49,ENOCSI:50,EL2HLT:51,EDEADLK:35,ENOLCK:37,EBADE:52,EBADR:53,EXFULL:54,ENOANO:55,EBADRQC:56,EBADSLT:57,EDEADLOCK:35,EBFONT:59,ENOSTR:60,ENODATA:61,ETIME:62,ENOSR:63,ENONET:64,ENOPKG:65,EREMOTE:66,ENOLINK:67,EADV:68,ESRMNT:69,ECOMM:70,EPROTO:71,EMULTIHOP:72,EDOTDOT:73,EBADMSG:74,ENOTUNIQ:76,EBADFD:77,EREMCHG:78,ELIBACC:79,ELIBBAD:80,ELIBSCN:81,ELIBMAX:82,ELIBEXEC:83,ENOSYS:38,ENOTEMPTY:39,ENAMETOOLONG:36,ELOOP:40,EOPNOTSUPP:95,EPFNOSUPPORT:96,ECONNRESET:104,ENOBUFS:105,EAFNOSUPPORT:97,EPROTOTYPE:91,ENOTSOCK:88,ENOPROTOOPT:92,ESHUTDOWN:108,ECONNREFUSED:111,EADDRINUSE:98,ECONNABORTED:103,ENETUNREACH:101,ENETDOWN:100,ETIMEDOUT:110,EHOSTDOWN:112,EHOSTUNREACH:113,EINPROGRESS:115,EALREADY:114,EDESTADDRREQ:89,EMSGSIZE:90,EPROTONOSUPPORT:93,ESOCKTNOSUPPORT:94,EADDRNOTAVAIL:99,ENETRESET:102,EISCONN:106,ENOTCONN:107,ETOOMANYREFS:109,EUSERS:87,EDQUOT:122,ESTALE:116,ENOTSUP:95,ENOMEDIUM:123,EILSEQ:84,EOVERFLOW:75,ECANCELED:125,ENOTRECOVERABLE:131,EOWNERDEAD:130,ESTRPIPE:86};function _sysconf(name){switch(name){case 30:return PAGE_SIZE;case 85:var maxHeapSize=2*1024*1024*1024-16777216;maxHeapSize=HEAPU8.length;return maxHeapSize/PAGE_SIZE;case 132:case 133:case 12:case 137:case 138:case 15:case 235:case 16:case 17:case 18:case 19:case 20:case 149:case 13:case 10:case 236:case 153:case 9:case 21:case 22:case 159:case 154:case 14:case 77:case 78:case 139:case 80:case 81:case 82:case 68:case 67:case 164:case 11:case 29:case 47:case 48:case 95:case 52:case 51:case 46:return 200809;case 79:return 0;case 27:case 246:case 127:case 128:case 23:case 24:case 160:case 161:case 181:case 182:case 242:case 183:case 184:case 243:case 244:case 245:case 165:case 178:case 179:case 49:case 50:case 168:case 169:case 175:case 170:case 171:case 172:case 97:case 76:case 32:case 173:case 35:return-1;case 176:case 177:case 7:case 155:case 8:case 157:case 125:case 126:case 92:case 93:case 129:case 130:case 131:case 94:case 91:return 1;case 74:case 60:case 69:case 70:case 4:return 1024;case 31:case 42:case 72:return 32;case 87:case 26:case 33:return 2147483647;case 34:case 1:return 47839;case 38:case 36:return 99;case 43:case 37:return 2048;case 0:return 2097152;case 3:return 65536;case 28:return 32768;case 44:return 32767;case 75:return 16384;case 39:return 1e3;case 89:return 700;case 71:return 256;case 40:return 255;case 2:return 100;case 180:return 64;case 25:return 20;case 5:return 16;case 6:return 6;case 73:return 4;case 84:{if(typeof navigator==="object")return navigator["hardwareConcurrency"]||1;return 1}}___setErrNo(ERRNO_CODES.EINVAL);return-1}Module["_sbrk"]=_sbrk;Module["_memmove"]=_memmove;Module["___uremdi3"]=___uremdi3;DYNAMICTOP_PTR=allocate(1,"i32",ALLOC_STATIC);STACK_BASE=STACKTOP=Runtime.alignMemory(STATICTOP);STACK_MAX=STACK_BASE+TOTAL_STACK;DYNAMIC_BASE=Runtime.alignMemory(STACK_MAX);HEAP32[DYNAMICTOP_PTR>>2]=DYNAMIC_BASE;staticSealed=true;Module.asmGlobalArg={"Math":Math,"Int8Array":Int8Array,"Int16Array":Int16Array,"Int32Array":Int32Array,"Uint8Array":Uint8Array,"Uint16Array":Uint16Array,"Uint32Array":Uint32Array,"Float32Array":Float32Array,"Float64Array":Float64Array,"NaN":NaN,"Infinity":Infinity};Module.asmLibraryArg={"abort":abort,"assert":assert,"enlargeMemory":enlargeMemory,"getTotalMemory":getTotalMemory,"abortOnCannotGrowMemory":abortOnCannotGrowMemory,"_emscripten_asm_const_i":_emscripten_asm_const_i,"_sysconf":_sysconf,"_abort":_abort,"___setErrNo":___setErrNo,"_emscripten_memcpy_big":_emscripten_memcpy_big,"_emscripten_asm_const_v":_emscripten_asm_const_v,"___assert_fail":___assert_fail,"DYNAMICTOP_PTR":DYNAMICTOP_PTR,"tempDoublePtr":tempDoublePtr,"ABORT":ABORT,"STACKTOP":STACKTOP,"STACK_MAX":STACK_MAX,"cttz_i8":cttz_i8};// EMSCRIPTEN_START_ASM +var asm=(function(global,env,buffer) { +"use asm";var a=new global.Int8Array(buffer);var b=new global.Int16Array(buffer);var c=new global.Int32Array(buffer);var d=new global.Uint8Array(buffer);var e=new global.Uint16Array(buffer);var f=new global.Uint32Array(buffer);var g=new global.Float32Array(buffer);var h=new global.Float64Array(buffer);var i=env.DYNAMICTOP_PTR|0;var j=env.tempDoublePtr|0;var k=env.ABORT|0;var l=env.STACKTOP|0;var m=env.STACK_MAX|0;var n=env.cttz_i8|0;var o=0;var p=0;var q=0;var r=0;var s=global.NaN,t=global.Infinity;var u=0,v=0,w=0,x=0,y=0.0;var z=0;var A=global.Math.floor;var B=global.Math.abs;var C=global.Math.sqrt;var D=global.Math.pow;var E=global.Math.cos;var F=global.Math.sin;var G=global.Math.tan;var H=global.Math.acos;var I=global.Math.asin;var J=global.Math.atan;var K=global.Math.atan2;var L=global.Math.exp;var M=global.Math.log;var N=global.Math.ceil;var O=global.Math.imul;var P=global.Math.min;var Q=global.Math.max;var R=global.Math.clz32;var S=env.abort;var T=env.assert;var U=env.enlargeMemory;var V=env.getTotalMemory;var W=env.abortOnCannotGrowMemory;var X=env._emscripten_asm_const_i;var Y=env._sysconf;var Z=env._abort;var _=env.___setErrNo;var $=env._emscripten_memcpy_big;var aa=env._emscripten_asm_const_v;var ba=env.___assert_fail;var ca=0.0; +// EMSCRIPTEN_START_FUNCS +function ga(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0;f=l;g=l=l+63&-64;l=l+256|0;d=0;do{h=Te(b+(d<<3)|0)|0;e=g+128+(d<<3)|0;c[e>>2]=h;c[e+4>>2]=z;d=d+1|0}while((d|0)!=16);d=g;b=a;e=d+64|0;do{c[d>>2]=c[b>>2];d=d+4|0;b=b+4|0}while((d|0)<(e|0));c[g+88>>2]=1595750129;c[g+88+4>>2]=-1521486534;ca=c[a+64>>2]^-1377402159;r=c[a+64+4>>2]^1359893119;h=c[a+72>>2]^725511199;w=c[a+72+4>>2]^-1694144372;n=c[a+80>>2]^-79577749;s=c[a+80+4>>2]^528734635;K=c[a+88>>2]^327033209;ba=c[a+88+4>>2]^1541459225;c[g+120>>2]=K;c[g+120+4>>2]=ba;u=c[g+32>>2]|0;e=c[g+32+4>>2]|0;N=fg(u|0,e|0,c[g>>2]|0,c[g+4>>2]|0)|0;N=fg(N|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;d=z;r=Ze(ca^N,r^d,32)|0;ca=z;V=fg(r|0,ca|0,-205731576,1779033703)|0;O=z;e=Ze(u^V,e^O,24)|0;u=z;d=fg(N|0,d|0,e|0,u|0)|0;N=g+128+8|0;d=fg(d|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;R=z;c[g>>2]=d;c[g+4>>2]=R;ca=Ze(r^d,ca^R,16)|0;r=z;c[g+96>>2]=ca;c[g+96+4>>2]=r;r=fg(V|0,O|0,ca|0,r|0)|0;ca=z;c[g+64>>2]=r;c[g+64+4>>2]=ca;ca=Ze(e^r,u^ca,63)|0;c[g+32>>2]=ca;c[g+32+4>>2]=z;ca=c[g+40>>2]|0;u=c[g+40+4>>2]|0;r=fg(ca|0,u|0,c[g+8>>2]|0,c[g+8+4>>2]|0)|0;e=g+128+16|0;r=fg(r|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;O=z;w=Ze(h^r,w^O,32)|0;h=z;V=fg(w|0,h|0,-2067093701,-1150833019)|0;D=z;u=Ze(ca^V,u^D,24)|0;ca=z;O=fg(r|0,O|0,u|0,ca|0)|0;r=g+128+24|0;O=fg(O|0,z|0,c[r>>2]|0,c[r+4>>2]|0)|0;x=z;h=Ze(w^O,h^x,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;D=fg(V|0,D|0,h|0,w|0)|0;V=z;c[g+72>>2]=D;c[g+72+4>>2]=V;V=Ze(u^D,ca^V,63)|0;ca=z;D=c[g+48>>2]|0;u=c[g+48+4>>2]|0;t=fg(D|0,u|0,c[g+16>>2]|0,c[g+16+4>>2]|0)|0;X=g+128+32|0;t=fg(t|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;i=z;s=Ze(n^t,s^i,32)|0;n=z;C=fg(s|0,n|0,-23791573,1013904242)|0;b=z;u=Ze(D^C,u^b,24)|0;D=z;i=fg(t|0,i|0,u|0,D|0)|0;t=g+128+40|0;i=fg(i|0,z|0,c[t>>2]|0,c[t+4>>2]|0)|0;P=z;n=Ze(s^i,n^P,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;b=fg(C|0,b|0,n|0,s|0)|0;C=z;D=Ze(u^b,D^C,63)|0;u=z;m=c[g+56>>2]|0;o=c[g+56+4>>2]|0;v=fg(m|0,o|0,c[g+24>>2]|0,c[g+24+4>>2]|0)|0;q=g+128+48|0;v=fg(v|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;aa=z;ba=Ze(K^v,ba^aa,32)|0;K=z;B=fg(c[g+88>>2]|0,c[g+88+4>>2]|0,ba|0,K|0)|0;F=z;o=Ze(m^B,o^F,24)|0;m=z;aa=fg(v|0,aa|0,o|0,m|0)|0;v=g+128+56|0;aa=fg(aa|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;y=z;K=Ze(ba^aa,K^y,16)|0;ba=z;F=fg(B|0,F|0,K|0,ba|0)|0;B=z;m=Ze(o^F,m^B,63)|0;o=z;R=fg(V|0,ca|0,d|0,R|0)|0;d=g+128+64|0;R=fg(R|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;S=z;ba=Ze(K^R,ba^S,32)|0;K=z;C=fg(b|0,C|0,ba|0,K|0)|0;b=z;ca=Ze(V^C,ca^b,24)|0;V=z;S=fg(R|0,S|0,ca|0,V|0)|0;R=g+128+72|0;S=fg(S|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;$=z;K=Ze(ba^S,K^$,16)|0;ba=z;c[g+120>>2]=K;c[g+120+4>>2]=ba;ba=fg(C|0,b|0,K|0,ba|0)|0;K=z;c[g+80>>2]=ba;c[g+80+4>>2]=K;K=Ze(ca^ba,V^K,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;x=fg(D|0,u|0,O|0,x|0)|0;O=g+128+80|0;ba=c[O>>2]|0;ca=c[O+4>>2]|0;x=fg(x|0,z|0,ba|0,ca|0)|0;b=z;C=Ze(c[g+96>>2]^x,c[g+96+4>>2]^b,32)|0;A=z;B=fg(F|0,B|0,C|0,A|0)|0;F=z;u=Ze(D^B,u^F,24)|0;D=z;b=fg(x|0,b|0,u|0,D|0)|0;x=g+128+88|0;b=fg(b|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;M=z;A=Ze(C^b,A^M,16)|0;C=z;F=fg(B|0,F|0,A|0,C|0)|0;B=z;c[g+88>>2]=F;c[g+88+4>>2]=B;B=Ze(u^F,D^B,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;P=fg(m|0,o|0,i|0,P|0)|0;i=g+128+96|0;P=fg(P|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;F=z;w=Ze(h^P,w^F,32)|0;h=z;u=fg(c[g+64>>2]|0,c[g+64+4>>2]|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;F=fg(P|0,F|0,o|0,m|0)|0;P=g+128+104|0;da=c[P>>2]|0;_=c[P+4>>2]|0;F=fg(F|0,z|0,da|0,_|0)|0;E=z;h=Ze(w^F,h^E,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;k=c[g+32>>2]|0;ga=c[g+32+4>>2]|0;y=fg(k|0,ga|0,aa|0,y|0)|0;aa=g+128+112|0;T=c[aa>>2]|0;j=c[aa+4>>2]|0;y=fg(y|0,z|0,T|0,j|0)|0;ia=z;s=Ze(n^y,s^ia,32)|0;n=z;I=fg(c[g+72>>2]|0,c[g+72+4>>2]|0,s|0,n|0)|0;U=z;ga=Ze(k^I,ga^U,24)|0;k=z;ia=fg(y|0,ia|0,ga|0,k|0)|0;y=g+128+120|0;H=c[y>>2]|0;fa=c[y+4>>2]|0;ia=fg(ia|0,z|0,H|0,fa|0)|0;Q=z;n=Ze(s^ia,n^Q,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;k=Ze(ga^U,k^I,63)|0;ga=z;$=fg(S|0,$|0,k|0,ga|0)|0;j=fg($|0,z|0,T|0,j|0)|0;T=z;C=Ze(A^j,C^T,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;ga=Ze(k^u,ga^p,24)|0;k=z;T=fg(j|0,T|0,ga|0,k|0)|0;ca=fg(T|0,z|0,ba|0,ca|0)|0;ba=z;A=Ze(C^ca,A^ba,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;k=Ze(ga^p,k^u,63)|0;c[g+32>>2]=k;c[g+32+4>>2]=z;M=fg(K|0,V|0,b|0,M|0)|0;M=fg(M|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;b=z;w=Ze(h^M,w^b,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;b=fg(M|0,b|0,V|0,K|0)|0;b=fg(b|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;M=z;h=Ze(w^b,h^M,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;E=fg(B|0,D|0,F|0,E|0)|0;E=fg(E|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;F=z;s=Ze(n^E,s^F,32)|0;n=z;k=fg(c[g+80>>2]|0,c[g+80+4>>2]|0,s|0,n|0)|0;ga=z;D=Ze(B^k,D^ga,24)|0;B=z;F=fg(E|0,F|0,D|0,B|0)|0;fa=fg(F|0,z|0,H|0,fa|0)|0;H=z;n=Ze(s^fa,n^H,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;ga=fg(k|0,ga|0,n|0,s|0)|0;k=z;B=Ze(D^ga,B^k,63)|0;D=z;Q=fg(m|0,o|0,ia|0,Q|0)|0;_=fg(Q|0,z|0,da|0,_|0)|0;da=z;Q=Ze(c[g+120>>2]^_,c[g+120+4>>2]^da,32)|0;ia=z;F=fg(c[g+88>>2]|0,c[g+88+4>>2]|0,Q|0,ia|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;da=fg(_|0,da|0,o|0,m|0)|0;da=fg(da|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;_=z;ia=Ze(Q^da,ia^_,16)|0;Q=z;E=fg(F|0,E|0,ia|0,Q|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;ba=fg(K|0,V|0,ca|0,ba|0)|0;ba=fg(ba|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;ca=z;Q=Ze(ia^ba,Q^ca,32)|0;ia=z;k=fg(ga|0,k|0,Q|0,ia|0)|0;ga=z;V=Ze(K^k,V^ga,24)|0;K=z;ca=fg(ba|0,ca|0,V|0,K|0)|0;ba=c[i>>2]|0;T=c[i+4>>2]|0;ca=fg(ca|0,z|0,ba|0,T|0)|0;j=z;ia=Ze(Q^ca,ia^j,16)|0;Q=z;c[g+120>>2]=ia;c[g+120+4>>2]=Q;Q=fg(k|0,ga|0,ia|0,Q|0)|0;ia=z;c[g+80>>2]=Q;c[g+80+4>>2]=ia;K=Ze(V^Q,K^ia,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;M=fg(B|0,D|0,b|0,M|0)|0;b=c[g+128>>2]|0;ga=c[g+128+4>>2]|0;M=fg(M|0,z|0,b|0,ga|0)|0;k=z;C=Ze(A^M,C^k,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;k=fg(M|0,k|0,D|0,B|0)|0;M=c[e>>2]|0;$=c[e+4>>2]|0;k=fg(k|0,z|0,M|0,$|0)|0;S=z;A=Ze(C^k,A^S,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;H=fg(m|0,o|0,fa|0,H|0)|0;fa=c[x>>2]|0;ha=c[x+4>>2]|0;H=fg(H|0,z|0,fa|0,ha|0)|0;L=z;w=Ze(h^H,w^L,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;L=fg(H|0,L|0,o|0,m|0)|0;L=fg(L|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;H=z;h=Ze(w^L,h^H,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;Z=c[g+32>>2]|0;W=c[g+32+4>>2]|0;_=fg(Z|0,W|0,da|0,_|0)|0;da=c[t>>2]|0;G=c[t+4>>2]|0;_=fg(_|0,z|0,da|0,G|0)|0;ea=z;s=Ze(n^_,s^ea,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;W=Ze(Z^I,W^U,24)|0;Z=z;ea=fg(_|0,ea|0,W|0,Z|0)|0;_=c[r>>2]|0;J=c[r+4>>2]|0;ea=fg(ea|0,z|0,_|0,J|0)|0;Y=z;n=Ze(s^ea,n^Y,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;Z=Ze(W^U,Z^I,63)|0;W=z;j=fg(ca|0,j|0,Z|0,W|0)|0;ha=fg(j|0,z|0,fa|0,ha|0)|0;fa=z;C=Ze(A^ha,C^fa,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;W=Ze(Z^u,W^p,24)|0;Z=z;fa=fg(ha|0,fa|0,W|0,Z|0)|0;fa=fg(fa|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;ha=z;A=Ze(C^fa,A^ha,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;Z=Ze(W^p,Z^u,63)|0;c[g+32>>2]=Z;c[g+32+4>>2]=z;S=fg(K|0,V|0,k|0,S|0)|0;T=fg(S|0,z|0,ba|0,T|0)|0;ba=z;w=Ze(h^T,w^ba,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;ba=fg(T|0,ba|0,V|0,K|0)|0;ga=fg(ba|0,z|0,b|0,ga|0)|0;b=z;h=Ze(w^ga,h^b,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;H=fg(B|0,D|0,L|0,H|0)|0;G=fg(H|0,z|0,da|0,G|0)|0;da=z;s=Ze(n^G,s^da,32)|0;n=z;ia=fg(Q|0,ia|0,s|0,n|0)|0;Q=z;D=Ze(B^ia,D^Q,24)|0;B=z;da=fg(G|0,da|0,D|0,B|0)|0;$=fg(da|0,z|0,M|0,$|0)|0;M=z;n=Ze(s^$,n^M,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;Q=fg(ia|0,Q|0,n|0,s|0)|0;ia=z;B=Ze(D^Q,B^ia,63)|0;D=z;Y=fg(m|0,o|0,ea|0,Y|0)|0;Y=fg(Y|0,z|0,c[y>>2]|0,c[y+4>>2]|0)|0;ea=z;da=Ze(c[g+120>>2]^Y,c[g+120+4>>2]^ea,32)|0;G=z;F=fg(E|0,F|0,da|0,G|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;ea=fg(Y|0,ea|0,o|0,m|0)|0;ea=fg(ea|0,z|0,c[P>>2]|0,c[P+4>>2]|0)|0;Y=z;G=Ze(da^ea,G^Y,16)|0;da=z;E=fg(F|0,E|0,G|0,da|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;ha=fg(K|0,V|0,fa|0,ha|0)|0;ha=fg(ha|0,z|0,c[O>>2]|0,c[O+4>>2]|0)|0;fa=z;da=Ze(G^ha,da^fa,32)|0;G=z;ia=fg(Q|0,ia|0,da|0,G|0)|0;Q=z;V=Ze(K^ia,V^Q,24)|0;K=z;fa=fg(ha|0,fa|0,V|0,K|0)|0;fa=fg(fa|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;ha=z;G=Ze(da^fa,G^ha,16)|0;da=z;c[g+120>>2]=G;c[g+120+4>>2]=da;da=fg(ia|0,Q|0,G|0,da|0)|0;G=z;c[g+80>>2]=da;c[g+80+4>>2]=G;K=Ze(V^da,K^G,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;b=fg(B|0,D|0,ga|0,b|0)|0;J=fg(b|0,z|0,_|0,J|0)|0;_=z;C=Ze(A^J,C^_,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;_=fg(J|0,_|0,D|0,B|0)|0;_=fg(_|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;J=z;A=Ze(C^_,A^J,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;M=fg(m|0,o|0,$|0,M|0)|0;$=c[v>>2]|0;b=c[v+4>>2]|0;M=fg(M|0,z|0,$|0,b|0)|0;ga=z;w=Ze(h^M,w^ga,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;ga=fg(M|0,ga|0,o|0,m|0)|0;M=c[N>>2]|0;Q=c[N+4>>2]|0;ga=fg(ga|0,z|0,M|0,Q|0)|0;ia=z;h=Ze(w^ga,h^ia,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;H=c[g+32>>2]|0;L=c[g+32+4>>2]|0;Y=fg(H|0,L|0,ea|0,Y|0)|0;ea=c[R>>2]|0;ba=c[R+4>>2]|0;Y=fg(Y|0,z|0,ea|0,ba|0)|0;T=z;s=Ze(n^Y,s^T,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;L=Ze(H^I,L^U,24)|0;H=z;T=fg(Y|0,T|0,L|0,H|0)|0;T=fg(T|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;Y=z;n=Ze(s^T,n^Y,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;H=Ze(L^U,H^I,63)|0;L=z;ha=fg(fa|0,ha|0,H|0,L|0)|0;b=fg(ha|0,z|0,$|0,b|0)|0;$=z;C=Ze(A^b,C^$,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;L=Ze(H^u,L^p,24)|0;H=z;$=fg(b|0,$|0,L|0,H|0)|0;ba=fg($|0,z|0,ea|0,ba|0)|0;ea=z;A=Ze(C^ba,A^ea,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;H=Ze(L^p,H^u,63)|0;c[g+32>>2]=H;c[g+32+4>>2]=z;J=fg(K|0,V|0,_|0,J|0)|0;J=fg(J|0,z|0,c[r>>2]|0,c[r+4>>2]|0)|0;_=z;w=Ze(h^J,w^_,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;_=fg(J|0,_|0,V|0,K|0)|0;Q=fg(_|0,z|0,M|0,Q|0)|0;M=z;h=Ze(w^Q,h^M,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;ia=fg(B|0,D|0,ga|0,ia|0)|0;ia=fg(ia|0,z|0,c[P>>2]|0,c[P+4>>2]|0)|0;ga=z;s=Ze(n^ia,s^ga,32)|0;n=z;G=fg(da|0,G|0,s|0,n|0)|0;da=z;D=Ze(B^G,D^da,24)|0;B=z;ga=fg(ia|0,ga|0,D|0,B|0)|0;ga=fg(ga|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;ia=z;n=Ze(s^ga,n^ia,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;da=fg(G|0,da|0,n|0,s|0)|0;G=z;B=Ze(D^da,B^G,63)|0;D=z;Y=fg(m|0,o|0,T|0,Y|0)|0;Y=fg(Y|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;T=z;_=Ze(c[g+120>>2]^Y,c[g+120+4>>2]^T,32)|0;J=z;F=fg(E|0,F|0,_|0,J|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;T=fg(Y|0,T|0,o|0,m|0)|0;T=fg(T|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;Y=z;J=Ze(_^T,J^Y,16)|0;_=z;E=fg(F|0,E|0,J|0,_|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;ea=fg(K|0,V|0,ba|0,ea|0)|0;ea=fg(ea|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;ba=z;_=Ze(J^ea,_^ba,32)|0;J=z;G=fg(da|0,G|0,_|0,J|0)|0;da=z;V=Ze(K^G,V^da,24)|0;K=z;ba=fg(ea|0,ba|0,V|0,K|0)|0;ba=fg(ba|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;ea=z;J=Ze(_^ba,J^ea,16)|0;_=z;c[g+120>>2]=J;c[g+120+4>>2]=_;_=fg(G|0,da|0,J|0,_|0)|0;J=z;c[g+80>>2]=_;c[g+80+4>>2]=J;K=Ze(V^_,K^J,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;M=fg(B|0,D|0,Q|0,M|0)|0;Q=c[t>>2]|0;da=c[t+4>>2]|0;M=fg(M|0,z|0,Q|0,da|0)|0;G=z;C=Ze(A^M,C^G,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;G=fg(M|0,G|0,D|0,B|0)|0;M=c[O>>2]|0;H=c[O+4>>2]|0;G=fg(G|0,z|0,M|0,H|0)|0;L=z;A=Ze(C^G,A^L,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;ia=fg(m|0,o|0,ga|0,ia|0)|0;ga=c[X>>2]|0;$=c[X+4>>2]|0;ia=fg(ia|0,z|0,ga|0,$|0)|0;b=z;w=Ze(h^ia,w^b,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;b=fg(ia|0,b|0,o|0,m|0)|0;ia=c[g+128>>2]|0;ha=c[g+128+4>>2]|0;b=fg(b|0,z|0,ia|0,ha|0)|0;fa=z;h=Ze(w^b,h^fa,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;S=c[g+32>>2]|0;k=c[g+32+4>>2]|0;Y=fg(S|0,k|0,T|0,Y|0)|0;T=c[y>>2]|0;Z=c[y+4>>2]|0;Y=fg(Y|0,z|0,T|0,Z|0)|0;W=z;s=Ze(n^Y,s^W,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;k=Ze(S^I,k^U,24)|0;S=z;W=fg(Y|0,W|0,k|0,S|0)|0;W=fg(W|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;Y=z;n=Ze(s^W,n^Y,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;S=Ze(k^U,S^I,63)|0;k=z;ea=fg(ba|0,ea|0,S|0,k|0)|0;ea=fg(ea|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;ba=z;C=Ze(A^ea,C^ba,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;k=Ze(S^u,k^p,24)|0;S=z;ba=fg(ea|0,ba|0,k|0,S|0)|0;ha=fg(ba|0,z|0,ia|0,ha|0)|0;ia=z;A=Ze(C^ha,A^ia,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;S=Ze(k^p,S^u,63)|0;c[g+32>>2]=S;c[g+32+4>>2]=z;L=fg(K|0,V|0,G|0,L|0)|0;da=fg(L|0,z|0,Q|0,da|0)|0;Q=z;w=Ze(h^da,w^Q,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;Q=fg(da|0,Q|0,V|0,K|0)|0;Q=fg(Q|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;da=z;h=Ze(w^Q,h^da,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;fa=fg(B|0,D|0,b|0,fa|0)|0;fa=fg(fa|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;b=z;s=Ze(n^fa,s^b,32)|0;n=z;J=fg(_|0,J|0,s|0,n|0)|0;_=z;D=Ze(B^J,D^_,24)|0;B=z;b=fg(fa|0,b|0,D|0,B|0)|0;$=fg(b|0,z|0,ga|0,$|0)|0;ga=z;n=Ze(s^$,n^ga,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;_=fg(J|0,_|0,n|0,s|0)|0;J=z;B=Ze(D^_,B^J,63)|0;D=z;Y=fg(m|0,o|0,W|0,Y|0)|0;H=fg(Y|0,z|0,M|0,H|0)|0;M=z;Y=Ze(c[g+120>>2]^H,c[g+120+4>>2]^M,32)|0;W=z;F=fg(E|0,F|0,Y|0,W|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;M=fg(H|0,M|0,o|0,m|0)|0;Z=fg(M|0,z|0,T|0,Z|0)|0;T=z;W=Ze(Y^Z,W^T,16)|0;Y=z;E=fg(F|0,E|0,W|0,Y|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;ia=fg(K|0,V|0,ha|0,ia|0)|0;ia=fg(ia|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;ha=z;Y=Ze(W^ia,Y^ha,32)|0;W=z;J=fg(_|0,J|0,Y|0,W|0)|0;_=z;V=Ze(K^J,V^_,24)|0;K=z;ha=fg(ia|0,ha|0,V|0,K|0)|0;ha=fg(ha|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;ia=z;W=Ze(Y^ha,W^ia,16)|0;Y=z;c[g+120>>2]=W;c[g+120+4>>2]=Y;Y=fg(J|0,_|0,W|0,Y|0)|0;W=z;c[g+80>>2]=Y;c[g+80+4>>2]=W;K=Ze(V^Y,K^W,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;da=fg(B|0,D|0,Q|0,da|0)|0;Q=c[x>>2]|0;_=c[x+4>>2]|0;da=fg(da|0,z|0,Q|0,_|0)|0;J=z;C=Ze(A^da,C^J,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;J=fg(da|0,J|0,D|0,B|0)|0;da=c[i>>2]|0;M=c[i+4>>2]|0;J=fg(J|0,z|0,da|0,M|0)|0;H=z;A=Ze(C^J,A^H,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;ga=fg(m|0,o|0,$|0,ga|0)|0;$=c[q>>2]|0;b=c[q+4>>2]|0;ga=fg(ga|0,z|0,$|0,b|0)|0;fa=z;w=Ze(h^ga,w^fa,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;fa=fg(ga|0,fa|0,o|0,m|0)|0;ga=c[d>>2]|0;L=c[d+4>>2]|0;fa=fg(fa|0,z|0,ga|0,L|0)|0;G=z;h=Ze(w^fa,h^G,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;S=c[g+32>>2]|0;k=c[g+32+4>>2]|0;T=fg(S|0,k|0,Z|0,T|0)|0;Z=c[r>>2]|0;ba=c[r+4>>2]|0;T=fg(T|0,z|0,Z|0,ba|0)|0;ea=z;s=Ze(n^T,s^ea,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;k=Ze(S^I,k^U,24)|0;S=z;ea=fg(T|0,ea|0,k|0,S|0)|0;T=c[P>>2]|0;j=c[P+4>>2]|0;ea=fg(ea|0,z|0,T|0,j|0)|0;ca=z;n=Ze(s^ea,n^ca,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;S=Ze(k^U,S^I,63)|0;k=z;ia=fg(ha|0,ia|0,S|0,k|0)|0;ia=fg(ia|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;ha=z;C=Ze(A^ia,C^ha,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;k=Ze(S^u,k^p,24)|0;S=z;ha=fg(ia|0,ha|0,k|0,S|0)|0;M=fg(ha|0,z|0,da|0,M|0)|0;da=z;A=Ze(C^M,A^da,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;S=Ze(k^p,S^u,63)|0;c[g+32>>2]=S;c[g+32+4>>2]=z;H=fg(K|0,V|0,J|0,H|0)|0;b=fg(H|0,z|0,$|0,b|0)|0;$=z;w=Ze(h^b,w^$,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;$=fg(b|0,$|0,V|0,K|0)|0;$=fg($|0,z|0,c[O>>2]|0,c[O+4>>2]|0)|0;b=z;h=Ze(w^$,h^b,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;G=fg(B|0,D|0,fa|0,G|0)|0;G=fg(G|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;fa=z;s=Ze(n^G,s^fa,32)|0;n=z;W=fg(Y|0,W|0,s|0,n|0)|0;Y=z;D=Ze(B^W,D^Y,24)|0;B=z;fa=fg(G|0,fa|0,D|0,B|0)|0;_=fg(fa|0,z|0,Q|0,_|0)|0;Q=z;n=Ze(s^_,n^Q,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;Y=fg(W|0,Y|0,n|0,s|0)|0;W=z;B=Ze(D^Y,B^W,63)|0;D=z;ca=fg(m|0,o|0,ea|0,ca|0)|0;L=fg(ca|0,z|0,ga|0,L|0)|0;ga=z;ca=Ze(c[g+120>>2]^L,c[g+120+4>>2]^ga,32)|0;ea=z;F=fg(E|0,F|0,ca|0,ea|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;ga=fg(L|0,ga|0,o|0,m|0)|0;ba=fg(ga|0,z|0,Z|0,ba|0)|0;Z=z;ea=Ze(ca^ba,ea^Z,16)|0;ca=z;E=fg(F|0,E|0,ea|0,ca|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;da=fg(K|0,V|0,M|0,da|0)|0;da=fg(da|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;M=z;ca=Ze(ea^da,ca^M,32)|0;ea=z;W=fg(Y|0,W|0,ca|0,ea|0)|0;Y=z;V=Ze(K^W,V^Y,24)|0;K=z;M=fg(da|0,M|0,V|0,K|0)|0;j=fg(M|0,z|0,T|0,j|0)|0;T=z;ea=Ze(ca^j,ea^T,16)|0;ca=z;c[g+120>>2]=ea;c[g+120+4>>2]=ca;ca=fg(W|0,Y|0,ea|0,ca|0)|0;ea=z;c[g+80>>2]=ca;c[g+80+4>>2]=ea;K=Ze(V^ca,K^ea,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;b=fg(B|0,D|0,$|0,b|0)|0;b=fg(b|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;$=z;C=Ze(A^b,C^$,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;$=fg(b|0,$|0,D|0,B|0)|0;b=c[t>>2]|0;Y=c[t+4>>2]|0;$=fg($|0,z|0,b|0,Y|0)|0;W=z;A=Ze(C^$,A^W,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;Q=fg(m|0,o|0,_|0,Q|0)|0;_=c[y>>2]|0;M=c[y+4>>2]|0;Q=fg(Q|0,z|0,_|0,M|0)|0;da=z;w=Ze(h^Q,w^da,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;da=fg(Q|0,da|0,o|0,m|0)|0;Q=c[aa>>2]|0;ga=c[aa+4>>2]|0;da=fg(da|0,z|0,Q|0,ga|0)|0;L=z;h=Ze(w^da,h^L,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;fa=c[g+32>>2]|0;G=c[g+32+4>>2]|0;Z=fg(fa|0,G|0,ba|0,Z|0)|0;ba=c[N>>2]|0;H=c[N+4>>2]|0;Z=fg(Z|0,z|0,ba|0,H|0)|0;J=z;s=Ze(n^Z,s^J,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;G=Ze(fa^I,G^U,24)|0;fa=z;J=fg(Z|0,J|0,G|0,fa|0)|0;J=fg(J|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;Z=z;n=Ze(s^J,n^Z,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;fa=Ze(G^U,fa^I,63)|0;G=z;T=fg(j|0,T|0,fa|0,G|0)|0;T=fg(T|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;j=z;C=Ze(A^T,C^j,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;G=Ze(fa^u,G^p,24)|0;fa=z;j=fg(T|0,j|0,G|0,fa|0)|0;Y=fg(j|0,z|0,b|0,Y|0)|0;b=z;A=Ze(C^Y,A^b,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;fa=Ze(G^p,fa^u,63)|0;c[g+32>>2]=fa;c[g+32+4>>2]=z;W=fg(K|0,V|0,$|0,W|0)|0;H=fg(W|0,z|0,ba|0,H|0)|0;ba=z;w=Ze(h^H,w^ba,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;ba=fg(H|0,ba|0,V|0,K|0)|0;M=fg(ba|0,z|0,_|0,M|0)|0;_=z;h=Ze(w^M,h^_,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;L=fg(B|0,D|0,da|0,L|0)|0;ga=fg(L|0,z|0,Q|0,ga|0)|0;Q=z;s=Ze(n^ga,s^Q,32)|0;n=z;ea=fg(ca|0,ea|0,s|0,n|0)|0;ca=z;D=Ze(B^ea,D^ca,24)|0;B=z;Q=fg(ga|0,Q|0,D|0,B|0)|0;ga=c[P>>2]|0;L=c[P+4>>2]|0;Q=fg(Q|0,z|0,ga|0,L|0)|0;da=z;n=Ze(s^Q,n^da,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;ca=fg(ea|0,ca|0,n|0,s|0)|0;ea=z;B=Ze(D^ca,B^ea,63)|0;D=z;Z=fg(m|0,o|0,J|0,Z|0)|0;Z=fg(Z|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;J=z;ba=Ze(c[g+120>>2]^Z,c[g+120+4>>2]^J,32)|0;H=z;F=fg(E|0,F|0,ba|0,H|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;J=fg(Z|0,J|0,o|0,m|0)|0;J=fg(J|0,z|0,c[O>>2]|0,c[O+4>>2]|0)|0;Z=z;H=Ze(ba^J,H^Z,16)|0;ba=z;E=fg(F|0,E|0,H|0,ba|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;b=fg(K|0,V|0,Y|0,b|0)|0;b=fg(b|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;Y=z;ba=Ze(H^b,ba^Y,32)|0;H=z;ea=fg(ca|0,ea|0,ba|0,H|0)|0;ca=z;V=Ze(K^ea,V^ca,24)|0;K=z;Y=fg(b|0,Y|0,V|0,K|0)|0;b=c[v>>2]|0;W=c[v+4>>2]|0;Y=fg(Y|0,z|0,b|0,W|0)|0;$=z;H=Ze(ba^Y,H^$,16)|0;ba=z;c[g+120>>2]=H;c[g+120+4>>2]=ba;ba=fg(ea|0,ca|0,H|0,ba|0)|0;H=z;c[g+80>>2]=ba;c[g+80+4>>2]=H;K=Ze(V^ba,K^H,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;_=fg(B|0,D|0,M|0,_|0)|0;_=fg(_|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;M=z;C=Ze(A^_,C^M,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;M=fg(_|0,M|0,D|0,B|0)|0;_=c[r>>2]|0;ca=c[r+4>>2]|0;M=fg(M|0,z|0,_|0,ca|0)|0;ea=z;A=Ze(C^M,A^ea,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;da=fg(m|0,o|0,Q|0,da|0)|0;Q=c[R>>2]|0;fa=c[R+4>>2]|0;da=fg(da|0,z|0,Q|0,fa|0)|0;G=z;w=Ze(h^da,w^G,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;G=fg(da|0,G|0,o|0,m|0)|0;G=fg(G|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;da=z;h=Ze(w^G,h^da,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;j=c[g+32>>2]|0;T=c[g+32+4>>2]|0;Z=fg(j|0,T|0,J|0,Z|0)|0;Z=fg(Z|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;J=z;s=Ze(n^Z,s^J,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;T=Ze(j^I,T^U,24)|0;j=z;J=fg(Z|0,J|0,T|0,j|0)|0;Z=c[x>>2]|0;S=c[x+4>>2]|0;J=fg(J|0,z|0,Z|0,S|0)|0;k=z;n=Ze(s^J,n^k,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;j=Ze(T^U,j^I,63)|0;T=z;$=fg(Y|0,$|0,j|0,T|0)|0;L=fg($|0,z|0,ga|0,L|0)|0;ga=z;C=Ze(A^L,C^ga,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;T=Ze(j^u,T^p,24)|0;j=z;ga=fg(L|0,ga|0,T|0,j|0)|0;S=fg(ga|0,z|0,Z|0,S|0)|0;Z=z;A=Ze(C^S,A^Z,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;j=Ze(T^p,j^u,63)|0;c[g+32>>2]=j;c[g+32+4>>2]=z;ea=fg(K|0,V|0,M|0,ea|0)|0;W=fg(ea|0,z|0,b|0,W|0)|0;b=z;w=Ze(h^W,w^b,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;b=fg(W|0,b|0,V|0,K|0)|0;b=fg(b|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;W=z;h=Ze(w^b,h^W,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;da=fg(B|0,D|0,G|0,da|0)|0;da=fg(da|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;G=z;s=Ze(n^da,s^G,32)|0;n=z;H=fg(ba|0,H|0,s|0,n|0)|0;ba=z;D=Ze(B^H,D^ba,24)|0;B=z;G=fg(da|0,G|0,D|0,B|0)|0;G=fg(G|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;da=z;n=Ze(s^G,n^da,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;ba=fg(H|0,ba|0,n|0,s|0)|0;H=z;B=Ze(D^ba,B^H,63)|0;D=z;k=fg(m|0,o|0,J|0,k|0)|0;ca=fg(k|0,z|0,_|0,ca|0)|0;_=z;k=Ze(c[g+120>>2]^ca,c[g+120+4>>2]^_,32)|0;J=z;F=fg(E|0,F|0,k|0,J|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;_=fg(ca|0,_|0,o|0,m|0)|0;fa=fg(_|0,z|0,Q|0,fa|0)|0;Q=z;J=Ze(k^fa,J^Q,16)|0;k=z;E=fg(F|0,E|0,J|0,k|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;Z=fg(K|0,V|0,S|0,Z|0)|0;Z=fg(Z|0,z|0,c[t>>2]|0,c[t+4>>2]|0)|0;S=z;k=Ze(J^Z,k^S,32)|0;J=z;H=fg(ba|0,H|0,k|0,J|0)|0;ba=z;V=Ze(K^H,V^ba,24)|0;K=z;S=fg(Z|0,S|0,V|0,K|0)|0;S=fg(S|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;Z=z;J=Ze(k^S,J^Z,16)|0;k=z;c[g+120>>2]=J;c[g+120+4>>2]=k;k=fg(H|0,ba|0,J|0,k|0)|0;J=z;c[g+80>>2]=k;c[g+80+4>>2]=J;K=Ze(V^k,K^J,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;W=fg(B|0,D|0,b|0,W|0)|0;b=c[y>>2]|0;ba=c[y+4>>2]|0;W=fg(W|0,z|0,b|0,ba|0)|0;H=z;C=Ze(A^W,C^H,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;H=fg(W|0,H|0,D|0,B|0)|0;H=fg(H|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;W=z;A=Ze(C^H,A^W,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;da=fg(m|0,o|0,G|0,da|0)|0;G=c[d>>2]|0;_=c[d+4>>2]|0;da=fg(da|0,z|0,G|0,_|0)|0;ca=z;w=Ze(h^da,w^ca,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;ca=fg(da|0,ca|0,o|0,m|0)|0;da=c[q>>2]|0;ea=c[q+4>>2]|0;ca=fg(ca|0,z|0,da|0,ea|0)|0;M=z;h=Ze(w^ca,h^M,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;j=c[g+32>>2]|0;T=c[g+32+4>>2]|0;Q=fg(j|0,T|0,fa|0,Q|0)|0;fa=c[e>>2]|0;ga=c[e+4>>2]|0;Q=fg(Q|0,z|0,fa|0,ga|0)|0;L=z;s=Ze(n^Q,s^L,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;T=Ze(j^I,T^U,24)|0;j=z;L=fg(Q|0,L|0,T|0,j|0)|0;L=fg(L|0,z|0,c[O>>2]|0,c[O+4>>2]|0)|0;Q=z;n=Ze(s^L,n^Q,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;j=Ze(T^U,j^I,63)|0;T=z;Z=fg(S|0,Z|0,j|0,T|0)|0;ea=fg(Z|0,z|0,da|0,ea|0)|0;da=z;C=Ze(A^ea,C^da,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;T=Ze(j^u,T^p,24)|0;j=z;da=fg(ea|0,da|0,T|0,j|0)|0;ba=fg(da|0,z|0,b|0,ba|0)|0;b=z;A=Ze(C^ba,A^b,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;j=Ze(T^p,j^u,63)|0;c[g+32>>2]=j;c[g+32+4>>2]=z;W=fg(K|0,V|0,H|0,W|0)|0;W=fg(W|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;H=z;w=Ze(h^W,w^H,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;H=fg(W|0,H|0,V|0,K|0)|0;H=fg(H|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;W=z;h=Ze(w^H,h^W,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;M=fg(B|0,D|0,ca|0,M|0)|0;M=fg(M|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;ca=z;s=Ze(n^M,s^ca,32)|0;n=z;J=fg(k|0,J|0,s|0,n|0)|0;k=z;D=Ze(B^J,D^k,24)|0;B=z;ca=fg(M|0,ca|0,D|0,B|0)|0;ca=fg(ca|0,z|0,c[r>>2]|0,c[r+4>>2]|0)|0;M=z;n=Ze(s^ca,n^M,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;k=fg(J|0,k|0,n|0,s|0)|0;J=z;B=Ze(D^k,B^J,63)|0;D=z;Q=fg(m|0,o|0,L|0,Q|0)|0;Q=fg(Q|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;L=z;j=Ze(c[g+120>>2]^Q,c[g+120+4>>2]^L,32)|0;T=z;F=fg(E|0,F|0,j|0,T|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;L=fg(Q|0,L|0,o|0,m|0)|0;_=fg(L|0,z|0,G|0,_|0)|0;G=z;T=Ze(j^_,T^G,16)|0;j=z;E=fg(F|0,E|0,T|0,j|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;b=fg(K|0,V|0,ba|0,b|0)|0;b=fg(b|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;ba=z;j=Ze(T^b,j^ba,32)|0;T=z;J=fg(k|0,J|0,j|0,T|0)|0;k=z;V=Ze(K^J,V^k,24)|0;K=z;ba=fg(b|0,ba|0,V|0,K|0)|0;ga=fg(ba|0,z|0,fa|0,ga|0)|0;fa=z;T=Ze(j^ga,T^fa,16)|0;j=z;c[g+120>>2]=T;c[g+120+4>>2]=j;j=fg(J|0,k|0,T|0,j|0)|0;T=z;c[g+80>>2]=j;c[g+80+4>>2]=T;K=Ze(V^j,K^T,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;W=fg(B|0,D|0,H|0,W|0)|0;W=fg(W|0,z|0,c[P>>2]|0,c[P+4>>2]|0)|0;H=z;C=Ze(A^W,C^H,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;H=fg(W|0,H|0,D|0,B|0)|0;W=c[v>>2]|0;k=c[v+4>>2]|0;H=fg(H|0,z|0,W|0,k|0)|0;J=z;A=Ze(C^H,A^J,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;M=fg(m|0,o|0,ca|0,M|0)|0;ca=c[N>>2]|0;ba=c[N+4>>2]|0;M=fg(M|0,z|0,ca|0,ba|0)|0;b=z;w=Ze(h^M,w^b,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;b=fg(M|0,b|0,o|0,m|0)|0;M=c[X>>2]|0;L=c[X+4>>2]|0;b=fg(b|0,z|0,M|0,L|0)|0;Q=z;h=Ze(w^b,h^Q,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;da=c[g+32>>2]|0;ea=c[g+32+4>>2]|0;G=fg(da|0,ea|0,_|0,G|0)|0;_=c[O>>2]|0;Z=c[O+4>>2]|0;G=fg(G|0,z|0,_|0,Z|0)|0;S=z;s=Ze(n^G,s^S,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;ea=Ze(da^I,ea^U,24)|0;da=z;S=fg(G|0,S|0,ea|0,da|0)|0;G=c[t>>2]|0;$=c[t+4>>2]|0;S=fg(S|0,z|0,G|0,$|0)|0;Y=z;n=Ze(s^S,n^Y,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;da=Ze(ea^U,da^I,63)|0;ea=z;fa=fg(ga|0,fa|0,da|0,ea|0)|0;Z=fg(fa|0,z|0,_|0,Z|0)|0;_=z;C=Ze(A^Z,C^_,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;ea=Ze(da^u,ea^p,24)|0;da=z;_=fg(Z|0,_|0,ea|0,da|0)|0;_=fg(_|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;Z=z;A=Ze(C^_,A^Z,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;da=Ze(ea^p,da^u,63)|0;c[g+32>>2]=da;c[g+32+4>>2]=z;J=fg(K|0,V|0,H|0,J|0)|0;J=fg(J|0,z|0,c[d>>2]|0,c[d+4>>2]|0)|0;H=z;w=Ze(h^J,w^H,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;H=fg(J|0,H|0,V|0,K|0)|0;L=fg(H|0,z|0,M|0,L|0)|0;M=z;h=Ze(w^L,h^M,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;Q=fg(B|0,D|0,b|0,Q|0)|0;k=fg(Q|0,z|0,W|0,k|0)|0;W=z;s=Ze(n^k,s^W,32)|0;n=z;T=fg(j|0,T|0,s|0,n|0)|0;j=z;D=Ze(B^T,D^j,24)|0;B=z;W=fg(k|0,W|0,D|0,B|0)|0;W=fg(W|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;k=z;n=Ze(s^W,n^k,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;j=fg(T|0,j|0,n|0,s|0)|0;T=z;B=Ze(D^j,B^T,63)|0;D=z;Y=fg(m|0,o|0,S|0,Y|0)|0;ba=fg(Y|0,z|0,ca|0,ba|0)|0;ca=z;Y=Ze(c[g+120>>2]^ba,c[g+120+4>>2]^ca,32)|0;S=z;F=fg(E|0,F|0,Y|0,S|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;ca=fg(ba|0,ca|0,o|0,m|0)|0;$=fg(ca|0,z|0,G|0,$|0)|0;G=z;S=Ze(Y^$,S^G,16)|0;Y=z;E=fg(F|0,E|0,S|0,Y|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;Z=fg(K|0,V|0,_|0,Z|0)|0;Z=fg(Z|0,z|0,c[y>>2]|0,c[y+4>>2]|0)|0;_=z;Y=Ze(S^Z,Y^_,32)|0;S=z;T=fg(j|0,T|0,Y|0,S|0)|0;j=z;V=Ze(K^T,V^j,24)|0;K=z;_=fg(Z|0,_|0,V|0,K|0)|0;_=fg(_|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;Z=z;S=Ze(Y^_,S^Z,16)|0;Y=z;c[g+120>>2]=S;c[g+120+4>>2]=Y;Y=fg(T|0,j|0,S|0,Y|0)|0;S=z;c[g+80>>2]=Y;c[g+80+4>>2]=S;K=Ze(V^Y,K^S,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;M=fg(B|0,D|0,L|0,M|0)|0;M=fg(M|0,z|0,c[R>>2]|0,c[R+4>>2]|0)|0;L=z;C=Ze(A^M,C^L,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;L=fg(M|0,L|0,D|0,B|0)|0;L=fg(L|0,z|0,c[aa>>2]|0,c[aa+4>>2]|0)|0;M=z;A=Ze(C^L,A^M,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;k=fg(m|0,o|0,W|0,k|0)|0;W=c[r>>2]|0;j=c[r+4>>2]|0;k=fg(k|0,z|0,W|0,j|0)|0;T=z;w=Ze(h^k,w^T,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;T=fg(k|0,T|0,o|0,m|0)|0;T=fg(T|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;k=z;h=Ze(w^T,h^k,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;ca=c[g+32>>2]|0;ba=c[g+32+4>>2]|0;G=fg(ca|0,ba|0,$|0,G|0)|0;G=fg(G|0,z|0,c[P>>2]|0,c[P+4>>2]|0)|0;$=z;s=Ze(n^G,s^$,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;ba=Ze(ca^I,ba^U,24)|0;ca=z;$=fg(G|0,$|0,ba|0,ca|0)|0;G=c[g+128>>2]|0;Q=c[g+128+4>>2]|0;$=fg($|0,z|0,G|0,Q|0)|0;b=z;n=Ze(s^$,n^b,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;ca=Ze(ba^U,ca^I,63)|0;ba=z;Z=fg(_|0,Z|0,ca|0,ba|0)|0;Q=fg(Z|0,z|0,G|0,Q|0)|0;G=z;C=Ze(A^Q,C^G,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;ba=Ze(ca^u,ba^p,24)|0;ca=z;G=fg(Q|0,G|0,ba|0,ca|0)|0;G=fg(G|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;Q=z;A=Ze(C^G,A^Q,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;ca=Ze(ba^p,ca^u,63)|0;c[g+32>>2]=ca;c[g+32+4>>2]=z;M=fg(K|0,V|0,L|0,M|0)|0;M=fg(M|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;L=z;w=Ze(h^M,w^L,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;L=fg(M|0,L|0,V|0,K|0)|0;j=fg(L|0,z|0,W|0,j|0)|0;W=z;h=Ze(w^j,h^W,16)|0;w=z;c[g+104>>2]=h;c[g+104+4>>2]=w;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;K=Ze(V^U,K^I,63)|0;V=z;k=fg(B|0,D|0,T|0,k|0)|0;k=fg(k|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;T=z;s=Ze(n^k,s^T,32)|0;n=z;S=fg(Y|0,S|0,s|0,n|0)|0;Y=z;D=Ze(B^S,D^Y,24)|0;B=z;T=fg(k|0,T|0,D|0,B|0)|0;T=fg(T|0,z|0,c[t>>2]|0,c[t+4>>2]|0)|0;k=z;n=Ze(s^T,n^k,16)|0;s=z;c[g+112>>2]=n;c[g+112+4>>2]=s;Y=fg(S|0,Y|0,n|0,s|0)|0;S=z;B=Ze(D^Y,B^S,63)|0;D=z;b=fg(m|0,o|0,$|0,b|0)|0;b=fg(b|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;$=z;L=Ze(c[g+120>>2]^b,c[g+120+4>>2]^$,32)|0;M=z;F=fg(E|0,F|0,L|0,M|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;$=fg(b|0,$|0,o|0,m|0)|0;$=fg($|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;b=z;M=Ze(L^$,M^b,16)|0;L=z;E=fg(F|0,E|0,M|0,L|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;Q=fg(K|0,V|0,G|0,Q|0)|0;G=c[d>>2]|0;d=c[d+4>>2]|0;Q=fg(Q|0,z|0,G|0,d|0)|0;ca=z;L=Ze(M^Q,L^ca,32)|0;M=z;S=fg(Y|0,S|0,L|0,M|0)|0;Y=z;V=Ze(K^S,V^Y,24)|0;K=z;ca=fg(Q|0,ca|0,V|0,K|0)|0;Q=c[R>>2]|0;R=c[R+4>>2]|0;ca=fg(ca|0,z|0,Q|0,R|0)|0;ba=z;M=Ze(L^ca,M^ba,16)|0;L=z;c[g+120>>2]=M;c[g+120+4>>2]=L;L=fg(S|0,Y|0,M|0,L|0)|0;M=z;c[g+80>>2]=L;c[g+80+4>>2]=M;K=Ze(V^L,K^M,63)|0;V=z;c[g+40>>2]=K;c[g+40+4>>2]=V;W=fg(B|0,D|0,j|0,W|0)|0;j=c[O>>2]|0;O=c[O+4>>2]|0;W=fg(W|0,z|0,j|0,O|0)|0;Y=z;C=Ze(A^W,C^Y,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;Y=fg(W|0,Y|0,D|0,B|0)|0;Y=fg(Y|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;W=z;A=Ze(C^Y,A^W,16)|0;C=z;E=fg(F|0,E|0,A|0,C|0)|0;F=z;c[g+88>>2]=E;c[g+88+4>>2]=F;B=Ze(D^E,B^F,63)|0;D=z;c[g+48>>2]=B;c[g+48+4>>2]=D;k=fg(m|0,o|0,T|0,k|0)|0;k=fg(k|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;T=z;w=Ze(h^k,w^T,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;T=fg(k|0,T|0,o|0,m|0)|0;k=c[P>>2]|0;P=c[P+4>>2]|0;T=fg(T|0,z|0,k|0,P|0)|0;S=z;h=Ze(w^T,h^S,16)|0;w=z;p=fg(u|0,p|0,h|0,w|0)|0;u=z;m=Ze(o^p,m^u,63)|0;o=z;c[g+56>>2]=m;c[g+56+4>>2]=o;Z=c[g+32>>2]|0;_=c[g+32+4>>2]|0;b=fg(Z|0,_|0,$|0,b|0)|0;$=c[aa>>2]|0;aa=c[aa+4>>2]|0;b=fg(b|0,z|0,$|0,aa|0)|0;H=z;s=Ze(n^b,s^H,32)|0;n=z;I=fg(U|0,I|0,s|0,n|0)|0;U=z;_=Ze(Z^I,_^U,24)|0;Z=z;H=fg(b|0,H|0,_|0,Z|0)|0;b=c[y>>2]|0;y=c[y+4>>2]|0;H=fg(H|0,z|0,b|0,y|0)|0;J=z;n=Ze(s^H,n^J,16)|0;s=z;U=fg(I|0,U|0,n|0,s|0)|0;I=z;Z=Ze(_^U,Z^I,63)|0;_=z;ba=fg(ca|0,ba|0,Z|0,_|0)|0;aa=fg(ba|0,z|0,$|0,aa|0)|0;$=z;C=Ze(A^aa,C^$,32)|0;A=z;u=fg(p|0,u|0,C|0,A|0)|0;p=z;_=Ze(Z^u,_^p,24)|0;Z=z;$=fg(aa|0,$|0,_|0,Z|0)|0;O=fg($|0,z|0,j|0,O|0)|0;j=z;A=Ze(C^O,A^j,16)|0;C=z;p=fg(u|0,p|0,A|0,C|0)|0;u=z;c[g+64>>2]=p;c[g+64+4>>2]=u;Z=Ze(_^p,Z^u,63)|0;c[g+32>>2]=Z;c[g+32+4>>2]=z;W=fg(K|0,V|0,Y|0,W|0)|0;X=fg(W|0,z|0,c[X>>2]|0,c[X+4>>2]|0)|0;W=z;w=Ze(h^X,w^W,32)|0;h=z;I=fg(U|0,I|0,w|0,h|0)|0;U=z;V=Ze(K^I,V^U,24)|0;K=z;W=fg(X|0,W|0,V|0,K|0)|0;d=fg(W|0,z|0,G|0,d|0)|0;G=z;h=Ze(w^d,h^G,16)|0;w=z;U=fg(I|0,U|0,h|0,w|0)|0;I=z;c[g+72>>2]=U;c[g+72+4>>2]=I;I=Ze(V^U,K^I,63)|0;K=z;S=fg(B|0,D|0,T|0,S|0)|0;R=fg(S|0,z|0,Q|0,R|0)|0;Q=z;s=Ze(n^R,s^Q,32)|0;n=z;M=fg(L|0,M|0,s|0,n|0)|0;L=z;D=Ze(B^M,D^L,24)|0;B=z;Q=fg(R|0,Q|0,D|0,B|0)|0;y=fg(Q|0,z|0,b|0,y|0)|0;b=z;n=Ze(s^y,n^b,16)|0;s=z;L=fg(M|0,L|0,n|0,s|0)|0;M=z;B=Ze(D^L,B^M,63)|0;D=z;J=fg(m|0,o|0,H|0,J|0)|0;P=fg(J|0,z|0,k|0,P|0)|0;k=z;J=Ze(c[g+120>>2]^P,c[g+120+4>>2]^k,32)|0;H=z;F=fg(E|0,F|0,J|0,H|0)|0;E=z;o=Ze(m^F,o^E,24)|0;m=z;k=fg(P|0,k|0,o|0,m|0)|0;q=fg(k|0,z|0,c[q>>2]|0,c[q+4>>2]|0)|0;k=z;H=Ze(J^q,H^k,16)|0;J=z;E=fg(F|0,E|0,H|0,J|0)|0;F=z;m=Ze(o^E,m^F,63)|0;o=z;j=fg(I|0,K|0,O|0,j|0)|0;N=fg(j|0,z|0,c[N>>2]|0,c[N+4>>2]|0)|0;j=z;J=Ze(H^N,J^j,32)|0;H=z;M=fg(L|0,M|0,J|0,H|0)|0;L=z;K=Ze(I^M,K^L,24)|0;I=z;j=fg(N|0,j|0,K|0,I|0)|0;i=fg(j|0,z|0,c[i>>2]|0,c[i+4>>2]|0)|0;j=z;c[g>>2]=i;c[g+4>>2]=j;H=Ze(J^i,H^j,16)|0;J=z;c[g+120>>2]=H;c[g+120+4>>2]=J;J=fg(M|0,L|0,H|0,J|0)|0;H=z;c[g+80>>2]=J;c[g+80+4>>2]=H;H=Ze(K^J,I^H,63)|0;c[g+40>>2]=H;c[g+40+4>>2]=z;G=fg(B|0,D|0,d|0,G|0)|0;G=fg(G|0,z|0,c[g+128>>2]|0,c[g+128+4>>2]|0)|0;d=z;C=Ze(A^G,C^d,32)|0;A=z;F=fg(E|0,F|0,C|0,A|0)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;d=fg(G|0,d|0,D|0,B|0)|0;e=fg(d|0,z|0,c[e>>2]|0,c[e+4>>2]|0)|0;d=z;c[g+8>>2]=e;c[g+8+4>>2]=d;A=Ze(C^e,A^d,16)|0;C=z;c[g+96>>2]=A;c[g+96+4>>2]=C;C=fg(F|0,E|0,A|0,C|0)|0;A=z;c[g+88>>2]=C;c[g+88+4>>2]=A;A=Ze(D^C,B^A,63)|0;c[g+48>>2]=A;c[g+48+4>>2]=z;b=fg(m|0,o|0,y|0,b|0)|0;x=fg(b|0,z|0,c[x>>2]|0,c[x+4>>2]|0)|0;b=z;w=Ze(h^x,w^b,32)|0;h=z;u=fg(p|0,u|0,w|0,h|0)|0;p=z;o=Ze(m^u,o^p,24)|0;m=z;b=fg(x|0,b|0,o|0,m|0)|0;v=fg(b|0,z|0,c[v>>2]|0,c[v+4>>2]|0)|0;b=z;c[g+16>>2]=v;c[g+16+4>>2]=b;b=Ze(w^v,h^b,16)|0;h=z;c[g+104>>2]=b;c[g+104+4>>2]=h;h=fg(u|0,p|0,b|0,h|0)|0;b=z;c[g+64>>2]=h;c[g+64+4>>2]=b;m=Ze(o^h,m^b,63)|0;c[g+56>>2]=m;c[g+56+4>>2]=z;m=c[g+32>>2]|0;o=c[g+32+4>>2]|0;k=fg(m|0,o|0,q|0,k|0)|0;t=fg(k|0,z|0,c[t>>2]|0,c[t+4>>2]|0)|0;k=z;s=Ze(n^t,s^k,32)|0;n=z;q=fg(c[g+72>>2]|0,c[g+72+4>>2]|0,s|0,n|0)|0;p=z;o=Ze(m^q,o^p,24)|0;m=z;k=fg(t|0,k|0,o|0,m|0)|0;r=fg(k|0,z|0,c[r>>2]|0,c[r+4>>2]|0)|0;k=z;c[g+24>>2]=r;c[g+24+4>>2]=k;k=Ze(s^r,n^k,16)|0;n=z;c[g+112>>2]=k;c[g+112+4>>2]=n;n=fg(q|0,p|0,k|0,n|0)|0;k=z;c[g+72>>2]=n;c[g+72+4>>2]=k;k=Ze(o^n,m^k,63)|0;c[g+32>>2]=k;c[g+32+4>>2]=z;b=j^c[a+4>>2]^b;c[a>>2]=i^c[a>>2]^h;c[a+4>>2]=b;b=1;while(1){ia=a+(b<<3)|0;ha=g+(b+8<<3)|0;d=d^c[ia+4>>2]^c[ha+4>>2];c[ia>>2]=e^c[ia>>2]^c[ha>>2];c[ia+4>>2]=d;d=b+1|0;if((d|0)==8)break;b=d;e=c[g+(d<<3)>>2]|0;d=c[g+(d<<3)+4>>2]|0}l=f;return}function ha(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0,sa=0,ta=0,ua=0,va=0,wa=0,xa=0,ya=0,za=0,Aa=0,Ba=0,Ca=0,Da=0,Ea=0,Fa=0,Ga=0,Ha=0,Ia=0,Ja=0,Ka=0,La=0,Ma=0,Na=0,Oa=0,Pa=0,Qa=0,Ra=0,Sa=0,Ta=0,Ua=0,Va=0,Wa=0,Xa=0,Ya=0,Za=0,_a=0,$a=0,ab=0,bb=0,cb=0,db=0,eb=0,fb=0,gb=0,hb=0,ib=0,jb=0,kb=0,lb=0,mb=0,nb=0,ob=0,pb=0,qb=0,rb=0,sb=0,tb=0,ub=0,vb=0,wb=0,xb=0,yb=0,zb=0,Ab=0,Bb=0,Cb=0,Db=0,Eb=0,Fb=0,Gb=0,Hb=0,Ib=0,Jb=0,Kb=0,Lb=0,Mb=0,Nb=0,Ob=0,Pb=0,Qb=0,Rb=0,Sb=0,Tb=0,Ub=0,Vb=0,Wb=0,Xb=0,Yb=0,Zb=0,_b=0,$b=0,ac=0,bc=0,cc=0,dc=0,ec=0,fc=0,gc=0,hc=0,ic=0,jc=0,kc=0,lc=0,mc=0,nc=0,oc=0,pc=0,qc=0,rc=0,sc=0;Za=df(a[c>>0]|0,a[c+1>>0]|0,a[c+2>>0]|0)|0;nb=Qd(c+2|0)|0;nb=yf(nb|0,z|0,5)|0;A=df(a[c+5>>0]|0,a[c+6>>0]|0,a[c+7>>0]|0)|0;A=yf(A|0,z|0,2)|0;kb=Qd(c+7|0)|0;kb=yf(kb|0,z|0,7)|0;l=Qd(c+10|0)|0;l=yf(l|0,z|0,4)|0;J=df(a[c+13>>0]|0,a[c+14>>0]|0,a[c+15>>0]|0)|0;J=yf(J|0,z|0,1)|0;F=Qd(c+15|0)|0;F=yf(F|0,z|0,6)|0;ea=df(a[c+18>>0]|0,a[c+19>>0]|0,a[c+20>>0]|0)|0;ea=yf(ea|0,z|0,3)|0;ib=df(a[c+21>>0]|0,a[c+22>>0]|0,a[c+23>>0]|0)|0;I=Qd(c+23|0)|0;I=yf(I|0,z|0,5)|0;qc=df(a[c+26>>0]|0,a[c+27>>0]|0,a[c+28>>0]|0)|0;qc=yf(qc|0,z|0,2)|0;n=Qd(c+28|0)|0;n=yf(n|0,z|0,7)|0;ua=z;ub=df(a[d>>0]|0,a[d+1>>0]|0,a[d+2>>0]|0)|0;Ia=Qd(d+2|0)|0;Ia=yf(Ia|0,z|0,5)|0;Wa=df(a[d+5>>0]|0,a[d+6>>0]|0,a[d+7>>0]|0)|0;Wa=yf(Wa|0,z|0,2)|0;ca=Qd(d+7|0)|0;ca=yf(ca|0,z|0,7)|0;P=Qd(d+10|0)|0;P=yf(P|0,z|0,4)|0;ta=df(a[d+13>>0]|0,a[d+14>>0]|0,a[d+15>>0]|0)|0;ta=yf(ta|0,z|0,1)|0;xa=Qd(d+15|0)|0;xa=yf(xa|0,z|0,6)|0;rb=df(a[d+18>>0]|0,a[d+19>>0]|0,a[d+20>>0]|0)|0;rb=yf(rb|0,z|0,3)|0;na=df(a[d+21>>0]|0,a[d+22>>0]|0,a[d+23>>0]|0)|0;O=Qd(d+23|0)|0;O=yf(O|0,z|0,5)|0;Ja=df(a[d+26>>0]|0,a[d+27>>0]|0,a[d+28>>0]|0)|0;Ja=yf(Ja|0,z|0,2)|0;w=Qd(d+28|0)|0;w=yf(w|0,z|0,7)|0;qa=z;V=df(a[e>>0]|0,a[e+1>>0]|0,a[e+2>>0]|0)|0;oa=Qd(e+2|0)|0;oa=yf(oa|0,z|0,5)|0;sa=df(a[e+5>>0]|0,a[e+6>>0]|0,a[e+7>>0]|0)|0;sa=yf(sa|0,z|0,2)|0;Na=Qd(e+7|0)|0;Na=yf(Na|0,z|0,7)|0;ma=Qd(e+10|0)|0;ma=yf(ma|0,z|0,4)|0;Da=df(a[e+13>>0]|0,a[e+14>>0]|0,a[e+15>>0]|0)|0;Da=yf(Da|0,z|0,1)|0;fb=Qd(e+15|0)|0;fb=yf(fb|0,z|0,6)|0;g=df(a[e+18>>0]|0,a[e+19>>0]|0,a[e+20>>0]|0)|0;g=yf(g|0,z|0,3)|0;Ra=df(a[e+21>>0]|0,a[e+22>>0]|0,a[e+23>>0]|0)|0;E=Qd(e+23|0)|0;E=yf(E|0,z|0,5)|0;Qa=df(a[e+26>>0]|0,a[e+27>>0]|0,a[e+28>>0]|0)|0;Qa=yf(Qa|0,z|0,2)|0;c=Qd(e+28|0)|0;c=yf(c|0,z|0,7)|0;h=z;pa=af(ub&2097151|0,0,Za&2097151|0,0)|0;pa=fg(V&2097151|0,0,pa|0,z|0)|0;V=z;pc=af(Ia&2097151|0,0,Za&2097151|0,0)|0;oc=z;nc=af(ub&2097151|0,0,nb&2097151|0,0)|0;t=z;ja=af(Wa&2097151|0,0,Za&2097151|0,0)|0;ra=z;ka=af(Ia&2097151|0,0,nb&2097151|0,0)|0;ic=z;S=af(ub&2097151|0,0,A&2097151|0,0)|0;S=fg(ka|0,ic|0,S|0,z|0)|0;ra=fg(S|0,z|0,ja|0,ra|0)|0;sa=fg(ra|0,z|0,sa&2097151|0,0)|0;ra=z;ja=af(ca&2097151|0,0,Za&2097151|0,0)|0;S=z;ic=af(Wa&2097151|0,0,nb&2097151|0,0)|0;ka=z;mc=af(Ia&2097151|0,0,A&2097151|0,0)|0;lc=z;kc=af(ub&2097151|0,0,kb&2097151|0,0)|0;jc=z;Ca=af(P&2097151|0,0,Za&2097151|0,0)|0;la=z;$b=af(ca&2097151|0,0,nb&2097151|0,0)|0;_=z;bc=af(Wa&2097151|0,0,A&2097151|0,0)|0;Ba=z;cc=af(Ia&2097151|0,0,kb&2097151|0,0)|0;dc=z;ac=af(ub&2097151|0,0,l&2097151|0,0)|0;ac=fg(cc|0,dc|0,ac|0,z|0)|0;Ba=fg(ac|0,z|0,bc|0,Ba|0)|0;_=fg(Ba|0,z|0,$b|0,_|0)|0;la=fg(_|0,z|0,Ca|0,la|0)|0;ma=fg(la|0,z|0,ma&2097151|0,0)|0;la=z;Ca=af(ta&2097151|0,0,Za&2097151|0,0)|0;_=z;$b=af(P&2097151|0,0,nb&2097151|0,0)|0;Ba=z;bc=af(ca&2097151|0,0,A&2097151|0,0)|0;ac=z;dc=af(Wa&2097151|0,0,kb&2097151|0,0)|0;cc=z;hc=af(Ia&2097151|0,0,l&2097151|0,0)|0;gc=z;fc=af(ub&2097151|0,0,J&2097151|0,0)|0;ec=z;Y=af(xa&2097151|0,0,Za&2097151|0,0)|0;$a=z;Ob=af(ta&2097151|0,0,nb&2097151|0,0)|0;B=z;Qb=af(P&2097151|0,0,A&2097151|0,0)|0;X=z;Sb=af(ca&2097151|0,0,kb&2097151|0,0)|0;Pb=z;Ub=af(Wa&2097151|0,0,l&2097151|0,0)|0;Rb=z;Vb=af(Ia&2097151|0,0,J&2097151|0,0)|0;Wb=z;Tb=af(ub&2097151|0,0,F&2097151|0,0)|0;Tb=fg(Vb|0,Wb|0,Tb|0,z|0)|0;Rb=fg(Tb|0,z|0,Ub|0,Rb|0)|0;Pb=fg(Rb|0,z|0,Sb|0,Pb|0)|0;X=fg(Pb|0,z|0,Qb|0,X|0)|0;B=fg(X|0,z|0,Ob|0,B|0)|0;$a=fg(B|0,z|0,Y|0,$a|0)|0;fb=fg($a|0,z|0,fb&2097151|0,0)|0;$a=z;Y=af(rb&2097151|0,0,Za&2097151|0,0)|0;B=z;Ob=af(xa&2097151|0,0,nb&2097151|0,0)|0;X=z;Qb=af(ta&2097151|0,0,A&2097151|0,0)|0;Pb=z;Sb=af(P&2097151|0,0,kb&2097151|0,0)|0;Rb=z;Ub=af(ca&2097151|0,0,l&2097151|0,0)|0;Tb=z;Wb=af(Wa&2097151|0,0,J&2097151|0,0)|0;Vb=z;_b=af(Ia&2097151|0,0,F&2097151|0,0)|0;Zb=z;Yb=af(ub&2097151|0,0,ea&2097151|0,0)|0;Xb=z;zb=af(na&2097151|0,0,Za&2097151|0,0)|0;e=z;i=af(rb&2097151|0,0,nb&2097151|0,0)|0;Sa=z;xb=af(xa&2097151|0,0,A&2097151|0,0)|0;yb=z;Bb=af(ta&2097151|0,0,kb&2097151|0,0)|0;va=z;Db=af(P&2097151|0,0,l&2097151|0,0)|0;Ab=z;Fb=af(ca&2097151|0,0,J&2097151|0,0)|0;Cb=z;Hb=af(Wa&2097151|0,0,F&2097151|0,0)|0;Eb=z;Ib=af(Ia&2097151|0,0,ea&2097151|0,0)|0;Jb=z;Gb=af(ub&2097151|0,0,ib&2097151|0,0)|0;Gb=fg(Ib|0,Jb|0,Gb|0,z|0)|0;Eb=fg(Gb|0,z|0,Hb|0,Eb|0)|0;Cb=fg(Eb|0,z|0,Fb|0,Cb|0)|0;Ab=fg(Cb|0,z|0,Db|0,Ab|0)|0;va=fg(Ab|0,z|0,Bb|0,va|0)|0;yb=fg(va|0,z|0,xb|0,yb|0)|0;e=fg(yb|0,z|0,zb|0,e|0)|0;Sa=fg(e|0,z|0,i|0,Sa|0)|0;Ra=fg(Sa|0,z|0,Ra&2097151|0,0)|0;Sa=z;i=af(O&2097151|0,0,Za&2097151|0,0)|0;e=z;zb=af(na&2097151|0,0,nb&2097151|0,0)|0;yb=z;xb=af(rb&2097151|0,0,A&2097151|0,0)|0;va=z;Bb=af(xa&2097151|0,0,kb&2097151|0,0)|0;Ab=z;Db=af(ta&2097151|0,0,l&2097151|0,0)|0;Cb=z;Fb=af(P&2097151|0,0,J&2097151|0,0)|0;Eb=z;Hb=af(ca&2097151|0,0,F&2097151|0,0)|0;Gb=z;Jb=af(Wa&2097151|0,0,ea&2097151|0,0)|0;Ib=z;Nb=af(Ia&2097151|0,0,ib&2097151|0,0)|0;Mb=z;Lb=af(ub&2097151|0,0,I&2097151|0,0)|0;Kb=z;_a=af(Ja&2097151|0,0,Za&2097151|0,0)|0;Pa=z;ab=af(O&2097151|0,0,nb&2097151|0,0)|0;gb=z;$=af(na&2097151|0,0,A&2097151|0,0)|0;aa=z;U=af(rb&2097151|0,0,kb&2097151|0,0)|0;T=z;mb=af(xa&2097151|0,0,l&2097151|0,0)|0;lb=z;Ma=af(ta&2097151|0,0,J&2097151|0,0)|0;La=z;eb=af(P&2097151|0,0,F&2097151|0,0)|0;db=z;Ga=af(ca&2097151|0,0,ea&2097151|0,0)|0;Fa=z;Ua=af(Wa&2097151|0,0,ib&2097151|0,0)|0;Ta=z;wb=af(Ia&2097151|0,0,I&2097151|0,0)|0;L=z;Q=af(ub&2097151|0,0,qc&2097151|0,0)|0;Q=fg(wb|0,L|0,Q|0,z|0)|0;Ta=fg(Q|0,z|0,Ua|0,Ta|0)|0;Fa=fg(Ta|0,z|0,Ga|0,Fa|0)|0;db=fg(Fa|0,z|0,eb|0,db|0)|0;La=fg(db|0,z|0,Ma|0,La|0)|0;lb=fg(La|0,z|0,mb|0,lb|0)|0;aa=fg(lb|0,z|0,$|0,aa|0)|0;T=fg(aa|0,z|0,U|0,T|0)|0;gb=fg(T|0,z|0,ab|0,gb|0)|0;Pa=fg(gb|0,z|0,_a|0,Pa|0)|0;Qa=fg(Pa|0,z|0,Qa&2097151|0,0)|0;Pa=z;Za=af(w|0,qa|0,Za&2097151|0,0)|0;_a=z;gb=af(Ja&2097151|0,0,nb&2097151|0,0)|0;ab=z;T=af(O&2097151|0,0,A&2097151|0,0)|0;U=z;aa=af(na&2097151|0,0,kb&2097151|0,0)|0;$=z;lb=af(rb&2097151|0,0,l&2097151|0,0)|0;mb=z;La=af(xa&2097151|0,0,J&2097151|0,0)|0;Ma=z;db=af(ta&2097151|0,0,F&2097151|0,0)|0;eb=z;Fa=af(P&2097151|0,0,ea&2097151|0,0)|0;Ga=z;Ta=af(ca&2097151|0,0,ib&2097151|0,0)|0;Ua=z;Q=af(Wa&2097151|0,0,I&2097151|0,0)|0;L=z;wb=af(Ia&2097151|0,0,qc&2097151|0,0)|0;vb=z;ub=af(ub&2097151|0,0,n|0,ua|0)|0;tb=z;nb=af(w|0,qa|0,nb&2097151|0,0)|0;ob=z;bb=af(Ja&2097151|0,0,A&2097151|0,0)|0;v=z;M=af(O&2097151|0,0,kb&2097151|0,0)|0;cb=z;pb=af(na&2097151|0,0,l&2097151|0,0)|0;u=z;p=af(rb&2097151|0,0,J&2097151|0,0)|0;hb=z;q=af(xa&2097151|0,0,F&2097151|0,0)|0;qb=z;ha=af(ta&2097151|0,0,ea&2097151|0,0)|0;y=z;da=af(P&2097151|0,0,ib&2097151|0,0)|0;ia=z;Ha=af(ca&2097151|0,0,I&2097151|0,0)|0;R=z;jb=af(Wa&2097151|0,0,qc&2097151|0,0)|0;Va=z;Ia=af(Ia&2097151|0,0,n|0,ua|0)|0;Ia=fg(jb|0,Va|0,Ia|0,z|0)|0;R=fg(Ia|0,z|0,Ha|0,R|0)|0;ia=fg(R|0,z|0,da|0,ia|0)|0;y=fg(ia|0,z|0,ha|0,y|0)|0;qb=fg(y|0,z|0,q|0,qb|0)|0;u=fg(qb|0,z|0,pb|0,u|0)|0;hb=fg(u|0,z|0,p|0,hb|0)|0;cb=fg(hb|0,z|0,M|0,cb|0)|0;v=fg(cb|0,z|0,bb|0,v|0)|0;ob=fg(v|0,z|0,nb|0,ob|0)|0;nb=z;A=af(w|0,qa|0,A&2097151|0,0)|0;v=z;bb=af(Ja&2097151|0,0,kb&2097151|0,0)|0;cb=z;M=af(O&2097151|0,0,l&2097151|0,0)|0;hb=z;p=af(na&2097151|0,0,J&2097151|0,0)|0;u=z;pb=af(rb&2097151|0,0,F&2097151|0,0)|0;qb=z;q=af(xa&2097151|0,0,ea&2097151|0,0)|0;y=z;ha=af(ta&2097151|0,0,ib&2097151|0,0)|0;ia=z;da=af(P&2097151|0,0,I&2097151|0,0)|0;R=z;Ha=af(ca&2097151|0,0,qc&2097151|0,0)|0;Ia=z;Wa=af(Wa&2097151|0,0,n|0,ua|0)|0;Va=z;kb=af(w|0,qa|0,kb&2097151|0,0)|0;jb=z;Xa=af(Ja&2097151|0,0,l&2097151|0,0)|0;j=z;m=af(O&2097151|0,0,J&2097151|0,0)|0;Ya=z;W=af(na&2097151|0,0,F&2097151|0,0)|0;G=z;Z=af(rb&2097151|0,0,ea&2097151|0,0)|0;f=z;za=af(xa&2097151|0,0,ib&2097151|0,0)|0;r=z;wa=af(ta&2097151|0,0,I&2097151|0,0)|0;k=z;sb=af(P&2097151|0,0,qc&2097151|0,0)|0;o=z;ca=af(ca&2097151|0,0,n|0,ua|0)|0;ca=fg(sb|0,o|0,ca|0,z|0)|0;k=fg(ca|0,z|0,wa|0,k|0)|0;r=fg(k|0,z|0,za|0,r|0)|0;G=fg(r|0,z|0,W|0,G|0)|0;f=fg(G|0,z|0,Z|0,f|0)|0;Ya=fg(f|0,z|0,m|0,Ya|0)|0;j=fg(Ya|0,z|0,Xa|0,j|0)|0;jb=fg(j|0,z|0,kb|0,jb|0)|0;kb=z;l=af(w|0,qa|0,l&2097151|0,0)|0;j=z;Xa=af(Ja&2097151|0,0,J&2097151|0,0)|0;Ya=z;m=af(O&2097151|0,0,F&2097151|0,0)|0;f=z;Z=af(na&2097151|0,0,ea&2097151|0,0)|0;G=z;W=af(rb&2097151|0,0,ib&2097151|0,0)|0;r=z;za=af(xa&2097151|0,0,I&2097151|0,0)|0;k=z;wa=af(ta&2097151|0,0,qc&2097151|0,0)|0;ca=z;P=af(P&2097151|0,0,n|0,ua|0)|0;o=z;J=af(w|0,qa|0,J&2097151|0,0)|0;sb=z;fa=af(Ja&2097151|0,0,F&2097151|0,0)|0;Ka=z;Ea=af(O&2097151|0,0,ea&2097151|0,0)|0;C=z;ba=af(na&2097151|0,0,ib&2097151|0,0)|0;s=z;D=af(rb&2097151|0,0,I&2097151|0,0)|0;Aa=z;K=af(xa&2097151|0,0,qc&2097151|0,0)|0;ya=z;d=af(ta&2097151|0,0,n|0,ua|0)|0;d=fg(K|0,ya|0,d|0,z|0)|0;s=fg(d|0,z|0,ba|0,s|0)|0;Aa=fg(s|0,z|0,D|0,Aa|0)|0;C=fg(Aa|0,z|0,Ea|0,C|0)|0;Ka=fg(C|0,z|0,fa|0,Ka|0)|0;sb=fg(Ka|0,z|0,J|0,sb|0)|0;J=z;F=af(w|0,qa|0,F&2097151|0,0)|0;Ka=z;fa=af(Ja&2097151|0,0,ea&2097151|0,0)|0;C=z;Ea=af(O&2097151|0,0,ib&2097151|0,0)|0;Aa=z;D=af(na&2097151|0,0,I&2097151|0,0)|0;s=z;ba=af(rb&2097151|0,0,qc&2097151|0,0)|0;d=z;xa=af(xa&2097151|0,0,n|0,ua|0)|0;ya=z;ea=af(w|0,qa|0,ea&2097151|0,0)|0;K=z;ta=af(Ja&2097151|0,0,ib&2097151|0,0)|0;N=z;Oa=af(O&2097151|0,0,I&2097151|0,0)|0;H=z;x=af(na&2097151|0,0,qc&2097151|0,0)|0;ga=z;rb=af(rb&2097151|0,0,n|0,ua|0)|0;ga=fg(rb|0,z|0,x|0,ga|0)|0;H=fg(ga|0,z|0,Oa|0,H|0)|0;N=fg(H|0,z|0,ta|0,N|0)|0;K=fg(N|0,z|0,ea|0,K|0)|0;ea=z;ib=af(w|0,qa|0,ib&2097151|0,0)|0;N=z;ta=af(Ja&2097151|0,0,I&2097151|0,0)|0;H=z;Oa=af(O&2097151|0,0,qc&2097151|0,0)|0;ga=z;na=af(na&2097151|0,0,n|0,ua|0)|0;x=z;I=af(w|0,qa|0,I&2097151|0,0)|0;rb=z;sc=af(Ja&2097151|0,0,qc&2097151|0,0)|0;rc=z;O=af(O&2097151|0,0,n|0,ua|0)|0;O=fg(sc|0,rc|0,O|0,z|0)|0;rb=fg(O|0,z|0,I|0,rb|0)|0;I=z;qc=af(w|0,qa|0,qc&2097151|0,0)|0;O=z;Ja=af(Ja&2097151|0,0,n|0,ua|0)|0;Ja=fg(qc|0,O|0,Ja|0,z|0)|0;O=z;ua=af(w|0,qa|0,n|0,ua|0)|0;n=z;qa=fg(pa|0,V|0,1048576,0)|0;qa=yf(qa|0,z|0,21)|0;w=z;t=fg(pc|0,oc|0,nc|0,t|0)|0;oa=fg(t|0,z|0,oa&2097151|0,0)|0;oa=fg(oa|0,z|0,qa|0,w|0)|0;t=z;w=vf(qa|0,w|0,21)|0;w=cg(pa|0,V|0,w|0,z|0)|0;V=z;pa=fg(sa|0,ra|0,1048576,0)|0;pa=yf(pa|0,z|0,21)|0;qa=z;jc=fg(mc|0,lc|0,kc|0,jc|0)|0;ka=fg(jc|0,z|0,ic|0,ka|0)|0;S=fg(ka|0,z|0,ja|0,S|0)|0;Na=fg(S|0,z|0,Na&2097151|0,0)|0;Na=fg(Na|0,z|0,pa|0,qa|0)|0;S=z;qa=vf(pa|0,qa|0,21)|0;pa=z;ja=fg(ma|0,la|0,1048576,0)|0;ja=Xe(ja|0,z|0,21)|0;ka=z;ec=fg(hc|0,gc|0,fc|0,ec|0)|0;cc=fg(ec|0,z|0,dc|0,cc|0)|0;ac=fg(cc|0,z|0,bc|0,ac|0)|0;Ba=fg(ac|0,z|0,$b|0,Ba|0)|0;_=fg(Ba|0,z|0,Ca|0,_|0)|0;Da=fg(_|0,z|0,Da&2097151|0,0)|0;Da=fg(Da|0,z|0,ja|0,ka|0)|0;_=z;ka=vf(ja|0,ka|0,21)|0;ja=z;Ca=fg(fb|0,$a|0,1048576,0)|0;Ca=Xe(Ca|0,z|0,21)|0;Ba=z;Xb=fg(_b|0,Zb|0,Yb|0,Xb|0)|0;Vb=fg(Xb|0,z|0,Wb|0,Vb|0)|0;Tb=fg(Vb|0,z|0,Ub|0,Tb|0)|0;Rb=fg(Tb|0,z|0,Sb|0,Rb|0)|0;Pb=fg(Rb|0,z|0,Qb|0,Pb|0)|0;X=fg(Pb|0,z|0,Ob|0,X|0)|0;B=fg(X|0,z|0,Y|0,B|0)|0;g=fg(B|0,z|0,g&2097151|0,0)|0;g=fg(g|0,z|0,Ca|0,Ba|0)|0;B=z;Ba=vf(Ca|0,Ba|0,21)|0;Ca=z;Y=fg(Ra|0,Sa|0,1048576,0)|0;Y=Xe(Y|0,z|0,21)|0;X=z;Kb=fg(Nb|0,Mb|0,Lb|0,Kb|0)|0;Ib=fg(Kb|0,z|0,Jb|0,Ib|0)|0;Gb=fg(Ib|0,z|0,Hb|0,Gb|0)|0;Eb=fg(Gb|0,z|0,Fb|0,Eb|0)|0;Cb=fg(Eb|0,z|0,Db|0,Cb|0)|0;Ab=fg(Cb|0,z|0,Bb|0,Ab|0)|0;yb=fg(Ab|0,z|0,zb|0,yb|0)|0;va=fg(yb|0,z|0,xb|0,va|0)|0;e=fg(va|0,z|0,i|0,e|0)|0;e=fg(e|0,z|0,E&2097151|0,0)|0;e=fg(e|0,z|0,Y|0,X|0)|0;E=z;X=vf(Y|0,X|0,21)|0;Y=z;i=fg(Qa|0,Pa|0,1048576,0)|0;i=Xe(i|0,z|0,21)|0;va=z;tb=fg(wb|0,vb|0,ub|0,tb|0)|0;L=fg(tb|0,z|0,Q|0,L|0)|0;Ua=fg(L|0,z|0,Ta|0,Ua|0)|0;Ga=fg(Ua|0,z|0,Fa|0,Ga|0)|0;eb=fg(Ga|0,z|0,db|0,eb|0)|0;Ma=fg(eb|0,z|0,La|0,Ma|0)|0;$=fg(Ma|0,z|0,aa|0,$|0)|0;mb=fg($|0,z|0,lb|0,mb|0)|0;U=fg(mb|0,z|0,T|0,U|0)|0;_a=fg(U|0,z|0,Za|0,_a|0)|0;ab=fg(_a|0,z|0,gb|0,ab|0)|0;h=fg(ab|0,z|0,c|0,h|0)|0;h=fg(h|0,z|0,i|0,va|0)|0;c=z;va=vf(i|0,va|0,21)|0;i=z;ab=fg(ob|0,nb|0,1048576,0)|0;ab=Xe(ab|0,z|0,21)|0;gb=z;Va=fg(Ha|0,Ia|0,Wa|0,Va|0)|0;R=fg(Va|0,z|0,da|0,R|0)|0;ia=fg(R|0,z|0,ha|0,ia|0)|0;y=fg(ia|0,z|0,q|0,y|0)|0;u=fg(y|0,z|0,p|0,u|0)|0;qb=fg(u|0,z|0,pb|0,qb|0)|0;hb=fg(qb|0,z|0,M|0,hb|0)|0;cb=fg(hb|0,z|0,bb|0,cb|0)|0;v=fg(cb|0,z|0,A|0,v|0)|0;v=fg(v|0,z|0,ab|0,gb|0)|0;A=z;gb=vf(ab|0,gb|0,21)|0;ab=z;cb=fg(jb|0,kb|0,1048576,0)|0;cb=Xe(cb|0,z|0,21)|0;bb=z;o=fg(wa|0,ca|0,P|0,o|0)|0;k=fg(o|0,z|0,za|0,k|0)|0;G=fg(k|0,z|0,Z|0,G|0)|0;r=fg(G|0,z|0,W|0,r|0)|0;f=fg(r|0,z|0,m|0,f|0)|0;Ya=fg(f|0,z|0,Xa|0,Ya|0)|0;j=fg(Ya|0,z|0,l|0,j|0)|0;j=fg(j|0,z|0,cb|0,bb|0)|0;l=z;bb=vf(cb|0,bb|0,21)|0;cb=z;Ya=fg(sb|0,J|0,1048576,0)|0;Ya=Xe(Ya|0,z|0,21)|0;Xa=z;ya=fg(D|0,s|0,xa|0,ya|0)|0;d=fg(ya|0,z|0,ba|0,d|0)|0;Aa=fg(d|0,z|0,Ea|0,Aa|0)|0;C=fg(Aa|0,z|0,fa|0,C|0)|0;Ka=fg(C|0,z|0,F|0,Ka|0)|0;Ka=fg(Ka|0,z|0,Ya|0,Xa|0)|0;F=z;Xa=vf(Ya|0,Xa|0,21)|0;Ya=z;C=fg(K|0,ea|0,1048576,0)|0;C=Xe(C|0,z|0,21)|0;fa=z;x=fg(Oa|0,ga|0,na|0,x|0)|0;H=fg(x|0,z|0,ta|0,H|0)|0;N=fg(H|0,z|0,ib|0,N|0)|0;N=fg(N|0,z|0,C|0,fa|0)|0;ib=z;fa=vf(C|0,fa|0,21)|0;fa=cg(K|0,ea|0,fa|0,z|0)|0;ea=z;K=fg(rb|0,I|0,1048576,0)|0;K=Xe(K|0,z|0,21)|0;C=z;O=fg(Ja|0,O|0,K|0,C|0)|0;Ja=z;C=vf(K|0,C|0,21)|0;C=cg(rb|0,I|0,C|0,z|0)|0;I=z;rb=fg(ua|0,n|0,1048576,0)|0;rb=Xe(rb|0,z|0,21)|0;K=z;H=vf(rb|0,K|0,21)|0;H=cg(ua|0,n|0,H|0,z|0)|0;n=z;ua=fg(oa|0,t|0,1048576,0)|0;ua=yf(ua|0,z|0,21)|0;ta=z;x=vf(ua|0,ta|0,21)|0;x=cg(oa|0,t|0,x|0,z|0)|0;t=z;oa=fg(Na|0,S|0,1048576,0)|0;oa=Xe(oa|0,z|0,21)|0;na=z;ga=vf(oa|0,na|0,21)|0;ga=cg(Na|0,S|0,ga|0,z|0)|0;S=z;Na=fg(Da|0,_|0,1048576,0)|0;Na=Xe(Na|0,z|0,21)|0;Oa=z;Aa=vf(Na|0,Oa|0,21)|0;Aa=cg(Da|0,_|0,Aa|0,z|0)|0;_=z;Da=fg(g|0,B|0,1048576,0)|0;Da=Xe(Da|0,z|0,21)|0;Ea=z;d=vf(Da|0,Ea|0,21)|0;ba=z;ya=fg(e|0,E|0,1048576,0)|0;ya=Xe(ya|0,z|0,21)|0;xa=z;s=vf(ya|0,xa|0,21)|0;D=z;f=fg(h|0,c|0,1048576,0)|0;f=Xe(f|0,z|0,21)|0;m=z;r=vf(f|0,m|0,21)|0;W=z;G=fg(v|0,A|0,1048576,0)|0;G=Xe(G|0,z|0,21)|0;Z=z;k=vf(G|0,Z|0,21)|0;za=z;o=fg(j|0,l|0,1048576,0)|0;o=Xe(o|0,z|0,21)|0;P=z;ca=vf(o|0,P|0,21)|0;wa=z;hb=fg(Ka|0,F|0,1048576,0)|0;hb=Xe(hb|0,z|0,21)|0;M=z;ea=fg(hb|0,M|0,fa|0,ea|0)|0;fa=z;M=vf(hb|0,M|0,21)|0;M=cg(Ka|0,F|0,M|0,z|0)|0;F=z;Ka=fg(N|0,ib|0,1048576,0)|0;Ka=Xe(Ka|0,z|0,21)|0;hb=z;I=fg(Ka|0,hb|0,C|0,I|0)|0;C=z;hb=vf(Ka|0,hb|0,21)|0;hb=cg(N|0,ib|0,hb|0,z|0)|0;ib=z;N=fg(O|0,Ja|0,1048576,0)|0;N=Xe(N|0,z|0,21)|0;Ka=z;n=fg(N|0,Ka|0,H|0,n|0)|0;H=z;Ka=vf(N|0,Ka|0,21)|0;Ka=cg(O|0,Ja|0,Ka|0,z|0)|0;Ja=z;O=af(rb|0,K|0,666643,0)|0;N=z;qb=af(rb|0,K|0,470296,0)|0;pb=z;u=af(rb|0,K|0,654183,0)|0;p=z;y=af(rb|0,K|0,-997805,-1)|0;q=z;ia=af(rb|0,K|0,136657,0)|0;ha=z;K=af(rb|0,K|0,-683901,-1)|0;K=fg(sb|0,J|0,K|0,z|0)|0;Ya=cg(K|0,z|0,Xa|0,Ya|0)|0;P=fg(Ya|0,z|0,o|0,P|0)|0;o=z;Ya=af(n|0,H|0,666643,0)|0;Xa=z;K=af(n|0,H|0,470296,0)|0;J=z;sb=af(n|0,H|0,654183,0)|0;rb=z;R=af(n|0,H|0,-997805,-1)|0;da=z;Va=af(n|0,H|0,136657,0)|0;Wa=z;H=af(n|0,H|0,-683901,-1)|0;n=z;Ia=af(Ka|0,Ja|0,666643,0)|0;Ha=z;_a=af(Ka|0,Ja|0,470296,0)|0;Za=z;U=af(Ka|0,Ja|0,654183,0)|0;T=z;mb=af(Ka|0,Ja|0,-997805,-1)|0;lb=z;$=af(Ka|0,Ja|0,136657,0)|0;aa=z;Ja=af(Ka|0,Ja|0,-683901,-1)|0;Ka=z;q=fg(jb|0,kb|0,y|0,q|0)|0;Wa=fg(q|0,z|0,Va|0,Wa|0)|0;Ka=fg(Wa|0,z|0,Ja|0,Ka|0)|0;cb=cg(Ka|0,z|0,bb|0,cb|0)|0;Z=fg(cb|0,z|0,G|0,Z|0)|0;G=z;cb=af(I|0,C|0,666643,0)|0;bb=z;Ka=af(I|0,C|0,470296,0)|0;Ja=z;Wa=af(I|0,C|0,654183,0)|0;Va=z;q=af(I|0,C|0,-997805,-1)|0;y=z;kb=af(I|0,C|0,136657,0)|0;jb=z;C=af(I|0,C|0,-683901,-1)|0;I=z;Ma=af(hb|0,ib|0,666643,0)|0;La=z;eb=af(hb|0,ib|0,470296,0)|0;db=z;Ga=af(hb|0,ib|0,654183,0)|0;Fa=z;Ua=af(hb|0,ib|0,-997805,-1)|0;Ta=z;L=af(hb|0,ib|0,136657,0)|0;Q=z;ib=af(hb|0,ib|0,-683901,-1)|0;hb=z;pb=fg(sb|0,rb|0,qb|0,pb|0)|0;nb=fg(pb|0,z|0,ob|0,nb|0)|0;lb=fg(nb|0,z|0,mb|0,lb|0)|0;jb=fg(lb|0,z|0,kb|0,jb|0)|0;hb=fg(jb|0,z|0,ib|0,hb|0)|0;ab=cg(hb|0,z|0,gb|0,ab|0)|0;m=fg(ab|0,z|0,f|0,m|0)|0;f=z;ab=af(ea|0,fa|0,666643,0)|0;ab=fg(fb|0,$a|0,ab|0,z|0)|0;Oa=fg(ab|0,z|0,Na|0,Oa|0)|0;Ca=cg(Oa|0,z|0,Ba|0,Ca|0)|0;Ba=z;Oa=af(ea|0,fa|0,470296,0)|0;Na=z;ab=af(ea|0,fa|0,654183,0)|0;$a=z;bb=fg(eb|0,db|0,cb|0,bb|0)|0;$a=fg(bb|0,z|0,ab|0,$a|0)|0;Sa=fg($a|0,z|0,Ra|0,Sa|0)|0;Ea=fg(Sa|0,z|0,Da|0,Ea|0)|0;Y=cg(Ea|0,z|0,X|0,Y|0)|0;X=z;Ea=af(ea|0,fa|0,-997805,-1)|0;Da=z;Sa=af(ea|0,fa|0,136657,0)|0;Ra=z;Xa=fg(_a|0,Za|0,Ya|0,Xa|0)|0;Va=fg(Xa|0,z|0,Wa|0,Va|0)|0;Ta=fg(Va|0,z|0,Ua|0,Ta|0)|0;Ra=fg(Ta|0,z|0,Sa|0,Ra|0)|0;Pa=fg(Ra|0,z|0,Qa|0,Pa|0)|0;xa=fg(Pa|0,z|0,ya|0,xa|0)|0;i=cg(xa|0,z|0,va|0,i|0)|0;va=z;fa=af(ea|0,fa|0,-683901,-1)|0;ea=z;xa=fg(Ca|0,Ba|0,1048576,0)|0;xa=Xe(xa|0,z|0,21)|0;ya=z;La=fg(Oa|0,Na|0,Ma|0,La|0)|0;B=fg(La|0,z|0,g|0,B|0)|0;ba=cg(B|0,z|0,d|0,ba|0)|0;ba=fg(ba|0,z|0,xa|0,ya|0)|0;d=z;ya=vf(xa|0,ya|0,21)|0;xa=z;B=fg(Y|0,X|0,1048576,0)|0;B=Xe(B|0,z|0,21)|0;g=z;Ha=fg(Ka|0,Ja|0,Ia|0,Ha|0)|0;Fa=fg(Ha|0,z|0,Ga|0,Fa|0)|0;Da=fg(Fa|0,z|0,Ea|0,Da|0)|0;E=fg(Da|0,z|0,e|0,E|0)|0;D=cg(E|0,z|0,s|0,D|0)|0;D=fg(D|0,z|0,B|0,g|0)|0;s=z;g=vf(B|0,g|0,21)|0;B=z;E=fg(i|0,va|0,1048576,0)|0;E=Xe(E|0,z|0,21)|0;e=z;N=fg(K|0,J|0,O|0,N|0)|0;T=fg(N|0,z|0,U|0,T|0)|0;y=fg(T|0,z|0,q|0,y|0)|0;Q=fg(y|0,z|0,L|0,Q|0)|0;ea=fg(Q|0,z|0,fa|0,ea|0)|0;c=fg(ea|0,z|0,h|0,c|0)|0;W=cg(c|0,z|0,r|0,W|0)|0;W=fg(W|0,z|0,E|0,e|0)|0;r=z;e=vf(E|0,e|0,21)|0;E=z;c=fg(m|0,f|0,1048576,0)|0;c=Xe(c|0,z|0,21)|0;h=z;p=fg(R|0,da|0,u|0,p|0)|0;aa=fg(p|0,z|0,$|0,aa|0)|0;I=fg(aa|0,z|0,C|0,I|0)|0;A=fg(I|0,z|0,v|0,A|0)|0;za=cg(A|0,z|0,k|0,za|0)|0;za=fg(za|0,z|0,c|0,h|0)|0;k=z;h=vf(c|0,h|0,21)|0;h=cg(m|0,f|0,h|0,z|0)|0;f=z;m=fg(Z|0,G|0,1048576,0)|0;m=Xe(m|0,z|0,21)|0;c=z;ha=fg(H|0,n|0,ia|0,ha|0)|0;l=fg(ha|0,z|0,j|0,l|0)|0;wa=cg(l|0,z|0,ca|0,wa|0)|0;wa=fg(wa|0,z|0,m|0,c|0)|0;ca=z;c=vf(m|0,c|0,21)|0;c=cg(Z|0,G|0,c|0,z|0)|0;G=z;Z=fg(P|0,o|0,1048576,0)|0;Z=Xe(Z|0,z|0,21)|0;m=z;F=fg(Z|0,m|0,M|0,F|0)|0;M=z;m=vf(Z|0,m|0,21)|0;m=cg(P|0,o|0,m|0,z|0)|0;o=z;P=fg(ba|0,d|0,1048576,0)|0;P=Xe(P|0,z|0,21)|0;Z=z;l=vf(P|0,Z|0,21)|0;j=z;ha=fg(D|0,s|0,1048576,0)|0;ha=Xe(ha|0,z|0,21)|0;ia=z;n=vf(ha|0,ia|0,21)|0;H=z;A=fg(W|0,r|0,1048576,0)|0;A=Xe(A|0,z|0,21)|0;v=z;f=fg(A|0,v|0,h|0,f|0)|0;h=z;v=vf(A|0,v|0,21)|0;v=cg(W|0,r|0,v|0,z|0)|0;r=z;W=fg(za|0,k|0,1048576,0)|0;W=Xe(W|0,z|0,21)|0;A=z;G=fg(W|0,A|0,c|0,G|0)|0;c=z;A=vf(W|0,A|0,21)|0;A=cg(za|0,k|0,A|0,z|0)|0;k=z;za=fg(wa|0,ca|0,1048576,0)|0;za=Xe(za|0,z|0,21)|0;W=z;o=fg(za|0,W|0,m|0,o|0)|0;m=z;W=vf(za|0,W|0,21)|0;W=cg(wa|0,ca|0,W|0,z|0)|0;ca=z;wa=af(F|0,M|0,666643,0)|0;wa=fg(Aa|0,_|0,wa|0,z|0)|0;_=z;Aa=af(F|0,M|0,470296,0)|0;za=z;I=af(F|0,M|0,654183,0)|0;C=z;aa=af(F|0,M|0,-997805,-1)|0;$=z;p=af(F|0,M|0,136657,0)|0;u=z;M=af(F|0,M|0,-683901,-1)|0;M=fg(i|0,va|0,M|0,z|0)|0;ia=fg(M|0,z|0,ha|0,ia|0)|0;E=cg(ia|0,z|0,e|0,E|0)|0;e=z;ia=af(o|0,m|0,666643,0)|0;ha=z;M=af(o|0,m|0,470296,0)|0;M=fg(wa|0,_|0,M|0,z|0)|0;_=z;wa=af(o|0,m|0,654183,0)|0;va=z;i=af(o|0,m|0,-997805,-1)|0;F=z;da=af(o|0,m|0,136657,0)|0;R=z;m=af(o|0,m|0,-683901,-1)|0;o=z;ea=af(W|0,ca|0,666643,0)|0;ea=fg(ga|0,S|0,ea|0,z|0)|0;S=z;ga=af(W|0,ca|0,470296,0)|0;fa=z;Q=af(W|0,ca|0,654183,0)|0;Q=fg(M|0,_|0,Q|0,z|0)|0;_=z;M=af(W|0,ca|0,-997805,-1)|0;L=z;y=af(W|0,ca|0,136657,0)|0;q=z;ca=af(W|0,ca|0,-683901,-1)|0;W=z;$=fg(Y|0,X|0,aa|0,$|0)|0;Z=fg($|0,z|0,P|0,Z|0)|0;R=fg(Z|0,z|0,da|0,R|0)|0;W=fg(R|0,z|0,ca|0,W|0)|0;B=cg(W|0,z|0,g|0,B|0)|0;g=z;W=af(G|0,c|0,666643,0)|0;ca=z;R=af(G|0,c|0,470296,0)|0;R=fg(ea|0,S|0,R|0,z|0)|0;S=z;ea=af(G|0,c|0,654183,0)|0;da=z;Z=af(G|0,c|0,-997805,-1)|0;Z=fg(Q|0,_|0,Z|0,z|0)|0;_=z;Q=af(G|0,c|0,136657,0)|0;P=z;c=af(G|0,c|0,-683901,-1)|0;G=z;$=af(A|0,k|0,666643,0)|0;aa=z;X=af(A|0,k|0,470296,0)|0;Y=z;T=af(A|0,k|0,654183,0)|0;U=z;N=af(A|0,k|0,-997805,-1)|0;O=z;J=af(A|0,k|0,136657,0)|0;K=z;k=af(A|0,k|0,-683901,-1)|0;A=z;za=fg(Ca|0,Ba|0,Aa|0,za|0)|0;xa=cg(za|0,z|0,ya|0,xa|0)|0;va=fg(xa|0,z|0,wa|0,va|0)|0;L=fg(va|0,z|0,M|0,L|0)|0;P=fg(L|0,z|0,Q|0,P|0)|0;A=fg(P|0,z|0,k|0,A|0)|0;k=z;P=af(f|0,h|0,666643,0)|0;V=fg(P|0,z|0,w|0,V|0)|0;w=z;P=af(f|0,h|0,470296,0)|0;Q=z;L=af(f|0,h|0,654183,0)|0;M=z;ra=fg(ua|0,ta|0,sa|0,ra|0)|0;pa=cg(ra|0,z|0,qa|0,pa|0)|0;ca=fg(pa|0,z|0,W|0,ca|0)|0;M=fg(ca|0,z|0,L|0,M|0)|0;Y=fg(M|0,z|0,X|0,Y|0)|0;X=z;M=af(f|0,h|0,-997805,-1)|0;L=z;ca=af(f|0,h|0,136657,0)|0;W=z;la=fg(oa|0,na|0,ma|0,la|0)|0;ja=cg(la|0,z|0,ka|0,ja|0)|0;ha=fg(ja|0,z|0,ia|0,ha|0)|0;fa=fg(ha|0,z|0,ga|0,fa|0)|0;da=fg(fa|0,z|0,ea|0,da|0)|0;W=fg(da|0,z|0,ca|0,W|0)|0;O=fg(W|0,z|0,N|0,O|0)|0;N=z;h=af(f|0,h|0,-683901,-1)|0;f=z;W=fg(V|0,w|0,1048576,0)|0;W=Xe(W|0,z|0,21)|0;ca=z;Q=fg(x|0,t|0,P|0,Q|0)|0;aa=fg(Q|0,z|0,$|0,aa|0)|0;aa=fg(aa|0,z|0,W|0,ca|0)|0;$=z;ca=vf(W|0,ca|0,21)|0;ca=cg(V|0,w|0,ca|0,z|0)|0;w=z;V=fg(Y|0,X|0,1048576,0)|0;V=Xe(V|0,z|0,21)|0;W=z;L=fg(R|0,S|0,M|0,L|0)|0;U=fg(L|0,z|0,T|0,U|0)|0;U=fg(U|0,z|0,V|0,W|0)|0;T=z;W=vf(V|0,W|0,21)|0;V=z;L=fg(O|0,N|0,1048576,0)|0;L=Xe(L|0,z|0,21)|0;M=z;f=fg(Z|0,_|0,h|0,f|0)|0;K=fg(f|0,z|0,J|0,K|0)|0;K=fg(K|0,z|0,L|0,M|0)|0;J=z;M=vf(L|0,M|0,21)|0;L=z;f=fg(A|0,k|0,1048576,0)|0;f=Xe(f|0,z|0,21)|0;h=z;C=fg(ba|0,d|0,I|0,C|0)|0;F=fg(C|0,z|0,i|0,F|0)|0;j=cg(F|0,z|0,l|0,j|0)|0;q=fg(j|0,z|0,y|0,q|0)|0;G=fg(q|0,z|0,c|0,G|0)|0;G=fg(G|0,z|0,f|0,h|0)|0;c=z;h=vf(f|0,h|0,21)|0;h=cg(A|0,k|0,h|0,z|0)|0;k=z;A=fg(B|0,g|0,1048576,0)|0;A=Xe(A|0,z|0,21)|0;f=z;u=fg(m|0,o|0,p|0,u|0)|0;s=fg(u|0,z|0,D|0,s|0)|0;H=cg(s|0,z|0,n|0,H|0)|0;H=fg(H|0,z|0,A|0,f|0)|0;n=z;f=vf(A|0,f|0,21)|0;f=cg(B|0,g|0,f|0,z|0)|0;g=z;B=fg(E|0,e|0,1048576,0)|0;B=Xe(B|0,z|0,21)|0;A=z;r=fg(v|0,r|0,B|0,A|0)|0;v=z;A=vf(B|0,A|0,21)|0;B=z;s=fg(aa|0,$|0,1048576,0)|0;s=Xe(s|0,z|0,21)|0;D=z;u=vf(s|0,D|0,21)|0;p=z;o=fg(U|0,T|0,1048576,0)|0;o=Xe(o|0,z|0,21)|0;m=z;q=vf(o|0,m|0,21)|0;y=z;j=fg(K|0,J|0,1048576,0)|0;j=Xe(j|0,z|0,21)|0;l=z;k=fg(h|0,k|0,j|0,l|0)|0;h=z;l=vf(j|0,l|0,21)|0;j=z;F=fg(G|0,c|0,1048576,0)|0;F=Xe(F|0,z|0,21)|0;i=z;g=fg(f|0,g|0,F|0,i|0)|0;f=z;i=vf(F|0,i|0,21)|0;i=cg(G|0,c|0,i|0,z|0)|0;c=z;G=fg(H|0,n|0,1048576,0)|0;G=Xe(G|0,z|0,21)|0;F=z;C=vf(G|0,F|0,21)|0;C=cg(H|0,n|0,C|0,z|0)|0;n=z;H=fg(r|0,v|0,1048576,0)|0;H=Xe(H|0,z|0,21)|0;I=z;d=vf(H|0,I|0,21)|0;d=cg(r|0,v|0,d|0,z|0)|0;v=z;r=af(H|0,I|0,666643,0)|0;r=fg(ca|0,w|0,r|0,z|0)|0;w=z;ca=af(H|0,I|0,470296,0)|0;ba=z;_=af(H|0,I|0,654183,0)|0;Z=z;S=af(H|0,I|0,-997805,-1)|0;R=z;Q=af(H|0,I|0,136657,0)|0;P=z;I=af(H|0,I|0,-683901,-1)|0;H=z;t=Xe(r|0,w|0,21)|0;x=z;$=fg(ca|0,ba|0,aa|0,$|0)|0;p=cg($|0,z|0,u|0,p|0)|0;p=fg(p|0,z|0,t|0,x|0)|0;u=z;x=vf(t|0,x|0,21)|0;x=cg(r|0,w|0,x|0,z|0)|0;w=z;r=Xe(p|0,u|0,21)|0;t=z;X=fg(_|0,Z|0,Y|0,X|0)|0;V=cg(X|0,z|0,W|0,V|0)|0;D=fg(V|0,z|0,s|0,D|0)|0;D=fg(D|0,z|0,r|0,t|0)|0;s=z;t=vf(r|0,t|0,21)|0;t=cg(p|0,u|0,t|0,z|0)|0;u=z;p=Xe(D|0,s|0,21)|0;r=z;R=fg(U|0,T|0,S|0,R|0)|0;y=cg(R|0,z|0,q|0,y|0)|0;y=fg(y|0,z|0,p|0,r|0)|0;q=z;r=vf(p|0,r|0,21)|0;r=cg(D|0,s|0,r|0,z|0)|0;s=z;D=Xe(y|0,q|0,21)|0;p=z;N=fg(Q|0,P|0,O|0,N|0)|0;L=cg(N|0,z|0,M|0,L|0)|0;m=fg(L|0,z|0,o|0,m|0)|0;m=fg(m|0,z|0,D|0,p|0)|0;o=z;p=vf(D|0,p|0,21)|0;p=cg(y|0,q|0,p|0,z|0)|0;q=z;y=Xe(m|0,o|0,21)|0;D=z;H=fg(K|0,J|0,I|0,H|0)|0;j=cg(H|0,z|0,l|0,j|0)|0;j=fg(j|0,z|0,y|0,D|0)|0;l=z;D=vf(y|0,D|0,21)|0;D=cg(m|0,o|0,D|0,z|0)|0;o=z;m=Xe(j|0,l|0,21)|0;y=z;h=fg(k|0,h|0,m|0,y|0)|0;k=z;y=vf(m|0,y|0,21)|0;y=cg(j|0,l|0,y|0,z|0)|0;l=z;j=Xe(h|0,k|0,21)|0;m=z;c=fg(j|0,m|0,i|0,c|0)|0;i=z;m=vf(j|0,m|0,21)|0;m=cg(h|0,k|0,m|0,z|0)|0;k=z;h=Xe(c|0,i|0,21)|0;j=z;f=fg(g|0,f|0,h|0,j|0)|0;g=z;j=vf(h|0,j|0,21)|0;j=cg(c|0,i|0,j|0,z|0)|0;i=z;c=Xe(f|0,g|0,21)|0;h=z;n=fg(c|0,h|0,C|0,n|0)|0;C=z;h=vf(c|0,h|0,21)|0;h=cg(f|0,g|0,h|0,z|0)|0;g=z;f=Xe(n|0,C|0,21)|0;c=z;e=fg(G|0,F|0,E|0,e|0)|0;B=cg(e|0,z|0,A|0,B|0)|0;B=fg(B|0,z|0,f|0,c|0)|0;A=z;c=vf(f|0,c|0,21)|0;c=cg(n|0,C|0,c|0,z|0)|0;C=z;n=Xe(B|0,A|0,21)|0;f=z;v=fg(n|0,f|0,d|0,v|0)|0;d=z;f=vf(n|0,f|0,21)|0;f=cg(B|0,A|0,f|0,z|0)|0;A=z;B=Xe(v|0,d|0,21)|0;n=z;e=vf(B|0,n|0,21)|0;e=cg(v|0,d|0,e|0,z|0)|0;d=z;v=af(B|0,n|0,666643,0)|0;w=fg(v|0,z|0,x|0,w|0)|0;x=z;v=af(B|0,n|0,470296,0)|0;v=fg(t|0,u|0,v|0,z|0)|0;u=z;t=af(B|0,n|0,654183,0)|0;t=fg(r|0,s|0,t|0,z|0)|0;s=z;r=af(B|0,n|0,-997805,-1)|0;r=fg(p|0,q|0,r|0,z|0)|0;q=z;p=af(B|0,n|0,136657,0)|0;p=fg(D|0,o|0,p|0,z|0)|0;o=z;n=af(B|0,n|0,-683901,-1)|0;n=fg(y|0,l|0,n|0,z|0)|0;l=z;y=Xe(w|0,x|0,21)|0;B=z;u=fg(v|0,u|0,y|0,B|0)|0;v=z;B=vf(y|0,B|0,21)|0;B=cg(w|0,x|0,B|0,z|0)|0;x=z;w=Xe(u|0,v|0,21)|0;y=z;s=fg(t|0,s|0,w|0,y|0)|0;t=z;y=vf(w|0,y|0,21)|0;y=cg(u|0,v|0,y|0,z|0)|0;v=z;u=Xe(s|0,t|0,21)|0;w=z;q=fg(r|0,q|0,u|0,w|0)|0;r=z;w=vf(u|0,w|0,21)|0;w=cg(s|0,t|0,w|0,z|0)|0;t=z;s=Xe(q|0,r|0,21)|0;u=z;o=fg(p|0,o|0,s|0,u|0)|0;p=z;u=vf(s|0,u|0,21)|0;u=cg(q|0,r|0,u|0,z|0)|0;r=z;q=Xe(o|0,p|0,21)|0;s=z;l=fg(n|0,l|0,q|0,s|0)|0;n=z;s=vf(q|0,s|0,21)|0;s=cg(o|0,p|0,s|0,z|0)|0;p=z;o=Xe(l|0,n|0,21)|0;q=z;k=fg(o|0,q|0,m|0,k|0)|0;m=z;q=vf(o|0,q|0,21)|0;q=cg(l|0,n|0,q|0,z|0)|0;n=z;l=Xe(k|0,m|0,21)|0;o=z;i=fg(l|0,o|0,j|0,i|0)|0;j=z;o=vf(l|0,o|0,21)|0;o=cg(k|0,m|0,o|0,z|0)|0;m=z;k=Xe(i|0,j|0,21)|0;l=z;g=fg(k|0,l|0,h|0,g|0)|0;h=z;l=vf(k|0,l|0,21)|0;l=cg(i|0,j|0,l|0,z|0)|0;j=z;i=Xe(g|0,h|0,21)|0;k=z;C=fg(i|0,k|0,c|0,C|0)|0;c=z;k=vf(i|0,k|0,21)|0;k=cg(g|0,h|0,k|0,z|0)|0;h=z;g=Xe(C|0,c|0,21)|0;i=z;A=fg(g|0,i|0,f|0,A|0)|0;f=z;i=vf(g|0,i|0,21)|0;i=cg(C|0,c|0,i|0,z|0)|0;c=z;C=Xe(A|0,f|0,21)|0;g=z;d=fg(C|0,g|0,e|0,d|0)|0;e=z;g=vf(C|0,g|0,21)|0;g=cg(A|0,f|0,g|0,z|0)|0;f=z;a[b>>0]=B;A=yf(B|0,x|0,8)|0;a[b+1>>0]=A;x=yf(B|0,x|0,16)|0;B=z;A=vf(y|0,v|0,5)|0;a[b+2>>0]=A|x;x=yf(y|0,v|0,3)|0;a[b+3>>0]=x;x=yf(y|0,v|0,11)|0;a[b+4>>0]=x;v=yf(y|0,v|0,19)|0;y=z;x=vf(w|0,t|0,2)|0;a[b+5>>0]=x|v;v=yf(w|0,t|0,6)|0;a[b+6>>0]=v;t=yf(w|0,t|0,14)|0;w=z;v=vf(u|0,r|0,7)|0;a[b+7>>0]=v|t;t=yf(u|0,r|0,1)|0;a[b+8>>0]=t;t=yf(u|0,r|0,9)|0;a[b+9>>0]=t;r=yf(u|0,r|0,17)|0;u=z;t=vf(s|0,p|0,4)|0;a[b+10>>0]=t|r;r=yf(s|0,p|0,4)|0;a[b+11>>0]=r;r=yf(s|0,p|0,12)|0;a[b+12>>0]=r;p=yf(s|0,p|0,20)|0;s=z;r=vf(q|0,n|0,1)|0;a[b+13>>0]=r|p;p=yf(q|0,n|0,7)|0;a[b+14>>0]=p;n=yf(q|0,n|0,15)|0;q=z;p=vf(o|0,m|0,6)|0;a[b+15>>0]=p|n;n=yf(o|0,m|0,2)|0;a[b+16>>0]=n;n=yf(o|0,m|0,10)|0;a[b+17>>0]=n;m=yf(o|0,m|0,18)|0;o=z;n=vf(l|0,j|0,3)|0;a[b+18>>0]=n|m;m=yf(l|0,j|0,5)|0;a[b+19>>0]=m;j=yf(l|0,j|0,13)|0;a[b+20>>0]=j;a[b+21>>0]=k;j=yf(k|0,h|0,8)|0;a[b+22>>0]=j;h=yf(k|0,h|0,16)|0;k=z;j=vf(i|0,c|0,5)|0;a[b+23>>0]=j|h;h=yf(i|0,c|0,3)|0;a[b+24>>0]=h;h=yf(i|0,c|0,11)|0;a[b+25>>0]=h;c=yf(i|0,c|0,19)|0;i=z;h=vf(g|0,f|0,2)|0;a[b+26>>0]=h|c;c=yf(g|0,f|0,6)|0;a[b+27>>0]=c;f=yf(g|0,f|0,14)|0;g=z;c=vf(d|0,e|0,7)|0;a[b+28>>0]=f|c;c=yf(d|0,e|0,1)|0;a[b+29>>0]=c;c=yf(d|0,e|0,9)|0;a[b+30>>0]=c;e=yf(d|0,e|0,17)|0;a[b+31>>0]=e;return}function ia(a){a=a|0;var b=0,d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0;I=l;n=l=l+63&-64;l=l+16|0;do if(a>>>0<245){s=a>>>0<11?16:a+11&-8;r=c[8850]|0;if(r>>>(s>>>3)&3|0){a=35440+((r>>>(s>>>3)&1^1)+(s>>>3)<<1<<2)|0;b=c[a+8>>2]|0;d=c[b+8>>2]|0;do if((a|0)!=(d|0)){if(d>>>0<(c[8854]|0)>>>0)Z();if((c[d+12>>2]|0)==(b|0)){c[d+12>>2]=a;c[a+8>>2]=d;break}else Z()}else c[8850]=r&~(1<<(r>>>(s>>>3)&1^1)+(s>>>3));while(0);H=(r>>>(s>>>3)&1^1)+(s>>>3)<<3;c[b+4>>2]=H|3;c[b+H+4>>2]=c[b+H+4>>2]|1;H=b+8|0;l=I;return H|0}q=c[8852]|0;if(s>>>0>q>>>0){if(r>>>(s>>>3)|0){a=r>>>(s>>>3)<<(s>>>3)&(2<<(s>>>3)|0-(2<<(s>>>3)));e=((a&0-a)+-1|0)>>>(((a&0-a)+-1|0)>>>12&16);d=e>>>(e>>>5&8)>>>(e>>>(e>>>5&8)>>>2&4);d=(e>>>5&8|((a&0-a)+-1|0)>>>12&16|e>>>(e>>>5&8)>>>2&4|d>>>1&2|d>>>(d>>>1&2)>>>1&1)+(d>>>(d>>>1&2)>>>(d>>>(d>>>1&2)>>>1&1))|0;e=c[35440+(d<<1<<2)+8>>2]|0;a=c[e+8>>2]|0;do if((35440+(d<<1<<2)|0)!=(a|0)){if(a>>>0<(c[8854]|0)>>>0)Z();if((c[a+12>>2]|0)==(e|0)){c[a+12>>2]=35440+(d<<1<<2);c[35440+(d<<1<<2)+8>>2]=a;f=r;break}else Z()}else{c[8850]=r&~(1<<d);f=r&~(1<<d)}while(0);c[e+4>>2]=s|3;c[e+s+4>>2]=(d<<3)-s|1;c[e+s+((d<<3)-s)>>2]=(d<<3)-s;if(q|0){b=c[8855]|0;if(f&1<<(q>>>3)){a=c[35440+(q>>>3<<1<<2)+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{h=a;i=35440+(q>>>3<<1<<2)+8|0}}else{c[8850]=f|1<<(q>>>3);h=35440+(q>>>3<<1<<2)|0;i=35440+(q>>>3<<1<<2)+8|0}c[i>>2]=b;c[h+12>>2]=b;c[b+8>>2]=h;c[b+12>>2]=35440+(q>>>3<<1<<2)}c[8852]=(d<<3)-s;c[8855]=e+s;H=e+8|0;l=I;return H|0}k=c[8851]|0;if(k){b=((k&0-k)+-1|0)>>>(((k&0-k)+-1|0)>>>12&16);a=b>>>(b>>>5&8)>>>(b>>>(b>>>5&8)>>>2&4);a=c[35704+((b>>>5&8|((k&0-k)+-1|0)>>>12&16|b>>>(b>>>5&8)>>>2&4|a>>>1&2|a>>>(a>>>1&2)>>>1&1)+(a>>>(a>>>1&2)>>>(a>>>(a>>>1&2)>>>1&1))<<2)>>2]|0;b=(c[a+4>>2]&-8)-s|0;d=c[a+16+(((c[a+16>>2]|0)==0&1)<<2)>>2]|0;if(!d){j=a;h=b}else{do{G=(c[d+4>>2]&-8)-s|0;H=G>>>0<b>>>0;b=H?G:b;a=H?d:a;d=c[d+16+(((c[d+16>>2]|0)==0&1)<<2)>>2]|0}while((d|0)!=0);j=a;h=b}f=c[8854]|0;if(j>>>0<f>>>0)Z();i=j+s|0;if(j>>>0>=i>>>0)Z();g=c[j+24>>2]|0;a=c[j+12>>2]|0;do if((a|0)==(j|0)){b=j+20|0;a=c[b>>2]|0;if(!a){b=j+16|0;a=c[b>>2]|0;if(!a){m=0;break}}while(1){d=a+20|0;e=c[d>>2]|0;if(e|0){a=e;b=d;continue}d=a+16|0;e=c[d>>2]|0;if(!e)break;else{a=e;b=d}}if(b>>>0<f>>>0)Z();else{c[b>>2]=0;m=a;break}}else{b=c[j+8>>2]|0;if(b>>>0<f>>>0)Z();if((c[b+12>>2]|0)!=(j|0))Z();if((c[a+8>>2]|0)==(j|0)){c[b+12>>2]=a;c[a+8>>2]=b;m=a;break}else Z()}while(0);a:do if(g|0){a=c[j+28>>2]|0;do if((j|0)==(c[35704+(a<<2)>>2]|0)){c[35704+(a<<2)>>2]=m;if(!m){c[8851]=k&~(1<<a);break a}}else if(g>>>0>=(c[8854]|0)>>>0){c[g+16+(((c[g+16>>2]|0)!=(j|0)&1)<<2)>>2]=m;if(!m)break a;else break}else Z();while(0);b=c[8854]|0;if(m>>>0<b>>>0)Z();c[m+24>>2]=g;a=c[j+16>>2]|0;do if(a|0)if(a>>>0<b>>>0)Z();else{c[m+16>>2]=a;c[a+24>>2]=m;break}while(0);a=c[j+20>>2]|0;if(a|0)if(a>>>0<(c[8854]|0)>>>0)Z();else{c[m+20>>2]=a;c[a+24>>2]=m;break}}while(0);if(h>>>0<16){H=h+s|0;c[j+4>>2]=H|3;H=j+H+4|0;c[H>>2]=c[H>>2]|1}else{c[j+4>>2]=s|3;c[i+4>>2]=h|1;c[i+h>>2]=h;if(q|0){b=c[8855]|0;if(r&1<<(q>>>3)){a=c[35440+(q>>>3<<1<<2)+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{o=a;p=35440+(q>>>3<<1<<2)+8|0}}else{c[8850]=r|1<<(q>>>3);o=35440+(q>>>3<<1<<2)|0;p=35440+(q>>>3<<1<<2)+8|0}c[p>>2]=b;c[o+12>>2]=b;c[b+8>>2]=o;c[b+12>>2]=35440+(q>>>3<<1<<2)}c[8852]=h;c[8855]=i}H=j+8|0;l=I;return H|0}}}else if(a>>>0<=4294967231){s=a+11&-8;k=c[8851]|0;if(k){if((a+11|0)>>>8)if(s>>>0>16777215)i=31;else{i=(a+11|0)>>>8<<((((a+11|0)>>>8)+1048320|0)>>>16&8);i=14-((i+520192|0)>>>16&4|(((a+11|0)>>>8)+1048320|0)>>>16&8|((i<<((i+520192|0)>>>16&4))+245760|0)>>>16&2)+(i<<((i+520192|0)>>>16&4)<<(((i<<((i+520192|0)>>>16&4))+245760|0)>>>16&2)>>>15)|0;i=s>>>(i+7|0)&1|i<<1}else i=0;b=c[35704+(i<<2)>>2]|0;b:do if(!b){b=0;a=0;d=0-s|0;A=81}else{a=0;d=0-s|0;h=s<<((i|0)==31?0:25-(i>>>1)|0);f=0;while(1){e=(c[b+4>>2]&-8)-s|0;if(e>>>0<d>>>0)if(!e){a=b;d=0;e=b;A=85;break b}else{a=b;d=e}e=c[b+20>>2]|0;b=c[b+16+(h>>>31<<2)>>2]|0;f=(e|0)==0|(e|0)==(b|0)?f:e;e=(b|0)==0;if(e){b=f;A=81;break}else h=h<<((e^1)&1)}}while(0);if((A|0)==81){if((b|0)==0&(a|0)==0){a=2<<i;if(!(k&(a|0-a)))break;o=(k&(a|0-a)&0-(k&(a|0-a)))+-1|0;p=o>>>(o>>>12&16)>>>(o>>>(o>>>12&16)>>>5&8);b=p>>>(p>>>2&4)>>>(p>>>(p>>>2&4)>>>1&2);a=0;b=c[35704+((o>>>(o>>>12&16)>>>5&8|o>>>12&16|p>>>2&4|p>>>(p>>>2&4)>>>1&2|b>>>1&1)+(b>>>(b>>>1&1))<<2)>>2]|0}if(!b){j=a;i=d}else{e=b;A=85}}if((A|0)==85)while(1){A=0;b=(c[e+4>>2]&-8)-s|0;p=b>>>0<d>>>0;b=p?b:d;a=p?e:a;e=c[e+16+(((c[e+16>>2]|0)==0&1)<<2)>>2]|0;if(!e){j=a;i=b;break}else{d=b;A=85}}if((j|0)!=0?i>>>0<((c[8852]|0)-s|0)>>>0:0){f=c[8854]|0;if(j>>>0<f>>>0)Z();h=j+s|0;if(j>>>0>=h>>>0)Z();g=c[j+24>>2]|0;a=c[j+12>>2]|0;do if((a|0)==(j|0)){b=j+20|0;a=c[b>>2]|0;if(!a){b=j+16|0;a=c[b>>2]|0;if(!a){q=0;break}}while(1){d=a+20|0;e=c[d>>2]|0;if(e|0){a=e;b=d;continue}d=a+16|0;e=c[d>>2]|0;if(!e)break;else{a=e;b=d}}if(b>>>0<f>>>0)Z();else{c[b>>2]=0;q=a;break}}else{b=c[j+8>>2]|0;if(b>>>0<f>>>0)Z();if((c[b+12>>2]|0)!=(j|0))Z();if((c[a+8>>2]|0)==(j|0)){c[b+12>>2]=a;c[a+8>>2]=b;q=a;break}else Z()}while(0);c:do if(g){a=c[j+28>>2]|0;do if((j|0)==(c[35704+(a<<2)>>2]|0)){c[35704+(a<<2)>>2]=q;if(!q){c[8851]=k&~(1<<a);x=k&~(1<<a);break c}}else if(g>>>0>=(c[8854]|0)>>>0){c[g+16+(((c[g+16>>2]|0)!=(j|0)&1)<<2)>>2]=q;if(!q){x=k;break c}else break}else Z();while(0);b=c[8854]|0;if(q>>>0<b>>>0)Z();c[q+24>>2]=g;a=c[j+16>>2]|0;do if(a|0)if(a>>>0<b>>>0)Z();else{c[q+16>>2]=a;c[a+24>>2]=q;break}while(0);a=c[j+20>>2]|0;if(a)if(a>>>0<(c[8854]|0)>>>0)Z();else{c[q+20>>2]=a;c[a+24>>2]=q;x=k;break}else x=k}else x=k;while(0);do if(i>>>0>=16){c[j+4>>2]=s|3;c[h+4>>2]=i|1;c[h+i>>2]=i;b=i>>>3;if(i>>>0<256){a=c[8850]|0;if(a&1<<b){a=c[35440+(b<<1<<2)+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{r=a;w=35440+(b<<1<<2)+8|0}}else{c[8850]=a|1<<b;r=35440+(b<<1<<2)|0;w=35440+(b<<1<<2)+8|0}c[w>>2]=h;c[r+12>>2]=h;c[h+8>>2]=r;c[h+12>>2]=35440+(b<<1<<2);break}a=i>>>8;if(a)if(i>>>0>16777215)a=31;else{H=a<<((a+1048320|0)>>>16&8)<<(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4);a=14-(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4|(a+1048320|0)>>>16&8|(H+245760|0)>>>16&2)+(H<<((H+245760|0)>>>16&2)>>>15)|0;a=i>>>(a+7|0)&1|a<<1}else a=0;d=35704+(a<<2)|0;c[h+28>>2]=a;c[h+16+4>>2]=0;c[h+16>>2]=0;b=1<<a;if(!(x&b)){c[8851]=x|b;c[d>>2]=h;c[h+24>>2]=d;c[h+12>>2]=h;c[h+8>>2]=h;break}b=i<<((a|0)==31?0:25-(a>>>1)|0);e=c[d>>2]|0;while(1){if((c[e+4>>2]&-8|0)==(i|0)){A=139;break}d=e+16+(b>>>31<<2)|0;a=c[d>>2]|0;if(!a){A=136;break}else{b=b<<1;e=a}}if((A|0)==136)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[d>>2]=h;c[h+24>>2]=e;c[h+12>>2]=h;c[h+8>>2]=h;break}else if((A|0)==139){a=e+8|0;b=c[a>>2]|0;H=c[8854]|0;if(b>>>0>=H>>>0&e>>>0>=H>>>0){c[b+12>>2]=h;c[a>>2]=h;c[h+8>>2]=b;c[h+12>>2]=e;c[h+24>>2]=0;break}else Z()}}else{H=i+s|0;c[j+4>>2]=H|3;H=j+H+4|0;c[H>>2]=c[H>>2]|1}while(0);H=j+8|0;l=I;return H|0}}}else s=-1;while(0);d=c[8852]|0;if(d>>>0>=s>>>0){a=d-s|0;b=c[8855]|0;if(a>>>0>15){H=b+s|0;c[8855]=H;c[8852]=a;c[H+4>>2]=a|1;c[H+a>>2]=a;c[b+4>>2]=s|3}else{c[8852]=0;c[8855]=0;c[b+4>>2]=d|3;c[b+d+4>>2]=c[b+d+4>>2]|1}H=b+8|0;l=I;return H|0}f=c[8853]|0;if(f>>>0>s>>>0){F=f-s|0;c[8853]=F;H=c[8856]|0;G=H+s|0;c[8856]=G;c[G+4>>2]=F|1;c[H+4>>2]=s|3;H=H+8|0;l=I;return H|0}if(!(c[8968]|0)){c[8970]=4096;c[8969]=4096;c[8971]=-1;c[8972]=-1;c[8973]=0;c[8961]=0;c[n>>2]=n&-16^1431655768;c[8968]=n&-16^1431655768;a=4096}else a=c[8970]|0;h=s+48|0;i=s+47|0;k=a+i|0;j=0-a|0;if((k&j)>>>0<=s>>>0){H=0;l=I;return H|0}a=c[8960]|0;if(a|0?(x=c[8958]|0,(x+(k&j)|0)>>>0<=x>>>0?1:(x+(k&j)|0)>>>0>a>>>0):0){H=0;l=I;return H|0}d:do if(!(c[8961]&4)){d=c[8856]|0;e:do if(d){b=35848;while(1){a=c[b>>2]|0;if(a>>>0<=d>>>0?(t=b+4|0,(a+(c[t>>2]|0)|0)>>>0>d>>>0):0)break;a=c[b+8>>2]|0;if(!a){A=163;break e}else b=a}if((k-f&j)>>>0<2147483647){a=jd(k-f&j|0)|0;if((a|0)==((c[b>>2]|0)+(c[t>>2]|0)|0))if((a|0)==(-1|0))a=k-f&j;else{h=k-f&j;g=a;A=180;break d}else{e=a;d=k-f&j;A=171}}else a=0}else A=163;while(0);do if((A|0)==163){b=jd(0)|0;if((b|0)!=(-1|0)?(v=c[8969]|0,v=((v+-1&b|0)==0?0:(v+-1+b&0-v)-b|0)+(k&j)|0,u=c[8958]|0,v>>>0>s>>>0&v>>>0<2147483647):0){x=c[8960]|0;if(x|0?(v+u|0)>>>0<=u>>>0|(v+u|0)>>>0>x>>>0:0){a=0;break}a=jd(v|0)|0;if((a|0)==(b|0)){h=v;g=b;A=180;break d}else{e=a;d=v;A=171}}else a=0}while(0);do if((A|0)==171){b=0-d|0;if(!(h>>>0>d>>>0&(d>>>0<2147483647&(e|0)!=(-1|0))))if((e|0)==(-1|0)){a=0;break}else{h=d;g=e;A=180;break d}a=c[8970]|0;a=i-d+a&0-a;if(a>>>0>=2147483647){h=d;g=e;A=180;break d}if((jd(a|0)|0)==(-1|0)){jd(b|0)|0;a=0;break}else{h=a+d|0;g=e;A=180;break d}}while(0);c[8961]=c[8961]|4;A=178}else{a=0;A=178}while(0);if(((A|0)==178?(k&j)>>>0<2147483647:0)?(g=jd(k&j|0)|0,y=jd(0)|0,z=(y-g|0)>>>0>(s+40|0)>>>0,!((g|0)==(-1|0)|z^1|g>>>0<y>>>0&((g|0)!=(-1|0)&(y|0)!=(-1|0))^1)):0){h=z?y-g|0:a;A=180}if((A|0)==180){a=(c[8958]|0)+h|0;c[8958]=a;if(a>>>0>(c[8959]|0)>>>0)c[8959]=a;i=c[8856]|0;do if(i){a=35848;while(1){b=c[a>>2]|0;d=a+4|0;e=c[d>>2]|0;if((g|0)==(b+e|0)){A=190;break}f=c[a+8>>2]|0;if(!f)break;else a=f}if(((A|0)==190?(c[a+12>>2]&8|0)==0:0)?i>>>0<g>>>0&i>>>0>=b>>>0:0){c[d>>2]=e+h;G=(i+8&7|0)==0?0:0-(i+8)&7;H=(c[8853]|0)+(h-G)|0;c[8856]=i+G;c[8853]=H;c[i+G+4>>2]=H|1;c[i+G+H+4>>2]=40;c[8857]=c[8972];break}a=c[8854]|0;if(g>>>0<a>>>0){c[8854]=g;j=g}else j=a;d=g+h|0;a=35848;while(1){if((c[a>>2]|0)==(d|0)){A=198;break}b=c[a+8>>2]|0;if(!b)break;else a=b}if((A|0)==198?(c[a+12>>2]&8|0)==0:0){c[a>>2]=g;m=a+4|0;c[m>>2]=(c[m>>2]|0)+h;m=g+8|0;m=g+((m&7|0)==0?0:0-m&7)|0;a=d+((d+8&7|0)==0?0:0-(d+8)&7)|0;k=m+s|0;f=a-m-s|0;c[m+4>>2]=s|3;do if((a|0)!=(i|0)){if((a|0)==(c[8855]|0)){H=(c[8852]|0)+f|0;c[8852]=H;c[8855]=k;c[k+4>>2]=H|1;c[k+H>>2]=H;break}i=c[a+4>>2]|0;if((i&3|0)==1){f:do if(i>>>0>=256){h=c[a+24>>2]|0;b=c[a+12>>2]|0;do if((b|0)==(a|0)){b=c[a+16+4>>2]|0;if(!b){b=c[a+16>>2]|0;if(!b){F=0;break}else g=a+16|0}else g=a+16+4|0;while(1){d=b+20|0;e=c[d>>2]|0;if(e|0){b=e;g=d;continue}d=b+16|0;e=c[d>>2]|0;if(!e)break;else{b=e;g=d}}if(g>>>0<j>>>0)Z();else{c[g>>2]=0;F=b;break}}else{d=c[a+8>>2]|0;if(d>>>0<j>>>0)Z();if((c[d+12>>2]|0)!=(a|0))Z();if((c[b+8>>2]|0)==(a|0)){c[d+12>>2]=b;c[b+8>>2]=d;F=b;break}else Z()}while(0);if(!h)break;b=c[a+28>>2]|0;do if((a|0)!=(c[35704+(b<<2)>>2]|0))if(h>>>0>=(c[8854]|0)>>>0){c[h+16+(((c[h+16>>2]|0)!=(a|0)&1)<<2)>>2]=F;if(!F)break f;else break}else Z();else{c[35704+(b<<2)>>2]=F;if(F|0)break;c[8851]=c[8851]&~(1<<b);break f}while(0);d=c[8854]|0;if(F>>>0<d>>>0)Z();c[F+24>>2]=h;b=c[a+16>>2]|0;do if(b|0)if(b>>>0<d>>>0)Z();else{c[F+16>>2]=b;c[b+24>>2]=F;break}while(0);b=c[a+16+4>>2]|0;if(!b)break;if(b>>>0<(c[8854]|0)>>>0)Z();else{c[F+20>>2]=b;c[b+24>>2]=F;break}}else{b=c[a+8>>2]|0;d=c[a+12>>2]|0;do if((b|0)!=(35440+(i>>>3<<1<<2)|0)){if(b>>>0<j>>>0)Z();if((c[b+12>>2]|0)==(a|0))break;Z()}while(0);if((d|0)==(b|0)){c[8850]=c[8850]&~(1<<(i>>>3));break}do if((d|0)==(35440+(i>>>3<<1<<2)|0))E=d+8|0;else{if(d>>>0<j>>>0)Z();if((c[d+8>>2]|0)==(a|0)){E=d+8|0;break}Z()}while(0);c[b+12>>2]=d;c[E>>2]=b}while(0);a=a+(i&-8)|0;f=(i&-8)+f|0}b=a+4|0;c[b>>2]=c[b>>2]&-2;c[k+4>>2]=f|1;c[k+f>>2]=f;b=f>>>3;if(f>>>0<256){a=c[8850]|0;do if(!(a&1<<b)){c[8850]=a|1<<b;G=35440+(b<<1<<2)|0;H=35440+(b<<1<<2)+8|0}else{a=c[35440+(b<<1<<2)+8>>2]|0;if(a>>>0>=(c[8854]|0)>>>0){G=a;H=35440+(b<<1<<2)+8|0;break}Z()}while(0);c[H>>2]=k;c[G+12>>2]=k;c[k+8>>2]=G;c[k+12>>2]=35440+(b<<1<<2);break}a=f>>>8;do if(!a)a=0;else{if(f>>>0>16777215){a=31;break}H=a<<((a+1048320|0)>>>16&8)<<(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4);a=14-(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4|(a+1048320|0)>>>16&8|(H+245760|0)>>>16&2)+(H<<((H+245760|0)>>>16&2)>>>15)|0;a=f>>>(a+7|0)&1|a<<1}while(0);e=35704+(a<<2)|0;c[k+28>>2]=a;c[k+16+4>>2]=0;c[k+16>>2]=0;b=c[8851]|0;d=1<<a;if(!(b&d)){c[8851]=b|d;c[e>>2]=k;c[k+24>>2]=e;c[k+12>>2]=k;c[k+8>>2]=k;break}b=f<<((a|0)==31?0:25-(a>>>1)|0);e=c[e>>2]|0;while(1){if((c[e+4>>2]&-8|0)==(f|0)){A=265;break}d=e+16+(b>>>31<<2)|0;a=c[d>>2]|0;if(!a){A=262;break}else{b=b<<1;e=a}}if((A|0)==262)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[d>>2]=k;c[k+24>>2]=e;c[k+12>>2]=k;c[k+8>>2]=k;break}else if((A|0)==265){a=e+8|0;b=c[a>>2]|0;H=c[8854]|0;if(b>>>0>=H>>>0&e>>>0>=H>>>0){c[b+12>>2]=k;c[a>>2]=k;c[k+8>>2]=b;c[k+12>>2]=e;c[k+24>>2]=0;break}else Z()}}else{H=(c[8853]|0)+f|0;c[8853]=H;c[8856]=k;c[k+4>>2]=H|1}while(0);H=m+8|0;l=I;return H|0}a=35848;while(1){b=c[a>>2]|0;if(b>>>0<=i>>>0?(B=b+(c[a+4>>2]|0)|0,B>>>0>i>>>0):0)break;a=c[a+8>>2]|0}f=B+-47+((B+-47+8&7|0)==0?0:0-(B+-47+8)&7)|0;f=f>>>0<(i+16|0)>>>0?i:f;a=g+8|0;a=(a&7|0)==0?0:0-a&7;H=g+a|0;a=h+-40-a|0;c[8856]=H;c[8853]=a;c[H+4>>2]=a|1;c[H+a+4>>2]=40;c[8857]=c[8972];c[f+4>>2]=27;c[f+8>>2]=c[8962];c[f+8+4>>2]=c[8963];c[f+8+8>>2]=c[8964];c[f+8+12>>2]=c[8965];c[8962]=g;c[8963]=h;c[8965]=0;c[8964]=f+8;a=f+24|0;do{H=a;a=a+4|0;c[a>>2]=7}while((H+8|0)>>>0<B>>>0);if((f|0)!=(i|0)){c[f+4>>2]=c[f+4>>2]&-2;c[i+4>>2]=f-i|1;c[f>>2]=f-i;if((f-i|0)>>>0<256){b=35440+((f-i|0)>>>3<<1<<2)|0;a=c[8850]|0;if(a&1<<((f-i|0)>>>3)){a=c[b+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{C=a;D=b+8|0}}else{c[8850]=a|1<<((f-i|0)>>>3);C=b;D=b+8|0}c[D>>2]=i;c[C+12>>2]=i;c[i+8>>2]=C;c[i+12>>2]=b;break}if((f-i|0)>>>8)if((f-i|0)>>>0>16777215)a=31;else{a=(f-i|0)>>>8<<((((f-i|0)>>>8)+1048320|0)>>>16&8);a=14-((a+520192|0)>>>16&4|(((f-i|0)>>>8)+1048320|0)>>>16&8|((a<<((a+520192|0)>>>16&4))+245760|0)>>>16&2)+(a<<((a+520192|0)>>>16&4)<<(((a<<((a+520192|0)>>>16&4))+245760|0)>>>16&2)>>>15)|0;a=(f-i|0)>>>(a+7|0)&1|a<<1}else a=0;e=35704+(a<<2)|0;c[i+28>>2]=a;c[i+20>>2]=0;c[i+16>>2]=0;b=c[8851]|0;d=1<<a;if(!(b&d)){c[8851]=b|d;c[e>>2]=i;c[i+24>>2]=e;c[i+12>>2]=i;c[i+8>>2]=i;break}b=f-i<<((a|0)==31?0:25-(a>>>1)|0);e=c[e>>2]|0;while(1){if((c[e+4>>2]&-8|0)==(f-i|0)){A=292;break}d=e+16+(b>>>31<<2)|0;a=c[d>>2]|0;if(!a){A=289;break}else{b=b<<1;e=a}}if((A|0)==289)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[d>>2]=i;c[i+24>>2]=e;c[i+12>>2]=i;c[i+8>>2]=i;break}else if((A|0)==292){a=e+8|0;b=c[a>>2]|0;H=c[8854]|0;if(b>>>0>=H>>>0&e>>>0>=H>>>0){c[b+12>>2]=i;c[a>>2]=i;c[i+8>>2]=b;c[i+12>>2]=e;c[i+24>>2]=0;break}else Z()}}}else{H=c[8854]|0;if((H|0)==0|g>>>0<H>>>0)c[8854]=g;c[8962]=g;c[8963]=h;c[8965]=0;c[8859]=c[8968];c[8858]=-1;a=0;do{H=35440+(a<<1<<2)|0;c[H+12>>2]=H;c[H+8>>2]=H;a=a+1|0}while((a|0)!=32);H=g+8|0;H=(H&7|0)==0?0:0-H&7;G=g+H|0;H=h+-40-H|0;c[8856]=G;c[8853]=H;c[G+4>>2]=H|1;c[G+H+4>>2]=40;c[8857]=c[8972]}while(0);a=c[8853]|0;if(a>>>0>s>>>0){F=a-s|0;c[8853]=F;H=c[8856]|0;G=H+s|0;c[8856]=G;c[G+4>>2]=F|1;c[H+4>>2]=s|3;H=H+8|0;l=I;return H|0}}c[8326]=12;H=0;l=I;return H|0}function ja(a,b,d,e){a=a|0;b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0;De(d,b);b=e;f=a;g=b+64|0;do{c[b>>2]=c[f>>2];b=b+4|0;f=f+4|0}while((b|0)<(g|0));s=0;b=c[d>>2]|0;f=c[d+4>>2]|0;while(1){A=c[e+32>>2]|0;q=c[e+32+4>>2]|0;i=Ze(A,q,14)|0;C=z;y=Ze(A,q,18)|0;C=z^C;D=Ze(A,q,41)|0;r=c[e+40>>2]|0;l=c[e+40+4>>2]|0;k=c[e+48>>2]|0;M=c[e+48+4>>2]|0;o=464+(s<<3)|0;m=c[o>>2]|0;o=c[o+4>>2]|0;w=c[e+56>>2]|0;u=c[e+56+4>>2]|0;C=fg(b|0,f|0,y^i^D|0,C^z|0)|0;o=fg(C|0,z|0,m|0,o|0)|0;o=fg(o|0,z|0,(k^r)&A^k|0,(M^l)&q^M|0)|0;u=fg(o|0,z|0,w|0,u|0)|0;w=z;o=fg(u|0,w|0,c[e+24>>2]|0,c[e+24+4>>2]|0)|0;m=z;c[e+24>>2]=o;c[e+24+4>>2]=m;C=c[e>>2]|0;D=c[e+4>>2]|0;i=Ze(C,D,28)|0;y=z;j=Ze(C,D,34)|0;y=z^y;v=Ze(C,D,39)|0;B=c[e+8>>2]|0;H=c[e+8+4>>2]|0;E=c[e+16>>2]|0;I=c[e+16+4>>2]|0;y=fg(u|0,w|0,j^i^v|0,y^z|0)|0;y=fg(y|0,z|0,(E|B)&C|E&B|0,(I|H)&D|I&H|0)|0;v=z;c[e+56>>2]=y;c[e+56+4>>2]=v;i=Ze(o,m,14)|0;j=z;w=Ze(o,m,18)|0;j=z^j;u=Ze(o,m,41)|0;h=s|1;x=c[464+(h<<3)>>2]|0;L=c[464+(h<<3)+4>>2]|0;j=fg(c[d+(h<<3)>>2]|0,c[d+(h<<3)+4>>2]|0,w^i^u|0,j^z|0)|0;L=fg(j|0,z|0,x|0,L|0)|0;L=fg(L|0,z|0,(r^A)&o^r|0,(l^q)&m^l|0)|0;M=fg(L|0,z|0,k|0,M|0)|0;k=z;I=fg(M|0,k|0,E|0,I|0)|0;E=z;c[e+16>>2]=I;c[e+16+4>>2]=E;L=Ze(y,v,28)|0;x=z;j=Ze(y,v,34)|0;x=z^x;u=Ze(y,v,39)|0;x=fg(M|0,k|0,j^L^u|0,x^z|0)|0;x=fg(x|0,z|0,(B|C)&y|B&C|0,(H|D)&v|H&D|0)|0;u=z;c[e+48>>2]=x;c[e+48+4>>2]=u;L=Ze(I,E,14)|0;j=z;k=Ze(I,E,18)|0;j=z^j;M=Ze(I,E,41)|0;i=s|2;w=c[464+(i<<3)>>2]|0;n=c[464+(i<<3)+4>>2]|0;j=fg(c[d+(i<<3)>>2]|0,c[d+(i<<3)+4>>2]|0,k^L^M|0,j^z|0)|0;n=fg(j|0,z|0,w|0,n|0)|0;q=fg(n|0,z|0,(A^o)&I^A|0,(q^m)&E^q|0)|0;l=fg(q|0,z|0,r|0,l|0)|0;r=z;H=fg(l|0,r|0,B|0,H|0)|0;B=z;c[e+8>>2]=H;c[e+8+4>>2]=B;q=Ze(x,u,28)|0;A=z;n=Ze(x,u,34)|0;A=z^A;w=Ze(x,u,39)|0;A=fg(l|0,r|0,n^q^w|0,A^z|0)|0;A=fg(A|0,z|0,(C|y)&x|C&y|0,(D|v)&u|D&v|0)|0;w=z;c[e+40>>2]=A;c[e+40+4>>2]=w;q=Ze(H,B,14)|0;n=z;r=Ze(H,B,18)|0;n=z^n;l=Ze(H,B,41)|0;j=s|3;M=c[464+(j<<3)>>2]|0;L=c[464+(j<<3)+4>>2]|0;k=c[e+32>>2]|0;p=c[e+32+4>>2]|0;n=fg(c[d+(j<<3)>>2]|0,c[d+(j<<3)+4>>2]|0,r^q^l|0,n^z|0)|0;L=fg(n|0,z|0,M|0,L|0)|0;m=fg(L|0,z|0,(o^I)&H^o|0,(m^E)&B^m|0)|0;p=fg(m|0,z|0,k|0,p|0)|0;k=z;D=fg(p|0,k|0,C|0,D|0)|0;C=z;c[e>>2]=D;c[e+4>>2]=C;m=Ze(A,w,28)|0;o=z;L=Ze(A,w,34)|0;o=z^o;M=Ze(A,w,39)|0;o=fg(p|0,k|0,L^m^M|0,o^z|0)|0;v=fg(o|0,z|0,(y|x)&A|y&x|0,(v|u)&w|v&u|0)|0;y=z;c[e+32>>2]=v;c[e+32+4>>2]=y;o=Ze(D,C,14)|0;M=z;m=Ze(D,C,18)|0;M=z^M;L=Ze(D,C,41)|0;k=s|4;p=c[464+(k<<3)>>2]|0;n=c[464+(k<<3)+4>>2]|0;l=c[e+24>>2]|0;q=c[e+24+4>>2]|0;M=fg(c[d+(k<<3)>>2]|0,c[d+(k<<3)+4>>2]|0,m^o^L|0,M^z|0)|0;n=fg(M|0,z|0,p|0,n|0)|0;E=fg(n|0,z|0,(I^H)&D^I|0,(E^B)&C^E|0)|0;q=fg(E|0,z|0,l|0,q|0)|0;l=z;E=fg(q|0,l|0,c[e+56>>2]|0,c[e+56+4>>2]|0)|0;I=z;c[e+56>>2]=E;c[e+56+4>>2]=I;n=Ze(v,y,28)|0;p=z;M=Ze(v,y,34)|0;p=z^p;L=Ze(v,y,39)|0;p=fg(q|0,l|0,M^n^L|0,p^z|0)|0;u=fg(p|0,z|0,(x|A)&v|x&A|0,(u|w)&y|u&w|0)|0;x=z;c[e+24>>2]=u;c[e+24+4>>2]=x;p=Ze(E,I,14)|0;L=z;n=Ze(E,I,18)|0;L=z^L;M=Ze(E,I,41)|0;l=s|5;q=c[464+(l<<3)>>2]|0;o=c[464+(l<<3)+4>>2]|0;m=c[e+16>>2]|0;r=c[e+16+4>>2]|0;L=fg(c[d+(l<<3)>>2]|0,c[d+(l<<3)+4>>2]|0,n^p^M|0,L^z|0)|0;o=fg(L|0,z|0,q|0,o|0)|0;B=fg(o|0,z|0,(H^D)&E^H|0,(B^C)&I^B|0)|0;r=fg(B|0,z|0,m|0,r|0)|0;m=z;B=fg(r|0,m|0,c[e+48>>2]|0,c[e+48+4>>2]|0)|0;H=z;c[e+48>>2]=B;c[e+48+4>>2]=H;o=Ze(u,x,28)|0;q=z;L=Ze(u,x,34)|0;q=z^q;M=Ze(u,x,39)|0;q=fg(r|0,m|0,L^o^M|0,q^z|0)|0;w=fg(q|0,z|0,(A|v)&u|A&v|0,(w|y)&x|w&y|0)|0;A=z;c[e+16>>2]=w;c[e+16+4>>2]=A;q=Ze(B,H,14)|0;M=z;o=Ze(B,H,18)|0;M=z^M;L=Ze(B,H,41)|0;m=s|6;r=c[464+(m<<3)>>2]|0;p=c[464+(m<<3)+4>>2]|0;n=c[e+8>>2]|0;b=c[e+8+4>>2]|0;M=fg(c[d+(m<<3)>>2]|0,c[d+(m<<3)+4>>2]|0,o^q^L|0,M^z|0)|0;p=fg(M|0,z|0,r|0,p|0)|0;C=fg(p|0,z|0,(D^E)&B^D|0,(C^I)&H^C|0)|0;b=fg(C|0,z|0,n|0,b|0)|0;n=z;C=fg(b|0,n|0,c[e+40>>2]|0,c[e+40+4>>2]|0)|0;D=z;c[e+40>>2]=C;c[e+40+4>>2]=D;p=Ze(w,A,28)|0;r=z;M=Ze(w,A,34)|0;r=z^r;L=Ze(w,A,39)|0;r=fg(b|0,n|0,M^p^L|0,r^z|0)|0;y=fg(r|0,z|0,(v|u)&w|v&u|0,(y|x)&A|y&x|0)|0;v=z;c[e+8>>2]=y;c[e+8+4>>2]=v;r=Ze(C,D,14)|0;L=z;p=Ze(C,D,18)|0;L=z^L;M=Ze(C,D,41)|0;n=s|7;b=c[464+(n<<3)>>2]|0;q=c[464+(n<<3)+4>>2]|0;o=c[e>>2]|0;f=c[e+4>>2]|0;L=fg(c[d+(n<<3)>>2]|0,c[d+(n<<3)+4>>2]|0,p^r^M|0,L^z|0)|0;q=fg(L|0,z|0,b|0,q|0)|0;I=fg(q|0,z|0,(E^B)&C^E|0,(I^H)&D^I|0)|0;f=fg(I|0,z|0,o|0,f|0)|0;o=z;I=fg(f|0,o|0,c[e+32>>2]|0,c[e+32+4>>2]|0)|0;E=z;c[e+32>>2]=I;c[e+32+4>>2]=E;q=Ze(y,v,28)|0;b=z;L=Ze(y,v,34)|0;b=z^b;M=Ze(y,v,39)|0;b=fg(f|0,o|0,L^q^M|0,b^z|0)|0;x=fg(b|0,z|0,(u|w)&y|u&w|0,(x|A)&v|x&A|0)|0;u=z;c[e>>2]=x;c[e+4>>2]=u;b=Ze(I,E,14)|0;M=z;q=Ze(I,E,18)|0;M=z^M;L=Ze(I,E,41)|0;o=s|8;f=c[464+(o<<3)>>2]|0;r=c[464+(o<<3)+4>>2]|0;p=c[e+56>>2]|0;g=c[e+56+4>>2]|0;M=fg(c[d+(o<<3)>>2]|0,c[d+(o<<3)+4>>2]|0,q^b^L|0,M^z|0)|0;r=fg(M|0,z|0,f|0,r|0)|0;H=fg(r|0,z|0,(B^C)&I^B|0,(H^D)&E^H|0)|0;g=fg(H|0,z|0,p|0,g|0)|0;p=z;H=fg(g|0,p|0,c[e+24>>2]|0,c[e+24+4>>2]|0)|0;B=z;c[e+24>>2]=H;c[e+24+4>>2]=B;r=Ze(x,u,28)|0;f=z;M=Ze(x,u,34)|0;f=z^f;L=Ze(x,u,39)|0;f=fg(g|0,p|0,M^r^L|0,f^z|0)|0;A=fg(f|0,z|0,(w|y)&x|w&y|0,(A|v)&u|A&v|0)|0;w=z;c[e+56>>2]=A;c[e+56+4>>2]=w;f=Ze(H,B,14)|0;L=z;r=Ze(H,B,18)|0;L=z^L;M=Ze(H,B,41)|0;p=s|9;g=c[464+(p<<3)>>2]|0;b=c[464+(p<<3)+4>>2]|0;q=c[e+48>>2]|0;t=c[e+48+4>>2]|0;L=fg(c[d+(p<<3)>>2]|0,c[d+(p<<3)+4>>2]|0,r^f^M|0,L^z|0)|0;b=fg(L|0,z|0,g|0,b|0)|0;D=fg(b|0,z|0,(C^I)&H^C|0,(D^E)&B^D|0)|0;t=fg(D|0,z|0,q|0,t|0)|0;q=z;D=fg(t|0,q|0,c[e+16>>2]|0,c[e+16+4>>2]|0)|0;C=z;c[e+16>>2]=D;c[e+16+4>>2]=C;b=Ze(A,w,28)|0;g=z;L=Ze(A,w,34)|0;g=z^g;M=Ze(A,w,39)|0;g=fg(t|0,q|0,L^b^M|0,g^z|0)|0;v=fg(g|0,z|0,(y|x)&A|y&x|0,(v|u)&w|v&u|0)|0;y=z;c[e+48>>2]=v;c[e+48+4>>2]=y;g=Ze(D,C,14)|0;M=z;b=Ze(D,C,18)|0;M=z^M;L=Ze(D,C,41)|0;q=s|10;t=c[464+(q<<3)>>2]|0;f=c[464+(q<<3)+4>>2]|0;r=c[e+40>>2]|0;F=c[e+40+4>>2]|0;M=fg(c[d+(q<<3)>>2]|0,c[d+(q<<3)+4>>2]|0,b^g^L|0,M^z|0)|0;f=fg(M|0,z|0,t|0,f|0)|0;E=fg(f|0,z|0,(I^H)&D^I|0,(E^B)&C^E|0)|0;F=fg(E|0,z|0,r|0,F|0)|0;r=z;E=fg(F|0,r|0,c[e+8>>2]|0,c[e+8+4>>2]|0)|0;I=z;c[e+8>>2]=E;c[e+8+4>>2]=I;f=Ze(v,y,28)|0;t=z;M=Ze(v,y,34)|0;t=z^t;L=Ze(v,y,39)|0;t=fg(F|0,r|0,M^f^L|0,t^z|0)|0;u=fg(t|0,z|0,(x|A)&v|x&A|0,(u|w)&y|u&w|0)|0;x=z;c[e+40>>2]=u;c[e+40+4>>2]=x;t=Ze(E,I,14)|0;L=z;f=Ze(E,I,18)|0;L=z^L;M=Ze(E,I,41)|0;r=s|11;F=c[464+(r<<3)>>2]|0;g=c[464+(r<<3)+4>>2]|0;b=c[e+32>>2]|0;O=c[e+32+4>>2]|0;L=fg(c[d+(r<<3)>>2]|0,c[d+(r<<3)+4>>2]|0,f^t^M|0,L^z|0)|0;g=fg(L|0,z|0,F|0,g|0)|0;B=fg(g|0,z|0,(H^D)&E^H|0,(B^C)&I^B|0)|0;O=fg(B|0,z|0,b|0,O|0)|0;b=z;B=fg(O|0,b|0,c[e>>2]|0,c[e+4>>2]|0)|0;H=z;c[e>>2]=B;c[e+4>>2]=H;g=Ze(u,x,28)|0;F=z;L=Ze(u,x,34)|0;F=z^F;M=Ze(u,x,39)|0;F=fg(O|0,b|0,L^g^M|0,F^z|0)|0;w=fg(F|0,z|0,(A|v)&u|A&v|0,(w|y)&x|w&y|0)|0;A=z;c[e+32>>2]=w;c[e+32+4>>2]=A;F=Ze(B,H,14)|0;M=z;g=Ze(B,H,18)|0;M=z^M;L=Ze(B,H,41)|0;b=s|12;O=c[464+(b<<3)>>2]|0;t=c[464+(b<<3)+4>>2]|0;f=c[e+24>>2]|0;J=c[e+24+4>>2]|0;M=fg(c[d+(b<<3)>>2]|0,c[d+(b<<3)+4>>2]|0,g^F^L|0,M^z|0)|0;t=fg(M|0,z|0,O|0,t|0)|0;C=fg(t|0,z|0,(D^E)&B^D|0,(C^I)&H^C|0)|0;J=fg(C|0,z|0,f|0,J|0)|0;f=z;C=fg(J|0,f|0,c[e+56>>2]|0,c[e+56+4>>2]|0)|0;D=z;c[e+56>>2]=C;c[e+56+4>>2]=D;t=Ze(w,A,28)|0;O=z;M=Ze(w,A,34)|0;O=z^O;L=Ze(w,A,39)|0;O=fg(J|0,f|0,M^t^L|0,O^z|0)|0;y=fg(O|0,z|0,(v|u)&w|v&u|0,(y|x)&A|y&x|0)|0;v=z;c[e+24>>2]=y;c[e+24+4>>2]=v;O=Ze(C,D,14)|0;L=z;t=Ze(C,D,18)|0;L=z^L;M=Ze(C,D,41)|0;f=s|13;J=c[464+(f<<3)>>2]|0;F=c[464+(f<<3)+4>>2]|0;g=c[e+16>>2]|0;N=c[e+16+4>>2]|0;L=fg(c[d+(f<<3)>>2]|0,c[d+(f<<3)+4>>2]|0,t^O^M|0,L^z|0)|0;F=fg(L|0,z|0,J|0,F|0)|0;I=fg(F|0,z|0,(E^B)&C^E|0,(I^H)&D^I|0)|0;N=fg(I|0,z|0,g|0,N|0)|0;g=z;I=fg(N|0,g|0,c[e+48>>2]|0,c[e+48+4>>2]|0)|0;E=z;c[e+48>>2]=I;c[e+48+4>>2]=E;F=Ze(y,v,28)|0;J=z;L=Ze(y,v,34)|0;J=z^J;M=Ze(y,v,39)|0;J=fg(N|0,g|0,L^F^M|0,J^z|0)|0;x=fg(J|0,z|0,(u|w)&y|u&w|0,(x|A)&v|x&A|0)|0;u=z;c[e+16>>2]=x;c[e+16+4>>2]=u;J=Ze(I,E,14)|0;M=z;F=Ze(I,E,18)|0;M=z^M;L=Ze(I,E,41)|0;g=s|14;N=c[464+(g<<3)>>2]|0;O=c[464+(g<<3)+4>>2]|0;t=c[e+8>>2]|0;K=c[e+8+4>>2]|0;M=fg(c[d+(g<<3)>>2]|0,c[d+(g<<3)+4>>2]|0,F^J^L|0,M^z|0)|0;O=fg(M|0,z|0,N|0,O|0)|0;H=fg(O|0,z|0,(B^C)&I^B|0,(H^D)&E^H|0)|0;K=fg(H|0,z|0,t|0,K|0)|0;t=z;H=fg(K|0,t|0,c[e+40>>2]|0,c[e+40+4>>2]|0)|0;B=z;c[e+40>>2]=H;c[e+40+4>>2]=B;O=Ze(x,u,28)|0;N=z;M=Ze(x,u,34)|0;N=z^N;L=Ze(x,u,39)|0;N=fg(K|0,t|0,M^O^L|0,N^z|0)|0;A=fg(N|0,z|0,(w|y)&x|w&y|0,(A|v)&u|A&v|0)|0;w=z;c[e+8>>2]=A;c[e+8+4>>2]=w;N=Ze(H,B,14)|0;L=z;O=Ze(H,B,18)|0;L=z^L;M=Ze(H,B,41)|0;t=s|15;K=c[464+(t<<3)>>2]|0;J=c[464+(t<<3)+4>>2]|0;F=c[e>>2]|0;G=c[e+4>>2]|0;L=fg(c[d+(t<<3)>>2]|0,c[d+(t<<3)+4>>2]|0,O^N^M|0,L^z|0)|0;J=fg(L|0,z|0,K|0,J|0)|0;D=fg(J|0,z|0,(C^I)&H^C|0,(D^E)&B^D|0)|0;G=fg(D|0,z|0,F|0,G|0)|0;F=z;D=fg(G|0,F|0,c[e+32>>2]|0,c[e+32+4>>2]|0)|0;c[e+32>>2]=D;c[e+32+4>>2]=z;D=Ze(A,w,28)|0;B=z;E=Ze(A,w,34)|0;B=z^B;C=Ze(A,w,39)|0;B=fg(G|0,F|0,E^D^C|0,B^z|0)|0;u=fg(B|0,z|0,(y|x)&A|y&x|0,(v|u)&w|v&u|0)|0;c[e>>2]=u;c[e+4>>2]=z;if((s|0)==64){b=0;break}K=c[d+(g<<3)>>2]|0;I=c[d+(g<<3)+4>>2]|0;N=Ze(K,I,19)|0;C=z;H=Ze(K,I,61)|0;J=z;I=yf(K|0,I|0,6)|0;J=fg(I^N^H|0,z^C^J|0,c[d+(p<<3)>>2]|0,c[d+(p<<3)+4>>2]|0)|0;C=z;H=c[d+(h<<3)>>2]|0;N=c[d+(h<<3)+4>>2]|0;I=Ze(H,N,1)|0;K=z;G=Ze(H,N,8)|0;L=z;E=yf(H|0,N|0,7)|0;L=z^K^L;K=d+(s<<3)|0;K=fg(J|0,C|0,c[K>>2]|0,c[K+4>>2]|0)|0;L=fg(K|0,z|0,E^I^G|0,L|0)|0;G=z;s=s+16|0;I=d+(s<<3)|0;c[I>>2]=L;c[I+4>>2]=G;I=c[d+(t<<3)>>2]|0;E=c[d+(t<<3)+4>>2]|0;K=Ze(I,E,19)|0;C=z;J=Ze(I,E,61)|0;F=z;E=yf(I|0,E|0,6)|0;F=fg(E^K^J|0,z^C^F|0,c[d+(h+9<<3)>>2]|0,c[d+(h+9<<3)+4>>2]|0)|0;C=z;J=c[d+(h+1<<3)>>2]|0;K=c[d+(h+1<<3)+4>>2]|0;E=Ze(J,K,1)|0;I=z;O=Ze(J,K,8)|0;M=z;D=yf(J|0,K|0,7)|0;M=z^I^M;N=fg(F|0,C|0,H|0,N|0)|0;M=fg(N|0,z|0,D^E^O|0,M|0)|0;O=z;c[d+(h+16<<3)>>2]=M;c[d+(h+16<<3)+4>>2]=O;E=Ze(L,G,19)|0;D=z;N=Ze(L,G,61)|0;H=z;G=yf(L|0,G|0,6)|0;H=fg(G^E^N|0,z^D^H|0,c[d+(r<<3)>>2]|0,c[d+(r<<3)+4>>2]|0)|0;D=z;N=c[d+(j<<3)>>2]|0;E=c[d+(j<<3)+4>>2]|0;G=Ze(N,E,1)|0;L=z;C=Ze(N,E,8)|0;F=z;I=yf(N|0,E|0,7)|0;F=z^L^F;K=fg(H|0,D|0,J|0,K|0)|0;F=fg(K|0,z|0,I^G^C|0,F|0)|0;C=z;c[d+(i+16<<3)>>2]=F;c[d+(i+16<<3)+4>>2]=C;G=Ze(M,O,19)|0;I=z;K=Ze(M,O,61)|0;J=z;O=yf(M|0,O|0,6)|0;J=fg(O^G^K|0,z^I^J|0,c[d+(j+9<<3)>>2]|0,c[d+(j+9<<3)+4>>2]|0)|0;I=z;K=c[d+(j+1<<3)>>2]|0;G=c[d+(j+1<<3)+4>>2]|0;O=Ze(K,G,1)|0;M=z;D=Ze(K,G,8)|0;H=z;L=yf(K|0,G|0,7)|0;H=z^M^H;E=fg(J|0,I|0,N|0,E|0)|0;H=fg(E|0,z|0,L^O^D|0,H|0)|0;D=z;c[d+(j+16<<3)>>2]=H;c[d+(j+16<<3)+4>>2]=D;O=Ze(F,C,19)|0;L=z;E=Ze(F,C,61)|0;N=z;C=yf(F|0,C|0,6)|0;N=fg(C^O^E|0,z^L^N|0,c[d+(f<<3)>>2]|0,c[d+(f<<3)+4>>2]|0)|0;L=z;E=c[d+(l<<3)>>2]|0;O=c[d+(l<<3)+4>>2]|0;C=Ze(E,O,1)|0;F=z;I=Ze(E,O,8)|0;J=z;M=yf(E|0,O|0,7)|0;J=z^F^J;G=fg(N|0,L|0,K|0,G|0)|0;J=fg(G|0,z|0,M^C^I|0,J|0)|0;I=z;c[d+(k+16<<3)>>2]=J;c[d+(k+16<<3)+4>>2]=I;C=Ze(H,D,19)|0;M=z;G=Ze(H,D,61)|0;K=z;D=yf(H|0,D|0,6)|0;K=fg(D^C^G|0,z^M^K|0,c[d+(l+9<<3)>>2]|0,c[d+(l+9<<3)+4>>2]|0)|0;M=z;G=c[d+(l+1<<3)>>2]|0;C=c[d+(l+1<<3)+4>>2]|0;D=Ze(G,C,1)|0;H=z;L=Ze(G,C,8)|0;N=z;F=yf(G|0,C|0,7)|0;N=z^H^N;O=fg(K|0,M|0,E|0,O|0)|0;N=fg(O|0,z|0,F^D^L|0,N|0)|0;L=z;c[d+(l+16<<3)>>2]=N;c[d+(l+16<<3)+4>>2]=L;D=Ze(J,I,19)|0;F=z;O=Ze(J,I,61)|0;E=z;I=yf(J|0,I|0,6)|0;E=fg(I^D^O|0,z^F^E|0,c[d+(t<<3)>>2]|0,c[d+(t<<3)+4>>2]|0)|0;F=z;O=c[d+(n<<3)>>2]|0;D=c[d+(n<<3)+4>>2]|0;I=Ze(O,D,1)|0;J=z;M=Ze(O,D,8)|0;K=z;H=yf(O|0,D|0,7)|0;K=z^J^K;C=fg(E|0,F|0,G|0,C|0)|0;K=fg(C|0,z|0,H^I^M|0,K|0)|0;M=z;c[d+(m+16<<3)>>2]=K;c[d+(m+16<<3)+4>>2]=M;I=Ze(N,L,19)|0;H=z;C=Ze(N,L,61)|0;G=z;L=yf(N|0,L|0,6)|0;G=fg(L^I^C|0,z^H^G|0,c[d+(n+9<<3)>>2]|0,c[d+(n+9<<3)+4>>2]|0)|0;H=z;C=c[d+(n+1<<3)>>2]|0;I=c[d+(n+1<<3)+4>>2]|0;L=Ze(C,I,1)|0;N=z;F=Ze(C,I,8)|0;E=z;J=yf(C|0,I|0,7)|0;E=z^N^E;D=fg(G|0,H|0,O|0,D|0)|0;E=fg(D|0,z|0,J^L^F|0,E|0)|0;F=z;c[d+(n+16<<3)>>2]=E;c[d+(n+16<<3)+4>>2]=F;L=Ze(K,M,19)|0;J=z;D=Ze(K,M,61)|0;O=z;M=yf(K|0,M|0,6)|0;O=fg(M^L^D|0,z^J^O|0,c[d+(o+9<<3)>>2]|0,c[d+(o+9<<3)+4>>2]|0)|0;J=z;D=c[d+(p<<3)>>2]|0;L=c[d+(p<<3)+4>>2]|0;M=Ze(D,L,1)|0;K=z;H=Ze(D,L,8)|0;G=z;N=yf(D|0,L|0,7)|0;G=z^K^G;I=fg(O|0,J|0,C|0,I|0)|0;G=fg(I|0,z|0,N^M^H|0,G|0)|0;H=z;c[d+(o+16<<3)>>2]=G;c[d+(o+16<<3)+4>>2]=H;M=Ze(E,F,19)|0;N=z;I=Ze(E,F,61)|0;C=z;F=yf(E|0,F|0,6)|0;C=fg(F^M^I|0,z^N^C|0,c[d+(p+9<<3)>>2]|0,c[d+(p+9<<3)+4>>2]|0)|0;N=z;I=c[d+(p+1<<3)>>2]|0;M=c[d+(p+1<<3)+4>>2]|0;F=Ze(I,M,1)|0;E=z;J=Ze(I,M,8)|0;O=z;K=yf(I|0,M|0,7)|0;O=z^E^O;L=fg(C|0,N|0,D|0,L|0)|0;O=fg(L|0,z|0,K^F^J|0,O|0)|0;J=z;c[d+(p+16<<3)>>2]=O;c[d+(p+16<<3)+4>>2]=J;F=Ze(G,H,19)|0;K=z;L=Ze(G,H,61)|0;D=z;H=yf(G|0,H|0,6)|0;D=fg(H^F^L|0,z^K^D|0,c[d+(q+9<<3)>>2]|0,c[d+(q+9<<3)+4>>2]|0)|0;K=z;L=c[d+(r<<3)>>2]|0;F=c[d+(r<<3)+4>>2]|0;H=Ze(L,F,1)|0;G=z;N=Ze(L,F,8)|0;C=z;E=yf(L|0,F|0,7)|0;C=z^G^C;M=fg(D|0,K|0,I|0,M|0)|0;C=fg(M|0,z|0,E^H^N|0,C|0)|0;N=z;c[d+(q+16<<3)>>2]=C;c[d+(q+16<<3)+4>>2]=N;H=Ze(O,J,19)|0;E=z;M=Ze(O,J,61)|0;I=z;J=yf(O|0,J|0,6)|0;I=fg(J^H^M|0,z^E^I|0,c[d+(r+9<<3)>>2]|0,c[d+(r+9<<3)+4>>2]|0)|0;E=z;M=c[d+(r+1<<3)>>2]|0;H=c[d+(r+1<<3)+4>>2]|0;J=Ze(M,H,1)|0;O=z;K=Ze(M,H,8)|0;D=z;G=yf(M|0,H|0,7)|0;D=z^O^D;F=fg(I|0,E|0,L|0,F|0)|0;D=fg(F|0,z|0,G^J^K|0,D|0)|0;K=z;c[d+(r+16<<3)>>2]=D;c[d+(r+16<<3)+4>>2]=K;J=Ze(C,N,19)|0;G=z;F=Ze(C,N,61)|0;L=z;N=yf(C|0,N|0,6)|0;L=fg(N^J^F|0,z^G^L|0,c[d+(b+9<<3)>>2]|0,c[d+(b+9<<3)+4>>2]|0)|0;G=z;F=c[d+(f<<3)>>2]|0;J=c[d+(f<<3)+4>>2]|0;N=Ze(F,J,1)|0;C=z;E=Ze(F,J,8)|0;I=z;O=yf(F|0,J|0,7)|0;I=z^C^I;H=fg(L|0,G|0,M|0,H|0)|0;I=fg(H|0,z|0,O^N^E|0,I|0)|0;E=z;c[d+(b+16<<3)>>2]=I;c[d+(b+16<<3)+4>>2]=E;N=Ze(D,K,19)|0;b=z;O=Ze(D,K,61)|0;H=z;K=yf(D|0,K|0,6)|0;H=fg(K^N^O|0,z^b^H|0,c[d+(f+9<<3)>>2]|0,c[d+(f+9<<3)+4>>2]|0)|0;b=z;O=c[d+(f+1<<3)>>2]|0;N=c[d+(f+1<<3)+4>>2]|0;K=Ze(O,N,1)|0;D=z;M=Ze(O,N,8)|0;G=z;L=yf(O|0,N|0,7)|0;G=z^D^G;J=fg(H|0,b|0,F|0,J|0)|0;G=fg(J|0,z|0,L^K^M|0,G|0)|0;M=z;c[d+(f+16<<3)>>2]=G;c[d+(f+16<<3)+4>>2]=M;K=Ze(I,E,19)|0;L=z;J=Ze(I,E,61)|0;F=z;b=yf(I|0,E|0,6)|0;F=fg(b^K^J|0,z^L^F|0,c[d+(g+9<<3)>>2]|0,c[d+(g+9<<3)+4>>2]|0)|0;L=z;J=c[d+(t<<3)>>2]|0;K=c[d+(t<<3)+4>>2]|0;b=Ze(J,K,1)|0;E=z;I=Ze(J,K,8)|0;f=z;H=yf(J|0,K|0,7)|0;f=z^E^f;N=fg(F|0,L|0,O|0,N|0)|0;f=fg(N|0,z|0,H^b^I|0,f|0)|0;c[d+(g+16<<3)>>2]=f;c[d+(g+16<<3)+4>>2]=z;f=Ze(G,M,19)|0;I=z;b=Ze(G,M,61)|0;H=z;M=yf(G|0,M|0,6)|0;H=fg(M^f^b|0,z^I^H|0,c[d+(t+9<<3)>>2]|0,c[d+(t+9<<3)+4>>2]|0)|0;I=z;b=c[d+(t+1<<3)>>2]|0;f=c[d+(t+1<<3)+4>>2]|0;M=Ze(b,f,1)|0;G=z;N=Ze(b,f,8)|0;O=z;L=yf(b|0,f|0,7)|0;O=z^G^O;K=fg(H|0,I|0,J|0,K|0)|0;O=fg(K|0,z|0,L^M^N|0,O|0)|0;c[d+(t+16<<3)>>2]=O;c[d+(t+16<<3)+4>>2]=z;if((s|0)>=80){b=0;break}}do{N=e+(b<<3)|0;O=a+(b<<3)|0;N=fg(c[O>>2]|0,c[O+4>>2]|0,c[N>>2]|0,c[N+4>>2]|0)|0;c[O>>2]=N;c[O+4>>2]=z;b=b+1|0}while((b|0)!=8);return}function ka(b){b=b|0;var c=0,d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0;R=df(a[b>>0]|0,a[b+1>>0]|0,a[b+2>>0]|0)|0;d=Qd(b+2|0)|0;d=yf(d|0,z|0,5)|0;S=df(a[b+5>>0]|0,a[b+6>>0]|0,a[b+7>>0]|0)|0;S=yf(S|0,z|0,2)|0;V=Qd(b+7|0)|0;V=yf(V|0,z|0,7)|0;w=Qd(b+10|0)|0;w=yf(w|0,z|0,4)|0;X=df(a[b+13>>0]|0,a[b+14>>0]|0,a[b+15>>0]|0)|0;X=yf(X|0,z|0,1)|0;Q=Qd(b+15|0)|0;Q=yf(Q|0,z|0,6)|0;fa=df(a[b+18>>0]|0,a[b+19>>0]|0,a[b+20>>0]|0)|0;fa=yf(fa|0,z|0,3)|0;ma=df(a[b+21>>0]|0,a[b+22>>0]|0,a[b+23>>0]|0)|0;ca=Qd(b+23|0)|0;ca=yf(ca|0,z|0,5)|0;la=df(a[b+26>>0]|0,a[b+27>>0]|0,a[b+28>>0]|0)|0;la=yf(la|0,z|0,2)|0;t=Qd(b+28|0)|0;t=yf(t|0,z|0,7)|0;qa=Qd(b+31|0)|0;qa=yf(qa|0,z|0,4)|0;u=df(a[b+34>>0]|0,a[b+35>>0]|0,a[b+36>>0]|0)|0;u=yf(u|0,z|0,1)|0;A=Qd(b+36|0)|0;A=yf(A|0,z|0,6)|0;o=df(a[b+39>>0]|0,a[b+40>>0]|0,a[b+41>>0]|0)|0;o=yf(o|0,z|0,3)|0;Z=df(a[b+42>>0]|0,a[b+43>>0]|0,a[b+44>>0]|0)|0;O=Qd(b+44|0)|0;O=yf(O|0,z|0,5)|0;$=df(a[b+47>>0]|0,a[b+48>>0]|0,a[b+49>>0]|0)|0;$=yf($|0,z|0,2)|0;ra=Qd(b+49|0)|0;ra=yf(ra|0,z|0,7)|0;v=Qd(b+52|0)|0;v=yf(v|0,z|0,4)|0;s=df(a[b+55>>0]|0,a[b+56>>0]|0,a[b+57>>0]|0)|0;s=yf(s|0,z|0,1)|0;g=Qd(b+57|0)|0;g=yf(g|0,z|0,6)|0;H=Qd(b+60|0)|0;H=yf(H|0,z|0,3)|0;c=z;h=af(H|0,c|0,666643,0)|0;e=z;ha=af(H|0,c|0,470296,0)|0;k=z;P=af(H|0,c|0,654183,0)|0;l=z;F=af(H|0,c|0,-997805,-1)|0;K=z;j=af(H|0,c|0,136657,0)|0;o=fg(j|0,z|0,o&2097151|0,0)|0;j=z;c=af(H|0,c|0,-683901,-1)|0;Z=fg(c|0,z|0,Z&2097151|0,0)|0;c=z;H=af(g&2097151|0,0,666643,0)|0;C=z;r=af(g&2097151|0,0,470296,0)|0;D=z;f=af(g&2097151|0,0,654183,0)|0;n=z;B=af(g&2097151|0,0,-997805,-1)|0;I=z;Y=af(g&2097151|0,0,136657,0)|0;G=z;g=af(g&2097151|0,0,-683901,-1)|0;g=fg(o|0,j|0,g|0,z|0)|0;j=z;o=af(s&2097151|0,0,666643,0)|0;m=z;J=af(s&2097151|0,0,470296,0)|0;x=z;y=af(s&2097151|0,0,654183,0)|0;U=z;na=af(s&2097151|0,0,-997805,-1)|0;ga=z;p=af(s&2097151|0,0,136657,0)|0;_=z;s=af(s&2097151|0,0,-683901,-1)|0;A=fg(s|0,z|0,A&2097151|0,0)|0;K=fg(A|0,z|0,F|0,K|0)|0;G=fg(K|0,z|0,Y|0,G|0)|0;Y=z;K=af(v&2097151|0,0,666643,0)|0;F=z;A=af(v&2097151|0,0,470296,0)|0;s=z;ia=af(v&2097151|0,0,654183,0)|0;i=z;N=af(v&2097151|0,0,-997805,-1)|0;q=z;pa=af(v&2097151|0,0,136657,0)|0;oa=z;v=af(v&2097151|0,0,-683901,-1)|0;W=z;E=af(ra&2097151|0,0,666643,0)|0;T=z;da=af(ra&2097151|0,0,470296,0)|0;ea=z;ba=af(ra&2097151|0,0,654183,0)|0;aa=z;ka=af(ra&2097151|0,0,-997805,-1)|0;ja=z;L=af(ra&2097151|0,0,136657,0)|0;M=z;ra=af(ra&2097151|0,0,-683901,-1)|0;qa=fg(ra|0,z|0,qa&2097151|0,0)|0;oa=fg(qa|0,z|0,pa|0,oa|0)|0;ga=fg(oa|0,z|0,na|0,ga|0)|0;k=fg(ga|0,z|0,ha|0,k|0)|0;n=fg(k|0,z|0,f|0,n|0)|0;f=z;k=af($&2097151|0,0,666643,0)|0;Q=fg(k|0,z|0,Q&2097151|0,0)|0;k=z;ha=af($&2097151|0,0,470296,0)|0;ga=z;na=af($&2097151|0,0,654183,0)|0;ma=fg(na|0,z|0,ma&2097151|0,0)|0;ea=fg(ma|0,z|0,da|0,ea|0)|0;F=fg(ea|0,z|0,K|0,F|0)|0;K=z;ea=af($&2097151|0,0,-997805,-1)|0;da=z;ma=af($&2097151|0,0,136657,0)|0;la=fg(ma|0,z|0,la&2097151|0,0)|0;ja=fg(la|0,z|0,ka|0,ja|0)|0;i=fg(ja|0,z|0,ia|0,i|0)|0;x=fg(i|0,z|0,J|0,x|0)|0;C=fg(x|0,z|0,H|0,C|0)|0;H=z;$=af($&2097151|0,0,-683901,-1)|0;x=z;J=fg(Q|0,k|0,1048576,0)|0;J=yf(J|0,z|0,21)|0;i=z;fa=fg(ha|0,ga|0,fa&2097151|0,0)|0;T=fg(fa|0,z|0,E|0,T|0)|0;T=fg(T|0,z|0,J|0,i|0)|0;E=z;i=vf(J|0,i|0,21)|0;i=cg(Q|0,k|0,i|0,z|0)|0;k=z;Q=fg(F|0,K|0,1048576,0)|0;Q=yf(Q|0,z|0,21)|0;J=z;ca=fg(ea|0,da|0,ca&2097151|0,0)|0;aa=fg(ca|0,z|0,ba|0,aa|0)|0;s=fg(aa|0,z|0,A|0,s|0)|0;m=fg(s|0,z|0,o|0,m|0)|0;m=fg(m|0,z|0,Q|0,J|0)|0;o=z;J=vf(Q|0,J|0,21)|0;Q=z;s=fg(C|0,H|0,1048576,0)|0;s=Xe(s|0,z|0,21)|0;A=z;t=fg($|0,x|0,t&2097151|0,0)|0;M=fg(t|0,z|0,L|0,M|0)|0;q=fg(M|0,z|0,N|0,q|0)|0;U=fg(q|0,z|0,y|0,U|0)|0;e=fg(U|0,z|0,h|0,e|0)|0;D=fg(e|0,z|0,r|0,D|0)|0;D=fg(D|0,z|0,s|0,A|0)|0;r=z;A=vf(s|0,A|0,21)|0;s=z;e=fg(n|0,f|0,1048576,0)|0;e=Xe(e|0,z|0,21)|0;h=z;u=fg(v|0,W|0,u&2097151|0,0)|0;_=fg(u|0,z|0,p|0,_|0)|0;l=fg(_|0,z|0,P|0,l|0)|0;I=fg(l|0,z|0,B|0,I|0)|0;I=fg(I|0,z|0,e|0,h|0)|0;B=z;h=vf(e|0,h|0,21)|0;h=cg(n|0,f|0,h|0,z|0)|0;f=z;n=fg(G|0,Y|0,1048576,0)|0;n=Xe(n|0,z|0,21)|0;e=z;j=fg(g|0,j|0,n|0,e|0)|0;g=z;e=vf(n|0,e|0,21)|0;e=cg(G|0,Y|0,e|0,z|0)|0;Y=z;G=fg(Z|0,c|0,1048576,0)|0;G=Xe(G|0,z|0,21)|0;n=z;O=fg(G|0,n|0,O&2097151|0,0)|0;l=z;n=vf(G|0,n|0,21)|0;n=cg(Z|0,c|0,n|0,z|0)|0;c=z;Z=fg(T|0,E|0,1048576,0)|0;Z=yf(Z|0,z|0,21)|0;G=z;P=vf(Z|0,G|0,21)|0;P=cg(T|0,E|0,P|0,z|0)|0;E=z;T=fg(m|0,o|0,1048576,0)|0;T=Xe(T|0,z|0,21)|0;_=z;p=vf(T|0,_|0,21)|0;u=z;W=fg(D|0,r|0,1048576,0)|0;W=Xe(W|0,z|0,21)|0;v=z;f=fg(W|0,v|0,h|0,f|0)|0;h=z;v=vf(W|0,v|0,21)|0;v=cg(D|0,r|0,v|0,z|0)|0;r=z;D=fg(I|0,B|0,1048576,0)|0;D=Xe(D|0,z|0,21)|0;W=z;Y=fg(D|0,W|0,e|0,Y|0)|0;e=z;W=vf(D|0,W|0,21)|0;W=cg(I|0,B|0,W|0,z|0)|0;B=z;I=fg(j|0,g|0,1048576,0)|0;I=Xe(I|0,z|0,21)|0;D=z;c=fg(I|0,D|0,n|0,c|0)|0;n=z;D=vf(I|0,D|0,21)|0;D=cg(j|0,g|0,D|0,z|0)|0;g=z;j=af(O|0,l|0,666643,0)|0;X=fg(j|0,z|0,X&2097151|0,0)|0;j=z;I=af(O|0,l|0,470296,0)|0;I=fg(i|0,k|0,I|0,z|0)|0;k=z;i=af(O|0,l|0,654183,0)|0;i=fg(P|0,E|0,i|0,z|0)|0;E=z;P=af(O|0,l|0,-997805,-1)|0;U=z;y=af(O|0,l|0,136657,0)|0;q=z;l=af(O|0,l|0,-683901,-1)|0;H=fg(l|0,z|0,C|0,H|0)|0;_=fg(H|0,z|0,T|0,_|0)|0;s=cg(_|0,z|0,A|0,s|0)|0;A=z;_=af(c|0,n|0,666643,0)|0;w=fg(_|0,z|0,w&2097151|0,0)|0;_=z;T=af(c|0,n|0,470296,0)|0;T=fg(X|0,j|0,T|0,z|0)|0;j=z;X=af(c|0,n|0,654183,0)|0;X=fg(I|0,k|0,X|0,z|0)|0;k=z;I=af(c|0,n|0,-997805,-1)|0;I=fg(i|0,E|0,I|0,z|0)|0;E=z;i=af(c|0,n|0,136657,0)|0;H=z;n=af(c|0,n|0,-683901,-1)|0;c=z;C=af(D|0,g|0,666643,0)|0;V=fg(C|0,z|0,V&2097151|0,0)|0;C=z;l=af(D|0,g|0,470296,0)|0;l=fg(w|0,_|0,l|0,z|0)|0;_=z;w=af(D|0,g|0,654183,0)|0;w=fg(T|0,j|0,w|0,z|0)|0;j=z;T=af(D|0,g|0,-997805,-1)|0;T=fg(X|0,k|0,T|0,z|0)|0;k=z;X=af(D|0,g|0,136657,0)|0;X=fg(I|0,E|0,X|0,z|0)|0;E=z;g=af(D|0,g|0,-683901,-1)|0;D=z;K=fg(Z|0,G|0,F|0,K|0)|0;Q=cg(K|0,z|0,J|0,Q|0)|0;U=fg(Q|0,z|0,P|0,U|0)|0;H=fg(U|0,z|0,i|0,H|0)|0;D=fg(H|0,z|0,g|0,D|0)|0;g=z;H=af(Y|0,e|0,666643,0)|0;S=fg(H|0,z|0,S&2097151|0,0)|0;H=z;i=af(Y|0,e|0,470296,0)|0;i=fg(V|0,C|0,i|0,z|0)|0;C=z;V=af(Y|0,e|0,654183,0)|0;V=fg(l|0,_|0,V|0,z|0)|0;_=z;l=af(Y|0,e|0,-997805,-1)|0;l=fg(w|0,j|0,l|0,z|0)|0;j=z;w=af(Y|0,e|0,136657,0)|0;w=fg(T|0,k|0,w|0,z|0)|0;k=z;e=af(Y|0,e|0,-683901,-1)|0;e=fg(X|0,E|0,e|0,z|0)|0;E=z;X=af(W|0,B|0,666643,0)|0;Y=z;T=af(W|0,B|0,470296,0)|0;U=z;P=af(W|0,B|0,654183,0)|0;Q=z;J=af(W|0,B|0,-997805,-1)|0;K=z;F=af(W|0,B|0,136657,0)|0;G=z;B=af(W|0,B|0,-683901,-1)|0;B=fg(w|0,k|0,B|0,z|0)|0;k=z;w=af(f|0,h|0,666643,0)|0;R=fg(w|0,z|0,R&2097151|0,0)|0;w=z;W=af(f|0,h|0,470296,0)|0;Z=z;I=af(f|0,h|0,654183,0)|0;I=fg(S|0,H|0,I|0,z|0)|0;U=fg(I|0,z|0,T|0,U|0)|0;T=z;I=af(f|0,h|0,-997805,-1)|0;H=z;S=af(f|0,h|0,136657,0)|0;S=fg(V|0,_|0,S|0,z|0)|0;K=fg(S|0,z|0,J|0,K|0)|0;J=z;h=af(f|0,h|0,-683901,-1)|0;f=z;S=fg(R|0,w|0,1048576,0)|0;S=Xe(S|0,z|0,21)|0;_=z;d=fg(W|0,Z|0,d&2097151|0,0)|0;Y=fg(d|0,z|0,X|0,Y|0)|0;Y=fg(Y|0,z|0,S|0,_|0)|0;X=z;_=vf(S|0,_|0,21)|0;_=cg(R|0,w|0,_|0,z|0)|0;w=z;R=fg(U|0,T|0,1048576,0)|0;R=Xe(R|0,z|0,21)|0;S=z;H=fg(i|0,C|0,I|0,H|0)|0;Q=fg(H|0,z|0,P|0,Q|0)|0;Q=fg(Q|0,z|0,R|0,S|0)|0;P=z;S=vf(R|0,S|0,21)|0;R=z;H=fg(K|0,J|0,1048576,0)|0;H=Xe(H|0,z|0,21)|0;I=z;f=fg(l|0,j|0,h|0,f|0)|0;G=fg(f|0,z|0,F|0,G|0)|0;G=fg(G|0,z|0,H|0,I|0)|0;F=z;I=vf(H|0,I|0,21)|0;H=z;f=fg(B|0,k|0,1048576,0)|0;f=Xe(f|0,z|0,21)|0;h=z;E=fg(e|0,E|0,f|0,h|0)|0;e=z;h=vf(f|0,h|0,21)|0;h=cg(B|0,k|0,h|0,z|0)|0;k=z;B=fg(D|0,g|0,1048576,0)|0;B=Xe(B|0,z|0,21)|0;f=z;o=fg(y|0,q|0,m|0,o|0)|0;u=cg(o|0,z|0,p|0,u|0)|0;c=fg(u|0,z|0,n|0,c|0)|0;c=fg(c|0,z|0,B|0,f|0)|0;n=z;f=vf(B|0,f|0,21)|0;f=cg(D|0,g|0,f|0,z|0)|0;g=z;D=fg(s|0,A|0,1048576,0)|0;D=Xe(D|0,z|0,21)|0;B=z;r=fg(D|0,B|0,v|0,r|0)|0;v=z;B=vf(D|0,B|0,21)|0;B=cg(s|0,A|0,B|0,z|0)|0;A=z;s=fg(Y|0,X|0,1048576,0)|0;s=Xe(s|0,z|0,21)|0;D=z;u=vf(s|0,D|0,21)|0;p=z;o=fg(Q|0,P|0,1048576,0)|0;o=Xe(o|0,z|0,21)|0;m=z;q=vf(o|0,m|0,21)|0;y=z;j=fg(G|0,F|0,1048576,0)|0;j=Xe(j|0,z|0,21)|0;l=z;k=fg(h|0,k|0,j|0,l|0)|0;h=z;l=vf(j|0,l|0,21)|0;j=z;C=fg(E|0,e|0,1048576,0)|0;C=Xe(C|0,z|0,21)|0;i=z;g=fg(f|0,g|0,C|0,i|0)|0;f=z;i=vf(C|0,i|0,21)|0;i=cg(E|0,e|0,i|0,z|0)|0;e=z;E=fg(c|0,n|0,1048576,0)|0;E=Xe(E|0,z|0,21)|0;C=z;A=fg(B|0,A|0,E|0,C|0)|0;B=z;C=vf(E|0,C|0,21)|0;C=cg(c|0,n|0,C|0,z|0)|0;n=z;c=fg(r|0,v|0,1048576,0)|0;c=Xe(c|0,z|0,21)|0;E=z;d=vf(c|0,E|0,21)|0;d=cg(r|0,v|0,d|0,z|0)|0;v=z;r=af(c|0,E|0,666643,0)|0;r=fg(_|0,w|0,r|0,z|0)|0;w=z;_=af(c|0,E|0,470296,0)|0;Z=z;W=af(c|0,E|0,654183,0)|0;V=z;O=af(c|0,E|0,-997805,-1)|0;N=z;M=af(c|0,E|0,136657,0)|0;L=z;E=af(c|0,E|0,-683901,-1)|0;c=z;t=Xe(r|0,w|0,21)|0;x=z;X=fg(_|0,Z|0,Y|0,X|0)|0;p=cg(X|0,z|0,u|0,p|0)|0;p=fg(p|0,z|0,t|0,x|0)|0;u=z;x=vf(t|0,x|0,21)|0;x=cg(r|0,w|0,x|0,z|0)|0;w=z;r=Xe(p|0,u|0,21)|0;t=z;T=fg(W|0,V|0,U|0,T|0)|0;R=cg(T|0,z|0,S|0,R|0)|0;D=fg(R|0,z|0,s|0,D|0)|0;D=fg(D|0,z|0,r|0,t|0)|0;s=z;t=vf(r|0,t|0,21)|0;t=cg(p|0,u|0,t|0,z|0)|0;u=z;p=Xe(D|0,s|0,21)|0;r=z;N=fg(Q|0,P|0,O|0,N|0)|0;y=cg(N|0,z|0,q|0,y|0)|0;y=fg(y|0,z|0,p|0,r|0)|0;q=z;r=vf(p|0,r|0,21)|0;r=cg(D|0,s|0,r|0,z|0)|0;s=z;D=Xe(y|0,q|0,21)|0;p=z;J=fg(M|0,L|0,K|0,J|0)|0;H=cg(J|0,z|0,I|0,H|0)|0;m=fg(H|0,z|0,o|0,m|0)|0;m=fg(m|0,z|0,D|0,p|0)|0;o=z;p=vf(D|0,p|0,21)|0;p=cg(y|0,q|0,p|0,z|0)|0;q=z;y=Xe(m|0,o|0,21)|0;D=z;c=fg(G|0,F|0,E|0,c|0)|0;j=cg(c|0,z|0,l|0,j|0)|0;j=fg(j|0,z|0,y|0,D|0)|0;l=z;D=vf(y|0,D|0,21)|0;D=cg(m|0,o|0,D|0,z|0)|0;o=z;m=Xe(j|0,l|0,21)|0;y=z;h=fg(k|0,h|0,m|0,y|0)|0;k=z;y=vf(m|0,y|0,21)|0;y=cg(j|0,l|0,y|0,z|0)|0;l=z;j=Xe(h|0,k|0,21)|0;m=z;e=fg(j|0,m|0,i|0,e|0)|0;i=z;m=vf(j|0,m|0,21)|0;m=cg(h|0,k|0,m|0,z|0)|0;k=z;h=Xe(e|0,i|0,21)|0;j=z;f=fg(g|0,f|0,h|0,j|0)|0;g=z;j=vf(h|0,j|0,21)|0;j=cg(e|0,i|0,j|0,z|0)|0;i=z;e=Xe(f|0,g|0,21)|0;h=z;n=fg(e|0,h|0,C|0,n|0)|0;C=z;h=vf(e|0,h|0,21)|0;h=cg(f|0,g|0,h|0,z|0)|0;g=z;f=Xe(n|0,C|0,21)|0;e=z;B=fg(A|0,B|0,f|0,e|0)|0;A=z;e=vf(f|0,e|0,21)|0;e=cg(n|0,C|0,e|0,z|0)|0;C=z;n=Xe(B|0,A|0,21)|0;f=z;v=fg(n|0,f|0,d|0,v|0)|0;d=z;f=vf(n|0,f|0,21)|0;f=cg(B|0,A|0,f|0,z|0)|0;A=z;B=Xe(v|0,d|0,21)|0;n=z;c=vf(B|0,n|0,21)|0;c=cg(v|0,d|0,c|0,z|0)|0;d=z;v=af(B|0,n|0,666643,0)|0;w=fg(v|0,z|0,x|0,w|0)|0;x=z;v=af(B|0,n|0,470296,0)|0;v=fg(t|0,u|0,v|0,z|0)|0;u=z;t=af(B|0,n|0,654183,0)|0;t=fg(r|0,s|0,t|0,z|0)|0;s=z;r=af(B|0,n|0,-997805,-1)|0;r=fg(p|0,q|0,r|0,z|0)|0;q=z;p=af(B|0,n|0,136657,0)|0;p=fg(D|0,o|0,p|0,z|0)|0;o=z;n=af(B|0,n|0,-683901,-1)|0;n=fg(y|0,l|0,n|0,z|0)|0;l=z;y=Xe(w|0,x|0,21)|0;B=z;u=fg(v|0,u|0,y|0,B|0)|0;v=z;B=vf(y|0,B|0,21)|0;B=cg(w|0,x|0,B|0,z|0)|0;x=z;w=Xe(u|0,v|0,21)|0;y=z;s=fg(t|0,s|0,w|0,y|0)|0;t=z;y=vf(w|0,y|0,21)|0;y=cg(u|0,v|0,y|0,z|0)|0;v=z;u=Xe(s|0,t|0,21)|0;w=z;q=fg(r|0,q|0,u|0,w|0)|0;r=z;w=vf(u|0,w|0,21)|0;w=cg(s|0,t|0,w|0,z|0)|0;t=z;s=Xe(q|0,r|0,21)|0;u=z;o=fg(p|0,o|0,s|0,u|0)|0;p=z;u=vf(s|0,u|0,21)|0;u=cg(q|0,r|0,u|0,z|0)|0;r=z;q=Xe(o|0,p|0,21)|0;s=z;l=fg(n|0,l|0,q|0,s|0)|0;n=z;s=vf(q|0,s|0,21)|0;s=cg(o|0,p|0,s|0,z|0)|0;p=z;o=Xe(l|0,n|0,21)|0;q=z;k=fg(o|0,q|0,m|0,k|0)|0;m=z;q=vf(o|0,q|0,21)|0;q=cg(l|0,n|0,q|0,z|0)|0;n=z;l=Xe(k|0,m|0,21)|0;o=z;i=fg(l|0,o|0,j|0,i|0)|0;j=z;o=vf(l|0,o|0,21)|0;o=cg(k|0,m|0,o|0,z|0)|0;m=z;k=Xe(i|0,j|0,21)|0;l=z;g=fg(k|0,l|0,h|0,g|0)|0;h=z;l=vf(k|0,l|0,21)|0;l=cg(i|0,j|0,l|0,z|0)|0;j=z;i=Xe(g|0,h|0,21)|0;k=z;C=fg(i|0,k|0,e|0,C|0)|0;e=z;k=vf(i|0,k|0,21)|0;k=cg(g|0,h|0,k|0,z|0)|0;h=z;g=Xe(C|0,e|0,21)|0;i=z;A=fg(g|0,i|0,f|0,A|0)|0;f=z;i=vf(g|0,i|0,21)|0;i=cg(C|0,e|0,i|0,z|0)|0;e=z;C=Xe(A|0,f|0,21)|0;g=z;d=fg(C|0,g|0,c|0,d|0)|0;c=z;g=vf(C|0,g|0,21)|0;g=cg(A|0,f|0,g|0,z|0)|0;f=z;a[b>>0]=B;A=yf(B|0,x|0,8)|0;a[b+1>>0]=A;x=yf(B|0,x|0,16)|0;B=z;A=vf(y|0,v|0,5)|0;a[b+2>>0]=A|x;x=yf(y|0,v|0,3)|0;a[b+3>>0]=x;x=yf(y|0,v|0,11)|0;a[b+4>>0]=x;v=yf(y|0,v|0,19)|0;y=z;x=vf(w|0,t|0,2)|0;a[b+5>>0]=x|v;v=yf(w|0,t|0,6)|0;a[b+6>>0]=v;t=yf(w|0,t|0,14)|0;w=z;v=vf(u|0,r|0,7)|0;a[b+7>>0]=v|t;t=yf(u|0,r|0,1)|0;a[b+8>>0]=t;t=yf(u|0,r|0,9)|0;a[b+9>>0]=t;r=yf(u|0,r|0,17)|0;u=z;t=vf(s|0,p|0,4)|0;a[b+10>>0]=t|r;r=yf(s|0,p|0,4)|0;a[b+11>>0]=r;r=yf(s|0,p|0,12)|0;a[b+12>>0]=r;p=yf(s|0,p|0,20)|0;s=z;r=vf(q|0,n|0,1)|0;a[b+13>>0]=r|p;p=yf(q|0,n|0,7)|0;a[b+14>>0]=p;n=yf(q|0,n|0,15)|0;q=z;p=vf(o|0,m|0,6)|0;a[b+15>>0]=p|n;n=yf(o|0,m|0,2)|0;a[b+16>>0]=n;n=yf(o|0,m|0,10)|0;a[b+17>>0]=n;m=yf(o|0,m|0,18)|0;o=z;n=vf(l|0,j|0,3)|0;a[b+18>>0]=n|m;m=yf(l|0,j|0,5)|0;a[b+19>>0]=m;j=yf(l|0,j|0,13)|0;a[b+20>>0]=j;a[b+21>>0]=k;j=yf(k|0,h|0,8)|0;a[b+22>>0]=j;h=yf(k|0,h|0,16)|0;k=z;j=vf(i|0,e|0,5)|0;a[b+23>>0]=j|h;h=yf(i|0,e|0,3)|0;a[b+24>>0]=h;h=yf(i|0,e|0,11)|0;a[b+25>>0]=h;e=yf(i|0,e|0,19)|0;i=z;h=vf(g|0,f|0,2)|0;a[b+26>>0]=h|e;e=yf(g|0,f|0,6)|0;a[b+27>>0]=e;f=yf(g|0,f|0,14)|0;g=z;e=vf(d|0,c|0,7)|0;a[b+28>>0]=f|e;e=yf(d|0,c|0,1)|0;a[b+29>>0]=e;e=yf(d|0,c|0,9)|0;a[b+30>>0]=e;c=yf(d|0,c|0,17)|0;a[b+31>>0]=c;return}function la(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0,sa=0,ta=0,ua=0,va=0,wa=0,xa=0,ya=0,za=0,Aa=0,Ba=0,Ca=0,Da=0,Ea=0,Fa=0,Ga=0,Ha=0,Ia=0,Ja=0,Ka=0,La=0,Ma=0,Na=0,Oa=0,Pa=0,Qa=0,Ra=0,Sa=0,Ta=0,Ua=0,Va=0,Wa=0,Xa=0,Ya=0,Za=0,_a=0,$a=0,ab=0,bb=0,cb=0,db=0,eb=0,fb=0,gb=0,hb=0,ib=0,jb=0,kb=0,lb=0,mb=0,nb=0,ob=0,pb=0,qb=0,rb=0,sb=0,tb=0,ub=0,vb=0,wb=0,xb=0,yb=0,zb=0,Ab=0,Bb=0,Cb=0,Db=0,Eb=0,Fb=0,Gb=0,Hb=0,Ib=0,Jb=0,Kb=0,Lb=0,Mb=0,Nb=0,Ob=0,Pb=0,Qb=0,Rb=0,Sb=0,Tb=0,Ub=0,Vb=0,Wb=0,Xb=0,Yb=0,Zb=0,_b=0,$b=0,ac=0,bc=0,cc=0,dc=0,ec=0,fc=0,gc=0,hc=0,ic=0,jc=0,kc=0,lc=0,mc=0,nc=0,oc=0,pc=0,qc=0,rc=0,sc=0,tc=0,uc=0,vc=0,wc=0,xc=0,yc=0,zc=0,Ac=0,Bc=0,Cc=0,Dc=0,Ec=0,Fc=0,Gc=0,Hc=0,Ic=0,Jc=0,Kc=0,Lc=0,Mc=0,Nc=0,Oc=0,Pc=0;o=c[b>>2]|0;n=c[b+4>>2]|0;k=c[b+8>>2]|0;fa=c[b+12>>2]|0;N=c[b+16>>2]|0;M=c[b+20>>2]|0;g=c[b+24>>2]|0;ea=c[b+28>>2]|0;L=c[b+32>>2]|0;q=c[b+36>>2]|0;I=c[d>>2]|0;Oc=c[d+4>>2]|0;cc=c[d+8>>2]|0;sb=c[d+12>>2]|0;Ia=c[d+16>>2]|0;jc=c[d+20>>2]|0;Db=c[d+24>>2]|0;Ta=c[d+28>>2]|0;ga=c[d+32>>2]|0;Pc=c[d+36>>2]|0;Mc=af(I|0,((I|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;Lc=z;wc=af(Oc|0,((Oc|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;vc=z;ub=af(cc|0,((cc|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;tb=z;Ka=af(sb|0,((sb|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;Ja=z;mc=af(Ia|0,((Ia|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;lc=z;Gb=af(jc|0,((jc|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;Fb=z;Wa=af(Db|0,((Db|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;Va=z;ja=af(Ta|0,((Ta|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;ia=z;P=af(ga|0,((ga|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;O=z;o=af(Pc|0,((Pc|0)<0)<<31>>31|0,o|0,((o|0)<0)<<31>>31|0)|0;l=z;dc=af(I|0,((I|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;ec=z;yb=af(Oc|0,((Oc|0)<0)<<31>>31|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;xb=z;Ma=af(cc|0,((cc|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;La=z;oc=af(sb|0,((sb|0)<0)<<31>>31|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;nc=z;Ib=af(Ia|0,((Ia|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;Hb=z;Ya=af(jc|0,((jc|0)<0)<<31>>31|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;Xa=z;la=af(Db|0,((Db|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;ka=z;R=af(Ta|0,((Ta|0)<0)<<31>>31|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;Q=z;t=af(ga|0,((ga|0)<0)<<31>>31|0,n|0,((n|0)<0)<<31>>31|0)|0;s=z;d=((Pc*19|0)<0)<<31>>31;n=af(Pc*19|0,d|0,n<<1|0,((n<<1|0)<0)<<31>>31|0)|0;p=z;wb=af(I|0,((I|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;vb=z;Qa=af(Oc|0,((Oc|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;Pa=z;qc=af(cc|0,((cc|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;pc=z;Kb=af(sb|0,((sb|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;Jb=z;_a=af(Ia|0,((Ia|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;Za=z;na=af(jc|0,((jc|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;ma=z;T=af(Db|0,((Db|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;S=z;v=af(Ta|0,((Ta|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;u=z;ha=((ga*19|0)<0)<<31>>31;yc=af(ga*19|0,ha|0,k|0,((k|0)<0)<<31>>31|0)|0;xc=z;k=af(Pc*19|0,d|0,k|0,((k|0)<0)<<31>>31|0)|0;j=z;Oa=af(I|0,((I|0)<0)<<31>>31|0,fa|0,((fa|0)<0)<<31>>31|0)|0;Na=z;uc=af(Oc|0,((Oc|0)<0)<<31>>31|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;tc=z;Mb=af(cc|0,((cc|0)<0)<<31>>31|0,fa|0,((fa|0)<0)<<31>>31|0)|0;Lb=z;ab=af(sb|0,((sb|0)<0)<<31>>31|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;$a=z;pa=af(Ia|0,((Ia|0)<0)<<31>>31|0,fa|0,((fa|0)<0)<<31>>31|0)|0;oa=z;V=af(jc|0,((jc|0)<0)<<31>>31|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;U=z;x=af(Db|0,((Db|0)<0)<<31>>31|0,fa|0,((fa|0)<0)<<31>>31|0)|0;w=z;Ua=((Ta*19|0)<0)<<31>>31;Ac=af(Ta*19|0,Ua|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;zc=z;Sb=af(ga*19|0,ha|0,fa|0,((fa|0)<0)<<31>>31|0)|0;Rb=z;fa=af(Pc*19|0,d|0,fa<<1|0,((fa<<1|0)<0)<<31>>31|0)|0;f=z;sc=af(I|0,((I|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;rc=z;Qb=af(Oc|0,((Oc|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;Pb=z;cb=af(cc|0,((cc|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;bb=z;ra=af(sb|0,((sb|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;qa=z;X=af(Ia|0,((Ia|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;W=z;A=af(jc|0,((jc|0)<0)<<31>>31|0,N|0,((N|0)<0)<<31>>31|0)|0;y=z;Eb=((Db*19|0)<0)<<31>>31;Cc=af(Db*19|0,Eb|0,N|0,((N|0)<0)<<31>>31|0)|0;Bc=z;Ub=af(Ta*19|0,Ua|0,N|0,((N|0)<0)<<31>>31|0)|0;Tb=z;ib=af(ga*19|0,ha|0,N|0,((N|0)<0)<<31>>31|0)|0;hb=z;N=af(Pc*19|0,d|0,N|0,((N|0)<0)<<31>>31|0)|0;e=z;Ob=af(I|0,((I|0)<0)<<31>>31|0,M|0,((M|0)<0)<<31>>31|0)|0;Nb=z;gb=af(Oc|0,((Oc|0)<0)<<31>>31|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;fb=z;ta=af(cc|0,((cc|0)<0)<<31>>31|0,M|0,((M|0)<0)<<31>>31|0)|0;sa=z;Z=af(sb|0,((sb|0)<0)<<31>>31|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;Y=z;C=af(Ia|0,((Ia|0)<0)<<31>>31|0,M|0,((M|0)<0)<<31>>31|0)|0;B=z;kc=((jc*19|0)<0)<<31>>31;Ec=af(jc*19|0,kc|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;Dc=z;Wb=af(Db*19|0,Eb|0,M|0,((M|0)<0)<<31>>31|0)|0;Vb=z;kb=af(Ta*19|0,Ua|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;jb=z;Aa=af(ga*19|0,ha|0,M|0,((M|0)<0)<<31>>31|0)|0;za=z;b=af(Pc*19|0,d|0,M<<1|0,((M<<1|0)<0)<<31>>31|0)|0;M=z;eb=af(I|0,((I|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;db=z;xa=af(Oc|0,((Oc|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;wa=z;$=af(cc|0,((cc|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;_=z;E=af(sb|0,((sb|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;D=z;Gc=af(Ia*19|0,((Ia*19|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;Fc=z;Yb=af(jc*19|0,kc|0,g|0,((g|0)<0)<<31>>31|0)|0;Xb=z;mb=af(Db*19|0,Eb|0,g|0,((g|0)<0)<<31>>31|0)|0;lb=z;Ca=af(Ta*19|0,Ua|0,g|0,((g|0)<0)<<31>>31|0)|0;Ba=z;m=af(ga*19|0,ha|0,g|0,((g|0)<0)<<31>>31|0)|0;r=z;g=af(Pc*19|0,d|0,g|0,((g|0)<0)<<31>>31|0)|0;ya=z;va=af(I|0,((I|0)<0)<<31>>31|0,ea|0,((ea|0)<0)<<31>>31|0)|0;ua=z;da=af(Oc|0,((Oc|0)<0)<<31>>31|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;ca=z;G=af(cc|0,((cc|0)<0)<<31>>31|0,ea|0,((ea|0)<0)<<31>>31|0)|0;F=z;Ic=af(sb*19|0,((sb*19|0)<0)<<31>>31|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;Hc=z;_b=af(Ia*19|0,((Ia*19|0)<0)<<31>>31|0,ea|0,((ea|0)<0)<<31>>31|0)|0;Zb=z;ob=af(jc*19|0,kc|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;nb=z;Ea=af(Db*19|0,Eb|0,ea|0,((ea|0)<0)<<31>>31|0)|0;Da=z;gc=af(Ta*19|0,Ua|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;fc=z;Ab=af(ga*19|0,ha|0,ea|0,((ea|0)<0)<<31>>31|0)|0;zb=z;ea=af(Pc*19|0,d|0,ea<<1|0,((ea<<1|0)<0)<<31>>31|0)|0;i=z;ba=af(I|0,((I|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;aa=z;K=af(Oc|0,((Oc|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;J=z;Kc=af(cc*19|0,((cc*19|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;Jc=z;ac=af(sb*19|0,((sb*19|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;$b=z;qb=af(Ia*19|0,((Ia*19|0)<0)<<31>>31|0,L|0,((L|0)<0)<<31>>31|0)|0;pb=z;Ga=af(jc*19|0,kc|0,L|0,((L|0)<0)<<31>>31|0)|0;Fa=z;ic=af(Db*19|0,Eb|0,L|0,((L|0)<0)<<31>>31|0)|0;hc=z;Cb=af(Ta*19|0,Ua|0,L|0,((L|0)<0)<<31>>31|0)|0;Bb=z;Sa=af(ga*19|0,ha|0,L|0,((L|0)<0)<<31>>31|0)|0;Ra=z;L=af(Pc*19|0,d|0,L|0,((L|0)<0)<<31>>31|0)|0;h=z;I=af(I|0,((I|0)<0)<<31>>31|0,q|0,((q|0)<0)<<31>>31|0)|0;H=z;Oc=af(Oc*19|0,((Oc*19|0)<0)<<31>>31|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;Nc=z;cc=af(cc*19|0,((cc*19|0)<0)<<31>>31|0,q|0,((q|0)<0)<<31>>31|0)|0;bc=z;sb=af(sb*19|0,((sb*19|0)<0)<<31>>31|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;rb=z;Ia=af(Ia*19|0,((Ia*19|0)<0)<<31>>31|0,q|0,((q|0)<0)<<31>>31|0)|0;Ha=z;kc=af(jc*19|0,kc|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;jc=z;Eb=af(Db*19|0,Eb|0,q|0,((q|0)<0)<<31>>31|0)|0;Db=z;Ua=af(Ta*19|0,Ua|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;Ta=z;ha=af(ga*19|0,ha|0,q|0,((q|0)<0)<<31>>31|0)|0;ga=z;q=af(Pc*19|0,d|0,q<<1|0,((q<<1|0)<0)<<31>>31|0)|0;d=z;Lc=fg(Oc|0,Nc|0,Mc|0,Lc|0)|0;Jc=fg(Lc|0,z|0,Kc|0,Jc|0)|0;Hc=fg(Jc|0,z|0,Ic|0,Hc|0)|0;Fc=fg(Hc|0,z|0,Gc|0,Fc|0)|0;Dc=fg(Fc|0,z|0,Ec|0,Dc|0)|0;Bc=fg(Dc|0,z|0,Cc|0,Bc|0)|0;zc=fg(Bc|0,z|0,Ac|0,zc|0)|0;xc=fg(zc|0,z|0,yc|0,xc|0)|0;p=fg(xc|0,z|0,n|0,p|0)|0;n=z;ec=fg(wc|0,vc|0,dc|0,ec|0)|0;dc=z;rc=fg(uc|0,tc|0,sc|0,rc|0)|0;pc=fg(rc|0,z|0,qc|0,pc|0)|0;nc=fg(pc|0,z|0,oc|0,nc|0)|0;lc=fg(nc|0,z|0,mc|0,lc|0)|0;jc=fg(lc|0,z|0,kc|0,jc|0)|0;hc=fg(jc|0,z|0,ic|0,hc|0)|0;fc=fg(hc|0,z|0,gc|0,fc|0)|0;r=fg(fc|0,z|0,m|0,r|0)|0;M=fg(r|0,z|0,b|0,M|0)|0;b=z;r=fg(p|0,n|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;m=z;bc=fg(ec|0,dc|0,cc|0,bc|0)|0;$b=fg(bc|0,z|0,ac|0,$b|0)|0;Zb=fg($b|0,z|0,_b|0,Zb|0)|0;Xb=fg(Zb|0,z|0,Yb|0,Xb|0)|0;Vb=fg(Xb|0,z|0,Wb|0,Vb|0)|0;Tb=fg(Vb|0,z|0,Ub|0,Tb|0)|0;Rb=fg(Tb|0,z|0,Sb|0,Rb|0)|0;j=fg(Rb|0,z|0,k|0,j|0)|0;j=fg(j|0,z|0,r|0,m|0)|0;k=z;m=vf(r|0,m|0,26)|0;m=cg(p|0,n|0,m|0,z|0)|0;n=z;p=fg(M|0,b|0,33554432,0)|0;p=Xe(p|0,z|0,26)|0;r=z;Nb=fg(Qb|0,Pb|0,Ob|0,Nb|0)|0;Lb=fg(Nb|0,z|0,Mb|0,Lb|0)|0;Jb=fg(Lb|0,z|0,Kb|0,Jb|0)|0;Hb=fg(Jb|0,z|0,Ib|0,Hb|0)|0;Fb=fg(Hb|0,z|0,Gb|0,Fb|0)|0;Db=fg(Fb|0,z|0,Eb|0,Db|0)|0;Bb=fg(Db|0,z|0,Cb|0,Bb|0)|0;zb=fg(Bb|0,z|0,Ab|0,zb|0)|0;ya=fg(zb|0,z|0,g|0,ya|0)|0;ya=fg(ya|0,z|0,p|0,r|0)|0;g=z;r=vf(p|0,r|0,26)|0;r=cg(M|0,b|0,r|0,z|0)|0;b=z;M=fg(j|0,k|0,16777216,0)|0;M=Xe(M|0,z|0,25)|0;p=z;vb=fg(yb|0,xb|0,wb|0,vb|0)|0;tb=fg(vb|0,z|0,ub|0,tb|0)|0;rb=fg(tb|0,z|0,sb|0,rb|0)|0;pb=fg(rb|0,z|0,qb|0,pb|0)|0;nb=fg(pb|0,z|0,ob|0,nb|0)|0;lb=fg(nb|0,z|0,mb|0,lb|0)|0;jb=fg(lb|0,z|0,kb|0,jb|0)|0;hb=fg(jb|0,z|0,ib|0,hb|0)|0;f=fg(hb|0,z|0,fa|0,f|0)|0;f=fg(f|0,z|0,M|0,p|0)|0;fa=z;p=vf(M|0,p|0,25)|0;p=cg(j|0,k|0,p|0,z|0)|0;k=z;j=fg(ya|0,g|0,16777216,0)|0;j=Xe(j|0,z|0,25)|0;M=z;db=fg(gb|0,fb|0,eb|0,db|0)|0;bb=fg(db|0,z|0,cb|0,bb|0)|0;$a=fg(bb|0,z|0,ab|0,$a|0)|0;Za=fg($a|0,z|0,_a|0,Za|0)|0;Xa=fg(Za|0,z|0,Ya|0,Xa|0)|0;Va=fg(Xa|0,z|0,Wa|0,Va|0)|0;Ta=fg(Va|0,z|0,Ua|0,Ta|0)|0;Ra=fg(Ta|0,z|0,Sa|0,Ra|0)|0;i=fg(Ra|0,z|0,ea|0,i|0)|0;i=fg(i|0,z|0,j|0,M|0)|0;ea=z;M=vf(j|0,M|0,25)|0;M=cg(ya|0,g|0,M|0,z|0)|0;g=z;ya=fg(f|0,fa|0,33554432,0)|0;ya=Xe(ya|0,z|0,26)|0;j=z;Na=fg(Qa|0,Pa|0,Oa|0,Na|0)|0;La=fg(Na|0,z|0,Ma|0,La|0)|0;Ja=fg(La|0,z|0,Ka|0,Ja|0)|0;Ha=fg(Ja|0,z|0,Ia|0,Ha|0)|0;Fa=fg(Ha|0,z|0,Ga|0,Fa|0)|0;Da=fg(Fa|0,z|0,Ea|0,Da|0)|0;Ba=fg(Da|0,z|0,Ca|0,Ba|0)|0;za=fg(Ba|0,z|0,Aa|0,za|0)|0;e=fg(za|0,z|0,N|0,e|0)|0;e=fg(e|0,z|0,ya|0,j|0)|0;N=z;j=vf(ya|0,j|0,26)|0;j=cg(f|0,fa|0,j|0,z|0)|0;fa=fg(i|0,ea|0,33554432,0)|0;fa=Xe(fa|0,z|0,26)|0;f=z;ua=fg(xa|0,wa|0,va|0,ua|0)|0;sa=fg(ua|0,z|0,ta|0,sa|0)|0;qa=fg(sa|0,z|0,ra|0,qa|0)|0;oa=fg(qa|0,z|0,pa|0,oa|0)|0;ma=fg(oa|0,z|0,na|0,ma|0)|0;ka=fg(ma|0,z|0,la|0,ka|0)|0;ia=fg(ka|0,z|0,ja|0,ia|0)|0;ga=fg(ia|0,z|0,ha|0,ga|0)|0;h=fg(ga|0,z|0,L|0,h|0)|0;h=fg(h|0,z|0,fa|0,f|0)|0;L=z;f=vf(fa|0,f|0,26)|0;f=cg(i|0,ea|0,f|0,z|0)|0;ea=fg(e|0,N|0,16777216,0)|0;ea=Xe(ea|0,z|0,25)|0;i=z;b=fg(ea|0,i|0,r|0,b|0)|0;r=z;i=vf(ea|0,i|0,25)|0;i=cg(e|0,N|0,i|0,z|0)|0;N=fg(h|0,L|0,16777216,0)|0;N=Xe(N|0,z|0,25)|0;e=z;aa=fg(da|0,ca|0,ba|0,aa|0)|0;_=fg(aa|0,z|0,$|0,_|0)|0;Y=fg(_|0,z|0,Z|0,Y|0)|0;W=fg(Y|0,z|0,X|0,W|0)|0;U=fg(W|0,z|0,V|0,U|0)|0;S=fg(U|0,z|0,T|0,S|0)|0;Q=fg(S|0,z|0,R|0,Q|0)|0;O=fg(Q|0,z|0,P|0,O|0)|0;d=fg(O|0,z|0,q|0,d|0)|0;d=fg(d|0,z|0,N|0,e|0)|0;q=z;e=vf(N|0,e|0,25)|0;e=cg(h|0,L|0,e|0,z|0)|0;L=fg(b|0,r|0,33554432,0)|0;L=Xe(L|0,z|0,26)|0;h=z;g=fg(M|0,g|0,L|0,h|0)|0;h=vf(L|0,h|0,26)|0;h=cg(b|0,r|0,h|0,z|0)|0;r=fg(d|0,q|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;b=z;H=fg(K|0,J|0,I|0,H|0)|0;F=fg(H|0,z|0,G|0,F|0)|0;D=fg(F|0,z|0,E|0,D|0)|0;B=fg(D|0,z|0,C|0,B|0)|0;y=fg(B|0,z|0,A|0,y|0)|0;w=fg(y|0,z|0,x|0,w|0)|0;u=fg(w|0,z|0,v|0,u|0)|0;s=fg(u|0,z|0,t|0,s|0)|0;l=fg(s|0,z|0,o|0,l|0)|0;l=fg(l|0,z|0,r|0,b|0)|0;o=z;b=vf(r|0,b|0,26)|0;b=cg(d|0,q|0,b|0,z|0)|0;q=fg(l|0,o|0,16777216,0)|0;q=Xe(q|0,z|0,25)|0;d=z;r=af(q|0,d|0,19,0)|0;n=fg(r|0,z|0,m|0,n|0)|0;m=z;d=vf(q|0,d|0,25)|0;d=cg(l|0,o|0,d|0,z|0)|0;o=fg(n|0,m|0,33554432,0)|0;o=Xe(o|0,z|0,26)|0;l=z;k=fg(p|0,k|0,o|0,l|0)|0;l=vf(o|0,l|0,26)|0;l=cg(n|0,m|0,l|0,z|0)|0;c[a>>2]=l;c[a+4>>2]=k;c[a+8>>2]=j;c[a+12>>2]=i;c[a+16>>2]=h;c[a+20>>2]=g;c[a+24>>2]=f;c[a+28>>2]=e;c[a+32>>2]=b;c[a+36>>2]=d;return}function ma(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0;e=l;f=l=l+63&-64;l=l+2048|0;uh(f+1024|0,b);Ud(f+1024|0,a);uh(f,f+1024|0);Ud(f,d);a=0;do{b=a<<4;u=c[f+1024+((b|4)<<3)>>2]|0;x=c[f+1024+((b|4)<<3)+4>>2]|0;A=ce(c[f+1024+(b<<3)>>2]|0,c[f+1024+(b<<3)+4>>2]|0,u,x)|0;G=z;y=Ze(c[f+1024+((b|12)<<3)>>2]^A,c[f+1024+((b|12)<<3)+4>>2]^G,32)|0;t=z;D=ce(c[f+1024+((b|8)<<3)>>2]|0,c[f+1024+((b|8)<<3)+4>>2]|0,y,t)|0;q=z;x=Ze(u^D,x^q,24)|0;u=z;G=ce(A,G,x,u)|0;A=z;t=Ze(y^G,t^A,16)|0;y=z;c[f+1024+((b|12)<<3)>>2]=t;c[f+1024+((b|12)<<3)+4>>2]=y;q=ce(D,q,t,y)|0;D=z;c[f+1024+((b|8)<<3)>>2]=q;c[f+1024+((b|8)<<3)+4>>2]=D;D=Ze(x^q,u^D,63)|0;c[f+1024+((b|4)<<3)>>2]=D;c[f+1024+((b|4)<<3)+4>>2]=z;D=c[f+1024+((b|5)<<3)>>2]|0;u=c[f+1024+((b|5)<<3)+4>>2]|0;q=ce(c[f+1024+((b|1)<<3)>>2]|0,c[f+1024+((b|1)<<3)+4>>2]|0,D,u)|0;x=z;s=Ze(c[f+1024+((b|13)<<3)>>2]^q,c[f+1024+((b|13)<<3)+4>>2]^x,32)|0;m=z;B=ce(c[f+1024+((b|9)<<3)>>2]|0,c[f+1024+((b|9)<<3)+4>>2]|0,s,m)|0;p=z;u=Ze(D^B,u^p,24)|0;D=z;x=ce(q,x,u,D)|0;q=z;m=Ze(s^x,m^q,16)|0;s=z;p=ce(B,p,m,s)|0;B=z;c[f+1024+((b|9)<<3)>>2]=p;c[f+1024+((b|9)<<3)+4>>2]=B;B=Ze(u^p,D^B,63)|0;D=z;p=c[f+1024+((b|6)<<3)>>2]|0;u=c[f+1024+((b|6)<<3)+4>>2]|0;h=ce(c[f+1024+((b|2)<<3)>>2]|0,c[f+1024+((b|2)<<3)+4>>2]|0,p,u)|0;r=z;o=Ze(c[f+1024+((b|14)<<3)>>2]^h,c[f+1024+((b|14)<<3)+4>>2]^r,32)|0;i=z;F=ce(c[f+1024+((b|10)<<3)>>2]|0,c[f+1024+((b|10)<<3)+4>>2]|0,o,i)|0;E=z;u=Ze(p^F,u^E,24)|0;p=z;r=ce(h,r,u,p)|0;h=z;i=Ze(o^r,i^h,16)|0;o=z;E=ce(F,E,i,o)|0;F=z;p=Ze(u^E,p^F,63)|0;u=z;j=c[f+1024+((b|7)<<3)>>2]|0;k=c[f+1024+((b|7)<<3)+4>>2]|0;g=ce(c[f+1024+((b|3)<<3)>>2]|0,c[f+1024+((b|3)<<3)+4>>2]|0,j,k)|0;n=z;H=Ze(c[f+1024+((b|15)<<3)>>2]^g,c[f+1024+((b|15)<<3)+4>>2]^n,32)|0;C=z;w=ce(c[f+1024+((b|11)<<3)>>2]|0,c[f+1024+((b|11)<<3)+4>>2]|0,H,C)|0;v=z;k=Ze(j^w,k^v,24)|0;j=z;n=ce(g,n,k,j)|0;g=z;C=Ze(H^n,C^g,16)|0;H=z;v=ce(w,v,C,H)|0;w=z;j=Ze(k^v,j^w,63)|0;k=z;A=ce(G,A,B,D)|0;G=z;H=Ze(C^A,H^G,32)|0;C=z;F=ce(E,F,H,C)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;G=ce(A,G,D,B)|0;A=z;c[f+1024+(b<<3)>>2]=G;c[f+1024+(b<<3)+4>>2]=A;A=Ze(H^G,C^A,16)|0;C=z;c[f+1024+((b|15)<<3)>>2]=A;c[f+1024+((b|15)<<3)+4>>2]=C;C=ce(F,E,A,C)|0;A=z;c[f+1024+((b|10)<<3)>>2]=C;c[f+1024+((b|10)<<3)+4>>2]=A;A=Ze(D^C,B^A,63)|0;c[f+1024+((b|5)<<3)>>2]=A;c[f+1024+((b|5)<<3)+4>>2]=z;q=ce(x,q,p,u)|0;x=z;y=Ze(t^q,y^x,32)|0;t=z;w=ce(v,w,y,t)|0;v=z;u=Ze(p^w,u^v,24)|0;p=z;x=ce(q,x,u,p)|0;q=z;c[f+1024+((b|1)<<3)>>2]=x;c[f+1024+((b|1)<<3)+4>>2]=q;q=Ze(y^x,t^q,16)|0;t=z;c[f+1024+((b|12)<<3)>>2]=q;c[f+1024+((b|12)<<3)+4>>2]=t;t=ce(w,v,q,t)|0;q=z;c[f+1024+((b|11)<<3)>>2]=t;c[f+1024+((b|11)<<3)+4>>2]=q;q=Ze(u^t,p^q,63)|0;c[f+1024+((b|6)<<3)>>2]=q;c[f+1024+((b|6)<<3)+4>>2]=z;h=ce(r,h,j,k)|0;r=z;s=Ze(m^h,s^r,32)|0;m=z;q=ce(c[f+1024+((b|8)<<3)>>2]|0,c[f+1024+((b|8)<<3)+4>>2]|0,s,m)|0;p=z;k=Ze(j^q,k^p,24)|0;j=z;r=ce(h,r,k,j)|0;h=z;c[f+1024+((b|2)<<3)>>2]=r;c[f+1024+((b|2)<<3)+4>>2]=h;h=Ze(s^r,m^h,16)|0;m=z;c[f+1024+((b|13)<<3)>>2]=h;c[f+1024+((b|13)<<3)+4>>2]=m;m=ce(q,p,h,m)|0;h=z;c[f+1024+((b|8)<<3)>>2]=m;c[f+1024+((b|8)<<3)+4>>2]=h;h=Ze(k^m,j^h,63)|0;c[f+1024+((b|7)<<3)>>2]=h;c[f+1024+((b|7)<<3)+4>>2]=z;h=c[f+1024+((b|4)<<3)>>2]|0;j=c[f+1024+((b|4)<<3)+4>>2]|0;g=ce(n,g,h,j)|0;n=z;o=Ze(i^g,o^n,32)|0;i=z;m=ce(c[f+1024+((b|9)<<3)>>2]|0,c[f+1024+((b|9)<<3)+4>>2]|0,o,i)|0;k=z;j=Ze(h^m,j^k,24)|0;h=z;n=ce(g,n,j,h)|0;g=z;c[f+1024+((b|3)<<3)>>2]=n;c[f+1024+((b|3)<<3)+4>>2]=g;g=Ze(o^n,i^g,16)|0;i=z;c[f+1024+((b|14)<<3)>>2]=g;c[f+1024+((b|14)<<3)+4>>2]=i;i=ce(m,k,g,i)|0;g=z;c[f+1024+((b|9)<<3)>>2]=i;c[f+1024+((b|9)<<3)+4>>2]=g;g=Ze(j^i,h^g,63)|0;c[f+1024+((b|4)<<3)>>2]=g;c[f+1024+((b|4)<<3)+4>>2]=z;a=a+1|0}while((a|0)!=8);a=0;do{H=a<<1;p=f+1024+(H+32<<3)|0;s=c[p>>2]|0;p=c[p+4>>2]|0;m=ce(c[f+1024+(H<<3)>>2]|0,c[f+1024+(H<<3)+4>>2]|0,s,p)|0;g=z;o=f+1024+(H+96<<3)|0;o=Ze(c[o>>2]^m,c[o+4>>2]^g,32)|0;t=z;j=f+1024+(H+64<<3)|0;j=ce(c[j>>2]|0,c[j+4>>2]|0,o,t)|0;x=z;p=Ze(s^j,p^x,24)|0;s=z;g=ce(m,g,p,s)|0;m=z;t=Ze(o^g,t^m,16)|0;o=z;u=f+1024+(H+96<<3)|0;c[u>>2]=t;c[u+4>>2]=o;x=ce(j,x,t,o)|0;j=z;u=f+1024+(H+64<<3)|0;c[u>>2]=x;c[u+4>>2]=j;j=Ze(p^x,s^j,63)|0;s=f+1024+(H+32<<3)|0;c[s>>2]=j;c[s+4>>2]=z;s=f+1024+(H+33<<3)|0;j=c[s>>2]|0;s=c[s+4>>2]|0;x=ce(c[f+1024+((H|1)<<3)>>2]|0,c[f+1024+((H|1)<<3)+4>>2]|0,j,s)|0;p=z;u=f+1024+(H+97<<3)|0;u=Ze(c[u>>2]^x,c[u+4>>2]^p,32)|0;B=z;n=f+1024+(H+65<<3)|0;n=ce(c[n>>2]|0,c[n+4>>2]|0,u,B)|0;F=z;s=Ze(j^n,s^F,24)|0;j=z;p=ce(x,p,s,j)|0;x=z;B=Ze(u^p,B^x,16)|0;u=z;F=ce(n,F,B,u)|0;n=z;w=f+1024+(H+65<<3)|0;c[w>>2]=F;c[w+4>>2]=n;n=Ze(s^F,j^n,63)|0;j=z;F=f+1024+(H+16<<3)|0;s=f+1024+(H+48<<3)|0;w=c[s>>2]|0;s=c[s+4>>2]|0;F=ce(c[F>>2]|0,c[F+4>>2]|0,w,s)|0;v=z;y=f+1024+(H+112<<3)|0;y=Ze(c[y>>2]^F,c[y+4>>2]^v,32)|0;E=z;h=f+1024+(H+80<<3)|0;h=ce(c[h>>2]|0,c[h+4>>2]|0,y,E)|0;i=z;s=Ze(w^h,s^i,24)|0;w=z;v=ce(F,v,s,w)|0;F=z;E=Ze(y^v,E^F,16)|0;y=z;i=ce(h,i,E,y)|0;h=z;w=Ze(s^i,w^h,63)|0;s=z;G=f+1024+(H+17<<3)|0;C=f+1024+(H+49<<3)|0;D=c[C>>2]|0;C=c[C+4>>2]|0;G=ce(c[G>>2]|0,c[G+4>>2]|0,D,C)|0;A=z;b=f+1024+(H+113<<3)|0;b=Ze(c[b>>2]^G,c[b+4>>2]^A,32)|0;k=z;q=f+1024+(H+81<<3)|0;q=ce(c[q>>2]|0,c[q+4>>2]|0,b,k)|0;r=z;C=Ze(D^q,C^r,24)|0;D=z;A=ce(G,A,C,D)|0;G=z;k=Ze(b^A,k^G,16)|0;b=z;r=ce(q,r,k,b)|0;q=z;D=Ze(C^r,D^q,63)|0;C=z;m=ce(g,m,n,j)|0;g=z;b=Ze(k^m,b^g,32)|0;k=z;h=ce(i,h,b,k)|0;i=z;j=Ze(n^h,j^i,24)|0;n=z;g=ce(m,g,j,n)|0;m=z;c[f+1024+(H<<3)>>2]=g;c[f+1024+(H<<3)+4>>2]=m;m=Ze(b^g,k^m,16)|0;k=z;g=f+1024+(H+113<<3)|0;c[g>>2]=m;c[g+4>>2]=k;k=ce(h,i,m,k)|0;m=z;i=f+1024+(H+80<<3)|0;c[i>>2]=k;c[i+4>>2]=m;m=Ze(j^k,n^m,63)|0;n=f+1024+(H+33<<3)|0;c[n>>2]=m;c[n+4>>2]=z;x=ce(p,x,w,s)|0;p=z;o=Ze(t^x,o^p,32)|0;t=z;q=ce(r,q,o,t)|0;r=z;s=Ze(w^q,s^r,24)|0;w=z;p=ce(x,p,s,w)|0;x=z;c[f+1024+((H|1)<<3)>>2]=p;c[f+1024+((H|1)<<3)+4>>2]=x;x=Ze(o^p,t^x,16)|0;t=z;p=f+1024+(H+96<<3)|0;c[p>>2]=x;c[p+4>>2]=t;t=ce(q,r,x,t)|0;x=z;r=f+1024+(H+81<<3)|0;c[r>>2]=t;c[r+4>>2]=x;x=Ze(s^t,w^x,63)|0;w=f+1024+(H+48<<3)|0;c[w>>2]=x;c[w+4>>2]=z;F=ce(v,F,D,C)|0;v=z;u=Ze(B^F,u^v,32)|0;B=z;w=f+1024+(H+64<<3)|0;w=ce(c[w>>2]|0,c[w+4>>2]|0,u,B)|0;x=z;C=Ze(D^w,C^x,24)|0;D=z;v=ce(F,v,C,D)|0;F=z;t=f+1024+(H+16<<3)|0;c[t>>2]=v;c[t+4>>2]=F;F=Ze(u^v,B^F,16)|0;B=z;v=f+1024+(H+97<<3)|0;c[v>>2]=F;c[v+4>>2]=B;B=ce(w,x,F,B)|0;F=z;x=f+1024+(H+64<<3)|0;c[x>>2]=B;c[x+4>>2]=F;F=Ze(C^B,D^F,63)|0;D=f+1024+(H+49<<3)|0;c[D>>2]=F;c[D+4>>2]=z;D=f+1024+(H+32<<3)|0;F=c[D>>2]|0;D=c[D+4>>2]|0;G=ce(A,G,F,D)|0;A=z;y=Ze(E^G,y^A,32)|0;E=z;B=f+1024+(H+65<<3)|0;B=ce(c[B>>2]|0,c[B+4>>2]|0,y,E)|0;C=z;D=Ze(F^B,D^C,24)|0;F=z;A=ce(G,A,D,F)|0;G=z;x=f+1024+(H+17<<3)|0;c[x>>2]=A;c[x+4>>2]=G;G=Ze(y^A,E^G,16)|0;E=z;A=f+1024+(H+112<<3)|0;c[A>>2]=G;c[A+4>>2]=E;E=ce(B,C,G,E)|0;G=z;C=f+1024+(H+65<<3)|0;c[C>>2]=E;c[C+4>>2]=G;G=Ze(D^E,F^G,63)|0;H=f+1024+(H+32<<3)|0;c[H>>2]=G;c[H+4>>2]=z;a=a+1|0}while((a|0)!=8);uh(d,f);Ud(d,f+1024|0);l=e;return}function na(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0;e=l;f=l=l+63&-64;l=l+2048|0;uh(f+1024|0,b);Ud(f+1024|0,a);uh(f,f+1024|0);a=0;do{b=a<<4;u=c[f+1024+((b|4)<<3)>>2]|0;x=c[f+1024+((b|4)<<3)+4>>2]|0;A=ce(c[f+1024+(b<<3)>>2]|0,c[f+1024+(b<<3)+4>>2]|0,u,x)|0;G=z;y=Ze(c[f+1024+((b|12)<<3)>>2]^A,c[f+1024+((b|12)<<3)+4>>2]^G,32)|0;t=z;D=ce(c[f+1024+((b|8)<<3)>>2]|0,c[f+1024+((b|8)<<3)+4>>2]|0,y,t)|0;q=z;x=Ze(u^D,x^q,24)|0;u=z;G=ce(A,G,x,u)|0;A=z;t=Ze(y^G,t^A,16)|0;y=z;c[f+1024+((b|12)<<3)>>2]=t;c[f+1024+((b|12)<<3)+4>>2]=y;q=ce(D,q,t,y)|0;D=z;c[f+1024+((b|8)<<3)>>2]=q;c[f+1024+((b|8)<<3)+4>>2]=D;D=Ze(x^q,u^D,63)|0;c[f+1024+((b|4)<<3)>>2]=D;c[f+1024+((b|4)<<3)+4>>2]=z;D=c[f+1024+((b|5)<<3)>>2]|0;u=c[f+1024+((b|5)<<3)+4>>2]|0;q=ce(c[f+1024+((b|1)<<3)>>2]|0,c[f+1024+((b|1)<<3)+4>>2]|0,D,u)|0;x=z;s=Ze(c[f+1024+((b|13)<<3)>>2]^q,c[f+1024+((b|13)<<3)+4>>2]^x,32)|0;m=z;B=ce(c[f+1024+((b|9)<<3)>>2]|0,c[f+1024+((b|9)<<3)+4>>2]|0,s,m)|0;p=z;u=Ze(D^B,u^p,24)|0;D=z;x=ce(q,x,u,D)|0;q=z;m=Ze(s^x,m^q,16)|0;s=z;p=ce(B,p,m,s)|0;B=z;c[f+1024+((b|9)<<3)>>2]=p;c[f+1024+((b|9)<<3)+4>>2]=B;B=Ze(u^p,D^B,63)|0;D=z;p=c[f+1024+((b|6)<<3)>>2]|0;u=c[f+1024+((b|6)<<3)+4>>2]|0;h=ce(c[f+1024+((b|2)<<3)>>2]|0,c[f+1024+((b|2)<<3)+4>>2]|0,p,u)|0;r=z;o=Ze(c[f+1024+((b|14)<<3)>>2]^h,c[f+1024+((b|14)<<3)+4>>2]^r,32)|0;i=z;F=ce(c[f+1024+((b|10)<<3)>>2]|0,c[f+1024+((b|10)<<3)+4>>2]|0,o,i)|0;E=z;u=Ze(p^F,u^E,24)|0;p=z;r=ce(h,r,u,p)|0;h=z;i=Ze(o^r,i^h,16)|0;o=z;E=ce(F,E,i,o)|0;F=z;p=Ze(u^E,p^F,63)|0;u=z;j=c[f+1024+((b|7)<<3)>>2]|0;k=c[f+1024+((b|7)<<3)+4>>2]|0;g=ce(c[f+1024+((b|3)<<3)>>2]|0,c[f+1024+((b|3)<<3)+4>>2]|0,j,k)|0;n=z;H=Ze(c[f+1024+((b|15)<<3)>>2]^g,c[f+1024+((b|15)<<3)+4>>2]^n,32)|0;C=z;w=ce(c[f+1024+((b|11)<<3)>>2]|0,c[f+1024+((b|11)<<3)+4>>2]|0,H,C)|0;v=z;k=Ze(j^w,k^v,24)|0;j=z;n=ce(g,n,k,j)|0;g=z;C=Ze(H^n,C^g,16)|0;H=z;v=ce(w,v,C,H)|0;w=z;j=Ze(k^v,j^w,63)|0;k=z;A=ce(G,A,B,D)|0;G=z;H=Ze(C^A,H^G,32)|0;C=z;F=ce(E,F,H,C)|0;E=z;D=Ze(B^F,D^E,24)|0;B=z;G=ce(A,G,D,B)|0;A=z;c[f+1024+(b<<3)>>2]=G;c[f+1024+(b<<3)+4>>2]=A;A=Ze(H^G,C^A,16)|0;C=z;c[f+1024+((b|15)<<3)>>2]=A;c[f+1024+((b|15)<<3)+4>>2]=C;C=ce(F,E,A,C)|0;A=z;c[f+1024+((b|10)<<3)>>2]=C;c[f+1024+((b|10)<<3)+4>>2]=A;A=Ze(D^C,B^A,63)|0;c[f+1024+((b|5)<<3)>>2]=A;c[f+1024+((b|5)<<3)+4>>2]=z;q=ce(x,q,p,u)|0;x=z;y=Ze(t^q,y^x,32)|0;t=z;w=ce(v,w,y,t)|0;v=z;u=Ze(p^w,u^v,24)|0;p=z;x=ce(q,x,u,p)|0;q=z;c[f+1024+((b|1)<<3)>>2]=x;c[f+1024+((b|1)<<3)+4>>2]=q;q=Ze(y^x,t^q,16)|0;t=z;c[f+1024+((b|12)<<3)>>2]=q;c[f+1024+((b|12)<<3)+4>>2]=t;t=ce(w,v,q,t)|0;q=z;c[f+1024+((b|11)<<3)>>2]=t;c[f+1024+((b|11)<<3)+4>>2]=q;q=Ze(u^t,p^q,63)|0;c[f+1024+((b|6)<<3)>>2]=q;c[f+1024+((b|6)<<3)+4>>2]=z;h=ce(r,h,j,k)|0;r=z;s=Ze(m^h,s^r,32)|0;m=z;q=ce(c[f+1024+((b|8)<<3)>>2]|0,c[f+1024+((b|8)<<3)+4>>2]|0,s,m)|0;p=z;k=Ze(j^q,k^p,24)|0;j=z;r=ce(h,r,k,j)|0;h=z;c[f+1024+((b|2)<<3)>>2]=r;c[f+1024+((b|2)<<3)+4>>2]=h;h=Ze(s^r,m^h,16)|0;m=z;c[f+1024+((b|13)<<3)>>2]=h;c[f+1024+((b|13)<<3)+4>>2]=m;m=ce(q,p,h,m)|0;h=z;c[f+1024+((b|8)<<3)>>2]=m;c[f+1024+((b|8)<<3)+4>>2]=h;h=Ze(k^m,j^h,63)|0;c[f+1024+((b|7)<<3)>>2]=h;c[f+1024+((b|7)<<3)+4>>2]=z;h=c[f+1024+((b|4)<<3)>>2]|0;j=c[f+1024+((b|4)<<3)+4>>2]|0;g=ce(n,g,h,j)|0;n=z;o=Ze(i^g,o^n,32)|0;i=z;m=ce(c[f+1024+((b|9)<<3)>>2]|0,c[f+1024+((b|9)<<3)+4>>2]|0,o,i)|0;k=z;j=Ze(h^m,j^k,24)|0;h=z;n=ce(g,n,j,h)|0;g=z;c[f+1024+((b|3)<<3)>>2]=n;c[f+1024+((b|3)<<3)+4>>2]=g;g=Ze(o^n,i^g,16)|0;i=z;c[f+1024+((b|14)<<3)>>2]=g;c[f+1024+((b|14)<<3)+4>>2]=i;i=ce(m,k,g,i)|0;g=z;c[f+1024+((b|9)<<3)>>2]=i;c[f+1024+((b|9)<<3)+4>>2]=g;g=Ze(j^i,h^g,63)|0;c[f+1024+((b|4)<<3)>>2]=g;c[f+1024+((b|4)<<3)+4>>2]=z;a=a+1|0}while((a|0)!=8);a=0;do{H=a<<1;p=f+1024+(H+32<<3)|0;s=c[p>>2]|0;p=c[p+4>>2]|0;m=ce(c[f+1024+(H<<3)>>2]|0,c[f+1024+(H<<3)+4>>2]|0,s,p)|0;g=z;o=f+1024+(H+96<<3)|0;o=Ze(c[o>>2]^m,c[o+4>>2]^g,32)|0;t=z;j=f+1024+(H+64<<3)|0;j=ce(c[j>>2]|0,c[j+4>>2]|0,o,t)|0;x=z;p=Ze(s^j,p^x,24)|0;s=z;g=ce(m,g,p,s)|0;m=z;t=Ze(o^g,t^m,16)|0;o=z;u=f+1024+(H+96<<3)|0;c[u>>2]=t;c[u+4>>2]=o;x=ce(j,x,t,o)|0;j=z;u=f+1024+(H+64<<3)|0;c[u>>2]=x;c[u+4>>2]=j;j=Ze(p^x,s^j,63)|0;s=f+1024+(H+32<<3)|0;c[s>>2]=j;c[s+4>>2]=z;s=f+1024+(H+33<<3)|0;j=c[s>>2]|0;s=c[s+4>>2]|0;x=ce(c[f+1024+((H|1)<<3)>>2]|0,c[f+1024+((H|1)<<3)+4>>2]|0,j,s)|0;p=z;u=f+1024+(H+97<<3)|0;u=Ze(c[u>>2]^x,c[u+4>>2]^p,32)|0;B=z;n=f+1024+(H+65<<3)|0;n=ce(c[n>>2]|0,c[n+4>>2]|0,u,B)|0;F=z;s=Ze(j^n,s^F,24)|0;j=z;p=ce(x,p,s,j)|0;x=z;B=Ze(u^p,B^x,16)|0;u=z;F=ce(n,F,B,u)|0;n=z;w=f+1024+(H+65<<3)|0;c[w>>2]=F;c[w+4>>2]=n;n=Ze(s^F,j^n,63)|0;j=z;F=f+1024+(H+16<<3)|0;s=f+1024+(H+48<<3)|0;w=c[s>>2]|0;s=c[s+4>>2]|0;F=ce(c[F>>2]|0,c[F+4>>2]|0,w,s)|0;v=z;y=f+1024+(H+112<<3)|0;y=Ze(c[y>>2]^F,c[y+4>>2]^v,32)|0;E=z;h=f+1024+(H+80<<3)|0;h=ce(c[h>>2]|0,c[h+4>>2]|0,y,E)|0;i=z;s=Ze(w^h,s^i,24)|0;w=z;v=ce(F,v,s,w)|0;F=z;E=Ze(y^v,E^F,16)|0;y=z;i=ce(h,i,E,y)|0;h=z;w=Ze(s^i,w^h,63)|0;s=z;G=f+1024+(H+17<<3)|0;C=f+1024+(H+49<<3)|0;D=c[C>>2]|0;C=c[C+4>>2]|0;G=ce(c[G>>2]|0,c[G+4>>2]|0,D,C)|0;A=z;b=f+1024+(H+113<<3)|0;b=Ze(c[b>>2]^G,c[b+4>>2]^A,32)|0;k=z;q=f+1024+(H+81<<3)|0;q=ce(c[q>>2]|0,c[q+4>>2]|0,b,k)|0;r=z;C=Ze(D^q,C^r,24)|0;D=z;A=ce(G,A,C,D)|0;G=z;k=Ze(b^A,k^G,16)|0;b=z;r=ce(q,r,k,b)|0;q=z;D=Ze(C^r,D^q,63)|0;C=z;m=ce(g,m,n,j)|0;g=z;b=Ze(k^m,b^g,32)|0;k=z;h=ce(i,h,b,k)|0;i=z;j=Ze(n^h,j^i,24)|0;n=z;g=ce(m,g,j,n)|0;m=z;c[f+1024+(H<<3)>>2]=g;c[f+1024+(H<<3)+4>>2]=m;m=Ze(b^g,k^m,16)|0;k=z;g=f+1024+(H+113<<3)|0;c[g>>2]=m;c[g+4>>2]=k;k=ce(h,i,m,k)|0;m=z;i=f+1024+(H+80<<3)|0;c[i>>2]=k;c[i+4>>2]=m;m=Ze(j^k,n^m,63)|0;n=f+1024+(H+33<<3)|0;c[n>>2]=m;c[n+4>>2]=z;x=ce(p,x,w,s)|0;p=z;o=Ze(t^x,o^p,32)|0;t=z;q=ce(r,q,o,t)|0;r=z;s=Ze(w^q,s^r,24)|0;w=z;p=ce(x,p,s,w)|0;x=z;c[f+1024+((H|1)<<3)>>2]=p;c[f+1024+((H|1)<<3)+4>>2]=x;x=Ze(o^p,t^x,16)|0;t=z;p=f+1024+(H+96<<3)|0;c[p>>2]=x;c[p+4>>2]=t;t=ce(q,r,x,t)|0;x=z;r=f+1024+(H+81<<3)|0;c[r>>2]=t;c[r+4>>2]=x;x=Ze(s^t,w^x,63)|0;w=f+1024+(H+48<<3)|0;c[w>>2]=x;c[w+4>>2]=z;F=ce(v,F,D,C)|0;v=z;u=Ze(B^F,u^v,32)|0;B=z;w=f+1024+(H+64<<3)|0;w=ce(c[w>>2]|0,c[w+4>>2]|0,u,B)|0;x=z;C=Ze(D^w,C^x,24)|0;D=z;v=ce(F,v,C,D)|0;F=z;t=f+1024+(H+16<<3)|0;c[t>>2]=v;c[t+4>>2]=F;F=Ze(u^v,B^F,16)|0;B=z;v=f+1024+(H+97<<3)|0;c[v>>2]=F;c[v+4>>2]=B;B=ce(w,x,F,B)|0;F=z;x=f+1024+(H+64<<3)|0;c[x>>2]=B;c[x+4>>2]=F;F=Ze(C^B,D^F,63)|0;D=f+1024+(H+49<<3)|0;c[D>>2]=F;c[D+4>>2]=z;D=f+1024+(H+32<<3)|0;F=c[D>>2]|0;D=c[D+4>>2]|0;G=ce(A,G,F,D)|0;A=z;y=Ze(E^G,y^A,32)|0;E=z;B=f+1024+(H+65<<3)|0;B=ce(c[B>>2]|0,c[B+4>>2]|0,y,E)|0;C=z;D=Ze(F^B,D^C,24)|0;F=z;A=ce(G,A,D,F)|0;G=z;x=f+1024+(H+17<<3)|0;c[x>>2]=A;c[x+4>>2]=G;G=Ze(y^A,E^G,16)|0;E=z;A=f+1024+(H+112<<3)|0;c[A>>2]=G;c[A+4>>2]=E;E=ce(B,C,G,E)|0;G=z;C=f+1024+(H+65<<3)|0;c[C>>2]=E;c[C+4>>2]=G;G=Ze(D^E,F^G,63)|0;H=f+1024+(H+32<<3)|0;c[H>>2]=G;c[H+4>>2]=z;a=a+1|0}while((a|0)!=8);uh(d,f);Ud(d,f+1024|0);l=e;return}function oa(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0,sa=0,ta=0,ua=0,va=0,wa=0,xa=0,ya=0,za=0,Aa=0,Ba=0,Ca=0,Da=0,Ea=0,Fa=0,Ga=0,Ha=0,Ia=0,Ja=0,Ka=0,La=0,Ma=0,Na=0,Oa=0,Pa=0,Qa=0,Ra=0,Sa=0,Ta=0,Ua=0,Va=0,Wa=0,Xa=0,Ya=0,Za=0,_a=0,$a=0,ab=0,bb=0,cb=0,db=0,eb=0;l=c[b>>2]|0;n=c[b+4>>2]|0;k=c[b+8>>2]|0;f=c[b+12>>2]|0;u=c[b+16>>2]|0;t=c[b+20>>2]|0;g=c[b+24>>2]|0;v=c[b+28>>2]|0;s=c[b+32>>2]|0;q=c[b+36>>2]|0;cb=af(l|0,((l|0)<0)<<31>>31|0,l|0,((l|0)<0)<<31>>31|0)|0;bb=z;o=((l<<1|0)<0)<<31>>31;Ua=af(l<<1|0,o|0,n|0,((n|0)<0)<<31>>31|0)|0;Ta=z;Oa=af(k|0,((k|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Na=z;Ea=af(f|0,((f|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Da=z;sa=af(u|0,((u|0)<0)<<31>>31|0,l<<1|0,o|0)|0;ra=z;ia=af(t|0,((t|0)<0)<<31>>31|0,l<<1|0,o|0)|0;ha=z;_=af(g|0,((g|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Z=z;Q=af(v|0,((v|0)<0)<<31>>31|0,l<<1|0,o|0)|0;P=z;G=af(s|0,((s|0)<0)<<31>>31|0,l<<1|0,o|0)|0;F=z;o=af(q|0,((q|0)<0)<<31>>31|0,l<<1|0,o|0)|0;l=z;p=((n<<1|0)<0)<<31>>31;Ma=af(n<<1|0,p|0,n|0,((n|0)<0)<<31>>31|0)|0;La=z;Ca=af(n<<1|0,p|0,k|0,((k|0)<0)<<31>>31|0)|0;Ba=z;w=((f<<1|0)<0)<<31>>31;wa=af(f<<1|0,w|0,n<<1|0,p|0)|0;va=z;ma=af(u|0,((u|0)<0)<<31>>31|0,n<<1|0,p|0)|0;la=z;aa=af(t<<1|0,((t<<1|0)<0)<<31>>31|0,n<<1|0,p|0)|0;$=z;S=af(g|0,((g|0)<0)<<31>>31|0,n<<1|0,p|0)|0;R=z;I=af(v<<1|0,((v<<1|0)<0)<<31>>31|0,n<<1|0,p|0)|0;H=z;m=af(s|0,((s|0)<0)<<31>>31|0,n<<1|0,p|0)|0;r=z;b=((q*38|0)<0)<<31>>31;p=af(q*38|0,b|0,n<<1|0,p|0)|0;n=z;ua=af(k|0,((k|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;ta=z;ka=af(k<<1|0,((k<<1|0)<0)<<31>>31|0,f|0,((f|0)<0)<<31>>31|0)|0;ja=z;ca=af(u|0,((u|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;ba=z;W=af(t|0,((t|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;V=z;O=af(g|0,((g|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;N=z;A=af(v|0,((v|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;y=z;Y=((s*19|0)<0)<<31>>31;Ya=af(s*19|0,Y|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;Xa=z;k=af(q*38|0,b|0,k|0,((k|0)<0)<<31>>31|0)|0;j=z;ea=af(f<<1|0,w|0,f|0,((f|0)<0)<<31>>31|0)|0;da=z;U=af(f<<1|0,w|0,u|0,((u|0)<0)<<31>>31|0)|0;T=z;K=af(t<<1|0,((t<<1|0)<0)<<31>>31|0,f<<1|0,w|0)|0;J=z;E=af(g|0,((g|0)<0)<<31>>31|0,f<<1|0,w|0)|0;D=z;qa=((v*38|0)<0)<<31>>31;_a=af(v*38|0,qa|0,f<<1|0,w|0)|0;Za=z;Qa=af(s*19|0,Y|0,f<<1|0,w|0)|0;Pa=z;w=af(q*38|0,b|0,f<<1|0,w|0)|0;f=z;M=af(u|0,((u|0)<0)<<31>>31|0,u|0,((u|0)<0)<<31>>31|0)|0;L=z;C=af(u<<1|0,((u<<1|0)<0)<<31>>31|0,t|0,((t|0)<0)<<31>>31|0)|0;B=z;ab=af(g*19|0,((g*19|0)<0)<<31>>31|0,u<<1|0,((u<<1|0)<0)<<31>>31|0)|0;$a=z;Sa=af(v*38|0,qa|0,u|0,((u|0)<0)<<31>>31|0)|0;Ra=z;Ga=af(s*19|0,Y|0,u<<1|0,((u<<1|0)<0)<<31>>31|0)|0;Fa=z;u=af(q*38|0,b|0,u|0,((u|0)<0)<<31>>31|0)|0;e=z;eb=af(t*38|0,((t*38|0)<0)<<31>>31|0,t|0,((t|0)<0)<<31>>31|0)|0;db=z;Wa=af(g*19|0,((g*19|0)<0)<<31>>31|0,t<<1|0,((t<<1|0)<0)<<31>>31|0)|0;Va=z;Ia=af(v*38|0,qa|0,t<<1|0,((t<<1|0)<0)<<31>>31|0)|0;Ha=z;ya=af(s*19|0,Y|0,t<<1|0,((t<<1|0)<0)<<31>>31|0)|0;xa=z;t=af(q*38|0,b|0,t<<1|0,((t<<1|0)<0)<<31>>31|0)|0;d=z;Ka=af(g*19|0,((g*19|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;Ja=z;Aa=af(v*38|0,qa|0,g|0,((g|0)<0)<<31>>31|0)|0;za=z;oa=af(s*19|0,Y|0,g<<1|0,((g<<1|0)<0)<<31>>31|0)|0;na=z;g=af(q*38|0,b|0,g|0,((g|0)<0)<<31>>31|0)|0;x=z;qa=af(v*38|0,qa|0,v|0,((v|0)<0)<<31>>31|0)|0;pa=z;ga=af(s*19|0,Y|0,v<<1|0,((v<<1|0)<0)<<31>>31|0)|0;fa=z;v=af(q*38|0,b|0,v<<1|0,((v<<1|0)<0)<<31>>31|0)|0;i=z;Y=af(s*19|0,Y|0,s|0,((s|0)<0)<<31>>31|0)|0;X=z;s=af(q*38|0,b|0,s|0,((s|0)<0)<<31>>31|0)|0;h=z;q=af(q*38|0,b|0,q|0,((q|0)<0)<<31>>31|0)|0;b=z;bb=fg(eb|0,db|0,cb|0,bb|0)|0;$a=fg(bb|0,z|0,ab|0,$a|0)|0;Za=fg($a|0,z|0,_a|0,Za|0)|0;Xa=fg(Za|0,z|0,Ya|0,Xa|0)|0;n=fg(Xa|0,z|0,p|0,n|0)|0;p=z;Ta=fg(Wa|0,Va|0,Ua|0,Ta|0)|0;Ra=fg(Ta|0,z|0,Sa|0,Ra|0)|0;Pa=fg(Ra|0,z|0,Qa|0,Pa|0)|0;j=fg(Pa|0,z|0,k|0,j|0)|0;k=z;La=fg(Oa|0,Na|0,Ma|0,La|0)|0;Ja=fg(La|0,z|0,Ka|0,Ja|0)|0;Ha=fg(Ja|0,z|0,Ia|0,Ha|0)|0;Fa=fg(Ha|0,z|0,Ga|0,Fa|0)|0;f=fg(Fa|0,z|0,w|0,f|0)|0;w=z;Ba=fg(Ea|0,Da|0,Ca|0,Ba|0)|0;za=fg(Ba|0,z|0,Aa|0,za|0)|0;xa=fg(za|0,z|0,ya|0,xa|0)|0;e=fg(xa|0,z|0,u|0,e|0)|0;u=z;ta=fg(wa|0,va|0,ua|0,ta|0)|0;ra=fg(ta|0,z|0,sa|0,ra|0)|0;pa=fg(ra|0,z|0,qa|0,pa|0)|0;na=fg(pa|0,z|0,oa|0,na|0)|0;d=fg(na|0,z|0,t|0,d|0)|0;t=z;ja=fg(ma|0,la|0,ka|0,ja|0)|0;ha=fg(ja|0,z|0,ia|0,ha|0)|0;fa=fg(ha|0,z|0,ga|0,fa|0)|0;x=fg(fa|0,z|0,g|0,x|0)|0;g=z;ba=fg(ea|0,da|0,ca|0,ba|0)|0;$=fg(ba|0,z|0,aa|0,$|0)|0;Z=fg($|0,z|0,_|0,Z|0)|0;X=fg(Z|0,z|0,Y|0,X|0)|0;i=fg(X|0,z|0,v|0,i|0)|0;v=z;T=fg(W|0,V|0,U|0,T|0)|0;R=fg(T|0,z|0,S|0,R|0)|0;P=fg(R|0,z|0,Q|0,P|0)|0;h=fg(P|0,z|0,s|0,h|0)|0;s=z;L=fg(O|0,N|0,M|0,L|0)|0;J=fg(L|0,z|0,K|0,J|0)|0;H=fg(J|0,z|0,I|0,H|0)|0;F=fg(H|0,z|0,G|0,F|0)|0;b=fg(F|0,z|0,q|0,b|0)|0;q=z;B=fg(E|0,D|0,C|0,B|0)|0;y=fg(B|0,z|0,A|0,y|0)|0;r=fg(y|0,z|0,m|0,r|0)|0;l=fg(r|0,z|0,o|0,l|0)|0;o=z;p=vf(n|0,p|0,1)|0;n=z;k=vf(j|0,k|0,1)|0;j=z;w=vf(f|0,w|0,1)|0;f=z;u=vf(e|0,u|0,1)|0;e=z;t=vf(d|0,t|0,1)|0;d=z;g=vf(x|0,g|0,1)|0;x=z;v=vf(i|0,v|0,1)|0;i=z;s=vf(h|0,s|0,1)|0;h=z;q=vf(b|0,q|0,1)|0;b=z;o=vf(l|0,o|0,1)|0;l=z;r=fg(p|0,n|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;m=z;j=fg(r|0,m|0,k|0,j|0)|0;k=z;m=vf(r|0,m|0,26)|0;m=cg(p|0,n|0,m|0,z|0)|0;n=z;p=fg(t|0,d|0,33554432,0)|0;p=Xe(p|0,z|0,26)|0;r=z;x=fg(p|0,r|0,g|0,x|0)|0;g=z;r=vf(p|0,r|0,26)|0;r=cg(t|0,d|0,r|0,z|0)|0;d=z;t=fg(j|0,k|0,16777216,0)|0;t=Xe(t|0,z|0,25)|0;p=z;f=fg(t|0,p|0,w|0,f|0)|0;w=z;p=vf(t|0,p|0,25)|0;p=cg(j|0,k|0,p|0,z|0)|0;k=z;j=fg(x|0,g|0,16777216,0)|0;j=Xe(j|0,z|0,25)|0;t=z;i=fg(j|0,t|0,v|0,i|0)|0;v=z;t=vf(j|0,t|0,25)|0;t=cg(x|0,g|0,t|0,z|0)|0;g=z;x=fg(f|0,w|0,33554432,0)|0;x=Xe(x|0,z|0,26)|0;j=z;e=fg(x|0,j|0,u|0,e|0)|0;u=z;j=vf(x|0,j|0,26)|0;j=cg(f|0,w|0,j|0,z|0)|0;w=fg(i|0,v|0,33554432,0)|0;w=Xe(w|0,z|0,26)|0;f=z;h=fg(w|0,f|0,s|0,h|0)|0;s=z;f=vf(w|0,f|0,26)|0;f=cg(i|0,v|0,f|0,z|0)|0;v=fg(e|0,u|0,16777216,0)|0;v=Xe(v|0,z|0,25)|0;i=z;d=fg(v|0,i|0,r|0,d|0)|0;r=z;i=vf(v|0,i|0,25)|0;i=cg(e|0,u|0,i|0,z|0)|0;u=fg(h|0,s|0,16777216,0)|0;u=Xe(u|0,z|0,25)|0;e=z;b=fg(u|0,e|0,q|0,b|0)|0;q=z;e=vf(u|0,e|0,25)|0;e=cg(h|0,s|0,e|0,z|0)|0;s=fg(d|0,r|0,33554432,0)|0;s=Xe(s|0,z|0,26)|0;h=z;g=fg(t|0,g|0,s|0,h|0)|0;h=vf(s|0,h|0,26)|0;h=cg(d|0,r|0,h|0,z|0)|0;r=fg(b|0,q|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;d=z;l=fg(r|0,d|0,o|0,l|0)|0;o=z;d=vf(r|0,d|0,26)|0;d=cg(b|0,q|0,d|0,z|0)|0;q=fg(l|0,o|0,16777216,0)|0;q=Xe(q|0,z|0,25)|0;b=z;r=af(q|0,b|0,19,0)|0;n=fg(r|0,z|0,m|0,n|0)|0;m=z;b=vf(q|0,b|0,25)|0;b=cg(l|0,o|0,b|0,z|0)|0;o=fg(n|0,m|0,33554432,0)|0;o=Xe(o|0,z|0,26)|0;l=z;k=fg(p|0,k|0,o|0,l|0)|0;l=vf(o|0,l|0,26)|0;l=cg(n|0,m|0,l|0,z|0)|0;c[a>>2]=l;c[a+4>>2]=k;c[a+8>>2]=j;c[a+12>>2]=i;c[a+16>>2]=h;c[a+20>>2]=g;c[a+24>>2]=f;c[a+28>>2]=e;c[a+32>>2]=d;c[a+36>>2]=b;return}function pa(a,b,d,e){a=a|0;b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0;tf(d,b);c[e>>2]=c[a>>2];c[e+4>>2]=c[a+4>>2];c[e+8>>2]=c[a+8>>2];c[e+12>>2]=c[a+12>>2];c[e+16>>2]=c[a+16>>2];c[e+20>>2]=c[a+20>>2];c[e+24>>2]=c[a+24>>2];c[e+28>>2]=c[a+28>>2];s=0;b=c[d>>2]|0;while(1){w=c[e+16>>2]|0;m=Ah(w,6)|0;m=(Ah(w,11)|0)^m;m=m^(Ah(w,25)|0);k=c[e+20>>2]|0;j=c[e+24>>2]|0;m=b+m+(c[32984+(s<<2)>>2]|0)+((j^k)&w^j)+(c[e+28>>2]|0)|0;l=m+(c[e+12>>2]|0)|0;c[e+12>>2]=l;i=c[e>>2]|0;v=Ah(i,2)|0;v=(Ah(i,13)|0)^v;v=v^(Ah(i,22)|0);h=c[e+4>>2]|0;g=c[e+8>>2]|0;c[e+28>>2]=m+v+((g|h)&i|g&h);u=Ah(l,6)|0;u=(Ah(l,11)|0)^u;u=u^(Ah(l,25)|0);q=s|1;j=(c[d+(q<<2)>>2]|0)+u+(c[32984+(q<<2)>>2]|0)+((k^w)&l^k)+j|0;c[e+8>>2]=j+g;u=Ah(m+v+((g|h)&i|g&h)|0,2)|0;u=(Ah(m+v+((g|h)&i|g&h)|0,13)|0)^u;u=j+(u^(Ah(m+v+((g|h)&i|g&h)|0,22)|0))+((h|i)&m+v+((g|h)&i|g&h)|h&i)|0;c[e+24>>2]=u;f=Ah(j+g|0,6)|0;f=(Ah(j+g|0,11)|0)^f;f=f^(Ah(j+g|0,25)|0);r=s|2;k=(c[d+(r<<2)>>2]|0)+f+(c[32984+(r<<2)>>2]|0)+((w^l)&j+g^w)+k|0;c[e+4>>2]=k+h;w=Ah(u,2)|0;w=(Ah(u,13)|0)^w;w=k+(w^(Ah(u,22)|0))+((i|m+v+((g|h)&i|g&h))&u|i&m+v+((g|h)&i|g&h))|0;c[e+20>>2]=w;f=Ah(k+h|0,6)|0;f=(Ah(k+h|0,11)|0)^f;f=f^(Ah(k+h|0,25)|0);b=s|3;l=(c[d+(b<<2)>>2]|0)+f+(c[32984+(b<<2)>>2]|0)+((l^j+g)&k+h^l)+(c[e+16>>2]|0)|0;c[e>>2]=l+i;f=Ah(w,2)|0;f=(Ah(w,13)|0)^f;v=l+(f^(Ah(w,22)|0))+((m+v+((g|h)&i|g&h)|u)&w|m+v+((g|h)&i|g&h)&u)|0;c[e+16>>2]=v;m=Ah(l+i|0,6)|0;m=(Ah(l+i|0,11)|0)^m;m=m^(Ah(l+i|0,25)|0);f=s|4;g=(c[d+(f<<2)>>2]|0)+m+(c[32984+(f<<2)>>2]|0)+((j+g^k+h)&l+i^j+g)+(c[e+12>>2]|0)|0;j=g+(c[e+28>>2]|0)|0;c[e+28>>2]=j;m=Ah(v,2)|0;m=(Ah(v,13)|0)^m;u=g+(m^(Ah(v,22)|0))+((u|w)&v|u&w)|0;c[e+12>>2]=u;m=Ah(j,6)|0;m=(Ah(j,11)|0)^m;m=m^(Ah(j,25)|0);g=s|5;h=(c[d+(g<<2)>>2]|0)+m+(c[32984+(g<<2)>>2]|0)+((k+h^l+i)&j^k+h)+(c[e+8>>2]|0)|0;k=h+(c[e+24>>2]|0)|0;c[e+24>>2]=k;m=Ah(u,2)|0;m=(Ah(u,13)|0)^m;w=h+(m^(Ah(u,22)|0))+((w|v)&u|w&v)|0;c[e+8>>2]=w;m=Ah(k,6)|0;m=(Ah(k,11)|0)^m;m=m^(Ah(k,25)|0);h=s|6;i=(c[d+(h<<2)>>2]|0)+m+(c[32984+(h<<2)>>2]|0)+((l+i^j)&k^l+i)+(c[e+4>>2]|0)|0;l=i+(c[e+20>>2]|0)|0;c[e+20>>2]=l;m=Ah(w,2)|0;m=(Ah(w,13)|0)^m;v=i+(m^(Ah(w,22)|0))+((v|u)&w|v&u)|0;c[e+4>>2]=v;m=Ah(l,6)|0;m=(Ah(l,11)|0)^m;m=m^(Ah(l,25)|0);i=s|7;j=(c[d+(i<<2)>>2]|0)+m+(c[32984+(i<<2)>>2]|0)+((j^k)&l^j)+(c[e>>2]|0)|0;m=j+(c[e+16>>2]|0)|0;c[e+16>>2]=m;n=Ah(v,2)|0;n=(Ah(v,13)|0)^n;u=j+(n^(Ah(v,22)|0))+((u|w)&v|u&w)|0;c[e>>2]=u;n=Ah(m,6)|0;n=(Ah(m,11)|0)^n;n=n^(Ah(m,25)|0);j=s|8;k=(c[d+(j<<2)>>2]|0)+n+(c[32984+(j<<2)>>2]|0)+((k^l)&m^k)+(c[e+28>>2]|0)|0;n=k+(c[e+12>>2]|0)|0;c[e+12>>2]=n;o=Ah(u,2)|0;o=(Ah(u,13)|0)^o;w=k+(o^(Ah(u,22)|0))+((w|v)&u|w&v)|0;c[e+28>>2]=w;o=Ah(n,6)|0;o=(Ah(n,11)|0)^o;o=o^(Ah(n,25)|0);k=s|9;l=(c[d+(k<<2)>>2]|0)+o+(c[32984+(k<<2)>>2]|0)+((l^m)&n^l)+(c[e+24>>2]|0)|0;o=l+(c[e+8>>2]|0)|0;c[e+8>>2]=o;p=Ah(w,2)|0;p=(Ah(w,13)|0)^p;v=l+(p^(Ah(w,22)|0))+((v|u)&w|v&u)|0;c[e+24>>2]=v;p=Ah(o,6)|0;p=(Ah(o,11)|0)^p;p=p^(Ah(o,25)|0);l=s|10;m=(c[d+(l<<2)>>2]|0)+p+(c[32984+(l<<2)>>2]|0)+((m^n)&o^m)+(c[e+20>>2]|0)|0;p=m+(c[e+4>>2]|0)|0;c[e+4>>2]=p;t=Ah(v,2)|0;t=(Ah(v,13)|0)^t;u=m+(t^(Ah(v,22)|0))+((u|w)&v|u&w)|0;c[e+20>>2]=u;t=Ah(p,6)|0;t=(Ah(p,11)|0)^t;t=t^(Ah(p,25)|0);m=s|11;n=(c[d+(m<<2)>>2]|0)+t+(c[32984+(m<<2)>>2]|0)+((n^o)&p^n)+(c[e+16>>2]|0)|0;t=n+(c[e>>2]|0)|0;c[e>>2]=t;y=Ah(u,2)|0;y=(Ah(u,13)|0)^y;w=n+(y^(Ah(u,22)|0))+((w|v)&u|w&v)|0;c[e+16>>2]=w;y=Ah(t,6)|0;y=(Ah(t,11)|0)^y;y=y^(Ah(t,25)|0);n=s|12;o=(c[d+(n<<2)>>2]|0)+y+(c[32984+(n<<2)>>2]|0)+((o^p)&t^o)+(c[e+12>>2]|0)|0;y=o+(c[e+28>>2]|0)|0;c[e+28>>2]=y;z=Ah(w,2)|0;z=(Ah(w,13)|0)^z;v=o+(z^(Ah(w,22)|0))+((v|u)&w|v&u)|0;c[e+12>>2]=v;z=Ah(y,6)|0;z=(Ah(y,11)|0)^z;z=z^(Ah(y,25)|0);o=s|13;p=(c[d+(o<<2)>>2]|0)+z+(c[32984+(o<<2)>>2]|0)+((p^t)&y^p)+(c[e+8>>2]|0)|0;z=p+(c[e+24>>2]|0)|0;c[e+24>>2]=z;x=Ah(v,2)|0;x=(Ah(v,13)|0)^x;u=p+(x^(Ah(v,22)|0))+((u|w)&v|u&w)|0;c[e+8>>2]=u;x=Ah(z,6)|0;x=(Ah(z,11)|0)^x;x=x^(Ah(z,25)|0);p=s|14;t=(c[d+(p<<2)>>2]|0)+x+(c[32984+(p<<2)>>2]|0)+((t^y)&z^t)+(c[e+4>>2]|0)|0;x=t+(c[e+20>>2]|0)|0;c[e+20>>2]=x;A=Ah(u,2)|0;A=(Ah(u,13)|0)^A;w=t+(A^(Ah(u,22)|0))+((w|v)&u|w&v)|0;c[e+4>>2]=w;A=Ah(x,6)|0;A=(Ah(x,11)|0)^A;A=A^(Ah(x,25)|0);t=s|15;y=(c[d+(t<<2)>>2]|0)+A+(c[32984+(t<<2)>>2]|0)+((y^z)&x^y)+(c[e>>2]|0)|0;c[e+16>>2]=y+(c[e+16>>2]|0);x=Ah(w,2)|0;x=(Ah(w,13)|0)^x;c[e>>2]=y+(x^(Ah(w,22)|0))+((v|u)&w|v&u);if((s|0)==48){b=0;break}z=c[d+(p<<2)>>2]|0;y=Ah(z,17)|0;z=z>>>10^y^(Ah(z,19)|0);z=z+(c[d+(k<<2)>>2]|0)|0;y=c[d+(q<<2)>>2]|0;x=Ah(y,7)|0;x=y>>>3^x^(Ah(y,18)|0);x=z+(c[d+(s<<2)>>2]|0)+x|0;s=s+16|0;c[d+(s<<2)>>2]=x;z=c[d+(t<<2)>>2]|0;A=Ah(z,17)|0;z=z>>>10^A^(Ah(z,19)|0);z=z+(c[d+(q+9<<2)>>2]|0)|0;A=c[d+(q+1<<2)>>2]|0;w=Ah(A,7)|0;w=z+y+(A>>>3^w^(Ah(A,18)|0))|0;c[d+(q+16<<2)>>2]=w;y=Ah(x,17)|0;x=x>>>10^y^(Ah(x,19)|0);x=x+(c[d+(m<<2)>>2]|0)|0;y=c[d+(b<<2)>>2]|0;z=Ah(y,7)|0;z=x+A+(y>>>3^z^(Ah(y,18)|0))|0;c[d+(r+16<<2)>>2]=z;A=Ah(w,17)|0;w=w>>>10^A^(Ah(w,19)|0);w=w+(c[d+(b+9<<2)>>2]|0)|0;A=c[d+(b+1<<2)>>2]|0;x=Ah(A,7)|0;x=w+y+(A>>>3^x^(Ah(A,18)|0))|0;c[d+(b+16<<2)>>2]=x;b=Ah(z,17)|0;b=z>>>10^b^(Ah(z,19)|0);b=b+(c[d+(o<<2)>>2]|0)|0;z=c[d+(g<<2)>>2]|0;y=Ah(z,7)|0;y=b+A+(z>>>3^y^(Ah(z,18)|0))|0;c[d+(f+16<<2)>>2]=y;A=Ah(x,17)|0;x=x>>>10^A^(Ah(x,19)|0);x=x+(c[d+(g+9<<2)>>2]|0)|0;A=c[d+(g+1<<2)>>2]|0;b=Ah(A,7)|0;b=x+z+(A>>>3^b^(Ah(A,18)|0))|0;c[d+(g+16<<2)>>2]=b;z=Ah(y,17)|0;y=y>>>10^z^(Ah(y,19)|0);y=y+(c[d+(t<<2)>>2]|0)|0;z=c[d+(i<<2)>>2]|0;x=Ah(z,7)|0;x=y+A+(z>>>3^x^(Ah(z,18)|0))|0;c[d+(h+16<<2)>>2]=x;A=Ah(b,17)|0;b=b>>>10^A^(Ah(b,19)|0);b=b+(c[d+(i+9<<2)>>2]|0)|0;A=c[d+(i+1<<2)>>2]|0;y=Ah(A,7)|0;y=b+z+(A>>>3^y^(Ah(A,18)|0))|0;c[d+(i+16<<2)>>2]=y;z=Ah(x,17)|0;x=x>>>10^z^(Ah(x,19)|0);x=x+(c[d+(j+9<<2)>>2]|0)|0;z=c[d+(k<<2)>>2]|0;b=Ah(z,7)|0;b=x+A+(z>>>3^b^(Ah(z,18)|0))|0;c[d+(j+16<<2)>>2]=b;A=Ah(y,17)|0;y=y>>>10^A^(Ah(y,19)|0);y=y+(c[d+(k+9<<2)>>2]|0)|0;A=c[d+(k+1<<2)>>2]|0;x=Ah(A,7)|0;x=y+z+(A>>>3^x^(Ah(A,18)|0))|0;c[d+(k+16<<2)>>2]=x;z=Ah(b,17)|0;b=b>>>10^z^(Ah(b,19)|0);b=b+(c[d+(l+9<<2)>>2]|0)|0;z=c[d+(m<<2)>>2]|0;y=Ah(z,7)|0;y=b+A+(z>>>3^y^(Ah(z,18)|0))|0;c[d+(l+16<<2)>>2]=y;A=Ah(x,17)|0;x=x>>>10^A^(Ah(x,19)|0);x=x+(c[d+(m+9<<2)>>2]|0)|0;A=c[d+(m+1<<2)>>2]|0;b=Ah(A,7)|0;b=x+z+(A>>>3^b^(Ah(A,18)|0))|0;c[d+(m+16<<2)>>2]=b;z=Ah(y,17)|0;y=y>>>10^z^(Ah(y,19)|0);y=y+(c[d+(n+9<<2)>>2]|0)|0;z=c[d+(o<<2)>>2]|0;x=Ah(z,7)|0;x=y+A+(z>>>3^x^(Ah(z,18)|0))|0;c[d+(n+16<<2)>>2]=x;A=Ah(b,17)|0;b=b>>>10^A^(Ah(b,19)|0);b=b+(c[d+(o+9<<2)>>2]|0)|0;A=c[d+(o+1<<2)>>2]|0;y=Ah(A,7)|0;y=b+z+(A>>>3^y^(Ah(A,18)|0))|0;c[d+(o+16<<2)>>2]=y;z=Ah(x,17)|0;x=x>>>10^z^(Ah(x,19)|0);x=x+(c[d+(p+9<<2)>>2]|0)|0;z=c[d+(t<<2)>>2]|0;b=Ah(z,7)|0;c[d+(p+16<<2)>>2]=x+A+(z>>>3^b^(Ah(z,18)|0));b=Ah(y,17)|0;y=y>>>10^b^(Ah(y,19)|0);y=y+(c[d+(t+9<<2)>>2]|0)|0;b=c[d+(t+1<<2)>>2]|0;A=Ah(b,7)|0;c[d+(t+16<<2)>>2]=y+z+(b>>>3^A^(Ah(b,18)|0));if((s|0)>=64){b=0;break}}do{A=a+(b<<2)|0;c[A>>2]=(c[A>>2]|0)+(c[e+(b<<2)>>2]|0);b=b+1|0}while((b|0)!=8);return}function qa(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,Z=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0,pa=0,qa=0,ra=0,sa=0,ta=0,ua=0,va=0,wa=0,xa=0,ya=0,za=0,Aa=0,Ba=0,Ca=0,Da=0,Ea=0,Fa=0,Ga=0,Ha=0,Ia=0,Ja=0,Ka=0,La=0,Ma=0,Na=0,Oa=0,Pa=0,Qa=0,Ra=0,Sa=0,Ta=0,Ua=0,Va=0,Wa=0,Xa=0,Ya=0,Za=0,_a=0,$a=0,ab=0,bb=0,cb=0,db=0,eb=0;l=c[b>>2]|0;p=c[b+4>>2]|0;k=c[b+8>>2]|0;f=c[b+12>>2]|0;D=c[b+16>>2]|0;d=c[b+20>>2]|0;g=c[b+24>>2]|0;O=c[b+28>>2]|0;B=c[b+32>>2]|0;q=c[b+36>>2]|0;cb=af(l|0,((l|0)<0)<<31>>31|0,l|0,((l|0)<0)<<31>>31|0)|0;bb=z;o=((l<<1|0)<0)<<31>>31;Ia=af(l<<1|0,o|0,p|0,((p|0)<0)<<31>>31|0)|0;Ha=z;Wa=af(k|0,((k|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Va=z;Ua=af(f|0,((f|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Ta=z;Oa=af(D|0,((D|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Na=z;ya=af(d|0,((d|0)<0)<<31>>31|0,l<<1|0,o|0)|0;xa=z;ga=af(g|0,((g|0)<0)<<31>>31|0,l<<1|0,o|0)|0;fa=z;R=af(O|0,((O|0)<0)<<31>>31|0,l<<1|0,o|0)|0;Q=z;F=af(B|0,((B|0)<0)<<31>>31|0,l<<1|0,o|0)|0;E=z;o=af(q|0,((q|0)<0)<<31>>31|0,l<<1|0,o|0)|0;l=z;n=((p<<1|0)<0)<<31>>31;ta=af(p<<1|0,n|0,p|0,((p|0)<0)<<31>>31|0)|0;ua=z;ba=af(p<<1|0,n|0,k|0,((k|0)<0)<<31>>31|0)|0;ca=z;P=((f<<1|0)<0)<<31>>31;Sa=af(f<<1|0,P|0,p<<1|0,n|0)|0;Ra=z;Ca=af(D|0,((D|0)<0)<<31>>31|0,p<<1|0,n|0)|0;Ba=z;ia=af(d<<1|0,((d<<1|0)<0)<<31>>31|0,p<<1|0,n|0)|0;ha=z;T=af(g|0,((g|0)<0)<<31>>31|0,p<<1|0,n|0)|0;S=z;H=af(O<<1|0,((O<<1|0)<0)<<31>>31|0,p<<1|0,n|0)|0;G=z;t=af(B|0,((B|0)<0)<<31>>31|0,p<<1|0,n|0)|0;s=z;b=((q*38|0)<0)<<31>>31;n=af(q*38|0,b|0,p<<1|0,n|0)|0;p=z;Qa=af(k|0,((k|0)<0)<<31>>31|0,k|0,((k|0)<0)<<31>>31|0)|0;Pa=z;Aa=af(k<<1|0,((k<<1|0)<0)<<31>>31|0,f|0,((f|0)<0)<<31>>31|0)|0;za=z;ka=af(D|0,((D|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;ja=z;X=af(d|0,((d|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;W=z;N=af(g|0,((g|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;M=z;v=af(O|0,((O|0)<0)<<31>>31|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;u=z;ea=((B*19|0)<0)<<31>>31;Ya=af(B*19|0,ea|0,k<<1|0,((k<<1|0)<0)<<31>>31|0)|0;Xa=z;k=af(q*38|0,b|0,k|0,((k|0)<0)<<31>>31|0)|0;j=z;ma=af(f<<1|0,P|0,f|0,((f|0)<0)<<31>>31|0)|0;la=z;V=af(f<<1|0,P|0,D|0,((D|0)<0)<<31>>31|0)|0;U=z;J=af(d<<1|0,((d<<1|0)<0)<<31>>31|0,f<<1|0,P|0)|0;I=z;A=af(g|0,((g|0)<0)<<31>>31|0,f<<1|0,P|0)|0;y=z;Ma=((O*38|0)<0)<<31>>31;_a=af(O*38|0,Ma|0,f<<1|0,P|0)|0;Za=z;Ea=af(B*19|0,ea|0,f<<1|0,P|0)|0;Da=z;P=af(q*38|0,b|0,f<<1|0,P|0)|0;f=z;L=af(D|0,((D|0)<0)<<31>>31|0,D|0,((D|0)<0)<<31>>31|0)|0;K=z;x=af(D<<1|0,((D<<1|0)<0)<<31>>31|0,d|0,((d|0)<0)<<31>>31|0)|0;w=z;ab=af(g*19|0,((g*19|0)<0)<<31>>31|0,D<<1|0,((D<<1|0)<0)<<31>>31|0)|0;$a=z;Ga=af(O*38|0,Ma|0,D|0,((D|0)<0)<<31>>31|0)|0;Fa=z;oa=af(B*19|0,ea|0,D<<1|0,((D<<1|0)<0)<<31>>31|0)|0;na=z;D=af(q*38|0,b|0,D|0,((D|0)<0)<<31>>31|0)|0;e=z;eb=af(d*38|0,((d*38|0)<0)<<31>>31|0,d|0,((d|0)<0)<<31>>31|0)|0;db=z;Ka=af(g*19|0,((g*19|0)<0)<<31>>31|0,d<<1|0,((d<<1|0)<0)<<31>>31|0)|0;Ja=z;qa=af(O*38|0,Ma|0,d<<1|0,((d<<1|0)<0)<<31>>31|0)|0;pa=z;_=af(B*19|0,ea|0,d<<1|0,((d<<1|0)<0)<<31>>31|0)|0;Z=z;d=af(q*38|0,b|0,d<<1|0,((d<<1|0)<0)<<31>>31|0)|0;C=z;sa=af(g*19|0,((g*19|0)<0)<<31>>31|0,g|0,((g|0)<0)<<31>>31|0)|0;ra=z;aa=af(O*38|0,Ma|0,g|0,((g|0)<0)<<31>>31|0)|0;$=z;m=af(B*19|0,ea|0,g<<1|0,((g<<1|0)<0)<<31>>31|0)|0;r=z;g=af(q*38|0,b|0,g|0,((g|0)<0)<<31>>31|0)|0;Y=z;Ma=af(O*38|0,Ma|0,O|0,((O|0)<0)<<31>>31|0)|0;La=z;wa=af(B*19|0,ea|0,O<<1|0,((O<<1|0)<0)<<31>>31|0)|0;va=z;O=af(q*38|0,b|0,O<<1|0,((O<<1|0)<0)<<31>>31|0)|0;i=z;ea=af(B*19|0,ea|0,B|0,((B|0)<0)<<31>>31|0)|0;da=z;B=af(q*38|0,b|0,B|0,((B|0)<0)<<31>>31|0)|0;h=z;q=af(q*38|0,b|0,q|0,((q|0)<0)<<31>>31|0)|0;b=z;bb=fg(eb|0,db|0,cb|0,bb|0)|0;$a=fg(bb|0,z|0,ab|0,$a|0)|0;Za=fg($a|0,z|0,_a|0,Za|0)|0;Xa=fg(Za|0,z|0,Ya|0,Xa|0)|0;p=fg(Xa|0,z|0,n|0,p|0)|0;n=z;ua=fg(Wa|0,Va|0,ta|0,ua|0)|0;ta=z;ca=fg(Ua|0,Ta|0,ba|0,ca|0)|0;ba=z;Pa=fg(Sa|0,Ra|0,Qa|0,Pa|0)|0;Na=fg(Pa|0,z|0,Oa|0,Na|0)|0;La=fg(Na|0,z|0,Ma|0,La|0)|0;r=fg(La|0,z|0,m|0,r|0)|0;C=fg(r|0,z|0,d|0,C|0)|0;d=z;r=fg(p|0,n|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;m=z;Ha=fg(Ka|0,Ja|0,Ia|0,Ha|0)|0;Fa=fg(Ha|0,z|0,Ga|0,Fa|0)|0;Da=fg(Fa|0,z|0,Ea|0,Da|0)|0;j=fg(Da|0,z|0,k|0,j|0)|0;j=fg(j|0,z|0,r|0,m|0)|0;k=z;m=vf(r|0,m|0,26)|0;m=cg(p|0,n|0,m|0,z|0)|0;n=z;p=fg(C|0,d|0,33554432,0)|0;p=Xe(p|0,z|0,26)|0;r=z;za=fg(Ca|0,Ba|0,Aa|0,za|0)|0;xa=fg(za|0,z|0,ya|0,xa|0)|0;va=fg(xa|0,z|0,wa|0,va|0)|0;Y=fg(va|0,z|0,g|0,Y|0)|0;Y=fg(Y|0,z|0,p|0,r|0)|0;g=z;r=vf(p|0,r|0,26)|0;r=cg(C|0,d|0,r|0,z|0)|0;d=z;C=fg(j|0,k|0,16777216,0)|0;C=Xe(C|0,z|0,25)|0;p=z;ra=fg(ua|0,ta|0,sa|0,ra|0)|0;pa=fg(ra|0,z|0,qa|0,pa|0)|0;na=fg(pa|0,z|0,oa|0,na|0)|0;f=fg(na|0,z|0,P|0,f|0)|0;f=fg(f|0,z|0,C|0,p|0)|0;P=z;p=vf(C|0,p|0,25)|0;p=cg(j|0,k|0,p|0,z|0)|0;k=z;j=fg(Y|0,g|0,16777216,0)|0;j=Xe(j|0,z|0,25)|0;C=z;ja=fg(ma|0,la|0,ka|0,ja|0)|0;ha=fg(ja|0,z|0,ia|0,ha|0)|0;fa=fg(ha|0,z|0,ga|0,fa|0)|0;da=fg(fa|0,z|0,ea|0,da|0)|0;i=fg(da|0,z|0,O|0,i|0)|0;i=fg(i|0,z|0,j|0,C|0)|0;O=z;C=vf(j|0,C|0,25)|0;C=cg(Y|0,g|0,C|0,z|0)|0;g=z;Y=fg(f|0,P|0,33554432,0)|0;Y=Xe(Y|0,z|0,26)|0;j=z;$=fg(ca|0,ba|0,aa|0,$|0)|0;Z=fg($|0,z|0,_|0,Z|0)|0;e=fg(Z|0,z|0,D|0,e|0)|0;e=fg(e|0,z|0,Y|0,j|0)|0;D=z;j=vf(Y|0,j|0,26)|0;j=cg(f|0,P|0,j|0,z|0)|0;P=fg(i|0,O|0,33554432,0)|0;P=Xe(P|0,z|0,26)|0;f=z;U=fg(X|0,W|0,V|0,U|0)|0;S=fg(U|0,z|0,T|0,S|0)|0;Q=fg(S|0,z|0,R|0,Q|0)|0;h=fg(Q|0,z|0,B|0,h|0)|0;h=fg(h|0,z|0,P|0,f|0)|0;B=z;f=vf(P|0,f|0,26)|0;f=cg(i|0,O|0,f|0,z|0)|0;O=fg(e|0,D|0,16777216,0)|0;O=Xe(O|0,z|0,25)|0;i=z;d=fg(O|0,i|0,r|0,d|0)|0;r=z;i=vf(O|0,i|0,25)|0;i=cg(e|0,D|0,i|0,z|0)|0;D=fg(h|0,B|0,16777216,0)|0;D=Xe(D|0,z|0,25)|0;e=z;K=fg(N|0,M|0,L|0,K|0)|0;I=fg(K|0,z|0,J|0,I|0)|0;G=fg(I|0,z|0,H|0,G|0)|0;E=fg(G|0,z|0,F|0,E|0)|0;b=fg(E|0,z|0,q|0,b|0)|0;b=fg(b|0,z|0,D|0,e|0)|0;q=z;e=vf(D|0,e|0,25)|0;e=cg(h|0,B|0,e|0,z|0)|0;B=fg(d|0,r|0,33554432,0)|0;B=Xe(B|0,z|0,26)|0;h=z;g=fg(C|0,g|0,B|0,h|0)|0;h=vf(B|0,h|0,26)|0;h=cg(d|0,r|0,h|0,z|0)|0;r=fg(b|0,q|0,33554432,0)|0;r=Xe(r|0,z|0,26)|0;d=z;w=fg(A|0,y|0,x|0,w|0)|0;u=fg(w|0,z|0,v|0,u|0)|0;s=fg(u|0,z|0,t|0,s|0)|0;l=fg(s|0,z|0,o|0,l|0)|0;l=fg(l|0,z|0,r|0,d|0)|0;o=z;d=vf(r|0,d|0,26)|0;d=cg(b|0,q|0,d|0,z|0)|0;q=fg(l|0,o|0,16777216,0)|0;q=Xe(q|0,z|0,25)|0;b=z;r=af(q|0,b|0,19,0)|0;n=fg(r|0,z|0,m|0,n|0)|0;m=z;b=vf(q|0,b|0,25)|0;b=cg(l|0,o|0,b|0,z|0)|0;o=fg(n|0,m|0,33554432,0)|0;o=Xe(o|0,z|0,26)|0;l=z;k=fg(p|0,k|0,o|0,l|0)|0;l=vf(o|0,l|0,26)|0;l=cg(n|0,m|0,l|0,z|0)|0;c[a>>2]=l;c[a+4>>2]=k;c[a+8>>2]=j;c[a+12>>2]=i;c[a+16>>2]=h;c[a+20>>2]=g;c[a+24>>2]=f;c[a+28>>2]=e;c[a+32>>2]=d;c[a+36>>2]=b;return}function ra(a){a=a|0;var b=0,d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0;if(!a)return;h=c[8854]|0;if((a+-8|0)>>>0<h>>>0)Z();b=c[a+-4>>2]|0;if((b&3|0)==1)Z();o=a+-8+(b&-8)|0;a:do if(!(b&1)){e=c[a+-8>>2]|0;if(!(b&3))return;k=a+-8+(0-e)|0;j=e+(b&-8)|0;if(k>>>0<h>>>0)Z();if((k|0)==(c[8855]|0)){a=c[o+4>>2]|0;if((a&3|0)!=3){r=k;f=j;m=k;break}c[8852]=j;c[o+4>>2]=a&-2;c[k+4>>2]=j|1;c[k+j>>2]=j;return}if(e>>>0<256){a=c[k+8>>2]|0;b=c[k+12>>2]|0;if((a|0)!=(35440+(e>>>3<<1<<2)|0)){if(a>>>0<h>>>0)Z();if((c[a+12>>2]|0)!=(k|0))Z()}if((b|0)==(a|0)){c[8850]=c[8850]&~(1<<(e>>>3));r=k;f=j;m=k;break}if((b|0)!=(35440+(e>>>3<<1<<2)|0)){if(b>>>0<h>>>0)Z();if((c[b+8>>2]|0)!=(k|0))Z();else d=b+8|0}else d=b+8|0;c[a+12>>2]=b;c[d>>2]=a;r=k;f=j;m=k;break}g=c[k+24>>2]|0;a=c[k+12>>2]|0;do if((a|0)==(k|0)){a=c[k+16+4>>2]|0;if(!a){a=c[k+16>>2]|0;if(!a){i=0;break}else e=k+16|0}else e=k+16+4|0;while(1){b=a+20|0;d=c[b>>2]|0;if(d|0){a=d;e=b;continue}b=a+16|0;d=c[b>>2]|0;if(!d)break;else{a=d;e=b}}if(e>>>0<h>>>0)Z();else{c[e>>2]=0;i=a;break}}else{b=c[k+8>>2]|0;if(b>>>0<h>>>0)Z();if((c[b+12>>2]|0)!=(k|0))Z();if((c[a+8>>2]|0)==(k|0)){c[b+12>>2]=a;c[a+8>>2]=b;i=a;break}else Z()}while(0);if(g){a=c[k+28>>2]|0;do if((k|0)==(c[35704+(a<<2)>>2]|0)){c[35704+(a<<2)>>2]=i;if(!i){c[8851]=c[8851]&~(1<<a);r=k;f=j;m=k;break a}}else if(g>>>0>=(c[8854]|0)>>>0){c[g+16+(((c[g+16>>2]|0)!=(k|0)&1)<<2)>>2]=i;if(!i){r=k;f=j;m=k;break a}else break}else Z();while(0);b=c[8854]|0;if(i>>>0<b>>>0)Z();c[i+24>>2]=g;a=c[k+16>>2]|0;do if(a|0)if(a>>>0<b>>>0)Z();else{c[i+16>>2]=a;c[a+24>>2]=i;break}while(0);a=c[k+16+4>>2]|0;if(a)if(a>>>0<(c[8854]|0)>>>0)Z();else{c[i+20>>2]=a;c[a+24>>2]=i;r=k;f=j;m=k;break}else{r=k;f=j;m=k}}else{r=k;f=j;m=k}}else{r=a+-8|0;f=b&-8;m=a+-8|0}while(0);if(m>>>0>=o>>>0)Z();d=c[o+4>>2]|0;if(!(d&1))Z();if(!(d&2)){a=c[8855]|0;if((o|0)==(c[8856]|0)){q=(c[8853]|0)+f|0;c[8853]=q;c[8856]=r;c[r+4>>2]=q|1;if((r|0)!=(a|0))return;c[8855]=0;c[8852]=0;return}if((o|0)==(a|0)){q=(c[8852]|0)+f|0;c[8852]=q;c[8855]=m;c[r+4>>2]=q|1;c[m+q>>2]=q;return}f=(d&-8)+f|0;b:do if(d>>>0>=256){g=c[o+24>>2]|0;a=c[o+12>>2]|0;do if((a|0)==(o|0)){a=c[o+16+4>>2]|0;if(!a){a=c[o+16>>2]|0;if(!a){n=0;break}else e=o+16|0}else e=o+16+4|0;while(1){b=a+20|0;d=c[b>>2]|0;if(d|0){a=d;e=b;continue}b=a+16|0;d=c[b>>2]|0;if(!d)break;else{a=d;e=b}}if(e>>>0<(c[8854]|0)>>>0)Z();else{c[e>>2]=0;n=a;break}}else{b=c[o+8>>2]|0;if(b>>>0<(c[8854]|0)>>>0)Z();if((c[b+12>>2]|0)!=(o|0))Z();if((c[a+8>>2]|0)==(o|0)){c[b+12>>2]=a;c[a+8>>2]=b;n=a;break}else Z()}while(0);if(g|0){a=c[o+28>>2]|0;do if((o|0)==(c[35704+(a<<2)>>2]|0)){c[35704+(a<<2)>>2]=n;if(!n){c[8851]=c[8851]&~(1<<a);break b}}else if(g>>>0>=(c[8854]|0)>>>0){c[g+16+(((c[g+16>>2]|0)!=(o|0)&1)<<2)>>2]=n;if(!n)break b;else break}else Z();while(0);b=c[8854]|0;if(n>>>0<b>>>0)Z();c[n+24>>2]=g;a=c[o+16>>2]|0;do if(a|0)if(a>>>0<b>>>0)Z();else{c[n+16>>2]=a;c[a+24>>2]=n;break}while(0);a=c[o+16+4>>2]|0;if(a|0)if(a>>>0<(c[8854]|0)>>>0)Z();else{c[n+20>>2]=a;c[a+24>>2]=n;break}}}else{a=c[o+8>>2]|0;b=c[o+12>>2]|0;if((a|0)!=(35440+(d>>>3<<1<<2)|0)){if(a>>>0<(c[8854]|0)>>>0)Z();if((c[a+12>>2]|0)!=(o|0))Z()}if((b|0)==(a|0)){c[8850]=c[8850]&~(1<<(d>>>3));break}if((b|0)!=(35440+(d>>>3<<1<<2)|0)){if(b>>>0<(c[8854]|0)>>>0)Z();if((c[b+8>>2]|0)!=(o|0))Z();else l=b+8|0}else l=b+8|0;c[a+12>>2]=b;c[l>>2]=a}while(0);c[r+4>>2]=f|1;c[m+f>>2]=f;if((r|0)==(c[8855]|0)){c[8852]=f;return}}else{c[o+4>>2]=d&-2;c[r+4>>2]=f|1;c[m+f>>2]=f}b=f>>>3;if(f>>>0<256){a=c[8850]|0;if(a&1<<b){a=c[35440+(b<<1<<2)+8>>2]|0;if(a>>>0<(c[8854]|0)>>>0)Z();else{p=a;q=35440+(b<<1<<2)+8|0}}else{c[8850]=a|1<<b;p=35440+(b<<1<<2)|0;q=35440+(b<<1<<2)+8|0}c[q>>2]=r;c[p+12>>2]=r;c[r+8>>2]=p;c[r+12>>2]=35440+(b<<1<<2);return}a=f>>>8;if(a)if(f>>>0>16777215)a=31;else{q=a<<((a+1048320|0)>>>16&8)<<(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4);a=14-(((a<<((a+1048320|0)>>>16&8))+520192|0)>>>16&4|(a+1048320|0)>>>16&8|(q+245760|0)>>>16&2)+(q<<((q+245760|0)>>>16&2)>>>15)|0;a=f>>>(a+7|0)&1|a<<1}else a=0;e=35704+(a<<2)|0;c[r+28>>2]=a;c[r+20>>2]=0;c[r+16>>2]=0;b=c[8851]|0;d=1<<a;do if(b&d){b=f<<((a|0)==31?0:25-(a>>>1)|0);e=c[e>>2]|0;while(1){if((c[e+4>>2]&-8|0)==(f|0)){a=124;break}d=e+16+(b>>>31<<2)|0;a=c[d>>2]|0;if(!a){a=121;break}else{b=b<<1;e=a}}if((a|0)==121)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[d>>2]=r;c[r+24>>2]=e;c[r+12>>2]=r;c[r+8>>2]=r;break}else if((a|0)==124){a=e+8|0;b=c[a>>2]|0;q=c[8854]|0;if(b>>>0>=q>>>0&e>>>0>=q>>>0){c[b+12>>2]=r;c[a>>2]=r;c[r+8>>2]=b;c[r+12>>2]=e;c[r+24>>2]=0;break}else Z()}}else{c[8851]=b|d;c[e>>2]=r;c[r+24>>2]=e;c[r+12>>2]=r;c[r+8>>2]=r}while(0);r=(c[8858]|0)+-1|0;c[8858]=r;if(!r)a=35856;else return;while(1){a=c[a>>2]|0;if(!a)break;else a=a+8|0}c[8858]=-1;return}function sa(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0;d=c[a+4>>2]|0;a:do if(!(d&1)){l=c[a>>2]|0;if(!(d&3))return;j=c[8854]|0;if((a+(0-l)|0)>>>0<j>>>0)Z();if((a+(0-l)|0)==(c[8855]|0)){d=c[a+b+4>>2]|0;if((d&3|0)!=3){q=a+(0-l)|0;h=l+b|0;break}c[8852]=l+b;c[a+b+4>>2]=d&-2;c[a+(0-l)+4>>2]=l+b|1;c[a+(0-l)+(l+b)>>2]=l+b;return}if(l>>>0<256){d=c[a+(0-l)+8>>2]|0;e=c[a+(0-l)+12>>2]|0;if((d|0)!=(35440+(l>>>3<<1<<2)|0)){if(d>>>0<j>>>0)Z();if((c[d+12>>2]|0)!=(a+(0-l)|0))Z()}if((e|0)==(d|0)){c[8850]=c[8850]&~(1<<(l>>>3));q=a+(0-l)|0;h=l+b|0;break}if((e|0)!=(35440+(l>>>3<<1<<2)|0)){if(e>>>0<j>>>0)Z();if((c[e+8>>2]|0)!=(a+(0-l)|0))Z();else f=e+8|0}else f=e+8|0;c[d+12>>2]=e;c[f>>2]=d;q=a+(0-l)|0;h=l+b|0;break}i=c[a+(0-l)+24>>2]|0;d=c[a+(0-l)+12>>2]|0;do if((d|0)==(a+(0-l)|0)){e=a+(0-l)+16|0;d=c[e+4>>2]|0;if(!d){d=c[e>>2]|0;if(!d){k=0;break}}else e=e+4|0;while(1){f=d+20|0;g=c[f>>2]|0;if(g|0){d=g;e=f;continue}f=d+16|0;g=c[f>>2]|0;if(!g)break;else{d=g;e=f}}if(e>>>0<j>>>0)Z();else{c[e>>2]=0;k=d;break}}else{e=c[a+(0-l)+8>>2]|0;if(e>>>0<j>>>0)Z();if((c[e+12>>2]|0)!=(a+(0-l)|0))Z();if((c[d+8>>2]|0)==(a+(0-l)|0)){c[e+12>>2]=d;c[d+8>>2]=e;k=d;break}else Z()}while(0);if(i){d=c[a+(0-l)+28>>2]|0;do if((a+(0-l)|0)==(c[35704+(d<<2)>>2]|0)){c[35704+(d<<2)>>2]=k;if(!k){c[8851]=c[8851]&~(1<<d);q=a+(0-l)|0;h=l+b|0;break a}}else if(i>>>0>=(c[8854]|0)>>>0){c[i+16+(((c[i+16>>2]|0)!=(a+(0-l)|0)&1)<<2)>>2]=k;if(!k){q=a+(0-l)|0;h=l+b|0;break a}else break}else Z();while(0);e=c[8854]|0;if(k>>>0<e>>>0)Z();c[k+24>>2]=i;d=c[a+(0-l)+16>>2]|0;do if(d|0)if(d>>>0<e>>>0)Z();else{c[k+16>>2]=d;c[d+24>>2]=k;break}while(0);d=c[a+(0-l)+16+4>>2]|0;if(d)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[k+20>>2]=d;c[d+24>>2]=k;q=a+(0-l)|0;h=l+b|0;break}else{q=a+(0-l)|0;h=l+b|0}}else{q=a+(0-l)|0;h=l+b|0}}else{q=a;h=b}while(0);j=c[8854]|0;if((a+b|0)>>>0<j>>>0)Z();f=c[a+b+4>>2]|0;if(!(f&2)){d=c[8855]|0;if((a+b|0)==(c[8856]|0)){p=(c[8853]|0)+h|0;c[8853]=p;c[8856]=q;c[q+4>>2]=p|1;if((q|0)!=(d|0))return;c[8855]=0;c[8852]=0;return}if((a+b|0)==(d|0)){p=(c[8852]|0)+h|0;c[8852]=p;c[8855]=q;c[q+4>>2]=p|1;c[q+p>>2]=p;return}h=(f&-8)+h|0;b:do if(f>>>0>=256){i=c[a+b+24>>2]|0;d=c[a+b+12>>2]|0;do if((d|0)==(a+b|0)){d=c[a+b+16+4>>2]|0;if(!d){d=c[a+b+16>>2]|0;if(!d){n=0;break}else g=a+b+16|0}else g=a+b+16+4|0;while(1){e=d+20|0;f=c[e>>2]|0;if(f|0){d=f;g=e;continue}e=d+16|0;f=c[e>>2]|0;if(!f)break;else{d=f;g=e}}if(g>>>0<j>>>0)Z();else{c[g>>2]=0;n=d;break}}else{e=c[a+b+8>>2]|0;if(e>>>0<j>>>0)Z();if((c[e+12>>2]|0)!=(a+b|0))Z();if((c[d+8>>2]|0)==(a+b|0)){c[e+12>>2]=d;c[d+8>>2]=e;n=d;break}else Z()}while(0);if(i|0){d=c[a+b+28>>2]|0;do if((a+b|0)==(c[35704+(d<<2)>>2]|0)){c[35704+(d<<2)>>2]=n;if(!n){c[8851]=c[8851]&~(1<<d);break b}}else if(i>>>0>=(c[8854]|0)>>>0){c[i+16+(((c[i+16>>2]|0)!=(a+b|0)&1)<<2)>>2]=n;if(!n)break b;else break}else Z();while(0);e=c[8854]|0;if(n>>>0<e>>>0)Z();c[n+24>>2]=i;d=c[a+b+16>>2]|0;do if(d|0)if(d>>>0<e>>>0)Z();else{c[n+16>>2]=d;c[d+24>>2]=n;break}while(0);d=c[a+b+16+4>>2]|0;if(d|0)if(d>>>0<(c[8854]|0)>>>0)Z();else{c[n+20>>2]=d;c[d+24>>2]=n;break}}}else{d=c[a+b+8>>2]|0;e=c[a+b+12>>2]|0;if((d|0)!=(35440+(f>>>3<<1<<2)|0)){if(d>>>0<j>>>0)Z();if((c[d+12>>2]|0)!=(a+b|0))Z()}if((e|0)==(d|0)){c[8850]=c[8850]&~(1<<(f>>>3));break}if((e|0)!=(35440+(f>>>3<<1<<2)|0)){if(e>>>0<j>>>0)Z();if((c[e+8>>2]|0)!=(a+b|0))Z();else m=e+8|0}else m=e+8|0;c[d+12>>2]=e;c[m>>2]=d}while(0);c[q+4>>2]=h|1;c[q+h>>2]=h;if((q|0)==(c[8855]|0)){c[8852]=h;return}}else{c[a+b+4>>2]=f&-2;c[q+4>>2]=h|1;c[q+h>>2]=h}e=h>>>3;if(h>>>0<256){d=c[8850]|0;if(d&1<<e){d=c[35440+(e<<1<<2)+8>>2]|0;if(d>>>0<(c[8854]|0)>>>0)Z();else{o=d;p=35440+(e<<1<<2)+8|0}}else{c[8850]=d|1<<e;o=35440+(e<<1<<2)|0;p=35440+(e<<1<<2)+8|0}c[p>>2]=q;c[o+12>>2]=q;c[q+8>>2]=o;c[q+12>>2]=35440+(e<<1<<2);return}d=h>>>8;if(d)if(h>>>0>16777215)d=31;else{p=d<<((d+1048320|0)>>>16&8)<<(((d<<((d+1048320|0)>>>16&8))+520192|0)>>>16&4);d=14-(((d<<((d+1048320|0)>>>16&8))+520192|0)>>>16&4|(d+1048320|0)>>>16&8|(p+245760|0)>>>16&2)+(p<<((p+245760|0)>>>16&2)>>>15)|0;d=h>>>(d+7|0)&1|d<<1}else d=0;g=35704+(d<<2)|0;c[q+28>>2]=d;c[q+20>>2]=0;c[q+16>>2]=0;e=c[8851]|0;f=1<<d;if(!(e&f)){c[8851]=e|f;c[g>>2]=q;c[q+24>>2]=g;c[q+12>>2]=q;c[q+8>>2]=q;return}e=h<<((d|0)==31?0:25-(d>>>1)|0);g=c[g>>2]|0;while(1){if((c[g+4>>2]&-8|0)==(h|0)){d=121;break}f=g+16+(e>>>31<<2)|0;d=c[f>>2]|0;if(!d){d=118;break}else{e=e<<1;g=d}}if((d|0)==118){if(f>>>0<(c[8854]|0)>>>0)Z();c[f>>2]=q;c[q+24>>2]=g;c[q+12>>2]=q;c[q+8>>2]=q;return}else if((d|0)==121){d=g+8|0;e=c[d>>2]|0;p=c[8854]|0;if(!(e>>>0>=p>>>0&g>>>0>=p>>>0))Z();c[e+12>>2]=q;c[d>>2]=q;c[q+8>>2]=e;c[q+12>>2]=g;c[q+24>>2]=0;return}}function ta(a,b,c,e,f){a=a|0;b=b|0;c=c|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0;m=Te(f)|0;o=z;g=Te(f+8|0)|0;h=z;e=vf(c|0,e|0,56)|0;f=z;if((b+c+(0-(c&7))|0)==(b|0)){q=g^2037671283;j=h^1952801890;n=m^1886610805;k=o^1936682341;i=g^1852075907;r=h^1685025377;h=m^1852142177;g=o^1819895653}else{s=b;q=g^2037671283;j=h^1952801890;n=m^1886610805;l=o^1936682341;k=g^1852075907;i=h^1685025377;h=m^1852142177;g=o^1819895653;while(1){p=Te(s)|0;t=z;v=p^q;j=t^j;l=fg(n|0,l|0,k|0,i|0)|0;r=z;n=_e(k,i,13)|0;k=z^r;r=_e(l,r,32)|0;q=z;m=fg(v|0,j|0,h|0,g|0)|0;o=z;j=_e(v,j,16)|0;i=z^o;q=fg(j^m|0,i|0,r|0,q|0)|0;r=z;i=_e(j^m,i,21)|0;j=r^z;o=fg(m|0,o|0,n^l|0,k|0)|0;m=z;k=_e(n^l,k,17)|0;g=z^m;m=_e(o,m,32)|0;h=z;r=fg(k^o|0,g|0,q|0,r|0)|0;l=z;g=_e(k^o,g,13)|0;o=z^l;l=_e(r,l,32)|0;k=z;h=fg(m|0,h|0,q^i|0,j|0)|0;m=z;j=_e(q^i,j,16)|0;i=z^m;k=fg(j^h|0,i|0,l|0,k|0)|0;l=z;i=_e(j^h,i,21)|0;j=l^z;m=fg(g^r|0,o|0,h|0,m|0)|0;h=z;o=_e(g^r,o,17)|0;r=z^h;h=_e(m,h,32)|0;g=z;s=s+8|0;if((s|0)==(b+c+(0-(c&7))|0)){b=b+c+(0-(c&7))|0;q=k^i;n=k^p;k=l^t;i=o^m;break}else{q=k^i;n=k^p;l=l^t;k=o^m;i=r}}}switch(c&7){case 7:{e=vf(d[b+6>>0]|0|0,0,48)|0|e;f=z|f;u=5;break}case 6:{u=5;break}case 5:{u=6;break}case 4:{u=7;break}case 3:{u=8;break}case 2:{u=9;break}case 1:{u=10;break}default:{}}if((u|0)==5){v=vf(d[b+5>>0]|0|0,0,40)|0;f=z|f;e=v|e;u=6}if((u|0)==6){f=d[b+4>>0]|0|f;u=7}if((u|0)==7){v=vf(d[b+3>>0]|0|0,0,24)|0;e=v|e;f=z|f;u=8}if((u|0)==8){v=vf(d[b+2>>0]|0|0,0,16)|0;e=v|e;f=z|f;u=9}if((u|0)==9){v=vf(d[b+1>>0]|0|0,0,8)|0;e=v|e;f=z|f;u=10}if((u|0)==10)e=d[b>>0]|0|e;t=e^q;c=f^j;b=fg(n|0,k|0,i|0,r|0)|0;v=z;u=_e(i,r,13)|0;o=z^v;v=_e(b,v,32)|0;q=z;s=fg(t|0,c|0,h|0,g|0)|0;p=z;r=_e(t,c,16)|0;c=z^p;q=fg(r^s|0,c|0,v|0,q|0)|0;v=z;c=_e(r^s,c,21)|0;r=v^z;p=fg(s|0,p|0,u^b|0,o|0)|0;s=z;o=_e(u^b,o,17)|0;b=z^s;s=_e(p,s,32)|0;u=z;v=fg(o^p|0,b|0,q|0,v|0)|0;t=z;b=_e(o^p,b,13)|0;p=z^t;t=_e(v,t,32)|0;o=z;u=fg(s|0,u|0,q^c|0,r|0)|0;s=z;r=_e(q^c,r,16)|0;c=z^s;o=fg(r^u|0,c|0,t|0,o|0)|0;t=z;c=_e(r^u,c,21)|0;r=t^z;s=fg(b^v|0,p|0,u|0,s|0)|0;u=z;p=_e(b^v,p,17)|0;v=z^u;u=_e(s,u,32)|0;b=z;t=fg(o^e|0,t^f|0,p^s|0,v|0)|0;q=z;v=_e(p^s,v,13)|0;s=z^q;q=_e(t,q,32)|0;p=z;b=fg(u^238|0,b|0,o^c|0,r|0)|0;u=z;r=_e(o^c,r,16)|0;c=z^u;p=fg(r^b|0,c|0,q|0,p|0)|0;q=z;c=_e(r^b,c,21)|0;r=q^z;u=fg(b|0,u|0,v^t|0,s|0)|0;b=z;s=_e(v^t,s,17)|0;t=z^b;b=_e(u,b,32)|0;v=z;q=fg(s^u|0,t|0,p|0,q|0)|0;o=z;t=_e(s^u,t,13)|0;u=z^o;o=_e(q,o,32)|0;s=z;v=fg(b|0,v|0,p^c|0,r|0)|0;b=z;r=_e(p^c,r,16)|0;c=z^b;s=fg(r^v|0,c|0,o|0,s|0)|0;o=z;c=_e(r^v,c,21)|0;r=o^z;b=fg(t^q|0,u|0,v|0,b|0)|0;v=z;u=_e(t^q,u,17)|0;q=z^v;v=_e(b,v,32)|0;t=z;o=fg(u^b|0,q|0,s|0,o|0)|0;p=z;q=_e(u^b,q,13)|0;b=z^p;p=_e(o,p,32)|0;u=z;t=fg(v|0,t|0,s^c|0,r|0)|0;v=z;r=_e(s^c,r,16)|0;c=z^v;u=fg(r^t|0,c|0,p|0,u|0)|0;p=z;c=_e(r^t,c,21)|0;r=p^z;v=fg(q^o|0,b|0,t|0,v|0)|0;t=z;b=_e(q^o,b,17)|0;o=z^t;t=_e(v,t,32)|0;q=z;p=fg(b^v|0,o|0,u|0,p|0)|0;s=z;o=_e(b^v,o,13)|0;v=z^s;s=_e(p,s,32)|0;b=z;q=fg(t|0,q|0,u^c|0,r|0)|0;t=z;r=_e(u^c,r,16)|0;c=z^t;b=fg(r^q|0,c|0,s|0,b|0)|0;s=z;c=_e(r^q,c,21)|0;r=s^z;t=fg(o^p|0,v|0,q|0,t|0)|0;q=z;v=_e(o^p,v,17)|0;p=z^q;q=_e(t,q,32)|0;o=z;re(a,v^t^b^q^(b^c),p^s^o^r);s=fg(v^t^221|0,p|0,b|0,s|0)|0;u=z;p=_e(v^t^221,p,13)|0;t=z^u;u=_e(s,u,32)|0;v=z;o=fg(q|0,o|0,b^c|0,r|0)|0;q=z;r=_e(b^c,r,16)|0;c=z^q;v=fg(r^o|0,c|0,u|0,v|0)|0;u=z;c=_e(r^o,c,21)|0;r=u^z;q=fg(p^s|0,t|0,o|0,q|0)|0;o=z;t=_e(p^s,t,17)|0;s=z^o;o=_e(q,o,32)|0;p=z;u=fg(t^q|0,s|0,v|0,u|0)|0;b=z;s=_e(t^q,s,13)|0;q=z^b;b=_e(u,b,32)|0;t=z;p=fg(o|0,p|0,v^c|0,r|0)|0;o=z;r=_e(v^c,r,16)|0;c=z^o;t=fg(r^p|0,c|0,b|0,t|0)|0;b=z;c=_e(r^p,c,21)|0;r=b^z;o=fg(s^u|0,q|0,p|0,o|0)|0;p=z;q=_e(s^u,q,17)|0;u=z^p;p=_e(o,p,32)|0;s=z;b=fg(q^o|0,u|0,t|0,b|0)|0;v=z;u=_e(q^o,u,13)|0;o=z^v;v=_e(b,v,32)|0;q=z;s=fg(p|0,s|0,t^c|0,r|0)|0;p=z;r=_e(t^c,r,16)|0;c=z^p;q=fg(r^s|0,c|0,v|0,q|0)|0;v=z;c=_e(r^s,c,21)|0;r=v^z;p=fg(u^b|0,o|0,s|0,p|0)|0;s=z;o=_e(u^b,o,17)|0;b=z^s;s=_e(p,s,32)|0;u=z;v=fg(o^p|0,b|0,q|0,v|0)|0;t=z;b=_e(o^p,b,13)|0;t=z^t;u=fg(s|0,u|0,q^c|0,r|0)|0;s=z;r=_e(q^c,r,16)|0;r=_e(r^u,z^s,21)|0;c=z;s=fg(b^v|0,t|0,u|0,s|0)|0;u=z;t=_e(b^v,t,17)|0;v=z;b=_e(s,u,32)|0;re(a+8|0,r^s^t^b,c^u^v^z);return 0}function ua(a,b,c,e,f){a=a|0;b=b|0;c=c|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0;m=Te(f)|0;o=z;g=Te(f+8|0)|0;h=z;e=vf(c|0,e|0,56)|0;f=z;if((b+c+(0-(c&7))|0)==(b|0)){q=g^2037671283;j=h^1952801890;n=m^1886610805;k=o^1936682341;i=g^1852075885;r=h^1685025377;h=m^1852142177;g=o^1819895653}else{s=b;q=g^2037671283;j=h^1952801890;n=m^1886610805;l=o^1936682341;k=g^1852075885;i=h^1685025377;h=m^1852142177;g=o^1819895653;while(1){p=Te(s)|0;t=z;v=p^q;j=t^j;l=fg(n|0,l|0,k|0,i|0)|0;r=z;n=_e(k,i,13)|0;k=z^r;r=_e(l,r,32)|0;q=z;m=fg(v|0,j|0,h|0,g|0)|0;o=z;j=_e(v,j,16)|0;i=z^o;q=fg(j^m|0,i|0,r|0,q|0)|0;r=z;i=_e(j^m,i,21)|0;j=r^z;o=fg(m|0,o|0,n^l|0,k|0)|0;m=z;k=_e(n^l,k,17)|0;g=z^m;m=_e(o,m,32)|0;h=z;r=fg(k^o|0,g|0,q|0,r|0)|0;l=z;g=_e(k^o,g,13)|0;o=z^l;l=_e(r,l,32)|0;k=z;h=fg(m|0,h|0,q^i|0,j|0)|0;m=z;j=_e(q^i,j,16)|0;i=z^m;k=fg(j^h|0,i|0,l|0,k|0)|0;l=z;i=_e(j^h,i,21)|0;j=l^z;m=fg(g^r|0,o|0,h|0,m|0)|0;h=z;o=_e(g^r,o,17)|0;r=z^h;h=_e(m,h,32)|0;g=z;s=s+8|0;if((s|0)==(b+c+(0-(c&7))|0)){b=b+c+(0-(c&7))|0;q=k^i;n=k^p;k=l^t;i=o^m;break}else{q=k^i;n=k^p;l=l^t;k=o^m;i=r}}}switch(c&7){case 7:{e=vf(d[b+6>>0]|0|0,0,48)|0|e;f=z|f;u=5;break}case 6:{u=5;break}case 5:{u=6;break}case 4:{u=7;break}case 3:{u=8;break}case 2:{u=9;break}case 1:{u=10;break}default:{}}if((u|0)==5){v=vf(d[b+5>>0]|0|0,0,40)|0;f=z|f;e=v|e;u=6}if((u|0)==6){f=d[b+4>>0]|0|f;u=7}if((u|0)==7){v=vf(d[b+3>>0]|0|0,0,24)|0;e=v|e;f=z|f;u=8}if((u|0)==8){v=vf(d[b+2>>0]|0|0,0,16)|0;e=v|e;f=z|f;u=9}if((u|0)==9){v=vf(d[b+1>>0]|0|0,0,8)|0;e=v|e;f=z|f;u=10}if((u|0)==10)e=d[b>>0]|0|e;s=e^q;c=f^j;o=fg(n|0,k|0,i|0,r|0)|0;p=z;q=_e(i,r,13)|0;b=z^p;p=_e(o,p,32)|0;u=z;t=fg(s|0,c|0,h|0,g|0)|0;v=z;r=_e(s,c,16)|0;c=z^v;u=fg(r^t|0,c|0,p|0,u|0)|0;p=z;c=_e(r^t,c,21)|0;r=p^z;v=fg(t|0,v|0,q^o|0,b|0)|0;t=z;b=_e(q^o,b,17)|0;o=z^t;t=_e(v,t,32)|0;q=z;p=fg(b^v|0,o|0,u|0,p|0)|0;s=z;o=_e(b^v,o,13)|0;v=z^s;s=_e(p,s,32)|0;b=z;q=fg(t|0,q|0,u^c|0,r|0)|0;t=z;r=_e(u^c,r,16)|0;c=z^t;b=fg(r^q|0,c|0,s|0,b|0)|0;s=z;c=_e(r^q,c,21)|0;r=s^z;t=fg(o^p|0,v|0,q|0,t|0)|0;q=z;v=_e(o^p,v,17)|0;p=z^q;q=_e(t,q,32)|0;o=z;s=fg(b^e|0,s^f|0,v^t|0,p|0)|0;u=z;p=_e(v^t,p,13)|0;t=z^u;u=_e(s,u,32)|0;v=z;o=fg(q^255|0,o|0,b^c|0,r|0)|0;q=z;r=_e(b^c,r,16)|0;c=z^q;v=fg(r^o|0,c|0,u|0,v|0)|0;u=z;c=_e(r^o,c,21)|0;r=u^z;q=fg(o|0,q|0,p^s|0,t|0)|0;o=z;t=_e(p^s,t,17)|0;s=z^o;o=_e(q,o,32)|0;p=z;u=fg(t^q|0,s|0,v|0,u|0)|0;b=z;s=_e(t^q,s,13)|0;q=z^b;b=_e(u,b,32)|0;t=z;p=fg(o|0,p|0,v^c|0,r|0)|0;o=z;r=_e(v^c,r,16)|0;c=z^o;t=fg(r^p|0,c|0,b|0,t|0)|0;b=z;c=_e(r^p,c,21)|0;r=b^z;o=fg(s^u|0,q|0,p|0,o|0)|0;p=z;q=_e(s^u,q,17)|0;u=z^p;p=_e(o,p,32)|0;s=z;b=fg(q^o|0,u|0,t|0,b|0)|0;v=z;u=_e(q^o,u,13)|0;o=z^v;v=_e(b,v,32)|0;q=z;s=fg(p|0,s|0,t^c|0,r|0)|0;p=z;r=_e(t^c,r,16)|0;c=z^p;q=fg(r^s|0,c|0,v|0,q|0)|0;v=z;c=_e(r^s,c,21)|0;r=v^z;p=fg(u^b|0,o|0,s|0,p|0)|0;s=z;o=_e(u^b,o,17)|0;b=z^s;s=_e(p,s,32)|0;u=z;v=fg(o^p|0,b|0,q|0,v|0)|0;t=z;b=_e(o^p,b,13)|0;t=z^t;u=fg(s|0,u|0,q^c|0,r|0)|0;s=z;r=_e(q^c,r,16)|0;r=_e(r^u,z^s,21)|0;c=z;s=fg(b^v|0,t|0,u|0,s|0)|0;u=z;t=_e(b^v,t,17)|0;v=z;b=_e(s,u,32)|0;re(a,r^s^t^b,c^u^v^z);return 0}function va(b,d,e,f,g){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0,O=0,P=0,Q=0,R=0,S=0,T=0,U=0,V=0,W=0,X=0,Y=0,_=0,$=0,aa=0,ba=0,ca=0,da=0,ea=0,fa=0,ga=0,ha=0,ia=0,ja=0,ka=0,la=0,ma=0,na=0,oa=0;T=l;S=l=l+63&-64;l=l+64|0;if(!((f|0)==0&(g|0)==0)){if(g>>>0>63|(g|0)==63&f>>>0>4294967232)Z();E=c[b>>2]|0;F=c[b+4>>2]|0;G=c[b+8>>2]|0;H=c[b+12>>2]|0;I=c[b+16>>2]|0;J=c[b+20>>2]|0;K=c[b+24>>2]|0;L=c[b+28>>2]|0;M=c[b+32>>2]|0;N=c[b+36>>2]|0;O=c[b+40>>2]|0;P=c[b+44>>2]|0;Q=c[b+56>>2]|0;R=c[b+60>>2]|0;h=0;B=c[b+52>>2]|0;y=c[b+48>>2]|0;C=g;D=f;while(1){A=C>>>0<0|(C|0)==0&D>>>0<64;if(A){g=S;f=g+64|0;do{a[g>>0]=0;g=g+1|0}while((g|0)<(f|0));g=0;do{a[S+g>>0]=a[d+g>>0]|0;g=g+1|0}while(0<C>>>0|0==(C|0)&g>>>0<D>>>0);h=e;d=S;e=S}g=E;f=F;i=G;j=H;k=I;m=J;n=K;o=L;p=M;q=N;r=O;s=R;t=Q;u=B;v=y;w=P;x=20;do{ma=g+k|0;ba=xh(ma^v,16)|0;aa=ba+p|0;na=xh(aa^k,12)|0;ba=xh(na+ma^ba,8)|0;Y=xh(ba+aa^na,7)|0;ia=f+m|0;W=xh(ia^u,16)|0;V=W+q|0;ja=xh(V^m,12)|0;W=xh(ja+ia^W,8)|0;oa=xh(W+V^ja,7)|0;da=i+n|0;X=xh(da^t,16)|0;ca=X+r|0;ea=xh(ca^n,12)|0;X=xh(ea+da^X,8)|0;ka=xh(X+ca^ea,7)|0;_=j+o|0;ga=xh(_^s,16)|0;U=ga+w|0;$=xh(U^o,12)|0;ga=xh($+_^ga,8)|0;fa=xh(ga+U^$,7)|0;la=xh(ga^oa+(na+ma),16)|0;ha=xh(la+(X+ca)^oa,12)|0;g=ha+(oa+(na+ma))|0;s=xh(g^la,8)|0;r=s+(la+(X+ca))|0;m=xh(r^ha,7)|0;ha=xh(ka+(ja+ia)^ba,16)|0;ca=xh(ha+(ga+U)^ka,12)|0;f=ca+(ka+(ja+ia))|0;v=xh(f^ha,8)|0;w=v+(ha+(ga+U))|0;n=xh(w^ca,7)|0;ca=xh(fa+(ea+da)^W,16)|0;U=xh(ca+(ba+aa)^fa,12)|0;i=U+(fa+(ea+da))|0;u=xh(i^ca,8)|0;p=u+(ca+(ba+aa))|0;o=xh(p^U,7)|0;X=xh($+_+Y^X,16)|0;U=xh(X+(W+V)^Y,12)|0;j=U+($+_+Y)|0;t=xh(j^X,8)|0;q=t+(X+(W+V))|0;k=xh(q^U,7)|0;x=x+-2|0}while((x|0)!=0);$=(Rg(d)|0)^g+E;aa=(Rg(d+4|0)|0)^f+F;ba=(Rg(d+8|0)|0)^i+G;ca=(Rg(d+12|0)|0)^j+H;da=(Rg(d+16|0)|0)^k+I;ea=(Rg(d+20|0)|0)^m+J;fa=(Rg(d+24|0)|0)^n+K;ga=(Rg(d+28|0)|0)^o+L;ha=(Rg(d+32|0)|0)^p+M;ia=(Rg(d+36|0)|0)^q+N;ja=(Rg(d+40|0)|0)^r+O;ka=(Rg(d+44|0)|0)^w+P;la=(Rg(d+48|0)|0)^v+y;ma=(Rg(d+52|0)|0)^u+B;na=(Rg(d+56|0)|0)^t+Q;oa=(Rg(d+60|0)|0)^s+R;f=y+1|0;g=((f|0)==0&1)+B|0;jg(e,$);jg(e+4|0,aa);jg(e+8|0,ba);jg(e+12|0,ca);jg(e+16|0,da);jg(e+20|0,ea);jg(e+24|0,fa);jg(e+28|0,ga);jg(e+32|0,ha);jg(e+36|0,ia);jg(e+40|0,ja);jg(e+44|0,ka);jg(e+48|0,la);jg(e+52|0,ma);jg(e+56|0,na);jg(e+60|0,oa);if(C>>>0<0|(C|0)==0&D>>>0<65)break;oa=fg(D|0,C|0,-64,-1)|0;d=d+64|0;e=e+64|0;B=g;y=f;C=z;D=oa}if(A?D|0:0){d=0;do{a[h+d>>0]=a[e+d>>0]|0;d=d+1|0}while((d|0)!=(D|0))}c[b+48>>2]=f;c[b+52>>2]=g}l=T;return}function wa(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0;s=a[b+80>>0]|0?0:16777216;t=c[b+4>>2]|0;o=c[b+8>>2]|0;p=c[b+12>>2]|0;q=c[b+16>>2]|0;k=c[b+20>>2]|0;j=c[b+24>>2]|0;i=c[b+28>>2]|0;h=c[b+32>>2]|0;g=c[b+36>>2]|0;if(f>>>0>0|(f|0)==0&e>>>0>15){r=c[b>>2]|0;m=e;while(1){y=((Rg(d)|0)&67108863)+k|0;A=((Rg(d+3|0)|0)>>>2&67108863)+j|0;x=((Rg(d+6|0)|0)>>>4&67108863)+i|0;w=((Rg(d+9|0)|0)>>>6)+h|0;k=((Rg(d+12|0)|0)>>>8|s)+g|0;g=af(y|0,0,r|0,0)|0;e=z;i=af(A|0,0,q*5|0,0)|0;e=fg(i|0,z|0,g|0,e|0)|0;g=z;i=af(x|0,0,p*5|0,0)|0;i=fg(e|0,g|0,i|0,z|0)|0;g=z;e=af(w|0,0,o*5|0,0)|0;e=fg(i|0,g|0,e|0,z|0)|0;g=z;i=af(k|0,0,t*5|0,0)|0;i=fg(e|0,g|0,i|0,z|0)|0;g=z;e=af(y|0,0,t|0,0)|0;l=z;v=af(A|0,0,r|0,0)|0;l=fg(v|0,z|0,e|0,l|0)|0;e=z;v=af(x|0,0,q*5|0,0)|0;v=fg(l|0,e|0,v|0,z|0)|0;e=z;l=af(w|0,0,p*5|0,0)|0;l=fg(v|0,e|0,l|0,z|0)|0;e=z;v=af(k|0,0,o*5|0,0)|0;v=fg(l|0,e|0,v|0,z|0)|0;e=z;l=af(y|0,0,o|0,0)|0;n=z;u=af(A|0,0,t|0,0)|0;n=fg(u|0,z|0,l|0,n|0)|0;l=z;u=af(x|0,0,r|0,0)|0;u=fg(n|0,l|0,u|0,z|0)|0;l=z;n=af(w|0,0,q*5|0,0)|0;n=fg(u|0,l|0,n|0,z|0)|0;l=z;u=af(k|0,0,p*5|0,0)|0;u=fg(n|0,l|0,u|0,z|0)|0;l=z;n=af(y|0,0,p|0,0)|0;h=z;j=af(A|0,0,o|0,0)|0;h=fg(j|0,z|0,n|0,h|0)|0;n=z;j=af(x|0,0,t|0,0)|0;j=fg(h|0,n|0,j|0,z|0)|0;n=z;h=af(w|0,0,r|0,0)|0;h=fg(j|0,n|0,h|0,z|0)|0;n=z;j=af(k|0,0,q*5|0,0)|0;j=fg(h|0,n|0,j|0,z|0)|0;n=z;h=af(y|0,0,q|0,0)|0;y=z;A=af(A|0,0,p|0,0)|0;y=fg(A|0,z|0,h|0,y|0)|0;h=z;x=af(x|0,0,o|0,0)|0;x=fg(y|0,h|0,x|0,z|0)|0;h=z;w=af(w|0,0,t|0,0)|0;w=fg(x|0,h|0,w|0,z|0)|0;h=z;k=af(k|0,0,r|0,0)|0;k=fg(w|0,h|0,k|0,z|0)|0;h=z;g=yf(i|0,g|0,26)|0;g=fg(v|0,e|0,g|0,0)|0;e=yf(g|0,z|0,26)|0;e=fg(u|0,l|0,e|0,0)|0;l=yf(e|0,z|0,26)|0;l=fg(j|0,n|0,l|0,0)|0;n=yf(l|0,z|0,26)|0;n=fg(k|0,h|0,n|0,0)|0;h=yf(n|0,z|0,26)|0;m=fg(m|0,f|0,-16,-1)|0;f=z;if(!(f>>>0>0|(f|0)==0&m>>>0>15)){k=(h*5|0)+i&67108863;j=(((h*5|0)+(i&67108863)|0)>>>26)+(g&67108863)|0;i=e&67108863;h=l&67108863;g=n&67108863;break}else{k=(h*5|0)+i&67108863;j=(((h*5|0)+(i&67108863)|0)>>>26)+(g&67108863)|0;i=e&67108863;h=l&67108863;g=n&67108863;d=d+16|0}}}c[b+20>>2]=k;c[b+24>>2]=j;c[b+28>>2]=i;c[b+32>>2]=h;c[b+36>>2]=g;return}function xa(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,A=0,B=0,C=0;y=Qd(d)|0;k=z;x=df(a[d+4>>0]|0,a[d+5>>0]|0,a[d+6>>0]|0)|0;x=vf(x|0,z|0,6)|0;l=z;w=df(a[d+7>>0]|0,a[d+8>>0]|0,a[d+9>>0]|0)|0;w=vf(w|0,z|0,5)|0;i=z;t=df(a[d+10>>0]|0,a[d+11>>0]|0,a[d+12>>0]|0)|0;t=vf(t|0,z|0,3)|0;j=z;s=df(a[d+13>>0]|0,a[d+14>>0]|0,a[d+15>>0]|0)|0;s=vf(s|0,z|0,2)|0;g=z;f=Qd(d+16|0)|0;h=z;p=df(a[d+20>>0]|0,a[d+21>>0]|0,a[d+22>>0]|0)|0;p=vf(p|0,z|0,7)|0;e=z;v=df(a[d+23>>0]|0,a[d+24>>0]|0,a[d+25>>0]|0)|0;v=vf(v|0,z|0,5)|0;u=z;n=df(a[d+26>>0]|0,a[d+27>>0]|0,a[d+28>>0]|0)|0;n=vf(n|0,z|0,4)|0;o=z;r=df(a[d+29>>0]|0,a[d+30>>0]|0,a[d+31>>0]|0)|0;r=vf(r|0,z|0,2)|0;d=fg(r&33554428|0,0,16777216,0)|0;d=yf(d|0,z|0,25)|0;q=z;A=cg(0,0,d|0,q|0)|0;k=fg(A&19|0,0,y|0,k|0)|0;y=z;q=vf(d|0,q|0,25)|0;d=z;A=fg(x|0,l|0,16777216,0)|0;A=Xe(A|0,z|0,25)|0;C=z;i=fg(A|0,C|0,w|0,i|0)|0;w=z;C=vf(A|0,C|0,25)|0;C=cg(x|0,l|0,C|0,z|0)|0;l=z;x=fg(t|0,j|0,16777216,0)|0;x=Xe(x|0,z|0,25)|0;A=z;g=fg(x|0,A|0,s|0,g|0)|0;s=z;A=vf(x|0,A|0,25)|0;A=cg(t|0,j|0,A|0,z|0)|0;j=z;t=fg(f|0,h|0,16777216,0)|0;t=Xe(t|0,z|0,25)|0;x=z;e=fg(p|0,e|0,t|0,x|0)|0;p=z;x=vf(t|0,x|0,25)|0;x=cg(f|0,h|0,x|0,z|0)|0;h=z;f=fg(v|0,u|0,16777216,0)|0;f=Xe(f|0,z|0,25)|0;t=z;o=fg(f|0,t|0,n|0,o|0)|0;n=z;t=vf(f|0,t|0,25)|0;f=z;B=fg(k|0,y|0,33554432,0)|0;B=Xe(B|0,z|0,26)|0;m=z;l=fg(C|0,l|0,B|0,m|0)|0;m=vf(B|0,m|0,26)|0;m=cg(k|0,y|0,m|0,z|0)|0;y=fg(i|0,w|0,33554432,0)|0;y=Xe(y|0,z|0,26)|0;k=z;j=fg(A|0,j|0,y|0,k|0)|0;k=vf(y|0,k|0,26)|0;k=cg(i|0,w|0,k|0,z|0)|0;w=fg(g|0,s|0,33554432,0)|0;w=Xe(w|0,z|0,26)|0;i=z;h=fg(x|0,h|0,w|0,i|0)|0;i=vf(w|0,i|0,26)|0;i=cg(g|0,s|0,i|0,z|0)|0;s=fg(e|0,p|0,33554432,0)|0;s=Xe(s|0,z|0,26)|0;g=z;u=fg(s|0,g|0,v|0,u|0)|0;f=cg(u|0,z|0,t|0,f|0)|0;g=vf(s|0,g|0,26)|0;g=cg(e|0,p|0,g|0,z|0)|0;p=fg(o|0,n|0,33554432,0)|0;p=Xe(p|0,z|0,26)|0;e=z;r=fg(p|0,e|0,r&33554428|0,0)|0;d=cg(r|0,z|0,q|0,d|0)|0;e=vf(p|0,e|0,26)|0;e=cg(o|0,n|0,e|0,z|0)|0;c[b>>2]=m;c[b+4>>2]=l;c[b+8>>2]=k;c[b+12>>2]=j;c[b+16>>2]=i;c[b+20>>2]=h;c[b+24>>2]=g;c[b+28>>2]=f;c[b+32>>2]=e;c[b+36>>2]=d;return}function ya(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0;u=c[b>>2]|0;t=c[b+4>>2]|0;s=c[b+8>>2]|0;r=c[b+12>>2]|0;q=c[b+16>>2]|0;l=c[b+20>>2]|0;o=c[b+24>>2]|0;w=c[b+28>>2]|0;m=c[b+32>>2]|0;v=c[b+36>>2]|0;u=af(u|0,((u|0)<0)<<31>>31|0,121666,0)|0;j=z;t=af(t|0,((t|0)<0)<<31>>31|0,121666,0)|0;k=z;s=af(s|0,((s|0)<0)<<31>>31|0,121666,0)|0;h=z;r=af(r|0,((r|0)<0)<<31>>31|0,121666,0)|0;i=z;q=af(q|0,((q|0)<0)<<31>>31|0,121666,0)|0;f=z;l=af(l|0,((l|0)<0)<<31>>31|0,121666,0)|0;g=z;o=af(o|0,((o|0)<0)<<31>>31|0,121666,0)|0;d=z;w=af(w|0,((w|0)<0)<<31>>31|0,121666,0)|0;e=z;m=af(m|0,((m|0)<0)<<31>>31|0,121666,0)|0;n=z;v=af(v|0,((v|0)<0)<<31>>31|0,121666,0)|0;b=z;x=fg(v|0,b|0,16777216,0)|0;x=Xe(x|0,z|0,25)|0;p=z;y=af(x|0,p|0,19,0)|0;j=fg(y|0,z|0,u|0,j|0)|0;u=z;p=vf(x|0,p|0,25)|0;p=cg(v|0,b|0,p|0,z|0)|0;b=z;v=fg(t|0,k|0,16777216,0)|0;v=Xe(v|0,z|0,25)|0;x=z;h=fg(v|0,x|0,s|0,h|0)|0;s=z;x=vf(v|0,x|0,25)|0;x=cg(t|0,k|0,x|0,z|0)|0;k=z;t=fg(r|0,i|0,16777216,0)|0;t=Xe(t|0,z|0,25)|0;v=z;f=fg(t|0,v|0,q|0,f|0)|0;q=z;v=vf(t|0,v|0,25)|0;v=cg(r|0,i|0,v|0,z|0)|0;i=z;r=fg(l|0,g|0,16777216,0)|0;r=Xe(r|0,z|0,25)|0;t=z;d=fg(r|0,t|0,o|0,d|0)|0;o=z;t=vf(r|0,t|0,25)|0;t=cg(l|0,g|0,t|0,z|0)|0;g=z;l=fg(w|0,e|0,16777216,0)|0;l=Xe(l|0,z|0,25)|0;r=z;n=fg(l|0,r|0,m|0,n|0)|0;m=z;r=vf(l|0,r|0,25)|0;r=cg(w|0,e|0,r|0,z|0)|0;e=z;w=fg(j|0,u|0,33554432,0)|0;w=Xe(w|0,z|0,26)|0;l=z;k=fg(x|0,k|0,w|0,l|0)|0;l=vf(w|0,l|0,26)|0;l=cg(j|0,u|0,l|0,z|0)|0;u=fg(h|0,s|0,33554432,0)|0;u=Xe(u|0,z|0,26)|0;j=z;i=fg(v|0,i|0,u|0,j|0)|0;j=vf(u|0,j|0,26)|0;j=cg(h|0,s|0,j|0,z|0)|0;s=fg(f|0,q|0,33554432,0)|0;s=Xe(s|0,z|0,26)|0;h=z;g=fg(t|0,g|0,s|0,h|0)|0;h=vf(s|0,h|0,26)|0;h=cg(f|0,q|0,h|0,z|0)|0;q=fg(d|0,o|0,33554432,0)|0;q=Xe(q|0,z|0,26)|0;f=z;e=fg(r|0,e|0,q|0,f|0)|0;f=vf(q|0,f|0,26)|0;f=cg(d|0,o|0,f|0,z|0)|0;o=fg(n|0,m|0,33554432,0)|0;o=Xe(o|0,z|0,26)|0;d=z;b=fg(p|0,b|0,o|0,d|0)|0;d=vf(o|0,d|0,26)|0;d=cg(n|0,m|0,d|0,z|0)|0;c[a>>2]=l;c[a+4>>2]=k;c[a+8>>2]=j;c[a+12>>2]=i;c[a+16>>2]=h;c[a+20>>2]=g;c[a+24>>2]=f;c[a+28>>2]=e;c[a+32>>2]=d;c[a+36>>2]=b;return}function za(a,b,d,e,f){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0;if(!b)if(!e){if(f|0){c[f>>2]=(a>>>0)%(d>>>0);c[f+4>>2]=0}e=0;f=(a>>>0)/(d>>>0)>>>0;return (z=e,f)|0}else{if(!f){e=0;f=0;return (z=e,f)|0}c[f>>2]=a|0;c[f+4>>2]=b&0;e=0;f=0;return (z=e,f)|0}do if(d){if(e|0){h=(R(e|0)|0)-(R(b|0)|0)|0;if(h>>>0<=31){n=h+1|0;i=a>>>((h+1|0)>>>0)&h-31>>31|b<<31-h;m=b>>>((h+1|0)>>>0)&h-31>>31;g=0;h=a<<31-h;break}if(!f){e=0;f=0;return (z=e,f)|0}c[f>>2]=a|0;c[f+4>>2]=b|b&0;e=0;f=0;return (z=e,f)|0}if(d-1&d|0){h=(R(d|0)|0)+33-(R(b|0)|0)|0;n=h;i=32-h-1>>31&b>>>((h-32|0)>>>0)|(b<<32-h|a>>>(h>>>0))&h-32>>31;m=h-32>>31&b>>>(h>>>0);g=a<<64-h&32-h>>31;h=(b<<64-h|a>>>((h-32|0)>>>0))&32-h>>31|a<<32-h&h-33>>31;break}if(f|0){c[f>>2]=d-1&a;c[f+4>>2]=0}if((d|0)==1){e=b|b&0;f=a|0|0;return (z=e,f)|0}else{f=Yd(d|0)|0;e=b>>>(f>>>0)|0;f=b<<32-f|a>>>(f>>>0)|0;return (z=e,f)|0}}else{if(!e){if(f|0){c[f>>2]=(b>>>0)%(d>>>0);c[f+4>>2]=0}e=0;f=(b>>>0)/(d>>>0)>>>0;return (z=e,f)|0}if(!a){if(f|0){c[f>>2]=0;c[f+4>>2]=(b>>>0)%(e>>>0)}d=0;f=(b>>>0)/(e>>>0)>>>0;return (z=d,f)|0}if(!(e-1&e)){if(f|0){c[f>>2]=a|0;c[f+4>>2]=e-1&b|b&0}d=0;f=b>>>((Yd(e|0)|0)>>>0);return (z=d,f)|0}h=(R(e|0)|0)-(R(b|0)|0)|0;if(h>>>0<=30){n=h+1|0;i=b<<31-h|a>>>((h+1|0)>>>0);m=b>>>((h+1|0)>>>0);g=0;h=a<<31-h;break}if(!f){e=0;f=0;return (z=e,f)|0}c[f>>2]=a|0;c[f+4>>2]=b|b&0;e=0;f=0;return (z=e,f)|0}while(0);if(!n){j=h;b=m;a=0;h=0}else{k=fg(d|0|0,e|e&0|0,-1,-1)|0;l=z;j=h;b=m;a=n;h=0;do{p=j;j=g>>>31|j<<1;g=h|g<<1;p=i<<1|p>>>31|0;o=i>>>31|b<<1|0;cg(k|0,l|0,p|0,o|0)|0;n=z;m=n>>31|((n|0)<0?-1:0)<<1;h=m&1;i=cg(p|0,o|0,m&(d|0)|0,(((n|0)<0?-1:0)>>31|((n|0)<0?-1:0)<<1)&(e|e&0)|0)|0;b=z;a=a-1|0}while((a|0)!=0);a=0}if(f|0){c[f>>2]=i;c[f+4>>2]=b}o=(g|0)>>>31|j<<1|(0<<1|g>>>31)&0|a;p=(g<<1|0>>>31)&-2|h;return (z=o,p)|0}function Aa(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0;if(!d){G=857760878;H=2036477234;I=1634760805;y=1797285236}else{I=Rg(d)|0;G=Rg(d+4|0)|0;H=Rg(d+8|0)|0;y=Rg(d+12|0)|0}z=Rg(c)|0;A=Rg(c+4|0)|0;B=Rg(c+8|0)|0;C=Rg(c+12|0)|0;D=Rg(c+16|0)|0;E=Rg(c+20|0)|0;F=Rg(c+24|0)|0;u=Rg(c+28|0)|0;v=Rg(b)|0;w=Rg(b+4|0)|0;x=Rg(b+8|0)|0;t=Rg(b+12|0)|0;if((e|0)>0){g=z;i=A;l=B;o=C;r=v;q=w;p=x;n=t;m=D;k=u;j=F;h=E;s=0;b=G;c=H;d=y;f=I;do{o=(xh(f+h|0,7)|0)^o;p=(xh(o+f|0,9)|0)^p;h=(xh(p+o|0,13)|0)^h;f=(xh(h+p|0,18)|0)^f;n=(xh(g+b|0,7)|0)^n;j=(xh(n+b|0,9)|0)^j;g=(xh(j+n|0,13)|0)^g;b=(xh(g+j|0,18)|0)^b;k=(xh(r+c|0,7)|0)^k;i=(xh(k+c|0,9)|0)^i;r=(xh(i+k|0,13)|0)^r;c=(xh(r+i|0,18)|0)^c;l=(xh(m+d|0,7)|0)^l;q=(xh(l+d|0,9)|0)^q;m=(xh(q+l|0,13)|0)^m;d=(xh(m+q|0,18)|0)^d;g=(xh(l+f|0,7)|0)^g;i=(xh(g+f|0,9)|0)^i;l=(xh(i+g|0,13)|0)^l;f=(xh(l+i|0,18)|0)^f;r=(xh(b+o|0,7)|0)^r;q=(xh(r+b|0,9)|0)^q;o=(xh(q+r|0,13)|0)^o;b=(xh(o+q|0,18)|0)^b;m=(xh(c+n|0,7)|0)^m;p=(xh(m+c|0,9)|0)^p;n=(xh(p+m|0,13)|0)^n;c=(xh(n+p|0,18)|0)^c;h=(xh(d+k|0,7)|0)^h;j=(xh(h+d|0,9)|0)^j;k=(xh(j+h|0,13)|0)^k;d=(xh(k+j|0,18)|0)^d;s=s+2|0}while((s|0)<(e|0))}else{g=z;i=A;l=B;o=C;r=v;q=w;p=x;n=t;m=D;k=u;j=F;h=E;f=I;b=G;c=H;d=y}jg(a,f+I|0);jg(a+4|0,g+z|0);jg(a+8|0,i+A|0);jg(a+12|0,l+B|0);jg(a+16|0,o+C|0);jg(a+20|0,b+G|0);jg(a+24|0,r+v|0);jg(a+28|0,q+w|0);jg(a+32|0,p+x|0);jg(a+36|0,n+t|0);jg(a+40|0,c+H|0);jg(a+44|0,m+D|0);jg(a+48|0,h+E|0);jg(a+52|0,j+F|0);jg(a+56|0,k+u|0);jg(a+60|0,d+y|0);return}function Ba(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+2272|0;Ab(g+2016|0,c);Ab(g+1760|0,e);Xd(g+480|0,d);ye(g+320|0,d);Id(g,g+320|0);Rb(g+320|0,g,g+480|0);Id(g+160|0,g+320|0);Xd(g+480+160|0,g+160|0);Rb(g+320|0,g,g+480+160|0);Id(g+160|0,g+320|0);Xd(g+480+320|0,g+160|0);Rb(g+320|0,g,g+480+320|0);Id(g+160|0,g+320|0);Xd(g+480+480|0,g+160|0);Rb(g+320|0,g,g+480+480|0);Id(g+160|0,g+320|0);Xd(g+480+640|0,g+160|0);Rb(g+320|0,g,g+480+640|0);Id(g+160|0,g+320|0);Xd(g+480+800|0,g+160|0);Rb(g+320|0,g,g+480+800|0);Id(g+160|0,g+320|0);Xd(g+480+960|0,g+160|0);Rb(g+320|0,g,g+480+960|0);Id(g+160|0,g+320|0);Xd(g+480+1120|0,g+160|0);Mf(b);c=255;while(1){if(a[g+2016+c>>0]|0)break;if(a[g+1760+c>>0]|0)break;d=c+-1|0;if((c|0)>0)c=d;else{c=d;break}}if((c|0)>-1)while(1){jc(g+320|0,b);d=a[g+2016+c>>0]|0;if(d<<24>>24<=0){if(d<<24>>24<0){Id(g+160|0,g+320|0);Qb(g+320|0,g+160|0,g+480+((((d<<24>>24)/-2|0)<<24>>24)*160|0)|0)}}else{Id(g+160|0,g+320|0);Rb(g+320|0,g+160|0,g+480+(((d&255)>>>1&255)*160|0)|0)}d=a[g+1760+c>>0]|0;if(d<<24>>24<=0){if(d<<24>>24<0){Id(g+160|0,g+320|0);Vb(g+320|0,g+160|0,1272+((((d<<24>>24)/-2|0)<<24>>24)*120|0)|0)}}else{Id(g+160|0,g+320|0);Wb(g+320|0,g+160|0,1272+(((d&255)>>>1&255)*120|0)|0)}ze(b,g+320|0);if((c|0)>0)c=c+-1|0;else break}l=f;return}function Ca(a){a=a|0;var b=0,d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0;u=l;v=l=l+63&-64;l=l+64|0;Ef(v,a);b=0;e=c[v+44>>2]|0;f=c[v+60>>2]|0;g=c[v+12>>2]|0;h=c[v+28>>2]|0;i=c[v+48>>2]|0;j=c[v>>2]|0;k=c[v+16>>2]|0;m=c[v+32>>2]|0;d=c[v+4>>2]|0;n=c[v+20>>2]|0;o=c[v+36>>2]|0;p=c[v+52>>2]|0;q=c[v+24>>2]|0;r=c[v+40>>2]|0;s=c[v+56>>2]|0;t=c[v+8>>2]|0;do{F=i+j|0;F=(F<<7|F>>>25)^k;C=F+j|0;C=(C<<9|C>>>23)^m;z=(C+F<<13|(C+F|0)>>>19)^i;I=(z+C<<18|(z+C|0)>>>14)^j;B=d+n|0;B=(B<<7|B>>>25)^o;y=B+n|0;y=(y<<9|y>>>23)^p;L=(y+B<<13|(y+B|0)>>>19)^d;E=(L+y<<18|(L+y|0)>>>14)^n;x=q+r|0;x=(x<<7|x>>>25)^s;K=x+r|0;K=(K<<9|K>>>23)^t;H=(K+x<<13|(K+x|0)>>>19)^q;A=(H+K<<18|(H+K|0)>>>14)^r;J=e+f|0;J=(J<<7|J>>>25)^g;G=J+f|0;G=(G<<9|G>>>23)^h;D=(G+J<<13|(G+J|0)>>>19)^e;w=(D+G<<18|(D+G|0)>>>14)^f;d=(J+I<<7|(J+I|0)>>>25)^L;L=d+I|0;t=(L<<9|L>>>23)^K;K=t+d|0;g=(K<<13|K>>>19)^J;J=g+t|0;j=(J<<18|J>>>14)^I;q=(F+E<<7|(F+E|0)>>>25)^H;H=q+E|0;h=(H<<9|H>>>23)^G;G=h+q|0;k=(G<<13|G>>>19)^F;F=k+h|0;n=(F<<18|F>>>14)^E;e=(B+A<<7|(B+A|0)>>>25)^D;D=e+A|0;m=(D<<9|D>>>23)^C;C=m+e|0;o=(C<<13|C>>>19)^B;B=o+m|0;r=(B<<18|B>>>14)^A;i=(x+w<<7|(x+w|0)>>>25)^z;z=i+w|0;p=(z<<9|z>>>23)^y;y=p+i|0;s=(y<<13|y>>>19)^x;x=s+p|0;f=(x<<18|x>>>14)^w;b=b+2|0}while(b>>>0<8);c[v>>2]=j;c[v+48>>2]=i;c[v+16>>2]=k;c[v+32>>2]=m;c[v+20>>2]=n;c[v+4>>2]=d;c[v+36>>2]=o;c[v+52>>2]=p;c[v+40>>2]=r;c[v+24>>2]=q;c[v+56>>2]=s;c[v+8>>2]=t;c[v+60>>2]=f;c[v+44>>2]=e;c[v+12>>2]=g;c[v+28>>2]=h;c[a>>2]=(c[a>>2]|0)+j;b=1;while(1){L=a+(b<<2)|0;c[L>>2]=(c[L>>2]|0)+d;b=b+1|0;if((b|0)==16)break;d=c[v+(b<<2)>>2]|0}l=u;return}function Da(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=0;if(!d){d=1797285236;e=2036477234;f=857760878;g=1634760805}else{g=Rg(d)|0;f=Rg(d+4|0)|0;e=Rg(d+8|0)|0;d=Rg(d+12|0)|0}r=Rg(c)|0;q=Rg(c+4|0)|0;p=Rg(c+8|0)|0;o=Rg(c+12|0)|0;n=Rg(c+16|0)|0;m=Rg(c+20|0)|0;l=Rg(c+24|0)|0;k=Rg(c+28|0)|0;j=Rg(b)|0;i=Rg(b+4|0)|0;h=Rg(b+8|0)|0;s=0;b=Rg(b+12|0)|0;c=g;do{L=r+c|0;A=xh(j^L,16)|0;z=A+n|0;M=xh(z^r,12)|0;A=xh(M+L^A,8)|0;w=xh(A+z^M,7)|0;H=q+f|0;u=xh(i^H,16)|0;t=u+m|0;I=xh(t^q,12)|0;u=xh(I+H^u,8)|0;N=xh(u+t^I,7)|0;C=p+e|0;v=xh(h^C,16)|0;B=v+l|0;D=xh(B^p,12)|0;v=xh(D+C^v,8)|0;J=xh(v+B^D,7)|0;x=o+d|0;F=xh(b^x,16)|0;g=F+k|0;y=xh(g^o,12)|0;F=xh(y+x^F,8)|0;E=xh(F+g^y,7)|0;K=xh(F^N+(M+L),16)|0;G=xh(K+(v+B)^N,12)|0;c=G+(N+(M+L))|0;b=xh(c^K,8)|0;l=b+(K+(v+B))|0;q=xh(l^G,7)|0;G=xh(J+(I+H)^A,16)|0;B=xh(G+(F+g)^J,12)|0;f=B+(J+(I+H))|0;j=xh(f^G,8)|0;k=j+(G+(F+g))|0;p=xh(k^B,7)|0;B=xh(E+(D+C)^u,16)|0;g=xh(B+(A+z)^E,12)|0;e=g+(E+(D+C))|0;i=xh(e^B,8)|0;n=i+(B+(A+z))|0;o=xh(n^g,7)|0;v=xh(y+x+w^v,16)|0;g=xh(v+(u+t)^w,12)|0;d=g+(y+x+w)|0;h=xh(d^v,8)|0;m=h+(v+(u+t))|0;r=xh(m^g,7)|0;s=s+1|0}while((s|0)!=10);jg(a,c);jg(a+4|0,f);jg(a+8|0,e);jg(a+12|0,d);jg(a+16|0,j);jg(a+20|0,i);jg(a+24|0,h);jg(a+28|0,b);return 0}function Ea(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0;n=l;m=l=l+63&-64;l=l+704|0;a:do if(!((e|0)==0&(f|0)==0)){r=c[b+72>>2]|0;p=c[b+72+4>>2]|0;k=yf(r|0,p|0,3)|0;o=vf(e|0,f|0,3)|0;q=z;i=yf(e|0,f|0,61)|0;j=z;p=fg(r|0,p|0,o|0,q|0)|0;r=z;c[b+72>>2]=p;c[b+72+4>>2]=r;g=c[b+64>>2]|0;h=c[b+64+4>>2]|0;if(r>>>0<q>>>0|(r|0)==(q|0)&p>>>0<o>>>0){g=fg(g|0,h|0,1,0)|0;h=z;c[b+64>>2]=g;c[b+64+4>>2]=h}j=fg(g|0,h|0,i|0,j|0)|0;c[b+64>>2]=j;c[b+64+4>>2]=z;j=cg(128,0,k&127|0,0)|0;g=z;if(g>>>0>f>>>0|(g|0)==(f|0)&j>>>0>e>>>0){g=0;h=0;while(1){q=a[d+g>>0]|0;r=fg(g|0,h|0,k&127|0,0)|0;a[b+80+r>>0]=q;g=fg(g|0,h|0,1,0)|0;h=z;if(!(h>>>0<f>>>0|(h|0)==(f|0)&g>>>0<e>>>0))break a}}if(!((j|0)==0&(g|0)==0)){h=0;i=0;do{q=a[d+h>>0]|0;r=fg(h|0,i|0,k&127|0,0)|0;a[b+80+r>>0]=q;h=fg(h|0,i|0,1,0)|0;i=z}while(i>>>0<g>>>0|(i|0)==(g|0)&h>>>0<j>>>0)}ja(b,b+80|0,m,m+640|0);g=cg(e|0,f|0,j|0,g|0)|0;h=z;if(h>>>0>0|(h|0)==0&g>>>0>127){i=d+j|0;do{ja(b,i,m,m+640|0);i=i+128|0;g=fg(g|0,h|0,-128,-1)|0;h=z}while(h>>>0>0|(h|0)==0&g>>>0>127);j=i}else j=d+j|0;g=g&127;if(!((g|0)==0&0==0)){h=0;i=0;do{a[b+80+h>>0]=a[j+h>>0]|0;h=fg(h|0,i|0,1,0)|0;i=z}while(i>>>0<0|(i|0)==0&h>>>0<g>>>0)}Sd(m,704)}while(0);l=n;return 0}function Fa(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+160|0;qa(d+120|0,b);qa(d+80|0,d+120|0);qa(d+80|0,d+80|0);la(d+80|0,b,d+80|0);la(d+120|0,d+120|0,d+80|0);qa(d+40|0,d+120|0);la(d+80|0,d+80|0,d+40|0);qa(d+40|0,d+80|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=5);la(d+80|0,d+40|0,d+80|0);qa(d+40|0,d+80|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=10);la(d+40|0,d+40|0,d+80|0);qa(d,d+40|0);b=1;do{qa(d,d);b=b+1|0}while((b|0)!=20);la(d+40|0,d,d+40|0);qa(d+40|0,d+40|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=10);la(d+80|0,d+40|0,d+80|0);qa(d+40|0,d+80|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=50);la(d+40|0,d+40|0,d+80|0);qa(d,d+40|0);b=1;do{qa(d,d);b=b+1|0}while((b|0)!=100);la(d+40|0,d,d+40|0);qa(d+40|0,d+40|0);b=1;do{qa(d+40|0,d+40|0);b=b+1|0}while((b|0)!=50);la(d+80|0,d+40|0,d+80|0);qa(d+80|0,d+80|0);b=1;do{qa(d+80|0,d+80|0);b=b+1|0}while((b|0)!=5);la(a,d+80|0,d+120|0);l=c;return}function Ga(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0,y=0,z=0,A=0,B=0,C=0,D=0,E=0,F=0,G=0,H=0;if(!d){d=1797285236;e=2036477234;f=857760878;o=1634760805}else{o=Rg(d)|0;f=Rg(d+4|0)|0;e=Rg(d+8|0)|0;d=Rg(d+12|0)|0}n=Rg(c)|0;m=Rg(c+4|0)|0;l=Rg(c+8|0)|0;k=Rg(c+12|0)|0;t=Rg(c+16|0)|0;s=Rg(c+20|0)|0;r=Rg(c+24|0)|0;q=Rg(c+28|0)|0;j=Rg(b)|0;i=Rg(b+4|0)|0;h=Rg(b+8|0)|0;g=Rg(b+12|0)|0;p=20;b=f;c=o;while(1){B=(xh(s+c|0,7)|0)^k;y=(xh(B+c|0,9)|0)^h;v=(xh(y+B|0,13)|0)^s;E=(xh(v+y|0,18)|0)^c;x=(xh(b+n|0,7)|0)^g;u=(xh(x+b|0,9)|0)^r;H=(xh(u+x|0,13)|0)^n;A=(xh(H+u|0,18)|0)^b;f=(xh(e+j|0,7)|0)^q;G=(xh(f+e|0,9)|0)^m;D=(xh(G+f|0,13)|0)^j;w=(xh(D+G|0,18)|0)^e;F=(xh(d+t|0,7)|0)^l;C=(xh(F+d|0,9)|0)^i;z=(xh(C+F|0,13)|0)^t;o=(xh(z+C|0,18)|0)^d;n=(xh(F+E|0,7)|0)^H;m=(xh(n+E|0,9)|0)^G;l=(xh(m+n|0,13)|0)^F;c=(xh(l+m|0,18)|0)^E;j=(xh(A+B|0,7)|0)^D;i=(xh(j+A|0,9)|0)^C;k=(xh(i+j|0,13)|0)^B;b=(xh(k+i|0,18)|0)^A;t=(xh(w+x|0,7)|0)^z;h=(xh(t+w|0,9)|0)^y;g=(xh(h+t|0,13)|0)^x;e=(xh(g+h|0,18)|0)^w;s=(xh(o+f|0,7)|0)^v;r=(xh(s+o|0,9)|0)^u;q=(xh(r+s|0,13)|0)^f;d=(xh(q+r|0,18)|0)^o;if((p|0)<=2)break;else p=p+-2|0}jg(a,c);jg(a+4|0,b);jg(a+8|0,e);jg(a+12|0,d);jg(a+16|0,j);jg(a+20|0,i);jg(a+24|0,h);jg(a+28|0,g);return 0}function Ha(a,b){a=a|0;b=b|0;var c=0,d=0,e=0;d=l;e=l=l+63&-64;l=l+128|0;qa(e+80|0,b);qa(e+40|0,e+80|0);qa(e+40|0,e+40|0);la(e+40|0,b,e+40|0);la(e+80|0,e+80|0,e+40|0);qa(e+80|0,e+80|0);la(e+80|0,e+40|0,e+80|0);qa(e+40|0,e+80|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=5);la(e+80|0,e+40|0,e+80|0);qa(e+40|0,e+80|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=10);la(e+40|0,e+40|0,e+80|0);qa(e,e+40|0);c=1;do{qa(e,e);c=c+1|0}while((c|0)!=20);la(e+40|0,e,e+40|0);qa(e+40|0,e+40|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=10);la(e+80|0,e+40|0,e+80|0);qa(e+40|0,e+80|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=50);la(e+40|0,e+40|0,e+80|0);qa(e,e+40|0);c=1;do{qa(e,e);c=c+1|0}while((c|0)!=100);la(e+40|0,e,e+40|0);qa(e+40|0,e+40|0);c=1;do{qa(e+40|0,e+40|0);c=c+1|0}while((c|0)!=50);la(e+80|0,e+40|0,e+80|0);qa(e+80|0,e+80|0);qa(e+80|0,e+80|0);la(a,e+80|0,b);l=d;return}function Ia(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0;o=l;k=l=l+63&-64;l=l+16|0;do if(d>>>0>=12){f=b;g=34163;h=f+12|0;do{a[f>>0]=a[g>>0]|0;f=f+1|0;g=g+1|0}while((f|0)<(h|0));f=hb(e)|0;if(!f){fd(k,19);h=uc(k)|0;g=b+11+h|0;if((d+-11|0)>>>0<=h>>>0){f=-31;break}fb(b+11|0,k|0,h+1|0)|0;if((d+-11-h|0)>>>0>=4){a[g>>0]=36;a[g+1>>0]=109;a[g+2>>0]=61;a[g+3>>0]=0;fd(k,c[e+44>>2]|0);f=uc(k)|0;i=g+3+f|0;j=d+-11-h+-3-f|0;if((d+-11-h+-3|0)>>>0<=f>>>0){f=-31;break}fb(g+3|0,k|0,f+1|0)|0;if(j>>>0>=4){a[i>>0]=44;a[i+1>>0]=116;a[i+2>>0]=61;a[i+3>>0]=0;fd(k,c[e+40>>2]|0);f=uc(k)|0;b=i+3+f|0;if((j+-3|0)>>>0<=f>>>0){f=-31;break}fb(i+3|0,k|0,f+1|0)|0;if((j+-3-f|0)>>>0>=4){a[b>>0]=44;a[b+1>>0]=112;a[b+2>>0]=61;a[b+3>>0]=0;fd(k,c[e+48>>2]|0);g=uc(k)|0;h=j+-3-f+-3-g|0;if((j+-3-f+-3|0)>>>0<=g>>>0){f=-31;break}fb(b+3|0,k|0,g+1|0)|0;f=b+3+g+1|0;if(h>>>0>=2?(a[b+3+g>>0]=36,a[b+3+g+1>>0]=0,k=Eb(f,h+-1|0,c[e+16>>2]|0,c[e+20>>2]|0)|0,n=h+-1-((k|0)==-1?0:k)|0,m=(k|0)==-1?f:f+k|0,!((k|0)==-1|n>>>0<2)):0){a[m>>0]=36;a[m+1>>0]=0;e=(Eb(m+1|0,n+-1|0,c[e>>2]|0,c[e+4>>2]|0)|0)!=-1;l=o;return (e?0:-31)|0}else f=-31}else f=-31}else f=-31}else f=-31}}else f=-31;while(0);l=o;return f|0}function Ja(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0;m=c[d>>2]|0;h=c[d+4>>2]|0;i=c[d+8>>2]|0;j=c[d+12>>2]|0;p=c[d+16>>2]|0;f=c[d+20>>2]|0;g=c[d+24>>2]|0;n=c[d+28>>2]|0;e=c[d+32>>2]|0;d=c[d+36>>2]|0;o=((((((((((((((d*19|0)+16777216|0)>>>25)+m>>26)+h>>25)+i>>26)+j>>25)+p>>26)+f>>25)+g>>26)+n>>25)+e>>26)+d>>25)*19|0)+m>>26;m=((((((((((((((d*19|0)+16777216|0)>>>25)+m>>26)+h>>25)+i>>26)+j>>25)+p>>26)+f>>25)+g>>26)+n>>25)+e>>26)+d>>25)*19|0)+m-(o<<26)|0;l=o+h-(o+h>>25<<25)|0;k=(o+h>>25)+i-((o+h>>25)+i>>26<<26)|0;q=((o+h>>25)+i>>26)+j>>25;j=((o+h>>25)+i>>26)+j-(q<<25)|0;i=q+p-(q+p>>26<<26)|0;h=(q+p>>26)+f-((q+p>>26)+f>>25<<25)|0;o=((q+p>>26)+f>>25)+g>>26;g=((q+p>>26)+f>>25)+g-(o<<26)|0;f=o+n-(o+n>>25<<25)|0;d=((o+n>>25)+e>>26)+d|0;e=(o+n>>25)+e-((o+n>>25)+e>>26<<26)|0;a[b>>0]=m;a[b+1>>0]=m>>>8;a[b+2>>0]=m>>>16;a[b+3>>0]=l<<2|m>>>24;a[b+4>>0]=l>>>6;a[b+5>>0]=l>>>14;a[b+6>>0]=k<<3|l>>>22;a[b+7>>0]=k>>>5;a[b+8>>0]=k>>>13;a[b+9>>0]=j<<5|k>>>21;a[b+10>>0]=j>>>3;a[b+11>>0]=j>>>11;a[b+12>>0]=i<<6|j>>>19;a[b+13>>0]=i>>>2;a[b+14>>0]=i>>>10;a[b+15>>0]=i>>>18;a[b+16>>0]=h;a[b+17>>0]=h>>>8;a[b+18>>0]=h>>>16;a[b+19>>0]=g<<1|h>>>24;a[b+20>>0]=g>>>7;a[b+21>>0]=g>>>15;a[b+22>>0]=f<<3|g>>>23;a[b+23>>0]=f>>>5;a[b+24>>0]=f>>>13;a[b+25>>0]=e<<4|f>>>21;a[b+26>>0]=e>>>4;a[b+27>>0]=e>>>12;a[b+28>>0]=e>>>20|(d&33554431)<<6;a[b+29>>0]=d>>>2;a[b+30>>0]=d>>>10;a[b+31>>0]=(d&33554431)>>>18;return}function Ka(b,c,e){b=b|0;c=c|0;e=e|0;var f=0,g=0,h=0,i=0;h=l;i=l=l+63&-64;l=l+320|0;g=i+280|0;f=g+32|0;do{a[g>>0]=a[c>>0]|0;g=g+1|0;c=c+1|0}while((g|0)<(f|0));a[i+280>>0]=a[i+280>>0]&-8;a[i+280+31>>0]=a[i+280+31>>0]&63|64;xa(i+240|0,e);Bf(i+200|0);lg(i+160|0);qc(i+120|0,i+240|0);Bf(i+80|0);c=0;f=254;while(1){g=c;c=(d[i+280+(f>>>3)>>0]|0)>>>(f&7)&1;g=c^g;bb(i+200|0,i+120|0,g);bb(i+160|0,i+80|0,g);Fb(i+40|0,i+120|0,i+80|0);Fb(i,i+200|0,i+160|0);Gb(i+200|0,i+200|0,i+160|0);Gb(i+160|0,i+120|0,i+80|0);la(i+80|0,i+40|0,i+200|0);la(i+160|0,i+160|0,i);qa(i+40|0,i);qa(i,i+200|0);Gb(i+120|0,i+80|0,i+160|0);Fb(i+160|0,i+80|0,i+160|0);la(i+200|0,i,i+40|0);Fb(i,i,i+40|0);qa(i+160|0,i+160|0);ya(i+80|0,i);qa(i+120|0,i+120|0);Gb(i+40|0,i+40|0,i+80|0);la(i+80|0,i+240|0,i+160|0);la(i+160|0,i,i+40|0);if((f|0)<=0)break;else f=f+-1|0}bb(i+200|0,i+120|0,c);bb(i+160|0,i+80|0,c);Fa(i+160|0,i+160|0);la(i+200|0,i+200|0,i+160|0);Ja(b,i+200|0);l=h;return 0}function La(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0;n=l;m=l=l+63&-64;l=l+288|0;a:do if(!((e|0)==0&(f|0)==0)){i=c[b+32>>2]|0;g=c[b+32+4>>2]|0;j=yf(i|0,g|0,3)|0;k=vf(e|0,f|0,3)|0;k=fg(i|0,g|0,k|0,z|0)|0;c[b+32>>2]=k;c[b+32+4>>2]=z;k=cg(64,0,j&63|0,0)|0;g=z;if(g>>>0>f>>>0|(g|0)==(f|0)&k>>>0>e>>>0){g=0;h=0;while(1){k=a[d+g>>0]|0;m=fg(g|0,h|0,j&63|0,0)|0;a[b+40+m>>0]=k;g=fg(g|0,h|0,1,0)|0;h=z;if(!(h>>>0<f>>>0|(h|0)==(f|0)&g>>>0<e>>>0))break a}}if(!((k|0)==0&(g|0)==0)){h=0;i=0;do{p=a[d+h>>0]|0;o=fg(h|0,i|0,j&63|0,0)|0;a[b+40+o>>0]=p;h=fg(h|0,i|0,1,0)|0;i=z}while(i>>>0<g>>>0|(i|0)==(g|0)&h>>>0<k>>>0)}pa(b,b+40|0,m,m+256|0);g=cg(e|0,f|0,k|0,g|0)|0;h=z;if(h>>>0>0|(h|0)==0&g>>>0>63){i=d+k|0;do{pa(b,i,m,m+256|0);i=i+64|0;g=fg(g|0,h|0,-64,-1)|0;h=z}while(h>>>0>0|(h|0)==0&g>>>0>63);j=i}else j=d+k|0;g=g&63;if(!((g|0)==0&0==0)){h=0;i=0;do{a[b+40+h>>0]=a[j+h>>0]|0;h=fg(h|0,i|0,1,0)|0;i=z}while(i>>>0<0|(i|0)==0&h>>>0<g>>>0)}Sd(m,288)}while(0);l=n;return 0}function Ma(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0;h=c[b+56>>2]|0;g=c[b+56+4>>2]|0;if(!((h|0)==0&(g|0)==0)){j=cg(16,0,h|0,g|0)|0;l=z;k=l>>>0>f>>>0|(l|0)==(f|0)&j>>>0>e>>>0?e:j;l=l>>>0>f>>>0|(l|0)==(f|0)&j>>>0>e>>>0?f:l;if(!((k|0)==0&(l|0)==0)){j=0;i=0;do{n=a[d+j>>0]|0;h=fg(h|0,g|0,j|0,i|0)|0;a[b+64+h>>0]=n;j=fg(j|0,i|0,1,0)|0;i=z;h=c[b+56>>2]|0;g=c[b+56+4>>2]|0}while(i>>>0<l>>>0|(i|0)==(l|0)&j>>>0<k>>>0)}n=fg(h|0,g|0,k|0,l|0)|0;j=z;c[b+56>>2]=n;c[b+56+4>>2]=j;if(!(j>>>0<0|(j|0)==0&n>>>0<16)){e=cg(e|0,f|0,k|0,l|0)|0;f=z;wa(b,b+64|0,16,0);c[b+56>>2]=0;c[b+56+4>>2]=0;d=d+k|0;m=6}}else m=6;if((m|0)==6){g=e&-16;if(f>>>0>0|(f|0)==0&e>>>0>15){e=cg(e|0,f|0,g|0,f|0)|0;n=z;wa(b,d,g,f);d=d+g|0;g=n}else g=f;if(!((e|0)==0&(g|0)==0)){f=0;h=c[b+56>>2]|0;i=c[b+56+4>>2]|0;j=0;do{m=a[d+f>>0]|0;n=fg(h|0,i|0,f|0,j|0)|0;a[b+64+n>>0]=m;f=fg(f|0,j|0,1,0)|0;j=z;h=c[b+56>>2]|0;i=c[b+56+4>>2]|0}while(j>>>0<g>>>0|(j|0)==(g|0)&f>>>0<e>>>0);n=fg(h|0,i|0,e|0,g|0)|0;c[b+56>>2]=n;c[b+56+4>>2]=z}}return}function Na(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+400|0;if(!((a|0)==0|(b|0)==0)){Gc(f,0,0,64)|0;jg(f+384|0,c[b+48>>2]|0);og(f,f+384|0,4,0)|0;jg(f+384|0,c[b+4>>2]|0);og(f,f+384|0,4,0)|0;jg(f+384|0,c[b+44>>2]|0);og(f,f+384|0,4,0)|0;jg(f+384|0,c[b+40>>2]|0);og(f,f+384|0,4,0)|0;jg(f+384|0,19);og(f,f+384|0,4,0)|0;jg(f+384|0,d);og(f,f+384|0,4,0)|0;jg(f+384|0,c[b+12>>2]|0);og(f,f+384|0,4,0)|0;d=c[b+8>>2]|0;if(d|0?(og(f,d,c[b+12>>2]|0,0)|0,c[b+56>>2]&1|0):0){Sd(c[b+8>>2]|0,c[b+12>>2]|0);c[b+12>>2]=0}jg(f+384|0,c[b+20>>2]|0);og(f,f+384|0,4,0)|0;d=c[b+16>>2]|0;if(d|0)og(f,d,c[b+20>>2]|0,0)|0;jg(f+384|0,c[b+28>>2]|0);og(f,f+384|0,4,0)|0;d=c[b+24>>2]|0;if(d|0?(og(f,d,c[b+28>>2]|0,0)|0,c[b+56>>2]&2|0):0){Sd(c[b+24>>2]|0,c[b+28>>2]|0);c[b+28>>2]=0}jg(f+384|0,c[b+36>>2]|0);og(f,f+384|0,4,0)|0;d=c[b+32>>2]|0;if(d|0)og(f,d,c[b+36>>2]|0,0)|0;cf(f,a,64)|0}l=e;return}function Oa(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0;j=l;k=l=l+63&-64;l=l+528|0;c[k+384>>2]=0;jg(k+384|0,d);if(d>>>0<65){if((Gc(k,0,0,d)|0)>=0){og(k,k+384|0,4,0)|0;og(k,e,f,0)|0;cf(k,b,d)|0}}else a:do if((Gc(k,0,0,64)|0)>=0?(og(k,k+384|0,4,0)|0,og(k,e,f,0)|0,(cf(k,k+456|0,64)|0)>=0):0){g=b;h=k+456|0;i=g+32|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0));g=k+392|0;h=k+456|0;i=g+64|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0));if((d+-32|0)>>>0>64){f=d+-32|0;e=b+32|0;do{if((Sc(k+456|0,64,k+392|0,64,0,0,0)|0)<0)break a;g=e;h=k+456|0;i=g+32|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0));f=f+-32|0;e=e+32|0;g=k+392|0;h=k+456|0;i=g+64|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0))}while(f>>>0>64)}else{f=d+-32|0;e=b+32|0}if((Sc(k+456|0,f,k+392|0,64,0,0,0)|0)>=0)fb(e|0,k+456|0,f|0)|0}while(0);Sd(k,384);l=j;return}function Pa(b,e,f,g,h,i,j,k){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;var m=0,n=0,o=0,p=0;o=l;p=l=l+63&-64;l=l+112|0;if(!((f|0)==0&(g|0)==0)){n=p+16|0;m=n+32|0;do{a[n>>0]=a[k>>0]|0;n=n+1|0;k=k+1|0}while((n|0)<(m|0));k=d[h+4>>0]|d[h+4+1>>0]<<8|d[h+4+2>>0]<<16|d[h+4+3>>0]<<24;c[p>>2]=d[h>>0]|d[h+1>>0]<<8|d[h+2>>0]<<16|d[h+3>>0]<<24;c[p+4>>2]=k;k=8;while(1){a[p+k>>0]=i;i=yf(i|0,j|0,8)|0;k=k+1|0;if((k|0)==16)break;else j=z}if(g>>>0>0|(g|0)==0&f>>>0>63){k=b;i=f;while(1){Og(p+48|0,p,p+16|0,0)|0;b=0;do{a[k+b>>0]=a[p+48+b>>0]^a[e+b>>0];b=b+1|0}while((b|0)!=64);b=1;j=8;while(1){f=p+j|0;b=(d[f>>0]|0)+b|0;a[f>>0]=b;j=j+1|0;if((j|0)==16)break;else b=b>>>8}j=fg(i|0,g|0,-64,-1)|0;g=z;b=k+64|0;e=e+64|0;if(g>>>0>0|(g|0)==0&j>>>0>63){k=b;i=j}else break}}else j=f;if(!((j|0)==0&(g|0)==0)?(Og(p+48|0,p,p+16|0,0)|0,j|0):0){g=0;do{a[b+g>>0]=a[p+48+g>>0]^a[e+g>>0];g=g+1|0}while((g|0)!=(j|0))}Sd(p+48|0,64);Sd(p+16|0,32)}l=o;return 0}function Qa(b,c,d,e,f,g,h){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0;j=l;k=l=l+63&-64;l=l+352|0;Da(k+256|0,g,h,0)|0;if(b>>>0>d>>>0?0<f>>>0|0==(f|0)&(b-d|0)>>>0<e>>>0:0)i=5;else if(d>>>0>b>>>0?0<f>>>0|0==(f|0)&(d-b|0)>>>0<e>>>0:0)i=5;if((i|0)==5){Ed(b|0,d|0,e|0)|0;d=b}h=k+288|0;i=h+32|0;do{a[h>>0]=0;h=h+1|0}while((h|0)<(i|0));h=f>>>0>0|(f|0)==0&e>>>0>32?32:e;i=f>>>0>0|(f|0)==0&e>>>0>32?0:f;if(!((h|0)==0&(i|0)==0)){m=cg(-2,-1,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~e:-33)|0,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~f:-1)|0)|0;fb(k+288+32|0,d|0,m+1|0)|0}m=fg(h|0,i|0,32,0)|0;Tf(k+288|0,k+288|0,m,z,g+16|0,k+256|0)|0;_g(k,k+288|0)|0;if(!((h|0)==0&(i|0)==0)){m=cg(-2,-1,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~e:-33)|0,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~f:-1)|0)|0;fb(b|0,k+288+32|0,m+1|0)|0}Sd(k+288|0,64);if(f>>>0>0|(f|0)==0&e>>>0>32){m=cg(e|0,f|0,h|0,i|0)|0;jf(b+h|0,d+h|0,m,z,g+16|0,1,0,k+256|0)|0}Sd(k+256|0,32);eg(k,b,e,f)|0;Zg(k,c)|0;Sd(k,256);l=j;return 0}function Ra(b,e,f,g,h,i){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0;q=l;r=l=l+63&-64;l=l+112|0;if(!((f|0)==0&(g|0)==0)){k=r+16|0;j=k+32|0;do{a[k>>0]=a[i>>0]|0;k=k+1|0;i=i+1|0}while((k|0)<(j|0));k=d[h+4>>0]|d[h+4+1>>0]<<8|d[h+4+2>>0]<<16|d[h+4+3>>0]<<24;c[r>>2]=d[h>>0]|d[h+1>>0]<<8|d[h+2>>0]<<16|d[h+3>>0]<<24;c[r+4>>2]=k;c[r+8>>2]=0;c[r+8+4>>2]=0;if(g>>>0>0|(g|0)==0&f>>>0>63){k=e;h=f;do{Lg(r+48|0,r,r+16|0,0)|0;i=0;do{a[b+i>>0]=a[r+48+i>>0]^a[k+i>>0];i=i+1|0}while((i|0)!=64);i=1;j=8;while(1){f=r+j|0;i=(d[f>>0]|0)+i|0;a[f>>0]=i;j=j+1|0;if((j|0)==16)break;else i=i>>>8}h=fg(h|0,g|0,-64,-1)|0;g=z;b=b+64|0;k=k+64|0}while(g>>>0>0|(g|0)==0&h>>>0>63);if(!((h|0)==0&(g|0)==0)){n=b;o=h;p=k;m=8}}else{n=b;o=f;p=e;m=8}if((m|0)==8?(Lg(r+48|0,r,r+16|0,0)|0,o|0):0){i=0;do{a[n+i>>0]=a[r+48+i>>0]^a[p+i>>0];i=i+1|0}while((i|0)!=(o|0))}Sd(r+48|0,64);Sd(r+16|0,32)}l=q;return 0}function Sa(b,e,f,g,h,i){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0,n=0,o=0,p=0,q=0,r=0;q=l;r=l=l+63&-64;l=l+112|0;if(!((f|0)==0&(g|0)==0)){k=r+16|0;j=k+32|0;do{a[k>>0]=a[i>>0]|0;k=k+1|0;i=i+1|0}while((k|0)<(j|0));k=d[h+4>>0]|d[h+4+1>>0]<<8|d[h+4+2>>0]<<16|d[h+4+3>>0]<<24;c[r>>2]=d[h>>0]|d[h+1>>0]<<8|d[h+2>>0]<<16|d[h+3>>0]<<24;c[r+4>>2]=k;c[r+8>>2]=0;c[r+8+4>>2]=0;if(g>>>0>0|(g|0)==0&f>>>0>63){k=e;h=f;do{Ng(r+48|0,r,r+16|0,0)|0;i=0;do{a[b+i>>0]=a[r+48+i>>0]^a[k+i>>0];i=i+1|0}while((i|0)!=64);i=1;j=8;while(1){f=r+j|0;i=(d[f>>0]|0)+i|0;a[f>>0]=i;j=j+1|0;if((j|0)==16)break;else i=i>>>8}h=fg(h|0,g|0,-64,-1)|0;g=z;b=b+64|0;k=k+64|0}while(g>>>0>0|(g|0)==0&h>>>0>63);if(!((h|0)==0&(g|0)==0)){n=b;o=h;p=k;m=8}}else{n=b;o=f;p=e;m=8}if((m|0)==8?(Ng(r+48|0,r,r+16|0,0)|0,o|0):0){i=0;do{a[n+i>>0]=a[r+48+i>>0]^a[p+i>>0];i=i+1|0}while((i|0)!=(o|0))}Sd(r+48|0,64);Sd(r+16|0,32)}l=q;return 0}function Ta(b,c,d,e,f,g,h){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0;j=l;k=l=l+63&-64;l=l+352|0;Ga(k+256|0,g,h,0)|0;if(b>>>0>d>>>0?0<f>>>0|0==(f|0)&(b-d|0)>>>0<e>>>0:0)i=5;else if(d>>>0>b>>>0?0<f>>>0|0==(f|0)&(d-b|0)>>>0<e>>>0:0)i=5;if((i|0)==5){Ed(b|0,d|0,e|0)|0;d=b}h=k+288|0;i=h+32|0;do{a[h>>0]=0;h=h+1|0}while((h|0)<(i|0));h=f>>>0>0|(f|0)==0&e>>>0>32?32:e;i=f>>>0>0|(f|0)==0&e>>>0>32?0:f;if(!((h|0)==0&(i|0)==0)){m=cg(-2,-1,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~e:-33)|0,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~f:-1)|0)|0;fb(k+288+32|0,d|0,m+1|0)|0}m=fg(h|0,i|0,32,0)|0;Of(k+288|0,k+288|0,m,z,g+16|0,k+256|0)|0;_g(k,k+288|0)|0;if(!((h|0)==0&(i|0)==0)){m=cg(-2,-1,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~e:-33)|0,(~f>>>0>4294967295|(~f|0)==-1&~e>>>0>4294967263?~f:-1)|0)|0;fb(b|0,k+288+32|0,m+1|0)|0}Sd(k+288|0,64);if(f>>>0>0|(f|0)==0&e>>>0>32){m=cg(e|0,f|0,h|0,i|0)|0;ef(b+h|0,d+h|0,m,z,g+16|0,1,0,k+256|0)|0}Sd(k+256|0,32);eg(k,b,e,f)|0;Zg(k,c)|0;Sd(k,256);l=j;return 0}function Ua(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0;f=c[b+56>>2]|0;e=c[b+56+4>>2]|0;if(!((f|0)==0&(e|0)==0)){g=1;while(1){a[b+64+f>>0]=g;f=fg(f|0,e|0,1,0)|0;e=z;if(!(e>>>0<0|(e|0)==0&f>>>0<16))break;else g=0}a[b+80>>0]=1;wa(b,b+64|0,16,0)}f=c[b+24>>2]|0;g=(c[b+28>>2]|0)+(f>>>26)|0;k=(g>>>26)+(c[b+32>>2]|0)|0;i=(k>>>26)+(c[b+36>>2]|0)|0;h=((i>>>26)*5|0)+(c[b+20>>2]|0)|0;l=((((h&67108863)+5|0)>>>26)+((h>>>26)+(f&67108863))|0)>>>26;j=(i|-67108864)+((((l+(g&67108863)|0)>>>26)+(k&67108863)|0)>>>26)|0;f=(((h&67108863)+5|0)>>>26)+((h>>>26)+(f&67108863))&67108863&(j>>>31)+-1|j>>31&(h>>>26)+(f&67108863);k=((l+(g&67108863)|0)>>>26)+k&67108863&(j>>>31)+-1|j>>31&(k&67108863);h=fg(h+5&67108863&(j>>>31)+-1|j>>31&(h&67108863)|f<<26|0,0,c[b+40>>2]|0,0)|0;e=z;f=fg(f>>>6|(l+g&67108863&(j>>>31)+-1|j>>31&(g&67108863))<<20|0,0,c[b+44>>2]|0,0)|0;e=fg(f|0,z|0,e|0,0)|0;f=z;g=fg((l+g&67108863&(j>>>31)+-1|j>>31&(g&67108863))>>>12|k<<14|0,0,c[b+48>>2]|0,0)|0;f=fg(g|0,z|0,f|0,0)|0;g=z;i=fg(k>>>18|((j>>>31)+-1&j|j>>31&i)<<8|0,0,c[b+52>>2]|0,0)|0;g=fg(i|0,z|0,g|0,0)|0;jg(d,h);jg(d+4|0,e);jg(d+8|0,f);jg(d+12|0,g);Sd(b,88);return}function Va(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0,q=0;p=l;o=l=l+63&-64;l=l+16|0;m=c[b+20>>2]|0;n=c[b+4>>2]|0;c[b+20>>2]=0;c[b+4>>2]=0;q=(fc(d,34138,8)|0)==0;d=q?d+8|0:d;do if((q?(fc(d,34147,3)|0)==0:0)?(g=nc(d+3|0,o)|0,(g|0)!=0):0)if((c[o>>2]|0)==19)if(((((((fc(g,34151,3)|0)==0?(h=nc(g+3|0,o)|0,i=c[o>>2]|0,(h|0)!=0):0)?(c[b+44>>2]=i,(fc(h,34155,3)|0)==0):0)?(j=nc(h+3|0,o)|0,e=(j|0)==0?i:c[o>>2]|0,(j|0)!=0):0)?(c[b+40>>2]=e,(fc(j,34159,3)|0)==0):0)?(k=nc(j+3|0,o)|0,f=(k|0)==0?e:c[o>>2]|0,(k|0)!=0):0)?(c[b+48>>2]=f,c[b+52>>2]=f,(a[k>>0]|0)==36):0){c[o>>2]=m;d=tc(c[b+16>>2]|0,o,k+1|0)|0;if(!d){d=-32;break}c[b+20>>2]=c[o>>2];if((a[d>>0]|0)==36){c[o>>2]=n;e=tc(c[b>>2]|0,o,d+1|0)|0;if(!e){d=-32;break}c[b+4>>2]=c[o>>2];d=hb(b)|0;if(!d)d=(a[e>>0]|0)==0?0:-32}else d=-32}else d=-32;else d=-26;else d=-32;while(0);l=p;return d|0}function Wa(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0;if(b){m=ia(c[b+12>>2]<<3)|0;if(!m)e=-22;else{gb(b,d,m);i=c[d>>2]|0;f=a[d+8>>0]|0;e=(i|0)==0&f<<24>>24==0?2:0;h=c[b+16>>2]|0;k=O(h,c[d+4>>2]|0)|0;l=c[b+12>>2]|0;f=e+k+(O(l,f&255)|0)|0;a:do if(e>>>0<l>>>0){l=f;g=(((f>>>0)%(h>>>0)|0|0)==0?h+-1|0:-1)+f|0;f=h;while(1){k=((l>>>0)%(f>>>0)|0|0)==1?l+-1|0:g;f=m+(e<<3)|0;h=c[f>>2]|0;f=Pe(c[f+4>>2]|0,0,c[b+20>>2]|0,0)|0;g=z;j=(i|0)==0;if(j?(a[d+8>>0]|0)==0:0){f=c[d+4>>2]|0;g=0}c[d+12>>2]=e;h=Cb(b,d,h,((g|0)==0?(f|0)==(c[d+4>>2]|0):0)&1)|0;i=c[(c[b>>2]|0)+4>>2]|0;f=af(c[b+16>>2]|0,0,f|0,g|0)|0;g=i+(l<<10)|0;if(j)na(i+(k<<10)|0,i+(f<<10)+(h<<10)|0,g);else ma(i+(k<<10)|0,i+(f<<10)+(h<<10)|0,g);e=e+1|0;if(e>>>0>=(c[b+12>>2]|0)>>>0)break a;l=l+1|0;g=k+1|0;f=c[b+16>>2]|0;i=c[d>>2]|0}}while(0);ra(m);e=0}}else e=0;return e|0}function Xa(a,b,d,e,f,g){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0,l=0;if(b<<5|0){h=0;do{c[g+(h<<2)>>2]=Rg(a+(h<<2)|0)|0;h=h+1|0}while((h|0)!=(b<<5|0))}if(!((d|0)==0&(e|0)==0)){h=0;i=0;do{k=af(h|0,i|0,b<<5|0,0)|0;Re(f+(k<<2)|0,g,b<<7);Uc(g,g+(b<<5<<2)|0,g+(b<<6<<2)|0,b);k=af(h|1|0,i|0,b<<5|0,0)|0;Re(f+(k<<2)|0,g+(b<<5<<2)|0,b<<7);Uc(g+(b<<5<<2)|0,g,g+(b<<6<<2)|0,b);h=fg(h|0,i|0,2,0)|0;i=z}while(i>>>0<e>>>0|(i|0)==(e|0)&h>>>0<d>>>0);h=fg(d|0,e|0,-1,-1)|0;i=z;j=0;k=0;do{l=Ig(g,b)|0;l=af(l&h|0,z&i|0,b<<5|0,0)|0;we(g,f+(l<<2)|0,b<<7);Uc(g,g+(b<<5<<2)|0,g+(b<<6<<2)|0,b);l=Ig(g+(b<<5<<2)|0,b)|0;l=af(l&h|0,z&i|0,b<<5|0,0)|0;we(g+(b<<5<<2)|0,f+(l<<2)|0,b<<7);Uc(g+(b<<5<<2)|0,g,g+(b<<6<<2)|0,b);j=fg(j|0,k|0,2,0)|0;k=z}while(k>>>0<e>>>0|(k|0)==(e|0)&j>>>0<d>>>0)}if(b<<5|0){h=0;do{jg(a+(h<<2)|0,c[g+(h<<2)>>2]|0);h=h+1|0}while((h|0)!=(b<<5|0))}return}function Ya(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0;j=l;i=l=l+63&-64;l=l+96|0;Da(i,f,g,0)|0;Cg(i+32|0,32,0,f+16|0,i)|0;if(!(Rf(c,b,d,e,i+32|0)|0))if(!a)c=0;else{if(b>>>0>=a>>>0?0<e>>>0|0==(e|0)&(b-a|0)>>>0<d>>>0:0)h=8;else if(a>>>0>=b>>>0?0<e>>>0|0==(e|0)&(a-b|0)>>>0<d>>>0:0)h=8;if((h|0)==8){Ed(a|0,b|0,d|0)|0;b=a}c=e>>>0>0|(e|0)==0&d>>>0>32?32:d;g=e>>>0>0|(e|0)==0&d>>>0>32?0:e;if((c|0)==0&(g|0)==0)Tf(i+32|0,i+32|0,32,0,f+16|0,i)|0;else{h=cg(-2,-1,(~e>>>0>4294967295|(~e|0)==-1&~d>>>0>4294967263?~d:-33)|0,(~e>>>0>4294967295|(~e|0)==-1&~d>>>0>4294967263?~e:-1)|0)|0;fb(i+32+32|0,b|0,h+1|0)|0;k=fg(c|0,g|0,32,0)|0;Tf(i+32|0,i+32|0,k,z,f+16|0,i)|0;fb(a|0,i+32+32|0,h+1|0)|0}if(e>>>0>0|(e|0)==0&d>>>0>32){k=cg(d|0,e|0,c|0,g|0)|0;jf(a+c|0,b+c|0,k,z,f+16|0,1,0,i)|0}Sd(i,32);c=0}else{Sd(i,32);c=-1}l=j;return c|0}function Za(a,b){a=a|0;b=b|0;var c=0,e=0,f=0;f=l;c=l=l+63&-64;l=l+208|0;xa(a+40|0,b);Bf(a+80|0);qa(c+160|0,a+40|0);la(c+120|0,c+160|0,1152);Fb(c+160|0,c+160|0,a+80|0);Gb(c+120|0,c+120|0,a+80|0);qa(c+80|0,c+120|0);la(c+80|0,c+80|0,c+120|0);qa(a,c+80|0);la(a,a,c+120|0);la(a,a,c+160|0);Ha(a,a);la(a,a,c+80|0);la(a,a,c+160|0);qa(c+40|0,a);la(c+40|0,c+40|0,c+120|0);Fb(c,c+40|0,c+160|0);if(Ge(c)|0){Gb(c,c+40|0,c+160|0);if(!(Ge(c)|0)){la(a,a,1192);e=4}else a=-1}else e=4;if((e|0)==4){e=Ve(a)|0;if((e|0)==((d[b+31>>0]|0)>>>7|0))dc(a,a);la(a+120|0,a,a+40|0);a=0}l=f;return a|0}function _a(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;var m=0,n=0,o=0;o=af(j|0,0,i|0,0)|0;n=z;do if(n>>>0>0|(n|0)==0&o>>>0>1073741823){c[8326]=27;a=-1}else{if(h>>>0>0|(h|0)==0&g>>>0>4294967295){c[8326]=27;a=-1;break}o=fg(g|0,h|0,-1,-1)|0;if(h>>>0<0|(h|0)==0&g>>>0<2|((o&g|0)!=0|(z&h|0)!=0)){c[8326]=22;a=-1;break}if((i|0)==0|(j|0)==0){c[8326]=22;a=-1;break}if(!(i>>>0>16777215?1:(33554431/(j>>>0)|0)>>>0<i>>>0)?!(0<h>>>0|(0==(h|0)?(33554431/(i>>>0)|0)>>>0<g>>>0:0)):0){n=O(i<<7,j)|0;o=O(i<<7,g)|0;if((n+o|0)>>>0<o>>>0){c[8326]=12;a=-1;break}m=n+o+(i<<8|64)|0;if(m>>>0<(i<<8|64)>>>0){c[8326]=12;a=-1;break}if((c[a+8>>2]|0)>>>0<m>>>0?($g(a),(od(a,m)|0)==0):0){a=-1;break}m=c[a+4>>2]|0;cc(b,d,e,f,m,n);a=0;do{Xa(m+(O(i<<7,a)|0)|0,i,g,h,m+n|0,m+n+o|0);a=a+1|0}while((a|0)!=(j|0));cc(b,d,m,n,k,l);a=0;break}c[8326]=12;a=-1}while(0);return a|0}function $a(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0;j=l;i=l=l+63&-64;l=l+96|0;Ga(i,f,g,0)|0;xg(i+32|0,32,0,f+16|0,i)|0;if(!(Rf(c,b,d,e,i+32|0)|0))if(!a)c=0;else{if(b>>>0>=a>>>0?0<e>>>0|0==(e|0)&(b-a|0)>>>0<d>>>0:0)h=8;else if(a>>>0>=b>>>0?0<e>>>0|0==(e|0)&(a-b|0)>>>0<d>>>0:0)h=8;if((h|0)==8){Ed(a|0,b|0,d|0)|0;b=a}c=e>>>0>0|(e|0)==0&d>>>0>32?32:d;g=e>>>0>0|(e|0)==0&d>>>0>32?0:e;if((c|0)==0&(g|0)==0)Of(i+32|0,i+32|0,32,0,f+16|0,i)|0;else{h=cg(-2,-1,(~e>>>0>4294967295|(~e|0)==-1&~d>>>0>4294967263?~d:-33)|0,(~e>>>0>4294967295|(~e|0)==-1&~d>>>0>4294967263?~e:-1)|0)|0;fb(i+32+32|0,b|0,h+1|0)|0;k=fg(c|0,g|0,32,0)|0;Of(i+32|0,i+32|0,k,z,f+16|0,i)|0;fb(a|0,i+32+32|0,h+1|0)|0}if(e>>>0>0|(e|0)==0&d>>>0>32){k=cg(d|0,e|0,c|0,g|0)|0;ef(a+c|0,b+c|0,k,z,f+16|0,1,0,i)|0}Sd(i,32);c=0}else{Sd(i,32);c=-1}l=j;return c|0}function ab(b,c){b=b|0;c=c|0;var e=0,f=0,g=0,h=0,i=0;f=l;g=l=l+63&-64;l=l+464|0;e=0;do{i=a[c+e>>0]|0;h=e<<1;a[g+400+h>>0]=i&15;a[g+400+(h|1)>>0]=(i&255)>>>4;e=e+1|0}while((e|0)!=32);e=0;c=0;do{i=g+400+c|0;h=(d[i>>0]|0)+e|0;e=(h<<24)+134217728>>28;a[i>>0]=h-(e<<4);c=c+1|0}while((c|0)!=63);a[g+400+63>>0]=(d[g+400+63>>0]|0)+e;Ye(b);e=1;do{Jb(g,(e|0)/2|0,a[g+400+e>>0]|0);Wb(g+240|0,b,g);Id(b,g+240|0);e=e+2|0}while((e|0)<64);ye(g+240|0,b);ze(g+120|0,g+240|0);jc(g+240|0,g+120|0);ze(g+120|0,g+240|0);jc(g+240|0,g+120|0);ze(g+120|0,g+240|0);jc(g+240|0,g+120|0);Id(b,g+240|0);e=0;do{Jb(g,(e|0)/2|0,a[g+400+e>>0]|0);Wb(g+240|0,b,g);Id(b,g+240|0);e=e+2|0}while((e|0)<64);l=f;return}function bb(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0,x=0;x=c[a>>2]|0;v=c[a+4>>2]|0;t=c[a+8>>2]|0;r=c[a+12>>2]|0;p=c[a+16>>2]|0;n=c[a+20>>2]|0;l=c[a+24>>2]|0;j=c[a+28>>2]|0;h=c[a+32>>2]|0;f=c[a+36>>2]|0;w=c[b>>2]|0;u=c[b+4>>2]|0;s=c[b+8>>2]|0;q=c[b+12>>2]|0;o=c[b+16>>2]|0;m=c[b+20>>2]|0;k=c[b+24>>2]|0;i=c[b+28>>2]|0;g=c[b+32>>2]|0;e=c[b+36>>2]|0;c[a>>2]=(w^x)&0-d^x;c[a+4>>2]=(u^v)&0-d^v;c[a+8>>2]=(s^t)&0-d^t;c[a+12>>2]=(q^r)&0-d^r;c[a+16>>2]=(o^p)&0-d^p;c[a+20>>2]=(m^n)&0-d^n;c[a+24>>2]=(k^l)&0-d^l;c[a+28>>2]=(i^j)&0-d^j;c[a+32>>2]=(g^h)&0-d^h;c[a+36>>2]=(e^f)&0-d^f;c[b>>2]=(w^x)&0-d^w;c[b+4>>2]=(u^v)&0-d^u;c[b+8>>2]=(s^t)&0-d^s;c[b+12>>2]=(q^r)&0-d^q;c[b+16>>2]=(o^p)&0-d^o;c[b+20>>2]=(m^n)&0-d^m;c[b+24>>2]=(k^l)&0-d^k;c[b+28>>2]=(i^j)&0-d^i;c[b+32>>2]=(g^h)&0-d^g;c[b+36>>2]=(e^f)&0-d^e;return}function cb(b,e,f,g,h){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0,n=0,o=0,p=0;o=l;p=l=l+63&-64;l=l+112|0;if(!((e|0)==0&(f|0)==0)){j=p+16|0;i=j+32|0;do{a[j>>0]=a[h>>0]|0;j=j+1|0;h=h+1|0}while((j|0)<(i|0));j=d[g+4>>0]|d[g+4+1>>0]<<8|d[g+4+2>>0]<<16|d[g+4+3>>0]<<24;c[p>>2]=d[g>>0]|d[g+1>>0]<<8|d[g+2>>0]<<16|d[g+3>>0]<<24;c[p+4>>2]=j;c[p+8>>2]=0;c[p+8+4>>2]=0;if(f>>>0>0|(f|0)==0&e>>>0>63){do{Lg(b,p,p+16|0,0)|0;h=1;i=8;while(1){j=p+i|0;h=(d[j>>0]|0)+h|0;a[j>>0]=h;i=i+1|0;if((i|0)==16)break;else h=h>>>8}e=fg(e|0,f|0,-64,-1)|0;f=z;b=b+64|0}while(f>>>0>0|(f|0)==0&e>>>0>63);if(!((e|0)==0&(f|0)==0)){m=b;n=e;k=7}}else{m=b;n=e;k=7}if((k|0)==7?(Lg(p+48|0,p,p+16|0,0)|0,n|0):0){h=0;do{a[m+h>>0]=a[p+48+h>>0]|0;h=h+1|0}while((h|0)!=(n|0))}Sd(p+48|0,64);Sd(p+16|0,32)}l=o;return 0}function db(b,e,f,g,h){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0,n=0,o=0,p=0;o=l;p=l=l+63&-64;l=l+112|0;if(!((e|0)==0&(f|0)==0)){j=p+16|0;i=j+32|0;do{a[j>>0]=a[h>>0]|0;j=j+1|0;h=h+1|0}while((j|0)<(i|0));j=d[g+4>>0]|d[g+4+1>>0]<<8|d[g+4+2>>0]<<16|d[g+4+3>>0]<<24;c[p>>2]=d[g>>0]|d[g+1>>0]<<8|d[g+2>>0]<<16|d[g+3>>0]<<24;c[p+4>>2]=j;c[p+8>>2]=0;c[p+8+4>>2]=0;if(f>>>0>0|(f|0)==0&e>>>0>63){do{Ng(b,p,p+16|0,0)|0;h=1;i=8;while(1){j=p+i|0;h=(d[j>>0]|0)+h|0;a[j>>0]=h;i=i+1|0;if((i|0)==16)break;else h=h>>>8}e=fg(e|0,f|0,-64,-1)|0;f=z;b=b+64|0}while(f>>>0>0|(f|0)==0&e>>>0>63);if(!((e|0)==0&(f|0)==0)){m=b;n=e;k=7}}else{m=b;n=e;k=7}if((k|0)==7?(Ng(p+48|0,p,p+16|0,0)|0,n|0):0){h=0;do{a[m+h>>0]=a[p+48+h>>0]|0;h=h+1|0}while((h|0)!=(n|0))}Sd(p+48|0,64);Sd(p+16|0,32)}l=o;return 0}function eb(b,e,f,g,h){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0,m=0,n=0,o=0,p=0;o=l;p=l=l+63&-64;l=l+112|0;if(!((e|0)==0&(f|0)==0)){j=p+16|0;i=j+32|0;do{a[j>>0]=a[h>>0]|0;j=j+1|0;h=h+1|0}while((j|0)<(i|0));j=d[g+4>>0]|d[g+4+1>>0]<<8|d[g+4+2>>0]<<16|d[g+4+3>>0]<<24;c[p>>2]=d[g>>0]|d[g+1>>0]<<8|d[g+2>>0]<<16|d[g+3>>0]<<24;c[p+4>>2]=j;c[p+8>>2]=0;c[p+8+4>>2]=0;if(f>>>0>0|(f|0)==0&e>>>0>63){do{Og(b,p,p+16|0,0)|0;h=1;i=8;while(1){j=p+i|0;h=(d[j>>0]|0)+h|0;a[j>>0]=h;i=i+1|0;if((i|0)==16)break;else h=h>>>8}e=fg(e|0,f|0,-64,-1)|0;f=z;b=b+64|0}while(f>>>0>0|(f|0)==0&e>>>0>63);if(!((e|0)==0&(f|0)==0)){m=b;n=e;k=7}}else{m=b;n=e;k=7}if((k|0)==7?(Og(p+48|0,p,p+16|0,0)|0,n|0):0){h=0;do{a[m+h>>0]=a[p+48+h>>0]|0;h=h+1|0}while((h|0)!=(n|0))}Sd(p+48|0,64);Sd(p+16|0,32)}l=o;return 0}function fb(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0;if((e|0)>=8192)return $(b|0,d|0,e|0)|0;h=b|0;g=b+e|0;if((b&3)==(d&3)){while(b&3){if(!e)return h|0;a[b>>0]=a[d>>0]|0;b=b+1|0;d=d+1|0;e=e-1|0}e=g&-4|0;f=e-64|0;while((b|0)<=(f|0)){c[b>>2]=c[d>>2];c[b+4>>2]=c[d+4>>2];c[b+8>>2]=c[d+8>>2];c[b+12>>2]=c[d+12>>2];c[b+16>>2]=c[d+16>>2];c[b+20>>2]=c[d+20>>2];c[b+24>>2]=c[d+24>>2];c[b+28>>2]=c[d+28>>2];c[b+32>>2]=c[d+32>>2];c[b+36>>2]=c[d+36>>2];c[b+40>>2]=c[d+40>>2];c[b+44>>2]=c[d+44>>2];c[b+48>>2]=c[d+48>>2];c[b+52>>2]=c[d+52>>2];c[b+56>>2]=c[d+56>>2];c[b+60>>2]=c[d+60>>2];b=b+64|0;d=d+64|0}while((b|0)<(e|0)){c[b>>2]=c[d>>2];b=b+4|0;d=d+4|0}}else{e=g-4|0;while((b|0)<(e|0)){a[b>>0]=a[d>>0]|0;a[b+1>>0]=a[d+1>>0]|0;a[b+2>>0]=a[d+2>>0]|0;a[b+3>>0]=a[d+3>>0]|0;b=b+4|0;d=d+4|0}}while((b|0)<(g|0)){a[b>>0]=a[d>>0]|0;b=b+1|0;d=d+1|0}return h|0}function gb(a,b,e){a=a|0;b=b|0;e=e|0;var f=0,g=0,h=0,i=0,j=0;g=l;h=l=l+63&-64;l=l+4096|0;Eh(h+3072|0);Eh(h+2048|0);if((a|0)!=0&(b|0)!=0?(c[h+2048>>2]=c[b>>2],c[h+2048+4>>2]=0,c[h+2048+8>>2]=c[b+4>>2],c[h+2048+8+4>>2]=0,c[h+2048+16>>2]=d[b+8>>0],c[h+2048+16+4>>2]=0,c[h+2048+24>>2]=c[a+8>>2],c[h+2048+24+4>>2]=0,c[h+2048+32>>2]=c[a+4>>2],c[h+2048+32+4>>2]=0,c[h+2048+40>>2]=c[a+28>>2],c[h+2048+40+4>>2]=0,c[a+12>>2]|0):0){b=0;do{f=b&127;if(!f){i=fg(c[h+2048+48>>2]|0,c[h+2048+48+4>>2]|0,1,0)|0;c[h+2048+48>>2]=i;c[h+2048+48+4>>2]=z;Eh(h);Eh(h+1024|0);ma(h+3072|0,h+2048|0,h);ma(h+3072|0,h,h+1024|0)}j=c[h+1024+(f<<3)+4>>2]|0;i=e+(b<<3)|0;c[i>>2]=c[h+1024+(f<<3)>>2];c[i+4>>2]=j;b=b+1|0}while(b>>>0<(c[a+12>>2]|0)>>>0)}l=g;return}function hb(a){a=a|0;var b=0,d=0;do if(a)if(c[a>>2]|0)if((c[a+4>>2]|0)>>>0>=16){if((c[a+8>>2]|0)==0?c[a+12>>2]|0:0){b=-18;break}b=c[a+20>>2]|0;if((c[a+16>>2]|0)!=0|(b|0)==0)if(b>>>0>=8){if((c[a+24>>2]|0)==0?c[a+28>>2]|0:0){b=-20;break}if((c[a+32>>2]|0)==0?c[a+36>>2]|0:0){b=-21;break}b=c[a+44>>2]|0;if(b>>>0>=8)if(b>>>0<=2097152){d=c[a+48>>2]|0;if(b>>>0>=d<<3>>>0)if((c[a+40>>2]|0)>>>0>=3)if(d)if(d>>>0>16777215)b=-17;else{a=c[a+52>>2]|0;return ((a|0)==0?-28:a>>>0>16777215?-29:0)|0}else b=-16;else b=-12;else b=-14}else b=-15;else b=-14}else b=-6;else b=-19}else b=-2;else b=-1;else b=-25;while(0);return b|0}function ib(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0;k=l;j=l=l+63&-64;l=l+64|0;e=j+8|0;f=e+52|0;do{c[e>>2]=0;e=e+4|0}while((e|0)<(f|0));e=uc(a)|0;c[j+36>>2]=e;c[j+20>>2]=e;c[j+4>>2]=e;h=ia(e)|0;c[j+32>>2]=h;f=ia(e)|0;c[j+16>>2]=f;g=ia(e)|0;c[j>>2]=g;do if((f|0)==0|(g|0)==0|(h|0)==0){ra(h);ra(f);ra(g);e=-22}else{i=ia(e)|0;if(!i){ra(h);ra(f);ra(g);e=-22;break}e=Va(j,a)|0;if(e|0){ra(c[j+32>>2]|0);ra(c[j+16>>2]|0);ra(c[j>>2]|0);ra(i);break}d=ub(c[j+40>>2]|0,c[j+44>>2]|0,c[j+52>>2]|0,b,d,c[j+16>>2]|0,c[j+20>>2]|0,i,c[j+4>>2]|0,0,0)|0;ra(c[j+32>>2]|0);ra(c[j+16>>2]|0);if((d|0)==0?(Qc(i,c[j>>2]|0,c[j+4>>2]|0)|0)==0:0)e=0;else e=-35;ra(i);ra(c[j>>2]|0)}while(0);l=k;return e|0}function jb(a,b,d,e,f,g){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0;i=b>>>0>0|(b|0)==0&a>>>0>32768?a:32768;h=b>>>0>0|(b|0)==0&a>>>0>32768?b:0;c[g>>2]=8;a:do if(h>>>0<0|(h|0)==0&i>>>0<d>>>5>>>0){c[f>>2]=1;a=ah(i|0,h|0,c[g>>2]<<2|0,0)|0;c[e>>2]=1;a=yf(a|0,z|0,1)|0;b=z;h=1;do{g=vf(1,0,h|0)|0;f=z;h=h+1|0;if(f>>>0>b>>>0|(f|0)==(b|0)&g>>>0>a>>>0)break a;c[e>>2]=h}while(h>>>0<63)}else{c[e>>2]=1;a=1;b=1;while(1){j=vf(1,0,a|0)|0;k=z;b=b+1|0;if(k>>>0>0|(k|0)==0&j>>>0>d>>>11>>>0)break;c[e>>2]=b;if(b>>>0>=63){a=b;break}else a=b}e=yf(i|0,h|0,2)|0;e=yf(e|0,z|0,a|0)|0;j=z;k=j>>>0<0|(j|0)==0&e>>>0<1073741823?e:1073741823;c[f>>2]=(k>>>0)/((c[g>>2]|0)>>>0)|0}while(0);return}function kb(b,e,f,g,h,i,j){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;var k=0,l=0,m=0,n=0,o=0,p=0;a:do if(!g){n=0;l=0;m=0;k=0}else{k=0;n=0;l=0;p=0;while(1){while(1){m=d[f+l>>0]|0;o=(((m&223)+201&255)+65526^((m&223)+201&255)+65520)>>>8;if((o|((m^48)+65526|0)>>>8)&255|0)break;if(!((h|0)!=0&k<<24>>24==0)){m=0;break a}if(!(Kg(h,m)|0)){m=0;k=0;break a}l=l+1|0;if(l>>>0<g>>>0)k=0;else{m=0;k=0;break a}}if(n>>>0>=e>>>0)break;m=(m&223)+201&255&o|((m^48)+65526|0)>>>8&(m^48);if(!(k<<24>>24))m=m<<4&255;else{a[b+n>>0]=m|p&255;n=n+1|0;m=p}k=~k;l=l+1|0;if(l>>>0<g>>>0)p=m;else{m=0;break a}}c[8326]=34;m=-1}while(0);if(j|0)c[j>>2]=f+(((k<<24>>24!=0)<<31>>31)+l);if(i|0)c[i>>2]=n;return m|0}function lb(a,b,c,d,e,f,g,h,i,j,k){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;var m=0;m=l;l=l+352|0;pg(m+280|0,64,0,j,k)|0;_g(m,m+280|0)|0;Sd(m+280|0,64);eg(m,g,h,i)|0;b=cg(0,0,h|0,i|0)|0;eg(m,35896,b&15,0)|0;eg(m,c,d,e)|0;b=cg(0,0,d|0,e|0)|0;eg(m,35896,b&15,0)|0;re(m+272|0,h,i);eg(m,m+272|0,8,0)|0;re(m+272|0,d,e);eg(m,m+272|0,8,0)|0;Zg(m,m+256|0)|0;Sd(m,256);b=Oe(m+256|0,f)|0;Sd(m+256|0,16);do if(a)if(!b){pf(a,c,d,e,j,1,k)|0;b=0;break}else{Pb(a|0,0,d|0)|0;b=-1;break}while(0);l=m;return b|0}function mb(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0;a:do if((e|0)!=0&(b&3|0)!=0){f=e;while(1){if((a[b>>0]|0)==(d&255)<<24>>24)break a;b=b+1|0;e=f+-1|0;if((e|0)!=0&(b&3|0)!=0)f=e;else{f=e;e=(e|0)!=0;g=5;break}}}else{f=e;e=(e|0)!=0;g=5}while(0);b:do if((g|0)==5)if(e){if((a[b>>0]|0)!=(d&255)<<24>>24){e=O(d&255,16843009)|0;c:do if(f>>>0>3)while(1){h=c[b>>2]^e;if((h&-2139062144^-2139062144)&h+-16843009|0)break;b=b+4|0;f=f+-4|0;if(f>>>0<=3){g=11;break c}}else g=11;while(0);if((g|0)==11)if(!f){f=0;break}while(1){if((a[b>>0]|0)==(d&255)<<24>>24)break b;b=b+1|0;f=f+-1|0;if(!f){f=0;break}}}}else f=0;while(0);return (f|0?b:0)|0}function nb(b,c,d,e,f,g){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0;i=l;j=l=l+63&-64;l=l+192|0;if((c+-1&255)>63)Z();if((d|0)!=0&e<<24>>24!=0?(e&255)<=64:0){a[j+128>>0]=c;a[j+128+1>>0]=e;a[j+128+2>>0]=1;a[j+128+3>>0]=1;Vg(j+128+4|0);bf(j+128+8|0);c=j+128+16|0;h=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(h|0));if(!f){c=j+128+32|0;h=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(h|0))}else lf(j+128|0,f);if(!g){c=j+128+48|0;h=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(h|0))}else kf(j+128|0,g);ud(b,j+128|0);Pb(j+(e&255)|0,0,128-(e&255)|0)|0;fb(j|0,d|0,e&255|0)|0;Bb(b,j,128,0);Sd(j,128);l=i;return}Z()}function ob(a){a=a|0;var b=0,d=0,e=0,f=0;if(a>>>0>=4294967168){c[8326]=12;f=0;return f|0}f=a>>>0<11?16:a+11&-8;e=ia(f+76|0)|0;if(!e){f=0;return f|0}do if(e&63){d=((e+63&-64)+-8-(e+-8)|0)>>>0>15?(e+63&-64)+-8|0:(e+63&-64)+56|0;a=d-(e+-8)|0;b=c[e+-4>>2]|0;if(!(b&3)){c[d>>2]=(c[e+-8>>2]|0)+a;c[d+4>>2]=(b&-8)-a;a=d;break}else{c[d+4>>2]=(b&-8)-a|c[d+4>>2]&1|2;c[d+((b&-8)-a)+4>>2]=c[d+((b&-8)-a)+4>>2]|1;c[e+-4>>2]=a|c[e+-4>>2]&1|2;c[d+4>>2]=c[d+4>>2]|1;sa(e+-8|0,a);a=d;break}}else{a=e+-8|0;d=e+-8|0}while(0);a=a+4|0;b=c[a>>2]|0;if(b&3|0?(b&-8)>>>0>(f+16|0)>>>0:0){e=d+f|0;c[a>>2]=f|b&1|2;c[e+4>>2]=(b&-8)-f|3;c[e+((b&-8)-f)+4>>2]=c[e+((b&-8)-f)+4>>2]|1;sa(e,(b&-8)-f|0)}f=d+8|0;return f|0}function pb(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0;h=l;l=l+192|0;if(d>>>0>128){me(b)|0;Ea(b,c,d,0)|0;Be(b,h)|0;d=64;c=h}me(b)|0;e=h+64|0;f=e+128|0;do{a[e>>0]=54;e=e+1|0}while((e|0)<(f|0));g=(d|0)==0;if(!g?(a[h+64>>0]=a[c>>0]^54,(d|0)!=1):0){e=1;do{f=h+64+e|0;a[f>>0]=a[f>>0]^a[c+e>>0];e=e+1|0}while((e|0)!=(d|0))}Ea(b,h+64|0,128,0)|0;me(b+208|0)|0;e=h+64|0;f=e+128|0;do{a[e>>0]=92;e=e+1|0}while((e|0)<(f|0));if(!g?(a[h+64>>0]=a[c>>0]^92,(d|0)!=1):0){e=1;do{g=h+64+e|0;a[g>>0]=a[g>>0]^a[c+e>>0];e=e+1|0}while((e|0)!=(d|0))}Ea(b+208|0,h+64|0,128,0)|0;Sd(h+64|0,128);Sd(h,64);l=h;return 0}function qb(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0;h=l;l=l+96|0;if(d>>>0>64){td(b)|0;La(b,c,d,0)|0;Fe(b,h)|0;d=32;c=h}td(b)|0;e=h+32|0;f=e+64|0;do{a[e>>0]=54;e=e+1|0}while((e|0)<(f|0));g=(d|0)==0;if(!g?(a[h+32>>0]=a[c>>0]^54,(d|0)!=1):0){e=1;do{f=h+32+e|0;a[f>>0]=a[f>>0]^a[c+e>>0];e=e+1|0}while((e|0)!=(d|0))}La(b,h+32|0,64,0)|0;td(b+104|0)|0;e=h+32|0;f=e+64|0;do{a[e>>0]=92;e=e+1|0}while((e|0)<(f|0));if(!g?(a[h+32>>0]=a[c>>0]^92,(d|0)!=1):0){e=1;do{g=h+32+e|0;a[g>>0]=a[g>>0]^a[c+e>>0];e=e+1|0}while((e|0)!=(d|0))}La(b+104|0,h+32|0,64,0)|0;Sd(h+32|0,64);Sd(h,32);l=h;return 0}function rb(b,c){b=b|0;c=c|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+16|0;Ce(f,b);a[b>>0]=a[f+(d[c>>0]|0)>>0]|0;a[b+1>>0]=a[f+(d[c+1>>0]|0)>>0]|0;a[b+2>>0]=a[f+(d[c+2>>0]|0)>>0]|0;a[b+3>>0]=a[f+(d[c+3>>0]|0)>>0]|0;a[b+4>>0]=a[f+(d[c+4>>0]|0)>>0]|0;a[b+5>>0]=a[f+(d[c+5>>0]|0)>>0]|0;a[b+6>>0]=a[f+(d[c+6>>0]|0)>>0]|0;a[b+7>>0]=a[f+(d[c+7>>0]|0)>>0]|0;a[b+8>>0]=a[f+(d[c+8>>0]|0)>>0]|0;a[b+9>>0]=a[f+(d[c+9>>0]|0)>>0]|0;a[b+10>>0]=a[f+(d[c+10>>0]|0)>>0]|0;a[b+11>>0]=a[f+(d[c+11>>0]|0)>>0]|0;a[b+12>>0]=a[f+(d[c+12>>0]|0)>>0]|0;a[b+13>>0]=a[f+(d[c+13>>0]|0)>>0]|0;a[b+14>>0]=a[f+(d[c+14>>0]|0)>>0]|0;a[b+15>>0]=a[f+(d[c+15>>0]|0)>>0]|0;l=e;return}function sb(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0,w=0;w=c[a>>2]|0;u=c[a+4>>2]|0;s=c[a+8>>2]|0;q=c[a+12>>2]|0;o=c[a+16>>2]|0;m=c[a+20>>2]|0;k=c[a+24>>2]|0;i=c[a+28>>2]|0;g=c[a+32>>2]|0;e=c[a+36>>2]|0;v=(c[b+4>>2]^u)&0-d;t=(c[b+8>>2]^s)&0-d;r=(c[b+12>>2]^q)&0-d;p=(c[b+16>>2]^o)&0-d;n=(c[b+20>>2]^m)&0-d;l=(c[b+24>>2]^k)&0-d;j=(c[b+28>>2]^i)&0-d;h=(c[b+32>>2]^g)&0-d;f=(c[b+36>>2]^e)&0-d;c[a>>2]=(c[b>>2]^w)&0-d^w;c[a+4>>2]=v^u;c[a+8>>2]=t^s;c[a+12>>2]=r^q;c[a+16>>2]=p^o;c[a+20>>2]=n^m;c[a+24>>2]=l^k;c[a+28>>2]=j^i;c[a+32>>2]=h^g;c[a+36>>2]=f^e;return}function tb(b,d,e,f,g,h,i){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0;j=l;k=l=l+63&-64;l=l+560|0;de(k+496|0,h,32,0)|0;a[k+496>>0]=a[k+496>>0]&-8;a[k+496+31>>0]=a[k+496+31>>0]&63|64;ag(k,i);Ea(k,k+496+32|0,32,0)|0;Ea(k,e,f,g)|0;Be(k,k+432|0)|0;Ed(b+32|0,h+32|0,32)|0;ka(k+432|0);ab(k+208|0,k+432|0);Ic(b,k+208|0);ag(k,i);Ea(k,b,64,0)|0;Ea(k,e,f,g)|0;Be(k,k+368|0)|0;ka(k+368|0);ha(b+32|0,k+368|0,k+496|0,k+432|0);Sd(k+496|0,64);if(d|0){c[d>>2]=64;c[d+4>>2]=0}l=j;return}function ub(a,b,d,e,f,g,h,i,j,k,m){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;var n=0,o=0,p=0;p=l;o=l=l+63&-64;l=l+64|0;n=ia(j)|0;do if(!n)a=-22;else{c[o>>2]=n;c[o+4>>2]=j;c[o+8>>2]=e;c[o+12>>2]=f;c[o+16>>2]=g;c[o+20>>2]=h;c[o+24>>2]=0;c[o+24+4>>2]=0;c[o+24+8>>2]=0;c[o+24+12>>2]=0;c[o+40>>2]=a;c[o+44>>2]=b;c[o+48>>2]=d;c[o+52>>2]=d;c[o+56>>2]=4;a=$b(o)|0;if(a|0){Sd(n,j);ra(n);break}if(i|0)fb(i|0,n|0,j|0)|0;if((k|0)!=0&(m|0)!=0?Ia(k,m,o)|0:0){Sd(n,j);Sd(k,m);ra(n);a=-31;break}Sd(n,j);ra(n);a=0}while(0);l=p;return a|0}function vb(a,b,c,e,f,g){a=a|0;b=b|0;c=c|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0;k=l;j=l=l+63&-64;l=l+592|0;if(((nd(a+32|0)|0)==0?(xd(a)|0)==0:0)?(Za(j+328|0,f)|0)==0:0){h=0;i=0;do{i=d[f+h>>0]|0|i;h=h+1|0}while((h|0)!=32);if(i){ag(j,g);Ea(j,a,32,0)|0;Ea(j,f,32,0)|0;Ea(j,b,c,e)|0;Be(j,j+520|0)|0;ka(j+520|0);Ba(j+208|0,j+520|0,j+328|0,a+32|0);Ic(j+488|0,j+208|0);h=Ne(j+488|0,a)|0;h=((j+488|0)==(a|0)?-1:h)|(Qc(a,j+488|0,32)|0)}else h=-1}else h=-1;l=k;return h|0}function wb(b,d,e,f,g){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0,k=0,m=0,n=0,o=0,p=0;p=l;o=l=l+63&-64;l=l+48|0;if((((((a[f>>0]|0)==36?(a[f+1>>0]|0)==55:0)?(a[f+2>>0]|0)==36:0)?(_f(o+8|0,a[f+3>>0]|0)|0)==0:0)?(j=vf(1,0,c[o+8>>2]|0)|0,k=z,h=Tc(o+4|0,f+4|0)|0,(h|0)!=0):0)?(m=Tc(o,h)|0,(m|0)!=0):0){h=Bh(m)|0;if(!h)h=uc(m)|0;else h=h-m|0;i=h+(m-f)|0;if((!((i+45|0)>>>0>102|(i+45|0)>>>0<h>>>0)?(_a(b,d,e,m,h,j,k,c[o+4>>2]|0,c[o>>2]|0,o+16|0,32)|0)==0:0)?(fb(g|0,f|0,i|0)|0,a[g+i>>0]=36,n=Rc(g+i+1|0,g+102-(g+i+1)|0,o+16|0)|0,Sd(o+16|0,32),(n|0)!=0&n>>>0<(g+102|0)>>>0):0)a[n>>0]=0;else g=0}else g=0;l=p;return g|0}function xb(b){b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0;j=l;i=l=l+63&-64;l=l+32|0;a:do if(((b|0)!=0?(d=c[b+20>>2]|0,(d|0)!=0):0)?(c[b+4>>2]|0)!=0:0){h=0;while(1){g=0;do{if(!d)d=0;else{f=g&255;e=0;do{c[i>>2]=h;c[i+4>>2]=e;a[i+8>>0]=f;c[i+12>>2]=0;c[i+16>>2]=c[i>>2];c[i+16+4>>2]=c[i+4>>2];c[i+16+8>>2]=c[i+8>>2];c[i+16+12>>2]=c[i+12>>2];d=Wa(b,i+16|0)|0;e=e+1|0;if(d|0)break a;d=c[b+20>>2]|0}while(e>>>0<d>>>0)}g=g+1|0}while(g>>>0<4);h=h+1|0;if(h>>>0>=(c[b+4>>2]|0)>>>0){d=0;break}}}else d=0;while(0);l=j;return d|0}function yb(a,b,d,e,f,g,h,i,j,k,m,n){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;n=n|0;k=l;l=l+336|0;pg(k+264|0,64,0,m,n)|0;_g(k,k+264|0)|0;Sd(k+264|0,64);eg(k,h,i,j)|0;h=cg(0,0,i|0,j|0)|0;eg(k,35896,h&15,0)|0;pf(a,e,f,g,m,1,n)|0;eg(k,a,f,g)|0;h=cg(0,0,f|0,g|0)|0;eg(k,35896,h&15,0)|0;re(k+256|0,i,j);eg(k,k+256|0,8,0)|0;re(k+256|0,f,g);eg(k,k+256|0,8,0)|0;Zg(k,b)|0;Sd(k,256);if(d|0){c[d>>2]=16;c[d+4>>2]=0}l=k;return 0}function zb(a,b,c,d,e,f,g,h,i,j,k){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;var m=0;m=l;l=l+352|0;Cg(m+280|0,64,0,j,k)|0;_g(m,m+280|0)|0;Sd(m+280|0,64);eg(m,g,h,i)|0;re(m+272|0,h,i);eg(m,m+272|0,8,0)|0;eg(m,c,d,e)|0;re(m+272|0,d,e);eg(m,m+272|0,8,0)|0;Zg(m,m+256|0)|0;Sd(m,256);b=Oe(m+256|0,f)|0;Sd(m+256|0,16);do if(a)if(!b){jf(a,c,d,e,j,1,0,k)|0;b=0;break}else{Pb(a|0,0,d|0)|0;b=-1;break}while(0);l=m;return b|0} +function da(a,b){a=a|0;b=b|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+272|0;c[e+256>>2]=c[b>>2];c[e+256+4>>2]=c[b+4>>2];c[e+256+8>>2]=c[b+8>>2];c[e+256+12>>2]=c[b+12>>2];rb(e+256|0,35222);Ce(e+240|0,e+256|0);Ce(e+224|0,e+256|0);Ce(e+208|0,e+256|0);Ce(e+192|0,e+256|0);Ce(e+176|0,e+256|0);Ce(e+160|0,e+256|0);Ce(e+144|0,e+256|0);Ce(e,e+160|0);_d(e,1);Gd(e,e+144|0);Hd(e,1104);Gd(e+144|0,e);ae(e,1);Gd(e+160|0,e);Ce(e,e+192|0);_d(e,1);Gd(e,e+176|0);Hd(e,1104);Gd(e+176|0,e);ae(e,1);Gd(e+192|0,e);Ce(e,e+224|0);_d(e,1);Gd(e,e+208|0);Hd(e,1104);Gd(e+208|0,e);ae(e,1);Gd(e+224|0,e);Ce(e,e+256|0);_d(e,1);Gd(e,e+240|0);Hd(e,1104);Gd(e+240|0,e);ae(e,1);Gd(e+256|0,e);Ce(e,e+176|0);_d(e,2);Gd(e,e+144|0);Hd(e,1120);Gd(e+144|0,e);ae(e,2);Gd(e+176|0,e);Ce(e,e+192|0);_d(e,2);Gd(e,e+160|0);Hd(e,1120);Gd(e+160|0,e);ae(e,2);Gd(e+192|0,e);Ce(e,e+240|0);_d(e,2);Gd(e,e+208|0);Hd(e,1120);Gd(e+208|0,e);ae(e,2);Gd(e+240|0,e);Ce(e,e+256|0);_d(e,2);Gd(e,e+224|0);Hd(e,1120);Gd(e+224|0,e);ae(e,2);Gd(e+256|0,e);Ce(e,e+208|0);_d(e,4);Gd(e,e+144|0);Hd(e,1136);Gd(e+144|0,e);ae(e,4);Gd(e+208|0,e);Ce(e,e+224|0);_d(e,4);Gd(e,e+160|0);Hd(e,1136);Gd(e+160|0,e);ae(e,4);Gd(e+224|0,e);Ce(e,e+240|0);_d(e,4);Gd(e,e+176|0);Hd(e,1136);Gd(e+176|0,e);ae(e,4);Gd(e+240|0,e);Ce(e,e+256|0);_d(e,4);Gd(e,e+192|0);Hd(e,1136);Gd(e+192|0,e);ae(e,4);Gd(e+256|0,e);c[a>>2]=c[e+256>>2];c[a+4>>2]=c[e+256+4>>2];c[a+8>>2]=c[e+256+8>>2];c[a+12>>2]=c[e+256+12>>2];c[a+16>>2]=c[e+240>>2];c[a+16+4>>2]=c[e+240+4>>2];c[a+16+8>>2]=c[e+240+8>>2];c[a+16+12>>2]=c[e+240+12>>2];c[a+32>>2]=c[e+224>>2];c[a+32+4>>2]=c[e+224+4>>2];c[a+32+8>>2]=c[e+224+8>>2];c[a+32+12>>2]=c[e+224+12>>2];c[a+48>>2]=c[e+208>>2];c[a+48+4>>2]=c[e+208+4>>2];c[a+48+8>>2]=c[e+208+8>>2];c[a+48+12>>2]=c[e+208+12>>2];c[a+64>>2]=c[e+192>>2];c[a+64+4>>2]=c[e+192+4>>2];c[a+64+8>>2]=c[e+192+8>>2];c[a+64+12>>2]=c[e+192+12>>2];c[a+80>>2]=c[e+176>>2];c[a+80+4>>2]=c[e+176+4>>2];c[a+80+8>>2]=c[e+176+8>>2];c[a+80+12>>2]=c[e+176+12>>2];c[a+96>>2]=c[e+160>>2];c[a+96+4>>2]=c[e+160+4>>2];c[a+96+8>>2]=c[e+160+8>>2];c[a+96+12>>2]=c[e+160+12>>2];c[a+112>>2]=c[e+144>>2];c[a+112+4>>2]=c[e+144+4>>2];c[a+112+8>>2]=c[e+144+8>>2];c[a+112+12>>2]=c[e+144+12>>2];rb(e+256|0,35206);rb(e+240|0,35206);rb(e+224|0,35206);rb(e+208|0,35206);rb(e+192|0,35206);rb(e+176|0,35206);rb(e+160|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+160|0);Gd(e+224|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+160|0,e+224|0);Gd(e+208|0,e+256|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+144|0);Gd(e+208|0,e+192|0);Gd(e+144|0,e+176|0);Gd(e+208|0,e+240|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+224|0);Ce(e+64|0,e+160|0);Gd(e+80|0,e+192|0);Gd(e+96|0,e+224|0);Gd(e+112|0,e+208|0);Gd(e+48|0,e+192|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+208|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+160|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+224|0);Ce(e+48|0,e+192|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+208|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+160|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+160|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+176|0);Hd(e+160|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+160|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+208|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+208|0);Hd(e+256|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+256|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+160|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+208|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+192|0);Gd(e+128|0,e+224|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+224|0);Hd(e+192|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+192|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+224|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+160|0);Gd(e+192|0,e+144|0);Gd(e+160|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+224|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+208|0);Gd(e+208|0,e+176|0);Gd(e+160|0,e+208|0);dh(e+256|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+192|0,35238);rb(e+160|0,35238);rb(e+208|0,35238);rb(e+144|0,35238);rb(e+224|0,35238);rb(e+176|0,35238);rb(e+256|0,35238);c[e+128>>2]=c[a>>2];c[e+128+4>>2]=c[a+4>>2];c[e+128+8>>2]=c[a+8>>2];c[e+128+12>>2]=c[a+12>>2];c[e+112>>2]=c[a+16>>2];c[e+112+4>>2]=c[a+16+4>>2];c[e+112+8>>2]=c[a+16+8>>2];c[e+112+12>>2]=c[a+16+12>>2];c[e+96>>2]=c[a+32>>2];c[e+96+4>>2]=c[a+32+4>>2];c[e+96+8>>2]=c[a+32+8>>2];c[e+96+12>>2]=c[a+32+12>>2];c[e+80>>2]=c[a+48>>2];c[e+80+4>>2]=c[a+48+4>>2];c[e+80+8>>2]=c[a+48+8>>2];c[e+80+12>>2]=c[a+48+12>>2];c[e+64>>2]=c[a+64>>2];c[e+64+4>>2]=c[a+64+4>>2];c[e+64+8>>2]=c[a+64+8>>2];c[e+64+12>>2]=c[a+64+12>>2];c[e+48>>2]=c[a+80>>2];c[e+48+4>>2]=c[a+80+4>>2];c[e+48+8>>2]=c[a+80+8>>2];c[e+48+12>>2]=c[a+80+12>>2];c[e+32>>2]=c[a+96>>2];c[e+32+4>>2]=c[a+96+4>>2];c[e+32+8>>2]=c[a+96+8>>2];c[e+32+12>>2]=c[a+96+12>>2];c[e+16>>2]=c[a+112>>2];c[e+16+4>>2]=c[a+112+4>>2];c[e+16+8>>2]=c[a+112+8>>2];c[e+16+12>>2]=c[a+112+12>>2];Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);c[a+128>>2]=c[e+256>>2];c[a+128+4>>2]=c[e+256+4>>2];c[a+128+8>>2]=c[e+256+8>>2];c[a+128+12>>2]=c[e+256+12>>2];c[a+144>>2]=c[e+240>>2];c[a+144+4>>2]=c[e+240+4>>2];c[a+144+8>>2]=c[e+240+8>>2];c[a+144+12>>2]=c[e+240+12>>2];c[a+160>>2]=c[e+192>>2];c[a+160+4>>2]=c[e+192+4>>2];c[a+160+8>>2]=c[e+192+8>>2];c[a+160+12>>2]=c[e+192+12>>2];c[a+176>>2]=c[e+160>>2];c[a+176+4>>2]=c[e+160+4>>2];c[a+176+8>>2]=c[e+160+8>>2];c[a+176+12>>2]=c[e+160+12>>2];c[a+192>>2]=c[e+208>>2];c[a+192+4>>2]=c[e+208+4>>2];c[a+192+8>>2]=c[e+208+8>>2];c[a+192+12>>2]=c[e+208+12>>2];c[a+208>>2]=c[e+144>>2];c[a+208+4>>2]=c[e+144+4>>2];c[a+208+8>>2]=c[e+144+8>>2];c[a+208+12>>2]=c[e+144+12>>2];c[a+224>>2]=c[e+224>>2];c[a+224+4>>2]=c[e+224+4>>2];c[a+224+8>>2]=c[e+224+8>>2];c[a+224+12>>2]=c[e+224+12>>2];c[a+240>>2]=c[e+176>>2];c[a+240+4>>2]=c[e+176+4>>2];c[a+240+8>>2]=c[e+176+8>>2];c[a+240+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+224|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+192|0,35206);rb(e+160|0,35206);rb(e+208|0,35206);rb(e+144|0,35206);rb(e+224|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+224|0);Gd(e+192|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+224|0,e+192|0);Gd(e+160|0,e+256|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+176|0);Gd(e+160|0,e+208|0);Gd(e+176|0,e+144|0);Gd(e+160|0,e+240|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+192|0);Ce(e+64|0,e+224|0);Gd(e+80|0,e+208|0);Gd(e+96|0,e+192|0);Gd(e+112|0,e+160|0);Gd(e+48|0,e+208|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+160|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+224|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+192|0);Ce(e+48|0,e+208|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+160|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+224|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+224|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+144|0);Hd(e+224|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+224|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+160|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+160|0);Hd(e+256|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+256|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+224|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+160|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+208|0);Gd(e+128|0,e+192|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+192|0);Hd(e+208|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+208|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+192|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+224|0);Gd(e+208|0,e+176|0);Gd(e+224|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+192|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+160|0);Gd(e+160|0,e+144|0);Gd(e+224|0,e+160|0);dh(e+240|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+208|0,35238);rb(e+224|0,35238);rb(e+160|0,35238);rb(e+176|0,35238);rb(e+192|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+128>>2];c[e+128+4>>2]=c[a+128+4>>2];c[e+128+8>>2]=c[a+128+8>>2];c[e+128+12>>2]=c[a+128+12>>2];c[e+112>>2]=c[a+144>>2];c[e+112+4>>2]=c[a+144+4>>2];c[e+112+8>>2]=c[a+144+8>>2];c[e+112+12>>2]=c[a+144+12>>2];c[e+96>>2]=c[a+160>>2];c[e+96+4>>2]=c[a+160+4>>2];c[e+96+8>>2]=c[a+160+8>>2];c[e+96+12>>2]=c[a+160+12>>2];c[e+80>>2]=c[a+176>>2];c[e+80+4>>2]=c[a+176+4>>2];c[e+80+8>>2]=c[a+176+8>>2];c[e+80+12>>2]=c[a+176+12>>2];c[e+64>>2]=c[a+192>>2];c[e+64+4>>2]=c[a+192+4>>2];c[e+64+8>>2]=c[a+192+8>>2];c[e+64+12>>2]=c[a+192+12>>2];c[e+48>>2]=c[a+208>>2];c[e+48+4>>2]=c[a+208+4>>2];c[e+48+8>>2]=c[a+208+8>>2];c[e+48+12>>2]=c[a+208+12>>2];c[e+32>>2]=c[a+224>>2];c[e+32+4>>2]=c[a+224+4>>2];c[e+32+8>>2]=c[a+224+8>>2];c[e+32+12>>2]=c[a+224+12>>2];c[e+16>>2]=c[a+240>>2];c[e+16+4>>2]=c[a+240+4>>2];c[e+16+8>>2]=c[a+240+8>>2];c[e+16+12>>2]=c[a+240+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);c[a+256>>2]=c[e+256>>2];c[a+256+4>>2]=c[e+256+4>>2];c[a+256+8>>2]=c[e+256+8>>2];c[a+256+12>>2]=c[e+256+12>>2];c[a+272>>2]=c[e+240>>2];c[a+272+4>>2]=c[e+240+4>>2];c[a+272+8>>2]=c[e+240+8>>2];c[a+272+12>>2]=c[e+240+12>>2];c[a+288>>2]=c[e+208>>2];c[a+288+4>>2]=c[e+208+4>>2];c[a+288+8>>2]=c[e+208+8>>2];c[a+288+12>>2]=c[e+208+12>>2];c[a+304>>2]=c[e+224>>2];c[a+304+4>>2]=c[e+224+4>>2];c[a+304+8>>2]=c[e+224+8>>2];c[a+304+12>>2]=c[e+224+12>>2];c[a+320>>2]=c[e+160>>2];c[a+320+4>>2]=c[e+160+4>>2];c[a+320+8>>2]=c[e+160+8>>2];c[a+320+12>>2]=c[e+160+12>>2];c[a+336>>2]=c[e+176>>2];c[a+336+4>>2]=c[e+176+4>>2];c[a+336+8>>2]=c[e+176+8>>2];c[a+336+12>>2]=c[e+176+12>>2];c[a+352>>2]=c[e+192>>2];c[a+352+4>>2]=c[e+192+4>>2];c[a+352+8>>2]=c[e+192+8>>2];c[a+352+12>>2]=c[e+192+12>>2];c[a+368>>2]=c[e+144>>2];c[a+368+4>>2]=c[e+144+4>>2];c[a+368+8>>2]=c[e+144+8>>2];c[a+368+12>>2]=c[e+144+12>>2];Le(e+256|0);Le(e+240|0);Le(e+176|0);Le(e+192|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+208|0,35206);rb(e+224|0,35206);rb(e+160|0,35206);rb(e+176|0,35206);rb(e+192|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+192|0);Gd(e+208|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+192|0,e+208|0);Gd(e+224|0,e+256|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+144|0);Gd(e+224|0,e+160|0);Gd(e+144|0,e+176|0);Gd(e+224|0,e+240|0);Gd(e+160|0,e+176|0);Gd(e+208|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+208|0);Ce(e+64|0,e+192|0);Gd(e+80|0,e+160|0);Gd(e+96|0,e+208|0);Gd(e+112|0,e+224|0);Gd(e+48|0,e+160|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+224|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+192|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+208|0);Ce(e+48|0,e+160|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+224|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+192|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+192|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+176|0);Hd(e+192|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+192|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+224|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+224|0);Hd(e+256|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+256|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+192|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+224|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+160|0);Gd(e+128|0,e+208|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+208|0);Hd(e+160|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+160|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+208|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+192|0);Gd(e+160|0,e+144|0);Gd(e+192|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+208|0);Gd(e+160|0,e+176|0);Gd(e+208|0,e+224|0);Gd(e+224|0,e+176|0);Gd(e+192|0,e+224|0);dh(e+160|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+160|0,35238);rb(e+192|0,35238);rb(e+224|0,35238);rb(e+144|0,35238);rb(e+208|0,35238);rb(e+176|0,35238);c[e+128>>2]=c[a+256>>2];c[e+128+4>>2]=c[a+256+4>>2];c[e+128+8>>2]=c[a+256+8>>2];c[e+128+12>>2]=c[a+256+12>>2];c[e+112>>2]=c[a+272>>2];c[e+112+4>>2]=c[a+272+4>>2];c[e+112+8>>2]=c[a+272+8>>2];c[e+112+12>>2]=c[a+272+12>>2];c[e+96>>2]=c[a+288>>2];c[e+96+4>>2]=c[a+288+4>>2];c[e+96+8>>2]=c[a+288+8>>2];c[e+96+12>>2]=c[a+288+12>>2];c[e+80>>2]=c[a+304>>2];c[e+80+4>>2]=c[a+304+4>>2];c[e+80+8>>2]=c[a+304+8>>2];c[e+80+12>>2]=c[a+304+12>>2];c[e+64>>2]=c[a+320>>2];c[e+64+4>>2]=c[a+320+4>>2];c[e+64+8>>2]=c[a+320+8>>2];c[e+64+12>>2]=c[a+320+12>>2];c[e+48>>2]=c[a+336>>2];c[e+48+4>>2]=c[a+336+4>>2];c[e+48+8>>2]=c[a+336+8>>2];c[e+48+12>>2]=c[a+336+12>>2];c[e+32>>2]=c[a+352>>2];c[e+32+4>>2]=c[a+352+4>>2];c[e+32+8>>2]=c[a+352+8>>2];c[e+32+12>>2]=c[a+352+12>>2];c[e+16>>2]=c[a+368>>2];c[e+16+4>>2]=c[a+368+4>>2];c[e+16+8>>2]=c[a+368+8>>2];c[e+16+12>>2]=c[a+368+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);c[a+384>>2]=c[e+256>>2];c[a+384+4>>2]=c[e+256+4>>2];c[a+384+8>>2]=c[e+256+8>>2];c[a+384+12>>2]=c[e+256+12>>2];c[a+400>>2]=c[e+240>>2];c[a+400+4>>2]=c[e+240+4>>2];c[a+400+8>>2]=c[e+240+8>>2];c[a+400+12>>2]=c[e+240+12>>2];c[a+416>>2]=c[e+160>>2];c[a+416+4>>2]=c[e+160+4>>2];c[a+416+8>>2]=c[e+160+8>>2];c[a+416+12>>2]=c[e+160+12>>2];c[a+432>>2]=c[e+192>>2];c[a+432+4>>2]=c[e+192+4>>2];c[a+432+8>>2]=c[e+192+8>>2];c[a+432+12>>2]=c[e+192+12>>2];c[a+448>>2]=c[e+224>>2];c[a+448+4>>2]=c[e+224+4>>2];c[a+448+8>>2]=c[e+224+8>>2];c[a+448+12>>2]=c[e+224+12>>2];c[a+464>>2]=c[e+144>>2];c[a+464+4>>2]=c[e+144+4>>2];c[a+464+8>>2]=c[e+144+8>>2];c[a+464+12>>2]=c[e+144+12>>2];c[a+480>>2]=c[e+208>>2];c[a+480+4>>2]=c[e+208+4>>2];c[a+480+8>>2]=c[e+208+8>>2];c[a+480+12>>2]=c[e+208+12>>2];c[a+496>>2]=c[e+176>>2];c[a+496+4>>2]=c[e+176+4>>2];c[a+496+8>>2]=c[e+176+8>>2];c[a+496+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+208|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+160|0,35206);rb(e+192|0,35206);rb(e+224|0,35206);rb(e+144|0,35206);rb(e+208|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+208|0);Gd(e+160|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+208|0,e+160|0);Gd(e+192|0,e+256|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+176|0);Gd(e+192|0,e+224|0);Gd(e+176|0,e+144|0);Gd(e+192|0,e+240|0);Gd(e+224|0,e+144|0);Gd(e+160|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+160|0);Ce(e+64|0,e+208|0);Gd(e+80|0,e+224|0);Gd(e+96|0,e+160|0);Gd(e+112|0,e+192|0);Gd(e+48|0,e+224|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+192|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+208|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+160|0);Ce(e+48|0,e+224|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+192|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+208|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+208|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+144|0);Hd(e+208|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+208|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+192|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+192|0);Hd(e+256|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+256|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+208|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+192|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+224|0);Gd(e+128|0,e+160|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+160|0);Hd(e+224|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+224|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+160|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+208|0);Gd(e+224|0,e+176|0);Gd(e+208|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+160|0);Gd(e+224|0,e+144|0);Gd(e+160|0,e+192|0);Gd(e+192|0,e+144|0);Gd(e+208|0,e+192|0);dh(e+208|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+224|0,35238);rb(e+208|0,35238);rb(e+192|0,35238);rb(e+176|0,35238);rb(e+160|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+384>>2];c[e+128+4>>2]=c[a+384+4>>2];c[e+128+8>>2]=c[a+384+8>>2];c[e+128+12>>2]=c[a+384+12>>2];c[e+112>>2]=c[a+400>>2];c[e+112+4>>2]=c[a+400+4>>2];c[e+112+8>>2]=c[a+400+8>>2];c[e+112+12>>2]=c[a+400+12>>2];c[e+96>>2]=c[a+416>>2];c[e+96+4>>2]=c[a+416+4>>2];c[e+96+8>>2]=c[a+416+8>>2];c[e+96+12>>2]=c[a+416+12>>2];c[e+80>>2]=c[a+432>>2];c[e+80+4>>2]=c[a+432+4>>2];c[e+80+8>>2]=c[a+432+8>>2];c[e+80+12>>2]=c[a+432+12>>2];c[e+64>>2]=c[a+448>>2];c[e+64+4>>2]=c[a+448+4>>2];c[e+64+8>>2]=c[a+448+8>>2];c[e+64+12>>2]=c[a+448+12>>2];c[e+48>>2]=c[a+464>>2];c[e+48+4>>2]=c[a+464+4>>2];c[e+48+8>>2]=c[a+464+8>>2];c[e+48+12>>2]=c[a+464+12>>2];c[e+32>>2]=c[a+480>>2];c[e+32+4>>2]=c[a+480+4>>2];c[e+32+8>>2]=c[a+480+8>>2];c[e+32+12>>2]=c[a+480+12>>2];c[e+16>>2]=c[a+496>>2];c[e+16+4>>2]=c[a+496+4>>2];c[e+16+8>>2]=c[a+496+8>>2];c[e+16+12>>2]=c[a+496+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);c[a+512>>2]=c[e+256>>2];c[a+512+4>>2]=c[e+256+4>>2];c[a+512+8>>2]=c[e+256+8>>2];c[a+512+12>>2]=c[e+256+12>>2];c[a+528>>2]=c[e+240>>2];c[a+528+4>>2]=c[e+240+4>>2];c[a+528+8>>2]=c[e+240+8>>2];c[a+528+12>>2]=c[e+240+12>>2];c[a+544>>2]=c[e+224>>2];c[a+544+4>>2]=c[e+224+4>>2];c[a+544+8>>2]=c[e+224+8>>2];c[a+544+12>>2]=c[e+224+12>>2];c[a+560>>2]=c[e+208>>2];c[a+560+4>>2]=c[e+208+4>>2];c[a+560+8>>2]=c[e+208+8>>2];c[a+560+12>>2]=c[e+208+12>>2];c[a+576>>2]=c[e+192>>2];c[a+576+4>>2]=c[e+192+4>>2];c[a+576+8>>2]=c[e+192+8>>2];c[a+576+12>>2]=c[e+192+12>>2];c[a+592>>2]=c[e+176>>2];c[a+592+4>>2]=c[e+176+4>>2];c[a+592+8>>2]=c[e+176+8>>2];c[a+592+12>>2]=c[e+176+12>>2];c[a+608>>2]=c[e+160>>2];c[a+608+4>>2]=c[e+160+4>>2];c[a+608+8>>2]=c[e+160+8>>2];c[a+608+12>>2]=c[e+160+12>>2];c[a+624>>2]=c[e+144>>2];c[a+624+4>>2]=c[e+144+4>>2];c[a+624+8>>2]=c[e+144+8>>2];c[a+624+12>>2]=c[e+144+12>>2];Le(e+256|0);Le(e+240|0);Le(e+176|0);Le(e+160|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+224|0,35206);rb(e+208|0,35206);rb(e+192|0,35206);rb(e+176|0,35206);rb(e+160|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+160|0);Gd(e+224|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+160|0,e+224|0);Gd(e+208|0,e+256|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+144|0);Gd(e+208|0,e+192|0);Gd(e+144|0,e+176|0);Gd(e+208|0,e+240|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+224|0);Ce(e+64|0,e+160|0);Gd(e+80|0,e+192|0);Gd(e+96|0,e+224|0);Gd(e+112|0,e+208|0);Gd(e+48|0,e+192|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+208|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+160|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+224|0);Ce(e+48|0,e+192|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+208|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+160|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+160|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+176|0);Hd(e+160|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+160|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+208|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+208|0);Hd(e+256|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+256|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+160|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+208|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+192|0);Gd(e+128|0,e+224|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+224|0);Hd(e+192|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+192|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+224|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+160|0);Gd(e+192|0,e+144|0);Gd(e+160|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+224|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+208|0);Gd(e+208|0,e+176|0);Gd(e+160|0,e+208|0);dh(e+208|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+192|0,35238);rb(e+160|0,35238);rb(e+208|0,35238);rb(e+144|0,35238);rb(e+224|0,35238);rb(e+176|0,35238);c[e+128>>2]=c[a+512>>2];c[e+128+4>>2]=c[a+512+4>>2];c[e+128+8>>2]=c[a+512+8>>2];c[e+128+12>>2]=c[a+512+12>>2];c[e+112>>2]=c[a+528>>2];c[e+112+4>>2]=c[a+528+4>>2];c[e+112+8>>2]=c[a+528+8>>2];c[e+112+12>>2]=c[a+528+12>>2];c[e+96>>2]=c[a+544>>2];c[e+96+4>>2]=c[a+544+4>>2];c[e+96+8>>2]=c[a+544+8>>2];c[e+96+12>>2]=c[a+544+12>>2];c[e+80>>2]=c[a+560>>2];c[e+80+4>>2]=c[a+560+4>>2];c[e+80+8>>2]=c[a+560+8>>2];c[e+80+12>>2]=c[a+560+12>>2];c[e+64>>2]=c[a+576>>2];c[e+64+4>>2]=c[a+576+4>>2];c[e+64+8>>2]=c[a+576+8>>2];c[e+64+12>>2]=c[a+576+12>>2];c[e+48>>2]=c[a+592>>2];c[e+48+4>>2]=c[a+592+4>>2];c[e+48+8>>2]=c[a+592+8>>2];c[e+48+12>>2]=c[a+592+12>>2];c[e+32>>2]=c[a+608>>2];c[e+32+4>>2]=c[a+608+4>>2];c[e+32+8>>2]=c[a+608+8>>2];c[e+32+12>>2]=c[a+608+12>>2];c[e+16>>2]=c[a+624>>2];c[e+16+4>>2]=c[a+624+4>>2];c[e+16+8>>2]=c[a+624+8>>2];c[e+16+12>>2]=c[a+624+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);c[a+640>>2]=c[e+256>>2];c[a+640+4>>2]=c[e+256+4>>2];c[a+640+8>>2]=c[e+256+8>>2];c[a+640+12>>2]=c[e+256+12>>2];c[a+656>>2]=c[e+240>>2];c[a+656+4>>2]=c[e+240+4>>2];c[a+656+8>>2]=c[e+240+8>>2];c[a+656+12>>2]=c[e+240+12>>2];c[a+672>>2]=c[e+192>>2];c[a+672+4>>2]=c[e+192+4>>2];c[a+672+8>>2]=c[e+192+8>>2];c[a+672+12>>2]=c[e+192+12>>2];c[a+688>>2]=c[e+160>>2];c[a+688+4>>2]=c[e+160+4>>2];c[a+688+8>>2]=c[e+160+8>>2];c[a+688+12>>2]=c[e+160+12>>2];c[a+704>>2]=c[e+208>>2];c[a+704+4>>2]=c[e+208+4>>2];c[a+704+8>>2]=c[e+208+8>>2];c[a+704+12>>2]=c[e+208+12>>2];c[a+720>>2]=c[e+144>>2];c[a+720+4>>2]=c[e+144+4>>2];c[a+720+8>>2]=c[e+144+8>>2];c[a+720+12>>2]=c[e+144+12>>2];c[a+736>>2]=c[e+224>>2];c[a+736+4>>2]=c[e+224+4>>2];c[a+736+8>>2]=c[e+224+8>>2];c[a+736+12>>2]=c[e+224+12>>2];c[a+752>>2]=c[e+176>>2];c[a+752+4>>2]=c[e+176+4>>2];c[a+752+8>>2]=c[e+176+8>>2];c[a+752+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+224|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+192|0,35206);rb(e+160|0,35206);rb(e+208|0,35206);rb(e+144|0,35206);rb(e+224|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+224|0);Gd(e+192|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+224|0,e+192|0);Gd(e+160|0,e+256|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+176|0);Gd(e+160|0,e+208|0);Gd(e+176|0,e+144|0);Gd(e+160|0,e+240|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+192|0);Ce(e+64|0,e+224|0);Gd(e+80|0,e+208|0);Gd(e+96|0,e+192|0);Gd(e+112|0,e+160|0);Gd(e+48|0,e+208|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+160|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+224|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+192|0);Ce(e+48|0,e+208|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+160|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+224|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+224|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+144|0);Hd(e+224|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+224|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+160|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+160|0);Hd(e+256|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+256|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+224|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+160|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+208|0);Gd(e+128|0,e+192|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+192|0);Hd(e+208|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+208|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+192|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+224|0);Gd(e+208|0,e+176|0);Gd(e+224|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+192|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+160|0);Gd(e+160|0,e+144|0);Gd(e+224|0,e+160|0);dh(e+176|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+208|0,35238);rb(e+224|0,35238);rb(e+160|0,35238);rb(e+176|0,35238);rb(e+192|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+640>>2];c[e+128+4>>2]=c[a+640+4>>2];c[e+128+8>>2]=c[a+640+8>>2];c[e+128+12>>2]=c[a+640+12>>2];c[e+112>>2]=c[a+656>>2];c[e+112+4>>2]=c[a+656+4>>2];c[e+112+8>>2]=c[a+656+8>>2];c[e+112+12>>2]=c[a+656+12>>2];c[e+96>>2]=c[a+672>>2];c[e+96+4>>2]=c[a+672+4>>2];c[e+96+8>>2]=c[a+672+8>>2];c[e+96+12>>2]=c[a+672+12>>2];c[e+80>>2]=c[a+688>>2];c[e+80+4>>2]=c[a+688+4>>2];c[e+80+8>>2]=c[a+688+8>>2];c[e+80+12>>2]=c[a+688+12>>2];c[e+64>>2]=c[a+704>>2];c[e+64+4>>2]=c[a+704+4>>2];c[e+64+8>>2]=c[a+704+8>>2];c[e+64+12>>2]=c[a+704+12>>2];c[e+48>>2]=c[a+720>>2];c[e+48+4>>2]=c[a+720+4>>2];c[e+48+8>>2]=c[a+720+8>>2];c[e+48+12>>2]=c[a+720+12>>2];c[e+32>>2]=c[a+736>>2];c[e+32+4>>2]=c[a+736+4>>2];c[e+32+8>>2]=c[a+736+8>>2];c[e+32+12>>2]=c[a+736+12>>2];c[e+16>>2]=c[a+752>>2];c[e+16+4>>2]=c[a+752+4>>2];c[e+16+8>>2]=c[a+752+8>>2];c[e+16+12>>2]=c[a+752+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);c[a+768>>2]=c[e+256>>2];c[a+768+4>>2]=c[e+256+4>>2];c[a+768+8>>2]=c[e+256+8>>2];c[a+768+12>>2]=c[e+256+12>>2];c[a+784>>2]=c[e+240>>2];c[a+784+4>>2]=c[e+240+4>>2];c[a+784+8>>2]=c[e+240+8>>2];c[a+784+12>>2]=c[e+240+12>>2];c[a+800>>2]=c[e+208>>2];c[a+800+4>>2]=c[e+208+4>>2];c[a+800+8>>2]=c[e+208+8>>2];c[a+800+12>>2]=c[e+208+12>>2];c[a+816>>2]=c[e+224>>2];c[a+816+4>>2]=c[e+224+4>>2];c[a+816+8>>2]=c[e+224+8>>2];c[a+816+12>>2]=c[e+224+12>>2];c[a+832>>2]=c[e+160>>2];c[a+832+4>>2]=c[e+160+4>>2];c[a+832+8>>2]=c[e+160+8>>2];c[a+832+12>>2]=c[e+160+12>>2];c[a+848>>2]=c[e+176>>2];c[a+848+4>>2]=c[e+176+4>>2];c[a+848+8>>2]=c[e+176+8>>2];c[a+848+12>>2]=c[e+176+12>>2];c[a+864>>2]=c[e+192>>2];c[a+864+4>>2]=c[e+192+4>>2];c[a+864+8>>2]=c[e+192+8>>2];c[a+864+12>>2]=c[e+192+12>>2];c[a+880>>2]=c[e+144>>2];c[a+880+4>>2]=c[e+144+4>>2];c[a+880+8>>2]=c[e+144+8>>2];c[a+880+12>>2]=c[e+144+12>>2];Le(e+256|0);Le(e+240|0);Le(e+176|0);Le(e+192|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+208|0,35206);rb(e+224|0,35206);rb(e+160|0,35206);rb(e+176|0,35206);rb(e+192|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+192|0);Gd(e+208|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+192|0,e+208|0);Gd(e+224|0,e+256|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+144|0);Gd(e+224|0,e+160|0);Gd(e+144|0,e+176|0);Gd(e+224|0,e+240|0);Gd(e+160|0,e+176|0);Gd(e+208|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+208|0);Ce(e+64|0,e+192|0);Gd(e+80|0,e+160|0);Gd(e+96|0,e+208|0);Gd(e+112|0,e+224|0);Gd(e+48|0,e+160|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+224|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+192|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+208|0);Ce(e+48|0,e+160|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+224|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+192|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+192|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+176|0);Hd(e+192|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+192|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+224|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+224|0);Hd(e+256|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+256|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+192|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+224|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+160|0);Gd(e+128|0,e+208|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+208|0);Hd(e+160|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+160|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+208|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+192|0);Gd(e+160|0,e+144|0);Gd(e+192|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+208|0);Gd(e+160|0,e+176|0);Gd(e+208|0,e+224|0);Gd(e+224|0,e+176|0);Gd(e+192|0,e+224|0);dh(e+208|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+160|0,35238);rb(e+192|0,35238);rb(e+224|0,35238);rb(e+144|0,35238);rb(e+208|0,35238);rb(e+176|0,35238);c[e+128>>2]=c[a+768>>2];c[e+128+4>>2]=c[a+768+4>>2];c[e+128+8>>2]=c[a+768+8>>2];c[e+128+12>>2]=c[a+768+12>>2];c[e+112>>2]=c[a+784>>2];c[e+112+4>>2]=c[a+784+4>>2];c[e+112+8>>2]=c[a+784+8>>2];c[e+112+12>>2]=c[a+784+12>>2];c[e+96>>2]=c[a+800>>2];c[e+96+4>>2]=c[a+800+4>>2];c[e+96+8>>2]=c[a+800+8>>2];c[e+96+12>>2]=c[a+800+12>>2];c[e+80>>2]=c[a+816>>2];c[e+80+4>>2]=c[a+816+4>>2];c[e+80+8>>2]=c[a+816+8>>2];c[e+80+12>>2]=c[a+816+12>>2];c[e+64>>2]=c[a+832>>2];c[e+64+4>>2]=c[a+832+4>>2];c[e+64+8>>2]=c[a+832+8>>2];c[e+64+12>>2]=c[a+832+12>>2];c[e+48>>2]=c[a+848>>2];c[e+48+4>>2]=c[a+848+4>>2];c[e+48+8>>2]=c[a+848+8>>2];c[e+48+12>>2]=c[a+848+12>>2];c[e+32>>2]=c[a+864>>2];c[e+32+4>>2]=c[a+864+4>>2];c[e+32+8>>2]=c[a+864+8>>2];c[e+32+12>>2]=c[a+864+12>>2];c[e+16>>2]=c[a+880>>2];c[e+16+4>>2]=c[a+880+4>>2];c[e+16+8>>2]=c[a+880+8>>2];c[e+16+12>>2]=c[a+880+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+160|0,e+96|0);Gd(e+192|0,e+80|0);Gd(e+224|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+208|0,e+32|0);Gd(e+176|0,e+16|0);c[a+896>>2]=c[e+256>>2];c[a+896+4>>2]=c[e+256+4>>2];c[a+896+8>>2]=c[e+256+8>>2];c[a+896+12>>2]=c[e+256+12>>2];c[a+912>>2]=c[e+240>>2];c[a+912+4>>2]=c[e+240+4>>2];c[a+912+8>>2]=c[e+240+8>>2];c[a+912+12>>2]=c[e+240+12>>2];c[a+928>>2]=c[e+160>>2];c[a+928+4>>2]=c[e+160+4>>2];c[a+928+8>>2]=c[e+160+8>>2];c[a+928+12>>2]=c[e+160+12>>2];c[a+944>>2]=c[e+192>>2];c[a+944+4>>2]=c[e+192+4>>2];c[a+944+8>>2]=c[e+192+8>>2];c[a+944+12>>2]=c[e+192+12>>2];c[a+960>>2]=c[e+224>>2];c[a+960+4>>2]=c[e+224+4>>2];c[a+960+8>>2]=c[e+224+8>>2];c[a+960+12>>2]=c[e+224+12>>2];c[a+976>>2]=c[e+144>>2];c[a+976+4>>2]=c[e+144+4>>2];c[a+976+8>>2]=c[e+144+8>>2];c[a+976+12>>2]=c[e+144+12>>2];c[a+992>>2]=c[e+208>>2];c[a+992+4>>2]=c[e+208+4>>2];c[a+992+8>>2]=c[e+208+8>>2];c[a+992+12>>2]=c[e+208+12>>2];c[a+1008>>2]=c[e+176>>2];c[a+1008+4>>2]=c[e+176+4>>2];c[a+1008+8>>2]=c[e+176+8>>2];c[a+1008+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+208|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+160|0,35206);rb(e+192|0,35206);rb(e+224|0,35206);rb(e+144|0,35206);rb(e+208|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+208|0);Gd(e+160|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+208|0,e+160|0);Gd(e+192|0,e+256|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+176|0);Gd(e+192|0,e+224|0);Gd(e+176|0,e+144|0);Gd(e+192|0,e+240|0);Gd(e+224|0,e+144|0);Gd(e+160|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+160|0);Ce(e+64|0,e+208|0);Gd(e+80|0,e+224|0);Gd(e+96|0,e+160|0);Gd(e+112|0,e+192|0);Gd(e+48|0,e+224|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+192|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+208|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+160|0);Ce(e+48|0,e+224|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+192|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+208|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+208|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+144|0);Hd(e+208|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+208|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+192|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+192|0);Hd(e+256|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+256|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+208|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+192|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+224|0);Gd(e+128|0,e+160|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+160|0);Hd(e+224|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+224|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+160|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+208|0);Gd(e+224|0,e+176|0);Gd(e+208|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+160|0);Gd(e+224|0,e+144|0);Gd(e+160|0,e+192|0);Gd(e+192|0,e+144|0);Gd(e+208|0,e+192|0);dh(e+144|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+224|0,35238);rb(e+208|0,35238);rb(e+192|0,35238);rb(e+176|0,35238);rb(e+160|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+896>>2];c[e+128+4>>2]=c[a+896+4>>2];c[e+128+8>>2]=c[a+896+8>>2];c[e+128+12>>2]=c[a+896+12>>2];c[e+112>>2]=c[a+912>>2];c[e+112+4>>2]=c[a+912+4>>2];c[e+112+8>>2]=c[a+912+8>>2];c[e+112+12>>2]=c[a+912+12>>2];c[e+96>>2]=c[a+928>>2];c[e+96+4>>2]=c[a+928+4>>2];c[e+96+8>>2]=c[a+928+8>>2];c[e+96+12>>2]=c[a+928+12>>2];c[e+80>>2]=c[a+944>>2];c[e+80+4>>2]=c[a+944+4>>2];c[e+80+8>>2]=c[a+944+8>>2];c[e+80+12>>2]=c[a+944+12>>2];c[e+64>>2]=c[a+960>>2];c[e+64+4>>2]=c[a+960+4>>2];c[e+64+8>>2]=c[a+960+8>>2];c[e+64+12>>2]=c[a+960+12>>2];c[e+48>>2]=c[a+976>>2];c[e+48+4>>2]=c[a+976+4>>2];c[e+48+8>>2]=c[a+976+8>>2];c[e+48+12>>2]=c[a+976+12>>2];c[e+32>>2]=c[a+992>>2];c[e+32+4>>2]=c[a+992+4>>2];c[e+32+8>>2]=c[a+992+8>>2];c[e+32+12>>2]=c[a+992+12>>2];c[e+16>>2]=c[a+1008>>2];c[e+16+4>>2]=c[a+1008+4>>2];c[e+16+8>>2]=c[a+1008+8>>2];c[e+16+12>>2]=c[a+1008+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+224|0,e+96|0);Gd(e+208|0,e+80|0);Gd(e+192|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+160|0,e+32|0);Gd(e+144|0,e+16|0);c[a+1024>>2]=c[e+256>>2];c[a+1024+4>>2]=c[e+256+4>>2];c[a+1024+8>>2]=c[e+256+8>>2];c[a+1024+12>>2]=c[e+256+12>>2];c[a+1040>>2]=c[e+240>>2];c[a+1040+4>>2]=c[e+240+4>>2];c[a+1040+8>>2]=c[e+240+8>>2];c[a+1040+12>>2]=c[e+240+12>>2];c[a+1056>>2]=c[e+224>>2];c[a+1056+4>>2]=c[e+224+4>>2];c[a+1056+8>>2]=c[e+224+8>>2];c[a+1056+12>>2]=c[e+224+12>>2];c[a+1072>>2]=c[e+208>>2];c[a+1072+4>>2]=c[e+208+4>>2];c[a+1072+8>>2]=c[e+208+8>>2];c[a+1072+12>>2]=c[e+208+12>>2];c[a+1088>>2]=c[e+192>>2];c[a+1088+4>>2]=c[e+192+4>>2];c[a+1088+8>>2]=c[e+192+8>>2];c[a+1088+12>>2]=c[e+192+12>>2];c[a+1104>>2]=c[e+176>>2];c[a+1104+4>>2]=c[e+176+4>>2];c[a+1104+8>>2]=c[e+176+8>>2];c[a+1104+12>>2]=c[e+176+12>>2];c[a+1120>>2]=c[e+160>>2];c[a+1120+4>>2]=c[e+160+4>>2];c[a+1120+8>>2]=c[e+160+8>>2];c[a+1120+12>>2]=c[e+160+12>>2];c[a+1136>>2]=c[e+144>>2];c[a+1136+4>>2]=c[e+144+4>>2];c[a+1136+8>>2]=c[e+144+8>>2];c[a+1136+12>>2]=c[e+144+12>>2];Le(e+256|0);Le(e+240|0);Le(e+176|0);Le(e+160|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+224|0,35206);rb(e+208|0,35206);rb(e+192|0,35206);rb(e+176|0,35206);rb(e+160|0,35206);rb(e+144|0,35206);Gd(e+176|0,e+160|0);Gd(e+224|0,e+240|0);Gd(e+176|0,e+256|0);Gd(e+160|0,e+224|0);Gd(e+208|0,e+256|0);Gd(e+160|0,e+208|0);Gd(e+208|0,e+144|0);Gd(e+208|0,e+192|0);Gd(e+144|0,e+176|0);Gd(e+208|0,e+240|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+144|0);Gd(e+240|0,e+176|0);Ce(e+80|0,e+144|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+176|0);Ce(e+48|0,e+224|0);Ce(e+64|0,e+160|0);Gd(e+80|0,e+192|0);Gd(e+96|0,e+224|0);Gd(e+112|0,e+208|0);Gd(e+48|0,e+192|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+208|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+144|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+176|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+160|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+224|0);Ce(e+48|0,e+192|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+144|0);Hd(e+64|0,e+208|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+176|0);Jd(e+16|0,e+160|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+160|0);Ce(e+128|0,e+176|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+160|0);Gd(e+160|0,e+176|0);Hd(e+160|0,e+32|0);Hd(e+176|0,e+16|0);Gd(e+160|0,e+176|0);Gd(e+176|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+208|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+208|0);Hd(e+256|0,e+112|0);Hd(e+208|0,e+48|0);Gd(e+256|0,e+208|0);Gd(e+208|0,e+96|0);Gd(e+160|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+176|0,e+128|0);Gd(e+208|0,e+128|0);Ce(e+64|0,e+144|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+192|0);Gd(e+128|0,e+224|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+192|0);Gd(e+192|0,e+224|0);Hd(e+192|0,e+112|0);Hd(e+224|0,e+48|0);Gd(e+192|0,e+224|0);Gd(e+224|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+144|0);Gd(e+144|0,e+240|0);Hd(e+144|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+144|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+144|0,e+64|0);Gd(e+192|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+224|0,e+128|0);Gd(e+144|0,e+256|0);Gd(e+240|0,e+160|0);Gd(e+192|0,e+144|0);Gd(e+160|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+176|0);Gd(e+176|0,e+224|0);Gd(e+192|0,e+176|0);Gd(e+224|0,e+208|0);Gd(e+208|0,e+176|0);Gd(e+160|0,e+208|0);dh(e+256|0);dh(e+240|0);dh(e+160|0);dh(e+208|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+192|0,35238);rb(e+160|0,35238);rb(e+208|0,35238);rb(e+144|0,35238);rb(e+224|0,35238);rb(e+176|0,35238);c[e+128>>2]=c[a+1024>>2];c[e+128+4>>2]=c[a+1024+4>>2];c[e+128+8>>2]=c[a+1024+8>>2];c[e+128+12>>2]=c[a+1024+12>>2];c[e+112>>2]=c[a+1040>>2];c[e+112+4>>2]=c[a+1040+4>>2];c[e+112+8>>2]=c[a+1040+8>>2];c[e+112+12>>2]=c[a+1040+12>>2];c[e+96>>2]=c[a+1056>>2];c[e+96+4>>2]=c[a+1056+4>>2];c[e+96+8>>2]=c[a+1056+8>>2];c[e+96+12>>2]=c[a+1056+12>>2];c[e+80>>2]=c[a+1072>>2];c[e+80+4>>2]=c[a+1072+4>>2];c[e+80+8>>2]=c[a+1072+8>>2];c[e+80+12>>2]=c[a+1072+12>>2];c[e+64>>2]=c[a+1088>>2];c[e+64+4>>2]=c[a+1088+4>>2];c[e+64+8>>2]=c[a+1088+8>>2];c[e+64+12>>2]=c[a+1088+12>>2];c[e+48>>2]=c[a+1104>>2];c[e+48+4>>2]=c[a+1104+4>>2];c[e+48+8>>2]=c[a+1104+8>>2];c[e+48+12>>2]=c[a+1104+12>>2];c[e+32>>2]=c[a+1120>>2];c[e+32+4>>2]=c[a+1120+4>>2];c[e+32+8>>2]=c[a+1120+8>>2];c[e+32+12>>2]=c[a+1120+12>>2];c[e+16>>2]=c[a+1136>>2];c[e+16+4>>2]=c[a+1136+4>>2];c[e+16+8>>2]=c[a+1136+8>>2];c[e+16+12>>2]=c[a+1136+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+192|0,e+96|0);Gd(e+160|0,e+80|0);Gd(e+208|0,e+64|0);Gd(e+144|0,e+48|0);Gd(e+224|0,e+32|0);Gd(e+176|0,e+16|0);c[a+1152>>2]=c[e+256>>2];c[a+1152+4>>2]=c[e+256+4>>2];c[a+1152+8>>2]=c[e+256+8>>2];c[a+1152+12>>2]=c[e+256+12>>2];c[a+1168>>2]=c[e+240>>2];c[a+1168+4>>2]=c[e+240+4>>2];c[a+1168+8>>2]=c[e+240+8>>2];c[a+1168+12>>2]=c[e+240+12>>2];c[a+1184>>2]=c[e+192>>2];c[a+1184+4>>2]=c[e+192+4>>2];c[a+1184+8>>2]=c[e+192+8>>2];c[a+1184+12>>2]=c[e+192+12>>2];c[a+1200>>2]=c[e+160>>2];c[a+1200+4>>2]=c[e+160+4>>2];c[a+1200+8>>2]=c[e+160+8>>2];c[a+1200+12>>2]=c[e+160+12>>2];c[a+1216>>2]=c[e+208>>2];c[a+1216+4>>2]=c[e+208+4>>2];c[a+1216+8>>2]=c[e+208+8>>2];c[a+1216+12>>2]=c[e+208+12>>2];c[a+1232>>2]=c[e+144>>2];c[a+1232+4>>2]=c[e+144+4>>2];c[a+1232+8>>2]=c[e+144+8>>2];c[a+1232+12>>2]=c[e+144+12>>2];c[a+1248>>2]=c[e+224>>2];c[a+1248+4>>2]=c[e+224+4>>2];c[a+1248+8>>2]=c[e+224+8>>2];c[a+1248+12>>2]=c[e+224+12>>2];c[a+1264>>2]=c[e+176>>2];c[a+1264+4>>2]=c[e+176+4>>2];c[a+1264+8>>2]=c[e+176+8>>2];c[a+1264+12>>2]=c[e+176+12>>2];Le(e+256|0);Le(e+240|0);Le(e+144|0);Le(e+224|0);rb(e+256|0,35206);rb(e+240|0,35206);rb(e+192|0,35206);rb(e+160|0,35206);rb(e+208|0,35206);rb(e+144|0,35206);rb(e+224|0,35206);rb(e+176|0,35206);Gd(e+144|0,e+224|0);Gd(e+192|0,e+240|0);Gd(e+144|0,e+256|0);Gd(e+224|0,e+192|0);Gd(e+160|0,e+256|0);Gd(e+224|0,e+160|0);Gd(e+160|0,e+176|0);Gd(e+160|0,e+208|0);Gd(e+176|0,e+144|0);Gd(e+160|0,e+240|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+176|0);Gd(e+240|0,e+144|0);Ce(e+80|0,e+176|0);Ce(e+96|0,e+240|0);Ce(e+112|0,e+144|0);Ce(e+48|0,e+192|0);Ce(e+64|0,e+224|0);Gd(e+80|0,e+208|0);Gd(e+96|0,e+192|0);Gd(e+112|0,e+160|0);Gd(e+48|0,e+208|0);Gd(e+64|0,e+256|0);Ce(e+32|0,e+80|0);Ce(e+128|0,e+96|0);Ce(e+16|0,e+80|0);Jd(e+96|0,e+112|0);Jd(e+80|0,e+64|0);Gd(e+16|0,e+128|0);Hd(e+32|0,e+64|0);Hd(e+128|0,e+112|0);Gd(e+64|0,e+112|0);Hd(e+16|0,e+64|0);Ce(e+64|0,e+160|0);Gd(e+64|0,e+256|0);Hd(e+48|0,e+64|0);Gd(e+80|0,e+48|0);Gd(e+96|0,e+48|0);Ce(e+48|0,e+176|0);Gd(e+48|0,e+240|0);Ce(e+64|0,e+144|0);Ce(e+112|0,e+48|0);Gd(e+64|0,e+224|0);Jd(e+112|0,e+64|0);Hd(e+48|0,e+64|0);Gd(e+128|0,e+48|0);Gd(e+80|0,e+16|0);Gd(e+96|0,e+32|0);Gd(e+112|0,e+16|0);Gd(e+128|0,e+32|0);Gd(e+112|0,e+32|0);Ce(e+64|0,e+192|0);Ce(e+48|0,e+208|0);Ce(e+32|0,e+240|0);Ce(e+16|0,e+176|0);Hd(e+64|0,e+160|0);Hd(e+48|0,e+256|0);Hd(e+32|0,e+144|0);Jd(e+16|0,e+224|0);Gd(e+80|0,e+64|0);Gd(e+96|0,e+48|0);Gd(e+112|0,e+32|0);Gd(e+128|0,e+16|0);Ce(e+64|0,e+80|0);Gd(e+64|0,e+96|0);Hd(e+80|0,e+112|0);Ce(e+32|0,e+128|0);Gd(e+32|0,e+80|0);Ce(e+16|0,e+64|0);Hd(e+16|0,e+32|0);Gd(e+16|0,e+96|0);Ce(e+48|0,e+112|0);Gd(e+48|0,e+128|0);Gd(e+80|0,e+96|0);Hd(e+48|0,e+80|0);Gd(e+48|0,e+128|0);Gd(e+112|0,e+48|0);Ce(e+96|0,e+32|0);Gd(e+96|0,e+48|0);Hd(e+96|0,e+128|0);Gd(e+112|0,e+96|0);Gd(e+32|0,e+96|0);Hd(e+32|0,e+16|0);Gd(e+32|0,e+64|0);Ce(e+64|0,e+224|0);Ce(e+128|0,e+144|0);Ce(e+96|0,e+16|0);Gd(e+96|0,e+32|0);Hd(e+96|0,e+224|0);Gd(e+224|0,e+144|0);Hd(e+224|0,e+32|0);Hd(e+144|0,e+16|0);Gd(e+224|0,e+144|0);Gd(e+144|0,e+96|0);Gd(e+64|0,e+256|0);Gd(e+128|0,e+160|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+256|0);Gd(e+256|0,e+160|0);Hd(e+256|0,e+112|0);Hd(e+160|0,e+48|0);Gd(e+256|0,e+160|0);Gd(e+160|0,e+96|0);Gd(e+224|0,e+64|0);Gd(e+256|0,e+64|0);Gd(e+144|0,e+128|0);Gd(e+160|0,e+128|0);Ce(e+64|0,e+176|0);Ce(e+128|0,e+240|0);Gd(e+64|0,e+208|0);Gd(e+128|0,e+192|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+64|0);Gd(e+64|0,e+128|0);Hd(e+64|0,e+32|0);Hd(e+128|0,e+16|0);Gd(e+128|0,e+64|0);Gd(e+64|0,e+80|0);Ce(e+96|0,e+48|0);Gd(e+96|0,e+112|0);Hd(e+96|0,e+208|0);Gd(e+208|0,e+192|0);Hd(e+208|0,e+112|0);Hd(e+192|0,e+48|0);Gd(e+208|0,e+192|0);Gd(e+192|0,e+96|0);Gd(e+16|0,e+48|0);Gd(e+32|0,e+112|0);Ce(e+80|0,e+16|0);Gd(e+80|0,e+32|0);Hd(e+80|0,e+176|0);Gd(e+176|0,e+240|0);Hd(e+176|0,e+32|0);Hd(e+240|0,e+16|0);Gd(e+176|0,e+240|0);Gd(e+240|0,e+80|0);Gd(e+176|0,e+64|0);Gd(e+208|0,e+64|0);Gd(e+240|0,e+128|0);Gd(e+192|0,e+128|0);Gd(e+176|0,e+256|0);Gd(e+240|0,e+224|0);Gd(e+208|0,e+176|0);Gd(e+224|0,e+256|0);Gd(e+256|0,e+240|0);Gd(e+240|0,e+144|0);Gd(e+144|0,e+192|0);Gd(e+208|0,e+144|0);Gd(e+192|0,e+160|0);Gd(e+160|0,e+144|0);Gd(e+224|0,e+160|0);dh(e+240|0);dh(e+208|0);dh(e+160|0);dh(e+176|0);rb(e+256|0,35238);rb(e+240|0,35238);rb(e+208|0,35238);rb(e+224|0,35238);rb(e+160|0,35238);rb(e+176|0,35238);rb(e+192|0,35238);rb(e+144|0,35238);c[e+128>>2]=c[a+1152>>2];c[e+128+4>>2]=c[a+1152+4>>2];c[e+128+8>>2]=c[a+1152+8>>2];c[e+128+12>>2]=c[a+1152+12>>2];c[e+112>>2]=c[a+1168>>2];c[e+112+4>>2]=c[a+1168+4>>2];c[e+112+8>>2]=c[a+1168+8>>2];c[e+112+12>>2]=c[a+1168+12>>2];c[e+96>>2]=c[a+1184>>2];c[e+96+4>>2]=c[a+1184+4>>2];c[e+96+8>>2]=c[a+1184+8>>2];c[e+96+12>>2]=c[a+1184+12>>2];c[e+80>>2]=c[a+1200>>2];c[e+80+4>>2]=c[a+1200+4>>2];c[e+80+8>>2]=c[a+1200+8>>2];c[e+80+12>>2]=c[a+1200+12>>2];c[e+64>>2]=c[a+1216>>2];c[e+64+4>>2]=c[a+1216+4>>2];c[e+64+8>>2]=c[a+1216+8>>2];c[e+64+12>>2]=c[a+1216+12>>2];c[e+48>>2]=c[a+1232>>2];c[e+48+4>>2]=c[a+1232+4>>2];c[e+48+8>>2]=c[a+1232+8>>2];c[e+48+12>>2]=c[a+1232+12>>2];c[e+32>>2]=c[a+1248>>2];c[e+32+4>>2]=c[a+1248+4>>2];c[e+32+8>>2]=c[a+1248+8>>2];c[e+32+12>>2]=c[a+1248+12>>2];c[e+16>>2]=c[a+1264>>2];c[e+16+4>>2]=c[a+1264+4>>2];c[e+16+8>>2]=c[a+1264+8>>2];c[e+16+12>>2]=c[a+1264+12>>2];Le(e+128|0);Le(e+112|0);Le(e+48|0);Le(e+32|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);ue(e+128|0);ue(e+112|0);ue(e+96|0);ue(e+80|0);ue(e+64|0);ue(e+48|0);ue(e+32|0);ue(e+16|0);Gd(e+256|0,e+128|0);Gd(e+240|0,e+112|0);Gd(e+208|0,e+96|0);Gd(e+224|0,e+80|0);Gd(e+160|0,e+64|0);Gd(e+176|0,e+48|0);Gd(e+192|0,e+32|0);Gd(e+144|0,e+16|0);rb(e+256|0,35222);rb(e+240|0,35222);rb(e+192|0,35222);rb(e+160|0,35222);rb(e+208|0,35222);rb(e+144|0,35222);rb(e+224|0,35222);rb(e+176|0,35222);c[a+1280>>2]=c[e+256>>2];c[a+1280+4>>2]=c[e+256+4>>2];c[a+1280+8>>2]=c[e+256+8>>2];c[a+1280+12>>2]=c[e+256+12>>2];c[a+1296>>2]=c[e+240>>2];c[a+1296+4>>2]=c[e+240+4>>2];c[a+1296+8>>2]=c[e+240+8>>2];c[a+1296+12>>2]=c[e+240+12>>2];c[a+1312>>2]=c[e+208>>2];c[a+1312+4>>2]=c[e+208+4>>2];c[a+1312+8>>2]=c[e+208+8>>2];c[a+1312+12>>2]=c[e+208+12>>2];c[a+1328>>2]=c[e+224>>2];c[a+1328+4>>2]=c[e+224+4>>2];c[a+1328+8>>2]=c[e+224+8>>2];c[a+1328+12>>2]=c[e+224+12>>2];c[a+1344>>2]=c[e+160>>2];c[a+1344+4>>2]=c[e+160+4>>2];c[a+1344+8>>2]=c[e+160+8>>2];c[a+1344+12>>2]=c[e+160+12>>2];c[a+1360>>2]=c[e+176>>2];c[a+1360+4>>2]=c[e+176+4>>2];c[a+1360+8>>2]=c[e+176+8>>2];c[a+1360+12>>2]=c[e+176+12>>2];c[a+1376>>2]=c[e+192>>2];c[a+1376+4>>2]=c[e+192+4>>2];c[a+1376+8>>2]=c[e+192+8>>2];c[a+1376+12>>2]=c[e+192+12>>2];c[a+1392>>2]=c[e+144>>2];c[a+1392+4>>2]=c[e+144+4>>2];c[a+1392+8>>2]=c[e+144+8>>2];c[a+1392+12>>2]=c[e+144+12>>2];l=d;return 0}function ea(b,d,e,f,g,h){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0,k=0;k=l;j=l=l+63&-64;l=l+400|0;Ce(j,g);while(1){c[j+256>>2]=c[j>>2];c[j+256+4>>2]=c[j+4>>2];c[j+256+8>>2]=c[j+8>>2];c[j+256+12>>2]=c[j+12>>2];Ce(j+240|0,j+256|0);rb(j+240|0,35254);Ce(j+224|0,j+240|0);Ce(j+208|0,j+240|0);Ce(j+192|0,j+240|0);Ce(j+176|0,j+240|0);Ce(j+160|0,j+240|0);Ce(j+144|0,j+240|0);Eg(j+240|0,1);Eg(j+224|0,2);Eg(j+208|0,3);Eg(j+192|0,4);Eg(j+176|0,5);Eg(j+160|0,6);Eg(j+144|0,7);rb(j+256|0,35222);rb(j+240|0,35270);rb(j+224|0,35270);rb(j+208|0,35270);rb(j+192|0,35270);rb(j+176|0,35270);rb(j+160|0,35270);rb(j+144|0,35270);Ce(j+128|0,j+160|0);_d(j+128|0,1);Gd(j+128|0,j+144|0);Hd(j+128|0,1104);Gd(j+144|0,j+128|0);ae(j+128|0,1);Gd(j+160|0,j+128|0);Ce(j+128|0,j+192|0);_d(j+128|0,1);Gd(j+128|0,j+176|0);Hd(j+128|0,1104);Gd(j+176|0,j+128|0);ae(j+128|0,1);Gd(j+192|0,j+128|0);Ce(j+128|0,j+224|0);_d(j+128|0,1);Gd(j+128|0,j+208|0);Hd(j+128|0,1104);Gd(j+208|0,j+128|0);ae(j+128|0,1);Gd(j+224|0,j+128|0);Ce(j+128|0,j+256|0);_d(j+128|0,1);Gd(j+128|0,j+240|0);Hd(j+128|0,1104);Gd(j+240|0,j+128|0);ae(j+128|0,1);Gd(j+256|0,j+128|0);Ce(j+128|0,j+176|0);_d(j+128|0,2);Gd(j+128|0,j+144|0);Hd(j+128|0,1120);Gd(j+144|0,j+128|0);ae(j+128|0,2);Gd(j+176|0,j+128|0);Ce(j+128|0,j+192|0);_d(j+128|0,2);Gd(j+128|0,j+160|0);Hd(j+128|0,1120);Gd(j+160|0,j+128|0);ae(j+128|0,2);Gd(j+192|0,j+128|0);Ce(j+128|0,j+240|0);_d(j+128|0,2);Gd(j+128|0,j+208|0);Hd(j+128|0,1120);Gd(j+208|0,j+128|0);ae(j+128|0,2);Gd(j+240|0,j+128|0);Ce(j+128|0,j+256|0);_d(j+128|0,2);Gd(j+128|0,j+224|0);Hd(j+128|0,1120);Gd(j+224|0,j+128|0);ae(j+128|0,2);Gd(j+256|0,j+128|0);Ce(j+128|0,j+208|0);_d(j+128|0,4);Gd(j+128|0,j+144|0);Hd(j+128|0,1136);Gd(j+144|0,j+128|0);ae(j+128|0,4);Gd(j+208|0,j+128|0);Ce(j+128|0,j+224|0);_d(j+128|0,4);Gd(j+128|0,j+160|0);Hd(j+128|0,1136);Gd(j+160|0,j+128|0);ae(j+128|0,4);Gd(j+224|0,j+128|0);Ce(j+128|0,j+240|0);_d(j+128|0,4);Gd(j+128|0,j+176|0);Hd(j+128|0,1136);Gd(j+176|0,j+128|0);ae(j+128|0,4);Gd(j+240|0,j+128|0);Ce(j+128|0,j+256|0);_d(j+128|0,4);Gd(j+128|0,j+192|0);Hd(j+128|0,1136);Gd(j+192|0,j+128|0);ae(j+128|0,4);Gd(j+256|0,j+128|0);Gd(j+256|0,h);rb(j+256|0,35286);Gd(j+240|0,h+16|0);rb(j+240|0,35286);Gd(j+224|0,h+32|0);rb(j+224|0,35286);Gd(j+208|0,h+48|0);rb(j+208|0,35286);Gd(j+192|0,h+64|0);rb(j+192|0,35286);Gd(j+176|0,h+80|0);rb(j+176|0,35286);Gd(j+160|0,h+96|0);rb(j+160|0,35286);Gd(j+144|0,h+112|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+128|0);rb(j+128|0,35286);Gd(j+112|0,h+144|0);rb(j+112|0,35286);Gd(j+96|0,h+160|0);rb(j+96|0,35286);Gd(j+80|0,h+176|0);rb(j+80|0,35286);Gd(j+64|0,h+192|0);rb(j+64|0,35286);Gd(j+48|0,h+208|0);rb(j+48|0,35286);Gd(j+32|0,h+224|0);rb(j+32|0,35286);Gd(j+16|0,h+240|0);rb(j+16|0,35286);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);_c(j+256|0,j+128|0,147);_c(j+240|0,j+112|0,147);_c(j+224|0,j+64|0,147);_c(j+208|0,j+32|0,147);_c(j+192|0,j+80|0,147);_c(j+176|0,j+16|0,147);_c(j+160|0,j+96|0,147);_c(j+144|0,j+48|0,147);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+64|0,j+224|0);Gd(j+32|0,j+208|0);Gd(j+80|0,j+192|0);Gd(j+16|0,j+176|0);Gd(j+96|0,j+160|0);Gd(j+48|0,j+144|0);Gd(j+256|0,j+48|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+112|0);Gd(j+240|0,j+48|0);Gd(j+208|0,j+64|0);Gd(j+192|0,j+32|0);Gd(j+176|0,j+80|0);Gd(j+208|0,j+48|0);Gd(j+160|0,j+16|0);Gd(j+144|0,j+96|0);Gd(j+192|0,j+48|0);_c(j+128|0,j+128|0,78);_c(j+112|0,j+112|0,78);_c(j+64|0,j+64|0,78);_c(j+32|0,j+32|0,78);_c(j+80|0,j+80|0,78);_c(j+16|0,j+16|0,78);_c(j+96|0,j+96|0,78);_c(j+48|0,j+48|0,78);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+224|0,j+64|0);Gd(j+208|0,j+32|0);Gd(j+192|0,j+80|0);Gd(j+176|0,j+16|0);Gd(j+160|0,j+96|0);Gd(j+144|0,j+48|0);Gd(j+256|0,h+256|0);rb(j+256|0,35286);Gd(j+240|0,h+272|0);rb(j+240|0,35286);Gd(j+224|0,h+288|0);rb(j+224|0,35286);Gd(j+208|0,h+304|0);rb(j+208|0,35286);Gd(j+192|0,h+320|0);rb(j+192|0,35286);Gd(j+176|0,h+336|0);rb(j+176|0,35286);Gd(j+160|0,h+352|0);rb(j+160|0,35286);Gd(j+144|0,h+368|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+384|0);rb(j+128|0,35286);Gd(j+112|0,h+400|0);rb(j+112|0,35286);Gd(j+96|0,h+416|0);rb(j+96|0,35286);Gd(j+80|0,h+432|0);rb(j+80|0,35286);Gd(j+64|0,h+448|0);rb(j+64|0,35286);Gd(j+48|0,h+464|0);rb(j+48|0,35286);Gd(j+32|0,h+480|0);rb(j+32|0,35286);Gd(j+16|0,h+496|0);rb(j+16|0,35286);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);_c(j+256|0,j+128|0,147);_c(j+240|0,j+112|0,147);_c(j+224|0,j+64|0,147);_c(j+208|0,j+32|0,147);_c(j+192|0,j+80|0,147);_c(j+176|0,j+16|0,147);_c(j+160|0,j+96|0,147);_c(j+144|0,j+48|0,147);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+64|0,j+224|0);Gd(j+32|0,j+208|0);Gd(j+80|0,j+192|0);Gd(j+16|0,j+176|0);Gd(j+96|0,j+160|0);Gd(j+48|0,j+144|0);Gd(j+256|0,j+48|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+112|0);Gd(j+240|0,j+48|0);Gd(j+208|0,j+64|0);Gd(j+192|0,j+32|0);Gd(j+176|0,j+80|0);Gd(j+208|0,j+48|0);Gd(j+160|0,j+16|0);Gd(j+144|0,j+96|0);Gd(j+192|0,j+48|0);_c(j+128|0,j+128|0,78);_c(j+112|0,j+112|0,78);_c(j+64|0,j+64|0,78);_c(j+32|0,j+32|0,78);_c(j+80|0,j+80|0,78);_c(j+16|0,j+16|0,78);_c(j+96|0,j+96|0,78);_c(j+48|0,j+48|0,78);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+224|0,j+64|0);Gd(j+208|0,j+32|0);Gd(j+192|0,j+80|0);Gd(j+176|0,j+16|0);Gd(j+160|0,j+96|0);Gd(j+144|0,j+48|0);Gd(j+256|0,h+512|0);rb(j+256|0,35286);Gd(j+240|0,h+528|0);rb(j+240|0,35286);Gd(j+224|0,h+544|0);rb(j+224|0,35286);Gd(j+208|0,h+560|0);rb(j+208|0,35286);Gd(j+192|0,h+576|0);rb(j+192|0,35286);Gd(j+176|0,h+592|0);rb(j+176|0,35286);Gd(j+160|0,h+608|0);rb(j+160|0,35286);Gd(j+144|0,h+624|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+640|0);rb(j+128|0,35286);Gd(j+112|0,h+656|0);rb(j+112|0,35286);Gd(j+96|0,h+672|0);rb(j+96|0,35286);Gd(j+80|0,h+688|0);rb(j+80|0,35286);Gd(j+64|0,h+704|0);rb(j+64|0,35286);Gd(j+48|0,h+720|0);rb(j+48|0,35286);Gd(j+32|0,h+736|0);rb(j+32|0,35286);Gd(j+16|0,h+752|0);rb(j+16|0,35286);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);_c(j+256|0,j+128|0,147);_c(j+240|0,j+112|0,147);_c(j+224|0,j+64|0,147);_c(j+208|0,j+32|0,147);_c(j+192|0,j+80|0,147);_c(j+176|0,j+16|0,147);_c(j+160|0,j+96|0,147);_c(j+144|0,j+48|0,147);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+64|0,j+224|0);Gd(j+32|0,j+208|0);Gd(j+80|0,j+192|0);Gd(j+16|0,j+176|0);Gd(j+96|0,j+160|0);Gd(j+48|0,j+144|0);Gd(j+256|0,j+48|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+112|0);Gd(j+240|0,j+48|0);Gd(j+208|0,j+64|0);Gd(j+192|0,j+32|0);Gd(j+176|0,j+80|0);Gd(j+208|0,j+48|0);Gd(j+160|0,j+16|0);Gd(j+144|0,j+96|0);Gd(j+192|0,j+48|0);_c(j+128|0,j+128|0,78);_c(j+112|0,j+112|0,78);_c(j+64|0,j+64|0,78);_c(j+32|0,j+32|0,78);_c(j+80|0,j+80|0,78);_c(j+16|0,j+16|0,78);_c(j+96|0,j+96|0,78);_c(j+48|0,j+48|0,78);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+224|0,j+64|0);Gd(j+208|0,j+32|0);Gd(j+192|0,j+80|0);Gd(j+176|0,j+16|0);Gd(j+160|0,j+96|0);Gd(j+144|0,j+48|0);Gd(j+256|0,h+768|0);rb(j+256|0,35286);Gd(j+240|0,h+784|0);rb(j+240|0,35286);Gd(j+224|0,h+800|0);rb(j+224|0,35286);Gd(j+208|0,h+816|0);rb(j+208|0,35286);Gd(j+192|0,h+832|0);rb(j+192|0,35286);Gd(j+176|0,h+848|0);rb(j+176|0,35286);Gd(j+160|0,h+864|0);rb(j+160|0,35286);Gd(j+144|0,h+880|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+896|0);rb(j+128|0,35286);Gd(j+112|0,h+912|0);rb(j+112|0,35286);Gd(j+96|0,h+928|0);rb(j+96|0,35286);Gd(j+80|0,h+944|0);rb(j+80|0,35286);Gd(j+64|0,h+960|0);rb(j+64|0,35286);Gd(j+48|0,h+976|0);rb(j+48|0,35286);Gd(j+32|0,h+992|0);rb(j+32|0,35286);Gd(j+16|0,h+1008|0);rb(j+16|0,35286);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);_c(j+256|0,j+128|0,147);_c(j+240|0,j+112|0,147);_c(j+224|0,j+64|0,147);_c(j+208|0,j+32|0,147);_c(j+192|0,j+80|0,147);_c(j+176|0,j+16|0,147);_c(j+160|0,j+96|0,147);_c(j+144|0,j+48|0,147);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+64|0,j+224|0);Gd(j+32|0,j+208|0);Gd(j+80|0,j+192|0);Gd(j+16|0,j+176|0);Gd(j+96|0,j+160|0);Gd(j+48|0,j+144|0);Gd(j+256|0,j+48|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+112|0);Gd(j+240|0,j+48|0);Gd(j+208|0,j+64|0);Gd(j+192|0,j+32|0);Gd(j+176|0,j+80|0);Gd(j+208|0,j+48|0);Gd(j+160|0,j+16|0);Gd(j+144|0,j+96|0);Gd(j+192|0,j+48|0);_c(j+128|0,j+128|0,78);_c(j+112|0,j+112|0,78);_c(j+64|0,j+64|0,78);_c(j+32|0,j+32|0,78);_c(j+80|0,j+80|0,78);_c(j+16|0,j+16|0,78);_c(j+96|0,j+96|0,78);_c(j+48|0,j+48|0,78);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+224|0,j+64|0);Gd(j+208|0,j+32|0);Gd(j+192|0,j+80|0);Gd(j+176|0,j+16|0);Gd(j+160|0,j+96|0);Gd(j+144|0,j+48|0);Gd(j+256|0,h+1024|0);rb(j+256|0,35286);Gd(j+240|0,h+1040|0);rb(j+240|0,35286);Gd(j+224|0,h+1056|0);rb(j+224|0,35286);Gd(j+208|0,h+1072|0);rb(j+208|0,35286);Gd(j+192|0,h+1088|0);rb(j+192|0,35286);Gd(j+176|0,h+1104|0);rb(j+176|0,35286);Gd(j+160|0,h+1120|0);rb(j+160|0,35286);Gd(j+144|0,h+1136|0);rb(j+144|0,35286);Gd(j+176|0,j+160|0);Gd(j+224|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+160|0,j+224|0);Gd(j+208|0,j+256|0);Gd(j+160|0,j+208|0);Gd(j+208|0,j+144|0);Gd(j+208|0,j+192|0);Gd(j+144|0,j+176|0);Gd(j+208|0,j+240|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+144|0);Gd(j+240|0,j+176|0);Ce(j+80|0,j+144|0);Ce(j+96|0,j+240|0);Ce(j+112|0,j+176|0);Ce(j+48|0,j+224|0);Ce(j+64|0,j+160|0);Gd(j+80|0,j+192|0);Gd(j+96|0,j+224|0);Gd(j+112|0,j+208|0);Gd(j+48|0,j+192|0);Gd(j+64|0,j+256|0);Ce(j+32|0,j+80|0);Ce(j+128|0,j+96|0);Ce(j+16|0,j+80|0);Jd(j+96|0,j+112|0);Jd(j+80|0,j+64|0);Gd(j+16|0,j+128|0);Hd(j+32|0,j+64|0);Hd(j+128|0,j+112|0);Gd(j+64|0,j+112|0);Hd(j+16|0,j+64|0);Ce(j+64|0,j+208|0);Gd(j+64|0,j+256|0);Hd(j+48|0,j+64|0);Gd(j+80|0,j+48|0);Gd(j+96|0,j+48|0);Ce(j+48|0,j+144|0);Gd(j+48|0,j+240|0);Ce(j+64|0,j+176|0);Ce(j+112|0,j+48|0);Gd(j+64|0,j+160|0);Jd(j+112|0,j+64|0);Hd(j+48|0,j+64|0);Gd(j+128|0,j+48|0);Gd(j+80|0,j+16|0);Gd(j+96|0,j+32|0);Gd(j+112|0,j+16|0);Gd(j+128|0,j+32|0);Gd(j+112|0,j+32|0);Ce(j+64|0,j+224|0);Ce(j+48|0,j+192|0);Ce(j+32|0,j+240|0);Ce(j+16|0,j+144|0);Hd(j+64|0,j+208|0);Hd(j+48|0,j+256|0);Hd(j+32|0,j+176|0);Jd(j+16|0,j+160|0);Gd(j+80|0,j+64|0);Gd(j+96|0,j+48|0);Gd(j+112|0,j+32|0);Gd(j+128|0,j+16|0);Ce(j+64|0,j+80|0);Gd(j+64|0,j+96|0);Hd(j+80|0,j+112|0);Ce(j+32|0,j+128|0);Gd(j+32|0,j+80|0);Ce(j+16|0,j+64|0);Hd(j+16|0,j+32|0);Gd(j+16|0,j+96|0);Ce(j+48|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+80|0,j+96|0);Hd(j+48|0,j+80|0);Gd(j+48|0,j+128|0);Gd(j+112|0,j+48|0);Ce(j+96|0,j+32|0);Gd(j+96|0,j+48|0);Hd(j+96|0,j+128|0);Gd(j+112|0,j+96|0);Gd(j+32|0,j+96|0);Hd(j+32|0,j+16|0);Gd(j+32|0,j+64|0);Ce(j+64|0,j+160|0);Ce(j+128|0,j+176|0);Ce(j+96|0,j+16|0);Gd(j+96|0,j+32|0);Hd(j+96|0,j+160|0);Gd(j+160|0,j+176|0);Hd(j+160|0,j+32|0);Hd(j+176|0,j+16|0);Gd(j+160|0,j+176|0);Gd(j+176|0,j+96|0);Gd(j+64|0,j+256|0);Gd(j+128|0,j+208|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+256|0);Gd(j+256|0,j+208|0);Hd(j+256|0,j+112|0);Hd(j+208|0,j+48|0);Gd(j+256|0,j+208|0);Gd(j+208|0,j+96|0);Gd(j+160|0,j+64|0);Gd(j+256|0,j+64|0);Gd(j+176|0,j+128|0);Gd(j+208|0,j+128|0);Ce(j+64|0,j+144|0);Ce(j+128|0,j+240|0);Gd(j+64|0,j+192|0);Gd(j+128|0,j+224|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+64|0);Gd(j+64|0,j+128|0);Hd(j+64|0,j+32|0);Hd(j+128|0,j+16|0);Gd(j+128|0,j+64|0);Gd(j+64|0,j+80|0);Ce(j+96|0,j+48|0);Gd(j+96|0,j+112|0);Hd(j+96|0,j+192|0);Gd(j+192|0,j+224|0);Hd(j+192|0,j+112|0);Hd(j+224|0,j+48|0);Gd(j+192|0,j+224|0);Gd(j+224|0,j+96|0);Gd(j+16|0,j+48|0);Gd(j+32|0,j+112|0);Ce(j+80|0,j+16|0);Gd(j+80|0,j+32|0);Hd(j+80|0,j+144|0);Gd(j+144|0,j+240|0);Hd(j+144|0,j+32|0);Hd(j+240|0,j+16|0);Gd(j+144|0,j+240|0);Gd(j+240|0,j+80|0);Gd(j+144|0,j+64|0);Gd(j+192|0,j+64|0);Gd(j+240|0,j+128|0);Gd(j+224|0,j+128|0);Gd(j+144|0,j+256|0);Gd(j+240|0,j+160|0);Gd(j+192|0,j+144|0);Gd(j+160|0,j+256|0);Gd(j+256|0,j+240|0);Gd(j+240|0,j+176|0);Gd(j+176|0,j+224|0);Gd(j+192|0,j+176|0);Gd(j+224|0,j+208|0);Gd(j+208|0,j+176|0);Gd(j+160|0,j+208|0);_c(j+128|0,j+256|0,147);_c(j+112|0,j+240|0,147);_c(j+96|0,j+192|0,147);_c(j+80|0,j+160|0,147);_c(j+64|0,j+208|0,147);_c(j+48|0,j+144|0,147);_c(j+32|0,j+224|0,147);_c(j+16|0,j+176|0,147);Gd(j+256|0,j+128|0);Gd(j+240|0,j+112|0);Gd(j+192|0,j+96|0);Gd(j+160|0,j+80|0);Gd(j+208|0,j+64|0);Gd(j+144|0,j+48|0);Gd(j+224|0,j+32|0);Gd(j+176|0,j+16|0);Gd(j+128|0,j+176|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+240|0);Gd(j+112|0,j+176|0);Gd(j+80|0,j+192|0);Gd(j+64|0,j+160|0);Gd(j+48|0,j+208|0);Gd(j+80|0,j+176|0);Gd(j+32|0,j+144|0);Gd(j+16|0,j+224|0);Gd(j+64|0,j+176|0);_c(j+256|0,j+256|0,78);_c(j+240|0,j+240|0,78);_c(j+192|0,j+192|0,78);_c(j+160|0,j+160|0,78);_c(j+208|0,j+208|0,78);_c(j+144|0,j+144|0,78);_c(j+224|0,j+224|0,78);_c(j+176|0,j+176|0,78);Gd(j+128|0,j+256|0);Gd(j+112|0,j+240|0);Gd(j+96|0,j+192|0);Gd(j+80|0,j+160|0);Gd(j+64|0,j+208|0);Gd(j+48|0,j+144|0);Gd(j+32|0,j+224|0);Gd(j+16|0,j+176|0);Gd(j+128|0,h+1152|0);rb(j+128|0,35302);Gd(j+112|0,h+1168|0);rb(j+112|0,35302);Gd(j+96|0,h+1184|0);rb(j+96|0,35302);Gd(j+80|0,h+1200|0);rb(j+80|0,35302);Gd(j+64|0,h+1216|0);rb(j+64|0,35302);Gd(j+48|0,h+1232|0);rb(j+48|0,35302);Gd(j+32|0,h+1248|0);rb(j+32|0,35302);Gd(j+16|0,h+1264|0);rb(j+16|0,35302);Gd(j+48|0,j+32|0);Gd(j+96|0,j+112|0);Gd(j+48|0,j+128|0);Gd(j+32|0,j+96|0);Gd(j+80|0,j+128|0);Gd(j+32|0,j+80|0);Gd(j+80|0,j+16|0);Gd(j+80|0,j+64|0);Gd(j+16|0,j+48|0);Gd(j+80|0,j+112|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+16|0);Gd(j+112|0,j+48|0);Ce(j+208|0,j+16|0);Ce(j+224|0,j+112|0);Ce(j+240|0,j+48|0);Ce(j+176|0,j+96|0);Ce(j+192|0,j+32|0);Gd(j+208|0,j+64|0);Gd(j+224|0,j+96|0);Gd(j+240|0,j+80|0);Gd(j+176|0,j+64|0);Gd(j+192|0,j+128|0);Ce(j+160|0,j+208|0);Ce(j+256|0,j+224|0);Ce(j+144|0,j+208|0);Jd(j+224|0,j+240|0);Jd(j+208|0,j+192|0);Gd(j+144|0,j+256|0);Hd(j+160|0,j+192|0);Hd(j+256|0,j+240|0);Gd(j+192|0,j+240|0);Hd(j+144|0,j+192|0);Ce(j+192|0,j+80|0);Gd(j+192|0,j+128|0);Hd(j+176|0,j+192|0);Gd(j+208|0,j+176|0);Gd(j+224|0,j+176|0);Ce(j+176|0,j+16|0);Gd(j+176|0,j+112|0);Ce(j+192|0,j+48|0);Ce(j+240|0,j+176|0);Gd(j+192|0,j+32|0);Jd(j+240|0,j+192|0);Hd(j+176|0,j+192|0);Gd(j+256|0,j+176|0);Gd(j+208|0,j+144|0);Gd(j+224|0,j+160|0);Gd(j+240|0,j+144|0);Gd(j+256|0,j+160|0);Gd(j+240|0,j+160|0);Ce(j+192|0,j+96|0);Ce(j+176|0,j+64|0);Ce(j+160|0,j+112|0);Ce(j+144|0,j+16|0);Hd(j+192|0,j+80|0);Hd(j+176|0,j+128|0);Hd(j+160|0,j+48|0);Jd(j+144|0,j+32|0);Gd(j+208|0,j+192|0);Gd(j+224|0,j+176|0);Gd(j+240|0,j+160|0);Gd(j+256|0,j+144|0);Ce(j+192|0,j+208|0);Gd(j+192|0,j+224|0);Hd(j+208|0,j+240|0);Ce(j+160|0,j+256|0);Gd(j+160|0,j+208|0);Ce(j+144|0,j+192|0);Hd(j+144|0,j+160|0);Gd(j+144|0,j+224|0);Ce(j+176|0,j+240|0);Gd(j+176|0,j+256|0);Gd(j+208|0,j+224|0);Hd(j+176|0,j+208|0);Gd(j+176|0,j+256|0);Gd(j+240|0,j+176|0);Ce(j+224|0,j+160|0);Gd(j+224|0,j+176|0);Hd(j+224|0,j+256|0);Gd(j+240|0,j+224|0);Gd(j+160|0,j+224|0);Hd(j+160|0,j+144|0);Gd(j+160|0,j+192|0);Ce(j+192|0,j+32|0);Ce(j+256|0,j+48|0);Ce(j+224|0,j+144|0);Gd(j+224|0,j+160|0);Hd(j+224|0,j+32|0);Gd(j+32|0,j+48|0);Hd(j+32|0,j+160|0);Hd(j+48|0,j+144|0);Gd(j+32|0,j+48|0);Gd(j+48|0,j+224|0);Gd(j+192|0,j+128|0);Gd(j+256|0,j+80|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+128|0);Gd(j+128|0,j+80|0);Hd(j+128|0,j+240|0);Hd(j+80|0,j+176|0);Gd(j+128|0,j+80|0);Gd(j+80|0,j+224|0);Gd(j+32|0,j+192|0);Gd(j+128|0,j+192|0);Gd(j+48|0,j+256|0);Gd(j+80|0,j+256|0);Ce(j+192|0,j+16|0);Ce(j+256|0,j+112|0);Gd(j+192|0,j+64|0);Gd(j+256|0,j+96|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+192|0);Gd(j+192|0,j+256|0);Hd(j+192|0,j+160|0);Hd(j+256|0,j+144|0);Gd(j+256|0,j+192|0);Gd(j+192|0,j+208|0);Ce(j+224|0,j+176|0);Gd(j+224|0,j+240|0);Hd(j+224|0,j+64|0);Gd(j+64|0,j+96|0);Hd(j+64|0,j+240|0);Hd(j+96|0,j+176|0);Gd(j+64|0,j+96|0);Gd(j+96|0,j+224|0);Gd(j+144|0,j+176|0);Gd(j+160|0,j+240|0);Ce(j+208|0,j+144|0);Gd(j+208|0,j+160|0);Hd(j+208|0,j+16|0);Gd(j+16|0,j+112|0);Hd(j+16|0,j+160|0);Hd(j+112|0,j+144|0);Gd(j+16|0,j+112|0);Gd(j+112|0,j+208|0);Gd(j+16|0,j+192|0);Gd(j+64|0,j+192|0);Gd(j+112|0,j+256|0);Gd(j+96|0,j+256|0);Gd(j+16|0,j+128|0);Gd(j+112|0,j+32|0);Gd(j+64|0,j+16|0);Gd(j+32|0,j+128|0);Gd(j+128|0,j+112|0);Gd(j+112|0,j+48|0);Gd(j+48|0,j+96|0);Gd(j+64|0,j+48|0);Gd(j+96|0,j+80|0);Gd(j+80|0,j+48|0);Gd(j+32|0,j+80|0);Gd(j+128|0,h+1280|0);Gd(j+112|0,h+1296|0);Gd(j+64|0,h+1312|0);Gd(j+32|0,h+1328|0);Gd(j+80|0,h+1344|0);Gd(j+16|0,h+1360|0);Gd(j+96|0,h+1376|0);Gd(j+48|0,h+1392|0);Ce(j+256|0,j+96|0);_d(j+256|0,1);Gd(j+256|0,j+48|0);Hd(j+256|0,1104);Gd(j+48|0,j+256|0);ae(j+256|0,1);Gd(j+96|0,j+256|0);Ce(j+256|0,j+80|0);_d(j+256|0,1);Gd(j+256|0,j+16|0);Hd(j+256|0,1104);Gd(j+16|0,j+256|0);ae(j+256|0,1);Gd(j+80|0,j+256|0);Ce(j+256|0,j+64|0);_d(j+256|0,1);Gd(j+256|0,j+32|0);Hd(j+256|0,1104);Gd(j+32|0,j+256|0);ae(j+256|0,1);Gd(j+64|0,j+256|0);Ce(j+256|0,j+128|0);_d(j+256|0,1);Gd(j+256|0,j+112|0);Hd(j+256|0,1104);Gd(j+112|0,j+256|0);ae(j+256|0,1);Gd(j+128|0,j+256|0);Ce(j+256|0,j+16|0);_d(j+256|0,2);Gd(j+256|0,j+48|0);Hd(j+256|0,1120);Gd(j+48|0,j+256|0);ae(j+256|0,2);Gd(j+16|0,j+256|0);Ce(j+256|0,j+80|0);_d(j+256|0,2);Gd(j+256|0,j+96|0);Hd(j+256|0,1120);Gd(j+96|0,j+256|0);ae(j+256|0,2);Gd(j+80|0,j+256|0);Ce(j+256|0,j+112|0);_d(j+256|0,2);Gd(j+256|0,j+32|0);Hd(j+256|0,1120);Gd(j+32|0,j+256|0);ae(j+256|0,2);Gd(j+112|0,j+256|0);Ce(j+256|0,j+128|0);_d(j+256|0,2);Gd(j+256|0,j+64|0);Hd(j+256|0,1120);Gd(j+64|0,j+256|0);ae(j+256|0,2);Gd(j+128|0,j+256|0);Ce(j+256|0,j+32|0);_d(j+256|0,4);Gd(j+256|0,j+48|0);Hd(j+256|0,1136);Gd(j+48|0,j+256|0);ae(j+256|0,4);Gd(j+32|0,j+256|0);Ce(j+256|0,j+64|0);_d(j+256|0,4);Gd(j+256|0,j+96|0);Hd(j+256|0,1136);Gd(j+96|0,j+256|0);ae(j+256|0,4);Gd(j+64|0,j+256|0);Ce(j+256|0,j+112|0);_d(j+256|0,4);Gd(j+256|0,j+16|0);Hd(j+256|0,1136);Gd(j+16|0,j+256|0);ae(j+256|0,4);Gd(j+112|0,j+256|0);Ce(j+256|0,j+128|0);_d(j+256|0,4);Gd(j+256|0,j+80|0);Hd(j+256|0,1136);Gd(j+80|0,j+256|0);ae(j+256|0,4);Gd(j+128|0,j+256|0);if(f>>>0<0|(f|0)==0&e>>>0<128){i=5;break}gg(j+12|0,(ug(j+12|0)|0)+8|0);Gd(j+128|0,d);Gd(j+112|0,d+16|0);Gd(j+64|0,d+32|0);Gd(j+32|0,d+48|0);Gd(j+80|0,d+64|0);Gd(j+16|0,d+80|0);Gd(j+96|0,d+96|0);Gd(j+48|0,d+112|0);c[b>>2]=c[j+128>>2];c[b+4>>2]=c[j+128+4>>2];c[b+8>>2]=c[j+128+8>>2];c[b+12>>2]=c[j+128+12>>2];g=b+16|0;c[g>>2]=c[j+112>>2];c[g+4>>2]=c[j+112+4>>2];c[g+8>>2]=c[j+112+8>>2];c[g+12>>2]=c[j+112+12>>2];g=b+32|0;c[g>>2]=c[j+64>>2];c[g+4>>2]=c[j+64+4>>2];c[g+8>>2]=c[j+64+8>>2];c[g+12>>2]=c[j+64+12>>2];g=b+48|0;c[g>>2]=c[j+32>>2];c[g+4>>2]=c[j+32+4>>2];c[g+8>>2]=c[j+32+8>>2];c[g+12>>2]=c[j+32+12>>2];g=b+64|0;c[g>>2]=c[j+80>>2];c[g+4>>2]=c[j+80+4>>2];c[g+8>>2]=c[j+80+8>>2];c[g+12>>2]=c[j+80+12>>2];g=b+80|0;c[g>>2]=c[j+16>>2];c[g+4>>2]=c[j+16+4>>2];c[g+8>>2]=c[j+16+8>>2];c[g+12>>2]=c[j+16+12>>2];g=b+96|0;c[g>>2]=c[j+96>>2];c[g+4>>2]=c[j+96+4>>2];c[g+8>>2]=c[j+96+8>>2];c[g+12>>2]=c[j+96+12>>2];g=b+112|0;c[g>>2]=c[j+48>>2];c[g+4>>2]=c[j+48+4>>2];c[g+8>>2]=c[j+48+8>>2];c[g+12>>2]=c[j+48+12>>2];if((e|0)==128&(f|0)==0)break;g=fg(e|0,f|0,-128,-1)|0;b=b+128|0;d=d+128|0;f=z;e=g}if((i|0)==5?(h=yf(e|0,f|0,4)|0,i=z,i=fg(ug(j+12|0)|0,0,h|0,i|0)|0,gg(j+12|0,i),c[j+272>>2]=c[j+128>>2],c[j+272+4>>2]=c[j+128+4>>2],c[j+272+8>>2]=c[j+128+8>>2],c[j+272+12>>2]=c[j+128+12>>2],c[j+272+16>>2]=c[j+112>>2],c[j+272+16+4>>2]=c[j+112+4>>2],c[j+272+16+8>>2]=c[j+112+8>>2],c[j+272+16+12>>2]=c[j+112+12>>2],c[j+272+32>>2]=c[j+64>>2],c[j+272+32+4>>2]=c[j+64+4>>2],c[j+272+32+8>>2]=c[j+64+8>>2],c[j+272+32+12>>2]=c[j+64+12>>2],c[j+272+48>>2]=c[j+32>>2],c[j+272+48+4>>2]=c[j+32+4>>2],c[j+272+48+8>>2]=c[j+32+8>>2],c[j+272+48+12>>2]=c[j+32+12>>2],c[j+272+64>>2]=c[j+80>>2],c[j+272+64+4>>2]=c[j+80+4>>2],c[j+272+64+8>>2]=c[j+80+8>>2],c[j+272+64+12>>2]=c[j+80+12>>2],c[j+272+80>>2]=c[j+16>>2],c[j+272+80+4>>2]=c[j+16+4>>2],c[j+272+80+8>>2]=c[j+16+8>>2],c[j+272+80+12>>2]=c[j+16+12>>2],c[j+272+96>>2]=c[j+96>>2],c[j+272+96+4>>2]=c[j+96+4>>2],c[j+272+96+8>>2]=c[j+96+8>>2],c[j+272+96+12>>2]=c[j+96+12>>2],c[j+272+112>>2]=c[j+48>>2],c[j+272+112+4>>2]=c[j+48+4>>2],c[j+272+112+8>>2]=c[j+48+8>>2],c[j+272+112+12>>2]=c[j+48+12>>2],!((e|0)==0&(f|0)==0)):0){g=j+272|0;while(1){a[b>>0]=a[d>>0]^a[g>>0];e=fg(e|0,f|0,-1,-1)|0;f=z;if((e|0)==0&(f|0)==0)break;else{g=g+1|0;d=d+1|0;b=b+1|0}}}l=k;return 0}function fa(b,d,e,f,g){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0;j=l;i=l=l+63&-64;l=l+400|0;Ce(i,f);while(1){c[i+256>>2]=c[i>>2];c[i+256+4>>2]=c[i+4>>2];c[i+256+8>>2]=c[i+8>>2];c[i+256+12>>2]=c[i+12>>2];Ce(i+240|0,i+256|0);rb(i+240|0,35254);Ce(i+224|0,i+240|0);Ce(i+208|0,i+240|0);Ce(i+192|0,i+240|0);Ce(i+176|0,i+240|0);Ce(i+160|0,i+240|0);Ce(i+144|0,i+240|0);Eg(i+240|0,1);Eg(i+224|0,2);Eg(i+208|0,3);Eg(i+192|0,4);Eg(i+176|0,5);Eg(i+160|0,6);Eg(i+144|0,7);rb(i+256|0,35222);rb(i+240|0,35270);rb(i+224|0,35270);rb(i+208|0,35270);rb(i+192|0,35270);rb(i+176|0,35270);rb(i+160|0,35270);rb(i+144|0,35270);Ce(i+128|0,i+160|0);_d(i+128|0,1);Gd(i+128|0,i+144|0);Hd(i+128|0,1104);Gd(i+144|0,i+128|0);ae(i+128|0,1);Gd(i+160|0,i+128|0);Ce(i+128|0,i+192|0);_d(i+128|0,1);Gd(i+128|0,i+176|0);Hd(i+128|0,1104);Gd(i+176|0,i+128|0);ae(i+128|0,1);Gd(i+192|0,i+128|0);Ce(i+128|0,i+224|0);_d(i+128|0,1);Gd(i+128|0,i+208|0);Hd(i+128|0,1104);Gd(i+208|0,i+128|0);ae(i+128|0,1);Gd(i+224|0,i+128|0);Ce(i+128|0,i+256|0);_d(i+128|0,1);Gd(i+128|0,i+240|0);Hd(i+128|0,1104);Gd(i+240|0,i+128|0);ae(i+128|0,1);Gd(i+256|0,i+128|0);Ce(i+128|0,i+176|0);_d(i+128|0,2);Gd(i+128|0,i+144|0);Hd(i+128|0,1120);Gd(i+144|0,i+128|0);ae(i+128|0,2);Gd(i+176|0,i+128|0);Ce(i+128|0,i+192|0);_d(i+128|0,2);Gd(i+128|0,i+160|0);Hd(i+128|0,1120);Gd(i+160|0,i+128|0);ae(i+128|0,2);Gd(i+192|0,i+128|0);Ce(i+128|0,i+240|0);_d(i+128|0,2);Gd(i+128|0,i+208|0);Hd(i+128|0,1120);Gd(i+208|0,i+128|0);ae(i+128|0,2);Gd(i+240|0,i+128|0);Ce(i+128|0,i+256|0);_d(i+128|0,2);Gd(i+128|0,i+224|0);Hd(i+128|0,1120);Gd(i+224|0,i+128|0);ae(i+128|0,2);Gd(i+256|0,i+128|0);Ce(i+128|0,i+208|0);_d(i+128|0,4);Gd(i+128|0,i+144|0);Hd(i+128|0,1136);Gd(i+144|0,i+128|0);ae(i+128|0,4);Gd(i+208|0,i+128|0);Ce(i+128|0,i+224|0);_d(i+128|0,4);Gd(i+128|0,i+160|0);Hd(i+128|0,1136);Gd(i+160|0,i+128|0);ae(i+128|0,4);Gd(i+224|0,i+128|0);Ce(i+128|0,i+240|0);_d(i+128|0,4);Gd(i+128|0,i+176|0);Hd(i+128|0,1136);Gd(i+176|0,i+128|0);ae(i+128|0,4);Gd(i+240|0,i+128|0);Ce(i+128|0,i+256|0);_d(i+128|0,4);Gd(i+128|0,i+192|0);Hd(i+128|0,1136);Gd(i+192|0,i+128|0);ae(i+128|0,4);Gd(i+256|0,i+128|0);Gd(i+256|0,g);rb(i+256|0,35286);Gd(i+240|0,g+16|0);rb(i+240|0,35286);Gd(i+224|0,g+32|0);rb(i+224|0,35286);Gd(i+208|0,g+48|0);rb(i+208|0,35286);Gd(i+192|0,g+64|0);rb(i+192|0,35286);Gd(i+176|0,g+80|0);rb(i+176|0,35286);Gd(i+160|0,g+96|0);rb(i+160|0,35286);Gd(i+144|0,g+112|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+128|0);rb(i+128|0,35286);Gd(i+112|0,g+144|0);rb(i+112|0,35286);Gd(i+96|0,g+160|0);rb(i+96|0,35286);Gd(i+80|0,g+176|0);rb(i+80|0,35286);Gd(i+64|0,g+192|0);rb(i+64|0,35286);Gd(i+48|0,g+208|0);rb(i+48|0,35286);Gd(i+32|0,g+224|0);rb(i+32|0,35286);Gd(i+16|0,g+240|0);rb(i+16|0,35286);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);_c(i+256|0,i+128|0,147);_c(i+240|0,i+112|0,147);_c(i+224|0,i+64|0,147);_c(i+208|0,i+32|0,147);_c(i+192|0,i+80|0,147);_c(i+176|0,i+16|0,147);_c(i+160|0,i+96|0,147);_c(i+144|0,i+48|0,147);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+64|0,i+224|0);Gd(i+32|0,i+208|0);Gd(i+80|0,i+192|0);Gd(i+16|0,i+176|0);Gd(i+96|0,i+160|0);Gd(i+48|0,i+144|0);Gd(i+256|0,i+48|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+112|0);Gd(i+240|0,i+48|0);Gd(i+208|0,i+64|0);Gd(i+192|0,i+32|0);Gd(i+176|0,i+80|0);Gd(i+208|0,i+48|0);Gd(i+160|0,i+16|0);Gd(i+144|0,i+96|0);Gd(i+192|0,i+48|0);_c(i+128|0,i+128|0,78);_c(i+112|0,i+112|0,78);_c(i+64|0,i+64|0,78);_c(i+32|0,i+32|0,78);_c(i+80|0,i+80|0,78);_c(i+16|0,i+16|0,78);_c(i+96|0,i+96|0,78);_c(i+48|0,i+48|0,78);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+224|0,i+64|0);Gd(i+208|0,i+32|0);Gd(i+192|0,i+80|0);Gd(i+176|0,i+16|0);Gd(i+160|0,i+96|0);Gd(i+144|0,i+48|0);Gd(i+256|0,g+256|0);rb(i+256|0,35286);Gd(i+240|0,g+272|0);rb(i+240|0,35286);Gd(i+224|0,g+288|0);rb(i+224|0,35286);Gd(i+208|0,g+304|0);rb(i+208|0,35286);Gd(i+192|0,g+320|0);rb(i+192|0,35286);Gd(i+176|0,g+336|0);rb(i+176|0,35286);Gd(i+160|0,g+352|0);rb(i+160|0,35286);Gd(i+144|0,g+368|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+384|0);rb(i+128|0,35286);Gd(i+112|0,g+400|0);rb(i+112|0,35286);Gd(i+96|0,g+416|0);rb(i+96|0,35286);Gd(i+80|0,g+432|0);rb(i+80|0,35286);Gd(i+64|0,g+448|0);rb(i+64|0,35286);Gd(i+48|0,g+464|0);rb(i+48|0,35286);Gd(i+32|0,g+480|0);rb(i+32|0,35286);Gd(i+16|0,g+496|0);rb(i+16|0,35286);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);_c(i+256|0,i+128|0,147);_c(i+240|0,i+112|0,147);_c(i+224|0,i+64|0,147);_c(i+208|0,i+32|0,147);_c(i+192|0,i+80|0,147);_c(i+176|0,i+16|0,147);_c(i+160|0,i+96|0,147);_c(i+144|0,i+48|0,147);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+64|0,i+224|0);Gd(i+32|0,i+208|0);Gd(i+80|0,i+192|0);Gd(i+16|0,i+176|0);Gd(i+96|0,i+160|0);Gd(i+48|0,i+144|0);Gd(i+256|0,i+48|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+112|0);Gd(i+240|0,i+48|0);Gd(i+208|0,i+64|0);Gd(i+192|0,i+32|0);Gd(i+176|0,i+80|0);Gd(i+208|0,i+48|0);Gd(i+160|0,i+16|0);Gd(i+144|0,i+96|0);Gd(i+192|0,i+48|0);_c(i+128|0,i+128|0,78);_c(i+112|0,i+112|0,78);_c(i+64|0,i+64|0,78);_c(i+32|0,i+32|0,78);_c(i+80|0,i+80|0,78);_c(i+16|0,i+16|0,78);_c(i+96|0,i+96|0,78);_c(i+48|0,i+48|0,78);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+224|0,i+64|0);Gd(i+208|0,i+32|0);Gd(i+192|0,i+80|0);Gd(i+176|0,i+16|0);Gd(i+160|0,i+96|0);Gd(i+144|0,i+48|0);Gd(i+256|0,g+512|0);rb(i+256|0,35286);Gd(i+240|0,g+528|0);rb(i+240|0,35286);Gd(i+224|0,g+544|0);rb(i+224|0,35286);Gd(i+208|0,g+560|0);rb(i+208|0,35286);Gd(i+192|0,g+576|0);rb(i+192|0,35286);Gd(i+176|0,g+592|0);rb(i+176|0,35286);Gd(i+160|0,g+608|0);rb(i+160|0,35286);Gd(i+144|0,g+624|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+640|0);rb(i+128|0,35286);Gd(i+112|0,g+656|0);rb(i+112|0,35286);Gd(i+96|0,g+672|0);rb(i+96|0,35286);Gd(i+80|0,g+688|0);rb(i+80|0,35286);Gd(i+64|0,g+704|0);rb(i+64|0,35286);Gd(i+48|0,g+720|0);rb(i+48|0,35286);Gd(i+32|0,g+736|0);rb(i+32|0,35286);Gd(i+16|0,g+752|0);rb(i+16|0,35286);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);_c(i+256|0,i+128|0,147);_c(i+240|0,i+112|0,147);_c(i+224|0,i+64|0,147);_c(i+208|0,i+32|0,147);_c(i+192|0,i+80|0,147);_c(i+176|0,i+16|0,147);_c(i+160|0,i+96|0,147);_c(i+144|0,i+48|0,147);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+64|0,i+224|0);Gd(i+32|0,i+208|0);Gd(i+80|0,i+192|0);Gd(i+16|0,i+176|0);Gd(i+96|0,i+160|0);Gd(i+48|0,i+144|0);Gd(i+256|0,i+48|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+112|0);Gd(i+240|0,i+48|0);Gd(i+208|0,i+64|0);Gd(i+192|0,i+32|0);Gd(i+176|0,i+80|0);Gd(i+208|0,i+48|0);Gd(i+160|0,i+16|0);Gd(i+144|0,i+96|0);Gd(i+192|0,i+48|0);_c(i+128|0,i+128|0,78);_c(i+112|0,i+112|0,78);_c(i+64|0,i+64|0,78);_c(i+32|0,i+32|0,78);_c(i+80|0,i+80|0,78);_c(i+16|0,i+16|0,78);_c(i+96|0,i+96|0,78);_c(i+48|0,i+48|0,78);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+224|0,i+64|0);Gd(i+208|0,i+32|0);Gd(i+192|0,i+80|0);Gd(i+176|0,i+16|0);Gd(i+160|0,i+96|0);Gd(i+144|0,i+48|0);Gd(i+256|0,g+768|0);rb(i+256|0,35286);Gd(i+240|0,g+784|0);rb(i+240|0,35286);Gd(i+224|0,g+800|0);rb(i+224|0,35286);Gd(i+208|0,g+816|0);rb(i+208|0,35286);Gd(i+192|0,g+832|0);rb(i+192|0,35286);Gd(i+176|0,g+848|0);rb(i+176|0,35286);Gd(i+160|0,g+864|0);rb(i+160|0,35286);Gd(i+144|0,g+880|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+896|0);rb(i+128|0,35286);Gd(i+112|0,g+912|0);rb(i+112|0,35286);Gd(i+96|0,g+928|0);rb(i+96|0,35286);Gd(i+80|0,g+944|0);rb(i+80|0,35286);Gd(i+64|0,g+960|0);rb(i+64|0,35286);Gd(i+48|0,g+976|0);rb(i+48|0,35286);Gd(i+32|0,g+992|0);rb(i+32|0,35286);Gd(i+16|0,g+1008|0);rb(i+16|0,35286);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);_c(i+256|0,i+128|0,147);_c(i+240|0,i+112|0,147);_c(i+224|0,i+64|0,147);_c(i+208|0,i+32|0,147);_c(i+192|0,i+80|0,147);_c(i+176|0,i+16|0,147);_c(i+160|0,i+96|0,147);_c(i+144|0,i+48|0,147);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+64|0,i+224|0);Gd(i+32|0,i+208|0);Gd(i+80|0,i+192|0);Gd(i+16|0,i+176|0);Gd(i+96|0,i+160|0);Gd(i+48|0,i+144|0);Gd(i+256|0,i+48|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+112|0);Gd(i+240|0,i+48|0);Gd(i+208|0,i+64|0);Gd(i+192|0,i+32|0);Gd(i+176|0,i+80|0);Gd(i+208|0,i+48|0);Gd(i+160|0,i+16|0);Gd(i+144|0,i+96|0);Gd(i+192|0,i+48|0);_c(i+128|0,i+128|0,78);_c(i+112|0,i+112|0,78);_c(i+64|0,i+64|0,78);_c(i+32|0,i+32|0,78);_c(i+80|0,i+80|0,78);_c(i+16|0,i+16|0,78);_c(i+96|0,i+96|0,78);_c(i+48|0,i+48|0,78);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+224|0,i+64|0);Gd(i+208|0,i+32|0);Gd(i+192|0,i+80|0);Gd(i+176|0,i+16|0);Gd(i+160|0,i+96|0);Gd(i+144|0,i+48|0);Gd(i+256|0,g+1024|0);rb(i+256|0,35286);Gd(i+240|0,g+1040|0);rb(i+240|0,35286);Gd(i+224|0,g+1056|0);rb(i+224|0,35286);Gd(i+208|0,g+1072|0);rb(i+208|0,35286);Gd(i+192|0,g+1088|0);rb(i+192|0,35286);Gd(i+176|0,g+1104|0);rb(i+176|0,35286);Gd(i+160|0,g+1120|0);rb(i+160|0,35286);Gd(i+144|0,g+1136|0);rb(i+144|0,35286);Gd(i+176|0,i+160|0);Gd(i+224|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+160|0,i+224|0);Gd(i+208|0,i+256|0);Gd(i+160|0,i+208|0);Gd(i+208|0,i+144|0);Gd(i+208|0,i+192|0);Gd(i+144|0,i+176|0);Gd(i+208|0,i+240|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+144|0);Gd(i+240|0,i+176|0);Ce(i+80|0,i+144|0);Ce(i+96|0,i+240|0);Ce(i+112|0,i+176|0);Ce(i+48|0,i+224|0);Ce(i+64|0,i+160|0);Gd(i+80|0,i+192|0);Gd(i+96|0,i+224|0);Gd(i+112|0,i+208|0);Gd(i+48|0,i+192|0);Gd(i+64|0,i+256|0);Ce(i+32|0,i+80|0);Ce(i+128|0,i+96|0);Ce(i+16|0,i+80|0);Jd(i+96|0,i+112|0);Jd(i+80|0,i+64|0);Gd(i+16|0,i+128|0);Hd(i+32|0,i+64|0);Hd(i+128|0,i+112|0);Gd(i+64|0,i+112|0);Hd(i+16|0,i+64|0);Ce(i+64|0,i+208|0);Gd(i+64|0,i+256|0);Hd(i+48|0,i+64|0);Gd(i+80|0,i+48|0);Gd(i+96|0,i+48|0);Ce(i+48|0,i+144|0);Gd(i+48|0,i+240|0);Ce(i+64|0,i+176|0);Ce(i+112|0,i+48|0);Gd(i+64|0,i+160|0);Jd(i+112|0,i+64|0);Hd(i+48|0,i+64|0);Gd(i+128|0,i+48|0);Gd(i+80|0,i+16|0);Gd(i+96|0,i+32|0);Gd(i+112|0,i+16|0);Gd(i+128|0,i+32|0);Gd(i+112|0,i+32|0);Ce(i+64|0,i+224|0);Ce(i+48|0,i+192|0);Ce(i+32|0,i+240|0);Ce(i+16|0,i+144|0);Hd(i+64|0,i+208|0);Hd(i+48|0,i+256|0);Hd(i+32|0,i+176|0);Jd(i+16|0,i+160|0);Gd(i+80|0,i+64|0);Gd(i+96|0,i+48|0);Gd(i+112|0,i+32|0);Gd(i+128|0,i+16|0);Ce(i+64|0,i+80|0);Gd(i+64|0,i+96|0);Hd(i+80|0,i+112|0);Ce(i+32|0,i+128|0);Gd(i+32|0,i+80|0);Ce(i+16|0,i+64|0);Hd(i+16|0,i+32|0);Gd(i+16|0,i+96|0);Ce(i+48|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+80|0,i+96|0);Hd(i+48|0,i+80|0);Gd(i+48|0,i+128|0);Gd(i+112|0,i+48|0);Ce(i+96|0,i+32|0);Gd(i+96|0,i+48|0);Hd(i+96|0,i+128|0);Gd(i+112|0,i+96|0);Gd(i+32|0,i+96|0);Hd(i+32|0,i+16|0);Gd(i+32|0,i+64|0);Ce(i+64|0,i+160|0);Ce(i+128|0,i+176|0);Ce(i+96|0,i+16|0);Gd(i+96|0,i+32|0);Hd(i+96|0,i+160|0);Gd(i+160|0,i+176|0);Hd(i+160|0,i+32|0);Hd(i+176|0,i+16|0);Gd(i+160|0,i+176|0);Gd(i+176|0,i+96|0);Gd(i+64|0,i+256|0);Gd(i+128|0,i+208|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+256|0);Gd(i+256|0,i+208|0);Hd(i+256|0,i+112|0);Hd(i+208|0,i+48|0);Gd(i+256|0,i+208|0);Gd(i+208|0,i+96|0);Gd(i+160|0,i+64|0);Gd(i+256|0,i+64|0);Gd(i+176|0,i+128|0);Gd(i+208|0,i+128|0);Ce(i+64|0,i+144|0);Ce(i+128|0,i+240|0);Gd(i+64|0,i+192|0);Gd(i+128|0,i+224|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+64|0);Gd(i+64|0,i+128|0);Hd(i+64|0,i+32|0);Hd(i+128|0,i+16|0);Gd(i+128|0,i+64|0);Gd(i+64|0,i+80|0);Ce(i+96|0,i+48|0);Gd(i+96|0,i+112|0);Hd(i+96|0,i+192|0);Gd(i+192|0,i+224|0);Hd(i+192|0,i+112|0);Hd(i+224|0,i+48|0);Gd(i+192|0,i+224|0);Gd(i+224|0,i+96|0);Gd(i+16|0,i+48|0);Gd(i+32|0,i+112|0);Ce(i+80|0,i+16|0);Gd(i+80|0,i+32|0);Hd(i+80|0,i+144|0);Gd(i+144|0,i+240|0);Hd(i+144|0,i+32|0);Hd(i+240|0,i+16|0);Gd(i+144|0,i+240|0);Gd(i+240|0,i+80|0);Gd(i+144|0,i+64|0);Gd(i+192|0,i+64|0);Gd(i+240|0,i+128|0);Gd(i+224|0,i+128|0);Gd(i+144|0,i+256|0);Gd(i+240|0,i+160|0);Gd(i+192|0,i+144|0);Gd(i+160|0,i+256|0);Gd(i+256|0,i+240|0);Gd(i+240|0,i+176|0);Gd(i+176|0,i+224|0);Gd(i+192|0,i+176|0);Gd(i+224|0,i+208|0);Gd(i+208|0,i+176|0);Gd(i+160|0,i+208|0);_c(i+128|0,i+256|0,147);_c(i+112|0,i+240|0,147);_c(i+96|0,i+192|0,147);_c(i+80|0,i+160|0,147);_c(i+64|0,i+208|0,147);_c(i+48|0,i+144|0,147);_c(i+32|0,i+224|0,147);_c(i+16|0,i+176|0,147);Gd(i+256|0,i+128|0);Gd(i+240|0,i+112|0);Gd(i+192|0,i+96|0);Gd(i+160|0,i+80|0);Gd(i+208|0,i+64|0);Gd(i+144|0,i+48|0);Gd(i+224|0,i+32|0);Gd(i+176|0,i+16|0);Gd(i+128|0,i+176|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+240|0);Gd(i+112|0,i+176|0);Gd(i+80|0,i+192|0);Gd(i+64|0,i+160|0);Gd(i+48|0,i+208|0);Gd(i+80|0,i+176|0);Gd(i+32|0,i+144|0);Gd(i+16|0,i+224|0);Gd(i+64|0,i+176|0);_c(i+256|0,i+256|0,78);_c(i+240|0,i+240|0,78);_c(i+192|0,i+192|0,78);_c(i+160|0,i+160|0,78);_c(i+208|0,i+208|0,78);_c(i+144|0,i+144|0,78);_c(i+224|0,i+224|0,78);_c(i+176|0,i+176|0,78);Gd(i+128|0,i+256|0);Gd(i+112|0,i+240|0);Gd(i+96|0,i+192|0);Gd(i+80|0,i+160|0);Gd(i+64|0,i+208|0);Gd(i+48|0,i+144|0);Gd(i+32|0,i+224|0);Gd(i+16|0,i+176|0);Gd(i+128|0,g+1152|0);rb(i+128|0,35302);Gd(i+112|0,g+1168|0);rb(i+112|0,35302);Gd(i+96|0,g+1184|0);rb(i+96|0,35302);Gd(i+80|0,g+1200|0);rb(i+80|0,35302);Gd(i+64|0,g+1216|0);rb(i+64|0,35302);Gd(i+48|0,g+1232|0);rb(i+48|0,35302);Gd(i+32|0,g+1248|0);rb(i+32|0,35302);Gd(i+16|0,g+1264|0);rb(i+16|0,35302);Gd(i+48|0,i+32|0);Gd(i+96|0,i+112|0);Gd(i+48|0,i+128|0);Gd(i+32|0,i+96|0);Gd(i+80|0,i+128|0);Gd(i+32|0,i+80|0);Gd(i+80|0,i+16|0);Gd(i+80|0,i+64|0);Gd(i+16|0,i+48|0);Gd(i+80|0,i+112|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+16|0);Gd(i+112|0,i+48|0);Ce(i+208|0,i+16|0);Ce(i+224|0,i+112|0);Ce(i+240|0,i+48|0);Ce(i+176|0,i+96|0);Ce(i+192|0,i+32|0);Gd(i+208|0,i+64|0);Gd(i+224|0,i+96|0);Gd(i+240|0,i+80|0);Gd(i+176|0,i+64|0);Gd(i+192|0,i+128|0);Ce(i+160|0,i+208|0);Ce(i+256|0,i+224|0);Ce(i+144|0,i+208|0);Jd(i+224|0,i+240|0);Jd(i+208|0,i+192|0);Gd(i+144|0,i+256|0);Hd(i+160|0,i+192|0);Hd(i+256|0,i+240|0);Gd(i+192|0,i+240|0);Hd(i+144|0,i+192|0);Ce(i+192|0,i+80|0);Gd(i+192|0,i+128|0);Hd(i+176|0,i+192|0);Gd(i+208|0,i+176|0);Gd(i+224|0,i+176|0);Ce(i+176|0,i+16|0);Gd(i+176|0,i+112|0);Ce(i+192|0,i+48|0);Ce(i+240|0,i+176|0);Gd(i+192|0,i+32|0);Jd(i+240|0,i+192|0);Hd(i+176|0,i+192|0);Gd(i+256|0,i+176|0);Gd(i+208|0,i+144|0);Gd(i+224|0,i+160|0);Gd(i+240|0,i+144|0);Gd(i+256|0,i+160|0);Gd(i+240|0,i+160|0);Ce(i+192|0,i+96|0);Ce(i+176|0,i+64|0);Ce(i+160|0,i+112|0);Ce(i+144|0,i+16|0);Hd(i+192|0,i+80|0);Hd(i+176|0,i+128|0);Hd(i+160|0,i+48|0);Jd(i+144|0,i+32|0);Gd(i+208|0,i+192|0);Gd(i+224|0,i+176|0);Gd(i+240|0,i+160|0);Gd(i+256|0,i+144|0);Ce(i+192|0,i+208|0);Gd(i+192|0,i+224|0);Hd(i+208|0,i+240|0);Ce(i+160|0,i+256|0);Gd(i+160|0,i+208|0);Ce(i+144|0,i+192|0);Hd(i+144|0,i+160|0);Gd(i+144|0,i+224|0);Ce(i+176|0,i+240|0);Gd(i+176|0,i+256|0);Gd(i+208|0,i+224|0);Hd(i+176|0,i+208|0);Gd(i+176|0,i+256|0);Gd(i+240|0,i+176|0);Ce(i+224|0,i+160|0);Gd(i+224|0,i+176|0);Hd(i+224|0,i+256|0);Gd(i+240|0,i+224|0);Gd(i+160|0,i+224|0);Hd(i+160|0,i+144|0);Gd(i+160|0,i+192|0);Ce(i+192|0,i+32|0);Ce(i+256|0,i+48|0);Ce(i+224|0,i+144|0);Gd(i+224|0,i+160|0);Hd(i+224|0,i+32|0);Gd(i+32|0,i+48|0);Hd(i+32|0,i+160|0);Hd(i+48|0,i+144|0);Gd(i+32|0,i+48|0);Gd(i+48|0,i+224|0);Gd(i+192|0,i+128|0);Gd(i+256|0,i+80|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+128|0);Gd(i+128|0,i+80|0);Hd(i+128|0,i+240|0);Hd(i+80|0,i+176|0);Gd(i+128|0,i+80|0);Gd(i+80|0,i+224|0);Gd(i+32|0,i+192|0);Gd(i+128|0,i+192|0);Gd(i+48|0,i+256|0);Gd(i+80|0,i+256|0);Ce(i+192|0,i+16|0);Ce(i+256|0,i+112|0);Gd(i+192|0,i+64|0);Gd(i+256|0,i+96|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+192|0);Gd(i+192|0,i+256|0);Hd(i+192|0,i+160|0);Hd(i+256|0,i+144|0);Gd(i+256|0,i+192|0);Gd(i+192|0,i+208|0);Ce(i+224|0,i+176|0);Gd(i+224|0,i+240|0);Hd(i+224|0,i+64|0);Gd(i+64|0,i+96|0);Hd(i+64|0,i+240|0);Hd(i+96|0,i+176|0);Gd(i+64|0,i+96|0);Gd(i+96|0,i+224|0);Gd(i+144|0,i+176|0);Gd(i+160|0,i+240|0);Ce(i+208|0,i+144|0);Gd(i+208|0,i+160|0);Hd(i+208|0,i+16|0);Gd(i+16|0,i+112|0);Hd(i+16|0,i+160|0);Hd(i+112|0,i+144|0);Gd(i+16|0,i+112|0);Gd(i+112|0,i+208|0);Gd(i+16|0,i+192|0);Gd(i+64|0,i+192|0);Gd(i+112|0,i+256|0);Gd(i+96|0,i+256|0);Gd(i+16|0,i+128|0);Gd(i+112|0,i+32|0);Gd(i+64|0,i+16|0);Gd(i+32|0,i+128|0);Gd(i+128|0,i+112|0);Gd(i+112|0,i+48|0);Gd(i+48|0,i+96|0);Gd(i+64|0,i+48|0);Gd(i+96|0,i+80|0);Gd(i+80|0,i+48|0);Gd(i+32|0,i+80|0);Gd(i+128|0,g+1280|0);Gd(i+112|0,g+1296|0);Gd(i+64|0,g+1312|0);Gd(i+32|0,g+1328|0);Gd(i+80|0,g+1344|0);Gd(i+16|0,g+1360|0);Gd(i+96|0,g+1376|0);Gd(i+48|0,g+1392|0);Ce(i+256|0,i+96|0);_d(i+256|0,1);Gd(i+256|0,i+48|0);Hd(i+256|0,1104);Gd(i+48|0,i+256|0);ae(i+256|0,1);Gd(i+96|0,i+256|0);Ce(i+256|0,i+80|0);_d(i+256|0,1);Gd(i+256|0,i+16|0);Hd(i+256|0,1104);Gd(i+16|0,i+256|0);ae(i+256|0,1);Gd(i+80|0,i+256|0);Ce(i+256|0,i+64|0);_d(i+256|0,1);Gd(i+256|0,i+32|0);Hd(i+256|0,1104);Gd(i+32|0,i+256|0);ae(i+256|0,1);Gd(i+64|0,i+256|0);Ce(i+256|0,i+128|0);_d(i+256|0,1);Gd(i+256|0,i+112|0);Hd(i+256|0,1104);Gd(i+112|0,i+256|0);ae(i+256|0,1);Gd(i+128|0,i+256|0);Ce(i+256|0,i+16|0);_d(i+256|0,2);Gd(i+256|0,i+48|0);Hd(i+256|0,1120);Gd(i+48|0,i+256|0);ae(i+256|0,2);Gd(i+16|0,i+256|0);Ce(i+256|0,i+80|0);_d(i+256|0,2);Gd(i+256|0,i+96|0);Hd(i+256|0,1120);Gd(i+96|0,i+256|0);ae(i+256|0,2);Gd(i+80|0,i+256|0);Ce(i+256|0,i+112|0);_d(i+256|0,2);Gd(i+256|0,i+32|0);Hd(i+256|0,1120);Gd(i+32|0,i+256|0);ae(i+256|0,2);Gd(i+112|0,i+256|0);Ce(i+256|0,i+128|0);_d(i+256|0,2);Gd(i+256|0,i+64|0);Hd(i+256|0,1120);Gd(i+64|0,i+256|0);ae(i+256|0,2);Gd(i+128|0,i+256|0);Ce(i+256|0,i+32|0);_d(i+256|0,4);Gd(i+256|0,i+48|0);Hd(i+256|0,1136);Gd(i+48|0,i+256|0);ae(i+256|0,4);Gd(i+32|0,i+256|0);Ce(i+256|0,i+64|0);_d(i+256|0,4);Gd(i+256|0,i+96|0);Hd(i+256|0,1136);Gd(i+96|0,i+256|0);ae(i+256|0,4);Gd(i+64|0,i+256|0);Ce(i+256|0,i+112|0);_d(i+256|0,4);Gd(i+256|0,i+16|0);Hd(i+256|0,1136);Gd(i+16|0,i+256|0);ae(i+256|0,4);Gd(i+112|0,i+256|0);Ce(i+256|0,i+128|0);_d(i+256|0,4);Gd(i+256|0,i+80|0);Hd(i+256|0,1136);Gd(i+80|0,i+256|0);ae(i+256|0,4);Gd(i+128|0,i+256|0);if(e>>>0<0|(e|0)==0&d>>>0<128){h=5;break}gg(i+12|0,(ug(i+12|0)|0)+8|0);c[b>>2]=c[i+128>>2];c[b+4>>2]=c[i+128+4>>2];c[b+8>>2]=c[i+128+8>>2];c[b+12>>2]=c[i+128+12>>2];f=b+16|0;c[f>>2]=c[i+112>>2];c[f+4>>2]=c[i+112+4>>2];c[f+8>>2]=c[i+112+8>>2];c[f+12>>2]=c[i+112+12>>2];f=b+32|0;c[f>>2]=c[i+64>>2];c[f+4>>2]=c[i+64+4>>2];c[f+8>>2]=c[i+64+8>>2];c[f+12>>2]=c[i+64+12>>2];f=b+48|0;c[f>>2]=c[i+32>>2];c[f+4>>2]=c[i+32+4>>2];c[f+8>>2]=c[i+32+8>>2];c[f+12>>2]=c[i+32+12>>2];f=b+64|0;c[f>>2]=c[i+80>>2];c[f+4>>2]=c[i+80+4>>2];c[f+8>>2]=c[i+80+8>>2];c[f+12>>2]=c[i+80+12>>2];f=b+80|0;c[f>>2]=c[i+16>>2];c[f+4>>2]=c[i+16+4>>2];c[f+8>>2]=c[i+16+8>>2];c[f+12>>2]=c[i+16+12>>2];f=b+96|0;c[f>>2]=c[i+96>>2];c[f+4>>2]=c[i+96+4>>2];c[f+8>>2]=c[i+96+8>>2];c[f+12>>2]=c[i+96+12>>2];f=b+112|0;c[f>>2]=c[i+48>>2];c[f+4>>2]=c[i+48+4>>2];c[f+8>>2]=c[i+48+8>>2];c[f+12>>2]=c[i+48+12>>2];if((d|0)==128&(e|0)==0)break;f=fg(d|0,e|0,-128,-1)|0;b=b+128|0;e=z;d=f}if((h|0)==5?(g=yf(d|0,e|0,4)|0,h=z,h=fg(ug(i+12|0)|0,0,g|0,h|0)|0,gg(i+12|0,h),c[i+272>>2]=c[i+128>>2],c[i+272+4>>2]=c[i+128+4>>2],c[i+272+8>>2]=c[i+128+8>>2],c[i+272+12>>2]=c[i+128+12>>2],c[i+272+16>>2]=c[i+112>>2],c[i+272+16+4>>2]=c[i+112+4>>2],c[i+272+16+8>>2]=c[i+112+8>>2],c[i+272+16+12>>2]=c[i+112+12>>2],c[i+272+32>>2]=c[i+64>>2],c[i+272+32+4>>2]=c[i+64+4>>2],c[i+272+32+8>>2]=c[i+64+8>>2],c[i+272+32+12>>2]=c[i+64+12>>2],c[i+272+48>>2]=c[i+32>>2],c[i+272+48+4>>2]=c[i+32+4>>2],c[i+272+48+8>>2]=c[i+32+8>>2],c[i+272+48+12>>2]=c[i+32+12>>2],c[i+272+64>>2]=c[i+80>>2],c[i+272+64+4>>2]=c[i+80+4>>2],c[i+272+64+8>>2]=c[i+80+8>>2],c[i+272+64+12>>2]=c[i+80+12>>2],c[i+272+80>>2]=c[i+16>>2],c[i+272+80+4>>2]=c[i+16+4>>2],c[i+272+80+8>>2]=c[i+16+8>>2],c[i+272+80+12>>2]=c[i+16+12>>2],c[i+272+96>>2]=c[i+96>>2],c[i+272+96+4>>2]=c[i+96+4>>2],c[i+272+96+8>>2]=c[i+96+8>>2],c[i+272+96+12>>2]=c[i+96+12>>2],c[i+272+112>>2]=c[i+48>>2],c[i+272+112+4>>2]=c[i+48+4>>2],c[i+272+112+8>>2]=c[i+48+8>>2],c[i+272+112+12>>2]=c[i+48+12>>2],!((d|0)==0&(e|0)==0)):0){f=i+272|0;while(1){a[b>>0]=a[f>>0]|0;d=fg(d|0,e|0,-1,-1)|0;e=z;if((d|0)==0&(e|0)==0)break;else{f=f+1|0;b=b+1|0}}}l=j;return 0} +function Ab(b,c){b=b|0;c=c|0;var e=0,f=0,g=0,h=0,i=0;e=0;do{a[b+e>>0]=(d[c+(e>>3)>>0]|0)>>>(e&7)&1;e=e+1|0}while((e|0)!=256);h=0;do{i=b+h|0;a:do if(a[i>>0]|0){g=1;do{e=g+h|0;if((e|0)>=256)break a;c=a[b+e>>0]|0;b:do if(c<<24>>24){f=a[i>>0]|0;c=c<<24>>24<<g;if((f+c|0)<16){a[i>>0]=f+c;a[b+e>>0]=0;break}if((f-c|0)<=-16)break a;a[i>>0]=f-c;while(1){c=b+e|0;if(!(a[c>>0]|0))break;a[c>>0]=0;e=e+1|0;if((e|0)>=256)break b}a[c>>0]=1}while(0);g=g+1|0}while((g|0)<7)}while(0);h=h+1|0}while((h|0)!=256);return}function Bb(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0;a:do if(!((e|0)==0&(f|0)==0)){g=c[b+352>>2]|0;j=f;while(1){i=256-g|0;f=b+96+g|0;if(!(j>>>0>0|(j|0)==0&e>>>0>i>>>0))break;fb(f|0,d|0,i|0)|0;c[b+352>>2]=(c[b+352>>2]|0)+i;cd(b,128,0);ga(b,b+96|0);f=b+96|0;g=b+224|0;h=f+128|0;do{a[f>>0]=a[g>>0]|0;f=f+1|0;g=g+1|0}while((f|0)<(h|0));g=(c[b+352>>2]|0)+-128|0;c[b+352>>2]=g;e=cg(e|0,j|0,i|0,0)|0;f=z;if((e|0)==0&(f|0)==0)break a;else{d=d+i|0;j=f}}fb(f|0,d|0,e|0)|0;j=fg(c[b+352>>2]|0,0,e|0,j|0)|0;c[b+352>>2]=j}while(0);return}function Cb(b,d,e,f){b=b|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0;j=(c[d>>2]|0)==0;h=c[d+12>>2]|0;do if(j){g=a[d+8>>0]|0;if(!(g<<24>>24)){g=h+-1|0;break}g=O(c[b+12>>2]|0,g&255)|0;if(!f){g=g+(((h|0)==0)<<31>>31)|0;break}else{g=h+-1+g|0;break}}else{g=(c[b+16>>2]|0)-(c[b+12>>2]|0)|0;if(!f){g=g+(((h|0)==0)<<31>>31)|0;break}else{g=h+-1+g|0;break}}while(0);af(e|0,0,e|0,0)|0;af(g|0,0,z|0,0)|0;h=cg(g+-1|0,0,z|0,0)|0;e=z;if(!j?(i=a[d+8>>0]|0,i<<24>>24!=3):0){g=O(c[b+12>>2]|0,(i&255)+1|0)|0;f=0}else{g=0;f=0}j=fg(h|0,e|0,g|0,f|0)|0;b=Pe(j|0,z|0,c[b+16>>2]|0,0)|0;return b|0}function Db(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0;if(d<<24>>24?(d&255)<=64:0){if(!(sh(c[a+80>>2]|0,c[a+80+4>>2]|0)|0)){e=c[a+352>>2]|0;do if(e>>>0>128){cd(a,128,0);ga(a,a+96|0);e=(c[a+352>>2]|0)+-128|0;c[a+352>>2]=e;if(e>>>0<129){fb(a+96|0,a+224|0,e|0)|0;f=a+96|0;g=c[a+352>>2]|0;break}else ba(33525,33557,367,33602)}else{f=a+96|0;g=e}while(0);cd(a,g,0);ig(a);e=c[a+352>>2]|0;Pb(a+96+e|0,0,256-e|0)|0;ga(a,f);fb(b|0,a|0,d&255|0)|0;e=0}else e=-1;return e|0}Z();return 0}function Eb(b,c,e,f){b=b|0;c=c|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0;switch(((f>>>0)%3|0)&3){case 2:{g=((f>>>0)/3|0)<<2|1;h=3;break}case 1:{g=((f>>>0)/3|0)<<2;h=3;break}default:g=((f>>>0)/3|0)<<2}if((h|0)==3)g=g+2|0;if(g>>>0<c>>>0){if(f){i=0;c=0;while(1){i=d[e>>0]|0|i<<8;c=c+8|0;while(1){j=c+-6|0;h=b+1|0;a[b>>0]=xe(i>>>j&63)|0;if(j>>>0>5){b=h;c=j}else break}f=f+-1|0;if(!f)break;else{e=e+1|0;b=h;c=j}}if(!j)b=h;else{a[h>>0]=xe(i<<12-c&63)|0;b=b+2|0}}a[b>>0]=0}else g=-1;return g|0}function Fb(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0;m=(c[b+4>>2]|0)-(c[d+4>>2]|0)|0;l=(c[b+8>>2]|0)-(c[d+8>>2]|0)|0;k=(c[b+12>>2]|0)-(c[d+12>>2]|0)|0;j=(c[b+16>>2]|0)-(c[d+16>>2]|0)|0;i=(c[b+20>>2]|0)-(c[d+20>>2]|0)|0;h=(c[b+24>>2]|0)-(c[d+24>>2]|0)|0;g=(c[b+28>>2]|0)-(c[d+28>>2]|0)|0;f=(c[b+32>>2]|0)-(c[d+32>>2]|0)|0;e=(c[b+36>>2]|0)-(c[d+36>>2]|0)|0;c[a>>2]=(c[b>>2]|0)-(c[d>>2]|0);c[a+4>>2]=m;c[a+8>>2]=l;c[a+12>>2]=k;c[a+16>>2]=j;c[a+20>>2]=i;c[a+24>>2]=h;c[a+28>>2]=g;c[a+32>>2]=f;c[a+36>>2]=e;return}function Gb(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0;m=(c[d+4>>2]|0)+(c[b+4>>2]|0)|0;l=(c[d+8>>2]|0)+(c[b+8>>2]|0)|0;k=(c[d+12>>2]|0)+(c[b+12>>2]|0)|0;j=(c[d+16>>2]|0)+(c[b+16>>2]|0)|0;i=(c[d+20>>2]|0)+(c[b+20>>2]|0)|0;h=(c[d+24>>2]|0)+(c[b+24>>2]|0)|0;g=(c[d+28>>2]|0)+(c[b+28>>2]|0)|0;f=(c[d+32>>2]|0)+(c[b+32>>2]|0)|0;e=(c[d+36>>2]|0)+(c[b+36>>2]|0)|0;c[a>>2]=(c[d>>2]|0)+(c[b>>2]|0);c[a+4>>2]=m;c[a+8>>2]=l;c[a+12>>2]=k;c[a+16>>2]=j;c[a+20>>2]=i;c[a+24>>2]=h;c[a+28>>2]=g;c[a+32>>2]=f;c[a+36>>2]=e;return}function Hb(b,d){b=b|0;d=d|0;var e=0,f=0;a:do if(!(d&255))b=b+(uc(b)|0)|0;else{if(b&3)do{f=a[b>>0]|0;if(f<<24>>24==0?1:f<<24>>24==(d&255)<<24>>24)break a;b=b+1|0}while((b&3|0)!=0);f=O(d&255,16843009)|0;e=c[b>>2]|0;b:do if(!((e&-2139062144^-2139062144)&e+-16843009))do{e=e^f;if((e&-2139062144^-2139062144)&e+-16843009|0)break b;b=b+4|0;e=c[b>>2]|0}while(!((e&-2139062144^-2139062144)&e+-16843009|0));while(0);while(1){f=a[b>>0]|0;if(f<<24>>24==0?1:f<<24>>24==(d&255)<<24>>24)break;else b=b+1|0}}while(0);return b|0}function Ib(b,e,f,g,h,i){b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0;k=l;j=l=l+63&-64;l=l+32|0;m=d[h+4>>0]|d[h+4+1>>0]<<8|d[h+4+2>>0]<<16|d[h+4+3>>0]<<24;c[j>>2]=d[h>>0]|d[h+1>>0]<<8|d[h+2>>0]<<16|d[h+3>>0]<<24;c[j+4>>2]=m;c[j+8>>2]=0;c[j+8+4>>2]=0;re(j+16|0,f,g);h=j+16+8|0;a[h>>0]=0;a[h+1>>0]=0;a[h+2>>0]=0;a[h+3>>0]=0;h=j+16+8+4|0;a[h>>0]=0;a[h+1>>0]=0;a[h+2>>0]=0;a[h+3>>0]=0;if((e+-16|0)>>>0>48){c[8326]=22;b=-1}else b=Ec(b,e,0,0,0,i,32,j+16|0,j)|0;l=k;return b|0}function Jb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0,f=0;d=l;f=l=l+63&-64;l=l+128|0;e=Mg(c)|0;c=(c<<24>>24)-((c<<24>>24&0-(e&255))<<1)&255;Ff(a);Ke(a,2232+(b*960|0)|0,th(c,1)|0);Ke(a,2232+(b*960|0)+120|0,th(c,2)|0);Ke(a,2232+(b*960|0)+240|0,th(c,3)|0);Ke(a,2232+(b*960|0)+360|0,th(c,4)|0);Ke(a,2232+(b*960|0)+480|0,th(c,5)|0);Ke(a,2232+(b*960|0)+600|0,th(c,6)|0);Ke(a,2232+(b*960|0)+720|0,th(c,7)|0);Ke(a,2232+(b*960|0)+840|0,th(c,8)|0);qc(f,a+40|0);qc(f+40|0,a);dc(f+80|0,a+80|0);Ke(a,f,e);l=d;return}function Kb(a,b,d,e,f,g,h,i,j,k,m,n){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;n=n|0;k=l;l=l+336|0;Cg(k+264|0,64,0,m,n)|0;_g(k,k+264|0)|0;Sd(k+264|0,64);eg(k,h,i,j)|0;re(k+256|0,i,j);eg(k,k+256|0,8,0)|0;jf(a,e,f,g,m,1,0,n)|0;eg(k,a,f,g)|0;re(k+256|0,f,g);eg(k,k+256|0,8,0)|0;Zg(k,b)|0;Sd(k,256);if(d|0){c[d>>2]=16;c[d+4>>2]=0}l=k;return 0}function Lb(b,d,e,f,g,h,i){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0,n=0,o=0;o=l;k=l=l+63&-64;l=l+128|0;j=b;m=j+102|0;do{a[j>>0]=0;j=j+1|0}while((j|0)<(m|0));if(!(f>>>0>0|(f|0)==0&e>>>0>4294967295)){jb(g,h,i,k+8|0,k+4|0,k);gf(k+88|0,32);if((oc(c[k+8>>2]|0,c[k>>2]|0,c[k+4>>2]|0,k+88|0,k+24|0)|0)!=0?(Ih(k+12|0),m=(wb(k+12|0,d,e,k+24|0,b)|0)==0,Jh(k+12|0),!m):0)b=0;else{b=22;n=4}}else{b=27;n=4}if((n|0)==4){c[8326]=b;b=-1}l=o;return b|0}function Mb(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0;g=l;h=l=l+63&-64;l=l+64|0;if((c+-1&255)>63)Z();a[h>>0]=c;a[h+1>>0]=0;a[h+2>>0]=1;a[h+3>>0]=1;Vg(h+4|0);bf(h+8|0);c=h+16|0;f=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(f|0));if(!d){c=h+32|0;f=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(f|0))}else lf(h,d);if(!e){c=h+48|0;f=c+16|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(f|0))}else kf(h,e);ud(b,h);l=g;return}function Nb(b,c,d,e,f){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0;i=l;h=l=l+63&-64;l=l+480|0;g=(b|0)==0?c:b;c=(c|0)==0?g:c;if(!(bh(h+448|0,e,f)|0)){Dg(h,0,0,64)|0;rg(h,h+448|0,32,0)|0;Sd(h+448|0,32);rg(h,f,32,0)|0;rg(h,d,32,0)|0;Tg(h,h+384|0,64)|0;Sd(h,384);b=0;do{a[c+b>>0]=a[h+384+b>>0]|0;a[g+b>>0]=a[h+384+(b+32)>>0]|0;b=b+1|0}while((b|0)!=32);Sd(h+384|0,64);b=0}else b=-1;l=i;return b|0}function Ob(b,c,d,e,f){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0;i=l;h=l=l+63&-64;l=l+480|0;g=(b|0)==0?c:b;c=(c|0)==0?g:c;if(!(bh(h+448|0,e,f)|0)){Dg(h,0,0,64)|0;rg(h,h+448|0,32,0)|0;Sd(h+448|0,32);rg(h,d,32,0)|0;rg(h,f,32,0)|0;Tg(h,h+384|0,64)|0;Sd(h,384);b=0;do{a[g+b>>0]=a[h+384+b>>0]|0;a[c+b>>0]=a[h+384+(b+32)>>0]|0;b=b+1|0}while((b|0)!=32);Sd(h+384|0,64);b=0}else b=-1;l=i;return b|0}function Pb(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0;f=b+e|0;d=d&255;if((e|0)>=67){while(b&3){a[b>>0]=d;b=b+1|0}g=d|d<<8|d<<16|d<<24;while((b|0)<=((f&-4)-64|0)){c[b>>2]=g;c[b+4>>2]=g;c[b+8>>2]=g;c[b+12>>2]=g;c[b+16>>2]=g;c[b+20>>2]=g;c[b+24>>2]=g;c[b+28>>2]=g;c[b+32>>2]=g;c[b+36>>2]=g;c[b+40>>2]=g;c[b+44>>2]=g;c[b+48>>2]=g;c[b+52>>2]=g;c[b+56>>2]=g;c[b+60>>2]=g;b=b+64|0}while((b|0)<(f&-4|0)){c[b>>2]=g;b=b+4|0}}while((b|0)<(f|0)){a[b>>0]=d;b=b+1|0}return f-e|0}function Qb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+48|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);la(a+80|0,a,c+40|0);la(a+40|0,a+40|0,c);la(a+120|0,c+120|0,b+120|0);la(a,b+80|0,c+80|0);Gb(e,a,a);Fb(a,a+80|0,a+40|0);Gb(a+40|0,a+80|0,a+40|0);Fb(a+80|0,e,a+120|0);Gb(a+120|0,e,a+120|0);l=d;return}function Rb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+48|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);la(a+80|0,a,c);la(a+40|0,a+40|0,c+40|0);la(a+120|0,c+120|0,b+120|0);la(a,b+80|0,c+80|0);Gb(e,a,a);Fb(a,a+80|0,a+40|0);Gb(a+40|0,a+80|0,a+40|0);Gb(a+80|0,e,a+120|0);Fb(a+120|0,e,a+120|0);l=d;return}function Sb(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0;g=l;h=l=l+63&-64;l=l+192|0;if((c+-1&255)>63)Z();if((e+-1&255)>63|(d|0)==0)Z();else{a[h+128>>0]=c;a[h+128+1>>0]=e;a[h+128+2>>0]=1;a[h+128+3>>0]=1;Vg(h+128+4|0);bf(h+128+8|0);c=h+128+16|0;f=c+48|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(f|0));ud(b,h+128|0);Pb(h+(e&255)|0,0,(e<<24>>24<0?0:128-(e&255)|0)|0)|0;fb(h|0,d|0,e&255|0)|0;Bb(b,h,128,0);Sd(h,128);l=g;return}}function Tb(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0;e=l;f=l=l+63&-64;l=l+2048|0;if((a|0)!=0&(b|0)!=0){uh(f,(c[(c[b>>2]|0)+4>>2]|0)+(c[b+16>>2]<<10)+-1024|0);if((c[b+20>>2]|0)>>>0>1){d=1;do{g=c[b+16>>2]|0;g=g+-1+(O(g,d)|0)|0;Ud(f,(c[(c[b>>2]|0)+4>>2]|0)+(g<<10)|0);d=d+1|0}while(d>>>0<(c[b+20>>2]|0)>>>0)}Se(f+1024|0,f);Oa(c[a>>2]|0,c[a+4>>2]|0,f+1024|0,1024);Sd(f,1024);Sd(f+1024|0,1024);Gf(b,c[a+56>>2]&1);fh(c[b>>2]|0)}l=e;return}function Ub(a,b,d,e,f,g,h,i,j,k){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;var m=0,n=0;n=l;m=l=l+63&-64;l=l+16|0;Pb(a|0,0,b|0)|0;do if(!((g|d)>>>0>0|(g|d|0)==0&(f|b)>>>0>4294967295))if(d>>>0<0|(d|0)==0&b>>>0<16){c[8326]=22;a=-1;break}else{jb(i,j,k,m+8|0,m+4|0,m);k=vf(1,0,c[m+8>>2]|0)|0;a=dd(e,f,h,32,k,z,c[m>>2]|0,c[m+4>>2]|0,a,b)|0;break}else{c[8326]=27;a=-1}while(0);l=n;return a|0}function Vb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+48|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);la(a+80|0,a,c+40|0);la(a+40|0,a+40|0,c);la(a+120|0,c+80|0,b+120|0);Gb(e,b+80|0,b+80|0);Fb(a,a+80|0,a+40|0);Gb(a+40|0,a+80|0,a+40|0);Fb(a+80|0,e,a+120|0);Gb(a+120|0,e,a+120|0);l=d;return}function Wb(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+48|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);la(a+80|0,a,c);la(a+40|0,a+40|0,c+40|0);la(a+120|0,c+80|0,b+120|0);Gb(e,b+80|0,b+80|0);Fb(a,a+80|0,a+40|0);Gb(a+40|0,a+80|0,a+40|0);Gb(a+80|0,e,a+120|0);Fb(a+120|0,e,a+120|0);l=d;return}function Xb(a,b,e,f,g,h,i,j,k,m,n,o){a=a|0;b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;n=n|0;o=o|0;m=l;l=l+48|0;c[m>>2]=0;Da(m+16|0,n,o,0)|0;o=d[n+16+4>>0]|d[n+16+4+1>>0]<<8|d[n+16+4+2>>0]<<16|d[n+16+4+3>>0]<<24;c[m+4>>2]=d[n+16>>0]|d[n+16+1>>0]<<8|d[n+16+2>>0]<<16|d[n+16+3>>0]<<24;c[m+4+4>>2]=o;yb(a,b,e,f,g,h,i,j,k,0,m,m+16|0)|0;Sd(m+16|0,32);l=m;return 0}function Yb(a,b,c,d,e,f,g,h,i){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0;j=l;k=l=l+63&-64;l=l+384|0;if((b|0)==0&((e|0)!=0|(f|0)!=0))Z();if(!a)Z();if((d+-1&255)>63)Z();if(!((c|0)!=0|g<<24>>24!=0^1))Z();if((g&255)>64)Z();if(g<<24>>24)nb(k,d,c,g,h,i);else Mb(k,d,h,i);Bb(k,b,e,f);Db(k,a,d)|0;l=j;return}function Zb(a,b,e,f,g,h,i,j,k,m,n){a=a|0;b=b|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;m=m|0;n=n|0;b=l;l=l+48|0;c[b>>2]=0;Da(b+16|0,m,n,0)|0;n=d[m+16+4>>0]|d[m+16+4+1>>0]<<8|d[m+16+4+2>>0]<<16|d[m+16+4+3>>0]<<24;c[b+4>>2]=d[m+16>>0]|d[m+16+1>>0]<<8|d[m+16+2>>0]<<16|d[m+16+3>>0]<<24;c[b+4+4>>2]=n;m=lb(a,0,e,f,g,h,i,j,k,b,b+16|0)|0;Sd(b+16|0,32);l=b;return m|0}function _b(b,d,e,f,g,h,i){b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0,k=0,m=0,n=0;n=l;k=l=l+63&-64;l=l+16|0;j=b;m=j+128|0;do{a[j>>0]=0;j=j+1|0}while((j|0)<(m|0));do if(!((h|f)>>>0>0|(h|f|0)==0&(g|e)>>>0>4294967295|i>>>0>2147484671))if(h>>>0<0|(h|0)==0&g>>>0<3|i>>>0<8192){c[8326]=22;b=-1;break}else{gf(k,16);b=((Sf(g,i>>>10,d,e,k,b)|0)!=0)<<31>>31;break}else{c[8326]=27;b=-1}while(0);l=n;return b|0}function $b(a){a=a|0;var b=0,d=0,e=0,f=0,g=0;e=l;d=l=l+63&-64;l=l+48|0;b=hb(a)|0;if(!b){f=c[a+44>>2]|0;b=c[a+48>>2]|0;f=((f>>>0<b<<3>>>0?b<<3:f)>>>0)/(b<<2>>>0)|0;g=O(f,b<<2)|0;c[d>>2]=0;c[d+4>>2]=c[a+40>>2];c[d+8>>2]=g;c[d+12>>2]=f;c[d+16>>2]=f<<2;c[d+20>>2]=b;c[d+24>>2]=c[a+52>>2];c[d+28>>2]=1;b=ad(d,a)|0;if(!b){b=xb(d)|0;if(!b){Tb(a,d);b=0}}}l=e;return b|0}function ac(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0;e=c[a+32>>2]|0;i=c[a+32+4>>2]|0;d=yf(e|0,i|0,3)|0;if(0<0|0==0&(d&56)>>>0<56){fb(a+40+(d&63)|0,33915,56-(d&63)|0)|0;f=a+40|0;g=b+256|0;h=a;d=i}else{fb(a+40+(d&63)|0,33915,64-(d&63)|0)|0;pa(a,a+40|0,b,b+256|0);d=a+40|0;e=d+56|0;do{c[d>>2]=0;d=d+4|0}while((d|0)<(e|0));f=a+40|0;g=b+256|0;h=a;e=c[a+32>>2]|0;d=c[a+32+4>>2]|0}Lc(a+96|0,e,d);pa(h,f,b,g);return}function bc(b,d){b=b|0;d=d|0;c[b>>2]=(Rg(d)|0)&67108863;c[b+4>>2]=(Rg(d+3|0)|0)>>>2&67108611;c[b+8>>2]=(Rg(d+6|0)|0)>>>4&67092735;c[b+12>>2]=(Rg(d+9|0)|0)>>>6&66076671;c[b+16>>2]=(Rg(d+12|0)|0)>>>8&1048575;c[b+20>>2]=0;c[b+20+4>>2]=0;c[b+20+8>>2]=0;c[b+20+12>>2]=0;c[b+20+16>>2]=0;c[b+40>>2]=Rg(d+16|0)|0;c[b+44>>2]=Rg(d+20|0)|0;c[b+48>>2]=Rg(d+24|0)|0;c[b+52>>2]=Rg(d+28|0)|0;c[b+56>>2]=0;c[b+56+4>>2]=0;a[b+80>>0]=0;return}function cc(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0;g=l;h=l=l+63&-64;l=l+464|0;qb(h+208|0,a,b)|0;wg(h+208|0,c,d,0)|0;if(f|0){a=0;b=0;do{a=a+1|0;gg(h+448|0,a);fb(h|0,h+208|0,208)|0;wg(h,h+448|0,4,0)|0;qe(h,h+416|0)|0;d=f-b|0;fb(e+b|0,h+416|0,(d>>>0<32?d:32)|0)|0;b=a<<5}while(b>>>0<f>>>0)}Sd(h+208|0,208);l=g;return}function dc(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0;l=0-(c[b+4>>2]|0)|0;k=0-(c[b+8>>2]|0)|0;j=0-(c[b+12>>2]|0)|0;i=0-(c[b+16>>2]|0)|0;h=0-(c[b+20>>2]|0)|0;g=0-(c[b+24>>2]|0)|0;f=0-(c[b+28>>2]|0)|0;e=0-(c[b+32>>2]|0)|0;d=0-(c[b+36>>2]|0)|0;c[a>>2]=0-(c[b>>2]|0);c[a+4>>2]=l;c[a+8>>2]=k;c[a+12>>2]=j;c[a+16>>2]=i;c[a+20>>2]=h;c[a+24>>2]=g;c[a+28>>2]=f;c[a+32>>2]=e;c[a+36>>2]=d;return}function ec(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;Pb(a|0,0,b|0)|0;do if((l|0)==1){if((g|d|j)>>>0>0|(g|d|j|0)==0&(f|b|i)>>>0>4294967295|k>>>0>2147484671){c[8326]=27;a=-1;break}if(d>>>0<0|(d|0)==0&b>>>0<16|(j>>>0<0|(j|0)==0&i>>>0<3)|k>>>0<8192){c[8326]=22;a=-1;break}else{a=((Hf(i,k>>>10,e,f,h,a,b)|0)!=0)<<31>>31;break}}else a=-1;while(0);return a|0}function fc(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0,i=0,j=0;if(!d)b=0;else{i=a[b>>0]|0;e=a[c>>0]|0;a:do if(!(i<<24>>24)){d=e&255;b=i&255}else{j=b;h=d;f=e;g=i;d=e&255;b=i&255;do{h=h+-1|0;if(!(g<<24>>24==f<<24>>24&((h|0)!=0&f<<24>>24!=0)))break a;j=j+1|0;c=c+1|0;g=a[j>>0]|0;b=g&255;f=a[c>>0]|0;d=f&255}while(g<<24>>24!=0)}while(0);b=b-d|0}return b|0}function gc(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;e=l;f=l=l+63&-64;l=l+1024|0;if(c[b+20>>2]|0){d=0;do{jg(a+64|0,0);jg(a+68|0,d);Oa(f,1024,a,72);Ee((c[(c[b>>2]|0)+4>>2]|0)+((O(c[b+16>>2]|0,d)|0)<<10)|0,f);jg(a+64|0,1);Oa(f,1024,a,72);Ee((c[(c[b>>2]|0)+4>>2]|0)+((O(c[b+16>>2]|0,d)|0)+1<<10)|0,f);d=d+1|0}while(d>>>0<(c[b+20>>2]|0)>>>0)}Sd(f,1024);l=e;return}function hc(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;h=l;i=l=l+63&-64;l=l+384|0;if((b|0)==0&((e|0)!=0|(f|0)!=0))Z();if(!a)Z();if((d+-1&255)>63)Z();if(!((c|0)!=0|g<<24>>24!=0^1))Z();if((g&255)>64)Z();if(g<<24>>24)Sb(i,d,c,g);else Hc(i,d);Bb(i,b,e,f);Db(i,a,d)|0;l=h;return}function ic(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;e=l;d=l=l+63&-64;l=l+16|0;do if((((a|0)!=0?(b|0)!=0:0)?((b<<10>>>0)/(b>>>0)|0|0)==1024:0)?(f=ia(12)|0,c[a>>2]=f,(f|0)!=0):0){f=sf(d,b<<10)|0;c[8326]=f;if(f|0){c[d>>2]=0;d=-22;break}d=c[d>>2]|0;if(d){c[c[a>>2]>>2]=d;c[(c[a>>2]|0)+4>>2]=d;c[(c[a>>2]|0)+8>>2]=b<<10;d=0}else d=-22}else d=-22;while(0);l=e;return d|0}function jc(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+48|0;qa(a,b);qa(a+80|0,b+40|0);oa(a+120|0,b+80|0);Gb(a+40|0,b,b+40|0);qa(d,a+40|0);Gb(a+40|0,a+80|0,a);Fb(a+80|0,a+80|0,a);Fb(a,d,a+40|0);Fb(a+120|0,a+120|0,a+80|0);l=c;return}function kc(a,b,d,e,f,g){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;h=l;i=l=l+63&-64;l=l+16|0;Ed(a+64|0,d|0,e|0)|0;Jf(a,i,a+64|0,e,f,g)|0;if((c[i>>2]|0)==64&(c[i+4>>2]|0)==0)if(b|0){a=fg(e|0,f|0,64,0)|0;c[b>>2]=a;c[b+4>>2]=z;a=0}else a=0;else{if(b|0){c[b>>2]=0;c[b+4>>2]=0}i=fg(e|0,f|0,64,0)|0;Pb(a|0,0,i|0)|0;a=-1}l=h;return a|0}function lc(a,b){a=a|0;b=b|0;var c=0,d=0;d=l;c=l=l+63&-64;l=l+240|0;if(!(Za(c+80|0,b)|0)){Bf(c);Fb(c,c,c+80+40|0);Fa(c,c);Bf(c+40|0);Gb(c+40|0,c+40|0,c+80+40|0);la(c+40|0,c+40|0,c);Ja(a,c+40|0);a=0}else a=-1;l=d;return a|0}function mc(a,b,d,e,f,g){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0;e=fg(e|0,f|0,-64,-1)|0;f=z;do if(f>>>0>0|(f|0)==0&e>>>0>4294967231)h=7;else{if(Pf(d,d+64|0,e,f,g)|0){Pb(a|0,0,e|0)|0;h=7;break}if(b|0){c[b>>2]=e;c[b+4>>2]=f}Ed(a|0,d+64|0,e|0)|0;e=0}while(0);if((h|0)==7)if(!b)e=-1;else{c[b>>2]=0;c[b+4>>2]=0;e=-1}return e|0}function nc(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0,i=0;i=a[b>>0]|0;a:do if((i+-48&255)<=9){g=0;h=b;f=i;while(1){e=(f<<24>>24)+-48|0;f=g*10|0;if(!(g>>>0<429496730&(e>>>0>~f>>>0^1))){e=0;break a}g=(e>>>0>~f>>>0?0:e)+f|0;e=h+1|0;f=a[e>>0]|0;if((f+-48&255)>9)break;else h=e}if((e|0)!=(b|0)?(h|0)==(b|0)|i<<24>>24!=48:0)c[d>>2]=g;else e=0}else e=0;while(0);return e|0}function oc(b,c,d,e,f){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0,k=0;if((((b>>>0<=63?(j=af(d|0,0,c|0,0)|0,k=z,!(k>>>0>0|(k|0)==0&j>>>0>1073741823)):0)?(a[f>>0]=36,a[f+1>>0]=55,a[f+2>>0]=36,a[f+3>>0]=a[34193+b>>0]|0,g=bd(f+4|0,54,c,30)|0,(g|0)!=0):0)?(h=bd(g,f+58-g|0,d,30)|0,(h|0)!=0):0)?(i=Rc(h,f+58-h|0,e)|0,(i|0)!=0&i>>>0<(f+58|0)>>>0):0)a[i>>0]=0;else f=0;return f|0}function pc(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;d=yf(c[a+72>>2]|0,c[a+72+4>>2]|0,3)|0;if(0<0|0==0&(d&112)>>>0<112){fb(a+80+(d&127)|0,33979,112-(d&127)|0)|0;d=a+80|0;e=b+640|0;f=a}else{fb(a+80+(d&127)|0,33979,128-(d&127)|0)|0;ja(a,a+80|0,b,b+640|0);d=a+80|0;e=d+112|0;do{c[d>>2]=0;d=d+4|0}while((d|0)<(e|0));d=a+80|0;e=b+640|0;f=a}ne(a+192|0,a+64|0,16);ja(f,d,b,e);return}function qc(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0;l=c[b+4>>2]|0;k=c[b+8>>2]|0;j=c[b+12>>2]|0;i=c[b+16>>2]|0;h=c[b+20>>2]|0;g=c[b+24>>2]|0;f=c[b+28>>2]|0;e=c[b+32>>2]|0;d=c[b+36>>2]|0;c[a>>2]=c[b>>2];c[a+4>>2]=l;c[a+8>>2]=k;c[a+12>>2]=j;c[a+16>>2]=i;c[a+20>>2]=h;c[a+24>>2]=g;c[a+28>>2]=f;c[a+32>>2]=e;c[a+36>>2]=d;return}function rc(b,c,d,e,f,g){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0,j=0;i=l;h=l=l+63&-64;l=l+32|0;if(!(e>>>0<0|(e|0)==0&d>>>0<32)?(zd(h,32,0,f,g)|0,j=fg(d|0,e|0,-32,-1)|0,(Rf(c+16|0,c+32|0,j,z,h)|0)==0):0){If(b,c,d,e,f,g)|0;c=b+32|0;do{a[b>>0]=0;b=b+1|0}while((b|0)<(c|0));b=0}else b=-1;l=i;return b|0}function sc(a){a=a|0;return ((0-((0-(a^47)|0)>>>8&63^63|(0-(a^43)|0)>>>8&62^62|((a+65439|0)>>>8^255)&a+185&((122-a|0)>>>8&255^255)|((a+-65|0)>>>8^255)&a+-65&((90-a|0)>>>8&255^255)|((a+65488|0)>>>8^255)&a+4&((57-a|0)>>>8&255^255))|0)>>>8&255^255)&(0-(a^65)|0)>>>8|((0-(a^47)|0)>>>8&63^63|(0-(a^43)|0)>>>8&62^62|((a+65439|0)>>>8^255)&a+185&((122-a|0)>>>8&255^255)|((a+-65|0)>>>8^255)&a+-65&((90-a|0)>>>8&255^255)|((a+65488|0)>>>8^255)&a+4&((57-a|0)>>>8&255^255))|0}function tc(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0,h=0,i=0,j=0;f=0;h=0;i=0;a:while(1){while(1){g=sc(a[e>>0]|0)|0;if((g|0)==255){j=7;break a}e=e+1|0;h=g+(h<<6)|0;g=f+6|0;if(g>>>0>7)break;else f=g}f=f+-2|0;if(i>>>0>=(c[d>>2]|0)>>>0){e=0;break}a[b>>0]=h>>>f;b=b+1|0;i=i+1|0}if((j|0)==7)if(f>>>0<=4?((1<<f)+-1&h|0)==0:0)c[d>>2]=i;else e=0;return e|0}function uc(b){b=b|0;var d=0,e=0,f=0;a:do if(!(b&3)){d=b;f=4}else{d=b;e=b;while(1){if(!(a[d>>0]|0)){d=e;break a}d=d+1|0;e=d;if(!(e&3)){f=4;break}}}while(0);if((f|0)==4){while(1){e=c[d>>2]|0;if(!((e&-2139062144^-2139062144)&e+-16843009))d=d+4|0;else break}if((e&255)<<24>>24)do d=d+1|0;while((a[d>>0]|0)!=0)}return d-b|0}function vc(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0,h=0;h=l;f=l=l+63&-64;l=l+128|0;if((mb(b,0,102)|0)==(b+101|0)){Ih(f);e=f+12|0;g=e+102|0;do{a[e>>0]=0;e=e+1|0}while((e|0)<(g|0));d=(wb(f,c,d,b,f+12|0)|0)==0;Jh(f);if(!d){e=Qc(f+12|0,b,102)|0;Sd(f+12|0,102)}else e=-1}else e=-1;l=h;return e|0}function wc(b,c,d,e,f){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0,i=0,j=0;j=l;l=l+96|0;if(!(eh(j+32|0,j)|0)){g=b;h=j+32|0;i=g+32|0;do{a[g>>0]=a[h>>0]|0;g=g+1|0;h=h+1|0}while((g|0)<(i|0));wd(j+64|0,j+32|0,f);b=se(b+32|0,c,d,e,j+64|0,f,j)|0;Sd(j,32);Sd(j+32|0,32);Sd(j+64|0,24)}else b=-1;l=j;return b|0}function xc(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;do if(!(c>>>0>64|(d+-1|0)>>>0>63)){if(d>>>0>=256)ba(33636,33656,75,33829);if(c>>>0>=256)ba(33736,33656,76,33829);if((b|0)==0|(c|0)==0){Mb(a,d&255,e,f);a=0;break}else{nb(a,d&255,b,c&255,e,f);a=0;break}}else a=-1;while(0);return a|0}function yc(b,c){b=b|0;c=c|0;var d=0,e=0,f=0,g=0;f=l;g=l=l+63&-64;l=l+240|0;e=g+200|0;d=e+32|0;do{a[e>>0]=a[c>>0]|0;e=e+1|0;c=c+1|0}while((e|0)<(d|0));a[g+200>>0]=a[g+200>>0]&-8;a[g+200+31>>0]=a[g+200+31>>0]&63|64;ab(g+40|0,g+200|0);qd(g,g+40+40|0,g+40+80|0);Ja(b,g);l=f;return 0}function zc(a){a=a|0;var b=0,c=0,e=0,f=0,g=0,h=0,i=0;g=d[a+7>>0]|0;h=vf(d[a+6>>0]|0|0,0,8)|0;i=z;f=vf(d[a+5>>0]|0|0,0,16)|0;i=i|z;e=vf(d[a+4>>0]|0|0,0,24)|0;i=i|z|(d[a+3>>0]|0);c=vf(d[a+2>>0]|0|0,0,40)|0;i=i|z;b=vf(d[a+1>>0]|0|0,0,48)|0;i=i|z;a=vf(d[a>>0]|0|0,0,56)|0;z=i|z;return h|g|f|e|c|b|a|0}function Ac(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(g>>>0>0|(g|0)==0&f>>>0>15){d=fg(f|0,g|0,-16,-1)|0;a=Zb(a,0,e,d,z,e+f+-16|0,h,i,j,k,l)|0}else a=-1;if(b|0){k=(a|0)==0;g=fg(f|0,g|0,-16,-1)|0;c[b>>2]=k?g:0;c[b+4>>2]=k?z:0}return a|0}function Bc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(g>>>0>0|(g|0)==0&f>>>0>15){d=fg(f|0,g|0,-16,-1)|0;a=lb(a,0,e,d,z,e+f+-16|0,h,i,j,k,l)|0}else a=-1;if(b|0){k=(a|0)==0;g=fg(f|0,g|0,-16,-1)|0;c[b>>2]=k?g:0;c[b+4>>2]=k?z:0}return a|0}function Cc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(g>>>0>0|(g|0)==0&f>>>0>15){d=fg(f|0,g|0,-16,-1)|0;a=zb(a,0,e,d,z,e+f+-16|0,h,i,j,k,l)|0}else a=-1;if(b|0){k=(a|0)==0;g=fg(f|0,g|0,-16,-1)|0;c[b>>2]=k?g:0;c[b+4>>2]=k?z:0}return a|0}function Dc(b,c,e,f){b=b|0;c=c|0;e=e|0;f=f|0;var g=0,h=0;if(!(f>>>0<2147483647&f<<1>>>0<c>>>0))Z();if(!f)c=0;else{g=0;c=0;while(1){h=d[e+g>>0]|0;a[b+c>>0]=(h>>>4)+87+(((h>>>4)+65526|0)>>>8&217);a[b+(c|1)>>0]=(((h&15)<<8)+22272+((h&15)+65526&55552)|0)>>>8;c=g+1|0;if((c|0)==(f|0)){c=f<<1;break}else{g=c;c=c<<1}}}a[b+c>>0]=0;return b|0}function Ec(a,b,c,d,e,f,g,h,i){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;var j=0;do if(!((b+-1|0)>>>0>63|g>>>0>64)){if(b>>>0>=256)ba(33636,33656,35,33756);if(g>>>0<256){Yb(a,c,f,b&255,d,e,g&255,h,i);j=0;break}else ba(33736,33656,36,33756)}else j=-1;while(0);return j|0}function Fc(a,b){a=a|0;b=b|0;c[a>>2]=1634760805;c[a+4>>2]=857760878;c[a+8>>2]=2036477234;c[a+12>>2]=1797285236;c[a+16>>2]=Rg(b)|0;c[a+20>>2]=Rg(b+4|0)|0;c[a+24>>2]=Rg(b+8|0)|0;c[a+28>>2]=Rg(b+12|0)|0;c[a+32>>2]=Rg(b+16|0)|0;c[a+36>>2]=Rg(b+20|0)|0;c[a+40>>2]=Rg(b+24|0)|0;c[a+44>>2]=Rg(b+28|0)|0;return}function Gc(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;do if(!(c>>>0>64|(d+-1|0)>>>0>63)){if(d>>>0>=256)ba(33636,33656,52,33797);if(c>>>0>=256)ba(33736,33656,53,33797);if((b|0)==0|(c|0)==0){Hc(a,d&255);a=0;break}else{Sb(a,d&255,b,c&255);a=0;break}}else a=-1;while(0);return a|0}function Hc(b,c){b=b|0;c=c|0;var d=0,e=0,f=0;e=l;f=l=l+63&-64;l=l+64|0;if((c+-1&255)>63)Z();else{a[f>>0]=c;a[f+1>>0]=0;a[f+2>>0]=1;a[f+3>>0]=1;Vg(f+4|0);bf(f+8|0);c=f+16|0;d=c+48|0;do{a[c>>0]=0;c=c+1|0}while((c|0)<(d|0));ud(b,f);l=e;return}}function Ic(b,c){b=b|0;c=c|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+128|0;Fa(f+80|0,c+80|0);la(f+40|0,c,f+80|0);la(f,c+40|0,f+80|0);Ja(b,f);c=(Ve(f+40|0)|0)<<7;a[b+31>>0]=(d[b+31>>0]|0)^c;l=e;return}function Jc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(f>>>0>4294967295|(f|0)==-1&e>>>0>4294967279)Z();Xb(a,a+e|0,0,d,e,f,g,h,i,0,k,l)|0;if(b|0){k=fg(e|0,f|0,16,0)|0;c[b>>2]=k;c[b+4>>2]=z}return 0}function Kc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(f>>>0>4294967295|(f|0)==-1&e>>>0>4294967279)Z();yb(a,a+e|0,0,d,e,f,g,h,i,0,k,l)|0;if(b|0){k=fg(e|0,f|0,16,0)|0;c[b>>2]=k;c[b+4>>2]=z}return 0}function Lc(b,c,d){b=b|0;c=c|0;d=d|0;var e=0;a[b+7>>0]=c;e=yf(c|0,d|0,8)|0;a[b+6>>0]=e;e=yf(c|0,d|0,16)|0;a[b+5>>0]=e;e=yf(c|0,d|0,24)|0;a[b+4>>0]=e;a[b+3>>0]=d;e=yf(c|0,d|0,40)|0;a[b+2>>0]=e;e=yf(c|0,d|0,48)|0;a[b+1>>0]=e;d=yf(c|0,d|0,56)|0;a[b>>0]=d;return}function Mc(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;j=l;i=l=l+63&-64;l=l+32|0;if(!(Ad(i,g,h)|0)){a=Je(a,b,c,d,e,f,i)|0;Sd(i,32)}else a=-1;l=j;return a|0}function Nc(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if(f>>>0>4294967295|(f|0)==-1&e>>>0>4294967279)Z();Kb(a,a+e|0,0,d,e,f,g,h,i,0,k,l)|0;if(b|0){k=fg(e|0,f|0,16,0)|0;c[b>>2]=k;c[b+4>>2]=z}return 0}function Oc(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;j=l;i=l=l+63&-64;l=l+32|0;if(!(Ad(i,g,h)|0)){Qe(a,b,c,d,e,f,i)|0;Sd(i,32);a=0}else a=-1;l=j;return a|0}function Pc(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;i=l;j=l=l+63&-64;l=l+80|0;if(!((c|0)==0&(d|0)==0)){jg(j+64|0,f);jg(j+64+4|0,g);Fc(j,h);$d(j,e,j+64|0);va(j,b,a,c,d);Sd(j,64)}l=i;return 0}function Qc(b,d,e){b=b|0;d=d|0;e=e|0;var f=0,g=0;g=l;f=l=l+63&-64;l=l+16|0;c[f+4>>2]=b;c[f>>2]=d;if(!e)b=0;else{b=0;d=0;do{d=(a[(c[f>>2]|0)+b>>0]^a[(c[f+4>>2]|0)+b>>0])&255|d;b=b+1|0}while((b|0)!=(e|0));b=((d+511|0)>>>8&1)+-1|0}l=g;return b|0}function Rc(a,b,c){a=a|0;b=b|0;c=c|0;var e=0,f=0,g=0,h=0,i=0;e=0;while(1){if(e>>>0<32){f=0;g=0}else break;do{h=e;e=e+1|0;g=(d[c+h>>0]|0)<<f|g;f=f+8|0}while(e>>>0<32&f>>>0<24);i=a;a=bd(a,b,g,f)|0;h=(a|0)==0;b=(h?0:i-a|0)+b|0;if(h){a=0;break}}return a|0}function Sc(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0;do if(!((b+-1|0)>>>0>63|g>>>0>64)){if(b>>>0>=256)ba(33636,33656,18,33709);if(g>>>0<256){hc(a,c,f,b&255,d,e,g&255);h=0;break}else ba(33736,33656,19,33709)}else h=-1;while(0);return h|0}function Tc(b,d){b=b|0;d=d|0;var e=0,f=0,g=0,h=0;h=l;f=l=l+63&-64;l=l+16|0;g=0;e=0;while(1){if(_f(f,a[d>>0]|0)|0){e=3;break}d=d+1|0;g=c[f>>2]<<e|g;e=e+6|0;if(e>>>0>=30){e=5;break}}if((e|0)==3){c[b>>2]=0;d=0}else if((e|0)==5)c[b>>2]=g;l=h;return d|0}function Uc(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0;Ef(c,a+((d<<5)+-16<<2)|0);if(d<<1|0){e=0;do{g=e<<4;$e(c,a+(g<<2)|0);Ca(c);f=e<<3;Ef(b+(f<<2)|0,c);$e(c,a+((g|16)<<2)|0);Ca(c);Ef(b+(f+(d<<4)<<2)|0,c);e=e+2|0}while(e>>>0<d<<1>>>0)}return}function Vc(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+160|0;de(c,d,32,0)|0;a[c>>0]=a[c>>0]&-8;a[c+31>>0]=a[c+31>>0]&63|64;ab(f,c);Ic(b,f);Ed(c|0,d|0,32)|0;Ed(c+32|0,b|0,32)|0;l=e;return 0}function Wc(b,c,d){b=b|0;c=c|0;d=d|0;var e=0,f=0,g=0,h=0;g=l;h=l=l+63&-64;l=l+64|0;de(h,d,32,0)|0;d=c;e=h;f=d+32|0;do{a[d>>0]=a[e>>0]|0;d=d+1|0;e=e+1|0}while((d|0)<(f|0));Sd(h,64);h=Yg(b,c)|0;l=g;return h|0}function Xc(b,c,d,e,f,g){b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(e>>>0<0|(e|0)==0&d>>>0<32)b=-1;else{If(b,c,d,e,f,g)|0;c=fg(d|0,e|0,-32,-1)|0;Zf(b+16|0,b+32|0,c,z,b)|0;c=b+16|0;do{a[b>>0]=0;b=b+1|0}while((b|0)<(c|0));b=0}return b|0}function Yc(b,c){b=b|0;c=c|0;var d=0,e=0,f=0;e=l;f=l=l+63&-64;l=l+64|0;de(f,c,32,0)|0;a[f>>0]=a[f>>0]&-8;a[f+31>>0]=a[f+31>>0]&63|64;c=f;d=b+32|0;do{a[b>>0]=a[c>>0]|0;b=b+1|0;c=c+1|0}while((b|0)<(d|0));Sd(f,64);l=e;return 0}function Zc(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0;h=l;g=l=l+63&-64;l=l+32|0;if(d>>>0<0|(d|0)==0&c>>>0<48)a=-1;else{c=fg(c|0,d|0,-32,-1)|0;d=z;wd(g,b,e);a=Pd(a,b+32|0,c,d,g,b,f)|0}l=h;return a|0}function _c(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+16|0;c[f>>2]=c[b+((d&3)<<2)>>2];c[f+4>>2]=c[b+((d>>>2&3)<<2)>>2];c[f+8>>2]=c[b+((d>>>4&3)<<2)>>2];c[f+12>>2]=c[b+((d>>>6&3)<<2)>>2];Ce(a,f);l=e;return}function $c(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;h=l;i=l=l+63&-64;l=l+80|0;if(!((c|0)==0&(d|0)==0)){jg(i+64|0,f);Fc(i,g);oe(i,e,i+64|0);va(i,b,a,c,d);Sd(i,64)}l=h;return 0}function ad(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;f=l;e=l=l+63&-64;l=l+80|0;if(!((a|0)==0|(b|0)==0)){d=ic(a,c[a+8>>2]|0)|0;if(!d){Na(e,b,c[a+28>>2]|0);Sd(e+64|0,8);gc(e,a);Sd(e,72);d=0}}else d=-25;l=f;return d|0}function bd(b,c,d,e){b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;a:do if(e){f=0;while(1){if(!c){b=0;break a}g=b+1|0;a[b>>0]=a[34193+(d&63)>>0]|0;f=f+6|0;if(f>>>0>=e>>>0){b=g;break}else{d=d>>>6;c=c+-1|0;b=g}}}while(0);return b|0}function cd(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;e=fg(c[a+64>>2]|0,c[a+64+4>>2]|0,b|0,d|0)|0;f=z;c[a+64>>2]=e;c[a+64+4>>2]=f;d=fg((f>>>0<d>>>0|(f|0)==(d|0)&e>>>0<b>>>0)&1|0,0,c[a+72>>2]|0,c[a+72+4>>2]|0)|0;c[a+72>>2]=d;c[a+72+4>>2]=z;return}function dd(a,b,c,d,e,f,g,h,i,j){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;var k=0,m=0;k=l;m=l=l+63&-64;l=l+16|0;Ih(m);j=_a(m,a,b,c,d,e,f,g,h,i,j)|0;Jh(m);l=k;return j|0}function ed(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;i=l;h=l=l+63&-64;l=l+32|0;if(!(Cd(h,f,g)|0)){a=Lf(a,b,c,d,e,h)|0;Sd(h,32)}else a=-1;l=i;return a|0}function fd(b,c){b=b|0;c=c|0;var d=0,e=0,f=0,g=0;f=l;g=l=l+63&-64;l=l+16|0;e=10;while(1){d=e+-1|0;a[g+d>>0]=(c>>>0)%10|0|48;if(c>>>0>9&(d|0)!=0){e=d;c=(c>>>0)/10|0}else break}e=11-e|0;fb(b|0,g+d|0,e|0)|0;a[b+e>>0]=0;l=f;return}function gd(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;var h=0,i=0;i=l;h=l=l+63&-64;l=l+32|0;if(!(Cd(h,f,g)|0)){a=Uf(a,b,c,d,e,h)|0;Sd(h,32)}else a=-1;l=i;return a|0}function hd(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;i=l;j=l=l+63&-64;l=l+32|0;Ga(j,e,h,0)|0;h=ef(a,b,c,d,e+16|0,f,g,j)|0;Sd(j,32);l=i;return h|0}function id(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+64|0;if(!((b|0)==0&(c|0)==0)){Fc(g,e);oe(g,d,0);Pb(a|0,0,b|0)|0;va(g,a,a,b,c);Sd(g,64)}l=f;return 0}function jd(a){a=a|0;var b=0,d=0;d=a+15&-16|0;b=c[i>>2]|0;a=b+d|0;if((d|0)>0&(a|0)<(b|0)|(a|0)<0){W()|0;_(12);return -1}c[i>>2]=a;if((a|0)>(V()|0)?(U()|0)==0:0){_(12);c[i>>2]=b;return -1}return b|0}function kd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+64|0;if(!((b|0)==0&(c|0)==0)){Fc(g,e);$d(g,d,0);Pb(a|0,0,b|0)|0;va(g,a,a,b,c);Sd(g,64)}l=f;return 0}function ld(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0,j=0;i=l;j=l=l+63&-64;l=l+32|0;Da(j,e,h,0)|0;h=jf(a,b,c,d,e+16|0,f,g,j)|0;l=i;return h|0}function md(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0;i=l;l=l+32|0;if(!(Jg(i,g,h)|0)){a=mf(a,b,c,d,e,f,i)|0;Sd(i,32)}else a=-1;l=i;return a|0}function nd(b){b=b|0;var c=0,d=0,e=0,f=0,g=0;d=32;c=1;e=0;while(1){d=d+-1|0;f=a[b+d>>0]|0;g=a[34308+d>>0]|0;c=c&255;e=((f&255)-(g&255)|0)>>>8&c|e&255;if(!d)break;else c=(((g^f)&255)+65535|0)>>>8&c}return ((e|0)==0)<<31>>31|0}function od(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;e=l;d=l=l+63&-64;l=l+16|0;f=sf(d,b)|0;c[8326]=f;if(!f)d=c[d>>2]|0;else{c[d>>2]=0;d=0}c[a>>2]=d;c[a+4>>2]=d;c[a+8>>2]=d|0?b:0;l=e;return d|0}function pd(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;var i=0;i=l;l=l+32|0;if(!(Jg(i,g,h)|0)){qf(a,b,c,d,e,f,i)|0;Sd(i,32);a=0}else a=-1;l=i;return a|0}function qd(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+80|0;Gb(e+40|0,c,b);Fb(e,c,b);Fa(e,e);la(a,e+40|0,e);l=d;return}function rd(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=Mc(a,b+16|0,b,d,z,e,f,g)|0}return a|0}function sd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=Je(a,b+16|0,b,d,z,e,f)|0}return a|0}function td(a){a=a|0;c[a+32>>2]=0;c[a+32+4>>2]=0;c[a>>2]=c[8238];c[a+4>>2]=c[8239];c[a+8>>2]=c[8240];c[a+12>>2]=c[8241];c[a+16>>2]=c[8242];c[a+20>>2]=c[8243];c[a+24>>2]=c[8244];c[a+28>>2]=c[8245];return 0}function ud(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0;ff(a);d=0;do{g=Te(b+(d<<3)|0)|0;e=a+(d<<3)|0;f=c[e+4>>2]^z;c[e>>2]=c[e>>2]^g;c[e+4>>2]=f;d=d+1|0}while((d|0)!=8);return}function vd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=Ya(a,b+16|0,b,d,z,e,f)|0}return a|0}function wd(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+384|0;Dg(e,0,0,24)|0;rg(e,b,32,0)|0;rg(e,c,32,0)|0;Tg(e,a,24)|0;l=d;return}function xd(b){b=b|0;var c=0,d=0,e=0;d=0;while(1){c=0;e=0;do{e=(a[16+(d<<5)+c>>0]^a[b+c>>0])&255|e;c=c+1|0}while((c|0)!=32);d=d+1|0;if(!e){c=1;break}if(d>>>0>=12){c=0;break}}return c|0}function yd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;var g=0,h=0;g=l;h=l=l+63&-64;l=l+1408|0;da(h,f)|0;ea(a,b,c,d,e,h)|0;l=g;return 0}function zd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+32|0;Ga(g,d,e,0)|0;e=xg(a,b,c,d+16|0,g)|0;Sd(g,32);l=f;return e|0}function Ad(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;e=l;d=l=l+63&-64;l=l+32|0;if(!(Od(d,c,b)|0)){Da(a,35976,d,0)|0;a=0}else a=-1;l=e;return a|0}function Bd(a,b,d,e,f,g,h,i,j,k,l){a=a|0;b=b|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;i=i|0;j=j|0;k=k|0;l=l|0;if((l|0)==1)a=ec(a,b,d,e,f,g,h,i,j,k,1)|0;else{c[8326]=22;a=-1}return a|0}function Cd(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;e=l;d=l=l+63&-64;l=l+32|0;if(!(Od(d,c,b)|0)){Ga(a,35912,d,0)|0;a=0}else a=-1;l=e;return a|0}function Dd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+32|0;je(f,b,c,d,e)|0;e=Ne(a,f)|0;e=((f|0)==(a|0)?-1:e)|(Qc(f,a,32)|0);l=f;return e|0}function Ed(b,c,d){b=b|0;c=c|0;d=d|0;var e=0;if((c|0)<(b|0)&(b|0)<(c+d|0)){e=b;c=c+d|0;b=b+d|0;while((d|0)>0){b=b-1|0;c=c-1|0;d=d-1|0;a[b>>0]=a[c>>0]|0}b=e}else fb(b,c,d)|0;return b|0}function Fd(a,b){a=a|0;b=b|0;var c=0,d=0,e=0;c=O(b&65535,a&65535)|0;e=(c>>>16)+(O(b&65535,a>>>16)|0)|0;d=O(b>>>16,a&65535)|0;return (z=(e>>>16)+(O(b>>>16,a>>>16)|0)+(((e&65535)+d|0)>>>16)|0,e+d<<16|c&65535|0)|0}function Gd(a,b){a=a|0;b=b|0;var d=0;d=c[a+4>>2]^c[b+4>>2];c[a>>2]=c[a>>2]^c[b>>2];c[a+4>>2]=d;d=c[a+8+4>>2]^c[b+8+4>>2];c[a+8>>2]=c[a+8>>2]^c[b+8>>2];c[a+8+4>>2]=d;return}function Hd(a,b){a=a|0;b=b|0;var d=0;d=c[a+4>>2]&c[b+4>>2];c[a>>2]=c[a>>2]&c[b>>2];c[a+4>>2]=d;d=c[a+8+4>>2]&c[b+8+4>>2];c[a+8>>2]=c[a+8>>2]&c[b+8>>2];c[a+8+4>>2]=d;return}function Id(a,b){a=a|0;b=b|0;la(a,b,b+120|0);la(a+40|0,b+40|0,b+80|0);la(a+80|0,b+80|0,b+120|0);la(a+120|0,b,b+40|0);return}function Jd(a,b){a=a|0;b=b|0;var d=0;d=c[a+4>>2]|c[b+4>>2];c[a>>2]=c[a>>2]|c[b>>2];c[a+4>>2]=d;d=c[a+8+4>>2]|c[b+8+4>>2];c[a+8>>2]=c[a+8>>2]|c[b+8>>2];c[a+8+4>>2]=d;return}function Kd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+64|0;ie(f,b,c,d,e)|0;e=Me(a,f)|0;e=((f|0)==(a|0)?-1:e)|(Qc(f,a,64)|0);l=f;return e|0}function Ld(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+32|0;ge(f,b,c,d,e)|0;e=Ne(a,f)|0;e=((f|0)==(a|0)?-1:e)|(Qc(f,a,32)|0);l=f;return e|0}function Md(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else a=Oc(a+16|0,a,b,c,d,e,f,g)|0;return a|0}function Nd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else{Qe(a+16|0,a,b,c,d,e,f)|0;a=0}return a|0}function Od(a,b,c){a=a|0;b=b|0;c=c|0;if(!(Ka(a,b,c)|0)){b=0;c=0;do{c=d[a+b>>0]|0|c;b=b+1|0}while((b|0)!=32);b=0-((c+511|0)>>>8&1)|0}else b=-1;return b|0}function Pd(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=md(a,b+16|0,b,d,z,e,f,g)|0}return a|0}function Qd(a){a=a|0;var b=0,c=0,e=0,f=0;c=d[a>>0]|0;e=vf(d[a+1>>0]|0|0,0,8)|0;f=z;b=vf(d[a+2>>0]|0|0,0,16)|0;f=f|z;a=vf(d[a+3>>0]|0|0,0,24)|0;z=f|z;return e|c|b|a|0}function Rd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+16|0;he(g,b,c,d,e)|0;e=Oe(a,g)|0;l=f;return e|0}function Sd(b,d){b=b|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+16|0;c[f>>2]=b;if(d|0){b=0;do{a[(c[f>>2]|0)+b>>0]=0;b=b+1|0}while((b|0)!=(d|0))}l=e;return}function Td(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=mf(a,b+16|0,b,d,z,e,f)|0}return a|0}function Ud(a,b){a=a|0;b=b|0;var d=0,e=0,f=0,g=0;d=0;do{g=b+(d<<3)|0;e=a+(d<<3)|0;f=c[e+4>>2]^c[g+4>>2];c[e>>2]=c[e>>2]^c[g>>2];c[e+4>>2]=f;d=d+1|0}while((d|0)!=128);return}function Vd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+32|0;Da(g,d,e,0)|0;e=Cg(a,b,c,d+16|0,g)|0;l=f;return e|0}function Wd(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0<0|(d|0)==0&c>>>0<16)a=-1;else{d=fg(c|0,d|0,-16,-1)|0;a=$a(a,b+16|0,b,d,z,e,f)|0}return a|0}function Xd(a,b){a=a|0;b=b|0;Gb(a,b+40|0,b);Fb(a+40|0,b+40|0,b);qc(a+80|0,b+80|0);la(a+120|0,b+120|0,1232);return}function Yd(b){b=b|0;var c=0;c=a[n+(b&255)>>0]|0;if((c|0)<8)return c|0;c=a[n+(b>>8&255)>>0]|0;if((c|0)<8)return c+8|0;c=a[n+(b>>16&255)>>0]|0;if((c|0)<8)return c+16|0;return (a[n+(b>>>24)>>0]|0)+24|0}function Zd(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+1408|0;da(g,e)|0;fa(a,b,c,d,g)|0;l=f;return 0}function _d(a,b){a=a|0;b=b|0;var c=0;c=Te(a)|0;c=yf(c|0,z|0,b|0)|0;re(a,c,z);c=Te(a+8|0)|0;b=yf(c|0,z|0,b|0)|0;re(a+8|0,b,z);return}function $d(a,b,d){a=a|0;b=b|0;d=d|0;if(!d){c[a+48>>2]=0;d=0}else{c[a+48>>2]=Rg(d)|0;d=Rg(d+4|0)|0}c[a+52>>2]=d;c[a+56>>2]=Rg(b)|0;c[a+60>>2]=Rg(b+4|0)|0;return}function ae(a,b){a=a|0;b=b|0;var c=0;c=Te(a)|0;c=vf(c|0,z|0,b|0)|0;re(a,c,z);c=Te(a+8|0)|0;b=vf(c|0,z|0,b|0)|0;re(a+8|0,b,z);return}function be(b,c){b=b|0;c=c|0;var d=0,e=0;e=l;l=l+64|0;pe(b,e)|0;b=e;d=c+32|0;do{a[c>>0]=a[b>>0]|0;c=c+1|0;b=b+1|0}while((c|0)<(d|0));l=e;return 0}function ce(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;f=fg(c|0,d|0,a|0,b|0)|0;e=z;d=vf(a|0,b|0,1)|0;d=af(d&-2|0,z&1|0,c|0,0)|0;d=fg(f|0,e|0,d|0,z|0)|0;return d|0}function de(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+208|0;me(f)|0;Ea(f,b,c,d)|0;Be(f,a)|0;l=e;return 0}function ee(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+112|0;td(f)|0;La(f,b,c,d)|0;Fe(f,a)|0;l=e;return 0}function fe(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else{Qa(a+16|0,a,b,c,d,e,f)|0;a=0}return a|0}function ge(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+208|0;qb(f,e,32)|0;wg(f,b,c,d)|0;qe(f,a)|0;l=f;return 0}function he(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0,g=0;f=l;g=l=l+63&-64;l=l+96|0;bc(g,e);Ma(g,b,c,d);Ua(g,a);l=f;return 0}function ie(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+416|0;pb(f,e,32)|0;zg(f,b,c,d)|0;pe(f,a)|0;l=f;return 0}function je(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;var f=0;f=l;l=l+416|0;Pg(f,e,32)|0;Gg(f,b,c,d)|0;be(f,a)|0;l=f;return 0}function ke(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;e=l;f=l=l+63&-64;l=l+64|0;Be(a,f)|0;tb(b,c,f,64,0,d,1);l=e;return 0}function le(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=l;e=l=l+63&-64;l=l+64|0;Be(a,e)|0;c=vb(b,e,64,0,c,1)|0;l=d;return c|0}function me(a){a=a|0;var b=0,d=0;c[a+64>>2]=0;c[a+64+4>>2]=0;c[a+64+8>>2]=0;c[a+64+12>>2]=0;b=400;d=a+64|0;do{c[a>>2]=c[b>>2];a=a+4|0;b=b+4|0}while((a|0)<(d|0));return 0}function ne(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;if(d>>>3|0){e=0;do{f=b+(e<<3)|0;Lc(a+(e<<3)|0,c[f>>2]|0,c[f+4>>2]|0);e=e+1|0}while((e|0)!=(d>>>3|0))}return}function oe(a,b,d){a=a|0;b=b|0;d=d|0;if(!d)d=0;else d=Rg(d)|0;c[a+48>>2]=d;c[a+52>>2]=Rg(b)|0;c[a+56>>2]=Rg(b+4|0)|0;c[a+60>>2]=Rg(b+8|0)|0;return}function pe(a,b){a=a|0;b=b|0;var c=0;c=l;l=l+64|0;Be(a,c)|0;Ea(a+208|0,c,64,0)|0;Be(a+208|0,b)|0;Sd(c,64);l=c;return 0}function qe(a,b){a=a|0;b=b|0;var c=0;c=l;l=l+32|0;Fe(a,c)|0;La(a+104|0,c,32,0)|0;Fe(a+104|0,b)|0;Sd(c,32);l=c;return 0}function re(b,c,d){b=b|0;c=c|0;d=d|0;a[b>>0]=c;a[b+1>>0]=c>>8;a[b+2>>0]=c>>16;a[b+3>>0]=c>>24;a[b+4>>0]=d;a[b+4+1>>0]=d>>8;a[b+4+2>>0]=d>>16;a[b+4+3>>0]=d>>24;return}function se(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else a=pd(a+16|0,a,b,c,d,e,f,g)|0;return a|0}function te(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else{qf(a+16|0,a,b,c,d,e,f)|0;a=0}return a|0}function ue(a){a=a|0;jg(a,(Rg(a)|0)>>>8);jg(a+4|0,(Rg(a+4|0)|0)>>>8);jg(a+8|0,(Rg(a+8|0)|0)>>>8);jg(a+12|0,(Rg(a+12|0)|0)>>>8);return}function ve(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;if(d>>>0>0|(d|0)==0&c>>>0>4294967279)a=-1;else{Ta(a+16|0,a,b,c,d,e,f)|0;a=0}return a|0}function we(a,b,d){a=a|0;b=b|0;d=d|0;var e=0,f=0;if(d>>>2|0){e=0;do{f=a+(e<<2)|0;c[f>>2]=c[f>>2]^c[b+(e<<2)>>2];e=e+1|0}while((e|0)!=(d>>>2|0))}return}function xe(a){a=a|0;return (0-(a^62)|0)>>>8&43^43|(a+65510|0)>>>8&255&a+65|(0-(a^63)|0)>>>8&47^47|(a+65484|0)>>>8&a+71&((a+65510|0)>>>8&255^255)|(a+65474|0)>>>8&a+252&((a+65484|0)>>>8&255^255)|0}function ye(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+128|0;Ue(d,b);jc(a,d);l=c;return}function ze(a,b){a=a|0;b=b|0;la(a,b,b+120|0);la(a+40|0,b+40|0,b+80|0);la(a+80|0,b+80|0,b+120|0);return}function Ae(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+32|0;gf(d,32);Vc(a,b,d)|0;Sd(d,32);l=c;return 0}function Be(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+704|0;pc(a,d);ne(b,a,64);Sd(d,704);Sd(a,208);l=c;return 0}function Ce(a,b){a=a|0;b=b|0;var d=0;d=c[b+4>>2]|0;c[a>>2]=c[b>>2];c[a+4>>2]=d;d=c[b+8+4>>2]|0;c[a+8>>2]=c[b+8>>2];c[a+8+4>>2]=d;return}function De(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;d=0;do{f=zc(b+(d<<3)|0)|0;e=a+(d<<3)|0;c[e>>2]=f;c[e+4>>2]=z;d=d+1|0}while((d|0)!=16);return}function Ee(a,b){a=a|0;b=b|0;var d=0,e=0,f=0;d=0;do{f=Te(b+(d<<3)|0)|0;e=a+(d<<3)|0;c[e>>2]=f;c[e+4>>2]=z;d=d+1|0}while((d|0)!=128);return}function Fe(a,b){a=a|0;b=b|0;var c=0,d=0;c=l;d=l=l+63&-64;l=l+288|0;ac(a,d);uf(b,a);Sd(d,288);Sd(a,104);l=c;return 0}function Ge(a){a=a|0;var b=0,c=0;b=l;c=l=l+63&-64;l=l+32|0;Ja(c,a);a=Ne(c,35928)|0;l=b;return a|0}function He(a,b,d,e){a=a|0;b=b|0;d=d|0;e=e|0;if(e>>>0>0|(e|0)==0&d>>>0>4294967295){c[8326]=27;a=-1}else a=((qh(a,b,d)|0)!=0)<<31>>31;return a|0}function Ie(a){a=a|0;var b=0;if(a>>>0<2)a=0;else{do b=Mh()|0;while(b>>>0<(((0-a|0)>>>0)%(a>>>0)|0)>>>0);a=(b>>>0)%(a>>>0)|0}return a|0}function Je(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return Ya(a,b,c,d,e,f,g)|0}function Ke(a,b,c){a=a|0;b=b|0;c=c|0;sb(a,b,c&255);sb(a+40|0,b+40|0,c&255);sb(a+80|0,b+80|0,c&255);return}function Le(a){a=a|0;var b=0;b=~c[a+4>>2];c[a>>2]=~c[a>>2];c[a+4>>2]=b;b=~c[a+8+4>>2];c[a+8>>2]=~c[a+8>>2];c[a+8+4>>2]=b;return}function Me(b,c){b=b|0;c=c|0;var d=0,e=0;d=0;e=0;do{d=(a[c+e>>0]^a[b+e>>0])&255|d;e=e+1|0}while((e|0)!=64);return ((d+511|0)>>>8&1)+-1|0}function Ne(b,c){b=b|0;c=c|0;var d=0,e=0;d=0;e=0;do{d=(a[c+e>>0]^a[b+e>>0])&255|d;e=e+1|0}while((e|0)!=32);return ((d+511|0)>>>8&1)+-1|0}function Oe(b,c){b=b|0;c=c|0;var d=0,e=0;d=0;e=0;do{d=(a[c+e>>0]^a[b+e>>0])&255|d;e=e+1|0}while((e|0)!=16);return ((d+511|0)>>>8&1)+-1|0}function Pe(a,b,d,e){a=a|0;b=b|0;d=d|0;e=e|0;var f=0;f=l;l=l+16|0;za(a,b,d,e,f|0)|0;l=f;return (z=c[f+4>>2]|0,c[f>>2]|0)|0}function Qe(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;Qa(a,b,c,d,e,f,g)|0;return 0}function Re(a,b,d){a=a|0;b=b|0;d=d|0;var e=0;if(d>>>2|0){e=0;do{c[a+(e<<2)>>2]=c[b+(e<<2)>>2];e=e+1|0}while((e|0)!=(d>>>2|0))}return}function Se(a,b){a=a|0;b=b|0;var d=0,e=0;d=0;do{e=b+(d<<3)|0;re(a+(d<<3)|0,c[e>>2]|0,c[e+4>>2]|0);d=d+1|0}while((d|0)!=128);return}function Te(a){a=a|0;z=d[a+4>>0]|d[a+4+1>>0]<<8|d[a+4+2>>0]<<16|d[a+4+3>>0]<<24;return d[a>>0]|d[a+1>>0]<<8|d[a+2>>0]<<16|d[a+3>>0]<<24|0}function Ue(a,b){a=a|0;b=b|0;qc(a,b);qc(a+40|0,b+40|0);qc(a+80|0,b+80|0);return}function Ve(b){b=b|0;var c=0,d=0;d=l;c=l=l+63&-64;l=l+32|0;Ja(c,b);l=d;return a[c>>0]&1|0}function We(){}function Xe(a,b,c){a=a|0;b=b|0;c=c|0;if((c|0)<32){z=b>>c;return a>>>c|(b&(1<<c)-1)<<32-c}z=(b|0)<0?-1:0;return b>>c-32|0}function Ye(a){a=a|0;lg(a);Bf(a+40|0);Bf(a+80|0);lg(a+120|0);return}function Ze(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=yf(a|0,b|0,c|0)|0;e=z;c=vf(a|0,b|0,64-c|0)|0;z=z|e;return c|d|0}function _e(a,b,c){a=a|0;b=b|0;c=c|0;var d=0,e=0;d=vf(a|0,b|0,c|0)|0;e=z;c=yf(a|0,b|0,64-c|0)|0;z=z|e;return c|d|0}function $e(a,b){a=a|0;b=b|0;var d=0,e=0;d=0;do{e=a+(d<<2)|0;c[e>>2]=c[e>>2]^c[b+(d<<2)>>2];d=d+1|0}while((d|0)!=16);return}function af(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;var e=0,f=0;e=Fd(a,c)|0;f=z;return (z=(O(b,c)|0)+(O(d,a)|0)+f|f&0,e|0|0)|0}function bf(b){b=b|0;a[b>>0]=0;a[b+1>>0]=0;a[b+2>>0]=0;a[b+3>>0]=0;a[b+4>>0]=0;a[b+4+1>>0]=0;a[b+4+2>>0]=0;a[b+4+3>>0]=0;return}function cf(a,b,c){a=a|0;b=b|0;c=c|0;if(c>>>0<256)return Db(a,b,c&255)|0;else ba(33636,33656,102,33875);return 0}function df(a,b,c){a=a|0;b=b|0;c=c|0;var d=0;b=vf(b&255|0,0,8)|0;d=z;c=vf(c&255|0,0,16)|0;z=d|z;return b|a&255|c|0}function ef(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;return Pa(a,b,c,d,e,f,g,h)|0}function ff(a){a=a|0;var b=0,d=0;Pb(a+64|0,0,320)|0;b=400;d=a+64|0;do{c[a>>2]=c[b>>2];a=a+4|0;b=b+4|0}while((a|0)<(d|0));return}function gf(b,c){b=b|0;c=c|0;var d=0;if(c|0){d=0;do{a[b+d>>0]=Mh()|0;d=d+1|0}while((d|0)!=(c|0))}return}function hf(b,c){b=b|0;c=c|0;var d=0;d=c;do{if(!d){c=0;break}d=d+-1|0;c=b+d|0}while((a[c>>0]|0)!=36);return c|0}function jf(a,b,c,d,e,f,g,h){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;h=h|0;return Pc(a,b,c,d,e,f,g,h)|0}function kf(b,c){b=b|0;c=c|0;var d=0;d=b+48|0;b=d+16|0;do{a[d>>0]=a[c>>0]|0;d=d+1|0;c=c+1|0}while((d|0)<(b|0));return}function lf(b,c){b=b|0;c=c|0;var d=0;d=b+32|0;b=d+16|0;do{a[d>>0]=a[c>>0]|0;d=d+1|0;c=c+1|0}while((d|0)<(b|0));return}function mf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return $a(a,b,c,d,e,f,g)|0}function nf(){var a=0,b=0;a=l;b=l=l+63&-64;l=l+16|0;Xg(b);if(c[b>>2]|0)Xg(b);l=a;return}function of(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return ed(a,b,c,d,e,f,g)|0}function pf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return $c(a,b,c,d,e,f,g)|0}function qf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;Ta(a,b,c,d,e,f,g)|0;return 0}function rf(){var a=0;a=Y(30)|0;if((a|0)>0)c[8833]=a;else a=c[8833]|0;if(a>>>0<16)Z();else{gf(35960,16);return}}function sf(a,b){a=a|0;b=b|0;var d=0;if(b>>>0<=4294967168?(d=ob(b)|0,(d|0)!=0):0){c[a>>2]=d;a=0}else a=12;return a|0}function tf(a,b){a=a|0;b=b|0;var d=0;d=0;do{c[a+(d<<2)>>2]=ug(b+(d<<2)|0)|0;d=d+1|0}while((d|0)!=16);return}function uf(a,b){a=a|0;b=b|0;var d=0;d=0;do{gg(a+(d<<2)|0,c[b+(d<<2)>>2]|0);d=d+1|0}while((d|0)!=8);return}function vf(a,b,c){a=a|0;b=b|0;c=c|0;if((c|0)<32){z=b<<c|(a&(1<<c)-1<<32-c)>>>32-c;return a<<c}z=a<<c-32;return 0}function wf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return gd(a,b,c,d,e,f,g)|0}function xf(){var a=0;if(!(c[8832]|0)){zh();Oh();rf();c[8832]=1;a=0}else a=1;return a|0}function yf(a,b,c){a=a|0;b=b|0;c=c|0;if((c|0)<32){z=b>>>c;return a>>>c|(b&(1<<c)-1)<<32-c}z=0;return b>>>c-32|0}function zf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return Sc(a,b,c,d,e,f,g)|0}function Af(a,b,c){a=a|0;b=b|0;c=c|0;if(c>>>0<1|(c|0)==1&b>>>0<0){gf(a,b);return}else ba(35141,35161,200,35187)}function Bf(a){a=a|0;var b=0;c[a>>2]=1;a=a+4|0;b=a+36|0;do{c[a>>2]=0;a=a+4|0}while((a|0)<(b|0));return}function Cf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return _b(a,b,c,d,e,f,g)|0}function Df(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return ld(a,b,c,d,e,0,0,f)|0}function Ef(a,b){a=a|0;b=b|0;var d=0;d=0;do{c[a+(d<<2)>>2]=c[b+(d<<2)>>2];d=d+1|0}while((d|0)!=16);return}function Ff(a){a=a|0;Bf(a);Bf(a+40|0);lg(a+80|0);return}function Gf(a,b){a=a|0;b=b|0;var d=0;d=c[a>>2]|0;if((b|0)!=0&(d|0)!=0)Sd(c[d+4>>2]|0,c[a+8>>2]<<10);return}function Hf(a,b,c,d,e,f,g){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;g=g|0;return ub(a,b,1,c,d,e,16,f,g,0,0)|0}function If(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return hd(a,b,c,d,e,0,0,f)|0}function Jf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;tb(a,b,c,d,e,f,0);return 0}function Kf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Ib(a,b,c,d,e,f)|0}function Lf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return rc(a,b,c,d,e,f)|0}function Mf(a){a=a|0;lg(a);Bf(a+40|0);Bf(a+80|0);return}function Nf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return $c(a,b,c,d,e,0,f)|0}function Of(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Pa(a,b,c,d,e,0,0,f)|0}function Pf(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return vb(a,b,c,d,e,0)|0}function Qf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;Jf(a,b,c,d,e,f)|0;return 0}function Rf(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Rd(a,b,c,d,e)|0}function Sf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return ub(a,b,1,c,d,e,16,0,32,f,128)|0}function Tf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Pc(a,b,c,d,e,0,0,f)|0}function Uf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Xc(a,b,c,d,e,f)|0}function Vf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Lf(a,b,c,d,e,f)|0}function Wf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return If(a,b,c,d,e,f)|0}function Xf(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Pf(a,b,c,d,e)|0}function Yf(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return mc(a,b,c,d,e,f)|0}function Zf(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return he(a,b,c,d,e)|0}function _f(a,b){a=a|0;b=b|0;b=mb(34193,b&255,65)|0;c[a>>2]=(b|0)==0?0:b-34193|0;return ((b|0)==0)<<31>>31|0}function $f(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Rf(a,b,c,d,e)|0}function ag(a,b){a=a|0;b=b|0;me(a)|0;if(b|0)Ea(a,34340,34,0)|0;return}function bg(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return Uf(a,b,c,d,e,f)|0}function cg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;d=b-d-(c>>>0>a>>>0|0)>>>0;return (z=d,a-c>>>0|0)|0}function dg(a,b,c,d,e,f){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;f=f|0;return kc(a,b,c,d,e,f)|0}function eg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return Bg(a,b,c,d)|0}function fg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return (z=b+d+(a+c>>>0>>>0<a>>>0|0)>>>0,a+c>>>0|0)|0}function gg(b,c){b=b|0;c=c|0;a[b+3>>0]=c;a[b+2>>0]=c>>>8;a[b+1>>0]=c>>>16;a[b>>0]=c>>>24;return}function hg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Dd(a,b,c,d,e)|0}function ig(b){b=b|0;if(a[b+356>>0]|0)rh(b);c[b+80>>2]=-1;c[b+80+4>>2]=-1;return}function jg(b,c){b=b|0;c=c|0;a[b>>0]=c;a[b+1>>0]=c>>8;a[b+2>>0]=c>>16;a[b+3>>0]=c>>24;return}function kg(a,b,c){a=a|0;b=b|0;c=c|0;zf(b,32,c,32,0,0,0)|0;return ih(a,b)|0}function lg(a){a=a|0;var b=0;b=a+40|0;do{c[a>>2]=0;a=a+4|0}while((a|0)<(b|0));return}function mg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;ua(a,b,c,d,e)|0;return 0}function ng(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return Zf(a,b,c,d,e)|0}function og(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Bb(a,b,c,d);return 0}function pg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return id(a,b,c,d,e)|0}function qg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;ke(a,b,c,d)|0;return 0}function rg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;og(a,b,c,d)|0;return 0}function sg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;je(a,b,c,d,e)|0;return 0}function tg(a,b){a=a|0;b=b|0;gf(b,32);return Yg(a,b)|0}function ug(a){a=a|0;return (d[a+2>>0]|0)<<8|(d[a+3>>0]|0)|(d[a+1>>0]|0)<<16|(d[a>>0]|0)<<24|0}function vg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return eg(a,b,c,d)|0}function wg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;La(a,b,c,d)|0;return 0}function xg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return eb(a,b,c,d,e)|0}function yg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return zd(a,b,c,d,e)|0}function zg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Ea(a,b,c,d)|0;return 0}function Ag(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return He(a,b,c,d)|0}function Bg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Ma(a,b,c,d);return 0}function Cg(a,b,c,d,e){a=a|0;b=b|0;c=c|0;d=d|0;e=e|0;return kd(a,b,c,d,e)|0}function Dg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return Gc(a,b,c,d)|0}function Eg(a,b){a=a|0;b=b|0;jg(a+12|0,(Rg(a+12|0)|0)+b|0);return}function Fg(a,b,c){a=a|0;b=b|0;c=c|0;return Wc(a,b,c)|0}function Gg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;zg(a,b,c,d)|0;return 0}function Hg(a,b,c){a=a|0;b=b|0;c=c|0;pg(a,b,0,35129,c)|0;return}function Ig(a,b){a=a|0;b=b|0;z=c[a+-64+(b<<7)+4>>2]|0;return c[a+-64+(b<<7)>>2]|0}function Jg(a,b,c){a=a|0;b=b|0;c=c|0;return Cd(a,b,c)|0}function Kg(b,c){b=b|0;c=c|0;b=Hb(b,c)|0;return ((a[b>>0]|0)==(c&255)<<24>>24?b:0)|0}function Lg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Aa(a,b,c,d,12);return 0}function Mg(a){a=a|0;a=yf(a<<24>>24|0,((a<<24>>24|0)<0)<<31>>31|0,63)|0;return a&255|0}function Ng(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Aa(a,b,c,d,8);return 0}function Og(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;Aa(a,b,c,d,20);return 0}function Pg(a,b,c){a=a|0;b=b|0;c=c|0;pb(a,b,c)|0;return 0}function Qg(a,b,c){a=a|0;b=b|0;c=c|0;Vc(a,b,c)|0;return 0}function Rg(a){a=a|0;return d[a>>0]|d[a+1>>0]<<8|d[a+2>>0]<<16|d[a+3>>0]<<24|0}function Sg(a,b,c){a=a|0;b=b|0;c=c|0;return le(a,b,c)|0}function Tg(a,b,c){a=a|0;b=b|0;c=c|0;return cf(a,b,c)|0}function Ug(a){a=a|0;var b=0;b=l;l=l+a|0;l=l+15&-16;return b|0}function Vg(b){b=b|0;a[b>>0]=0;a[b+1>>0]=0;a[b+2>>0]=0;a[b+3>>0]=0;return}function Wg(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;de(a,b,c,d)|0;return 0}function Xg(a){a=a|0;c[a>>2]=0;c[a+4>>2]=0;c[a+8>>2]=0;c[a+12>>2]=0;return}function Yg(a,b){a=a|0;b=b|0;return yc(a,b)|0}function Zg(a,b){a=a|0;b=b|0;return kh(a,b)|0}function _g(a,b){a=a|0;b=b|0;return oh(a,b)|0}function $g(a){a=a|0;var b=0;b=c[a>>2]|0;if(b|0)ra(b);mh(a);return}function ah(a,b,c,d){a=a|0;b=b|0;c=c|0;d=d|0;return za(a,b,c,d,0)|0}function bh(a,b,c){a=a|0;b=b|0;c=c|0;return Od(a,b,c)|0}function ch(a,b){a=a|0;b=b|0;gf(b,32);return ih(a,b)|0}function dh(a){a=a|0;jg(a+12|0,~(Rg(a+12|0)|0));return}function eh(a,b){a=a|0;b=b|0;return tg(a,b)|0}function fh(a){a=a|0;var b=0;b=c[a>>2]|0;if(b|0)ra(b);ra(a);return}function gh(a,b){a=a|0;b=b|0;return Zg(a,b)|0}function hh(a,b){a=a|0;b=b|0;Ed(a|0,b+32|0,32)|0;return 0}function ih(a,b){a=a|0;b=b|0;return Yg(a,b)|0}function jh(a,b){a=a|0;b=b|0;return _g(a,b)|0}function kh(a,b){a=a|0;b=b|0;Ua(a,b);return 0}function lh(a,b){a=a|0;b=b|0;if(!o){o=a;p=b}}function mh(a){a=a|0;c[a+4>>2]=0;c[a>>2]=0;c[a+8>>2]=0;return}function nh(a,b){a=a|0;b=b|0;Ed(a|0,b|0,32)|0;return 0}function oh(a,b){a=a|0;b=b|0;bc(a,b);return 0}function ph(a,b){a=a|0;b=b|0;Ae(a,b)|0;return 0}function qh(a,b,c){a=a|0;b=b|0;c=c|0;return ib(a,b,c)|0}function rh(a){a=a|0;c[a+88>>2]=-1;c[a+88+4>>2]=-1;return}function sh(a,b){a=a|0;b=b|0;return ((a|0)!=0|(b|0)!=0)&1|0}function th(a,b){a=a|0;b=b|0;return (((b^a)&255)+-1|0)>>>31&255|0}function uh(a,b){a=a|0;b=b|0;fb(a|0,b|0,1024)|0;return}function vh(a){a=a|0;me(a)|0;return 0}function wh(a,b){a=a|0;b=b|0;l=a;m=b}function xh(a,b){a=a|0;b=b|0;return a>>>(32-b|0)|a<<b|0}function yh(a){a=a|0;vh(a)|0;return 0}function zh(){nf();return}function Ah(a,b){a=a|0;b=b|0;return a<<32-b|a>>>b|0}function Bh(a){a=a|0;return hf(a,(uc(a)|0)+1|0)|0}function Ch(a){a=a|0;gf(a,16);return}function Dh(){return 1073741824}function Eh(a){a=a|0;Pb(a|0,0,1024)|0;return}function Fh(){return 524288}function Gh(a){a=a|0;gf(a,32);return}function Hh(){return 16777216}function Ih(a){a=a|0;mh(a);return}function Jh(a){a=a|0;$g(a);return}function Kh(){return 32768}function Lh(){return 34258}function Mh(){return X(0)|0}function Nh(){return 102}function Oh(){aa(1);return}function Ph(){return 33554432}function Qh(){return 1408}function Rh(){return 536870912}function Sh(){return 12}function Th(){return 134217728}function Uh(){return -2147483648}function Vh(){return 34383}function Wh(){return 416}function Xh(a){a=a|0;l=a}function Yh(){return 34129}function Zh(a){a=a|0;z=a}function _h(){return 34262}function $h(){return 6}function ai(){return 256}function bi(){return 104}function ci(){return 384}function di(){return 35336}function ei(){return 34290}function fi(){return 34273}function gi(){return 8192}function hi(){return 4}function ii(){return 9}function ji(){return 34374}function ki(){return 34175}function li(){return 34185}function mi(){return 3}function ni(){return 35199}function oi(){return 34300}function pi(){return 1}function qi(){return 33908}function ri(){return 33484}function si(){return 208}function ti(){return 128}function ui(){return -1}function vi(){return 34107}function wi(){return 33498}function xi(){return 34115}function yi(){return 8}function zi(){return 24}function Ai(){return z|0}function Bi(){return 48}function Ci(){return 16}function Di(){return l|0}function Ei(){return 64}function Fi(){return 32}function Gi(){return 0} -var _hyphenPattern = /-(.)/g; +// EMSCRIPTEN_END_FUNCS +return{_crypto_onetimeauth_poly1305_init:_g,_crypto_hash_sha512_init:me,_crypto_pwhash_scryptsalsa208sha256:Ub,_crypto_scalarmult_primitive:_h,_crypto_scalarmult_base:ih,_crypto_auth_bytes:Fi,_crypto_stream_chacha20_keybytes:Fi,_crypto_aead_chacha20poly1305_decrypt_detached:zb,_crypto_kdf_blake2b_bytes_min:Ci,_crypto_box_curve25519xchacha20poly1305_open_easy_afternm:sd,_crypto_generichash_blake2b_keybytes_max:Ei,_crypto_box_beforenmbytes:Fi,_crypto_stream_salsa208:db,___udivmoddi4:za,_crypto_sign_ed25519_sk_to_curve25519:Yc,_crypto_stream_chacha20_ietf_xor_ic:pf,_crypto_secretbox_xsalsa20poly1305_open:rc,_crypto_box_zerobytes:Fi,_crypto_secretbox_xchacha20poly1305_open_detached:Ya,_crypto_stream_salsa208_keybytes:Fi,_crypto_hash_sha512_bytes:Ei,stackSave:Di,_crypto_stream_xsalsa20_xor_ic:hd,_crypto_core_hsalsa20_keybytes:Fi,_crypto_sign_primitive:oi,_crypto_scalarmult_curve25519_bytes:Fi,_crypto_scalarmult_curve25519_scalarbytes:Fi,_crypto_pwhash_scryptsalsa208sha256_saltbytes:Fi,_crypto_pwhash_argon2i_str_verify:He,_crypto_box_curve25519xchacha20poly1305_secretkeybytes:Fi,_crypto_auth_hmacsha512_keygen:Gh,_crypto_box_detached_afternm:qf,_crypto_stream_salsa20_xor_ic:ef,_crypto_auth_hmacsha256_init:qb,_crypto_stream_chacha20_ietf_xor:Nf,_crypto_auth_hmacsha512256_final:be,_crypto_stream_aes128ctr_xor_afternm:ea,setThrew:lh,_crypto_aead_chacha20poly1305_ietf_nsecbytes:Gi,_crypto_kdf_blake2b_derive_from_key:Ib,_crypto_box_curve25519xsalsa20poly1305_keypair:tg,_crypto_hash_sha256_init:td,_crypto_stream_xsalsa20_noncebytes:zi,_crypto_generichash_keybytes_max:Ei,_crypto_verify_64:Me,stackAlloc:Ug,_crypto_box_curve25519xchacha20poly1305_keypair:tg,_crypto_box_curve25519xsalsa20poly1305_open:ed,_crypto_pwhash_memlimit_sensitive:Rh,_crypto_box_boxzerobytes:Ci,_crypto_kdf_blake2b_keybytes:Fi,_crypto_hash_sha512_update:Ea,_crypto_core_hchacha20:Da,_crypto_pwhash_bytes_min:Ci,_crypto_secretbox_open:Lf,_crypto_auth_hmacsha256_final:qe,_crypto_verify_16:Oe,_crypto_stream_aes128ctr_xor:yd,_crypto_pwhash_scryptsalsa208sha256_memlimit_max:ui,_crypto_pwhash_scryptsalsa208sha256_ll:dd,_crypto_stream_salsa208_xor:Sa,_crypto_secretbox_xsalsa20poly1305_keygen:Gh,_crypto_aead_chacha20poly1305_abytes:Ci,_crypto_pwhash_argon2i_bytes_max:ui,_crypto_box_curve25519xchacha20poly1305_easy_afternm:Nd,_crypto_onetimeauth_poly1305_update:eg,_crypto_pwhash_memlimit_max:Uh,_crypto_verify_64_bytes:Ei,_crypto_onetimeauth_poly1305_keygen:Gh,_crypto_generichash_blake2b_keygen:Gh,_crypto_pwhash_argon2i_strprefix:ki,_crypto_auth_hmacsha256_update:wg,_crypto_aead_xchacha20poly1305_ietf_encrypt:Jc,_crypto_pwhash_scryptsalsa208sha256_strbytes:Nh,_crypto_stream_xsalsa20_keybytes:Fi,_crypto_generichash_keygen:Gh,_crypto_pwhash_argon2i_str:_b,_crypto_box_sealbytes:Bi,_crypto_onetimeauth:ng,_crypto_secretbox_boxzerobytes:Ci,_crypto_aead_chacha20poly1305_ietf_keygen:Gh,_crypto_stream_chacha20:Cg,_crypto_box_open_afternm:Vf,_crypto_pwhash_opslimit_moderate:$h,_crypto_box_macbytes:Ci,_crypto_shorthash_bytes:yi,_crypto_generichash_primitive:vi,_crypto_sign_ed25519_keypair:Ae,_crypto_sign_ed25519ph_statebytes:si,_crypto_aead_xchacha20poly1305_ietf_keybytes:Fi,_crypto_auth_primitive:ri,_crypto_core_salsa2012_keybytes:Fi,_malloc:ia,_crypto_stream_noncebytes:zi,_crypto_secretbox_xchacha20poly1305_keybytes:Fi,_crypto_secretbox_xsalsa20poly1305_keybytes:Fi,_crypto_pwhash_saltbytes:Ci,_crypto_secretbox_noncebytes:zi,_crypto_secretbox_xsalsa20poly1305_macbytes:Ci,_crypto_pwhash_argon2i_opslimit_max:ui,_crypto_auth_hmacsha512_bytes:Ei,_crypto_generichash_keybytes:Fi,_crypto_sign_publickeybytes:Fi,_crypto_pwhash_argon2i_memlimit_moderate:Th,_crypto_generichash_blake2b:Sc,_crypto_core_hchacha20_keybytes:Fi,___uremdi3:Pe,_crypto_pwhash_argon2i_opslimit_moderate:$h,_randombytes_implementation_name:Vh,_crypto_stream_xchacha20_noncebytes:zi,_crypto_sign_ed25519_verify_detached:Pf,_crypto_hash_sha512_statebytes:si,_crypto_secretbox_zerobytes:Fi,_crypto_verify_32_bytes:Fi,stackRestore:Xh,_crypto_kdf_keygen:Gh,_crypto_stream_xsalsa20_xor:If,_crypto_stream_chacha20_ietf_keygen:Gh,_crypto_stream_chacha20_keygen:Gh,_crypto_box_easy:se,_crypto_hash_sha256:ee,_crypto_sign_ed25519_seedbytes:Fi,_crypto_pwhash_alg_argon2i13:pi,_crypto_shorthash_siphash24_bytes:yi,_crypto_pwhash_opslimit_min:mi,_crypto_box_curve25519xsalsa20poly1305_publickeybytes:Fi,_crypto_kdf_blake2b_bytes_max:Ei,_crypto_generichash_bytes_max:Ei,_crypto_stream_chacha20_ietf_noncebytes:Sh,_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive:Dh,_crypto_box_curve25519xchacha20poly1305_open_easy:rd,_crypto_box_beforenm:Jg,_crypto_box_curve25519xsalsa20poly1305_afternm:Uf,_crypto_sign_statebytes:si,_crypto_sign_open:Yf,_crypto_box_seed_keypair:Fg,_crypto_auth_hmacsha512_init:pb,_crypto_sign_ed25519_sk_to_pk:hh,_crypto_scalarmult_curve25519:Od,_crypto_box_open_easy:Pd,_crypto_auth_hmacsha512:ie,_crypto_stream_keygen:Gh,_crypto_stream_aes128ctr_keybytes:Ci,_crypto_auth_hmacsha512256_keybytes:Fi,_crypto_aead_chacha20poly1305_keybytes:Fi,_free:ra,_crypto_kx_client_session_keys:Ob,_crypto_box_curve25519xchacha20poly1305_seedbytes:Fi,_crypto_onetimeauth_poly1305_keybytes:Fi,_crypto_sign_ed25519_secretkeybytes:Ei,_crypto_kdf_blake2b_contextbytes:yi,_crypto_stream_salsa2012:cb,_crypto_sign_seedbytes:Fi,_crypto_box_curve25519xchacha20poly1305_beforenmbytes:Fi,_randombytes_random:Mh,_crypto_sign_ed25519ph_update:zg,_crypto_auth_hmacsha256_keygen:Gh,_crypto_auth_hmacsha256_statebytes:si,_randombytes_buf_deterministic:Hg,_crypto_aead_chacha20poly1305_encrypt_detached:Kb,_crypto_stream_xsalsa20_keygen:Gh,_crypto_hash_primitive:qi,_crypto_sign_ed25519_pk_to_curve25519:lc,_crypto_shorthash_siphash24:ua,_crypto_box_curve25519xsalsa20poly1305_macbytes:Ci,_crypto_sign_ed25519_bytes:Ei,_crypto_sign_ed25519:kc,_crypto_core_salsa20_constbytes:Ci,_crypto_secretbox_primitive:fi,_crypto_pwhash_argon2i_opslimit_interactive:hi,_crypto_pwhash_argon2i_saltbytes:Ci,_crypto_box_curve25519xchacha20poly1305_open_detached_afternm:Je,_crypto_box_curve25519xsalsa20poly1305_beforenmbytes:Fi,_crypto_stream_xchacha20_keygen:Gh,_crypto_core_hchacha20_constbytes:Ci,_crypto_stream_xchacha20_xor:Df,_randombytes_seedbytes:Fi,_crypto_sign_final_create:qg,_crypto_kx_secretkeybytes:Fi,_crypto_box_detached:pd,_randombytes_buf:gf,_crypto_generichash_blake2b_saltbytes:Ci,_crypto_box_open_detached:md,_crypto_kx_seedbytes:Fi,_crypto_secretbox_xsalsa20poly1305_zerobytes:Fi,_crypto_box_curve25519xchacha20poly1305_open_detached:Mc,_crypto_generichash_blake2b_keybytes:Fi,_crypto_box_curve25519xchacha20poly1305_easy:Md,_crypto_pwhash_argon2i_bytes_min:Ci,_crypto_pwhash_scryptsalsa208sha256_str:Lb,_crypto_hash:Wg,_i64Subtract:cg,_crypto_box_seedbytes:Fi,_crypto_generichash_blake2b_bytes_min:Ci,_crypto_box_curve25519xsalsa20poly1305:gd,_crypto_generichash_blake2b_statebytes:ci,_crypto_sign_ed25519ph_final_create:ke,_crypto_aead_chacha20poly1305_ietf_decrypt_detached:lb,_crypto_generichash_final:Tg,_crypto_auth_hmacsha512_update:zg,_crypto_auth_hmacsha256:ge,_crypto_box_keypair:eh,_crypto_hash_sha256_bytes:Fi,___udivdi3:ah,_crypto_pwhash_argon2i_passwd_max:ui,_sodium_init:xf,_crypto_secretbox_macbytes:Ci,_crypto_aead_xchacha20poly1305_ietf_npubbytes:zi,_bitshift64Shl:vf,_crypto_pwhash_argon2i_opslimit_min:mi,setTempRet0:Zh,_crypto_sign_seed_keypair:Qg,_crypto_core_hchacha20_inputbytes:Ci,___muldi3:af,_crypto_core_salsa2012_constbytes:Ci,_crypto_kx_seed_keypair:kg,_crypto_box_curve25519xchacha20poly1305_detached_afternm:Qe,_crypto_aead_chacha20poly1305_nsecbytes:Gi,_sodium_library_minimal:Gi,_crypto_aead_xchacha20poly1305_ietf_nsecbytes:Gi,_crypto_pwhash_argon2i_strbytes:ti,_crypto_pwhash_argon2i_memlimit_max:Uh,_crypto_generichash_blake2b_salt_personal:Ec,_crypto_stream_aes128ctr_beforenmbytes:Qh,_crypto_kdf_derive_from_key:Kf,_crypto_secretbox_xsalsa20poly1305_noncebytes:zi,_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive:Fh,_crypto_pwhash_argon2i_memlimit_interactive:Ph,_crypto_hash_sha256_final:Fe,_crypto_stream_keybytes:Fi,_crypto_pwhash_memlimit_min:gi,_crypto_aead_chacha20poly1305_ietf_npubbytes:Sh,_crypto_stream_salsa208_noncebytes:yi,_sodium_library_version_minor:hi,_crypto_onetimeauth_bytes:Ci,_crypto_box_open:of,_crypto_secretbox_xchacha20poly1305_open_easy:vd,_crypto_scalarmult_curve25519_base:Yg,_crypto_sign_ed25519_open:mc,_crypto_stream_chacha20_ietf_keybytes:Fi,_crypto_box_noncebytes:zi,_crypto_core_hchacha20_outputbytes:Fi,_crypto_stream_salsa2012_xor:Ra,_crypto_onetimeauth_keygen:Gh,_crypto_pwhash_strbytes:ti,_crypto_auth_hmacsha512256_update:Gg,_crypto_core_salsa208_outputbytes:Ei,_crypto_onetimeauth_poly1305:Zf,_crypto_secretbox_xchacha20poly1305_macbytes:Ci,_crypto_kdf_bytes_min:Ci,_crypto_sign_ed25519_sk_to_seed:nh,_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive:Hh,_crypto_stream_xsalsa20:zd,_crypto_box_open_easy_afternm:Td,_crypto_box_curve25519xsalsa20poly1305_seedbytes:Fi,_crypto_stream_salsa20_keybytes:Fi,_crypto_kdf_primitive:vi,_crypto_sign_ed25519ph_final_verify:le,_crypto_sign_ed25519_publickeybytes:Fi,_crypto_stream_aes128ctr:Zd,_crypto_shorthash:mg,_crypto_auth_keybytes:Fi,_crypto_box_curve25519xsalsa20poly1305_open_afternm:Lf,_crypto_aead_chacha20poly1305_npubbytes:yi,_crypto_aead_xchacha20poly1305_ietf_abytes:Ci,_crypto_onetimeauth_poly1305_final:Zg,_crypto_onetimeauth_poly1305_bytes:Ci,_crypto_box_curve25519xsalsa20poly1305_seed_keypair:Wc,_crypto_box_primitive:wi,_crypto_pwhash_str:Cf,_crypto_auth_hmacsha512_keybytes:Fi,_crypto_auth:sg,_crypto_pwhash_scryptsalsa208sha256_bytes_min:Ci,_crypto_core_salsa20_keybytes:Fi,_crypto_box_afternm:bg,_crypto_core_salsa208_constbytes:Ci,_crypto_onetimeauth_primitive:Yh,_crypto_pwhash_scryptsalsa208sha256_str_verify:vc,_sodium_version_string:ni,_crypto_stream_xchacha20_xor_ic:ld,_crypto_pwhash_scryptsalsa208sha256_passwd_min:Gi,_crypto_stream_chacha20_ietf:pg,_crypto_generichash:zf,_crypto_core_hsalsa20_outputbytes:Fi,_crypto_pwhash_opslimit_interactive:hi,_crypto_stream_aes128ctr_beforenm:da,getTempRet0:Ai,_crypto_box_curve25519xsalsa20poly1305_noncebytes:zi,_crypto_stream_salsa2012_noncebytes:yi,_crypto_core_salsa208_keybytes:Fi,_crypto_aead_chacha20poly1305_ietf_decrypt:Bc,_crypto_auth_hmacsha512256_init:Pg,_crypto_kx_server_session_keys:Nb,_crypto_onetimeauth_poly1305_verify:Rf,_crypto_auth_hmacsha512_final:pe,_crypto_stream_aes128ctr_noncebytes:Ci,_crypto_box_secretkeybytes:Fi,_crypto_stream_salsa2012_keygen:Gh,_crypto_onetimeauth_update:vg,_crypto_core_salsa20:Og,_crypto_pwhash_memlimit_interactive:Ph,_crypto_scalarmult_bytes:Fi,_crypto_secretbox_detached:Ta,_crypto_stream_xor:Wf,_crypto_secretbox_xchacha20poly1305_easy:fe,_crypto_secretbox_easy:ve,_crypto_aead_xchacha20poly1305_ietf_decrypt_detached:Zb,_crypto_stream_salsa20:xg,_sodium_bin2hex:Dc,_crypto_auth_hmacsha512_statebytes:Wh,_crypto_pwhash_argon2i_opslimit_sensitive:yi,_crypto_generichash_blake2b_bytes_max:Ei,_crypto_hash_sha256_update:La,_crypto_core_hsalsa20_constbytes:Ci,_crypto_box_easy_afternm:te,_crypto_auth_hmacsha512256_verify:Dd,_crypto_pwhash_memlimit_moderate:Th,_crypto_core_salsa20_inputbytes:Ci,_crypto_box_publickeybytes:Fi,_crypto_sign_secretkeybytes:Ei,___muldsi3:Fd,_crypto_scalarmult_scalarbytes:Fi,_crypto_verify_32:Ne,_crypto_kx_sessionkeybytes:Fi,_crypto_aead_chacha20poly1305_decrypt:Cc,_crypto_sign:dg,_crypto_pwhash_passwd_max:ui,_crypto_pwhash_scryptsalsa208sha256_opslimit_min:Kh,_sodium_hex2bin:kb,_crypto_pwhash_argon2i_alg_argon2i13:pi,_crypto_secretbox_keybytes:Fi,_randombytes:Af,_crypto_hash_bytes:Ei,_crypto_stream_salsa20_keygen:Gh,_crypto_hash_sha256_statebytes:bi,_crypto_pwhash_argon2i_passwd_min:Gi,_crypto_pwhash_opslimit_sensitive:yi,_crypto_sign_init:yh,_crypto_generichash_blake2b_personalbytes:Ci,_crypto_stream_chacha20_xor_ic:jf,_crypto_sign_verify_detached:Xf,_crypto_onetimeauth_verify:$f,_crypto_sign_ed25519_detached:Jf,_crypto_generichash_init:Dg,_i64Add:fg,_crypto_sign_bytes:Ei,_crypto_generichash_update:rg,_crypto_scalarmult:bh,_crypto_aead_chacha20poly1305_ietf_abytes:Ci,_crypto_sign_detached:Qf,_crypto_generichash_blake2b_update:og,_crypto_box_curve25519xsalsa20poly1305_beforenm:Cd,_crypto_generichash_blake2b_bytes:Fi,_crypto_auth_hmacsha512256_bytes:Fi,_crypto_box_curve25519xchacha20poly1305_noncebytes:zi,_randombytes_uniform:Ie,_crypto_shorthash_siphash24_keybytes:Ci,_crypto_shorthash_keygen:Ch,_crypto_onetimeauth_init:jh,_crypto_generichash_bytes:Fi,_crypto_stream_salsa20_xor:Of,_crypto_auth_hmacsha512_verify:Kd,_crypto_generichash_blake2b_keybytes_min:Ci,_bitshift64Lshr:yf,_crypto_kx_publickeybytes:Fi,_crypto_pwhash_bytes_max:ui,_crypto_aead_chacha20poly1305_ietf_keybytes:Fi,_crypto_aead_chacha20poly1305_ietf_encrypt_detached:yb,_crypto_stream:yg,_sbrk:jd,_crypto_box_curve25519xchacha20poly1305_beforenm:Ad,_memcpy:fb,_crypto_pwhash:Bd,_crypto_auth_hmacsha512256:je,_crypto_secretbox_xsalsa20poly1305:Xc,_crypto_verify_16_bytes:Ci,_crypto_stream_salsa208_keygen:Gh,_emscripten_get_global_libc:di,_crypto_shorthash_siphashx24_bytes:Ci,_crypto_generichash_blake2b_final:cf,_crypto_generichash_blake2b_init_salt_personal:xc,_crypto_box_seal:wc,_crypto_aead_xchacha20poly1305_ietf_keygen:Gh,_crypto_kx_keypair:ch,runPostSets:We,_crypto_pwhash_alg_default:pi,_crypto_box:wf,_crypto_stream_primitive:ji,_crypto_secretbox_xsalsa20poly1305_boxzerobytes:Ci,_crypto_pwhash_str_verify:Ag,_crypto_generichash_keybytes_min:Ci,_crypto_generichash_statebytes:ci,_crypto_onetimeauth_poly1305_statebytes:ai,_crypto_sign_final_verify:Sg,_crypto_pwhash_strprefix:ki,_crypto_secretbox_keygen:Gh,_crypto_secretbox_xchacha20poly1305_noncebytes:zi,_crypto_hash_sha512:de,_llvm_cttz_i32:Yd,_crypto_pwhash_scryptsalsa208sha256_bytes_max:ui,_crypto_box_curve25519xchacha20poly1305_detached:Oc,_sodium_library_version_major:ii,_crypto_aead_chacha20poly1305_ietf_encrypt:Kc,_crypto_generichash_blake2b_init:Gc,_randombytes_close:Gi,_crypto_pwhash_primitive:li,_crypto_onetimeauth_keybytes:Fi,_crypto_pwhash_argon2i:ec,_crypto_stream_aes128ctr_afternm:fa,_crypto_kdf_keybytes:Fi,establishStackSpace:wh,_crypto_aead_chacha20poly1305_encrypt:Nc,_crypto_core_salsa2012_inputbytes:Ci,_crypto_pwhash_scryptsalsa208sha256_memlimit_min:Hh,_crypto_core_salsa208:Ng,_crypto_pwhash_opslimit_max:ui,_crypto_auth_verify:hg,_crypto_sign_ed25519_seed_keypair:Vc,_crypto_auth_hmacsha512256_keygen:Gh,_randombytes_stir:Oh,_memset:Pb,_crypto_box_open_detached_afternm:mf,_crypto_pwhash_argon2i_memlimit_sensitive:Rh,_crypto_kx_primitive:xi,_crypto_stream_salsa2012_keybytes:Fi,_crypto_aead_xchacha20poly1305_ietf_decrypt:Ac,_crypto_pwhash_scryptsalsa208sha256_strprefix:Lh,_crypto_core_salsa20_outputbytes:Ei,_crypto_auth_keygen:Gh,_crypto_secretbox:Uf,_crypto_aead_xchacha20poly1305_ietf_encrypt_detached:Xb,_crypto_pwhash_scryptsalsa208sha256_passwd_max:ui,_crypto_auth_hmacsha256_bytes:Fi,_crypto_auth_hmacsha256_verify:Ld,_crypto_sign_keypair:ph,_crypto_stream_xchacha20:Vd,_crypto_onetimeauth_statebytes:ai,_crypto_sign_ed25519ph_init:vh,_crypto_stream_salsa20_noncebytes:yi,_crypto_shorthash_keybytes:Ci,_crypto_aead_chacha20poly1305_keygen:Gh,_crypto_shorthash_siphashx24:ta,_memmove:Ed,_crypto_hash_sha512_final:Be,_crypto_box_curve25519xsalsa20poly1305_zerobytes:Fi,_crypto_shorthash_siphashx24_keybytes:Ci,_crypto_pwhash_passwd_min:Gi,_crypto_kdf_bytes_max:Ei,_crypto_box_curve25519xsalsa20poly1305_boxzerobytes:Ci,_crypto_generichash_bytes_min:Ci,_crypto_core_salsa2012_outputbytes:Ei,_crypto_auth_hmacsha256_keybytes:Fi,_crypto_core_salsa208_inputbytes:Ci,_crypto_pwhash_scryptsalsa208sha256_opslimit_max:ui,_crypto_sign_update:Gg,_crypto_secretbox_xchacha20poly1305_detached:Qa,_crypto_stream_chacha20_noncebytes:yi,_crypto_secretbox_open_detached:$a,_crypto_box_curve25519xchacha20poly1305_seed_keypair:Wc,_crypto_pwhash_argon2i_memlimit_min:gi,_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive:Ph,_crypto_box_curve25519xsalsa20poly1305_secretkeybytes:Fi,_crypto_kdf_contextbytes:yi,_crypto_stream_xchacha20_keybytes:Fi,_crypto_box_seal_open:Zc,_crypto_shorthash_primitive:ei,_crypto_core_hsalsa20_inputbytes:Ci,_crypto_onetimeauth_final:gh,_crypto_secretbox_open_easy:Wd,_crypto_core_salsa2012:Lg,_crypto_box_curve25519xchacha20poly1305_macbytes:Ci,_crypto_auth_hmacsha512256_statebytes:Wh,_bitshift64Ashr:Xe,_crypto_box_curve25519xchacha20poly1305_publickeybytes:Fi,_crypto_stream_chacha20_xor:Tf,_crypto_core_hsalsa20:Ga,stackAlloc:Ug,stackSave:Di,stackRestore:Xh,establishStackSpace:wh,setThrew:lh,setTempRet0:Zh,getTempRet0:Ai}}) -/** - * Camelcases a hyphenated string, for example: - * - * > camelize('background-color') - * < "backgroundColor" - * - * @param {string} string - * @return {string} - */ -function camelize(string) { - return string.replace(_hyphenPattern, function (_, character) { - return character.toUpperCase(); - }); -} -module.exports = camelize; +// EMSCRIPTEN_END_ASM +(Module.asmGlobalArg,Module.asmLibraryArg,buffer);var _crypto_onetimeauth_poly1305_init=Module["_crypto_onetimeauth_poly1305_init"]=asm["_crypto_onetimeauth_poly1305_init"];var _crypto_hash_sha512_init=Module["_crypto_hash_sha512_init"]=asm["_crypto_hash_sha512_init"];var _crypto_pwhash_scryptsalsa208sha256=Module["_crypto_pwhash_scryptsalsa208sha256"]=asm["_crypto_pwhash_scryptsalsa208sha256"];var _crypto_scalarmult_primitive=Module["_crypto_scalarmult_primitive"]=asm["_crypto_scalarmult_primitive"];var _crypto_scalarmult_base=Module["_crypto_scalarmult_base"]=asm["_crypto_scalarmult_base"];var _crypto_auth_bytes=Module["_crypto_auth_bytes"]=asm["_crypto_auth_bytes"];var _crypto_stream_chacha20_keybytes=Module["_crypto_stream_chacha20_keybytes"]=asm["_crypto_stream_chacha20_keybytes"];var _crypto_aead_chacha20poly1305_decrypt_detached=Module["_crypto_aead_chacha20poly1305_decrypt_detached"]=asm["_crypto_aead_chacha20poly1305_decrypt_detached"];var _crypto_kdf_blake2b_bytes_min=Module["_crypto_kdf_blake2b_bytes_min"]=asm["_crypto_kdf_blake2b_bytes_min"];var _crypto_box_curve25519xchacha20poly1305_open_easy_afternm=Module["_crypto_box_curve25519xchacha20poly1305_open_easy_afternm"]=asm["_crypto_box_curve25519xchacha20poly1305_open_easy_afternm"];var _crypto_generichash_blake2b_keybytes_max=Module["_crypto_generichash_blake2b_keybytes_max"]=asm["_crypto_generichash_blake2b_keybytes_max"];var _crypto_box_beforenmbytes=Module["_crypto_box_beforenmbytes"]=asm["_crypto_box_beforenmbytes"];var _crypto_stream_salsa208=Module["_crypto_stream_salsa208"]=asm["_crypto_stream_salsa208"];var ___udivmoddi4=Module["___udivmoddi4"]=asm["___udivmoddi4"];var _crypto_sign_ed25519_sk_to_curve25519=Module["_crypto_sign_ed25519_sk_to_curve25519"]=asm["_crypto_sign_ed25519_sk_to_curve25519"];var _crypto_stream_chacha20_ietf_xor_ic=Module["_crypto_stream_chacha20_ietf_xor_ic"]=asm["_crypto_stream_chacha20_ietf_xor_ic"];var _crypto_secretbox_xsalsa20poly1305_open=Module["_crypto_secretbox_xsalsa20poly1305_open"]=asm["_crypto_secretbox_xsalsa20poly1305_open"];var _crypto_box_zerobytes=Module["_crypto_box_zerobytes"]=asm["_crypto_box_zerobytes"];var _crypto_secretbox_xchacha20poly1305_open_detached=Module["_crypto_secretbox_xchacha20poly1305_open_detached"]=asm["_crypto_secretbox_xchacha20poly1305_open_detached"];var _crypto_stream_salsa208_keybytes=Module["_crypto_stream_salsa208_keybytes"]=asm["_crypto_stream_salsa208_keybytes"];var _crypto_hash_sha512_bytes=Module["_crypto_hash_sha512_bytes"]=asm["_crypto_hash_sha512_bytes"];var stackSave=Module["stackSave"]=asm["stackSave"];var _crypto_stream_xsalsa20_xor_ic=Module["_crypto_stream_xsalsa20_xor_ic"]=asm["_crypto_stream_xsalsa20_xor_ic"];var _crypto_core_hsalsa20_keybytes=Module["_crypto_core_hsalsa20_keybytes"]=asm["_crypto_core_hsalsa20_keybytes"];var _crypto_sign_primitive=Module["_crypto_sign_primitive"]=asm["_crypto_sign_primitive"];var _crypto_scalarmult_curve25519_bytes=Module["_crypto_scalarmult_curve25519_bytes"]=asm["_crypto_scalarmult_curve25519_bytes"];var _crypto_scalarmult_curve25519_scalarbytes=Module["_crypto_scalarmult_curve25519_scalarbytes"]=asm["_crypto_scalarmult_curve25519_scalarbytes"];var _crypto_pwhash_scryptsalsa208sha256_saltbytes=Module["_crypto_pwhash_scryptsalsa208sha256_saltbytes"]=asm["_crypto_pwhash_scryptsalsa208sha256_saltbytes"];var _crypto_pwhash_argon2i_str_verify=Module["_crypto_pwhash_argon2i_str_verify"]=asm["_crypto_pwhash_argon2i_str_verify"];var _crypto_box_curve25519xchacha20poly1305_secretkeybytes=Module["_crypto_box_curve25519xchacha20poly1305_secretkeybytes"]=asm["_crypto_box_curve25519xchacha20poly1305_secretkeybytes"];var _crypto_auth_hmacsha512_keygen=Module["_crypto_auth_hmacsha512_keygen"]=asm["_crypto_auth_hmacsha512_keygen"];var _crypto_box_detached_afternm=Module["_crypto_box_detached_afternm"]=asm["_crypto_box_detached_afternm"];var _crypto_stream_salsa20_xor_ic=Module["_crypto_stream_salsa20_xor_ic"]=asm["_crypto_stream_salsa20_xor_ic"];var _crypto_auth_hmacsha256_init=Module["_crypto_auth_hmacsha256_init"]=asm["_crypto_auth_hmacsha256_init"];var _crypto_stream_chacha20_ietf_xor=Module["_crypto_stream_chacha20_ietf_xor"]=asm["_crypto_stream_chacha20_ietf_xor"];var _crypto_auth_hmacsha512256_final=Module["_crypto_auth_hmacsha512256_final"]=asm["_crypto_auth_hmacsha512256_final"];var _crypto_stream_aes128ctr_xor_afternm=Module["_crypto_stream_aes128ctr_xor_afternm"]=asm["_crypto_stream_aes128ctr_xor_afternm"];var setThrew=Module["setThrew"]=asm["setThrew"];var _crypto_aead_chacha20poly1305_ietf_nsecbytes=Module["_crypto_aead_chacha20poly1305_ietf_nsecbytes"]=asm["_crypto_aead_chacha20poly1305_ietf_nsecbytes"];var _crypto_kdf_blake2b_derive_from_key=Module["_crypto_kdf_blake2b_derive_from_key"]=asm["_crypto_kdf_blake2b_derive_from_key"];var _crypto_box_curve25519xsalsa20poly1305_keypair=Module["_crypto_box_curve25519xsalsa20poly1305_keypair"]=asm["_crypto_box_curve25519xsalsa20poly1305_keypair"];var _crypto_hash_sha256_init=Module["_crypto_hash_sha256_init"]=asm["_crypto_hash_sha256_init"];var _crypto_stream_xsalsa20_noncebytes=Module["_crypto_stream_xsalsa20_noncebytes"]=asm["_crypto_stream_xsalsa20_noncebytes"];var _crypto_generichash_keybytes_max=Module["_crypto_generichash_keybytes_max"]=asm["_crypto_generichash_keybytes_max"];var _crypto_verify_64=Module["_crypto_verify_64"]=asm["_crypto_verify_64"];var stackAlloc=Module["stackAlloc"]=asm["stackAlloc"];var _crypto_box_curve25519xchacha20poly1305_keypair=Module["_crypto_box_curve25519xchacha20poly1305_keypair"]=asm["_crypto_box_curve25519xchacha20poly1305_keypair"];var _crypto_box_curve25519xsalsa20poly1305_open=Module["_crypto_box_curve25519xsalsa20poly1305_open"]=asm["_crypto_box_curve25519xsalsa20poly1305_open"];var _crypto_pwhash_memlimit_sensitive=Module["_crypto_pwhash_memlimit_sensitive"]=asm["_crypto_pwhash_memlimit_sensitive"];var _crypto_box_boxzerobytes=Module["_crypto_box_boxzerobytes"]=asm["_crypto_box_boxzerobytes"];var _crypto_kdf_blake2b_keybytes=Module["_crypto_kdf_blake2b_keybytes"]=asm["_crypto_kdf_blake2b_keybytes"];var _crypto_hash_sha512_update=Module["_crypto_hash_sha512_update"]=asm["_crypto_hash_sha512_update"];var _crypto_core_hchacha20=Module["_crypto_core_hchacha20"]=asm["_crypto_core_hchacha20"];var _crypto_pwhash_bytes_min=Module["_crypto_pwhash_bytes_min"]=asm["_crypto_pwhash_bytes_min"];var _crypto_secretbox_open=Module["_crypto_secretbox_open"]=asm["_crypto_secretbox_open"];var _crypto_auth_hmacsha256_final=Module["_crypto_auth_hmacsha256_final"]=asm["_crypto_auth_hmacsha256_final"];var _crypto_verify_16=Module["_crypto_verify_16"]=asm["_crypto_verify_16"];var _crypto_stream_aes128ctr_xor=Module["_crypto_stream_aes128ctr_xor"]=asm["_crypto_stream_aes128ctr_xor"];var _crypto_pwhash_scryptsalsa208sha256_memlimit_max=Module["_crypto_pwhash_scryptsalsa208sha256_memlimit_max"]=asm["_crypto_pwhash_scryptsalsa208sha256_memlimit_max"];var _crypto_pwhash_scryptsalsa208sha256_ll=Module["_crypto_pwhash_scryptsalsa208sha256_ll"]=asm["_crypto_pwhash_scryptsalsa208sha256_ll"];var _crypto_stream_salsa208_xor=Module["_crypto_stream_salsa208_xor"]=asm["_crypto_stream_salsa208_xor"];var _crypto_secretbox_xsalsa20poly1305_keygen=Module["_crypto_secretbox_xsalsa20poly1305_keygen"]=asm["_crypto_secretbox_xsalsa20poly1305_keygen"];var _crypto_aead_chacha20poly1305_abytes=Module["_crypto_aead_chacha20poly1305_abytes"]=asm["_crypto_aead_chacha20poly1305_abytes"];var _crypto_pwhash_argon2i_bytes_max=Module["_crypto_pwhash_argon2i_bytes_max"]=asm["_crypto_pwhash_argon2i_bytes_max"];var _crypto_box_curve25519xchacha20poly1305_easy_afternm=Module["_crypto_box_curve25519xchacha20poly1305_easy_afternm"]=asm["_crypto_box_curve25519xchacha20poly1305_easy_afternm"];var _crypto_onetimeauth_poly1305_update=Module["_crypto_onetimeauth_poly1305_update"]=asm["_crypto_onetimeauth_poly1305_update"];var _crypto_pwhash_memlimit_max=Module["_crypto_pwhash_memlimit_max"]=asm["_crypto_pwhash_memlimit_max"];var _crypto_verify_64_bytes=Module["_crypto_verify_64_bytes"]=asm["_crypto_verify_64_bytes"];var _crypto_onetimeauth_poly1305_keygen=Module["_crypto_onetimeauth_poly1305_keygen"]=asm["_crypto_onetimeauth_poly1305_keygen"];var _crypto_generichash_blake2b_keygen=Module["_crypto_generichash_blake2b_keygen"]=asm["_crypto_generichash_blake2b_keygen"];var _crypto_pwhash_argon2i_strprefix=Module["_crypto_pwhash_argon2i_strprefix"]=asm["_crypto_pwhash_argon2i_strprefix"];var _crypto_auth_hmacsha256_update=Module["_crypto_auth_hmacsha256_update"]=asm["_crypto_auth_hmacsha256_update"];var _crypto_aead_xchacha20poly1305_ietf_encrypt=Module["_crypto_aead_xchacha20poly1305_ietf_encrypt"]=asm["_crypto_aead_xchacha20poly1305_ietf_encrypt"];var _crypto_pwhash_scryptsalsa208sha256_strbytes=Module["_crypto_pwhash_scryptsalsa208sha256_strbytes"]=asm["_crypto_pwhash_scryptsalsa208sha256_strbytes"];var _crypto_stream_xsalsa20_keybytes=Module["_crypto_stream_xsalsa20_keybytes"]=asm["_crypto_stream_xsalsa20_keybytes"];var _crypto_generichash_keygen=Module["_crypto_generichash_keygen"]=asm["_crypto_generichash_keygen"];var _crypto_pwhash_argon2i_str=Module["_crypto_pwhash_argon2i_str"]=asm["_crypto_pwhash_argon2i_str"];var _crypto_box_sealbytes=Module["_crypto_box_sealbytes"]=asm["_crypto_box_sealbytes"];var _crypto_onetimeauth=Module["_crypto_onetimeauth"]=asm["_crypto_onetimeauth"];var _crypto_secretbox_boxzerobytes=Module["_crypto_secretbox_boxzerobytes"]=asm["_crypto_secretbox_boxzerobytes"];var _crypto_aead_chacha20poly1305_ietf_keygen=Module["_crypto_aead_chacha20poly1305_ietf_keygen"]=asm["_crypto_aead_chacha20poly1305_ietf_keygen"];var _crypto_stream_chacha20=Module["_crypto_stream_chacha20"]=asm["_crypto_stream_chacha20"];var _crypto_box_open_afternm=Module["_crypto_box_open_afternm"]=asm["_crypto_box_open_afternm"];var _crypto_pwhash_opslimit_moderate=Module["_crypto_pwhash_opslimit_moderate"]=asm["_crypto_pwhash_opslimit_moderate"];var _crypto_box_macbytes=Module["_crypto_box_macbytes"]=asm["_crypto_box_macbytes"];var _crypto_shorthash_bytes=Module["_crypto_shorthash_bytes"]=asm["_crypto_shorthash_bytes"];var _crypto_generichash_primitive=Module["_crypto_generichash_primitive"]=asm["_crypto_generichash_primitive"];var _crypto_sign_ed25519_keypair=Module["_crypto_sign_ed25519_keypair"]=asm["_crypto_sign_ed25519_keypair"];var _crypto_sign_ed25519ph_statebytes=Module["_crypto_sign_ed25519ph_statebytes"]=asm["_crypto_sign_ed25519ph_statebytes"];var _crypto_aead_xchacha20poly1305_ietf_keybytes=Module["_crypto_aead_xchacha20poly1305_ietf_keybytes"]=asm["_crypto_aead_xchacha20poly1305_ietf_keybytes"];var _crypto_auth_primitive=Module["_crypto_auth_primitive"]=asm["_crypto_auth_primitive"];var _crypto_core_salsa2012_keybytes=Module["_crypto_core_salsa2012_keybytes"]=asm["_crypto_core_salsa2012_keybytes"];var _malloc=Module["_malloc"]=asm["_malloc"];var _crypto_stream_noncebytes=Module["_crypto_stream_noncebytes"]=asm["_crypto_stream_noncebytes"];var _crypto_secretbox_xchacha20poly1305_keybytes=Module["_crypto_secretbox_xchacha20poly1305_keybytes"]=asm["_crypto_secretbox_xchacha20poly1305_keybytes"];var _crypto_secretbox_xsalsa20poly1305_keybytes=Module["_crypto_secretbox_xsalsa20poly1305_keybytes"]=asm["_crypto_secretbox_xsalsa20poly1305_keybytes"];var _crypto_pwhash_saltbytes=Module["_crypto_pwhash_saltbytes"]=asm["_crypto_pwhash_saltbytes"];var _crypto_secretbox_noncebytes=Module["_crypto_secretbox_noncebytes"]=asm["_crypto_secretbox_noncebytes"];var _crypto_secretbox_xsalsa20poly1305_macbytes=Module["_crypto_secretbox_xsalsa20poly1305_macbytes"]=asm["_crypto_secretbox_xsalsa20poly1305_macbytes"];var _crypto_pwhash_argon2i_opslimit_max=Module["_crypto_pwhash_argon2i_opslimit_max"]=asm["_crypto_pwhash_argon2i_opslimit_max"];var _crypto_auth_hmacsha512_bytes=Module["_crypto_auth_hmacsha512_bytes"]=asm["_crypto_auth_hmacsha512_bytes"];var _crypto_generichash_keybytes=Module["_crypto_generichash_keybytes"]=asm["_crypto_generichash_keybytes"];var _crypto_sign_publickeybytes=Module["_crypto_sign_publickeybytes"]=asm["_crypto_sign_publickeybytes"];var _crypto_pwhash_argon2i_memlimit_moderate=Module["_crypto_pwhash_argon2i_memlimit_moderate"]=asm["_crypto_pwhash_argon2i_memlimit_moderate"];var _crypto_generichash_blake2b=Module["_crypto_generichash_blake2b"]=asm["_crypto_generichash_blake2b"];var _crypto_core_hchacha20_keybytes=Module["_crypto_core_hchacha20_keybytes"]=asm["_crypto_core_hchacha20_keybytes"];var ___uremdi3=Module["___uremdi3"]=asm["___uremdi3"];var _crypto_pwhash_argon2i_opslimit_moderate=Module["_crypto_pwhash_argon2i_opslimit_moderate"]=asm["_crypto_pwhash_argon2i_opslimit_moderate"];var _randombytes_implementation_name=Module["_randombytes_implementation_name"]=asm["_randombytes_implementation_name"];var _crypto_stream_xchacha20_noncebytes=Module["_crypto_stream_xchacha20_noncebytes"]=asm["_crypto_stream_xchacha20_noncebytes"];var _crypto_sign_ed25519_verify_detached=Module["_crypto_sign_ed25519_verify_detached"]=asm["_crypto_sign_ed25519_verify_detached"];var _crypto_hash_sha512_statebytes=Module["_crypto_hash_sha512_statebytes"]=asm["_crypto_hash_sha512_statebytes"];var _crypto_secretbox_zerobytes=Module["_crypto_secretbox_zerobytes"]=asm["_crypto_secretbox_zerobytes"];var _crypto_verify_32_bytes=Module["_crypto_verify_32_bytes"]=asm["_crypto_verify_32_bytes"];var stackRestore=Module["stackRestore"]=asm["stackRestore"];var _crypto_kdf_keygen=Module["_crypto_kdf_keygen"]=asm["_crypto_kdf_keygen"];var _crypto_stream_xsalsa20_xor=Module["_crypto_stream_xsalsa20_xor"]=asm["_crypto_stream_xsalsa20_xor"];var _crypto_stream_chacha20_ietf_keygen=Module["_crypto_stream_chacha20_ietf_keygen"]=asm["_crypto_stream_chacha20_ietf_keygen"];var _crypto_stream_chacha20_keygen=Module["_crypto_stream_chacha20_keygen"]=asm["_crypto_stream_chacha20_keygen"];var _crypto_box_easy=Module["_crypto_box_easy"]=asm["_crypto_box_easy"];var _crypto_hash_sha256=Module["_crypto_hash_sha256"]=asm["_crypto_hash_sha256"];var _crypto_sign_ed25519_seedbytes=Module["_crypto_sign_ed25519_seedbytes"]=asm["_crypto_sign_ed25519_seedbytes"];var _crypto_pwhash_alg_argon2i13=Module["_crypto_pwhash_alg_argon2i13"]=asm["_crypto_pwhash_alg_argon2i13"];var _crypto_shorthash_siphash24_bytes=Module["_crypto_shorthash_siphash24_bytes"]=asm["_crypto_shorthash_siphash24_bytes"];var _crypto_pwhash_opslimit_min=Module["_crypto_pwhash_opslimit_min"]=asm["_crypto_pwhash_opslimit_min"];var _crypto_box_curve25519xsalsa20poly1305_publickeybytes=Module["_crypto_box_curve25519xsalsa20poly1305_publickeybytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_publickeybytes"];var _crypto_kdf_blake2b_bytes_max=Module["_crypto_kdf_blake2b_bytes_max"]=asm["_crypto_kdf_blake2b_bytes_max"];var _crypto_generichash_bytes_max=Module["_crypto_generichash_bytes_max"]=asm["_crypto_generichash_bytes_max"];var _crypto_stream_chacha20_ietf_noncebytes=Module["_crypto_stream_chacha20_ietf_noncebytes"]=asm["_crypto_stream_chacha20_ietf_noncebytes"];var _crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive=Module["_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive"]=asm["_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive"];var _crypto_box_curve25519xchacha20poly1305_open_easy=Module["_crypto_box_curve25519xchacha20poly1305_open_easy"]=asm["_crypto_box_curve25519xchacha20poly1305_open_easy"];var _crypto_box_beforenm=Module["_crypto_box_beforenm"]=asm["_crypto_box_beforenm"];var _crypto_box_curve25519xsalsa20poly1305_afternm=Module["_crypto_box_curve25519xsalsa20poly1305_afternm"]=asm["_crypto_box_curve25519xsalsa20poly1305_afternm"];var _crypto_sign_statebytes=Module["_crypto_sign_statebytes"]=asm["_crypto_sign_statebytes"];var _crypto_sign_open=Module["_crypto_sign_open"]=asm["_crypto_sign_open"];var _crypto_box_seed_keypair=Module["_crypto_box_seed_keypair"]=asm["_crypto_box_seed_keypair"];var _crypto_auth_hmacsha512_init=Module["_crypto_auth_hmacsha512_init"]=asm["_crypto_auth_hmacsha512_init"];var _crypto_sign_ed25519_sk_to_pk=Module["_crypto_sign_ed25519_sk_to_pk"]=asm["_crypto_sign_ed25519_sk_to_pk"];var _crypto_scalarmult_curve25519=Module["_crypto_scalarmult_curve25519"]=asm["_crypto_scalarmult_curve25519"];var _crypto_box_open_easy=Module["_crypto_box_open_easy"]=asm["_crypto_box_open_easy"];var _crypto_auth_hmacsha512=Module["_crypto_auth_hmacsha512"]=asm["_crypto_auth_hmacsha512"];var _crypto_stream_keygen=Module["_crypto_stream_keygen"]=asm["_crypto_stream_keygen"];var _crypto_stream_aes128ctr_keybytes=Module["_crypto_stream_aes128ctr_keybytes"]=asm["_crypto_stream_aes128ctr_keybytes"];var _crypto_auth_hmacsha512256_keybytes=Module["_crypto_auth_hmacsha512256_keybytes"]=asm["_crypto_auth_hmacsha512256_keybytes"];var _crypto_aead_chacha20poly1305_keybytes=Module["_crypto_aead_chacha20poly1305_keybytes"]=asm["_crypto_aead_chacha20poly1305_keybytes"];var _free=Module["_free"]=asm["_free"];var _crypto_kx_client_session_keys=Module["_crypto_kx_client_session_keys"]=asm["_crypto_kx_client_session_keys"];var _crypto_box_curve25519xchacha20poly1305_seedbytes=Module["_crypto_box_curve25519xchacha20poly1305_seedbytes"]=asm["_crypto_box_curve25519xchacha20poly1305_seedbytes"];var _crypto_onetimeauth_poly1305_keybytes=Module["_crypto_onetimeauth_poly1305_keybytes"]=asm["_crypto_onetimeauth_poly1305_keybytes"];var _crypto_sign_ed25519_secretkeybytes=Module["_crypto_sign_ed25519_secretkeybytes"]=asm["_crypto_sign_ed25519_secretkeybytes"];var _crypto_kdf_blake2b_contextbytes=Module["_crypto_kdf_blake2b_contextbytes"]=asm["_crypto_kdf_blake2b_contextbytes"];var _crypto_stream_salsa2012=Module["_crypto_stream_salsa2012"]=asm["_crypto_stream_salsa2012"];var _crypto_sign_seedbytes=Module["_crypto_sign_seedbytes"]=asm["_crypto_sign_seedbytes"];var _crypto_box_curve25519xchacha20poly1305_beforenmbytes=Module["_crypto_box_curve25519xchacha20poly1305_beforenmbytes"]=asm["_crypto_box_curve25519xchacha20poly1305_beforenmbytes"];var _randombytes_random=Module["_randombytes_random"]=asm["_randombytes_random"];var _crypto_sign_ed25519ph_update=Module["_crypto_sign_ed25519ph_update"]=asm["_crypto_sign_ed25519ph_update"];var _crypto_auth_hmacsha256_keygen=Module["_crypto_auth_hmacsha256_keygen"]=asm["_crypto_auth_hmacsha256_keygen"];var _crypto_auth_hmacsha256_statebytes=Module["_crypto_auth_hmacsha256_statebytes"]=asm["_crypto_auth_hmacsha256_statebytes"];var _randombytes_buf_deterministic=Module["_randombytes_buf_deterministic"]=asm["_randombytes_buf_deterministic"];var _crypto_aead_chacha20poly1305_encrypt_detached=Module["_crypto_aead_chacha20poly1305_encrypt_detached"]=asm["_crypto_aead_chacha20poly1305_encrypt_detached"];var _crypto_stream_xsalsa20_keygen=Module["_crypto_stream_xsalsa20_keygen"]=asm["_crypto_stream_xsalsa20_keygen"];var _crypto_hash_primitive=Module["_crypto_hash_primitive"]=asm["_crypto_hash_primitive"];var _crypto_sign_ed25519_pk_to_curve25519=Module["_crypto_sign_ed25519_pk_to_curve25519"]=asm["_crypto_sign_ed25519_pk_to_curve25519"];var _crypto_shorthash_siphash24=Module["_crypto_shorthash_siphash24"]=asm["_crypto_shorthash_siphash24"];var _crypto_box_curve25519xsalsa20poly1305_macbytes=Module["_crypto_box_curve25519xsalsa20poly1305_macbytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_macbytes"];var _crypto_sign_ed25519_bytes=Module["_crypto_sign_ed25519_bytes"]=asm["_crypto_sign_ed25519_bytes"];var _crypto_sign_ed25519=Module["_crypto_sign_ed25519"]=asm["_crypto_sign_ed25519"];var _crypto_core_salsa20_constbytes=Module["_crypto_core_salsa20_constbytes"]=asm["_crypto_core_salsa20_constbytes"];var _crypto_secretbox_primitive=Module["_crypto_secretbox_primitive"]=asm["_crypto_secretbox_primitive"];var _crypto_pwhash_argon2i_opslimit_interactive=Module["_crypto_pwhash_argon2i_opslimit_interactive"]=asm["_crypto_pwhash_argon2i_opslimit_interactive"];var _crypto_pwhash_argon2i_saltbytes=Module["_crypto_pwhash_argon2i_saltbytes"]=asm["_crypto_pwhash_argon2i_saltbytes"];var _crypto_box_curve25519xchacha20poly1305_open_detached_afternm=Module["_crypto_box_curve25519xchacha20poly1305_open_detached_afternm"]=asm["_crypto_box_curve25519xchacha20poly1305_open_detached_afternm"];var _crypto_box_curve25519xsalsa20poly1305_beforenmbytes=Module["_crypto_box_curve25519xsalsa20poly1305_beforenmbytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_beforenmbytes"];var _crypto_stream_xchacha20_keygen=Module["_crypto_stream_xchacha20_keygen"]=asm["_crypto_stream_xchacha20_keygen"];var _crypto_core_hchacha20_constbytes=Module["_crypto_core_hchacha20_constbytes"]=asm["_crypto_core_hchacha20_constbytes"];var _crypto_stream_xchacha20_xor=Module["_crypto_stream_xchacha20_xor"]=asm["_crypto_stream_xchacha20_xor"];var _randombytes_seedbytes=Module["_randombytes_seedbytes"]=asm["_randombytes_seedbytes"];var _crypto_sign_final_create=Module["_crypto_sign_final_create"]=asm["_crypto_sign_final_create"];var _crypto_kx_secretkeybytes=Module["_crypto_kx_secretkeybytes"]=asm["_crypto_kx_secretkeybytes"];var _crypto_box_detached=Module["_crypto_box_detached"]=asm["_crypto_box_detached"];var _randombytes_buf=Module["_randombytes_buf"]=asm["_randombytes_buf"];var _crypto_generichash_blake2b_saltbytes=Module["_crypto_generichash_blake2b_saltbytes"]=asm["_crypto_generichash_blake2b_saltbytes"];var _crypto_box_open_detached=Module["_crypto_box_open_detached"]=asm["_crypto_box_open_detached"];var _crypto_kx_seedbytes=Module["_crypto_kx_seedbytes"]=asm["_crypto_kx_seedbytes"];var _crypto_secretbox_xsalsa20poly1305_zerobytes=Module["_crypto_secretbox_xsalsa20poly1305_zerobytes"]=asm["_crypto_secretbox_xsalsa20poly1305_zerobytes"];var _crypto_box_curve25519xchacha20poly1305_open_detached=Module["_crypto_box_curve25519xchacha20poly1305_open_detached"]=asm["_crypto_box_curve25519xchacha20poly1305_open_detached"];var _crypto_generichash_blake2b_keybytes=Module["_crypto_generichash_blake2b_keybytes"]=asm["_crypto_generichash_blake2b_keybytes"];var _crypto_box_curve25519xchacha20poly1305_easy=Module["_crypto_box_curve25519xchacha20poly1305_easy"]=asm["_crypto_box_curve25519xchacha20poly1305_easy"];var _crypto_pwhash_argon2i_bytes_min=Module["_crypto_pwhash_argon2i_bytes_min"]=asm["_crypto_pwhash_argon2i_bytes_min"];var _crypto_pwhash_scryptsalsa208sha256_str=Module["_crypto_pwhash_scryptsalsa208sha256_str"]=asm["_crypto_pwhash_scryptsalsa208sha256_str"];var _crypto_hash=Module["_crypto_hash"]=asm["_crypto_hash"];var _i64Subtract=Module["_i64Subtract"]=asm["_i64Subtract"];var _crypto_box_seedbytes=Module["_crypto_box_seedbytes"]=asm["_crypto_box_seedbytes"];var _crypto_generichash_blake2b_bytes_min=Module["_crypto_generichash_blake2b_bytes_min"]=asm["_crypto_generichash_blake2b_bytes_min"];var _crypto_box_curve25519xsalsa20poly1305=Module["_crypto_box_curve25519xsalsa20poly1305"]=asm["_crypto_box_curve25519xsalsa20poly1305"];var _crypto_generichash_blake2b_statebytes=Module["_crypto_generichash_blake2b_statebytes"]=asm["_crypto_generichash_blake2b_statebytes"];var _crypto_sign_ed25519ph_final_create=Module["_crypto_sign_ed25519ph_final_create"]=asm["_crypto_sign_ed25519ph_final_create"];var _crypto_aead_chacha20poly1305_ietf_decrypt_detached=Module["_crypto_aead_chacha20poly1305_ietf_decrypt_detached"]=asm["_crypto_aead_chacha20poly1305_ietf_decrypt_detached"];var _crypto_generichash_final=Module["_crypto_generichash_final"]=asm["_crypto_generichash_final"];var _crypto_auth_hmacsha512_update=Module["_crypto_auth_hmacsha512_update"]=asm["_crypto_auth_hmacsha512_update"];var _crypto_auth_hmacsha256=Module["_crypto_auth_hmacsha256"]=asm["_crypto_auth_hmacsha256"];var _crypto_box_keypair=Module["_crypto_box_keypair"]=asm["_crypto_box_keypair"];var _crypto_hash_sha256_bytes=Module["_crypto_hash_sha256_bytes"]=asm["_crypto_hash_sha256_bytes"];var ___udivdi3=Module["___udivdi3"]=asm["___udivdi3"];var _crypto_pwhash_argon2i_passwd_max=Module["_crypto_pwhash_argon2i_passwd_max"]=asm["_crypto_pwhash_argon2i_passwd_max"];var _sodium_init=Module["_sodium_init"]=asm["_sodium_init"];var _crypto_secretbox_macbytes=Module["_crypto_secretbox_macbytes"]=asm["_crypto_secretbox_macbytes"];var _crypto_aead_xchacha20poly1305_ietf_npubbytes=Module["_crypto_aead_xchacha20poly1305_ietf_npubbytes"]=asm["_crypto_aead_xchacha20poly1305_ietf_npubbytes"];var _bitshift64Shl=Module["_bitshift64Shl"]=asm["_bitshift64Shl"];var _crypto_pwhash_argon2i_opslimit_min=Module["_crypto_pwhash_argon2i_opslimit_min"]=asm["_crypto_pwhash_argon2i_opslimit_min"];var setTempRet0=Module["setTempRet0"]=asm["setTempRet0"];var _crypto_sign_seed_keypair=Module["_crypto_sign_seed_keypair"]=asm["_crypto_sign_seed_keypair"];var _crypto_core_hchacha20_inputbytes=Module["_crypto_core_hchacha20_inputbytes"]=asm["_crypto_core_hchacha20_inputbytes"];var ___muldi3=Module["___muldi3"]=asm["___muldi3"];var _crypto_core_salsa2012_constbytes=Module["_crypto_core_salsa2012_constbytes"]=asm["_crypto_core_salsa2012_constbytes"];var _crypto_kx_seed_keypair=Module["_crypto_kx_seed_keypair"]=asm["_crypto_kx_seed_keypair"];var _crypto_box_curve25519xchacha20poly1305_detached_afternm=Module["_crypto_box_curve25519xchacha20poly1305_detached_afternm"]=asm["_crypto_box_curve25519xchacha20poly1305_detached_afternm"];var _crypto_aead_chacha20poly1305_nsecbytes=Module["_crypto_aead_chacha20poly1305_nsecbytes"]=asm["_crypto_aead_chacha20poly1305_nsecbytes"];var _sodium_library_minimal=Module["_sodium_library_minimal"]=asm["_sodium_library_minimal"];var _crypto_aead_xchacha20poly1305_ietf_nsecbytes=Module["_crypto_aead_xchacha20poly1305_ietf_nsecbytes"]=asm["_crypto_aead_xchacha20poly1305_ietf_nsecbytes"];var _crypto_pwhash_argon2i_strbytes=Module["_crypto_pwhash_argon2i_strbytes"]=asm["_crypto_pwhash_argon2i_strbytes"];var _crypto_pwhash_argon2i_memlimit_max=Module["_crypto_pwhash_argon2i_memlimit_max"]=asm["_crypto_pwhash_argon2i_memlimit_max"];var _crypto_generichash_blake2b_salt_personal=Module["_crypto_generichash_blake2b_salt_personal"]=asm["_crypto_generichash_blake2b_salt_personal"];var _crypto_stream_aes128ctr_beforenmbytes=Module["_crypto_stream_aes128ctr_beforenmbytes"]=asm["_crypto_stream_aes128ctr_beforenmbytes"];var _crypto_kdf_derive_from_key=Module["_crypto_kdf_derive_from_key"]=asm["_crypto_kdf_derive_from_key"];var _crypto_secretbox_xsalsa20poly1305_noncebytes=Module["_crypto_secretbox_xsalsa20poly1305_noncebytes"]=asm["_crypto_secretbox_xsalsa20poly1305_noncebytes"];var _crypto_pwhash_scryptsalsa208sha256_opslimit_interactive=Module["_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive"]=asm["_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive"];var _crypto_pwhash_argon2i_memlimit_interactive=Module["_crypto_pwhash_argon2i_memlimit_interactive"]=asm["_crypto_pwhash_argon2i_memlimit_interactive"];var _crypto_hash_sha256_final=Module["_crypto_hash_sha256_final"]=asm["_crypto_hash_sha256_final"];var _crypto_stream_keybytes=Module["_crypto_stream_keybytes"]=asm["_crypto_stream_keybytes"];var _crypto_pwhash_memlimit_min=Module["_crypto_pwhash_memlimit_min"]=asm["_crypto_pwhash_memlimit_min"];var _crypto_aead_chacha20poly1305_ietf_npubbytes=Module["_crypto_aead_chacha20poly1305_ietf_npubbytes"]=asm["_crypto_aead_chacha20poly1305_ietf_npubbytes"];var _crypto_stream_salsa208_noncebytes=Module["_crypto_stream_salsa208_noncebytes"]=asm["_crypto_stream_salsa208_noncebytes"];var _sodium_library_version_minor=Module["_sodium_library_version_minor"]=asm["_sodium_library_version_minor"];var _crypto_onetimeauth_bytes=Module["_crypto_onetimeauth_bytes"]=asm["_crypto_onetimeauth_bytes"];var _crypto_box_open=Module["_crypto_box_open"]=asm["_crypto_box_open"];var _crypto_secretbox_xchacha20poly1305_open_easy=Module["_crypto_secretbox_xchacha20poly1305_open_easy"]=asm["_crypto_secretbox_xchacha20poly1305_open_easy"];var _crypto_scalarmult_curve25519_base=Module["_crypto_scalarmult_curve25519_base"]=asm["_crypto_scalarmult_curve25519_base"];var _crypto_sign_ed25519_open=Module["_crypto_sign_ed25519_open"]=asm["_crypto_sign_ed25519_open"];var _crypto_stream_chacha20_ietf_keybytes=Module["_crypto_stream_chacha20_ietf_keybytes"]=asm["_crypto_stream_chacha20_ietf_keybytes"];var _crypto_box_noncebytes=Module["_crypto_box_noncebytes"]=asm["_crypto_box_noncebytes"];var _crypto_core_hchacha20_outputbytes=Module["_crypto_core_hchacha20_outputbytes"]=asm["_crypto_core_hchacha20_outputbytes"];var _crypto_stream_salsa2012_xor=Module["_crypto_stream_salsa2012_xor"]=asm["_crypto_stream_salsa2012_xor"];var _crypto_onetimeauth_keygen=Module["_crypto_onetimeauth_keygen"]=asm["_crypto_onetimeauth_keygen"];var _crypto_pwhash_strbytes=Module["_crypto_pwhash_strbytes"]=asm["_crypto_pwhash_strbytes"];var _crypto_auth_hmacsha512256_update=Module["_crypto_auth_hmacsha512256_update"]=asm["_crypto_auth_hmacsha512256_update"];var _crypto_core_salsa208_outputbytes=Module["_crypto_core_salsa208_outputbytes"]=asm["_crypto_core_salsa208_outputbytes"];var _crypto_onetimeauth_poly1305=Module["_crypto_onetimeauth_poly1305"]=asm["_crypto_onetimeauth_poly1305"];var _crypto_secretbox_xchacha20poly1305_macbytes=Module["_crypto_secretbox_xchacha20poly1305_macbytes"]=asm["_crypto_secretbox_xchacha20poly1305_macbytes"];var _crypto_kdf_bytes_min=Module["_crypto_kdf_bytes_min"]=asm["_crypto_kdf_bytes_min"];var _crypto_sign_ed25519_sk_to_seed=Module["_crypto_sign_ed25519_sk_to_seed"]=asm["_crypto_sign_ed25519_sk_to_seed"];var _crypto_pwhash_scryptsalsa208sha256_memlimit_interactive=Module["_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive"]=asm["_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive"];var _crypto_stream_xsalsa20=Module["_crypto_stream_xsalsa20"]=asm["_crypto_stream_xsalsa20"];var _crypto_box_open_easy_afternm=Module["_crypto_box_open_easy_afternm"]=asm["_crypto_box_open_easy_afternm"];var _crypto_box_curve25519xsalsa20poly1305_seedbytes=Module["_crypto_box_curve25519xsalsa20poly1305_seedbytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_seedbytes"];var _crypto_stream_salsa20_keybytes=Module["_crypto_stream_salsa20_keybytes"]=asm["_crypto_stream_salsa20_keybytes"];var _crypto_kdf_primitive=Module["_crypto_kdf_primitive"]=asm["_crypto_kdf_primitive"];var _crypto_sign_ed25519ph_final_verify=Module["_crypto_sign_ed25519ph_final_verify"]=asm["_crypto_sign_ed25519ph_final_verify"];var _crypto_sign_ed25519_publickeybytes=Module["_crypto_sign_ed25519_publickeybytes"]=asm["_crypto_sign_ed25519_publickeybytes"];var _crypto_stream_aes128ctr=Module["_crypto_stream_aes128ctr"]=asm["_crypto_stream_aes128ctr"];var _crypto_shorthash=Module["_crypto_shorthash"]=asm["_crypto_shorthash"];var _crypto_auth_keybytes=Module["_crypto_auth_keybytes"]=asm["_crypto_auth_keybytes"];var _crypto_box_curve25519xsalsa20poly1305_open_afternm=Module["_crypto_box_curve25519xsalsa20poly1305_open_afternm"]=asm["_crypto_box_curve25519xsalsa20poly1305_open_afternm"];var _crypto_aead_chacha20poly1305_npubbytes=Module["_crypto_aead_chacha20poly1305_npubbytes"]=asm["_crypto_aead_chacha20poly1305_npubbytes"];var _crypto_aead_xchacha20poly1305_ietf_abytes=Module["_crypto_aead_xchacha20poly1305_ietf_abytes"]=asm["_crypto_aead_xchacha20poly1305_ietf_abytes"];var _crypto_onetimeauth_poly1305_final=Module["_crypto_onetimeauth_poly1305_final"]=asm["_crypto_onetimeauth_poly1305_final"];var _crypto_onetimeauth_poly1305_bytes=Module["_crypto_onetimeauth_poly1305_bytes"]=asm["_crypto_onetimeauth_poly1305_bytes"];var _crypto_box_curve25519xsalsa20poly1305_seed_keypair=Module["_crypto_box_curve25519xsalsa20poly1305_seed_keypair"]=asm["_crypto_box_curve25519xsalsa20poly1305_seed_keypair"];var _crypto_box_primitive=Module["_crypto_box_primitive"]=asm["_crypto_box_primitive"];var _crypto_pwhash_str=Module["_crypto_pwhash_str"]=asm["_crypto_pwhash_str"];var _crypto_auth_hmacsha512_keybytes=Module["_crypto_auth_hmacsha512_keybytes"]=asm["_crypto_auth_hmacsha512_keybytes"];var _crypto_auth=Module["_crypto_auth"]=asm["_crypto_auth"];var _crypto_pwhash_scryptsalsa208sha256_bytes_min=Module["_crypto_pwhash_scryptsalsa208sha256_bytes_min"]=asm["_crypto_pwhash_scryptsalsa208sha256_bytes_min"];var _crypto_core_salsa20_keybytes=Module["_crypto_core_salsa20_keybytes"]=asm["_crypto_core_salsa20_keybytes"];var _crypto_box_afternm=Module["_crypto_box_afternm"]=asm["_crypto_box_afternm"];var _crypto_core_salsa208_constbytes=Module["_crypto_core_salsa208_constbytes"]=asm["_crypto_core_salsa208_constbytes"];var _crypto_onetimeauth_primitive=Module["_crypto_onetimeauth_primitive"]=asm["_crypto_onetimeauth_primitive"];var _crypto_pwhash_scryptsalsa208sha256_str_verify=Module["_crypto_pwhash_scryptsalsa208sha256_str_verify"]=asm["_crypto_pwhash_scryptsalsa208sha256_str_verify"];var _sodium_version_string=Module["_sodium_version_string"]=asm["_sodium_version_string"];var _crypto_stream_xchacha20_xor_ic=Module["_crypto_stream_xchacha20_xor_ic"]=asm["_crypto_stream_xchacha20_xor_ic"];var _crypto_pwhash_scryptsalsa208sha256_passwd_min=Module["_crypto_pwhash_scryptsalsa208sha256_passwd_min"]=asm["_crypto_pwhash_scryptsalsa208sha256_passwd_min"];var _crypto_stream_chacha20_ietf=Module["_crypto_stream_chacha20_ietf"]=asm["_crypto_stream_chacha20_ietf"];var _crypto_generichash=Module["_crypto_generichash"]=asm["_crypto_generichash"];var _crypto_core_hsalsa20_outputbytes=Module["_crypto_core_hsalsa20_outputbytes"]=asm["_crypto_core_hsalsa20_outputbytes"];var _crypto_pwhash_opslimit_interactive=Module["_crypto_pwhash_opslimit_interactive"]=asm["_crypto_pwhash_opslimit_interactive"];var _crypto_stream_aes128ctr_beforenm=Module["_crypto_stream_aes128ctr_beforenm"]=asm["_crypto_stream_aes128ctr_beforenm"];var getTempRet0=Module["getTempRet0"]=asm["getTempRet0"];var _crypto_box_curve25519xsalsa20poly1305_noncebytes=Module["_crypto_box_curve25519xsalsa20poly1305_noncebytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_noncebytes"];var _crypto_stream_salsa2012_noncebytes=Module["_crypto_stream_salsa2012_noncebytes"]=asm["_crypto_stream_salsa2012_noncebytes"];var _crypto_core_salsa208_keybytes=Module["_crypto_core_salsa208_keybytes"]=asm["_crypto_core_salsa208_keybytes"];var _crypto_aead_chacha20poly1305_ietf_decrypt=Module["_crypto_aead_chacha20poly1305_ietf_decrypt"]=asm["_crypto_aead_chacha20poly1305_ietf_decrypt"];var _crypto_auth_hmacsha512256_init=Module["_crypto_auth_hmacsha512256_init"]=asm["_crypto_auth_hmacsha512256_init"];var _crypto_kx_server_session_keys=Module["_crypto_kx_server_session_keys"]=asm["_crypto_kx_server_session_keys"];var _crypto_onetimeauth_poly1305_verify=Module["_crypto_onetimeauth_poly1305_verify"]=asm["_crypto_onetimeauth_poly1305_verify"];var _crypto_auth_hmacsha512_final=Module["_crypto_auth_hmacsha512_final"]=asm["_crypto_auth_hmacsha512_final"];var _crypto_stream_aes128ctr_noncebytes=Module["_crypto_stream_aes128ctr_noncebytes"]=asm["_crypto_stream_aes128ctr_noncebytes"];var _crypto_box_secretkeybytes=Module["_crypto_box_secretkeybytes"]=asm["_crypto_box_secretkeybytes"];var _crypto_stream_salsa2012_keygen=Module["_crypto_stream_salsa2012_keygen"]=asm["_crypto_stream_salsa2012_keygen"];var _crypto_onetimeauth_update=Module["_crypto_onetimeauth_update"]=asm["_crypto_onetimeauth_update"];var _crypto_core_salsa20=Module["_crypto_core_salsa20"]=asm["_crypto_core_salsa20"];var _crypto_pwhash_memlimit_interactive=Module["_crypto_pwhash_memlimit_interactive"]=asm["_crypto_pwhash_memlimit_interactive"];var _crypto_scalarmult_bytes=Module["_crypto_scalarmult_bytes"]=asm["_crypto_scalarmult_bytes"];var _crypto_secretbox_detached=Module["_crypto_secretbox_detached"]=asm["_crypto_secretbox_detached"];var _crypto_stream_xor=Module["_crypto_stream_xor"]=asm["_crypto_stream_xor"];var _crypto_secretbox_xchacha20poly1305_easy=Module["_crypto_secretbox_xchacha20poly1305_easy"]=asm["_crypto_secretbox_xchacha20poly1305_easy"];var _crypto_secretbox_easy=Module["_crypto_secretbox_easy"]=asm["_crypto_secretbox_easy"];var _crypto_aead_xchacha20poly1305_ietf_decrypt_detached=Module["_crypto_aead_xchacha20poly1305_ietf_decrypt_detached"]=asm["_crypto_aead_xchacha20poly1305_ietf_decrypt_detached"];var _crypto_stream_salsa20=Module["_crypto_stream_salsa20"]=asm["_crypto_stream_salsa20"];var _sodium_bin2hex=Module["_sodium_bin2hex"]=asm["_sodium_bin2hex"];var _crypto_auth_hmacsha512_statebytes=Module["_crypto_auth_hmacsha512_statebytes"]=asm["_crypto_auth_hmacsha512_statebytes"];var _crypto_pwhash_argon2i_opslimit_sensitive=Module["_crypto_pwhash_argon2i_opslimit_sensitive"]=asm["_crypto_pwhash_argon2i_opslimit_sensitive"];var _crypto_generichash_blake2b_bytes_max=Module["_crypto_generichash_blake2b_bytes_max"]=asm["_crypto_generichash_blake2b_bytes_max"];var _crypto_hash_sha256_update=Module["_crypto_hash_sha256_update"]=asm["_crypto_hash_sha256_update"];var _crypto_core_hsalsa20_constbytes=Module["_crypto_core_hsalsa20_constbytes"]=asm["_crypto_core_hsalsa20_constbytes"];var _crypto_box_easy_afternm=Module["_crypto_box_easy_afternm"]=asm["_crypto_box_easy_afternm"];var _crypto_auth_hmacsha512256_verify=Module["_crypto_auth_hmacsha512256_verify"]=asm["_crypto_auth_hmacsha512256_verify"];var _crypto_pwhash_memlimit_moderate=Module["_crypto_pwhash_memlimit_moderate"]=asm["_crypto_pwhash_memlimit_moderate"];var _crypto_core_salsa20_inputbytes=Module["_crypto_core_salsa20_inputbytes"]=asm["_crypto_core_salsa20_inputbytes"];var _crypto_box_publickeybytes=Module["_crypto_box_publickeybytes"]=asm["_crypto_box_publickeybytes"];var _crypto_sign_secretkeybytes=Module["_crypto_sign_secretkeybytes"]=asm["_crypto_sign_secretkeybytes"];var ___muldsi3=Module["___muldsi3"]=asm["___muldsi3"];var _crypto_scalarmult_scalarbytes=Module["_crypto_scalarmult_scalarbytes"]=asm["_crypto_scalarmult_scalarbytes"];var _crypto_verify_32=Module["_crypto_verify_32"]=asm["_crypto_verify_32"];var _crypto_kx_sessionkeybytes=Module["_crypto_kx_sessionkeybytes"]=asm["_crypto_kx_sessionkeybytes"];var _crypto_aead_chacha20poly1305_decrypt=Module["_crypto_aead_chacha20poly1305_decrypt"]=asm["_crypto_aead_chacha20poly1305_decrypt"];var _crypto_sign=Module["_crypto_sign"]=asm["_crypto_sign"];var _crypto_pwhash_passwd_max=Module["_crypto_pwhash_passwd_max"]=asm["_crypto_pwhash_passwd_max"];var _crypto_pwhash_scryptsalsa208sha256_opslimit_min=Module["_crypto_pwhash_scryptsalsa208sha256_opslimit_min"]=asm["_crypto_pwhash_scryptsalsa208sha256_opslimit_min"];var _sodium_hex2bin=Module["_sodium_hex2bin"]=asm["_sodium_hex2bin"];var _crypto_pwhash_argon2i_alg_argon2i13=Module["_crypto_pwhash_argon2i_alg_argon2i13"]=asm["_crypto_pwhash_argon2i_alg_argon2i13"];var _crypto_secretbox_keybytes=Module["_crypto_secretbox_keybytes"]=asm["_crypto_secretbox_keybytes"];var _randombytes=Module["_randombytes"]=asm["_randombytes"];var _crypto_hash_bytes=Module["_crypto_hash_bytes"]=asm["_crypto_hash_bytes"];var _crypto_stream_salsa20_keygen=Module["_crypto_stream_salsa20_keygen"]=asm["_crypto_stream_salsa20_keygen"];var _crypto_hash_sha256_statebytes=Module["_crypto_hash_sha256_statebytes"]=asm["_crypto_hash_sha256_statebytes"];var _crypto_pwhash_argon2i_passwd_min=Module["_crypto_pwhash_argon2i_passwd_min"]=asm["_crypto_pwhash_argon2i_passwd_min"];var _crypto_pwhash_opslimit_sensitive=Module["_crypto_pwhash_opslimit_sensitive"]=asm["_crypto_pwhash_opslimit_sensitive"];var _crypto_sign_init=Module["_crypto_sign_init"]=asm["_crypto_sign_init"];var _crypto_generichash_blake2b_personalbytes=Module["_crypto_generichash_blake2b_personalbytes"]=asm["_crypto_generichash_blake2b_personalbytes"];var _crypto_stream_chacha20_xor_ic=Module["_crypto_stream_chacha20_xor_ic"]=asm["_crypto_stream_chacha20_xor_ic"];var _crypto_sign_verify_detached=Module["_crypto_sign_verify_detached"]=asm["_crypto_sign_verify_detached"];var _crypto_onetimeauth_verify=Module["_crypto_onetimeauth_verify"]=asm["_crypto_onetimeauth_verify"];var _crypto_sign_ed25519_detached=Module["_crypto_sign_ed25519_detached"]=asm["_crypto_sign_ed25519_detached"];var _crypto_generichash_init=Module["_crypto_generichash_init"]=asm["_crypto_generichash_init"];var _i64Add=Module["_i64Add"]=asm["_i64Add"];var _crypto_sign_bytes=Module["_crypto_sign_bytes"]=asm["_crypto_sign_bytes"];var _crypto_generichash_update=Module["_crypto_generichash_update"]=asm["_crypto_generichash_update"];var _crypto_scalarmult=Module["_crypto_scalarmult"]=asm["_crypto_scalarmult"];var _crypto_aead_chacha20poly1305_ietf_abytes=Module["_crypto_aead_chacha20poly1305_ietf_abytes"]=asm["_crypto_aead_chacha20poly1305_ietf_abytes"];var _crypto_sign_detached=Module["_crypto_sign_detached"]=asm["_crypto_sign_detached"];var _crypto_generichash_blake2b_update=Module["_crypto_generichash_blake2b_update"]=asm["_crypto_generichash_blake2b_update"];var _crypto_box_curve25519xsalsa20poly1305_beforenm=Module["_crypto_box_curve25519xsalsa20poly1305_beforenm"]=asm["_crypto_box_curve25519xsalsa20poly1305_beforenm"];var _crypto_generichash_blake2b_bytes=Module["_crypto_generichash_blake2b_bytes"]=asm["_crypto_generichash_blake2b_bytes"];var _crypto_auth_hmacsha512256_bytes=Module["_crypto_auth_hmacsha512256_bytes"]=asm["_crypto_auth_hmacsha512256_bytes"];var _crypto_box_curve25519xchacha20poly1305_noncebytes=Module["_crypto_box_curve25519xchacha20poly1305_noncebytes"]=asm["_crypto_box_curve25519xchacha20poly1305_noncebytes"];var _randombytes_uniform=Module["_randombytes_uniform"]=asm["_randombytes_uniform"];var _crypto_shorthash_siphash24_keybytes=Module["_crypto_shorthash_siphash24_keybytes"]=asm["_crypto_shorthash_siphash24_keybytes"];var _crypto_shorthash_keygen=Module["_crypto_shorthash_keygen"]=asm["_crypto_shorthash_keygen"];var _crypto_onetimeauth_init=Module["_crypto_onetimeauth_init"]=asm["_crypto_onetimeauth_init"];var _crypto_generichash_bytes=Module["_crypto_generichash_bytes"]=asm["_crypto_generichash_bytes"];var _crypto_stream_salsa20_xor=Module["_crypto_stream_salsa20_xor"]=asm["_crypto_stream_salsa20_xor"];var _crypto_auth_hmacsha512_verify=Module["_crypto_auth_hmacsha512_verify"]=asm["_crypto_auth_hmacsha512_verify"];var _crypto_generichash_blake2b_keybytes_min=Module["_crypto_generichash_blake2b_keybytes_min"]=asm["_crypto_generichash_blake2b_keybytes_min"];var _bitshift64Lshr=Module["_bitshift64Lshr"]=asm["_bitshift64Lshr"];var _crypto_kx_publickeybytes=Module["_crypto_kx_publickeybytes"]=asm["_crypto_kx_publickeybytes"];var _crypto_pwhash_bytes_max=Module["_crypto_pwhash_bytes_max"]=asm["_crypto_pwhash_bytes_max"];var _crypto_aead_chacha20poly1305_ietf_keybytes=Module["_crypto_aead_chacha20poly1305_ietf_keybytes"]=asm["_crypto_aead_chacha20poly1305_ietf_keybytes"];var _crypto_aead_chacha20poly1305_ietf_encrypt_detached=Module["_crypto_aead_chacha20poly1305_ietf_encrypt_detached"]=asm["_crypto_aead_chacha20poly1305_ietf_encrypt_detached"];var _crypto_stream=Module["_crypto_stream"]=asm["_crypto_stream"];var _sbrk=Module["_sbrk"]=asm["_sbrk"];var _crypto_box_curve25519xchacha20poly1305_beforenm=Module["_crypto_box_curve25519xchacha20poly1305_beforenm"]=asm["_crypto_box_curve25519xchacha20poly1305_beforenm"];var _memcpy=Module["_memcpy"]=asm["_memcpy"];var _crypto_pwhash=Module["_crypto_pwhash"]=asm["_crypto_pwhash"];var _crypto_auth_hmacsha512256=Module["_crypto_auth_hmacsha512256"]=asm["_crypto_auth_hmacsha512256"];var _crypto_secretbox_xsalsa20poly1305=Module["_crypto_secretbox_xsalsa20poly1305"]=asm["_crypto_secretbox_xsalsa20poly1305"];var _crypto_verify_16_bytes=Module["_crypto_verify_16_bytes"]=asm["_crypto_verify_16_bytes"];var _crypto_stream_salsa208_keygen=Module["_crypto_stream_salsa208_keygen"]=asm["_crypto_stream_salsa208_keygen"];var _emscripten_get_global_libc=Module["_emscripten_get_global_libc"]=asm["_emscripten_get_global_libc"];var _crypto_shorthash_siphashx24_bytes=Module["_crypto_shorthash_siphashx24_bytes"]=asm["_crypto_shorthash_siphashx24_bytes"];var _crypto_generichash_blake2b_final=Module["_crypto_generichash_blake2b_final"]=asm["_crypto_generichash_blake2b_final"];var _crypto_generichash_blake2b_init_salt_personal=Module["_crypto_generichash_blake2b_init_salt_personal"]=asm["_crypto_generichash_blake2b_init_salt_personal"];var _crypto_box_seal=Module["_crypto_box_seal"]=asm["_crypto_box_seal"];var _crypto_aead_xchacha20poly1305_ietf_keygen=Module["_crypto_aead_xchacha20poly1305_ietf_keygen"]=asm["_crypto_aead_xchacha20poly1305_ietf_keygen"];var _crypto_kx_keypair=Module["_crypto_kx_keypair"]=asm["_crypto_kx_keypair"];var runPostSets=Module["runPostSets"]=asm["runPostSets"];var _crypto_pwhash_alg_default=Module["_crypto_pwhash_alg_default"]=asm["_crypto_pwhash_alg_default"];var _crypto_box=Module["_crypto_box"]=asm["_crypto_box"];var _crypto_stream_primitive=Module["_crypto_stream_primitive"]=asm["_crypto_stream_primitive"];var _crypto_secretbox_xsalsa20poly1305_boxzerobytes=Module["_crypto_secretbox_xsalsa20poly1305_boxzerobytes"]=asm["_crypto_secretbox_xsalsa20poly1305_boxzerobytes"];var _crypto_pwhash_str_verify=Module["_crypto_pwhash_str_verify"]=asm["_crypto_pwhash_str_verify"];var _crypto_generichash_keybytes_min=Module["_crypto_generichash_keybytes_min"]=asm["_crypto_generichash_keybytes_min"];var _crypto_generichash_statebytes=Module["_crypto_generichash_statebytes"]=asm["_crypto_generichash_statebytes"];var _crypto_onetimeauth_poly1305_statebytes=Module["_crypto_onetimeauth_poly1305_statebytes"]=asm["_crypto_onetimeauth_poly1305_statebytes"];var _crypto_sign_final_verify=Module["_crypto_sign_final_verify"]=asm["_crypto_sign_final_verify"];var _crypto_pwhash_strprefix=Module["_crypto_pwhash_strprefix"]=asm["_crypto_pwhash_strprefix"];var _crypto_secretbox_keygen=Module["_crypto_secretbox_keygen"]=asm["_crypto_secretbox_keygen"];var _crypto_secretbox_xchacha20poly1305_noncebytes=Module["_crypto_secretbox_xchacha20poly1305_noncebytes"]=asm["_crypto_secretbox_xchacha20poly1305_noncebytes"];var _crypto_hash_sha512=Module["_crypto_hash_sha512"]=asm["_crypto_hash_sha512"];var _llvm_cttz_i32=Module["_llvm_cttz_i32"]=asm["_llvm_cttz_i32"];var _crypto_pwhash_scryptsalsa208sha256_bytes_max=Module["_crypto_pwhash_scryptsalsa208sha256_bytes_max"]=asm["_crypto_pwhash_scryptsalsa208sha256_bytes_max"];var _crypto_box_curve25519xchacha20poly1305_detached=Module["_crypto_box_curve25519xchacha20poly1305_detached"]=asm["_crypto_box_curve25519xchacha20poly1305_detached"];var _sodium_library_version_major=Module["_sodium_library_version_major"]=asm["_sodium_library_version_major"];var _crypto_aead_chacha20poly1305_ietf_encrypt=Module["_crypto_aead_chacha20poly1305_ietf_encrypt"]=asm["_crypto_aead_chacha20poly1305_ietf_encrypt"];var _crypto_generichash_blake2b_init=Module["_crypto_generichash_blake2b_init"]=asm["_crypto_generichash_blake2b_init"];var _randombytes_close=Module["_randombytes_close"]=asm["_randombytes_close"];var _crypto_pwhash_primitive=Module["_crypto_pwhash_primitive"]=asm["_crypto_pwhash_primitive"];var _crypto_onetimeauth_keybytes=Module["_crypto_onetimeauth_keybytes"]=asm["_crypto_onetimeauth_keybytes"];var _crypto_pwhash_argon2i=Module["_crypto_pwhash_argon2i"]=asm["_crypto_pwhash_argon2i"];var _crypto_stream_aes128ctr_afternm=Module["_crypto_stream_aes128ctr_afternm"]=asm["_crypto_stream_aes128ctr_afternm"];var _crypto_kdf_keybytes=Module["_crypto_kdf_keybytes"]=asm["_crypto_kdf_keybytes"];var establishStackSpace=Module["establishStackSpace"]=asm["establishStackSpace"];var _crypto_aead_chacha20poly1305_encrypt=Module["_crypto_aead_chacha20poly1305_encrypt"]=asm["_crypto_aead_chacha20poly1305_encrypt"];var _crypto_core_salsa2012_inputbytes=Module["_crypto_core_salsa2012_inputbytes"]=asm["_crypto_core_salsa2012_inputbytes"];var _crypto_pwhash_scryptsalsa208sha256_memlimit_min=Module["_crypto_pwhash_scryptsalsa208sha256_memlimit_min"]=asm["_crypto_pwhash_scryptsalsa208sha256_memlimit_min"];var _crypto_core_salsa208=Module["_crypto_core_salsa208"]=asm["_crypto_core_salsa208"];var _crypto_pwhash_opslimit_max=Module["_crypto_pwhash_opslimit_max"]=asm["_crypto_pwhash_opslimit_max"];var _crypto_auth_verify=Module["_crypto_auth_verify"]=asm["_crypto_auth_verify"];var _crypto_sign_ed25519_seed_keypair=Module["_crypto_sign_ed25519_seed_keypair"]=asm["_crypto_sign_ed25519_seed_keypair"];var _crypto_auth_hmacsha512256_keygen=Module["_crypto_auth_hmacsha512256_keygen"]=asm["_crypto_auth_hmacsha512256_keygen"];var _randombytes_stir=Module["_randombytes_stir"]=asm["_randombytes_stir"];var _memset=Module["_memset"]=asm["_memset"];var _crypto_box_open_detached_afternm=Module["_crypto_box_open_detached_afternm"]=asm["_crypto_box_open_detached_afternm"];var _crypto_pwhash_argon2i_memlimit_sensitive=Module["_crypto_pwhash_argon2i_memlimit_sensitive"]=asm["_crypto_pwhash_argon2i_memlimit_sensitive"];var _crypto_kx_primitive=Module["_crypto_kx_primitive"]=asm["_crypto_kx_primitive"];var _crypto_stream_salsa2012_keybytes=Module["_crypto_stream_salsa2012_keybytes"]=asm["_crypto_stream_salsa2012_keybytes"];var _crypto_aead_xchacha20poly1305_ietf_decrypt=Module["_crypto_aead_xchacha20poly1305_ietf_decrypt"]=asm["_crypto_aead_xchacha20poly1305_ietf_decrypt"];var _crypto_pwhash_scryptsalsa208sha256_strprefix=Module["_crypto_pwhash_scryptsalsa208sha256_strprefix"]=asm["_crypto_pwhash_scryptsalsa208sha256_strprefix"];var _crypto_core_salsa20_outputbytes=Module["_crypto_core_salsa20_outputbytes"]=asm["_crypto_core_salsa20_outputbytes"];var _crypto_auth_keygen=Module["_crypto_auth_keygen"]=asm["_crypto_auth_keygen"];var _crypto_secretbox=Module["_crypto_secretbox"]=asm["_crypto_secretbox"];var _crypto_aead_xchacha20poly1305_ietf_encrypt_detached=Module["_crypto_aead_xchacha20poly1305_ietf_encrypt_detached"]=asm["_crypto_aead_xchacha20poly1305_ietf_encrypt_detached"];var _crypto_pwhash_scryptsalsa208sha256_passwd_max=Module["_crypto_pwhash_scryptsalsa208sha256_passwd_max"]=asm["_crypto_pwhash_scryptsalsa208sha256_passwd_max"];var _crypto_auth_hmacsha256_bytes=Module["_crypto_auth_hmacsha256_bytes"]=asm["_crypto_auth_hmacsha256_bytes"];var _crypto_auth_hmacsha256_verify=Module["_crypto_auth_hmacsha256_verify"]=asm["_crypto_auth_hmacsha256_verify"];var _crypto_sign_keypair=Module["_crypto_sign_keypair"]=asm["_crypto_sign_keypair"];var _crypto_stream_xchacha20=Module["_crypto_stream_xchacha20"]=asm["_crypto_stream_xchacha20"];var _crypto_onetimeauth_statebytes=Module["_crypto_onetimeauth_statebytes"]=asm["_crypto_onetimeauth_statebytes"];var _crypto_sign_ed25519ph_init=Module["_crypto_sign_ed25519ph_init"]=asm["_crypto_sign_ed25519ph_init"];var _crypto_stream_salsa20_noncebytes=Module["_crypto_stream_salsa20_noncebytes"]=asm["_crypto_stream_salsa20_noncebytes"];var _crypto_shorthash_keybytes=Module["_crypto_shorthash_keybytes"]=asm["_crypto_shorthash_keybytes"];var _crypto_aead_chacha20poly1305_keygen=Module["_crypto_aead_chacha20poly1305_keygen"]=asm["_crypto_aead_chacha20poly1305_keygen"];var _crypto_shorthash_siphashx24=Module["_crypto_shorthash_siphashx24"]=asm["_crypto_shorthash_siphashx24"];var _memmove=Module["_memmove"]=asm["_memmove"];var _crypto_hash_sha512_final=Module["_crypto_hash_sha512_final"]=asm["_crypto_hash_sha512_final"];var _crypto_box_curve25519xsalsa20poly1305_zerobytes=Module["_crypto_box_curve25519xsalsa20poly1305_zerobytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_zerobytes"];var _crypto_shorthash_siphashx24_keybytes=Module["_crypto_shorthash_siphashx24_keybytes"]=asm["_crypto_shorthash_siphashx24_keybytes"];var _crypto_pwhash_passwd_min=Module["_crypto_pwhash_passwd_min"]=asm["_crypto_pwhash_passwd_min"];var _crypto_kdf_bytes_max=Module["_crypto_kdf_bytes_max"]=asm["_crypto_kdf_bytes_max"];var _crypto_box_curve25519xsalsa20poly1305_boxzerobytes=Module["_crypto_box_curve25519xsalsa20poly1305_boxzerobytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_boxzerobytes"];var _crypto_generichash_bytes_min=Module["_crypto_generichash_bytes_min"]=asm["_crypto_generichash_bytes_min"];var _crypto_core_salsa2012_outputbytes=Module["_crypto_core_salsa2012_outputbytes"]=asm["_crypto_core_salsa2012_outputbytes"];var _crypto_auth_hmacsha256_keybytes=Module["_crypto_auth_hmacsha256_keybytes"]=asm["_crypto_auth_hmacsha256_keybytes"];var _crypto_core_salsa208_inputbytes=Module["_crypto_core_salsa208_inputbytes"]=asm["_crypto_core_salsa208_inputbytes"];var _crypto_pwhash_scryptsalsa208sha256_opslimit_max=Module["_crypto_pwhash_scryptsalsa208sha256_opslimit_max"]=asm["_crypto_pwhash_scryptsalsa208sha256_opslimit_max"];var _crypto_sign_update=Module["_crypto_sign_update"]=asm["_crypto_sign_update"];var _crypto_secretbox_xchacha20poly1305_detached=Module["_crypto_secretbox_xchacha20poly1305_detached"]=asm["_crypto_secretbox_xchacha20poly1305_detached"];var _crypto_stream_chacha20_noncebytes=Module["_crypto_stream_chacha20_noncebytes"]=asm["_crypto_stream_chacha20_noncebytes"];var _crypto_secretbox_open_detached=Module["_crypto_secretbox_open_detached"]=asm["_crypto_secretbox_open_detached"];var _crypto_box_curve25519xchacha20poly1305_seed_keypair=Module["_crypto_box_curve25519xchacha20poly1305_seed_keypair"]=asm["_crypto_box_curve25519xchacha20poly1305_seed_keypair"];var _crypto_pwhash_argon2i_memlimit_min=Module["_crypto_pwhash_argon2i_memlimit_min"]=asm["_crypto_pwhash_argon2i_memlimit_min"];var _crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive=Module["_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive"]=asm["_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive"];var _crypto_box_curve25519xsalsa20poly1305_secretkeybytes=Module["_crypto_box_curve25519xsalsa20poly1305_secretkeybytes"]=asm["_crypto_box_curve25519xsalsa20poly1305_secretkeybytes"];var _crypto_kdf_contextbytes=Module["_crypto_kdf_contextbytes"]=asm["_crypto_kdf_contextbytes"];var _crypto_stream_xchacha20_keybytes=Module["_crypto_stream_xchacha20_keybytes"]=asm["_crypto_stream_xchacha20_keybytes"];var _crypto_box_seal_open=Module["_crypto_box_seal_open"]=asm["_crypto_box_seal_open"];var _crypto_shorthash_primitive=Module["_crypto_shorthash_primitive"]=asm["_crypto_shorthash_primitive"];var _crypto_core_hsalsa20_inputbytes=Module["_crypto_core_hsalsa20_inputbytes"]=asm["_crypto_core_hsalsa20_inputbytes"];var _crypto_onetimeauth_final=Module["_crypto_onetimeauth_final"]=asm["_crypto_onetimeauth_final"];var _crypto_secretbox_open_easy=Module["_crypto_secretbox_open_easy"]=asm["_crypto_secretbox_open_easy"];var _crypto_core_salsa2012=Module["_crypto_core_salsa2012"]=asm["_crypto_core_salsa2012"];var _crypto_box_curve25519xchacha20poly1305_macbytes=Module["_crypto_box_curve25519xchacha20poly1305_macbytes"]=asm["_crypto_box_curve25519xchacha20poly1305_macbytes"];var _crypto_auth_hmacsha512256_statebytes=Module["_crypto_auth_hmacsha512256_statebytes"]=asm["_crypto_auth_hmacsha512256_statebytes"];var _bitshift64Ashr=Module["_bitshift64Ashr"]=asm["_bitshift64Ashr"];var _crypto_box_curve25519xchacha20poly1305_publickeybytes=Module["_crypto_box_curve25519xchacha20poly1305_publickeybytes"]=asm["_crypto_box_curve25519xchacha20poly1305_publickeybytes"];var _crypto_stream_chacha20_xor=Module["_crypto_stream_chacha20_xor"]=asm["_crypto_stream_chacha20_xor"];var _crypto_core_hsalsa20=Module["_crypto_core_hsalsa20"]=asm["_crypto_core_hsalsa20"];Runtime.stackAlloc=Module["stackAlloc"];Runtime.stackSave=Module["stackSave"];Runtime.stackRestore=Module["stackRestore"];Runtime.establishStackSpace=Module["establishStackSpace"];Runtime.setTempRet0=Module["setTempRet0"];Runtime.getTempRet0=Module["getTempRet0"];Module["asm"]=asm;function ExitStatus(status){this.name="ExitStatus";this.message="Program terminated with exit("+status+")";this.status=status}ExitStatus.prototype=new Error;ExitStatus.prototype.constructor=ExitStatus;var initialStackTop;var preloadStartTime=null;var calledMain=false;dependenciesFulfilled=function runCaller(){if(!Module["calledRun"])run();if(!Module["calledRun"])dependenciesFulfilled=runCaller};Module["callMain"]=Module.callMain=function callMain(args){args=args||[];ensureInitRuntime();var argc=args.length+1;function pad(){for(var i=0;i<4-1;i++){argv.push(0)}}var argv=[allocate(intArrayFromString(Module["thisProgram"]),"i8",ALLOC_NORMAL)];pad();for(var i=0;i<argc-1;i=i+1){argv.push(allocate(intArrayFromString(args[i]),"i8",ALLOC_NORMAL));pad()}argv.push(0);argv=allocate(argv,"i32",ALLOC_NORMAL);try{var ret=Module["_main"](argc,argv,0);exit(ret,true)}catch(e){if(e instanceof ExitStatus){return}else if(e=="SimulateInfiniteLoop"){Module["noExitRuntime"]=true;return}else{var toLog=e;if(e&&typeof e==="object"&&e.stack){toLog=[e,e.stack]}Module.printErr("exception thrown: "+toLog);Module["quit"](1,e)}}finally{calledMain=true}};function run(args){args=args||Module["arguments"];if(preloadStartTime===null)preloadStartTime=Date.now();if(runDependencies>0){return}preRun();if(runDependencies>0)return;if(Module["calledRun"])return;function doRun(){if(Module["calledRun"])return;Module["calledRun"]=true;if(ABORT)return;ensureInitRuntime();preMain();if(Module["onRuntimeInitialized"])Module["onRuntimeInitialized"]();if(Module["_main"]&&shouldRunNow)Module["callMain"](args);postRun()}if(Module["setStatus"]){Module["setStatus"]("Running...");setTimeout((function(){setTimeout((function(){Module["setStatus"]("")}),1);doRun()}),1)}else{doRun()}}Module["run"]=Module.run=run;function exit(status,implicit){if(implicit&&Module["noExitRuntime"]){return}if(Module["noExitRuntime"]){}else{ABORT=true;EXITSTATUS=status;STACKTOP=initialStackTop;exitRuntime();if(Module["onExit"])Module["onExit"](status)}if(ENVIRONMENT_IS_NODE){process["exit"](status)}Module["quit"](status,new ExitStatus(status))}Module["exit"]=Module.exit=exit;var abortDecorators=[];function abort(what){if(what!==undefined){Module.print(what);Module.printErr(what);what=JSON.stringify(what)}else{what=""}ABORT=true;EXITSTATUS=1;var extra="\nIf this abort() is unexpected, build with -s ASSERTIONS=1 which can give more information.";var output="abort("+what+") at "+stackTrace()+extra;if(abortDecorators){abortDecorators.forEach((function(decorator){output=decorator(output,what)}))}throw output}Module["abort"]=Module.abort=abort;if(Module["preInit"]){if(typeof Module["preInit"]=="function")Module["preInit"]=[Module["preInit"]];while(Module["preInit"].length>0){Module["preInit"].pop()()}}var shouldRunNow=true;if(Module["noInitialRun"]){shouldRunNow=false}run() -/***/ }), -/* 164 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + ENVIRONMENT_IS_NODE && !process.removeAllListeners("uncaughtException"); + return Module; +})); -var CSSProperty = __webpack_require__(92); -var warning = __webpack_require__(2); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var isUnitlessNumber = CSSProperty.isUnitlessNumber; -var styleWarnings = {}; +/***/ }), +/* 417 */ +/***/ (function(module, exports) { -/** - * Convert a value into the proper css writable value. The style name `name` - * should be logical (no hyphens), as specified - * in `CSSProperty.isUnitlessNumber`. - * - * @param {string} name CSS property name such as `topMargin`. - * @param {*} value CSS property value such as `10px`. - * @param {ReactDOMComponent} component - * @return {string} Normalized style value with dimensions applied. - */ -function dangerousStyleValue(name, value, component, isCustomProperty) { - // Note that we've removed escapeTextForBrowser() calls here since the - // whole string will be escaped when the attribute is injected into - // the markup. If you provide unsafe user data here they can inject - // arbitrary CSS which may be problematic (I couldn't repro this): - // https://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet - // http://www.thespanner.co.uk/2007/11/26/ultimate-xss-css-injection/ - // This is not an XSS hole but instead a potential CSS injection issue - // which has lead to a greater discussion about how we're going to - // trust URLs moving forward. See #2115901 - var isEmpty = value == null || typeof value === 'boolean' || value === ''; - if (isEmpty) { - return ''; - } - var isNonNumeric = isNaN(value); - if (isCustomProperty || isNonNumeric || value === 0 || isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name]) { - return '' + value; // cast to string - } +/***/ }), +/* 418 */ +/***/ (function(module, exports, __webpack_require__) { - if (typeof value === 'string') { - if (process.env.NODE_ENV !== 'production') { - // Allow '0' to pass through without warning. 0 is already special and - // doesn't require units, so we don't need to warn about it. - if (component && value !== '0') { - var owner = component._currentElement._owner; - var ownerName = owner ? owner.getName() : null; - if (ownerName && !styleWarnings[ownerName]) { - styleWarnings[ownerName] = {}; - } - var warned = false; - if (ownerName) { - var warnings = styleWarnings[ownerName]; - warned = warnings[name]; - if (!warned) { - warnings[name] = true; - } - } - if (!warned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'a `%s` tag (owner: `%s`) was passed a numeric string value ' + 'for CSS property `%s` (value: `%s`) which will be treated ' + 'as a unitless number in a future version of React.', component._currentElement.type, ownerName || 'unknown', name, value) : void 0; - } - } - } - value = value.trim(); - } - return value + 'px'; +/* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// resolves . and .. elements in a path array with directory names there +// must be no slashes, empty elements, or device names (c:\) in the array +// (so also no leading and trailing slashes - it does not distinguish +// relative and absolute paths) +function normalizeArray(parts, allowAboveRoot) { + // if the path tries to go above the root, `up` ends up > 0 + var up = 0; + for (var i = parts.length - 1; i >= 0; i--) { + var last = parts[i]; + if (last === '.') { + parts.splice(i, 1); + } else if (last === '..') { + parts.splice(i, 1); + up++; + } else if (up) { + parts.splice(i, 1); + up--; + } + } + + // if the path is allowed to go above the root, restore leading ..s + if (allowAboveRoot) { + for (; up--; up) { + parts.unshift('..'); + } + } + + return parts; } -module.exports = dangerousStyleValue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 165 */ -/***/ (function(module, exports, __webpack_require__) { +// Split a filename into [root, dir, basename, ext], unix version +// 'root' is just a slash, or nothing. +var splitPathRe = + /^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/; +var splitPath = function(filename) { + return splitPathRe.exec(filename).slice(1); +}; -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +// path.resolve([from ...], to) +// posix version +exports.resolve = function() { + var resolvedPath = '', + resolvedAbsolute = false; + for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) { + var path = (i >= 0) ? arguments[i] : process.cwd(); + // Skip empty and invalid entries + if (typeof path !== 'string') { + throw new TypeError('Arguments to path.resolve must be strings'); + } else if (!path) { + continue; + } -var hyphenate = __webpack_require__(166); + resolvedPath = path + '/' + resolvedPath; + resolvedAbsolute = path.charAt(0) === '/'; + } -var msPattern = /^ms-/; + // At this point the path should be resolved to a full absolute path, but + // handle relative paths to be safe (might happen when process.cwd() fails) -/** - * Hyphenates a camelcased CSS property name, for example: - * - * > hyphenateStyleName('backgroundColor') - * < "background-color" - * > hyphenateStyleName('MozTransition') - * < "-moz-transition" - * > hyphenateStyleName('msTransition') - * < "-ms-transition" - * - * As Modernizr suggests (http://modernizr.com/docs/#prefixed), an `ms` prefix - * is converted to `-ms-`. - * - * @param {string} string - * @return {string} - */ -function hyphenateStyleName(string) { - return hyphenate(string).replace(msPattern, '-ms-'); -} + // Normalize the path + resolvedPath = normalizeArray(filter(resolvedPath.split('/'), function(p) { + return !!p; + }), !resolvedAbsolute).join('/'); -module.exports = hyphenateStyleName; + return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.'; +}; -/***/ }), -/* 166 */ -/***/ (function(module, exports, __webpack_require__) { +// path.normalize(path) +// posix version +exports.normalize = function(path) { + var isAbsolute = exports.isAbsolute(path), + trailingSlash = substr(path, -1) === '/'; -"use strict"; + // Normalize the path + path = normalizeArray(filter(path.split('/'), function(p) { + return !!p; + }), !isAbsolute).join('/'); + if (!path && !isAbsolute) { + path = '.'; + } + if (path && trailingSlash) { + path += '/'; + } -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + return (isAbsolute ? '/' : '') + path; +}; -var _uppercasePattern = /([A-Z])/g; +// posix version +exports.isAbsolute = function(path) { + return path.charAt(0) === '/'; +}; -/** - * Hyphenates a camelcased string, for example: - * - * > hyphenate('backgroundColor') - * < "background-color" - * - * For CSS style names, use `hyphenateStyleName` instead which works properly - * with all vendor prefixes, including `ms`. - * - * @param {string} string - * @return {string} - */ -function hyphenate(string) { - return string.replace(_uppercasePattern, '-$1').toLowerCase(); -} +// posix version +exports.join = function() { + var paths = Array.prototype.slice.call(arguments, 0); + return exports.normalize(filter(paths, function(p, index) { + if (typeof p !== 'string') { + throw new TypeError('Arguments to path.join must be strings'); + } + return p; + }).join('/')); +}; -module.exports = hyphenate; -/***/ }), -/* 167 */ -/***/ (function(module, exports, __webpack_require__) { +// path.relative(from, to) +// posix version +exports.relative = function(from, to) { + from = exports.resolve(from).substr(1); + to = exports.resolve(to).substr(1); -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - * @typechecks static-only - */ + function trim(arr) { + var start = 0; + for (; start < arr.length; start++) { + if (arr[start] !== '') break; + } + var end = arr.length - 1; + for (; end >= 0; end--) { + if (arr[end] !== '') break; + } + if (start > end) return []; + return arr.slice(start, end - start + 1); + } -/** - * Memoizes the return value of a function that accepts one string argument. - */ + var fromParts = trim(from.split('/')); + var toParts = trim(to.split('/')); -function memoizeStringOnly(callback) { - var cache = {}; - return function (string) { - if (!cache.hasOwnProperty(string)) { - cache[string] = callback.call(this, string); + var length = Math.min(fromParts.length, toParts.length); + var samePartsLength = length; + for (var i = 0; i < length; i++) { + if (fromParts[i] !== toParts[i]) { + samePartsLength = i; + break; } - return cache[string]; - }; -} + } -module.exports = memoizeStringOnly; + var outputParts = []; + for (var i = samePartsLength; i < fromParts.length; i++) { + outputParts.push('..'); + } -/***/ }), -/* 168 */ -/***/ (function(module, exports, __webpack_require__) { + outputParts = outputParts.concat(toParts.slice(samePartsLength)); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return outputParts.join('/'); +}; +exports.sep = '/'; +exports.delimiter = ':'; +exports.dirname = function(path) { + var result = splitPath(path), + root = result[0], + dir = result[1]; -var escapeTextContentForBrowser = __webpack_require__(44); + if (!root && !dir) { + // No dirname whatsoever + return '.'; + } -/** - * Escapes attribute value to prevent scripting attacks. - * - * @param {*} value Value to escape. - * @return {string} An escaped string. - */ -function quoteAttributeValueForBrowser(value) { - return '"' + escapeTextContentForBrowser(value) + '"'; + if (dir) { + // It has a dirname, strip trailing slash + dir = dir.substr(0, dir.length - 1); + } + + return root + dir; +}; + + +exports.basename = function(path, ext) { + var f = splitPath(path)[2]; + // TODO: make this comparison case-insensitive on windows? + if (ext && f.substr(-1 * ext.length) === ext) { + f = f.substr(0, f.length - ext.length); + } + return f; +}; + + +exports.extname = function(path) { + return splitPath(path)[3]; +}; + +function filter (xs, f) { + if (xs.filter) return xs.filter(f); + var res = []; + for (var i = 0; i < xs.length; i++) { + if (f(xs[i], i, xs)) res.push(xs[i]); + } + return res; } -module.exports = quoteAttributeValueForBrowser; +// String.prototype.substr - negative index don't work in IE8 +var substr = 'ab'.substr(-1) === 'b' + ? function (str, start, len) { return str.substr(start, len) } + : function (str, start, len) { + if (start < 0) start = str.length + start; + return str.substr(start, len); + } +; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 169 */ +/* 419 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +exports.randomBytes = exports.rng = exports.pseudoRandomBytes = exports.prng = __webpack_require__(43) +exports.createHash = exports.Hash = __webpack_require__(27) +exports.createHmac = exports.Hmac = __webpack_require__(67) -var EventPluginHub = __webpack_require__(32); +var algos = __webpack_require__(421) +var algoKeys = Object.keys(algos) +var hashes = ['sha1', 'sha224', 'sha256', 'sha384', 'sha512', 'md5', 'rmd160'].concat(algoKeys) +exports.getHashes = function () { + return hashes +} -function runEventQueueInBatch(events) { - EventPluginHub.enqueueEvents(events); - EventPluginHub.processEventQueue(false); +var p = __webpack_require__(177) +exports.pbkdf2 = p.pbkdf2 +exports.pbkdf2Sync = p.pbkdf2Sync + +var aes = __webpack_require__(423) + +exports.Cipher = aes.Cipher +exports.createCipher = aes.createCipher +exports.Cipheriv = aes.Cipheriv +exports.createCipheriv = aes.createCipheriv +exports.Decipher = aes.Decipher +exports.createDecipher = aes.createDecipher +exports.Decipheriv = aes.Decipheriv +exports.createDecipheriv = aes.createDecipheriv +exports.getCiphers = aes.getCiphers +exports.listCiphers = aes.listCiphers + +var dh = __webpack_require__(434) + +exports.DiffieHellmanGroup = dh.DiffieHellmanGroup +exports.createDiffieHellmanGroup = dh.createDiffieHellmanGroup +exports.getDiffieHellman = dh.getDiffieHellman +exports.createDiffieHellman = dh.createDiffieHellman +exports.DiffieHellman = dh.DiffieHellman + +var sign = __webpack_require__(437) + +exports.createSign = sign.createSign +exports.Sign = sign.Sign +exports.createVerify = sign.createVerify +exports.Verify = sign.Verify + +exports.createECDH = __webpack_require__(454) + +var publicEncrypt = __webpack_require__(455) + +exports.publicEncrypt = publicEncrypt.publicEncrypt +exports.privateEncrypt = publicEncrypt.privateEncrypt +exports.publicDecrypt = publicEncrypt.publicDecrypt +exports.privateDecrypt = publicEncrypt.privateDecrypt + +// the least I can do is make error messages for the rest of the node.js/crypto api. +// ;[ +// 'createCredentials' +// ].forEach(function (name) { +// exports[name] = function () { +// throw new Error([ +// 'sorry, ' + name + ' is not implemented yet', +// 'we accept pull requests', +// 'https://github.com/crypto-browserify/crypto-browserify' +// ].join('\n')) +// } +// }) + +exports.createCredentials = function () { + throw new Error([ + 'sorry, createCredentials is not implemented yet', + 'we accept pull requests', + 'https://github.com/crypto-browserify/crypto-browserify' + ].join('\n')) } -var ReactEventEmitterMixin = { - /** - * Streams a fired top-level event to `EventPluginHub` where plugins have the - * opportunity to create `ReactEvent`s to be dispatched. - */ - handleTopLevel: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var events = EventPluginHub.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); - runEventQueueInBatch(events); - } -}; +exports.constants = { + 'DH_CHECK_P_NOT_SAFE_PRIME': 2, + 'DH_CHECK_P_NOT_PRIME': 1, + 'DH_UNABLE_TO_CHECK_GENERATOR': 4, + 'DH_NOT_SUITABLE_GENERATOR': 8, + 'NPN_ENABLED': 1, + 'ALPN_ENABLED': 1, + 'RSA_PKCS1_PADDING': 1, + 'RSA_SSLV23_PADDING': 2, + 'RSA_NO_PADDING': 3, + 'RSA_PKCS1_OAEP_PADDING': 4, + 'RSA_X931_PADDING': 5, + 'RSA_PKCS1_PSS_PADDING': 6, + 'POINT_CONVERSION_COMPRESSED': 2, + 'POINT_CONVERSION_UNCOMPRESSED': 4, + 'POINT_CONVERSION_HYBRID': 6 +} -module.exports = ReactEventEmitterMixin; /***/ }), -/* 170 */ +/* 420 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var inherits = __webpack_require__(4) +var Buffer = __webpack_require__(7).Buffer +var Base = __webpack_require__(29) -var ExecutionEnvironment = __webpack_require__(8); +var ZEROS = Buffer.alloc(128) +var blocksize = 64 -/** - * Generate a mapping of standard vendor prefixes using the defined style property and event name. - * - * @param {string} styleProp - * @param {string} eventName - * @returns {object} - */ -function makePrefixMap(styleProp, eventName) { - var prefixes = {}; - - prefixes[styleProp.toLowerCase()] = eventName.toLowerCase(); - prefixes['Webkit' + styleProp] = 'webkit' + eventName; - prefixes['Moz' + styleProp] = 'moz' + eventName; - prefixes['ms' + styleProp] = 'MS' + eventName; - prefixes['O' + styleProp] = 'o' + eventName.toLowerCase(); +function Hmac (alg, key) { + Base.call(this, 'digest') + if (typeof key === 'string') { + key = Buffer.from(key) + } - return prefixes; -} + this._alg = alg + this._key = key -/** - * A list of event names to a configurable list of vendor prefixes. - */ -var vendorPrefixes = { - animationend: makePrefixMap('Animation', 'AnimationEnd'), - animationiteration: makePrefixMap('Animation', 'AnimationIteration'), - animationstart: makePrefixMap('Animation', 'AnimationStart'), - transitionend: makePrefixMap('Transition', 'TransitionEnd') -}; + if (key.length > blocksize) { + key = alg(key) + } else if (key.length < blocksize) { + key = Buffer.concat([key, ZEROS], blocksize) + } -/** - * Event names that have already been detected and prefixed (if applicable). - */ -var prefixedEventNames = {}; + var ipad = this._ipad = Buffer.allocUnsafe(blocksize) + var opad = this._opad = Buffer.allocUnsafe(blocksize) -/** - * Element to check for prefixes on. - */ -var style = {}; + for (var i = 0; i < blocksize; i++) { + ipad[i] = key[i] ^ 0x36 + opad[i] = key[i] ^ 0x5C + } -/** - * Bootstrap if a DOM exists. - */ -if (ExecutionEnvironment.canUseDOM) { - style = document.createElement('div').style; + this._hash = [ipad] +} - // On some platforms, in particular some releases of Android 4.x, - // the un-prefixed "animation" and "transition" properties are defined on the - // style object but the events that fire will still be prefixed, so we need - // to check if the un-prefixed events are usable, and if not remove them from the map. - if (!('AnimationEvent' in window)) { - delete vendorPrefixes.animationend.animation; - delete vendorPrefixes.animationiteration.animation; - delete vendorPrefixes.animationstart.animation; - } +inherits(Hmac, Base) - // Same as above - if (!('TransitionEvent' in window)) { - delete vendorPrefixes.transitionend.transition; - } +Hmac.prototype._update = function (data) { + this._hash.push(data) } -/** - * Attempts to determine the correct vendor prefixed event name. - * - * @param {string} eventName - * @returns {string} - */ -function getVendorPrefixedEventName(eventName) { - if (prefixedEventNames[eventName]) { - return prefixedEventNames[eventName]; - } else if (!vendorPrefixes[eventName]) { - return eventName; - } +Hmac.prototype._final = function () { + var h = this._alg(Buffer.concat(this._hash)) + return this._alg(Buffer.concat([this._opad, h])) +} +module.exports = Hmac - var prefixMap = vendorPrefixes[eventName]; - for (var styleProp in prefixMap) { - if (prefixMap.hasOwnProperty(styleProp) && styleProp in style) { - return prefixedEventNames[eventName] = prefixMap[styleProp]; - } - } +/***/ }), +/* 421 */ +/***/ (function(module, exports, __webpack_require__) { - return ''; -} +module.exports = __webpack_require__(176) -module.exports = getVendorPrefixedEventName; /***/ }), -/* 171 */ +/* 422 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(global, process) {var checkParameters = __webpack_require__(178) +var defaultEncoding = __webpack_require__(179) +var sync = __webpack_require__(180) +var Buffer = __webpack_require__(7).Buffer + +var ZERO_BUF +var subtle = global.crypto && global.crypto.subtle +var toBrowser = { + 'sha': 'SHA-1', + 'sha-1': 'SHA-1', + 'sha1': 'SHA-1', + 'sha256': 'SHA-256', + 'sha-256': 'SHA-256', + 'sha384': 'SHA-384', + 'sha-384': 'SHA-384', + 'sha-512': 'SHA-512', + 'sha512': 'SHA-512' +} +var checks = [] +function checkNative (algo) { + if (global.process && !global.process.browser) { + return Promise.resolve(false) + } + if (!subtle || !subtle.importKey || !subtle.deriveBits) { + return Promise.resolve(false) + } + if (checks[algo] !== undefined) { + return checks[algo] + } + ZERO_BUF = ZERO_BUF || Buffer.alloc(8) + var prom = browserPbkdf2(ZERO_BUF, ZERO_BUF, 10, 128, algo) + .then(function () { + return true + }).catch(function () { + return false + }) + checks[algo] = prom + return prom +} +function browserPbkdf2 (password, salt, iterations, length, algo) { + return subtle.importKey( + 'raw', password, {name: 'PBKDF2'}, false, ['deriveBits'] + ).then(function (key) { + return subtle.deriveBits({ + name: 'PBKDF2', + salt: salt, + iterations: iterations, + hash: { + name: algo + } + }, key, length << 3) + }).then(function (res) { + return Buffer.from(res) + }) +} +function resolvePromise (promise, callback) { + promise.then(function (out) { + process.nextTick(function () { + callback(null, out) + }) + }, function (e) { + process.nextTick(function () { + callback(e) + }) + }) +} +module.exports = function (password, salt, iterations, keylen, digest, callback) { + if (!Buffer.isBuffer(password)) password = Buffer.from(password, defaultEncoding) + if (!Buffer.isBuffer(salt)) salt = Buffer.from(salt, defaultEncoding) + + checkParameters(iterations, keylen) + if (typeof digest === 'function') { + callback = digest + digest = undefined + } + if (typeof callback !== 'function') throw new Error('No callback provided to pbkdf2') + + digest = digest || 'sha1' + var algo = toBrowser[digest.toLowerCase()] + if (!algo || typeof global.Promise !== 'function') { + return process.nextTick(function () { + var out + try { + out = sync(password, salt, iterations, keylen, digest) + } catch (e) { + return callback(e) + } + callback(null, out) + }) + } + resolvePromise(checkNative(algo).then(function (resp) { + if (resp) { + return browserPbkdf2(password, salt, iterations, keylen, algo) + } else { + return sync(password, salt, iterations, keylen, digest) + } + }), callback) +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) +/***/ }), +/* 423 */ +/***/ (function(module, exports, __webpack_require__) { -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +var ebtk = __webpack_require__(68) +var aes = __webpack_require__(108) +var DES = __webpack_require__(427) +var desModes = __webpack_require__(433) +var aesModes = __webpack_require__(70) +function createCipher (suite, password) { + var keyLen, ivLen + suite = suite.toLowerCase() + if (aesModes[suite]) { + keyLen = aesModes[suite].key + ivLen = aesModes[suite].iv + } else if (desModes[suite]) { + keyLen = desModes[suite].key * 8 + ivLen = desModes[suite].iv + } else { + throw new TypeError('invalid suite type') + } + var keys = ebtk(password, false, keyLen, ivLen) + return createCipheriv(suite, keys.key, keys.iv) +} +function createDecipher (suite, password) { + var keyLen, ivLen + suite = suite.toLowerCase() + if (aesModes[suite]) { + keyLen = aesModes[suite].key + ivLen = aesModes[suite].iv + } else if (desModes[suite]) { + keyLen = desModes[suite].key * 8 + ivLen = desModes[suite].iv + } else { + throw new TypeError('invalid suite type') + } + var keys = ebtk(password, false, keyLen, ivLen) + return createDecipheriv(suite, keys.key, keys.iv) +} -var DOMPropertyOperations = __webpack_require__(93); -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); +function createCipheriv (suite, key, iv) { + suite = suite.toLowerCase() + if (aesModes[suite]) { + return aes.createCipheriv(suite, key, iv) + } else if (desModes[suite]) { + return new DES({ + key: key, + iv: iv, + mode: suite + }) + } else { + throw new TypeError('invalid suite type') + } +} +function createDecipheriv (suite, key, iv) { + suite = suite.toLowerCase() + if (aesModes[suite]) { + return aes.createDecipheriv(suite, key, iv) + } else if (desModes[suite]) { + return new DES({ + key: key, + iv: iv, + mode: suite, + decrypt: true + }) + } else { + throw new TypeError('invalid suite type') + } +} +exports.createCipher = exports.Cipher = createCipher +exports.createCipheriv = exports.Cipheriv = createCipheriv +exports.createDecipher = exports.Decipher = createDecipher +exports.createDecipheriv = exports.Decipheriv = createDecipheriv +function getCiphers () { + return Object.keys(desModes).concat(aes.getCiphers()) +} +exports.listCiphers = exports.getCiphers = getCiphers -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); -var didWarnValueLink = false; -var didWarnCheckedLink = false; -var didWarnValueDefaultValue = false; -var didWarnCheckedDefaultChecked = false; -var didWarnControlledToUncontrolled = false; -var didWarnUncontrolledToControlled = false; +/***/ }), +/* 424 */ +/***/ (function(module, exports, __webpack_require__) { -function forceUpdateIfMounted() { - if (this._rootNodeID) { - // DOM component is still mounted; update - ReactDOMInput.updateWrapper(this); +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var modes = __webpack_require__(70) +var ebtk = __webpack_require__(68) +var StreamCipher = __webpack_require__(181) +var AuthCipher = __webpack_require__(182) +inherits(Cipher, Transform) +function Cipher (mode, key, iv) { + if (!(this instanceof Cipher)) { + return new Cipher(mode, key, iv) + } + Transform.call(this) + this._cache = new Splitter() + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + iv.copy(this._prev) + this._mode = mode + this._autopadding = true +} +Cipher.prototype._update = function (data) { + this._cache.add(data) + var chunk + var thing + var out = [] + while ((chunk = this._cache.get())) { + thing = this._mode.encrypt(this, chunk) + out.push(thing) + } + return Buffer.concat(out) +} +Cipher.prototype._final = function () { + var chunk = this._cache.flush() + if (this._autopadding) { + chunk = this._mode.encrypt(this, chunk) + this._cipher.scrub() + return chunk + } else if (chunk.toString('hex') !== '10101010101010101010101010101010') { + this._cipher.scrub() + throw new Error('data not multiple of block length') } } +Cipher.prototype.setAutoPadding = function (setTo) { + this._autopadding = !!setTo + return this +} -function isControlled(props) { - var usesChecked = props.type === 'checkbox' || props.type === 'radio'; - return usesChecked ? props.checked != null : props.value != null; +function Splitter () { + if (!(this instanceof Splitter)) { + return new Splitter() + } + this.cache = new Buffer('') +} +Splitter.prototype.add = function (data) { + this.cache = Buffer.concat([this.cache, data]) } -/** - * Implements an <input> host component that allows setting these optional - * props: `checked`, `value`, `defaultChecked`, and `defaultValue`. - * - * If `checked` or `value` are not supplied (or null/undefined), user actions - * that affect the checked state or value will trigger updates to the element. - * - * If they are supplied (and not null/undefined), the rendered element will not - * trigger updates to the element. Instead, the props must change in order for - * the rendered element to be updated. - * - * The rendered element will be initialized as unchecked (or `defaultChecked`) - * with an empty value (or `defaultValue`). - * - * @see http://www.w3.org/TR/2012/WD-html5-20121025/the-input-element.html - */ -var ReactDOMInput = { - getHostProps: function (inst, props) { - var value = LinkedValueUtils.getValue(props); - var checked = LinkedValueUtils.getChecked(props); +Splitter.prototype.get = function () { + if (this.cache.length > 15) { + var out = this.cache.slice(0, 16) + this.cache = this.cache.slice(16) + return out + } + return null +} +Splitter.prototype.flush = function () { + var len = 16 - this.cache.length + var padBuff = new Buffer(len) - var hostProps = _assign({ - // Make sure we set .type before any other properties (setting .value - // before .type means .value is lost in IE11 and below) - type: undefined, - // Make sure we set .step before .value (setting .value before .step - // means .value is rounded on mount, based upon step precision) - step: undefined, - // Make sure we set .min & .max before .value (to ensure proper order - // in corner cases such as min or max deriving from value, e.g. Issue #7170) - min: undefined, - max: undefined - }, props, { - defaultChecked: undefined, - defaultValue: undefined, - value: value != null ? value : inst._wrapperState.initialValue, - checked: checked != null ? checked : inst._wrapperState.initialChecked, - onChange: inst._wrapperState.onChange - }); + var i = -1 + while (++i < len) { + padBuff.writeUInt8(len, i) + } + var out = Buffer.concat([this.cache, padBuff]) + return out +} +var modelist = { + ECB: __webpack_require__(183), + CBC: __webpack_require__(184), + CFB: __webpack_require__(185), + CFB8: __webpack_require__(186), + CFB1: __webpack_require__(187), + OFB: __webpack_require__(188), + CTR: __webpack_require__(71), + GCM: __webpack_require__(71) +} - return hostProps; - }, +function createCipheriv (suite, password, iv) { + var config = modes[suite.toLowerCase()] + if (!config) { + throw new TypeError('invalid suite type') + } + if (typeof iv === 'string') { + iv = new Buffer(iv) + } + if (typeof password === 'string') { + password = new Buffer(password) + } + if (password.length !== config.key / 8) { + throw new TypeError('invalid key length ' + password.length) + } + if (iv.length !== config.iv) { + throw new TypeError('invalid iv length ' + iv.length) + } + if (config.type === 'stream') { + return new StreamCipher(modelist[config.mode], password, iv) + } else if (config.type === 'auth') { + return new AuthCipher(modelist[config.mode], password, iv) + } + return new Cipher(modelist[config.mode], password, iv) +} +function createCipher (suite, password) { + var config = modes[suite.toLowerCase()] + if (!config) { + throw new TypeError('invalid suite type') + } + var keys = ebtk(password, false, config.key, config.iv) + return createCipheriv(suite, keys.key, keys.iv) +} - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - LinkedValueUtils.checkPropTypes('input', props, inst._currentElement._owner); +exports.createCipheriv = createCipheriv +exports.createCipher = createCipher - var owner = inst._currentElement._owner; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } - if (props.checkedLink !== undefined && !didWarnCheckedLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`checkedLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnCheckedLink = true; - } - if (props.checked !== undefined && props.defaultChecked !== undefined && !didWarnCheckedDefaultChecked) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both checked and defaultChecked props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnCheckedDefaultChecked = true; - } - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both value and defaultValue props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnValueDefaultValue = true; - } - } +/***/ }), +/* 425 */ +/***/ (function(module, exports, __webpack_require__) { - var defaultValue = props.defaultValue; - inst._wrapperState = { - initialChecked: props.checked != null ? props.checked : props.defaultChecked, - initialValue: props.value != null ? props.value : defaultValue, - listeners: null, - onChange: _handleChange.bind(inst), - controlled: isControlled(props) - }; - }, +/* WEBPACK VAR INJECTION */(function(Buffer) {var zeros = new Buffer(16) +zeros.fill(0) +module.exports = GHASH +function GHASH (key) { + this.h = key + this.state = new Buffer(16) + this.state.fill(0) + this.cache = new Buffer('') +} +// from http://bitwiseshiftleft.github.io/sjcl/doc/symbols/src/core_gcm.js.html +// by Juho Vähä-Herttua +GHASH.prototype.ghash = function (block) { + var i = -1 + while (++i < block.length) { + this.state[i] ^= block[i] + } + this._multiply() +} - updateWrapper: function (inst) { - var props = inst._currentElement.props; +GHASH.prototype._multiply = function () { + var Vi = toArray(this.h) + var Zi = [0, 0, 0, 0] + var j, xi, lsb_Vi + var i = -1 + while (++i < 128) { + xi = (this.state[~~(i / 8)] & (1 << (7 - i % 8))) !== 0 + if (xi) { + // Z_i+1 = Z_i ^ V_i + Zi = xor(Zi, Vi) + } - if (process.env.NODE_ENV !== 'production') { - var controlled = isControlled(props); - var owner = inst._currentElement._owner; + // Store the value of LSB(V_i) + lsb_Vi = (Vi[3] & 1) !== 0 - if (!inst._wrapperState.controlled && controlled && !didWarnUncontrolledToControlled) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing an uncontrolled input of type %s to be controlled. ' + 'Input elements should not switch from uncontrolled to controlled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnUncontrolledToControlled = true; - } - if (inst._wrapperState.controlled && !controlled && !didWarnControlledToUncontrolled) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing a controlled input of type %s to be uncontrolled. ' + 'Input elements should not switch from controlled to uncontrolled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnControlledToUncontrolled = true; - } + // V_i+1 = V_i >> 1 + for (j = 3; j > 0; j--) { + Vi[j] = (Vi[j] >>> 1) | ((Vi[j - 1] & 1) << 31) } + Vi[0] = Vi[0] >>> 1 - // TODO: Shouldn't this be getChecked(props)? - var checked = props.checked; - if (checked != null) { - DOMPropertyOperations.setValueForProperty(ReactDOMComponentTree.getNodeFromInstance(inst), 'checked', checked || false); + // If LSB(V_i) is 1, V_i+1 = (V_i >> 1) ^ R + if (lsb_Vi) { + Vi[0] = Vi[0] ^ (0xe1 << 24) } + } + this.state = fromArray(Zi) +} +GHASH.prototype.update = function (buf) { + this.cache = Buffer.concat([this.cache, buf]) + var chunk + while (this.cache.length >= 16) { + chunk = this.cache.slice(0, 16) + this.cache = this.cache.slice(16) + this.ghash(chunk) + } +} +GHASH.prototype.final = function (abl, bl) { + if (this.cache.length) { + this.ghash(Buffer.concat([this.cache, zeros], 16)) + } + this.ghash(fromArray([ + 0, abl, + 0, bl + ])) + return this.state +} - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var value = LinkedValueUtils.getValue(props); - if (value != null) { - if (value === 0 && node.value === '') { - node.value = '0'; - // Note: IE9 reports a number inputs as 'text', so check props instead. - } else if (props.type === 'number') { - // Simulate `input.valueAsNumber`. IE9 does not support it - var valueAsNumber = parseFloat(node.value, 10) || 0; - - if ( - // eslint-disable-next-line - value != valueAsNumber || - // eslint-disable-next-line - value == valueAsNumber && node.value != value) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - node.value = '' + value; - } - } else if (node.value !== '' + value) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - node.value = '' + value; - } - } else { - if (props.value == null && props.defaultValue != null) { - // In Chrome, assigning defaultValue to certain input types triggers input validation. - // For number inputs, the display value loses trailing decimal points. For email inputs, - // Chrome raises "The specified value <x> is not a valid email address". - // - // Here we check to see if the defaultValue has actually changed, avoiding these problems - // when the user is inputting text - // - // https://github.com/facebook/react/issues/7253 - if (node.defaultValue !== '' + props.defaultValue) { - node.defaultValue = '' + props.defaultValue; - } - } - if (props.checked == null && props.defaultChecked != null) { - node.defaultChecked = !!props.defaultChecked; - } - } - }, +function toArray (buf) { + return [ + buf.readUInt32BE(0), + buf.readUInt32BE(4), + buf.readUInt32BE(8), + buf.readUInt32BE(12) + ] +} +function fromArray (out) { + out = out.map(fixup_uint32) + var buf = new Buffer(16) + buf.writeUInt32BE(out[0], 0) + buf.writeUInt32BE(out[1], 4) + buf.writeUInt32BE(out[2], 8) + buf.writeUInt32BE(out[3], 12) + return buf +} +var uint_max = Math.pow(2, 32) +function fixup_uint32 (x) { + var ret, x_pos + ret = x > uint_max || x < 0 ? (x_pos = Math.abs(x) % uint_max, x < 0 ? uint_max - x_pos : x_pos) : x + return ret +} +function xor (a, b) { + return [ + a[0] ^ b[0], + a[1] ^ b[1], + a[2] ^ b[2], + a[3] ^ b[3] + ] +} - postMountWrapper: function (inst) { - var props = inst._currentElement.props; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - // This is in postMount because we need access to the DOM node, which is not - // available until after the component has mounted. - var node = ReactDOMComponentTree.getNodeFromInstance(inst); +/***/ }), +/* 426 */ +/***/ (function(module, exports, __webpack_require__) { - // Detach value from defaultValue. We won't do anything if we're working on - // submit or reset inputs as those values & defaultValues are linked. They - // are not resetable nodes so this operation doesn't matter and actually - // removes browser-default values (eg "Submit Query") when no value is - // provided. +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var modes = __webpack_require__(70) +var StreamCipher = __webpack_require__(181) +var AuthCipher = __webpack_require__(182) +var ebtk = __webpack_require__(68) + +inherits(Decipher, Transform) +function Decipher (mode, key, iv) { + if (!(this instanceof Decipher)) { + return new Decipher(mode, key, iv) + } + Transform.call(this) + this._cache = new Splitter() + this._last = void 0 + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + iv.copy(this._prev) + this._mode = mode + this._autopadding = true +} +Decipher.prototype._update = function (data) { + this._cache.add(data) + var chunk + var thing + var out = [] + while ((chunk = this._cache.get(this._autopadding))) { + thing = this._mode.decrypt(this, chunk) + out.push(thing) + } + return Buffer.concat(out) +} +Decipher.prototype._final = function () { + var chunk = this._cache.flush() + if (this._autopadding) { + return unpad(this._mode.decrypt(this, chunk)) + } else if (chunk) { + throw new Error('data not multiple of block length') + } +} +Decipher.prototype.setAutoPadding = function (setTo) { + this._autopadding = !!setTo + return this +} +function Splitter () { + if (!(this instanceof Splitter)) { + return new Splitter() + } + this.cache = new Buffer('') +} +Splitter.prototype.add = function (data) { + this.cache = Buffer.concat([this.cache, data]) +} - switch (props.type) { - case 'submit': - case 'reset': - break; - case 'color': - case 'date': - case 'datetime': - case 'datetime-local': - case 'month': - case 'time': - case 'week': - // This fixes the no-show issue on iOS Safari and Android Chrome: - // https://github.com/facebook/react/issues/7233 - node.value = ''; - node.value = node.defaultValue; - break; - default: - node.value = node.value; - break; +Splitter.prototype.get = function (autoPadding) { + var out + if (autoPadding) { + if (this.cache.length > 16) { + out = this.cache.slice(0, 16) + this.cache = this.cache.slice(16) + return out } - - // Normally, we'd just do `node.checked = node.checked` upon initial mount, less this bug - // this is needed to work around a chrome bug where setting defaultChecked - // will sometimes influence the value of checked (even after detachment). - // Reference: https://bugs.chromium.org/p/chromium/issues/detail?id=608416 - // We need to temporarily unset name to avoid disrupting radio button groups. - var name = node.name; - if (name !== '') { - node.name = ''; + } else { + if (this.cache.length >= 16) { + out = this.cache.slice(0, 16) + this.cache = this.cache.slice(16) + return out } - node.defaultChecked = !node.defaultChecked; - node.defaultChecked = !node.defaultChecked; - if (name !== '') { - node.name = name; + } + return null +} +Splitter.prototype.flush = function () { + if (this.cache.length) { + return this.cache + } +} +function unpad (last) { + var padded = last[15] + var i = -1 + while (++i < padded) { + if (last[(i + (16 - padded))] !== padded) { + throw new Error('unable to decrypt data') } } -}; - -function _handleChange(event) { - var props = this._currentElement.props; + if (padded === 16) { + return + } + return last.slice(0, 16 - padded) +} - var returnValue = LinkedValueUtils.executeOnChange(props, event); +var modelist = { + ECB: __webpack_require__(183), + CBC: __webpack_require__(184), + CFB: __webpack_require__(185), + CFB8: __webpack_require__(186), + CFB1: __webpack_require__(187), + OFB: __webpack_require__(188), + CTR: __webpack_require__(71), + GCM: __webpack_require__(71) +} - // Here we use asap to wait until all updates have propagated, which - // is important when using controlled components within layers: - // https://github.com/facebook/react/issues/1698 - ReactUpdates.asap(forceUpdateIfMounted, this); +function createDecipheriv (suite, password, iv) { + var config = modes[suite.toLowerCase()] + if (!config) { + throw new TypeError('invalid suite type') + } + if (typeof iv === 'string') { + iv = new Buffer(iv) + } + if (typeof password === 'string') { + password = new Buffer(password) + } + if (password.length !== config.key / 8) { + throw new TypeError('invalid key length ' + password.length) + } + if (iv.length !== config.iv) { + throw new TypeError('invalid iv length ' + iv.length) + } + if (config.type === 'stream') { + return new StreamCipher(modelist[config.mode], password, iv, true) + } else if (config.type === 'auth') { + return new AuthCipher(modelist[config.mode], password, iv, true) + } + return new Decipher(modelist[config.mode], password, iv) +} - var name = props.name; - if (props.type === 'radio' && name != null) { - var rootNode = ReactDOMComponentTree.getNodeFromInstance(this); - var queryRoot = rootNode; +function createDecipher (suite, password) { + var config = modes[suite.toLowerCase()] + if (!config) { + throw new TypeError('invalid suite type') + } + var keys = ebtk(password, false, config.key, config.iv) + return createDecipheriv(suite, keys.key, keys.iv) +} +exports.createDecipher = createDecipher +exports.createDecipheriv = createDecipheriv - while (queryRoot.parentNode) { - queryRoot = queryRoot.parentNode; - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - // If `rootNode.form` was non-null, then we could try `form.elements`, - // but that sometimes behaves strangely in IE8. We could also try using - // `form.getElementsByName`, but that will only return direct children - // and won't include inputs that use the HTML5 `form=` attribute. Since - // the input might not even be in a form, let's just use the global - // `querySelectorAll` to ensure we don't miss anything. - var group = queryRoot.querySelectorAll('input[name=' + JSON.stringify('' + name) + '][type="radio"]'); +/***/ }), +/* 427 */ +/***/ (function(module, exports, __webpack_require__) { - for (var i = 0; i < group.length; i++) { - var otherNode = group[i]; - if (otherNode === rootNode || otherNode.form !== rootNode.form) { - continue; - } - // This will throw if radio buttons rendered by different copies of React - // and the same name are rendered into the same form (same as #1939). - // That's probably okay; we don't support it just as we don't support - // mixing React radio buttons with non-React ones. - var otherInstance = ReactDOMComponentTree.getInstanceFromNode(otherNode); - !otherInstance ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOMInput: Mixing React and non-React radio inputs with the same `name` is not supported.') : _prodInvariant('90') : void 0; - // If this is a controlled radio button group, forcing the input that - // was previously checked to update will cause it to be come re-checked - // as appropriate. - ReactUpdates.asap(forceUpdateIfMounted, otherInstance); - } +/* WEBPACK VAR INJECTION */(function(Buffer) {var CipherBase = __webpack_require__(29) +var des = __webpack_require__(109) +var inherits = __webpack_require__(4) + +var modes = { + 'des-ede3-cbc': des.CBC.instantiate(des.EDE), + 'des-ede3': des.EDE, + 'des-ede-cbc': des.CBC.instantiate(des.EDE), + 'des-ede': des.EDE, + 'des-cbc': des.CBC.instantiate(des.DES), + 'des-ecb': des.DES +} +modes.des = modes['des-cbc'] +modes.des3 = modes['des-ede3-cbc'] +module.exports = DES +inherits(DES, CipherBase) +function DES (opts) { + CipherBase.call(this) + var modeName = opts.mode.toLowerCase() + var mode = modes[modeName] + var type + if (opts.decrypt) { + type = 'decrypt' + } else { + type = 'encrypt' } - - return returnValue; + var key = opts.key + if (modeName === 'des-ede' || modeName === 'des-ede-cbc') { + key = Buffer.concat([key, key.slice(0, 8)]) + } + var iv = opts.iv + this._des = mode.create({ + key: key, + iv: iv, + type: type + }) +} +DES.prototype._update = function (data) { + return new Buffer(this._des.update(data)) +} +DES.prototype._final = function () { + return new Buffer(this._des.final()) } -module.exports = ReactDOMInput; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 172 */ +/* 428 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - -var _assign = __webpack_require__(5); +exports.readUInt32BE = function readUInt32BE(bytes, off) { + var res = (bytes[0 + off] << 24) | + (bytes[1 + off] << 16) | + (bytes[2 + off] << 8) | + bytes[3 + off]; + return res >>> 0; +}; -var React = __webpack_require__(24); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMSelect = __webpack_require__(95); +exports.writeUInt32BE = function writeUInt32BE(bytes, value, off) { + bytes[0 + off] = value >>> 24; + bytes[1 + off] = (value >>> 16) & 0xff; + bytes[2 + off] = (value >>> 8) & 0xff; + bytes[3 + off] = value & 0xff; +}; -var warning = __webpack_require__(2); -var didWarnInvalidOptionChildren = false; +exports.ip = function ip(inL, inR, out, off) { + var outL = 0; + var outR = 0; -function flattenChildren(children) { - var content = ''; + for (var i = 6; i >= 0; i -= 2) { + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inR >>> (j + i)) & 1; + } + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inL >>> (j + i)) & 1; + } + } - // Flatten children and warn if they aren't strings or numbers; - // invalid types are ignored. - React.Children.forEach(children, function (child) { - if (child == null) { - return; + for (var i = 6; i >= 0; i -= 2) { + for (var j = 1; j <= 25; j += 8) { + outR <<= 1; + outR |= (inR >>> (j + i)) & 1; } - if (typeof child === 'string' || typeof child === 'number') { - content += child; - } else if (!didWarnInvalidOptionChildren) { - didWarnInvalidOptionChildren = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Only strings and numbers are supported as <option> children.') : void 0; + for (var j = 1; j <= 25; j += 8) { + outR <<= 1; + outR |= (inL >>> (j + i)) & 1; } - }); + } - return content; -} + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; -/** - * Implements an <option> host component that warns when `selected` is set. - */ -var ReactDOMOption = { - mountWrapper: function (inst, props, hostParent) { - // TODO (yungsters): Remove support for `selected` in <option>. - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(props.selected == null, 'Use the `defaultValue` or `value` props on <select> instead of ' + 'setting `selected` on <option>.') : void 0; - } +exports.rip = function rip(inL, inR, out, off) { + var outL = 0; + var outR = 0; - // Look up whether this option is 'selected' - var selectValue = null; - if (hostParent != null) { - var selectParent = hostParent; + for (var i = 0; i < 4; i++) { + for (var j = 24; j >= 0; j -= 8) { + outL <<= 1; + outL |= (inR >>> (j + i)) & 1; + outL <<= 1; + outL |= (inL >>> (j + i)) & 1; + } + } + for (var i = 4; i < 8; i++) { + for (var j = 24; j >= 0; j -= 8) { + outR <<= 1; + outR |= (inR >>> (j + i)) & 1; + outR <<= 1; + outR |= (inL >>> (j + i)) & 1; + } + } - if (selectParent._tag === 'optgroup') { - selectParent = selectParent._hostParent; - } + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; - if (selectParent != null && selectParent._tag === 'select') { - selectValue = ReactDOMSelect.getSelectValueContext(selectParent); - } +exports.pc1 = function pc1(inL, inR, out, off) { + var outL = 0; + var outR = 0; + + // 7, 15, 23, 31, 39, 47, 55, 63 + // 6, 14, 22, 30, 39, 47, 55, 63 + // 5, 13, 21, 29, 39, 47, 55, 63 + // 4, 12, 20, 28 + for (var i = 7; i >= 5; i--) { + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inR >> (j + i)) & 1; } + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inL >> (j + i)) & 1; + } + } + for (var j = 0; j <= 24; j += 8) { + outL <<= 1; + outL |= (inR >> (j + i)) & 1; + } - // If the value is null (e.g., no specified value or after initial mount) - // or missing (e.g., for <datalist>), we don't change props.selected - var selected = null; - if (selectValue != null) { - var value; - if (props.value != null) { - value = props.value + ''; - } else { - value = flattenChildren(props.children); - } - selected = false; - if (Array.isArray(selectValue)) { - // multiple - for (var i = 0; i < selectValue.length; i++) { - if ('' + selectValue[i] === value) { - selected = true; - break; - } - } - } else { - selected = '' + selectValue === value; - } + // 1, 9, 17, 25, 33, 41, 49, 57 + // 2, 10, 18, 26, 34, 42, 50, 58 + // 3, 11, 19, 27, 35, 43, 51, 59 + // 36, 44, 52, 60 + for (var i = 1; i <= 3; i++) { + for (var j = 0; j <= 24; j += 8) { + outR <<= 1; + outR |= (inR >> (j + i)) & 1; + } + for (var j = 0; j <= 24; j += 8) { + outR <<= 1; + outR |= (inL >> (j + i)) & 1; } + } + for (var j = 0; j <= 24; j += 8) { + outR <<= 1; + outR |= (inL >> (j + i)) & 1; + } - inst._wrapperState = { selected: selected }; - }, + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; - postMountWrapper: function (inst) { - // value="" should make a value attribute (#6219) - var props = inst._currentElement.props; - if (props.value != null) { - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - node.setAttribute('value', props.value); - } - }, +exports.r28shl = function r28shl(num, shift) { + return ((num << shift) & 0xfffffff) | (num >>> (28 - shift)); +}; - getHostProps: function (inst, props) { - var hostProps = _assign({ selected: undefined, children: undefined }, props); +var pc2table = [ + // inL => outL + 14, 11, 17, 4, 27, 23, 25, 0, + 13, 22, 7, 18, 5, 9, 16, 24, + 2, 20, 12, 21, 1, 8, 15, 26, - // Read state only from initial mount because <select> updates value - // manually; we need the initial state only for server rendering - if (inst._wrapperState.selected != null) { - hostProps.selected = inst._wrapperState.selected; - } + // inR => outR + 15, 4, 25, 19, 9, 1, 26, 16, + 5, 11, 23, 8, 12, 7, 17, 0, + 22, 3, 10, 14, 6, 20, 27, 24 +]; - var content = flattenChildren(props.children); +exports.pc2 = function pc2(inL, inR, out, off) { + var outL = 0; + var outR = 0; - if (content) { - hostProps.children = content; - } + var len = pc2table.length >>> 1; + for (var i = 0; i < len; i++) { + outL <<= 1; + outL |= (inL >>> pc2table[i]) & 0x1; + } + for (var i = len; i < pc2table.length; i++) { + outR <<= 1; + outR |= (inR >>> pc2table[i]) & 0x1; + } - return hostProps; + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; + +exports.expand = function expand(r, out, off) { + var outL = 0; + var outR = 0; + + outL = ((r & 1) << 5) | (r >>> 27); + for (var i = 23; i >= 15; i -= 4) { + outL <<= 6; + outL |= (r >>> i) & 0x3f; } + for (var i = 11; i >= 3; i -= 4) { + outR |= (r >>> i) & 0x3f; + outR <<= 6; + } + outR |= ((r & 0x1f) << 1) | (r >>> 31); + + out[off + 0] = outL >>> 0; + out[off + 1] = outR >>> 0; +}; + +var sTable = [ + 14, 0, 4, 15, 13, 7, 1, 4, 2, 14, 15, 2, 11, 13, 8, 1, + 3, 10, 10, 6, 6, 12, 12, 11, 5, 9, 9, 5, 0, 3, 7, 8, + 4, 15, 1, 12, 14, 8, 8, 2, 13, 4, 6, 9, 2, 1, 11, 7, + 15, 5, 12, 11, 9, 3, 7, 14, 3, 10, 10, 0, 5, 6, 0, 13, + + 15, 3, 1, 13, 8, 4, 14, 7, 6, 15, 11, 2, 3, 8, 4, 14, + 9, 12, 7, 0, 2, 1, 13, 10, 12, 6, 0, 9, 5, 11, 10, 5, + 0, 13, 14, 8, 7, 10, 11, 1, 10, 3, 4, 15, 13, 4, 1, 2, + 5, 11, 8, 6, 12, 7, 6, 12, 9, 0, 3, 5, 2, 14, 15, 9, + + 10, 13, 0, 7, 9, 0, 14, 9, 6, 3, 3, 4, 15, 6, 5, 10, + 1, 2, 13, 8, 12, 5, 7, 14, 11, 12, 4, 11, 2, 15, 8, 1, + 13, 1, 6, 10, 4, 13, 9, 0, 8, 6, 15, 9, 3, 8, 0, 7, + 11, 4, 1, 15, 2, 14, 12, 3, 5, 11, 10, 5, 14, 2, 7, 12, + + 7, 13, 13, 8, 14, 11, 3, 5, 0, 6, 6, 15, 9, 0, 10, 3, + 1, 4, 2, 7, 8, 2, 5, 12, 11, 1, 12, 10, 4, 14, 15, 9, + 10, 3, 6, 15, 9, 0, 0, 6, 12, 10, 11, 1, 7, 13, 13, 8, + 15, 9, 1, 4, 3, 5, 14, 11, 5, 12, 2, 7, 8, 2, 4, 14, + + 2, 14, 12, 11, 4, 2, 1, 12, 7, 4, 10, 7, 11, 13, 6, 1, + 8, 5, 5, 0, 3, 15, 15, 10, 13, 3, 0, 9, 14, 8, 9, 6, + 4, 11, 2, 8, 1, 12, 11, 7, 10, 1, 13, 14, 7, 2, 8, 13, + 15, 6, 9, 15, 12, 0, 5, 9, 6, 10, 3, 4, 0, 5, 14, 3, + + 12, 10, 1, 15, 10, 4, 15, 2, 9, 7, 2, 12, 6, 9, 8, 5, + 0, 6, 13, 1, 3, 13, 4, 14, 14, 0, 7, 11, 5, 3, 11, 8, + 9, 4, 14, 3, 15, 2, 5, 12, 2, 9, 8, 5, 12, 15, 3, 10, + 7, 11, 0, 14, 4, 1, 10, 7, 1, 6, 13, 0, 11, 8, 6, 13, + + 4, 13, 11, 0, 2, 11, 14, 7, 15, 4, 0, 9, 8, 1, 13, 10, + 3, 14, 12, 3, 9, 5, 7, 12, 5, 2, 10, 15, 6, 8, 1, 6, + 1, 6, 4, 11, 11, 13, 13, 8, 12, 1, 3, 4, 7, 10, 14, 7, + 10, 9, 15, 5, 6, 0, 8, 15, 0, 14, 5, 2, 9, 3, 2, 12, + + 13, 1, 2, 15, 8, 13, 4, 8, 6, 10, 15, 3, 11, 7, 1, 4, + 10, 12, 9, 5, 3, 6, 14, 11, 5, 0, 0, 14, 12, 9, 7, 2, + 7, 2, 11, 1, 4, 14, 1, 7, 9, 4, 12, 10, 14, 8, 2, 13, + 0, 15, 6, 12, 10, 9, 13, 0, 15, 3, 3, 5, 5, 6, 8, 11 +]; + +exports.substitute = function substitute(inL, inR) { + var out = 0; + for (var i = 0; i < 4; i++) { + var b = (inL >>> (18 - i * 6)) & 0x3f; + var sb = sTable[i * 0x40 + b]; + + out <<= 4; + out |= sb; + } + for (var i = 0; i < 4; i++) { + var b = (inR >>> (18 - i * 6)) & 0x3f; + var sb = sTable[4 * 0x40 + i * 0x40 + b]; + + out <<= 4; + out |= sb; + } + return out >>> 0; +}; + +var permuteTable = [ + 16, 25, 12, 11, 3, 20, 4, 15, 31, 17, 9, 6, 27, 14, 1, 22, + 30, 24, 8, 18, 0, 5, 29, 23, 13, 19, 2, 26, 10, 21, 28, 7 +]; + +exports.permute = function permute(num) { + var out = 0; + for (var i = 0; i < permuteTable.length; i++) { + out <<= 1; + out |= (num >>> permuteTable[i]) & 0x1; + } + return out >>> 0; +}; + +exports.padSplit = function padSplit(num, size, group) { + var str = num.toString(2); + while (str.length < size) + str = '0' + str; + + var out = []; + for (var i = 0; i < size; i += group) + out.push(str.slice(i, i + group)); + return out.join(' '); }; -module.exports = ReactDOMOption; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 173 */ +/* 429 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var assert = __webpack_require__(21); -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +function Cipher(options) { + this.options = options; -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); + this.type = this.options.type; + this.blockSize = 8; + this._init(); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); + this.buffer = new Array(this.blockSize); + this.bufferOff = 0; +} +module.exports = Cipher; -var didWarnValueLink = false; -var didWarnValDefaultVal = false; +Cipher.prototype._init = function _init() { + // Might be overrided +}; -function forceUpdateIfMounted() { - if (this._rootNodeID) { - // DOM component is still mounted; update - ReactDOMTextarea.updateWrapper(this); - } -} +Cipher.prototype.update = function update(data) { + if (data.length === 0) + return []; -/** - * Implements a <textarea> host component that allows setting `value`, and - * `defaultValue`. This differs from the traditional DOM API because value is - * usually set as PCDATA children. - * - * If `value` is not supplied (or null/undefined), user actions that affect the - * value will trigger updates to the element. - * - * If `value` is supplied (and not null/undefined), the rendered element will - * not trigger updates to the element. Instead, the `value` prop must change in - * order for the rendered element to be updated. - * - * The rendered element will be initialized with an empty value, the prop - * `defaultValue` if specified, or the children content (deprecated). - */ -var ReactDOMTextarea = { - getHostProps: function (inst, props) { - !(props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`dangerouslySetInnerHTML` does not make sense on <textarea>.') : _prodInvariant('91') : void 0; + if (this.type === 'decrypt') + return this._updateDecrypt(data); + else + return this._updateEncrypt(data); +}; - // Always set children to the same thing. In IE9, the selection range will - // get reset if `textContent` is mutated. We could add a check in setTextContent - // to only set the value if/when the value differs from the node value (which would - // completely solve this IE9 bug), but Sebastian+Ben seemed to like this solution. - // The value can be a boolean or object so that's why it's forced to be a string. - var hostProps = _assign({}, props, { - value: undefined, - defaultValue: undefined, - children: '' + inst._wrapperState.initialValue, - onChange: inst._wrapperState.onChange - }); +Cipher.prototype._buffer = function _buffer(data, off) { + // Append data to buffer + var min = Math.min(this.buffer.length - this.bufferOff, data.length - off); + for (var i = 0; i < min; i++) + this.buffer[this.bufferOff + i] = data[off + i]; + this.bufferOff += min; - return hostProps; - }, + // Shift next + return min; +}; - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - LinkedValueUtils.checkPropTypes('textarea', props, inst._currentElement._owner); - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `textarea` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValDefaultVal) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Textarea elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; - didWarnValDefaultVal = true; - } - } +Cipher.prototype._flushBuffer = function _flushBuffer(out, off) { + this._update(this.buffer, 0, out, off); + this.bufferOff = 0; + return this.blockSize; +}; - var value = LinkedValueUtils.getValue(props); - var initialValue = value; +Cipher.prototype._updateEncrypt = function _updateEncrypt(data) { + var inputOff = 0; + var outputOff = 0; - // Only bother fetching default value if we're going to use it - if (value == null) { - var defaultValue = props.defaultValue; - // TODO (yungsters): Remove support for children content in <textarea>. - var children = props.children; - if (children != null) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(false, 'Use the `defaultValue` or `value` props instead of setting ' + 'children on <textarea>.') : void 0; - } - !(defaultValue == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'If you supply `defaultValue` on a <textarea>, do not pass children.') : _prodInvariant('92') : void 0; - if (Array.isArray(children)) { - !(children.length <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, '<textarea> can only have at most one child.') : _prodInvariant('93') : void 0; - children = children[0]; - } + var count = ((this.bufferOff + data.length) / this.blockSize) | 0; + var out = new Array(count * this.blockSize); - defaultValue = '' + children; - } - if (defaultValue == null) { - defaultValue = ''; - } - initialValue = defaultValue; - } + if (this.bufferOff !== 0) { + inputOff += this._buffer(data, inputOff); - inst._wrapperState = { - initialValue: '' + initialValue, - listeners: null, - onChange: _handleChange.bind(inst) - }; - }, + if (this.bufferOff === this.buffer.length) + outputOff += this._flushBuffer(out, outputOff); + } - updateWrapper: function (inst) { - var props = inst._currentElement.props; + // Write blocks + var max = data.length - ((data.length - inputOff) % this.blockSize); + for (; inputOff < max; inputOff += this.blockSize) { + this._update(data, inputOff, out, outputOff); + outputOff += this.blockSize; + } - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var value = LinkedValueUtils.getValue(props); - if (value != null) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - var newValue = '' + value; + // Queue rest + for (; inputOff < data.length; inputOff++, this.bufferOff++) + this.buffer[this.bufferOff] = data[inputOff]; - // To avoid side effects (such as losing text selection), only set value if changed - if (newValue !== node.value) { - node.value = newValue; - } - if (props.defaultValue == null) { - node.defaultValue = newValue; - } - } - if (props.defaultValue != null) { - node.defaultValue = props.defaultValue; - } - }, + return out; +}; - postMountWrapper: function (inst) { - // This is in postMount because we need access to the DOM node, which is not - // available until after the component has mounted. - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var textContent = node.textContent; +Cipher.prototype._updateDecrypt = function _updateDecrypt(data) { + var inputOff = 0; + var outputOff = 0; - // Only set node.value if textContent is equal to the expected - // initial value. In IE10/IE11 there is a bug where the placeholder attribute - // will populate textContent as well. - // https://developer.microsoft.com/microsoft-edge/platform/issues/101525/ - if (textContent === inst._wrapperState.initialValue) { - node.value = textContent; - } + var count = Math.ceil((this.bufferOff + data.length) / this.blockSize) - 1; + var out = new Array(count * this.blockSize); + + // TODO(indutny): optimize it, this is far from optimal + for (; count > 0; count--) { + inputOff += this._buffer(data, inputOff); + outputOff += this._flushBuffer(out, outputOff); } + + // Buffer rest of the input + inputOff += this._buffer(data, inputOff); + + return out; }; -function _handleChange(event) { - var props = this._currentElement.props; - var returnValue = LinkedValueUtils.executeOnChange(props, event); - ReactUpdates.asap(forceUpdateIfMounted, this); - return returnValue; -} +Cipher.prototype.final = function final(buffer) { + var first; + if (buffer) + first = this.update(buffer); + + var last; + if (this.type === 'encrypt') + last = this._finalEncrypt(); + else + last = this._finalDecrypt(); + + if (first) + return first.concat(last); + else + return last; +}; + +Cipher.prototype._pad = function _pad(buffer, off) { + if (off === 0) + return false; + + while (off < buffer.length) + buffer[off++] = 0; + + return true; +}; + +Cipher.prototype._finalEncrypt = function _finalEncrypt() { + if (!this._pad(this.buffer, this.bufferOff)) + return []; + + var out = new Array(this.blockSize); + this._update(this.buffer, 0, out, 0); + return out; +}; + +Cipher.prototype._unpad = function _unpad(buffer) { + return buffer; +}; + +Cipher.prototype._finalDecrypt = function _finalDecrypt() { + assert.equal(this.bufferOff, this.blockSize, 'Not enough data to decrypt'); + var out = new Array(this.blockSize); + this._flushBuffer(out, 0); + + return this._unpad(out); +}; -module.exports = ReactDOMTextarea; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 174 */ +/* 430 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); -var _prodInvariant = __webpack_require__(3); +var des = __webpack_require__(109); +var utils = des.utils; +var Cipher = des.Cipher; -var ReactComponentEnvironment = __webpack_require__(59); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); +function DESState() { + this.tmp = new Array(2); + this.keys = null; +} -var ReactCurrentOwner = __webpack_require__(14); -var ReactReconciler = __webpack_require__(26); -var ReactChildReconciler = __webpack_require__(175); +function DES(options) { + Cipher.call(this, options); -var emptyFunction = __webpack_require__(12); -var flattenChildren = __webpack_require__(182); -var invariant = __webpack_require__(1); + var state = new DESState(); + this._desState = state; -/** - * Make an update for markup to be rendered and inserted at a supplied index. - * - * @param {string} markup Markup that renders into an element. - * @param {number} toIndex Destination index. - * @private - */ -function makeInsertMarkup(markup, afterNode, toIndex) { - // NOTE: Null values reduce hidden classes. - return { - type: 'INSERT_MARKUP', - content: markup, - fromIndex: null, - fromNode: null, - toIndex: toIndex, - afterNode: afterNode - }; + this.deriveKeys(state, options.key); } +inherits(DES, Cipher); +module.exports = DES; -/** - * Make an update for moving an existing element to another index. - * - * @param {number} fromIndex Source index of the existing element. - * @param {number} toIndex Destination index of the element. - * @private - */ -function makeMove(child, afterNode, toIndex) { - // NOTE: Null values reduce hidden classes. - return { - type: 'MOVE_EXISTING', - content: null, - fromIndex: child._mountIndex, - fromNode: ReactReconciler.getHostNode(child), - toIndex: toIndex, - afterNode: afterNode - }; -} +DES.create = function create(options) { + return new DES(options); +}; -/** - * Make an update for removing an element at an index. - * - * @param {number} fromIndex Index of the element to remove. - * @private - */ -function makeRemove(child, node) { - // NOTE: Null values reduce hidden classes. - return { - type: 'REMOVE_NODE', - content: null, - fromIndex: child._mountIndex, - fromNode: node, - toIndex: null, - afterNode: null - }; -} +var shiftTable = [ + 1, 1, 2, 2, 2, 2, 2, 2, + 1, 2, 2, 2, 2, 2, 2, 1 +]; -/** - * Make an update for setting the markup of a node. - * - * @param {string} markup Markup that renders into an element. - * @private - */ -function makeSetMarkup(markup) { - // NOTE: Null values reduce hidden classes. - return { - type: 'SET_MARKUP', - content: markup, - fromIndex: null, - fromNode: null, - toIndex: null, - afterNode: null - }; -} +DES.prototype.deriveKeys = function deriveKeys(state, key) { + state.keys = new Array(16 * 2); -/** - * Make an update for setting the text content. - * - * @param {string} textContent Text content to set. - * @private - */ -function makeTextContent(textContent) { - // NOTE: Null values reduce hidden classes. - return { - type: 'TEXT_CONTENT', - content: textContent, - fromIndex: null, - fromNode: null, - toIndex: null, - afterNode: null - }; -} + assert.equal(key.length, this.blockSize, 'Invalid key length'); -/** - * Push an update, if any, onto the queue. Creates a new queue if none is - * passed and always returns the queue. Mutative. - */ -function enqueue(queue, update) { - if (update) { - queue = queue || []; - queue.push(update); + var kL = utils.readUInt32BE(key, 0); + var kR = utils.readUInt32BE(key, 4); + + utils.pc1(kL, kR, state.tmp, 0); + kL = state.tmp[0]; + kR = state.tmp[1]; + for (var i = 0; i < state.keys.length; i += 2) { + var shift = shiftTable[i >>> 1]; + kL = utils.r28shl(kL, shift); + kR = utils.r28shl(kR, shift); + utils.pc2(kL, kR, state.keys, i); } - return queue; -} +}; -/** - * Processes any enqueued updates. - * - * @private - */ -function processQueue(inst, updateQueue) { - ReactComponentEnvironment.processChildrenUpdates(inst, updateQueue); -} +DES.prototype._update = function _update(inp, inOff, out, outOff) { + var state = this._desState; -var setChildrenForInstrumentation = emptyFunction; -if (process.env.NODE_ENV !== 'production') { - var getDebugID = function (inst) { - if (!inst._debugID) { - // Check for ART-like instances. TODO: This is silly/gross. - var internal; - if (internal = ReactInstanceMap.get(inst)) { - inst = internal; - } - } - return inst._debugID; - }; - setChildrenForInstrumentation = function (children) { - var debugID = getDebugID(this); - // TODO: React Native empty components are also multichild. - // This means they still get into this method but don't have _debugID. - if (debugID !== 0) { - ReactInstrumentation.debugTool.onSetChildren(debugID, children ? Object.keys(children).map(function (key) { - return children[key]._debugID; - }) : []); - } - }; -} + var l = utils.readUInt32BE(inp, inOff); + var r = utils.readUInt32BE(inp, inOff + 4); -/** - * ReactMultiChild are capable of reconciling multiple children. - * - * @class ReactMultiChild - * @internal - */ -var ReactMultiChild = { - /** - * Provides common functionality for components that must reconcile multiple - * children. This is used by `ReactDOMComponent` to mount, update, and - * unmount child components. - * - * @lends {ReactMultiChild.prototype} - */ - Mixin: { - _reconcilerInstantiateChildren: function (nestedChildren, transaction, context) { - if (process.env.NODE_ENV !== 'production') { - var selfDebugID = getDebugID(this); - if (this._currentElement) { - try { - ReactCurrentOwner.current = this._currentElement._owner; - return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context, selfDebugID); - } finally { - ReactCurrentOwner.current = null; - } - } - } - return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context); - }, + // Initial Permutation + utils.ip(l, r, state.tmp, 0); + l = state.tmp[0]; + r = state.tmp[1]; - _reconcilerUpdateChildren: function (prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context) { - var nextChildren; - var selfDebugID = 0; - if (process.env.NODE_ENV !== 'production') { - selfDebugID = getDebugID(this); - if (this._currentElement) { - try { - ReactCurrentOwner.current = this._currentElement._owner; - nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); - } finally { - ReactCurrentOwner.current = null; - } - ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); - return nextChildren; - } - } - nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); - ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); - return nextChildren; - }, + if (this.type === 'encrypt') + this._encrypt(state, l, r, state.tmp, 0); + else + this._decrypt(state, l, r, state.tmp, 0); - /** - * Generates a "mount image" for each of the supplied children. In the case - * of `ReactDOMComponent`, a mount image is a string of markup. - * - * @param {?object} nestedChildren Nested child maps. - * @return {array} An array of mounted representations. - * @internal - */ - mountChildren: function (nestedChildren, transaction, context) { - var children = this._reconcilerInstantiateChildren(nestedChildren, transaction, context); - this._renderedChildren = children; + l = state.tmp[0]; + r = state.tmp[1]; - var mountImages = []; - var index = 0; - for (var name in children) { - if (children.hasOwnProperty(name)) { - var child = children[name]; - var selfDebugID = 0; - if (process.env.NODE_ENV !== 'production') { - selfDebugID = getDebugID(this); - } - var mountImage = ReactReconciler.mountComponent(child, transaction, this, this._hostContainerInfo, context, selfDebugID); - child._mountIndex = index++; - mountImages.push(mountImage); - } - } + utils.writeUInt32BE(out, l, outOff); + utils.writeUInt32BE(out, r, outOff + 4); +}; - if (process.env.NODE_ENV !== 'production') { - setChildrenForInstrumentation.call(this, children); - } +DES.prototype._pad = function _pad(buffer, off) { + var value = buffer.length - off; + for (var i = off; i < buffer.length; i++) + buffer[i] = value; - return mountImages; - }, + return true; +}; - /** - * Replaces any rendered children with a text content string. - * - * @param {string} nextContent String of content. - * @internal - */ - updateTextContent: function (nextContent) { - var prevChildren = this._renderedChildren; - // Remove any rendered children. - ReactChildReconciler.unmountChildren(prevChildren, false); - for (var name in prevChildren) { - if (prevChildren.hasOwnProperty(name)) { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; - } - } - // Set new text content. - var updates = [makeTextContent(nextContent)]; - processQueue(this, updates); - }, +DES.prototype._unpad = function _unpad(buffer) { + var pad = buffer[buffer.length - 1]; + for (var i = buffer.length - pad; i < buffer.length; i++) + assert.equal(buffer[i], pad); - /** - * Replaces any rendered children with a markup string. - * - * @param {string} nextMarkup String of markup. - * @internal - */ - updateMarkup: function (nextMarkup) { - var prevChildren = this._renderedChildren; - // Remove any rendered children. - ReactChildReconciler.unmountChildren(prevChildren, false); - for (var name in prevChildren) { - if (prevChildren.hasOwnProperty(name)) { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; - } - } - var updates = [makeSetMarkup(nextMarkup)]; - processQueue(this, updates); - }, + return buffer.slice(0, buffer.length - pad); +}; - /** - * Updates the rendered children with new children. - * - * @param {?object} nextNestedChildrenElements Nested child element maps. - * @param {ReactReconcileTransaction} transaction - * @internal - */ - updateChildren: function (nextNestedChildrenElements, transaction, context) { - // Hook used by React ART - this._updateChildren(nextNestedChildrenElements, transaction, context); - }, +DES.prototype._encrypt = function _encrypt(state, lStart, rStart, out, off) { + var l = lStart; + var r = rStart; - /** - * @param {?object} nextNestedChildrenElements Nested child element maps. - * @param {ReactReconcileTransaction} transaction - * @final - * @protected - */ - _updateChildren: function (nextNestedChildrenElements, transaction, context) { - var prevChildren = this._renderedChildren; - var removedNodes = {}; - var mountImages = []; - var nextChildren = this._reconcilerUpdateChildren(prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context); - if (!nextChildren && !prevChildren) { - return; - } - var updates = null; - var name; - // `nextIndex` will increment for each child in `nextChildren`, but - // `lastIndex` will be the last index visited in `prevChildren`. - var nextIndex = 0; - var lastIndex = 0; - // `nextMountIndex` will increment for each newly mounted child. - var nextMountIndex = 0; - var lastPlacedNode = null; - for (name in nextChildren) { - if (!nextChildren.hasOwnProperty(name)) { - continue; - } - var prevChild = prevChildren && prevChildren[name]; - var nextChild = nextChildren[name]; - if (prevChild === nextChild) { - updates = enqueue(updates, this.moveChild(prevChild, lastPlacedNode, nextIndex, lastIndex)); - lastIndex = Math.max(prevChild._mountIndex, lastIndex); - prevChild._mountIndex = nextIndex; - } else { - if (prevChild) { - // Update `lastIndex` before `_mountIndex` gets unset by unmounting. - lastIndex = Math.max(prevChild._mountIndex, lastIndex); - // The `removedNodes` loop below will actually remove the child. - } - // The child must be instantiated before it's mounted. - updates = enqueue(updates, this._mountChildAtIndex(nextChild, mountImages[nextMountIndex], lastPlacedNode, nextIndex, transaction, context)); - nextMountIndex++; - } - nextIndex++; - lastPlacedNode = ReactReconciler.getHostNode(nextChild); - } - // Remove children that are no longer present. - for (name in removedNodes) { - if (removedNodes.hasOwnProperty(name)) { - updates = enqueue(updates, this._unmountChild(prevChildren[name], removedNodes[name])); - } - } - if (updates) { - processQueue(this, updates); - } - this._renderedChildren = nextChildren; + // Apply f() x16 times + for (var i = 0; i < state.keys.length; i += 2) { + var keyL = state.keys[i]; + var keyR = state.keys[i + 1]; - if (process.env.NODE_ENV !== 'production') { - setChildrenForInstrumentation.call(this, nextChildren); - } - }, + // f(r, k) + utils.expand(r, state.tmp, 0); - /** - * Unmounts all rendered children. This should be used to clean up children - * when this component is unmounted. It does not actually perform any - * backend operations. - * - * @internal - */ - unmountChildren: function (safely) { - var renderedChildren = this._renderedChildren; - ReactChildReconciler.unmountChildren(renderedChildren, safely); - this._renderedChildren = null; - }, + keyL ^= state.tmp[0]; + keyR ^= state.tmp[1]; + var s = utils.substitute(keyL, keyR); + var f = utils.permute(s); - /** - * Moves a child component to the supplied index. - * - * @param {ReactComponent} child Component to move. - * @param {number} toIndex Destination index of the element. - * @param {number} lastIndex Last index visited of the siblings of `child`. - * @protected - */ - moveChild: function (child, afterNode, toIndex, lastIndex) { - // If the index of `child` is less than `lastIndex`, then it needs to - // be moved. Otherwise, we do not need to move it because a child will be - // inserted or moved before `child`. - if (child._mountIndex < lastIndex) { - return makeMove(child, afterNode, toIndex); - } - }, + var t = r; + r = (l ^ f) >>> 0; + l = t; + } - /** - * Creates a child component. - * - * @param {ReactComponent} child Component to create. - * @param {string} mountImage Markup to insert. - * @protected - */ - createChild: function (child, afterNode, mountImage) { - return makeInsertMarkup(mountImage, afterNode, child._mountIndex); - }, + // Reverse Initial Permutation + utils.rip(r, l, out, off); +}; - /** - * Removes a child component. - * - * @param {ReactComponent} child Child to remove. - * @protected - */ - removeChild: function (child, node) { - return makeRemove(child, node); - }, +DES.prototype._decrypt = function _decrypt(state, lStart, rStart, out, off) { + var l = rStart; + var r = lStart; - /** - * Mounts a child with the supplied name. - * - * NOTE: This is part of `updateChildren` and is here for readability. - * - * @param {ReactComponent} child Component to mount. - * @param {string} name Name of the child. - * @param {number} index Index at which to insert the child. - * @param {ReactReconcileTransaction} transaction - * @private - */ - _mountChildAtIndex: function (child, mountImage, afterNode, index, transaction, context) { - child._mountIndex = index; - return this.createChild(child, afterNode, mountImage); - }, + // Apply f() x16 times + for (var i = state.keys.length - 2; i >= 0; i -= 2) { + var keyL = state.keys[i]; + var keyR = state.keys[i + 1]; - /** - * Unmounts a rendered child. - * - * NOTE: This is part of `updateChildren` and is here for readability. - * - * @param {ReactComponent} child Component to unmount. - * @private - */ - _unmountChild: function (child, node) { - var update = this.removeChild(child, node); - child._mountIndex = null; - return update; - } + // f(r, k) + utils.expand(l, state.tmp, 0); + + keyL ^= state.tmp[0]; + keyR ^= state.tmp[1]; + var s = utils.substitute(keyL, keyR); + var f = utils.permute(s); + + var t = l; + l = (r ^ f) >>> 0; + r = t; } + + // Reverse Initial Permutation + utils.rip(l, r, out, off); }; -module.exports = ReactMultiChild; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 175 */ +/* 431 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); -var ReactReconciler = __webpack_require__(26); +var proto = {}; -var instantiateReactComponent = __webpack_require__(96); -var KeyEscapeUtils = __webpack_require__(62); -var shouldUpdateReactComponent = __webpack_require__(61); -var traverseAllChildren = __webpack_require__(100); -var warning = __webpack_require__(2); +function CBCState(iv) { + assert.equal(iv.length, 8, 'Invalid IV length'); -var ReactComponentTreeHook; - -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); + this.iv = new Array(8); + for (var i = 0; i < this.iv.length; i++) + this.iv[i] = iv[i]; } -function instantiateChild(childInstances, child, name, selfDebugID) { - // We found a component instance. - var keyUnique = childInstances[name] === undefined; - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (!keyUnique) { - process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; - } +function instantiate(Base) { + function CBC(options) { + Base.call(this, options); + this._cbcInit(); } - if (child != null && keyUnique) { - childInstances[name] = instantiateReactComponent(child, true); + inherits(CBC, Base); + + var keys = Object.keys(proto); + for (var i = 0; i < keys.length; i++) { + var key = keys[i]; + CBC.prototype[key] = proto[key]; } + + CBC.create = function create(options) { + return new CBC(options); + }; + + return CBC; } -/** - * ReactChildReconciler provides helpers for initializing or updating a set of - * children. Its output is suitable for passing it onto ReactMultiChild which - * does diffed reordering and insertion. - */ -var ReactChildReconciler = { - /** - * Generates a "mount image" for each of the supplied children. In the case - * of `ReactDOMComponent`, a mount image is a string of markup. - * - * @param {?object} nestedChildNodes Nested child maps. - * @return {?object} A set of child instances. - * @internal - */ - instantiateChildren: function (nestedChildNodes, transaction, context, selfDebugID) // 0 in production and for roots - { - if (nestedChildNodes == null) { - return null; - } - var childInstances = {}; +exports.instantiate = instantiate; - if (process.env.NODE_ENV !== 'production') { - traverseAllChildren(nestedChildNodes, function (childInsts, child, name) { - return instantiateChild(childInsts, child, name, selfDebugID); - }, childInstances); - } else { - traverseAllChildren(nestedChildNodes, instantiateChild, childInstances); - } - return childInstances; - }, +proto._cbcInit = function _cbcInit() { + var state = new CBCState(this.options.iv); + this._cbcState = state; +}; - /** - * Updates the rendered children and returns a new set of children. - * - * @param {?object} prevChildren Previously initialized set of children. - * @param {?object} nextChildren Flat child element maps. - * @param {ReactReconcileTransaction} transaction - * @param {object} context - * @return {?object} A new set of child instances. - * @internal - */ - updateChildren: function (prevChildren, nextChildren, mountImages, removedNodes, transaction, hostParent, hostContainerInfo, context, selfDebugID) // 0 in production and for roots - { - // We currently don't have a way to track moves here but if we use iterators - // instead of for..in we can zip the iterators and check if an item has - // moved. - // TODO: If nothing has changed, return the prevChildren object so that we - // can quickly bailout if nothing has changed. - if (!nextChildren && !prevChildren) { - return; - } - var name; - var prevChild; - for (name in nextChildren) { - if (!nextChildren.hasOwnProperty(name)) { - continue; - } - prevChild = prevChildren && prevChildren[name]; - var prevElement = prevChild && prevChild._currentElement; - var nextElement = nextChildren[name]; - if (prevChild != null && shouldUpdateReactComponent(prevElement, nextElement)) { - ReactReconciler.receiveComponent(prevChild, nextElement, transaction, context); - nextChildren[name] = prevChild; - } else { - if (prevChild) { - removedNodes[name] = ReactReconciler.getHostNode(prevChild); - ReactReconciler.unmountComponent(prevChild, false); - } - // The child must be instantiated before it's mounted. - var nextChildInstance = instantiateReactComponent(nextElement, true); - nextChildren[name] = nextChildInstance; - // Creating mount image now ensures refs are resolved in right order - // (see https://github.com/facebook/react/pull/7101 for explanation). - var nextChildMountImage = ReactReconciler.mountComponent(nextChildInstance, transaction, hostParent, hostContainerInfo, context, selfDebugID); - mountImages.push(nextChildMountImage); - } - } - // Unmount children that are no longer present. - for (name in prevChildren) { - if (prevChildren.hasOwnProperty(name) && !(nextChildren && nextChildren.hasOwnProperty(name))) { - prevChild = prevChildren[name]; - removedNodes[name] = ReactReconciler.getHostNode(prevChild); - ReactReconciler.unmountComponent(prevChild, false); - } - } - }, +proto._update = function _update(inp, inOff, out, outOff) { + var state = this._cbcState; + var superProto = this.constructor.super_.prototype; - /** - * Unmounts all rendered children. This should be used to clean up children - * when this component is unmounted. - * - * @param {?object} renderedChildren Previously initialized set of children. - * @internal - */ - unmountChildren: function (renderedChildren, safely) { - for (var name in renderedChildren) { - if (renderedChildren.hasOwnProperty(name)) { - var renderedChild = renderedChildren[name]; - ReactReconciler.unmountComponent(renderedChild, safely); - } - } + var iv = state.iv; + if (this.type === 'encrypt') { + for (var i = 0; i < this.blockSize; i++) + iv[i] ^= inp[inOff + i]; + + superProto._update.call(this, iv, 0, out, outOff); + + for (var i = 0; i < this.blockSize; i++) + iv[i] = out[outOff + i]; + } else { + superProto._update.call(this, inp, inOff, out, outOff); + + for (var i = 0; i < this.blockSize; i++) + out[outOff + i] ^= iv[i]; + + for (var i = 0; i < this.blockSize; i++) + iv[i] = inp[inOff + i]; } }; -module.exports = ReactChildReconciler; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 176 */ +/* 432 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +var des = __webpack_require__(109); +var Cipher = des.Cipher; +var DES = des.DES; -var React = __webpack_require__(24); -var ReactComponentEnvironment = __webpack_require__(59); -var ReactCurrentOwner = __webpack_require__(14); -var ReactErrorUtils = __webpack_require__(51); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactNodeTypes = __webpack_require__(97); -var ReactReconciler = __webpack_require__(26); +function EDEState(type, key) { + assert.equal(key.length, 24, 'Invalid key length'); -if (process.env.NODE_ENV !== 'production') { - var checkReactTypeSpec = __webpack_require__(177); + var k1 = key.slice(0, 8); + var k2 = key.slice(8, 16); + var k3 = key.slice(16, 24); + + if (type === 'encrypt') { + this.ciphers = [ + DES.create({ type: 'encrypt', key: k1 }), + DES.create({ type: 'decrypt', key: k2 }), + DES.create({ type: 'encrypt', key: k3 }) + ]; + } else { + this.ciphers = [ + DES.create({ type: 'decrypt', key: k3 }), + DES.create({ type: 'encrypt', key: k2 }), + DES.create({ type: 'decrypt', key: k1 }) + ]; + } } -var emptyObject = __webpack_require__(39); -var invariant = __webpack_require__(1); -var shallowEqual = __webpack_require__(60); -var shouldUpdateReactComponent = __webpack_require__(61); -var warning = __webpack_require__(2); +function EDE(options) { + Cipher.call(this, options); -var CompositeTypes = { - ImpureClass: 0, - PureClass: 1, - StatelessFunctional: 2 + var state = new EDEState(this.type, this.options.key); + this._edeState = state; +} +inherits(EDE, Cipher); + +module.exports = EDE; + +EDE.create = function create(options) { + return new EDE(options); }; -function StatelessComponent(Component) {} -StatelessComponent.prototype.render = function () { - var Component = ReactInstanceMap.get(this)._currentElement.type; - var element = Component(this.props, this.context, this.updater); - warnIfInvalidElement(Component, element); - return element; +EDE.prototype._update = function _update(inp, inOff, out, outOff) { + var state = this._edeState; + + state.ciphers[0]._update(inp, inOff, out, outOff); + state.ciphers[1]._update(out, outOff, out, outOff); + state.ciphers[2]._update(out, outOff, out, outOff); }; -function warnIfInvalidElement(Component, element) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(element === null || element === false || React.isValidElement(element), '%s(...): A valid React element (or null) must be returned. You may have ' + 'returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!Component.childContextTypes, '%s(...): childContextTypes cannot be defined on a functional component.', Component.displayName || Component.name || 'Component') : void 0; - } +EDE.prototype._pad = DES.prototype._pad; +EDE.prototype._unpad = DES.prototype._unpad; + + +/***/ }), +/* 433 */ +/***/ (function(module, exports) { + +exports['des-ecb'] = { + key: 8, + iv: 0 +} +exports['des-cbc'] = exports.des = { + key: 8, + iv: 8 +} +exports['des-ede3-cbc'] = exports.des3 = { + key: 24, + iv: 8 +} +exports['des-ede3'] = { + key: 24, + iv: 0 +} +exports['des-ede-cbc'] = { + key: 16, + iv: 8 +} +exports['des-ede'] = { + key: 16, + iv: 0 } -function shouldConstruct(Component) { - return !!(Component.prototype && Component.prototype.isReactComponent); + +/***/ }), +/* 434 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var generatePrime = __webpack_require__(189) +var primes = __webpack_require__(435) + +var DH = __webpack_require__(436) + +function getDiffieHellman (mod) { + var prime = new Buffer(primes[mod].prime, 'hex') + var gen = new Buffer(primes[mod].gen, 'hex') + + return new DH(prime, gen) } -function isPureComponent(Component) { - return !!(Component.prototype && Component.prototype.isPureReactComponent); +var ENCODINGS = { + 'binary': true, 'hex': true, 'base64': true } -// Separated into a function to contain deoptimizations caused by try/finally. -function measureLifeCyclePerf(fn, debugID, timerType) { - if (debugID === 0) { - // Top-level wrappers (see ReactMount) and empty components (see - // ReactDOMEmptyComponent) are invisible to hooks and devtools. - // Both are implementation details that should go away in the future. - return fn(); +function createDiffieHellman (prime, enc, generator, genc) { + if (Buffer.isBuffer(enc) || ENCODINGS[enc] === undefined) { + return createDiffieHellman(prime, 'binary', enc, generator) } - ReactInstrumentation.debugTool.onBeginLifeCycleTimer(debugID, timerType); - try { - return fn(); - } finally { - ReactInstrumentation.debugTool.onEndLifeCycleTimer(debugID, timerType); + enc = enc || 'binary' + genc = genc || 'binary' + generator = generator || new Buffer([2]) + + if (!Buffer.isBuffer(generator)) { + generator = new Buffer(generator, genc) + } + + if (typeof prime === 'number') { + return new DH(generatePrime(prime, generator), generator, true) + } + + if (!Buffer.isBuffer(prime)) { + prime = new Buffer(prime, enc) } + + return new DH(prime, generator, true) } -/** - * ------------------ The Life-Cycle of a Composite Component ------------------ - * - * - constructor: Initialization of state. The instance is now retained. - * - componentWillMount - * - render - * - [children's constructors] - * - [children's componentWillMount and render] - * - [children's componentDidMount] - * - componentDidMount - * - * Update Phases: - * - componentWillReceiveProps (only called if parent updated) - * - shouldComponentUpdate - * - componentWillUpdate - * - render - * - [children's constructors or receive props phases] - * - componentDidUpdate - * - * - componentWillUnmount - * - [children's componentWillUnmount] - * - [children destroyed] - * - (destroyed): The instance is now blank, released by React and ready for GC. - * - * ----------------------------------------------------------------------------- - */ +exports.DiffieHellmanGroup = exports.createDiffieHellmanGroup = exports.getDiffieHellman = getDiffieHellman +exports.createDiffieHellman = exports.DiffieHellman = createDiffieHellman -/** - * An incrementing ID assigned to each component when it is mounted. This is - * used to enforce the order in which `ReactUpdates` updates dirty components. - * - * @private - */ -var nextMountID = 1; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -/** - * @lends {ReactCompositeComponent.prototype} - */ -var ReactCompositeComponent = { - /** - * Base constructor for all composite component. - * - * @param {ReactElement} element - * @final - * @internal - */ - construct: function (element) { - this._currentElement = element; - this._rootNodeID = 0; - this._compositeType = null; - this._instance = null; - this._hostParent = null; - this._hostContainerInfo = null; +/***/ }), +/* 435 */ +/***/ (function(module, exports) { - // See ReactUpdateQueue - this._updateBatchNumber = null; - this._pendingElement = null; - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; +module.exports = { + "modp1": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff" + }, + "modp2": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff" + }, + "modp5": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff" + }, + "modp14": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff" + }, + "modp15": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff" + }, + "modp16": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff" + }, + "modp17": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff" + }, + "modp18": { + "gen": "02", + "prime": "ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff" + } +}; - this._renderedNodeType = null; - this._renderedComponent = null; - this._context = null; - this._mountOrder = 0; - this._topLevelWrapper = null; +/***/ }), +/* 436 */ +/***/ (function(module, exports, __webpack_require__) { - // See ReactUpdates and ReactUpdateQueue. - this._pendingCallbacks = null; +/* WEBPACK VAR INJECTION */(function(Buffer) {var BN = __webpack_require__(11); +var MillerRabin = __webpack_require__(190); +var millerRabin = new MillerRabin(); +var TWENTYFOUR = new BN(24); +var ELEVEN = new BN(11); +var TEN = new BN(10); +var THREE = new BN(3); +var SEVEN = new BN(7); +var primes = __webpack_require__(189); +var randomBytes = __webpack_require__(43); +module.exports = DH; + +function setPublicKey(pub, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(pub)) { + pub = new Buffer(pub, enc); + } + this._pub = new BN(pub); + return this; +} - // ComponentWillUnmount shall only be called once - this._calledComponentWillUnmount = false; +function setPrivateKey(priv, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(priv)) { + priv = new Buffer(priv, enc); + } + this._priv = new BN(priv); + return this; +} - if (process.env.NODE_ENV !== 'production') { - this._warnedAboutRefsInRender = false; +var primeCache = {}; +function checkPrime(prime, generator) { + var gen = generator.toString('hex'); + var hex = [gen, prime.toString(16)].join('_'); + if (hex in primeCache) { + return primeCache[hex]; + } + var error = 0; + + if (prime.isEven() || + !primes.simpleSieve || + !primes.fermatTest(prime) || + !millerRabin.test(prime)) { + //not a prime so +1 + error += 1; + + if (gen === '02' || gen === '05') { + // we'd be able to check the generator + // it would fail so +8 + error += 8; + } else { + //we wouldn't be able to test the generator + // so +4 + error += 4; + } + primeCache[hex] = error; + return error; + } + if (!millerRabin.test(prime.shrn(1))) { + //not a safe prime + error += 2; + } + var rem; + switch (gen) { + case '02': + if (prime.mod(TWENTYFOUR).cmp(ELEVEN)) { + // unsuidable generator + error += 8; + } + break; + case '05': + rem = prime.mod(TEN); + if (rem.cmp(THREE) && rem.cmp(SEVEN)) { + // prime mod 10 needs to equal 3 or 7 + error += 8; + } + break; + default: + error += 4; + } + primeCache[hex] = error; + return error; +} + +function DH(prime, generator, malleable) { + this.setGenerator(generator); + this.__prime = new BN(prime); + this._prime = BN.mont(this.__prime); + this._primeLen = prime.length; + this._pub = undefined; + this._priv = undefined; + this._primeCode = undefined; + if (malleable) { + this.setPublicKey = setPublicKey; + this.setPrivateKey = setPrivateKey; + } else { + this._primeCode = 8; + } +} +Object.defineProperty(DH.prototype, 'verifyError', { + enumerable: true, + get: function () { + if (typeof this._primeCode !== 'number') { + this._primeCode = checkPrime(this.__prime, this.__gen); } - }, + return this._primeCode; + } +}); +DH.prototype.generateKeys = function () { + if (!this._priv) { + this._priv = new BN(randomBytes(this._primeLen)); + } + this._pub = this._gen.toRed(this._prime).redPow(this._priv).fromRed(); + return this.getPublicKey(); +}; - /** - * Initializes the component, renders markup, and registers event listeners. - * - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?object} hostParent - * @param {?object} hostContainerInfo - * @param {?object} context - * @return {?string} Rendered markup to be inserted into the DOM. - * @final - * @internal - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - var _this = this; +DH.prototype.computeSecret = function (other) { + other = new BN(other); + other = other.toRed(this._prime); + var secret = other.redPow(this._priv).fromRed(); + var out = new Buffer(secret.toArray()); + var prime = this.getPrime(); + if (out.length < prime.length) { + var front = new Buffer(prime.length - out.length); + front.fill(0); + out = Buffer.concat([front, out]); + } + return out; +}; - this._context = context; - this._mountOrder = nextMountID++; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; +DH.prototype.getPublicKey = function getPublicKey(enc) { + return formatReturnValue(this._pub, enc); +}; - var publicProps = this._currentElement.props; - var publicContext = this._processContext(context); +DH.prototype.getPrivateKey = function getPrivateKey(enc) { + return formatReturnValue(this._priv, enc); +}; - var Component = this._currentElement.type; +DH.prototype.getPrime = function (enc) { + return formatReturnValue(this.__prime, enc); +}; - var updateQueue = transaction.getUpdateQueue(); +DH.prototype.getGenerator = function (enc) { + return formatReturnValue(this._gen, enc); +}; - // Initialize the public class - var doConstruct = shouldConstruct(Component); - var inst = this._constructComponent(doConstruct, publicProps, publicContext, updateQueue); - var renderedElement; +DH.prototype.setGenerator = function (gen, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(gen)) { + gen = new Buffer(gen, enc); + } + this.__gen = gen; + this._gen = new BN(gen); + return this; +}; - // Support functional components - if (!doConstruct && (inst == null || inst.render == null)) { - renderedElement = inst; - warnIfInvalidElement(Component, renderedElement); - !(inst === null || inst === false || React.isValidElement(inst)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : _prodInvariant('105', Component.displayName || Component.name || 'Component') : void 0; - inst = new StatelessComponent(Component); - this._compositeType = CompositeTypes.StatelessFunctional; - } else { - if (isPureComponent(Component)) { - this._compositeType = CompositeTypes.PureClass; - } else { - this._compositeType = CompositeTypes.ImpureClass; - } - } +function formatReturnValue(bn, enc) { + var buf = new Buffer(bn.toArray()); + if (!enc) { + return buf; + } else { + return buf.toString(enc); + } +} - if (process.env.NODE_ENV !== 'production') { - // This will throw later in _renderValidatedComponent, but add an early - // warning now to help debugging - if (inst.render == null) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): No `render` method found on the returned component ' + 'instance: you may have forgotten to define `render`.', Component.displayName || Component.name || 'Component') : void 0; - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - var propsMutated = inst.props !== publicProps; - var componentName = Component.displayName || Component.name || 'Component'; +/***/ }), +/* 437 */ +/***/ (function(module, exports, __webpack_require__) { - process.env.NODE_ENV !== 'production' ? warning(inst.props === undefined || !propsMutated, '%s(...): When calling super() in `%s`, make sure to pass ' + "up the same props that your component's constructor was passed.", componentName, componentName) : void 0; - } +/* WEBPACK VAR INJECTION */(function(Buffer) {var createHash = __webpack_require__(27) +var stream = __webpack_require__(98) +var inherits = __webpack_require__(4) +var sign = __webpack_require__(438) +var verify = __webpack_require__(453) - // These should be set up in the constructor, but as a convenience for - // simpler class abstractions, we set them up after the fact. - inst.props = publicProps; - inst.context = publicContext; - inst.refs = emptyObject; - inst.updater = updateQueue; +var algorithms = __webpack_require__(176) +Object.keys(algorithms).forEach(function (key) { + algorithms[key].id = new Buffer(algorithms[key].id, 'hex') + algorithms[key.toLowerCase()] = algorithms[key] +}) - this._instance = inst; +function Sign (algorithm) { + stream.Writable.call(this) - // Store a reference from the instance back to the internal representation - ReactInstanceMap.set(inst, this); + var data = algorithms[algorithm] + if (!data) throw new Error('Unknown message digest') - if (process.env.NODE_ENV !== 'production') { - // Since plain JS classes are defined without any special initialization - // logic, we can not catch common errors early. Therefore, we have to - // catch them here, at initialization time, instead. - process.env.NODE_ENV !== 'production' ? warning(!inst.getInitialState || inst.getInitialState.isReactClassApproved || inst.state, 'getInitialState was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Did you mean to define a state property instead?', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.getDefaultProps || inst.getDefaultProps.isReactClassApproved, 'getDefaultProps was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Use a static property to define defaultProps instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.propTypes, 'propTypes was defined as an instance property on %s. Use a static ' + 'property to define propTypes instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.contextTypes, 'contextTypes was defined as an instance property on %s. Use a ' + 'static property to define contextTypes instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentShouldUpdate !== 'function', '%s has a method called ' + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + 'The name is phrased as a question because the function is ' + 'expected to return a value.', this.getName() || 'A component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentDidUnmount !== 'function', '%s has a method called ' + 'componentDidUnmount(). But there is no such lifecycle method. ' + 'Did you mean componentWillUnmount()?', this.getName() || 'A component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentWillRecieveProps !== 'function', '%s has a method called ' + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', this.getName() || 'A component') : void 0; - } + this._hashType = data.hash + this._hash = createHash(data.hash) + this._tag = data.id + this._signType = data.sign +} +inherits(Sign, stream.Writable) - var initialState = inst.state; - if (initialState === undefined) { - inst.state = initialState = null; - } - !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.state: must be set to an object or null', this.getName() || 'ReactCompositeComponent') : _prodInvariant('106', this.getName() || 'ReactCompositeComponent') : void 0; +Sign.prototype._write = function _write (data, _, done) { + this._hash.update(data) + done() +} - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; +Sign.prototype.update = function update (data, enc) { + if (typeof data === 'string') data = new Buffer(data, enc) - var markup; - if (inst.unstable_handleError) { - markup = this.performInitialMountWithErrorHandling(renderedElement, hostParent, hostContainerInfo, transaction, context); - } else { - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } + this._hash.update(data) + return this +} - if (inst.componentDidMount) { - if (process.env.NODE_ENV !== 'production') { - transaction.getReactMountReady().enqueue(function () { - measureLifeCyclePerf(function () { - return inst.componentDidMount(); - }, _this._debugID, 'componentDidMount'); - }); - } else { - transaction.getReactMountReady().enqueue(inst.componentDidMount, inst); - } - } +Sign.prototype.sign = function signMethod (key, enc) { + this.end() + var hash = this._hash.digest() + var sig = sign(hash, key, this._hashType, this._signType, this._tag) - return markup; - }, + return enc ? sig.toString(enc) : sig +} - _constructComponent: function (doConstruct, publicProps, publicContext, updateQueue) { - if (process.env.NODE_ENV !== 'production') { - ReactCurrentOwner.current = this; - try { - return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); - } finally { - ReactCurrentOwner.current = null; - } - } else { - return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); - } - }, +function Verify (algorithm) { + stream.Writable.call(this) - _constructComponentWithoutOwner: function (doConstruct, publicProps, publicContext, updateQueue) { - var Component = this._currentElement.type; + var data = algorithms[algorithm] + if (!data) throw new Error('Unknown message digest') - if (doConstruct) { - if (process.env.NODE_ENV !== 'production') { - return measureLifeCyclePerf(function () { - return new Component(publicProps, publicContext, updateQueue); - }, this._debugID, 'ctor'); - } else { - return new Component(publicProps, publicContext, updateQueue); - } - } + this._hash = createHash(data.hash) + this._tag = data.id + this._signType = data.sign +} +inherits(Verify, stream.Writable) - // This can still be an instance in case of factory components - // but we'll count this as time spent rendering as the more common case. - if (process.env.NODE_ENV !== 'production') { - return measureLifeCyclePerf(function () { - return Component(publicProps, publicContext, updateQueue); - }, this._debugID, 'render'); - } else { - return Component(publicProps, publicContext, updateQueue); - } - }, +Verify.prototype._write = function _write (data, _, done) { + this._hash.update(data) + done() +} - performInitialMountWithErrorHandling: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { - var markup; - var checkpoint = transaction.checkpoint(); - try { - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } catch (e) { - // Roll back to checkpoint, handle error (which may add items to the transaction), and take a new checkpoint - transaction.rollback(checkpoint); - this._instance.unstable_handleError(e); - if (this._pendingStateQueue) { - this._instance.state = this._processPendingState(this._instance.props, this._instance.context); - } - checkpoint = transaction.checkpoint(); +Verify.prototype.update = function update (data, enc) { + if (typeof data === 'string') data = new Buffer(data, enc) - this._renderedComponent.unmountComponent(true); - transaction.rollback(checkpoint); + this._hash.update(data) + return this +} - // Try again - we've informed the component about the error, so they can render an error message this time. - // If this throws again, the error will bubble up (and can be caught by a higher error boundary). - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } - return markup; - }, +Verify.prototype.verify = function verifyMethod (key, sig, enc) { + if (typeof sig === 'string') sig = new Buffer(sig, enc) - performInitialMount: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { - var inst = this._instance; + this.end() + var hash = this._hash.digest() + return verify(sig, hash, key, this._signType, this._tag) +} - var debugID = 0; - if (process.env.NODE_ENV !== 'production') { - debugID = this._debugID; - } +function createSign (algorithm) { + return new Sign(algorithm) +} - if (inst.componentWillMount) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillMount(); - }, debugID, 'componentWillMount'); - } else { - inst.componentWillMount(); - } - // When mounting, calls to `setState` by `componentWillMount` will set - // `this._pendingStateQueue` without triggering a re-render. - if (this._pendingStateQueue) { - inst.state = this._processPendingState(inst.props, inst.context); - } - } +function createVerify (algorithm) { + return new Verify(algorithm) +} - // If not a stateless component, we now render - if (renderedElement === undefined) { - renderedElement = this._renderValidatedComponent(); - } +module.exports = { + Sign: createSign, + Verify: createVerify, + createSign: createSign, + createVerify: createVerify +} - var nodeType = ReactNodeTypes.getType(renderedElement); - this._renderedNodeType = nodeType; - var child = this._instantiateReactComponent(renderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ - ); - this._renderedComponent = child; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - var markup = ReactReconciler.mountComponent(child, transaction, hostParent, hostContainerInfo, this._processChildContext(context), debugID); +/***/ }), +/* 438 */ +/***/ (function(module, exports, __webpack_require__) { - if (process.env.NODE_ENV !== 'production') { - if (debugID !== 0) { - var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; - ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); - } - } +/* WEBPACK VAR INJECTION */(function(Buffer) {// much of this based on https://github.com/indutny/self-signed/blob/gh-pages/lib/rsa.js +var createHmac = __webpack_require__(67) +var crt = __webpack_require__(110) +var EC = __webpack_require__(15).ec +var BN = __webpack_require__(11) +var parseKeys = __webpack_require__(72) +var curves = __webpack_require__(195) + +function sign (hash, key, hashType, signType, tag) { + var priv = parseKeys(key) + if (priv.curve) { + // rsa keys can be interpreted as ecdsa ones in openssl + if (signType !== 'ecdsa' && signType !== 'ecdsa/rsa') throw new Error('wrong private key type') + return ecSign(hash, priv) + } else if (priv.type === 'dsa') { + if (signType !== 'dsa') throw new Error('wrong private key type') + return dsaSign(hash, priv, hashType) + } else { + if (signType !== 'rsa' && signType !== 'ecdsa/rsa') throw new Error('wrong private key type') + } + hash = Buffer.concat([tag, hash]) + var len = priv.modulus.byteLength() + var pad = [ 0, 1 ] + while (hash.length + pad.length + 1 < len) pad.push(0xff) + pad.push(0x00) + var i = -1 + while (++i < hash.length) pad.push(hash[i]) + + var out = crt(pad, priv) + return out +} - return markup; - }, +function ecSign (hash, priv) { + var curveId = curves[priv.curve.join('.')] + if (!curveId) throw new Error('unknown curve ' + priv.curve.join('.')) - getHostNode: function () { - return ReactReconciler.getHostNode(this._renderedComponent); - }, + var curve = new EC(curveId) + var key = curve.keyFromPrivate(priv.privateKey) + var out = key.sign(hash) - /** - * Releases any resources allocated by `mountComponent`. - * - * @final - * @internal - */ - unmountComponent: function (safely) { - if (!this._renderedComponent) { - return; - } + return new Buffer(out.toDER()) +} - var inst = this._instance; +function dsaSign (hash, priv, algo) { + var x = priv.params.priv_key + var p = priv.params.p + var q = priv.params.q + var g = priv.params.g + var r = new BN(0) + var k + var H = bits2int(hash, q).mod(q) + var s = false + var kv = getKey(x, q, hash, algo) + while (s === false) { + k = makeKey(q, kv, algo) + r = makeR(g, k, p, q) + s = k.invm(q).imul(H.add(x.mul(r))).mod(q) + if (s.cmpn(0) === 0) { + s = false + r = new BN(0) + } + } + return toDER(r, s) +} - if (inst.componentWillUnmount && !inst._calledComponentWillUnmount) { - inst._calledComponentWillUnmount = true; +function toDER (r, s) { + r = r.toArray() + s = s.toArray() - if (safely) { - var name = this.getName() + '.componentWillUnmount()'; - ReactErrorUtils.invokeGuardedCallback(name, inst.componentWillUnmount.bind(inst)); - } else { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillUnmount(); - }, this._debugID, 'componentWillUnmount'); - } else { - inst.componentWillUnmount(); - } - } - } + // Pad values + if (r[0] & 0x80) r = [ 0 ].concat(r) + if (s[0] & 0x80) s = [ 0 ].concat(s) - if (this._renderedComponent) { - ReactReconciler.unmountComponent(this._renderedComponent, safely); - this._renderedNodeType = null; - this._renderedComponent = null; - this._instance = null; - } + var total = r.length + s.length + 4 + var res = [ 0x30, total, 0x02, r.length ] + res = res.concat(r, [ 0x02, s.length ], s) + return new Buffer(res) +} - // Reset pending fields - // Even if this component is scheduled for another update in ReactUpdates, - // it would still be ignored because these fields are reset. - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; - this._pendingCallbacks = null; - this._pendingElement = null; +function getKey (x, q, hash, algo) { + x = new Buffer(x.toArray()) + if (x.length < q.byteLength()) { + var zeros = new Buffer(q.byteLength() - x.length) + zeros.fill(0) + x = Buffer.concat([ zeros, x ]) + } + var hlen = hash.length + var hbits = bits2octets(hash, q) + var v = new Buffer(hlen) + v.fill(1) + var k = new Buffer(hlen) + k.fill(0) + k = createHmac(algo, k).update(v).update(new Buffer([ 0 ])).update(x).update(hbits).digest() + v = createHmac(algo, k).update(v).digest() + k = createHmac(algo, k).update(v).update(new Buffer([ 1 ])).update(x).update(hbits).digest() + v = createHmac(algo, k).update(v).digest() + return { k: k, v: v } +} - // These fields do not really need to be reset since this object is no - // longer accessible. - this._context = null; - this._rootNodeID = 0; - this._topLevelWrapper = null; +function bits2int (obits, q) { + var bits = new BN(obits) + var shift = (obits.length << 3) - q.bitLength() + if (shift > 0) bits.ishrn(shift) + return bits +} - // Delete the reference from the instance to this internal representation - // which allow the internals to be properly cleaned up even if the user - // leaks a reference to the public instance. - ReactInstanceMap.remove(inst); +function bits2octets (bits, q) { + bits = bits2int(bits, q) + bits = bits.mod(q) + var out = new Buffer(bits.toArray()) + if (out.length < q.byteLength()) { + var zeros = new Buffer(q.byteLength() - out.length) + zeros.fill(0) + out = Buffer.concat([ zeros, out ]) + } + return out +} - // Some existing components rely on inst.props even after they've been - // destroyed (in event handlers). - // TODO: inst.props = null; - // TODO: inst.state = null; - // TODO: inst.context = null; - }, +function makeKey (q, kv, algo) { + var t + var k - /** - * Filters the context object to only contain keys specified in - * `contextTypes` - * - * @param {object} context - * @return {?object} - * @private - */ - _maskContext: function (context) { - var Component = this._currentElement.type; - var contextTypes = Component.contextTypes; - if (!contextTypes) { - return emptyObject; - } - var maskedContext = {}; - for (var contextName in contextTypes) { - maskedContext[contextName] = context[contextName]; - } - return maskedContext; - }, + do { + t = new Buffer(0) - /** - * Filters the context object to only contain keys specified in - * `contextTypes`, and asserts that they are valid. - * - * @param {object} context - * @return {?object} - * @private - */ - _processContext: function (context) { - var maskedContext = this._maskContext(context); - if (process.env.NODE_ENV !== 'production') { - var Component = this._currentElement.type; - if (Component.contextTypes) { - this._checkContextTypes(Component.contextTypes, maskedContext, 'context'); - } + while (t.length * 8 < q.bitLength()) { + kv.v = createHmac(algo, kv.k).update(kv.v).digest() + t = Buffer.concat([ t, kv.v ]) } - return maskedContext; - }, - /** - * @param {object} currentContext - * @return {object} - * @private - */ - _processChildContext: function (currentContext) { - var Component = this._currentElement.type; - var inst = this._instance; - var childContext; + k = bits2int(t, q) + kv.k = createHmac(algo, kv.k).update(kv.v).update(new Buffer([ 0 ])).digest() + kv.v = createHmac(algo, kv.k).update(kv.v).digest() + } while (k.cmp(q) !== -1) - if (inst.getChildContext) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onBeginProcessingChildContext(); - try { - childContext = inst.getChildContext(); - } finally { - ReactInstrumentation.debugTool.onEndProcessingChildContext(); - } - } else { - childContext = inst.getChildContext(); - } - } + return k +} - if (childContext) { - !(typeof Component.childContextTypes === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().', this.getName() || 'ReactCompositeComponent') : _prodInvariant('107', this.getName() || 'ReactCompositeComponent') : void 0; - if (process.env.NODE_ENV !== 'production') { - this._checkContextTypes(Component.childContextTypes, childContext, 'child context'); - } - for (var name in childContext) { - !(name in Component.childContextTypes) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): key "%s" is not defined in childContextTypes.', this.getName() || 'ReactCompositeComponent', name) : _prodInvariant('108', this.getName() || 'ReactCompositeComponent', name) : void 0; - } - return _assign({}, currentContext, childContext); - } - return currentContext; - }, +function makeR (g, k, p, q) { + return g.toRed(BN.mont(p)).redPow(k).fromRed().mod(q) +} - /** - * Assert that the context types are valid - * - * @param {object} typeSpecs Map of context field to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @private - */ - _checkContextTypes: function (typeSpecs, values, location) { - if (process.env.NODE_ENV !== 'production') { - checkReactTypeSpec(typeSpecs, values, location, this.getName(), null, this._debugID); - } - }, +module.exports = sign +module.exports.getKey = getKey +module.exports.makeKey = makeKey - receiveComponent: function (nextElement, transaction, nextContext) { - var prevElement = this._currentElement; - var prevContext = this._context; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - this._pendingElement = null; +/***/ }), +/* 439 */ +/***/ (function(module, exports, __webpack_require__) { - this.updateComponent(transaction, prevElement, nextElement, prevContext, nextContext); - }, +"use strict"; +// from https://github.com/indutny/self-signed/blob/gh-pages/lib/asn1.js +// Fedor, you are amazing. + + +var asn1 = __webpack_require__(52) + +exports.certificate = __webpack_require__(450) + +var RSAPrivateKey = asn1.define('RSAPrivateKey', function () { + this.seq().obj( + this.key('version').int(), + this.key('modulus').int(), + this.key('publicExponent').int(), + this.key('privateExponent').int(), + this.key('prime1').int(), + this.key('prime2').int(), + this.key('exponent1').int(), + this.key('exponent2').int(), + this.key('coefficient').int() + ) +}) +exports.RSAPrivateKey = RSAPrivateKey + +var RSAPublicKey = asn1.define('RSAPublicKey', function () { + this.seq().obj( + this.key('modulus').int(), + this.key('publicExponent').int() + ) +}) +exports.RSAPublicKey = RSAPublicKey + +var PublicKey = asn1.define('SubjectPublicKeyInfo', function () { + this.seq().obj( + this.key('algorithm').use(AlgorithmIdentifier), + this.key('subjectPublicKey').bitstr() + ) +}) +exports.PublicKey = PublicKey + +var AlgorithmIdentifier = asn1.define('AlgorithmIdentifier', function () { + this.seq().obj( + this.key('algorithm').objid(), + this.key('none').null_().optional(), + this.key('curve').objid().optional(), + this.key('params').seq().obj( + this.key('p').int(), + this.key('q').int(), + this.key('g').int() + ).optional() + ) +}) + +var PrivateKeyInfo = asn1.define('PrivateKeyInfo', function () { + this.seq().obj( + this.key('version').int(), + this.key('algorithm').use(AlgorithmIdentifier), + this.key('subjectPrivateKey').octstr() + ) +}) +exports.PrivateKey = PrivateKeyInfo +var EncryptedPrivateKeyInfo = asn1.define('EncryptedPrivateKeyInfo', function () { + this.seq().obj( + this.key('algorithm').seq().obj( + this.key('id').objid(), + this.key('decrypt').seq().obj( + this.key('kde').seq().obj( + this.key('id').objid(), + this.key('kdeparams').seq().obj( + this.key('salt').octstr(), + this.key('iters').int() + ) + ), + this.key('cipher').seq().obj( + this.key('algo').objid(), + this.key('iv').octstr() + ) + ) + ), + this.key('subjectPrivateKey').octstr() + ) +}) + +exports.EncryptedPrivateKey = EncryptedPrivateKeyInfo + +var DSAPrivateKey = asn1.define('DSAPrivateKey', function () { + this.seq().obj( + this.key('version').int(), + this.key('p').int(), + this.key('q').int(), + this.key('g').int(), + this.key('pub_key').int(), + this.key('priv_key').int() + ) +}) +exports.DSAPrivateKey = DSAPrivateKey + +exports.DSAparam = asn1.define('DSAparam', function () { + this.int() +}) + +var ECPrivateKey = asn1.define('ECPrivateKey', function () { + this.seq().obj( + this.key('version').int(), + this.key('privateKey').octstr(), + this.key('parameters').optional().explicit(0).use(ECParameters), + this.key('publicKey').optional().explicit(1).bitstr() + ) +}) +exports.ECPrivateKey = ECPrivateKey + +var ECParameters = asn1.define('ECParameters', function () { + this.choice({ + namedCurve: this.objid() + }) +}) + +exports.signature = asn1.define('signature', function () { + this.seq().obj( + this.key('r').int(), + this.key('s').int() + ) +}) - /** - * If any of `_pendingElement`, `_pendingStateQueue`, or `_pendingForceUpdate` - * is set, update the component. - * - * @param {ReactReconcileTransaction} transaction - * @internal - */ - performUpdateIfNecessary: function (transaction) { - if (this._pendingElement != null) { - ReactReconciler.receiveComponent(this, this._pendingElement, transaction, this._context); - } else if (this._pendingStateQueue !== null || this._pendingForceUpdate) { - this.updateComponent(transaction, this._currentElement, this._currentElement, this._context, this._context); - } else { - this._updateBatchNumber = null; - } - }, - /** - * Perform an update to a mounted component. The componentWillReceiveProps and - * shouldComponentUpdate methods are called, then (assuming the update isn't - * skipped) the remaining update lifecycle methods are called and the DOM - * representation is updated. - * - * By default, this implements React's rendering and reconciliation algorithm. - * Sophisticated clients may wish to override this. - * - * @param {ReactReconcileTransaction} transaction - * @param {ReactElement} prevParentElement - * @param {ReactElement} nextParentElement - * @internal - * @overridable - */ - updateComponent: function (transaction, prevParentElement, nextParentElement, prevUnmaskedContext, nextUnmaskedContext) { - var inst = this._instance; - !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Attempted to update component `%s` that has already been unmounted (or failed to mount).', this.getName() || 'ReactCompositeComponent') : _prodInvariant('136', this.getName() || 'ReactCompositeComponent') : void 0; +/***/ }), +/* 440 */ +/***/ (function(module, exports, __webpack_require__) { - var willReceive = false; - var nextContext; +var asn1 = __webpack_require__(52); +var inherits = __webpack_require__(4); - // Determine if the context has changed or not - if (this._context === nextUnmaskedContext) { - nextContext = inst.context; - } else { - nextContext = this._processContext(nextUnmaskedContext); - willReceive = true; - } +var api = exports; - var prevProps = prevParentElement.props; - var nextProps = nextParentElement.props; +api.define = function define(name, body) { + return new Entity(name, body); +}; - // Not a simple state update but a props update - if (prevParentElement !== nextParentElement) { - willReceive = true; - } +function Entity(name, body) { + this.name = name; + this.body = body; - // An update here will schedule an update but immediately set - // _pendingStateQueue which will ensure that any state updates gets - // immediately reconciled instead of waiting for the next batch. - if (willReceive && inst.componentWillReceiveProps) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillReceiveProps(nextProps, nextContext); - }, this._debugID, 'componentWillReceiveProps'); - } else { - inst.componentWillReceiveProps(nextProps, nextContext); - } - } + this.decoders = {}; + this.encoders = {}; +}; - var nextState = this._processPendingState(nextProps, nextContext); - var shouldUpdate = true; +Entity.prototype._createNamed = function createNamed(base) { + var named; + try { + named = __webpack_require__(441).runInThisContext( + '(function ' + this.name + '(entity) {\n' + + ' this._initNamed(entity);\n' + + '})' + ); + } catch (e) { + named = function (entity) { + this._initNamed(entity); + }; + } + inherits(named, base); + named.prototype._initNamed = function initnamed(entity) { + base.call(this, entity); + }; - if (!this._pendingForceUpdate) { - if (inst.shouldComponentUpdate) { - if (process.env.NODE_ENV !== 'production') { - shouldUpdate = measureLifeCyclePerf(function () { - return inst.shouldComponentUpdate(nextProps, nextState, nextContext); - }, this._debugID, 'shouldComponentUpdate'); - } else { - shouldUpdate = inst.shouldComponentUpdate(nextProps, nextState, nextContext); - } - } else { - if (this._compositeType === CompositeTypes.PureClass) { - shouldUpdate = !shallowEqual(prevProps, nextProps) || !shallowEqual(inst.state, nextState); - } - } - } + return new named(this); +}; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(shouldUpdate !== undefined, '%s.shouldComponentUpdate(): Returned undefined instead of a ' + 'boolean value. Make sure to return true or false.', this.getName() || 'ReactCompositeComponent') : void 0; - } +Entity.prototype._getDecoder = function _getDecoder(enc) { + enc = enc || 'der'; + // Lazily create decoder + if (!this.decoders.hasOwnProperty(enc)) + this.decoders[enc] = this._createNamed(asn1.decoders[enc]); + return this.decoders[enc]; +}; - this._updateBatchNumber = null; - if (shouldUpdate) { - this._pendingForceUpdate = false; - // Will set `this.props`, `this.state` and `this.context`. - this._performComponentUpdate(nextParentElement, nextProps, nextState, nextContext, transaction, nextUnmaskedContext); - } else { - // If it's determined that a component should not update, we still want - // to set props and state but we shortcut the rest of the update. - this._currentElement = nextParentElement; - this._context = nextUnmaskedContext; - inst.props = nextProps; - inst.state = nextState; - inst.context = nextContext; - } - }, +Entity.prototype.decode = function decode(data, enc, options) { + return this._getDecoder(enc).decode(data, options); +}; - _processPendingState: function (props, context) { - var inst = this._instance; - var queue = this._pendingStateQueue; - var replace = this._pendingReplaceState; - this._pendingReplaceState = false; - this._pendingStateQueue = null; +Entity.prototype._getEncoder = function _getEncoder(enc) { + enc = enc || 'der'; + // Lazily create encoder + if (!this.encoders.hasOwnProperty(enc)) + this.encoders[enc] = this._createNamed(asn1.encoders[enc]); + return this.encoders[enc]; +}; - if (!queue) { - return inst.state; +Entity.prototype.encode = function encode(data, enc, /* internal */ reporter) { + return this._getEncoder(enc).encode(data, reporter); +}; + + +/***/ }), +/* 441 */ +/***/ (function(module, exports, __webpack_require__) { + +var indexOf = __webpack_require__(442); + +var Object_keys = function (obj) { + if (Object.keys) return Object.keys(obj) + else { + var res = []; + for (var key in obj) res.push(key) + return res; } +}; - if (replace && queue.length === 1) { - return queue[0]; +var forEach = function (xs, fn) { + if (xs.forEach) return xs.forEach(fn) + else for (var i = 0; i < xs.length; i++) { + fn(xs[i], i, xs); } +}; - var nextState = _assign({}, replace ? queue[0] : inst.state); - for (var i = replace ? 1 : 0; i < queue.length; i++) { - var partial = queue[i]; - _assign(nextState, typeof partial === 'function' ? partial.call(inst, nextState, props, context) : partial); +var defineProp = (function() { + try { + Object.defineProperty({}, '_', {}); + return function(obj, name, value) { + Object.defineProperty(obj, name, { + writable: true, + enumerable: false, + configurable: true, + value: value + }) + }; + } catch(e) { + return function(obj, name, value) { + obj[name] = value; + }; } +}()); - return nextState; - }, +var globals = ['Array', 'Boolean', 'Date', 'Error', 'EvalError', 'Function', +'Infinity', 'JSON', 'Math', 'NaN', 'Number', 'Object', 'RangeError', +'ReferenceError', 'RegExp', 'String', 'SyntaxError', 'TypeError', 'URIError', +'decodeURI', 'decodeURIComponent', 'encodeURI', 'encodeURIComponent', 'escape', +'eval', 'isFinite', 'isNaN', 'parseFloat', 'parseInt', 'undefined', 'unescape']; - /** - * Merges new props and state, notifies delegate methods of update and - * performs update. - * - * @param {ReactElement} nextElement Next element - * @param {object} nextProps Next public object to set as properties. - * @param {?object} nextState Next object to set as state. - * @param {?object} nextContext Next public object to set as context. - * @param {ReactReconcileTransaction} transaction - * @param {?object} unmaskedContext - * @private - */ - _performComponentUpdate: function (nextElement, nextProps, nextState, nextContext, transaction, unmaskedContext) { - var _this2 = this; +function Context() {} +Context.prototype = {}; - var inst = this._instance; +var Script = exports.Script = function NodeScript (code) { + if (!(this instanceof Script)) return new Script(code); + this.code = code; +}; - var hasComponentDidUpdate = Boolean(inst.componentDidUpdate); - var prevProps; - var prevState; - var prevContext; - if (hasComponentDidUpdate) { - prevProps = inst.props; - prevState = inst.state; - prevContext = inst.context; - } +Script.prototype.runInContext = function (context) { + if (!(context instanceof Context)) { + throw new TypeError("needs a 'context' argument."); + } + + var iframe = document.createElement('iframe'); + if (!iframe.style) iframe.style = {}; + iframe.style.display = 'none'; + + document.body.appendChild(iframe); + + var win = iframe.contentWindow; + var wEval = win.eval, wExecScript = win.execScript; + + if (!wEval && wExecScript) { + // win.eval() magically appears when this is called in IE: + wExecScript.call(win, 'null'); + wEval = win.eval; + } + + forEach(Object_keys(context), function (key) { + win[key] = context[key]; + }); + forEach(globals, function (key) { + if (context[key]) { + win[key] = context[key]; + } + }); + + var winKeys = Object_keys(win); + + var res = wEval.call(win, this.code); + + forEach(Object_keys(win), function (key) { + // Avoid copying circular objects like `top` and `window` by only + // updating existing context properties or new properties in the `win` + // that was only introduced after the eval. + if (key in context || indexOf(winKeys, key) === -1) { + context[key] = win[key]; + } + }); - if (inst.componentWillUpdate) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillUpdate(nextProps, nextState, nextContext); - }, this._debugID, 'componentWillUpdate'); - } else { - inst.componentWillUpdate(nextProps, nextState, nextContext); - } - } + forEach(globals, function (key) { + if (!(key in context)) { + defineProp(context, key, win[key]); + } + }); + + document.body.removeChild(iframe); + + return res; +}; - this._currentElement = nextElement; - this._context = unmaskedContext; - inst.props = nextProps; - inst.state = nextState; - inst.context = nextContext; +Script.prototype.runInThisContext = function () { + return eval(this.code); // maybe... +}; + +Script.prototype.runInNewContext = function (context) { + var ctx = Script.createContext(context); + var res = this.runInContext(ctx); + + forEach(Object_keys(ctx), function (key) { + context[key] = ctx[key]; + }); - this._updateRenderedComponent(transaction, unmaskedContext); + return res; +}; - if (hasComponentDidUpdate) { - if (process.env.NODE_ENV !== 'production') { - transaction.getReactMountReady().enqueue(function () { - measureLifeCyclePerf(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), _this2._debugID, 'componentDidUpdate'); - }); - } else { - transaction.getReactMountReady().enqueue(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), inst); - } - } - }, +forEach(Object_keys(Script.prototype), function (name) { + exports[name] = Script[name] = function (code) { + var s = Script(code); + return s[name].apply(s, [].slice.call(arguments, 1)); + }; +}); - /** - * Call the component's `render` method and update the DOM accordingly. - * - * @param {ReactReconcileTransaction} transaction - * @internal - */ - _updateRenderedComponent: function (transaction, context) { - var prevComponentInstance = this._renderedComponent; - var prevRenderedElement = prevComponentInstance._currentElement; - var nextRenderedElement = this._renderValidatedComponent(); +exports.createScript = function (code) { + return exports.Script(code); +}; - var debugID = 0; - if (process.env.NODE_ENV !== 'production') { - debugID = this._debugID; +exports.createContext = Script.createContext = function (context) { + var copy = new Context(); + if(typeof context === 'object') { + forEach(Object_keys(context), function (key) { + copy[key] = context[key]; + }); } + return copy; +}; - if (shouldUpdateReactComponent(prevRenderedElement, nextRenderedElement)) { - ReactReconciler.receiveComponent(prevComponentInstance, nextRenderedElement, transaction, this._processChildContext(context)); - } else { - var oldHostNode = ReactReconciler.getHostNode(prevComponentInstance); - ReactReconciler.unmountComponent(prevComponentInstance, false); - var nodeType = ReactNodeTypes.getType(nextRenderedElement); - this._renderedNodeType = nodeType; - var child = this._instantiateReactComponent(nextRenderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ - ); - this._renderedComponent = child; +/***/ }), +/* 442 */ +/***/ (function(module, exports) { - var nextMarkup = ReactReconciler.mountComponent(child, transaction, this._hostParent, this._hostContainerInfo, this._processChildContext(context), debugID); - if (process.env.NODE_ENV !== 'production') { - if (debugID !== 0) { - var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; - ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); - } - } +var indexOf = [].indexOf; - this._replaceNodeWithMarkup(oldHostNode, nextMarkup, prevComponentInstance); - } - }, +module.exports = function(arr, obj){ + if (indexOf) return arr.indexOf(obj); + for (var i = 0; i < arr.length; ++i) { + if (arr[i] === obj) return i; + } + return -1; +}; - /** - * Overridden in shallow rendering. - * - * @protected - */ - _replaceNodeWithMarkup: function (oldHostNode, nextMarkup, prevInstance) { - ReactComponentEnvironment.replaceNodeWithMarkup(oldHostNode, nextMarkup, prevInstance); - }, +/***/ }), +/* 443 */ +/***/ (function(module, exports, __webpack_require__) { - /** - * @protected - */ - _renderValidatedComponentWithoutOwnerOrContext: function () { - var inst = this._instance; - var renderedElement; +var inherits = __webpack_require__(4); - if (process.env.NODE_ENV !== 'production') { - renderedElement = measureLifeCyclePerf(function () { - return inst.render(); - }, this._debugID, 'render'); - } else { - renderedElement = inst.render(); - } +function Reporter(options) { + this._reporterState = { + obj: null, + path: [], + options: options || {}, + errors: [] + }; +} +exports.Reporter = Reporter; - if (process.env.NODE_ENV !== 'production') { - // We allow auto-mocks to proceed as if they're returning null. - if (renderedElement === undefined && inst.render._isMockFunction) { - // This is probably bad practice. Consider warning here and - // deprecating this convenience. - renderedElement = null; - } - } +Reporter.prototype.isError = function isError(obj) { + return obj instanceof ReporterError; +}; - return renderedElement; - }, +Reporter.prototype.save = function save() { + var state = this._reporterState; - /** - * @private - */ - _renderValidatedComponent: function () { - var renderedElement; - if (process.env.NODE_ENV !== 'production' || this._compositeType !== CompositeTypes.StatelessFunctional) { - ReactCurrentOwner.current = this; - try { - renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); - } finally { - ReactCurrentOwner.current = null; - } - } else { - renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); - } - !( - // TODO: An `isValidNode` function would probably be more appropriate - renderedElement === null || renderedElement === false || React.isValidElement(renderedElement)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.render(): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', this.getName() || 'ReactCompositeComponent') : _prodInvariant('109', this.getName() || 'ReactCompositeComponent') : void 0; + return { obj: state.obj, pathLen: state.path.length }; +}; - return renderedElement; - }, +Reporter.prototype.restore = function restore(data) { + var state = this._reporterState; - /** - * Lazily allocates the refs object and stores `component` as `ref`. - * - * @param {string} ref Reference name. - * @param {component} component Component to store as `ref`. - * @final - * @private - */ - attachRef: function (ref, component) { - var inst = this.getPublicInstance(); - !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Stateless function components cannot have refs.') : _prodInvariant('110') : void 0; - var publicComponentInstance = component.getPublicInstance(); - if (process.env.NODE_ENV !== 'production') { - var componentName = component && component.getName ? component.getName() : 'a component'; - process.env.NODE_ENV !== 'production' ? warning(publicComponentInstance != null || component._compositeType !== CompositeTypes.StatelessFunctional, 'Stateless function components cannot be given refs ' + '(See ref "%s" in %s created by %s). ' + 'Attempts to access this ref will fail.', ref, componentName, this.getName()) : void 0; - } - var refs = inst.refs === emptyObject ? inst.refs = {} : inst.refs; - refs[ref] = publicComponentInstance; - }, + state.obj = data.obj; + state.path = state.path.slice(0, data.pathLen); +}; - /** - * Detaches a reference name. - * - * @param {string} ref Name to dereference. - * @final - * @private - */ - detachRef: function (ref) { - var refs = this.getPublicInstance().refs; - delete refs[ref]; - }, +Reporter.prototype.enterKey = function enterKey(key) { + return this._reporterState.path.push(key); +}; - /** - * Get a text description of the component that can be used to identify it - * in error messages. - * @return {string} The name or null. - * @internal - */ - getName: function () { - var type = this._currentElement.type; - var constructor = this._instance && this._instance.constructor; - return type.displayName || constructor && constructor.displayName || type.name || constructor && constructor.name || null; - }, +Reporter.prototype.exitKey = function exitKey(index) { + var state = this._reporterState; - /** - * Get the publicly accessible representation of this component - i.e. what - * is exposed by refs and returned by render. Can be null for stateless - * components. - * - * @return {ReactComponent} the public component instance. - * @internal - */ - getPublicInstance: function () { - var inst = this._instance; - if (this._compositeType === CompositeTypes.StatelessFunctional) { - return null; - } - return inst; - }, + state.path = state.path.slice(0, index - 1); +}; - // Stub - _instantiateReactComponent: null +Reporter.prototype.leaveKey = function leaveKey(index, key, value) { + var state = this._reporterState; + + this.exitKey(index); + if (state.obj !== null) + state.obj[key] = value; }; -module.exports = ReactCompositeComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Reporter.prototype.path = function path() { + return this._reporterState.path.join('/'); +}; -/***/ }), -/* 177 */ -/***/ (function(module, exports, __webpack_require__) { +Reporter.prototype.enterObject = function enterObject() { + var state = this._reporterState; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var prev = state.obj; + state.obj = {}; + return prev; +}; +Reporter.prototype.leaveObject = function leaveObject(prev) { + var state = this._reporterState; + var now = state.obj; + state.obj = prev; + return now; +}; -var _prodInvariant = __webpack_require__(3); +Reporter.prototype.error = function error(msg) { + var err; + var state = this._reporterState; -var ReactPropTypeLocationNames = __webpack_require__(178); -var ReactPropTypesSecret = __webpack_require__(94); + var inherited = msg instanceof ReporterError; + if (inherited) { + err = msg; + } else { + err = new ReporterError(state.path.map(function(elem) { + return '[' + JSON.stringify(elem) + ']'; + }).join(''), msg.message || msg, msg.stack); + } -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); + if (!state.options.partial) + throw err; -var ReactComponentTreeHook; + if (!inherited) + state.errors.push(err); -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} + return err; +}; -var loggedTypeFailures = {}; +Reporter.prototype.wrapResult = function wrapResult(result) { + var state = this._reporterState; + if (!state.options.partial) + return result; -/** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. - * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?object} element The React element that is being type-checked - * @param {?number} debugID The React component instance that is being type-checked - * @private - */ -function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; + return { + result: this.isError(result) ? null : result, + errors: state.errors + }; +}; - var componentStackInfo = ''; +function ReporterError(path, msg) { + this.path = path; + this.rethrow(msg); +}; +inherits(ReporterError, Error); - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (debugID !== null) { - componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); - } else if (element !== null) { - componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); - } - } +ReporterError.prototype.rethrow = function rethrow(msg) { + this.message = msg + ' at: ' + (this.path || '(shallow)'); + if (Error.captureStackTrace) + Error.captureStackTrace(this, ReporterError); - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; - } + if (!this.stack) { + try { + // IE only adds stack when thrown + throw new Error(this.message); + } catch (e) { + this.stack = e.stack; } } -} + return this; +}; -module.exports = checkReactTypeSpec; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 178 */ +/* 444 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var Reporter = __webpack_require__(53).Reporter; +var EncoderBuffer = __webpack_require__(53).EncoderBuffer; +var DecoderBuffer = __webpack_require__(53).DecoderBuffer; +var assert = __webpack_require__(21); + +// Supported tags +var tags = [ + 'seq', 'seqof', 'set', 'setof', 'objid', 'bool', + 'gentime', 'utctime', 'null_', 'enum', 'int', 'objDesc', + 'bitstr', 'bmpstr', 'charstr', 'genstr', 'graphstr', 'ia5str', 'iso646str', + 'numstr', 'octstr', 'printstr', 't61str', 'unistr', 'utf8str', 'videostr' +]; + +// Public methods list +var methods = [ + 'key', 'obj', 'use', 'optional', 'explicit', 'implicit', 'def', 'choice', + 'any', 'contains' +].concat(tags); + +// Overrided methods list +var overrided = [ + '_peekTag', '_decodeTag', '_use', + '_decodeStr', '_decodeObjid', '_decodeTime', + '_decodeNull', '_decodeInt', '_decodeBool', '_decodeList', + + '_encodeComposite', '_encodeStr', '_encodeObjid', '_encodeTime', + '_encodeNull', '_encodeInt', '_encodeBool' +]; + +function Node(enc, parent) { + var state = {}; + this._baseState = state; + + state.enc = enc; + + state.parent = parent || null; + state.children = null; + + // State + state.tag = null; + state.args = null; + state.reverseArgs = null; + state.choice = null; + state.optional = false; + state.any = false; + state.obj = false; + state.use = null; + state.useDecoder = null; + state.key = null; + state['default'] = null; + state.explicit = null; + state.implicit = null; + state.contains = null; + + // Should create new instance on each method + if (!state.parent) { + state.children = []; + this._wrap(); + } +} +module.exports = Node; + +var stateProps = [ + 'enc', 'parent', 'children', 'tag', 'args', 'reverseArgs', 'choice', + 'optional', 'any', 'obj', 'use', 'alteredUse', 'key', 'default', 'explicit', + 'implicit', 'contains' +]; + +Node.prototype.clone = function clone() { + var state = this._baseState; + var cstate = {}; + stateProps.forEach(function(prop) { + cstate[prop] = state[prop]; + }); + var res = new this.constructor(cstate.parent); + res._baseState = cstate; + return res; +}; +Node.prototype._wrap = function wrap() { + var state = this._baseState; + methods.forEach(function(method) { + this[method] = function _wrappedMethod() { + var clone = new this.constructor(this); + state.children.push(clone); + return clone[method].apply(clone, arguments); + }; + }, this); +}; +Node.prototype._init = function init(body) { + var state = this._baseState; -var ReactPropTypeLocationNames = {}; + assert(state.parent === null); + body.call(this); -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' + // Filter children + state.children = state.children.filter(function(child) { + return child._baseState.parent === this; + }, this); + assert.equal(state.children.length, 1, 'Root node can have only one child'); +}; + +Node.prototype._useArgs = function useArgs(args) { + var state = this._baseState; + + // Filter children and args + var children = args.filter(function(arg) { + return arg instanceof this.constructor; + }, this); + args = args.filter(function(arg) { + return !(arg instanceof this.constructor); + }, this); + + if (children.length !== 0) { + assert(state.children === null); + state.children = children; + + // Replace parent to maintain backward link + children.forEach(function(child) { + child._baseState.parent = this; + }, this); + } + if (args.length !== 0) { + assert(state.args === null); + state.args = args; + state.reverseArgs = args.map(function(arg) { + if (typeof arg !== 'object' || arg.constructor !== Object) + return arg; + + var res = {}; + Object.keys(arg).forEach(function(key) { + if (key == (key | 0)) + key |= 0; + var value = arg[key]; + res[value] = key; + }); + return res; + }); + } +}; + +// +// Overrided methods +// + +overrided.forEach(function(method) { + Node.prototype[method] = function _overrided() { + var state = this._baseState; + throw new Error(method + ' not implemented for encoding: ' + state.enc); }; -} +}); -module.exports = ReactPropTypeLocationNames; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +// +// Public methods +// -/***/ }), -/* 179 */ -/***/ (function(module, exports, __webpack_require__) { +tags.forEach(function(tag) { + Node.prototype[tag] = function _tagMethod() { + var state = this._baseState; + var args = Array.prototype.slice.call(arguments); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + assert(state.tag === null); + state.tag = tag; + this._useArgs(args); + return this; + }; +}); -var nextDebugID = 1; +Node.prototype.use = function use(item) { + assert(item); + var state = this._baseState; -function getNextDebugID() { - return nextDebugID++; -} + assert(state.use === null); + state.use = item; -module.exports = getNextDebugID; + return this; +}; -/***/ }), -/* 180 */ -/***/ (function(module, exports, __webpack_require__) { +Node.prototype.optional = function optional() { + var state = this._baseState; -"use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + state.optional = true; + return this; +}; +Node.prototype.def = function def(val) { + var state = this._baseState; -// The Symbol used to tag the ReactElement type. If there is no native Symbol -// nor polyfill, then a plain number is used for performance. + assert(state['default'] === null); + state['default'] = val; + state.optional = true; -var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; + return this; +}; -module.exports = REACT_ELEMENT_TYPE; +Node.prototype.explicit = function explicit(num) { + var state = this._baseState; -/***/ }), -/* 181 */ -/***/ (function(module, exports, __webpack_require__) { + assert(state.explicit === null && state.implicit === null); + state.explicit = num; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + return this; +}; +Node.prototype.implicit = function implicit(num) { + var state = this._baseState; + assert(state.explicit === null && state.implicit === null); + state.implicit = num; -/* global Symbol */ + return this; +}; -var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; -var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. +Node.prototype.obj = function obj() { + var state = this._baseState; + var args = Array.prototype.slice.call(arguments); -/** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } - * - * @param {?object} maybeIterable - * @return {?function} - */ -function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; - } -} + state.obj = true; -module.exports = getIteratorFn; + if (args.length !== 0) + this._useArgs(args); -/***/ }), -/* 182 */ -/***/ (function(module, exports, __webpack_require__) { + return this; +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Node.prototype.key = function key(newKey) { + var state = this._baseState; + assert(state.key === null); + state.key = newKey; + return this; +}; -var KeyEscapeUtils = __webpack_require__(62); -var traverseAllChildren = __webpack_require__(100); -var warning = __webpack_require__(2); +Node.prototype.any = function any() { + var state = this._baseState; -var ReactComponentTreeHook; + state.any = true; -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} + return this; +}; -/** - * @param {function} traverseContext Context passed through traversal. - * @param {?ReactComponent} child React child component. - * @param {!string} name String name of key path to child. - * @param {number=} selfDebugID Optional debugID of the current internal instance. - */ -function flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID) { - // We found a component instance. - if (traverseContext && typeof traverseContext === 'object') { - var result = traverseContext; - var keyUnique = result[name] === undefined; - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (!keyUnique) { - process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; +Node.prototype.choice = function choice(obj) { + var state = this._baseState; + + assert(state.choice === null); + state.choice = obj; + this._useArgs(Object.keys(obj).map(function(key) { + return obj[key]; + })); + + return this; +}; + +Node.prototype.contains = function contains(item) { + var state = this._baseState; + + assert(state.use === null); + state.contains = item; + + return this; +}; + +// +// Decoding +// + +Node.prototype._decode = function decode(input, options) { + var state = this._baseState; + + // Decode root node + if (state.parent === null) + return input.wrapResult(state.children[0]._decode(input, options)); + + var result = state['default']; + var present = true; + + var prevKey = null; + if (state.key !== null) + prevKey = input.enterKey(state.key); + + // Check if tag is there + if (state.optional) { + var tag = null; + if (state.explicit !== null) + tag = state.explicit; + else if (state.implicit !== null) + tag = state.implicit; + else if (state.tag !== null) + tag = state.tag; + + if (tag === null && !state.any) { + // Trial and Error + var save = input.save(); + try { + if (state.choice === null) + this._decodeGeneric(state.tag, input, options); + else + this._decodeChoice(input, options); + present = true; + } catch (e) { + present = false; } + input.restore(save); + } else { + present = this._peekTag(input, tag, state.any); + + if (input.isError(present)) + return present; } - if (keyUnique && child != null) { - result[name] = child; + } + + // Push object on stack + var prevObj; + if (state.obj && present) + prevObj = input.enterObject(); + + if (present) { + // Unwrap explicit values + if (state.explicit !== null) { + var explicit = this._decodeTag(input, state.explicit); + if (input.isError(explicit)) + return explicit; + input = explicit; + } + + var start = input.offset; + + // Unwrap implicit and normal values + if (state.use === null && state.choice === null) { + if (state.any) + var save = input.save(); + var body = this._decodeTag( + input, + state.implicit !== null ? state.implicit : state.tag, + state.any + ); + if (input.isError(body)) + return body; + + if (state.any) + result = input.raw(save); + else + input = body; + } + + if (options && options.track && state.tag !== null) + options.track(input.path(), start, input.length, 'tagged'); + + if (options && options.track && state.tag !== null) + options.track(input.path(), input.offset, input.length, 'content'); + + // Select proper method for tag + if (state.any) + result = result; + else if (state.choice === null) + result = this._decodeGeneric(state.tag, input, options); + else + result = this._decodeChoice(input, options); + + if (input.isError(result)) + return result; + + // Decode children + if (!state.any && state.choice === null && state.children !== null) { + state.children.forEach(function decodeChildren(child) { + // NOTE: We are ignoring errors here, to let parser continue with other + // parts of encoded data + child._decode(input, options); + }); + } + + // Decode contained/encoded by schema, only in bit or octet strings + if (state.contains && (state.tag === 'octstr' || state.tag === 'bitstr')) { + var data = new DecoderBuffer(result); + result = this._getUse(state.contains, input._reporterState.obj) + ._decode(data, options); } } -} -/** - * Flattens children that are typically specified as `props.children`. Any null - * children will not be included in the resulting object. - * @return {!object} flattened children keyed by name. - */ -function flattenChildren(children, selfDebugID) { - if (children == null) { - return children; + // Pop object + if (state.obj && present) + result = input.leaveObject(prevObj); + + // Set key + if (state.key !== null && (result !== null || present === true)) + input.leaveKey(prevKey, state.key, result); + else if (prevKey !== null) + input.exitKey(prevKey); + + return result; +}; + +Node.prototype._decodeGeneric = function decodeGeneric(tag, input, options) { + var state = this._baseState; + + if (tag === 'seq' || tag === 'set') + return null; + if (tag === 'seqof' || tag === 'setof') + return this._decodeList(input, tag, state.args[0], options); + else if (/str$/.test(tag)) + return this._decodeStr(input, tag, options); + else if (tag === 'objid' && state.args) + return this._decodeObjid(input, state.args[0], state.args[1], options); + else if (tag === 'objid') + return this._decodeObjid(input, null, null, options); + else if (tag === 'gentime' || tag === 'utctime') + return this._decodeTime(input, tag, options); + else if (tag === 'null_') + return this._decodeNull(input, options); + else if (tag === 'bool') + return this._decodeBool(input, options); + else if (tag === 'objDesc') + return this._decodeStr(input, tag, options); + else if (tag === 'int' || tag === 'enum') + return this._decodeInt(input, state.args && state.args[0], options); + + if (state.use !== null) { + return this._getUse(state.use, input._reporterState.obj) + ._decode(input, options); + } else { + return input.error('unknown tag: ' + tag); } - var result = {}; +}; - if (process.env.NODE_ENV !== 'production') { - traverseAllChildren(children, function (traverseContext, child, name) { - return flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID); - }, result); +Node.prototype._getUse = function _getUse(entity, obj) { + + var state = this._baseState; + // Create altered use decoder if implicit is set + state.useDecoder = this._use(entity, obj); + assert(state.useDecoder._baseState.parent === null); + state.useDecoder = state.useDecoder._baseState.children[0]; + if (state.implicit !== state.useDecoder._baseState.implicit) { + state.useDecoder = state.useDecoder.clone(); + state.useDecoder._baseState.implicit = state.implicit; + } + return state.useDecoder; +}; + +Node.prototype._decodeChoice = function decodeChoice(input, options) { + var state = this._baseState; + var result = null; + var match = false; + + Object.keys(state.choice).some(function(key) { + var save = input.save(); + var node = state.choice[key]; + try { + var value = node._decode(input, options); + if (input.isError(value)) + return false; + + result = { type: key, value: value }; + match = true; + } catch (e) { + input.restore(save); + return false; + } + return true; + }, this); + + if (!match) + return input.error('Choice not matched'); + + return result; +}; + +// +// Encoding +// + +Node.prototype._createEncoderBuffer = function createEncoderBuffer(data) { + return new EncoderBuffer(data, this.reporter); +}; + +Node.prototype._encode = function encode(data, reporter, parent) { + var state = this._baseState; + if (state['default'] !== null && state['default'] === data) + return; + + var result = this._encodeValue(data, reporter, parent); + if (result === undefined) + return; + + if (this._skipDefault(result, reporter, parent)) + return; + + return result; +}; + +Node.prototype._encodeValue = function encode(data, reporter, parent) { + var state = this._baseState; + + // Decode root node + if (state.parent === null) + return state.children[0]._encode(data, reporter || new Reporter()); + + var result = null; + + // Set reporter to share it with a child class + this.reporter = reporter; + + // Check if data is there + if (state.optional && data === undefined) { + if (state['default'] !== null) + data = state['default'] + else + return; + } + + // Encode children first + var content = null; + var primitive = false; + if (state.any) { + // Anything that was given is translated to buffer + result = this._createEncoderBuffer(data); + } else if (state.choice) { + result = this._encodeChoice(data, reporter); + } else if (state.contains) { + content = this._getUse(state.contains, parent)._encode(data, reporter); + primitive = true; + } else if (state.children) { + content = state.children.map(function(child) { + if (child._baseState.tag === 'null_') + return child._encode(null, reporter, data); + + if (child._baseState.key === null) + return reporter.error('Child should have a key'); + var prevKey = reporter.enterKey(child._baseState.key); + + if (typeof data !== 'object') + return reporter.error('Child expected, but input is not object'); + + var res = child._encode(data[child._baseState.key], reporter, data); + reporter.leaveKey(prevKey); + + return res; + }, this).filter(function(child) { + return child; + }); + content = this._createEncoderBuffer(content); } else { - traverseAllChildren(children, flattenSingleChildIntoContext, result); + if (state.tag === 'seqof' || state.tag === 'setof') { + // TODO(indutny): this should be thrown on DSL level + if (!(state.args && state.args.length === 1)) + return reporter.error('Too many args for : ' + state.tag); + + if (!Array.isArray(data)) + return reporter.error('seqof/setof, but data is not Array'); + + var child = this.clone(); + child._baseState.implicit = null; + content = this._createEncoderBuffer(data.map(function(item) { + var state = this._baseState; + + return this._getUse(state.args[0], data)._encode(item, reporter); + }, child)); + } else if (state.use !== null) { + result = this._getUse(state.use, parent)._encode(data, reporter); + } else { + content = this._encodePrimitive(state.tag, data); + primitive = true; + } + } + + // Encode data itself + var result; + if (!state.any && state.choice === null) { + var tag = state.implicit !== null ? state.implicit : state.tag; + var cls = state.implicit === null ? 'universal' : 'context'; + + if (tag === null) { + if (state.use === null) + reporter.error('Tag could be ommited only for .use()'); + } else { + if (state.use === null) + result = this._encodeComposite(tag, primitive, cls, content); + } } + + // Wrap in explicit + if (state.explicit !== null) + result = this._encodeComposite(state.explicit, false, 'context', result); + return result; -} +}; + +Node.prototype._encodeChoice = function encodeChoice(data, reporter) { + var state = this._baseState; + + var node = state.choice[data.type]; + if (!node) { + assert( + false, + data.type + ' not found in ' + + JSON.stringify(Object.keys(state.choice))); + } + return node._encode(data.value, reporter); +}; + +Node.prototype._encodePrimitive = function encodePrimitive(tag, data) { + var state = this._baseState; + + if (/str$/.test(tag)) + return this._encodeStr(data, tag); + else if (tag === 'objid' && state.args) + return this._encodeObjid(data, state.reverseArgs[0], state.args[1]); + else if (tag === 'objid') + return this._encodeObjid(data, null, null); + else if (tag === 'gentime' || tag === 'utctime') + return this._encodeTime(data, tag); + else if (tag === 'null_') + return this._encodeNull(); + else if (tag === 'int' || tag === 'enum') + return this._encodeInt(data, state.args && state.reverseArgs[0]); + else if (tag === 'bool') + return this._encodeBool(data); + else if (tag === 'objDesc') + return this._encodeStr(data, tag); + else + throw new Error('Unsupported tag: ' + tag); +}; + +Node.prototype._isNumstr = function isNumstr(str) { + return /^[0-9 ]*$/.test(str); +}; + +Node.prototype._isPrintstr = function isPrintstr(str) { + return /^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(str); +}; -module.exports = flattenChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 183 */ +/* 445 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var constants = __webpack_require__(192); +exports.tagClass = { + 0: 'universal', + 1: 'application', + 2: 'context', + 3: 'private' +}; +exports.tagClassByName = constants._reverse(exports.tagClass); + +exports.tag = { + 0x00: 'end', + 0x01: 'bool', + 0x02: 'int', + 0x03: 'bitstr', + 0x04: 'octstr', + 0x05: 'null_', + 0x06: 'objid', + 0x07: 'objDesc', + 0x08: 'external', + 0x09: 'real', + 0x0a: 'enum', + 0x0b: 'embed', + 0x0c: 'utf8str', + 0x0d: 'relativeOid', + 0x10: 'seq', + 0x11: 'set', + 0x12: 'numstr', + 0x13: 'printstr', + 0x14: 't61str', + 0x15: 'videostr', + 0x16: 'ia5str', + 0x17: 'utctime', + 0x18: 'gentime', + 0x19: 'graphstr', + 0x1a: 'iso646str', + 0x1b: 'genstr', + 0x1c: 'unistr', + 0x1d: 'charstr', + 0x1e: 'bmpstr' +}; +exports.tagByName = constants._reverse(exports.tag); -var _assign = __webpack_require__(5); +/***/ }), +/* 446 */ +/***/ (function(module, exports, __webpack_require__) { -var PooledClass = __webpack_require__(20); -var Transaction = __webpack_require__(41); -var ReactInstrumentation = __webpack_require__(13); -var ReactServerUpdateQueue = __webpack_require__(184); +var decoders = exports; -/** - * Executed within the scope of the `Transaction` instance. Consider these as - * being member methods, but with an implied ordering while being isolated from - * each other. - */ -var TRANSACTION_WRAPPERS = []; +decoders.der = __webpack_require__(193); +decoders.pem = __webpack_require__(447); -if (process.env.NODE_ENV !== 'production') { - TRANSACTION_WRAPPERS.push({ - initialize: ReactInstrumentation.debugTool.onBeginFlush, - close: ReactInstrumentation.debugTool.onEndFlush - }); -} -var noopCallbackQueue = { - enqueue: function () {} +/***/ }), +/* 447 */ +/***/ (function(module, exports, __webpack_require__) { + +var inherits = __webpack_require__(4); +var Buffer = __webpack_require__(1).Buffer; + +var DERDecoder = __webpack_require__(193); + +function PEMDecoder(entity) { + DERDecoder.call(this, entity); + this.enc = 'pem'; }; +inherits(PEMDecoder, DERDecoder); +module.exports = PEMDecoder; -/** - * @class ReactServerRenderingTransaction - * @param {boolean} renderToStaticMarkup - */ -function ReactServerRenderingTransaction(renderToStaticMarkup) { - this.reinitializeTransaction(); - this.renderToStaticMarkup = renderToStaticMarkup; - this.useCreateElement = false; - this.updateQueue = new ReactServerUpdateQueue(this); -} +PEMDecoder.prototype.decode = function decode(data, options) { + var lines = data.toString().split(/[\r\n]+/g); -var Mixin = { - /** - * @see Transaction - * @abstract - * @final - * @return {array} Empty list of operation wrap procedures. - */ - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, + var label = options.label.toUpperCase(); - /** - * @return {object} The queue to collect `onDOMReady` callbacks with. - */ - getReactMountReady: function () { - return noopCallbackQueue; - }, + var re = /^-----(BEGIN|END) ([^-]+)-----$/; + var start = -1; + var end = -1; + for (var i = 0; i < lines.length; i++) { + var match = lines[i].match(re); + if (match === null) + continue; - /** - * @return {object} The queue to collect React async events. - */ - getUpdateQueue: function () { - return this.updateQueue; - }, + if (match[2] !== label) + continue; - /** - * `PooledClass` looks for this, and will invoke this before allowing this - * instance to be reused. - */ - destructor: function () {}, + if (start === -1) { + if (match[1] !== 'BEGIN') + break; + start = i; + } else { + if (match[1] !== 'END') + break; + end = i; + break; + } + } + if (start === -1 || end === -1) + throw new Error('PEM section not found for: ' + label); - checkpoint: function () {}, + var base64 = lines.slice(start + 1, end).join(''); + // Remove excessive symbols + base64.replace(/[^a-z0-9\+\/=]+/gi, ''); - rollback: function () {} + var input = new Buffer(base64, 'base64'); + return DERDecoder.prototype.decode.call(this, input, options); }; -_assign(ReactServerRenderingTransaction.prototype, Transaction, Mixin); -PooledClass.addPoolingTo(ReactServerRenderingTransaction); +/***/ }), +/* 448 */ +/***/ (function(module, exports, __webpack_require__) { + +var encoders = exports; + +encoders.der = __webpack_require__(194); +encoders.pem = __webpack_require__(449); -module.exports = ReactServerRenderingTransaction; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 184 */ +/* 449 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var inherits = __webpack_require__(4); + +var DEREncoder = __webpack_require__(194); +function PEMEncoder(entity) { + DEREncoder.call(this, entity); + this.enc = 'pem'; +}; +inherits(PEMEncoder, DEREncoder); +module.exports = PEMEncoder; + +PEMEncoder.prototype.encode = function encode(data, options) { + var buf = DEREncoder.prototype.encode.call(this, data); + + var p = buf.toString('base64'); + var out = [ '-----BEGIN ' + options.label + '-----' ]; + for (var i = 0; i < p.length; i += 64) + out.push(p.slice(i, i + 64)); + out.push('-----END ' + options.label + '-----'); + return out.join('\n'); +}; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +/***/ }), +/* 450 */ +/***/ (function(module, exports, __webpack_require__) { -var ReactUpdateQueue = __webpack_require__(63); +"use strict"; +// from https://github.com/Rantanen/node-dtls/blob/25a7dc861bda38cfeac93a723500eea4f0ac2e86/Certificate.js +// thanks to @Rantanen + + + +var asn = __webpack_require__(52) + +var Time = asn.define('Time', function () { + this.choice({ + utcTime: this.utctime(), + generalTime: this.gentime() + }) +}) + +var AttributeTypeValue = asn.define('AttributeTypeValue', function () { + this.seq().obj( + this.key('type').objid(), + this.key('value').any() + ) +}) + +var AlgorithmIdentifier = asn.define('AlgorithmIdentifier', function () { + this.seq().obj( + this.key('algorithm').objid(), + this.key('parameters').optional() + ) +}) + +var SubjectPublicKeyInfo = asn.define('SubjectPublicKeyInfo', function () { + this.seq().obj( + this.key('algorithm').use(AlgorithmIdentifier), + this.key('subjectPublicKey').bitstr() + ) +}) + +var RelativeDistinguishedName = asn.define('RelativeDistinguishedName', function () { + this.setof(AttributeTypeValue) +}) + +var RDNSequence = asn.define('RDNSequence', function () { + this.seqof(RelativeDistinguishedName) +}) + +var Name = asn.define('Name', function () { + this.choice({ + rdnSequence: this.use(RDNSequence) + }) +}) + +var Validity = asn.define('Validity', function () { + this.seq().obj( + this.key('notBefore').use(Time), + this.key('notAfter').use(Time) + ) +}) + +var Extension = asn.define('Extension', function () { + this.seq().obj( + this.key('extnID').objid(), + this.key('critical').bool().def(false), + this.key('extnValue').octstr() + ) +}) + +var TBSCertificate = asn.define('TBSCertificate', function () { + this.seq().obj( + this.key('version').explicit(0).int(), + this.key('serialNumber').int(), + this.key('signature').use(AlgorithmIdentifier), + this.key('issuer').use(Name), + this.key('validity').use(Validity), + this.key('subject').use(Name), + this.key('subjectPublicKeyInfo').use(SubjectPublicKeyInfo), + this.key('issuerUniqueID').implicit(1).bitstr().optional(), + this.key('subjectUniqueID').implicit(2).bitstr().optional(), + this.key('extensions').explicit(3).seqof(Extension).optional() + ) +}) + +var X509Certificate = asn.define('X509Certificate', function () { + this.seq().obj( + this.key('tbsCertificate').use(TBSCertificate), + this.key('signatureAlgorithm').use(AlgorithmIdentifier), + this.key('signatureValue').bitstr() + ) +}) + +module.exports = X509Certificate -var warning = __webpack_require__(2); -function warnNoop(publicInstance, callerName) { - if (process.env.NODE_ENV !== 'production') { - var constructor = publicInstance.constructor; - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounting component. ' + 'This usually means you called %s() outside componentWillMount() on the server. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; +/***/ }), +/* 451 */ +/***/ (function(module, exports) { + +module.exports = { + "2.16.840.1.101.3.4.1.1": "aes-128-ecb", + "2.16.840.1.101.3.4.1.2": "aes-128-cbc", + "2.16.840.1.101.3.4.1.3": "aes-128-ofb", + "2.16.840.1.101.3.4.1.4": "aes-128-cfb", + "2.16.840.1.101.3.4.1.21": "aes-192-ecb", + "2.16.840.1.101.3.4.1.22": "aes-192-cbc", + "2.16.840.1.101.3.4.1.23": "aes-192-ofb", + "2.16.840.1.101.3.4.1.24": "aes-192-cfb", + "2.16.840.1.101.3.4.1.41": "aes-256-ecb", + "2.16.840.1.101.3.4.1.42": "aes-256-cbc", + "2.16.840.1.101.3.4.1.43": "aes-256-ofb", + "2.16.840.1.101.3.4.1.44": "aes-256-cfb" +}; + +/***/ }), +/* 452 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {// adapted from https://github.com/apatil/pemstrip +var findProc = /Proc-Type: 4,ENCRYPTED\n\r?DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)\n\r?\n\r?([0-9A-z\n\r\+\/\=]+)\n\r?/m +var startRegex = /^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----\n/m +var fullRegex = /^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----\n\r?([0-9A-z\n\r\+\/\=]+)\n\r?-----END \1-----$/m +var evp = __webpack_require__(68) +var ciphers = __webpack_require__(108) +module.exports = function (okey, password) { + var key = okey.toString() + var match = key.match(findProc) + var decrypted + if (!match) { + var match2 = key.match(fullRegex) + decrypted = new Buffer(match2[2].replace(/\r?\n/g, ''), 'base64') + } else { + var suite = 'aes' + match[1] + var iv = new Buffer(match[2], 'hex') + var cipherText = new Buffer(match[3].replace(/\r?\n/g, ''), 'base64') + var cipherKey = evp(password, iv.slice(0, 8), parseInt(match[1], 10)).key + var out = [] + var cipher = ciphers.createDecipheriv(suite, cipherKey, iv) + out.push(cipher.update(cipherText)) + out.push(cipher.final()) + decrypted = Buffer.concat(out) + } + var tag = key.match(startRegex)[1] + return { + tag: tag, + data: decrypted } } -/** - * This is the update queue used for server rendering. - * It delegates to ReactUpdateQueue while server rendering is in progress and - * switches to ReactNoopUpdateQueue after the transaction has completed. - * @class ReactServerUpdateQueue - * @param {Transaction} transaction - */ +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var ReactServerUpdateQueue = function () { - function ReactServerUpdateQueue(transaction) { - _classCallCheck(this, ReactServerUpdateQueue); +/***/ }), +/* 453 */ +/***/ (function(module, exports, __webpack_require__) { - this.transaction = transaction; - } +/* WEBPACK VAR INJECTION */(function(Buffer) {// much of this based on https://github.com/indutny/self-signed/blob/gh-pages/lib/rsa.js +var BN = __webpack_require__(11) +var EC = __webpack_require__(15).ec +var parseKeys = __webpack_require__(72) +var curves = __webpack_require__(195) + +function verify (sig, hash, key, signType, tag) { + var pub = parseKeys(key) + if (pub.type === 'ec') { + // rsa keys can be interpreted as ecdsa ones in openssl + if (signType !== 'ecdsa' && signType !== 'ecdsa/rsa') throw new Error('wrong public key type') + return ecVerify(sig, hash, pub) + } else if (pub.type === 'dsa') { + if (signType !== 'dsa') throw new Error('wrong public key type') + return dsaVerify(sig, hash, pub) + } else { + if (signType !== 'rsa' && signType !== 'ecdsa/rsa') throw new Error('wrong public key type') + } + hash = Buffer.concat([tag, hash]) + var len = pub.modulus.byteLength() + var pad = [ 1 ] + var padNum = 0 + while (hash.length + pad.length + 2 < len) { + pad.push(0xff) + padNum++ + } + pad.push(0x00) + var i = -1 + while (++i < hash.length) { + pad.push(hash[i]) + } + pad = new Buffer(pad) + var red = BN.mont(pub.modulus) + sig = new BN(sig).toRed(red) + + sig = sig.redPow(new BN(pub.publicExponent)) + sig = new Buffer(sig.fromRed().toArray()) + var out = padNum < 8 ? 1 : 0 + len = Math.min(sig.length, pad.length) + if (sig.length !== pad.length) out = 1 + + i = -1 + while (++i < len) out |= sig[i] ^ pad[i] + return out === 0 +} - /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ +function ecVerify (sig, hash, pub) { + var curveId = curves[pub.data.algorithm.curve.join('.')] + if (!curveId) throw new Error('unknown curve ' + pub.data.algorithm.curve.join('.')) + var curve = new EC(curveId) + var pubkey = pub.data.subjectPrivateKey.data - ReactServerUpdateQueue.prototype.isMounted = function isMounted(publicInstance) { - return false; - }; + return curve.verify(hash, sig, pubkey) +} - /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. - * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @internal - */ +function dsaVerify (sig, hash, pub) { + var p = pub.data.p + var q = pub.data.q + var g = pub.data.g + var y = pub.data.pub_key + var unpacked = parseKeys.signature.decode(sig, 'der') + var s = unpacked.s + var r = unpacked.r + checkValue(s, q) + checkValue(r, q) + var montp = BN.mont(p) + var w = s.invm(q) + var v = g.toRed(montp) + .redPow(new BN(hash).mul(w).mod(q)) + .fromRed() + .mul(y.toRed(montp).redPow(r.mul(w).mod(q)).fromRed()) + .mod(p) + .mod(q) + return v.cmp(r) === 0 +} +function checkValue (b, q) { + if (b.cmpn(0) <= 0) throw new Error('invalid sig') + if (b.cmp(q) >= q) throw new Error('invalid sig') +} - ReactServerUpdateQueue.prototype.enqueueCallback = function enqueueCallback(publicInstance, callback, callerName) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueCallback(publicInstance, callback, callerName); - } - }; +module.exports = verify - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal - */ +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) +/***/ }), +/* 454 */ +/***/ (function(module, exports, __webpack_require__) { - ReactServerUpdateQueue.prototype.enqueueForceUpdate = function enqueueForceUpdate(publicInstance) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueForceUpdate(publicInstance); - } else { - warnNoop(publicInstance, 'forceUpdate'); - } - }; +/* WEBPACK VAR INJECTION */(function(Buffer) {var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); - /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object|function} completeState Next state. - * @internal - */ +module.exports = function createECDH(curve) { + return new ECDH(curve); +}; +var aliases = { + secp256k1: { + name: 'secp256k1', + byteLength: 32 + }, + secp224r1: { + name: 'p224', + byteLength: 28 + }, + prime256v1: { + name: 'p256', + byteLength: 32 + }, + prime192v1: { + name: 'p192', + byteLength: 24 + }, + ed25519: { + name: 'ed25519', + byteLength: 32 + }, + secp384r1: { + name: 'p384', + byteLength: 48 + }, + secp521r1: { + name: 'p521', + byteLength: 66 + } +}; - ReactServerUpdateQueue.prototype.enqueueReplaceState = function enqueueReplaceState(publicInstance, completeState) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueReplaceState(publicInstance, completeState); - } else { - warnNoop(publicInstance, 'replaceState'); - } - }; +aliases.p224 = aliases.secp224r1; +aliases.p256 = aliases.secp256r1 = aliases.prime256v1; +aliases.p192 = aliases.secp192r1 = aliases.prime192v1; +aliases.p384 = aliases.secp384r1; +aliases.p521 = aliases.secp521r1; + +function ECDH(curve) { + this.curveType = aliases[curve]; + if (!this.curveType ) { + this.curveType = { + name: curve + }; + } + this.curve = new elliptic.ec(this.curveType.name); + this.keys = void 0; +} - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object|function} partialState Next partial state to be merged with state. - * @internal - */ +ECDH.prototype.generateKeys = function (enc, format) { + this.keys = this.curve.genKeyPair(); + return this.getPublicKey(enc, format); +}; +ECDH.prototype.computeSecret = function (other, inenc, enc) { + inenc = inenc || 'utf8'; + if (!Buffer.isBuffer(other)) { + other = new Buffer(other, inenc); + } + var otherPub = this.curve.keyFromPublic(other).getPublic(); + var out = otherPub.mul(this.keys.getPrivate()).getX(); + return formatReturnValue(out, enc, this.curveType.byteLength); +}; - ReactServerUpdateQueue.prototype.enqueueSetState = function enqueueSetState(publicInstance, partialState) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueSetState(publicInstance, partialState); - } else { - warnNoop(publicInstance, 'setState'); - } - }; +ECDH.prototype.getPublicKey = function (enc, format) { + var key = this.keys.getPublic(format === 'compressed', true); + if (format === 'hybrid') { + if (key[key.length - 1] % 2) { + key[0] = 7; + } else { + key [0] = 6; + } + } + return formatReturnValue(key, enc); +}; - return ReactServerUpdateQueue; -}(); +ECDH.prototype.getPrivateKey = function (enc) { + return formatReturnValue(this.keys.getPrivate(), enc); +}; -module.exports = ReactServerUpdateQueue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +ECDH.prototype.setPublicKey = function (pub, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(pub)) { + pub = new Buffer(pub, enc); + } + this.keys._importPublic(pub); + return this; +}; + +ECDH.prototype.setPrivateKey = function (priv, enc) { + enc = enc || 'utf8'; + if (!Buffer.isBuffer(priv)) { + priv = new Buffer(priv, enc); + } + var _priv = new BN(priv); + _priv = _priv.toString(16); + this.keys._importPrivate(_priv); + return this; +}; + +function formatReturnValue(bn, enc, len) { + if (!Array.isArray(bn)) { + bn = bn.toArray(); + } + var buf = new Buffer(bn); + if (len && buf.length < len) { + var zeros = new Buffer(len - buf.length); + zeros.fill(0); + buf = Buffer.concat([zeros, buf]); + } + if (!enc) { + return buf; + } else { + return buf.toString(enc); + } +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 185 */ +/* 455 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +exports.publicEncrypt = __webpack_require__(456); +exports.privateDecrypt = __webpack_require__(457); +exports.privateEncrypt = function privateEncrypt(key, buf) { + return exports.publicEncrypt(key, buf, true); +}; -var _assign = __webpack_require__(5); +exports.publicDecrypt = function publicDecrypt(key, buf) { + return exports.privateDecrypt(key, buf, true); +}; -var DOMLazyTree = __webpack_require__(27); -var ReactDOMComponentTree = __webpack_require__(6); +/***/ }), +/* 456 */ +/***/ (function(module, exports, __webpack_require__) { -var ReactDOMEmptyComponent = function (instantiate) { - // ReactCompositeComponent uses this: - this._currentElement = null; - // ReactDOMComponentTree uses these: - this._hostNode = null; - this._hostParent = null; - this._hostContainerInfo = null; - this._domID = 0; +/* WEBPACK VAR INJECTION */(function(Buffer) {var parseKeys = __webpack_require__(72); +var randomBytes = __webpack_require__(43); +var createHash = __webpack_require__(27); +var mgf = __webpack_require__(196); +var xor = __webpack_require__(197); +var bn = __webpack_require__(11); +var withPublic = __webpack_require__(198); +var crt = __webpack_require__(110); + +var constants = { + RSA_PKCS1_OAEP_PADDING: 4, + RSA_PKCS1_PADDIN: 1, + RSA_NO_PADDING: 3 }; -_assign(ReactDOMEmptyComponent.prototype, { - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - var domID = hostContainerInfo._idCounter++; - this._domID = domID; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; - var nodeValue = ' react-empty: ' + this._domID + ' '; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var node = ownerDocument.createComment(nodeValue); - ReactDOMComponentTree.precacheNode(this, node); - return DOMLazyTree(node); - } else { - if (transaction.renderToStaticMarkup) { - // Normally we'd insert a comment node, but since this is a situation - // where React won't take over (static pages), we can simply return - // nothing. - return ''; - } - return '<!--' + nodeValue + '-->'; +module.exports = function publicEncrypt(public_key, msg, reverse) { + var padding; + if (public_key.padding) { + padding = public_key.padding; + } else if (reverse) { + padding = 1; + } else { + padding = 4; + } + var key = parseKeys(public_key); + var paddedMsg; + if (padding === 4) { + paddedMsg = oaep(key, msg); + } else if (padding === 1) { + paddedMsg = pkcs1(key, msg, reverse); + } else if (padding === 3) { + paddedMsg = new bn(msg); + if (paddedMsg.cmp(key.modulus) >= 0) { + throw new Error('data too long for modulus'); } - }, - receiveComponent: function () {}, - getHostNode: function () { - return ReactDOMComponentTree.getNodeFromInstance(this); - }, - unmountComponent: function () { - ReactDOMComponentTree.uncacheNode(this); + } else { + throw new Error('unknown padding'); } -}); + if (reverse) { + return crt(paddedMsg, key); + } else { + return withPublic(paddedMsg, key); + } +}; -module.exports = ReactDOMEmptyComponent; +function oaep(key, msg){ + var k = key.modulus.byteLength(); + var mLen = msg.length; + var iHash = createHash('sha1').update(new Buffer('')).digest(); + var hLen = iHash.length; + var hLen2 = 2 * hLen; + if (mLen > k - hLen2 - 2) { + throw new Error('message too long'); + } + var ps = new Buffer(k - mLen - hLen2 - 2); + ps.fill(0); + var dblen = k - hLen - 1; + var seed = randomBytes(hLen); + var maskedDb = xor(Buffer.concat([iHash, ps, new Buffer([1]), msg], dblen), mgf(seed, dblen)); + var maskedSeed = xor(seed, mgf(maskedDb, hLen)); + return new bn(Buffer.concat([new Buffer([0]), maskedSeed, maskedDb], k)); +} +function pkcs1(key, msg, reverse){ + var mLen = msg.length; + var k = key.modulus.byteLength(); + if (mLen > k - 11) { + throw new Error('message too long'); + } + var ps; + if (reverse) { + ps = new Buffer(k - mLen - 3); + ps.fill(0xff); + } else { + ps = nonZero(k - mLen - 3); + } + return new bn(Buffer.concat([new Buffer([0, reverse?1:2]), ps, new Buffer([0]), msg], k)); +} +function nonZero(len, crypto) { + var out = new Buffer(len); + var i = 0; + var cache = randomBytes(len*2); + var cur = 0; + var num; + while (i < len) { + if (cur === cache.length) { + cache = randomBytes(len*2); + cur = 0; + } + num = cache[cur++]; + if (num) { + out[i++] = num; + } + } + return out; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 186 */ +/* 457 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) {var parseKeys = __webpack_require__(72); +var mgf = __webpack_require__(196); +var xor = __webpack_require__(197); +var bn = __webpack_require__(11); +var crt = __webpack_require__(110); +var createHash = __webpack_require__(27); +var withPublic = __webpack_require__(198); +module.exports = function privateDecrypt(private_key, enc, reverse) { + var padding; + if (private_key.padding) { + padding = private_key.padding; + } else if (reverse) { + padding = 1; + } else { + padding = 4; + } + + var key = parseKeys(private_key); + var k = key.modulus.byteLength(); + if (enc.length > k || new bn(enc).cmp(key.modulus) >= 0) { + throw new Error('decryption error'); + } + var msg; + if (reverse) { + msg = withPublic(new bn(enc), key); + } else { + msg = crt(enc, key); + } + var zBuffer = new Buffer(k - msg.length); + zBuffer.fill(0); + msg = Buffer.concat([zBuffer, msg], k); + if (padding === 4) { + return oaep(key, msg); + } else if (padding === 1) { + return pkcs1(key, msg, reverse); + } else if (padding === 3) { + return msg; + } else { + throw new Error('unknown padding'); + } +}; +function oaep(key, msg){ + var n = key.modulus; + var k = key.modulus.byteLength(); + var mLen = msg.length; + var iHash = createHash('sha1').update(new Buffer('')).digest(); + var hLen = iHash.length; + var hLen2 = 2 * hLen; + if (msg[0] !== 0) { + throw new Error('decryption error'); + } + var maskedSeed = msg.slice(1, hLen + 1); + var maskedDb = msg.slice(hLen + 1); + var seed = xor(maskedSeed, mgf(maskedDb, hLen)); + var db = xor(maskedDb, mgf(seed, k - hLen - 1)); + if (compare(iHash, db.slice(0, hLen))) { + throw new Error('decryption error'); + } + var i = hLen; + while (db[i] === 0) { + i++; + } + if (db[i++] !== 1) { + throw new Error('decryption error'); + } + return db.slice(i); +} +function pkcs1(key, msg, reverse){ + var p1 = msg.slice(0, 2); + var i = 2; + var status = 0; + while (msg[i++] !== 0) { + if (i >= msg.length) { + status++; + break; + } + } + var ps = msg.slice(2, i - 1); + var p2 = msg.slice(i - 1, i); -var _prodInvariant = __webpack_require__(3); + if ((p1.toString('hex') !== '0002' && !reverse) || (p1.toString('hex') !== '0001' && reverse)){ + status++; + } + if (ps.length < 8) { + status++; + } + if (status) { + throw new Error('decryption error'); + } + return msg.slice(i); +} +function compare(a, b){ + a = new Buffer(a); + b = new Buffer(b); + var dif = 0; + var len = a.length; + if (a.length !== b.length) { + dif++; + len = Math.min(a.length, b.length); + } + var i = -1; + while (++i < len) { + dif += (a[i] ^ b[i]); + } + return dif; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var invariant = __webpack_require__(1); +/***/ }), +/* 458 */ +/***/ (function(module, exports, __webpack_require__) { -/** - * Return the lowest common ancestor of A and B, or null if they are in - * different trees. +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33); +var secp256k1 = __webpack_require__(168); +var int64buffer = __webpack_require__(459); +var varuint = __webpack_require__(73); +var zconfig = __webpack_require__(66); +var zbufferutils = __webpack_require__(199); +var zcrypto = __webpack_require__(107); +var zconstants = __webpack_require__(460); +var zaddress = __webpack_require__(96); +var zopcodes = __webpack_require__(461); +var zbufferutils = __webpack_require__(199); + +/* More info: https://github.com/ZencashOfficial/zen/blob/master/src/script/standard.cpp#L377 + * Given an address, generates a pubkeyhash replay type script needed for the transaction + * @param {String} address + * @param {Number} blockHeight + * @param {Number} blockHash + * @param {String} pubKeyHash (optional) + * return {String} pubKeyScript */ -function getLowestCommonAncestor(instA, instB) { - !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; - !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; +function mkPubkeyHashReplayScript(address, blockHeight, blockHash, pubKeyHash) { + // Get lengh of pubKeyHash (so we know where to substr later on) + pubKeyHash = pubKeyHash || zconfig.mainnet.pubKeyHash; - var depthA = 0; - for (var tempA = instA; tempA; tempA = tempA._hostParent) { - depthA++; - } - var depthB = 0; - for (var tempB = instB; tempB; tempB = tempB._hostParent) { - depthB++; - } + var addrHex = bs58check.decode(address).toString('hex'); - // If A is deeper, crawl up. - while (depthA - depthB > 0) { - instA = instA._hostParent; - depthA--; - } + // Cut out pubKeyHash + var subAddrHex = addrHex.substring(pubKeyHash.length, addrHex.length); - // If B is deeper, crawl up. - while (depthB - depthA > 0) { - instB = instB._hostParent; - depthB--; + // Minimal encoding + var blockHeightBuffer = Buffer.alloc(4); + blockHeightBuffer.writeUInt32LE(blockHeight, 0); + if (blockHeightBuffer[3] === 0x00) { + blockHeightBuffer = blockHeightBuffer.slice(0, 3); } + var blockHeightHex = blockHeightBuffer.toString('hex'); - // Walk in lockstep until we find a match. - var depth = depthA; - while (depth--) { - if (instA === instB) { - return instA; - } - instA = instA._hostParent; - instB = instB._hostParent; - } - return null; + // block hash is encoded in little indian + var blockHashHex = Buffer.from(blockHash, 'hex').reverse().toString('hex'); + + // '14' is the length of the subAddrHex (in bytes) + return zopcodes.OP_DUP + zopcodes.OP_HASH160 + zbufferutils.getStringBufferLength(subAddrHex) + subAddrHex + zopcodes.OP_EQUALVERIFY + zopcodes.OP_CHECKSIG + zbufferutils.getStringBufferLength(blockHashHex) + blockHashHex + zbufferutils.getStringBufferLength(blockHeightHex) + blockHeightHex + zopcodes.OP_CHECKBLOCKATHEIGHT; } -/** - * Return if A is an ancestor of B. +/* + * Given an address, generates a script hash replay type script needed for the transaction + * @param {String} address + * @param {Number} blockHeight + * @param {Number} blockHash + * return {String} scriptHash script */ -function isAncestor(instA, instB) { - !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; - !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; +function mkScriptHashReplayScript(address, blockHeight, blockHash) { + var addrHex = bs58check.decode(address).toString('hex'); + var subAddrHex = addrHex.substring(4, addrHex.length); // Cut out the '00' (we also only want 14 bytes instead of 16) - while (instB) { - if (instB === instA) { - return true; - } - instB = instB._hostParent; + var blockHeightBuffer = Buffer.alloc(4); + blockHeightBuffer.writeUInt32LE(blockHeight, 0); + if (blockHeightBuffer[3] === 0x00) { + blockHeightBuffer = blockHeightBuffer.slice(0, 3); } - return false; + var blockHeightHex = blockHeightBuffer.toString('hex'); + + // Need to reverse it + var blockHashHex = Buffer.from(blockHash, 'hex').reverse().toString('hex'); + + // '14' is the length of the subAddrHex (in bytes) + return zopcodes.OP_HASH160 + zbufferutils.getStringBufferLength(subAddrHex) + subAddrHex + zopcodes.OP_EQUAL + zbufferutils.getStringBufferLength(blockHashHex) + blockHashHex + zbufferutils.getStringBufferLength(blockHeightHex) + blockHeightHex + zopcodes.OP_CHECKBLOCKATHEIGHT; } -/** - * Return the parent instance of the passed-in instance. +/* + * Given an address, generates an output script + * @param {String} address + * @param {Number} blockHeight + * @param {Number} blockHash + * return {String} output script */ -function getParentInstance(inst) { - !('_hostNode' in inst) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getParentInstance: Invalid argument.') : _prodInvariant('36') : void 0; +function addressToScript(address, blockHeight, blockHash) { + // P2SH replay starts with a 's', or 't' + if (address[1] === 's' || address[0] === 't') { + return mkScriptHashReplayScript(address, blockHeight, blockHash); + } - return inst._hostParent; + // P2PKH-replay is a replacement for P2PKH + // P2PKH-replay starts with a 0 + return mkPubkeyHashReplayScript(address, blockHeight, blockHash); } -/** - * Simulates the traversal of a two-phase, capture/bubble event dispatch. +/* + * Signature hashing for TXOBJ + * @param {String} address + * @param {Number} i, which transaction input to sign + * @param {String} hex string of script + * @param {String} hash code (SIGHASH_ALL, SIGHASH_NONE...) + * return {String} output script */ -function traverseTwoPhase(inst, fn, arg) { - var path = []; - while (inst) { - path.push(inst); - inst = inst._hostParent; - } - var i; - for (i = path.length; i-- > 0;) { - fn(path[i], 'captured', arg); +function signatureForm(txObj, i, script, hashcode) { + // Copy object so we don't rewrite it + var newTx = JSON.parse(JSON.stringify(txObj)); + + for (var j = 0; j < newTx.ins.length; j++) { + newTx.ins[j].script = ''; } - for (i = 0; i < path.length; i++) { - fn(path[i], 'bubbled', arg); + newTx.ins[i].script = script; + + if (hashcode === zconstants.SIGHASH_NONE) { + newTx.outs = []; + } else if (hashcode === zconstants.SIGHASH_SINGLE) { + newTx.outs = newTx.outs.slice(0, newTx.ins.length); + for (var j = 0; j < newTx.ins.length - 1; ++j) { + newTx.outs[j].satoshis = Math.pow(2, 64) - 1; + newTx.outs[j].script = ''; + } + } else if (hashcode === zconstants.SIGHASH_ANYONECANPAY) { + newTx.ins = [newTx.ins[i]]; } + + return newTx; } -/** - * Traverses the ID hierarchy and invokes the supplied `cb` on any IDs that - * should would receive a `mouseEnter` or `mouseLeave` event. - * - * Does not invoke the callback on the nearest common ancestor because nothing - * "entered" or "left" that element. +/* + * Deserializes a hex string into a TXOBJ + * @param {String} hex string + * @return {Object} txOBJ */ -function traverseEnterLeave(from, to, fn, argFrom, argTo) { - var common = from && to ? getLowestCommonAncestor(from, to) : null; - var pathFrom = []; - while (from && from !== common) { - pathFrom.push(from); - from = from._hostParent; - } - var pathTo = []; - while (to && to !== common) { - pathTo.push(to); - to = to._hostParent; - } - var i; - for (i = 0; i < pathFrom.length; i++) { - fn(pathFrom[i], 'bubbled', argFrom); +function deserializeTx(hexStr) { + const buf = Buffer.from(hexStr, 'hex'); + var offset = 0; + + // Out txobj + var txObj = { version: 0, locktime: 0, ins: [], outs: [] + + // Version + };txObj.version = buf.readUInt32LE(offset); + offset += 4; + + // Vins + var vinLen = varuint.decode(buf, offset); + offset += varuint.decode.bytes; + for (var i = 0; i < vinLen; i++) { + const hash = buf.slice(offset, offset + 32); + offset += 32; + + const vout = buf.readUInt32LE(offset); + offset += 4; + + const scriptLen = varuint.decode(buf, offset); + offset += varuint.decode.bytes; + + const script = buf.slice(offset, offset + scriptLen); + offset += scriptLen; + + const sequence = buf.slice(offset, offset + 4).toString('hex'); + offset += 4; + + txObj.ins.push({ + output: { hash: hash.reverse().toString('hex'), vout: vout }, + script: script.toString('hex'), + sequence: sequence, + prevScriptPubKey: '' + }); } - for (i = pathTo.length; i-- > 0;) { - fn(pathTo[i], 'captured', argTo); + + // Vouts + var voutLen = varuint.decode(buf, offset); + offset += varuint.decode.bytes; + for (var i = 0; i < voutLen; i++) { + const satoshis = zbufferutils.readUInt64LE(buf, offset); + offset += 8; + + const scriptLen = varuint.decode(buf, offset); + offset += varuint.decode.bytes; + + const script = buf.slice(offset, offset + scriptLen); + offset += scriptLen; + + txObj.outs.push({ + satoshis: satoshis, + script: script.toString('hex') + }); } + + // Locktime + txObj.locktime = buf.readInt32LE(offset); + offset += 4; + + return txObj; +} + +/* + * Serializes a TXOBJ into hex string + * @param {Object} txObj + * return {String} hex string of txObj + */ +function serializeTx(txObj) { + var serializedTx = ''; + var _buf16 = Buffer.alloc(4); + + // Version + _buf16.writeUInt16LE(txObj.version, 0); + serializedTx += _buf16.toString('hex'); + + // History + serializedTx += zbufferutils.numToVarInt(txObj.ins.length); + txObj.ins.map(function (i) { + // Txids and vouts + _buf16.writeUInt16LE(i.output.vout, 0); + serializedTx += Buffer.from(i.output.hash, 'hex').reverse().toString('hex'); + serializedTx += _buf16.toString('hex'); + + // Script + serializedTx += zbufferutils.getStringBufferLength(i.script); + serializedTx += i.script; + + // Sequence + serializedTx += i.sequence; + }); + + // Outputs + serializedTx += zbufferutils.numToVarInt(txObj.outs.length); + txObj.outs.map(function (o) { + // Write 64bit buffers + // JS only supports 56 bit + // https://github.com/bitcoinjs/bitcoinjs-lib/blob/master/src/bufferutils.js#L25 + var _buf32 = Buffer.alloc(8); + + _buf32.writeInt32LE(o.satoshis & -1, 0); + _buf32.writeUInt32LE(Math.floor(o.satoshis / 0x100000000), 4); + + serializedTx += _buf32.toString('hex'); + serializedTx += zbufferutils.getStringBufferLength(o.script); + serializedTx += o.script; + }); + + // Locktime + _buf16.writeUInt16LE(txObj.locktime, 0); + serializedTx += _buf16.toString('hex'); + + return serializedTx; +} + +/* + * Creates a raw transaction + * @param {[HISTORY]} history type, array of transaction history + * @param {[RECIPIENTS]} recipient type, array of address on where to send coins to + * @param {Number} blockHeight (latest - 300) + * @param {String} blockHash of blockHeight + * @return {TXOBJ} Transction Object (see TXOBJ type for info about structure) + */ +function createRawTx(history, recipients, blockHeight, blockHash) { + var txObj = { locktime: 0, version: 1, ins: [], outs: [] }; + + txObj.ins = history.map(function (h) { + return { + output: { hash: h.txid, vout: h.vout }, + script: '', + prevScriptPubKey: h.scriptPubKey, + sequence: 'ffffffff' + }; + }); + txObj.outs = recipients.map(function (o) { + return { + script: addressToScript(o.address, blockHeight, blockHash), + satoshis: o.satoshis + }; + }); + + return txObj; +} + +/* + * Signs the raw transaction + * @param {String} rawTx raw transaction + * @param {Int} i + * @param {privKey} privKey (not WIF format) + * @param {compressPubKey} compress public key before appending to scriptSig? (default false) + * @param {hashcode} hashcode (default SIGHASH_ALL) + * return {String} signed transaction + */ +function signTx(_txObj, i, privKey, compressPubKey, hashcode) { + hashcode = hashcode || zconstants.SIGHASH_ALL; + compressPubKey = compressPubKey || false; + + // Make a copy + var txObj = JSON.parse(JSON.stringify(_txObj)); + + // Buffer + var _buf16 = Buffer.alloc(4); + _buf16.writeUInt16LE(hashcode, 0); + + // Prepare signing + const script = txObj.ins[i].prevScriptPubKey; + + // Prepare our signature + const signingTx = signatureForm(txObj, i, script, hashcode); + const signingTxHex = serializeTx(signingTx); + const signingTxWithHashcode = signingTxHex + _buf16.toString('hex'); + + // Sha256 it twice, according to spec + const msg = zcrypto.sha256x2(Buffer.from(signingTxWithHashcode, 'hex')); + + // Signing it + const rawsig = secp256k1.sign(Buffer.from(msg, 'hex'), Buffer.from(privKey, 'hex')).signature; + + // Convert it to DER format + // Appending 01 to it cause + // ScriptSig = <varint of total sig length> <SIG from code, including appended 01 SIGNHASH> <length of pubkey (0x21 or 0x41)> <pubkey> + // https://bitcoin.stackexchange.com/a/36481 + const signatureDER = secp256k1.signatureExport(rawsig).toString('hex') + '01'; + + // Chuck it back into txObj and add pubkey + // WHAT? If it fails, uncompress/compress it and it should work... + const pubKey = zaddress.privKeyToPubKey(privKey, compressPubKey); + + txObj.ins[i].script = zbufferutils.getStringBufferLength(signatureDER) + signatureDER + zbufferutils.getStringBufferLength(pubKey) + pubKey; + + return txObj; } module.exports = { - isAncestor: isAncestor, - getLowestCommonAncestor: getLowestCommonAncestor, - getParentInstance: getParentInstance, - traverseTwoPhase: traverseTwoPhase, - traverseEnterLeave: traverseEnterLeave + addressToScript: addressToScript, + createRawTx: createRawTx, + mkPubkeyHashReplayScript: mkPubkeyHashReplayScript, + mkScriptHashReplayScript: mkScriptHashReplayScript, + signatureForm: signatureForm, + serializeTx: serializeTx, + deserializeTx: deserializeTx, + signTx: signTx }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 187 */ +/* 459 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) {// int64-buffer.js +/*jshint -W018 */ // Confusing use of '!'. +/*jshint -W030 */ // Expected an assignment or function call and instead saw an expression. +/*jshint -W093 */ // Did you mean to return a conditional instead of an assignment? +var Uint64BE, Int64BE, Uint64LE, Int64LE; -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +!function(exports) { + // constants -var DOMChildrenOperations = __webpack_require__(55); -var DOMLazyTree = __webpack_require__(27); -var ReactDOMComponentTree = __webpack_require__(6); + var UNDEFINED = "undefined"; + var BUFFER = (UNDEFINED !== typeof Buffer) && Buffer; + var UINT8ARRAY = (UNDEFINED !== typeof Uint8Array) && Uint8Array; + var ARRAYBUFFER = (UNDEFINED !== typeof ArrayBuffer) && ArrayBuffer; + var ZERO = [0, 0, 0, 0, 0, 0, 0, 0]; + var isArray = Array.isArray || _isArray; + var BIT32 = 4294967296; + var BIT24 = 16777216; -var escapeTextContentForBrowser = __webpack_require__(44); -var invariant = __webpack_require__(1); -var validateDOMNesting = __webpack_require__(64); + // storage class -/** - * Text nodes violate a couple assumptions that React makes about components: - * - * - When mounting text into the DOM, adjacent text nodes are merged. - * - Text nodes cannot be assigned a React root ID. - * - * This component is used to wrap strings between comment nodes so that they - * can undergo the same reconciliation that is applied to elements. - * - * TODO: Investigate representing React components in the DOM with text nodes. - * - * @class ReactDOMTextComponent - * @extends ReactComponent - * @internal - */ -var ReactDOMTextComponent = function (text) { - // TODO: This is really a ReactText (ReactNode), not a ReactElement - this._currentElement = text; - this._stringText = '' + text; - // ReactDOMComponentTree uses these: - this._hostNode = null; - this._hostParent = null; + var storage; // Array; - // Properties - this._domID = 0; - this._mountIndex = 0; - this._closingComment = null; - this._commentNodes = null; -}; + // generate classes -_assign(ReactDOMTextComponent.prototype, { - /** - * Creates the markup for this text node. This node is not intended to have - * any features besides containing text content. - * - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @return {string} Markup for this text node. - * @internal - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - if (process.env.NODE_ENV !== 'production') { - var parentInfo; - if (hostParent != null) { - parentInfo = hostParent._ancestorInfo; - } else if (hostContainerInfo != null) { - parentInfo = hostContainerInfo._ancestorInfo; - } - if (parentInfo) { - // parentInfo should always be present except for the top-level - // component when server rendering - validateDOMNesting(null, this._stringText, this, parentInfo); - } + Uint64BE = factory("Uint64BE", true, true); + Int64BE = factory("Int64BE", true, false); + Uint64LE = factory("Uint64LE", false, true); + Int64LE = factory("Int64LE", false, false); + + // class factory + + function factory(name, bigendian, unsigned) { + var posH = bigendian ? 0 : 4; + var posL = bigendian ? 4 : 0; + var pos0 = bigendian ? 0 : 3; + var pos1 = bigendian ? 1 : 2; + var pos2 = bigendian ? 2 : 1; + var pos3 = bigendian ? 3 : 0; + var fromPositive = bigendian ? fromPositiveBE : fromPositiveLE; + var fromNegative = bigendian ? fromNegativeBE : fromNegativeLE; + var proto = Int64.prototype; + var isName = "is" + name; + var _isInt64 = "_" + isName; + + // properties + proto.buffer = void 0; + proto.offset = 0; + proto[_isInt64] = true; + + // methods + proto.toNumber = toNumber; + proto.toString = toString; + proto.toJSON = toNumber; + proto.toArray = toArray; + + // add .toBuffer() method only when Buffer available + if (BUFFER) proto.toBuffer = toBuffer; + + // add .toArrayBuffer() method only when Uint8Array available + if (UINT8ARRAY) proto.toArrayBuffer = toArrayBuffer; + + // isUint64BE, isInt64BE + Int64[isName] = isInt64; + + // CommonJS + exports[name] = Int64; + + return Int64; + + // constructor + function Int64(buffer, offset, value, raddix) { + if (!(this instanceof Int64)) return new Int64(buffer, offset, value, raddix); + return init(this, buffer, offset, value, raddix); } - var domID = hostContainerInfo._idCounter++; - var openingValue = ' react-text: ' + domID + ' '; - var closingValue = ' /react-text '; - this._domID = domID; - this._hostParent = hostParent; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var openingComment = ownerDocument.createComment(openingValue); - var closingComment = ownerDocument.createComment(closingValue); - var lazyTree = DOMLazyTree(ownerDocument.createDocumentFragment()); - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(openingComment)); - if (this._stringText) { - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(ownerDocument.createTextNode(this._stringText))); + // isUint64BE, isInt64BE + function isInt64(b) { + return !!(b && b[_isInt64]); + } + + // initializer + function init(that, buffer, offset, value, raddix) { + if (UINT8ARRAY && ARRAYBUFFER) { + if (buffer instanceof ARRAYBUFFER) buffer = new UINT8ARRAY(buffer); + if (value instanceof ARRAYBUFFER) value = new UINT8ARRAY(value); } - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(closingComment)); - ReactDOMComponentTree.precacheNode(this, openingComment); - this._closingComment = closingComment; - return lazyTree; - } else { - var escapedText = escapeTextContentForBrowser(this._stringText); - if (transaction.renderToStaticMarkup) { - // Normally we'd wrap this between comment nodes for the reasons stated - // above, but since this is a situation where React won't take over - // (static pages), we can simply return the text as it is. - return escapedText; + // Int64BE() style + if (!buffer && !offset && !value && !storage) { + // shortcut to initialize with zero + that.buffer = newArray(ZERO, 0); + return; } - return '<!--' + openingValue + '-->' + escapedText + '<!--' + closingValue + '-->'; - } - }, + // Int64BE(value, raddix) style + if (!isValidBuffer(buffer, offset)) { + var _storage = storage || Array; + raddix = offset; + value = buffer; + offset = 0; + buffer = new _storage(8); + } - /** - * Updates this component by updating the text content. - * - * @param {ReactText} nextText The next text content - * @param {ReactReconcileTransaction} transaction - * @internal - */ - receiveComponent: function (nextText, transaction) { - if (nextText !== this._currentElement) { - this._currentElement = nextText; - var nextStringText = '' + nextText; - if (nextStringText !== this._stringText) { - // TODO: Save this as pending props and use performUpdateIfNecessary - // and/or updateComponent to do the actual update for consistency with - // other component types? - this._stringText = nextStringText; - var commentNodes = this.getHostNode(); - DOMChildrenOperations.replaceDelimitedText(commentNodes[0], commentNodes[1], nextStringText); + that.buffer = buffer; + that.offset = offset |= 0; + + // Int64BE(buffer, offset) style + if (UNDEFINED === typeof value) return; + + // Int64BE(buffer, offset, value, raddix) style + if ("string" === typeof value) { + fromString(buffer, offset, value, raddix || 10); + } else if (isValidBuffer(value, raddix)) { + fromArray(buffer, offset, value, raddix); + } else if ("number" === typeof raddix) { + writeInt32(buffer, offset + posH, value); // high + writeInt32(buffer, offset + posL, raddix); // low + } else if (value > 0) { + fromPositive(buffer, offset, value); // positive + } else if (value < 0) { + fromNegative(buffer, offset, value); // negative + } else { + fromArray(buffer, offset, ZERO, 0); // zero, NaN and others } } - }, - getHostNode: function () { - var hostNode = this._commentNodes; - if (hostNode) { - return hostNode; - } - if (!this._closingComment) { - var openingComment = ReactDOMComponentTree.getNodeFromInstance(this); - var node = openingComment.nextSibling; - while (true) { - !(node != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Missing closing comment for text component %s', this._domID) : _prodInvariant('67', this._domID) : void 0; - if (node.nodeType === 8 && node.nodeValue === ' /react-text ') { - this._closingComment = node; - break; + function fromString(buffer, offset, str, raddix) { + var pos = 0; + var len = str.length; + var high = 0; + var low = 0; + if (str[0] === "-") pos++; + var sign = pos; + while (pos < len) { + var chr = parseInt(str[pos++], raddix); + if (!(chr >= 0)) break; // NaN + low = low * raddix + chr; + high = high * raddix + Math.floor(low / BIT32); + low %= BIT32; + } + if (sign) { + high = ~high; + if (low) { + low = BIT32 - low; + } else { + high++; } - node = node.nextSibling; } + writeInt32(buffer, offset + posH, high); + writeInt32(buffer, offset + posL, low); + } + + function toNumber() { + var buffer = this.buffer; + var offset = this.offset; + var high = readInt32(buffer, offset + posH); + var low = readInt32(buffer, offset + posL); + if (!unsigned) high |= 0; // a trick to get signed + return high ? (high * BIT32 + low) : low; + } + + function toString(radix) { + var buffer = this.buffer; + var offset = this.offset; + var high = readInt32(buffer, offset + posH); + var low = readInt32(buffer, offset + posL); + var str = ""; + var sign = !unsigned && (high & 0x80000000); + if (sign) { + high = ~high; + low = BIT32 - low; + } + radix = radix || 10; + while (1) { + var mod = (high % radix) * BIT32 + low; + high = Math.floor(high / radix); + low = Math.floor(mod / radix); + str = (mod % radix).toString(radix) + str; + if (!high && !low) break; + } + if (sign) { + str = "-" + str; + } + return str; } - hostNode = [this._hostNode, this._closingComment]; - this._commentNodes = hostNode; - return hostNode; - }, - - unmountComponent: function () { - this._closingComment = null; - this._commentNodes = null; - ReactDOMComponentTree.uncacheNode(this); - } -}); -module.exports = ReactDOMTextComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + function writeInt32(buffer, offset, value) { + buffer[offset + pos3] = value & 255; + value = value >> 8; + buffer[offset + pos2] = value & 255; + value = value >> 8; + buffer[offset + pos1] = value & 255; + value = value >> 8; + buffer[offset + pos0] = value & 255; + } -/***/ }), -/* 188 */ -/***/ (function(module, exports, __webpack_require__) { + function readInt32(buffer, offset) { + return (buffer[offset + pos0] * BIT24) + + (buffer[offset + pos1] << 16) + + (buffer[offset + pos2] << 8) + + buffer[offset + pos3]; + } + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + function toArray(raw) { + var buffer = this.buffer; + var offset = this.offset; + storage = null; // Array + if (raw !== false && offset === 0 && buffer.length === 8 && isArray(buffer)) return buffer; + return newArray(buffer, offset); + } + function toBuffer(raw) { + var buffer = this.buffer; + var offset = this.offset; + storage = BUFFER; + if (raw !== false && offset === 0 && buffer.length === 8 && Buffer.isBuffer(buffer)) return buffer; + var dest = new BUFFER(8); + fromArray(dest, 0, buffer, offset); + return dest; + } + function toArrayBuffer(raw) { + var buffer = this.buffer; + var offset = this.offset; + var arrbuf = buffer.buffer; + storage = UINT8ARRAY; + if (raw !== false && offset === 0 && (arrbuf instanceof ARRAYBUFFER) && arrbuf.byteLength === 8) return arrbuf; + var dest = new UINT8ARRAY(8); + fromArray(dest, 0, buffer, offset); + return dest.buffer; + } -var _assign = __webpack_require__(5); + function isValidBuffer(buffer, offset) { + var len = buffer && buffer.length; + offset |= 0; + return len && (offset + 8 <= len) && ("string" !== typeof buffer[offset]); + } -var ReactUpdates = __webpack_require__(15); -var Transaction = __webpack_require__(41); + function fromArray(destbuf, destoff, srcbuf, srcoff) { + destoff |= 0; + srcoff |= 0; + for (var i = 0; i < 8; i++) { + destbuf[destoff++] = srcbuf[srcoff++] & 255; + } + } -var emptyFunction = __webpack_require__(12); + function newArray(buffer, offset) { + return Array.prototype.slice.call(buffer, offset, offset + 8); + } -var RESET_BATCHED_UPDATES = { - initialize: emptyFunction, - close: function () { - ReactDefaultBatchingStrategy.isBatchingUpdates = false; + function fromPositiveBE(buffer, offset, value) { + var pos = offset + 8; + while (pos > offset) { + buffer[--pos] = value & 255; + value /= 256; + } } -}; -var FLUSH_BATCHED_UPDATES = { - initialize: emptyFunction, - close: ReactUpdates.flushBatchedUpdates.bind(ReactUpdates) -}; + function fromNegativeBE(buffer, offset, value) { + var pos = offset + 8; + value++; + while (pos > offset) { + buffer[--pos] = ((-value) & 255) ^ 255; + value /= 256; + } + } -var TRANSACTION_WRAPPERS = [FLUSH_BATCHED_UPDATES, RESET_BATCHED_UPDATES]; + function fromPositiveLE(buffer, offset, value) { + var end = offset + 8; + while (offset < end) { + buffer[offset++] = value & 255; + value /= 256; + } + } -function ReactDefaultBatchingStrategyTransaction() { - this.reinitializeTransaction(); -} + function fromNegativeLE(buffer, offset, value) { + var end = offset + 8; + value++; + while (offset < end) { + buffer[offset++] = ((-value) & 255) ^ 255; + value /= 256; + } + } -_assign(ReactDefaultBatchingStrategyTransaction.prototype, Transaction, { - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; + // https://github.com/retrofox/is-array + function _isArray(val) { + return !!val && "[object Array]" == Object.prototype.toString.call(val); } -}); -var transaction = new ReactDefaultBatchingStrategyTransaction(); +}(typeof exports === 'object' && typeof exports.nodeName !== 'string' ? exports : (this || {})); -var ReactDefaultBatchingStrategy = { - isBatchingUpdates: false, +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - /** - * Call the provided function in a context within which calls to `setState` - * and friends are batched such that components aren't updated unnecessarily. +/***/ }), +/* 460 */ +/***/ (function(module, exports) { + +module.exports = { + /* SIGHASH Codes + * Obtained from: https://github.com/ZencashOfficial/zen/blob/master/src/script/interpreter.h */ - batchedUpdates: function (callback, a, b, c, d, e) { - var alreadyBatchingUpdates = ReactDefaultBatchingStrategy.isBatchingUpdates; + SIGHASH_ALL: 1, + SIGHASH_NONE: 2, + SIGHASH_SINGLE: 3, + SIGHASH_ANYONECANPAY: 0x80 +}; - ReactDefaultBatchingStrategy.isBatchingUpdates = true; +/***/ }), +/* 461 */ +/***/ (function(module, exports) { - // The code is written this way to avoid extra allocations - if (alreadyBatchingUpdates) { - return callback(a, b, c, d, e); - } else { - return transaction.perform(callback, null, a, b, c, d, e); - } - } -}; -module.exports = ReactDefaultBatchingStrategy; +/* Useful OP codes for the scripting language + * Obtained from: https://github.com/ZencashOfficial/zen/blob/master/src/script/script.h + */ + +module.exports = { + OP_DUP: '76', + OP_HASH160: 'a9', + OP_EQUALVERIFY: '88', + OP_CHECKSIG: 'ac', + OP_CHECKBLOCKATHEIGHT: 'b4', + OP_EQUAL: '87', + OP_REVERSED: '89' +}; /***/ }), -/* 189 */ +/* 462 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var _bluebird = __webpack_require__(463); -var _assign = __webpack_require__(5); +var _bluebird2 = _interopRequireDefault(_bluebird); -var EventListener = __webpack_require__(101); -var ExecutionEnvironment = __webpack_require__(8); -var PooledClass = __webpack_require__(20); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); - -var getEventTarget = __webpack_require__(52); -var getUnboundedScrollPosition = __webpack_require__(190); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -/** - * Find the deepest React component completely containing the root of the - * passed-in instance (for use when entire React trees are nested within each - * other). If React trees are not nested, returns null. - */ -function findParent(inst) { - // TODO: It may be a good idea to cache this to prevent unnecessary DOM - // traversal, but caching is difficult to do correctly without using a - // mutation observer to listen for all DOM changes. - while (inst._hostParent) { - inst = inst._hostParent; +// Append url +function urlAppend(url, param) { + if (url.substr(-1) !== '/') { + url = url + '/'; } - var rootNode = ReactDOMComponentTree.getNodeFromInstance(inst); - var container = rootNode.parentNode; - return ReactDOMComponentTree.getClosestInstanceFromNode(container); + + return url + param; } -// Used to store ancestor hierarchy in top level callback -function TopLevelCallbackBookKeeping(topLevelType, nativeEvent) { - this.topLevelType = topLevelType; - this.nativeEvent = nativeEvent; - this.ancestors = []; +// Debounce promise +function promiseDebounce(fn, delay, count) { + var working = 0, + queue = []; + function work() { + if (queue.length === 0 || working === count) return; + working++; + _bluebird2.default.delay(delay).tap(function () { + working--; + }).then(work); + var next = queue.shift(); + next[2](fn.apply(next[0], next[1])); + } + return function debounced() { + var args = arguments; + return new _bluebird2.default(function (resolve) { + queue.push([this, args, resolve]); + if (working < count) work(); + }.bind(this)); + }; } -_assign(TopLevelCallbackBookKeeping.prototype, { - destructor: function () { - this.topLevelType = null; - this.nativeEvent = null; - this.ancestors.length = 0; - } -}); -PooledClass.addPoolingTo(TopLevelCallbackBookKeeping, PooledClass.twoArgumentPooler); -function handleTopLevelImpl(bookKeeping) { - var nativeEventTarget = getEventTarget(bookKeeping.nativeEvent); - var targetInst = ReactDOMComponentTree.getClosestInstanceFromNode(nativeEventTarget); +module.exports = { + promiseDebounce: promiseDebounce, + urlAppend: urlAppend +}; - // Loop through the hierarchy, in case there's any nested components. - // It's important that we build the array of ancestors before calling any - // event handlers, because event handlers can modify the DOM, leading to - // inconsistencies with ReactMount's node cache. See #1105. - var ancestor = targetInst; - do { - bookKeeping.ancestors.push(ancestor); - ancestor = ancestor && findParent(ancestor); - } while (ancestor); +/***/ }), +/* 463 */ +/***/ (function(module, exports, __webpack_require__) { - for (var i = 0; i < bookKeeping.ancestors.length; i++) { - targetInst = bookKeeping.ancestors[i]; - ReactEventListener._handleTopLevel(bookKeeping.topLevelType, targetInst, bookKeeping.nativeEvent, getEventTarget(bookKeeping.nativeEvent)); - } +/* WEBPACK VAR INJECTION */(function(process, global, setImmediate) {/* @preserve + * The MIT License (MIT) + * + * Copyright (c) 2013-2017 Petka Antonov + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + * + */ +/** + * bluebird build version 3.5.0 + * Features enabled: core, race, call_get, generators, map, nodeify, promisify, props, reduce, settle, some, using, timers, filter, any, each +*/ +!function(e){if(true)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.Promise=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof _dereq_=="function"&&_dereq_;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof _dereq_=="function"&&_dereq_;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +var SomePromiseArray = Promise._SomePromiseArray; +function any(promises) { + var ret = new SomePromiseArray(promises); + var promise = ret.promise(); + ret.setHowMany(1); + ret.setUnwrap(); + ret.init(); + return promise; } -function scrollValueMonitor(cb) { - var scrollPosition = getUnboundedScrollPosition(window); - cb(scrollPosition); +Promise.any = function (promises) { + return any(promises); +}; + +Promise.prototype.any = function () { + return any(this); +}; + +}; + +},{}],2:[function(_dereq_,module,exports){ +"use strict"; +var firstLineError; +try {throw new Error(); } catch (e) {firstLineError = e;} +var schedule = _dereq_("./schedule"); +var Queue = _dereq_("./queue"); +var util = _dereq_("./util"); + +function Async() { + this._customScheduler = false; + this._isTickUsed = false; + this._lateQueue = new Queue(16); + this._normalQueue = new Queue(16); + this._haveDrainedQueues = false; + this._trampolineEnabled = true; + var self = this; + this.drainQueues = function () { + self._drainQueues(); + }; + this._schedule = schedule; } -var ReactEventListener = { - _enabled: true, - _handleTopLevel: null, +Async.prototype.setScheduler = function(fn) { + var prev = this._schedule; + this._schedule = fn; + this._customScheduler = true; + return prev; +}; - WINDOW_HANDLE: ExecutionEnvironment.canUseDOM ? window : null, +Async.prototype.hasCustomScheduler = function() { + return this._customScheduler; +}; - setHandleTopLevel: function (handleTopLevel) { - ReactEventListener._handleTopLevel = handleTopLevel; - }, +Async.prototype.enableTrampoline = function() { + this._trampolineEnabled = true; +}; - setEnabled: function (enabled) { - ReactEventListener._enabled = !!enabled; - }, +Async.prototype.disableTrampolineIfNecessary = function() { + if (util.hasDevTools) { + this._trampolineEnabled = false; + } +}; - isEnabled: function () { - return ReactEventListener._enabled; - }, +Async.prototype.haveItemsQueued = function () { + return this._isTickUsed || this._haveDrainedQueues; +}; - /** - * Traps top-level events by using event bubbling. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {string} handlerBaseName Event name (e.g. "click"). - * @param {object} element Element on which to attach listener. - * @return {?object} An object with a remove function which will forcefully - * remove the listener. - * @internal - */ - trapBubbledEvent: function (topLevelType, handlerBaseName, element) { - if (!element) { - return null; + +Async.prototype.fatalError = function(e, isNode) { + if (isNode) { + process.stderr.write("Fatal " + (e instanceof Error ? e.stack : e) + + "\n"); + process.exit(2); + } else { + this.throwLater(e); } - return EventListener.listen(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); - }, +}; - /** - * Traps a top-level event by using event capturing. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {string} handlerBaseName Event name (e.g. "click"). - * @param {object} element Element on which to attach listener. - * @return {?object} An object with a remove function which will forcefully - * remove the listener. - * @internal - */ - trapCapturedEvent: function (topLevelType, handlerBaseName, element) { - if (!element) { - return null; +Async.prototype.throwLater = function(fn, arg) { + if (arguments.length === 1) { + arg = fn; + fn = function () { throw arg; }; + } + if (typeof setTimeout !== "undefined") { + setTimeout(function() { + fn(arg); + }, 0); + } else try { + this._schedule(function() { + fn(arg); + }); + } catch (e) { + throw new Error("No async scheduler available\u000a\u000a See http://goo.gl/MqrFmX\u000a"); } - return EventListener.capture(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); - }, +}; - monitorScrollValue: function (refresh) { - var callback = scrollValueMonitor.bind(null, refresh); - EventListener.listen(window, 'scroll', callback); - }, +function AsyncInvokeLater(fn, receiver, arg) { + this._lateQueue.push(fn, receiver, arg); + this._queueTick(); +} - dispatchEvent: function (topLevelType, nativeEvent) { - if (!ReactEventListener._enabled) { - return; +function AsyncInvoke(fn, receiver, arg) { + this._normalQueue.push(fn, receiver, arg); + this._queueTick(); +} + +function AsyncSettlePromises(promise) { + this._normalQueue._pushOne(promise); + this._queueTick(); +} + +if (!util.hasDevTools) { + Async.prototype.invokeLater = AsyncInvokeLater; + Async.prototype.invoke = AsyncInvoke; + Async.prototype.settlePromises = AsyncSettlePromises; +} else { + Async.prototype.invokeLater = function (fn, receiver, arg) { + if (this._trampolineEnabled) { + AsyncInvokeLater.call(this, fn, receiver, arg); + } else { + this._schedule(function() { + setTimeout(function() { + fn.call(receiver, arg); + }, 100); + }); + } + }; + + Async.prototype.invoke = function (fn, receiver, arg) { + if (this._trampolineEnabled) { + AsyncInvoke.call(this, fn, receiver, arg); + } else { + this._schedule(function() { + fn.call(receiver, arg); + }); + } + }; + + Async.prototype.settlePromises = function(promise) { + if (this._trampolineEnabled) { + AsyncSettlePromises.call(this, promise); + } else { + this._schedule(function() { + promise._settlePromises(); + }); + } + }; +} + +Async.prototype._drainQueue = function(queue) { + while (queue.length() > 0) { + var fn = queue.shift(); + if (typeof fn !== "function") { + fn._settlePromises(); + continue; + } + var receiver = queue.shift(); + var arg = queue.shift(); + fn.call(receiver, arg); } +}; - var bookKeeping = TopLevelCallbackBookKeeping.getPooled(topLevelType, nativeEvent); - try { - // Event queue being processed in the same cycle allows - // `preventDefault`. - ReactUpdates.batchedUpdates(handleTopLevelImpl, bookKeeping); - } finally { - TopLevelCallbackBookKeeping.release(bookKeeping); +Async.prototype._drainQueues = function () { + this._drainQueue(this._normalQueue); + this._reset(); + this._haveDrainedQueues = true; + this._drainQueue(this._lateQueue); +}; + +Async.prototype._queueTick = function () { + if (!this._isTickUsed) { + this._isTickUsed = true; + this._schedule(this.drainQueues); } - } }; -module.exports = ReactEventListener; +Async.prototype._reset = function () { + this._isTickUsed = false; +}; -/***/ }), -/* 190 */ -/***/ (function(module, exports, __webpack_require__) { +module.exports = Async; +module.exports.firstLineError = firstLineError; +},{"./queue":26,"./schedule":29,"./util":36}],3:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +module.exports = function(Promise, INTERNAL, tryConvertToPromise, debug) { +var calledBind = false; +var rejectThis = function(_, e) { + this._reject(e); +}; +var targetRejected = function(e, context) { + context.promiseRejectionQueued = true; + context.bindingPromise._then(rejectThis, rejectThis, null, this, e); +}; +var bindingResolved = function(thisArg, context) { + if (((this._bitField & 50397184) === 0)) { + this._resolveCallback(context.target); + } +}; -/** - * Gets the scroll position of the supplied element or window. - * - * The return values are unbounded, unlike `getScrollPosition`. This means they - * may be negative or exceed the element boundaries (which is possible using - * inertial scrolling). - * - * @param {DOMWindow|DOMElement} scrollable - * @return {object} Map with `x` and `y` keys. - */ +var bindingRejected = function(e, context) { + if (!context.promiseRejectionQueued) this._reject(e); +}; -function getUnboundedScrollPosition(scrollable) { - if (scrollable.Window && scrollable instanceof scrollable.Window) { - return { - x: scrollable.pageXOffset || scrollable.document.documentElement.scrollLeft, - y: scrollable.pageYOffset || scrollable.document.documentElement.scrollTop - }; - } - return { - x: scrollable.scrollLeft, - y: scrollable.scrollTop - }; -} +Promise.prototype.bind = function (thisArg) { + if (!calledBind) { + calledBind = true; + Promise.prototype._propagateFrom = debug.propagateFromFunction(); + Promise.prototype._boundValue = debug.boundValueFunction(); + } + var maybePromise = tryConvertToPromise(thisArg); + var ret = new Promise(INTERNAL); + ret._propagateFrom(this, 1); + var target = this._target(); + ret._setBoundTo(maybePromise); + if (maybePromise instanceof Promise) { + var context = { + promiseRejectionQueued: false, + promise: ret, + target: target, + bindingPromise: maybePromise + }; + target._then(INTERNAL, targetRejected, undefined, ret, context); + maybePromise._then( + bindingResolved, bindingRejected, undefined, ret, context); + ret._setOnCancel(maybePromise); + } else { + ret._resolveCallback(target); + } + return ret; +}; -module.exports = getUnboundedScrollPosition; +Promise.prototype._setBoundTo = function (obj) { + if (obj !== undefined) { + this._bitField = this._bitField | 2097152; + this._boundTo = obj; + } else { + this._bitField = this._bitField & (~2097152); + } +}; -/***/ }), -/* 191 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._isBound = function () { + return (this._bitField & 2097152) === 2097152; +}; + +Promise.bind = function (thisArg, value) { + return Promise.resolve(value).bind(thisArg); +}; +}; +},{}],4:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var old; +if (typeof Promise !== "undefined") old = Promise; +function noConflict() { + try { if (Promise === bluebird) Promise = old; } + catch (e) {} + return bluebird; +} +var bluebird = _dereq_("./promise")(); +bluebird.noConflict = noConflict; +module.exports = bluebird; + +},{"./promise":22}],5:[function(_dereq_,module,exports){ +"use strict"; +var cr = Object.create; +if (cr) { + var callerCache = cr(null); + var getterCache = cr(null); + callerCache[" size"] = getterCache[" size"] = 0; +} + +module.exports = function(Promise) { +var util = _dereq_("./util"); +var canEvaluate = util.canEvaluate; +var isIdentifier = util.isIdentifier; + +var getMethodCaller; +var getGetter; +if (false) { +var makeMethodCaller = function (methodName) { + return new Function("ensureMethod", " \n\ + return function(obj) { \n\ + 'use strict' \n\ + var len = this.length; \n\ + ensureMethod(obj, 'methodName'); \n\ + switch(len) { \n\ + case 1: return obj.methodName(this[0]); \n\ + case 2: return obj.methodName(this[0], this[1]); \n\ + case 3: return obj.methodName(this[0], this[1], this[2]); \n\ + case 0: return obj.methodName(); \n\ + default: \n\ + return obj.methodName.apply(obj, this); \n\ + } \n\ + }; \n\ + ".replace(/methodName/g, methodName))(ensureMethod); +}; + +var makeGetter = function (propertyName) { + return new Function("obj", " \n\ + 'use strict'; \n\ + return obj.propertyName; \n\ + ".replace("propertyName", propertyName)); +}; + +var getCompiled = function(name, compiler, cache) { + var ret = cache[name]; + if (typeof ret !== "function") { + if (!isIdentifier(name)) { + return null; + } + ret = compiler(name); + cache[name] = ret; + cache[" size"]++; + if (cache[" size"] > 512) { + var keys = Object.keys(cache); + for (var i = 0; i < 256; ++i) delete cache[keys[i]]; + cache[" size"] = keys.length - 256; + } + } + return ret; +}; +getMethodCaller = function(name) { + return getCompiled(name, makeMethodCaller, callerCache); +}; + +getGetter = function(name) { + return getCompiled(name, makeGetter, getterCache); +}; +} +function ensureMethod(obj, methodName) { + var fn; + if (obj != null) fn = obj[methodName]; + if (typeof fn !== "function") { + var message = "Object " + util.classString(obj) + " has no method '" + + util.toString(methodName) + "'"; + throw new Promise.TypeError(message); + } + return fn; +} -var DOMProperty = __webpack_require__(17); -var EventPluginHub = __webpack_require__(32); -var EventPluginUtils = __webpack_require__(50); -var ReactComponentEnvironment = __webpack_require__(59); -var ReactEmptyComponent = __webpack_require__(98); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactHostComponent = __webpack_require__(99); -var ReactUpdates = __webpack_require__(15); +function caller(obj) { + var methodName = this.pop(); + var fn = ensureMethod(obj, methodName); + return fn.apply(obj, this); +} +Promise.prototype.call = function (methodName) { + var args = [].slice.call(arguments, 1);; + if (false) { + if (canEvaluate) { + var maybeCaller = getMethodCaller(methodName); + if (maybeCaller !== null) { + return this._then( + maybeCaller, undefined, undefined, args, undefined); + } + } + } + args.push(methodName); + return this._then(caller, undefined, undefined, args, undefined); +}; -var ReactInjection = { - Component: ReactComponentEnvironment.injection, - DOMProperty: DOMProperty.injection, - EmptyComponent: ReactEmptyComponent.injection, - EventPluginHub: EventPluginHub.injection, - EventPluginUtils: EventPluginUtils.injection, - EventEmitter: ReactBrowserEventEmitter.injection, - HostComponent: ReactHostComponent.injection, - Updates: ReactUpdates.injection +function namedGetter(obj) { + return obj[this]; +} +function indexedGetter(obj) { + var index = +this; + if (index < 0) index = Math.max(0, index + obj.length); + return obj[index]; +} +Promise.prototype.get = function (propertyName) { + var isIndex = (typeof propertyName === "number"); + var getter; + if (!isIndex) { + if (canEvaluate) { + var maybeGetter = getGetter(propertyName); + getter = maybeGetter !== null ? maybeGetter : namedGetter; + } else { + getter = namedGetter; + } + } else { + getter = indexedGetter; + } + return this._then(getter, undefined, undefined, propertyName, undefined); +}; }; -module.exports = ReactInjection; +},{"./util":36}],6:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, PromiseArray, apiRejection, debug) { +var util = _dereq_("./util"); +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; +var async = Promise._async; + +Promise.prototype["break"] = Promise.prototype.cancel = function() { + if (!debug.cancellation()) return this._warn("cancellation is disabled"); + + var promise = this; + var child = promise; + while (promise._isCancellable()) { + if (!promise._cancelBy(child)) { + if (child._isFollowing()) { + child._followee().cancel(); + } else { + child._cancelBranched(); + } + break; + } -/***/ }), -/* 192 */ -/***/ (function(module, exports, __webpack_require__) { + var parent = promise._cancellationParent; + if (parent == null || !parent._isCancellable()) { + if (promise._isFollowing()) { + promise._followee().cancel(); + } else { + promise._cancelBranched(); + } + break; + } else { + if (promise._isFollowing()) promise._followee().cancel(); + promise._setWillBeCancelled(); + child = promise; + promise = parent; + } + } +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype._branchHasCancelled = function() { + this._branchesRemainingToCancel--; +}; +Promise.prototype._enoughBranchesHaveCancelled = function() { + return this._branchesRemainingToCancel === undefined || + this._branchesRemainingToCancel <= 0; +}; +Promise.prototype._cancelBy = function(canceller) { + if (canceller === this) { + this._branchesRemainingToCancel = 0; + this._invokeOnCancel(); + return true; + } else { + this._branchHasCancelled(); + if (this._enoughBranchesHaveCancelled()) { + this._invokeOnCancel(); + return true; + } + } + return false; +}; -var _assign = __webpack_require__(5); +Promise.prototype._cancelBranched = function() { + if (this._enoughBranchesHaveCancelled()) { + this._cancel(); + } +}; -var CallbackQueue = __webpack_require__(85); -var PooledClass = __webpack_require__(20); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactInputSelection = __webpack_require__(102); -var ReactInstrumentation = __webpack_require__(13); -var Transaction = __webpack_require__(41); -var ReactUpdateQueue = __webpack_require__(63); +Promise.prototype._cancel = function() { + if (!this._isCancellable()) return; + this._setCancelled(); + async.invoke(this._cancelPromises, this, undefined); +}; -/** - * Ensures that, when possible, the selection range (currently selected text - * input) is not disturbed by performing the transaction. - */ -var SELECTION_RESTORATION = { - /** - * @return {Selection} Selection information. - */ - initialize: ReactInputSelection.getSelectionInformation, - /** - * @param {Selection} sel Selection information returned from `initialize`. - */ - close: ReactInputSelection.restoreSelection +Promise.prototype._cancelPromises = function() { + if (this._length() > 0) this._settlePromises(); }; -/** - * Suppresses events (blur/focus) that could be inadvertently dispatched due to - * high level DOM manipulations (like temporarily removing a text input from the - * DOM). - */ -var EVENT_SUPPRESSION = { - /** - * @return {boolean} The enabled status of `ReactBrowserEventEmitter` before - * the reconciliation. - */ - initialize: function () { - var currentlyEnabled = ReactBrowserEventEmitter.isEnabled(); - ReactBrowserEventEmitter.setEnabled(false); - return currentlyEnabled; - }, +Promise.prototype._unsetOnCancel = function() { + this._onCancelField = undefined; +}; - /** - * @param {boolean} previouslyEnabled Enabled status of - * `ReactBrowserEventEmitter` before the reconciliation occurred. `close` - * restores the previous value. - */ - close: function (previouslyEnabled) { - ReactBrowserEventEmitter.setEnabled(previouslyEnabled); - } +Promise.prototype._isCancellable = function() { + return this.isPending() && !this._isCancelled(); }; -/** - * Provides a queue for collecting `componentDidMount` and - * `componentDidUpdate` callbacks during the transaction. - */ -var ON_DOM_READY_QUEUEING = { - /** - * Initializes the internal `onDOMReady` queue. - */ - initialize: function () { - this.reactMountReady.reset(); - }, +Promise.prototype.isCancellable = function() { + return this.isPending() && !this.isCancelled(); +}; - /** - * After DOM is flushed, invoke all registered `onDOMReady` callbacks. - */ - close: function () { - this.reactMountReady.notifyAll(); - } +Promise.prototype._doInvokeOnCancel = function(onCancelCallback, internalOnly) { + if (util.isArray(onCancelCallback)) { + for (var i = 0; i < onCancelCallback.length; ++i) { + this._doInvokeOnCancel(onCancelCallback[i], internalOnly); + } + } else if (onCancelCallback !== undefined) { + if (typeof onCancelCallback === "function") { + if (!internalOnly) { + var e = tryCatch(onCancelCallback).call(this._boundValue()); + if (e === errorObj) { + this._attachExtraTrace(e.e); + async.throwLater(e.e); + } + } + } else { + onCancelCallback._resultCancelled(this); + } + } }; -/** - * Executed within the scope of the `Transaction` instance. Consider these as - * being member methods, but with an implied ordering while being isolated from - * each other. - */ -var TRANSACTION_WRAPPERS = [SELECTION_RESTORATION, EVENT_SUPPRESSION, ON_DOM_READY_QUEUEING]; +Promise.prototype._invokeOnCancel = function() { + var onCancelCallback = this._onCancel(); + this._unsetOnCancel(); + async.invoke(this._doInvokeOnCancel, this, onCancelCallback); +}; -if (process.env.NODE_ENV !== 'production') { - TRANSACTION_WRAPPERS.push({ - initialize: ReactInstrumentation.debugTool.onBeginFlush, - close: ReactInstrumentation.debugTool.onEndFlush - }); -} +Promise.prototype._invokeInternalOnCancel = function() { + if (this._isCancellable()) { + this._doInvokeOnCancel(this._onCancel(), true); + this._unsetOnCancel(); + } +}; -/** - * Currently: - * - The order that these are listed in the transaction is critical: - * - Suppresses events. - * - Restores selection range. - * - * Future: - * - Restore document/overflow scroll positions that were unintentionally - * modified via DOM insertions above the top viewport boundary. - * - Implement/integrate with customized constraint based layout system and keep - * track of which dimensions must be remeasured. - * - * @class ReactReconcileTransaction - */ -function ReactReconcileTransaction(useCreateElement) { - this.reinitializeTransaction(); - // Only server-side rendering really needs this option (see - // `ReactServerRendering`), but server-side uses - // `ReactServerRenderingTransaction` instead. This option is here so that it's - // accessible and defaults to false when `ReactDOMComponent` and - // `ReactDOMTextComponent` checks it in `mountComponent`.` - this.renderToStaticMarkup = false; - this.reactMountReady = CallbackQueue.getPooled(null); - this.useCreateElement = useCreateElement; -} +Promise.prototype._resultCancelled = function() { + this.cancel(); +}; -var Mixin = { - /** - * @see Transaction - * @abstract - * @final - * @return {array<object>} List of operation wrap procedures. - * TODO: convert to array<TransactionWrapper> - */ - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, +}; - /** - * @return {object} The queue to collect `onDOMReady` callbacks with. - */ - getReactMountReady: function () { - return this.reactMountReady; - }, +},{"./util":36}],7:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(NEXT_FILTER) { +var util = _dereq_("./util"); +var getKeys = _dereq_("./es5").keys; +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; + +function catchFilter(instances, cb, promise) { + return function(e) { + var boundTo = promise._boundValue(); + predicateLoop: for (var i = 0; i < instances.length; ++i) { + var item = instances[i]; + + if (item === Error || + (item != null && item.prototype instanceof Error)) { + if (e instanceof item) { + return tryCatch(cb).call(boundTo, e); + } + } else if (typeof item === "function") { + var matchesPredicate = tryCatch(item).call(boundTo, e); + if (matchesPredicate === errorObj) { + return matchesPredicate; + } else if (matchesPredicate) { + return tryCatch(cb).call(boundTo, e); + } + } else if (util.isObject(e)) { + var keys = getKeys(item); + for (var j = 0; j < keys.length; ++j) { + var key = keys[j]; + if (item[key] != e[key]) { + continue predicateLoop; + } + } + return tryCatch(cb).call(boundTo, e); + } + } + return NEXT_FILTER; + }; +} - /** - * @return {object} The queue to collect React async events. - */ - getUpdateQueue: function () { - return ReactUpdateQueue; - }, +return catchFilter; +}; - /** - * Save current transaction state -- if the return value from this method is - * passed to `rollback`, the transaction will be reset to that state. - */ - checkpoint: function () { - // reactMountReady is the our only stateful wrapper - return this.reactMountReady.checkpoint(); - }, +},{"./es5":13,"./util":36}],8:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +var longStackTraces = false; +var contextStack = []; - rollback: function (checkpoint) { - this.reactMountReady.rollback(checkpoint); - }, +Promise.prototype._promiseCreated = function() {}; +Promise.prototype._pushContext = function() {}; +Promise.prototype._popContext = function() {return null;}; +Promise._peekContext = Promise.prototype._peekContext = function() {}; - /** - * `PooledClass` looks for this, and will invoke this before allowing this - * instance to be reused. - */ - destructor: function () { - CallbackQueue.release(this.reactMountReady); - this.reactMountReady = null; - } +function Context() { + this._trace = new Context.CapturedTrace(peekContext()); +} +Context.prototype._pushContext = function () { + if (this._trace !== undefined) { + this._trace._promiseCreated = null; + contextStack.push(this._trace); + } }; -_assign(ReactReconcileTransaction.prototype, Transaction, Mixin); - -PooledClass.addPoolingTo(ReactReconcileTransaction); +Context.prototype._popContext = function () { + if (this._trace !== undefined) { + var trace = contextStack.pop(); + var ret = trace._promiseCreated; + trace._promiseCreated = null; + return ret; + } + return null; +}; -module.exports = ReactReconcileTransaction; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function createContext() { + if (longStackTraces) return new Context(); +} -/***/ }), -/* 193 */ -/***/ (function(module, exports, __webpack_require__) { +function peekContext() { + var lastIndex = contextStack.length - 1; + if (lastIndex >= 0) { + return contextStack[lastIndex]; + } + return undefined; +} +Context.CapturedTrace = null; +Context.create = createContext; +Context.deactivateLongStackTraces = function() {}; +Context.activateLongStackTraces = function() { + var Promise_pushContext = Promise.prototype._pushContext; + var Promise_popContext = Promise.prototype._popContext; + var Promise_PeekContext = Promise._peekContext; + var Promise_peekContext = Promise.prototype._peekContext; + var Promise_promiseCreated = Promise.prototype._promiseCreated; + Context.deactivateLongStackTraces = function() { + Promise.prototype._pushContext = Promise_pushContext; + Promise.prototype._popContext = Promise_popContext; + Promise._peekContext = Promise_PeekContext; + Promise.prototype._peekContext = Promise_peekContext; + Promise.prototype._promiseCreated = Promise_promiseCreated; + longStackTraces = false; + }; + longStackTraces = true; + Promise.prototype._pushContext = Context.prototype._pushContext; + Promise.prototype._popContext = Context.prototype._popContext; + Promise._peekContext = Promise.prototype._peekContext = peekContext; + Promise.prototype._promiseCreated = function() { + var ctx = this._peekContext(); + if (ctx && ctx._promiseCreated == null) ctx._promiseCreated = this; + }; +}; +return Context; +}; +},{}],9:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = function(Promise, Context) { +var getDomain = Promise._getDomain; +var async = Promise._async; +var Warning = _dereq_("./errors").Warning; +var util = _dereq_("./util"); +var canAttachTrace = util.canAttachTrace; +var unhandledRejectionHandled; +var possiblyUnhandledRejection; +var bluebirdFramePattern = + /[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/; +var nodeFramePattern = /\((?:timers\.js):\d+:\d+\)/; +var parseLinePattern = /[\/<\(](.+?):(\d+):(\d+)\)?\s*$/; +var stackFramePattern = null; +var formatStack = null; +var indentStackFrames = false; +var printWarning; +var debugging = !!(util.env("BLUEBIRD_DEBUG") != 0 && + (true || + util.env("BLUEBIRD_DEBUG") || + util.env("NODE_ENV") === "development")); + +var warnings = !!(util.env("BLUEBIRD_WARNINGS") != 0 && + (debugging || util.env("BLUEBIRD_WARNINGS"))); + +var longStackTraces = !!(util.env("BLUEBIRD_LONG_STACK_TRACES") != 0 && + (debugging || util.env("BLUEBIRD_LONG_STACK_TRACES"))); + +var wForgottenReturn = util.env("BLUEBIRD_W_FORGOTTEN_RETURN") != 0 && + (warnings || !!util.env("BLUEBIRD_W_FORGOTTEN_RETURN")); + +Promise.prototype.suppressUnhandledRejections = function() { + var target = this._target(); + target._bitField = ((target._bitField & (~1048576)) | + 524288); +}; +Promise.prototype._ensurePossibleRejectionHandled = function () { + if ((this._bitField & 524288) !== 0) return; + this._setRejectionIsUnhandled(); + async.invokeLater(this._notifyUnhandledRejection, this, undefined); +}; +Promise.prototype._notifyUnhandledRejectionIsHandled = function () { + fireRejectionEvent("rejectionHandled", + unhandledRejectionHandled, undefined, this); +}; -var ExecutionEnvironment = __webpack_require__(8); +Promise.prototype._setReturnedNonUndefined = function() { + this._bitField = this._bitField | 268435456; +}; -var getNodeForCharacterOffset = __webpack_require__(194); -var getTextContentAccessor = __webpack_require__(84); +Promise.prototype._returnedNonUndefined = function() { + return (this._bitField & 268435456) !== 0; +}; -/** - * While `isCollapsed` is available on the Selection object and `collapsed` - * is available on the Range object, IE11 sometimes gets them wrong. - * If the anchor/focus nodes and offsets are the same, the range is collapsed. - */ -function isCollapsed(anchorNode, anchorOffset, focusNode, focusOffset) { - return anchorNode === focusNode && anchorOffset === focusOffset; -} +Promise.prototype._notifyUnhandledRejection = function () { + if (this._isRejectionUnhandled()) { + var reason = this._settledValue(); + this._setUnhandledRejectionIsNotified(); + fireRejectionEvent("unhandledRejection", + possiblyUnhandledRejection, reason, this); + } +}; -/** - * Get the appropriate anchor and focus node/offset pairs for IE. - * - * The catch here is that IE's selection API doesn't provide information - * about whether the selection is forward or backward, so we have to - * behave as though it's always forward. - * - * IE text differs from modern selection in that it behaves as though - * block elements end with a new line. This means character offsets will - * differ between the two APIs. - * - * @param {DOMElement} node - * @return {object} - */ -function getIEOffsets(node) { - var selection = document.selection; - var selectedRange = selection.createRange(); - var selectedLength = selectedRange.text.length; +Promise.prototype._setUnhandledRejectionIsNotified = function () { + this._bitField = this._bitField | 262144; +}; - // Duplicate selection so we can move range without breaking user selection. - var fromStart = selectedRange.duplicate(); - fromStart.moveToElementText(node); - fromStart.setEndPoint('EndToStart', selectedRange); +Promise.prototype._unsetUnhandledRejectionIsNotified = function () { + this._bitField = this._bitField & (~262144); +}; - var startOffset = fromStart.text.length; - var endOffset = startOffset + selectedLength; +Promise.prototype._isUnhandledRejectionNotified = function () { + return (this._bitField & 262144) > 0; +}; - return { - start: startOffset, - end: endOffset - }; -} +Promise.prototype._setRejectionIsUnhandled = function () { + this._bitField = this._bitField | 1048576; +}; -/** - * @param {DOMElement} node - * @return {?object} - */ -function getModernOffsets(node) { - var selection = window.getSelection && window.getSelection(); +Promise.prototype._unsetRejectionIsUnhandled = function () { + this._bitField = this._bitField & (~1048576); + if (this._isUnhandledRejectionNotified()) { + this._unsetUnhandledRejectionIsNotified(); + this._notifyUnhandledRejectionIsHandled(); + } +}; - if (!selection || selection.rangeCount === 0) { - return null; - } +Promise.prototype._isRejectionUnhandled = function () { + return (this._bitField & 1048576) > 0; +}; - var anchorNode = selection.anchorNode; - var anchorOffset = selection.anchorOffset; - var focusNode = selection.focusNode; - var focusOffset = selection.focusOffset; +Promise.prototype._warn = function(message, shouldUseOwnTrace, promise) { + return warn(message, shouldUseOwnTrace, promise || this); +}; - var currentRange = selection.getRangeAt(0); +Promise.onPossiblyUnhandledRejection = function (fn) { + var domain = getDomain(); + possiblyUnhandledRejection = + typeof fn === "function" ? (domain === null ? + fn : util.domainBind(domain, fn)) + : undefined; +}; - // In Firefox, range.startContainer and range.endContainer can be "anonymous - // divs", e.g. the up/down buttons on an <input type="number">. Anonymous - // divs do not seem to expose properties, triggering a "Permission denied - // error" if any of its properties are accessed. The only seemingly possible - // way to avoid erroring is to access a property that typically works for - // non-anonymous divs and catch any error that may otherwise arise. See - // https://bugzilla.mozilla.org/show_bug.cgi?id=208427 - try { - /* eslint-disable no-unused-expressions */ - currentRange.startContainer.nodeType; - currentRange.endContainer.nodeType; - /* eslint-enable no-unused-expressions */ - } catch (e) { - return null; - } +Promise.onUnhandledRejectionHandled = function (fn) { + var domain = getDomain(); + unhandledRejectionHandled = + typeof fn === "function" ? (domain === null ? + fn : util.domainBind(domain, fn)) + : undefined; +}; - // If the node and offset values are the same, the selection is collapsed. - // `Selection.isCollapsed` is available natively, but IE sometimes gets - // this value wrong. - var isSelectionCollapsed = isCollapsed(selection.anchorNode, selection.anchorOffset, selection.focusNode, selection.focusOffset); +var disableLongStackTraces = function() {}; +Promise.longStackTraces = function () { + if (async.haveItemsQueued() && !config.longStackTraces) { + throw new Error("cannot enable long stack traces after promises have been created\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + if (!config.longStackTraces && longStackTracesIsSupported()) { + var Promise_captureStackTrace = Promise.prototype._captureStackTrace; + var Promise_attachExtraTrace = Promise.prototype._attachExtraTrace; + config.longStackTraces = true; + disableLongStackTraces = function() { + if (async.haveItemsQueued() && !config.longStackTraces) { + throw new Error("cannot enable long stack traces after promises have been created\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + Promise.prototype._captureStackTrace = Promise_captureStackTrace; + Promise.prototype._attachExtraTrace = Promise_attachExtraTrace; + Context.deactivateLongStackTraces(); + async.enableTrampoline(); + config.longStackTraces = false; + }; + Promise.prototype._captureStackTrace = longStackTracesCaptureStackTrace; + Promise.prototype._attachExtraTrace = longStackTracesAttachExtraTrace; + Context.activateLongStackTraces(); + async.disableTrampolineIfNecessary(); + } +}; - var rangeLength = isSelectionCollapsed ? 0 : currentRange.toString().length; +Promise.hasLongStackTraces = function () { + return config.longStackTraces && longStackTracesIsSupported(); +}; - var tempRange = currentRange.cloneRange(); - tempRange.selectNodeContents(node); - tempRange.setEnd(currentRange.startContainer, currentRange.startOffset); +var fireDomEvent = (function() { + try { + if (typeof CustomEvent === "function") { + var event = new CustomEvent("CustomEvent"); + util.global.dispatchEvent(event); + return function(name, event) { + var domEvent = new CustomEvent(name.toLowerCase(), { + detail: event, + cancelable: true + }); + return !util.global.dispatchEvent(domEvent); + }; + } else if (typeof Event === "function") { + var event = new Event("CustomEvent"); + util.global.dispatchEvent(event); + return function(name, event) { + var domEvent = new Event(name.toLowerCase(), { + cancelable: true + }); + domEvent.detail = event; + return !util.global.dispatchEvent(domEvent); + }; + } else { + var event = document.createEvent("CustomEvent"); + event.initCustomEvent("testingtheevent", false, true, {}); + util.global.dispatchEvent(event); + return function(name, event) { + var domEvent = document.createEvent("CustomEvent"); + domEvent.initCustomEvent(name.toLowerCase(), false, true, + event); + return !util.global.dispatchEvent(domEvent); + }; + } + } catch (e) {} + return function() { + return false; + }; +})(); - var isTempRangeCollapsed = isCollapsed(tempRange.startContainer, tempRange.startOffset, tempRange.endContainer, tempRange.endOffset); +var fireGlobalEvent = (function() { + if (util.isNode) { + return function() { + return process.emit.apply(process, arguments); + }; + } else { + if (!util.global) { + return function() { + return false; + }; + } + return function(name) { + var methodName = "on" + name.toLowerCase(); + var method = util.global[methodName]; + if (!method) return false; + method.apply(util.global, [].slice.call(arguments, 1)); + return true; + }; + } +})(); - var start = isTempRangeCollapsed ? 0 : tempRange.toString().length; - var end = start + rangeLength; +function generatePromiseLifecycleEventObject(name, promise) { + return {promise: promise}; +} - // Detect whether the selection is backward. - var detectionRange = document.createRange(); - detectionRange.setStart(anchorNode, anchorOffset); - detectionRange.setEnd(focusNode, focusOffset); - var isBackward = detectionRange.collapsed; +var eventToObjectGenerator = { + promiseCreated: generatePromiseLifecycleEventObject, + promiseFulfilled: generatePromiseLifecycleEventObject, + promiseRejected: generatePromiseLifecycleEventObject, + promiseResolved: generatePromiseLifecycleEventObject, + promiseCancelled: generatePromiseLifecycleEventObject, + promiseChained: function(name, promise, child) { + return {promise: promise, child: child}; + }, + warning: function(name, warning) { + return {warning: warning}; + }, + unhandledRejection: function (name, reason, promise) { + return {reason: reason, promise: promise}; + }, + rejectionHandled: generatePromiseLifecycleEventObject +}; - return { - start: isBackward ? end : start, - end: isBackward ? start : end - }; -} +var activeFireEvent = function (name) { + var globalEventFired = false; + try { + globalEventFired = fireGlobalEvent.apply(null, arguments); + } catch (e) { + async.throwLater(e); + globalEventFired = true; + } -/** - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ -function setIEOffsets(node, offsets) { - var range = document.selection.createRange().duplicate(); - var start, end; + var domEventFired = false; + try { + domEventFired = fireDomEvent(name, + eventToObjectGenerator[name].apply(null, arguments)); + } catch (e) { + async.throwLater(e); + domEventFired = true; + } - if (offsets.end === undefined) { - start = offsets.start; - end = start; - } else if (offsets.start > offsets.end) { - start = offsets.end; - end = offsets.start; - } else { - start = offsets.start; - end = offsets.end; - } + return domEventFired || globalEventFired; +}; - range.moveToElementText(node); - range.moveStart('character', start); - range.setEndPoint('EndToStart', range); - range.moveEnd('character', end - start); - range.select(); -} +Promise.config = function(opts) { + opts = Object(opts); + if ("longStackTraces" in opts) { + if (opts.longStackTraces) { + Promise.longStackTraces(); + } else if (!opts.longStackTraces && Promise.hasLongStackTraces()) { + disableLongStackTraces(); + } + } + if ("warnings" in opts) { + var warningsOption = opts.warnings; + config.warnings = !!warningsOption; + wForgottenReturn = config.warnings; -/** - * In modern non-IE browsers, we can support both forward and backward - * selections. - * - * Note: IE10+ supports the Selection object, but it does not support - * the `extend` method, which means that even in modern IE, it's not possible - * to programmatically create a backward selection. Thus, for all IE - * versions, we use the old IE API to create our selections. - * - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ -function setModernOffsets(node, offsets) { - if (!window.getSelection) { - return; - } + if (util.isObject(warningsOption)) { + if ("wForgottenReturn" in warningsOption) { + wForgottenReturn = !!warningsOption.wForgottenReturn; + } + } + } + if ("cancellation" in opts && opts.cancellation && !config.cancellation) { + if (async.haveItemsQueued()) { + throw new Error( + "cannot enable cancellation after promises are in use"); + } + Promise.prototype._clearCancellationData = + cancellationClearCancellationData; + Promise.prototype._propagateFrom = cancellationPropagateFrom; + Promise.prototype._onCancel = cancellationOnCancel; + Promise.prototype._setOnCancel = cancellationSetOnCancel; + Promise.prototype._attachCancellationCallback = + cancellationAttachCancellationCallback; + Promise.prototype._execute = cancellationExecute; + propagateFromFunction = cancellationPropagateFrom; + config.cancellation = true; + } + if ("monitoring" in opts) { + if (opts.monitoring && !config.monitoring) { + config.monitoring = true; + Promise.prototype._fireEvent = activeFireEvent; + } else if (!opts.monitoring && config.monitoring) { + config.monitoring = false; + Promise.prototype._fireEvent = defaultFireEvent; + } + } + return Promise; +}; - var selection = window.getSelection(); - var length = node[getTextContentAccessor()].length; - var start = Math.min(offsets.start, length); - var end = offsets.end === undefined ? start : Math.min(offsets.end, length); +function defaultFireEvent() { return false; } - // IE 11 uses modern selection, but doesn't support the extend method. - // Flip backward selections, so we can set with a single range. - if (!selection.extend && start > end) { - var temp = end; - end = start; - start = temp; - } +Promise.prototype._fireEvent = defaultFireEvent; +Promise.prototype._execute = function(executor, resolve, reject) { + try { + executor(resolve, reject); + } catch (e) { + return e; + } +}; +Promise.prototype._onCancel = function () {}; +Promise.prototype._setOnCancel = function (handler) { ; }; +Promise.prototype._attachCancellationCallback = function(onCancel) { + ; +}; +Promise.prototype._captureStackTrace = function () {}; +Promise.prototype._attachExtraTrace = function () {}; +Promise.prototype._clearCancellationData = function() {}; +Promise.prototype._propagateFrom = function (parent, flags) { + ; + ; +}; - var startMarker = getNodeForCharacterOffset(node, start); - var endMarker = getNodeForCharacterOffset(node, end); +function cancellationExecute(executor, resolve, reject) { + var promise = this; + try { + executor(resolve, reject, function(onCancel) { + if (typeof onCancel !== "function") { + throw new TypeError("onCancel must be a function, got: " + + util.toString(onCancel)); + } + promise._attachCancellationCallback(onCancel); + }); + } catch (e) { + return e; + } +} - if (startMarker && endMarker) { - var range = document.createRange(); - range.setStart(startMarker.node, startMarker.offset); - selection.removeAllRanges(); +function cancellationAttachCancellationCallback(onCancel) { + if (!this._isCancellable()) return this; - if (start > end) { - selection.addRange(range); - selection.extend(endMarker.node, endMarker.offset); + var previousOnCancel = this._onCancel(); + if (previousOnCancel !== undefined) { + if (util.isArray(previousOnCancel)) { + previousOnCancel.push(onCancel); + } else { + this._setOnCancel([previousOnCancel, onCancel]); + } } else { - range.setEnd(endMarker.node, endMarker.offset); - selection.addRange(range); + this._setOnCancel(onCancel); } - } } -var useIEOffsets = ExecutionEnvironment.canUseDOM && 'selection' in document && !('getSelection' in window); +function cancellationOnCancel() { + return this._onCancelField; +} -var ReactDOMSelection = { - /** - * @param {DOMElement} node - */ - getOffsets: useIEOffsets ? getIEOffsets : getModernOffsets, +function cancellationSetOnCancel(onCancel) { + this._onCancelField = onCancel; +} - /** - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ - setOffsets: useIEOffsets ? setIEOffsets : setModernOffsets -}; +function cancellationClearCancellationData() { + this._cancellationParent = undefined; + this._onCancelField = undefined; +} -module.exports = ReactDOMSelection; +function cancellationPropagateFrom(parent, flags) { + if ((flags & 1) !== 0) { + this._cancellationParent = parent; + var branchesRemainingToCancel = parent._branchesRemainingToCancel; + if (branchesRemainingToCancel === undefined) { + branchesRemainingToCancel = 0; + } + parent._branchesRemainingToCancel = branchesRemainingToCancel + 1; + } + if ((flags & 2) !== 0 && parent._isBound()) { + this._setBoundTo(parent._boundTo); + } +} -/***/ }), -/* 194 */ -/***/ (function(module, exports, __webpack_require__) { +function bindingPropagateFrom(parent, flags) { + if ((flags & 2) !== 0 && parent._isBound()) { + this._setBoundTo(parent._boundTo); + } +} +var propagateFromFunction = bindingPropagateFrom; + +function boundValueFunction() { + var ret = this._boundTo; + if (ret !== undefined) { + if (ret instanceof Promise) { + if (ret.isFulfilled()) { + return ret.value(); + } else { + return undefined; + } + } + } + return ret; +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function longStackTracesCaptureStackTrace() { + this._trace = new CapturedTrace(this._peekContext()); +} +function longStackTracesAttachExtraTrace(error, ignoreSelf) { + if (canAttachTrace(error)) { + var trace = this._trace; + if (trace !== undefined) { + if (ignoreSelf) trace = trace._parent; + } + if (trace !== undefined) { + trace.attachExtraTrace(error); + } else if (!error.__stackCleaned__) { + var parsed = parseStackAndMessage(error); + util.notEnumerableProp(error, "stack", + parsed.message + "\n" + parsed.stack.join("\n")); + util.notEnumerableProp(error, "__stackCleaned__", true); + } + } +} +function checkForgottenReturns(returnValue, promiseCreated, name, promise, + parent) { + if (returnValue === undefined && promiseCreated !== null && + wForgottenReturn) { + if (parent !== undefined && parent._returnedNonUndefined()) return; + if ((promise._bitField & 65535) === 0) return; + + if (name) name = name + " "; + var handlerLine = ""; + var creatorLine = ""; + if (promiseCreated._trace) { + var traceLines = promiseCreated._trace.stack.split("\n"); + var stack = cleanStack(traceLines); + for (var i = stack.length - 1; i >= 0; --i) { + var line = stack[i]; + if (!nodeFramePattern.test(line)) { + var lineMatches = line.match(parseLinePattern); + if (lineMatches) { + handlerLine = "at " + lineMatches[1] + + ":" + lineMatches[2] + ":" + lineMatches[3] + " "; + } + break; + } + } -/** - * Given any node return the first leaf node without children. - * - * @param {DOMElement|DOMTextNode} node - * @return {DOMElement|DOMTextNode} - */ + if (stack.length > 0) { + var firstUserLine = stack[0]; + for (var i = 0; i < traceLines.length; ++i) { -function getLeafNode(node) { - while (node && node.firstChild) { - node = node.firstChild; - } - return node; -} + if (traceLines[i] === firstUserLine) { + if (i > 0) { + creatorLine = "\n" + traceLines[i - 1]; + } + break; + } + } -/** - * Get the next sibling within a container. This will walk up the - * DOM if a node's siblings have been exhausted. - * - * @param {DOMElement|DOMTextNode} node - * @return {?DOMElement|DOMTextNode} - */ -function getSiblingNode(node) { - while (node) { - if (node.nextSibling) { - return node.nextSibling; + } + } + var msg = "a promise was created in a " + name + + "handler " + handlerLine + "but was not returned from it, " + + "see http://goo.gl/rRqMUw" + + creatorLine; + promise._warn(msg, true, promiseCreated); } - node = node.parentNode; - } } -/** - * Get object describing the nodes which contain characters at offset. - * - * @param {DOMElement|DOMTextNode} root - * @param {number} offset - * @return {?object} - */ -function getNodeForCharacterOffset(root, offset) { - var node = getLeafNode(root); - var nodeStart = 0; - var nodeEnd = 0; +function deprecated(name, replacement) { + var message = name + + " is deprecated and will be removed in a future version."; + if (replacement) message += " Use " + replacement + " instead."; + return warn(message); +} - while (node) { - if (node.nodeType === 3) { - nodeEnd = nodeStart + node.textContent.length; +function warn(message, shouldUseOwnTrace, promise) { + if (!config.warnings) return; + var warning = new Warning(message); + var ctx; + if (shouldUseOwnTrace) { + promise._attachExtraTrace(warning); + } else if (config.longStackTraces && (ctx = Promise._peekContext())) { + ctx.attachExtraTrace(warning); + } else { + var parsed = parseStackAndMessage(warning); + warning.stack = parsed.message + "\n" + parsed.stack.join("\n"); + } - if (nodeStart <= offset && nodeEnd >= offset) { - return { - node: node, - offset: offset - nodeStart - }; - } + if (!activeFireEvent("warning", warning)) { + formatAndLogError(warning, "", true); + } +} - nodeStart = nodeEnd; +function reconstructStack(message, stacks) { + for (var i = 0; i < stacks.length - 1; ++i) { + stacks[i].push("From previous event:"); + stacks[i] = stacks[i].join("\n"); } + if (i < stacks.length) { + stacks[i] = stacks[i].join("\n"); + } + return message + "\n" + stacks.join("\n"); +} - node = getLeafNode(getSiblingNode(node)); - } +function removeDuplicateOrEmptyJumps(stacks) { + for (var i = 0; i < stacks.length; ++i) { + if (stacks[i].length === 0 || + ((i + 1 < stacks.length) && stacks[i][0] === stacks[i+1][0])) { + stacks.splice(i, 1); + i--; + } + } } -module.exports = getNodeForCharacterOffset; +function removeCommonRoots(stacks) { + var current = stacks[0]; + for (var i = 1; i < stacks.length; ++i) { + var prev = stacks[i]; + var currentLastIndex = current.length - 1; + var currentLastLine = current[currentLastIndex]; + var commonRootMeetPoint = -1; + + for (var j = prev.length - 1; j >= 0; --j) { + if (prev[j] === currentLastLine) { + commonRootMeetPoint = j; + break; + } + } -/***/ }), -/* 195 */ -/***/ (function(module, exports, __webpack_require__) { + for (var j = commonRootMeetPoint; j >= 0; --j) { + var line = prev[j]; + if (current[currentLastIndex] === line) { + current.pop(); + currentLastIndex--; + } else { + break; + } + } + current = prev; + } +} -"use strict"; +function cleanStack(stack) { + var ret = []; + for (var i = 0; i < stack.length; ++i) { + var line = stack[i]; + var isTraceLine = " (No stack trace)" === line || + stackFramePattern.test(line); + var isInternalFrame = isTraceLine && shouldIgnore(line); + if (isTraceLine && !isInternalFrame) { + if (indentStackFrames && line.charAt(0) !== " ") { + line = " " + line; + } + ret.push(line); + } + } + return ret; +} +function stackFramesAsArray(error) { + var stack = error.stack.replace(/\s+$/g, "").split("\n"); + for (var i = 0; i < stack.length; ++i) { + var line = stack[i]; + if (" (No stack trace)" === line || stackFramePattern.test(line)) { + break; + } + } + if (i > 0 && error.name != "SyntaxError") { + stack = stack.slice(i); + } + return stack; +} -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +function parseStackAndMessage(error) { + var stack = error.stack; + var message = error.toString(); + stack = typeof stack === "string" && stack.length > 0 + ? stackFramesAsArray(error) : [" (No stack trace)"]; + return { + message: message, + stack: error.name == "SyntaxError" ? stack : cleanStack(stack) + }; +} -var isTextNode = __webpack_require__(196); +function formatAndLogError(error, title, isSoft) { + if (typeof console !== "undefined") { + var message; + if (util.isObject(error)) { + var stack = error.stack; + message = title + formatStack(stack, error); + } else { + message = title + String(error); + } + if (typeof printWarning === "function") { + printWarning(message, isSoft); + } else if (typeof console.log === "function" || + typeof console.log === "object") { + console.log(message); + } + } +} -/*eslint-disable no-bitwise */ +function fireRejectionEvent(name, localHandler, reason, promise) { + var localEventFired = false; + try { + if (typeof localHandler === "function") { + localEventFired = true; + if (name === "rejectionHandled") { + localHandler(promise); + } else { + localHandler(reason, promise); + } + } + } catch (e) { + async.throwLater(e); + } -/** - * Checks if a given DOM node contains or is another DOM node. - */ -function containsNode(outerNode, innerNode) { - if (!outerNode || !innerNode) { - return false; - } else if (outerNode === innerNode) { - return true; - } else if (isTextNode(outerNode)) { - return false; - } else if (isTextNode(innerNode)) { - return containsNode(outerNode, innerNode.parentNode); - } else if ('contains' in outerNode) { - return outerNode.contains(innerNode); - } else if (outerNode.compareDocumentPosition) { - return !!(outerNode.compareDocumentPosition(innerNode) & 16); - } else { - return false; - } + if (name === "unhandledRejection") { + if (!activeFireEvent(name, reason, promise) && !localEventFired) { + formatAndLogError(reason, "Unhandled rejection "); + } + } else { + activeFireEvent(name, promise); + } } -module.exports = containsNode; +function formatNonError(obj) { + var str; + if (typeof obj === "function") { + str = "[function " + + (obj.name || "anonymous") + + "]"; + } else { + str = obj && typeof obj.toString === "function" + ? obj.toString() : util.toString(obj); + var ruselessToString = /\[object [a-zA-Z0-9$_]+\]/; + if (ruselessToString.test(str)) { + try { + var newStr = JSON.stringify(obj); + str = newStr; + } + catch(e) { -/***/ }), -/* 196 */ -/***/ (function(module, exports, __webpack_require__) { + } + } + if (str.length === 0) { + str = "(empty array)"; + } + } + return ("(<" + snip(str) + ">, no stack trace)"); +} -"use strict"; +function snip(str) { + var maxChars = 41; + if (str.length < maxChars) { + return str; + } + return str.substr(0, maxChars - 3) + "..."; +} +function longStackTracesIsSupported() { + return typeof captureStackTrace === "function"; +} -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +var shouldIgnore = function() { return false; }; +var parseLineInfoRegex = /[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/; +function parseLineInfo(line) { + var matches = line.match(parseLineInfoRegex); + if (matches) { + return { + fileName: matches[1], + line: parseInt(matches[2], 10) + }; + } +} -var isNode = __webpack_require__(197); +function setBounds(firstLineError, lastLineError) { + if (!longStackTracesIsSupported()) return; + var firstStackLines = firstLineError.stack.split("\n"); + var lastStackLines = lastLineError.stack.split("\n"); + var firstIndex = -1; + var lastIndex = -1; + var firstFileName; + var lastFileName; + for (var i = 0; i < firstStackLines.length; ++i) { + var result = parseLineInfo(firstStackLines[i]); + if (result) { + firstFileName = result.fileName; + firstIndex = result.line; + break; + } + } + for (var i = 0; i < lastStackLines.length; ++i) { + var result = parseLineInfo(lastStackLines[i]); + if (result) { + lastFileName = result.fileName; + lastIndex = result.line; + break; + } + } + if (firstIndex < 0 || lastIndex < 0 || !firstFileName || !lastFileName || + firstFileName !== lastFileName || firstIndex >= lastIndex) { + return; + } -/** - * @param {*} object The object to check. - * @return {boolean} Whether or not the object is a DOM text node. - */ -function isTextNode(object) { - return isNode(object) && object.nodeType == 3; + shouldIgnore = function(line) { + if (bluebirdFramePattern.test(line)) return true; + var info = parseLineInfo(line); + if (info) { + if (info.fileName === firstFileName && + (firstIndex <= info.line && info.line <= lastIndex)) { + return true; + } + } + return false; + }; } -module.exports = isTextNode; +function CapturedTrace(parent) { + this._parent = parent; + this._promisesCreated = 0; + var length = this._length = 1 + (parent === undefined ? 0 : parent._length); + captureStackTrace(this, CapturedTrace); + if (length > 32) this.uncycle(); +} +util.inherits(CapturedTrace, Error); +Context.CapturedTrace = CapturedTrace; + +CapturedTrace.prototype.uncycle = function() { + var length = this._length; + if (length < 2) return; + var nodes = []; + var stackToIndex = {}; + + for (var i = 0, node = this; node !== undefined; ++i) { + nodes.push(node); + node = node._parent; + } + length = this._length = i; + for (var i = length - 1; i >= 0; --i) { + var stack = nodes[i].stack; + if (stackToIndex[stack] === undefined) { + stackToIndex[stack] = i; + } + } + for (var i = 0; i < length; ++i) { + var currentStack = nodes[i].stack; + var index = stackToIndex[currentStack]; + if (index !== undefined && index !== i) { + if (index > 0) { + nodes[index - 1]._parent = undefined; + nodes[index - 1]._length = 1; + } + nodes[i]._parent = undefined; + nodes[i]._length = 1; + var cycleEdgeNode = i > 0 ? nodes[i - 1] : this; + + if (index < length - 1) { + cycleEdgeNode._parent = nodes[index + 1]; + cycleEdgeNode._parent.uncycle(); + cycleEdgeNode._length = + cycleEdgeNode._parent._length + 1; + } else { + cycleEdgeNode._parent = undefined; + cycleEdgeNode._length = 1; + } + var currentChildLength = cycleEdgeNode._length + 1; + for (var j = i - 2; j >= 0; --j) { + nodes[j]._length = currentChildLength; + currentChildLength++; + } + return; + } + } +}; -/***/ }), -/* 197 */ -/***/ (function(module, exports, __webpack_require__) { +CapturedTrace.prototype.attachExtraTrace = function(error) { + if (error.__stackCleaned__) return; + this.uncycle(); + var parsed = parseStackAndMessage(error); + var message = parsed.message; + var stacks = [parsed.stack]; + + var trace = this; + while (trace !== undefined) { + stacks.push(cleanStack(trace.stack.split("\n"))); + trace = trace._parent; + } + removeCommonRoots(stacks); + removeDuplicateOrEmptyJumps(stacks); + util.notEnumerableProp(error, "stack", reconstructStack(message, stacks)); + util.notEnumerableProp(error, "__stackCleaned__", true); +}; -"use strict"; +var captureStackTrace = (function stackDetection() { + var v8stackFramePattern = /^\s*at\s*/; + var v8stackFormatter = function(stack, error) { + if (typeof stack === "string") return stack; + if (error.name !== undefined && + error.message !== undefined) { + return error.toString(); + } + return formatNonError(error); + }; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + if (typeof Error.stackTraceLimit === "number" && + typeof Error.captureStackTrace === "function") { + Error.stackTraceLimit += 6; + stackFramePattern = v8stackFramePattern; + formatStack = v8stackFormatter; + var captureStackTrace = Error.captureStackTrace; -/** - * @param {*} object The object to check. - * @return {boolean} Whether or not the object is a DOM node. - */ -function isNode(object) { - var doc = object ? object.ownerDocument || object : document; - var defaultView = doc.defaultView || window; - return !!(object && (typeof defaultView.Node === 'function' ? object instanceof defaultView.Node : typeof object === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string')); -} + shouldIgnore = function(line) { + return bluebirdFramePattern.test(line); + }; + return function(receiver, ignoreUntil) { + Error.stackTraceLimit += 6; + captureStackTrace(receiver, ignoreUntil); + Error.stackTraceLimit -= 6; + }; + } + var err = new Error(); -module.exports = isNode; + if (typeof err.stack === "string" && + err.stack.split("\n")[0].indexOf("stackDetection@") >= 0) { + stackFramePattern = /@/; + formatStack = v8stackFormatter; + indentStackFrames = true; + return function captureStackTrace(o) { + o.stack = new Error().stack; + }; + } -/***/ }), -/* 198 */ -/***/ (function(module, exports, __webpack_require__) { + var hasStackAfterThrow; + try { throw new Error(); } + catch(e) { + hasStackAfterThrow = ("stack" in e); + } + if (!("stack" in err) && hasStackAfterThrow && + typeof Error.stackTraceLimit === "number") { + stackFramePattern = v8stackFramePattern; + formatStack = v8stackFormatter; + return function captureStackTrace(o) { + Error.stackTraceLimit += 6; + try { throw new Error(); } + catch(e) { o.stack = e.stack; } + Error.stackTraceLimit -= 6; + }; + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + formatStack = function(stack, error) { + if (typeof stack === "string") return stack; + if ((typeof error === "object" || + typeof error === "function") && + error.name !== undefined && + error.message !== undefined) { + return error.toString(); + } + return formatNonError(error); + }; + return null; -var NS = { - xlink: 'http://www.w3.org/1999/xlink', - xml: 'http://www.w3.org/XML/1998/namespace' +})([]); + +if (typeof console !== "undefined" && typeof console.warn !== "undefined") { + printWarning = function (message) { + console.warn(message); + }; + if (util.isNode && process.stderr.isTTY) { + printWarning = function(message, isSoft) { + var color = isSoft ? "\u001b[33m" : "\u001b[31m"; + console.warn(color + message + "\u001b[0m\n"); + }; + } else if (!util.isNode && typeof (new Error().stack) === "string") { + printWarning = function(message, isSoft) { + console.warn("%c" + message, + isSoft ? "color: darkorange" : "color: red"); + }; + } +} + +var config = { + warnings: warnings, + longStackTraces: false, + cancellation: false, + monitoring: false }; -// We use attributes for everything SVG so let's avoid some duplication and run -// code instead. -// The following are all specified in the HTML config already so we exclude here. -// - class (as className) -// - color -// - height -// - id -// - lang -// - max -// - media -// - method -// - min -// - name -// - style -// - target -// - type -// - width -var ATTRS = { - accentHeight: 'accent-height', - accumulate: 0, - additive: 0, - alignmentBaseline: 'alignment-baseline', - allowReorder: 'allowReorder', - alphabetic: 0, - amplitude: 0, - arabicForm: 'arabic-form', - ascent: 0, - attributeName: 'attributeName', - attributeType: 'attributeType', - autoReverse: 'autoReverse', - azimuth: 0, - baseFrequency: 'baseFrequency', - baseProfile: 'baseProfile', - baselineShift: 'baseline-shift', - bbox: 0, - begin: 0, - bias: 0, - by: 0, - calcMode: 'calcMode', - capHeight: 'cap-height', - clip: 0, - clipPath: 'clip-path', - clipRule: 'clip-rule', - clipPathUnits: 'clipPathUnits', - colorInterpolation: 'color-interpolation', - colorInterpolationFilters: 'color-interpolation-filters', - colorProfile: 'color-profile', - colorRendering: 'color-rendering', - contentScriptType: 'contentScriptType', - contentStyleType: 'contentStyleType', - cursor: 0, - cx: 0, - cy: 0, - d: 0, - decelerate: 0, - descent: 0, - diffuseConstant: 'diffuseConstant', - direction: 0, - display: 0, - divisor: 0, - dominantBaseline: 'dominant-baseline', - dur: 0, - dx: 0, - dy: 0, - edgeMode: 'edgeMode', - elevation: 0, - enableBackground: 'enable-background', - end: 0, - exponent: 0, - externalResourcesRequired: 'externalResourcesRequired', - fill: 0, - fillOpacity: 'fill-opacity', - fillRule: 'fill-rule', - filter: 0, - filterRes: 'filterRes', - filterUnits: 'filterUnits', - floodColor: 'flood-color', - floodOpacity: 'flood-opacity', - focusable: 0, - fontFamily: 'font-family', - fontSize: 'font-size', - fontSizeAdjust: 'font-size-adjust', - fontStretch: 'font-stretch', - fontStyle: 'font-style', - fontVariant: 'font-variant', - fontWeight: 'font-weight', - format: 0, - from: 0, - fx: 0, - fy: 0, - g1: 0, - g2: 0, - glyphName: 'glyph-name', - glyphOrientationHorizontal: 'glyph-orientation-horizontal', - glyphOrientationVertical: 'glyph-orientation-vertical', - glyphRef: 'glyphRef', - gradientTransform: 'gradientTransform', - gradientUnits: 'gradientUnits', - hanging: 0, - horizAdvX: 'horiz-adv-x', - horizOriginX: 'horiz-origin-x', - ideographic: 0, - imageRendering: 'image-rendering', - 'in': 0, - in2: 0, - intercept: 0, - k: 0, - k1: 0, - k2: 0, - k3: 0, - k4: 0, - kernelMatrix: 'kernelMatrix', - kernelUnitLength: 'kernelUnitLength', - kerning: 0, - keyPoints: 'keyPoints', - keySplines: 'keySplines', - keyTimes: 'keyTimes', - lengthAdjust: 'lengthAdjust', - letterSpacing: 'letter-spacing', - lightingColor: 'lighting-color', - limitingConeAngle: 'limitingConeAngle', - local: 0, - markerEnd: 'marker-end', - markerMid: 'marker-mid', - markerStart: 'marker-start', - markerHeight: 'markerHeight', - markerUnits: 'markerUnits', - markerWidth: 'markerWidth', - mask: 0, - maskContentUnits: 'maskContentUnits', - maskUnits: 'maskUnits', - mathematical: 0, - mode: 0, - numOctaves: 'numOctaves', - offset: 0, - opacity: 0, - operator: 0, - order: 0, - orient: 0, - orientation: 0, - origin: 0, - overflow: 0, - overlinePosition: 'overline-position', - overlineThickness: 'overline-thickness', - paintOrder: 'paint-order', - panose1: 'panose-1', - pathLength: 'pathLength', - patternContentUnits: 'patternContentUnits', - patternTransform: 'patternTransform', - patternUnits: 'patternUnits', - pointerEvents: 'pointer-events', - points: 0, - pointsAtX: 'pointsAtX', - pointsAtY: 'pointsAtY', - pointsAtZ: 'pointsAtZ', - preserveAlpha: 'preserveAlpha', - preserveAspectRatio: 'preserveAspectRatio', - primitiveUnits: 'primitiveUnits', - r: 0, - radius: 0, - refX: 'refX', - refY: 'refY', - renderingIntent: 'rendering-intent', - repeatCount: 'repeatCount', - repeatDur: 'repeatDur', - requiredExtensions: 'requiredExtensions', - requiredFeatures: 'requiredFeatures', - restart: 0, - result: 0, - rotate: 0, - rx: 0, - ry: 0, - scale: 0, - seed: 0, - shapeRendering: 'shape-rendering', - slope: 0, - spacing: 0, - specularConstant: 'specularConstant', - specularExponent: 'specularExponent', - speed: 0, - spreadMethod: 'spreadMethod', - startOffset: 'startOffset', - stdDeviation: 'stdDeviation', - stemh: 0, - stemv: 0, - stitchTiles: 'stitchTiles', - stopColor: 'stop-color', - stopOpacity: 'stop-opacity', - strikethroughPosition: 'strikethrough-position', - strikethroughThickness: 'strikethrough-thickness', - string: 0, - stroke: 0, - strokeDasharray: 'stroke-dasharray', - strokeDashoffset: 'stroke-dashoffset', - strokeLinecap: 'stroke-linecap', - strokeLinejoin: 'stroke-linejoin', - strokeMiterlimit: 'stroke-miterlimit', - strokeOpacity: 'stroke-opacity', - strokeWidth: 'stroke-width', - surfaceScale: 'surfaceScale', - systemLanguage: 'systemLanguage', - tableValues: 'tableValues', - targetX: 'targetX', - targetY: 'targetY', - textAnchor: 'text-anchor', - textDecoration: 'text-decoration', - textRendering: 'text-rendering', - textLength: 'textLength', - to: 0, - transform: 0, - u1: 0, - u2: 0, - underlinePosition: 'underline-position', - underlineThickness: 'underline-thickness', - unicode: 0, - unicodeBidi: 'unicode-bidi', - unicodeRange: 'unicode-range', - unitsPerEm: 'units-per-em', - vAlphabetic: 'v-alphabetic', - vHanging: 'v-hanging', - vIdeographic: 'v-ideographic', - vMathematical: 'v-mathematical', - values: 0, - vectorEffect: 'vector-effect', - version: 0, - vertAdvY: 'vert-adv-y', - vertOriginX: 'vert-origin-x', - vertOriginY: 'vert-origin-y', - viewBox: 'viewBox', - viewTarget: 'viewTarget', - visibility: 0, - widths: 0, - wordSpacing: 'word-spacing', - writingMode: 'writing-mode', - x: 0, - xHeight: 'x-height', - x1: 0, - x2: 0, - xChannelSelector: 'xChannelSelector', - xlinkActuate: 'xlink:actuate', - xlinkArcrole: 'xlink:arcrole', - xlinkHref: 'xlink:href', - xlinkRole: 'xlink:role', - xlinkShow: 'xlink:show', - xlinkTitle: 'xlink:title', - xlinkType: 'xlink:type', - xmlBase: 'xml:base', - xmlns: 0, - xmlnsXlink: 'xmlns:xlink', - xmlLang: 'xml:lang', - xmlSpace: 'xml:space', - y: 0, - y1: 0, - y2: 0, - yChannelSelector: 'yChannelSelector', - z: 0, - zoomAndPan: 'zoomAndPan' +if (longStackTraces) Promise.longStackTraces(); + +return { + longStackTraces: function() { + return config.longStackTraces; + }, + warnings: function() { + return config.warnings; + }, + cancellation: function() { + return config.cancellation; + }, + monitoring: function() { + return config.monitoring; + }, + propagateFromFunction: function() { + return propagateFromFunction; + }, + boundValueFunction: function() { + return boundValueFunction; + }, + checkForgottenReturns: checkForgottenReturns, + setBounds: setBounds, + warn: warn, + deprecated: deprecated, + CapturedTrace: CapturedTrace, + fireDomEvent: fireDomEvent, + fireGlobalEvent: fireGlobalEvent +}; }; -var SVGDOMPropertyConfig = { - Properties: {}, - DOMAttributeNamespaces: { - xlinkActuate: NS.xlink, - xlinkArcrole: NS.xlink, - xlinkHref: NS.xlink, - xlinkRole: NS.xlink, - xlinkShow: NS.xlink, - xlinkTitle: NS.xlink, - xlinkType: NS.xlink, - xmlBase: NS.xml, - xmlLang: NS.xml, - xmlSpace: NS.xml - }, - DOMAttributeNames: {} +},{"./errors":12,"./util":36}],10:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +function returner() { + return this.value; +} +function thrower() { + throw this.reason; +} + +Promise.prototype["return"] = +Promise.prototype.thenReturn = function (value) { + if (value instanceof Promise) value.suppressUnhandledRejections(); + return this._then( + returner, undefined, undefined, {value: value}, undefined); }; -Object.keys(ATTRS).forEach(function (key) { - SVGDOMPropertyConfig.Properties[key] = 0; - if (ATTRS[key]) { - SVGDOMPropertyConfig.DOMAttributeNames[key] = ATTRS[key]; - } -}); +Promise.prototype["throw"] = +Promise.prototype.thenThrow = function (reason) { + return this._then( + thrower, undefined, undefined, {reason: reason}, undefined); +}; -module.exports = SVGDOMPropertyConfig; +Promise.prototype.catchThrow = function (reason) { + if (arguments.length <= 1) { + return this._then( + undefined, thrower, undefined, {reason: reason}, undefined); + } else { + var _reason = arguments[1]; + var handler = function() {throw _reason;}; + return this.caught(reason, handler); + } +}; -/***/ }), -/* 199 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype.catchReturn = function (value) { + if (arguments.length <= 1) { + if (value instanceof Promise) value.suppressUnhandledRejections(); + return this._then( + undefined, returner, undefined, {value: value}, undefined); + } else { + var _value = arguments[1]; + if (_value instanceof Promise) _value.suppressUnhandledRejections(); + var handler = function() {return _value;}; + return this.caught(value, handler); + } +}; +}; +},{}],11:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = function(Promise, INTERNAL) { +var PromiseReduce = Promise.reduce; +var PromiseAll = Promise.all; +function promiseAllThis() { + return PromiseAll(this); +} +function PromiseMapSeries(promises, fn) { + return PromiseReduce(promises, fn, INTERNAL, INTERNAL); +} -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInputSelection = __webpack_require__(102); -var SyntheticEvent = __webpack_require__(16); +Promise.prototype.each = function (fn) { + return PromiseReduce(this, fn, INTERNAL, 0) + ._then(promiseAllThis, undefined, undefined, this, undefined); +}; -var getActiveElement = __webpack_require__(103); -var isTextInputElement = __webpack_require__(88); -var shallowEqual = __webpack_require__(60); +Promise.prototype.mapSeries = function (fn) { + return PromiseReduce(this, fn, INTERNAL, INTERNAL); +}; -var skipSelectionChangeEvent = ExecutionEnvironment.canUseDOM && 'documentMode' in document && document.documentMode <= 11; +Promise.each = function (promises, fn) { + return PromiseReduce(promises, fn, INTERNAL, 0) + ._then(promiseAllThis, undefined, undefined, promises, undefined); +}; -var eventTypes = { - select: { - phasedRegistrationNames: { - bubbled: 'onSelect', - captured: 'onSelectCapture' - }, - dependencies: ['topBlur', 'topContextMenu', 'topFocus', 'topKeyDown', 'topKeyUp', 'topMouseDown', 'topMouseUp', 'topSelectionChange'] - } +Promise.mapSeries = PromiseMapSeries; }; -var activeElement = null; -var activeElementInst = null; -var lastSelection = null; -var mouseDown = false; -// Track whether a listener exists for this plugin. If none exist, we do -// not extract events. See #3639. -var hasListener = false; +},{}],12:[function(_dereq_,module,exports){ +"use strict"; +var es5 = _dereq_("./es5"); +var Objectfreeze = es5.freeze; +var util = _dereq_("./util"); +var inherits = util.inherits; +var notEnumerableProp = util.notEnumerableProp; + +function subError(nameProperty, defaultMessage) { + function SubError(message) { + if (!(this instanceof SubError)) return new SubError(message); + notEnumerableProp(this, "message", + typeof message === "string" ? message : defaultMessage); + notEnumerableProp(this, "name", nameProperty); + if (Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } else { + Error.call(this); + } + } + inherits(SubError, Error); + return SubError; +} -/** - * Get an object which is a unique representation of the current selection. - * - * The return value will not be consistent across nodes or browsers, but - * two identical selections on the same node will return identical objects. - * - * @param {DOMElement} node - * @return {object} - */ -function getSelection(node) { - if ('selectionStart' in node && ReactInputSelection.hasSelectionCapabilities(node)) { - return { - start: node.selectionStart, - end: node.selectionEnd +var _TypeError, _RangeError; +var Warning = subError("Warning", "warning"); +var CancellationError = subError("CancellationError", "cancellation error"); +var TimeoutError = subError("TimeoutError", "timeout error"); +var AggregateError = subError("AggregateError", "aggregate error"); +try { + _TypeError = TypeError; + _RangeError = RangeError; +} catch(e) { + _TypeError = subError("TypeError", "type error"); + _RangeError = subError("RangeError", "range error"); +} + +var methods = ("join pop push shift unshift slice filter forEach some " + + "every map indexOf lastIndexOf reduce reduceRight sort reverse").split(" "); + +for (var i = 0; i < methods.length; ++i) { + if (typeof Array.prototype[methods[i]] === "function") { + AggregateError.prototype[methods[i]] = Array.prototype[methods[i]]; + } +} + +es5.defineProperty(AggregateError.prototype, "length", { + value: 0, + configurable: false, + writable: true, + enumerable: true +}); +AggregateError.prototype["isOperational"] = true; +var level = 0; +AggregateError.prototype.toString = function() { + var indent = Array(level * 4 + 1).join(" "); + var ret = "\n" + indent + "AggregateError of:" + "\n"; + level++; + indent = Array(level * 4 + 1).join(" "); + for (var i = 0; i < this.length; ++i) { + var str = this[i] === this ? "[Circular AggregateError]" : this[i] + ""; + var lines = str.split("\n"); + for (var j = 0; j < lines.length; ++j) { + lines[j] = indent + lines[j]; + } + str = lines.join("\n"); + ret += str + "\n"; + } + level--; + return ret; +}; + +function OperationalError(message) { + if (!(this instanceof OperationalError)) + return new OperationalError(message); + notEnumerableProp(this, "name", "OperationalError"); + notEnumerableProp(this, "message", message); + this.cause = message; + this["isOperational"] = true; + + if (message instanceof Error) { + notEnumerableProp(this, "message", message.message); + notEnumerableProp(this, "stack", message.stack); + } else if (Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } + +} +inherits(OperationalError, Error); + +var errorTypes = Error["__BluebirdErrorTypes__"]; +if (!errorTypes) { + errorTypes = Objectfreeze({ + CancellationError: CancellationError, + TimeoutError: TimeoutError, + OperationalError: OperationalError, + RejectionError: OperationalError, + AggregateError: AggregateError + }); + es5.defineProperty(Error, "__BluebirdErrorTypes__", { + value: errorTypes, + writable: false, + enumerable: false, + configurable: false + }); +} + +module.exports = { + Error: Error, + TypeError: _TypeError, + RangeError: _RangeError, + CancellationError: errorTypes.CancellationError, + OperationalError: errorTypes.OperationalError, + TimeoutError: errorTypes.TimeoutError, + AggregateError: errorTypes.AggregateError, + Warning: Warning +}; + +},{"./es5":13,"./util":36}],13:[function(_dereq_,module,exports){ +var isES5 = (function(){ + "use strict"; + return this === undefined; +})(); + +if (isES5) { + module.exports = { + freeze: Object.freeze, + defineProperty: Object.defineProperty, + getDescriptor: Object.getOwnPropertyDescriptor, + keys: Object.keys, + names: Object.getOwnPropertyNames, + getPrototypeOf: Object.getPrototypeOf, + isArray: Array.isArray, + isES5: isES5, + propertyIsWritable: function(obj, prop) { + var descriptor = Object.getOwnPropertyDescriptor(obj, prop); + return !!(!descriptor || descriptor.writable || descriptor.set); + } }; - } else if (window.getSelection) { - var selection = window.getSelection(); - return { - anchorNode: selection.anchorNode, - anchorOffset: selection.anchorOffset, - focusNode: selection.focusNode, - focusOffset: selection.focusOffset +} else { + var has = {}.hasOwnProperty; + var str = {}.toString; + var proto = {}.constructor.prototype; + + var ObjectKeys = function (o) { + var ret = []; + for (var key in o) { + if (has.call(o, key)) { + ret.push(key); + } + } + return ret; }; - } else if (document.selection) { - var range = document.selection.createRange(); - return { - parentElement: range.parentElement(), - text: range.text, - top: range.boundingTop, - left: range.boundingLeft + + var ObjectGetDescriptor = function(o, key) { + return {value: o[key]}; + }; + + var ObjectDefineProperty = function (o, key, desc) { + o[key] = desc.value; + return o; + }; + + var ObjectFreeze = function (obj) { + return obj; + }; + + var ObjectGetPrototypeOf = function (obj) { + try { + return Object(obj).constructor.prototype; + } + catch (e) { + return proto; + } + }; + + var ArrayIsArray = function (obj) { + try { + return str.call(obj) === "[object Array]"; + } + catch(e) { + return false; + } + }; + + module.exports = { + isArray: ArrayIsArray, + keys: ObjectKeys, + names: ObjectKeys, + defineProperty: ObjectDefineProperty, + getDescriptor: ObjectGetDescriptor, + freeze: ObjectFreeze, + getPrototypeOf: ObjectGetPrototypeOf, + isES5: isES5, + propertyIsWritable: function() { + return true; + } }; - } } -/** - * Poll selection to see whether it's changed. - * - * @param {object} nativeEvent - * @return {?SyntheticEvent} - */ -function constructSelectEvent(nativeEvent, nativeEventTarget) { - // Ensure we have the right element, and that the user is not dragging a - // selection (this matches native `select` event behavior). In HTML5, select - // fires only on input and textarea thus if there's no focused element we - // won't dispatch. - if (mouseDown || activeElement == null || activeElement !== getActiveElement()) { - return null; - } +},{}],14:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL) { +var PromiseMap = Promise.map; - // Only fire when selection has actually changed. - var currentSelection = getSelection(activeElement); - if (!lastSelection || !shallowEqual(lastSelection, currentSelection)) { - lastSelection = currentSelection; +Promise.prototype.filter = function (fn, options) { + return PromiseMap(this, fn, options, INTERNAL); +}; - var syntheticEvent = SyntheticEvent.getPooled(eventTypes.select, activeElementInst, nativeEvent, nativeEventTarget); +Promise.filter = function (promises, fn, options) { + return PromiseMap(promises, fn, options, INTERNAL); +}; +}; - syntheticEvent.type = 'select'; - syntheticEvent.target = activeElement; +},{}],15:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, tryConvertToPromise, NEXT_FILTER) { +var util = _dereq_("./util"); +var CancellationError = Promise.CancellationError; +var errorObj = util.errorObj; +var catchFilter = _dereq_("./catch_filter")(NEXT_FILTER); + +function PassThroughHandlerContext(promise, type, handler) { + this.promise = promise; + this.type = type; + this.handler = handler; + this.called = false; + this.cancelPromise = null; +} - EventPropagators.accumulateTwoPhaseDispatches(syntheticEvent); +PassThroughHandlerContext.prototype.isFinallyHandler = function() { + return this.type === 0; +}; - return syntheticEvent; - } +function FinallyHandlerCancelReaction(finallyHandler) { + this.finallyHandler = finallyHandler; +} - return null; +FinallyHandlerCancelReaction.prototype._resultCancelled = function() { + checkCancel(this.finallyHandler); +}; + +function checkCancel(ctx, reason) { + if (ctx.cancelPromise != null) { + if (arguments.length > 1) { + ctx.cancelPromise._reject(reason); + } else { + ctx.cancelPromise._cancel(); + } + ctx.cancelPromise = null; + return true; + } + return false; } -/** - * This plugin creates an `onSelect` event that normalizes select events - * across form elements. - * - * Supported elements are: - * - input (see `isTextInputElement`) - * - textarea - * - contentEditable - * - * This differs from native browser implementations in the following ways: - * - Fires on contentEditable fields as well as inputs. - * - Fires for collapsed selection. - * - Fires after user input. - */ -var SelectEventPlugin = { - eventTypes: eventTypes, +function succeed() { + return finallyHandler.call(this, this.promise._target()._settledValue()); +} +function fail(reason) { + if (checkCancel(this, reason)) return; + errorObj.e = reason; + return errorObj; +} +function finallyHandler(reasonOrValue) { + var promise = this.promise; + var handler = this.handler; + + if (!this.called) { + this.called = true; + var ret = this.isFinallyHandler() + ? handler.call(promise._boundValue()) + : handler.call(promise._boundValue(), reasonOrValue); + if (ret === NEXT_FILTER) { + return ret; + } else if (ret !== undefined) { + promise._setReturnedNonUndefined(); + var maybePromise = tryConvertToPromise(ret, promise); + if (maybePromise instanceof Promise) { + if (this.cancelPromise != null) { + if (maybePromise._isCancelled()) { + var reason = + new CancellationError("late cancellation observer"); + promise._attachExtraTrace(reason); + errorObj.e = reason; + return errorObj; + } else if (maybePromise.isPending()) { + maybePromise._attachCancellationCallback( + new FinallyHandlerCancelReaction(this)); + } + } + return maybePromise._then( + succeed, fail, undefined, this, undefined); + } + } + } - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - if (!hasListener) { - return null; + if (promise.isRejected()) { + checkCancel(this); + errorObj.e = reasonOrValue; + return errorObj; + } else { + checkCancel(this); + return reasonOrValue; } +} - var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; +Promise.prototype._passThrough = function(handler, type, success, fail) { + if (typeof handler !== "function") return this.then(); + return this._then(success, + fail, + undefined, + new PassThroughHandlerContext(this, type, handler), + undefined); +}; - switch (topLevelType) { - // Track the input node that has focus. - case 'topFocus': - if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') { - activeElement = targetNode; - activeElementInst = targetInst; - lastSelection = null; - } - break; - case 'topBlur': - activeElement = null; - activeElementInst = null; - lastSelection = null; - break; - // Don't fire the event while the user is dragging. This matches the - // semantics of the native select event. - case 'topMouseDown': - mouseDown = true; - break; - case 'topContextMenu': - case 'topMouseUp': - mouseDown = false; - return constructSelectEvent(nativeEvent, nativeEventTarget); - // Chrome and IE fire non-standard event when selection is changed (and - // sometimes when it hasn't). IE's event fires out of order with respect - // to key and input events on deletion, so we discard it. - // - // Firefox doesn't support selectionchange, so check selection status - // after each key entry. The selection changes after keydown and before - // keyup, but we check on keydown as well in the case of holding down a - // key, when multiple keydown events are fired but only one keyup is. - // This is also our approach for IE handling, for the reason above. - case 'topSelectionChange': - if (skipSelectionChangeEvent) { - break; +Promise.prototype.lastly = +Promise.prototype["finally"] = function (handler) { + return this._passThrough(handler, + 0, + finallyHandler, + finallyHandler); +}; + + +Promise.prototype.tap = function (handler) { + return this._passThrough(handler, 1, finallyHandler); +}; + +Promise.prototype.tapCatch = function (handlerOrPredicate) { + var len = arguments.length; + if(len === 1) { + return this._passThrough(handlerOrPredicate, + 1, + undefined, + finallyHandler); + } else { + var catchInstances = new Array(len - 1), + j = 0, i; + for (i = 0; i < len - 1; ++i) { + var item = arguments[i]; + if (util.isObject(item)) { + catchInstances[j++] = item; + } else { + return Promise.reject(new TypeError( + "tapCatch statement predicate: " + + "expecting an object but got " + util.classString(item) + )); + } } - // falls through - case 'topKeyDown': - case 'topKeyUp': - return constructSelectEvent(nativeEvent, nativeEventTarget); + catchInstances.length = j; + var handler = arguments[i]; + return this._passThrough(catchFilter(catchInstances, handler, this), + 1, + undefined, + finallyHandler); } +}; + +return PassThroughHandlerContext; +}; + +},{"./catch_filter":7,"./util":36}],16:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, + apiRejection, + INTERNAL, + tryConvertToPromise, + Proxyable, + debug) { +var errors = _dereq_("./errors"); +var TypeError = errors.TypeError; +var util = _dereq_("./util"); +var errorObj = util.errorObj; +var tryCatch = util.tryCatch; +var yieldHandlers = []; + +function promiseFromYieldHandler(value, yieldHandlers, traceParent) { + for (var i = 0; i < yieldHandlers.length; ++i) { + traceParent._pushContext(); + var result = tryCatch(yieldHandlers[i])(value); + traceParent._popContext(); + if (result === errorObj) { + traceParent._pushContext(); + var ret = Promise.reject(errorObj.e); + traceParent._popContext(); + return ret; + } + var maybePromise = tryConvertToPromise(result, traceParent); + if (maybePromise instanceof Promise) return maybePromise; + } return null; - }, +} - didPutListener: function (inst, registrationName, listener) { - if (registrationName === 'onSelect') { - hasListener = true; +function PromiseSpawn(generatorFunction, receiver, yieldHandler, stack) { + if (debug.cancellation()) { + var internal = new Promise(INTERNAL); + var _finallyPromise = this._finallyPromise = new Promise(INTERNAL); + this._promise = internal.lastly(function() { + return _finallyPromise; + }); + internal._captureStackTrace(); + internal._setOnCancel(this); + } else { + var promise = this._promise = new Promise(INTERNAL); + promise._captureStackTrace(); + } + this._stack = stack; + this._generatorFunction = generatorFunction; + this._receiver = receiver; + this._generator = undefined; + this._yieldHandlers = typeof yieldHandler === "function" + ? [yieldHandler].concat(yieldHandlers) + : yieldHandlers; + this._yieldedPromise = null; + this._cancellationPhase = false; +} +util.inherits(PromiseSpawn, Proxyable); + +PromiseSpawn.prototype._isResolved = function() { + return this._promise === null; +}; + +PromiseSpawn.prototype._cleanup = function() { + this._promise = this._generator = null; + if (debug.cancellation() && this._finallyPromise !== null) { + this._finallyPromise._fulfill(); + this._finallyPromise = null; } - } }; -module.exports = SelectEventPlugin; +PromiseSpawn.prototype._promiseCancelled = function() { + if (this._isResolved()) return; + var implementsReturn = typeof this._generator["return"] !== "undefined"; + + var result; + if (!implementsReturn) { + var reason = new Promise.CancellationError( + "generator .return() sentinel"); + Promise.coroutine.returnSentinel = reason; + this._promise._attachExtraTrace(reason); + this._promise._pushContext(); + result = tryCatch(this._generator["throw"]).call(this._generator, + reason); + this._promise._popContext(); + } else { + this._promise._pushContext(); + result = tryCatch(this._generator["return"]).call(this._generator, + undefined); + this._promise._popContext(); + } + this._cancellationPhase = true; + this._yieldedPromise = null; + this._continue(result); +}; -/***/ }), -/* 200 */ -/***/ (function(module, exports, __webpack_require__) { +PromiseSpawn.prototype._promiseFulfilled = function(value) { + this._yieldedPromise = null; + this._promise._pushContext(); + var result = tryCatch(this._generator.next).call(this._generator, value); + this._promise._popContext(); + this._continue(result); +}; + +PromiseSpawn.prototype._promiseRejected = function(reason) { + this._yieldedPromise = null; + this._promise._attachExtraTrace(reason); + this._promise._pushContext(); + var result = tryCatch(this._generator["throw"]) + .call(this._generator, reason); + this._promise._popContext(); + this._continue(result); +}; + +PromiseSpawn.prototype._resultCancelled = function() { + if (this._yieldedPromise instanceof Promise) { + var promise = this._yieldedPromise; + this._yieldedPromise = null; + promise.cancel(); + } +}; + +PromiseSpawn.prototype.promise = function () { + return this._promise; +}; + +PromiseSpawn.prototype._run = function () { + this._generator = this._generatorFunction.call(this._receiver); + this._receiver = + this._generatorFunction = undefined; + this._promiseFulfilled(undefined); +}; + +PromiseSpawn.prototype._continue = function (result) { + var promise = this._promise; + if (result === errorObj) { + this._cleanup(); + if (this._cancellationPhase) { + return promise.cancel(); + } else { + return promise._rejectCallback(result.e, false); + } + } + + var value = result.value; + if (result.done === true) { + this._cleanup(); + if (this._cancellationPhase) { + return promise.cancel(); + } else { + return promise._resolveCallback(value); + } + } else { + var maybePromise = tryConvertToPromise(value, this._promise); + if (!(maybePromise instanceof Promise)) { + maybePromise = + promiseFromYieldHandler(maybePromise, + this._yieldHandlers, + this._promise); + if (maybePromise === null) { + this._promiseRejected( + new TypeError( + "A value %s was yielded that could not be treated as a promise\u000a\u000a See http://goo.gl/MqrFmX\u000a\u000a".replace("%s", String(value)) + + "From coroutine:\u000a" + + this._stack.split("\n").slice(1, -7).join("\n") + ) + ); + return; + } + } + maybePromise = maybePromise._target(); + var bitField = maybePromise._bitField; + ; + if (((bitField & 50397184) === 0)) { + this._yieldedPromise = maybePromise; + maybePromise._proxy(this, null); + } else if (((bitField & 33554432) !== 0)) { + Promise._async.invoke( + this._promiseFulfilled, this, maybePromise._value() + ); + } else if (((bitField & 16777216) !== 0)) { + Promise._async.invoke( + this._promiseRejected, this, maybePromise._reason() + ); + } else { + this._promiseCancelled(); + } + } +}; + +Promise.coroutine = function (generatorFunction, options) { + if (typeof generatorFunction !== "function") { + throw new TypeError("generatorFunction must be a function\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + var yieldHandler = Object(options).yieldHandler; + var PromiseSpawn$ = PromiseSpawn; + var stack = new Error().stack; + return function () { + var generator = generatorFunction.apply(this, arguments); + var spawn = new PromiseSpawn$(undefined, undefined, yieldHandler, + stack); + var ret = spawn.promise(); + spawn._generator = generator; + spawn._promiseFulfilled(undefined); + return ret; + }; +}; + +Promise.coroutine.addYieldHandler = function(fn) { + if (typeof fn !== "function") { + throw new TypeError("expecting a function but got " + util.classString(fn)); + } + yieldHandlers.push(fn); +}; + +Promise.spawn = function (generatorFunction) { + debug.deprecated("Promise.spawn()", "Promise.coroutine()"); + if (typeof generatorFunction !== "function") { + return apiRejection("generatorFunction must be a function\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + var spawn = new PromiseSpawn(generatorFunction, this); + var ret = spawn.promise(); + spawn._run(Promise.spawn); + return ret; +}; +}; +},{"./errors":12,"./util":36}],17:[function(_dereq_,module,exports){ "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +module.exports = +function(Promise, PromiseArray, tryConvertToPromise, INTERNAL, async, + getDomain) { +var util = _dereq_("./util"); +var canEvaluate = util.canEvaluate; +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; +var reject; + +if (false) { +if (canEvaluate) { + var thenCallback = function(i) { + return new Function("value", "holder", " \n\ + 'use strict'; \n\ + holder.pIndex = value; \n\ + holder.checkFulfillment(this); \n\ + ".replace(/Index/g, i)); + }; + var promiseSetter = function(i) { + return new Function("promise", "holder", " \n\ + 'use strict'; \n\ + holder.pIndex = promise; \n\ + ".replace(/Index/g, i)); + }; + var generateHolderClass = function(total) { + var props = new Array(total); + for (var i = 0; i < props.length; ++i) { + props[i] = "this.p" + (i+1); + } + var assignment = props.join(" = ") + " = null;"; + var cancellationCode= "var promise;\n" + props.map(function(prop) { + return " \n\ + promise = " + prop + "; \n\ + if (promise instanceof Promise) { \n\ + promise.cancel(); \n\ + } \n\ + "; + }).join("\n"); + var passedArguments = props.join(", "); + var name = "Holder$" + total; + + + var code = "return function(tryCatch, errorObj, Promise, async) { \n\ + 'use strict'; \n\ + function [TheName](fn) { \n\ + [TheProperties] \n\ + this.fn = fn; \n\ + this.asyncNeeded = true; \n\ + this.now = 0; \n\ + } \n\ + \n\ + [TheName].prototype._callFunction = function(promise) { \n\ + promise._pushContext(); \n\ + var ret = tryCatch(this.fn)([ThePassedArguments]); \n\ + promise._popContext(); \n\ + if (ret === errorObj) { \n\ + promise._rejectCallback(ret.e, false); \n\ + } else { \n\ + promise._resolveCallback(ret); \n\ + } \n\ + }; \n\ + \n\ + [TheName].prototype.checkFulfillment = function(promise) { \n\ + var now = ++this.now; \n\ + if (now === [TheTotal]) { \n\ + if (this.asyncNeeded) { \n\ + async.invoke(this._callFunction, this, promise); \n\ + } else { \n\ + this._callFunction(promise); \n\ + } \n\ + \n\ + } \n\ + }; \n\ + \n\ + [TheName].prototype._resultCancelled = function() { \n\ + [CancellationCode] \n\ + }; \n\ + \n\ + return [TheName]; \n\ + }(tryCatch, errorObj, Promise, async); \n\ + "; + + code = code.replace(/\[TheName\]/g, name) + .replace(/\[TheTotal\]/g, total) + .replace(/\[ThePassedArguments\]/g, passedArguments) + .replace(/\[TheProperties\]/g, assignment) + .replace(/\[CancellationCode\]/g, cancellationCode); + + return new Function("tryCatch", "errorObj", "Promise", "async", code) + (tryCatch, errorObj, Promise, async); + }; -var _prodInvariant = __webpack_require__(3); + var holderClasses = []; + var thenCallbacks = []; + var promiseSetters = []; -var EventListener = __webpack_require__(101); -var EventPropagators = __webpack_require__(31); -var ReactDOMComponentTree = __webpack_require__(6); -var SyntheticAnimationEvent = __webpack_require__(201); -var SyntheticClipboardEvent = __webpack_require__(202); -var SyntheticEvent = __webpack_require__(16); -var SyntheticFocusEvent = __webpack_require__(203); -var SyntheticKeyboardEvent = __webpack_require__(204); -var SyntheticMouseEvent = __webpack_require__(42); -var SyntheticDragEvent = __webpack_require__(206); -var SyntheticTouchEvent = __webpack_require__(207); -var SyntheticTransitionEvent = __webpack_require__(208); -var SyntheticUIEvent = __webpack_require__(33); -var SyntheticWheelEvent = __webpack_require__(209); + for (var i = 0; i < 8; ++i) { + holderClasses.push(generateHolderClass(i + 1)); + thenCallbacks.push(thenCallback(i + 1)); + promiseSetters.push(promiseSetter(i + 1)); + } -var emptyFunction = __webpack_require__(12); -var getEventCharCode = __webpack_require__(65); -var invariant = __webpack_require__(1); + reject = function (reason) { + this._reject(reason); + }; +}} + +Promise.join = function () { + var last = arguments.length - 1; + var fn; + if (last > 0 && typeof arguments[last] === "function") { + fn = arguments[last]; + if (false) { + if (last <= 8 && canEvaluate) { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + var HolderClass = holderClasses[last - 1]; + var holder = new HolderClass(fn); + var callbacks = thenCallbacks; + + for (var i = 0; i < last; ++i) { + var maybePromise = tryConvertToPromise(arguments[i], ret); + if (maybePromise instanceof Promise) { + maybePromise = maybePromise._target(); + var bitField = maybePromise._bitField; + ; + if (((bitField & 50397184) === 0)) { + maybePromise._then(callbacks[i], reject, + undefined, ret, holder); + promiseSetters[i](maybePromise, holder); + holder.asyncNeeded = false; + } else if (((bitField & 33554432) !== 0)) { + callbacks[i].call(ret, + maybePromise._value(), holder); + } else if (((bitField & 16777216) !== 0)) { + ret._reject(maybePromise._reason()); + } else { + ret._cancel(); + } + } else { + callbacks[i].call(ret, maybePromise, holder); + } + } -/** - * Turns - * ['abort', ...] - * into - * eventTypes = { - * 'abort': { - * phasedRegistrationNames: { - * bubbled: 'onAbort', - * captured: 'onAbortCapture', - * }, - * dependencies: ['topAbort'], - * }, - * ... - * }; - * topLevelEventsToDispatchConfig = { - * 'topAbort': { sameConfig } - * }; - */ -var eventTypes = {}; -var topLevelEventsToDispatchConfig = {}; -['abort', 'animationEnd', 'animationIteration', 'animationStart', 'blur', 'canPlay', 'canPlayThrough', 'click', 'contextMenu', 'copy', 'cut', 'doubleClick', 'drag', 'dragEnd', 'dragEnter', 'dragExit', 'dragLeave', 'dragOver', 'dragStart', 'drop', 'durationChange', 'emptied', 'encrypted', 'ended', 'error', 'focus', 'input', 'invalid', 'keyDown', 'keyPress', 'keyUp', 'load', 'loadedData', 'loadedMetadata', 'loadStart', 'mouseDown', 'mouseMove', 'mouseOut', 'mouseOver', 'mouseUp', 'paste', 'pause', 'play', 'playing', 'progress', 'rateChange', 'reset', 'scroll', 'seeked', 'seeking', 'stalled', 'submit', 'suspend', 'timeUpdate', 'touchCancel', 'touchEnd', 'touchMove', 'touchStart', 'transitionEnd', 'volumeChange', 'waiting', 'wheel'].forEach(function (event) { - var capitalizedEvent = event[0].toUpperCase() + event.slice(1); - var onEvent = 'on' + capitalizedEvent; - var topEvent = 'top' + capitalizedEvent; + if (!ret._isFateSealed()) { + if (holder.asyncNeeded) { + var domain = getDomain(); + if (domain !== null) { + holder.fn = util.domainBind(domain, holder.fn); + } + } + ret._setAsyncGuaranteed(); + ret._setOnCancel(holder); + } + return ret; + } + } + } + var args = [].slice.call(arguments);; + if (fn) args.pop(); + var ret = new PromiseArray(args).promise(); + return fn !== undefined ? ret.spread(fn) : ret; +}; - var type = { - phasedRegistrationNames: { - bubbled: onEvent, - captured: onEvent + 'Capture' - }, - dependencies: [topEvent] - }; - eventTypes[event] = type; - topLevelEventsToDispatchConfig[topEvent] = type; -}); +}; -var onClickListeners = {}; +},{"./util":36}],18:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, + PromiseArray, + apiRejection, + tryConvertToPromise, + INTERNAL, + debug) { +var getDomain = Promise._getDomain; +var util = _dereq_("./util"); +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; +var async = Promise._async; + +function MappingPromiseArray(promises, fn, limit, _filter) { + this.constructor$(promises); + this._promise._captureStackTrace(); + var domain = getDomain(); + this._callback = domain === null ? fn : util.domainBind(domain, fn); + this._preservedValues = _filter === INTERNAL + ? new Array(this.length()) + : null; + this._limit = limit; + this._inFlight = 0; + this._queue = []; + async.invoke(this._asyncInit, this, undefined); +} +util.inherits(MappingPromiseArray, PromiseArray); + +MappingPromiseArray.prototype._asyncInit = function() { + this._init$(undefined, -2); +}; + +MappingPromiseArray.prototype._init = function () {}; + +MappingPromiseArray.prototype._promiseFulfilled = function (value, index) { + var values = this._values; + var length = this.length(); + var preservedValues = this._preservedValues; + var limit = this._limit; + + if (index < 0) { + index = (index * -1) - 1; + values[index] = value; + if (limit >= 1) { + this._inFlight--; + this._drainQueue(); + if (this._isResolved()) return true; + } + } else { + if (limit >= 1 && this._inFlight >= limit) { + values[index] = value; + this._queue.push(index); + return false; + } + if (preservedValues !== null) preservedValues[index] = value; + + var promise = this._promise; + var callback = this._callback; + var receiver = promise._boundValue(); + promise._pushContext(); + var ret = tryCatch(callback).call(receiver, value, index, length); + var promiseCreated = promise._popContext(); + debug.checkForgottenReturns( + ret, + promiseCreated, + preservedValues !== null ? "Promise.filter" : "Promise.map", + promise + ); + if (ret === errorObj) { + this._reject(ret.e); + return true; + } + + var maybePromise = tryConvertToPromise(ret, this._promise); + if (maybePromise instanceof Promise) { + maybePromise = maybePromise._target(); + var bitField = maybePromise._bitField; + ; + if (((bitField & 50397184) === 0)) { + if (limit >= 1) this._inFlight++; + values[index] = maybePromise; + maybePromise._proxy(this, (index + 1) * -1); + return false; + } else if (((bitField & 33554432) !== 0)) { + ret = maybePromise._value(); + } else if (((bitField & 16777216) !== 0)) { + this._reject(maybePromise._reason()); + return true; + } else { + this._cancel(); + return true; + } + } + values[index] = ret; + } + var totalResolved = ++this._totalResolved; + if (totalResolved >= length) { + if (preservedValues !== null) { + this._filter(values, preservedValues); + } else { + this._resolve(values); + } + return true; + } + return false; +}; + +MappingPromiseArray.prototype._drainQueue = function () { + var queue = this._queue; + var limit = this._limit; + var values = this._values; + while (queue.length > 0 && this._inFlight < limit) { + if (this._isResolved()) return; + var index = queue.pop(); + this._promiseFulfilled(values[index], index); + } +}; + +MappingPromiseArray.prototype._filter = function (booleans, values) { + var len = values.length; + var ret = new Array(len); + var j = 0; + for (var i = 0; i < len; ++i) { + if (booleans[i]) ret[j++] = values[i]; + } + ret.length = j; + this._resolve(ret); +}; + +MappingPromiseArray.prototype.preservedValues = function () { + return this._preservedValues; +}; + +function map(promises, fn, options, _filter) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + + var limit = 0; + if (options !== undefined) { + if (typeof options === "object" && options !== null) { + if (typeof options.concurrency !== "number") { + return Promise.reject( + new TypeError("'concurrency' must be a number but it is " + + util.classString(options.concurrency))); + } + limit = options.concurrency; + } else { + return Promise.reject(new TypeError( + "options argument must be an object but it is " + + util.classString(options))); + } + } + limit = typeof limit === "number" && + isFinite(limit) && limit >= 1 ? limit : 0; + return new MappingPromiseArray(promises, fn, limit, _filter).promise(); +} + +Promise.prototype.map = function (fn, options) { + return map(this, fn, options, null); +}; + +Promise.map = function (promises, fn, options, _filter) { + return map(promises, fn, options, _filter); +}; + + +}; + +},{"./util":36}],19:[function(_dereq_,module,exports){ +"use strict"; +module.exports = +function(Promise, INTERNAL, tryConvertToPromise, apiRejection, debug) { +var util = _dereq_("./util"); +var tryCatch = util.tryCatch; + +Promise.method = function (fn) { + if (typeof fn !== "function") { + throw new Promise.TypeError("expecting a function but got " + util.classString(fn)); + } + return function () { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._pushContext(); + var value = tryCatch(fn).apply(this, arguments); + var promiseCreated = ret._popContext(); + debug.checkForgottenReturns( + value, promiseCreated, "Promise.method", ret); + ret._resolveFromSyncValue(value); + return ret; + }; +}; + +Promise.attempt = Promise["try"] = function (fn) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._pushContext(); + var value; + if (arguments.length > 1) { + debug.deprecated("calling Promise.try with more than 1 argument"); + var arg = arguments[1]; + var ctx = arguments[2]; + value = util.isArray(arg) ? tryCatch(fn).apply(ctx, arg) + : tryCatch(fn).call(ctx, arg); + } else { + value = tryCatch(fn)(); + } + var promiseCreated = ret._popContext(); + debug.checkForgottenReturns( + value, promiseCreated, "Promise.try", ret); + ret._resolveFromSyncValue(value); + return ret; +}; + +Promise.prototype._resolveFromSyncValue = function (value) { + if (value === util.errorObj) { + this._rejectCallback(value.e, false); + } else { + this._resolveCallback(value, true); + } +}; +}; + +},{"./util":36}],20:[function(_dereq_,module,exports){ +"use strict"; +var util = _dereq_("./util"); +var maybeWrapAsError = util.maybeWrapAsError; +var errors = _dereq_("./errors"); +var OperationalError = errors.OperationalError; +var es5 = _dereq_("./es5"); + +function isUntypedError(obj) { + return obj instanceof Error && + es5.getPrototypeOf(obj) === Error.prototype; +} + +var rErrorKey = /^(?:name|message|stack|cause)$/; +function wrapAsOperationalError(obj) { + var ret; + if (isUntypedError(obj)) { + ret = new OperationalError(obj); + ret.name = obj.name; + ret.message = obj.message; + ret.stack = obj.stack; + var keys = es5.keys(obj); + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + if (!rErrorKey.test(key)) { + ret[key] = obj[key]; + } + } + return ret; + } + util.markAsOriginatingFromRejection(obj); + return obj; +} + +function nodebackForPromise(promise, multiArgs) { + return function(err, value) { + if (promise === null) return; + if (err) { + var wrapped = wrapAsOperationalError(maybeWrapAsError(err)); + promise._attachExtraTrace(wrapped); + promise._reject(wrapped); + } else if (!multiArgs) { + promise._fulfill(value); + } else { + var args = [].slice.call(arguments, 1);; + promise._fulfill(args); + } + promise = null; + }; +} + +module.exports = nodebackForPromise; + +},{"./errors":12,"./es5":13,"./util":36}],21:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise) { +var util = _dereq_("./util"); +var async = Promise._async; +var tryCatch = util.tryCatch; +var errorObj = util.errorObj; + +function spreadAdapter(val, nodeback) { + var promise = this; + if (!util.isArray(val)) return successAdapter.call(promise, val, nodeback); + var ret = + tryCatch(nodeback).apply(promise._boundValue(), [null].concat(val)); + if (ret === errorObj) { + async.throwLater(ret.e); + } +} + +function successAdapter(val, nodeback) { + var promise = this; + var receiver = promise._boundValue(); + var ret = val === undefined + ? tryCatch(nodeback).call(receiver, null) + : tryCatch(nodeback).call(receiver, null, val); + if (ret === errorObj) { + async.throwLater(ret.e); + } +} +function errorAdapter(reason, nodeback) { + var promise = this; + if (!reason) { + var newReason = new Error(reason + ""); + newReason.cause = reason; + reason = newReason; + } + var ret = tryCatch(nodeback).call(promise._boundValue(), reason); + if (ret === errorObj) { + async.throwLater(ret.e); + } +} + +Promise.prototype.asCallback = Promise.prototype.nodeify = function (nodeback, + options) { + if (typeof nodeback == "function") { + var adapter = successAdapter; + if (options !== undefined && Object(options).spread) { + adapter = spreadAdapter; + } + this._then( + adapter, + errorAdapter, + undefined, + this, + nodeback + ); + } + return this; +}; +}; + +},{"./util":36}],22:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function() { +var makeSelfResolutionError = function () { + return new TypeError("circular promise resolution chain\u000a\u000a See http://goo.gl/MqrFmX\u000a"); +}; +var reflectHandler = function() { + return new Promise.PromiseInspection(this._target()); +}; +var apiRejection = function(msg) { + return Promise.reject(new TypeError(msg)); +}; +function Proxyable() {} +var UNDEFINED_BINDING = {}; +var util = _dereq_("./util"); + +var getDomain; +if (util.isNode) { + getDomain = function() { + var ret = process.domain; + if (ret === undefined) ret = null; + return ret; + }; +} else { + getDomain = function() { + return null; + }; +} +util.notEnumerableProp(Promise, "_getDomain", getDomain); + +var es5 = _dereq_("./es5"); +var Async = _dereq_("./async"); +var async = new Async(); +es5.defineProperty(Promise, "_async", {value: async}); +var errors = _dereq_("./errors"); +var TypeError = Promise.TypeError = errors.TypeError; +Promise.RangeError = errors.RangeError; +var CancellationError = Promise.CancellationError = errors.CancellationError; +Promise.TimeoutError = errors.TimeoutError; +Promise.OperationalError = errors.OperationalError; +Promise.RejectionError = errors.OperationalError; +Promise.AggregateError = errors.AggregateError; +var INTERNAL = function(){}; +var APPLY = {}; +var NEXT_FILTER = {}; +var tryConvertToPromise = _dereq_("./thenables")(Promise, INTERNAL); +var PromiseArray = + _dereq_("./promise_array")(Promise, INTERNAL, + tryConvertToPromise, apiRejection, Proxyable); +var Context = _dereq_("./context")(Promise); + /*jshint unused:false*/ +var createContext = Context.create; +var debug = _dereq_("./debuggability")(Promise, Context); +var CapturedTrace = debug.CapturedTrace; +var PassThroughHandlerContext = + _dereq_("./finally")(Promise, tryConvertToPromise, NEXT_FILTER); +var catchFilter = _dereq_("./catch_filter")(NEXT_FILTER); +var nodebackForPromise = _dereq_("./nodeback"); +var errorObj = util.errorObj; +var tryCatch = util.tryCatch; +function check(self, executor) { + if (self == null || self.constructor !== Promise) { + throw new TypeError("the promise constructor cannot be invoked directly\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + if (typeof executor !== "function") { + throw new TypeError("expecting a function but got " + util.classString(executor)); + } -function getDictionaryKey(inst) { - // Prevents V8 performance issue: - // https://github.com/facebook/react/pull/7232 - return '.' + inst._rootNodeID; } -function isInteractive(tag) { - return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; -} +function Promise(executor) { + if (executor !== INTERNAL) { + check(this, executor); + } + this._bitField = 0; + this._fulfillmentHandler0 = undefined; + this._rejectionHandler0 = undefined; + this._promise0 = undefined; + this._receiver0 = undefined; + this._resolveFromExecutor(executor); + this._promiseCreated(); + this._fireEvent("promiseCreated", this); +} + +Promise.prototype.toString = function () { + return "[object Promise]"; +}; + +Promise.prototype.caught = Promise.prototype["catch"] = function (fn) { + var len = arguments.length; + if (len > 1) { + var catchInstances = new Array(len - 1), + j = 0, i; + for (i = 0; i < len - 1; ++i) { + var item = arguments[i]; + if (util.isObject(item)) { + catchInstances[j++] = item; + } else { + return apiRejection("Catch statement predicate: " + + "expecting an object but got " + util.classString(item)); + } + } + catchInstances.length = j; + fn = arguments[i]; + return this.then(undefined, catchFilter(catchInstances, fn, this)); + } + return this.then(undefined, fn); +}; + +Promise.prototype.reflect = function () { + return this._then(reflectHandler, + reflectHandler, undefined, this, undefined); +}; + +Promise.prototype.then = function (didFulfill, didReject) { + if (debug.warnings() && arguments.length > 0 && + typeof didFulfill !== "function" && + typeof didReject !== "function") { + var msg = ".then() only accepts functions but was passed: " + + util.classString(didFulfill); + if (arguments.length > 1) { + msg += ", " + util.classString(didReject); + } + this._warn(msg); + } + return this._then(didFulfill, didReject, undefined, undefined, undefined); +}; + +Promise.prototype.done = function (didFulfill, didReject) { + var promise = + this._then(didFulfill, didReject, undefined, undefined, undefined); + promise._setIsFinal(); +}; -var SimpleEventPlugin = { - eventTypes: eventTypes, +Promise.prototype.spread = function (fn) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + return this.all()._then(fn, undefined, undefined, APPLY, undefined); +}; - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var dispatchConfig = topLevelEventsToDispatchConfig[topLevelType]; - if (!dispatchConfig) { - return null; +Promise.prototype.toJSON = function () { + var ret = { + isFulfilled: false, + isRejected: false, + fulfillmentValue: undefined, + rejectionReason: undefined + }; + if (this.isFulfilled()) { + ret.fulfillmentValue = this.value(); + ret.isFulfilled = true; + } else if (this.isRejected()) { + ret.rejectionReason = this.reason(); + ret.isRejected = true; } - var EventConstructor; - switch (topLevelType) { - case 'topAbort': - case 'topCanPlay': - case 'topCanPlayThrough': - case 'topDurationChange': - case 'topEmptied': - case 'topEncrypted': - case 'topEnded': - case 'topError': - case 'topInput': - case 'topInvalid': - case 'topLoad': - case 'topLoadedData': - case 'topLoadedMetadata': - case 'topLoadStart': - case 'topPause': - case 'topPlay': - case 'topPlaying': - case 'topProgress': - case 'topRateChange': - case 'topReset': - case 'topSeeked': - case 'topSeeking': - case 'topStalled': - case 'topSubmit': - case 'topSuspend': - case 'topTimeUpdate': - case 'topVolumeChange': - case 'topWaiting': - // HTML Events - // @see http://www.w3.org/TR/html5/index.html#events-0 - EventConstructor = SyntheticEvent; - break; - case 'topKeyPress': - // Firefox creates a keypress event for function keys too. This removes - // the unwanted keypress events. Enter is however both printable and - // non-printable. One would expect Tab to be as well (but it isn't). - if (getEventCharCode(nativeEvent) === 0) { - return null; - } - /* falls through */ - case 'topKeyDown': - case 'topKeyUp': - EventConstructor = SyntheticKeyboardEvent; - break; - case 'topBlur': - case 'topFocus': - EventConstructor = SyntheticFocusEvent; - break; - case 'topClick': - // Firefox creates a click event on right mouse clicks. This removes the - // unwanted click events. - if (nativeEvent.button === 2) { - return null; - } - /* falls through */ - case 'topDoubleClick': - case 'topMouseDown': - case 'topMouseMove': - case 'topMouseUp': - // TODO: Disabled elements should not respond to mouse events - /* falls through */ - case 'topMouseOut': - case 'topMouseOver': - case 'topContextMenu': - EventConstructor = SyntheticMouseEvent; - break; - case 'topDrag': - case 'topDragEnd': - case 'topDragEnter': - case 'topDragExit': - case 'topDragLeave': - case 'topDragOver': - case 'topDragStart': - case 'topDrop': - EventConstructor = SyntheticDragEvent; - break; - case 'topTouchCancel': - case 'topTouchEnd': - case 'topTouchMove': - case 'topTouchStart': - EventConstructor = SyntheticTouchEvent; - break; - case 'topAnimationEnd': - case 'topAnimationIteration': - case 'topAnimationStart': - EventConstructor = SyntheticAnimationEvent; - break; - case 'topTransitionEnd': - EventConstructor = SyntheticTransitionEvent; - break; - case 'topScroll': - EventConstructor = SyntheticUIEvent; - break; - case 'topWheel': - EventConstructor = SyntheticWheelEvent; - break; - case 'topCopy': - case 'topCut': - case 'topPaste': - EventConstructor = SyntheticClipboardEvent; - break; + return ret; +}; + +Promise.prototype.all = function () { + if (arguments.length > 0) { + this._warn(".all() was passed arguments but it does not take any"); } - !EventConstructor ? process.env.NODE_ENV !== 'production' ? invariant(false, 'SimpleEventPlugin: Unhandled event type, `%s`.', topLevelType) : _prodInvariant('86', topLevelType) : void 0; - var event = EventConstructor.getPooled(dispatchConfig, targetInst, nativeEvent, nativeEventTarget); - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; - }, + return new PromiseArray(this).promise(); +}; - didPutListener: function (inst, registrationName, listener) { - // Mobile Safari does not fire properly bubble click events on - // non-interactive elements, which means delegated click listeners do not - // fire. The workaround for this bug involves attaching an empty click - // listener on the target node. - // http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html - if (registrationName === 'onClick' && !isInteractive(inst._tag)) { - var key = getDictionaryKey(inst); - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - if (!onClickListeners[key]) { - onClickListeners[key] = EventListener.listen(node, 'click', emptyFunction); - } +Promise.prototype.error = function (fn) { + return this.caught(util.originatesFromRejection, fn); +}; + +Promise.getNewLibraryCopy = module.exports; + +Promise.is = function (val) { + return val instanceof Promise; +}; + +Promise.fromNode = Promise.fromCallback = function(fn) { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + var multiArgs = arguments.length > 1 ? !!Object(arguments[1]).multiArgs + : false; + var result = tryCatch(fn)(nodebackForPromise(ret, multiArgs)); + if (result === errorObj) { + ret._rejectCallback(result.e, true); } - }, + if (!ret._isFateSealed()) ret._setAsyncGuaranteed(); + return ret; +}; - willDeleteListener: function (inst, registrationName) { - if (registrationName === 'onClick' && !isInteractive(inst._tag)) { - var key = getDictionaryKey(inst); - onClickListeners[key].remove(); - delete onClickListeners[key]; +Promise.all = function (promises) { + return new PromiseArray(promises).promise(); +}; + +Promise.cast = function (obj) { + var ret = tryConvertToPromise(obj); + if (!(ret instanceof Promise)) { + ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._setFulfilled(); + ret._rejectionHandler0 = obj; } - } + return ret; }; -module.exports = SimpleEventPlugin; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Promise.resolve = Promise.fulfilled = Promise.cast; -/***/ }), -/* 201 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.reject = Promise.rejected = function (reason) { + var ret = new Promise(INTERNAL); + ret._captureStackTrace(); + ret._rejectCallback(reason, true); + return ret; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.setScheduler = function(fn) { + if (typeof fn !== "function") { + throw new TypeError("expecting a function but got " + util.classString(fn)); + } + return async.setScheduler(fn); +}; +Promise.prototype._then = function ( + didFulfill, + didReject, + _, receiver, + internalData +) { + var haveInternalData = internalData !== undefined; + var promise = haveInternalData ? internalData : new Promise(INTERNAL); + var target = this._target(); + var bitField = target._bitField; + + if (!haveInternalData) { + promise._propagateFrom(this, 3); + promise._captureStackTrace(); + if (receiver === undefined && + ((this._bitField & 2097152) !== 0)) { + if (!((bitField & 50397184) === 0)) { + receiver = this._boundValue(); + } else { + receiver = target === this ? undefined : this._boundTo; + } + } + this._fireEvent("promiseChained", this, promise); + } + + var domain = getDomain(); + if (!((bitField & 50397184) === 0)) { + var handler, value, settler = target._settlePromiseCtx; + if (((bitField & 33554432) !== 0)) { + value = target._rejectionHandler0; + handler = didFulfill; + } else if (((bitField & 16777216) !== 0)) { + value = target._fulfillmentHandler0; + handler = didReject; + target._unsetRejectionIsUnhandled(); + } else { + settler = target._settlePromiseLateCancellationObserver; + value = new CancellationError("late cancellation observer"); + target._attachExtraTrace(value); + handler = didReject; + } + async.invoke(settler, target, { + handler: domain === null ? handler + : (typeof handler === "function" && + util.domainBind(domain, handler)), + promise: promise, + receiver: receiver, + value: value + }); + } else { + target._addCallbacks(didFulfill, didReject, promise, receiver, domain); + } -var SyntheticEvent = __webpack_require__(16); + return promise; +}; -/** - * @interface Event - * @see http://www.w3.org/TR/css3-animations/#AnimationEvent-interface - * @see https://developer.mozilla.org/en-US/docs/Web/API/AnimationEvent - */ -var AnimationEventInterface = { - animationName: null, - elapsedTime: null, - pseudoElement: null +Promise.prototype._length = function () { + return this._bitField & 65535; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticAnimationEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.prototype._isFateSealed = function () { + return (this._bitField & 117506048) !== 0; +}; -SyntheticEvent.augmentClass(SyntheticAnimationEvent, AnimationEventInterface); +Promise.prototype._isFollowing = function () { + return (this._bitField & 67108864) === 67108864; +}; -module.exports = SyntheticAnimationEvent; +Promise.prototype._setLength = function (len) { + this._bitField = (this._bitField & -65536) | + (len & 65535); +}; -/***/ }), -/* 202 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._setFulfilled = function () { + this._bitField = this._bitField | 33554432; + this._fireEvent("promiseFulfilled", this); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype._setRejected = function () { + this._bitField = this._bitField | 16777216; + this._fireEvent("promiseRejected", this); +}; +Promise.prototype._setFollowing = function () { + this._bitField = this._bitField | 67108864; + this._fireEvent("promiseResolved", this); +}; +Promise.prototype._setIsFinal = function () { + this._bitField = this._bitField | 4194304; +}; -var SyntheticEvent = __webpack_require__(16); +Promise.prototype._isFinal = function () { + return (this._bitField & 4194304) > 0; +}; -/** - * @interface Event - * @see http://www.w3.org/TR/clipboard-apis/ - */ -var ClipboardEventInterface = { - clipboardData: function (event) { - return 'clipboardData' in event ? event.clipboardData : window.clipboardData; - } +Promise.prototype._unsetCancelled = function() { + this._bitField = this._bitField & (~65536); }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticClipboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.prototype._setCancelled = function() { + this._bitField = this._bitField | 65536; + this._fireEvent("promiseCancelled", this); +}; -SyntheticEvent.augmentClass(SyntheticClipboardEvent, ClipboardEventInterface); +Promise.prototype._setWillBeCancelled = function() { + this._bitField = this._bitField | 8388608; +}; -module.exports = SyntheticClipboardEvent; +Promise.prototype._setAsyncGuaranteed = function() { + if (async.hasCustomScheduler()) return; + this._bitField = this._bitField | 134217728; +}; -/***/ }), -/* 203 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._receiverAt = function (index) { + var ret = index === 0 ? this._receiver0 : this[ + index * 4 - 4 + 3]; + if (ret === UNDEFINED_BINDING) { + return undefined; + } else if (ret === undefined && this._isBound()) { + return this._boundValue(); + } + return ret; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype._promiseAt = function (index) { + return this[ + index * 4 - 4 + 2]; +}; +Promise.prototype._fulfillmentHandlerAt = function (index) { + return this[ + index * 4 - 4 + 0]; +}; +Promise.prototype._rejectionHandlerAt = function (index) { + return this[ + index * 4 - 4 + 1]; +}; -var SyntheticUIEvent = __webpack_require__(33); +Promise.prototype._boundValue = function() {}; -/** - * @interface FocusEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var FocusEventInterface = { - relatedTarget: null +Promise.prototype._migrateCallback0 = function (follower) { + var bitField = follower._bitField; + var fulfill = follower._fulfillmentHandler0; + var reject = follower._rejectionHandler0; + var promise = follower._promise0; + var receiver = follower._receiverAt(0); + if (receiver === undefined) receiver = UNDEFINED_BINDING; + this._addCallbacks(fulfill, reject, promise, receiver, null); }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticFocusEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.prototype._migrateCallbackAt = function (follower, index) { + var fulfill = follower._fulfillmentHandlerAt(index); + var reject = follower._rejectionHandlerAt(index); + var promise = follower._promiseAt(index); + var receiver = follower._receiverAt(index); + if (receiver === undefined) receiver = UNDEFINED_BINDING; + this._addCallbacks(fulfill, reject, promise, receiver, null); +}; -SyntheticUIEvent.augmentClass(SyntheticFocusEvent, FocusEventInterface); +Promise.prototype._addCallbacks = function ( + fulfill, + reject, + promise, + receiver, + domain +) { + var index = this._length(); + + if (index >= 65535 - 4) { + index = 0; + this._setLength(0); + } + + if (index === 0) { + this._promise0 = promise; + this._receiver0 = receiver; + if (typeof fulfill === "function") { + this._fulfillmentHandler0 = + domain === null ? fulfill : util.domainBind(domain, fulfill); + } + if (typeof reject === "function") { + this._rejectionHandler0 = + domain === null ? reject : util.domainBind(domain, reject); + } + } else { + var base = index * 4 - 4; + this[base + 2] = promise; + this[base + 3] = receiver; + if (typeof fulfill === "function") { + this[base + 0] = + domain === null ? fulfill : util.domainBind(domain, fulfill); + } + if (typeof reject === "function") { + this[base + 1] = + domain === null ? reject : util.domainBind(domain, reject); + } + } + this._setLength(index + 1); + return index; +}; -module.exports = SyntheticFocusEvent; +Promise.prototype._proxy = function (proxyable, arg) { + this._addCallbacks(undefined, undefined, arg, proxyable, null); +}; -/***/ }), -/* 204 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._resolveCallback = function(value, shouldBind) { + if (((this._bitField & 117506048) !== 0)) return; + if (value === this) + return this._rejectCallback(makeSelfResolutionError(), false); + var maybePromise = tryConvertToPromise(value, this); + if (!(maybePromise instanceof Promise)) return this._fulfill(value); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + if (shouldBind) this._propagateFrom(maybePromise, 2); + var promise = maybePromise._target(); + if (promise === this) { + this._reject(makeSelfResolutionError()); + return; + } -var SyntheticUIEvent = __webpack_require__(33); + var bitField = promise._bitField; + if (((bitField & 50397184) === 0)) { + var len = this._length(); + if (len > 0) promise._migrateCallback0(this); + for (var i = 1; i < len; ++i) { + promise._migrateCallbackAt(this, i); + } + this._setFollowing(); + this._setLength(0); + this._setFollowee(promise); + } else if (((bitField & 33554432) !== 0)) { + this._fulfill(promise._value()); + } else if (((bitField & 16777216) !== 0)) { + this._reject(promise._reason()); + } else { + var reason = new CancellationError("late cancellation observer"); + promise._attachExtraTrace(reason); + this._reject(reason); + } +}; -var getEventCharCode = __webpack_require__(65); -var getEventKey = __webpack_require__(205); -var getEventModifierState = __webpack_require__(54); +Promise.prototype._rejectCallback = +function(reason, synchronous, ignoreNonErrorWarnings) { + var trace = util.ensureErrorObject(reason); + var hasStack = trace === reason; + if (!hasStack && !ignoreNonErrorWarnings && debug.warnings()) { + var message = "a promise was rejected with a non-error: " + + util.classString(reason); + this._warn(message, true); + } + this._attachExtraTrace(trace, synchronous ? hasStack : false); + this._reject(reason); +}; -/** - * @interface KeyboardEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var KeyboardEventInterface = { - key: getEventKey, - location: null, - ctrlKey: null, - shiftKey: null, - altKey: null, - metaKey: null, - repeat: null, - locale: null, - getModifierState: getEventModifierState, - // Legacy Interface - charCode: function (event) { - // `charCode` is the result of a KeyPress event and represents the value of - // the actual printable character. +Promise.prototype._resolveFromExecutor = function (executor) { + if (executor === INTERNAL) return; + var promise = this; + this._captureStackTrace(); + this._pushContext(); + var synchronous = true; + var r = this._execute(executor, function(value) { + promise._resolveCallback(value); + }, function (reason) { + promise._rejectCallback(reason, synchronous); + }); + synchronous = false; + this._popContext(); - // KeyPress is deprecated, but its replacement is not yet final and not - // implemented in any major browser. Only KeyPress has charCode. - if (event.type === 'keypress') { - return getEventCharCode(event); + if (r !== undefined) { + promise._rejectCallback(r, true); } - return 0; - }, - keyCode: function (event) { - // `keyCode` is the result of a KeyDown/Up event and represents the value of - // physical keyboard key. +}; - // The actual meaning of the value depends on the users' keyboard layout - // which cannot be detected. Assuming that it is a US keyboard layout - // provides a surprisingly accurate mapping for US and European users. - // Due to this, it is left to the user to implement at this time. - if (event.type === 'keydown' || event.type === 'keyup') { - return event.keyCode; +Promise.prototype._settlePromiseFromHandler = function ( + handler, receiver, value, promise +) { + var bitField = promise._bitField; + if (((bitField & 65536) !== 0)) return; + promise._pushContext(); + var x; + if (receiver === APPLY) { + if (!value || typeof value.length !== "number") { + x = errorObj; + x.e = new TypeError("cannot .spread() a non-array: " + + util.classString(value)); + } else { + x = tryCatch(handler).apply(this._boundValue(), value); + } + } else { + x = tryCatch(handler).call(receiver, value); } - return 0; - }, - which: function (event) { - // `which` is an alias for either `keyCode` or `charCode` depending on the - // type of the event. - if (event.type === 'keypress') { - return getEventCharCode(event); + var promiseCreated = promise._popContext(); + bitField = promise._bitField; + if (((bitField & 65536) !== 0)) return; + + if (x === NEXT_FILTER) { + promise._reject(value); + } else if (x === errorObj) { + promise._rejectCallback(x.e, false); + } else { + debug.checkForgottenReturns(x, promiseCreated, "", promise, this); + promise._resolveCallback(x); } - if (event.type === 'keydown' || event.type === 'keyup') { - return event.keyCode; +}; + +Promise.prototype._target = function() { + var ret = this; + while (ret._isFollowing()) ret = ret._followee(); + return ret; +}; + +Promise.prototype._followee = function() { + return this._rejectionHandler0; +}; + +Promise.prototype._setFollowee = function(promise) { + this._rejectionHandler0 = promise; +}; + +Promise.prototype._settlePromise = function(promise, handler, receiver, value) { + var isPromise = promise instanceof Promise; + var bitField = this._bitField; + var asyncGuaranteed = ((bitField & 134217728) !== 0); + if (((bitField & 65536) !== 0)) { + if (isPromise) promise._invokeInternalOnCancel(); + + if (receiver instanceof PassThroughHandlerContext && + receiver.isFinallyHandler()) { + receiver.cancelPromise = promise; + if (tryCatch(handler).call(receiver, value) === errorObj) { + promise._reject(errorObj.e); + } + } else if (handler === reflectHandler) { + promise._fulfill(reflectHandler.call(receiver)); + } else if (receiver instanceof Proxyable) { + receiver._promiseCancelled(promise); + } else if (isPromise || promise instanceof PromiseArray) { + promise._cancel(); + } else { + receiver.cancel(); + } + } else if (typeof handler === "function") { + if (!isPromise) { + handler.call(receiver, value, promise); + } else { + if (asyncGuaranteed) promise._setAsyncGuaranteed(); + this._settlePromiseFromHandler(handler, receiver, value, promise); + } + } else if (receiver instanceof Proxyable) { + if (!receiver._isResolved()) { + if (((bitField & 33554432) !== 0)) { + receiver._promiseFulfilled(value, promise); + } else { + receiver._promiseRejected(value, promise); + } + } + } else if (isPromise) { + if (asyncGuaranteed) promise._setAsyncGuaranteed(); + if (((bitField & 33554432) !== 0)) { + promise._fulfill(value); + } else { + promise._reject(value); + } } - return 0; - } }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticKeyboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +Promise.prototype._settlePromiseLateCancellationObserver = function(ctx) { + var handler = ctx.handler; + var promise = ctx.promise; + var receiver = ctx.receiver; + var value = ctx.value; + if (typeof handler === "function") { + if (!(promise instanceof Promise)) { + handler.call(receiver, value, promise); + } else { + this._settlePromiseFromHandler(handler, receiver, value, promise); + } + } else if (promise instanceof Promise) { + promise._reject(value); + } +}; -SyntheticUIEvent.augmentClass(SyntheticKeyboardEvent, KeyboardEventInterface); +Promise.prototype._settlePromiseCtx = function(ctx) { + this._settlePromise(ctx.promise, ctx.handler, ctx.receiver, ctx.value); +}; -module.exports = SyntheticKeyboardEvent; +Promise.prototype._settlePromise0 = function(handler, value, bitField) { + var promise = this._promise0; + var receiver = this._receiverAt(0); + this._promise0 = undefined; + this._receiver0 = undefined; + this._settlePromise(promise, handler, receiver, value); +}; -/***/ }), -/* 205 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._clearCallbackDataAtIndex = function(index) { + var base = index * 4 - 4; + this[base + 2] = + this[base + 3] = + this[base + 0] = + this[base + 1] = undefined; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype._fulfill = function (value) { + var bitField = this._bitField; + if (((bitField & 117506048) >>> 16)) return; + if (value === this) { + var err = makeSelfResolutionError(); + this._attachExtraTrace(err); + return this._reject(err); + } + this._setFulfilled(); + this._rejectionHandler0 = value; + if ((bitField & 65535) > 0) { + if (((bitField & 134217728) !== 0)) { + this._settlePromises(); + } else { + async.settlePromises(this); + } + } +}; +Promise.prototype._reject = function (reason) { + var bitField = this._bitField; + if (((bitField & 117506048) >>> 16)) return; + this._setRejected(); + this._fulfillmentHandler0 = reason; -var getEventCharCode = __webpack_require__(65); + if (this._isFinal()) { + return async.fatalError(reason, util.isNode); + } -/** - * Normalization of deprecated HTML5 `key` values - * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names - */ -var normalizeKey = { - Esc: 'Escape', - Spacebar: ' ', - Left: 'ArrowLeft', - Up: 'ArrowUp', - Right: 'ArrowRight', - Down: 'ArrowDown', - Del: 'Delete', - Win: 'OS', - Menu: 'ContextMenu', - Apps: 'ContextMenu', - Scroll: 'ScrollLock', - MozPrintableKey: 'Unidentified' + if ((bitField & 65535) > 0) { + async.settlePromises(this); + } else { + this._ensurePossibleRejectionHandled(); + } }; -/** - * Translation from legacy `keyCode` to HTML5 `key` - * Only special keys supported, all others depend on keyboard layout or browser - * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names - */ -var translateToKey = { - 8: 'Backspace', - 9: 'Tab', - 12: 'Clear', - 13: 'Enter', - 16: 'Shift', - 17: 'Control', - 18: 'Alt', - 19: 'Pause', - 20: 'CapsLock', - 27: 'Escape', - 32: ' ', - 33: 'PageUp', - 34: 'PageDown', - 35: 'End', - 36: 'Home', - 37: 'ArrowLeft', - 38: 'ArrowUp', - 39: 'ArrowRight', - 40: 'ArrowDown', - 45: 'Insert', - 46: 'Delete', - 112: 'F1', - 113: 'F2', - 114: 'F3', - 115: 'F4', - 116: 'F5', - 117: 'F6', - 118: 'F7', - 119: 'F8', - 120: 'F9', - 121: 'F10', - 122: 'F11', - 123: 'F12', - 144: 'NumLock', - 145: 'ScrollLock', - 224: 'Meta' +Promise.prototype._fulfillPromises = function (len, value) { + for (var i = 1; i < len; i++) { + var handler = this._fulfillmentHandlerAt(i); + var promise = this._promiseAt(i); + var receiver = this._receiverAt(i); + this._clearCallbackDataAtIndex(i); + this._settlePromise(promise, handler, receiver, value); + } }; -/** - * @param {object} nativeEvent Native browser event. - * @return {string} Normalized `key` property. - */ -function getEventKey(nativeEvent) { - if (nativeEvent.key) { - // Normalize inconsistent values reported by browsers due to - // implementations of a working draft specification. +Promise.prototype._rejectPromises = function (len, reason) { + for (var i = 1; i < len; i++) { + var handler = this._rejectionHandlerAt(i); + var promise = this._promiseAt(i); + var receiver = this._receiverAt(i); + this._clearCallbackDataAtIndex(i); + this._settlePromise(promise, handler, receiver, reason); + } +}; - // FireFox implements `key` but returns `MozPrintableKey` for all - // printable characters (normalized to `Unidentified`), ignore it. - var key = normalizeKey[nativeEvent.key] || nativeEvent.key; - if (key !== 'Unidentified') { - return key; +Promise.prototype._settlePromises = function () { + var bitField = this._bitField; + var len = (bitField & 65535); + + if (len > 0) { + if (((bitField & 16842752) !== 0)) { + var reason = this._fulfillmentHandler0; + this._settlePromise0(this._rejectionHandler0, reason, bitField); + this._rejectPromises(len, reason); + } else { + var value = this._rejectionHandler0; + this._settlePromise0(this._fulfillmentHandler0, value, bitField); + this._fulfillPromises(len, value); + } + this._setLength(0); } - } + this._clearCancellationData(); +}; - // Browser does not implement `key`, polyfill as much of it as we can. - if (nativeEvent.type === 'keypress') { - var charCode = getEventCharCode(nativeEvent); +Promise.prototype._settledValue = function() { + var bitField = this._bitField; + if (((bitField & 33554432) !== 0)) { + return this._rejectionHandler0; + } else if (((bitField & 16777216) !== 0)) { + return this._fulfillmentHandler0; + } +}; + +function deferResolve(v) {this.promise._resolveCallback(v);} +function deferReject(v) {this.promise._rejectCallback(v, false);} + +Promise.defer = Promise.pending = function() { + debug.deprecated("Promise.defer", "new Promise"); + var promise = new Promise(INTERNAL); + return { + promise: promise, + resolve: deferResolve, + reject: deferReject + }; +}; + +util.notEnumerableProp(Promise, + "_makeSelfResolutionError", + makeSelfResolutionError); + +_dereq_("./method")(Promise, INTERNAL, tryConvertToPromise, apiRejection, + debug); +_dereq_("./bind")(Promise, INTERNAL, tryConvertToPromise, debug); +_dereq_("./cancel")(Promise, PromiseArray, apiRejection, debug); +_dereq_("./direct_resolve")(Promise); +_dereq_("./synchronous_inspection")(Promise); +_dereq_("./join")( + Promise, PromiseArray, tryConvertToPromise, INTERNAL, async, getDomain); +Promise.Promise = Promise; +Promise.version = "3.5.0"; +_dereq_('./map.js')(Promise, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug); +_dereq_('./call_get.js')(Promise); +_dereq_('./using.js')(Promise, apiRejection, tryConvertToPromise, createContext, INTERNAL, debug); +_dereq_('./timers.js')(Promise, INTERNAL, debug); +_dereq_('./generators.js')(Promise, apiRejection, INTERNAL, tryConvertToPromise, Proxyable, debug); +_dereq_('./nodeify.js')(Promise); +_dereq_('./promisify.js')(Promise, INTERNAL); +_dereq_('./props.js')(Promise, PromiseArray, tryConvertToPromise, apiRejection); +_dereq_('./race.js')(Promise, INTERNAL, tryConvertToPromise, apiRejection); +_dereq_('./reduce.js')(Promise, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug); +_dereq_('./settle.js')(Promise, PromiseArray, debug); +_dereq_('./some.js')(Promise, PromiseArray, apiRejection); +_dereq_('./filter.js')(Promise, INTERNAL); +_dereq_('./each.js')(Promise, INTERNAL); +_dereq_('./any.js')(Promise); + + util.toFastProperties(Promise); + util.toFastProperties(Promise.prototype); + function fillTypes(value) { + var p = new Promise(INTERNAL); + p._fulfillmentHandler0 = value; + p._rejectionHandler0 = value; + p._promise0 = value; + p._receiver0 = value; + } + // Complete slack tracking, opt out of field-type tracking and + // stabilize map + fillTypes({a: 1}); + fillTypes({b: 2}); + fillTypes({c: 3}); + fillTypes(1); + fillTypes(function(){}); + fillTypes(undefined); + fillTypes(false); + fillTypes(new Promise(INTERNAL)); + debug.setBounds(Async.firstLineError, util.lastLineError); + return Promise; + +}; + +},{"./any.js":1,"./async":2,"./bind":3,"./call_get.js":5,"./cancel":6,"./catch_filter":7,"./context":8,"./debuggability":9,"./direct_resolve":10,"./each.js":11,"./errors":12,"./es5":13,"./filter.js":14,"./finally":15,"./generators.js":16,"./join":17,"./map.js":18,"./method":19,"./nodeback":20,"./nodeify.js":21,"./promise_array":23,"./promisify.js":24,"./props.js":25,"./race.js":27,"./reduce.js":28,"./settle.js":30,"./some.js":31,"./synchronous_inspection":32,"./thenables":33,"./timers.js":34,"./using.js":35,"./util":36}],23:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL, tryConvertToPromise, + apiRejection, Proxyable) { +var util = _dereq_("./util"); +var isArray = util.isArray; - // The enter-key is technically both printable and non-printable and can - // thus be captured by `keypress`, no other non-printable key should. - return charCode === 13 ? 'Enter' : String.fromCharCode(charCode); - } - if (nativeEvent.type === 'keydown' || nativeEvent.type === 'keyup') { - // While user keyboard layout determines the actual meaning of each - // `keyCode` value, almost all function keys have a universal value. - return translateToKey[nativeEvent.keyCode] || 'Unidentified'; - } - return ''; +function toResolutionValue(val) { + switch(val) { + case -2: return []; + case -3: return {}; + case -6: return new Map(); + } } -module.exports = getEventKey; +function PromiseArray(values) { + var promise = this._promise = new Promise(INTERNAL); + if (values instanceof Promise) { + promise._propagateFrom(values, 3); + } + promise._setOnCancel(this); + this._values = values; + this._length = 0; + this._totalResolved = 0; + this._init(undefined, -2); +} +util.inherits(PromiseArray, Proxyable); -/***/ }), -/* 206 */ -/***/ (function(module, exports, __webpack_require__) { +PromiseArray.prototype.length = function () { + return this._length; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +PromiseArray.prototype.promise = function () { + return this._promise; +}; +PromiseArray.prototype._init = function init(_, resolveValueIfEmpty) { + var values = tryConvertToPromise(this._values, this._promise); + if (values instanceof Promise) { + values = values._target(); + var bitField = values._bitField; + ; + this._values = values; + + if (((bitField & 50397184) === 0)) { + this._promise._setAsyncGuaranteed(); + return values._then( + init, + this._reject, + undefined, + this, + resolveValueIfEmpty + ); + } else if (((bitField & 33554432) !== 0)) { + values = values._value(); + } else if (((bitField & 16777216) !== 0)) { + return this._reject(values._reason()); + } else { + return this._cancel(); + } + } + values = util.asArray(values); + if (values === null) { + var err = apiRejection( + "expecting an array or an iterable object but got " + util.classString(values)).reason(); + this._promise._rejectCallback(err, false); + return; + } + if (values.length === 0) { + if (resolveValueIfEmpty === -5) { + this._resolveEmptyArray(); + } + else { + this._resolve(toResolutionValue(resolveValueIfEmpty)); + } + return; + } + this._iterate(values); +}; -var SyntheticMouseEvent = __webpack_require__(42); +PromiseArray.prototype._iterate = function(values) { + var len = this.getActualLength(values.length); + this._length = len; + this._values = this.shouldCopyValues() ? new Array(len) : this._values; + var result = this._promise; + var isResolved = false; + var bitField = null; + for (var i = 0; i < len; ++i) { + var maybePromise = tryConvertToPromise(values[i], result); + + if (maybePromise instanceof Promise) { + maybePromise = maybePromise._target(); + bitField = maybePromise._bitField; + } else { + bitField = null; + } -/** - * @interface DragEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var DragEventInterface = { - dataTransfer: null + if (isResolved) { + if (bitField !== null) { + maybePromise.suppressUnhandledRejections(); + } + } else if (bitField !== null) { + if (((bitField & 50397184) === 0)) { + maybePromise._proxy(this, i); + this._values[i] = maybePromise; + } else if (((bitField & 33554432) !== 0)) { + isResolved = this._promiseFulfilled(maybePromise._value(), i); + } else if (((bitField & 16777216) !== 0)) { + isResolved = this._promiseRejected(maybePromise._reason(), i); + } else { + isResolved = this._promiseCancelled(i); + } + } else { + isResolved = this._promiseFulfilled(maybePromise, i); + } + } + if (!isResolved) result._setAsyncGuaranteed(); }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticDragEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +PromiseArray.prototype._isResolved = function () { + return this._values === null; +}; -SyntheticMouseEvent.augmentClass(SyntheticDragEvent, DragEventInterface); +PromiseArray.prototype._resolve = function (value) { + this._values = null; + this._promise._fulfill(value); +}; -module.exports = SyntheticDragEvent; +PromiseArray.prototype._cancel = function() { + if (this._isResolved() || !this._promise._isCancellable()) return; + this._values = null; + this._promise._cancel(); +}; -/***/ }), -/* 207 */ -/***/ (function(module, exports, __webpack_require__) { +PromiseArray.prototype._reject = function (reason) { + this._values = null; + this._promise._rejectCallback(reason, false); +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +PromiseArray.prototype._promiseFulfilled = function (value, index) { + this._values[index] = value; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + this._resolve(this._values); + return true; + } + return false; +}; +PromiseArray.prototype._promiseCancelled = function() { + this._cancel(); + return true; +}; +PromiseArray.prototype._promiseRejected = function (reason) { + this._totalResolved++; + this._reject(reason); + return true; +}; -var SyntheticUIEvent = __webpack_require__(33); +PromiseArray.prototype._resultCancelled = function() { + if (this._isResolved()) return; + var values = this._values; + this._cancel(); + if (values instanceof Promise) { + values.cancel(); + } else { + for (var i = 0; i < values.length; ++i) { + if (values[i] instanceof Promise) { + values[i].cancel(); + } + } + } +}; -var getEventModifierState = __webpack_require__(54); +PromiseArray.prototype.shouldCopyValues = function () { + return true; +}; -/** - * @interface TouchEvent - * @see http://www.w3.org/TR/touch-events/ - */ -var TouchEventInterface = { - touches: null, - targetTouches: null, - changedTouches: null, - altKey: null, - metaKey: null, - ctrlKey: null, - shiftKey: null, - getModifierState: getEventModifierState +PromiseArray.prototype.getActualLength = function (len) { + return len; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticTouchEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +return PromiseArray; +}; + +},{"./util":36}],24:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL) { +var THIS = {}; +var util = _dereq_("./util"); +var nodebackForPromise = _dereq_("./nodeback"); +var withAppended = util.withAppended; +var maybeWrapAsError = util.maybeWrapAsError; +var canEvaluate = util.canEvaluate; +var TypeError = _dereq_("./errors").TypeError; +var defaultSuffix = "Async"; +var defaultPromisified = {__isPromisified__: true}; +var noCopyProps = [ + "arity", "length", + "name", + "arguments", + "caller", + "callee", + "prototype", + "__isPromisified__" +]; +var noCopyPropsPattern = new RegExp("^(?:" + noCopyProps.join("|") + ")$"); + +var defaultFilter = function(name) { + return util.isIdentifier(name) && + name.charAt(0) !== "_" && + name !== "constructor"; +}; + +function propsFilter(key) { + return !noCopyPropsPattern.test(key); } -SyntheticUIEvent.augmentClass(SyntheticTouchEvent, TouchEventInterface); +function isPromisified(fn) { + try { + return fn.__isPromisified__ === true; + } + catch (e) { + return false; + } +} -module.exports = SyntheticTouchEvent; +function hasPromisified(obj, key, suffix) { + var val = util.getDataPropertyOrDefault(obj, key + suffix, + defaultPromisified); + return val ? isPromisified(val) : false; +} +function checkValid(ret, suffix, suffixRegexp) { + for (var i = 0; i < ret.length; i += 2) { + var key = ret[i]; + if (suffixRegexp.test(key)) { + var keyWithoutAsyncSuffix = key.replace(suffixRegexp, ""); + for (var j = 0; j < ret.length; j += 2) { + if (ret[j] === keyWithoutAsyncSuffix) { + throw new TypeError("Cannot promisify an API that has normal methods with '%s'-suffix\u000a\u000a See http://goo.gl/MqrFmX\u000a" + .replace("%s", suffix)); + } + } + } + } +} -/***/ }), -/* 208 */ -/***/ (function(module, exports, __webpack_require__) { +function promisifiableMethods(obj, suffix, suffixRegexp, filter) { + var keys = util.inheritedDataKeys(obj); + var ret = []; + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + var value = obj[key]; + var passesDefaultFilter = filter === defaultFilter + ? true : defaultFilter(key, value, obj); + if (typeof value === "function" && + !isPromisified(value) && + !hasPromisified(obj, key, suffix) && + filter(key, value, obj, passesDefaultFilter)) { + ret.push(key, value); + } + } + checkValid(ret, suffix, suffixRegexp); + return ret; +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var escapeIdentRegex = function(str) { + return str.replace(/([$])/, "\\$"); +}; +var makeNodePromisifiedEval; +if (false) { +var switchCaseArgumentOrder = function(likelyArgumentCount) { + var ret = [likelyArgumentCount]; + var min = Math.max(0, likelyArgumentCount - 1 - 3); + for(var i = likelyArgumentCount - 1; i >= min; --i) { + ret.push(i); + } + for(var i = likelyArgumentCount + 1; i <= 3; ++i) { + ret.push(i); + } + return ret; +}; +var argumentSequence = function(argumentCount) { + return util.filledRange(argumentCount, "_arg", ""); +}; -var SyntheticEvent = __webpack_require__(16); +var parameterDeclaration = function(parameterCount) { + return util.filledRange( + Math.max(parameterCount, 3), "_arg", ""); +}; -/** - * @interface Event - * @see http://www.w3.org/TR/2009/WD-css3-transitions-20090320/#transition-events- - * @see https://developer.mozilla.org/en-US/docs/Web/API/TransitionEvent - */ -var TransitionEventInterface = { - propertyName: null, - elapsedTime: null, - pseudoElement: null +var parameterCount = function(fn) { + if (typeof fn.length === "number") { + return Math.max(Math.min(fn.length, 1023 + 1), 0); + } + return 0; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticTransitionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +makeNodePromisifiedEval = +function(callback, receiver, originalName, fn, _, multiArgs) { + var newParameterCount = Math.max(0, parameterCount(fn) - 1); + var argumentOrder = switchCaseArgumentOrder(newParameterCount); + var shouldProxyThis = typeof callback === "string" || receiver === THIS; + + function generateCallForArgumentCount(count) { + var args = argumentSequence(count).join(", "); + var comma = count > 0 ? ", " : ""; + var ret; + if (shouldProxyThis) { + ret = "ret = callback.call(this, {{args}}, nodeback); break;\n"; + } else { + ret = receiver === undefined + ? "ret = callback({{args}}, nodeback); break;\n" + : "ret = callback.call(receiver, {{args}}, nodeback); break;\n"; + } + return ret.replace("{{args}}", args).replace(", ", comma); + } + + function generateArgumentSwitchCase() { + var ret = ""; + for (var i = 0; i < argumentOrder.length; ++i) { + ret += "case " + argumentOrder[i] +":" + + generateCallForArgumentCount(argumentOrder[i]); + } + + ret += " \n\ + default: \n\ + var args = new Array(len + 1); \n\ + var i = 0; \n\ + for (var i = 0; i < len; ++i) { \n\ + args[i] = arguments[i]; \n\ + } \n\ + args[i] = nodeback; \n\ + [CodeForCall] \n\ + break; \n\ + ".replace("[CodeForCall]", (shouldProxyThis + ? "ret = callback.apply(this, args);\n" + : "ret = callback.apply(receiver, args);\n")); + return ret; + } + + var getFunctionCode = typeof callback === "string" + ? ("this != null ? this['"+callback+"'] : fn") + : "fn"; + var body = "'use strict'; \n\ + var ret = function (Parameters) { \n\ + 'use strict'; \n\ + var len = arguments.length; \n\ + var promise = new Promise(INTERNAL); \n\ + promise._captureStackTrace(); \n\ + var nodeback = nodebackForPromise(promise, " + multiArgs + "); \n\ + var ret; \n\ + var callback = tryCatch([GetFunctionCode]); \n\ + switch(len) { \n\ + [CodeForSwitchCase] \n\ + } \n\ + if (ret === errorObj) { \n\ + promise._rejectCallback(maybeWrapAsError(ret.e), true, true);\n\ + } \n\ + if (!promise._isFateSealed()) promise._setAsyncGuaranteed(); \n\ + return promise; \n\ + }; \n\ + notEnumerableProp(ret, '__isPromisified__', true); \n\ + return ret; \n\ + ".replace("[CodeForSwitchCase]", generateArgumentSwitchCase()) + .replace("[GetFunctionCode]", getFunctionCode); + body = body.replace("Parameters", parameterDeclaration(newParameterCount)); + return new Function("Promise", + "fn", + "receiver", + "withAppended", + "maybeWrapAsError", + "nodebackForPromise", + "tryCatch", + "errorObj", + "notEnumerableProp", + "INTERNAL", + body)( + Promise, + fn, + receiver, + withAppended, + maybeWrapAsError, + nodebackForPromise, + util.tryCatch, + util.errorObj, + util.notEnumerableProp, + INTERNAL); +}; } -SyntheticEvent.augmentClass(SyntheticTransitionEvent, TransitionEventInterface); +function makeNodePromisifiedClosure(callback, receiver, _, fn, __, multiArgs) { + var defaultThis = (function() {return this;})(); + var method = callback; + if (typeof method === "string") { + callback = fn; + } + function promisified() { + var _receiver = receiver; + if (receiver === THIS) _receiver = this; + var promise = new Promise(INTERNAL); + promise._captureStackTrace(); + var cb = typeof method === "string" && this !== defaultThis + ? this[method] : callback; + var fn = nodebackForPromise(promise, multiArgs); + try { + cb.apply(_receiver, withAppended(arguments, fn)); + } catch(e) { + promise._rejectCallback(maybeWrapAsError(e), true, true); + } + if (!promise._isFateSealed()) promise._setAsyncGuaranteed(); + return promise; + } + util.notEnumerableProp(promisified, "__isPromisified__", true); + return promisified; +} -module.exports = SyntheticTransitionEvent; +var makeNodePromisified = canEvaluate + ? makeNodePromisifiedEval + : makeNodePromisifiedClosure; + +function promisifyAll(obj, suffix, filter, promisifier, multiArgs) { + var suffixRegexp = new RegExp(escapeIdentRegex(suffix) + "$"); + var methods = + promisifiableMethods(obj, suffix, suffixRegexp, filter); + + for (var i = 0, len = methods.length; i < len; i+= 2) { + var key = methods[i]; + var fn = methods[i+1]; + var promisifiedKey = key + suffix; + if (promisifier === makeNodePromisified) { + obj[promisifiedKey] = + makeNodePromisified(key, THIS, key, fn, suffix, multiArgs); + } else { + var promisified = promisifier(fn, function() { + return makeNodePromisified(key, THIS, key, + fn, suffix, multiArgs); + }); + util.notEnumerableProp(promisified, "__isPromisified__", true); + obj[promisifiedKey] = promisified; + } + } + util.toFastProperties(obj); + return obj; +} -/***/ }), -/* 209 */ -/***/ (function(module, exports, __webpack_require__) { +function promisify(callback, receiver, multiArgs) { + return makeNodePromisified(callback, receiver, undefined, + callback, null, multiArgs); +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.promisify = function (fn, options) { + if (typeof fn !== "function") { + throw new TypeError("expecting a function but got " + util.classString(fn)); + } + if (isPromisified(fn)) { + return fn; + } + options = Object(options); + var receiver = options.context === undefined ? THIS : options.context; + var multiArgs = !!options.multiArgs; + var ret = promisify(fn, receiver, multiArgs); + util.copyDescriptors(fn, ret, propsFilter); + return ret; +}; +Promise.promisifyAll = function (target, options) { + if (typeof target !== "function" && typeof target !== "object") { + throw new TypeError("the target of promisifyAll must be an object or a function\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + options = Object(options); + var multiArgs = !!options.multiArgs; + var suffix = options.suffix; + if (typeof suffix !== "string") suffix = defaultSuffix; + var filter = options.filter; + if (typeof filter !== "function") filter = defaultFilter; + var promisifier = options.promisifier; + if (typeof promisifier !== "function") promisifier = makeNodePromisified; + + if (!util.isIdentifier(suffix)) { + throw new RangeError("suffix must be a valid identifier\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + + var keys = util.inheritedDataKeys(target); + for (var i = 0; i < keys.length; ++i) { + var value = target[keys[i]]; + if (keys[i] !== "constructor" && + util.isClass(value)) { + promisifyAll(value.prototype, suffix, filter, promisifier, + multiArgs); + promisifyAll(value, suffix, filter, promisifier, multiArgs); + } + } + return promisifyAll(target, suffix, filter, promisifier, multiArgs); +}; +}; -var SyntheticMouseEvent = __webpack_require__(42); -/** - * @interface WheelEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var WheelEventInterface = { - deltaX: function (event) { - return 'deltaX' in event ? event.deltaX : // Fallback to `wheelDeltaX` for Webkit and normalize (right is positive). - 'wheelDeltaX' in event ? -event.wheelDeltaX : 0; - }, - deltaY: function (event) { - return 'deltaY' in event ? event.deltaY : // Fallback to `wheelDeltaY` for Webkit and normalize (down is positive). - 'wheelDeltaY' in event ? -event.wheelDeltaY : // Fallback to `wheelDelta` for IE<9 and normalize (down is positive). - 'wheelDelta' in event ? -event.wheelDelta : 0; - }, - deltaZ: null, +},{"./errors":12,"./nodeback":20,"./util":36}],25:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function( + Promise, PromiseArray, tryConvertToPromise, apiRejection) { +var util = _dereq_("./util"); +var isObject = util.isObject; +var es5 = _dereq_("./es5"); +var Es6Map; +if (typeof Map === "function") Es6Map = Map; + +var mapToEntries = (function() { + var index = 0; + var size = 0; + + function extractEntry(value, key) { + this[index] = value; + this[index + size] = key; + index++; + } + + return function mapToEntries(map) { + size = map.size; + index = 0; + var ret = new Array(map.size * 2); + map.forEach(extractEntry, ret); + return ret; + }; +})(); - // Browsers without "deltaMode" is reporting in raw wheel delta where one - // notch on the scroll is always +/- 120, roughly equivalent to pixels. - // A good approximation of DOM_DELTA_LINE (1) is 5% of viewport size or - // ~40 pixels, for DOM_DELTA_SCREEN (2) it is 87.5% of viewport size. - deltaMode: null +var entriesToMap = function(entries) { + var ret = new Es6Map(); + var length = entries.length / 2 | 0; + for (var i = 0; i < length; ++i) { + var key = entries[length + i]; + var value = entries[i]; + ret.set(key, value); + } + return ret; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticMouseEvent} - */ -function SyntheticWheelEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +function PropertiesPromiseArray(obj) { + var isMap = false; + var entries; + if (Es6Map !== undefined && obj instanceof Es6Map) { + entries = mapToEntries(obj); + isMap = true; + } else { + var keys = es5.keys(obj); + var len = keys.length; + entries = new Array(len * 2); + for (var i = 0; i < len; ++i) { + var key = keys[i]; + entries[i] = obj[key]; + entries[i + len] = key; + } + } + this.constructor$(entries); + this._isMap = isMap; + this._init$(undefined, isMap ? -6 : -3); } +util.inherits(PropertiesPromiseArray, PromiseArray); -SyntheticMouseEvent.augmentClass(SyntheticWheelEvent, WheelEventInterface); - -module.exports = SyntheticWheelEvent; - -/***/ }), -/* 210 */ -/***/ (function(module, exports, __webpack_require__) { +PropertiesPromiseArray.prototype._init = function () {}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +PropertiesPromiseArray.prototype._promiseFulfilled = function (value, index) { + this._values[index] = value; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + var val; + if (this._isMap) { + val = entriesToMap(this._values); + } else { + val = {}; + var keyOffset = this.length(); + for (var i = 0, len = this.length(); i < len; ++i) { + val[this._values[i + keyOffset]] = this._values[i]; + } + } + this._resolve(val); + return true; + } + return false; +}; +PropertiesPromiseArray.prototype.shouldCopyValues = function () { + return false; +}; +PropertiesPromiseArray.prototype.getActualLength = function (len) { + return len >> 1; +}; -var validateDOMNesting = __webpack_require__(64); +function props(promises) { + var ret; + var castValue = tryConvertToPromise(promises); -var DOC_NODE_TYPE = 9; + if (!isObject(castValue)) { + return apiRejection("cannot await properties of a non-object\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } else if (castValue instanceof Promise) { + ret = castValue._then( + Promise.props, undefined, undefined, undefined, undefined); + } else { + ret = new PropertiesPromiseArray(castValue).promise(); + } -function ReactDOMContainerInfo(topLevelWrapper, node) { - var info = { - _topLevelWrapper: topLevelWrapper, - _idCounter: 1, - _ownerDocument: node ? node.nodeType === DOC_NODE_TYPE ? node : node.ownerDocument : null, - _node: node, - _tag: node ? node.nodeName.toLowerCase() : null, - _namespaceURI: node ? node.namespaceURI : null - }; - if (process.env.NODE_ENV !== 'production') { - info._ancestorInfo = node ? validateDOMNesting.updatedAncestorInfo(null, info._tag, null) : null; - } - return info; + if (castValue instanceof Promise) { + ret._propagateFrom(castValue, 2); + } + return ret; } -module.exports = ReactDOMContainerInfo; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Promise.prototype.props = function () { + return props(this); +}; -/***/ }), -/* 211 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.props = function (promises) { + return props(promises); +}; +}; +},{"./es5":13,"./util":36}],26:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function arrayMove(src, srcIndex, dst, dstIndex, len) { + for (var j = 0; j < len; ++j) { + dst[j + dstIndex] = src[j + srcIndex]; + src[j + srcIndex] = void 0; + } +} + +function Queue(capacity) { + this._capacity = capacity; + this._length = 0; + this._front = 0; +} +Queue.prototype._willBeOverCapacity = function (size) { + return this._capacity < size; +}; +Queue.prototype._pushOne = function (arg) { + var length = this.length(); + this._checkCapacity(length + 1); + var i = (this._front + length) & (this._capacity - 1); + this[i] = arg; + this._length = length + 1; +}; -var ReactDOMFeatureFlags = { - useCreateElement: true, - useFiber: false +Queue.prototype.push = function (fn, receiver, arg) { + var length = this.length() + 3; + if (this._willBeOverCapacity(length)) { + this._pushOne(fn); + this._pushOne(receiver); + this._pushOne(arg); + return; + } + var j = this._front + length - 3; + this._checkCapacity(length); + var wrapMask = this._capacity - 1; + this[(j + 0) & wrapMask] = fn; + this[(j + 1) & wrapMask] = receiver; + this[(j + 2) & wrapMask] = arg; + this._length = length; }; -module.exports = ReactDOMFeatureFlags; +Queue.prototype.shift = function () { + var front = this._front, + ret = this[front]; -/***/ }), -/* 212 */ -/***/ (function(module, exports, __webpack_require__) { + this[front] = undefined; + this._front = (front + 1) & (this._capacity - 1); + this._length--; + return ret; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Queue.prototype.length = function () { + return this._length; +}; +Queue.prototype._checkCapacity = function (size) { + if (this._capacity < size) { + this._resizeTo(this._capacity << 1); + } +}; +Queue.prototype._resizeTo = function (capacity) { + var oldCapacity = this._capacity; + this._capacity = capacity; + var front = this._front; + var length = this._length; + var moveItemsCount = (front + length) & (oldCapacity - 1); + arrayMove(this, 0, this, oldCapacity, moveItemsCount); +}; -var adler32 = __webpack_require__(213); +module.exports = Queue; -var TAG_END = /\/?>/; -var COMMENT_START = /^<\!\-\-/; +},{}],27:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function( + Promise, INTERNAL, tryConvertToPromise, apiRejection) { +var util = _dereq_("./util"); -var ReactMarkupChecksum = { - CHECKSUM_ATTR_NAME: 'data-react-checksum', +var raceLater = function (promise) { + return promise.then(function(array) { + return race(array, promise); + }); +}; - /** - * @param {string} markup Markup string - * @return {string} Markup string with checksum attribute attached - */ - addChecksumToMarkup: function (markup) { - var checksum = adler32(markup); +function race(promises, parent) { + var maybePromise = tryConvertToPromise(promises); - // Add checksum (handle both parent tags, comments and self-closing tags) - if (COMMENT_START.test(markup)) { - return markup; + if (maybePromise instanceof Promise) { + return raceLater(maybePromise); } else { - return markup.replace(TAG_END, ' ' + ReactMarkupChecksum.CHECKSUM_ATTR_NAME + '="' + checksum + '"$&'); + promises = util.asArray(promises); + if (promises === null) + return apiRejection("expecting an array or an iterable object but got " + util.classString(promises)); } - }, - - /** - * @param {string} markup to use - * @param {DOMElement} element root React element - * @returns {boolean} whether or not the markup is the same - */ - canReuseMarkup: function (markup, element) { - var existingChecksum = element.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); - existingChecksum = existingChecksum && parseInt(existingChecksum, 10); - var markupChecksum = adler32(markup); - return markupChecksum === existingChecksum; - } -}; -module.exports = ReactMarkupChecksum; + var ret = new Promise(INTERNAL); + if (parent !== undefined) { + ret._propagateFrom(parent, 3); + } + var fulfill = ret._fulfill; + var reject = ret._reject; + for (var i = 0, len = promises.length; i < len; ++i) { + var val = promises[i]; -/***/ }), -/* 213 */ -/***/ (function(module, exports, __webpack_require__) { + if (val === undefined && !(i in promises)) { + continue; + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + Promise.cast(val)._then(fulfill, reject, undefined, ret, null); + } + return ret; +} +Promise.race = function (promises) { + return race(promises, undefined); +}; +Promise.prototype.race = function () { + return race(this, undefined); +}; -var MOD = 65521; +}; -// adler32 is not cryptographically strong, and is only used to sanity check that -// markup generated on the server matches the markup generated on the client. -// This implementation (a modified version of the SheetJS version) has been optimized -// for our use case, at the expense of conforming to the adler32 specification -// for non-ascii inputs. -function adler32(data) { - var a = 1; - var b = 0; - var i = 0; - var l = data.length; - var m = l & ~0x3; - while (i < m) { - var n = Math.min(i + 4096, m); - for (; i < n; i += 4) { - b += (a += data.charCodeAt(i)) + (a += data.charCodeAt(i + 1)) + (a += data.charCodeAt(i + 2)) + (a += data.charCodeAt(i + 3)); +},{"./util":36}],28:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, + PromiseArray, + apiRejection, + tryConvertToPromise, + INTERNAL, + debug) { +var getDomain = Promise._getDomain; +var util = _dereq_("./util"); +var tryCatch = util.tryCatch; + +function ReductionPromiseArray(promises, fn, initialValue, _each) { + this.constructor$(promises); + var domain = getDomain(); + this._fn = domain === null ? fn : util.domainBind(domain, fn); + if (initialValue !== undefined) { + initialValue = Promise.resolve(initialValue); + initialValue._attachCancellationCallback(this); + } + this._initialValue = initialValue; + this._currentCancellable = null; + if(_each === INTERNAL) { + this._eachValues = Array(this._length); + } else if (_each === 0) { + this._eachValues = null; + } else { + this._eachValues = undefined; } - a %= MOD; - b %= MOD; - } - for (; i < l; i++) { - b += a += data.charCodeAt(i); - } - a %= MOD; - b %= MOD; - return a | b << 16; + this._promise._captureStackTrace(); + this._init$(undefined, -5); } +util.inherits(ReductionPromiseArray, PromiseArray); -module.exports = adler32; +ReductionPromiseArray.prototype._gotAccum = function(accum) { + if (this._eachValues !== undefined && + this._eachValues !== null && + accum !== INTERNAL) { + this._eachValues.push(accum); + } +}; -/***/ }), -/* 214 */ -/***/ (function(module, exports, __webpack_require__) { +ReductionPromiseArray.prototype._eachComplete = function(value) { + if (this._eachValues !== null) { + this._eachValues.push(value); + } + return this._eachValues; +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +ReductionPromiseArray.prototype._init = function() {}; +ReductionPromiseArray.prototype._resolveEmptyArray = function() { + this._resolve(this._eachValues !== undefined ? this._eachValues + : this._initialValue); +}; +ReductionPromiseArray.prototype.shouldCopyValues = function () { + return false; +}; -module.exports = '15.6.1'; +ReductionPromiseArray.prototype._resolve = function(value) { + this._promise._resolveCallback(value); + this._values = null; +}; -/***/ }), -/* 215 */ -/***/ (function(module, exports, __webpack_require__) { +ReductionPromiseArray.prototype._resultCancelled = function(sender) { + if (sender === this._initialValue) return this._cancel(); + if (this._isResolved()) return; + this._resultCancelled$(); + if (this._currentCancellable instanceof Promise) { + this._currentCancellable.cancel(); + } + if (this._initialValue instanceof Promise) { + this._initialValue.cancel(); + } +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +ReductionPromiseArray.prototype._iterate = function (values) { + this._values = values; + var value; + var i; + var length = values.length; + if (this._initialValue !== undefined) { + value = this._initialValue; + i = 0; + } else { + value = Promise.resolve(values[0]); + i = 1; + } + this._currentCancellable = value; + if (!value.isRejected()) { + for (; i < length; ++i) { + var ctx = { + accum: null, + value: values[i], + index: i, + length: length, + array: this + }; + value = value._then(gotAccum, undefined, undefined, ctx, undefined); + } + } -var _prodInvariant = __webpack_require__(3); + if (this._eachValues !== undefined) { + value = value + ._then(this._eachComplete, undefined, undefined, this, undefined); + } + value._then(completed, completed, undefined, value, this); +}; -var ReactCurrentOwner = __webpack_require__(14); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstanceMap = __webpack_require__(34); +Promise.prototype.reduce = function (fn, initialValue) { + return reduce(this, fn, initialValue, null); +}; -var getHostComponentFromComposite = __webpack_require__(105); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +Promise.reduce = function (promises, fn, initialValue, _each) { + return reduce(promises, fn, initialValue, _each); +}; -/** - * Returns the DOM node rendered by this element. - * - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.finddomnode - * - * @param {ReactComponent|DOMElement} componentOrElement - * @return {?DOMElement} The root node of this element. - */ -function findDOMNode(componentOrElement) { - if (process.env.NODE_ENV !== 'production') { - var owner = ReactCurrentOwner.current; - if (owner !== null) { - process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing findDOMNode inside its render(). ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; - owner._warnedAboutRefsInRender = true; +function completed(valueOrReason, array) { + if (this.isFulfilled()) { + array._resolve(valueOrReason); + } else { + array._reject(valueOrReason); } - } - if (componentOrElement == null) { - return null; - } - if (componentOrElement.nodeType === 1) { - return componentOrElement; - } +} - var inst = ReactInstanceMap.get(componentOrElement); - if (inst) { - inst = getHostComponentFromComposite(inst); - return inst ? ReactDOMComponentTree.getNodeFromInstance(inst) : null; - } +function reduce(promises, fn, initialValue, _each) { + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + var array = new ReductionPromiseArray(promises, fn, initialValue, _each); + return array.promise(); +} - if (typeof componentOrElement.render === 'function') { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'findDOMNode was called on an unmounted component.') : _prodInvariant('44') : void 0; - } else { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element appears to be neither ReactComponent nor DOMNode (keys: %s)', Object.keys(componentOrElement)) : _prodInvariant('45', Object.keys(componentOrElement)) : void 0; - } +function gotAccum(accum) { + this.accum = accum; + this.array._gotAccum(accum); + var value = tryConvertToPromise(this.value, this.array._promise); + if (value instanceof Promise) { + this.array._currentCancellable = value; + return value._then(gotValue, undefined, undefined, this, undefined); + } else { + return gotValue.call(this, value); + } } -module.exports = findDOMNode; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function gotValue(value) { + var array = this.array; + var promise = array._promise; + var fn = tryCatch(array._fn); + promise._pushContext(); + var ret; + if (array._eachValues !== undefined) { + ret = fn.call(promise._boundValue(), value, this.index, this.length); + } else { + ret = fn.call(promise._boundValue(), + this.accum, value, this.index, this.length); + } + if (ret instanceof Promise) { + array._currentCancellable = ret; + } + var promiseCreated = promise._popContext(); + debug.checkForgottenReturns( + ret, + promiseCreated, + array._eachValues !== undefined ? "Promise.each" : "Promise.reduce", + promise + ); + return ret; +} +}; -/***/ }), -/* 216 */ -/***/ (function(module, exports, __webpack_require__) { +},{"./util":36}],29:[function(_dereq_,module,exports){ +"use strict"; +var util = _dereq_("./util"); +var schedule; +var noAsyncScheduler = function() { + throw new Error("No async scheduler available\u000a\u000a See http://goo.gl/MqrFmX\u000a"); +}; +var NativePromise = util.getNativePromise(); +if (util.isNode && typeof MutationObserver === "undefined") { + var GlobalSetImmediate = global.setImmediate; + var ProcessNextTick = process.nextTick; + schedule = util.isRecentNode + ? function(fn) { GlobalSetImmediate.call(global, fn); } + : function(fn) { ProcessNextTick.call(process, fn); }; +} else if (typeof NativePromise === "function" && + typeof NativePromise.resolve === "function") { + var nativePromise = NativePromise.resolve(); + schedule = function(fn) { + nativePromise.then(fn); + }; +} else if ((typeof MutationObserver !== "undefined") && + !(typeof window !== "undefined" && + window.navigator && + (window.navigator.standalone || window.cordova))) { + schedule = (function() { + var div = document.createElement("div"); + var opts = {attributes: true}; + var toggleScheduled = false; + var div2 = document.createElement("div"); + var o2 = new MutationObserver(function() { + div.classList.toggle("foo"); + toggleScheduled = false; + }); + o2.observe(div2, opts); + var scheduleToggle = function() { + if (toggleScheduled) return; + toggleScheduled = true; + div2.classList.toggle("foo"); + }; + + return function schedule(fn) { + var o = new MutationObserver(function() { + o.disconnect(); + fn(); + }); + o.observe(div, opts); + scheduleToggle(); + }; + })(); +} else if (typeof setImmediate !== "undefined") { + schedule = function (fn) { + setImmediate(fn); + }; +} else if (typeof setTimeout !== "undefined") { + schedule = function (fn) { + setTimeout(fn, 0); + }; +} else { + schedule = noAsyncScheduler; +} +module.exports = schedule; + +},{"./util":36}],30:[function(_dereq_,module,exports){ "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = + function(Promise, PromiseArray, debug) { +var PromiseInspection = Promise.PromiseInspection; +var util = _dereq_("./util"); +function SettledPromiseArray(values) { + this.constructor$(values); +} +util.inherits(SettledPromiseArray, PromiseArray); +SettledPromiseArray.prototype._promiseResolved = function (index, inspection) { + this._values[index] = inspection; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + this._resolve(this._values); + return true; + } + return false; +}; -var ReactMount = __webpack_require__(104); +SettledPromiseArray.prototype._promiseFulfilled = function (value, index) { + var ret = new PromiseInspection(); + ret._bitField = 33554432; + ret._settledValueField = value; + return this._promiseResolved(index, ret); +}; +SettledPromiseArray.prototype._promiseRejected = function (reason, index) { + var ret = new PromiseInspection(); + ret._bitField = 16777216; + ret._settledValueField = reason; + return this._promiseResolved(index, ret); +}; -module.exports = ReactMount.renderSubtreeIntoContainer; +Promise.settle = function (promises) { + debug.deprecated(".settle()", ".reflect()"); + return new SettledPromiseArray(promises).promise(); +}; -/***/ }), -/* 217 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype.settle = function () { + return Promise.settle(this); +}; +}; +},{"./util":36}],31:[function(_dereq_,module,exports){ "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +module.exports = +function(Promise, PromiseArray, apiRejection) { +var util = _dereq_("./util"); +var RangeError = _dereq_("./errors").RangeError; +var AggregateError = _dereq_("./errors").AggregateError; +var isArray = util.isArray; +var CANCELLATION = {}; + + +function SomePromiseArray(values) { + this.constructor$(values); + this._howMany = 0; + this._unwrap = false; + this._initialized = false; +} +util.inherits(SomePromiseArray, PromiseArray); +SomePromiseArray.prototype._init = function () { + if (!this._initialized) { + return; + } + if (this._howMany === 0) { + this._resolve([]); + return; + } + this._init$(undefined, -5); + var isArrayResolved = isArray(this._values); + if (!this._isResolved() && + isArrayResolved && + this._howMany > this._canPossiblyFulfill()) { + this._reject(this._getRangeError(this.length())); + } +}; -var DOMProperty = __webpack_require__(17); -var EventPluginRegistry = __webpack_require__(40); -var ReactComponentTreeHook = __webpack_require__(10); +SomePromiseArray.prototype.init = function () { + this._initialized = true; + this._init(); +}; -var warning = __webpack_require__(2); +SomePromiseArray.prototype.setUnwrap = function () { + this._unwrap = true; +}; -if (process.env.NODE_ENV !== 'production') { - var reactProps = { - children: true, - dangerouslySetInnerHTML: true, - key: true, - ref: true, +SomePromiseArray.prototype.howMany = function () { + return this._howMany; +}; - autoFocus: true, - defaultValue: true, - valueLink: true, - defaultChecked: true, - checkedLink: true, - innerHTML: true, - suppressContentEditableWarning: true, - onFocusIn: true, - onFocusOut: true - }; - var warnedProperties = {}; +SomePromiseArray.prototype.setHowMany = function (count) { + this._howMany = count; +}; - var validateProperty = function (tagName, name, debugID) { - if (DOMProperty.properties.hasOwnProperty(name) || DOMProperty.isCustomAttribute(name)) { - return true; +SomePromiseArray.prototype._promiseFulfilled = function (value) { + this._addFulfilled(value); + if (this._fulfilled() === this.howMany()) { + this._values.length = this.howMany(); + if (this.howMany() === 1 && this._unwrap) { + this._resolve(this._values[0]); + } else { + this._resolve(this._values); + } + return true; } - if (reactProps.hasOwnProperty(name) && reactProps[name] || warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { - return true; + return false; + +}; +SomePromiseArray.prototype._promiseRejected = function (reason) { + this._addRejected(reason); + return this._checkOutcome(); +}; + +SomePromiseArray.prototype._promiseCancelled = function () { + if (this._values instanceof Promise || this._values == null) { + return this._cancel(); } - if (EventPluginRegistry.registrationNameModules.hasOwnProperty(name)) { - return true; + this._addRejected(CANCELLATION); + return this._checkOutcome(); +}; + +SomePromiseArray.prototype._checkOutcome = function() { + if (this.howMany() > this._canPossiblyFulfill()) { + var e = new AggregateError(); + for (var i = this.length(); i < this._values.length; ++i) { + if (this._values[i] !== CANCELLATION) { + e.push(this._values[i]); + } + } + if (e.length > 0) { + this._reject(e); + } else { + this._cancel(); + } + return true; } - warnedProperties[name] = true; - var lowerCasedName = name.toLowerCase(); + return false; +}; - // data-* attributes should be lowercase; suggest the lowercase version - var standardName = DOMProperty.isCustomAttribute(lowerCasedName) ? lowerCasedName : DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; +SomePromiseArray.prototype._fulfilled = function () { + return this._totalResolved; +}; - var registrationName = EventPluginRegistry.possibleRegistrationNames.hasOwnProperty(lowerCasedName) ? EventPluginRegistry.possibleRegistrationNames[lowerCasedName] : null; +SomePromiseArray.prototype._rejected = function () { + return this._values.length - this.length(); +}; - if (standardName != null) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown DOM property %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - return true; - } else if (registrationName != null) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown event handler property %s. Did you mean `%s`?%s', name, registrationName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - return true; - } else { - // We were unable to guess which prop the user intended. - // It is likely that the user was just blindly spreading/forwarding props - // Components should be careful to only render valid props/attributes. - // Warning will be invoked in warnUnknownProperties to allow grouping. - return false; - } - }; -} +SomePromiseArray.prototype._addRejected = function (reason) { + this._values.push(reason); +}; -var warnUnknownProperties = function (debugID, element) { - var unknownProps = []; - for (var key in element.props) { - var isValid = validateProperty(element.type, key, debugID); - if (!isValid) { - unknownProps.push(key); - } - } +SomePromiseArray.prototype._addFulfilled = function (value) { + this._values[this._totalResolved++] = value; +}; - var unknownPropString = unknownProps.map(function (prop) { - return '`' + prop + '`'; - }).join(', '); +SomePromiseArray.prototype._canPossiblyFulfill = function () { + return this.length() - this._rejected(); +}; - if (unknownProps.length === 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown prop %s on <%s> tag. Remove this prop from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } else if (unknownProps.length > 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown props %s on <%s> tag. Remove these props from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } +SomePromiseArray.prototype._getRangeError = function (count) { + var message = "Input array must contain at least " + + this._howMany + " items but contains only " + count + " items"; + return new RangeError(message); }; -function handleElement(debugID, element) { - if (element == null || typeof element.type !== 'string') { - return; - } - if (element.type.indexOf('-') >= 0 || element.props.is) { - return; - } - warnUnknownProperties(debugID, element); +SomePromiseArray.prototype._resolveEmptyArray = function () { + this._reject(this._getRangeError(0)); +}; + +function some(promises, howMany) { + if ((howMany | 0) !== howMany || howMany < 0) { + return apiRejection("expecting a positive integer\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + var ret = new SomePromiseArray(promises); + var promise = ret.promise(); + ret.setHowMany(howMany); + ret.init(); + return promise; } -var ReactDOMUnknownPropertyHook = { - onBeforeMountComponent: function (debugID, element) { - handleElement(debugID, element); - }, - onBeforeUpdateComponent: function (debugID, element) { - handleElement(debugID, element); - } +Promise.some = function (promises, howMany) { + return some(promises, howMany); }; -module.exports = ReactDOMUnknownPropertyHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Promise.prototype.some = function (howMany) { + return some(this, howMany); +}; -/***/ }), -/* 218 */ -/***/ (function(module, exports, __webpack_require__) { +Promise._SomePromiseArray = SomePromiseArray; +}; +},{"./errors":12,"./util":36}],32:[function(_dereq_,module,exports){ "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +module.exports = function(Promise) { +function PromiseInspection(promise) { + if (promise !== undefined) { + promise = promise._target(); + this._bitField = promise._bitField; + this._settledValueField = promise._isFateSealed() + ? promise._settledValue() : undefined; + } + else { + this._bitField = 0; + this._settledValueField = undefined; + } +} +PromiseInspection.prototype._settledValue = function() { + return this._settledValueField; +}; +var value = PromiseInspection.prototype.value = function () { + if (!this.isFulfilled()) { + throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + return this._settledValue(); +}; -var ReactComponentTreeHook = __webpack_require__(10); +var reason = PromiseInspection.prototype.error = +PromiseInspection.prototype.reason = function () { + if (!this.isRejected()) { + throw new TypeError("cannot get rejection reason of a non-rejected promise\u000a\u000a See http://goo.gl/MqrFmX\u000a"); + } + return this._settledValue(); +}; -var warning = __webpack_require__(2); +var isFulfilled = PromiseInspection.prototype.isFulfilled = function() { + return (this._bitField & 33554432) !== 0; +}; -var didWarnValueNull = false; +var isRejected = PromiseInspection.prototype.isRejected = function () { + return (this._bitField & 16777216) !== 0; +}; -function handleElement(debugID, element) { - if (element == null) { - return; - } - if (element.type !== 'input' && element.type !== 'textarea' && element.type !== 'select') { - return; - } - if (element.props != null && element.props.value === null && !didWarnValueNull) { - process.env.NODE_ENV !== 'production' ? warning(false, '`value` prop on `%s` should not be null. ' + 'Consider using the empty string to clear the component or `undefined` ' + 'for uncontrolled components.%s', element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; +var isPending = PromiseInspection.prototype.isPending = function () { + return (this._bitField & 50397184) === 0; +}; - didWarnValueNull = true; - } -} +var isResolved = PromiseInspection.prototype.isResolved = function () { + return (this._bitField & 50331648) !== 0; +}; -var ReactDOMNullInputValuePropHook = { - onBeforeMountComponent: function (debugID, element) { - handleElement(debugID, element); - }, - onBeforeUpdateComponent: function (debugID, element) { - handleElement(debugID, element); - } +PromiseInspection.prototype.isCancelled = function() { + return (this._bitField & 8454144) !== 0; }; -module.exports = ReactDOMNullInputValuePropHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Promise.prototype.__isCancelled = function() { + return (this._bitField & 65536) === 65536; +}; -/***/ }), -/* 219 */ -/***/ (function(module, exports, __webpack_require__) { +Promise.prototype._isCancelled = function() { + return this._target().__isCancelled(); +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Promise.prototype.isCancelled = function() { + return (this._target()._bitField & 8454144) !== 0; +}; +Promise.prototype.isPending = function() { + return isPending.call(this._target()); +}; +Promise.prototype.isRejected = function() { + return isRejected.call(this._target()); +}; -var DOMProperty = __webpack_require__(17); -var ReactComponentTreeHook = __webpack_require__(10); +Promise.prototype.isFulfilled = function() { + return isFulfilled.call(this._target()); +}; -var warning = __webpack_require__(2); +Promise.prototype.isResolved = function() { + return isResolved.call(this._target()); +}; -var warnedProperties = {}; -var rARIA = new RegExp('^(aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); +Promise.prototype.value = function() { + return value.call(this._target()); +}; -function validateProperty(tagName, name, debugID) { - if (warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { - return true; - } +Promise.prototype.reason = function() { + var target = this._target(); + target._unsetRejectionIsUnhandled(); + return reason.call(target); +}; - if (rARIA.test(name)) { - var lowerCasedName = name.toLowerCase(); - var standardName = DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; +Promise.prototype._value = function() { + return this._settledValue(); +}; - // If this is an aria-* attribute, but is not listed in the known DOM - // DOM properties, then it is an invalid aria-* attribute. - if (standardName == null) { - warnedProperties[name] = true; - return false; +Promise.prototype._reason = function() { + this._unsetRejectionIsUnhandled(); + return this._settledValue(); +}; + +Promise.PromiseInspection = PromiseInspection; +}; + +},{}],33:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL) { +var util = _dereq_("./util"); +var errorObj = util.errorObj; +var isObject = util.isObject; + +function tryConvertToPromise(obj, context) { + if (isObject(obj)) { + if (obj instanceof Promise) return obj; + var then = getThen(obj); + if (then === errorObj) { + if (context) context._pushContext(); + var ret = Promise.reject(then.e); + if (context) context._popContext(); + return ret; + } else if (typeof then === "function") { + if (isAnyBluebirdPromise(obj)) { + var ret = new Promise(INTERNAL); + obj._then( + ret._fulfill, + ret._reject, + undefined, + ret, + null + ); + return ret; + } + return doThenable(obj, then, context); + } } - // aria-* attributes should be lowercase; suggest the lowercase version. - if (name !== standardName) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown ARIA attribute %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - warnedProperties[name] = true; - return true; + return obj; +} + +function doGetThen(obj) { + return obj.then; +} + +function getThen(obj) { + try { + return doGetThen(obj); + } catch (e) { + errorObj.e = e; + return errorObj; } - } +} - return true; +var hasProp = {}.hasOwnProperty; +function isAnyBluebirdPromise(obj) { + try { + return hasProp.call(obj, "_promise0"); + } catch (e) { + return false; + } } -function warnInvalidARIAProps(debugID, element) { - var invalidProps = []; +function doThenable(x, then, context) { + var promise = new Promise(INTERNAL); + var ret = promise; + if (context) context._pushContext(); + promise._captureStackTrace(); + if (context) context._popContext(); + var synchronous = true; + var result = util.tryCatch(then).call(x, resolve, reject); + synchronous = false; - for (var key in element.props) { - var isValid = validateProperty(element.type, key, debugID); - if (!isValid) { - invalidProps.push(key); + if (promise && result === errorObj) { + promise._rejectCallback(result.e, true, true); + promise = null; } - } - var unknownPropString = invalidProps.map(function (prop) { - return '`' + prop + '`'; - }).join(', '); + function resolve(value) { + if (!promise) return; + promise._resolveCallback(value); + promise = null; + } - if (invalidProps.length === 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria prop %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } else if (invalidProps.length > 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria props %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } + function reject(reason) { + if (!promise) return; + promise._rejectCallback(reason, synchronous, true); + promise = null; + } + return ret; } -function handleElement(debugID, element) { - if (element == null || typeof element.type !== 'string') { - return; - } - if (element.type.indexOf('-') >= 0 || element.props.is) { - return; - } +return tryConvertToPromise; +}; - warnInvalidARIAProps(debugID, element); +},{"./util":36}],34:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function(Promise, INTERNAL, debug) { +var util = _dereq_("./util"); +var TimeoutError = Promise.TimeoutError; + +function HandleWrapper(handle) { + this.handle = handle; } -var ReactDOMInvalidARIAHook = { - onBeforeMountComponent: function (debugID, element) { - if (process.env.NODE_ENV !== 'production') { - handleElement(debugID, element); - } - }, - onBeforeUpdateComponent: function (debugID, element) { - if (process.env.NODE_ENV !== 'production') { - handleElement(debugID, element); +HandleWrapper.prototype._resultCancelled = function() { + clearTimeout(this.handle); +}; + +var afterValue = function(value) { return delay(+this).thenReturn(value); }; +var delay = Promise.delay = function (ms, value) { + var ret; + var handle; + if (value !== undefined) { + ret = Promise.resolve(value) + ._then(afterValue, null, null, ms, undefined); + if (debug.cancellation() && value instanceof Promise) { + ret._setOnCancel(value); + } + } else { + ret = new Promise(INTERNAL); + handle = setTimeout(function() { ret._fulfill(); }, +ms); + if (debug.cancellation()) { + ret._setOnCancel(new HandleWrapper(handle)); + } + ret._captureStackTrace(); } - } + ret._setAsyncGuaranteed(); + return ret; }; -module.exports = ReactDOMInvalidARIAHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Promise.prototype.delay = function (ms) { + return delay(ms, this); +}; -/***/ }), -/* 220 */ -/***/ (function(module, exports, __webpack_require__) { +var afterTimeout = function (promise, message, parent) { + var err; + if (typeof message !== "string") { + if (message instanceof Error) { + err = message; + } else { + err = new TimeoutError("operation timed out"); + } + } else { + err = new TimeoutError(message); + } + util.markAsOriginatingFromRejection(err); + promise._attachExtraTrace(err); + promise._reject(err); -"use strict"; + if (parent != null) { + parent.cancel(); + } +}; +function successClear(value) { + clearTimeout(this.handle); + return value; +} -Object.defineProperty(exports, "__esModule", { - value: true -}); +function failureClear(reason) { + clearTimeout(this.handle); + throw reason; +} -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +Promise.prototype.timeout = function (ms, message) { + ms = +ms; + var ret, parent; -var _react = __webpack_require__(4); + var handleWrapper = new HandleWrapper(setTimeout(function timeoutTimeout() { + if (ret.isPending()) { + afterTimeout(ret, message, parent); + } + }, ms)); -var _react2 = _interopRequireDefault(_react); + if (debug.cancellation()) { + parent = this.then(); + ret = parent._then(successClear, failureClear, + undefined, handleWrapper, undefined); + ret._setOnCancel(handleWrapper); + } else { + ret = this._then(successClear, failureClear, + undefined, handleWrapper, undefined); + } -var _reactstrap = __webpack_require__(66); + return ret; +}; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +}; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +},{"./util":36}],35:[function(_dereq_,module,exports){ +"use strict"; +module.exports = function (Promise, apiRejection, tryConvertToPromise, + createContext, INTERNAL, debug) { + var util = _dereq_("./util"); + var TypeError = _dereq_("./errors").TypeError; + var inherits = _dereq_("./util").inherits; + var errorObj = util.errorObj; + var tryCatch = util.tryCatch; + var NULL = {}; + + function thrower(e) { + setTimeout(function(){throw e;}, 0); + } + + function castPreservingDisposable(thenable) { + var maybePromise = tryConvertToPromise(thenable); + if (maybePromise !== thenable && + typeof thenable._isDisposable === "function" && + typeof thenable._getDisposer === "function" && + thenable._isDisposable()) { + maybePromise._setDisposable(thenable._getDisposer()); + } + return maybePromise; + } + function dispose(resources, inspection) { + var i = 0; + var len = resources.length; + var ret = new Promise(INTERNAL); + function iterator() { + if (i >= len) return ret._fulfill(); + var maybePromise = castPreservingDisposable(resources[i++]); + if (maybePromise instanceof Promise && + maybePromise._isDisposable()) { + try { + maybePromise = tryConvertToPromise( + maybePromise._getDisposer().tryDispose(inspection), + resources.promise); + } catch (e) { + return thrower(e); + } + if (maybePromise instanceof Promise) { + return maybePromise._then(iterator, thrower, + null, null, null); + } + } + iterator(); + } + iterator(); + return ret; + } -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + function Disposer(data, promise, context) { + this._data = data; + this._promise = promise; + this._context = context; + } -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + Disposer.prototype.data = function () { + return this._data; + }; -var ZNavbar = function (_React$Component) { - _inherits(ZNavbar, _React$Component); + Disposer.prototype.promise = function () { + return this._promise; + }; - function ZNavbar(props) { - _classCallCheck(this, ZNavbar); + Disposer.prototype.resource = function () { + if (this.promise().isFulfilled()) { + return this.promise().value(); + } + return NULL; + }; - var _this = _possibleConstructorReturn(this, (ZNavbar.__proto__ || Object.getPrototypeOf(ZNavbar)).call(this, props)); + Disposer.prototype.tryDispose = function(inspection) { + var resource = this.resource(); + var context = this._context; + if (context !== undefined) context._pushContext(); + var ret = resource !== NULL + ? this.doDispose(resource, inspection) : null; + if (context !== undefined) context._popContext(); + this._promise._unsetDisposable(); + this._data = null; + return ret; + }; - _this.toggleNavbar = _this.toggleNavbar.bind(_this); - _this.state = { - isOpen: false + Disposer.isDisposer = function (d) { + return (d != null && + typeof d.resource === "function" && + typeof d.tryDispose === "function"); }; - return _this; - } - _createClass(ZNavbar, [{ - key: 'toggleNavbar', - value: function toggleNavbar() { - this.setState({ - isOpen: !this.state.isOpen - }); - } - }, { - key: 'render', - value: function render() { - return _react2.default.createElement( - _reactstrap.Navbar, - { color: 'faded', light: true, toggleable: true }, - _react2.default.createElement(_reactstrap.NavbarToggler, { right: true, onClick: this.toggleNavbar }), - _react2.default.createElement( - _reactstrap.NavbarBrand, - { href: '/' }, - 'myzenwallet.io' - ), - _react2.default.createElement( - _reactstrap.Collapse, - { isOpen: this.state.isOpen, navbar: true }, - _react2.default.createElement( - _reactstrap.Nav, - { className: 'ml-auto', navbar: true }, - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: 'http://getzen.cash' }, - 'FREE ZEN' - ) - ), - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: '/faq.html' }, - 'FAQ' - ) - ), - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: '/guide.html' }, - 'GETTING STARTED' - ) - ) - ) - ) - ); + function FunctionDisposer(fn, promise, context) { + this.constructor$(fn, promise, context); } - }]); - - return ZNavbar; -}(_react2.default.Component); - -exports.default = ZNavbar; + inherits(FunctionDisposer, Disposer); -/***/ }), -/* 221 */ -/***/ (function(module, exports, __webpack_require__) { + FunctionDisposer.prototype.doDispose = function (resource, inspection) { + var fn = this.data(); + return fn.call(resource, resource, inspection); + }; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ + function maybeUnwrapDisposer(value) { + if (Disposer.isDisposer(value)) { + this.resources[this.index]._setDisposable(value); + return value.promise(); + } + return value; + } + function ResourceList(length) { + this.length = length; + this.promise = null; + this[length-1] = null; + } + ResourceList.prototype._resultCancelled = function() { + var len = this.length; + for (var i = 0; i < len; ++i) { + var item = this[i]; + if (item instanceof Promise) { + item.cancel(); + } + } + }; -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); -var ReactPropTypesSecret = __webpack_require__(49); + Promise.using = function () { + var len = arguments.length; + if (len < 2) return apiRejection( + "you must pass at least 2 arguments to Promise.using"); + var fn = arguments[len - 1]; + if (typeof fn !== "function") { + return apiRejection("expecting a function but got " + util.classString(fn)); + } + var input; + var spreadArgs = true; + if (len === 2 && Array.isArray(arguments[0])) { + input = arguments[0]; + len = input.length; + spreadArgs = false; + } else { + input = arguments; + len--; + } + var resources = new ResourceList(len); + for (var i = 0; i < len; ++i) { + var resource = input[i]; + if (Disposer.isDisposer(resource)) { + var disposer = resource; + resource = resource.promise(); + resource._setDisposable(disposer); + } else { + var maybePromise = tryConvertToPromise(resource); + if (maybePromise instanceof Promise) { + resource = + maybePromise._then(maybeUnwrapDisposer, null, null, { + resources: resources, + index: i + }, undefined); + } + } + resources[i] = resource; + } -module.exports = function() { - function shim(props, propName, componentName, location, propFullName, secret) { - if (secret === ReactPropTypesSecret) { - // It is still safe when called from React. - return; - } - invariant( - false, - 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + - 'Use PropTypes.checkPropTypes() to call them. ' + - 'Read more at http://fb.me/use-check-prop-types' - ); - }; - shim.isRequired = shim; - function getShim() { - return shim; - }; - // Important! - // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`. - var ReactPropTypes = { - array: shim, - bool: shim, - func: shim, - number: shim, - object: shim, - string: shim, - symbol: shim, + var reflectedResources = new Array(resources.length); + for (var i = 0; i < reflectedResources.length; ++i) { + reflectedResources[i] = Promise.resolve(resources[i]).reflect(); + } - any: shim, - arrayOf: getShim, - element: shim, - instanceOf: getShim, - node: shim, - objectOf: getShim, - oneOf: getShim, - oneOfType: getShim, - shape: getShim - }; + var resultPromise = Promise.all(reflectedResources) + .then(function(inspections) { + for (var i = 0; i < inspections.length; ++i) { + var inspection = inspections[i]; + if (inspection.isRejected()) { + errorObj.e = inspection.error(); + return errorObj; + } else if (!inspection.isFulfilled()) { + resultPromise.cancel(); + return; + } + inspections[i] = inspection.value(); + } + promise._pushContext(); + + fn = tryCatch(fn); + var ret = spreadArgs + ? fn.apply(undefined, inspections) : fn(inspections); + var promiseCreated = promise._popContext(); + debug.checkForgottenReturns( + ret, promiseCreated, "Promise.using", promise); + return ret; + }); - ReactPropTypes.checkPropTypes = emptyFunction; - ReactPropTypes.PropTypes = ReactPropTypes; + var promise = resultPromise.lastly(function() { + var inspection = new Promise.PromiseInspection(resultPromise); + return dispose(resources, inspection); + }); + resources.promise = promise; + promise._setOnCancel(resources); + return promise; + }; - return ReactPropTypes; -}; + Promise.prototype._setDisposable = function (disposer) { + this._bitField = this._bitField | 131072; + this._disposer = disposer; + }; + Promise.prototype._isDisposable = function () { + return (this._bitField & 131072) > 0; + }; -/***/ }), -/* 222 */ -/***/ (function(module, exports) { + Promise.prototype._getDisposer = function () { + return this._disposer; + }; -/** - * lodash 3.0.2 (Custom Build) <https://lodash.com/> - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license <https://lodash.com/license> - */ + Promise.prototype._unsetDisposable = function () { + this._bitField = this._bitField & (~131072); + this._disposer = undefined; + }; -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(1); - * // => false - */ -function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} + Promise.prototype.disposer = function (fn) { + if (typeof fn === "function") { + return new FunctionDisposer(fn, this, createContext()); + } + throw new TypeError(); + }; -module.exports = isObject; +}; +},{"./errors":12,"./util":36}],36:[function(_dereq_,module,exports){ +"use strict"; +var es5 = _dereq_("./es5"); +var canEvaluate = typeof navigator == "undefined"; -/***/ }), -/* 223 */ -/***/ (function(module, exports) { +var errorObj = {e: {}}; +var tryCatchTarget; +var globalObject = typeof self !== "undefined" ? self : + typeof window !== "undefined" ? window : + typeof global !== "undefined" ? global : + this !== undefined ? this : null; -/** - * lodash 3.0.8 (Custom Build) <https://lodash.com/> - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation <http://dojofoundation.org/> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license <https://lodash.com/license> - */ +function tryCatcher() { + try { + var target = tryCatchTarget; + tryCatchTarget = null; + return target.apply(this, arguments); + } catch (e) { + errorObj.e = e; + return errorObj; + } +} +function tryCatch(fn) { + tryCatchTarget = fn; + return tryCatcher; +} -/** `Object#toString` result references. */ -var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; +var inherits = function(Child, Parent) { + var hasProp = {}.hasOwnProperty; + + function T() { + this.constructor = Child; + this.constructor$ = Parent; + for (var propertyName in Parent.prototype) { + if (hasProp.call(Parent.prototype, propertyName) && + propertyName.charAt(propertyName.length-1) !== "$" + ) { + this[propertyName + "$"] = Parent.prototype[propertyName]; + } + } + } + T.prototype = Parent.prototype; + Child.prototype = new T(); + return Child.prototype; +}; -/** Used for built-in method references. */ -var objectProto = Object.prototype; -/** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; +function isPrimitive(val) { + return val == null || val === true || val === false || + typeof val === "string" || typeof val === "number"; -/** - * Checks if `value` is classified as a `Function` object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false - */ -function isFunction(value) { - // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 8 which returns 'object' for typed array constructors, and - // PhantomJS 1.9 which returns 'function' for `NodeList` instances. - var tag = isObject(value) ? objectToString.call(value) : ''; - return tag == funcTag || tag == genTag; } -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); + return typeof value === "function" || + typeof value === "object" && value !== null; } -module.exports = isFunction; +function maybeWrapAsError(maybeError) { + if (!isPrimitive(maybeError)) return maybeError; + return new Error(safeToString(maybeError)); +} -/***/ }), -/* 224 */ -/***/ (function(module, exports, __webpack_require__) { +function withAppended(target, appendee) { + var len = target.length; + var ret = new Array(len + 1); + var i; + for (i = 0; i < len; ++i) { + ret[i] = target[i]; + } + ret[i] = appendee; + return ret; +} -var require;var require;/*! tether 1.3.4 */ -(function(f){if(true){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Tether = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ -'use strict'; +function getDataPropertyOrDefault(obj, key, defaultValue) { + if (es5.isES5) { + var desc = Object.getOwnPropertyDescriptor(obj, key); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } + if (desc != null) { + return desc.get == null && desc.set == null + ? desc.value + : defaultValue; + } + } else { + return {}.hasOwnProperty.call(obj, key) ? obj[key] : undefined; + } +} -var _utils = require('./utils'); +function notEnumerableProp(obj, name, value) { + if (isPrimitive(obj)) return obj; + var descriptor = { + value: value, + configurable: true, + enumerable: false, + writable: true + }; + es5.defineProperty(obj, name, descriptor); + return obj; +} -var _utils2 = _interopRequireDefault(_utils); +function thrower(r) { + throw r; +} -var _TetherBase$Utils = _utils2['default'].Utils; -var getBounds = _TetherBase$Utils.getBounds; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; +var inheritedDataKeys = (function() { + var excludedPrototypes = [ + Array.prototype, + Object.prototype, + Function.prototype + ]; + + var isExcludedProto = function(val) { + for (var i = 0; i < excludedPrototypes.length; ++i) { + if (excludedPrototypes[i] === val) { + return true; + } + } + return false; + }; -_utils2['default'].modules.push({ - position: function position(_ref) { - var _this = this; + if (es5.isES5) { + var getKeys = Object.getOwnPropertyNames; + return function(obj) { + var ret = []; + var visitedKeys = Object.create(null); + while (obj != null && !isExcludedProto(obj)) { + var keys; + try { + keys = getKeys(obj); + } catch (e) { + return ret; + } + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + if (visitedKeys[key]) continue; + visitedKeys[key] = true; + var desc = Object.getOwnPropertyDescriptor(obj, key); + if (desc != null && desc.get == null && desc.set == null) { + ret.push(key); + } + } + obj = es5.getPrototypeOf(obj); + } + return ret; + }; + } else { + var hasProp = {}.hasOwnProperty; + return function(obj) { + if (isExcludedProto(obj)) return []; + var ret = []; + + /*jshint forin:false */ + enumeration: for (var key in obj) { + if (hasProp.call(obj, key)) { + ret.push(key); + } else { + for (var i = 0; i < excludedPrototypes.length; ++i) { + if (hasProp.call(excludedPrototypes[i], key)) { + continue enumeration; + } + } + ret.push(key); + } + } + return ret; + }; + } - var top = _ref.top; - var left = _ref.left; +})(); - var _cache = this.cache('element-bounds', function () { - return getBounds(_this.element); - }); +var thisAssignmentPattern = /this\s*\.\s*\S+\s*=/; +function isClass(fn) { + try { + if (typeof fn === "function") { + var keys = es5.names(fn.prototype); + + var hasMethods = es5.isES5 && keys.length > 1; + var hasMethodsOtherThanConstructor = keys.length > 0 && + !(keys.length === 1 && keys[0] === "constructor"); + var hasThisAssignmentAndStaticMethods = + thisAssignmentPattern.test(fn + "") && es5.names(fn).length > 0; + + if (hasMethods || hasMethodsOtherThanConstructor || + hasThisAssignmentAndStaticMethods) { + return true; + } + } + return false; + } catch (e) { + return false; + } +} - var height = _cache.height; - var width = _cache.width; +function toFastProperties(obj) { + /*jshint -W027,-W055,-W031*/ + function FakeConstructor() {} + FakeConstructor.prototype = obj; + var l = 8; + while (l--) new FakeConstructor(); + return obj; + eval(obj); +} - var targetPos = this.getTargetBounds(); +var rident = /^[a-z$_][a-z$_0-9]*$/i; +function isIdentifier(str) { + return rident.test(str); +} - var bottom = top + height; - var right = left + width; +function filledRange(count, prefix, suffix) { + var ret = new Array(count); + for(var i = 0; i < count; ++i) { + ret[i] = prefix + i + suffix; + } + return ret; +} - var abutted = []; - if (top <= targetPos.bottom && bottom >= targetPos.top) { - ['left', 'right'].forEach(function (side) { - var targetPosSide = targetPos[side]; - if (targetPosSide === left || targetPosSide === right) { - abutted.push(side); - } - }); +function safeToString(obj) { + try { + return obj + ""; + } catch (e) { + return "[no string representation]"; } +} - if (left <= targetPos.right && right >= targetPos.left) { - ['top', 'bottom'].forEach(function (side) { - var targetPosSide = targetPos[side]; - if (targetPosSide === top || targetPosSide === bottom) { - abutted.push(side); - } - }); +function isError(obj) { + return obj !== null && + typeof obj === "object" && + typeof obj.message === "string" && + typeof obj.name === "string"; +} + +function markAsOriginatingFromRejection(e) { + try { + notEnumerableProp(e, "isOperational", true); } + catch(ignore) {} +} - var allClasses = []; - var addClasses = []; +function originatesFromRejection(e) { + if (e == null) return false; + return ((e instanceof Error["__BluebirdErrorTypes__"].OperationalError) || + e["isOperational"] === true); +} - var sides = ['left', 'top', 'right', 'bottom']; - allClasses.push(this.getClass('abutted')); - sides.forEach(function (side) { - allClasses.push(_this.getClass('abutted') + '-' + side); - }); +function canAttachTrace(obj) { + return isError(obj) && es5.propertyIsWritable(obj, "stack"); +} - if (abutted.length) { - addClasses.push(this.getClass('abutted')); +var ensureErrorObject = (function() { + if (!("stack" in new Error())) { + return function(value) { + if (canAttachTrace(value)) return value; + try {throw new Error(safeToString(value));} + catch(err) {return err;} + }; + } else { + return function(value) { + if (canAttachTrace(value)) return value; + return new Error(safeToString(value)); + }; } +})(); - abutted.forEach(function (side) { - addClasses.push(_this.getClass('abutted') + '-' + side); - }); - - defer(function () { - if (!(_this.options.addTargetClasses === false)) { - updateClasses(_this.target, addClasses, allClasses); - } - updateClasses(_this.element, addClasses, allClasses); - }); +function classString(obj) { + return {}.toString.call(obj); +} - return true; - } -}); +function copyDescriptors(from, to, filter) { + var keys = es5.names(from); + for (var i = 0; i < keys.length; ++i) { + var key = keys[i]; + if (filter(key)) { + try { + es5.defineProperty(to, key, es5.getDescriptor(from, key)); + } catch (ignore) {} + } + } +} -},{"./utils":5}],2:[function(require,module,exports){ -'use strict'; +var asArray = function(v) { + if (es5.isArray(v)) { + return v; + } + return null; +}; -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +if (typeof Symbol !== "undefined" && Symbol.iterator) { + var ArrayFrom = typeof Array.from === "function" ? function(v) { + return Array.from(v); + } : function(v) { + var ret = []; + var it = v[Symbol.iterator](); + var itResult; + while (!((itResult = it.next()).done)) { + ret.push(itResult.value); + } + return ret; + }; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } + asArray = function(v) { + if (es5.isArray(v)) { + return v; + } else if (v != null && typeof v[Symbol.iterator] === "function") { + return ArrayFrom(v); + } + return null; + }; +} -var _utils = require('./utils'); +var isNode = typeof process !== "undefined" && + classString(process).toLowerCase() === "[object process]"; -var _utils2 = _interopRequireDefault(_utils); +var hasEnvVariables = typeof process !== "undefined" && + typeof process.env !== "undefined"; -var _TetherBase$Utils = _utils2['default'].Utils; -var getBounds = _TetherBase$Utils.getBounds; -var extend = _TetherBase$Utils.extend; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; +function env(key) { + return hasEnvVariables ? process.env[key] : undefined; +} -var BOUNDS_FORMAT = ['left', 'top', 'right', 'bottom']; +function getNativePromise() { + if (typeof Promise === "function") { + try { + var promise = new Promise(function(){}); + if ({}.toString.call(promise) === "[object Promise]") { + return Promise; + } + } catch (e) {} + } +} -function getBoundingRect(tether, to) { - if (to === 'scrollParent') { - to = tether.scrollParents[0]; - } else if (to === 'window') { - to = [pageXOffset, pageYOffset, innerWidth + pageXOffset, innerHeight + pageYOffset]; - } +function domainBind(self, cb) { + return self.bind(cb); +} - if (to === document) { - to = to.documentElement; - } +var ret = { + isClass: isClass, + isIdentifier: isIdentifier, + inheritedDataKeys: inheritedDataKeys, + getDataPropertyOrDefault: getDataPropertyOrDefault, + thrower: thrower, + isArray: es5.isArray, + asArray: asArray, + notEnumerableProp: notEnumerableProp, + isPrimitive: isPrimitive, + isObject: isObject, + isError: isError, + canEvaluate: canEvaluate, + errorObj: errorObj, + tryCatch: tryCatch, + inherits: inherits, + withAppended: withAppended, + maybeWrapAsError: maybeWrapAsError, + toFastProperties: toFastProperties, + filledRange: filledRange, + toString: safeToString, + canAttachTrace: canAttachTrace, + ensureErrorObject: ensureErrorObject, + originatesFromRejection: originatesFromRejection, + markAsOriginatingFromRejection: markAsOriginatingFromRejection, + classString: classString, + copyDescriptors: copyDescriptors, + hasDevTools: typeof chrome !== "undefined" && chrome && + typeof chrome.loadTimes === "function", + isNode: isNode, + hasEnvVariables: hasEnvVariables, + env: env, + global: globalObject, + getNativePromise: getNativePromise, + domainBind: domainBind +}; +ret.isRecentNode = ret.isNode && (function() { + var version = process.versions.node.split(".").map(Number); + return (version[0] === 0 && version[1] > 10) || (version[0] > 0); +})(); - if (typeof to.nodeType !== 'undefined') { - (function () { - var node = to; - var size = getBounds(to); - var pos = size; - var style = getComputedStyle(to); +if (ret.isNode) ret.toFastProperties(process); - to = [pos.left, pos.top, size.width + pos.left, size.height + pos.top]; +try {throw new Error(); } catch (e) {ret.lastLineError = e;} +module.exports = ret; - // Account any parent Frames scroll offset - if (node.ownerDocument !== document) { - var win = node.ownerDocument.defaultView; - to[0] += win.pageXOffset; - to[1] += win.pageYOffset; - to[2] += win.pageXOffset; - to[3] += win.pageYOffset; - } +},{"./es5":13}]},{},[4])(4) +}); ;if (typeof window !== 'undefined' && window !== null) { window.P = window.Promise; } else if (typeof self !== 'undefined' && self !== null) { self.P = self.Promise; } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0), __webpack_require__(24), __webpack_require__(164).setImmediate)) - BOUNDS_FORMAT.forEach(function (side, i) { - side = side[0].toUpperCase() + side.substr(1); - if (side === 'Top' || side === 'Left') { - to[i] += parseFloat(style['border' + side + 'Width']); - } else { - to[i] -= parseFloat(style['border' + side + 'Width']); - } - }); - })(); - } +/***/ }), +/* 464 */ +/***/ (function(module, exports, __webpack_require__) { - return to; -} +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { -_utils2['default'].modules.push({ - position: function position(_ref) { - var _this = this; +var bitcoinjs = __webpack_require__(200); +var bip32utils = __webpack_require__(495); +var zencashjs = __webpack_require__(160); +var bs58check = __webpack_require__(33); - var top = _ref.top; - var left = _ref.left; - var targetAttachment = _ref.targetAttachment; +// Hierarchical Deterministic wallet +function phraseToHDWallet(phraseStr) { + // Seed key, make it fucking strong + // phraseStr: string + var seedHex = Buffer.from(phraseStr).toString('hex'); - if (!this.options.constraints) { - return true; - } + // chains + var hdNode = bitcoinjs.HDNode.fromSeedHex(seedHex); + var chain = new bip32utils.Chain(hdNode); - var _cache = this.cache('element-bounds', function () { - return getBounds(_this.element); - }); + // Creates 42 address from the same chain + for (var k = 0; k < 42; k++) { + chain.next(); + } - var height = _cache.height; - var width = _cache.width; + // Get private keys from them + var privateKeys = chain.getAll().map(function (x) { + return chain.derive(x).keyPair.toWIF(); + }); - if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { - var _lastSize = this.lastSize; + return privateKeys; +} - // Handle the item getting hidden as a result of our positioning without glitching - // the classes in and out - width = _lastSize.width; - height = _lastSize.height; - } +module.exports = { + phraseToHDWallet: phraseToHDWallet +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - var targetSize = this.cache('target-bounds', function () { - return _this.getTargetBounds(); - }); +/***/ }), +/* 465 */ +/***/ (function(module, exports, __webpack_require__) { - var targetHeight = targetSize.height; - var targetWidth = targetSize.width; +var Buffer = __webpack_require__(7).Buffer +var bcrypto = __webpack_require__(44) +var fastMerkleRoot = __webpack_require__(466) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var varuint = __webpack_require__(73) + +var Transaction = __webpack_require__(112) + +function Block () { + this.version = 1 + this.prevHash = null + this.merkleRoot = null + this.timestamp = 0 + this.bits = 0 + this.nonce = 0 +} - var allClasses = [this.getClass('pinned'), this.getClass('out-of-bounds')]; +Block.fromBuffer = function (buffer) { + if (buffer.length < 80) throw new Error('Buffer too small (< 80 bytes)') - this.options.constraints.forEach(function (constraint) { - var outOfBoundsClass = constraint.outOfBoundsClass; - var pinnedClass = constraint.pinnedClass; + var offset = 0 + function readSlice (n) { + offset += n + return buffer.slice(offset - n, offset) + } - if (outOfBoundsClass) { - allClasses.push(outOfBoundsClass); - } - if (pinnedClass) { - allClasses.push(pinnedClass); - } - }); + function readUInt32 () { + var i = buffer.readUInt32LE(offset) + offset += 4 + return i + } - allClasses.forEach(function (cls) { - ['left', 'top', 'right', 'bottom'].forEach(function (side) { - allClasses.push(cls + '-' + side); - }); - }); + function readInt32 () { + var i = buffer.readInt32LE(offset) + offset += 4 + return i + } - var addClasses = []; + var block = new Block() + block.version = readInt32() + block.prevHash = readSlice(32) + block.merkleRoot = readSlice(32) + block.timestamp = readUInt32() + block.bits = readUInt32() + block.nonce = readUInt32() - var tAttachment = extend({}, targetAttachment); - var eAttachment = extend({}, this.attachment); + if (buffer.length === 80) return block - this.options.constraints.forEach(function (constraint) { - var to = constraint.to; - var attachment = constraint.attachment; - var pin = constraint.pin; + function readVarInt () { + var vi = varuint.decode(buffer, offset) + offset += varuint.decode.bytes + return vi + } - if (typeof attachment === 'undefined') { - attachment = ''; - } + function readTransaction () { + var tx = Transaction.fromBuffer(buffer.slice(offset), true) + offset += tx.byteLength() + return tx + } - var changeAttachX = undefined, - changeAttachY = undefined; - if (attachment.indexOf(' ') >= 0) { - var _attachment$split = attachment.split(' '); + var nTransactions = readVarInt() + block.transactions = [] - var _attachment$split2 = _slicedToArray(_attachment$split, 2); + for (var i = 0; i < nTransactions; ++i) { + var tx = readTransaction() + block.transactions.push(tx) + } - changeAttachY = _attachment$split2[0]; - changeAttachX = _attachment$split2[1]; - } else { - changeAttachX = changeAttachY = attachment; - } + return block +} - var bounds = getBoundingRect(_this, to); +Block.prototype.byteLength = function (headersOnly) { + if (headersOnly || !this.transactions) return 80 - if (changeAttachY === 'target' || changeAttachY === 'both') { - if (top < bounds[1] && tAttachment.top === 'top') { - top += targetHeight; - tAttachment.top = 'bottom'; - } + return 80 + varuint.encodingLength(this.transactions.length) + this.transactions.reduce(function (a, x) { + return a + x.byteLength() + }, 0) +} - if (top + height > bounds[3] && tAttachment.top === 'bottom') { - top -= targetHeight; - tAttachment.top = 'top'; - } - } +Block.fromHex = function (hex) { + return Block.fromBuffer(Buffer.from(hex, 'hex')) +} - if (changeAttachY === 'together') { - if (tAttachment.top === 'top') { - if (eAttachment.top === 'bottom' && top < bounds[1]) { - top += targetHeight; - tAttachment.top = 'bottom'; +Block.prototype.getHash = function () { + return bcrypto.hash256(this.toBuffer(true)) +} - top += height; - eAttachment.top = 'top'; - } else if (eAttachment.top === 'top' && top + height > bounds[3] && top - (height - targetHeight) >= bounds[1]) { - top -= height - targetHeight; - tAttachment.top = 'bottom'; +Block.prototype.getId = function () { + return this.getHash().reverse().toString('hex') +} - eAttachment.top = 'bottom'; - } - } +Block.prototype.getUTCDate = function () { + var date = new Date(0) // epoch + date.setUTCSeconds(this.timestamp) - if (tAttachment.top === 'bottom') { - if (eAttachment.top === 'top' && top + height > bounds[3]) { - top -= targetHeight; - tAttachment.top = 'top'; + return date +} - top -= height; - eAttachment.top = 'bottom'; - } else if (eAttachment.top === 'bottom' && top < bounds[1] && top + (height * 2 - targetHeight) <= bounds[3]) { - top += height - targetHeight; - tAttachment.top = 'top'; +// TODO: buffer, offset compatibility +Block.prototype.toBuffer = function (headersOnly) { + var buffer = Buffer.allocUnsafe(this.byteLength(headersOnly)) - eAttachment.top = 'top'; - } - } + var offset = 0 + function writeSlice (slice) { + slice.copy(buffer, offset) + offset += slice.length + } - if (tAttachment.top === 'middle') { - if (top + height > bounds[3] && eAttachment.top === 'top') { - top -= height; - eAttachment.top = 'bottom'; - } else if (top < bounds[1] && eAttachment.top === 'bottom') { - top += height; - eAttachment.top = 'top'; - } - } - } + function writeInt32 (i) { + buffer.writeInt32LE(i, offset) + offset += 4 + } + function writeUInt32 (i) { + buffer.writeUInt32LE(i, offset) + offset += 4 + } - if (changeAttachX === 'target' || changeAttachX === 'both') { - if (left < bounds[0] && tAttachment.left === 'left') { - left += targetWidth; - tAttachment.left = 'right'; - } + writeInt32(this.version) + writeSlice(this.prevHash) + writeSlice(this.merkleRoot) + writeUInt32(this.timestamp) + writeUInt32(this.bits) + writeUInt32(this.nonce) - if (left + width > bounds[2] && tAttachment.left === 'right') { - left -= targetWidth; - tAttachment.left = 'left'; - } - } + if (headersOnly || !this.transactions) return buffer - if (changeAttachX === 'together') { - if (left < bounds[0] && tAttachment.left === 'left') { - if (eAttachment.left === 'right') { - left += targetWidth; - tAttachment.left = 'right'; + varuint.encode(this.transactions.length, buffer, offset) + offset += varuint.encode.bytes - left += width; - eAttachment.left = 'left'; - } else if (eAttachment.left === 'left') { - left += targetWidth; - tAttachment.left = 'right'; + this.transactions.forEach(function (tx) { + var txSize = tx.byteLength() // TODO: extract from toBuffer? + tx.toBuffer(buffer, offset) + offset += txSize + }) - left -= width; - eAttachment.left = 'right'; - } - } else if (left + width > bounds[2] && tAttachment.left === 'right') { - if (eAttachment.left === 'left') { - left -= targetWidth; - tAttachment.left = 'left'; + return buffer +} - left -= width; - eAttachment.left = 'right'; - } else if (eAttachment.left === 'right') { - left -= targetWidth; - tAttachment.left = 'left'; +Block.prototype.toHex = function (headersOnly) { + return this.toBuffer(headersOnly).toString('hex') +} - left += width; - eAttachment.left = 'left'; - } - } else if (tAttachment.left === 'center') { - if (left + width > bounds[2] && eAttachment.left === 'left') { - left -= width; - eAttachment.left = 'right'; - } else if (left < bounds[0] && eAttachment.left === 'right') { - left += width; - eAttachment.left = 'left'; - } - } - } +Block.calculateTarget = function (bits) { + var exponent = ((bits & 0xff000000) >> 24) - 3 + var mantissa = bits & 0x007fffff + var target = Buffer.alloc(32, 0) + target.writeUInt32BE(mantissa, 28 - exponent) + return target +} - if (changeAttachY === 'element' || changeAttachY === 'both') { - if (top < bounds[1] && eAttachment.top === 'bottom') { - top += height; - eAttachment.top = 'top'; - } +Block.calculateMerkleRoot = function (transactions) { + typeforce([{ getHash: types.Function }], transactions) + if (transactions.length === 0) throw TypeError('Cannot compute merkle root for zero transactions') - if (top + height > bounds[3] && eAttachment.top === 'top') { - top -= height; - eAttachment.top = 'bottom'; - } - } + var hashes = transactions.map(function (transaction) { + return transaction.getHash() + }) - if (changeAttachX === 'element' || changeAttachX === 'both') { - if (left < bounds[0]) { - if (eAttachment.left === 'right') { - left += width; - eAttachment.left = 'left'; - } else if (eAttachment.left === 'center') { - left += width / 2; - eAttachment.left = 'left'; - } - } + return fastMerkleRoot(hashes, bcrypto.hash256) +} - if (left + width > bounds[2]) { - if (eAttachment.left === 'left') { - left -= width; - eAttachment.left = 'right'; - } else if (eAttachment.left === 'center') { - left -= width / 2; - eAttachment.left = 'right'; - } - } - } +Block.prototype.checkMerkleRoot = function () { + if (!this.transactions) return false - if (typeof pin === 'string') { - pin = pin.split(',').map(function (p) { - return p.trim(); - }); - } else if (pin === true) { - pin = ['top', 'left', 'right', 'bottom']; - } + var actualMerkleRoot = Block.calculateMerkleRoot(this.transactions) + return this.merkleRoot.compare(actualMerkleRoot) === 0 +} - pin = pin || []; +Block.prototype.checkProofOfWork = function () { + var hash = this.getHash().reverse() + var target = Block.calculateTarget(this.bits) - var pinned = []; - var oob = []; + return hash.compare(target) <= 0 +} - if (top < bounds[1]) { - if (pin.indexOf('top') >= 0) { - top = bounds[1]; - pinned.push('top'); - } else { - oob.push('top'); - } - } +module.exports = Block - if (top + height > bounds[3]) { - if (pin.indexOf('bottom') >= 0) { - top = bounds[3] - height; - pinned.push('bottom'); - } else { - oob.push('bottom'); - } - } - if (left < bounds[0]) { - if (pin.indexOf('left') >= 0) { - left = bounds[0]; - pinned.push('left'); - } else { - oob.push('left'); - } - } +/***/ }), +/* 466 */ +/***/ (function(module, exports, __webpack_require__) { - if (left + width > bounds[2]) { - if (pin.indexOf('right') >= 0) { - left = bounds[2] - width; - pinned.push('right'); - } else { - oob.push('right'); - } - } +/* WEBPACK VAR INJECTION */(function(Buffer) {// constant-space merkle root calculation algorithm +module.exports = function fastRoot (values, digestFn) { + if (!Array.isArray(values)) throw TypeError('Expected values Array') + if (typeof digestFn !== 'function') throw TypeError('Expected digest Function') - if (pinned.length) { - (function () { - var pinnedClass = undefined; - if (typeof _this.options.pinnedClass !== 'undefined') { - pinnedClass = _this.options.pinnedClass; - } else { - pinnedClass = _this.getClass('pinned'); - } + var length = values.length + var results = values.concat() - addClasses.push(pinnedClass); - pinned.forEach(function (side) { - addClasses.push(pinnedClass + '-' + side); - }); - })(); - } + while (length > 1) { + var j = 0 - if (oob.length) { - (function () { - var oobClass = undefined; - if (typeof _this.options.outOfBoundsClass !== 'undefined') { - oobClass = _this.options.outOfBoundsClass; - } else { - oobClass = _this.getClass('out-of-bounds'); - } + for (var i = 0; i < length; i += 2, ++j) { + var left = results[i] + var right = i + 1 === length ? left : results[i + 1] + var data = Buffer.concat([left, right]) - addClasses.push(oobClass); - oob.forEach(function (side) { - addClasses.push(oobClass + '-' + side); - }); - })(); - } + results[j] = digestFn(data) + } - if (pinned.indexOf('left') >= 0 || pinned.indexOf('right') >= 0) { - eAttachment.left = tAttachment.left = false; - } - if (pinned.indexOf('top') >= 0 || pinned.indexOf('bottom') >= 0) { - eAttachment.top = tAttachment.top = false; - } + length = j + } - if (tAttachment.top !== targetAttachment.top || tAttachment.left !== targetAttachment.left || eAttachment.top !== _this.attachment.top || eAttachment.left !== _this.attachment.left) { - _this.updateAttachClasses(eAttachment, tAttachment); - _this.trigger('update', { - attachment: eAttachment, - targetAttachment: tAttachment - }); - } - }); + return results[0] +} - defer(function () { - if (!(_this.options.addTargetClasses === false)) { - updateClasses(_this.target, addClasses, allClasses); - } - updateClasses(_this.element, addClasses, allClasses); - }); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - return { top: top, left: left }; +/***/ }), +/* 467 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var NATIVE = __webpack_require__(111) +var ERRORS = __webpack_require__(201) + +function _Buffer (value) { + return Buffer.isBuffer(value) +} + +function Hex (value) { + return typeof value === 'string' && /^([0-9a-f]{2})+$/i.test(value) +} + +function _LengthN (type, length) { + var name = type.toJSON() + + function Length (value) { + if (!type(value)) return false + if (value.length === length) return true + + throw ERRORS.tfCustomError(name + '(Length: ' + length + ')', name + '(Length: ' + value.length + ')') } -}); + Length.toJSON = function () { return name } -},{"./utils":5}],3:[function(require,module,exports){ -'use strict'; + return Length +} -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +var _ArrayN = _LengthN.bind(null, NATIVE.Array) +var _BufferN = _LengthN.bind(null, _Buffer) +var _HexN = _LengthN.bind(null, Hex) -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +var UINT53_MAX = Math.pow(2, 53) - 1 -var _utils = require('./utils'); +function Finite (value) { + return typeof value === 'number' && isFinite(value) +} +function Int8 (value) { return ((value << 24) >> 24) === value } +function Int16 (value) { return ((value << 16) >> 16) === value } +function Int32 (value) { return (value | 0) === value } +function UInt8 (value) { return (value & 0xff) === value } +function UInt16 (value) { return (value & 0xffff) === value } +function UInt32 (value) { return (value >>> 0) === value } +function UInt53 (value) { + return typeof value === 'number' && + value >= 0 && + value <= UINT53_MAX && + Math.floor(value) === value +} -var _utils2 = _interopRequireDefault(_utils); +var types = { + ArrayN: _ArrayN, + Buffer: _Buffer, + BufferN: _BufferN, + Finite: Finite, + Hex: Hex, + HexN: _HexN, + Int8: Int8, + Int16: Int16, + Int32: Int32, + UInt8: UInt8, + UInt16: UInt16, + UInt32: UInt32, + UInt53: UInt53 +} -_utils2['default'].modules.push({ - position: function position(_ref) { - var top = _ref.top; - var left = _ref.left; +for (var typeName in types) { + types[typeName].toJSON = function (t) { + return t + }.bind(null, typeName) +} - if (!this.options.shift) { - return; - } +module.exports = types - var shift = this.options.shift; - if (typeof this.options.shift === 'function') { - shift = this.options.shift.call(this, { top: top, left: left }); - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - var shiftTop = undefined, - shiftLeft = undefined; - if (typeof shift === 'string') { - shift = shift.split(' '); - shift[1] = shift[1] || shift[0]; +/***/ }), +/* 468 */ +/***/ (function(module, exports, __webpack_require__) { - var _shift = shift; +var OPS = __webpack_require__(16) - var _shift2 = _slicedToArray(_shift, 2); +var map = {} +for (var op in OPS) { + var code = OPS[op] + map[code] = op +} - shiftTop = _shift2[0]; - shiftLeft = _shift2[1]; +module.exports = map - shiftTop = parseFloat(shiftTop, 10); - shiftLeft = parseFloat(shiftLeft, 10); - } else { - shiftTop = shift.top; - shiftLeft = shift.left; - } - top += shiftTop; - left += shiftLeft; +/***/ }), +/* 469 */ +/***/ (function(module, exports, __webpack_require__) { - return { top: top, left: left }; - } -}); +var decompile = __webpack_require__(14).decompile +var multisig = __webpack_require__(470) +var nullData = __webpack_require__(473) +var pubKey = __webpack_require__(474) +var pubKeyHash = __webpack_require__(477) +var scriptHash = __webpack_require__(479) +var witnessPubKeyHash = __webpack_require__(481) +var witnessScriptHash = __webpack_require__(484) +var witnessCommitment = __webpack_require__(487) + +var types = { + MULTISIG: 'multisig', + NONSTANDARD: 'nonstandard', + NULLDATA: 'nulldata', + P2PK: 'pubkey', + P2PKH: 'pubkeyhash', + P2SH: 'scripthash', + P2WPKH: 'witnesspubkeyhash', + P2WSH: 'witnessscripthash', + WITNESS_COMMITMENT: 'witnesscommitment' +} -},{"./utils":5}],4:[function(require,module,exports){ -/* globals performance */ +function classifyOutput (script) { + if (witnessPubKeyHash.output.check(script)) return types.P2WPKH + if (witnessScriptHash.output.check(script)) return types.P2WSH + if (pubKeyHash.output.check(script)) return types.P2PKH + if (scriptHash.output.check(script)) return types.P2SH -'use strict'; + // XXX: optimization, below functions .decompile before use + var chunks = decompile(script) + if (multisig.output.check(chunks)) return types.MULTISIG + if (pubKey.output.check(chunks)) return types.P2PK + if (witnessCommitment.output.check(chunks)) return types.WITNESS_COMMITMENT + if (nullData.output.check(chunks)) return types.NULLDATA -Object.defineProperty(exports, '__esModule', { - value: true -}); + return types.NONSTANDARD +} -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +function classifyInput (script, allowIncomplete) { + // XXX: optimization, below functions .decompile before use + var chunks = decompile(script) -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); + if (pubKeyHash.input.check(chunks)) return types.P2PKH + if (scriptHash.input.check(chunks, allowIncomplete)) return types.P2SH + if (multisig.input.check(chunks, allowIncomplete)) return types.MULTISIG + if (pubKey.input.check(chunks)) return types.P2PK -var _get = function get(_x6, _x7, _x8) { var _again = true; _function: while (_again) { var object = _x6, property = _x7, receiver = _x8; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x6 = parent; _x7 = property; _x8 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; + return types.NONSTANDARD +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +function classifyWitness (script, allowIncomplete) { + // XXX: optimization, below functions .decompile before use + var chunks = decompile(script) -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + if (witnessPubKeyHash.input.check(chunks)) return types.P2WPKH + if (witnessScriptHash.input.check(chunks, allowIncomplete)) return types.P2WSH -function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + return types.NONSTANDARD +} -var _utils = require('./utils'); +module.exports = { + classifyInput: classifyInput, + classifyOutput: classifyOutput, + classifyWitness: classifyWitness, + multisig: multisig, + nullData: nullData, + pubKey: pubKey, + pubKeyHash: pubKeyHash, + scriptHash: scriptHash, + witnessPubKeyHash: witnessPubKeyHash, + witnessScriptHash: witnessScriptHash, + witnessCommitment: witnessCommitment, + types: types +} -var _utils2 = _interopRequireDefault(_utils); -require('./constraint'); +/***/ }), +/* 470 */ +/***/ (function(module, exports, __webpack_require__) { -require('./abutment'); +module.exports = { + input: __webpack_require__(471), + output: __webpack_require__(472) +} -require('./shift'); -var _TetherBase$Utils = _utils2['default'].Utils; -var getScrollParents = _TetherBase$Utils.getScrollParents; -var getBounds = _TetherBase$Utils.getBounds; -var getOffsetParent = _TetherBase$Utils.getOffsetParent; -var extend = _TetherBase$Utils.extend; -var addClass = _TetherBase$Utils.addClass; -var removeClass = _TetherBase$Utils.removeClass; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; -var flush = _TetherBase$Utils.flush; -var getScrollBarSize = _TetherBase$Utils.getScrollBarSize; -var removeUtilElements = _TetherBase$Utils.removeUtilElements; -var Evented = _TetherBase$Utils.Evented; +/***/ }), +/* 471 */ +/***/ (function(module, exports, __webpack_require__) { -function within(a, b) { - var diff = arguments.length <= 2 || arguments[2] === undefined ? 1 : arguments[2]; +// OP_0 [signatures ...] - return a + diff >= b && b >= a - diff; +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) + +function partialSignature (value) { + return value === OPS.OP_0 || bscript.isCanonicalSignature(value) } -var transformKey = (function () { - if (typeof document === 'undefined') { - return ''; +function check (script, allowIncomplete) { + var chunks = bscript.decompile(script) + if (chunks.length < 2) return false + if (chunks[0] !== OPS.OP_0) return false + + if (allowIncomplete) { + return chunks.slice(1).every(partialSignature) } - var el = document.createElement('div'); - var transforms = ['transform', 'WebkitTransform', 'OTransform', 'MozTransform', 'msTransform']; - for (var i = 0; i < transforms.length; ++i) { - var key = transforms[i]; - if (el.style[key] !== undefined) { - return key; + return chunks.slice(1).every(bscript.isCanonicalSignature) +} +check.toJSON = function () { return 'multisig input' } + +var EMPTY_BUFFER = Buffer.allocUnsafe(0) + +function encodeStack (signatures, scriptPubKey) { + typeforce([partialSignature], signatures) + + if (scriptPubKey) { + var scriptData = bscript.multisig.output.decode(scriptPubKey) + + if (signatures.length < scriptData.m) { + throw new TypeError('Not enough signatures provided') + } + + if (signatures.length > scriptData.pubKeys.length) { + throw new TypeError('Too many signatures provided') } } -})(); -var tethers = []; + return [].concat(EMPTY_BUFFER, signatures) +} -var position = function position() { - tethers.forEach(function (tether) { - tether.position(false); - }); - flush(); -}; +function encode (signatures, scriptPubKey) { + return bscript.compile(encodeStack(signatures, scriptPubKey)) +} -function now() { - if (typeof performance !== 'undefined' && typeof performance.now !== 'undefined') { - return performance.now(); - } - return +new Date(); +function decodeStack (stack, allowIncomplete) { + typeforce(check, stack, allowIncomplete) + return stack.slice(1) } -(function () { - var lastCall = null; - var lastDuration = null; - var pendingTimeout = null; +function decode (buffer, allowIncomplete) { + var stack = bscript.decompile(buffer) + return decodeStack(stack, allowIncomplete) +} - var tick = function tick() { - if (typeof lastDuration !== 'undefined' && lastDuration > 16) { - // We voluntarily throttle ourselves if we can't manage 60fps - lastDuration = Math.min(lastDuration - 16, 250); +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} - // Just in case this is the last event, remember to position just once more - pendingTimeout = setTimeout(tick, 250); - return; - } - if (typeof lastCall !== 'undefined' && now() - lastCall < 10) { - // Some browsers call events a little too frequently, refuse to run more than is reasonable - return; - } +/***/ }), +/* 472 */ +/***/ (function(module, exports, __webpack_require__) { - if (pendingTimeout != null) { - clearTimeout(pendingTimeout); - pendingTimeout = null; - } +// m [pubKeys ...] n OP_CHECKMULTISIG - lastCall = now(); - position(); - lastDuration = now() - lastCall; - }; +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) +var OP_INT_BASE = OPS.OP_RESERVED // OP_1 - 1 - if (typeof window !== 'undefined' && typeof window.addEventListener !== 'undefined') { - ['resize', 'scroll', 'touchmove'].forEach(function (event) { - window.addEventListener(event, tick); - }); - } -})(); +function check (script, allowIncomplete) { + var chunks = bscript.decompile(script) -var MIRROR_LR = { - center: 'center', - left: 'right', - right: 'left' -}; + if (chunks.length < 4) return false + if (chunks[chunks.length - 1] !== OPS.OP_CHECKMULTISIG) return false + if (!types.Number(chunks[0])) return false + if (!types.Number(chunks[chunks.length - 2])) return false + var m = chunks[0] - OP_INT_BASE + var n = chunks[chunks.length - 2] - OP_INT_BASE -var MIRROR_TB = { - middle: 'middle', - top: 'bottom', - bottom: 'top' -}; + if (m <= 0) return false + if (n > 16) return false + if (m > n) return false + if (n !== chunks.length - 3) return false + if (allowIncomplete) return true -var OFFSET_MAP = { - top: 0, - left: 0, - middle: '50%', - center: '50%', - bottom: '100%', - right: '100%' -}; + var keys = chunks.slice(1, -2) + return keys.every(bscript.isCanonicalPubKey) +} +check.toJSON = function () { return 'multi-sig output' } -var autoToFixedAttachment = function autoToFixedAttachment(attachment, relativeToAttachment) { - var left = attachment.left; - var top = attachment.top; +function encode (m, pubKeys) { + typeforce({ + m: types.Number, + pubKeys: [bscript.isCanonicalPubKey] + }, { + m: m, + pubKeys: pubKeys + }) + + var n = pubKeys.length + if (n < m) throw new TypeError('Not enough pubKeys provided') + + return bscript.compile([].concat( + OP_INT_BASE + m, + pubKeys, + OP_INT_BASE + n, + OPS.OP_CHECKMULTISIG + )) +} - if (left === 'auto') { - left = MIRROR_LR[relativeToAttachment.left]; - } +function decode (buffer, allowIncomplete) { + var chunks = bscript.decompile(buffer) + typeforce(check, chunks, allowIncomplete) - if (top === 'auto') { - top = MIRROR_TB[relativeToAttachment.top]; + return { + m: chunks[0] - OP_INT_BASE, + pubKeys: chunks.slice(1, -2) } +} - return { left: left, top: top }; -}; +module.exports = { + check: check, + decode: decode, + encode: encode +} -var attachmentToOffset = function attachmentToOffset(attachment) { - var left = attachment.left; - var top = attachment.top; - if (typeof OFFSET_MAP[attachment.left] !== 'undefined') { - left = OFFSET_MAP[attachment.left]; - } +/***/ }), +/* 473 */ +/***/ (function(module, exports, __webpack_require__) { - if (typeof OFFSET_MAP[attachment.top] !== 'undefined') { - top = OFFSET_MAP[attachment.top]; - } +// OP_RETURN {data} - return { left: left, top: top }; -}; +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) -function addOffset() { - var out = { top: 0, left: 0 }; +function check (script) { + var buffer = bscript.compile(script) - for (var _len = arguments.length, offsets = Array(_len), _key = 0; _key < _len; _key++) { - offsets[_key] = arguments[_key]; - } + return buffer.length > 1 && + buffer[0] === OPS.OP_RETURN +} +check.toJSON = function () { return 'null data output' } - offsets.forEach(function (_ref) { - var top = _ref.top; - var left = _ref.left; +function encode (data) { + typeforce(types.Buffer, data) - if (typeof top === 'string') { - top = parseFloat(top, 10); - } - if (typeof left === 'string') { - left = parseFloat(left, 10); - } + return bscript.compile([OPS.OP_RETURN, data]) +} - out.top += top; - out.left += left; - }); +function decode (buffer) { + typeforce(check, buffer) - return out; + return buffer.slice(2) } -function offsetToPx(offset, size) { - if (typeof offset.left === 'string' && offset.left.indexOf('%') !== -1) { - offset.left = parseFloat(offset.left, 10) / 100 * size.width; - } - if (typeof offset.top === 'string' && offset.top.indexOf('%') !== -1) { - offset.top = parseFloat(offset.top, 10) / 100 * size.height; +module.exports = { + output: { + check: check, + decode: decode, + encode: encode } +} - return offset; + +/***/ }), +/* 474 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = { + input: __webpack_require__(475), + output: __webpack_require__(476) } -var parseOffset = function parseOffset(value) { - var _value$split = value.split(' '); - var _value$split2 = _slicedToArray(_value$split, 2); +/***/ }), +/* 475 */ +/***/ (function(module, exports, __webpack_require__) { - var top = _value$split2[0]; - var left = _value$split2[1]; +// {signature} - return { top: top, left: left }; -}; -var parseAttachment = parseOffset; +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) -var TetherClass = (function (_Evented) { - _inherits(TetherClass, _Evented); +function check (script) { + var chunks = bscript.decompile(script) - function TetherClass(options) { - var _this = this; + return chunks.length === 1 && + bscript.isCanonicalSignature(chunks[0]) +} +check.toJSON = function () { return 'pubKey input' } - _classCallCheck(this, TetherClass); +function encodeStack (signature) { + typeforce(types.Buffer, signature) + return [signature] +} - _get(Object.getPrototypeOf(TetherClass.prototype), 'constructor', this).call(this); - this.position = this.position.bind(this); +function encode (signature) { + return bscript.compile(encodeStack(signature)) +} - tethers.push(this); +function decodeStack (stack) { + typeforce(check, stack) + return stack[0] +} - this.history = []; +function decode (buffer) { + var stack = bscript.decompile(buffer) + return decodeStack(stack) +} - this.setOptions(options, false); +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} - _utils2['default'].modules.forEach(function (module) { - if (typeof module.initialize !== 'undefined') { - module.initialize.call(_this); - } - }); - this.position(); - } +/***/ }), +/* 476 */ +/***/ (function(module, exports, __webpack_require__) { - _createClass(TetherClass, [{ - key: 'getClass', - value: function getClass() { - var key = arguments.length <= 0 || arguments[0] === undefined ? '' : arguments[0]; - var classes = this.options.classes; +// {pubKey} OP_CHECKSIG - if (typeof classes !== 'undefined' && classes[key]) { - return this.options.classes[key]; - } else if (this.options.classPrefix) { - return this.options.classPrefix + '-' + key; - } else { - return key; - } - } - }, { - key: 'setOptions', - value: function setOptions(options) { - var _this2 = this; +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - var pos = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1]; +function check (script) { + var chunks = bscript.decompile(script) - var defaults = { - offset: '0 0', - targetOffset: '0 0', - targetAttachment: 'auto auto', - classPrefix: 'tether' - }; + return chunks.length === 2 && + bscript.isCanonicalPubKey(chunks[0]) && + chunks[1] === OPS.OP_CHECKSIG +} +check.toJSON = function () { return 'pubKey output' } - this.options = extend(defaults, options); +function encode (pubKey) { + typeforce(bscript.isCanonicalPubKey, pubKey) - var _options = this.options; - var element = _options.element; - var target = _options.target; - var targetModifier = _options.targetModifier; + return bscript.compile([pubKey, OPS.OP_CHECKSIG]) +} - this.element = element; - this.target = target; - this.targetModifier = targetModifier; +function decode (buffer) { + var chunks = bscript.decompile(buffer) + typeforce(check, chunks) - if (this.target === 'viewport') { - this.target = document.body; - this.targetModifier = 'visible'; - } else if (this.target === 'scroll-handle') { - this.target = document.body; - this.targetModifier = 'scroll-handle'; - } + return chunks[0] +} - ['element', 'target'].forEach(function (key) { - if (typeof _this2[key] === 'undefined') { - throw new Error('Tether Error: Both element and target must be defined'); - } +module.exports = { + check: check, + decode: decode, + encode: encode +} - if (typeof _this2[key].jquery !== 'undefined') { - _this2[key] = _this2[key][0]; - } else if (typeof _this2[key] === 'string') { - _this2[key] = document.querySelector(_this2[key]); - } - }); - addClass(this.element, this.getClass('element')); - if (!(this.options.addTargetClasses === false)) { - addClass(this.target, this.getClass('target')); - } +/***/ }), +/* 477 */ +/***/ (function(module, exports, __webpack_require__) { - if (!this.options.attachment) { - throw new Error('Tether Error: You must provide an attachment'); - } +module.exports = { + input: __webpack_require__(204), + output: __webpack_require__(478) +} - this.targetAttachment = parseAttachment(this.options.targetAttachment); - this.attachment = parseAttachment(this.options.attachment); - this.offset = parseOffset(this.options.offset); - this.targetOffset = parseOffset(this.options.targetOffset); - if (typeof this.scrollParents !== 'undefined') { - this.disable(); - } +/***/ }), +/* 478 */ +/***/ (function(module, exports, __webpack_require__) { - if (this.targetModifier === 'scroll-handle') { - this.scrollParents = [this.target]; - } else { - this.scrollParents = getScrollParents(this.target); - } +// OP_DUP OP_HASH160 {pubKeyHash} OP_EQUALVERIFY OP_CHECKSIG - if (!(this.options.enabled === false)) { - this.enable(pos); - } - } - }, { - key: 'getTargetBounds', - value: function getTargetBounds() { - if (typeof this.targetModifier !== 'undefined') { - if (this.targetModifier === 'visible') { - if (this.target === document.body) { - return { top: pageYOffset, left: pageXOffset, height: innerHeight, width: innerWidth }; - } else { - var bounds = getBounds(this.target); +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - var out = { - height: bounds.height, - width: bounds.width, - top: bounds.top, - left: bounds.left - }; +function check (script) { + var buffer = bscript.compile(script) + + return buffer.length === 25 && + buffer[0] === OPS.OP_DUP && + buffer[1] === OPS.OP_HASH160 && + buffer[2] === 0x14 && + buffer[23] === OPS.OP_EQUALVERIFY && + buffer[24] === OPS.OP_CHECKSIG +} +check.toJSON = function () { return 'pubKeyHash output' } + +function encode (pubKeyHash) { + typeforce(types.Hash160bit, pubKeyHash) + + return bscript.compile([ + OPS.OP_DUP, + OPS.OP_HASH160, + pubKeyHash, + OPS.OP_EQUALVERIFY, + OPS.OP_CHECKSIG + ]) +} + +function decode (buffer) { + typeforce(check, buffer) + + return buffer.slice(3, 23) +} + +module.exports = { + check: check, + decode: decode, + encode: encode +} + + +/***/ }), +/* 479 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = { + input: __webpack_require__(205), + output: __webpack_require__(480) +} - out.height = Math.min(out.height, bounds.height - (pageYOffset - bounds.top)); - out.height = Math.min(out.height, bounds.height - (bounds.top + bounds.height - (pageYOffset + innerHeight))); - out.height = Math.min(innerHeight, out.height); - out.height -= 2; - out.width = Math.min(out.width, bounds.width - (pageXOffset - bounds.left)); - out.width = Math.min(out.width, bounds.width - (bounds.left + bounds.width - (pageXOffset + innerWidth))); - out.width = Math.min(innerWidth, out.width); - out.width -= 2; +/***/ }), +/* 480 */ +/***/ (function(module, exports, __webpack_require__) { - if (out.top < pageYOffset) { - out.top = pageYOffset; - } - if (out.left < pageXOffset) { - out.left = pageXOffset; - } +// OP_HASH160 {scriptHash} OP_EQUAL - return out; - } - } else if (this.targetModifier === 'scroll-handle') { - var bounds = undefined; - var target = this.target; - if (target === document.body) { - target = document.documentElement; +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - bounds = { - left: pageXOffset, - top: pageYOffset, - height: innerHeight, - width: innerWidth - }; - } else { - bounds = getBounds(target); - } +function check (script) { + var buffer = bscript.compile(script) - var style = getComputedStyle(target); + return buffer.length === 23 && + buffer[0] === OPS.OP_HASH160 && + buffer[1] === 0x14 && + buffer[22] === OPS.OP_EQUAL +} +check.toJSON = function () { return 'scriptHash output' } - var hasBottomScroll = target.scrollWidth > target.clientWidth || [style.overflow, style.overflowX].indexOf('scroll') >= 0 || this.target !== document.body; +function encode (scriptHash) { + typeforce(types.Hash160bit, scriptHash) - var scrollBottom = 0; - if (hasBottomScroll) { - scrollBottom = 15; - } + return bscript.compile([OPS.OP_HASH160, scriptHash, OPS.OP_EQUAL]) +} - var height = bounds.height - parseFloat(style.borderTopWidth) - parseFloat(style.borderBottomWidth) - scrollBottom; +function decode (buffer) { + typeforce(check, buffer) - var out = { - width: 15, - height: height * 0.975 * (height / target.scrollHeight), - left: bounds.left + bounds.width - parseFloat(style.borderLeftWidth) - 15 - }; + return buffer.slice(2, 22) +} - var fitAdj = 0; - if (height < 408 && this.target === document.body) { - fitAdj = -0.00011 * Math.pow(height, 2) - 0.00727 * height + 22.58; - } +module.exports = { + check: check, + decode: decode, + encode: encode +} - if (this.target !== document.body) { - out.height = Math.max(out.height, 24); - } - var scrollPercentage = this.target.scrollTop / (target.scrollHeight - height); - out.top = scrollPercentage * (height - out.height - fitAdj) + bounds.top + parseFloat(style.borderTopWidth); +/***/ }), +/* 481 */ +/***/ (function(module, exports, __webpack_require__) { - if (this.target === document.body) { - out.height = Math.max(out.height, 24); - } +module.exports = { + input: __webpack_require__(482), + output: __webpack_require__(483) +} - return out; - } - } else { - return getBounds(this.target); - } - } - }, { - key: 'clearCache', - value: function clearCache() { - this._cache = {}; - } - }, { - key: 'cache', - value: function cache(k, getter) { - // More than one module will often need the same DOM info, so - // we keep a cache which is cleared on each position call - if (typeof this._cache === 'undefined') { - this._cache = {}; - } - if (typeof this._cache[k] === 'undefined') { - this._cache[k] = getter.call(this); - } +/***/ }), +/* 482 */ +/***/ (function(module, exports, __webpack_require__) { - return this._cache[k]; - } - }, { - key: 'enable', - value: function enable() { - var _this3 = this; +// {signature} {pubKey} - var pos = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; +var pkh = __webpack_require__(204) - if (!(this.options.addTargetClasses === false)) { - addClass(this.target, this.getClass('enabled')); - } - addClass(this.element, this.getClass('enabled')); - this.enabled = true; +module.exports = { + check: pkh.check, + decodeStack: pkh.decodeStack, + encodeStack: pkh.encodeStack +} - this.scrollParents.forEach(function (parent) { - if (parent !== _this3.target.ownerDocument) { - parent.addEventListener('scroll', _this3.position); - } - }); - if (pos) { - this.position(); - } - } - }, { - key: 'disable', - value: function disable() { - var _this4 = this; +/***/ }), +/* 483 */ +/***/ (function(module, exports, __webpack_require__) { - removeClass(this.target, this.getClass('enabled')); - removeClass(this.element, this.getClass('enabled')); - this.enabled = false; +// OP_0 {pubKeyHash} - if (typeof this.scrollParents !== 'undefined') { - this.scrollParents.forEach(function (parent) { - parent.removeEventListener('scroll', _this4.position); - }); - } - } - }, { - key: 'destroy', - value: function destroy() { - var _this5 = this; +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - this.disable(); +function check (script) { + var buffer = bscript.compile(script) - tethers.forEach(function (tether, i) { - if (tether === _this5) { - tethers.splice(i, 1); - } - }); + return buffer.length === 22 && + buffer[0] === OPS.OP_0 && + buffer[1] === 0x14 +} +check.toJSON = function () { return 'Witness pubKeyHash output' } - // Remove any elements we were using for convenience from the DOM - if (tethers.length === 0) { - removeUtilElements(); - } - } - }, { - key: 'updateAttachClasses', - value: function updateAttachClasses(elementAttach, targetAttach) { - var _this6 = this; +function encode (pubKeyHash) { + typeforce(types.Hash160bit, pubKeyHash) - elementAttach = elementAttach || this.attachment; - targetAttach = targetAttach || this.targetAttachment; - var sides = ['left', 'top', 'bottom', 'right', 'middle', 'center']; + return bscript.compile([OPS.OP_0, pubKeyHash]) +} - if (typeof this._addAttachClasses !== 'undefined' && this._addAttachClasses.length) { - // updateAttachClasses can be called more than once in a position call, so - // we need to clean up after ourselves such that when the last defer gets - // ran it doesn't add any extra classes from previous calls. - this._addAttachClasses.splice(0, this._addAttachClasses.length); - } +function decode (buffer) { + typeforce(check, buffer) - if (typeof this._addAttachClasses === 'undefined') { - this._addAttachClasses = []; - } - var add = this._addAttachClasses; + return buffer.slice(2) +} - if (elementAttach.top) { - add.push(this.getClass('element-attached') + '-' + elementAttach.top); - } - if (elementAttach.left) { - add.push(this.getClass('element-attached') + '-' + elementAttach.left); - } - if (targetAttach.top) { - add.push(this.getClass('target-attached') + '-' + targetAttach.top); - } - if (targetAttach.left) { - add.push(this.getClass('target-attached') + '-' + targetAttach.left); - } +module.exports = { + check: check, + decode: decode, + encode: encode +} - var all = []; - sides.forEach(function (side) { - all.push(_this6.getClass('element-attached') + '-' + side); - all.push(_this6.getClass('target-attached') + '-' + side); - }); - defer(function () { - if (!(typeof _this6._addAttachClasses !== 'undefined')) { - return; - } +/***/ }), +/* 484 */ +/***/ (function(module, exports, __webpack_require__) { - updateClasses(_this6.element, _this6._addAttachClasses, all); - if (!(_this6.options.addTargetClasses === false)) { - updateClasses(_this6.target, _this6._addAttachClasses, all); - } +module.exports = { + input: __webpack_require__(485), + output: __webpack_require__(486) +} - delete _this6._addAttachClasses; - }); - } - }, { - key: 'position', - value: function position() { - var _this7 = this; - var flushChanges = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; +/***/ }), +/* 485 */ +/***/ (function(module, exports, __webpack_require__) { - // flushChanges commits the changes immediately, leave true unless you are positioning multiple - // tethers (in which case call Tether.Utils.flush yourself when you're done) +// {signature} {pubKey} - if (!this.enabled) { - return; - } +var p2sh = __webpack_require__(205) - this.clearCache(); +module.exports = { + check: p2sh.check, + decodeStack: p2sh.decodeStack, + encodeStack: p2sh.encodeStack +} - // Turn 'auto' attachments into the appropriate corner or edge - var targetAttachment = autoToFixedAttachment(this.targetAttachment, this.attachment); - this.updateAttachClasses(this.attachment, targetAttachment); +/***/ }), +/* 486 */ +/***/ (function(module, exports, __webpack_require__) { - var elementPos = this.cache('element-bounds', function () { - return getBounds(_this7.element); - }); +// OP_0 {scriptHash} - var width = elementPos.width; - var height = elementPos.height; +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { - var _lastSize = this.lastSize; +function check (script) { + var buffer = bscript.compile(script) - // We cache the height and width to make it possible to position elements that are - // getting hidden. - width = _lastSize.width; - height = _lastSize.height; - } else { - this.lastSize = { width: width, height: height }; - } + return buffer.length === 34 && + buffer[0] === OPS.OP_0 && + buffer[1] === 0x20 +} +check.toJSON = function () { return 'Witness scriptHash output' } - var targetPos = this.cache('target-bounds', function () { - return _this7.getTargetBounds(); - }); - var targetSize = targetPos; +function encode (scriptHash) { + typeforce(types.Hash256bit, scriptHash) - // Get an actual px offset from the attachment - var offset = offsetToPx(attachmentToOffset(this.attachment), { width: width, height: height }); - var targetOffset = offsetToPx(attachmentToOffset(targetAttachment), targetSize); + return bscript.compile([OPS.OP_0, scriptHash]) +} - var manualOffset = offsetToPx(this.offset, { width: width, height: height }); - var manualTargetOffset = offsetToPx(this.targetOffset, targetSize); +function decode (buffer) { + typeforce(check, buffer) - // Add the manually provided offset - offset = addOffset(offset, manualOffset); - targetOffset = addOffset(targetOffset, manualTargetOffset); + return buffer.slice(2) +} - // It's now our goal to make (element position + offset) == (target position + target offset) - var left = targetPos.left + targetOffset.left - offset.left; - var top = targetPos.top + targetOffset.top - offset.top; +module.exports = { + check: check, + decode: decode, + encode: encode +} - for (var i = 0; i < _utils2['default'].modules.length; ++i) { - var _module2 = _utils2['default'].modules[i]; - var ret = _module2.position.call(this, { - left: left, - top: top, - targetAttachment: targetAttachment, - targetPos: targetPos, - elementPos: elementPos, - offset: offset, - targetOffset: targetOffset, - manualOffset: manualOffset, - manualTargetOffset: manualTargetOffset, - scrollbarSize: scrollbarSize, - attachment: this.attachment - }); - if (ret === false) { - return false; - } else if (typeof ret === 'undefined' || typeof ret !== 'object') { - continue; - } else { - top = ret.top; - left = ret.left; - } - } +/***/ }), +/* 487 */ +/***/ (function(module, exports, __webpack_require__) { - // We describe the position three different ways to give the optimizer - // a chance to decide the best possible way to position the element - // with the fewest repaints. - var next = { - // It's position relative to the page (absolute positioning when - // the element is a child of the body) - page: { - top: top, - left: left - }, +module.exports = { + output: __webpack_require__(488) +} - // It's position relative to the viewport (fixed positioning) - viewport: { - top: top - pageYOffset, - bottom: pageYOffset - top - height + innerHeight, - left: left - pageXOffset, - right: pageXOffset - left - width + innerWidth - } - }; - var doc = this.target.ownerDocument; - var win = doc.defaultView; +/***/ }), +/* 488 */ +/***/ (function(module, exports, __webpack_require__) { - var scrollbarSize = undefined; - if (doc.body.scrollWidth > win.innerWidth) { - scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); - next.viewport.bottom -= scrollbarSize.height; - } +// OP_RETURN {aa21a9ed} {commitment} - if (doc.body.scrollHeight > win.innerHeight) { - scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); - next.viewport.right -= scrollbarSize.width; - } +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) - if (['', 'static'].indexOf(doc.body.style.position) === -1 || ['', 'static'].indexOf(doc.body.parentElement.style.position) === -1) { - // Absolute positioning in the body will be relative to the page, not the 'initial containing block' - next.page.bottom = doc.body.scrollHeight - top - height; - next.page.right = doc.body.scrollWidth - left - width; - } +var HEADER = Buffer.from('aa21a9ed', 'hex') - if (typeof this.options.optimizations !== 'undefined' && this.options.optimizations.moveElement !== false && !(typeof this.targetModifier !== 'undefined')) { - (function () { - var offsetParent = _this7.cache('target-offsetparent', function () { - return getOffsetParent(_this7.target); - }); - var offsetPosition = _this7.cache('target-offsetparent-bounds', function () { - return getBounds(offsetParent); - }); - var offsetParentStyle = getComputedStyle(offsetParent); - var offsetParentSize = offsetPosition; +function check (script) { + var buffer = bscript.compile(script) - var offsetBorder = {}; - ['Top', 'Left', 'Bottom', 'Right'].forEach(function (side) { - offsetBorder[side.toLowerCase()] = parseFloat(offsetParentStyle['border' + side + 'Width']); - }); + return buffer.length > 37 && + buffer[0] === OPS.OP_RETURN && + buffer[1] === 0x24 && + buffer.slice(2, 6).equals(HEADER) +} - offsetPosition.right = doc.body.scrollWidth - offsetPosition.left - offsetParentSize.width + offsetBorder.right; - offsetPosition.bottom = doc.body.scrollHeight - offsetPosition.top - offsetParentSize.height + offsetBorder.bottom; +check.toJSON = function () { return 'Witness commitment output' } - if (next.page.top >= offsetPosition.top + offsetBorder.top && next.page.bottom >= offsetPosition.bottom) { - if (next.page.left >= offsetPosition.left + offsetBorder.left && next.page.right >= offsetPosition.right) { - // We're within the visible part of the target's scroll parent - var scrollTop = offsetParent.scrollTop; - var scrollLeft = offsetParent.scrollLeft; +function encode (commitment) { + typeforce(types.Hash256bit, commitment) - // It's position relative to the target's offset parent (absolute positioning when - // the element is moved to be a child of the target's offset parent). - next.offset = { - top: next.page.top - offsetPosition.top + scrollTop - offsetBorder.top, - left: next.page.left - offsetPosition.left + scrollLeft - offsetBorder.left - }; - } - } - })(); - } + var buffer = Buffer.allocUnsafe(36) + HEADER.copy(buffer, 0) + commitment.copy(buffer, 4) - // We could also travel up the DOM and try each containing context, rather than only - // looking at the body, but we're gonna get diminishing returns. + return bscript.compile([OPS.OP_RETURN, buffer]) +} - this.move(next); +function decode (buffer) { + typeforce(check, buffer) - this.history.unshift(next); + return bscript.decompile(buffer)[1].slice(4, 36) +} - if (this.history.length > 3) { - this.history.pop(); - } +module.exports = { + check: check, + decode: decode, + encode: encode +} - if (flushChanges) { - flush(); - } - return true; - } +/***/ }), +/* 489 */ +/***/ (function(module, exports, __webpack_require__) { - // THE ISSUE - }, { - key: 'move', - value: function move(pos) { - var _this8 = this; +var Buffer = __webpack_require__(7).Buffer +var createHmac = __webpack_require__(67) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) + +var BigInteger = __webpack_require__(30) +var ECSignature = __webpack_require__(115) + +var ZERO = Buffer.alloc(1, 0) +var ONE = Buffer.alloc(1, 1) + +var ecurve = __webpack_require__(116) +var secp256k1 = ecurve.getCurveByName('secp256k1') + +// https://tools.ietf.org/html/rfc6979#section-3.2 +function deterministicGenerateK (hash, x, checkSig) { + typeforce(types.tuple( + types.Hash256bit, + types.Buffer256bit, + types.Function + ), arguments) + + // Step A, ignored as hash already provided + // Step B + // Step C + var k = Buffer.alloc(32, 0) + var v = Buffer.alloc(32, 1) + + // Step D + k = createHmac('sha256', k) + .update(v) + .update(ZERO) + .update(x) + .update(hash) + .digest() + + // Step E + v = createHmac('sha256', k).update(v).digest() + + // Step F + k = createHmac('sha256', k) + .update(v) + .update(ONE) + .update(x) + .update(hash) + .digest() + + // Step G + v = createHmac('sha256', k).update(v).digest() + + // Step H1/H2a, ignored as tlen === qlen (256 bit) + // Step H2b + v = createHmac('sha256', k).update(v).digest() + + var T = BigInteger.fromBuffer(v) + + // Step H3, repeat until T is within the interval [1, n - 1] and is suitable for ECDSA + while (T.signum() <= 0 || T.compareTo(secp256k1.n) >= 0 || !checkSig(T)) { + k = createHmac('sha256', k) + .update(v) + .update(ZERO) + .digest() + + v = createHmac('sha256', k).update(v).digest() + + // Step H1/H2a, again, ignored as tlen === qlen (256 bit) + // Step H2b again + v = createHmac('sha256', k).update(v).digest() + T = BigInteger.fromBuffer(v) + } + + return T +} - if (!(typeof this.element.parentNode !== 'undefined')) { - return; - } +var N_OVER_TWO = secp256k1.n.shiftRight(1) - var same = {}; +function sign (hash, d) { + typeforce(types.tuple(types.Hash256bit, types.BigInt), arguments) - for (var type in pos) { - same[type] = {}; + var x = d.toBuffer(32) + var e = BigInteger.fromBuffer(hash) + var n = secp256k1.n + var G = secp256k1.G - for (var key in pos[type]) { - var found = false; + var r, s + deterministicGenerateK(hash, x, function (k) { + var Q = G.multiply(k) - for (var i = 0; i < this.history.length; ++i) { - var point = this.history[i]; - if (typeof point[type] !== 'undefined' && !within(point[type][key], pos[type][key])) { - found = true; - break; - } - } + if (secp256k1.isInfinity(Q)) return false - if (!found) { - same[type][key] = true; - } - } - } + r = Q.affineX.mod(n) + if (r.signum() === 0) return false - var css = { top: '', left: '', right: '', bottom: '' }; + s = k.modInverse(n).multiply(e.add(d.multiply(r))).mod(n) + if (s.signum() === 0) return false - var transcribe = function transcribe(_same, _pos) { - var hasOptimizations = typeof _this8.options.optimizations !== 'undefined'; - var gpu = hasOptimizations ? _this8.options.optimizations.gpu : null; - if (gpu !== false) { - var yPos = undefined, - xPos = undefined; - if (_same.top) { - css.top = 0; - yPos = _pos.top; - } else { - css.bottom = 0; - yPos = -_pos.bottom; - } + return true + }) - if (_same.left) { - css.left = 0; - xPos = _pos.left; - } else { - css.right = 0; - xPos = -_pos.right; - } + // enforce low S values, see bip62: 'low s values in signatures' + if (s.compareTo(N_OVER_TWO) > 0) { + s = n.subtract(s) + } - css[transformKey] = 'translateX(' + Math.round(xPos) + 'px) translateY(' + Math.round(yPos) + 'px)'; + return new ECSignature(r, s) +} - if (transformKey !== 'msTransform') { - // The Z transform will keep this in the GPU (faster, and prevents artifacts), - // but IE9 doesn't support 3d transforms and will choke. - css[transformKey] += " translateZ(0)"; - } - } else { - if (_same.top) { - css.top = _pos.top + 'px'; - } else { - css.bottom = _pos.bottom + 'px'; - } +function verify (hash, signature, Q) { + typeforce(types.tuple( + types.Hash256bit, + types.ECSignature, + types.ECPoint + ), arguments) - if (_same.left) { - css.left = _pos.left + 'px'; - } else { - css.right = _pos.right + 'px'; - } - } - }; + var n = secp256k1.n + var G = secp256k1.G - var moved = false; - if ((same.page.top || same.page.bottom) && (same.page.left || same.page.right)) { - css.position = 'absolute'; - transcribe(same.page, pos.page); - } else if ((same.viewport.top || same.viewport.bottom) && (same.viewport.left || same.viewport.right)) { - css.position = 'fixed'; - transcribe(same.viewport, pos.viewport); - } else if (typeof same.offset !== 'undefined' && same.offset.top && same.offset.left) { - (function () { - css.position = 'absolute'; - var offsetParent = _this8.cache('target-offsetparent', function () { - return getOffsetParent(_this8.target); - }); + var r = signature.r + var s = signature.s - if (getOffsetParent(_this8.element) !== offsetParent) { - defer(function () { - _this8.element.parentNode.removeChild(_this8.element); - offsetParent.appendChild(_this8.element); - }); - } + // 1.4.1 Enforce r and s are both integers in the interval [1, n − 1] + if (r.signum() <= 0 || r.compareTo(n) >= 0) return false + if (s.signum() <= 0 || s.compareTo(n) >= 0) return false - transcribe(same.offset, pos.offset); - moved = true; - })(); - } else { - css.position = 'absolute'; - transcribe({ top: true, left: true }, pos.page); - } + // 1.4.2 H = Hash(M), already done by the user + // 1.4.3 e = H + var e = BigInteger.fromBuffer(hash) - if (!moved) { - var offsetParentIsBody = true; - var currentNode = this.element.parentNode; - while (currentNode && currentNode.nodeType === 1 && currentNode.tagName !== 'BODY') { - if (getComputedStyle(currentNode).position !== 'static') { - offsetParentIsBody = false; - break; - } + // Compute s^-1 + var sInv = s.modInverse(n) - currentNode = currentNode.parentNode; - } + // 1.4.4 Compute u1 = es^−1 mod n + // u2 = rs^−1 mod n + var u1 = e.multiply(sInv).mod(n) + var u2 = r.multiply(sInv).mod(n) - if (!offsetParentIsBody) { - this.element.parentNode.removeChild(this.element); - this.element.ownerDocument.body.appendChild(this.element); - } - } + // 1.4.5 Compute R = (xR, yR) + // R = u1G + u2Q + var R = G.multiplyTwo(u1, Q, u2) - // Any css change will trigger a repaint, so let's avoid one if nothing changed - var writeCSS = {}; - var write = false; - for (var key in css) { - var val = css[key]; - var elVal = this.element.style[key]; + // 1.4.5 (cont.) Enforce R is not at infinity + if (secp256k1.isInfinity(R)) return false - if (elVal !== val) { - write = true; - writeCSS[key] = val; - } - } + // 1.4.6 Convert the field element R.x to an integer + var xR = R.affineX - if (write) { - defer(function () { - extend(_this8.element.style, writeCSS); - _this8.trigger('repositioned'); - }); - } - } - }]); + // 1.4.7 Set v = xR mod n + var v = xR.mod(n) - return TetherClass; -})(Evented); + // 1.4.8 If v = r, output "valid", and if v != r, output "invalid" + return v.equals(r) +} -TetherClass.modules = []; +module.exports = { + deterministicGenerateK: deterministicGenerateK, + sign: sign, + verify: verify, -_utils2['default'].position = position; + // TODO: remove + __curve: secp256k1 +} -var Tether = extend(TetherClass, _utils2['default']); -exports['default'] = Tether; -module.exports = exports['default']; +/***/ }), +/* 490 */ +/***/ (function(module, exports, __webpack_require__) { -},{"./abutment":1,"./constraint":2,"./shift":3,"./utils":5}],5:[function(require,module,exports){ -'use strict'; +var BigInteger = __webpack_require__(30) -Object.defineProperty(exports, '__esModule', { - value: true -}); +var curves = __webpack_require__(491) +var Curve = __webpack_require__(208) + +function getCurveByName (name) { + var curve = curves[name] + if (!curve) return null + + var p = new BigInteger(curve.p, 16) + var a = new BigInteger(curve.a, 16) + var b = new BigInteger(curve.b, 16) + var n = new BigInteger(curve.n, 16) + var h = new BigInteger(curve.h, 16) + var Gx = new BigInteger(curve.Gx, 16) + var Gy = new BigInteger(curve.Gy, 16) + + return new Curve(p, a, b, Gx, Gy, n, h) +} -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); +module.exports = getCurveByName -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } -var TetherBase = { modules: [] }; +/***/ }), +/* 491 */ +/***/ (function(module, exports) { -var zeroElement = null; +module.exports = { + "secp128r1": { + "p": "fffffffdffffffffffffffffffffffff", + "a": "fffffffdfffffffffffffffffffffffc", + "b": "e87579c11079f43dd824993c2cee5ed3", + "n": "fffffffe0000000075a30d1b9038a115", + "h": "01", + "Gx": "161ff7528b899b2d0c28607ca52c5b86", + "Gy": "cf5ac8395bafeb13c02da292dded7a83" + }, + "secp160k1": { + "p": "fffffffffffffffffffffffffffffffeffffac73", + "a": "00", + "b": "07", + "n": "0100000000000000000001b8fa16dfab9aca16b6b3", + "h": "01", + "Gx": "3b4c382ce37aa192a4019e763036f4f5dd4d7ebb", + "Gy": "938cf935318fdced6bc28286531733c3f03c4fee" + }, + "secp160r1": { + "p": "ffffffffffffffffffffffffffffffff7fffffff", + "a": "ffffffffffffffffffffffffffffffff7ffffffc", + "b": "1c97befc54bd7a8b65acf89f81d4d4adc565fa45", + "n": "0100000000000000000001f4c8f927aed3ca752257", + "h": "01", + "Gx": "4a96b5688ef573284664698968c38bb913cbfc82", + "Gy": "23a628553168947d59dcc912042351377ac5fb32" + }, + "secp192k1": { + "p": "fffffffffffffffffffffffffffffffffffffffeffffee37", + "a": "00", + "b": "03", + "n": "fffffffffffffffffffffffe26f2fc170f69466a74defd8d", + "h": "01", + "Gx": "db4ff10ec057e9ae26b07d0280b7f4341da5d1b1eae06c7d", + "Gy": "9b2f2f6d9c5628a7844163d015be86344082aa88d95e2f9d" + }, + "secp192r1": { + "p": "fffffffffffffffffffffffffffffffeffffffffffffffff", + "a": "fffffffffffffffffffffffffffffffefffffffffffffffc", + "b": "64210519e59c80e70fa7e9ab72243049feb8deecc146b9b1", + "n": "ffffffffffffffffffffffff99def836146bc9b1b4d22831", + "h": "01", + "Gx": "188da80eb03090f67cbf20eb43a18800f4ff0afd82ff1012", + "Gy": "07192b95ffc8da78631011ed6b24cdd573f977a11e794811" + }, + "secp256k1": { + "p": "fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f", + "a": "00", + "b": "07", + "n": "fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141", + "h": "01", + "Gx": "79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798", + "Gy": "483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8" + }, + "secp256r1": { + "p": "ffffffff00000001000000000000000000000000ffffffffffffffffffffffff", + "a": "ffffffff00000001000000000000000000000000fffffffffffffffffffffffc", + "b": "5ac635d8aa3a93e7b3ebbd55769886bc651d06b0cc53b0f63bce3c3e27d2604b", + "n": "ffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551", + "h": "01", + "Gx": "6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296", + "Gy": "4fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5" + } +}; -// Same as native getBoundingClientRect, except it takes into account parent <frame> offsets -// if the element lies within a nested document (<frame> or <iframe>-like). -function getActualBoundingClientRect(node) { - var boundingRect = node.getBoundingClientRect(); +/***/ }), +/* 492 */ +/***/ (function(module, exports, __webpack_require__) { - // The original object returned by getBoundingClientRect is immutable, so we clone it - // We can't use extend because the properties are not considered part of the object by hasOwnProperty in IE9 - var rect = {}; - for (var k in boundingRect) { - rect[k] = boundingRect[k]; - } +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33) - if (node.ownerDocument !== document) { - var _frameElement = node.ownerDocument.defaultView.frameElement; - if (_frameElement) { - var frameRect = getActualBoundingClientRect(_frameElement); - rect.top += frameRect.top; - rect.bottom += frameRect.top; - rect.left += frameRect.left; - rect.right += frameRect.left; +function decodeRaw (buffer, version) { + // check version only if defined + if (version !== undefined && buffer[0] !== version) throw new Error('Invalid network version') + + // uncompressed + if (buffer.length === 33) { + return { + version: buffer[0], + privateKey: buffer.slice(1, 33), + compressed: false } } - return rect; -} + // invalid length + if (buffer.length !== 34) throw new Error('Invalid WIF length') -function getScrollParents(el) { - // In firefox if the el is inside an iframe with display: none; window.getComputedStyle() will return null; - // https://bugzilla.mozilla.org/show_bug.cgi?id=548397 - var computedStyle = getComputedStyle(el) || {}; - var position = computedStyle.position; - var parents = []; + // invalid compression flag + if (buffer[33] !== 0x01) throw new Error('Invalid compression flag') - if (position === 'fixed') { - return [el]; + return { + version: buffer[0], + privateKey: buffer.slice(1, 33), + compressed: true } +} - var parent = el; - while ((parent = parent.parentNode) && parent && parent.nodeType === 1) { - var style = undefined; - try { - style = getComputedStyle(parent); - } catch (err) {} - - if (typeof style === 'undefined' || style === null) { - parents.push(parent); - return parents; - } +function encodeRaw (version, privateKey, compressed) { + var result = new Buffer(compressed ? 34 : 33) - var _style = style; - var overflow = _style.overflow; - var overflowX = _style.overflowX; - var overflowY = _style.overflowY; + result.writeUInt8(version, 0) + privateKey.copy(result, 1) - if (/(auto|scroll)/.test(overflow + overflowY + overflowX)) { - if (position !== 'absolute' || ['relative', 'absolute', 'fixed'].indexOf(style.position) >= 0) { - parents.push(parent); - } - } + if (compressed) { + result[33] = 0x01 } - parents.push(el.ownerDocument.body); - - // If the node is within a frame, account for the parent window scroll - if (el.ownerDocument !== document) { - parents.push(el.ownerDocument.defaultView); - } + return result +} - return parents; +function decode (string, version) { + return decodeRaw(bs58check.decode(string), version) } -var uniqueId = (function () { - var id = 0; - return function () { - return ++id; - }; -})(); +function encode (version, privateKey, compressed) { + if (typeof version === 'number') return bs58check.encode(encodeRaw(version, privateKey, compressed)) -var zeroPosCache = {}; -var getOrigin = function getOrigin() { - // getBoundingClientRect is unfortunately too accurate. It introduces a pixel or two of - // jitter as the user scrolls that messes with our ability to detect if two positions - // are equivilant or not. We place an element at the top left of the page that will - // get the same jitter, so we can cancel the two out. - var node = zeroElement; - if (!node) { - node = document.createElement('div'); - node.setAttribute('data-tether-id', uniqueId()); - extend(node.style, { - top: 0, - left: 0, - position: 'absolute' - }); + return bs58check.encode( + encodeRaw( + version.version, + version.privateKey, + version.compressed + ) + ) +} - document.body.appendChild(node); +module.exports = { + decode: decode, + decodeRaw: decodeRaw, + encode: encode, + encodeRaw: encodeRaw +} - zeroElement = node; - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - var id = node.getAttribute('data-tether-id'); - if (typeof zeroPosCache[id] === 'undefined') { - zeroPosCache[id] = getActualBoundingClientRect(node); +/***/ }), +/* 493 */ +/***/ (function(module, exports, __webpack_require__) { - // Clear the cache when this position call is done - defer(function () { - delete zeroPosCache[id]; - }); - } +var Buffer = __webpack_require__(7).Buffer +var base58check = __webpack_require__(33) +var bcrypto = __webpack_require__(44) +var createHmac = __webpack_require__(67) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var NETWORKS = __webpack_require__(54) - return zeroPosCache[id]; -}; +var BigInteger = __webpack_require__(30) +var ECPair = __webpack_require__(113) -function removeUtilElements() { - if (zeroElement) { - document.body.removeChild(zeroElement); - } - zeroElement = null; -}; +var ecurve = __webpack_require__(116) +var curve = ecurve.getCurveByName('secp256k1') -function getBounds(el) { - var doc = undefined; - if (el === document) { - doc = document; - el = document.documentElement; - } else { - doc = el.ownerDocument; - } +function HDNode (keyPair, chainCode) { + typeforce(types.tuple('ECPair', types.Buffer256bit), arguments) - var docEl = doc.documentElement; + if (!keyPair.compressed) throw new TypeError('BIP32 only allows compressed keyPairs') - var box = getActualBoundingClientRect(el); + this.keyPair = keyPair + this.chainCode = chainCode + this.depth = 0 + this.index = 0 + this.parentFingerprint = 0x00000000 +} - var origin = getOrigin(); +HDNode.HIGHEST_BIT = 0x80000000 +HDNode.LENGTH = 78 +HDNode.MASTER_SECRET = Buffer.from('Bitcoin seed', 'utf8') - box.top -= origin.top; - box.left -= origin.left; +HDNode.fromSeedBuffer = function (seed, network) { + typeforce(types.tuple(types.Buffer, types.maybe(types.Network)), arguments) - if (typeof box.width === 'undefined') { - box.width = document.body.scrollWidth - box.left - box.right; - } - if (typeof box.height === 'undefined') { - box.height = document.body.scrollHeight - box.top - box.bottom; - } + if (seed.length < 16) throw new TypeError('Seed should be at least 128 bits') + if (seed.length > 64) throw new TypeError('Seed should be at most 512 bits') - box.top = box.top - docEl.clientTop; - box.left = box.left - docEl.clientLeft; - box.right = doc.body.clientWidth - box.width - box.left; - box.bottom = doc.body.clientHeight - box.height - box.top; + var I = createHmac('sha512', HDNode.MASTER_SECRET).update(seed).digest() + var IL = I.slice(0, 32) + var IR = I.slice(32) - return box; + // In case IL is 0 or >= n, the master key is invalid + // This is handled by the ECPair constructor + var pIL = BigInteger.fromBuffer(IL) + var keyPair = new ECPair(pIL, null, { + network: network + }) + + return new HDNode(keyPair, IR) } -function getOffsetParent(el) { - return el.offsetParent || document.documentElement; +HDNode.fromSeedHex = function (hex, network) { + return HDNode.fromSeedBuffer(Buffer.from(hex, 'hex'), network) } -function getScrollBarSize() { - var inner = document.createElement('div'); - inner.style.width = '100%'; - inner.style.height = '200px'; +HDNode.fromBase58 = function (string, networks) { + var buffer = base58check.decode(string) + if (buffer.length !== 78) throw new Error('Invalid buffer length') - var outer = document.createElement('div'); - extend(outer.style, { - position: 'absolute', - top: 0, - left: 0, - pointerEvents: 'none', - visibility: 'hidden', - width: '200px', - height: '150px', - overflow: 'hidden' - }); + // 4 bytes: version bytes + var version = buffer.readUInt32BE(0) + var network - outer.appendChild(inner); + // list of networks? + if (Array.isArray(networks)) { + network = networks.filter(function (x) { + return version === x.bip32.private || + version === x.bip32.public + }).pop() - document.body.appendChild(outer); + if (!network) throw new Error('Unknown network version') - var widthContained = inner.offsetWidth; - outer.style.overflow = 'scroll'; - var widthScroll = inner.offsetWidth; + // otherwise, assume a network object (or default to bitcoin) + } else { + network = networks || NETWORKS.bitcoin + } - if (widthContained === widthScroll) { - widthScroll = outer.clientWidth; + if (version !== network.bip32.private && + version !== network.bip32.public) throw new Error('Invalid network version') + + // 1 byte: depth: 0x00 for master nodes, 0x01 for level-1 descendants, ... + var depth = buffer[4] + + // 4 bytes: the fingerprint of the parent's key (0x00000000 if master key) + var parentFingerprint = buffer.readUInt32BE(5) + if (depth === 0) { + if (parentFingerprint !== 0x00000000) throw new Error('Invalid parent fingerprint') } - document.body.removeChild(outer); + // 4 bytes: child number. This is the number i in xi = xpar/i, with xi the key being serialized. + // This is encoded in MSB order. (0x00000000 if master key) + var index = buffer.readUInt32BE(9) + if (depth === 0 && index !== 0) throw new Error('Invalid index') - var width = widthContained - widthScroll; + // 32 bytes: the chain code + var chainCode = buffer.slice(13, 45) + var keyPair - return { width: width, height: width }; -} + // 33 bytes: private key data (0x00 + k) + if (version === network.bip32.private) { + if (buffer.readUInt8(45) !== 0x00) throw new Error('Invalid private key') -function extend() { - var out = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0]; + var d = BigInteger.fromBuffer(buffer.slice(46, 78)) + keyPair = new ECPair(d, null, { network: network }) - var args = []; + // 33 bytes: public key data (0x02 + X or 0x03 + X) + } else { + var Q = ecurve.Point.decodeFrom(curve, buffer.slice(45, 78)) + // Q.compressed is assumed, if somehow this assumption is broken, `new HDNode` will throw - Array.prototype.push.apply(args, arguments); + // Verify that the X coordinate in the public point corresponds to a point on the curve. + // If not, the extended public key is invalid. + curve.validate(Q) - args.slice(1).forEach(function (obj) { - if (obj) { - for (var key in obj) { - if (({}).hasOwnProperty.call(obj, key)) { - out[key] = obj[key]; - } - } - } - }); + keyPair = new ECPair(null, Q, { network: network }) + } - return out; + var hd = new HDNode(keyPair, chainCode) + hd.depth = depth + hd.index = index + hd.parentFingerprint = parentFingerprint + + return hd } -function removeClass(el, name) { - if (typeof el.classList !== 'undefined') { - name.split(' ').forEach(function (cls) { - if (cls.trim()) { - el.classList.remove(cls); - } - }); - } else { - var regex = new RegExp('(^| )' + name.split(' ').join('|') + '( |$)', 'gi'); - var className = getClassName(el).replace(regex, ' '); - setClassName(el, className); - } +HDNode.prototype.getAddress = function () { + return this.keyPair.getAddress() } -function addClass(el, name) { - if (typeof el.classList !== 'undefined') { - name.split(' ').forEach(function (cls) { - if (cls.trim()) { - el.classList.add(cls); - } - }); - } else { - removeClass(el, name); - var cls = getClassName(el) + (' ' + name); - setClassName(el, cls); - } +HDNode.prototype.getIdentifier = function () { + return bcrypto.hash160(this.keyPair.getPublicKeyBuffer()) } -function hasClass(el, name) { - if (typeof el.classList !== 'undefined') { - return el.classList.contains(name); - } - var className = getClassName(el); - return new RegExp('(^| )' + name + '( |$)', 'gi').test(className); +HDNode.prototype.getFingerprint = function () { + return this.getIdentifier().slice(0, 4) } -function getClassName(el) { - // Can't use just SVGAnimatedString here since nodes within a Frame in IE have - // completely separately SVGAnimatedString base classes - if (el.className instanceof el.ownerDocument.defaultView.SVGAnimatedString) { - return el.className.baseVal; - } - return el.className; +HDNode.prototype.getNetwork = function () { + return this.keyPair.getNetwork() } -function setClassName(el, className) { - el.setAttribute('class', className); +HDNode.prototype.getPublicKeyBuffer = function () { + return this.keyPair.getPublicKeyBuffer() } -function updateClasses(el, add, all) { - // Of the set of 'all' classes, we need the 'add' classes, and only the - // 'add' classes to be set. - all.forEach(function (cls) { - if (add.indexOf(cls) === -1 && hasClass(el, cls)) { - removeClass(el, cls); - } - }); +HDNode.prototype.neutered = function () { + var neuteredKeyPair = new ECPair(null, this.keyPair.Q, { + network: this.keyPair.network + }) - add.forEach(function (cls) { - if (!hasClass(el, cls)) { - addClass(el, cls); - } - }); + var neutered = new HDNode(neuteredKeyPair, this.chainCode) + neutered.depth = this.depth + neutered.index = this.index + neutered.parentFingerprint = this.parentFingerprint + + return neutered } -var deferred = []; +HDNode.prototype.sign = function (hash) { + return this.keyPair.sign(hash) +} -var defer = function defer(fn) { - deferred.push(fn); -}; +HDNode.prototype.verify = function (hash, signature) { + return this.keyPair.verify(hash, signature) +} -var flush = function flush() { - var fn = undefined; - while (fn = deferred.pop()) { - fn(); - } -}; +HDNode.prototype.toBase58 = function (__isPrivate) { + if (__isPrivate !== undefined) throw new TypeError('Unsupported argument in 2.0.0') -var Evented = (function () { - function Evented() { - _classCallCheck(this, Evented); - } + // Version + var network = this.keyPair.network + var version = (!this.isNeutered()) ? network.bip32.private : network.bip32.public + var buffer = Buffer.allocUnsafe(78) - _createClass(Evented, [{ - key: 'on', - value: function on(event, handler, ctx) { - var once = arguments.length <= 3 || arguments[3] === undefined ? false : arguments[3]; + // 4 bytes: version bytes + buffer.writeUInt32BE(version, 0) - if (typeof this.bindings === 'undefined') { - this.bindings = {}; - } - if (typeof this.bindings[event] === 'undefined') { - this.bindings[event] = []; - } - this.bindings[event].push({ handler: handler, ctx: ctx, once: once }); - } - }, { - key: 'once', - value: function once(event, handler, ctx) { - this.on(event, handler, ctx, true); - } - }, { - key: 'off', - value: function off(event, handler) { - if (typeof this.bindings === 'undefined' || typeof this.bindings[event] === 'undefined') { - return; - } + // 1 byte: depth: 0x00 for master nodes, 0x01 for level-1 descendants, .... + buffer.writeUInt8(this.depth, 4) - if (typeof handler === 'undefined') { - delete this.bindings[event]; - } else { - var i = 0; - while (i < this.bindings[event].length) { - if (this.bindings[event][i].handler === handler) { - this.bindings[event].splice(i, 1); - } else { - ++i; - } - } - } - } - }, { - key: 'trigger', - value: function trigger(event) { - if (typeof this.bindings !== 'undefined' && this.bindings[event]) { - var i = 0; + // 4 bytes: the fingerprint of the parent's key (0x00000000 if master key) + buffer.writeUInt32BE(this.parentFingerprint, 5) - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; - } + // 4 bytes: child number. This is the number i in xi = xpar/i, with xi the key being serialized. + // This is encoded in big endian. (0x00000000 if master key) + buffer.writeUInt32BE(this.index, 9) - while (i < this.bindings[event].length) { - var _bindings$event$i = this.bindings[event][i]; - var handler = _bindings$event$i.handler; - var ctx = _bindings$event$i.ctx; - var once = _bindings$event$i.once; + // 32 bytes: the chain code + this.chainCode.copy(buffer, 13) - var context = ctx; - if (typeof context === 'undefined') { - context = this; - } + // 33 bytes: the public key or private key data + if (!this.isNeutered()) { + // 0x00 + k for private keys + buffer.writeUInt8(0, 45) + this.keyPair.d.toBuffer(32).copy(buffer, 46) - handler.apply(context, args); + // 33 bytes: the public key + } else { + // X9.62 encoding for public keys + this.keyPair.getPublicKeyBuffer().copy(buffer, 45) + } - if (once) { - this.bindings[event].splice(i, 1); - } else { - ++i; - } - } - } - } - }]); + return base58check.encode(buffer) +} - return Evented; -})(); +// https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki#child-key-derivation-ckd-functions +HDNode.prototype.derive = function (index) { + typeforce(types.UInt32, index) -TetherBase.Utils = { - getActualBoundingClientRect: getActualBoundingClientRect, - getScrollParents: getScrollParents, - getBounds: getBounds, - getOffsetParent: getOffsetParent, - extend: extend, - addClass: addClass, - removeClass: removeClass, - hasClass: hasClass, - updateClasses: updateClasses, - defer: defer, - flush: flush, - uniqueId: uniqueId, - Evented: Evented, - getScrollBarSize: getScrollBarSize, - removeUtilElements: removeUtilElements -}; + var isHardened = index >= HDNode.HIGHEST_BIT + var data = Buffer.allocUnsafe(37) -exports['default'] = TetherBase; -module.exports = exports['default']; + // Hardened child + if (isHardened) { + if (this.isNeutered()) throw new TypeError('Could not derive hardened child key') -},{}]},{},[4])(4) -}); + // data = 0x00 || ser256(kpar) || ser32(index) + data[0] = 0x00 + this.keyPair.d.toBuffer(32).copy(data, 1) + data.writeUInt32BE(index, 33) -/***/ }), -/* 225 */ -/***/ (function(module, exports) { + // Normal child + } else { + // data = serP(point(kpar)) || ser32(index) + // = serP(Kpar) || ser32(index) + this.keyPair.getPublicKeyBuffer().copy(data, 0) + data.writeUInt32BE(index, 33) + } -/** - * lodash (Custom Build) <https://lodash.com/> - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors <https://jquery.org/> - * Released under MIT license <https://lodash.com/license> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */ + var I = createHmac('sha512', this.chainCode).update(data).digest() + var IL = I.slice(0, 32) + var IR = I.slice(32) -/** Used as references for various `Number` constants. */ -var NAN = 0 / 0; + var pIL = BigInteger.fromBuffer(IL) -/** `Object#toString` result references. */ -var symbolTag = '[object Symbol]'; + // In case parse256(IL) >= n, proceed with the next value for i + if (pIL.compareTo(curve.n) >= 0) { + return this.derive(index + 1) + } -/** Used to match leading and trailing whitespace. */ -var reTrim = /^\s+|\s+$/g; + // Private parent key -> private child key + var derivedKeyPair + if (!this.isNeutered()) { + // ki = parse256(IL) + kpar (mod n) + var ki = pIL.add(this.keyPair.d).mod(curve.n) -/** Used to detect bad signed hexadecimal string values. */ -var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; + // In case ki == 0, proceed with the next value for i + if (ki.signum() === 0) { + return this.derive(index + 1) + } -/** Used to detect binary string values. */ -var reIsBinary = /^0b[01]+$/i; + derivedKeyPair = new ECPair(ki, null, { + network: this.keyPair.network + }) -/** Used to detect octal string values. */ -var reIsOctal = /^0o[0-7]+$/i; + // Public parent key -> public child key + } else { + // Ki = point(parse256(IL)) + Kpar + // = G*IL + Kpar + var Ki = curve.G.multiply(pIL).add(this.keyPair.Q) -/** Built-in method references without a dependency on `root`. */ -var freeParseInt = parseInt; + // In case Ki is the point at infinity, proceed with the next value for i + if (curve.isInfinity(Ki)) { + return this.derive(index + 1) + } -/** Used for built-in method references. */ -var objectProto = Object.prototype; + derivedKeyPair = new ECPair(null, Ki, { + network: this.keyPair.network + }) + } -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; + var hd = new HDNode(derivedKeyPair, IR) + hd.depth = this.depth + 1 + hd.index = index + hd.parentFingerprint = this.getFingerprint().readUInt32BE(0) -/** - * Checks if `value` is the - * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) - * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); + return hd } -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; +HDNode.prototype.deriveHardened = function (index) { + typeforce(types.UInt31, index) + + // Only derives hardened private keys by default + return this.derive(index + HDNode.HIGHEST_BIT) } -/** - * Checks if `value` is classified as a `Symbol` primitive or object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. - * @example - * - * _.isSymbol(Symbol.iterator); - * // => true - * - * _.isSymbol('abc'); - * // => false - */ -function isSymbol(value) { - return typeof value == 'symbol' || - (isObjectLike(value) && objectToString.call(value) == symbolTag); +// Private === not neutered +// Public === neutered +HDNode.prototype.isNeutered = function () { + return !(this.keyPair.d) } -/** - * Converts `value` to a number. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to process. - * @returns {number} Returns the number. - * @example - * - * _.toNumber(3.2); - * // => 3.2 - * - * _.toNumber(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toNumber(Infinity); - * // => Infinity - * - * _.toNumber('3.2'); - * // => 3.2 - */ -function toNumber(value) { - if (typeof value == 'number') { - return value; - } - if (isSymbol(value)) { - return NAN; - } - if (isObject(value)) { - var other = typeof value.valueOf == 'function' ? value.valueOf() : value; - value = isObject(other) ? (other + '') : other; - } - if (typeof value != 'string') { - return value === 0 ? value : +value; +HDNode.prototype.derivePath = function (path) { + typeforce(types.BIP32Path, path) + + var splitPath = path.split('/') + if (splitPath[0] === 'm') { + if (this.parentFingerprint) { + throw new Error('Not a master node') + } + + splitPath = splitPath.slice(1) } - value = value.replace(reTrim, ''); - var isBinary = reIsBinary.test(value); - return (isBinary || reIsOctal.test(value)) - ? freeParseInt(value.slice(2), isBinary ? 2 : 8) - : (reIsBadHex.test(value) ? NAN : +value); + + return splitPath.reduce(function (prevHd, indexStr) { + var index + if (indexStr.slice(-1) === "'") { + index = parseInt(indexStr.slice(0, -1), 10) + return prevHd.deriveHardened(index) + } else { + index = parseInt(indexStr, 10) + return prevHd.derive(index) + } + }, this) } -module.exports = toNumber; +module.exports = HDNode /***/ }), -/* 226 */ +/* 494 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +var Buffer = __webpack_require__(7).Buffer +var baddress = __webpack_require__(114) +var bcrypto = __webpack_require__(44) +var bscript = __webpack_require__(14) +var networks = __webpack_require__(54) +var ops = __webpack_require__(16) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var scriptTypes = bscript.types +var SIGNABLE = [bscript.types.P2PKH, bscript.types.P2PK, bscript.types.MULTISIG] +var P2SH = SIGNABLE.concat([bscript.types.P2WPKH, bscript.types.P2WSH]) + +var ECPair = __webpack_require__(113) +var ECSignature = __webpack_require__(115) +var Transaction = __webpack_require__(112) + +function extractChunks (type, chunks, script) { + var pubKeys = [] + var signatures = [] + switch (type) { + case scriptTypes.P2PKH: + // if (redeemScript) throw new Error('Nonstandard... P2SH(P2PKH)') + pubKeys = chunks.slice(1) + signatures = chunks.slice(0, 1) + break + + case scriptTypes.P2PK: + pubKeys[0] = script ? bscript.pubKey.output.decode(script) : undefined + signatures = chunks.slice(0, 1) + break + + case scriptTypes.MULTISIG: + if (script) { + var multisig = bscript.multisig.output.decode(script) + pubKeys = multisig.pubKeys + } + signatures = chunks.slice(1).map(function (chunk) { + return chunk.length === 0 ? undefined : chunk + }) + break + } -var _CSSTransitionGroup = __webpack_require__(227); + return { + pubKeys: pubKeys, + signatures: signatures + } +} +function expandInput (scriptSig, witnessStack) { + if (scriptSig.length === 0 && witnessStack.length === 0) return {} + + var prevOutScript + var prevOutType + var scriptType + var script + var redeemScript + var witnessScript + var witnessScriptType + var redeemScriptType + var witness = false + var p2wsh = false + var p2sh = false + var witnessProgram + var chunks + + var scriptSigChunks = bscript.decompile(scriptSig) + var sigType = bscript.classifyInput(scriptSigChunks, true) + if (sigType === scriptTypes.P2SH) { + p2sh = true + redeemScript = scriptSigChunks[scriptSigChunks.length - 1] + redeemScriptType = bscript.classifyOutput(redeemScript) + prevOutScript = bscript.scriptHash.output.encode(bcrypto.hash160(redeemScript)) + prevOutType = scriptTypes.P2SH + script = redeemScript + } + + var classifyWitness = bscript.classifyWitness(witnessStack) + if (classifyWitness === scriptTypes.P2WSH) { + witnessScript = witnessStack[witnessStack.length - 1] + witnessScriptType = bscript.classifyOutput(witnessScript) + p2wsh = true + if (scriptSig.length === 0) { + prevOutScript = bscript.witnessScriptHash.output.encode(bcrypto.sha256(witnessScript)) + prevOutType = scriptTypes.P2WSH + if (typeof redeemScript !== 'undefined') { + throw new Error('Redeem script given when unnecessary') + } + // bare witness + } else { + if (!redeemScript) { + throw new Error('No redeemScript provided for P2WSH, but scriptSig non-empty') + } + witnessProgram = bscript.witnessScriptHash.output.encode(bcrypto.sha256(witnessScript)) + if (!redeemScript.equals(witnessProgram)) { + throw new Error('Redeem script didn\'t match witnessScript') + } + } -var _CSSTransitionGroup2 = _interopRequireDefault(_CSSTransitionGroup); + if (SIGNABLE.indexOf(bscript.classifyOutput(witnessScript)) === -1) { + throw new Error('unsupported witness script') + } + script = witnessScript + scriptType = witnessScriptType + chunks = witnessStack.slice(0, -1) + } else if (classifyWitness === scriptTypes.P2WPKH) { + var key = witnessStack[witnessStack.length - 1] + var keyHash = bcrypto.hash160(key) + if (scriptSig.length === 0) { + prevOutScript = bscript.witnessPubKeyHash.output.encode(keyHash) + prevOutType = scriptTypes.P2WPKH + if (typeof redeemScript !== 'undefined') { + throw new Error('Redeem script given when unnecessary') + } + } else { + if (!redeemScript) { + throw new Error('No redeemScript provided for P2WPKH, but scriptSig wasn\'t empty') + } + witnessProgram = bscript.witnessPubKeyHash.output.encode(keyHash) + if (!redeemScript.equals(witnessProgram)) { + throw new Error('Redeem script did not have the right witness program') + } + } -var _TransitionGroup = __webpack_require__(106); + scriptType = scriptTypes.P2PKH + chunks = witnessStack + } else if (redeemScript) { + if (P2SH.indexOf(redeemScriptType) === -1) { + throw new Error('Bad redeemscript!') + } -var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); + script = redeemScript + scriptType = redeemScriptType + chunks = scriptSigChunks.slice(0, -1) + } else { + prevOutType = scriptType = bscript.classifyInput(scriptSig) + chunks = scriptSigChunks + } -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + var expanded = extractChunks(scriptType, chunks, script) -module.exports = { - TransitionGroup: _TransitionGroup2.default, - CSSTransitionGroup: _CSSTransitionGroup2.default -}; + var result = { + pubKeys: expanded.pubKeys, + signatures: expanded.signatures, + prevOutScript: prevOutScript, + prevOutType: prevOutType, + signType: scriptType, + signScript: script, + witness: Boolean(witness) + } -/***/ }), -/* 227 */ -/***/ (function(module, exports, __webpack_require__) { + if (p2sh) { + result.redeemScript = redeemScript + result.redeemScriptType = redeemScriptType + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { + if (p2wsh) { + result.witnessScript = witnessScript + result.witnessScriptType = witnessScriptType + } -exports.__esModule = true; + return result +} -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +// could be done in expandInput, but requires the original Transaction for hashForSignature +function fixMultisigOrder (input, transaction, vin) { + if (input.redeemScriptType !== scriptTypes.MULTISIG || !input.redeemScript) return + if (input.pubKeys.length === input.signatures.length) return -var _react = __webpack_require__(4); + var unmatched = input.signatures.concat() -var _react2 = _interopRequireDefault(_react); + input.signatures = input.pubKeys.map(function (pubKey) { + var keyPair = ECPair.fromPublicKeyBuffer(pubKey) + var match -var _propTypes = __webpack_require__(9); + // check for a signature + unmatched.some(function (signature, i) { + // skip if undefined || OP_0 + if (!signature) return false -var _propTypes2 = _interopRequireDefault(_propTypes); + // TODO: avoid O(n) hashForSignature + var parsed = ECSignature.parseScriptSignature(signature) + var hash = transaction.hashForSignature(vin, input.redeemScript, parsed.hashType) -var _TransitionGroup = __webpack_require__(106); + // skip if signature does not match pubKey + if (!keyPair.verify(hash, parsed.signature)) return false -var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); + // remove matched signature from unmatched + unmatched[i] = undefined + match = signature -var _CSSTransitionGroupChild = __webpack_require__(231); + return true + }) -var _CSSTransitionGroupChild2 = _interopRequireDefault(_CSSTransitionGroupChild); + return match + }) +} -var _PropTypes = __webpack_require__(108); +function expandOutput (script, scriptType, ourPubKey) { + typeforce(types.Buffer, script) -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + var scriptChunks = bscript.decompile(script) + if (!scriptType) { + scriptType = bscript.classifyOutput(script) + } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + var pubKeys = [] -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + switch (scriptType) { + // does our hash160(pubKey) match the output scripts? + case scriptTypes.P2PKH: + if (!ourPubKey) break -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + var pkh1 = scriptChunks[2] + var pkh2 = bcrypto.hash160(ourPubKey) + if (pkh1.equals(pkh2)) pubKeys = [ourPubKey] + break -var propTypes = { - transitionName: _PropTypes.nameShape.isRequired, + // does our hash160(pubKey) match the output scripts? + case scriptTypes.P2WPKH: + if (!ourPubKey) break - transitionAppear: _propTypes2.default.bool, - transitionEnter: _propTypes2.default.bool, - transitionLeave: _propTypes2.default.bool, - transitionAppearTimeout: (0, _PropTypes.transitionTimeout)('Appear'), - transitionEnterTimeout: (0, _PropTypes.transitionTimeout)('Enter'), - transitionLeaveTimeout: (0, _PropTypes.transitionTimeout)('Leave') -}; + var wpkh1 = scriptChunks[1] + var wpkh2 = bcrypto.hash160(ourPubKey) + if (wpkh1.equals(wpkh2)) pubKeys = [ourPubKey] + break -var defaultProps = { - transitionAppear: false, - transitionEnter: true, - transitionLeave: true -}; + case scriptTypes.P2PK: + pubKeys = scriptChunks.slice(0, 1) + break -var CSSTransitionGroup = function (_React$Component) { - _inherits(CSSTransitionGroup, _React$Component); + case scriptTypes.MULTISIG: + pubKeys = scriptChunks.slice(1, -2) + break - function CSSTransitionGroup() { - var _temp, _this, _ret; + default: return { scriptType: scriptType } + } - _classCallCheck(this, CSSTransitionGroup); + return { + pubKeys: pubKeys, + scriptType: scriptType, + signatures: pubKeys.map(function () { return undefined }) + } +} - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } +function checkP2shInput (input, redeemScriptHash) { + if (input.prevOutType) { + if (input.prevOutType !== scriptTypes.P2SH) throw new Error('PrevOutScript must be P2SH') - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this._wrapChild = function (child) { - return _react2.default.createElement(_CSSTransitionGroupChild2.default, { - name: _this.props.transitionName, - appear: _this.props.transitionAppear, - enter: _this.props.transitionEnter, - leave: _this.props.transitionLeave, - appearTimeout: _this.props.transitionAppearTimeout, - enterTimeout: _this.props.transitionEnterTimeout, - leaveTimeout: _this.props.transitionLeaveTimeout - }, child); - }, _temp), _possibleConstructorReturn(_this, _ret); + var prevOutScriptScriptHash = bscript.decompile(input.prevOutScript)[1] + if (!prevOutScriptScriptHash.equals(redeemScriptHash)) throw new Error('Inconsistent hash160(RedeemScript)') } +} - // We need to provide this childFactory so that - // ReactCSSTransitionGroupChild can receive updates to name, enter, and - // leave while it is leaving. +function checkP2WSHInput (input, witnessScriptHash) { + if (input.prevOutType) { + if (input.prevOutType !== scriptTypes.P2WSH) throw new Error('PrevOutScript must be P2WSH') + var scriptHash = bscript.decompile(input.prevOutScript)[1] + if (!scriptHash.equals(witnessScriptHash)) throw new Error('Inconsistent sha25(WitnessScript)') + } +} - CSSTransitionGroup.prototype.render = function render() { - return _react2.default.createElement(_TransitionGroup2.default, _extends({}, this.props, { childFactory: this._wrapChild })); - }; +function prepareInput (input, kpPubKey, redeemScript, witnessValue, witnessScript) { + var expanded + var prevOutType + var prevOutScript + + var p2sh = false + var p2shType + var redeemScriptHash + + var witness = false + var p2wsh = false + var witnessType + var witnessScriptHash + + var signType + var signScript + + if (redeemScript && witnessScript) { + redeemScriptHash = bcrypto.hash160(redeemScript) + witnessScriptHash = bcrypto.sha256(witnessScript) + checkP2shInput(input, redeemScriptHash) + + if (!redeemScript.equals(bscript.witnessScriptHash.output.encode(witnessScriptHash))) throw new Error('Witness script inconsistent with redeem script') + + expanded = expandOutput(witnessScript, undefined, kpPubKey) + if (!expanded.pubKeys) throw new Error('WitnessScript not supported "' + bscript.toASM(redeemScript) + '"') + prevOutType = bscript.types.P2SH + prevOutScript = bscript.scriptHash.output.encode(redeemScriptHash) + p2sh = witness = p2wsh = true + p2shType = bscript.types.P2WSH + signType = witnessType = expanded.scriptType + signScript = witnessScript + } else if (redeemScript) { + redeemScriptHash = bcrypto.hash160(redeemScript) + checkP2shInput(input, redeemScriptHash) + + expanded = expandOutput(redeemScript, undefined, kpPubKey) + if (!expanded.pubKeys) throw new Error('RedeemScript not supported "' + bscript.toASM(redeemScript) + '"') + + prevOutType = bscript.types.P2SH + prevOutScript = bscript.scriptHash.output.encode(redeemScriptHash) + p2sh = true + signType = p2shType = expanded.scriptType + signScript = redeemScript + witness = signType === bscript.types.P2WPKH + } else if (witnessScript) { + witnessScriptHash = bcrypto.sha256(witnessScript) + checkP2WSHInput(input, witnessScriptHash) + + expanded = expandOutput(witnessScript, undefined, kpPubKey) + if (!expanded.pubKeys) throw new Error('WitnessScript not supported "' + bscript.toASM(redeemScript) + '"') + + prevOutType = bscript.types.P2WSH + prevOutScript = bscript.witnessScriptHash.output.encode(witnessScriptHash) + witness = p2wsh = true + signType = witnessType = expanded.scriptType + signScript = witnessScript + } else if (input.prevOutType) { + // embedded scripts are not possible without a redeemScript + if (input.prevOutType === scriptTypes.P2SH || + input.prevOutType === scriptTypes.P2WSH) { + throw new Error('PrevOutScript is ' + input.prevOutType + ', requires redeemScript') + } + + prevOutType = input.prevOutType + prevOutScript = input.prevOutScript + expanded = expandOutput(input.prevOutScript, input.prevOutType, kpPubKey) + if (!expanded.pubKeys) return + + witness = (input.prevOutType === scriptTypes.P2WPKH) + signType = prevOutType + signScript = prevOutScript + } else { + prevOutScript = bscript.pubKeyHash.output.encode(bcrypto.hash160(kpPubKey)) + expanded = expandOutput(prevOutScript, scriptTypes.P2PKH, kpPubKey) + prevOutType = scriptTypes.P2PKH + witness = false + signType = prevOutType + signScript = prevOutScript + } - return CSSTransitionGroup; -}(_react2.default.Component); + if (witness && !types.Satoshi(witnessValue)) { + throw new Error('Input was witness but not given witness value') + } -CSSTransitionGroup.displayName = 'CSSTransitionGroup'; + if (signType === scriptTypes.P2WPKH) { + signScript = bscript.pubKeyHash.output.encode(bscript.witnessPubKeyHash.output.decode(signScript)) + } + if (p2sh) { + input.redeemScript = redeemScript + input.redeemScriptType = p2shType + } -CSSTransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; -CSSTransitionGroup.defaultProps = defaultProps; + if (p2wsh) { + input.witnessScript = witnessScript + input.witnessScriptType = witnessType + } -exports.default = CSSTransitionGroup; -module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + input.pubKeys = expanded.pubKeys + input.signatures = expanded.signatures + input.signScript = signScript + input.signType = signType + input.prevOutScript = prevOutScript + input.prevOutType = prevOutType + input.witness = witness +} -/***/ }), -/* 228 */ -/***/ (function(module, exports) { +function buildStack (type, signatures, pubKeys, allowIncomplete) { + if (type === scriptTypes.P2PKH) { + if (signatures.length === 1 && Buffer.isBuffer(signatures[0]) && pubKeys.length === 1) return bscript.pubKeyHash.input.encodeStack(signatures[0], pubKeys[0]) + } else if (type === scriptTypes.P2PK) { + if (signatures.length === 1 && Buffer.isBuffer(signatures[0])) return bscript.pubKey.input.encodeStack(signatures[0]) + } else if (type === scriptTypes.MULTISIG) { + if (signatures.length > 0) { + signatures = signatures.map(function (signature) { + return signature || ops.OP_0 + }) + if (!allowIncomplete) { + // remove blank signatures + signatures = signatures.filter(function (x) { return x !== ops.OP_0 }) + } - -module.exports = function chain(){ - var len = arguments.length - var args = []; - - for (var i = 0; i < len; i++) - args[i] = arguments[i] - - args = args.filter(function(fn){ return fn != null }) - - if (args.length === 0) return undefined - if (args.length === 1) return args[0] - - return args.reduce(function(current, next){ - return function chainedFunction() { - current.apply(this, arguments); - next.apply(this, arguments); - }; - }) -} + return bscript.multisig.input.encodeStack(signatures /* see if it's necessary first */) + } + } else { + throw new Error('Not yet supported') + } + if (!allowIncomplete) throw new Error('Not enough signatures provided') -/***/ }), -/* 229 */ -/***/ (function(module, exports, __webpack_require__) { + return [] +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +function buildInput (input, allowIncomplete) { + var scriptType = input.prevOutType + var sig = [] + var witness = [] + if (SIGNABLE.indexOf(scriptType) !== -1) { + sig = buildStack(scriptType, input.signatures, input.pubKeys, allowIncomplete) + } + + var p2sh = false + if (scriptType === bscript.types.P2SH) { + // We can remove this error later when we have a guarantee prepareInput + // rejects unsignable scripts - it MUST be signable at this point. + if (P2SH.indexOf(input.redeemScriptType) === -1) { + throw new Error('Impossible to sign this type') + } + p2sh = true + if (SIGNABLE.indexOf(input.redeemScriptType) !== -1) { + sig = buildStack(input.redeemScriptType, input.signatures, input.pubKeys, allowIncomplete) + } + // If it wasn't SIGNABLE, it's witness, defer to that + scriptType = input.redeemScriptType + } + + if (scriptType === bscript.types.P2WPKH) { + // P2WPKH is a special case of P2PKH + witness = buildStack(bscript.types.P2PKH, input.signatures, input.pubKeys, allowIncomplete) + } else if (scriptType === bscript.types.P2WSH) { + // We can remove this check later + if (SIGNABLE.indexOf(input.witnessScriptType) !== -1) { + witness = buildStack(input.witnessScriptType, input.signatures, input.pubKeys, allowIncomplete) + witness.push(input.witnessScript) + } else { + // We can remove this error later when we have a guarantee prepareInput + // rejects unsignble scripts - it MUST be signable at this point. + throw new Error() + } + scriptType = input.witnessScriptType + } + // append redeemScript if necessary + if (p2sh) { + sig.push(input.redeemScript) + } -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ + return { + type: scriptType, + script: bscript.compile(sig), + witness: witness + } +} -var warning = function() {}; +function TransactionBuilder (network, maximumFeeRate) { + this.prevTxMap = {} + this.network = network || networks.bitcoin -if (process.env.NODE_ENV !== 'production') { - warning = function(condition, format, args) { - var len = arguments.length; - args = new Array(len > 2 ? len - 2 : 0); - for (var key = 2; key < len; key++) { - args[key - 2] = arguments[key]; - } - if (format === undefined) { - throw new Error( - '`warning(condition, format, ...args)` requires a warning ' + - 'message argument' - ); - } + // WARNING: This is __NOT__ to be relied on, its just another potential safety mechanism (safety in-depth) + this.maximumFeeRate = maximumFeeRate || 1000 - if (format.length < 10 || (/^[s\W]*$/).test(format)) { - throw new Error( - 'The warning format should be able to uniquely identify this ' + - 'warning. Please, use a more descriptive format than: ' + format - ); - } + this.inputs = [] + this.tx = new Transaction() +} - if (!condition) { - var argIndex = 0; - var message = 'Warning: ' + - format.replace(/%s/g, function() { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch(x) {} - } - }; +TransactionBuilder.prototype.setLockTime = function (locktime) { + typeforce(types.UInt32, locktime) + + // if any signatures exist, throw + if (this.inputs.some(function (input) { + if (!input.signatures) return false + + return input.signatures.some(function (s) { return s }) + })) { + throw new Error('No, this would invalidate signatures') + } + + this.tx.locktime = locktime } -module.exports = warning; +TransactionBuilder.prototype.setVersion = function (version) { + typeforce(types.UInt32, version) -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // XXX: this might eventually become more complex depending on what the versions represent + this.tx.version = version +} -/***/ }), -/* 230 */ -/***/ (function(module, exports, __webpack_require__) { +TransactionBuilder.fromTransaction = function (transaction, network) { + var txb = new TransactionBuilder(network) + + // Copy transaction fields + txb.setVersion(transaction.version) + txb.setLockTime(transaction.locktime) + + // Copy outputs (done first to avoid signature invalidation) + transaction.outs.forEach(function (txOut) { + txb.addOutput(txOut.script, txOut.value) + }) + + // Copy inputs + transaction.ins.forEach(function (txIn) { + txb.__addInputUnsafe(txIn.hash, txIn.index, { + sequence: txIn.sequence, + script: txIn.script, + witness: txIn.witness + }) + }) + + // fix some things not possible through the public API + txb.inputs.forEach(function (input, i) { + fixMultisigOrder(input, transaction, i) + }) + + return txb +} -"use strict"; +TransactionBuilder.prototype.addInput = function (txHash, vout, sequence, prevOutScript) { + if (!this.__canModifyInputs()) { + throw new Error('No, this would invalidate signatures') + } + var value -exports.__esModule = true; -exports.getChildMapping = getChildMapping; -exports.mergeChildMappings = mergeChildMappings; + // is it a hex string? + if (typeof txHash === 'string') { + // transaction hashs's are displayed in reverse order, un-reverse it + txHash = Buffer.from(txHash, 'hex').reverse() -var _react = __webpack_require__(4); + // is it a Transaction object? + } else if (txHash instanceof Transaction) { + var txOut = txHash.outs[vout] + prevOutScript = txOut.script + value = txOut.value -/** - * Given `this.props.children`, return an object mapping key to child. - * - * @param {*} children `this.props.children` - * @return {object} Mapping of key to child - */ -function getChildMapping(children) { - if (!children) { - return children; + txHash = txHash.getHash() } - var result = {}; - _react.Children.map(children, function (child) { - return child; - }).forEach(function (child) { - result[child.key] = child; - }); - return result; + + return this.__addInputUnsafe(txHash, vout, { + sequence: sequence, + prevOutScript: prevOutScript, + value: value + }) } -/** - * When you're adding or removing children some may be added or removed in the - * same render pass. We want to show *both* since we want to simultaneously - * animate elements in and out. This function takes a previous set of keys - * and a new set of keys and merges them with its best guess of the correct - * ordering. In the future we may expose some of the utilities in - * ReactMultiChild to make this easy, but for now React itself does not - * directly have this concept of the union of prevChildren and nextChildren - * so we implement it here. - * - * @param {object} prev prev children as returned from - * `ReactTransitionChildMapping.getChildMapping()`. - * @param {object} next next children as returned from - * `ReactTransitionChildMapping.getChildMapping()`. - * @return {object} a key set that contains all keys in `prev` and all keys - * in `next` in a reasonable order. - */ -function mergeChildMappings(prev, next) { - prev = prev || {}; - next = next || {}; +TransactionBuilder.prototype.__addInputUnsafe = function (txHash, vout, options) { + if (Transaction.isCoinbaseHash(txHash)) { + throw new Error('coinbase inputs not supported') + } - function getValueForKey(key) { - if (next.hasOwnProperty(key)) { - return next[key]; - } + var prevTxOut = txHash.toString('hex') + ':' + vout + if (this.prevTxMap[prevTxOut] !== undefined) throw new Error('Duplicate TxOut: ' + prevTxOut) - return prev[key]; + var input = {} + + // derive what we can from the scriptSig + if (options.script !== undefined) { + input = expandInput(options.script, options.witness || []) } - // For each key of `next`, the list of keys to insert before that key in - // the combined list - var nextKeysPending = {}; + // if an input value was given, retain it + if (options.value !== undefined) { + input.value = options.value + } - var pendingKeys = []; - for (var prevKey in prev) { - if (next.hasOwnProperty(prevKey)) { - if (pendingKeys.length) { - nextKeysPending[prevKey] = pendingKeys; - pendingKeys = []; + // derive what we can from the previous transactions output script + if (!input.prevOutScript && options.prevOutScript) { + var prevOutType + + if (!input.pubKeys && !input.signatures) { + var expanded = expandOutput(options.prevOutScript) + + if (expanded.pubKeys) { + input.pubKeys = expanded.pubKeys + input.signatures = expanded.signatures } - } else { - pendingKeys.push(prevKey); + + prevOutType = expanded.scriptType } + + input.prevOutScript = options.prevOutScript + input.prevOutType = prevOutType || bscript.classifyOutput(options.prevOutScript) } - var i = void 0; - var childMapping = {}; - for (var nextKey in next) { - if (nextKeysPending.hasOwnProperty(nextKey)) { - for (i = 0; i < nextKeysPending[nextKey].length; i++) { - var pendingNextKey = nextKeysPending[nextKey][i]; - childMapping[nextKeysPending[nextKey][i]] = getValueForKey(pendingNextKey); + var vin = this.tx.addInput(txHash, vout, options.sequence, options.scriptSig) + this.inputs[vin] = input + this.prevTxMap[prevTxOut] = vin + + return vin +} + +TransactionBuilder.prototype.addOutput = function (scriptPubKey, value) { + if (!this.__canModifyOutputs()) { + throw new Error('No, this would invalidate signatures') + } + + // Attempt to get a script if it's a base58 address string + if (typeof scriptPubKey === 'string') { + scriptPubKey = baddress.toOutputScript(scriptPubKey, this.network) + } + + return this.tx.addOutput(scriptPubKey, value) +} + +TransactionBuilder.prototype.build = function () { + return this.__build(false) +} +TransactionBuilder.prototype.buildIncomplete = function () { + return this.__build(true) +} + +TransactionBuilder.prototype.__build = function (allowIncomplete) { + if (!allowIncomplete) { + if (!this.tx.ins.length) throw new Error('Transaction has no inputs') + if (!this.tx.outs.length) throw new Error('Transaction has no outputs') + } + + var tx = this.tx.clone() + // Create script signatures from inputs + this.inputs.forEach(function (input, i) { + var scriptType = input.witnessScriptType || input.redeemScriptType || input.prevOutType + if (!scriptType && !allowIncomplete) throw new Error('Transaction is not complete') + var result = buildInput(input, allowIncomplete) + + // skip if no result + if (!allowIncomplete) { + if (SIGNABLE.indexOf(result.type) === -1 && result.type !== bscript.types.P2WPKH) { + throw new Error(result.type + ' not supported') } } - childMapping[nextKey] = getValueForKey(nextKey); + + tx.setInputScript(i, result.script) + tx.setWitness(i, result.witness) + }) + + if (!allowIncomplete) { + // do not rely on this, its merely a last resort + if (this.__overMaximumFees(tx.byteLength())) { + throw new Error('Transaction has absurd fees') + } } - // Finally, add the keys which didn't appear before any key in `next` - for (i = 0; i < pendingKeys.length; i++) { - childMapping[pendingKeys[i]] = getValueForKey(pendingKeys[i]); + return tx +} + +function canSign (input) { + return input.prevOutScript !== undefined && + input.signScript !== undefined && + input.pubKeys !== undefined && + input.signatures !== undefined && + input.signatures.length === input.pubKeys.length && + input.pubKeys.length > 0 && + input.witness !== undefined +} + +TransactionBuilder.prototype.sign = function (vin, keyPair, redeemScript, hashType, witnessValue, witnessScript) { + if (keyPair.network !== this.network) throw new Error('Inconsistent network') + if (!this.inputs[vin]) throw new Error('No input at index: ' + vin) + hashType = hashType || Transaction.SIGHASH_ALL + + var input = this.inputs[vin] + + // if redeemScript was previously provided, enforce consistency + if (input.redeemScript !== undefined && + redeemScript && + !input.redeemScript.equals(redeemScript)) { + throw new Error('Inconsistent redeemScript') } - return childMapping; + var kpPubKey = keyPair.getPublicKeyBuffer() + if (!canSign(input)) { + prepareInput(input, kpPubKey, redeemScript, witnessValue, witnessScript) + if (!canSign(input)) throw Error(input.prevOutType + ' not supported') + } + + // ready to sign + var signatureHash + if (input.witness) { + signatureHash = this.tx.hashForWitnessV0(vin, input.signScript, witnessValue, hashType) + } else { + signatureHash = this.tx.hashForSignature(vin, input.signScript, hashType) + } + // enforce in order signing of public keys + var signed = input.pubKeys.some(function (pubKey, i) { + if (!kpPubKey.equals(pubKey)) return false + if (input.signatures[i]) throw new Error('Signature already exists') + + input.signatures[i] = keyPair.sign(signatureHash).toScriptSignature(hashType) + return true + }) + + if (!signed) throw new Error('Key pair cannot sign for this input') } -/***/ }), -/* 231 */ -/***/ (function(module, exports, __webpack_require__) { +function signatureHashType (buffer) { + return buffer.readUInt8(buffer.length - 1) +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +TransactionBuilder.prototype.__canModifyInputs = function () { + return this.inputs.every(function (input) { + // any signatures? + if (input.signatures === undefined) return true -exports.__esModule = true; + return input.signatures.every(function (signature) { + if (!signature) return true + var hashType = signatureHashType(signature) -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + // if SIGHASH_ANYONECANPAY is set, signatures would not + // be invalidated by more inputs + return hashType & Transaction.SIGHASH_ANYONECANPAY + }) + }) +} -var _addClass = __webpack_require__(232); +TransactionBuilder.prototype.__canModifyOutputs = function () { + var nInputs = this.tx.ins.length + var nOutputs = this.tx.outs.length -var _addClass2 = _interopRequireDefault(_addClass); + return this.inputs.every(function (input) { + if (input.signatures === undefined) return true -var _removeClass = __webpack_require__(234); + return input.signatures.every(function (signature) { + if (!signature) return true + var hashType = signatureHashType(signature) -var _removeClass2 = _interopRequireDefault(_removeClass); + var hashTypeMod = hashType & 0x1f + if (hashTypeMod === Transaction.SIGHASH_NONE) return true + if (hashTypeMod === Transaction.SIGHASH_SINGLE) { + // if SIGHASH_SINGLE is set, and nInputs > nOutputs + // some signatures would be invalidated by the addition + // of more outputs + return nInputs <= nOutputs + } + }) + }) +} -var _requestAnimationFrame = __webpack_require__(235); +TransactionBuilder.prototype.__overMaximumFees = function (bytes) { + // not all inputs will have .value defined + var incoming = this.inputs.reduce(function (a, x) { return a + (x.value >>> 0) }, 0) -var _requestAnimationFrame2 = _interopRequireDefault(_requestAnimationFrame); + // but all outputs do, and if we have any input value + // we can immediately determine if the outputs are too small + var outgoing = this.tx.outs.reduce(function (a, x) { return a + x.value }, 0) + var fee = incoming - outgoing + var feeRate = fee / bytes -var _properties = __webpack_require__(236); + return feeRate > this.maximumFeeRate +} -var _react = __webpack_require__(4); +module.exports = TransactionBuilder -var _react2 = _interopRequireDefault(_react); -var _propTypes = __webpack_require__(9); +/***/ }), +/* 495 */ +/***/ (function(module, exports, __webpack_require__) { -var _propTypes2 = _interopRequireDefault(_propTypes); +module.exports = { + Account: __webpack_require__(496), + Chain: __webpack_require__(210), + discovery: __webpack_require__(209) +} -var _reactDom = __webpack_require__(28); -var _PropTypes = __webpack_require__(108); +/***/ }), +/* 496 */ +/***/ (function(module, exports, __webpack_require__) { -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var bitcoinjs = __webpack_require__(200) +var discovery = __webpack_require__(209) -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +var Chain = __webpack_require__(210) -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +function Account (chains) { + this.chains = chains +} -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +Account.fromJSON = function (json, network) { + var chains = json.map(function (j) { + var node = bitcoinjs.HDNode.fromBase58(j.node, network) -var events = []; -if (_properties.transitionEnd) events.push(_properties.transitionEnd); -if (_properties.animationEnd) events.push(_properties.animationEnd); + var chain = new Chain(node, j.k) + chain.map = j.map -function addEndListener(node, listener) { - if (events.length) { - events.forEach(function (e) { - return node.addEventListener(e, listener, false); - }); - } else { - setTimeout(listener, 0); - } + // derive from k map + chain.addresses = Object.keys(chain.map).sort(function (a, b) { + return chain.map[a] - chain.map[b] + }) - return function () { - if (!events.length) return; - events.forEach(function (e) { - return node.removeEventListener(e, listener, false); - }); - }; + return chain + }) + + return new Account(chains) } -var propTypes = { - children: _propTypes2.default.node, - name: _PropTypes.nameShape.isRequired, +Account.prototype.containsAddress = function (address) { + return this.chains.some(function (chain) { + return chain.find(address) !== undefined + }) +} - // Once we require timeouts to be specified, we can remove the - // boolean flags (appear etc.) and just accept a number - // or a bool for the timeout flags (appearTimeout etc.) - appear: _propTypes2.default.bool, - enter: _propTypes2.default.bool, - leave: _propTypes2.default.bool, - appearTimeout: _propTypes2.default.number, - enterTimeout: _propTypes2.default.number, - leaveTimeout: _propTypes2.default.number -}; +// optional parents argument for private key escalation +Account.prototype.derive = function (address, parents) { + var derived -var CSSTransitionGroupChild = function (_React$Component) { - _inherits(CSSTransitionGroupChild, _React$Component); + this.chains.some(function (chain, i) { + derived = chain.derive(address, parents && parents[i]) + return derived + }) - function CSSTransitionGroupChild() { - var _temp, _this, _ret; + return derived +} - _classCallCheck(this, CSSTransitionGroupChild); +Account.prototype.discoverChain = function (i, gapLimit, queryCallback, callback) { + var chains = this.chains + var chain = chains[i].clone() - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } + discovery(chain, gapLimit, queryCallback, function (err, used, checked) { + if (err) return callback(err) - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.componentWillAppear = function (done) { - if (_this.props.appear) { - _this.transition('appear', done, _this.props.appearTimeout); - } else { - done(); - } - }, _this.componentWillEnter = function (done) { - if (_this.props.enter) { - _this.transition('enter', done, _this.props.enterTimeout); - } else { - done(); - } - }, _this.componentWillLeave = function (done) { - if (_this.props.leave) { - _this.transition('leave', done, _this.props.leaveTimeout); - } else { - done(); - } - }, _temp), _possibleConstructorReturn(_this, _ret); - } + // throw away EACH unused address AFTER the last unused address + var unused = checked - used + for (var j = 1; j < unused; ++j) chain.pop() - CSSTransitionGroupChild.prototype.componentWillMount = function componentWillMount() { - this.classNameAndNodeQueue = []; - this.transitionTimeouts = []; - }; + // override the internal chain + chains[i] = chain - CSSTransitionGroupChild.prototype.componentWillUnmount = function componentWillUnmount() { - this.unmounted = true; + callback() + }) +} - if (this.timeout) { - clearTimeout(this.timeout); - } - this.transitionTimeouts.forEach(function (timeout) { - clearTimeout(timeout); - }); +Account.prototype.getAllAddresses = function () { + return [].concat.apply([], this.chains.map(function (chain) { + return chain.getAll() + })) +} - this.classNameAndNodeQueue.length = 0; - }; +Account.prototype.getChain = function (i) { return this.chains[i] } +Account.prototype.getChains = function () { return this.chains } +Account.prototype.getChainAddress = function (i) { return this.chains[i].get() } +Account.prototype.getNetwork = function () { return this.chains[0].getParent().keyPair.network } - CSSTransitionGroupChild.prototype.transition = function transition(animationType, finishCallback, timeout) { - var node = (0, _reactDom.findDOMNode)(this); +Account.prototype.isChainAddress = function (i, address) { + return this.chains[i].find(address) !== undefined +} - if (!node) { - if (finishCallback) { - finishCallback(); - } - return; +Account.prototype.nextChainAddress = function (i) { + return this.chains[i].next() +} + +Account.prototype.toJSON = function () { + return this.chains.map(function (chain) { + return { + k: chain.k, + map: chain.map, + node: chain.getParent().toBase58() } + }) +} - var className = this.props.name[animationType] || this.props.name + '-' + animationType; - var activeClassName = this.props.name[animationType + 'Active'] || className + '-active'; - var timer = null; - var removeListeners = void 0; +module.exports = Account - (0, _addClass2.default)(node, className); - // Need to do this to actually trigger a transition. - this.queueClassAndNode(activeClassName, node); +/***/ }), +/* 497 */ +/***/ (function(module, exports, __webpack_require__) { - // Clean-up the animation after the specified delay - var finish = function finish(e) { - if (e && e.target !== node) { - return; - } +var __WEBPACK_AMD_DEFINE_RESULT__;/* FileSaver.js + * A saveAs() FileSaver implementation. + * 1.3.2 + * 2016-06-16 18:25:19 + * + * By Eli Grey, http://eligrey.com + * License: MIT + * See https://github.com/eligrey/FileSaver.js/blob/master/LICENSE.md + */ - clearTimeout(timer); - if (removeListeners) removeListeners(); +/*global self */ +/*jslint bitwise: true, indent: 4, laxbreak: true, laxcomma: true, smarttabs: true, plusplus: true */ - (0, _removeClass2.default)(node, className); - (0, _removeClass2.default)(node, activeClassName); +/*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */ - if (removeListeners) removeListeners(); +var saveAs = saveAs || (function(view) { + "use strict"; + // IE <10 is explicitly unsupported + if (typeof view === "undefined" || typeof navigator !== "undefined" && /MSIE [1-9]\./.test(navigator.userAgent)) { + return; + } + var + doc = view.document + // only get URL when necessary in case Blob.js hasn't overridden it yet + , get_URL = function() { + return view.URL || view.webkitURL || view; + } + , save_link = doc.createElementNS("http://www.w3.org/1999/xhtml", "a") + , can_use_save_link = "download" in save_link + , click = function(node) { + var event = new MouseEvent("click"); + node.dispatchEvent(event); + } + , is_safari = /constructor/i.test(view.HTMLElement) || view.safari + , is_chrome_ios =/CriOS\/[\d]+/.test(navigator.userAgent) + , throw_outside = function(ex) { + (view.setImmediate || view.setTimeout)(function() { + throw ex; + }, 0); + } + , force_saveable_type = "application/octet-stream" + // the Blob API is fundamentally broken as there is no "downloadfinished" event to subscribe to + , arbitrary_revoke_timeout = 1000 * 40 // in ms + , revoke = function(file) { + var revoker = function() { + if (typeof file === "string") { // file is an object URL + get_URL().revokeObjectURL(file); + } else { // file is a File + file.remove(); + } + }; + setTimeout(revoker, arbitrary_revoke_timeout); + } + , dispatch = function(filesaver, event_types, event) { + event_types = [].concat(event_types); + var i = event_types.length; + while (i--) { + var listener = filesaver["on" + event_types[i]]; + if (typeof listener === "function") { + try { + listener.call(filesaver, event || filesaver); + } catch (ex) { + throw_outside(ex); + } + } + } + } + , auto_bom = function(blob) { + // prepend BOM for UTF-8 XML and text/* types (including HTML) + // note: your browser will automatically convert UTF-16 U+FEFF to EF BB BF + if (/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(blob.type)) { + return new Blob([String.fromCharCode(0xFEFF), blob], {type: blob.type}); + } + return blob; + } + , FileSaver = function(blob, name, no_auto_bom) { + if (!no_auto_bom) { + blob = auto_bom(blob); + } + // First try a.download, then web filesystem, then object URLs + var + filesaver = this + , type = blob.type + , force = type === force_saveable_type + , object_url + , dispatch_all = function() { + dispatch(filesaver, "writestart progress write writeend".split(" ")); + } + // on any filesys errors revert to saving with object URLs + , fs_error = function() { + if ((is_chrome_ios || (force && is_safari)) && view.FileReader) { + // Safari doesn't allow downloading of blob urls + var reader = new FileReader(); + reader.onloadend = function() { + var url = is_chrome_ios ? reader.result : reader.result.replace(/^data:[^;]*;/, 'data:attachment/file;'); + var popup = view.open(url, '_blank'); + if(!popup) view.location.href = url; + url=undefined; // release reference before dispatching + filesaver.readyState = filesaver.DONE; + dispatch_all(); + }; + reader.readAsDataURL(blob); + filesaver.readyState = filesaver.INIT; + return; + } + // don't create more object URLs than needed + if (!object_url) { + object_url = get_URL().createObjectURL(blob); + } + if (force) { + view.location.href = object_url; + } else { + var opened = view.open(object_url, "_blank"); + if (!opened) { + // Apple does not allow window.open, see https://developer.apple.com/library/safari/documentation/Tools/Conceptual/SafariExtensionGuide/WorkingwithWindowsandTabs/WorkingwithWindowsandTabs.html + view.location.href = object_url; + } + } + filesaver.readyState = filesaver.DONE; + dispatch_all(); + revoke(object_url); + } + ; + filesaver.readyState = filesaver.INIT; + + if (can_use_save_link) { + object_url = get_URL().createObjectURL(blob); + setTimeout(function() { + save_link.href = object_url; + save_link.download = name; + click(save_link); + dispatch_all(); + revoke(object_url); + filesaver.readyState = filesaver.DONE; + }); + return; + } - // Usually this optional callback is used for informing an owner of - // a leave animation and telling it to remove the child. - if (finishCallback) { - finishCallback(); - } - }; + fs_error(); + } + , FS_proto = FileSaver.prototype + , saveAs = function(blob, name, no_auto_bom) { + return new FileSaver(blob, name || blob.name || "download", no_auto_bom); + } + ; + // IE 10+ (native saveAs) + if (typeof navigator !== "undefined" && navigator.msSaveOrOpenBlob) { + return function(blob, name, no_auto_bom) { + name = name || blob.name || "download"; + + if (!no_auto_bom) { + blob = auto_bom(blob); + } + return navigator.msSaveOrOpenBlob(blob, name); + }; + } - if (timeout) { - timer = setTimeout(finish, timeout); - this.transitionTimeouts.push(timer); - } else if (_properties.transitionEnd) { - removeListeners = addEndListener(node, finish); - } - }; + FS_proto.abort = function(){}; + FS_proto.readyState = FS_proto.INIT = 0; + FS_proto.WRITING = 1; + FS_proto.DONE = 2; + + FS_proto.error = + FS_proto.onwritestart = + FS_proto.onprogress = + FS_proto.onwrite = + FS_proto.onabort = + FS_proto.onerror = + FS_proto.onwriteend = + null; + + return saveAs; +}( + typeof self !== "undefined" && self + || typeof window !== "undefined" && window + || this.content +)); +// `self` is undefined in Firefox for Android content script context +// while `this` is nsIContentFrameMessageManager +// with an attribute `content` that corresponds to the window + +if (typeof module !== "undefined" && module.exports) { + module.exports.saveAs = saveAs; +} else if (("function" !== "undefined" && __webpack_require__(498) !== null) && (__webpack_require__(499) !== null)) { + !(__WEBPACK_AMD_DEFINE_RESULT__ = function() { + return saveAs; + }.call(exports, __webpack_require__, exports, module), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); +} + + +/***/ }), +/* 498 */ +/***/ (function(module, exports) { + +module.exports = function() { + throw new Error("define cannot be used indirect"); +}; + + +/***/ }), +/* 499 */ +/***/ (function(module, exports) { + +/* WEBPACK VAR INJECTION */(function(__webpack_amd_options__) {/* globals __webpack_amd_options__ */ +module.exports = __webpack_amd_options__; + +/* WEBPACK VAR INJECTION */}.call(exports, {})) + +/***/ }), +/* 500 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; - CSSTransitionGroupChild.prototype.queueClassAndNode = function queueClassAndNode(className, node) { - var _this2 = this; - this.classNameAndNodeQueue.push({ - className: className, - node: node - }); +Object.defineProperty(exports, "__esModule", { + value: true +}); - if (!this.rafHandle) { - this.rafHandle = (0, _requestAnimationFrame2.default)(function () { - return _this2.flushClassNameAndNodeQueue(); - }); - } - }; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - CSSTransitionGroupChild.prototype.flushClassNameAndNodeQueue = function flushClassNameAndNodeQueue() { - if (!this.unmounted) { - this.classNameAndNodeQueue.forEach(function (obj) { - // This is for to force a repaint, - // which is necessary in order to transition styles when adding a class name. - /* eslint-disable no-unused-expressions */ - obj.node.scrollTop; - /* eslint-enable no-unused-expressions */ - (0, _addClass2.default)(obj.node, obj.className); - }); - } - this.classNameAndNodeQueue.length = 0; - this.rafHandle = null; - }; +var _react = __webpack_require__(6); - CSSTransitionGroupChild.prototype.render = function render() { - var props = _extends({}, this.props); - delete props.name; - delete props.appear; - delete props.enter; - delete props.leave; - delete props.appearTimeout; - delete props.enterTimeout; - delete props.leaveTimeout; - delete props.children; - return _react2.default.cloneElement(_react2.default.Children.only(this.props.children), props); - }; +var _react2 = _interopRequireDefault(_react); - return CSSTransitionGroupChild; -}(_react2.default.Component); +var _reactIconBase = __webpack_require__(35); -CSSTransitionGroupChild.displayName = 'CSSTransitionGroupChild'; +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -CSSTransitionGroupChild.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; +var MdRefresh = function MdRefresh(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm29.5 10.5l3.9-3.9v11.8h-11.8l5.4-5.4c-1.8-1.8-4.3-3-7-3-5.5 0-10 4.5-10 10s4.5 10 10 10c4.4 0 8.1-2.7 9.5-6.6h3.4c-1.5 5.7-6.6 10-12.9 10-7.3 0-13.3-6.1-13.3-13.4s6-13.4 13.3-13.4c3.7 0 7 1.5 9.5 3.9z' }) + ) + ); +}; -exports.default = CSSTransitionGroupChild; +exports.default = MdRefresh; module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 232 */ +/* 501 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { - value: true + value: true }); -exports.default = addClass; -var _hasClass = __webpack_require__(233); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _hasClass2 = _interopRequireDefault(_hasClass); +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -function addClass(element, className) { - if (element.classList) element.classList.add(className);else if (!(0, _hasClass2.default)(element)) element.className = element.className + ' ' + className; -} +var MdContentCopy = function MdContentCopy(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm31.6 35v-23.4h-18.2v23.4h18.2z m0-26.6c1.8 0 3.4 1.4 3.4 3.2v23.4c0 1.8-1.6 3.4-3.4 3.4h-18.2c-1.8 0-3.4-1.6-3.4-3.4v-23.4c0-1.8 1.6-3.2 3.4-3.2h18.2z m-5-6.8v3.4h-20v23.4h-3.2v-23.4c0-1.8 1.4-3.4 3.2-3.4h20z' }) + ) + ); +}; + +exports.default = MdContentCopy; module.exports = exports['default']; /***/ }), -/* 233 */ +/* 502 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { - value: true + value: true }); -exports.default = hasClass; -function hasClass(element, className) { - if (element.classList) return !!className && element.classList.contains(className);else return (" " + element.className + " ").indexOf(" " + className + " ") !== -1; -} -module.exports = exports["default"]; -/***/ }), -/* 234 */ -/***/ (function(module, exports, __webpack_require__) { +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -"use strict"; +var _react = __webpack_require__(6); +var _react2 = _interopRequireDefault(_react); -module.exports = function removeClass(element, className) { - if (element.classList) element.classList.remove(className);else element.className = element.className.replace(new RegExp('(^|\\s)' + className + '(?:\\s|$)', 'g'), '$1').replace(/\s+/g, ' ').replace(/^\s*|\s*$/g, ''); +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var MdSettings = function MdSettings(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm20 25.9c3.2 0 5.9-2.7 5.9-5.9s-2.7-5.9-5.9-5.9-5.9 2.7-5.9 5.9 2.7 5.9 5.9 5.9z m12.4-4.3l3.5 2.8c0.4 0.2 0.4 0.7 0.2 1.1l-3.4 5.8c-0.2 0.3-0.6 0.4-1 0.3l-4.1-1.7c-0.9 0.7-1.8 1.3-2.8 1.7l-0.7 4.3c0 0.4-0.4 0.7-0.7 0.7h-6.8c-0.4 0-0.7-0.3-0.7-0.7l-0.7-4.3c-1-0.4-1.9-1-2.8-1.7l-4.1 1.7c-0.4 0.1-0.8 0-1-0.3l-3.4-5.8c-0.2-0.4-0.2-0.9 0.2-1.1l3.5-2.8c-0.1-0.5-0.1-1.1-0.1-1.6s0-1.1 0.1-1.6l-3.5-2.8c-0.4-0.2-0.4-0.7-0.2-1.1l3.4-5.7c0.2-0.4 0.6-0.5 1-0.4l4.1 1.7c0.9-0.6 1.8-1.3 2.8-1.7l0.7-4.3c0-0.4 0.3-0.7 0.7-0.7h6.8c0.3 0 0.7 0.3 0.7 0.7l0.7 4.3c1 0.4 1.9 1 2.8 1.7l4.1-1.7c0.4-0.1 0.8 0 1 0.4l3.4 5.7c0.2 0.4 0.2 0.9-0.2 1.1l-3.5 2.8c0.1 0.5 0.1 1.1 0.1 1.6s0 1.1-0.1 1.6z' }) + ) + ); }; +exports.default = MdSettings; +module.exports = exports['default']; + /***/ }), -/* 235 */ +/* 503 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { - value: true + value: true }); -var _inDOM = __webpack_require__(107); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _inDOM2 = _interopRequireDefault(_inDOM); +var _react = __webpack_require__(6); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var _react2 = _interopRequireDefault(_react); -var vendors = ['', 'webkit', 'moz', 'o', 'ms']; -var cancel = 'clearTimeout'; -var raf = fallback; -var compatRaf = void 0; +var _reactIconBase = __webpack_require__(35); -var getKey = function getKey(vendor, k) { - return vendor + (!vendor ? k : k[0].toUpperCase() + k.substr(1)) + 'AnimationFrame'; +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var FaRepeat = function FaRepeat(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm37.3 5.7v10q0 0.6-0.4 1t-1 0.4h-10q-1 0-1.4-0.9-0.3-0.8 0.4-1.5l3-3.1q-3.3-3-7.8-3-2.3 0-4.4 0.9t-3.6 2.4-2.5 3.7-0.9 4.4 0.9 4.4 2.5 3.7 3.6 2.4 4.4 0.9q2.7 0 5.1-1.1t4-3.3q0.1-0.2 0.5-0.3 0.3 0 0.5 0.2l3.1 3.1q0.2 0.2 0.2 0.5t-0.2 0.5q-2.4 2.9-5.9 4.5t-7.3 1.6q-3.4 0-6.6-1.3t-5.5-3.7-3.6-5.4-1.4-6.7 1.4-6.7 3.6-5.4 5.5-3.7 6.6-1.3q3.3 0 6.4 1.2t5.5 3.5l2.9-2.9q0.6-0.7 1.5-0.3 0.9 0.4 0.9 1.3z' }) + ) + ); }; -if (_inDOM2.default) { - vendors.some(function (vendor) { - var rafKey = getKey(vendor, 'request'); +exports.default = FaRepeat; +module.exports = exports['default']; - if (rafKey in window) { - cancel = getKey(vendor, 'cancel'); - return raf = function raf(cb) { - return window[rafKey](cb); - }; - } - }); -} +/***/ }), +/* 504 */ +/***/ (function(module, exports, __webpack_require__) { -/* https://github.com/component/raf */ -var prev = new Date().getTime(); -function fallback(fn) { - var curr = new Date().getTime(), - ms = Math.max(0, 16 - (curr - prev)), - req = setTimeout(fn, ms); +"use strict"; - prev = curr; - return req; -} -compatRaf = function compatRaf(cb) { - return raf(cb); -}; -compatRaf.cancel = function (id) { - window[cancel] && typeof window[cancel] === 'function' && window[cancel](id); +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var FaUnlockAlt = function FaUnlockAlt(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm30.6 17.1q0.9 0 1.5 0.7t0.6 1.5v12.8q0 0.9-0.6 1.6t-1.5 0.6h-21.5q-0.8 0-1.5-0.6t-0.6-1.6v-12.8q0-0.9 0.6-1.5t1.5-0.7h0.8v-7.1q0-4.1 2.9-7.1t7.1-2.9 7 2.9 3 7.1q0 0.6-0.5 1t-1 0.4h-1.4q-0.6 0-1-0.4t-0.4-1q0-2.4-1.7-4t-4-1.7-4.1 1.7-1.7 4v7.1h16.5z' }) + ) + ); }; -exports.default = compatRaf; + +exports.default = FaUnlockAlt; module.exports = exports['default']; /***/ }), -/* 236 */ +/* 505 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { - value: true + value: true }); -exports.animationEnd = exports.animationDelay = exports.animationTiming = exports.animationDuration = exports.animationName = exports.transitionEnd = exports.transitionDuration = exports.transitionDelay = exports.transitionTiming = exports.transitionProperty = exports.transform = undefined; -var _inDOM = __webpack_require__(107); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _inDOM2 = _interopRequireDefault(_inDOM); +var _react = __webpack_require__(6); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var _react2 = _interopRequireDefault(_react); -var transform = 'transform'; -var prefix = void 0, - transitionEnd = void 0, - animationEnd = void 0; -var transitionProperty = void 0, - transitionDuration = void 0, - transitionTiming = void 0, - transitionDelay = void 0; -var animationName = void 0, - animationDuration = void 0, - animationTiming = void 0, - animationDelay = void 0; +var _reactIconBase = __webpack_require__(35); -if (_inDOM2.default) { - var _getTransitionPropert = getTransitionProperties(); +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); - prefix = _getTransitionPropert.prefix; - exports.transitionEnd = transitionEnd = _getTransitionPropert.transitionEnd; - exports.animationEnd = animationEnd = _getTransitionPropert.animationEnd; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var FaEyeSlash = function FaEyeSlash(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm12.4 29.8l1.7-3.1q-1.9-1.5-3-3.6t-1.1-4.5q0-2.7 1.4-5-5.2 2.6-8.5 7.8 3.7 5.8 9.5 8.4z m8.7-16.9q0-0.5-0.3-0.8t-0.8-0.3q-2.8 0-4.8 2t-2 4.8q0 0.4 0.3 0.7t0.8 0.3 0.7-0.3 0.4-0.7q0-1.9 1.3-3.3t3.3-1.4q0.4 0 0.8-0.3t0.3-0.7z m8.1-4.3q0 0.2 0 0.2-2.4 4.2-7.1 12.6t-7 12.7l-1.1 2q-0.2 0.3-0.7 0.3-0.2 0-2.9-1.5-0.4-0.3-0.4-0.7 0-0.2 1-1.9-3.2-1.5-5.9-3.9t-4.7-5.4q-0.4-0.7-0.4-1.6t0.4-1.5q3.5-5.3 8.5-8.3t11.1-3q2 0 4 0.4l1.2-2.2q0.2-0.4 0.6-0.4 0.2 0 0.4 0.2t0.7 0.3 0.8 0.4 0.7 0.4 0.4 0.3q0.4 0.2 0.4 0.6z m0.8 10q0 3.1-1.8 5.6t-4.6 3.7l6.2-11.2q0.2 1 0.2 1.9z m10 2.8q0 0.8-0.4 1.6-0.9 1.4-2.5 3.2-3.3 3.8-7.7 6t-9.4 2.1l1.7-3q4.7-0.4 8.7-3t6.7-6.9q-2.5-4-6.3-6.5l1.5-2.5q2.1 1.4 4 3.4t3.3 4.1q0.4 0.7 0.4 1.5z' }) + ) + ); +}; - exports.transform = transform = prefix + '-' + transform; - exports.transitionProperty = transitionProperty = prefix + '-transition-property'; - exports.transitionDuration = transitionDuration = prefix + '-transition-duration'; - exports.transitionDelay = transitionDelay = prefix + '-transition-delay'; - exports.transitionTiming = transitionTiming = prefix + '-transition-timing-function'; +exports.default = FaEyeSlash; +module.exports = exports['default']; - exports.animationName = animationName = prefix + '-animation-name'; - exports.animationDuration = animationDuration = prefix + '-animation-duration'; - exports.animationTiming = animationTiming = prefix + '-animation-delay'; - exports.animationDelay = animationDelay = prefix + '-animation-timing-function'; -} +/***/ }), +/* 506 */ +/***/ (function(module, exports, __webpack_require__) { -exports.transform = transform; -exports.transitionProperty = transitionProperty; -exports.transitionTiming = transitionTiming; -exports.transitionDelay = transitionDelay; -exports.transitionDuration = transitionDuration; -exports.transitionEnd = transitionEnd; -exports.animationName = animationName; -exports.animationDuration = animationDuration; -exports.animationTiming = animationTiming; -exports.animationDelay = animationDelay; -exports.animationEnd = animationEnd; -exports.default = { - transform: transform, - end: transitionEnd, - property: transitionProperty, - timing: transitionTiming, - delay: transitionDelay, - duration: transitionDuration -}; +"use strict"; -function getTransitionProperties() { - var style = document.createElement('div').style; +Object.defineProperty(exports, "__esModule", { + value: true +}); - var vendorMap = { - O: function O(e) { - return 'o' + e.toLowerCase(); - }, - Moz: function Moz(e) { - return e.toLowerCase(); - }, - Webkit: function Webkit(e) { - return 'webkit' + e; - }, - ms: function ms(e) { - return 'MS' + e; - } - }; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - var vendors = Object.keys(vendorMap); +var _react = __webpack_require__(6); - var transitionEnd = void 0, - animationEnd = void 0; - var prefix = ''; +var _react2 = _interopRequireDefault(_react); - for (var i = 0; i < vendors.length; i++) { - var vendor = vendors[i]; +var _reactIconBase = __webpack_require__(35); - if (vendor + 'TransitionProperty' in style) { - prefix = '-' + vendor.toLowerCase(); - transitionEnd = vendorMap[vendor]('TransitionEnd'); - animationEnd = vendorMap[vendor]('AnimationEnd'); - break; - } - } +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); - if (!transitionEnd && 'transitionProperty' in style) transitionEnd = 'transitionend'; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - if (!animationEnd && 'animationName' in style) animationEnd = 'animationend'; +var FaEye = function FaEye(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm37.1 21.4q-3.3-5.2-8.5-7.8 1.4 2.3 1.4 5 0 4.1-2.9 7t-7.1 3-7.1-3-2.9-7q0-2.7 1.4-5.1-5.1 2.7-8.5 7.9 2.9 4.6 7.4 7.3t9.7 2.7 9.7-2.7 7.4-7.3z m-16-8.5q0-0.5-0.3-0.8t-0.8-0.3q-2.8 0-4.8 2t-2 4.8q0 0.4 0.3 0.7t0.8 0.3 0.7-0.3 0.4-0.7q0-2 1.3-3.3t3.3-1.4q0.4 0 0.8-0.3t0.3-0.7z m18.9 8.5q0 0.8-0.4 1.6-3.2 5.1-8.4 8.2t-11.2 3.1-11.2-3.1-8.4-8.2q-0.4-0.8-0.4-1.6t0.4-1.5q3.2-5.1 8.4-8.2t11.2-3.1 11.1 3.1 8.5 8.2q0.4 0.8 0.4 1.5z' }) + ) + ); +}; - style = null; +exports.default = FaEye; +module.exports = exports['default']; - return { animationEnd: animationEnd, transitionEnd: transitionEnd, prefix: prefix }; -} +/***/ }), +/* 507 */ +/***/ (function(module, exports) { + +module.exports = { + "name": "myzenwallet", + "version": "v2.0.0a", + "description": "Secure ZENCash wallet online", + "main": "index.js", + "repository": "https://github.com/kendricktan/myzenwallet.git", + "author": "Kendrick Tan <kendricktan0814@gmail.com>", + "license": "MIT", + "scripts": { + "start": "webpack-dev-server", + "watch": "webpack --watch" + }, + "dependencies": { + "axios": "^0.16.2", + "babel-preset-env": "^1.6.0", + "bip32-utils": "^0.10.0", + "bitcoinjs-lib": "^3.1.1", + "bluebird": "^3.5.0", + "bootstrap": "^4.0.0-alpha.6", + "bs58": "^4.0.1", + "bs58check": "^2.0.2", + "classnames": "^2.2.5", + "css-loader": "^0.28.4", + "file-loader": "^0.11.2", + "file-saver": "^1.3.3", + "fs": "^0.0.1-security", + "hash.js": "^1.1.3", + "html-webpack-plugin": "^2.29.0", + "path": "^0.12.7", + "react": "^15.6.1", + "react-addons-css-transition-group": "^15.6.0", + "react-addons-transition-group": "^15.6.0", + "react-bootstrap": "^0.31.1", + "react-copy-to-clipboard": "^5.0.0", + "react-dom": "^15.6.1", + "react-icons": "^2.2.5", + "react-table": "^6.5.3", + "reactstrap": "^4.8.0", + "style-loader": "^0.18.2", + "throttled-queue": "^1.0.4", + "webpack": "^3.3.0", + "webpack-dev-server": "^2.5.1", + "zencashjs": "^1.1.4-a" + }, + "devDependencies": { + "babel-core": "^6.25.0", + "babel-loader": "^7.1.1", + "babel-preset-es2015": "^6.24.1", + "babel-preset-react": "^6.24.1", + "css-loader": "^0.28.4" + } +}; /***/ }), -/* 237 */, -/* 238 */, -/* 239 */, -/* 240 */, -/* 241 */, -/* 242 */, -/* 243 */ +/* 508 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -30709,11 +80492,11 @@ Object.defineProperty(exports, "__esModule", { var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactstrap = __webpack_require__(66); +var _reactstrap = __webpack_require__(93); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -30849,627 +80632,43 @@ var ZFooter = function (_React$Component) { exports.default = ZFooter; /***/ }), -/* 244 */, -/* 245 */, -/* 246 */, -/* 247 */, -/* 248 */, -/* 249 */, -/* 250 */, -/* 251 */, -/* 252 */, -/* 253 */, -/* 254 */, -/* 255 */, -/* 256 */, -/* 257 */, -/* 258 */, -/* 259 */, -/* 260 */, -/* 261 */, -/* 262 */, -/* 263 */, -/* 264 */, -/* 265 */, -/* 266 */, -/* 267 */, -/* 268 */, -/* 269 */, -/* 270 */, -/* 271 */, -/* 272 */, -/* 273 */, -/* 274 */, -/* 275 */, -/* 276 */, -/* 277 */, -/* 278 */, -/* 279 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _reactIconBase = __webpack_require__(70); - -var _reactIconBase2 = _interopRequireDefault(_reactIconBase); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -var MdSettings = function MdSettings(props) { - return _react2.default.createElement( - _reactIconBase2.default, - _extends({ viewBox: '0 0 40 40' }, props), - _react2.default.createElement( - 'g', - null, - _react2.default.createElement('path', { d: 'm20 25.9c3.2 0 5.9-2.7 5.9-5.9s-2.7-5.9-5.9-5.9-5.9 2.7-5.9 5.9 2.7 5.9 5.9 5.9z m12.4-4.3l3.5 2.8c0.4 0.2 0.4 0.7 0.2 1.1l-3.4 5.8c-0.2 0.3-0.6 0.4-1 0.3l-4.1-1.7c-0.9 0.7-1.8 1.3-2.8 1.7l-0.7 4.3c0 0.4-0.4 0.7-0.7 0.7h-6.8c-0.4 0-0.7-0.3-0.7-0.7l-0.7-4.3c-1-0.4-1.9-1-2.8-1.7l-4.1 1.7c-0.4 0.1-0.8 0-1-0.3l-3.4-5.8c-0.2-0.4-0.2-0.9 0.2-1.1l3.5-2.8c-0.1-0.5-0.1-1.1-0.1-1.6s0-1.1 0.1-1.6l-3.5-2.8c-0.4-0.2-0.4-0.7-0.2-1.1l3.4-5.7c0.2-0.4 0.6-0.5 1-0.4l4.1 1.7c0.9-0.6 1.8-1.3 2.8-1.7l0.7-4.3c0-0.4 0.3-0.7 0.7-0.7h6.8c0.3 0 0.7 0.3 0.7 0.7l0.7 4.3c1 0.4 1.9 1 2.8 1.7l4.1-1.7c0.4-0.1 0.8 0 1 0.4l3.4 5.7c0.2 0.4 0.2 0.9-0.2 1.1l-3.5 2.8c0.1 0.5 0.1 1.1 0.1 1.6s0 1.1-0.1 1.6z' }) - ) - ); -}; - -exports.default = MdSettings; -module.exports = exports['default']; - -/***/ }), -/* 280 */ +/* 509 */, +/* 510 */, +/* 511 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _reactIconBase = __webpack_require__(70); - -var _reactIconBase2 = _interopRequireDefault(_reactIconBase); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -var FaUnlockAlt = function FaUnlockAlt(props) { - return _react2.default.createElement( - _reactIconBase2.default, - _extends({ viewBox: '0 0 40 40' }, props), - _react2.default.createElement( - 'g', - null, - _react2.default.createElement('path', { d: 'm30.6 17.1q0.9 0 1.5 0.7t0.6 1.5v12.8q0 0.9-0.6 1.6t-1.5 0.6h-21.5q-0.8 0-1.5-0.6t-0.6-1.6v-12.8q0-0.9 0.6-1.5t1.5-0.7h0.8v-7.1q0-4.1 2.9-7.1t7.1-2.9 7 2.9 3 7.1q0 0.6-0.5 1t-1 0.4h-1.4q-0.6 0-1-0.4t-0.4-1q0-2.4-1.7-4t-4-1.7-4.1 1.7-1.7 4v7.1h16.5z' }) - ) - ); -}; +__webpack_require__(211); -exports.default = FaUnlockAlt; -module.exports = exports['default']; +__webpack_require__(214); -/***/ }), -/* 281 */, -/* 282 */, -/* 283 */, -/* 284 */, -/* 285 */, -/* 286 */, -/* 287 */, -/* 288 */, -/* 289 */, -/* 290 */, -/* 291 */, -/* 292 */, -/* 293 */, -/* 294 */, -/* 295 */, -/* 296 */, -/* 297 */, -/* 298 */, -/* 299 */, -/* 300 */, -/* 301 */, -/* 302 */, -/* 303 */, -/* 304 */, -/* 305 */, -/* 306 */, -/* 307 */, -/* 308 */, -/* 309 */, -/* 310 */, -/* 311 */, -/* 312 */, -/* 313 */, -/* 314 */, -/* 315 */, -/* 316 */, -/* 317 */, -/* 318 */, -/* 319 */, -/* 320 */, -/* 321 */, -/* 322 */, -/* 323 */, -/* 324 */, -/* 325 */, -/* 326 */, -/* 327 */, -/* 328 */, -/* 329 */, -/* 330 */, -/* 331 */, -/* 332 */, -/* 333 */, -/* 334 */, -/* 335 */, -/* 336 */, -/* 337 */, -/* 338 */, -/* 339 */, -/* 340 */, -/* 341 */, -/* 342 */, -/* 343 */, -/* 344 */, -/* 345 */, -/* 346 */, -/* 347 */, -/* 348 */, -/* 349 */, -/* 350 */, -/* 351 */, -/* 352 */, -/* 353 */, -/* 354 */, -/* 355 */, -/* 356 */, -/* 357 */, -/* 358 */, -/* 359 */, -/* 360 */, -/* 361 */, -/* 362 */, -/* 363 */, -/* 364 */, -/* 365 */, -/* 366 */, -/* 367 */, -/* 368 */, -/* 369 */, -/* 370 */, -/* 371 */, -/* 372 */, -/* 373 */, -/* 374 */, -/* 375 */, -/* 376 */, -/* 377 */, -/* 378 */, -/* 379 */, -/* 380 */, -/* 381 */, -/* 382 */, -/* 383 */, -/* 384 */, -/* 385 */, -/* 386 */, -/* 387 */, -/* 388 */, -/* 389 */, -/* 390 */, -/* 391 */, -/* 392 */, -/* 393 */, -/* 394 */, -/* 395 */, -/* 396 */, -/* 397 */, -/* 398 */, -/* 399 */, -/* 400 */, -/* 401 */, -/* 402 */, -/* 403 */, -/* 404 */, -/* 405 */, -/* 406 */, -/* 407 */, -/* 408 */, -/* 409 */, -/* 410 */, -/* 411 */, -/* 412 */, -/* 413 */, -/* 414 */, -/* 415 */, -/* 416 */, -/* 417 */, -/* 418 */, -/* 419 */, -/* 420 */, -/* 421 */, -/* 422 */, -/* 423 */, -/* 424 */, -/* 425 */, -/* 426 */, -/* 427 */, -/* 428 */, -/* 429 */, -/* 430 */, -/* 431 */, -/* 432 */, -/* 433 */, -/* 434 */, -/* 435 */, -/* 436 */, -/* 437 */, -/* 438 */, -/* 439 */, -/* 440 */, -/* 441 */, -/* 442 */, -/* 443 */, -/* 444 */, -/* 445 */, -/* 446 */, -/* 447 */, -/* 448 */, -/* 449 */, -/* 450 */, -/* 451 */, -/* 452 */, -/* 453 */, -/* 454 */, -/* 455 */, -/* 456 */, -/* 457 */, -/* 458 */, -/* 459 */, -/* 460 */, -/* 461 */, -/* 462 */, -/* 463 */, -/* 464 */, -/* 465 */, -/* 466 */, -/* 467 */, -/* 468 */, -/* 469 */, -/* 470 */, -/* 471 */, -/* 472 */, -/* 473 */, -/* 474 */, -/* 475 */, -/* 476 */, -/* 477 */, -/* 478 */, -/* 479 */, -/* 480 */, -/* 481 */, -/* 482 */, -/* 483 */, -/* 484 */, -/* 485 */, -/* 486 */, -/* 487 */, -/* 488 */, -/* 489 */, -/* 490 */, -/* 491 */, -/* 492 */, -/* 493 */, -/* 494 */, -/* 495 */, -/* 496 */, -/* 497 */, -/* 498 */, -/* 499 */, -/* 500 */, -/* 501 */, -/* 502 */, -/* 503 */, -/* 504 */, -/* 505 */, -/* 506 */, -/* 507 */, -/* 508 */, -/* 509 */, -/* 510 */, -/* 511 */, -/* 512 */, -/* 513 */, -/* 514 */, -/* 515 */, -/* 516 */, -/* 517 */, -/* 518 */, -/* 519 */, -/* 520 */, -/* 521 */, -/* 522 */, -/* 523 */, -/* 524 */, -/* 525 */, -/* 526 */, -/* 527 */, -/* 528 */, -/* 529 */, -/* 530 */, -/* 531 */, -/* 532 */, -/* 533 */, -/* 534 */, -/* 535 */, -/* 536 */, -/* 537 */, -/* 538 */, -/* 539 */, -/* 540 */, -/* 541 */, -/* 542 */, -/* 543 */, -/* 544 */, -/* 545 */, -/* 546 */, -/* 547 */, -/* 548 */, -/* 549 */, -/* 550 */, -/* 551 */, -/* 552 */, -/* 553 */, -/* 554 */, -/* 555 */, -/* 556 */, -/* 557 */, -/* 558 */, -/* 559 */, -/* 560 */, -/* 561 */, -/* 562 */, -/* 563 */, -/* 564 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -__webpack_require__(117); - -__webpack_require__(120); - -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactDom = __webpack_require__(28); +var _reactDom = __webpack_require__(76); var _reactDom2 = _interopRequireDefault(_reactDom); -var _navbar = __webpack_require__(220); +var _navbar = __webpack_require__(315); var _navbar2 = _interopRequireDefault(_navbar); -var _guide = __webpack_require__(565); +var _wallet = __webpack_require__(332); -var _guide2 = _interopRequireDefault(_guide); +var _wallet2 = _interopRequireDefault(_wallet); -var _footer = __webpack_require__(243); +var _footer = __webpack_require__(508); var _footer2 = _interopRequireDefault(_footer); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } _reactDom2.default.render(_react2.default.createElement(_navbar2.default, null), document.getElementById('navbar')); -_reactDom2.default.render(_react2.default.createElement(_guide2.default, null), document.getElementById('guide')); +_reactDom2.default.render(_react2.default.createElement(ZGuide, null), document.getElementById('guide')); _reactDom2.default.render(_react2.default.createElement(_footer2.default, null), document.getElementById('footer')); -/***/ }), -/* 565 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _reactstrap = __webpack_require__(66); - -var _unlockAlt = __webpack_require__(280); - -var _unlockAlt2 = _interopRequireDefault(_unlockAlt); - -var _settings = __webpack_require__(279); - -var _settings2 = _interopRequireDefault(_settings); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var ZGuide = function (_React$Component) { - _inherits(ZGuide, _React$Component); - - function ZGuide() { - _classCallCheck(this, ZGuide); - - return _possibleConstructorReturn(this, (ZGuide.__proto__ || Object.getPrototypeOf(ZGuide)).apply(this, arguments)); - } - - _createClass(ZGuide, [{ - key: 'render', - value: function render() { - return _react2.default.createElement( - _reactstrap.Container, - null, - _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - null, - _react2.default.createElement( - 'h3', - null, - '1. Creating a new wallet' - ), - _react2.default.createElement( - 'ul', - null, - _react2.default.createElement( - 'li', - null, - 'Go to ', - _react2.default.createElement( - 'a', - { href: 'https://myzenwallet.io' }, - 'https://myzenwallet.io' - ) - ), - _react2.default.createElement( - 'li', - null, - 'Enter a strong but easy to remember secret phrase. Save this somewhere and do NOT forget it.' - ), - _react2.default.createElement( - 'li', - null, - 'Click the ', - _react2.default.createElement( - 'code', - null, - 'Unlock Button' - ), - ' (', - _react2.default.createElement(_unlockAlt2.default, null), - ') on the right.' - ), - _react2.default.createElement( - 'ul', - null, - _react2.default.createElement( - 'li', - null, - 'This creates a ', - _react2.default.createElement( - 'a', - { href: 'https://en.bitcoin.it/wiki/Deterministic_wallet' }, - 'deterministic wallet' - ), - ' based on your secret phrase.' - ) - ) - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - 'h3', - null, - '2. Accessing an existing wallet' - ), - _react2.default.createElement( - 'ul', - null, - _react2.default.createElement( - 'li', - null, - 'If you\'ve created a wallet on ', - _react2.default.createElement( - 'a', - { href: 'https://myzenwallet.io' }, - 'https://myzenwallet.io' - ), - ' via the secret phrase, simply re-enter the same phrase.' - ), - _react2.default.createElement( - 'li', - null, - 'For those with a ', - _react2.default.createElement( - 'code', - null, - 'wallet.dat' - ), - ' file generated by GUI wallets. Click ', - _react2.default.createElement( - 'code', - null, - 'settings' - ), - ' (', - _react2.default.createElement(_settings2.default, null), - '), select the ', - _react2.default.createElement( - 'code', - null, - 'Load wallet.dat' - ), - ' option and load your ', - _react2.default.createElement( - 'code', - null, - 'wallet.dat' - ), - ' file' - ), - _react2.default.createElement( - 'li', - null, - 'To unlock a single address, Click ', - _react2.default.createElement( - 'code', - null, - 'settings' - ), - ' (', - _react2.default.createElement(_settings2.default, null), - '), select the ', - _react2.default.createElement( - 'code', - null, - 'Paste private key' - ), - ' option, paste in your private key and click the unlock button (', - _react2.default.createElement(_unlockAlt2.default, null), - ')' - ) - ) - ) - ) - ); - } - }]); - - return ZGuide; -}(_react2.default.Component); - -exports.default = ZGuide; - /***/ }) /******/ ]); \ No newline at end of file diff --git a/dist/js/index.js b/dist/js/index.js index 4264043..84eb7eb 100644 --- a/dist/js/index.js +++ b/dist/js/index.js @@ -60,7 +60,7 @@ /******/ __webpack_require__.p = ""; /******/ /******/ // Load entry module and return exports -/******/ return __webpack_require__(__webpack_require__.s = 357); +/******/ return __webpack_require__(__webpack_require__.s = 509); /******/ }) /************************************************************************/ /******/ ([ @@ -257,493 +257,6 @@ process.umask = function() { return 0; }; /* 1 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -/** - * Use invariant() to assert state which your program assumes to be true. - * - * Provide sprintf-style format (only %s is supported) and arguments - * to provide information about what broke and what you were - * expecting. - * - * The invariant message will be stripped in production, but the invariant - * will remain to ensure logic does not differ in production. - */ - -var validateFormat = function validateFormat(format) {}; - -if (process.env.NODE_ENV !== 'production') { - validateFormat = function validateFormat(format) { - if (format === undefined) { - throw new Error('invariant requires an error message argument'); - } - }; -} - -function invariant(condition, format, a, b, c, d, e, f) { - validateFormat(format); - - if (!condition) { - var error; - if (format === undefined) { - error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); - } else { - var args = [a, b, c, d, e, f]; - var argIndex = 0; - error = new Error(format.replace(/%s/g, function () { - return args[argIndex++]; - })); - error.name = 'Invariant Violation'; - } - - error.framesToPop = 1; // we don't care about invariant's own frame - throw error; - } -} - -module.exports = invariant; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 2 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var emptyFunction = __webpack_require__(12); - -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ - -var warning = emptyFunction; - -if (process.env.NODE_ENV !== 'production') { - (function () { - var printWarning = function printWarning(format) { - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; - } - - var argIndex = 0; - var message = 'Warning: ' + format.replace(/%s/g, function () { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // --- Welcome to debugging React --- - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch (x) {} - }; - - warning = function warning(condition, format) { - if (format === undefined) { - throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); - } - - if (format.indexOf('Failed Composite propType: ') === 0) { - return; // Ignore CompositeComponent proptype check. - } - - if (!condition) { - for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { - args[_key2 - 2] = arguments[_key2]; - } - - printWarning.apply(undefined, [format].concat(args)); - } - }; - })(); -} - -module.exports = warning; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 3 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ - - -/** - * WARNING: DO NOT manually require this module. - * This is a replacement for `invariant(...)` used by the error code system - * and will _only_ be required by the corresponding babel pass. - * It always throws. - */ - -function reactProdInvariant(code) { - var argCount = arguments.length - 1; - - var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; - - for (var argIdx = 0; argIdx < argCount; argIdx++) { - message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); - } - - message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; - - var error = new Error(message); - error.name = 'Invariant Violation'; - error.framesToPop = 1; // we don't care about reactProdInvariant's own frame - - throw error; -} - -module.exports = reactProdInvariant; - -/***/ }), -/* 4 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = __webpack_require__(24); - - -/***/ }), -/* 5 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* -object-assign -(c) Sindre Sorhus -@license MIT -*/ - - -/* eslint-disable no-unused-vars */ -var getOwnPropertySymbols = Object.getOwnPropertySymbols; -var hasOwnProperty = Object.prototype.hasOwnProperty; -var propIsEnumerable = Object.prototype.propertyIsEnumerable; - -function toObject(val) { - if (val === null || val === undefined) { - throw new TypeError('Object.assign cannot be called with null or undefined'); - } - - return Object(val); -} - -function shouldUseNative() { - try { - if (!Object.assign) { - return false; - } - - // Detect buggy property enumeration order in older V8 versions. - - // https://bugs.chromium.org/p/v8/issues/detail?id=4118 - var test1 = new String('abc'); // eslint-disable-line no-new-wrappers - test1[5] = 'de'; - if (Object.getOwnPropertyNames(test1)[0] === '5') { - return false; - } - - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test2 = {}; - for (var i = 0; i < 10; i++) { - test2['_' + String.fromCharCode(i)] = i; - } - var order2 = Object.getOwnPropertyNames(test2).map(function (n) { - return test2[n]; - }); - if (order2.join('') !== '0123456789') { - return false; - } - - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test3 = {}; - 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { - test3[letter] = letter; - }); - if (Object.keys(Object.assign({}, test3)).join('') !== - 'abcdefghijklmnopqrst') { - return false; - } - - return true; - } catch (err) { - // We don't expect any of the above to throw, but better to be safe. - return false; - } -} - -module.exports = shouldUseNative() ? Object.assign : function (target, source) { - var from; - var to = toObject(target); - var symbols; - - for (var s = 1; s < arguments.length; s++) { - from = Object(arguments[s]); - - for (var key in from) { - if (hasOwnProperty.call(from, key)) { - to[key] = from[key]; - } - } - - if (getOwnPropertySymbols) { - symbols = getOwnPropertySymbols(from); - for (var i = 0; i < symbols.length; i++) { - if (propIsEnumerable.call(from, symbols[i])) { - to[symbols[i]] = from[symbols[i]]; - } - } - } - } - - return to; -}; - - -/***/ }), -/* 6 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var _prodInvariant = __webpack_require__(3); - -var DOMProperty = __webpack_require__(17); -var ReactDOMComponentFlags = __webpack_require__(81); - -var invariant = __webpack_require__(1); - -var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; -var Flags = ReactDOMComponentFlags; - -var internalInstanceKey = '__reactInternalInstance$' + Math.random().toString(36).slice(2); - -/** - * Check if a given node should be cached. - */ -function shouldPrecacheNode(node, nodeID) { - return node.nodeType === 1 && node.getAttribute(ATTR_NAME) === String(nodeID) || node.nodeType === 8 && node.nodeValue === ' react-text: ' + nodeID + ' ' || node.nodeType === 8 && node.nodeValue === ' react-empty: ' + nodeID + ' '; -} - -/** - * Drill down (through composites and empty components) until we get a host or - * host text component. - * - * This is pretty polymorphic but unavoidable with the current structure we have - * for `_renderedChildren`. - */ -function getRenderedHostOrTextFromComponent(component) { - var rendered; - while (rendered = component._renderedComponent) { - component = rendered; - } - return component; -} - -/** - * Populate `_hostNode` on the rendered host/text component with the given - * DOM node. The passed `inst` can be a composite. - */ -function precacheNode(inst, node) { - var hostInst = getRenderedHostOrTextFromComponent(inst); - hostInst._hostNode = node; - node[internalInstanceKey] = hostInst; -} - -function uncacheNode(inst) { - var node = inst._hostNode; - if (node) { - delete node[internalInstanceKey]; - inst._hostNode = null; - } -} - -/** - * Populate `_hostNode` on each child of `inst`, assuming that the children - * match up with the DOM (element) children of `node`. - * - * We cache entire levels at once to avoid an n^2 problem where we access the - * children of a node sequentially and have to walk from the start to our target - * node every time. - * - * Since we update `_renderedChildren` and the actual DOM at (slightly) - * different times, we could race here and see a newer `_renderedChildren` than - * the DOM nodes we see. To avoid this, ReactMultiChild calls - * `prepareToManageChildren` before we change `_renderedChildren`, at which - * time the container's child nodes are always cached (until it unmounts). - */ -function precacheChildNodes(inst, node) { - if (inst._flags & Flags.hasCachedChildNodes) { - return; - } - var children = inst._renderedChildren; - var childNode = node.firstChild; - outer: for (var name in children) { - if (!children.hasOwnProperty(name)) { - continue; - } - var childInst = children[name]; - var childID = getRenderedHostOrTextFromComponent(childInst)._domID; - if (childID === 0) { - // We're currently unmounting this child in ReactMultiChild; skip it. - continue; - } - // We assume the child nodes are in the same order as the child instances. - for (; childNode !== null; childNode = childNode.nextSibling) { - if (shouldPrecacheNode(childNode, childID)) { - precacheNode(childInst, childNode); - continue outer; - } - } - // We reached the end of the DOM children without finding an ID match. - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unable to find element with ID %s.', childID) : _prodInvariant('32', childID) : void 0; - } - inst._flags |= Flags.hasCachedChildNodes; -} - -/** - * Given a DOM node, return the closest ReactDOMComponent or - * ReactDOMTextComponent instance ancestor. - */ -function getClosestInstanceFromNode(node) { - if (node[internalInstanceKey]) { - return node[internalInstanceKey]; - } - - // Walk up the tree until we find an ancestor whose instance we have cached. - var parents = []; - while (!node[internalInstanceKey]) { - parents.push(node); - if (node.parentNode) { - node = node.parentNode; - } else { - // Top of the tree. This node must not be part of a React tree (or is - // unmounted, potentially). - return null; - } - } - - var closest; - var inst; - for (; node && (inst = node[internalInstanceKey]); node = parents.pop()) { - closest = inst; - if (parents.length) { - precacheChildNodes(inst, node); - } - } - - return closest; -} - -/** - * Given a DOM node, return the ReactDOMComponent or ReactDOMTextComponent - * instance, or null if the node was not rendered by this React. - */ -function getInstanceFromNode(node) { - var inst = getClosestInstanceFromNode(node); - if (inst != null && inst._hostNode === node) { - return inst; - } else { - return null; - } -} - -/** - * Given a ReactDOMComponent or ReactDOMTextComponent, return the corresponding - * DOM node. - */ -function getNodeFromInstance(inst) { - // Without this first invariant, passing a non-DOM-component triggers the next - // invariant for a missing parent, which is super confusing. - !(inst._hostNode !== undefined) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; - - if (inst._hostNode) { - return inst._hostNode; - } - - // Walk up the tree until we find an ancestor whose DOM node we have cached. - var parents = []; - while (!inst._hostNode) { - parents.push(inst); - !inst._hostParent ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React DOM tree root should always have a node reference.') : _prodInvariant('34') : void 0; - inst = inst._hostParent; - } - - // Now parents contains each ancestor that does *not* have a cached native - // node, and `inst` is the deepest ancestor that does. - for (; parents.length; inst = parents.pop()) { - precacheChildNodes(inst, inst._hostNode); - } - - return inst._hostNode; -} - -var ReactDOMComponentTree = { - getClosestInstanceFromNode: getClosestInstanceFromNode, - getInstanceFromNode: getInstanceFromNode, - getNodeFromInstance: getNodeFromInstance, - precacheChildNodes: precacheChildNodes, - precacheNode: precacheNode, - uncacheNode: uncacheNode -}; - -module.exports = ReactDOMComponentTree; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 7 */ -/***/ (function(module, exports, __webpack_require__) { - "use strict"; /* WEBPACK VAR INJECTION */(function(global) {/*! * The buffer module from node.js, for the browser. @@ -755,9 +268,9 @@ module.exports = ReactDOMComponentTree; -var base64 = __webpack_require__(359) -var ieee754 = __webpack_require__(360) -var isArray = __webpack_require__(281) +var base64 = __webpack_require__(333) +var ieee754 = __webpack_require__(334) +var isArray = __webpack_require__(154) exports.Buffer = Buffer exports.SlowBuffer = SlowBuffer @@ -2535,14 +2048,14 @@ function isnan (val) { return val !== val // eslint-disable-line no-self-compare } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(67))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) /***/ }), -/* 8 */ +/* 2 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** +/* WEBPACK VAR INJECTION */(function(process) {/** * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * @@ -2554,454 +2067,126 @@ function isnan (val) { -var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); - /** - * Simple, lightweight module assisting with the detection and context of - * Worker. Helps avoid circular dependencies and allows code to reason about - * whether or not they are in a Worker, even if they never include the main - * `ReactWorker` dependency. - */ -var ExecutionEnvironment = { - - canUseDOM: canUseDOM, - - canUseWorkers: typeof Worker !== 'undefined', - - canUseEventListeners: canUseDOM && !!(window.addEventListener || window.attachEvent), - - canUseViewport: canUseDOM && !!window.screen, - - isInWorker: !canUseDOM // For now, this is true - might change in the future. - -}; - -module.exports = ExecutionEnvironment; - -/***/ }), -/* 9 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. + * Use invariant() to assert state which your program assumes to be true. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Provide sprintf-style format (only %s is supported) and arguments + * to provide information about what broke and what you were + * expecting. + * + * The invariant message will be stripped in production, but the invariant + * will remain to ensure logic does not differ in production. */ -if (process.env.NODE_ENV !== 'production') { - var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && - Symbol.for && - Symbol.for('react.element')) || - 0xeac7; +var validateFormat = function validateFormat(format) {}; - var isValidElement = function(object) { - return typeof object === 'object' && - object !== null && - object.$$typeof === REACT_ELEMENT_TYPE; +if (process.env.NODE_ENV !== 'production') { + validateFormat = function validateFormat(format) { + if (format === undefined) { + throw new Error('invariant requires an error message argument'); + } }; +} - // By explicitly using `prop-types` you are opting into new development behavior. - // http://fb.me/prop-types-in-prod - var throwOnDirectAccess = true; - module.exports = __webpack_require__(80)(isValidElement, throwOnDirectAccess); -} else { - // By explicitly using `prop-types` you are opting into new production behavior. - // http://fb.me/prop-types-in-prod - module.exports = __webpack_require__(221)(); +function invariant(condition, format, a, b, c, d, e, f) { + validateFormat(format); + + if (!condition) { + var error; + if (format === undefined) { + error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); + } else { + var args = [a, b, c, d, e, f]; + var argIndex = 0; + error = new Error(format.replace(/%s/g, function () { + return args[argIndex++]; + })); + error.name = 'Invariant Violation'; + } + + error.framesToPop = 1; // we don't care about invariant's own frame + throw error; + } } +module.exports = invariant; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 10 */ +/* 3 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. + * Copyright 2014-2015, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -var _prodInvariant = __webpack_require__(25); - -var ReactCurrentOwner = __webpack_require__(14); - -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); - -function isNative(fn) { - // Based on isNative() from Lodash - var funcToString = Function.prototype.toString; - var hasOwnProperty = Object.prototype.hasOwnProperty; - var reIsNative = RegExp('^' + funcToString - // Take an example native function source for comparison - .call(hasOwnProperty - // Strip regex characters so we can use it for regex - ).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&' - // Remove hasOwnProperty from the template to make it generic - ).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'); - try { - var source = funcToString.call(fn); - return reIsNative.test(source); - } catch (err) { - return false; - } -} - -var canUseCollections = -// Array.from -typeof Array.from === 'function' && -// Map -typeof Map === 'function' && isNative(Map) && -// Map.prototype.keys -Map.prototype != null && typeof Map.prototype.keys === 'function' && isNative(Map.prototype.keys) && -// Set -typeof Set === 'function' && isNative(Set) && -// Set.prototype.keys -Set.prototype != null && typeof Set.prototype.keys === 'function' && isNative(Set.prototype.keys); - -var setItem; -var getItem; -var removeItem; -var getItemIDs; -var addRoot; -var removeRoot; -var getRootIDs; - -if (canUseCollections) { - var itemMap = new Map(); - var rootIDSet = new Set(); - - setItem = function (id, item) { - itemMap.set(id, item); - }; - getItem = function (id) { - return itemMap.get(id); - }; - removeItem = function (id) { - itemMap['delete'](id); - }; - getItemIDs = function () { - return Array.from(itemMap.keys()); - }; - - addRoot = function (id) { - rootIDSet.add(id); - }; - removeRoot = function (id) { - rootIDSet['delete'](id); - }; - getRootIDs = function () { - return Array.from(rootIDSet.keys()); - }; -} else { - var itemByKey = {}; - var rootByKey = {}; - - // Use non-numeric keys to prevent V8 performance issues: - // https://github.com/facebook/react/pull/7232 - var getKeyFromID = function (id) { - return '.' + id; - }; - var getIDFromKey = function (key) { - return parseInt(key.substr(1), 10); - }; - - setItem = function (id, item) { - var key = getKeyFromID(id); - itemByKey[key] = item; - }; - getItem = function (id) { - var key = getKeyFromID(id); - return itemByKey[key]; - }; - removeItem = function (id) { - var key = getKeyFromID(id); - delete itemByKey[key]; - }; - getItemIDs = function () { - return Object.keys(itemByKey).map(getIDFromKey); - }; - - addRoot = function (id) { - var key = getKeyFromID(id); - rootByKey[key] = true; - }; - removeRoot = function (id) { - var key = getKeyFromID(id); - delete rootByKey[key]; - }; - getRootIDs = function () { - return Object.keys(rootByKey).map(getIDFromKey); - }; -} - -var unmountedIDs = []; - -function purgeDeep(id) { - var item = getItem(id); - if (item) { - var childIDs = item.childIDs; - - removeItem(id); - childIDs.forEach(purgeDeep); - } -} - -function describeComponentFrame(name, source, ownerName) { - return '\n in ' + (name || 'Unknown') + (source ? ' (at ' + source.fileName.replace(/^.*[\\\/]/, '') + ':' + source.lineNumber + ')' : ownerName ? ' (created by ' + ownerName + ')' : ''); -} +var emptyFunction = __webpack_require__(18); -function getDisplayName(element) { - if (element == null) { - return '#empty'; - } else if (typeof element === 'string' || typeof element === 'number') { - return '#text'; - } else if (typeof element.type === 'string') { - return element.type; - } else { - return element.type.displayName || element.type.name || 'Unknown'; - } -} +/** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ -function describeID(id) { - var name = ReactComponentTreeHook.getDisplayName(id); - var element = ReactComponentTreeHook.getElement(id); - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var ownerName; - if (ownerID) { - ownerName = ReactComponentTreeHook.getDisplayName(ownerID); - } - process.env.NODE_ENV !== 'production' ? warning(element, 'ReactComponentTreeHook: Missing React element for debugID %s when ' + 'building stack', id) : void 0; - return describeComponentFrame(name, element && element._source, ownerName); -} +var warning = emptyFunction; -var ReactComponentTreeHook = { - onSetChildren: function (id, nextChildIDs) { - var item = getItem(id); - !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; - item.childIDs = nextChildIDs; +if (process.env.NODE_ENV !== 'production') { + (function () { + var printWarning = function printWarning(format) { + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } - for (var i = 0; i < nextChildIDs.length; i++) { - var nextChildID = nextChildIDs[i]; - var nextChild = getItem(nextChildID); - !nextChild ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected hook events to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('140') : void 0; - !(nextChild.childIDs != null || typeof nextChild.element !== 'object' || nextChild.element == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onSetChildren() to fire for a container child before its parent includes it in onSetChildren().') : _prodInvariant('141') : void 0; - !nextChild.isMounted ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onMountComponent() to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('71') : void 0; - if (nextChild.parentID == null) { - nextChild.parentID = id; - // TODO: This shouldn't be necessary but mounting a new root during in - // componentWillMount currently causes not-yet-mounted components to - // be purged from our tree data so their parent id is missing. + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.error(message); } - !(nextChild.parentID === id) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onBeforeMountComponent() parent and onSetChildren() to be consistent (%s has parents %s and %s).', nextChildID, nextChild.parentID, id) : _prodInvariant('142', nextChildID, nextChild.parentID, id) : void 0; - } - }, - onBeforeMountComponent: function (id, element, parentID) { - var item = { - element: element, - parentID: parentID, - text: null, - childIDs: [], - isMounted: false, - updateCount: 0 + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} }; - setItem(id, item); - }, - onBeforeUpdateComponent: function (id, element) { - var item = getItem(id); - if (!item || !item.isMounted) { - // We may end up here as a result of setState() in componentWillUnmount(). - // In this case, ignore the element. - return; - } - item.element = element; - }, - onMountComponent: function (id) { - var item = getItem(id); - !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; - item.isMounted = true; - var isRoot = item.parentID === 0; - if (isRoot) { - addRoot(id); - } - }, - onUpdateComponent: function (id) { - var item = getItem(id); - if (!item || !item.isMounted) { - // We may end up here as a result of setState() in componentWillUnmount(). - // In this case, ignore the element. - return; - } - item.updateCount++; - }, - onUnmountComponent: function (id) { - var item = getItem(id); - if (item) { - // We need to check if it exists. - // `item` might not exist if it is inside an error boundary, and a sibling - // error boundary child threw while mounting. Then this instance never - // got a chance to mount, but it still gets an unmounting event during - // the error boundary cleanup. - item.isMounted = false; - var isRoot = item.parentID === 0; - if (isRoot) { - removeRoot(id); - } - } - unmountedIDs.push(id); - }, - purgeUnmountedComponents: function () { - if (ReactComponentTreeHook._preventPurging) { - // Should only be used for testing. - return; - } - - for (var i = 0; i < unmountedIDs.length; i++) { - var id = unmountedIDs[i]; - purgeDeep(id); - } - unmountedIDs.length = 0; - }, - isMounted: function (id) { - var item = getItem(id); - return item ? item.isMounted : false; - }, - getCurrentStackAddendum: function (topElement) { - var info = ''; - if (topElement) { - var name = getDisplayName(topElement); - var owner = topElement._owner; - info += describeComponentFrame(name, topElement._source, owner && owner.getName()); - } - - var currentOwner = ReactCurrentOwner.current; - var id = currentOwner && currentOwner._debugID; - - info += ReactComponentTreeHook.getStackAddendumByID(id); - return info; - }, - getStackAddendumByID: function (id) { - var info = ''; - while (id) { - info += describeID(id); - id = ReactComponentTreeHook.getParentID(id); - } - return info; - }, - getChildIDs: function (id) { - var item = getItem(id); - return item ? item.childIDs : []; - }, - getDisplayName: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (!element) { - return null; - } - return getDisplayName(element); - }, - getElement: function (id) { - var item = getItem(id); - return item ? item.element : null; - }, - getOwnerID: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (!element || !element._owner) { - return null; - } - return element._owner._debugID; - }, - getParentID: function (id) { - var item = getItem(id); - return item ? item.parentID : null; - }, - getSource: function (id) { - var item = getItem(id); - var element = item ? item.element : null; - var source = element != null ? element._source : null; - return source; - }, - getText: function (id) { - var element = ReactComponentTreeHook.getElement(id); - if (typeof element === 'string') { - return element; - } else if (typeof element === 'number') { - return '' + element; - } else { - return null; - } - }, - getUpdateCount: function (id) { - var item = getItem(id); - return item ? item.updateCount : 0; - }, - - - getRootIDs: getRootIDs, - getRegisteredIDs: getItemIDs, - - pushNonStandardWarningStack: function (isCreatingElement, currentSource) { - if (typeof console.reactStack !== 'function') { - return; - } - - var stack = []; - var currentOwner = ReactCurrentOwner.current; - var id = currentOwner && currentOwner._debugID; - try { - if (isCreatingElement) { - stack.push({ - name: id ? ReactComponentTreeHook.getDisplayName(id) : null, - fileName: currentSource ? currentSource.fileName : null, - lineNumber: currentSource ? currentSource.lineNumber : null - }); + warning = function warning(condition, format) { + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); } - while (id) { - var element = ReactComponentTreeHook.getElement(id); - var parentID = ReactComponentTreeHook.getParentID(id); - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var ownerName = ownerID ? ReactComponentTreeHook.getDisplayName(ownerID) : null; - var source = element && element._source; - stack.push({ - name: ownerName, - fileName: source ? source.fileName : null, - lineNumber: source ? source.lineNumber : null - }); - id = parentID; + if (format.indexOf('Failed Composite propType: ') === 0) { + return; // Ignore CompositeComponent proptype check. } - } catch (err) { - // Internal state is messed up. - // Stop building the stack (it's just a nice to have). - } - console.reactStack(stack); - }, - popNonStandardWarningStack: function () { - if (typeof console.reactStackEnd !== 'function') { - return; - } - console.reactStackEnd(); - } -}; + if (!condition) { + for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { + args[_key2 - 2] = arguments[_key2]; + } -module.exports = ReactComponentTreeHook; + printWarning.apply(undefined, [format].concat(args)); + } + }; + })(); +} + +module.exports = warning; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 11 */ +/* 4 */ /***/ (function(module, exports) { if (typeof Object.create === 'function') { @@ -3030,12 +2215,10 @@ if (typeof Object.create === 'function') { /***/ }), -/* 12 */ +/* 5 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; - - /** * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. @@ -3047,627 +2230,450 @@ if (typeof Object.create === 'function') { * */ -function makeEmptyFunction(arg) { - return function () { - return arg; - }; -} /** - * This function accepts and discards inputs; it has no side effects. This is - * primarily useful idiomatically for overridable function endpoints which - * always need to be callable, since JS lacks a null-call idiom ala Cocoa. + * WARNING: DO NOT manually require this module. + * This is a replacement for `invariant(...)` used by the error code system + * and will _only_ be required by the corresponding babel pass. + * It always throws. */ -var emptyFunction = function emptyFunction() {}; -emptyFunction.thatReturns = makeEmptyFunction; -emptyFunction.thatReturnsFalse = makeEmptyFunction(false); -emptyFunction.thatReturnsTrue = makeEmptyFunction(true); -emptyFunction.thatReturnsNull = makeEmptyFunction(null); -emptyFunction.thatReturnsThis = function () { - return this; -}; -emptyFunction.thatReturnsArgument = function (arg) { - return arg; -}; - -module.exports = emptyFunction; - -/***/ }), -/* 13 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +function reactProdInvariant(code) { + var argCount = arguments.length - 1; + var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; + for (var argIdx = 0; argIdx < argCount; argIdx++) { + message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); + } -// Trust the developer to only use ReactInstrumentation with a __DEV__ check + message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; -var debugTool = null; + var error = new Error(message); + error.name = 'Invariant Violation'; + error.framesToPop = 1; // we don't care about reactProdInvariant's own frame -if (process.env.NODE_ENV !== 'production') { - var ReactDebugTool = __webpack_require__(145); - debugTool = ReactDebugTool; + throw error; } -module.exports = { debugTool: debugTool }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = reactProdInvariant; /***/ }), -/* 14 */ +/* 6 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +module.exports = __webpack_require__(36); -/** - * Keeps track of the current owner. - * - * The current owner is the component who should own any components that are - * currently being constructed. - */ -var ReactCurrentOwner = { - /** - * @internal - * @type {ReactComponent} - */ - current: null -}; - -module.exports = ReactCurrentOwner; /***/ }), -/* 15 */ +/* 7 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); - -var CallbackQueue = __webpack_require__(85); -var PooledClass = __webpack_require__(20); -var ReactFeatureFlags = __webpack_require__(86); -var ReactReconciler = __webpack_require__(26); -var Transaction = __webpack_require__(41); +/* eslint-disable node/no-deprecated-api */ +var buffer = __webpack_require__(1) +var Buffer = buffer.Buffer -var invariant = __webpack_require__(1); +// alternative to using Object.keys for old browsers +function copyProps (src, dst) { + for (var key in src) { + dst[key] = src[key] + } +} +if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { + module.exports = buffer +} else { + // Copy properties from require('buffer') + copyProps(buffer, exports) + exports.Buffer = SafeBuffer +} -var dirtyComponents = []; -var updateBatchNumber = 0; -var asapCallbackQueue = CallbackQueue.getPooled(); -var asapEnqueued = false; +function SafeBuffer (arg, encodingOrOffset, length) { + return Buffer(arg, encodingOrOffset, length) +} -var batchingStrategy = null; +// Copy static methods from Buffer +copyProps(Buffer, SafeBuffer) -function ensureInjected() { - !(ReactUpdates.ReactReconcileTransaction && batchingStrategy) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must inject a reconcile transaction class and batching strategy') : _prodInvariant('123') : void 0; +SafeBuffer.from = function (arg, encodingOrOffset, length) { + if (typeof arg === 'number') { + throw new TypeError('Argument must not be a number') + } + return Buffer(arg, encodingOrOffset, length) } -var NESTED_UPDATES = { - initialize: function () { - this.dirtyComponentsLength = dirtyComponents.length; - }, - close: function () { - if (this.dirtyComponentsLength !== dirtyComponents.length) { - // Additional updates were enqueued by componentDidUpdate handlers or - // similar; before our own UPDATE_QUEUEING wrapper closes, we want to run - // these new updates so that if A's componentDidUpdate calls setState on - // B, B will update before the callback A's updater provided when calling - // setState. - dirtyComponents.splice(0, this.dirtyComponentsLength); - flushBatchedUpdates(); +SafeBuffer.alloc = function (size, fill, encoding) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + var buf = Buffer(size) + if (fill !== undefined) { + if (typeof encoding === 'string') { + buf.fill(fill, encoding) } else { - dirtyComponents.length = 0; + buf.fill(fill) } + } else { + buf.fill(0) } -}; - -var UPDATE_QUEUEING = { - initialize: function () { - this.callbackQueue.reset(); - }, - close: function () { - this.callbackQueue.notifyAll(); - } -}; - -var TRANSACTION_WRAPPERS = [NESTED_UPDATES, UPDATE_QUEUEING]; - -function ReactUpdatesFlushTransaction() { - this.reinitializeTransaction(); - this.dirtyComponentsLength = null; - this.callbackQueue = CallbackQueue.getPooled(); - this.reconcileTransaction = ReactUpdates.ReactReconcileTransaction.getPooled( - /* useCreateElement */true); + return buf } -_assign(ReactUpdatesFlushTransaction.prototype, Transaction, { - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, - - destructor: function () { - this.dirtyComponentsLength = null; - CallbackQueue.release(this.callbackQueue); - this.callbackQueue = null; - ReactUpdates.ReactReconcileTransaction.release(this.reconcileTransaction); - this.reconcileTransaction = null; - }, - - perform: function (method, scope, a) { - // Essentially calls `this.reconcileTransaction.perform(method, scope, a)` - // with this transaction's wrappers around it. - return Transaction.perform.call(this, this.reconcileTransaction.perform, this.reconcileTransaction, method, scope, a); +SafeBuffer.allocUnsafe = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') } -}); - -PooledClass.addPoolingTo(ReactUpdatesFlushTransaction); - -function batchedUpdates(callback, a, b, c, d, e) { - ensureInjected(); - return batchingStrategy.batchedUpdates(callback, a, b, c, d, e); + return Buffer(size) } -/** - * Array comparator for ReactComponents by mount ordering. - * - * @param {ReactComponent} c1 first component you're comparing - * @param {ReactComponent} c2 second component you're comparing - * @return {number} Return value usable by Array.prototype.sort(). - */ -function mountOrderComparator(c1, c2) { - return c1._mountOrder - c2._mountOrder; +SafeBuffer.allocUnsafeSlow = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return buffer.SlowBuffer(size) } -function runBatchedUpdates(transaction) { - var len = transaction.dirtyComponentsLength; - !(len === dirtyComponents.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected flush transaction\'s stored dirty-components length (%s) to match dirty-components array length (%s).', len, dirtyComponents.length) : _prodInvariant('124', len, dirtyComponents.length) : void 0; - - // Since reconciling a component higher in the owner hierarchy usually (not - // always -- see shouldComponentUpdate()) will reconcile children, reconcile - // them before their children by sorting the array. - dirtyComponents.sort(mountOrderComparator); - - // Any updates enqueued while reconciling must be performed after this entire - // batch. Otherwise, if dirtyComponents is [A, B] where A has children B and - // C, B could update twice in a single batch if C's render enqueues an update - // to B (since B would have already updated, we should skip it, and the only - // way we can know to do so is by checking the batch counter). - updateBatchNumber++; - for (var i = 0; i < len; i++) { - // If a component is unmounted before pending changes apply, it will still - // be here, but we assume that it has cleared its _pendingCallbacks and - // that performUpdateIfNecessary is a noop. - var component = dirtyComponents[i]; +/***/ }), +/* 8 */ +/***/ (function(module, exports, __webpack_require__) { - // If performUpdateIfNecessary happens to enqueue any new updates, we - // shouldn't execute the callbacks until the next render happens, so - // stash the callbacks first - var callbacks = component._pendingCallbacks; - component._pendingCallbacks = null; +"use strict"; +/* +object-assign +(c) Sindre Sorhus +@license MIT +*/ - var markerName; - if (ReactFeatureFlags.logTopLevelRenders) { - var namedComponent = component; - // Duck type TopLevelWrapper. This is probably always true. - if (component._currentElement.type.isReactTopLevelWrapper) { - namedComponent = component._renderedComponent; - } - markerName = 'React update: ' + namedComponent.getName(); - console.time(markerName); - } - ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction, updateBatchNumber); +/* eslint-disable no-unused-vars */ +var getOwnPropertySymbols = Object.getOwnPropertySymbols; +var hasOwnProperty = Object.prototype.hasOwnProperty; +var propIsEnumerable = Object.prototype.propertyIsEnumerable; - if (markerName) { - console.timeEnd(markerName); - } +function toObject(val) { + if (val === null || val === undefined) { + throw new TypeError('Object.assign cannot be called with null or undefined'); + } - if (callbacks) { - for (var j = 0; j < callbacks.length; j++) { - transaction.callbackQueue.enqueue(callbacks[j], component.getPublicInstance()); - } - } - } + return Object(val); } -var flushBatchedUpdates = function () { - // ReactUpdatesFlushTransaction's wrappers will clear the dirtyComponents - // array and perform any updates enqueued by mount-ready handlers (i.e., - // componentDidUpdate) but we need to check here too in order to catch - // updates enqueued by setState callbacks and asap calls. - while (dirtyComponents.length || asapEnqueued) { - if (dirtyComponents.length) { - var transaction = ReactUpdatesFlushTransaction.getPooled(); - transaction.perform(runBatchedUpdates, null, transaction); - ReactUpdatesFlushTransaction.release(transaction); - } +function shouldUseNative() { + try { + if (!Object.assign) { + return false; + } - if (asapEnqueued) { - asapEnqueued = false; - var queue = asapCallbackQueue; - asapCallbackQueue = CallbackQueue.getPooled(); - queue.notifyAll(); - CallbackQueue.release(queue); - } - } -}; + // Detect buggy property enumeration order in older V8 versions. -/** - * Mark a component as needing a rerender, adding an optional callback to a - * list of functions which will be executed once the rerender occurs. - */ -function enqueueUpdate(component) { - ensureInjected(); + // https://bugs.chromium.org/p/v8/issues/detail?id=4118 + var test1 = new String('abc'); // eslint-disable-line no-new-wrappers + test1[5] = 'de'; + if (Object.getOwnPropertyNames(test1)[0] === '5') { + return false; + } - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. (This is called by each top-level update - // function, like setState, forceUpdate, etc.; creation and - // destruction of top-level components is guarded in ReactMount.) + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test2 = {}; + for (var i = 0; i < 10; i++) { + test2['_' + String.fromCharCode(i)] = i; + } + var order2 = Object.getOwnPropertyNames(test2).map(function (n) { + return test2[n]; + }); + if (order2.join('') !== '0123456789') { + return false; + } - if (!batchingStrategy.isBatchingUpdates) { - batchingStrategy.batchedUpdates(enqueueUpdate, component); - return; - } + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test3 = {}; + 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { + test3[letter] = letter; + }); + if (Object.keys(Object.assign({}, test3)).join('') !== + 'abcdefghijklmnopqrst') { + return false; + } - dirtyComponents.push(component); - if (component._updateBatchNumber == null) { - component._updateBatchNumber = updateBatchNumber + 1; - } + return true; + } catch (err) { + // We don't expect any of the above to throw, but better to be safe. + return false; + } } -/** - * Enqueue a callback to be run at the end of the current batching cycle. Throws - * if no updates are currently being performed. - */ -function asap(callback, context) { - !batchingStrategy.isBatchingUpdates ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates.asap: Can\'t enqueue an asap callback in a context whereupdates are not being batched.') : _prodInvariant('125') : void 0; - asapCallbackQueue.enqueue(callback, context); - asapEnqueued = true; -} +module.exports = shouldUseNative() ? Object.assign : function (target, source) { + var from; + var to = toObject(target); + var symbols; -var ReactUpdatesInjection = { - injectReconcileTransaction: function (ReconcileTransaction) { - !ReconcileTransaction ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a reconcile transaction class') : _prodInvariant('126') : void 0; - ReactUpdates.ReactReconcileTransaction = ReconcileTransaction; - }, + for (var s = 1; s < arguments.length; s++) { + from = Object(arguments[s]); - injectBatchingStrategy: function (_batchingStrategy) { - !_batchingStrategy ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batching strategy') : _prodInvariant('127') : void 0; - !(typeof _batchingStrategy.batchedUpdates === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batchedUpdates() function') : _prodInvariant('128') : void 0; - !(typeof _batchingStrategy.isBatchingUpdates === 'boolean') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide an isBatchingUpdates boolean attribute') : _prodInvariant('129') : void 0; - batchingStrategy = _batchingStrategy; - } -}; + for (var key in from) { + if (hasOwnProperty.call(from, key)) { + to[key] = from[key]; + } + } -var ReactUpdates = { - /** - * React references `ReactReconcileTransaction` using this property in order - * to allow dependency injection. - * - * @internal - */ - ReactReconcileTransaction: null, + if (getOwnPropertySymbols) { + symbols = getOwnPropertySymbols(from); + for (var i = 0; i < symbols.length; i++) { + if (propIsEnumerable.call(from, symbols[i])) { + to[symbols[i]] = from[symbols[i]]; + } + } + } + } - batchedUpdates: batchedUpdates, - enqueueUpdate: enqueueUpdate, - flushBatchedUpdates: flushBatchedUpdates, - injection: ReactUpdatesInjection, - asap: asap + return to; }; -module.exports = ReactUpdates; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 16 */ +/* 9 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var ERRORS = __webpack_require__(201) +var NATIVE = __webpack_require__(111) +// short-hand +var tfJSON = ERRORS.tfJSON +var TfTypeError = ERRORS.TfTypeError +var TfPropertyTypeError = ERRORS.TfPropertyTypeError +var tfSubError = ERRORS.tfSubError +var getValueTypeName = ERRORS.getValueTypeName +var TYPES = { + arrayOf: function arrayOf (type) { + type = compile(type) -var _assign = __webpack_require__(5); + function _arrayOf (array, strict) { + if (!NATIVE.Array(array)) return false -var PooledClass = __webpack_require__(20); + return array.every(function (value, i) { + try { + return typeforce(type, value, strict) + } catch (e) { + throw tfSubError(e, i) + } + }) + } + _arrayOf.toJSON = function () { return '[' + tfJSON(type) + ']' } -var emptyFunction = __webpack_require__(12); -var warning = __webpack_require__(2); + return _arrayOf + }, -var didWarnForAddedNewProperty = false; -var isProxySupported = typeof Proxy === 'function'; + maybe: function maybe (type) { + type = compile(type) -var shouldBeReleasedProperties = ['dispatchConfig', '_targetInst', 'nativeEvent', 'isDefaultPrevented', 'isPropagationStopped', '_dispatchListeners', '_dispatchInstances']; + function _maybe (value, strict) { + return NATIVE.Nil(value) || type(value, strict, maybe) + } + _maybe.toJSON = function () { return '?' + tfJSON(type) } -/** - * @interface Event - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var EventInterface = { - type: null, - target: null, - // currentTarget is set when dispatching; no use in copying it here - currentTarget: emptyFunction.thatReturnsNull, - eventPhase: null, - bubbles: null, - cancelable: null, - timeStamp: function (event) { - return event.timeStamp || Date.now(); + return _maybe }, - defaultPrevented: null, - isTrusted: null -}; -/** - * Synthetic events are dispatched by event plugins, typically in response to a - * top-level event delegation handler. - * - * These systems should generally use pooling to reduce the frequency of garbage - * collection. The system should check `isPersistent` to determine whether the - * event should be released into the pool after being dispatched. Users that - * need a persisted event should invoke `persist`. - * - * Synthetic events (and subclasses) implement the DOM Level 3 Events API by - * normalizing browser quirks. Subclasses do not necessarily have to implement a - * DOM interface; custom application-specific events can also subclass this. - * - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {*} targetInst Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @param {DOMEventTarget} nativeEventTarget Target node. - */ -function SyntheticEvent(dispatchConfig, targetInst, nativeEvent, nativeEventTarget) { - if (process.env.NODE_ENV !== 'production') { - // these have a getter/setter for warnings - delete this.nativeEvent; - delete this.preventDefault; - delete this.stopPropagation; - } + map: function map (propertyType, propertyKeyType) { + propertyType = compile(propertyType) + if (propertyKeyType) propertyKeyType = compile(propertyKeyType) - this.dispatchConfig = dispatchConfig; - this._targetInst = targetInst; - this.nativeEvent = nativeEvent; + function _map (value, strict) { + if (!NATIVE.Object(value, strict)) return false + if (NATIVE.Nil(value, strict)) return false - var Interface = this.constructor.Interface; - for (var propName in Interface) { - if (!Interface.hasOwnProperty(propName)) { - continue; - } - if (process.env.NODE_ENV !== 'production') { - delete this[propName]; // this has a getter/setter for warnings + for (var propertyName in value) { + try { + if (propertyKeyType) { + typeforce(propertyKeyType, propertyName, strict) + } + } catch (e) { + throw tfSubError(e, propertyName, 'key') + } + + try { + var propertyValue = value[propertyName] + typeforce(propertyType, propertyValue, strict) + } catch (e) { + throw tfSubError(e, propertyName) + } + } + + return true } - var normalize = Interface[propName]; - if (normalize) { - this[propName] = normalize(nativeEvent); - } else { - if (propName === 'target') { - this.target = nativeEventTarget; - } else { - this[propName] = nativeEvent[propName]; + + if (propertyKeyType) { + _map.toJSON = function () { + return '{' + tfJSON(propertyKeyType) + ': ' + tfJSON(propertyType) + '}' } + } else { + _map.toJSON = function () { return '{' + tfJSON(propertyType) + '}' } } - } - var defaultPrevented = nativeEvent.defaultPrevented != null ? nativeEvent.defaultPrevented : nativeEvent.returnValue === false; - if (defaultPrevented) { - this.isDefaultPrevented = emptyFunction.thatReturnsTrue; - } else { - this.isDefaultPrevented = emptyFunction.thatReturnsFalse; - } - this.isPropagationStopped = emptyFunction.thatReturnsFalse; - return this; -} + return _map + }, -_assign(SyntheticEvent.prototype, { - preventDefault: function () { - this.defaultPrevented = true; - var event = this.nativeEvent; - if (!event) { - return; + object: function object (uncompiled) { + var type = {} + + for (var typePropertyName in uncompiled) { + type[typePropertyName] = compile(uncompiled[typePropertyName]) } - if (event.preventDefault) { - event.preventDefault(); - // eslint-disable-next-line valid-typeof - } else if (typeof event.returnValue !== 'unknown') { - event.returnValue = false; + function _object (value, strict) { + if (!NATIVE.Object(value)) return false + if (NATIVE.Nil(value)) return false + + var propertyName + + try { + for (propertyName in type) { + var propertyType = type[propertyName] + var propertyValue = value[propertyName] + + typeforce(propertyType, propertyValue, strict) + } + } catch (e) { + throw tfSubError(e, propertyName) + } + + if (strict) { + for (propertyName in value) { + if (type[propertyName]) continue + + throw new TfPropertyTypeError(undefined, propertyName) + } + } + + return true } - this.isDefaultPrevented = emptyFunction.thatReturnsTrue; + _object.toJSON = function () { return tfJSON(type) } + + return _object }, - stopPropagation: function () { - var event = this.nativeEvent; - if (!event) { - return; - } + oneOf: function oneOf () { + var types = [].slice.call(arguments).map(compile) - if (event.stopPropagation) { - event.stopPropagation(); - // eslint-disable-next-line valid-typeof - } else if (typeof event.cancelBubble !== 'unknown') { - // The ChangeEventPlugin registers a "propertychange" event for - // IE. This event does not support bubbling or cancelling, and - // any references to cancelBubble throw "Member not found". A - // typeof check of "unknown" circumvents this issue (and is also - // IE specific). - event.cancelBubble = true; + function _oneOf (value, strict) { + return types.some(function (type) { + try { + return typeforce(type, value, strict) + } catch (e) { + return false + } + }) } + _oneOf.toJSON = function () { return types.map(tfJSON).join('|') } - this.isPropagationStopped = emptyFunction.thatReturnsTrue; + return _oneOf }, - /** - * We release all dispatched `SyntheticEvent`s after each event loop, adding - * them back into the pool. This allows a way to hold onto a reference that - * won't be added back into the pool. - */ - persist: function () { - this.isPersistent = emptyFunction.thatReturnsTrue; + quacksLike: function quacksLike (type) { + function _quacksLike (value) { + return type === getValueTypeName(value) + } + _quacksLike.toJSON = function () { return type } + + return _quacksLike }, - /** - * Checks if this event should be released back into the pool. - * - * @return {boolean} True if this should not be released, false otherwise. - */ - isPersistent: emptyFunction.thatReturnsFalse, + tuple: function tuple () { + var types = [].slice.call(arguments).map(compile) - /** - * `PooledClass` looks for `destructor` on each instance it releases. - */ - destructor: function () { - var Interface = this.constructor.Interface; - for (var propName in Interface) { - if (process.env.NODE_ENV !== 'production') { - Object.defineProperty(this, propName, getPooledWarningPropertyDefinition(propName, Interface[propName])); - } else { - this[propName] = null; - } - } - for (var i = 0; i < shouldBeReleasedProperties.length; i++) { - this[shouldBeReleasedProperties[i]] = null; + function _tuple (values, strict) { + return types.every(function (type, i) { + try { + return typeforce(type, values[i], strict) + } catch (e) { + throw tfSubError(e, i) + } + }) && (!strict || values.length === arguments.length) } - if (process.env.NODE_ENV !== 'production') { - Object.defineProperty(this, 'nativeEvent', getPooledWarningPropertyDefinition('nativeEvent', null)); - Object.defineProperty(this, 'preventDefault', getPooledWarningPropertyDefinition('preventDefault', emptyFunction)); - Object.defineProperty(this, 'stopPropagation', getPooledWarningPropertyDefinition('stopPropagation', emptyFunction)); + _tuple.toJSON = function () { return '(' + types.map(tfJSON).join(', ') + ')' } + + return _tuple + }, + + value: function value (expected) { + function _value (actual) { + return actual === expected } + _value.toJSON = function () { return expected } + + return _value } -}); +} -SyntheticEvent.Interface = EventInterface; +function compile (type) { + if (NATIVE.String(type)) { + if (type[0] === '?') return TYPES.maybe(compile(type.slice(1))) -if (process.env.NODE_ENV !== 'production') { - if (isProxySupported) { - /*eslint-disable no-func-assign */ - SyntheticEvent = new Proxy(SyntheticEvent, { - construct: function (target, args) { - return this.apply(target, Object.create(target.prototype), args); - }, - apply: function (constructor, that, args) { - return new Proxy(constructor.apply(that, args), { - set: function (target, prop, value) { - if (prop !== 'isPersistent' && !target.constructor.Interface.hasOwnProperty(prop) && shouldBeReleasedProperties.indexOf(prop) === -1) { - process.env.NODE_ENV !== 'production' ? warning(didWarnForAddedNewProperty || target.isPersistent(), "This synthetic event is reused for performance reasons. If you're " + "seeing this, you're adding a new property in the synthetic event object. " + 'The property is never released. See ' + 'https://fb.me/react-event-pooling for more information.') : void 0; - didWarnForAddedNewProperty = true; - } - target[prop] = value; - return true; - } - }); - } - }); - /*eslint-enable no-func-assign */ + return NATIVE[type] || TYPES.quacksLike(type) + } else if (type && NATIVE.Object(type)) { + if (NATIVE.Array(type)) return TYPES.arrayOf(compile(type[0])) + + return TYPES.object(type) + } else if (NATIVE.Function(type)) { + return type } -} -/** - * Helper to reduce boilerplate when creating subclasses. - * - * @param {function} Class - * @param {?object} Interface - */ -SyntheticEvent.augmentClass = function (Class, Interface) { - var Super = this; - var E = function () {}; - E.prototype = Super.prototype; - var prototype = new E(); + return TYPES.value(type) +} - _assign(prototype, Class.prototype); - Class.prototype = prototype; - Class.prototype.constructor = Class; +function typeforce (type, value, strict, surrogate) { + if (NATIVE.Function(type)) { + if (type(value, strict)) return true - Class.Interface = _assign({}, Super.Interface, Interface); - Class.augmentClass = Super.augmentClass; + throw new TfTypeError(surrogate || type, value) + } - PooledClass.addPoolingTo(Class, PooledClass.fourArgumentPooler); -}; + // JIT + return typeforce(compile(type), value, strict) +} -PooledClass.addPoolingTo(SyntheticEvent, PooledClass.fourArgumentPooler); +// assign types to typeforce function +for (var typeName in NATIVE) { + typeforce[typeName] = NATIVE[typeName] +} -module.exports = SyntheticEvent; +for (typeName in TYPES) { + typeforce[typeName] = TYPES[typeName] +} -/** - * Helper to nullify syntheticEvent instance properties when destructing - * - * @param {object} SyntheticEvent - * @param {String} propName - * @return {object} defineProperty object - */ -function getPooledWarningPropertyDefinition(propName, getVal) { - var isFunction = typeof getVal === 'function'; - return { - configurable: true, - set: set, - get: get - }; +var EXTRA = __webpack_require__(467) +for (typeName in EXTRA) { + typeforce[typeName] = EXTRA[typeName] +} - function set(val) { - var action = isFunction ? 'setting the method' : 'setting the property'; - warn(action, 'This is effectively a no-op'); - return val; - } +// async wrapper +function __async (type, value, strict, callback) { + // default to falsy strict if using shorthand overload + if (typeof strict === 'function') return __async(type, value, false, strict) - function get() { - var action = isFunction ? 'accessing the method' : 'accessing the property'; - var result = isFunction ? 'This is a no-op function' : 'This is set to null'; - warn(action, result); - return getVal; + try { + typeforce(type, value, strict) + } catch (e) { + return callback(e) } - function warn(action, result) { - var warningCondition = false; - process.env.NODE_ENV !== 'production' ? warning(warningCondition, "This synthetic event is reused for performance reasons. If you're seeing this, " + "you're %s `%s` on a released/nullified synthetic event. %s. " + 'If you must keep the original synthetic event around, use event.persist(). ' + 'See https://fb.me/react-event-pooling for more information.', action, propName, result) : void 0; - } + callback() } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +typeforce.async = __async +typeforce.compile = compile +typeforce.TfTypeError = TfTypeError +typeforce.TfPropertyTypeError = TfPropertyTypeError + +module.exports = typeforce + /***/ }), -/* 17 */ +/* 10 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -3683,2105 +2689,1222 @@ function getPooledWarningPropertyDefinition(propName, getVal) { -var _prodInvariant = __webpack_require__(3); - -var invariant = __webpack_require__(1); - -function checkMask(value, bitmask) { - return (value & bitmask) === bitmask; -} - -var DOMPropertyInjection = { - /** - * Mapping from normalized, camelcased property names to a configuration that - * specifies how the associated DOM property should be accessed or rendered. - */ - MUST_USE_PROPERTY: 0x1, - HAS_BOOLEAN_VALUE: 0x4, - HAS_NUMERIC_VALUE: 0x8, - HAS_POSITIVE_NUMERIC_VALUE: 0x10 | 0x8, - HAS_OVERLOADED_BOOLEAN_VALUE: 0x20, +var _prodInvariant = __webpack_require__(5); - /** - * Inject some specialized knowledge about the DOM. This takes a config object - * with the following properties: - * - * isCustomAttribute: function that given an attribute name will return true - * if it can be inserted into the DOM verbatim. Useful for data-* or aria-* - * attributes where it's impossible to enumerate all of the possible - * attribute names, - * - * Properties: object mapping DOM property name to one of the - * DOMPropertyInjection constants or null. If your attribute isn't in here, - * it won't get written to the DOM. - * - * DOMAttributeNames: object mapping React attribute name to the DOM - * attribute name. Attribute names not specified use the **lowercase** - * normalized name. - * - * DOMAttributeNamespaces: object mapping React attribute name to the DOM - * attribute namespace URL. (Attribute names not specified use no namespace.) - * - * DOMPropertyNames: similar to DOMAttributeNames but for DOM properties. - * Property names not specified use the normalized name. - * - * DOMMutationMethods: Properties that require special mutation methods. If - * `value` is undefined, the mutation method should unset the property. - * - * @param {object} domPropertyConfig the config as described above. - */ - injectDOMPropertyConfig: function (domPropertyConfig) { - var Injection = DOMPropertyInjection; - var Properties = domPropertyConfig.Properties || {}; - var DOMAttributeNamespaces = domPropertyConfig.DOMAttributeNamespaces || {}; - var DOMAttributeNames = domPropertyConfig.DOMAttributeNames || {}; - var DOMPropertyNames = domPropertyConfig.DOMPropertyNames || {}; - var DOMMutationMethods = domPropertyConfig.DOMMutationMethods || {}; +var DOMProperty = __webpack_require__(28); +var ReactDOMComponentFlags = __webpack_require__(126); - if (domPropertyConfig.isCustomAttribute) { - DOMProperty._isCustomAttributeFunctions.push(domPropertyConfig.isCustomAttribute); - } +var invariant = __webpack_require__(2); - for (var propName in Properties) { - !!DOMProperty.properties.hasOwnProperty(propName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'injectDOMPropertyConfig(...): You\'re trying to inject DOM property \'%s\' which has already been injected. You may be accidentally injecting the same DOM property config twice, or you may be injecting two configs that have conflicting property names.', propName) : _prodInvariant('48', propName) : void 0; +var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; +var Flags = ReactDOMComponentFlags; - var lowerCased = propName.toLowerCase(); - var propConfig = Properties[propName]; +var internalInstanceKey = '__reactInternalInstance$' + Math.random().toString(36).slice(2); - var propertyInfo = { - attributeName: lowerCased, - attributeNamespace: null, - propertyName: propName, - mutationMethod: null, +/** + * Check if a given node should be cached. + */ +function shouldPrecacheNode(node, nodeID) { + return node.nodeType === 1 && node.getAttribute(ATTR_NAME) === String(nodeID) || node.nodeType === 8 && node.nodeValue === ' react-text: ' + nodeID + ' ' || node.nodeType === 8 && node.nodeValue === ' react-empty: ' + nodeID + ' '; +} - mustUseProperty: checkMask(propConfig, Injection.MUST_USE_PROPERTY), - hasBooleanValue: checkMask(propConfig, Injection.HAS_BOOLEAN_VALUE), - hasNumericValue: checkMask(propConfig, Injection.HAS_NUMERIC_VALUE), - hasPositiveNumericValue: checkMask(propConfig, Injection.HAS_POSITIVE_NUMERIC_VALUE), - hasOverloadedBooleanValue: checkMask(propConfig, Injection.HAS_OVERLOADED_BOOLEAN_VALUE) - }; - !(propertyInfo.hasBooleanValue + propertyInfo.hasNumericValue + propertyInfo.hasOverloadedBooleanValue <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'DOMProperty: Value can be one of boolean, overloaded boolean, or numeric value, but not a combination: %s', propName) : _prodInvariant('50', propName) : void 0; +/** + * Drill down (through composites and empty components) until we get a host or + * host text component. + * + * This is pretty polymorphic but unavoidable with the current structure we have + * for `_renderedChildren`. + */ +function getRenderedHostOrTextFromComponent(component) { + var rendered; + while (rendered = component._renderedComponent) { + component = rendered; + } + return component; +} - if (process.env.NODE_ENV !== 'production') { - DOMProperty.getPossibleStandardName[lowerCased] = propName; - } +/** + * Populate `_hostNode` on the rendered host/text component with the given + * DOM node. The passed `inst` can be a composite. + */ +function precacheNode(inst, node) { + var hostInst = getRenderedHostOrTextFromComponent(inst); + hostInst._hostNode = node; + node[internalInstanceKey] = hostInst; +} - if (DOMAttributeNames.hasOwnProperty(propName)) { - var attributeName = DOMAttributeNames[propName]; - propertyInfo.attributeName = attributeName; - if (process.env.NODE_ENV !== 'production') { - DOMProperty.getPossibleStandardName[attributeName] = propName; - } - } +function uncacheNode(inst) { + var node = inst._hostNode; + if (node) { + delete node[internalInstanceKey]; + inst._hostNode = null; + } +} - if (DOMAttributeNamespaces.hasOwnProperty(propName)) { - propertyInfo.attributeNamespace = DOMAttributeNamespaces[propName]; +/** + * Populate `_hostNode` on each child of `inst`, assuming that the children + * match up with the DOM (element) children of `node`. + * + * We cache entire levels at once to avoid an n^2 problem where we access the + * children of a node sequentially and have to walk from the start to our target + * node every time. + * + * Since we update `_renderedChildren` and the actual DOM at (slightly) + * different times, we could race here and see a newer `_renderedChildren` than + * the DOM nodes we see. To avoid this, ReactMultiChild calls + * `prepareToManageChildren` before we change `_renderedChildren`, at which + * time the container's child nodes are always cached (until it unmounts). + */ +function precacheChildNodes(inst, node) { + if (inst._flags & Flags.hasCachedChildNodes) { + return; + } + var children = inst._renderedChildren; + var childNode = node.firstChild; + outer: for (var name in children) { + if (!children.hasOwnProperty(name)) { + continue; + } + var childInst = children[name]; + var childID = getRenderedHostOrTextFromComponent(childInst)._domID; + if (childID === 0) { + // We're currently unmounting this child in ReactMultiChild; skip it. + continue; + } + // We assume the child nodes are in the same order as the child instances. + for (; childNode !== null; childNode = childNode.nextSibling) { + if (shouldPrecacheNode(childNode, childID)) { + precacheNode(childInst, childNode); + continue outer; } + } + // We reached the end of the DOM children without finding an ID match. + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unable to find element with ID %s.', childID) : _prodInvariant('32', childID) : void 0; + } + inst._flags |= Flags.hasCachedChildNodes; +} - if (DOMPropertyNames.hasOwnProperty(propName)) { - propertyInfo.propertyName = DOMPropertyNames[propName]; - } +/** + * Given a DOM node, return the closest ReactDOMComponent or + * ReactDOMTextComponent instance ancestor. + */ +function getClosestInstanceFromNode(node) { + if (node[internalInstanceKey]) { + return node[internalInstanceKey]; + } - if (DOMMutationMethods.hasOwnProperty(propName)) { - propertyInfo.mutationMethod = DOMMutationMethods[propName]; - } + // Walk up the tree until we find an ancestor whose instance we have cached. + var parents = []; + while (!node[internalInstanceKey]) { + parents.push(node); + if (node.parentNode) { + node = node.parentNode; + } else { + // Top of the tree. This node must not be part of a React tree (or is + // unmounted, potentially). + return null; + } + } - DOMProperty.properties[propName] = propertyInfo; + var closest; + var inst; + for (; node && (inst = node[internalInstanceKey]); node = parents.pop()) { + closest = inst; + if (parents.length) { + precacheChildNodes(inst, node); } } -}; -/* eslint-disable max-len */ -var ATTRIBUTE_NAME_START_CHAR = ':A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD'; -/* eslint-enable max-len */ + return closest; +} /** - * DOMProperty exports lookup objects that can be used like functions: - * - * > DOMProperty.isValid['id'] - * true - * > DOMProperty.isValid['foobar'] - * undefined - * - * Although this may be confusing, it performs better in general. - * - * @see http://jsperf.com/key-exists - * @see http://jsperf.com/key-missing + * Given a DOM node, return the ReactDOMComponent or ReactDOMTextComponent + * instance, or null if the node was not rendered by this React. */ -var DOMProperty = { - ID_ATTRIBUTE_NAME: 'data-reactid', - ROOT_ATTRIBUTE_NAME: 'data-reactroot', - - ATTRIBUTE_NAME_START_CHAR: ATTRIBUTE_NAME_START_CHAR, - ATTRIBUTE_NAME_CHAR: ATTRIBUTE_NAME_START_CHAR + '\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040', +function getInstanceFromNode(node) { + var inst = getClosestInstanceFromNode(node); + if (inst != null && inst._hostNode === node) { + return inst; + } else { + return null; + } +} - /** - * Map from property "standard name" to an object with info about how to set - * the property in the DOM. Each object contains: - * - * attributeName: - * Used when rendering markup or with `*Attribute()`. - * attributeNamespace - * propertyName: - * Used on DOM node instances. (This includes properties that mutate due to - * external factors.) - * mutationMethod: - * If non-null, used instead of the property or `setAttribute()` after - * initial render. - * mustUseProperty: - * Whether the property must be accessed and mutated as an object property. - * hasBooleanValue: - * Whether the property should be removed when set to a falsey value. - * hasNumericValue: - * Whether the property must be numeric or parse as a numeric and should be - * removed when set to a falsey value. - * hasPositiveNumericValue: - * Whether the property must be positive numeric or parse as a positive - * numeric and should be removed when set to a falsey value. - * hasOverloadedBooleanValue: - * Whether the property can be used as a flag as well as with a value. - * Removed when strictly equal to false; present without a value when - * strictly equal to true; present with a value otherwise. - */ - properties: {}, +/** + * Given a ReactDOMComponent or ReactDOMTextComponent, return the corresponding + * DOM node. + */ +function getNodeFromInstance(inst) { + // Without this first invariant, passing a non-DOM-component triggers the next + // invariant for a missing parent, which is super confusing. + !(inst._hostNode !== undefined) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; - /** - * Mapping from lowercase property names to the properly cased version, used - * to warn in the case of missing properties. Available only in __DEV__. - * - * autofocus is predefined, because adding it to the property whitelist - * causes unintended side effects. - * - * @type {Object} - */ - getPossibleStandardName: process.env.NODE_ENV !== 'production' ? { autofocus: 'autoFocus' } : null, + if (inst._hostNode) { + return inst._hostNode; + } - /** - * All of the isCustomAttribute() functions that have been injected. - */ - _isCustomAttributeFunctions: [], + // Walk up the tree until we find an ancestor whose DOM node we have cached. + var parents = []; + while (!inst._hostNode) { + parents.push(inst); + !inst._hostParent ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React DOM tree root should always have a node reference.') : _prodInvariant('34') : void 0; + inst = inst._hostParent; + } - /** - * Checks whether a property name is a custom attribute. - * @method - */ - isCustomAttribute: function (attributeName) { - for (var i = 0; i < DOMProperty._isCustomAttributeFunctions.length; i++) { - var isCustomAttributeFn = DOMProperty._isCustomAttributeFunctions[i]; - if (isCustomAttributeFn(attributeName)) { - return true; - } - } - return false; - }, + // Now parents contains each ancestor that does *not* have a cached native + // node, and `inst` is the deepest ancestor that does. + for (; parents.length; inst = parents.pop()) { + precacheChildNodes(inst, inst._hostNode); + } - injection: DOMPropertyInjection + return inst._hostNode; +} + +var ReactDOMComponentTree = { + getClosestInstanceFromNode: getClosestInstanceFromNode, + getInstanceFromNode: getInstanceFromNode, + getNodeFromInstance: getNodeFromInstance, + precacheChildNodes: precacheChildNodes, + precacheNode: precacheNode, + uncacheNode: uncacheNode }; -module.exports = DOMProperty; +module.exports = ReactDOMComponentTree; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 18 */ +/* 11 */ /***/ (function(module, exports, __webpack_require__) { -/* eslint-disable node/no-deprecated-api */ -var buffer = __webpack_require__(7) -var Buffer = buffer.Buffer +/* WEBPACK VAR INJECTION */(function(module) {(function (module, exports) { + 'use strict'; -// alternative to using Object.keys for old browsers -function copyProps (src, dst) { - for (var key in src) { - dst[key] = src[key] + // Utils + function assert (val, msg) { + if (!val) throw new Error(msg || 'Assertion failed'); } -} -if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { - module.exports = buffer -} else { - // Copy properties from require('buffer') - copyProps(buffer, exports) - exports.Buffer = SafeBuffer -} - -function SafeBuffer (arg, encodingOrOffset, length) { - return Buffer(arg, encodingOrOffset, length) -} - -// Copy static methods from Buffer -copyProps(Buffer, SafeBuffer) -SafeBuffer.from = function (arg, encodingOrOffset, length) { - if (typeof arg === 'number') { - throw new TypeError('Argument must not be a number') + // Could use `inherits` module, but don't want to move from single file + // architecture yet. + function inherits (ctor, superCtor) { + ctor.super_ = superCtor; + var TempCtor = function () {}; + TempCtor.prototype = superCtor.prototype; + ctor.prototype = new TempCtor(); + ctor.prototype.constructor = ctor; } - return Buffer(arg, encodingOrOffset, length) -} -SafeBuffer.alloc = function (size, fill, encoding) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - var buf = Buffer(size) - if (fill !== undefined) { - if (typeof encoding === 'string') { - buf.fill(fill, encoding) - } else { - buf.fill(fill) - } - } else { - buf.fill(0) - } - return buf -} + // BN -SafeBuffer.allocUnsafe = function (size) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - return Buffer(size) -} + function BN (number, base, endian) { + if (BN.isBN(number)) { + return number; + } -SafeBuffer.allocUnsafeSlow = function (size) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - return buffer.SlowBuffer(size) -} + this.negative = 0; + this.words = null; + this.length = 0; + // Reduction context + this.red = null; -/***/ }), -/* 19 */ -/***/ (function(module, exports, __webpack_require__) { + if (number !== null) { + if (base === 'le' || base === 'be') { + endian = base; + base = 10; + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + this._init(number || 0, base || 10, endian || 'be'); + } + } + if (typeof module === 'object') { + module.exports = BN; + } else { + exports.BN = BN; + } + BN.BN = BN; + BN.wordSize = 26; + var Buffer; + try { + // Obfuscate that we require Buffer, to reduce size + Buffer = __webpack_require__(1).Buffer; + } catch (e) { + } -var _assign = __webpack_require__(5); + BN.isBN = function isBN (num) { + if (num instanceof BN) { + return true; + } -var ReactCurrentOwner = __webpack_require__(14); + return num !== null && typeof num === 'object' && + num.constructor.wordSize === BN.wordSize && Array.isArray(num.words); + }; -var warning = __webpack_require__(2); -var canDefineProperty = __webpack_require__(38); -var hasOwnProperty = Object.prototype.hasOwnProperty; + BN.max = function max (left, right) { + if (left.cmp(right) > 0) return left; + return right; + }; -var REACT_ELEMENT_TYPE = __webpack_require__(76); + BN.min = function min (left, right) { + if (left.cmp(right) < 0) return left; + return right; + }; -var RESERVED_PROPS = { - key: true, - ref: true, - __self: true, - __source: true -}; + BN.prototype._init = function init (number, base, endian) { + if (typeof number === 'number') { + return this._initNumber(number, base, endian); + } -var specialPropKeyWarningShown, specialPropRefWarningShown; + if (typeof number === 'object') { + return this._initArray(number, base, endian); + } -function hasValidRef(config) { - if (process.env.NODE_ENV !== 'production') { - if (hasOwnProperty.call(config, 'ref')) { - var getter = Object.getOwnPropertyDescriptor(config, 'ref').get; - if (getter && getter.isReactWarning) { - return false; - } + if (base === 'hex') { + base = 16; } - } - return config.ref !== undefined; -} + assert(base === (base | 0) && base >= 2 && base <= 36); -function hasValidKey(config) { - if (process.env.NODE_ENV !== 'production') { - if (hasOwnProperty.call(config, 'key')) { - var getter = Object.getOwnPropertyDescriptor(config, 'key').get; - if (getter && getter.isReactWarning) { - return false; - } + number = number.toString().replace(/\s+/g, ''); + var start = 0; + if (number[0] === '-') { + start++; } - } - return config.key !== undefined; -} -function defineKeyPropWarningGetter(props, displayName) { - var warnAboutAccessingKey = function () { - if (!specialPropKeyWarningShown) { - specialPropKeyWarningShown = true; - process.env.NODE_ENV !== 'production' ? warning(false, '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + if (base === 16) { + this._parseHex(number, start); + } else { + this._parseBase(number, base, start); } - }; - warnAboutAccessingKey.isReactWarning = true; - Object.defineProperty(props, 'key', { - get: warnAboutAccessingKey, - configurable: true - }); -} -function defineRefPropWarningGetter(props, displayName) { - var warnAboutAccessingRef = function () { - if (!specialPropRefWarningShown) { - specialPropRefWarningShown = true; - process.env.NODE_ENV !== 'production' ? warning(false, '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + if (number[0] === '-') { + this.negative = 1; } - }; - warnAboutAccessingRef.isReactWarning = true; - Object.defineProperty(props, 'ref', { - get: warnAboutAccessingRef, - configurable: true - }); -} -/** - * Factory method to create a new React element. This no longer adheres to - * the class pattern, so do not use new to call it. Also, no instanceof check - * will work. Instead test $$typeof field against Symbol.for('react.element') to check - * if something is a React Element. - * - * @param {*} type - * @param {*} key - * @param {string|object} ref - * @param {*} self A *temporary* helper to detect places where `this` is - * different from the `owner` when React.createElement is called, so that we - * can warn. We want to get rid of owner and replace string `ref`s with arrow - * functions, and as long as `this` and owner are the same, there will be no - * change in behavior. - * @param {*} source An annotation object (added by a transpiler or otherwise) - * indicating filename, line number, and/or other information. - * @param {*} owner - * @param {*} props - * @internal - */ -var ReactElement = function (type, key, ref, self, source, owner, props) { - var element = { - // This tag allow us to uniquely identify this as a React Element - $$typeof: REACT_ELEMENT_TYPE, + this.strip(); - // Built-in properties that belong on the element - type: type, - key: key, - ref: ref, - props: props, + if (endian !== 'le') return; - // Record the component responsible for creating this element. - _owner: owner + this._initArray(this.toArray(), base, endian); }; - if (process.env.NODE_ENV !== 'production') { - // The validation flag is currently mutative. We put it on - // an external backing store so that we can freeze the whole object. - // This can be replaced with a WeakMap once they are implemented in - // commonly used development environments. - element._store = {}; - - // To make comparing ReactElements easier for testing purposes, we make - // the validation flag non-enumerable (where possible, which should - // include every environment we run tests in), so the test framework - // ignores it. - if (canDefineProperty) { - Object.defineProperty(element._store, 'validated', { - configurable: false, - enumerable: false, - writable: true, - value: false - }); - // self and source are DEV only properties. - Object.defineProperty(element, '_self', { - configurable: false, - enumerable: false, - writable: false, - value: self - }); - // Two elements created in two different places should be considered - // equal for testing purposes and therefore we hide it from enumeration. - Object.defineProperty(element, '_source', { - configurable: false, - enumerable: false, - writable: false, - value: source - }); - } else { - element._store.validated = false; - element._self = self; - element._source = source; + BN.prototype._initNumber = function _initNumber (number, base, endian) { + if (number < 0) { + this.negative = 1; + number = -number; } - if (Object.freeze) { - Object.freeze(element.props); - Object.freeze(element); + if (number < 0x4000000) { + this.words = [ number & 0x3ffffff ]; + this.length = 1; + } else if (number < 0x10000000000000) { + this.words = [ + number & 0x3ffffff, + (number / 0x4000000) & 0x3ffffff + ]; + this.length = 2; + } else { + assert(number < 0x20000000000000); // 2 ^ 53 (unsafe) + this.words = [ + number & 0x3ffffff, + (number / 0x4000000) & 0x3ffffff, + 1 + ]; + this.length = 3; } - } - - return element; -}; - -/** - * Create and return a new ReactElement of the given type. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createelement - */ -ReactElement.createElement = function (type, config, children) { - var propName; - // Reserved names are extracted - var props = {}; + if (endian !== 'le') return; - var key = null; - var ref = null; - var self = null; - var source = null; + // Reverse the bytes + this._initArray(this.toArray(), base, endian); + }; - if (config != null) { - if (hasValidRef(config)) { - ref = config.ref; - } - if (hasValidKey(config)) { - key = '' + config.key; + BN.prototype._initArray = function _initArray (number, base, endian) { + // Perhaps a Uint8Array + assert(typeof number.length === 'number'); + if (number.length <= 0) { + this.words = [ 0 ]; + this.length = 1; + return this; } - self = config.__self === undefined ? null : config.__self; - source = config.__source === undefined ? null : config.__source; - // Remaining properties are added to a new props object - for (propName in config) { - if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { - props[propName] = config[propName]; - } + this.length = Math.ceil(number.length / 3); + this.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + this.words[i] = 0; } - } - // Children can be more than one argument, and those are transferred onto - // the newly allocated props object. - var childrenLength = arguments.length - 2; - if (childrenLength === 1) { - props.children = children; - } else if (childrenLength > 1) { - var childArray = Array(childrenLength); - for (var i = 0; i < childrenLength; i++) { - childArray[i] = arguments[i + 2]; - } - if (process.env.NODE_ENV !== 'production') { - if (Object.freeze) { - Object.freeze(childArray); + var j, w; + var off = 0; + if (endian === 'be') { + for (i = number.length - 1, j = 0; i >= 0; i -= 3) { + w = number[i] | (number[i - 1] << 8) | (number[i - 2] << 16); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] = (w >>> (26 - off)) & 0x3ffffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } } - } - props.children = childArray; - } - - // Resolve default props - if (type && type.defaultProps) { - var defaultProps = type.defaultProps; - for (propName in defaultProps) { - if (props[propName] === undefined) { - props[propName] = defaultProps[propName]; + } else if (endian === 'le') { + for (i = 0, j = 0; i < number.length; i += 3) { + w = number[i] | (number[i + 1] << 8) | (number[i + 2] << 16); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] = (w >>> (26 - off)) & 0x3ffffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } } } - } - if (process.env.NODE_ENV !== 'production') { - if (key || ref) { - if (typeof props.$$typeof === 'undefined' || props.$$typeof !== REACT_ELEMENT_TYPE) { - var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type; - if (key) { - defineKeyPropWarningGetter(props, displayName); - } - if (ref) { - defineRefPropWarningGetter(props, displayName); - } + return this.strip(); + }; + + function parseHex (str, start, end) { + var r = 0; + var len = Math.min(str.length, end); + for (var i = start; i < len; i++) { + var c = str.charCodeAt(i) - 48; + + r <<= 4; + + // 'a' - 'f' + if (c >= 49 && c <= 54) { + r |= c - 49 + 0xa; + + // 'A' - 'F' + } else if (c >= 17 && c <= 22) { + r |= c - 17 + 0xa; + + // '0' - '9' + } else { + r |= c & 0xf; } } + return r; } - return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props); -}; -/** - * Return a function that produces ReactElements of a given type. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createfactory - */ -ReactElement.createFactory = function (type) { - var factory = ReactElement.createElement.bind(null, type); - // Expose the type on the factory and the prototype so that it can be - // easily accessed on elements. E.g. `<Foo />.type === Foo`. - // This should not be named `constructor` since this may not be the function - // that created the element, and it may not even be a constructor. - // Legacy hook TODO: Warn if this is accessed - factory.type = type; - return factory; -}; - -ReactElement.cloneAndReplaceKey = function (oldElement, newKey) { - var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props); - - return newElement; -}; + BN.prototype._parseHex = function _parseHex (number, start) { + // Create possibly bigger array to ensure that it fits the number + this.length = Math.ceil((number.length - start) / 6); + this.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + this.words[i] = 0; + } -/** - * Clone and return a new ReactElement using element as the starting point. - * See https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement - */ -ReactElement.cloneElement = function (element, config, children) { - var propName; + var j, w; + // Scan 24-bit chunks and add them to the number + var off = 0; + for (i = number.length - 6, j = 0; i >= start; i -= 6) { + w = parseHex(number, i, i + 6); + this.words[j] |= (w << off) & 0x3ffffff; + // NOTE: `0x3fffff` is intentional here, 26bits max shift + 24bit hex limb + this.words[j + 1] |= w >>> (26 - off) & 0x3fffff; + off += 24; + if (off >= 26) { + off -= 26; + j++; + } + } + if (i + 6 !== start) { + w = parseHex(number, start, i + 6); + this.words[j] |= (w << off) & 0x3ffffff; + this.words[j + 1] |= w >>> (26 - off) & 0x3fffff; + } + this.strip(); + }; - // Original props are copied - var props = _assign({}, element.props); + function parseBase (str, start, end, mul) { + var r = 0; + var len = Math.min(str.length, end); + for (var i = start; i < len; i++) { + var c = str.charCodeAt(i) - 48; - // Reserved names are extracted - var key = element.key; - var ref = element.ref; - // Self is preserved since the owner is preserved. - var self = element._self; - // Source is preserved since cloneElement is unlikely to be targeted by a - // transpiler, and the original source is probably a better indicator of the - // true owner. - var source = element._source; + r *= mul; - // Owner will be preserved, unless ref is overridden - var owner = element._owner; + // 'a' + if (c >= 49) { + r += c - 49 + 0xa; - if (config != null) { - if (hasValidRef(config)) { - // Silently steal the ref from the parent. - ref = config.ref; - owner = ReactCurrentOwner.current; - } - if (hasValidKey(config)) { - key = '' + config.key; - } + // 'A' + } else if (c >= 17) { + r += c - 17 + 0xa; - // Remaining properties override existing props - var defaultProps; - if (element.type && element.type.defaultProps) { - defaultProps = element.type.defaultProps; - } - for (propName in config) { - if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { - if (config[propName] === undefined && defaultProps !== undefined) { - // Resolve default props - props[propName] = defaultProps[propName]; - } else { - props[propName] = config[propName]; - } + // '0' - '9' + } else { + r += c; } } + return r; } - // Children can be more than one argument, and those are transferred onto - // the newly allocated props object. - var childrenLength = arguments.length - 2; - if (childrenLength === 1) { - props.children = children; - } else if (childrenLength > 1) { - var childArray = Array(childrenLength); - for (var i = 0; i < childrenLength; i++) { - childArray[i] = arguments[i + 2]; - } - props.children = childArray; - } + BN.prototype._parseBase = function _parseBase (number, base, start) { + // Initialize as zero + this.words = [ 0 ]; + this.length = 1; - return ReactElement(element.type, key, ref, self, source, owner, props); -}; + // Find length of limb in base + for (var limbLen = 0, limbPow = 1; limbPow <= 0x3ffffff; limbPow *= base) { + limbLen++; + } + limbLen--; + limbPow = (limbPow / base) | 0; -/** - * Verifies the object is a ReactElement. - * See https://facebook.github.io/react/docs/top-level-api.html#react.isvalidelement - * @param {?object} object - * @return {boolean} True if `object` is a valid component. - * @final - */ -ReactElement.isValidElement = function (object) { - return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE; -}; + var total = number.length - start; + var mod = total % limbLen; + var end = Math.min(total, total - mod) + start; -module.exports = ReactElement; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var word = 0; + for (var i = start; i < end; i += limbLen) { + word = parseBase(number, i, i + limbLen, base); -/***/ }), -/* 20 */ -/***/ (function(module, exports, __webpack_require__) { + this.imuln(limbPow); + if (this.words[0] + word < 0x4000000) { + this.words[0] += word; + } else { + this._iaddn(word); + } + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + if (mod !== 0) { + var pow = 1; + word = parseBase(number, i, number.length, base); + for (i = 0; i < mod; i++) { + pow *= base; + } + this.imuln(pow); + if (this.words[0] + word < 0x4000000) { + this.words[0] += word; + } else { + this._iaddn(word); + } + } + }; -var _prodInvariant = __webpack_require__(3); + BN.prototype.copy = function copy (dest) { + dest.words = new Array(this.length); + for (var i = 0; i < this.length; i++) { + dest.words[i] = this.words[i]; + } + dest.length = this.length; + dest.negative = this.negative; + dest.red = this.red; + }; -var invariant = __webpack_require__(1); + BN.prototype.clone = function clone () { + var r = new BN(null); + this.copy(r); + return r; + }; -/** - * Static poolers. Several custom versions for each potential number of - * arguments. A completely generic pooler is easy to implement, but would - * require accessing the `arguments` object. In each of these, `this` refers to - * the Class itself, not an instance. If any others are needed, simply add them - * here, or in their own files. - */ -var oneArgumentPooler = function (copyFieldsFrom) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, copyFieldsFrom); - return instance; - } else { - return new Klass(copyFieldsFrom); - } -}; + BN.prototype._expand = function _expand (size) { + while (this.length < size) { + this.words[this.length++] = 0; + } + return this; + }; -var twoArgumentPooler = function (a1, a2) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2); - return instance; - } else { - return new Klass(a1, a2); - } -}; + // Remove leading `0` from `this` + BN.prototype.strip = function strip () { + while (this.length > 1 && this.words[this.length - 1] === 0) { + this.length--; + } + return this._normSign(); + }; -var threeArgumentPooler = function (a1, a2, a3) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3); - return instance; - } else { - return new Klass(a1, a2, a3); - } -}; + BN.prototype._normSign = function _normSign () { + // -0 = 0 + if (this.length === 1 && this.words[0] === 0) { + this.negative = 0; + } + return this; + }; -var fourArgumentPooler = function (a1, a2, a3, a4) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3, a4); - return instance; - } else { - return new Klass(a1, a2, a3, a4); - } -}; + BN.prototype.inspect = function inspect () { + return (this.red ? '<BN-R: ' : '<BN: ') + this.toString(16) + '>'; + }; -var standardReleaser = function (instance) { - var Klass = this; - !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; - instance.destructor(); - if (Klass.instancePool.length < Klass.poolSize) { - Klass.instancePool.push(instance); - } -}; + /* -var DEFAULT_POOL_SIZE = 10; -var DEFAULT_POOLER = oneArgumentPooler; + var zeros = []; + var groupSizes = []; + var groupBases = []; -/** - * Augments `CopyConstructor` to be a poolable class, augmenting only the class - * itself (statically) not adding any prototypical fields. Any CopyConstructor - * you give this may have a `poolSize` property, and will look for a - * prototypical `destructor` on instances. - * - * @param {Function} CopyConstructor Constructor that can be used to reset. - * @param {Function} pooler Customizable pooler. - */ -var addPoolingTo = function (CopyConstructor, pooler) { - // Casting as any so that flow ignores the actual implementation and trusts - // it to match the type we declared - var NewKlass = CopyConstructor; - NewKlass.instancePool = []; - NewKlass.getPooled = pooler || DEFAULT_POOLER; - if (!NewKlass.poolSize) { - NewKlass.poolSize = DEFAULT_POOL_SIZE; + var s = ''; + var i = -1; + while (++i < BN.wordSize) { + zeros[i] = s; + s += '0'; + } + groupSizes[0] = 0; + groupSizes[1] = 0; + groupBases[0] = 0; + groupBases[1] = 0; + var base = 2 - 1; + while (++base < 36 + 1) { + var groupSize = 0; + var groupBase = 1; + while (groupBase < (1 << BN.wordSize) / base) { + groupBase *= base; + groupSize += 1; + } + groupSizes[base] = groupSize; + groupBases[base] = groupBase; } - NewKlass.release = standardReleaser; - return NewKlass; -}; -var PooledClass = { - addPoolingTo: addPoolingTo, - oneArgumentPooler: oneArgumentPooler, - twoArgumentPooler: twoArgumentPooler, - threeArgumentPooler: threeArgumentPooler, - fourArgumentPooler: fourArgumentPooler -}; + */ -module.exports = PooledClass; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var zeros = [ + '', + '0', + '00', + '000', + '0000', + '00000', + '000000', + '0000000', + '00000000', + '000000000', + '0000000000', + '00000000000', + '000000000000', + '0000000000000', + '00000000000000', + '000000000000000', + '0000000000000000', + '00000000000000000', + '000000000000000000', + '0000000000000000000', + '00000000000000000000', + '000000000000000000000', + '0000000000000000000000', + '00000000000000000000000', + '000000000000000000000000', + '0000000000000000000000000' + ]; -/***/ }), -/* 21 */ -/***/ (function(module, exports, __webpack_require__) { + var groupSizes = [ + 0, 0, + 25, 16, 12, 11, 10, 9, 8, + 8, 7, 7, 7, 7, 6, 6, + 6, 6, 6, 6, 6, 5, 5, + 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5 + ]; -var ERRORS = __webpack_require__(347) -var NATIVE = __webpack_require__(273) + var groupBases = [ + 0, 0, + 33554432, 43046721, 16777216, 48828125, 60466176, 40353607, 16777216, + 43046721, 10000000, 19487171, 35831808, 62748517, 7529536, 11390625, + 16777216, 24137569, 34012224, 47045881, 64000000, 4084101, 5153632, + 6436343, 7962624, 9765625, 11881376, 14348907, 17210368, 20511149, + 24300000, 28629151, 33554432, 39135393, 45435424, 52521875, 60466176 + ]; -// short-hand -var tfJSON = ERRORS.tfJSON -var TfTypeError = ERRORS.TfTypeError -var TfPropertyTypeError = ERRORS.TfPropertyTypeError -var tfSubError = ERRORS.tfSubError -var getValueTypeName = ERRORS.getValueTypeName + BN.prototype.toString = function toString (base, padding) { + base = base || 10; + padding = padding | 0 || 1; -var TYPES = { - arrayOf: function arrayOf (type) { - type = compile(type) + var out; + if (base === 16 || base === 'hex') { + out = ''; + var off = 0; + var carry = 0; + for (var i = 0; i < this.length; i++) { + var w = this.words[i]; + var word = (((w << off) | carry) & 0xffffff).toString(16); + carry = (w >>> (24 - off)) & 0xffffff; + if (carry !== 0 || i !== this.length - 1) { + out = zeros[6 - word.length] + word + out; + } else { + out = word + out; + } + off += 2; + if (off >= 26) { + off -= 26; + i--; + } + } + if (carry !== 0) { + out = carry.toString(16) + out; + } + while (out.length % padding !== 0) { + out = '0' + out; + } + if (this.negative !== 0) { + out = '-' + out; + } + return out; + } - function _arrayOf (array, strict) { - if (!NATIVE.Array(array)) return false + if (base === (base | 0) && base >= 2 && base <= 36) { + // var groupSize = Math.floor(BN.wordSize * Math.LN2 / Math.log(base)); + var groupSize = groupSizes[base]; + // var groupBase = Math.pow(base, groupSize); + var groupBase = groupBases[base]; + out = ''; + var c = this.clone(); + c.negative = 0; + while (!c.isZero()) { + var r = c.modn(groupBase).toString(base); + c = c.idivn(groupBase); - return array.every(function (value, i) { - try { - return typeforce(type, value, strict) - } catch (e) { - throw tfSubError(e, i) + if (!c.isZero()) { + out = zeros[groupSize - r.length] + r + out; + } else { + out = r + out; } - }) + } + if (this.isZero()) { + out = '0' + out; + } + while (out.length % padding !== 0) { + out = '0' + out; + } + if (this.negative !== 0) { + out = '-' + out; + } + return out; } - _arrayOf.toJSON = function () { return '[' + tfJSON(type) + ']' } - - return _arrayOf - }, - maybe: function maybe (type) { - type = compile(type) + assert(false, 'Base should be between 2 and 36'); + }; - function _maybe (value, strict) { - return NATIVE.Nil(value) || type(value, strict, maybe) + BN.prototype.toNumber = function toNumber () { + var ret = this.words[0]; + if (this.length === 2) { + ret += this.words[1] * 0x4000000; + } else if (this.length === 3 && this.words[2] === 0x01) { + // NOTE: at this stage it is known that the top bit is set + ret += 0x10000000000000 + (this.words[1] * 0x4000000); + } else if (this.length > 2) { + assert(false, 'Number can only safely store up to 53 bits'); } - _maybe.toJSON = function () { return '?' + tfJSON(type) } + return (this.negative !== 0) ? -ret : ret; + }; - return _maybe - }, + BN.prototype.toJSON = function toJSON () { + return this.toString(16); + }; - map: function map (propertyType, propertyKeyType) { - propertyType = compile(propertyType) - if (propertyKeyType) propertyKeyType = compile(propertyKeyType) + BN.prototype.toBuffer = function toBuffer (endian, length) { + assert(typeof Buffer !== 'undefined'); + return this.toArrayLike(Buffer, endian, length); + }; - function _map (value, strict) { - if (!NATIVE.Object(value, strict)) return false - if (NATIVE.Nil(value, strict)) return false + BN.prototype.toArray = function toArray (endian, length) { + return this.toArrayLike(Array, endian, length); + }; - for (var propertyName in value) { - try { - if (propertyKeyType) { - typeforce(propertyKeyType, propertyName, strict) - } - } catch (e) { - throw tfSubError(e, propertyName, 'key') - } + BN.prototype.toArrayLike = function toArrayLike (ArrayType, endian, length) { + var byteLength = this.byteLength(); + var reqLength = length || Math.max(1, byteLength); + assert(byteLength <= reqLength, 'byte array longer than desired length'); + assert(reqLength > 0, 'Requested array length <= 0'); - try { - var propertyValue = value[propertyName] - typeforce(propertyType, propertyValue, strict) - } catch (e) { - throw tfSubError(e, propertyName) - } + this.strip(); + var littleEndian = endian === 'le'; + var res = new ArrayType(reqLength); + + var b, i; + var q = this.clone(); + if (!littleEndian) { + // Assume big-endian + for (i = 0; i < reqLength - byteLength; i++) { + res[i] = 0; } - return true - } + for (i = 0; !q.isZero(); i++) { + b = q.andln(0xff); + q.iushrn(8); - if (propertyKeyType) { - _map.toJSON = function () { - return '{' + tfJSON(propertyKeyType) + ': ' + tfJSON(propertyType) + '}' + res[reqLength - i - 1] = b; } } else { - _map.toJSON = function () { return '{' + tfJSON(propertyType) + '}' } - } - - return _map - }, + for (i = 0; !q.isZero(); i++) { + b = q.andln(0xff); + q.iushrn(8); - object: function object (uncompiled) { - var type = {} + res[i] = b; + } - for (var typePropertyName in uncompiled) { - type[typePropertyName] = compile(uncompiled[typePropertyName]) + for (; i < reqLength; i++) { + res[i] = 0; + } } - function _object (value, strict) { - if (!NATIVE.Object(value)) return false - if (NATIVE.Nil(value)) return false - - var propertyName - - try { - for (propertyName in type) { - var propertyType = type[propertyName] - var propertyValue = value[propertyName] + return res; + }; - typeforce(propertyType, propertyValue, strict) - } - } catch (e) { - throw tfSubError(e, propertyName) + if (Math.clz32) { + BN.prototype._countBits = function _countBits (w) { + return 32 - Math.clz32(w); + }; + } else { + BN.prototype._countBits = function _countBits (w) { + var t = w; + var r = 0; + if (t >= 0x1000) { + r += 13; + t >>>= 13; } - - if (strict) { - for (propertyName in value) { - if (type[propertyName]) continue - - throw new TfPropertyTypeError(undefined, propertyName) - } + if (t >= 0x40) { + r += 7; + t >>>= 7; + } + if (t >= 0x8) { + r += 4; + t >>>= 4; + } + if (t >= 0x02) { + r += 2; + t >>>= 2; } + return r + t; + }; + } - return true - } - _object.toJSON = function () { return tfJSON(type) } + BN.prototype._zeroBits = function _zeroBits (w) { + // Short-cut + if (w === 0) return 26; - return _object - }, + var t = w; + var r = 0; + if ((t & 0x1fff) === 0) { + r += 13; + t >>>= 13; + } + if ((t & 0x7f) === 0) { + r += 7; + t >>>= 7; + } + if ((t & 0xf) === 0) { + r += 4; + t >>>= 4; + } + if ((t & 0x3) === 0) { + r += 2; + t >>>= 2; + } + if ((t & 0x1) === 0) { + r++; + } + return r; + }; - oneOf: function oneOf () { - var types = [].slice.call(arguments).map(compile) + // Return number of used bits in a BN + BN.prototype.bitLength = function bitLength () { + var w = this.words[this.length - 1]; + var hi = this._countBits(w); + return (this.length - 1) * 26 + hi; + }; - function _oneOf (value, strict) { - return types.some(function (type) { - try { - return typeforce(type, value, strict) - } catch (e) { - return false - } - }) - } - _oneOf.toJSON = function () { return types.map(tfJSON).join('|') } + function toBitArray (num) { + var w = new Array(num.bitLength()); - return _oneOf - }, + for (var bit = 0; bit < w.length; bit++) { + var off = (bit / 26) | 0; + var wbit = bit % 26; - quacksLike: function quacksLike (type) { - function _quacksLike (value) { - return type === getValueTypeName(value) + w[bit] = (num.words[off] & (1 << wbit)) >>> wbit; } - _quacksLike.toJSON = function () { return type } - return _quacksLike - }, + return w; + } - tuple: function tuple () { - var types = [].slice.call(arguments).map(compile) + // Number of trailing zero bits + BN.prototype.zeroBits = function zeroBits () { + if (this.isZero()) return 0; - function _tuple (values, strict) { - return types.every(function (type, i) { - try { - return typeforce(type, values[i], strict) - } catch (e) { - throw tfSubError(e, i) - } - }) && (!strict || values.length === arguments.length) + var r = 0; + for (var i = 0; i < this.length; i++) { + var b = this._zeroBits(this.words[i]); + r += b; + if (b !== 26) break; } - _tuple.toJSON = function () { return '(' + types.map(tfJSON).join(', ') + ')' } + return r; + }; - return _tuple - }, + BN.prototype.byteLength = function byteLength () { + return Math.ceil(this.bitLength() / 8); + }; - value: function value (expected) { - function _value (actual) { - return actual === expected + BN.prototype.toTwos = function toTwos (width) { + if (this.negative !== 0) { + return this.abs().inotn(width).iaddn(1); } - _value.toJSON = function () { return expected } + return this.clone(); + }; - return _value - } -} + BN.prototype.fromTwos = function fromTwos (width) { + if (this.testn(width - 1)) { + return this.notn(width).iaddn(1).ineg(); + } + return this.clone(); + }; -function compile (type) { - if (NATIVE.String(type)) { - if (type[0] === '?') return TYPES.maybe(compile(type.slice(1))) + BN.prototype.isNeg = function isNeg () { + return this.negative !== 0; + }; - return NATIVE[type] || TYPES.quacksLike(type) - } else if (type && NATIVE.Object(type)) { - if (NATIVE.Array(type)) return TYPES.arrayOf(compile(type[0])) + // Return negative clone of `this` + BN.prototype.neg = function neg () { + return this.clone().ineg(); + }; - return TYPES.object(type) - } else if (NATIVE.Function(type)) { - return type - } + BN.prototype.ineg = function ineg () { + if (!this.isZero()) { + this.negative ^= 1; + } - return TYPES.value(type) -} + return this; + }; -function typeforce (type, value, strict, surrogate) { - if (NATIVE.Function(type)) { - if (type(value, strict)) return true + // Or `num` with `this` in-place + BN.prototype.iuor = function iuor (num) { + while (this.length < num.length) { + this.words[this.length++] = 0; + } - throw new TfTypeError(surrogate || type, value) - } + for (var i = 0; i < num.length; i++) { + this.words[i] = this.words[i] | num.words[i]; + } - // JIT - return typeforce(compile(type), value, strict) -} + return this.strip(); + }; -// assign types to typeforce function -for (var typeName in NATIVE) { - typeforce[typeName] = NATIVE[typeName] -} + BN.prototype.ior = function ior (num) { + assert((this.negative | num.negative) === 0); + return this.iuor(num); + }; -for (typeName in TYPES) { - typeforce[typeName] = TYPES[typeName] -} + // Or `num` with `this` + BN.prototype.or = function or (num) { + if (this.length > num.length) return this.clone().ior(num); + return num.clone().ior(this); + }; -var EXTRA = __webpack_require__(527) -for (typeName in EXTRA) { - typeforce[typeName] = EXTRA[typeName] -} + BN.prototype.uor = function uor (num) { + if (this.length > num.length) return this.clone().iuor(num); + return num.clone().iuor(this); + }; -// async wrapper -function __async (type, value, strict, callback) { - // default to falsy strict if using shorthand overload - if (typeof strict === 'function') return __async(type, value, false, strict) + // And `num` with `this` in-place + BN.prototype.iuand = function iuand (num) { + // b = min-length(num, this) + var b; + if (this.length > num.length) { + b = num; + } else { + b = this; + } - try { - typeforce(type, value, strict) - } catch (e) { - return callback(e) - } + for (var i = 0; i < b.length; i++) { + this.words[i] = this.words[i] & num.words[i]; + } - callback() -} + this.length = b.length; -typeforce.async = __async -typeforce.compile = compile -typeforce.TfTypeError = TfTypeError -typeforce.TfPropertyTypeError = TfPropertyTypeError + return this.strip(); + }; -module.exports = typeforce + BN.prototype.iand = function iand (num) { + assert((this.negative | num.negative) === 0); + return this.iuand(num); + }; + // And `num` with `this` + BN.prototype.and = function and (num) { + if (this.length > num.length) return this.clone().iand(num); + return num.clone().iand(this); + }; -/***/ }), -/* 22 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.uand = function uand (num) { + if (this.length > num.length) return this.clone().iuand(num); + return num.clone().iuand(this); + }; -"use strict"; + // Xor `num` with `this` in-place + BN.prototype.iuxor = function iuxor (num) { + // a.length > b.length + var a; + var b; + if (this.length > num.length) { + a = this; + b = num; + } else { + a = num; + b = this; + } + for (var i = 0; i < b.length; i++) { + this.words[i] = a.words[i] ^ b.words[i]; + } -Object.defineProperty(exports, "__esModule", { - value: true -}); -var CONST_VAR = { - SORT_DESC: 'desc', - SORT_ASC: 'asc', - AWAIT_BEFORE_CELL_EDIT: 1, - SIZE_PER_PAGE: 10, - NEXT_PAGE: '>', - NEXT_PAGE_TITLE: 'next page', - LAST_PAGE: '>>', - LAST_PAGE_TITLE: 'last page', - PRE_PAGE: '<', - PRE_PAGE_TITLE: 'previous page', - FIRST_PAGE: '<<', - FIRST_PAGE_TITLE: 'first page', - PAGE_START_INDEX: 1, - ROW_SELECT_BG_COLOR: '', - ROW_SELECT_NONE: 'none', - ROW_SELECT_SINGLE: 'radio', - ROW_SELECT_MULTI: 'checkbox', - CELL_EDIT_NONE: 'none', - CELL_EDIT_CLICK: 'click', - CELL_EDIT_DBCLICK: 'dbclick', - SIZE_PER_PAGE_LIST: [10, 25, 30, 50], - PAGINATION_SIZE: 5, - PAGINATION_POS_TOP: 'top', - PAGINATION_POS_BOTTOM: 'bottom', - PAGINATION_POS_BOTH: 'both', - NO_DATA_TEXT: 'There is no data to display', - SHOW_ONLY_SELECT: 'Show Selected Only', - SHOW_ALL: 'Show All', - EXPORT_CSV_TEXT: 'Export to CSV', - INSERT_BTN_TEXT: 'New', - DELETE_BTN_TEXT: 'Delete', - SAVE_BTN_TEXT: 'Save', - CLOSE_BTN_TEXT: 'Close', - FILTER_DELAY: 500, - SCROLL_TOP: 'Top', - SCROLL_BOTTOM: 'Bottom', - FILTER_TYPE: { - TEXT: 'TextFilter', - REGEX: 'RegexFilter', - SELECT: 'SelectFilter', - NUMBER: 'NumberFilter', - DATE: 'DateFilter', - CUSTOM: 'CustomFilter' - }, - FILTER_COND_EQ: 'eq', - FILTER_COND_LIKE: 'like', - EXPAND_BY_ROW: 'row', - EXPAND_BY_COL: 'column', - REMOTE_SORT: 'sort', - REMOTE_PAGE: 'pagination', - REMOTE_CELL_EDIT: 'cellEdit', - REMOTE_INSERT_ROW: 'insertRow', - REMOTE_DROP_ROW: 'dropRow', - REMOTE_FILTER: 'filter', - REMOTE_SEARCH: 'search', - REMOTE_EXPORT_CSV: 'exportCSV', - INSERT_FAIL_INDICATOR: 'Validation errors, please check!', - DEFAULT_CSV_SEPARATOR: ',' -}; - -CONST_VAR.REMOTE = {}; -CONST_VAR.REMOTE[CONST_VAR.REMOTE_SORT] = false; -CONST_VAR.REMOTE[CONST_VAR.REMOTE_PAGE] = false; -CONST_VAR.REMOTE[CONST_VAR.REMOTE_CELL_EDIT] = false; -CONST_VAR.REMOTE[CONST_VAR.REMOTE_INSERT_ROW] = false; -CONST_VAR.REMOTE[CONST_VAR.REMOTE_DROP_ROW] = false; -CONST_VAR.REMOTE[CONST_VAR.REMOTE_FILTER] = false; -CONST_VAR.REMOTE[CONST_VAR.REMOTE_SEARCH] = false; -CONST_VAR.REMOTE[CONST_VAR.REMOTE_EXPORT_CSV] = false; - -var _default = CONST_VAR; -exports.default = _default; -; + if (this !== a) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; + } + } -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } + this.length = a.length; - __REACT_HOT_LOADER__.register(CONST_VAR, 'CONST_VAR', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/Const.js'); + return this.strip(); + }; - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/Const.js'); -}(); + BN.prototype.ixor = function ixor (num) { + assert((this.negative | num.negative) === 0); + return this.iuxor(num); + }; -; + // Xor `num` with `this` + BN.prototype.xor = function xor (num) { + if (this.length > num.length) return this.clone().ixor(num); + return num.clone().ixor(this); + }; -/***/ }), -/* 23 */ -/***/ (function(module, exports, __webpack_require__) { + BN.prototype.uxor = function uxor (num) { + if (this.length > num.length) return this.clone().iuxor(num); + return num.clone().iuxor(this); + }; -/* WEBPACK VAR INJECTION */(function(module) {(function (module, exports) { - 'use strict'; + // Not ``this`` with ``width`` bitwidth + BN.prototype.inotn = function inotn (width) { + assert(typeof width === 'number' && width >= 0); - // Utils - function assert (val, msg) { - if (!val) throw new Error(msg || 'Assertion failed'); - } + var bytesNeeded = Math.ceil(width / 26) | 0; + var bitsLeft = width % 26; - // Could use `inherits` module, but don't want to move from single file - // architecture yet. - function inherits (ctor, superCtor) { - ctor.super_ = superCtor; - var TempCtor = function () {}; - TempCtor.prototype = superCtor.prototype; - ctor.prototype = new TempCtor(); - ctor.prototype.constructor = ctor; - } + // Extend the buffer with leading zeroes + this._expand(bytesNeeded); - // BN + if (bitsLeft > 0) { + bytesNeeded--; + } - function BN (number, base, endian) { - if (BN.isBN(number)) { - return number; + // Handle complete words + for (var i = 0; i < bytesNeeded; i++) { + this.words[i] = ~this.words[i] & 0x3ffffff; } - this.negative = 0; - this.words = null; - this.length = 0; + // Handle the residue + if (bitsLeft > 0) { + this.words[i] = ~this.words[i] & (0x3ffffff >> (26 - bitsLeft)); + } - // Reduction context - this.red = null; + // And remove leading zeroes + return this.strip(); + }; - if (number !== null) { - if (base === 'le' || base === 'be') { - endian = base; - base = 10; - } + BN.prototype.notn = function notn (width) { + return this.clone().inotn(width); + }; - this._init(number || 0, base || 10, endian || 'be'); - } - } - if (typeof module === 'object') { - module.exports = BN; - } else { - exports.BN = BN; - } + // Set `bit` of `this` + BN.prototype.setn = function setn (bit, val) { + assert(typeof bit === 'number' && bit >= 0); - BN.BN = BN; - BN.wordSize = 26; + var off = (bit / 26) | 0; + var wbit = bit % 26; - var Buffer; - try { - // Obfuscate that we require Buffer, to reduce size - Buffer = __webpack_require__(7).Buffer; - } catch (e) { - } + this._expand(off + 1); - BN.isBN = function isBN (num) { - if (num instanceof BN) { - return true; + if (val) { + this.words[off] = this.words[off] | (1 << wbit); + } else { + this.words[off] = this.words[off] & ~(1 << wbit); } - return num !== null && typeof num === 'object' && - num.constructor.wordSize === BN.wordSize && Array.isArray(num.words); - }; - - BN.max = function max (left, right) { - if (left.cmp(right) > 0) return left; - return right; + return this.strip(); }; - BN.min = function min (left, right) { - if (left.cmp(right) < 0) return left; - return right; - }; + // Add `num` to `this` in-place + BN.prototype.iadd = function iadd (num) { + var r; - BN.prototype._init = function init (number, base, endian) { - if (typeof number === 'number') { - return this._initNumber(number, base, endian); - } + // negative + positive + if (this.negative !== 0 && num.negative === 0) { + this.negative = 0; + r = this.isub(num); + this.negative ^= 1; + return this._normSign(); - if (typeof number === 'object') { - return this._initArray(number, base, endian); + // positive + negative + } else if (this.negative === 0 && num.negative !== 0) { + num.negative = 0; + r = this.isub(num); + num.negative = 1; + return r._normSign(); } - if (base === 'hex') { - base = 16; + // a.length > b.length + var a, b; + if (this.length > num.length) { + a = this; + b = num; + } else { + a = num; + b = this; } - assert(base === (base | 0) && base >= 2 && base <= 36); - number = number.toString().replace(/\s+/g, ''); - var start = 0; - if (number[0] === '-') { - start++; + var carry = 0; + for (var i = 0; i < b.length; i++) { + r = (a.words[i] | 0) + (b.words[i] | 0) + carry; + this.words[i] = r & 0x3ffffff; + carry = r >>> 26; } - - if (base === 16) { - this._parseHex(number, start); - } else { - this._parseBase(number, base, start); + for (; carry !== 0 && i < a.length; i++) { + r = (a.words[i] | 0) + carry; + this.words[i] = r & 0x3ffffff; + carry = r >>> 26; } - if (number[0] === '-') { - this.negative = 1; + this.length = a.length; + if (carry !== 0) { + this.words[this.length] = carry; + this.length++; + // Copy the rest of the words + } else if (a !== this) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; + } } - this.strip(); + return this; + }; - if (endian !== 'le') return; - - this._initArray(this.toArray(), base, endian); - }; - - BN.prototype._initNumber = function _initNumber (number, base, endian) { - if (number < 0) { + // Add `num` to `this` + BN.prototype.add = function add (num) { + var res; + if (num.negative !== 0 && this.negative === 0) { + num.negative = 0; + res = this.sub(num); + num.negative ^= 1; + return res; + } else if (num.negative === 0 && this.negative !== 0) { + this.negative = 0; + res = num.sub(this); this.negative = 1; - number = -number; - } - if (number < 0x4000000) { - this.words = [ number & 0x3ffffff ]; - this.length = 1; - } else if (number < 0x10000000000000) { - this.words = [ - number & 0x3ffffff, - (number / 0x4000000) & 0x3ffffff - ]; - this.length = 2; - } else { - assert(number < 0x20000000000000); // 2 ^ 53 (unsafe) - this.words = [ - number & 0x3ffffff, - (number / 0x4000000) & 0x3ffffff, - 1 - ]; - this.length = 3; - } - - if (endian !== 'le') return; - - // Reverse the bytes - this._initArray(this.toArray(), base, endian); - }; - - BN.prototype._initArray = function _initArray (number, base, endian) { - // Perhaps a Uint8Array - assert(typeof number.length === 'number'); - if (number.length <= 0) { - this.words = [ 0 ]; - this.length = 1; - return this; + return res; } - this.length = Math.ceil(number.length / 3); - this.words = new Array(this.length); - for (var i = 0; i < this.length; i++) { - this.words[i] = 0; - } + if (this.length > num.length) return this.clone().iadd(num); - var j, w; - var off = 0; - if (endian === 'be') { - for (i = number.length - 1, j = 0; i >= 0; i -= 3) { - w = number[i] | (number[i - 1] << 8) | (number[i - 2] << 16); - this.words[j] |= (w << off) & 0x3ffffff; - this.words[j + 1] = (w >>> (26 - off)) & 0x3ffffff; - off += 24; - if (off >= 26) { - off -= 26; - j++; - } - } - } else if (endian === 'le') { - for (i = 0, j = 0; i < number.length; i += 3) { - w = number[i] | (number[i + 1] << 8) | (number[i + 2] << 16); - this.words[j] |= (w << off) & 0x3ffffff; - this.words[j + 1] = (w >>> (26 - off)) & 0x3ffffff; - off += 24; - if (off >= 26) { - off -= 26; - j++; - } - } - } - return this.strip(); + return num.clone().iadd(this); }; - function parseHex (str, start, end) { - var r = 0; - var len = Math.min(str.length, end); - for (var i = start; i < len; i++) { - var c = str.charCodeAt(i) - 48; - - r <<= 4; - - // 'a' - 'f' - if (c >= 49 && c <= 54) { - r |= c - 49 + 0xa; - - // 'A' - 'F' - } else if (c >= 17 && c <= 22) { - r |= c - 17 + 0xa; + // Subtract `num` from `this` in-place + BN.prototype.isub = function isub (num) { + // this - (-num) = this + num + if (num.negative !== 0) { + num.negative = 0; + var r = this.iadd(num); + num.negative = 1; + return r._normSign(); - // '0' - '9' - } else { - r |= c & 0xf; - } + // -this - num = -(this + num) + } else if (this.negative !== 0) { + this.negative = 0; + this.iadd(num); + this.negative = 1; + return this._normSign(); } - return r; - } - BN.prototype._parseHex = function _parseHex (number, start) { - // Create possibly bigger array to ensure that it fits the number - this.length = Math.ceil((number.length - start) / 6); - this.words = new Array(this.length); - for (var i = 0; i < this.length; i++) { - this.words[i] = 0; - } + // At this point both numbers are positive + var cmp = this.cmp(num); - var j, w; - // Scan 24-bit chunks and add them to the number - var off = 0; - for (i = number.length - 6, j = 0; i >= start; i -= 6) { - w = parseHex(number, i, i + 6); - this.words[j] |= (w << off) & 0x3ffffff; - // NOTE: `0x3fffff` is intentional here, 26bits max shift + 24bit hex limb - this.words[j + 1] |= w >>> (26 - off) & 0x3fffff; - off += 24; - if (off >= 26) { - off -= 26; - j++; - } - } - if (i + 6 !== start) { - w = parseHex(number, start, i + 6); - this.words[j] |= (w << off) & 0x3ffffff; - this.words[j + 1] |= w >>> (26 - off) & 0x3fffff; + // Optimization - zeroify + if (cmp === 0) { + this.negative = 0; + this.length = 1; + this.words[0] = 0; + return this; } - this.strip(); - }; - - function parseBase (str, start, end, mul) { - var r = 0; - var len = Math.min(str.length, end); - for (var i = start; i < len; i++) { - var c = str.charCodeAt(i) - 48; - - r *= mul; - - // 'a' - if (c >= 49) { - r += c - 49 + 0xa; - - // 'A' - } else if (c >= 17) { - r += c - 17 + 0xa; - // '0' - '9' - } else { - r += c; - } + // a > b + var a, b; + if (cmp > 0) { + a = this; + b = num; + } else { + a = num; + b = this; } - return r; - } - - BN.prototype._parseBase = function _parseBase (number, base, start) { - // Initialize as zero - this.words = [ 0 ]; - this.length = 1; - // Find length of limb in base - for (var limbLen = 0, limbPow = 1; limbPow <= 0x3ffffff; limbPow *= base) { - limbLen++; + var carry = 0; + for (var i = 0; i < b.length; i++) { + r = (a.words[i] | 0) - (b.words[i] | 0) + carry; + carry = r >> 26; + this.words[i] = r & 0x3ffffff; } - limbLen--; - limbPow = (limbPow / base) | 0; - - var total = number.length - start; - var mod = total % limbLen; - var end = Math.min(total, total - mod) + start; - - var word = 0; - for (var i = start; i < end; i += limbLen) { - word = parseBase(number, i, i + limbLen, base); - - this.imuln(limbPow); - if (this.words[0] + word < 0x4000000) { - this.words[0] += word; - } else { - this._iaddn(word); - } + for (; carry !== 0 && i < a.length; i++) { + r = (a.words[i] | 0) + carry; + carry = r >> 26; + this.words[i] = r & 0x3ffffff; } - if (mod !== 0) { - var pow = 1; - word = parseBase(number, i, number.length, base); - - for (i = 0; i < mod; i++) { - pow *= base; - } - - this.imuln(pow); - if (this.words[0] + word < 0x4000000) { - this.words[0] += word; - } else { - this._iaddn(word); + // Copy rest of the words + if (carry === 0 && i < a.length && a !== this) { + for (; i < a.length; i++) { + this.words[i] = a.words[i]; } } - }; - - BN.prototype.copy = function copy (dest) { - dest.words = new Array(this.length); - for (var i = 0; i < this.length; i++) { - dest.words[i] = this.words[i]; - } - dest.length = this.length; - dest.negative = this.negative; - dest.red = this.red; - }; - - BN.prototype.clone = function clone () { - var r = new BN(null); - this.copy(r); - return r; - }; - BN.prototype._expand = function _expand (size) { - while (this.length < size) { - this.words[this.length++] = 0; - } - return this; - }; + this.length = Math.max(this.length, i); - // Remove leading `0` from `this` - BN.prototype.strip = function strip () { - while (this.length > 1 && this.words[this.length - 1] === 0) { - this.length--; + if (a !== this) { + this.negative = 1; } - return this._normSign(); - }; - BN.prototype._normSign = function _normSign () { - // -0 = 0 - if (this.length === 1 && this.words[0] === 0) { - this.negative = 0; - } - return this; + return this.strip(); }; - BN.prototype.inspect = function inspect () { - return (this.red ? '<BN-R: ' : '<BN: ') + this.toString(16) + '>'; + // Subtract `num` from `this` + BN.prototype.sub = function sub (num) { + return this.clone().isub(num); }; - /* - - var zeros = []; - var groupSizes = []; - var groupBases = []; - - var s = ''; - var i = -1; - while (++i < BN.wordSize) { - zeros[i] = s; - s += '0'; - } - groupSizes[0] = 0; - groupSizes[1] = 0; - groupBases[0] = 0; - groupBases[1] = 0; - var base = 2 - 1; - while (++base < 36 + 1) { - var groupSize = 0; - var groupBase = 1; - while (groupBase < (1 << BN.wordSize) / base) { - groupBase *= base; - groupSize += 1; - } - groupSizes[base] = groupSize; - groupBases[base] = groupBase; - } - - */ - - var zeros = [ - '', - '0', - '00', - '000', - '0000', - '00000', - '000000', - '0000000', - '00000000', - '000000000', - '0000000000', - '00000000000', - '000000000000', - '0000000000000', - '00000000000000', - '000000000000000', - '0000000000000000', - '00000000000000000', - '000000000000000000', - '0000000000000000000', - '00000000000000000000', - '000000000000000000000', - '0000000000000000000000', - '00000000000000000000000', - '000000000000000000000000', - '0000000000000000000000000' - ]; - - var groupSizes = [ - 0, 0, - 25, 16, 12, 11, 10, 9, 8, - 8, 7, 7, 7, 7, 6, 6, - 6, 6, 6, 6, 6, 5, 5, - 5, 5, 5, 5, 5, 5, 5, - 5, 5, 5, 5, 5, 5, 5 - ]; - - var groupBases = [ - 0, 0, - 33554432, 43046721, 16777216, 48828125, 60466176, 40353607, 16777216, - 43046721, 10000000, 19487171, 35831808, 62748517, 7529536, 11390625, - 16777216, 24137569, 34012224, 47045881, 64000000, 4084101, 5153632, - 6436343, 7962624, 9765625, 11881376, 14348907, 17210368, 20511149, - 24300000, 28629151, 33554432, 39135393, 45435424, 52521875, 60466176 - ]; - - BN.prototype.toString = function toString (base, padding) { - base = base || 10; - padding = padding | 0 || 1; + function smallMulTo (self, num, out) { + out.negative = num.negative ^ self.negative; + var len = (self.length + num.length) | 0; + out.length = len; + len = (len - 1) | 0; - var out; - if (base === 16 || base === 'hex') { - out = ''; - var off = 0; - var carry = 0; - for (var i = 0; i < this.length; i++) { - var w = this.words[i]; - var word = (((w << off) | carry) & 0xffffff).toString(16); - carry = (w >>> (24 - off)) & 0xffffff; - if (carry !== 0 || i !== this.length - 1) { - out = zeros[6 - word.length] + word + out; - } else { - out = word + out; - } - off += 2; - if (off >= 26) { - off -= 26; - i--; - } - } - if (carry !== 0) { - out = carry.toString(16) + out; - } - while (out.length % padding !== 0) { - out = '0' + out; - } - if (this.negative !== 0) { - out = '-' + out; - } - return out; - } + // Peel one iteration (compiler can't do it, because of code complexity) + var a = self.words[0] | 0; + var b = num.words[0] | 0; + var r = a * b; - if (base === (base | 0) && base >= 2 && base <= 36) { - // var groupSize = Math.floor(BN.wordSize * Math.LN2 / Math.log(base)); - var groupSize = groupSizes[base]; - // var groupBase = Math.pow(base, groupSize); - var groupBase = groupBases[base]; - out = ''; - var c = this.clone(); - c.negative = 0; - while (!c.isZero()) { - var r = c.modn(groupBase).toString(base); - c = c.idivn(groupBase); + var lo = r & 0x3ffffff; + var carry = (r / 0x4000000) | 0; + out.words[0] = lo; - if (!c.isZero()) { - out = zeros[groupSize - r.length] + r + out; - } else { - out = r + out; - } - } - if (this.isZero()) { - out = '0' + out; - } - while (out.length % padding !== 0) { - out = '0' + out; - } - if (this.negative !== 0) { - out = '-' + out; + for (var k = 1; k < len; k++) { + // Sum all words with the same `i + j = k` and accumulate `ncarry`, + // note that ncarry could be >= 0x3ffffff + var ncarry = carry >>> 26; + var rword = carry & 0x3ffffff; + var maxJ = Math.min(k, num.length - 1); + for (var j = Math.max(0, k - self.length + 1); j <= maxJ; j++) { + var i = (k - j) | 0; + a = self.words[i] | 0; + b = num.words[j] | 0; + r = a * b + rword; + ncarry += (r / 0x4000000) | 0; + rword = r & 0x3ffffff; } - return out; - } - - assert(false, 'Base should be between 2 and 36'); - }; - - BN.prototype.toNumber = function toNumber () { - var ret = this.words[0]; - if (this.length === 2) { - ret += this.words[1] * 0x4000000; - } else if (this.length === 3 && this.words[2] === 0x01) { - // NOTE: at this stage it is known that the top bit is set - ret += 0x10000000000000 + (this.words[1] * 0x4000000); - } else if (this.length > 2) { - assert(false, 'Number can only safely store up to 53 bits'); + out.words[k] = rword | 0; + carry = ncarry | 0; } - return (this.negative !== 0) ? -ret : ret; - }; - - BN.prototype.toJSON = function toJSON () { - return this.toString(16); - }; - - BN.prototype.toBuffer = function toBuffer (endian, length) { - assert(typeof Buffer !== 'undefined'); - return this.toArrayLike(Buffer, endian, length); - }; - - BN.prototype.toArray = function toArray (endian, length) { - return this.toArrayLike(Array, endian, length); - }; - - BN.prototype.toArrayLike = function toArrayLike (ArrayType, endian, length) { - var byteLength = this.byteLength(); - var reqLength = length || Math.max(1, byteLength); - assert(byteLength <= reqLength, 'byte array longer than desired length'); - assert(reqLength > 0, 'Requested array length <= 0'); - - this.strip(); - var littleEndian = endian === 'le'; - var res = new ArrayType(reqLength); - - var b, i; - var q = this.clone(); - if (!littleEndian) { - // Assume big-endian - for (i = 0; i < reqLength - byteLength; i++) { - res[i] = 0; - } - - for (i = 0; !q.isZero(); i++) { - b = q.andln(0xff); - q.iushrn(8); - - res[reqLength - i - 1] = b; - } + if (carry !== 0) { + out.words[k] = carry | 0; } else { - for (i = 0; !q.isZero(); i++) { - b = q.andln(0xff); - q.iushrn(8); - - res[i] = b; - } - - for (; i < reqLength; i++) { - res[i] = 0; - } - } - - return res; - }; - - if (Math.clz32) { - BN.prototype._countBits = function _countBits (w) { - return 32 - Math.clz32(w); - }; - } else { - BN.prototype._countBits = function _countBits (w) { - var t = w; - var r = 0; - if (t >= 0x1000) { - r += 13; - t >>>= 13; - } - if (t >= 0x40) { - r += 7; - t >>>= 7; - } - if (t >= 0x8) { - r += 4; - t >>>= 4; - } - if (t >= 0x02) { - r += 2; - t >>>= 2; - } - return r + t; - }; - } - - BN.prototype._zeroBits = function _zeroBits (w) { - // Short-cut - if (w === 0) return 26; - - var t = w; - var r = 0; - if ((t & 0x1fff) === 0) { - r += 13; - t >>>= 13; - } - if ((t & 0x7f) === 0) { - r += 7; - t >>>= 7; - } - if ((t & 0xf) === 0) { - r += 4; - t >>>= 4; - } - if ((t & 0x3) === 0) { - r += 2; - t >>>= 2; - } - if ((t & 0x1) === 0) { - r++; - } - return r; - }; - - // Return number of used bits in a BN - BN.prototype.bitLength = function bitLength () { - var w = this.words[this.length - 1]; - var hi = this._countBits(w); - return (this.length - 1) * 26 + hi; - }; - - function toBitArray (num) { - var w = new Array(num.bitLength()); - - for (var bit = 0; bit < w.length; bit++) { - var off = (bit / 26) | 0; - var wbit = bit % 26; - - w[bit] = (num.words[off] & (1 << wbit)) >>> wbit; - } - - return w; - } - - // Number of trailing zero bits - BN.prototype.zeroBits = function zeroBits () { - if (this.isZero()) return 0; - - var r = 0; - for (var i = 0; i < this.length; i++) { - var b = this._zeroBits(this.words[i]); - r += b; - if (b !== 26) break; - } - return r; - }; - - BN.prototype.byteLength = function byteLength () { - return Math.ceil(this.bitLength() / 8); - }; - - BN.prototype.toTwos = function toTwos (width) { - if (this.negative !== 0) { - return this.abs().inotn(width).iaddn(1); - } - return this.clone(); - }; - - BN.prototype.fromTwos = function fromTwos (width) { - if (this.testn(width - 1)) { - return this.notn(width).iaddn(1).ineg(); - } - return this.clone(); - }; - - BN.prototype.isNeg = function isNeg () { - return this.negative !== 0; - }; - - // Return negative clone of `this` - BN.prototype.neg = function neg () { - return this.clone().ineg(); - }; - - BN.prototype.ineg = function ineg () { - if (!this.isZero()) { - this.negative ^= 1; - } - - return this; - }; - - // Or `num` with `this` in-place - BN.prototype.iuor = function iuor (num) { - while (this.length < num.length) { - this.words[this.length++] = 0; - } - - for (var i = 0; i < num.length; i++) { - this.words[i] = this.words[i] | num.words[i]; - } - - return this.strip(); - }; - - BN.prototype.ior = function ior (num) { - assert((this.negative | num.negative) === 0); - return this.iuor(num); - }; - - // Or `num` with `this` - BN.prototype.or = function or (num) { - if (this.length > num.length) return this.clone().ior(num); - return num.clone().ior(this); - }; - - BN.prototype.uor = function uor (num) { - if (this.length > num.length) return this.clone().iuor(num); - return num.clone().iuor(this); - }; - - // And `num` with `this` in-place - BN.prototype.iuand = function iuand (num) { - // b = min-length(num, this) - var b; - if (this.length > num.length) { - b = num; - } else { - b = this; - } - - for (var i = 0; i < b.length; i++) { - this.words[i] = this.words[i] & num.words[i]; - } - - this.length = b.length; - - return this.strip(); - }; - - BN.prototype.iand = function iand (num) { - assert((this.negative | num.negative) === 0); - return this.iuand(num); - }; - - // And `num` with `this` - BN.prototype.and = function and (num) { - if (this.length > num.length) return this.clone().iand(num); - return num.clone().iand(this); - }; - - BN.prototype.uand = function uand (num) { - if (this.length > num.length) return this.clone().iuand(num); - return num.clone().iuand(this); - }; - - // Xor `num` with `this` in-place - BN.prototype.iuxor = function iuxor (num) { - // a.length > b.length - var a; - var b; - if (this.length > num.length) { - a = this; - b = num; - } else { - a = num; - b = this; - } - - for (var i = 0; i < b.length; i++) { - this.words[i] = a.words[i] ^ b.words[i]; - } - - if (this !== a) { - for (; i < a.length; i++) { - this.words[i] = a.words[i]; - } - } - - this.length = a.length; - - return this.strip(); - }; - - BN.prototype.ixor = function ixor (num) { - assert((this.negative | num.negative) === 0); - return this.iuxor(num); - }; - - // Xor `num` with `this` - BN.prototype.xor = function xor (num) { - if (this.length > num.length) return this.clone().ixor(num); - return num.clone().ixor(this); - }; - - BN.prototype.uxor = function uxor (num) { - if (this.length > num.length) return this.clone().iuxor(num); - return num.clone().iuxor(this); - }; - - // Not ``this`` with ``width`` bitwidth - BN.prototype.inotn = function inotn (width) { - assert(typeof width === 'number' && width >= 0); - - var bytesNeeded = Math.ceil(width / 26) | 0; - var bitsLeft = width % 26; - - // Extend the buffer with leading zeroes - this._expand(bytesNeeded); - - if (bitsLeft > 0) { - bytesNeeded--; - } - - // Handle complete words - for (var i = 0; i < bytesNeeded; i++) { - this.words[i] = ~this.words[i] & 0x3ffffff; - } - - // Handle the residue - if (bitsLeft > 0) { - this.words[i] = ~this.words[i] & (0x3ffffff >> (26 - bitsLeft)); - } - - // And remove leading zeroes - return this.strip(); - }; - - BN.prototype.notn = function notn (width) { - return this.clone().inotn(width); - }; - - // Set `bit` of `this` - BN.prototype.setn = function setn (bit, val) { - assert(typeof bit === 'number' && bit >= 0); - - var off = (bit / 26) | 0; - var wbit = bit % 26; - - this._expand(off + 1); - - if (val) { - this.words[off] = this.words[off] | (1 << wbit); - } else { - this.words[off] = this.words[off] & ~(1 << wbit); - } - - return this.strip(); - }; - - // Add `num` to `this` in-place - BN.prototype.iadd = function iadd (num) { - var r; - - // negative + positive - if (this.negative !== 0 && num.negative === 0) { - this.negative = 0; - r = this.isub(num); - this.negative ^= 1; - return this._normSign(); - - // positive + negative - } else if (this.negative === 0 && num.negative !== 0) { - num.negative = 0; - r = this.isub(num); - num.negative = 1; - return r._normSign(); - } - - // a.length > b.length - var a, b; - if (this.length > num.length) { - a = this; - b = num; - } else { - a = num; - b = this; - } - - var carry = 0; - for (var i = 0; i < b.length; i++) { - r = (a.words[i] | 0) + (b.words[i] | 0) + carry; - this.words[i] = r & 0x3ffffff; - carry = r >>> 26; - } - for (; carry !== 0 && i < a.length; i++) { - r = (a.words[i] | 0) + carry; - this.words[i] = r & 0x3ffffff; - carry = r >>> 26; - } - - this.length = a.length; - if (carry !== 0) { - this.words[this.length] = carry; - this.length++; - // Copy the rest of the words - } else if (a !== this) { - for (; i < a.length; i++) { - this.words[i] = a.words[i]; - } - } - - return this; - }; - - // Add `num` to `this` - BN.prototype.add = function add (num) { - var res; - if (num.negative !== 0 && this.negative === 0) { - num.negative = 0; - res = this.sub(num); - num.negative ^= 1; - return res; - } else if (num.negative === 0 && this.negative !== 0) { - this.negative = 0; - res = num.sub(this); - this.negative = 1; - return res; - } - - if (this.length > num.length) return this.clone().iadd(num); - - return num.clone().iadd(this); - }; - - // Subtract `num` from `this` in-place - BN.prototype.isub = function isub (num) { - // this - (-num) = this + num - if (num.negative !== 0) { - num.negative = 0; - var r = this.iadd(num); - num.negative = 1; - return r._normSign(); - - // -this - num = -(this + num) - } else if (this.negative !== 0) { - this.negative = 0; - this.iadd(num); - this.negative = 1; - return this._normSign(); - } - - // At this point both numbers are positive - var cmp = this.cmp(num); - - // Optimization - zeroify - if (cmp === 0) { - this.negative = 0; - this.length = 1; - this.words[0] = 0; - return this; - } - - // a > b - var a, b; - if (cmp > 0) { - a = this; - b = num; - } else { - a = num; - b = this; - } - - var carry = 0; - for (var i = 0; i < b.length; i++) { - r = (a.words[i] | 0) - (b.words[i] | 0) + carry; - carry = r >> 26; - this.words[i] = r & 0x3ffffff; - } - for (; carry !== 0 && i < a.length; i++) { - r = (a.words[i] | 0) + carry; - carry = r >> 26; - this.words[i] = r & 0x3ffffff; - } - - // Copy rest of the words - if (carry === 0 && i < a.length && a !== this) { - for (; i < a.length; i++) { - this.words[i] = a.words[i]; - } - } - - this.length = Math.max(this.length, i); - - if (a !== this) { - this.negative = 1; - } - - return this.strip(); - }; - - // Subtract `num` from `this` - BN.prototype.sub = function sub (num) { - return this.clone().isub(num); - }; - - function smallMulTo (self, num, out) { - out.negative = num.negative ^ self.negative; - var len = (self.length + num.length) | 0; - out.length = len; - len = (len - 1) | 0; - - // Peel one iteration (compiler can't do it, because of code complexity) - var a = self.words[0] | 0; - var b = num.words[0] | 0; - var r = a * b; - - var lo = r & 0x3ffffff; - var carry = (r / 0x4000000) | 0; - out.words[0] = lo; - - for (var k = 1; k < len; k++) { - // Sum all words with the same `i + j = k` and accumulate `ncarry`, - // note that ncarry could be >= 0x3ffffff - var ncarry = carry >>> 26; - var rword = carry & 0x3ffffff; - var maxJ = Math.min(k, num.length - 1); - for (var j = Math.max(0, k - self.length + 1); j <= maxJ; j++) { - var i = (k - j) | 0; - a = self.words[i] | 0; - b = num.words[j] | 0; - r = a * b + rword; - ncarry += (r / 0x4000000) | 0; - rword = r & 0x3ffffff; - } - out.words[k] = rword | 0; - carry = ncarry | 0; - } - if (carry !== 0) { - out.words[k] = carry | 0; - } else { - out.length--; + out.length--; } return out.strip(); @@ -8183,148 +6306,69 @@ var _temp = function () { }; })(typeof module === 'undefined' || module, this); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(444)(module))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(384)(module))) /***/ }), -/* 24 */ +/* 12 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var _assign = __webpack_require__(5); - -var ReactBaseClasses = __webpack_require__(74); -var ReactChildren = __webpack_require__(122); -var ReactDOMFactories = __webpack_require__(126); -var ReactElement = __webpack_require__(19); -var ReactPropTypes = __webpack_require__(130); -var ReactVersion = __webpack_require__(132); +var typeforce = __webpack_require__(9) -var createReactClass = __webpack_require__(133); -var onlyChild = __webpack_require__(134); - -var createElement = ReactElement.createElement; -var createFactory = ReactElement.createFactory; -var cloneElement = ReactElement.cloneElement; - -if (process.env.NODE_ENV !== 'production') { - var lowPriorityWarning = __webpack_require__(48); - var canDefineProperty = __webpack_require__(38); - var ReactElementValidator = __webpack_require__(78); - var didWarnPropTypesDeprecated = false; - createElement = ReactElementValidator.createElement; - createFactory = ReactElementValidator.createFactory; - cloneElement = ReactElementValidator.cloneElement; +var UINT31_MAX = Math.pow(2, 31) - 1 +function UInt31 (value) { + return typeforce.UInt32(value) && value <= UINT31_MAX } -var __spread = _assign; -var createMixin = function (mixin) { - return mixin; -}; - -if (process.env.NODE_ENV !== 'production') { - var warnedForSpread = false; - var warnedForCreateMixin = false; - __spread = function () { - lowPriorityWarning(warnedForSpread, 'React.__spread is deprecated and should not be used. Use ' + 'Object.assign directly or another helper function with similar ' + 'semantics. You may be seeing this warning due to your compiler. ' + 'See https://fb.me/react-spread-deprecation for more details.'); - warnedForSpread = true; - return _assign.apply(null, arguments); - }; +function BIP32Path (value) { + return typeforce.String(value) && value.match(/^(m\/)?(\d+'?\/)*\d+'?$/) +} +BIP32Path.toJSON = function () { return 'BIP32 derivation path' } - createMixin = function (mixin) { - lowPriorityWarning(warnedForCreateMixin, 'React.createMixin is deprecated and should not be used. ' + 'In React v16.0, it will be removed. ' + 'You can use this mixin directly instead. ' + 'See https://fb.me/createmixin-was-never-implemented for more info.'); - warnedForCreateMixin = true; - return mixin; - }; +var SATOSHI_MAX = 21 * 1e14 +function Satoshi (value) { + return typeforce.UInt53(value) && value <= SATOSHI_MAX } -var React = { - // Modern +// external dependent types +var BigInt = typeforce.quacksLike('BigInteger') +var ECPoint = typeforce.quacksLike('Point') - Children: { - map: ReactChildren.map, - forEach: ReactChildren.forEach, - count: ReactChildren.count, - toArray: ReactChildren.toArray, - only: onlyChild +// exposed, external API +var ECSignature = typeforce.compile({ r: BigInt, s: BigInt }) +var Network = typeforce.compile({ + messagePrefix: typeforce.oneOf(typeforce.Buffer, typeforce.String), + bip32: { + public: typeforce.UInt32, + private: typeforce.UInt32 }, + pubKeyHash: typeforce.UInt8, + scriptHash: typeforce.UInt8, + wif: typeforce.UInt8 +}) - Component: ReactBaseClasses.Component, - PureComponent: ReactBaseClasses.PureComponent, - - createElement: createElement, - cloneElement: cloneElement, - isValidElement: ReactElement.isValidElement, - - // Classic - - PropTypes: ReactPropTypes, - createClass: createReactClass, - createFactory: createFactory, - createMixin: createMixin, - - // This looks DOM specific but these are actually isomorphic helpers - // since they are just generating DOM strings. - DOM: ReactDOMFactories, - - version: ReactVersion, - - // Deprecated hook for JSX spread, don't use this for anything. - __spread: __spread -}; - -if (process.env.NODE_ENV !== 'production') { - var warnedForCreateClass = false; - if (canDefineProperty) { - Object.defineProperty(React, 'PropTypes', { - get: function () { - lowPriorityWarning(didWarnPropTypesDeprecated, 'Accessing PropTypes via the main React package is deprecated,' + ' and will be removed in React v16.0.' + ' Use the latest available v15.* prop-types package from npm instead.' + ' For info on usage, compatibility, migration and more, see ' + 'https://fb.me/prop-types-docs'); - didWarnPropTypesDeprecated = true; - return ReactPropTypes; - } - }); - - Object.defineProperty(React, 'createClass', { - get: function () { - lowPriorityWarning(warnedForCreateClass, 'Accessing createClass via the main React package is deprecated,' + ' and will be removed in React v16.0.' + " Use a plain JavaScript class instead. If you're not yet " + 'ready to migrate, create-react-class v15.* is available ' + 'on npm as a temporary, drop-in replacement. ' + 'For more info see https://fb.me/react-create-class'); - warnedForCreateClass = true; - return createReactClass; - } - }); - } +// extend typeforce types with ours +var types = { + BigInt: BigInt, + BIP32Path: BIP32Path, + Buffer256bit: typeforce.BufferN(32), + ECPoint: ECPoint, + ECSignature: ECSignature, + Hash160bit: typeforce.BufferN(20), + Hash256bit: typeforce.BufferN(32), + Network: Network, + Satoshi: Satoshi, + UInt31: UInt31 +} - // React.DOM factories are deprecated. Wrap these methods so that - // invocations of the React.DOM namespace and alert users to switch - // to the `react-dom-factories` package. - React.DOM = {}; - var warnedForFactories = false; - Object.keys(ReactDOMFactories).forEach(function (factory) { - React.DOM[factory] = function () { - if (!warnedForFactories) { - lowPriorityWarning(false, 'Accessing factories like React.DOM.%s has been deprecated ' + 'and will be removed in v16.0+. Use the ' + 'react-dom-factories package instead. ' + ' Version 1.0 provides a drop-in replacement.' + ' For more info, see https://fb.me/react-dom-factories', factory); - warnedForFactories = true; - } - return ReactDOMFactories[factory].apply(ReactDOMFactories, arguments); - }; - }); +for (var typeName in typeforce) { + types[typeName] = typeforce[typeName] } -module.exports = React; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = types + /***/ }), -/* 25 */ +/* 13 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -8336,1669 +6380,1759 @@ module.exports = React; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ + +var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement); + /** - * WARNING: DO NOT manually require this module. - * This is a replacement for `invariant(...)` used by the error code system - * and will _only_ be required by the corresponding babel pass. - * It always throws. + * Simple, lightweight module assisting with the detection and context of + * Worker. Helps avoid circular dependencies and allows code to reason about + * whether or not they are in a Worker, even if they never include the main + * `ReactWorker` dependency. */ +var ExecutionEnvironment = { -function reactProdInvariant(code) { - var argCount = arguments.length - 1; + canUseDOM: canUseDOM, - var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; + canUseWorkers: typeof Worker !== 'undefined', - for (var argIdx = 0; argIdx < argCount; argIdx++) { - message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); - } + canUseEventListeners: canUseDOM && !!(window.addEventListener || window.attachEvent), - message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; + canUseViewport: canUseDOM && !!window.screen, - var error = new Error(message); - error.name = 'Invariant Violation'; - error.framesToPop = 1; // we don't care about reactProdInvariant's own frame + isInWorker: !canUseDOM // For now, this is true - might change in the future. - throw error; -} +}; -module.exports = reactProdInvariant; +module.exports = ExecutionEnvironment; /***/ }), -/* 26 */ +/* 14 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +var Buffer = __webpack_require__(7).Buffer +var bip66 = __webpack_require__(104) +var pushdata = __webpack_require__(202) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var scriptNumber = __webpack_require__(203) +var OPS = __webpack_require__(16) +var REVERSE_OPS = __webpack_require__(468) +var OP_INT_BASE = OPS.OP_RESERVED // OP_1 - 1 -var ReactRef = __webpack_require__(143); -var ReactInstrumentation = __webpack_require__(13); +function isOPInt (value) { + return types.Number(value) && + ((value === OPS.OP_0) || + (value >= OPS.OP_1 && value <= OPS.OP_16) || + (value === OPS.OP_1NEGATE)) +} -var warning = __webpack_require__(2); +function isPushOnlyChunk (value) { + return types.Buffer(value) || isOPInt(value) +} -/** - * Helper to call ReactRef.attachRefs with this composite component, split out - * to avoid allocations in the transaction mount-ready queue. - */ -function attachRefs() { - ReactRef.attachRefs(this, this._currentElement); +function isPushOnly (value) { + return types.Array(value) && value.every(isPushOnlyChunk) } -var ReactReconciler = { - /** - * Initializes the component, renders markup, and registers event listeners. - * - * @param {ReactComponent} internalInstance - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?object} the containing host component instance - * @param {?object} info about the host container - * @return {?string} Rendered markup to be inserted into the DOM. - * @final - * @internal - */ - mountComponent: function (internalInstance, transaction, hostParent, hostContainerInfo, context, parentDebugID) // 0 in production and for roots - { - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeMountComponent(internalInstance._debugID, internalInstance._currentElement, parentDebugID); - } - } - var markup = internalInstance.mountComponent(transaction, hostParent, hostContainerInfo, context, parentDebugID); - if (internalInstance._currentElement && internalInstance._currentElement.ref != null) { - transaction.getReactMountReady().enqueue(attachRefs, internalInstance); - } - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onMountComponent(internalInstance._debugID); - } - } - return markup; - }, +function compile (chunks) { + // TODO: remove me + if (Buffer.isBuffer(chunks)) return chunks - /** - * Returns a value that can be passed to - * ReactComponentEnvironment.replaceNodeWithMarkup. - */ - getHostNode: function (internalInstance) { - return internalInstance.getHostNode(); - }, + typeforce(types.Array, chunks) - /** - * Releases any resources allocated by `mountComponent`. - * - * @final - * @internal - */ - unmountComponent: function (internalInstance, safely) { - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUnmountComponent(internalInstance._debugID); - } - } - ReactRef.detachRefs(internalInstance, internalInstance._currentElement); - internalInstance.unmountComponent(safely); - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUnmountComponent(internalInstance._debugID); + var bufferSize = chunks.reduce(function (accum, chunk) { + // data chunk + if (Buffer.isBuffer(chunk)) { + // adhere to BIP62.3, minimal push policy + if (chunk.length === 1 && (chunk[0] === 0x81 || (chunk[0] >= 1 && chunk[0] <= 16))) { + return accum + 1 } - } - }, - /** - * Update a component using a new element. - * - * @param {ReactComponent} internalInstance - * @param {ReactElement} nextElement - * @param {ReactReconcileTransaction} transaction - * @param {object} context - * @internal - */ - receiveComponent: function (internalInstance, nextElement, transaction, context) { - var prevElement = internalInstance._currentElement; + return accum + pushdata.encodingLength(chunk.length) + chunk.length + } - if (nextElement === prevElement && context === internalInstance._context) { - // Since elements are immutable after the owner is rendered, - // we can do a cheap identity compare here to determine if this is a - // superfluous reconcile. It's possible for state to be mutable but such - // change should trigger an update of the owner which would recreate - // the element. We explicitly check for the existence of an owner since - // it's possible for an element created outside a composite to be - // deeply mutated and reused. + // opcode + return accum + 1 + }, 0.0) - // TODO: Bailing out early is just a perf optimization right? - // TODO: Removing the return statement should affect correctness? - return; - } + var buffer = Buffer.allocUnsafe(bufferSize) + var offset = 0 - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, nextElement); + chunks.forEach(function (chunk) { + // data chunk + if (Buffer.isBuffer(chunk)) { + // adhere to BIP62.3, minimal push policy + if (chunk.length === 1 && chunk[0] >= 1 && chunk[0] <= 16) { + var opcode = OP_INT_BASE + chunk[0] + buffer.writeUInt8(opcode, offset) + offset += 1 + return } - } - var refsChanged = ReactRef.shouldUpdateRefs(prevElement, nextElement); + if (chunk.length === 1 && chunk[0] === 0x81) { + buffer.writeUInt8(OPS.OP_1NEGATE, offset) + offset += 1 + return + } - if (refsChanged) { - ReactRef.detachRefs(internalInstance, prevElement); - } + offset += pushdata.encode(buffer, chunk.length, offset) - internalInstance.receiveComponent(nextElement, transaction, context); + chunk.copy(buffer, offset) + offset += chunk.length - if (refsChanged && internalInstance._currentElement && internalInstance._currentElement.ref != null) { - transaction.getReactMountReady().enqueue(attachRefs, internalInstance); + // opcode + } else { + buffer.writeUInt8(chunk, offset) + offset += 1 } + }) - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); - } - } - }, + if (offset !== buffer.length) throw new Error('Could not decode chunks') + return buffer +} - /** - * Flush any dirty changes in a component. - * - * @param {ReactComponent} internalInstance - * @param {ReactReconcileTransaction} transaction - * @internal - */ - performUpdateIfNecessary: function (internalInstance, transaction, updateBatchNumber) { - if (internalInstance._updateBatchNumber !== updateBatchNumber) { - // The component's enqueued batch number should always be the current - // batch or the following one. - process.env.NODE_ENV !== 'production' ? warning(internalInstance._updateBatchNumber == null || internalInstance._updateBatchNumber === updateBatchNumber + 1, 'performUpdateIfNecessary: Unexpected batch number (current %s, ' + 'pending %s)', updateBatchNumber, internalInstance._updateBatchNumber) : void 0; - return; - } - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, internalInstance._currentElement); - } - } - internalInstance.performUpdateIfNecessary(transaction); - if (process.env.NODE_ENV !== 'production') { - if (internalInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); - } - } - } -}; +function decompile (buffer) { + // TODO: remove me + if (types.Array(buffer)) return buffer -module.exports = ReactReconciler; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + typeforce(types.Buffer, buffer) -/***/ }), -/* 27 */ -/***/ (function(module, exports, __webpack_require__) { + var chunks = [] + var i = 0 -"use strict"; -/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + while (i < buffer.length) { + var opcode = buffer[i] + // data chunk + if ((opcode > OPS.OP_0) && (opcode <= OPS.OP_PUSHDATA4)) { + var d = pushdata.decode(buffer, i) + // did reading a pushDataInt fail? empty script + if (d === null) return [] + i += d.size -var DOMNamespaces = __webpack_require__(56); -var setInnerHTML = __webpack_require__(43); + // attempt to read too much data? empty script + if (i + d.number > buffer.length) return [] -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); -var setTextContent = __webpack_require__(90); + var data = buffer.slice(i, i + d.number) + i += d.number -var ELEMENT_NODE_TYPE = 1; -var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + chunks.push(data) -/** - * In IE (8-11) and Edge, appending nodes with no children is dramatically - * faster than appending a full subtree, so we essentially queue up the - * .appendChild calls here and apply them so each node is added to its parent - * before any children are added. - * - * In other browsers, doing so is slower or neutral compared to the other order - * (in Firefox, twice as slow) so we only do this inversion in IE. - * - * See https://github.com/spicyj/innerhtml-vs-createelement-vs-clonenode. - */ -var enableLazy = typeof document !== 'undefined' && typeof document.documentMode === 'number' || typeof navigator !== 'undefined' && typeof navigator.userAgent === 'string' && /\bEdge\/\d/.test(navigator.userAgent); + // opcode + } else { + chunks.push(opcode) -function insertTreeChildren(tree) { - if (!enableLazy) { - return; - } - var node = tree.node; - var children = tree.children; - if (children.length) { - for (var i = 0; i < children.length; i++) { - insertTreeBefore(node, children[i], null); + i += 1 } - } else if (tree.html != null) { - setInnerHTML(node, tree.html); - } else if (tree.text != null) { - setTextContent(node, tree.text); } + + return chunks } -var insertTreeBefore = createMicrosoftUnsafeLocalFunction(function (parentNode, tree, referenceNode) { - // DocumentFragments aren't actually part of the DOM after insertion so - // appending children won't update the DOM. We need to ensure the fragment - // is properly populated first, breaking out of our lazy approach for just - // this level. Also, some <object> plugins (like Flash Player) will read - // <param> nodes immediately upon insertion into the DOM, so <object> - // must also be populated prior to insertion into the DOM. - if (tree.node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE || tree.node.nodeType === ELEMENT_NODE_TYPE && tree.node.nodeName.toLowerCase() === 'object' && (tree.node.namespaceURI == null || tree.node.namespaceURI === DOMNamespaces.html)) { - insertTreeChildren(tree); - parentNode.insertBefore(tree.node, referenceNode); - } else { - parentNode.insertBefore(tree.node, referenceNode); - insertTreeChildren(tree); +function toASM (chunks) { + if (Buffer.isBuffer(chunks)) { + chunks = decompile(chunks) } -}); -function replaceChildWithTree(oldNode, newTree) { - oldNode.parentNode.replaceChild(newTree.node, oldNode); - insertTreeChildren(newTree); -} + return chunks.map(function (chunk) { + // data? + if (Buffer.isBuffer(chunk)) return chunk.toString('hex') -function queueChild(parentTree, childTree) { - if (enableLazy) { - parentTree.children.push(childTree); - } else { - parentTree.node.appendChild(childTree.node); - } + // opcode! + return REVERSE_OPS[chunk] + }).join(' ') } -function queueHTML(tree, html) { - if (enableLazy) { - tree.html = html; - } else { - setInnerHTML(tree.node, html); - } -} +function fromASM (asm) { + typeforce(types.String, asm) -function queueText(tree, text) { - if (enableLazy) { - tree.text = text; - } else { - setTextContent(tree.node, text); - } -} + return compile(asm.split(' ').map(function (chunkStr) { + // opcode? + if (OPS[chunkStr] !== undefined) return OPS[chunkStr] + typeforce(types.Hex, chunkStr) -function toString() { - return this.node.nodeName; + // data! + return Buffer.from(chunkStr, 'hex') + })) } -function DOMLazyTree(node) { - return { - node: node, - children: [], - html: null, - text: null, - toString: toString - }; -} - -DOMLazyTree.insertTreeBefore = insertTreeBefore; -DOMLazyTree.replaceChildWithTree = replaceChildWithTree; -DOMLazyTree.queueChild = queueChild; -DOMLazyTree.queueHTML = queueHTML; -DOMLazyTree.queueText = queueText; - -module.exports = DOMLazyTree; - -/***/ }), -/* 28 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; +function toStack (chunks) { + chunks = decompile(chunks) + typeforce(isPushOnly, chunks) + return chunks.map(function (op) { + if (Buffer.isBuffer(op)) return op + if (op === OPS.OP_0) return Buffer.allocUnsafe(0) -module.exports = __webpack_require__(135); + return scriptNumber.encode(op - OP_INT_BASE) + }) +} +function isCanonicalPubKey (buffer) { + if (!Buffer.isBuffer(buffer)) return false + if (buffer.length < 33) return false -/***/ }), -/* 29 */ -/***/ (function(module, exports, __webpack_require__) { + switch (buffer[0]) { + case 0x02: + case 0x03: + return buffer.length === 33 + case 0x04: + return buffer.length === 65 + } -var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! - Copyright (c) 2016 Jed Watson. - Licensed under the MIT License (MIT), see - http://jedwatson.github.io/classnames -*/ -/* global define */ + return false +} -(function () { - 'use strict'; +function isDefinedHashType (hashType) { + var hashTypeMod = hashType & ~0x80 - var hasOwn = {}.hasOwnProperty; +// return hashTypeMod > SIGHASH_ALL && hashTypeMod < SIGHASH_SINGLE + return hashTypeMod > 0x00 && hashTypeMod < 0x04 +} - function classNames () { - var classes = []; +function isCanonicalSignature (buffer) { + if (!Buffer.isBuffer(buffer)) return false + if (!isDefinedHashType(buffer[buffer.length - 1])) return false - for (var i = 0; i < arguments.length; i++) { - var arg = arguments[i]; - if (!arg) continue; + return bip66.check(buffer.slice(0, -1)) +} - var argType = typeof arg; +module.exports = { + compile: compile, + decompile: decompile, + fromASM: fromASM, + toASM: toASM, + toStack: toStack, - if (argType === 'string' || argType === 'number') { - classes.push(arg); - } else if (Array.isArray(arg)) { - classes.push(classNames.apply(null, arg)); - } else if (argType === 'object') { - for (var key in arg) { - if (hasOwn.call(arg, key) && arg[key]) { - classes.push(key); - } - } - } - } + number: __webpack_require__(203), - return classes.join(' '); - } + isCanonicalPubKey: isCanonicalPubKey, + isCanonicalSignature: isCanonicalSignature, + isPushOnly: isPushOnly, + isDefinedHashType: isDefinedHashType +} - if (typeof module !== 'undefined' && module.exports) { - module.exports = classNames; - } else if (true) { - // register as 'classnames', consistent with npm package name - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function () { - return classNames; - }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else { - window.classNames = classNames; - } -}()); +var templates = __webpack_require__(469) +for (var key in templates) { + module.exports[key] = templates[key] +} /***/ }), -/* 30 */ +/* 15 */ /***/ (function(module, exports, __webpack_require__) { -var typeforce = __webpack_require__(21) - -var UINT31_MAX = Math.pow(2, 31) - 1 -function UInt31 (value) { - return typeforce.UInt32(value) && value <= UINT31_MAX -} - -function BIP32Path (value) { - return typeforce.String(value) && value.match(/^(m\/)?(\d+'?\/)*\d+'?$/) -} -BIP32Path.toJSON = function () { return 'BIP32 derivation path' } +"use strict"; -var SATOSHI_MAX = 21 * 1e14 -function Satoshi (value) { - return typeforce.UInt53(value) && value <= SATOSHI_MAX -} -// external dependent types -var BigInt = typeforce.quacksLike('BigInteger') -var ECPoint = typeforce.quacksLike('Point') +var elliptic = exports; -// exposed, external API -var ECSignature = typeforce.compile({ r: BigInt, s: BigInt }) -var Network = typeforce.compile({ - messagePrefix: typeforce.oneOf(typeforce.Buffer, typeforce.String), - bip32: { - public: typeforce.UInt32, - private: typeforce.UInt32 - }, - pubKeyHash: typeforce.UInt8, - scriptHash: typeforce.UInt8, - wif: typeforce.UInt8 -}) +elliptic.version = __webpack_require__(385).version; +elliptic.utils = __webpack_require__(386); +elliptic.rand = __webpack_require__(171); +elliptic.curve = __webpack_require__(65); +elliptic.curves = __webpack_require__(392); -// extend typeforce types with ours -var types = { - BigInt: BigInt, - BIP32Path: BIP32Path, - Buffer256bit: typeforce.BufferN(32), - ECPoint: ECPoint, - ECSignature: ECSignature, - Hash160bit: typeforce.BufferN(20), - Hash256bit: typeforce.BufferN(32), - Network: Network, - Satoshi: Satoshi, - UInt31: UInt31 -} +// Protocols +elliptic.ec = __webpack_require__(400); +elliptic.eddsa = __webpack_require__(404); -for (var typeName in typeforce) { - types[typeName] = typeforce[typeName] -} -module.exports = types +/***/ }), +/* 16 */ +/***/ (function(module, exports) { +module.exports = { + "OP_FALSE": 0, + "OP_0": 0, + "OP_PUSHDATA1": 76, + "OP_PUSHDATA2": 77, + "OP_PUSHDATA4": 78, + "OP_1NEGATE": 79, + "OP_RESERVED": 80, + "OP_1": 81, + "OP_TRUE": 81, + "OP_2": 82, + "OP_3": 83, + "OP_4": 84, + "OP_5": 85, + "OP_6": 86, + "OP_7": 87, + "OP_8": 88, + "OP_9": 89, + "OP_10": 90, + "OP_11": 91, + "OP_12": 92, + "OP_13": 93, + "OP_14": 94, + "OP_15": 95, + "OP_16": 96, + "OP_NOP": 97, + "OP_VER": 98, + "OP_IF": 99, + "OP_NOTIF": 100, + "OP_VERIF": 101, + "OP_VERNOTIF": 102, + "OP_ELSE": 103, + "OP_ENDIF": 104, + "OP_VERIFY": 105, + "OP_RETURN": 106, + "OP_TOALTSTACK": 107, + "OP_FROMALTSTACK": 108, + "OP_2DROP": 109, + "OP_2DUP": 110, + "OP_3DUP": 111, + "OP_2OVER": 112, + "OP_2ROT": 113, + "OP_2SWAP": 114, + "OP_IFDUP": 115, + "OP_DEPTH": 116, + "OP_DROP": 117, + "OP_DUP": 118, + "OP_NIP": 119, + "OP_OVER": 120, + "OP_PICK": 121, + "OP_ROLL": 122, + "OP_ROT": 123, + "OP_SWAP": 124, + "OP_TUCK": 125, + "OP_CAT": 126, + "OP_SUBSTR": 127, + "OP_LEFT": 128, + "OP_RIGHT": 129, + "OP_SIZE": 130, + "OP_INVERT": 131, + "OP_AND": 132, + "OP_OR": 133, + "OP_XOR": 134, + "OP_EQUAL": 135, + "OP_EQUALVERIFY": 136, + "OP_RESERVED1": 137, + "OP_RESERVED2": 138, + "OP_1ADD": 139, + "OP_1SUB": 140, + "OP_2MUL": 141, + "OP_2DIV": 142, + "OP_NEGATE": 143, + "OP_ABS": 144, + "OP_NOT": 145, + "OP_0NOTEQUAL": 146, + "OP_ADD": 147, + "OP_SUB": 148, + "OP_MUL": 149, + "OP_DIV": 150, + "OP_MOD": 151, + "OP_LSHIFT": 152, + "OP_RSHIFT": 153, + "OP_BOOLAND": 154, + "OP_BOOLOR": 155, + "OP_NUMEQUAL": 156, + "OP_NUMEQUALVERIFY": 157, + "OP_NUMNOTEQUAL": 158, + "OP_LESSTHAN": 159, + "OP_GREATERTHAN": 160, + "OP_LESSTHANOREQUAL": 161, + "OP_GREATERTHANOREQUAL": 162, + "OP_MIN": 163, + "OP_MAX": 164, + "OP_WITHIN": 165, + "OP_RIPEMD160": 166, + "OP_SHA1": 167, + "OP_SHA256": 168, + "OP_HASH160": 169, + "OP_HASH256": 170, + "OP_CODESEPARATOR": 171, + "OP_CHECKSIG": 172, + "OP_CHECKSIGVERIFY": 173, + "OP_CHECKMULTISIG": 174, + "OP_CHECKMULTISIGVERIFY": 175, + "OP_NOP1": 176, + "OP_NOP2": 177, + "OP_CHECKLOCKTIMEVERIFY": 177, + "OP_NOP3": 178, + "OP_NOP4": 179, + "OP_NOP5": 180, + "OP_NOP6": 181, + "OP_NOP7": 182, + "OP_NOP8": 183, + "OP_NOP9": 184, + "OP_NOP10": 185, + "OP_PUBKEYHASH": 253, + "OP_PUBKEY": 254, + "OP_INVALIDOPCODE": 255 +}; /***/ }), -/* 31 */ +/* 17 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. + * Copyright 2016-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -var EventPluginHub = __webpack_require__(32); -var EventPluginUtils = __webpack_require__(50); +var _prodInvariant = __webpack_require__(37); -var accumulateInto = __webpack_require__(82); -var forEachAccumulated = __webpack_require__(83); -var warning = __webpack_require__(2); - -var getListener = EventPluginHub.getListener; +var ReactCurrentOwner = __webpack_require__(22); -/** - * Some event types have a notion of different registration names for different - * "phases" of propagation. This finds listeners by a given phase. - */ -function listenerAtPhase(inst, event, propagationPhase) { - var registrationName = event.dispatchConfig.phasedRegistrationNames[propagationPhase]; - return getListener(inst, registrationName); -} +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); -/** - * Tags a `SyntheticEvent` with dispatched listeners. Creating this function - * here, allows us to not have to bind or create functions for each event. - * Mutating the event's members allows us to not have to create a wrapping - * "dispatch" object that pairs the event with the listener. - */ -function accumulateDirectionalDispatches(inst, phase, event) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(inst, 'Dispatching inst must not be null') : void 0; - } - var listener = listenerAtPhase(inst, event, phase); - if (listener) { - event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); - event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); +function isNative(fn) { + // Based on isNative() from Lodash + var funcToString = Function.prototype.toString; + var hasOwnProperty = Object.prototype.hasOwnProperty; + var reIsNative = RegExp('^' + funcToString + // Take an example native function source for comparison + .call(hasOwnProperty + // Strip regex characters so we can use it for regex + ).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&' + // Remove hasOwnProperty from the template to make it generic + ).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'); + try { + var source = funcToString.call(fn); + return reIsNative.test(source); + } catch (err) { + return false; } } -/** - * Collect dispatches (must be entirely collected before dispatching - see unit - * tests). Lazily allocate the array to conserve memory. We must loop through - * each event and perform the traversal for each one. We cannot perform a - * single traversal for the entire collection of events because each event may - * have a different target. - */ -function accumulateTwoPhaseDispatchesSingle(event) { - if (event && event.dispatchConfig.phasedRegistrationNames) { - EventPluginUtils.traverseTwoPhase(event._targetInst, accumulateDirectionalDispatches, event); - } -} +var canUseCollections = +// Array.from +typeof Array.from === 'function' && +// Map +typeof Map === 'function' && isNative(Map) && +// Map.prototype.keys +Map.prototype != null && typeof Map.prototype.keys === 'function' && isNative(Map.prototype.keys) && +// Set +typeof Set === 'function' && isNative(Set) && +// Set.prototype.keys +Set.prototype != null && typeof Set.prototype.keys === 'function' && isNative(Set.prototype.keys); -/** - * Same as `accumulateTwoPhaseDispatchesSingle`, but skips over the targetID. - */ -function accumulateTwoPhaseDispatchesSingleSkipTarget(event) { - if (event && event.dispatchConfig.phasedRegistrationNames) { - var targetInst = event._targetInst; - var parentInst = targetInst ? EventPluginUtils.getParentInstance(targetInst) : null; - EventPluginUtils.traverseTwoPhase(parentInst, accumulateDirectionalDispatches, event); - } -} +var setItem; +var getItem; +var removeItem; +var getItemIDs; +var addRoot; +var removeRoot; +var getRootIDs; -/** - * Accumulates without regard to direction, does not look for phased - * registration names. Same as `accumulateDirectDispatchesSingle` but without - * requiring that the `dispatchMarker` be the same as the dispatched ID. - */ -function accumulateDispatches(inst, ignoredDirection, event) { - if (event && event.dispatchConfig.registrationName) { - var registrationName = event.dispatchConfig.registrationName; - var listener = getListener(inst, registrationName); - if (listener) { - event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); - event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); - } - } +if (canUseCollections) { + var itemMap = new Map(); + var rootIDSet = new Set(); + + setItem = function (id, item) { + itemMap.set(id, item); + }; + getItem = function (id) { + return itemMap.get(id); + }; + removeItem = function (id) { + itemMap['delete'](id); + }; + getItemIDs = function () { + return Array.from(itemMap.keys()); + }; + + addRoot = function (id) { + rootIDSet.add(id); + }; + removeRoot = function (id) { + rootIDSet['delete'](id); + }; + getRootIDs = function () { + return Array.from(rootIDSet.keys()); + }; +} else { + var itemByKey = {}; + var rootByKey = {}; + + // Use non-numeric keys to prevent V8 performance issues: + // https://github.com/facebook/react/pull/7232 + var getKeyFromID = function (id) { + return '.' + id; + }; + var getIDFromKey = function (key) { + return parseInt(key.substr(1), 10); + }; + + setItem = function (id, item) { + var key = getKeyFromID(id); + itemByKey[key] = item; + }; + getItem = function (id) { + var key = getKeyFromID(id); + return itemByKey[key]; + }; + removeItem = function (id) { + var key = getKeyFromID(id); + delete itemByKey[key]; + }; + getItemIDs = function () { + return Object.keys(itemByKey).map(getIDFromKey); + }; + + addRoot = function (id) { + var key = getKeyFromID(id); + rootByKey[key] = true; + }; + removeRoot = function (id) { + var key = getKeyFromID(id); + delete rootByKey[key]; + }; + getRootIDs = function () { + return Object.keys(rootByKey).map(getIDFromKey); + }; } -/** - * Accumulates dispatches on an `SyntheticEvent`, but only for the - * `dispatchMarker`. - * @param {SyntheticEvent} event - */ -function accumulateDirectDispatchesSingle(event) { - if (event && event.dispatchConfig.registrationName) { - accumulateDispatches(event._targetInst, null, event); +var unmountedIDs = []; + +function purgeDeep(id) { + var item = getItem(id); + if (item) { + var childIDs = item.childIDs; + + removeItem(id); + childIDs.forEach(purgeDeep); } } -function accumulateTwoPhaseDispatches(events) { - forEachAccumulated(events, accumulateTwoPhaseDispatchesSingle); +function describeComponentFrame(name, source, ownerName) { + return '\n in ' + (name || 'Unknown') + (source ? ' (at ' + source.fileName.replace(/^.*[\\\/]/, '') + ':' + source.lineNumber + ')' : ownerName ? ' (created by ' + ownerName + ')' : ''); } -function accumulateTwoPhaseDispatchesSkipTarget(events) { - forEachAccumulated(events, accumulateTwoPhaseDispatchesSingleSkipTarget); +function getDisplayName(element) { + if (element == null) { + return '#empty'; + } else if (typeof element === 'string' || typeof element === 'number') { + return '#text'; + } else if (typeof element.type === 'string') { + return element.type; + } else { + return element.type.displayName || element.type.name || 'Unknown'; + } } -function accumulateEnterLeaveDispatches(leave, enter, from, to) { - EventPluginUtils.traverseEnterLeave(from, to, accumulateDispatches, leave, enter); +function describeID(id) { + var name = ReactComponentTreeHook.getDisplayName(id); + var element = ReactComponentTreeHook.getElement(id); + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var ownerName; + if (ownerID) { + ownerName = ReactComponentTreeHook.getDisplayName(ownerID); + } + process.env.NODE_ENV !== 'production' ? warning(element, 'ReactComponentTreeHook: Missing React element for debugID %s when ' + 'building stack', id) : void 0; + return describeComponentFrame(name, element && element._source, ownerName); } -function accumulateDirectDispatches(events) { - forEachAccumulated(events, accumulateDirectDispatchesSingle); -} +var ReactComponentTreeHook = { + onSetChildren: function (id, nextChildIDs) { + var item = getItem(id); + !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; + item.childIDs = nextChildIDs; -/** - * A small set of propagation patterns, each of which will accept a small amount - * of information, and generate a set of "dispatch ready event objects" - which - * are sets of events that have already been annotated with a set of dispatched - * listener functions/ids. The API is designed this way to discourage these - * propagation strategies from actually executing the dispatches, since we - * always want to collect the entire set of dispatches before executing event a - * single one. - * - * @constructor EventPropagators - */ -var EventPropagators = { - accumulateTwoPhaseDispatches: accumulateTwoPhaseDispatches, - accumulateTwoPhaseDispatchesSkipTarget: accumulateTwoPhaseDispatchesSkipTarget, - accumulateDirectDispatches: accumulateDirectDispatches, - accumulateEnterLeaveDispatches: accumulateEnterLeaveDispatches -}; - -module.exports = EventPropagators; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 32 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var _prodInvariant = __webpack_require__(3); - -var EventPluginRegistry = __webpack_require__(40); -var EventPluginUtils = __webpack_require__(50); -var ReactErrorUtils = __webpack_require__(51); - -var accumulateInto = __webpack_require__(82); -var forEachAccumulated = __webpack_require__(83); -var invariant = __webpack_require__(1); - -/** - * Internal store for event listeners - */ -var listenerBank = {}; - -/** - * Internal queue of events that have accumulated their dispatches and are - * waiting to have their dispatches executed. - */ -var eventQueue = null; - -/** - * Dispatches an event and releases it back into the pool, unless persistent. - * - * @param {?object} event Synthetic event to be dispatched. - * @param {boolean} simulated If the event is simulated (changes exn behavior) - * @private - */ -var executeDispatchesAndRelease = function (event, simulated) { - if (event) { - EventPluginUtils.executeDispatchesInOrder(event, simulated); - - if (!event.isPersistent()) { - event.constructor.release(event); + for (var i = 0; i < nextChildIDs.length; i++) { + var nextChildID = nextChildIDs[i]; + var nextChild = getItem(nextChildID); + !nextChild ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected hook events to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('140') : void 0; + !(nextChild.childIDs != null || typeof nextChild.element !== 'object' || nextChild.element == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onSetChildren() to fire for a container child before its parent includes it in onSetChildren().') : _prodInvariant('141') : void 0; + !nextChild.isMounted ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onMountComponent() to fire for the child before its parent includes it in onSetChildren().') : _prodInvariant('71') : void 0; + if (nextChild.parentID == null) { + nextChild.parentID = id; + // TODO: This shouldn't be necessary but mounting a new root during in + // componentWillMount currently causes not-yet-mounted components to + // be purged from our tree data so their parent id is missing. + } + !(nextChild.parentID === id) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected onBeforeMountComponent() parent and onSetChildren() to be consistent (%s has parents %s and %s).', nextChildID, nextChild.parentID, id) : _prodInvariant('142', nextChildID, nextChild.parentID, id) : void 0; } - } -}; -var executeDispatchesAndReleaseSimulated = function (e) { - return executeDispatchesAndRelease(e, true); -}; -var executeDispatchesAndReleaseTopLevel = function (e) { - return executeDispatchesAndRelease(e, false); -}; - -var getDictionaryKey = function (inst) { - // Prevents V8 performance issue: - // https://github.com/facebook/react/pull/7232 - return '.' + inst._rootNodeID; -}; - -function isInteractive(tag) { - return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; -} - -function shouldPreventMouseEvent(name, type, props) { - switch (name) { - case 'onClick': - case 'onClickCapture': - case 'onDoubleClick': - case 'onDoubleClickCapture': - case 'onMouseDown': - case 'onMouseDownCapture': - case 'onMouseMove': - case 'onMouseMoveCapture': - case 'onMouseUp': - case 'onMouseUpCapture': - return !!(props.disabled && isInteractive(type)); - default: - return false; - } -} - -/** - * This is a unified interface for event plugins to be installed and configured. - * - * Event plugins can implement the following properties: - * - * `extractEvents` {function(string, DOMEventTarget, string, object): *} - * Required. When a top-level event is fired, this method is expected to - * extract synthetic events that will in turn be queued and dispatched. - * - * `eventTypes` {object} - * Optional, plugins that fire events must publish a mapping of registration - * names that are used to register listeners. Values of this mapping must - * be objects that contain `registrationName` or `phasedRegistrationNames`. - * - * `executeDispatch` {function(object, function, string)} - * Optional, allows plugins to override how an event gets dispatched. By - * default, the listener is simply invoked. - * - * Each plugin that is injected into `EventsPluginHub` is immediately operable. - * - * @public - */ -var EventPluginHub = { - /** - * Methods for injecting dependencies. - */ - injection: { - /** - * @param {array} InjectedEventPluginOrder - * @public - */ - injectEventPluginOrder: EventPluginRegistry.injectEventPluginOrder, - - /** - * @param {object} injectedNamesToPlugins Map from names to plugin modules. - */ - injectEventPluginsByName: EventPluginRegistry.injectEventPluginsByName }, - - /** - * Stores `listener` at `listenerBank[registrationName][key]`. Is idempotent. - * - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @param {function} listener The callback to store. - */ - putListener: function (inst, registrationName, listener) { - !(typeof listener === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected %s listener to be a function, instead got type %s', registrationName, typeof listener) : _prodInvariant('94', registrationName, typeof listener) : void 0; - - var key = getDictionaryKey(inst); - var bankForRegistrationName = listenerBank[registrationName] || (listenerBank[registrationName] = {}); - bankForRegistrationName[key] = listener; - - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.didPutListener) { - PluginModule.didPutListener(inst, registrationName, listener); - } + onBeforeMountComponent: function (id, element, parentID) { + var item = { + element: element, + parentID: parentID, + text: null, + childIDs: [], + isMounted: false, + updateCount: 0 + }; + setItem(id, item); }, - - /** - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @return {?function} The stored callback. - */ - getListener: function (inst, registrationName) { - // TODO: shouldPreventMouseEvent is DOM-specific and definitely should not - // live here; needs to be moved to a better place soon - var bankForRegistrationName = listenerBank[registrationName]; - if (shouldPreventMouseEvent(registrationName, inst._currentElement.type, inst._currentElement.props)) { - return null; + onBeforeUpdateComponent: function (id, element) { + var item = getItem(id); + if (!item || !item.isMounted) { + // We may end up here as a result of setState() in componentWillUnmount(). + // In this case, ignore the element. + return; } - var key = getDictionaryKey(inst); - return bankForRegistrationName && bankForRegistrationName[key]; + item.element = element; }, - - /** - * Deletes a listener from the registration bank. - * - * @param {object} inst The instance, which is the source of events. - * @param {string} registrationName Name of listener (e.g. `onClick`). - */ - deleteListener: function (inst, registrationName) { - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.willDeleteListener) { - PluginModule.willDeleteListener(inst, registrationName); + onMountComponent: function (id) { + var item = getItem(id); + !item ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Item must have been set') : _prodInvariant('144') : void 0; + item.isMounted = true; + var isRoot = item.parentID === 0; + if (isRoot) { + addRoot(id); } - - var bankForRegistrationName = listenerBank[registrationName]; - // TODO: This should never be null -- when is it? - if (bankForRegistrationName) { - var key = getDictionaryKey(inst); - delete bankForRegistrationName[key]; + }, + onUpdateComponent: function (id) { + var item = getItem(id); + if (!item || !item.isMounted) { + // We may end up here as a result of setState() in componentWillUnmount(). + // In this case, ignore the element. + return; } + item.updateCount++; }, - - /** - * Deletes all listeners for the DOM element with the supplied ID. - * - * @param {object} inst The instance, which is the source of events. - */ - deleteAllListeners: function (inst) { - var key = getDictionaryKey(inst); - for (var registrationName in listenerBank) { - if (!listenerBank.hasOwnProperty(registrationName)) { - continue; + onUnmountComponent: function (id) { + var item = getItem(id); + if (item) { + // We need to check if it exists. + // `item` might not exist if it is inside an error boundary, and a sibling + // error boundary child threw while mounting. Then this instance never + // got a chance to mount, but it still gets an unmounting event during + // the error boundary cleanup. + item.isMounted = false; + var isRoot = item.parentID === 0; + if (isRoot) { + removeRoot(id); } + } + unmountedIDs.push(id); + }, + purgeUnmountedComponents: function () { + if (ReactComponentTreeHook._preventPurging) { + // Should only be used for testing. + return; + } - if (!listenerBank[registrationName][key]) { - continue; - } + for (var i = 0; i < unmountedIDs.length; i++) { + var id = unmountedIDs[i]; + purgeDeep(id); + } + unmountedIDs.length = 0; + }, + isMounted: function (id) { + var item = getItem(id); + return item ? item.isMounted : false; + }, + getCurrentStackAddendum: function (topElement) { + var info = ''; + if (topElement) { + var name = getDisplayName(topElement); + var owner = topElement._owner; + info += describeComponentFrame(name, topElement._source, owner && owner.getName()); + } - var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; - if (PluginModule && PluginModule.willDeleteListener) { - PluginModule.willDeleteListener(inst, registrationName); - } + var currentOwner = ReactCurrentOwner.current; + var id = currentOwner && currentOwner._debugID; - delete listenerBank[registrationName][key]; + info += ReactComponentTreeHook.getStackAddendumByID(id); + return info; + }, + getStackAddendumByID: function (id) { + var info = ''; + while (id) { + info += describeID(id); + id = ReactComponentTreeHook.getParentID(id); } + return info; }, - - /** - * Allows registered plugins an opportunity to extract events from top-level - * native browser events. - * - * @return {*} An accumulation of synthetic events. - * @internal - */ - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var events; - var plugins = EventPluginRegistry.plugins; - for (var i = 0; i < plugins.length; i++) { - // Not every plugin in the ordering may be loaded at runtime. - var possiblePlugin = plugins[i]; - if (possiblePlugin) { - var extractedEvents = possiblePlugin.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); - if (extractedEvents) { - events = accumulateInto(events, extractedEvents); - } - } + getChildIDs: function (id) { + var item = getItem(id); + return item ? item.childIDs : []; + }, + getDisplayName: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (!element) { + return null; } - return events; + return getDisplayName(element); }, - - /** - * Enqueues a synthetic event that should be dispatched when - * `processEventQueue` is invoked. - * - * @param {*} events An accumulation of synthetic events. - * @internal - */ - enqueueEvents: function (events) { - if (events) { - eventQueue = accumulateInto(eventQueue, events); + getElement: function (id) { + var item = getItem(id); + return item ? item.element : null; + }, + getOwnerID: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (!element || !element._owner) { + return null; } + return element._owner._debugID; }, - - /** - * Dispatches all synthetic events on the event queue. - * - * @internal - */ - processEventQueue: function (simulated) { - // Set `eventQueue` to null before processing it so that we can tell if more - // events get enqueued while processing. - var processingEventQueue = eventQueue; - eventQueue = null; - if (simulated) { - forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseSimulated); + getParentID: function (id) { + var item = getItem(id); + return item ? item.parentID : null; + }, + getSource: function (id) { + var item = getItem(id); + var element = item ? item.element : null; + var source = element != null ? element._source : null; + return source; + }, + getText: function (id) { + var element = ReactComponentTreeHook.getElement(id); + if (typeof element === 'string') { + return element; + } else if (typeof element === 'number') { + return '' + element; } else { - forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseTopLevel); + return null; } - !!eventQueue ? process.env.NODE_ENV !== 'production' ? invariant(false, 'processEventQueue(): Additional events were enqueued while processing an event queue. Support for this has not yet been implemented.') : _prodInvariant('95') : void 0; - // This would be a good time to rethrow if any of the event handlers threw. - ReactErrorUtils.rethrowCaughtError(); }, - - /** - * These are needed for tests only. Do not use! - */ - __purge: function () { - listenerBank = {}; + getUpdateCount: function (id) { + var item = getItem(id); + return item ? item.updateCount : 0; }, - __getListenerBank: function () { - return listenerBank; + + getRootIDs: getRootIDs, + getRegisteredIDs: getItemIDs, + + pushNonStandardWarningStack: function (isCreatingElement, currentSource) { + if (typeof console.reactStack !== 'function') { + return; + } + + var stack = []; + var currentOwner = ReactCurrentOwner.current; + var id = currentOwner && currentOwner._debugID; + + try { + if (isCreatingElement) { + stack.push({ + name: id ? ReactComponentTreeHook.getDisplayName(id) : null, + fileName: currentSource ? currentSource.fileName : null, + lineNumber: currentSource ? currentSource.lineNumber : null + }); + } + + while (id) { + var element = ReactComponentTreeHook.getElement(id); + var parentID = ReactComponentTreeHook.getParentID(id); + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var ownerName = ownerID ? ReactComponentTreeHook.getDisplayName(ownerID) : null; + var source = element && element._source; + stack.push({ + name: ownerName, + fileName: source ? source.fileName : null, + lineNumber: source ? source.lineNumber : null + }); + id = parentID; + } + } catch (err) { + // Internal state is messed up. + // Stop building the stack (it's just a nice to have). + } + + console.reactStack(stack); + }, + popNonStandardWarningStack: function () { + if (typeof console.reactStackEnd !== 'function') { + return; + } + console.reactStackEnd(); } }; -module.exports = EventPluginHub; +module.exports = ReactComponentTreeHook; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 33 */ +/* 18 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; + + /** - * Copyright 2013-present, Facebook, Inc. + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ - - -var SyntheticEvent = __webpack_require__(16); - -var getEventTarget = __webpack_require__(52); +function makeEmptyFunction(arg) { + return function () { + return arg; + }; +} /** - * @interface UIEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ + * This function accepts and discards inputs; it has no side effects. This is + * primarily useful idiomatically for overridable function endpoints which + * always need to be callable, since JS lacks a null-call idiom ala Cocoa. */ -var UIEventInterface = { - view: function (event) { - if (event.view) { - return event.view; - } - - var target = getEventTarget(event); - if (target.window === target) { - // target is a window object - return target; - } +var emptyFunction = function emptyFunction() {}; - var doc = target.ownerDocument; - // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. - if (doc) { - return doc.defaultView || doc.parentWindow; - } else { - return window; - } - }, - detail: function (event) { - return event.detail || 0; - } +emptyFunction.thatReturns = makeEmptyFunction; +emptyFunction.thatReturnsFalse = makeEmptyFunction(false); +emptyFunction.thatReturnsTrue = makeEmptyFunction(true); +emptyFunction.thatReturnsNull = makeEmptyFunction(null); +emptyFunction.thatReturnsThis = function () { + return this; +}; +emptyFunction.thatReturnsArgument = function (arg) { + return arg; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticUIEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} - -SyntheticEvent.augmentClass(SyntheticUIEvent, UIEventInterface); - -module.exports = SyntheticUIEvent; +module.exports = emptyFunction; /***/ }), -/* 34 */ +/* 19 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -/** - * `ReactInstanceMap` maintains a mapping from a public facing stateful - * instance (key) and the internal representation (value). This allows public - * methods to accept the user facing instance as an argument and map them back - * to internal methods. - */ +// Trust the developer to only use ReactInstrumentation with a __DEV__ check -// TODO: Replace this with ES6: var ReactInstanceMap = new Map(); - -var ReactInstanceMap = { - /** - * This API should be called `delete` but we'd have to make sure to always - * transform these to strings for IE support. When this transform is fully - * supported we can rename it. - */ - remove: function (key) { - key._reactInternalInstance = undefined; - }, - - get: function (key) { - return key._reactInternalInstance; - }, - - has: function (key) { - return key._reactInternalInstance !== undefined; - }, +var debugTool = null; - set: function (key, value) { - key._reactInternalInstance = value; - } -}; +if (process.env.NODE_ENV !== 'production') { + var ReactDebugTool = __webpack_require__(240); + debugTool = ReactDebugTool; +} -module.exports = ReactInstanceMap; +module.exports = { debugTool: debugTool }; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 35 */ +/* 20 */ /***/ (function(module, exports, __webpack_require__) { -var Buffer = __webpack_require__(18).Buffer -var bip66 = __webpack_require__(266) -var pushdata = __webpack_require__(348) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) -var scriptNumber = __webpack_require__(349) - -var OPS = __webpack_require__(37) -var REVERSE_OPS = __webpack_require__(528) -var OP_INT_BASE = OPS.OP_RESERVED // OP_1 - 1 - -function isOPInt (value) { - return types.Number(value) && - ((value === OPS.OP_0) || - (value >= OPS.OP_1 && value <= OPS.OP_16) || - (value === OPS.OP_1NEGATE)) -} - -function isPushOnlyChunk (value) { - return types.Buffer(value) || isOPInt(value) -} +"use strict"; -function isPushOnly (value) { - return types.Array(value) && value.every(isPushOnlyChunk) -} -function compile (chunks) { - // TODO: remove me - if (Buffer.isBuffer(chunks)) return chunks +var bind = __webpack_require__(155); +var isBuffer = __webpack_require__(337); - typeforce(types.Array, chunks) +/*global toString:true*/ - var bufferSize = chunks.reduce(function (accum, chunk) { - // data chunk - if (Buffer.isBuffer(chunk)) { - // adhere to BIP62.3, minimal push policy - if (chunk.length === 1 && (chunk[0] === 0x81 || (chunk[0] >= 1 && chunk[0] <= 16))) { - return accum + 1 - } +// utils is a library of generic helper functions non-specific to axios - return accum + pushdata.encodingLength(chunk.length) + chunk.length - } +var toString = Object.prototype.toString; - // opcode - return accum + 1 - }, 0.0) +/** + * Determine if a value is an Array + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an Array, otherwise false + */ +function isArray(val) { + return toString.call(val) === '[object Array]'; +} - var buffer = Buffer.allocUnsafe(bufferSize) - var offset = 0 +/** + * Determine if a value is an ArrayBuffer + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an ArrayBuffer, otherwise false + */ +function isArrayBuffer(val) { + return toString.call(val) === '[object ArrayBuffer]'; +} - chunks.forEach(function (chunk) { - // data chunk - if (Buffer.isBuffer(chunk)) { - // adhere to BIP62.3, minimal push policy - if (chunk.length === 1 && chunk[0] >= 1 && chunk[0] <= 16) { - var opcode = OP_INT_BASE + chunk[0] - buffer.writeUInt8(opcode, offset) - offset += 1 - return - } +/** + * Determine if a value is a FormData + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an FormData, otherwise false + */ +function isFormData(val) { + return (typeof FormData !== 'undefined') && (val instanceof FormData); +} - if (chunk.length === 1 && chunk[0] === 0x81) { - buffer.writeUInt8(OPS.OP_1NEGATE, offset) - offset += 1 - return - } +/** + * Determine if a value is a view on an ArrayBuffer + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false + */ +function isArrayBufferView(val) { + var result; + if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) { + result = ArrayBuffer.isView(val); + } else { + result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer); + } + return result; +} - offset += pushdata.encode(buffer, chunk.length, offset) +/** + * Determine if a value is a String + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a String, otherwise false + */ +function isString(val) { + return typeof val === 'string'; +} - chunk.copy(buffer, offset) - offset += chunk.length +/** + * Determine if a value is a Number + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Number, otherwise false + */ +function isNumber(val) { + return typeof val === 'number'; +} - // opcode - } else { - buffer.writeUInt8(chunk, offset) - offset += 1 - } - }) +/** + * Determine if a value is undefined + * + * @param {Object} val The value to test + * @returns {boolean} True if the value is undefined, otherwise false + */ +function isUndefined(val) { + return typeof val === 'undefined'; +} - if (offset !== buffer.length) throw new Error('Could not decode chunks') - return buffer +/** + * Determine if a value is an Object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is an Object, otherwise false + */ +function isObject(val) { + return val !== null && typeof val === 'object'; } -function decompile (buffer) { - // TODO: remove me - if (types.Array(buffer)) return buffer +/** + * Determine if a value is a Date + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Date, otherwise false + */ +function isDate(val) { + return toString.call(val) === '[object Date]'; +} - typeforce(types.Buffer, buffer) +/** + * Determine if a value is a File + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a File, otherwise false + */ +function isFile(val) { + return toString.call(val) === '[object File]'; +} - var chunks = [] - var i = 0 +/** + * Determine if a value is a Blob + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Blob, otherwise false + */ +function isBlob(val) { + return toString.call(val) === '[object Blob]'; +} - while (i < buffer.length) { - var opcode = buffer[i] +/** + * Determine if a value is a Function + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Function, otherwise false + */ +function isFunction(val) { + return toString.call(val) === '[object Function]'; +} - // data chunk - if ((opcode > OPS.OP_0) && (opcode <= OPS.OP_PUSHDATA4)) { - var d = pushdata.decode(buffer, i) +/** + * Determine if a value is a Stream + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a Stream, otherwise false + */ +function isStream(val) { + return isObject(val) && isFunction(val.pipe); +} - // did reading a pushDataInt fail? empty script - if (d === null) return [] - i += d.size +/** + * Determine if a value is a URLSearchParams object + * + * @param {Object} val The value to test + * @returns {boolean} True if value is a URLSearchParams object, otherwise false + */ +function isURLSearchParams(val) { + return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams; +} - // attempt to read too much data? empty script - if (i + d.number > buffer.length) return [] +/** + * Trim excess whitespace off the beginning and end of a string + * + * @param {String} str The String to trim + * @returns {String} The String freed of excess whitespace + */ +function trim(str) { + return str.replace(/^\s*/, '').replace(/\s*$/, ''); +} - var data = buffer.slice(i, i + d.number) - i += d.number +/** + * Determine if we're running in a standard browser environment + * + * This allows axios to run in a web worker, and react-native. + * Both environments support XMLHttpRequest, but not fully standard globals. + * + * web workers: + * typeof window -> undefined + * typeof document -> undefined + * + * react-native: + * navigator.product -> 'ReactNative' + */ +function isStandardBrowserEnv() { + if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') { + return false; + } + return ( + typeof window !== 'undefined' && + typeof document !== 'undefined' + ); +} - chunks.push(data) +/** + * Iterate over an Array or an Object invoking a function for each item. + * + * If `obj` is an Array callback will be called passing + * the value, index, and complete array for each item. + * + * If 'obj' is an Object callback will be called passing + * the value, key, and complete object for each property. + * + * @param {Object|Array} obj The object to iterate + * @param {Function} fn The callback to invoke for each item + */ +function forEach(obj, fn) { + // Don't bother if no value provided + if (obj === null || typeof obj === 'undefined') { + return; + } - // opcode - } else { - chunks.push(opcode) + // Force an array if not already something iterable + if (typeof obj !== 'object' && !isArray(obj)) { + /*eslint no-param-reassign:0*/ + obj = [obj]; + } - i += 1 + if (isArray(obj)) { + // Iterate over array values + for (var i = 0, l = obj.length; i < l; i++) { + fn.call(null, obj[i], i, obj); + } + } else { + // Iterate over object keys + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key)) { + fn.call(null, obj[key], key, obj); + } } } - - return chunks } -function toASM (chunks) { - if (Buffer.isBuffer(chunks)) { - chunks = decompile(chunks) +/** + * Accepts varargs expecting each argument to be an object, then + * immutably merges the properties of each object and returns result. + * + * When multiple objects contain the same key the later object in + * the arguments list will take precedence. + * + * Example: + * + * ```js + * var result = merge({foo: 123}, {foo: 456}); + * console.log(result.foo); // outputs 456 + * ``` + * + * @param {Object} obj1 Object to merge + * @returns {Object} Result of all merge properties + */ +function merge(/* obj1, obj2, obj3, ... */) { + var result = {}; + function assignValue(val, key) { + if (typeof result[key] === 'object' && typeof val === 'object') { + result[key] = merge(result[key], val); + } else { + result[key] = val; + } } - return chunks.map(function (chunk) { - // data? - if (Buffer.isBuffer(chunk)) return chunk.toString('hex') - - // opcode! - return REVERSE_OPS[chunk] - }).join(' ') + for (var i = 0, l = arguments.length; i < l; i++) { + forEach(arguments[i], assignValue); + } + return result; } -function fromASM (asm) { - typeforce(types.String, asm) - - return compile(asm.split(' ').map(function (chunkStr) { - // opcode? - if (OPS[chunkStr] !== undefined) return OPS[chunkStr] - typeforce(types.Hex, chunkStr) - - // data! - return Buffer.from(chunkStr, 'hex') - })) +/** + * Extends object a by mutably adding to it the properties of object b. + * + * @param {Object} a The object to be extended + * @param {Object} b The object to copy properties from + * @param {Object} thisArg The object to bind function to + * @return {Object} The resulting value of object a + */ +function extend(a, b, thisArg) { + forEach(b, function assignValue(val, key) { + if (thisArg && typeof val === 'function') { + a[key] = bind(val, thisArg); + } else { + a[key] = val; + } + }); + return a; } -function toStack (chunks) { - chunks = decompile(chunks) - typeforce(isPushOnly, chunks) - - return chunks.map(function (op) { - if (Buffer.isBuffer(op)) return op - if (op === OPS.OP_0) return Buffer.allocUnsafe(0) +module.exports = { + isArray: isArray, + isArrayBuffer: isArrayBuffer, + isBuffer: isBuffer, + isFormData: isFormData, + isArrayBufferView: isArrayBufferView, + isString: isString, + isNumber: isNumber, + isObject: isObject, + isUndefined: isUndefined, + isDate: isDate, + isFile: isFile, + isBlob: isBlob, + isFunction: isFunction, + isStream: isStream, + isURLSearchParams: isURLSearchParams, + isStandardBrowserEnv: isStandardBrowserEnv, + forEach: forEach, + merge: merge, + extend: extend, + trim: trim +}; - return scriptNumber.encode(op - OP_INT_BASE) - }) -} -function isCanonicalPubKey (buffer) { - if (!Buffer.isBuffer(buffer)) return false - if (buffer.length < 33) return false +/***/ }), +/* 21 */ +/***/ (function(module, exports) { - switch (buffer[0]) { - case 0x02: - case 0x03: - return buffer.length === 33 - case 0x04: - return buffer.length === 65 - } +module.exports = assert; - return false +function assert(val, msg) { + if (!val) + throw new Error(msg || 'Assertion failed'); } -function isDefinedHashType (hashType) { - var hashTypeMod = hashType & ~0x80 - -// return hashTypeMod > SIGHASH_ALL && hashTypeMod < SIGHASH_SINGLE - return hashTypeMod > 0x00 && hashTypeMod < 0x04 -} +assert.equal = function assertEqual(l, r, msg) { + if (l != r) + throw new Error(msg || ('Assertion failed: ' + l + ' != ' + r)); +}; -function isCanonicalSignature (buffer) { - if (!Buffer.isBuffer(buffer)) return false - if (!isDefinedHashType(buffer[buffer.length - 1])) return false - return bip66.check(buffer.slice(0, -1)) -} +/***/ }), +/* 22 */ +/***/ (function(module, exports, __webpack_require__) { -module.exports = { - compile: compile, - decompile: decompile, - fromASM: fromASM, - toASM: toASM, - toStack: toStack, +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - number: __webpack_require__(349), - isCanonicalPubKey: isCanonicalPubKey, - isCanonicalSignature: isCanonicalSignature, - isPushOnly: isPushOnly, - isDefinedHashType: isDefinedHashType -} -var templates = __webpack_require__(529) -for (var key in templates) { - module.exports[key] = templates[key] -} +/** + * Keeps track of the current owner. + * + * The current owner is the component who should own any components that are + * currently being constructed. + */ +var ReactCurrentOwner = { + /** + * @internal + * @type {ReactComponent} + */ + current: null +}; +module.exports = ReactCurrentOwner; /***/ }), -/* 36 */ +/* 23 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var elliptic = exports; -elliptic.version = __webpack_require__(445).version; -elliptic.utils = __webpack_require__(446); -elliptic.rand = __webpack_require__(317); -elliptic.curve = __webpack_require__(247); -elliptic.curves = __webpack_require__(452); +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); -// Protocols -elliptic.ec = __webpack_require__(460); -elliptic.eddsa = __webpack_require__(464); +var CallbackQueue = __webpack_require__(130); +var PooledClass = __webpack_require__(32); +var ReactFeatureFlags = __webpack_require__(131); +var ReactReconciler = __webpack_require__(38); +var Transaction = __webpack_require__(58); +var invariant = __webpack_require__(2); -/***/ }), -/* 37 */ -/***/ (function(module, exports) { +var dirtyComponents = []; +var updateBatchNumber = 0; +var asapCallbackQueue = CallbackQueue.getPooled(); +var asapEnqueued = false; -module.exports = { - "OP_FALSE": 0, - "OP_0": 0, - "OP_PUSHDATA1": 76, - "OP_PUSHDATA2": 77, - "OP_PUSHDATA4": 78, - "OP_1NEGATE": 79, - "OP_RESERVED": 80, - "OP_1": 81, - "OP_TRUE": 81, - "OP_2": 82, - "OP_3": 83, - "OP_4": 84, - "OP_5": 85, - "OP_6": 86, - "OP_7": 87, - "OP_8": 88, - "OP_9": 89, - "OP_10": 90, - "OP_11": 91, - "OP_12": 92, - "OP_13": 93, - "OP_14": 94, - "OP_15": 95, - "OP_16": 96, - "OP_NOP": 97, - "OP_VER": 98, - "OP_IF": 99, - "OP_NOTIF": 100, - "OP_VERIF": 101, - "OP_VERNOTIF": 102, - "OP_ELSE": 103, - "OP_ENDIF": 104, - "OP_VERIFY": 105, - "OP_RETURN": 106, - "OP_TOALTSTACK": 107, - "OP_FROMALTSTACK": 108, - "OP_2DROP": 109, - "OP_2DUP": 110, - "OP_3DUP": 111, - "OP_2OVER": 112, - "OP_2ROT": 113, - "OP_2SWAP": 114, - "OP_IFDUP": 115, - "OP_DEPTH": 116, - "OP_DROP": 117, - "OP_DUP": 118, - "OP_NIP": 119, - "OP_OVER": 120, - "OP_PICK": 121, - "OP_ROLL": 122, - "OP_ROT": 123, - "OP_SWAP": 124, - "OP_TUCK": 125, - "OP_CAT": 126, - "OP_SUBSTR": 127, - "OP_LEFT": 128, - "OP_RIGHT": 129, - "OP_SIZE": 130, - "OP_INVERT": 131, - "OP_AND": 132, - "OP_OR": 133, - "OP_XOR": 134, - "OP_EQUAL": 135, - "OP_EQUALVERIFY": 136, - "OP_RESERVED1": 137, - "OP_RESERVED2": 138, - "OP_1ADD": 139, - "OP_1SUB": 140, - "OP_2MUL": 141, - "OP_2DIV": 142, - "OP_NEGATE": 143, - "OP_ABS": 144, - "OP_NOT": 145, - "OP_0NOTEQUAL": 146, - "OP_ADD": 147, - "OP_SUB": 148, - "OP_MUL": 149, - "OP_DIV": 150, - "OP_MOD": 151, - "OP_LSHIFT": 152, - "OP_RSHIFT": 153, - "OP_BOOLAND": 154, - "OP_BOOLOR": 155, - "OP_NUMEQUAL": 156, - "OP_NUMEQUALVERIFY": 157, - "OP_NUMNOTEQUAL": 158, - "OP_LESSTHAN": 159, - "OP_GREATERTHAN": 160, - "OP_LESSTHANOREQUAL": 161, - "OP_GREATERTHANOREQUAL": 162, - "OP_MIN": 163, - "OP_MAX": 164, - "OP_WITHIN": 165, - "OP_RIPEMD160": 166, - "OP_SHA1": 167, - "OP_SHA256": 168, - "OP_HASH160": 169, - "OP_HASH256": 170, - "OP_CODESEPARATOR": 171, - "OP_CHECKSIG": 172, - "OP_CHECKSIGVERIFY": 173, - "OP_CHECKMULTISIG": 174, - "OP_CHECKMULTISIGVERIFY": 175, - "OP_NOP1": 176, - "OP_NOP2": 177, - "OP_CHECKLOCKTIMEVERIFY": 177, - "OP_NOP3": 178, - "OP_NOP4": 179, - "OP_NOP5": 180, - "OP_NOP6": 181, - "OP_NOP7": 182, - "OP_NOP8": 183, - "OP_NOP9": 184, - "OP_NOP10": 185, - "OP_PUBKEYHASH": 253, - "OP_PUBKEY": 254, - "OP_INVALIDOPCODE": 255 -}; - -/***/ }), -/* 38 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var batchingStrategy = null; +function ensureInjected() { + !(ReactUpdates.ReactReconcileTransaction && batchingStrategy) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must inject a reconcile transaction class and batching strategy') : _prodInvariant('123') : void 0; +} +var NESTED_UPDATES = { + initialize: function () { + this.dirtyComponentsLength = dirtyComponents.length; + }, + close: function () { + if (this.dirtyComponentsLength !== dirtyComponents.length) { + // Additional updates were enqueued by componentDidUpdate handlers or + // similar; before our own UPDATE_QUEUEING wrapper closes, we want to run + // these new updates so that if A's componentDidUpdate calls setState on + // B, B will update before the callback A's updater provided when calling + // setState. + dirtyComponents.splice(0, this.dirtyComponentsLength); + flushBatchedUpdates(); + } else { + dirtyComponents.length = 0; + } + } +}; -var canDefineProperty = false; -if (process.env.NODE_ENV !== 'production') { - try { - // $FlowFixMe https://github.com/facebook/flow/issues/285 - Object.defineProperty({}, 'x', { get: function () {} }); - canDefineProperty = true; - } catch (x) { - // IE will fail on defineProperty +var UPDATE_QUEUEING = { + initialize: function () { + this.callbackQueue.reset(); + }, + close: function () { + this.callbackQueue.notifyAll(); } -} +}; -module.exports = canDefineProperty; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var TRANSACTION_WRAPPERS = [NESTED_UPDATES, UPDATE_QUEUEING]; -/***/ }), -/* 39 */ -/***/ (function(module, exports, __webpack_require__) { +function ReactUpdatesFlushTransaction() { + this.reinitializeTransaction(); + this.dirtyComponentsLength = null; + this.callbackQueue = CallbackQueue.getPooled(); + this.reconcileTransaction = ReactUpdates.ReactReconcileTransaction.getPooled( + /* useCreateElement */true); +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +_assign(ReactUpdatesFlushTransaction.prototype, Transaction, { + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, + destructor: function () { + this.dirtyComponentsLength = null; + CallbackQueue.release(this.callbackQueue); + this.callbackQueue = null; + ReactUpdates.ReactReconcileTransaction.release(this.reconcileTransaction); + this.reconcileTransaction = null; + }, + perform: function (method, scope, a) { + // Essentially calls `this.reconcileTransaction.perform(method, scope, a)` + // with this transaction's wrappers around it. + return Transaction.perform.call(this, this.reconcileTransaction.perform, this.reconcileTransaction, method, scope, a); + } +}); -var emptyObject = {}; +PooledClass.addPoolingTo(ReactUpdatesFlushTransaction); -if (process.env.NODE_ENV !== 'production') { - Object.freeze(emptyObject); +function batchedUpdates(callback, a, b, c, d, e) { + ensureInjected(); + return batchingStrategy.batchedUpdates(callback, a, b, c, d, e); } -module.exports = emptyObject; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 40 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +/** + * Array comparator for ReactComponents by mount ordering. * - * + * @param {ReactComponent} c1 first component you're comparing + * @param {ReactComponent} c2 second component you're comparing + * @return {number} Return value usable by Array.prototype.sort(). */ +function mountOrderComparator(c1, c2) { + return c1._mountOrder - c2._mountOrder; +} + +function runBatchedUpdates(transaction) { + var len = transaction.dirtyComponentsLength; + !(len === dirtyComponents.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected flush transaction\'s stored dirty-components length (%s) to match dirty-components array length (%s).', len, dirtyComponents.length) : _prodInvariant('124', len, dirtyComponents.length) : void 0; + // Since reconciling a component higher in the owner hierarchy usually (not + // always -- see shouldComponentUpdate()) will reconcile children, reconcile + // them before their children by sorting the array. + dirtyComponents.sort(mountOrderComparator); + // Any updates enqueued while reconciling must be performed after this entire + // batch. Otherwise, if dirtyComponents is [A, B] where A has children B and + // C, B could update twice in a single batch if C's render enqueues an update + // to B (since B would have already updated, we should skip it, and the only + // way we can know to do so is by checking the batch counter). + updateBatchNumber++; -var _prodInvariant = __webpack_require__(3); + for (var i = 0; i < len; i++) { + // If a component is unmounted before pending changes apply, it will still + // be here, but we assume that it has cleared its _pendingCallbacks and + // that performUpdateIfNecessary is a noop. + var component = dirtyComponents[i]; -var invariant = __webpack_require__(1); + // If performUpdateIfNecessary happens to enqueue any new updates, we + // shouldn't execute the callbacks until the next render happens, so + // stash the callbacks first + var callbacks = component._pendingCallbacks; + component._pendingCallbacks = null; -/** - * Injectable ordering of event plugins. - */ -var eventPluginOrder = null; + var markerName; + if (ReactFeatureFlags.logTopLevelRenders) { + var namedComponent = component; + // Duck type TopLevelWrapper. This is probably always true. + if (component._currentElement.type.isReactTopLevelWrapper) { + namedComponent = component._renderedComponent; + } + markerName = 'React update: ' + namedComponent.getName(); + console.time(markerName); + } -/** - * Injectable mapping from names to event plugin modules. - */ -var namesToPlugins = {}; + ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction, updateBatchNumber); -/** - * Recomputes the plugin list using the injected plugins and plugin ordering. - * - * @private - */ -function recomputePluginOrdering() { - if (!eventPluginOrder) { - // Wait until an `eventPluginOrder` is injected. - return; - } - for (var pluginName in namesToPlugins) { - var pluginModule = namesToPlugins[pluginName]; - var pluginIndex = eventPluginOrder.indexOf(pluginName); - !(pluginIndex > -1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugins that do not exist in the plugin ordering, `%s`.', pluginName) : _prodInvariant('96', pluginName) : void 0; - if (EventPluginRegistry.plugins[pluginIndex]) { - continue; + if (markerName) { + console.timeEnd(markerName); } - !pluginModule.extractEvents ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Event plugins must implement an `extractEvents` method, but `%s` does not.', pluginName) : _prodInvariant('97', pluginName) : void 0; - EventPluginRegistry.plugins[pluginIndex] = pluginModule; - var publishedEvents = pluginModule.eventTypes; - for (var eventName in publishedEvents) { - !publishEventForPlugin(publishedEvents[eventName], pluginModule, eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Failed to publish event `%s` for plugin `%s`.', eventName, pluginName) : _prodInvariant('98', eventName, pluginName) : void 0; + + if (callbacks) { + for (var j = 0; j < callbacks.length; j++) { + transaction.callbackQueue.enqueue(callbacks[j], component.getPublicInstance()); + } } } } -/** - * Publishes an event so that it can be dispatched by the supplied plugin. - * - * @param {object} dispatchConfig Dispatch configuration for the event. - * @param {object} PluginModule Plugin publishing the event. - * @return {boolean} True if the event was successfully published. - * @private - */ -function publishEventForPlugin(dispatchConfig, pluginModule, eventName) { - !!EventPluginRegistry.eventNameDispatchConfigs.hasOwnProperty(eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same event name, `%s`.', eventName) : _prodInvariant('99', eventName) : void 0; - EventPluginRegistry.eventNameDispatchConfigs[eventName] = dispatchConfig; +var flushBatchedUpdates = function () { + // ReactUpdatesFlushTransaction's wrappers will clear the dirtyComponents + // array and perform any updates enqueued by mount-ready handlers (i.e., + // componentDidUpdate) but we need to check here too in order to catch + // updates enqueued by setState callbacks and asap calls. + while (dirtyComponents.length || asapEnqueued) { + if (dirtyComponents.length) { + var transaction = ReactUpdatesFlushTransaction.getPooled(); + transaction.perform(runBatchedUpdates, null, transaction); + ReactUpdatesFlushTransaction.release(transaction); + } - var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; - if (phasedRegistrationNames) { - for (var phaseName in phasedRegistrationNames) { - if (phasedRegistrationNames.hasOwnProperty(phaseName)) { - var phasedRegistrationName = phasedRegistrationNames[phaseName]; - publishRegistrationName(phasedRegistrationName, pluginModule, eventName); - } + if (asapEnqueued) { + asapEnqueued = false; + var queue = asapCallbackQueue; + asapCallbackQueue = CallbackQueue.getPooled(); + queue.notifyAll(); + CallbackQueue.release(queue); } - return true; - } else if (dispatchConfig.registrationName) { - publishRegistrationName(dispatchConfig.registrationName, pluginModule, eventName); - return true; } - return false; -} +}; /** - * Publishes a registration name that is used to identify dispatched events and - * can be used with `EventPluginHub.putListener` to register listeners. - * - * @param {string} registrationName Registration name to add. - * @param {object} PluginModule Plugin publishing the event. - * @private + * Mark a component as needing a rerender, adding an optional callback to a + * list of functions which will be executed once the rerender occurs. */ -function publishRegistrationName(registrationName, pluginModule, eventName) { - !!EventPluginRegistry.registrationNameModules[registrationName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same registration name, `%s`.', registrationName) : _prodInvariant('100', registrationName) : void 0; - EventPluginRegistry.registrationNameModules[registrationName] = pluginModule; - EventPluginRegistry.registrationNameDependencies[registrationName] = pluginModule.eventTypes[eventName].dependencies; +function enqueueUpdate(component) { + ensureInjected(); - if (process.env.NODE_ENV !== 'production') { - var lowerCasedName = registrationName.toLowerCase(); - EventPluginRegistry.possibleRegistrationNames[lowerCasedName] = registrationName; + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. (This is called by each top-level update + // function, like setState, forceUpdate, etc.; creation and + // destruction of top-level components is guarded in ReactMount.) - if (registrationName === 'onDoubleClick') { - EventPluginRegistry.possibleRegistrationNames.ondblclick = registrationName; - } + if (!batchingStrategy.isBatchingUpdates) { + batchingStrategy.batchedUpdates(enqueueUpdate, component); + return; + } + + dirtyComponents.push(component); + if (component._updateBatchNumber == null) { + component._updateBatchNumber = updateBatchNumber + 1; } } /** - * Registers plugins so that they can extract and dispatch events. - * - * @see {EventPluginHub} + * Enqueue a callback to be run at the end of the current batching cycle. Throws + * if no updates are currently being performed. */ -var EventPluginRegistry = { - /** - * Ordered list of injected plugins. - */ - plugins: [], - - /** - * Mapping from event name to dispatch config - */ - eventNameDispatchConfigs: {}, - - /** - * Mapping from registration name to plugin module - */ - registrationNameModules: {}, +function asap(callback, context) { + !batchingStrategy.isBatchingUpdates ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates.asap: Can\'t enqueue an asap callback in a context whereupdates are not being batched.') : _prodInvariant('125') : void 0; + asapCallbackQueue.enqueue(callback, context); + asapEnqueued = true; +} - /** - * Mapping from registration name to event name - */ - registrationNameDependencies: {}, +var ReactUpdatesInjection = { + injectReconcileTransaction: function (ReconcileTransaction) { + !ReconcileTransaction ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a reconcile transaction class') : _prodInvariant('126') : void 0; + ReactUpdates.ReactReconcileTransaction = ReconcileTransaction; + }, - /** - * Mapping from lowercase registration names to the properly cased version, - * used to warn in the case of missing event handlers. Available - * only in __DEV__. - * @type {Object} - */ - possibleRegistrationNames: process.env.NODE_ENV !== 'production' ? {} : null, - // Trust the developer to only use possibleRegistrationNames in __DEV__ + injectBatchingStrategy: function (_batchingStrategy) { + !_batchingStrategy ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batching strategy') : _prodInvariant('127') : void 0; + !(typeof _batchingStrategy.batchedUpdates === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide a batchedUpdates() function') : _prodInvariant('128') : void 0; + !(typeof _batchingStrategy.isBatchingUpdates === 'boolean') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactUpdates: must provide an isBatchingUpdates boolean attribute') : _prodInvariant('129') : void 0; + batchingStrategy = _batchingStrategy; + } +}; +var ReactUpdates = { /** - * Injects an ordering of plugins (by plugin name). This allows the ordering - * to be decoupled from injection of the actual plugins so that ordering is - * always deterministic regardless of packaging, on-the-fly injection, etc. + * React references `ReactReconcileTransaction` using this property in order + * to allow dependency injection. * - * @param {array} InjectedEventPluginOrder * @internal - * @see {EventPluginHub.injection.injectEventPluginOrder} */ - injectEventPluginOrder: function (injectedEventPluginOrder) { - !!eventPluginOrder ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugin ordering more than once. You are likely trying to load more than one copy of React.') : _prodInvariant('101') : void 0; - // Clone the ordering so it cannot be dynamically mutated. - eventPluginOrder = Array.prototype.slice.call(injectedEventPluginOrder); - recomputePluginOrdering(); - }, + ReactReconcileTransaction: null, - /** - * Injects plugins to be used by `EventPluginHub`. The plugin names must be - * in the ordering injected by `injectEventPluginOrder`. - * - * Plugins can be injected as part of page initialization or on-the-fly. - * - * @param {object} injectedNamesToPlugins Map from names to plugin modules. - * @internal - * @see {EventPluginHub.injection.injectEventPluginsByName} - */ - injectEventPluginsByName: function (injectedNamesToPlugins) { - var isOrderingDirty = false; - for (var pluginName in injectedNamesToPlugins) { - if (!injectedNamesToPlugins.hasOwnProperty(pluginName)) { - continue; - } - var pluginModule = injectedNamesToPlugins[pluginName]; - if (!namesToPlugins.hasOwnProperty(pluginName) || namesToPlugins[pluginName] !== pluginModule) { - !!namesToPlugins[pluginName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject two different event plugins using the same name, `%s`.', pluginName) : _prodInvariant('102', pluginName) : void 0; - namesToPlugins[pluginName] = pluginModule; - isOrderingDirty = true; - } - } - if (isOrderingDirty) { - recomputePluginOrdering(); - } - }, + batchedUpdates: batchedUpdates, + enqueueUpdate: enqueueUpdate, + flushBatchedUpdates: flushBatchedUpdates, + injection: ReactUpdatesInjection, + asap: asap +}; - /** - * Looks up the plugin for the supplied event. - * - * @param {object} event A synthetic event. - * @return {?object} The plugin that created the supplied event. - * @internal - */ - getPluginModuleForEvent: function (event) { - var dispatchConfig = event.dispatchConfig; - if (dispatchConfig.registrationName) { - return EventPluginRegistry.registrationNameModules[dispatchConfig.registrationName] || null; - } - if (dispatchConfig.phasedRegistrationNames !== undefined) { - // pulling phasedRegistrationNames out of dispatchConfig helps Flow see - // that it is not undefined. - var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; +module.exports = ReactUpdates; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - for (var phase in phasedRegistrationNames) { - if (!phasedRegistrationNames.hasOwnProperty(phase)) { - continue; - } - var pluginModule = EventPluginRegistry.registrationNameModules[phasedRegistrationNames[phase]]; - if (pluginModule) { - return pluginModule; - } - } - } - return null; - }, +/***/ }), +/* 24 */ +/***/ (function(module, exports) { - /** - * Exposed for unit testing. - * @private - */ - _resetEventPlugins: function () { - eventPluginOrder = null; - for (var pluginName in namesToPlugins) { - if (namesToPlugins.hasOwnProperty(pluginName)) { - delete namesToPlugins[pluginName]; - } - } - EventPluginRegistry.plugins.length = 0; +var g; + +// This works in non-strict mode +g = (function() { + return this; +})(); + +try { + // This works if eval is allowed (see CSP) + g = g || Function("return this")() || (1,eval)("this"); +} catch(e) { + // This works if the window reference is available + if(typeof window === "object") + g = window; +} + +// g can still be undefined, but nothing to do about it... +// We return undefined, instead of nothing here, so it's +// easier to handle this case. if(!global) { ...} + +module.exports = g; - var eventNameDispatchConfigs = EventPluginRegistry.eventNameDispatchConfigs; - for (var eventName in eventNameDispatchConfigs) { - if (eventNameDispatchConfigs.hasOwnProperty(eventName)) { - delete eventNameDispatchConfigs[eventName]; - } - } - var registrationNameModules = EventPluginRegistry.registrationNameModules; - for (var registrationName in registrationNameModules) { - if (registrationNameModules.hasOwnProperty(registrationName)) { - delete registrationNameModules[registrationName]; +/***/ }), +/* 25 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); + +exports.inherits = inherits; + +function toArray(msg, enc) { + if (Array.isArray(msg)) + return msg.slice(); + if (!msg) + return []; + var res = []; + if (typeof msg === 'string') { + if (!enc) { + for (var i = 0; i < msg.length; i++) { + var c = msg.charCodeAt(i); + var hi = c >> 8; + var lo = c & 0xff; + if (hi) + res.push(hi, lo); + else + res.push(lo); } + } else if (enc === 'hex') { + msg = msg.replace(/[^a-z0-9]+/ig, ''); + if (msg.length % 2 !== 0) + msg = '0' + msg; + for (i = 0; i < msg.length; i += 2) + res.push(parseInt(msg[i] + msg[i + 1], 16)); } + } else { + for (i = 0; i < msg.length; i++) + res[i] = msg[i] | 0; + } + return res; +} +exports.toArray = toArray; - if (process.env.NODE_ENV !== 'production') { - var possibleRegistrationNames = EventPluginRegistry.possibleRegistrationNames; - for (var lowerCasedName in possibleRegistrationNames) { - if (possibleRegistrationNames.hasOwnProperty(lowerCasedName)) { - delete possibleRegistrationNames[lowerCasedName]; - } - } +function toHex(msg) { + var res = ''; + for (var i = 0; i < msg.length; i++) + res += zero2(msg[i].toString(16)); + return res; +} +exports.toHex = toHex; + +function htonl(w) { + var res = (w >>> 24) | + ((w >>> 8) & 0xff00) | + ((w << 8) & 0xff0000) | + ((w & 0xff) << 24); + return res >>> 0; +} +exports.htonl = htonl; + +function toHex32(msg, endian) { + var res = ''; + for (var i = 0; i < msg.length; i++) { + var w = msg[i]; + if (endian === 'little') + w = htonl(w); + res += zero8(w.toString(16)); + } + return res; +} +exports.toHex32 = toHex32; + +function zero2(word) { + if (word.length === 1) + return '0' + word; + else + return word; +} +exports.zero2 = zero2; + +function zero8(word) { + if (word.length === 7) + return '0' + word; + else if (word.length === 6) + return '00' + word; + else if (word.length === 5) + return '000' + word; + else if (word.length === 4) + return '0000' + word; + else if (word.length === 3) + return '00000' + word; + else if (word.length === 2) + return '000000' + word; + else if (word.length === 1) + return '0000000' + word; + else + return word; +} +exports.zero8 = zero8; + +function join32(msg, start, end, endian) { + var len = end - start; + assert(len % 4 === 0); + var res = new Array(len / 4); + for (var i = 0, k = start; i < res.length; i++, k += 4) { + var w; + if (endian === 'big') + w = (msg[k] << 24) | (msg[k + 1] << 16) | (msg[k + 2] << 8) | msg[k + 3]; + else + w = (msg[k + 3] << 24) | (msg[k + 2] << 16) | (msg[k + 1] << 8) | msg[k]; + res[i] = w >>> 0; + } + return res; +} +exports.join32 = join32; + +function split32(msg, endian) { + var res = new Array(msg.length * 4); + for (var i = 0, k = 0; i < msg.length; i++, k += 4) { + var m = msg[i]; + if (endian === 'big') { + res[k] = m >>> 24; + res[k + 1] = (m >>> 16) & 0xff; + res[k + 2] = (m >>> 8) & 0xff; + res[k + 3] = m & 0xff; + } else { + res[k + 3] = m >>> 24; + res[k + 2] = (m >>> 16) & 0xff; + res[k + 1] = (m >>> 8) & 0xff; + res[k] = m & 0xff; } } -}; + return res; +} +exports.split32 = split32; + +function rotr32(w, b) { + return (w >>> b) | (w << (32 - b)); +} +exports.rotr32 = rotr32; + +function rotl32(w, b) { + return (w << b) | (w >>> (32 - b)); +} +exports.rotl32 = rotl32; + +function sum32(a, b) { + return (a + b) >>> 0; +} +exports.sum32 = sum32; + +function sum32_3(a, b, c) { + return (a + b + c) >>> 0; +} +exports.sum32_3 = sum32_3; + +function sum32_4(a, b, c, d) { + return (a + b + c + d) >>> 0; +} +exports.sum32_4 = sum32_4; + +function sum32_5(a, b, c, d, e) { + return (a + b + c + d + e) >>> 0; +} +exports.sum32_5 = sum32_5; + +function sum64(buf, pos, ah, al) { + var bh = buf[pos]; + var bl = buf[pos + 1]; + + var lo = (al + bl) >>> 0; + var hi = (lo < al ? 1 : 0) + ah + bh; + buf[pos] = hi >>> 0; + buf[pos + 1] = lo; +} +exports.sum64 = sum64; + +function sum64_hi(ah, al, bh, bl) { + var lo = (al + bl) >>> 0; + var hi = (lo < al ? 1 : 0) + ah + bh; + return hi >>> 0; +} +exports.sum64_hi = sum64_hi; + +function sum64_lo(ah, al, bh, bl) { + var lo = al + bl; + return lo >>> 0; +} +exports.sum64_lo = sum64_lo; + +function sum64_4_hi(ah, al, bh, bl, ch, cl, dh, dl) { + var carry = 0; + var lo = al; + lo = (lo + bl) >>> 0; + carry += lo < al ? 1 : 0; + lo = (lo + cl) >>> 0; + carry += lo < cl ? 1 : 0; + lo = (lo + dl) >>> 0; + carry += lo < dl ? 1 : 0; + + var hi = ah + bh + ch + dh + carry; + return hi >>> 0; +} +exports.sum64_4_hi = sum64_4_hi; + +function sum64_4_lo(ah, al, bh, bl, ch, cl, dh, dl) { + var lo = al + bl + cl + dl; + return lo >>> 0; +} +exports.sum64_4_lo = sum64_4_lo; + +function sum64_5_hi(ah, al, bh, bl, ch, cl, dh, dl, eh, el) { + var carry = 0; + var lo = al; + lo = (lo + bl) >>> 0; + carry += lo < al ? 1 : 0; + lo = (lo + cl) >>> 0; + carry += lo < cl ? 1 : 0; + lo = (lo + dl) >>> 0; + carry += lo < dl ? 1 : 0; + lo = (lo + el) >>> 0; + carry += lo < el ? 1 : 0; + + var hi = ah + bh + ch + dh + eh + carry; + return hi >>> 0; +} +exports.sum64_5_hi = sum64_5_hi; + +function sum64_5_lo(ah, al, bh, bl, ch, cl, dh, dl, eh, el) { + var lo = al + bl + cl + dl + el; + + return lo >>> 0; +} +exports.sum64_5_lo = sum64_5_lo; + +function rotr64_hi(ah, al, num) { + var r = (al << (32 - num)) | (ah >>> num); + return r >>> 0; +} +exports.rotr64_hi = rotr64_hi; + +function rotr64_lo(ah, al, num) { + var r = (ah << (32 - num)) | (al >>> num); + return r >>> 0; +} +exports.rotr64_lo = rotr64_lo; + +function shr64_hi(ah, al, num) { + return ah >>> num; +} +exports.shr64_hi = shr64_hi; + +function shr64_lo(ah, al, num) { + var r = (ah << (32 - num)) | (al >>> num); + return r >>> 0; +} +exports.shr64_lo = shr64_lo; -module.exports = EventPluginRegistry; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 41 */ +/* 26 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -10010,540 +8144,331 @@ module.exports = EventPluginRegistry; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -var _prodInvariant = __webpack_require__(3); +var _assign = __webpack_require__(8); -var invariant = __webpack_require__(1); +var PooledClass = __webpack_require__(32); -var OBSERVED_ERROR = {}; +var emptyFunction = __webpack_require__(18); +var warning = __webpack_require__(3); + +var didWarnForAddedNewProperty = false; +var isProxySupported = typeof Proxy === 'function'; + +var shouldBeReleasedProperties = ['dispatchConfig', '_targetInst', 'nativeEvent', 'isDefaultPrevented', 'isPropagationStopped', '_dispatchListeners', '_dispatchInstances']; /** - * `Transaction` creates a black box that is able to wrap any method such that - * certain invariants are maintained before and after the method is invoked - * (Even if an exception is thrown while invoking the wrapped method). Whoever - * instantiates a transaction can provide enforcers of the invariants at - * creation time. The `Transaction` class itself will supply one additional - * automatic invariant for you - the invariant that any transaction instance - * should not be run while it is already being run. You would typically create a - * single instance of a `Transaction` for reuse multiple times, that potentially - * is used to wrap several different methods. Wrappers are extremely simple - - * they only require implementing two methods. - * - * <pre> - * wrappers (injected at creation time) - * + + - * | | - * +-----------------|--------|--------------+ - * | v | | - * | +---------------+ | | - * | +--| wrapper1 |---|----+ | - * | | +---------------+ v | | - * | | +-------------+ | | - * | | +----| wrapper2 |--------+ | - * | | | +-------------+ | | | - * | | | | | | - * | v v v v | wrapper - * | +---+ +---+ +---------+ +---+ +---+ | invariants - * perform(anyMethod) | | | | | | | | | | | | maintained - * +----------------->|-|---|-|---|-->|anyMethod|---|---|-|---|-|--------> - * | | | | | | | | | | | | - * | | | | | | | | | | | | - * | | | | | | | | | | | | - * | +---+ +---+ +---------+ +---+ +---+ | - * | initialize close | - * +-----------------------------------------+ - * </pre> - * - * Use cases: - * - Preserving the input selection ranges before/after reconciliation. - * Restoring selection even in the event of an unexpected error. - * - Deactivating events while rearranging the DOM, preventing blurs/focuses, - * while guaranteeing that afterwards, the event system is reactivated. - * - Flushing a queue of collected DOM mutations to the main UI thread after a - * reconciliation takes place in a worker thread. - * - Invoking any collected `componentDidUpdate` callbacks after rendering new - * content. - * - (Future use case): Wrapping particular flushes of the `ReactWorker` queue - * to preserve the `scrollTop` (an automatic scroll aware DOM). - * - (Future use case): Layout calculations before and after DOM updates. + * @interface Event + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var EventInterface = { + type: null, + target: null, + // currentTarget is set when dispatching; no use in copying it here + currentTarget: emptyFunction.thatReturnsNull, + eventPhase: null, + bubbles: null, + cancelable: null, + timeStamp: function (event) { + return event.timeStamp || Date.now(); + }, + defaultPrevented: null, + isTrusted: null +}; + +/** + * Synthetic events are dispatched by event plugins, typically in response to a + * top-level event delegation handler. * - * Transactional plugin API: - * - A module that has an `initialize` method that returns any precomputation. - * - and a `close` method that accepts the precomputation. `close` is invoked - * when the wrapped process is completed, or has failed. + * These systems should generally use pooling to reduce the frequency of garbage + * collection. The system should check `isPersistent` to determine whether the + * event should be released into the pool after being dispatched. Users that + * need a persisted event should invoke `persist`. * - * @param {Array<TransactionalWrapper>} transactionWrapper Wrapper modules - * that implement `initialize` and `close`. - * @return {Transaction} Single transaction for reuse in thread. + * Synthetic events (and subclasses) implement the DOM Level 3 Events API by + * normalizing browser quirks. Subclasses do not necessarily have to implement a + * DOM interface; custom application-specific events can also subclass this. * - * @class Transaction + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {*} targetInst Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @param {DOMEventTarget} nativeEventTarget Target node. */ -var TransactionImpl = { - /** - * Sets up this instance so that it is prepared for collecting metrics. Does - * so such that this setup method may be used on an instance that is already - * initialized, in a way that does not consume additional memory upon reuse. - * That can be useful if you decide to make your subclass of this mixin a - * "PooledClass". - */ - reinitializeTransaction: function () { - this.transactionWrappers = this.getTransactionWrappers(); - if (this.wrapperInitData) { - this.wrapperInitData.length = 0; +function SyntheticEvent(dispatchConfig, targetInst, nativeEvent, nativeEventTarget) { + if (process.env.NODE_ENV !== 'production') { + // these have a getter/setter for warnings + delete this.nativeEvent; + delete this.preventDefault; + delete this.stopPropagation; + } + + this.dispatchConfig = dispatchConfig; + this._targetInst = targetInst; + this.nativeEvent = nativeEvent; + + var Interface = this.constructor.Interface; + for (var propName in Interface) { + if (!Interface.hasOwnProperty(propName)) { + continue; + } + if (process.env.NODE_ENV !== 'production') { + delete this[propName]; // this has a getter/setter for warnings + } + var normalize = Interface[propName]; + if (normalize) { + this[propName] = normalize(nativeEvent); } else { - this.wrapperInitData = []; + if (propName === 'target') { + this.target = nativeEventTarget; + } else { + this[propName] = nativeEvent[propName]; + } } - this._isInTransaction = false; + } + + var defaultPrevented = nativeEvent.defaultPrevented != null ? nativeEvent.defaultPrevented : nativeEvent.returnValue === false; + if (defaultPrevented) { + this.isDefaultPrevented = emptyFunction.thatReturnsTrue; + } else { + this.isDefaultPrevented = emptyFunction.thatReturnsFalse; + } + this.isPropagationStopped = emptyFunction.thatReturnsFalse; + return this; +} + +_assign(SyntheticEvent.prototype, { + preventDefault: function () { + this.defaultPrevented = true; + var event = this.nativeEvent; + if (!event) { + return; + } + + if (event.preventDefault) { + event.preventDefault(); + // eslint-disable-next-line valid-typeof + } else if (typeof event.returnValue !== 'unknown') { + event.returnValue = false; + } + this.isDefaultPrevented = emptyFunction.thatReturnsTrue; }, - _isInTransaction: false, + stopPropagation: function () { + var event = this.nativeEvent; + if (!event) { + return; + } - /** - * @abstract - * @return {Array<TransactionWrapper>} Array of transaction wrappers. - */ - getTransactionWrappers: null, + if (event.stopPropagation) { + event.stopPropagation(); + // eslint-disable-next-line valid-typeof + } else if (typeof event.cancelBubble !== 'unknown') { + // The ChangeEventPlugin registers a "propertychange" event for + // IE. This event does not support bubbling or cancelling, and + // any references to cancelBubble throw "Member not found". A + // typeof check of "unknown" circumvents this issue (and is also + // IE specific). + event.cancelBubble = true; + } - isInTransaction: function () { - return !!this._isInTransaction; + this.isPropagationStopped = emptyFunction.thatReturnsTrue; }, - /* eslint-disable space-before-function-paren */ + /** + * We release all dispatched `SyntheticEvent`s after each event loop, adding + * them back into the pool. This allows a way to hold onto a reference that + * won't be added back into the pool. + */ + persist: function () { + this.isPersistent = emptyFunction.thatReturnsTrue; + }, /** - * Executes the function within a safety window. Use this for the top level - * methods that result in large amounts of computation/mutations that would - * need to be safety checked. The optional arguments helps prevent the need - * to bind in many cases. - * - * @param {function} method Member of scope to call. - * @param {Object} scope Scope to invoke from. - * @param {Object?=} a Argument to pass to the method. - * @param {Object?=} b Argument to pass to the method. - * @param {Object?=} c Argument to pass to the method. - * @param {Object?=} d Argument to pass to the method. - * @param {Object?=} e Argument to pass to the method. - * @param {Object?=} f Argument to pass to the method. + * Checks if this event should be released back into the pool. * - * @return {*} Return value from `method`. + * @return {boolean} True if this should not be released, false otherwise. */ - perform: function (method, scope, a, b, c, d, e, f) { - /* eslint-enable space-before-function-paren */ - !!this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.perform(...): Cannot initialize a transaction when there is already an outstanding transaction.') : _prodInvariant('27') : void 0; - var errorThrown; - var ret; - try { - this._isInTransaction = true; - // Catching errors makes debugging more difficult, so we start with - // errorThrown set to true before setting it to false after calling - // close -- if it's still set to true in the finally block, it means - // one of these calls threw. - errorThrown = true; - this.initializeAll(0); - ret = method.call(scope, a, b, c, d, e, f); - errorThrown = false; - } finally { - try { - if (errorThrown) { - // If `method` throws, prefer to show that stack trace over any thrown - // by invoking `closeAll`. - try { - this.closeAll(0); - } catch (err) {} - } else { - // Since `method` didn't throw, we don't want to silence the exception - // here. - this.closeAll(0); - } - } finally { - this._isInTransaction = false; - } - } - return ret; - }, - - initializeAll: function (startIndex) { - var transactionWrappers = this.transactionWrappers; - for (var i = startIndex; i < transactionWrappers.length; i++) { - var wrapper = transactionWrappers[i]; - try { - // Catching errors makes debugging more difficult, so we start with the - // OBSERVED_ERROR state before overwriting it with the real return value - // of initialize -- if it's still set to OBSERVED_ERROR in the finally - // block, it means wrapper.initialize threw. - this.wrapperInitData[i] = OBSERVED_ERROR; - this.wrapperInitData[i] = wrapper.initialize ? wrapper.initialize.call(this) : null; - } finally { - if (this.wrapperInitData[i] === OBSERVED_ERROR) { - // The initializer for wrapper i threw an error; initialize the - // remaining wrappers but silence any exceptions from them to ensure - // that the first error is the one to bubble up. - try { - this.initializeAll(i + 1); - } catch (err) {} - } - } - } - }, + isPersistent: emptyFunction.thatReturnsFalse, /** - * Invokes each of `this.transactionWrappers.close[i]` functions, passing into - * them the respective return values of `this.transactionWrappers.init[i]` - * (`close`rs that correspond to initializers that failed will not be - * invoked). + * `PooledClass` looks for `destructor` on each instance it releases. */ - closeAll: function (startIndex) { - !this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.closeAll(): Cannot close transaction when none are open.') : _prodInvariant('28') : void 0; - var transactionWrappers = this.transactionWrappers; - for (var i = startIndex; i < transactionWrappers.length; i++) { - var wrapper = transactionWrappers[i]; - var initData = this.wrapperInitData[i]; - var errorThrown; - try { - // Catching errors makes debugging more difficult, so we start with - // errorThrown set to true before setting it to false after calling - // close -- if it's still set to true in the finally block, it means - // wrapper.close threw. - errorThrown = true; - if (initData !== OBSERVED_ERROR && wrapper.close) { - wrapper.close.call(this, initData); - } - errorThrown = false; - } finally { - if (errorThrown) { - // The closer for wrapper i threw an error; close the remaining - // wrappers but silence any exceptions from them to ensure that the - // first error is the one to bubble up. - try { - this.closeAll(i + 1); - } catch (e) {} - } + destructor: function () { + var Interface = this.constructor.Interface; + for (var propName in Interface) { + if (process.env.NODE_ENV !== 'production') { + Object.defineProperty(this, propName, getPooledWarningPropertyDefinition(propName, Interface[propName])); + } else { + this[propName] = null; } } - this.wrapperInitData.length = 0; + for (var i = 0; i < shouldBeReleasedProperties.length; i++) { + this[shouldBeReleasedProperties[i]] = null; + } + if (process.env.NODE_ENV !== 'production') { + Object.defineProperty(this, 'nativeEvent', getPooledWarningPropertyDefinition('nativeEvent', null)); + Object.defineProperty(this, 'preventDefault', getPooledWarningPropertyDefinition('preventDefault', emptyFunction)); + Object.defineProperty(this, 'stopPropagation', getPooledWarningPropertyDefinition('stopPropagation', emptyFunction)); + } } -}; - -module.exports = TransactionImpl; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 42 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var SyntheticUIEvent = __webpack_require__(33); -var ViewportMetrics = __webpack_require__(89); +}); -var getEventModifierState = __webpack_require__(54); +SyntheticEvent.Interface = EventInterface; -/** - * @interface MouseEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var MouseEventInterface = { - screenX: null, - screenY: null, - clientX: null, - clientY: null, - ctrlKey: null, - shiftKey: null, - altKey: null, - metaKey: null, - getModifierState: getEventModifierState, - button: function (event) { - // Webkit, Firefox, IE9+ - // which: 1 2 3 - // button: 0 1 2 (standard) - var button = event.button; - if ('which' in event) { - return button; - } - // IE<9 - // which: undefined - // button: 0 0 0 - // button: 1 4 2 (onmouseup) - return button === 2 ? 2 : button === 4 ? 1 : 0; - }, - buttons: null, - relatedTarget: function (event) { - return event.relatedTarget || (event.fromElement === event.srcElement ? event.toElement : event.fromElement); - }, - // "Proprietary" Interface. - pageX: function (event) { - return 'pageX' in event ? event.pageX : event.clientX + ViewportMetrics.currentScrollLeft; - }, - pageY: function (event) { - return 'pageY' in event ? event.pageY : event.clientY + ViewportMetrics.currentScrollTop; +if (process.env.NODE_ENV !== 'production') { + if (isProxySupported) { + /*eslint-disable no-func-assign */ + SyntheticEvent = new Proxy(SyntheticEvent, { + construct: function (target, args) { + return this.apply(target, Object.create(target.prototype), args); + }, + apply: function (constructor, that, args) { + return new Proxy(constructor.apply(that, args), { + set: function (target, prop, value) { + if (prop !== 'isPersistent' && !target.constructor.Interface.hasOwnProperty(prop) && shouldBeReleasedProperties.indexOf(prop) === -1) { + process.env.NODE_ENV !== 'production' ? warning(didWarnForAddedNewProperty || target.isPersistent(), "This synthetic event is reused for performance reasons. If you're " + "seeing this, you're adding a new property in the synthetic event object. " + 'The property is never released. See ' + 'https://fb.me/react-event-pooling for more information.') : void 0; + didWarnForAddedNewProperty = true; + } + target[prop] = value; + return true; + } + }); + } + }); + /*eslint-enable no-func-assign */ } -}; - -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticMouseEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); } - -SyntheticUIEvent.augmentClass(SyntheticMouseEvent, MouseEventInterface); - -module.exports = SyntheticMouseEvent; - -/***/ }), -/* 43 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Helper to reduce boilerplate when creating subclasses. * + * @param {function} Class + * @param {?object} Interface */ +SyntheticEvent.augmentClass = function (Class, Interface) { + var Super = this; + var E = function () {}; + E.prototype = Super.prototype; + var prototype = new E(); + _assign(prototype, Class.prototype); + Class.prototype = prototype; + Class.prototype.constructor = Class; -var ExecutionEnvironment = __webpack_require__(8); -var DOMNamespaces = __webpack_require__(56); + Class.Interface = _assign({}, Super.Interface, Interface); + Class.augmentClass = Super.augmentClass; -var WHITESPACE_TEST = /^[ \r\n\t\f]/; -var NONVISIBLE_TEST = /<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/; + PooledClass.addPoolingTo(Class, PooledClass.fourArgumentPooler); +}; -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); +PooledClass.addPoolingTo(SyntheticEvent, PooledClass.fourArgumentPooler); -// SVG temp container for IE lacking innerHTML -var reusableSVGContainer; +module.exports = SyntheticEvent; /** - * Set the innerHTML property of a node, ensuring that whitespace is preserved - * even in IE8. - * - * @param {DOMElement} node - * @param {string} html - * @internal - */ -var setInnerHTML = createMicrosoftUnsafeLocalFunction(function (node, html) { - // IE does not have innerHTML for SVG nodes, so instead we inject the - // new markup in a temp node and then move the child nodes across into - // the target node - if (node.namespaceURI === DOMNamespaces.svg && !('innerHTML' in node)) { - reusableSVGContainer = reusableSVGContainer || document.createElement('div'); - reusableSVGContainer.innerHTML = '<svg>' + html + '</svg>'; - var svgNode = reusableSVGContainer.firstChild; - while (svgNode.firstChild) { - node.appendChild(svgNode.firstChild); - } - } else { - node.innerHTML = html; - } -}); - -if (ExecutionEnvironment.canUseDOM) { - // IE8: When updating a just created node with innerHTML only leading - // whitespace is removed. When updating an existing node with innerHTML - // whitespace in root TextNodes is also collapsed. - // @see quirksmode.org/bugreports/archives/2004/11/innerhtml_and_t.html + * Helper to nullify syntheticEvent instance properties when destructing + * + * @param {object} SyntheticEvent + * @param {String} propName + * @return {object} defineProperty object + */ +function getPooledWarningPropertyDefinition(propName, getVal) { + var isFunction = typeof getVal === 'function'; + return { + configurable: true, + set: set, + get: get + }; - // Feature detection; only IE8 is known to behave improperly like this. - var testElement = document.createElement('div'); - testElement.innerHTML = ' '; - if (testElement.innerHTML === '') { - setInnerHTML = function (node, html) { - // Magic theory: IE8 supposedly differentiates between added and updated - // nodes when processing innerHTML, innerHTML on updated nodes suffers - // from worse whitespace behavior. Re-adding a node like this triggers - // the initial and more favorable whitespace behavior. - // TODO: What to do on a detached node? - if (node.parentNode) { - node.parentNode.replaceChild(node, node); - } + function set(val) { + var action = isFunction ? 'setting the method' : 'setting the property'; + warn(action, 'This is effectively a no-op'); + return val; + } - // We also implement a workaround for non-visible tags disappearing into - // thin air on IE8, this only happens if there is no visible text - // in-front of the non-visible tags. Piggyback on the whitespace fix - // and simply check if any non-visible tags appear in the source. - if (WHITESPACE_TEST.test(html) || html[0] === '<' && NONVISIBLE_TEST.test(html)) { - // Recover leading whitespace by temporarily prepending any character. - // \uFEFF has the potential advantage of being zero-width/invisible. - // UglifyJS drops U+FEFF chars when parsing, so use String.fromCharCode - // in hopes that this is preserved even if "\uFEFF" is transformed to - // the actual Unicode character (by Babel, for example). - // https://github.com/mishoo/UglifyJS2/blob/v2.4.20/lib/parse.js#L216 - node.innerHTML = String.fromCharCode(0xfeff) + html; + function get() { + var action = isFunction ? 'accessing the method' : 'accessing the property'; + var result = isFunction ? 'This is a no-op function' : 'This is set to null'; + warn(action, result); + return getVal; + } - // deleteData leaves an empty `TextNode` which offsets the index of all - // children. Definitely want to avoid this. - var textNode = node.firstChild; - if (textNode.data.length === 1) { - node.removeChild(textNode); - } else { - textNode.deleteData(0, 1); - } - } else { - node.innerHTML = html; - } - }; + function warn(action, result) { + var warningCondition = false; + process.env.NODE_ENV !== 'production' ? warning(warningCondition, "This synthetic event is reused for performance reasons. If you're seeing this, " + "you're %s `%s` on a released/nullified synthetic event. %s. " + 'If you must keep the original synthetic event around, use event.persist(). ' + 'See https://fb.me/react-event-pooling for more information.', action, propName, result) : void 0; } - testElement = null; } - -module.exports = setInnerHTML; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 44 */ +/* 27 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2016-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * Based on the escape-html library, which is used under the MIT License below: - * - * Copyright (c) 2012-2013 TJ Holowaychuk - * Copyright (c) 2015 Andreas Lubbe - * Copyright (c) 2015 Tiancheng "Timothy" Gu - * - * Permission is hereby granted, free of charge, to any person obtaining - * a copy of this software and associated documentation files (the - * 'Software'), to deal in the Software without restriction, including - * without limitation the rights to use, copy, modify, merge, publish, - * distribute, sublicense, and/or sell copies of the Software, and to - * permit persons to whom the Software is furnished to do so, subject to - * the following conditions: - * - * The above copyright notice and this permission notice shall be - * included in all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, - * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. - * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY - * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, - * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE - * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) { +var inherits = __webpack_require__(4) +var md5 = __webpack_require__(63) +var RIPEMD160 = __webpack_require__(97) +var sha = __webpack_require__(103) +var Base = __webpack_require__(29) +function HashNoConstructor (hash) { + Base.call(this, 'digest') -// code copied and modified from escape-html -/** - * Module variables. - * @private - */ + this._hash = hash + this.buffers = [] +} -var matchHtmlRegExp = /["'&<>]/; +inherits(HashNoConstructor, Base) -/** - * Escape special characters in the given string of html. - * - * @param {string} string The string to escape for inserting into HTML - * @return {string} - * @public - */ +HashNoConstructor.prototype._update = function (data) { + this.buffers.push(data) +} -function escapeHtml(string) { - var str = '' + string; - var match = matchHtmlRegExp.exec(str); +HashNoConstructor.prototype._final = function () { + var buf = Buffer.concat(this.buffers) + var r = this._hash(buf) + this.buffers = null - if (!match) { - return str; - } + return r +} - var escape; - var html = ''; - var index = 0; - var lastIndex = 0; +function Hash (hash) { + Base.call(this, 'digest') - for (index = match.index; index < str.length; index++) { - switch (str.charCodeAt(index)) { - case 34: - // " - escape = '"'; - break; - case 38: - // & - escape = '&'; - break; - case 39: - // ' - escape = '''; // modified from escape-html; used to be ''' - break; - case 60: - // < - escape = '<'; - break; - case 62: - // > - escape = '>'; - break; - default: - continue; - } + this._hash = hash +} - if (lastIndex !== index) { - html += str.substring(lastIndex, index); - } +inherits(Hash, Base) - lastIndex = index + 1; - html += escape; - } +Hash.prototype._update = function (data) { + this._hash.update(data) +} - return lastIndex !== index ? html + str.substring(lastIndex, index) : html; +Hash.prototype._final = function () { + return this._hash.digest() } -// end code copied and modified from escape-html -/** - * Escapes text to prevent scripting attacks. - * - * @param {*} text Text value to escape. - * @return {string} An escaped string. - */ -function escapeTextContentForBrowser(text) { - if (typeof text === 'boolean' || typeof text === 'number') { - // this shortcircuit helps perf for types that we know will never have - // special characters, especially given that this function is used often - // for numeric dom ids. - return '' + text; - } - return escapeHtml(text); +module.exports = function createHash (alg) { + alg = alg.toLowerCase() + if (alg === 'md5') return new HashNoConstructor(md5) + if (alg === 'rmd160' || alg === 'ripemd160') return new Hash(new RIPEMD160()) + + return new Hash(sha(alg)) } -module.exports = escapeTextContentForBrowser; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 45 */ +/* 28 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** +/* WEBPACK VAR INJECTION */(function(process) {/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -10555,652 +8480,327 @@ module.exports = escapeTextContentForBrowser; -var _assign = __webpack_require__(5); +var _prodInvariant = __webpack_require__(5); -var EventPluginRegistry = __webpack_require__(40); -var ReactEventEmitterMixin = __webpack_require__(169); -var ViewportMetrics = __webpack_require__(89); +var invariant = __webpack_require__(2); -var getVendorPrefixedEventName = __webpack_require__(170); -var isEventSupported = __webpack_require__(53); +function checkMask(value, bitmask) { + return (value & bitmask) === bitmask; +} -/** - * Summary of `ReactBrowserEventEmitter` event handling: - * - * - Top-level delegation is used to trap most native browser events. This - * may only occur in the main thread and is the responsibility of - * ReactEventListener, which is injected and can therefore support pluggable - * event sources. This is the only work that occurs in the main thread. - * - * - We normalize and de-duplicate events to account for browser quirks. This - * may be done in the worker thread. - * - * - Forward these native events (with the associated top-level type used to - * trap it) to `EventPluginHub`, which in turn will ask plugins if they want - * to extract any synthetic events. - * - * - The `EventPluginHub` will then process each event by annotating them with - * "dispatches", a sequence of listeners and IDs that care about that event. - * - * - The `EventPluginHub` then dispatches the events. - * - * Overview of React and the event system: - * - * +------------+ . - * | DOM | . - * +------------+ . - * | . - * v . - * +------------+ . - * | ReactEvent | . - * | Listener | . - * +------------+ . +-----------+ - * | . +--------+|SimpleEvent| - * | . | |Plugin | - * +-----|------+ . v +-----------+ - * | | | . +--------------+ +------------+ - * | +-----------.--->|EventPluginHub| | Event | - * | | . | | +-----------+ | Propagators| - * | ReactEvent | . | | |TapEvent | |------------| - * | Emitter | . | |<---+|Plugin | |other plugin| - * | | . | | +-----------+ | utilities | - * | +-----------.--->| | +------------+ - * | | | . +--------------+ - * +-----|------+ . ^ +-----------+ - * | . | |Enter/Leave| - * + . +-------+|Plugin | - * +-------------+ . +-----------+ - * | application | . - * |-------------| . - * | | . - * | | . - * +-------------+ . - * . - * React Core . General Purpose Event Plugin System - */ +var DOMPropertyInjection = { + /** + * Mapping from normalized, camelcased property names to a configuration that + * specifies how the associated DOM property should be accessed or rendered. + */ + MUST_USE_PROPERTY: 0x1, + HAS_BOOLEAN_VALUE: 0x4, + HAS_NUMERIC_VALUE: 0x8, + HAS_POSITIVE_NUMERIC_VALUE: 0x10 | 0x8, + HAS_OVERLOADED_BOOLEAN_VALUE: 0x20, -var hasEventPageXY; -var alreadyListeningTo = {}; -var isMonitoringScrollValue = false; -var reactTopListenersCounter = 0; + /** + * Inject some specialized knowledge about the DOM. This takes a config object + * with the following properties: + * + * isCustomAttribute: function that given an attribute name will return true + * if it can be inserted into the DOM verbatim. Useful for data-* or aria-* + * attributes where it's impossible to enumerate all of the possible + * attribute names, + * + * Properties: object mapping DOM property name to one of the + * DOMPropertyInjection constants or null. If your attribute isn't in here, + * it won't get written to the DOM. + * + * DOMAttributeNames: object mapping React attribute name to the DOM + * attribute name. Attribute names not specified use the **lowercase** + * normalized name. + * + * DOMAttributeNamespaces: object mapping React attribute name to the DOM + * attribute namespace URL. (Attribute names not specified use no namespace.) + * + * DOMPropertyNames: similar to DOMAttributeNames but for DOM properties. + * Property names not specified use the normalized name. + * + * DOMMutationMethods: Properties that require special mutation methods. If + * `value` is undefined, the mutation method should unset the property. + * + * @param {object} domPropertyConfig the config as described above. + */ + injectDOMPropertyConfig: function (domPropertyConfig) { + var Injection = DOMPropertyInjection; + var Properties = domPropertyConfig.Properties || {}; + var DOMAttributeNamespaces = domPropertyConfig.DOMAttributeNamespaces || {}; + var DOMAttributeNames = domPropertyConfig.DOMAttributeNames || {}; + var DOMPropertyNames = domPropertyConfig.DOMPropertyNames || {}; + var DOMMutationMethods = domPropertyConfig.DOMMutationMethods || {}; -// For events like 'submit' which don't consistently bubble (which we trap at a -// lower node than `document`), binding at `document` would cause duplicate -// events so we don't include them here -var topEventMapping = { - topAbort: 'abort', - topAnimationEnd: getVendorPrefixedEventName('animationend') || 'animationend', - topAnimationIteration: getVendorPrefixedEventName('animationiteration') || 'animationiteration', - topAnimationStart: getVendorPrefixedEventName('animationstart') || 'animationstart', - topBlur: 'blur', - topCanPlay: 'canplay', - topCanPlayThrough: 'canplaythrough', - topChange: 'change', - topClick: 'click', - topCompositionEnd: 'compositionend', - topCompositionStart: 'compositionstart', - topCompositionUpdate: 'compositionupdate', - topContextMenu: 'contextmenu', - topCopy: 'copy', - topCut: 'cut', - topDoubleClick: 'dblclick', - topDrag: 'drag', - topDragEnd: 'dragend', - topDragEnter: 'dragenter', - topDragExit: 'dragexit', - topDragLeave: 'dragleave', - topDragOver: 'dragover', - topDragStart: 'dragstart', - topDrop: 'drop', - topDurationChange: 'durationchange', - topEmptied: 'emptied', - topEncrypted: 'encrypted', - topEnded: 'ended', - topError: 'error', - topFocus: 'focus', - topInput: 'input', - topKeyDown: 'keydown', - topKeyPress: 'keypress', - topKeyUp: 'keyup', - topLoadedData: 'loadeddata', - topLoadedMetadata: 'loadedmetadata', - topLoadStart: 'loadstart', - topMouseDown: 'mousedown', - topMouseMove: 'mousemove', - topMouseOut: 'mouseout', - topMouseOver: 'mouseover', - topMouseUp: 'mouseup', - topPaste: 'paste', - topPause: 'pause', - topPlay: 'play', - topPlaying: 'playing', - topProgress: 'progress', - topRateChange: 'ratechange', - topScroll: 'scroll', - topSeeked: 'seeked', - topSeeking: 'seeking', - topSelectionChange: 'selectionchange', - topStalled: 'stalled', - topSuspend: 'suspend', - topTextInput: 'textInput', - topTimeUpdate: 'timeupdate', - topTouchCancel: 'touchcancel', - topTouchEnd: 'touchend', - topTouchMove: 'touchmove', - topTouchStart: 'touchstart', - topTransitionEnd: getVendorPrefixedEventName('transitionend') || 'transitionend', - topVolumeChange: 'volumechange', - topWaiting: 'waiting', - topWheel: 'wheel' -}; + if (domPropertyConfig.isCustomAttribute) { + DOMProperty._isCustomAttributeFunctions.push(domPropertyConfig.isCustomAttribute); + } -/** - * To ensure no conflicts with other potential React instances on the page - */ -var topListenersIDKey = '_reactListenersID' + String(Math.random()).slice(2); + for (var propName in Properties) { + !!DOMProperty.properties.hasOwnProperty(propName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'injectDOMPropertyConfig(...): You\'re trying to inject DOM property \'%s\' which has already been injected. You may be accidentally injecting the same DOM property config twice, or you may be injecting two configs that have conflicting property names.', propName) : _prodInvariant('48', propName) : void 0; -function getListeningForDocument(mountAt) { - // In IE8, `mountAt` is a host object and doesn't have `hasOwnProperty` - // directly. - if (!Object.prototype.hasOwnProperty.call(mountAt, topListenersIDKey)) { - mountAt[topListenersIDKey] = reactTopListenersCounter++; - alreadyListeningTo[mountAt[topListenersIDKey]] = {}; + var lowerCased = propName.toLowerCase(); + var propConfig = Properties[propName]; + + var propertyInfo = { + attributeName: lowerCased, + attributeNamespace: null, + propertyName: propName, + mutationMethod: null, + + mustUseProperty: checkMask(propConfig, Injection.MUST_USE_PROPERTY), + hasBooleanValue: checkMask(propConfig, Injection.HAS_BOOLEAN_VALUE), + hasNumericValue: checkMask(propConfig, Injection.HAS_NUMERIC_VALUE), + hasPositiveNumericValue: checkMask(propConfig, Injection.HAS_POSITIVE_NUMERIC_VALUE), + hasOverloadedBooleanValue: checkMask(propConfig, Injection.HAS_OVERLOADED_BOOLEAN_VALUE) + }; + !(propertyInfo.hasBooleanValue + propertyInfo.hasNumericValue + propertyInfo.hasOverloadedBooleanValue <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'DOMProperty: Value can be one of boolean, overloaded boolean, or numeric value, but not a combination: %s', propName) : _prodInvariant('50', propName) : void 0; + + if (process.env.NODE_ENV !== 'production') { + DOMProperty.getPossibleStandardName[lowerCased] = propName; + } + + if (DOMAttributeNames.hasOwnProperty(propName)) { + var attributeName = DOMAttributeNames[propName]; + propertyInfo.attributeName = attributeName; + if (process.env.NODE_ENV !== 'production') { + DOMProperty.getPossibleStandardName[attributeName] = propName; + } + } + + if (DOMAttributeNamespaces.hasOwnProperty(propName)) { + propertyInfo.attributeNamespace = DOMAttributeNamespaces[propName]; + } + + if (DOMPropertyNames.hasOwnProperty(propName)) { + propertyInfo.propertyName = DOMPropertyNames[propName]; + } + + if (DOMMutationMethods.hasOwnProperty(propName)) { + propertyInfo.mutationMethod = DOMMutationMethods[propName]; + } + + DOMProperty.properties[propName] = propertyInfo; + } } - return alreadyListeningTo[mountAt[topListenersIDKey]]; -} +}; + +/* eslint-disable max-len */ +var ATTRIBUTE_NAME_START_CHAR = ':A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD'; +/* eslint-enable max-len */ /** - * `ReactBrowserEventEmitter` is used to attach top-level event listeners. For - * example: + * DOMProperty exports lookup objects that can be used like functions: * - * EventPluginHub.putListener('myID', 'onClick', myFunction); + * > DOMProperty.isValid['id'] + * true + * > DOMProperty.isValid['foobar'] + * undefined * - * This would allocate a "registration" of `('onClick', myFunction)` on 'myID'. + * Although this may be confusing, it performs better in general. * - * @internal + * @see http://jsperf.com/key-exists + * @see http://jsperf.com/key-missing */ -var ReactBrowserEventEmitter = _assign({}, ReactEventEmitterMixin, { - /** - * Injectable event backend - */ - ReactEventListener: null, +var DOMProperty = { + ID_ATTRIBUTE_NAME: 'data-reactid', + ROOT_ATTRIBUTE_NAME: 'data-reactroot', - injection: { - /** - * @param {object} ReactEventListener - */ - injectReactEventListener: function (ReactEventListener) { - ReactEventListener.setHandleTopLevel(ReactBrowserEventEmitter.handleTopLevel); - ReactBrowserEventEmitter.ReactEventListener = ReactEventListener; - } - }, + ATTRIBUTE_NAME_START_CHAR: ATTRIBUTE_NAME_START_CHAR, + ATTRIBUTE_NAME_CHAR: ATTRIBUTE_NAME_START_CHAR + '\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040', /** - * Sets whether or not any created callbacks should be enabled. + * Map from property "standard name" to an object with info about how to set + * the property in the DOM. Each object contains: * - * @param {boolean} enabled True if callbacks should be enabled. - */ - setEnabled: function (enabled) { - if (ReactBrowserEventEmitter.ReactEventListener) { - ReactBrowserEventEmitter.ReactEventListener.setEnabled(enabled); - } - }, - - /** - * @return {boolean} True if callbacks are enabled. + * attributeName: + * Used when rendering markup or with `*Attribute()`. + * attributeNamespace + * propertyName: + * Used on DOM node instances. (This includes properties that mutate due to + * external factors.) + * mutationMethod: + * If non-null, used instead of the property or `setAttribute()` after + * initial render. + * mustUseProperty: + * Whether the property must be accessed and mutated as an object property. + * hasBooleanValue: + * Whether the property should be removed when set to a falsey value. + * hasNumericValue: + * Whether the property must be numeric or parse as a numeric and should be + * removed when set to a falsey value. + * hasPositiveNumericValue: + * Whether the property must be positive numeric or parse as a positive + * numeric and should be removed when set to a falsey value. + * hasOverloadedBooleanValue: + * Whether the property can be used as a flag as well as with a value. + * Removed when strictly equal to false; present without a value when + * strictly equal to true; present with a value otherwise. */ - isEnabled: function () { - return !!(ReactBrowserEventEmitter.ReactEventListener && ReactBrowserEventEmitter.ReactEventListener.isEnabled()); - }, + properties: {}, /** - * We listen for bubbled touch events on the document object. - * - * Firefox v8.01 (and possibly others) exhibited strange behavior when - * mounting `onmousemove` events at some node that was not the document - * element. The symptoms were that if your mouse is not moving over something - * contained within that mount point (for example on the background) the - * top-level listeners for `onmousemove` won't be called. However, if you - * register the `mousemove` on the document object, then it will of course - * catch all `mousemove`s. This along with iOS quirks, justifies restricting - * top-level listeners to the document object only, at least for these - * movement types of events and possibly all events. - * - * @see http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html + * Mapping from lowercase property names to the properly cased version, used + * to warn in the case of missing properties. Available only in __DEV__. * - * Also, `keyup`/`keypress`/`keydown` do not bubble to the window on IE, but - * they bubble to document. + * autofocus is predefined, because adding it to the property whitelist + * causes unintended side effects. * - * @param {string} registrationName Name of listener (e.g. `onClick`). - * @param {object} contentDocumentHandle Document which owns the container + * @type {Object} */ - listenTo: function (registrationName, contentDocumentHandle) { - var mountAt = contentDocumentHandle; - var isListening = getListeningForDocument(mountAt); - var dependencies = EventPluginRegistry.registrationNameDependencies[registrationName]; - - for (var i = 0; i < dependencies.length; i++) { - var dependency = dependencies[i]; - if (!(isListening.hasOwnProperty(dependency) && isListening[dependency])) { - if (dependency === 'topWheel') { - if (isEventSupported('wheel')) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'wheel', mountAt); - } else if (isEventSupported('mousewheel')) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'mousewheel', mountAt); - } else { - // Firefox needs to capture a different mouse scroll event. - // @see http://www.quirksmode.org/dom/events/tests/scroll.html - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'DOMMouseScroll', mountAt); - } - } else if (dependency === 'topScroll') { - if (isEventSupported('scroll', true)) { - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topScroll', 'scroll', mountAt); - } else { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topScroll', 'scroll', ReactBrowserEventEmitter.ReactEventListener.WINDOW_HANDLE); - } - } else if (dependency === 'topFocus' || dependency === 'topBlur') { - if (isEventSupported('focus', true)) { - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topFocus', 'focus', mountAt); - ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topBlur', 'blur', mountAt); - } else if (isEventSupported('focusin')) { - // IE has `focusin` and `focusout` events which bubble. - // @see http://www.quirksmode.org/blog/archives/2008/04/delegating_the.html - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topFocus', 'focusin', mountAt); - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topBlur', 'focusout', mountAt); - } - - // to make sure blur and focus event listeners are only attached once - isListening.topBlur = true; - isListening.topFocus = true; - } else if (topEventMapping.hasOwnProperty(dependency)) { - ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(dependency, topEventMapping[dependency], mountAt); - } - - isListening[dependency] = true; - } - } - }, - - trapBubbledEvent: function (topLevelType, handlerBaseName, handle) { - return ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(topLevelType, handlerBaseName, handle); - }, - - trapCapturedEvent: function (topLevelType, handlerBaseName, handle) { - return ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent(topLevelType, handlerBaseName, handle); - }, + getPossibleStandardName: process.env.NODE_ENV !== 'production' ? { autofocus: 'autoFocus' } : null, /** - * Protect against document.createEvent() returning null - * Some popup blocker extensions appear to do this: - * https://github.com/facebook/react/issues/6887 + * All of the isCustomAttribute() functions that have been injected. */ - supportsEventPageXY: function () { - if (!document.createEvent) { - return false; - } - var ev = document.createEvent('MouseEvent'); - return ev != null && 'pageX' in ev; - }, + _isCustomAttributeFunctions: [], /** - * Listens to window scroll and resize events. We cache scroll values so that - * application code can access them without triggering reflows. - * - * ViewportMetrics is only used by SyntheticMouse/TouchEvent and only when - * pageX/pageY isn't supported (legacy browsers). - * - * NOTE: Scroll events do not bubble. - * - * @see http://www.quirksmode.org/dom/events/scroll.html + * Checks whether a property name is a custom attribute. + * @method */ - ensureScrollValueMonitoring: function () { - if (hasEventPageXY === undefined) { - hasEventPageXY = ReactBrowserEventEmitter.supportsEventPageXY(); - } - if (!hasEventPageXY && !isMonitoringScrollValue) { - var refresh = ViewportMetrics.refreshScrollValues; - ReactBrowserEventEmitter.ReactEventListener.monitorScrollValue(refresh); - isMonitoringScrollValue = true; + isCustomAttribute: function (attributeName) { + for (var i = 0; i < DOMProperty._isCustomAttributeFunctions.length; i++) { + var isCustomAttributeFn = DOMProperty._isCustomAttributeFunctions[i]; + if (isCustomAttributeFn(attributeName)) { + return true; + } } - } -}); + return false; + }, -module.exports = ReactBrowserEventEmitter; + injection: DOMPropertyInjection +}; + +module.exports = DOMProperty; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 46 */ +/* 29 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +var Buffer = __webpack_require__(7).Buffer +var Transform = __webpack_require__(98).Transform +var StringDecoder = __webpack_require__(102).StringDecoder +var inherits = __webpack_require__(4) +function CipherBase (hashMode) { + Transform.call(this) + this.hashMode = typeof hashMode === 'string' + if (this.hashMode) { + this[hashMode] = this._finalOrDigest + } else { + this.final = this._finalOrDigest + } + if (this._final) { + this.__final = this._final + this._final = null + } + this._decoder = null + this._encoding = null +} +inherits(CipherBase, Transform) -var bind = __webpack_require__(301); -var isBuffer = __webpack_require__(402); +CipherBase.prototype.update = function (data, inputEnc, outputEnc) { + if (typeof data === 'string') { + data = Buffer.from(data, inputEnc) + } -/*global toString:true*/ + var outData = this._update(data) + if (this.hashMode) return this -// utils is a library of generic helper functions non-specific to axios + if (outputEnc) { + outData = this._toString(outData, outputEnc) + } -var toString = Object.prototype.toString; + return outData +} -/** - * Determine if a value is an Array - * - * @param {Object} val The value to test - * @returns {boolean} True if value is an Array, otherwise false - */ -function isArray(val) { - return toString.call(val) === '[object Array]'; +CipherBase.prototype.setAutoPadding = function () {} +CipherBase.prototype.getAuthTag = function () { + throw new Error('trying to get auth tag in unsupported state') } -/** - * Determine if a value is an ArrayBuffer - * - * @param {Object} val The value to test - * @returns {boolean} True if value is an ArrayBuffer, otherwise false - */ -function isArrayBuffer(val) { - return toString.call(val) === '[object ArrayBuffer]'; +CipherBase.prototype.setAuthTag = function () { + throw new Error('trying to set auth tag in unsupported state') } -/** - * Determine if a value is a FormData - * - * @param {Object} val The value to test - * @returns {boolean} True if value is an FormData, otherwise false - */ -function isFormData(val) { - return (typeof FormData !== 'undefined') && (val instanceof FormData); +CipherBase.prototype.setAAD = function () { + throw new Error('trying to set aad in unsupported state') } -/** - * Determine if a value is a view on an ArrayBuffer - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false - */ -function isArrayBufferView(val) { - var result; - if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) { - result = ArrayBuffer.isView(val); - } else { - result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer); +CipherBase.prototype._transform = function (data, _, next) { + var err + try { + if (this.hashMode) { + this._update(data) + } else { + this.push(this._update(data)) + } + } catch (e) { + err = e + } finally { + next(err) } - return result; } +CipherBase.prototype._flush = function (done) { + var err + try { + this.push(this.__final()) + } catch (e) { + err = e + } -/** - * Determine if a value is a String - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a String, otherwise false - */ -function isString(val) { - return typeof val === 'string'; -} - -/** - * Determine if a value is a Number - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a Number, otherwise false - */ -function isNumber(val) { - return typeof val === 'number'; -} - -/** - * Determine if a value is undefined - * - * @param {Object} val The value to test - * @returns {boolean} True if the value is undefined, otherwise false - */ -function isUndefined(val) { - return typeof val === 'undefined'; -} - -/** - * Determine if a value is an Object - * - * @param {Object} val The value to test - * @returns {boolean} True if value is an Object, otherwise false - */ -function isObject(val) { - return val !== null && typeof val === 'object'; -} - -/** - * Determine if a value is a Date - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a Date, otherwise false - */ -function isDate(val) { - return toString.call(val) === '[object Date]'; -} - -/** - * Determine if a value is a File - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a File, otherwise false - */ -function isFile(val) { - return toString.call(val) === '[object File]'; -} - -/** - * Determine if a value is a Blob - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a Blob, otherwise false - */ -function isBlob(val) { - return toString.call(val) === '[object Blob]'; -} - -/** - * Determine if a value is a Function - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a Function, otherwise false - */ -function isFunction(val) { - return toString.call(val) === '[object Function]'; -} - -/** - * Determine if a value is a Stream - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a Stream, otherwise false - */ -function isStream(val) { - return isObject(val) && isFunction(val.pipe); -} - -/** - * Determine if a value is a URLSearchParams object - * - * @param {Object} val The value to test - * @returns {boolean} True if value is a URLSearchParams object, otherwise false - */ -function isURLSearchParams(val) { - return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams; -} - -/** - * Trim excess whitespace off the beginning and end of a string - * - * @param {String} str The String to trim - * @returns {String} The String freed of excess whitespace - */ -function trim(str) { - return str.replace(/^\s*/, '').replace(/\s*$/, ''); + done(err) } - -/** - * Determine if we're running in a standard browser environment - * - * This allows axios to run in a web worker, and react-native. - * Both environments support XMLHttpRequest, but not fully standard globals. - * - * web workers: - * typeof window -> undefined - * typeof document -> undefined - * - * react-native: - * navigator.product -> 'ReactNative' - */ -function isStandardBrowserEnv() { - if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') { - return false; +CipherBase.prototype._finalOrDigest = function (outputEnc) { + var outData = this.__final() || Buffer.alloc(0) + if (outputEnc) { + outData = this._toString(outData, outputEnc, true) } - return ( - typeof window !== 'undefined' && - typeof document !== 'undefined' - ); + return outData } -/** - * Iterate over an Array or an Object invoking a function for each item. - * - * If `obj` is an Array callback will be called passing - * the value, index, and complete array for each item. - * - * If 'obj' is an Object callback will be called passing - * the value, key, and complete object for each property. - * - * @param {Object|Array} obj The object to iterate - * @param {Function} fn The callback to invoke for each item - */ -function forEach(obj, fn) { - // Don't bother if no value provided - if (obj === null || typeof obj === 'undefined') { - return; - } - - // Force an array if not already something iterable - if (typeof obj !== 'object' && !isArray(obj)) { - /*eslint no-param-reassign:0*/ - obj = [obj]; - } - - if (isArray(obj)) { - // Iterate over array values - for (var i = 0, l = obj.length; i < l; i++) { - fn.call(null, obj[i], i, obj); - } - } else { - // Iterate over object keys - for (var key in obj) { - if (Object.prototype.hasOwnProperty.call(obj, key)) { - fn.call(null, obj[key], key, obj); - } - } +CipherBase.prototype._toString = function (value, enc, fin) { + if (!this._decoder) { + this._decoder = new StringDecoder(enc) + this._encoding = enc } -} -/** - * Accepts varargs expecting each argument to be an object, then - * immutably merges the properties of each object and returns result. - * - * When multiple objects contain the same key the later object in - * the arguments list will take precedence. - * - * Example: - * - * ```js - * var result = merge({foo: 123}, {foo: 456}); - * console.log(result.foo); // outputs 456 - * ``` - * - * @param {Object} obj1 Object to merge - * @returns {Object} Result of all merge properties - */ -function merge(/* obj1, obj2, obj3, ... */) { - var result = {}; - function assignValue(val, key) { - if (typeof result[key] === 'object' && typeof val === 'object') { - result[key] = merge(result[key], val); - } else { - result[key] = val; - } - } + if (this._encoding !== enc) throw new Error('can\'t switch encodings') - for (var i = 0, l = arguments.length; i < l; i++) { - forEach(arguments[i], assignValue); + var out = this._decoder.write(value) + if (fin) { + out += this._decoder.end() } - return result; -} -/** - * Extends object a by mutably adding to it the properties of object b. - * - * @param {Object} a The object to be extended - * @param {Object} b The object to copy properties from - * @param {Object} thisArg The object to bind function to - * @return {Object} The resulting value of object a - */ -function extend(a, b, thisArg) { - forEach(b, function assignValue(val, key) { - if (thisArg && typeof val === 'function') { - a[key] = bind(val, thisArg); - } else { - a[key] = val; - } - }); - return a; + return out } -module.exports = { - isArray: isArray, - isArrayBuffer: isArrayBuffer, - isBuffer: isBuffer, - isFormData: isFormData, - isArrayBufferView: isArrayBufferView, - isString: isString, - isNumber: isNumber, - isObject: isObject, - isUndefined: isUndefined, - isDate: isDate, - isFile: isFile, - isBlob: isBlob, - isFunction: isFunction, - isStream: isStream, - isURLSearchParams: isURLSearchParams, - isStandardBrowserEnv: isStandardBrowserEnv, - forEach: forEach, - merge: merge, - extend: extend, - trim: trim -}; +module.exports = CipherBase /***/ }), -/* 47 */ -/***/ (function(module, exports) { - -module.exports = assert; +/* 30 */ +/***/ (function(module, exports, __webpack_require__) { -function assert(val, msg) { - if (!val) - throw new Error(msg || 'Assertion failed'); -} +var BigInteger = __webpack_require__(175) -assert.equal = function assertEqual(l, r, msg) { - if (l != r) - throw new Error(msg || ('Assertion failed: ' + l + ' != ' + r)); -}; +//addons +__webpack_require__(408) +module.exports = BigInteger /***/ }), -/* 48 */ +/* 31 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. + * Copyright 2014-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -11211,315 +8811,338 @@ assert.equal = function assertEqual(l, r, msg) { -/** - * Forked from fbjs/warning: - * https://github.com/facebook/fbjs/blob/e66ba20ad5be433eb54423f2b097d829324d9de6/packages/fbjs/src/__forks__/warning.js - * - * Only change is we use console.warn instead of console.error, - * and do nothing when 'console' is not supported. - * This really simplifies the code. - * --- - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ +var _assign = __webpack_require__(8); -var lowPriorityWarning = function () {}; +var ReactCurrentOwner = __webpack_require__(22); -if (process.env.NODE_ENV !== 'production') { - var printWarning = function (format) { - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; - } +var warning = __webpack_require__(3); +var canDefineProperty = __webpack_require__(55); +var hasOwnProperty = Object.prototype.hasOwnProperty; - var argIndex = 0; - var message = 'Warning: ' + format.replace(/%s/g, function () { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.warn(message); - } - try { - // --- Welcome to debugging React --- - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch (x) {} - }; +var REACT_ELEMENT_TYPE = __webpack_require__(121); - lowPriorityWarning = function (condition, format) { - if (format === undefined) { - throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); +var RESERVED_PROPS = { + key: true, + ref: true, + __self: true, + __source: true +}; + +var specialPropKeyWarningShown, specialPropRefWarningShown; + +function hasValidRef(config) { + if (process.env.NODE_ENV !== 'production') { + if (hasOwnProperty.call(config, 'ref')) { + var getter = Object.getOwnPropertyDescriptor(config, 'ref').get; + if (getter && getter.isReactWarning) { + return false; + } } - if (!condition) { - for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { - args[_key2 - 2] = arguments[_key2]; + } + return config.ref !== undefined; +} + +function hasValidKey(config) { + if (process.env.NODE_ENV !== 'production') { + if (hasOwnProperty.call(config, 'key')) { + var getter = Object.getOwnPropertyDescriptor(config, 'key').get; + if (getter && getter.isReactWarning) { + return false; } + } + } + return config.key !== undefined; +} - printWarning.apply(undefined, [format].concat(args)); +function defineKeyPropWarningGetter(props, displayName) { + var warnAboutAccessingKey = function () { + if (!specialPropKeyWarningShown) { + specialPropKeyWarningShown = true; + process.env.NODE_ENV !== 'production' ? warning(false, '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; } }; + warnAboutAccessingKey.isReactWarning = true; + Object.defineProperty(props, 'key', { + get: warnAboutAccessingKey, + configurable: true + }); } -module.exports = lowPriorityWarning; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 49 */ -/***/ (function(module, exports, __webpack_require__) { +function defineRefPropWarningGetter(props, displayName) { + var warnAboutAccessingRef = function () { + if (!specialPropRefWarningShown) { + specialPropRefWarningShown = true; + process.env.NODE_ENV !== 'production' ? warning(false, '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName) : void 0; + } + }; + warnAboutAccessingRef.isReactWarning = true; + Object.defineProperty(props, 'ref', { + get: warnAboutAccessingRef, + configurable: true + }); +} -"use strict"; /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. + * Factory method to create a new React element. This no longer adheres to + * the class pattern, so do not use new to call it. Also, no instanceof check + * will work. Instead test $$typeof field against Symbol.for('react.element') to check + * if something is a React Element. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * @param {*} type + * @param {*} key + * @param {string|object} ref + * @param {*} self A *temporary* helper to detect places where `this` is + * different from the `owner` when React.createElement is called, so that we + * can warn. We want to get rid of owner and replace string `ref`s with arrow + * functions, and as long as `this` and owner are the same, there will be no + * change in behavior. + * @param {*} source An annotation object (added by a transpiler or otherwise) + * indicating filename, line number, and/or other information. + * @param {*} owner + * @param {*} props + * @internal */ +var ReactElement = function (type, key, ref, self, source, owner, props) { + var element = { + // This tag allow us to uniquely identify this as a React Element + $$typeof: REACT_ELEMENT_TYPE, + // Built-in properties that belong on the element + type: type, + key: key, + ref: ref, + props: props, + // Record the component responsible for creating this element. + _owner: owner + }; -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; - -module.exports = ReactPropTypesSecret; + if (process.env.NODE_ENV !== 'production') { + // The validation flag is currently mutative. We put it on + // an external backing store so that we can freeze the whole object. + // This can be replaced with a WeakMap once they are implemented in + // commonly used development environments. + element._store = {}; + // To make comparing ReactElements easier for testing purposes, we make + // the validation flag non-enumerable (where possible, which should + // include every environment we run tests in), so the test framework + // ignores it. + if (canDefineProperty) { + Object.defineProperty(element._store, 'validated', { + configurable: false, + enumerable: false, + writable: true, + value: false + }); + // self and source are DEV only properties. + Object.defineProperty(element, '_self', { + configurable: false, + enumerable: false, + writable: false, + value: self + }); + // Two elements created in two different places should be considered + // equal for testing purposes and therefore we hide it from enumeration. + Object.defineProperty(element, '_source', { + configurable: false, + enumerable: false, + writable: false, + value: source + }); + } else { + element._store.validated = false; + element._self = self; + element._source = source; + } + if (Object.freeze) { + Object.freeze(element.props); + Object.freeze(element); + } + } -/***/ }), -/* 50 */ -/***/ (function(module, exports, __webpack_require__) { + return element; +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * +/** + * Create and return a new ReactElement of the given type. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createelement */ +ReactElement.createElement = function (type, config, children) { + var propName; + // Reserved names are extracted + var props = {}; + var key = null; + var ref = null; + var self = null; + var source = null; -var _prodInvariant = __webpack_require__(3); - -var ReactErrorUtils = __webpack_require__(51); - -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); - -/** - * Injected dependencies: - */ - -/** - * - `ComponentTree`: [required] Module that can convert between React instances - * and actual node references. - */ -var ComponentTree; -var TreeTraversal; -var injection = { - injectComponentTree: function (Injected) { - ComponentTree = Injected; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.getNodeFromInstance && Injected.getInstanceFromNode, 'EventPluginUtils.injection.injectComponentTree(...): Injected ' + 'module is missing getNodeFromInstance or getInstanceFromNode.') : void 0; + if (config != null) { + if (hasValidRef(config)) { + ref = config.ref; } - }, - injectTreeTraversal: function (Injected) { - TreeTraversal = Injected; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.isAncestor && Injected.getLowestCommonAncestor, 'EventPluginUtils.injection.injectTreeTraversal(...): Injected ' + 'module is missing isAncestor or getLowestCommonAncestor.') : void 0; + if (hasValidKey(config)) { + key = '' + config.key; + } + + self = config.__self === undefined ? null : config.__self; + source = config.__source === undefined ? null : config.__source; + // Remaining properties are added to a new props object + for (propName in config) { + if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { + props[propName] = config[propName]; + } } } -}; -function isEndish(topLevelType) { - return topLevelType === 'topMouseUp' || topLevelType === 'topTouchEnd' || topLevelType === 'topTouchCancel'; -} - -function isMoveish(topLevelType) { - return topLevelType === 'topMouseMove' || topLevelType === 'topTouchMove'; -} -function isStartish(topLevelType) { - return topLevelType === 'topMouseDown' || topLevelType === 'topTouchStart'; -} - -var validateEventDispatches; -if (process.env.NODE_ENV !== 'production') { - validateEventDispatches = function (event) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; - - var listenersIsArr = Array.isArray(dispatchListeners); - var listenersLen = listenersIsArr ? dispatchListeners.length : dispatchListeners ? 1 : 0; - - var instancesIsArr = Array.isArray(dispatchInstances); - var instancesLen = instancesIsArr ? dispatchInstances.length : dispatchInstances ? 1 : 0; - - process.env.NODE_ENV !== 'production' ? warning(instancesIsArr === listenersIsArr && instancesLen === listenersLen, 'EventPluginUtils: Invalid `event`.') : void 0; - }; -} - -/** - * Dispatch the event to the listener. - * @param {SyntheticEvent} event SyntheticEvent to handle - * @param {boolean} simulated If the event is simulated (changes exn behavior) - * @param {function} listener Application-level callback - * @param {*} inst Internal component instance - */ -function executeDispatch(event, simulated, listener, inst) { - var type = event.type || 'unknown-event'; - event.currentTarget = EventPluginUtils.getNodeFromInstance(inst); - if (simulated) { - ReactErrorUtils.invokeGuardedCallbackWithCatch(type, listener, event); - } else { - ReactErrorUtils.invokeGuardedCallback(type, listener, event); + // Children can be more than one argument, and those are transferred onto + // the newly allocated props object. + var childrenLength = arguments.length - 2; + if (childrenLength === 1) { + props.children = children; + } else if (childrenLength > 1) { + var childArray = Array(childrenLength); + for (var i = 0; i < childrenLength; i++) { + childArray[i] = arguments[i + 2]; + } + if (process.env.NODE_ENV !== 'production') { + if (Object.freeze) { + Object.freeze(childArray); + } + } + props.children = childArray; } - event.currentTarget = null; -} -/** - * Standard/simple iteration through an event's collected dispatches. - */ -function executeDispatchesInOrder(event, simulated) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; - if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - if (Array.isArray(dispatchListeners)) { - for (var i = 0; i < dispatchListeners.length; i++) { - if (event.isPropagationStopped()) { - break; + // Resolve default props + if (type && type.defaultProps) { + var defaultProps = type.defaultProps; + for (propName in defaultProps) { + if (props[propName] === undefined) { + props[propName] = defaultProps[propName]; } - // Listeners and Instances are two parallel arrays that are always in sync. - executeDispatch(event, simulated, dispatchListeners[i], dispatchInstances[i]); } - } else if (dispatchListeners) { - executeDispatch(event, simulated, dispatchListeners, dispatchInstances); } - event._dispatchListeners = null; - event._dispatchInstances = null; -} - -/** - * Standard/simple iteration through an event's collected dispatches, but stops - * at the first dispatch execution returning true, and returns that id. - * - * @return {?string} id of the first dispatch execution who's listener returns - * true, or null if no listener returned true. - */ -function executeDispatchesInOrderStopAtTrueImpl(event) { - var dispatchListeners = event._dispatchListeners; - var dispatchInstances = event._dispatchInstances; if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - if (Array.isArray(dispatchListeners)) { - for (var i = 0; i < dispatchListeners.length; i++) { - if (event.isPropagationStopped()) { - break; - } - // Listeners and Instances are two parallel arrays that are always in sync. - if (dispatchListeners[i](event, dispatchInstances[i])) { - return dispatchInstances[i]; + if (key || ref) { + if (typeof props.$$typeof === 'undefined' || props.$$typeof !== REACT_ELEMENT_TYPE) { + var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type; + if (key) { + defineKeyPropWarningGetter(props, displayName); + } + if (ref) { + defineRefPropWarningGetter(props, displayName); + } } } - } else if (dispatchListeners) { - if (dispatchListeners(event, dispatchInstances)) { - return dispatchInstances; - } } - return null; -} + return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props); +}; /** - * @see executeDispatchesInOrderStopAtTrueImpl + * Return a function that produces ReactElements of a given type. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createfactory */ -function executeDispatchesInOrderStopAtTrue(event) { - var ret = executeDispatchesInOrderStopAtTrueImpl(event); - event._dispatchInstances = null; - event._dispatchListeners = null; - return ret; -} +ReactElement.createFactory = function (type) { + var factory = ReactElement.createElement.bind(null, type); + // Expose the type on the factory and the prototype so that it can be + // easily accessed on elements. E.g. `<Foo />.type === Foo`. + // This should not be named `constructor` since this may not be the function + // that created the element, and it may not even be a constructor. + // Legacy hook TODO: Warn if this is accessed + factory.type = type; + return factory; +}; -/** - * Execution of a "direct" dispatch - there must be at most one dispatch - * accumulated on the event or it is considered an error. It doesn't really make - * sense for an event with multiple dispatches (bubbled) to keep track of the - * return values at each dispatch execution, but it does tend to make sense when - * dealing with "direct" dispatches. - * - * @return {*} The return value of executing the single dispatch. - */ -function executeDirectDispatch(event) { - if (process.env.NODE_ENV !== 'production') { - validateEventDispatches(event); - } - var dispatchListener = event._dispatchListeners; - var dispatchInstance = event._dispatchInstances; - !!Array.isArray(dispatchListener) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'executeDirectDispatch(...): Invalid `event`.') : _prodInvariant('103') : void 0; - event.currentTarget = dispatchListener ? EventPluginUtils.getNodeFromInstance(dispatchInstance) : null; - var res = dispatchListener ? dispatchListener(event) : null; - event.currentTarget = null; - event._dispatchListeners = null; - event._dispatchInstances = null; - return res; -} +ReactElement.cloneAndReplaceKey = function (oldElement, newKey) { + var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props); -/** - * @param {SyntheticEvent} event - * @return {boolean} True iff number of dispatches accumulated is greater than 0. - */ -function hasDispatches(event) { - return !!event._dispatchListeners; -} + return newElement; +}; /** - * General utilities that are useful in creating custom Event Plugins. + * Clone and return a new ReactElement using element as the starting point. + * See https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement */ -var EventPluginUtils = { - isEndish: isEndish, - isMoveish: isMoveish, - isStartish: isStartish, +ReactElement.cloneElement = function (element, config, children) { + var propName; - executeDirectDispatch: executeDirectDispatch, - executeDispatchesInOrder: executeDispatchesInOrder, - executeDispatchesInOrderStopAtTrue: executeDispatchesInOrderStopAtTrue, - hasDispatches: hasDispatches, + // Original props are copied + var props = _assign({}, element.props); - getInstanceFromNode: function (node) { - return ComponentTree.getInstanceFromNode(node); - }, - getNodeFromInstance: function (node) { - return ComponentTree.getNodeFromInstance(node); - }, - isAncestor: function (a, b) { - return TreeTraversal.isAncestor(a, b); - }, - getLowestCommonAncestor: function (a, b) { - return TreeTraversal.getLowestCommonAncestor(a, b); - }, - getParentInstance: function (inst) { - return TreeTraversal.getParentInstance(inst); - }, - traverseTwoPhase: function (target, fn, arg) { - return TreeTraversal.traverseTwoPhase(target, fn, arg); - }, - traverseEnterLeave: function (from, to, fn, argFrom, argTo) { - return TreeTraversal.traverseEnterLeave(from, to, fn, argFrom, argTo); - }, + // Reserved names are extracted + var key = element.key; + var ref = element.ref; + // Self is preserved since the owner is preserved. + var self = element._self; + // Source is preserved since cloneElement is unlikely to be targeted by a + // transpiler, and the original source is probably a better indicator of the + // true owner. + var source = element._source; - injection: injection + // Owner will be preserved, unless ref is overridden + var owner = element._owner; + + if (config != null) { + if (hasValidRef(config)) { + // Silently steal the ref from the parent. + ref = config.ref; + owner = ReactCurrentOwner.current; + } + if (hasValidKey(config)) { + key = '' + config.key; + } + + // Remaining properties override existing props + var defaultProps; + if (element.type && element.type.defaultProps) { + defaultProps = element.type.defaultProps; + } + for (propName in config) { + if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { + if (config[propName] === undefined && defaultProps !== undefined) { + // Resolve default props + props[propName] = defaultProps[propName]; + } else { + props[propName] = config[propName]; + } + } + } + } + + // Children can be more than one argument, and those are transferred onto + // the newly allocated props object. + var childrenLength = arguments.length - 2; + if (childrenLength === 1) { + props.children = children; + } else if (childrenLength > 1) { + var childArray = Array(childrenLength); + for (var i = 0; i < childrenLength; i++) { + childArray[i] = arguments[i + 2]; + } + props.children = childArray; + } + + return ReactElement(element.type, key, ref, self, source, owner, props); }; -module.exports = EventPluginUtils; +/** + * Verifies the object is a ReactElement. + * See https://facebook.github.io/react/docs/top-level-api.html#react.isvalidelement + * @param {?object} object + * @return {boolean} True if `object` is a valid component. + * @final + */ +ReactElement.isValidElement = function (object) { + return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE; +}; + +module.exports = ReactElement; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 51 */ +/* 32 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -11536,519 +9159,364 @@ module.exports = EventPluginUtils; -var caughtError = null; +var _prodInvariant = __webpack_require__(5); + +var invariant = __webpack_require__(2); /** - * Call a function while guarding against errors that happens within it. - * - * @param {String} name of the guard to use for logging or debugging - * @param {Function} func The function to invoke - * @param {*} a First argument - * @param {*} b Second argument + * Static poolers. Several custom versions for each potential number of + * arguments. A completely generic pooler is easy to implement, but would + * require accessing the `arguments` object. In each of these, `this` refers to + * the Class itself, not an instance. If any others are needed, simply add them + * here, or in their own files. */ -function invokeGuardedCallback(name, func, a) { - try { - func(a); - } catch (x) { - if (caughtError === null) { - caughtError = x; - } +var oneArgumentPooler = function (copyFieldsFrom) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, copyFieldsFrom); + return instance; + } else { + return new Klass(copyFieldsFrom); } -} - -var ReactErrorUtils = { - invokeGuardedCallback: invokeGuardedCallback, - - /** - * Invoked by ReactTestUtils.Simulate so that any errors thrown by the event - * handler are sure to be rethrown by rethrowCaughtError. - */ - invokeGuardedCallbackWithCatch: invokeGuardedCallback, +}; - /** - * During execution of guarded functions we will capture the first error which - * we will rethrow to be handled by the top level error handler. - */ - rethrowCaughtError: function () { - if (caughtError) { - var error = caughtError; - caughtError = null; - throw error; - } +var twoArgumentPooler = function (a1, a2) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2); + return instance; + } else { + return new Klass(a1, a2); } }; -if (process.env.NODE_ENV !== 'production') { - /** - * To help development we can get better devtools integration by simulating a - * real browser event. - */ - if (typeof window !== 'undefined' && typeof window.dispatchEvent === 'function' && typeof document !== 'undefined' && typeof document.createEvent === 'function') { - var fakeNode = document.createElement('react'); - ReactErrorUtils.invokeGuardedCallback = function (name, func, a) { - var boundFunc = func.bind(null, a); - var evtType = 'react-' + name; - fakeNode.addEventListener(evtType, boundFunc, false); - var evt = document.createEvent('Event'); - evt.initEvent(evtType, false, false); - fakeNode.dispatchEvent(evt); - fakeNode.removeEventListener(evtType, boundFunc, false); - }; +var threeArgumentPooler = function (a1, a2, a3) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3); + return instance; + } else { + return new Klass(a1, a2, a3); } -} - -module.exports = ReactErrorUtils; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 52 */ -/***/ (function(module, exports, __webpack_require__) { +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var fourArgumentPooler = function (a1, a2, a3, a4) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3, a4); + return instance; + } else { + return new Klass(a1, a2, a3, a4); + } +}; +var standardReleaser = function (instance) { + var Klass = this; + !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; + instance.destructor(); + if (Klass.instancePool.length < Klass.poolSize) { + Klass.instancePool.push(instance); + } +}; +var DEFAULT_POOL_SIZE = 10; +var DEFAULT_POOLER = oneArgumentPooler; /** - * Gets the target node from a native browser event by accounting for - * inconsistencies in browser DOM APIs. + * Augments `CopyConstructor` to be a poolable class, augmenting only the class + * itself (statically) not adding any prototypical fields. Any CopyConstructor + * you give this may have a `poolSize` property, and will look for a + * prototypical `destructor` on instances. * - * @param {object} nativeEvent Native browser event. - * @return {DOMEventTarget} Target node. + * @param {Function} CopyConstructor Constructor that can be used to reset. + * @param {Function} pooler Customizable pooler. */ - -function getEventTarget(nativeEvent) { - var target = nativeEvent.target || nativeEvent.srcElement || window; - - // Normalize SVG <use> element events #4963 - if (target.correspondingUseElement) { - target = target.correspondingUseElement; +var addPoolingTo = function (CopyConstructor, pooler) { + // Casting as any so that flow ignores the actual implementation and trusts + // it to match the type we declared + var NewKlass = CopyConstructor; + NewKlass.instancePool = []; + NewKlass.getPooled = pooler || DEFAULT_POOLER; + if (!NewKlass.poolSize) { + NewKlass.poolSize = DEFAULT_POOL_SIZE; } + NewKlass.release = standardReleaser; + return NewKlass; +}; - // Safari may fire events on text nodes (Node.TEXT_NODE is 3). - // @see http://www.quirksmode.org/js/events_properties.html - return target.nodeType === 3 ? target.parentNode : target; -} +var PooledClass = { + addPoolingTo: addPoolingTo, + oneArgumentPooler: oneArgumentPooler, + twoArgumentPooler: twoArgumentPooler, + threeArgumentPooler: threeArgumentPooler, + fourArgumentPooler: fourArgumentPooler +}; -module.exports = getEventTarget; +module.exports = PooledClass; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 53 */ +/* 33 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +/* WEBPACK VAR INJECTION */(function(Buffer) { +var base58 = __webpack_require__(363) +var createHash = __webpack_require__(27) +// SHA256(SHA256(buffer)) +function sha256x2 (buffer) { + var tmp = createHash('sha256').update(buffer).digest() + return createHash('sha256').update(tmp).digest() +} -var ExecutionEnvironment = __webpack_require__(8); +// Encode a buffer as a base58-check encoded string +function encode (payload) { + var checksum = sha256x2(payload) -var useHasFeature; -if (ExecutionEnvironment.canUseDOM) { - useHasFeature = document.implementation && document.implementation.hasFeature && - // always returns true in newer browsers as per the standard. - // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature - document.implementation.hasFeature('', '') !== true; + return base58.encode(Buffer.concat([ + payload, + checksum + ], payload.length + 4)) } -/** - * Checks if an event is supported in the current execution environment. - * - * NOTE: This will not work correctly for non-generic events such as `change`, - * `reset`, `load`, `error`, and `select`. - * - * Borrows from Modernizr. - * - * @param {string} eventNameSuffix Event name, e.g. "click". - * @param {?boolean} capture Check if the capture phase is supported. - * @return {boolean} True if the event is supported. - * @internal - * @license Modernizr 3.0.0pre (Custom Build) | MIT - */ -function isEventSupported(eventNameSuffix, capture) { - if (!ExecutionEnvironment.canUseDOM || capture && !('addEventListener' in document)) { - return false; - } - - var eventName = 'on' + eventNameSuffix; - var isSupported = eventName in document; +function decodeRaw (buffer) { + var payload = buffer.slice(0, -4) + var checksum = buffer.slice(-4) + var newChecksum = sha256x2(payload) - if (!isSupported) { - var element = document.createElement('div'); - element.setAttribute(eventName, 'return;'); - isSupported = typeof element[eventName] === 'function'; - } + if (checksum[0] ^ newChecksum[0] | + checksum[1] ^ newChecksum[1] | + checksum[2] ^ newChecksum[2] | + checksum[3] ^ newChecksum[3]) return - if (!isSupported && useHasFeature && eventNameSuffix === 'wheel') { - // This is the only way to test support for the `wheel` event in IE9+. - isSupported = document.implementation.hasFeature('Events.wheel', '3.0'); - } + return payload +} - return isSupported; +// Decode a base58-check encoded string to a buffer, no result if checksum is wrong +function decodeUnsafe (string) { + var buffer = base58.decodeUnsafe(string) + if (!buffer) return + + return decodeRaw(buffer) } -module.exports = isEventSupported; +function decode (string) { + var buffer = base58.decode(string) + var payload = decodeRaw(buffer) + if (!payload) throw new Error('Invalid checksum') + return payload +} + +module.exports = { + encode: encode, + decode: decode, + decodeUnsafe: decodeUnsafe +} + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 54 */ +/* 34 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. +// a duplex stream is just a stream that is both readable and writable. +// Since JS doesn't have multiple prototypal inheritance, this class +// prototypally inherits from Readable, and then parasitically from +// Writable. -/** - * Translation from modifier key to the associated property in the event. - * @see http://www.w3.org/TR/DOM-Level-3-Events/#keys-Modifiers - */ -var modifierKeyToProp = { - Alt: 'altKey', - Control: 'ctrlKey', - Meta: 'metaKey', - Shift: 'shiftKey' -}; +/*<replacement>*/ -// IE8 does not implement getModifierState so we simply map it to the only -// modifier keys exposed by the event itself, does not support Lock-keys. -// Currently, all major browsers except Chrome seems to support Lock-keys. -function modifierStateGetter(keyArg) { - var syntheticEvent = this; - var nativeEvent = syntheticEvent.nativeEvent; - if (nativeEvent.getModifierState) { - return nativeEvent.getModifierState(keyArg); - } - var keyProp = modifierKeyToProp[keyArg]; - return keyProp ? !!nativeEvent[keyProp] : false; -} +var processNextTick = __webpack_require__(64); +/*</replacement>*/ -function getEventModifierState(nativeEvent) { - return modifierStateGetter; -} +/*<replacement>*/ +var objectKeys = Object.keys || function (obj) { + var keys = []; + for (var key in obj) { + keys.push(key); + }return keys; +}; +/*</replacement>*/ -module.exports = getEventModifierState; +module.exports = Duplex; -/***/ }), -/* 55 */ -/***/ (function(module, exports, __webpack_require__) { +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Readable = __webpack_require__(161); +var Writable = __webpack_require__(101); +util.inherits(Duplex, Readable); +var keys = objectKeys(Writable.prototype); +for (var v = 0; v < keys.length; v++) { + var method = keys[v]; + if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method]; +} -var DOMLazyTree = __webpack_require__(27); -var Danger = __webpack_require__(154); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstrumentation = __webpack_require__(13); +function Duplex(options) { + if (!(this instanceof Duplex)) return new Duplex(options); -var createMicrosoftUnsafeLocalFunction = __webpack_require__(57); -var setInnerHTML = __webpack_require__(43); -var setTextContent = __webpack_require__(90); + Readable.call(this, options); + Writable.call(this, options); -function getNodeAfter(parentNode, node) { - // Special case for text components, which return [open, close] comments - // from getHostNode. - if (Array.isArray(node)) { - node = node[1]; - } - return node ? node.nextSibling : parentNode.firstChild; -} + if (options && options.readable === false) this.readable = false; -/** - * Inserts `childNode` as a child of `parentNode` at the `index`. - * - * @param {DOMElement} parentNode Parent node in which to insert. - * @param {DOMElement} childNode Child node to insert. - * @param {number} index Index at which to insert the child. - * @internal - */ -var insertChildAt = createMicrosoftUnsafeLocalFunction(function (parentNode, childNode, referenceNode) { - // We rely exclusively on `insertBefore(node, null)` instead of also using - // `appendChild(node)`. (Using `undefined` is not allowed by all browsers so - // we are careful to use `null`.) - parentNode.insertBefore(childNode, referenceNode); -}); + if (options && options.writable === false) this.writable = false; -function insertLazyTreeChildAt(parentNode, childTree, referenceNode) { - DOMLazyTree.insertTreeBefore(parentNode, childTree, referenceNode); -} + this.allowHalfOpen = true; + if (options && options.allowHalfOpen === false) this.allowHalfOpen = false; -function moveChild(parentNode, childNode, referenceNode) { - if (Array.isArray(childNode)) { - moveDelimitedText(parentNode, childNode[0], childNode[1], referenceNode); - } else { - insertChildAt(parentNode, childNode, referenceNode); - } + this.once('end', onend); } -function removeChild(parentNode, childNode) { - if (Array.isArray(childNode)) { - var closingComment = childNode[1]; - childNode = childNode[0]; - removeDelimitedText(parentNode, childNode, closingComment); - parentNode.removeChild(closingComment); - } - parentNode.removeChild(childNode); -} +// the no-half-open enforcer +function onend() { + // if we allow half-open state, or if the writable side ended, + // then we're ok. + if (this.allowHalfOpen || this._writableState.ended) return; -function moveDelimitedText(parentNode, openingComment, closingComment, referenceNode) { - var node = openingComment; - while (true) { - var nextNode = node.nextSibling; - insertChildAt(parentNode, node, referenceNode); - if (node === closingComment) { - break; - } - node = nextNode; - } + // no more data can be written. + // But allow more writes to happen in this tick. + processNextTick(onEndNT, this); } -function removeDelimitedText(parentNode, startNode, closingComment) { - while (true) { - var node = startNode.nextSibling; - if (node === closingComment) { - // The closing comment is removed by ReactMultiChild. - break; - } else { - parentNode.removeChild(node); - } - } +function onEndNT(self) { + self.end(); } -function replaceDelimitedText(openingComment, closingComment, stringText) { - var parentNode = openingComment.parentNode; - var nodeAfterComment = openingComment.nextSibling; - if (nodeAfterComment === closingComment) { - // There are no text nodes between the opening and closing comments; insert - // a new one if stringText isn't empty. - if (stringText) { - insertChildAt(parentNode, document.createTextNode(stringText), nodeAfterComment); +Object.defineProperty(Duplex.prototype, 'destroyed', { + get: function () { + if (this._readableState === undefined || this._writableState === undefined) { + return false; } - } else { - if (stringText) { - // Set the text content of the first node after the opening comment, and - // remove all following nodes up until the closing comment. - setTextContent(nodeAfterComment, stringText); - removeDelimitedText(parentNode, nodeAfterComment, closingComment); - } else { - removeDelimitedText(parentNode, openingComment, closingComment); + return this._readableState.destroyed && this._writableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (this._readableState === undefined || this._writableState === undefined) { + return; } - } - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(openingComment)._debugID, - type: 'replace text', - payload: stringText - }); + // backward compatibility, the user is explicitly + // managing destroyed + this._readableState.destroyed = value; + this._writableState.destroyed = value; } -} - -var dangerouslyReplaceNodeWithMarkup = Danger.dangerouslyReplaceNodeWithMarkup; -if (process.env.NODE_ENV !== 'production') { - dangerouslyReplaceNodeWithMarkup = function (oldChild, markup, prevInstance) { - Danger.dangerouslyReplaceNodeWithMarkup(oldChild, markup); - if (prevInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: prevInstance._debugID, - type: 'replace with', - payload: markup.toString() - }); - } else { - var nextInstance = ReactDOMComponentTree.getInstanceFromNode(markup.node); - if (nextInstance._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: nextInstance._debugID, - type: 'mount', - payload: markup.toString() - }); - } - } - }; -} - -/** - * Operations for updating with DOM children. - */ -var DOMChildrenOperations = { - dangerouslyReplaceNodeWithMarkup: dangerouslyReplaceNodeWithMarkup, - - replaceDelimitedText: replaceDelimitedText, +}); - /** - * Updates a component's children by processing a series of updates. The - * update configurations are each expected to have a `parentNode` property. - * - * @param {array<object>} updates List of update configurations. - * @internal - */ - processUpdates: function (parentNode, updates) { - if (process.env.NODE_ENV !== 'production') { - var parentNodeDebugID = ReactDOMComponentTree.getInstanceFromNode(parentNode)._debugID; - } +Duplex.prototype._destroy = function (err, cb) { + this.push(null); + this.end(); - for (var k = 0; k < updates.length; k++) { - var update = updates[k]; - switch (update.type) { - case 'INSERT_MARKUP': - insertLazyTreeChildAt(parentNode, update.content, getNodeAfter(parentNode, update.afterNode)); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'insert child', - payload: { - toIndex: update.toIndex, - content: update.content.toString() - } - }); - } - break; - case 'MOVE_EXISTING': - moveChild(parentNode, update.fromNode, getNodeAfter(parentNode, update.afterNode)); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'move child', - payload: { fromIndex: update.fromIndex, toIndex: update.toIndex } - }); - } - break; - case 'SET_MARKUP': - setInnerHTML(parentNode, update.content); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'replace children', - payload: update.content.toString() - }); - } - break; - case 'TEXT_CONTENT': - setTextContent(parentNode, update.content); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'replace text', - payload: update.content.toString() - }); - } - break; - case 'REMOVE_NODE': - removeChild(parentNode, update.fromNode); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: parentNodeDebugID, - type: 'remove child', - payload: { fromIndex: update.fromIndex } - }); - } - break; - } - } - } + processNextTick(cb, err); }; -module.exports = DOMChildrenOperations; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function forEach(xs, f) { + for (var i = 0, l = xs.length; i < l; i++) { + f(xs[i], i); + } +} /***/ }), -/* 56 */ +/* 35 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Object.defineProperty(exports, "__esModule", { + value: true +}); -var DOMNamespaces = { - html: 'http://www.w3.org/1999/xhtml', - mathml: 'http://www.w3.org/1998/Math/MathML', - svg: 'http://www.w3.org/2000/svg' -}; +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -module.exports = DOMNamespaces; +var _react = __webpack_require__(6); -/***/ }), -/* 57 */ -/***/ (function(module, exports, __webpack_require__) { +var _react2 = _interopRequireDefault(_react); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var _propTypes = __webpack_require__(40); -/* globals MSApp */ +var _propTypes2 = _interopRequireDefault(_propTypes); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } +var IconBase = function IconBase(_ref, _ref2) { + var children = _ref.children; + var color = _ref.color; + var size = _ref.size; + var style = _ref.style; -/** - * Create a function which has 'unsafe' privileges (required by windows8 apps) - */ + var props = _objectWithoutProperties(_ref, ['children', 'color', 'size', 'style']); -var createMicrosoftUnsafeLocalFunction = function (func) { - if (typeof MSApp !== 'undefined' && MSApp.execUnsafeLocalFunction) { - return function (arg0, arg1, arg2, arg3) { - MSApp.execUnsafeLocalFunction(function () { - return func(arg0, arg1, arg2, arg3); - }); - }; - } else { - return func; - } + var _ref2$reactIconBase = _ref2.reactIconBase; + var reactIconBase = _ref2$reactIconBase === undefined ? {} : _ref2$reactIconBase; + + var computedSize = size || reactIconBase.size || '1em'; + return _react2.default.createElement('svg', _extends({ + children: children, + fill: 'currentColor', + preserveAspectRatio: 'xMidYMid meet', + height: computedSize, + width: computedSize + }, reactIconBase, props, { + style: _extends({ + verticalAlign: 'middle', + color: color || reactIconBase.color + }, reactIconBase.style || {}, style) + })); }; -module.exports = createMicrosoftUnsafeLocalFunction; +IconBase.propTypes = { + color: _propTypes2.default.string, + size: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.number]), + style: _propTypes2.default.object +}; + +IconBase.contextTypes = { + reactIconBase: _propTypes2.default.shape(IconBase.propTypes) +}; + +exports.default = IconBase; +module.exports = exports['default']; /***/ }), -/* 58 */ +/* 36 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -12064,140 +9532,134 @@ module.exports = createMicrosoftUnsafeLocalFunction; -var _prodInvariant = __webpack_require__(3); +var _assign = __webpack_require__(8); -var ReactPropTypesSecret = __webpack_require__(94); -var propTypesFactory = __webpack_require__(79); +var ReactBaseClasses = __webpack_require__(119); +var ReactChildren = __webpack_require__(216); +var ReactDOMFactories = __webpack_require__(220); +var ReactElement = __webpack_require__(31); +var ReactPropTypes = __webpack_require__(224); +var ReactVersion = __webpack_require__(226); -var React = __webpack_require__(24); -var PropTypes = propTypesFactory(React.isValidElement); +var createReactClass = __webpack_require__(227); +var onlyChild = __webpack_require__(229); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +var createElement = ReactElement.createElement; +var createFactory = ReactElement.createFactory; +var cloneElement = ReactElement.cloneElement; -var hasReadOnlyValue = { - button: true, - checkbox: true, - image: true, - hidden: true, - radio: true, - reset: true, - submit: true +if (process.env.NODE_ENV !== 'production') { + var lowPriorityWarning = __webpack_require__(74); + var canDefineProperty = __webpack_require__(55); + var ReactElementValidator = __webpack_require__(123); + var didWarnPropTypesDeprecated = false; + createElement = ReactElementValidator.createElement; + createFactory = ReactElementValidator.createFactory; + cloneElement = ReactElementValidator.cloneElement; +} + +var __spread = _assign; +var createMixin = function (mixin) { + return mixin; }; -function _assertSingleLink(inputProps) { - !(inputProps.checkedLink == null || inputProps.valueLink == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a valueLink. If you want to use checkedLink, you probably don\'t want to use valueLink and vice versa.') : _prodInvariant('87') : void 0; -} -function _assertValueLink(inputProps) { - _assertSingleLink(inputProps); - !(inputProps.value == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a valueLink and a value or onChange event. If you want to use value or onChange, you probably don\'t want to use valueLink.') : _prodInvariant('88') : void 0; -} +if (process.env.NODE_ENV !== 'production') { + var warnedForSpread = false; + var warnedForCreateMixin = false; + __spread = function () { + lowPriorityWarning(warnedForSpread, 'React.__spread is deprecated and should not be used. Use ' + 'Object.assign directly or another helper function with similar ' + 'semantics. You may be seeing this warning due to your compiler. ' + 'See https://fb.me/react-spread-deprecation for more details.'); + warnedForSpread = true; + return _assign.apply(null, arguments); + }; -function _assertCheckedLink(inputProps) { - _assertSingleLink(inputProps); - !(inputProps.checked == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a checked property or onChange event. If you want to use checked or onChange, you probably don\'t want to use checkedLink') : _prodInvariant('89') : void 0; + createMixin = function (mixin) { + lowPriorityWarning(warnedForCreateMixin, 'React.createMixin is deprecated and should not be used. ' + 'In React v16.0, it will be removed. ' + 'You can use this mixin directly instead. ' + 'See https://fb.me/createmixin-was-never-implemented for more info.'); + warnedForCreateMixin = true; + return mixin; + }; } -var propTypes = { - value: function (props, propName, componentName) { - if (!props[propName] || hasReadOnlyValue[props.type] || props.onChange || props.readOnly || props.disabled) { - return null; - } - return new Error('You provided a `value` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultValue`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); - }, - checked: function (props, propName, componentName) { - if (!props[propName] || props.onChange || props.readOnly || props.disabled) { - return null; - } - return new Error('You provided a `checked` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultChecked`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); +var React = { + // Modern + + Children: { + map: ReactChildren.map, + forEach: ReactChildren.forEach, + count: ReactChildren.count, + toArray: ReactChildren.toArray, + only: onlyChild }, - onChange: PropTypes.func -}; -var loggedTypeFailures = {}; -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; -} + Component: ReactBaseClasses.Component, + PureComponent: ReactBaseClasses.PureComponent, -/** - * Provide a linked `value` attribute for controlled forms. You should not use - * this outside of the ReactDOM controlled form components. - */ -var LinkedValueUtils = { - checkPropTypes: function (tagName, props, owner) { - for (var propName in propTypes) { - if (propTypes.hasOwnProperty(propName)) { - var error = propTypes[propName](props, propName, tagName, 'prop', null, ReactPropTypesSecret); - } - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; + createElement: createElement, + cloneElement: cloneElement, + isValidElement: ReactElement.isValidElement, - var addendum = getDeclarationErrorAddendum(owner); - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed form propType: %s%s', error.message, addendum) : void 0; - } - } - }, + // Classic - /** - * @param {object} inputProps Props for form component - * @return {*} current value of the input either from value prop or link. - */ - getValue: function (inputProps) { - if (inputProps.valueLink) { - _assertValueLink(inputProps); - return inputProps.valueLink.value; - } - return inputProps.value; - }, + PropTypes: ReactPropTypes, + createClass: createReactClass, + createFactory: createFactory, + createMixin: createMixin, - /** - * @param {object} inputProps Props for form component - * @return {*} current checked status of the input either from checked prop - * or link. - */ - getChecked: function (inputProps) { - if (inputProps.checkedLink) { - _assertCheckedLink(inputProps); - return inputProps.checkedLink.value; - } - return inputProps.checked; - }, + // This looks DOM specific but these are actually isomorphic helpers + // since they are just generating DOM strings. + DOM: ReactDOMFactories, - /** - * @param {object} inputProps Props for form component - * @param {SyntheticEvent} event change event to handle - */ - executeOnChange: function (inputProps, event) { - if (inputProps.valueLink) { - _assertValueLink(inputProps); - return inputProps.valueLink.requestChange(event.target.value); - } else if (inputProps.checkedLink) { - _assertCheckedLink(inputProps); - return inputProps.checkedLink.requestChange(event.target.checked); - } else if (inputProps.onChange) { - return inputProps.onChange.call(undefined, event); - } - } + version: ReactVersion, + + // Deprecated hook for JSX spread, don't use this for anything. + __spread: __spread }; -module.exports = LinkedValueUtils; +if (process.env.NODE_ENV !== 'production') { + var warnedForCreateClass = false; + if (canDefineProperty) { + Object.defineProperty(React, 'PropTypes', { + get: function () { + lowPriorityWarning(didWarnPropTypesDeprecated, 'Accessing PropTypes via the main React package is deprecated,' + ' and will be removed in React v16.0.' + ' Use the latest available v15.* prop-types package from npm instead.' + ' For info on usage, compatibility, migration and more, see ' + 'https://fb.me/prop-types-docs'); + didWarnPropTypesDeprecated = true; + return ReactPropTypes; + } + }); + + Object.defineProperty(React, 'createClass', { + get: function () { + lowPriorityWarning(warnedForCreateClass, 'Accessing createClass via the main React package is deprecated,' + ' and will be removed in React v16.0.' + " Use a plain JavaScript class instead. If you're not yet " + 'ready to migrate, create-react-class v15.* is available ' + 'on npm as a temporary, drop-in replacement. ' + 'For more info see https://fb.me/react-create-class'); + warnedForCreateClass = true; + return createReactClass; + } + }); + } + + // React.DOM factories are deprecated. Wrap these methods so that + // invocations of the React.DOM namespace and alert users to switch + // to the `react-dom-factories` package. + React.DOM = {}; + var warnedForFactories = false; + Object.keys(ReactDOMFactories).forEach(function (factory) { + React.DOM[factory] = function () { + if (!warnedForFactories) { + lowPriorityWarning(false, 'Accessing factories like React.DOM.%s has been deprecated ' + 'and will be removed in v16.0+. Use the ' + 'react-dom-factories package instead. ' + ' Version 1.0 provides a drop-in replacement.' + ' For more info, see https://fb.me/react-dom-factories', factory); + warnedForFactories = true; + } + return ReactDOMFactories[factory].apply(ReactDOMFactories, arguments); + }; + }); +} + +module.exports = React; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 59 */ +/* 37 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. +/** + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -12208,119 +9670,212 @@ module.exports = LinkedValueUtils; */ +/** + * WARNING: DO NOT manually require this module. + * This is a replacement for `invariant(...)` used by the error code system + * and will _only_ be required by the corresponding babel pass. + * It always throws. + */ -var _prodInvariant = __webpack_require__(3); +function reactProdInvariant(code) { + var argCount = arguments.length - 1; -var invariant = __webpack_require__(1); + var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code; -var injected = false; + for (var argIdx = 0; argIdx < argCount; argIdx++) { + message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]); + } -var ReactComponentEnvironment = { - /** - * Optionally injectable hook for swapping out mount images in the middle of - * the tree. - */ - replaceNodeWithMarkup: null, + message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.'; - /** - * Optionally injectable hook for processing a queue of child updates. Will - * later move into MultiChildComponents. - */ - processChildrenUpdates: null, + var error = new Error(message); + error.name = 'Invariant Violation'; + error.framesToPop = 1; // we don't care about reactProdInvariant's own frame - injection: { - injectEnvironment: function (environment) { - !!injected ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactCompositeComponent: injectEnvironment() can only be called once.') : _prodInvariant('104') : void 0; - ReactComponentEnvironment.replaceNodeWithMarkup = environment.replaceNodeWithMarkup; - ReactComponentEnvironment.processChildrenUpdates = environment.processChildrenUpdates; - injected = true; - } - } -}; + throw error; +} -module.exports = ReactComponentEnvironment; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = reactProdInvariant; /***/ }), -/* 60 */ +/* 38 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * @typechecks - * */ -/*eslint-disable no-self-compare */ +var ReactRef = __webpack_require__(238); +var ReactInstrumentation = __webpack_require__(19); -var hasOwnProperty = Object.prototype.hasOwnProperty; +var warning = __webpack_require__(3); /** - * inlined Object.is polyfill to avoid requiring consumers ship their own - * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is + * Helper to call ReactRef.attachRefs with this composite component, split out + * to avoid allocations in the transaction mount-ready queue. */ -function is(x, y) { - // SameValue algorithm - if (x === y) { - // Steps 1-5, 7-10 - // Steps 6.b-6.e: +0 != -0 - // Added the nonzero y check to make Flow happy, but it is redundant - return x !== 0 || y !== 0 || 1 / x === 1 / y; - } else { - // Step 6.a: NaN == NaN - return x !== x && y !== y; - } +function attachRefs() { + ReactRef.attachRefs(this, this._currentElement); } -/** - * Performs equality by iterating through keys on an object and returning false - * when any key has values which are not strictly equal between the arguments. - * Returns true when the values of all keys are strictly equal. - */ -function shallowEqual(objA, objB) { - if (is(objA, objB)) { - return true; - } +var ReactReconciler = { + /** + * Initializes the component, renders markup, and registers event listeners. + * + * @param {ReactComponent} internalInstance + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?object} the containing host component instance + * @param {?object} info about the host container + * @return {?string} Rendered markup to be inserted into the DOM. + * @final + * @internal + */ + mountComponent: function (internalInstance, transaction, hostParent, hostContainerInfo, context, parentDebugID) // 0 in production and for roots + { + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeMountComponent(internalInstance._debugID, internalInstance._currentElement, parentDebugID); + } + } + var markup = internalInstance.mountComponent(transaction, hostParent, hostContainerInfo, context, parentDebugID); + if (internalInstance._currentElement && internalInstance._currentElement.ref != null) { + transaction.getReactMountReady().enqueue(attachRefs, internalInstance); + } + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onMountComponent(internalInstance._debugID); + } + } + return markup; + }, - if (typeof objA !== 'object' || objA === null || typeof objB !== 'object' || objB === null) { - return false; - } + /** + * Returns a value that can be passed to + * ReactComponentEnvironment.replaceNodeWithMarkup. + */ + getHostNode: function (internalInstance) { + return internalInstance.getHostNode(); + }, - var keysA = Object.keys(objA); - var keysB = Object.keys(objB); + /** + * Releases any resources allocated by `mountComponent`. + * + * @final + * @internal + */ + unmountComponent: function (internalInstance, safely) { + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUnmountComponent(internalInstance._debugID); + } + } + ReactRef.detachRefs(internalInstance, internalInstance._currentElement); + internalInstance.unmountComponent(safely); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUnmountComponent(internalInstance._debugID); + } + } + }, - if (keysA.length !== keysB.length) { - return false; - } + /** + * Update a component using a new element. + * + * @param {ReactComponent} internalInstance + * @param {ReactElement} nextElement + * @param {ReactReconcileTransaction} transaction + * @param {object} context + * @internal + */ + receiveComponent: function (internalInstance, nextElement, transaction, context) { + var prevElement = internalInstance._currentElement; - // Test for A's keys different from B. - for (var i = 0; i < keysA.length; i++) { - if (!hasOwnProperty.call(objB, keysA[i]) || !is(objA[keysA[i]], objB[keysA[i]])) { - return false; + if (nextElement === prevElement && context === internalInstance._context) { + // Since elements are immutable after the owner is rendered, + // we can do a cheap identity compare here to determine if this is a + // superfluous reconcile. It's possible for state to be mutable but such + // change should trigger an update of the owner which would recreate + // the element. We explicitly check for the existence of an owner since + // it's possible for an element created outside a composite to be + // deeply mutated and reused. + + // TODO: Bailing out early is just a perf optimization right? + // TODO: Removing the return statement should affect correctness? + return; } - } - return true; -} + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, nextElement); + } + } -module.exports = shallowEqual; + var refsChanged = ReactRef.shouldUpdateRefs(prevElement, nextElement); + + if (refsChanged) { + ReactRef.detachRefs(internalInstance, prevElement); + } + + internalInstance.receiveComponent(nextElement, transaction, context); + + if (refsChanged && internalInstance._currentElement && internalInstance._currentElement.ref != null) { + transaction.getReactMountReady().enqueue(attachRefs, internalInstance); + } + + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); + } + } + }, + + /** + * Flush any dirty changes in a component. + * + * @param {ReactComponent} internalInstance + * @param {ReactReconcileTransaction} transaction + * @internal + */ + performUpdateIfNecessary: function (internalInstance, transaction, updateBatchNumber) { + if (internalInstance._updateBatchNumber !== updateBatchNumber) { + // The component's enqueued batch number should always be the current + // batch or the following one. + process.env.NODE_ENV !== 'production' ? warning(internalInstance._updateBatchNumber == null || internalInstance._updateBatchNumber === updateBatchNumber + 1, 'performUpdateIfNecessary: Unexpected batch number (current %s, ' + 'pending %s)', updateBatchNumber, internalInstance._updateBatchNumber) : void 0; + return; + } + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(internalInstance._debugID, internalInstance._currentElement); + } + } + internalInstance.performUpdateIfNecessary(transaction); + if (process.env.NODE_ENV !== 'production') { + if (internalInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID); + } + } + } +}; + +module.exports = ReactReconciler; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 61 */ +/* 39 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /** - * Copyright 2013-present, Facebook, Inc. + * Copyright 2015-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -12331,347 +9886,368 @@ module.exports = shallowEqual; +var DOMNamespaces = __webpack_require__(83); +var setInnerHTML = __webpack_require__(60); + +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); +var setTextContent = __webpack_require__(135); + +var ELEMENT_NODE_TYPE = 1; +var DOCUMENT_FRAGMENT_NODE_TYPE = 11; + /** - * Given a `prevElement` and `nextElement`, determines if the existing - * instance should be updated as opposed to being destroyed or replaced by a new - * instance. Both arguments are elements. This ensures that this logic can - * operate on stateless trees without any backing instance. + * In IE (8-11) and Edge, appending nodes with no children is dramatically + * faster than appending a full subtree, so we essentially queue up the + * .appendChild calls here and apply them so each node is added to its parent + * before any children are added. * - * @param {?object} prevElement - * @param {?object} nextElement - * @return {boolean} True if the existing instance should be updated. - * @protected + * In other browsers, doing so is slower or neutral compared to the other order + * (in Firefox, twice as slow) so we only do this inversion in IE. + * + * See https://github.com/spicyj/innerhtml-vs-createelement-vs-clonenode. */ +var enableLazy = typeof document !== 'undefined' && typeof document.documentMode === 'number' || typeof navigator !== 'undefined' && typeof navigator.userAgent === 'string' && /\bEdge\/\d/.test(navigator.userAgent); -function shouldUpdateReactComponent(prevElement, nextElement) { - var prevEmpty = prevElement === null || prevElement === false; - var nextEmpty = nextElement === null || nextElement === false; - if (prevEmpty || nextEmpty) { - return prevEmpty === nextEmpty; +function insertTreeChildren(tree) { + if (!enableLazy) { + return; } - - var prevType = typeof prevElement; - var nextType = typeof nextElement; - if (prevType === 'string' || prevType === 'number') { - return nextType === 'string' || nextType === 'number'; - } else { - return nextType === 'object' && prevElement.type === nextElement.type && prevElement.key === nextElement.key; + var node = tree.node; + var children = tree.children; + if (children.length) { + for (var i = 0; i < children.length; i++) { + insertTreeBefore(node, children[i], null); + } + } else if (tree.html != null) { + setInnerHTML(node, tree.html); + } else if (tree.text != null) { + setTextContent(node, tree.text); } } -module.exports = shouldUpdateReactComponent; - -/***/ }), -/* 62 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var insertTreeBefore = createMicrosoftUnsafeLocalFunction(function (parentNode, tree, referenceNode) { + // DocumentFragments aren't actually part of the DOM after insertion so + // appending children won't update the DOM. We need to ensure the fragment + // is properly populated first, breaking out of our lazy approach for just + // this level. Also, some <object> plugins (like Flash Player) will read + // <param> nodes immediately upon insertion into the DOM, so <object> + // must also be populated prior to insertion into the DOM. + if (tree.node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE || tree.node.nodeType === ELEMENT_NODE_TYPE && tree.node.nodeName.toLowerCase() === 'object' && (tree.node.namespaceURI == null || tree.node.namespaceURI === DOMNamespaces.html)) { + insertTreeChildren(tree); + parentNode.insertBefore(tree.node, referenceNode); + } else { + parentNode.insertBefore(tree.node, referenceNode); + insertTreeChildren(tree); + } +}); +function replaceChildWithTree(oldNode, newTree) { + oldNode.parentNode.replaceChild(newTree.node, oldNode); + insertTreeChildren(newTree); +} +function queueChild(parentTree, childTree) { + if (enableLazy) { + parentTree.children.push(childTree); + } else { + parentTree.node.appendChild(childTree.node); + } +} -/** - * Escape and wrap key so it is safe to use as a reactid - * - * @param {string} key to be escaped. - * @return {string} the escaped key. - */ +function queueHTML(tree, html) { + if (enableLazy) { + tree.html = html; + } else { + setInnerHTML(tree.node, html); + } +} -function escape(key) { - var escapeRegex = /[=:]/g; - var escaperLookup = { - '=': '=0', - ':': '=2' - }; - var escapedString = ('' + key).replace(escapeRegex, function (match) { - return escaperLookup[match]; - }); +function queueText(tree, text) { + if (enableLazy) { + tree.text = text; + } else { + setTextContent(tree.node, text); + } +} - return '$' + escapedString; +function toString() { + return this.node.nodeName; } -/** - * Unescape and unwrap key for human-readable display - * - * @param {string} key to unescape. - * @return {string} the unescaped key. - */ -function unescape(key) { - var unescapeRegex = /(=0|=2)/g; - var unescaperLookup = { - '=0': '=', - '=2': ':' +function DOMLazyTree(node) { + return { + node: node, + children: [], + html: null, + text: null, + toString: toString }; - var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); - - return ('' + keySubstring).replace(unescapeRegex, function (match) { - return unescaperLookup[match]; - }); } -var KeyEscapeUtils = { - escape: escape, - unescape: unescape -}; +DOMLazyTree.insertTreeBefore = insertTreeBefore; +DOMLazyTree.replaceChildWithTree = replaceChildWithTree; +DOMLazyTree.queueChild = queueChild; +DOMLazyTree.queueHTML = queueHTML; +DOMLazyTree.queueText = queueText; -module.exports = KeyEscapeUtils; +module.exports = DOMLazyTree; /***/ }), -/* 63 */ +/* 40 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. - * */ +if (process.env.NODE_ENV !== 'production') { + var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' && + Symbol.for && + Symbol.for('react.element')) || + 0xeac7; + + var isValidElement = function(object) { + return typeof object === 'object' && + object !== null && + object.$$typeof === REACT_ELEMENT_TYPE; + }; + // By explicitly using `prop-types` you are opting into new development behavior. + // http://fb.me/prop-types-in-prod + var throwOnDirectAccess = true; + module.exports = __webpack_require__(125)(isValidElement, throwOnDirectAccess); +} else { + // By explicitly using `prop-types` you are opting into new production behavior. + // http://fb.me/prop-types-in-prod + module.exports = __webpack_require__(316)(); +} -var _prodInvariant = __webpack_require__(3); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var ReactCurrentOwner = __webpack_require__(14); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactUpdates = __webpack_require__(15); +/***/ }), +/* 41 */ +/***/ (function(module, exports, __webpack_require__) { -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! + Copyright (c) 2016 Jed Watson. + Licensed under the MIT License (MIT), see + http://jedwatson.github.io/classnames +*/ +/* global define */ -function enqueueUpdate(internalInstance) { - ReactUpdates.enqueueUpdate(internalInstance); +(function () { + 'use strict'; + + var hasOwn = {}.hasOwnProperty; + + function classNames () { + var classes = []; + + for (var i = 0; i < arguments.length; i++) { + var arg = arguments[i]; + if (!arg) continue; + + var argType = typeof arg; + + if (argType === 'string' || argType === 'number') { + classes.push(arg); + } else if (Array.isArray(arg)) { + classes.push(classNames.apply(null, arg)); + } else if (argType === 'object') { + for (var key in arg) { + if (hasOwn.call(arg, key) && arg[key]) { + classes.push(key); + } + } + } + } + + return classes.join(' '); + } + + if (typeof module !== 'undefined' && module.exports) { + module.exports = classNames; + } else if (true) { + // register as 'classnames', consistent with npm package name + !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function () { + return classNames; + }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); + } else { + window.classNames = classNames; + } +}()); + + +/***/ }), +/* 42 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {// prototype class for hash functions +function Hash (blockSize, finalSize) { + this._block = new Buffer(blockSize) + this._finalSize = finalSize + this._blockSize = blockSize + this._len = 0 + this._s = 0 } -function formatUnexpectedArgument(arg) { - var type = typeof arg; - if (type !== 'object') { - return type; - } - var displayName = arg.constructor && arg.constructor.name || type; - var keys = Object.keys(arg); - if (keys.length > 0 && keys.length < 20) { - return displayName + ' (keys: ' + keys.join(', ') + ')'; +Hash.prototype.update = function (data, enc) { + if (typeof data === 'string') { + enc = enc || 'utf8' + data = new Buffer(data, enc) } - return displayName; -} -function getInternalInstanceReadyForUpdate(publicInstance, callerName) { - var internalInstance = ReactInstanceMap.get(publicInstance); - if (!internalInstance) { - if (process.env.NODE_ENV !== 'production') { - var ctor = publicInstance.constructor; - // Only warn when we have a callerName. Otherwise we should be silent. - // We're probably calling from enqueueCallback. We don't want to warn - // there because we already warned for the corresponding lifecycle method. - process.env.NODE_ENV !== 'production' ? warning(!callerName, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, ctor && (ctor.displayName || ctor.name) || 'ReactClass') : void 0; + var l = this._len += data.length + var s = this._s || 0 + var f = 0 + var buffer = this._block + + while (s < l) { + var t = Math.min(data.length, f + this._blockSize - (s % this._blockSize)) + var ch = (t - f) + + for (var i = 0; i < ch; i++) { + buffer[(s % this._blockSize) + i] = data[i + f] + } + + s += ch + f += ch + + if ((s % this._blockSize) === 0) { + this._update(buffer) } - return null; } + this._s = s - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '%s(...): Cannot update during an existing state transition (such as ' + "within `render` or another component's constructor). Render methods " + 'should be a pure function of props and state; constructor ' + 'side-effects are an anti-pattern, but can be moved to ' + '`componentWillMount`.', callerName) : void 0; + return this +} + +Hash.prototype.digest = function (enc) { + // Suppose the length of the message M, in bits, is l + var l = this._len * 8 + + // Append the bit 1 to the end of the message + this._block[this._len % this._blockSize] = 0x80 + + // and then k zero bits, where k is the smallest non-negative solution to the equation (l + 1 + k) === finalSize mod blockSize + this._block.fill(0, this._len % this._blockSize + 1) + + if (l % (this._blockSize * 8) >= this._finalSize * 8) { + this._update(this._block) + this._block.fill(0) } - return internalInstance; + // to this append the block which is equal to the number l written in binary + // TODO: handle case where l is > Math.pow(2, 29) + this._block.writeInt32BE(l, this._blockSize - 4) + + var hash = this._update(this._block) || this._hash() + + return enc ? hash.toString(enc) : hash } -/** - * ReactUpdateQueue allows for state updates to be scheduled into a later - * reconciliation step. - */ -var ReactUpdateQueue = { - /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function (publicInstance) { - if (process.env.NODE_ENV !== 'production') { - var owner = ReactCurrentOwner.current; - if (owner !== null) { - process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing isMounted inside its render() function. ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; - owner._warnedAboutRefsInRender = true; - } - } - var internalInstance = ReactInstanceMap.get(publicInstance); - if (internalInstance) { - // During componentWillMount and render this will still be null but after - // that will always render to something. At least for now. So we can use - // this hack. - return !!internalInstance._renderedComponent; - } else { - return false; - } - }, +Hash.prototype._update = function () { + throw new Error('_update must be implemented by subclass') +} - /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. - * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @param {string} callerName Name of the calling function in the public API. - * @internal - */ - enqueueCallback: function (publicInstance, callback, callerName) { - ReactUpdateQueue.validateCallback(callback, callerName); - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance); +module.exports = Hash - // Previously we would throw an error if we didn't have an internal - // instance. Since we want to make it a no-op instead, we mirror the same - // behavior we have in other enqueue* methods. - // We also need to ignore callbacks in componentWillMount. See - // enqueueUpdates. - if (!internalInstance) { - return null; - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); - } else { - internalInstance._pendingCallbacks = [callback]; - } - // TODO: The callback here is ignored when setState is called from - // componentWillMount. Either fix it or disallow doing so completely in - // favor of getInitialState. Alternatively, we can disallow - // componentWillMount during server-side rendering. - enqueueUpdate(internalInstance); - }, +/***/ }), +/* 43 */ +/***/ (function(module, exports, __webpack_require__) { - enqueueCallbackInternal: function (internalInstance, callback) { - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); - } else { - internalInstance._pendingCallbacks = [callback]; - } - enqueueUpdate(internalInstance); - }, +"use strict"; +/* WEBPACK VAR INJECTION */(function(global, process) { - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal - */ - enqueueForceUpdate: function (publicInstance) { - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'forceUpdate'); +function oldBrowser () { + throw new Error('secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11') +} - if (!internalInstance) { - return; - } +var Buffer = __webpack_require__(7).Buffer +var crypto = global.crypto || global.msCrypto - internalInstance._pendingForceUpdate = true; +if (crypto && crypto.getRandomValues) { + module.exports = randomBytes +} else { + module.exports = oldBrowser +} - enqueueUpdate(internalInstance); - }, +function randomBytes (size, cb) { + // phantomjs needs to throw + if (size > 65536) throw new Error('requested too many random bytes') + // in case browserify isn't using the Uint8Array version + var rawBytes = new global.Uint8Array(size) - /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} completeState Next state. - * @internal - */ - enqueueReplaceState: function (publicInstance, completeState, callback) { - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'replaceState'); + // This will not work in older browsers. + // See https://developer.mozilla.org/en-US/docs/Web/API/window.crypto.getRandomValues + if (size > 0) { // getRandomValues fails on IE if size == 0 + crypto.getRandomValues(rawBytes) + } - if (!internalInstance) { - return; - } + // XXX: phantomjs doesn't like a buffer being passed here + var bytes = Buffer.from(rawBytes.buffer) - internalInstance._pendingStateQueue = [completeState]; - internalInstance._pendingReplaceState = true; + if (typeof cb === 'function') { + return process.nextTick(function () { + cb(null, bytes) + }) + } - // Future-proof 15.5 - if (callback !== undefined && callback !== null) { - ReactUpdateQueue.validateCallback(callback, 'replaceState'); - if (internalInstance._pendingCallbacks) { - internalInstance._pendingCallbacks.push(callback); - } else { - internalInstance._pendingCallbacks = [callback]; - } - } + return bytes +} - enqueueUpdate(internalInstance); - }, +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} partialState Next partial state to be merged with state. - * @internal - */ - enqueueSetState: function (publicInstance, partialState) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetState(); - process.env.NODE_ENV !== 'production' ? warning(partialState != null, 'setState(...): You passed an undefined or null state object; ' + 'instead, use forceUpdate().') : void 0; - } +/***/ }), +/* 44 */ +/***/ (function(module, exports, __webpack_require__) { - var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'setState'); +var createHash = __webpack_require__(27) - if (!internalInstance) { - return; - } +function ripemd160 (buffer) { + return createHash('rmd160').update(buffer).digest() +} - var queue = internalInstance._pendingStateQueue || (internalInstance._pendingStateQueue = []); - queue.push(partialState); +function sha1 (buffer) { + return createHash('sha1').update(buffer).digest() +} - enqueueUpdate(internalInstance); - }, +function sha256 (buffer) { + return createHash('sha256').update(buffer).digest() +} - enqueueElementInternal: function (internalInstance, nextElement, nextContext) { - internalInstance._pendingElement = nextElement; - // TODO: introduce _pendingContext instead of setting it directly. - internalInstance._context = nextContext; - enqueueUpdate(internalInstance); - }, +function hash160 (buffer) { + return ripemd160(sha256(buffer)) +} - validateCallback: function (callback, callerName) { - !(!callback || typeof callback === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.', callerName, formatUnexpectedArgument(callback)) : _prodInvariant('122', callerName, formatUnexpectedArgument(callback)) : void 0; - } -}; +function hash256 (buffer) { + return sha256(sha256(buffer)) +} + +module.exports = { + hash160: hash160, + hash256: hash256, + ripemd160: ripemd160, + sha1: sha1, + sha256: sha256 +} -module.exports = ReactUpdateQueue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 64 */ +/* 45 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -12682,368 +10258,411 @@ module.exports = ReactUpdateQueue; -var _assign = __webpack_require__(5); - -var emptyFunction = __webpack_require__(12); -var warning = __webpack_require__(2); +var EventPluginHub = __webpack_require__(46); +var EventPluginUtils = __webpack_require__(77); -var validateDOMNesting = emptyFunction; +var accumulateInto = __webpack_require__(127); +var forEachAccumulated = __webpack_require__(128); +var warning = __webpack_require__(3); -if (process.env.NODE_ENV !== 'production') { - // This validation code was written based on the HTML5 parsing spec: - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope - // - // Note: this does not catch all invalid nesting, nor does it try to (as it's - // not clear what practical benefit doing so provides); instead, we warn only - // for cases where the parser will give a parse tree differing from what React - // intended. For example, <b><div></div></b> is invalid but we don't warn - // because it still parses correctly; we do warn for other cases like nested - // <p> tags where the beginning of the second element implicitly closes the - // first, causing a confusing mess. +var getListener = EventPluginHub.getListener; - // https://html.spec.whatwg.org/multipage/syntax.html#special - var specialTags = ['address', 'applet', 'area', 'article', 'aside', 'base', 'basefont', 'bgsound', 'blockquote', 'body', 'br', 'button', 'caption', 'center', 'col', 'colgroup', 'dd', 'details', 'dir', 'div', 'dl', 'dt', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'frame', 'frameset', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'iframe', 'img', 'input', 'isindex', 'li', 'link', 'listing', 'main', 'marquee', 'menu', 'menuitem', 'meta', 'nav', 'noembed', 'noframes', 'noscript', 'object', 'ol', 'p', 'param', 'plaintext', 'pre', 'script', 'section', 'select', 'source', 'style', 'summary', 'table', 'tbody', 'td', 'template', 'textarea', 'tfoot', 'th', 'thead', 'title', 'tr', 'track', 'ul', 'wbr', 'xmp']; +/** + * Some event types have a notion of different registration names for different + * "phases" of propagation. This finds listeners by a given phase. + */ +function listenerAtPhase(inst, event, propagationPhase) { + var registrationName = event.dispatchConfig.phasedRegistrationNames[propagationPhase]; + return getListener(inst, registrationName); +} - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope - var inScopeTags = ['applet', 'caption', 'html', 'table', 'td', 'th', 'marquee', 'object', 'template', +/** + * Tags a `SyntheticEvent` with dispatched listeners. Creating this function + * here, allows us to not have to bind or create functions for each event. + * Mutating the event's members allows us to not have to create a wrapping + * "dispatch" object that pairs the event with the listener. + */ +function accumulateDirectionalDispatches(inst, phase, event) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(inst, 'Dispatching inst must not be null') : void 0; + } + var listener = listenerAtPhase(inst, event, phase); + if (listener) { + event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); + event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); + } +} - // https://html.spec.whatwg.org/multipage/syntax.html#html-integration-point - // TODO: Distinguish by namespace here -- for <title>, including it here - // errs on the side of fewer warnings - 'foreignObject', 'desc', 'title']; +/** + * Collect dispatches (must be entirely collected before dispatching - see unit + * tests). Lazily allocate the array to conserve memory. We must loop through + * each event and perform the traversal for each one. We cannot perform a + * single traversal for the entire collection of events because each event may + * have a different target. + */ +function accumulateTwoPhaseDispatchesSingle(event) { + if (event && event.dispatchConfig.phasedRegistrationNames) { + EventPluginUtils.traverseTwoPhase(event._targetInst, accumulateDirectionalDispatches, event); + } +} - // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-button-scope - var buttonScopeTags = inScopeTags.concat(['button']); +/** + * Same as `accumulateTwoPhaseDispatchesSingle`, but skips over the targetID. + */ +function accumulateTwoPhaseDispatchesSingleSkipTarget(event) { + if (event && event.dispatchConfig.phasedRegistrationNames) { + var targetInst = event._targetInst; + var parentInst = targetInst ? EventPluginUtils.getParentInstance(targetInst) : null; + EventPluginUtils.traverseTwoPhase(parentInst, accumulateDirectionalDispatches, event); + } +} - // https://html.spec.whatwg.org/multipage/syntax.html#generate-implied-end-tags - var impliedEndTags = ['dd', 'dt', 'li', 'option', 'optgroup', 'p', 'rp', 'rt']; +/** + * Accumulates without regard to direction, does not look for phased + * registration names. Same as `accumulateDirectDispatchesSingle` but without + * requiring that the `dispatchMarker` be the same as the dispatched ID. + */ +function accumulateDispatches(inst, ignoredDirection, event) { + if (event && event.dispatchConfig.registrationName) { + var registrationName = event.dispatchConfig.registrationName; + var listener = getListener(inst, registrationName); + if (listener) { + event._dispatchListeners = accumulateInto(event._dispatchListeners, listener); + event._dispatchInstances = accumulateInto(event._dispatchInstances, inst); + } + } +} - var emptyAncestorInfo = { - current: null, +/** + * Accumulates dispatches on an `SyntheticEvent`, but only for the + * `dispatchMarker`. + * @param {SyntheticEvent} event + */ +function accumulateDirectDispatchesSingle(event) { + if (event && event.dispatchConfig.registrationName) { + accumulateDispatches(event._targetInst, null, event); + } +} - formTag: null, - aTagInScope: null, - buttonTagInScope: null, - nobrTagInScope: null, - pTagInButtonScope: null, +function accumulateTwoPhaseDispatches(events) { + forEachAccumulated(events, accumulateTwoPhaseDispatchesSingle); +} - listItemTagAutoclosing: null, - dlItemTagAutoclosing: null - }; +function accumulateTwoPhaseDispatchesSkipTarget(events) { + forEachAccumulated(events, accumulateTwoPhaseDispatchesSingleSkipTarget); +} - var updatedAncestorInfo = function (oldInfo, tag, instance) { - var ancestorInfo = _assign({}, oldInfo || emptyAncestorInfo); - var info = { tag: tag, instance: instance }; +function accumulateEnterLeaveDispatches(leave, enter, from, to) { + EventPluginUtils.traverseEnterLeave(from, to, accumulateDispatches, leave, enter); +} - if (inScopeTags.indexOf(tag) !== -1) { - ancestorInfo.aTagInScope = null; - ancestorInfo.buttonTagInScope = null; - ancestorInfo.nobrTagInScope = null; - } - if (buttonScopeTags.indexOf(tag) !== -1) { - ancestorInfo.pTagInButtonScope = null; - } +function accumulateDirectDispatches(events) { + forEachAccumulated(events, accumulateDirectDispatchesSingle); +} - // See rules for 'li', 'dd', 'dt' start tags in - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody - if (specialTags.indexOf(tag) !== -1 && tag !== 'address' && tag !== 'div' && tag !== 'p') { - ancestorInfo.listItemTagAutoclosing = null; - ancestorInfo.dlItemTagAutoclosing = null; - } - - ancestorInfo.current = info; - - if (tag === 'form') { - ancestorInfo.formTag = info; - } - if (tag === 'a') { - ancestorInfo.aTagInScope = info; - } - if (tag === 'button') { - ancestorInfo.buttonTagInScope = info; - } - if (tag === 'nobr') { - ancestorInfo.nobrTagInScope = info; - } - if (tag === 'p') { - ancestorInfo.pTagInButtonScope = info; - } - if (tag === 'li') { - ancestorInfo.listItemTagAutoclosing = info; - } - if (tag === 'dd' || tag === 'dt') { - ancestorInfo.dlItemTagAutoclosing = info; - } +/** + * A small set of propagation patterns, each of which will accept a small amount + * of information, and generate a set of "dispatch ready event objects" - which + * are sets of events that have already been annotated with a set of dispatched + * listener functions/ids. The API is designed this way to discourage these + * propagation strategies from actually executing the dispatches, since we + * always want to collect the entire set of dispatches before executing event a + * single one. + * + * @constructor EventPropagators + */ +var EventPropagators = { + accumulateTwoPhaseDispatches: accumulateTwoPhaseDispatches, + accumulateTwoPhaseDispatchesSkipTarget: accumulateTwoPhaseDispatchesSkipTarget, + accumulateDirectDispatches: accumulateDirectDispatches, + accumulateEnterLeaveDispatches: accumulateEnterLeaveDispatches +}; - return ancestorInfo; - }; +module.exports = EventPropagators; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - /** - * Returns whether - */ - var isTagValidWithParent = function (tag, parentTag) { - // First, let's check if we're in an unusual parsing mode... - switch (parentTag) { - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inselect - case 'select': - return tag === 'option' || tag === 'optgroup' || tag === '#text'; - case 'optgroup': - return tag === 'option' || tag === '#text'; - // Strictly speaking, seeing an <option> doesn't mean we're in a <select> - // but - case 'option': - return tag === '#text'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intd - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incaption - // No special behavior since these rules fall back to "in body" mode for - // all except special table nodes which cause bad parsing behavior anyway. +/***/ }), +/* 46 */ +/***/ (function(module, exports, __webpack_require__) { - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intr - case 'tr': - return tag === 'th' || tag === 'td' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intbody - case 'tbody': - case 'thead': - case 'tfoot': - return tag === 'tr' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incolgroup - case 'colgroup': - return tag === 'col' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intable - case 'table': - return tag === 'caption' || tag === 'colgroup' || tag === 'tbody' || tag === 'tfoot' || tag === 'thead' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inhead - case 'head': - return tag === 'base' || tag === 'basefont' || tag === 'bgsound' || tag === 'link' || tag === 'meta' || tag === 'title' || tag === 'noscript' || tag === 'noframes' || tag === 'style' || tag === 'script' || tag === 'template'; - // https://html.spec.whatwg.org/multipage/semantics.html#the-html-element - case 'html': - return tag === 'head' || tag === 'body'; - case '#document': - return tag === 'html'; - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // Probably in the "in body" parsing mode, so we outlaw only tag combos - // where the parsing rules cause implicit opens or closes to be added. - // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody - switch (tag) { - case 'h1': - case 'h2': - case 'h3': - case 'h4': - case 'h5': - case 'h6': - return parentTag !== 'h1' && parentTag !== 'h2' && parentTag !== 'h3' && parentTag !== 'h4' && parentTag !== 'h5' && parentTag !== 'h6'; - case 'rp': - case 'rt': - return impliedEndTags.indexOf(parentTag) === -1; - case 'body': - case 'caption': - case 'col': - case 'colgroup': - case 'frame': - case 'head': - case 'html': - case 'tbody': - case 'td': - case 'tfoot': - case 'th': - case 'thead': - case 'tr': - // These tags are only valid with a few parents that have special child - // parsing rules -- if we're down here, then none of those matched and - // so we allow it only if we don't know what the parent is, as all other - // cases are invalid. - return parentTag == null; - } +var _prodInvariant = __webpack_require__(5); - return true; - }; +var EventPluginRegistry = __webpack_require__(57); +var EventPluginUtils = __webpack_require__(77); +var ReactErrorUtils = __webpack_require__(78); - /** - * Returns whether - */ - var findInvalidAncestorForTag = function (tag, ancestorInfo) { - switch (tag) { - case 'address': - case 'article': - case 'aside': - case 'blockquote': - case 'center': - case 'details': - case 'dialog': - case 'dir': - case 'div': - case 'dl': - case 'fieldset': - case 'figcaption': - case 'figure': - case 'footer': - case 'header': - case 'hgroup': - case 'main': - case 'menu': - case 'nav': - case 'ol': - case 'p': - case 'section': - case 'summary': - case 'ul': - case 'pre': - case 'listing': - case 'table': - case 'hr': - case 'xmp': - case 'h1': - case 'h2': - case 'h3': - case 'h4': - case 'h5': - case 'h6': - return ancestorInfo.pTagInButtonScope; +var accumulateInto = __webpack_require__(127); +var forEachAccumulated = __webpack_require__(128); +var invariant = __webpack_require__(2); - case 'form': - return ancestorInfo.formTag || ancestorInfo.pTagInButtonScope; +/** + * Internal store for event listeners + */ +var listenerBank = {}; - case 'li': - return ancestorInfo.listItemTagAutoclosing; +/** + * Internal queue of events that have accumulated their dispatches and are + * waiting to have their dispatches executed. + */ +var eventQueue = null; - case 'dd': - case 'dt': - return ancestorInfo.dlItemTagAutoclosing; +/** + * Dispatches an event and releases it back into the pool, unless persistent. + * + * @param {?object} event Synthetic event to be dispatched. + * @param {boolean} simulated If the event is simulated (changes exn behavior) + * @private + */ +var executeDispatchesAndRelease = function (event, simulated) { + if (event) { + EventPluginUtils.executeDispatchesInOrder(event, simulated); - case 'button': - return ancestorInfo.buttonTagInScope; + if (!event.isPersistent()) { + event.constructor.release(event); + } + } +}; +var executeDispatchesAndReleaseSimulated = function (e) { + return executeDispatchesAndRelease(e, true); +}; +var executeDispatchesAndReleaseTopLevel = function (e) { + return executeDispatchesAndRelease(e, false); +}; - case 'a': - // Spec says something about storing a list of markers, but it sounds - // equivalent to this check. - return ancestorInfo.aTagInScope; +var getDictionaryKey = function (inst) { + // Prevents V8 performance issue: + // https://github.com/facebook/react/pull/7232 + return '.' + inst._rootNodeID; +}; - case 'nobr': - return ancestorInfo.nobrTagInScope; - } +function isInteractive(tag) { + return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; +} - return null; - }; +function shouldPreventMouseEvent(name, type, props) { + switch (name) { + case 'onClick': + case 'onClickCapture': + case 'onDoubleClick': + case 'onDoubleClickCapture': + case 'onMouseDown': + case 'onMouseDownCapture': + case 'onMouseMove': + case 'onMouseMoveCapture': + case 'onMouseUp': + case 'onMouseUpCapture': + return !!(props.disabled && isInteractive(type)); + default: + return false; + } +} +/** + * This is a unified interface for event plugins to be installed and configured. + * + * Event plugins can implement the following properties: + * + * `extractEvents` {function(string, DOMEventTarget, string, object): *} + * Required. When a top-level event is fired, this method is expected to + * extract synthetic events that will in turn be queued and dispatched. + * + * `eventTypes` {object} + * Optional, plugins that fire events must publish a mapping of registration + * names that are used to register listeners. Values of this mapping must + * be objects that contain `registrationName` or `phasedRegistrationNames`. + * + * `executeDispatch` {function(object, function, string)} + * Optional, allows plugins to override how an event gets dispatched. By + * default, the listener is simply invoked. + * + * Each plugin that is injected into `EventsPluginHub` is immediately operable. + * + * @public + */ +var EventPluginHub = { /** - * Given a ReactCompositeComponent instance, return a list of its recursive - * owners, starting at the root and ending with the instance itself. + * Methods for injecting dependencies. */ - var findOwnerStack = function (instance) { - if (!instance) { - return []; - } + injection: { + /** + * @param {array} InjectedEventPluginOrder + * @public + */ + injectEventPluginOrder: EventPluginRegistry.injectEventPluginOrder, - var stack = []; - do { - stack.push(instance); - } while (instance = instance._currentElement._owner); - stack.reverse(); - return stack; - }; + /** + * @param {object} injectedNamesToPlugins Map from names to plugin modules. + */ + injectEventPluginsByName: EventPluginRegistry.injectEventPluginsByName + }, - var didWarn = {}; + /** + * Stores `listener` at `listenerBank[registrationName][key]`. Is idempotent. + * + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @param {function} listener The callback to store. + */ + putListener: function (inst, registrationName, listener) { + !(typeof listener === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Expected %s listener to be a function, instead got type %s', registrationName, typeof listener) : _prodInvariant('94', registrationName, typeof listener) : void 0; - validateDOMNesting = function (childTag, childText, childInstance, ancestorInfo) { - ancestorInfo = ancestorInfo || emptyAncestorInfo; - var parentInfo = ancestorInfo.current; - var parentTag = parentInfo && parentInfo.tag; + var key = getDictionaryKey(inst); + var bankForRegistrationName = listenerBank[registrationName] || (listenerBank[registrationName] = {}); + bankForRegistrationName[key] = listener; - if (childText != null) { - process.env.NODE_ENV !== 'production' ? warning(childTag == null, 'validateDOMNesting: when childText is passed, childTag should be null') : void 0; - childTag = '#text'; + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.didPutListener) { + PluginModule.didPutListener(inst, registrationName, listener); } + }, - var invalidParent = isTagValidWithParent(childTag, parentTag) ? null : parentInfo; - var invalidAncestor = invalidParent ? null : findInvalidAncestorForTag(childTag, ancestorInfo); - var problematic = invalidParent || invalidAncestor; - - if (problematic) { - var ancestorTag = problematic.tag; - var ancestorInstance = problematic.instance; - - var childOwner = childInstance && childInstance._currentElement._owner; - var ancestorOwner = ancestorInstance && ancestorInstance._currentElement._owner; + /** + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @return {?function} The stored callback. + */ + getListener: function (inst, registrationName) { + // TODO: shouldPreventMouseEvent is DOM-specific and definitely should not + // live here; needs to be moved to a better place soon + var bankForRegistrationName = listenerBank[registrationName]; + if (shouldPreventMouseEvent(registrationName, inst._currentElement.type, inst._currentElement.props)) { + return null; + } + var key = getDictionaryKey(inst); + return bankForRegistrationName && bankForRegistrationName[key]; + }, - var childOwners = findOwnerStack(childOwner); - var ancestorOwners = findOwnerStack(ancestorOwner); + /** + * Deletes a listener from the registration bank. + * + * @param {object} inst The instance, which is the source of events. + * @param {string} registrationName Name of listener (e.g. `onClick`). + */ + deleteListener: function (inst, registrationName) { + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.willDeleteListener) { + PluginModule.willDeleteListener(inst, registrationName); + } - var minStackLen = Math.min(childOwners.length, ancestorOwners.length); - var i; + var bankForRegistrationName = listenerBank[registrationName]; + // TODO: This should never be null -- when is it? + if (bankForRegistrationName) { + var key = getDictionaryKey(inst); + delete bankForRegistrationName[key]; + } + }, - var deepestCommon = -1; - for (i = 0; i < minStackLen; i++) { - if (childOwners[i] === ancestorOwners[i]) { - deepestCommon = i; - } else { - break; - } + /** + * Deletes all listeners for the DOM element with the supplied ID. + * + * @param {object} inst The instance, which is the source of events. + */ + deleteAllListeners: function (inst) { + var key = getDictionaryKey(inst); + for (var registrationName in listenerBank) { + if (!listenerBank.hasOwnProperty(registrationName)) { + continue; } - var UNKNOWN = '(unknown)'; - var childOwnerNames = childOwners.slice(deepestCommon + 1).map(function (inst) { - return inst.getName() || UNKNOWN; - }); - var ancestorOwnerNames = ancestorOwners.slice(deepestCommon + 1).map(function (inst) { - return inst.getName() || UNKNOWN; - }); - var ownerInfo = [].concat( - // If the parent and child instances have a common owner ancestor, start - // with that -- otherwise we just start with the parent's owners. - deepestCommon !== -1 ? childOwners[deepestCommon].getName() || UNKNOWN : [], ancestorOwnerNames, ancestorTag, - // If we're warning about an invalid (non-parent) ancestry, add '...' - invalidAncestor ? ['...'] : [], childOwnerNames, childTag).join(' > '); - - var warnKey = !!invalidParent + '|' + childTag + '|' + ancestorTag + '|' + ownerInfo; - if (didWarn[warnKey]) { - return; + if (!listenerBank[registrationName][key]) { + continue; } - didWarn[warnKey] = true; - var tagDisplayName = childTag; - var whitespaceInfo = ''; - if (childTag === '#text') { - if (/\S/.test(childText)) { - tagDisplayName = 'Text nodes'; - } else { - tagDisplayName = 'Whitespace text nodes'; - whitespaceInfo = " Make sure you don't have any extra whitespace between tags on " + 'each line of your source code.'; - } - } else { - tagDisplayName = '<' + childTag + '>'; + var PluginModule = EventPluginRegistry.registrationNameModules[registrationName]; + if (PluginModule && PluginModule.willDeleteListener) { + PluginModule.willDeleteListener(inst, registrationName); } - if (invalidParent) { - var info = ''; - if (ancestorTag === 'table' && childTag === 'tr') { - info += ' Add a <tbody> to your code to match the DOM tree generated by ' + 'the browser.'; + delete listenerBank[registrationName][key]; + } + }, + + /** + * Allows registered plugins an opportunity to extract events from top-level + * native browser events. + * + * @return {*} An accumulation of synthetic events. + * @internal + */ + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var events; + var plugins = EventPluginRegistry.plugins; + for (var i = 0; i < plugins.length; i++) { + // Not every plugin in the ordering may be loaded at runtime. + var possiblePlugin = plugins[i]; + if (possiblePlugin) { + var extractedEvents = possiblePlugin.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); + if (extractedEvents) { + events = accumulateInto(events, extractedEvents); } - process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a child of <%s>.%s ' + 'See %s.%s', tagDisplayName, ancestorTag, whitespaceInfo, ownerInfo, info) : void 0; - } else { - process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a descendant of ' + '<%s>. See %s.', tagDisplayName, ancestorTag, ownerInfo) : void 0; } } - }; + return events; + }, - validateDOMNesting.updatedAncestorInfo = updatedAncestorInfo; + /** + * Enqueues a synthetic event that should be dispatched when + * `processEventQueue` is invoked. + * + * @param {*} events An accumulation of synthetic events. + * @internal + */ + enqueueEvents: function (events) { + if (events) { + eventQueue = accumulateInto(eventQueue, events); + } + }, - // For testing - validateDOMNesting.isTagValidInContext = function (tag, ancestorInfo) { - ancestorInfo = ancestorInfo || emptyAncestorInfo; - var parentInfo = ancestorInfo.current; - var parentTag = parentInfo && parentInfo.tag; - return isTagValidWithParent(tag, parentTag) && !findInvalidAncestorForTag(tag, ancestorInfo); - }; -} + /** + * Dispatches all synthetic events on the event queue. + * + * @internal + */ + processEventQueue: function (simulated) { + // Set `eventQueue` to null before processing it so that we can tell if more + // events get enqueued while processing. + var processingEventQueue = eventQueue; + eventQueue = null; + if (simulated) { + forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseSimulated); + } else { + forEachAccumulated(processingEventQueue, executeDispatchesAndReleaseTopLevel); + } + !!eventQueue ? process.env.NODE_ENV !== 'production' ? invariant(false, 'processEventQueue(): Additional events were enqueued while processing an event queue. Support for this has not yet been implemented.') : _prodInvariant('95') : void 0; + // This would be a good time to rethrow if any of the event handlers threw. + ReactErrorUtils.rethrowCaughtError(); + }, -module.exports = validateDOMNesting; + /** + * These are needed for tests only. Do not use! + */ + __purge: function () { + listenerBank = {}; + }, + + __getListenerBank: function () { + return listenerBank; + } +}; + +module.exports = EventPluginHub; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 65 */ +/* 47 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -13059,9361 +10678,9793 @@ module.exports = validateDOMNesting; +var SyntheticEvent = __webpack_require__(26); + +var getEventTarget = __webpack_require__(79); + /** - * `charCode` represents the actual "character code" and is safe to use with - * `String.fromCharCode`. As such, only keys that correspond to printable - * characters produce a valid `charCode`, the only exception to this is Enter. - * The Tab-key is considered non-printable and does not have a `charCode`, - * presumably because it does not produce a tab-character in browsers. - * - * @param {object} nativeEvent Native browser event. - * @return {number} Normalized `charCode` property. + * @interface UIEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ */ +var UIEventInterface = { + view: function (event) { + if (event.view) { + return event.view; + } -function getEventCharCode(nativeEvent) { - var charCode; - var keyCode = nativeEvent.keyCode; - - if ('charCode' in nativeEvent) { - charCode = nativeEvent.charCode; - - // FF does not set `charCode` for the Enter-key, check against `keyCode`. - if (charCode === 0 && keyCode === 13) { - charCode = 13; + var target = getEventTarget(event); + if (target.window === target) { + // target is a window object + return target; } - } else { - // IE8 does not implement `charCode`, but `keyCode` has the correct value. - charCode = keyCode; - } - // Some non-printable keys are reported in `charCode`/`keyCode`, discard them. - // Must not discard the (non-)printable Enter-key. - if (charCode >= 32 || charCode === 13) { - return charCode; + var doc = target.ownerDocument; + // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. + if (doc) { + return doc.defaultView || doc.parentWindow; + } else { + return window; + } + }, + detail: function (event) { + return event.detail || 0; } +}; - return 0; +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticUIEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); } -module.exports = getEventCharCode; +SyntheticEvent.augmentClass(SyntheticUIEvent, UIEventInterface); + +module.exports = SyntheticUIEvent; /***/ }), -/* 66 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 48 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Alert", function() { return Alert; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Container", function() { return Container; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Row", function() { return Row; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Col", function() { return Col; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Navbar", function() { return Navbar; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarBrand", function() { return NavbarBrand; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarToggler", function() { return NavbarToggler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Nav", function() { return Nav; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavItem", function() { return NavItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavDropdown", function() { return NavDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavLink", function() { return NavLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Breadcrumb", function() { return Breadcrumb; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BreadcrumbItem", function() { return BreadcrumbItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Button", function() { return Button; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonDropdown", function() { return ButtonDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonGroup", function() { return ButtonGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonToolbar", function() { return ButtonToolbar; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Dropdown", function() { return Dropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownItem", function() { return DropdownItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownMenu", function() { return DropdownMenu; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownToggle", function() { return DropdownToggle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Fade", function() { return Fade; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Badge", function() { return Badge; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Card", function() { return Card; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardLink", function() { return CardLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardGroup", function() { return CardGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardDeck", function() { return CardDeck; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardColumns", function() { return CardColumns; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardBlock", function() { return CardBlock; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardFooter", function() { return CardFooter; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardHeader", function() { return CardHeader; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImg", function() { return CardImg; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImgOverlay", function() { return CardImgOverlay; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardSubtitle", function() { return CardSubtitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardText", function() { return CardText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardTitle", function() { return CardTitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Popover", function() { return Popover; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverContent", function() { return PopoverContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverTitle", function() { return PopoverTitle; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Progress", function() { return Progress; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Modal", function() { return Modal; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalHeader", function() { return ModalHeader; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalBody", function() { return ModalBody; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalFooter", function() { return ModalFooter; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TetherContent", function() { return TetherContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Tooltip", function() { return Tooltip; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Table", function() { return Table; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroup", function() { return ListGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Form", function() { return Form; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormFeedback", function() { return FormFeedback; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormGroup", function() { return FormGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormText", function() { return FormText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Input", function() { return Input; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroup", function() { return InputGroup; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupAddon", function() { return InputGroupAddon; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupButton", function() { return InputGroupButton; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Label", function() { return Label; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Media", function() { return Media; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Pagination", function() { return Pagination; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationItem", function() { return PaginationItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationLink", function() { return PaginationLink; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabContent", function() { return TabContent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabPane", function() { return TabPane; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Jumbotron", function() { return Jumbotron; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Collapse", function() { return Collapse; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItem", function() { return ListGroupItem; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemText", function() { return ListGroupItemText; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemHeading", function() { return ListGroupItemHeading; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledAlert", function() { return UncontrolledAlert; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledButtonDropdown", function() { return UncontrolledButtonDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledDropdown", function() { return UncontrolledDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledNavDropdown", function() { return UncontrolledNavDropdown; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledTooltip", function() { return UncontrolledTooltip; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_classnames__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject__ = __webpack_require__(222); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_lodash_isobject__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom__ = __webpack_require__(28); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_react_dom__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__ = __webpack_require__(223); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__ = __webpack_require__(224); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__ = __webpack_require__(225); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group__ = __webpack_require__(226); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8_react_transition_group__); +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ +/** + * `ReactInstanceMap` maintains a mapping from a public facing stateful + * instance (key) and the internal representation (value). This allows public + * methods to accept the user facing instance as an argument and map them back + * to internal methods. + */ +// TODO: Replace this with ES6: var ReactInstanceMap = new Map(); +var ReactInstanceMap = { + /** + * This API should be called `delete` but we'd have to make sure to always + * transform these to strings for IE support. When this transform is fully + * supported we can rename it. + */ + remove: function (key) { + key._reactInternalInstance = undefined; + }, + get: function (key) { + return key._reactInternalInstance; + }, + has: function (key) { + return key._reactInternalInstance !== undefined; + }, + set: function (key, value) { + key._reactInternalInstance = value; + } +}; +module.exports = ReactInstanceMap; -function getTetherAttachments(placement) { - var attachments = {}; - switch (placement) { - case 'top': - case 'top center': - attachments = { - attachment: 'bottom center', - targetAttachment: 'top center' - }; - break; - case 'bottom': - case 'bottom center': - attachments = { - attachment: 'top center', - targetAttachment: 'bottom center' - }; - break; - case 'left': - case 'left center': - attachments = { - attachment: 'middle right', - targetAttachment: 'middle left' - }; - break; - case 'right': - case 'right center': - attachments = { - attachment: 'middle left', - targetAttachment: 'middle right' - }; - break; - case 'top left': - attachments = { - attachment: 'bottom left', - targetAttachment: 'top left' - }; - break; - case 'top right': - attachments = { - attachment: 'bottom right', - targetAttachment: 'top right' - }; - break; - case 'bottom left': - attachments = { - attachment: 'top left', - targetAttachment: 'bottom left' - }; - break; - case 'bottom right': - attachments = { - attachment: 'top right', - targetAttachment: 'bottom right' - }; - break; - case 'right top': - attachments = { - attachment: 'top left', - targetAttachment: 'top right' - }; - break; - case 'right bottom': - attachments = { - attachment: 'bottom left', - targetAttachment: 'bottom right' - }; - break; - case 'left top': - attachments = { - attachment: 'top right', - targetAttachment: 'top left' - }; - break; - case 'left bottom': - attachments = { - attachment: 'bottom right', - targetAttachment: 'bottom left' - }; - break; - default: - attachments = { - attachment: 'top center', - targetAttachment: 'bottom center' - }; - } +/***/ }), +/* 49 */ +/***/ (function(module, exports, __webpack_require__) { - return attachments; -} +/* WEBPACK VAR INJECTION */(function(Buffer) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. -var tetherAttachements = ['top', 'bottom', 'left', 'right', 'top left', 'top center', 'top right', 'right top', 'right middle', 'right bottom', 'bottom right', 'bottom center', 'bottom left', 'left top', 'left middle', 'left bottom']; +// NOTE: These type checking functions intentionally don't use `instanceof` +// because it is fragile and can be easily faked with `Object.create()`. -// https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L436-L443 -function getScrollbarWidth() { - var scrollDiv = document.createElement('div'); - // .modal-scrollbar-measure styles // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/scss/_modal.scss#L106-L113 - scrollDiv.style.position = 'absolute'; - scrollDiv.style.top = '-9999px'; - scrollDiv.style.width = '50px'; - scrollDiv.style.height = '50px'; - scrollDiv.style.overflow = 'scroll'; - document.body.appendChild(scrollDiv); - var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth; - document.body.removeChild(scrollDiv); - return scrollbarWidth; +function isArray(arg) { + if (Array.isArray) { + return Array.isArray(arg); + } + return objectToString(arg) === '[object Array]'; } +exports.isArray = isArray; -function setScrollbarWidth(padding) { - document.body.style.paddingRight = padding > 0 ? padding + 'px' : null; +function isBoolean(arg) { + return typeof arg === 'boolean'; } +exports.isBoolean = isBoolean; -function isBodyOverflowing() { - return document.body.clientWidth < window.innerWidth; +function isNull(arg) { + return arg === null; } +exports.isNull = isNull; -function getOriginalBodyPadding() { - return parseInt(window.getComputedStyle(document.body, null).getPropertyValue('padding-right') || 0, 10); +function isNullOrUndefined(arg) { + return arg == null; } +exports.isNullOrUndefined = isNullOrUndefined; -function conditionallyUpdateScrollbar() { - var scrollbarWidth = getScrollbarWidth(); - // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L420 - var fixedContent = document.querySelectorAll('.navbar-fixed-top, .navbar-fixed-bottom, .is-fixed')[0]; - var bodyPadding = fixedContent ? parseInt(fixedContent.style.paddingRight || 0, 10) : 0; +function isNumber(arg) { + return typeof arg === 'number'; +} +exports.isNumber = isNumber; - if (isBodyOverflowing()) { - setScrollbarWidth(bodyPadding + scrollbarWidth); - } +function isString(arg) { + return typeof arg === 'string'; } +exports.isString = isString; -function mapToCssModules(className, cssModule) { - if (!cssModule) return className; - return className.split(' ').map(function (c) { - return cssModule[c] || c; - }).join(' '); +function isSymbol(arg) { + return typeof arg === 'symbol'; } +exports.isSymbol = isSymbol; -/** - * Returns a new object with the key/value pairs from `obj` that are not in the array `omitKeys`. - */ -function omit(obj, omitKeys) { - var result = {}; - Object.keys(obj).forEach(function (key) { - if (omitKeys.indexOf(key) === -1) { - result[key] = obj[key]; - } - }); - return result; +function isUndefined(arg) { + return arg === void 0; } +exports.isUndefined = isUndefined; -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { - return typeof obj; -} : function (obj) { - return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; -}; +function isRegExp(re) { + return objectToString(re) === '[object RegExp]'; +} +exports.isRegExp = isRegExp; +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} +exports.isObject = isObject; +function isDate(d) { + return objectToString(d) === '[object Date]'; +} +exports.isDate = isDate; +function isError(e) { + return (objectToString(e) === '[object Error]' || e instanceof Error); +} +exports.isError = isError; +function isFunction(arg) { + return typeof arg === 'function'; +} +exports.isFunction = isFunction; +function isPrimitive(arg) { + return arg === null || + typeof arg === 'boolean' || + typeof arg === 'number' || + typeof arg === 'string' || + typeof arg === 'symbol' || // ES6 symbol + typeof arg === 'undefined'; +} +exports.isPrimitive = isPrimitive; +exports.isBuffer = Buffer.isBuffer; +function objectToString(o) { + return Object.prototype.toString.call(o); +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) +/***/ }), +/* 50 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; -var classCallCheck = function (instance, Constructor) { - if (!(instance instanceof Constructor)) { - throw new TypeError("Cannot call a class as a function"); - } -}; -var createClass = function () { - function defineProperties(target, props) { - for (var i = 0; i < props.length; i++) { - var descriptor = props[i]; - descriptor.enumerable = descriptor.enumerable || false; - descriptor.configurable = true; - if ("value" in descriptor) descriptor.writable = true; - Object.defineProperty(target, descriptor.key, descriptor); - } - } +var utils = __webpack_require__(25); +var assert = __webpack_require__(21); - return function (Constructor, protoProps, staticProps) { - if (protoProps) defineProperties(Constructor.prototype, protoProps); - if (staticProps) defineProperties(Constructor, staticProps); - return Constructor; - }; -}(); +function BlockHash() { + this.pending = null; + this.pendingTotal = 0; + this.blockSize = this.constructor.blockSize; + this.outSize = this.constructor.outSize; + this.hmacStrength = this.constructor.hmacStrength; + this.padLength = this.constructor.padLength / 8; + this.endian = 'big'; + this._delta8 = this.blockSize / 8; + this._delta32 = this.blockSize / 32; +} +exports.BlockHash = BlockHash; +BlockHash.prototype.update = function update(msg, enc) { + // Convert message to array, pad it, and join into 32bit blocks + msg = utils.toArray(msg, enc); + if (!this.pending) + this.pending = msg; + else + this.pending = this.pending.concat(msg); + this.pendingTotal += msg.length; + // Enough data, try updating + if (this.pending.length >= this._delta8) { + msg = this.pending; + // Process pending data in blocks + var r = msg.length % this._delta8; + this.pending = msg.slice(msg.length - r, msg.length); + if (this.pending.length === 0) + this.pending = null; -var defineProperty = function (obj, key, value) { - if (key in obj) { - Object.defineProperty(obj, key, { - value: value, - enumerable: true, - configurable: true, - writable: true - }); - } else { - obj[key] = value; + msg = utils.join32(msg, 0, msg.length - r, this.endian); + for (var i = 0; i < msg.length; i += this._delta32) + this._update(msg, i, i + this._delta32); } - return obj; + return this; }; -var _extends = Object.assign || function (target) { - for (var i = 1; i < arguments.length; i++) { - var source = arguments[i]; - - for (var key in source) { - if (Object.prototype.hasOwnProperty.call(source, key)) { - target[key] = source[key]; - } - } - } +BlockHash.prototype.digest = function digest(enc) { + this.update(this._pad()); + assert(this.pending === null); - return target; + return this._digest(enc); }; +BlockHash.prototype._pad = function pad() { + var len = this.pendingTotal; + var bytes = this._delta8; + var k = bytes - ((len + this.padLength) % bytes); + var res = new Array(k + this.padLength); + res[0] = 0x80; + for (var i = 1; i < k; i++) + res[i] = 0; + // Append length + len <<= 3; + if (this.endian === 'big') { + for (var t = 8; t < this.padLength; t++) + res[i++] = 0; -var inherits = function (subClass, superClass) { - if (typeof superClass !== "function" && superClass !== null) { - throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); - } - - subClass.prototype = Object.create(superClass && superClass.prototype, { - constructor: { - value: subClass, - enumerable: false, - writable: true, - configurable: true - } - }); - if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; -}; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = (len >>> 24) & 0xff; + res[i++] = (len >>> 16) & 0xff; + res[i++] = (len >>> 8) & 0xff; + res[i++] = len & 0xff; + } else { + res[i++] = len & 0xff; + res[i++] = (len >>> 8) & 0xff; + res[i++] = (len >>> 16) & 0xff; + res[i++] = (len >>> 24) & 0xff; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + res[i++] = 0; + for (t = 8; t < this.padLength; t++) + res[i++] = 0; + } + return res; +}; +/***/ }), +/* 51 */ +/***/ (function(module, exports, __webpack_require__) { +/* WEBPACK VAR INJECTION */(function(Buffer) {module.exports = function xor (a, b) { + var length = Math.min(a.length, b.length) + var buffer = new Buffer(length) + for (var i = 0; i < length; ++i) { + buffer[i] = a[i] ^ b[i] + } + return buffer +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var objectWithoutProperties = function (obj, keys) { - var target = {}; +/***/ }), +/* 52 */ +/***/ (function(module, exports, __webpack_require__) { - for (var i in obj) { - if (keys.indexOf(i) >= 0) continue; - if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; - target[i] = obj[i]; - } +var asn1 = exports; - return target; -}; +asn1.bignum = __webpack_require__(11); -var possibleConstructorReturn = function (self, call) { - if (!self) { - throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); - } +asn1.define = __webpack_require__(440).define; +asn1.base = __webpack_require__(53); +asn1.constants = __webpack_require__(192); +asn1.decoders = __webpack_require__(446); +asn1.encoders = __webpack_require__(448); - return call && (typeof call === "object" || typeof call === "function") ? call : self; -}; -var propTypes = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 53 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps = { - tag: 'div' -}; +var base = exports; -var Container = function Container(props) { - var className = props.className, - cssModule = props.cssModule, - fluid = props.fluid, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'fluid', 'tag']); +base.Reporter = __webpack_require__(443).Reporter; +base.DecoderBuffer = __webpack_require__(191).DecoderBuffer; +base.EncoderBuffer = __webpack_require__(191).EncoderBuffer; +base.Node = __webpack_require__(444); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, fluid ? 'container-fluid' : 'container'), cssModule); +/***/ }), +/* 54 */ +/***/ (function(module, exports) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +// https://en.bitcoin.it/wiki/List_of_address_prefixes +// Dogecoin BIP32 is a proposed standard: https://bitcointalk.org/index.php?topic=409731 -Container.propTypes = propTypes; -Container.defaultProps = defaultProps; +module.exports = { + bitcoin: { + messagePrefix: '\x18Bitcoin Signed Message:\n', + bip32: { + public: 0x0488b21e, + private: 0x0488ade4 + }, + pubKeyHash: 0x00, + scriptHash: 0x05, + wif: 0x80 + }, + testnet: { + messagePrefix: '\x18Bitcoin Signed Message:\n', + bip32: { + public: 0x043587cf, + private: 0x04358394 + }, + pubKeyHash: 0x6f, + scriptHash: 0xc4, + wif: 0xef + }, + litecoin: { + messagePrefix: '\x19Litecoin Signed Message:\n', + bip32: { + public: 0x019da462, + private: 0x019d9cfe + }, + pubKeyHash: 0x30, + scriptHash: 0x32, + wif: 0xb0 + } +} -var propTypes$1 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - noGutters: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$1 = { - tag: 'div' -}; +/***/ }), +/* 55 */ +/***/ (function(module, exports, __webpack_require__) { -var Row = function Row(props) { - var className = props.className, - cssModule = props.cssModule, - noGutters = props.noGutters, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'noGutters', 'tag']); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, noGutters ? 'no-gutters' : null, 'row'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var canDefineProperty = false; +if (process.env.NODE_ENV !== 'production') { + try { + // $FlowFixMe https://github.com/facebook/flow/issues/285 + Object.defineProperty({}, 'x', { get: function () {} }); + canDefineProperty = true; + } catch (x) { + // IE will fail on defineProperty + } +} -Row.propTypes = propTypes$1; -Row.defaultProps = defaultProps$1; +module.exports = canDefineProperty; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var colWidths = ['xs', 'sm', 'md', 'lg', 'xl']; -var stringOrNumberProp = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); +/***/ }), +/* 56 */ +/***/ (function(module, exports, __webpack_require__) { -var columnProps = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - push: stringOrNumberProp, - pull: stringOrNumberProp, - offset: stringOrNumberProp -})]); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var propTypes$2 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - xs: columnProps, - sm: columnProps, - md: columnProps, - lg: columnProps, - xl: columnProps, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - widths: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.array -}; -var defaultProps$2 = { - tag: 'div', - widths: colWidths -}; -var getColumnSizeClass = function getColumnSizeClass(isXs, colWidth, colSize) { - if (colSize === true || colSize === '') { - return isXs ? 'col' : 'col-' + colWidth; - } else if (colSize === 'auto') { - return isXs ? 'col-auto' : 'col-' + colWidth + '-auto'; - } +var emptyObject = {}; - return isXs ? 'col-' + colSize : 'col-' + colWidth + '-' + colSize; -}; +if (process.env.NODE_ENV !== 'production') { + Object.freeze(emptyObject); +} -var Col = function Col(props) { - var className = props.className, - cssModule = props.cssModule, - widths = props.widths, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'widths', 'tag']); +module.exports = emptyObject; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var colClasses = []; +/***/ }), +/* 57 */ +/***/ (function(module, exports, __webpack_require__) { - widths.forEach(function (colWidth, i) { - var columnProp = props[colWidth]; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - if (!i && columnProp === undefined) { - columnProp = true; - } - delete attributes[colWidth]; - if (!columnProp) { - return; - } +var _prodInvariant = __webpack_require__(5); - var isXs = !i; - var colClass = void 0; +var invariant = __webpack_require__(2); - if (__WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default()(columnProp)) { - var _classNames; +/** + * Injectable ordering of event plugins. + */ +var eventPluginOrder = null; - var colSizeInterfix = isXs ? '-' : '-' + colWidth + '-'; - colClass = getColumnSizeClass(isXs, colWidth, columnProp.size); +/** + * Injectable mapping from names to event plugin modules. + */ +var namesToPlugins = {}; - colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, colClass, columnProp.size || columnProp.size === ''), defineProperty(_classNames, 'push' + colSizeInterfix + columnProp.push, columnProp.push || columnProp.push === 0), defineProperty(_classNames, 'pull' + colSizeInterfix + columnProp.pull, columnProp.pull || columnProp.pull === 0), defineProperty(_classNames, 'offset' + colSizeInterfix + columnProp.offset, columnProp.offset || columnProp.offset === 0), _classNames))), cssModule); - } else { - colClass = getColumnSizeClass(isXs, colWidth, columnProp); - colClasses.push(colClass); +/** + * Recomputes the plugin list using the injected plugins and plugin ordering. + * + * @private + */ +function recomputePluginOrdering() { + if (!eventPluginOrder) { + // Wait until an `eventPluginOrder` is injected. + return; + } + for (var pluginName in namesToPlugins) { + var pluginModule = namesToPlugins[pluginName]; + var pluginIndex = eventPluginOrder.indexOf(pluginName); + !(pluginIndex > -1) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugins that do not exist in the plugin ordering, `%s`.', pluginName) : _prodInvariant('96', pluginName) : void 0; + if (EventPluginRegistry.plugins[pluginIndex]) { + continue; } - }); - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, colClasses), cssModule); + !pluginModule.extractEvents ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Event plugins must implement an `extractEvents` method, but `%s` does not.', pluginName) : _prodInvariant('97', pluginName) : void 0; + EventPluginRegistry.plugins[pluginIndex] = pluginModule; + var publishedEvents = pluginModule.eventTypes; + for (var eventName in publishedEvents) { + !publishEventForPlugin(publishedEvents[eventName], pluginModule, eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Failed to publish event `%s` for plugin `%s`.', eventName, pluginName) : _prodInvariant('98', eventName, pluginName) : void 0; + } + } +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/** + * Publishes an event so that it can be dispatched by the supplied plugin. + * + * @param {object} dispatchConfig Dispatch configuration for the event. + * @param {object} PluginModule Plugin publishing the event. + * @return {boolean} True if the event was successfully published. + * @private + */ +function publishEventForPlugin(dispatchConfig, pluginModule, eventName) { + !!EventPluginRegistry.eventNameDispatchConfigs.hasOwnProperty(eventName) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same event name, `%s`.', eventName) : _prodInvariant('99', eventName) : void 0; + EventPluginRegistry.eventNameDispatchConfigs[eventName] = dispatchConfig; -Col.propTypes = propTypes$2; -Col.defaultProps = defaultProps$2; + var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; + if (phasedRegistrationNames) { + for (var phaseName in phasedRegistrationNames) { + if (phasedRegistrationNames.hasOwnProperty(phaseName)) { + var phasedRegistrationName = phasedRegistrationNames[phaseName]; + publishRegistrationName(phasedRegistrationName, pluginModule, eventName); + } + } + return true; + } else if (dispatchConfig.registrationName) { + publishRegistrationName(dispatchConfig.registrationName, pluginModule, eventName); + return true; + } + return false; +} -var propTypes$3 = { - light: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - full: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - fixed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - sticky: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggleable: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; +/** + * Publishes a registration name that is used to identify dispatched events and + * can be used with `EventPluginHub.putListener` to register listeners. + * + * @param {string} registrationName Registration name to add. + * @param {object} PluginModule Plugin publishing the event. + * @private + */ +function publishRegistrationName(registrationName, pluginModule, eventName) { + !!EventPluginRegistry.registrationNameModules[registrationName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginHub: More than one plugin attempted to publish the same registration name, `%s`.', registrationName) : _prodInvariant('100', registrationName) : void 0; + EventPluginRegistry.registrationNameModules[registrationName] = pluginModule; + EventPluginRegistry.registrationNameDependencies[registrationName] = pluginModule.eventTypes[eventName].dependencies; -var defaultProps$3 = { - tag: 'nav', - toggleable: false -}; + if (process.env.NODE_ENV !== 'production') { + var lowerCasedName = registrationName.toLowerCase(); + EventPluginRegistry.possibleRegistrationNames[lowerCasedName] = registrationName; -var getToggleableClass = function getToggleableClass(toggleable) { - if (toggleable === false) { - return false; - } else if (toggleable === true || toggleable === 'xs') { - return 'navbar-toggleable'; + if (registrationName === 'onDoubleClick') { + EventPluginRegistry.possibleRegistrationNames.ondblclick = registrationName; + } } +} - return 'navbar-toggleable-' + toggleable; -}; +/** + * Registers plugins so that they can extract and dispatch events. + * + * @see {EventPluginHub} + */ +var EventPluginRegistry = { + /** + * Ordered list of injected plugins. + */ + plugins: [], -var Navbar = function Navbar(props) { - var _classNames; + /** + * Mapping from event name to dispatch config + */ + eventNameDispatchConfigs: {}, - var toggleable = props.toggleable, - className = props.className, - cssModule = props.cssModule, - light = props.light, - inverse = props.inverse, - full = props.full, - fixed = props.fixed, - sticky = props.sticky, - color = props.color, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['toggleable', 'className', 'cssModule', 'light', 'inverse', 'full', 'fixed', 'sticky', 'color', 'tag']); + /** + * Mapping from registration name to plugin module + */ + registrationNameModules: {}, + /** + * Mapping from registration name to event name + */ + registrationNameDependencies: {}, - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar', getToggleableClass(toggleable), (_classNames = { - 'navbar-light': light, - 'navbar-inverse': inverse - }, defineProperty(_classNames, 'bg-' + color, color), defineProperty(_classNames, 'navbar-full', full), defineProperty(_classNames, 'fixed-' + fixed, fixed), defineProperty(_classNames, 'sticky-' + sticky, sticky), _classNames)), cssModule); + /** + * Mapping from lowercase registration names to the properly cased version, + * used to warn in the case of missing event handlers. Available + * only in __DEV__. + * @type {Object} + */ + possibleRegistrationNames: process.env.NODE_ENV !== 'production' ? {} : null, + // Trust the developer to only use possibleRegistrationNames in __DEV__ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + /** + * Injects an ordering of plugins (by plugin name). This allows the ordering + * to be decoupled from injection of the actual plugins so that ordering is + * always deterministic regardless of packaging, on-the-fly injection, etc. + * + * @param {array} InjectedEventPluginOrder + * @internal + * @see {EventPluginHub.injection.injectEventPluginOrder} + */ + injectEventPluginOrder: function (injectedEventPluginOrder) { + !!eventPluginOrder ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject event plugin ordering more than once. You are likely trying to load more than one copy of React.') : _prodInvariant('101') : void 0; + // Clone the ordering so it cannot be dynamically mutated. + eventPluginOrder = Array.prototype.slice.call(injectedEventPluginOrder); + recomputePluginOrdering(); + }, -Navbar.propTypes = propTypes$3; -Navbar.defaultProps = defaultProps$3; + /** + * Injects plugins to be used by `EventPluginHub`. The plugin names must be + * in the ordering injected by `injectEventPluginOrder`. + * + * Plugins can be injected as part of page initialization or on-the-fly. + * + * @param {object} injectedNamesToPlugins Map from names to plugin modules. + * @internal + * @see {EventPluginHub.injection.injectEventPluginsByName} + */ + injectEventPluginsByName: function (injectedNamesToPlugins) { + var isOrderingDirty = false; + for (var pluginName in injectedNamesToPlugins) { + if (!injectedNamesToPlugins.hasOwnProperty(pluginName)) { + continue; + } + var pluginModule = injectedNamesToPlugins[pluginName]; + if (!namesToPlugins.hasOwnProperty(pluginName) || namesToPlugins[pluginName] !== pluginModule) { + !!namesToPlugins[pluginName] ? process.env.NODE_ENV !== 'production' ? invariant(false, 'EventPluginRegistry: Cannot inject two different event plugins using the same name, `%s`.', pluginName) : _prodInvariant('102', pluginName) : void 0; + namesToPlugins[pluginName] = pluginModule; + isOrderingDirty = true; + } + } + if (isOrderingDirty) { + recomputePluginOrdering(); + } + }, -var propTypes$4 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * Looks up the plugin for the supplied event. + * + * @param {object} event A synthetic event. + * @return {?object} The plugin that created the supplied event. + * @internal + */ + getPluginModuleForEvent: function (event) { + var dispatchConfig = event.dispatchConfig; + if (dispatchConfig.registrationName) { + return EventPluginRegistry.registrationNameModules[dispatchConfig.registrationName] || null; + } + if (dispatchConfig.phasedRegistrationNames !== undefined) { + // pulling phasedRegistrationNames out of dispatchConfig helps Flow see + // that it is not undefined. + var phasedRegistrationNames = dispatchConfig.phasedRegistrationNames; -var defaultProps$4 = { - tag: 'a' -}; + for (var phase in phasedRegistrationNames) { + if (!phasedRegistrationNames.hasOwnProperty(phase)) { + continue; + } + var pluginModule = EventPluginRegistry.registrationNameModules[phasedRegistrationNames[phase]]; + if (pluginModule) { + return pluginModule; + } + } + } + return null; + }, -var NavbarBrand = function NavbarBrand(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + /** + * Exposed for unit testing. + * @private + */ + _resetEventPlugins: function () { + eventPluginOrder = null; + for (var pluginName in namesToPlugins) { + if (namesToPlugins.hasOwnProperty(pluginName)) { + delete namesToPlugins[pluginName]; + } + } + EventPluginRegistry.plugins.length = 0; + var eventNameDispatchConfigs = EventPluginRegistry.eventNameDispatchConfigs; + for (var eventName in eventNameDispatchConfigs) { + if (eventNameDispatchConfigs.hasOwnProperty(eventName)) { + delete eventNameDispatchConfigs[eventName]; + } + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-brand'), cssModule); + var registrationNameModules = EventPluginRegistry.registrationNameModules; + for (var registrationName in registrationNameModules) { + if (registrationNameModules.hasOwnProperty(registrationName)) { + delete registrationNameModules[registrationName]; + } + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + if (process.env.NODE_ENV !== 'production') { + var possibleRegistrationNames = EventPluginRegistry.possibleRegistrationNames; + for (var lowerCasedName in possibleRegistrationNames) { + if (possibleRegistrationNames.hasOwnProperty(lowerCasedName)) { + delete possibleRegistrationNames[lowerCasedName]; + } + } + } + } }; -NavbarBrand.propTypes = propTypes$4; -NavbarBrand.defaultProps = defaultProps$4; - -var propTypes$5 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +module.exports = EventPluginRegistry; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var defaultProps$5 = { - tag: 'button', - type: 'button' -}; +/***/ }), +/* 58 */ +/***/ (function(module, exports, __webpack_require__) { -var navbarToggleIcon = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('span', { className: 'navbar-toggler-icon' }); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var NavbarToggler = function NavbarToggler(props) { - var className = props.className, - cssModule = props.cssModule, - children = props.children, - right = props.right, - left = props.left, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'right', 'left', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-toggler', right && 'navbar-toggler-right', left && 'navbar-toggler-left'), cssModule); +var _prodInvariant = __webpack_require__(5); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { className: classes }), - children || navbarToggleIcon - ); -}; +var invariant = __webpack_require__(2); -NavbarToggler.propTypes = propTypes$5; -NavbarToggler.defaultProps = defaultProps$5; +var OBSERVED_ERROR = {}; -var propTypes$6 = { - tabs: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - pills: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/** + * `Transaction` creates a black box that is able to wrap any method such that + * certain invariants are maintained before and after the method is invoked + * (Even if an exception is thrown while invoking the wrapped method). Whoever + * instantiates a transaction can provide enforcers of the invariants at + * creation time. The `Transaction` class itself will supply one additional + * automatic invariant for you - the invariant that any transaction instance + * should not be run while it is already being run. You would typically create a + * single instance of a `Transaction` for reuse multiple times, that potentially + * is used to wrap several different methods. Wrappers are extremely simple - + * they only require implementing two methods. + * + * <pre> + * wrappers (injected at creation time) + * + + + * | | + * +-----------------|--------|--------------+ + * | v | | + * | +---------------+ | | + * | +--| wrapper1 |---|----+ | + * | | +---------------+ v | | + * | | +-------------+ | | + * | | +----| wrapper2 |--------+ | + * | | | +-------------+ | | | + * | | | | | | + * | v v v v | wrapper + * | +---+ +---+ +---------+ +---+ +---+ | invariants + * perform(anyMethod) | | | | | | | | | | | | maintained + * +----------------->|-|---|-|---|-->|anyMethod|---|---|-|---|-|--------> + * | | | | | | | | | | | | + * | | | | | | | | | | | | + * | | | | | | | | | | | | + * | +---+ +---+ +---------+ +---+ +---+ | + * | initialize close | + * +-----------------------------------------+ + * </pre> + * + * Use cases: + * - Preserving the input selection ranges before/after reconciliation. + * Restoring selection even in the event of an unexpected error. + * - Deactivating events while rearranging the DOM, preventing blurs/focuses, + * while guaranteeing that afterwards, the event system is reactivated. + * - Flushing a queue of collected DOM mutations to the main UI thread after a + * reconciliation takes place in a worker thread. + * - Invoking any collected `componentDidUpdate` callbacks after rendering new + * content. + * - (Future use case): Wrapping particular flushes of the `ReactWorker` queue + * to preserve the `scrollTop` (an automatic scroll aware DOM). + * - (Future use case): Layout calculations before and after DOM updates. + * + * Transactional plugin API: + * - A module that has an `initialize` method that returns any precomputation. + * - and a `close` method that accepts the precomputation. `close` is invoked + * when the wrapped process is completed, or has failed. + * + * @param {Array<TransactionalWrapper>} transactionWrapper Wrapper modules + * that implement `initialize` and `close`. + * @return {Transaction} Single transaction for reuse in thread. + * + * @class Transaction + */ +var TransactionImpl = { + /** + * Sets up this instance so that it is prepared for collecting metrics. Does + * so such that this setup method may be used on an instance that is already + * initialized, in a way that does not consume additional memory upon reuse. + * That can be useful if you decide to make your subclass of this mixin a + * "PooledClass". + */ + reinitializeTransaction: function () { + this.transactionWrappers = this.getTransactionWrappers(); + if (this.wrapperInitData) { + this.wrapperInitData.length = 0; + } else { + this.wrapperInitData = []; + } + this._isInTransaction = false; + }, -var defaultProps$6 = { - tag: 'ul' -}; + _isInTransaction: false, -var Nav = function Nav(props) { - var className = props.className, - cssModule = props.cssModule, - tabs = props.tabs, - pills = props.pills, - vertical = props.vertical, - navbar = props.navbar, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabs', 'pills', 'vertical', 'navbar', 'tag']); + /** + * @abstract + * @return {Array<TransactionWrapper>} Array of transaction wrappers. + */ + getTransactionWrappers: null, + isInTransaction: function () { + return !!this._isInTransaction; + }, - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, navbar ? 'navbar-nav' : 'nav', { - 'nav-tabs': tabs, - 'nav-pills': pills, - 'flex-column': vertical - }), cssModule); + /* eslint-disable space-before-function-paren */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + /** + * Executes the function within a safety window. Use this for the top level + * methods that result in large amounts of computation/mutations that would + * need to be safety checked. The optional arguments helps prevent the need + * to bind in many cases. + * + * @param {function} method Member of scope to call. + * @param {Object} scope Scope to invoke from. + * @param {Object?=} a Argument to pass to the method. + * @param {Object?=} b Argument to pass to the method. + * @param {Object?=} c Argument to pass to the method. + * @param {Object?=} d Argument to pass to the method. + * @param {Object?=} e Argument to pass to the method. + * @param {Object?=} f Argument to pass to the method. + * + * @return {*} Return value from `method`. + */ + perform: function (method, scope, a, b, c, d, e, f) { + /* eslint-enable space-before-function-paren */ + !!this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.perform(...): Cannot initialize a transaction when there is already an outstanding transaction.') : _prodInvariant('27') : void 0; + var errorThrown; + var ret; + try { + this._isInTransaction = true; + // Catching errors makes debugging more difficult, so we start with + // errorThrown set to true before setting it to false after calling + // close -- if it's still set to true in the finally block, it means + // one of these calls threw. + errorThrown = true; + this.initializeAll(0); + ret = method.call(scope, a, b, c, d, e, f); + errorThrown = false; + } finally { + try { + if (errorThrown) { + // If `method` throws, prefer to show that stack trace over any thrown + // by invoking `closeAll`. + try { + this.closeAll(0); + } catch (err) {} + } else { + // Since `method` didn't throw, we don't want to silence the exception + // here. + this.closeAll(0); + } + } finally { + this._isInTransaction = false; + } + } + return ret; + }, -Nav.propTypes = propTypes$6; -Nav.defaultProps = defaultProps$6; + initializeAll: function (startIndex) { + var transactionWrappers = this.transactionWrappers; + for (var i = startIndex; i < transactionWrappers.length; i++) { + var wrapper = transactionWrappers[i]; + try { + // Catching errors makes debugging more difficult, so we start with the + // OBSERVED_ERROR state before overwriting it with the real return value + // of initialize -- if it's still set to OBSERVED_ERROR in the finally + // block, it means wrapper.initialize threw. + this.wrapperInitData[i] = OBSERVED_ERROR; + this.wrapperInitData[i] = wrapper.initialize ? wrapper.initialize.call(this) : null; + } finally { + if (this.wrapperInitData[i] === OBSERVED_ERROR) { + // The initializer for wrapper i threw an error; initialize the + // remaining wrappers but silence any exceptions from them to ensure + // that the first error is the one to bubble up. + try { + this.initializeAll(i + 1); + } catch (err) {} + } + } + } + }, -var propTypes$7 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object + /** + * Invokes each of `this.transactionWrappers.close[i]` functions, passing into + * them the respective return values of `this.transactionWrappers.init[i]` + * (`close`rs that correspond to initializers that failed will not be + * invoked). + */ + closeAll: function (startIndex) { + !this.isInTransaction() ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Transaction.closeAll(): Cannot close transaction when none are open.') : _prodInvariant('28') : void 0; + var transactionWrappers = this.transactionWrappers; + for (var i = startIndex; i < transactionWrappers.length; i++) { + var wrapper = transactionWrappers[i]; + var initData = this.wrapperInitData[i]; + var errorThrown; + try { + // Catching errors makes debugging more difficult, so we start with + // errorThrown set to true before setting it to false after calling + // close -- if it's still set to true in the finally block, it means + // wrapper.close threw. + errorThrown = true; + if (initData !== OBSERVED_ERROR && wrapper.close) { + wrapper.close.call(this, initData); + } + errorThrown = false; + } finally { + if (errorThrown) { + // The closer for wrapper i threw an error; close the remaining + // wrappers but silence any exceptions from them to ensure that the + // first error is the one to bubble up. + try { + this.closeAll(i + 1); + } catch (e) {} + } + } + } + this.wrapperInitData.length = 0; + } }; -var defaultProps$7 = { - tag: 'li' -}; +module.exports = TransactionImpl; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var NavItem = function NavItem(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/***/ }), +/* 59 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -NavItem.propTypes = propTypes$7; -NavItem.defaultProps = defaultProps$7; +var SyntheticUIEvent = __webpack_require__(47); +var ViewportMetrics = __webpack_require__(134); -var propTypes$10 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - arrow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object.isRequired, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - style: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var getEventModifierState = __webpack_require__(81); -var defaultProps$10 = { - isOpen: false, - tetherRef: function tetherRef() {} +/** + * @interface MouseEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var MouseEventInterface = { + screenX: null, + screenY: null, + clientX: null, + clientY: null, + ctrlKey: null, + shiftKey: null, + altKey: null, + metaKey: null, + getModifierState: getEventModifierState, + button: function (event) { + // Webkit, Firefox, IE9+ + // which: 1 2 3 + // button: 0 1 2 (standard) + var button = event.button; + if ('which' in event) { + return button; + } + // IE<9 + // which: undefined + // button: 0 0 0 + // button: 1 4 2 (onmouseup) + return button === 2 ? 2 : button === 4 ? 1 : 0; + }, + buttons: null, + relatedTarget: function (event) { + return event.relatedTarget || (event.fromElement === event.srcElement ? event.toElement : event.fromElement); + }, + // "Proprietary" Interface. + pageX: function (event) { + return 'pageX' in event ? event.pageX : event.clientX + ViewportMetrics.currentScrollLeft; + }, + pageY: function (event) { + return 'pageY' in event ? event.pageY : event.clientY + ViewportMetrics.currentScrollTop; + } }; -var TetherContent = function (_React$Component) { - inherits(TetherContent, _React$Component); +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticMouseEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} - function TetherContent(props) { - classCallCheck(this, TetherContent); +SyntheticUIEvent.augmentClass(SyntheticMouseEvent, MouseEventInterface); - var _this = possibleConstructorReturn(this, (TetherContent.__proto__ || Object.getPrototypeOf(TetherContent)).call(this, props)); +module.exports = SyntheticMouseEvent; - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.toggle = _this.toggle.bind(_this); - return _this; - } +/***/ }), +/* 60 */ +/***/ (function(module, exports, __webpack_require__) { - createClass(TetherContent, [{ - key: 'componentDidMount', - value: function componentDidMount() { - this.handleProps(); - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - this.handleProps(); - } else if (this._element) { - // rerender - this.renderIntoSubtree(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.hide(); - } - }, { - key: 'getTarget', - value: function getTarget() { - var target = this.props.tether.target; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if (__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default()(target)) { - return target(); - } - return target; - } - }, { - key: 'getTetherConfig', - value: function getTetherConfig() { - var config = _extends({}, this.props.tether); - config.element = this._element; - config.target = this.getTarget(); - return config; - } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - var container = this._element; - if (e.target === container || !container.contains(e.target)) { - this.toggle(); - } - } - }, { - key: 'handleProps', - value: function handleProps() { - if (this.props.isOpen) { - this.show(); - } else { - this.hide(); - } - } - }, { - key: 'hide', - value: function hide() { - document.removeEventListener('click', this.handleDocumentClick, true); +var ExecutionEnvironment = __webpack_require__(13); +var DOMNamespaces = __webpack_require__(83); - if (this._element) { - document.body.removeChild(this._element); - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); - this._element = null; - } +var WHITESPACE_TEST = /^[ \r\n\t\f]/; +var NONVISIBLE_TEST = /<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/; - if (this._tether) { - this._tether.destroy(); - this._tether = null; - this.props.tetherRef(this._tether); - } - } - }, { - key: 'show', - value: function show() { - document.addEventListener('click', this.handleDocumentClick, true); +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); - this._element = document.createElement('div'); - this._element.className = this.props.className; - document.body.appendChild(this._element); - this.renderIntoSubtree(); - this._tether = new __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default.a(this.getTetherConfig()); - this.props.tetherRef(this._tether); - this._tether.position(); - this._element.childNodes[0].focus(); - } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); - } +// SVG temp container for IE lacking innerHTML +var reusableSVGContainer; - return this.props.toggle(); - } - }, { - key: 'renderIntoSubtree', - value: function renderIntoSubtree() { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); - } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _props = this.props, - children = _props.children, - style = _props.style; - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(children, { style: style }); - } - }, { - key: 'render', - value: function render() { - return null; +/** + * Set the innerHTML property of a node, ensuring that whitespace is preserved + * even in IE8. + * + * @param {DOMElement} node + * @param {string} html + * @internal + */ +var setInnerHTML = createMicrosoftUnsafeLocalFunction(function (node, html) { + // IE does not have innerHTML for SVG nodes, so instead we inject the + // new markup in a temp node and then move the child nodes across into + // the target node + if (node.namespaceURI === DOMNamespaces.svg && !('innerHTML' in node)) { + reusableSVGContainer = reusableSVGContainer || document.createElement('div'); + reusableSVGContainer.innerHTML = '<svg>' + html + '</svg>'; + var svgNode = reusableSVGContainer.firstChild; + while (svgNode.firstChild) { + node.appendChild(svgNode.firstChild); } - }]); - return TetherContent; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - -TetherContent.propTypes = propTypes$10; -TetherContent.defaultProps = defaultProps$10; - -var propTypes$11 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; - -var defaultProps$11 = { - tag: 'div' -}; + } else { + node.innerHTML = html; + } +}); -var contextTypes = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired -}; +if (ExecutionEnvironment.canUseDOM) { + // IE8: When updating a just created node with innerHTML only leading + // whitespace is removed. When updating an existing node with innerHTML + // whitespace in root TextNodes is also collapsed. + // @see quirksmode.org/bugreports/archives/2004/11/innerhtml_and_t.html -var DropdownMenu = function DropdownMenu(props, context) { - var className = props.className, - cssModule = props.cssModule, - right = props.right, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'right', 'tag']); + // Feature detection; only IE8 is known to behave improperly like this. + var testElement = document.createElement('div'); + testElement.innerHTML = ' '; + if (testElement.innerHTML === '') { + setInnerHTML = function (node, html) { + // Magic theory: IE8 supposedly differentiates between added and updated + // nodes when processing innerHTML, innerHTML on updated nodes suffers + // from worse whitespace behavior. Re-adding a node like this triggers + // the initial and more favorable whitespace behavior. + // TODO: What to do on a detached node? + if (node.parentNode) { + node.parentNode.replaceChild(node, node); + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'dropdown-menu', { 'dropdown-menu-right': right }), cssModule); + // We also implement a workaround for non-visible tags disappearing into + // thin air on IE8, this only happens if there is no visible text + // in-front of the non-visible tags. Piggyback on the whitespace fix + // and simply check if any non-visible tags appear in the source. + if (WHITESPACE_TEST.test(html) || html[0] === '<' && NONVISIBLE_TEST.test(html)) { + // Recover leading whitespace by temporarily prepending any character. + // \uFEFF has the potential advantage of being zero-width/invisible. + // UglifyJS drops U+FEFF chars when parsing, so use String.fromCharCode + // in hopes that this is preserved even if "\uFEFF" is transformed to + // the actual Unicode character (by Babel, for example). + // https://github.com/mishoo/UglifyJS2/blob/v2.4.20/lib/parse.js#L216 + node.innerHTML = String.fromCharCode(0xfeff) + html; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { tabIndex: '-1', 'aria-hidden': !context.isOpen, role: 'menu', className: classes })); -}; + // deleteData leaves an empty `TextNode` which offsets the index of all + // children. Definitely want to avoid this. + var textNode = node.firstChild; + if (textNode.data.length === 1) { + node.removeChild(textNode); + } else { + textNode.deleteData(0, 1); + } + } else { + node.innerHTML = html; + } + }; + } + testElement = null; +} -DropdownMenu.propTypes = propTypes$11; -DropdownMenu.defaultProps = defaultProps$11; -DropdownMenu.contextTypes = contextTypes; +module.exports = setInnerHTML; -/* eslint react/no-find-dom-node: 0 */ -// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-find-dom-node.md +/***/ }), +/* 61 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$9 = { - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - dropup: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - group: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool]), - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +"use strict"; +/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * Based on the escape-html library, which is used under the MIT License below: + * + * Copyright (c) 2012-2013 TJ Holowaychuk + * Copyright (c) 2015 Andreas Lubbe + * Copyright (c) 2015 Tiancheng "Timothy" Gu + * + * Permission is hereby granted, free of charge, to any person obtaining + * a copy of this software and associated documentation files (the + * 'Software'), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sublicense, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice shall be + * included in all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. + * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY + * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + */ -var defaultProps$9 = { - isOpen: false, - tag: 'div' -}; -var childContextTypes = { - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired -}; -var defaultTetherConfig = { - classPrefix: 'bs-tether', - classes: { element: 'dropdown', enabled: 'show' }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; +// code copied and modified from escape-html +/** + * Module variables. + * @private + */ -var Dropdown = function (_React$Component) { - inherits(Dropdown, _React$Component); +var matchHtmlRegExp = /["'&<>]/; - function Dropdown(props) { - classCallCheck(this, Dropdown); +/** + * Escape special characters in the given string of html. + * + * @param {string} string The string to escape for inserting into HTML + * @return {string} + * @public + */ - var _this = possibleConstructorReturn(this, (Dropdown.__proto__ || Object.getPrototypeOf(Dropdown)).call(this, props)); +function escapeHtml(string) { + var str = '' + string; + var match = matchHtmlRegExp.exec(str); - _this.addEvents = _this.addEvents.bind(_this); - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.removeEvents = _this.removeEvents.bind(_this); - _this.toggle = _this.toggle.bind(_this); - return _this; + if (!match) { + return str; } - createClass(Dropdown, [{ - key: 'getChildContext', - value: function getChildContext() { - return { - toggle: this.props.toggle, - isOpen: this.props.isOpen - }; - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - this.handleProps(); - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - this.handleProps(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.removeEvents(); - } - }, { - key: 'getTetherTarget', - value: function getTetherTarget() { - var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); - - return container.querySelector('[data-toggle="dropdown"]'); - } - }, { - key: 'getTetherConfig', - value: function getTetherConfig(childProps) { - var _this2 = this; - - var target = function target() { - return _this2.getTetherTarget(); - }; - var vElementAttach = 'top'; - var hElementAttach = 'left'; - var vTargetAttach = 'bottom'; - var hTargetAttach = 'left'; - - if (childProps.right) { - hElementAttach = 'right'; - hTargetAttach = 'right'; - } - - if (this.props.dropup) { - vElementAttach = 'bottom'; - vTargetAttach = 'top'; - } - - return _extends({}, defaultTetherConfig, { - attachment: vElementAttach + ' ' + hElementAttach, - targetAttachment: vTargetAttach + ' ' + hTargetAttach, - target: target - }, this.props.tether); - } - }, { - key: 'addEvents', - value: function addEvents() { - document.addEventListener('click', this.handleDocumentClick, true); - } - }, { - key: 'removeEvents', - value: function removeEvents() { - document.removeEventListener('click', this.handleDocumentClick, true); - } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); - - if (container.contains(e.target) && container !== e.target) { - return; - } - - this.toggle(); - } - }, { - key: 'handleProps', - value: function handleProps() { - if (this.props.tether) { - return; - } + var escape; + var html = ''; + var index = 0; + var lastIndex = 0; - if (this.props.isOpen) { - this.addEvents(); - } else { - this.removeEvents(); - } + for (index = match.index; index < str.length; index++) { + switch (str.charCodeAt(index)) { + case 34: + // " + escape = '"'; + break; + case 38: + // & + escape = '&'; + break; + case 39: + // ' + escape = '''; // modified from escape-html; used to be ''' + break; + case 60: + // < + escape = '<'; + break; + case 62: + // > + escape = '>'; + break; + default: + continue; } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); - } - return this.props.toggle(); + if (lastIndex !== index) { + html += str.substring(lastIndex, index); } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _this3 = this; - var _props = this.props, - tether = _props.tether, - children = _props.children, - attrs = objectWithoutProperties(_props, ['tether', 'children']); - - attrs.toggle = this.toggle; - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.map(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children), function (child) { - if (tether && child.type === DropdownMenu) { - var tetherConfig = _this3.getTetherConfig(child.props); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - _extends({}, attrs, { tether: tetherConfig }), - child - ); - } + lastIndex = index + 1; + html += escape; + } - return child; - }); - } - }, { - key: 'render', - value: function render() { - var _classNames; + return lastIndex !== index ? html + str.substring(lastIndex, index) : html; +} +// end code copied and modified from escape-html - var _omit = omit(this.props, ['toggle', 'tether']), - className = _omit.className, - cssModule = _omit.cssModule, - dropup = _omit.dropup, - group = _omit.group, - size = _omit.size, - Tag = _omit.tag, - isOpen = _omit.isOpen, - attributes = objectWithoutProperties(_omit, ['className', 'cssModule', 'dropup', 'group', 'size', 'tag', 'isOpen']); +/** + * Escapes text to prevent scripting attacks. + * + * @param {*} text Text value to escape. + * @return {string} An escaped string. + */ +function escapeTextContentForBrowser(text) { + if (typeof text === 'boolean' || typeof text === 'number') { + // this shortcircuit helps perf for types that we know will never have + // special characters, especially given that this function is used often + // for numeric dom ids. + return '' + text; + } + return escapeHtml(text); +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, (_classNames = { - 'btn-group': group - }, defineProperty(_classNames, 'btn-group-' + size, !!size), defineProperty(_classNames, 'dropdown', !group), defineProperty(_classNames, 'show', isOpen), defineProperty(_classNames, 'dropup', dropup), _classNames)), cssModule); +module.exports = escapeTextContentForBrowser; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { - className: classes - }), - this.renderChildren() - ); - } - }]); - return Dropdown; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +/***/ }), +/* 62 */ +/***/ (function(module, exports, __webpack_require__) { -Dropdown.propTypes = propTypes$9; -Dropdown.defaultProps = defaultProps$9; -Dropdown.childContextTypes = childContextTypes; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var propTypes$8 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$8 = { - tag: 'li' -}; -var NavDropdown = function NavDropdown(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +var _assign = __webpack_require__(8); +var EventPluginRegistry = __webpack_require__(57); +var ReactEventEmitterMixin = __webpack_require__(264); +var ViewportMetrics = __webpack_require__(134); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); +var getVendorPrefixedEventName = __webpack_require__(265); +var isEventSupported = __webpack_require__(80); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({}, attributes, { tag: Tag, className: classes })); -}; +/** + * Summary of `ReactBrowserEventEmitter` event handling: + * + * - Top-level delegation is used to trap most native browser events. This + * may only occur in the main thread and is the responsibility of + * ReactEventListener, which is injected and can therefore support pluggable + * event sources. This is the only work that occurs in the main thread. + * + * - We normalize and de-duplicate events to account for browser quirks. This + * may be done in the worker thread. + * + * - Forward these native events (with the associated top-level type used to + * trap it) to `EventPluginHub`, which in turn will ask plugins if they want + * to extract any synthetic events. + * + * - The `EventPluginHub` will then process each event by annotating them with + * "dispatches", a sequence of listeners and IDs that care about that event. + * + * - The `EventPluginHub` then dispatches the events. + * + * Overview of React and the event system: + * + * +------------+ . + * | DOM | . + * +------------+ . + * | . + * v . + * +------------+ . + * | ReactEvent | . + * | Listener | . + * +------------+ . +-----------+ + * | . +--------+|SimpleEvent| + * | . | |Plugin | + * +-----|------+ . v +-----------+ + * | | | . +--------------+ +------------+ + * | +-----------.--->|EventPluginHub| | Event | + * | | . | | +-----------+ | Propagators| + * | ReactEvent | . | | |TapEvent | |------------| + * | Emitter | . | |<---+|Plugin | |other plugin| + * | | . | | +-----------+ | utilities | + * | +-----------.--->| | +------------+ + * | | | . +--------------+ + * +-----|------+ . ^ +-----------+ + * | . | |Enter/Leave| + * + . +-------+|Plugin | + * +-------------+ . +-----------+ + * | application | . + * |-------------| . + * | | . + * | | . + * +-------------+ . + * . + * React Core . General Purpose Event Plugin System + */ -NavDropdown.propTypes = propTypes$8; -NavDropdown.defaultProps = defaultProps$8; +var hasEventPageXY; +var alreadyListeningTo = {}; +var isMonitoringScrollValue = false; +var reactTopListenersCounter = 0; -var propTypes$12 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - href: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +// For events like 'submit' which don't consistently bubble (which we trap at a +// lower node than `document`), binding at `document` would cause duplicate +// events so we don't include them here +var topEventMapping = { + topAbort: 'abort', + topAnimationEnd: getVendorPrefixedEventName('animationend') || 'animationend', + topAnimationIteration: getVendorPrefixedEventName('animationiteration') || 'animationiteration', + topAnimationStart: getVendorPrefixedEventName('animationstart') || 'animationstart', + topBlur: 'blur', + topCanPlay: 'canplay', + topCanPlayThrough: 'canplaythrough', + topChange: 'change', + topClick: 'click', + topCompositionEnd: 'compositionend', + topCompositionStart: 'compositionstart', + topCompositionUpdate: 'compositionupdate', + topContextMenu: 'contextmenu', + topCopy: 'copy', + topCut: 'cut', + topDoubleClick: 'dblclick', + topDrag: 'drag', + topDragEnd: 'dragend', + topDragEnter: 'dragenter', + topDragExit: 'dragexit', + topDragLeave: 'dragleave', + topDragOver: 'dragover', + topDragStart: 'dragstart', + topDrop: 'drop', + topDurationChange: 'durationchange', + topEmptied: 'emptied', + topEncrypted: 'encrypted', + topEnded: 'ended', + topError: 'error', + topFocus: 'focus', + topInput: 'input', + topKeyDown: 'keydown', + topKeyPress: 'keypress', + topKeyUp: 'keyup', + topLoadedData: 'loadeddata', + topLoadedMetadata: 'loadedmetadata', + topLoadStart: 'loadstart', + topMouseDown: 'mousedown', + topMouseMove: 'mousemove', + topMouseOut: 'mouseout', + topMouseOver: 'mouseover', + topMouseUp: 'mouseup', + topPaste: 'paste', + topPause: 'pause', + topPlay: 'play', + topPlaying: 'playing', + topProgress: 'progress', + topRateChange: 'ratechange', + topScroll: 'scroll', + topSeeked: 'seeked', + topSeeking: 'seeking', + topSelectionChange: 'selectionchange', + topStalled: 'stalled', + topSuspend: 'suspend', + topTextInput: 'textInput', + topTimeUpdate: 'timeupdate', + topTouchCancel: 'touchcancel', + topTouchEnd: 'touchend', + topTouchMove: 'touchmove', + topTouchStart: 'touchstart', + topTransitionEnd: getVendorPrefixedEventName('transitionend') || 'transitionend', + topVolumeChange: 'volumechange', + topWaiting: 'waiting', + topWheel: 'wheel' }; -var defaultProps$12 = { - tag: 'a' -}; +/** + * To ensure no conflicts with other potential React instances on the page + */ +var topListenersIDKey = '_reactListenersID' + String(Math.random()).slice(2); -var NavLink = function (_React$Component) { - inherits(NavLink, _React$Component); +function getListeningForDocument(mountAt) { + // In IE8, `mountAt` is a host object and doesn't have `hasOwnProperty` + // directly. + if (!Object.prototype.hasOwnProperty.call(mountAt, topListenersIDKey)) { + mountAt[topListenersIDKey] = reactTopListenersCounter++; + alreadyListeningTo[mountAt[topListenersIDKey]] = {}; + } + return alreadyListeningTo[mountAt[topListenersIDKey]]; +} - function NavLink(props) { - classCallCheck(this, NavLink); +/** + * `ReactBrowserEventEmitter` is used to attach top-level event listeners. For + * example: + * + * EventPluginHub.putListener('myID', 'onClick', myFunction); + * + * This would allocate a "registration" of `('onClick', myFunction)` on 'myID'. + * + * @internal + */ +var ReactBrowserEventEmitter = _assign({}, ReactEventEmitterMixin, { + /** + * Injectable event backend + */ + ReactEventListener: null, - var _this = possibleConstructorReturn(this, (NavLink.__proto__ || Object.getPrototypeOf(NavLink)).call(this, props)); + injection: { + /** + * @param {object} ReactEventListener + */ + injectReactEventListener: function (ReactEventListener) { + ReactEventListener.setHandleTopLevel(ReactBrowserEventEmitter.handleTopLevel); + ReactBrowserEventEmitter.ReactEventListener = ReactEventListener; + } + }, - _this.onClick = _this.onClick.bind(_this); - return _this; - } + /** + * Sets whether or not any created callbacks should be enabled. + * + * @param {boolean} enabled True if callbacks should be enabled. + */ + setEnabled: function (enabled) { + if (ReactBrowserEventEmitter.ReactEventListener) { + ReactBrowserEventEmitter.ReactEventListener.setEnabled(enabled); + } + }, - createClass(NavLink, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } + /** + * @return {boolean} True if callbacks are enabled. + */ + isEnabled: function () { + return !!(ReactBrowserEventEmitter.ReactEventListener && ReactBrowserEventEmitter.ReactEventListener.isEnabled()); + }, - if (this.props.href === '#') { - e.preventDefault(); - } + /** + * We listen for bubbled touch events on the document object. + * + * Firefox v8.01 (and possibly others) exhibited strange behavior when + * mounting `onmousemove` events at some node that was not the document + * element. The symptoms were that if your mouse is not moving over something + * contained within that mount point (for example on the background) the + * top-level listeners for `onmousemove` won't be called. However, if you + * register the `mousemove` on the document object, then it will of course + * catch all `mousemove`s. This along with iOS quirks, justifies restricting + * top-level listeners to the document object only, at least for these + * movement types of events and possibly all events. + * + * @see http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html + * + * Also, `keyup`/`keypress`/`keydown` do not bubble to the window on IE, but + * they bubble to document. + * + * @param {string} registrationName Name of listener (e.g. `onClick`). + * @param {object} contentDocumentHandle Document which owns the container + */ + listenTo: function (registrationName, contentDocumentHandle) { + var mountAt = contentDocumentHandle; + var isListening = getListeningForDocument(mountAt); + var dependencies = EventPluginRegistry.registrationNameDependencies[registrationName]; - if (this.props.onClick) { - this.props.onClick(e); + for (var i = 0; i < dependencies.length; i++) { + var dependency = dependencies[i]; + if (!(isListening.hasOwnProperty(dependency) && isListening[dependency])) { + if (dependency === 'topWheel') { + if (isEventSupported('wheel')) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'wheel', mountAt); + } else if (isEventSupported('mousewheel')) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'mousewheel', mountAt); + } else { + // Firefox needs to capture a different mouse scroll event. + // @see http://www.quirksmode.org/dom/events/tests/scroll.html + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topWheel', 'DOMMouseScroll', mountAt); + } + } else if (dependency === 'topScroll') { + if (isEventSupported('scroll', true)) { + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topScroll', 'scroll', mountAt); + } else { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topScroll', 'scroll', ReactBrowserEventEmitter.ReactEventListener.WINDOW_HANDLE); + } + } else if (dependency === 'topFocus' || dependency === 'topBlur') { + if (isEventSupported('focus', true)) { + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topFocus', 'focus', mountAt); + ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent('topBlur', 'blur', mountAt); + } else if (isEventSupported('focusin')) { + // IE has `focusin` and `focusout` events which bubble. + // @see http://www.quirksmode.org/blog/archives/2008/04/delegating_the.html + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topFocus', 'focusin', mountAt); + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent('topBlur', 'focusout', mountAt); + } + + // to make sure blur and focus event listeners are only attached once + isListening.topBlur = true; + isListening.topFocus = true; + } else if (topEventMapping.hasOwnProperty(dependency)) { + ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(dependency, topEventMapping[dependency], mountAt); + } + + isListening[dependency] = true; } } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - active = _props.active, - Tag = _props.tag, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'active', 'tag', 'getRef']); + }, + trapBubbledEvent: function (topLevelType, handlerBaseName, handle) { + return ReactBrowserEventEmitter.ReactEventListener.trapBubbledEvent(topLevelType, handlerBaseName, handle); + }, - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-link', { - disabled: attributes.disabled, - active: active - }), cssModule); + trapCapturedEvent: function (topLevelType, handlerBaseName, handle) { + return ReactBrowserEventEmitter.ReactEventListener.trapCapturedEvent(topLevelType, handlerBaseName, handle); + }, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, onClick: this.onClick, className: classes })); + /** + * Protect against document.createEvent() returning null + * Some popup blocker extensions appear to do this: + * https://github.com/facebook/react/issues/6887 + */ + supportsEventPageXY: function () { + if (!document.createEvent) { + return false; } - }]); - return NavLink; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + var ev = document.createEvent('MouseEvent'); + return ev != null && 'pageX' in ev; + }, -NavLink.propTypes = propTypes$12; -NavLink.defaultProps = defaultProps$12; + /** + * Listens to window scroll and resize events. We cache scroll values so that + * application code can access them without triggering reflows. + * + * ViewportMetrics is only used by SyntheticMouse/TouchEvent and only when + * pageX/pageY isn't supported (legacy browsers). + * + * NOTE: Scroll events do not bubble. + * + * @see http://www.quirksmode.org/dom/events/scroll.html + */ + ensureScrollValueMonitoring: function () { + if (hasEventPageXY === undefined) { + hasEventPageXY = ReactBrowserEventEmitter.supportsEventPageXY(); + } + if (!hasEventPageXY && !isMonitoringScrollValue) { + var refresh = ViewportMetrics.refreshScrollValues; + ReactBrowserEventEmitter.ReactEventListener.monitorScrollValue(refresh); + isMonitoringScrollValue = true; + } + } +}); -var propTypes$13 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +module.exports = ReactBrowserEventEmitter; -var defaultProps$13 = { - tag: 'ol' -}; +/***/ }), +/* 63 */ +/***/ (function(module, exports, __webpack_require__) { -var Breadcrumb = function Breadcrumb(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +"use strict"; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'breadcrumb'), cssModule); +/* + * A JavaScript implementation of the RSA Data Security, Inc. MD5 Message + * Digest Algorithm, as defined in RFC 1321. + * Version 2.1 Copyright (C) Paul Johnston 1999 - 2002. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet + * Distributed under the BSD License + * See http://pajhome.org.uk/crypt/md5 for more info. + */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var makeHash = __webpack_require__(365) -Breadcrumb.propTypes = propTypes$13; -Breadcrumb.defaultProps = defaultProps$13; +/* + * Calculate the MD5 of an array of little-endian words, and a bit length + */ +function core_md5 (x, len) { + /* append padding */ + x[len >> 5] |= 0x80 << ((len) % 32) + x[(((len + 64) >>> 9) << 4) + 14] = len -var propTypes$14 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var a = 1732584193 + var b = -271733879 + var c = -1732584194 + var d = 271733878 -var defaultProps$14 = { - tag: 'li' -}; + for (var i = 0; i < x.length; i += 16) { + var olda = a + var oldb = b + var oldc = c + var oldd = d -var BreadcrumbItem = function BreadcrumbItem(props) { - var className = props.className, - cssModule = props.cssModule, - active = props.active, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'active', 'tag']); + a = md5_ff(a, b, c, d, x[i + 0], 7, -680876936) + d = md5_ff(d, a, b, c, x[i + 1], 12, -389564586) + c = md5_ff(c, d, a, b, x[i + 2], 17, 606105819) + b = md5_ff(b, c, d, a, x[i + 3], 22, -1044525330) + a = md5_ff(a, b, c, d, x[i + 4], 7, -176418897) + d = md5_ff(d, a, b, c, x[i + 5], 12, 1200080426) + c = md5_ff(c, d, a, b, x[i + 6], 17, -1473231341) + b = md5_ff(b, c, d, a, x[i + 7], 22, -45705983) + a = md5_ff(a, b, c, d, x[i + 8], 7, 1770035416) + d = md5_ff(d, a, b, c, x[i + 9], 12, -1958414417) + c = md5_ff(c, d, a, b, x[i + 10], 17, -42063) + b = md5_ff(b, c, d, a, x[i + 11], 22, -1990404162) + a = md5_ff(a, b, c, d, x[i + 12], 7, 1804603682) + d = md5_ff(d, a, b, c, x[i + 13], 12, -40341101) + c = md5_ff(c, d, a, b, x[i + 14], 17, -1502002290) + b = md5_ff(b, c, d, a, x[i + 15], 22, 1236535329) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, 'breadcrumb-item'), cssModule); + a = md5_gg(a, b, c, d, x[i + 1], 5, -165796510) + d = md5_gg(d, a, b, c, x[i + 6], 9, -1069501632) + c = md5_gg(c, d, a, b, x[i + 11], 14, 643717713) + b = md5_gg(b, c, d, a, x[i + 0], 20, -373897302) + a = md5_gg(a, b, c, d, x[i + 5], 5, -701558691) + d = md5_gg(d, a, b, c, x[i + 10], 9, 38016083) + c = md5_gg(c, d, a, b, x[i + 15], 14, -660478335) + b = md5_gg(b, c, d, a, x[i + 4], 20, -405537848) + a = md5_gg(a, b, c, d, x[i + 9], 5, 568446438) + d = md5_gg(d, a, b, c, x[i + 14], 9, -1019803690) + c = md5_gg(c, d, a, b, x[i + 3], 14, -187363961) + b = md5_gg(b, c, d, a, x[i + 8], 20, 1163531501) + a = md5_gg(a, b, c, d, x[i + 13], 5, -1444681467) + d = md5_gg(d, a, b, c, x[i + 2], 9, -51403784) + c = md5_gg(c, d, a, b, x[i + 7], 14, 1735328473) + b = md5_gg(b, c, d, a, x[i + 12], 20, -1926607734) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + a = md5_hh(a, b, c, d, x[i + 5], 4, -378558) + d = md5_hh(d, a, b, c, x[i + 8], 11, -2022574463) + c = md5_hh(c, d, a, b, x[i + 11], 16, 1839030562) + b = md5_hh(b, c, d, a, x[i + 14], 23, -35309556) + a = md5_hh(a, b, c, d, x[i + 1], 4, -1530992060) + d = md5_hh(d, a, b, c, x[i + 4], 11, 1272893353) + c = md5_hh(c, d, a, b, x[i + 7], 16, -155497632) + b = md5_hh(b, c, d, a, x[i + 10], 23, -1094730640) + a = md5_hh(a, b, c, d, x[i + 13], 4, 681279174) + d = md5_hh(d, a, b, c, x[i + 0], 11, -358537222) + c = md5_hh(c, d, a, b, x[i + 3], 16, -722521979) + b = md5_hh(b, c, d, a, x[i + 6], 23, 76029189) + a = md5_hh(a, b, c, d, x[i + 9], 4, -640364487) + d = md5_hh(d, a, b, c, x[i + 12], 11, -421815835) + c = md5_hh(c, d, a, b, x[i + 15], 16, 530742520) + b = md5_hh(b, c, d, a, x[i + 2], 23, -995338651) -BreadcrumbItem.propTypes = propTypes$14; -BreadcrumbItem.defaultProps = defaultProps$14; + a = md5_ii(a, b, c, d, x[i + 0], 6, -198630844) + d = md5_ii(d, a, b, c, x[i + 7], 10, 1126891415) + c = md5_ii(c, d, a, b, x[i + 14], 15, -1416354905) + b = md5_ii(b, c, d, a, x[i + 5], 21, -57434055) + a = md5_ii(a, b, c, d, x[i + 12], 6, 1700485571) + d = md5_ii(d, a, b, c, x[i + 3], 10, -1894986606) + c = md5_ii(c, d, a, b, x[i + 10], 15, -1051523) + b = md5_ii(b, c, d, a, x[i + 1], 21, -2054922799) + a = md5_ii(a, b, c, d, x[i + 8], 6, 1873313359) + d = md5_ii(d, a, b, c, x[i + 15], 10, -30611744) + c = md5_ii(c, d, a, b, x[i + 6], 15, -1560198380) + b = md5_ii(b, c, d, a, x[i + 13], 21, 1309151649) + a = md5_ii(a, b, c, d, x[i + 4], 6, -145523070) + d = md5_ii(d, a, b, c, x[i + 11], 10, -1120210379) + c = md5_ii(c, d, a, b, x[i + 2], 15, 718787259) + b = md5_ii(b, c, d, a, x[i + 9], 21, -343485551) -var propTypes$15 = { - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + a = safe_add(a, olda) + b = safe_add(b, oldb) + c = safe_add(c, oldc) + d = safe_add(d, oldd) + } -var defaultProps$15 = { - color: 'secondary', - tag: 'button' -}; + return [a, b, c, d] +} -var Button = function (_React$Component) { - inherits(Button, _React$Component); +/* + * These functions implement the four basic operations the algorithm uses. + */ +function md5_cmn (q, a, b, x, s, t) { + return safe_add(bit_rol(safe_add(safe_add(a, q), safe_add(x, t)), s), b) +} - function Button(props) { - classCallCheck(this, Button); +function md5_ff (a, b, c, d, x, s, t) { + return md5_cmn((b & c) | ((~b) & d), a, b, x, s, t) +} - var _this = possibleConstructorReturn(this, (Button.__proto__ || Object.getPrototypeOf(Button)).call(this, props)); +function md5_gg (a, b, c, d, x, s, t) { + return md5_cmn((b & d) | (c & (~d)), a, b, x, s, t) +} - _this.onClick = _this.onClick.bind(_this); - return _this; - } +function md5_hh (a, b, c, d, x, s, t) { + return md5_cmn(b ^ c ^ d, a, b, x, s, t) +} - createClass(Button, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } +function md5_ii (a, b, c, d, x, s, t) { + return md5_cmn(c ^ (b | (~d)), a, b, x, s, t) +} - if (this.props.onClick) { - this.props.onClick(e); - } - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - active = _props.active, - block = _props.block, - className = _props.className, - cssModule = _props.cssModule, - color = _props.color, - outline = _props.outline, - size = _props.size, - Tag = _props.tag, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['active', 'block', 'className', 'cssModule', 'color', 'outline', 'size', 'tag', 'getRef']); +/* + * Add integers, wrapping at 2^32. This uses 16-bit operations internally + * to work around bugs in some JS interpreters. + */ +function safe_add (x, y) { + var lsw = (x & 0xFFFF) + (y & 0xFFFF) + var msw = (x >> 16) + (y >> 16) + (lsw >> 16) + return (msw << 16) | (lsw & 0xFFFF) +} +/* + * Bitwise rotate a 32-bit number to the left. + */ +function bit_rol (num, cnt) { + return (num << cnt) | (num >>> (32 - cnt)) +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn', 'btn' + (outline ? '-outline' : '') + '-' + color, size ? 'btn-' + size : false, block ? 'btn-block' : false, { active: active, disabled: this.props.disabled }), cssModule); +module.exports = function md5 (buf) { + return makeHash(buf, core_md5) +} - if (attributes.href && Tag === 'button') { - Tag = 'a'; - } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ - type: Tag === 'button' && attributes.onClick ? 'button' : undefined - }, attributes, { - className: classes, - ref: getRef, - onClick: this.onClick - })); - } - }]); - return Button; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +/***/ }), +/* 64 */ +/***/ (function(module, exports, __webpack_require__) { -Button.propTypes = propTypes$15; -Button.defaultProps = defaultProps$15; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { -var propTypes$16 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node -}; +if (!process.version || + process.version.indexOf('v0.') === 0 || + process.version.indexOf('v1.') === 0 && process.version.indexOf('v1.8.') !== 0) { + module.exports = nextTick; +} else { + module.exports = process.nextTick; +} -var ButtonDropdown = function ButtonDropdown(props) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({ group: true }, props)); -}; +function nextTick(fn, arg1, arg2, arg3) { + if (typeof fn !== 'function') { + throw new TypeError('"callback" argument must be a function'); + } + var len = arguments.length; + var args, i; + switch (len) { + case 0: + case 1: + return process.nextTick(fn); + case 2: + return process.nextTick(function afterTickOne() { + fn.call(null, arg1); + }); + case 3: + return process.nextTick(function afterTickTwo() { + fn.call(null, arg1, arg2); + }); + case 4: + return process.nextTick(function afterTickThree() { + fn.call(null, arg1, arg2, arg3); + }); + default: + args = new Array(len - 1); + i = 0; + while (i < args.length) { + args[i++] = arguments[i]; + } + return process.nextTick(function afterTick() { + fn.apply(null, args); + }); + } +} -ButtonDropdown.propTypes = propTypes$16; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var propTypes$17 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +/***/ }), +/* 65 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$16 = { - tag: 'div', - role: 'group' -}; +"use strict"; -var ButtonGroup = function ButtonGroup(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - vertical = props.vertical, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'vertical', 'tag']); +var curve = exports; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, size ? 'btn-group-' + size : false, vertical ? 'btn-group-vertical' : 'btn-group'), cssModule); +curve.base = __webpack_require__(388); +curve.short = __webpack_require__(389); +curve.mont = __webpack_require__(390); +curve.edwards = __webpack_require__(391); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -ButtonGroup.propTypes = propTypes$17; -ButtonGroup.defaultProps = defaultProps$16; +/***/ }), +/* 66 */ +/***/ (function(module, exports) { -var propTypes$18 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string -}; +/* +config.js - Configuration for ZENCash Coin +*/ -var defaultProps$17 = { - tag: 'div', - role: 'toolbar' +module.exports = { + mainnet: { + messagePrefix: 'ZENCash main net', + bip32: { + public: '0488b21e', + private: '0488ade4' + }, + pubKeyHash: '2089', + scriptHash: '2096', + zcPaymentAddressHash: '169a', // Private z-address + zcSpendingKeyHash: 'ab36', // Spending key + wif: '80' + }, + testnet: { + wif: 'ef', + pubKeyHash: '2098' + } }; -var ButtonToolbar = function ButtonToolbar(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/***/ }), +/* 67 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn-toolbar'), cssModule); +var inherits = __webpack_require__(4) +var Legacy = __webpack_require__(420) +var Base = __webpack_require__(29) +var Buffer = __webpack_require__(7).Buffer +var md5 = __webpack_require__(63) +var RIPEMD160 = __webpack_require__(97) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var sha = __webpack_require__(103) -ButtonToolbar.propTypes = propTypes$18; -ButtonToolbar.defaultProps = defaultProps$17; +var ZEROS = Buffer.alloc(128) -var propTypes$19 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - divider: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - header: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; +function Hmac (alg, key) { + Base.call(this, 'digest') + if (typeof key === 'string') { + key = Buffer.from(key) + } -var contextTypes$1 = { - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; + var blocksize = (alg === 'sha512' || alg === 'sha384') ? 128 : 64 -var defaultProps$18 = { - tag: 'button', - toggle: true -}; + this._alg = alg + this._key = key + if (key.length > blocksize) { + var hash = alg === 'rmd160' ? new RIPEMD160() : sha(alg) + key = hash.update(key).digest() + } else if (key.length < blocksize) { + key = Buffer.concat([key, ZEROS], blocksize) + } -var DropdownItem = function (_React$Component) { - inherits(DropdownItem, _React$Component); + var ipad = this._ipad = Buffer.allocUnsafe(blocksize) + var opad = this._opad = Buffer.allocUnsafe(blocksize) - function DropdownItem(props) { - classCallCheck(this, DropdownItem); + for (var i = 0; i < blocksize; i++) { + ipad[i] = key[i] ^ 0x36 + opad[i] = key[i] ^ 0x5C + } + this._hash = alg === 'rmd160' ? new RIPEMD160() : sha(alg) + this._hash.update(ipad) +} - var _this = possibleConstructorReturn(this, (DropdownItem.__proto__ || Object.getPrototypeOf(DropdownItem)).call(this, props)); +inherits(Hmac, Base) - _this.onClick = _this.onClick.bind(_this); - _this.getTabIndex = _this.getTabIndex.bind(_this); - return _this; +Hmac.prototype._update = function (data) { + this._hash.update(data) +} + +Hmac.prototype._final = function () { + var h = this._hash.digest() + var hash = this._alg === 'rmd160' ? new RIPEMD160() : sha(this._alg) + return hash.update(this._opad).update(h).digest() +} + +module.exports = function createHmac (alg, key) { + alg = alg.toLowerCase() + if (alg === 'rmd160' || alg === 'ripemd160') { + return new Hmac('rmd160', key) + } + if (alg === 'md5') { + return new Legacy(md5, key) } + return new Hmac(alg, key) +} - createClass(DropdownItem, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled || this.props.header || this.props.divider) { - e.preventDefault(); - return; - } - if (this.props.onClick) { - this.props.onClick(e); - } +/***/ }), +/* 68 */ +/***/ (function(module, exports, __webpack_require__) { - if (this.props.toggle) { - this.context.toggle(); - } +/* WEBPACK VAR INJECTION */(function(Buffer) {var md5 = __webpack_require__(63) +module.exports = EVP_BytesToKey +function EVP_BytesToKey (password, salt, keyLen, ivLen) { + if (!Buffer.isBuffer(password)) { + password = new Buffer(password, 'binary') + } + if (salt && !Buffer.isBuffer(salt)) { + salt = new Buffer(salt, 'binary') + } + keyLen = keyLen / 8 + ivLen = ivLen || 0 + var ki = 0 + var ii = 0 + var key = new Buffer(keyLen) + var iv = new Buffer(ivLen) + var addmd = 0 + var md_buf + var i + var bufs = [] + while (true) { + if (addmd++ > 0) { + bufs.push(md_buf) } - }, { - key: 'getTabIndex', - value: function getTabIndex() { - if (this.props.disabled || this.props.header || this.props.divider) { - return '-1'; + bufs.push(password) + if (salt) { + bufs.push(salt) + } + md_buf = md5(Buffer.concat(bufs)) + bufs = [] + i = 0 + if (keyLen > 0) { + while (true) { + if (keyLen === 0) { + break + } + if (i === md_buf.length) { + break + } + key[ki++] = md_buf[i] + keyLen-- + i++ } - - return '0'; } - }, { - key: 'render', - value: function render() { - var tabIndex = this.getTabIndex(); - - var _omit = omit(this.props, ['toggle']), - className = _omit.className, - cssModule = _omit.cssModule, - divider = _omit.divider, - Tag = _omit.tag, - header = _omit.header, - active = _omit.active, - props = objectWithoutProperties(_omit, ['className', 'cssModule', 'divider', 'tag', 'header', 'active']); - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - disabled: props.disabled, - 'dropdown-item': !divider && !header, - active: active, - 'dropdown-header': header, - 'dropdown-divider': divider - }), cssModule); - - if (Tag === 'button') { - if (header) { - Tag = 'h6'; - } else if (divider) { - Tag = 'div'; - } else if (props.href) { - Tag = 'a'; + if (ivLen > 0 && i !== md_buf.length) { + while (true) { + if (ivLen === 0) { + break + } + if (i === md_buf.length) { + break } + iv[ii++] = md_buf[i] + ivLen-- + i++ } - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ - type: Tag === 'button' && (props.onClick || this.props.toggle) ? 'button' : undefined - }, props, { - tabIndex: tabIndex, - className: classes, - onClick: this.onClick - })); } - }]); - return DropdownItem; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - -DropdownItem.propTypes = propTypes$19; -DropdownItem.defaultProps = defaultProps$18; -DropdownItem.contextTypes = contextTypes$1; - -var propTypes$20 = { - caret: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - 'data-toggle': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - 'aria-haspopup': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - split: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - nav: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; - -var defaultProps$19 = { - 'data-toggle': 'dropdown', - 'aria-haspopup': true, - color: 'secondary' -}; + if (keyLen === 0 && ivLen === 0) { + break + } + } + for (i = 0; i < md_buf.length; i++) { + md_buf[i] = 0 + } + return { + key: key, + iv: iv + } +} -var contextTypes$2 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var DropdownToggle = function (_React$Component) { - inherits(DropdownToggle, _React$Component); +/***/ }), +/* 69 */ +/***/ (function(module, exports, __webpack_require__) { - function DropdownToggle(props) { - classCallCheck(this, DropdownToggle); +/* WEBPACK VAR INJECTION */(function(Buffer) {// based on the aes implimentation in triple sec +// https://github.com/keybase/triplesec - var _this = possibleConstructorReturn(this, (DropdownToggle.__proto__ || Object.getPrototypeOf(DropdownToggle)).call(this, props)); +// which is in turn based on the one from crypto-js +// https://code.google.com/p/crypto-js/ - _this.onClick = _this.onClick.bind(_this); - return _this; +var uint_max = Math.pow(2, 32) +function fixup_uint32 (x) { + var ret, x_pos + ret = x > uint_max || x < 0 ? (x_pos = Math.abs(x) % uint_max, x < 0 ? uint_max - x_pos : x_pos) : x + return ret +} +function scrub_vec (v) { + for (var i = 0; i < v.length; v++) { + v[i] = 0 } + return false +} - createClass(DropdownToggle, [{ - key: 'onClick', - value: function onClick(e) { - if (this.props.disabled) { - e.preventDefault(); - return; - } - - if (this.props.nav && !this.props.tag) { - e.preventDefault(); - } +function Global () { + this.SBOX = [] + this.INV_SBOX = [] + this.SUB_MIX = [[], [], [], []] + this.INV_SUB_MIX = [[], [], [], []] + this.init() + this.RCON = [0x00, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x1b, 0x36] +} - if (this.props.onClick) { - this.props.onClick(e); +Global.prototype.init = function () { + var d, i, sx, t, x, x2, x4, x8, xi, _i + d = (function () { + var _i, _results + _results = [] + for (i = _i = 0; _i < 256; i = ++_i) { + if (i < 128) { + _results.push(i << 1) + } else { + _results.push((i << 1) ^ 0x11b) } - - this.context.toggle(); } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - color = _props.color, - cssModule = _props.cssModule, - caret = _props.caret, - split = _props.split, - nav = _props.nav, - tag = _props.tag, - props = objectWithoutProperties(_props, ['className', 'color', 'cssModule', 'caret', 'split', 'nav', 'tag']); - - var ariaLabel = props['aria-label'] || 'Toggle Dropdown'; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - 'dropdown-toggle': caret || split, - 'dropdown-toggle-split': split, - active: this.context.isOpen, - 'nav-link': nav - }), cssModule); - var children = props.children || __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { className: 'sr-only' }, - ariaLabel - ); + return _results + })() + x = 0 + xi = 0 + for (i = _i = 0; _i < 256; i = ++_i) { + sx = xi ^ (xi << 1) ^ (xi << 2) ^ (xi << 3) ^ (xi << 4) + sx = (sx >>> 8) ^ (sx & 0xff) ^ 0x63 + this.SBOX[x] = sx + this.INV_SBOX[sx] = x + x2 = d[x] + x4 = d[x2] + x8 = d[x4] + t = (d[sx] * 0x101) ^ (sx * 0x1010100) + this.SUB_MIX[0][x] = (t << 24) | (t >>> 8) + this.SUB_MIX[1][x] = (t << 16) | (t >>> 16) + this.SUB_MIX[2][x] = (t << 8) | (t >>> 24) + this.SUB_MIX[3][x] = t + t = (x8 * 0x1010101) ^ (x4 * 0x10001) ^ (x2 * 0x101) ^ (x * 0x1010100) + this.INV_SUB_MIX[0][sx] = (t << 24) | (t >>> 8) + this.INV_SUB_MIX[1][sx] = (t << 16) | (t >>> 16) + this.INV_SUB_MIX[2][sx] = (t << 8) | (t >>> 24) + this.INV_SUB_MIX[3][sx] = t + if (x === 0) { + x = xi = 1 + } else { + x = x2 ^ d[d[d[x8 ^ x2]]] + xi ^= d[d[xi]] + } + } + return true +} - var Tag = void 0; +var G = new Global() - if (nav && !tag) { - Tag = 'a'; - props.href = '#'; - } else if (!tag) { - Tag = Button; - props.color = color; - } else { - Tag = tag; - } +AES.blockSize = 4 * 4 - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, props, { - className: classes, - onClick: this.onClick, - 'aria-haspopup': 'true', - 'aria-expanded': this.context.isOpen, - children: children - })); - } - }]); - return DropdownToggle; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +AES.prototype.blockSize = AES.blockSize -DropdownToggle.propTypes = propTypes$20; -DropdownToggle.defaultProps = defaultProps$19; -DropdownToggle.contextTypes = contextTypes$2; +AES.keySize = 256 / 8 -var propTypes$21 = { - baseClass: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - baseClassIn: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionAppear: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - transitionEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - transitionLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - onLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; +AES.prototype.keySize = AES.keySize -var defaultProps$20 = { - tag: 'div', - baseClass: 'fade', - baseClassIn: 'show', - transitionAppearTimeout: 0, - transitionEnterTimeout: 0, - transitionLeaveTimeout: 0, - transitionAppear: true, - transitionEnter: true, - transitionLeave: true -}; - -var Fade = function (_React$Component) { - inherits(Fade, _React$Component); - - function Fade(props) { - classCallCheck(this, Fade); - - var _this = possibleConstructorReturn(this, (Fade.__proto__ || Object.getPrototypeOf(Fade)).call(this, props)); - - _this.state = { - mounted: !props.transitionAppear - }; - - _this.onLeave = _this.onLeave.bind(_this); - _this.onEnter = _this.onEnter.bind(_this); - _this.timers = []; - return _this; +function bufferToArray (buf) { + var len = buf.length / 4 + var out = new Array(len) + var i = -1 + while (++i < len) { + out[i] = buf.readUInt32BE(i * 4) } + return out +} +function AES (key) { + this._key = bufferToArray(key) + this._doReset() +} - createClass(Fade, [{ - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.timers.forEach(function (timer) { - return clearTimeout(timer); - }); - } - }, { - key: 'onEnter', - value: function onEnter(cb) { - var _this2 = this; - - return function () { - cb(); - if (_this2.props.onEnter) { - _this2.props.onEnter(); - } - }; - } - }, { - key: 'onLeave', - value: function onLeave(cb) { - var _this3 = this; - - return function () { - cb(); - if (_this3.props.onLeave) { - _this3.props.onLeave(); - } - }; - } - }, { - key: 'componentWillAppear', - value: function componentWillAppear(cb) { - if (!this.props.transitionAppear) { - this.onEnter(cb)(); - } - - this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionAppearTimeout)); - } - }, { - key: 'componentDidAppear', - value: function componentDidAppear() { - this.setState({ - mounted: true - }); - } - }, { - key: 'componentWillEnter', - value: function componentWillEnter(cb) { - if (!this.props.transitionEnter) { - this.onEnter(cb)(); - } - - this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionEnterTimeout)); - } - }, { - key: 'componentDidEnter', - value: function componentDidEnter() { - this.setState({ - mounted: true - }); - } - }, { - key: 'componentWillLeave', - value: function componentWillLeave(cb) { - this.setState({ - mounted: false - }); - - if (!this.props.transitionLeave) { - this.onLeave(cb)(); - } - - this.timers.push(setTimeout(this.onLeave(cb), this.props.transitionLeaveTimeout)); - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - baseClass = _props.baseClass, - baseClassIn = _props.baseClassIn, - className = _props.className, - cssModule = _props.cssModule, - Tag = _props.tag; - - var attributes = omit(this.props, Object.keys(propTypes$21)); - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, baseClass, this.state.mounted ? baseClassIn : false), cssModule); - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); - } - }]); - return Fade; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - -Fade.propTypes = propTypes$21; -Fade.defaultProps = defaultProps$20; - -var propTypes$22 = { - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - pill: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +AES.prototype._doReset = function () { + var invKsRow, keySize, keyWords, ksRow, ksRows, t + keyWords = this._key + keySize = keyWords.length + this._nRounds = keySize + 6 + ksRows = (this._nRounds + 1) * 4 + this._keySchedule = [] + for (ksRow = 0; ksRow < ksRows; ksRow++) { + this._keySchedule[ksRow] = ksRow < keySize ? keyWords[ksRow] : (t = this._keySchedule[ksRow - 1], (ksRow % keySize) === 0 ? (t = (t << 8) | (t >>> 24), t = (G.SBOX[t >>> 24] << 24) | (G.SBOX[(t >>> 16) & 0xff] << 16) | (G.SBOX[(t >>> 8) & 0xff] << 8) | G.SBOX[t & 0xff], t ^= G.RCON[(ksRow / keySize) | 0] << 24) : keySize > 6 && ksRow % keySize === 4 ? t = (G.SBOX[t >>> 24] << 24) | (G.SBOX[(t >>> 16) & 0xff] << 16) | (G.SBOX[(t >>> 8) & 0xff] << 8) | G.SBOX[t & 0xff] : void 0, this._keySchedule[ksRow - keySize] ^ t) + } + this._invKeySchedule = [] + for (invKsRow = 0; invKsRow < ksRows; invKsRow++) { + ksRow = ksRows - invKsRow + t = this._keySchedule[ksRow - (invKsRow % 4 ? 0 : 4)] + this._invKeySchedule[invKsRow] = invKsRow < 4 || ksRow <= 4 ? t : G.INV_SUB_MIX[0][G.SBOX[t >>> 24]] ^ G.INV_SUB_MIX[1][G.SBOX[(t >>> 16) & 0xff]] ^ G.INV_SUB_MIX[2][G.SBOX[(t >>> 8) & 0xff]] ^ G.INV_SUB_MIX[3][G.SBOX[t & 0xff]] + } + return true +} -var defaultProps$21 = { - color: 'default', - pill: false, - tag: 'span' -}; +AES.prototype.encryptBlock = function (M) { + M = bufferToArray(new Buffer(M)) + var out = this._doCryptBlock(M, this._keySchedule, G.SUB_MIX, G.SBOX) + var buf = new Buffer(16) + buf.writeUInt32BE(out[0], 0) + buf.writeUInt32BE(out[1], 4) + buf.writeUInt32BE(out[2], 8) + buf.writeUInt32BE(out[3], 12) + return buf +} -var Badge = function Badge(props) { - var className = props.className, - cssModule = props.cssModule, - color = props.color, - pill = props.pill, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'pill', 'tag']); +AES.prototype.decryptBlock = function (M) { + M = bufferToArray(new Buffer(M)) + var temp = [M[3], M[1]] + M[1] = temp[0] + M[3] = temp[1] + var out = this._doCryptBlock(M, this._invKeySchedule, G.INV_SUB_MIX, G.INV_SBOX) + var buf = new Buffer(16) + buf.writeUInt32BE(out[0], 0) + buf.writeUInt32BE(out[3], 4) + buf.writeUInt32BE(out[2], 8) + buf.writeUInt32BE(out[1], 12) + return buf +} +AES.prototype.scrub = function () { + scrub_vec(this._keySchedule) + scrub_vec(this._invKeySchedule) + scrub_vec(this._key) +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'badge', 'badge-' + color, pill ? 'badge-pill' : false), cssModule); +AES.prototype._doCryptBlock = function (M, keySchedule, SUB_MIX, SBOX) { + var ksRow, s0, s1, s2, s3, t0, t1, t2, t3 - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + s0 = M[0] ^ keySchedule[0] + s1 = M[1] ^ keySchedule[1] + s2 = M[2] ^ keySchedule[2] + s3 = M[3] ^ keySchedule[3] + ksRow = 4 + for (var round = 1; round < this._nRounds; round++) { + t0 = SUB_MIX[0][s0 >>> 24] ^ SUB_MIX[1][(s1 >>> 16) & 0xff] ^ SUB_MIX[2][(s2 >>> 8) & 0xff] ^ SUB_MIX[3][s3 & 0xff] ^ keySchedule[ksRow++] + t1 = SUB_MIX[0][s1 >>> 24] ^ SUB_MIX[1][(s2 >>> 16) & 0xff] ^ SUB_MIX[2][(s3 >>> 8) & 0xff] ^ SUB_MIX[3][s0 & 0xff] ^ keySchedule[ksRow++] + t2 = SUB_MIX[0][s2 >>> 24] ^ SUB_MIX[1][(s3 >>> 16) & 0xff] ^ SUB_MIX[2][(s0 >>> 8) & 0xff] ^ SUB_MIX[3][s1 & 0xff] ^ keySchedule[ksRow++] + t3 = SUB_MIX[0][s3 >>> 24] ^ SUB_MIX[1][(s0 >>> 16) & 0xff] ^ SUB_MIX[2][(s1 >>> 8) & 0xff] ^ SUB_MIX[3][s2 & 0xff] ^ keySchedule[ksRow++] + s0 = t0 + s1 = t1 + s2 = t2 + s3 = t3 + } + t0 = ((SBOX[s0 >>> 24] << 24) | (SBOX[(s1 >>> 16) & 0xff] << 16) | (SBOX[(s2 >>> 8) & 0xff] << 8) | SBOX[s3 & 0xff]) ^ keySchedule[ksRow++] + t1 = ((SBOX[s1 >>> 24] << 24) | (SBOX[(s2 >>> 16) & 0xff] << 16) | (SBOX[(s3 >>> 8) & 0xff] << 8) | SBOX[s0 & 0xff]) ^ keySchedule[ksRow++] + t2 = ((SBOX[s2 >>> 24] << 24) | (SBOX[(s3 >>> 16) & 0xff] << 16) | (SBOX[(s0 >>> 8) & 0xff] << 8) | SBOX[s1 & 0xff]) ^ keySchedule[ksRow++] + t3 = ((SBOX[s3 >>> 24] << 24) | (SBOX[(s0 >>> 16) & 0xff] << 16) | (SBOX[(s1 >>> 8) & 0xff] << 8) | SBOX[s2 & 0xff]) ^ keySchedule[ksRow++] + return [ + fixup_uint32(t0), + fixup_uint32(t1), + fixup_uint32(t2), + fixup_uint32(t3) + ] +} -Badge.propTypes = propTypes$22; -Badge.defaultProps = defaultProps$21; +exports.AES = AES -var propTypes$23 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var defaultProps$22 = { - tag: 'div' -}; +/***/ }), +/* 70 */ +/***/ (function(module, exports) { -var Card = function Card(props) { - var className = props.className, - cssModule = props.cssModule, - color = props.color, - block = props.block, - inverse = props.inverse, - outline = props.outline, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'block', 'inverse', 'outline', 'tag']); +exports['aes-128-ecb'] = { + cipher: 'AES', + key: 128, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-192-ecb'] = { + cipher: 'AES', + key: 192, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-256-ecb'] = { + cipher: 'AES', + key: 256, + iv: 0, + mode: 'ECB', + type: 'block' +} +exports['aes-128-cbc'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes-192-cbc'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes-256-cbc'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CBC', + type: 'block' +} +exports['aes128'] = exports['aes-128-cbc'] +exports['aes192'] = exports['aes-192-cbc'] +exports['aes256'] = exports['aes-256-cbc'] +exports['aes-128-cfb'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-192-cfb'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-256-cfb'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB', + type: 'stream' +} +exports['aes-128-cfb8'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-192-cfb8'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-256-cfb8'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB8', + type: 'stream' +} +exports['aes-128-cfb1'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-192-cfb1'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-256-cfb1'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CFB1', + type: 'stream' +} +exports['aes-128-ofb'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-192-ofb'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-256-ofb'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'OFB', + type: 'stream' +} +exports['aes-128-ctr'] = { + cipher: 'AES', + key: 128, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-192-ctr'] = { + cipher: 'AES', + key: 192, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-256-ctr'] = { + cipher: 'AES', + key: 256, + iv: 16, + mode: 'CTR', + type: 'stream' +} +exports['aes-128-gcm'] = { + cipher: 'AES', + key: 128, + iv: 12, + mode: 'GCM', + type: 'auth' +} +exports['aes-192-gcm'] = { + cipher: 'AES', + key: 192, + iv: 12, + mode: 'GCM', + type: 'auth' +} +exports['aes-256-gcm'] = { + cipher: 'AES', + key: 256, + iv: 12, + mode: 'GCM', + type: 'auth' +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card', inverse ? 'card-inverse' : false, block ? 'card-block' : false, color ? 'card' + (outline ? '-outline' : '') + '-' + color : false), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 71 */ +/***/ (function(module, exports, __webpack_require__) { -Card.propTypes = propTypes$23; -Card.defaultProps = defaultProps$22; +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) -var propTypes$24 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function incr32 (iv) { + var len = iv.length + var item + while (len--) { + item = iv.readUInt8(len) + if (item === 255) { + iv.writeUInt8(0, len) + } else { + item++ + iv.writeUInt8(item, len) + break + } + } +} -var defaultProps$23 = { - tag: 'div' -}; +function getBlock (self) { + var out = self._cipher.encryptBlock(self._prev) + incr32(self._prev) + return out +} -var CardGroup = function CardGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +exports.encrypt = function (self, chunk) { + while (self._cache.length < chunk.length) { + self._cache = Buffer.concat([self._cache, getBlock(self)]) + } + var pad = self._cache.slice(0, chunk.length) + self._cache = self._cache.slice(chunk.length) + return xor(chunk, pad) +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-group'), cssModule); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 72 */ +/***/ (function(module, exports, __webpack_require__) { -CardGroup.propTypes = propTypes$24; -CardGroup.defaultProps = defaultProps$23; +/* WEBPACK VAR INJECTION */(function(Buffer) {var asn1 = __webpack_require__(439) +var aesid = __webpack_require__(451) +var fixProc = __webpack_require__(452) +var ciphers = __webpack_require__(108) +var compat = __webpack_require__(177) +module.exports = parseKeys -var propTypes$25 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +function parseKeys (buffer) { + var password + if (typeof buffer === 'object' && !Buffer.isBuffer(buffer)) { + password = buffer.passphrase + buffer = buffer.key + } + if (typeof buffer === 'string') { + buffer = new Buffer(buffer) + } -var defaultProps$24 = { - tag: 'div' -}; + var stripped = fixProc(buffer, password) -var CardDeck = function CardDeck(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + var type = stripped.tag + var data = stripped.data + var subtype, ndata + switch (type) { + case 'CERTIFICATE': + ndata = asn1.certificate.decode(data, 'der').tbsCertificate.subjectPublicKeyInfo + // falls through + case 'PUBLIC KEY': + if (!ndata) { + ndata = asn1.PublicKey.decode(data, 'der') + } + subtype = ndata.algorithm.algorithm.join('.') + switch (subtype) { + case '1.2.840.113549.1.1.1': + return asn1.RSAPublicKey.decode(ndata.subjectPublicKey.data, 'der') + case '1.2.840.10045.2.1': + ndata.subjectPrivateKey = ndata.subjectPublicKey + return { + type: 'ec', + data: ndata + } + case '1.2.840.10040.4.1': + ndata.algorithm.params.pub_key = asn1.DSAparam.decode(ndata.subjectPublicKey.data, 'der') + return { + type: 'dsa', + data: ndata.algorithm.params + } + default: throw new Error('unknown key id ' + subtype) + } + throw new Error('unknown key type ' + type) + case 'ENCRYPTED PRIVATE KEY': + data = asn1.EncryptedPrivateKey.decode(data, 'der') + data = decrypt(data, password) + // falls through + case 'PRIVATE KEY': + ndata = asn1.PrivateKey.decode(data, 'der') + subtype = ndata.algorithm.algorithm.join('.') + switch (subtype) { + case '1.2.840.113549.1.1.1': + return asn1.RSAPrivateKey.decode(ndata.subjectPrivateKey, 'der') + case '1.2.840.10045.2.1': + return { + curve: ndata.algorithm.curve, + privateKey: asn1.ECPrivateKey.decode(ndata.subjectPrivateKey, 'der').privateKey + } + case '1.2.840.10040.4.1': + ndata.algorithm.params.priv_key = asn1.DSAparam.decode(ndata.subjectPrivateKey, 'der') + return { + type: 'dsa', + params: ndata.algorithm.params + } + default: throw new Error('unknown key id ' + subtype) + } + throw new Error('unknown key type ' + type) + case 'RSA PUBLIC KEY': + return asn1.RSAPublicKey.decode(data, 'der') + case 'RSA PRIVATE KEY': + return asn1.RSAPrivateKey.decode(data, 'der') + case 'DSA PRIVATE KEY': + return { + type: 'dsa', + params: asn1.DSAPrivateKey.decode(data, 'der') + } + case 'EC PRIVATE KEY': + data = asn1.ECPrivateKey.decode(data, 'der') + return { + curve: data.parameters.value, + privateKey: data.privateKey + } + default: throw new Error('unknown key type ' + type) + } +} +parseKeys.signature = asn1.signature +function decrypt (data, password) { + var salt = data.algorithm.decrypt.kde.kdeparams.salt + var iters = parseInt(data.algorithm.decrypt.kde.kdeparams.iters.toString(), 10) + var algo = aesid[data.algorithm.decrypt.cipher.algo.join('.')] + var iv = data.algorithm.decrypt.cipher.iv + var cipherText = data.subjectPrivateKey + var keylen = parseInt(algo.split('-')[1], 10) / 8 + var key = compat.pbkdf2Sync(password, salt, iters, keylen) + var cipher = ciphers.createDecipheriv(algo, key, iv) + var out = [] + out.push(cipher.update(cipherText)) + out.push(cipher.final()) + return Buffer.concat(out) +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-deck'), cssModule); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 73 */ +/***/ (function(module, exports, __webpack_require__) { -CardDeck.propTypes = propTypes$25; -CardDeck.defaultProps = defaultProps$24; +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { -var propTypes$26 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +// Number.MAX_SAFE_INTEGER +var MAX_SAFE_INTEGER = 9007199254740991 -var defaultProps$25 = { - tag: 'div' -}; +function checkUInt53 (n) { + if (n < 0 || n > MAX_SAFE_INTEGER || n % 1 !== 0) throw new RangeError('value out of range') +} -var CardColumns = function CardColumns(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +function encode (number, buffer, offset) { + checkUInt53(number) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-columns'), cssModule); + if (!buffer) buffer = new Buffer(encodingLength(number)) + if (!Buffer.isBuffer(buffer)) throw new TypeError('buffer must be a Buffer instance') + if (!offset) offset = 0 - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + // 8 bit + if (number < 0xfd) { + buffer.writeUInt8(number, offset) + encode.bytes = 1 -CardColumns.propTypes = propTypes$26; -CardColumns.defaultProps = defaultProps$25; + // 16 bit + } else if (number <= 0xffff) { + buffer.writeUInt8(0xfd, offset) + buffer.writeUInt16LE(number, offset + 1) + encode.bytes = 3 -var propTypes$27 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + // 32 bit + } else if (number <= 0xffffffff) { + buffer.writeUInt8(0xfe, offset) + buffer.writeUInt32LE(number, offset + 1) + encode.bytes = 5 -var defaultProps$26 = { - tag: 'div' -}; + // 64 bit + } else { + buffer.writeUInt8(0xff, offset) + buffer.writeUInt32LE(number >>> 0, offset + 1) + buffer.writeUInt32LE((number / 0x100000000) | 0, offset + 5) + encode.bytes = 9 + } -var CardBlock = function CardBlock(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + return buffer +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-block'), cssModule); +function decode (buffer, offset) { + if (!Buffer.isBuffer(buffer)) throw new TypeError('buffer must be a Buffer instance') + if (!offset) offset = 0 - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + var first = buffer.readUInt8(offset) -CardBlock.propTypes = propTypes$27; -CardBlock.defaultProps = defaultProps$26; + // 8 bit + if (first < 0xfd) { + decode.bytes = 1 + return first -var propTypes$28 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + // 16 bit + } else if (first === 0xfd) { + decode.bytes = 3 + return buffer.readUInt16LE(offset + 1) -var defaultProps$27 = { - tag: 'a' -}; + // 32 bit + } else if (first === 0xfe) { + decode.bytes = 5 + return buffer.readUInt32LE(offset + 1) -var CardLink = function CardLink(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - getRef = props.getRef, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'getRef']); + // 64 bit + } else { + decode.bytes = 9 + var lo = buffer.readUInt32LE(offset + 1) + var hi = buffer.readUInt32LE(offset + 5) + var number = hi * 0x0100000000 + lo + checkUInt53(number) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-link'), cssModule); + return number + } +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); -}; +function encodingLength (number) { + checkUInt53(number) -CardLink.propTypes = propTypes$28; -CardLink.defaultProps = defaultProps$27; + return ( + number < 0xfd ? 1 + : number <= 0xffff ? 3 + : number <= 0xffffffff ? 5 + : 9 + ) +} -var propTypes$29 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +module.exports = { encode: encode, decode: decode, encodingLength: encodingLength } -var defaultProps$28 = { - tag: 'div' -}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var CardFooter = function CardFooter(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/***/ }), +/* 74 */ +/***/ (function(module, exports, __webpack_require__) { - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-footer'), cssModule); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -CardFooter.propTypes = propTypes$29; -CardFooter.defaultProps = defaultProps$28; -var propTypes$30 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/** + * Forked from fbjs/warning: + * https://github.com/facebook/fbjs/blob/e66ba20ad5be433eb54423f2b097d829324d9de6/packages/fbjs/src/__forks__/warning.js + * + * Only change is we use console.warn instead of console.error, + * and do nothing when 'console' is not supported. + * This really simplifies the code. + * --- + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ -var defaultProps$29 = { - tag: 'div' -}; +var lowPriorityWarning = function () {}; -var CardHeader = function CardHeader(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +if (process.env.NODE_ENV !== 'production') { + var printWarning = function (format) { + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-header'), cssModule); + var argIndex = 0; + var message = 'Warning: ' + format.replace(/%s/g, function () { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.warn(message); + } + try { + // --- Welcome to debugging React --- + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch (x) {} + }; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + lowPriorityWarning = function (condition, format) { + if (format === undefined) { + throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); + } + if (!condition) { + for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { + args[_key2 - 2] = arguments[_key2]; + } -CardHeader.propTypes = propTypes$30; -CardHeader.defaultProps = defaultProps$29; + printWarning.apply(undefined, [format].concat(args)); + } + }; +} -var propTypes$31 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +module.exports = lowPriorityWarning; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var defaultProps$30 = { - tag: 'img' -}; +/***/ }), +/* 75 */ +/***/ (function(module, exports, __webpack_require__) { -var CardImg = function CardImg(props) { - var className = props.className, - cssModule = props.cssModule, - top = props.top, - bottom = props.bottom, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'top', 'bottom', 'tag']); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ - var cardImgClassName = 'card-img'; - if (top) { - cardImgClassName = 'card-img-top'; - } - if (bottom) { - cardImgClassName = 'card-img-bottom'; - } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, cardImgClassName), cssModule); +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +module.exports = ReactPropTypesSecret; -CardImg.propTypes = propTypes$31; -CardImg.defaultProps = defaultProps$30; -var propTypes$32 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 76 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$31 = { - tag: 'div' -}; +"use strict"; -var CardImgOverlay = function CardImgOverlay(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-img-overlay'), cssModule); +module.exports = __webpack_require__(230); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -CardImgOverlay.propTypes = propTypes$32; -CardImgOverlay.defaultProps = defaultProps$31; +/***/ }), +/* 77 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$33 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var defaultProps$32 = { - tag: 'h6' -}; -var CardSubtitle = function CardSubtitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-subtitle'), cssModule); +var _prodInvariant = __webpack_require__(5); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +var ReactErrorUtils = __webpack_require__(78); -CardSubtitle.propTypes = propTypes$33; -CardSubtitle.defaultProps = defaultProps$32; +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); -var propTypes$34 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/** + * Injected dependencies: + */ -var defaultProps$33 = { - tag: 'p' +/** + * - `ComponentTree`: [required] Module that can convert between React instances + * and actual node references. + */ +var ComponentTree; +var TreeTraversal; +var injection = { + injectComponentTree: function (Injected) { + ComponentTree = Injected; + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.getNodeFromInstance && Injected.getInstanceFromNode, 'EventPluginUtils.injection.injectComponentTree(...): Injected ' + 'module is missing getNodeFromInstance or getInstanceFromNode.') : void 0; + } + }, + injectTreeTraversal: function (Injected) { + TreeTraversal = Injected; + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(Injected && Injected.isAncestor && Injected.getLowestCommonAncestor, 'EventPluginUtils.injection.injectTreeTraversal(...): Injected ' + 'module is missing isAncestor or getLowestCommonAncestor.') : void 0; + } + } }; -var CardText = function CardText(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-text'), cssModule); - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +function isEndish(topLevelType) { + return topLevelType === 'topMouseUp' || topLevelType === 'topTouchEnd' || topLevelType === 'topTouchCancel'; +} -CardText.propTypes = propTypes$34; -CardText.defaultProps = defaultProps$33; +function isMoveish(topLevelType) { + return topLevelType === 'topMouseMove' || topLevelType === 'topTouchMove'; +} +function isStartish(topLevelType) { + return topLevelType === 'topMouseDown' || topLevelType === 'topTouchStart'; +} -var propTypes$35 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var validateEventDispatches; +if (process.env.NODE_ENV !== 'production') { + validateEventDispatches = function (event) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; -var defaultProps$34 = { - tag: 'h4' -}; + var listenersIsArr = Array.isArray(dispatchListeners); + var listenersLen = listenersIsArr ? dispatchListeners.length : dispatchListeners ? 1 : 0; -var CardTitle = function CardTitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + var instancesIsArr = Array.isArray(dispatchInstances); + var instancesLen = instancesIsArr ? dispatchInstances.length : dispatchInstances ? 1 : 0; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-title'), cssModule); + process.env.NODE_ENV !== 'production' ? warning(instancesIsArr === listenersIsArr && instancesLen === listenersLen, 'EventPluginUtils: Invalid `event`.') : void 0; + }; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/** + * Dispatch the event to the listener. + * @param {SyntheticEvent} event SyntheticEvent to handle + * @param {boolean} simulated If the event is simulated (changes exn behavior) + * @param {function} listener Application-level callback + * @param {*} inst Internal component instance + */ +function executeDispatch(event, simulated, listener, inst) { + var type = event.type || 'unknown-event'; + event.currentTarget = EventPluginUtils.getNodeFromInstance(inst); + if (simulated) { + ReactErrorUtils.invokeGuardedCallbackWithCatch(type, listener, event); + } else { + ReactErrorUtils.invokeGuardedCallback(type, listener, event); + } + event.currentTarget = null; +} -CardTitle.propTypes = propTypes$35; -CardTitle.defaultProps = defaultProps$34; +/** + * Standard/simple iteration through an event's collected dispatches. + */ +function executeDispatchesInOrder(event, simulated) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + if (Array.isArray(dispatchListeners)) { + for (var i = 0; i < dispatchListeners.length; i++) { + if (event.isPropagationStopped()) { + break; + } + // Listeners and Instances are two parallel arrays that are always in sync. + executeDispatch(event, simulated, dispatchListeners[i], dispatchInstances[i]); + } + } else if (dispatchListeners) { + executeDispatch(event, simulated, dispatchListeners, dispatchInstances); + } + event._dispatchListeners = null; + event._dispatchInstances = null; +} -var propTypes$36 = { - placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), - target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string.isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; +/** + * Standard/simple iteration through an event's collected dispatches, but stops + * at the first dispatch execution returning true, and returns that id. + * + * @return {?string} id of the first dispatch execution who's listener returns + * true, or null if no listener returned true. + */ +function executeDispatchesInOrderStopAtTrueImpl(event) { + var dispatchListeners = event._dispatchListeners; + var dispatchInstances = event._dispatchInstances; + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + if (Array.isArray(dispatchListeners)) { + for (var i = 0; i < dispatchListeners.length; i++) { + if (event.isPropagationStopped()) { + break; + } + // Listeners and Instances are two parallel arrays that are always in sync. + if (dispatchListeners[i](event, dispatchInstances[i])) { + return dispatchInstances[i]; + } + } + } else if (dispatchListeners) { + if (dispatchListeners(event, dispatchInstances)) { + return dispatchInstances; + } + } + return null; +} -var defaultProps$35 = { - isOpen: false, - placement: 'bottom', - toggle: function toggle() {} -}; +/** + * @see executeDispatchesInOrderStopAtTrueImpl + */ +function executeDispatchesInOrderStopAtTrue(event) { + var ret = executeDispatchesInOrderStopAtTrueImpl(event); + event._dispatchInstances = null; + event._dispatchListeners = null; + return ret; +} -var defaultTetherConfig$1 = { - classPrefix: 'bs-tether', - classes: { - element: false, - enabled: 'show' - }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; +/** + * Execution of a "direct" dispatch - there must be at most one dispatch + * accumulated on the event or it is considered an error. It doesn't really make + * sense for an event with multiple dispatches (bubbled) to keep track of the + * return values at each dispatch execution, but it does tend to make sense when + * dealing with "direct" dispatches. + * + * @return {*} The return value of executing the single dispatch. + */ +function executeDirectDispatch(event) { + if (process.env.NODE_ENV !== 'production') { + validateEventDispatches(event); + } + var dispatchListener = event._dispatchListeners; + var dispatchInstance = event._dispatchInstances; + !!Array.isArray(dispatchListener) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'executeDirectDispatch(...): Invalid `event`.') : _prodInvariant('103') : void 0; + event.currentTarget = dispatchListener ? EventPluginUtils.getNodeFromInstance(dispatchInstance) : null; + var res = dispatchListener ? dispatchListener(event) : null; + event.currentTarget = null; + event._dispatchListeners = null; + event._dispatchInstances = null; + return res; +} -var Popover = function (_React$Component) { - inherits(Popover, _React$Component); +/** + * @param {SyntheticEvent} event + * @return {boolean} True iff number of dispatches accumulated is greater than 0. + */ +function hasDispatches(event) { + return !!event._dispatchListeners; +} - function Popover(props) { - classCallCheck(this, Popover); +/** + * General utilities that are useful in creating custom Event Plugins. + */ +var EventPluginUtils = { + isEndish: isEndish, + isMoveish: isMoveish, + isStartish: isStartish, - var _this = possibleConstructorReturn(this, (Popover.__proto__ || Object.getPrototypeOf(Popover)).call(this, props)); + executeDirectDispatch: executeDirectDispatch, + executeDispatchesInOrder: executeDispatchesInOrder, + executeDispatchesInOrderStopAtTrue: executeDispatchesInOrderStopAtTrue, + hasDispatches: hasDispatches, - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - return _this; - } + getInstanceFromNode: function (node) { + return ComponentTree.getInstanceFromNode(node); + }, + getNodeFromInstance: function (node) { + return ComponentTree.getNodeFromInstance(node); + }, + isAncestor: function (a, b) { + return TreeTraversal.isAncestor(a, b); + }, + getLowestCommonAncestor: function (a, b) { + return TreeTraversal.getLowestCommonAncestor(a, b); + }, + getParentInstance: function (inst) { + return TreeTraversal.getParentInstance(inst); + }, + traverseTwoPhase: function (target, fn, arg) { + return TreeTraversal.traverseTwoPhase(target, fn, arg); + }, + traverseEnterLeave: function (from, to, fn, argFrom, argTo) { + return TreeTraversal.traverseEnterLeave(from, to, fn, argFrom, argTo); + }, - createClass(Popover, [{ - key: 'getTetherConfig', - value: function getTetherConfig() { - var attachments = getTetherAttachments(this.props.placement); - return _extends({}, defaultTetherConfig$1, attachments, { - target: '#' + this.props.target - }, this.props.tether); - } - }, { - key: 'render', - value: function render() { - if (!this.props.isOpen) { - return null; - } + injection: injection +}; - var tetherConfig = this.getTetherConfig(); +module.exports = EventPluginUtils; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('popover-inner', this.props.className), this.props.cssModule); +/***/ }), +/* 78 */ +/***/ (function(module, exports, __webpack_require__) { - var attributes = omit(this.props, Object.keys(propTypes$36)); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - { - className: mapToCssModules('popover', this.props.cssModule), - tether: tetherConfig, - tetherRef: this.props.tetherRef, - isOpen: this.props.isOpen, - toggle: this.props.toggle - }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { className: classes })) - ); + + +var caughtError = null; + +/** + * Call a function while guarding against errors that happens within it. + * + * @param {String} name of the guard to use for logging or debugging + * @param {Function} func The function to invoke + * @param {*} a First argument + * @param {*} b Second argument + */ +function invokeGuardedCallback(name, func, a) { + try { + func(a); + } catch (x) { + if (caughtError === null) { + caughtError = x; } - }]); - return Popover; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + } +} -Popover.propTypes = propTypes$36; -Popover.defaultProps = defaultProps$35; +var ReactErrorUtils = { + invokeGuardedCallback: invokeGuardedCallback, -var propTypes$37 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * Invoked by ReactTestUtils.Simulate so that any errors thrown by the event + * handler are sure to be rethrown by rethrowCaughtError. + */ + invokeGuardedCallbackWithCatch: invokeGuardedCallback, -var defaultProps$36 = { - tag: 'h3' + /** + * During execution of guarded functions we will capture the first error which + * we will rethrow to be handled by the top level error handler. + */ + rethrowCaughtError: function () { + if (caughtError) { + var error = caughtError; + caughtError = null; + throw error; + } + } }; -var PopoverTitle = function PopoverTitle(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - +if (process.env.NODE_ENV !== 'production') { + /** + * To help development we can get better devtools integration by simulating a + * real browser event. + */ + if (typeof window !== 'undefined' && typeof window.dispatchEvent === 'function' && typeof document !== 'undefined' && typeof document.createEvent === 'function') { + var fakeNode = document.createElement('react'); + ReactErrorUtils.invokeGuardedCallback = function (name, func, a) { + var boundFunc = func.bind(null, a); + var evtType = 'react-' + name; + fakeNode.addEventListener(evtType, boundFunc, false); + var evt = document.createEvent('Event'); + evt.initEvent(evtType, false, false); + fakeNode.dispatchEvent(evt); + fakeNode.removeEventListener(evtType, boundFunc, false); + }; + } +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-title'), cssModule); +module.exports = ReactErrorUtils; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 79 */ +/***/ (function(module, exports, __webpack_require__) { -PopoverTitle.propTypes = propTypes$37; -PopoverTitle.defaultProps = defaultProps$36; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var propTypes$38 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; -var defaultProps$37 = { - tag: 'div' -}; -var PopoverContent = function PopoverContent(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/** + * Gets the target node from a native browser event by accounting for + * inconsistencies in browser DOM APIs. + * + * @param {object} nativeEvent Native browser event. + * @return {DOMEventTarget} Target node. + */ +function getEventTarget(nativeEvent) { + var target = nativeEvent.target || nativeEvent.srcElement || window; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-content'), cssModule); + // Normalize SVG <use> element events #4963 + if (target.correspondingUseElement) { + target = target.correspondingUseElement; + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + // Safari may fire events on text nodes (Node.TEXT_NODE is 3). + // @see http://www.quirksmode.org/js/events_properties.html + return target.nodeType === 3 ? target.parentNode : target; +} -PopoverContent.propTypes = propTypes$38; -PopoverContent.defaultProps = defaultProps$37; +module.exports = getEventTarget; -var propTypes$39 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - bar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - multi: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - value: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - max: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - animated: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - barClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 80 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$38 = { - tag: 'div', - value: 0, - max: 100 -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var Progress = function Progress(props) { - var children = props.children, - className = props.className, - barClassName = props.barClassName, - cssModule = props.cssModule, - value = props.value, - max = props.max, - animated = props.animated, - striped = props.striped, - color = props.color, - bar = props.bar, - multi = props.multi, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['children', 'className', 'barClassName', 'cssModule', 'value', 'max', 'animated', 'striped', 'color', 'bar', 'multi', 'tag']); - var percent = __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(value) / __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(max) * 100; +var ExecutionEnvironment = __webpack_require__(13); - var progressClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'progress'), cssModule); +var useHasFeature; +if (ExecutionEnvironment.canUseDOM) { + useHasFeature = document.implementation && document.implementation.hasFeature && + // always returns true in newer browsers as per the standard. + // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature + document.implementation.hasFeature('', '') !== true; +} - var progressBarClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('progress-bar', bar ? className || barClassName : barClassName, animated ? 'progress-bar-animated' : null, color ? 'bg-' + color : null, striped || animated ? 'progress-bar-striped' : null), cssModule); +/** + * Checks if an event is supported in the current execution environment. + * + * NOTE: This will not work correctly for non-generic events such as `change`, + * `reset`, `load`, `error`, and `select`. + * + * Borrows from Modernizr. + * + * @param {string} eventNameSuffix Event name, e.g. "click". + * @param {?boolean} capture Check if the capture phase is supported. + * @return {boolean} True if the event is supported. + * @internal + * @license Modernizr 3.0.0pre (Custom Build) | MIT + */ +function isEventSupported(eventNameSuffix, capture) { + if (!ExecutionEnvironment.canUseDOM || capture && !('addEventListener' in document)) { + return false; + } - var ProgressBar = multi ? children : __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { - className: progressBarClasses, - style: { width: percent + '%' }, - role: 'progressbar', - 'aria-valuenow': value, - 'aria-valuemin': '0', - 'aria-valuemax': max, - children: children - }); + var eventName = 'on' + eventNameSuffix; + var isSupported = eventName in document; - if (bar) { - return ProgressBar; + if (!isSupported) { + var element = document.createElement('div'); + element.setAttribute(eventName, 'return;'); + isSupported = typeof element[eventName] === 'function'; } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: progressClasses, children: ProgressBar })); -}; + if (!isSupported && useHasFeature && eventNameSuffix === 'wheel') { + // This is the only way to test support for the `wheel` event in IE9+. + isSupported = document.implementation.hasFeature('Events.wheel', '3.0'); + } -Progress.propTypes = propTypes$39; -Progress.defaultProps = defaultProps$38; + return isSupported; +} -var propTypes$40 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - autoFocus: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - keyboard: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - backdrop: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(['static'])]), - onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onExit: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - wrapClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - modalClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - backdropClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - contentClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - fade: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - zIndex: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - backdropTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - backdropTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - modalTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number -}; +module.exports = isEventSupported; -var propsToOmit = Object.keys(propTypes$40); +/***/ }), +/* 81 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$39 = { - isOpen: false, - autoFocus: true, - backdrop: true, - keyboard: true, - zIndex: 1050, - fade: true, - modalTransitionTimeout: 300, - backdropTransitionTimeout: 150 -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var Modal = function (_React$Component) { - inherits(Modal, _React$Component); - function Modal(props) { - classCallCheck(this, Modal); - var _this = possibleConstructorReturn(this, (Modal.__proto__ || Object.getPrototypeOf(Modal)).call(this, props)); +/** + * Translation from modifier key to the associated property in the event. + * @see http://www.w3.org/TR/DOM-Level-3-Events/#keys-Modifiers + */ - _this.originalBodyPadding = null; - _this.isBodyOverflowing = false; - _this.togglePortal = _this.togglePortal.bind(_this); - _this.handleBackdropClick = _this.handleBackdropClick.bind(_this); - _this.handleEscape = _this.handleEscape.bind(_this); - _this.destroy = _this.destroy.bind(_this); - _this.onEnter = _this.onEnter.bind(_this); - _this.onExit = _this.onExit.bind(_this); - return _this; - } +var modifierKeyToProp = { + Alt: 'altKey', + Control: 'ctrlKey', + Meta: 'metaKey', + Shift: 'shiftKey' +}; - createClass(Modal, [{ - key: 'componentDidMount', - value: function componentDidMount() { - if (this.props.isOpen) { - this.togglePortal(); - } - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - if (this.props.isOpen !== prevProps.isOpen) { - // handle portal events/dom updates - this.togglePortal(); - } else if (this._element) { - // rerender portal - this.renderIntoSubtree(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.onExit(); - } - }, { - key: 'onEnter', - value: function onEnter() { - if (this.props.onEnter) { - this.props.onEnter(); - } - } - }, { - key: 'onExit', - value: function onExit() { - this.destroy(); - if (this.props.onExit) { - this.props.onExit(); - } - } - }, { - key: 'handleEscape', - value: function handleEscape(e) { - if (this.props.keyboard && e.keyCode === 27 && this.props.toggle) { - this.props.toggle(); - } - } - }, { - key: 'handleBackdropClick', - value: function handleBackdropClick(e) { - if (this.props.backdrop !== true) return; - - var container = this._dialog; +// IE8 does not implement getModifierState so we simply map it to the only +// modifier keys exposed by the event itself, does not support Lock-keys. +// Currently, all major browsers except Chrome seems to support Lock-keys. +function modifierStateGetter(keyArg) { + var syntheticEvent = this; + var nativeEvent = syntheticEvent.nativeEvent; + if (nativeEvent.getModifierState) { + return nativeEvent.getModifierState(keyArg); + } + var keyProp = modifierKeyToProp[keyArg]; + return keyProp ? !!nativeEvent[keyProp] : false; +} - if (e.target && !container.contains(e.target) && this.props.toggle) { - this.props.toggle(); - } - } - }, { - key: 'hasTransition', - value: function hasTransition() { - if (this.props.fade === false) { - return false; - } +function getEventModifierState(nativeEvent) { + return modifierStateGetter; +} - return this.props.modalTransitionTimeout > 0; - } - }, { - key: 'togglePortal', - value: function togglePortal() { - if (this.props.isOpen) { - if (this.props.autoFocus) { - this._focus = true; - } - this.show(); - if (!this.hasTransition()) { - this.onEnter(); - } - } else { - this.hide(); - if (!this.hasTransition()) { - this.onExit(); - } - } - } - }, { - key: 'destroy', - value: function destroy() { - if (this._element) { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); - document.body.removeChild(this._element); - this._element = null; - } +module.exports = getEventModifierState; - // Use regex to prevent matching `modal-open` as part of a different class, e.g. `my-modal-opened` - var classes = document.body.className.replace(/(^| )modal-open( |$)/, ' '); - document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes).trim(), this.props.cssModule); - setScrollbarWidth(this.originalBodyPadding); - } - }, { - key: 'hide', - value: function hide() { - this.renderIntoSubtree(); - } - }, { - key: 'show', - value: function show() { - var classes = document.body.className; - this._element = document.createElement('div'); - this._element.setAttribute('tabindex', '-1'); - this._element.style.position = 'relative'; - this._element.style.zIndex = this.props.zIndex; - this.originalBodyPadding = getOriginalBodyPadding(); +/***/ }), +/* 82 */ +/***/ (function(module, exports, __webpack_require__) { - conditionallyUpdateScrollbar(); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - document.body.appendChild(this._element); - document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes, 'modal-open'), this.props.cssModule); - this.renderIntoSubtree(); - } - }, { - key: 'renderModalDialog', - value: function renderModalDialog() { - var _this2 = this; +var DOMLazyTree = __webpack_require__(39); +var Danger = __webpack_require__(249); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstrumentation = __webpack_require__(19); - var attributes = omit(this.props, propsToOmit); +var createMicrosoftUnsafeLocalFunction = __webpack_require__(84); +var setInnerHTML = __webpack_require__(60); +var setTextContent = __webpack_require__(135); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - _extends({ - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-dialog', this.props.className, defineProperty({}, 'modal-' + this.props.size, this.props.size)), this.props.cssModule), - role: 'document', - ref: function ref(c) { - return _this2._dialog = c; - } - }, attributes), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - { - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-content', this.props.contentClassName), this.props.cssModule) - }, - this.props.children - ) - ); - } - }, { - key: 'renderIntoSubtree', - value: function renderIntoSubtree() { - __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); +function getNodeAfter(parentNode, node) { + // Special case for text components, which return [open, close] comments + // from getHostNode. + if (Array.isArray(node)) { + node = node[1]; + } + return node ? node.nextSibling : parentNode.firstChild; +} - // check if modal should receive focus - if (this._focus) { - this._dialog.parentNode.focus(); - this._focus = false; - } - } - }, { - key: 'renderChildren', - value: function renderChildren() { - var _props = this.props, - wrapClassName = _props.wrapClassName, - modalClassName = _props.modalClassName, - backdropClassName = _props.backdropClassName, - cssModule = _props.cssModule, - isOpen = _props.isOpen, - backdrop = _props.backdrop, - modalTransitionTimeout = _props.modalTransitionTimeout, - backdropTransitionTimeout = _props.backdropTransitionTimeout; +/** + * Inserts `childNode` as a child of `parentNode` at the `index`. + * + * @param {DOMElement} parentNode Parent node in which to insert. + * @param {DOMElement} childNode Child node to insert. + * @param {number} index Index at which to insert the child. + * @internal + */ +var insertChildAt = createMicrosoftUnsafeLocalFunction(function (parentNode, childNode, referenceNode) { + // We rely exclusively on `insertBefore(node, null)` instead of also using + // `appendChild(node)`. (Using `undefined` is not allowed by all browsers so + // we are careful to use `null`.) + parentNode.insertBefore(childNode, referenceNode); +}); +function insertLazyTreeChildAt(parentNode, childTree, referenceNode) { + DOMLazyTree.insertTreeBefore(parentNode, childTree, referenceNode); +} - var modalAttributes = { - onClickCapture: this.handleBackdropClick, - onKeyUp: this.handleEscape, - style: { display: 'block' }, - tabIndex: '-1' - }; +function moveChild(parentNode, childNode, referenceNode) { + if (Array.isArray(childNode)) { + moveDelimitedText(parentNode, childNode[0], childNode[1], referenceNode); + } else { + insertChildAt(parentNode, childNode, referenceNode); + } +} - if (this.hasTransition()) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["TransitionGroup"], - { component: 'div', className: mapToCssModules(wrapClassName) }, - isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Fade, - _extends({ - key: 'modal-dialog', - onEnter: this.onEnter, - onLeave: this.onExit, - transitionAppearTimeout: typeof this.props.modalTransitionAppearTimeout === 'number' ? this.props.modalTransitionAppearTimeout : modalTransitionTimeout, - transitionEnterTimeout: typeof this.props.modalTransitionEnterTimeout === 'number' ? this.props.modalTransitionEnterTimeout : modalTransitionTimeout, - transitionLeaveTimeout: typeof this.props.modalTransitionLeaveTimeout === 'number' ? this.props.modalTransitionLeaveTimeout : modalTransitionTimeout, - cssModule: cssModule, - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', modalClassName), cssModule) - }, modalAttributes), - this.renderModalDialog() - ), - isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Fade, { - key: 'modal-backdrop', - transitionAppearTimeout: typeof this.props.backdropTransitionAppearTimeout === 'number' ? this.props.backdropTransitionAppearTimeout : backdropTransitionTimeout, - transitionEnterTimeout: typeof this.props.backdropTransitionEnterTimeout === 'number' ? this.props.backdropTransitionEnterTimeout : backdropTransitionTimeout, - transitionLeaveTimeout: typeof this.props.backdropTransitionLeaveTimeout === 'number' ? this.props.backdropTransitionLeaveTimeout : backdropTransitionTimeout, - cssModule: cssModule, - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', backdropClassName), cssModule) - }) - ); - } +function removeChild(parentNode, childNode) { + if (Array.isArray(childNode)) { + var closingComment = childNode[1]; + childNode = childNode[0]; + removeDelimitedText(parentNode, childNode, closingComment); + parentNode.removeChild(closingComment); + } + parentNode.removeChild(childNode); +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - { className: mapToCssModules(wrapClassName) }, - isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'div', - _extends({ - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', 'show', modalClassName), cssModule) - }, modalAttributes), - this.renderModalDialog() - ), - isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { - className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', 'show', backdropClassName), cssModule) - }) - ); +function moveDelimitedText(parentNode, openingComment, closingComment, referenceNode) { + var node = openingComment; + while (true) { + var nextNode = node.nextSibling; + insertChildAt(parentNode, node, referenceNode); + if (node === closingComment) { + break; } - }, { - key: 'render', - value: function render() { - return null; + node = nextNode; + } +} + +function removeDelimitedText(parentNode, startNode, closingComment) { + while (true) { + var node = startNode.nextSibling; + if (node === closingComment) { + // The closing comment is removed by ReactMultiChild. + break; + } else { + parentNode.removeChild(node); } - }]); - return Modal; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + } +} -Modal.propTypes = propTypes$40; -Modal.defaultProps = defaultProps$39; +function replaceDelimitedText(openingComment, closingComment, stringText) { + var parentNode = openingComment.parentNode; + var nodeAfterComment = openingComment.nextSibling; + if (nodeAfterComment === closingComment) { + // There are no text nodes between the opening and closing comments; insert + // a new one if stringText isn't empty. + if (stringText) { + insertChildAt(parentNode, document.createTextNode(stringText), nodeAfterComment); + } + } else { + if (stringText) { + // Set the text content of the first node after the opening comment, and + // remove all following nodes up until the closing comment. + setTextContent(nodeAfterComment, stringText); + removeDelimitedText(parentNode, nodeAfterComment, closingComment); + } else { + removeDelimitedText(parentNode, openingComment, closingComment); + } + } -var propTypes$41 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - wrapTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node -}; + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(openingComment)._debugID, + type: 'replace text', + payload: stringText + }); + } +} -var defaultProps$40 = { - tag: 'h4', - wrapTag: 'div' -}; +var dangerouslyReplaceNodeWithMarkup = Danger.dangerouslyReplaceNodeWithMarkup; +if (process.env.NODE_ENV !== 'production') { + dangerouslyReplaceNodeWithMarkup = function (oldChild, markup, prevInstance) { + Danger.dangerouslyReplaceNodeWithMarkup(oldChild, markup); + if (prevInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: prevInstance._debugID, + type: 'replace with', + payload: markup.toString() + }); + } else { + var nextInstance = ReactDOMComponentTree.getInstanceFromNode(markup.node); + if (nextInstance._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: nextInstance._debugID, + type: 'mount', + payload: markup.toString() + }); + } + } + }; +} -var ModalHeader = function ModalHeader(props) { - var closeButton = void 0; - var className = props.className, - cssModule = props.cssModule, - children = props.children, - toggle = props.toggle, - Tag = props.tag, - WrapTag = props.wrapTag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'toggle', 'tag', 'wrapTag']); +/** + * Operations for updating with DOM children. + */ +var DOMChildrenOperations = { + dangerouslyReplaceNodeWithMarkup: dangerouslyReplaceNodeWithMarkup, + replaceDelimitedText: replaceDelimitedText, - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-header'), cssModule); + /** + * Updates a component's children by processing a series of updates. The + * update configurations are each expected to have a `parentNode` property. + * + * @param {array<object>} updates List of update configurations. + * @internal + */ + processUpdates: function (parentNode, updates) { + if (process.env.NODE_ENV !== 'production') { + var parentNodeDebugID = ReactDOMComponentTree.getInstanceFromNode(parentNode)._debugID; + } - if (toggle) { - closeButton = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'button', - { type: 'button', onClick: toggle, className: 'close', 'aria-label': 'Close' }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { 'aria-hidden': 'true' }, - String.fromCharCode(215) - ) - ); + for (var k = 0; k < updates.length; k++) { + var update = updates[k]; + switch (update.type) { + case 'INSERT_MARKUP': + insertLazyTreeChildAt(parentNode, update.content, getNodeAfter(parentNode, update.afterNode)); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'insert child', + payload: { + toIndex: update.toIndex, + content: update.content.toString() + } + }); + } + break; + case 'MOVE_EXISTING': + moveChild(parentNode, update.fromNode, getNodeAfter(parentNode, update.afterNode)); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'move child', + payload: { fromIndex: update.fromIndex, toIndex: update.toIndex } + }); + } + break; + case 'SET_MARKUP': + setInnerHTML(parentNode, update.content); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'replace children', + payload: update.content.toString() + }); + } + break; + case 'TEXT_CONTENT': + setTextContent(parentNode, update.content); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'replace text', + payload: update.content.toString() + }); + } + break; + case 'REMOVE_NODE': + removeChild(parentNode, update.fromNode); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: parentNodeDebugID, + type: 'remove child', + payload: { fromIndex: update.fromIndex } + }); + } + break; + } + } } - - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - WrapTag, - _extends({}, attributes, { className: classes }), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - { className: mapToCssModules('modal-title', cssModule) }, - children - ), - closeButton - ); }; -ModalHeader.propTypes = propTypes$41; -ModalHeader.defaultProps = defaultProps$40; +module.exports = DOMChildrenOperations; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var propTypes$42 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 83 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$41 = { - tag: 'div' -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var ModalBody = function ModalBody(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-body'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +var DOMNamespaces = { + html: 'http://www.w3.org/1999/xhtml', + mathml: 'http://www.w3.org/1998/Math/MathML', + svg: 'http://www.w3.org/2000/svg' }; -ModalBody.propTypes = propTypes$42; -ModalBody.defaultProps = defaultProps$41; +module.exports = DOMNamespaces; -var propTypes$43 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/***/ }), +/* 84 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps$42 = { - tag: 'div' -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var ModalFooter = function ModalFooter(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); +/* globals MSApp */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-footer'), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -ModalFooter.propTypes = propTypes$43; -ModalFooter.defaultProps = defaultProps$42; +/** + * Create a function which has 'unsafe' privileges (required by windows8 apps) + */ -var propTypes$44 = { - placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), - target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - autohide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]) +var createMicrosoftUnsafeLocalFunction = function (func) { + if (typeof MSApp !== 'undefined' && MSApp.execUnsafeLocalFunction) { + return function (arg0, arg1, arg2, arg3) { + MSApp.execUnsafeLocalFunction(function () { + return func(arg0, arg1, arg2, arg3); + }); + }; + } else { + return func; + } }; -var DEFAULT_DELAYS = { - show: 0, - hide: 250 -}; +module.exports = createMicrosoftUnsafeLocalFunction; -var defaultProps$43 = { - isOpen: false, - placement: 'bottom', - delay: DEFAULT_DELAYS, - autohide: true, - toggle: function toggle() {} -}; +/***/ }), +/* 85 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultTetherConfig$2 = { - classPrefix: 'bs-tether', - classes: { - element: false, - enabled: 'show' - }, - constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var Tooltip = function (_React$Component) { - inherits(Tooltip, _React$Component); - function Tooltip(props) { - classCallCheck(this, Tooltip); - var _this = possibleConstructorReturn(this, (Tooltip.__proto__ || Object.getPrototypeOf(Tooltip)).call(this, props)); +var _prodInvariant = __webpack_require__(5); - _this.addTargetEvents = _this.addTargetEvents.bind(_this); - _this.getTarget = _this.getTarget.bind(_this); - _this.getTetherConfig = _this.getTetherConfig.bind(_this); - _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); - _this.removeTargetEvents = _this.removeTargetEvents.bind(_this); - _this.toggle = _this.toggle.bind(_this); - _this.onMouseOverTooltip = _this.onMouseOverTooltip.bind(_this); - _this.onMouseLeaveTooltip = _this.onMouseLeaveTooltip.bind(_this); - _this.onMouseOverTooltipContent = _this.onMouseOverTooltipContent.bind(_this); - _this.onMouseLeaveTooltipContent = _this.onMouseLeaveTooltipContent.bind(_this); - _this.show = _this.show.bind(_this); - _this.hide = _this.hide.bind(_this); - return _this; - } +var ReactPropTypesSecret = __webpack_require__(139); +var propTypesFactory = __webpack_require__(124); - createClass(Tooltip, [{ - key: 'componentDidMount', - value: function componentDidMount() { - this._target = this.getTarget(); - this.addTargetEvents(); - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.removeTargetEvents(); - } - }, { - key: 'onMouseOverTooltip', - value: function onMouseOverTooltip() { - if (this._hideTimeout) { - this.clearHideTimeout(); - } - this._showTimeout = setTimeout(this.show, this.getDelay('show')); - } - }, { - key: 'onMouseLeaveTooltip', - value: function onMouseLeaveTooltip() { - if (this._showTimeout) { - this.clearShowTimeout(); - } - this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); - } - }, { - key: 'onMouseOverTooltipContent', - value: function onMouseOverTooltipContent() { - if (this.props.autohide) { - return; - } - if (this._hideTimeout) { - this.clearHideTimeout(); - } - } - }, { - key: 'onMouseLeaveTooltipContent', - value: function onMouseLeaveTooltipContent() { - if (this.props.autohide) { - return; - } - if (this._showTimeout) { - this.clearShowTimeout(); - } - this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); - } - }, { - key: 'getDelay', - value: function getDelay(key) { - var delay = this.props.delay; +var React = __webpack_require__(36); +var PropTypes = propTypesFactory(React.isValidElement); - if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { - return isNaN(delay[key]) ? DEFAULT_DELAYS[key] : delay[key]; - } - return delay; - } - }, { - key: 'getTarget', - value: function getTarget() { - var target = this.props.target; +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); - if ((typeof target === 'undefined' ? 'undefined' : _typeof(target)) === 'object') { - return target; - } - return document.getElementById(target); +var hasReadOnlyValue = { + button: true, + checkbox: true, + image: true, + hidden: true, + radio: true, + reset: true, + submit: true +}; + +function _assertSingleLink(inputProps) { + !(inputProps.checkedLink == null || inputProps.valueLink == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a valueLink. If you want to use checkedLink, you probably don\'t want to use valueLink and vice versa.') : _prodInvariant('87') : void 0; +} +function _assertValueLink(inputProps) { + _assertSingleLink(inputProps); + !(inputProps.value == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a valueLink and a value or onChange event. If you want to use value or onChange, you probably don\'t want to use valueLink.') : _prodInvariant('88') : void 0; +} + +function _assertCheckedLink(inputProps) { + _assertSingleLink(inputProps); + !(inputProps.checked == null && inputProps.onChange == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Cannot provide a checkedLink and a checked property or onChange event. If you want to use checked or onChange, you probably don\'t want to use checkedLink') : _prodInvariant('89') : void 0; +} + +var propTypes = { + value: function (props, propName, componentName) { + if (!props[propName] || hasReadOnlyValue[props.type] || props.onChange || props.readOnly || props.disabled) { + return null; } - }, { - key: 'getTetherConfig', - value: function getTetherConfig() { - var attachments = getTetherAttachments(this.props.placement); - return _extends({}, defaultTetherConfig$2, attachments, { - target: this.getTarget - }, this.props.tether); + return new Error('You provided a `value` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultValue`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); + }, + checked: function (props, propName, componentName) { + if (!props[propName] || props.onChange || props.readOnly || props.disabled) { + return null; } - }, { - key: 'show', - value: function show() { - if (!this.props.isOpen) { - this.clearShowTimeout(); - this.toggle(); - } + return new Error('You provided a `checked` prop to a form field without an ' + '`onChange` handler. This will render a read-only field. If ' + 'the field should be mutable use `defaultChecked`. Otherwise, ' + 'set either `onChange` or `readOnly`.'); + }, + onChange: PropTypes.func +}; + +var loggedTypeFailures = {}; +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; } - }, { - key: 'hide', - value: function hide() { - if (this.props.isOpen) { - this.clearHideTimeout(); - this.toggle(); + } + return ''; +} + +/** + * Provide a linked `value` attribute for controlled forms. You should not use + * this outside of the ReactDOM controlled form components. + */ +var LinkedValueUtils = { + checkPropTypes: function (tagName, props, owner) { + for (var propName in propTypes) { + if (propTypes.hasOwnProperty(propName)) { + var error = propTypes[propName](props, propName, tagName, 'prop', null, ReactPropTypesSecret); } - } - }, { - key: 'clearShowTimeout', - value: function clearShowTimeout() { - clearTimeout(this._showTimeout); - this._showTimeout = undefined; - } - }, { - key: 'clearHideTimeout', - value: function clearHideTimeout() { - clearTimeout(this._hideTimeout); - this._hideTimeout = undefined; - } - }, { - key: 'handleDocumentClick', - value: function handleDocumentClick(e) { - if (e.target === this._target || this._target.contains(e.target)) { - if (this._hideTimeout) { - this.clearHideTimeout(); - } + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; - if (!this.props.isOpen) { - this.toggle(); - } + var addendum = getDeclarationErrorAddendum(owner); + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed form propType: %s%s', error.message, addendum) : void 0; } } - }, { - key: 'addTargetEvents', - value: function addTargetEvents() { - this._target.addEventListener('mouseover', this.onMouseOverTooltip, true); - this._target.addEventListener('mouseout', this.onMouseLeaveTooltip, true); - document.addEventListener('click', this.handleDocumentClick, true); - } - }, { - key: 'removeTargetEvents', - value: function removeTargetEvents() { - this._target.removeEventListener('mouseover', this.onMouseOverTooltip, true); - this._target.removeEventListener('mouseout', this.onMouseLeaveTooltip, true); - document.removeEventListener('click', this.handleDocumentClick, true); - } - }, { - key: 'toggle', - value: function toggle(e) { - if (this.props.disabled) { - return e && e.preventDefault(); - } + }, - return this.props.toggle(); + /** + * @param {object} inputProps Props for form component + * @return {*} current value of the input either from value prop or link. + */ + getValue: function (inputProps) { + if (inputProps.valueLink) { + _assertValueLink(inputProps); + return inputProps.valueLink.value; } - }, { - key: 'render', - value: function render() { - if (!this.props.isOpen) { - return null; - } - - var attributes = omit(this.props, Object.keys(propTypes$44)); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tooltip-inner', this.props.className), this.props.cssModule); - - var tetherConfig = this.getTetherConfig(); + return inputProps.value; + }, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - TetherContent, - { - className: 'tooltip', - tether: tetherConfig, - tetherRef: this.props.tetherRef, - isOpen: this.props.isOpen, - toggle: this.toggle - }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { - className: classes, - onMouseOver: this.onMouseOverTooltipContent, - onMouseLeave: this.onMouseLeaveTooltipContent - })) - ); + /** + * @param {object} inputProps Props for form component + * @return {*} current checked status of the input either from checked prop + * or link. + */ + getChecked: function (inputProps) { + if (inputProps.checkedLink) { + _assertCheckedLink(inputProps); + return inputProps.checkedLink.value; } - }]); - return Tooltip; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - -Tooltip.propTypes = propTypes$44; -Tooltip.defaultProps = defaultProps$43; - -var propTypes$45 = { - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - bordered: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - hover: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - reflow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - responsive: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - responsiveTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; + return inputProps.checked; + }, -var defaultProps$44 = { - tag: 'table', - responsiveTag: 'div' + /** + * @param {object} inputProps Props for form component + * @param {SyntheticEvent} event change event to handle + */ + executeOnChange: function (inputProps, event) { + if (inputProps.valueLink) { + _assertValueLink(inputProps); + return inputProps.valueLink.requestChange(event.target.value); + } else if (inputProps.checkedLink) { + _assertCheckedLink(inputProps); + return inputProps.checkedLink.requestChange(event.target.checked); + } else if (inputProps.onChange) { + return inputProps.onChange.call(undefined, event); + } + } }; -var Table = function Table(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - bordered = props.bordered, - striped = props.striped, - inverse = props.inverse, - hover = props.hover, - reflow = props.reflow, - responsive = props.responsive, - Tag = props.tag, - ResponsiveTag = props.responsiveTag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'bordered', 'striped', 'inverse', 'hover', 'reflow', 'responsive', 'tag', 'responsiveTag']); - +module.exports = LinkedValueUtils; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'table', size ? 'table-' + size : false, bordered ? 'table-bordered' : false, striped ? 'table-striped' : false, inverse ? 'table-inverse' : false, hover ? 'table-hover' : false, reflow ? 'table-reflow' : false), cssModule); +/***/ }), +/* 86 */ +/***/ (function(module, exports, __webpack_require__) { - var table = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - if (responsive) { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - ResponsiveTag, - { className: 'table-responsive' }, - table - ); - } - return table; -}; -Table.propTypes = propTypes$45; -Table.defaultProps = defaultProps$44; +var _prodInvariant = __webpack_require__(5); -var propTypes$46 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - flush: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +var invariant = __webpack_require__(2); -var defaultProps$45 = { - tag: 'ul' -}; +var injected = false; -var ListGroup = function ListGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - flush = props.flush, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'flush']); +var ReactComponentEnvironment = { + /** + * Optionally injectable hook for swapping out mount images in the middle of + * the tree. + */ + replaceNodeWithMarkup: null, - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group', flush ? 'list-group-flush' : false), cssModule); + /** + * Optionally injectable hook for processing a queue of child updates. Will + * later move into MultiChildComponents. + */ + processChildrenUpdates: null, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + injection: { + injectEnvironment: function (environment) { + !!injected ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactCompositeComponent: injectEnvironment() can only be called once.') : _prodInvariant('104') : void 0; + ReactComponentEnvironment.replaceNodeWithMarkup = environment.replaceNodeWithMarkup; + ReactComponentEnvironment.processChildrenUpdates = environment.processChildrenUpdates; + injected = true; + } + } }; -ListGroup.propTypes = propTypes$46; -ListGroup.defaultProps = defaultProps$45; - -var propTypes$47 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +module.exports = ReactComponentEnvironment; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var defaultProps$46 = { - tag: 'form' -}; +/***/ }), +/* 87 */ +/***/ (function(module, exports, __webpack_require__) { -var Form = function Form(props) { - var className = props.className, - cssModule = props.cssModule, - inline = props.inline, - Tag = props.tag, - getRef = props.getRef, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'tag', 'getRef']); +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + * + */ +/*eslint-disable no-self-compare */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, inline ? 'form-inline' : false), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); -}; -Form.propTypes = propTypes$47; -Form.defaultProps = defaultProps$46; +var hasOwnProperty = Object.prototype.hasOwnProperty; -var propTypes$48 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +/** + * inlined Object.is polyfill to avoid requiring consumers ship their own + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is + */ +function is(x, y) { + // SameValue algorithm + if (x === y) { + // Steps 1-5, 7-10 + // Steps 6.b-6.e: +0 != -0 + // Added the nonzero y check to make Flow happy, but it is redundant + return x !== 0 || y !== 0 || 1 / x === 1 / y; + } else { + // Step 6.a: NaN == NaN + return x !== x && y !== y; + } +} -var defaultProps$47 = { - tag: 'div' -}; +/** + * Performs equality by iterating through keys on an object and returning false + * when any key has values which are not strictly equal between the arguments. + * Returns true when the values of all keys are strictly equal. + */ +function shallowEqual(objA, objB) { + if (is(objA, objB)) { + return true; + } -var FormFeedback = function FormFeedback(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + if (typeof objA !== 'object' || objA === null || typeof objB !== 'object' || objB === null) { + return false; + } + var keysA = Object.keys(objA); + var keysB = Object.keys(objB); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'form-control-feedback'), cssModule); + if (keysA.length !== keysB.length) { + return false; + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + // Test for A's keys different from B. + for (var i = 0; i < keysA.length; i++) { + if (!hasOwnProperty.call(objB, keysA[i]) || !is(objA[keysA[i]], objB[keysA[i]])) { + return false; + } + } -FormFeedback.propTypes = propTypes$48; -FormFeedback.defaultProps = defaultProps$47; + return true; +} -var propTypes$49 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - row: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; +module.exports = shallowEqual; -var defaultProps$48 = { - tag: 'div' -}; +/***/ }), +/* 88 */ +/***/ (function(module, exports, __webpack_require__) { -var FormGroup = function FormGroup(props) { - var className = props.className, - cssModule = props.cssModule, - row = props.row, - disabled = props.disabled, - color = props.color, - check = props.check, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'row', 'disabled', 'color', 'check', 'tag']); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, color ? 'has-' + color : false, row ? 'row' : false, check ? 'form-check' : 'form-group', check && disabled ? 'disabled' : false), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/** + * Given a `prevElement` and `nextElement`, determines if the existing + * instance should be updated as opposed to being destroyed or replaced by a new + * instance. Both arguments are elements. This ensures that this logic can + * operate on stateless trees without any backing instance. + * + * @param {?object} prevElement + * @param {?object} nextElement + * @return {boolean} True if the existing instance should be updated. + * @protected + */ -FormGroup.propTypes = propTypes$49; -FormGroup.defaultProps = defaultProps$48; +function shouldUpdateReactComponent(prevElement, nextElement) { + var prevEmpty = prevElement === null || prevElement === false; + var nextEmpty = nextElement === null || nextElement === false; + if (prevEmpty || nextEmpty) { + return prevEmpty === nextEmpty; + } -var propTypes$50 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var prevType = typeof prevElement; + var nextType = typeof nextElement; + if (prevType === 'string' || prevType === 'number') { + return nextType === 'string' || nextType === 'number'; + } else { + return nextType === 'object' && prevElement.type === nextElement.type && prevElement.key === nextElement.key; + } +} -var defaultProps$49 = { - tag: 'small' -}; +module.exports = shouldUpdateReactComponent; -var FormText = function FormText(props) { - var className = props.className, - cssModule = props.cssModule, - inline = props.inline, - color = props.color, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'color', 'tag']); +/***/ }), +/* 89 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, !inline ? 'form-text' : false, color ? 'text-' + color : false), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; -FormText.propTypes = propTypes$50; -FormText.defaultProps = defaultProps$49; +/** + * Escape and wrap key so it is safe to use as a reactid + * + * @param {string} key to be escaped. + * @return {string} the escaped key. + */ -/* eslint react/prefer-stateless-function: 0 */ +function escape(key) { + var escapeRegex = /[=:]/g; + var escaperLookup = { + '=': '=0', + ':': '=2' + }; + var escapedString = ('' + key).replace(escapeRegex, function (match) { + return escaperLookup[match]; + }); -var propTypes$51 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - state: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - static: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - addon: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + return '$' + escapedString; +} -var defaultProps$50 = { - tag: 'p', - type: 'text' +/** + * Unescape and unwrap key for human-readable display + * + * @param {string} key to unescape. + * @return {string} the unescaped key. + */ +function unescape(key) { + var unescapeRegex = /(=0|=2)/g; + var unescaperLookup = { + '=0': '=', + '=2': ':' + }; + var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); + + return ('' + keySubstring).replace(unescapeRegex, function (match) { + return unescaperLookup[match]; + }); +} + +var KeyEscapeUtils = { + escape: escape, + unescape: unescape }; -var Input = function (_React$Component) { - inherits(Input, _React$Component); +module.exports = KeyEscapeUtils; - function Input() { - classCallCheck(this, Input); - return possibleConstructorReturn(this, (Input.__proto__ || Object.getPrototypeOf(Input)).apply(this, arguments)); - } +/***/ }), +/* 90 */ +/***/ (function(module, exports, __webpack_require__) { - createClass(Input, [{ - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - type = _props.type, - size = _props.size, - state = _props.state, - tag = _props.tag, - addon = _props.addon, - staticInput = _props.static, - getRef = _props.getRef, - attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'type', 'size', 'state', 'tag', 'addon', 'static', 'getRef']); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var checkInput = ['radio', 'checkbox'].indexOf(type) > -1; - var fileInput = type === 'file'; - var textareaInput = type === 'textarea'; - var selectInput = type === 'select'; - var Tag = selectInput || textareaInput ? type : 'input'; +var _prodInvariant = __webpack_require__(5); - var formControlClass = 'form-control'; +var ReactCurrentOwner = __webpack_require__(22); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactUpdates = __webpack_require__(23); - if (staticInput) { - formControlClass = formControlClass + '-static'; - Tag = tag; - } else if (fileInput) { - formControlClass = formControlClass + '-file'; - } else if (checkInput) { - if (addon) { - formControlClass = null; - } else { - formControlClass = 'form-check-input'; - } - } +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, state ? 'form-control-' + state : false, size ? 'form-control-' + size : false, formControlClass), cssModule); +function enqueueUpdate(internalInstance) { + ReactUpdates.enqueueUpdate(internalInstance); +} - if (Tag === 'input') { - attributes.type = type; - } +function formatUnexpectedArgument(arg) { + var type = typeof arg; + if (type !== 'object') { + return type; + } + var displayName = arg.constructor && arg.constructor.name || type; + var keys = Object.keys(arg); + if (keys.length > 0 && keys.length < 20) { + return displayName + ' (keys: ' + keys.join(', ') + ')'; + } + return displayName; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); +function getInternalInstanceReadyForUpdate(publicInstance, callerName) { + var internalInstance = ReactInstanceMap.get(publicInstance); + if (!internalInstance) { + if (process.env.NODE_ENV !== 'production') { + var ctor = publicInstance.constructor; + // Only warn when we have a callerName. Otherwise we should be silent. + // We're probably calling from enqueueCallback. We don't want to warn + // there because we already warned for the corresponding lifecycle method. + process.env.NODE_ENV !== 'production' ? warning(!callerName, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, ctor && (ctor.displayName || ctor.name) || 'ReactClass') : void 0; } - }]); - return Input; -}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); + return null; + } -Input.propTypes = propTypes$51; -Input.defaultProps = defaultProps$50; + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '%s(...): Cannot update during an existing state transition (such as ' + "within `render` or another component's constructor). Render methods " + 'should be a pure function of props and state; constructor ' + 'side-effects are an anti-pattern, but can be moved to ' + '`componentWillMount`.', callerName) : void 0; + } -var propTypes$52 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + return internalInstance; +} -var defaultProps$51 = { - tag: 'div' -}; +/** + * ReactUpdateQueue allows for state updates to be scheduled into a later + * reconciliation step. + */ +var ReactUpdateQueue = { + /** + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + isMounted: function (publicInstance) { + if (process.env.NODE_ENV !== 'production') { + var owner = ReactCurrentOwner.current; + if (owner !== null) { + process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing isMounted inside its render() function. ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; + owner._warnedAboutRefsInRender = true; + } + } + var internalInstance = ReactInstanceMap.get(publicInstance); + if (internalInstance) { + // During componentWillMount and render this will still be null but after + // that will always render to something. At least for now. So we can use + // this hack. + return !!internalInstance._renderedComponent; + } else { + return false; + } + }, -var InputGroup = function InputGroup(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - size = props.size, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'size']); + /** + * Enqueue a callback that will be executed after all the pending updates + * have processed. + * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @param {string} callerName Name of the calling function in the public API. + * @internal + */ + enqueueCallback: function (publicInstance, callback, callerName) { + ReactUpdateQueue.validateCallback(callback, callerName); + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group', size ? 'input-group-' + size : null), cssModule); + // Previously we would throw an error if we didn't have an internal + // instance. Since we want to make it a no-op instead, we mirror the same + // behavior we have in other enqueue* methods. + // We also need to ignore callbacks in componentWillMount. See + // enqueueUpdates. + if (!internalInstance) { + return null; + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); + } else { + internalInstance._pendingCallbacks = [callback]; + } + // TODO: The callback here is ignored when setState is called from + // componentWillMount. Either fix it or disallow doing so completely in + // favor of getInitialState. Alternatively, we can disallow + // componentWillMount during server-side rendering. + enqueueUpdate(internalInstance); + }, -InputGroup.propTypes = propTypes$52; -InputGroup.defaultProps = defaultProps$51; + enqueueCallbackInternal: function (internalInstance, callback) { + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); + } else { + internalInstance._pendingCallbacks = [callback]; + } + enqueueUpdate(internalInstance); + }, -var propTypes$53 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + /** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal + */ + enqueueForceUpdate: function (publicInstance) { + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'forceUpdate'); -var defaultProps$52 = { - tag: 'div' -}; + if (!internalInstance) { + return; + } -var InputGroupAddon = function InputGroupAddon(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + internalInstance._pendingForceUpdate = true; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-addon'), cssModule); + enqueueUpdate(internalInstance); + }, - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} completeState Next state. + * @internal + */ + enqueueReplaceState: function (publicInstance, completeState, callback) { + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'replaceState'); -InputGroupAddon.propTypes = propTypes$53; -InputGroupAddon.defaultProps = defaultProps$52; + if (!internalInstance) { + return; + } -var propTypes$54 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - groupClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - groupAttributes: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + internalInstance._pendingStateQueue = [completeState]; + internalInstance._pendingReplaceState = true; -var defaultProps$53 = { - tag: 'div' -}; + // Future-proof 15.5 + if (callback !== undefined && callback !== null) { + ReactUpdateQueue.validateCallback(callback, 'replaceState'); + if (internalInstance._pendingCallbacks) { + internalInstance._pendingCallbacks.push(callback); + } else { + internalInstance._pendingCallbacks = [callback]; + } + } -var InputGroupButton = function InputGroupButton(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - children = props.children, - groupClassName = props.groupClassName, - groupAttributes = props.groupAttributes, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'children', 'groupClassName', 'groupAttributes']); + enqueueUpdate(internalInstance); + }, + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} partialState Next partial state to be merged with state. + * @internal + */ + enqueueSetState: function (publicInstance, partialState) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetState(); + process.env.NODE_ENV !== 'production' ? warning(partialState != null, 'setState(...): You passed an undefined or null state object; ' + 'instead, use forceUpdate().') : void 0; + } - if (typeof children === 'string') { - var groupClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(groupClassName, 'input-group-btn'), cssModule); + var internalInstance = getInternalInstanceReadyForUpdate(publicInstance, 'setState'); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, groupAttributes, { className: groupClasses }), - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Button, _extends({}, attributes, { className: className, children: children })) - ); - } + if (!internalInstance) { + return; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-btn'), cssModule); + var queue = internalInstance._pendingStateQueue || (internalInstance._pendingStateQueue = []); + queue.push(partialState); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes, children: children })); -}; + enqueueUpdate(internalInstance); + }, -InputGroupButton.propTypes = propTypes$54; -InputGroupButton.defaultProps = defaultProps$53; + enqueueElementInternal: function (internalInstance, nextElement, nextContext) { + internalInstance._pendingElement = nextElement; + // TODO: introduce _pendingContext instead of setting it directly. + internalInstance._context = nextContext; + enqueueUpdate(internalInstance); + }, -var colSizes = ['xs', 'sm', 'md', 'lg', 'xl']; + validateCallback: function (callback, callerName) { + !(!callback || typeof callback === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.', callerName, formatUnexpectedArgument(callback)) : _prodInvariant('122', callerName, formatUnexpectedArgument(callback)) : void 0; + } +}; -var stringOrNumberProp$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); +module.exports = ReactUpdateQueue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var columnProps$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ - size: stringOrNumberProp$1, - push: stringOrNumberProp$1, - pull: stringOrNumberProp$1, - offset: stringOrNumberProp$1 -})]); +/***/ }), +/* 91 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$55 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - hidden: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - for: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - xs: columnProps$1, - sm: columnProps$1, - md: columnProps$1, - lg: columnProps$1, - xl: columnProps$1 -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var defaultProps$54 = { - tag: 'label' -}; -var Label = function Label(props) { - var className = props.className, - cssModule = props.cssModule, - hidden = props.hidden, - Tag = props.tag, - check = props.check, - inline = props.inline, - disabled = props.disabled, - size = props.size, - htmlFor = props.for, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'hidden', 'tag', 'check', 'inline', 'disabled', 'size', 'for']); +var _assign = __webpack_require__(8); - var colClasses = []; +var emptyFunction = __webpack_require__(18); +var warning = __webpack_require__(3); - colSizes.forEach(function (colSize) { - var columnProp = props[colSize]; - delete attributes[colSize]; +var validateDOMNesting = emptyFunction; - if (columnProp && columnProp.size) { - var _classNames; +if (process.env.NODE_ENV !== 'production') { + // This validation code was written based on the HTML5 parsing spec: + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope + // + // Note: this does not catch all invalid nesting, nor does it try to (as it's + // not clear what practical benefit doing so provides); instead, we warn only + // for cases where the parser will give a parse tree differing from what React + // intended. For example, <b><div></div></b> is invalid but we don't warn + // because it still parses correctly; we do warn for other cases like nested + // <p> tags where the beginning of the second element implicitly closes the + // first, causing a confusing mess. - colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, 'col-' + colSize + '-' + columnProp.size, columnProp.size), defineProperty(_classNames, 'push-' + colSize + '-' + columnProp.push, columnProp.push), defineProperty(_classNames, 'pull-' + colSize + '-' + columnProp.pull, columnProp.pull), defineProperty(_classNames, 'offset-' + colSize + '-' + columnProp.offset, columnProp.offset), _classNames))), cssModule); - } else if (columnProp) { - colClasses.push('col-' + colSize + '-' + columnProp); - } - }); + // https://html.spec.whatwg.org/multipage/syntax.html#special + var specialTags = ['address', 'applet', 'area', 'article', 'aside', 'base', 'basefont', 'bgsound', 'blockquote', 'body', 'br', 'button', 'caption', 'center', 'col', 'colgroup', 'dd', 'details', 'dir', 'div', 'dl', 'dt', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'frame', 'frameset', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'iframe', 'img', 'input', 'isindex', 'li', 'link', 'listing', 'main', 'marquee', 'menu', 'menuitem', 'meta', 'nav', 'noembed', 'noframes', 'noscript', 'object', 'ol', 'p', 'param', 'plaintext', 'pre', 'script', 'section', 'select', 'source', 'style', 'summary', 'table', 'tbody', 'td', 'template', 'textarea', 'tfoot', 'th', 'thead', 'title', 'tr', 'track', 'ul', 'wbr', 'xmp']; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, hidden ? 'sr-only' : false, check ? 'form-check-' + (inline ? 'inline' : 'label') : false, check && inline && disabled ? 'disabled' : false, size ? 'col-form-label-' + size : false, colClasses, colClasses.length ? 'col-form-label' : false, !check && !colClasses.length ? 'form-control-label' : false), cssModule); + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-scope + var inScopeTags = ['applet', 'caption', 'html', 'table', 'td', 'th', 'marquee', 'object', 'template', - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ htmlFor: htmlFor }, attributes, { className: classes })); -}; + // https://html.spec.whatwg.org/multipage/syntax.html#html-integration-point + // TODO: Distinguish by namespace here -- for <title>, including it here + // errs on the side of fewer warnings + 'foreignObject', 'desc', 'title']; -Label.propTypes = propTypes$55; -Label.defaultProps = defaultProps$54; + // https://html.spec.whatwg.org/multipage/syntax.html#has-an-element-in-button-scope + var buttonScopeTags = inScopeTags.concat(['button']); -var propTypes$56 = { - body: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - heading: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - list: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - middle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - object: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool -}; + // https://html.spec.whatwg.org/multipage/syntax.html#generate-implied-end-tags + var impliedEndTags = ['dd', 'dt', 'li', 'option', 'optgroup', 'p', 'rp', 'rt']; -var Media = function Media(props) { - var body = props.body, - bottom = props.bottom, - className = props.className, - cssModule = props.cssModule, - heading = props.heading, - left = props.left, - list = props.list, - middle = props.middle, - object = props.object, - right = props.right, - tag = props.tag, - top = props.top, - attributes = objectWithoutProperties(props, ['body', 'bottom', 'className', 'cssModule', 'heading', 'left', 'list', 'middle', 'object', 'right', 'tag', 'top']); + var emptyAncestorInfo = { + current: null, + formTag: null, + aTagInScope: null, + buttonTagInScope: null, + nobrTagInScope: null, + pTagInButtonScope: null, - var defaultTag = void 0; - if (heading) { - defaultTag = 'h4'; - } else if (left || right) { - defaultTag = 'a'; - } else if (object) { - defaultTag = 'img'; - } else if (list) { - defaultTag = 'ul'; - } else { - defaultTag = 'div'; - } - var Tag = tag || defaultTag; + listItemTagAutoclosing: null, + dlItemTagAutoclosing: null + }; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { - 'media-body': body, - 'media-heading': heading, - 'media-left': left, - 'media-right': right, - 'media-top': top, - 'media-bottom': bottom, - 'media-middle': middle, - 'media-object': object, - 'media-list': list, - media: !body && !heading && !left && !right && !top && !bottom && !middle && !object && !list - }), cssModule); + var updatedAncestorInfo = function (oldInfo, tag, instance) { + var ancestorInfo = _assign({}, oldInfo || emptyAncestorInfo); + var info = { tag: tag, instance: instance }; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + if (inScopeTags.indexOf(tag) !== -1) { + ancestorInfo.aTagInScope = null; + ancestorInfo.buttonTagInScope = null; + ancestorInfo.nobrTagInScope = null; + } + if (buttonScopeTags.indexOf(tag) !== -1) { + ancestorInfo.pTagInButtonScope = null; + } -Media.propTypes = propTypes$56; + // See rules for 'li', 'dd', 'dt' start tags in + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody + if (specialTags.indexOf(tag) !== -1 && tag !== 'address' && tag !== 'div' && tag !== 'p') { + ancestorInfo.listItemTagAutoclosing = null; + ancestorInfo.dlItemTagAutoclosing = null; + } -var propTypes$57 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; + ancestorInfo.current = info; -var defaultProps$55 = { - tag: 'ul' -}; + if (tag === 'form') { + ancestorInfo.formTag = info; + } + if (tag === 'a') { + ancestorInfo.aTagInScope = info; + } + if (tag === 'button') { + ancestorInfo.buttonTagInScope = info; + } + if (tag === 'nobr') { + ancestorInfo.nobrTagInScope = info; + } + if (tag === 'p') { + ancestorInfo.pTagInButtonScope = info; + } + if (tag === 'li') { + ancestorInfo.listItemTagAutoclosing = info; + } + if (tag === 'dd' || tag === 'dt') { + ancestorInfo.dlItemTagAutoclosing = info; + } -var Pagination = function Pagination(props) { - var className = props.className, - cssModule = props.cssModule, - size = props.size, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'tag']); + return ancestorInfo; + }; + /** + * Returns whether + */ + var isTagValidWithParent = function (tag, parentTag) { + // First, let's check if we're in an unusual parsing mode... + switch (parentTag) { + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inselect + case 'select': + return tag === 'option' || tag === 'optgroup' || tag === '#text'; + case 'optgroup': + return tag === 'option' || tag === '#text'; + // Strictly speaking, seeing an <option> doesn't mean we're in a <select> + // but + case 'option': + return tag === '#text'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intd + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incaption + // No special behavior since these rules fall back to "in body" mode for + // all except special table nodes which cause bad parsing behavior anyway. - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'pagination', defineProperty({}, 'pagination-' + size, !!size)), cssModule); + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intr + case 'tr': + return tag === 'th' || tag === 'td' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intbody + case 'tbody': + case 'thead': + case 'tfoot': + return tag === 'tr' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-incolgroup + case 'colgroup': + return tag === 'col' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-intable + case 'table': + return tag === 'caption' || tag === 'colgroup' || tag === 'tbody' || tag === 'tfoot' || tag === 'thead' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inhead + case 'head': + return tag === 'base' || tag === 'basefont' || tag === 'bgsound' || tag === 'link' || tag === 'meta' || tag === 'title' || tag === 'noscript' || tag === 'noframes' || tag === 'style' || tag === 'script' || tag === 'template'; + // https://html.spec.whatwg.org/multipage/semantics.html#the-html-element + case 'html': + return tag === 'head' || tag === 'body'; + case '#document': + return tag === 'html'; + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + // Probably in the "in body" parsing mode, so we outlaw only tag combos + // where the parsing rules cause implicit opens or closes to be added. + // https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inbody + switch (tag) { + case 'h1': + case 'h2': + case 'h3': + case 'h4': + case 'h5': + case 'h6': + return parentTag !== 'h1' && parentTag !== 'h2' && parentTag !== 'h3' && parentTag !== 'h4' && parentTag !== 'h5' && parentTag !== 'h6'; -Pagination.propTypes = propTypes$57; -Pagination.defaultProps = defaultProps$55; + case 'rp': + case 'rt': + return impliedEndTags.indexOf(parentTag) === -1; -var propTypes$58 = { - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; + case 'body': + case 'caption': + case 'col': + case 'colgroup': + case 'frame': + case 'head': + case 'html': + case 'tbody': + case 'td': + case 'tfoot': + case 'th': + case 'thead': + case 'tr': + // These tags are only valid with a few parents that have special child + // parsing rules -- if we're down here, then none of those matched and + // so we allow it only if we don't know what the parent is, as all other + // cases are invalid. + return parentTag == null; + } -var defaultProps$56 = { - tag: 'li' -}; + return true; + }; -var PaginationItem = function PaginationItem(props) { - var active = props.active, - className = props.className, - cssModule = props.cssModule, - disabled = props.disabled, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['active', 'className', 'cssModule', 'disabled', 'tag']); + /** + * Returns whether + */ + var findInvalidAncestorForTag = function (tag, ancestorInfo) { + switch (tag) { + case 'address': + case 'article': + case 'aside': + case 'blockquote': + case 'center': + case 'details': + case 'dialog': + case 'dir': + case 'div': + case 'dl': + case 'fieldset': + case 'figcaption': + case 'figure': + case 'footer': + case 'header': + case 'hgroup': + case 'main': + case 'menu': + case 'nav': + case 'ol': + case 'p': + case 'section': + case 'summary': + case 'ul': + case 'pre': + case 'listing': + case 'table': + case 'hr': + case 'xmp': + case 'h1': + case 'h2': + case 'h3': + case 'h4': + case 'h5': + case 'h6': + return ancestorInfo.pTagInButtonScope; + case 'form': + return ancestorInfo.formTag || ancestorInfo.pTagInButtonScope; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-item', { - active: active, - disabled: disabled - }), cssModule); + case 'li': + return ancestorInfo.listItemTagAutoclosing; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; + case 'dd': + case 'dt': + return ancestorInfo.dlItemTagAutoclosing; -PaginationItem.propTypes = propTypes$58; -PaginationItem.defaultProps = defaultProps$56; + case 'button': + return ancestorInfo.buttonTagInScope; -var propTypes$59 = { - 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - next: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - previous: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) -}; + case 'a': + // Spec says something about storing a list of markers, but it sounds + // equivalent to this check. + return ancestorInfo.aTagInScope; -var defaultProps$57 = { - tag: 'a' -}; + case 'nobr': + return ancestorInfo.nobrTagInScope; + } -var PaginationLink = function PaginationLink(props) { - var className = props.className, - cssModule = props.cssModule, - next = props.next, - previous = props.previous, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'next', 'previous', 'tag']); + return null; + }; + /** + * Given a ReactCompositeComponent instance, return a list of its recursive + * owners, starting at the root and ending with the instance itself. + */ + var findOwnerStack = function (instance) { + if (!instance) { + return []; + } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-link'), cssModule); + var stack = []; + do { + stack.push(instance); + } while (instance = instance._currentElement._owner); + stack.reverse(); + return stack; + }; - var defaultAriaLabel = void 0; - if (previous) { - defaultAriaLabel = 'Previous'; - } else if (next) { - defaultAriaLabel = 'Next'; - } - var ariaLabel = props['aria-label'] || defaultAriaLabel; + var didWarn = {}; - var defaultCaret = void 0; - if (previous) { - defaultCaret = '\xAB'; - } else if (next) { - defaultCaret = '\xBB'; - } + validateDOMNesting = function (childTag, childText, childInstance, ancestorInfo) { + ancestorInfo = ancestorInfo || emptyAncestorInfo; + var parentInfo = ancestorInfo.current; + var parentTag = parentInfo && parentInfo.tag; - var children = props.children; - if (previous || next) { - children = [__WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { - 'aria-hidden': 'true', - key: 'caret' - }, - children || defaultCaret - ), __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { - className: 'sr-only', - key: 'sr' - }, - ariaLabel - )]; - } + if (childText != null) { + process.env.NODE_ENV !== 'production' ? warning(childTag == null, 'validateDOMNesting: when childText is passed, childTag should be null') : void 0; + childTag = '#text'; + } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { - className: classes, - 'aria-label': ariaLabel - }), - children - ); -}; + var invalidParent = isTagValidWithParent(childTag, parentTag) ? null : parentInfo; + var invalidAncestor = invalidParent ? null : findInvalidAncestorForTag(childTag, ancestorInfo); + var problematic = invalidParent || invalidAncestor; -PaginationLink.propTypes = propTypes$59; -PaginationLink.defaultProps = defaultProps$57; + if (problematic) { + var ancestorTag = problematic.tag; + var ancestorInstance = problematic.instance; -var propTypes$60 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - activeTab: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + var childOwner = childInstance && childInstance._currentElement._owner; + var ancestorOwner = ancestorInstance && ancestorInstance._currentElement._owner; -var defaultProps$58 = { - tag: 'div' -}; + var childOwners = findOwnerStack(childOwner); + var ancestorOwners = findOwnerStack(ancestorOwner); -var childContextTypes$1 = { - activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; + var minStackLen = Math.min(childOwners.length, ancestorOwners.length); + var i; -var TabContent = function (_Component) { - inherits(TabContent, _Component); + var deepestCommon = -1; + for (i = 0; i < minStackLen; i++) { + if (childOwners[i] === ancestorOwners[i]) { + deepestCommon = i; + } else { + break; + } + } - function TabContent(props) { - classCallCheck(this, TabContent); + var UNKNOWN = '(unknown)'; + var childOwnerNames = childOwners.slice(deepestCommon + 1).map(function (inst) { + return inst.getName() || UNKNOWN; + }); + var ancestorOwnerNames = ancestorOwners.slice(deepestCommon + 1).map(function (inst) { + return inst.getName() || UNKNOWN; + }); + var ownerInfo = [].concat( + // If the parent and child instances have a common owner ancestor, start + // with that -- otherwise we just start with the parent's owners. + deepestCommon !== -1 ? childOwners[deepestCommon].getName() || UNKNOWN : [], ancestorOwnerNames, ancestorTag, + // If we're warning about an invalid (non-parent) ancestry, add '...' + invalidAncestor ? ['...'] : [], childOwnerNames, childTag).join(' > '); - var _this = possibleConstructorReturn(this, (TabContent.__proto__ || Object.getPrototypeOf(TabContent)).call(this, props)); + var warnKey = !!invalidParent + '|' + childTag + '|' + ancestorTag + '|' + ownerInfo; + if (didWarn[warnKey]) { + return; + } + didWarn[warnKey] = true; - _this.state = { - activeTab: _this.props.activeTab - }; - return _this; - } + var tagDisplayName = childTag; + var whitespaceInfo = ''; + if (childTag === '#text') { + if (/\S/.test(childText)) { + tagDisplayName = 'Text nodes'; + } else { + tagDisplayName = 'Whitespace text nodes'; + whitespaceInfo = " Make sure you don't have any extra whitespace between tags on " + 'each line of your source code.'; + } + } else { + tagDisplayName = '<' + childTag + '>'; + } - createClass(TabContent, [{ - key: 'getChildContext', - value: function getChildContext() { - return { - activeTabId: this.state.activeTab - }; - } - }, { - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - if (this.state.activeTab !== nextProps.activeTab) { - this.setState({ - activeTab: nextProps.activeTab - }); + if (invalidParent) { + var info = ''; + if (ancestorTag === 'table' && childTag === 'tr') { + info += ' Add a <tbody> to your code to match the DOM tree generated by ' + 'the browser.'; + } + process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a child of <%s>.%s ' + 'See %s.%s', tagDisplayName, ancestorTag, whitespaceInfo, ownerInfo, info) : void 0; + } else { + process.env.NODE_ENV !== 'production' ? warning(false, 'validateDOMNesting(...): %s cannot appear as a descendant of ' + '<%s>. See %s.', tagDisplayName, ancestorTag, ownerInfo) : void 0; } } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - cssModule = _props.cssModule, - Tag = _props.tag; - + }; - var attributes = omit(this.props, Object.keys(propTypes$60)); + validateDOMNesting.updatedAncestorInfo = updatedAncestorInfo; - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-content', className), cssModule); + // For testing + validateDOMNesting.isTagValidInContext = function (tag, ancestorInfo) { + ancestorInfo = ancestorInfo || emptyAncestorInfo; + var parentInfo = ancestorInfo.current; + var parentTag = parentInfo && parentInfo.tag; + return isTagValidWithParent(tag, parentTag) && !findInvalidAncestorForTag(tag, ancestorInfo); + }; +} - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); - } - }]); - return TabContent; -}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); +module.exports = validateDOMNesting; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -TabContent.propTypes = propTypes$60; -TabContent.defaultProps = defaultProps$58; -TabContent.childContextTypes = childContextTypes$1; +/***/ }), +/* 92 */ +/***/ (function(module, exports, __webpack_require__) { -var propTypes$61 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - tabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var defaultProps$59 = { - tag: 'div' -}; -var contextTypes$3 = { - activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any -}; -function TabPane(props, context) { - var className = props.className, - cssModule = props.cssModule, - tabId = props.tabId, - Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabId', 'tag']); +/** + * `charCode` represents the actual "character code" and is safe to use with + * `String.fromCharCode`. As such, only keys that correspond to printable + * characters produce a valid `charCode`, the only exception to this is Enter. + * The Tab-key is considered non-printable and does not have a `charCode`, + * presumably because it does not produce a tab-character in browsers. + * + * @param {object} nativeEvent Native browser event. + * @return {number} Normalized `charCode` property. + */ - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-pane', className, { active: tabId === context.activeTabId }), cssModule); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -} -TabPane.propTypes = propTypes$61; -TabPane.defaultProps = defaultProps$59; -TabPane.contextTypes = contextTypes$3; +function getEventCharCode(nativeEvent) { + var charCode; + var keyCode = nativeEvent.keyCode; -var propTypes$62 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object -}; + if ('charCode' in nativeEvent) { + charCode = nativeEvent.charCode; -var defaultProps$60 = { - tag: 'div' -}; + // FF does not set `charCode` for the Enter-key, check against `keyCode`. + if (charCode === 0 && keyCode === 13) { + charCode = 13; + } + } else { + // IE8 does not implement `charCode`, but `keyCode` has the correct value. + charCode = keyCode; + } -var Jumbotron = function Jumbotron(props) { - var className = props.className, - cssModule = props.cssModule, - Tag = props.tag, - fluid = props.fluid, - attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'fluid']); + // Some non-printable keys are reported in `charCode`/`keyCode`, discard them. + // Must not discard the (non-)printable Enter-key. + if (charCode >= 32 || charCode === 13) { + return charCode; + } + return 0; +} - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'jumbotron', fluid ? 'jumbotron-fluid' : false), cssModule); +module.exports = getEventCharCode; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -}; +/***/ }), +/* 93 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -Jumbotron.propTypes = propTypes$62; -Jumbotron.defaultProps = defaultProps$60; +"use strict"; +Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Alert", function() { return Alert; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Container", function() { return Container; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Row", function() { return Row; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Col", function() { return Col; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Navbar", function() { return Navbar; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarBrand", function() { return NavbarBrand; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavbarToggler", function() { return NavbarToggler; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Nav", function() { return Nav; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavItem", function() { return NavItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavDropdown", function() { return NavDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NavLink", function() { return NavLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Breadcrumb", function() { return Breadcrumb; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BreadcrumbItem", function() { return BreadcrumbItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Button", function() { return Button; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonDropdown", function() { return ButtonDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonGroup", function() { return ButtonGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ButtonToolbar", function() { return ButtonToolbar; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Dropdown", function() { return Dropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownItem", function() { return DropdownItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownMenu", function() { return DropdownMenu; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DropdownToggle", function() { return DropdownToggle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Fade", function() { return Fade; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Badge", function() { return Badge; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Card", function() { return Card; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardLink", function() { return CardLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardGroup", function() { return CardGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardDeck", function() { return CardDeck; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardColumns", function() { return CardColumns; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardBlock", function() { return CardBlock; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardFooter", function() { return CardFooter; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardHeader", function() { return CardHeader; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImg", function() { return CardImg; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardImgOverlay", function() { return CardImgOverlay; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardSubtitle", function() { return CardSubtitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardText", function() { return CardText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "CardTitle", function() { return CardTitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Popover", function() { return Popover; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverContent", function() { return PopoverContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PopoverTitle", function() { return PopoverTitle; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Progress", function() { return Progress; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Modal", function() { return Modal; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalHeader", function() { return ModalHeader; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalBody", function() { return ModalBody; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ModalFooter", function() { return ModalFooter; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TetherContent", function() { return TetherContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Tooltip", function() { return Tooltip; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Table", function() { return Table; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroup", function() { return ListGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Form", function() { return Form; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormFeedback", function() { return FormFeedback; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormGroup", function() { return FormGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FormText", function() { return FormText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Input", function() { return Input; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroup", function() { return InputGroup; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupAddon", function() { return InputGroupAddon; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "InputGroupButton", function() { return InputGroupButton; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Label", function() { return Label; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Media", function() { return Media; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Pagination", function() { return Pagination; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationItem", function() { return PaginationItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PaginationLink", function() { return PaginationLink; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabContent", function() { return TabContent; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TabPane", function() { return TabPane; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Jumbotron", function() { return Jumbotron; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Collapse", function() { return Collapse; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItem", function() { return ListGroupItem; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemText", function() { return ListGroupItemText; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ListGroupItemHeading", function() { return ListGroupItemHeading; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledAlert", function() { return UncontrolledAlert; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledButtonDropdown", function() { return UncontrolledButtonDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledDropdown", function() { return UncontrolledDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledNavDropdown", function() { return UncontrolledNavDropdown; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "UncontrolledTooltip", function() { return UncontrolledTooltip; }); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(6); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(40); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames__ = __webpack_require__(41); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_classnames___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_classnames__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject__ = __webpack_require__(317); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_lodash_isobject__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom__ = __webpack_require__(76); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_react_dom__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__ = __webpack_require__(318); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__ = __webpack_require__(319); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_reactstrap_tether__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__ = __webpack_require__(320); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_lodash_tonumber__); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group__ = __webpack_require__(321); +/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_transition_group___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8_react_transition_group__); -var FirstChild = function FirstChild(_ref) { - var children = _ref.children; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children)[0] || null; -}; -var propTypes$63 = { - children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - closeClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, - transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number -}; -var defaultProps$61 = { - color: 'success', - isOpen: true, - tag: 'div', - transitionAppearTimeout: 150, - transitionEnterTimeout: 150, - transitionLeaveTimeout: 150 -}; -var Alert = function Alert(props) { - var className = props.className, - closeClassName = props.closeClassName, - cssModule = props.cssModule, - Tag = props.tag, - color = props.color, - isOpen = props.isOpen, - toggle = props.toggle, - children = props.children, - transitionAppearTimeout = props.transitionAppearTimeout, - transitionEnterTimeout = props.transitionEnterTimeout, - transitionLeaveTimeout = props.transitionLeaveTimeout, - attributes = objectWithoutProperties(props, ['className', 'closeClassName', 'cssModule', 'tag', 'color', 'isOpen', 'toggle', 'children', 'transitionAppearTimeout', 'transitionEnterTimeout', 'transitionLeaveTimeout']); - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'alert', 'alert-' + color, { 'alert-dismissible': toggle }), cssModule); - var closeClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('close', closeClassName), cssModule); - var alert = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - Tag, - _extends({}, attributes, { className: classes, role: 'alert' }), - toggle ? __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'button', - { type: 'button', className: closeClasses, 'aria-label': 'Close', onClick: toggle }, - __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - 'span', - { 'aria-hidden': 'true' }, - '\xD7' - ) - ) : null, - children - ); - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( - __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["CSSTransitionGroup"], - { - component: FirstChild, - transitionName: { - appear: 'fade', - appearActive: 'show', - enter: 'fade', - enterActive: 'show', - leave: 'fade', - leaveActive: 'out' - }, - transitionAppear: transitionAppearTimeout > 0, - transitionAppearTimeout: transitionAppearTimeout, - transitionEnter: transitionEnterTimeout > 0, - transitionEnterTimeout: transitionEnterTimeout, - transitionLeave: transitionLeaveTimeout > 0, - transitionLeaveTimeout: transitionLeaveTimeout - }, - isOpen ? alert : null - ); -}; -Alert.propTypes = propTypes$63; -Alert.defaultProps = defaultProps$61; +function getTetherAttachments(placement) { + var attachments = {}; + switch (placement) { + case 'top': + case 'top center': + attachments = { + attachment: 'bottom center', + targetAttachment: 'top center' + }; + break; + case 'bottom': + case 'bottom center': + attachments = { + attachment: 'top center', + targetAttachment: 'bottom center' + }; + break; + case 'left': + case 'left center': + attachments = { + attachment: 'middle right', + targetAttachment: 'middle left' + }; + break; + case 'right': + case 'right center': + attachments = { + attachment: 'middle left', + targetAttachment: 'middle right' + }; + break; + case 'top left': + attachments = { + attachment: 'bottom left', + targetAttachment: 'top left' + }; + break; + case 'top right': + attachments = { + attachment: 'bottom right', + targetAttachment: 'top right' + }; + break; + case 'bottom left': + attachments = { + attachment: 'top left', + targetAttachment: 'bottom left' + }; + break; + case 'bottom right': + attachments = { + attachment: 'top right', + targetAttachment: 'bottom right' + }; + break; + case 'right top': + attachments = { + attachment: 'top left', + targetAttachment: 'top right' + }; + break; + case 'right bottom': + attachments = { + attachment: 'bottom left', + targetAttachment: 'bottom right' + }; + break; + case 'left top': + attachments = { + attachment: 'top right', + targetAttachment: 'top left' + }; + break; + case 'left bottom': + attachments = { + attachment: 'bottom right', + targetAttachment: 'bottom left' + }; + break; + default: + attachments = { + attachment: 'top center', + targetAttachment: 'bottom center' + }; + } -var SHOW = 'SHOW'; -var SHOWN = 'SHOWN'; -var HIDE = 'HIDE'; -var HIDDEN = 'HIDDEN'; + return attachments; +} -var propTypes$64 = { - isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, - navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), - onOpened: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, - onClosed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func -}; +var tetherAttachements = ['top', 'bottom', 'left', 'right', 'top left', 'top center', 'top right', 'right top', 'right middle', 'right bottom', 'bottom right', 'bottom center', 'bottom left', 'left top', 'left middle', 'left bottom']; -var DEFAULT_DELAYS$1 = { - show: 350, - hide: 350 -}; +// https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L436-L443 +function getScrollbarWidth() { + var scrollDiv = document.createElement('div'); + // .modal-scrollbar-measure styles // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/scss/_modal.scss#L106-L113 + scrollDiv.style.position = 'absolute'; + scrollDiv.style.top = '-9999px'; + scrollDiv.style.width = '50px'; + scrollDiv.style.height = '50px'; + scrollDiv.style.overflow = 'scroll'; + document.body.appendChild(scrollDiv); + var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth; + document.body.removeChild(scrollDiv); + return scrollbarWidth; +} -var defaultProps$62 = { - isOpen: false, - tag: 'div', - delay: DEFAULT_DELAYS$1, - onOpened: function onOpened() {}, - onClosed: function onClosed() {} -}; +function setScrollbarWidth(padding) { + document.body.style.paddingRight = padding > 0 ? padding + 'px' : null; +} -var Collapse = function (_Component) { - inherits(Collapse, _Component); +function isBodyOverflowing() { + return document.body.clientWidth < window.innerWidth; +} - function Collapse(props) { - classCallCheck(this, Collapse); +function getOriginalBodyPadding() { + return parseInt(window.getComputedStyle(document.body, null).getPropertyValue('padding-right') || 0, 10); +} - var _this = possibleConstructorReturn(this, (Collapse.__proto__ || Object.getPrototypeOf(Collapse)).call(this, props)); +function conditionallyUpdateScrollbar() { + var scrollbarWidth = getScrollbarWidth(); + // https://github.com/twbs/bootstrap/blob/v4.0.0-alpha.4/js/src/modal.js#L420 + var fixedContent = document.querySelectorAll('.navbar-fixed-top, .navbar-fixed-bottom, .is-fixed')[0]; + var bodyPadding = fixedContent ? parseInt(fixedContent.style.paddingRight || 0, 10) : 0; - _this.state = { - collapse: props.isOpen ? SHOWN : HIDDEN, - height: null - }; - _this.element = null; - return _this; + if (isBodyOverflowing()) { + setScrollbarWidth(bodyPadding + scrollbarWidth); } +} - createClass(Collapse, [{ - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - var _this2 = this; +function mapToCssModules(className, cssModule) { + if (!cssModule) return className; + return className.split(' ').map(function (c) { + return cssModule[c] || c; + }).join(' '); +} - var willOpen = nextProps.isOpen; - var collapse = this.state.collapse; +/** + * Returns a new object with the key/value pairs from `obj` that are not in the array `omitKeys`. + */ +function omit(obj, omitKeys) { + var result = {}; + Object.keys(obj).forEach(function (key) { + if (omitKeys.indexOf(key) === -1) { + result[key] = obj[key]; + } + }); + return result; +} - if (willOpen && collapse === HIDDEN) { - // will open - this.setState({ collapse: SHOW }, function () { - // the height transition will work after class "collapsing" applied - _this2.setState({ height: _this2.getHeight() }); - _this2.transitionTag = setTimeout(function () { - _this2.setState({ - collapse: SHOWN, - height: null - }); - }, _this2.getDelay('show')); - }); - } else if (!willOpen && collapse === SHOWN) { - // will hide - this.setState({ height: this.getHeight() }, function () { - _this2.setState({ - collapse: HIDE, - height: _this2.getHeight() - }, function () { - _this2.setState({ height: 0 }); - }); - }); +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { + return typeof obj; +} : function (obj) { + return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; +}; - this.transitionTag = setTimeout(function () { - _this2.setState({ - collapse: HIDDEN, - height: null - }); - }, this.getDelay('hide')); - } - // else: do nothing. - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps, prevState) { - if (this.state.collapse === SHOWN && prevState && prevState.collapse !== SHOWN) { - this.props.onOpened(); - } - if (this.state.collapse === HIDDEN && prevState && prevState.collapse !== HIDDEN) { - this.props.onClosed(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - clearTimeout(this.transitionTag); - } - }, { - key: 'getDelay', - value: function getDelay(key) { - var delay = this.props.delay; - if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { - return isNaN(delay[key]) ? DEFAULT_DELAYS$1[key] : delay[key]; - } - return delay; - } - }, { - key: 'getHeight', - value: function getHeight() { - return this.element.scrollHeight; - } - }, { - key: 'render', - value: function render() { - var _this3 = this; - var _omit = omit(this.props, ['isOpen', 'delay', 'onOpened', 'onClosed']), - navbar = _omit.navbar, - className = _omit.className, - cssModule = _omit.cssModule, - Tag = _omit.tag, - attributes = objectWithoutProperties(_omit, ['navbar', 'className', 'cssModule', 'tag']); - var _state = this.state, - collapse = _state.collapse, - height = _state.height; - var collapseClass = void 0; - switch (collapse) { - case SHOW: - collapseClass = 'collapsing'; - break; - case SHOWN: - collapseClass = 'collapse show'; - break; - case HIDE: - collapseClass = 'collapsing'; - break; - case HIDDEN: - collapseClass = 'collapse'; - break; - default: - // HIDDEN - collapseClass = 'collapse'; - } - var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, collapseClass, navbar && 'navbar-collapse'), cssModule); - var style = height === null ? null : { height: height }; - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { - style: _extends({}, attributes.style, style), - className: classes, - ref: function ref(c) { - _this3.element = c; - } - })); + + + + +var classCallCheck = function (instance, Constructor) { + if (!(instance instanceof Constructor)) { + throw new TypeError("Cannot call a class as a function"); + } +}; + +var createClass = function () { + function defineProperties(target, props) { + for (var i = 0; i < props.length; i++) { + var descriptor = props[i]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); } - }]); - return Collapse; -}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); + } -Collapse.propTypes = propTypes$64; -Collapse.defaultProps = defaultProps$62; + return function (Constructor, protoProps, staticProps) { + if (protoProps) defineProperties(Constructor.prototype, protoProps); + if (staticProps) defineProperties(Constructor, staticProps); + return Constructor; + }; +}(); -var propTypes$65 = { - tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, - action: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any + + + + +var defineProperty = function (obj, key, value) { + if (key in obj) { + Object.defineProperty(obj, key, { + value: value, + enumerable: true, + configurable: true, + writable: true + }); + } else { + obj[key] = value; + } + + return obj; }; -var defaultProps$63 = { - tag: 'li' +var _extends = Object.assign || function (target) { + for (var i = 1; i < arguments.length; i++) { + var source = arguments[i]; + + for (var key in source) { + if (Object.prototype.hasOwnProperty.call(source, key)) { + target[key] = source[key]; + } + } + } + + return target; }; -var handleDisabledOnClick = function handleDisabledOnClick(e) { - e.preventDefault(); + + +var inherits = function (subClass, superClass) { + if (typeof superClass !== "function" && superClass !== null) { + throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); + } + + subClass.prototype = Object.create(superClass && superClass.prototype, { + constructor: { + value: subClass, + enumerable: false, + writable: true, + configurable: true + } + }); + if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }; -var ListGroupItem = function ListGroupItem(props) { - var className = props.className, - Tag = props.tag, - active = props.active, - disabled = props.disabled, - action = props.action, - color = props.color, - attributes = objectWithoutProperties(props, ['className', 'tag', 'active', 'disabled', 'action', 'color']); - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, disabled ? 'disabled' : false, action ? 'list-group-item-action' : false, color ? 'list-group-item-' + color : false, 'list-group-item'); - // Prevent click event when disabled. - if (disabled) { - attributes.onClick = handleDisabledOnClick; + + + + + + +var objectWithoutProperties = function (obj, keys) { + var target = {}; + + for (var i in obj) { + if (keys.indexOf(i) >= 0) continue; + if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; + target[i] = obj[i]; } - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + + return target; }; -ListGroupItem.propTypes = propTypes$65; -ListGroupItem.defaultProps = defaultProps$63; +var possibleConstructorReturn = function (self, call) { + if (!self) { + throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); + } -var propTypes$66 = { + return call && (typeof call === "object" || typeof call === "function") ? call : self; +}; + +var propTypes = { tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any + fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -var defaultProps$64 = { - tag: 'h5' +var defaultProps = { + tag: 'div' }; -var ListGroupItemHeading = function ListGroupItemHeading(props) { +var Container = function Container(props) { var className = props.className, + cssModule = props.cssModule, + fluid = props.fluid, Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'tag']); + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'fluid', 'tag']); - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-heading'); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, fluid ? 'container-fluid' : 'container'), cssModule); return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -ListGroupItemHeading.propTypes = propTypes$66; -ListGroupItemHeading.defaultProps = defaultProps$64; +Container.propTypes = propTypes; +Container.defaultProps = defaultProps; -var propTypes$67 = { +var propTypes$1 = { tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), - className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any + noGutters: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -var defaultProps$65 = { - tag: 'p' +var defaultProps$1 = { + tag: 'div' }; -var ListGroupItemText = function ListGroupItemText(props) { +var Row = function Row(props) { var className = props.className, + cssModule = props.cssModule, + noGutters = props.noGutters, Tag = props.tag, - attributes = objectWithoutProperties(props, ['className', 'tag']); + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'noGutters', 'tag']); - var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-text'); + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, noGutters ? 'no-gutters' : null, 'row'), cssModule); return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -ListGroupItemText.propTypes = propTypes$67; -ListGroupItemText.defaultProps = defaultProps$65; +Row.propTypes = propTypes$1; +Row.defaultProps = defaultProps$1; -var Component$1 = __WEBPACK_IMPORTED_MODULE_0_react___default.a.Component; +var colWidths = ['xs', 'sm', 'md', 'lg', 'xl']; +var stringOrNumberProp = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); -var components = { - UncontrolledAlert: Alert, - UncontrolledButtonDropdown: ButtonDropdown, - UncontrolledDropdown: Dropdown, - UncontrolledNavDropdown: NavDropdown, - UncontrolledTooltip: Tooltip +var columnProps = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + push: stringOrNumberProp, + pull: stringOrNumberProp, + offset: stringOrNumberProp +})]); + +var propTypes$2 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + xs: columnProps, + sm: columnProps, + md: columnProps, + lg: columnProps, + xl: columnProps, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + widths: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.array }; -Object.keys(components).forEach(function (key) { - var Tag = components[key]; - var defaultValue = Tag === Alert; +var defaultProps$2 = { + tag: 'div', + widths: colWidths +}; - var Uncontrolled = function (_Component) { - inherits(Uncontrolled, _Component); +var getColumnSizeClass = function getColumnSizeClass(isXs, colWidth, colSize) { + if (colSize === true || colSize === '') { + return isXs ? 'col' : 'col-' + colWidth; + } else if (colSize === 'auto') { + return isXs ? 'col-auto' : 'col-' + colWidth + '-auto'; + } - function Uncontrolled(props) { - classCallCheck(this, Uncontrolled); + return isXs ? 'col-' + colSize : 'col-' + colWidth + '-' + colSize; +}; - var _this = possibleConstructorReturn(this, (Uncontrolled.__proto__ || Object.getPrototypeOf(Uncontrolled)).call(this, props)); +var Col = function Col(props) { + var className = props.className, + cssModule = props.cssModule, + widths = props.widths, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'widths', 'tag']); - _this.state = { isOpen: defaultValue }; + var colClasses = []; - _this.toggle = _this.toggle.bind(_this); - return _this; + widths.forEach(function (colWidth, i) { + var columnProp = props[colWidth]; + + if (!i && columnProp === undefined) { + columnProp = true; } - createClass(Uncontrolled, [{ - key: 'toggle', - value: function toggle() { - this.setState({ isOpen: !this.state.isOpen }); - } - }, { - key: 'render', - value: function render() { - return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ isOpen: this.state.isOpen, toggle: this.toggle }, this.props)); - } - }]); - return Uncontrolled; - }(Component$1); + delete attributes[colWidth]; - Uncontrolled.displayName = key; + if (!columnProp) { + return; + } - components[key] = Uncontrolled; -}); + var isXs = !i; + var colClass = void 0; -var UncontrolledAlert = components.UncontrolledAlert; -var UncontrolledButtonDropdown = components.UncontrolledButtonDropdown; -var UncontrolledDropdown = components.UncontrolledDropdown; -var UncontrolledNavDropdown = components.UncontrolledNavDropdown; -var UncontrolledTooltip = components.UncontrolledTooltip; + if (__WEBPACK_IMPORTED_MODULE_3_lodash_isobject___default()(columnProp)) { + var _classNames; + var colSizeInterfix = isXs ? '-' : '-' + colWidth + '-'; + colClass = getColumnSizeClass(isXs, colWidth, columnProp.size); -//# sourceMappingURL=reactstrap.es.js.map + colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, colClass, columnProp.size || columnProp.size === ''), defineProperty(_classNames, 'push' + colSizeInterfix + columnProp.push, columnProp.push || columnProp.push === 0), defineProperty(_classNames, 'pull' + colSizeInterfix + columnProp.pull, columnProp.pull || columnProp.pull === 0), defineProperty(_classNames, 'offset' + colSizeInterfix + columnProp.offset, columnProp.offset || columnProp.offset === 0), _classNames))), cssModule); + } else { + colClass = getColumnSizeClass(isXs, colWidth, columnProp); + colClasses.push(colClass); + } + }); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, colClasses), cssModule); -/***/ }), -/* 67 */ -/***/ (function(module, exports) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var g; - -// This works in non-strict mode -g = (function() { - return this; -})(); - -try { - // This works if eval is allowed (see CSP) - g = g || Function("return this")() || (1,eval)("this"); -} catch(e) { - // This works if the window reference is available - if(typeof window === "object") - g = window; -} - -// g can still be undefined, but nothing to do about it... -// We return undefined, instead of nothing here, so it's -// easier to handle this case. if(!global) { ...} - -module.exports = g; +Col.propTypes = propTypes$2; +Col.defaultProps = defaultProps$2; +var propTypes$3 = { + light: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + full: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + fixed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + sticky: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggleable: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; -/***/ }), -/* 68 */ -/***/ (function(module, exports, __webpack_require__) { +var defaultProps$3 = { + tag: 'nav', + toggleable: false +}; -"use strict"; +var getToggleableClass = function getToggleableClass(toggleable) { + if (toggleable === false) { + return false; + } else if (toggleable === true || toggleable === 'xs') { + return 'navbar-toggleable'; + } + return 'navbar-toggleable-' + toggleable; +}; -Object.defineProperty(exports, "__esModule", { - value: true -}); +var Navbar = function Navbar(props) { + var _classNames; -var _react = __webpack_require__(4); + var toggleable = props.toggleable, + className = props.className, + cssModule = props.cssModule, + light = props.light, + inverse = props.inverse, + full = props.full, + fixed = props.fixed, + sticky = props.sticky, + color = props.color, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['toggleable', 'className', 'cssModule', 'light', 'inverse', 'full', 'fixed', 'sticky', 'color', 'tag']); -var _react2 = _interopRequireDefault(_react); -var _Const = __webpack_require__(22); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar', getToggleableClass(toggleable), (_classNames = { + 'navbar-light': light, + 'navbar-inverse': inverse + }, defineProperty(_classNames, 'bg-' + color, color), defineProperty(_classNames, 'navbar-full', full), defineProperty(_classNames, 'fixed-' + fixed, fixed), defineProperty(_classNames, 'sticky-' + sticky, sticky), _classNames)), cssModule); -var _Const2 = _interopRequireDefault(_Const); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var _classnames = __webpack_require__(29); +Navbar.propTypes = propTypes$3; +Navbar.defaultProps = defaultProps$3; -var _classnames2 = _interopRequireDefault(_classnames); +var propTypes$4 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var defaultProps$4 = { + tag: 'a' +}; -var _default = { - renderReactSortCaret: function renderReactSortCaret(order, isBootstrap4) { - var orderClass = void 0; - if (isBootstrap4) { - orderClass = (0, _classnames2.default)('fa', { - 'fa-sort-asc': order === _Const2.default.SORT_ASC, - 'fa-sort-desc': order === _Const2.default.SORT_DESC - }); - return _react2.default.createElement('span', { className: orderClass, style: { margin: '10px 5px' } }); - } else { - orderClass = (0, _classnames2.default)('order', { - 'dropup': order === _Const2.default.SORT_ASC - }); - return _react2.default.createElement( - 'span', - { className: orderClass }, - _react2.default.createElement('span', { className: 'caret', style: { margin: '10px 5px' } }) - ); - } - }, - isFunction: function isFunction(obj) { - return obj && typeof obj === 'function'; - }, - getScrollBarWidth: function getScrollBarWidth() { - var inner = document.createElement('p'); - inner.style.width = '100%'; - inner.style.height = '200px'; - - var outer = document.createElement('div'); - outer.style.position = 'absolute'; - outer.style.top = '0px'; - outer.style.left = '0px'; - outer.style.visibility = 'hidden'; - outer.style.width = '200px'; - outer.style.height = '150px'; - outer.style.overflow = 'hidden'; - outer.appendChild(inner); - - document.body.appendChild(outer); - var w1 = inner.getBoundingClientRect().width; - outer.style.overflow = 'scroll'; - var w2 = inner.getBoundingClientRect().width; - - if (w1 === w2) w2 = outer.clientWidth; - - document.body.removeChild(outer); - - return w1 - w2; - }, - canUseDOM: function canUseDOM() { - return typeof window !== 'undefined' && typeof window.document !== 'undefined'; - }, +var NavbarBrand = function NavbarBrand(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - // We calculate an offset here in order to properly fetch the indexed data, - // despite the page start index not always being 1 - getNormalizedPage: function getNormalizedPage(pageStartIndex, page) { - pageStartIndex = this.getFirstPage(pageStartIndex); - if (page === undefined) page = pageStartIndex; - var offset = Math.abs(_Const2.default.PAGE_START_INDEX - pageStartIndex); - return page + offset; - }, - getFirstPage: function getFirstPage(pageStartIndex) { - return pageStartIndex !== undefined ? pageStartIndex : _Const2.default.PAGE_START_INDEX; - }, - isBootstrap4: function isBootstrap4(version) { - return version === '4'; - }, - renderColGroup: function renderColGroup(columns, selectRow) { - var expandColumnOptions = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {}; - var version = arguments[3]; - - var selectRowHeader = null; - var expandRowHeader = null; - var isBootstrap4 = this.isBootstrap4(version); - var isSelectRowDefined = selectRow.mode === _Const2.default.ROW_SELECT_SINGLE || selectRow.mode === _Const2.default.ROW_SELECT_MULTI; - var columnWidth = isBootstrap4 ? '38px' : '30px'; - if (isSelectRowDefined) { - var style = { - width: selectRow.columnWidth || columnWidth, - minWidth: selectRow.columnWidth || columnWidth - }; - if (!selectRow.hideSelectColumn) { - selectRowHeader = _react2.default.createElement('col', { key: 'select-col', style: style }); - } - } - if (expandColumnOptions.expandColumnVisible) { - var _style = { - width: expandColumnOptions.columnWidth || columnWidth, - minWidth: expandColumnOptions.columnWidth || columnWidth - }; - expandRowHeader = _react2.default.createElement('col', { key: 'expand-col', style: _style }); - } - var theader = columns.map(function (column, i) { - var style = { - display: column.hidden ? 'none' : null - }; - if (column.width) { - var width = !isNaN(column.width) ? column.width + 'px' : column.width; - style.width = width; - /** add min-wdth to fix user assign column width - not eq offsetWidth in large column table **/ - style.minWidth = width; - } - return _react2.default.createElement('col', { style: style, key: i, className: column.className }); - }); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-brand'), cssModule); - return _react2.default.createElement( - 'colgroup', - null, - expandColumnOptions.expandColumnVisible && expandColumnOptions.expandColumnBeforeSelectColumn && expandRowHeader, - selectRowHeader, - expandColumnOptions.expandColumnVisible && !expandColumnOptions.expandColumnBeforeSelectColumn && expandRowHeader, - theader - ); - } -}; /* eslint react/display-name: 0 */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -exports.default = _default; -; +NavbarBrand.propTypes = propTypes$4; +NavbarBrand.defaultProps = defaultProps$4; -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } +var propTypes$5 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/util.js'); -}(); +var defaultProps$5 = { + tag: 'button', + type: 'button' +}; -; +var navbarToggleIcon = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('span', { className: 'navbar-toggler-icon' }); -/***/ }), -/* 69 */ -/***/ (function(module, exports, __webpack_require__) { +var NavbarToggler = function NavbarToggler(props) { + var className = props.className, + cssModule = props.cssModule, + children = props.children, + right = props.right, + left = props.left, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'right', 'left', 'tag']); -"use strict"; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'navbar-toggler', right && 'navbar-toggler-right', left && 'navbar-toggler-left'), cssModule); -var assert = __webpack_require__(47); -var inherits = __webpack_require__(11); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { className: classes }), + children || navbarToggleIcon + ); +}; -exports.inherits = inherits; +NavbarToggler.propTypes = propTypes$5; +NavbarToggler.defaultProps = defaultProps$5; -function toArray(msg, enc) { - if (Array.isArray(msg)) - return msg.slice(); - if (!msg) - return []; - var res = []; - if (typeof msg === 'string') { - if (!enc) { - for (var i = 0; i < msg.length; i++) { - var c = msg.charCodeAt(i); - var hi = c >> 8; - var lo = c & 0xff; - if (hi) - res.push(hi, lo); - else - res.push(lo); - } - } else if (enc === 'hex') { - msg = msg.replace(/[^a-z0-9]+/ig, ''); - if (msg.length % 2 !== 0) - msg = '0' + msg; - for (i = 0; i < msg.length; i += 2) - res.push(parseInt(msg[i] + msg[i + 1], 16)); - } - } else { - for (i = 0; i < msg.length; i++) - res[i] = msg[i] | 0; - } - return res; -} -exports.toArray = toArray; +var propTypes$6 = { + tabs: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + pills: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -function toHex(msg) { - var res = ''; - for (var i = 0; i < msg.length; i++) - res += zero2(msg[i].toString(16)); - return res; -} -exports.toHex = toHex; +var defaultProps$6 = { + tag: 'ul' +}; -function htonl(w) { - var res = (w >>> 24) | - ((w >>> 8) & 0xff00) | - ((w << 8) & 0xff0000) | - ((w & 0xff) << 24); - return res >>> 0; -} -exports.htonl = htonl; +var Nav = function Nav(props) { + var className = props.className, + cssModule = props.cssModule, + tabs = props.tabs, + pills = props.pills, + vertical = props.vertical, + navbar = props.navbar, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabs', 'pills', 'vertical', 'navbar', 'tag']); -function toHex32(msg, endian) { - var res = ''; - for (var i = 0; i < msg.length; i++) { - var w = msg[i]; - if (endian === 'little') - w = htonl(w); - res += zero8(w.toString(16)); - } - return res; -} -exports.toHex32 = toHex32; -function zero2(word) { - if (word.length === 1) - return '0' + word; - else - return word; -} -exports.zero2 = zero2; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, navbar ? 'navbar-nav' : 'nav', { + 'nav-tabs': tabs, + 'nav-pills': pills, + 'flex-column': vertical + }), cssModule); -function zero8(word) { - if (word.length === 7) - return '0' + word; - else if (word.length === 6) - return '00' + word; - else if (word.length === 5) - return '000' + word; - else if (word.length === 4) - return '0000' + word; - else if (word.length === 3) - return '00000' + word; - else if (word.length === 2) - return '000000' + word; - else if (word.length === 1) - return '0000000' + word; - else - return word; -} -exports.zero8 = zero8; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -function join32(msg, start, end, endian) { - var len = end - start; - assert(len % 4 === 0); - var res = new Array(len / 4); - for (var i = 0, k = start; i < res.length; i++, k += 4) { - var w; - if (endian === 'big') - w = (msg[k] << 24) | (msg[k + 1] << 16) | (msg[k + 2] << 8) | msg[k + 3]; - else - w = (msg[k + 3] << 24) | (msg[k + 2] << 16) | (msg[k + 1] << 8) | msg[k]; - res[i] = w >>> 0; - } - return res; -} -exports.join32 = join32; +Nav.propTypes = propTypes$6; +Nav.defaultProps = defaultProps$6; -function split32(msg, endian) { - var res = new Array(msg.length * 4); - for (var i = 0, k = 0; i < msg.length; i++, k += 4) { - var m = msg[i]; - if (endian === 'big') { - res[k] = m >>> 24; - res[k + 1] = (m >>> 16) & 0xff; - res[k + 2] = (m >>> 8) & 0xff; - res[k + 3] = m & 0xff; - } else { - res[k + 3] = m >>> 24; - res[k + 2] = (m >>> 16) & 0xff; - res[k + 1] = (m >>> 8) & 0xff; - res[k] = m & 0xff; - } - } - return res; -} -exports.split32 = split32; +var propTypes$7 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -function rotr32(w, b) { - return (w >>> b) | (w << (32 - b)); -} -exports.rotr32 = rotr32; +var defaultProps$7 = { + tag: 'li' +}; -function rotl32(w, b) { - return (w << b) | (w >>> (32 - b)); -} -exports.rotl32 = rotl32; +var NavItem = function NavItem(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -function sum32(a, b) { - return (a + b) >>> 0; -} -exports.sum32 = sum32; -function sum32_3(a, b, c) { - return (a + b + c) >>> 0; -} -exports.sum32_3 = sum32_3; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); -function sum32_4(a, b, c, d) { - return (a + b + c + d) >>> 0; -} -exports.sum32_4 = sum32_4; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -function sum32_5(a, b, c, d, e) { - return (a + b + c + d + e) >>> 0; -} -exports.sum32_5 = sum32_5; +NavItem.propTypes = propTypes$7; +NavItem.defaultProps = defaultProps$7; -function sum64(buf, pos, ah, al) { - var bh = buf[pos]; - var bl = buf[pos + 1]; +var propTypes$10 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + arrow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object.isRequired, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + style: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - var lo = (al + bl) >>> 0; - var hi = (lo < al ? 1 : 0) + ah + bh; - buf[pos] = hi >>> 0; - buf[pos + 1] = lo; -} -exports.sum64 = sum64; +var defaultProps$10 = { + isOpen: false, + tetherRef: function tetherRef() {} +}; -function sum64_hi(ah, al, bh, bl) { - var lo = (al + bl) >>> 0; - var hi = (lo < al ? 1 : 0) + ah + bh; - return hi >>> 0; -} -exports.sum64_hi = sum64_hi; +var TetherContent = function (_React$Component) { + inherits(TetherContent, _React$Component); -function sum64_lo(ah, al, bh, bl) { - var lo = al + bl; - return lo >>> 0; -} -exports.sum64_lo = sum64_lo; + function TetherContent(props) { + classCallCheck(this, TetherContent); -function sum64_4_hi(ah, al, bh, bl, ch, cl, dh, dl) { - var carry = 0; - var lo = al; - lo = (lo + bl) >>> 0; - carry += lo < al ? 1 : 0; - lo = (lo + cl) >>> 0; - carry += lo < cl ? 1 : 0; - lo = (lo + dl) >>> 0; - carry += lo < dl ? 1 : 0; + var _this = possibleConstructorReturn(this, (TetherContent.__proto__ || Object.getPrototypeOf(TetherContent)).call(this, props)); - var hi = ah + bh + ch + dh + carry; - return hi >>> 0; -} -exports.sum64_4_hi = sum64_4_hi; + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.toggle = _this.toggle.bind(_this); + return _this; + } -function sum64_4_lo(ah, al, bh, bl, ch, cl, dh, dl) { - var lo = al + bl + cl + dl; - return lo >>> 0; -} -exports.sum64_4_lo = sum64_4_lo; + createClass(TetherContent, [{ + key: 'componentDidMount', + value: function componentDidMount() { + this.handleProps(); + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + this.handleProps(); + } else if (this._element) { + // rerender + this.renderIntoSubtree(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.hide(); + } + }, { + key: 'getTarget', + value: function getTarget() { + var target = this.props.tether.target; -function sum64_5_hi(ah, al, bh, bl, ch, cl, dh, dl, eh, el) { - var carry = 0; - var lo = al; - lo = (lo + bl) >>> 0; - carry += lo < al ? 1 : 0; - lo = (lo + cl) >>> 0; - carry += lo < cl ? 1 : 0; - lo = (lo + dl) >>> 0; - carry += lo < dl ? 1 : 0; - lo = (lo + el) >>> 0; - carry += lo < el ? 1 : 0; + if (__WEBPACK_IMPORTED_MODULE_5_lodash_isfunction___default()(target)) { + return target(); + } - var hi = ah + bh + ch + dh + eh + carry; - return hi >>> 0; -} -exports.sum64_5_hi = sum64_5_hi; + return target; + } + }, { + key: 'getTetherConfig', + value: function getTetherConfig() { + var config = _extends({}, this.props.tether); -function sum64_5_lo(ah, al, bh, bl, ch, cl, dh, dl, eh, el) { - var lo = al + bl + cl + dl + el; + config.element = this._element; + config.target = this.getTarget(); + return config; + } + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + var container = this._element; + if (e.target === container || !container.contains(e.target)) { + this.toggle(); + } + } + }, { + key: 'handleProps', + value: function handleProps() { + if (this.props.isOpen) { + this.show(); + } else { + this.hide(); + } + } + }, { + key: 'hide', + value: function hide() { + document.removeEventListener('click', this.handleDocumentClick, true); - return lo >>> 0; -} -exports.sum64_5_lo = sum64_5_lo; + if (this._element) { + document.body.removeChild(this._element); + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); + this._element = null; + } -function rotr64_hi(ah, al, num) { - var r = (al << (32 - num)) | (ah >>> num); - return r >>> 0; -} -exports.rotr64_hi = rotr64_hi; + if (this._tether) { + this._tether.destroy(); + this._tether = null; + this.props.tetherRef(this._tether); + } + } + }, { + key: 'show', + value: function show() { + document.addEventListener('click', this.handleDocumentClick, true); -function rotr64_lo(ah, al, num) { - var r = (ah << (32 - num)) | (al >>> num); - return r >>> 0; -} -exports.rotr64_lo = rotr64_lo; + this._element = document.createElement('div'); + this._element.className = this.props.className; + document.body.appendChild(this._element); + this.renderIntoSubtree(); + this._tether = new __WEBPACK_IMPORTED_MODULE_6_reactstrap_tether___default.a(this.getTetherConfig()); + this.props.tetherRef(this._tether); + this._tether.position(); + this._element.childNodes[0].focus(); + } + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } -function shr64_hi(ah, al, num) { - return ah >>> num; -} -exports.shr64_hi = shr64_hi; + return this.props.toggle(); + } + }, { + key: 'renderIntoSubtree', + value: function renderIntoSubtree() { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _props = this.props, + children = _props.children, + style = _props.style; -function shr64_lo(ah, al, num) { - var r = (ah << (32 - num)) | (al >>> num); - return r >>> 0; -} -exports.shr64_lo = shr64_lo; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(children, { style: style }); + } + }, { + key: 'render', + value: function render() { + return null; + } + }]); + return TetherContent; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +TetherContent.propTypes = propTypes$10; +TetherContent.defaultProps = defaultProps$10; -/***/ }), -/* 70 */ -/***/ (function(module, exports, __webpack_require__) { +var propTypes$11 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node.isRequired, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -"use strict"; +var defaultProps$11 = { + tag: 'div' +}; +var contextTypes = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired +}; -Object.defineProperty(exports, "__esModule", { - value: true -}); +var DropdownMenu = function DropdownMenu(props, context) { + var className = props.className, + cssModule = props.cssModule, + right = props.right, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'right', 'tag']); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'dropdown-menu', { 'dropdown-menu-right': right }), cssModule); -var _react = __webpack_require__(4); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { tabIndex: '-1', 'aria-hidden': !context.isOpen, role: 'menu', className: classes })); +}; -var _react2 = _interopRequireDefault(_react); +DropdownMenu.propTypes = propTypes$11; +DropdownMenu.defaultProps = defaultProps$11; +DropdownMenu.contextTypes = contextTypes; -var _propTypes = __webpack_require__(9); +/* eslint react/no-find-dom-node: 0 */ +// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-find-dom-node.md -var _propTypes2 = _interopRequireDefault(_propTypes); +var propTypes$9 = { + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + dropup: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + group: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool]), + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var defaultProps$9 = { + isOpen: false, + tag: 'div' +}; -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } - -var IconBase = function IconBase(_ref, _ref2) { - var children = _ref.children; - var color = _ref.color; - var size = _ref.size; - var style = _ref.style; - - var props = _objectWithoutProperties(_ref, ['children', 'color', 'size', 'style']); - - var _ref2$reactIconBase = _ref2.reactIconBase; - var reactIconBase = _ref2$reactIconBase === undefined ? {} : _ref2$reactIconBase; - - var computedSize = size || reactIconBase.size || '1em'; - return _react2.default.createElement('svg', _extends({ - children: children, - fill: 'currentColor', - preserveAspectRatio: 'xMidYMid meet', - height: computedSize, - width: computedSize - }, reactIconBase, props, { - style: _extends({ - verticalAlign: 'middle', - color: color || reactIconBase.color - }, reactIconBase.style || {}, style) - })); +var childContextTypes = { + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired }; -IconBase.propTypes = { - color: _propTypes2.default.string, - size: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.number]), - style: _propTypes2.default.object +var defaultTetherConfig = { + classPrefix: 'bs-tether', + classes: { element: 'dropdown', enabled: 'show' }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] }; -IconBase.contextTypes = { - reactIconBase: _propTypes2.default.shape(IconBase.propTypes) -}; +var Dropdown = function (_React$Component) { + inherits(Dropdown, _React$Component); -exports.default = IconBase; -module.exports = exports['default']; + function Dropdown(props) { + classCallCheck(this, Dropdown); -/***/ }), -/* 71 */ -/***/ (function(module, exports, __webpack_require__) { + var _this = possibleConstructorReturn(this, (Dropdown.__proto__ || Object.getPrototypeOf(Dropdown)).call(this, props)); -"use strict"; -/* WEBPACK VAR INJECTION */(function(Buffer) { -var inherits = __webpack_require__(11) -var md5 = __webpack_require__(245) -var RIPEMD160 = __webpack_require__(260) -var sha = __webpack_require__(265) + _this.addEvents = _this.addEvents.bind(_this); + _this.getTetherConfig = _this.getTetherConfig.bind(_this); + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.removeEvents = _this.removeEvents.bind(_this); + _this.toggle = _this.toggle.bind(_this); + return _this; + } -var Base = __webpack_require__(109) + createClass(Dropdown, [{ + key: 'getChildContext', + value: function getChildContext() { + return { + toggle: this.props.toggle, + isOpen: this.props.isOpen + }; + } + }, { + key: 'componentDidMount', + value: function componentDidMount() { + this.handleProps(); + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + this.handleProps(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.removeEvents(); + } + }, { + key: 'getTetherTarget', + value: function getTetherTarget() { + var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); -function HashNoConstructor (hash) { - Base.call(this, 'digest') + return container.querySelector('[data-toggle="dropdown"]'); + } + }, { + key: 'getTetherConfig', + value: function getTetherConfig(childProps) { + var _this2 = this; - this._hash = hash - this.buffers = [] -} + var target = function target() { + return _this2.getTetherTarget(); + }; + var vElementAttach = 'top'; + var hElementAttach = 'left'; + var vTargetAttach = 'bottom'; + var hTargetAttach = 'left'; -inherits(HashNoConstructor, Base) + if (childProps.right) { + hElementAttach = 'right'; + hTargetAttach = 'right'; + } -HashNoConstructor.prototype._update = function (data) { - this.buffers.push(data) -} + if (this.props.dropup) { + vElementAttach = 'bottom'; + vTargetAttach = 'top'; + } -HashNoConstructor.prototype._final = function () { - var buf = Buffer.concat(this.buffers) - var r = this._hash(buf) - this.buffers = null + return _extends({}, defaultTetherConfig, { + attachment: vElementAttach + ' ' + hElementAttach, + targetAttachment: vTargetAttach + ' ' + hTargetAttach, + target: target + }, this.props.tether); + } + }, { + key: 'addEvents', + value: function addEvents() { + document.addEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'removeEvents', + value: function removeEvents() { + document.removeEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + var container = __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.findDOMNode(this); - return r -} + if (container.contains(e.target) && container !== e.target) { + return; + } -function Hash (hash) { - Base.call(this, 'digest') + this.toggle(); + } + }, { + key: 'handleProps', + value: function handleProps() { + if (this.props.tether) { + return; + } - this._hash = hash -} + if (this.props.isOpen) { + this.addEvents(); + } else { + this.removeEvents(); + } + } + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } -inherits(Hash, Base) + return this.props.toggle(); + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _this3 = this; -Hash.prototype._update = function (data) { - this._hash.update(data) -} + var _props = this.props, + tether = _props.tether, + children = _props.children, + attrs = objectWithoutProperties(_props, ['tether', 'children']); -Hash.prototype._final = function () { - return this._hash.digest() -} + attrs.toggle = this.toggle; -module.exports = function createHash (alg) { - alg = alg.toLowerCase() - if (alg === 'md5') return new HashNoConstructor(md5) - if (alg === 'rmd160' || alg === 'ripemd160') return new Hash(new RIPEMD160()) + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.map(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children), function (child) { + if (tether && child.type === DropdownMenu) { + var tetherConfig = _this3.getTetherConfig(child.props); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + _extends({}, attrs, { tether: tetherConfig }), + child + ); + } - return new Hash(sha(alg)) -} + return child; + }); + } + }, { + key: 'render', + value: function render() { + var _classNames; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + var _omit = omit(this.props, ['toggle', 'tether']), + className = _omit.className, + cssModule = _omit.cssModule, + dropup = _omit.dropup, + group = _omit.group, + size = _omit.size, + Tag = _omit.tag, + isOpen = _omit.isOpen, + attributes = objectWithoutProperties(_omit, ['className', 'cssModule', 'dropup', 'group', 'size', 'tag', 'isOpen']); -/***/ }), -/* 72 */ -/***/ (function(module, exports) { + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, (_classNames = { + 'btn-group': group + }, defineProperty(_classNames, 'btn-group-' + size, !!size), defineProperty(_classNames, 'dropdown', !group), defineProperty(_classNames, 'show', isOpen), defineProperty(_classNames, 'dropup', dropup), _classNames)), cssModule); -/* - MIT License http://www.opensource.org/licenses/mit-license.php - Author Tobias Koppers @sokra -*/ -// css base code, injected by the css-loader -module.exports = function(useSourceMap) { - var list = []; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { + className: classes + }), + this.renderChildren() + ); + } + }]); + return Dropdown; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - // return the list of modules as css string - list.toString = function toString() { - return this.map(function (item) { - var content = cssWithMappingToString(item, useSourceMap); - if(item[2]) { - return "@media " + item[2] + "{" + content + "}"; - } else { - return content; - } - }).join(""); - }; +Dropdown.propTypes = propTypes$9; +Dropdown.defaultProps = defaultProps$9; +Dropdown.childContextTypes = childContextTypes; - // import a list of modules into the list - list.i = function(modules, mediaQuery) { - if(typeof modules === "string") - modules = [[null, modules, ""]]; - var alreadyImportedModules = {}; - for(var i = 0; i < this.length; i++) { - var id = this[i][0]; - if(typeof id === "number") - alreadyImportedModules[id] = true; - } - for(i = 0; i < modules.length; i++) { - var item = modules[i]; - // skip already imported module - // this implementation is not 100% perfect for weird media query combinations - // when a module is imported multiple times with different media queries. - // I hope this will never occur (Hey this way we have smaller bundles) - if(typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) { - if(mediaQuery && !item[2]) { - item[2] = mediaQuery; - } else if(mediaQuery) { - item[2] = "(" + item[2] + ") and (" + mediaQuery + ")"; - } - list.push(item); - } - } - }; - return list; +var propTypes$8 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -function cssWithMappingToString(item, useSourceMap) { - var content = item[1] || ''; - var cssMapping = item[3]; - if (!cssMapping) { - return content; - } - - if (useSourceMap && typeof btoa === 'function') { - var sourceMapping = toComment(cssMapping); - var sourceURLs = cssMapping.sources.map(function (source) { - return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */' - }); +var defaultProps$8 = { + tag: 'li' +}; - return [content].concat(sourceURLs).concat([sourceMapping]).join('\n'); - } +var NavDropdown = function NavDropdown(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - return [content].join('\n'); -} -// Adapted from convert-source-map (MIT) -function toComment(sourceMap) { - // eslint-disable-next-line no-undef - var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))); - var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-item'), cssModule); - return '/*# ' + data + ' */'; -} + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({}, attributes, { tag: Tag, className: classes })); +}; +NavDropdown.propTypes = propTypes$8; +NavDropdown.defaultProps = defaultProps$8; -/***/ }), -/* 73 */ -/***/ (function(module, exports, __webpack_require__) { +var propTypes$12 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + href: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -/* - MIT License http://www.opensource.org/licenses/mit-license.php - Author Tobias Koppers @sokra -*/ +var defaultProps$12 = { + tag: 'a' +}; -var stylesInDom = {}; +var NavLink = function (_React$Component) { + inherits(NavLink, _React$Component); -var memoize = function (fn) { - var memo; + function NavLink(props) { + classCallCheck(this, NavLink); - return function () { - if (typeof memo === "undefined") memo = fn.apply(this, arguments); - return memo; - }; -}; + var _this = possibleConstructorReturn(this, (NavLink.__proto__ || Object.getPrototypeOf(NavLink)).call(this, props)); -var isOldIE = memoize(function () { - // Test for IE <= 9 as proposed by Browserhacks - // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805 - // Tests for existence of standard globals is to allow style-loader - // to operate correctly into non-standard environments - // @see https://github.com/webpack-contrib/style-loader/issues/177 - return window && document && document.all && !window.atob; -}); + _this.onClick = _this.onClick.bind(_this); + return _this; + } -var getElement = (function (fn) { - var memo = {}; + createClass(NavLink, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } - return function(selector) { - if (typeof memo[selector] === "undefined") { - memo[selector] = fn.call(this, selector); - } + if (this.props.href === '#') { + e.preventDefault(); + } - return memo[selector] - }; -})(function (target) { - return document.querySelector(target) -}); + if (this.props.onClick) { + this.props.onClick(e); + } + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + active = _props.active, + Tag = _props.tag, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'active', 'tag', 'getRef']); -var singleton = null; -var singletonCounter = 0; -var stylesInsertedAtTop = []; -var fixUrls = __webpack_require__(119); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'nav-link', { + disabled: attributes.disabled, + active: active + }), cssModule); -module.exports = function(list, options) { - if (typeof DEBUG !== "undefined" && DEBUG) { - if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment"); - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, onClick: this.onClick, className: classes })); + } + }]); + return NavLink; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - options = options || {}; +NavLink.propTypes = propTypes$12; +NavLink.defaultProps = defaultProps$12; - options.attrs = typeof options.attrs === "object" ? options.attrs : {}; +var propTypes$13 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - // Force single-tag solution on IE6-9, which has a hard limit on the # of <style> - // tags it will allow on a page - if (!options.singleton) options.singleton = isOldIE(); +var defaultProps$13 = { + tag: 'ol' +}; - // By default, add <style> tags to the <head> element - if (!options.insertInto) options.insertInto = "head"; +var Breadcrumb = function Breadcrumb(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - // By default, add <style> tags to the bottom of the target - if (!options.insertAt) options.insertAt = "bottom"; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'breadcrumb'), cssModule); - var styles = listToStyles(list, options); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - addStylesToDom(styles, options); +Breadcrumb.propTypes = propTypes$13; +Breadcrumb.defaultProps = defaultProps$13; - return function update (newList) { - var mayRemove = []; +var propTypes$14 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - for (var i = 0; i < styles.length; i++) { - var item = styles[i]; - var domStyle = stylesInDom[item.id]; +var defaultProps$14 = { + tag: 'li' +}; - domStyle.refs--; - mayRemove.push(domStyle); - } +var BreadcrumbItem = function BreadcrumbItem(props) { + var className = props.className, + cssModule = props.cssModule, + active = props.active, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'active', 'tag']); - if(newList) { - var newStyles = listToStyles(newList, options); - addStylesToDom(newStyles, options); - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, 'breadcrumb-item'), cssModule); - for (var i = 0; i < mayRemove.length; i++) { - var domStyle = mayRemove[i]; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if(domStyle.refs === 0) { - for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](); +BreadcrumbItem.propTypes = propTypes$14; +BreadcrumbItem.defaultProps = defaultProps$14; - delete stylesInDom[domStyle.id]; - } - } - }; +var propTypes$15 = { + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -function addStylesToDom (styles, options) { - for (var i = 0; i < styles.length; i++) { - var item = styles[i]; - var domStyle = stylesInDom[item.id]; +var defaultProps$15 = { + color: 'secondary', + tag: 'button' +}; - if(domStyle) { - domStyle.refs++; - - for(var j = 0; j < domStyle.parts.length; j++) { - domStyle.parts[j](item.parts[j]); - } - - for(; j < item.parts.length; j++) { - domStyle.parts.push(addStyle(item.parts[j], options)); - } - } else { - var parts = []; +var Button = function (_React$Component) { + inherits(Button, _React$Component); - for(var j = 0; j < item.parts.length; j++) { - parts.push(addStyle(item.parts[j], options)); - } + function Button(props) { + classCallCheck(this, Button); - stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts}; - } - } -} + var _this = possibleConstructorReturn(this, (Button.__proto__ || Object.getPrototypeOf(Button)).call(this, props)); -function listToStyles (list, options) { - var styles = []; - var newStyles = {}; + _this.onClick = _this.onClick.bind(_this); + return _this; + } - for (var i = 0; i < list.length; i++) { - var item = list[i]; - var id = options.base ? item[0] + options.base : item[0]; - var css = item[1]; - var media = item[2]; - var sourceMap = item[3]; - var part = {css: css, media: media, sourceMap: sourceMap}; + createClass(Button, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } - if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]}); - else newStyles[id].parts.push(part); - } + if (this.props.onClick) { + this.props.onClick(e); + } + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + active = _props.active, + block = _props.block, + className = _props.className, + cssModule = _props.cssModule, + color = _props.color, + outline = _props.outline, + size = _props.size, + Tag = _props.tag, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['active', 'block', 'className', 'cssModule', 'color', 'outline', 'size', 'tag', 'getRef']); - return styles; -} -function insertStyleElement (options, style) { - var target = getElement(options.insertInto) + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn', 'btn' + (outline ? '-outline' : '') + '-' + color, size ? 'btn-' + size : false, block ? 'btn-block' : false, { active: active, disabled: this.props.disabled }), cssModule); - if (!target) { - throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid."); - } + if (attributes.href && Tag === 'button') { + Tag = 'a'; + } - var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1]; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ + type: Tag === 'button' && attributes.onClick ? 'button' : undefined + }, attributes, { + className: classes, + ref: getRef, + onClick: this.onClick + })); + } + }]); + return Button; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - if (options.insertAt === "top") { - if (!lastStyleElementInsertedAtTop) { - target.insertBefore(style, target.firstChild); - } else if (lastStyleElementInsertedAtTop.nextSibling) { - target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling); - } else { - target.appendChild(style); - } - stylesInsertedAtTop.push(style); - } else if (options.insertAt === "bottom") { - target.appendChild(style); - } else { - throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'."); - } -} +Button.propTypes = propTypes$15; +Button.defaultProps = defaultProps$15; -function removeStyleElement (style) { - if (style.parentNode === null) return false; - style.parentNode.removeChild(style); +var propTypes$16 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node +}; - var idx = stylesInsertedAtTop.indexOf(style); - if(idx >= 0) { - stylesInsertedAtTop.splice(idx, 1); - } -} +var ButtonDropdown = function ButtonDropdown(props) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Dropdown, _extends({ group: true }, props)); +}; -function createStyleElement (options) { - var style = document.createElement("style"); +ButtonDropdown.propTypes = propTypes$16; - options.attrs.type = "text/css"; +var propTypes$17 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + vertical: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; - addAttrs(style, options.attrs); - insertStyleElement(options, style); +var defaultProps$16 = { + tag: 'div', + role: 'group' +}; - return style; -} +var ButtonGroup = function ButtonGroup(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + vertical = props.vertical, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'vertical', 'tag']); -function createLinkElement (options) { - var link = document.createElement("link"); - options.attrs.type = "text/css"; - options.attrs.rel = "stylesheet"; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, size ? 'btn-group-' + size : false, vertical ? 'btn-group-vertical' : 'btn-group'), cssModule); - addAttrs(link, options.attrs); - insertStyleElement(options, link); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - return link; -} +ButtonGroup.propTypes = propTypes$17; +ButtonGroup.defaultProps = defaultProps$16; -function addAttrs (el, attrs) { - Object.keys(attrs).forEach(function (key) { - el.setAttribute(key, attrs[key]); - }); -} +var propTypes$18 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + role: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string +}; -function addStyle (obj, options) { - var style, update, remove, result; +var defaultProps$17 = { + tag: 'div', + role: 'toolbar' +}; - // If a transform function was defined, run it on the css - if (options.transform && obj.css) { - result = options.transform(obj.css); +var ButtonToolbar = function ButtonToolbar(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - if (result) { - // If transform returns a value, use that instead of the original css. - // This allows running runtime transformations on the css. - obj.css = result; - } else { - // If the transform function returns a falsy value, don't add this css. - // This allows conditional loading of css - return function() { - // noop - }; - } - } - if (options.singleton) { - var styleIndex = singletonCounter++; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'btn-toolbar'), cssModule); - style = singleton || (singleton = createStyleElement(options)); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - update = applyToSingletonTag.bind(null, style, styleIndex, false); - remove = applyToSingletonTag.bind(null, style, styleIndex, true); +ButtonToolbar.propTypes = propTypes$18; +ButtonToolbar.defaultProps = defaultProps$17; - } else if ( - obj.sourceMap && - typeof URL === "function" && - typeof URL.createObjectURL === "function" && - typeof URL.revokeObjectURL === "function" && - typeof Blob === "function" && - typeof btoa === "function" - ) { - style = createLinkElement(options); - update = updateLink.bind(null, style, options); - remove = function () { - removeStyleElement(style); +var propTypes$19 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + divider: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + header: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; - if(style.href) URL.revokeObjectURL(style.href); - }; - } else { - style = createStyleElement(options); - update = applyToTag.bind(null, style); - remove = function () { - removeStyleElement(style); - }; - } +var contextTypes$1 = { + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; - update(obj); +var defaultProps$18 = { + tag: 'button', + toggle: true +}; - return function updateStyle (newObj) { - if (newObj) { - if ( - newObj.css === obj.css && - newObj.media === obj.media && - newObj.sourceMap === obj.sourceMap - ) { - return; - } +var DropdownItem = function (_React$Component) { + inherits(DropdownItem, _React$Component); - update(obj = newObj); - } else { - remove(); - } - }; -} + function DropdownItem(props) { + classCallCheck(this, DropdownItem); -var replaceText = (function () { - var textStore = []; + var _this = possibleConstructorReturn(this, (DropdownItem.__proto__ || Object.getPrototypeOf(DropdownItem)).call(this, props)); - return function (index, replacement) { - textStore[index] = replacement; + _this.onClick = _this.onClick.bind(_this); + _this.getTabIndex = _this.getTabIndex.bind(_this); + return _this; + } - return textStore.filter(Boolean).join('\n'); - }; -})(); + createClass(DropdownItem, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled || this.props.header || this.props.divider) { + e.preventDefault(); + return; + } -function applyToSingletonTag (style, index, remove, obj) { - var css = remove ? "" : obj.css; + if (this.props.onClick) { + this.props.onClick(e); + } - if (style.styleSheet) { - style.styleSheet.cssText = replaceText(index, css); - } else { - var cssNode = document.createTextNode(css); - var childNodes = style.childNodes; + if (this.props.toggle) { + this.context.toggle(); + } + } + }, { + key: 'getTabIndex', + value: function getTabIndex() { + if (this.props.disabled || this.props.header || this.props.divider) { + return '-1'; + } - if (childNodes[index]) style.removeChild(childNodes[index]); + return '0'; + } + }, { + key: 'render', + value: function render() { + var tabIndex = this.getTabIndex(); - if (childNodes.length) { - style.insertBefore(cssNode, childNodes[index]); - } else { - style.appendChild(cssNode); - } - } -} + var _omit = omit(this.props, ['toggle']), + className = _omit.className, + cssModule = _omit.cssModule, + divider = _omit.divider, + Tag = _omit.tag, + header = _omit.header, + active = _omit.active, + props = objectWithoutProperties(_omit, ['className', 'cssModule', 'divider', 'tag', 'header', 'active']); -function applyToTag (style, obj) { - var css = obj.css; - var media = obj.media; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + disabled: props.disabled, + 'dropdown-item': !divider && !header, + active: active, + 'dropdown-header': header, + 'dropdown-divider': divider + }), cssModule); - if(media) { - style.setAttribute("media", media) - } + if (Tag === 'button') { + if (header) { + Tag = 'h6'; + } else if (divider) { + Tag = 'div'; + } else if (props.href) { + Tag = 'a'; + } + } - if(style.styleSheet) { - style.styleSheet.cssText = css; - } else { - while(style.firstChild) { - style.removeChild(style.firstChild); - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ + type: Tag === 'button' && (props.onClick || this.props.toggle) ? 'button' : undefined + }, props, { + tabIndex: tabIndex, + className: classes, + onClick: this.onClick + })); + } + }]); + return DropdownItem; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - style.appendChild(document.createTextNode(css)); - } -} +DropdownItem.propTypes = propTypes$19; +DropdownItem.defaultProps = defaultProps$18; +DropdownItem.contextTypes = contextTypes$1; -function updateLink (link, options, obj) { - var css = obj.css; - var sourceMap = obj.sourceMap; +var propTypes$20 = { + caret: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onClick: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + 'data-toggle': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + 'aria-haspopup': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + split: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + nav: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; - /* - If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled - and there is no publicPath defined then lets turn convertToAbsoluteUrls - on by default. Otherwise default to the convertToAbsoluteUrls option - directly - */ - var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap; +var defaultProps$19 = { + 'data-toggle': 'dropdown', + 'aria-haspopup': true, + color: 'secondary' +}; - if (options.convertToAbsoluteUrls || autoFixUrls) { - css = fixUrls(css); - } +var contextTypes$2 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool.isRequired, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func.isRequired +}; - if (sourceMap) { - // http://stackoverflow.com/a/26603875 - css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */"; - } +var DropdownToggle = function (_React$Component) { + inherits(DropdownToggle, _React$Component); - var blob = new Blob([css], { type: "text/css" }); + function DropdownToggle(props) { + classCallCheck(this, DropdownToggle); - var oldSrc = link.href; + var _this = possibleConstructorReturn(this, (DropdownToggle.__proto__ || Object.getPrototypeOf(DropdownToggle)).call(this, props)); - link.href = URL.createObjectURL(blob); + _this.onClick = _this.onClick.bind(_this); + return _this; + } - if(oldSrc) URL.revokeObjectURL(oldSrc); -} + createClass(DropdownToggle, [{ + key: 'onClick', + value: function onClick(e) { + if (this.props.disabled) { + e.preventDefault(); + return; + } + if (this.props.nav && !this.props.tag) { + e.preventDefault(); + } -/***/ }), -/* 74 */ -/***/ (function(module, exports, __webpack_require__) { + if (this.props.onClick) { + this.props.onClick(e); + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + this.context.toggle(); + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + color = _props.color, + cssModule = _props.cssModule, + caret = _props.caret, + split = _props.split, + nav = _props.nav, + tag = _props.tag, + props = objectWithoutProperties(_props, ['className', 'color', 'cssModule', 'caret', 'split', 'nav', 'tag']); + var ariaLabel = props['aria-label'] || 'Toggle Dropdown'; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + 'dropdown-toggle': caret || split, + 'dropdown-toggle-split': split, + active: this.context.isOpen, + 'nav-link': nav + }), cssModule); + var children = props.children || __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { className: 'sr-only' }, + ariaLabel + ); + var Tag = void 0; -var _prodInvariant = __webpack_require__(25), - _assign = __webpack_require__(5); + if (nav && !tag) { + Tag = 'a'; + props.href = '#'; + } else if (!tag) { + Tag = Button; + props.color = color; + } else { + Tag = tag; + } -var ReactNoopUpdateQueue = __webpack_require__(75); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, props, { + className: classes, + onClick: this.onClick, + 'aria-haspopup': 'true', + 'aria-expanded': this.context.isOpen, + children: children + })); + } + }]); + return DropdownToggle; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -var canDefineProperty = __webpack_require__(38); -var emptyObject = __webpack_require__(39); -var invariant = __webpack_require__(1); -var lowPriorityWarning = __webpack_require__(48); +DropdownToggle.propTypes = propTypes$20; +DropdownToggle.defaultProps = defaultProps$19; +DropdownToggle.contextTypes = contextTypes$2; -/** - * Base class helpers for the updating state of a component. - */ -function ReactComponent(props, context, updater) { - this.props = props; - this.context = context; - this.refs = emptyObject; - // We initialize the default updater but the real one gets injected by the - // renderer. - this.updater = updater || ReactNoopUpdateQueue; -} - -ReactComponent.prototype.isReactComponent = {}; +var propTypes$21 = { + baseClass: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + baseClassIn: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionAppear: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + transitionEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + transitionLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + onLeave: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; -/** - * Sets a subset of the state. Always use this to mutate - * state. You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * There is no guarantee that calls to `setState` will run synchronously, - * as they may eventually be batched together. You can provide an optional - * callback that will be executed when the call to setState is actually - * completed. - * - * When a function is provided to setState, it will be called at some point in - * the future (not synchronously). It will be called with the up to date - * component arguments (state, props, context). These values can be different - * from this.* because your function may be called after receiveProps but before - * shouldComponentUpdate, and this new state, props, and context will not yet be - * assigned to this. - * - * @param {object|function} partialState Next partial state or function to - * produce next partial state to be merged with current state. - * @param {?function} callback Called after state is updated. - * @final - * @protected - */ -ReactComponent.prototype.setState = function (partialState, callback) { - !(typeof partialState === 'object' || typeof partialState === 'function' || partialState == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.') : _prodInvariant('85') : void 0; - this.updater.enqueueSetState(this, partialState); - if (callback) { - this.updater.enqueueCallback(this, callback, 'setState'); - } +var defaultProps$20 = { + tag: 'div', + baseClass: 'fade', + baseClassIn: 'show', + transitionAppearTimeout: 0, + transitionEnterTimeout: 0, + transitionLeaveTimeout: 0, + transitionAppear: true, + transitionEnter: true, + transitionLeave: true }; -/** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {?function} callback Called after update is complete. - * @final - * @protected - */ -ReactComponent.prototype.forceUpdate = function (callback) { - this.updater.enqueueForceUpdate(this); - if (callback) { - this.updater.enqueueCallback(this, callback, 'forceUpdate'); +var Fade = function (_React$Component) { + inherits(Fade, _React$Component); + + function Fade(props) { + classCallCheck(this, Fade); + + var _this = possibleConstructorReturn(this, (Fade.__proto__ || Object.getPrototypeOf(Fade)).call(this, props)); + + _this.state = { + mounted: !props.transitionAppear + }; + + _this.onLeave = _this.onLeave.bind(_this); + _this.onEnter = _this.onEnter.bind(_this); + _this.timers = []; + return _this; } -}; -/** - * Deprecated APIs. These APIs used to exist on classic React classes but since - * we would like to deprecate them, we're not going to move them over to this - * modern base class. Instead, we define a getter that warns if it's accessed. - */ -if (process.env.NODE_ENV !== 'production') { - var deprecatedAPIs = { - isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'], - replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).'] - }; - var defineDeprecationWarning = function (methodName, info) { - if (canDefineProperty) { - Object.defineProperty(ReactComponent.prototype, methodName, { - get: function () { - lowPriorityWarning(false, '%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]); - return undefined; + createClass(Fade, [{ + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.timers.forEach(function (timer) { + return clearTimeout(timer); + }); + } + }, { + key: 'onEnter', + value: function onEnter(cb) { + var _this2 = this; + + return function () { + cb(); + if (_this2.props.onEnter) { + _this2.props.onEnter(); + } + }; + } + }, { + key: 'onLeave', + value: function onLeave(cb) { + var _this3 = this; + + return function () { + cb(); + if (_this3.props.onLeave) { + _this3.props.onLeave(); } + }; + } + }, { + key: 'componentWillAppear', + value: function componentWillAppear(cb) { + if (!this.props.transitionAppear) { + this.onEnter(cb)(); + } + + this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionAppearTimeout)); + } + }, { + key: 'componentDidAppear', + value: function componentDidAppear() { + this.setState({ + mounted: true }); } - }; - for (var fnName in deprecatedAPIs) { - if (deprecatedAPIs.hasOwnProperty(fnName)) { - defineDeprecationWarning(fnName, deprecatedAPIs[fnName]); + }, { + key: 'componentWillEnter', + value: function componentWillEnter(cb) { + if (!this.props.transitionEnter) { + this.onEnter(cb)(); + } + + this.timers.push(setTimeout(this.onEnter(cb), this.props.transitionEnterTimeout)); } - } -} + }, { + key: 'componentDidEnter', + value: function componentDidEnter() { + this.setState({ + mounted: true + }); + } + }, { + key: 'componentWillLeave', + value: function componentWillLeave(cb) { + this.setState({ + mounted: false + }); -/** - * Base class helpers for the updating state of a component. - */ -function ReactPureComponent(props, context, updater) { - // Duplicated from ReactComponent. - this.props = props; - this.context = context; - this.refs = emptyObject; - // We initialize the default updater but the real one gets injected by the - // renderer. - this.updater = updater || ReactNoopUpdateQueue; -} + if (!this.props.transitionLeave) { + this.onLeave(cb)(); + } -function ComponentDummy() {} -ComponentDummy.prototype = ReactComponent.prototype; -ReactPureComponent.prototype = new ComponentDummy(); -ReactPureComponent.prototype.constructor = ReactPureComponent; -// Avoid an extra prototype jump for these methods. -_assign(ReactPureComponent.prototype, ReactComponent.prototype); -ReactPureComponent.prototype.isPureReactComponent = true; + this.timers.push(setTimeout(this.onLeave(cb), this.props.transitionLeaveTimeout)); + } + }, { + key: 'render', + value: function render() { + var _props = this.props, + baseClass = _props.baseClass, + baseClassIn = _props.baseClassIn, + className = _props.className, + cssModule = _props.cssModule, + Tag = _props.tag; -module.exports = { - Component: ReactComponent, - PureComponent: ReactPureComponent -}; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + var attributes = omit(this.props, Object.keys(propTypes$21)); -/***/ }), -/* 75 */ -/***/ (function(module, exports, __webpack_require__) { + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, baseClass, this.state.mounted ? baseClassIn : false), cssModule); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); + } + }]); + return Fade; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +Fade.propTypes = propTypes$21; +Fade.defaultProps = defaultProps$20; +var propTypes$22 = { + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + pill: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var warning = __webpack_require__(2); +var defaultProps$21 = { + color: 'default', + pill: false, + tag: 'span' +}; -function warnNoop(publicInstance, callerName) { - if (process.env.NODE_ENV !== 'production') { - var constructor = publicInstance.constructor; - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; - } -} +var Badge = function Badge(props) { + var className = props.className, + cssModule = props.cssModule, + color = props.color, + pill = props.pill, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'pill', 'tag']); -/** - * This is the abstract API for an update queue. - */ -var ReactNoopUpdateQueue = { - /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function (publicInstance) { - return false; - }, - /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. - * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @internal - */ - enqueueCallback: function (publicInstance, callback) {}, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'badge', 'badge-' + color, pill ? 'badge-pill' : false), cssModule); - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal - */ - enqueueForceUpdate: function (publicInstance) { - warnNoop(publicInstance, 'forceUpdate'); - }, + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} completeState Next state. - * @internal - */ - enqueueReplaceState: function (publicInstance, completeState) { - warnNoop(publicInstance, 'replaceState'); - }, +Badge.propTypes = propTypes$22; +Badge.defaultProps = defaultProps$21; - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object} partialState Next partial state to be merged with state. - * @internal - */ - enqueueSetState: function (publicInstance, partialState) { - warnNoop(publicInstance, 'setState'); - } +var propTypes$23 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + block: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + outline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -module.exports = ReactNoopUpdateQueue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var defaultProps$22 = { + tag: 'div' +}; -/***/ }), -/* 76 */ -/***/ (function(module, exports, __webpack_require__) { +var Card = function Card(props) { + var className = props.className, + cssModule = props.cssModule, + color = props.color, + block = props.block, + inverse = props.inverse, + outline = props.outline, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'color', 'block', 'inverse', 'outline', 'tag']); -"use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card', inverse ? 'card-inverse' : false, block ? 'card-block' : false, color ? 'card' + (outline ? '-outline' : '') + '-' + color : false), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +Card.propTypes = propTypes$23; +Card.defaultProps = defaultProps$22; -// The Symbol used to tag the ReactElement type. If there is no native Symbol -// nor polyfill, then a plain number is used for performance. +var propTypes$24 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; +var defaultProps$23 = { + tag: 'div' +}; -module.exports = REACT_ELEMENT_TYPE; +var CardGroup = function CardGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -/***/ }), -/* 77 */ -/***/ (function(module, exports, __webpack_require__) { + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-group'), cssModule); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +CardGroup.propTypes = propTypes$24; +CardGroup.defaultProps = defaultProps$23; +var propTypes$25 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -/* global Symbol */ +var defaultProps$24 = { + tag: 'div' +}; -var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; -var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. +var CardDeck = function CardDeck(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -/** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } - * - * @param {?object} maybeIterable - * @return {?function} - */ -function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; - } -} + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-deck'), cssModule); -module.exports = getIteratorFn; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -/***/ }), -/* 78 */ -/***/ (function(module, exports, __webpack_require__) { +CardDeck.propTypes = propTypes$25; +CardDeck.defaultProps = defaultProps$24; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var propTypes$26 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -/** - * ReactElementValidator provides a wrapper around a element factory - * which validates the props passed to the element. This is intended to be - * used only in DEV and could be replaced by a static type checker for languages - * that support it. - */ +var defaultProps$25 = { + tag: 'div' +}; +var CardColumns = function CardColumns(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-columns'), cssModule); -var ReactCurrentOwner = __webpack_require__(14); -var ReactComponentTreeHook = __webpack_require__(10); -var ReactElement = __webpack_require__(19); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var checkReactTypeSpec = __webpack_require__(127); +CardColumns.propTypes = propTypes$26; +CardColumns.defaultProps = defaultProps$25; -var canDefineProperty = __webpack_require__(38); -var getIteratorFn = __webpack_require__(77); -var warning = __webpack_require__(2); -var lowPriorityWarning = __webpack_require__(48); +var propTypes$27 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -function getDeclarationErrorAddendum() { - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; -} +var defaultProps$26 = { + tag: 'div' +}; -function getSourceInfoErrorAddendum(elementProps) { - if (elementProps !== null && elementProps !== undefined && elementProps.__source !== undefined) { - var source = elementProps.__source; - var fileName = source.fileName.replace(/^.*[\\\/]/, ''); - var lineNumber = source.lineNumber; - return ' Check your code at ' + fileName + ':' + lineNumber + '.'; - } - return ''; -} +var CardBlock = function CardBlock(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -/** - * Warn if there's no key explicitly set on dynamic arrays of children or - * object keys are not valid. This allows us to keep track of children between - * updates. - */ -var ownerHasKeyUseWarning = {}; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-block'), cssModule); -function getCurrentComponentErrorInfo(parentType) { - var info = getDeclarationErrorAddendum(); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (!info) { - var parentName = typeof parentType === 'string' ? parentType : parentType.displayName || parentType.name; - if (parentName) { - info = ' Check the top-level render call using <' + parentName + '>.'; - } - } - return info; -} +CardBlock.propTypes = propTypes$27; +CardBlock.defaultProps = defaultProps$26; -/** - * Warn if the element doesn't have an explicit key assigned to it. - * This element is in an array. The array could grow and shrink or be - * reordered. All children that haven't already been validated are required to - * have a "key" property assigned to it. Error statuses are cached so a warning - * will only be shown once. - * - * @internal - * @param {ReactElement} element Element that requires a key. - * @param {*} parentType element's parent's type. - */ -function validateExplicitKey(element, parentType) { - if (!element._store || element._store.validated || element.key != null) { - return; - } - element._store.validated = true; +var propTypes$28 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - var memoizer = ownerHasKeyUseWarning.uniqueKey || (ownerHasKeyUseWarning.uniqueKey = {}); +var defaultProps$27 = { + tag: 'a' +}; - var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType); - if (memoizer[currentComponentErrorInfo]) { - return; - } - memoizer[currentComponentErrorInfo] = true; +var CardLink = function CardLink(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + getRef = props.getRef, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'getRef']); - // Usually the current owner is the offender, but if it accepts children as a - // property, it may be the creator of the child that's responsible for - // assigning it a key. - var childOwner = ''; - if (element && element._owner && element._owner !== ReactCurrentOwner.current) { - // Give the component that originally created this child. - childOwner = ' It was passed a child from ' + element._owner.getName() + '.'; - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-link'), cssModule); - process.env.NODE_ENV !== 'production' ? warning(false, 'Each child in an array or iterator should have a unique "key" prop.' + '%s%s See https://fb.me/react-warning-keys for more information.%s', currentComponentErrorInfo, childOwner, ReactComponentTreeHook.getCurrentStackAddendum(element)) : void 0; -} + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); +}; -/** - * Ensure that every element either is passed in a static location, in an - * array with an explicit keys property defined, or in an object literal - * with valid key property. - * - * @internal - * @param {ReactNode} node Statically passed child of any type. - * @param {*} parentType node's parent's type. - */ -function validateChildKeys(node, parentType) { - if (typeof node !== 'object') { - return; - } - if (Array.isArray(node)) { - for (var i = 0; i < node.length; i++) { - var child = node[i]; - if (ReactElement.isValidElement(child)) { - validateExplicitKey(child, parentType); - } - } - } else if (ReactElement.isValidElement(node)) { - // This element was passed in a valid location. - if (node._store) { - node._store.validated = true; - } - } else if (node) { - var iteratorFn = getIteratorFn(node); - // Entry iterators provide implicit keys. - if (iteratorFn) { - if (iteratorFn !== node.entries) { - var iterator = iteratorFn.call(node); - var step; - while (!(step = iterator.next()).done) { - if (ReactElement.isValidElement(step.value)) { - validateExplicitKey(step.value, parentType); - } - } - } - } - } -} +CardLink.propTypes = propTypes$28; +CardLink.defaultProps = defaultProps$27; -/** - * Given an element, validate that its props follow the propTypes definition, - * provided by the type. - * - * @param {ReactElement} element - */ -function validatePropTypes(element) { - var componentClass = element.type; - if (typeof componentClass !== 'function') { - return; - } - var name = componentClass.displayName || componentClass.name; - if (componentClass.propTypes) { - checkReactTypeSpec(componentClass.propTypes, element.props, 'prop', name, element, null); - } - if (typeof componentClass.getDefaultProps === 'function') { - process.env.NODE_ENV !== 'production' ? warning(componentClass.getDefaultProps.isReactClassApproved, 'getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.') : void 0; - } -} +var propTypes$29 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var ReactElementValidator = { - createElement: function (type, props, children) { - var validType = typeof type === 'string' || typeof type === 'function'; - // We warn in this case but don't throw. We expect the element creation to - // succeed and there will likely be errors in render. - if (!validType) { - if (typeof type !== 'function' && typeof type !== 'string') { - var info = ''; - if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { - info += ' You likely forgot to export your component from the file ' + "it's defined in."; - } +var defaultProps$28 = { + tag: 'div' +}; - var sourceInfo = getSourceInfoErrorAddendum(props); - if (sourceInfo) { - info += sourceInfo; - } else { - info += getDeclarationErrorAddendum(); - } +var CardFooter = function CardFooter(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - info += ReactComponentTreeHook.getCurrentStackAddendum(); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-footer'), cssModule); - var currentSource = props !== null && props !== undefined && props.__source !== undefined ? props.__source : null; - ReactComponentTreeHook.pushNonStandardWarningStack(true, currentSource); - process.env.NODE_ENV !== 'production' ? warning(false, 'React.createElement: type is invalid -- expected a string (for ' + 'built-in components) or a class/function (for composite ' + 'components) but got: %s.%s', type == null ? type : typeof type, info) : void 0; - ReactComponentTreeHook.popNonStandardWarningStack(); - } - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - var element = ReactElement.createElement.apply(this, arguments); +CardFooter.propTypes = propTypes$29; +CardFooter.defaultProps = defaultProps$28; - // The result can be nullish if a mock or a custom function is used. - // TODO: Drop this when these are no longer allowed as the type argument. - if (element == null) { - return element; - } +var propTypes$30 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - // Skip key warning if the type isn't valid since our key validation logic - // doesn't expect a non-string/function type and can throw confusing errors. - // We don't want exception behavior to differ between dev and prod. - // (Rendering will throw with a helpful message and as soon as the type is - // fixed, the key warnings will appear.) - if (validType) { - for (var i = 2; i < arguments.length; i++) { - validateChildKeys(arguments[i], type); - } - } +var defaultProps$29 = { + tag: 'div' +}; - validatePropTypes(element); +var CardHeader = function CardHeader(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - return element; - }, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-header'), cssModule); - createFactory: function (type) { - var validatedFactory = ReactElementValidator.createElement.bind(null, type); - // Legacy hook TODO: Warn if this is accessed - validatedFactory.type = type; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (process.env.NODE_ENV !== 'production') { - if (canDefineProperty) { - Object.defineProperty(validatedFactory, 'type', { - enumerable: false, - get: function () { - lowPriorityWarning(false, 'Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.'); - Object.defineProperty(this, 'type', { - value: type - }); - return type; - } - }); - } - } +CardHeader.propTypes = propTypes$30; +CardHeader.defaultProps = defaultProps$29; - return validatedFactory; - }, +var propTypes$31 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - cloneElement: function (element, props, children) { - var newElement = ReactElement.cloneElement.apply(this, arguments); - for (var i = 2; i < arguments.length; i++) { - validateChildKeys(arguments[i], newElement.type); - } - validatePropTypes(newElement); - return newElement; - } +var defaultProps$30 = { + tag: 'img' }; -module.exports = ReactElementValidator; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var CardImg = function CardImg(props) { + var className = props.className, + cssModule = props.cssModule, + top = props.top, + bottom = props.bottom, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'top', 'bottom', 'tag']); -/***/ }), -/* 79 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ + var cardImgClassName = 'card-img'; + if (top) { + cardImgClassName = 'card-img-top'; + } + if (bottom) { + cardImgClassName = 'card-img-bottom'; + } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, cardImgClassName), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -// React 15.5 references this module, and assumes PropTypes are still callable in production. -// Therefore we re-export development-only version with all the PropTypes checks here. -// However if one is migrating to the `prop-types` npm library, they will go through the -// `index.js` entry point, and it will branch depending on the environment. -var factory = __webpack_require__(80); -module.exports = function(isValidElement) { - // It is still allowed in 15.5. - var throwOnDirectAccess = false; - return factory(isValidElement, throwOnDirectAccess); +CardImg.propTypes = propTypes$31; +CardImg.defaultProps = defaultProps$30; + +var propTypes$32 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; +var defaultProps$31 = { + tag: 'div' +}; -/***/ }), -/* 80 */ -/***/ (function(module, exports, __webpack_require__) { +var CardImgOverlay = function CardImgOverlay(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-img-overlay'), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +CardImgOverlay.propTypes = propTypes$32; +CardImgOverlay.defaultProps = defaultProps$31; -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +var propTypes$33 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var ReactPropTypesSecret = __webpack_require__(49); -var checkPropTypes = __webpack_require__(131); +var defaultProps$32 = { + tag: 'h6' +}; -module.exports = function(isValidElement, throwOnDirectAccess) { - /* global Symbol */ - var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; - var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. +var CardSubtitle = function CardSubtitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - /** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } - * - * @param {?object} maybeIterable - * @return {?function} - */ - function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; - } - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-subtitle'), cssModule); - /** - * Collection of methods that allow declaration and validation of props that are - * supplied to React components. Example usage: - * - * var Props = require('ReactPropTypes'); - * var MyArticle = React.createClass({ - * propTypes: { - * // An optional string prop named "description". - * description: Props.string, - * - * // A required enum prop named "category". - * category: Props.oneOf(['News','Photos']).isRequired, - * - * // A prop named "dialog" that requires an instance of Dialog. - * dialog: Props.instanceOf(Dialog).isRequired - * }, - * render: function() { ... } - * }); - * - * A more formal specification of how these methods are used: - * - * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...) - * decl := ReactPropTypes.{type}(.isRequired)? - * - * Each and every declaration produces a function with the same signature. This - * allows the creation of custom validation functions. For example: - * - * var MyLink = React.createClass({ - * propTypes: { - * // An optional string or URI prop named "href". - * href: function(props, propName, componentName) { - * var propValue = props[propName]; - * if (propValue != null && typeof propValue !== 'string' && - * !(propValue instanceof URI)) { - * return new Error( - * 'Expected a string or an URI for ' + propName + ' in ' + - * componentName - * ); - * } - * } - * }, - * render: function() {...} - * }); - * - * @internal - */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - var ANONYMOUS = '<<anonymous>>'; +CardSubtitle.propTypes = propTypes$33; +CardSubtitle.defaultProps = defaultProps$32; - // Important! - // Keep this list in sync with production version in `./factoryWithThrowingShims.js`. - var ReactPropTypes = { - array: createPrimitiveTypeChecker('array'), - bool: createPrimitiveTypeChecker('boolean'), - func: createPrimitiveTypeChecker('function'), - number: createPrimitiveTypeChecker('number'), - object: createPrimitiveTypeChecker('object'), - string: createPrimitiveTypeChecker('string'), - symbol: createPrimitiveTypeChecker('symbol'), +var propTypes$34 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - any: createAnyTypeChecker(), - arrayOf: createArrayOfTypeChecker, - element: createElementTypeChecker(), - instanceOf: createInstanceTypeChecker, - node: createNodeChecker(), - objectOf: createObjectOfTypeChecker, - oneOf: createEnumTypeChecker, - oneOfType: createUnionTypeChecker, - shape: createShapeTypeChecker - }; +var defaultProps$33 = { + tag: 'p' +}; - /** - * inlined Object.is polyfill to avoid requiring consumers ship their own - * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is - */ - /*eslint-disable no-self-compare*/ - function is(x, y) { - // SameValue algorithm - if (x === y) { - // Steps 1-5, 7-10 - // Steps 6.b-6.e: +0 != -0 - return x !== 0 || 1 / x === 1 / y; - } else { - // Step 6.a: NaN == NaN - return x !== x && y !== y; - } - } - /*eslint-enable no-self-compare*/ +var CardText = function CardText(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - /** - * We use an Error-like object for backward compatibility as people may call - * PropTypes directly and inspect their output. However, we don't use real - * Errors anymore. We don't inspect their stack anyway, and creating them - * is prohibitively expensive if they are created too often, such as what - * happens in oneOfType() for any type before the one that matched. - */ - function PropTypeError(message) { - this.message = message; - this.stack = ''; - } - // Make `instanceof Error` still work for returned errors. - PropTypeError.prototype = Error.prototype; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-text'), cssModule); - function createChainableTypeChecker(validate) { - if (process.env.NODE_ENV !== 'production') { - var manualPropTypeCallCache = {}; - var manualPropTypeWarningCount = 0; - } - function checkType(isRequired, props, propName, componentName, location, propFullName, secret) { - componentName = componentName || ANONYMOUS; - propFullName = propFullName || propName; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (secret !== ReactPropTypesSecret) { - if (throwOnDirectAccess) { - // New behavior only for users of `prop-types` package - invariant( - false, - 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + - 'Use `PropTypes.checkPropTypes()` to call them. ' + - 'Read more at http://fb.me/use-check-prop-types' - ); - } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') { - // Old behavior for people using React.PropTypes - var cacheKey = componentName + ':' + propName; - if ( - !manualPropTypeCallCache[cacheKey] && - // Avoid spamming the console because they are often not actionable except for lib authors - manualPropTypeWarningCount < 3 - ) { - warning( - false, - 'You are manually calling a React.PropTypes validation ' + - 'function for the `%s` prop on `%s`. This is deprecated ' + - 'and will throw in the standalone `prop-types` package. ' + - 'You may be seeing this warning due to a third-party PropTypes ' + - 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.', - propFullName, - componentName - ); - manualPropTypeCallCache[cacheKey] = true; - manualPropTypeWarningCount++; - } - } - } - if (props[propName] == null) { - if (isRequired) { - if (props[propName] === null) { - return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.')); - } - return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.')); - } - return null; - } else { - return validate(props, propName, componentName, location, propFullName); - } - } +CardText.propTypes = propTypes$34; +CardText.defaultProps = defaultProps$33; - var chainedCheckType = checkType.bind(null, false); - chainedCheckType.isRequired = checkType.bind(null, true); +var propTypes$35 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - return chainedCheckType; - } +var defaultProps$34 = { + tag: 'h4' +}; - function createPrimitiveTypeChecker(expectedType) { - function validate(props, propName, componentName, location, propFullName, secret) { - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== expectedType) { - // `propValue` being instance of, say, date/regexp, pass the 'object' - // check, but we can offer a more precise error message here rather than - // 'of type `object`'. - var preciseType = getPreciseType(propValue); +var CardTitle = function CardTitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.')); - } - return null; - } - return createChainableTypeChecker(validate); - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'card-title'), cssModule); - function createAnyTypeChecker() { - return createChainableTypeChecker(emptyFunction.thatReturnsNull); - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - function createArrayOfTypeChecker(typeChecker) { - function validate(props, propName, componentName, location, propFullName) { - if (typeof typeChecker !== 'function') { - return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.'); - } - var propValue = props[propName]; - if (!Array.isArray(propValue)) { - var propType = getPropType(propValue); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.')); - } - for (var i = 0; i < propValue.length; i++) { - var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret); - if (error instanceof Error) { - return error; - } - } - return null; - } - return createChainableTypeChecker(validate); - } +CardTitle.propTypes = propTypes$35; +CardTitle.defaultProps = defaultProps$34; - function createElementTypeChecker() { - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - if (!isValidElement(propValue)) { - var propType = getPropType(propValue); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.')); - } - return null; - } - return createChainableTypeChecker(validate); - } +var propTypes$36 = { + placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), + target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string.isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func +}; - function createInstanceTypeChecker(expectedClass) { - function validate(props, propName, componentName, location, propFullName) { - if (!(props[propName] instanceof expectedClass)) { - var expectedClassName = expectedClass.name || ANONYMOUS; - var actualClassName = getClassName(props[propName]); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.')); - } - return null; - } - return createChainableTypeChecker(validate); - } +var defaultProps$35 = { + isOpen: false, + placement: 'bottom', + toggle: function toggle() {} +}; - function createEnumTypeChecker(expectedValues) { - if (!Array.isArray(expectedValues)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOf, expected an instance of array.') : void 0; - return emptyFunction.thatReturnsNull; - } +var defaultTetherConfig$1 = { + classPrefix: 'bs-tether', + classes: { + element: false, + enabled: 'show' + }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] +}; - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - for (var i = 0; i < expectedValues.length; i++) { - if (is(propValue, expectedValues[i])) { - return null; - } - } +var Popover = function (_React$Component) { + inherits(Popover, _React$Component); - var valuesString = JSON.stringify(expectedValues); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + propValue + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.')); - } - return createChainableTypeChecker(validate); - } + function Popover(props) { + classCallCheck(this, Popover); - function createObjectOfTypeChecker(typeChecker) { - function validate(props, propName, componentName, location, propFullName) { - if (typeof typeChecker !== 'function') { - return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.'); - } - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== 'object') { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.')); - } - for (var key in propValue) { - if (propValue.hasOwnProperty(key)) { - var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); - if (error instanceof Error) { - return error; - } - } - } - return null; - } - return createChainableTypeChecker(validate); + var _this = possibleConstructorReturn(this, (Popover.__proto__ || Object.getPrototypeOf(Popover)).call(this, props)); + + _this.getTetherConfig = _this.getTetherConfig.bind(_this); + return _this; } - function createUnionTypeChecker(arrayOfTypeCheckers) { - if (!Array.isArray(arrayOfTypeCheckers)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOfType, expected an instance of array.') : void 0; - return emptyFunction.thatReturnsNull; + createClass(Popover, [{ + key: 'getTetherConfig', + value: function getTetherConfig() { + var attachments = getTetherAttachments(this.props.placement); + return _extends({}, defaultTetherConfig$1, attachments, { + target: '#' + this.props.target + }, this.props.tether); } - - for (var i = 0; i < arrayOfTypeCheckers.length; i++) { - var checker = arrayOfTypeCheckers[i]; - if (typeof checker !== 'function') { - warning( - false, - 'Invalid argument supplid to oneOfType. Expected an array of check functions, but ' + - 'received %s at index %s.', - getPostfixForTypeWarning(checker), - i - ); - return emptyFunction.thatReturnsNull; + }, { + key: 'render', + value: function render() { + if (!this.props.isOpen) { + return null; } - } - function validate(props, propName, componentName, location, propFullName) { - for (var i = 0; i < arrayOfTypeCheckers.length; i++) { - var checker = arrayOfTypeCheckers[i]; - if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) { - return null; - } - } + var tetherConfig = this.getTetherConfig(); - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.')); - } - return createChainableTypeChecker(validate); - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('popover-inner', this.props.className), this.props.cssModule); - function createNodeChecker() { - function validate(props, propName, componentName, location, propFullName) { - if (!isNode(props[propName])) { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.')); - } - return null; - } - return createChainableTypeChecker(validate); - } + var attributes = omit(this.props, Object.keys(propTypes$36)); - function createShapeTypeChecker(shapeTypes) { - function validate(props, propName, componentName, location, propFullName) { - var propValue = props[propName]; - var propType = getPropType(propValue); - if (propType !== 'object') { - return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.')); - } - for (var key in shapeTypes) { - var checker = shapeTypes[key]; - if (!checker) { - continue; - } - var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); - if (error) { - return error; - } - } - return null; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + { + className: mapToCssModules('popover', this.props.cssModule), + tether: tetherConfig, + tetherRef: this.props.tetherRef, + isOpen: this.props.isOpen, + toggle: this.props.toggle + }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { className: classes })) + ); } - return createChainableTypeChecker(validate); - } + }]); + return Popover; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - function isNode(propValue) { - switch (typeof propValue) { - case 'number': - case 'string': - case 'undefined': - return true; - case 'boolean': - return !propValue; - case 'object': - if (Array.isArray(propValue)) { - return propValue.every(isNode); - } - if (propValue === null || isValidElement(propValue)) { - return true; - } +Popover.propTypes = propTypes$36; +Popover.defaultProps = defaultProps$35; - var iteratorFn = getIteratorFn(propValue); - if (iteratorFn) { - var iterator = iteratorFn.call(propValue); - var step; - if (iteratorFn !== propValue.entries) { - while (!(step = iterator.next()).done) { - if (!isNode(step.value)) { - return false; - } - } - } else { - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - if (!isNode(entry[1])) { - return false; - } - } - } - } - } else { - return false; - } +var propTypes$37 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - return true; - default: - return false; - } - } +var defaultProps$36 = { + tag: 'h3' +}; - function isSymbol(propType, propValue) { - // Native Symbol. - if (propType === 'symbol') { - return true; - } +var PopoverTitle = function PopoverTitle(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol' - if (propValue['@@toStringTag'] === 'Symbol') { - return true; - } - // Fallback for non-spec compliant Symbols which are polyfilled. - if (typeof Symbol === 'function' && propValue instanceof Symbol) { - return true; - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-title'), cssModule); - return false; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - // Equivalent of `typeof` but with special handling for array and regexp. - function getPropType(propValue) { - var propType = typeof propValue; - if (Array.isArray(propValue)) { - return 'array'; - } - if (propValue instanceof RegExp) { - // Old webkits (at least until Android 4.0) return 'function' rather than - // 'object' for typeof a RegExp. We'll normalize this here so that /bla/ - // passes PropTypes.object. - return 'object'; - } - if (isSymbol(propType, propValue)) { - return 'symbol'; - } - return propType; - } +PopoverTitle.propTypes = propTypes$37; +PopoverTitle.defaultProps = defaultProps$36; - // This handles more types than `getPropType`. Only used for error messages. - // See `createPrimitiveTypeChecker`. - function getPreciseType(propValue) { - if (typeof propValue === 'undefined' || propValue === null) { - return '' + propValue; - } - var propType = getPropType(propValue); - if (propType === 'object') { - if (propValue instanceof Date) { - return 'date'; - } else if (propValue instanceof RegExp) { - return 'regexp'; - } - } - return propType; - } +var propTypes$38 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - // Returns a string that is postfixed to a warning about an invalid type. - // For example, "undefined" or "of type array" - function getPostfixForTypeWarning(value) { - var type = getPreciseType(value); - switch (type) { - case 'array': - case 'object': - return 'an ' + type; - case 'boolean': - case 'date': - case 'regexp': - return 'a ' + type; - default: - return type; - } - } +var defaultProps$37 = { + tag: 'div' +}; - // Returns class name of the object, if any. - function getClassName(propValue) { - if (!propValue.constructor || !propValue.constructor.name) { - return ANONYMOUS; - } - return propValue.constructor.name; - } +var PopoverContent = function PopoverContent(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - ReactPropTypes.checkPropTypes = checkPropTypes; - ReactPropTypes.PropTypes = ReactPropTypes; - return ReactPropTypes; -}; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'popover-content'), cssModule); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -/***/ }), -/* 81 */ -/***/ (function(module, exports, __webpack_require__) { +PopoverContent.propTypes = propTypes$38; +PopoverContent.defaultProps = defaultProps$37; -"use strict"; -/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var propTypes$39 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + bar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + multi: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + value: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + max: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + animated: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + barClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; +var defaultProps$38 = { + tag: 'div', + value: 0, + max: 100 +}; +var Progress = function Progress(props) { + var children = props.children, + className = props.className, + barClassName = props.barClassName, + cssModule = props.cssModule, + value = props.value, + max = props.max, + animated = props.animated, + striped = props.striped, + color = props.color, + bar = props.bar, + multi = props.multi, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['children', 'className', 'barClassName', 'cssModule', 'value', 'max', 'animated', 'striped', 'color', 'bar', 'multi', 'tag']); -var ReactDOMComponentFlags = { - hasCachedChildNodes: 1 << 0 -}; -module.exports = ReactDOMComponentFlags; + var percent = __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(value) / __WEBPACK_IMPORTED_MODULE_7_lodash_tonumber___default()(max) * 100; -/***/ }), -/* 82 */ -/***/ (function(module, exports, __webpack_require__) { + var progressClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'progress'), cssModule); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var progressBarClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('progress-bar', bar ? className || barClassName : barClassName, animated ? 'progress-bar-animated' : null, color ? 'bg-' + color : null, striped || animated ? 'progress-bar-striped' : null), cssModule); + var ProgressBar = multi ? children : __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { + className: progressBarClasses, + style: { width: percent + '%' }, + role: 'progressbar', + 'aria-valuenow': value, + 'aria-valuemin': '0', + 'aria-valuemax': max, + children: children + }); + if (bar) { + return ProgressBar; + } -var _prodInvariant = __webpack_require__(3); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: progressClasses, children: ProgressBar })); +}; -var invariant = __webpack_require__(1); +Progress.propTypes = propTypes$39; +Progress.defaultProps = defaultProps$38; -/** - * Accumulates items that must not be null or undefined into the first one. This - * is used to conserve memory by avoiding array allocations, and thus sacrifices - * API cleanness. Since `current` can be null before being passed in and not - * null after this function, make sure to assign it back to `current`: - * - * `a = accumulateInto(a, b);` - * - * This API should be sparingly used. Try `accumulate` for something cleaner. - * - * @return {*|array<*>} An accumulation of items. - */ +var propTypes$40 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + autoFocus: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + keyboard: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + backdrop: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(['static'])]), + onEnter: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onExit: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + wrapClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + modalClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + backdropClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + contentClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + fade: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + zIndex: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + backdropTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + backdropTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + modalTransitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number +}; -function accumulateInto(current, next) { - !(next != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'accumulateInto(...): Accumulated items must not be null or undefined.') : _prodInvariant('30') : void 0; +var propsToOmit = Object.keys(propTypes$40); - if (current == null) { - return next; +var defaultProps$39 = { + isOpen: false, + autoFocus: true, + backdrop: true, + keyboard: true, + zIndex: 1050, + fade: true, + modalTransitionTimeout: 300, + backdropTransitionTimeout: 150 +}; + +var Modal = function (_React$Component) { + inherits(Modal, _React$Component); + + function Modal(props) { + classCallCheck(this, Modal); + + var _this = possibleConstructorReturn(this, (Modal.__proto__ || Object.getPrototypeOf(Modal)).call(this, props)); + + _this.originalBodyPadding = null; + _this.isBodyOverflowing = false; + _this.togglePortal = _this.togglePortal.bind(_this); + _this.handleBackdropClick = _this.handleBackdropClick.bind(_this); + _this.handleEscape = _this.handleEscape.bind(_this); + _this.destroy = _this.destroy.bind(_this); + _this.onEnter = _this.onEnter.bind(_this); + _this.onExit = _this.onExit.bind(_this); + return _this; } - // Both are not empty. Warning: Never call x.concat(y) when you are not - // certain that x is an Array (x could be a string with concat method). - if (Array.isArray(current)) { - if (Array.isArray(next)) { - current.push.apply(current, next); - return current; + createClass(Modal, [{ + key: 'componentDidMount', + value: function componentDidMount() { + if (this.props.isOpen) { + this.togglePortal(); + } } - current.push(next); - return current; - } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps) { + if (this.props.isOpen !== prevProps.isOpen) { + // handle portal events/dom updates + this.togglePortal(); + } else if (this._element) { + // rerender portal + this.renderIntoSubtree(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.onExit(); + } + }, { + key: 'onEnter', + value: function onEnter() { + if (this.props.onEnter) { + this.props.onEnter(); + } + } + }, { + key: 'onExit', + value: function onExit() { + this.destroy(); + if (this.props.onExit) { + this.props.onExit(); + } + } + }, { + key: 'handleEscape', + value: function handleEscape(e) { + if (this.props.keyboard && e.keyCode === 27 && this.props.toggle) { + this.props.toggle(); + } + } + }, { + key: 'handleBackdropClick', + value: function handleBackdropClick(e) { + if (this.props.backdrop !== true) return; - if (Array.isArray(next)) { - // A bit too dangerous to mutate `next`. - return [current].concat(next); - } + var container = this._dialog; - return [current, next]; -} + if (e.target && !container.contains(e.target) && this.props.toggle) { + this.props.toggle(); + } + } + }, { + key: 'hasTransition', + value: function hasTransition() { + if (this.props.fade === false) { + return false; + } -module.exports = accumulateInto; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return this.props.modalTransitionTimeout > 0; + } + }, { + key: 'togglePortal', + value: function togglePortal() { + if (this.props.isOpen) { + if (this.props.autoFocus) { + this._focus = true; + } + this.show(); + if (!this.hasTransition()) { + this.onEnter(); + } + } else { + this.hide(); + if (!this.hasTransition()) { + this.onExit(); + } + } + } + }, { + key: 'destroy', + value: function destroy() { + if (this._element) { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unmountComponentAtNode(this._element); + document.body.removeChild(this._element); + this._element = null; + } -/***/ }), -/* 83 */ -/***/ (function(module, exports, __webpack_require__) { + // Use regex to prevent matching `modal-open` as part of a different class, e.g. `my-modal-opened` + var classes = document.body.className.replace(/(^| )modal-open( |$)/, ' '); + document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes).trim(), this.props.cssModule); + setScrollbarWidth(this.originalBodyPadding); + } + }, { + key: 'hide', + value: function hide() { + this.renderIntoSubtree(); + } + }, { + key: 'show', + value: function show() { + var classes = document.body.className; + this._element = document.createElement('div'); + this._element.setAttribute('tabindex', '-1'); + this._element.style.position = 'relative'; + this._element.style.zIndex = this.props.zIndex; + this.originalBodyPadding = getOriginalBodyPadding(); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + conditionallyUpdateScrollbar(); + document.body.appendChild(this._element); + document.body.className = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(classes, 'modal-open'), this.props.cssModule); -/** - * @param {array} arr an "accumulation" of items which is either an Array or - * a single item. Useful when paired with the `accumulate` module. This is a - * simple utility that allows us to reason about a collection of items, but - * handling the case when there is exactly one item (and we do not need to - * allocate an array). - */ + this.renderIntoSubtree(); + } + }, { + key: 'renderModalDialog', + value: function renderModalDialog() { + var _this2 = this; -function forEachAccumulated(arr, cb, scope) { - if (Array.isArray(arr)) { - arr.forEach(cb, scope); - } else if (arr) { - cb.call(scope, arr); - } -} + var attributes = omit(this.props, propsToOmit); -module.exports = forEachAccumulated; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + _extends({ + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-dialog', this.props.className, defineProperty({}, 'modal-' + this.props.size, this.props.size)), this.props.cssModule), + role: 'document', + ref: function ref(c) { + return _this2._dialog = c; + } + }, attributes), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + { + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-content', this.props.contentClassName), this.props.cssModule) + }, + this.props.children + ) + ); + } + }, { + key: 'renderIntoSubtree', + value: function renderIntoSubtree() { + __WEBPACK_IMPORTED_MODULE_4_react_dom___default.a.unstable_renderSubtreeIntoContainer(this, this.renderChildren(), this._element); -/***/ }), -/* 84 */ -/***/ (function(module, exports, __webpack_require__) { + // check if modal should receive focus + if (this._focus) { + this._dialog.parentNode.focus(); + this._focus = false; + } + } + }, { + key: 'renderChildren', + value: function renderChildren() { + var _props = this.props, + wrapClassName = _props.wrapClassName, + modalClassName = _props.modalClassName, + backdropClassName = _props.backdropClassName, + cssModule = _props.cssModule, + isOpen = _props.isOpen, + backdrop = _props.backdrop, + modalTransitionTimeout = _props.modalTransitionTimeout, + backdropTransitionTimeout = _props.backdropTransitionTimeout; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var modalAttributes = { + onClickCapture: this.handleBackdropClick, + onKeyUp: this.handleEscape, + style: { display: 'block' }, + tabIndex: '-1' + }; + if (this.hasTransition()) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["TransitionGroup"], + { component: 'div', className: mapToCssModules(wrapClassName) }, + isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Fade, + _extends({ + key: 'modal-dialog', + onEnter: this.onEnter, + onLeave: this.onExit, + transitionAppearTimeout: typeof this.props.modalTransitionAppearTimeout === 'number' ? this.props.modalTransitionAppearTimeout : modalTransitionTimeout, + transitionEnterTimeout: typeof this.props.modalTransitionEnterTimeout === 'number' ? this.props.modalTransitionEnterTimeout : modalTransitionTimeout, + transitionLeaveTimeout: typeof this.props.modalTransitionLeaveTimeout === 'number' ? this.props.modalTransitionLeaveTimeout : modalTransitionTimeout, + cssModule: cssModule, + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', modalClassName), cssModule) + }, modalAttributes), + this.renderModalDialog() + ), + isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Fade, { + key: 'modal-backdrop', + transitionAppearTimeout: typeof this.props.backdropTransitionAppearTimeout === 'number' ? this.props.backdropTransitionAppearTimeout : backdropTransitionTimeout, + transitionEnterTimeout: typeof this.props.backdropTransitionEnterTimeout === 'number' ? this.props.backdropTransitionEnterTimeout : backdropTransitionTimeout, + transitionLeaveTimeout: typeof this.props.backdropTransitionLeaveTimeout === 'number' ? this.props.backdropTransitionLeaveTimeout : backdropTransitionTimeout, + cssModule: cssModule, + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', backdropClassName), cssModule) + }) + ); + } -var ExecutionEnvironment = __webpack_require__(8); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + { className: mapToCssModules(wrapClassName) }, + isOpen && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'div', + _extends({ + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal', 'show', modalClassName), cssModule) + }, modalAttributes), + this.renderModalDialog() + ), + isOpen && backdrop && __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', { + className: mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('modal-backdrop', 'show', backdropClassName), cssModule) + }) + ); + } + }, { + key: 'render', + value: function render() { + return null; + } + }]); + return Modal; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); -var contentKey = null; +Modal.propTypes = propTypes$40; +Modal.defaultProps = defaultProps$39; -/** - * Gets the key used to access text content on a DOM node. - * - * @return {?string} Key used to access text content. - * @internal - */ -function getTextContentAccessor() { - if (!contentKey && ExecutionEnvironment.canUseDOM) { - // Prefer textContent to innerText because many browsers support both but - // SVG <text> elements don't support innerText even when <div> does. - contentKey = 'textContent' in document.documentElement ? 'textContent' : 'innerText'; - } - return contentKey; -} +var propTypes$41 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + wrapTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node +}; -module.exports = getTextContentAccessor; +var defaultProps$40 = { + tag: 'h4', + wrapTag: 'div' +}; -/***/ }), -/* 85 */ -/***/ (function(module, exports, __webpack_require__) { +var ModalHeader = function ModalHeader(props) { + var closeButton = void 0; + var className = props.className, + cssModule = props.cssModule, + children = props.children, + toggle = props.toggle, + Tag = props.tag, + WrapTag = props.wrapTag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'children', 'toggle', 'tag', 'wrapTag']); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-header'), cssModule); + if (toggle) { + closeButton = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'button', + { type: 'button', onClick: toggle, className: 'close', 'aria-label': 'Close' }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { 'aria-hidden': 'true' }, + String.fromCharCode(215) + ) + ); + } -var _prodInvariant = __webpack_require__(3); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + WrapTag, + _extends({}, attributes, { className: classes }), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + { className: mapToCssModules('modal-title', cssModule) }, + children + ), + closeButton + ); +}; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +ModalHeader.propTypes = propTypes$41; +ModalHeader.defaultProps = defaultProps$40; -var PooledClass = __webpack_require__(20); +var propTypes$42 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var invariant = __webpack_require__(1); +var defaultProps$41 = { + tag: 'div' +}; -/** - * A specialized pseudo-event module to help keep track of components waiting to - * be notified when their DOM representations are available for use. - * - * This implements `PooledClass`, so you should never need to instantiate this. - * Instead, use `CallbackQueue.getPooled()`. - * - * @class ReactMountReady - * @implements PooledClass - * @internal - */ +var ModalBody = function ModalBody(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -var CallbackQueue = function () { - function CallbackQueue(arg) { - _classCallCheck(this, CallbackQueue); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-body'), cssModule); - this._callbacks = null; - this._contexts = null; - this._arg = arg; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - /** - * Enqueues a callback to be invoked when `notifyAll` is invoked. - * - * @param {function} callback Invoked when `notifyAll` is invoked. - * @param {?object} context Context to call `callback` with. - * @internal - */ +ModalBody.propTypes = propTypes$42; +ModalBody.defaultProps = defaultProps$41; +var propTypes$43 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - CallbackQueue.prototype.enqueue = function enqueue(callback, context) { - this._callbacks = this._callbacks || []; - this._callbacks.push(callback); - this._contexts = this._contexts || []; - this._contexts.push(context); - }; +var defaultProps$42 = { + tag: 'div' +}; - /** - * Invokes all enqueued callbacks and clears the queue. This is invoked after - * the DOM representation of a component has been created or updated. - * - * @internal - */ +var ModalFooter = function ModalFooter(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'modal-footer'), cssModule); - CallbackQueue.prototype.notifyAll = function notifyAll() { - var callbacks = this._callbacks; - var contexts = this._contexts; - var arg = this._arg; - if (callbacks && contexts) { - !(callbacks.length === contexts.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Mismatched list of contexts in callback queue') : _prodInvariant('24') : void 0; - this._callbacks = null; - this._contexts = null; - for (var i = 0; i < callbacks.length; i++) { - callbacks[i].call(contexts[i], arg); - } - callbacks.length = 0; - contexts.length = 0; - } - }; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - CallbackQueue.prototype.checkpoint = function checkpoint() { - return this._callbacks ? this._callbacks.length : 0; - }; +ModalFooter.propTypes = propTypes$43; +ModalFooter.defaultProps = defaultProps$42; - CallbackQueue.prototype.rollback = function rollback(len) { - if (this._callbacks && this._contexts) { - this._callbacks.length = len; - this._contexts.length = len; - } - }; - - /** - * Resets the internal queue. - * - * @internal - */ +var propTypes$44 = { + placement: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOf(tetherAttachements), + target: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object]).isRequired, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tether: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tetherRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + autohide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]) +}; +var DEFAULT_DELAYS = { + show: 0, + hide: 250 +}; - CallbackQueue.prototype.reset = function reset() { - this._callbacks = null; - this._contexts = null; - }; +var defaultProps$43 = { + isOpen: false, + placement: 'bottom', + delay: DEFAULT_DELAYS, + autohide: true, + toggle: function toggle() {} +}; - /** - * `PooledClass` looks for this. - */ +var defaultTetherConfig$2 = { + classPrefix: 'bs-tether', + classes: { + element: false, + enabled: 'show' + }, + constraints: [{ to: 'scrollParent', attachment: 'together none' }, { to: 'window', attachment: 'together none' }] +}; +var Tooltip = function (_React$Component) { + inherits(Tooltip, _React$Component); - CallbackQueue.prototype.destructor = function destructor() { - this.reset(); - }; + function Tooltip(props) { + classCallCheck(this, Tooltip); - return CallbackQueue; -}(); + var _this = possibleConstructorReturn(this, (Tooltip.__proto__ || Object.getPrototypeOf(Tooltip)).call(this, props)); -module.exports = PooledClass.addPoolingTo(CallbackQueue); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + _this.addTargetEvents = _this.addTargetEvents.bind(_this); + _this.getTarget = _this.getTarget.bind(_this); + _this.getTetherConfig = _this.getTetherConfig.bind(_this); + _this.handleDocumentClick = _this.handleDocumentClick.bind(_this); + _this.removeTargetEvents = _this.removeTargetEvents.bind(_this); + _this.toggle = _this.toggle.bind(_this); + _this.onMouseOverTooltip = _this.onMouseOverTooltip.bind(_this); + _this.onMouseLeaveTooltip = _this.onMouseLeaveTooltip.bind(_this); + _this.onMouseOverTooltipContent = _this.onMouseOverTooltipContent.bind(_this); + _this.onMouseLeaveTooltipContent = _this.onMouseLeaveTooltipContent.bind(_this); + _this.show = _this.show.bind(_this); + _this.hide = _this.hide.bind(_this); + return _this; + } -/***/ }), -/* 86 */ -/***/ (function(module, exports, __webpack_require__) { + createClass(Tooltip, [{ + key: 'componentDidMount', + value: function componentDidMount() { + this._target = this.getTarget(); + this.addTargetEvents(); + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + this.removeTargetEvents(); + } + }, { + key: 'onMouseOverTooltip', + value: function onMouseOverTooltip() { + if (this._hideTimeout) { + this.clearHideTimeout(); + } + this._showTimeout = setTimeout(this.show, this.getDelay('show')); + } + }, { + key: 'onMouseLeaveTooltip', + value: function onMouseLeaveTooltip() { + if (this._showTimeout) { + this.clearShowTimeout(); + } + this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); + } + }, { + key: 'onMouseOverTooltipContent', + value: function onMouseOverTooltipContent() { + if (this.props.autohide) { + return; + } + if (this._hideTimeout) { + this.clearHideTimeout(); + } + } + }, { + key: 'onMouseLeaveTooltipContent', + value: function onMouseLeaveTooltipContent() { + if (this.props.autohide) { + return; + } + if (this._showTimeout) { + this.clearShowTimeout(); + } + this._hideTimeout = setTimeout(this.hide, this.getDelay('hide')); + } + }, { + key: 'getDelay', + value: function getDelay(key) { + var delay = this.props.delay; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { + return isNaN(delay[key]) ? DEFAULT_DELAYS[key] : delay[key]; + } + return delay; + } + }, { + key: 'getTarget', + value: function getTarget() { + var target = this.props.target; + if ((typeof target === 'undefined' ? 'undefined' : _typeof(target)) === 'object') { + return target; + } + return document.getElementById(target); + } + }, { + key: 'getTetherConfig', + value: function getTetherConfig() { + var attachments = getTetherAttachments(this.props.placement); + return _extends({}, defaultTetherConfig$2, attachments, { + target: this.getTarget + }, this.props.tether); + } + }, { + key: 'show', + value: function show() { + if (!this.props.isOpen) { + this.clearShowTimeout(); + this.toggle(); + } + } + }, { + key: 'hide', + value: function hide() { + if (this.props.isOpen) { + this.clearHideTimeout(); + this.toggle(); + } + } + }, { + key: 'clearShowTimeout', + value: function clearShowTimeout() { + clearTimeout(this._showTimeout); + this._showTimeout = undefined; + } + }, { + key: 'clearHideTimeout', + value: function clearHideTimeout() { + clearTimeout(this._hideTimeout); + this._hideTimeout = undefined; + } + }, { + key: 'handleDocumentClick', + value: function handleDocumentClick(e) { + if (e.target === this._target || this._target.contains(e.target)) { + if (this._hideTimeout) { + this.clearHideTimeout(); + } + if (!this.props.isOpen) { + this.toggle(); + } + } + } + }, { + key: 'addTargetEvents', + value: function addTargetEvents() { + this._target.addEventListener('mouseover', this.onMouseOverTooltip, true); + this._target.addEventListener('mouseout', this.onMouseLeaveTooltip, true); + document.addEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'removeTargetEvents', + value: function removeTargetEvents() { + this._target.removeEventListener('mouseover', this.onMouseOverTooltip, true); + this._target.removeEventListener('mouseout', this.onMouseLeaveTooltip, true); + document.removeEventListener('click', this.handleDocumentClick, true); + } + }, { + key: 'toggle', + value: function toggle(e) { + if (this.props.disabled) { + return e && e.preventDefault(); + } -var ReactFeatureFlags = { - // When true, call console.time() before and .timeEnd() after each top-level - // render (both initial renders and updates). Useful when looking at prod-mode - // timeline profiles in Chrome, for example. - logTopLevelRenders: false -}; + return this.props.toggle(); + } + }, { + key: 'render', + value: function render() { + if (!this.props.isOpen) { + return null; + } -module.exports = ReactFeatureFlags; + var attributes = omit(this.props, Object.keys(propTypes$44)); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tooltip-inner', this.props.className), this.props.cssModule); -/***/ }), -/* 87 */ -/***/ (function(module, exports, __webpack_require__) { + var tetherConfig = this.getTetherConfig(); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + TetherContent, + { + className: 'tooltip', + tether: tetherConfig, + tetherRef: this.props.tetherRef, + isOpen: this.props.isOpen, + toggle: this.toggle + }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement('div', _extends({}, attributes, { + className: classes, + onMouseOver: this.onMouseOverTooltipContent, + onMouseLeave: this.onMouseLeaveTooltipContent + })) + ); + } + }]); + return Tooltip; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); +Tooltip.propTypes = propTypes$44; +Tooltip.defaultProps = defaultProps$43; +var propTypes$45 = { + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + bordered: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + striped: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inverse: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + hover: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + reflow: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + responsive: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + responsiveTag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; -var ReactDOMComponentTree = __webpack_require__(6); +var defaultProps$44 = { + tag: 'table', + responsiveTag: 'div' +}; -function isCheckable(elem) { - var type = elem.type; - var nodeName = elem.nodeName; - return nodeName && nodeName.toLowerCase() === 'input' && (type === 'checkbox' || type === 'radio'); -} +var Table = function Table(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + bordered = props.bordered, + striped = props.striped, + inverse = props.inverse, + hover = props.hover, + reflow = props.reflow, + responsive = props.responsive, + Tag = props.tag, + ResponsiveTag = props.responsiveTag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'bordered', 'striped', 'inverse', 'hover', 'reflow', 'responsive', 'tag', 'responsiveTag']); -function getTracker(inst) { - return inst._wrapperState.valueTracker; -} -function attachTracker(inst, tracker) { - inst._wrapperState.valueTracker = tracker; -} + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'table', size ? 'table-' + size : false, bordered ? 'table-bordered' : false, striped ? 'table-striped' : false, inverse ? 'table-inverse' : false, hover ? 'table-hover' : false, reflow ? 'table-reflow' : false), cssModule); -function detachTracker(inst) { - delete inst._wrapperState.valueTracker; -} + var table = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); -function getValueFromNode(node) { - var value; - if (node) { - value = isCheckable(node) ? '' + node.checked : node.value; + if (responsive) { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + ResponsiveTag, + { className: 'table-responsive' }, + table + ); } - return value; -} - -var inputValueTracking = { - // exposed for testing - _getTrackerFromNode: function (node) { - return getTracker(ReactDOMComponentTree.getInstanceFromNode(node)); - }, - - - track: function (inst) { - if (getTracker(inst)) { - return; - } - - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var valueField = isCheckable(node) ? 'checked' : 'value'; - var descriptor = Object.getOwnPropertyDescriptor(node.constructor.prototype, valueField); - var currentValue = '' + node[valueField]; + return table; +}; - // if someone has already defined a value or Safari, then bail - // and don't track value will cause over reporting of changes, - // but it's better then a hard failure - // (needed for certain tests that spyOn input values and Safari) - if (node.hasOwnProperty(valueField) || typeof descriptor.get !== 'function' || typeof descriptor.set !== 'function') { - return; - } +Table.propTypes = propTypes$45; +Table.defaultProps = defaultProps$44; - Object.defineProperty(node, valueField, { - enumerable: descriptor.enumerable, - configurable: true, - get: function () { - return descriptor.get.call(this); - }, - set: function (value) { - currentValue = '' + value; - descriptor.set.call(this, value); - } - }); +var propTypes$46 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + flush: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; - attachTracker(inst, { - getValue: function () { - return currentValue; - }, - setValue: function (value) { - currentValue = '' + value; - }, - stopTracking: function () { - detachTracker(inst); - delete node[valueField]; - } - }); - }, +var defaultProps$45 = { + tag: 'ul' +}; - updateValueIfChanged: function (inst) { - if (!inst) { - return false; - } - var tracker = getTracker(inst); +var ListGroup = function ListGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + flush = props.flush, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'flush']); - if (!tracker) { - inputValueTracking.track(inst); - return true; - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group', flush ? 'list-group-flush' : false), cssModule); - var lastValue = tracker.getValue(); - var nextValue = getValueFromNode(ReactDOMComponentTree.getNodeFromInstance(inst)); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - if (nextValue !== lastValue) { - tracker.setValue(nextValue); - return true; - } +ListGroup.propTypes = propTypes$46; +ListGroup.defaultProps = defaultProps$45; - return false; - }, - stopTracking: function (inst) { - var tracker = getTracker(inst); - if (tracker) { - tracker.stopTracking(); - } - } +var propTypes$47 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -module.exports = inputValueTracking; +var defaultProps$46 = { + tag: 'form' +}; -/***/ }), -/* 88 */ -/***/ (function(module, exports, __webpack_require__) { +var Form = function Form(props) { + var className = props.className, + cssModule = props.cssModule, + inline = props.inline, + Tag = props.tag, + getRef = props.getRef, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'tag', 'getRef']); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, inline ? 'form-inline' : false), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); +}; -/** - * @see http://www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#input-type-attr-summary - */ +Form.propTypes = propTypes$47; +Form.defaultProps = defaultProps$46; -var supportedInputTypes = { - color: true, - date: true, - datetime: true, - 'datetime-local': true, - email: true, - month: true, - number: true, - password: true, - range: true, - search: true, - tel: true, - text: true, - time: true, - url: true, - week: true +var propTypes$48 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -function isTextInputElement(elem) { - var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); +var defaultProps$47 = { + tag: 'div' +}; - if (nodeName === 'input') { - return !!supportedInputTypes[elem.type]; - } +var FormFeedback = function FormFeedback(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); - if (nodeName === 'textarea') { - return true; - } - return false; -} + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'form-control-feedback'), cssModule); -module.exports = isTextInputElement; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -/***/ }), -/* 89 */ -/***/ (function(module, exports, __webpack_require__) { +FormFeedback.propTypes = propTypes$48; +FormFeedback.defaultProps = defaultProps$47; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var propTypes$49 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + row: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; +var defaultProps$48 = { + tag: 'div' +}; +var FormGroup = function FormGroup(props) { + var className = props.className, + cssModule = props.cssModule, + row = props.row, + disabled = props.disabled, + color = props.color, + check = props.check, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'row', 'disabled', 'color', 'check', 'tag']); -var ViewportMetrics = { - currentScrollLeft: 0, - currentScrollTop: 0, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, color ? 'has-' + color : false, row ? 'row' : false, check ? 'form-check' : 'form-group', check && disabled ? 'disabled' : false), cssModule); - refreshScrollValues: function (scrollPosition) { - ViewportMetrics.currentScrollLeft = scrollPosition.x; - ViewportMetrics.currentScrollTop = scrollPosition.y; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -module.exports = ViewportMetrics; - -/***/ }), -/* 90 */ -/***/ (function(module, exports, __webpack_require__) { +FormGroup.propTypes = propTypes$49; +FormGroup.defaultProps = defaultProps$48; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var propTypes$50 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; +var defaultProps$49 = { + tag: 'small' +}; +var FormText = function FormText(props) { + var className = props.className, + cssModule = props.cssModule, + inline = props.inline, + color = props.color, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'inline', 'color', 'tag']); -var ExecutionEnvironment = __webpack_require__(8); -var escapeTextContentForBrowser = __webpack_require__(44); -var setInnerHTML = __webpack_require__(43); -/** - * Set the textContent property of a node, ensuring that whitespace is preserved - * even in IE8. innerText is a poor substitute for textContent and, among many - * issues, inserts <br> instead of the literal newline chars. innerHTML behaves - * as it should. - * - * @param {DOMElement} node - * @param {string} text - * @internal - */ -var setTextContent = function (node, text) { - if (text) { - var firstChild = node.firstChild; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, !inline ? 'form-text' : false, color ? 'text-' + color : false), cssModule); - if (firstChild && firstChild === node.lastChild && firstChild.nodeType === 3) { - firstChild.nodeValue = text; - return; - } - } - node.textContent = text; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -if (ExecutionEnvironment.canUseDOM) { - if (!('textContent' in document.documentElement)) { - setTextContent = function (node, text) { - if (node.nodeType === 3) { - node.nodeValue = text; - return; - } - setInnerHTML(node, escapeTextContentForBrowser(text)); - }; - } -} +FormText.propTypes = propTypes$50; +FormText.defaultProps = defaultProps$49; -module.exports = setTextContent; +/* eslint react/prefer-stateless-function: 0 */ -/***/ }), -/* 91 */ -/***/ (function(module, exports, __webpack_require__) { +var propTypes$51 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + type: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + state: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + getRef: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + static: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + addon: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var defaultProps$50 = { + tag: 'p', + type: 'text' +}; +var Input = function (_React$Component) { + inherits(Input, _React$Component); + function Input() { + classCallCheck(this, Input); + return possibleConstructorReturn(this, (Input.__proto__ || Object.getPrototypeOf(Input)).apply(this, arguments)); + } -/** - * @param {DOMElement} node input/textarea to focus - */ + createClass(Input, [{ + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + type = _props.type, + size = _props.size, + state = _props.state, + tag = _props.tag, + addon = _props.addon, + staticInput = _props.static, + getRef = _props.getRef, + attributes = objectWithoutProperties(_props, ['className', 'cssModule', 'type', 'size', 'state', 'tag', 'addon', 'static', 'getRef']); -function focusNode(node) { - // IE8 can throw "Can't move focus to the control because it is invisible, - // not enabled, or of a type that does not accept the focus." for all kinds of - // reasons that are too expensive and fragile to test. - try { - node.focus(); - } catch (e) {} -} -module.exports = focusNode; + var checkInput = ['radio', 'checkbox'].indexOf(type) > -1; -/***/ }), -/* 92 */ -/***/ (function(module, exports, __webpack_require__) { + var fileInput = type === 'file'; + var textareaInput = type === 'textarea'; + var selectInput = type === 'select'; + var Tag = selectInput || textareaInput ? type : 'input'; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var formControlClass = 'form-control'; + if (staticInput) { + formControlClass = formControlClass + '-static'; + Tag = tag; + } else if (fileInput) { + formControlClass = formControlClass + '-file'; + } else if (checkInput) { + if (addon) { + formControlClass = null; + } else { + formControlClass = 'form-check-input'; + } + } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, state ? 'form-control-' + state : false, size ? 'form-control-' + size : false, formControlClass), cssModule); -/** - * CSS properties which accept numbers but are not in units of "px". - */ + if (Tag === 'input') { + attributes.type = type; + } -var isUnitlessNumber = { - animationIterationCount: true, - borderImageOutset: true, - borderImageSlice: true, - borderImageWidth: true, - boxFlex: true, - boxFlexGroup: true, - boxOrdinalGroup: true, - columnCount: true, - flex: true, - flexGrow: true, - flexPositive: true, - flexShrink: true, - flexNegative: true, - flexOrder: true, - gridRow: true, - gridRowEnd: true, - gridRowSpan: true, - gridRowStart: true, - gridColumn: true, - gridColumnEnd: true, - gridColumnSpan: true, - gridColumnStart: true, - fontWeight: true, - lineClamp: true, - lineHeight: true, - opacity: true, - order: true, - orphans: true, - tabSize: true, - widows: true, - zIndex: true, - zoom: true, + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { ref: getRef, className: classes })); + } + }]); + return Input; +}(__WEBPACK_IMPORTED_MODULE_0_react___default.a.Component); - // SVG-related properties - fillOpacity: true, - floodOpacity: true, - stopOpacity: true, - strokeDasharray: true, - strokeDashoffset: true, - strokeMiterlimit: true, - strokeOpacity: true, - strokeWidth: true +Input.propTypes = propTypes$51; +Input.defaultProps = defaultProps$50; + +var propTypes$52 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -/** - * @param {string} prefix vendor-specific prefix, eg: Webkit - * @param {string} key style name, eg: transitionDuration - * @return {string} style name prefixed with `prefix`, properly camelCased, eg: - * WebkitTransitionDuration - */ -function prefixKey(prefix, key) { - return prefix + key.charAt(0).toUpperCase() + key.substring(1); -} +var defaultProps$51 = { + tag: 'div' +}; -/** - * Support style names that may come passed in prefixed by adding permutations - * of vendor prefixes. - */ -var prefixes = ['Webkit', 'ms', 'Moz', 'O']; +var InputGroup = function InputGroup(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + size = props.size, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'size']); -// Using Object.keys here, or else the vanilla for-in loop makes IE8 go into an -// infinite loop, because it iterates over the newly added props too. -Object.keys(isUnitlessNumber).forEach(function (prop) { - prefixes.forEach(function (prefix) { - isUnitlessNumber[prefixKey(prefix, prop)] = isUnitlessNumber[prop]; - }); -}); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group', size ? 'input-group-' + size : null), cssModule); -/** - * Most style properties can be unset by doing .style[prop] = '' but IE8 - * doesn't like doing that with shorthand properties so for the properties that - * IE8 breaks on, which are listed here, we instead unset each of the - * individual properties. See http://bugs.jquery.com/ticket/12385. - * The 4-value 'clock' properties like margin, padding, border-width seem to - * behave without any problems. Curiously, list-style works too without any - * special prodding. - */ -var shorthandPropertyExpansions = { - background: { - backgroundAttachment: true, - backgroundColor: true, - backgroundImage: true, - backgroundPositionX: true, - backgroundPositionY: true, - backgroundRepeat: true - }, - backgroundPosition: { - backgroundPositionX: true, - backgroundPositionY: true - }, - border: { - borderWidth: true, - borderStyle: true, - borderColor: true - }, - borderBottom: { - borderBottomWidth: true, - borderBottomStyle: true, - borderBottomColor: true - }, - borderLeft: { - borderLeftWidth: true, - borderLeftStyle: true, - borderLeftColor: true - }, - borderRight: { - borderRightWidth: true, - borderRightStyle: true, - borderRightColor: true - }, - borderTop: { - borderTopWidth: true, - borderTopStyle: true, - borderTopColor: true - }, - font: { - fontStyle: true, - fontVariant: true, - fontWeight: true, - fontSize: true, - lineHeight: true, - fontFamily: true - }, - outline: { - outlineWidth: true, - outlineStyle: true, - outlineColor: true - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); }; -var CSSProperty = { - isUnitlessNumber: isUnitlessNumber, - shorthandPropertyExpansions: shorthandPropertyExpansions +InputGroup.propTypes = propTypes$52; +InputGroup.defaultProps = defaultProps$51; + +var propTypes$53 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -module.exports = CSSProperty; +var defaultProps$52 = { + tag: 'div' +}; -/***/ }), -/* 93 */ -/***/ (function(module, exports, __webpack_require__) { +var InputGroupAddon = function InputGroupAddon(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag']); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-addon'), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +InputGroupAddon.propTypes = propTypes$53; +InputGroupAddon.defaultProps = defaultProps$52; -var DOMProperty = __webpack_require__(17); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstrumentation = __webpack_require__(13); +var propTypes$54 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + groupClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + groupAttributes: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; -var quoteAttributeValueForBrowser = __webpack_require__(168); -var warning = __webpack_require__(2); +var defaultProps$53 = { + tag: 'div' +}; -var VALID_ATTRIBUTE_NAME_REGEX = new RegExp('^[' + DOMProperty.ATTRIBUTE_NAME_START_CHAR + '][' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); -var illegalAttributeNameCache = {}; -var validatedAttributeNameCache = {}; +var InputGroupButton = function InputGroupButton(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + children = props.children, + groupClassName = props.groupClassName, + groupAttributes = props.groupAttributes, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'children', 'groupClassName', 'groupAttributes']); -function isAttributeNameSafe(attributeName) { - if (validatedAttributeNameCache.hasOwnProperty(attributeName)) { - return true; - } - if (illegalAttributeNameCache.hasOwnProperty(attributeName)) { - return false; - } - if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) { - validatedAttributeNameCache[attributeName] = true; - return true; + + if (typeof children === 'string') { + var groupClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(groupClassName, 'input-group-btn'), cssModule); + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, groupAttributes, { className: groupClasses }), + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Button, _extends({}, attributes, { className: className, children: children })) + ); } - illegalAttributeNameCache[attributeName] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid attribute name: `%s`', attributeName) : void 0; - return false; -} -function shouldIgnoreValue(propertyInfo, value) { - return value == null || propertyInfo.hasBooleanValue && !value || propertyInfo.hasNumericValue && isNaN(value) || propertyInfo.hasPositiveNumericValue && value < 1 || propertyInfo.hasOverloadedBooleanValue && value === false; -} + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'input-group-btn'), cssModule); -/** - * Operations for dealing with DOM properties. - */ -var DOMPropertyOperations = { - /** - * Creates markup for the ID property. - * - * @param {string} id Unescaped ID. - * @return {string} Markup string. - */ - createMarkupForID: function (id) { - return DOMProperty.ID_ATTRIBUTE_NAME + '=' + quoteAttributeValueForBrowser(id); - }, + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes, children: children })); +}; - setAttributeForID: function (node, id) { - node.setAttribute(DOMProperty.ID_ATTRIBUTE_NAME, id); - }, +InputGroupButton.propTypes = propTypes$54; +InputGroupButton.defaultProps = defaultProps$53; - createMarkupForRoot: function () { - return DOMProperty.ROOT_ATTRIBUTE_NAME + '=""'; - }, +var colSizes = ['xs', 'sm', 'md', 'lg', 'xl']; - setAttributeForRoot: function (node) { - node.setAttribute(DOMProperty.ROOT_ATTRIBUTE_NAME, ''); - }, +var stringOrNumberProp$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]); - /** - * Creates markup for a property. - * - * @param {string} name - * @param {*} value - * @return {?string} Markup string, or null if the property was invalid. - */ - createMarkupForProperty: function (name, value) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - if (shouldIgnoreValue(propertyInfo, value)) { - return ''; - } - var attributeName = propertyInfo.attributeName; - if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { - return attributeName + '=""'; - } - return attributeName + '=' + quoteAttributeValueForBrowser(value); - } else if (DOMProperty.isCustomAttribute(name)) { - if (value == null) { - return ''; - } - return name + '=' + quoteAttributeValueForBrowser(value); - } - return null; - }, +var columnProps$1 = __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ + size: stringOrNumberProp$1, + push: stringOrNumberProp$1, + pull: stringOrNumberProp$1, + offset: stringOrNumberProp$1 +})]); - /** - * Creates markup for a custom property. - * - * @param {string} name - * @param {*} value - * @return {string} Markup string, or empty string if the property was invalid. - */ - createMarkupForCustomAttribute: function (name, value) { - if (!isAttributeNameSafe(name) || value == null) { - return ''; - } - return name + '=' + quoteAttributeValueForBrowser(value); - }, +var propTypes$55 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + hidden: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + check: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + inline: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + for: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + xs: columnProps$1, + sm: columnProps$1, + md: columnProps$1, + lg: columnProps$1, + xl: columnProps$1 +}; - /** - * Sets the value for a property on a node. - * - * @param {DOMElement} node - * @param {string} name - * @param {*} value - */ - setValueForProperty: function (node, name, value) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - var mutationMethod = propertyInfo.mutationMethod; - if (mutationMethod) { - mutationMethod(node, value); - } else if (shouldIgnoreValue(propertyInfo, value)) { - this.deleteValueForProperty(node, name); - return; - } else if (propertyInfo.mustUseProperty) { - // Contrary to `setAttribute`, object properties are properly - // `toString`ed by IE8/9. - node[propertyInfo.propertyName] = value; - } else { - var attributeName = propertyInfo.attributeName; - var namespace = propertyInfo.attributeNamespace; - // `setAttribute` with objects becomes only `[object]` in IE8/9, - // ('' + value) makes it output the correct toString()-value. - if (namespace) { - node.setAttributeNS(namespace, attributeName, '' + value); - } else if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { - node.setAttribute(attributeName, ''); - } else { - node.setAttribute(attributeName, '' + value); - } - } - } else if (DOMProperty.isCustomAttribute(name)) { - DOMPropertyOperations.setValueForAttribute(node, name, value); - return; - } +var defaultProps$54 = { + tag: 'label' +}; - if (process.env.NODE_ENV !== 'production') { - var payload = {}; - payload[name] = value; - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'update attribute', - payload: payload - }); - } - }, +var Label = function Label(props) { + var className = props.className, + cssModule = props.cssModule, + hidden = props.hidden, + Tag = props.tag, + check = props.check, + inline = props.inline, + disabled = props.disabled, + size = props.size, + htmlFor = props.for, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'hidden', 'tag', 'check', 'inline', 'disabled', 'size', 'for']); - setValueForAttribute: function (node, name, value) { - if (!isAttributeNameSafe(name)) { - return; - } - if (value == null) { - node.removeAttribute(name); - } else { - node.setAttribute(name, '' + value); - } - if (process.env.NODE_ENV !== 'production') { - var payload = {}; - payload[name] = value; - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'update attribute', - payload: payload - }); - } - }, + var colClasses = []; - /** - * Deletes an attributes from a node. - * - * @param {DOMElement} node - * @param {string} name - */ - deleteValueForAttribute: function (node, name) { - node.removeAttribute(name); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'remove attribute', - payload: name - }); - } - }, + colSizes.forEach(function (colSize) { + var columnProp = props[colSize]; + delete attributes[colSize]; - /** - * Deletes the value for a property on a node. - * - * @param {DOMElement} node - * @param {string} name - */ - deleteValueForProperty: function (node, name) { - var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; - if (propertyInfo) { - var mutationMethod = propertyInfo.mutationMethod; - if (mutationMethod) { - mutationMethod(node, undefined); - } else if (propertyInfo.mustUseProperty) { - var propName = propertyInfo.propertyName; - if (propertyInfo.hasBooleanValue) { - node[propName] = false; - } else { - node[propName] = ''; - } - } else { - node.removeAttribute(propertyInfo.attributeName); - } - } else if (DOMProperty.isCustomAttribute(name)) { - node.removeAttribute(name); - } + if (columnProp && columnProp.size) { + var _classNames; - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, - type: 'remove attribute', - payload: name - }); + colClasses.push(mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()((_classNames = {}, defineProperty(_classNames, 'col-' + colSize + '-' + columnProp.size, columnProp.size), defineProperty(_classNames, 'push-' + colSize + '-' + columnProp.push, columnProp.push), defineProperty(_classNames, 'pull-' + colSize + '-' + columnProp.pull, columnProp.pull), defineProperty(_classNames, 'offset-' + colSize + '-' + columnProp.offset, columnProp.offset), _classNames))), cssModule); + } else if (columnProp) { + colClasses.push('col-' + colSize + '-' + columnProp); } - } -}; - -module.exports = DOMPropertyOperations; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 94 */ -/***/ (function(module, exports, __webpack_require__) { + }); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, hidden ? 'sr-only' : false, check ? 'form-check-' + (inline ? 'inline' : 'label') : false, check && inline && disabled ? 'disabled' : false, size ? 'col-form-label-' + size : false, colClasses, colClasses.length ? 'col-form-label' : false, !check && !colClasses.length ? 'form-control-label' : false), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ htmlFor: htmlFor }, attributes, { className: classes })); +}; +Label.propTypes = propTypes$55; +Label.defaultProps = defaultProps$54; -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; +var propTypes$56 = { + body: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + bottom: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + heading: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + left: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + list: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + middle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + object: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + right: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + top: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool +}; -module.exports = ReactPropTypesSecret; +var Media = function Media(props) { + var body = props.body, + bottom = props.bottom, + className = props.className, + cssModule = props.cssModule, + heading = props.heading, + left = props.left, + list = props.list, + middle = props.middle, + object = props.object, + right = props.right, + tag = props.tag, + top = props.top, + attributes = objectWithoutProperties(props, ['body', 'bottom', 'className', 'cssModule', 'heading', 'left', 'list', 'middle', 'object', 'right', 'tag', 'top']); -/***/ }), -/* 95 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var defaultTag = void 0; + if (heading) { + defaultTag = 'h4'; + } else if (left || right) { + defaultTag = 'a'; + } else if (object) { + defaultTag = 'img'; + } else if (list) { + defaultTag = 'ul'; + } else { + defaultTag = 'div'; + } + var Tag = tag || defaultTag; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, { + 'media-body': body, + 'media-heading': heading, + 'media-left': left, + 'media-right': right, + 'media-top': top, + 'media-bottom': bottom, + 'media-middle': middle, + 'media-object': object, + 'media-list': list, + media: !body && !heading && !left && !right && !top && !bottom && !middle && !object && !list + }), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var _assign = __webpack_require__(5); +Media.propTypes = propTypes$56; -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); +var propTypes$57 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + size: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; -var warning = __webpack_require__(2); +var defaultProps$55 = { + tag: 'ul' +}; -var didWarnValueLink = false; -var didWarnValueDefaultValue = false; +var Pagination = function Pagination(props) { + var className = props.className, + cssModule = props.cssModule, + size = props.size, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'size', 'tag']); -function updateOptionsIfPendingUpdateAndMounted() { - if (this._rootNodeID && this._wrapperState.pendingUpdate) { - this._wrapperState.pendingUpdate = false; - var props = this._currentElement.props; - var value = LinkedValueUtils.getValue(props); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'pagination', defineProperty({}, 'pagination-' + size, !!size)), cssModule); - if (value != null) { - updateOptions(this, Boolean(props.multiple), value); - } - } -} + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; -} +Pagination.propTypes = propTypes$57; +Pagination.defaultProps = defaultProps$55; -var valuePropNames = ['value', 'defaultValue']; +var propTypes$58 = { + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; -/** - * Validation function for `value` and `defaultValue`. - * @private - */ -function checkSelectPropTypes(inst, props) { - var owner = inst._currentElement._owner; - LinkedValueUtils.checkPropTypes('select', props, owner); +var defaultProps$56 = { + tag: 'li' +}; - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `select` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } +var PaginationItem = function PaginationItem(props) { + var active = props.active, + className = props.className, + cssModule = props.cssModule, + disabled = props.disabled, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['active', 'className', 'cssModule', 'disabled', 'tag']); - for (var i = 0; i < valuePropNames.length; i++) { - var propName = valuePropNames[i]; - if (props[propName] == null) { - continue; - } - var isArray = Array.isArray(props[propName]); - if (props.multiple && !isArray) { - process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be an array if ' + '`multiple` is true.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; - } else if (!props.multiple && isArray) { - process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be a scalar ' + 'value if `multiple` is false.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; - } - } -} -/** - * @param {ReactDOMComponent} inst - * @param {boolean} multiple - * @param {*} propValue A stringable (with `multiple`, a list of stringables). - * @private - */ -function updateOptions(inst, multiple, propValue) { - var selectedValue, i; - var options = ReactDOMComponentTree.getNodeFromInstance(inst).options; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-item', { + active: active, + disabled: disabled + }), cssModule); - if (multiple) { - selectedValue = {}; - for (i = 0; i < propValue.length; i++) { - selectedValue['' + propValue[i]] = true; - } - for (i = 0; i < options.length; i++) { - var selected = selectedValue.hasOwnProperty(options[i].value); - if (options[i].selected !== selected) { - options[i].selected = selected; - } - } - } else { - // Do not set `select.value` as exact behavior isn't consistent across all - // browsers for all cases. - selectedValue = '' + propValue; - for (i = 0; i < options.length; i++) { - if (options[i].value === selectedValue) { - options[i].selected = true; - return; - } - } - if (options.length) { - options[0].selected = true; - } - } -} + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -/** - * Implements a <select> host component that allows optionally setting the - * props `value` and `defaultValue`. If `multiple` is false, the prop must be a - * stringable. If `multiple` is true, the prop must be an array of stringables. - * - * If `value` is not supplied (or null/undefined), user actions that change the - * selected option will trigger updates to the rendered options. - * - * If it is supplied (and not null/undefined), the rendered options will not - * update in response to user actions. Instead, the `value` prop must change in - * order for the rendered options to update. - * - * If `defaultValue` is provided, any options with the supplied values will be - * selected. - */ -var ReactDOMSelect = { - getHostProps: function (inst, props) { - return _assign({}, props, { - onChange: inst._wrapperState.onChange, - value: undefined - }); - }, +PaginationItem.propTypes = propTypes$58; +PaginationItem.defaultProps = defaultProps$56; - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - checkSelectPropTypes(inst, props); - } +var propTypes$59 = { + 'aria-label': __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + next: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + previous: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]) +}; - var value = LinkedValueUtils.getValue(props); - inst._wrapperState = { - pendingUpdate: false, - initialValue: value != null ? value : props.defaultValue, - listeners: null, - onChange: _handleChange.bind(inst), - wasMultiple: Boolean(props.multiple) - }; +var defaultProps$57 = { + tag: 'a' +}; - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Select elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; - didWarnValueDefaultValue = true; - } - }, +var PaginationLink = function PaginationLink(props) { + var className = props.className, + cssModule = props.cssModule, + next = props.next, + previous = props.previous, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'next', 'previous', 'tag']); - getSelectValueContext: function (inst) { - // ReactDOMOption looks at this initial value so the initial generated - // markup has correct `selected` attributes - return inst._wrapperState.initialValue; - }, - postUpdateWrapper: function (inst) { - var props = inst._currentElement.props; + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'page-link'), cssModule); - // After the initial mount, we control selected-ness manually so don't pass - // this value down - inst._wrapperState.initialValue = undefined; + var defaultAriaLabel = void 0; + if (previous) { + defaultAriaLabel = 'Previous'; + } else if (next) { + defaultAriaLabel = 'Next'; + } + var ariaLabel = props['aria-label'] || defaultAriaLabel; - var wasMultiple = inst._wrapperState.wasMultiple; - inst._wrapperState.wasMultiple = Boolean(props.multiple); + var defaultCaret = void 0; + if (previous) { + defaultCaret = '\xAB'; + } else if (next) { + defaultCaret = '\xBB'; + } - var value = LinkedValueUtils.getValue(props); - if (value != null) { - inst._wrapperState.pendingUpdate = false; - updateOptions(inst, Boolean(props.multiple), value); - } else if (wasMultiple !== Boolean(props.multiple)) { - // For simplicity, reapply `defaultValue` if `multiple` is toggled. - if (props.defaultValue != null) { - updateOptions(inst, Boolean(props.multiple), props.defaultValue); - } else { - // Revert the select back to its default unselected state. - updateOptions(inst, Boolean(props.multiple), props.multiple ? [] : ''); - } - } + var children = props.children; + if (previous || next) { + children = [__WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { + 'aria-hidden': 'true', + key: 'caret' + }, + children || defaultCaret + ), __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { + className: 'sr-only', + key: 'sr' + }, + ariaLabel + )]; } + + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { + className: classes, + 'aria-label': ariaLabel + }), + children + ); }; -function _handleChange(event) { - var props = this._currentElement.props; - var returnValue = LinkedValueUtils.executeOnChange(props, event); - - if (this._rootNodeID) { - this._wrapperState.pendingUpdate = true; - } - ReactUpdates.asap(updateOptionsIfPendingUpdateAndMounted, this); - return returnValue; -} - -module.exports = ReactDOMSelect; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 96 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +PaginationLink.propTypes = propTypes$59; +PaginationLink.defaultProps = defaultProps$57; +var propTypes$60 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + activeTab: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object +}; +var defaultProps$58 = { + tag: 'div' +}; -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +var childContextTypes$1 = { + activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -var ReactCompositeComponent = __webpack_require__(176); -var ReactEmptyComponent = __webpack_require__(98); -var ReactHostComponent = __webpack_require__(99); +var TabContent = function (_Component) { + inherits(TabContent, _Component); -var getNextDebugID = __webpack_require__(179); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); + function TabContent(props) { + classCallCheck(this, TabContent); -// To avoid a cyclic dependency, we create the final class in this module -var ReactCompositeComponentWrapper = function (element) { - this.construct(element); -}; + var _this = possibleConstructorReturn(this, (TabContent.__proto__ || Object.getPrototypeOf(TabContent)).call(this, props)); -function getDeclarationErrorAddendum(owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } + _this.state = { + activeTab: _this.props.activeTab + }; + return _this; } - return ''; -} - -/** - * Check if the type reference is a known internal type. I.e. not a user - * provided composite type. - * - * @param {function} type - * @return {boolean} Returns true if this is a valid internal type. - */ -function isInternalComponentType(type) { - return typeof type === 'function' && typeof type.prototype !== 'undefined' && typeof type.prototype.mountComponent === 'function' && typeof type.prototype.receiveComponent === 'function'; -} - -/** - * Given a ReactNode, create an instance that will actually be mounted. - * - * @param {ReactNode} node - * @param {boolean} shouldHaveDebugID - * @return {object} A new instance of the element's constructor. - * @protected - */ -function instantiateReactComponent(node, shouldHaveDebugID) { - var instance; - if (node === null || node === false) { - instance = ReactEmptyComponent.create(instantiateReactComponent); - } else if (typeof node === 'object') { - var element = node; - var type = element.type; - if (typeof type !== 'function' && typeof type !== 'string') { - var info = ''; - if (process.env.NODE_ENV !== 'production') { - if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { - info += ' You likely forgot to export your component from the file ' + "it's defined in."; - } - } - info += getDeclarationErrorAddendum(element._owner); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s', type == null ? type : typeof type, info) : _prodInvariant('130', type == null ? type : typeof type, info) : void 0; + createClass(TabContent, [{ + key: 'getChildContext', + value: function getChildContext() { + return { + activeTabId: this.state.activeTab + }; } - - // Special case string values - if (typeof element.type === 'string') { - instance = ReactHostComponent.createInternalComponent(element); - } else if (isInternalComponentType(element.type)) { - // This is temporarily available for custom components that are not string - // representations. I.e. ART. Once those are updated to use the string - // representation, we can drop this code path. - instance = new element.type(element); - - // We renamed this. Allow the old name for compat. :( - if (!instance.getHostNode) { - instance.getHostNode = instance.getNativeNode; + }, { + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + if (this.state.activeTab !== nextProps.activeTab) { + this.setState({ + activeTab: nextProps.activeTab + }); } - } else { - instance = new ReactCompositeComponentWrapper(element); } - } else if (typeof node === 'string' || typeof node === 'number') { - instance = ReactHostComponent.createInstanceForText(node); - } else { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Encountered invalid React node of type %s', typeof node) : _prodInvariant('131', typeof node) : void 0; - } + }, { + key: 'render', + value: function render() { + var _props = this.props, + className = _props.className, + cssModule = _props.cssModule, + Tag = _props.tag; - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(typeof instance.mountComponent === 'function' && typeof instance.receiveComponent === 'function' && typeof instance.getHostNode === 'function' && typeof instance.unmountComponent === 'function', 'Only React Components can be mounted.') : void 0; - } - // These two fields are used by the DOM and ART diffing algorithms - // respectively. Instead of using expandos on components, we should be - // storing the state needed by the diffing algorithms elsewhere. - instance._mountIndex = 0; - instance._mountImage = null; + var attributes = omit(this.props, Object.keys(propTypes$60)); - if (process.env.NODE_ENV !== 'production') { - instance._debugID = shouldHaveDebugID ? getNextDebugID() : 0; - } + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-content', className), cssModule); - // Internal instances should fully constructed at this point, so they should - // not get any new fields added to them at this point. - if (process.env.NODE_ENV !== 'production') { - if (Object.preventExtensions) { - Object.preventExtensions(instance); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); } - } - - return instance; -} - -_assign(ReactCompositeComponentWrapper.prototype, ReactCompositeComponent, { - _instantiateReactComponent: instantiateReactComponent -}); - -module.exports = instantiateReactComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 97 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + }]); + return TabContent; +}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); +TabContent.propTypes = propTypes$60; +TabContent.defaultProps = defaultProps$58; +TabContent.childContextTypes = childContextTypes$1; +var propTypes$61 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + tabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -var _prodInvariant = __webpack_require__(3); +var defaultProps$59 = { + tag: 'div' +}; -var React = __webpack_require__(24); +var contextTypes$3 = { + activeTabId: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -var invariant = __webpack_require__(1); +function TabPane(props, context) { + var className = props.className, + cssModule = props.cssModule, + tabId = props.tabId, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tabId', 'tag']); -var ReactNodeTypes = { - HOST: 0, - COMPOSITE: 1, - EMPTY: 2, + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('tab-pane', className, { active: tabId === context.activeTabId }), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +} +TabPane.propTypes = propTypes$61; +TabPane.defaultProps = defaultProps$59; +TabPane.contextTypes = contextTypes$3; - getType: function (node) { - if (node === null || node === false) { - return ReactNodeTypes.EMPTY; - } else if (React.isValidElement(node)) { - if (typeof node.type === 'function') { - return ReactNodeTypes.COMPOSITE; - } else { - return ReactNodeTypes.HOST; - } - } - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unexpected node: %s', node) : _prodInvariant('26', node) : void 0; - } +var propTypes$62 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + fluid: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object }; -module.exports = ReactNodeTypes; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var defaultProps$60 = { + tag: 'div' +}; -/***/ }), -/* 98 */ -/***/ (function(module, exports, __webpack_require__) { +var Jumbotron = function Jumbotron(props) { + var className = props.className, + cssModule = props.cssModule, + Tag = props.tag, + fluid = props.fluid, + attributes = objectWithoutProperties(props, ['className', 'cssModule', 'tag', 'fluid']); -"use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'jumbotron', fluid ? 'jumbotron-fluid' : false), cssModule); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -var emptyComponentFactory; +Jumbotron.propTypes = propTypes$62; +Jumbotron.defaultProps = defaultProps$60; -var ReactEmptyComponentInjection = { - injectEmptyComponentFactory: function (factory) { - emptyComponentFactory = factory; - } +var FirstChild = function FirstChild(_ref) { + var children = _ref.children; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.toArray(children)[0] || null; }; -var ReactEmptyComponent = { - create: function (instantiate) { - return emptyComponentFactory(instantiate); - } +var propTypes$63 = { + children: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + closeClassName: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + toggle: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + transitionAppearTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionEnterTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, + transitionLeaveTimeout: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }; -ReactEmptyComponent.injection = ReactEmptyComponentInjection; - -module.exports = ReactEmptyComponent; - -/***/ }), -/* 99 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var defaultProps$61 = { + color: 'success', + isOpen: true, + tag: 'div', + transitionAppearTimeout: 150, + transitionEnterTimeout: 150, + transitionLeaveTimeout: 150 +}; +var Alert = function Alert(props) { + var className = props.className, + closeClassName = props.closeClassName, + cssModule = props.cssModule, + Tag = props.tag, + color = props.color, + isOpen = props.isOpen, + toggle = props.toggle, + children = props.children, + transitionAppearTimeout = props.transitionAppearTimeout, + transitionEnterTimeout = props.transitionEnterTimeout, + transitionLeaveTimeout = props.transitionLeaveTimeout, + attributes = objectWithoutProperties(props, ['className', 'closeClassName', 'cssModule', 'tag', 'color', 'isOpen', 'toggle', 'children', 'transitionAppearTimeout', 'transitionEnterTimeout', 'transitionLeaveTimeout']); -var _prodInvariant = __webpack_require__(3); + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'alert', 'alert-' + color, { 'alert-dismissible': toggle }), cssModule); -var invariant = __webpack_require__(1); + var closeClasses = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()('close', closeClassName), cssModule); -var genericComponentClass = null; -var textComponentClass = null; + var alert = __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + Tag, + _extends({}, attributes, { className: classes, role: 'alert' }), + toggle ? __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'button', + { type: 'button', className: closeClasses, 'aria-label': 'Close', onClick: toggle }, + __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + 'span', + { 'aria-hidden': 'true' }, + '\xD7' + ) + ) : null, + children + ); -var ReactHostComponentInjection = { - // This accepts a class that receives the tag string. This is a catch all - // that can render any kind of tag. - injectGenericComponentClass: function (componentClass) { - genericComponentClass = componentClass; - }, - // This accepts a text component class that takes the text string to be - // rendered as props. - injectTextComponentClass: function (componentClass) { - textComponentClass = componentClass; - } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement( + __WEBPACK_IMPORTED_MODULE_8_react_transition_group__["CSSTransitionGroup"], + { + component: FirstChild, + transitionName: { + appear: 'fade', + appearActive: 'show', + enter: 'fade', + enterActive: 'show', + leave: 'fade', + leaveActive: 'out' + }, + transitionAppear: transitionAppearTimeout > 0, + transitionAppearTimeout: transitionAppearTimeout, + transitionEnter: transitionEnterTimeout > 0, + transitionEnterTimeout: transitionEnterTimeout, + transitionLeave: transitionLeaveTimeout > 0, + transitionLeaveTimeout: transitionLeaveTimeout + }, + isOpen ? alert : null + ); }; -/** - * Get a host internal component class for a specific tag. - * - * @param {ReactElement} element The element to create. - * @return {function} The internal class constructor function. - */ -function createInternalComponent(element) { - !genericComponentClass ? process.env.NODE_ENV !== 'production' ? invariant(false, 'There is no registered component for the tag %s', element.type) : _prodInvariant('111', element.type) : void 0; - return new genericComponentClass(element); -} - -/** - * @param {ReactText} text - * @return {ReactComponent} - */ -function createInstanceForText(text) { - return new textComponentClass(text); -} +Alert.propTypes = propTypes$63; +Alert.defaultProps = defaultProps$61; -/** - * @param {ReactComponent} component - * @return {boolean} - */ -function isTextComponent(component) { - return component instanceof textComponentClass; -} +var SHOW = 'SHOW'; +var SHOWN = 'SHOWN'; +var HIDE = 'HIDE'; +var HIDDEN = 'HIDDEN'; -var ReactHostComponent = { - createInternalComponent: createInternalComponent, - createInstanceForText: createInstanceForText, - isTextComponent: isTextComponent, - injection: ReactHostComponentInjection +var propTypes$64 = { + isOpen: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.node, + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + cssModule: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.object, + navbar: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + delay: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.shape({ show: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number, hide: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number }), __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.number]), + onOpened: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, + onClosed: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func }; -module.exports = ReactHostComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var DEFAULT_DELAYS$1 = { + show: 350, + hide: 350 +}; -/***/ }), -/* 100 */ -/***/ (function(module, exports, __webpack_require__) { +var defaultProps$62 = { + isOpen: false, + tag: 'div', + delay: DEFAULT_DELAYS$1, + onOpened: function onOpened() {}, + onClosed: function onClosed() {} +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Collapse = function (_Component) { + inherits(Collapse, _Component); + function Collapse(props) { + classCallCheck(this, Collapse); + var _this = possibleConstructorReturn(this, (Collapse.__proto__ || Object.getPrototypeOf(Collapse)).call(this, props)); -var _prodInvariant = __webpack_require__(3); + _this.state = { + collapse: props.isOpen ? SHOWN : HIDDEN, + height: null + }; + _this.element = null; + return _this; + } -var ReactCurrentOwner = __webpack_require__(14); -var REACT_ELEMENT_TYPE = __webpack_require__(180); + createClass(Collapse, [{ + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + var _this2 = this; -var getIteratorFn = __webpack_require__(181); -var invariant = __webpack_require__(1); -var KeyEscapeUtils = __webpack_require__(62); -var warning = __webpack_require__(2); + var willOpen = nextProps.isOpen; + var collapse = this.state.collapse; -var SEPARATOR = '.'; -var SUBSEPARATOR = ':'; + if (willOpen && collapse === HIDDEN) { + // will open + this.setState({ collapse: SHOW }, function () { + // the height transition will work after class "collapsing" applied + _this2.setState({ height: _this2.getHeight() }); + _this2.transitionTag = setTimeout(function () { + _this2.setState({ + collapse: SHOWN, + height: null + }); + }, _this2.getDelay('show')); + }); + } else if (!willOpen && collapse === SHOWN) { + // will hide + this.setState({ height: this.getHeight() }, function () { + _this2.setState({ + collapse: HIDE, + height: _this2.getHeight() + }, function () { + _this2.setState({ height: 0 }); + }); + }); -/** - * This is inlined from ReactElement since this file is shared between - * isomorphic and renderers. We could extract this to a - * - */ + this.transitionTag = setTimeout(function () { + _this2.setState({ + collapse: HIDDEN, + height: null + }); + }, this.getDelay('hide')); + } + // else: do nothing. + } + }, { + key: 'componentDidUpdate', + value: function componentDidUpdate(prevProps, prevState) { + if (this.state.collapse === SHOWN && prevState && prevState.collapse !== SHOWN) { + this.props.onOpened(); + } -/** - * TODO: Test that a single child and an array with one item have the same key - * pattern. - */ - -var didWarnAboutMaps = false; - -/** - * Generate a key string that identifies a component within a set. - * - * @param {*} component A component that could contain a manual key. - * @param {number} index Index that is used if a manual key is not provided. - * @return {string} - */ -function getComponentKey(component, index) { - // Do some typechecking here since we call this blindly. We want to ensure - // that we don't block potential future ES APIs. - if (component && typeof component === 'object' && component.key != null) { - // Explicit key - return KeyEscapeUtils.escape(component.key); - } - // Implicit key determined by the index in the set - return index.toString(36); -} - -/** - * @param {?*} children Children tree container. - * @param {!string} nameSoFar Name of the key path so far. - * @param {!function} callback Callback to invoke with each child found. - * @param {?*} traverseContext Used to pass information throughout the traversal - * process. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { - var type = typeof children; + if (this.state.collapse === HIDDEN && prevState && prevState.collapse !== HIDDEN) { + this.props.onClosed(); + } + } + }, { + key: 'componentWillUnmount', + value: function componentWillUnmount() { + clearTimeout(this.transitionTag); + } + }, { + key: 'getDelay', + value: function getDelay(key) { + var delay = this.props.delay; - if (type === 'undefined' || type === 'boolean') { - // All of the above are perceived as null. - children = null; - } + if ((typeof delay === 'undefined' ? 'undefined' : _typeof(delay)) === 'object') { + return isNaN(delay[key]) ? DEFAULT_DELAYS$1[key] : delay[key]; + } + return delay; + } + }, { + key: 'getHeight', + value: function getHeight() { + return this.element.scrollHeight; + } + }, { + key: 'render', + value: function render() { + var _this3 = this; - if (children === null || type === 'string' || type === 'number' || - // The following is inlined from ReactElement. This means we can optimize - // some checks. React Fiber also inlines this logic for similar purposes. - type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { - callback(traverseContext, children, - // If it's the only child, treat the name as if it was wrapped in an array - // so that it's consistent if the number of children grows. - nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); - return 1; - } + var _omit = omit(this.props, ['isOpen', 'delay', 'onOpened', 'onClosed']), + navbar = _omit.navbar, + className = _omit.className, + cssModule = _omit.cssModule, + Tag = _omit.tag, + attributes = objectWithoutProperties(_omit, ['navbar', 'className', 'cssModule', 'tag']); - var child; - var nextName; - var subtreeCount = 0; // Count of children found in the current subtree. - var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; + var _state = this.state, + collapse = _state.collapse, + height = _state.height; - if (Array.isArray(children)) { - for (var i = 0; i < children.length; i++) { - child = children[i]; - nextName = nextNamePrefix + getComponentKey(child, i); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - var iteratorFn = getIteratorFn(children); - if (iteratorFn) { - var iterator = iteratorFn.call(children); - var step; - if (iteratorFn !== children.entries) { - var ii = 0; - while (!(step = iterator.next()).done) { - child = step.value; - nextName = nextNamePrefix + getComponentKey(child, ii++); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - if (process.env.NODE_ENV !== 'production') { - var mapsAsChildrenAddendum = ''; - if (ReactCurrentOwner.current) { - var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); - if (mapsAsChildrenOwnerName) { - mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; - } - } - process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; - didWarnAboutMaps = true; - } - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - child = entry[1]; - nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } + var collapseClass = void 0; + switch (collapse) { + case SHOW: + collapseClass = 'collapsing'; + break; + case SHOWN: + collapseClass = 'collapse show'; + break; + case HIDE: + collapseClass = 'collapsing'; + break; + case HIDDEN: + collapseClass = 'collapse'; + break; + default: + // HIDDEN + collapseClass = 'collapse'; } - } else if (type === 'object') { - var addendum = ''; - if (process.env.NODE_ENV !== 'production') { - addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; - if (children._isReactElement) { - addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; - } - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - addendum += ' Check the render method of `' + name + '`.'; - } + + var classes = mapToCssModules(__WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, collapseClass, navbar && 'navbar-collapse'), cssModule); + var style = height === null ? null : { height: height }; + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { + style: _extends({}, attributes.style, style), + className: classes, + ref: function ref(c) { + _this3.element = c; } - } - var childrenString = String(children); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; + })); } - } + }]); + return Collapse; +}(__WEBPACK_IMPORTED_MODULE_0_react__["Component"]); - return subtreeCount; -} +Collapse.propTypes = propTypes$64; +Collapse.defaultProps = defaultProps$62; -/** - * Traverses children that are typically specified as `props.children`, but - * might also be specified through attributes: - * - * - `traverseAllChildren(this.props.children, ...)` - * - `traverseAllChildren(this.props.leftPanelChildren, ...)` - * - * The `traverseContext` is an optional argument that is passed through the - * entire traversal. It can be used to store accumulations or anything else that - * the callback might find relevant. - * - * @param {?*} children Children tree object. - * @param {!function} callback To invoke upon traversing each child. - * @param {?*} traverseContext Context for traversal. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildren(children, callback, traverseContext) { - if (children == null) { - return 0; +var propTypes$65 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + active: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + disabled: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + color: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string, + action: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.bool, + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; + +var defaultProps$63 = { + tag: 'li' +}; + +var handleDisabledOnClick = function handleDisabledOnClick(e) { + e.preventDefault(); +}; + +var ListGroupItem = function ListGroupItem(props) { + var className = props.className, + Tag = props.tag, + active = props.active, + disabled = props.disabled, + action = props.action, + color = props.color, + attributes = objectWithoutProperties(props, ['className', 'tag', 'active', 'disabled', 'action', 'color']); + + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, active ? 'active' : false, disabled ? 'disabled' : false, action ? 'list-group-item-action' : false, color ? 'list-group-item-' + color : false, 'list-group-item'); + + // Prevent click event when disabled. + if (disabled) { + attributes.onClick = handleDisabledOnClick; } + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; - return traverseAllChildrenImpl(children, '', callback, traverseContext); -} +ListGroupItem.propTypes = propTypes$65; +ListGroupItem.defaultProps = defaultProps$63; -module.exports = traverseAllChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var propTypes$66 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; -/***/ }), -/* 101 */ -/***/ (function(module, exports, __webpack_require__) { +var defaultProps$64 = { + tag: 'h5' +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +var ListGroupItemHeading = function ListGroupItemHeading(props) { + var className = props.className, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'tag']); -/** - * Copyright (c) 2013-present, Facebook, Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * @typechecks - */ + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-heading'); -var emptyFunction = __webpack_require__(12); + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; -/** - * Upstream version of event listener. Does not take into account specific - * nature of platform. - */ -var EventListener = { - /** - * Listen to DOM events during the bubble phase. - * - * @param {DOMEventTarget} target DOM element to register listener on. - * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. - * @param {function} callback Callback function. - * @return {object} Object with a `remove` method. - */ - listen: function listen(target, eventType, callback) { - if (target.addEventListener) { - target.addEventListener(eventType, callback, false); - return { - remove: function remove() { - target.removeEventListener(eventType, callback, false); - } - }; - } else if (target.attachEvent) { - target.attachEvent('on' + eventType, callback); - return { - remove: function remove() { - target.detachEvent('on' + eventType, callback); - } - }; - } - }, +ListGroupItemHeading.propTypes = propTypes$66; +ListGroupItemHeading.defaultProps = defaultProps$64; - /** - * Listen to DOM events during the capture phase. - * - * @param {DOMEventTarget} target DOM element to register listener on. - * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. - * @param {function} callback Callback function. - * @return {object} Object with a `remove` method. - */ - capture: function capture(target, eventType, callback) { - if (target.addEventListener) { - target.addEventListener(eventType, callback, true); - return { - remove: function remove() { - target.removeEventListener(eventType, callback, true); - } - }; - } else { - if (process.env.NODE_ENV !== 'production') { - console.error('Attempted to listen to events during the capture phase on a ' + 'browser that does not support the capture phase. Your application ' + 'will not receive some events.'); - } - return { - remove: emptyFunction - }; - } - }, +var propTypes$67 = { + tag: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.func, __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string]), + className: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.any +}; - registerDefault: function registerDefault() {} +var defaultProps$65 = { + tag: 'p' }; -module.exports = EventListener; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +var ListGroupItemText = function ListGroupItemText(props) { + var className = props.className, + Tag = props.tag, + attributes = objectWithoutProperties(props, ['className', 'tag']); -/***/ }), -/* 102 */ -/***/ (function(module, exports, __webpack_require__) { + var classes = __WEBPACK_IMPORTED_MODULE_2_classnames___default()(className, 'list-group-item-text'); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({}, attributes, { className: classes })); +}; +ListGroupItemText.propTypes = propTypes$67; +ListGroupItemText.defaultProps = defaultProps$65; +var Component$1 = __WEBPACK_IMPORTED_MODULE_0_react___default.a.Component; -var ReactDOMSelection = __webpack_require__(193); +var components = { + UncontrolledAlert: Alert, + UncontrolledButtonDropdown: ButtonDropdown, + UncontrolledDropdown: Dropdown, + UncontrolledNavDropdown: NavDropdown, + UncontrolledTooltip: Tooltip +}; -var containsNode = __webpack_require__(195); -var focusNode = __webpack_require__(91); -var getActiveElement = __webpack_require__(103); +Object.keys(components).forEach(function (key) { + var Tag = components[key]; + var defaultValue = Tag === Alert; -function isInDocument(node) { - return containsNode(document.documentElement, node); -} + var Uncontrolled = function (_Component) { + inherits(Uncontrolled, _Component); -/** - * @ReactInputSelection: React input selection module. Based on Selection.js, - * but modified to be suitable for react and has a couple of bug fixes (doesn't - * assume buttons have range selections allowed). - * Input selection module for React. - */ -var ReactInputSelection = { - hasSelectionCapabilities: function (elem) { - var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); - return nodeName && (nodeName === 'input' && elem.type === 'text' || nodeName === 'textarea' || elem.contentEditable === 'true'); - }, + function Uncontrolled(props) { + classCallCheck(this, Uncontrolled); - getSelectionInformation: function () { - var focusedElem = getActiveElement(); - return { - focusedElem: focusedElem, - selectionRange: ReactInputSelection.hasSelectionCapabilities(focusedElem) ? ReactInputSelection.getSelection(focusedElem) : null - }; - }, + var _this = possibleConstructorReturn(this, (Uncontrolled.__proto__ || Object.getPrototypeOf(Uncontrolled)).call(this, props)); - /** - * @restoreSelection: If any selection information was potentially lost, - * restore it. This is useful when performing operations that could remove dom - * nodes and place them back in, resulting in focus being lost. - */ - restoreSelection: function (priorSelectionInformation) { - var curFocusedElem = getActiveElement(); - var priorFocusedElem = priorSelectionInformation.focusedElem; - var priorSelectionRange = priorSelectionInformation.selectionRange; - if (curFocusedElem !== priorFocusedElem && isInDocument(priorFocusedElem)) { - if (ReactInputSelection.hasSelectionCapabilities(priorFocusedElem)) { - ReactInputSelection.setSelection(priorFocusedElem, priorSelectionRange); - } - focusNode(priorFocusedElem); - } - }, + _this.state = { isOpen: defaultValue }; - /** - * @getSelection: Gets the selection bounds of a focused textarea, input or - * contentEditable node. - * -@input: Look up selection bounds of this input - * -@return {start: selectionStart, end: selectionEnd} - */ - getSelection: function (input) { - var selection; + _this.toggle = _this.toggle.bind(_this); + return _this; + } - if ('selectionStart' in input) { - // Modern browser with input or textarea. - selection = { - start: input.selectionStart, - end: input.selectionEnd - }; - } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { - // IE8 input. - var range = document.selection.createRange(); - // There can only be one selection per document in IE, so it must - // be in our element. - if (range.parentElement() === input) { - selection = { - start: -range.moveStart('character', -input.value.length), - end: -range.moveEnd('character', -input.value.length) - }; + createClass(Uncontrolled, [{ + key: 'toggle', + value: function toggle() { + this.setState({ isOpen: !this.state.isOpen }); } - } else { - // Content editable or old IE textarea. - selection = ReactDOMSelection.getOffsets(input); - } + }, { + key: 'render', + value: function render() { + return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(Tag, _extends({ isOpen: this.state.isOpen, toggle: this.toggle }, this.props)); + } + }]); + return Uncontrolled; + }(Component$1); - return selection || { start: 0, end: 0 }; - }, + Uncontrolled.displayName = key; - /** - * @setSelection: Sets the selection bounds of a textarea or input and focuses - * the input. - * -@input Set selection bounds of this input or textarea - * -@offsets Object of same form that is returned from get* - */ - setSelection: function (input, offsets) { - var start = offsets.start; - var end = offsets.end; - if (end === undefined) { - end = start; - } + components[key] = Uncontrolled; +}); - if ('selectionStart' in input) { - input.selectionStart = start; - input.selectionEnd = Math.min(end, input.value.length); - } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { - var range = input.createTextRange(); - range.collapse(true); - range.moveStart('character', start); - range.moveEnd('character', end - start); - range.select(); - } else { - ReactDOMSelection.setOffsets(input, offsets); - } - } -}; +var UncontrolledAlert = components.UncontrolledAlert; +var UncontrolledButtonDropdown = components.UncontrolledButtonDropdown; +var UncontrolledDropdown = components.UncontrolledDropdown; +var UncontrolledNavDropdown = components.UncontrolledNavDropdown; +var UncontrolledTooltip = components.UncontrolledTooltip; + + +//# sourceMappingURL=reactstrap.es.js.map -module.exports = ReactInputSelection; /***/ }), -/* 103 */ +/* 94 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/* WEBPACK VAR INJECTION */(function(process) { +var utils = __webpack_require__(20); +var normalizeHeaderName = __webpack_require__(339); -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +var DEFAULT_CONTENT_TYPE = { + 'Content-Type': 'application/x-www-form-urlencoded' +}; -/* eslint-disable fb-www/typeof-undefined */ - -/** - * Same as document.activeElement but wraps in a try-catch block. In IE it is - * not safe to call document.activeElement if there is nothing focused. - * - * The activeElement will be null only if the document or document body is not - * yet defined. - * - * @param {?DOMDocument} doc Defaults to current document. - * @return {?DOMElement} - */ -function getActiveElement(doc) /*?DOMElement*/{ - doc = doc || (typeof document !== 'undefined' ? document : undefined); - if (typeof doc === 'undefined') { - return null; +function setContentTypeIfUnset(headers, value) { + if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) { + headers['Content-Type'] = value; } - try { - return doc.activeElement || doc.body; - } catch (e) { - return doc.body; +} + +function getDefaultAdapter() { + var adapter; + if (typeof XMLHttpRequest !== 'undefined') { + // For browsers use XHR adapter + adapter = __webpack_require__(156); + } else if (typeof process !== 'undefined') { + // For node use HTTP adapter + adapter = __webpack_require__(156); } + return adapter; } -module.exports = getActiveElement; +var defaults = { + adapter: getDefaultAdapter(), + + transformRequest: [function transformRequest(data, headers) { + normalizeHeaderName(headers, 'Content-Type'); + if (utils.isFormData(data) || + utils.isArrayBuffer(data) || + utils.isBuffer(data) || + utils.isStream(data) || + utils.isFile(data) || + utils.isBlob(data) + ) { + return data; + } + if (utils.isArrayBufferView(data)) { + return data.buffer; + } + if (utils.isURLSearchParams(data)) { + setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8'); + return data.toString(); + } + if (utils.isObject(data)) { + setContentTypeIfUnset(headers, 'application/json;charset=utf-8'); + return JSON.stringify(data); + } + return data; + }], + + transformResponse: [function transformResponse(data) { + /*eslint no-param-reassign:0*/ + if (typeof data === 'string') { + try { + data = JSON.parse(data); + } catch (e) { /* Ignore */ } + } + return data; + }], + + timeout: 0, + + xsrfCookieName: 'XSRF-TOKEN', + xsrfHeaderName: 'X-XSRF-TOKEN', + + maxContentLength: -1, + + validateStatus: function validateStatus(status) { + return status >= 200 && status < 300; + } +}; + +defaults.headers = { + common: { + 'Accept': 'application/json, text/plain, */*' + } +}; + +utils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) { + defaults.headers[method] = {}; +}); + +utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE); +}); + +module.exports = defaults; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 104 */ +/* 95 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Object.defineProperty(exports, "__esModule", { + value: true +}); -var _prodInvariant = __webpack_require__(3); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var DOMLazyTree = __webpack_require__(27); -var DOMProperty = __webpack_require__(17); -var React = __webpack_require__(24); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactCurrentOwner = __webpack_require__(14); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMContainerInfo = __webpack_require__(210); -var ReactDOMFeatureFlags = __webpack_require__(211); -var ReactFeatureFlags = __webpack_require__(86); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactMarkupChecksum = __webpack_require__(212); -var ReactReconciler = __webpack_require__(26); -var ReactUpdateQueue = __webpack_require__(63); -var ReactUpdates = __webpack_require__(15); +var _react = __webpack_require__(6); -var emptyObject = __webpack_require__(39); -var instantiateReactComponent = __webpack_require__(96); -var invariant = __webpack_require__(1); -var setInnerHTML = __webpack_require__(43); -var shouldUpdateReactComponent = __webpack_require__(61); -var warning = __webpack_require__(2); +var _react2 = _interopRequireDefault(_react); -var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; -var ROOT_ATTR_NAME = DOMProperty.ROOT_ATTRIBUTE_NAME; +var _classnames = __webpack_require__(41); -var ELEMENT_NODE_TYPE = 1; -var DOC_NODE_TYPE = 9; -var DOCUMENT_FRAGMENT_NODE_TYPE = 11; +var _classnames2 = _interopRequireDefault(_classnames); -var instancesByReactRootID = {}; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -/** - * Finds the index of the first character - * that's not common between the two given strings. - * - * @return {number} the index of the character where the strings diverge - */ -function firstDifferenceIndex(string1, string2) { - var minLen = Math.min(string1.length, string2.length); - for (var i = 0; i < minLen; i++) { - if (string1.charAt(i) !== string2.charAt(i)) { - return i; - } +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } + +// +exports.default = { + get: get, + set: set, + takeRight: takeRight, + last: last, + orderBy: orderBy, + range: range, + remove: remove, + clone: clone, + getFirstDefined: getFirstDefined, + sum: sum, + makeTemplateComponent: makeTemplateComponent, + groupBy: groupBy, + isArray: isArray, + splitProps: splitProps, + compactObject: compactObject, + isSortingDesc: isSortingDesc, + normalizeComponent: normalizeComponent, + asPx: asPx +}; + + +function get(obj, path, def) { + if (!path) { + return obj; } - return string1.length === string2.length ? -1 : minLen; + var pathObj = makePathArray(path); + var val = void 0; + try { + val = pathObj.reduce(function (current, pathPart) { + return current[pathPart]; + }, obj); + } catch (e) {} + return typeof val !== 'undefined' ? val : def; } -/** - * @param {DOMElement|DOMDocument} container DOM element that may contain - * a React component - * @return {?*} DOM element that may have the reactRoot ID, or null. - */ -function getReactRootElementInContainer(container) { - if (!container) { - return null; - } +function set() { + var obj = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + var path = arguments[1]; + var value = arguments[2]; - if (container.nodeType === DOC_NODE_TYPE) { - return container.documentElement; - } else { - return container.firstChild; + var keys = makePathArray(path); + var keyPart = void 0; + var cursor = obj; + while ((keyPart = keys.shift()) && keys.length) { + if (!cursor[keyPart]) { + cursor[keyPart] = {}; + } + cursor = cursor[keyPart]; } + cursor[keyPart] = value; + return obj; } -function internalGetID(node) { - // If node is something like a window, document, or text node, none of - // which support attributes or a .getAttribute method, gracefully return - // the empty string, as if the attribute were missing. - return node.getAttribute && node.getAttribute(ATTR_NAME) || ''; +function takeRight(arr, n) { + var start = n > arr.length ? 0 : arr.length - n; + return arr.slice(start); } -/** - * Mounts this component and inserts it into the DOM. - * - * @param {ReactComponent} componentInstance The instance to mount. - * @param {DOMElement} container DOM element to mount into. - * @param {ReactReconcileTransaction} transaction - * @param {boolean} shouldReuseMarkup If true, do not insert markup - */ -function mountComponentIntoNode(wrapperInstance, container, transaction, shouldReuseMarkup, context) { - var markerName; - if (ReactFeatureFlags.logTopLevelRenders) { - var wrappedElement = wrapperInstance._currentElement.props.child; - var type = wrappedElement.type; - markerName = 'React mount: ' + (typeof type === 'string' ? type : type.displayName || type.name); - console.time(markerName); - } - - var markup = ReactReconciler.mountComponent(wrapperInstance, transaction, null, ReactDOMContainerInfo(wrapperInstance, container), context, 0 /* parentDebugID */ - ); +function last(arr) { + return arr[arr.length - 1]; +} - if (markerName) { - console.timeEnd(markerName); +function range(n) { + var arr = []; + for (var i = 0; i < n; i++) { + arr.push(n); } + return arr; +} - wrapperInstance._renderedComponent._topLevelWrapper = wrapperInstance; - ReactMount._mountImageIntoNode(markup, container, wrapperInstance, shouldReuseMarkup, transaction); +function orderBy(arr, funcs, dirs, indexKey) { + return arr.sort(function (rowA, rowB) { + for (var i = 0; i < funcs.length; i++) { + var comp = funcs[i]; + var desc = dirs[i] === false || dirs[i] === 'desc'; + var sortInt = comp(rowA, rowB); + if (sortInt) { + return desc ? -sortInt : sortInt; + } + } + // Use the row index for tie breakers + return dirs[0] ? rowA[indexKey] - rowB[indexKey] : rowB[indexKey] - rowA[indexKey]; + }); } -/** - * Batched mount. - * - * @param {ReactComponent} componentInstance The instance to mount. - * @param {DOMElement} container DOM element to mount into. - * @param {boolean} shouldReuseMarkup If true, do not insert markup - */ -function batchedMountComponentIntoNode(componentInstance, container, shouldReuseMarkup, context) { - var transaction = ReactUpdates.ReactReconcileTransaction.getPooled( - /* useCreateElement */ - !shouldReuseMarkup && ReactDOMFeatureFlags.useCreateElement); - transaction.perform(mountComponentIntoNode, null, componentInstance, container, transaction, shouldReuseMarkup, context); - ReactUpdates.ReactReconcileTransaction.release(transaction); +function remove(a, b) { + return a.filter(function (o, i) { + var r = b(o); + if (r) { + a.splice(i, 1); + return true; + } + return false; + }); } -/** - * Unmounts a component and removes it from the DOM. - * - * @param {ReactComponent} instance React component instance. - * @param {DOMElement} container DOM element to unmount from. - * @final - * @internal - * @see {ReactMount.unmountComponentAtNode} - */ -function unmountComponentFromNode(instance, container, safely) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onBeginFlush(); - } - ReactReconciler.unmountComponent(instance, safely); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onEndFlush(); +function clone(a) { + try { + return JSON.parse(JSON.stringify(a, function (key, value) { + if (typeof value === 'function') { + return value.toString(); + } + return value; + })); + } catch (e) { + return a; } +} - if (container.nodeType === DOC_NODE_TYPE) { - container = container.documentElement; +function getFirstDefined() { + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; } - // http://jsperf.com/emptying-a-node - while (container.lastChild) { - container.removeChild(container.lastChild); + for (var i = 0; i < args.length; i++) { + if (typeof args[i] !== 'undefined') { + return args[i]; + } } } -/** - * True if the supplied DOM node has a direct React-rendered child that is - * not a React root element. Useful for warning in `render`, - * `unmountComponentAtNode`, etc. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM element contains a direct child that was - * rendered by React but is not a root element. - * @internal - */ -function hasNonRootReactChild(container) { - var rootEl = getReactRootElementInContainer(container); - if (rootEl) { - var inst = ReactDOMComponentTree.getInstanceFromNode(rootEl); - return !!(inst && inst._hostParent); +function sum(arr) { + return arr.reduce(function (a, b) { + return a + b; + }, 0); +} + +function makeTemplateComponent(compClass, displayName) { + if (!displayName) { + throw new Error('No displayName found for template component:', compClass); } + var cmp = function cmp(_ref) { + var children = _ref.children, + className = _ref.className, + rest = _objectWithoutProperties(_ref, ['children', 'className']); + + return _react2.default.createElement( + 'div', + _extends({ className: (0, _classnames2.default)(compClass, className) }, rest), + children + ); + }; + cmp.displayName = displayName; + return cmp; } -/** - * True if the supplied DOM node is a React DOM element and - * it has been rendered by another copy of React. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM has been rendered by another copy of React - * @internal - */ -function nodeIsRenderedByOtherInstance(container) { - var rootEl = getReactRootElementInContainer(container); - return !!(rootEl && isReactNode(rootEl) && !ReactDOMComponentTree.getInstanceFromNode(rootEl)); +function groupBy(xs, key) { + return xs.reduce(function (rv, x, i) { + var resKey = typeof key === 'function' ? key(x, i) : x[key]; + rv[resKey] = isArray(rv[resKey]) ? rv[resKey] : []; + rv[resKey].push(x); + return rv; + }, {}); } -/** - * True if the supplied DOM node is a valid node element. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM is a valid DOM node. - * @internal - */ -function isValidContainer(node) { - return !!(node && (node.nodeType === ELEMENT_NODE_TYPE || node.nodeType === DOC_NODE_TYPE || node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE)); +function asPx(value) { + value = Number(value); + return Number.isNaN(value) ? null : value + 'px'; } -/** - * True if the supplied DOM node is a valid React node element. - * - * @param {?DOMElement} node The candidate DOM node. - * @return {boolean} True if the DOM is a valid React DOM node. - * @internal - */ -function isReactNode(node) { - return isValidContainer(node) && (node.hasAttribute(ROOT_ATTR_NAME) || node.hasAttribute(ATTR_NAME)); +function isArray(a) { + return Array.isArray(a); } -function getHostRootInstanceInContainer(container) { - var rootEl = getReactRootElementInContainer(container); - var prevHostInstance = rootEl && ReactDOMComponentTree.getInstanceFromNode(rootEl); - return prevHostInstance && !prevHostInstance._hostParent ? prevHostInstance : null; +// ######################################################################## +// Non-exported Helpers +// ######################################################################## + +function makePathArray(obj) { + return flattenDeep(obj).join('.').replace(/\[/g, '.').replace(/\]/g, '').split('.'); } -function getTopLevelWrapperInContainer(container) { - var root = getHostRootInstanceInContainer(container); - return root ? root._hostContainerInfo._topLevelWrapper : null; +function flattenDeep(arr) { + var newArr = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : []; + + if (!isArray(arr)) { + newArr.push(arr); + } else { + for (var i = 0; i < arr.length; i++) { + flattenDeep(arr[i], newArr); + } + } + return newArr; } -/** - * Temporary (?) hack so that we can store all top-level pending updates on - * composites instead of having to worry about different types of components - * here. - */ -var topLevelRootCounter = 1; -var TopLevelWrapper = function () { - this.rootID = topLevelRootCounter++; -}; -TopLevelWrapper.prototype.isReactComponent = {}; -if (process.env.NODE_ENV !== 'production') { - TopLevelWrapper.displayName = 'TopLevelWrapper'; +function splitProps(_ref2) { + var className = _ref2.className, + style = _ref2.style, + rest = _objectWithoutProperties(_ref2, ['className', 'style']); + + return { + className: className, + style: style, + rest: rest || {} + }; } -TopLevelWrapper.prototype.render = function () { - return this.props.child; -}; -TopLevelWrapper.isReactTopLevelWrapper = true; -/** - * Mounting is the process of initializing a React component by creating its - * representative DOM elements and inserting them into a supplied `container`. - * Any prior content inside `container` is destroyed in the process. - * - * ReactMount.render( - * component, - * document.getElementById('container') - * ); - * - * <div id="container"> <-- Supplied `container`. - * <div data-reactid=".3"> <-- Rendered reactRoot of React - * // ... component. - * </div> - * </div> - * - * Inside of `container`, the first element rendered is the "reactRoot". - */ -var ReactMount = { - TopLevelWrapper: TopLevelWrapper, +function compactObject(obj) { + var newObj = {}; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key] !== undefined && typeof obj[key] !== 'undefined') { + newObj[key] = obj[key]; + } + } + return newObj; +} - /** - * Used by devtools. The keys are not important. - */ - _instancesByReactRootID: instancesByReactRootID, +function isSortingDesc(d) { + return !!(d.sort === 'desc' || d.desc === true || d.asc === false); +} - /** - * This is a hook provided to support rendering React components while - * ensuring that the apparent scroll position of its `container` does not - * change. - * - * @param {DOMElement} container The `container` being rendered into. - * @param {function} renderCallback This must be called once to do the render. - */ - scrollMonitor: function (container, renderCallback) { - renderCallback(); - }, +function normalizeComponent(Comp) { + var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; + var fallback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Comp; - /** - * Take a component that's already mounted into the DOM and replace its props - * @param {ReactComponent} prevComponent component instance already in the DOM - * @param {ReactElement} nextElement component instance to render - * @param {DOMElement} container container to render into - * @param {?function} callback function triggered on completion - */ - _updateRootComponent: function (prevComponent, nextElement, nextContext, container, callback) { - ReactMount.scrollMonitor(container, function () { - ReactUpdateQueue.enqueueElementInternal(prevComponent, nextElement, nextContext); - if (callback) { - ReactUpdateQueue.enqueueCallbackInternal(prevComponent, callback); - } - }); + return typeof Comp === 'function' ? Object.getPrototypeOf(Comp).isReactComponent ? _react2.default.createElement(Comp, params) : Comp(params) : fallback; +} +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy91dGlscy5qcyJdLCJuYW1lcyI6WyJnZXQiLCJzZXQiLCJ0YWtlUmlnaHQiLCJsYXN0Iiwib3JkZXJCeSIsInJhbmdlIiwicmVtb3ZlIiwiY2xvbmUiLCJnZXRGaXJzdERlZmluZWQiLCJzdW0iLCJtYWtlVGVtcGxhdGVDb21wb25lbnQiLCJncm91cEJ5IiwiaXNBcnJheSIsInNwbGl0UHJvcHMiLCJjb21wYWN0T2JqZWN0IiwiaXNTb3J0aW5nRGVzYyIsIm5vcm1hbGl6ZUNvbXBvbmVudCIsImFzUHgiLCJvYmoiLCJwYXRoIiwiZGVmIiwicGF0aE9iaiIsIm1ha2VQYXRoQXJyYXkiLCJ2YWwiLCJyZWR1Y2UiLCJjdXJyZW50IiwicGF0aFBhcnQiLCJlIiwidmFsdWUiLCJrZXlzIiwia2V5UGFydCIsImN1cnNvciIsInNoaWZ0IiwibGVuZ3RoIiwiYXJyIiwibiIsInN0YXJ0Iiwic2xpY2UiLCJpIiwicHVzaCIsImZ1bmNzIiwiZGlycyIsImluZGV4S2V5Iiwic29ydCIsInJvd0EiLCJyb3dCIiwiY29tcCIsImRlc2MiLCJzb3J0SW50IiwiYSIsImIiLCJmaWx0ZXIiLCJvIiwiciIsInNwbGljZSIsIkpTT04iLCJwYXJzZSIsInN0cmluZ2lmeSIsImtleSIsInRvU3RyaW5nIiwiYXJncyIsImNvbXBDbGFzcyIsImRpc3BsYXlOYW1lIiwiRXJyb3IiLCJjbXAiLCJjaGlsZHJlbiIsImNsYXNzTmFtZSIsInJlc3QiLCJ4cyIsInJ2IiwieCIsInJlc0tleSIsIk51bWJlciIsImlzTmFOIiwiQXJyYXkiLCJmbGF0dGVuRGVlcCIsImpvaW4iLCJyZXBsYWNlIiwic3BsaXQiLCJuZXdBcnIiLCJzdHlsZSIsIm5ld09iaiIsImhhc093blByb3BlcnR5IiwidW5kZWZpbmVkIiwiZCIsImFzYyIsIkNvbXAiLCJwYXJhbXMiLCJmYWxsYmFjayIsIk9iamVjdCIsImdldFByb3RvdHlwZU9mIiwiaXNSZWFjdENvbXBvbmVudCJdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7Ozs7OztBQUNBO2tCQUNlO0FBQ2JBLFVBRGE7QUFFYkMsVUFGYTtBQUdiQyxzQkFIYTtBQUliQyxZQUphO0FBS2JDLGtCQUxhO0FBTWJDLGNBTmE7QUFPYkMsZ0JBUGE7QUFRYkMsY0FSYTtBQVNiQyxrQ0FUYTtBQVViQyxVQVZhO0FBV2JDLDhDQVhhO0FBWWJDLGtCQVphO0FBYWJDLGtCQWJhO0FBY2JDLHdCQWRhO0FBZWJDLDhCQWZhO0FBZ0JiQyw4QkFoQmE7QUFpQmJDLHdDQWpCYTtBQWtCYkM7QUFsQmEsQzs7O0FBcUJmLFNBQVNqQixHQUFULENBQWNrQixHQUFkLEVBQW1CQyxJQUFuQixFQUF5QkMsR0FBekIsRUFBOEI7QUFDNUIsTUFBSSxDQUFDRCxJQUFMLEVBQVc7QUFDVCxXQUFPRCxHQUFQO0FBQ0Q7QUFDRCxNQUFNRyxVQUFVQyxjQUFjSCxJQUFkLENBQWhCO0FBQ0EsTUFBSUksWUFBSjtBQUNBLE1BQUk7QUFDRkEsVUFBTUYsUUFBUUcsTUFBUixDQUFlLFVBQUNDLE9BQUQsRUFBVUMsUUFBVjtBQUFBLGFBQXVCRCxRQUFRQyxRQUFSLENBQXZCO0FBQUEsS0FBZixFQUF5RFIsR0FBekQsQ0FBTjtBQUNELEdBRkQsQ0FFRSxPQUFPUyxDQUFQLEVBQVUsQ0FBRTtBQUNkLFNBQU8sT0FBT0osR0FBUCxLQUFlLFdBQWYsR0FBNkJBLEdBQTdCLEdBQW1DSCxHQUExQztBQUNEOztBQUVELFNBQVNuQixHQUFULEdBQXFDO0FBQUEsTUFBdkJpQixHQUF1Qix1RUFBakIsRUFBaUI7QUFBQSxNQUFiQyxJQUFhO0FBQUEsTUFBUFMsS0FBTzs7QUFDbkMsTUFBTUMsT0FBT1AsY0FBY0gsSUFBZCxDQUFiO0FBQ0EsTUFBSVcsZ0JBQUo7QUFDQSxNQUFJQyxTQUFTYixHQUFiO0FBQ0EsU0FBTyxDQUFDWSxVQUFVRCxLQUFLRyxLQUFMLEVBQVgsS0FBNEJILEtBQUtJLE1BQXhDLEVBQWdEO0FBQzlDLFFBQUksQ0FBQ0YsT0FBT0QsT0FBUCxDQUFMLEVBQXNCO0FBQ3BCQyxhQUFPRCxPQUFQLElBQWtCLEVBQWxCO0FBQ0Q7QUFDREMsYUFBU0EsT0FBT0QsT0FBUCxDQUFUO0FBQ0Q7QUFDREMsU0FBT0QsT0FBUCxJQUFrQkYsS0FBbEI7QUFDQSxTQUFPVixHQUFQO0FBQ0Q7O0FBRUQsU0FBU2hCLFNBQVQsQ0FBb0JnQyxHQUFwQixFQUF5QkMsQ0FBekIsRUFBNEI7QUFDMUIsTUFBTUMsUUFBUUQsSUFBSUQsSUFBSUQsTUFBUixHQUFpQixDQUFqQixHQUFxQkMsSUFBSUQsTUFBSixHQUFhRSxDQUFoRDtBQUNBLFNBQU9ELElBQUlHLEtBQUosQ0FBVUQsS0FBVixDQUFQO0FBQ0Q7O0FBRUQsU0FBU2pDLElBQVQsQ0FBZStCLEdBQWYsRUFBb0I7QUFDbEIsU0FBT0EsSUFBSUEsSUFBSUQsTUFBSixHQUFhLENBQWpCLENBQVA7QUFDRDs7QUFFRCxTQUFTNUIsS0FBVCxDQUFnQjhCLENBQWhCLEVBQW1CO0FBQ2pCLE1BQU1ELE1BQU0sRUFBWjtBQUNBLE9BQUssSUFBSUksSUFBSSxDQUFiLEVBQWdCQSxJQUFJSCxDQUFwQixFQUF1QkcsR0FBdkIsRUFBNEI7QUFDMUJKLFFBQUlLLElBQUosQ0FBU0osQ0FBVDtBQUNEO0FBQ0QsU0FBT0QsR0FBUDtBQUNEOztBQUVELFNBQVM5QixPQUFULENBQWtCOEIsR0FBbEIsRUFBdUJNLEtBQXZCLEVBQThCQyxJQUE5QixFQUFvQ0MsUUFBcEMsRUFBOEM7QUFDNUMsU0FBT1IsSUFBSVMsSUFBSixDQUFTLFVBQUNDLElBQUQsRUFBT0MsSUFBUCxFQUFnQjtBQUM5QixTQUFLLElBQUlQLElBQUksQ0FBYixFQUFnQkEsSUFBSUUsTUFBTVAsTUFBMUIsRUFBa0NLLEdBQWxDLEVBQXVDO0FBQ3JDLFVBQU1RLE9BQU9OLE1BQU1GLENBQU4sQ0FBYjtBQUNBLFVBQU1TLE9BQU9OLEtBQUtILENBQUwsTUFBWSxLQUFaLElBQXFCRyxLQUFLSCxDQUFMLE1BQVksTUFBOUM7QUFDQSxVQUFNVSxVQUFVRixLQUFLRixJQUFMLEVBQVdDLElBQVgsQ0FBaEI7QUFDQSxVQUFJRyxPQUFKLEVBQWE7QUFDWCxlQUFPRCxPQUFPLENBQUNDLE9BQVIsR0FBa0JBLE9BQXpCO0FBQ0Q7QUFDRjtBQUNEO0FBQ0EsV0FBT1AsS0FBSyxDQUFMLElBQ0hHLEtBQUtGLFFBQUwsSUFBaUJHLEtBQUtILFFBQUwsQ0FEZCxHQUVIRyxLQUFLSCxRQUFMLElBQWlCRSxLQUFLRixRQUFMLENBRnJCO0FBR0QsR0FiTSxDQUFQO0FBY0Q7O0FBRUQsU0FBU3BDLE1BQVQsQ0FBaUIyQyxDQUFqQixFQUFvQkMsQ0FBcEIsRUFBdUI7QUFDckIsU0FBT0QsRUFBRUUsTUFBRixDQUFTLFVBQVVDLENBQVYsRUFBYWQsQ0FBYixFQUFnQjtBQUM5QixRQUFJZSxJQUFJSCxFQUFFRSxDQUFGLENBQVI7QUFDQSxRQUFJQyxDQUFKLEVBQU87QUFDTEosUUFBRUssTUFBRixDQUFTaEIsQ0FBVCxFQUFZLENBQVo7QUFDQSxhQUFPLElBQVA7QUFDRDtBQUNELFdBQU8sS0FBUDtBQUNELEdBUE0sQ0FBUDtBQVFEOztBQUVELFNBQVMvQixLQUFULENBQWdCMEMsQ0FBaEIsRUFBbUI7QUFDakIsTUFBSTtBQUNGLFdBQU9NLEtBQUtDLEtBQUwsQ0FDTEQsS0FBS0UsU0FBTCxDQUFlUixDQUFmLEVBQWtCLFVBQUNTLEdBQUQsRUFBTTlCLEtBQU4sRUFBZ0I7QUFDaEMsVUFBSSxPQUFPQSxLQUFQLEtBQWlCLFVBQXJCLEVBQWlDO0FBQy9CLGVBQU9BLE1BQU0rQixRQUFOLEVBQVA7QUFDRDtBQUNELGFBQU8vQixLQUFQO0FBQ0QsS0FMRCxDQURLLENBQVA7QUFRRCxHQVRELENBU0UsT0FBT0QsQ0FBUCxFQUFVO0FBQ1YsV0FBT3NCLENBQVA7QUFDRDtBQUNGOztBQUVELFNBQVN6QyxlQUFULEdBQW1DO0FBQUEsb0NBQU5vRCxJQUFNO0FBQU5BLFFBQU07QUFBQTs7QUFDakMsT0FBSyxJQUFJdEIsSUFBSSxDQUFiLEVBQWdCQSxJQUFJc0IsS0FBSzNCLE1BQXpCLEVBQWlDSyxHQUFqQyxFQUFzQztBQUNwQyxRQUFJLE9BQU9zQixLQUFLdEIsQ0FBTCxDQUFQLEtBQW1CLFdBQXZCLEVBQW9DO0FBQ2xDLGFBQU9zQixLQUFLdEIsQ0FBTCxDQUFQO0FBQ0Q7QUFDRjtBQUNGOztBQUVELFNBQVM3QixHQUFULENBQWN5QixHQUFkLEVBQW1CO0FBQ2pCLFNBQU9BLElBQUlWLE1BQUosQ0FBVyxVQUFDeUIsQ0FBRCxFQUFJQyxDQUFKLEVBQVU7QUFDMUIsV0FBT0QsSUFBSUMsQ0FBWDtBQUNELEdBRk0sRUFFSixDQUZJLENBQVA7QUFHRDs7QUFFRCxTQUFTeEMscUJBQVQsQ0FBZ0NtRCxTQUFoQyxFQUEyQ0MsV0FBM0MsRUFBd0Q7QUFDdEQsTUFBSSxDQUFDQSxXQUFMLEVBQWtCO0FBQ2hCLFVBQU0sSUFBSUMsS0FBSixDQUFVLDhDQUFWLEVBQTBERixTQUExRCxDQUFOO0FBQ0Q7QUFDRCxNQUFNRyxNQUFNLFNBQU5BLEdBQU07QUFBQSxRQUFHQyxRQUFILFFBQUdBLFFBQUg7QUFBQSxRQUFhQyxTQUFiLFFBQWFBLFNBQWI7QUFBQSxRQUEyQkMsSUFBM0I7O0FBQUEsV0FDVjtBQUFBO0FBQUEsaUJBQUssV0FBVywwQkFBV04sU0FBWCxFQUFzQkssU0FBdEIsQ0FBaEIsSUFBc0RDLElBQXREO0FBQ0dGO0FBREgsS0FEVTtBQUFBLEdBQVo7QUFJQUQsTUFBSUYsV0FBSixHQUFrQkEsV0FBbEI7QUFDQSxTQUFPRSxHQUFQO0FBQ0Q7O0FBRUQsU0FBU3JELE9BQVQsQ0FBa0J5RCxFQUFsQixFQUFzQlYsR0FBdEIsRUFBMkI7QUFDekIsU0FBT1UsR0FBRzVDLE1BQUgsQ0FBVSxVQUFDNkMsRUFBRCxFQUFLQyxDQUFMLEVBQVFoQyxDQUFSLEVBQWM7QUFDN0IsUUFBTWlDLFNBQVMsT0FBT2IsR0FBUCxLQUFlLFVBQWYsR0FBNEJBLElBQUlZLENBQUosRUFBT2hDLENBQVAsQ0FBNUIsR0FBd0NnQyxFQUFFWixHQUFGLENBQXZEO0FBQ0FXLE9BQUdFLE1BQUgsSUFBYTNELFFBQVF5RCxHQUFHRSxNQUFILENBQVIsSUFBc0JGLEdBQUdFLE1BQUgsQ0FBdEIsR0FBbUMsRUFBaEQ7QUFDQUYsT0FBR0UsTUFBSCxFQUFXaEMsSUFBWCxDQUFnQitCLENBQWhCO0FBQ0EsV0FBT0QsRUFBUDtBQUNELEdBTE0sRUFLSixFQUxJLENBQVA7QUFNRDs7QUFFRCxTQUFTcEQsSUFBVCxDQUFlVyxLQUFmLEVBQXNCO0FBQ3BCQSxVQUFRNEMsT0FBTzVDLEtBQVAsQ0FBUjtBQUNBLFNBQU80QyxPQUFPQyxLQUFQLENBQWE3QyxLQUFiLElBQXNCLElBQXRCLEdBQTZCQSxRQUFRLElBQTVDO0FBQ0Q7O0FBRUQsU0FBU2hCLE9BQVQsQ0FBa0JxQyxDQUFsQixFQUFxQjtBQUNuQixTQUFPeUIsTUFBTTlELE9BQU4sQ0FBY3FDLENBQWQsQ0FBUDtBQUNEOztBQUVEO0FBQ0E7QUFDQTs7QUFFQSxTQUFTM0IsYUFBVCxDQUF3QkosR0FBeEIsRUFBNkI7QUFDM0IsU0FBT3lELFlBQVl6RCxHQUFaLEVBQ0owRCxJQURJLENBQ0MsR0FERCxFQUVKQyxPQUZJLENBRUksS0FGSixFQUVXLEdBRlgsRUFHSkEsT0FISSxDQUdJLEtBSEosRUFHVyxFQUhYLEVBSUpDLEtBSkksQ0FJRSxHQUpGLENBQVA7QUFLRDs7QUFFRCxTQUFTSCxXQUFULENBQXNCekMsR0FBdEIsRUFBd0M7QUFBQSxNQUFiNkMsTUFBYSx1RUFBSixFQUFJOztBQUN0QyxNQUFJLENBQUNuRSxRQUFRc0IsR0FBUixDQUFMLEVBQW1CO0FBQ2pCNkMsV0FBT3hDLElBQVAsQ0FBWUwsR0FBWjtBQUNELEdBRkQsTUFFTztBQUNMLFNBQUssSUFBSUksSUFBSSxDQUFiLEVBQWdCQSxJQUFJSixJQUFJRCxNQUF4QixFQUFnQ0ssR0FBaEMsRUFBcUM7QUFDbkNxQyxrQkFBWXpDLElBQUlJLENBQUosQ0FBWixFQUFvQnlDLE1BQXBCO0FBQ0Q7QUFDRjtBQUNELFNBQU9BLE1BQVA7QUFDRDs7QUFFRCxTQUFTbEUsVUFBVCxRQUFvRDtBQUFBLE1BQTdCcUQsU0FBNkIsU0FBN0JBLFNBQTZCO0FBQUEsTUFBbEJjLEtBQWtCLFNBQWxCQSxLQUFrQjtBQUFBLE1BQVJiLElBQVE7O0FBQ2xELFNBQU87QUFDTEQsd0JBREs7QUFFTGMsZ0JBRks7QUFHTGIsVUFBTUEsUUFBUTtBQUhULEdBQVA7QUFLRDs7QUFFRCxTQUFTckQsYUFBVCxDQUF3QkksR0FBeEIsRUFBNkI7QUFDM0IsTUFBTStELFNBQVMsRUFBZjtBQUNBLE9BQUssSUFBSXZCLEdBQVQsSUFBZ0J4QyxHQUFoQixFQUFxQjtBQUNuQixRQUNFQSxJQUFJZ0UsY0FBSixDQUFtQnhCLEdBQW5CLEtBQ0F4QyxJQUFJd0MsR0FBSixNQUFheUIsU0FEYixJQUVBLE9BQU9qRSxJQUFJd0MsR0FBSixDQUFQLEtBQW9CLFdBSHRCLEVBSUU7QUFDQXVCLGFBQU92QixHQUFQLElBQWN4QyxJQUFJd0MsR0FBSixDQUFkO0FBQ0Q7QUFDRjtBQUNELFNBQU91QixNQUFQO0FBQ0Q7O0FBRUQsU0FBU2xFLGFBQVQsQ0FBd0JxRSxDQUF4QixFQUEyQjtBQUN6QixTQUFPLENBQUMsRUFBRUEsRUFBRXpDLElBQUYsS0FBVyxNQUFYLElBQXFCeUMsRUFBRXJDLElBQUYsS0FBVyxJQUFoQyxJQUF3Q3FDLEVBQUVDLEdBQUYsS0FBVSxLQUFwRCxDQUFSO0FBQ0Q7O0FBRUQsU0FBU3JFLGtCQUFULENBQTZCc0UsSUFBN0IsRUFBaUU7QUFBQSxNQUE5QkMsTUFBOEIsdUVBQXJCLEVBQXFCO0FBQUEsTUFBakJDLFFBQWlCLHVFQUFORixJQUFNOztBQUMvRCxTQUFPLE9BQU9BLElBQVAsS0FBZ0IsVUFBaEIsR0FDSEcsT0FBT0MsY0FBUCxDQUFzQkosSUFBdEIsRUFBNEJLLGdCQUE1QixHQUNFLDhCQUFDLElBQUQsRUFBVUosTUFBVixDQURGLEdBRUVELEtBQUtDLE1BQUwsQ0FIQyxHQUlIQyxRQUpKO0FBS0QiLCJmaWxlIjoidXRpbHMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgUmVhY3QgZnJvbSAncmVhY3QnXG5pbXBvcnQgY2xhc3NuYW1lcyBmcm9tICdjbGFzc25hbWVzJ1xuLy9cbmV4cG9ydCBkZWZhdWx0IHtcbiAgZ2V0LFxuICBzZXQsXG4gIHRha2VSaWdodCxcbiAgbGFzdCxcbiAgb3JkZXJCeSxcbiAgcmFuZ2UsXG4gIHJlbW92ZSxcbiAgY2xvbmUsXG4gIGdldEZpcnN0RGVmaW5lZCxcbiAgc3VtLFxuICBtYWtlVGVtcGxhdGVDb21wb25lbnQsXG4gIGdyb3VwQnksXG4gIGlzQXJyYXksXG4gIHNwbGl0UHJvcHMsXG4gIGNvbXBhY3RPYmplY3QsXG4gIGlzU29ydGluZ0Rlc2MsXG4gIG5vcm1hbGl6ZUNvbXBvbmVudCxcbiAgYXNQeCxcbn1cblxuZnVuY3Rpb24gZ2V0IChvYmosIHBhdGgsIGRlZikge1xuICBpZiAoIXBhdGgpIHtcbiAgICByZXR1cm4gb2JqXG4gIH1cbiAgY29uc3QgcGF0aE9iaiA9IG1ha2VQYXRoQXJyYXkocGF0aClcbiAgbGV0IHZhbFxuICB0cnkge1xuICAgIHZhbCA9IHBhdGhPYmoucmVkdWNlKChjdXJyZW50LCBwYXRoUGFydCkgPT4gY3VycmVudFtwYXRoUGFydF0sIG9iailcbiAgfSBjYXRjaCAoZSkge31cbiAgcmV0dXJuIHR5cGVvZiB2YWwgIT09ICd1bmRlZmluZWQnID8gdmFsIDogZGVmXG59XG5cbmZ1bmN0aW9uIHNldCAob2JqID0ge30sIHBhdGgsIHZhbHVlKSB7XG4gIGNvbnN0IGtleXMgPSBtYWtlUGF0aEFycmF5KHBhdGgpXG4gIGxldCBrZXlQYXJ0XG4gIGxldCBjdXJzb3IgPSBvYmpcbiAgd2hpbGUgKChrZXlQYXJ0ID0ga2V5cy5zaGlmdCgpKSAmJiBrZXlzLmxlbmd0aCkge1xuICAgIGlmICghY3Vyc29yW2tleVBhcnRdKSB7XG4gICAgICBjdXJzb3Jba2V5UGFydF0gPSB7fVxuICAgIH1cbiAgICBjdXJzb3IgPSBjdXJzb3Jba2V5UGFydF1cbiAgfVxuICBjdXJzb3Jba2V5UGFydF0gPSB2YWx1ZVxuICByZXR1cm4gb2JqXG59XG5cbmZ1bmN0aW9uIHRha2VSaWdodCAoYXJyLCBuKSB7XG4gIGNvbnN0IHN0YXJ0ID0gbiA+IGFyci5sZW5ndGggPyAwIDogYXJyLmxlbmd0aCAtIG5cbiAgcmV0dXJuIGFyci5zbGljZShzdGFydClcbn1cblxuZnVuY3Rpb24gbGFzdCAoYXJyKSB7XG4gIHJldHVybiBhcnJbYXJyLmxlbmd0aCAtIDFdXG59XG5cbmZ1bmN0aW9uIHJhbmdlIChuKSB7XG4gIGNvbnN0IGFyciA9IFtdXG4gIGZvciAobGV0IGkgPSAwOyBpIDwgbjsgaSsrKSB7XG4gICAgYXJyLnB1c2gobilcbiAgfVxuICByZXR1cm4gYXJyXG59XG5cbmZ1bmN0aW9uIG9yZGVyQnkgKGFyciwgZnVuY3MsIGRpcnMsIGluZGV4S2V5KSB7XG4gIHJldHVybiBhcnIuc29ydCgocm93QSwgcm93QikgPT4ge1xuICAgIGZvciAobGV0IGkgPSAwOyBpIDwgZnVuY3MubGVuZ3RoOyBpKyspIHtcbiAgICAgIGNvbnN0IGNvbXAgPSBmdW5jc1tpXVxuICAgICAgY29uc3QgZGVzYyA9IGRpcnNbaV0gPT09IGZhbHNlIHx8IGRpcnNbaV0gPT09ICdkZXNjJ1xuICAgICAgY29uc3Qgc29ydEludCA9IGNvbXAocm93QSwgcm93QilcbiAgICAgIGlmIChzb3J0SW50KSB7XG4gICAgICAgIHJldHVybiBkZXNjID8gLXNvcnRJbnQgOiBzb3J0SW50XG4gICAgICB9XG4gICAgfVxuICAgIC8vIFVzZSB0aGUgcm93IGluZGV4IGZvciB0aWUgYnJlYWtlcnNcbiAgICByZXR1cm4gZGlyc1swXVxuICAgICAgPyByb3dBW2luZGV4S2V5XSAtIHJvd0JbaW5kZXhLZXldXG4gICAgICA6IHJvd0JbaW5kZXhLZXldIC0gcm93QVtpbmRleEtleV1cbiAgfSlcbn1cblxuZnVuY3Rpb24gcmVtb3ZlIChhLCBiKSB7XG4gIHJldHVybiBhLmZpbHRlcihmdW5jdGlvbiAobywgaSkge1xuICAgIHZhciByID0gYihvKVxuICAgIGlmIChyKSB7XG4gICAgICBhLnNwbGljZShpLCAxKVxuICAgICAgcmV0dXJuIHRydWVcbiAgICB9XG4gICAgcmV0dXJuIGZhbHNlXG4gIH0pXG59XG5cbmZ1bmN0aW9uIGNsb25lIChhKSB7XG4gIHRyeSB7XG4gICAgcmV0dXJuIEpTT04ucGFyc2UoXG4gICAgICBKU09OLnN0cmluZ2lmeShhLCAoa2V5LCB2YWx1ZSkgPT4ge1xuICAgICAgICBpZiAodHlwZW9mIHZhbHVlID09PSAnZnVuY3Rpb24nKSB7XG4gICAgICAgICAgcmV0dXJuIHZhbHVlLnRvU3RyaW5nKClcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gdmFsdWVcbiAgICAgIH0pXG4gICAgKVxuICB9IGNhdGNoIChlKSB7XG4gICAgcmV0dXJuIGFcbiAgfVxufVxuXG5mdW5jdGlvbiBnZXRGaXJzdERlZmluZWQgKC4uLmFyZ3MpIHtcbiAgZm9yICh2YXIgaSA9IDA7IGkgPCBhcmdzLmxlbmd0aDsgaSsrKSB7XG4gICAgaWYgKHR5cGVvZiBhcmdzW2ldICE9PSAndW5kZWZpbmVkJykge1xuICAgICAgcmV0dXJuIGFyZ3NbaV1cbiAgICB9XG4gIH1cbn1cblxuZnVuY3Rpb24gc3VtIChhcnIpIHtcbiAgcmV0dXJuIGFyci5yZWR1Y2UoKGEsIGIpID0+IHtcbiAgICByZXR1cm4gYSArIGJcbiAgfSwgMClcbn1cblxuZnVuY3Rpb24gbWFrZVRlbXBsYXRlQ29tcG9uZW50IChjb21wQ2xhc3MsIGRpc3BsYXlOYW1lKSB7XG4gIGlmICghZGlzcGxheU5hbWUpIHtcbiAgICB0aHJvdyBuZXcgRXJyb3IoJ05vIGRpc3BsYXlOYW1lIGZvdW5kIGZvciB0ZW1wbGF0ZSBjb21wb25lbnQ6JywgY29tcENsYXNzKVxuICB9XG4gIGNvbnN0IGNtcCA9ICh7IGNoaWxkcmVuLCBjbGFzc05hbWUsIC4uLnJlc3QgfSkgPT5cbiAgICA8ZGl2IGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhjb21wQ2xhc3MsIGNsYXNzTmFtZSl9IHsuLi5yZXN0fT5cbiAgICAgIHtjaGlsZHJlbn1cbiAgICA8L2Rpdj5cbiAgY21wLmRpc3BsYXlOYW1lID0gZGlzcGxheU5hbWVcbiAgcmV0dXJuIGNtcFxufVxuXG5mdW5jdGlvbiBncm91cEJ5ICh4cywga2V5KSB7XG4gIHJldHVybiB4cy5yZWR1Y2UoKHJ2LCB4LCBpKSA9PiB7XG4gICAgY29uc3QgcmVzS2V5ID0gdHlwZW9mIGtleSA9PT0gJ2Z1bmN0aW9uJyA/IGtleSh4LCBpKSA6IHhba2V5XVxuICAgIHJ2W3Jlc0tleV0gPSBpc0FycmF5KHJ2W3Jlc0tleV0pID8gcnZbcmVzS2V5XSA6IFtdXG4gICAgcnZbcmVzS2V5XS5wdXNoKHgpXG4gICAgcmV0dXJuIHJ2XG4gIH0sIHt9KVxufVxuXG5mdW5jdGlvbiBhc1B4ICh2YWx1ZSkge1xuICB2YWx1ZSA9IE51bWJlcih2YWx1ZSlcbiAgcmV0dXJuIE51bWJlci5pc05hTih2YWx1ZSkgPyBudWxsIDogdmFsdWUgKyAncHgnXG59XG5cbmZ1bmN0aW9uIGlzQXJyYXkgKGEpIHtcbiAgcmV0dXJuIEFycmF5LmlzQXJyYXkoYSlcbn1cblxuLy8gIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjXG4vLyBOb24tZXhwb3J0ZWQgSGVscGVyc1xuLy8gIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjXG5cbmZ1bmN0aW9uIG1ha2VQYXRoQXJyYXkgKG9iaikge1xuICByZXR1cm4gZmxhdHRlbkRlZXAob2JqKVxuICAgIC5qb2luKCcuJylcbiAgICAucmVwbGFjZSgvXFxbL2csICcuJylcbiAgICAucmVwbGFjZSgvXFxdL2csICcnKVxuICAgIC5zcGxpdCgnLicpXG59XG5cbmZ1bmN0aW9uIGZsYXR0ZW5EZWVwIChhcnIsIG5ld0FyciA9IFtdKSB7XG4gIGlmICghaXNBcnJheShhcnIpKSB7XG4gICAgbmV3QXJyLnB1c2goYXJyKVxuICB9IGVsc2Uge1xuICAgIGZvciAodmFyIGkgPSAwOyBpIDwgYXJyLmxlbmd0aDsgaSsrKSB7XG4gICAgICBmbGF0dGVuRGVlcChhcnJbaV0sIG5ld0FycilcbiAgICB9XG4gIH1cbiAgcmV0dXJuIG5ld0FyclxufVxuXG5mdW5jdGlvbiBzcGxpdFByb3BzICh7IGNsYXNzTmFtZSwgc3R5bGUsIC4uLnJlc3QgfSkge1xuICByZXR1cm4ge1xuICAgIGNsYXNzTmFtZSxcbiAgICBzdHlsZSxcbiAgICByZXN0OiByZXN0IHx8IHt9LFxuICB9XG59XG5cbmZ1bmN0aW9uIGNvbXBhY3RPYmplY3QgKG9iaikge1xuICBjb25zdCBuZXdPYmogPSB7fVxuICBmb3IgKHZhciBrZXkgaW4gb2JqKSB7XG4gICAgaWYgKFxuICAgICAgb2JqLmhhc093blByb3BlcnR5KGtleSkgJiZcbiAgICAgIG9ialtrZXldICE9PSB1bmRlZmluZWQgJiZcbiAgICAgIHR5cGVvZiBvYmpba2V5XSAhPT0gJ3VuZGVmaW5lZCdcbiAgICApIHtcbiAgICAgIG5ld09ialtrZXldID0gb2JqW2tleV1cbiAgICB9XG4gIH1cbiAgcmV0dXJuIG5ld09ialxufVxuXG5mdW5jdGlvbiBpc1NvcnRpbmdEZXNjIChkKSB7XG4gIHJldHVybiAhIShkLnNvcnQgPT09ICdkZXNjJyB8fCBkLmRlc2MgPT09IHRydWUgfHwgZC5hc2MgPT09IGZhbHNlKVxufVxuXG5mdW5jdGlvbiBub3JtYWxpemVDb21wb25lbnQgKENvbXAsIHBhcmFtcyA9IHt9LCBmYWxsYmFjayA9IENvbXApIHtcbiAgcmV0dXJuIHR5cGVvZiBDb21wID09PSAnZnVuY3Rpb24nXG4gICAgPyBPYmplY3QuZ2V0UHJvdG90eXBlT2YoQ29tcCkuaXNSZWFjdENvbXBvbmVudFxuICAgICAgPyA8Q29tcCB7Li4ucGFyYW1zfSAvPlxuICAgICAgOiBDb21wKHBhcmFtcylcbiAgICA6IGZhbGxiYWNrXG59XG4iXX0= - return prevComponent; - }, +/***/ }), +/* 96 */ +/***/ (function(module, exports, __webpack_require__) { - /** - * Render a new component into the DOM. Hooked by hooks! - * - * @param {ReactElement} nextElement element to render - * @param {DOMElement} container container to render into - * @param {boolean} shouldReuseMarkup if we should skip the markup insertion - * @return {ReactComponent} nextComponent - */ - _renderNewRootComponent: function (nextElement, container, shouldReuseMarkup, context) { - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '_renderNewRootComponent(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from ' + 'render is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33); +var secp256k1 = __webpack_require__(168); +var bigi = __webpack_require__(30); +var zcrypto = __webpack_require__(107); +var zconfig = __webpack_require__(66); - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, '_registerComponent(...): Target container is not a DOM element.') : _prodInvariant('37') : void 0; +/* + * Makes a private key + * @param {String} phrase (Password phrase) + * @return {Sting} Private key + */ +function mkPrivKey(phrase) { + return zcrypto.sha256(Buffer.from(phrase, 'utf-8')); +} - ReactBrowserEventEmitter.ensureScrollValueMonitoring(); - var componentInstance = instantiateReactComponent(nextElement, false); +/* + * Converts a private key to WIF format + * @param {String} privKey (private key) + * @param {boolean} toCompressed (Convert to WIF compressed key or nah) + * @param {string} wif (wif hashing bytes (default: 0x80)) + * @return {Sting} WIF format (uncompressed) + */ +function privKeyToWIF(privKey, toCompressed, wif) { + toCompressed = toCompressed || false; + wif = wif || zconfig.mainnet.wif; - // The initial render is synchronous but any updates that happen during - // rendering, in componentWillMount or componentDidMount, will be batched - // according to the current batching strategy. + if (toCompressed) privKey = privKey + '01'; - ReactUpdates.batchedUpdates(batchedMountComponentIntoNode, componentInstance, container, shouldReuseMarkup, context); + return bs58check.encode(Buffer.from(wif + privKey, 'hex')); +} - var wrapperID = componentInstance._instance.rootID; - instancesByReactRootID[wrapperID] = componentInstance; +/* + * Returns private key's public Key + * @param {String} privKey (private key) + * @param {boolean} toCompressed (Convert to public key compressed key or nah) + * @return {Sting} Public Key (default: uncompressed) + */ +function privKeyToPubKey(privKey, toCompressed) { + toCompressed = toCompressed || false; - return componentInstance; - }, + const pkBuffer = Buffer.from(privKey, 'hex'); + var publicKey = secp256k1.publicKeyCreate(pkBuffer, toCompressed); + return publicKey.toString('hex'); +} - /** - * Renders a React component into the DOM in the supplied `container`. - * - * If the React component was previously rendered into `container`, this will - * perform an update on it and only mutate the DOM as necessary to reflect the - * latest React component. - * - * @param {ReactComponent} parentComponent The conceptual parent of this render tree. - * @param {ReactElement} nextElement Component element to render. - * @param {DOMElement} container DOM element to render into. - * @param {?function} callback function triggered on completion - * @return {ReactComponent} Component instance rendered in `container`. - */ - renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { - !(parentComponent != null && ReactInstanceMap.has(parentComponent)) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'parentComponent must be a valid React Component') : _prodInvariant('38') : void 0; - return ReactMount._renderSubtreeIntoContainer(parentComponent, nextElement, container, callback); - }, +/* + * Given a WIF format pk, convert it back to the original pk + * @param {String} privKey (private key) + * @return {Sting} Public Key (uncompressed) + */ +function WIFToPrivKey(wifPk) { + var og = bs58check.decode(wifPk, 'hex').toString('hex'); + og = og.substr(2, og.length); // remove WIF format ('80') - _renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { - ReactUpdateQueue.validateCallback(callback, 'ReactDOM.render'); - !React.isValidElement(nextElement) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOM.render(): Invalid component element.%s', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : // Check if it quacks like an element - nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : _prodInvariant('39', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : void 0; + // remove the '01' at the end to 'compress it' during WIF conversion + if (og.length > 64) { + og = og.substr(0, 64); + } - process.env.NODE_ENV !== 'production' ? warning(!container || !container.tagName || container.tagName.toUpperCase() !== 'BODY', 'render(): Rendering components directly into document.body is ' + 'discouraged, since its children are often manipulated by third-party ' + 'scripts and browser extensions. This may lead to subtle ' + 'reconciliation issues. Try rendering into a container element created ' + 'for your app.') : void 0; + return og; +} - var nextWrappedElement = React.createElement(TopLevelWrapper, { - child: nextElement - }); +/* + * Converts public key to zencash address + * @param {String} pubKey (public key) + * @param {String} pubKeyHash (public key hash (optional, else use defaul)) + * @return {Sting} zencash address + */ +function pubKeyToAddr(pubKey, pubKeyHash) { + pubKeyHash = pubKeyHash || zconfig.mainnet.pubKeyHash; - var nextContext; - if (parentComponent) { - var parentInst = ReactInstanceMap.get(parentComponent); - nextContext = parentInst._processChildContext(parentInst._context); - } else { - nextContext = emptyObject; - } + const hash160 = zcrypto.hash160(Buffer.from(pubKey, 'hex')); + return bs58check.encode(Buffer.from(pubKeyHash + hash160, 'hex')).toString('hex'); +} - var prevComponent = getTopLevelWrapperInContainer(container); +module.exports = { + mkPrivKey: mkPrivKey, + privKeyToWIF: privKeyToWIF, + privKeyToPubKey: privKeyToPubKey, + pubKeyToAddr: pubKeyToAddr, + WIFToPrivKey: WIFToPrivKey +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - if (prevComponent) { - var prevWrappedElement = prevComponent._currentElement; - var prevElement = prevWrappedElement.props.child; - if (shouldUpdateReactComponent(prevElement, nextElement)) { - var publicInst = prevComponent._renderedComponent.getPublicInstance(); - var updatedCallback = callback && function () { - callback.call(publicInst); - }; - ReactMount._updateRootComponent(prevComponent, nextWrappedElement, nextContext, container, updatedCallback); - return publicInst; - } else { - ReactMount.unmountComponentAtNode(container); - } - } - - var reactRootElement = getReactRootElementInContainer(container); - var containerHasReactMarkup = reactRootElement && !!internalGetID(reactRootElement); - var containerHasNonRootReactChild = hasNonRootReactChild(container); - - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, 'render(...): Replacing React-rendered children with a new root ' + 'component. If you intended to update the children of this node, ' + 'you should instead have the existing children update their state ' + 'and render the new components instead of calling ReactDOM.render.') : void 0; - - if (!containerHasReactMarkup || reactRootElement.nextSibling) { - var rootElementSibling = reactRootElement; - while (rootElementSibling) { - if (internalGetID(rootElementSibling)) { - process.env.NODE_ENV !== 'production' ? warning(false, 'render(): Target node has markup rendered by React, but there ' + 'are unrelated nodes as well. This is most commonly caused by ' + 'white-space inserted around server-rendered markup.') : void 0; - break; - } - rootElementSibling = rootElementSibling.nextSibling; - } - } - } +/***/ }), +/* 97 */ +/***/ (function(module, exports, __webpack_require__) { - var shouldReuseMarkup = containerHasReactMarkup && !prevComponent && !containerHasNonRootReactChild; - var component = ReactMount._renderNewRootComponent(nextWrappedElement, container, shouldReuseMarkup, nextContext)._renderedComponent.getPublicInstance(); - if (callback) { - callback.call(component); - } - return component; - }, +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +var inherits = __webpack_require__(4) +var HashBase = __webpack_require__(366) - /** - * Renders a React component into the DOM in the supplied `container`. - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.render - * - * If the React component was previously rendered into `container`, this will - * perform an update on it and only mutate the DOM as necessary to reflect the - * latest React component. - * - * @param {ReactElement} nextElement Component element to render. - * @param {DOMElement} container DOM element to render into. - * @param {?function} callback function triggered on completion - * @return {ReactComponent} Component instance rendered in `container`. - */ - render: function (nextElement, container, callback) { - return ReactMount._renderSubtreeIntoContainer(null, nextElement, container, callback); - }, +function RIPEMD160 () { + HashBase.call(this, 64) - /** - * Unmounts and destroys the React component rendered in the `container`. - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.unmountcomponentatnode - * - * @param {DOMElement} container DOM element containing a React component. - * @return {boolean} True if a component was found in and unmounted from - * `container` - */ - unmountComponentAtNode: function (container) { - // Various parts of our code (such as ReactCompositeComponent's - // _renderValidatedComponent) assume that calls to render aren't nested; - // verify that that's the case. (Strictly speaking, unmounting won't cause a - // render but we still don't expect to be in a render call here.) - process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, 'unmountComponentAtNode(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from render ' + 'is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; + // state + this._a = 0x67452301 + this._b = 0xefcdab89 + this._c = 0x98badcfe + this._d = 0x10325476 + this._e = 0xc3d2e1f0 +} - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'unmountComponentAtNode(...): Target container is not a DOM element.') : _prodInvariant('40') : void 0; +inherits(RIPEMD160, HashBase) - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!nodeIsRenderedByOtherInstance(container), "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by another copy of React.') : void 0; - } +RIPEMD160.prototype._update = function () { + var m = new Array(16) + for (var i = 0; i < 16; ++i) m[i] = this._block.readInt32LE(i * 4) - var prevComponent = getTopLevelWrapperInContainer(container); - if (!prevComponent) { - // Check if the node being unmounted was rendered by React, but isn't a - // root node. - var containerHasNonRootReactChild = hasNonRootReactChild(container); + var al = this._a + var bl = this._b + var cl = this._c + var dl = this._d + var el = this._e - // Check if the container itself is a React root node. - var isContainerReactRoot = container.nodeType === 1 && container.hasAttribute(ROOT_ATTR_NAME); + // Mj = 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 + // K = 0x00000000 + // Sj = 11, 14, 15, 12, 5, 8, 7, 9, 11, 13, 14, 15, 6, 7, 9, 8 + al = fn1(al, bl, cl, dl, el, m[0], 0x00000000, 11); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[1], 0x00000000, 14); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[2], 0x00000000, 15); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[3], 0x00000000, 12); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[4], 0x00000000, 5); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[5], 0x00000000, 8); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[6], 0x00000000, 7); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[7], 0x00000000, 9); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[8], 0x00000000, 11); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[9], 0x00000000, 13); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[10], 0x00000000, 14); cl = rotl(cl, 10) + el = fn1(el, al, bl, cl, dl, m[11], 0x00000000, 15); bl = rotl(bl, 10) + dl = fn1(dl, el, al, bl, cl, m[12], 0x00000000, 6); al = rotl(al, 10) + cl = fn1(cl, dl, el, al, bl, m[13], 0x00000000, 7); el = rotl(el, 10) + bl = fn1(bl, cl, dl, el, al, m[14], 0x00000000, 9); dl = rotl(dl, 10) + al = fn1(al, bl, cl, dl, el, m[15], 0x00000000, 8); cl = rotl(cl, 10) - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by React and is not a top-level container. %s', isContainerReactRoot ? 'You may have accidentally passed in a React root node instead ' + 'of its container.' : 'Instead, have the parent component update its state and ' + 'rerender in order to remove this component.') : void 0; - } + // Mj = 7, 4, 13, 1, 10, 6, 15, 3, 12, 0, 9, 5, 2, 14, 11, 8 + // K = 0x5a827999 + // Sj = 7, 6, 8, 13, 11, 9, 7, 15, 7, 12, 15, 9, 11, 7, 13, 12 + el = fn2(el, al, bl, cl, dl, m[7], 0x5a827999, 7); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[4], 0x5a827999, 6); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[13], 0x5a827999, 8); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[1], 0x5a827999, 13); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[10], 0x5a827999, 11); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[6], 0x5a827999, 9); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[15], 0x5a827999, 7); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[3], 0x5a827999, 15); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[12], 0x5a827999, 7); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[0], 0x5a827999, 12); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[9], 0x5a827999, 15); bl = rotl(bl, 10) + dl = fn2(dl, el, al, bl, cl, m[5], 0x5a827999, 9); al = rotl(al, 10) + cl = fn2(cl, dl, el, al, bl, m[2], 0x5a827999, 11); el = rotl(el, 10) + bl = fn2(bl, cl, dl, el, al, m[14], 0x5a827999, 7); dl = rotl(dl, 10) + al = fn2(al, bl, cl, dl, el, m[11], 0x5a827999, 13); cl = rotl(cl, 10) + el = fn2(el, al, bl, cl, dl, m[8], 0x5a827999, 12); bl = rotl(bl, 10) - return false; - } - delete instancesByReactRootID[prevComponent._instance.rootID]; - ReactUpdates.batchedUpdates(unmountComponentFromNode, prevComponent, container, false); - return true; - }, + // Mj = 3, 10, 14, 4, 9, 15, 8, 1, 2, 7, 0, 6, 13, 11, 5, 12 + // K = 0x6ed9eba1 + // Sj = 11, 13, 6, 7, 14, 9, 13, 15, 14, 8, 13, 6, 5, 12, 7, 5 + dl = fn3(dl, el, al, bl, cl, m[3], 0x6ed9eba1, 11); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[10], 0x6ed9eba1, 13); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[14], 0x6ed9eba1, 6); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[4], 0x6ed9eba1, 7); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[9], 0x6ed9eba1, 14); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[15], 0x6ed9eba1, 9); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[8], 0x6ed9eba1, 13); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[1], 0x6ed9eba1, 15); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[2], 0x6ed9eba1, 14); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[7], 0x6ed9eba1, 8); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[0], 0x6ed9eba1, 13); al = rotl(al, 10) + cl = fn3(cl, dl, el, al, bl, m[6], 0x6ed9eba1, 6); el = rotl(el, 10) + bl = fn3(bl, cl, dl, el, al, m[13], 0x6ed9eba1, 5); dl = rotl(dl, 10) + al = fn3(al, bl, cl, dl, el, m[11], 0x6ed9eba1, 12); cl = rotl(cl, 10) + el = fn3(el, al, bl, cl, dl, m[5], 0x6ed9eba1, 7); bl = rotl(bl, 10) + dl = fn3(dl, el, al, bl, cl, m[12], 0x6ed9eba1, 5); al = rotl(al, 10) - _mountImageIntoNode: function (markup, container, instance, shouldReuseMarkup, transaction) { - !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'mountComponentIntoNode(...): Target container is not valid.') : _prodInvariant('41') : void 0; + // Mj = 1, 9, 11, 10, 0, 8, 12, 4, 13, 3, 7, 15, 14, 5, 6, 2 + // K = 0x8f1bbcdc + // Sj = 11, 12, 14, 15, 14, 15, 9, 8, 9, 14, 5, 6, 8, 6, 5, 12 + cl = fn4(cl, dl, el, al, bl, m[1], 0x8f1bbcdc, 11); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[9], 0x8f1bbcdc, 12); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[11], 0x8f1bbcdc, 14); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[10], 0x8f1bbcdc, 15); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[0], 0x8f1bbcdc, 14); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[8], 0x8f1bbcdc, 15); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[12], 0x8f1bbcdc, 9); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[4], 0x8f1bbcdc, 8); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[13], 0x8f1bbcdc, 9); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[3], 0x8f1bbcdc, 14); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[7], 0x8f1bbcdc, 5); el = rotl(el, 10) + bl = fn4(bl, cl, dl, el, al, m[15], 0x8f1bbcdc, 6); dl = rotl(dl, 10) + al = fn4(al, bl, cl, dl, el, m[14], 0x8f1bbcdc, 8); cl = rotl(cl, 10) + el = fn4(el, al, bl, cl, dl, m[5], 0x8f1bbcdc, 6); bl = rotl(bl, 10) + dl = fn4(dl, el, al, bl, cl, m[6], 0x8f1bbcdc, 5); al = rotl(al, 10) + cl = fn4(cl, dl, el, al, bl, m[2], 0x8f1bbcdc, 12); el = rotl(el, 10) - if (shouldReuseMarkup) { - var rootElement = getReactRootElementInContainer(container); - if (ReactMarkupChecksum.canReuseMarkup(markup, rootElement)) { - ReactDOMComponentTree.precacheNode(instance, rootElement); - return; - } else { - var checksum = rootElement.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); - rootElement.removeAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + // Mj = 4, 0, 5, 9, 7, 12, 2, 10, 14, 1, 3, 8, 11, 6, 15, 13 + // K = 0xa953fd4e + // Sj = 9, 15, 5, 11, 6, 8, 13, 12, 5, 12, 13, 14, 11, 8, 5, 6 + bl = fn5(bl, cl, dl, el, al, m[4], 0xa953fd4e, 9); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[0], 0xa953fd4e, 15); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[5], 0xa953fd4e, 5); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[9], 0xa953fd4e, 11); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[7], 0xa953fd4e, 6); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[12], 0xa953fd4e, 8); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[2], 0xa953fd4e, 13); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[10], 0xa953fd4e, 12); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[14], 0xa953fd4e, 5); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[1], 0xa953fd4e, 12); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[3], 0xa953fd4e, 13); dl = rotl(dl, 10) + al = fn5(al, bl, cl, dl, el, m[8], 0xa953fd4e, 14); cl = rotl(cl, 10) + el = fn5(el, al, bl, cl, dl, m[11], 0xa953fd4e, 11); bl = rotl(bl, 10) + dl = fn5(dl, el, al, bl, cl, m[6], 0xa953fd4e, 8); al = rotl(al, 10) + cl = fn5(cl, dl, el, al, bl, m[15], 0xa953fd4e, 5); el = rotl(el, 10) + bl = fn5(bl, cl, dl, el, al, m[13], 0xa953fd4e, 6); dl = rotl(dl, 10) - var rootMarkup = rootElement.outerHTML; - rootElement.setAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME, checksum); + var ar = this._a + var br = this._b + var cr = this._c + var dr = this._d + var er = this._e - var normalizedMarkup = markup; - if (process.env.NODE_ENV !== 'production') { - // because rootMarkup is retrieved from the DOM, various normalizations - // will have occurred which will not be present in `markup`. Here, - // insert markup into a <div> or <iframe> depending on the container - // type to perform the same normalizations before comparing. - var normalizer; - if (container.nodeType === ELEMENT_NODE_TYPE) { - normalizer = document.createElement('div'); - normalizer.innerHTML = markup; - normalizedMarkup = normalizer.innerHTML; - } else { - normalizer = document.createElement('iframe'); - document.body.appendChild(normalizer); - normalizer.contentDocument.write(markup); - normalizedMarkup = normalizer.contentDocument.documentElement.outerHTML; - document.body.removeChild(normalizer); - } - } + // M'j = 5, 14, 7, 0, 9, 2, 11, 4, 13, 6, 15, 8, 1, 10, 3, 12 + // K' = 0x50a28be6 + // S'j = 8, 9, 9, 11, 13, 15, 15, 5, 7, 7, 8, 11, 14, 14, 12, 6 + ar = fn5(ar, br, cr, dr, er, m[5], 0x50a28be6, 8); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[14], 0x50a28be6, 9); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[7], 0x50a28be6, 9); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[0], 0x50a28be6, 11); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[9], 0x50a28be6, 13); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[2], 0x50a28be6, 15); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[11], 0x50a28be6, 15); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[4], 0x50a28be6, 5); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[13], 0x50a28be6, 7); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[6], 0x50a28be6, 7); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[15], 0x50a28be6, 8); cr = rotl(cr, 10) + er = fn5(er, ar, br, cr, dr, m[8], 0x50a28be6, 11); br = rotl(br, 10) + dr = fn5(dr, er, ar, br, cr, m[1], 0x50a28be6, 14); ar = rotl(ar, 10) + cr = fn5(cr, dr, er, ar, br, m[10], 0x50a28be6, 14); er = rotl(er, 10) + br = fn5(br, cr, dr, er, ar, m[3], 0x50a28be6, 12); dr = rotl(dr, 10) + ar = fn5(ar, br, cr, dr, er, m[12], 0x50a28be6, 6); cr = rotl(cr, 10) - var diffIndex = firstDifferenceIndex(normalizedMarkup, rootMarkup); - var difference = ' (client) ' + normalizedMarkup.substring(diffIndex - 20, diffIndex + 20) + '\n (server) ' + rootMarkup.substring(diffIndex - 20, diffIndex + 20); + // M'j = 6, 11, 3, 7, 0, 13, 5, 10, 14, 15, 8, 12, 4, 9, 1, 2 + // K' = 0x5c4dd124 + // S'j = 9, 13, 15, 7, 12, 8, 9, 11, 7, 7, 12, 7, 6, 15, 13, 11 + er = fn4(er, ar, br, cr, dr, m[6], 0x5c4dd124, 9); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[11], 0x5c4dd124, 13); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[3], 0x5c4dd124, 15); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[7], 0x5c4dd124, 7); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[0], 0x5c4dd124, 12); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[13], 0x5c4dd124, 8); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[5], 0x5c4dd124, 9); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[10], 0x5c4dd124, 11); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[14], 0x5c4dd124, 7); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[15], 0x5c4dd124, 7); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[8], 0x5c4dd124, 12); br = rotl(br, 10) + dr = fn4(dr, er, ar, br, cr, m[12], 0x5c4dd124, 7); ar = rotl(ar, 10) + cr = fn4(cr, dr, er, ar, br, m[4], 0x5c4dd124, 6); er = rotl(er, 10) + br = fn4(br, cr, dr, er, ar, m[9], 0x5c4dd124, 15); dr = rotl(dr, 10) + ar = fn4(ar, br, cr, dr, er, m[1], 0x5c4dd124, 13); cr = rotl(cr, 10) + er = fn4(er, ar, br, cr, dr, m[2], 0x5c4dd124, 11); br = rotl(br, 10) - !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document using server rendering but the checksum was invalid. This usually means you rendered a different component type or props on the client from the one on the server, or your render() methods are impure. React cannot handle this case due to cross-browser quirks by rendering at the document root. You should look for environment dependent code in your components and ensure the props are the same client and server side:\n%s', difference) : _prodInvariant('42', difference) : void 0; + // M'j = 15, 5, 1, 3, 7, 14, 6, 9, 11, 8, 12, 2, 10, 0, 4, 13 + // K' = 0x6d703ef3 + // S'j = 9, 7, 15, 11, 8, 6, 6, 14, 12, 13, 5, 14, 13, 13, 7, 5 + dr = fn3(dr, er, ar, br, cr, m[15], 0x6d703ef3, 9); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[5], 0x6d703ef3, 7); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[1], 0x6d703ef3, 15); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[3], 0x6d703ef3, 11); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[7], 0x6d703ef3, 8); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[14], 0x6d703ef3, 6); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[6], 0x6d703ef3, 6); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[9], 0x6d703ef3, 14); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[11], 0x6d703ef3, 12); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[8], 0x6d703ef3, 13); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[12], 0x6d703ef3, 5); ar = rotl(ar, 10) + cr = fn3(cr, dr, er, ar, br, m[2], 0x6d703ef3, 14); er = rotl(er, 10) + br = fn3(br, cr, dr, er, ar, m[10], 0x6d703ef3, 13); dr = rotl(dr, 10) + ar = fn3(ar, br, cr, dr, er, m[0], 0x6d703ef3, 13); cr = rotl(cr, 10) + er = fn3(er, ar, br, cr, dr, m[4], 0x6d703ef3, 7); br = rotl(br, 10) + dr = fn3(dr, er, ar, br, cr, m[13], 0x6d703ef3, 5); ar = rotl(ar, 10) - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(false, 'React attempted to reuse markup in a container but the ' + 'checksum was invalid. This generally means that you are ' + 'using server rendering and the markup generated on the ' + 'server was not what the client was expecting. React injected ' + 'new markup to compensate which works but you have lost many ' + 'of the benefits of server rendering. Instead, figure out ' + 'why the markup being generated is different on the client ' + 'or server:\n%s', difference) : void 0; - } - } - } + // M'j = 8, 6, 4, 1, 3, 11, 15, 0, 5, 12, 2, 13, 9, 7, 10, 14 + // K' = 0x7a6d76e9 + // S'j = 15, 5, 8, 11, 14, 14, 6, 14, 6, 9, 12, 9, 12, 5, 15, 8 + cr = fn2(cr, dr, er, ar, br, m[8], 0x7a6d76e9, 15); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[6], 0x7a6d76e9, 5); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[4], 0x7a6d76e9, 8); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[1], 0x7a6d76e9, 11); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[3], 0x7a6d76e9, 14); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[11], 0x7a6d76e9, 14); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[15], 0x7a6d76e9, 6); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[0], 0x7a6d76e9, 14); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[5], 0x7a6d76e9, 6); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[12], 0x7a6d76e9, 9); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[2], 0x7a6d76e9, 12); er = rotl(er, 10) + br = fn2(br, cr, dr, er, ar, m[13], 0x7a6d76e9, 9); dr = rotl(dr, 10) + ar = fn2(ar, br, cr, dr, er, m[9], 0x7a6d76e9, 12); cr = rotl(cr, 10) + er = fn2(er, ar, br, cr, dr, m[7], 0x7a6d76e9, 5); br = rotl(br, 10) + dr = fn2(dr, er, ar, br, cr, m[10], 0x7a6d76e9, 15); ar = rotl(ar, 10) + cr = fn2(cr, dr, er, ar, br, m[14], 0x7a6d76e9, 8); er = rotl(er, 10) - !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document but you didn\'t use server rendering. We can\'t do this without using server rendering due to cross-browser quirks. See ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('43') : void 0; + // M'j = 12, 15, 10, 4, 1, 5, 8, 7, 6, 2, 13, 14, 0, 3, 9, 11 + // K' = 0x00000000 + // S'j = 8, 5, 12, 9, 12, 5, 14, 6, 8, 13, 6, 5, 15, 13, 11, 11 + br = fn1(br, cr, dr, er, ar, m[12], 0x00000000, 8); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[15], 0x00000000, 5); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[10], 0x00000000, 12); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[4], 0x00000000, 9); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[1], 0x00000000, 12); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[5], 0x00000000, 5); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[8], 0x00000000, 14); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[7], 0x00000000, 6); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[6], 0x00000000, 8); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[2], 0x00000000, 13); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[13], 0x00000000, 6); dr = rotl(dr, 10) + ar = fn1(ar, br, cr, dr, er, m[14], 0x00000000, 5); cr = rotl(cr, 10) + er = fn1(er, ar, br, cr, dr, m[0], 0x00000000, 15); br = rotl(br, 10) + dr = fn1(dr, er, ar, br, cr, m[3], 0x00000000, 13); ar = rotl(ar, 10) + cr = fn1(cr, dr, er, ar, br, m[9], 0x00000000, 11); er = rotl(er, 10) + br = fn1(br, cr, dr, er, ar, m[11], 0x00000000, 11); dr = rotl(dr, 10) - if (transaction.useCreateElement) { - while (container.lastChild) { - container.removeChild(container.lastChild); - } - DOMLazyTree.insertTreeBefore(container, markup, null); - } else { - setInnerHTML(container, markup); - ReactDOMComponentTree.precacheNode(instance, container.firstChild); - } + // change state + var t = (this._b + cl + dr) | 0 + this._b = (this._c + dl + er) | 0 + this._c = (this._d + el + ar) | 0 + this._d = (this._e + al + br) | 0 + this._e = (this._a + bl + cr) | 0 + this._a = t +} - if (process.env.NODE_ENV !== 'production') { - var hostNode = ReactDOMComponentTree.getInstanceFromNode(container.firstChild); - if (hostNode._debugID !== 0) { - ReactInstrumentation.debugTool.onHostOperation({ - instanceID: hostNode._debugID, - type: 'mount', - payload: markup.toString() - }); - } - } +RIPEMD160.prototype._digest = function () { + // create padding and handle blocks + this._block[this._blockOffset++] = 0x80 + if (this._blockOffset > 56) { + this._block.fill(0, this._blockOffset, 64) + this._update() + this._blockOffset = 0 } -}; - -module.exports = ReactMount; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -/***/ }), -/* 105 */ -/***/ (function(module, exports, __webpack_require__) { + this._block.fill(0, this._blockOffset, 56) + this._block.writeUInt32LE(this._length[0], 56) + this._block.writeUInt32LE(this._length[1], 60) + this._update() -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // produce result + var buffer = new Buffer(20) + buffer.writeInt32LE(this._a, 0) + buffer.writeInt32LE(this._b, 4) + buffer.writeInt32LE(this._c, 8) + buffer.writeInt32LE(this._d, 12) + buffer.writeInt32LE(this._e, 16) + return buffer +} +function rotl (x, n) { + return (x << n) | (x >>> (32 - n)) +} +function fn1 (a, b, c, d, e, m, k, s) { + return (rotl((a + (b ^ c ^ d) + m + k) | 0, s) + e) | 0 +} -var ReactNodeTypes = __webpack_require__(97); +function fn2 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b & c) | ((~b) & d)) + m + k) | 0, s) + e) | 0 +} -function getHostComponentFromComposite(inst) { - var type; +function fn3 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b | (~c)) ^ d) + m + k) | 0, s) + e) | 0 +} - while ((type = inst._renderedNodeType) === ReactNodeTypes.COMPOSITE) { - inst = inst._renderedComponent; - } +function fn4 (a, b, c, d, e, m, k, s) { + return (rotl((a + ((b & d) | (c & (~d))) + m + k) | 0, s) + e) | 0 +} - if (type === ReactNodeTypes.HOST) { - return inst._renderedComponent; - } else if (type === ReactNodeTypes.EMPTY) { - return null; - } +function fn5 (a, b, c, d, e, m, k, s) { + return (rotl((a + (b ^ (c | (~d))) + m + k) | 0, s) + e) | 0 } -module.exports = getHostComponentFromComposite; +module.exports = RIPEMD160 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 106 */ +/* 98 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. -exports.__esModule = true; +module.exports = Stream; -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +var EE = __webpack_require__(99).EventEmitter; +var inherits = __webpack_require__(4); -var _chainFunction = __webpack_require__(228); +inherits(Stream, EE); +Stream.Readable = __webpack_require__(100); +Stream.Writable = __webpack_require__(372); +Stream.Duplex = __webpack_require__(373); +Stream.Transform = __webpack_require__(374); +Stream.PassThrough = __webpack_require__(375); -var _chainFunction2 = _interopRequireDefault(_chainFunction); +// Backwards-compat with node 0.4.x +Stream.Stream = Stream; -var _react = __webpack_require__(4); -var _react2 = _interopRequireDefault(_react); -var _propTypes = __webpack_require__(9); +// old-style streams. Note that the pipe method (the only relevant +// part of this class) is overridden in the Readable class. -var _propTypes2 = _interopRequireDefault(_propTypes); +function Stream() { + EE.call(this); +} -var _warning = __webpack_require__(229); +Stream.prototype.pipe = function(dest, options) { + var source = this; -var _warning2 = _interopRequireDefault(_warning); + function ondata(chunk) { + if (dest.writable) { + if (false === dest.write(chunk) && source.pause) { + source.pause(); + } + } + } -var _ChildMapping = __webpack_require__(230); + source.on('data', ondata); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + function ondrain() { + if (source.readable && source.resume) { + source.resume(); + } + } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + dest.on('drain', ondrain); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + // If the 'end' option is not supplied, dest.end() will be called when + // source gets the 'end' or 'close' events. Only dest.end() once. + if (!dest._isStdio && (!options || options.end !== false)) { + source.on('end', onend); + source.on('close', onclose); + } -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + var didOnEnd = false; + function onend() { + if (didOnEnd) return; + didOnEnd = true; -var propTypes = { - component: _propTypes2.default.any, - childFactory: _propTypes2.default.func, - children: _propTypes2.default.node -}; + dest.end(); + } -var defaultProps = { - component: 'span', - childFactory: function childFactory(child) { - return child; + + function onclose() { + if (didOnEnd) return; + didOnEnd = true; + + if (typeof dest.destroy === 'function') dest.destroy(); } -}; -var TransitionGroup = function (_React$Component) { - _inherits(TransitionGroup, _React$Component); + // don't leave dangling pipes when there are errors. + function onerror(er) { + cleanup(); + if (EE.listenerCount(this, 'error') === 0) { + throw er; // Unhandled stream error in pipe. + } + } - function TransitionGroup(props, context) { - _classCallCheck(this, TransitionGroup); + source.on('error', onerror); + dest.on('error', onerror); - var _this = _possibleConstructorReturn(this, _React$Component.call(this, props, context)); + // remove all the event listeners that were added. + function cleanup() { + source.removeListener('data', ondata); + dest.removeListener('drain', ondrain); - _this.performAppear = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; + source.removeListener('end', onend); + source.removeListener('close', onclose); - if (component.componentWillAppear) { - component.componentWillAppear(_this._handleDoneAppearing.bind(_this, key, component)); - } else { - _this._handleDoneAppearing(key, component); - } - }; + source.removeListener('error', onerror); + dest.removeListener('error', onerror); - _this._handleDoneAppearing = function (key, component) { - if (component.componentDidAppear) { - component.componentDidAppear(); - } + source.removeListener('end', cleanup); + source.removeListener('close', cleanup); - delete _this.currentlyTransitioningKeys[key]; + dest.removeListener('close', cleanup); + } - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); + source.on('end', cleanup); + source.on('close', cleanup); - if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { - // This was removed before it had fully appeared. Remove it. - _this.performLeave(key, component); - } - }; + dest.on('close', cleanup); - _this.performEnter = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; + dest.emit('pipe', source); - if (component.componentWillEnter) { - component.componentWillEnter(_this._handleDoneEntering.bind(_this, key, component)); - } else { - _this._handleDoneEntering(key, component); - } - }; + // Allow for unix-like usage: A.pipe(B).pipe(C) + return dest; +}; - _this._handleDoneEntering = function (key, component) { - if (component.componentDidEnter) { - component.componentDidEnter(); - } - delete _this.currentlyTransitioningKeys[key]; +/***/ }), +/* 99 */ +/***/ (function(module, exports) { - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. - if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { - // This was removed before it had fully entered. Remove it. - _this.performLeave(key, component); - } - }; +function EventEmitter() { + this._events = this._events || {}; + this._maxListeners = this._maxListeners || undefined; +} +module.exports = EventEmitter; - _this.performLeave = function (key, component) { - _this.currentlyTransitioningKeys[key] = true; +// Backwards-compat with node 0.10.x +EventEmitter.EventEmitter = EventEmitter; - if (component.componentWillLeave) { - component.componentWillLeave(_this._handleDoneLeaving.bind(_this, key, component)); - } else { - // Note that this is somewhat dangerous b/c it calls setState() - // again, effectively mutating the component before all the work - // is done. - _this._handleDoneLeaving(key, component); - } - }; +EventEmitter.prototype._events = undefined; +EventEmitter.prototype._maxListeners = undefined; - _this._handleDoneLeaving = function (key, component) { - if (component.componentDidLeave) { - component.componentDidLeave(); - } +// By default EventEmitters will print a warning if more than 10 listeners are +// added to it. This is a useful default which helps finding memory leaks. +EventEmitter.defaultMaxListeners = 10; - delete _this.currentlyTransitioningKeys[key]; +// Obviously not all Emitters should be limited to 10. This function allows +// that to be increased. Set to zero for unlimited. +EventEmitter.prototype.setMaxListeners = function(n) { + if (!isNumber(n) || n < 0 || isNaN(n)) + throw TypeError('n must be a positive number'); + this._maxListeners = n; + return this; +}; - var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); +EventEmitter.prototype.emit = function(type) { + var er, handler, len, args, i, listeners; - if (currentChildMapping && currentChildMapping.hasOwnProperty(key)) { - // This entered again before it fully left. Add it again. - _this.keysToEnter.push(key); + if (!this._events) + this._events = {}; + + // If there is no 'error' event listener then throw. + if (type === 'error') { + if (!this._events.error || + (isObject(this._events.error) && !this._events.error.length)) { + er = arguments[1]; + if (er instanceof Error) { + throw er; // Unhandled 'error' event } else { - _this.setState(function (state) { - var newChildren = _extends({}, state.children); - delete newChildren[key]; - return { children: newChildren }; - }); + // At least give some kind of context to the user + var err = new Error('Uncaught, unspecified "error" event. (' + er + ')'); + err.context = er; + throw err; } - }; + } + } - _this.childRefs = Object.create(null); + handler = this._events[type]; - _this.state = { - children: (0, _ChildMapping.getChildMapping)(props.children) - }; - return _this; + if (isUndefined(handler)) + return false; + + if (isFunction(handler)) { + switch (arguments.length) { + // fast cases + case 1: + handler.call(this); + break; + case 2: + handler.call(this, arguments[1]); + break; + case 3: + handler.call(this, arguments[1], arguments[2]); + break; + // slower + default: + args = Array.prototype.slice.call(arguments, 1); + handler.apply(this, args); + } + } else if (isObject(handler)) { + args = Array.prototype.slice.call(arguments, 1); + listeners = handler.slice(); + len = listeners.length; + for (i = 0; i < len; i++) + listeners[i].apply(this, args); } - TransitionGroup.prototype.componentWillMount = function componentWillMount() { - this.currentlyTransitioningKeys = {}; - this.keysToEnter = []; - this.keysToLeave = []; - }; + return true; +}; - TransitionGroup.prototype.componentDidMount = function componentDidMount() { - var initialChildMapping = this.state.children; - for (var key in initialChildMapping) { - if (initialChildMapping[key]) { - this.performAppear(key, this.childRefs[key]); - } - } - }; +EventEmitter.prototype.addListener = function(type, listener) { + var m; - TransitionGroup.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { - var nextChildMapping = (0, _ChildMapping.getChildMapping)(nextProps.children); - var prevChildMapping = this.state.children; + if (!isFunction(listener)) + throw TypeError('listener must be a function'); - this.setState({ - children: (0, _ChildMapping.mergeChildMappings)(prevChildMapping, nextChildMapping) - }); + if (!this._events) + this._events = {}; - for (var key in nextChildMapping) { - var hasPrev = prevChildMapping && prevChildMapping.hasOwnProperty(key); - if (nextChildMapping[key] && !hasPrev && !this.currentlyTransitioningKeys[key]) { - this.keysToEnter.push(key); - } + // To avoid recursion in the case that type === "newListener"! Before + // adding it to the listeners, first emit "newListener". + if (this._events.newListener) + this.emit('newListener', type, + isFunction(listener.listener) ? + listener.listener : listener); + + if (!this._events[type]) + // Optimize the case of one listener. Don't need the extra array object. + this._events[type] = listener; + else if (isObject(this._events[type])) + // If we've already got an array, just append. + this._events[type].push(listener); + else + // Adding the second element, need to change to array. + this._events[type] = [this._events[type], listener]; + + // Check for listener leak + if (isObject(this._events[type]) && !this._events[type].warned) { + if (!isUndefined(this._maxListeners)) { + m = this._maxListeners; + } else { + m = EventEmitter.defaultMaxListeners; } - for (var _key in prevChildMapping) { - var hasNext = nextChildMapping && nextChildMapping.hasOwnProperty(_key); - if (prevChildMapping[_key] && !hasNext && !this.currentlyTransitioningKeys[_key]) { - this.keysToLeave.push(_key); + if (m && m > 0 && this._events[type].length > m) { + this._events[type].warned = true; + console.error('(node) warning: possible EventEmitter memory ' + + 'leak detected. %d listeners added. ' + + 'Use emitter.setMaxListeners() to increase limit.', + this._events[type].length); + if (typeof console.trace === 'function') { + // not supported in IE 10 + console.trace(); } } + } - // If we want to someday check for reordering, we could do it here. - }; - - TransitionGroup.prototype.componentDidUpdate = function componentDidUpdate() { - var _this2 = this; - - var keysToEnter = this.keysToEnter; - this.keysToEnter = []; - keysToEnter.forEach(function (key) { - return _this2.performEnter(key, _this2.childRefs[key]); - }); + return this; +}; - var keysToLeave = this.keysToLeave; - this.keysToLeave = []; - keysToLeave.forEach(function (key) { - return _this2.performLeave(key, _this2.childRefs[key]); - }); - }; +EventEmitter.prototype.on = EventEmitter.prototype.addListener; - TransitionGroup.prototype.render = function render() { - var _this3 = this; +EventEmitter.prototype.once = function(type, listener) { + if (!isFunction(listener)) + throw TypeError('listener must be a function'); - // TODO: we could get rid of the need for the wrapper node - // by cloning a single child - var childrenToRender = []; + var fired = false; - var _loop = function _loop(key) { - var child = _this3.state.children[key]; - if (child) { - var isCallbackRef = typeof child.ref !== 'string'; - var factoryChild = _this3.props.childFactory(child); - var ref = function ref(r) { - _this3.childRefs[key] = r; - }; + function g() { + this.removeListener(type, g); - process.env.NODE_ENV !== 'production' ? (0, _warning2.default)(isCallbackRef, 'string refs are not supported on children of TransitionGroup and will be ignored. ' + 'Please use a callback ref instead: https://facebook.github.io/react/docs/refs-and-the-dom.html#the-ref-callback-attribute') : void 0; + if (!fired) { + fired = true; + listener.apply(this, arguments); + } + } - // Always chaining the refs leads to problems when the childFactory - // wraps the child. The child ref callback gets called twice with the - // wrapper and the child. So we only need to chain the ref if the - // factoryChild is not different from child. - if (factoryChild === child && isCallbackRef) { - ref = (0, _chainFunction2.default)(child.ref, ref); - } + g.listener = listener; + this.on(type, g); - // You may need to apply reactive updates to a child as it is leaving. - // The normal React way to do it won't work since the child will have - // already been removed. In case you need this behavior you can provide - // a childFactory function to wrap every child, even the ones that are - // leaving. - childrenToRender.push(_react2.default.cloneElement(factoryChild, { - key: key, - ref: ref - })); - } - }; + return this; +}; - for (var key in this.state.children) { - _loop(key); - } +// emits a 'removeListener' event iff the listener was removed +EventEmitter.prototype.removeListener = function(type, listener) { + var list, position, length, i; - // Do not forward TransitionGroup props to primitive DOM nodes - var props = _extends({}, this.props); - delete props.transitionLeave; - delete props.transitionName; - delete props.transitionAppear; - delete props.transitionEnter; - delete props.childFactory; - delete props.transitionLeaveTimeout; - delete props.transitionEnterTimeout; - delete props.transitionAppearTimeout; - delete props.component; + if (!isFunction(listener)) + throw TypeError('listener must be a function'); - return _react2.default.createElement(this.props.component, props, childrenToRender); - }; + if (!this._events || !this._events[type]) + return this; - return TransitionGroup; -}(_react2.default.Component); + list = this._events[type]; + length = list.length; + position = -1; -TransitionGroup.displayName = 'TransitionGroup'; + if (list === listener || + (isFunction(list.listener) && list.listener === listener)) { + delete this._events[type]; + if (this._events.removeListener) + this.emit('removeListener', type, listener); + } else if (isObject(list)) { + for (i = length; i-- > 0;) { + if (list[i] === listener || + (list[i].listener && list[i].listener === listener)) { + position = i; + break; + } + } -TransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; -TransitionGroup.defaultProps = defaultProps; + if (position < 0) + return this; -exports.default = TransitionGroup; -module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + if (list.length === 1) { + list.length = 0; + delete this._events[type]; + } else { + list.splice(position, 1); + } -/***/ }), -/* 107 */ -/***/ (function(module, exports, __webpack_require__) { + if (this._events.removeListener) + this.emit('removeListener', type, listener); + } -"use strict"; + return this; +}; +EventEmitter.prototype.removeAllListeners = function(type) { + var key, listeners; -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.default = !!(typeof window !== 'undefined' && window.document && window.document.createElement); -module.exports = exports['default']; + if (!this._events) + return this; -/***/ }), -/* 108 */ -/***/ (function(module, exports, __webpack_require__) { + // not listening for removeListener, no need to emit + if (!this._events.removeListener) { + if (arguments.length === 0) + this._events = {}; + else if (this._events[type]) + delete this._events[type]; + return this; + } -"use strict"; + // emit removeListener for all listeners on all events + if (arguments.length === 0) { + for (key in this._events) { + if (key === 'removeListener') continue; + this.removeAllListeners(key); + } + this.removeAllListeners('removeListener'); + this._events = {}; + return this; + } + listeners = this._events[type]; -exports.__esModule = true; -exports.nameShape = undefined; -exports.transitionTimeout = transitionTimeout; + if (isFunction(listeners)) { + this.removeListener(type, listeners); + } else if (listeners) { + // LIFO order + while (listeners.length) + this.removeListener(type, listeners[listeners.length - 1]); + } + delete this._events[type]; -var _react = __webpack_require__(4); + return this; +}; -var _react2 = _interopRequireDefault(_react); +EventEmitter.prototype.listeners = function(type) { + var ret; + if (!this._events || !this._events[type]) + ret = []; + else if (isFunction(this._events[type])) + ret = [this._events[type]]; + else + ret = this._events[type].slice(); + return ret; +}; -var _propTypes = __webpack_require__(9); +EventEmitter.prototype.listenerCount = function(type) { + if (this._events) { + var evlistener = this._events[type]; -var _propTypes2 = _interopRequireDefault(_propTypes); + if (isFunction(evlistener)) + return 1; + else if (evlistener) + return evlistener.length; + } + return 0; +}; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +EventEmitter.listenerCount = function(emitter, type) { + return emitter.listenerCount(type); +}; -function transitionTimeout(transitionType) { - var timeoutPropName = 'transition' + transitionType + 'Timeout'; - var enabledPropName = 'transition' + transitionType; +function isFunction(arg) { + return typeof arg === 'function'; +} - return function (props) { - // If the transition is enabled - if (props[enabledPropName]) { - // If no timeout duration is provided - if (props[timeoutPropName] == null) { - return new Error(timeoutPropName + ' wasn\'t supplied to CSSTransitionGroup: ' + 'this can cause unreliable animations and won\'t be supported in ' + 'a future version of React. See ' + 'https://fb.me/react-animation-transition-group-timeout for more ' + 'information.'); +function isNumber(arg) { + return typeof arg === 'number'; +} - // If the duration isn't a number - } else if (typeof props[timeoutPropName] !== 'number') { - return new Error(timeoutPropName + ' must be a number (in milliseconds)'); - } - } +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} - return null; - }; +function isUndefined(arg) { + return arg === void 0; } -var nameShape = exports.nameShape = _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.shape({ - enter: _propTypes2.default.string, - leave: _propTypes2.default.string, - active: _propTypes2.default.string -}), _propTypes2.default.shape({ - enter: _propTypes2.default.string, - enterActive: _propTypes2.default.string, - leave: _propTypes2.default.string, - leaveActive: _propTypes2.default.string, - appear: _propTypes2.default.string, - appearActive: _propTypes2.default.string -})]); /***/ }), -/* 109 */ -/***/ (function(module, exports, __webpack_require__) { - -var Buffer = __webpack_require__(18).Buffer -var Transform = __webpack_require__(261).Transform -var StringDecoder = __webpack_require__(264).StringDecoder -var inherits = __webpack_require__(11) - -function CipherBase (hashMode) { - Transform.call(this) - this.hashMode = typeof hashMode === 'string' - if (this.hashMode) { - this[hashMode] = this._finalOrDigest - } else { - this.final = this._finalOrDigest - } - if (this._final) { - this.__final = this._final - this._final = null - } - this._decoder = null - this._encoding = null -} -inherits(CipherBase, Transform) - -CipherBase.prototype.update = function (data, inputEnc, outputEnc) { - if (typeof data === 'string') { - data = Buffer.from(data, inputEnc) - } - - var outData = this._update(data) - if (this.hashMode) return this - - if (outputEnc) { - outData = this._toString(outData, outputEnc) - } - - return outData -} - -CipherBase.prototype.setAutoPadding = function () {} -CipherBase.prototype.getAuthTag = function () { - throw new Error('trying to get auth tag in unsupported state') -} - -CipherBase.prototype.setAuthTag = function () { - throw new Error('trying to set auth tag in unsupported state') -} - -CipherBase.prototype.setAAD = function () { - throw new Error('trying to set aad in unsupported state') -} - -CipherBase.prototype._transform = function (data, _, next) { - var err - try { - if (this.hashMode) { - this._update(data) - } else { - this.push(this._update(data)) - } - } catch (e) { - err = e - } finally { - next(err) - } -} -CipherBase.prototype._flush = function (done) { - var err - try { - this.push(this.__final()) - } catch (e) { - err = e - } - - done(err) -} -CipherBase.prototype._finalOrDigest = function (outputEnc) { - var outData = this.__final() || Buffer.alloc(0) - if (outputEnc) { - outData = this._toString(outData, outputEnc, true) - } - return outData -} - -CipherBase.prototype._toString = function (value, enc, fin) { - if (!this._decoder) { - this._decoder = new StringDecoder(enc) - this._encoding = enc - } - - if (this._encoding !== enc) throw new Error('can\'t switch encodings') - - var out = this._decoder.write(value) - if (fin) { - out += this._decoder.end() - } - - return out -} - -module.exports = CipherBase - - -/***/ }), -/* 110 */ -/***/ (function(module, exports, __webpack_require__) { - -var BigInteger = __webpack_require__(321) - -//addons -__webpack_require__(468) - -module.exports = BigInteger - -/***/ }), -/* 111 */ +/* 100 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(Buffer) { - -var base58 = __webpack_require__(423) -var createHash = __webpack_require__(71) - -// SHA256(SHA256(buffer)) -function sha256x2 (buffer) { - var tmp = createHash('sha256').update(buffer).digest() - return createHash('sha256').update(tmp).digest() -} - -// Encode a buffer as a base58-check encoded string -function encode (payload) { - var checksum = sha256x2(payload) - - return base58.encode(Buffer.concat([ - payload, - checksum - ], payload.length + 4)) -} - -function decodeRaw (buffer) { - var payload = buffer.slice(0, -4) - var checksum = buffer.slice(-4) - var newChecksum = sha256x2(payload) - - if (checksum[0] ^ newChecksum[0] | - checksum[1] ^ newChecksum[1] | - checksum[2] ^ newChecksum[2] | - checksum[3] ^ newChecksum[3]) return - - return payload -} - -// Decode a base58-check encoded string to a buffer, no result if checksum is wrong -function decodeUnsafe (string) { - var buffer = base58.decodeUnsafe(string) - if (!buffer) return - - return decodeRaw(buffer) -} - -function decode (string) { - var buffer = base58.decode(string) - var payload = decodeRaw(buffer) - if (!payload) throw new Error('Invalid checksum') - return payload -} - -module.exports = { - encode: encode, - decode: decode, - decodeUnsafe: decodeUnsafe -} +exports = module.exports = __webpack_require__(161); +exports.Stream = exports; +exports.Readable = exports; +exports.Writable = __webpack_require__(101); +exports.Duplex = __webpack_require__(34); +exports.Transform = __webpack_require__(165); +exports.PassThrough = __webpack_require__(371); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) /***/ }), -/* 112 */ +/* 101 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -// Copyright Joyent, Inc. and other Node contributors. +/* WEBPACK VAR INJECTION */(function(process, setImmediate, global) {// Copyright Joyent, Inc. and other Node contributors. // // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation files (the @@ -22434,3669 +20485,2930 @@ module.exports = { // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE // USE OR OTHER DEALINGS IN THE SOFTWARE. -// a duplex stream is just a stream that is both readable and writable. -// Since JS doesn't have multiple prototypal inheritance, this class -// prototypally inherits from Readable, and then parasitically from -// Writable. +// A bit simpler than readable streams. +// Implement an async ._write(chunk, encoding, cb), and it'll handle all +// the drain event emission and buffering. /*<replacement>*/ -var processNextTick = __webpack_require__(246); +var processNextTick = __webpack_require__(64); +/*</replacement>*/ + +module.exports = Writable; + +/* <replacement> */ +function WriteReq(chunk, encoding, cb) { + this.chunk = chunk; + this.encoding = encoding; + this.callback = cb; + this.next = null; +} + +// It seems a linked list but it is not +// there will be only 2 of these for each stream +function CorkedRequest(state) { + var _this = this; + + this.next = null; + this.entry = null; + this.finish = function () { + onCorkedFinish(_this, state); + }; +} +/* </replacement> */ + +/*<replacement>*/ +var asyncWrite = !process.browser && ['v0.10', 'v0.9.'].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : processNextTick; /*</replacement>*/ /*<replacement>*/ -var objectKeys = Object.keys || function (obj) { - var keys = []; - for (var key in obj) { - keys.push(key); - }return keys; -}; +var Duplex; /*</replacement>*/ -module.exports = Duplex; +Writable.WritableState = WritableState; /*<replacement>*/ -var util = __webpack_require__(237); -util.inherits = __webpack_require__(11); +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); /*</replacement>*/ -var Readable = __webpack_require__(307); -var Writable = __webpack_require__(263); +/*<replacement>*/ +var internalUtil = { + deprecate: __webpack_require__(370) +}; +/*</replacement>*/ -util.inherits(Duplex, Readable); +/*<replacement>*/ +var Stream = __webpack_require__(162); +/*</replacement>*/ -var keys = objectKeys(Writable.prototype); -for (var v = 0; v < keys.length; v++) { - var method = keys[v]; - if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method]; +/*<replacement>*/ +var Buffer = __webpack_require__(7).Buffer; +var OurUint8Array = global.Uint8Array || function () {}; +function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk); +} +function _isUint8Array(obj) { + return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; } +/*</replacement>*/ -function Duplex(options) { - if (!(this instanceof Duplex)) return new Duplex(options); +var destroyImpl = __webpack_require__(163); - Readable.call(this, options); - Writable.call(this, options); +util.inherits(Writable, Stream); - if (options && options.readable === false) this.readable = false; +function nop() {} - if (options && options.writable === false) this.writable = false; +function WritableState(options, stream) { + Duplex = Duplex || __webpack_require__(34); - this.allowHalfOpen = true; - if (options && options.allowHalfOpen === false) this.allowHalfOpen = false; + options = options || {}; - this.once('end', onend); -} + // object stream flag to indicate whether or not this stream + // contains buffers or objects. + this.objectMode = !!options.objectMode; -// the no-half-open enforcer -function onend() { - // if we allow half-open state, or if the writable side ended, - // then we're ok. - if (this.allowHalfOpen || this._writableState.ended) return; + if (stream instanceof Duplex) this.objectMode = this.objectMode || !!options.writableObjectMode; - // no more data can be written. - // But allow more writes to happen in this tick. - processNextTick(onEndNT, this); -} + // the point at which write() starts returning false + // Note: 0 is a valid value, means that we always return false if + // the entire buffer is not flushed immediately on write() + var hwm = options.highWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; + this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm; -function onEndNT(self) { - self.end(); -} + // cast to ints. + this.highWaterMark = Math.floor(this.highWaterMark); -Object.defineProperty(Duplex.prototype, 'destroyed', { - get: function () { - if (this._readableState === undefined || this._writableState === undefined) { - return false; - } - return this._readableState.destroyed && this._writableState.destroyed; - }, - set: function (value) { - // we ignore the value if the stream - // has not been initialized yet - if (this._readableState === undefined || this._writableState === undefined) { - return; - } + // if _final has been called + this.finalCalled = false; - // backward compatibility, the user is explicitly - // managing destroyed - this._readableState.destroyed = value; - this._writableState.destroyed = value; - } -}); + // drain event flag. + this.needDrain = false; + // at the start of calling end() + this.ending = false; + // when end() has been called, and returned + this.ended = false; + // when 'finish' is emitted + this.finished = false; -Duplex.prototype._destroy = function (err, cb) { - this.push(null); - this.end(); + // has it been destroyed + this.destroyed = false; - processNextTick(cb, err); -}; + // should we decode strings into buffers before passing to _write? + // this is here so that some node-core streams can optimize string + // handling at a lower level. + var noDecode = options.decodeStrings === false; + this.decodeStrings = !noDecode; -function forEach(xs, f) { - for (var i = 0, l = xs.length; i < l; i++) { - f(xs[i], i); - } -} + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; -/***/ }), -/* 113 */ -/***/ (function(module, exports, __webpack_require__) { + // not an actual buffer we keep track of, but a measurement + // of how much we're waiting to get pushed to some underlying + // socket or file. + this.length = 0; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // a flag to see when we're in the middle of a write. + this.writing = false; + + // when true all writes will be buffered until .uncork() call + this.corked = 0; + + // a flag to be able to tell if the onwrite cb is called immediately, + // or on a later tick. We set this to true at first, because any + // actions that shouldn't happen until "later" should generally also + // not happen before the first write call. + this.sync = true; + + // a flag to know if we're processing previously buffered items, which + // may call the _write() callback in the same tick, so that we don't + // end up in an overlapped onwrite situation. + this.bufferProcessing = false; + // the callback that's passed to _write(chunk,cb) + this.onwrite = function (er) { + onwrite(stream, er); + }; + // the callback that the user supplies to write(chunk,encoding,cb) + this.writecb = null; -var _assign = __webpack_require__(5); + // the amount that is being written when _write is called. + this.writelen = 0; -var emptyObject = __webpack_require__(39); -var _invariant = __webpack_require__(1); + this.bufferedRequest = null; + this.lastBufferedRequest = null; -if (process.env.NODE_ENV !== 'production') { - var warning = __webpack_require__(2); -} + // number of pending user-supplied write callbacks + // this must be 0 before 'finish' can be emitted + this.pendingcb = 0; -var MIXINS_KEY = 'mixins'; + // emit prefinish if the only thing we're waiting for is _write cbs + // This is relevant for synchronous Transform streams + this.prefinished = false; -// Helper function to allow the creation of anonymous functions which do not -// have .name set to the name of the variable being assigned to. -function identity(fn) { - return fn; + // True if the error was already emitted and should not be thrown again + this.errorEmitted = false; + + // count buffered requests + this.bufferedRequestCount = 0; + + // allocate the first CorkedRequest, there is always + // one allocated and free to use, and we maintain at most two + this.corkedRequestsFree = new CorkedRequest(this); } -var ReactPropTypeLocationNames; -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' - }; +WritableState.prototype.getBuffer = function getBuffer() { + var current = this.bufferedRequest; + var out = []; + while (current) { + out.push(current); + current = current.next; + } + return out; +}; + +(function () { + try { + Object.defineProperty(WritableState.prototype, 'buffer', { + get: internalUtil.deprecate(function () { + return this.getBuffer(); + }, '_writableState.buffer is deprecated. Use _writableState.getBuffer ' + 'instead.', 'DEP0003') + }); + } catch (_) {} +})(); + +// Test _writableState for inheritance to account for Duplex streams, +// whose prototype chain only points to Readable. +var realHasInstance; +if (typeof Symbol === 'function' && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] === 'function') { + realHasInstance = Function.prototype[Symbol.hasInstance]; + Object.defineProperty(Writable, Symbol.hasInstance, { + value: function (object) { + if (realHasInstance.call(this, object)) return true; + + return object && object._writableState instanceof WritableState; + } + }); } else { - ReactPropTypeLocationNames = {}; + realHasInstance = function (object) { + return object instanceof this; + }; } -function factory(ReactComponent, isValidElement, ReactNoopUpdateQueue) { - /** - * Policies that describe methods in `ReactClassInterface`. - */ +function Writable(options) { + Duplex = Duplex || __webpack_require__(34); - var injectedMixins = []; + // Writable ctor is applied to Duplexes, too. + // `realHasInstance` is necessary because using plain `instanceof` + // would return false, as no `_writableState` property is attached. - /** - * Composite components are higher-level components that compose other composite - * or host components. - * - * To create a new type of `ReactClass`, pass a specification of - * your new class to `React.createClass`. The only requirement of your class - * specification is that you implement a `render` method. - * - * var MyComponent = React.createClass({ - * render: function() { - * return <div>Hello World</div>; - * } - * }); - * - * The class specification supports a specific protocol of methods that have - * special meaning (e.g. `render`). See `ReactClassInterface` for - * more the comprehensive protocol. Any other properties and methods in the - * class specification will be available on the prototype. - * - * @interface ReactClassInterface - * @internal - */ - var ReactClassInterface = { - /** - * An array of Mixin objects to include when defining your component. - * - * @type {array} - * @optional - */ - mixins: 'DEFINE_MANY', + // Trying to use the custom `instanceof` for Writable here will also break the + // Node.js LazyTransform implementation, which has a non-trivial getter for + // `_writableState` that would lead to infinite recursion. + if (!realHasInstance.call(Writable, this) && !(this instanceof Duplex)) { + return new Writable(options); + } - /** - * An object containing properties and methods that should be defined on - * the component's constructor instead of its prototype (static methods). - * - * @type {object} - * @optional - */ - statics: 'DEFINE_MANY', + this._writableState = new WritableState(options, this); - /** - * Definition of prop types for this component. - * - * @type {object} - * @optional - */ - propTypes: 'DEFINE_MANY', + // legacy. + this.writable = true; - /** - * Definition of context types for this component. - * - * @type {object} - * @optional - */ - contextTypes: 'DEFINE_MANY', + if (options) { + if (typeof options.write === 'function') this._write = options.write; - /** - * Definition of context types this component sets for its children. - * - * @type {object} - * @optional - */ - childContextTypes: 'DEFINE_MANY', + if (typeof options.writev === 'function') this._writev = options.writev; - // ==== Definition methods ==== + if (typeof options.destroy === 'function') this._destroy = options.destroy; - /** - * Invoked when the component is mounted. Values in the mapping will be set on - * `this.props` if that prop is not specified (i.e. using an `in` check). - * - * This method is invoked before `getInitialState` and therefore cannot rely - * on `this.state` or use `this.setState`. - * - * @return {object} - * @optional - */ - getDefaultProps: 'DEFINE_MANY_MERGED', + if (typeof options.final === 'function') this._final = options.final; + } - /** - * Invoked once before the component is mounted. The return value will be used - * as the initial value of `this.state`. - * - * getInitialState: function() { - * return { - * isOn: false, - * fooBaz: new BazFoo() - * } - * } - * - * @return {object} - * @optional - */ - getInitialState: 'DEFINE_MANY_MERGED', + Stream.call(this); +} - /** - * @return {object} - * @optional - */ - getChildContext: 'DEFINE_MANY_MERGED', +// Otherwise people can pipe Writable streams, which is just wrong. +Writable.prototype.pipe = function () { + this.emit('error', new Error('Cannot pipe, not readable')); +}; - /** - * Uses props from `this.props` and state from `this.state` to render the - * structure of the component. - * - * No guarantees are made about when or how often this method is invoked, so - * it must not have side effects. - * - * render: function() { - * var name = this.props.name; - * return <div>Hello, {name}!</div>; - * } - * - * @return {ReactComponent} - * @required - */ - render: 'DEFINE_ONCE', +function writeAfterEnd(stream, cb) { + var er = new Error('write after end'); + // TODO: defer error events consistently everywhere, not just the cb + stream.emit('error', er); + processNextTick(cb, er); +} - // ==== Delegate methods ==== +// Checks that a user-supplied chunk is valid, especially for the particular +// mode the stream is in. Currently this means that `null` is never accepted +// and undefined/non-string values are only allowed in object mode. +function validChunk(stream, state, chunk, cb) { + var valid = true; + var er = false; - /** - * Invoked when the component is initially created and about to be mounted. - * This may have side effects, but any external subscriptions or data created - * by this method must be cleaned up in `componentWillUnmount`. - * - * @optional - */ - componentWillMount: 'DEFINE_MANY', + if (chunk === null) { + er = new TypeError('May not write null values to stream'); + } else if (typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); + } + if (er) { + stream.emit('error', er); + processNextTick(cb, er); + valid = false; + } + return valid; +} - /** - * Invoked when the component has been mounted and has a DOM representation. - * However, there is no guarantee that the DOM node is in the document. - * - * Use this as an opportunity to operate on the DOM when the component has - * been mounted (initialized and rendered) for the first time. - * - * @param {DOMElement} rootNode DOM element representing the component. - * @optional - */ - componentDidMount: 'DEFINE_MANY', +Writable.prototype.write = function (chunk, encoding, cb) { + var state = this._writableState; + var ret = false; + var isBuf = _isUint8Array(chunk) && !state.objectMode; - /** - * Invoked before the component receives new props. - * - * Use this as an opportunity to react to a prop transition by updating the - * state using `this.setState`. Current props are accessed via `this.props`. - * - * componentWillReceiveProps: function(nextProps, nextContext) { - * this.setState({ - * likesIncreasing: nextProps.likeCount > this.props.likeCount - * }); - * } - * - * NOTE: There is no equivalent `componentWillReceiveState`. An incoming prop - * transition may cause a state change, but the opposite is not true. If you - * need it, you are probably looking for `componentWillUpdate`. - * - * @param {object} nextProps - * @optional - */ - componentWillReceiveProps: 'DEFINE_MANY', + if (isBuf && !Buffer.isBuffer(chunk)) { + chunk = _uint8ArrayToBuffer(chunk); + } - /** - * Invoked while deciding if the component should be updated as a result of - * receiving new props, state and/or context. - * - * Use this as an opportunity to `return false` when you're certain that the - * transition to the new props/state/context will not require a component - * update. - * - * shouldComponentUpdate: function(nextProps, nextState, nextContext) { - * return !equal(nextProps, this.props) || - * !equal(nextState, this.state) || - * !equal(nextContext, this.context); - * } - * - * @param {object} nextProps - * @param {?object} nextState - * @param {?object} nextContext - * @return {boolean} True if the component should update. - * @optional - */ - shouldComponentUpdate: 'DEFINE_ONCE', + if (typeof encoding === 'function') { + cb = encoding; + encoding = null; + } - /** - * Invoked when the component is about to update due to a transition from - * `this.props`, `this.state` and `this.context` to `nextProps`, `nextState` - * and `nextContext`. - * - * Use this as an opportunity to perform preparation before an update occurs. - * - * NOTE: You **cannot** use `this.setState()` in this method. - * - * @param {object} nextProps - * @param {?object} nextState - * @param {?object} nextContext - * @param {ReactReconcileTransaction} transaction - * @optional - */ - componentWillUpdate: 'DEFINE_MANY', + if (isBuf) encoding = 'buffer';else if (!encoding) encoding = state.defaultEncoding; - /** - * Invoked when the component's DOM representation has been updated. - * - * Use this as an opportunity to operate on the DOM when the component has - * been updated. - * - * @param {object} prevProps - * @param {?object} prevState - * @param {?object} prevContext - * @param {DOMElement} rootNode DOM element representing the component. - * @optional - */ - componentDidUpdate: 'DEFINE_MANY', + if (typeof cb !== 'function') cb = nop; - /** - * Invoked when the component is about to be removed from its parent and have - * its DOM representation destroyed. - * - * Use this as an opportunity to deallocate any external resources. - * - * NOTE: There is no `componentDidUnmount` since your component will have been - * destroyed by that point. - * - * @optional - */ - componentWillUnmount: 'DEFINE_MANY', + if (state.ended) writeAfterEnd(this, cb);else if (isBuf || validChunk(this, state, chunk, cb)) { + state.pendingcb++; + ret = writeOrBuffer(this, state, isBuf, chunk, encoding, cb); + } - // ==== Advanced methods ==== + return ret; +}; - /** - * Updates the component's currently mounted DOM representation. - * - * By default, this implements React's rendering and reconciliation algorithm. - * Sophisticated clients may wish to override this. - * - * @param {ReactReconcileTransaction} transaction - * @internal - * @overridable - */ - updateComponent: 'OVERRIDE_BASE' - }; +Writable.prototype.cork = function () { + var state = this._writableState; - /** - * Mapping from class specification keys to special processing functions. - * - * Although these are declared like instance properties in the specification - * when defining classes using `React.createClass`, they are actually static - * and are accessible on the constructor instead of the prototype. Despite - * being static, they must be defined outside of the "statics" key under - * which all other static methods are defined. - */ - var RESERVED_SPEC_KEYS = { - displayName: function(Constructor, displayName) { - Constructor.displayName = displayName; - }, - mixins: function(Constructor, mixins) { - if (mixins) { - for (var i = 0; i < mixins.length; i++) { - mixSpecIntoComponent(Constructor, mixins[i]); - } - } - }, - childContextTypes: function(Constructor, childContextTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, childContextTypes, 'childContext'); - } - Constructor.childContextTypes = _assign( - {}, - Constructor.childContextTypes, - childContextTypes - ); - }, - contextTypes: function(Constructor, contextTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, contextTypes, 'context'); - } - Constructor.contextTypes = _assign( - {}, - Constructor.contextTypes, - contextTypes - ); - }, - /** - * Special case getDefaultProps which should move into statics but requires - * automatic merging. - */ - getDefaultProps: function(Constructor, getDefaultProps) { - if (Constructor.getDefaultProps) { - Constructor.getDefaultProps = createMergedResultFunction( - Constructor.getDefaultProps, - getDefaultProps - ); - } else { - Constructor.getDefaultProps = getDefaultProps; - } - }, - propTypes: function(Constructor, propTypes) { - if (process.env.NODE_ENV !== 'production') { - validateTypeDef(Constructor, propTypes, 'prop'); - } - Constructor.propTypes = _assign({}, Constructor.propTypes, propTypes); - }, - statics: function(Constructor, statics) { - mixStaticSpecIntoComponent(Constructor, statics); - }, - autobind: function() {} - }; + state.corked++; +}; - function validateTypeDef(Constructor, typeDef, location) { - for (var propName in typeDef) { - if (typeDef.hasOwnProperty(propName)) { - // use a warning instead of an _invariant so components - // don't show up in prod but only in __DEV__ - if (process.env.NODE_ENV !== 'production') { - warning( - typeof typeDef[propName] === 'function', - '%s: %s type `%s` is invalid; it must be a function, usually from ' + - 'React.PropTypes.', - Constructor.displayName || 'ReactClass', - ReactPropTypeLocationNames[location], - propName - ); - } - } - } +Writable.prototype.uncork = function () { + var state = this._writableState; + + if (state.corked) { + state.corked--; + + if (!state.writing && !state.corked && !state.finished && !state.bufferProcessing && state.bufferedRequest) clearBuffer(this, state); } +}; - function validateMethodOverride(isAlreadyDefined, name) { - var specPolicy = ReactClassInterface.hasOwnProperty(name) - ? ReactClassInterface[name] - : null; +Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) { + // node::ParseEncoding() requires lower case. + if (typeof encoding === 'string') encoding = encoding.toLowerCase(); + if (!(['hex', 'utf8', 'utf-8', 'ascii', 'binary', 'base64', 'ucs2', 'ucs-2', 'utf16le', 'utf-16le', 'raw'].indexOf((encoding + '').toLowerCase()) > -1)) throw new TypeError('Unknown encoding: ' + encoding); + this._writableState.defaultEncoding = encoding; + return this; +}; - // Disallow overriding of base class methods unless explicitly allowed. - if (ReactClassMixin.hasOwnProperty(name)) { - _invariant( - specPolicy === 'OVERRIDE_BASE', - 'ReactClassInterface: You are attempting to override ' + - '`%s` from your class specification. Ensure that your method names ' + - 'do not overlap with React methods.', - name - ); - } +function decodeChunk(state, chunk, encoding) { + if (!state.objectMode && state.decodeStrings !== false && typeof chunk === 'string') { + chunk = Buffer.from(chunk, encoding); + } + return chunk; +} - // Disallow defining methods more than once unless explicitly allowed. - if (isAlreadyDefined) { - _invariant( - specPolicy === 'DEFINE_MANY' || specPolicy === 'DEFINE_MANY_MERGED', - 'ReactClassInterface: You are attempting to define ' + - '`%s` on your component more than once. This conflict may be due ' + - 'to a mixin.', - name - ); +// if we're already writing something, then just put this +// in the queue, and wait our turn. Otherwise, call _write +// If we return false, then we need a drain event, so set that flag. +function writeOrBuffer(stream, state, isBuf, chunk, encoding, cb) { + if (!isBuf) { + var newChunk = decodeChunk(state, chunk, encoding); + if (chunk !== newChunk) { + isBuf = true; + encoding = 'buffer'; + chunk = newChunk; } } + var len = state.objectMode ? 1 : chunk.length; - /** - * Mixin helper which handles policy validation and reserved - * specification keys when building React classes. - */ - function mixSpecIntoComponent(Constructor, spec) { - if (!spec) { - if (process.env.NODE_ENV !== 'production') { - var typeofSpec = typeof spec; - var isMixinValid = typeofSpec === 'object' && spec !== null; + state.length += len; - if (process.env.NODE_ENV !== 'production') { - warning( - isMixinValid, - "%s: You're attempting to include a mixin that is either null " + - 'or not an object. Check the mixins included by the component, ' + - 'as well as any mixins they include themselves. ' + - 'Expected object but got %s.', - Constructor.displayName || 'ReactClass', - spec === null ? null : typeofSpec - ); - } - } + var ret = state.length < state.highWaterMark; + // we must ensure that previous needDrain will not be reset to false. + if (!ret) state.needDrain = true; - return; + if (state.writing || state.corked) { + var last = state.lastBufferedRequest; + state.lastBufferedRequest = { + chunk: chunk, + encoding: encoding, + isBuf: isBuf, + callback: cb, + next: null + }; + if (last) { + last.next = state.lastBufferedRequest; + } else { + state.bufferedRequest = state.lastBufferedRequest; } + state.bufferedRequestCount += 1; + } else { + doWrite(stream, state, false, len, chunk, encoding, cb); + } - _invariant( - typeof spec !== 'function', - "ReactClass: You're attempting to " + - 'use a component class or function as a mixin. Instead, just use a ' + - 'regular object.' - ); - _invariant( - !isValidElement(spec), - "ReactClass: You're attempting to " + - 'use a component as a mixin. Instead, just use a regular object.' - ); + return ret; +} - var proto = Constructor.prototype; - var autoBindPairs = proto.__reactAutoBindPairs; +function doWrite(stream, state, writev, len, chunk, encoding, cb) { + state.writelen = len; + state.writecb = cb; + state.writing = true; + state.sync = true; + if (writev) stream._writev(chunk, state.onwrite);else stream._write(chunk, encoding, state.onwrite); + state.sync = false; +} - // By handling mixins before any other properties, we ensure the same - // chaining order is applied to methods with DEFINE_MANY policy, whether - // mixins are listed before or after these methods in the spec. - if (spec.hasOwnProperty(MIXINS_KEY)) { - RESERVED_SPEC_KEYS.mixins(Constructor, spec.mixins); - } +function onwriteError(stream, state, sync, er, cb) { + --state.pendingcb; - for (var name in spec) { - if (!spec.hasOwnProperty(name)) { - continue; - } + if (sync) { + // defer the callback if we are being called synchronously + // to avoid piling up things on the stack + processNextTick(cb, er); + // this can emit finish, and it will always happen + // after error + processNextTick(finishMaybe, stream, state); + stream._writableState.errorEmitted = true; + stream.emit('error', er); + } else { + // the caller expect this to happen before if + // it is async + cb(er); + stream._writableState.errorEmitted = true; + stream.emit('error', er); + // this can emit finish, but finish must + // always follow error + finishMaybe(stream, state); + } +} - if (name === MIXINS_KEY) { - // We have already handled mixins in a special case above. - continue; - } +function onwriteStateUpdate(state) { + state.writing = false; + state.writecb = null; + state.length -= state.writelen; + state.writelen = 0; +} - var property = spec[name]; - var isAlreadyDefined = proto.hasOwnProperty(name); - validateMethodOverride(isAlreadyDefined, name); +function onwrite(stream, er) { + var state = stream._writableState; + var sync = state.sync; + var cb = state.writecb; - if (RESERVED_SPEC_KEYS.hasOwnProperty(name)) { - RESERVED_SPEC_KEYS[name](Constructor, property); - } else { - // Setup methods on prototype: - // The following member methods should not be automatically bound: - // 1. Expected ReactClass methods (in the "interface"). - // 2. Overridden methods (that were mixed in). - var isReactClassMethod = ReactClassInterface.hasOwnProperty(name); - var isFunction = typeof property === 'function'; - var shouldAutoBind = - isFunction && - !isReactClassMethod && - !isAlreadyDefined && - spec.autobind !== false; + onwriteStateUpdate(state); - if (shouldAutoBind) { - autoBindPairs.push(name, property); - proto[name] = property; - } else { - if (isAlreadyDefined) { - var specPolicy = ReactClassInterface[name]; + if (er) onwriteError(stream, state, sync, er, cb);else { + // Check if we're actually ready to finish, but don't emit yet + var finished = needFinish(state); - // These cases should already be caught by validateMethodOverride. - _invariant( - isReactClassMethod && - (specPolicy === 'DEFINE_MANY_MERGED' || - specPolicy === 'DEFINE_MANY'), - 'ReactClass: Unexpected spec policy %s for key %s ' + - 'when mixing in component specs.', - specPolicy, - name - ); + if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) { + clearBuffer(stream, state); + } - // For methods which are defined more than once, call the existing - // methods before calling the new property, merging if appropriate. - if (specPolicy === 'DEFINE_MANY_MERGED') { - proto[name] = createMergedResultFunction(proto[name], property); - } else if (specPolicy === 'DEFINE_MANY') { - proto[name] = createChainedFunction(proto[name], property); - } - } else { - proto[name] = property; - if (process.env.NODE_ENV !== 'production') { - // Add verbose displayName to the function, which helps when looking - // at profiling tools. - if (typeof property === 'function' && spec.displayName) { - proto[name].displayName = spec.displayName + '_' + name; - } - } - } - } - } - } - } - - function mixStaticSpecIntoComponent(Constructor, statics) { - if (!statics) { - return; - } - for (var name in statics) { - var property = statics[name]; - if (!statics.hasOwnProperty(name)) { - continue; - } - - var isReserved = name in RESERVED_SPEC_KEYS; - _invariant( - !isReserved, - 'ReactClass: You are attempting to define a reserved ' + - 'property, `%s`, that shouldn\'t be on the "statics" key. Define it ' + - 'as an instance property instead; it will still be accessible on the ' + - 'constructor.', - name - ); - - var isInherited = name in Constructor; - _invariant( - !isInherited, - 'ReactClass: You are attempting to define ' + - '`%s` on your component more than once. This conflict may be ' + - 'due to a mixin.', - name - ); - Constructor[name] = property; - } - } - - /** - * Merge two objects, but throw if both contain the same key. - * - * @param {object} one The first object, which is mutated. - * @param {object} two The second object - * @return {object} one after it has been mutated to contain everything in two. - */ - function mergeIntoWithNoDuplicateKeys(one, two) { - _invariant( - one && two && typeof one === 'object' && typeof two === 'object', - 'mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.' - ); - - for (var key in two) { - if (two.hasOwnProperty(key)) { - _invariant( - one[key] === undefined, - 'mergeIntoWithNoDuplicateKeys(): ' + - 'Tried to merge two objects with the same key: `%s`. This conflict ' + - 'may be due to a mixin; in particular, this may be caused by two ' + - 'getInitialState() or getDefaultProps() methods returning objects ' + - 'with clashing keys.', - key - ); - one[key] = two[key]; - } + if (sync) { + /*<replacement>*/ + asyncWrite(afterWrite, stream, state, finished, cb); + /*</replacement>*/ + } else { + afterWrite(stream, state, finished, cb); } - return one; } +} - /** - * Creates a function that invokes two functions and merges their return values. - * - * @param {function} one Function to invoke first. - * @param {function} two Function to invoke second. - * @return {function} Function that invokes the two argument functions. - * @private - */ - function createMergedResultFunction(one, two) { - return function mergedResult() { - var a = one.apply(this, arguments); - var b = two.apply(this, arguments); - if (a == null) { - return b; - } else if (b == null) { - return a; - } - var c = {}; - mergeIntoWithNoDuplicateKeys(c, a); - mergeIntoWithNoDuplicateKeys(c, b); - return c; - }; - } +function afterWrite(stream, state, finished, cb) { + if (!finished) onwriteDrain(stream, state); + state.pendingcb--; + cb(); + finishMaybe(stream, state); +} - /** - * Creates a function that invokes two functions and ignores their return vales. - * - * @param {function} one Function to invoke first. - * @param {function} two Function to invoke second. - * @return {function} Function that invokes the two argument functions. - * @private - */ - function createChainedFunction(one, two) { - return function chainedFunction() { - one.apply(this, arguments); - two.apply(this, arguments); - }; +// Must force callback to be called on nextTick, so that we don't +// emit 'drain' before the write() consumer gets the 'false' return +// value, and has a chance to attach a 'drain' listener. +function onwriteDrain(stream, state) { + if (state.length === 0 && state.needDrain) { + state.needDrain = false; + stream.emit('drain'); } +} - /** - * Binds a method to the component. - * - * @param {object} component Component whose method is going to be bound. - * @param {function} method Method to be bound. - * @return {function} The bound method. - */ - function bindAutoBindMethod(component, method) { - var boundMethod = method.bind(component); - if (process.env.NODE_ENV !== 'production') { - boundMethod.__reactBoundContext = component; - boundMethod.__reactBoundMethod = method; - boundMethod.__reactBoundArguments = null; - var componentName = component.constructor.displayName; - var _bind = boundMethod.bind; - boundMethod.bind = function(newThis) { - for ( - var _len = arguments.length, - args = Array(_len > 1 ? _len - 1 : 0), - _key = 1; - _key < _len; - _key++ - ) { - args[_key - 1] = arguments[_key]; - } +// if there's something in the buffer waiting, then process it +function clearBuffer(stream, state) { + state.bufferProcessing = true; + var entry = state.bufferedRequest; - // User is trying to bind() an autobound method; we effectively will - // ignore the value of "this" that the user is trying to use, so - // let's warn. - if (newThis !== component && newThis !== null) { - if (process.env.NODE_ENV !== 'production') { - warning( - false, - 'bind(): React component methods may only be bound to the ' + - 'component instance. See %s', - componentName - ); - } - } else if (!args.length) { - if (process.env.NODE_ENV !== 'production') { - warning( - false, - 'bind(): You are binding a component method to the component. ' + - 'React does this for you automatically in a high-performance ' + - 'way, so you can safely remove this call. See %s', - componentName - ); - } - return boundMethod; - } - var reboundMethod = _bind.apply(boundMethod, arguments); - reboundMethod.__reactBoundContext = component; - reboundMethod.__reactBoundMethod = method; - reboundMethod.__reactBoundArguments = args; - return reboundMethod; - }; - } - return boundMethod; - } + if (stream._writev && entry && entry.next) { + // Fast case, write everything using _writev() + var l = state.bufferedRequestCount; + var buffer = new Array(l); + var holder = state.corkedRequestsFree; + holder.entry = entry; - /** - * Binds all auto-bound methods in a component. - * - * @param {object} component Component whose method is going to be bound. - */ - function bindAutoBindMethods(component) { - var pairs = component.__reactAutoBindPairs; - for (var i = 0; i < pairs.length; i += 2) { - var autoBindKey = pairs[i]; - var method = pairs[i + 1]; - component[autoBindKey] = bindAutoBindMethod(component, method); + var count = 0; + var allBuffers = true; + while (entry) { + buffer[count] = entry; + if (!entry.isBuf) allBuffers = false; + entry = entry.next; + count += 1; } - } + buffer.allBuffers = allBuffers; - var IsMountedPreMixin = { - componentDidMount: function() { - this.__isMounted = true; - } - }; + doWrite(stream, state, true, state.length, buffer, '', holder.finish); - var IsMountedPostMixin = { - componentWillUnmount: function() { - this.__isMounted = false; + // doWrite is almost always async, defer these to save a bit of time + // as the hot path ends with doWrite + state.pendingcb++; + state.lastBufferedRequest = null; + if (holder.next) { + state.corkedRequestsFree = holder.next; + holder.next = null; + } else { + state.corkedRequestsFree = new CorkedRequest(state); } - }; - - /** - * Add more to the ReactClass base class. These are all legacy features and - * therefore not already part of the modern ReactComponent. - */ - var ReactClassMixin = { - /** - * TODO: This will be deprecated because state should always keep a consistent - * type signature and the only use case for this, is to avoid that. - */ - replaceState: function(newState, callback) { - this.updater.enqueueReplaceState(this, newState, callback); - }, + } else { + // Slow case, write chunks one-by-one + while (entry) { + var chunk = entry.chunk; + var encoding = entry.encoding; + var cb = entry.callback; + var len = state.objectMode ? 1 : chunk.length; - /** - * Checks whether or not this composite component is mounted. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ - isMounted: function() { - if (process.env.NODE_ENV !== 'production') { - warning( - this.__didWarnIsMounted, - '%s: isMounted is deprecated. Instead, make sure to clean up ' + - 'subscriptions and pending requests in componentWillUnmount to ' + - 'prevent memory leaks.', - (this.constructor && this.constructor.displayName) || - this.name || - 'Component' - ); - this.__didWarnIsMounted = true; + doWrite(stream, state, false, len, chunk, encoding, cb); + entry = entry.next; + // if we didn't call the onwrite immediately, then + // it means that we need to wait until it does. + // also, that means that the chunk and cb are currently + // being processed, so move the buffer counter past them. + if (state.writing) { + break; } - return !!this.__isMounted; } - }; - - var ReactClassComponent = function() {}; - _assign( - ReactClassComponent.prototype, - ReactComponent.prototype, - ReactClassMixin - ); - - /** - * Creates a composite component class given a class specification. - * See https://facebook.github.io/react/docs/top-level-api.html#react.createclass - * - * @param {object} spec Class specification (which must define `render`). - * @return {function} Component constructor function. - * @public - */ - function createClass(spec) { - // To keep our warnings more understandable, we'll use a little hack here to - // ensure that Constructor.name !== 'Constructor'. This makes sure we don't - // unnecessarily identify a class without displayName as 'Constructor'. - var Constructor = identity(function(props, context, updater) { - // This constructor gets overridden by mocks. The argument is used - // by mocks to assert on what gets mounted. - - if (process.env.NODE_ENV !== 'production') { - warning( - this instanceof Constructor, - 'Something is calling a React component directly. Use a factory or ' + - 'JSX instead. See: https://fb.me/react-legacyfactory' - ); - } - // Wire up auto-binding - if (this.__reactAutoBindPairs.length) { - bindAutoBindMethods(this); - } + if (entry === null) state.lastBufferedRequest = null; + } - this.props = props; - this.context = context; - this.refs = emptyObject; - this.updater = updater || ReactNoopUpdateQueue; + state.bufferedRequestCount = 0; + state.bufferedRequest = entry; + state.bufferProcessing = false; +} - this.state = null; +Writable.prototype._write = function (chunk, encoding, cb) { + cb(new Error('_write() is not implemented')); +}; - // ReactClasses doesn't have constructors. Instead, they use the - // getInitialState and componentWillMount methods for initialization. +Writable.prototype._writev = null; - var initialState = this.getInitialState ? this.getInitialState() : null; - if (process.env.NODE_ENV !== 'production') { - // We allow auto-mocks to proceed as if they're returning null. - if ( - initialState === undefined && - this.getInitialState._isMockFunction - ) { - // This is probably bad practice. Consider warning here and - // deprecating this convenience. - initialState = null; - } - } - _invariant( - typeof initialState === 'object' && !Array.isArray(initialState), - '%s.getInitialState(): must return an object or null', - Constructor.displayName || 'ReactCompositeComponent' - ); +Writable.prototype.end = function (chunk, encoding, cb) { + var state = this._writableState; - this.state = initialState; - }); - Constructor.prototype = new ReactClassComponent(); - Constructor.prototype.constructor = Constructor; - Constructor.prototype.__reactAutoBindPairs = []; + if (typeof chunk === 'function') { + cb = chunk; + chunk = null; + encoding = null; + } else if (typeof encoding === 'function') { + cb = encoding; + encoding = null; + } - injectedMixins.forEach(mixSpecIntoComponent.bind(null, Constructor)); + if (chunk !== null && chunk !== undefined) this.write(chunk, encoding); - mixSpecIntoComponent(Constructor, IsMountedPreMixin); - mixSpecIntoComponent(Constructor, spec); - mixSpecIntoComponent(Constructor, IsMountedPostMixin); + // .end() fully uncorks + if (state.corked) { + state.corked = 1; + this.uncork(); + } - // Initialize the defaultProps property after all mixins have been merged. - if (Constructor.getDefaultProps) { - Constructor.defaultProps = Constructor.getDefaultProps(); - } + // ignore unnecessary end() calls. + if (!state.ending && !state.finished) endWritable(this, state, cb); +}; - if (process.env.NODE_ENV !== 'production') { - // This is a tag to indicate that the use of these method names is ok, - // since it's used with createClass. If it's not, then it's likely a - // mistake so we'll warn you to use the static property, property - // initializer or constructor respectively. - if (Constructor.getDefaultProps) { - Constructor.getDefaultProps.isReactClassApproved = {}; - } - if (Constructor.prototype.getInitialState) { - Constructor.prototype.getInitialState.isReactClassApproved = {}; - } +function needFinish(state) { + return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing; +} +function callFinal(stream, state) { + stream._final(function (err) { + state.pendingcb--; + if (err) { + stream.emit('error', err); } - - _invariant( - Constructor.prototype.render, - 'createClass(...): Class specification must implement a `render` method.' - ); - - if (process.env.NODE_ENV !== 'production') { - warning( - !Constructor.prototype.componentShouldUpdate, - '%s has a method called ' + - 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + - 'The name is phrased as a question because the function is ' + - 'expected to return a value.', - spec.displayName || 'A component' - ); - warning( - !Constructor.prototype.componentWillRecieveProps, - '%s has a method called ' + - 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', - spec.displayName || 'A component' - ); + state.prefinished = true; + stream.emit('prefinish'); + finishMaybe(stream, state); + }); +} +function prefinish(stream, state) { + if (!state.prefinished && !state.finalCalled) { + if (typeof stream._final === 'function') { + state.pendingcb++; + state.finalCalled = true; + processNextTick(callFinal, stream, state); + } else { + state.prefinished = true; + stream.emit('prefinish'); } + } +} - // Reduce time spent doing lookups by setting these on the prototype. - for (var methodName in ReactClassInterface) { - if (!Constructor.prototype[methodName]) { - Constructor.prototype[methodName] = null; - } +function finishMaybe(stream, state) { + var need = needFinish(state); + if (need) { + prefinish(stream, state); + if (state.pendingcb === 0) { + state.finished = true; + stream.emit('finish'); } + } + return need; +} - return Constructor; +function endWritable(stream, state, cb) { + state.ending = true; + finishMaybe(stream, state); + if (cb) { + if (state.finished) processNextTick(cb);else stream.once('finish', cb); } + state.ended = true; + stream.writable = false; +} - return createClass; +function onCorkedFinish(corkReq, state, err) { + var entry = corkReq.entry; + corkReq.entry = null; + while (entry) { + var cb = entry.callback; + state.pendingcb--; + cb(err); + entry = entry.next; + } + if (state.corkedRequestsFree) { + state.corkedRequestsFree.next = corkReq; + } else { + state.corkedRequestsFree = corkReq; + } } -module.exports = factory; +Object.defineProperty(Writable.prototype, 'destroyed', { + get: function () { + if (this._writableState === undefined) { + return false; + } + return this._writableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (!this._writableState) { + return; + } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // backward compatibility, the user is explicitly + // managing destroyed + this._writableState.destroyed = value; + } +}); + +Writable.prototype.destroy = destroyImpl.destroy; +Writable.prototype._undestroy = destroyImpl.undestroy; +Writable.prototype._destroy = function (err, cb) { + this.end(); + cb(err); +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0), __webpack_require__(164).setImmediate, __webpack_require__(24))) /***/ }), -/* 114 */ +/* 102 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {// prototype class for hash functions -function Hash (blockSize, finalSize) { - this._block = new Buffer(blockSize) - this._finalSize = finalSize - this._blockSize = blockSize - this._len = 0 - this._s = 0 +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +var Buffer = __webpack_require__(1).Buffer; + +var isBufferEncoding = Buffer.isEncoding + || function(encoding) { + switch (encoding && encoding.toLowerCase()) { + case 'hex': case 'utf8': case 'utf-8': case 'ascii': case 'binary': case 'base64': case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': case 'raw': return true; + default: return false; + } + } + + +function assertEncoding(encoding) { + if (encoding && !isBufferEncoding(encoding)) { + throw new Error('Unknown encoding: ' + encoding); + } } -Hash.prototype.update = function (data, enc) { - if (typeof data === 'string') { - enc = enc || 'utf8' - data = new Buffer(data, enc) +// StringDecoder provides an interface for efficiently splitting a series of +// buffers into a series of JS strings without breaking apart multi-byte +// characters. CESU-8 is handled as part of the UTF-8 encoding. +// +// @TODO Handling all encodings inside a single object makes it very difficult +// to reason about this code, so it should be split up in the future. +// @TODO There should be a utf8-strict encoding that rejects invalid UTF-8 code +// points as used by CESU-8. +var StringDecoder = exports.StringDecoder = function(encoding) { + this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, ''); + assertEncoding(encoding); + switch (this.encoding) { + case 'utf8': + // CESU-8 represents each of Surrogate Pair by 3-bytes + this.surrogateSize = 3; + break; + case 'ucs2': + case 'utf16le': + // UTF-16 represents each of Surrogate Pair by 2-bytes + this.surrogateSize = 2; + this.detectIncompleteChar = utf16DetectIncompleteChar; + break; + case 'base64': + // Base-64 stores 3 bytes in 4 chars, and pads the remainder. + this.surrogateSize = 3; + this.detectIncompleteChar = base64DetectIncompleteChar; + break; + default: + this.write = passThroughWrite; + return; } - var l = this._len += data.length - var s = this._s || 0 - var f = 0 - var buffer = this._block + // Enough space to store all bytes of a single character. UTF-8 needs 4 + // bytes, but CESU-8 may require up to 6 (3 bytes per surrogate). + this.charBuffer = new Buffer(6); + // Number of bytes received for the current incomplete multi-byte character. + this.charReceived = 0; + // Number of bytes expected for the current incomplete multi-byte character. + this.charLength = 0; +}; - while (s < l) { - var t = Math.min(data.length, f + this._blockSize - (s % this._blockSize)) - var ch = (t - f) - for (var i = 0; i < ch; i++) { - buffer[(s % this._blockSize) + i] = data[i + f] +// write decodes the given buffer and returns it as JS string that is +// guaranteed to not contain any partial multi-byte characters. Any partial +// character found at the end of the buffer is buffered up, and will be +// returned when calling write again with the remaining bytes. +// +// Note: Converting a Buffer containing an orphan surrogate to a String +// currently works, but converting a String to a Buffer (via `new Buffer`, or +// Buffer#write) will replace incomplete surrogates with the unicode +// replacement character. See https://codereview.chromium.org/121173009/ . +StringDecoder.prototype.write = function(buffer) { + var charStr = ''; + // if our last write ended with an incomplete multibyte character + while (this.charLength) { + // determine how many remaining bytes this buffer has to offer for this char + var available = (buffer.length >= this.charLength - this.charReceived) ? + this.charLength - this.charReceived : + buffer.length; + + // add the new bytes to the char buffer + buffer.copy(this.charBuffer, this.charReceived, 0, available); + this.charReceived += available; + + if (this.charReceived < this.charLength) { + // still not enough chars in this buffer? wait for more ... + return ''; } - s += ch - f += ch + // remove bytes belonging to the current character from the buffer + buffer = buffer.slice(available, buffer.length); - if ((s % this._blockSize) === 0) { - this._update(buffer) + // get the character that was split + charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding); + + // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character + var charCode = charStr.charCodeAt(charStr.length - 1); + if (charCode >= 0xD800 && charCode <= 0xDBFF) { + this.charLength += this.surrogateSize; + charStr = ''; + continue; } - } - this._s = s + this.charReceived = this.charLength = 0; - return this -} + // if there are no more bytes in this buffer, just emit our char + if (buffer.length === 0) { + return charStr; + } + break; + } -Hash.prototype.digest = function (enc) { - // Suppose the length of the message M, in bits, is l - var l = this._len * 8 + // determine and set charLength / charReceived + this.detectIncompleteChar(buffer); - // Append the bit 1 to the end of the message - this._block[this._len % this._blockSize] = 0x80 + var end = buffer.length; + if (this.charLength) { + // buffer the incomplete character bytes we got + buffer.copy(this.charBuffer, 0, buffer.length - this.charReceived, end); + end -= this.charReceived; + } - // and then k zero bits, where k is the smallest non-negative solution to the equation (l + 1 + k) === finalSize mod blockSize - this._block.fill(0, this._len % this._blockSize + 1) + charStr += buffer.toString(this.encoding, 0, end); - if (l % (this._blockSize * 8) >= this._finalSize * 8) { - this._update(this._block) - this._block.fill(0) + var end = charStr.length - 1; + var charCode = charStr.charCodeAt(end); + // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character + if (charCode >= 0xD800 && charCode <= 0xDBFF) { + var size = this.surrogateSize; + this.charLength += size; + this.charReceived += size; + this.charBuffer.copy(this.charBuffer, size, 0, size); + buffer.copy(this.charBuffer, 0, 0, size); + return charStr.substring(0, end); } - // to this append the block which is equal to the number l written in binary - // TODO: handle case where l is > Math.pow(2, 29) - this._block.writeInt32BE(l, this._blockSize - 4) + // or just emit the charStr + return charStr; +}; - var hash = this._update(this._block) || this._hash() +// detectIncompleteChar determines if there is an incomplete UTF-8 character at +// the end of the given buffer. If so, it sets this.charLength to the byte +// length that character, and sets this.charReceived to the number of bytes +// that are available for this character. +StringDecoder.prototype.detectIncompleteChar = function(buffer) { + // determine how many bytes we have to check at the end of this buffer + var i = (buffer.length >= 3) ? 3 : buffer.length; - return enc ? hash.toString(enc) : hash -} + // Figure out if one of the last i bytes of our buffer announces an + // incomplete char. + for (; i > 0; i--) { + var c = buffer[buffer.length - i]; -Hash.prototype._update = function () { - throw new Error('_update must be implemented by subclass') -} + // See http://en.wikipedia.org/wiki/UTF-8#Description -module.exports = Hash + // 110XXXXX + if (i == 1 && c >> 5 == 0x06) { + this.charLength = 2; + break; + } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + // 1110XXXX + if (i <= 2 && c >> 4 == 0x0E) { + this.charLength = 3; + break; + } -/***/ }), -/* 115 */ -/***/ (function(module, exports, __webpack_require__) { + // 11110XXX + if (i <= 3 && c >> 3 == 0x1E) { + this.charLength = 4; + break; + } + } + this.charReceived = i; +}; -"use strict"; -/* WEBPACK VAR INJECTION */(function(global, process) { +StringDecoder.prototype.end = function(buffer) { + var res = ''; + if (buffer && buffer.length) + res = this.write(buffer); -function oldBrowser () { - throw new Error('secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11') + if (this.charReceived) { + var cr = this.charReceived; + var buf = this.charBuffer; + var enc = this.encoding; + res += buf.slice(0, cr).toString(enc); + } + + return res; +}; + +function passThroughWrite(buffer) { + return buffer.toString(this.encoding); } -var Buffer = __webpack_require__(18).Buffer -var crypto = global.crypto || global.msCrypto +function utf16DetectIncompleteChar(buffer) { + this.charReceived = buffer.length % 2; + this.charLength = this.charReceived ? 2 : 0; +} -if (crypto && crypto.getRandomValues) { - module.exports = randomBytes -} else { - module.exports = oldBrowser +function base64DetectIncompleteChar(buffer) { + this.charReceived = buffer.length % 3; + this.charLength = this.charReceived ? 3 : 0; } -function randomBytes (size, cb) { - // phantomjs needs to throw - if (size > 65536) throw new Error('requested too many random bytes') - // in case browserify isn't using the Uint8Array version - var rawBytes = new global.Uint8Array(size) - // This will not work in older browsers. - // See https://developer.mozilla.org/en-US/docs/Web/API/window.crypto.getRandomValues - if (size > 0) { // getRandomValues fails on IE if size == 0 - crypto.getRandomValues(rawBytes) - } +/***/ }), +/* 103 */ +/***/ (function(module, exports, __webpack_require__) { - // XXX: phantomjs doesn't like a buffer being passed here - var bytes = Buffer.from(rawBytes.buffer) +var exports = module.exports = function SHA (algorithm) { + algorithm = algorithm.toLowerCase() - if (typeof cb === 'function') { - return process.nextTick(function () { - cb(null, bytes) - }) - } + var Algorithm = exports[algorithm] + if (!Algorithm) throw new Error(algorithm + ' is not supported (we accept pull requests)') - return bytes + return new Algorithm() } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(67), __webpack_require__(0))) +exports.sha = __webpack_require__(376) +exports.sha1 = __webpack_require__(377) +exports.sha224 = __webpack_require__(378) +exports.sha256 = __webpack_require__(166) +exports.sha384 = __webpack_require__(379) +exports.sha512 = __webpack_require__(167) + /***/ }), -/* 116 */ +/* 104 */ /***/ (function(module, exports, __webpack_require__) { -var createHash = __webpack_require__(71) +// Reference https://github.com/bitcoin/bips/blob/master/bip-0066.mediawiki +// Format: 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S] +// NOTE: SIGHASH byte ignored AND restricted, truncate before use -function ripemd160 (buffer) { - return createHash('rmd160').update(buffer).digest() -} +var Buffer = __webpack_require__(7).Buffer -function sha1 (buffer) { - return createHash('sha1').update(buffer).digest() -} +function check (buffer) { + if (buffer.length < 8) return false + if (buffer.length > 72) return false + if (buffer[0] !== 0x30) return false + if (buffer[1] !== buffer.length - 2) return false + if (buffer[2] !== 0x02) return false -function sha256 (buffer) { - return createHash('sha256').update(buffer).digest() -} + var lenR = buffer[3] + if (lenR === 0) return false + if (5 + lenR >= buffer.length) return false + if (buffer[4 + lenR] !== 0x02) return false -function hash160 (buffer) { - return ripemd160(sha256(buffer)) -} + var lenS = buffer[5 + lenR] + if (lenS === 0) return false + if ((6 + lenR + lenS) !== buffer.length) return false -function hash256 (buffer) { - return sha256(sha256(buffer)) + if (buffer[4] & 0x80) return false + if (lenR > 1 && (buffer[4] === 0x00) && !(buffer[5] & 0x80)) return false + + if (buffer[lenR + 6] & 0x80) return false + if (lenS > 1 && (buffer[lenR + 6] === 0x00) && !(buffer[lenR + 7] & 0x80)) return false + return true } -module.exports = { - hash160: hash160, - hash256: hash256, - ripemd160: ripemd160, - sha1: sha1, - sha256: sha256 +function decode (buffer) { + if (buffer.length < 8) throw new Error('DER sequence length is too short') + if (buffer.length > 72) throw new Error('DER sequence length is too long') + if (buffer[0] !== 0x30) throw new Error('Expected DER sequence') + if (buffer[1] !== buffer.length - 2) throw new Error('DER sequence length is invalid') + if (buffer[2] !== 0x02) throw new Error('Expected DER integer') + + var lenR = buffer[3] + if (lenR === 0) throw new Error('R length is zero') + if (5 + lenR >= buffer.length) throw new Error('R length is too long') + if (buffer[4 + lenR] !== 0x02) throw new Error('Expected DER integer (2)') + + var lenS = buffer[5 + lenR] + if (lenS === 0) throw new Error('S length is zero') + if ((6 + lenR + lenS) !== buffer.length) throw new Error('S length is invalid') + + if (buffer[4] & 0x80) throw new Error('R value is negative') + if (lenR > 1 && (buffer[4] === 0x00) && !(buffer[5] & 0x80)) throw new Error('R value excessively padded') + + if (buffer[lenR + 6] & 0x80) throw new Error('S value is negative') + if (lenS > 1 && (buffer[lenR + 6] === 0x00) && !(buffer[lenR + 7] & 0x80)) throw new Error('S value excessively padded') + + // non-BIP66 - extract R, S values + return { + r: buffer.slice(4, 4 + lenR), + s: buffer.slice(6 + lenR) + } } +/* + * Expects r and s to be positive DER integers. + * + * The DER format uses the most significant bit as a sign bit (& 0x80). + * If the significant bit is set AND the integer is positive, a 0x00 is prepended. + * + * Examples: + * + * 0 => 0x00 + * 1 => 0x01 + * -1 => 0xff + * 127 => 0x7f + * -127 => 0x81 + * 128 => 0x0080 + * -128 => 0x80 + * 255 => 0x00ff + * -255 => 0xff01 + * 16300 => 0x3fac + * -16300 => 0xc054 + * 62300 => 0x00f35c + * -62300 => 0xff0ca4 +*/ +function encode (r, s) { + var lenR = r.length + var lenS = s.length + if (lenR === 0) throw new Error('R length is zero') + if (lenS === 0) throw new Error('S length is zero') + if (lenR > 33) throw new Error('R length is too long') + if (lenS > 33) throw new Error('S length is too long') + if (r[0] & 0x80) throw new Error('R value is negative') + if (s[0] & 0x80) throw new Error('S value is negative') + if (lenR > 1 && (r[0] === 0x00) && !(r[1] & 0x80)) throw new Error('R value excessively padded') + if (lenS > 1 && (s[0] === 0x00) && !(s[1] & 0x80)) throw new Error('S value excessively padded') -/***/ }), -/* 117 */ -/***/ (function(module, exports, __webpack_require__) { + var signature = Buffer.allocUnsafe(6 + lenR + lenS) -// style-loader: Adds some css to the DOM by adding a <style> tag + // 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S] + signature[0] = 0x30 + signature[1] = signature.length - 2 + signature[2] = 0x02 + signature[3] = r.length + r.copy(signature, 4) + signature[4 + lenR] = 0x02 + signature[5 + lenR] = s.length + s.copy(signature, 6 + lenR) -// load the styles -var content = __webpack_require__(118); -if(typeof content === 'string') content = [[module.i, content, '']]; -// Prepare cssTransformation -var transform; + return signature +} -var options = {} -options.transform = transform -// add the styles to the DOM -var update = __webpack_require__(73)(content, options); -if(content.locals) module.exports = content.locals; -// Hot Module Replacement -if(false) { - // When the styles change, update the <style> tags - if(!content.locals) { - module.hot.accept("!!../../../css-loader/index.js!./bootstrap.css", function() { - var newContent = require("!!../../../css-loader/index.js!./bootstrap.css"); - if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; - update(newContent); - }); - } - // When the module is disposed, remove the <style> tags - module.hot.dispose(function() { update(); }); +module.exports = { + check: check, + decode: decode, + encode: encode } + /***/ }), -/* 118 */ +/* 105 */ /***/ (function(module, exports, __webpack_require__) { -exports = module.exports = __webpack_require__(72)(undefined); -// imports - +var hash = exports; -// module -exports.push([module.i, "/*!\n * Bootstrap v4.0.0-alpha.6 (https://getbootstrap.com)\n * Copyright 2011-2017 The Bootstrap Authors\n * Copyright 2011-2017 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n */\n/*! normalize.css v5.0.0 | MIT License | github.com/necolas/normalize.css */\nhtml {\n font-family: sans-serif;\n line-height: 1.15;\n -ms-text-size-adjust: 100%;\n -webkit-text-size-adjust: 100%;\n}\n\nbody {\n margin: 0;\n}\n\narticle,\naside,\nfooter,\nheader,\nnav,\nsection {\n display: block;\n}\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\nfigcaption,\nfigure,\nmain {\n display: block;\n}\n\nfigure {\n margin: 1em 40px;\n}\n\nhr {\n -webkit-box-sizing: content-box;\n box-sizing: content-box;\n height: 0;\n overflow: visible;\n}\n\npre {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\na {\n background-color: transparent;\n -webkit-text-decoration-skip: objects;\n}\n\na:active,\na:hover {\n outline-width: 0;\n}\n\nabbr[title] {\n border-bottom: none;\n text-decoration: underline;\n text-decoration: underline dotted;\n}\n\nb,\nstrong {\n font-weight: inherit;\n}\n\nb,\nstrong {\n font-weight: bolder;\n}\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\ndfn {\n font-style: italic;\n}\n\nmark {\n background-color: #ff0;\n color: #000;\n}\n\nsmall {\n font-size: 80%;\n}\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\naudio,\nvideo {\n display: inline-block;\n}\n\naudio:not([controls]) {\n display: none;\n height: 0;\n}\n\nimg {\n border-style: none;\n}\n\nsvg:not(:root) {\n overflow: hidden;\n}\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: sans-serif;\n font-size: 100%;\n line-height: 1.15;\n margin: 0;\n}\n\nbutton,\ninput {\n overflow: visible;\n}\n\nbutton,\nselect {\n text-transform: none;\n}\n\nbutton,\nhtml [type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\nfieldset {\n border: 1px solid #c0c0c0;\n margin: 0 2px;\n padding: 0.35em 0.625em 0.75em;\n}\n\nlegend {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: inherit;\n display: table;\n max-width: 100%;\n padding: 0;\n white-space: normal;\n}\n\nprogress {\n display: inline-block;\n vertical-align: baseline;\n}\n\ntextarea {\n overflow: auto;\n}\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n padding: 0;\n}\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n[type=\"search\"] {\n -webkit-appearance: textfield;\n outline-offset: -2px;\n}\n\n[type=\"search\"]::-webkit-search-cancel-button,\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n::-webkit-file-upload-button {\n -webkit-appearance: button;\n font: inherit;\n}\n\ndetails,\nmenu {\n display: block;\n}\n\nsummary {\n display: list-item;\n}\n\ncanvas {\n display: inline-block;\n}\n\ntemplate {\n display: none;\n}\n\n[hidden] {\n display: none;\n}\n\n@media print {\n *,\n *::before,\n *::after,\n p::first-letter,\n div::first-letter,\n blockquote::first-letter,\n li::first-letter,\n p::first-line,\n div::first-line,\n blockquote::first-line,\n li::first-line {\n text-shadow: none !important;\n -webkit-box-shadow: none !important;\n box-shadow: none !important;\n }\n a,\n a:visited {\n text-decoration: underline;\n }\n abbr[title]::after {\n content: \" (\" attr(title) \")\";\n }\n pre {\n white-space: pre-wrap !important;\n }\n pre,\n blockquote {\n border: 1px solid #999;\n page-break-inside: avoid;\n }\n thead {\n display: table-header-group;\n }\n tr,\n img {\n page-break-inside: avoid;\n }\n p,\n h2,\n h3 {\n orphans: 3;\n widows: 3;\n }\n h2,\n h3 {\n page-break-after: avoid;\n }\n .navbar {\n display: none;\n }\n .badge {\n border: 1px solid #000;\n }\n .table {\n border-collapse: collapse !important;\n }\n .table td,\n .table th {\n background-color: #fff !important;\n }\n .table-bordered th,\n .table-bordered td {\n border: 1px solid #ddd !important;\n }\n}\n\nhtml {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n}\n\n*,\n*::before,\n*::after {\n -webkit-box-sizing: inherit;\n box-sizing: inherit;\n}\n\n@-ms-viewport {\n width: device-width;\n}\n\nhtml {\n -ms-overflow-style: scrollbar;\n -webkit-tap-highlight-color: transparent;\n}\n\nbody {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.5;\n color: #292b2c;\n background-color: #fff;\n}\n\n[tabindex=\"-1\"]:focus {\n outline: none !important;\n}\n\nh1, h2, h3, h4, h5, h6 {\n margin-top: 0;\n margin-bottom: .5rem;\n}\n\np {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nabbr[title],\nabbr[data-original-title] {\n cursor: help;\n}\n\naddress {\n margin-bottom: 1rem;\n font-style: normal;\n line-height: inherit;\n}\n\nol,\nul,\ndl {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nol ol,\nul ul,\nol ul,\nul ol {\n margin-bottom: 0;\n}\n\ndt {\n font-weight: bold;\n}\n\ndd {\n margin-bottom: .5rem;\n margin-left: 0;\n}\n\nblockquote {\n margin: 0 0 1rem;\n}\n\na {\n color: #0275d8;\n text-decoration: none;\n}\n\na:focus, a:hover {\n color: #014c8c;\n text-decoration: underline;\n}\n\na:not([href]):not([tabindex]) {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus, a:not([href]):not([tabindex]):hover {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus {\n outline: 0;\n}\n\npre {\n margin-top: 0;\n margin-bottom: 1rem;\n overflow: auto;\n}\n\nfigure {\n margin: 0 0 1rem;\n}\n\nimg {\n vertical-align: middle;\n}\n\n[role=\"button\"] {\n cursor: pointer;\n}\n\na,\narea,\nbutton,\n[role=\"button\"],\ninput,\nlabel,\nselect,\nsummary,\ntextarea {\n -ms-touch-action: manipulation;\n touch-action: manipulation;\n}\n\ntable {\n border-collapse: collapse;\n background-color: transparent;\n}\n\ncaption {\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n color: #636c72;\n text-align: left;\n caption-side: bottom;\n}\n\nth {\n text-align: left;\n}\n\nlabel {\n display: inline-block;\n margin-bottom: .5rem;\n}\n\nbutton:focus {\n outline: 1px dotted;\n outline: 5px auto -webkit-focus-ring-color;\n}\n\ninput,\nbutton,\nselect,\ntextarea {\n line-height: inherit;\n}\n\ninput[type=\"radio\"]:disabled,\ninput[type=\"checkbox\"]:disabled {\n cursor: not-allowed;\n}\n\ninput[type=\"date\"],\ninput[type=\"time\"],\ninput[type=\"datetime-local\"],\ninput[type=\"month\"] {\n -webkit-appearance: listbox;\n}\n\ntextarea {\n resize: vertical;\n}\n\nfieldset {\n min-width: 0;\n padding: 0;\n margin: 0;\n border: 0;\n}\n\nlegend {\n display: block;\n width: 100%;\n padding: 0;\n margin-bottom: .5rem;\n font-size: 1.5rem;\n line-height: inherit;\n}\n\ninput[type=\"search\"] {\n -webkit-appearance: none;\n}\n\noutput {\n display: inline-block;\n}\n\n[hidden] {\n display: none !important;\n}\n\nh1, h2, h3, h4, h5, h6,\n.h1, .h2, .h3, .h4, .h5, .h6 {\n margin-bottom: 0.5rem;\n font-family: inherit;\n font-weight: 500;\n line-height: 1.1;\n color: inherit;\n}\n\nh1, .h1 {\n font-size: 2.5rem;\n}\n\nh2, .h2 {\n font-size: 2rem;\n}\n\nh3, .h3 {\n font-size: 1.75rem;\n}\n\nh4, .h4 {\n font-size: 1.5rem;\n}\n\nh5, .h5 {\n font-size: 1.25rem;\n}\n\nh6, .h6 {\n font-size: 1rem;\n}\n\n.lead {\n font-size: 1.25rem;\n font-weight: 300;\n}\n\n.display-1 {\n font-size: 6rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-2 {\n font-size: 5.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-3 {\n font-size: 4.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-4 {\n font-size: 3.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\nhr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n border: 0;\n border-top: 1px solid rgba(0, 0, 0, 0.1);\n}\n\nsmall,\n.small {\n font-size: 80%;\n font-weight: normal;\n}\n\nmark,\n.mark {\n padding: 0.2em;\n background-color: #fcf8e3;\n}\n\n.list-unstyled {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline-item {\n display: inline-block;\n}\n\n.list-inline-item:not(:last-child) {\n margin-right: 5px;\n}\n\n.initialism {\n font-size: 90%;\n text-transform: uppercase;\n}\n\n.blockquote {\n padding: 0.5rem 1rem;\n margin-bottom: 1rem;\n font-size: 1.25rem;\n border-left: 0.25rem solid #eceeef;\n}\n\n.blockquote-footer {\n display: block;\n font-size: 80%;\n color: #636c72;\n}\n\n.blockquote-footer::before {\n content: \"\\2014 \\A0\";\n}\n\n.blockquote-reverse {\n padding-right: 1rem;\n padding-left: 0;\n text-align: right;\n border-right: 0.25rem solid #eceeef;\n border-left: 0;\n}\n\n.blockquote-reverse .blockquote-footer::before {\n content: \"\";\n}\n\n.blockquote-reverse .blockquote-footer::after {\n content: \"\\A0 \\2014\";\n}\n\n.img-fluid {\n max-width: 100%;\n height: auto;\n}\n\n.img-thumbnail {\n padding: 0.25rem;\n background-color: #fff;\n border: 1px solid #ddd;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n max-width: 100%;\n height: auto;\n}\n\n.figure {\n display: inline-block;\n}\n\n.figure-img {\n margin-bottom: 0.5rem;\n line-height: 1;\n}\n\n.figure-caption {\n font-size: 90%;\n color: #636c72;\n}\n\ncode,\nkbd,\npre,\nsamp {\n font-family: Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;\n}\n\ncode {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #bd4147;\n background-color: #f7f7f9;\n border-radius: 0.25rem;\n}\n\na > code {\n padding: 0;\n color: inherit;\n background-color: inherit;\n}\n\nkbd {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #fff;\n background-color: #292b2c;\n border-radius: 0.2rem;\n}\n\nkbd kbd {\n padding: 0;\n font-size: 100%;\n font-weight: bold;\n}\n\npre {\n display: block;\n margin-top: 0;\n margin-bottom: 1rem;\n font-size: 90%;\n color: #292b2c;\n}\n\npre code {\n padding: 0;\n font-size: inherit;\n color: inherit;\n background-color: transparent;\n border-radius: 0;\n}\n\n.pre-scrollable {\n max-height: 340px;\n overflow-y: scroll;\n}\n\n.container {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .container {\n width: 540px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n width: 720px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n width: 960px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n width: 1140px;\n max-width: 100%;\n }\n}\n\n.container-fluid {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.row {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: wrap;\n -ms-flex-wrap: wrap;\n flex-wrap: wrap;\n margin-right: -15px;\n margin-left: -15px;\n}\n\n@media (min-width: 576px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 768px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 992px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 1200px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n.no-gutters {\n margin-right: 0;\n margin-left: 0;\n}\n\n.no-gutters > .col,\n.no-gutters > [class*=\"col-\"] {\n padding-right: 0;\n padding-left: 0;\n}\n\n.col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n position: relative;\n width: 100%;\n min-height: 1px;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.col {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n}\n\n.col-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n}\n\n.col-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n}\n\n.col-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n}\n\n.col-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n}\n\n.col-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n}\n\n.col-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n}\n\n.col-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n}\n\n.col-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n}\n\n.col-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n}\n\n.col-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n}\n\n.col-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n}\n\n.col-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n}\n\n.col-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n}\n\n.pull-0 {\n right: auto;\n}\n\n.pull-1 {\n right: 8.333333%;\n}\n\n.pull-2 {\n right: 16.666667%;\n}\n\n.pull-3 {\n right: 25%;\n}\n\n.pull-4 {\n right: 33.333333%;\n}\n\n.pull-5 {\n right: 41.666667%;\n}\n\n.pull-6 {\n right: 50%;\n}\n\n.pull-7 {\n right: 58.333333%;\n}\n\n.pull-8 {\n right: 66.666667%;\n}\n\n.pull-9 {\n right: 75%;\n}\n\n.pull-10 {\n right: 83.333333%;\n}\n\n.pull-11 {\n right: 91.666667%;\n}\n\n.pull-12 {\n right: 100%;\n}\n\n.push-0 {\n left: auto;\n}\n\n.push-1 {\n left: 8.333333%;\n}\n\n.push-2 {\n left: 16.666667%;\n}\n\n.push-3 {\n left: 25%;\n}\n\n.push-4 {\n left: 33.333333%;\n}\n\n.push-5 {\n left: 41.666667%;\n}\n\n.push-6 {\n left: 50%;\n}\n\n.push-7 {\n left: 58.333333%;\n}\n\n.push-8 {\n left: 66.666667%;\n}\n\n.push-9 {\n left: 75%;\n}\n\n.push-10 {\n left: 83.333333%;\n}\n\n.push-11 {\n left: 91.666667%;\n}\n\n.push-12 {\n left: 100%;\n}\n\n.offset-1 {\n margin-left: 8.333333%;\n}\n\n.offset-2 {\n margin-left: 16.666667%;\n}\n\n.offset-3 {\n margin-left: 25%;\n}\n\n.offset-4 {\n margin-left: 33.333333%;\n}\n\n.offset-5 {\n margin-left: 41.666667%;\n}\n\n.offset-6 {\n margin-left: 50%;\n}\n\n.offset-7 {\n margin-left: 58.333333%;\n}\n\n.offset-8 {\n margin-left: 66.666667%;\n}\n\n.offset-9 {\n margin-left: 75%;\n}\n\n.offset-10 {\n margin-left: 83.333333%;\n}\n\n.offset-11 {\n margin-left: 91.666667%;\n}\n\n@media (min-width: 576px) {\n .col-sm {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-sm-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-sm-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-sm-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-sm-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-sm-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-sm-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-sm-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-sm-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-sm-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-sm-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-sm-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-sm-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-sm-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-sm-0 {\n right: auto;\n }\n .pull-sm-1 {\n right: 8.333333%;\n }\n .pull-sm-2 {\n right: 16.666667%;\n }\n .pull-sm-3 {\n right: 25%;\n }\n .pull-sm-4 {\n right: 33.333333%;\n }\n .pull-sm-5 {\n right: 41.666667%;\n }\n .pull-sm-6 {\n right: 50%;\n }\n .pull-sm-7 {\n right: 58.333333%;\n }\n .pull-sm-8 {\n right: 66.666667%;\n }\n .pull-sm-9 {\n right: 75%;\n }\n .pull-sm-10 {\n right: 83.333333%;\n }\n .pull-sm-11 {\n right: 91.666667%;\n }\n .pull-sm-12 {\n right: 100%;\n }\n .push-sm-0 {\n left: auto;\n }\n .push-sm-1 {\n left: 8.333333%;\n }\n .push-sm-2 {\n left: 16.666667%;\n }\n .push-sm-3 {\n left: 25%;\n }\n .push-sm-4 {\n left: 33.333333%;\n }\n .push-sm-5 {\n left: 41.666667%;\n }\n .push-sm-6 {\n left: 50%;\n }\n .push-sm-7 {\n left: 58.333333%;\n }\n .push-sm-8 {\n left: 66.666667%;\n }\n .push-sm-9 {\n left: 75%;\n }\n .push-sm-10 {\n left: 83.333333%;\n }\n .push-sm-11 {\n left: 91.666667%;\n }\n .push-sm-12 {\n left: 100%;\n }\n .offset-sm-0 {\n margin-left: 0%;\n }\n .offset-sm-1 {\n margin-left: 8.333333%;\n }\n .offset-sm-2 {\n margin-left: 16.666667%;\n }\n .offset-sm-3 {\n margin-left: 25%;\n }\n .offset-sm-4 {\n margin-left: 33.333333%;\n }\n .offset-sm-5 {\n margin-left: 41.666667%;\n }\n .offset-sm-6 {\n margin-left: 50%;\n }\n .offset-sm-7 {\n margin-left: 58.333333%;\n }\n .offset-sm-8 {\n margin-left: 66.666667%;\n }\n .offset-sm-9 {\n margin-left: 75%;\n }\n .offset-sm-10 {\n margin-left: 83.333333%;\n }\n .offset-sm-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 768px) {\n .col-md {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-md-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-md-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-md-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-md-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-md-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-md-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-md-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-md-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-md-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-md-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-md-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-md-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-md-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-md-0 {\n right: auto;\n }\n .pull-md-1 {\n right: 8.333333%;\n }\n .pull-md-2 {\n right: 16.666667%;\n }\n .pull-md-3 {\n right: 25%;\n }\n .pull-md-4 {\n right: 33.333333%;\n }\n .pull-md-5 {\n right: 41.666667%;\n }\n .pull-md-6 {\n right: 50%;\n }\n .pull-md-7 {\n right: 58.333333%;\n }\n .pull-md-8 {\n right: 66.666667%;\n }\n .pull-md-9 {\n right: 75%;\n }\n .pull-md-10 {\n right: 83.333333%;\n }\n .pull-md-11 {\n right: 91.666667%;\n }\n .pull-md-12 {\n right: 100%;\n }\n .push-md-0 {\n left: auto;\n }\n .push-md-1 {\n left: 8.333333%;\n }\n .push-md-2 {\n left: 16.666667%;\n }\n .push-md-3 {\n left: 25%;\n }\n .push-md-4 {\n left: 33.333333%;\n }\n .push-md-5 {\n left: 41.666667%;\n }\n .push-md-6 {\n left: 50%;\n }\n .push-md-7 {\n left: 58.333333%;\n }\n .push-md-8 {\n left: 66.666667%;\n }\n .push-md-9 {\n left: 75%;\n }\n .push-md-10 {\n left: 83.333333%;\n }\n .push-md-11 {\n left: 91.666667%;\n }\n .push-md-12 {\n left: 100%;\n }\n .offset-md-0 {\n margin-left: 0%;\n }\n .offset-md-1 {\n margin-left: 8.333333%;\n }\n .offset-md-2 {\n margin-left: 16.666667%;\n }\n .offset-md-3 {\n margin-left: 25%;\n }\n .offset-md-4 {\n margin-left: 33.333333%;\n }\n .offset-md-5 {\n margin-left: 41.666667%;\n }\n .offset-md-6 {\n margin-left: 50%;\n }\n .offset-md-7 {\n margin-left: 58.333333%;\n }\n .offset-md-8 {\n margin-left: 66.666667%;\n }\n .offset-md-9 {\n margin-left: 75%;\n }\n .offset-md-10 {\n margin-left: 83.333333%;\n }\n .offset-md-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 992px) {\n .col-lg {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-lg-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-lg-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-lg-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-lg-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-lg-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-lg-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-lg-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-lg-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-lg-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-lg-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-lg-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-lg-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-lg-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-lg-0 {\n right: auto;\n }\n .pull-lg-1 {\n right: 8.333333%;\n }\n .pull-lg-2 {\n right: 16.666667%;\n }\n .pull-lg-3 {\n right: 25%;\n }\n .pull-lg-4 {\n right: 33.333333%;\n }\n .pull-lg-5 {\n right: 41.666667%;\n }\n .pull-lg-6 {\n right: 50%;\n }\n .pull-lg-7 {\n right: 58.333333%;\n }\n .pull-lg-8 {\n right: 66.666667%;\n }\n .pull-lg-9 {\n right: 75%;\n }\n .pull-lg-10 {\n right: 83.333333%;\n }\n .pull-lg-11 {\n right: 91.666667%;\n }\n .pull-lg-12 {\n right: 100%;\n }\n .push-lg-0 {\n left: auto;\n }\n .push-lg-1 {\n left: 8.333333%;\n }\n .push-lg-2 {\n left: 16.666667%;\n }\n .push-lg-3 {\n left: 25%;\n }\n .push-lg-4 {\n left: 33.333333%;\n }\n .push-lg-5 {\n left: 41.666667%;\n }\n .push-lg-6 {\n left: 50%;\n }\n .push-lg-7 {\n left: 58.333333%;\n }\n .push-lg-8 {\n left: 66.666667%;\n }\n .push-lg-9 {\n left: 75%;\n }\n .push-lg-10 {\n left: 83.333333%;\n }\n .push-lg-11 {\n left: 91.666667%;\n }\n .push-lg-12 {\n left: 100%;\n }\n .offset-lg-0 {\n margin-left: 0%;\n }\n .offset-lg-1 {\n margin-left: 8.333333%;\n }\n .offset-lg-2 {\n margin-left: 16.666667%;\n }\n .offset-lg-3 {\n margin-left: 25%;\n }\n .offset-lg-4 {\n margin-left: 33.333333%;\n }\n .offset-lg-5 {\n margin-left: 41.666667%;\n }\n .offset-lg-6 {\n margin-left: 50%;\n }\n .offset-lg-7 {\n margin-left: 58.333333%;\n }\n .offset-lg-8 {\n margin-left: 66.666667%;\n }\n .offset-lg-9 {\n margin-left: 75%;\n }\n .offset-lg-10 {\n margin-left: 83.333333%;\n }\n .offset-lg-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 1200px) {\n .col-xl {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-xl-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-xl-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-xl-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-xl-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-xl-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-xl-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-xl-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-xl-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-xl-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-xl-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-xl-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-xl-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-xl-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-xl-0 {\n right: auto;\n }\n .pull-xl-1 {\n right: 8.333333%;\n }\n .pull-xl-2 {\n right: 16.666667%;\n }\n .pull-xl-3 {\n right: 25%;\n }\n .pull-xl-4 {\n right: 33.333333%;\n }\n .pull-xl-5 {\n right: 41.666667%;\n }\n .pull-xl-6 {\n right: 50%;\n }\n .pull-xl-7 {\n right: 58.333333%;\n }\n .pull-xl-8 {\n right: 66.666667%;\n }\n .pull-xl-9 {\n right: 75%;\n }\n .pull-xl-10 {\n right: 83.333333%;\n }\n .pull-xl-11 {\n right: 91.666667%;\n }\n .pull-xl-12 {\n right: 100%;\n }\n .push-xl-0 {\n left: auto;\n }\n .push-xl-1 {\n left: 8.333333%;\n }\n .push-xl-2 {\n left: 16.666667%;\n }\n .push-xl-3 {\n left: 25%;\n }\n .push-xl-4 {\n left: 33.333333%;\n }\n .push-xl-5 {\n left: 41.666667%;\n }\n .push-xl-6 {\n left: 50%;\n }\n .push-xl-7 {\n left: 58.333333%;\n }\n .push-xl-8 {\n left: 66.666667%;\n }\n .push-xl-9 {\n left: 75%;\n }\n .push-xl-10 {\n left: 83.333333%;\n }\n .push-xl-11 {\n left: 91.666667%;\n }\n .push-xl-12 {\n left: 100%;\n }\n .offset-xl-0 {\n margin-left: 0%;\n }\n .offset-xl-1 {\n margin-left: 8.333333%;\n }\n .offset-xl-2 {\n margin-left: 16.666667%;\n }\n .offset-xl-3 {\n margin-left: 25%;\n }\n .offset-xl-4 {\n margin-left: 33.333333%;\n }\n .offset-xl-5 {\n margin-left: 41.666667%;\n }\n .offset-xl-6 {\n margin-left: 50%;\n }\n .offset-xl-7 {\n margin-left: 58.333333%;\n }\n .offset-xl-8 {\n margin-left: 66.666667%;\n }\n .offset-xl-9 {\n margin-left: 75%;\n }\n .offset-xl-10 {\n margin-left: 83.333333%;\n }\n .offset-xl-11 {\n margin-left: 91.666667%;\n }\n}\n\n.table {\n width: 100%;\n max-width: 100%;\n margin-bottom: 1rem;\n}\n\n.table th,\n.table td {\n padding: 0.75rem;\n vertical-align: top;\n border-top: 1px solid #eceeef;\n}\n\n.table thead th {\n vertical-align: bottom;\n border-bottom: 2px solid #eceeef;\n}\n\n.table tbody + tbody {\n border-top: 2px solid #eceeef;\n}\n\n.table .table {\n background-color: #fff;\n}\n\n.table-sm th,\n.table-sm td {\n padding: 0.3rem;\n}\n\n.table-bordered {\n border: 1px solid #eceeef;\n}\n\n.table-bordered th,\n.table-bordered td {\n border: 1px solid #eceeef;\n}\n\n.table-bordered thead th,\n.table-bordered thead td {\n border-bottom-width: 2px;\n}\n\n.table-striped tbody tr:nth-of-type(odd) {\n background-color: rgba(0, 0, 0, 0.05);\n}\n\n.table-hover tbody tr:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-active,\n.table-active > th,\n.table-active > td {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover > td,\n.table-hover .table-active:hover > th {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-success,\n.table-success > th,\n.table-success > td {\n background-color: #dff0d8;\n}\n\n.table-hover .table-success:hover {\n background-color: #d0e9c6;\n}\n\n.table-hover .table-success:hover > td,\n.table-hover .table-success:hover > th {\n background-color: #d0e9c6;\n}\n\n.table-info,\n.table-info > th,\n.table-info > td {\n background-color: #d9edf7;\n}\n\n.table-hover .table-info:hover {\n background-color: #c4e3f3;\n}\n\n.table-hover .table-info:hover > td,\n.table-hover .table-info:hover > th {\n background-color: #c4e3f3;\n}\n\n.table-warning,\n.table-warning > th,\n.table-warning > td {\n background-color: #fcf8e3;\n}\n\n.table-hover .table-warning:hover {\n background-color: #faf2cc;\n}\n\n.table-hover .table-warning:hover > td,\n.table-hover .table-warning:hover > th {\n background-color: #faf2cc;\n}\n\n.table-danger,\n.table-danger > th,\n.table-danger > td {\n background-color: #f2dede;\n}\n\n.table-hover .table-danger:hover {\n background-color: #ebcccc;\n}\n\n.table-hover .table-danger:hover > td,\n.table-hover .table-danger:hover > th {\n background-color: #ebcccc;\n}\n\n.thead-inverse th {\n color: #fff;\n background-color: #292b2c;\n}\n\n.thead-default th {\n color: #464a4c;\n background-color: #eceeef;\n}\n\n.table-inverse {\n color: #fff;\n background-color: #292b2c;\n}\n\n.table-inverse th,\n.table-inverse td,\n.table-inverse thead th {\n border-color: #fff;\n}\n\n.table-inverse.table-bordered {\n border: 0;\n}\n\n.table-responsive {\n display: block;\n width: 100%;\n overflow-x: auto;\n -ms-overflow-style: -ms-autohiding-scrollbar;\n}\n\n.table-responsive.table-bordered {\n border: 0;\n}\n\n.form-control {\n display: block;\n width: 100%;\n padding: 0.5rem 0.75rem;\n font-size: 1rem;\n line-height: 1.25;\n color: #464a4c;\n background-color: #fff;\n background-image: none;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -webkit-transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n -o-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n}\n\n.form-control::-ms-expand {\n background-color: transparent;\n border: 0;\n}\n\n.form-control:focus {\n color: #464a4c;\n background-color: #fff;\n border-color: #5cb3fd;\n outline: none;\n}\n\n.form-control::-webkit-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::-moz-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:-ms-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:disabled, .form-control[readonly] {\n background-color: #eceeef;\n opacity: 1;\n}\n\n.form-control:disabled {\n cursor: not-allowed;\n}\n\nselect.form-control:not([size]):not([multiple]) {\n height: calc(2.25rem + 2px);\n}\n\nselect.form-control:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.form-control-file,\n.form-control-range {\n display: block;\n}\n\n.col-form-label {\n padding-top: calc(0.5rem - 1px * 2);\n padding-bottom: calc(0.5rem - 1px * 2);\n margin-bottom: 0;\n}\n\n.col-form-label-lg {\n padding-top: calc(0.75rem - 1px * 2);\n padding-bottom: calc(0.75rem - 1px * 2);\n font-size: 1.25rem;\n}\n\n.col-form-label-sm {\n padding-top: calc(0.25rem - 1px * 2);\n padding-bottom: calc(0.25rem - 1px * 2);\n font-size: 0.875rem;\n}\n\n.col-form-legend {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n font-size: 1rem;\n}\n\n.form-control-static {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n line-height: 1.25;\n border: solid transparent;\n border-width: 1px 0;\n}\n\n.form-control-static.form-control-sm, .input-group-sm > .form-control-static.form-control,\n.input-group-sm > .form-control-static.input-group-addon,\n.input-group-sm > .input-group-btn > .form-control-static.btn, .form-control-static.form-control-lg, .input-group-lg > .form-control-static.form-control,\n.input-group-lg > .form-control-static.input-group-addon,\n.input-group-lg > .input-group-btn > .form-control-static.btn {\n padding-right: 0;\n padding-left: 0;\n}\n\n.form-control-sm, .input-group-sm > .form-control,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\nselect.form-control-sm:not([size]):not([multiple]), .input-group-sm > select.form-control:not([size]):not([multiple]),\n.input-group-sm > select.input-group-addon:not([size]):not([multiple]),\n.input-group-sm > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 1.8125rem;\n}\n\n.form-control-lg, .input-group-lg > .form-control,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\nselect.form-control-lg:not([size]):not([multiple]), .input-group-lg > select.form-control:not([size]):not([multiple]),\n.input-group-lg > select.input-group-addon:not([size]):not([multiple]),\n.input-group-lg > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 3.166667rem;\n}\n\n.form-group {\n margin-bottom: 1rem;\n}\n\n.form-text {\n display: block;\n margin-top: 0.25rem;\n}\n\n.form-check {\n position: relative;\n display: block;\n margin-bottom: 0.5rem;\n}\n\n.form-check.disabled .form-check-label {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.form-check-label {\n padding-left: 1.25rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.form-check-input {\n position: absolute;\n margin-top: 0.25rem;\n margin-left: -1.25rem;\n}\n\n.form-check-input:only-child {\n position: static;\n}\n\n.form-check-inline {\n display: inline-block;\n}\n\n.form-check-inline .form-check-label {\n vertical-align: middle;\n}\n\n.form-check-inline + .form-check-inline {\n margin-left: 0.75rem;\n}\n\n.form-control-feedback {\n margin-top: 0.25rem;\n}\n\n.form-control-success,\n.form-control-warning,\n.form-control-danger {\n padding-right: 2.25rem;\n background-repeat: no-repeat;\n background-position: center right 0.5625rem;\n -webkit-background-size: 1.125rem 1.125rem;\n background-size: 1.125rem 1.125rem;\n}\n\n.has-success .form-control-feedback,\n.has-success .form-control-label,\n.has-success .col-form-label,\n.has-success .form-check-label,\n.has-success .custom-control {\n color: #5cb85c;\n}\n\n.has-success .form-control {\n border-color: #5cb85c;\n}\n\n.has-success .input-group-addon {\n color: #5cb85c;\n border-color: #5cb85c;\n background-color: #eaf6ea;\n}\n\n.has-success .form-control-success {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%235cb85c' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3E%3C/svg%3E\");\n}\n\n.has-warning .form-control-feedback,\n.has-warning .form-control-label,\n.has-warning .col-form-label,\n.has-warning .form-check-label,\n.has-warning .custom-control {\n color: #f0ad4e;\n}\n\n.has-warning .form-control {\n border-color: #f0ad4e;\n}\n\n.has-warning .input-group-addon {\n color: #f0ad4e;\n border-color: #f0ad4e;\n background-color: white;\n}\n\n.has-warning .form-control-warning {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23f0ad4e' d='M4.4 5.324h-.8v-2.46h.8zm0 1.42h-.8V5.89h.8zM3.76.63L.04 7.075c-.115.2.016.425.26.426h7.397c.242 0 .372-.226.258-.426C6.726 4.924 5.47 2.79 4.253.63c-.113-.174-.39-.174-.494 0z'/%3E%3C/svg%3E\");\n}\n\n.has-danger .form-control-feedback,\n.has-danger .form-control-label,\n.has-danger .col-form-label,\n.has-danger .form-check-label,\n.has-danger .custom-control {\n color: #d9534f;\n}\n\n.has-danger .form-control {\n border-color: #d9534f;\n}\n\n.has-danger .input-group-addon {\n color: #d9534f;\n border-color: #d9534f;\n background-color: #fdf7f7;\n}\n\n.has-danger .form-control-danger {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23d9534f' viewBox='-2 -2 7 7'%3E%3Cpath stroke='%23d9534f' d='M0 0l3 3m0-3L0 3'/%3E%3Ccircle r='.5'/%3E%3Ccircle cx='3' r='.5'/%3E%3Ccircle cy='3' r='.5'/%3E%3Ccircle cx='3' cy='3' r='.5'/%3E%3C/svg%3E\");\n}\n\n.form-inline {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.form-inline .form-check {\n width: 100%;\n}\n\n@media (min-width: 576px) {\n .form-inline label {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n margin-bottom: 0;\n }\n .form-inline .form-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n margin-bottom: 0;\n }\n .form-inline .form-control {\n display: inline-block;\n width: auto;\n vertical-align: middle;\n }\n .form-inline .form-control-static {\n display: inline-block;\n }\n .form-inline .input-group {\n width: auto;\n }\n .form-inline .form-control-label {\n margin-bottom: 0;\n vertical-align: middle;\n }\n .form-inline .form-check {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: auto;\n margin-top: 0;\n margin-bottom: 0;\n }\n .form-inline .form-check-label {\n padding-left: 0;\n }\n .form-inline .form-check-input {\n position: relative;\n margin-top: 0;\n margin-right: 0.25rem;\n margin-left: 0;\n }\n .form-inline .custom-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n }\n .form-inline .custom-control-indicator {\n position: static;\n display: inline-block;\n margin-right: 0.25rem;\n vertical-align: text-bottom;\n }\n .form-inline .has-feedback .form-control-feedback {\n top: 0;\n }\n}\n\n.btn {\n display: inline-block;\n font-weight: normal;\n line-height: 1.25;\n text-align: center;\n white-space: nowrap;\n vertical-align: middle;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n border: 1px solid transparent;\n padding: 0.5rem 1rem;\n font-size: 1rem;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n}\n\n.btn:focus, .btn:hover {\n text-decoration: none;\n}\n\n.btn:focus, .btn.focus {\n outline: 0;\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n}\n\n.btn.disabled, .btn:disabled {\n cursor: not-allowed;\n opacity: .65;\n}\n\n.btn:active, .btn.active {\n background-image: none;\n}\n\na.btn.disabled,\nfieldset[disabled] a.btn {\n pointer-events: none;\n}\n\n.btn-primary {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:hover {\n color: #fff;\n background-color: #025aa5;\n border-color: #01549b;\n}\n\n.btn-primary:focus, .btn-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-primary.disabled, .btn-primary:disabled {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:active, .btn-primary.active,\n.show > .btn-primary.dropdown-toggle {\n color: #fff;\n background-color: #025aa5;\n background-image: none;\n border-color: #01549b;\n}\n\n.btn-secondary {\n color: #292b2c;\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:hover {\n color: #292b2c;\n background-color: #e6e6e6;\n border-color: #adadad;\n}\n\n.btn-secondary:focus, .btn-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-secondary.disabled, .btn-secondary:disabled {\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:active, .btn-secondary.active,\n.show > .btn-secondary.dropdown-toggle {\n color: #292b2c;\n background-color: #e6e6e6;\n background-image: none;\n border-color: #adadad;\n}\n\n.btn-info {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:hover {\n color: #fff;\n background-color: #31b0d5;\n border-color: #2aabd2;\n}\n\n.btn-info:focus, .btn-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-info.disabled, .btn-info:disabled {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:active, .btn-info.active,\n.show > .btn-info.dropdown-toggle {\n color: #fff;\n background-color: #31b0d5;\n background-image: none;\n border-color: #2aabd2;\n}\n\n.btn-success {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:hover {\n color: #fff;\n background-color: #449d44;\n border-color: #419641;\n}\n\n.btn-success:focus, .btn-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-success.disabled, .btn-success:disabled {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:active, .btn-success.active,\n.show > .btn-success.dropdown-toggle {\n color: #fff;\n background-color: #449d44;\n background-image: none;\n border-color: #419641;\n}\n\n.btn-warning {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:hover {\n color: #fff;\n background-color: #ec971f;\n border-color: #eb9316;\n}\n\n.btn-warning:focus, .btn-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-warning.disabled, .btn-warning:disabled {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:active, .btn-warning.active,\n.show > .btn-warning.dropdown-toggle {\n color: #fff;\n background-color: #ec971f;\n background-image: none;\n border-color: #eb9316;\n}\n\n.btn-danger {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:hover {\n color: #fff;\n background-color: #c9302c;\n border-color: #c12e2a;\n}\n\n.btn-danger:focus, .btn-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-danger.disabled, .btn-danger:disabled {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:active, .btn-danger.active,\n.show > .btn-danger.dropdown-toggle {\n color: #fff;\n background-color: #c9302c;\n background-image: none;\n border-color: #c12e2a;\n}\n\n.btn-outline-primary {\n color: #0275d8;\n background-image: none;\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:hover {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:focus, .btn-outline-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-outline-primary.disabled, .btn-outline-primary:disabled {\n color: #0275d8;\n background-color: transparent;\n}\n\n.btn-outline-primary:active, .btn-outline-primary.active,\n.show > .btn-outline-primary.dropdown-toggle {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-secondary {\n color: #ccc;\n background-image: none;\n background-color: transparent;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:hover {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:focus, .btn-outline-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-outline-secondary.disabled, .btn-outline-secondary:disabled {\n color: #ccc;\n background-color: transparent;\n}\n\n.btn-outline-secondary:active, .btn-outline-secondary.active,\n.show > .btn-outline-secondary.dropdown-toggle {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-info {\n color: #5bc0de;\n background-image: none;\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:hover {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:focus, .btn-outline-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-outline-info.disabled, .btn-outline-info:disabled {\n color: #5bc0de;\n background-color: transparent;\n}\n\n.btn-outline-info:active, .btn-outline-info.active,\n.show > .btn-outline-info.dropdown-toggle {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-success {\n color: #5cb85c;\n background-image: none;\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:hover {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:focus, .btn-outline-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-outline-success.disabled, .btn-outline-success:disabled {\n color: #5cb85c;\n background-color: transparent;\n}\n\n.btn-outline-success:active, .btn-outline-success.active,\n.show > .btn-outline-success.dropdown-toggle {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-warning {\n color: #f0ad4e;\n background-image: none;\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:hover {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:focus, .btn-outline-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-outline-warning.disabled, .btn-outline-warning:disabled {\n color: #f0ad4e;\n background-color: transparent;\n}\n\n.btn-outline-warning:active, .btn-outline-warning.active,\n.show > .btn-outline-warning.dropdown-toggle {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-danger {\n color: #d9534f;\n background-image: none;\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:hover {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:focus, .btn-outline-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-outline-danger.disabled, .btn-outline-danger:disabled {\n color: #d9534f;\n background-color: transparent;\n}\n\n.btn-outline-danger:active, .btn-outline-danger.active,\n.show > .btn-outline-danger.dropdown-toggle {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-link {\n font-weight: normal;\n color: #0275d8;\n border-radius: 0;\n}\n\n.btn-link, .btn-link:active, .btn-link.active, .btn-link:disabled {\n background-color: transparent;\n}\n\n.btn-link, .btn-link:focus, .btn-link:active {\n border-color: transparent;\n}\n\n.btn-link:hover {\n border-color: transparent;\n}\n\n.btn-link:focus, .btn-link:hover {\n color: #014c8c;\n text-decoration: underline;\n background-color: transparent;\n}\n\n.btn-link:disabled {\n color: #636c72;\n}\n\n.btn-link:disabled:focus, .btn-link:disabled:hover {\n text-decoration: none;\n}\n\n.btn-lg, .btn-group-lg > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.btn-sm, .btn-group-sm > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.btn-block {\n display: block;\n width: 100%;\n}\n\n.btn-block + .btn-block {\n margin-top: 0.5rem;\n}\n\ninput[type=\"submit\"].btn-block,\ninput[type=\"reset\"].btn-block,\ninput[type=\"button\"].btn-block {\n width: 100%;\n}\n\n.fade {\n opacity: 0;\n -webkit-transition: opacity 0.15s linear;\n -o-transition: opacity 0.15s linear;\n transition: opacity 0.15s linear;\n}\n\n.fade.show {\n opacity: 1;\n}\n\n.collapse {\n display: none;\n}\n\n.collapse.show {\n display: block;\n}\n\ntr.collapse.show {\n display: table-row;\n}\n\ntbody.collapse.show {\n display: table-row-group;\n}\n\n.collapsing {\n position: relative;\n height: 0;\n overflow: hidden;\n -webkit-transition: height 0.35s ease;\n -o-transition: height 0.35s ease;\n transition: height 0.35s ease;\n}\n\n.dropup,\n.dropdown {\n position: relative;\n}\n\n.dropdown-toggle::after {\n display: inline-block;\n width: 0;\n height: 0;\n margin-left: 0.3em;\n vertical-align: middle;\n content: \"\";\n border-top: 0.3em solid;\n border-right: 0.3em solid transparent;\n border-left: 0.3em solid transparent;\n}\n\n.dropdown-toggle:focus {\n outline: 0;\n}\n\n.dropup .dropdown-toggle::after {\n border-top: 0;\n border-bottom: 0.3em solid;\n}\n\n.dropdown-menu {\n position: absolute;\n top: 100%;\n left: 0;\n z-index: 1000;\n display: none;\n float: left;\n min-width: 10rem;\n padding: 0.5rem 0;\n margin: 0.125rem 0 0;\n font-size: 1rem;\n color: #292b2c;\n text-align: left;\n list-style: none;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.dropdown-divider {\n height: 1px;\n margin: 0.5rem 0;\n overflow: hidden;\n background-color: #eceeef;\n}\n\n.dropdown-item {\n display: block;\n width: 100%;\n padding: 3px 1.5rem;\n clear: both;\n font-weight: normal;\n color: #292b2c;\n text-align: inherit;\n white-space: nowrap;\n background: none;\n border: 0;\n}\n\n.dropdown-item:focus, .dropdown-item:hover {\n color: #1d1e1f;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.dropdown-item.active, .dropdown-item:active {\n color: #fff;\n text-decoration: none;\n background-color: #0275d8;\n}\n\n.dropdown-item.disabled, .dropdown-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: transparent;\n}\n\n.show > .dropdown-menu {\n display: block;\n}\n\n.show > a {\n outline: 0;\n}\n\n.dropdown-menu-right {\n right: 0;\n left: auto;\n}\n\n.dropdown-menu-left {\n right: auto;\n left: 0;\n}\n\n.dropdown-header {\n display: block;\n padding: 0.5rem 1.5rem;\n margin-bottom: 0;\n font-size: 0.875rem;\n color: #636c72;\n white-space: nowrap;\n}\n\n.dropdown-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 990;\n}\n\n.dropup .dropdown-menu {\n top: auto;\n bottom: 100%;\n margin-bottom: 0.125rem;\n}\n\n.btn-group,\n.btn-group-vertical {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n vertical-align: middle;\n}\n\n.btn-group > .btn,\n.btn-group-vertical > .btn {\n position: relative;\n -webkit-box-flex: 0;\n -webkit-flex: 0 1 auto;\n -ms-flex: 0 1 auto;\n flex: 0 1 auto;\n}\n\n.btn-group > .btn:hover,\n.btn-group-vertical > .btn:hover {\n z-index: 2;\n}\n\n.btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active,\n.btn-group-vertical > .btn:focus,\n.btn-group-vertical > .btn:active,\n.btn-group-vertical > .btn.active {\n z-index: 2;\n}\n\n.btn-group .btn + .btn,\n.btn-group .btn + .btn-group,\n.btn-group .btn-group + .btn,\n.btn-group .btn-group + .btn-group,\n.btn-group-vertical .btn + .btn,\n.btn-group-vertical .btn + .btn-group,\n.btn-group-vertical .btn-group + .btn,\n.btn-group-vertical .btn-group + .btn-group {\n margin-left: -1px;\n}\n\n.btn-toolbar {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: start;\n -webkit-justify-content: flex-start;\n -ms-flex-pack: start;\n justify-content: flex-start;\n}\n\n.btn-toolbar .input-group {\n width: auto;\n}\n\n.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {\n border-radius: 0;\n}\n\n.btn-group > .btn:first-child {\n margin-left: 0;\n}\n\n.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn:last-child:not(:first-child),\n.btn-group > .dropdown-toggle:not(:first-child) {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group > .btn-group {\n float: left;\n}\n\n.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group .dropdown-toggle:active,\n.btn-group.open .dropdown-toggle {\n outline: 0;\n}\n\n.btn + .dropdown-toggle-split {\n padding-right: 0.75rem;\n padding-left: 0.75rem;\n}\n\n.btn + .dropdown-toggle-split::after {\n margin-left: 0;\n}\n\n.btn-sm + .dropdown-toggle-split, .btn-group-sm > .btn + .dropdown-toggle-split {\n padding-right: 0.375rem;\n padding-left: 0.375rem;\n}\n\n.btn-lg + .dropdown-toggle-split, .btn-group-lg > .btn + .dropdown-toggle-split {\n padding-right: 1.125rem;\n padding-left: 1.125rem;\n}\n\n.btn-group-vertical {\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.btn-group-vertical .btn,\n.btn-group-vertical .btn-group {\n width: 100%;\n}\n\n.btn-group-vertical > .btn + .btn,\n.btn-group-vertical > .btn + .btn-group,\n.btn-group-vertical > .btn-group + .btn,\n.btn-group-vertical > .btn-group + .btn-group {\n margin-top: -1px;\n margin-left: 0;\n}\n\n.btn-group-vertical > .btn:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn:first-child:not(:last-child) {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn:last-child:not(:first-child) {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n[data-toggle=\"buttons\"] > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn input[type=\"checkbox\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"checkbox\"] {\n position: absolute;\n clip: rect(0, 0, 0, 0);\n pointer-events: none;\n}\n\n.input-group {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n width: 100%;\n}\n\n.input-group .form-control {\n position: relative;\n z-index: 2;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n width: 1%;\n margin-bottom: 0;\n}\n\n.input-group .form-control:focus, .input-group .form-control:active, .input-group .form-control:hover {\n z-index: 3;\n}\n\n.input-group-addon,\n.input-group-btn,\n.input-group .form-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.input-group-addon:not(:first-child):not(:last-child),\n.input-group-btn:not(:first-child):not(:last-child),\n.input-group .form-control:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.input-group-addon,\n.input-group-btn {\n white-space: nowrap;\n vertical-align: middle;\n}\n\n.input-group-addon {\n padding: 0.5rem 0.75rem;\n margin-bottom: 0;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.25;\n color: #464a4c;\n text-align: center;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.input-group-addon.form-control-sm,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .input-group-addon.btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.input-group-addon.form-control-lg,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .input-group-addon.btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.input-group-addon input[type=\"radio\"],\n.input-group-addon input[type=\"checkbox\"] {\n margin-top: 0;\n}\n\n.input-group .form-control:not(:last-child),\n.input-group-addon:not(:last-child),\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group > .btn,\n.input-group-btn:not(:last-child) > .dropdown-toggle,\n.input-group-btn:not(:first-child) > .btn:not(:last-child):not(.dropdown-toggle),\n.input-group-btn:not(:first-child) > .btn-group:not(:last-child) > .btn {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.input-group-addon:not(:last-child) {\n border-right: 0;\n}\n\n.input-group .form-control:not(:first-child),\n.input-group-addon:not(:first-child),\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group > .btn,\n.input-group-btn:not(:first-child) > .dropdown-toggle,\n.input-group-btn:not(:last-child) > .btn:not(:first-child),\n.input-group-btn:not(:last-child) > .btn-group:not(:first-child) > .btn {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.form-control + .input-group-addon:not(:first-child) {\n border-left: 0;\n}\n\n.input-group-btn {\n position: relative;\n font-size: 0;\n white-space: nowrap;\n}\n\n.input-group-btn > .btn {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.input-group-btn > .btn + .btn {\n margin-left: -1px;\n}\n\n.input-group-btn > .btn:focus, .input-group-btn > .btn:active, .input-group-btn > .btn:hover {\n z-index: 3;\n}\n\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group {\n margin-right: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group {\n z-index: 2;\n margin-left: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn:focus, .input-group-btn:not(:first-child) > .btn:active, .input-group-btn:not(:first-child) > .btn:hover,\n.input-group-btn:not(:first-child) > .btn-group:focus,\n.input-group-btn:not(:first-child) > .btn-group:active,\n.input-group-btn:not(:first-child) > .btn-group:hover {\n z-index: 3;\n}\n\n.custom-control {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n min-height: 1.5rem;\n padding-left: 1.5rem;\n margin-right: 1rem;\n cursor: pointer;\n}\n\n.custom-control-input {\n position: absolute;\n z-index: -1;\n opacity: 0;\n}\n\n.custom-control-input:checked ~ .custom-control-indicator {\n color: #fff;\n background-color: #0275d8;\n}\n\n.custom-control-input:focus ~ .custom-control-indicator {\n -webkit-box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n}\n\n.custom-control-input:active ~ .custom-control-indicator {\n color: #fff;\n background-color: #8fcafe;\n}\n\n.custom-control-input:disabled ~ .custom-control-indicator {\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-control-input:disabled ~ .custom-control-description {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.custom-control-indicator {\n position: absolute;\n top: 0.25rem;\n left: 0;\n display: block;\n width: 1rem;\n height: 1rem;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #ddd;\n background-repeat: no-repeat;\n background-position: center center;\n -webkit-background-size: 50% 50%;\n background-size: 50% 50%;\n}\n\n.custom-checkbox .custom-control-indicator {\n border-radius: 0.25rem;\n}\n\n.custom-checkbox .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26 2.974 7.25 8 2.193z'/%3E%3C/svg%3E\");\n}\n\n.custom-checkbox .custom-control-input:indeterminate ~ .custom-control-indicator {\n background-color: #0275d8;\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 4'%3E%3Cpath stroke='%23fff' d='M0 2h4'/%3E%3C/svg%3E\");\n}\n\n.custom-radio .custom-control-indicator {\n border-radius: 50%;\n}\n\n.custom-radio .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3E%3Ccircle r='3' fill='%23fff'/%3E%3C/svg%3E\");\n}\n\n.custom-controls-stacked {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n\n.custom-controls-stacked .custom-control {\n margin-bottom: 0.25rem;\n}\n\n.custom-controls-stacked .custom-control + .custom-control {\n margin-left: 0;\n}\n\n.custom-select {\n display: inline-block;\n max-width: 100%;\n height: calc(2.25rem + 2px);\n padding: 0.375rem 1.75rem 0.375rem 0.75rem;\n line-height: 1.25;\n color: #464a4c;\n vertical-align: middle;\n background: #fff url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23333' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E\") no-repeat right 0.75rem center;\n -webkit-background-size: 8px 10px;\n background-size: 8px 10px;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -moz-appearance: none;\n -webkit-appearance: none;\n}\n\n.custom-select:focus {\n border-color: #5cb3fd;\n outline: none;\n}\n\n.custom-select:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.custom-select:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-select::-ms-expand {\n opacity: 0;\n}\n\n.custom-select-sm {\n padding-top: 0.375rem;\n padding-bottom: 0.375rem;\n font-size: 75%;\n}\n\n.custom-file {\n position: relative;\n display: inline-block;\n max-width: 100%;\n height: 2.5rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.custom-file-input {\n min-width: 14rem;\n max-width: 100%;\n height: 2.5rem;\n margin: 0;\n filter: alpha(opacity=0);\n opacity: 0;\n}\n\n.custom-file-control {\n position: absolute;\n top: 0;\n right: 0;\n left: 0;\n z-index: 5;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.custom-file-control:lang(en)::after {\n content: \"Choose file...\";\n}\n\n.custom-file-control::before {\n position: absolute;\n top: -1px;\n right: -1px;\n bottom: -1px;\n z-index: 6;\n display: block;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0 0.25rem 0.25rem 0;\n}\n\n.custom-file-control:lang(en)::before {\n content: \"Browse\";\n}\n\n.nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.nav-link {\n display: block;\n padding: 0.5em 1em;\n}\n\n.nav-link:focus, .nav-link:hover {\n text-decoration: none;\n}\n\n.nav-link.disabled {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.nav-tabs {\n border-bottom: 1px solid #ddd;\n}\n\n.nav-tabs .nav-item {\n margin-bottom: -1px;\n}\n\n.nav-tabs .nav-link {\n border: 1px solid transparent;\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.nav-tabs .nav-link:focus, .nav-tabs .nav-link:hover {\n border-color: #eceeef #eceeef #ddd;\n}\n\n.nav-tabs .nav-link.disabled {\n color: #636c72;\n background-color: transparent;\n border-color: transparent;\n}\n\n.nav-tabs .nav-link.active,\n.nav-tabs .nav-item.show .nav-link {\n color: #464a4c;\n background-color: #fff;\n border-color: #ddd #ddd #fff;\n}\n\n.nav-tabs .dropdown-menu {\n margin-top: -1px;\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.nav-pills .nav-link {\n border-radius: 0.25rem;\n}\n\n.nav-pills .nav-link.active,\n.nav-pills .nav-item.show .nav-link {\n color: #fff;\n cursor: default;\n background-color: #0275d8;\n}\n\n.nav-fill .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n text-align: center;\n}\n\n.nav-justified .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 100%;\n -ms-flex: 1 1 100%;\n flex: 1 1 100%;\n text-align: center;\n}\n\n.tab-content > .tab-pane {\n display: none;\n}\n\n.tab-content > .active {\n display: block;\n}\n\n.navbar {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding: 0.5rem 1rem;\n}\n\n.navbar-brand {\n display: inline-block;\n padding-top: .25rem;\n padding-bottom: .25rem;\n margin-right: 1rem;\n font-size: 1.25rem;\n line-height: inherit;\n white-space: nowrap;\n}\n\n.navbar-brand:focus, .navbar-brand:hover {\n text-decoration: none;\n}\n\n.navbar-nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.navbar-nav .nav-link {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-text {\n display: inline-block;\n padding-top: .425rem;\n padding-bottom: .425rem;\n}\n\n.navbar-toggler {\n -webkit-align-self: flex-start;\n -ms-flex-item-align: start;\n align-self: flex-start;\n padding: 0.25rem 0.75rem;\n font-size: 1.25rem;\n line-height: 1;\n background: transparent;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.navbar-toggler:focus, .navbar-toggler:hover {\n text-decoration: none;\n}\n\n.navbar-toggler-icon {\n display: inline-block;\n width: 1.5em;\n height: 1.5em;\n vertical-align: middle;\n content: \"\";\n background: no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.navbar-toggler-left {\n position: absolute;\n left: 1rem;\n}\n\n.navbar-toggler-right {\n position: absolute;\n right: 1rem;\n}\n\n@media (max-width: 575px) {\n .navbar-toggleable .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 576px) {\n .navbar-toggleable {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 767px) {\n .navbar-toggleable-sm .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-sm > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 768px) {\n .navbar-toggleable-sm {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-sm .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-sm > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-sm .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 991px) {\n .navbar-toggleable-md .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-md > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 992px) {\n .navbar-toggleable-md {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-md .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-md > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-md .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 1199px) {\n .navbar-toggleable-lg .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-lg > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 1200px) {\n .navbar-toggleable-lg {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-lg .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-lg > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-lg .navbar-toggler {\n display: none;\n }\n}\n\n.navbar-toggleable-xl {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n}\n\n.navbar-toggleable-xl > .container {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-toggleable-xl .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n\n.navbar-toggleable-xl .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n}\n\n.navbar-toggleable-xl > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n}\n\n.navbar-toggleable-xl .navbar-toggler {\n display: none;\n}\n\n.navbar-light .navbar-brand,\n.navbar-light .navbar-toggler {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-brand:focus, .navbar-light .navbar-brand:hover,\n.navbar-light .navbar-toggler:focus,\n.navbar-light .navbar-toggler:hover {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-nav .nav-link {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-light .navbar-nav .nav-link:focus, .navbar-light .navbar-nav .nav-link:hover {\n color: rgba(0, 0, 0, 0.7);\n}\n\n.navbar-light .navbar-nav .nav-link.disabled {\n color: rgba(0, 0, 0, 0.3);\n}\n\n.navbar-light .navbar-nav .open > .nav-link,\n.navbar-light .navbar-nav .active > .nav-link,\n.navbar-light .navbar-nav .nav-link.open,\n.navbar-light .navbar-nav .nav-link.active {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-toggler {\n border-color: rgba(0, 0, 0, 0.1);\n}\n\n.navbar-light .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(0, 0, 0, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-light .navbar-text {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-inverse .navbar-brand,\n.navbar-inverse .navbar-toggler {\n color: white;\n}\n\n.navbar-inverse .navbar-brand:focus, .navbar-inverse .navbar-brand:hover,\n.navbar-inverse .navbar-toggler:focus,\n.navbar-inverse .navbar-toggler:hover {\n color: white;\n}\n\n.navbar-inverse .navbar-nav .nav-link {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.navbar-inverse .navbar-nav .nav-link:focus, .navbar-inverse .navbar-nav .nav-link:hover {\n color: rgba(255, 255, 255, 0.75);\n}\n\n.navbar-inverse .navbar-nav .nav-link.disabled {\n color: rgba(255, 255, 255, 0.25);\n}\n\n.navbar-inverse .navbar-nav .open > .nav-link,\n.navbar-inverse .navbar-nav .active > .nav-link,\n.navbar-inverse .navbar-nav .nav-link.open,\n.navbar-inverse .navbar-nav .nav-link.active {\n color: white;\n}\n\n.navbar-inverse .navbar-toggler {\n border-color: rgba(255, 255, 255, 0.1);\n}\n\n.navbar-inverse .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255, 255, 255, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-inverse .navbar-text {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.card {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n border-radius: 0.25rem;\n}\n\n.card-block {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 1.25rem;\n}\n\n.card-title {\n margin-bottom: 0.75rem;\n}\n\n.card-subtitle {\n margin-top: -0.375rem;\n margin-bottom: 0;\n}\n\n.card-text:last-child {\n margin-bottom: 0;\n}\n\n.card-link:hover {\n text-decoration: none;\n}\n\n.card-link + .card-link {\n margin-left: 1.25rem;\n}\n\n.card > .list-group:first-child .list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.card > .list-group:last-child .list-group-item:last-child {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.card-header {\n padding: 0.75rem 1.25rem;\n margin-bottom: 0;\n background-color: #f7f7f9;\n border-bottom: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-header:first-child {\n border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;\n}\n\n.card-footer {\n padding: 0.75rem 1.25rem;\n background-color: #f7f7f9;\n border-top: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-footer:last-child {\n border-radius: 0 0 calc(0.25rem - 1px) calc(0.25rem - 1px);\n}\n\n.card-header-tabs {\n margin-right: -0.625rem;\n margin-bottom: -0.75rem;\n margin-left: -0.625rem;\n border-bottom: 0;\n}\n\n.card-header-pills {\n margin-right: -0.625rem;\n margin-left: -0.625rem;\n}\n\n.card-primary {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.card-primary .card-header,\n.card-primary .card-footer {\n background-color: transparent;\n}\n\n.card-success {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.card-success .card-header,\n.card-success .card-footer {\n background-color: transparent;\n}\n\n.card-info {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.card-info .card-header,\n.card-info .card-footer {\n background-color: transparent;\n}\n\n.card-warning {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.card-warning .card-header,\n.card-warning .card-footer {\n background-color: transparent;\n}\n\n.card-danger {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.card-danger .card-header,\n.card-danger .card-footer {\n background-color: transparent;\n}\n\n.card-outline-primary {\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.card-outline-secondary {\n background-color: transparent;\n border-color: #ccc;\n}\n\n.card-outline-info {\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.card-outline-success {\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.card-outline-warning {\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.card-outline-danger {\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.card-inverse {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer {\n background-color: transparent;\n border-color: rgba(255, 255, 255, 0.2);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer,\n.card-inverse .card-title,\n.card-inverse .card-blockquote {\n color: #fff;\n}\n\n.card-inverse .card-link,\n.card-inverse .card-text,\n.card-inverse .card-subtitle,\n.card-inverse .card-blockquote .blockquote-footer {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-link:focus, .card-inverse .card-link:hover {\n color: #fff;\n}\n\n.card-blockquote {\n padding: 0;\n margin-bottom: 0;\n border-left: 0;\n}\n\n.card-img {\n border-radius: calc(0.25rem - 1px);\n}\n\n.card-img-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n padding: 1.25rem;\n}\n\n.card-img-top {\n border-top-right-radius: calc(0.25rem - 1px);\n border-top-left-radius: calc(0.25rem - 1px);\n}\n\n.card-img-bottom {\n border-bottom-right-radius: calc(0.25rem - 1px);\n border-bottom-left-radius: calc(0.25rem - 1px);\n}\n\n@media (min-width: 576px) {\n .card-deck {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-deck .card {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n }\n .card-deck .card:not(:first-child) {\n margin-left: 15px;\n }\n .card-deck .card:not(:last-child) {\n margin-right: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .card-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-group .card {\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n }\n .card-group .card + .card {\n margin-left: 0;\n border-left: 0;\n }\n .card-group .card:first-child {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-top {\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-bottom {\n border-bottom-right-radius: 0;\n }\n .card-group .card:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-top {\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-bottom {\n border-bottom-left-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) {\n border-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) .card-img-top,\n .card-group .card:not(:first-child):not(:last-child) .card-img-bottom {\n border-radius: 0;\n }\n}\n\n@media (min-width: 576px) {\n .card-columns {\n -webkit-column-count: 3;\n -moz-column-count: 3;\n column-count: 3;\n -webkit-column-gap: 1.25rem;\n -moz-column-gap: 1.25rem;\n column-gap: 1.25rem;\n }\n .card-columns .card {\n display: inline-block;\n width: 100%;\n margin-bottom: 0.75rem;\n }\n}\n\n.breadcrumb {\n padding: 0.75rem 1rem;\n margin-bottom: 1rem;\n list-style: none;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.breadcrumb::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.breadcrumb-item {\n float: left;\n}\n\n.breadcrumb-item + .breadcrumb-item::before {\n display: inline-block;\n padding-right: 0.5rem;\n padding-left: 0.5rem;\n color: #636c72;\n content: \"/\";\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: underline;\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: none;\n}\n\n.breadcrumb-item.active {\n color: #636c72;\n}\n\n.pagination {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n list-style: none;\n border-radius: 0.25rem;\n}\n\n.page-item:first-child .page-link {\n margin-left: 0;\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.page-item:last-child .page-link {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.page-item.active .page-link {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.page-item.disabled .page-link {\n color: #636c72;\n pointer-events: none;\n cursor: not-allowed;\n background-color: #fff;\n border-color: #ddd;\n}\n\n.page-link {\n position: relative;\n display: block;\n padding: 0.5rem 0.75rem;\n margin-left: -1px;\n line-height: 1.25;\n color: #0275d8;\n background-color: #fff;\n border: 1px solid #ddd;\n}\n\n.page-link:focus, .page-link:hover {\n color: #014c8c;\n text-decoration: none;\n background-color: #eceeef;\n border-color: #ddd;\n}\n\n.pagination-lg .page-link {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n}\n\n.pagination-lg .page-item:first-child .page-link {\n border-bottom-left-radius: 0.3rem;\n border-top-left-radius: 0.3rem;\n}\n\n.pagination-lg .page-item:last-child .page-link {\n border-bottom-right-radius: 0.3rem;\n border-top-right-radius: 0.3rem;\n}\n\n.pagination-sm .page-link {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n}\n\n.pagination-sm .page-item:first-child .page-link {\n border-bottom-left-radius: 0.2rem;\n border-top-left-radius: 0.2rem;\n}\n\n.pagination-sm .page-item:last-child .page-link {\n border-bottom-right-radius: 0.2rem;\n border-top-right-radius: 0.2rem;\n}\n\n.badge {\n display: inline-block;\n padding: 0.25em 0.4em;\n font-size: 75%;\n font-weight: bold;\n line-height: 1;\n color: #fff;\n text-align: center;\n white-space: nowrap;\n vertical-align: baseline;\n border-radius: 0.25rem;\n}\n\n.badge:empty {\n display: none;\n}\n\n.btn .badge {\n position: relative;\n top: -1px;\n}\n\na.badge:focus, a.badge:hover {\n color: #fff;\n text-decoration: none;\n cursor: pointer;\n}\n\n.badge-pill {\n padding-right: 0.6em;\n padding-left: 0.6em;\n border-radius: 10rem;\n}\n\n.badge-default {\n background-color: #636c72;\n}\n\n.badge-default[href]:focus, .badge-default[href]:hover {\n background-color: #4b5257;\n}\n\n.badge-primary {\n background-color: #0275d8;\n}\n\n.badge-primary[href]:focus, .badge-primary[href]:hover {\n background-color: #025aa5;\n}\n\n.badge-success {\n background-color: #5cb85c;\n}\n\n.badge-success[href]:focus, .badge-success[href]:hover {\n background-color: #449d44;\n}\n\n.badge-info {\n background-color: #5bc0de;\n}\n\n.badge-info[href]:focus, .badge-info[href]:hover {\n background-color: #31b0d5;\n}\n\n.badge-warning {\n background-color: #f0ad4e;\n}\n\n.badge-warning[href]:focus, .badge-warning[href]:hover {\n background-color: #ec971f;\n}\n\n.badge-danger {\n background-color: #d9534f;\n}\n\n.badge-danger[href]:focus, .badge-danger[href]:hover {\n background-color: #c9302c;\n}\n\n.jumbotron {\n padding: 2rem 1rem;\n margin-bottom: 2rem;\n background-color: #eceeef;\n border-radius: 0.3rem;\n}\n\n@media (min-width: 576px) {\n .jumbotron {\n padding: 4rem 2rem;\n }\n}\n\n.jumbotron-hr {\n border-top-color: #d0d5d8;\n}\n\n.jumbotron-fluid {\n padding-right: 0;\n padding-left: 0;\n border-radius: 0;\n}\n\n.alert {\n padding: 0.75rem 1.25rem;\n margin-bottom: 1rem;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.alert-heading {\n color: inherit;\n}\n\n.alert-link {\n font-weight: bold;\n}\n\n.alert-dismissible .close {\n position: relative;\n top: -0.75rem;\n right: -1.25rem;\n padding: 0.75rem 1.25rem;\n color: inherit;\n}\n\n.alert-success {\n background-color: #dff0d8;\n border-color: #d0e9c6;\n color: #3c763d;\n}\n\n.alert-success hr {\n border-top-color: #c1e2b3;\n}\n\n.alert-success .alert-link {\n color: #2b542c;\n}\n\n.alert-info {\n background-color: #d9edf7;\n border-color: #bcdff1;\n color: #31708f;\n}\n\n.alert-info hr {\n border-top-color: #a6d5ec;\n}\n\n.alert-info .alert-link {\n color: #245269;\n}\n\n.alert-warning {\n background-color: #fcf8e3;\n border-color: #faf2cc;\n color: #8a6d3b;\n}\n\n.alert-warning hr {\n border-top-color: #f7ecb5;\n}\n\n.alert-warning .alert-link {\n color: #66512c;\n}\n\n.alert-danger {\n background-color: #f2dede;\n border-color: #ebcccc;\n color: #a94442;\n}\n\n.alert-danger hr {\n border-top-color: #e4b9b9;\n}\n\n.alert-danger .alert-link {\n color: #843534;\n}\n\n@-webkit-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@-o-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n.progress {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n overflow: hidden;\n font-size: 0.75rem;\n line-height: 1rem;\n text-align: center;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.progress-bar {\n height: 1rem;\n color: #fff;\n background-color: #0275d8;\n}\n\n.progress-bar-striped {\n background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n -webkit-background-size: 1rem 1rem;\n background-size: 1rem 1rem;\n}\n\n.progress-bar-animated {\n -webkit-animation: progress-bar-stripes 1s linear infinite;\n -o-animation: progress-bar-stripes 1s linear infinite;\n animation: progress-bar-stripes 1s linear infinite;\n}\n\n.media {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n}\n\n.media-body {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.list-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n}\n\n.list-group-item-action {\n width: 100%;\n color: #464a4c;\n text-align: inherit;\n}\n\n.list-group-item-action .list-group-item-heading {\n color: #292b2c;\n}\n\n.list-group-item-action:focus, .list-group-item-action:hover {\n color: #464a4c;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.list-group-item-action:active {\n color: #292b2c;\n background-color: #eceeef;\n}\n\n.list-group-item {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n padding: 0.75rem 1.25rem;\n margin-bottom: -1px;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.list-group-item:last-child {\n margin-bottom: 0;\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.list-group-item:focus, .list-group-item:hover {\n text-decoration: none;\n}\n\n.list-group-item.disabled, .list-group-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #fff;\n}\n\n.list-group-item.disabled .list-group-item-heading, .list-group-item:disabled .list-group-item-heading {\n color: inherit;\n}\n\n.list-group-item.disabled .list-group-item-text, .list-group-item:disabled .list-group-item-text {\n color: #636c72;\n}\n\n.list-group-item.active {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.list-group-item.active .list-group-item-heading,\n.list-group-item.active .list-group-item-heading > small,\n.list-group-item.active .list-group-item-heading > .small {\n color: inherit;\n}\n\n.list-group-item.active .list-group-item-text {\n color: #daeeff;\n}\n\n.list-group-flush .list-group-item {\n border-right: 0;\n border-left: 0;\n border-radius: 0;\n}\n\n.list-group-flush:first-child .list-group-item:first-child {\n border-top: 0;\n}\n\n.list-group-flush:last-child .list-group-item:last-child {\n border-bottom: 0;\n}\n\n.list-group-item-success {\n color: #3c763d;\n background-color: #dff0d8;\n}\n\na.list-group-item-success,\nbutton.list-group-item-success {\n color: #3c763d;\n}\n\na.list-group-item-success .list-group-item-heading,\nbutton.list-group-item-success .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-success:focus, a.list-group-item-success:hover,\nbutton.list-group-item-success:focus,\nbutton.list-group-item-success:hover {\n color: #3c763d;\n background-color: #d0e9c6;\n}\n\na.list-group-item-success.active,\nbutton.list-group-item-success.active {\n color: #fff;\n background-color: #3c763d;\n border-color: #3c763d;\n}\n\n.list-group-item-info {\n color: #31708f;\n background-color: #d9edf7;\n}\n\na.list-group-item-info,\nbutton.list-group-item-info {\n color: #31708f;\n}\n\na.list-group-item-info .list-group-item-heading,\nbutton.list-group-item-info .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-info:focus, a.list-group-item-info:hover,\nbutton.list-group-item-info:focus,\nbutton.list-group-item-info:hover {\n color: #31708f;\n background-color: #c4e3f3;\n}\n\na.list-group-item-info.active,\nbutton.list-group-item-info.active {\n color: #fff;\n background-color: #31708f;\n border-color: #31708f;\n}\n\n.list-group-item-warning {\n color: #8a6d3b;\n background-color: #fcf8e3;\n}\n\na.list-group-item-warning,\nbutton.list-group-item-warning {\n color: #8a6d3b;\n}\n\na.list-group-item-warning .list-group-item-heading,\nbutton.list-group-item-warning .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-warning:focus, a.list-group-item-warning:hover,\nbutton.list-group-item-warning:focus,\nbutton.list-group-item-warning:hover {\n color: #8a6d3b;\n background-color: #faf2cc;\n}\n\na.list-group-item-warning.active,\nbutton.list-group-item-warning.active {\n color: #fff;\n background-color: #8a6d3b;\n border-color: #8a6d3b;\n}\n\n.list-group-item-danger {\n color: #a94442;\n background-color: #f2dede;\n}\n\na.list-group-item-danger,\nbutton.list-group-item-danger {\n color: #a94442;\n}\n\na.list-group-item-danger .list-group-item-heading,\nbutton.list-group-item-danger .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-danger:focus, a.list-group-item-danger:hover,\nbutton.list-group-item-danger:focus,\nbutton.list-group-item-danger:hover {\n color: #a94442;\n background-color: #ebcccc;\n}\n\na.list-group-item-danger.active,\nbutton.list-group-item-danger.active {\n color: #fff;\n background-color: #a94442;\n border-color: #a94442;\n}\n\n.embed-responsive {\n position: relative;\n display: block;\n width: 100%;\n padding: 0;\n overflow: hidden;\n}\n\n.embed-responsive::before {\n display: block;\n content: \"\";\n}\n\n.embed-responsive .embed-responsive-item,\n.embed-responsive iframe,\n.embed-responsive embed,\n.embed-responsive object,\n.embed-responsive video {\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 100%;\n border: 0;\n}\n\n.embed-responsive-21by9::before {\n padding-top: 42.857143%;\n}\n\n.embed-responsive-16by9::before {\n padding-top: 56.25%;\n}\n\n.embed-responsive-4by3::before {\n padding-top: 75%;\n}\n\n.embed-responsive-1by1::before {\n padding-top: 100%;\n}\n\n.close {\n float: right;\n font-size: 1.5rem;\n font-weight: bold;\n line-height: 1;\n color: #000;\n text-shadow: 0 1px 0 #fff;\n opacity: .5;\n}\n\n.close:focus, .close:hover {\n color: #000;\n text-decoration: none;\n cursor: pointer;\n opacity: .75;\n}\n\nbutton.close {\n padding: 0;\n cursor: pointer;\n background: transparent;\n border: 0;\n -webkit-appearance: none;\n}\n\n.modal-open {\n overflow: hidden;\n}\n\n.modal {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1050;\n display: none;\n overflow: hidden;\n outline: 0;\n}\n\n.modal.fade .modal-dialog {\n -webkit-transition: -webkit-transform 0.3s ease-out;\n transition: -webkit-transform 0.3s ease-out;\n -o-transition: -o-transform 0.3s ease-out;\n transition: transform 0.3s ease-out;\n transition: transform 0.3s ease-out, -webkit-transform 0.3s ease-out, -o-transform 0.3s ease-out;\n -webkit-transform: translate(0, -25%);\n -o-transform: translate(0, -25%);\n transform: translate(0, -25%);\n}\n\n.modal.show .modal-dialog {\n -webkit-transform: translate(0, 0);\n -o-transform: translate(0, 0);\n transform: translate(0, 0);\n}\n\n.modal-open .modal {\n overflow-x: hidden;\n overflow-y: auto;\n}\n\n.modal-dialog {\n position: relative;\n width: auto;\n margin: 10px;\n}\n\n.modal-content {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n outline: 0;\n}\n\n.modal-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1040;\n background-color: #000;\n}\n\n.modal-backdrop.fade {\n opacity: 0;\n}\n\n.modal-backdrop.show {\n opacity: 0.5;\n}\n\n.modal-header {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n padding: 15px;\n border-bottom: 1px solid #eceeef;\n}\n\n.modal-title {\n margin-bottom: 0;\n line-height: 1.5;\n}\n\n.modal-body {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 15px;\n}\n\n.modal-footer {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: end;\n -webkit-justify-content: flex-end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n padding: 15px;\n border-top: 1px solid #eceeef;\n}\n\n.modal-footer > :not(:first-child) {\n margin-left: .25rem;\n}\n\n.modal-footer > :not(:last-child) {\n margin-right: .25rem;\n}\n\n.modal-scrollbar-measure {\n position: absolute;\n top: -9999px;\n width: 50px;\n height: 50px;\n overflow: scroll;\n}\n\n@media (min-width: 576px) {\n .modal-dialog {\n max-width: 500px;\n margin: 30px auto;\n }\n .modal-sm {\n max-width: 300px;\n }\n}\n\n@media (min-width: 992px) {\n .modal-lg {\n max-width: 800px;\n }\n}\n\n.tooltip {\n position: absolute;\n z-index: 1070;\n display: block;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n opacity: 0;\n}\n\n.tooltip.show {\n opacity: 0.9;\n}\n\n.tooltip.tooltip-top, .tooltip.bs-tether-element-attached-bottom {\n padding: 5px 0;\n margin-top: -3px;\n}\n\n.tooltip.tooltip-top .tooltip-inner::before, .tooltip.bs-tether-element-attached-bottom .tooltip-inner::before {\n bottom: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 5px 5px 0;\n border-top-color: #000;\n}\n\n.tooltip.tooltip-right, .tooltip.bs-tether-element-attached-left {\n padding: 0 5px;\n margin-left: 3px;\n}\n\n.tooltip.tooltip-right .tooltip-inner::before, .tooltip.bs-tether-element-attached-left .tooltip-inner::before {\n top: 50%;\n left: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 5px 5px 0;\n border-right-color: #000;\n}\n\n.tooltip.tooltip-bottom, .tooltip.bs-tether-element-attached-top {\n padding: 5px 0;\n margin-top: 3px;\n}\n\n.tooltip.tooltip-bottom .tooltip-inner::before, .tooltip.bs-tether-element-attached-top .tooltip-inner::before {\n top: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 0 5px 5px;\n border-bottom-color: #000;\n}\n\n.tooltip.tooltip-left, .tooltip.bs-tether-element-attached-right {\n padding: 0 5px;\n margin-left: -3px;\n}\n\n.tooltip.tooltip-left .tooltip-inner::before, .tooltip.bs-tether-element-attached-right .tooltip-inner::before {\n top: 50%;\n right: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 0 5px 5px;\n border-left-color: #000;\n}\n\n.tooltip-inner {\n max-width: 200px;\n padding: 3px 8px;\n color: #fff;\n text-align: center;\n background-color: #000;\n border-radius: 0.25rem;\n}\n\n.tooltip-inner::before {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1060;\n display: block;\n max-width: 276px;\n padding: 1px;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n}\n\n.popover.popover-top, .popover.bs-tether-element-attached-bottom {\n margin-top: -10px;\n}\n\n.popover.popover-top::before, .popover.popover-top::after, .popover.bs-tether-element-attached-bottom::before, .popover.bs-tether-element-attached-bottom::after {\n left: 50%;\n border-bottom-width: 0;\n}\n\n.popover.popover-top::before, .popover.bs-tether-element-attached-bottom::before {\n bottom: -11px;\n margin-left: -11px;\n border-top-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-top::after, .popover.bs-tether-element-attached-bottom::after {\n bottom: -10px;\n margin-left: -10px;\n border-top-color: #fff;\n}\n\n.popover.popover-right, .popover.bs-tether-element-attached-left {\n margin-left: 10px;\n}\n\n.popover.popover-right::before, .popover.popover-right::after, .popover.bs-tether-element-attached-left::before, .popover.bs-tether-element-attached-left::after {\n top: 50%;\n border-left-width: 0;\n}\n\n.popover.popover-right::before, .popover.bs-tether-element-attached-left::before {\n left: -11px;\n margin-top: -11px;\n border-right-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-right::after, .popover.bs-tether-element-attached-left::after {\n left: -10px;\n margin-top: -10px;\n border-right-color: #fff;\n}\n\n.popover.popover-bottom, .popover.bs-tether-element-attached-top {\n margin-top: 10px;\n}\n\n.popover.popover-bottom::before, .popover.popover-bottom::after, .popover.bs-tether-element-attached-top::before, .popover.bs-tether-element-attached-top::after {\n left: 50%;\n border-top-width: 0;\n}\n\n.popover.popover-bottom::before, .popover.bs-tether-element-attached-top::before {\n top: -11px;\n margin-left: -11px;\n border-bottom-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-bottom::after, .popover.bs-tether-element-attached-top::after {\n top: -10px;\n margin-left: -10px;\n border-bottom-color: #f7f7f7;\n}\n\n.popover.popover-bottom .popover-title::before, .popover.bs-tether-element-attached-top .popover-title::before {\n position: absolute;\n top: 0;\n left: 50%;\n display: block;\n width: 20px;\n margin-left: -10px;\n content: \"\";\n border-bottom: 1px solid #f7f7f7;\n}\n\n.popover.popover-left, .popover.bs-tether-element-attached-right {\n margin-left: -10px;\n}\n\n.popover.popover-left::before, .popover.popover-left::after, .popover.bs-tether-element-attached-right::before, .popover.bs-tether-element-attached-right::after {\n top: 50%;\n border-right-width: 0;\n}\n\n.popover.popover-left::before, .popover.bs-tether-element-attached-right::before {\n right: -11px;\n margin-top: -11px;\n border-left-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-left::after, .popover.bs-tether-element-attached-right::after {\n right: -10px;\n margin-top: -10px;\n border-left-color: #fff;\n}\n\n.popover-title {\n padding: 8px 14px;\n margin-bottom: 0;\n font-size: 1rem;\n background-color: #f7f7f7;\n border-bottom: 1px solid #ebebeb;\n border-top-right-radius: calc(0.3rem - 1px);\n border-top-left-radius: calc(0.3rem - 1px);\n}\n\n.popover-title:empty {\n display: none;\n}\n\n.popover-content {\n padding: 9px 14px;\n}\n\n.popover::before,\n.popover::after {\n position: absolute;\n display: block;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover::before {\n content: \"\";\n border-width: 11px;\n}\n\n.popover::after {\n content: \"\";\n border-width: 10px;\n}\n\n.carousel {\n position: relative;\n}\n\n.carousel-inner {\n position: relative;\n width: 100%;\n overflow: hidden;\n}\n\n.carousel-item {\n position: relative;\n display: none;\n width: 100%;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n.carousel-item.active,\n.carousel-item-next,\n.carousel-item-prev {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n}\n\n.carousel-item-next,\n.carousel-item-prev {\n position: absolute;\n top: 0;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n.carousel-control-prev,\n.carousel-control-next {\n position: absolute;\n top: 0;\n bottom: 0;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: 15%;\n color: #fff;\n text-align: center;\n opacity: 0.5;\n}\n\n.carousel-control-prev:focus, .carousel-control-prev:hover,\n.carousel-control-next:focus,\n.carousel-control-next:hover {\n color: #fff;\n text-decoration: none;\n outline: 0;\n opacity: .9;\n}\n\n.carousel-control-prev {\n left: 0;\n}\n\n.carousel-control-next {\n right: 0;\n}\n\n.carousel-control-prev-icon,\n.carousel-control-next-icon {\n display: inline-block;\n width: 20px;\n height: 20px;\n background: transparent no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.carousel-control-prev-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M4 0l-4 4 4 4 1.5-1.5-2.5-2.5 2.5-2.5-1.5-1.5z'/%3E%3C/svg%3E\");\n}\n\n.carousel-control-next-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M1.5 0l-1.5 1.5 2.5 2.5-2.5 2.5 1.5 1.5 4-4-4-4z'/%3E%3C/svg%3E\");\n}\n\n.carousel-indicators {\n position: absolute;\n right: 0;\n bottom: 10px;\n left: 0;\n z-index: 15;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n margin-right: 15%;\n margin-left: 15%;\n list-style: none;\n}\n\n.carousel-indicators li {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 auto;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n max-width: 30px;\n height: 3px;\n margin-right: 3px;\n margin-left: 3px;\n text-indent: -999px;\n cursor: pointer;\n background-color: rgba(255, 255, 255, 0.5);\n}\n\n.carousel-indicators li::before {\n position: absolute;\n top: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators li::after {\n position: absolute;\n bottom: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators .active {\n background-color: #fff;\n}\n\n.carousel-caption {\n position: absolute;\n right: 15%;\n bottom: 20px;\n left: 15%;\n z-index: 10;\n padding-top: 20px;\n padding-bottom: 20px;\n color: #fff;\n text-align: center;\n}\n\n.align-baseline {\n vertical-align: baseline !important;\n}\n\n.align-top {\n vertical-align: top !important;\n}\n\n.align-middle {\n vertical-align: middle !important;\n}\n\n.align-bottom {\n vertical-align: bottom !important;\n}\n\n.align-text-bottom {\n vertical-align: text-bottom !important;\n}\n\n.align-text-top {\n vertical-align: text-top !important;\n}\n\n.bg-faded {\n background-color: #f7f7f7;\n}\n\n.bg-primary {\n background-color: #0275d8 !important;\n}\n\na.bg-primary:focus, a.bg-primary:hover {\n background-color: #025aa5 !important;\n}\n\n.bg-success {\n background-color: #5cb85c !important;\n}\n\na.bg-success:focus, a.bg-success:hover {\n background-color: #449d44 !important;\n}\n\n.bg-info {\n background-color: #5bc0de !important;\n}\n\na.bg-info:focus, a.bg-info:hover {\n background-color: #31b0d5 !important;\n}\n\n.bg-warning {\n background-color: #f0ad4e !important;\n}\n\na.bg-warning:focus, a.bg-warning:hover {\n background-color: #ec971f !important;\n}\n\n.bg-danger {\n background-color: #d9534f !important;\n}\n\na.bg-danger:focus, a.bg-danger:hover {\n background-color: #c9302c !important;\n}\n\n.bg-inverse {\n background-color: #292b2c !important;\n}\n\na.bg-inverse:focus, a.bg-inverse:hover {\n background-color: #101112 !important;\n}\n\n.border-0 {\n border: 0 !important;\n}\n\n.border-top-0 {\n border-top: 0 !important;\n}\n\n.border-right-0 {\n border-right: 0 !important;\n}\n\n.border-bottom-0 {\n border-bottom: 0 !important;\n}\n\n.border-left-0 {\n border-left: 0 !important;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.rounded-top {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-right {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.rounded-bottom {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.rounded-left {\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-circle {\n border-radius: 50%;\n}\n\n.rounded-0 {\n border-radius: 0;\n}\n\n.clearfix::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.d-none {\n display: none !important;\n}\n\n.d-inline {\n display: inline !important;\n}\n\n.d-inline-block {\n display: inline-block !important;\n}\n\n.d-block {\n display: block !important;\n}\n\n.d-table {\n display: table !important;\n}\n\n.d-table-cell {\n display: table-cell !important;\n}\n\n.d-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n}\n\n.d-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n}\n\n@media (min-width: 576px) {\n .d-sm-none {\n display: none !important;\n }\n .d-sm-inline {\n display: inline !important;\n }\n .d-sm-inline-block {\n display: inline-block !important;\n }\n .d-sm-block {\n display: block !important;\n }\n .d-sm-table {\n display: table !important;\n }\n .d-sm-table-cell {\n display: table-cell !important;\n }\n .d-sm-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-sm-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 768px) {\n .d-md-none {\n display: none !important;\n }\n .d-md-inline {\n display: inline !important;\n }\n .d-md-inline-block {\n display: inline-block !important;\n }\n .d-md-block {\n display: block !important;\n }\n .d-md-table {\n display: table !important;\n }\n .d-md-table-cell {\n display: table-cell !important;\n }\n .d-md-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-md-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 992px) {\n .d-lg-none {\n display: none !important;\n }\n .d-lg-inline {\n display: inline !important;\n }\n .d-lg-inline-block {\n display: inline-block !important;\n }\n .d-lg-block {\n display: block !important;\n }\n .d-lg-table {\n display: table !important;\n }\n .d-lg-table-cell {\n display: table-cell !important;\n }\n .d-lg-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-lg-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 1200px) {\n .d-xl-none {\n display: none !important;\n }\n .d-xl-inline {\n display: inline !important;\n }\n .d-xl-inline-block {\n display: inline-block !important;\n }\n .d-xl-block {\n display: block !important;\n }\n .d-xl-table {\n display: table !important;\n }\n .d-xl-table-cell {\n display: table-cell !important;\n }\n .d-xl-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-xl-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n.flex-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n}\n\n.flex-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n}\n\n.flex-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n}\n\n.flex-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n}\n\n.flex-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n}\n\n.flex-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n}\n\n.flex-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n}\n\n.flex-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n}\n\n.flex-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n}\n\n.flex-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n}\n\n.justify-content-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n}\n\n.justify-content-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n}\n\n.justify-content-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n}\n\n.justify-content-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n}\n\n.justify-content-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n}\n\n.align-items-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n}\n\n.align-items-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n}\n\n.align-items-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n}\n\n.align-items-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n}\n\n.align-items-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n}\n\n.align-content-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n}\n\n.align-content-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n}\n\n.align-content-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n}\n\n.align-content-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n}\n\n.align-content-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n}\n\n.align-content-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n}\n\n.align-self-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n}\n\n.align-self-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n}\n\n.align-self-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n}\n\n.align-self-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n}\n\n.align-self-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n}\n\n.align-self-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n}\n\n@media (min-width: 576px) {\n .flex-sm-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-sm-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-sm-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-sm-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-sm-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-sm-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-sm-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-sm-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-sm-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-sm-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-sm-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-sm-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-sm-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-sm-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-sm-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-sm-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-sm-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-sm-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-sm-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-sm-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-sm-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-sm-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-sm-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-sm-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-sm-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-sm-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-sm-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-sm-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-sm-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-sm-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-sm-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-sm-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 768px) {\n .flex-md-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-md-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-md-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-md-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-md-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-md-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-md-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-md-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-md-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-md-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-md-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-md-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-md-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-md-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-md-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-md-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-md-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-md-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-md-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-md-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-md-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-md-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-md-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-md-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-md-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-md-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-md-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-md-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-md-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-md-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-md-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-md-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 992px) {\n .flex-lg-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-lg-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-lg-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-lg-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-lg-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-lg-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-lg-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-lg-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-lg-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-lg-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-lg-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-lg-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-lg-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-lg-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-lg-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-lg-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-lg-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-lg-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-lg-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-lg-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-lg-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-lg-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-lg-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-lg-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-lg-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-lg-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-lg-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-lg-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-lg-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-lg-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-lg-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-lg-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 1200px) {\n .flex-xl-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-xl-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-xl-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-xl-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-xl-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-xl-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-xl-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-xl-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-xl-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-xl-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-xl-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-xl-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-xl-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-xl-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-xl-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-xl-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-xl-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-xl-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-xl-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-xl-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-xl-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-xl-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-xl-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-xl-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-xl-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-xl-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-xl-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-xl-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-xl-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-xl-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-xl-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-xl-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n.float-left {\n float: left !important;\n}\n\n.float-right {\n float: right !important;\n}\n\n.float-none {\n float: none !important;\n}\n\n@media (min-width: 576px) {\n .float-sm-left {\n float: left !important;\n }\n .float-sm-right {\n float: right !important;\n }\n .float-sm-none {\n float: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .float-md-left {\n float: left !important;\n }\n .float-md-right {\n float: right !important;\n }\n .float-md-none {\n float: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .float-lg-left {\n float: left !important;\n }\n .float-lg-right {\n float: right !important;\n }\n .float-lg-none {\n float: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .float-xl-left {\n float: left !important;\n }\n .float-xl-right {\n float: right !important;\n }\n .float-xl-none {\n float: none !important;\n }\n}\n\n.fixed-top {\n position: fixed;\n top: 0;\n right: 0;\n left: 0;\n z-index: 1030;\n}\n\n.fixed-bottom {\n position: fixed;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1030;\n}\n\n.sticky-top {\n position: -webkit-sticky;\n position: sticky;\n top: 0;\n z-index: 1030;\n}\n\n.sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n border: 0;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n position: static;\n width: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n clip: auto;\n}\n\n.w-25 {\n width: 25% !important;\n}\n\n.w-50 {\n width: 50% !important;\n}\n\n.w-75 {\n width: 75% !important;\n}\n\n.w-100 {\n width: 100% !important;\n}\n\n.h-25 {\n height: 25% !important;\n}\n\n.h-50 {\n height: 50% !important;\n}\n\n.h-75 {\n height: 75% !important;\n}\n\n.h-100 {\n height: 100% !important;\n}\n\n.mw-100 {\n max-width: 100% !important;\n}\n\n.mh-100 {\n max-height: 100% !important;\n}\n\n.m-0 {\n margin: 0 0 !important;\n}\n\n.mt-0 {\n margin-top: 0 !important;\n}\n\n.mr-0 {\n margin-right: 0 !important;\n}\n\n.mb-0 {\n margin-bottom: 0 !important;\n}\n\n.ml-0 {\n margin-left: 0 !important;\n}\n\n.mx-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n}\n\n.my-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n}\n\n.m-1 {\n margin: 0.25rem 0.25rem !important;\n}\n\n.mt-1 {\n margin-top: 0.25rem !important;\n}\n\n.mr-1 {\n margin-right: 0.25rem !important;\n}\n\n.mb-1 {\n margin-bottom: 0.25rem !important;\n}\n\n.ml-1 {\n margin-left: 0.25rem !important;\n}\n\n.mx-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n}\n\n.my-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n}\n\n.m-2 {\n margin: 0.5rem 0.5rem !important;\n}\n\n.mt-2 {\n margin-top: 0.5rem !important;\n}\n\n.mr-2 {\n margin-right: 0.5rem !important;\n}\n\n.mb-2 {\n margin-bottom: 0.5rem !important;\n}\n\n.ml-2 {\n margin-left: 0.5rem !important;\n}\n\n.mx-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n}\n\n.my-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n}\n\n.m-3 {\n margin: 1rem 1rem !important;\n}\n\n.mt-3 {\n margin-top: 1rem !important;\n}\n\n.mr-3 {\n margin-right: 1rem !important;\n}\n\n.mb-3 {\n margin-bottom: 1rem !important;\n}\n\n.ml-3 {\n margin-left: 1rem !important;\n}\n\n.mx-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n}\n\n.my-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n}\n\n.m-4 {\n margin: 1.5rem 1.5rem !important;\n}\n\n.mt-4 {\n margin-top: 1.5rem !important;\n}\n\n.mr-4 {\n margin-right: 1.5rem !important;\n}\n\n.mb-4 {\n margin-bottom: 1.5rem !important;\n}\n\n.ml-4 {\n margin-left: 1.5rem !important;\n}\n\n.mx-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n}\n\n.my-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n}\n\n.m-5 {\n margin: 3rem 3rem !important;\n}\n\n.mt-5 {\n margin-top: 3rem !important;\n}\n\n.mr-5 {\n margin-right: 3rem !important;\n}\n\n.mb-5 {\n margin-bottom: 3rem !important;\n}\n\n.ml-5 {\n margin-left: 3rem !important;\n}\n\n.mx-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n}\n\n.my-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n}\n\n.p-0 {\n padding: 0 0 !important;\n}\n\n.pt-0 {\n padding-top: 0 !important;\n}\n\n.pr-0 {\n padding-right: 0 !important;\n}\n\n.pb-0 {\n padding-bottom: 0 !important;\n}\n\n.pl-0 {\n padding-left: 0 !important;\n}\n\n.px-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n}\n\n.py-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n}\n\n.p-1 {\n padding: 0.25rem 0.25rem !important;\n}\n\n.pt-1 {\n padding-top: 0.25rem !important;\n}\n\n.pr-1 {\n padding-right: 0.25rem !important;\n}\n\n.pb-1 {\n padding-bottom: 0.25rem !important;\n}\n\n.pl-1 {\n padding-left: 0.25rem !important;\n}\n\n.px-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n}\n\n.py-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n}\n\n.p-2 {\n padding: 0.5rem 0.5rem !important;\n}\n\n.pt-2 {\n padding-top: 0.5rem !important;\n}\n\n.pr-2 {\n padding-right: 0.5rem !important;\n}\n\n.pb-2 {\n padding-bottom: 0.5rem !important;\n}\n\n.pl-2 {\n padding-left: 0.5rem !important;\n}\n\n.px-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n}\n\n.py-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n}\n\n.p-3 {\n padding: 1rem 1rem !important;\n}\n\n.pt-3 {\n padding-top: 1rem !important;\n}\n\n.pr-3 {\n padding-right: 1rem !important;\n}\n\n.pb-3 {\n padding-bottom: 1rem !important;\n}\n\n.pl-3 {\n padding-left: 1rem !important;\n}\n\n.px-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n}\n\n.py-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n}\n\n.p-4 {\n padding: 1.5rem 1.5rem !important;\n}\n\n.pt-4 {\n padding-top: 1.5rem !important;\n}\n\n.pr-4 {\n padding-right: 1.5rem !important;\n}\n\n.pb-4 {\n padding-bottom: 1.5rem !important;\n}\n\n.pl-4 {\n padding-left: 1.5rem !important;\n}\n\n.px-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n}\n\n.py-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n}\n\n.p-5 {\n padding: 3rem 3rem !important;\n}\n\n.pt-5 {\n padding-top: 3rem !important;\n}\n\n.pr-5 {\n padding-right: 3rem !important;\n}\n\n.pb-5 {\n padding-bottom: 3rem !important;\n}\n\n.pl-5 {\n padding-left: 3rem !important;\n}\n\n.px-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n}\n\n.py-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n}\n\n.m-auto {\n margin: auto !important;\n}\n\n.mt-auto {\n margin-top: auto !important;\n}\n\n.mr-auto {\n margin-right: auto !important;\n}\n\n.mb-auto {\n margin-bottom: auto !important;\n}\n\n.ml-auto {\n margin-left: auto !important;\n}\n\n.mx-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n}\n\n.my-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n}\n\n@media (min-width: 576px) {\n .m-sm-0 {\n margin: 0 0 !important;\n }\n .mt-sm-0 {\n margin-top: 0 !important;\n }\n .mr-sm-0 {\n margin-right: 0 !important;\n }\n .mb-sm-0 {\n margin-bottom: 0 !important;\n }\n .ml-sm-0 {\n margin-left: 0 !important;\n }\n .mx-sm-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-sm-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-sm-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-sm-1 {\n margin-top: 0.25rem !important;\n }\n .mr-sm-1 {\n margin-right: 0.25rem !important;\n }\n .mb-sm-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-sm-1 {\n margin-left: 0.25rem !important;\n }\n .mx-sm-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-sm-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-sm-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-sm-2 {\n margin-top: 0.5rem !important;\n }\n .mr-sm-2 {\n margin-right: 0.5rem !important;\n }\n .mb-sm-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-sm-2 {\n margin-left: 0.5rem !important;\n }\n .mx-sm-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-sm-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-sm-3 {\n margin: 1rem 1rem !important;\n }\n .mt-sm-3 {\n margin-top: 1rem !important;\n }\n .mr-sm-3 {\n margin-right: 1rem !important;\n }\n .mb-sm-3 {\n margin-bottom: 1rem !important;\n }\n .ml-sm-3 {\n margin-left: 1rem !important;\n }\n .mx-sm-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-sm-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-sm-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-sm-4 {\n margin-top: 1.5rem !important;\n }\n .mr-sm-4 {\n margin-right: 1.5rem !important;\n }\n .mb-sm-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-sm-4 {\n margin-left: 1.5rem !important;\n }\n .mx-sm-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-sm-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-sm-5 {\n margin: 3rem 3rem !important;\n }\n .mt-sm-5 {\n margin-top: 3rem !important;\n }\n .mr-sm-5 {\n margin-right: 3rem !important;\n }\n .mb-sm-5 {\n margin-bottom: 3rem !important;\n }\n .ml-sm-5 {\n margin-left: 3rem !important;\n }\n .mx-sm-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-sm-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-sm-0 {\n padding: 0 0 !important;\n }\n .pt-sm-0 {\n padding-top: 0 !important;\n }\n .pr-sm-0 {\n padding-right: 0 !important;\n }\n .pb-sm-0 {\n padding-bottom: 0 !important;\n }\n .pl-sm-0 {\n padding-left: 0 !important;\n }\n .px-sm-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-sm-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-sm-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-sm-1 {\n padding-top: 0.25rem !important;\n }\n .pr-sm-1 {\n padding-right: 0.25rem !important;\n }\n .pb-sm-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-sm-1 {\n padding-left: 0.25rem !important;\n }\n .px-sm-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-sm-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-sm-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-sm-2 {\n padding-top: 0.5rem !important;\n }\n .pr-sm-2 {\n padding-right: 0.5rem !important;\n }\n .pb-sm-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-sm-2 {\n padding-left: 0.5rem !important;\n }\n .px-sm-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-sm-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-sm-3 {\n padding: 1rem 1rem !important;\n }\n .pt-sm-3 {\n padding-top: 1rem !important;\n }\n .pr-sm-3 {\n padding-right: 1rem !important;\n }\n .pb-sm-3 {\n padding-bottom: 1rem !important;\n }\n .pl-sm-3 {\n padding-left: 1rem !important;\n }\n .px-sm-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-sm-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-sm-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-sm-4 {\n padding-top: 1.5rem !important;\n }\n .pr-sm-4 {\n padding-right: 1.5rem !important;\n }\n .pb-sm-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-sm-4 {\n padding-left: 1.5rem !important;\n }\n .px-sm-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-sm-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-sm-5 {\n padding: 3rem 3rem !important;\n }\n .pt-sm-5 {\n padding-top: 3rem !important;\n }\n .pr-sm-5 {\n padding-right: 3rem !important;\n }\n .pb-sm-5 {\n padding-bottom: 3rem !important;\n }\n .pl-sm-5 {\n padding-left: 3rem !important;\n }\n .px-sm-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-sm-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-sm-auto {\n margin: auto !important;\n }\n .mt-sm-auto {\n margin-top: auto !important;\n }\n .mr-sm-auto {\n margin-right: auto !important;\n }\n .mb-sm-auto {\n margin-bottom: auto !important;\n }\n .ml-sm-auto {\n margin-left: auto !important;\n }\n .mx-sm-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-sm-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 768px) {\n .m-md-0 {\n margin: 0 0 !important;\n }\n .mt-md-0 {\n margin-top: 0 !important;\n }\n .mr-md-0 {\n margin-right: 0 !important;\n }\n .mb-md-0 {\n margin-bottom: 0 !important;\n }\n .ml-md-0 {\n margin-left: 0 !important;\n }\n .mx-md-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-md-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-md-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-md-1 {\n margin-top: 0.25rem !important;\n }\n .mr-md-1 {\n margin-right: 0.25rem !important;\n }\n .mb-md-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-md-1 {\n margin-left: 0.25rem !important;\n }\n .mx-md-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-md-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-md-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-md-2 {\n margin-top: 0.5rem !important;\n }\n .mr-md-2 {\n margin-right: 0.5rem !important;\n }\n .mb-md-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-md-2 {\n margin-left: 0.5rem !important;\n }\n .mx-md-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-md-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-md-3 {\n margin: 1rem 1rem !important;\n }\n .mt-md-3 {\n margin-top: 1rem !important;\n }\n .mr-md-3 {\n margin-right: 1rem !important;\n }\n .mb-md-3 {\n margin-bottom: 1rem !important;\n }\n .ml-md-3 {\n margin-left: 1rem !important;\n }\n .mx-md-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-md-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-md-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-md-4 {\n margin-top: 1.5rem !important;\n }\n .mr-md-4 {\n margin-right: 1.5rem !important;\n }\n .mb-md-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-md-4 {\n margin-left: 1.5rem !important;\n }\n .mx-md-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-md-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-md-5 {\n margin: 3rem 3rem !important;\n }\n .mt-md-5 {\n margin-top: 3rem !important;\n }\n .mr-md-5 {\n margin-right: 3rem !important;\n }\n .mb-md-5 {\n margin-bottom: 3rem !important;\n }\n .ml-md-5 {\n margin-left: 3rem !important;\n }\n .mx-md-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-md-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-md-0 {\n padding: 0 0 !important;\n }\n .pt-md-0 {\n padding-top: 0 !important;\n }\n .pr-md-0 {\n padding-right: 0 !important;\n }\n .pb-md-0 {\n padding-bottom: 0 !important;\n }\n .pl-md-0 {\n padding-left: 0 !important;\n }\n .px-md-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-md-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-md-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-md-1 {\n padding-top: 0.25rem !important;\n }\n .pr-md-1 {\n padding-right: 0.25rem !important;\n }\n .pb-md-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-md-1 {\n padding-left: 0.25rem !important;\n }\n .px-md-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-md-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-md-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-md-2 {\n padding-top: 0.5rem !important;\n }\n .pr-md-2 {\n padding-right: 0.5rem !important;\n }\n .pb-md-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-md-2 {\n padding-left: 0.5rem !important;\n }\n .px-md-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-md-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-md-3 {\n padding: 1rem 1rem !important;\n }\n .pt-md-3 {\n padding-top: 1rem !important;\n }\n .pr-md-3 {\n padding-right: 1rem !important;\n }\n .pb-md-3 {\n padding-bottom: 1rem !important;\n }\n .pl-md-3 {\n padding-left: 1rem !important;\n }\n .px-md-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-md-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-md-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-md-4 {\n padding-top: 1.5rem !important;\n }\n .pr-md-4 {\n padding-right: 1.5rem !important;\n }\n .pb-md-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-md-4 {\n padding-left: 1.5rem !important;\n }\n .px-md-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-md-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-md-5 {\n padding: 3rem 3rem !important;\n }\n .pt-md-5 {\n padding-top: 3rem !important;\n }\n .pr-md-5 {\n padding-right: 3rem !important;\n }\n .pb-md-5 {\n padding-bottom: 3rem !important;\n }\n .pl-md-5 {\n padding-left: 3rem !important;\n }\n .px-md-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-md-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-md-auto {\n margin: auto !important;\n }\n .mt-md-auto {\n margin-top: auto !important;\n }\n .mr-md-auto {\n margin-right: auto !important;\n }\n .mb-md-auto {\n margin-bottom: auto !important;\n }\n .ml-md-auto {\n margin-left: auto !important;\n }\n .mx-md-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-md-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 992px) {\n .m-lg-0 {\n margin: 0 0 !important;\n }\n .mt-lg-0 {\n margin-top: 0 !important;\n }\n .mr-lg-0 {\n margin-right: 0 !important;\n }\n .mb-lg-0 {\n margin-bottom: 0 !important;\n }\n .ml-lg-0 {\n margin-left: 0 !important;\n }\n .mx-lg-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-lg-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-lg-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-lg-1 {\n margin-top: 0.25rem !important;\n }\n .mr-lg-1 {\n margin-right: 0.25rem !important;\n }\n .mb-lg-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-lg-1 {\n margin-left: 0.25rem !important;\n }\n .mx-lg-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-lg-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-lg-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-lg-2 {\n margin-top: 0.5rem !important;\n }\n .mr-lg-2 {\n margin-right: 0.5rem !important;\n }\n .mb-lg-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-lg-2 {\n margin-left: 0.5rem !important;\n }\n .mx-lg-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-lg-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-lg-3 {\n margin: 1rem 1rem !important;\n }\n .mt-lg-3 {\n margin-top: 1rem !important;\n }\n .mr-lg-3 {\n margin-right: 1rem !important;\n }\n .mb-lg-3 {\n margin-bottom: 1rem !important;\n }\n .ml-lg-3 {\n margin-left: 1rem !important;\n }\n .mx-lg-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-lg-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-lg-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-lg-4 {\n margin-top: 1.5rem !important;\n }\n .mr-lg-4 {\n margin-right: 1.5rem !important;\n }\n .mb-lg-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-lg-4 {\n margin-left: 1.5rem !important;\n }\n .mx-lg-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-lg-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-lg-5 {\n margin: 3rem 3rem !important;\n }\n .mt-lg-5 {\n margin-top: 3rem !important;\n }\n .mr-lg-5 {\n margin-right: 3rem !important;\n }\n .mb-lg-5 {\n margin-bottom: 3rem !important;\n }\n .ml-lg-5 {\n margin-left: 3rem !important;\n }\n .mx-lg-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-lg-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-lg-0 {\n padding: 0 0 !important;\n }\n .pt-lg-0 {\n padding-top: 0 !important;\n }\n .pr-lg-0 {\n padding-right: 0 !important;\n }\n .pb-lg-0 {\n padding-bottom: 0 !important;\n }\n .pl-lg-0 {\n padding-left: 0 !important;\n }\n .px-lg-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-lg-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-lg-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-lg-1 {\n padding-top: 0.25rem !important;\n }\n .pr-lg-1 {\n padding-right: 0.25rem !important;\n }\n .pb-lg-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-lg-1 {\n padding-left: 0.25rem !important;\n }\n .px-lg-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-lg-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-lg-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-lg-2 {\n padding-top: 0.5rem !important;\n }\n .pr-lg-2 {\n padding-right: 0.5rem !important;\n }\n .pb-lg-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-lg-2 {\n padding-left: 0.5rem !important;\n }\n .px-lg-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-lg-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-lg-3 {\n padding: 1rem 1rem !important;\n }\n .pt-lg-3 {\n padding-top: 1rem !important;\n }\n .pr-lg-3 {\n padding-right: 1rem !important;\n }\n .pb-lg-3 {\n padding-bottom: 1rem !important;\n }\n .pl-lg-3 {\n padding-left: 1rem !important;\n }\n .px-lg-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-lg-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-lg-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-lg-4 {\n padding-top: 1.5rem !important;\n }\n .pr-lg-4 {\n padding-right: 1.5rem !important;\n }\n .pb-lg-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-lg-4 {\n padding-left: 1.5rem !important;\n }\n .px-lg-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-lg-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-lg-5 {\n padding: 3rem 3rem !important;\n }\n .pt-lg-5 {\n padding-top: 3rem !important;\n }\n .pr-lg-5 {\n padding-right: 3rem !important;\n }\n .pb-lg-5 {\n padding-bottom: 3rem !important;\n }\n .pl-lg-5 {\n padding-left: 3rem !important;\n }\n .px-lg-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-lg-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-lg-auto {\n margin: auto !important;\n }\n .mt-lg-auto {\n margin-top: auto !important;\n }\n .mr-lg-auto {\n margin-right: auto !important;\n }\n .mb-lg-auto {\n margin-bottom: auto !important;\n }\n .ml-lg-auto {\n margin-left: auto !important;\n }\n .mx-lg-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-lg-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 1200px) {\n .m-xl-0 {\n margin: 0 0 !important;\n }\n .mt-xl-0 {\n margin-top: 0 !important;\n }\n .mr-xl-0 {\n margin-right: 0 !important;\n }\n .mb-xl-0 {\n margin-bottom: 0 !important;\n }\n .ml-xl-0 {\n margin-left: 0 !important;\n }\n .mx-xl-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-xl-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-xl-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-xl-1 {\n margin-top: 0.25rem !important;\n }\n .mr-xl-1 {\n margin-right: 0.25rem !important;\n }\n .mb-xl-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-xl-1 {\n margin-left: 0.25rem !important;\n }\n .mx-xl-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-xl-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-xl-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-xl-2 {\n margin-top: 0.5rem !important;\n }\n .mr-xl-2 {\n margin-right: 0.5rem !important;\n }\n .mb-xl-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-xl-2 {\n margin-left: 0.5rem !important;\n }\n .mx-xl-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-xl-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-xl-3 {\n margin: 1rem 1rem !important;\n }\n .mt-xl-3 {\n margin-top: 1rem !important;\n }\n .mr-xl-3 {\n margin-right: 1rem !important;\n }\n .mb-xl-3 {\n margin-bottom: 1rem !important;\n }\n .ml-xl-3 {\n margin-left: 1rem !important;\n }\n .mx-xl-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-xl-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-xl-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-xl-4 {\n margin-top: 1.5rem !important;\n }\n .mr-xl-4 {\n margin-right: 1.5rem !important;\n }\n .mb-xl-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-xl-4 {\n margin-left: 1.5rem !important;\n }\n .mx-xl-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-xl-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-xl-5 {\n margin: 3rem 3rem !important;\n }\n .mt-xl-5 {\n margin-top: 3rem !important;\n }\n .mr-xl-5 {\n margin-right: 3rem !important;\n }\n .mb-xl-5 {\n margin-bottom: 3rem !important;\n }\n .ml-xl-5 {\n margin-left: 3rem !important;\n }\n .mx-xl-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-xl-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-xl-0 {\n padding: 0 0 !important;\n }\n .pt-xl-0 {\n padding-top: 0 !important;\n }\n .pr-xl-0 {\n padding-right: 0 !important;\n }\n .pb-xl-0 {\n padding-bottom: 0 !important;\n }\n .pl-xl-0 {\n padding-left: 0 !important;\n }\n .px-xl-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-xl-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-xl-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-xl-1 {\n padding-top: 0.25rem !important;\n }\n .pr-xl-1 {\n padding-right: 0.25rem !important;\n }\n .pb-xl-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-xl-1 {\n padding-left: 0.25rem !important;\n }\n .px-xl-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-xl-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-xl-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-xl-2 {\n padding-top: 0.5rem !important;\n }\n .pr-xl-2 {\n padding-right: 0.5rem !important;\n }\n .pb-xl-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-xl-2 {\n padding-left: 0.5rem !important;\n }\n .px-xl-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-xl-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-xl-3 {\n padding: 1rem 1rem !important;\n }\n .pt-xl-3 {\n padding-top: 1rem !important;\n }\n .pr-xl-3 {\n padding-right: 1rem !important;\n }\n .pb-xl-3 {\n padding-bottom: 1rem !important;\n }\n .pl-xl-3 {\n padding-left: 1rem !important;\n }\n .px-xl-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-xl-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-xl-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-xl-4 {\n padding-top: 1.5rem !important;\n }\n .pr-xl-4 {\n padding-right: 1.5rem !important;\n }\n .pb-xl-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-xl-4 {\n padding-left: 1.5rem !important;\n }\n .px-xl-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-xl-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-xl-5 {\n padding: 3rem 3rem !important;\n }\n .pt-xl-5 {\n padding-top: 3rem !important;\n }\n .pr-xl-5 {\n padding-right: 3rem !important;\n }\n .pb-xl-5 {\n padding-bottom: 3rem !important;\n }\n .pl-xl-5 {\n padding-left: 3rem !important;\n }\n .px-xl-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-xl-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-xl-auto {\n margin: auto !important;\n }\n .mt-xl-auto {\n margin-top: auto !important;\n }\n .mr-xl-auto {\n margin-right: auto !important;\n }\n .mb-xl-auto {\n margin-bottom: auto !important;\n }\n .ml-xl-auto {\n margin-left: auto !important;\n }\n .mx-xl-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-xl-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n.text-justify {\n text-align: justify !important;\n}\n\n.text-nowrap {\n white-space: nowrap !important;\n}\n\n.text-truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.text-left {\n text-align: left !important;\n}\n\n.text-right {\n text-align: right !important;\n}\n\n.text-center {\n text-align: center !important;\n}\n\n@media (min-width: 576px) {\n .text-sm-left {\n text-align: left !important;\n }\n .text-sm-right {\n text-align: right !important;\n }\n .text-sm-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 768px) {\n .text-md-left {\n text-align: left !important;\n }\n .text-md-right {\n text-align: right !important;\n }\n .text-md-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 992px) {\n .text-lg-left {\n text-align: left !important;\n }\n .text-lg-right {\n text-align: right !important;\n }\n .text-lg-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 1200px) {\n .text-xl-left {\n text-align: left !important;\n }\n .text-xl-right {\n text-align: right !important;\n }\n .text-xl-center {\n text-align: center !important;\n }\n}\n\n.text-lowercase {\n text-transform: lowercase !important;\n}\n\n.text-uppercase {\n text-transform: uppercase !important;\n}\n\n.text-capitalize {\n text-transform: capitalize !important;\n}\n\n.font-weight-normal {\n font-weight: normal;\n}\n\n.font-weight-bold {\n font-weight: bold;\n}\n\n.font-italic {\n font-style: italic;\n}\n\n.text-white {\n color: #fff !important;\n}\n\n.text-muted {\n color: #636c72 !important;\n}\n\na.text-muted:focus, a.text-muted:hover {\n color: #4b5257 !important;\n}\n\n.text-primary {\n color: #0275d8 !important;\n}\n\na.text-primary:focus, a.text-primary:hover {\n color: #025aa5 !important;\n}\n\n.text-success {\n color: #5cb85c !important;\n}\n\na.text-success:focus, a.text-success:hover {\n color: #449d44 !important;\n}\n\n.text-info {\n color: #5bc0de !important;\n}\n\na.text-info:focus, a.text-info:hover {\n color: #31b0d5 !important;\n}\n\n.text-warning {\n color: #f0ad4e !important;\n}\n\na.text-warning:focus, a.text-warning:hover {\n color: #ec971f !important;\n}\n\n.text-danger {\n color: #d9534f !important;\n}\n\na.text-danger:focus, a.text-danger:hover {\n color: #c9302c !important;\n}\n\n.text-gray-dark {\n color: #292b2c !important;\n}\n\na.text-gray-dark:focus, a.text-gray-dark:hover {\n color: #101112 !important;\n}\n\n.text-hide {\n font: 0/0 a;\n color: transparent;\n text-shadow: none;\n background-color: transparent;\n border: 0;\n}\n\n.invisible {\n visibility: hidden !important;\n}\n\n.hidden-xs-up {\n display: none !important;\n}\n\n@media (max-width: 575px) {\n .hidden-xs-down {\n display: none !important;\n }\n}\n\n@media (min-width: 576px) {\n .hidden-sm-up {\n display: none !important;\n }\n}\n\n@media (max-width: 767px) {\n .hidden-sm-down {\n display: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .hidden-md-up {\n display: none !important;\n }\n}\n\n@media (max-width: 991px) {\n .hidden-md-down {\n display: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .hidden-lg-up {\n display: none !important;\n }\n}\n\n@media (max-width: 1199px) {\n .hidden-lg-down {\n display: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .hidden-xl-up {\n display: none !important;\n }\n}\n\n.hidden-xl-down {\n display: none !important;\n}\n\n.visible-print-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-block {\n display: block !important;\n }\n}\n\n.visible-print-inline {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline {\n display: inline !important;\n }\n}\n\n.visible-print-inline-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline-block {\n display: inline-block !important;\n }\n}\n\n@media print {\n .hidden-print {\n display: none !important;\n }\n}", ""]); +hash.utils = __webpack_require__(25); +hash.common = __webpack_require__(50); +hash.sha = __webpack_require__(393); +hash.ripemd = __webpack_require__(397); +hash.hmac = __webpack_require__(398); -// exports +// Proxy hash functions to the main object +hash.sha1 = hash.sha.sha1; +hash.sha256 = hash.sha.sha256; +hash.sha224 = hash.sha.sha224; +hash.sha384 = hash.sha.sha384; +hash.sha512 = hash.sha.sha512; +hash.ripemd160 = hash.ripemd.ripemd160; /***/ }), -/* 119 */ -/***/ (function(module, exports) { +/* 106 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +/* WEBPACK VAR INJECTION */(function(global) { -/** - * When source maps are enabled, `style-loader` uses a link element with a data-uri to - * embed the css on the page. This breaks all relative urls because now they are relative to a - * bundle instead of the current page. - * - * One solution is to only use full urls, but that may be impossible. - * - * Instead, this function "fixes" the relative urls to be absolute according to the current page location. - * - * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command. +// compare and isBuffer taken from https://github.com/feross/buffer/blob/680e9e5e488f22aac27599a57dc844a6315928dd/index.js +// original notice: + +/*! + * The buffer module from node.js, for the browser. * + * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> + * @license MIT */ +function compare(a, b) { + if (a === b) { + return 0; + } -module.exports = function (css) { - // get current location - var location = typeof window !== "undefined" && window.location; + var x = a.length; + var y = b.length; - if (!location) { - throw new Error("fixUrls requires window.location"); + for (var i = 0, len = Math.min(x, y); i < len; ++i) { + if (a[i] !== b[i]) { + x = a[i]; + y = b[i]; + break; + } } - // blank or null? - if (!css || typeof css !== "string") { - return css; + if (x < y) { + return -1; } + if (y < x) { + return 1; + } + return 0; +} +function isBuffer(b) { + if (global.Buffer && typeof global.Buffer.isBuffer === 'function') { + return global.Buffer.isBuffer(b); + } + return !!(b != null && b._isBuffer); +} - var baseUrl = location.protocol + "//" + location.host; - var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/"); - - // convert each url(...) - /* - This regular expression is just a way to recursively match brackets within - a string. +// based on node assert, original notice: - /url\s*\( = Match on the word "url" with any whitespace after it and then a parens - ( = Start a capturing group - (?: = Start a non-capturing group - [^)(] = Match anything that isn't a parentheses - | = OR - \( = Match a start parentheses - (?: = Start another non-capturing groups - [^)(]+ = Match anything that isn't a parentheses - | = OR - \( = Match a start parentheses - [^)(]* = Match anything that isn't a parentheses - \) = Match a end parentheses - ) = End Group - *\) = Match anything and then a close parens - ) = Close non-capturing group - * = Match anything - ) = Close capturing group - \) = Match a close parens +// http://wiki.commonjs.org/wiki/Unit_Testing/1.0 +// +// THIS IS NOT TESTED NOR LIKELY TO WORK OUTSIDE V8! +// +// Originally from narwhal.js (http://narwhaljs.org) +// Copyright (c) 2009 Thomas Robinson <280north.com> +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the 'Software'), to +// deal in the Software without restriction, including without limitation the +// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +// sell copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN +// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - /gi = Get all matches, not the first. Be case insensitive. - */ - var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) { - // strip quotes (if they exist) - var unquotedOrigUrl = origUrl - .trim() - .replace(/^"(.*)"$/, function(o, $1){ return $1; }) - .replace(/^'(.*)'$/, function(o, $1){ return $1; }); +var util = __webpack_require__(409); +var hasOwn = Object.prototype.hasOwnProperty; +var pSlice = Array.prototype.slice; +var functionsHaveNames = (function () { + return function foo() {}.name === 'foo'; +}()); +function pToString (obj) { + return Object.prototype.toString.call(obj); +} +function isView(arrbuf) { + if (isBuffer(arrbuf)) { + return false; + } + if (typeof global.ArrayBuffer !== 'function') { + return false; + } + if (typeof ArrayBuffer.isView === 'function') { + return ArrayBuffer.isView(arrbuf); + } + if (!arrbuf) { + return false; + } + if (arrbuf instanceof DataView) { + return true; + } + if (arrbuf.buffer && arrbuf.buffer instanceof ArrayBuffer) { + return true; + } + return false; +} +// 1. The assert module provides functions that throw +// AssertionError's when particular conditions are not met. The +// assert module must conform to the following interface. - // already a full url? no change - if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(unquotedOrigUrl)) { - return fullMatch; - } +var assert = module.exports = ok; - // convert the url to a full url - var newUrl; +// 2. The AssertionError is defined in assert. +// new assert.AssertionError({ message: message, +// actual: actual, +// expected: expected }) - if (unquotedOrigUrl.indexOf("//") === 0) { - //TODO: should we add protocol? - newUrl = unquotedOrigUrl; - } else if (unquotedOrigUrl.indexOf("/") === 0) { - // path should be relative to the base url - newUrl = baseUrl + unquotedOrigUrl; // already starts with '/' - } else { - // path should be relative to current directory - newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './' - } +var regex = /\s*function\s+([^\(\s]*)\s*/; +// based on https://github.com/ljharb/function.prototype.name/blob/adeeeec8bfcc6068b187d7d9fb3d5bb1d3a30899/implementation.js +function getName(func) { + if (!util.isFunction(func)) { + return; + } + if (functionsHaveNames) { + return func.name; + } + var str = func.toString(); + var match = str.match(regex); + return match && match[1]; +} +assert.AssertionError = function AssertionError(options) { + this.name = 'AssertionError'; + this.actual = options.actual; + this.expected = options.expected; + this.operator = options.operator; + if (options.message) { + this.message = options.message; + this.generatedMessage = false; + } else { + this.message = getMessage(this); + this.generatedMessage = true; + } + var stackStartFunction = options.stackStartFunction || fail; + if (Error.captureStackTrace) { + Error.captureStackTrace(this, stackStartFunction); + } else { + // non v8 browsers so we can have a stacktrace + var err = new Error(); + if (err.stack) { + var out = err.stack; - // send back the fixed url(...) - return "url(" + JSON.stringify(newUrl) + ")"; - }); + // try to strip useless frames + var fn_name = getName(stackStartFunction); + var idx = out.indexOf('\n' + fn_name); + if (idx >= 0) { + // once we have located the function frame + // we need to strip out everything before it (and its line) + var next_line = out.indexOf('\n', idx + 1); + out = out.substring(next_line + 1); + } - // send back the fixed css - return fixedCss; + this.stack = out; + } + } }; +// assert.AssertionError instanceof Error +util.inherits(assert.AssertionError, Error); -/***/ }), -/* 120 */ -/***/ (function(module, exports, __webpack_require__) { +function truncate(s, n) { + if (typeof s === 'string') { + return s.length < n ? s : s.slice(0, n); + } else { + return s; + } +} +function inspect(something) { + if (functionsHaveNames || !util.isFunction(something)) { + return util.inspect(something); + } + var rawname = getName(something); + var name = rawname ? ': ' + rawname : ''; + return '[Function' + name + ']'; +} +function getMessage(self) { + return truncate(inspect(self.actual), 128) + ' ' + + self.operator + ' ' + + truncate(inspect(self.expected), 128); +} -// style-loader: Adds some css to the DOM by adding a <style> tag +// At present only the three keys mentioned above are used and +// understood by the spec. Implementations or sub modules can pass +// other keys to the AssertionError's constructor - they will be +// ignored. -// load the styles -var content = __webpack_require__(121); -if(typeof content === 'string') content = [[module.i, content, '']]; -// Prepare cssTransformation -var transform; +// 3. All of the following functions must throw an AssertionError +// when a corresponding condition is not met, with a message that +// may be undefined if not provided. All assertion methods provide +// both the actual and expected values to the assertion error for +// display purposes. -var options = {} -options.transform = transform -// add the styles to the DOM -var update = __webpack_require__(73)(content, options); -if(content.locals) module.exports = content.locals; -// Hot Module Replacement -if(false) { - // When the styles change, update the <style> tags - if(!content.locals) { - module.hot.accept("!!../../css-loader/index.js!./react-bootstrap-table-all.min.css", function() { - var newContent = require("!!../../css-loader/index.js!./react-bootstrap-table-all.min.css"); - if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; - update(newContent); - }); - } - // When the module is disposed, remove the <style> tags - module.hot.dispose(function() { update(); }); +function fail(actual, expected, message, operator, stackStartFunction) { + throw new assert.AssertionError({ + message: message, + actual: actual, + expected: expected, + operator: operator, + stackStartFunction: stackStartFunction + }); } -/***/ }), -/* 121 */ -/***/ (function(module, exports, __webpack_require__) { +// EXTENSION! allows for well behaved errors defined elsewhere. +assert.fail = fail; -exports = module.exports = __webpack_require__(72)(undefined); -// imports +// 4. Pure assertion tests whether a value is truthy, as determined +// by !!guard. +// assert.ok(guard, message_opt); +// This statement is equivalent to assert.equal(true, !!guard, +// message_opt);. To test strictly for the value true, use +// assert.strictEqual(true, guard, message_opt);. +function ok(value, message) { + if (!value) fail(value, true, message, '==', assert.ok); +} +assert.ok = ok; -// module -exports.push([module.i, ".react-bs-table .react-bs-container-header .sort-column,.s-alert-close,td.react-bs-table-expand-cell{cursor:pointer}.react-bs-table-container .react-bs-table-search-form{margin-bottom:0}.react-bs-table-bordered{border:1px solid #ddd;border-radius:5px}.react-bs-table table{margin-bottom:0;table-layout:fixed}.react-bs-table table td,.react-bs-table table th{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.react-bs-table-pagination{margin-top:10px}.react-bs-table-tool-bar{margin-bottom:5px}.react-bs-container-header{overflow:hidden;width:100%}.react-bs-container-body{overflow:auto;width:100%}.react-bootstrap-table-page-btns-ul{float:right;margin-top:0}.react-bs-table .table-bordered{border:0;outline:0!important}.react-bs-table .table-bordered>thead>tr>td,.react-bs-table .table-bordered>thead>tr>th{border-bottom-width:2px}.react-bs-table .table-bordered>tbody>tr>td{outline:0!important}.react-bs-table .table-bordered>tbody>tr>td.default-focus-cell{outline:#6495ed solid 3px!important;outline-offset:-1px}.react-bs-table .table-bordered>tfoot>tr>td,.react-bs-table .table-bordered>tfoot>tr>th{border-top-width:2px;border-bottom-width:0}.react-bs-table .table-bordered>tbody>tr>td:first-child,.react-bs-table .table-bordered>tbody>tr>th:first-child,.react-bs-table .table-bordered>tfoot>tr>td:first-child,.react-bs-table .table-bordered>tfoot>tr>th:first-child,.react-bs-table .table-bordered>thead>tr>td:first-child,.react-bs-table .table-bordered>thead>tr>th:first-child{border-left-width:0}.react-bs-table .table-bordered>tbody>tr>td:last-child,.react-bs-table .table-bordered>tbody>tr>th:last-child,.react-bs-table .table-bordered>tfoot>tr>td:last-child,.react-bs-table .table-bordered>tfoot>tr>th:last-child,.react-bs-table .table-bordered>thead>tr>td:last-child,.react-bs-table .table-bordered>thead>tr>th:last-child{border-right-width:0}.react-bs-table .table-bordered>thead>tr:first-child>td,.react-bs-table .table-bordered>thead>tr:first-child>th{border-top-width:0}.react-bs-table .table-bordered>tfoot>tr:last-child>td,.react-bs-table .table-bordered>tfoot>tr:last-child>th{border-bottom-width:0}.react-bs-table .react-bs-container-header>table>thead>tr>th{vertical-align:middle}.react-bs-table .react-bs-container-header>table>thead>tr>th .filter{font-weight:400}.react-bs-table .react-bs-container-header>table>thead>tr>th .filter::-webkit-input-placeholder,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-input::-webkit-input-placeholder,.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter option[value=''],.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter.placeholder-selected{color:#d3d3d3;font-style:italic}.react-bs-table .react-bs-container-header>table>thead>tr>th .select-filter.placeholder-selected option:not([value='']){color:initial;font-style:initial}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter{display:flex}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter-input,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-input{margin-left:5px;float:left;width:calc(100% - 67px - 5px)}.react-bs-table .react-bs-container-header>table>thead>tr>th .date-filter-comparator,.react-bs-table .react-bs-container-header>table>thead>tr>th .number-filter-comparator{width:67px;float:left}.react-bs-container .textarea-save-btn{position:absolute;z-index:100;right:0;top:-21px}.react-bs-table-no-data{text-align:center}.ReactModal__Overlay{-webkit-perspective:600;perspective:600;opacity:0;overflow-x:hidden;overflow-y:auto;background-color:rgba(0,0,0,.5);z-index:101}.ReactModal__Overlay--after-open{opacity:1;transition:opacity 150ms ease-out}.ReactModal__Content{-webkit-transform:scale(.5) rotateX(-30deg);transform:scale(.5) rotateX(-30deg)}.ReactModal__Content--after-open{-webkit-transform:scale(1) rotateX(0);transform:scale(1) rotateX(0);transition:all 150ms ease-in}.ReactModal__Overlay--before-close{opacity:0}.ReactModal__Content--before-close{-webkit-transform:scale(.5) rotateX(30deg);transform:scale(.5) rotateX(30deg);transition:all 150ms ease-in}.ReactModal__Content.modal-dialog{border:none;background-color:transparent}.animated{animation-fill-mode:both}.animated.bounceIn,.animated.bounceOut{animation-duration:.75s}.animated.shake{animation-duration:.3s}@keyframes shake{from,to{transform:translate3d(0,0,0)}10%,50%,90%{transform:translate3d(-10px,0,0)}30%,70%{transform:translate3d(10px,0,0)}}.shake{animation-name:shake}@keyframes bounceIn{20%,40%,60%,80%,from,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:scale3d(.3,.3,.3)}20%{transform:scale3d(1.1,1.1,1.1)}40%{transform:scale3d(.9,.9,.9)}60%{opacity:1;transform:scale3d(1.03,1.03,1.03)}80%{transform:scale3d(.97,.97,.97)}to{opacity:1;transform:scale3d(1,1,1)}}.bounceIn{animation-name:bounceIn}@keyframes bounceOut{20%{transform:scale3d(.9,.9,.9)}50%,55%{opacity:1;transform:scale3d(1.1,1.1,1.1)}to{opacity:0;transform:scale3d(.3,.3,.3)}}.bounceOut{animation-name:bounceOut}.s-alert-box,.s-alert-box *{box-sizing:border-box}.s-alert-box{position:fixed;background:rgba(42,45,50,.85);padding:22px;line-height:1.4;z-index:1000;pointer-events:none;color:rgba(250,251,255,.95);font-size:100%;font-family:'Helvetica Neue','Segoe UI',Helvetica,Arial,sans-serif;max-width:300px;-webkit-transition:top .4s,bottom .4s;transition:top .4s,bottom .4s}.s-alert-box.s-alert-show,.s-alert-box.s-alert-visible{pointer-events:auto}.s-alert-box a{color:inherit;opacity:.7;font-weight:700}.s-alert-box a:focus,.s-alert-box a:hover{opacity:1}.s-alert-box p{margin:0}.s-alert-close{width:20px;height:20px;position:absolute;right:4px;top:4px;overflow:hidden;text-indent:100%;-webkit-backface-visibility:hidden;backface-visibility:hidden}.s-alert-close:focus,.s-alert-close:hover{outline:0}.s-alert-close::after,.s-alert-close::before{content:'';position:absolute;width:3px;height:60%;top:50%;left:50%;background:#fff}.s-alert-close:hover::after,.s-alert-close:hover::before{background:#fff}.s-alert-close::before{-webkit-transform:translate(-50%,-50%) rotate(45deg);transform:translate(-50%,-50%) rotate(45deg)}.s-alert-close::after{-webkit-transform:translate(-50%,-50%) rotate(-45deg);transform:translate(-50%,-50%) rotate(-45deg)}.s-alert-bottom-left{top:auto;right:auto;bottom:30px;left:30px}.s-alert-top-left{top:30px;right:auto;bottom:auto;left:30px}.s-alert-top-right{top:30px;right:30px;bottom:auto;left:auto}.s-alert-bottom-right{top:auto;right:30px;bottom:30px;left:auto}.s-alert-bottom,.s-alert-top{width:100%;max-width:100%;left:0;right:0}.s-alert-bottom{bottom:0;top:auto}.s-alert-top{top:0;bottom:auto}.s-alert-info{background:#00A2D3;color:#fff}.s-alert-success{background:#27AE60;color:#fff}.s-alert-warning{background:#F1C40F;color:#fff}.s-alert-error{background:#E74C3C;color:#fff}[class*=\" s-alert-effect-\"].s-alert-hide,[class^=s-alert-effect-].s-alert-hide{-webkit-animation-direction:reverse;animation-direction:reverse}.s-alert-box-height{visibility:hidden;position:fixed}.s-alert-effect-scale a,.s-alert-effect-scale a:focus,.s-alert-effect-scale a:hover{color:#fff}.s-alert-effect-scale .s-alert-close::after,.s-alert-effect-scale .s-alert-close::before,.s-alert-effect-scale .s-alert-close:hover::after,.s-alert-effect-scale .s-alert-close:hover::before{background:#fff}.s-alert-effect-scale.s-alert-hide,.s-alert-effect-scale.s-alert-show{-webkit-animation-name:animScale;animation-name:animScale;-webkit-animation-duration:.25s;animation-duration:.25s}@-webkit-keyframes animScale{0%{opacity:0;-webkit-transform:translate3d(0,40px,0) scale3d(.1,.6,1)}100%{opacity:1;-webkit-transform:translate3d(0,0,0) scale3d(1,1,1)}}@keyframes animScale{0%{opacity:0;-webkit-transform:translate3d(0,40px,0) scale3d(.1,.6,1);transform:translate3d(0,40px,0) scale3d(.1,.6,1)}100%{opacity:1;-webkit-transform:translate3d(0,0,0) scale3d(1,1,1);transform:translate3d(0,0,0) scale3d(1,1,1)}}", ""]); +// 5. The equality assertion tests shallow, coercive equality with +// ==. +// assert.equal(actual, expected, message_opt); -// exports +assert.equal = function equal(actual, expected, message) { + if (actual != expected) fail(actual, expected, message, '==', assert.equal); +}; +// 6. The non-equality assertion tests for whether two objects are not equal +// with != assert.notEqual(actual, expected, message_opt); -/***/ }), -/* 122 */ -/***/ (function(module, exports, __webpack_require__) { +assert.notEqual = function notEqual(actual, expected, message) { + if (actual == expected) { + fail(actual, expected, message, '!=', assert.notEqual); + } +}; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +// 7. The equivalence assertion tests a deep equality relation. +// assert.deepEqual(actual, expected, message_opt); +assert.deepEqual = function deepEqual(actual, expected, message) { + if (!_deepEqual(actual, expected, false)) { + fail(actual, expected, message, 'deepEqual', assert.deepEqual); + } +}; + +assert.deepStrictEqual = function deepStrictEqual(actual, expected, message) { + if (!_deepEqual(actual, expected, true)) { + fail(actual, expected, message, 'deepStrictEqual', assert.deepStrictEqual); + } +}; +function _deepEqual(actual, expected, strict, memos) { + // 7.1. All identical values are equivalent, as determined by ===. + if (actual === expected) { + return true; + } else if (isBuffer(actual) && isBuffer(expected)) { + return compare(actual, expected) === 0; -var PooledClass = __webpack_require__(123); -var ReactElement = __webpack_require__(19); + // 7.2. If the expected value is a Date object, the actual value is + // equivalent if it is also a Date object that refers to the same time. + } else if (util.isDate(actual) && util.isDate(expected)) { + return actual.getTime() === expected.getTime(); -var emptyFunction = __webpack_require__(12); -var traverseAllChildren = __webpack_require__(124); + // 7.3 If the expected value is a RegExp object, the actual value is + // equivalent if it is also a RegExp object with the same source and + // properties (`global`, `multiline`, `lastIndex`, `ignoreCase`). + } else if (util.isRegExp(actual) && util.isRegExp(expected)) { + return actual.source === expected.source && + actual.global === expected.global && + actual.multiline === expected.multiline && + actual.lastIndex === expected.lastIndex && + actual.ignoreCase === expected.ignoreCase; -var twoArgumentPooler = PooledClass.twoArgumentPooler; -var fourArgumentPooler = PooledClass.fourArgumentPooler; + // 7.4. Other pairs that do not both pass typeof value == 'object', + // equivalence is determined by ==. + } else if ((actual === null || typeof actual !== 'object') && + (expected === null || typeof expected !== 'object')) { + return strict ? actual === expected : actual == expected; -var userProvidedKeyEscapeRegex = /\/+/g; -function escapeUserProvidedKey(text) { - return ('' + text).replace(userProvidedKeyEscapeRegex, '$&/'); -} + // If both values are instances of typed arrays, wrap their underlying + // ArrayBuffers in a Buffer each to increase performance + // This optimization requires the arrays to have the same type as checked by + // Object.prototype.toString (aka pToString). Never perform binary + // comparisons for Float*Arrays, though, since e.g. +0 === -0 but their + // bit patterns are not identical. + } else if (isView(actual) && isView(expected) && + pToString(actual) === pToString(expected) && + !(actual instanceof Float32Array || + actual instanceof Float64Array)) { + return compare(new Uint8Array(actual.buffer), + new Uint8Array(expected.buffer)) === 0; -/** - * PooledClass representing the bookkeeping associated with performing a child - * traversal. Allows avoiding binding callbacks. - * - * @constructor ForEachBookKeeping - * @param {!function} forEachFunction Function to perform traversal with. - * @param {?*} forEachContext Context to perform context with. - */ -function ForEachBookKeeping(forEachFunction, forEachContext) { - this.func = forEachFunction; - this.context = forEachContext; - this.count = 0; -} -ForEachBookKeeping.prototype.destructor = function () { - this.func = null; - this.context = null; - this.count = 0; -}; -PooledClass.addPoolingTo(ForEachBookKeeping, twoArgumentPooler); + // 7.5 For all other Object pairs, including Array objects, equivalence is + // determined by having the same number of owned properties (as verified + // with Object.prototype.hasOwnProperty.call), the same set of keys + // (although not necessarily the same order), equivalent values for every + // corresponding key, and an identical 'prototype' property. Note: this + // accounts for both named and indexed properties on Arrays. + } else if (isBuffer(actual) !== isBuffer(expected)) { + return false; + } else { + memos = memos || {actual: [], expected: []}; -function forEachSingleChild(bookKeeping, child, name) { - var func = bookKeeping.func, - context = bookKeeping.context; + var actualIndex = memos.actual.indexOf(actual); + if (actualIndex !== -1) { + if (actualIndex === memos.expected.indexOf(expected)) { + return true; + } + } - func.call(context, child, bookKeeping.count++); -} + memos.actual.push(actual); + memos.expected.push(expected); -/** - * Iterates through children that are typically specified as `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.foreach - * - * The provided forEachFunc(child, index) will be called for each - * leaf child. - * - * @param {?*} children Children tree container. - * @param {function(*, int)} forEachFunc - * @param {*} forEachContext Context for forEachContext. - */ -function forEachChildren(children, forEachFunc, forEachContext) { - if (children == null) { - return children; + return objEquiv(actual, expected, strict, memos); } - var traverseContext = ForEachBookKeeping.getPooled(forEachFunc, forEachContext); - traverseAllChildren(children, forEachSingleChild, traverseContext); - ForEachBookKeeping.release(traverseContext); } -/** - * PooledClass representing the bookkeeping associated with performing a child - * mapping. Allows avoiding binding callbacks. - * - * @constructor MapBookKeeping - * @param {!*} mapResult Object containing the ordered map of results. - * @param {!function} mapFunction Function to perform mapping with. - * @param {?*} mapContext Context to perform mapping with. - */ -function MapBookKeeping(mapResult, keyPrefix, mapFunction, mapContext) { - this.result = mapResult; - this.keyPrefix = keyPrefix; - this.func = mapFunction; - this.context = mapContext; - this.count = 0; +function isArguments(object) { + return Object.prototype.toString.call(object) == '[object Arguments]'; } -MapBookKeeping.prototype.destructor = function () { - this.result = null; - this.keyPrefix = null; - this.func = null; - this.context = null; - this.count = 0; -}; -PooledClass.addPoolingTo(MapBookKeeping, fourArgumentPooler); -function mapSingleChildIntoContext(bookKeeping, child, childKey) { - var result = bookKeeping.result, - keyPrefix = bookKeeping.keyPrefix, - func = bookKeeping.func, - context = bookKeeping.context; +function objEquiv(a, b, strict, actualVisitedObjects) { + if (a === null || a === undefined || b === null || b === undefined) + return false; + // if one is a primitive, the other must be same + if (util.isPrimitive(a) || util.isPrimitive(b)) + return a === b; + if (strict && Object.getPrototypeOf(a) !== Object.getPrototypeOf(b)) + return false; + var aIsArgs = isArguments(a); + var bIsArgs = isArguments(b); + if ((aIsArgs && !bIsArgs) || (!aIsArgs && bIsArgs)) + return false; + if (aIsArgs) { + a = pSlice.call(a); + b = pSlice.call(b); + return _deepEqual(a, b, strict); + } + var ka = objectKeys(a); + var kb = objectKeys(b); + var key, i; + // having the same number of owned properties (keys incorporates + // hasOwnProperty) + if (ka.length !== kb.length) + return false; + //the same set of keys (although not necessarily the same order), + ka.sort(); + kb.sort(); + //~~~cheap key test + for (i = ka.length - 1; i >= 0; i--) { + if (ka[i] !== kb[i]) + return false; + } + //equivalent values for every corresponding key, and + //~~~possibly expensive deep test + for (i = ka.length - 1; i >= 0; i--) { + key = ka[i]; + if (!_deepEqual(a[key], b[key], strict, actualVisitedObjects)) + return false; + } + return true; +} +// 8. The non-equivalence assertion tests for any deep inequality. +// assert.notDeepEqual(actual, expected, message_opt); - var mappedChild = func.call(context, child, bookKeeping.count++); - if (Array.isArray(mappedChild)) { - mapIntoWithKeyPrefixInternal(mappedChild, result, childKey, emptyFunction.thatReturnsArgument); - } else if (mappedChild != null) { - if (ReactElement.isValidElement(mappedChild)) { - mappedChild = ReactElement.cloneAndReplaceKey(mappedChild, - // Keep both the (mapped) and old keys if they differ, just as - // traverseAllChildren used to do for objects as children - keyPrefix + (mappedChild.key && (!child || child.key !== mappedChild.key) ? escapeUserProvidedKey(mappedChild.key) + '/' : '') + childKey); - } - result.push(mappedChild); +assert.notDeepEqual = function notDeepEqual(actual, expected, message) { + if (_deepEqual(actual, expected, false)) { + fail(actual, expected, message, 'notDeepEqual', assert.notDeepEqual); } -} +}; -function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) { - var escapedPrefix = ''; - if (prefix != null) { - escapedPrefix = escapeUserProvidedKey(prefix) + '/'; +assert.notDeepStrictEqual = notDeepStrictEqual; +function notDeepStrictEqual(actual, expected, message) { + if (_deepEqual(actual, expected, true)) { + fail(actual, expected, message, 'notDeepStrictEqual', notDeepStrictEqual); } - var traverseContext = MapBookKeeping.getPooled(array, escapedPrefix, func, context); - traverseAllChildren(children, mapSingleChildIntoContext, traverseContext); - MapBookKeeping.release(traverseContext); } -/** - * Maps children that are typically specified as `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.map - * - * The provided mapFunction(child, key, index) will be called for each - * leaf child. - * - * @param {?*} children Children tree container. - * @param {function(*, int)} func The map function. - * @param {*} context Context for mapFunction. - * @return {object} Object containing the ordered map of results. - */ -function mapChildren(children, func, context) { - if (children == null) { - return children; + +// 9. The strict equality assertion tests strict equality, as determined by ===. +// assert.strictEqual(actual, expected, message_opt); + +assert.strictEqual = function strictEqual(actual, expected, message) { + if (actual !== expected) { + fail(actual, expected, message, '===', assert.strictEqual); } - var result = []; - mapIntoWithKeyPrefixInternal(children, result, null, func, context); - return result; -} +}; -function forEachSingleChildDummy(traverseContext, child, name) { - return null; -} +// 10. The strict non-equality assertion tests for strict inequality, as +// determined by !==. assert.notStrictEqual(actual, expected, message_opt); -/** - * Count the number of children that are typically specified as - * `props.children`. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.count - * - * @param {?*} children Children tree container. - * @return {number} The number of children. - */ -function countChildren(children, context) { - return traverseAllChildren(children, forEachSingleChildDummy, null); -} +assert.notStrictEqual = function notStrictEqual(actual, expected, message) { + if (actual === expected) { + fail(actual, expected, message, '!==', assert.notStrictEqual); + } +}; -/** - * Flatten a children object (typically specified as `props.children`) and - * return an array with appropriately re-keyed children. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.toarray - */ -function toArray(children) { - var result = []; - mapIntoWithKeyPrefixInternal(children, result, null, emptyFunction.thatReturnsArgument); - return result; -} - -var ReactChildren = { - forEach: forEachChildren, - map: mapChildren, - mapIntoWithKeyPrefixInternal: mapIntoWithKeyPrefixInternal, - count: countChildren, - toArray: toArray -}; +function expectedException(actual, expected) { + if (!actual || !expected) { + return false; + } -module.exports = ReactChildren; + if (Object.prototype.toString.call(expected) == '[object RegExp]') { + return expected.test(actual); + } -/***/ }), -/* 123 */ -/***/ (function(module, exports, __webpack_require__) { + try { + if (actual instanceof expected) { + return true; + } + } catch (e) { + // Ignore. The instanceof check doesn't work for arrow functions. + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + if (Error.isPrototypeOf(expected)) { + return false; + } + return expected.call({}, actual) === true; +} +function _tryBlock(block) { + var error; + try { + block(); + } catch (e) { + error = e; + } + return error; +} -var _prodInvariant = __webpack_require__(25); +function _throws(shouldThrow, block, expected, message) { + var actual; -var invariant = __webpack_require__(1); + if (typeof block !== 'function') { + throw new TypeError('"block" argument must be a function'); + } -/** - * Static poolers. Several custom versions for each potential number of - * arguments. A completely generic pooler is easy to implement, but would - * require accessing the `arguments` object. In each of these, `this` refers to - * the Class itself, not an instance. If any others are needed, simply add them - * here, or in their own files. - */ -var oneArgumentPooler = function (copyFieldsFrom) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, copyFieldsFrom); - return instance; - } else { - return new Klass(copyFieldsFrom); + if (typeof expected === 'string') { + message = expected; + expected = null; } -}; -var twoArgumentPooler = function (a1, a2) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2); - return instance; - } else { - return new Klass(a1, a2); + actual = _tryBlock(block); + + message = (expected && expected.name ? ' (' + expected.name + ').' : '.') + + (message ? ' ' + message : '.'); + + if (shouldThrow && !actual) { + fail(actual, expected, 'Missing expected exception' + message); } -}; -var threeArgumentPooler = function (a1, a2, a3) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3); - return instance; - } else { - return new Klass(a1, a2, a3); + var userProvidedMessage = typeof message === 'string'; + var isUnwantedException = !shouldThrow && util.isError(actual); + var isUnexpectedException = !shouldThrow && actual && !expected; + + if ((isUnwantedException && + userProvidedMessage && + expectedException(actual, expected)) || + isUnexpectedException) { + fail(actual, expected, 'Got unwanted exception' + message); } -}; -var fourArgumentPooler = function (a1, a2, a3, a4) { - var Klass = this; - if (Klass.instancePool.length) { - var instance = Klass.instancePool.pop(); - Klass.call(instance, a1, a2, a3, a4); - return instance; - } else { - return new Klass(a1, a2, a3, a4); + if ((shouldThrow && actual && expected && + !expectedException(actual, expected)) || (!shouldThrow && actual)) { + throw actual; } +} + +// 11. Expected to throw an error: +// assert.throws(block, Error_opt, message_opt); + +assert.throws = function(block, /*optional*/error, /*optional*/message) { + _throws(true, block, error, message); }; -var standardReleaser = function (instance) { - var Klass = this; - !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; - instance.destructor(); - if (Klass.instancePool.length < Klass.poolSize) { - Klass.instancePool.push(instance); - } +// EXTENSION! This is annoying to write outside this module. +assert.doesNotThrow = function(block, /*optional*/error, /*optional*/message) { + _throws(false, block, error, message); }; -var DEFAULT_POOL_SIZE = 10; -var DEFAULT_POOLER = oneArgumentPooler; +assert.ifError = function(err) { if (err) throw err; }; -/** - * Augments `CopyConstructor` to be a poolable class, augmenting only the class - * itself (statically) not adding any prototypical fields. Any CopyConstructor - * you give this may have a `poolSize` property, and will look for a - * prototypical `destructor` on instances. - * - * @param {Function} CopyConstructor Constructor that can be used to reset. - * @param {Function} pooler Customizable pooler. - */ -var addPoolingTo = function (CopyConstructor, pooler) { - // Casting as any so that flow ignores the actual implementation and trusts - // it to match the type we declared - var NewKlass = CopyConstructor; - NewKlass.instancePool = []; - NewKlass.getPooled = pooler || DEFAULT_POOLER; - if (!NewKlass.poolSize) { - NewKlass.poolSize = DEFAULT_POOL_SIZE; +var objectKeys = Object.keys || function (obj) { + var keys = []; + for (var key in obj) { + if (hasOwn.call(obj, key)) keys.push(key); } - NewKlass.release = standardReleaser; - return NewKlass; -}; - -var PooledClass = { - addPoolingTo: addPoolingTo, - oneArgumentPooler: oneArgumentPooler, - twoArgumentPooler: twoArgumentPooler, - threeArgumentPooler: threeArgumentPooler, - fourArgumentPooler: fourArgumentPooler + return keys; }; -module.exports = PooledClass; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) /***/ }), -/* 124 */ +/* 107 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var _prodInvariant = __webpack_require__(25); - -var ReactCurrentOwner = __webpack_require__(14); -var REACT_ELEMENT_TYPE = __webpack_require__(76); - -var getIteratorFn = __webpack_require__(77); -var invariant = __webpack_require__(1); -var KeyEscapeUtils = __webpack_require__(125); -var warning = __webpack_require__(2); - -var SEPARATOR = '.'; -var SUBSEPARATOR = ':'; - -/** - * This is inlined from ReactElement since this file is shared between - * isomorphic and renderers. We could extract this to a - * - */ - -/** - * TODO: Test that a single child and an array with one item have the same key - * pattern. +/* WEBPACK VAR INJECTION */(function(Buffer) {/* + * Obtained from https://github.com/bitcoinjs/bitcoinjs-lib/blob/master/src/crypto.js + * 2017/07/25: No ripemd160 in SJCL, so resorted to this */ -var didWarnAboutMaps = false; +var createHash = __webpack_require__(27); -/** - * Generate a key string that identifies a component within a set. - * - * @param {*} component A component that could contain a manual key. - * @param {number} index Index that is used if a manual key is not provided. - * @return {string} - */ -function getComponentKey(component, index) { - // Do some typechecking here since we call this blindly. We want to ensure - // that we don't block potential future ES APIs. - if (component && typeof component === 'object' && component.key != null) { - // Explicit key - return KeyEscapeUtils.escape(component.key); - } - // Implicit key determined by the index in the set - return index.toString(36); +function ripemd160(buffer) { + return createHash('rmd160').update(buffer).digest('hex'); } -/** - * @param {?*} children Children tree container. - * @param {!string} nameSoFar Name of the key path so far. - * @param {!function} callback Callback to invoke with each child found. - * @param {?*} traverseContext Used to pass information throughout the traversal - * process. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { - var type = typeof children; - - if (type === 'undefined' || type === 'boolean') { - // All of the above are perceived as null. - children = null; - } - - if (children === null || type === 'string' || type === 'number' || - // The following is inlined from ReactElement. This means we can optimize - // some checks. React Fiber also inlines this logic for similar purposes. - type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { - callback(traverseContext, children, - // If it's the only child, treat the name as if it was wrapped in an array - // so that it's consistent if the number of children grows. - nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); - return 1; - } +function sha1(buffer) { + return createHash('sha1').update(buffer).digest('hex'); +} - var child; - var nextName; - var subtreeCount = 0; // Count of children found in the current subtree. - var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; +function sha256(buffer) { + return createHash('sha256').update(buffer).digest('hex'); +} - if (Array.isArray(children)) { - for (var i = 0; i < children.length; i++) { - child = children[i]; - nextName = nextNamePrefix + getComponentKey(child, i); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - var iteratorFn = getIteratorFn(children); - if (iteratorFn) { - var iterator = iteratorFn.call(children); - var step; - if (iteratorFn !== children.entries) { - var ii = 0; - while (!(step = iterator.next()).done) { - child = step.value; - nextName = nextNamePrefix + getComponentKey(child, ii++); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } else { - if (process.env.NODE_ENV !== 'production') { - var mapsAsChildrenAddendum = ''; - if (ReactCurrentOwner.current) { - var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); - if (mapsAsChildrenOwnerName) { - mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; - } - } - process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; - didWarnAboutMaps = true; - } - // Iterator will provide entry [k,v] tuples rather than values. - while (!(step = iterator.next()).done) { - var entry = step.value; - if (entry) { - child = entry[1]; - nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); - subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); - } - } - } - } else if (type === 'object') { - var addendum = ''; - if (process.env.NODE_ENV !== 'production') { - addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; - if (children._isReactElement) { - addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; - } - if (ReactCurrentOwner.current) { - var name = ReactCurrentOwner.current.getName(); - if (name) { - addendum += ' Check the render method of `' + name + '`.'; - } - } - } - var childrenString = String(children); - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; - } - } +function sha256x2(buffer) { + return sha256(Buffer.from(sha256(buffer), 'hex')); +} - return subtreeCount; +function hash160(buffer) { + const sha = sha256(buffer); + const hash160 = ripemd160(Buffer.from(sha, 'hex')); + return hash160; } -/** - * Traverses children that are typically specified as `props.children`, but - * might also be specified through attributes: - * - * - `traverseAllChildren(this.props.children, ...)` - * - `traverseAllChildren(this.props.leftPanelChildren, ...)` - * - * The `traverseContext` is an optional argument that is passed through the - * entire traversal. It can be used to store accumulations or anything else that - * the callback might find relevant. - * - * @param {?*} children Children tree object. - * @param {!function} callback To invoke upon traversing each child. - * @param {?*} traverseContext Context for traversal. - * @return {!number} The number of children in this subtree. - */ -function traverseAllChildren(children, callback, traverseContext) { - if (children == null) { - return 0; - } +module.exports = { + hash160: hash160, + ripemd160: ripemd160, + sha1: sha1, + sha256: sha256, + sha256x2: sha256x2 +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - return traverseAllChildrenImpl(children, '', callback, traverseContext); +/***/ }), +/* 108 */ +/***/ (function(module, exports, __webpack_require__) { + +var ciphers = __webpack_require__(424) +exports.createCipher = exports.Cipher = ciphers.createCipher +exports.createCipheriv = exports.Cipheriv = ciphers.createCipheriv +var deciphers = __webpack_require__(426) +exports.createDecipher = exports.Decipher = deciphers.createDecipher +exports.createDecipheriv = exports.Decipheriv = deciphers.createDecipheriv +var modes = __webpack_require__(70) +function getCiphers () { + return Object.keys(modes) } +exports.listCiphers = exports.getCiphers = getCiphers -module.exports = traverseAllChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 125 */ +/* 109 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +exports.utils = __webpack_require__(428); +exports.Cipher = __webpack_require__(429); +exports.DES = __webpack_require__(430); +exports.CBC = __webpack_require__(431); +exports.EDE = __webpack_require__(432); -/** - * Escape and wrap key so it is safe to use as a reactid - * - * @param {string} key to be escaped. - * @return {string} the escaped key. - */ -function escape(key) { - var escapeRegex = /[=:]/g; - var escaperLookup = { - '=': '=0', - ':': '=2' +/***/ }), +/* 110 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var bn = __webpack_require__(11); +var randomBytes = __webpack_require__(43); +module.exports = crt; +function blind(priv) { + var r = getr(priv); + var blinder = r.toRed(bn.mont(priv.modulus)) + .redPow(new bn(priv.publicExponent)).fromRed(); + return { + blinder: blinder, + unblinder:r.invm(priv.modulus) }; - var escapedString = ('' + key).replace(escapeRegex, function (match) { - return escaperLookup[match]; - }); +} +function crt(msg, priv) { + var blinds = blind(priv); + var len = priv.modulus.byteLength(); + var mod = bn.mont(priv.modulus); + var blinded = new bn(msg).mul(blinds.blinder).umod(priv.modulus); + var c1 = blinded.toRed(bn.mont(priv.prime1)); + var c2 = blinded.toRed(bn.mont(priv.prime2)); + var qinv = priv.coefficient; + var p = priv.prime1; + var q = priv.prime2; + var m1 = c1.redPow(priv.exponent1); + var m2 = c2.redPow(priv.exponent2); + m1 = m1.fromRed(); + m2 = m2.fromRed(); + var h = m1.isub(m2).imul(qinv).umod(p); + h.imul(q); + m2.iadd(h); + return new Buffer(m2.imul(blinds.unblinder).umod(priv.modulus).toArray(false, len)); +} +crt.getr = getr; +function getr(priv) { + var len = priv.modulus.byteLength(); + var r = new bn(randomBytes(len)); + while (r.cmp(priv.modulus) >= 0 || !r.umod(priv.prime1) || !r.umod(priv.prime2)) { + r = new bn(randomBytes(len)); + } + return r; +} - return '$' + escapedString; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 111 */ +/***/ (function(module, exports) { + +var types = { + Array: function (value) { return value !== null && value !== undefined && value.constructor === Array }, + Boolean: function (value) { return typeof value === 'boolean' }, + Function: function (value) { return typeof value === 'function' }, + Nil: function (value) { return value === undefined || value === null }, + Number: function (value) { return typeof value === 'number' }, + Object: function (value) { return typeof value === 'object' }, + String: function (value) { return typeof value === 'string' }, + '': function () { return true } } -/** - * Unescape and unwrap key for human-readable display - * - * @param {string} key to unescape. - * @return {string} the unescaped key. - */ -function unescape(key) { - var unescapeRegex = /(=0|=2)/g; - var unescaperLookup = { - '=0': '=', - '=2': ':' - }; - var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); +// TODO: deprecate +types.Null = types.Nil - return ('' + keySubstring).replace(unescapeRegex, function (match) { - return unescaperLookup[match]; - }); +for (var typeName in types) { + types[typeName].toJSON = function (t) { + return t + }.bind(null, typeName) } -var KeyEscapeUtils = { - escape: escape, - unescape: unescape -}; +module.exports = types -module.exports = KeyEscapeUtils; /***/ }), -/* 126 */ +/* 112 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Buffer = __webpack_require__(7).Buffer +var bcrypto = __webpack_require__(44) +var bscript = __webpack_require__(14) +var bufferutils = __webpack_require__(206) +var opcodes = __webpack_require__(16) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var varuint = __webpack_require__(73) +function varSliceSize (someScript) { + var length = someScript.length + return varuint.encodingLength(length) + length +} -var ReactElement = __webpack_require__(19); +function vectorSize (someVector) { + var length = someVector.length -/** - * Create a factory that creates HTML tag elements. - * - * @private - */ -var createDOMFactory = ReactElement.createFactory; -if (process.env.NODE_ENV !== 'production') { - var ReactElementValidator = __webpack_require__(78); - createDOMFactory = ReactElementValidator.createFactory; + return varuint.encodingLength(length) + someVector.reduce(function (sum, witness) { + return sum + varSliceSize(witness) + }, 0) } -/** - * Creates a mapping from supported HTML tags to `ReactDOMComponent` classes. - * - * @public - */ -var ReactDOMFactories = { - a: createDOMFactory('a'), - abbr: createDOMFactory('abbr'), - address: createDOMFactory('address'), - area: createDOMFactory('area'), - article: createDOMFactory('article'), - aside: createDOMFactory('aside'), - audio: createDOMFactory('audio'), - b: createDOMFactory('b'), - base: createDOMFactory('base'), - bdi: createDOMFactory('bdi'), - bdo: createDOMFactory('bdo'), - big: createDOMFactory('big'), - blockquote: createDOMFactory('blockquote'), - body: createDOMFactory('body'), - br: createDOMFactory('br'), - button: createDOMFactory('button'), - canvas: createDOMFactory('canvas'), - caption: createDOMFactory('caption'), - cite: createDOMFactory('cite'), - code: createDOMFactory('code'), - col: createDOMFactory('col'), - colgroup: createDOMFactory('colgroup'), - data: createDOMFactory('data'), - datalist: createDOMFactory('datalist'), - dd: createDOMFactory('dd'), - del: createDOMFactory('del'), - details: createDOMFactory('details'), - dfn: createDOMFactory('dfn'), - dialog: createDOMFactory('dialog'), - div: createDOMFactory('div'), - dl: createDOMFactory('dl'), - dt: createDOMFactory('dt'), - em: createDOMFactory('em'), - embed: createDOMFactory('embed'), - fieldset: createDOMFactory('fieldset'), - figcaption: createDOMFactory('figcaption'), - figure: createDOMFactory('figure'), - footer: createDOMFactory('footer'), - form: createDOMFactory('form'), - h1: createDOMFactory('h1'), - h2: createDOMFactory('h2'), - h3: createDOMFactory('h3'), - h4: createDOMFactory('h4'), - h5: createDOMFactory('h5'), - h6: createDOMFactory('h6'), - head: createDOMFactory('head'), - header: createDOMFactory('header'), - hgroup: createDOMFactory('hgroup'), - hr: createDOMFactory('hr'), - html: createDOMFactory('html'), - i: createDOMFactory('i'), - iframe: createDOMFactory('iframe'), - img: createDOMFactory('img'), - input: createDOMFactory('input'), - ins: createDOMFactory('ins'), - kbd: createDOMFactory('kbd'), - keygen: createDOMFactory('keygen'), - label: createDOMFactory('label'), - legend: createDOMFactory('legend'), - li: createDOMFactory('li'), - link: createDOMFactory('link'), - main: createDOMFactory('main'), - map: createDOMFactory('map'), - mark: createDOMFactory('mark'), - menu: createDOMFactory('menu'), - menuitem: createDOMFactory('menuitem'), - meta: createDOMFactory('meta'), - meter: createDOMFactory('meter'), - nav: createDOMFactory('nav'), - noscript: createDOMFactory('noscript'), - object: createDOMFactory('object'), - ol: createDOMFactory('ol'), - optgroup: createDOMFactory('optgroup'), - option: createDOMFactory('option'), - output: createDOMFactory('output'), - p: createDOMFactory('p'), - param: createDOMFactory('param'), - picture: createDOMFactory('picture'), - pre: createDOMFactory('pre'), - progress: createDOMFactory('progress'), - q: createDOMFactory('q'), - rp: createDOMFactory('rp'), - rt: createDOMFactory('rt'), - ruby: createDOMFactory('ruby'), - s: createDOMFactory('s'), - samp: createDOMFactory('samp'), - script: createDOMFactory('script'), - section: createDOMFactory('section'), - select: createDOMFactory('select'), - small: createDOMFactory('small'), - source: createDOMFactory('source'), - span: createDOMFactory('span'), - strong: createDOMFactory('strong'), - style: createDOMFactory('style'), - sub: createDOMFactory('sub'), - summary: createDOMFactory('summary'), - sup: createDOMFactory('sup'), - table: createDOMFactory('table'), - tbody: createDOMFactory('tbody'), - td: createDOMFactory('td'), - textarea: createDOMFactory('textarea'), - tfoot: createDOMFactory('tfoot'), - th: createDOMFactory('th'), - thead: createDOMFactory('thead'), - time: createDOMFactory('time'), - title: createDOMFactory('title'), - tr: createDOMFactory('tr'), - track: createDOMFactory('track'), - u: createDOMFactory('u'), - ul: createDOMFactory('ul'), - 'var': createDOMFactory('var'), - video: createDOMFactory('video'), - wbr: createDOMFactory('wbr'), - - // SVG - circle: createDOMFactory('circle'), - clipPath: createDOMFactory('clipPath'), - defs: createDOMFactory('defs'), - ellipse: createDOMFactory('ellipse'), - g: createDOMFactory('g'), - image: createDOMFactory('image'), - line: createDOMFactory('line'), - linearGradient: createDOMFactory('linearGradient'), - mask: createDOMFactory('mask'), - path: createDOMFactory('path'), - pattern: createDOMFactory('pattern'), - polygon: createDOMFactory('polygon'), - polyline: createDOMFactory('polyline'), - radialGradient: createDOMFactory('radialGradient'), - rect: createDOMFactory('rect'), - stop: createDOMFactory('stop'), - svg: createDOMFactory('svg'), - text: createDOMFactory('text'), - tspan: createDOMFactory('tspan') -}; +function Transaction () { + this.version = 1 + this.locktime = 0 + this.ins = [] + this.outs = [] +} -module.exports = ReactDOMFactories; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Transaction.DEFAULT_SEQUENCE = 0xffffffff +Transaction.SIGHASH_ALL = 0x01 +Transaction.SIGHASH_NONE = 0x02 +Transaction.SIGHASH_SINGLE = 0x03 +Transaction.SIGHASH_ANYONECANPAY = 0x80 +Transaction.ADVANCED_TRANSACTION_MARKER = 0x00 +Transaction.ADVANCED_TRANSACTION_FLAG = 0x01 -/***/ }), -/* 127 */ -/***/ (function(module, exports, __webpack_require__) { +var EMPTY_SCRIPT = Buffer.allocUnsafe(0) +var EMPTY_WITNESS = [] +var ZERO = Buffer.from('0000000000000000000000000000000000000000000000000000000000000000', 'hex') +var ONE = Buffer.from('0000000000000000000000000000000000000000000000000000000000000001', 'hex') +var VALUE_UINT64_MAX = Buffer.from('ffffffffffffffff', 'hex') +var BLANK_OUTPUT = { + script: EMPTY_SCRIPT, + valueBuffer: VALUE_UINT64_MAX +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Transaction.fromBuffer = function (buffer, __noStrict) { + var offset = 0 + function readSlice (n) { + offset += n + return buffer.slice(offset - n, offset) + } + function readUInt32 () { + var i = buffer.readUInt32LE(offset) + offset += 4 + return i + } + function readInt32 () { + var i = buffer.readInt32LE(offset) + offset += 4 + return i + } -var _prodInvariant = __webpack_require__(25); + function readUInt64 () { + var i = bufferutils.readUInt64LE(buffer, offset) + offset += 8 + return i + } -var ReactPropTypeLocationNames = __webpack_require__(128); -var ReactPropTypesSecret = __webpack_require__(129); + function readVarInt () { + var vi = varuint.decode(buffer, offset) + offset += varuint.decode.bytes + return vi + } -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); + function readVarSlice () { + return readSlice(readVarInt()) + } -var ReactComponentTreeHook; + function readVector () { + var count = readVarInt() + var vector = [] + for (var i = 0; i < count; i++) vector.push(readVarSlice()) + return vector + } -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} + var tx = new Transaction() + tx.version = readInt32() -var loggedTypeFailures = {}; + var marker = buffer.readUInt8(offset) + var flag = buffer.readUInt8(offset + 1) -/** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. - * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?object} element The React element that is being type-checked - * @param {?number} debugID The React component instance that is being type-checked - * @private - */ -function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; + var hasWitnesses = false + if (marker === Transaction.ADVANCED_TRANSACTION_MARKER && + flag === Transaction.ADVANCED_TRANSACTION_FLAG) { + offset += 2 + hasWitnesses = true + } - var componentStackInfo = ''; + var vinLen = readVarInt() + for (var i = 0; i < vinLen; ++i) { + tx.ins.push({ + hash: readSlice(32), + index: readUInt32(), + script: readVarSlice(), + sequence: readUInt32(), + witness: EMPTY_WITNESS + }) + } - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (debugID !== null) { - componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); - } else if (element !== null) { - componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); - } - } + var voutLen = readVarInt() + for (i = 0; i < voutLen; ++i) { + tx.outs.push({ + value: readUInt64(), + script: readVarSlice() + }) + } - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; - } + if (hasWitnesses) { + for (i = 0; i < vinLen; ++i) { + tx.ins[i].witness = readVector() } + + // was this pointless? + if (!tx.hasWitnesses()) throw new Error('Transaction has superfluous witness data') } + + tx.locktime = readUInt32() + + if (__noStrict) return tx + if (offset !== buffer.length) throw new Error('Transaction has unexpected data') + + return tx } -module.exports = checkReactTypeSpec; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Transaction.fromHex = function (hex) { + return Transaction.fromBuffer(Buffer.from(hex, 'hex')) +} -/***/ }), -/* 128 */ -/***/ (function(module, exports, __webpack_require__) { +Transaction.isCoinbaseHash = function (buffer) { + typeforce(types.Hash256bit, buffer) + for (var i = 0; i < 32; ++i) { + if (buffer[i] !== 0) return false + } + return true +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Transaction.prototype.isCoinbase = function () { + return this.ins.length === 1 && Transaction.isCoinbaseHash(this.ins[0].hash) +} + +Transaction.prototype.addInput = function (hash, index, sequence, scriptSig) { + typeforce(types.tuple( + types.Hash256bit, + types.UInt32, + types.maybe(types.UInt32), + types.maybe(types.Buffer) + ), arguments) + if (types.Null(sequence)) { + sequence = Transaction.DEFAULT_SEQUENCE + } + // Add the input and return the input's index + return (this.ins.push({ + hash: hash, + index: index, + script: scriptSig || EMPTY_SCRIPT, + sequence: sequence, + witness: EMPTY_WITNESS + }) - 1) +} -var ReactPropTypeLocationNames = {}; +Transaction.prototype.addOutput = function (scriptPubKey, value) { + typeforce(types.tuple(types.Buffer, types.Satoshi), arguments) -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' - }; + // Add the output and return the output's index + return (this.outs.push({ + script: scriptPubKey, + value: value + }) - 1) } -module.exports = ReactPropTypeLocationNames; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Transaction.prototype.hasWitnesses = function () { + return this.ins.some(function (x) { + return x.witness.length !== 0 + }) +} -/***/ }), -/* 129 */ -/***/ (function(module, exports, __webpack_require__) { +Transaction.prototype.weight = function () { + var base = this.__byteLength(false) + var total = this.__byteLength(true) + return base * 3 + total +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Transaction.prototype.virtualSize = function () { + return Math.ceil(this.weight() / 4) +} +Transaction.prototype.byteLength = function () { + return this.__byteLength(true) +} +Transaction.prototype.__byteLength = function (__allowWitness) { + var hasWitnesses = __allowWitness && this.hasWitnesses() -var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; + return ( + (hasWitnesses ? 10 : 8) + + varuint.encodingLength(this.ins.length) + + varuint.encodingLength(this.outs.length) + + this.ins.reduce(function (sum, input) { return sum + 40 + varSliceSize(input.script) }, 0) + + this.outs.reduce(function (sum, output) { return sum + 8 + varSliceSize(output.script) }, 0) + + (hasWitnesses ? this.ins.reduce(function (sum, input) { return sum + vectorSize(input.witness) }, 0) : 0) + ) +} -module.exports = ReactPropTypesSecret; +Transaction.prototype.clone = function () { + var newTx = new Transaction() + newTx.version = this.version + newTx.locktime = this.locktime -/***/ }), -/* 130 */ -/***/ (function(module, exports, __webpack_require__) { + newTx.ins = this.ins.map(function (txIn) { + return { + hash: txIn.hash, + index: txIn.index, + script: txIn.script, + sequence: txIn.sequence, + witness: txIn.witness + } + }) + + newTx.outs = this.outs.map(function (txOut) { + return { + script: txOut.script, + value: txOut.value + } + }) + + return newTx +} -"use strict"; /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Hash transaction for signing a specific input. * + * Bitcoin uses a different hash for each signed transaction input. + * This method copies the transaction, makes the necessary changes based on the + * hashType, and then hashes the result. + * This hash can then be used to sign the provided transaction input. */ +Transaction.prototype.hashForSignature = function (inIndex, prevOutScript, hashType) { + typeforce(types.tuple(types.UInt32, types.Buffer, /* types.UInt8 */ types.Number), arguments) + // https://github.com/bitcoin/bitcoin/blob/master/src/test/sighash_tests.cpp#L29 + if (inIndex >= this.ins.length) return ONE + // ignore OP_CODESEPARATOR + var ourScript = bscript.compile(bscript.decompile(prevOutScript).filter(function (x) { + return x !== opcodes.OP_CODESEPARATOR + })) -var _require = __webpack_require__(19), - isValidElement = _require.isValidElement; + var txTmp = this.clone() -var factory = __webpack_require__(79); + // SIGHASH_NONE: ignore all outputs? (wildcard payee) + if ((hashType & 0x1f) === Transaction.SIGHASH_NONE) { + txTmp.outs = [] -module.exports = factory(isValidElement); + // ignore sequence numbers (except at inIndex) + txTmp.ins.forEach(function (input, i) { + if (i === inIndex) return -/***/ }), -/* 131 */ -/***/ (function(module, exports, __webpack_require__) { + input.sequence = 0 + }) -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ + // SIGHASH_SINGLE: ignore all outputs, except at the same index? + } else if ((hashType & 0x1f) === Transaction.SIGHASH_SINGLE) { + // https://github.com/bitcoin/bitcoin/blob/master/src/test/sighash_tests.cpp#L60 + if (inIndex >= this.outs.length) return ONE + // truncate outputs after + txTmp.outs.length = inIndex + 1 + // "blank" outputs before + for (var i = 0; i < inIndex; i++) { + txTmp.outs[i] = BLANK_OUTPUT + } -if (process.env.NODE_ENV !== 'production') { - var invariant = __webpack_require__(1); - var warning = __webpack_require__(2); - var ReactPropTypesSecret = __webpack_require__(49); - var loggedTypeFailures = {}; -} + // ignore sequence numbers (except at inIndex) + txTmp.ins.forEach(function (input, y) { + if (y === inIndex) return -/** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. - * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?Function} getStack Returns the component stack. - * @private - */ -function checkPropTypes(typeSpecs, values, location, componentName, getStack) { - if (process.env.NODE_ENV !== 'production') { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - invariant(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', componentName || 'React class', location, typeSpecName); - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error); - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; + input.sequence = 0 + }) + } - var stack = getStack ? getStack() : ''; + // SIGHASH_ANYONECANPAY: ignore inputs entirely? + if (hashType & Transaction.SIGHASH_ANYONECANPAY) { + txTmp.ins = [txTmp.ins[inIndex]] + txTmp.ins[0].script = ourScript - warning(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : ''); - } - } - } + // SIGHASH_ALL: only ignore input scripts + } else { + // "blank" others input scripts + txTmp.ins.forEach(function (input) { input.script = EMPTY_SCRIPT }) + txTmp.ins[inIndex].script = ourScript } -} -module.exports = checkPropTypes; + // serialize and hash + var buffer = Buffer.allocUnsafe(txTmp.__byteLength(false) + 4) + buffer.writeInt32LE(hashType, buffer.length - 4) + txTmp.__toBuffer(buffer, 0, false) -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return bcrypto.hash256(buffer) +} -/***/ }), -/* 132 */ -/***/ (function(module, exports, __webpack_require__) { +Transaction.prototype.hashForWitnessV0 = function (inIndex, prevOutScript, value, hashType) { + typeforce(types.tuple(types.UInt32, types.Buffer, types.Satoshi, types.UInt32), arguments) -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var tbuffer, toffset + function writeSlice (slice) { toffset += slice.copy(tbuffer, toffset) } + function writeUInt32 (i) { toffset = tbuffer.writeUInt32LE(i, toffset) } + function writeUInt64 (i) { toffset = bufferutils.writeUInt64LE(tbuffer, i, toffset) } + function writeVarInt (i) { + varuint.encode(i, tbuffer, toffset) + toffset += varuint.encode.bytes + } + function writeVarSlice (slice) { writeVarInt(slice.length); writeSlice(slice) } + var hashOutputs = ZERO + var hashPrevouts = ZERO + var hashSequence = ZERO + if (!(hashType & Transaction.SIGHASH_ANYONECANPAY)) { + tbuffer = Buffer.allocUnsafe(36 * this.ins.length) + toffset = 0 -module.exports = '15.6.1'; + this.ins.forEach(function (txIn) { + writeSlice(txIn.hash) + writeUInt32(txIn.index) + }) -/***/ }), -/* 133 */ -/***/ (function(module, exports, __webpack_require__) { + hashPrevouts = bcrypto.hash256(tbuffer) + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + if (!(hashType & Transaction.SIGHASH_ANYONECANPAY) && + (hashType & 0x1f) !== Transaction.SIGHASH_SINGLE && + (hashType & 0x1f) !== Transaction.SIGHASH_NONE) { + tbuffer = Buffer.allocUnsafe(4 * this.ins.length) + toffset = 0 + this.ins.forEach(function (txIn) { + writeUInt32(txIn.sequence) + }) + hashSequence = bcrypto.hash256(tbuffer) + } -var _require = __webpack_require__(74), - Component = _require.Component; + if ((hashType & 0x1f) !== Transaction.SIGHASH_SINGLE && + (hashType & 0x1f) !== Transaction.SIGHASH_NONE) { + var txOutsSize = this.outs.reduce(function (sum, output) { + return sum + 8 + varSliceSize(output.script) + }, 0) -var _require2 = __webpack_require__(19), - isValidElement = _require2.isValidElement; + tbuffer = Buffer.allocUnsafe(txOutsSize) + toffset = 0 -var ReactNoopUpdateQueue = __webpack_require__(75); -var factory = __webpack_require__(113); + this.outs.forEach(function (out) { + writeUInt64(out.value) + writeVarSlice(out.script) + }) -module.exports = factory(Component, isValidElement, ReactNoopUpdateQueue); + hashOutputs = bcrypto.hash256(tbuffer) + } else if ((hashType & 0x1f) === Transaction.SIGHASH_SINGLE && inIndex < this.outs.length) { + var output = this.outs[inIndex] -/***/ }), -/* 134 */ -/***/ (function(module, exports, __webpack_require__) { + tbuffer = Buffer.allocUnsafe(8 + varSliceSize(output.script)) + toffset = 0 + writeUInt64(output.value) + writeVarSlice(output.script) -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + hashOutputs = bcrypto.hash256(tbuffer) + } + tbuffer = Buffer.allocUnsafe(156 + varSliceSize(prevOutScript)) + toffset = 0 -var _prodInvariant = __webpack_require__(25); + var input = this.ins[inIndex] + writeUInt32(this.version) + writeSlice(hashPrevouts) + writeSlice(hashSequence) + writeSlice(input.hash) + writeUInt32(input.index) + writeVarSlice(prevOutScript) + writeUInt64(value) + writeUInt32(input.sequence) + writeSlice(hashOutputs) + writeUInt32(this.locktime) + writeUInt32(hashType) + return bcrypto.hash256(tbuffer) +} -var ReactElement = __webpack_require__(19); +Transaction.prototype.getHash = function () { + return bcrypto.hash256(this.__toBuffer(undefined, undefined, false)) +} -var invariant = __webpack_require__(1); +Transaction.prototype.getId = function () { + // transaction hash's are displayed in reverse order + return this.getHash().reverse().toString('hex') +} -/** - * Returns the first child in a collection of children and verifies that there - * is only one child in the collection. - * - * See https://facebook.github.io/react/docs/top-level-api.html#react.children.only - * - * The current implementation of this function assumes that a single child gets - * passed without a wrapper, but the purpose of this helper function is to - * abstract away the particular structure of children. - * - * @param {?object} children Child collection structure. - * @return {ReactElement} The first and only `ReactElement` contained in the - * structure. - */ -function onlyChild(children) { - !ReactElement.isValidElement(children) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React.Children.only expected to receive a single React element child.') : _prodInvariant('143') : void 0; - return children; +Transaction.prototype.toBuffer = function (buffer, initialOffset) { + return this.__toBuffer(buffer, initialOffset, true) } -module.exports = onlyChild; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Transaction.prototype.__toBuffer = function (buffer, initialOffset, __allowWitness) { + if (!buffer) buffer = Buffer.allocUnsafe(this.__byteLength(__allowWitness)) -/***/ }), -/* 135 */ -/***/ (function(module, exports, __webpack_require__) { + var offset = initialOffset || 0 + function writeSlice (slice) { offset += slice.copy(buffer, offset) } + function writeUInt8 (i) { offset = buffer.writeUInt8(i, offset) } + function writeUInt32 (i) { offset = buffer.writeUInt32LE(i, offset) } + function writeInt32 (i) { offset = buffer.writeInt32LE(i, offset) } + function writeUInt64 (i) { offset = bufferutils.writeUInt64LE(buffer, i, offset) } + function writeVarInt (i) { + varuint.encode(i, buffer, offset) + offset += varuint.encode.bytes + } + function writeVarSlice (slice) { writeVarInt(slice.length); writeSlice(slice) } + function writeVector (vector) { writeVarInt(vector.length); vector.forEach(writeVarSlice) } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + writeInt32(this.version) -/* globals __REACT_DEVTOOLS_GLOBAL_HOOK__*/ + var hasWitnesses = __allowWitness && this.hasWitnesses() + if (hasWitnesses) { + writeUInt8(Transaction.ADVANCED_TRANSACTION_MARKER) + writeUInt8(Transaction.ADVANCED_TRANSACTION_FLAG) + } + writeVarInt(this.ins.length) -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDefaultInjection = __webpack_require__(136); -var ReactMount = __webpack_require__(104); -var ReactReconciler = __webpack_require__(26); -var ReactUpdates = __webpack_require__(15); -var ReactVersion = __webpack_require__(214); + this.ins.forEach(function (txIn) { + writeSlice(txIn.hash) + writeUInt32(txIn.index) + writeVarSlice(txIn.script) + writeUInt32(txIn.sequence) + }) -var findDOMNode = __webpack_require__(215); -var getHostComponentFromComposite = __webpack_require__(105); -var renderSubtreeIntoContainer = __webpack_require__(216); -var warning = __webpack_require__(2); + writeVarInt(this.outs.length) + this.outs.forEach(function (txOut) { + if (!txOut.valueBuffer) { + writeUInt64(txOut.value) + } else { + writeSlice(txOut.valueBuffer) + } -ReactDefaultInjection.inject(); + writeVarSlice(txOut.script) + }) -var ReactDOM = { - findDOMNode: findDOMNode, - render: ReactMount.render, - unmountComponentAtNode: ReactMount.unmountComponentAtNode, - version: ReactVersion, + if (hasWitnesses) { + this.ins.forEach(function (input) { + writeVector(input.witness) + }) + } - /* eslint-disable camelcase */ - unstable_batchedUpdates: ReactUpdates.batchedUpdates, - unstable_renderSubtreeIntoContainer: renderSubtreeIntoContainer - /* eslint-enable camelcase */ -}; + writeUInt32(this.locktime) -// Inject the runtime into a devtools global hook regardless of browser. -// Allows for debugging when the hook is injected on the page. -if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject === 'function') { - __REACT_DEVTOOLS_GLOBAL_HOOK__.inject({ - ComponentTree: { - getClosestInstanceFromNode: ReactDOMComponentTree.getClosestInstanceFromNode, - getNodeFromInstance: function (inst) { - // inst is an internal instance (but could be a composite) - if (inst._renderedComponent) { - inst = getHostComponentFromComposite(inst); - } - if (inst) { - return ReactDOMComponentTree.getNodeFromInstance(inst); - } else { - return null; - } - } - }, - Mount: ReactMount, - Reconciler: ReactReconciler - }); + // avoid slicing unless necessary + if (initialOffset !== undefined) return buffer.slice(initialOffset, offset) + return buffer } -if (process.env.NODE_ENV !== 'production') { - var ExecutionEnvironment = __webpack_require__(8); - if (ExecutionEnvironment.canUseDOM && window.top === window.self) { - // First check if devtools is not installed - if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined') { - // If we're in Chrome or Firefox, provide a download link if not installed. - if (navigator.userAgent.indexOf('Chrome') > -1 && navigator.userAgent.indexOf('Edge') === -1 || navigator.userAgent.indexOf('Firefox') > -1) { - // Firefox does not have the issue with devtools loaded over file:// - var showFileUrlMessage = window.location.protocol.indexOf('http') === -1 && navigator.userAgent.indexOf('Firefox') === -1; - console.debug('Download the React DevTools ' + (showFileUrlMessage ? 'and use an HTTP server (instead of a file: URL) ' : '') + 'for a better development experience: ' + 'https://fb.me/react-devtools'); - } - } +Transaction.prototype.toHex = function () { + return this.toBuffer().toString('hex') +} - var testFunc = function testFn() {}; - process.env.NODE_ENV !== 'production' ? warning((testFunc.name || testFunc.toString()).indexOf('testFn') !== -1, "It looks like you're using a minified copy of the development build " + 'of React. When deploying React apps to production, make sure to use ' + 'the production build which skips development warnings and is faster. ' + 'See https://fb.me/react-minification for more details.') : void 0; +Transaction.prototype.setInputScript = function (index, scriptSig) { + typeforce(types.tuple(types.Number, types.Buffer), arguments) - // If we're in IE8, check to see if we are in compatibility mode and provide - // information on preventing compatibility mode - var ieCompatibilityMode = document.documentMode && document.documentMode < 8; + this.ins[index].script = scriptSig +} - process.env.NODE_ENV !== 'production' ? warning(!ieCompatibilityMode, 'Internet Explorer is running in compatibility mode; please add the ' + 'following tag to your HTML to prevent this from happening: ' + '<meta http-equiv="X-UA-Compatible" content="IE=edge" />') : void 0; +Transaction.prototype.setWitness = function (index, witness) { + typeforce(types.tuple(types.Number, [types.Buffer]), arguments) - var expectedFeatures = [ - // shims - Array.isArray, Array.prototype.every, Array.prototype.forEach, Array.prototype.indexOf, Array.prototype.map, Date.now, Function.prototype.bind, Object.keys, String.prototype.trim]; + this.ins[index].witness = witness +} - for (var i = 0; i < expectedFeatures.length; i++) { - if (!expectedFeatures[i]) { - process.env.NODE_ENV !== 'production' ? warning(false, 'One or more ES5 shims expected by React are not available: ' + 'https://fb.me/react-warning-polyfills') : void 0; - break; - } - } +module.exports = Transaction + + +/***/ }), +/* 113 */ +/***/ (function(module, exports, __webpack_require__) { + +var baddress = __webpack_require__(114) +var bcrypto = __webpack_require__(44) +var ecdsa = __webpack_require__(489) +var randomBytes = __webpack_require__(43) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var wif = __webpack_require__(492) + +var NETWORKS = __webpack_require__(54) +var BigInteger = __webpack_require__(30) + +var ecurve = __webpack_require__(116) +var secp256k1 = ecdsa.__curve + +function ECPair (d, Q, options) { + if (options) { + typeforce({ + compressed: types.maybe(types.Boolean), + network: types.maybe(types.Network) + }, options) } -} -if (process.env.NODE_ENV !== 'production') { - var ReactInstrumentation = __webpack_require__(13); - var ReactDOMUnknownPropertyHook = __webpack_require__(217); - var ReactDOMNullInputValuePropHook = __webpack_require__(218); - var ReactDOMInvalidARIAHook = __webpack_require__(219); + options = options || {} - ReactInstrumentation.debugTool.addHook(ReactDOMUnknownPropertyHook); - ReactInstrumentation.debugTool.addHook(ReactDOMNullInputValuePropHook); - ReactInstrumentation.debugTool.addHook(ReactDOMInvalidARIAHook); + if (d) { + if (d.signum() <= 0) throw new Error('Private key must be greater than 0') + if (d.compareTo(secp256k1.n) >= 0) throw new Error('Private key must be less than the curve order') + if (Q) throw new TypeError('Unexpected publicKey parameter') + + this.d = d + } else { + typeforce(types.ECPoint, Q) + + this.__Q = Q + } + + this.compressed = options.compressed === undefined ? true : options.compressed + this.network = options.network || NETWORKS.bitcoin } -module.exports = ReactDOM; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Object.defineProperty(ECPair.prototype, 'Q', { + get: function () { + if (!this.__Q && this.d) { + this.__Q = secp256k1.G.multiply(this.d) + } -/***/ }), -/* 136 */ -/***/ (function(module, exports, __webpack_require__) { + return this.__Q + } +}) -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +ECPair.fromPublicKeyBuffer = function (buffer, network) { + var Q = ecurve.Point.decodeFrom(secp256k1, buffer) + + return new ECPair(null, Q, { + compressed: Q.compressed, + network: network + }) +} +ECPair.fromWIF = function (string, network) { + var decoded = wif.decode(string) + var version = decoded.version + // list of networks? + if (types.Array(network)) { + network = network.filter(function (x) { + return version === x.wif + }).pop() -var ARIADOMPropertyConfig = __webpack_require__(137); -var BeforeInputEventPlugin = __webpack_require__(138); -var ChangeEventPlugin = __webpack_require__(142); -var DefaultEventPluginOrder = __webpack_require__(150); -var EnterLeaveEventPlugin = __webpack_require__(151); -var HTMLDOMPropertyConfig = __webpack_require__(152); -var ReactComponentBrowserEnvironment = __webpack_require__(153); -var ReactDOMComponent = __webpack_require__(159); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMEmptyComponent = __webpack_require__(185); -var ReactDOMTreeTraversal = __webpack_require__(186); -var ReactDOMTextComponent = __webpack_require__(187); -var ReactDefaultBatchingStrategy = __webpack_require__(188); -var ReactEventListener = __webpack_require__(189); -var ReactInjection = __webpack_require__(191); -var ReactReconcileTransaction = __webpack_require__(192); -var SVGDOMPropertyConfig = __webpack_require__(198); -var SelectEventPlugin = __webpack_require__(199); -var SimpleEventPlugin = __webpack_require__(200); + if (!network) throw new Error('Unknown network version') -var alreadyInjected = false; + // otherwise, assume a network object (or default to bitcoin) + } else { + network = network || NETWORKS.bitcoin -function inject() { - if (alreadyInjected) { - // TODO: This is currently true because these injections are shared between - // the client and the server package. They should be built independently - // and not share any injection state. Then this problem will be solved. - return; + if (version !== network.wif) throw new Error('Invalid network version') } - alreadyInjected = true; - ReactInjection.EventEmitter.injectReactEventListener(ReactEventListener); + var d = BigInteger.fromBuffer(decoded.privateKey) - /** - * Inject modules for resolving DOM hierarchy and plugin ordering. - */ - ReactInjection.EventPluginHub.injectEventPluginOrder(DefaultEventPluginOrder); - ReactInjection.EventPluginUtils.injectComponentTree(ReactDOMComponentTree); - ReactInjection.EventPluginUtils.injectTreeTraversal(ReactDOMTreeTraversal); + return new ECPair(d, null, { + compressed: decoded.compressed, + network: network + }) +} - /** - * Some important event plugins included by default (without having to require - * them). - */ - ReactInjection.EventPluginHub.injectEventPluginsByName({ - SimpleEventPlugin: SimpleEventPlugin, - EnterLeaveEventPlugin: EnterLeaveEventPlugin, - ChangeEventPlugin: ChangeEventPlugin, - SelectEventPlugin: SelectEventPlugin, - BeforeInputEventPlugin: BeforeInputEventPlugin - }); +ECPair.makeRandom = function (options) { + options = options || {} - ReactInjection.HostComponent.injectGenericComponentClass(ReactDOMComponent); + var rng = options.rng || randomBytes - ReactInjection.HostComponent.injectTextComponentClass(ReactDOMTextComponent); + var d + do { + var buffer = rng(32) + typeforce(types.Buffer256bit, buffer) - ReactInjection.DOMProperty.injectDOMPropertyConfig(ARIADOMPropertyConfig); - ReactInjection.DOMProperty.injectDOMPropertyConfig(HTMLDOMPropertyConfig); - ReactInjection.DOMProperty.injectDOMPropertyConfig(SVGDOMPropertyConfig); + d = BigInteger.fromBuffer(buffer) + } while (d.signum() <= 0 || d.compareTo(secp256k1.n) >= 0) - ReactInjection.EmptyComponent.injectEmptyComponentFactory(function (instantiate) { - return new ReactDOMEmptyComponent(instantiate); - }); + return new ECPair(d, null, options) +} - ReactInjection.Updates.injectReconcileTransaction(ReactReconcileTransaction); - ReactInjection.Updates.injectBatchingStrategy(ReactDefaultBatchingStrategy); +ECPair.prototype.getAddress = function () { + return baddress.toBase58Check(bcrypto.hash160(this.getPublicKeyBuffer()), this.getNetwork().pubKeyHash) +} - ReactInjection.Component.injectEnvironment(ReactComponentBrowserEnvironment); +ECPair.prototype.getNetwork = function () { + return this.network } -module.exports = { - inject: inject -}; +ECPair.prototype.getPublicKeyBuffer = function () { + return this.Q.getEncoded(this.compressed) +} + +ECPair.prototype.sign = function (hash) { + if (!this.d) throw new Error('Missing private key') + + return ecdsa.sign(hash, this.d) +} + +ECPair.prototype.toWIF = function () { + if (!this.d) throw new Error('Missing private key') + + return wif.encode(this.network.wif, this.d.toBuffer(32), this.compressed) +} + +ECPair.prototype.verify = function (hash, signature) { + return ecdsa.verify(hash, signature, this.Q) +} + +module.exports = ECPair + /***/ }), -/* 137 */ +/* 114 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Buffer = __webpack_require__(7).Buffer +var bs58check = __webpack_require__(33) +var bscript = __webpack_require__(14) +var networks = __webpack_require__(54) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +function fromBase58Check (address) { + var payload = bs58check.decode(address) + if (payload.length < 21) throw new TypeError(address + ' is too short') + if (payload.length > 21) throw new TypeError(address + ' is too long') + var version = payload.readUInt8(0) + var hash = payload.slice(1) -var ARIADOMPropertyConfig = { - Properties: { - // Global States and Properties - 'aria-current': 0, // state - 'aria-details': 0, - 'aria-disabled': 0, // state - 'aria-hidden': 0, // state - 'aria-invalid': 0, // state - 'aria-keyshortcuts': 0, - 'aria-label': 0, - 'aria-roledescription': 0, - // Widget Attributes - 'aria-autocomplete': 0, - 'aria-checked': 0, - 'aria-expanded': 0, - 'aria-haspopup': 0, - 'aria-level': 0, - 'aria-modal': 0, - 'aria-multiline': 0, - 'aria-multiselectable': 0, - 'aria-orientation': 0, - 'aria-placeholder': 0, - 'aria-pressed': 0, - 'aria-readonly': 0, - 'aria-required': 0, - 'aria-selected': 0, - 'aria-sort': 0, - 'aria-valuemax': 0, - 'aria-valuemin': 0, - 'aria-valuenow': 0, - 'aria-valuetext': 0, - // Live Region Attributes - 'aria-atomic': 0, - 'aria-busy': 0, - 'aria-live': 0, - 'aria-relevant': 0, - // Drag-and-Drop Attributes - 'aria-dropeffect': 0, - 'aria-grabbed': 0, - // Relationship Attributes - 'aria-activedescendant': 0, - 'aria-colcount': 0, - 'aria-colindex': 0, - 'aria-colspan': 0, - 'aria-controls': 0, - 'aria-describedby': 0, - 'aria-errormessage': 0, - 'aria-flowto': 0, - 'aria-labelledby': 0, - 'aria-owns': 0, - 'aria-posinset': 0, - 'aria-rowcount': 0, - 'aria-rowindex': 0, - 'aria-rowspan': 0, - 'aria-setsize': 0 - }, - DOMAttributeNames: {}, - DOMPropertyNames: {} -}; - -module.exports = ARIADOMPropertyConfig; - -/***/ }), -/* 138 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var FallbackCompositionState = __webpack_require__(139); -var SyntheticCompositionEvent = __webpack_require__(140); -var SyntheticInputEvent = __webpack_require__(141); + return { hash: hash, version: version } +} -var END_KEYCODES = [9, 13, 27, 32]; // Tab, Return, Esc, Space -var START_KEYCODE = 229; +function toBase58Check (hash, version) { + typeforce(types.tuple(types.Hash160bit, types.UInt8), arguments) -var canUseCompositionEvent = ExecutionEnvironment.canUseDOM && 'CompositionEvent' in window; + var payload = Buffer.allocUnsafe(21) + payload.writeUInt8(version, 0) + hash.copy(payload, 1) -var documentMode = null; -if (ExecutionEnvironment.canUseDOM && 'documentMode' in document) { - documentMode = document.documentMode; + return bs58check.encode(payload) } -// Webkit offers a very useful `textInput` event that can be used to -// directly represent `beforeInput`. The IE `textinput` event is not as -// useful, so we don't use it. -var canUseTextInputEvent = ExecutionEnvironment.canUseDOM && 'TextEvent' in window && !documentMode && !isPresto(); +function fromOutputScript (outputScript, network) { + network = network || networks.bitcoin -// In IE9+, we have access to composition events, but the data supplied -// by the native compositionend event may be incorrect. Japanese ideographic -// spaces, for instance (\u3000) are not recorded correctly. -var useFallbackCompositionData = ExecutionEnvironment.canUseDOM && (!canUseCompositionEvent || documentMode && documentMode > 8 && documentMode <= 11); + if (bscript.pubKeyHash.output.check(outputScript)) return toBase58Check(bscript.compile(outputScript).slice(3, 23), network.pubKeyHash) + if (bscript.scriptHash.output.check(outputScript)) return toBase58Check(bscript.compile(outputScript).slice(2, 22), network.scriptHash) -/** - * Opera <= 12 includes TextEvent in window, but does not fire - * text input events. Rely on keypress instead. - */ -function isPresto() { - var opera = window.opera; - return typeof opera === 'object' && typeof opera.version === 'function' && parseInt(opera.version(), 10) <= 12; + throw new Error(bscript.toASM(outputScript) + ' has no matching Address') } -var SPACEBAR_CODE = 32; -var SPACEBAR_CHAR = String.fromCharCode(SPACEBAR_CODE); - -// Events and their corresponding property names. -var eventTypes = { - beforeInput: { - phasedRegistrationNames: { - bubbled: 'onBeforeInput', - captured: 'onBeforeInputCapture' - }, - dependencies: ['topCompositionEnd', 'topKeyPress', 'topTextInput', 'topPaste'] - }, - compositionEnd: { - phasedRegistrationNames: { - bubbled: 'onCompositionEnd', - captured: 'onCompositionEndCapture' - }, - dependencies: ['topBlur', 'topCompositionEnd', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] - }, - compositionStart: { - phasedRegistrationNames: { - bubbled: 'onCompositionStart', - captured: 'onCompositionStartCapture' - }, - dependencies: ['topBlur', 'topCompositionStart', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] - }, - compositionUpdate: { - phasedRegistrationNames: { - bubbled: 'onCompositionUpdate', - captured: 'onCompositionUpdateCapture' - }, - dependencies: ['topBlur', 'topCompositionUpdate', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] - } -}; +function toOutputScript (address, network) { + network = network || networks.bitcoin -// Track whether we've ever handled a keypress on the space key. -var hasSpaceKeypress = false; + var decode = fromBase58Check(address) + if (decode.version === network.pubKeyHash) return bscript.pubKeyHash.output.encode(decode.hash) + if (decode.version === network.scriptHash) return bscript.scriptHash.output.encode(decode.hash) -/** - * Return whether a native keypress event is assumed to be a command. - * This is required because Firefox fires `keypress` events for key commands - * (cut, copy, select-all, etc.) even though no character is inserted. - */ -function isKeypressCommand(nativeEvent) { - return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) && - // ctrlKey && altKey is equivalent to AltGr, and is not a command. - !(nativeEvent.ctrlKey && nativeEvent.altKey); + throw new Error(address + ' has no matching Script') } -/** - * Translate native top level events into event types. - * - * @param {string} topLevelType - * @return {object} - */ -function getCompositionEventType(topLevelType) { - switch (topLevelType) { - case 'topCompositionStart': - return eventTypes.compositionStart; - case 'topCompositionEnd': - return eventTypes.compositionEnd; - case 'topCompositionUpdate': - return eventTypes.compositionUpdate; - } +module.exports = { + fromBase58Check: fromBase58Check, + fromOutputScript: fromOutputScript, + toBase58Check: toBase58Check, + toOutputScript: toOutputScript } -/** - * Does our fallback best-guess model think this event signifies that - * composition has begun? - * - * @param {string} topLevelType - * @param {object} nativeEvent - * @return {boolean} - */ -function isFallbackCompositionStart(topLevelType, nativeEvent) { - return topLevelType === 'topKeyDown' && nativeEvent.keyCode === START_KEYCODE; -} -/** - * Does our fallback mode think that this event is the end of composition? - * - * @param {string} topLevelType - * @param {object} nativeEvent - * @return {boolean} - */ -function isFallbackCompositionEnd(topLevelType, nativeEvent) { - switch (topLevelType) { - case 'topKeyUp': - // Command keys insert or clear IME input. - return END_KEYCODES.indexOf(nativeEvent.keyCode) !== -1; - case 'topKeyDown': - // Expect IME keyCode on each keydown. If we get any other - // code we must have exited earlier. - return nativeEvent.keyCode !== START_KEYCODE; - case 'topKeyPress': - case 'topMouseDown': - case 'topBlur': - // Events are not possible without cancelling IME. - return true; - default: - return false; - } -} +/***/ }), +/* 115 */ +/***/ (function(module, exports, __webpack_require__) { -/** - * Google Input Tools provides composition data via a CustomEvent, - * with the `data` property populated in the `detail` object. If this - * is available on the event object, use it. If not, this is a plain - * composition event and we have nothing special to extract. - * - * @param {object} nativeEvent - * @return {?string} - */ -function getDataFromCustomEvent(nativeEvent) { - var detail = nativeEvent.detail; - if (typeof detail === 'object' && 'data' in detail) { - return detail.data; - } - return null; -} +/* WEBPACK VAR INJECTION */(function(Buffer) {var bip66 = __webpack_require__(104) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) -// Track the current IME composition fallback object, if any. -var currentComposition = null; +var BigInteger = __webpack_require__(30) -/** - * @return {?object} A SyntheticCompositionEvent. - */ -function extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var eventType; - var fallbackData; +function ECSignature (r, s) { + typeforce(types.tuple(types.BigInt, types.BigInt), arguments) - if (canUseCompositionEvent) { - eventType = getCompositionEventType(topLevelType); - } else if (!currentComposition) { - if (isFallbackCompositionStart(topLevelType, nativeEvent)) { - eventType = eventTypes.compositionStart; - } - } else if (isFallbackCompositionEnd(topLevelType, nativeEvent)) { - eventType = eventTypes.compositionEnd; - } + this.r = r + this.s = s +} - if (!eventType) { - return null; - } +ECSignature.parseCompact = function (buffer) { + if (buffer.length !== 65) throw new Error('Invalid signature length') - if (useFallbackCompositionData) { - // The current composition is stored statically and must not be - // overwritten while composition continues. - if (!currentComposition && eventType === eventTypes.compositionStart) { - currentComposition = FallbackCompositionState.getPooled(nativeEventTarget); - } else if (eventType === eventTypes.compositionEnd) { - if (currentComposition) { - fallbackData = currentComposition.getData(); - } - } - } + var flagByte = buffer.readUInt8(0) - 27 + if (flagByte !== (flagByte & 7)) throw new Error('Invalid signature parameter') - var event = SyntheticCompositionEvent.getPooled(eventType, targetInst, nativeEvent, nativeEventTarget); + var compressed = !!(flagByte & 4) + var recoveryParam = flagByte & 3 - if (fallbackData) { - // Inject data generated from fallback path into the synthetic event. - // This matches the property of native CompositionEventInterface. - event.data = fallbackData; - } else { - var customData = getDataFromCustomEvent(nativeEvent); - if (customData !== null) { - event.data = customData; - } - } + var r = BigInteger.fromBuffer(buffer.slice(1, 33)) + var s = BigInteger.fromBuffer(buffer.slice(33)) - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; + return { + compressed: compressed, + i: recoveryParam, + signature: new ECSignature(r, s) + } } -/** - * @param {string} topLevelType Record from `EventConstants`. - * @param {object} nativeEvent Native browser event. - * @return {?string} The string corresponding to this `beforeInput` event. - */ -function getNativeBeforeInputChars(topLevelType, nativeEvent) { - switch (topLevelType) { - case 'topCompositionEnd': - return getDataFromCustomEvent(nativeEvent); - case 'topKeyPress': - /** - * If native `textInput` events are available, our goal is to make - * use of them. However, there is a special case: the spacebar key. - * In Webkit, preventing default on a spacebar `textInput` event - * cancels character insertion, but it *also* causes the browser - * to fall back to its default spacebar behavior of scrolling the - * page. - * - * Tracking at: - * https://code.google.com/p/chromium/issues/detail?id=355103 - * - * To avoid this issue, use the keypress event as if no `textInput` - * event is available. - */ - var which = nativeEvent.which; - if (which !== SPACEBAR_CODE) { - return null; - } - - hasSpaceKeypress = true; - return SPACEBAR_CHAR; +ECSignature.fromDER = function (buffer) { + var decode = bip66.decode(buffer) + var r = BigInteger.fromDERInteger(decode.r) + var s = BigInteger.fromDERInteger(decode.s) - case 'topTextInput': - // Record the characters to be added to the DOM. - var chars = nativeEvent.data; + return new ECSignature(r, s) +} - // If it's a spacebar character, assume that we have already handled - // it at the keypress level and bail immediately. Android Chrome - // doesn't give us keycodes, so we need to blacklist it. - if (chars === SPACEBAR_CHAR && hasSpaceKeypress) { - return null; - } +// BIP62: 1 byte hashType flag (only 0x01, 0x02, 0x03, 0x81, 0x82 and 0x83 are allowed) +ECSignature.parseScriptSignature = function (buffer) { + var hashType = buffer.readUInt8(buffer.length - 1) + var hashTypeMod = hashType & ~0x80 - return chars; + if (hashTypeMod <= 0x00 || hashTypeMod >= 0x04) throw new Error('Invalid hashType ' + hashType) - default: - // For other native event types, do nothing. - return null; + return { + signature: ECSignature.fromDER(buffer.slice(0, -1)), + hashType: hashType } } -/** - * For browsers that do not provide the `textInput` event, extract the - * appropriate string to use for SyntheticInputEvent. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {object} nativeEvent Native browser event. - * @return {?string} The fallback string for this `beforeInput` event. - */ -function getFallbackBeforeInputChars(topLevelType, nativeEvent) { - // If we are currently composing (IME) and using a fallback to do so, - // try to extract the composed characters from the fallback object. - // If composition event is available, we extract a string only at - // compositionevent, otherwise extract it at fallback events. - if (currentComposition) { - if (topLevelType === 'topCompositionEnd' || !canUseCompositionEvent && isFallbackCompositionEnd(topLevelType, nativeEvent)) { - var chars = currentComposition.getData(); - FallbackCompositionState.release(currentComposition); - currentComposition = null; - return chars; - } - return null; +ECSignature.prototype.toCompact = function (i, compressed) { + if (compressed) { + i += 4 } - switch (topLevelType) { - case 'topPaste': - // If a paste event occurs after a keypress, throw out the input - // chars. Paste events should not lead to BeforeInput events. - return null; - case 'topKeyPress': - /** - * As of v27, Firefox may fire keypress events even when no character - * will be inserted. A few possibilities: - * - * - `which` is `0`. Arrow keys, Esc key, etc. - * - * - `which` is the pressed key code, but no char is available. - * Ex: 'AltGr + d` in Polish. There is no modified character for - * this key combination and no character is inserted into the - * document, but FF fires the keypress for char code `100` anyway. - * No `input` event will occur. - * - * - `which` is the pressed key code, but a command combination is - * being used. Ex: `Cmd+C`. No character is inserted, and no - * `input` event will occur. - */ - if (nativeEvent.which && !isKeypressCommand(nativeEvent)) { - return String.fromCharCode(nativeEvent.which); - } - return null; - case 'topCompositionEnd': - return useFallbackCompositionData ? null : nativeEvent.data; - default: - return null; - } + i += 27 + + var buffer = Buffer.alloc(65) + buffer.writeUInt8(i, 0) + this.r.toBuffer(32).copy(buffer, 1) + this.s.toBuffer(32).copy(buffer, 33) + + return buffer } -/** - * Extract a SyntheticInputEvent for `beforeInput`, based on either native - * `textInput` or fallback behavior. - * - * @return {?object} A SyntheticInputEvent. - */ -function extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var chars; +ECSignature.prototype.toDER = function () { + var r = Buffer.from(this.r.toDERInteger()) + var s = Buffer.from(this.s.toDERInteger()) - if (canUseTextInputEvent) { - chars = getNativeBeforeInputChars(topLevelType, nativeEvent); - } else { - chars = getFallbackBeforeInputChars(topLevelType, nativeEvent); - } + return bip66.encode(r, s) +} - // If no characters are being inserted, no BeforeInput event should - // be fired. - if (!chars) { - return null; - } +ECSignature.prototype.toScriptSignature = function (hashType) { + var hashTypeMod = hashType & ~0x80 + if (hashTypeMod <= 0 || hashTypeMod >= 4) throw new Error('Invalid hashType ' + hashType) - var event = SyntheticInputEvent.getPooled(eventTypes.beforeInput, targetInst, nativeEvent, nativeEventTarget); + var hashTypeBuffer = Buffer.alloc(1) + hashTypeBuffer.writeUInt8(hashType, 0) - event.data = chars; - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; + return Buffer.concat([this.toDER(), hashTypeBuffer]) } -/** - * Create an `onBeforeInput` event to match - * http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105/#events-inputevents. - * - * This event plugin is based on the native `textInput` event - * available in Chrome, Safari, Opera, and IE. This event fires after - * `onKeyPress` and `onCompositionEnd`, but before `onInput`. - * - * `beforeInput` is spec'd but not implemented in any browsers, and - * the `input` event does not provide any useful information about what has - * actually been added, contrary to the spec. Thus, `textInput` is the best - * available event to identify the characters that have actually been inserted - * into the target node. - * - * This plugin is also responsible for emitting `composition` events, thus - * allowing us to share composition fallback code for both `beforeInput` and - * `composition` event types. - */ -var BeforeInputEventPlugin = { - eventTypes: eventTypes, - - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - return [extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget), extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget)]; - } -}; +module.exports = ECSignature -module.exports = BeforeInputEventPlugin; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 139 */ +/* 116 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var Point = __webpack_require__(207) +var Curve = __webpack_require__(208) +var getCurveByName = __webpack_require__(490) +module.exports = { + Curve: Curve, + Point: Point, + getCurveByName: getCurveByName +} -var _assign = __webpack_require__(5); -var PooledClass = __webpack_require__(20); +/***/ }), +/* 117 */ +/***/ (function(module, exports) { -var getTextContentAccessor = __webpack_require__(84); +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ +// css base code, injected by the css-loader +module.exports = function(useSourceMap) { + var list = []; -/** - * This helper class stores information about text content of a target node, - * allowing comparison of content before and after a given event. - * - * Identify the node where selection currently begins, then observe - * both its text content and its current position in the DOM. Since the - * browser may natively replace the target node during composition, we can - * use its position to find its replacement. - * - * @param {DOMEventTarget} root - */ -function FallbackCompositionState(root) { - this._root = root; - this._startText = this.getText(); - this._fallbackText = null; -} - -_assign(FallbackCompositionState.prototype, { - destructor: function () { - this._root = null; - this._startText = null; - this._fallbackText = null; - }, + // return the list of modules as css string + list.toString = function toString() { + return this.map(function (item) { + var content = cssWithMappingToString(item, useSourceMap); + if(item[2]) { + return "@media " + item[2] + "{" + content + "}"; + } else { + return content; + } + }).join(""); + }; - /** - * Get current text of input. - * - * @return {string} - */ - getText: function () { - if ('value' in this._root) { - return this._root.value; - } - return this._root[getTextContentAccessor()]; - }, + // import a list of modules into the list + list.i = function(modules, mediaQuery) { + if(typeof modules === "string") + modules = [[null, modules, ""]]; + var alreadyImportedModules = {}; + for(var i = 0; i < this.length; i++) { + var id = this[i][0]; + if(typeof id === "number") + alreadyImportedModules[id] = true; + } + for(i = 0; i < modules.length; i++) { + var item = modules[i]; + // skip already imported module + // this implementation is not 100% perfect for weird media query combinations + // when a module is imported multiple times with different media queries. + // I hope this will never occur (Hey this way we have smaller bundles) + if(typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) { + if(mediaQuery && !item[2]) { + item[2] = mediaQuery; + } else if(mediaQuery) { + item[2] = "(" + item[2] + ") and (" + mediaQuery + ")"; + } + list.push(item); + } + } + }; + return list; +}; - /** - * Determine the differing substring between the initially stored - * text content and the current content. - * - * @return {string} - */ - getData: function () { - if (this._fallbackText) { - return this._fallbackText; - } +function cssWithMappingToString(item, useSourceMap) { + var content = item[1] || ''; + var cssMapping = item[3]; + if (!cssMapping) { + return content; + } - var start; - var startValue = this._startText; - var startLength = startValue.length; - var end; - var endValue = this.getText(); - var endLength = endValue.length; + if (useSourceMap && typeof btoa === 'function') { + var sourceMapping = toComment(cssMapping); + var sourceURLs = cssMapping.sources.map(function (source) { + return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */' + }); - for (start = 0; start < startLength; start++) { - if (startValue[start] !== endValue[start]) { - break; - } - } + return [content].concat(sourceURLs).concat([sourceMapping]).join('\n'); + } - var minEnd = startLength - start; - for (end = 1; end <= minEnd; end++) { - if (startValue[startLength - end] !== endValue[endLength - end]) { - break; - } - } + return [content].join('\n'); +} - var sliceTail = end > 1 ? 1 - end : undefined; - this._fallbackText = endValue.slice(start, sliceTail); - return this._fallbackText; - } -}); +// Adapted from convert-source-map (MIT) +function toComment(sourceMap) { + // eslint-disable-next-line no-undef + var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))); + var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64; -PooledClass.addPoolingTo(FallbackCompositionState); + return '/*# ' + data + ' */'; +} -module.exports = FallbackCompositionState; /***/ }), -/* 140 */ +/* 118 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ +var stylesInDom = {}; -var SyntheticEvent = __webpack_require__(16); +var memoize = function (fn) { + var memo; -/** - * @interface Event - * @see http://www.w3.org/TR/DOM-Level-3-Events/#events-compositionevents - */ -var CompositionEventInterface = { - data: null + return function () { + if (typeof memo === "undefined") memo = fn.apply(this, arguments); + return memo; + }; }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticCompositionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +var isOldIE = memoize(function () { + // Test for IE <= 9 as proposed by Browserhacks + // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805 + // Tests for existence of standard globals is to allow style-loader + // to operate correctly into non-standard environments + // @see https://github.com/webpack-contrib/style-loader/issues/177 + return window && document && document.all && !window.atob; +}); -SyntheticEvent.augmentClass(SyntheticCompositionEvent, CompositionEventInterface); +var getElement = (function (fn) { + var memo = {}; -module.exports = SyntheticCompositionEvent; + return function(selector) { + if (typeof memo[selector] === "undefined") { + memo[selector] = fn.call(this, selector); + } -/***/ }), -/* 141 */ -/***/ (function(module, exports, __webpack_require__) { + return memo[selector] + }; +})(function (target) { + return document.querySelector(target) +}); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var singleton = null; +var singletonCounter = 0; +var stylesInsertedAtTop = []; +var fixUrls = __webpack_require__(213); +module.exports = function(list, options) { + if (typeof DEBUG !== "undefined" && DEBUG) { + if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment"); + } -var SyntheticEvent = __webpack_require__(16); + options = options || {}; -/** - * @interface Event - * @see http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105 - * /#events-inputevents - */ -var InputEventInterface = { - data: null -}; + options.attrs = typeof options.attrs === "object" ? options.attrs : {}; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticInputEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} + // Force single-tag solution on IE6-9, which has a hard limit on the # of <style> + // tags it will allow on a page + if (!options.singleton) options.singleton = isOldIE(); -SyntheticEvent.augmentClass(SyntheticInputEvent, InputEventInterface); + // By default, add <style> tags to the <head> element + if (!options.insertInto) options.insertInto = "head"; -module.exports = SyntheticInputEvent; + // By default, add <style> tags to the bottom of the target + if (!options.insertAt) options.insertAt = "bottom"; -/***/ }), -/* 142 */ -/***/ (function(module, exports, __webpack_require__) { + var styles = listToStyles(list, options); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + addStylesToDom(styles, options); + return function update (newList) { + var mayRemove = []; + for (var i = 0; i < styles.length; i++) { + var item = styles[i]; + var domStyle = stylesInDom[item.id]; -var EventPluginHub = __webpack_require__(32); -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); -var SyntheticEvent = __webpack_require__(16); + domStyle.refs--; + mayRemove.push(domStyle); + } -var inputValueTracking = __webpack_require__(87); -var getEventTarget = __webpack_require__(52); -var isEventSupported = __webpack_require__(53); -var isTextInputElement = __webpack_require__(88); + if(newList) { + var newStyles = listToStyles(newList, options); + addStylesToDom(newStyles, options); + } -var eventTypes = { - change: { - phasedRegistrationNames: { - bubbled: 'onChange', - captured: 'onChangeCapture' - }, - dependencies: ['topBlur', 'topChange', 'topClick', 'topFocus', 'topInput', 'topKeyDown', 'topKeyUp', 'topSelectionChange'] - } + for (var i = 0; i < mayRemove.length; i++) { + var domStyle = mayRemove[i]; + + if(domStyle.refs === 0) { + for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](); + + delete stylesInDom[domStyle.id]; + } + } + }; }; -function createAndAccumulateChangeEvent(inst, nativeEvent, target) { - var event = SyntheticEvent.getPooled(eventTypes.change, inst, nativeEvent, target); - event.type = 'change'; - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; -} -/** - * For IE shims - */ -var activeElement = null; -var activeElementInst = null; +function addStylesToDom (styles, options) { + for (var i = 0; i < styles.length; i++) { + var item = styles[i]; + var domStyle = stylesInDom[item.id]; -/** - * SECTION: handle `change` event - */ -function shouldUseChangeEvent(elem) { - var nodeName = elem.nodeName && elem.nodeName.toLowerCase(); - return nodeName === 'select' || nodeName === 'input' && elem.type === 'file'; -} + if(domStyle) { + domStyle.refs++; -var doesChangeEventBubble = false; -if (ExecutionEnvironment.canUseDOM) { - // See `handleChange` comment below - doesChangeEventBubble = isEventSupported('change') && (!document.documentMode || document.documentMode > 8); -} + for(var j = 0; j < domStyle.parts.length; j++) { + domStyle.parts[j](item.parts[j]); + } -function manualDispatchChangeEvent(nativeEvent) { - var event = createAndAccumulateChangeEvent(activeElementInst, nativeEvent, getEventTarget(nativeEvent)); + for(; j < item.parts.length; j++) { + domStyle.parts.push(addStyle(item.parts[j], options)); + } + } else { + var parts = []; - // If change and propertychange bubbled, we'd just bind to it like all the - // other events and have it go through ReactBrowserEventEmitter. Since it - // doesn't, we manually listen for the events and so we have to enqueue and - // process the abstract event manually. - // - // Batching is necessary here in order to ensure that all event handlers run - // before the next rerender (including event handlers attached to ancestor - // elements instead of directly on the input). Without this, controlled - // components don't work properly in conjunction with event bubbling because - // the component is rerendered and the value reverted before all the event - // handlers can run. See https://github.com/facebook/react/issues/708. - ReactUpdates.batchedUpdates(runEventInBatch, event); -} + for(var j = 0; j < item.parts.length; j++) { + parts.push(addStyle(item.parts[j], options)); + } -function runEventInBatch(event) { - EventPluginHub.enqueueEvents(event); - EventPluginHub.processEventQueue(false); + stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts}; + } + } } -function startWatchingForChangeEventIE8(target, targetInst) { - activeElement = target; - activeElementInst = targetInst; - activeElement.attachEvent('onchange', manualDispatchChangeEvent); -} +function listToStyles (list, options) { + var styles = []; + var newStyles = {}; -function stopWatchingForChangeEventIE8() { - if (!activeElement) { - return; - } - activeElement.detachEvent('onchange', manualDispatchChangeEvent); - activeElement = null; - activeElementInst = null; -} + for (var i = 0; i < list.length; i++) { + var item = list[i]; + var id = options.base ? item[0] + options.base : item[0]; + var css = item[1]; + var media = item[2]; + var sourceMap = item[3]; + var part = {css: css, media: media, sourceMap: sourceMap}; -function getInstIfValueChanged(targetInst, nativeEvent) { - var updated = inputValueTracking.updateValueIfChanged(targetInst); - var simulated = nativeEvent.simulated === true && ChangeEventPlugin._allowSimulatedPassThrough; + if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]}); + else newStyles[id].parts.push(part); + } - if (updated || simulated) { - return targetInst; - } + return styles; } -function getTargetInstForChangeEvent(topLevelType, targetInst) { - if (topLevelType === 'topChange') { - return targetInst; - } -} +function insertStyleElement (options, style) { + var target = getElement(options.insertInto) -function handleEventsForChangeEventIE8(topLevelType, target, targetInst) { - if (topLevelType === 'topFocus') { - // stopWatching() should be a noop here but we call it just in case we - // missed a blur event somehow. - stopWatchingForChangeEventIE8(); - startWatchingForChangeEventIE8(target, targetInst); - } else if (topLevelType === 'topBlur') { - stopWatchingForChangeEventIE8(); - } -} + if (!target) { + throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid."); + } -/** - * SECTION: handle `input` event - */ -var isInputEventSupported = false; -if (ExecutionEnvironment.canUseDOM) { - // IE9 claims to support the input event but fails to trigger it when - // deleting text, so we ignore its input events. + var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1]; - isInputEventSupported = isEventSupported('input') && (!('documentMode' in document) || document.documentMode > 9); + if (options.insertAt === "top") { + if (!lastStyleElementInsertedAtTop) { + target.insertBefore(style, target.firstChild); + } else if (lastStyleElementInsertedAtTop.nextSibling) { + target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling); + } else { + target.appendChild(style); + } + stylesInsertedAtTop.push(style); + } else if (options.insertAt === "bottom") { + target.appendChild(style); + } else { + throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'."); + } } -/** - * (For IE <=9) Starts tracking propertychange events on the passed-in element - * and override the value property so that we can distinguish user events from - * value changes in JS. - */ -function startWatchingForValueChange(target, targetInst) { - activeElement = target; - activeElementInst = targetInst; - activeElement.attachEvent('onpropertychange', handlePropertyChange); +function removeStyleElement (style) { + if (style.parentNode === null) return false; + style.parentNode.removeChild(style); + + var idx = stylesInsertedAtTop.indexOf(style); + if(idx >= 0) { + stylesInsertedAtTop.splice(idx, 1); + } } -/** - * (For IE <=9) Removes the event listeners from the currently-tracked element, - * if any exists. - */ -function stopWatchingForValueChange() { - if (!activeElement) { - return; - } - activeElement.detachEvent('onpropertychange', handlePropertyChange); +function createStyleElement (options) { + var style = document.createElement("style"); - activeElement = null; - activeElementInst = null; -} + options.attrs.type = "text/css"; -/** - * (For IE <=9) Handles a propertychange event, sending a `change` event if - * the value of the active element has changed. - */ -function handlePropertyChange(nativeEvent) { - if (nativeEvent.propertyName !== 'value') { - return; - } - if (getInstIfValueChanged(activeElementInst, nativeEvent)) { - manualDispatchChangeEvent(nativeEvent); - } -} + addAttrs(style, options.attrs); + insertStyleElement(options, style); -function handleEventsForInputEventPolyfill(topLevelType, target, targetInst) { - if (topLevelType === 'topFocus') { - // In IE8, we can capture almost all .value changes by adding a - // propertychange handler and looking for events with propertyName - // equal to 'value' - // In IE9, propertychange fires for most input events but is buggy and - // doesn't fire when text is deleted, but conveniently, selectionchange - // appears to fire in all of the remaining cases so we catch those and - // forward the event if the value has changed - // In either case, we don't want to call the event handler if the value - // is changed from JS so we redefine a setter for `.value` that updates - // our activeElementValue variable, allowing us to ignore those changes - // - // stopWatching() should be a noop here but we call it just in case we - // missed a blur event somehow. - stopWatchingForValueChange(); - startWatchingForValueChange(target, targetInst); - } else if (topLevelType === 'topBlur') { - stopWatchingForValueChange(); - } + return style; } -// For IE8 and IE9. -function getTargetInstForInputEventPolyfill(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topSelectionChange' || topLevelType === 'topKeyUp' || topLevelType === 'topKeyDown') { - // On the selectionchange event, the target is just document which isn't - // helpful for us so just check activeElement instead. - // - // 99% of the time, keydown and keyup aren't necessary. IE8 fails to fire - // propertychange on the first input event after setting `value` from a - // script and fires only keydown, keypress, keyup. Catching keyup usually - // gets it and catching keydown lets us fire an event for the first - // keystroke if user does a key repeat (it'll be a little delayed: right - // before the second keystroke). Other input methods (e.g., paste) seem to - // fire selectionchange normally. - return getInstIfValueChanged(activeElementInst, nativeEvent); - } -} +function createLinkElement (options) { + var link = document.createElement("link"); -/** - * SECTION: handle `click` event - */ -function shouldUseClickEvent(elem) { - // Use the `click` event to detect changes to checkbox and radio inputs. - // This approach works across all browsers, whereas `change` does not fire - // until `blur` in IE8. - var nodeName = elem.nodeName; - return nodeName && nodeName.toLowerCase() === 'input' && (elem.type === 'checkbox' || elem.type === 'radio'); -} + options.attrs.type = "text/css"; + options.attrs.rel = "stylesheet"; -function getTargetInstForClickEvent(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topClick') { - return getInstIfValueChanged(targetInst, nativeEvent); - } + addAttrs(link, options.attrs); + insertStyleElement(options, link); + + return link; } -function getTargetInstForInputOrChangeEvent(topLevelType, targetInst, nativeEvent) { - if (topLevelType === 'topInput' || topLevelType === 'topChange') { - return getInstIfValueChanged(targetInst, nativeEvent); - } +function addAttrs (el, attrs) { + Object.keys(attrs).forEach(function (key) { + el.setAttribute(key, attrs[key]); + }); } -function handleControlledInputBlur(inst, node) { - // TODO: In IE, inst is occasionally null. Why? - if (inst == null) { - return; - } - - // Fiber and ReactDOM keep wrapper state in separate places - var state = inst._wrapperState || node._wrapperState; +function addStyle (obj, options) { + var style, update, remove, result; - if (!state || !state.controlled || node.type !== 'number') { - return; - } + // If a transform function was defined, run it on the css + if (options.transform && obj.css) { + result = options.transform(obj.css); - // If controlled, assign the value attribute to the current value on blur - var value = '' + node.value; - if (node.getAttribute('value') !== value) { - node.setAttribute('value', value); - } -} + if (result) { + // If transform returns a value, use that instead of the original css. + // This allows running runtime transformations on the css. + obj.css = result; + } else { + // If the transform function returns a falsy value, don't add this css. + // This allows conditional loading of css + return function() { + // noop + }; + } + } -/** - * This plugin creates an `onChange` event that normalizes change events - * across form elements. This event fires at a time when it's possible to - * change the element's value without seeing a flicker. - * - * Supported elements are: - * - input (see `isTextInputElement`) - * - textarea - * - select - */ -var ChangeEventPlugin = { - eventTypes: eventTypes, + if (options.singleton) { + var styleIndex = singletonCounter++; - _allowSimulatedPassThrough: true, - _isInputEventSupported: isInputEventSupported, + style = singleton || (singleton = createStyleElement(options)); - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; + update = applyToSingletonTag.bind(null, style, styleIndex, false); + remove = applyToSingletonTag.bind(null, style, styleIndex, true); - var getTargetInstFunc, handleEventFunc; - if (shouldUseChangeEvent(targetNode)) { - if (doesChangeEventBubble) { - getTargetInstFunc = getTargetInstForChangeEvent; - } else { - handleEventFunc = handleEventsForChangeEventIE8; - } - } else if (isTextInputElement(targetNode)) { - if (isInputEventSupported) { - getTargetInstFunc = getTargetInstForInputOrChangeEvent; - } else { - getTargetInstFunc = getTargetInstForInputEventPolyfill; - handleEventFunc = handleEventsForInputEventPolyfill; - } - } else if (shouldUseClickEvent(targetNode)) { - getTargetInstFunc = getTargetInstForClickEvent; - } + } else if ( + obj.sourceMap && + typeof URL === "function" && + typeof URL.createObjectURL === "function" && + typeof URL.revokeObjectURL === "function" && + typeof Blob === "function" && + typeof btoa === "function" + ) { + style = createLinkElement(options); + update = updateLink.bind(null, style, options); + remove = function () { + removeStyleElement(style); - if (getTargetInstFunc) { - var inst = getTargetInstFunc(topLevelType, targetInst, nativeEvent); - if (inst) { - var event = createAndAccumulateChangeEvent(inst, nativeEvent, nativeEventTarget); - return event; - } - } + if(style.href) URL.revokeObjectURL(style.href); + }; + } else { + style = createStyleElement(options); + update = applyToTag.bind(null, style); + remove = function () { + removeStyleElement(style); + }; + } - if (handleEventFunc) { - handleEventFunc(topLevelType, targetNode, targetInst); - } + update(obj); - // When blurring, set the value attribute for number inputs - if (topLevelType === 'topBlur') { - handleControlledInputBlur(targetInst, targetNode); - } - } -}; + return function updateStyle (newObj) { + if (newObj) { + if ( + newObj.css === obj.css && + newObj.media === obj.media && + newObj.sourceMap === obj.sourceMap + ) { + return; + } -module.exports = ChangeEventPlugin; + update(obj = newObj); + } else { + remove(); + } + }; +} -/***/ }), -/* 143 */ -/***/ (function(module, exports, __webpack_require__) { +var replaceText = (function () { + var textStore = []; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ + return function (index, replacement) { + textStore[index] = replacement; + return textStore.filter(Boolean).join('\n'); + }; +})(); +function applyToSingletonTag (style, index, remove, obj) { + var css = remove ? "" : obj.css; -var ReactOwner = __webpack_require__(144); + if (style.styleSheet) { + style.styleSheet.cssText = replaceText(index, css); + } else { + var cssNode = document.createTextNode(css); + var childNodes = style.childNodes; -var ReactRef = {}; + if (childNodes[index]) style.removeChild(childNodes[index]); -function attachRef(ref, component, owner) { - if (typeof ref === 'function') { - ref(component.getPublicInstance()); - } else { - // Legacy ref - ReactOwner.addComponentAsRefTo(component, ref, owner); - } + if (childNodes.length) { + style.insertBefore(cssNode, childNodes[index]); + } else { + style.appendChild(cssNode); + } + } } -function detachRef(ref, component, owner) { - if (typeof ref === 'function') { - ref(null); - } else { - // Legacy ref - ReactOwner.removeComponentAsRefFrom(component, ref, owner); - } +function applyToTag (style, obj) { + var css = obj.css; + var media = obj.media; + + if(media) { + style.setAttribute("media", media) + } + + if(style.styleSheet) { + style.styleSheet.cssText = css; + } else { + while(style.firstChild) { + style.removeChild(style.firstChild); + } + + style.appendChild(document.createTextNode(css)); + } } -ReactRef.attachRefs = function (instance, element) { - if (element === null || typeof element !== 'object') { - return; - } - var ref = element.ref; - if (ref != null) { - attachRef(ref, instance, element._owner); - } -}; +function updateLink (link, options, obj) { + var css = obj.css; + var sourceMap = obj.sourceMap; -ReactRef.shouldUpdateRefs = function (prevElement, nextElement) { - // If either the owner or a `ref` has changed, make sure the newest owner - // has stored a reference to `this`, and the previous owner (if different) - // has forgotten the reference to `this`. We use the element instead - // of the public this.props because the post processing cannot determine - // a ref. The ref conceptually lives on the element. + /* + If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled + and there is no publicPath defined then lets turn convertToAbsoluteUrls + on by default. Otherwise default to the convertToAbsoluteUrls option + directly + */ + var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap; - // TODO: Should this even be possible? The owner cannot change because - // it's forbidden by shouldUpdateReactComponent. The ref can change - // if you swap the keys of but not the refs. Reconsider where this check - // is made. It probably belongs where the key checking and - // instantiateReactComponent is done. + if (options.convertToAbsoluteUrls || autoFixUrls) { + css = fixUrls(css); + } - var prevRef = null; - var prevOwner = null; - if (prevElement !== null && typeof prevElement === 'object') { - prevRef = prevElement.ref; - prevOwner = prevElement._owner; - } + if (sourceMap) { + // http://stackoverflow.com/a/26603875 + css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */"; + } - var nextRef = null; - var nextOwner = null; - if (nextElement !== null && typeof nextElement === 'object') { - nextRef = nextElement.ref; - nextOwner = nextElement._owner; - } + var blob = new Blob([css], { type: "text/css" }); - return prevRef !== nextRef || - // If owner changes but we have an unchanged function ref, don't update refs - typeof nextRef === 'string' && nextOwner !== prevOwner; -}; + var oldSrc = link.href; -ReactRef.detachRefs = function (instance, element) { - if (element === null || typeof element !== 'object') { - return; - } - var ref = element.ref; - if (ref != null) { - detachRef(ref, instance, element._owner); - } -}; + link.href = URL.createObjectURL(blob); + + if(oldSrc) URL.revokeObjectURL(oldSrc); +} -module.exports = ReactRef; /***/ }), -/* 144 */ +/* 119 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -26108,466 +23420,250 @@ module.exports = ReactRef; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -var _prodInvariant = __webpack_require__(3); +var _prodInvariant = __webpack_require__(37), + _assign = __webpack_require__(8); + +var ReactNoopUpdateQueue = __webpack_require__(120); -var invariant = __webpack_require__(1); +var canDefineProperty = __webpack_require__(55); +var emptyObject = __webpack_require__(56); +var invariant = __webpack_require__(2); +var lowPriorityWarning = __webpack_require__(74); /** - * @param {?object} object - * @return {boolean} True if `object` is a valid owner. - * @final + * Base class helpers for the updating state of a component. */ -function isValidOwner(object) { - return !!(object && typeof object.attachRef === 'function' && typeof object.detachRef === 'function'); +function ReactComponent(props, context, updater) { + this.props = props; + this.context = context; + this.refs = emptyObject; + // We initialize the default updater but the real one gets injected by the + // renderer. + this.updater = updater || ReactNoopUpdateQueue; } +ReactComponent.prototype.isReactComponent = {}; + /** - * ReactOwners are capable of storing references to owned components. + * Sets a subset of the state. Always use this to mutate + * state. You should treat `this.state` as immutable. * - * All components are capable of //being// referenced by owner components, but - * only ReactOwner components are capable of //referencing// owned components. - * The named reference is known as a "ref". + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. * - * Refs are available when mounted and updated during reconciliation. + * There is no guarantee that calls to `setState` will run synchronously, + * as they may eventually be batched together. You can provide an optional + * callback that will be executed when the call to setState is actually + * completed. * - * var MyComponent = React.createClass({ - * render: function() { - * return ( - * <div onClick={this.handleClick}> - * <CustomComponent ref="custom" /> - * </div> - * ); - * }, - * handleClick: function() { - * this.refs.custom.handleClick(); - * }, - * componentDidMount: function() { - * this.refs.custom.initialize(); - * } - * }); + * When a function is provided to setState, it will be called at some point in + * the future (not synchronously). It will be called with the up to date + * component arguments (state, props, context). These values can be different + * from this.* because your function may be called after receiveProps but before + * shouldComponentUpdate, and this new state, props, and context will not yet be + * assigned to this. * - * Refs should rarely be used. When refs are used, they should only be done to - * control data that is not handled by React's data flow. + * @param {object|function} partialState Next partial state or function to + * produce next partial state to be merged with current state. + * @param {?function} callback Called after state is updated. + * @final + * @protected + */ +ReactComponent.prototype.setState = function (partialState, callback) { + !(typeof partialState === 'object' || typeof partialState === 'function' || partialState == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.') : _prodInvariant('85') : void 0; + this.updater.enqueueSetState(this, partialState); + if (callback) { + this.updater.enqueueCallback(this, callback, 'setState'); + } +}; + +/** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. * - * @class ReactOwner + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {?function} callback Called after update is complete. + * @final + * @protected */ -var ReactOwner = { - /** - * Adds a component by ref to an owner component. - * - * @param {ReactComponent} component Component to reference. - * @param {string} ref Name by which to refer to the component. - * @param {ReactOwner} owner Component on which to record the ref. - * @final - * @internal - */ - addComponentAsRefTo: function (component, ref, owner) { - !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('119') : void 0; - owner.attachRef(ref, component); - }, +ReactComponent.prototype.forceUpdate = function (callback) { + this.updater.enqueueForceUpdate(this); + if (callback) { + this.updater.enqueueCallback(this, callback, 'forceUpdate'); + } +}; - /** - * Removes a component by ref from an owner component. - * - * @param {ReactComponent} component Component to dereference. - * @param {string} ref Name of the ref to remove. - * @param {ReactOwner} owner Component on which the ref is recorded. - * @final - * @internal - */ - removeComponentAsRefFrom: function (component, ref, owner) { - !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'removeComponentAsRefFrom(...): Only a ReactOwner can have refs. You might be removing a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('120') : void 0; - var ownerPublicInstance = owner.getPublicInstance(); - // Check that `component`'s owner is still alive and that `component` is still the current ref - // because we do not want to detach the ref if another component stole it. - if (ownerPublicInstance && ownerPublicInstance.refs[ref] === component.getPublicInstance()) { - owner.detachRef(ref); +/** + * Deprecated APIs. These APIs used to exist on classic React classes but since + * we would like to deprecate them, we're not going to move them over to this + * modern base class. Instead, we define a getter that warns if it's accessed. + */ +if (process.env.NODE_ENV !== 'production') { + var deprecatedAPIs = { + isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'], + replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).'] + }; + var defineDeprecationWarning = function (methodName, info) { + if (canDefineProperty) { + Object.defineProperty(ReactComponent.prototype, methodName, { + get: function () { + lowPriorityWarning(false, '%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]); + return undefined; + } + }); + } + }; + for (var fnName in deprecatedAPIs) { + if (deprecatedAPIs.hasOwnProperty(fnName)) { + defineDeprecationWarning(fnName, deprecatedAPIs[fnName]); } } -}; +} -module.exports = ReactOwner; +/** + * Base class helpers for the updating state of a component. + */ +function ReactPureComponent(props, context, updater) { + // Duplicated from ReactComponent. + this.props = props; + this.context = context; + this.refs = emptyObject; + // We initialize the default updater but the real one gets injected by the + // renderer. + this.updater = updater || ReactNoopUpdateQueue; +} + +function ComponentDummy() {} +ComponentDummy.prototype = ReactComponent.prototype; +ReactPureComponent.prototype = new ComponentDummy(); +ReactPureComponent.prototype.constructor = ReactPureComponent; +// Avoid an extra prototype jump for these methods. +_assign(ReactPureComponent.prototype, ReactComponent.prototype); +ReactPureComponent.prototype.isPureReactComponent = true; + +module.exports = { + Component: ReactComponent, + PureComponent: ReactPureComponent +}; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 145 */ +/* 120 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. + * Copyright 2015-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * */ -var ReactInvalidSetStateWarningHook = __webpack_require__(146); -var ReactHostOperationHistoryHook = __webpack_require__(147); -var ReactComponentTreeHook = __webpack_require__(10); -var ExecutionEnvironment = __webpack_require__(8); - -var performanceNow = __webpack_require__(148); -var warning = __webpack_require__(2); - -var hooks = []; -var didHookThrowForEvent = {}; - -function callHook(event, fn, context, arg1, arg2, arg3, arg4, arg5) { - try { - fn.call(context, arg1, arg2, arg3, arg4, arg5); - } catch (e) { - process.env.NODE_ENV !== 'production' ? warning(didHookThrowForEvent[event], 'Exception thrown by hook while handling %s: %s', event, e + '\n' + e.stack) : void 0; - didHookThrowForEvent[event] = true; - } -} +var warning = __webpack_require__(3); -function emitEvent(event, arg1, arg2, arg3, arg4, arg5) { - for (var i = 0; i < hooks.length; i++) { - var hook = hooks[i]; - var fn = hook[event]; - if (fn) { - callHook(event, fn, hook, arg1, arg2, arg3, arg4, arg5); - } +function warnNoop(publicInstance, callerName) { + if (process.env.NODE_ENV !== 'production') { + var constructor = publicInstance.constructor; + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; } } -var isProfiling = false; -var flushHistory = []; -var lifeCycleTimerStack = []; -var currentFlushNesting = 0; -var currentFlushMeasurements = []; -var currentFlushStartTime = 0; -var currentTimerDebugID = null; -var currentTimerStartTime = 0; -var currentTimerNestedFlushDuration = 0; -var currentTimerType = null; - -var lifeCycleTimerHasWarned = false; +/** + * This is the abstract API for an update queue. + */ +var ReactNoopUpdateQueue = { + /** + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + isMounted: function (publicInstance) { + return false; + }, -function clearHistory() { - ReactComponentTreeHook.purgeUnmountedComponents(); - ReactHostOperationHistoryHook.clearHistory(); -} + /** + * Enqueue a callback that will be executed after all the pending updates + * have processed. + * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @internal + */ + enqueueCallback: function (publicInstance, callback) {}, -function getTreeSnapshot(registeredIDs) { - return registeredIDs.reduce(function (tree, id) { - var ownerID = ReactComponentTreeHook.getOwnerID(id); - var parentID = ReactComponentTreeHook.getParentID(id); - tree[id] = { - displayName: ReactComponentTreeHook.getDisplayName(id), - text: ReactComponentTreeHook.getText(id), - updateCount: ReactComponentTreeHook.getUpdateCount(id), - childIDs: ReactComponentTreeHook.getChildIDs(id), - // Text nodes don't have owners but this is close enough. - ownerID: ownerID || parentID && ReactComponentTreeHook.getOwnerID(parentID) || 0, - parentID: parentID - }; - return tree; - }, {}); -} - -function resetMeasurements() { - var previousStartTime = currentFlushStartTime; - var previousMeasurements = currentFlushMeasurements; - var previousOperations = ReactHostOperationHistoryHook.getHistory(); - - if (currentFlushNesting === 0) { - currentFlushStartTime = 0; - currentFlushMeasurements = []; - clearHistory(); - return; - } - - if (previousMeasurements.length || previousOperations.length) { - var registeredIDs = ReactComponentTreeHook.getRegisteredIDs(); - flushHistory.push({ - duration: performanceNow() - previousStartTime, - measurements: previousMeasurements || [], - operations: previousOperations || [], - treeSnapshot: getTreeSnapshot(registeredIDs) - }); - } - - clearHistory(); - currentFlushStartTime = performanceNow(); - currentFlushMeasurements = []; -} - -function checkDebugID(debugID) { - var allowRoot = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; - - if (allowRoot && debugID === 0) { - return; - } - if (!debugID) { - process.env.NODE_ENV !== 'production' ? warning(false, 'ReactDebugTool: debugID may not be empty.') : void 0; - } -} - -function beginLifeCycleTimer(debugID, timerType) { - if (currentFlushNesting === 0) { - return; - } - if (currentTimerType && !lifeCycleTimerHasWarned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'Did not expect %s timer to start while %s timer is still in ' + 'progress for %s instance.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; - lifeCycleTimerHasWarned = true; - } - currentTimerStartTime = performanceNow(); - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = debugID; - currentTimerType = timerType; -} - -function endLifeCycleTimer(debugID, timerType) { - if (currentFlushNesting === 0) { - return; - } - if (currentTimerType !== timerType && !lifeCycleTimerHasWarned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'We did not expect %s timer to stop while %s timer is still in ' + 'progress for %s instance. Please report this as a bug in React.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; - lifeCycleTimerHasWarned = true; - } - if (isProfiling) { - currentFlushMeasurements.push({ - timerType: timerType, - instanceID: debugID, - duration: performanceNow() - currentTimerStartTime - currentTimerNestedFlushDuration - }); - } - currentTimerStartTime = 0; - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = null; - currentTimerType = null; -} - -function pauseCurrentLifeCycleTimer() { - var currentTimer = { - startTime: currentTimerStartTime, - nestedFlushStartTime: performanceNow(), - debugID: currentTimerDebugID, - timerType: currentTimerType - }; - lifeCycleTimerStack.push(currentTimer); - currentTimerStartTime = 0; - currentTimerNestedFlushDuration = 0; - currentTimerDebugID = null; - currentTimerType = null; -} - -function resumeCurrentLifeCycleTimer() { - var _lifeCycleTimerStack$ = lifeCycleTimerStack.pop(), - startTime = _lifeCycleTimerStack$.startTime, - nestedFlushStartTime = _lifeCycleTimerStack$.nestedFlushStartTime, - debugID = _lifeCycleTimerStack$.debugID, - timerType = _lifeCycleTimerStack$.timerType; - - var nestedFlushDuration = performanceNow() - nestedFlushStartTime; - currentTimerStartTime = startTime; - currentTimerNestedFlushDuration += nestedFlushDuration; - currentTimerDebugID = debugID; - currentTimerType = timerType; -} - -var lastMarkTimeStamp = 0; -var canUsePerformanceMeasure = typeof performance !== 'undefined' && typeof performance.mark === 'function' && typeof performance.clearMarks === 'function' && typeof performance.measure === 'function' && typeof performance.clearMeasures === 'function'; - -function shouldMark(debugID) { - if (!isProfiling || !canUsePerformanceMeasure) { - return false; - } - var element = ReactComponentTreeHook.getElement(debugID); - if (element == null || typeof element !== 'object') { - return false; - } - var isHostElement = typeof element.type === 'string'; - if (isHostElement) { - return false; - } - return true; -} - -function markBegin(debugID, markType) { - if (!shouldMark(debugID)) { - return; - } - - var markName = debugID + '::' + markType; - lastMarkTimeStamp = performanceNow(); - performance.mark(markName); -} - -function markEnd(debugID, markType) { - if (!shouldMark(debugID)) { - return; - } - - var markName = debugID + '::' + markType; - var displayName = ReactComponentTreeHook.getDisplayName(debugID) || 'Unknown'; - - // Chrome has an issue of dropping markers recorded too fast: - // https://bugs.chromium.org/p/chromium/issues/detail?id=640652 - // To work around this, we will not report very small measurements. - // I determined the magic number by tweaking it back and forth. - // 0.05ms was enough to prevent the issue, but I set it to 0.1ms to be safe. - // When the bug is fixed, we can `measure()` unconditionally if we want to. - var timeStamp = performanceNow(); - if (timeStamp - lastMarkTimeStamp > 0.1) { - var measurementName = displayName + ' [' + markType + ']'; - performance.measure(measurementName, markName); - } - - performance.clearMarks(markName); - if (measurementName) { - performance.clearMeasures(measurementName); - } -} - -var ReactDebugTool = { - addHook: function (hook) { - hooks.push(hook); - }, - removeHook: function (hook) { - for (var i = 0; i < hooks.length; i++) { - if (hooks[i] === hook) { - hooks.splice(i, 1); - i--; - } - } - }, - isProfiling: function () { - return isProfiling; + /** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal + */ + enqueueForceUpdate: function (publicInstance) { + warnNoop(publicInstance, 'forceUpdate'); }, - beginProfiling: function () { - if (isProfiling) { - return; - } - isProfiling = true; - flushHistory.length = 0; - resetMeasurements(); - ReactDebugTool.addHook(ReactHostOperationHistoryHook); + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} completeState Next state. + * @internal + */ + enqueueReplaceState: function (publicInstance, completeState) { + warnNoop(publicInstance, 'replaceState'); }, - endProfiling: function () { - if (!isProfiling) { - return; - } - isProfiling = false; - resetMeasurements(); - ReactDebugTool.removeHook(ReactHostOperationHistoryHook); - }, - getFlushHistory: function () { - return flushHistory; - }, - onBeginFlush: function () { - currentFlushNesting++; - resetMeasurements(); - pauseCurrentLifeCycleTimer(); - emitEvent('onBeginFlush'); - }, - onEndFlush: function () { - resetMeasurements(); - currentFlushNesting--; - resumeCurrentLifeCycleTimer(); - emitEvent('onEndFlush'); - }, - onBeginLifeCycleTimer: function (debugID, timerType) { - checkDebugID(debugID); - emitEvent('onBeginLifeCycleTimer', debugID, timerType); - markBegin(debugID, timerType); - beginLifeCycleTimer(debugID, timerType); - }, - onEndLifeCycleTimer: function (debugID, timerType) { - checkDebugID(debugID); - endLifeCycleTimer(debugID, timerType); - markEnd(debugID, timerType); - emitEvent('onEndLifeCycleTimer', debugID, timerType); - }, - onBeginProcessingChildContext: function () { - emitEvent('onBeginProcessingChildContext'); - }, - onEndProcessingChildContext: function () { - emitEvent('onEndProcessingChildContext'); - }, - onHostOperation: function (operation) { - checkDebugID(operation.instanceID); - emitEvent('onHostOperation', operation); - }, - onSetState: function () { - emitEvent('onSetState'); - }, - onSetChildren: function (debugID, childDebugIDs) { - checkDebugID(debugID); - childDebugIDs.forEach(checkDebugID); - emitEvent('onSetChildren', debugID, childDebugIDs); - }, - onBeforeMountComponent: function (debugID, element, parentDebugID) { - checkDebugID(debugID); - checkDebugID(parentDebugID, true); - emitEvent('onBeforeMountComponent', debugID, element, parentDebugID); - markBegin(debugID, 'mount'); - }, - onMountComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'mount'); - emitEvent('onMountComponent', debugID); - }, - onBeforeUpdateComponent: function (debugID, element) { - checkDebugID(debugID); - emitEvent('onBeforeUpdateComponent', debugID, element); - markBegin(debugID, 'update'); - }, - onUpdateComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'update'); - emitEvent('onUpdateComponent', debugID); - }, - onBeforeUnmountComponent: function (debugID) { - checkDebugID(debugID); - emitEvent('onBeforeUnmountComponent', debugID); - markBegin(debugID, 'unmount'); - }, - onUnmountComponent: function (debugID) { - checkDebugID(debugID); - markEnd(debugID, 'unmount'); - emitEvent('onUnmountComponent', debugID); - }, - onTestEvent: function () { - emitEvent('onTestEvent'); + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object} partialState Next partial state to be merged with state. + * @internal + */ + enqueueSetState: function (publicInstance, partialState) { + warnNoop(publicInstance, 'setState'); } }; -// TODO remove these when RN/www gets updated -ReactDebugTool.addDevtool = ReactDebugTool.addHook; -ReactDebugTool.removeDevtool = ReactDebugTool.removeHook; - -ReactDebugTool.addHook(ReactInvalidSetStateWarningHook); -ReactDebugTool.addHook(ReactComponentTreeHook); -var url = ExecutionEnvironment.canUseDOM && window.location.href || ''; -if (/[?&]react_perf\b/.test(url)) { - ReactDebugTool.beginProfiling(); -} - -module.exports = ReactDebugTool; +module.exports = ReactNoopUpdateQueue; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 146 */ +/* 121 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2016-present, Facebook, Inc. +/** + * Copyright 2014-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -26579,38 +23675,20 @@ module.exports = ReactDebugTool; -var warning = __webpack_require__(2); - -if (process.env.NODE_ENV !== 'production') { - var processingChildContext = false; - - var warnInvalidSetState = function () { - process.env.NODE_ENV !== 'production' ? warning(!processingChildContext, 'setState(...): Cannot call setState() inside getChildContext()') : void 0; - }; -} +// The Symbol used to tag the ReactElement type. If there is no native Symbol +// nor polyfill, then a plain number is used for performance. -var ReactInvalidSetStateWarningHook = { - onBeginProcessingChildContext: function () { - processingChildContext = true; - }, - onEndProcessingChildContext: function () { - processingChildContext = false; - }, - onSetState: function () { - warnInvalidSetState(); - } -}; +var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; -module.exports = ReactInvalidSetStateWarningHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = REACT_ELEMENT_TYPE; /***/ }), -/* 147 */ +/* 122 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /** - * Copyright 2016-present, Facebook, Inc. + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -26622,471 +23700,297 @@ module.exports = ReactInvalidSetStateWarningHook; -var history = []; - -var ReactHostOperationHistoryHook = { - onHostOperation: function (operation) { - history.push(operation); - }, - clearHistory: function () { - if (ReactHostOperationHistoryHook._preventClearing) { - // Should only be used for tests. - return; - } - - history = []; - }, - getHistory: function () { - return history; - } -}; - -module.exports = ReactHostOperationHistoryHook; - -/***/ }), -/* 148 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; +/* global Symbol */ +var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; +var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. /** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. + * Returns the iterator method function contained on the iterable object. * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Be sure to invoke the function with the iterable as context: * - * @typechecks - */ - -var performance = __webpack_require__(149); - -var performanceNow; - -/** - * Detect if we can use `window.performance.now()` and gracefully fallback to - * `Date.now()` if it doesn't exist. We need to support Firefox < 15 for now - * because of Facebook's testing infrastructure. + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} */ -if (performance.now) { - performanceNow = function performanceNow() { - return performance.now(); - }; -} else { - performanceNow = function performanceNow() { - return Date.now(); - }; +function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } } -module.exports = performanceNow; +module.exports = getIteratorFn; /***/ }), -/* 149 */ +/* 123 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * @typechecks */ +/** + * ReactElementValidator provides a wrapper around a element factory + * which validates the props passed to the element. This is intended to be + * used only in DEV and could be replaced by a static type checker for languages + * that support it. + */ -var ExecutionEnvironment = __webpack_require__(8); - -var performance; - -if (ExecutionEnvironment.canUseDOM) { - performance = window.performance || window.msPerformance || window.webkitPerformance; -} -module.exports = performance || {}; +var ReactCurrentOwner = __webpack_require__(22); +var ReactComponentTreeHook = __webpack_require__(17); +var ReactElement = __webpack_require__(31); -/***/ }), -/* 150 */ -/***/ (function(module, exports, __webpack_require__) { +var checkReactTypeSpec = __webpack_require__(221); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var canDefineProperty = __webpack_require__(55); +var getIteratorFn = __webpack_require__(122); +var warning = __webpack_require__(3); +var lowPriorityWarning = __webpack_require__(74); +function getDeclarationErrorAddendum() { + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} +function getSourceInfoErrorAddendum(elementProps) { + if (elementProps !== null && elementProps !== undefined && elementProps.__source !== undefined) { + var source = elementProps.__source; + var fileName = source.fileName.replace(/^.*[\\\/]/, ''); + var lineNumber = source.lineNumber; + return ' Check your code at ' + fileName + ':' + lineNumber + '.'; + } + return ''; +} /** - * Module that is injectable into `EventPluginHub`, that specifies a - * deterministic ordering of `EventPlugin`s. A convenient way to reason about - * plugins, without having to package every one of them. This is better than - * having plugins be ordered in the same order that they are injected because - * that ordering would be influenced by the packaging order. - * `ResponderEventPlugin` must occur before `SimpleEventPlugin` so that - * preventing default on events is convenient in `SimpleEventPlugin` handlers. + * Warn if there's no key explicitly set on dynamic arrays of children or + * object keys are not valid. This allows us to keep track of children between + * updates. */ +var ownerHasKeyUseWarning = {}; -var DefaultEventPluginOrder = ['ResponderEventPlugin', 'SimpleEventPlugin', 'TapEventPlugin', 'EnterLeaveEventPlugin', 'ChangeEventPlugin', 'SelectEventPlugin', 'BeforeInputEventPlugin']; - -module.exports = DefaultEventPluginOrder; +function getCurrentComponentErrorInfo(parentType) { + var info = getDeclarationErrorAddendum(); -/***/ }), -/* 151 */ -/***/ (function(module, exports, __webpack_require__) { + if (!info) { + var parentName = typeof parentType === 'string' ? parentType : parentType.displayName || parentType.name; + if (parentName) { + info = ' Check the top-level render call using <' + parentName + '>.'; + } + } + return info; +} -"use strict"; /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Warn if the element doesn't have an explicit key assigned to it. + * This element is in an array. The array could grow and shrink or be + * reordered. All children that haven't already been validated are required to + * have a "key" property assigned to it. Error statuses are cached so a warning + * will only be shown once. * + * @internal + * @param {ReactElement} element Element that requires a key. + * @param {*} parentType element's parent's type. */ +function validateExplicitKey(element, parentType) { + if (!element._store || element._store.validated || element.key != null) { + return; + } + element._store.validated = true; + var memoizer = ownerHasKeyUseWarning.uniqueKey || (ownerHasKeyUseWarning.uniqueKey = {}); - -var EventPropagators = __webpack_require__(31); -var ReactDOMComponentTree = __webpack_require__(6); -var SyntheticMouseEvent = __webpack_require__(42); - -var eventTypes = { - mouseEnter: { - registrationName: 'onMouseEnter', - dependencies: ['topMouseOut', 'topMouseOver'] - }, - mouseLeave: { - registrationName: 'onMouseLeave', - dependencies: ['topMouseOut', 'topMouseOver'] + var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType); + if (memoizer[currentComponentErrorInfo]) { + return; } -}; + memoizer[currentComponentErrorInfo] = true; -var EnterLeaveEventPlugin = { - eventTypes: eventTypes, + // Usually the current owner is the offender, but if it accepts children as a + // property, it may be the creator of the child that's responsible for + // assigning it a key. + var childOwner = ''; + if (element && element._owner && element._owner !== ReactCurrentOwner.current) { + // Give the component that originally created this child. + childOwner = ' It was passed a child from ' + element._owner.getName() + '.'; + } - /** - * For almost every interaction we care about, there will be both a top-level - * `mouseover` and `mouseout` event that occurs. Only use `mouseout` so that - * we do not extract duplicate events. However, moving the mouse into the - * browser from outside will not fire a `mouseout` event. In this case, we use - * the `mouseover` top-level event. - */ - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - if (topLevelType === 'topMouseOver' && (nativeEvent.relatedTarget || nativeEvent.fromElement)) { - return null; - } - if (topLevelType !== 'topMouseOut' && topLevelType !== 'topMouseOver') { - // Must not be a mouse in or mouse out - ignoring. - return null; - } + process.env.NODE_ENV !== 'production' ? warning(false, 'Each child in an array or iterator should have a unique "key" prop.' + '%s%s See https://fb.me/react-warning-keys for more information.%s', currentComponentErrorInfo, childOwner, ReactComponentTreeHook.getCurrentStackAddendum(element)) : void 0; +} - var win; - if (nativeEventTarget.window === nativeEventTarget) { - // `nativeEventTarget` is probably a window object. - win = nativeEventTarget; - } else { - // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. - var doc = nativeEventTarget.ownerDocument; - if (doc) { - win = doc.defaultView || doc.parentWindow; - } else { - win = window; +/** + * Ensure that every element either is passed in a static location, in an + * array with an explicit keys property defined, or in an object literal + * with valid key property. + * + * @internal + * @param {ReactNode} node Statically passed child of any type. + * @param {*} parentType node's parent's type. + */ +function validateChildKeys(node, parentType) { + if (typeof node !== 'object') { + return; + } + if (Array.isArray(node)) { + for (var i = 0; i < node.length; i++) { + var child = node[i]; + if (ReactElement.isValidElement(child)) { + validateExplicitKey(child, parentType); } } - - var from; - var to; - if (topLevelType === 'topMouseOut') { - from = targetInst; - var related = nativeEvent.relatedTarget || nativeEvent.toElement; - to = related ? ReactDOMComponentTree.getClosestInstanceFromNode(related) : null; - } else { - // Moving to a node from outside the window. - from = null; - to = targetInst; + } else if (ReactElement.isValidElement(node)) { + // This element was passed in a valid location. + if (node._store) { + node._store.validated = true; } - - if (from === to) { - // Nothing pertains to our managed components. - return null; + } else if (node) { + var iteratorFn = getIteratorFn(node); + // Entry iterators provide implicit keys. + if (iteratorFn) { + if (iteratorFn !== node.entries) { + var iterator = iteratorFn.call(node); + var step; + while (!(step = iterator.next()).done) { + if (ReactElement.isValidElement(step.value)) { + validateExplicitKey(step.value, parentType); + } + } + } } - - var fromNode = from == null ? win : ReactDOMComponentTree.getNodeFromInstance(from); - var toNode = to == null ? win : ReactDOMComponentTree.getNodeFromInstance(to); - - var leave = SyntheticMouseEvent.getPooled(eventTypes.mouseLeave, from, nativeEvent, nativeEventTarget); - leave.type = 'mouseleave'; - leave.target = fromNode; - leave.relatedTarget = toNode; - - var enter = SyntheticMouseEvent.getPooled(eventTypes.mouseEnter, to, nativeEvent, nativeEventTarget); - enter.type = 'mouseenter'; - enter.target = toNode; - enter.relatedTarget = fromNode; - - EventPropagators.accumulateEnterLeaveDispatches(leave, enter, from, to); - - return [leave, enter]; } -}; - -module.exports = EnterLeaveEventPlugin; - -/***/ }), -/* 152 */ -/***/ (function(module, exports, __webpack_require__) { +} -"use strict"; /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Given an element, validate that its props follow the propTypes definition, + * provided by the type. * + * @param {ReactElement} element */ +function validatePropTypes(element) { + var componentClass = element.type; + if (typeof componentClass !== 'function') { + return; + } + var name = componentClass.displayName || componentClass.name; + if (componentClass.propTypes) { + checkReactTypeSpec(componentClass.propTypes, element.props, 'prop', name, element, null); + } + if (typeof componentClass.getDefaultProps === 'function') { + process.env.NODE_ENV !== 'production' ? warning(componentClass.getDefaultProps.isReactClassApproved, 'getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.') : void 0; + } +} +var ReactElementValidator = { + createElement: function (type, props, children) { + var validType = typeof type === 'string' || typeof type === 'function'; + // We warn in this case but don't throw. We expect the element creation to + // succeed and there will likely be errors in render. + if (!validType) { + if (typeof type !== 'function' && typeof type !== 'string') { + var info = ''; + if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { + info += ' You likely forgot to export your component from the file ' + "it's defined in."; + } + var sourceInfo = getSourceInfoErrorAddendum(props); + if (sourceInfo) { + info += sourceInfo; + } else { + info += getDeclarationErrorAddendum(); + } -var DOMProperty = __webpack_require__(17); + info += ReactComponentTreeHook.getCurrentStackAddendum(); -var MUST_USE_PROPERTY = DOMProperty.injection.MUST_USE_PROPERTY; -var HAS_BOOLEAN_VALUE = DOMProperty.injection.HAS_BOOLEAN_VALUE; -var HAS_NUMERIC_VALUE = DOMProperty.injection.HAS_NUMERIC_VALUE; -var HAS_POSITIVE_NUMERIC_VALUE = DOMProperty.injection.HAS_POSITIVE_NUMERIC_VALUE; -var HAS_OVERLOADED_BOOLEAN_VALUE = DOMProperty.injection.HAS_OVERLOADED_BOOLEAN_VALUE; + var currentSource = props !== null && props !== undefined && props.__source !== undefined ? props.__source : null; + ReactComponentTreeHook.pushNonStandardWarningStack(true, currentSource); + process.env.NODE_ENV !== 'production' ? warning(false, 'React.createElement: type is invalid -- expected a string (for ' + 'built-in components) or a class/function (for composite ' + 'components) but got: %s.%s', type == null ? type : typeof type, info) : void 0; + ReactComponentTreeHook.popNonStandardWarningStack(); + } + } -var HTMLDOMPropertyConfig = { - isCustomAttribute: RegExp.prototype.test.bind(new RegExp('^(data|aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$')), - Properties: { - /** - * Standard Properties - */ - accept: 0, - acceptCharset: 0, - accessKey: 0, - action: 0, - allowFullScreen: HAS_BOOLEAN_VALUE, - allowTransparency: 0, - alt: 0, - // specifies target context for links with `preload` type - as: 0, - async: HAS_BOOLEAN_VALUE, - autoComplete: 0, - // autoFocus is polyfilled/normalized by AutoFocusUtils - // autoFocus: HAS_BOOLEAN_VALUE, - autoPlay: HAS_BOOLEAN_VALUE, - capture: HAS_BOOLEAN_VALUE, - cellPadding: 0, - cellSpacing: 0, - charSet: 0, - challenge: 0, - checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - cite: 0, - classID: 0, - className: 0, - cols: HAS_POSITIVE_NUMERIC_VALUE, - colSpan: 0, - content: 0, - contentEditable: 0, - contextMenu: 0, - controls: HAS_BOOLEAN_VALUE, - coords: 0, - crossOrigin: 0, - data: 0, // For `<object />` acts as `src`. - dateTime: 0, - 'default': HAS_BOOLEAN_VALUE, - defer: HAS_BOOLEAN_VALUE, - dir: 0, - disabled: HAS_BOOLEAN_VALUE, - download: HAS_OVERLOADED_BOOLEAN_VALUE, - draggable: 0, - encType: 0, - form: 0, - formAction: 0, - formEncType: 0, - formMethod: 0, - formNoValidate: HAS_BOOLEAN_VALUE, - formTarget: 0, - frameBorder: 0, - headers: 0, - height: 0, - hidden: HAS_BOOLEAN_VALUE, - high: 0, - href: 0, - hrefLang: 0, - htmlFor: 0, - httpEquiv: 0, - icon: 0, - id: 0, - inputMode: 0, - integrity: 0, - is: 0, - keyParams: 0, - keyType: 0, - kind: 0, - label: 0, - lang: 0, - list: 0, - loop: HAS_BOOLEAN_VALUE, - low: 0, - manifest: 0, - marginHeight: 0, - marginWidth: 0, - max: 0, - maxLength: 0, - media: 0, - mediaGroup: 0, - method: 0, - min: 0, - minLength: 0, - // Caution; `option.selected` is not updated if `select.multiple` is - // disabled with `removeAttribute`. - multiple: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - muted: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - name: 0, - nonce: 0, - noValidate: HAS_BOOLEAN_VALUE, - open: HAS_BOOLEAN_VALUE, - optimum: 0, - pattern: 0, - placeholder: 0, - playsInline: HAS_BOOLEAN_VALUE, - poster: 0, - preload: 0, - profile: 0, - radioGroup: 0, - readOnly: HAS_BOOLEAN_VALUE, - referrerPolicy: 0, - rel: 0, - required: HAS_BOOLEAN_VALUE, - reversed: HAS_BOOLEAN_VALUE, - role: 0, - rows: HAS_POSITIVE_NUMERIC_VALUE, - rowSpan: HAS_NUMERIC_VALUE, - sandbox: 0, - scope: 0, - scoped: HAS_BOOLEAN_VALUE, - scrolling: 0, - seamless: HAS_BOOLEAN_VALUE, - selected: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, - shape: 0, - size: HAS_POSITIVE_NUMERIC_VALUE, - sizes: 0, - span: HAS_POSITIVE_NUMERIC_VALUE, - spellCheck: 0, - src: 0, - srcDoc: 0, - srcLang: 0, - srcSet: 0, - start: HAS_NUMERIC_VALUE, - step: 0, - style: 0, - summary: 0, - tabIndex: 0, - target: 0, - title: 0, - // Setting .type throws on non-<input> tags - type: 0, - useMap: 0, - value: 0, - width: 0, - wmode: 0, - wrap: 0, + var element = ReactElement.createElement.apply(this, arguments); - /** - * RDFa Properties - */ - about: 0, - datatype: 0, - inlist: 0, - prefix: 0, - // property is also supported for OpenGraph in meta tags. - property: 0, - resource: 0, - 'typeof': 0, - vocab: 0, + // The result can be nullish if a mock or a custom function is used. + // TODO: Drop this when these are no longer allowed as the type argument. + if (element == null) { + return element; + } - /** - * Non-standard Properties - */ - // autoCapitalize and autoCorrect are supported in Mobile Safari for - // keyboard hints. - autoCapitalize: 0, - autoCorrect: 0, - // autoSave allows WebKit/Blink to persist values of input fields on page reloads - autoSave: 0, - // color is for Safari mask-icon link - color: 0, - // itemProp, itemScope, itemType are for - // Microdata support. See http://schema.org/docs/gs.html - itemProp: 0, - itemScope: HAS_BOOLEAN_VALUE, - itemType: 0, - // itemID and itemRef are for Microdata support as well but - // only specified in the WHATWG spec document. See - // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api - itemID: 0, - itemRef: 0, - // results show looking glass icon and recent searches on input - // search fields in WebKit/Blink - results: 0, - // IE-only attribute that specifies security restrictions on an iframe - // as an alternative to the sandbox attribute on IE<10 - security: 0, - // IE-only attribute that controls focus behavior - unselectable: 0 - }, - DOMAttributeNames: { - acceptCharset: 'accept-charset', - className: 'class', - htmlFor: 'for', - httpEquiv: 'http-equiv' - }, - DOMPropertyNames: {}, - DOMMutationMethods: { - value: function (node, value) { - if (value == null) { - return node.removeAttribute('value'); + // Skip key warning if the type isn't valid since our key validation logic + // doesn't expect a non-string/function type and can throw confusing errors. + // We don't want exception behavior to differ between dev and prod. + // (Rendering will throw with a helpful message and as soon as the type is + // fixed, the key warnings will appear.) + if (validType) { + for (var i = 2; i < arguments.length; i++) { + validateChildKeys(arguments[i], type); } + } - // Number inputs get special treatment due to some edge cases in - // Chrome. Let everything else assign the value attribute as normal. - // https://github.com/facebook/react/issues/7253#issuecomment-236074326 - if (node.type !== 'number' || node.hasAttribute('value') === false) { - node.setAttribute('value', '' + value); - } else if (node.validity && !node.validity.badInput && node.ownerDocument.activeElement !== node) { - // Don't assign an attribute if validation reports bad - // input. Chrome will clear the value. Additionally, don't - // operate on inputs that have focus, otherwise Chrome might - // strip off trailing decimal places and cause the user's - // cursor position to jump to the beginning of the input. - // - // In ReactDOMInput, we have an onBlur event that will trigger - // this function again when focus is lost. - node.setAttribute('value', '' + value); + validatePropTypes(element); + + return element; + }, + + createFactory: function (type) { + var validatedFactory = ReactElementValidator.createElement.bind(null, type); + // Legacy hook TODO: Warn if this is accessed + validatedFactory.type = type; + + if (process.env.NODE_ENV !== 'production') { + if (canDefineProperty) { + Object.defineProperty(validatedFactory, 'type', { + enumerable: false, + get: function () { + lowPriorityWarning(false, 'Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.'); + Object.defineProperty(this, 'type', { + value: type + }); + return type; + } + }); } } + + return validatedFactory; + }, + + cloneElement: function (element, props, children) { + var newElement = ReactElement.cloneElement.apply(this, arguments); + for (var i = 2; i < arguments.length; i++) { + validateChildKeys(arguments[i], newElement.type); + } + validatePropTypes(newElement); + return newElement; } }; -module.exports = HTMLDOMPropertyConfig; +module.exports = ReactElementValidator; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 153 */ +/* 124 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -27097,29 +24001,24 @@ module.exports = HTMLDOMPropertyConfig; * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. - * */ -var DOMChildrenOperations = __webpack_require__(55); -var ReactDOMIDOperations = __webpack_require__(158); - -/** - * Abstracts away all functionality of the reconciler that requires knowledge of - * the browser context. TODO: These callers should be refactored to avoid the - * need for this injection. - */ -var ReactComponentBrowserEnvironment = { - processChildrenUpdates: ReactDOMIDOperations.dangerouslyProcessChildrenUpdates, - - replaceNodeWithMarkup: DOMChildrenOperations.dangerouslyReplaceNodeWithMarkup +// React 15.5 references this module, and assumes PropTypes are still callable in production. +// Therefore we re-export development-only version with all the PropTypes checks here. +// However if one is migrating to the `prop-types` npm library, they will go through the +// `index.js` entry point, and it will branch depending on the environment. +var factory = __webpack_require__(125); +module.exports = function(isValidElement) { + // It is still allowed in 15.5. + var throwOnDirectAccess = false; + return factory(isValidElement, throwOnDirectAccess); }; -module.exports = ReactComponentBrowserEnvironment; /***/ }), -/* 154 */ +/* 125 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -27130,278 +24029,521 @@ module.exports = ReactComponentBrowserEnvironment; * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. - * */ -var _prodInvariant = __webpack_require__(3); +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); -var DOMLazyTree = __webpack_require__(27); -var ExecutionEnvironment = __webpack_require__(8); +var ReactPropTypesSecret = __webpack_require__(75); +var checkPropTypes = __webpack_require__(225); -var createNodesFromMarkup = __webpack_require__(155); -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); +module.exports = function(isValidElement, throwOnDirectAccess) { + /* global Symbol */ + var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; + var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. -var Danger = { /** - * Replaces a node with a string of markup at its current position within its - * parent. The markup must render into a single root node. + * Returns the iterator method function contained on the iterable object. * - * @param {DOMElement} oldChild Child node to replace. - * @param {string} markup Markup to render in place of the child node. - * @internal + * Be sure to invoke the function with the iterable as context: + * + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} */ - dangerouslyReplaceNodeWithMarkup: function (oldChild, markup) { - !ExecutionEnvironment.canUseDOM ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot render markup in a worker thread. Make sure `window` and `document` are available globally before requiring React when unit testing or use ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('56') : void 0; - !markup ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Missing markup.') : _prodInvariant('57') : void 0; - !(oldChild.nodeName !== 'HTML') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot replace markup of the <html> node. This is because browser quirks make this unreliable and/or slow. If you want to render to the root you must use server rendering. See ReactDOMServer.renderToString().') : _prodInvariant('58') : void 0; + function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } + } - if (typeof markup === 'string') { - var newChild = createNodesFromMarkup(markup, emptyFunction)[0]; - oldChild.parentNode.replaceChild(newChild, oldChild); + /** + * Collection of methods that allow declaration and validation of props that are + * supplied to React components. Example usage: + * + * var Props = require('ReactPropTypes'); + * var MyArticle = React.createClass({ + * propTypes: { + * // An optional string prop named "description". + * description: Props.string, + * + * // A required enum prop named "category". + * category: Props.oneOf(['News','Photos']).isRequired, + * + * // A prop named "dialog" that requires an instance of Dialog. + * dialog: Props.instanceOf(Dialog).isRequired + * }, + * render: function() { ... } + * }); + * + * A more formal specification of how these methods are used: + * + * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...) + * decl := ReactPropTypes.{type}(.isRequired)? + * + * Each and every declaration produces a function with the same signature. This + * allows the creation of custom validation functions. For example: + * + * var MyLink = React.createClass({ + * propTypes: { + * // An optional string or URI prop named "href". + * href: function(props, propName, componentName) { + * var propValue = props[propName]; + * if (propValue != null && typeof propValue !== 'string' && + * !(propValue instanceof URI)) { + * return new Error( + * 'Expected a string or an URI for ' + propName + ' in ' + + * componentName + * ); + * } + * } + * }, + * render: function() {...} + * }); + * + * @internal + */ + + var ANONYMOUS = '<<anonymous>>'; + + // Important! + // Keep this list in sync with production version in `./factoryWithThrowingShims.js`. + var ReactPropTypes = { + array: createPrimitiveTypeChecker('array'), + bool: createPrimitiveTypeChecker('boolean'), + func: createPrimitiveTypeChecker('function'), + number: createPrimitiveTypeChecker('number'), + object: createPrimitiveTypeChecker('object'), + string: createPrimitiveTypeChecker('string'), + symbol: createPrimitiveTypeChecker('symbol'), + + any: createAnyTypeChecker(), + arrayOf: createArrayOfTypeChecker, + element: createElementTypeChecker(), + instanceOf: createInstanceTypeChecker, + node: createNodeChecker(), + objectOf: createObjectOfTypeChecker, + oneOf: createEnumTypeChecker, + oneOfType: createUnionTypeChecker, + shape: createShapeTypeChecker + }; + + /** + * inlined Object.is polyfill to avoid requiring consumers ship their own + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is + */ + /*eslint-disable no-self-compare*/ + function is(x, y) { + // SameValue algorithm + if (x === y) { + // Steps 1-5, 7-10 + // Steps 6.b-6.e: +0 != -0 + return x !== 0 || 1 / x === 1 / y; } else { - DOMLazyTree.replaceChildWithTree(oldChild, markup); + // Step 6.a: NaN == NaN + return x !== x && y !== y; } } -}; + /*eslint-enable no-self-compare*/ -module.exports = Danger; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + /** + * We use an Error-like object for backward compatibility as people may call + * PropTypes directly and inspect their output. However, we don't use real + * Errors anymore. We don't inspect their stack anyway, and creating them + * is prohibitively expensive if they are created too often, such as what + * happens in oneOfType() for any type before the one that matched. + */ + function PropTypeError(message) { + this.message = message; + this.stack = ''; + } + // Make `instanceof Error` still work for returned errors. + PropTypeError.prototype = Error.prototype; -/***/ }), -/* 155 */ -/***/ (function(module, exports, __webpack_require__) { + function createChainableTypeChecker(validate) { + if (process.env.NODE_ENV !== 'production') { + var manualPropTypeCallCache = {}; + var manualPropTypeWarningCount = 0; + } + function checkType(isRequired, props, propName, componentName, location, propFullName, secret) { + componentName = componentName || ANONYMOUS; + propFullName = propFullName || propName; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { + if (secret !== ReactPropTypesSecret) { + if (throwOnDirectAccess) { + // New behavior only for users of `prop-types` package + invariant( + false, + 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + + 'Use `PropTypes.checkPropTypes()` to call them. ' + + 'Read more at http://fb.me/use-check-prop-types' + ); + } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') { + // Old behavior for people using React.PropTypes + var cacheKey = componentName + ':' + propName; + if ( + !manualPropTypeCallCache[cacheKey] && + // Avoid spamming the console because they are often not actionable except for lib authors + manualPropTypeWarningCount < 3 + ) { + warning( + false, + 'You are manually calling a React.PropTypes validation ' + + 'function for the `%s` prop on `%s`. This is deprecated ' + + 'and will throw in the standalone `prop-types` package. ' + + 'You may be seeing this warning due to a third-party PropTypes ' + + 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.', + propFullName, + componentName + ); + manualPropTypeCallCache[cacheKey] = true; + manualPropTypeWarningCount++; + } + } + } + if (props[propName] == null) { + if (isRequired) { + if (props[propName] === null) { + return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.')); + } + return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.')); + } + return null; + } else { + return validate(props, propName, componentName, location, propFullName); + } + } -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + var chainedCheckType = checkType.bind(null, false); + chainedCheckType.isRequired = checkType.bind(null, true); -/*eslint-disable fb-www/unsafe-html*/ + return chainedCheckType; + } -var ExecutionEnvironment = __webpack_require__(8); + function createPrimitiveTypeChecker(expectedType) { + function validate(props, propName, componentName, location, propFullName, secret) { + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== expectedType) { + // `propValue` being instance of, say, date/regexp, pass the 'object' + // check, but we can offer a more precise error message here rather than + // 'of type `object`'. + var preciseType = getPreciseType(propValue); -var createArrayFromMixed = __webpack_require__(156); -var getMarkupWrap = __webpack_require__(157); -var invariant = __webpack_require__(1); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.')); + } + return null; + } + return createChainableTypeChecker(validate); + } -/** - * Dummy container used to render all markup. - */ -var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; + function createAnyTypeChecker() { + return createChainableTypeChecker(emptyFunction.thatReturnsNull); + } -/** - * Pattern used by `getNodeName`. - */ -var nodeNamePattern = /^\s*<(\w+)/; + function createArrayOfTypeChecker(typeChecker) { + function validate(props, propName, componentName, location, propFullName) { + if (typeof typeChecker !== 'function') { + return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.'); + } + var propValue = props[propName]; + if (!Array.isArray(propValue)) { + var propType = getPropType(propValue); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.')); + } + for (var i = 0; i < propValue.length; i++) { + var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret); + if (error instanceof Error) { + return error; + } + } + return null; + } + return createChainableTypeChecker(validate); + } -/** - * Extracts the `nodeName` of the first element in a string of markup. - * - * @param {string} markup String of markup. - * @return {?string} Node name of the supplied markup. - */ -function getNodeName(markup) { - var nodeNameMatch = markup.match(nodeNamePattern); - return nodeNameMatch && nodeNameMatch[1].toLowerCase(); -} + function createElementTypeChecker() { + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + if (!isValidElement(propValue)) { + var propType = getPropType(propValue); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.')); + } + return null; + } + return createChainableTypeChecker(validate); + } -/** - * Creates an array containing the nodes rendered from the supplied markup. The - * optionally supplied `handleScript` function will be invoked once for each - * <script> element that is rendered. If no `handleScript` function is supplied, - * an exception is thrown if any <script> elements are rendered. - * - * @param {string} markup A string of valid HTML markup. - * @param {?function} handleScript Invoked once for each rendered <script>. - * @return {array<DOMElement|DOMTextNode>} An array of rendered nodes. - */ -function createNodesFromMarkup(markup, handleScript) { - var node = dummyNode; - !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup dummy not initialized') : invariant(false) : void 0; - var nodeName = getNodeName(markup); + function createInstanceTypeChecker(expectedClass) { + function validate(props, propName, componentName, location, propFullName) { + if (!(props[propName] instanceof expectedClass)) { + var expectedClassName = expectedClass.name || ANONYMOUS; + var actualClassName = getClassName(props[propName]); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.')); + } + return null; + } + return createChainableTypeChecker(validate); + } - var wrap = nodeName && getMarkupWrap(nodeName); - if (wrap) { - node.innerHTML = wrap[1] + markup + wrap[2]; + function createEnumTypeChecker(expectedValues) { + if (!Array.isArray(expectedValues)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOf, expected an instance of array.') : void 0; + return emptyFunction.thatReturnsNull; + } - var wrapDepth = wrap[0]; - while (wrapDepth--) { - node = node.lastChild; + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + for (var i = 0; i < expectedValues.length; i++) { + if (is(propValue, expectedValues[i])) { + return null; + } + } + + var valuesString = JSON.stringify(expectedValues); + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + propValue + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.')); } - } else { - node.innerHTML = markup; + return createChainableTypeChecker(validate); } - var scripts = node.getElementsByTagName('script'); - if (scripts.length) { - !handleScript ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup(...): Unexpected <script> element rendered.') : invariant(false) : void 0; - createArrayFromMixed(scripts).forEach(handleScript); + function createObjectOfTypeChecker(typeChecker) { + function validate(props, propName, componentName, location, propFullName) { + if (typeof typeChecker !== 'function') { + return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.'); + } + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== 'object') { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.')); + } + for (var key in propValue) { + if (propValue.hasOwnProperty(key)) { + var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); + if (error instanceof Error) { + return error; + } + } + } + return null; + } + return createChainableTypeChecker(validate); } - var nodes = Array.from(node.childNodes); - while (node.lastChild) { - node.removeChild(node.lastChild); - } - return nodes; -} + function createUnionTypeChecker(arrayOfTypeCheckers) { + if (!Array.isArray(arrayOfTypeCheckers)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOfType, expected an instance of array.') : void 0; + return emptyFunction.thatReturnsNull; + } -module.exports = createNodesFromMarkup; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + for (var i = 0; i < arrayOfTypeCheckers.length; i++) { + var checker = arrayOfTypeCheckers[i]; + if (typeof checker !== 'function') { + warning( + false, + 'Invalid argument supplid to oneOfType. Expected an array of check functions, but ' + + 'received %s at index %s.', + getPostfixForTypeWarning(checker), + i + ); + return emptyFunction.thatReturnsNull; + } + } -/***/ }), -/* 156 */ -/***/ (function(module, exports, __webpack_require__) { + function validate(props, propName, componentName, location, propFullName) { + for (var i = 0; i < arrayOfTypeCheckers.length; i++) { + var checker = arrayOfTypeCheckers[i]; + if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) { + return null; + } + } -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.')); + } + return createChainableTypeChecker(validate); + } -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ + function createNodeChecker() { + function validate(props, propName, componentName, location, propFullName) { + if (!isNode(props[propName])) { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.')); + } + return null; + } + return createChainableTypeChecker(validate); + } -var invariant = __webpack_require__(1); + function createShapeTypeChecker(shapeTypes) { + function validate(props, propName, componentName, location, propFullName) { + var propValue = props[propName]; + var propType = getPropType(propValue); + if (propType !== 'object') { + return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.')); + } + for (var key in shapeTypes) { + var checker = shapeTypes[key]; + if (!checker) { + continue; + } + var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret); + if (error) { + return error; + } + } + return null; + } + return createChainableTypeChecker(validate); + } -/** - * Convert array-like objects to arrays. - * - * This API assumes the caller knows the contents of the data type. For less - * well defined inputs use createArrayFromMixed. - * - * @param {object|function|filelist} obj - * @return {array} - */ -function toArray(obj) { - var length = obj.length; + function isNode(propValue) { + switch (typeof propValue) { + case 'number': + case 'string': + case 'undefined': + return true; + case 'boolean': + return !propValue; + case 'object': + if (Array.isArray(propValue)) { + return propValue.every(isNode); + } + if (propValue === null || isValidElement(propValue)) { + return true; + } - // Some browsers builtin objects can report typeof 'function' (e.g. NodeList - // in old versions of Safari). - !(!Array.isArray(obj) && (typeof obj === 'object' || typeof obj === 'function')) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Array-like object expected') : invariant(false) : void 0; + var iteratorFn = getIteratorFn(propValue); + if (iteratorFn) { + var iterator = iteratorFn.call(propValue); + var step; + if (iteratorFn !== propValue.entries) { + while (!(step = iterator.next()).done) { + if (!isNode(step.value)) { + return false; + } + } + } else { + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + if (!isNode(entry[1])) { + return false; + } + } + } + } + } else { + return false; + } - !(typeof length === 'number') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object needs a length property') : invariant(false) : void 0; + return true; + default: + return false; + } + } - !(length === 0 || length - 1 in obj) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object should have keys for indices') : invariant(false) : void 0; + function isSymbol(propType, propValue) { + // Native Symbol. + if (propType === 'symbol') { + return true; + } - !(typeof obj.callee !== 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object can\'t be `arguments`. Use rest params ' + '(function(...args) {}) or Array.from() instead.') : invariant(false) : void 0; + // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol' + if (propValue['@@toStringTag'] === 'Symbol') { + return true; + } - // Old IE doesn't give collections access to hasOwnProperty. Assume inputs - // without method will throw during the slice call and skip straight to the - // fallback. - if (obj.hasOwnProperty) { - try { - return Array.prototype.slice.call(obj); - } catch (e) { - // IE < 9 does not support Array#slice on collections objects + // Fallback for non-spec compliant Symbols which are polyfilled. + if (typeof Symbol === 'function' && propValue instanceof Symbol) { + return true; } + + return false; } - // Fall back to copying key by key. This assumes all keys have a value, - // so will not preserve sparsely populated inputs. - var ret = Array(length); - for (var ii = 0; ii < length; ii++) { - ret[ii] = obj[ii]; + // Equivalent of `typeof` but with special handling for array and regexp. + function getPropType(propValue) { + var propType = typeof propValue; + if (Array.isArray(propValue)) { + return 'array'; + } + if (propValue instanceof RegExp) { + // Old webkits (at least until Android 4.0) return 'function' rather than + // 'object' for typeof a RegExp. We'll normalize this here so that /bla/ + // passes PropTypes.object. + return 'object'; + } + if (isSymbol(propType, propValue)) { + return 'symbol'; + } + return propType; } - return ret; -} -/** - * Perform a heuristic test to determine if an object is "array-like". - * - * A monk asked Joshu, a Zen master, "Has a dog Buddha nature?" - * Joshu replied: "Mu." - * - * This function determines if its argument has "array nature": it returns - * true if the argument is an actual array, an `arguments' object, or an - * HTMLCollection (e.g. node.childNodes or node.getElementsByTagName()). - * - * It will return false for other array-like objects like Filelist. - * - * @param {*} obj - * @return {boolean} - */ -function hasArrayNature(obj) { - return ( - // not null/false - !!obj && ( - // arrays are objects, NodeLists are functions in Safari - typeof obj == 'object' || typeof obj == 'function') && - // quacks like an array - 'length' in obj && - // not window - !('setInterval' in obj) && - // no DOM node should be considered an array-like - // a 'select' element has 'length' and 'item' properties on IE8 - typeof obj.nodeType != 'number' && ( - // a real array - Array.isArray(obj) || - // arguments - 'callee' in obj || - // HTMLCollection/NodeList - 'item' in obj) - ); -} + // This handles more types than `getPropType`. Only used for error messages. + // See `createPrimitiveTypeChecker`. + function getPreciseType(propValue) { + if (typeof propValue === 'undefined' || propValue === null) { + return '' + propValue; + } + var propType = getPropType(propValue); + if (propType === 'object') { + if (propValue instanceof Date) { + return 'date'; + } else if (propValue instanceof RegExp) { + return 'regexp'; + } + } + return propType; + } -/** - * Ensure that the argument is an array by wrapping it in an array if it is not. - * Creates a copy of the argument if it is already an array. - * - * This is mostly useful idiomatically: - * - * var createArrayFromMixed = require('createArrayFromMixed'); - * - * function takesOneOrMoreThings(things) { - * things = createArrayFromMixed(things); - * ... - * } - * - * This allows you to treat `things' as an array, but accept scalars in the API. - * - * If you need to convert an array-like object, like `arguments`, into an array - * use toArray instead. - * - * @param {*} obj - * @return {array} - */ -function createArrayFromMixed(obj) { - if (!hasArrayNature(obj)) { - return [obj]; - } else if (Array.isArray(obj)) { - return obj.slice(); - } else { - return toArray(obj); + // Returns a string that is postfixed to a warning about an invalid type. + // For example, "undefined" or "of type array" + function getPostfixForTypeWarning(value) { + var type = getPreciseType(value); + switch (type) { + case 'array': + case 'object': + return 'an ' + type; + case 'boolean': + case 'date': + case 'regexp': + return 'a ' + type; + default: + return type; + } } -} -module.exports = createArrayFromMixed; + // Returns class name of the object, if any. + function getClassName(propValue) { + if (!propValue.constructor || !propValue.constructor.name) { + return ANONYMOUS; + } + return propValue.constructor.name; + } + + ReactPropTypes.checkPropTypes = checkPropTypes; + ReactPropTypes.PropTypes = ReactPropTypes; + + return ReactPropTypes; +}; + /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 157 */ +/* 126 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) { - /** - * Copyright (c) 2013-present, Facebook, Inc. + * Copyright 2015-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -27410,92 +24552,80 @@ module.exports = createArrayFromMixed; * */ -/*eslint-disable fb-www/unsafe-html */ -var ExecutionEnvironment = __webpack_require__(8); -var invariant = __webpack_require__(1); +var ReactDOMComponentFlags = { + hasCachedChildNodes: 1 << 0 +}; + +module.exports = ReactDOMComponentFlags; -/** - * Dummy container used to detect which wraps are necessary. - */ -var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; +/***/ }), +/* 127 */ +/***/ (function(module, exports, __webpack_require__) { -/** - * Some browsers cannot use `innerHTML` to render certain elements standalone, - * so we wrap them, render the wrapped nodes, then extract the desired node. +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. * - * In IE8, certain elements cannot render alone, so wrap all elements ('*'). + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * */ -var shouldWrap = {}; - -var selectWrap = [1, '<select multiple="true">', '</select>']; -var tableWrap = [1, '<table>', '</table>']; -var trWrap = [3, '<table><tbody><tr>', '</tr></tbody></table>']; - -var svgWrap = [1, '<svg xmlns="http://www.w3.org/2000/svg">', '</svg>']; - -var markupWrap = { - '*': [1, '?<div>', '</div>'], - - 'area': [1, '<map>', '</map>'], - 'col': [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>'], - 'legend': [1, '<fieldset>', '</fieldset>'], - 'param': [1, '<object>', '</object>'], - 'tr': [2, '<table><tbody>', '</tbody></table>'], - 'optgroup': selectWrap, - 'option': selectWrap, - - 'caption': tableWrap, - 'colgroup': tableWrap, - 'tbody': tableWrap, - 'tfoot': tableWrap, - 'thead': tableWrap, - 'td': trWrap, - 'th': trWrap -}; +var _prodInvariant = __webpack_require__(5); -// Initialize the SVG elements since we know they'll always need to be wrapped -// consistently. If they are created inside a <div> they will be initialized in -// the wrong namespace (and will not display). -var svgElements = ['circle', 'clipPath', 'defs', 'ellipse', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'text', 'tspan']; -svgElements.forEach(function (nodeName) { - markupWrap[nodeName] = svgWrap; - shouldWrap[nodeName] = true; -}); +var invariant = __webpack_require__(2); /** - * Gets the markup wrap configuration for the supplied `nodeName`. + * Accumulates items that must not be null or undefined into the first one. This + * is used to conserve memory by avoiding array allocations, and thus sacrifices + * API cleanness. Since `current` can be null before being passed in and not + * null after this function, make sure to assign it back to `current`: * - * NOTE: This lazily detects which wraps are necessary for the current browser. + * `a = accumulateInto(a, b);` * - * @param {string} nodeName Lowercase `nodeName`. - * @return {?array} Markup wrap configuration, if applicable. + * This API should be sparingly used. Try `accumulate` for something cleaner. + * + * @return {*|array<*>} An accumulation of items. */ -function getMarkupWrap(nodeName) { - !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Markup wrapping node not initialized') : invariant(false) : void 0; - if (!markupWrap.hasOwnProperty(nodeName)) { - nodeName = '*'; + +function accumulateInto(current, next) { + !(next != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'accumulateInto(...): Accumulated items must not be null or undefined.') : _prodInvariant('30') : void 0; + + if (current == null) { + return next; } - if (!shouldWrap.hasOwnProperty(nodeName)) { - if (nodeName === '*') { - dummyNode.innerHTML = '<link />'; - } else { - dummyNode.innerHTML = '<' + nodeName + '></' + nodeName + '>'; + + // Both are not empty. Warning: Never call x.concat(y) when you are not + // certain that x is an Array (x could be a string with concat method). + if (Array.isArray(current)) { + if (Array.isArray(next)) { + current.push.apply(current, next); + return current; } - shouldWrap[nodeName] = !dummyNode.firstChild; + current.push(next); + return current; } - return shouldWrap[nodeName] ? markupWrap[nodeName] : null; + + if (Array.isArray(next)) { + // A bit too dangerous to mutate `next`. + return [current].concat(next); + } + + return [current, next]; } -module.exports = getMarkupWrap; +module.exports = accumulateInto; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 158 */ +/* 128 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -27507,37 +24637,35 @@ module.exports = getMarkupWrap; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -var DOMChildrenOperations = __webpack_require__(55); -var ReactDOMComponentTree = __webpack_require__(6); - /** - * Operations used to process updates to DOM nodes. + * @param {array} arr an "accumulation" of items which is either an Array or + * a single item. Useful when paired with the `accumulate` module. This is a + * simple utility that allows us to reason about a collection of items, but + * handling the case when there is exactly one item (and we do not need to + * allocate an array). */ -var ReactDOMIDOperations = { - /** - * Updates a component's children by processing a series of updates. - * - * @param {array<object>} updates List of update configurations. - * @internal - */ - dangerouslyProcessChildrenUpdates: function (parentInst, updates) { - var node = ReactDOMComponentTree.getNodeFromInstance(parentInst); - DOMChildrenOperations.processUpdates(node, updates); + +function forEachAccumulated(arr, cb, scope) { + if (Array.isArray(arr)) { + arr.forEach(cb, scope); + } else if (arr) { + cb.call(scope, arr); } -}; +} -module.exports = ReactDOMIDOperations; +module.exports = forEachAccumulated; /***/ }), -/* 159 */ +/* 129 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** +/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -27547,1009 +24675,397 @@ module.exports = ReactDOMIDOperations; * */ -/* global hasOwnProperty:true */ - - - -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); - -var AutoFocusUtils = __webpack_require__(160); -var CSSPropertyOperations = __webpack_require__(161); -var DOMLazyTree = __webpack_require__(27); -var DOMNamespaces = __webpack_require__(56); -var DOMProperty = __webpack_require__(17); -var DOMPropertyOperations = __webpack_require__(93); -var EventPluginHub = __webpack_require__(32); -var EventPluginRegistry = __webpack_require__(40); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactDOMComponentFlags = __webpack_require__(81); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMInput = __webpack_require__(171); -var ReactDOMOption = __webpack_require__(172); -var ReactDOMSelect = __webpack_require__(95); -var ReactDOMTextarea = __webpack_require__(173); -var ReactInstrumentation = __webpack_require__(13); -var ReactMultiChild = __webpack_require__(174); -var ReactServerRenderingTransaction = __webpack_require__(183); - -var emptyFunction = __webpack_require__(12); -var escapeTextContentForBrowser = __webpack_require__(44); -var invariant = __webpack_require__(1); -var isEventSupported = __webpack_require__(53); -var shallowEqual = __webpack_require__(60); -var inputValueTracking = __webpack_require__(87); -var validateDOMNesting = __webpack_require__(64); -var warning = __webpack_require__(2); -var Flags = ReactDOMComponentFlags; -var deleteListener = EventPluginHub.deleteListener; -var getNode = ReactDOMComponentTree.getNodeFromInstance; -var listenTo = ReactBrowserEventEmitter.listenTo; -var registrationNameModules = EventPluginRegistry.registrationNameModules; - -// For quickly matching children type, to test if can be treated as content. -var CONTENT_TYPES = { string: true, number: true }; -var STYLE = 'style'; -var HTML = '__html'; -var RESERVED_PROPS = { - children: null, - dangerouslySetInnerHTML: null, - suppressContentEditableWarning: null -}; +var ExecutionEnvironment = __webpack_require__(13); -// Node type for document fragments (Node.DOCUMENT_FRAGMENT_NODE). -var DOC_FRAGMENT_TYPE = 11; +var contentKey = null; -function getDeclarationErrorAddendum(internalInstance) { - if (internalInstance) { - var owner = internalInstance._currentElement._owner || null; - if (owner) { - var name = owner.getName(); - if (name) { - return ' This DOM node was rendered by `' + name + '`.'; - } - } +/** + * Gets the key used to access text content on a DOM node. + * + * @return {?string} Key used to access text content. + * @internal + */ +function getTextContentAccessor() { + if (!contentKey && ExecutionEnvironment.canUseDOM) { + // Prefer textContent to innerText because many browsers support both but + // SVG <text> elements don't support innerText even when <div> does. + contentKey = 'textContent' in document.documentElement ? 'textContent' : 'innerText'; } - return ''; + return contentKey; } -function friendlyStringify(obj) { - if (typeof obj === 'object') { - if (Array.isArray(obj)) { - return '[' + obj.map(friendlyStringify).join(', ') + ']'; - } else { - var pairs = []; - for (var key in obj) { - if (Object.prototype.hasOwnProperty.call(obj, key)) { - var keyEscaped = /^[a-z$_][\w$_]*$/i.test(key) ? key : JSON.stringify(key); - pairs.push(keyEscaped + ': ' + friendlyStringify(obj[key])); - } - } - return '{' + pairs.join(', ') + '}'; - } - } else if (typeof obj === 'string') { - return JSON.stringify(obj); - } else if (typeof obj === 'function') { - return '[function object]'; - } - // Differs from JSON.stringify in that undefined because undefined and that - // inf and nan don't become null - return String(obj); -} +module.exports = getTextContentAccessor; -var styleMutationWarning = {}; +/***/ }), +/* 130 */ +/***/ (function(module, exports, __webpack_require__) { -function checkAndWarnForMutatedStyle(style1, style2, component) { - if (style1 == null || style2 == null) { - return; - } - if (shallowEqual(style1, style2)) { - return; - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - var componentName = component._tag; - var owner = component._currentElement._owner; - var ownerName; - if (owner) { - ownerName = owner.getName(); - } - var hash = ownerName + '|' + componentName; - if (styleMutationWarning.hasOwnProperty(hash)) { - return; - } +var _prodInvariant = __webpack_require__(5); - styleMutationWarning[hash] = true; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - process.env.NODE_ENV !== 'production' ? warning(false, '`%s` was passed a style object that has previously been mutated. ' + 'Mutating `style` is deprecated. Consider cloning it beforehand. Check ' + 'the `render` %s. Previous style: %s. Mutated style: %s.', componentName, owner ? 'of `' + ownerName + '`' : 'using <' + componentName + '>', friendlyStringify(style1), friendlyStringify(style2)) : void 0; -} +var PooledClass = __webpack_require__(32); + +var invariant = __webpack_require__(2); /** - * @param {object} component - * @param {?object} props + * A specialized pseudo-event module to help keep track of components waiting to + * be notified when their DOM representations are available for use. + * + * This implements `PooledClass`, so you should never need to instantiate this. + * Instead, use `CallbackQueue.getPooled()`. + * + * @class ReactMountReady + * @implements PooledClass + * @internal */ -function assertValidProps(component, props) { - if (!props) { - return; - } - // Note the use of `==` which checks for null or undefined. - if (voidElementTags[component._tag]) { - !(props.children == null && props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.%s', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : _prodInvariant('137', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : void 0; - } - if (props.dangerouslySetInnerHTML != null) { - !(props.children == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Can only set one of `children` or `props.dangerouslySetInnerHTML`.') : _prodInvariant('60') : void 0; - !(typeof props.dangerouslySetInnerHTML === 'object' && HTML in props.dangerouslySetInnerHTML) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.') : _prodInvariant('61') : void 0; - } - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(props.innerHTML == null, 'Directly setting property `innerHTML` is not permitted. ' + 'For more information, lookup documentation on `dangerouslySetInnerHTML`.') : void 0; - process.env.NODE_ENV !== 'production' ? warning(props.suppressContentEditableWarning || !props.contentEditable || props.children == null, 'A component is `contentEditable` and contains `children` managed by ' + 'React. It is now your responsibility to guarantee that none of ' + 'those nodes are unexpectedly modified or duplicated. This is ' + 'probably not intentional.') : void 0; - process.env.NODE_ENV !== 'production' ? warning(props.onFocusIn == null && props.onFocusOut == null, 'React uses onFocus and onBlur instead of onFocusIn and onFocusOut. ' + 'All React events are normalized to bubble, so onFocusIn and onFocusOut ' + 'are not needed/supported by React.') : void 0; - } - !(props.style == null || typeof props.style === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + \'em\'}} when using JSX.%s', getDeclarationErrorAddendum(component)) : _prodInvariant('62', getDeclarationErrorAddendum(component)) : void 0; -} -function enqueuePutListener(inst, registrationName, listener, transaction) { - if (transaction instanceof ReactServerRenderingTransaction) { - return; - } - if (process.env.NODE_ENV !== 'production') { - // IE8 has no API for event capturing and the `onScroll` event doesn't - // bubble. - process.env.NODE_ENV !== 'production' ? warning(registrationName !== 'onScroll' || isEventSupported('scroll', true), "This browser doesn't support the `onScroll` event") : void 0; +var CallbackQueue = function () { + function CallbackQueue(arg) { + _classCallCheck(this, CallbackQueue); + + this._callbacks = null; + this._contexts = null; + this._arg = arg; } - var containerInfo = inst._hostContainerInfo; - var isDocumentFragment = containerInfo._node && containerInfo._node.nodeType === DOC_FRAGMENT_TYPE; - var doc = isDocumentFragment ? containerInfo._node : containerInfo._ownerDocument; - listenTo(registrationName, doc); - transaction.getReactMountReady().enqueue(putListener, { - inst: inst, - registrationName: registrationName, - listener: listener - }); -} -function putListener() { - var listenerToPut = this; - EventPluginHub.putListener(listenerToPut.inst, listenerToPut.registrationName, listenerToPut.listener); -} + /** + * Enqueues a callback to be invoked when `notifyAll` is invoked. + * + * @param {function} callback Invoked when `notifyAll` is invoked. + * @param {?object} context Context to call `callback` with. + * @internal + */ -function inputPostMount() { - var inst = this; - ReactDOMInput.postMountWrapper(inst); -} -function textareaPostMount() { - var inst = this; - ReactDOMTextarea.postMountWrapper(inst); -} + CallbackQueue.prototype.enqueue = function enqueue(callback, context) { + this._callbacks = this._callbacks || []; + this._callbacks.push(callback); + this._contexts = this._contexts || []; + this._contexts.push(context); + }; -function optionPostMount() { - var inst = this; - ReactDOMOption.postMountWrapper(inst); -} + /** + * Invokes all enqueued callbacks and clears the queue. This is invoked after + * the DOM representation of a component has been created or updated. + * + * @internal + */ -var setAndValidateContentChildDev = emptyFunction; -if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev = function (content) { - var hasExistingContent = this._contentDebugID != null; - var debugID = this._debugID; - // This ID represents the inlined child that has no backing instance: - var contentDebugID = -debugID; - if (content == null) { - if (hasExistingContent) { - ReactInstrumentation.debugTool.onUnmountComponent(this._contentDebugID); + CallbackQueue.prototype.notifyAll = function notifyAll() { + var callbacks = this._callbacks; + var contexts = this._contexts; + var arg = this._arg; + if (callbacks && contexts) { + !(callbacks.length === contexts.length) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Mismatched list of contexts in callback queue') : _prodInvariant('24') : void 0; + this._callbacks = null; + this._contexts = null; + for (var i = 0; i < callbacks.length; i++) { + callbacks[i].call(contexts[i], arg); } - this._contentDebugID = null; - return; + callbacks.length = 0; + contexts.length = 0; } + }; - validateDOMNesting(null, String(content), this, this._ancestorInfo); - this._contentDebugID = contentDebugID; - if (hasExistingContent) { - ReactInstrumentation.debugTool.onBeforeUpdateComponent(contentDebugID, content); - ReactInstrumentation.debugTool.onUpdateComponent(contentDebugID); - } else { - ReactInstrumentation.debugTool.onBeforeMountComponent(contentDebugID, content, debugID); - ReactInstrumentation.debugTool.onMountComponent(contentDebugID); - ReactInstrumentation.debugTool.onSetChildren(debugID, [contentDebugID]); + CallbackQueue.prototype.checkpoint = function checkpoint() { + return this._callbacks ? this._callbacks.length : 0; + }; + + CallbackQueue.prototype.rollback = function rollback(len) { + if (this._callbacks && this._contexts) { + this._callbacks.length = len; + this._contexts.length = len; } }; -} -// There are so many media events, it makes sense to just -// maintain a list rather than create a `trapBubbledEvent` for each -var mediaEvents = { - topAbort: 'abort', - topCanPlay: 'canplay', - topCanPlayThrough: 'canplaythrough', - topDurationChange: 'durationchange', - topEmptied: 'emptied', - topEncrypted: 'encrypted', - topEnded: 'ended', - topError: 'error', - topLoadedData: 'loadeddata', - topLoadedMetadata: 'loadedmetadata', - topLoadStart: 'loadstart', - topPause: 'pause', - topPlay: 'play', - topPlaying: 'playing', - topProgress: 'progress', - topRateChange: 'ratechange', - topSeeked: 'seeked', - topSeeking: 'seeking', - topStalled: 'stalled', - topSuspend: 'suspend', - topTimeUpdate: 'timeupdate', - topVolumeChange: 'volumechange', - topWaiting: 'waiting' -}; + /** + * Resets the internal queue. + * + * @internal + */ -function trackInputValue() { - inputValueTracking.track(this); -} -function trapBubbledEventsLocal() { - var inst = this; - // If a component renders to null or if another component fatals and causes - // the state of the tree to be corrupted, `node` here can be null. - !inst._rootNodeID ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Must be mounted to trap events') : _prodInvariant('63') : void 0; - var node = getNode(inst); - !node ? process.env.NODE_ENV !== 'production' ? invariant(false, 'trapBubbledEvent(...): Requires node to be rendered.') : _prodInvariant('64') : void 0; + CallbackQueue.prototype.reset = function reset() { + this._callbacks = null; + this._contexts = null; + }; - switch (inst._tag) { - case 'iframe': - case 'object': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; - break; - case 'video': - case 'audio': - inst._wrapperState.listeners = []; - // Create listener for each media event - for (var event in mediaEvents) { - if (mediaEvents.hasOwnProperty(event)) { - inst._wrapperState.listeners.push(ReactBrowserEventEmitter.trapBubbledEvent(event, mediaEvents[event], node)); - } - } - break; - case 'source': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node)]; - break; - case 'img': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node), ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; - break; - case 'form': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topReset', 'reset', node), ReactBrowserEventEmitter.trapBubbledEvent('topSubmit', 'submit', node)]; - break; - case 'input': - case 'select': - case 'textarea': - inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topInvalid', 'invalid', node)]; - break; - } -} + /** + * `PooledClass` looks for this. + */ -function postUpdateSelectWrapper() { - ReactDOMSelect.postUpdateWrapper(this); -} -// For HTML, certain tags should omit their close tag. We keep a whitelist for -// those special-case tags. + CallbackQueue.prototype.destructor = function destructor() { + this.reset(); + }; -var omittedCloseTags = { - area: true, - base: true, - br: true, - col: true, - embed: true, - hr: true, - img: true, - input: true, - keygen: true, - link: true, - meta: true, - param: true, - source: true, - track: true, - wbr: true - // NOTE: menuitem's close tag should be omitted, but that causes problems. -}; + return CallbackQueue; +}(); -var newlineEatingTags = { - listing: true, - pre: true, - textarea: true -}; +module.exports = PooledClass.addPoolingTo(CallbackQueue); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -// For HTML, certain tags cannot have children. This has the same purpose as -// `omittedCloseTags` except that `menuitem` should still have its closing tag. +/***/ }), +/* 131 */ +/***/ (function(module, exports, __webpack_require__) { -var voidElementTags = _assign({ - menuitem: true -}, omittedCloseTags); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -// We accept any tag to be rendered but since this gets injected into arbitrary -// HTML, we want to make sure that it's a safe tag. -// http://www.w3.org/TR/REC-xml/#NT-Name -var VALID_TAG_REGEX = /^[a-zA-Z][a-zA-Z:_\.\-\d]*$/; // Simplified subset -var validatedTagCache = {}; -var hasOwnProperty = {}.hasOwnProperty; -function validateDangerousTag(tag) { - if (!hasOwnProperty.call(validatedTagCache, tag)) { - !VALID_TAG_REGEX.test(tag) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Invalid tag: %s', tag) : _prodInvariant('65', tag) : void 0; - validatedTagCache[tag] = true; - } -} +var ReactFeatureFlags = { + // When true, call console.time() before and .timeEnd() after each top-level + // render (both initial renders and updates). Useful when looking at prod-mode + // timeline profiles in Chrome, for example. + logTopLevelRenders: false +}; -function isCustomComponent(tagName, props) { - return tagName.indexOf('-') >= 0 || props.is != null; -} +module.exports = ReactFeatureFlags; -var globalIdCounter = 1; +/***/ }), +/* 132 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; /** - * Creates a new React class that is idempotent and capable of containing other - * React components. It accepts event listeners and DOM properties that are - * valid according to `DOMProperty`. - * - * - Event listeners: `onClick`, `onMouseDown`, etc. - * - DOM properties: `className`, `name`, `title`, etc. + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. * - * The `style` property functions differently from the DOM API. It accepts an - * object mapping of style properties to values. + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. * - * @constructor ReactDOMComponent - * @extends ReactMultiChild */ -function ReactDOMComponent(element) { - var tag = element.type; - validateDangerousTag(tag); - this._currentElement = element; - this._tag = tag.toLowerCase(); - this._namespaceURI = null; - this._renderedChildren = null; - this._previousStyle = null; - this._previousStyleCopy = null; - this._hostNode = null; - this._hostParent = null; - this._rootNodeID = 0; - this._domID = 0; - this._hostContainerInfo = null; - this._wrapperState = null; - this._topLevelWrapper = null; - this._flags = 0; - if (process.env.NODE_ENV !== 'production') { - this._ancestorInfo = null; - setAndValidateContentChildDev.call(this, null); - } + + + +var ReactDOMComponentTree = __webpack_require__(10); + +function isCheckable(elem) { + var type = elem.type; + var nodeName = elem.nodeName; + return nodeName && nodeName.toLowerCase() === 'input' && (type === 'checkbox' || type === 'radio'); } -ReactDOMComponent.displayName = 'ReactDOMComponent'; +function getTracker(inst) { + return inst._wrapperState.valueTracker; +} -ReactDOMComponent.Mixin = { - /** - * Generates root tag markup then recurses. This method has side effects and - * is not idempotent. - * - * @internal - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?ReactDOMComponent} the parent component instance - * @param {?object} info about the host container - * @param {object} context - * @return {string} The computed markup. - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - this._rootNodeID = globalIdCounter++; - this._domID = hostContainerInfo._idCounter++; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; +function attachTracker(inst, tracker) { + inst._wrapperState.valueTracker = tracker; +} - var props = this._currentElement.props; +function detachTracker(inst) { + delete inst._wrapperState.valueTracker; +} - switch (this._tag) { - case 'audio': - case 'form': - case 'iframe': - case 'img': - case 'link': - case 'object': - case 'source': - case 'video': - this._wrapperState = { - listeners: null - }; - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'input': - ReactDOMInput.mountWrapper(this, props, hostParent); - props = ReactDOMInput.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trackInputValue, this); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'option': - ReactDOMOption.mountWrapper(this, props, hostParent); - props = ReactDOMOption.getHostProps(this, props); - break; - case 'select': - ReactDOMSelect.mountWrapper(this, props, hostParent); - props = ReactDOMSelect.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - case 'textarea': - ReactDOMTextarea.mountWrapper(this, props, hostParent); - props = ReactDOMTextarea.getHostProps(this, props); - transaction.getReactMountReady().enqueue(trackInputValue, this); - transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); - break; - } +function getValueFromNode(node) { + var value; + if (node) { + value = isCheckable(node) ? '' + node.checked : node.value; + } + return value; +} - assertValidProps(this, props); +var inputValueTracking = { + // exposed for testing + _getTrackerFromNode: function (node) { + return getTracker(ReactDOMComponentTree.getInstanceFromNode(node)); + }, - // We create tags in the namespace of their parent container, except HTML - // tags get no namespace. - var namespaceURI; - var parentTag; - if (hostParent != null) { - namespaceURI = hostParent._namespaceURI; - parentTag = hostParent._tag; - } else if (hostContainerInfo._tag) { - namespaceURI = hostContainerInfo._namespaceURI; - parentTag = hostContainerInfo._tag; - } - if (namespaceURI == null || namespaceURI === DOMNamespaces.svg && parentTag === 'foreignobject') { - namespaceURI = DOMNamespaces.html; + + track: function (inst) { + if (getTracker(inst)) { + return; } - if (namespaceURI === DOMNamespaces.html) { - if (this._tag === 'svg') { - namespaceURI = DOMNamespaces.svg; - } else if (this._tag === 'math') { - namespaceURI = DOMNamespaces.mathml; - } + + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var valueField = isCheckable(node) ? 'checked' : 'value'; + var descriptor = Object.getOwnPropertyDescriptor(node.constructor.prototype, valueField); + + var currentValue = '' + node[valueField]; + + // if someone has already defined a value or Safari, then bail + // and don't track value will cause over reporting of changes, + // but it's better then a hard failure + // (needed for certain tests that spyOn input values and Safari) + if (node.hasOwnProperty(valueField) || typeof descriptor.get !== 'function' || typeof descriptor.set !== 'function') { + return; } - this._namespaceURI = namespaceURI; - if (process.env.NODE_ENV !== 'production') { - var parentInfo; - if (hostParent != null) { - parentInfo = hostParent._ancestorInfo; - } else if (hostContainerInfo._tag) { - parentInfo = hostContainerInfo._ancestorInfo; + Object.defineProperty(node, valueField, { + enumerable: descriptor.enumerable, + configurable: true, + get: function () { + return descriptor.get.call(this); + }, + set: function (value) { + currentValue = '' + value; + descriptor.set.call(this, value); } - if (parentInfo) { - // parentInfo should always be present except for the top-level - // component when server rendering - validateDOMNesting(this._tag, null, this, parentInfo); + }); + + attachTracker(inst, { + getValue: function () { + return currentValue; + }, + setValue: function (value) { + currentValue = '' + value; + }, + stopTracking: function () { + detachTracker(inst); + delete node[valueField]; } - this._ancestorInfo = validateDOMNesting.updatedAncestorInfo(parentInfo, this._tag, this); + }); + }, + + updateValueIfChanged: function (inst) { + if (!inst) { + return false; } + var tracker = getTracker(inst); - var mountImage; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var el; - if (namespaceURI === DOMNamespaces.html) { - if (this._tag === 'script') { - // Create the script via .innerHTML so its "parser-inserted" flag is - // set to true and it does not execute - var div = ownerDocument.createElement('div'); - var type = this._currentElement.type; - div.innerHTML = '<' + type + '></' + type + '>'; - el = div.removeChild(div.firstChild); - } else if (props.is) { - el = ownerDocument.createElement(this._currentElement.type, props.is); - } else { - // Separate else branch instead of using `props.is || undefined` above becuase of a Firefox bug. - // See discussion in https://github.com/facebook/react/pull/6896 - // and discussion in https://bugzilla.mozilla.org/show_bug.cgi?id=1276240 - el = ownerDocument.createElement(this._currentElement.type); - } - } else { - el = ownerDocument.createElementNS(namespaceURI, this._currentElement.type); - } - ReactDOMComponentTree.precacheNode(this, el); - this._flags |= Flags.hasCachedChildNodes; - if (!this._hostParent) { - DOMPropertyOperations.setAttributeForRoot(el); - } - this._updateDOMProperties(null, props, transaction); - var lazyTree = DOMLazyTree(el); - this._createInitialChildren(transaction, props, context, lazyTree); - mountImage = lazyTree; - } else { - var tagOpen = this._createOpenTagMarkupAndPutListeners(transaction, props); - var tagContent = this._createContentMarkup(transaction, props, context); - if (!tagContent && omittedCloseTags[this._tag]) { - mountImage = tagOpen + '/>'; - } else { - mountImage = tagOpen + '>' + tagContent + '</' + this._currentElement.type + '>'; - } + if (!tracker) { + inputValueTracking.track(inst); + return true; } - switch (this._tag) { - case 'input': - transaction.getReactMountReady().enqueue(inputPostMount, this); - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'textarea': - transaction.getReactMountReady().enqueue(textareaPostMount, this); - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'select': - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'button': - if (props.autoFocus) { - transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); - } - break; - case 'option': - transaction.getReactMountReady().enqueue(optionPostMount, this); - break; + var lastValue = tracker.getValue(); + var nextValue = getValueFromNode(ReactDOMComponentTree.getNodeFromInstance(inst)); + + if (nextValue !== lastValue) { + tracker.setValue(nextValue); + return true; } - return mountImage; + return false; }, + stopTracking: function (inst) { + var tracker = getTracker(inst); + if (tracker) { + tracker.stopTracking(); + } + } +}; - /** - * Creates markup for the open tag and all attributes. - * - * This method has side effects because events get registered. - * - * Iterating over object properties is faster than iterating over arrays. - * @see http://jsperf.com/obj-vs-arr-iteration - * - * @private - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} props - * @return {string} Markup of opening tag. - */ - _createOpenTagMarkupAndPutListeners: function (transaction, props) { - var ret = '<' + this._currentElement.type; +module.exports = inputValueTracking; - for (var propKey in props) { - if (!props.hasOwnProperty(propKey)) { - continue; - } - var propValue = props[propKey]; - if (propValue == null) { - continue; - } - if (registrationNameModules.hasOwnProperty(propKey)) { - if (propValue) { - enqueuePutListener(this, propKey, propValue, transaction); - } - } else { - if (propKey === STYLE) { - if (propValue) { - if (process.env.NODE_ENV !== 'production') { - // See `_updateDOMProperties`. style block - this._previousStyle = propValue; - } - propValue = this._previousStyleCopy = _assign({}, props.style); - } - propValue = CSSPropertyOperations.createMarkupForStyles(propValue, this); - } - var markup = null; - if (this._tag != null && isCustomComponent(this._tag, props)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - markup = DOMPropertyOperations.createMarkupForCustomAttribute(propKey, propValue); - } - } else { - markup = DOMPropertyOperations.createMarkupForProperty(propKey, propValue); - } - if (markup) { - ret += ' ' + markup; - } - } - } +/***/ }), +/* 133 */ +/***/ (function(module, exports, __webpack_require__) { - // For static pages, no need to put React ID and checksum. Saves lots of - // bytes. - if (transaction.renderToStaticMarkup) { - return ret; - } +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - if (!this._hostParent) { - ret += ' ' + DOMPropertyOperations.createMarkupForRoot(); - } - ret += ' ' + DOMPropertyOperations.createMarkupForID(this._domID); - return ret; - }, - /** - * Creates markup for the content between the tags. - * - * @private - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} props - * @param {object} context - * @return {string} Content markup. - */ - _createContentMarkup: function (transaction, props, context) { - var ret = ''; - // Intentional use of != to avoid catching zero/false. - var innerHTML = props.dangerouslySetInnerHTML; - if (innerHTML != null) { - if (innerHTML.__html != null) { - ret = innerHTML.__html; - } - } else { - var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; - var childrenToUse = contentToUse != null ? null : props.children; - if (contentToUse != null) { - // TODO: Validate that text is allowed as a child of this node - ret = escapeTextContentForBrowser(contentToUse); - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, contentToUse); - } - } else if (childrenToUse != null) { - var mountImages = this.mountChildren(childrenToUse, transaction, context); - ret = mountImages.join(''); - } - } - if (newlineEatingTags[this._tag] && ret.charAt(0) === '\n') { - // text/html ignores the first character in these tags if it's a newline - // Prefer to break application/xml over text/html (for now) by adding - // a newline specifically to get eaten by the parser. (Alternately for - // textareas, replacing "^\n" with "\r\n" doesn't get eaten, and the first - // \r is normalized out by HTMLTextAreaElement#value.) - // See: <http://www.w3.org/TR/html-polyglot/#newlines-in-textarea-and-pre> - // See: <http://www.w3.org/TR/html5/syntax.html#element-restrictions> - // See: <http://www.w3.org/TR/html5/syntax.html#newlines> - // See: Parsing of "textarea" "listing" and "pre" elements - // from <http://www.w3.org/TR/html5/syntax.html#parsing-main-inbody> - return '\n' + ret; - } else { - return ret; - } - }, - - _createInitialChildren: function (transaction, props, context, lazyTree) { - // Intentional use of != to avoid catching zero/false. - var innerHTML = props.dangerouslySetInnerHTML; - if (innerHTML != null) { - if (innerHTML.__html != null) { - DOMLazyTree.queueHTML(lazyTree, innerHTML.__html); - } - } else { - var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; - var childrenToUse = contentToUse != null ? null : props.children; - // TODO: Validate that text is allowed as a child of this node - if (contentToUse != null) { - // Avoid setting textContent when the text is empty. In IE11 setting - // textContent on a text area will cause the placeholder to not - // show within the textarea until it has been focused and blurred again. - // https://github.com/facebook/react/issues/6731#issuecomment-254874553 - if (contentToUse !== '') { - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, contentToUse); - } - DOMLazyTree.queueText(lazyTree, contentToUse); - } - } else if (childrenToUse != null) { - var mountImages = this.mountChildren(childrenToUse, transaction, context); - for (var i = 0; i < mountImages.length; i++) { - DOMLazyTree.queueChild(lazyTree, mountImages[i]); - } - } - } - }, - - /** - * Receives a next element and updates the component. - * - * @internal - * @param {ReactElement} nextElement - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {object} context - */ - receiveComponent: function (nextElement, transaction, context) { - var prevElement = this._currentElement; - this._currentElement = nextElement; - this.updateComponent(transaction, prevElement, nextElement, context); - }, - - /** - * Updates a DOM component after it has already been allocated and - * attached to the DOM. Reconciles the root DOM node, then recurses. - * - * @param {ReactReconcileTransaction} transaction - * @param {ReactElement} prevElement - * @param {ReactElement} nextElement - * @internal - * @overridable - */ - updateComponent: function (transaction, prevElement, nextElement, context) { - var lastProps = prevElement.props; - var nextProps = this._currentElement.props; - - switch (this._tag) { - case 'input': - lastProps = ReactDOMInput.getHostProps(this, lastProps); - nextProps = ReactDOMInput.getHostProps(this, nextProps); - break; - case 'option': - lastProps = ReactDOMOption.getHostProps(this, lastProps); - nextProps = ReactDOMOption.getHostProps(this, nextProps); - break; - case 'select': - lastProps = ReactDOMSelect.getHostProps(this, lastProps); - nextProps = ReactDOMSelect.getHostProps(this, nextProps); - break; - case 'textarea': - lastProps = ReactDOMTextarea.getHostProps(this, lastProps); - nextProps = ReactDOMTextarea.getHostProps(this, nextProps); - break; - } - - assertValidProps(this, nextProps); - this._updateDOMProperties(lastProps, nextProps, transaction); - this._updateDOMChildren(lastProps, nextProps, transaction, context); +/** + * @see http://www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#input-type-attr-summary + */ - switch (this._tag) { - case 'input': - // Update the wrapper around inputs *after* updating props. This has to - // happen after `_updateDOMProperties`. Otherwise HTML5 input validations - // raise warnings and prevent the new value from being assigned. - ReactDOMInput.updateWrapper(this); - break; - case 'textarea': - ReactDOMTextarea.updateWrapper(this); - break; - case 'select': - // <select> value update needs to occur after <option> children - // reconciliation - transaction.getReactMountReady().enqueue(postUpdateSelectWrapper, this); - break; - } - }, +var supportedInputTypes = { + color: true, + date: true, + datetime: true, + 'datetime-local': true, + email: true, + month: true, + number: true, + password: true, + range: true, + search: true, + tel: true, + text: true, + time: true, + url: true, + week: true +}; - /** - * Reconciles the properties by detecting differences in property values and - * updating the DOM as necessary. This function is probably the single most - * critical path for performance optimization. - * - * TODO: Benchmark whether checking for changed values in memory actually - * improves performance (especially statically positioned elements). - * TODO: Benchmark the effects of putting this at the top since 99% of props - * do not change for a given reconciliation. - * TODO: Benchmark areas that can be improved with caching. - * - * @private - * @param {object} lastProps - * @param {object} nextProps - * @param {?DOMElement} node - */ - _updateDOMProperties: function (lastProps, nextProps, transaction) { - var propKey; - var styleName; - var styleUpdates; - for (propKey in lastProps) { - if (nextProps.hasOwnProperty(propKey) || !lastProps.hasOwnProperty(propKey) || lastProps[propKey] == null) { - continue; - } - if (propKey === STYLE) { - var lastStyle = this._previousStyleCopy; - for (styleName in lastStyle) { - if (lastStyle.hasOwnProperty(styleName)) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = ''; - } - } - this._previousStyleCopy = null; - } else if (registrationNameModules.hasOwnProperty(propKey)) { - if (lastProps[propKey]) { - // Only call deleteListener if there was a listener previously or - // else willDeleteListener gets called when there wasn't actually a - // listener (e.g., onClick={null}) - deleteListener(this, propKey); - } - } else if (isCustomComponent(this._tag, lastProps)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - DOMPropertyOperations.deleteValueForAttribute(getNode(this), propKey); - } - } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { - DOMPropertyOperations.deleteValueForProperty(getNode(this), propKey); - } - } - for (propKey in nextProps) { - var nextProp = nextProps[propKey]; - var lastProp = propKey === STYLE ? this._previousStyleCopy : lastProps != null ? lastProps[propKey] : undefined; - if (!nextProps.hasOwnProperty(propKey) || nextProp === lastProp || nextProp == null && lastProp == null) { - continue; - } - if (propKey === STYLE) { - if (nextProp) { - if (process.env.NODE_ENV !== 'production') { - checkAndWarnForMutatedStyle(this._previousStyleCopy, this._previousStyle, this); - this._previousStyle = nextProp; - } - nextProp = this._previousStyleCopy = _assign({}, nextProp); - } else { - this._previousStyleCopy = null; - } - if (lastProp) { - // Unset styles on `lastProp` but not on `nextProp`. - for (styleName in lastProp) { - if (lastProp.hasOwnProperty(styleName) && (!nextProp || !nextProp.hasOwnProperty(styleName))) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = ''; - } - } - // Update styles that changed since `lastProp`. - for (styleName in nextProp) { - if (nextProp.hasOwnProperty(styleName) && lastProp[styleName] !== nextProp[styleName]) { - styleUpdates = styleUpdates || {}; - styleUpdates[styleName] = nextProp[styleName]; - } - } - } else { - // Relies on `updateStylesByID` not mutating `styleUpdates`. - styleUpdates = nextProp; - } - } else if (registrationNameModules.hasOwnProperty(propKey)) { - if (nextProp) { - enqueuePutListener(this, propKey, nextProp, transaction); - } else if (lastProp) { - deleteListener(this, propKey); - } - } else if (isCustomComponent(this._tag, nextProps)) { - if (!RESERVED_PROPS.hasOwnProperty(propKey)) { - DOMPropertyOperations.setValueForAttribute(getNode(this), propKey, nextProp); - } - } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { - var node = getNode(this); - // If we're updating to null or undefined, we should remove the property - // from the DOM node instead of inadvertently setting to a string. This - // brings us in line with the same behavior we have on initial render. - if (nextProp != null) { - DOMPropertyOperations.setValueForProperty(node, propKey, nextProp); - } else { - DOMPropertyOperations.deleteValueForProperty(node, propKey); - } - } - } - if (styleUpdates) { - CSSPropertyOperations.setValueForStyles(getNode(this), styleUpdates, this); - } - }, +function isTextInputElement(elem) { + var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); - /** - * Reconciles the children with the various properties that affect the - * children content. - * - * @param {object} lastProps - * @param {object} nextProps - * @param {ReactReconcileTransaction} transaction - * @param {object} context - */ - _updateDOMChildren: function (lastProps, nextProps, transaction, context) { - var lastContent = CONTENT_TYPES[typeof lastProps.children] ? lastProps.children : null; - var nextContent = CONTENT_TYPES[typeof nextProps.children] ? nextProps.children : null; + if (nodeName === 'input') { + return !!supportedInputTypes[elem.type]; + } - var lastHtml = lastProps.dangerouslySetInnerHTML && lastProps.dangerouslySetInnerHTML.__html; - var nextHtml = nextProps.dangerouslySetInnerHTML && nextProps.dangerouslySetInnerHTML.__html; + if (nodeName === 'textarea') { + return true; + } - // Note the use of `!=` which checks for null or undefined. - var lastChildren = lastContent != null ? null : lastProps.children; - var nextChildren = nextContent != null ? null : nextProps.children; + return false; +} - // If we're switching from children to content/html or vice versa, remove - // the old content - var lastHasContentOrHtml = lastContent != null || lastHtml != null; - var nextHasContentOrHtml = nextContent != null || nextHtml != null; - if (lastChildren != null && nextChildren == null) { - this.updateChildren(null, transaction, context); - } else if (lastHasContentOrHtml && !nextHasContentOrHtml) { - this.updateTextContent(''); - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); - } - } +module.exports = isTextInputElement; - if (nextContent != null) { - if (lastContent !== nextContent) { - this.updateTextContent('' + nextContent); - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, nextContent); - } - } - } else if (nextHtml != null) { - if (lastHtml !== nextHtml) { - this.updateMarkup('' + nextHtml); - } - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); - } - } else if (nextChildren != null) { - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, null); - } +/***/ }), +/* 134 */ +/***/ (function(module, exports, __webpack_require__) { - this.updateChildren(nextChildren, transaction, context); - } - }, +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - getHostNode: function () { - return getNode(this); - }, - /** - * Destroys all event registrations for this instance. Does not remove from - * the DOM. That must be done by the parent. - * - * @internal - */ - unmountComponent: function (safely) { - switch (this._tag) { - case 'audio': - case 'form': - case 'iframe': - case 'img': - case 'link': - case 'object': - case 'source': - case 'video': - var listeners = this._wrapperState.listeners; - if (listeners) { - for (var i = 0; i < listeners.length; i++) { - listeners[i].remove(); - } - } - break; - case 'input': - case 'textarea': - inputValueTracking.stopTracking(this); - break; - case 'html': - case 'head': - case 'body': - /** - * Components like <html> <head> and <body> can't be removed or added - * easily in a cross-browser way, however it's valuable to be able to - * take advantage of React's reconciliation for styling and <title> - * management. So we just document it and throw in dangerous cases. - */ - true ? process.env.NODE_ENV !== 'production' ? invariant(false, '<%s> tried to unmount. Because of cross-browser quirks it is impossible to unmount some top-level components (eg <html>, <head>, and <body>) reliably and efficiently. To fix this, have a single top-level component that never unmounts render these elements.', this._tag) : _prodInvariant('66', this._tag) : void 0; - break; - } - this.unmountChildren(safely); - ReactDOMComponentTree.uncacheNode(this); - EventPluginHub.deleteAllListeners(this); - this._rootNodeID = 0; - this._domID = 0; - this._wrapperState = null; +var ViewportMetrics = { + currentScrollLeft: 0, - if (process.env.NODE_ENV !== 'production') { - setAndValidateContentChildDev.call(this, null); - } - }, + currentScrollTop: 0, - getPublicInstance: function () { - return getNode(this); + refreshScrollValues: function (scrollPosition) { + ViewportMetrics.currentScrollLeft = scrollPosition.x; + ViewportMetrics.currentScrollTop = scrollPosition.y; } }; -_assign(ReactDOMComponent.prototype, ReactDOMComponent.Mixin, ReactMultiChild.Mixin); - -module.exports = ReactDOMComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = ViewportMetrics; /***/ }), -/* 160 */ +/* 135 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -28565,25 +25081,53 @@ module.exports = ReactDOMComponent; -var ReactDOMComponentTree = __webpack_require__(6); +var ExecutionEnvironment = __webpack_require__(13); +var escapeTextContentForBrowser = __webpack_require__(61); +var setInnerHTML = __webpack_require__(60); -var focusNode = __webpack_require__(91); +/** + * Set the textContent property of a node, ensuring that whitespace is preserved + * even in IE8. innerText is a poor substitute for textContent and, among many + * issues, inserts <br> instead of the literal newline chars. innerHTML behaves + * as it should. + * + * @param {DOMElement} node + * @param {string} text + * @internal + */ +var setTextContent = function (node, text) { + if (text) { + var firstChild = node.firstChild; -var AutoFocusUtils = { - focusDOMComponent: function () { - focusNode(ReactDOMComponentTree.getNodeFromInstance(this)); + if (firstChild && firstChild === node.lastChild && firstChild.nodeType === 3) { + firstChild.nodeValue = text; + return; + } } + node.textContent = text; }; -module.exports = AutoFocusUtils; +if (ExecutionEnvironment.canUseDOM) { + if (!('textContent' in document.documentElement)) { + setTextContent = function (node, text) { + if (node.nodeType === 3) { + node.nodeValue = text; + return; + } + setInnerHTML(node, escapeTextContentForBrowser(text)); + }; + } +} + +module.exports = setTextContent; /***/ }), -/* 161 */ +/* 136 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. +/** + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -28594,294 +25138,445 @@ module.exports = AutoFocusUtils; -var CSSProperty = __webpack_require__(92); -var ExecutionEnvironment = __webpack_require__(8); -var ReactInstrumentation = __webpack_require__(13); - -var camelizeStyleName = __webpack_require__(162); -var dangerousStyleValue = __webpack_require__(164); -var hyphenateStyleName = __webpack_require__(165); -var memoizeStringOnly = __webpack_require__(167); -var warning = __webpack_require__(2); - -var processStyleName = memoizeStringOnly(function (styleName) { - return hyphenateStyleName(styleName); -}); +/** + * @param {DOMElement} node input/textarea to focus + */ -var hasShorthandPropertyBug = false; -var styleFloatAccessor = 'cssFloat'; -if (ExecutionEnvironment.canUseDOM) { - var tempStyle = document.createElement('div').style; +function focusNode(node) { + // IE8 can throw "Can't move focus to the control because it is invisible, + // not enabled, or of a type that does not accept the focus." for all kinds of + // reasons that are too expensive and fragile to test. try { - // IE8 throws "Invalid argument." if resetting shorthand style properties. - tempStyle.font = ''; - } catch (e) { - hasShorthandPropertyBug = true; - } - // IE8 only supports accessing cssFloat (standard) as styleFloat - if (document.documentElement.style.cssFloat === undefined) { - styleFloatAccessor = 'styleFloat'; - } + node.focus(); + } catch (e) {} } -if (process.env.NODE_ENV !== 'production') { - // 'msTransform' is correct, but the other prefixes should be capitalized - var badVendoredStyleNamePattern = /^(?:webkit|moz|o)[A-Z]/; - - // style values shouldn't contain a semicolon - var badStyleValueWithSemicolonPattern = /;\s*$/; +module.exports = focusNode; - var warnedStyleNames = {}; - var warnedStyleValues = {}; - var warnedForNaNValue = false; +/***/ }), +/* 137 */ +/***/ (function(module, exports, __webpack_require__) { - var warnHyphenatedStyleName = function (name, owner) { - if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { - return; - } +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - warnedStyleNames[name] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported style property %s. Did you mean %s?%s', name, camelizeStyleName(name), checkRenderMessage(owner)) : void 0; - }; - var warnBadVendoredStyleName = function (name, owner) { - if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { - return; - } - warnedStyleNames[name] = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported vendor-prefixed style property %s. Did you mean %s?%s', name, name.charAt(0).toUpperCase() + name.slice(1), checkRenderMessage(owner)) : void 0; - }; +/** + * CSS properties which accept numbers but are not in units of "px". + */ - var warnStyleValueWithSemicolon = function (name, value, owner) { - if (warnedStyleValues.hasOwnProperty(value) && warnedStyleValues[value]) { - return; - } +var isUnitlessNumber = { + animationIterationCount: true, + borderImageOutset: true, + borderImageSlice: true, + borderImageWidth: true, + boxFlex: true, + boxFlexGroup: true, + boxOrdinalGroup: true, + columnCount: true, + flex: true, + flexGrow: true, + flexPositive: true, + flexShrink: true, + flexNegative: true, + flexOrder: true, + gridRow: true, + gridRowEnd: true, + gridRowSpan: true, + gridRowStart: true, + gridColumn: true, + gridColumnEnd: true, + gridColumnSpan: true, + gridColumnStart: true, + fontWeight: true, + lineClamp: true, + lineHeight: true, + opacity: true, + order: true, + orphans: true, + tabSize: true, + widows: true, + zIndex: true, + zoom: true, - warnedStyleValues[value] = true; - process.env.NODE_ENV !== 'production' ? warning(false, "Style property values shouldn't contain a semicolon.%s " + 'Try "%s: %s" instead.', checkRenderMessage(owner), name, value.replace(badStyleValueWithSemicolonPattern, '')) : void 0; - }; + // SVG-related properties + fillOpacity: true, + floodOpacity: true, + stopOpacity: true, + strokeDasharray: true, + strokeDashoffset: true, + strokeMiterlimit: true, + strokeOpacity: true, + strokeWidth: true +}; - var warnStyleValueIsNaN = function (name, value, owner) { - if (warnedForNaNValue) { - return; - } +/** + * @param {string} prefix vendor-specific prefix, eg: Webkit + * @param {string} key style name, eg: transitionDuration + * @return {string} style name prefixed with `prefix`, properly camelCased, eg: + * WebkitTransitionDuration + */ +function prefixKey(prefix, key) { + return prefix + key.charAt(0).toUpperCase() + key.substring(1); +} - warnedForNaNValue = true; - process.env.NODE_ENV !== 'production' ? warning(false, '`NaN` is an invalid value for the `%s` css style property.%s', name, checkRenderMessage(owner)) : void 0; - }; +/** + * Support style names that may come passed in prefixed by adding permutations + * of vendor prefixes. + */ +var prefixes = ['Webkit', 'ms', 'Moz', 'O']; - var checkRenderMessage = function (owner) { - if (owner) { - var name = owner.getName(); - if (name) { - return ' Check the render method of `' + name + '`.'; - } - } - return ''; - }; +// Using Object.keys here, or else the vanilla for-in loop makes IE8 go into an +// infinite loop, because it iterates over the newly added props too. +Object.keys(isUnitlessNumber).forEach(function (prop) { + prefixes.forEach(function (prefix) { + isUnitlessNumber[prefixKey(prefix, prop)] = isUnitlessNumber[prop]; + }); +}); + +/** + * Most style properties can be unset by doing .style[prop] = '' but IE8 + * doesn't like doing that with shorthand properties so for the properties that + * IE8 breaks on, which are listed here, we instead unset each of the + * individual properties. See http://bugs.jquery.com/ticket/12385. + * The 4-value 'clock' properties like margin, padding, border-width seem to + * behave without any problems. Curiously, list-style works too without any + * special prodding. + */ +var shorthandPropertyExpansions = { + background: { + backgroundAttachment: true, + backgroundColor: true, + backgroundImage: true, + backgroundPositionX: true, + backgroundPositionY: true, + backgroundRepeat: true + }, + backgroundPosition: { + backgroundPositionX: true, + backgroundPositionY: true + }, + border: { + borderWidth: true, + borderStyle: true, + borderColor: true + }, + borderBottom: { + borderBottomWidth: true, + borderBottomStyle: true, + borderBottomColor: true + }, + borderLeft: { + borderLeftWidth: true, + borderLeftStyle: true, + borderLeftColor: true + }, + borderRight: { + borderRightWidth: true, + borderRightStyle: true, + borderRightColor: true + }, + borderTop: { + borderTopWidth: true, + borderTopStyle: true, + borderTopColor: true + }, + font: { + fontStyle: true, + fontVariant: true, + fontWeight: true, + fontSize: true, + lineHeight: true, + fontFamily: true + }, + outline: { + outlineWidth: true, + outlineStyle: true, + outlineColor: true + } +}; + +var CSSProperty = { + isUnitlessNumber: isUnitlessNumber, + shorthandPropertyExpansions: shorthandPropertyExpansions +}; + +module.exports = CSSProperty; + +/***/ }), +/* 138 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var DOMProperty = __webpack_require__(28); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstrumentation = __webpack_require__(19); + +var quoteAttributeValueForBrowser = __webpack_require__(263); +var warning = __webpack_require__(3); + +var VALID_ATTRIBUTE_NAME_REGEX = new RegExp('^[' + DOMProperty.ATTRIBUTE_NAME_START_CHAR + '][' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); +var illegalAttributeNameCache = {}; +var validatedAttributeNameCache = {}; + +function isAttributeNameSafe(attributeName) { + if (validatedAttributeNameCache.hasOwnProperty(attributeName)) { + return true; + } + if (illegalAttributeNameCache.hasOwnProperty(attributeName)) { + return false; + } + if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) { + validatedAttributeNameCache[attributeName] = true; + return true; + } + illegalAttributeNameCache[attributeName] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid attribute name: `%s`', attributeName) : void 0; + return false; +} + +function shouldIgnoreValue(propertyInfo, value) { + return value == null || propertyInfo.hasBooleanValue && !value || propertyInfo.hasNumericValue && isNaN(value) || propertyInfo.hasPositiveNumericValue && value < 1 || propertyInfo.hasOverloadedBooleanValue && value === false; +} + +/** + * Operations for dealing with DOM properties. + */ +var DOMPropertyOperations = { + /** + * Creates markup for the ID property. + * + * @param {string} id Unescaped ID. + * @return {string} Markup string. + */ + createMarkupForID: function (id) { + return DOMProperty.ID_ATTRIBUTE_NAME + '=' + quoteAttributeValueForBrowser(id); + }, + + setAttributeForID: function (node, id) { + node.setAttribute(DOMProperty.ID_ATTRIBUTE_NAME, id); + }, + + createMarkupForRoot: function () { + return DOMProperty.ROOT_ATTRIBUTE_NAME + '=""'; + }, + + setAttributeForRoot: function (node) { + node.setAttribute(DOMProperty.ROOT_ATTRIBUTE_NAME, ''); + }, /** + * Creates markup for a property. + * * @param {string} name * @param {*} value - * @param {ReactDOMComponent} component + * @return {?string} Markup string, or null if the property was invalid. */ - var warnValidStyle = function (name, value, component) { - var owner; - if (component) { - owner = component._currentElement._owner; - } - if (name.indexOf('-') > -1) { - warnHyphenatedStyleName(name, owner); - } else if (badVendoredStyleNamePattern.test(name)) { - warnBadVendoredStyleName(name, owner); - } else if (badStyleValueWithSemicolonPattern.test(value)) { - warnStyleValueWithSemicolon(name, value, owner); + createMarkupForProperty: function (name, value) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + if (shouldIgnoreValue(propertyInfo, value)) { + return ''; + } + var attributeName = propertyInfo.attributeName; + if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { + return attributeName + '=""'; + } + return attributeName + '=' + quoteAttributeValueForBrowser(value); + } else if (DOMProperty.isCustomAttribute(name)) { + if (value == null) { + return ''; + } + return name + '=' + quoteAttributeValueForBrowser(value); } + return null; + }, - if (typeof value === 'number' && isNaN(value)) { - warnStyleValueIsNaN(name, value, owner); + /** + * Creates markup for a custom property. + * + * @param {string} name + * @param {*} value + * @return {string} Markup string, or empty string if the property was invalid. + */ + createMarkupForCustomAttribute: function (name, value) { + if (!isAttributeNameSafe(name) || value == null) { + return ''; } - }; -} + return name + '=' + quoteAttributeValueForBrowser(value); + }, -/** - * Operations for dealing with CSS properties. - */ -var CSSPropertyOperations = { /** - * Serializes a mapping of style properties for use as inline styles: - * - * > createMarkupForStyles({width: '200px', height: 0}) - * "width:200px;height:0;" - * - * Undefined values are ignored so that declarative programming is easier. - * The result should be HTML-escaped before insertion into the DOM. + * Sets the value for a property on a node. * - * @param {object} styles - * @param {ReactDOMComponent} component - * @return {?string} + * @param {DOMElement} node + * @param {string} name + * @param {*} value */ - createMarkupForStyles: function (styles, component) { - var serialized = ''; - for (var styleName in styles) { - if (!styles.hasOwnProperty(styleName)) { - continue; - } - var isCustomProperty = styleName.indexOf('--') === 0; - var styleValue = styles[styleName]; - if (process.env.NODE_ENV !== 'production') { - if (!isCustomProperty) { - warnValidStyle(styleName, styleValue, component); + setValueForProperty: function (node, name, value) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + var mutationMethod = propertyInfo.mutationMethod; + if (mutationMethod) { + mutationMethod(node, value); + } else if (shouldIgnoreValue(propertyInfo, value)) { + this.deleteValueForProperty(node, name); + return; + } else if (propertyInfo.mustUseProperty) { + // Contrary to `setAttribute`, object properties are properly + // `toString`ed by IE8/9. + node[propertyInfo.propertyName] = value; + } else { + var attributeName = propertyInfo.attributeName; + var namespace = propertyInfo.attributeNamespace; + // `setAttribute` with objects becomes only `[object]` in IE8/9, + // ('' + value) makes it output the correct toString()-value. + if (namespace) { + node.setAttributeNS(namespace, attributeName, '' + value); + } else if (propertyInfo.hasBooleanValue || propertyInfo.hasOverloadedBooleanValue && value === true) { + node.setAttribute(attributeName, ''); + } else { + node.setAttribute(attributeName, '' + value); } } - if (styleValue != null) { - serialized += processStyleName(styleName) + ':'; - serialized += dangerousStyleValue(styleName, styleValue, component, isCustomProperty) + ';'; - } + } else if (DOMProperty.isCustomAttribute(name)) { + DOMPropertyOperations.setValueForAttribute(node, name, value); + return; + } + + if (process.env.NODE_ENV !== 'production') { + var payload = {}; + payload[name] = value; + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'update attribute', + payload: payload + }); + } + }, + + setValueForAttribute: function (node, name, value) { + if (!isAttributeNameSafe(name)) { + return; + } + if (value == null) { + node.removeAttribute(name); + } else { + node.setAttribute(name, '' + value); + } + + if (process.env.NODE_ENV !== 'production') { + var payload = {}; + payload[name] = value; + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'update attribute', + payload: payload + }); } - return serialized || null; }, /** - * Sets the value for multiple styles on a node. If a value is specified as - * '' (empty string), the corresponding style property will be unset. + * Deletes an attributes from a node. * * @param {DOMElement} node - * @param {object} styles - * @param {ReactDOMComponent} component + * @param {string} name */ - setValueForStyles: function (node, styles, component) { + deleteValueForAttribute: function (node, name) { + node.removeAttribute(name); if (process.env.NODE_ENV !== 'production') { ReactInstrumentation.debugTool.onHostOperation({ - instanceID: component._debugID, - type: 'update styles', - payload: styles + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'remove attribute', + payload: name }); } + }, - var style = node.style; - for (var styleName in styles) { - if (!styles.hasOwnProperty(styleName)) { - continue; - } - var isCustomProperty = styleName.indexOf('--') === 0; - if (process.env.NODE_ENV !== 'production') { - if (!isCustomProperty) { - warnValidStyle(styleName, styles[styleName], component); - } - } - var styleValue = dangerousStyleValue(styleName, styles[styleName], component, isCustomProperty); - if (styleName === 'float' || styleName === 'cssFloat') { - styleName = styleFloatAccessor; - } - if (isCustomProperty) { - style.setProperty(styleName, styleValue); - } else if (styleValue) { - style[styleName] = styleValue; - } else { - var expansion = hasShorthandPropertyBug && CSSProperty.shorthandPropertyExpansions[styleName]; - if (expansion) { - // Shorthand property that IE8 won't like unsetting, so unset each - // component to placate it - for (var individualStyleName in expansion) { - style[individualStyleName] = ''; - } + /** + * Deletes the value for a property on a node. + * + * @param {DOMElement} node + * @param {string} name + */ + deleteValueForProperty: function (node, name) { + var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null; + if (propertyInfo) { + var mutationMethod = propertyInfo.mutationMethod; + if (mutationMethod) { + mutationMethod(node, undefined); + } else if (propertyInfo.mustUseProperty) { + var propName = propertyInfo.propertyName; + if (propertyInfo.hasBooleanValue) { + node[propName] = false; } else { - style[styleName] = ''; + node[propName] = ''; } + } else { + node.removeAttribute(propertyInfo.attributeName); } + } else if (DOMProperty.isCustomAttribute(name)) { + node.removeAttribute(name); + } + + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: ReactDOMComponentTree.getInstanceFromNode(node)._debugID, + type: 'remove attribute', + payload: name + }); } } }; -module.exports = CSSPropertyOperations; +module.exports = DOMPropertyOperations; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 162 */ +/* 139 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /** - * Copyright (c) 2013-present, Facebook, Inc. + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * @typechecks - */ - - - -var camelize = __webpack_require__(163); - -var msPattern = /^-ms-/; - -/** - * Camelcases a hyphenated CSS property name, for example: - * - * > camelizeStyleName('background-color') - * < "backgroundColor" - * > camelizeStyleName('-moz-transition') - * < "MozTransition" - * > camelizeStyleName('-ms-transition') - * < "msTransition" - * - * As Andi Smith suggests - * (http://www.andismith.com/blog/2012/02/modernizr-prefixed/), an `-ms` prefix - * is converted to lowercase `ms`. - * - * @param {string} string - * @return {string} + * */ -function camelizeStyleName(string) { - return camelize(string.replace(msPattern, 'ms-')); -} - -module.exports = camelizeStyleName; -/***/ }), -/* 163 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ -var _hyphenPattern = /-(.)/g; -/** - * Camelcases a hyphenated string, for example: - * - * > camelize('background-color') - * < "backgroundColor" - * - * @param {string} string - * @return {string} - */ -function camelize(string) { - return string.replace(_hyphenPattern, function (_, character) { - return character.toUpperCase(); - }); -} +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; -module.exports = camelize; +module.exports = ReactPropTypesSecret; /***/ }), -/* 164 */ +/* 140 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -28897,197 +25592,336 @@ module.exports = camelize; -var CSSProperty = __webpack_require__(92); -var warning = __webpack_require__(2); +var _assign = __webpack_require__(8); -var isUnitlessNumber = CSSProperty.isUnitlessNumber; -var styleWarnings = {}; +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); -/** - * Convert a value into the proper css writable value. The style name `name` - * should be logical (no hyphens), as specified - * in `CSSProperty.isUnitlessNumber`. - * - * @param {string} name CSS property name such as `topMargin`. - * @param {*} value CSS property value such as `10px`. - * @param {ReactDOMComponent} component - * @return {string} Normalized style value with dimensions applied. - */ -function dangerousStyleValue(name, value, component, isCustomProperty) { - // Note that we've removed escapeTextForBrowser() calls here since the - // whole string will be escaped when the attribute is injected into - // the markup. If you provide unsafe user data here they can inject - // arbitrary CSS which may be problematic (I couldn't repro this): - // https://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet - // http://www.thespanner.co.uk/2007/11/26/ultimate-xss-css-injection/ - // This is not an XSS hole but instead a potential CSS injection issue - // which has lead to a greater discussion about how we're going to - // trust URLs moving forward. See #2115901 +var warning = __webpack_require__(3); - var isEmpty = value == null || typeof value === 'boolean' || value === ''; - if (isEmpty) { - return ''; - } +var didWarnValueLink = false; +var didWarnValueDefaultValue = false; - var isNonNumeric = isNaN(value); - if (isCustomProperty || isNonNumeric || value === 0 || isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name]) { - return '' + value; // cast to string - } +function updateOptionsIfPendingUpdateAndMounted() { + if (this._rootNodeID && this._wrapperState.pendingUpdate) { + this._wrapperState.pendingUpdate = false; - if (typeof value === 'string') { - if (process.env.NODE_ENV !== 'production') { - // Allow '0' to pass through without warning. 0 is already special and - // doesn't require units, so we don't need to warn about it. - if (component && value !== '0') { - var owner = component._currentElement._owner; - var ownerName = owner ? owner.getName() : null; - if (ownerName && !styleWarnings[ownerName]) { - styleWarnings[ownerName] = {}; - } - var warned = false; - if (ownerName) { - var warnings = styleWarnings[ownerName]; - warned = warnings[name]; - if (!warned) { - warnings[name] = true; - } - } - if (!warned) { - process.env.NODE_ENV !== 'production' ? warning(false, 'a `%s` tag (owner: `%s`) was passed a numeric string value ' + 'for CSS property `%s` (value: `%s`) which will be treated ' + 'as a unitless number in a future version of React.', component._currentElement.type, ownerName || 'unknown', name, value) : void 0; - } - } + var props = this._currentElement.props; + var value = LinkedValueUtils.getValue(props); + + if (value != null) { + updateOptions(this, Boolean(props.multiple), value); } - value = value.trim(); } - return value + 'px'; } -module.exports = dangerousStyleValue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} -/***/ }), -/* 165 */ -/***/ (function(module, exports, __webpack_require__) { +var valuePropNames = ['value', 'defaultValue']; -"use strict"; /** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks + * Validation function for `value` and `defaultValue`. + * @private */ +function checkSelectPropTypes(inst, props) { + var owner = inst._currentElement._owner; + LinkedValueUtils.checkPropTypes('select', props, owner); + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `select` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + for (var i = 0; i < valuePropNames.length; i++) { + var propName = valuePropNames[i]; + if (props[propName] == null) { + continue; + } + var isArray = Array.isArray(props[propName]); + if (props.multiple && !isArray) { + process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be an array if ' + '`multiple` is true.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; + } else if (!props.multiple && isArray) { + process.env.NODE_ENV !== 'production' ? warning(false, 'The `%s` prop supplied to <select> must be a scalar ' + 'value if `multiple` is false.%s', propName, getDeclarationErrorAddendum(owner)) : void 0; + } + } +} -var hyphenate = __webpack_require__(166); +/** + * @param {ReactDOMComponent} inst + * @param {boolean} multiple + * @param {*} propValue A stringable (with `multiple`, a list of stringables). + * @private + */ +function updateOptions(inst, multiple, propValue) { + var selectedValue, i; + var options = ReactDOMComponentTree.getNodeFromInstance(inst).options; -var msPattern = /^ms-/; + if (multiple) { + selectedValue = {}; + for (i = 0; i < propValue.length; i++) { + selectedValue['' + propValue[i]] = true; + } + for (i = 0; i < options.length; i++) { + var selected = selectedValue.hasOwnProperty(options[i].value); + if (options[i].selected !== selected) { + options[i].selected = selected; + } + } + } else { + // Do not set `select.value` as exact behavior isn't consistent across all + // browsers for all cases. + selectedValue = '' + propValue; + for (i = 0; i < options.length; i++) { + if (options[i].value === selectedValue) { + options[i].selected = true; + return; + } + } + if (options.length) { + options[0].selected = true; + } + } +} /** - * Hyphenates a camelcased CSS property name, for example: + * Implements a <select> host component that allows optionally setting the + * props `value` and `defaultValue`. If `multiple` is false, the prop must be a + * stringable. If `multiple` is true, the prop must be an array of stringables. * - * > hyphenateStyleName('backgroundColor') - * < "background-color" - * > hyphenateStyleName('MozTransition') - * < "-moz-transition" - * > hyphenateStyleName('msTransition') - * < "-ms-transition" + * If `value` is not supplied (or null/undefined), user actions that change the + * selected option will trigger updates to the rendered options. * - * As Modernizr suggests (http://modernizr.com/docs/#prefixed), an `ms` prefix - * is converted to `-ms-`. + * If it is supplied (and not null/undefined), the rendered options will not + * update in response to user actions. Instead, the `value` prop must change in + * order for the rendered options to update. * - * @param {string} string - * @return {string} + * If `defaultValue` is provided, any options with the supplied values will be + * selected. */ -function hyphenateStyleName(string) { - return hyphenate(string).replace(msPattern, '-ms-'); +var ReactDOMSelect = { + getHostProps: function (inst, props) { + return _assign({}, props, { + onChange: inst._wrapperState.onChange, + value: undefined + }); + }, + + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + checkSelectPropTypes(inst, props); + } + + var value = LinkedValueUtils.getValue(props); + inst._wrapperState = { + pendingUpdate: false, + initialValue: value != null ? value : props.defaultValue, + listeners: null, + onChange: _handleChange.bind(inst), + wasMultiple: Boolean(props.multiple) + }; + + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Select elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; + didWarnValueDefaultValue = true; + } + }, + + getSelectValueContext: function (inst) { + // ReactDOMOption looks at this initial value so the initial generated + // markup has correct `selected` attributes + return inst._wrapperState.initialValue; + }, + + postUpdateWrapper: function (inst) { + var props = inst._currentElement.props; + + // After the initial mount, we control selected-ness manually so don't pass + // this value down + inst._wrapperState.initialValue = undefined; + + var wasMultiple = inst._wrapperState.wasMultiple; + inst._wrapperState.wasMultiple = Boolean(props.multiple); + + var value = LinkedValueUtils.getValue(props); + if (value != null) { + inst._wrapperState.pendingUpdate = false; + updateOptions(inst, Boolean(props.multiple), value); + } else if (wasMultiple !== Boolean(props.multiple)) { + // For simplicity, reapply `defaultValue` if `multiple` is toggled. + if (props.defaultValue != null) { + updateOptions(inst, Boolean(props.multiple), props.defaultValue); + } else { + // Revert the select back to its default unselected state. + updateOptions(inst, Boolean(props.multiple), props.multiple ? [] : ''); + } + } + } +}; + +function _handleChange(event) { + var props = this._currentElement.props; + var returnValue = LinkedValueUtils.executeOnChange(props, event); + + if (this._rootNodeID) { + this._wrapperState.pendingUpdate = true; + } + ReactUpdates.asap(updateOptionsIfPendingUpdateAndMounted, this); + return returnValue; } -module.exports = hyphenateStyleName; +module.exports = ReactDOMSelect; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 166 */ +/* 141 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; - - -/** - * Copyright (c) 2013-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * - * @typechecks */ -var _uppercasePattern = /([A-Z])/g; + + +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var ReactCompositeComponent = __webpack_require__(271); +var ReactEmptyComponent = __webpack_require__(143); +var ReactHostComponent = __webpack_require__(144); + +var getNextDebugID = __webpack_require__(274); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); + +// To avoid a cyclic dependency, we create the final class in this module +var ReactCompositeComponentWrapper = function (element) { + this.construct(element); +}; + +function getDeclarationErrorAddendum(owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; +} /** - * Hyphenates a camelcased string, for example: - * - * > hyphenate('backgroundColor') - * < "background-color" - * - * For CSS style names, use `hyphenateStyleName` instead which works properly - * with all vendor prefixes, including `ms`. + * Check if the type reference is a known internal type. I.e. not a user + * provided composite type. * - * @param {string} string - * @return {string} + * @param {function} type + * @return {boolean} Returns true if this is a valid internal type. */ -function hyphenate(string) { - return string.replace(_uppercasePattern, '-$1').toLowerCase(); +function isInternalComponentType(type) { + return typeof type === 'function' && typeof type.prototype !== 'undefined' && typeof type.prototype.mountComponent === 'function' && typeof type.prototype.receiveComponent === 'function'; } -module.exports = hyphenate; - -/***/ }), -/* 167 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; /** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * Given a ReactNode, create an instance that will actually be mounted. * - * - * @typechecks static-only + * @param {ReactNode} node + * @param {boolean} shouldHaveDebugID + * @return {object} A new instance of the element's constructor. + * @protected */ +function instantiateReactComponent(node, shouldHaveDebugID) { + var instance; + + if (node === null || node === false) { + instance = ReactEmptyComponent.create(instantiateReactComponent); + } else if (typeof node === 'object') { + var element = node; + var type = element.type; + if (typeof type !== 'function' && typeof type !== 'string') { + var info = ''; + if (process.env.NODE_ENV !== 'production') { + if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { + info += ' You likely forgot to export your component from the file ' + "it's defined in."; + } + } + info += getDeclarationErrorAddendum(element._owner); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s', type == null ? type : typeof type, info) : _prodInvariant('130', type == null ? type : typeof type, info) : void 0; + } + // Special case string values + if (typeof element.type === 'string') { + instance = ReactHostComponent.createInternalComponent(element); + } else if (isInternalComponentType(element.type)) { + // This is temporarily available for custom components that are not string + // representations. I.e. ART. Once those are updated to use the string + // representation, we can drop this code path. + instance = new element.type(element); + // We renamed this. Allow the old name for compat. :( + if (!instance.getHostNode) { + instance.getHostNode = instance.getNativeNode; + } + } else { + instance = new ReactCompositeComponentWrapper(element); + } + } else if (typeof node === 'string' || typeof node === 'number') { + instance = ReactHostComponent.createInstanceForText(node); + } else { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Encountered invalid React node of type %s', typeof node) : _prodInvariant('131', typeof node) : void 0; + } -/** - * Memoizes the return value of a function that accepts one string argument. - */ + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(typeof instance.mountComponent === 'function' && typeof instance.receiveComponent === 'function' && typeof instance.getHostNode === 'function' && typeof instance.unmountComponent === 'function', 'Only React Components can be mounted.') : void 0; + } -function memoizeStringOnly(callback) { - var cache = {}; - return function (string) { - if (!cache.hasOwnProperty(string)) { - cache[string] = callback.call(this, string); + // These two fields are used by the DOM and ART diffing algorithms + // respectively. Instead of using expandos on components, we should be + // storing the state needed by the diffing algorithms elsewhere. + instance._mountIndex = 0; + instance._mountImage = null; + + if (process.env.NODE_ENV !== 'production') { + instance._debugID = shouldHaveDebugID ? getNextDebugID() : 0; + } + + // Internal instances should fully constructed at this point, so they should + // not get any new fields added to them at this point. + if (process.env.NODE_ENV !== 'production') { + if (Object.preventExtensions) { + Object.preventExtensions(instance); } - return cache[string]; - }; + } + + return instance; } -module.exports = memoizeStringOnly; +_assign(ReactCompositeComponentWrapper.prototype, ReactCompositeComponent, { + _instantiateReactComponent: instantiateReactComponent +}); + +module.exports = instantiateReactComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 168 */ +/* 142 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** +/* WEBPACK VAR INJECTION */(function(process) {/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -29095,31 +25929,46 @@ module.exports = memoizeStringOnly; * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * */ -var escapeTextContentForBrowser = __webpack_require__(44); +var _prodInvariant = __webpack_require__(5); -/** - * Escapes attribute value to prevent scripting attacks. - * - * @param {*} value Value to escape. - * @return {string} An escaped string. - */ -function quoteAttributeValueForBrowser(value) { - return '"' + escapeTextContentForBrowser(value) + '"'; -} +var React = __webpack_require__(36); -module.exports = quoteAttributeValueForBrowser; +var invariant = __webpack_require__(2); + +var ReactNodeTypes = { + HOST: 0, + COMPOSITE: 1, + EMPTY: 2, + + getType: function (node) { + if (node === null || node === false) { + return ReactNodeTypes.EMPTY; + } else if (React.isValidElement(node)) { + if (typeof node.type === 'function') { + return ReactNodeTypes.COMPOSITE; + } else { + return ReactNodeTypes.HOST; + } + } + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Unexpected node: %s', node) : _prodInvariant('26', node) : void 0; + } +}; + +module.exports = ReactNodeTypes; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 169 */ +/* 143 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /** - * Copyright 2013-present, Facebook, Inc. + * Copyright 2014-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -29130,33 +25979,31 @@ module.exports = quoteAttributeValueForBrowser; -var EventPluginHub = __webpack_require__(32); +var emptyComponentFactory; -function runEventQueueInBatch(events) { - EventPluginHub.enqueueEvents(events); - EventPluginHub.processEventQueue(false); -} +var ReactEmptyComponentInjection = { + injectEmptyComponentFactory: function (factory) { + emptyComponentFactory = factory; + } +}; -var ReactEventEmitterMixin = { - /** - * Streams a fired top-level event to `EventPluginHub` where plugins have the - * opportunity to create `ReactEvent`s to be dispatched. - */ - handleTopLevel: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var events = EventPluginHub.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); - runEventQueueInBatch(events); +var ReactEmptyComponent = { + create: function (instantiate) { + return emptyComponentFactory(instantiate); } }; -module.exports = ReactEventEmitterMixin; +ReactEmptyComponent.injection = ReactEmptyComponentInjection; + +module.exports = ReactEmptyComponent; /***/ }), -/* 170 */ +/* 144 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the @@ -29167,97 +26014,65 @@ module.exports = ReactEventEmitterMixin; -var ExecutionEnvironment = __webpack_require__(8); - -/** - * Generate a mapping of standard vendor prefixes using the defined style property and event name. - * - * @param {string} styleProp - * @param {string} eventName - * @returns {object} - */ -function makePrefixMap(styleProp, eventName) { - var prefixes = {}; +var _prodInvariant = __webpack_require__(5); - prefixes[styleProp.toLowerCase()] = eventName.toLowerCase(); - prefixes['Webkit' + styleProp] = 'webkit' + eventName; - prefixes['Moz' + styleProp] = 'moz' + eventName; - prefixes['ms' + styleProp] = 'MS' + eventName; - prefixes['O' + styleProp] = 'o' + eventName.toLowerCase(); +var invariant = __webpack_require__(2); - return prefixes; -} +var genericComponentClass = null; +var textComponentClass = null; -/** - * A list of event names to a configurable list of vendor prefixes. - */ -var vendorPrefixes = { - animationend: makePrefixMap('Animation', 'AnimationEnd'), - animationiteration: makePrefixMap('Animation', 'AnimationIteration'), - animationstart: makePrefixMap('Animation', 'AnimationStart'), - transitionend: makePrefixMap('Transition', 'TransitionEnd') +var ReactHostComponentInjection = { + // This accepts a class that receives the tag string. This is a catch all + // that can render any kind of tag. + injectGenericComponentClass: function (componentClass) { + genericComponentClass = componentClass; + }, + // This accepts a text component class that takes the text string to be + // rendered as props. + injectTextComponentClass: function (componentClass) { + textComponentClass = componentClass; + } }; /** - * Event names that have already been detected and prefixed (if applicable). + * Get a host internal component class for a specific tag. + * + * @param {ReactElement} element The element to create. + * @return {function} The internal class constructor function. */ -var prefixedEventNames = {}; +function createInternalComponent(element) { + !genericComponentClass ? process.env.NODE_ENV !== 'production' ? invariant(false, 'There is no registered component for the tag %s', element.type) : _prodInvariant('111', element.type) : void 0; + return new genericComponentClass(element); +} /** - * Element to check for prefixes on. + * @param {ReactText} text + * @return {ReactComponent} */ -var style = {}; +function createInstanceForText(text) { + return new textComponentClass(text); +} /** - * Bootstrap if a DOM exists. + * @param {ReactComponent} component + * @return {boolean} */ -if (ExecutionEnvironment.canUseDOM) { - style = document.createElement('div').style; - - // On some platforms, in particular some releases of Android 4.x, - // the un-prefixed "animation" and "transition" properties are defined on the - // style object but the events that fire will still be prefixed, so we need - // to check if the un-prefixed events are usable, and if not remove them from the map. - if (!('AnimationEvent' in window)) { - delete vendorPrefixes.animationend.animation; - delete vendorPrefixes.animationiteration.animation; - delete vendorPrefixes.animationstart.animation; - } - - // Same as above - if (!('TransitionEvent' in window)) { - delete vendorPrefixes.transitionend.transition; - } +function isTextComponent(component) { + return component instanceof textComponentClass; } -/** - * Attempts to determine the correct vendor prefixed event name. - * - * @param {string} eventName - * @returns {string} - */ -function getVendorPrefixedEventName(eventName) { - if (prefixedEventNames[eventName]) { - return prefixedEventNames[eventName]; - } else if (!vendorPrefixes[eventName]) { - return eventName; - } - - var prefixMap = vendorPrefixes[eventName]; - - for (var styleProp in prefixMap) { - if (prefixMap.hasOwnProperty(styleProp) && styleProp in style) { - return prefixedEventNames[eventName] = prefixMap[styleProp]; - } - } - - return ''; -} +var ReactHostComponent = { + createInternalComponent: createInternalComponent, + createInstanceForText: createInstanceForText, + isTextComponent: isTextComponent, + injection: ReactHostComponentInjection +}; -module.exports = getVendorPrefixedEventName; +module.exports = ReactHostComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 171 */ +/* 145 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -29273,288 +26088,267 @@ module.exports = getVendorPrefixedEventName; -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); - -var DOMPropertyOperations = __webpack_require__(93); -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); +var _prodInvariant = __webpack_require__(5); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); - -var didWarnValueLink = false; -var didWarnCheckedLink = false; -var didWarnValueDefaultValue = false; -var didWarnCheckedDefaultChecked = false; -var didWarnControlledToUncontrolled = false; -var didWarnUncontrolledToControlled = false; +var ReactCurrentOwner = __webpack_require__(22); +var REACT_ELEMENT_TYPE = __webpack_require__(275); -function forceUpdateIfMounted() { - if (this._rootNodeID) { - // DOM component is still mounted; update - ReactDOMInput.updateWrapper(this); - } -} +var getIteratorFn = __webpack_require__(276); +var invariant = __webpack_require__(2); +var KeyEscapeUtils = __webpack_require__(89); +var warning = __webpack_require__(3); -function isControlled(props) { - var usesChecked = props.type === 'checkbox' || props.type === 'radio'; - return usesChecked ? props.checked != null : props.value != null; -} +var SEPARATOR = '.'; +var SUBSEPARATOR = ':'; /** - * Implements an <input> host component that allows setting these optional - * props: `checked`, `value`, `defaultChecked`, and `defaultValue`. - * - * If `checked` or `value` are not supplied (or null/undefined), user actions - * that affect the checked state or value will trigger updates to the element. - * - * If they are supplied (and not null/undefined), the rendered element will not - * trigger updates to the element. Instead, the props must change in order for - * the rendered element to be updated. - * - * The rendered element will be initialized as unchecked (or `defaultChecked`) - * with an empty value (or `defaultValue`). + * This is inlined from ReactElement since this file is shared between + * isomorphic and renderers. We could extract this to a * - * @see http://www.w3.org/TR/2012/WD-html5-20121025/the-input-element.html */ -var ReactDOMInput = { - getHostProps: function (inst, props) { - var value = LinkedValueUtils.getValue(props); - var checked = LinkedValueUtils.getChecked(props); - - var hostProps = _assign({ - // Make sure we set .type before any other properties (setting .value - // before .type means .value is lost in IE11 and below) - type: undefined, - // Make sure we set .step before .value (setting .value before .step - // means .value is rounded on mount, based upon step precision) - step: undefined, - // Make sure we set .min & .max before .value (to ensure proper order - // in corner cases such as min or max deriving from value, e.g. Issue #7170) - min: undefined, - max: undefined - }, props, { - defaultChecked: undefined, - defaultValue: undefined, - value: value != null ? value : inst._wrapperState.initialValue, - checked: checked != null ? checked : inst._wrapperState.initialChecked, - onChange: inst._wrapperState.onChange - }); - - return hostProps; - }, - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - LinkedValueUtils.checkPropTypes('input', props, inst._currentElement._owner); +/** + * TODO: Test that a single child and an array with one item have the same key + * pattern. + */ - var owner = inst._currentElement._owner; +var didWarnAboutMaps = false; - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } - if (props.checkedLink !== undefined && !didWarnCheckedLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`checkedLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnCheckedLink = true; - } - if (props.checked !== undefined && props.defaultChecked !== undefined && !didWarnCheckedDefaultChecked) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both checked and defaultChecked props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnCheckedDefaultChecked = true; - } - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both value and defaultValue props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnValueDefaultValue = true; - } - } +/** + * Generate a key string that identifies a component within a set. + * + * @param {*} component A component that could contain a manual key. + * @param {number} index Index that is used if a manual key is not provided. + * @return {string} + */ +function getComponentKey(component, index) { + // Do some typechecking here since we call this blindly. We want to ensure + // that we don't block potential future ES APIs. + if (component && typeof component === 'object' && component.key != null) { + // Explicit key + return KeyEscapeUtils.escape(component.key); + } + // Implicit key determined by the index in the set + return index.toString(36); +} - var defaultValue = props.defaultValue; - inst._wrapperState = { - initialChecked: props.checked != null ? props.checked : props.defaultChecked, - initialValue: props.value != null ? props.value : defaultValue, - listeners: null, - onChange: _handleChange.bind(inst), - controlled: isControlled(props) - }; - }, +/** + * @param {?*} children Children tree container. + * @param {!string} nameSoFar Name of the key path so far. + * @param {!function} callback Callback to invoke with each child found. + * @param {?*} traverseContext Used to pass information throughout the traversal + * process. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { + var type = typeof children; - updateWrapper: function (inst) { - var props = inst._currentElement.props; + if (type === 'undefined' || type === 'boolean') { + // All of the above are perceived as null. + children = null; + } - if (process.env.NODE_ENV !== 'production') { - var controlled = isControlled(props); - var owner = inst._currentElement._owner; + if (children === null || type === 'string' || type === 'number' || + // The following is inlined from ReactElement. This means we can optimize + // some checks. React Fiber also inlines this logic for similar purposes. + type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { + callback(traverseContext, children, + // If it's the only child, treat the name as if it was wrapped in an array + // so that it's consistent if the number of children grows. + nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); + return 1; + } - if (!inst._wrapperState.controlled && controlled && !didWarnUncontrolledToControlled) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing an uncontrolled input of type %s to be controlled. ' + 'Input elements should not switch from uncontrolled to controlled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnUncontrolledToControlled = true; - } - if (inst._wrapperState.controlled && !controlled && !didWarnControlledToUncontrolled) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing a controlled input of type %s to be uncontrolled. ' + 'Input elements should not switch from controlled to uncontrolled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; - didWarnControlledToUncontrolled = true; - } - } + var child; + var nextName; + var subtreeCount = 0; // Count of children found in the current subtree. + var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; - // TODO: Shouldn't this be getChecked(props)? - var checked = props.checked; - if (checked != null) { - DOMPropertyOperations.setValueForProperty(ReactDOMComponentTree.getNodeFromInstance(inst), 'checked', checked || false); + if (Array.isArray(children)) { + for (var i = 0; i < children.length; i++) { + child = children[i]; + nextName = nextNamePrefix + getComponentKey(child, i); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); } - - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var value = LinkedValueUtils.getValue(props); - if (value != null) { - if (value === 0 && node.value === '') { - node.value = '0'; - // Note: IE9 reports a number inputs as 'text', so check props instead. - } else if (props.type === 'number') { - // Simulate `input.valueAsNumber`. IE9 does not support it - var valueAsNumber = parseFloat(node.value, 10) || 0; - - if ( - // eslint-disable-next-line - value != valueAsNumber || - // eslint-disable-next-line - value == valueAsNumber && node.value != value) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - node.value = '' + value; + } else { + var iteratorFn = getIteratorFn(children); + if (iteratorFn) { + var iterator = iteratorFn.call(children); + var step; + if (iteratorFn !== children.entries) { + var ii = 0; + while (!(step = iterator.next()).done) { + child = step.value; + nextName = nextNamePrefix + getComponentKey(child, ii++); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); } - } else if (node.value !== '' + value) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - node.value = '' + value; - } - } else { - if (props.value == null && props.defaultValue != null) { - // In Chrome, assigning defaultValue to certain input types triggers input validation. - // For number inputs, the display value loses trailing decimal points. For email inputs, - // Chrome raises "The specified value <x> is not a valid email address". - // - // Here we check to see if the defaultValue has actually changed, avoiding these problems - // when the user is inputting text - // - // https://github.com/facebook/react/issues/7253 - if (node.defaultValue !== '' + props.defaultValue) { - node.defaultValue = '' + props.defaultValue; + } else { + if (process.env.NODE_ENV !== 'production') { + var mapsAsChildrenAddendum = ''; + if (ReactCurrentOwner.current) { + var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); + if (mapsAsChildrenOwnerName) { + mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; + } + } + process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; + didWarnAboutMaps = true; + } + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + child = entry[1]; + nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } } } - if (props.checked == null && props.defaultChecked != null) { - node.defaultChecked = !!props.defaultChecked; + } else if (type === 'object') { + var addendum = ''; + if (process.env.NODE_ENV !== 'production') { + addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; + if (children._isReactElement) { + addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; + } + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + addendum += ' Check the render method of `' + name + '`.'; + } + } } + var childrenString = String(children); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; } - }, - - postMountWrapper: function (inst) { - var props = inst._currentElement.props; + } - // This is in postMount because we need access to the DOM node, which is not - // available until after the component has mounted. - var node = ReactDOMComponentTree.getNodeFromInstance(inst); + return subtreeCount; +} - // Detach value from defaultValue. We won't do anything if we're working on - // submit or reset inputs as those values & defaultValues are linked. They - // are not resetable nodes so this operation doesn't matter and actually - // removes browser-default values (eg "Submit Query") when no value is - // provided. +/** + * Traverses children that are typically specified as `props.children`, but + * might also be specified through attributes: + * + * - `traverseAllChildren(this.props.children, ...)` + * - `traverseAllChildren(this.props.leftPanelChildren, ...)` + * + * The `traverseContext` is an optional argument that is passed through the + * entire traversal. It can be used to store accumulations or anything else that + * the callback might find relevant. + * + * @param {?*} children Children tree object. + * @param {!function} callback To invoke upon traversing each child. + * @param {?*} traverseContext Context for traversal. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildren(children, callback, traverseContext) { + if (children == null) { + return 0; + } - switch (props.type) { - case 'submit': - case 'reset': - break; - case 'color': - case 'date': - case 'datetime': - case 'datetime-local': - case 'month': - case 'time': - case 'week': - // This fixes the no-show issue on iOS Safari and Android Chrome: - // https://github.com/facebook/react/issues/7233 - node.value = ''; - node.value = node.defaultValue; - break; - default: - node.value = node.value; - break; - } + return traverseAllChildrenImpl(children, '', callback, traverseContext); +} - // Normally, we'd just do `node.checked = node.checked` upon initial mount, less this bug - // this is needed to work around a chrome bug where setting defaultChecked - // will sometimes influence the value of checked (even after detachment). - // Reference: https://bugs.chromium.org/p/chromium/issues/detail?id=608416 - // We need to temporarily unset name to avoid disrupting radio button groups. - var name = node.name; - if (name !== '') { - node.name = ''; - } - node.defaultChecked = !node.defaultChecked; - node.defaultChecked = !node.defaultChecked; - if (name !== '') { - node.name = name; - } - } -}; +module.exports = traverseAllChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -function _handleChange(event) { - var props = this._currentElement.props; +/***/ }), +/* 146 */ +/***/ (function(module, exports, __webpack_require__) { - var returnValue = LinkedValueUtils.executeOnChange(props, event); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { - // Here we use asap to wait until all updates have propagated, which - // is important when using controlled components within layers: - // https://github.com/facebook/react/issues/1698 - ReactUpdates.asap(forceUpdateIfMounted, this); +/** + * Copyright (c) 2013-present, Facebook, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * @typechecks + */ - var name = props.name; - if (props.type === 'radio' && name != null) { - var rootNode = ReactDOMComponentTree.getNodeFromInstance(this); - var queryRoot = rootNode; +var emptyFunction = __webpack_require__(18); - while (queryRoot.parentNode) { - queryRoot = queryRoot.parentNode; +/** + * Upstream version of event listener. Does not take into account specific + * nature of platform. + */ +var EventListener = { + /** + * Listen to DOM events during the bubble phase. + * + * @param {DOMEventTarget} target DOM element to register listener on. + * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. + * @param {function} callback Callback function. + * @return {object} Object with a `remove` method. + */ + listen: function listen(target, eventType, callback) { + if (target.addEventListener) { + target.addEventListener(eventType, callback, false); + return { + remove: function remove() { + target.removeEventListener(eventType, callback, false); + } + }; + } else if (target.attachEvent) { + target.attachEvent('on' + eventType, callback); + return { + remove: function remove() { + target.detachEvent('on' + eventType, callback); + } + }; } + }, - // If `rootNode.form` was non-null, then we could try `form.elements`, - // but that sometimes behaves strangely in IE8. We could also try using - // `form.getElementsByName`, but that will only return direct children - // and won't include inputs that use the HTML5 `form=` attribute. Since - // the input might not even be in a form, let's just use the global - // `querySelectorAll` to ensure we don't miss anything. - var group = queryRoot.querySelectorAll('input[name=' + JSON.stringify('' + name) + '][type="radio"]'); - - for (var i = 0; i < group.length; i++) { - var otherNode = group[i]; - if (otherNode === rootNode || otherNode.form !== rootNode.form) { - continue; + /** + * Listen to DOM events during the capture phase. + * + * @param {DOMEventTarget} target DOM element to register listener on. + * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. + * @param {function} callback Callback function. + * @return {object} Object with a `remove` method. + */ + capture: function capture(target, eventType, callback) { + if (target.addEventListener) { + target.addEventListener(eventType, callback, true); + return { + remove: function remove() { + target.removeEventListener(eventType, callback, true); + } + }; + } else { + if (process.env.NODE_ENV !== 'production') { + console.error('Attempted to listen to events during the capture phase on a ' + 'browser that does not support the capture phase. Your application ' + 'will not receive some events.'); } - // This will throw if radio buttons rendered by different copies of React - // and the same name are rendered into the same form (same as #1939). - // That's probably okay; we don't support it just as we don't support - // mixing React radio buttons with non-React ones. - var otherInstance = ReactDOMComponentTree.getInstanceFromNode(otherNode); - !otherInstance ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOMInput: Mixing React and non-React radio inputs with the same `name` is not supported.') : _prodInvariant('90') : void 0; - // If this is a controlled radio button group, forcing the input that - // was previously checked to update will cause it to be come re-checked - // as appropriate. - ReactUpdates.asap(forceUpdateIfMounted, otherInstance); + return { + remove: emptyFunction + }; } - } + }, - return returnValue; -} + registerDefault: function registerDefault() {} +}; -module.exports = ReactDOMInput; +module.exports = EventListener; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 172 */ +/* 147 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** +/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -29566,285 +26360,163 @@ module.exports = ReactDOMInput; -var _assign = __webpack_require__(5); +var ReactDOMSelection = __webpack_require__(288); -var React = __webpack_require__(24); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactDOMSelect = __webpack_require__(95); +var containsNode = __webpack_require__(290); +var focusNode = __webpack_require__(136); +var getActiveElement = __webpack_require__(148); -var warning = __webpack_require__(2); -var didWarnInvalidOptionChildren = false; +function isInDocument(node) { + return containsNode(document.documentElement, node); +} -function flattenChildren(children) { - var content = ''; +/** + * @ReactInputSelection: React input selection module. Based on Selection.js, + * but modified to be suitable for react and has a couple of bug fixes (doesn't + * assume buttons have range selections allowed). + * Input selection module for React. + */ +var ReactInputSelection = { + hasSelectionCapabilities: function (elem) { + var nodeName = elem && elem.nodeName && elem.nodeName.toLowerCase(); + return nodeName && (nodeName === 'input' && elem.type === 'text' || nodeName === 'textarea' || elem.contentEditable === 'true'); + }, - // Flatten children and warn if they aren't strings or numbers; - // invalid types are ignored. - React.Children.forEach(children, function (child) { - if (child == null) { - return; - } - if (typeof child === 'string' || typeof child === 'number') { - content += child; - } else if (!didWarnInvalidOptionChildren) { - didWarnInvalidOptionChildren = true; - process.env.NODE_ENV !== 'production' ? warning(false, 'Only strings and numbers are supported as <option> children.') : void 0; - } - }); - - return content; -} - -/** - * Implements an <option> host component that warns when `selected` is set. - */ -var ReactDOMOption = { - mountWrapper: function (inst, props, hostParent) { - // TODO (yungsters): Remove support for `selected` in <option>. - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(props.selected == null, 'Use the `defaultValue` or `value` props on <select> instead of ' + 'setting `selected` on <option>.') : void 0; - } - - // Look up whether this option is 'selected' - var selectValue = null; - if (hostParent != null) { - var selectParent = hostParent; - - if (selectParent._tag === 'optgroup') { - selectParent = selectParent._hostParent; - } + getSelectionInformation: function () { + var focusedElem = getActiveElement(); + return { + focusedElem: focusedElem, + selectionRange: ReactInputSelection.hasSelectionCapabilities(focusedElem) ? ReactInputSelection.getSelection(focusedElem) : null + }; + }, - if (selectParent != null && selectParent._tag === 'select') { - selectValue = ReactDOMSelect.getSelectValueContext(selectParent); + /** + * @restoreSelection: If any selection information was potentially lost, + * restore it. This is useful when performing operations that could remove dom + * nodes and place them back in, resulting in focus being lost. + */ + restoreSelection: function (priorSelectionInformation) { + var curFocusedElem = getActiveElement(); + var priorFocusedElem = priorSelectionInformation.focusedElem; + var priorSelectionRange = priorSelectionInformation.selectionRange; + if (curFocusedElem !== priorFocusedElem && isInDocument(priorFocusedElem)) { + if (ReactInputSelection.hasSelectionCapabilities(priorFocusedElem)) { + ReactInputSelection.setSelection(priorFocusedElem, priorSelectionRange); } + focusNode(priorFocusedElem); } + }, - // If the value is null (e.g., no specified value or after initial mount) - // or missing (e.g., for <datalist>), we don't change props.selected - var selected = null; - if (selectValue != null) { - var value; - if (props.value != null) { - value = props.value + ''; - } else { - value = flattenChildren(props.children); - } - selected = false; - if (Array.isArray(selectValue)) { - // multiple - for (var i = 0; i < selectValue.length; i++) { - if ('' + selectValue[i] === value) { - selected = true; - break; - } - } - } else { - selected = '' + selectValue === value; + /** + * @getSelection: Gets the selection bounds of a focused textarea, input or + * contentEditable node. + * -@input: Look up selection bounds of this input + * -@return {start: selectionStart, end: selectionEnd} + */ + getSelection: function (input) { + var selection; + + if ('selectionStart' in input) { + // Modern browser with input or textarea. + selection = { + start: input.selectionStart, + end: input.selectionEnd + }; + } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { + // IE8 input. + var range = document.selection.createRange(); + // There can only be one selection per document in IE, so it must + // be in our element. + if (range.parentElement() === input) { + selection = { + start: -range.moveStart('character', -input.value.length), + end: -range.moveEnd('character', -input.value.length) + }; } + } else { + // Content editable or old IE textarea. + selection = ReactDOMSelection.getOffsets(input); } - inst._wrapperState = { selected: selected }; - }, - - postMountWrapper: function (inst) { - // value="" should make a value attribute (#6219) - var props = inst._currentElement.props; - if (props.value != null) { - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - node.setAttribute('value', props.value); - } + return selection || { start: 0, end: 0 }; }, - getHostProps: function (inst, props) { - var hostProps = _assign({ selected: undefined, children: undefined }, props); - - // Read state only from initial mount because <select> updates value - // manually; we need the initial state only for server rendering - if (inst._wrapperState.selected != null) { - hostProps.selected = inst._wrapperState.selected; + /** + * @setSelection: Sets the selection bounds of a textarea or input and focuses + * the input. + * -@input Set selection bounds of this input or textarea + * -@offsets Object of same form that is returned from get* + */ + setSelection: function (input, offsets) { + var start = offsets.start; + var end = offsets.end; + if (end === undefined) { + end = start; } - var content = flattenChildren(props.children); - - if (content) { - hostProps.children = content; + if ('selectionStart' in input) { + input.selectionStart = start; + input.selectionEnd = Math.min(end, input.value.length); + } else if (document.selection && input.nodeName && input.nodeName.toLowerCase() === 'input') { + var range = input.createTextRange(); + range.collapse(true); + range.moveStart('character', start); + range.moveEnd('character', end - start); + range.select(); + } else { + ReactDOMSelection.setOffsets(input, offsets); } - - return hostProps; } }; -module.exports = ReactDOMOption; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = ReactInputSelection; /***/ }), -/* 173 */ +/* 148 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. + + +/** + * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * + * @typechecks */ - - -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); - -var LinkedValueUtils = __webpack_require__(58); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); - -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); - -var didWarnValueLink = false; -var didWarnValDefaultVal = false; - -function forceUpdateIfMounted() { - if (this._rootNodeID) { - // DOM component is still mounted; update - ReactDOMTextarea.updateWrapper(this); - } -} +/* eslint-disable fb-www/typeof-undefined */ /** - * Implements a <textarea> host component that allows setting `value`, and - * `defaultValue`. This differs from the traditional DOM API because value is - * usually set as PCDATA children. - * - * If `value` is not supplied (or null/undefined), user actions that affect the - * value will trigger updates to the element. + * Same as document.activeElement but wraps in a try-catch block. In IE it is + * not safe to call document.activeElement if there is nothing focused. * - * If `value` is supplied (and not null/undefined), the rendered element will - * not trigger updates to the element. Instead, the `value` prop must change in - * order for the rendered element to be updated. + * The activeElement will be null only if the document or document body is not + * yet defined. * - * The rendered element will be initialized with an empty value, the prop - * `defaultValue` if specified, or the children content (deprecated). + * @param {?DOMDocument} doc Defaults to current document. + * @return {?DOMElement} */ -var ReactDOMTextarea = { - getHostProps: function (inst, props) { - !(props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`dangerouslySetInnerHTML` does not make sense on <textarea>.') : _prodInvariant('91') : void 0; - - // Always set children to the same thing. In IE9, the selection range will - // get reset if `textContent` is mutated. We could add a check in setTextContent - // to only set the value if/when the value differs from the node value (which would - // completely solve this IE9 bug), but Sebastian+Ben seemed to like this solution. - // The value can be a boolean or object so that's why it's forced to be a string. - var hostProps = _assign({}, props, { - value: undefined, - defaultValue: undefined, - children: '' + inst._wrapperState.initialValue, - onChange: inst._wrapperState.onChange - }); - - return hostProps; - }, - - mountWrapper: function (inst, props) { - if (process.env.NODE_ENV !== 'production') { - LinkedValueUtils.checkPropTypes('textarea', props, inst._currentElement._owner); - if (props.valueLink !== undefined && !didWarnValueLink) { - process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `textarea` is deprecated; set `value` and `onChange` instead.') : void 0; - didWarnValueLink = true; - } - if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValDefaultVal) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Textarea elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; - didWarnValDefaultVal = true; - } - } - - var value = LinkedValueUtils.getValue(props); - var initialValue = value; - - // Only bother fetching default value if we're going to use it - if (value == null) { - var defaultValue = props.defaultValue; - // TODO (yungsters): Remove support for children content in <textarea>. - var children = props.children; - if (children != null) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(false, 'Use the `defaultValue` or `value` props instead of setting ' + 'children on <textarea>.') : void 0; - } - !(defaultValue == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'If you supply `defaultValue` on a <textarea>, do not pass children.') : _prodInvariant('92') : void 0; - if (Array.isArray(children)) { - !(children.length <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, '<textarea> can only have at most one child.') : _prodInvariant('93') : void 0; - children = children[0]; - } - - defaultValue = '' + children; - } - if (defaultValue == null) { - defaultValue = ''; - } - initialValue = defaultValue; - } - - inst._wrapperState = { - initialValue: '' + initialValue, - listeners: null, - onChange: _handleChange.bind(inst) - }; - }, - - updateWrapper: function (inst) { - var props = inst._currentElement.props; - - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var value = LinkedValueUtils.getValue(props); - if (value != null) { - // Cast `value` to a string to ensure the value is set correctly. While - // browsers typically do this as necessary, jsdom doesn't. - var newValue = '' + value; - - // To avoid side effects (such as losing text selection), only set value if changed - if (newValue !== node.value) { - node.value = newValue; - } - if (props.defaultValue == null) { - node.defaultValue = newValue; - } - } - if (props.defaultValue != null) { - node.defaultValue = props.defaultValue; - } - }, - - postMountWrapper: function (inst) { - // This is in postMount because we need access to the DOM node, which is not - // available until after the component has mounted. - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - var textContent = node.textContent; - - // Only set node.value if textContent is equal to the expected - // initial value. In IE10/IE11 there is a bug where the placeholder attribute - // will populate textContent as well. - // https://developer.microsoft.com/microsoft-edge/platform/issues/101525/ - if (textContent === inst._wrapperState.initialValue) { - node.value = textContent; - } +function getActiveElement(doc) /*?DOMElement*/{ + doc = doc || (typeof document !== 'undefined' ? document : undefined); + if (typeof doc === 'undefined') { + return null; + } + try { + return doc.activeElement || doc.body; + } catch (e) { + return doc.body; } -}; - -function _handleChange(event) { - var props = this._currentElement.props; - var returnValue = LinkedValueUtils.executeOnChange(props, event); - ReactUpdates.asap(forceUpdateIfMounted, this); - return returnValue; } -module.exports = ReactDOMTextarea; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +module.exports = getActiveElement; /***/ }), -/* 174 */ +/* 149 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -29860,606 +26532,539 @@ module.exports = ReactDOMTextarea; -var _prodInvariant = __webpack_require__(3); +var _prodInvariant = __webpack_require__(5); + +var DOMLazyTree = __webpack_require__(39); +var DOMProperty = __webpack_require__(28); +var React = __webpack_require__(36); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactCurrentOwner = __webpack_require__(22); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMContainerInfo = __webpack_require__(305); +var ReactDOMFeatureFlags = __webpack_require__(306); +var ReactFeatureFlags = __webpack_require__(131); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactMarkupChecksum = __webpack_require__(307); +var ReactReconciler = __webpack_require__(38); +var ReactUpdateQueue = __webpack_require__(90); +var ReactUpdates = __webpack_require__(23); + +var emptyObject = __webpack_require__(56); +var instantiateReactComponent = __webpack_require__(141); +var invariant = __webpack_require__(2); +var setInnerHTML = __webpack_require__(60); +var shouldUpdateReactComponent = __webpack_require__(88); +var warning = __webpack_require__(3); -var ReactComponentEnvironment = __webpack_require__(59); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); +var ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME; +var ROOT_ATTR_NAME = DOMProperty.ROOT_ATTRIBUTE_NAME; -var ReactCurrentOwner = __webpack_require__(14); -var ReactReconciler = __webpack_require__(26); -var ReactChildReconciler = __webpack_require__(175); +var ELEMENT_NODE_TYPE = 1; +var DOC_NODE_TYPE = 9; +var DOCUMENT_FRAGMENT_NODE_TYPE = 11; -var emptyFunction = __webpack_require__(12); -var flattenChildren = __webpack_require__(182); -var invariant = __webpack_require__(1); +var instancesByReactRootID = {}; /** - * Make an update for markup to be rendered and inserted at a supplied index. + * Finds the index of the first character + * that's not common between the two given strings. * - * @param {string} markup Markup that renders into an element. - * @param {number} toIndex Destination index. - * @private + * @return {number} the index of the character where the strings diverge */ -function makeInsertMarkup(markup, afterNode, toIndex) { - // NOTE: Null values reduce hidden classes. - return { - type: 'INSERT_MARKUP', - content: markup, - fromIndex: null, - fromNode: null, - toIndex: toIndex, - afterNode: afterNode - }; +function firstDifferenceIndex(string1, string2) { + var minLen = Math.min(string1.length, string2.length); + for (var i = 0; i < minLen; i++) { + if (string1.charAt(i) !== string2.charAt(i)) { + return i; + } + } + return string1.length === string2.length ? -1 : minLen; } /** - * Make an update for moving an existing element to another index. - * - * @param {number} fromIndex Source index of the existing element. - * @param {number} toIndex Destination index of the element. - * @private + * @param {DOMElement|DOMDocument} container DOM element that may contain + * a React component + * @return {?*} DOM element that may have the reactRoot ID, or null. */ -function makeMove(child, afterNode, toIndex) { - // NOTE: Null values reduce hidden classes. - return { - type: 'MOVE_EXISTING', - content: null, - fromIndex: child._mountIndex, - fromNode: ReactReconciler.getHostNode(child), - toIndex: toIndex, - afterNode: afterNode - }; +function getReactRootElementInContainer(container) { + if (!container) { + return null; + } + + if (container.nodeType === DOC_NODE_TYPE) { + return container.documentElement; + } else { + return container.firstChild; + } +} + +function internalGetID(node) { + // If node is something like a window, document, or text node, none of + // which support attributes or a .getAttribute method, gracefully return + // the empty string, as if the attribute were missing. + return node.getAttribute && node.getAttribute(ATTR_NAME) || ''; } /** - * Make an update for removing an element at an index. + * Mounts this component and inserts it into the DOM. * - * @param {number} fromIndex Index of the element to remove. - * @private + * @param {ReactComponent} componentInstance The instance to mount. + * @param {DOMElement} container DOM element to mount into. + * @param {ReactReconcileTransaction} transaction + * @param {boolean} shouldReuseMarkup If true, do not insert markup */ -function makeRemove(child, node) { - // NOTE: Null values reduce hidden classes. - return { - type: 'REMOVE_NODE', - content: null, - fromIndex: child._mountIndex, - fromNode: node, - toIndex: null, - afterNode: null - }; +function mountComponentIntoNode(wrapperInstance, container, transaction, shouldReuseMarkup, context) { + var markerName; + if (ReactFeatureFlags.logTopLevelRenders) { + var wrappedElement = wrapperInstance._currentElement.props.child; + var type = wrappedElement.type; + markerName = 'React mount: ' + (typeof type === 'string' ? type : type.displayName || type.name); + console.time(markerName); + } + + var markup = ReactReconciler.mountComponent(wrapperInstance, transaction, null, ReactDOMContainerInfo(wrapperInstance, container), context, 0 /* parentDebugID */ + ); + + if (markerName) { + console.timeEnd(markerName); + } + + wrapperInstance._renderedComponent._topLevelWrapper = wrapperInstance; + ReactMount._mountImageIntoNode(markup, container, wrapperInstance, shouldReuseMarkup, transaction); } /** - * Make an update for setting the markup of a node. + * Batched mount. * - * @param {string} markup Markup that renders into an element. - * @private + * @param {ReactComponent} componentInstance The instance to mount. + * @param {DOMElement} container DOM element to mount into. + * @param {boolean} shouldReuseMarkup If true, do not insert markup */ -function makeSetMarkup(markup) { - // NOTE: Null values reduce hidden classes. - return { - type: 'SET_MARKUP', - content: markup, - fromIndex: null, - fromNode: null, - toIndex: null, - afterNode: null - }; +function batchedMountComponentIntoNode(componentInstance, container, shouldReuseMarkup, context) { + var transaction = ReactUpdates.ReactReconcileTransaction.getPooled( + /* useCreateElement */ + !shouldReuseMarkup && ReactDOMFeatureFlags.useCreateElement); + transaction.perform(mountComponentIntoNode, null, componentInstance, container, transaction, shouldReuseMarkup, context); + ReactUpdates.ReactReconcileTransaction.release(transaction); } /** - * Make an update for setting the text content. + * Unmounts a component and removes it from the DOM. * - * @param {string} textContent Text content to set. - * @private + * @param {ReactComponent} instance React component instance. + * @param {DOMElement} container DOM element to unmount from. + * @final + * @internal + * @see {ReactMount.unmountComponentAtNode} */ -function makeTextContent(textContent) { - // NOTE: Null values reduce hidden classes. - return { - type: 'TEXT_CONTENT', - content: textContent, - fromIndex: null, - fromNode: null, - toIndex: null, - afterNode: null - }; +function unmountComponentFromNode(instance, container, safely) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onBeginFlush(); + } + ReactReconciler.unmountComponent(instance, safely); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onEndFlush(); + } + + if (container.nodeType === DOC_NODE_TYPE) { + container = container.documentElement; + } + + // http://jsperf.com/emptying-a-node + while (container.lastChild) { + container.removeChild(container.lastChild); + } } /** - * Push an update, if any, onto the queue. Creates a new queue if none is - * passed and always returns the queue. Mutative. + * True if the supplied DOM node has a direct React-rendered child that is + * not a React root element. Useful for warning in `render`, + * `unmountComponentAtNode`, etc. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM element contains a direct child that was + * rendered by React but is not a root element. + * @internal */ -function enqueue(queue, update) { - if (update) { - queue = queue || []; - queue.push(update); +function hasNonRootReactChild(container) { + var rootEl = getReactRootElementInContainer(container); + if (rootEl) { + var inst = ReactDOMComponentTree.getInstanceFromNode(rootEl); + return !!(inst && inst._hostParent); } - return queue; } /** - * Processes any enqueued updates. + * True if the supplied DOM node is a React DOM element and + * it has been rendered by another copy of React. * - * @private + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM has been rendered by another copy of React + * @internal */ -function processQueue(inst, updateQueue) { - ReactComponentEnvironment.processChildrenUpdates(inst, updateQueue); -} - -var setChildrenForInstrumentation = emptyFunction; -if (process.env.NODE_ENV !== 'production') { - var getDebugID = function (inst) { - if (!inst._debugID) { - // Check for ART-like instances. TODO: This is silly/gross. - var internal; - if (internal = ReactInstanceMap.get(inst)) { - inst = internal; - } - } - return inst._debugID; - }; - setChildrenForInstrumentation = function (children) { - var debugID = getDebugID(this); - // TODO: React Native empty components are also multichild. - // This means they still get into this method but don't have _debugID. - if (debugID !== 0) { - ReactInstrumentation.debugTool.onSetChildren(debugID, children ? Object.keys(children).map(function (key) { - return children[key]._debugID; - }) : []); - } - }; +function nodeIsRenderedByOtherInstance(container) { + var rootEl = getReactRootElementInContainer(container); + return !!(rootEl && isReactNode(rootEl) && !ReactDOMComponentTree.getInstanceFromNode(rootEl)); } /** - * ReactMultiChild are capable of reconciling multiple children. + * True if the supplied DOM node is a valid node element. * - * @class ReactMultiChild + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM is a valid DOM node. * @internal */ -var ReactMultiChild = { - /** - * Provides common functionality for components that must reconcile multiple - * children. This is used by `ReactDOMComponent` to mount, update, and - * unmount child components. - * - * @lends {ReactMultiChild.prototype} - */ - Mixin: { - _reconcilerInstantiateChildren: function (nestedChildren, transaction, context) { - if (process.env.NODE_ENV !== 'production') { - var selfDebugID = getDebugID(this); - if (this._currentElement) { - try { - ReactCurrentOwner.current = this._currentElement._owner; - return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context, selfDebugID); - } finally { - ReactCurrentOwner.current = null; - } - } - } - return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context); - }, - - _reconcilerUpdateChildren: function (prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context) { - var nextChildren; - var selfDebugID = 0; - if (process.env.NODE_ENV !== 'production') { - selfDebugID = getDebugID(this); - if (this._currentElement) { - try { - ReactCurrentOwner.current = this._currentElement._owner; - nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); - } finally { - ReactCurrentOwner.current = null; - } - ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); - return nextChildren; - } - } - nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); - ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); - return nextChildren; - }, +function isValidContainer(node) { + return !!(node && (node.nodeType === ELEMENT_NODE_TYPE || node.nodeType === DOC_NODE_TYPE || node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE)); +} - /** - * Generates a "mount image" for each of the supplied children. In the case - * of `ReactDOMComponent`, a mount image is a string of markup. - * - * @param {?object} nestedChildren Nested child maps. - * @return {array} An array of mounted representations. - * @internal - */ - mountChildren: function (nestedChildren, transaction, context) { - var children = this._reconcilerInstantiateChildren(nestedChildren, transaction, context); - this._renderedChildren = children; +/** + * True if the supplied DOM node is a valid React node element. + * + * @param {?DOMElement} node The candidate DOM node. + * @return {boolean} True if the DOM is a valid React DOM node. + * @internal + */ +function isReactNode(node) { + return isValidContainer(node) && (node.hasAttribute(ROOT_ATTR_NAME) || node.hasAttribute(ATTR_NAME)); +} - var mountImages = []; - var index = 0; - for (var name in children) { - if (children.hasOwnProperty(name)) { - var child = children[name]; - var selfDebugID = 0; - if (process.env.NODE_ENV !== 'production') { - selfDebugID = getDebugID(this); - } - var mountImage = ReactReconciler.mountComponent(child, transaction, this, this._hostContainerInfo, context, selfDebugID); - child._mountIndex = index++; - mountImages.push(mountImage); - } - } +function getHostRootInstanceInContainer(container) { + var rootEl = getReactRootElementInContainer(container); + var prevHostInstance = rootEl && ReactDOMComponentTree.getInstanceFromNode(rootEl); + return prevHostInstance && !prevHostInstance._hostParent ? prevHostInstance : null; +} - if (process.env.NODE_ENV !== 'production') { - setChildrenForInstrumentation.call(this, children); - } +function getTopLevelWrapperInContainer(container) { + var root = getHostRootInstanceInContainer(container); + return root ? root._hostContainerInfo._topLevelWrapper : null; +} - return mountImages; - }, +/** + * Temporary (?) hack so that we can store all top-level pending updates on + * composites instead of having to worry about different types of components + * here. + */ +var topLevelRootCounter = 1; +var TopLevelWrapper = function () { + this.rootID = topLevelRootCounter++; +}; +TopLevelWrapper.prototype.isReactComponent = {}; +if (process.env.NODE_ENV !== 'production') { + TopLevelWrapper.displayName = 'TopLevelWrapper'; +} +TopLevelWrapper.prototype.render = function () { + return this.props.child; +}; +TopLevelWrapper.isReactTopLevelWrapper = true; - /** - * Replaces any rendered children with a text content string. - * - * @param {string} nextContent String of content. - * @internal - */ - updateTextContent: function (nextContent) { - var prevChildren = this._renderedChildren; - // Remove any rendered children. - ReactChildReconciler.unmountChildren(prevChildren, false); - for (var name in prevChildren) { - if (prevChildren.hasOwnProperty(name)) { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; - } - } - // Set new text content. - var updates = [makeTextContent(nextContent)]; - processQueue(this, updates); - }, +/** + * Mounting is the process of initializing a React component by creating its + * representative DOM elements and inserting them into a supplied `container`. + * Any prior content inside `container` is destroyed in the process. + * + * ReactMount.render( + * component, + * document.getElementById('container') + * ); + * + * <div id="container"> <-- Supplied `container`. + * <div data-reactid=".3"> <-- Rendered reactRoot of React + * // ... component. + * </div> + * </div> + * + * Inside of `container`, the first element rendered is the "reactRoot". + */ +var ReactMount = { + TopLevelWrapper: TopLevelWrapper, - /** - * Replaces any rendered children with a markup string. - * - * @param {string} nextMarkup String of markup. - * @internal - */ - updateMarkup: function (nextMarkup) { - var prevChildren = this._renderedChildren; - // Remove any rendered children. - ReactChildReconciler.unmountChildren(prevChildren, false); - for (var name in prevChildren) { - if (prevChildren.hasOwnProperty(name)) { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; - } - } - var updates = [makeSetMarkup(nextMarkup)]; - processQueue(this, updates); - }, + /** + * Used by devtools. The keys are not important. + */ + _instancesByReactRootID: instancesByReactRootID, - /** - * Updates the rendered children with new children. - * - * @param {?object} nextNestedChildrenElements Nested child element maps. - * @param {ReactReconcileTransaction} transaction - * @internal - */ - updateChildren: function (nextNestedChildrenElements, transaction, context) { - // Hook used by React ART - this._updateChildren(nextNestedChildrenElements, transaction, context); - }, + /** + * This is a hook provided to support rendering React components while + * ensuring that the apparent scroll position of its `container` does not + * change. + * + * @param {DOMElement} container The `container` being rendered into. + * @param {function} renderCallback This must be called once to do the render. + */ + scrollMonitor: function (container, renderCallback) { + renderCallback(); + }, - /** - * @param {?object} nextNestedChildrenElements Nested child element maps. - * @param {ReactReconcileTransaction} transaction - * @final - * @protected - */ - _updateChildren: function (nextNestedChildrenElements, transaction, context) { - var prevChildren = this._renderedChildren; - var removedNodes = {}; - var mountImages = []; - var nextChildren = this._reconcilerUpdateChildren(prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context); - if (!nextChildren && !prevChildren) { - return; - } - var updates = null; - var name; - // `nextIndex` will increment for each child in `nextChildren`, but - // `lastIndex` will be the last index visited in `prevChildren`. - var nextIndex = 0; - var lastIndex = 0; - // `nextMountIndex` will increment for each newly mounted child. - var nextMountIndex = 0; - var lastPlacedNode = null; - for (name in nextChildren) { - if (!nextChildren.hasOwnProperty(name)) { - continue; - } - var prevChild = prevChildren && prevChildren[name]; - var nextChild = nextChildren[name]; - if (prevChild === nextChild) { - updates = enqueue(updates, this.moveChild(prevChild, lastPlacedNode, nextIndex, lastIndex)); - lastIndex = Math.max(prevChild._mountIndex, lastIndex); - prevChild._mountIndex = nextIndex; - } else { - if (prevChild) { - // Update `lastIndex` before `_mountIndex` gets unset by unmounting. - lastIndex = Math.max(prevChild._mountIndex, lastIndex); - // The `removedNodes` loop below will actually remove the child. - } - // The child must be instantiated before it's mounted. - updates = enqueue(updates, this._mountChildAtIndex(nextChild, mountImages[nextMountIndex], lastPlacedNode, nextIndex, transaction, context)); - nextMountIndex++; - } - nextIndex++; - lastPlacedNode = ReactReconciler.getHostNode(nextChild); - } - // Remove children that are no longer present. - for (name in removedNodes) { - if (removedNodes.hasOwnProperty(name)) { - updates = enqueue(updates, this._unmountChild(prevChildren[name], removedNodes[name])); - } - } - if (updates) { - processQueue(this, updates); + /** + * Take a component that's already mounted into the DOM and replace its props + * @param {ReactComponent} prevComponent component instance already in the DOM + * @param {ReactElement} nextElement component instance to render + * @param {DOMElement} container container to render into + * @param {?function} callback function triggered on completion + */ + _updateRootComponent: function (prevComponent, nextElement, nextContext, container, callback) { + ReactMount.scrollMonitor(container, function () { + ReactUpdateQueue.enqueueElementInternal(prevComponent, nextElement, nextContext); + if (callback) { + ReactUpdateQueue.enqueueCallbackInternal(prevComponent, callback); } - this._renderedChildren = nextChildren; + }); - if (process.env.NODE_ENV !== 'production') { - setChildrenForInstrumentation.call(this, nextChildren); - } - }, + return prevComponent; + }, - /** - * Unmounts all rendered children. This should be used to clean up children - * when this component is unmounted. It does not actually perform any - * backend operations. - * - * @internal - */ - unmountChildren: function (safely) { - var renderedChildren = this._renderedChildren; - ReactChildReconciler.unmountChildren(renderedChildren, safely); - this._renderedChildren = null; - }, + /** + * Render a new component into the DOM. Hooked by hooks! + * + * @param {ReactElement} nextElement element to render + * @param {DOMElement} container container to render into + * @param {boolean} shouldReuseMarkup if we should skip the markup insertion + * @return {ReactComponent} nextComponent + */ + _renderNewRootComponent: function (nextElement, container, shouldReuseMarkup, context) { + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, '_renderNewRootComponent(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from ' + 'render is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; - /** - * Moves a child component to the supplied index. - * - * @param {ReactComponent} child Component to move. - * @param {number} toIndex Destination index of the element. - * @param {number} lastIndex Last index visited of the siblings of `child`. - * @protected - */ - moveChild: function (child, afterNode, toIndex, lastIndex) { - // If the index of `child` is less than `lastIndex`, then it needs to - // be moved. Otherwise, we do not need to move it because a child will be - // inserted or moved before `child`. - if (child._mountIndex < lastIndex) { - return makeMove(child, afterNode, toIndex); - } - }, + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, '_registerComponent(...): Target container is not a DOM element.') : _prodInvariant('37') : void 0; - /** - * Creates a child component. - * - * @param {ReactComponent} child Component to create. - * @param {string} mountImage Markup to insert. - * @protected - */ - createChild: function (child, afterNode, mountImage) { - return makeInsertMarkup(mountImage, afterNode, child._mountIndex); - }, + ReactBrowserEventEmitter.ensureScrollValueMonitoring(); + var componentInstance = instantiateReactComponent(nextElement, false); - /** - * Removes a child component. - * - * @param {ReactComponent} child Child to remove. - * @protected - */ - removeChild: function (child, node) { - return makeRemove(child, node); - }, + // The initial render is synchronous but any updates that happen during + // rendering, in componentWillMount or componentDidMount, will be batched + // according to the current batching strategy. - /** - * Mounts a child with the supplied name. - * - * NOTE: This is part of `updateChildren` and is here for readability. - * - * @param {ReactComponent} child Component to mount. - * @param {string} name Name of the child. - * @param {number} index Index at which to insert the child. - * @param {ReactReconcileTransaction} transaction - * @private - */ - _mountChildAtIndex: function (child, mountImage, afterNode, index, transaction, context) { - child._mountIndex = index; - return this.createChild(child, afterNode, mountImage); - }, + ReactUpdates.batchedUpdates(batchedMountComponentIntoNode, componentInstance, container, shouldReuseMarkup, context); - /** - * Unmounts a rendered child. - * - * NOTE: This is part of `updateChildren` and is here for readability. - * - * @param {ReactComponent} child Component to unmount. - * @private - */ - _unmountChild: function (child, node) { - var update = this.removeChild(child, node); - child._mountIndex = null; - return update; - } - } -}; + var wrapperID = componentInstance._instance.rootID; + instancesByReactRootID[wrapperID] = componentInstance; -module.exports = ReactMultiChild; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return componentInstance; + }, -/***/ }), -/* 175 */ -/***/ (function(module, exports, __webpack_require__) { + /** + * Renders a React component into the DOM in the supplied `container`. + * + * If the React component was previously rendered into `container`, this will + * perform an update on it and only mutate the DOM as necessary to reflect the + * latest React component. + * + * @param {ReactComponent} parentComponent The conceptual parent of this render tree. + * @param {ReactElement} nextElement Component element to render. + * @param {DOMElement} container DOM element to render into. + * @param {?function} callback function triggered on completion + * @return {ReactComponent} Component instance rendered in `container`. + */ + renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { + !(parentComponent != null && ReactInstanceMap.has(parentComponent)) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'parentComponent must be a valid React Component') : _prodInvariant('38') : void 0; + return ReactMount._renderSubtreeIntoContainer(parentComponent, nextElement, container, callback); + }, -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + _renderSubtreeIntoContainer: function (parentComponent, nextElement, container, callback) { + ReactUpdateQueue.validateCallback(callback, 'ReactDOM.render'); + !React.isValidElement(nextElement) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOM.render(): Invalid component element.%s', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : // Check if it quacks like an element + nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : _prodInvariant('39', typeof nextElement === 'string' ? " Instead of passing a string like 'div', pass " + "React.createElement('div') or <div />." : typeof nextElement === 'function' ? ' Instead of passing a class like Foo, pass ' + 'React.createElement(Foo) or <Foo />.' : nextElement != null && nextElement.props !== undefined ? ' This may be caused by unintentionally loading two independent ' + 'copies of React.' : '') : void 0; + + process.env.NODE_ENV !== 'production' ? warning(!container || !container.tagName || container.tagName.toUpperCase() !== 'BODY', 'render(): Rendering components directly into document.body is ' + 'discouraged, since its children are often manipulated by third-party ' + 'scripts and browser extensions. This may lead to subtle ' + 'reconciliation issues. Try rendering into a container element created ' + 'for your app.') : void 0; + var nextWrappedElement = React.createElement(TopLevelWrapper, { + child: nextElement + }); + var nextContext; + if (parentComponent) { + var parentInst = ReactInstanceMap.get(parentComponent); + nextContext = parentInst._processChildContext(parentInst._context); + } else { + nextContext = emptyObject; + } -var ReactReconciler = __webpack_require__(26); + var prevComponent = getTopLevelWrapperInContainer(container); -var instantiateReactComponent = __webpack_require__(96); -var KeyEscapeUtils = __webpack_require__(62); -var shouldUpdateReactComponent = __webpack_require__(61); -var traverseAllChildren = __webpack_require__(100); -var warning = __webpack_require__(2); + if (prevComponent) { + var prevWrappedElement = prevComponent._currentElement; + var prevElement = prevWrappedElement.props.child; + if (shouldUpdateReactComponent(prevElement, nextElement)) { + var publicInst = prevComponent._renderedComponent.getPublicInstance(); + var updatedCallback = callback && function () { + callback.call(publicInst); + }; + ReactMount._updateRootComponent(prevComponent, nextWrappedElement, nextContext, container, updatedCallback); + return publicInst; + } else { + ReactMount.unmountComponentAtNode(container); + } + } -var ReactComponentTreeHook; + var reactRootElement = getReactRootElementInContainer(container); + var containerHasReactMarkup = reactRootElement && !!internalGetID(reactRootElement); + var containerHasNonRootReactChild = hasNonRootReactChild(container); -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, 'render(...): Replacing React-rendered children with a new root ' + 'component. If you intended to update the children of this node, ' + 'you should instead have the existing children update their state ' + 'and render the new components instead of calling ReactDOM.render.') : void 0; -function instantiateChild(childInstances, child, name, selfDebugID) { - // We found a component instance. - var keyUnique = childInstances[name] === undefined; - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); + if (!containerHasReactMarkup || reactRootElement.nextSibling) { + var rootElementSibling = reactRootElement; + while (rootElementSibling) { + if (internalGetID(rootElementSibling)) { + process.env.NODE_ENV !== 'production' ? warning(false, 'render(): Target node has markup rendered by React, but there ' + 'are unrelated nodes as well. This is most commonly caused by ' + 'white-space inserted around server-rendered markup.') : void 0; + break; + } + rootElementSibling = rootElementSibling.nextSibling; + } + } } - if (!keyUnique) { - process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; + + var shouldReuseMarkup = containerHasReactMarkup && !prevComponent && !containerHasNonRootReactChild; + var component = ReactMount._renderNewRootComponent(nextWrappedElement, container, shouldReuseMarkup, nextContext)._renderedComponent.getPublicInstance(); + if (callback) { + callback.call(component); } - } - if (child != null && keyUnique) { - childInstances[name] = instantiateReactComponent(child, true); - } -} + return component; + }, -/** - * ReactChildReconciler provides helpers for initializing or updating a set of - * children. Its output is suitable for passing it onto ReactMultiChild which - * does diffed reordering and insertion. - */ -var ReactChildReconciler = { /** - * Generates a "mount image" for each of the supplied children. In the case - * of `ReactDOMComponent`, a mount image is a string of markup. + * Renders a React component into the DOM in the supplied `container`. + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.render * - * @param {?object} nestedChildNodes Nested child maps. - * @return {?object} A set of child instances. - * @internal + * If the React component was previously rendered into `container`, this will + * perform an update on it and only mutate the DOM as necessary to reflect the + * latest React component. + * + * @param {ReactElement} nextElement Component element to render. + * @param {DOMElement} container DOM element to render into. + * @param {?function} callback function triggered on completion + * @return {ReactComponent} Component instance rendered in `container`. */ - instantiateChildren: function (nestedChildNodes, transaction, context, selfDebugID) // 0 in production and for roots - { - if (nestedChildNodes == null) { - return null; - } - var childInstances = {}; - - if (process.env.NODE_ENV !== 'production') { - traverseAllChildren(nestedChildNodes, function (childInsts, child, name) { - return instantiateChild(childInsts, child, name, selfDebugID); - }, childInstances); - } else { - traverseAllChildren(nestedChildNodes, instantiateChild, childInstances); - } - return childInstances; + render: function (nextElement, container, callback) { + return ReactMount._renderSubtreeIntoContainer(null, nextElement, container, callback); }, /** - * Updates the rendered children and returns a new set of children. + * Unmounts and destroys the React component rendered in the `container`. + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.unmountcomponentatnode * - * @param {?object} prevChildren Previously initialized set of children. - * @param {?object} nextChildren Flat child element maps. - * @param {ReactReconcileTransaction} transaction - * @param {object} context - * @return {?object} A new set of child instances. - * @internal + * @param {DOMElement} container DOM element containing a React component. + * @return {boolean} True if a component was found in and unmounted from + * `container` */ - updateChildren: function (prevChildren, nextChildren, mountImages, removedNodes, transaction, hostParent, hostContainerInfo, context, selfDebugID) // 0 in production and for roots - { - // We currently don't have a way to track moves here but if we use iterators - // instead of for..in we can zip the iterators and check if an item has - // moved. - // TODO: If nothing has changed, return the prevChildren object so that we - // can quickly bailout if nothing has changed. - if (!nextChildren && !prevChildren) { - return; + unmountComponentAtNode: function (container) { + // Various parts of our code (such as ReactCompositeComponent's + // _renderValidatedComponent) assume that calls to render aren't nested; + // verify that that's the case. (Strictly speaking, unmounting won't cause a + // render but we still don't expect to be in a render call here.) + process.env.NODE_ENV !== 'production' ? warning(ReactCurrentOwner.current == null, 'unmountComponentAtNode(): Render methods should be a pure function ' + 'of props and state; triggering nested component updates from render ' + 'is not allowed. If necessary, trigger nested updates in ' + 'componentDidUpdate. Check the render method of %s.', ReactCurrentOwner.current && ReactCurrentOwner.current.getName() || 'ReactCompositeComponent') : void 0; + + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'unmountComponentAtNode(...): Target container is not a DOM element.') : _prodInvariant('40') : void 0; + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!nodeIsRenderedByOtherInstance(container), "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by another copy of React.') : void 0; } - var name; - var prevChild; - for (name in nextChildren) { - if (!nextChildren.hasOwnProperty(name)) { - continue; + + var prevComponent = getTopLevelWrapperInContainer(container); + if (!prevComponent) { + // Check if the node being unmounted was rendered by React, but isn't a + // root node. + var containerHasNonRootReactChild = hasNonRootReactChild(container); + + // Check if the container itself is a React root node. + var isContainerReactRoot = container.nodeType === 1 && container.hasAttribute(ROOT_ATTR_NAME); + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(!containerHasNonRootReactChild, "unmountComponentAtNode(): The node you're attempting to unmount " + 'was rendered by React and is not a top-level container. %s', isContainerReactRoot ? 'You may have accidentally passed in a React root node instead ' + 'of its container.' : 'Instead, have the parent component update its state and ' + 'rerender in order to remove this component.') : void 0; } - prevChild = prevChildren && prevChildren[name]; - var prevElement = prevChild && prevChild._currentElement; - var nextElement = nextChildren[name]; - if (prevChild != null && shouldUpdateReactComponent(prevElement, nextElement)) { - ReactReconciler.receiveComponent(prevChild, nextElement, transaction, context); - nextChildren[name] = prevChild; + + return false; + } + delete instancesByReactRootID[prevComponent._instance.rootID]; + ReactUpdates.batchedUpdates(unmountComponentFromNode, prevComponent, container, false); + return true; + }, + + _mountImageIntoNode: function (markup, container, instance, shouldReuseMarkup, transaction) { + !isValidContainer(container) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'mountComponentIntoNode(...): Target container is not valid.') : _prodInvariant('41') : void 0; + + if (shouldReuseMarkup) { + var rootElement = getReactRootElementInContainer(container); + if (ReactMarkupChecksum.canReuseMarkup(markup, rootElement)) { + ReactDOMComponentTree.precacheNode(instance, rootElement); + return; } else { - if (prevChild) { - removedNodes[name] = ReactReconciler.getHostNode(prevChild); - ReactReconciler.unmountComponent(prevChild, false); + var checksum = rootElement.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + rootElement.removeAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + + var rootMarkup = rootElement.outerHTML; + rootElement.setAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME, checksum); + + var normalizedMarkup = markup; + if (process.env.NODE_ENV !== 'production') { + // because rootMarkup is retrieved from the DOM, various normalizations + // will have occurred which will not be present in `markup`. Here, + // insert markup into a <div> or <iframe> depending on the container + // type to perform the same normalizations before comparing. + var normalizer; + if (container.nodeType === ELEMENT_NODE_TYPE) { + normalizer = document.createElement('div'); + normalizer.innerHTML = markup; + normalizedMarkup = normalizer.innerHTML; + } else { + normalizer = document.createElement('iframe'); + document.body.appendChild(normalizer); + normalizer.contentDocument.write(markup); + normalizedMarkup = normalizer.contentDocument.documentElement.outerHTML; + document.body.removeChild(normalizer); + } + } + + var diffIndex = firstDifferenceIndex(normalizedMarkup, rootMarkup); + var difference = ' (client) ' + normalizedMarkup.substring(diffIndex - 20, diffIndex + 20) + '\n (server) ' + rootMarkup.substring(diffIndex - 20, diffIndex + 20); + + !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document using server rendering but the checksum was invalid. This usually means you rendered a different component type or props on the client from the one on the server, or your render() methods are impure. React cannot handle this case due to cross-browser quirks by rendering at the document root. You should look for environment dependent code in your components and ensure the props are the same client and server side:\n%s', difference) : _prodInvariant('42', difference) : void 0; + + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(false, 'React attempted to reuse markup in a container but the ' + 'checksum was invalid. This generally means that you are ' + 'using server rendering and the markup generated on the ' + 'server was not what the client was expecting. React injected ' + 'new markup to compensate which works but you have lost many ' + 'of the benefits of server rendering. Instead, figure out ' + 'why the markup being generated is different on the client ' + 'or server:\n%s', difference) : void 0; } - // The child must be instantiated before it's mounted. - var nextChildInstance = instantiateReactComponent(nextElement, true); - nextChildren[name] = nextChildInstance; - // Creating mount image now ensures refs are resolved in right order - // (see https://github.com/facebook/react/pull/7101 for explanation). - var nextChildMountImage = ReactReconciler.mountComponent(nextChildInstance, transaction, hostParent, hostContainerInfo, context, selfDebugID); - mountImages.push(nextChildMountImage); } } - // Unmount children that are no longer present. - for (name in prevChildren) { - if (prevChildren.hasOwnProperty(name) && !(nextChildren && nextChildren.hasOwnProperty(name))) { - prevChild = prevChildren[name]; - removedNodes[name] = ReactReconciler.getHostNode(prevChild); - ReactReconciler.unmountComponent(prevChild, false); + + !(container.nodeType !== DOC_NODE_TYPE) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'You\'re trying to render a component to the document but you didn\'t use server rendering. We can\'t do this without using server rendering due to cross-browser quirks. See ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('43') : void 0; + + if (transaction.useCreateElement) { + while (container.lastChild) { + container.removeChild(container.lastChild); } + DOMLazyTree.insertTreeBefore(container, markup, null); + } else { + setInnerHTML(container, markup); + ReactDOMComponentTree.precacheNode(instance, container.firstChild); } - }, - /** - * Unmounts all rendered children. This should be used to clean up children - * when this component is unmounted. - * - * @param {?object} renderedChildren Previously initialized set of children. - * @internal - */ - unmountChildren: function (renderedChildren, safely) { - for (var name in renderedChildren) { - if (renderedChildren.hasOwnProperty(name)) { - var renderedChild = renderedChildren[name]; - ReactReconciler.unmountComponent(renderedChild, safely); + if (process.env.NODE_ENV !== 'production') { + var hostNode = ReactDOMComponentTree.getInstanceFromNode(container.firstChild); + if (hostNode._debugID !== 0) { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: hostNode._debugID, + type: 'mount', + payload: markup.toString() + }); } } } }; -module.exports = ReactChildReconciler; +module.exports = ReactMount; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 176 */ +/* 150 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** +/** * Copyright 2013-present, Facebook, Inc. * All rights reserved. * @@ -30471,28923 +27076,22290 @@ module.exports = ReactChildReconciler; -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); +var ReactNodeTypes = __webpack_require__(142); -var React = __webpack_require__(24); -var ReactComponentEnvironment = __webpack_require__(59); -var ReactCurrentOwner = __webpack_require__(14); -var ReactErrorUtils = __webpack_require__(51); -var ReactInstanceMap = __webpack_require__(34); -var ReactInstrumentation = __webpack_require__(13); -var ReactNodeTypes = __webpack_require__(97); -var ReactReconciler = __webpack_require__(26); +function getHostComponentFromComposite(inst) { + var type; -if (process.env.NODE_ENV !== 'production') { - var checkReactTypeSpec = __webpack_require__(177); + while ((type = inst._renderedNodeType) === ReactNodeTypes.COMPOSITE) { + inst = inst._renderedComponent; + } + + if (type === ReactNodeTypes.HOST) { + return inst._renderedComponent; + } else if (type === ReactNodeTypes.EMPTY) { + return null; + } } -var emptyObject = __webpack_require__(39); -var invariant = __webpack_require__(1); -var shallowEqual = __webpack_require__(60); -var shouldUpdateReactComponent = __webpack_require__(61); -var warning = __webpack_require__(2); +module.exports = getHostComponentFromComposite; -var CompositeTypes = { - ImpureClass: 0, - PureClass: 1, - StatelessFunctional: 2 -}; +/***/ }), +/* 151 */ +/***/ (function(module, exports, __webpack_require__) { -function StatelessComponent(Component) {} -StatelessComponent.prototype.render = function () { - var Component = ReactInstanceMap.get(this)._currentElement.type; - var element = Component(this.props, this.context, this.updater); - warnIfInvalidElement(Component, element); - return element; -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { -function warnIfInvalidElement(Component, element) { - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(element === null || element === false || React.isValidElement(element), '%s(...): A valid React element (or null) must be returned. You may have ' + 'returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!Component.childContextTypes, '%s(...): childContextTypes cannot be defined on a functional component.', Component.displayName || Component.name || 'Component') : void 0; - } -} +exports.__esModule = true; -function shouldConstruct(Component) { - return !!(Component.prototype && Component.prototype.isReactComponent); -} +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -function isPureComponent(Component) { - return !!(Component.prototype && Component.prototype.isPureReactComponent); -} +var _chainFunction = __webpack_require__(323); -// Separated into a function to contain deoptimizations caused by try/finally. -function measureLifeCyclePerf(fn, debugID, timerType) { - if (debugID === 0) { - // Top-level wrappers (see ReactMount) and empty components (see - // ReactDOMEmptyComponent) are invisible to hooks and devtools. - // Both are implementation details that should go away in the future. - return fn(); - } +var _chainFunction2 = _interopRequireDefault(_chainFunction); - ReactInstrumentation.debugTool.onBeginLifeCycleTimer(debugID, timerType); - try { - return fn(); - } finally { - ReactInstrumentation.debugTool.onEndLifeCycleTimer(debugID, timerType); - } -} +var _react = __webpack_require__(6); -/** - * ------------------ The Life-Cycle of a Composite Component ------------------ - * - * - constructor: Initialization of state. The instance is now retained. - * - componentWillMount - * - render - * - [children's constructors] - * - [children's componentWillMount and render] - * - [children's componentDidMount] - * - componentDidMount - * - * Update Phases: - * - componentWillReceiveProps (only called if parent updated) - * - shouldComponentUpdate - * - componentWillUpdate - * - render - * - [children's constructors or receive props phases] - * - componentDidUpdate - * - * - componentWillUnmount - * - [children's componentWillUnmount] - * - [children destroyed] - * - (destroyed): The instance is now blank, released by React and ready for GC. - * - * ----------------------------------------------------------------------------- - */ +var _react2 = _interopRequireDefault(_react); -/** - * An incrementing ID assigned to each component when it is mounted. This is - * used to enforce the order in which `ReactUpdates` updates dirty components. - * - * @private - */ -var nextMountID = 1; +var _propTypes = __webpack_require__(40); -/** - * @lends {ReactCompositeComponent.prototype} - */ -var ReactCompositeComponent = { - /** - * Base constructor for all composite component. - * - * @param {ReactElement} element - * @final - * @internal - */ - construct: function (element) { - this._currentElement = element; - this._rootNodeID = 0; - this._compositeType = null; - this._instance = null; - this._hostParent = null; - this._hostContainerInfo = null; +var _propTypes2 = _interopRequireDefault(_propTypes); - // See ReactUpdateQueue - this._updateBatchNumber = null; - this._pendingElement = null; - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; +var _warning = __webpack_require__(324); - this._renderedNodeType = null; - this._renderedComponent = null; - this._context = null; - this._mountOrder = 0; - this._topLevelWrapper = null; +var _warning2 = _interopRequireDefault(_warning); - // See ReactUpdates and ReactUpdateQueue. - this._pendingCallbacks = null; +var _ChildMapping = __webpack_require__(325); - // ComponentWillUnmount shall only be called once - this._calledComponentWillUnmount = false; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - if (process.env.NODE_ENV !== 'production') { - this._warnedAboutRefsInRender = false; - } - }, +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - /** - * Initializes the component, renders markup, and registers event listeners. - * - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @param {?object} hostParent - * @param {?object} hostContainerInfo - * @param {?object} context - * @return {?string} Rendered markup to be inserted into the DOM. - * @final - * @internal - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - var _this = this; +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - this._context = context; - this._mountOrder = nextMountID++; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - var publicProps = this._currentElement.props; - var publicContext = this._processContext(context); +var propTypes = { + component: _propTypes2.default.any, + childFactory: _propTypes2.default.func, + children: _propTypes2.default.node +}; - var Component = this._currentElement.type; +var defaultProps = { + component: 'span', + childFactory: function childFactory(child) { + return child; + } +}; - var updateQueue = transaction.getUpdateQueue(); +var TransitionGroup = function (_React$Component) { + _inherits(TransitionGroup, _React$Component); - // Initialize the public class - var doConstruct = shouldConstruct(Component); - var inst = this._constructComponent(doConstruct, publicProps, publicContext, updateQueue); - var renderedElement; + function TransitionGroup(props, context) { + _classCallCheck(this, TransitionGroup); - // Support functional components - if (!doConstruct && (inst == null || inst.render == null)) { - renderedElement = inst; - warnIfInvalidElement(Component, renderedElement); - !(inst === null || inst === false || React.isValidElement(inst)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : _prodInvariant('105', Component.displayName || Component.name || 'Component') : void 0; - inst = new StatelessComponent(Component); - this._compositeType = CompositeTypes.StatelessFunctional; - } else { - if (isPureComponent(Component)) { - this._compositeType = CompositeTypes.PureClass; + var _this = _possibleConstructorReturn(this, _React$Component.call(this, props, context)); + + _this.performAppear = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; + + if (component.componentWillAppear) { + component.componentWillAppear(_this._handleDoneAppearing.bind(_this, key, component)); } else { - this._compositeType = CompositeTypes.ImpureClass; + _this._handleDoneAppearing(key, component); } - } + }; - if (process.env.NODE_ENV !== 'production') { - // This will throw later in _renderValidatedComponent, but add an early - // warning now to help debugging - if (inst.render == null) { - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): No `render` method found on the returned component ' + 'instance: you may have forgotten to define `render`.', Component.displayName || Component.name || 'Component') : void 0; + _this._handleDoneAppearing = function (key, component) { + if (component.componentDidAppear) { + component.componentDidAppear(); } - var propsMutated = inst.props !== publicProps; - var componentName = Component.displayName || Component.name || 'Component'; + delete _this.currentlyTransitioningKeys[key]; - process.env.NODE_ENV !== 'production' ? warning(inst.props === undefined || !propsMutated, '%s(...): When calling super() in `%s`, make sure to pass ' + "up the same props that your component's constructor was passed.", componentName, componentName) : void 0; - } + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); - // These should be set up in the constructor, but as a convenience for - // simpler class abstractions, we set them up after the fact. - inst.props = publicProps; - inst.context = publicContext; - inst.refs = emptyObject; - inst.updater = updateQueue; + if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { + // This was removed before it had fully appeared. Remove it. + _this.performLeave(key, component); + } + }; - this._instance = inst; + _this.performEnter = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; - // Store a reference from the instance back to the internal representation - ReactInstanceMap.set(inst, this); + if (component.componentWillEnter) { + component.componentWillEnter(_this._handleDoneEntering.bind(_this, key, component)); + } else { + _this._handleDoneEntering(key, component); + } + }; - if (process.env.NODE_ENV !== 'production') { - // Since plain JS classes are defined without any special initialization - // logic, we can not catch common errors early. Therefore, we have to - // catch them here, at initialization time, instead. - process.env.NODE_ENV !== 'production' ? warning(!inst.getInitialState || inst.getInitialState.isReactClassApproved || inst.state, 'getInitialState was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Did you mean to define a state property instead?', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.getDefaultProps || inst.getDefaultProps.isReactClassApproved, 'getDefaultProps was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Use a static property to define defaultProps instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.propTypes, 'propTypes was defined as an instance property on %s. Use a static ' + 'property to define propTypes instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(!inst.contextTypes, 'contextTypes was defined as an instance property on %s. Use a ' + 'static property to define contextTypes instead.', this.getName() || 'a component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentShouldUpdate !== 'function', '%s has a method called ' + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + 'The name is phrased as a question because the function is ' + 'expected to return a value.', this.getName() || 'A component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentDidUnmount !== 'function', '%s has a method called ' + 'componentDidUnmount(). But there is no such lifecycle method. ' + 'Did you mean componentWillUnmount()?', this.getName() || 'A component') : void 0; - process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentWillRecieveProps !== 'function', '%s has a method called ' + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', this.getName() || 'A component') : void 0; - } + _this._handleDoneEntering = function (key, component) { + if (component.componentDidEnter) { + component.componentDidEnter(); + } - var initialState = inst.state; - if (initialState === undefined) { - inst.state = initialState = null; - } - !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.state: must be set to an object or null', this.getName() || 'ReactCompositeComponent') : _prodInvariant('106', this.getName() || 'ReactCompositeComponent') : void 0; + delete _this.currentlyTransitioningKeys[key]; - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); - var markup; - if (inst.unstable_handleError) { - markup = this.performInitialMountWithErrorHandling(renderedElement, hostParent, hostContainerInfo, transaction, context); - } else { - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } + if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) { + // This was removed before it had fully entered. Remove it. + _this.performLeave(key, component); + } + }; - if (inst.componentDidMount) { - if (process.env.NODE_ENV !== 'production') { - transaction.getReactMountReady().enqueue(function () { - measureLifeCyclePerf(function () { - return inst.componentDidMount(); - }, _this._debugID, 'componentDidMount'); - }); + _this.performLeave = function (key, component) { + _this.currentlyTransitioningKeys[key] = true; + + if (component.componentWillLeave) { + component.componentWillLeave(_this._handleDoneLeaving.bind(_this, key, component)); } else { - transaction.getReactMountReady().enqueue(inst.componentDidMount, inst); + // Note that this is somewhat dangerous b/c it calls setState() + // again, effectively mutating the component before all the work + // is done. + _this._handleDoneLeaving(key, component); } - } - - return markup; - }, + }; - _constructComponent: function (doConstruct, publicProps, publicContext, updateQueue) { - if (process.env.NODE_ENV !== 'production') { - ReactCurrentOwner.current = this; - try { - return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); - } finally { - ReactCurrentOwner.current = null; + _this._handleDoneLeaving = function (key, component) { + if (component.componentDidLeave) { + component.componentDidLeave(); } - } else { - return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); - } - }, - _constructComponentWithoutOwner: function (doConstruct, publicProps, publicContext, updateQueue) { - var Component = this._currentElement.type; + delete _this.currentlyTransitioningKeys[key]; - if (doConstruct) { - if (process.env.NODE_ENV !== 'production') { - return measureLifeCyclePerf(function () { - return new Component(publicProps, publicContext, updateQueue); - }, this._debugID, 'ctor'); - } else { - return new Component(publicProps, publicContext, updateQueue); - } - } + var currentChildMapping = (0, _ChildMapping.getChildMapping)(_this.props.children); - // This can still be an instance in case of factory components - // but we'll count this as time spent rendering as the more common case. - if (process.env.NODE_ENV !== 'production') { - return measureLifeCyclePerf(function () { - return Component(publicProps, publicContext, updateQueue); - }, this._debugID, 'render'); - } else { - return Component(publicProps, publicContext, updateQueue); - } - }, - - performInitialMountWithErrorHandling: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { - var markup; - var checkpoint = transaction.checkpoint(); - try { - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } catch (e) { - // Roll back to checkpoint, handle error (which may add items to the transaction), and take a new checkpoint - transaction.rollback(checkpoint); - this._instance.unstable_handleError(e); - if (this._pendingStateQueue) { - this._instance.state = this._processPendingState(this._instance.props, this._instance.context); + if (currentChildMapping && currentChildMapping.hasOwnProperty(key)) { + // This entered again before it fully left. Add it again. + _this.keysToEnter.push(key); + } else { + _this.setState(function (state) { + var newChildren = _extends({}, state.children); + delete newChildren[key]; + return { children: newChildren }; + }); } - checkpoint = transaction.checkpoint(); + }; - this._renderedComponent.unmountComponent(true); - transaction.rollback(checkpoint); + _this.childRefs = Object.create(null); - // Try again - we've informed the component about the error, so they can render an error message this time. - // If this throws again, the error will bubble up (and can be caught by a higher error boundary). - markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); - } - return markup; - }, + _this.state = { + children: (0, _ChildMapping.getChildMapping)(props.children) + }; + return _this; + } - performInitialMount: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { - var inst = this._instance; + TransitionGroup.prototype.componentWillMount = function componentWillMount() { + this.currentlyTransitioningKeys = {}; + this.keysToEnter = []; + this.keysToLeave = []; + }; - var debugID = 0; - if (process.env.NODE_ENV !== 'production') { - debugID = this._debugID; + TransitionGroup.prototype.componentDidMount = function componentDidMount() { + var initialChildMapping = this.state.children; + for (var key in initialChildMapping) { + if (initialChildMapping[key]) { + this.performAppear(key, this.childRefs[key]); + } } + }; - if (inst.componentWillMount) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillMount(); - }, debugID, 'componentWillMount'); - } else { - inst.componentWillMount(); - } - // When mounting, calls to `setState` by `componentWillMount` will set - // `this._pendingStateQueue` without triggering a re-render. - if (this._pendingStateQueue) { - inst.state = this._processPendingState(inst.props, inst.context); + TransitionGroup.prototype.componentWillReceiveProps = function componentWillReceiveProps(nextProps) { + var nextChildMapping = (0, _ChildMapping.getChildMapping)(nextProps.children); + var prevChildMapping = this.state.children; + + this.setState({ + children: (0, _ChildMapping.mergeChildMappings)(prevChildMapping, nextChildMapping) + }); + + for (var key in nextChildMapping) { + var hasPrev = prevChildMapping && prevChildMapping.hasOwnProperty(key); + if (nextChildMapping[key] && !hasPrev && !this.currentlyTransitioningKeys[key]) { + this.keysToEnter.push(key); } } - // If not a stateless component, we now render - if (renderedElement === undefined) { - renderedElement = this._renderValidatedComponent(); + for (var _key in prevChildMapping) { + var hasNext = nextChildMapping && nextChildMapping.hasOwnProperty(_key); + if (prevChildMapping[_key] && !hasNext && !this.currentlyTransitioningKeys[_key]) { + this.keysToLeave.push(_key); + } } - var nodeType = ReactNodeTypes.getType(renderedElement); - this._renderedNodeType = nodeType; - var child = this._instantiateReactComponent(renderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ - ); - this._renderedComponent = child; + // If we want to someday check for reordering, we could do it here. + }; - var markup = ReactReconciler.mountComponent(child, transaction, hostParent, hostContainerInfo, this._processChildContext(context), debugID); + TransitionGroup.prototype.componentDidUpdate = function componentDidUpdate() { + var _this2 = this; - if (process.env.NODE_ENV !== 'production') { - if (debugID !== 0) { - var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; - ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); - } - } + var keysToEnter = this.keysToEnter; + this.keysToEnter = []; + keysToEnter.forEach(function (key) { + return _this2.performEnter(key, _this2.childRefs[key]); + }); - return markup; - }, + var keysToLeave = this.keysToLeave; + this.keysToLeave = []; + keysToLeave.forEach(function (key) { + return _this2.performLeave(key, _this2.childRefs[key]); + }); + }; - getHostNode: function () { - return ReactReconciler.getHostNode(this._renderedComponent); - }, + TransitionGroup.prototype.render = function render() { + var _this3 = this; - /** - * Releases any resources allocated by `mountComponent`. - * - * @final - * @internal - */ - unmountComponent: function (safely) { - if (!this._renderedComponent) { - return; - } + // TODO: we could get rid of the need for the wrapper node + // by cloning a single child + var childrenToRender = []; - var inst = this._instance; + var _loop = function _loop(key) { + var child = _this3.state.children[key]; + if (child) { + var isCallbackRef = typeof child.ref !== 'string'; + var factoryChild = _this3.props.childFactory(child); + var ref = function ref(r) { + _this3.childRefs[key] = r; + }; - if (inst.componentWillUnmount && !inst._calledComponentWillUnmount) { - inst._calledComponentWillUnmount = true; + process.env.NODE_ENV !== 'production' ? (0, _warning2.default)(isCallbackRef, 'string refs are not supported on children of TransitionGroup and will be ignored. ' + 'Please use a callback ref instead: https://facebook.github.io/react/docs/refs-and-the-dom.html#the-ref-callback-attribute') : void 0; - if (safely) { - var name = this.getName() + '.componentWillUnmount()'; - ReactErrorUtils.invokeGuardedCallback(name, inst.componentWillUnmount.bind(inst)); - } else { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillUnmount(); - }, this._debugID, 'componentWillUnmount'); - } else { - inst.componentWillUnmount(); + // Always chaining the refs leads to problems when the childFactory + // wraps the child. The child ref callback gets called twice with the + // wrapper and the child. So we only need to chain the ref if the + // factoryChild is not different from child. + if (factoryChild === child && isCallbackRef) { + ref = (0, _chainFunction2.default)(child.ref, ref); } + + // You may need to apply reactive updates to a child as it is leaving. + // The normal React way to do it won't work since the child will have + // already been removed. In case you need this behavior you can provide + // a childFactory function to wrap every child, even the ones that are + // leaving. + childrenToRender.push(_react2.default.cloneElement(factoryChild, { + key: key, + ref: ref + })); } - } + }; - if (this._renderedComponent) { - ReactReconciler.unmountComponent(this._renderedComponent, safely); - this._renderedNodeType = null; - this._renderedComponent = null; - this._instance = null; + for (var key in this.state.children) { + _loop(key); } - // Reset pending fields - // Even if this component is scheduled for another update in ReactUpdates, - // it would still be ignored because these fields are reset. - this._pendingStateQueue = null; - this._pendingReplaceState = false; - this._pendingForceUpdate = false; - this._pendingCallbacks = null; - this._pendingElement = null; + // Do not forward TransitionGroup props to primitive DOM nodes + var props = _extends({}, this.props); + delete props.transitionLeave; + delete props.transitionName; + delete props.transitionAppear; + delete props.transitionEnter; + delete props.childFactory; + delete props.transitionLeaveTimeout; + delete props.transitionEnterTimeout; + delete props.transitionAppearTimeout; + delete props.component; - // These fields do not really need to be reset since this object is no - // longer accessible. - this._context = null; - this._rootNodeID = 0; - this._topLevelWrapper = null; + return _react2.default.createElement(this.props.component, props, childrenToRender); + }; - // Delete the reference from the instance to this internal representation - // which allow the internals to be properly cleaned up even if the user - // leaks a reference to the public instance. - ReactInstanceMap.remove(inst); + return TransitionGroup; +}(_react2.default.Component); - // Some existing components rely on inst.props even after they've been - // destroyed (in event handlers). - // TODO: inst.props = null; - // TODO: inst.state = null; - // TODO: inst.context = null; - }, +TransitionGroup.displayName = 'TransitionGroup'; - /** - * Filters the context object to only contain keys specified in - * `contextTypes` - * - * @param {object} context - * @return {?object} - * @private - */ - _maskContext: function (context) { - var Component = this._currentElement.type; - var contextTypes = Component.contextTypes; - if (!contextTypes) { - return emptyObject; - } - var maskedContext = {}; - for (var contextName in contextTypes) { - maskedContext[contextName] = context[contextName]; - } - return maskedContext; - }, - /** - * Filters the context object to only contain keys specified in - * `contextTypes`, and asserts that they are valid. - * - * @param {object} context - * @return {?object} - * @private - */ - _processContext: function (context) { - var maskedContext = this._maskContext(context); - if (process.env.NODE_ENV !== 'production') { - var Component = this._currentElement.type; - if (Component.contextTypes) { - this._checkContextTypes(Component.contextTypes, maskedContext, 'context'); - } - } - return maskedContext; - }, +TransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; +TransitionGroup.defaultProps = defaultProps; - /** - * @param {object} currentContext - * @return {object} - * @private - */ - _processChildContext: function (currentContext) { - var Component = this._currentElement.type; - var inst = this._instance; - var childContext; +exports.default = TransitionGroup; +module.exports = exports['default']; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - if (inst.getChildContext) { - if (process.env.NODE_ENV !== 'production') { - ReactInstrumentation.debugTool.onBeginProcessingChildContext(); - try { - childContext = inst.getChildContext(); - } finally { - ReactInstrumentation.debugTool.onEndProcessingChildContext(); - } - } else { - childContext = inst.getChildContext(); - } - } +/***/ }), +/* 152 */ +/***/ (function(module, exports, __webpack_require__) { - if (childContext) { - !(typeof Component.childContextTypes === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().', this.getName() || 'ReactCompositeComponent') : _prodInvariant('107', this.getName() || 'ReactCompositeComponent') : void 0; - if (process.env.NODE_ENV !== 'production') { - this._checkContextTypes(Component.childContextTypes, childContext, 'child context'); - } - for (var name in childContext) { - !(name in Component.childContextTypes) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): key "%s" is not defined in childContextTypes.', this.getName() || 'ReactCompositeComponent', name) : _prodInvariant('108', this.getName() || 'ReactCompositeComponent', name) : void 0; - } - return _assign({}, currentContext, childContext); - } - return currentContext; - }, +"use strict"; - /** - * Assert that the context types are valid - * - * @param {object} typeSpecs Map of context field to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @private - */ - _checkContextTypes: function (typeSpecs, values, location) { - if (process.env.NODE_ENV !== 'production') { - checkReactTypeSpec(typeSpecs, values, location, this.getName(), null, this._debugID); - } - }, - receiveComponent: function (nextElement, transaction, nextContext) { - var prevElement = this._currentElement; - var prevContext = this._context; +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = !!(typeof window !== 'undefined' && window.document && window.document.createElement); +module.exports = exports['default']; - this._pendingElement = null; +/***/ }), +/* 153 */ +/***/ (function(module, exports, __webpack_require__) { - this.updateComponent(transaction, prevElement, nextElement, prevContext, nextContext); - }, +"use strict"; - /** - * If any of `_pendingElement`, `_pendingStateQueue`, or `_pendingForceUpdate` - * is set, update the component. - * - * @param {ReactReconcileTransaction} transaction - * @internal - */ - performUpdateIfNecessary: function (transaction) { - if (this._pendingElement != null) { - ReactReconciler.receiveComponent(this, this._pendingElement, transaction, this._context); - } else if (this._pendingStateQueue !== null || this._pendingForceUpdate) { - this.updateComponent(transaction, this._currentElement, this._currentElement, this._context, this._context); - } else { - this._updateBatchNumber = null; - } - }, - /** - * Perform an update to a mounted component. The componentWillReceiveProps and - * shouldComponentUpdate methods are called, then (assuming the update isn't - * skipped) the remaining update lifecycle methods are called and the DOM - * representation is updated. - * - * By default, this implements React's rendering and reconciliation algorithm. - * Sophisticated clients may wish to override this. - * - * @param {ReactReconcileTransaction} transaction - * @param {ReactElement} prevParentElement - * @param {ReactElement} nextParentElement - * @internal - * @overridable - */ - updateComponent: function (transaction, prevParentElement, nextParentElement, prevUnmaskedContext, nextUnmaskedContext) { - var inst = this._instance; - !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Attempted to update component `%s` that has already been unmounted (or failed to mount).', this.getName() || 'ReactCompositeComponent') : _prodInvariant('136', this.getName() || 'ReactCompositeComponent') : void 0; +exports.__esModule = true; +exports.nameShape = undefined; +exports.transitionTimeout = transitionTimeout; - var willReceive = false; - var nextContext; +var _react = __webpack_require__(6); - // Determine if the context has changed or not - if (this._context === nextUnmaskedContext) { - nextContext = inst.context; - } else { - nextContext = this._processContext(nextUnmaskedContext); - willReceive = true; - } +var _react2 = _interopRequireDefault(_react); - var prevProps = prevParentElement.props; - var nextProps = nextParentElement.props; +var _propTypes = __webpack_require__(40); - // Not a simple state update but a props update - if (prevParentElement !== nextParentElement) { - willReceive = true; - } +var _propTypes2 = _interopRequireDefault(_propTypes); - // An update here will schedule an update but immediately set - // _pendingStateQueue which will ensure that any state updates gets - // immediately reconciled instead of waiting for the next batch. - if (willReceive && inst.componentWillReceiveProps) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillReceiveProps(nextProps, nextContext); - }, this._debugID, 'componentWillReceiveProps'); - } else { - inst.componentWillReceiveProps(nextProps, nextContext); - } - } +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - var nextState = this._processPendingState(nextProps, nextContext); - var shouldUpdate = true; +function transitionTimeout(transitionType) { + var timeoutPropName = 'transition' + transitionType + 'Timeout'; + var enabledPropName = 'transition' + transitionType; - if (!this._pendingForceUpdate) { - if (inst.shouldComponentUpdate) { - if (process.env.NODE_ENV !== 'production') { - shouldUpdate = measureLifeCyclePerf(function () { - return inst.shouldComponentUpdate(nextProps, nextState, nextContext); - }, this._debugID, 'shouldComponentUpdate'); - } else { - shouldUpdate = inst.shouldComponentUpdate(nextProps, nextState, nextContext); - } - } else { - if (this._compositeType === CompositeTypes.PureClass) { - shouldUpdate = !shallowEqual(prevProps, nextProps) || !shallowEqual(inst.state, nextState); - } + return function (props) { + // If the transition is enabled + if (props[enabledPropName]) { + // If no timeout duration is provided + if (props[timeoutPropName] == null) { + return new Error(timeoutPropName + ' wasn\'t supplied to CSSTransitionGroup: ' + 'this can cause unreliable animations and won\'t be supported in ' + 'a future version of React. See ' + 'https://fb.me/react-animation-transition-group-timeout for more ' + 'information.'); + + // If the duration isn't a number + } else if (typeof props[timeoutPropName] !== 'number') { + return new Error(timeoutPropName + ' must be a number (in milliseconds)'); } } - if (process.env.NODE_ENV !== 'production') { - process.env.NODE_ENV !== 'production' ? warning(shouldUpdate !== undefined, '%s.shouldComponentUpdate(): Returned undefined instead of a ' + 'boolean value. Make sure to return true or false.', this.getName() || 'ReactCompositeComponent') : void 0; - } + return null; + }; +} - this._updateBatchNumber = null; - if (shouldUpdate) { - this._pendingForceUpdate = false; - // Will set `this.props`, `this.state` and `this.context`. - this._performComponentUpdate(nextParentElement, nextProps, nextState, nextContext, transaction, nextUnmaskedContext); - } else { - // If it's determined that a component should not update, we still want - // to set props and state but we shortcut the rest of the update. - this._currentElement = nextParentElement; - this._context = nextUnmaskedContext; - inst.props = nextProps; - inst.state = nextState; - inst.context = nextContext; - } - }, +var nameShape = exports.nameShape = _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.shape({ + enter: _propTypes2.default.string, + leave: _propTypes2.default.string, + active: _propTypes2.default.string +}), _propTypes2.default.shape({ + enter: _propTypes2.default.string, + enterActive: _propTypes2.default.string, + leave: _propTypes2.default.string, + leaveActive: _propTypes2.default.string, + appear: _propTypes2.default.string, + appearActive: _propTypes2.default.string +})]); - _processPendingState: function (props, context) { - var inst = this._instance; - var queue = this._pendingStateQueue; - var replace = this._pendingReplaceState; - this._pendingReplaceState = false; - this._pendingStateQueue = null; +/***/ }), +/* 154 */ +/***/ (function(module, exports) { - if (!queue) { - return inst.state; - } +var toString = {}.toString; - if (replace && queue.length === 1) { - return queue[0]; - } +module.exports = Array.isArray || function (arr) { + return toString.call(arr) == '[object Array]'; +}; - var nextState = _assign({}, replace ? queue[0] : inst.state); - for (var i = replace ? 1 : 0; i < queue.length; i++) { - var partial = queue[i]; - _assign(nextState, typeof partial === 'function' ? partial.call(inst, nextState, props, context) : partial); - } - return nextState; - }, +/***/ }), +/* 155 */ +/***/ (function(module, exports, __webpack_require__) { - /** - * Merges new props and state, notifies delegate methods of update and - * performs update. - * - * @param {ReactElement} nextElement Next element - * @param {object} nextProps Next public object to set as properties. - * @param {?object} nextState Next object to set as state. - * @param {?object} nextContext Next public object to set as context. - * @param {ReactReconcileTransaction} transaction - * @param {?object} unmaskedContext - * @private - */ - _performComponentUpdate: function (nextElement, nextProps, nextState, nextContext, transaction, unmaskedContext) { - var _this2 = this; +"use strict"; - var inst = this._instance; - var hasComponentDidUpdate = Boolean(inst.componentDidUpdate); - var prevProps; - var prevState; - var prevContext; - if (hasComponentDidUpdate) { - prevProps = inst.props; - prevState = inst.state; - prevContext = inst.context; +module.exports = function bind(fn, thisArg) { + return function wrap() { + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; } + return fn.apply(thisArg, args); + }; +}; - if (inst.componentWillUpdate) { - if (process.env.NODE_ENV !== 'production') { - measureLifeCyclePerf(function () { - return inst.componentWillUpdate(nextProps, nextState, nextContext); - }, this._debugID, 'componentWillUpdate'); - } else { - inst.componentWillUpdate(nextProps, nextState, nextContext); - } - } - this._currentElement = nextElement; - this._context = unmaskedContext; - inst.props = nextProps; - inst.state = nextState; - inst.context = nextContext; +/***/ }), +/* 156 */ +/***/ (function(module, exports, __webpack_require__) { - this._updateRenderedComponent(transaction, unmaskedContext); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { - if (hasComponentDidUpdate) { - if (process.env.NODE_ENV !== 'production') { - transaction.getReactMountReady().enqueue(function () { - measureLifeCyclePerf(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), _this2._debugID, 'componentDidUpdate'); - }); - } else { - transaction.getReactMountReady().enqueue(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), inst); - } +var utils = __webpack_require__(20); +var settle = __webpack_require__(340); +var buildURL = __webpack_require__(342); +var parseHeaders = __webpack_require__(343); +var isURLSameOrigin = __webpack_require__(344); +var createError = __webpack_require__(157); +var btoa = (typeof window !== 'undefined' && window.btoa && window.btoa.bind(window)) || __webpack_require__(345); + +module.exports = function xhrAdapter(config) { + return new Promise(function dispatchXhrRequest(resolve, reject) { + var requestData = config.data; + var requestHeaders = config.headers; + + if (utils.isFormData(requestData)) { + delete requestHeaders['Content-Type']; // Let the browser set it } - }, - /** - * Call the component's `render` method and update the DOM accordingly. - * - * @param {ReactReconcileTransaction} transaction - * @internal - */ - _updateRenderedComponent: function (transaction, context) { - var prevComponentInstance = this._renderedComponent; - var prevRenderedElement = prevComponentInstance._currentElement; - var nextRenderedElement = this._renderValidatedComponent(); + var request = new XMLHttpRequest(); + var loadEvent = 'onreadystatechange'; + var xDomain = false; - var debugID = 0; - if (process.env.NODE_ENV !== 'production') { - debugID = this._debugID; + // For IE 8/9 CORS support + // Only supports POST and GET calls and doesn't returns the response headers. + // DON'T do this for testing b/c XMLHttpRequest is mocked, not XDomainRequest. + if (process.env.NODE_ENV !== 'test' && + typeof window !== 'undefined' && + window.XDomainRequest && !('withCredentials' in request) && + !isURLSameOrigin(config.url)) { + request = new window.XDomainRequest(); + loadEvent = 'onload'; + xDomain = true; + request.onprogress = function handleProgress() {}; + request.ontimeout = function handleTimeout() {}; } - if (shouldUpdateReactComponent(prevRenderedElement, nextRenderedElement)) { - ReactReconciler.receiveComponent(prevComponentInstance, nextRenderedElement, transaction, this._processChildContext(context)); - } else { - var oldHostNode = ReactReconciler.getHostNode(prevComponentInstance); - ReactReconciler.unmountComponent(prevComponentInstance, false); + // HTTP basic authentication + if (config.auth) { + var username = config.auth.username || ''; + var password = config.auth.password || ''; + requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password); + } - var nodeType = ReactNodeTypes.getType(nextRenderedElement); - this._renderedNodeType = nodeType; - var child = this._instantiateReactComponent(nextRenderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ - ); - this._renderedComponent = child; + request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true); - var nextMarkup = ReactReconciler.mountComponent(child, transaction, this._hostParent, this._hostContainerInfo, this._processChildContext(context), debugID); + // Set the request timeout in MS + request.timeout = config.timeout; - if (process.env.NODE_ENV !== 'production') { - if (debugID !== 0) { - var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; - ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); - } + // Listen for ready state + request[loadEvent] = function handleLoad() { + if (!request || (request.readyState !== 4 && !xDomain)) { + return; } - this._replaceNodeWithMarkup(oldHostNode, nextMarkup, prevComponentInstance); - } - }, + // The request errored out and we didn't get a response, this will be + // handled by onerror instead + // With one exception: request that using file: protocol, most browsers + // will return status as 0 even though it's a successful request + if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) { + return; + } - /** - * Overridden in shallow rendering. - * - * @protected - */ - _replaceNodeWithMarkup: function (oldHostNode, nextMarkup, prevInstance) { - ReactComponentEnvironment.replaceNodeWithMarkup(oldHostNode, nextMarkup, prevInstance); - }, + // Prepare the response + var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null; + var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response; + var response = { + data: responseData, + // IE sends 1223 instead of 204 (https://github.com/mzabriskie/axios/issues/201) + status: request.status === 1223 ? 204 : request.status, + statusText: request.status === 1223 ? 'No Content' : request.statusText, + headers: responseHeaders, + config: config, + request: request + }; - /** - * @protected - */ - _renderValidatedComponentWithoutOwnerOrContext: function () { - var inst = this._instance; - var renderedElement; + settle(resolve, reject, response); - if (process.env.NODE_ENV !== 'production') { - renderedElement = measureLifeCyclePerf(function () { - return inst.render(); - }, this._debugID, 'render'); - } else { - renderedElement = inst.render(); - } + // Clean up request + request = null; + }; - if (process.env.NODE_ENV !== 'production') { - // We allow auto-mocks to proceed as if they're returning null. - if (renderedElement === undefined && inst.render._isMockFunction) { - // This is probably bad practice. Consider warning here and - // deprecating this convenience. - renderedElement = null; + // Handle low level network errors + request.onerror = function handleError() { + // Real errors are hidden from us by the browser + // onerror should only fire if it's a network error + reject(createError('Network Error', config, null, request)); + + // Clean up request + request = null; + }; + + // Handle timeout + request.ontimeout = function handleTimeout() { + reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED', + request)); + + // Clean up request + request = null; + }; + + // Add xsrf header + // This is only done if running in a standard browser environment. + // Specifically not if we're in a web worker, or react-native. + if (utils.isStandardBrowserEnv()) { + var cookies = __webpack_require__(346); + + // Add xsrf header + var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ? + cookies.read(config.xsrfCookieName) : + undefined; + + if (xsrfValue) { + requestHeaders[config.xsrfHeaderName] = xsrfValue; } } - return renderedElement; - }, + // Add headers to the request + if ('setRequestHeader' in request) { + utils.forEach(requestHeaders, function setRequestHeader(val, key) { + if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') { + // Remove Content-Type if data is undefined + delete requestHeaders[key]; + } else { + // Otherwise add header to the request + request.setRequestHeader(key, val); + } + }); + } - /** - * @private - */ - _renderValidatedComponent: function () { - var renderedElement; - if (process.env.NODE_ENV !== 'production' || this._compositeType !== CompositeTypes.StatelessFunctional) { - ReactCurrentOwner.current = this; + // Add withCredentials to request if needed + if (config.withCredentials) { + request.withCredentials = true; + } + + // Add responseType to request if needed + if (config.responseType) { try { - renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); - } finally { - ReactCurrentOwner.current = null; + request.responseType = config.responseType; + } catch (e) { + // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2. + // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function. + if (config.responseType !== 'json') { + throw e; + } } - } else { - renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); } - !( - // TODO: An `isValidNode` function would probably be more appropriate - renderedElement === null || renderedElement === false || React.isValidElement(renderedElement)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.render(): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', this.getName() || 'ReactCompositeComponent') : _prodInvariant('109', this.getName() || 'ReactCompositeComponent') : void 0; - return renderedElement; - }, + // Handle progress if needed + if (typeof config.onDownloadProgress === 'function') { + request.addEventListener('progress', config.onDownloadProgress); + } - /** - * Lazily allocates the refs object and stores `component` as `ref`. - * - * @param {string} ref Reference name. - * @param {component} component Component to store as `ref`. - * @final - * @private - */ - attachRef: function (ref, component) { - var inst = this.getPublicInstance(); - !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Stateless function components cannot have refs.') : _prodInvariant('110') : void 0; - var publicComponentInstance = component.getPublicInstance(); - if (process.env.NODE_ENV !== 'production') { - var componentName = component && component.getName ? component.getName() : 'a component'; - process.env.NODE_ENV !== 'production' ? warning(publicComponentInstance != null || component._compositeType !== CompositeTypes.StatelessFunctional, 'Stateless function components cannot be given refs ' + '(See ref "%s" in %s created by %s). ' + 'Attempts to access this ref will fail.', ref, componentName, this.getName()) : void 0; + // Not all browsers support upload events + if (typeof config.onUploadProgress === 'function' && request.upload) { + request.upload.addEventListener('progress', config.onUploadProgress); } - var refs = inst.refs === emptyObject ? inst.refs = {} : inst.refs; - refs[ref] = publicComponentInstance; - }, - /** - * Detaches a reference name. - * - * @param {string} ref Name to dereference. - * @final - * @private - */ - detachRef: function (ref) { - var refs = this.getPublicInstance().refs; - delete refs[ref]; - }, + if (config.cancelToken) { + // Handle cancellation + config.cancelToken.promise.then(function onCanceled(cancel) { + if (!request) { + return; + } - /** - * Get a text description of the component that can be used to identify it - * in error messages. - * @return {string} The name or null. - * @internal - */ - getName: function () { - var type = this._currentElement.type; - var constructor = this._instance && this._instance.constructor; - return type.displayName || constructor && constructor.displayName || type.name || constructor && constructor.name || null; - }, + request.abort(); + reject(cancel); + // Clean up request + request = null; + }); + } - /** - * Get the publicly accessible representation of this component - i.e. what - * is exposed by refs and returned by render. Can be null for stateless - * components. - * - * @return {ReactComponent} the public component instance. - * @internal - */ - getPublicInstance: function () { - var inst = this._instance; - if (this._compositeType === CompositeTypes.StatelessFunctional) { - return null; + if (requestData === undefined) { + requestData = null; } - return inst; - }, - // Stub - _instantiateReactComponent: null + // Send the request + request.send(requestData); + }); }; -module.exports = ReactCompositeComponent; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 177 */ +/* 157 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - -var _prodInvariant = __webpack_require__(3); - -var ReactPropTypeLocationNames = __webpack_require__(178); -var ReactPropTypesSecret = __webpack_require__(94); - -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); - -var ReactComponentTreeHook; - -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} -var loggedTypeFailures = {}; +var enhanceError = __webpack_require__(341); /** - * Assert that the values match with the type specs. - * Error messages are memorized and will only be shown once. + * Create an Error with the specified message, config, error code, request and response. * - * @param {object} typeSpecs Map of name to a ReactPropType - * @param {object} values Runtime values that need to be type-checked - * @param {string} location e.g. "prop", "context", "child context" - * @param {string} componentName Name of the component for error messages. - * @param {?object} element The React element that is being type-checked - * @param {?number} debugID The React component instance that is being type-checked - * @private + * @param {string} message The error message. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The created error. */ -function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { - for (var typeSpecName in typeSpecs) { - if (typeSpecs.hasOwnProperty(typeSpecName)) { - var error; - // Prop type validation may throw. In case they do, we don't want to - // fail the render phase where it didn't fail before. So we log it. - // After these have been cleaned up, we'll let them throw. - try { - // This is intentionally an invariant that gets caught. It's the same - // behavior as without this statement except with a better message. - !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; - error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); - } catch (ex) { - error = ex; - } - process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; - if (error instanceof Error && !(error.message in loggedTypeFailures)) { - // Only monitor this failure once because there tends to be a lot of the - // same error. - loggedTypeFailures[error.message] = true; - - var componentStackInfo = ''; - - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (debugID !== null) { - componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); - } else if (element !== null) { - componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); - } - } - - process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; - } - } - } -} +module.exports = function createError(message, config, code, request, response) { + var error = new Error(message); + return enhanceError(error, config, code, request, response); +}; -module.exports = checkReactTypeSpec; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 178 */ +/* 158 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ - -var ReactPropTypeLocationNames = {}; - -if (process.env.NODE_ENV !== 'production') { - ReactPropTypeLocationNames = { - prop: 'prop', - context: 'context', - childContext: 'child context' - }; -} +module.exports = function isCancel(value) { + return !!(value && value.__CANCEL__); +}; -module.exports = ReactPropTypeLocationNames; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 179 */ +/* 159 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; + + /** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. + * A `Cancel` is an object that is thrown when an operation is canceled. * - * + * @class + * @param {string=} message The message. */ +function Cancel(message) { + this.message = message; +} + +Cancel.prototype.toString = function toString() { + return 'Cancel' + (this.message ? ': ' + this.message : ''); +}; +Cancel.prototype.__CANCEL__ = true; +module.exports = Cancel; -var nextDebugID = 1; -function getNextDebugID() { - return nextDebugID++; -} +/***/ }), +/* 160 */ +/***/ (function(module, exports, __webpack_require__) { -module.exports = getNextDebugID; +module.exports = { + address: __webpack_require__(96), + config: __webpack_require__(66), + zaddress: __webpack_require__(412), + crypto: __webpack_require__(107), + transaction: __webpack_require__(458) +}; /***/ }), -/* 180 */ +/* 161 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +/* WEBPACK VAR INJECTION */(function(global, process) {// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. -// The Symbol used to tag the ReactElement type. If there is no native Symbol -// nor polyfill, then a plain number is used for performance. +/*<replacement>*/ -var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; +var processNextTick = __webpack_require__(64); +/*</replacement>*/ -module.exports = REACT_ELEMENT_TYPE; +module.exports = Readable; -/***/ }), -/* 181 */ -/***/ (function(module, exports, __webpack_require__) { +/*<replacement>*/ +var isArray = __webpack_require__(154); +/*</replacement>*/ -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +/*<replacement>*/ +var Duplex; +/*</replacement>*/ +Readable.ReadableState = ReadableState; +/*<replacement>*/ +var EE = __webpack_require__(99).EventEmitter; -/* global Symbol */ +var EElistenerCount = function (emitter, type) { + return emitter.listeners(type).length; +}; +/*</replacement>*/ -var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; -var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. +/*<replacement>*/ +var Stream = __webpack_require__(162); +/*</replacement>*/ -/** - * Returns the iterator method function contained on the iterable object. - * - * Be sure to invoke the function with the iterable as context: - * - * var iteratorFn = getIteratorFn(myIterable); - * if (iteratorFn) { - * var iterator = iteratorFn.call(myIterable); - * ... - * } - * - * @param {?object} maybeIterable - * @return {?function} - */ -function getIteratorFn(maybeIterable) { - var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); - if (typeof iteratorFn === 'function') { - return iteratorFn; - } +// TODO(bmeurer): Change this back to const once hole checks are +// properly optimized away early in Ignition+TurboFan. +/*<replacement>*/ +var Buffer = __webpack_require__(7).Buffer; +var OurUint8Array = global.Uint8Array || function () {}; +function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk); } +function _isUint8Array(obj) { + return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; +} +/*</replacement>*/ -module.exports = getIteratorFn; - -/***/ }), -/* 182 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ - +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ +/*<replacement>*/ +var debugUtil = __webpack_require__(367); +var debug = void 0; +if (debugUtil && debugUtil.debuglog) { + debug = debugUtil.debuglog('stream'); +} else { + debug = function () {}; +} +/*</replacement>*/ -var KeyEscapeUtils = __webpack_require__(62); -var traverseAllChildren = __webpack_require__(100); -var warning = __webpack_require__(2); +var BufferList = __webpack_require__(368); +var destroyImpl = __webpack_require__(163); +var StringDecoder; -var ReactComponentTreeHook; +util.inherits(Readable, Stream); -if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { - // Temporary hack. - // Inline requires don't work well with Jest: - // https://github.com/facebook/react/issues/7240 - // Remove the inline requires when we don't need them anymore: - // https://github.com/facebook/react/pull/7178 - ReactComponentTreeHook = __webpack_require__(10); -} +var kProxyEvents = ['error', 'close', 'destroy', 'pause', 'resume']; -/** - * @param {function} traverseContext Context passed through traversal. - * @param {?ReactComponent} child React child component. - * @param {!string} name String name of key path to child. - * @param {number=} selfDebugID Optional debugID of the current internal instance. - */ -function flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID) { - // We found a component instance. - if (traverseContext && typeof traverseContext === 'object') { - var result = traverseContext; - var keyUnique = result[name] === undefined; - if (process.env.NODE_ENV !== 'production') { - if (!ReactComponentTreeHook) { - ReactComponentTreeHook = __webpack_require__(10); - } - if (!keyUnique) { - process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; - } - } - if (keyUnique && child != null) { - result[name] = child; - } +function prependListener(emitter, event, fn) { + // Sadly this is not cacheable as some libraries bundle their own + // event emitter implementation with them. + if (typeof emitter.prependListener === 'function') { + return emitter.prependListener(event, fn); + } else { + // This is a hack to make sure that our error handler is attached before any + // userland ones. NEVER DO THIS. This is here only because this code needs + // to continue to work with older versions of Node.js that do not include + // the prependListener() method. The goal is to eventually remove this hack. + if (!emitter._events || !emitter._events[event]) emitter.on(event, fn);else if (isArray(emitter._events[event])) emitter._events[event].unshift(fn);else emitter._events[event] = [fn, emitter._events[event]]; } } -/** - * Flattens children that are typically specified as `props.children`. Any null - * children will not be included in the resulting object. - * @return {!object} flattened children keyed by name. - */ -function flattenChildren(children, selfDebugID) { - if (children == null) { - return children; - } - var result = {}; +function ReadableState(options, stream) { + Duplex = Duplex || __webpack_require__(34); - if (process.env.NODE_ENV !== 'production') { - traverseAllChildren(children, function (traverseContext, child, name) { - return flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID); - }, result); - } else { - traverseAllChildren(children, flattenSingleChildIntoContext, result); - } - return result; -} + options = options || {}; -module.exports = flattenChildren; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // object stream flag. Used to make read(n) ignore n and to + // make all the buffer merging and length checks go away + this.objectMode = !!options.objectMode; -/***/ }), -/* 183 */ -/***/ (function(module, exports, __webpack_require__) { + if (stream instanceof Duplex) this.objectMode = this.objectMode || !!options.readableObjectMode; -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // the point at which it stops calling _read() to fill the buffer + // Note: 0 is a valid value, means "don't call _read preemptively ever" + var hwm = options.highWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; + this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm; + // cast to ints. + this.highWaterMark = Math.floor(this.highWaterMark); + // A linked list is used to store data chunks instead of an array because the + // linked list can remove elements from the beginning faster than + // array.shift() + this.buffer = new BufferList(); + this.length = 0; + this.pipes = null; + this.pipesCount = 0; + this.flowing = null; + this.ended = false; + this.endEmitted = false; + this.reading = false; -var _assign = __webpack_require__(5); + // a flag to be able to tell if the event 'readable'/'data' is emitted + // immediately, or on a later tick. We set this to true at first, because + // any actions that shouldn't happen until "later" should generally also + // not happen before the first read call. + this.sync = true; -var PooledClass = __webpack_require__(20); -var Transaction = __webpack_require__(41); -var ReactInstrumentation = __webpack_require__(13); -var ReactServerUpdateQueue = __webpack_require__(184); + // whenever we return null, then we set a flag to say + // that we're awaiting a 'readable' event emission. + this.needReadable = false; + this.emittedReadable = false; + this.readableListening = false; + this.resumeScheduled = false; -/** - * Executed within the scope of the `Transaction` instance. Consider these as - * being member methods, but with an implied ordering while being isolated from - * each other. - */ -var TRANSACTION_WRAPPERS = []; + // has it been destroyed + this.destroyed = false; -if (process.env.NODE_ENV !== 'production') { - TRANSACTION_WRAPPERS.push({ - initialize: ReactInstrumentation.debugTool.onBeginFlush, - close: ReactInstrumentation.debugTool.onEndFlush - }); -} + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; -var noopCallbackQueue = { - enqueue: function () {} -}; + // the number of writers that are awaiting a drain event in .pipe()s + this.awaitDrain = 0; -/** - * @class ReactServerRenderingTransaction - * @param {boolean} renderToStaticMarkup - */ -function ReactServerRenderingTransaction(renderToStaticMarkup) { - this.reinitializeTransaction(); - this.renderToStaticMarkup = renderToStaticMarkup; - this.useCreateElement = false; - this.updateQueue = new ReactServerUpdateQueue(this); -} + // if true, a maybeReadMore has been scheduled + this.readingMore = false; -var Mixin = { - /** - * @see Transaction - * @abstract - * @final - * @return {array} Empty list of operation wrap procedures. - */ - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, + this.decoder = null; + this.encoding = null; + if (options.encoding) { + if (!StringDecoder) StringDecoder = __webpack_require__(102).StringDecoder; + this.decoder = new StringDecoder(options.encoding); + this.encoding = options.encoding; + } +} - /** - * @return {object} The queue to collect `onDOMReady` callbacks with. - */ - getReactMountReady: function () { - return noopCallbackQueue; - }, +function Readable(options) { + Duplex = Duplex || __webpack_require__(34); - /** - * @return {object} The queue to collect React async events. - */ - getUpdateQueue: function () { - return this.updateQueue; - }, + if (!(this instanceof Readable)) return new Readable(options); - /** - * `PooledClass` looks for this, and will invoke this before allowing this - * instance to be reused. - */ - destructor: function () {}, + this._readableState = new ReadableState(options, this); - checkpoint: function () {}, + // legacy + this.readable = true; - rollback: function () {} -}; + if (options) { + if (typeof options.read === 'function') this._read = options.read; -_assign(ReactServerRenderingTransaction.prototype, Transaction, Mixin); + if (typeof options.destroy === 'function') this._destroy = options.destroy; + } -PooledClass.addPoolingTo(ReactServerRenderingTransaction); + Stream.call(this); +} -module.exports = ReactServerRenderingTransaction; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Object.defineProperty(Readable.prototype, 'destroyed', { + get: function () { + if (this._readableState === undefined) { + return false; + } + return this._readableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (!this._readableState) { + return; + } -/***/ }), -/* 184 */ -/***/ (function(module, exports, __webpack_require__) { + // backward compatibility, the user is explicitly + // managing destroyed + this._readableState.destroyed = value; + } +}); -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Readable.prototype.destroy = destroyImpl.destroy; +Readable.prototype._undestroy = destroyImpl.undestroy; +Readable.prototype._destroy = function (err, cb) { + this.push(null); + cb(err); +}; +// Manually shove something into the read() buffer. +// This returns true if the highWaterMark has not been hit yet, +// similar to how Writable.write() returns true if you should +// write() some more. +Readable.prototype.push = function (chunk, encoding) { + var state = this._readableState; + var skipChunkCheck; + if (!state.objectMode) { + if (typeof chunk === 'string') { + encoding = encoding || state.defaultEncoding; + if (encoding !== state.encoding) { + chunk = Buffer.from(chunk, encoding); + encoding = ''; + } + skipChunkCheck = true; + } + } else { + skipChunkCheck = true; + } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + return readableAddChunk(this, chunk, encoding, false, skipChunkCheck); +}; -var ReactUpdateQueue = __webpack_require__(63); +// Unshift should *always* be something directly out of read() +Readable.prototype.unshift = function (chunk) { + return readableAddChunk(this, chunk, null, true, false); +}; -var warning = __webpack_require__(2); +function readableAddChunk(stream, chunk, encoding, addToFront, skipChunkCheck) { + var state = stream._readableState; + if (chunk === null) { + state.reading = false; + onEofChunk(stream, state); + } else { + var er; + if (!skipChunkCheck) er = chunkInvalid(state, chunk); + if (er) { + stream.emit('error', er); + } else if (state.objectMode || chunk && chunk.length > 0) { + if (typeof chunk !== 'string' && !state.objectMode && Object.getPrototypeOf(chunk) !== Buffer.prototype) { + chunk = _uint8ArrayToBuffer(chunk); + } -function warnNoop(publicInstance, callerName) { - if (process.env.NODE_ENV !== 'production') { - var constructor = publicInstance.constructor; - process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounting component. ' + 'This usually means you called %s() outside componentWillMount() on the server. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; + if (addToFront) { + if (state.endEmitted) stream.emit('error', new Error('stream.unshift() after end event'));else addChunk(stream, state, chunk, true); + } else if (state.ended) { + stream.emit('error', new Error('stream.push() after EOF')); + } else { + state.reading = false; + if (state.decoder && !encoding) { + chunk = state.decoder.write(chunk); + if (state.objectMode || chunk.length !== 0) addChunk(stream, state, chunk, false);else maybeReadMore(stream, state); + } else { + addChunk(stream, state, chunk, false); + } + } + } else if (!addToFront) { + state.reading = false; + } } + + return needMoreData(state); } -/** - * This is the update queue used for server rendering. - * It delegates to ReactUpdateQueue while server rendering is in progress and - * switches to ReactNoopUpdateQueue after the transaction has completed. - * @class ReactServerUpdateQueue - * @param {Transaction} transaction - */ +function addChunk(stream, state, chunk, addToFront) { + if (state.flowing && state.length === 0 && !state.sync) { + stream.emit('data', chunk); + stream.read(0); + } else { + // update the buffer info. + state.length += state.objectMode ? 1 : chunk.length; + if (addToFront) state.buffer.unshift(chunk);else state.buffer.push(chunk); -var ReactServerUpdateQueue = function () { - function ReactServerUpdateQueue(transaction) { - _classCallCheck(this, ReactServerUpdateQueue); + if (state.needReadable) emitReadable(stream); + } + maybeReadMore(stream, state); +} - this.transaction = transaction; +function chunkInvalid(state, chunk) { + var er; + if (!_isUint8Array(chunk) && typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); } + return er; +} - /** - * Checks whether or not this composite component is mounted. - * @param {ReactClass} publicInstance The instance we want to test. - * @return {boolean} True if mounted, false otherwise. - * @protected - * @final - */ +// if it's past the high water mark, we can push in some more. +// Also, if we have no data yet, we can stand some +// more bytes. This is to work around cases where hwm=0, +// such as the repl. Also, if the push() triggered a +// readable event, and the user called read(largeNumber) such that +// needReadable was set, then we ought to push more, so that another +// 'readable' event will be triggered. +function needMoreData(state) { + return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0); +} +Readable.prototype.isPaused = function () { + return this._readableState.flowing === false; +}; - ReactServerUpdateQueue.prototype.isMounted = function isMounted(publicInstance) { - return false; - }; +// backwards compatibility. +Readable.prototype.setEncoding = function (enc) { + if (!StringDecoder) StringDecoder = __webpack_require__(102).StringDecoder; + this._readableState.decoder = new StringDecoder(enc); + this._readableState.encoding = enc; + return this; +}; - /** - * Enqueue a callback that will be executed after all the pending updates - * have processed. - * - * @param {ReactClass} publicInstance The instance to use as `this` context. - * @param {?function} callback Called after state is updated. - * @internal - */ +// Don't raise the hwm > 8MB +var MAX_HWM = 0x800000; +function computeNewHighWaterMark(n) { + if (n >= MAX_HWM) { + n = MAX_HWM; + } else { + // Get the next highest power of 2 to prevent increasing hwm excessively in + // tiny amounts + n--; + n |= n >>> 1; + n |= n >>> 2; + n |= n >>> 4; + n |= n >>> 8; + n |= n >>> 16; + n++; + } + return n; +} +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function howMuchToRead(n, state) { + if (n <= 0 || state.length === 0 && state.ended) return 0; + if (state.objectMode) return 1; + if (n !== n) { + // Only flow one buffer at a time + if (state.flowing && state.length) return state.buffer.head.data.length;else return state.length; + } + // If we're asking for more than the current hwm, then raise the hwm. + if (n > state.highWaterMark) state.highWaterMark = computeNewHighWaterMark(n); + if (n <= state.length) return n; + // Don't have enough + if (!state.ended) { + state.needReadable = true; + return 0; + } + return state.length; +} - ReactServerUpdateQueue.prototype.enqueueCallback = function enqueueCallback(publicInstance, callback, callerName) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueCallback(publicInstance, callback, callerName); - } - }; +// you can override either this method, or the async _read(n) below. +Readable.prototype.read = function (n) { + debug('read', n); + n = parseInt(n, 10); + var state = this._readableState; + var nOrig = n; - /** - * Forces an update. This should only be invoked when it is known with - * certainty that we are **not** in a DOM transaction. - * - * You may want to call this when you know that some deeper aspect of the - * component's state has changed but `setState` was not called. - * - * This will not invoke `shouldComponentUpdate`, but it will invoke - * `componentWillUpdate` and `componentDidUpdate`. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @internal - */ + if (n !== 0) state.emittedReadable = false; + // if we're doing read(0) to trigger a readable event, but we + // already have a bunch of data in the buffer, then just trigger + // the 'readable' event and move on. + if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) { + debug('read: emitReadable', state.length, state.ended); + if (state.length === 0 && state.ended) endReadable(this);else emitReadable(this); + return null; + } - ReactServerUpdateQueue.prototype.enqueueForceUpdate = function enqueueForceUpdate(publicInstance) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueForceUpdate(publicInstance); - } else { - warnNoop(publicInstance, 'forceUpdate'); - } - }; - - /** - * Replaces all of the state. Always use this or `setState` to mutate state. - * You should treat `this.state` as immutable. - * - * There is no guarantee that `this.state` will be immediately updated, so - * accessing `this.state` after calling this method may return the old value. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object|function} completeState Next state. - * @internal - */ - - - ReactServerUpdateQueue.prototype.enqueueReplaceState = function enqueueReplaceState(publicInstance, completeState) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueReplaceState(publicInstance, completeState); - } else { - warnNoop(publicInstance, 'replaceState'); - } - }; - - /** - * Sets a subset of the state. This only exists because _pendingState is - * internal. This provides a merging strategy that is not available to deep - * properties which is confusing. TODO: Expose pendingState or don't use it - * during the merge. - * - * @param {ReactClass} publicInstance The instance that should rerender. - * @param {object|function} partialState Next partial state to be merged with state. - * @internal - */ + n = howMuchToRead(n, state); + // if we've ended, and we're now clear, then finish it up. + if (n === 0 && state.ended) { + if (state.length === 0) endReadable(this); + return null; + } - ReactServerUpdateQueue.prototype.enqueueSetState = function enqueueSetState(publicInstance, partialState) { - if (this.transaction.isInTransaction()) { - ReactUpdateQueue.enqueueSetState(publicInstance, partialState); - } else { - warnNoop(publicInstance, 'setState'); - } - }; + // All the actual chunk generation logic needs to be + // *below* the call to _read. The reason is that in certain + // synthetic stream cases, such as passthrough streams, _read + // may be a completely synchronous operation which may change + // the state of the read buffer, providing enough data when + // before there was *not* enough. + // + // So, the steps are: + // 1. Figure out what the state of things will be after we do + // a read from the buffer. + // + // 2. If that resulting state will trigger a _read, then call _read. + // Note that this may be asynchronous, or synchronous. Yes, it is + // deeply ugly to write APIs this way, but that still doesn't mean + // that the Readable class should behave improperly, as streams are + // designed to be sync/async agnostic. + // Take note if the _read call is sync or async (ie, if the read call + // has returned yet), so that we know whether or not it's safe to emit + // 'readable' etc. + // + // 3. Actually pull the requested chunks out of the buffer and return. - return ReactServerUpdateQueue; -}(); + // if we need a readable event, then we need to do some reading. + var doRead = state.needReadable; + debug('need readable', doRead); -module.exports = ReactServerUpdateQueue; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + // if we currently have less than the highWaterMark, then also read some + if (state.length === 0 || state.length - n < state.highWaterMark) { + doRead = true; + debug('length less than watermark', doRead); + } -/***/ }), -/* 185 */ -/***/ (function(module, exports, __webpack_require__) { + // however, if we've ended, then there's no point, and if we're already + // reading, then it's unnecessary. + if (state.ended || state.reading) { + doRead = false; + debug('reading or ended', doRead); + } else if (doRead) { + debug('do read'); + state.reading = true; + state.sync = true; + // if the length is currently zero, then we *need* a readable event. + if (state.length === 0) state.needReadable = true; + // call internal read method + this._read(state.highWaterMark); + state.sync = false; + // If _read pushed data synchronously, then `reading` will be false, + // and we need to re-evaluate how much data we can return to the user. + if (!state.reading) n = howMuchToRead(nOrig, state); + } -"use strict"; -/** - * Copyright 2014-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var ret; + if (n > 0) ret = fromList(n, state);else ret = null; + if (ret === null) { + state.needReadable = true; + n = 0; + } else { + state.length -= n; + } + if (state.length === 0) { + // If we have nothing in the buffer, then we want to know + // as soon as we *do* get something into the buffer. + if (!state.ended) state.needReadable = true; -var _assign = __webpack_require__(5); + // If we tried to read() past the EOF, then emit end on the next tick. + if (nOrig !== n && state.ended) endReadable(this); + } -var DOMLazyTree = __webpack_require__(27); -var ReactDOMComponentTree = __webpack_require__(6); + if (ret !== null) this.emit('data', ret); -var ReactDOMEmptyComponent = function (instantiate) { - // ReactCompositeComponent uses this: - this._currentElement = null; - // ReactDOMComponentTree uses these: - this._hostNode = null; - this._hostParent = null; - this._hostContainerInfo = null; - this._domID = 0; + return ret; }; -_assign(ReactDOMEmptyComponent.prototype, { - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - var domID = hostContainerInfo._idCounter++; - this._domID = domID; - this._hostParent = hostParent; - this._hostContainerInfo = hostContainerInfo; - var nodeValue = ' react-empty: ' + this._domID + ' '; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var node = ownerDocument.createComment(nodeValue); - ReactDOMComponentTree.precacheNode(this, node); - return DOMLazyTree(node); - } else { - if (transaction.renderToStaticMarkup) { - // Normally we'd insert a comment node, but since this is a situation - // where React won't take over (static pages), we can simply return - // nothing. - return ''; - } - return '<!--' + nodeValue + '-->'; +function onEofChunk(stream, state) { + if (state.ended) return; + if (state.decoder) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) { + state.buffer.push(chunk); + state.length += state.objectMode ? 1 : chunk.length; } - }, - receiveComponent: function () {}, - getHostNode: function () { - return ReactDOMComponentTree.getNodeFromInstance(this); - }, - unmountComponent: function () { - ReactDOMComponentTree.uncacheNode(this); } -}); - -module.exports = ReactDOMEmptyComponent; + state.ended = true; -/***/ }), -/* 186 */ -/***/ (function(module, exports, __webpack_require__) { + // emit 'readable' now to make sure it gets picked up. + emitReadable(stream); +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +// Don't emit readable right away in sync mode, because this can trigger +// another read() call => stack overflow. This way, it might trigger +// a nextTick recursion warning, but that's not so bad. +function emitReadable(stream) { + var state = stream._readableState; + state.needReadable = false; + if (!state.emittedReadable) { + debug('emitReadable', state.flowing); + state.emittedReadable = true; + if (state.sync) processNextTick(emitReadable_, stream);else emitReadable_(stream); + } +} +function emitReadable_(stream) { + debug('emit readable'); + stream.emit('readable'); + flow(stream); +} +// at this point, the user has presumably seen the 'readable' event, +// and called read() to consume some data. that may have triggered +// in turn another _read(n) call, in which case reading = true if +// it's in progress. +// However, if we're not ended, or reading, and the length < hwm, +// then go ahead and try to read some more preemptively. +function maybeReadMore(stream, state) { + if (!state.readingMore) { + state.readingMore = true; + processNextTick(maybeReadMore_, stream, state); + } +} -var _prodInvariant = __webpack_require__(3); +function maybeReadMore_(stream, state) { + var len = state.length; + while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) { + debug('maybeReadMore read 0'); + stream.read(0); + if (len === state.length) + // didn't get any data, stop spinning. + break;else len = state.length; + } + state.readingMore = false; +} -var invariant = __webpack_require__(1); +// abstract method. to be overridden in specific implementation classes. +// call cb(er, data) where data is <= n in length. +// for virtual (non-string, non-buffer) streams, "length" is somewhat +// arbitrary, and perhaps not very meaningful. +Readable.prototype._read = function (n) { + this.emit('error', new Error('_read() is not implemented')); +}; -/** - * Return the lowest common ancestor of A and B, or null if they are in - * different trees. - */ -function getLowestCommonAncestor(instA, instB) { - !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; - !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; +Readable.prototype.pipe = function (dest, pipeOpts) { + var src = this; + var state = this._readableState; - var depthA = 0; - for (var tempA = instA; tempA; tempA = tempA._hostParent) { - depthA++; - } - var depthB = 0; - for (var tempB = instB; tempB; tempB = tempB._hostParent) { - depthB++; + switch (state.pipesCount) { + case 0: + state.pipes = dest; + break; + case 1: + state.pipes = [state.pipes, dest]; + break; + default: + state.pipes.push(dest); + break; } + state.pipesCount += 1; + debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts); - // If A is deeper, crawl up. - while (depthA - depthB > 0) { - instA = instA._hostParent; - depthA--; - } + var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr; - // If B is deeper, crawl up. - while (depthB - depthA > 0) { - instB = instB._hostParent; - depthB--; - } + var endFn = doEnd ? onend : unpipe; + if (state.endEmitted) processNextTick(endFn);else src.once('end', endFn); - // Walk in lockstep until we find a match. - var depth = depthA; - while (depth--) { - if (instA === instB) { - return instA; + dest.on('unpipe', onunpipe); + function onunpipe(readable, unpipeInfo) { + debug('onunpipe'); + if (readable === src) { + if (unpipeInfo && unpipeInfo.hasUnpiped === false) { + unpipeInfo.hasUnpiped = true; + cleanup(); + } } - instA = instA._hostParent; - instB = instB._hostParent; } - return null; -} - -/** - * Return if A is an ancestor of B. - */ -function isAncestor(instA, instB) { - !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; - !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; - while (instB) { - if (instB === instA) { - return true; - } - instB = instB._hostParent; + function onend() { + debug('onend'); + dest.end(); } - return false; -} -/** - * Return the parent instance of the passed-in instance. - */ -function getParentInstance(inst) { - !('_hostNode' in inst) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getParentInstance: Invalid argument.') : _prodInvariant('36') : void 0; + // when the dest drains, it reduces the awaitDrain counter + // on the source. This would be more elegant with a .once() + // handler in flow(), but adding and removing repeatedly is + // too slow. + var ondrain = pipeOnDrain(src); + dest.on('drain', ondrain); - return inst._hostParent; -} + var cleanedUp = false; + function cleanup() { + debug('cleanup'); + // cleanup event handlers once the pipe is broken + dest.removeListener('close', onclose); + dest.removeListener('finish', onfinish); + dest.removeListener('drain', ondrain); + dest.removeListener('error', onerror); + dest.removeListener('unpipe', onunpipe); + src.removeListener('end', onend); + src.removeListener('end', unpipe); + src.removeListener('data', ondata); -/** - * Simulates the traversal of a two-phase, capture/bubble event dispatch. - */ -function traverseTwoPhase(inst, fn, arg) { - var path = []; - while (inst) { - path.push(inst); - inst = inst._hostParent; + cleanedUp = true; + + // if the reader is waiting for a drain event from this + // specific writer, then it would cause it to never start + // flowing again. + // So, if this is awaiting a drain, then we just call it now. + // If we don't know, then assume that we are waiting for one. + if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain)) ondrain(); } - var i; - for (i = path.length; i-- > 0;) { - fn(path[i], 'captured', arg); + + // If the user pushes more data while we're writing to dest then we'll end up + // in ondata again. However, we only want to increase awaitDrain once because + // dest will only emit one 'drain' event for the multiple writes. + // => Introduce a guard on increasing awaitDrain. + var increasedAwaitDrain = false; + src.on('data', ondata); + function ondata(chunk) { + debug('ondata'); + increasedAwaitDrain = false; + var ret = dest.write(chunk); + if (false === ret && !increasedAwaitDrain) { + // If the user unpiped during `dest.write()`, it is possible + // to get stuck in a permanently paused state if that write + // also returned false. + // => Check whether `dest` is still a piping destination. + if ((state.pipesCount === 1 && state.pipes === dest || state.pipesCount > 1 && indexOf(state.pipes, dest) !== -1) && !cleanedUp) { + debug('false write response, pause', src._readableState.awaitDrain); + src._readableState.awaitDrain++; + increasedAwaitDrain = true; + } + src.pause(); + } } - for (i = 0; i < path.length; i++) { - fn(path[i], 'bubbled', arg); + + // if the dest has an error, then stop piping into it. + // however, don't suppress the throwing behavior for this. + function onerror(er) { + debug('onerror', er); + unpipe(); + dest.removeListener('error', onerror); + if (EElistenerCount(dest, 'error') === 0) dest.emit('error', er); } -} -/** - * Traverses the ID hierarchy and invokes the supplied `cb` on any IDs that - * should would receive a `mouseEnter` or `mouseLeave` event. - * - * Does not invoke the callback on the nearest common ancestor because nothing - * "entered" or "left" that element. - */ -function traverseEnterLeave(from, to, fn, argFrom, argTo) { - var common = from && to ? getLowestCommonAncestor(from, to) : null; - var pathFrom = []; - while (from && from !== common) { - pathFrom.push(from); - from = from._hostParent; + // Make sure our error handler is attached before userland ones. + prependListener(dest, 'error', onerror); + + // Both close and finish should trigger unpipe, but only once. + function onclose() { + dest.removeListener('finish', onfinish); + unpipe(); } - var pathTo = []; - while (to && to !== common) { - pathTo.push(to); - to = to._hostParent; + dest.once('close', onclose); + function onfinish() { + debug('onfinish'); + dest.removeListener('close', onclose); + unpipe(); } - var i; - for (i = 0; i < pathFrom.length; i++) { - fn(pathFrom[i], 'bubbled', argFrom); + dest.once('finish', onfinish); + + function unpipe() { + debug('unpipe'); + src.unpipe(dest); } - for (i = pathTo.length; i-- > 0;) { - fn(pathTo[i], 'captured', argTo); + + // tell the dest that it's being piped to + dest.emit('pipe', src); + + // start the flow if it hasn't been started already. + if (!state.flowing) { + debug('pipe resume'); + src.resume(); } -} -module.exports = { - isAncestor: isAncestor, - getLowestCommonAncestor: getLowestCommonAncestor, - getParentInstance: getParentInstance, - traverseTwoPhase: traverseTwoPhase, - traverseEnterLeave: traverseEnterLeave + return dest; }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -/***/ }), -/* 187 */ -/***/ (function(module, exports, __webpack_require__) { +function pipeOnDrain(src) { + return function () { + var state = src._readableState; + debug('pipeOnDrain', state.awaitDrain); + if (state.awaitDrain) state.awaitDrain--; + if (state.awaitDrain === 0 && EElistenerCount(src, 'data')) { + state.flowing = true; + flow(src); + } + }; +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +Readable.prototype.unpipe = function (dest) { + var state = this._readableState; + var unpipeInfo = { hasUnpiped: false }; + // if we're not piping anywhere, then do nothing. + if (state.pipesCount === 0) return this; + // just one destination. most common case. + if (state.pipesCount === 1) { + // passed in one, but it's not the right one. + if (dest && dest !== state.pipes) return this; -var _prodInvariant = __webpack_require__(3), - _assign = __webpack_require__(5); + if (!dest) dest = state.pipes; -var DOMChildrenOperations = __webpack_require__(55); -var DOMLazyTree = __webpack_require__(27); -var ReactDOMComponentTree = __webpack_require__(6); + // got a match. + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + if (dest) dest.emit('unpipe', this, unpipeInfo); + return this; + } -var escapeTextContentForBrowser = __webpack_require__(44); -var invariant = __webpack_require__(1); -var validateDOMNesting = __webpack_require__(64); + // slow case. multiple pipe destinations. -/** - * Text nodes violate a couple assumptions that React makes about components: - * - * - When mounting text into the DOM, adjacent text nodes are merged. - * - Text nodes cannot be assigned a React root ID. - * - * This component is used to wrap strings between comment nodes so that they - * can undergo the same reconciliation that is applied to elements. - * - * TODO: Investigate representing React components in the DOM with text nodes. - * - * @class ReactDOMTextComponent - * @extends ReactComponent - * @internal - */ -var ReactDOMTextComponent = function (text) { - // TODO: This is really a ReactText (ReactNode), not a ReactElement - this._currentElement = text; - this._stringText = '' + text; - // ReactDOMComponentTree uses these: - this._hostNode = null; - this._hostParent = null; + if (!dest) { + // remove all. + var dests = state.pipes; + var len = state.pipesCount; + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; - // Properties - this._domID = 0; - this._mountIndex = 0; - this._closingComment = null; - this._commentNodes = null; -}; + for (var i = 0; i < len; i++) { + dests[i].emit('unpipe', this, unpipeInfo); + }return this; + } -_assign(ReactDOMTextComponent.prototype, { - /** - * Creates the markup for this text node. This node is not intended to have - * any features besides containing text content. - * - * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction - * @return {string} Markup for this text node. - * @internal - */ - mountComponent: function (transaction, hostParent, hostContainerInfo, context) { - if (process.env.NODE_ENV !== 'production') { - var parentInfo; - if (hostParent != null) { - parentInfo = hostParent._ancestorInfo; - } else if (hostContainerInfo != null) { - parentInfo = hostContainerInfo._ancestorInfo; - } - if (parentInfo) { - // parentInfo should always be present except for the top-level - // component when server rendering - validateDOMNesting(null, this._stringText, this, parentInfo); - } - } + // try to find the right one. + var index = indexOf(state.pipes, dest); + if (index === -1) return this; - var domID = hostContainerInfo._idCounter++; - var openingValue = ' react-text: ' + domID + ' '; - var closingValue = ' /react-text '; - this._domID = domID; - this._hostParent = hostParent; - if (transaction.useCreateElement) { - var ownerDocument = hostContainerInfo._ownerDocument; - var openingComment = ownerDocument.createComment(openingValue); - var closingComment = ownerDocument.createComment(closingValue); - var lazyTree = DOMLazyTree(ownerDocument.createDocumentFragment()); - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(openingComment)); - if (this._stringText) { - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(ownerDocument.createTextNode(this._stringText))); - } - DOMLazyTree.queueChild(lazyTree, DOMLazyTree(closingComment)); - ReactDOMComponentTree.precacheNode(this, openingComment); - this._closingComment = closingComment; - return lazyTree; - } else { - var escapedText = escapeTextContentForBrowser(this._stringText); + state.pipes.splice(index, 1); + state.pipesCount -= 1; + if (state.pipesCount === 1) state.pipes = state.pipes[0]; - if (transaction.renderToStaticMarkup) { - // Normally we'd wrap this between comment nodes for the reasons stated - // above, but since this is a situation where React won't take over - // (static pages), we can simply return the text as it is. - return escapedText; - } + dest.emit('unpipe', this, unpipeInfo); - return '<!--' + openingValue + '-->' + escapedText + '<!--' + closingValue + '-->'; - } - }, + return this; +}; - /** - * Updates this component by updating the text content. - * - * @param {ReactText} nextText The next text content - * @param {ReactReconcileTransaction} transaction - * @internal - */ - receiveComponent: function (nextText, transaction) { - if (nextText !== this._currentElement) { - this._currentElement = nextText; - var nextStringText = '' + nextText; - if (nextStringText !== this._stringText) { - // TODO: Save this as pending props and use performUpdateIfNecessary - // and/or updateComponent to do the actual update for consistency with - // other component types? - this._stringText = nextStringText; - var commentNodes = this.getHostNode(); - DOMChildrenOperations.replaceDelimitedText(commentNodes[0], commentNodes[1], nextStringText); - } - } - }, +// set up data events if they are asked for +// Ensure readable listeners eventually get something +Readable.prototype.on = function (ev, fn) { + var res = Stream.prototype.on.call(this, ev, fn); - getHostNode: function () { - var hostNode = this._commentNodes; - if (hostNode) { - return hostNode; - } - if (!this._closingComment) { - var openingComment = ReactDOMComponentTree.getNodeFromInstance(this); - var node = openingComment.nextSibling; - while (true) { - !(node != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Missing closing comment for text component %s', this._domID) : _prodInvariant('67', this._domID) : void 0; - if (node.nodeType === 8 && node.nodeValue === ' /react-text ') { - this._closingComment = node; - break; - } - node = node.nextSibling; + if (ev === 'data') { + // Start flowing on next tick if stream isn't explicitly paused + if (this._readableState.flowing !== false) this.resume(); + } else if (ev === 'readable') { + var state = this._readableState; + if (!state.endEmitted && !state.readableListening) { + state.readableListening = state.needReadable = true; + state.emittedReadable = false; + if (!state.reading) { + processNextTick(nReadingNextTick, this); + } else if (state.length) { + emitReadable(this); } } - hostNode = [this._hostNode, this._closingComment]; - this._commentNodes = hostNode; - return hostNode; - }, - - unmountComponent: function () { - this._closingComment = null; - this._commentNodes = null; - ReactDOMComponentTree.uncacheNode(this); } -}); - -module.exports = ReactDOMTextComponent; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 188 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + return res; +}; +Readable.prototype.addListener = Readable.prototype.on; +function nReadingNextTick(self) { + debug('readable nexttick read 0'); + self.read(0); +} +// pause() and resume() are remnants of the legacy readable stream API +// If the user uses them, then switch into old mode. +Readable.prototype.resume = function () { + var state = this._readableState; + if (!state.flowing) { + debug('resume'); + state.flowing = true; + resume(this, state); + } + return this; +}; -var _assign = __webpack_require__(5); +function resume(stream, state) { + if (!state.resumeScheduled) { + state.resumeScheduled = true; + processNextTick(resume_, stream, state); + } +} -var ReactUpdates = __webpack_require__(15); -var Transaction = __webpack_require__(41); +function resume_(stream, state) { + if (!state.reading) { + debug('resume read 0'); + stream.read(0); + } -var emptyFunction = __webpack_require__(12); + state.resumeScheduled = false; + state.awaitDrain = 0; + stream.emit('resume'); + flow(stream); + if (state.flowing && !state.reading) stream.read(0); +} -var RESET_BATCHED_UPDATES = { - initialize: emptyFunction, - close: function () { - ReactDefaultBatchingStrategy.isBatchingUpdates = false; +Readable.prototype.pause = function () { + debug('call pause flowing=%j', this._readableState.flowing); + if (false !== this._readableState.flowing) { + debug('pause'); + this._readableState.flowing = false; + this.emit('pause'); } + return this; }; -var FLUSH_BATCHED_UPDATES = { - initialize: emptyFunction, - close: ReactUpdates.flushBatchedUpdates.bind(ReactUpdates) -}; - -var TRANSACTION_WRAPPERS = [FLUSH_BATCHED_UPDATES, RESET_BATCHED_UPDATES]; - -function ReactDefaultBatchingStrategyTransaction() { - this.reinitializeTransaction(); +function flow(stream) { + var state = stream._readableState; + debug('flow', state.flowing); + while (state.flowing && stream.read() !== null) {} } -_assign(ReactDefaultBatchingStrategyTransaction.prototype, Transaction, { - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - } -}); +// wrap an old-style stream as the async data source. +// This is *not* part of the readable stream interface. +// It is an ugly unfortunate mess of history. +Readable.prototype.wrap = function (stream) { + var state = this._readableState; + var paused = false; -var transaction = new ReactDefaultBatchingStrategyTransaction(); + var self = this; + stream.on('end', function () { + debug('wrapped end'); + if (state.decoder && !state.ended) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) self.push(chunk); + } -var ReactDefaultBatchingStrategy = { - isBatchingUpdates: false, + self.push(null); + }); - /** - * Call the provided function in a context within which calls to `setState` - * and friends are batched such that components aren't updated unnecessarily. - */ - batchedUpdates: function (callback, a, b, c, d, e) { - var alreadyBatchingUpdates = ReactDefaultBatchingStrategy.isBatchingUpdates; + stream.on('data', function (chunk) { + debug('wrapped data'); + if (state.decoder) chunk = state.decoder.write(chunk); - ReactDefaultBatchingStrategy.isBatchingUpdates = true; + // don't skip over falsy values in objectMode + if (state.objectMode && (chunk === null || chunk === undefined)) return;else if (!state.objectMode && (!chunk || !chunk.length)) return; - // The code is written this way to avoid extra allocations - if (alreadyBatchingUpdates) { - return callback(a, b, c, d, e); - } else { - return transaction.perform(callback, null, a, b, c, d, e); + var ret = self.push(chunk); + if (!ret) { + paused = true; + stream.pause(); } - } -}; + }); -module.exports = ReactDefaultBatchingStrategy; + // proxy all the other methods. + // important when wrapping filters and duplexes. + for (var i in stream) { + if (this[i] === undefined && typeof stream[i] === 'function') { + this[i] = function (method) { + return function () { + return stream[method].apply(stream, arguments); + }; + }(i); + } + } -/***/ }), -/* 189 */ -/***/ (function(module, exports, __webpack_require__) { + // proxy certain important events. + for (var n = 0; n < kProxyEvents.length; n++) { + stream.on(kProxyEvents[n], self.emit.bind(self, kProxyEvents[n])); + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + // when we try to consume some more bytes, simply unpause the + // underlying stream. + self._read = function (n) { + debug('wrapped _read', n); + if (paused) { + paused = false; + stream.resume(); + } + }; + return self; +}; +// exposed for testing purposes only. +Readable._fromList = fromList; -var _assign = __webpack_require__(5); +// Pluck off n bytes from an array of buffers. +// Length is the combined lengths of all the buffers in the list. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function fromList(n, state) { + // nothing buffered + if (state.length === 0) return null; -var EventListener = __webpack_require__(101); -var ExecutionEnvironment = __webpack_require__(8); -var PooledClass = __webpack_require__(20); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactUpdates = __webpack_require__(15); + var ret; + if (state.objectMode) ret = state.buffer.shift();else if (!n || n >= state.length) { + // read it all, truncate the list + if (state.decoder) ret = state.buffer.join('');else if (state.buffer.length === 1) ret = state.buffer.head.data;else ret = state.buffer.concat(state.length); + state.buffer.clear(); + } else { + // read part of list + ret = fromListPartial(n, state.buffer, state.decoder); + } -var getEventTarget = __webpack_require__(52); -var getUnboundedScrollPosition = __webpack_require__(190); + return ret; +} -/** - * Find the deepest React component completely containing the root of the - * passed-in instance (for use when entire React trees are nested within each - * other). If React trees are not nested, returns null. - */ -function findParent(inst) { - // TODO: It may be a good idea to cache this to prevent unnecessary DOM - // traversal, but caching is difficult to do correctly without using a - // mutation observer to listen for all DOM changes. - while (inst._hostParent) { - inst = inst._hostParent; +// Extracts only enough buffered data to satisfy the amount requested. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function fromListPartial(n, list, hasStrings) { + var ret; + if (n < list.head.data.length) { + // slice is the same for buffers and strings + ret = list.head.data.slice(0, n); + list.head.data = list.head.data.slice(n); + } else if (n === list.head.data.length) { + // first chunk is a perfect match + ret = list.shift(); + } else { + // result spans more than one buffer + ret = hasStrings ? copyFromBufferString(n, list) : copyFromBuffer(n, list); } - var rootNode = ReactDOMComponentTree.getNodeFromInstance(inst); - var container = rootNode.parentNode; - return ReactDOMComponentTree.getClosestInstanceFromNode(container); + return ret; } -// Used to store ancestor hierarchy in top level callback -function TopLevelCallbackBookKeeping(topLevelType, nativeEvent) { - this.topLevelType = topLevelType; - this.nativeEvent = nativeEvent; - this.ancestors = []; +// Copies a specified amount of characters from the list of buffered data +// chunks. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function copyFromBufferString(n, list) { + var p = list.head; + var c = 1; + var ret = p.data; + n -= ret.length; + while (p = p.next) { + var str = p.data; + var nb = n > str.length ? str.length : n; + if (nb === str.length) ret += str;else ret += str.slice(0, n); + n -= nb; + if (n === 0) { + if (nb === str.length) { + ++c; + if (p.next) list.head = p.next;else list.head = list.tail = null; + } else { + list.head = p; + p.data = str.slice(nb); + } + break; + } + ++c; + } + list.length -= c; + return ret; } -_assign(TopLevelCallbackBookKeeping.prototype, { - destructor: function () { - this.topLevelType = null; - this.nativeEvent = null; - this.ancestors.length = 0; + +// Copies a specified amount of bytes from the list of buffered data chunks. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function copyFromBuffer(n, list) { + var ret = Buffer.allocUnsafe(n); + var p = list.head; + var c = 1; + p.data.copy(ret); + n -= p.data.length; + while (p = p.next) { + var buf = p.data; + var nb = n > buf.length ? buf.length : n; + buf.copy(ret, ret.length - n, 0, nb); + n -= nb; + if (n === 0) { + if (nb === buf.length) { + ++c; + if (p.next) list.head = p.next;else list.head = list.tail = null; + } else { + list.head = p; + p.data = buf.slice(nb); + } + break; + } + ++c; } -}); -PooledClass.addPoolingTo(TopLevelCallbackBookKeeping, PooledClass.twoArgumentPooler); + list.length -= c; + return ret; +} -function handleTopLevelImpl(bookKeeping) { - var nativeEventTarget = getEventTarget(bookKeeping.nativeEvent); - var targetInst = ReactDOMComponentTree.getClosestInstanceFromNode(nativeEventTarget); +function endReadable(stream) { + var state = stream._readableState; - // Loop through the hierarchy, in case there's any nested components. - // It's important that we build the array of ancestors before calling any - // event handlers, because event handlers can modify the DOM, leading to - // inconsistencies with ReactMount's node cache. See #1105. - var ancestor = targetInst; - do { - bookKeeping.ancestors.push(ancestor); - ancestor = ancestor && findParent(ancestor); - } while (ancestor); + // If we get here before consuming all the bytes, then that is a + // bug in node. Should never happen. + if (state.length > 0) throw new Error('"endReadable()" called on non-empty stream'); - for (var i = 0; i < bookKeeping.ancestors.length; i++) { - targetInst = bookKeeping.ancestors[i]; - ReactEventListener._handleTopLevel(bookKeeping.topLevelType, targetInst, bookKeeping.nativeEvent, getEventTarget(bookKeeping.nativeEvent)); + if (!state.endEmitted) { + state.ended = true; + processNextTick(endReadableNT, state, stream); } } -function scrollValueMonitor(cb) { - var scrollPosition = getUnboundedScrollPosition(window); - cb(scrollPosition); +function endReadableNT(state, stream) { + // Check that we didn't get one last unshift. + if (!state.endEmitted && state.length === 0) { + state.endEmitted = true; + stream.readable = false; + stream.emit('end'); + } } -var ReactEventListener = { - _enabled: true, - _handleTopLevel: null, +function forEach(xs, f) { + for (var i = 0, l = xs.length; i < l; i++) { + f(xs[i], i); + } +} - WINDOW_HANDLE: ExecutionEnvironment.canUseDOM ? window : null, +function indexOf(xs, x) { + for (var i = 0, l = xs.length; i < l; i++) { + if (xs[i] === x) return i; + } + return -1; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) - setHandleTopLevel: function (handleTopLevel) { - ReactEventListener._handleTopLevel = handleTopLevel; - }, +/***/ }), +/* 162 */ +/***/ (function(module, exports, __webpack_require__) { - setEnabled: function (enabled) { - ReactEventListener._enabled = !!enabled; - }, +module.exports = __webpack_require__(99).EventEmitter; - isEnabled: function () { - return ReactEventListener._enabled; - }, - /** - * Traps top-level events by using event bubbling. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {string} handlerBaseName Event name (e.g. "click"). - * @param {object} element Element on which to attach listener. - * @return {?object} An object with a remove function which will forcefully - * remove the listener. - * @internal - */ - trapBubbledEvent: function (topLevelType, handlerBaseName, element) { - if (!element) { - return null; - } - return EventListener.listen(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); - }, +/***/ }), +/* 163 */ +/***/ (function(module, exports, __webpack_require__) { - /** - * Traps a top-level event by using event capturing. - * - * @param {string} topLevelType Record from `EventConstants`. - * @param {string} handlerBaseName Event name (e.g. "click"). - * @param {object} element Element on which to attach listener. - * @return {?object} An object with a remove function which will forcefully - * remove the listener. - * @internal - */ - trapCapturedEvent: function (topLevelType, handlerBaseName, element) { - if (!element) { - return null; - } - return EventListener.capture(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); - }, - - monitorScrollValue: function (refresh) { - var callback = scrollValueMonitor.bind(null, refresh); - EventListener.listen(window, 'scroll', callback); - }, - - dispatchEvent: function (topLevelType, nativeEvent) { - if (!ReactEventListener._enabled) { - return; - } +"use strict"; - var bookKeeping = TopLevelCallbackBookKeeping.getPooled(topLevelType, nativeEvent); - try { - // Event queue being processed in the same cycle allows - // `preventDefault`. - ReactUpdates.batchedUpdates(handleTopLevelImpl, bookKeeping); - } finally { - TopLevelCallbackBookKeeping.release(bookKeeping); - } - } -}; -module.exports = ReactEventListener; +/*<replacement>*/ -/***/ }), -/* 190 */ -/***/ (function(module, exports, __webpack_require__) { +var processNextTick = __webpack_require__(64); +/*</replacement>*/ -"use strict"; -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +// undocumented cb() API, needed for core, not for public API +function destroy(err, cb) { + var _this = this; + var readableDestroyed = this._readableState && this._readableState.destroyed; + var writableDestroyed = this._writableState && this._writableState.destroyed; + if (readableDestroyed || writableDestroyed) { + if (cb) { + cb(err); + } else if (err && (!this._writableState || !this._writableState.errorEmitted)) { + processNextTick(emitErrorNT, this, err); + } + return; + } -/** - * Gets the scroll position of the supplied element or window. - * - * The return values are unbounded, unlike `getScrollPosition`. This means they - * may be negative or exceed the element boundaries (which is possible using - * inertial scrolling). - * - * @param {DOMWindow|DOMElement} scrollable - * @return {object} Map with `x` and `y` keys. - */ + // we set destroyed to true before firing error callbacks in order + // to make it re-entrance safe in case destroy() is called within callbacks -function getUnboundedScrollPosition(scrollable) { - if (scrollable.Window && scrollable instanceof scrollable.Window) { - return { - x: scrollable.pageXOffset || scrollable.document.documentElement.scrollLeft, - y: scrollable.pageYOffset || scrollable.document.documentElement.scrollTop - }; + if (this._readableState) { + this._readableState.destroyed = true; } - return { - x: scrollable.scrollLeft, - y: scrollable.scrollTop - }; -} -module.exports = getUnboundedScrollPosition; - -/***/ }), -/* 191 */ -/***/ (function(module, exports, __webpack_require__) { + // if this is a duplex stream mark the writable part as destroyed as well + if (this._writableState) { + this._writableState.destroyed = true; + } -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + this._destroy(err || null, function (err) { + if (!cb && err) { + processNextTick(emitErrorNT, _this, err); + if (_this._writableState) { + _this._writableState.errorEmitted = true; + } + } else if (cb) { + cb(err); + } + }); +} +function undestroy() { + if (this._readableState) { + this._readableState.destroyed = false; + this._readableState.reading = false; + this._readableState.ended = false; + this._readableState.endEmitted = false; + } + if (this._writableState) { + this._writableState.destroyed = false; + this._writableState.ended = false; + this._writableState.ending = false; + this._writableState.finished = false; + this._writableState.errorEmitted = false; + } +} -var DOMProperty = __webpack_require__(17); -var EventPluginHub = __webpack_require__(32); -var EventPluginUtils = __webpack_require__(50); -var ReactComponentEnvironment = __webpack_require__(59); -var ReactEmptyComponent = __webpack_require__(98); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactHostComponent = __webpack_require__(99); -var ReactUpdates = __webpack_require__(15); +function emitErrorNT(self, err) { + self.emit('error', err); +} -var ReactInjection = { - Component: ReactComponentEnvironment.injection, - DOMProperty: DOMProperty.injection, - EmptyComponent: ReactEmptyComponent.injection, - EventPluginHub: EventPluginHub.injection, - EventPluginUtils: EventPluginUtils.injection, - EventEmitter: ReactBrowserEventEmitter.injection, - HostComponent: ReactHostComponent.injection, - Updates: ReactUpdates.injection +module.exports = { + destroy: destroy, + undestroy: undestroy }; -module.exports = ReactInjection; - /***/ }), -/* 192 */ +/* 164 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var _assign = __webpack_require__(5); +var apply = Function.prototype.apply; -var CallbackQueue = __webpack_require__(85); -var PooledClass = __webpack_require__(20); -var ReactBrowserEventEmitter = __webpack_require__(45); -var ReactInputSelection = __webpack_require__(102); -var ReactInstrumentation = __webpack_require__(13); -var Transaction = __webpack_require__(41); -var ReactUpdateQueue = __webpack_require__(63); +// DOM APIs, for completeness -/** - * Ensures that, when possible, the selection range (currently selected text - * input) is not disturbed by performing the transaction. - */ -var SELECTION_RESTORATION = { - /** - * @return {Selection} Selection information. - */ - initialize: ReactInputSelection.getSelectionInformation, - /** - * @param {Selection} sel Selection information returned from `initialize`. - */ - close: ReactInputSelection.restoreSelection +exports.setTimeout = function() { + return new Timeout(apply.call(setTimeout, window, arguments), clearTimeout); }; - -/** - * Suppresses events (blur/focus) that could be inadvertently dispatched due to - * high level DOM manipulations (like temporarily removing a text input from the - * DOM). - */ -var EVENT_SUPPRESSION = { - /** - * @return {boolean} The enabled status of `ReactBrowserEventEmitter` before - * the reconciliation. - */ - initialize: function () { - var currentlyEnabled = ReactBrowserEventEmitter.isEnabled(); - ReactBrowserEventEmitter.setEnabled(false); - return currentlyEnabled; - }, - - /** - * @param {boolean} previouslyEnabled Enabled status of - * `ReactBrowserEventEmitter` before the reconciliation occurred. `close` - * restores the previous value. - */ - close: function (previouslyEnabled) { - ReactBrowserEventEmitter.setEnabled(previouslyEnabled); - } +exports.setInterval = function() { + return new Timeout(apply.call(setInterval, window, arguments), clearInterval); }; - -/** - * Provides a queue for collecting `componentDidMount` and - * `componentDidUpdate` callbacks during the transaction. - */ -var ON_DOM_READY_QUEUEING = { - /** - * Initializes the internal `onDOMReady` queue. - */ - initialize: function () { - this.reactMountReady.reset(); - }, - - /** - * After DOM is flushed, invoke all registered `onDOMReady` callbacks. - */ - close: function () { - this.reactMountReady.notifyAll(); +exports.clearTimeout = +exports.clearInterval = function(timeout) { + if (timeout) { + timeout.close(); } }; -/** - * Executed within the scope of the `Transaction` instance. Consider these as - * being member methods, but with an implied ordering while being isolated from - * each other. - */ -var TRANSACTION_WRAPPERS = [SELECTION_RESTORATION, EVENT_SUPPRESSION, ON_DOM_READY_QUEUEING]; - -if (process.env.NODE_ENV !== 'production') { - TRANSACTION_WRAPPERS.push({ - initialize: ReactInstrumentation.debugTool.onBeginFlush, - close: ReactInstrumentation.debugTool.onEndFlush - }); -} - -/** - * Currently: - * - The order that these are listed in the transaction is critical: - * - Suppresses events. - * - Restores selection range. - * - * Future: - * - Restore document/overflow scroll positions that were unintentionally - * modified via DOM insertions above the top viewport boundary. - * - Implement/integrate with customized constraint based layout system and keep - * track of which dimensions must be remeasured. - * - * @class ReactReconcileTransaction - */ -function ReactReconcileTransaction(useCreateElement) { - this.reinitializeTransaction(); - // Only server-side rendering really needs this option (see - // `ReactServerRendering`), but server-side uses - // `ReactServerRenderingTransaction` instead. This option is here so that it's - // accessible and defaults to false when `ReactDOMComponent` and - // `ReactDOMTextComponent` checks it in `mountComponent`.` - this.renderToStaticMarkup = false; - this.reactMountReady = CallbackQueue.getPooled(null); - this.useCreateElement = useCreateElement; +function Timeout(id, clearFn) { + this._id = id; + this._clearFn = clearFn; } +Timeout.prototype.unref = Timeout.prototype.ref = function() {}; +Timeout.prototype.close = function() { + this._clearFn.call(window, this._id); +}; -var Mixin = { - /** - * @see Transaction - * @abstract - * @final - * @return {array<object>} List of operation wrap procedures. - * TODO: convert to array<TransactionWrapper> - */ - getTransactionWrappers: function () { - return TRANSACTION_WRAPPERS; - }, - - /** - * @return {object} The queue to collect `onDOMReady` callbacks with. - */ - getReactMountReady: function () { - return this.reactMountReady; - }, - - /** - * @return {object} The queue to collect React async events. - */ - getUpdateQueue: function () { - return ReactUpdateQueue; - }, +// Does not start the time, just sets up the members needed. +exports.enroll = function(item, msecs) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = msecs; +}; - /** - * Save current transaction state -- if the return value from this method is - * passed to `rollback`, the transaction will be reset to that state. - */ - checkpoint: function () { - // reactMountReady is the our only stateful wrapper - return this.reactMountReady.checkpoint(); - }, +exports.unenroll = function(item) { + clearTimeout(item._idleTimeoutId); + item._idleTimeout = -1; +}; - rollback: function (checkpoint) { - this.reactMountReady.rollback(checkpoint); - }, +exports._unrefActive = exports.active = function(item) { + clearTimeout(item._idleTimeoutId); - /** - * `PooledClass` looks for this, and will invoke this before allowing this - * instance to be reused. - */ - destructor: function () { - CallbackQueue.release(this.reactMountReady); - this.reactMountReady = null; + var msecs = item._idleTimeout; + if (msecs >= 0) { + item._idleTimeoutId = setTimeout(function onTimeout() { + if (item._onTimeout) + item._onTimeout(); + }, msecs); } }; -_assign(ReactReconcileTransaction.prototype, Transaction, Mixin); - -PooledClass.addPoolingTo(ReactReconcileTransaction); +// setimmediate attaches itself to the global object +__webpack_require__(369); +exports.setImmediate = setImmediate; +exports.clearImmediate = clearImmediate; -module.exports = ReactReconcileTransaction; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 193 */ +/* 165 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. +// a transform stream is a readable/writable stream where you do +// something with the data. Sometimes it's called a "filter", +// but that's not a great name for it, since that implies a thing where +// some bits pass through, and others are simply ignored. (That would +// be a valid example of a transform, of course.) +// +// While the output is causally related to the input, it's not a +// necessarily symmetric or synchronous transformation. For example, +// a zlib stream might take multiple plain-text writes(), and then +// emit a single compressed chunk some time in the future. +// +// Here's how this works: +// +// The Transform stream has all the aspects of the readable and writable +// stream classes. When you write(chunk), that calls _write(chunk,cb) +// internally, and returns false if there's a lot of pending writes +// buffered up. When you call read(), that calls _read(n) until +// there's enough pending readable data buffered up. +// +// In a transform stream, the written data is placed in a buffer. When +// _read(n) is called, it transforms the queued up data, calling the +// buffered _write cb's as it consumes chunks. If consuming a single +// written chunk would result in multiple output chunks, then the first +// outputted bit calls the readcb, and subsequent chunks just go into +// the read buffer, and will cause it to emit 'readable' if necessary. +// +// This way, back-pressure is actually determined by the reading side, +// since _read has to be called to start processing a new chunk. However, +// a pathological inflate type of transform can cause excessive buffering +// here. For example, imagine a stream where every byte of input is +// interpreted as an integer from 0-255, and then results in that many +// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in +// 1kb of data being output. In this case, you could write a very small +// amount of input, and end up with a very large amount of output. In +// such a pathological inflating mechanism, there'd be no way to tell +// the system to stop doing the transform. A single 4MB write could +// cause the system to run out of memory. +// +// However, even in such a pathological case, only a single written chunk +// would be consumed, and then the rest would wait (un-transformed) until +// the results of the previous transformed chunk were consumed. -var ExecutionEnvironment = __webpack_require__(8); -var getNodeForCharacterOffset = __webpack_require__(194); -var getTextContentAccessor = __webpack_require__(84); -/** - * While `isCollapsed` is available on the Selection object and `collapsed` - * is available on the Range object, IE11 sometimes gets them wrong. - * If the anchor/focus nodes and offsets are the same, the range is collapsed. - */ -function isCollapsed(anchorNode, anchorOffset, focusNode, focusOffset) { - return anchorNode === focusNode && anchorOffset === focusOffset; -} +module.exports = Transform; -/** - * Get the appropriate anchor and focus node/offset pairs for IE. - * - * The catch here is that IE's selection API doesn't provide information - * about whether the selection is forward or backward, so we have to - * behave as though it's always forward. - * - * IE text differs from modern selection in that it behaves as though - * block elements end with a new line. This means character offsets will - * differ between the two APIs. - * - * @param {DOMElement} node - * @return {object} - */ -function getIEOffsets(node) { - var selection = document.selection; - var selectedRange = selection.createRange(); - var selectedLength = selectedRange.text.length; +var Duplex = __webpack_require__(34); - // Duplicate selection so we can move range without breaking user selection. - var fromStart = selectedRange.duplicate(); - fromStart.moveToElementText(node); - fromStart.setEndPoint('EndToStart', selectedRange); +/*<replacement>*/ +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); +/*</replacement>*/ - var startOffset = fromStart.text.length; - var endOffset = startOffset + selectedLength; +util.inherits(Transform, Duplex); - return { - start: startOffset, - end: endOffset +function TransformState(stream) { + this.afterTransform = function (er, data) { + return afterTransform(stream, er, data); }; + + this.needTransform = false; + this.transforming = false; + this.writecb = null; + this.writechunk = null; + this.writeencoding = null; } -/** - * @param {DOMElement} node - * @return {?object} - */ -function getModernOffsets(node) { - var selection = window.getSelection && window.getSelection(); +function afterTransform(stream, er, data) { + var ts = stream._transformState; + ts.transforming = false; - if (!selection || selection.rangeCount === 0) { - return null; + var cb = ts.writecb; + + if (!cb) { + return stream.emit('error', new Error('write callback called multiple times')); } - var anchorNode = selection.anchorNode; - var anchorOffset = selection.anchorOffset; - var focusNode = selection.focusNode; - var focusOffset = selection.focusOffset; + ts.writechunk = null; + ts.writecb = null; - var currentRange = selection.getRangeAt(0); + if (data !== null && data !== undefined) stream.push(data); - // In Firefox, range.startContainer and range.endContainer can be "anonymous - // divs", e.g. the up/down buttons on an <input type="number">. Anonymous - // divs do not seem to expose properties, triggering a "Permission denied - // error" if any of its properties are accessed. The only seemingly possible - // way to avoid erroring is to access a property that typically works for - // non-anonymous divs and catch any error that may otherwise arise. See - // https://bugzilla.mozilla.org/show_bug.cgi?id=208427 - try { - /* eslint-disable no-unused-expressions */ - currentRange.startContainer.nodeType; - currentRange.endContainer.nodeType; - /* eslint-enable no-unused-expressions */ - } catch (e) { - return null; + cb(er); + + var rs = stream._readableState; + rs.reading = false; + if (rs.needReadable || rs.length < rs.highWaterMark) { + stream._read(rs.highWaterMark); } +} - // If the node and offset values are the same, the selection is collapsed. - // `Selection.isCollapsed` is available natively, but IE sometimes gets - // this value wrong. - var isSelectionCollapsed = isCollapsed(selection.anchorNode, selection.anchorOffset, selection.focusNode, selection.focusOffset); +function Transform(options) { + if (!(this instanceof Transform)) return new Transform(options); - var rangeLength = isSelectionCollapsed ? 0 : currentRange.toString().length; - - var tempRange = currentRange.cloneRange(); - tempRange.selectNodeContents(node); - tempRange.setEnd(currentRange.startContainer, currentRange.startOffset); + Duplex.call(this, options); - var isTempRangeCollapsed = isCollapsed(tempRange.startContainer, tempRange.startOffset, tempRange.endContainer, tempRange.endOffset); + this._transformState = new TransformState(this); - var start = isTempRangeCollapsed ? 0 : tempRange.toString().length; - var end = start + rangeLength; + var stream = this; - // Detect whether the selection is backward. - var detectionRange = document.createRange(); - detectionRange.setStart(anchorNode, anchorOffset); - detectionRange.setEnd(focusNode, focusOffset); - var isBackward = detectionRange.collapsed; + // start out asking for a readable event once data is transformed. + this._readableState.needReadable = true; - return { - start: isBackward ? end : start, - end: isBackward ? start : end - }; -} + // we have implemented the _read method, and done the other things + // that Readable wants before the first _read call, so unset the + // sync guard flag. + this._readableState.sync = false; -/** - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ -function setIEOffsets(node, offsets) { - var range = document.selection.createRange().duplicate(); - var start, end; + if (options) { + if (typeof options.transform === 'function') this._transform = options.transform; - if (offsets.end === undefined) { - start = offsets.start; - end = start; - } else if (offsets.start > offsets.end) { - start = offsets.end; - end = offsets.start; - } else { - start = offsets.start; - end = offsets.end; + if (typeof options.flush === 'function') this._flush = options.flush; } - range.moveToElementText(node); - range.moveStart('character', start); - range.setEndPoint('EndToStart', range); - range.moveEnd('character', end - start); - range.select(); + // When the writable side finishes, then flush out anything remaining. + this.once('prefinish', function () { + if (typeof this._flush === 'function') this._flush(function (er, data) { + done(stream, er, data); + });else done(stream); + }); } -/** - * In modern non-IE browsers, we can support both forward and backward - * selections. - * - * Note: IE10+ supports the Selection object, but it does not support - * the `extend` method, which means that even in modern IE, it's not possible - * to programmatically create a backward selection. Thus, for all IE - * versions, we use the old IE API to create our selections. - * - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ -function setModernOffsets(node, offsets) { - if (!window.getSelection) { - return; +Transform.prototype.push = function (chunk, encoding) { + this._transformState.needTransform = false; + return Duplex.prototype.push.call(this, chunk, encoding); +}; + +// This is the part where you do stuff! +// override this function in implementation classes. +// 'chunk' is an input chunk. +// +// Call `push(newChunk)` to pass along transformed output +// to the readable side. You may call 'push' zero or more times. +// +// Call `cb(err)` when you are done with this chunk. If you pass +// an error, then that'll put the hurt on the whole operation. If you +// never call cb(), then you'll never get another chunk. +Transform.prototype._transform = function (chunk, encoding, cb) { + throw new Error('_transform() is not implemented'); +}; + +Transform.prototype._write = function (chunk, encoding, cb) { + var ts = this._transformState; + ts.writecb = cb; + ts.writechunk = chunk; + ts.writeencoding = encoding; + if (!ts.transforming) { + var rs = this._readableState; + if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark) this._read(rs.highWaterMark); } +}; - var selection = window.getSelection(); - var length = node[getTextContentAccessor()].length; - var start = Math.min(offsets.start, length); - var end = offsets.end === undefined ? start : Math.min(offsets.end, length); +// Doesn't matter what the args are here. +// _transform does all the work. +// That we got here means that the readable side wants more data. +Transform.prototype._read = function (n) { + var ts = this._transformState; - // IE 11 uses modern selection, but doesn't support the extend method. - // Flip backward selections, so we can set with a single range. - if (!selection.extend && start > end) { - var temp = end; - end = start; - start = temp; + if (ts.writechunk !== null && ts.writecb && !ts.transforming) { + ts.transforming = true; + this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); + } else { + // mark that we need a transform, so that any data that comes in + // will get processed, now that we've asked for it. + ts.needTransform = true; } +}; - var startMarker = getNodeForCharacterOffset(node, start); - var endMarker = getNodeForCharacterOffset(node, end); +Transform.prototype._destroy = function (err, cb) { + var _this = this; - if (startMarker && endMarker) { - var range = document.createRange(); - range.setStart(startMarker.node, startMarker.offset); - selection.removeAllRanges(); + Duplex.prototype._destroy.call(this, err, function (err2) { + cb(err2); + _this.emit('close'); + }); +}; - if (start > end) { - selection.addRange(range); - selection.extend(endMarker.node, endMarker.offset); - } else { - range.setEnd(endMarker.node, endMarker.offset); - selection.addRange(range); - } - } -} +function done(stream, er, data) { + if (er) return stream.emit('error', er); -var useIEOffsets = ExecutionEnvironment.canUseDOM && 'selection' in document && !('getSelection' in window); + if (data !== null && data !== undefined) stream.push(data); -var ReactDOMSelection = { - /** - * @param {DOMElement} node - */ - getOffsets: useIEOffsets ? getIEOffsets : getModernOffsets, + // if there's nothing in the write buffer, then that means + // that nothing more will ever be provided + var ws = stream._writableState; + var ts = stream._transformState; - /** - * @param {DOMElement|DOMTextNode} node - * @param {object} offsets - */ - setOffsets: useIEOffsets ? setIEOffsets : setModernOffsets -}; + if (ws.length) throw new Error('Calling transform done when ws.length != 0'); -module.exports = ReactDOMSelection; + if (ts.transforming) throw new Error('Calling transform done when still transforming'); + + return stream.push(null); +} /***/ }), -/* 194 */ +/* 166 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. +/* WEBPACK VAR INJECTION */(function(Buffer) {/** + * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined + * in FIPS 180-2 + * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009. + * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet * */ +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) + +var K = [ + 0x428A2F98, 0x71374491, 0xB5C0FBCF, 0xE9B5DBA5, + 0x3956C25B, 0x59F111F1, 0x923F82A4, 0xAB1C5ED5, + 0xD807AA98, 0x12835B01, 0x243185BE, 0x550C7DC3, + 0x72BE5D74, 0x80DEB1FE, 0x9BDC06A7, 0xC19BF174, + 0xE49B69C1, 0xEFBE4786, 0x0FC19DC6, 0x240CA1CC, + 0x2DE92C6F, 0x4A7484AA, 0x5CB0A9DC, 0x76F988DA, + 0x983E5152, 0xA831C66D, 0xB00327C8, 0xBF597FC7, + 0xC6E00BF3, 0xD5A79147, 0x06CA6351, 0x14292967, + 0x27B70A85, 0x2E1B2138, 0x4D2C6DFC, 0x53380D13, + 0x650A7354, 0x766A0ABB, 0x81C2C92E, 0x92722C85, + 0xA2BFE8A1, 0xA81A664B, 0xC24B8B70, 0xC76C51A3, + 0xD192E819, 0xD6990624, 0xF40E3585, 0x106AA070, + 0x19A4C116, 0x1E376C08, 0x2748774C, 0x34B0BCB5, + 0x391C0CB3, 0x4ED8AA4A, 0x5B9CCA4F, 0x682E6FF3, + 0x748F82EE, 0x78A5636F, 0x84C87814, 0x8CC70208, + 0x90BEFFFA, 0xA4506CEB, 0xBEF9A3F7, 0xC67178F2 +] +var W = new Array(64) -/** - * Given any node return the first leaf node without children. - * - * @param {DOMElement|DOMTextNode} node - * @return {DOMElement|DOMTextNode} - */ +function Sha256 () { + this.init() -function getLeafNode(node) { - while (node && node.firstChild) { - node = node.firstChild; - } - return node; -} + this._w = W // new Array(64) -/** - * Get the next sibling within a container. This will walk up the - * DOM if a node's siblings have been exhausted. - * - * @param {DOMElement|DOMTextNode} node - * @return {?DOMElement|DOMTextNode} - */ -function getSiblingNode(node) { - while (node) { - if (node.nextSibling) { - return node.nextSibling; - } - node = node.parentNode; - } + Hash.call(this, 64, 56) } -/** - * Get object describing the nodes which contain characters at offset. - * - * @param {DOMElement|DOMTextNode} root - * @param {number} offset - * @return {?object} - */ -function getNodeForCharacterOffset(root, offset) { - var node = getLeafNode(root); - var nodeStart = 0; - var nodeEnd = 0; +inherits(Sha256, Hash) - while (node) { - if (node.nodeType === 3) { - nodeEnd = nodeStart + node.textContent.length; +Sha256.prototype.init = function () { + this._a = 0x6a09e667 + this._b = 0xbb67ae85 + this._c = 0x3c6ef372 + this._d = 0xa54ff53a + this._e = 0x510e527f + this._f = 0x9b05688c + this._g = 0x1f83d9ab + this._h = 0x5be0cd19 - if (nodeStart <= offset && nodeEnd >= offset) { - return { - node: node, - offset: offset - nodeStart - }; - } + return this +} - nodeStart = nodeEnd; - } +function ch (x, y, z) { + return z ^ (x & (y ^ z)) +} - node = getLeafNode(getSiblingNode(node)); - } +function maj (x, y, z) { + return (x & y) | (z & (x | y)) } -module.exports = getNodeForCharacterOffset; +function sigma0 (x) { + return (x >>> 2 | x << 30) ^ (x >>> 13 | x << 19) ^ (x >>> 22 | x << 10) +} -/***/ }), -/* 195 */ -/***/ (function(module, exports, __webpack_require__) { +function sigma1 (x) { + return (x >>> 6 | x << 26) ^ (x >>> 11 | x << 21) ^ (x >>> 25 | x << 7) +} -"use strict"; +function gamma0 (x) { + return (x >>> 7 | x << 25) ^ (x >>> 18 | x << 14) ^ (x >>> 3) +} +function gamma1 (x) { + return (x >>> 17 | x << 15) ^ (x >>> 19 | x << 13) ^ (x >>> 10) +} -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +Sha256.prototype._update = function (M) { + var W = this._w -var isTextNode = __webpack_require__(196); + var a = this._a | 0 + var b = this._b | 0 + var c = this._c | 0 + var d = this._d | 0 + var e = this._e | 0 + var f = this._f | 0 + var g = this._g | 0 + var h = this._h | 0 -/*eslint-disable no-bitwise */ + for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4) + for (; i < 64; ++i) W[i] = (gamma1(W[i - 2]) + W[i - 7] + gamma0(W[i - 15]) + W[i - 16]) | 0 -/** - * Checks if a given DOM node contains or is another DOM node. - */ -function containsNode(outerNode, innerNode) { - if (!outerNode || !innerNode) { - return false; - } else if (outerNode === innerNode) { - return true; - } else if (isTextNode(outerNode)) { - return false; - } else if (isTextNode(innerNode)) { - return containsNode(outerNode, innerNode.parentNode); - } else if ('contains' in outerNode) { - return outerNode.contains(innerNode); - } else if (outerNode.compareDocumentPosition) { - return !!(outerNode.compareDocumentPosition(innerNode) & 16); - } else { - return false; + for (var j = 0; j < 64; ++j) { + var T1 = (h + sigma1(e) + ch(e, f, g) + K[j] + W[j]) | 0 + var T2 = (sigma0(a) + maj(a, b, c)) | 0 + + h = g + g = f + f = e + e = (d + T1) | 0 + d = c + c = b + b = a + a = (T1 + T2) | 0 } + + this._a = (a + this._a) | 0 + this._b = (b + this._b) | 0 + this._c = (c + this._c) | 0 + this._d = (d + this._d) | 0 + this._e = (e + this._e) | 0 + this._f = (f + this._f) | 0 + this._g = (g + this._g) | 0 + this._h = (h + this._h) | 0 } -module.exports = containsNode; +Sha256.prototype._hash = function () { + var H = new Buffer(32) + + H.writeInt32BE(this._a, 0) + H.writeInt32BE(this._b, 4) + H.writeInt32BE(this._c, 8) + H.writeInt32BE(this._d, 12) + H.writeInt32BE(this._e, 16) + H.writeInt32BE(this._f, 20) + H.writeInt32BE(this._g, 24) + H.writeInt32BE(this._h, 28) + + return H +} + +module.exports = Sha256 + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 196 */ +/* 167 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) {var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) +var K = [ + 0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd, + 0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc, + 0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019, + 0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118, + 0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe, + 0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2, + 0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1, + 0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694, + 0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3, + 0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65, + 0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483, + 0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5, + 0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210, + 0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4, + 0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725, + 0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70, + 0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926, + 0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df, + 0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8, + 0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b, + 0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001, + 0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30, + 0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910, + 0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8, + 0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53, + 0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8, + 0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb, + 0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3, + 0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60, + 0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec, + 0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9, + 0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b, + 0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207, + 0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178, + 0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6, + 0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b, + 0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493, + 0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c, + 0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a, + 0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817 +] -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +var W = new Array(160) -var isNode = __webpack_require__(197); +function Sha512 () { + this.init() + this._w = W -/** - * @param {*} object The object to check. - * @return {boolean} Whether or not the object is a DOM text node. - */ -function isTextNode(object) { - return isNode(object) && object.nodeType == 3; + Hash.call(this, 128, 112) } -module.exports = isTextNode; +inherits(Sha512, Hash) -/***/ }), -/* 197 */ -/***/ (function(module, exports, __webpack_require__) { +Sha512.prototype.init = function () { + this._ah = 0x6a09e667 + this._bh = 0xbb67ae85 + this._ch = 0x3c6ef372 + this._dh = 0xa54ff53a + this._eh = 0x510e527f + this._fh = 0x9b05688c + this._gh = 0x1f83d9ab + this._hh = 0x5be0cd19 -"use strict"; + this._al = 0xf3bcc908 + this._bl = 0x84caa73b + this._cl = 0xfe94f82b + this._dl = 0x5f1d36f1 + this._el = 0xade682d1 + this._fl = 0x2b3e6c1f + this._gl = 0xfb41bd6b + this._hl = 0x137e2179 + return this +} -/** - * Copyright (c) 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * @typechecks - */ +function Ch (x, y, z) { + return z ^ (x & (y ^ z)) +} -/** - * @param {*} object The object to check. - * @return {boolean} Whether or not the object is a DOM node. - */ -function isNode(object) { - var doc = object ? object.ownerDocument || object : document; - var defaultView = doc.defaultView || window; - return !!(object && (typeof defaultView.Node === 'function' ? object instanceof defaultView.Node : typeof object === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string')); +function maj (x, y, z) { + return (x & y) | (z & (x | y)) } -module.exports = isNode; +function sigma0 (x, xl) { + return (x >>> 28 | xl << 4) ^ (xl >>> 2 | x << 30) ^ (xl >>> 7 | x << 25) +} -/***/ }), -/* 198 */ -/***/ (function(module, exports, __webpack_require__) { +function sigma1 (x, xl) { + return (x >>> 14 | xl << 18) ^ (x >>> 18 | xl << 14) ^ (xl >>> 9 | x << 23) +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function Gamma0 (x, xl) { + return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7) +} +function Gamma0l (x, xl) { + return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7 | xl << 25) +} +function Gamma1 (x, xl) { + return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6) +} -var NS = { - xlink: 'http://www.w3.org/1999/xlink', - xml: 'http://www.w3.org/XML/1998/namespace' -}; +function Gamma1l (x, xl) { + return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6 | xl << 26) +} -// We use attributes for everything SVG so let's avoid some duplication and run -// code instead. -// The following are all specified in the HTML config already so we exclude here. -// - class (as className) -// - color -// - height -// - id -// - lang -// - max -// - media -// - method -// - min -// - name -// - style -// - target -// - type -// - width -var ATTRS = { - accentHeight: 'accent-height', - accumulate: 0, - additive: 0, - alignmentBaseline: 'alignment-baseline', - allowReorder: 'allowReorder', - alphabetic: 0, - amplitude: 0, - arabicForm: 'arabic-form', - ascent: 0, - attributeName: 'attributeName', - attributeType: 'attributeType', - autoReverse: 'autoReverse', - azimuth: 0, - baseFrequency: 'baseFrequency', - baseProfile: 'baseProfile', - baselineShift: 'baseline-shift', - bbox: 0, - begin: 0, - bias: 0, - by: 0, - calcMode: 'calcMode', - capHeight: 'cap-height', - clip: 0, - clipPath: 'clip-path', - clipRule: 'clip-rule', - clipPathUnits: 'clipPathUnits', - colorInterpolation: 'color-interpolation', - colorInterpolationFilters: 'color-interpolation-filters', - colorProfile: 'color-profile', - colorRendering: 'color-rendering', - contentScriptType: 'contentScriptType', - contentStyleType: 'contentStyleType', - cursor: 0, - cx: 0, - cy: 0, - d: 0, - decelerate: 0, - descent: 0, - diffuseConstant: 'diffuseConstant', - direction: 0, - display: 0, - divisor: 0, - dominantBaseline: 'dominant-baseline', - dur: 0, - dx: 0, - dy: 0, - edgeMode: 'edgeMode', - elevation: 0, - enableBackground: 'enable-background', - end: 0, - exponent: 0, - externalResourcesRequired: 'externalResourcesRequired', - fill: 0, - fillOpacity: 'fill-opacity', - fillRule: 'fill-rule', - filter: 0, - filterRes: 'filterRes', - filterUnits: 'filterUnits', - floodColor: 'flood-color', - floodOpacity: 'flood-opacity', - focusable: 0, - fontFamily: 'font-family', - fontSize: 'font-size', - fontSizeAdjust: 'font-size-adjust', - fontStretch: 'font-stretch', - fontStyle: 'font-style', - fontVariant: 'font-variant', - fontWeight: 'font-weight', - format: 0, - from: 0, - fx: 0, - fy: 0, - g1: 0, - g2: 0, - glyphName: 'glyph-name', - glyphOrientationHorizontal: 'glyph-orientation-horizontal', - glyphOrientationVertical: 'glyph-orientation-vertical', - glyphRef: 'glyphRef', - gradientTransform: 'gradientTransform', - gradientUnits: 'gradientUnits', - hanging: 0, - horizAdvX: 'horiz-adv-x', - horizOriginX: 'horiz-origin-x', - ideographic: 0, - imageRendering: 'image-rendering', - 'in': 0, - in2: 0, - intercept: 0, - k: 0, - k1: 0, - k2: 0, - k3: 0, - k4: 0, - kernelMatrix: 'kernelMatrix', - kernelUnitLength: 'kernelUnitLength', - kerning: 0, - keyPoints: 'keyPoints', - keySplines: 'keySplines', - keyTimes: 'keyTimes', - lengthAdjust: 'lengthAdjust', - letterSpacing: 'letter-spacing', - lightingColor: 'lighting-color', - limitingConeAngle: 'limitingConeAngle', - local: 0, - markerEnd: 'marker-end', - markerMid: 'marker-mid', - markerStart: 'marker-start', - markerHeight: 'markerHeight', - markerUnits: 'markerUnits', - markerWidth: 'markerWidth', - mask: 0, - maskContentUnits: 'maskContentUnits', - maskUnits: 'maskUnits', - mathematical: 0, - mode: 0, - numOctaves: 'numOctaves', - offset: 0, - opacity: 0, - operator: 0, - order: 0, - orient: 0, - orientation: 0, - origin: 0, - overflow: 0, - overlinePosition: 'overline-position', - overlineThickness: 'overline-thickness', - paintOrder: 'paint-order', - panose1: 'panose-1', - pathLength: 'pathLength', - patternContentUnits: 'patternContentUnits', - patternTransform: 'patternTransform', - patternUnits: 'patternUnits', - pointerEvents: 'pointer-events', - points: 0, - pointsAtX: 'pointsAtX', - pointsAtY: 'pointsAtY', - pointsAtZ: 'pointsAtZ', - preserveAlpha: 'preserveAlpha', - preserveAspectRatio: 'preserveAspectRatio', - primitiveUnits: 'primitiveUnits', - r: 0, - radius: 0, - refX: 'refX', - refY: 'refY', - renderingIntent: 'rendering-intent', - repeatCount: 'repeatCount', - repeatDur: 'repeatDur', - requiredExtensions: 'requiredExtensions', - requiredFeatures: 'requiredFeatures', - restart: 0, - result: 0, - rotate: 0, - rx: 0, - ry: 0, - scale: 0, - seed: 0, - shapeRendering: 'shape-rendering', - slope: 0, - spacing: 0, - specularConstant: 'specularConstant', - specularExponent: 'specularExponent', - speed: 0, - spreadMethod: 'spreadMethod', - startOffset: 'startOffset', - stdDeviation: 'stdDeviation', - stemh: 0, - stemv: 0, - stitchTiles: 'stitchTiles', - stopColor: 'stop-color', - stopOpacity: 'stop-opacity', - strikethroughPosition: 'strikethrough-position', - strikethroughThickness: 'strikethrough-thickness', - string: 0, - stroke: 0, - strokeDasharray: 'stroke-dasharray', - strokeDashoffset: 'stroke-dashoffset', - strokeLinecap: 'stroke-linecap', - strokeLinejoin: 'stroke-linejoin', - strokeMiterlimit: 'stroke-miterlimit', - strokeOpacity: 'stroke-opacity', - strokeWidth: 'stroke-width', - surfaceScale: 'surfaceScale', - systemLanguage: 'systemLanguage', - tableValues: 'tableValues', - targetX: 'targetX', - targetY: 'targetY', - textAnchor: 'text-anchor', - textDecoration: 'text-decoration', - textRendering: 'text-rendering', - textLength: 'textLength', - to: 0, - transform: 0, - u1: 0, - u2: 0, - underlinePosition: 'underline-position', - underlineThickness: 'underline-thickness', - unicode: 0, - unicodeBidi: 'unicode-bidi', - unicodeRange: 'unicode-range', - unitsPerEm: 'units-per-em', - vAlphabetic: 'v-alphabetic', - vHanging: 'v-hanging', - vIdeographic: 'v-ideographic', - vMathematical: 'v-mathematical', - values: 0, - vectorEffect: 'vector-effect', - version: 0, - vertAdvY: 'vert-adv-y', - vertOriginX: 'vert-origin-x', - vertOriginY: 'vert-origin-y', - viewBox: 'viewBox', - viewTarget: 'viewTarget', - visibility: 0, - widths: 0, - wordSpacing: 'word-spacing', - writingMode: 'writing-mode', - x: 0, - xHeight: 'x-height', - x1: 0, - x2: 0, - xChannelSelector: 'xChannelSelector', - xlinkActuate: 'xlink:actuate', - xlinkArcrole: 'xlink:arcrole', - xlinkHref: 'xlink:href', - xlinkRole: 'xlink:role', - xlinkShow: 'xlink:show', - xlinkTitle: 'xlink:title', - xlinkType: 'xlink:type', - xmlBase: 'xml:base', - xmlns: 0, - xmlnsXlink: 'xmlns:xlink', - xmlLang: 'xml:lang', - xmlSpace: 'xml:space', - y: 0, - y1: 0, - y2: 0, - yChannelSelector: 'yChannelSelector', - z: 0, - zoomAndPan: 'zoomAndPan' -}; +function getCarry (a, b) { + return (a >>> 0) < (b >>> 0) ? 1 : 0 +} -var SVGDOMPropertyConfig = { - Properties: {}, - DOMAttributeNamespaces: { - xlinkActuate: NS.xlink, - xlinkArcrole: NS.xlink, - xlinkHref: NS.xlink, - xlinkRole: NS.xlink, - xlinkShow: NS.xlink, - xlinkTitle: NS.xlink, - xlinkType: NS.xlink, - xmlBase: NS.xml, - xmlLang: NS.xml, - xmlSpace: NS.xml - }, - DOMAttributeNames: {} -}; +Sha512.prototype._update = function (M) { + var W = this._w -Object.keys(ATTRS).forEach(function (key) { - SVGDOMPropertyConfig.Properties[key] = 0; - if (ATTRS[key]) { - SVGDOMPropertyConfig.DOMAttributeNames[key] = ATTRS[key]; + var ah = this._ah | 0 + var bh = this._bh | 0 + var ch = this._ch | 0 + var dh = this._dh | 0 + var eh = this._eh | 0 + var fh = this._fh | 0 + var gh = this._gh | 0 + var hh = this._hh | 0 + + var al = this._al | 0 + var bl = this._bl | 0 + var cl = this._cl | 0 + var dl = this._dl | 0 + var el = this._el | 0 + var fl = this._fl | 0 + var gl = this._gl | 0 + var hl = this._hl | 0 + + for (var i = 0; i < 32; i += 2) { + W[i] = M.readInt32BE(i * 4) + W[i + 1] = M.readInt32BE(i * 4 + 4) } -}); + for (; i < 160; i += 2) { + var xh = W[i - 15 * 2] + var xl = W[i - 15 * 2 + 1] + var gamma0 = Gamma0(xh, xl) + var gamma0l = Gamma0l(xl, xh) -module.exports = SVGDOMPropertyConfig; + xh = W[i - 2 * 2] + xl = W[i - 2 * 2 + 1] + var gamma1 = Gamma1(xh, xl) + var gamma1l = Gamma1l(xl, xh) -/***/ }), -/* 199 */ -/***/ (function(module, exports, __webpack_require__) { + // W[i] = gamma0 + W[i - 7] + gamma1 + W[i - 16] + var Wi7h = W[i - 7 * 2] + var Wi7l = W[i - 7 * 2 + 1] -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var Wi16h = W[i - 16 * 2] + var Wi16l = W[i - 16 * 2 + 1] + var Wil = (gamma0l + Wi7l) | 0 + var Wih = (gamma0 + Wi7h + getCarry(Wil, gamma0l)) | 0 + Wil = (Wil + gamma1l) | 0 + Wih = (Wih + gamma1 + getCarry(Wil, gamma1l)) | 0 + Wil = (Wil + Wi16l) | 0 + Wih = (Wih + Wi16h + getCarry(Wil, Wi16l)) | 0 + W[i] = Wih + W[i + 1] = Wil + } -var EventPropagators = __webpack_require__(31); -var ExecutionEnvironment = __webpack_require__(8); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInputSelection = __webpack_require__(102); -var SyntheticEvent = __webpack_require__(16); + for (var j = 0; j < 160; j += 2) { + Wih = W[j] + Wil = W[j + 1] -var getActiveElement = __webpack_require__(103); -var isTextInputElement = __webpack_require__(88); -var shallowEqual = __webpack_require__(60); + var majh = maj(ah, bh, ch) + var majl = maj(al, bl, cl) -var skipSelectionChangeEvent = ExecutionEnvironment.canUseDOM && 'documentMode' in document && document.documentMode <= 11; + var sigma0h = sigma0(ah, al) + var sigma0l = sigma0(al, ah) + var sigma1h = sigma1(eh, el) + var sigma1l = sigma1(el, eh) -var eventTypes = { - select: { - phasedRegistrationNames: { - bubbled: 'onSelect', - captured: 'onSelectCapture' - }, - dependencies: ['topBlur', 'topContextMenu', 'topFocus', 'topKeyDown', 'topKeyUp', 'topMouseDown', 'topMouseUp', 'topSelectionChange'] - } -}; + // t1 = h + sigma1 + ch + K[j] + W[j] + var Kih = K[j] + var Kil = K[j + 1] -var activeElement = null; -var activeElementInst = null; -var lastSelection = null; -var mouseDown = false; + var chh = Ch(eh, fh, gh) + var chl = Ch(el, fl, gl) -// Track whether a listener exists for this plugin. If none exist, we do -// not extract events. See #3639. -var hasListener = false; + var t1l = (hl + sigma1l) | 0 + var t1h = (hh + sigma1h + getCarry(t1l, hl)) | 0 + t1l = (t1l + chl) | 0 + t1h = (t1h + chh + getCarry(t1l, chl)) | 0 + t1l = (t1l + Kil) | 0 + t1h = (t1h + Kih + getCarry(t1l, Kil)) | 0 + t1l = (t1l + Wil) | 0 + t1h = (t1h + Wih + getCarry(t1l, Wil)) | 0 -/** - * Get an object which is a unique representation of the current selection. - * - * The return value will not be consistent across nodes or browsers, but - * two identical selections on the same node will return identical objects. - * - * @param {DOMElement} node - * @return {object} - */ -function getSelection(node) { - if ('selectionStart' in node && ReactInputSelection.hasSelectionCapabilities(node)) { - return { - start: node.selectionStart, - end: node.selectionEnd - }; - } else if (window.getSelection) { - var selection = window.getSelection(); - return { - anchorNode: selection.anchorNode, - anchorOffset: selection.anchorOffset, - focusNode: selection.focusNode, - focusOffset: selection.focusOffset - }; - } else if (document.selection) { - var range = document.selection.createRange(); - return { - parentElement: range.parentElement(), - text: range.text, - top: range.boundingTop, - left: range.boundingLeft - }; + // t2 = sigma0 + maj + var t2l = (sigma0l + majl) | 0 + var t2h = (sigma0h + majh + getCarry(t2l, sigma0l)) | 0 + + hh = gh + hl = gl + gh = fh + gl = fl + fh = eh + fl = el + el = (dl + t1l) | 0 + eh = (dh + t1h + getCarry(el, dl)) | 0 + dh = ch + dl = cl + ch = bh + cl = bl + bh = ah + bl = al + al = (t1l + t2l) | 0 + ah = (t1h + t2h + getCarry(al, t1l)) | 0 } + + this._al = (this._al + al) | 0 + this._bl = (this._bl + bl) | 0 + this._cl = (this._cl + cl) | 0 + this._dl = (this._dl + dl) | 0 + this._el = (this._el + el) | 0 + this._fl = (this._fl + fl) | 0 + this._gl = (this._gl + gl) | 0 + this._hl = (this._hl + hl) | 0 + + this._ah = (this._ah + ah + getCarry(this._al, al)) | 0 + this._bh = (this._bh + bh + getCarry(this._bl, bl)) | 0 + this._ch = (this._ch + ch + getCarry(this._cl, cl)) | 0 + this._dh = (this._dh + dh + getCarry(this._dl, dl)) | 0 + this._eh = (this._eh + eh + getCarry(this._el, el)) | 0 + this._fh = (this._fh + fh + getCarry(this._fl, fl)) | 0 + this._gh = (this._gh + gh + getCarry(this._gl, gl)) | 0 + this._hh = (this._hh + hh + getCarry(this._hl, hl)) | 0 } -/** - * Poll selection to see whether it's changed. - * - * @param {object} nativeEvent - * @return {?SyntheticEvent} - */ -function constructSelectEvent(nativeEvent, nativeEventTarget) { - // Ensure we have the right element, and that the user is not dragging a - // selection (this matches native `select` event behavior). In HTML5, select - // fires only on input and textarea thus if there's no focused element we - // won't dispatch. - if (mouseDown || activeElement == null || activeElement !== getActiveElement()) { - return null; +Sha512.prototype._hash = function () { + var H = new Buffer(64) + + function writeInt64BE (h, l, offset) { + H.writeInt32BE(h, offset) + H.writeInt32BE(l, offset + 4) } - // Only fire when selection has actually changed. - var currentSelection = getSelection(activeElement); - if (!lastSelection || !shallowEqual(lastSelection, currentSelection)) { - lastSelection = currentSelection; + writeInt64BE(this._ah, this._al, 0) + writeInt64BE(this._bh, this._bl, 8) + writeInt64BE(this._ch, this._cl, 16) + writeInt64BE(this._dh, this._dl, 24) + writeInt64BE(this._eh, this._el, 32) + writeInt64BE(this._fh, this._fl, 40) + writeInt64BE(this._gh, this._gl, 48) + writeInt64BE(this._hh, this._hl, 56) - var syntheticEvent = SyntheticEvent.getPooled(eventTypes.select, activeElementInst, nativeEvent, nativeEventTarget); + return H +} - syntheticEvent.type = 'select'; - syntheticEvent.target = activeElement; +module.exports = Sha512 - EventPropagators.accumulateTwoPhaseDispatches(syntheticEvent); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - return syntheticEvent; - } +/***/ }), +/* 168 */ +/***/ (function(module, exports, __webpack_require__) { - return null; -} +"use strict"; -/** - * This plugin creates an `onSelect` event that normalizes select events - * across form elements. - * - * Supported elements are: - * - input (see `isTextInputElement`) - * - textarea - * - contentEditable - * - * This differs from native browser implementations in the following ways: - * - Fires on contentEditable fields as well as inputs. - * - Fires for collapsed selection. - * - Fires after user input. - */ -var SelectEventPlugin = { - eventTypes: eventTypes, - - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - if (!hasListener) { - return null; - } - - var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; +module.exports = __webpack_require__(380)(__webpack_require__(383)) - switch (topLevelType) { - // Track the input node that has focus. - case 'topFocus': - if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') { - activeElement = targetNode; - activeElementInst = targetInst; - lastSelection = null; - } - break; - case 'topBlur': - activeElement = null; - activeElementInst = null; - lastSelection = null; - break; - // Don't fire the event while the user is dragging. This matches the - // semantics of the native select event. - case 'topMouseDown': - mouseDown = true; - break; - case 'topContextMenu': - case 'topMouseUp': - mouseDown = false; - return constructSelectEvent(nativeEvent, nativeEventTarget); - // Chrome and IE fire non-standard event when selection is changed (and - // sometimes when it hasn't). IE's event fires out of order with respect - // to key and input events on deletion, so we discard it. - // - // Firefox doesn't support selectionchange, so check selection status - // after each key entry. The selection changes after keydown and before - // keyup, but we check on keydown as well in the case of holding down a - // key, when multiple keydown events are fired but only one keyup is. - // This is also our approach for IE handling, for the reason above. - case 'topSelectionChange': - if (skipSelectionChangeEvent) { - break; - } - // falls through - case 'topKeyDown': - case 'topKeyUp': - return constructSelectEvent(nativeEvent, nativeEventTarget); - } - return null; - }, +/***/ }), +/* 169 */ +/***/ (function(module, exports) { - didPutListener: function (inst, registrationName, listener) { - if (registrationName === 'onSelect') { - hasListener = true; - } - } +module.exports = { + "COMPRESSED_TYPE_INVALID": "compressed should be a boolean", + "EC_PRIVATE_KEY_TYPE_INVALID": "private key should be a Buffer", + "EC_PRIVATE_KEY_LENGTH_INVALID": "private key length is invalid", + "EC_PRIVATE_KEY_TWEAK_ADD_FAIL": "tweak out of range or resulting private key is invalid", + "EC_PRIVATE_KEY_TWEAK_MUL_FAIL": "tweak out of range", + "EC_PRIVATE_KEY_EXPORT_DER_FAIL": "couldn't export to DER format", + "EC_PRIVATE_KEY_IMPORT_DER_FAIL": "couldn't import from DER format", + "EC_PUBLIC_KEYS_TYPE_INVALID": "public keys should be an Array", + "EC_PUBLIC_KEYS_LENGTH_INVALID": "public keys Array should have at least 1 element", + "EC_PUBLIC_KEY_TYPE_INVALID": "public key should be a Buffer", + "EC_PUBLIC_KEY_LENGTH_INVALID": "public key length is invalid", + "EC_PUBLIC_KEY_PARSE_FAIL": "the public key could not be parsed or is invalid", + "EC_PUBLIC_KEY_CREATE_FAIL": "private was invalid, try again", + "EC_PUBLIC_KEY_TWEAK_ADD_FAIL": "tweak out of range or resulting public key is invalid", + "EC_PUBLIC_KEY_TWEAK_MUL_FAIL": "tweak out of range", + "EC_PUBLIC_KEY_COMBINE_FAIL": "the sum of the public keys is not valid", + "ECDH_FAIL": "scalar was invalid (zero or overflow)", + "ECDSA_SIGNATURE_TYPE_INVALID": "signature should be a Buffer", + "ECDSA_SIGNATURE_LENGTH_INVALID": "signature length is invalid", + "ECDSA_SIGNATURE_PARSE_FAIL": "couldn't parse signature", + "ECDSA_SIGNATURE_PARSE_DER_FAIL": "couldn't parse DER signature", + "ECDSA_SIGNATURE_SERIALIZE_DER_FAIL": "couldn't serialize signature to DER format", + "ECDSA_SIGN_FAIL": "nonce generation function failed or private key is invalid", + "ECDSA_RECOVER_FAIL": "couldn't recover public key from signature", + "MSG32_TYPE_INVALID": "message should be a Buffer", + "MSG32_LENGTH_INVALID": "message length is invalid", + "OPTIONS_TYPE_INVALID": "options should be an Object", + "OPTIONS_DATA_TYPE_INVALID": "options.data should be a Buffer", + "OPTIONS_DATA_LENGTH_INVALID": "options.data length is invalid", + "OPTIONS_NONCEFN_TYPE_INVALID": "options.noncefn should be a Function", + "RECOVERY_ID_TYPE_INVALID": "recovery should be a Number", + "RECOVERY_ID_VALUE_INVALID": "recovery should have value between -1 and 4", + "TWEAK_TYPE_INVALID": "tweak should be a Buffer", + "TWEAK_LENGTH_INVALID": "tweak length is invalid" }; -module.exports = SelectEventPlugin; - /***/ }), -/* 200 */ +/* 170 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ +var utils = exports; + +function toArray(msg, enc) { + if (Array.isArray(msg)) + return msg.slice(); + if (!msg) + return []; + var res = []; + if (typeof msg !== 'string') { + for (var i = 0; i < msg.length; i++) + res[i] = msg[i] | 0; + return res; + } + if (enc === 'hex') { + msg = msg.replace(/[^a-z0-9]+/ig, ''); + if (msg.length % 2 !== 0) + msg = '0' + msg; + for (var i = 0; i < msg.length; i += 2) + res.push(parseInt(msg[i] + msg[i + 1], 16)); + } else { + for (var i = 0; i < msg.length; i++) { + var c = msg.charCodeAt(i); + var hi = c >> 8; + var lo = c & 0xff; + if (hi) + res.push(hi, lo); + else + res.push(lo); + } + } + return res; +} +utils.toArray = toArray; + +function zero2(word) { + if (word.length === 1) + return '0' + word; + else + return word; +} +utils.zero2 = zero2; -var _prodInvariant = __webpack_require__(3); +function toHex(msg) { + var res = ''; + for (var i = 0; i < msg.length; i++) + res += zero2(msg[i].toString(16)); + return res; +} +utils.toHex = toHex; -var EventListener = __webpack_require__(101); -var EventPropagators = __webpack_require__(31); -var ReactDOMComponentTree = __webpack_require__(6); -var SyntheticAnimationEvent = __webpack_require__(201); -var SyntheticClipboardEvent = __webpack_require__(202); -var SyntheticEvent = __webpack_require__(16); -var SyntheticFocusEvent = __webpack_require__(203); -var SyntheticKeyboardEvent = __webpack_require__(204); -var SyntheticMouseEvent = __webpack_require__(42); -var SyntheticDragEvent = __webpack_require__(206); -var SyntheticTouchEvent = __webpack_require__(207); -var SyntheticTransitionEvent = __webpack_require__(208); -var SyntheticUIEvent = __webpack_require__(33); -var SyntheticWheelEvent = __webpack_require__(209); +utils.encode = function encode(arr, enc) { + if (enc === 'hex') + return toHex(arr); + else + return arr; +}; -var emptyFunction = __webpack_require__(12); -var getEventCharCode = __webpack_require__(65); -var invariant = __webpack_require__(1); -/** - * Turns - * ['abort', ...] - * into - * eventTypes = { - * 'abort': { - * phasedRegistrationNames: { - * bubbled: 'onAbort', - * captured: 'onAbortCapture', - * }, - * dependencies: ['topAbort'], - * }, - * ... - * }; - * topLevelEventsToDispatchConfig = { - * 'topAbort': { sameConfig } - * }; - */ -var eventTypes = {}; -var topLevelEventsToDispatchConfig = {}; -['abort', 'animationEnd', 'animationIteration', 'animationStart', 'blur', 'canPlay', 'canPlayThrough', 'click', 'contextMenu', 'copy', 'cut', 'doubleClick', 'drag', 'dragEnd', 'dragEnter', 'dragExit', 'dragLeave', 'dragOver', 'dragStart', 'drop', 'durationChange', 'emptied', 'encrypted', 'ended', 'error', 'focus', 'input', 'invalid', 'keyDown', 'keyPress', 'keyUp', 'load', 'loadedData', 'loadedMetadata', 'loadStart', 'mouseDown', 'mouseMove', 'mouseOut', 'mouseOver', 'mouseUp', 'paste', 'pause', 'play', 'playing', 'progress', 'rateChange', 'reset', 'scroll', 'seeked', 'seeking', 'stalled', 'submit', 'suspend', 'timeUpdate', 'touchCancel', 'touchEnd', 'touchMove', 'touchStart', 'transitionEnd', 'volumeChange', 'waiting', 'wheel'].forEach(function (event) { - var capitalizedEvent = event[0].toUpperCase() + event.slice(1); - var onEvent = 'on' + capitalizedEvent; - var topEvent = 'top' + capitalizedEvent; +/***/ }), +/* 171 */ +/***/ (function(module, exports, __webpack_require__) { - var type = { - phasedRegistrationNames: { - bubbled: onEvent, - captured: onEvent + 'Capture' - }, - dependencies: [topEvent] - }; - eventTypes[event] = type; - topLevelEventsToDispatchConfig[topEvent] = type; -}); +var r; -var onClickListeners = {}; +module.exports = function rand(len) { + if (!r) + r = new Rand(null); -function getDictionaryKey(inst) { - // Prevents V8 performance issue: - // https://github.com/facebook/react/pull/7232 - return '.' + inst._rootNodeID; -} + return r.generate(len); +}; -function isInteractive(tag) { - return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; +function Rand(rand) { + this.rand = rand; } +module.exports.Rand = Rand; -var SimpleEventPlugin = { - eventTypes: eventTypes, +Rand.prototype.generate = function generate(len) { + return this._rand(len); +}; - extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { - var dispatchConfig = topLevelEventsToDispatchConfig[topLevelType]; - if (!dispatchConfig) { - return null; - } - var EventConstructor; - switch (topLevelType) { - case 'topAbort': - case 'topCanPlay': - case 'topCanPlayThrough': - case 'topDurationChange': - case 'topEmptied': - case 'topEncrypted': - case 'topEnded': - case 'topError': - case 'topInput': - case 'topInvalid': - case 'topLoad': - case 'topLoadedData': - case 'topLoadedMetadata': - case 'topLoadStart': - case 'topPause': - case 'topPlay': - case 'topPlaying': - case 'topProgress': - case 'topRateChange': - case 'topReset': - case 'topSeeked': - case 'topSeeking': - case 'topStalled': - case 'topSubmit': - case 'topSuspend': - case 'topTimeUpdate': - case 'topVolumeChange': - case 'topWaiting': - // HTML Events - // @see http://www.w3.org/TR/html5/index.html#events-0 - EventConstructor = SyntheticEvent; - break; - case 'topKeyPress': - // Firefox creates a keypress event for function keys too. This removes - // the unwanted keypress events. Enter is however both printable and - // non-printable. One would expect Tab to be as well (but it isn't). - if (getEventCharCode(nativeEvent) === 0) { - return null; - } - /* falls through */ - case 'topKeyDown': - case 'topKeyUp': - EventConstructor = SyntheticKeyboardEvent; - break; - case 'topBlur': - case 'topFocus': - EventConstructor = SyntheticFocusEvent; - break; - case 'topClick': - // Firefox creates a click event on right mouse clicks. This removes the - // unwanted click events. - if (nativeEvent.button === 2) { - return null; - } - /* falls through */ - case 'topDoubleClick': - case 'topMouseDown': - case 'topMouseMove': - case 'topMouseUp': - // TODO: Disabled elements should not respond to mouse events - /* falls through */ - case 'topMouseOut': - case 'topMouseOver': - case 'topContextMenu': - EventConstructor = SyntheticMouseEvent; - break; - case 'topDrag': - case 'topDragEnd': - case 'topDragEnter': - case 'topDragExit': - case 'topDragLeave': - case 'topDragOver': - case 'topDragStart': - case 'topDrop': - EventConstructor = SyntheticDragEvent; - break; - case 'topTouchCancel': - case 'topTouchEnd': - case 'topTouchMove': - case 'topTouchStart': - EventConstructor = SyntheticTouchEvent; - break; - case 'topAnimationEnd': - case 'topAnimationIteration': - case 'topAnimationStart': - EventConstructor = SyntheticAnimationEvent; - break; - case 'topTransitionEnd': - EventConstructor = SyntheticTransitionEvent; - break; - case 'topScroll': - EventConstructor = SyntheticUIEvent; - break; - case 'topWheel': - EventConstructor = SyntheticWheelEvent; - break; - case 'topCopy': - case 'topCut': - case 'topPaste': - EventConstructor = SyntheticClipboardEvent; - break; - } - !EventConstructor ? process.env.NODE_ENV !== 'production' ? invariant(false, 'SimpleEventPlugin: Unhandled event type, `%s`.', topLevelType) : _prodInvariant('86', topLevelType) : void 0; - var event = EventConstructor.getPooled(dispatchConfig, targetInst, nativeEvent, nativeEventTarget); - EventPropagators.accumulateTwoPhaseDispatches(event); - return event; - }, +// Emulate crypto API using randy +Rand.prototype._rand = function _rand(n) { + if (this.rand.getBytes) + return this.rand.getBytes(n); - didPutListener: function (inst, registrationName, listener) { - // Mobile Safari does not fire properly bubble click events on - // non-interactive elements, which means delegated click listeners do not - // fire. The workaround for this bug involves attaching an empty click - // listener on the target node. - // http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html - if (registrationName === 'onClick' && !isInteractive(inst._tag)) { - var key = getDictionaryKey(inst); - var node = ReactDOMComponentTree.getNodeFromInstance(inst); - if (!onClickListeners[key]) { - onClickListeners[key] = EventListener.listen(node, 'click', emptyFunction); - } - } - }, + var res = new Uint8Array(n); + for (var i = 0; i < res.length; i++) + res[i] = this.rand.getByte(); + return res; +}; - willDeleteListener: function (inst, registrationName) { - if (registrationName === 'onClick' && !isInteractive(inst._tag)) { - var key = getDictionaryKey(inst); - onClickListeners[key].remove(); - delete onClickListeners[key]; - } +if (typeof self === 'object') { + if (self.crypto && self.crypto.getRandomValues) { + // Modern browsers + Rand.prototype._rand = function _rand(n) { + var arr = new Uint8Array(n); + self.crypto.getRandomValues(arr); + return arr; + }; + } else if (self.msCrypto && self.msCrypto.getRandomValues) { + // IE + Rand.prototype._rand = function _rand(n) { + var arr = new Uint8Array(n); + self.msCrypto.getRandomValues(arr); + return arr; + }; + + // Safari's WebWorkers do not have `crypto` + } else if (typeof window === 'object') { + // Old junk + Rand.prototype._rand = function() { + throw new Error('Not implemented yet'); + }; } -}; +} else { + // Node.js or Web worker with no crypto support + try { + var crypto = __webpack_require__(387); + if (typeof crypto.randomBytes !== 'function') + throw new Error('Not supported'); + + Rand.prototype._rand = function _rand(n) { + return crypto.randomBytes(n); + }; + } catch (e) { + } +} -module.exports = SimpleEventPlugin; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 201 */ +/* 172 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var utils = __webpack_require__(25); +var rotr32 = utils.rotr32; -var SyntheticEvent = __webpack_require__(16); +function ft_1(s, x, y, z) { + if (s === 0) + return ch32(x, y, z); + if (s === 1 || s === 3) + return p32(x, y, z); + if (s === 2) + return maj32(x, y, z); +} +exports.ft_1 = ft_1; -/** - * @interface Event - * @see http://www.w3.org/TR/css3-animations/#AnimationEvent-interface - * @see https://developer.mozilla.org/en-US/docs/Web/API/AnimationEvent - */ -var AnimationEventInterface = { - animationName: null, - elapsedTime: null, - pseudoElement: null -}; +function ch32(x, y, z) { + return (x & y) ^ ((~x) & z); +} +exports.ch32 = ch32; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticAnimationEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +function maj32(x, y, z) { + return (x & y) ^ (x & z) ^ (y & z); } +exports.maj32 = maj32; -SyntheticEvent.augmentClass(SyntheticAnimationEvent, AnimationEventInterface); +function p32(x, y, z) { + return x ^ y ^ z; +} +exports.p32 = p32; + +function s0_256(x) { + return rotr32(x, 2) ^ rotr32(x, 13) ^ rotr32(x, 22); +} +exports.s0_256 = s0_256; + +function s1_256(x) { + return rotr32(x, 6) ^ rotr32(x, 11) ^ rotr32(x, 25); +} +exports.s1_256 = s1_256; + +function g0_256(x) { + return rotr32(x, 7) ^ rotr32(x, 18) ^ (x >>> 3); +} +exports.g0_256 = g0_256; + +function g1_256(x) { + return rotr32(x, 17) ^ rotr32(x, 19) ^ (x >>> 10); +} +exports.g1_256 = g1_256; -module.exports = SyntheticAnimationEvent; /***/ }), -/* 202 */ +/* 173 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var shaCommon = __webpack_require__(172); +var assert = __webpack_require__(21); -var SyntheticEvent = __webpack_require__(16); +var sum32 = utils.sum32; +var sum32_4 = utils.sum32_4; +var sum32_5 = utils.sum32_5; +var ch32 = shaCommon.ch32; +var maj32 = shaCommon.maj32; +var s0_256 = shaCommon.s0_256; +var s1_256 = shaCommon.s1_256; +var g0_256 = shaCommon.g0_256; +var g1_256 = shaCommon.g1_256; -/** - * @interface Event - * @see http://www.w3.org/TR/clipboard-apis/ - */ -var ClipboardEventInterface = { - clipboardData: function (event) { - return 'clipboardData' in event ? event.clipboardData : window.clipboardData; - } -}; +var BlockHash = common.BlockHash; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticClipboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} +var sha256_K = [ + 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, + 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5, + 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, + 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174, + 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, + 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da, + 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, + 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967, + 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, + 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85, + 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, + 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070, + 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, + 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3, + 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, + 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2 +]; -SyntheticEvent.augmentClass(SyntheticClipboardEvent, ClipboardEventInterface); +function SHA256() { + if (!(this instanceof SHA256)) + return new SHA256(); -module.exports = SyntheticClipboardEvent; + BlockHash.call(this); + this.h = [ + 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, + 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19 + ]; + this.k = sha256_K; + this.W = new Array(64); +} +utils.inherits(SHA256, BlockHash); +module.exports = SHA256; -/***/ }), -/* 203 */ -/***/ (function(module, exports, __webpack_require__) { +SHA256.blockSize = 512; +SHA256.outSize = 256; +SHA256.hmacStrength = 192; +SHA256.padLength = 64; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +SHA256.prototype._update = function _update(msg, start) { + var W = this.W; + for (var i = 0; i < 16; i++) + W[i] = msg[start + i]; + for (; i < W.length; i++) + W[i] = sum32_4(g1_256(W[i - 2]), W[i - 7], g0_256(W[i - 15]), W[i - 16]); + var a = this.h[0]; + var b = this.h[1]; + var c = this.h[2]; + var d = this.h[3]; + var e = this.h[4]; + var f = this.h[5]; + var g = this.h[6]; + var h = this.h[7]; -var SyntheticUIEvent = __webpack_require__(33); + assert(this.k.length === W.length); + for (i = 0; i < W.length; i++) { + var T1 = sum32_5(h, s1_256(e), ch32(e, f, g), this.k[i], W[i]); + var T2 = sum32(s0_256(a), maj32(a, b, c)); + h = g; + g = f; + f = e; + e = sum32(d, T1); + d = c; + c = b; + b = a; + a = sum32(T1, T2); + } -/** - * @interface FocusEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var FocusEventInterface = { - relatedTarget: null + this.h[0] = sum32(this.h[0], a); + this.h[1] = sum32(this.h[1], b); + this.h[2] = sum32(this.h[2], c); + this.h[3] = sum32(this.h[3], d); + this.h[4] = sum32(this.h[4], e); + this.h[5] = sum32(this.h[5], f); + this.h[6] = sum32(this.h[6], g); + this.h[7] = sum32(this.h[7], h); }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticFocusEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} - -SyntheticUIEvent.augmentClass(SyntheticFocusEvent, FocusEventInterface); +SHA256.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'big'); + else + return utils.split32(this.h, 'big'); +}; -module.exports = SyntheticFocusEvent; /***/ }), -/* 204 */ +/* 174 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - -var SyntheticUIEvent = __webpack_require__(33); +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var assert = __webpack_require__(21); -var getEventCharCode = __webpack_require__(65); -var getEventKey = __webpack_require__(205); -var getEventModifierState = __webpack_require__(54); +var rotr64_hi = utils.rotr64_hi; +var rotr64_lo = utils.rotr64_lo; +var shr64_hi = utils.shr64_hi; +var shr64_lo = utils.shr64_lo; +var sum64 = utils.sum64; +var sum64_hi = utils.sum64_hi; +var sum64_lo = utils.sum64_lo; +var sum64_4_hi = utils.sum64_4_hi; +var sum64_4_lo = utils.sum64_4_lo; +var sum64_5_hi = utils.sum64_5_hi; +var sum64_5_lo = utils.sum64_5_lo; -/** - * @interface KeyboardEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var KeyboardEventInterface = { - key: getEventKey, - location: null, - ctrlKey: null, - shiftKey: null, - altKey: null, - metaKey: null, - repeat: null, - locale: null, - getModifierState: getEventModifierState, - // Legacy Interface - charCode: function (event) { - // `charCode` is the result of a KeyPress event and represents the value of - // the actual printable character. +var BlockHash = common.BlockHash; - // KeyPress is deprecated, but its replacement is not yet final and not - // implemented in any major browser. Only KeyPress has charCode. - if (event.type === 'keypress') { - return getEventCharCode(event); - } - return 0; - }, - keyCode: function (event) { - // `keyCode` is the result of a KeyDown/Up event and represents the value of - // physical keyboard key. +var sha512_K = [ + 0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd, + 0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc, + 0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019, + 0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118, + 0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe, + 0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2, + 0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1, + 0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694, + 0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3, + 0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65, + 0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483, + 0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5, + 0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210, + 0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4, + 0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725, + 0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70, + 0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926, + 0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df, + 0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8, + 0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b, + 0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001, + 0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30, + 0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910, + 0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8, + 0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53, + 0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8, + 0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb, + 0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3, + 0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60, + 0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec, + 0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9, + 0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b, + 0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207, + 0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178, + 0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6, + 0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b, + 0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493, + 0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c, + 0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a, + 0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817 +]; - // The actual meaning of the value depends on the users' keyboard layout - // which cannot be detected. Assuming that it is a US keyboard layout - // provides a surprisingly accurate mapping for US and European users. - // Due to this, it is left to the user to implement at this time. - if (event.type === 'keydown' || event.type === 'keyup') { - return event.keyCode; - } - return 0; - }, - which: function (event) { - // `which` is an alias for either `keyCode` or `charCode` depending on the - // type of the event. - if (event.type === 'keypress') { - return getEventCharCode(event); - } - if (event.type === 'keydown' || event.type === 'keyup') { - return event.keyCode; - } - return 0; - } -}; +function SHA512() { + if (!(this instanceof SHA512)) + return new SHA512(); -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticKeyboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); + BlockHash.call(this); + this.h = [ + 0x6a09e667, 0xf3bcc908, + 0xbb67ae85, 0x84caa73b, + 0x3c6ef372, 0xfe94f82b, + 0xa54ff53a, 0x5f1d36f1, + 0x510e527f, 0xade682d1, + 0x9b05688c, 0x2b3e6c1f, + 0x1f83d9ab, 0xfb41bd6b, + 0x5be0cd19, 0x137e2179 ]; + this.k = sha512_K; + this.W = new Array(160); } +utils.inherits(SHA512, BlockHash); +module.exports = SHA512; -SyntheticUIEvent.augmentClass(SyntheticKeyboardEvent, KeyboardEventInterface); +SHA512.blockSize = 1024; +SHA512.outSize = 512; +SHA512.hmacStrength = 192; +SHA512.padLength = 128; -module.exports = SyntheticKeyboardEvent; +SHA512.prototype._prepareBlock = function _prepareBlock(msg, start) { + var W = this.W; -/***/ }), -/* 205 */ -/***/ (function(module, exports, __webpack_require__) { + // 32 x 32bit words + for (var i = 0; i < 32; i++) + W[i] = msg[start + i]; + for (; i < W.length; i += 2) { + var c0_hi = g1_512_hi(W[i - 4], W[i - 3]); // i - 2 + var c0_lo = g1_512_lo(W[i - 4], W[i - 3]); + var c1_hi = W[i - 14]; // i - 7 + var c1_lo = W[i - 13]; + var c2_hi = g0_512_hi(W[i - 30], W[i - 29]); // i - 15 + var c2_lo = g0_512_lo(W[i - 30], W[i - 29]); + var c3_hi = W[i - 32]; // i - 16 + var c3_lo = W[i - 31]; -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + W[i] = sum64_4_hi( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo); + W[i + 1] = sum64_4_lo( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo); + } +}; +SHA512.prototype._update = function _update(msg, start) { + this._prepareBlock(msg, start); + var W = this.W; -var getEventCharCode = __webpack_require__(65); + var ah = this.h[0]; + var al = this.h[1]; + var bh = this.h[2]; + var bl = this.h[3]; + var ch = this.h[4]; + var cl = this.h[5]; + var dh = this.h[6]; + var dl = this.h[7]; + var eh = this.h[8]; + var el = this.h[9]; + var fh = this.h[10]; + var fl = this.h[11]; + var gh = this.h[12]; + var gl = this.h[13]; + var hh = this.h[14]; + var hl = this.h[15]; -/** - * Normalization of deprecated HTML5 `key` values - * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names - */ -var normalizeKey = { - Esc: 'Escape', - Spacebar: ' ', - Left: 'ArrowLeft', - Up: 'ArrowUp', - Right: 'ArrowRight', - Down: 'ArrowDown', - Del: 'Delete', - Win: 'OS', - Menu: 'ContextMenu', - Apps: 'ContextMenu', - Scroll: 'ScrollLock', - MozPrintableKey: 'Unidentified' -}; + assert(this.k.length === W.length); + for (var i = 0; i < W.length; i += 2) { + var c0_hi = hh; + var c0_lo = hl; + var c1_hi = s1_512_hi(eh, el); + var c1_lo = s1_512_lo(eh, el); + var c2_hi = ch64_hi(eh, el, fh, fl, gh, gl); + var c2_lo = ch64_lo(eh, el, fh, fl, gh, gl); + var c3_hi = this.k[i]; + var c3_lo = this.k[i + 1]; + var c4_hi = W[i]; + var c4_lo = W[i + 1]; -/** - * Translation from legacy `keyCode` to HTML5 `key` - * Only special keys supported, all others depend on keyboard layout or browser - * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names - */ -var translateToKey = { - 8: 'Backspace', - 9: 'Tab', - 12: 'Clear', - 13: 'Enter', - 16: 'Shift', - 17: 'Control', - 18: 'Alt', - 19: 'Pause', - 20: 'CapsLock', - 27: 'Escape', - 32: ' ', - 33: 'PageUp', - 34: 'PageDown', - 35: 'End', - 36: 'Home', - 37: 'ArrowLeft', - 38: 'ArrowUp', - 39: 'ArrowRight', - 40: 'ArrowDown', - 45: 'Insert', - 46: 'Delete', - 112: 'F1', - 113: 'F2', - 114: 'F3', - 115: 'F4', - 116: 'F5', - 117: 'F6', - 118: 'F7', - 119: 'F8', - 120: 'F9', - 121: 'F10', - 122: 'F11', - 123: 'F12', - 144: 'NumLock', - 145: 'ScrollLock', - 224: 'Meta' -}; + var T1_hi = sum64_5_hi( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo, + c4_hi, c4_lo); + var T1_lo = sum64_5_lo( + c0_hi, c0_lo, + c1_hi, c1_lo, + c2_hi, c2_lo, + c3_hi, c3_lo, + c4_hi, c4_lo); -/** - * @param {object} nativeEvent Native browser event. - * @return {string} Normalized `key` property. - */ -function getEventKey(nativeEvent) { - if (nativeEvent.key) { - // Normalize inconsistent values reported by browsers due to - // implementations of a working draft specification. + c0_hi = s0_512_hi(ah, al); + c0_lo = s0_512_lo(ah, al); + c1_hi = maj64_hi(ah, al, bh, bl, ch, cl); + c1_lo = maj64_lo(ah, al, bh, bl, ch, cl); - // FireFox implements `key` but returns `MozPrintableKey` for all - // printable characters (normalized to `Unidentified`), ignore it. - var key = normalizeKey[nativeEvent.key] || nativeEvent.key; - if (key !== 'Unidentified') { - return key; - } - } + var T2_hi = sum64_hi(c0_hi, c0_lo, c1_hi, c1_lo); + var T2_lo = sum64_lo(c0_hi, c0_lo, c1_hi, c1_lo); - // Browser does not implement `key`, polyfill as much of it as we can. - if (nativeEvent.type === 'keypress') { - var charCode = getEventCharCode(nativeEvent); + hh = gh; + hl = gl; - // The enter-key is technically both printable and non-printable and can - // thus be captured by `keypress`, no other non-printable key should. - return charCode === 13 ? 'Enter' : String.fromCharCode(charCode); - } - if (nativeEvent.type === 'keydown' || nativeEvent.type === 'keyup') { - // While user keyboard layout determines the actual meaning of each - // `keyCode` value, almost all function keys have a universal value. - return translateToKey[nativeEvent.keyCode] || 'Unidentified'; - } - return ''; -} + gh = fh; + gl = fl; -module.exports = getEventKey; + fh = eh; + fl = el; -/***/ }), -/* 206 */ -/***/ (function(module, exports, __webpack_require__) { + eh = sum64_hi(dh, dl, T1_hi, T1_lo); + el = sum64_lo(dl, dl, T1_hi, T1_lo); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + dh = ch; + dl = cl; + ch = bh; + cl = bl; + bh = ah; + bl = al; -var SyntheticMouseEvent = __webpack_require__(42); + ah = sum64_hi(T1_hi, T1_lo, T2_hi, T2_lo); + al = sum64_lo(T1_hi, T1_lo, T2_hi, T2_lo); + } -/** - * @interface DragEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var DragEventInterface = { - dataTransfer: null + sum64(this.h, 0, ah, al); + sum64(this.h, 2, bh, bl); + sum64(this.h, 4, ch, cl); + sum64(this.h, 6, dh, dl); + sum64(this.h, 8, eh, el); + sum64(this.h, 10, fh, fl); + sum64(this.h, 12, gh, gl); + sum64(this.h, 14, hh, hl); }; -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticDragEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); -} - -SyntheticMouseEvent.augmentClass(SyntheticDragEvent, DragEventInterface); +SHA512.prototype._digest = function digest(enc) { + if (enc === 'hex') + return utils.toHex32(this.h, 'big'); + else + return utils.split32(this.h, 'big'); +}; -module.exports = SyntheticDragEvent; +function ch64_hi(xh, xl, yh, yl, zh) { + var r = (xh & yh) ^ ((~xh) & zh); + if (r < 0) + r += 0x100000000; + return r; +} -/***/ }), -/* 207 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var SyntheticUIEvent = __webpack_require__(33); - -var getEventModifierState = __webpack_require__(54); - -/** - * @interface TouchEvent - * @see http://www.w3.org/TR/touch-events/ - */ -var TouchEventInterface = { - touches: null, - targetTouches: null, - changedTouches: null, - altKey: null, - metaKey: null, - ctrlKey: null, - shiftKey: null, - getModifierState: getEventModifierState -}; - -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticUIEvent} - */ -function SyntheticTouchEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +function ch64_lo(xh, xl, yh, yl, zh, zl) { + var r = (xl & yl) ^ ((~xl) & zl); + if (r < 0) + r += 0x100000000; + return r; } -SyntheticUIEvent.augmentClass(SyntheticTouchEvent, TouchEventInterface); - -module.exports = SyntheticTouchEvent; +function maj64_hi(xh, xl, yh, yl, zh) { + var r = (xh & yh) ^ (xh & zh) ^ (yh & zh); + if (r < 0) + r += 0x100000000; + return r; +} -/***/ }), -/* 208 */ -/***/ (function(module, exports, __webpack_require__) { +function maj64_lo(xh, xl, yh, yl, zh, zl) { + var r = (xl & yl) ^ (xl & zl) ^ (yl & zl); + if (r < 0) + r += 0x100000000; + return r; +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function s0_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 28); + var c1_hi = rotr64_hi(xl, xh, 2); // 34 + var c2_hi = rotr64_hi(xl, xh, 7); // 39 + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} +function s0_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 28); + var c1_lo = rotr64_lo(xl, xh, 2); // 34 + var c2_lo = rotr64_lo(xl, xh, 7); // 39 -var SyntheticEvent = __webpack_require__(16); + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} -/** - * @interface Event - * @see http://www.w3.org/TR/2009/WD-css3-transitions-20090320/#transition-events- - * @see https://developer.mozilla.org/en-US/docs/Web/API/TransitionEvent - */ -var TransitionEventInterface = { - propertyName: null, - elapsedTime: null, - pseudoElement: null -}; +function s1_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 14); + var c1_hi = rotr64_hi(xh, xl, 18); + var c2_hi = rotr64_hi(xl, xh, 9); // 41 -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticEvent} - */ -function SyntheticTransitionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; } -SyntheticEvent.augmentClass(SyntheticTransitionEvent, TransitionEventInterface); +function s1_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 14); + var c1_lo = rotr64_lo(xh, xl, 18); + var c2_lo = rotr64_lo(xl, xh, 9); // 41 -module.exports = SyntheticTransitionEvent; + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} -/***/ }), -/* 209 */ -/***/ (function(module, exports, __webpack_require__) { +function g0_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 1); + var c1_hi = rotr64_hi(xh, xl, 8); + var c2_hi = shr64_hi(xh, xl, 7); -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} +function g0_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 1); + var c1_lo = rotr64_lo(xh, xl, 8); + var c2_lo = shr64_lo(xh, xl, 7); + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; +} -var SyntheticMouseEvent = __webpack_require__(42); +function g1_512_hi(xh, xl) { + var c0_hi = rotr64_hi(xh, xl, 19); + var c1_hi = rotr64_hi(xl, xh, 29); // 61 + var c2_hi = shr64_hi(xh, xl, 6); -/** - * @interface WheelEvent - * @see http://www.w3.org/TR/DOM-Level-3-Events/ - */ -var WheelEventInterface = { - deltaX: function (event) { - return 'deltaX' in event ? event.deltaX : // Fallback to `wheelDeltaX` for Webkit and normalize (right is positive). - 'wheelDeltaX' in event ? -event.wheelDeltaX : 0; - }, - deltaY: function (event) { - return 'deltaY' in event ? event.deltaY : // Fallback to `wheelDeltaY` for Webkit and normalize (down is positive). - 'wheelDeltaY' in event ? -event.wheelDeltaY : // Fallback to `wheelDelta` for IE<9 and normalize (down is positive). - 'wheelDelta' in event ? -event.wheelDelta : 0; - }, - deltaZ: null, + var r = c0_hi ^ c1_hi ^ c2_hi; + if (r < 0) + r += 0x100000000; + return r; +} - // Browsers without "deltaMode" is reporting in raw wheel delta where one - // notch on the scroll is always +/- 120, roughly equivalent to pixels. - // A good approximation of DOM_DELTA_LINE (1) is 5% of viewport size or - // ~40 pixels, for DOM_DELTA_SCREEN (2) it is 87.5% of viewport size. - deltaMode: null -}; +function g1_512_lo(xh, xl) { + var c0_lo = rotr64_lo(xh, xl, 19); + var c1_lo = rotr64_lo(xl, xh, 29); // 61 + var c2_lo = shr64_lo(xh, xl, 6); -/** - * @param {object} dispatchConfig Configuration used to dispatch this event. - * @param {string} dispatchMarker Marker identifying the event target. - * @param {object} nativeEvent Native browser event. - * @extends {SyntheticMouseEvent} - */ -function SyntheticWheelEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { - return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); + var r = c0_lo ^ c1_lo ^ c2_lo; + if (r < 0) + r += 0x100000000; + return r; } -SyntheticMouseEvent.augmentClass(SyntheticWheelEvent, WheelEventInterface); - -module.exports = SyntheticWheelEvent; /***/ }), -/* 210 */ +/* 175 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var validateDOMNesting = __webpack_require__(64); - -var DOC_NODE_TYPE = 9; +// (public) Constructor +function BigInteger(a, b, c) { + if (!(this instanceof BigInteger)) + return new BigInteger(a, b, c) -function ReactDOMContainerInfo(topLevelWrapper, node) { - var info = { - _topLevelWrapper: topLevelWrapper, - _idCounter: 1, - _ownerDocument: node ? node.nodeType === DOC_NODE_TYPE ? node : node.ownerDocument : null, - _node: node, - _tag: node ? node.nodeName.toLowerCase() : null, - _namespaceURI: node ? node.namespaceURI : null - }; - if (process.env.NODE_ENV !== 'production') { - info._ancestorInfo = node ? validateDOMNesting.updatedAncestorInfo(null, info._tag, null) : null; + if (a != null) { + if ("number" == typeof a) this.fromNumber(a, b, c) + else if (b == null && "string" != typeof a) this.fromString(a, 256) + else this.fromString(a, b) } - return info; } -module.exports = ReactDOMContainerInfo; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 211 */ -/***/ (function(module, exports, __webpack_require__) { +var proto = BigInteger.prototype -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +// duck-typed isBigInteger +proto.__bigi = __webpack_require__(407).version +BigInteger.isBigInteger = function (obj, check_ver) { + return obj && obj.__bigi && (!check_ver || obj.__bigi === proto.__bigi) +} +// Bits per digit +var dbits +// am: Compute w_j += (x*this_i), propagate carries, +// c is initial carry, returns final carry. +// c < 3*dvalue, x < 2*dvalue, this_i < dvalue +// We need to select the fastest one that works in this environment. -var ReactDOMFeatureFlags = { - useCreateElement: true, - useFiber: false -}; +// am1: use a single mult and divide to get the high bits, +// max digit bits should be 26 because +// max internal value = 2*dvalue^2-2*dvalue (< 2^53) +function am1(i, x, w, j, c, n) { + while (--n >= 0) { + var v = x * this[i++] + w[j] + c + c = Math.floor(v / 0x4000000) + w[j++] = v & 0x3ffffff + } + return c +} +// am2 avoids a big mult-and-extract completely. +// Max digit bits should be <= 30 because we do bitwise ops +// on values up to 2*hdvalue^2-hdvalue-1 (< 2^31) +function am2(i, x, w, j, c, n) { + var xl = x & 0x7fff, + xh = x >> 15 + while (--n >= 0) { + var l = this[i] & 0x7fff + var h = this[i++] >> 15 + var m = xh * l + h * xl + l = xl * l + ((m & 0x7fff) << 15) + w[j] + (c & 0x3fffffff) + c = (l >>> 30) + (m >>> 15) + xh * h + (c >>> 30) + w[j++] = l & 0x3fffffff + } + return c +} +// Alternately, set max digit bits to 28 since some +// browsers slow down when dealing with 32-bit numbers. +function am3(i, x, w, j, c, n) { + var xl = x & 0x3fff, + xh = x >> 14 + while (--n >= 0) { + var l = this[i] & 0x3fff + var h = this[i++] >> 14 + var m = xh * l + h * xl + l = xl * l + ((m & 0x3fff) << 14) + w[j] + c + c = (l >> 28) + (m >> 14) + xh * h + w[j++] = l & 0xfffffff + } + return c +} -module.exports = ReactDOMFeatureFlags; +// wtf? +BigInteger.prototype.am = am1 +dbits = 26 -/***/ }), -/* 212 */ -/***/ (function(module, exports, __webpack_require__) { +BigInteger.prototype.DB = dbits +BigInteger.prototype.DM = ((1 << dbits) - 1) +var DV = BigInteger.prototype.DV = (1 << dbits) -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +var BI_FP = 52 +BigInteger.prototype.FV = Math.pow(2, BI_FP) +BigInteger.prototype.F1 = BI_FP - dbits +BigInteger.prototype.F2 = 2 * dbits - BI_FP +// Digit conversions +var BI_RM = "0123456789abcdefghijklmnopqrstuvwxyz" +var BI_RC = new Array() +var rr, vv +rr = "0".charCodeAt(0) +for (vv = 0; vv <= 9; ++vv) BI_RC[rr++] = vv +rr = "a".charCodeAt(0) +for (vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv +rr = "A".charCodeAt(0) +for (vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv +function int2char(n) { + return BI_RM.charAt(n) +} -var adler32 = __webpack_require__(213); +function intAt(s, i) { + var c = BI_RC[s.charCodeAt(i)] + return (c == null) ? -1 : c +} -var TAG_END = /\/?>/; -var COMMENT_START = /^<\!\-\-/; +// (protected) copy this to r +function bnpCopyTo(r) { + for (var i = this.t - 1; i >= 0; --i) r[i] = this[i] + r.t = this.t + r.s = this.s +} -var ReactMarkupChecksum = { - CHECKSUM_ATTR_NAME: 'data-react-checksum', +// (protected) set from integer value x, -DV <= x < DV +function bnpFromInt(x) { + this.t = 1 + this.s = (x < 0) ? -1 : 0 + if (x > 0) this[0] = x + else if (x < -1) this[0] = x + DV + else this.t = 0 +} - /** - * @param {string} markup Markup string - * @return {string} Markup string with checksum attribute attached - */ - addChecksumToMarkup: function (markup) { - var checksum = adler32(markup); +// return bigint initialized to value +function nbv(i) { + var r = new BigInteger() + r.fromInt(i) + return r +} - // Add checksum (handle both parent tags, comments and self-closing tags) - if (COMMENT_START.test(markup)) { - return markup; - } else { - return markup.replace(TAG_END, ' ' + ReactMarkupChecksum.CHECKSUM_ATTR_NAME + '="' + checksum + '"$&'); - } - }, +// (protected) set from string and radix +function bnpFromString(s, b) { + var self = this - /** - * @param {string} markup to use - * @param {DOMElement} element root React element - * @returns {boolean} whether or not the markup is the same - */ - canReuseMarkup: function (markup, element) { - var existingChecksum = element.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); - existingChecksum = existingChecksum && parseInt(existingChecksum, 10); - var markupChecksum = adler32(markup); - return markupChecksum === existingChecksum; + var k + if (b == 16) k = 4 + else if (b == 8) k = 3 + else if (b == 256) k = 8; // byte array + else if (b == 2) k = 1 + else if (b == 32) k = 5 + else if (b == 4) k = 2 + else { + self.fromRadix(s, b) + return } -}; - -module.exports = ReactMarkupChecksum; - -/***/ }), -/* 213 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - * - */ - - - -var MOD = 65521; - -// adler32 is not cryptographically strong, and is only used to sanity check that -// markup generated on the server matches the markup generated on the client. -// This implementation (a modified version of the SheetJS version) has been optimized -// for our use case, at the expense of conforming to the adler32 specification -// for non-ascii inputs. -function adler32(data) { - var a = 1; - var b = 0; - var i = 0; - var l = data.length; - var m = l & ~0x3; - while (i < m) { - var n = Math.min(i + 4096, m); - for (; i < n; i += 4) { - b += (a += data.charCodeAt(i)) + (a += data.charCodeAt(i + 1)) + (a += data.charCodeAt(i + 2)) + (a += data.charCodeAt(i + 3)); + self.t = 0 + self.s = 0 + var i = s.length, + mi = false, + sh = 0 + while (--i >= 0) { + var x = (k == 8) ? s[i] & 0xff : intAt(s, i) + if (x < 0) { + if (s.charAt(i) == "-") mi = true + continue } - a %= MOD; - b %= MOD; + mi = false + if (sh == 0) + self[self.t++] = x + else if (sh + k > self.DB) { + self[self.t - 1] |= (x & ((1 << (self.DB - sh)) - 1)) << sh + self[self.t++] = (x >> (self.DB - sh)) + } else + self[self.t - 1] |= x << sh + sh += k + if (sh >= self.DB) sh -= self.DB } - for (; i < l; i++) { - b += a += data.charCodeAt(i); + if (k == 8 && (s[0] & 0x80) != 0) { + self.s = -1 + if (sh > 0) self[self.t - 1] |= ((1 << (self.DB - sh)) - 1) << sh } - a %= MOD; - b %= MOD; - return a | b << 16; + self.clamp() + if (mi) BigInteger.ZERO.subTo(self, self) } -module.exports = adler32; - -/***/ }), -/* 214 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -module.exports = '15.6.1'; - -/***/ }), -/* 215 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +// (protected) clamp off excess high words +function bnpClamp() { + var c = this.s & this.DM + while (this.t > 0 && this[this.t - 1] == c)--this.t +} +// (public) return string representation in given radix +function bnToString(b) { + var self = this + if (self.s < 0) return "-" + self.negate() + .toString(b) + var k + if (b == 16) k = 4 + else if (b == 8) k = 3 + else if (b == 2) k = 1 + else if (b == 32) k = 5 + else if (b == 4) k = 2 + else return self.toRadix(b) + var km = (1 << k) - 1, + d, m = false, + r = "", + i = self.t + var p = self.DB - (i * self.DB) % k + if (i-- > 0) { + if (p < self.DB && (d = self[i] >> p) > 0) { + m = true + r = int2char(d) + } + while (i >= 0) { + if (p < k) { + d = (self[i] & ((1 << p) - 1)) << (k - p) + d |= self[--i] >> (p += self.DB - k) + } else { + d = (self[i] >> (p -= k)) & km + if (p <= 0) { + p += self.DB + --i + } + } + if (d > 0) m = true + if (m) r += int2char(d) + } + } + return m ? r : "0" +} -var _prodInvariant = __webpack_require__(3); +// (public) -this +function bnNegate() { + var r = new BigInteger() + BigInteger.ZERO.subTo(this, r) + return r +} -var ReactCurrentOwner = __webpack_require__(14); -var ReactDOMComponentTree = __webpack_require__(6); -var ReactInstanceMap = __webpack_require__(34); +// (public) |this| +function bnAbs() { + return (this.s < 0) ? this.negate() : this +} -var getHostComponentFromComposite = __webpack_require__(105); -var invariant = __webpack_require__(1); -var warning = __webpack_require__(2); +// (public) return + if this > a, - if this < a, 0 if equal +function bnCompareTo(a) { + var r = this.s - a.s + if (r != 0) return r + var i = this.t + r = i - a.t + if (r != 0) return (this.s < 0) ? -r : r + while (--i >= 0) + if ((r = this[i] - a[i]) != 0) return r + return 0 +} -/** - * Returns the DOM node rendered by this element. - * - * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.finddomnode - * - * @param {ReactComponent|DOMElement} componentOrElement - * @return {?DOMElement} The root node of this element. - */ -function findDOMNode(componentOrElement) { - if (process.env.NODE_ENV !== 'production') { - var owner = ReactCurrentOwner.current; - if (owner !== null) { - process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing findDOMNode inside its render(). ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; - owner._warnedAboutRefsInRender = true; - } +// returns bit length of the integer x +function nbits(x) { + var r = 1, + t + if ((t = x >>> 16) != 0) { + x = t + r += 16 } - if (componentOrElement == null) { - return null; + if ((t = x >> 8) != 0) { + x = t + r += 8 } - if (componentOrElement.nodeType === 1) { - return componentOrElement; + if ((t = x >> 4) != 0) { + x = t + r += 4 } - - var inst = ReactInstanceMap.get(componentOrElement); - if (inst) { - inst = getHostComponentFromComposite(inst); - return inst ? ReactDOMComponentTree.getNodeFromInstance(inst) : null; + if ((t = x >> 2) != 0) { + x = t + r += 2 } - - if (typeof componentOrElement.render === 'function') { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'findDOMNode was called on an unmounted component.') : _prodInvariant('44') : void 0; - } else { - true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element appears to be neither ReactComponent nor DOMNode (keys: %s)', Object.keys(componentOrElement)) : _prodInvariant('45', Object.keys(componentOrElement)) : void 0; + if ((t = x >> 1) != 0) { + x = t + r += 1 } + return r } -module.exports = findDOMNode; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 216 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var ReactMount = __webpack_require__(104); - -module.exports = ReactMount.renderSubtreeIntoContainer; - -/***/ }), -/* 217 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - +// (public) return the number of bits in "this" +function bnBitLength() { + if (this.t <= 0) return 0 + return this.DB * (this.t - 1) + nbits(this[this.t - 1] ^ (this.s & this.DM)) +} +// (public) return the number of bytes in "this" +function bnByteLength() { + return this.bitLength() >> 3 +} -var DOMProperty = __webpack_require__(17); -var EventPluginRegistry = __webpack_require__(40); -var ReactComponentTreeHook = __webpack_require__(10); +// (protected) r = this << n*DB +function bnpDLShiftTo(n, r) { + var i + for (i = this.t - 1; i >= 0; --i) r[i + n] = this[i] + for (i = n - 1; i >= 0; --i) r[i] = 0 + r.t = this.t + n + r.s = this.s +} -var warning = __webpack_require__(2); +// (protected) r = this >> n*DB +function bnpDRShiftTo(n, r) { + for (var i = n; i < this.t; ++i) r[i - n] = this[i] + r.t = Math.max(this.t - n, 0) + r.s = this.s +} -if (process.env.NODE_ENV !== 'production') { - var reactProps = { - children: true, - dangerouslySetInnerHTML: true, - key: true, - ref: true, +// (protected) r = this << n +function bnpLShiftTo(n, r) { + var self = this + var bs = n % self.DB + var cbs = self.DB - bs + var bm = (1 << cbs) - 1 + var ds = Math.floor(n / self.DB), + c = (self.s << bs) & self.DM, + i + for (i = self.t - 1; i >= 0; --i) { + r[i + ds + 1] = (self[i] >> cbs) | c + c = (self[i] & bm) << bs + } + for (i = ds - 1; i >= 0; --i) r[i] = 0 + r[ds] = c + r.t = self.t + ds + 1 + r.s = self.s + r.clamp() +} - autoFocus: true, - defaultValue: true, - valueLink: true, - defaultChecked: true, - checkedLink: true, - innerHTML: true, - suppressContentEditableWarning: true, - onFocusIn: true, - onFocusOut: true - }; - var warnedProperties = {}; +// (protected) r = this >> n +function bnpRShiftTo(n, r) { + var self = this + r.s = self.s + var ds = Math.floor(n / self.DB) + if (ds >= self.t) { + r.t = 0 + return + } + var bs = n % self.DB + var cbs = self.DB - bs + var bm = (1 << bs) - 1 + r[0] = self[ds] >> bs + for (var i = ds + 1; i < self.t; ++i) { + r[i - ds - 1] |= (self[i] & bm) << cbs + r[i - ds] = self[i] >> bs + } + if (bs > 0) r[self.t - ds - 1] |= (self.s & bm) << cbs + r.t = self.t - ds + r.clamp() +} - var validateProperty = function (tagName, name, debugID) { - if (DOMProperty.properties.hasOwnProperty(name) || DOMProperty.isCustomAttribute(name)) { - return true; - } - if (reactProps.hasOwnProperty(name) && reactProps[name] || warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { - return true; +// (protected) r = this - a +function bnpSubTo(a, r) { + var self = this + var i = 0, + c = 0, + m = Math.min(a.t, self.t) + while (i < m) { + c += self[i] - a[i] + r[i++] = c & self.DM + c >>= self.DB + } + if (a.t < self.t) { + c -= a.s + while (i < self.t) { + c += self[i] + r[i++] = c & self.DM + c >>= self.DB } - if (EventPluginRegistry.registrationNameModules.hasOwnProperty(name)) { - return true; + c += self.s + } else { + c += self.s + while (i < a.t) { + c -= a[i] + r[i++] = c & self.DM + c >>= self.DB } - warnedProperties[name] = true; - var lowerCasedName = name.toLowerCase(); - - // data-* attributes should be lowercase; suggest the lowercase version - var standardName = DOMProperty.isCustomAttribute(lowerCasedName) ? lowerCasedName : DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; - - var registrationName = EventPluginRegistry.possibleRegistrationNames.hasOwnProperty(lowerCasedName) ? EventPluginRegistry.possibleRegistrationNames[lowerCasedName] : null; + c -= a.s + } + r.s = (c < 0) ? -1 : 0 + if (c < -1) r[i++] = self.DV + c + else if (c > 0) r[i++] = c + r.t = i + r.clamp() +} - if (standardName != null) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown DOM property %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - return true; - } else if (registrationName != null) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown event handler property %s. Did you mean `%s`?%s', name, registrationName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - return true; - } else { - // We were unable to guess which prop the user intended. - // It is likely that the user was just blindly spreading/forwarding props - // Components should be careful to only render valid props/attributes. - // Warning will be invoked in warnUnknownProperties to allow grouping. - return false; - } - }; +// (protected) r = this * a, r != this,a (HAC 14.12) +// "this" should be the larger one if appropriate. +function bnpMultiplyTo(a, r) { + var x = this.abs(), + y = a.abs() + var i = x.t + r.t = i + y.t + while (--i >= 0) r[i] = 0 + for (i = 0; i < y.t; ++i) r[i + x.t] = x.am(0, y[i], r, i, 0, x.t) + r.s = 0 + r.clamp() + if (this.s != a.s) BigInteger.ZERO.subTo(r, r) } -var warnUnknownProperties = function (debugID, element) { - var unknownProps = []; - for (var key in element.props) { - var isValid = validateProperty(element.type, key, debugID); - if (!isValid) { - unknownProps.push(key); +// (protected) r = this^2, r != this (HAC 14.16) +function bnpSquareTo(r) { + var x = this.abs() + var i = r.t = 2 * x.t + while (--i >= 0) r[i] = 0 + for (i = 0; i < x.t - 1; ++i) { + var c = x.am(i, x[i], r, 2 * i, 0, 1) + if ((r[i + x.t] += x.am(i + 1, 2 * x[i], r, 2 * i + 1, c, x.t - i - 1)) >= x.DV) { + r[i + x.t] -= x.DV + r[i + x.t + 1] = 1 } } + if (r.t > 0) r[r.t - 1] += x.am(i, x[i], r, 2 * i, 0, 1) + r.s = 0 + r.clamp() +} - var unknownPropString = unknownProps.map(function (prop) { - return '`' + prop + '`'; - }).join(', '); - - if (unknownProps.length === 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown prop %s on <%s> tag. Remove this prop from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } else if (unknownProps.length > 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown props %s on <%s> tag. Remove these props from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } -}; - -function handleElement(debugID, element) { - if (element == null || typeof element.type !== 'string') { - return; +// (protected) divide this by m, quotient and remainder to q, r (HAC 14.20) +// r != q, this != m. q or r may be null. +function bnpDivRemTo(m, q, r) { + var self = this + var pm = m.abs() + if (pm.t <= 0) return + var pt = self.abs() + if (pt.t < pm.t) { + if (q != null) q.fromInt(0) + if (r != null) self.copyTo(r) + return } - if (element.type.indexOf('-') >= 0 || element.props.is) { - return; + if (r == null) r = new BigInteger() + var y = new BigInteger(), + ts = self.s, + ms = m.s + var nsh = self.DB - nbits(pm[pm.t - 1]); // normalize modulus + if (nsh > 0) { + pm.lShiftTo(nsh, y) + pt.lShiftTo(nsh, r) + } else { + pm.copyTo(y) + pt.copyTo(r) } - warnUnknownProperties(debugID, element); -} - -var ReactDOMUnknownPropertyHook = { - onBeforeMountComponent: function (debugID, element) { - handleElement(debugID, element); - }, - onBeforeUpdateComponent: function (debugID, element) { - handleElement(debugID, element); + var ys = y.t + var y0 = y[ys - 1] + if (y0 == 0) return + var yt = y0 * (1 << self.F1) + ((ys > 1) ? y[ys - 2] >> self.F2 : 0) + var d1 = self.FV / yt, + d2 = (1 << self.F1) / yt, + e = 1 << self.F2 + var i = r.t, + j = i - ys, + t = (q == null) ? new BigInteger() : q + y.dlShiftTo(j, t) + if (r.compareTo(t) >= 0) { + r[r.t++] = 1 + r.subTo(t, r) } -}; - -module.exports = ReactDOMUnknownPropertyHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 218 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var ReactComponentTreeHook = __webpack_require__(10); - -var warning = __webpack_require__(2); - -var didWarnValueNull = false; - -function handleElement(debugID, element) { - if (element == null) { - return; + BigInteger.ONE.dlShiftTo(ys, t) + t.subTo(y, y); // "negative" y so we can replace sub with am later + while (y.t < ys) y[y.t++] = 0 + while (--j >= 0) { + // Estimate quotient digit + var qd = (r[--i] == y0) ? self.DM : Math.floor(r[i] * d1 + (r[i - 1] + e) * d2) + if ((r[i] += y.am(0, qd, r, j, 0, ys)) < qd) { // Try it out + y.dlShiftTo(j, t) + r.subTo(t, r) + while (r[i] < --qd) r.subTo(t, r) + } } - if (element.type !== 'input' && element.type !== 'textarea' && element.type !== 'select') { - return; + if (q != null) { + r.drShiftTo(ys, q) + if (ts != ms) BigInteger.ZERO.subTo(q, q) } - if (element.props != null && element.props.value === null && !didWarnValueNull) { - process.env.NODE_ENV !== 'production' ? warning(false, '`value` prop on `%s` should not be null. ' + 'Consider using the empty string to clear the component or `undefined` ' + 'for uncontrolled components.%s', element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + r.t = ys + r.clamp() + if (nsh > 0) r.rShiftTo(nsh, r); // Denormalize remainder + if (ts < 0) BigInteger.ZERO.subTo(r, r) +} - didWarnValueNull = true; - } +// (public) this mod a +function bnMod(a) { + var r = new BigInteger() + this.abs() + .divRemTo(a, null, r) + if (this.s < 0 && r.compareTo(BigInteger.ZERO) > 0) a.subTo(r, r) + return r } -var ReactDOMNullInputValuePropHook = { - onBeforeMountComponent: function (debugID, element) { - handleElement(debugID, element); - }, - onBeforeUpdateComponent: function (debugID, element) { - handleElement(debugID, element); - } -}; +// Modular reduction using "classic" algorithm +function Classic(m) { + this.m = m +} -module.exports = ReactDOMNullInputValuePropHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +function cConvert(x) { + if (x.s < 0 || x.compareTo(this.m) >= 0) return x.mod(this.m) + else return x +} -/***/ }), -/* 219 */ -/***/ (function(module, exports, __webpack_require__) { +function cRevert(x) { + return x +} -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ +function cReduce(x) { + x.divRemTo(this.m, null, x) +} +function cMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) +} +function cSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} -var DOMProperty = __webpack_require__(17); -var ReactComponentTreeHook = __webpack_require__(10); +Classic.prototype.convert = cConvert +Classic.prototype.revert = cRevert +Classic.prototype.reduce = cReduce +Classic.prototype.mulTo = cMulTo +Classic.prototype.sqrTo = cSqrTo -var warning = __webpack_require__(2); - -var warnedProperties = {}; -var rARIA = new RegExp('^(aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); - -function validateProperty(tagName, name, debugID) { - if (warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { - return true; - } - - if (rARIA.test(name)) { - var lowerCasedName = name.toLowerCase(); - var standardName = DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; +// (protected) return "-1/this % 2^DB"; useful for Mont. reduction +// justification: +// xy == 1 (mod m) +// xy = 1+km +// xy(2-xy) = (1+km)(1-km) +// x[y(2-xy)] = 1-k^2m^2 +// x[y(2-xy)] == 1 (mod m^2) +// if y is 1/x mod m, then y(2-xy) is 1/x mod m^2 +// should reduce x and y(2-xy) by m^2 at each step to keep size bounded. +// JS multiply "overflows" differently from C/C++, so care is needed here. +function bnpInvDigit() { + if (this.t < 1) return 0 + var x = this[0] + if ((x & 1) == 0) return 0 + var y = x & 3; // y == 1/x mod 2^2 + y = (y * (2 - (x & 0xf) * y)) & 0xf; // y == 1/x mod 2^4 + y = (y * (2 - (x & 0xff) * y)) & 0xff; // y == 1/x mod 2^8 + y = (y * (2 - (((x & 0xffff) * y) & 0xffff))) & 0xffff; // y == 1/x mod 2^16 + // last step - calculate inverse mod DV directly + // assumes 16 < DB <= 32 and assumes ability to handle 48-bit ints + y = (y * (2 - x * y % this.DV)) % this.DV; // y == 1/x mod 2^dbits + // we really want the negative inverse, and -DV < y < DV + return (y > 0) ? this.DV - y : -y +} - // If this is an aria-* attribute, but is not listed in the known DOM - // DOM properties, then it is an invalid aria-* attribute. - if (standardName == null) { - warnedProperties[name] = true; - return false; - } - // aria-* attributes should be lowercase; suggest the lowercase version. - if (name !== standardName) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown ARIA attribute %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - warnedProperties[name] = true; - return true; - } - } +// Montgomery reduction +function Montgomery(m) { + this.m = m + this.mp = m.invDigit() + this.mpl = this.mp & 0x7fff + this.mph = this.mp >> 15 + this.um = (1 << (m.DB - 15)) - 1 + this.mt2 = 2 * m.t +} - return true; +// xR mod m +function montConvert(x) { + var r = new BigInteger() + x.abs() + .dlShiftTo(this.m.t, r) + r.divRemTo(this.m, null, r) + if (x.s < 0 && r.compareTo(BigInteger.ZERO) > 0) this.m.subTo(r, r) + return r } -function warnInvalidARIAProps(debugID, element) { - var invalidProps = []; +// x/R mod m +function montRevert(x) { + var r = new BigInteger() + x.copyTo(r) + this.reduce(r) + return r +} - for (var key in element.props) { - var isValid = validateProperty(element.type, key, debugID); - if (!isValid) { - invalidProps.push(key); +// x = x/R mod m (HAC 14.32) +function montReduce(x) { + while (x.t <= this.mt2) // pad x so am has enough room later + x[x.t++] = 0 + for (var i = 0; i < this.m.t; ++i) { + // faster way of calculating u0 = x[i]*mp mod DV + var j = x[i] & 0x7fff + var u0 = (j * this.mpl + (((j * this.mph + (x[i] >> 15) * this.mpl) & this.um) << 15)) & x.DM + // use am to combine the multiply-shift-add into one call + j = i + this.m.t + x[j] += this.m.am(0, u0, x, i, 0, this.m.t) + // propagate carry + while (x[j] >= x.DV) { + x[j] -= x.DV + x[++j]++ } } + x.clamp() + x.drShiftTo(this.m.t, x) + if (x.compareTo(this.m) >= 0) x.subTo(this.m, x) +} - var unknownPropString = invalidProps.map(function (prop) { - return '`' + prop + '`'; - }).join(', '); +// r = "x^2/R mod m"; x != r +function montSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} - if (invalidProps.length === 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria prop %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } else if (invalidProps.length > 1) { - process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria props %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - } +// r = "xy/R mod m"; x,y != r +function montMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) } -function handleElement(debugID, element) { - if (element == null || typeof element.type !== 'string') { - return; - } - if (element.type.indexOf('-') >= 0 || element.props.is) { - return; - } +Montgomery.prototype.convert = montConvert +Montgomery.prototype.revert = montRevert +Montgomery.prototype.reduce = montReduce +Montgomery.prototype.mulTo = montMulTo +Montgomery.prototype.sqrTo = montSqrTo - warnInvalidARIAProps(debugID, element); +// (protected) true iff this is even +function bnpIsEven() { + return ((this.t > 0) ? (this[0] & 1) : this.s) == 0 } -var ReactDOMInvalidARIAHook = { - onBeforeMountComponent: function (debugID, element) { - if (process.env.NODE_ENV !== 'production') { - handleElement(debugID, element); - } - }, - onBeforeUpdateComponent: function (debugID, element) { - if (process.env.NODE_ENV !== 'production') { - handleElement(debugID, element); +// (protected) this^e, e < 2^32, doing sqr and mul with "r" (HAC 14.79) +function bnpExp(e, z) { + if (e > 0xffffffff || e < 1) return BigInteger.ONE + var r = new BigInteger(), + r2 = new BigInteger(), + g = z.convert(this), + i = nbits(e) - 1 + g.copyTo(r) + while (--i >= 0) { + z.sqrTo(r, r2) + if ((e & (1 << i)) > 0) z.mulTo(r2, g, r) + else { + var t = r + r = r2 + r2 = t } } -}; + return z.revert(r) +} -module.exports = ReactDOMInvalidARIAHook; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +// (public) this^e % m, 0 <= e < 2^32 +function bnModPowInt(e, m) { + var z + if (e < 256 || m.isEven()) z = new Classic(m) + else z = new Montgomery(m) + return this.exp(e, z) +} -/***/ }), -/* 220 */ -/***/ (function(module, exports, __webpack_require__) { +// protected +proto.copyTo = bnpCopyTo +proto.fromInt = bnpFromInt +proto.fromString = bnpFromString +proto.clamp = bnpClamp +proto.dlShiftTo = bnpDLShiftTo +proto.drShiftTo = bnpDRShiftTo +proto.lShiftTo = bnpLShiftTo +proto.rShiftTo = bnpRShiftTo +proto.subTo = bnpSubTo +proto.multiplyTo = bnpMultiplyTo +proto.squareTo = bnpSquareTo +proto.divRemTo = bnpDivRemTo +proto.invDigit = bnpInvDigit +proto.isEven = bnpIsEven +proto.exp = bnpExp -"use strict"; +// public +proto.toString = bnToString +proto.negate = bnNegate +proto.abs = bnAbs +proto.compareTo = bnCompareTo +proto.bitLength = bnBitLength +proto.byteLength = bnByteLength +proto.mod = bnMod +proto.modPowInt = bnModPowInt +// (public) +function bnClone() { + var r = new BigInteger() + this.copyTo(r) + return r +} -Object.defineProperty(exports, "__esModule", { - value: true -}); +// (public) return value as integer +function bnIntValue() { + if (this.s < 0) { + if (this.t == 1) return this[0] - this.DV + else if (this.t == 0) return -1 + } else if (this.t == 1) return this[0] + else if (this.t == 0) return 0 + // assumes 16 < DB < 32 + return ((this[1] & ((1 << (32 - this.DB)) - 1)) << this.DB) | this[0] +} -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +// (public) return value as byte +function bnByteValue() { + return (this.t == 0) ? this.s : (this[0] << 24) >> 24 +} -var _react = __webpack_require__(4); +// (public) return value as short (assumes DB>=16) +function bnShortValue() { + return (this.t == 0) ? this.s : (this[0] << 16) >> 16 +} -var _react2 = _interopRequireDefault(_react); +// (protected) return x s.t. r^x < DV +function bnpChunkSize(r) { + return Math.floor(Math.LN2 * this.DB / Math.log(r)) +} -var _reactstrap = __webpack_require__(66); +// (public) 0 if this == 0, 1 if this > 0 +function bnSigNum() { + if (this.s < 0) return -1 + else if (this.t <= 0 || (this.t == 1 && this[0] <= 0)) return 0 + else return 1 +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +// (protected) convert to radix string +function bnpToRadix(b) { + if (b == null) b = 10 + if (this.signum() == 0 || b < 2 || b > 36) return "0" + var cs = this.chunkSize(b) + var a = Math.pow(b, cs) + var d = nbv(a), + y = new BigInteger(), + z = new BigInteger(), + r = "" + this.divRemTo(d, y, z) + while (y.signum() > 0) { + r = (a + z.intValue()) + .toString(b) + .substr(1) + r + y.divRemTo(d, y, z) + } + return z.intValue() + .toString(b) + r +} -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +// (protected) convert from radix string +function bnpFromRadix(s, b) { + var self = this + self.fromInt(0) + if (b == null) b = 10 + var cs = self.chunkSize(b) + var d = Math.pow(b, cs), + mi = false, + j = 0, + w = 0 + for (var i = 0; i < s.length; ++i) { + var x = intAt(s, i) + if (x < 0) { + if (s.charAt(i) == "-" && self.signum() == 0) mi = true + continue + } + w = b * w + x + if (++j >= cs) { + self.dMultiply(d) + self.dAddOffset(w, 0) + j = 0 + w = 0 + } + } + if (j > 0) { + self.dMultiply(Math.pow(b, j)) + self.dAddOffset(w, 0) + } + if (mi) BigInteger.ZERO.subTo(self, self) +} -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +// (protected) alternate constructor +function bnpFromNumber(a, b, c) { + var self = this + if ("number" == typeof b) { + // new BigInteger(int,int,RNG) + if (a < 2) self.fromInt(1) + else { + self.fromNumber(a, c) + if (!self.testBit(a - 1)) // force MSB set + self.bitwiseTo(BigInteger.ONE.shiftLeft(a - 1), op_or, self) + if (self.isEven()) self.dAddOffset(1, 0); // force odd + while (!self.isProbablePrime(b)) { + self.dAddOffset(2, 0) + if (self.bitLength() > a) self.subTo(BigInteger.ONE.shiftLeft(a - 1), self) + } + } + } else { + // new BigInteger(int,RNG) + var x = new Array(), + t = a & 7 + x.length = (a >> 3) + 1 + b.nextBytes(x) + if (t > 0) x[0] &= ((1 << t) - 1) + else x[0] = 0 + self.fromString(x, 256) + } +} -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +// (public) convert to bigendian byte array +function bnToByteArray() { + var self = this + var i = self.t, + r = new Array() + r[0] = self.s + var p = self.DB - (i * self.DB) % 8, + d, k = 0 + if (i-- > 0) { + if (p < self.DB && (d = self[i] >> p) != (self.s & self.DM) >> p) + r[k++] = d | (self.s << (self.DB - p)) + while (i >= 0) { + if (p < 8) { + d = (self[i] & ((1 << p) - 1)) << (8 - p) + d |= self[--i] >> (p += self.DB - 8) + } else { + d = (self[i] >> (p -= 8)) & 0xff + if (p <= 0) { + p += self.DB + --i + } + } + if ((d & 0x80) != 0) d |= -256 + if (k === 0 && (self.s & 0x80) != (d & 0x80))++k + if (k > 0 || d != self.s) r[k++] = d + } + } + return r +} -var ZNavbar = function (_React$Component) { - _inherits(ZNavbar, _React$Component); +function bnEquals(a) { + return (this.compareTo(a) == 0) +} - function ZNavbar(props) { - _classCallCheck(this, ZNavbar); +function bnMin(a) { + return (this.compareTo(a) < 0) ? this : a +} - var _this = _possibleConstructorReturn(this, (ZNavbar.__proto__ || Object.getPrototypeOf(ZNavbar)).call(this, props)); +function bnMax(a) { + return (this.compareTo(a) > 0) ? this : a +} - _this.toggleNavbar = _this.toggleNavbar.bind(_this); - _this.state = { - isOpen: false - }; - return _this; +// (protected) r = this op a (bitwise) +function bnpBitwiseTo(a, op, r) { + var self = this + var i, f, m = Math.min(a.t, self.t) + for (i = 0; i < m; ++i) r[i] = op(self[i], a[i]) + if (a.t < self.t) { + f = a.s & self.DM + for (i = m; i < self.t; ++i) r[i] = op(self[i], f) + r.t = self.t + } else { + f = self.s & self.DM + for (i = m; i < a.t; ++i) r[i] = op(f, a[i]) + r.t = a.t } + r.s = op(self.s, a.s) + r.clamp() +} - _createClass(ZNavbar, [{ - key: 'toggleNavbar', - value: function toggleNavbar() { - this.setState({ - isOpen: !this.state.isOpen - }); - } - }, { - key: 'render', - value: function render() { - return _react2.default.createElement( - _reactstrap.Navbar, - { color: 'faded', light: true, toggleable: true }, - _react2.default.createElement(_reactstrap.NavbarToggler, { right: true, onClick: this.toggleNavbar }), - _react2.default.createElement( - _reactstrap.NavbarBrand, - { href: '/' }, - 'myzenwallet.io' - ), - _react2.default.createElement( - _reactstrap.Collapse, - { isOpen: this.state.isOpen, navbar: true }, - _react2.default.createElement( - _reactstrap.Nav, - { className: 'ml-auto', navbar: true }, - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: 'http://getzen.cash' }, - 'FREE ZEN' - ) - ), - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: '/faq.html' }, - 'FAQ' - ) - ), - _react2.default.createElement( - _reactstrap.NavItem, - null, - _react2.default.createElement( - _reactstrap.NavLink, - { href: '/guide.html' }, - 'GETTING STARTED' - ) - ) - ) - ) - ); - } - }]); +// (public) this & a +function op_and(x, y) { + return x & y +} - return ZNavbar; -}(_react2.default.Component); +function bnAnd(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_and, r) + return r +} -exports.default = ZNavbar; +// (public) this | a +function op_or(x, y) { + return x | y +} -/***/ }), -/* 221 */ -/***/ (function(module, exports, __webpack_require__) { +function bnOr(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_or, r) + return r +} -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ +// (public) this ^ a +function op_xor(x, y) { + return x ^ y +} +function bnXor(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_xor, r) + return r +} +// (public) this & ~a +function op_andnot(x, y) { + return x & ~y +} -var emptyFunction = __webpack_require__(12); -var invariant = __webpack_require__(1); -var ReactPropTypesSecret = __webpack_require__(49); +function bnAndNot(a) { + var r = new BigInteger() + this.bitwiseTo(a, op_andnot, r) + return r +} -module.exports = function() { - function shim(props, propName, componentName, location, propFullName, secret) { - if (secret === ReactPropTypesSecret) { - // It is still safe when called from React. - return; - } - invariant( - false, - 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + - 'Use PropTypes.checkPropTypes() to call them. ' + - 'Read more at http://fb.me/use-check-prop-types' - ); - }; - shim.isRequired = shim; - function getShim() { - return shim; - }; - // Important! - // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`. - var ReactPropTypes = { - array: shim, - bool: shim, - func: shim, - number: shim, - object: shim, - string: shim, - symbol: shim, - - any: shim, - arrayOf: getShim, - element: shim, - instanceOf: getShim, - node: shim, - objectOf: getShim, - oneOf: getShim, - oneOfType: getShim, - shape: getShim - }; - - ReactPropTypes.checkPropTypes = emptyFunction; - ReactPropTypes.PropTypes = ReactPropTypes; +// (public) ~this +function bnNot() { + var r = new BigInteger() + for (var i = 0; i < this.t; ++i) r[i] = this.DM & ~this[i] + r.t = this.t + r.s = ~this.s + return r +} - return ReactPropTypes; -}; +// (public) this << n +function bnShiftLeft(n) { + var r = new BigInteger() + if (n < 0) this.rShiftTo(-n, r) + else this.lShiftTo(n, r) + return r +} +// (public) this >> n +function bnShiftRight(n) { + var r = new BigInteger() + if (n < 0) this.lShiftTo(-n, r) + else this.rShiftTo(n, r) + return r +} -/***/ }), -/* 222 */ -/***/ (function(module, exports) { +// return index of lowest 1-bit in x, x < 2^31 +function lbit(x) { + if (x == 0) return -1 + var r = 0 + if ((x & 0xffff) == 0) { + x >>= 16 + r += 16 + } + if ((x & 0xff) == 0) { + x >>= 8 + r += 8 + } + if ((x & 0xf) == 0) { + x >>= 4 + r += 4 + } + if ((x & 3) == 0) { + x >>= 2 + r += 2 + } + if ((x & 1) == 0)++r + return r +} -/** - * lodash 3.0.2 (Custom Build) <https://lodash.com/> - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license <https://lodash.com/license> - */ +// (public) returns index of lowest 1-bit (or -1 if none) +function bnGetLowestSetBit() { + for (var i = 0; i < this.t; ++i) + if (this[i] != 0) return i * this.DB + lbit(this[i]) + if (this.s < 0) return this.t * this.DB + return -1 +} -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(1); - * // => false - */ -function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); +// return number of 1 bits in x +function cbit(x) { + var r = 0 + while (x != 0) { + x &= x - 1 + ++r + } + return r } -module.exports = isObject; +// (public) return number of set bits +function bnBitCount() { + var r = 0, + x = this.s & this.DM + for (var i = 0; i < this.t; ++i) r += cbit(this[i] ^ x) + return r +} +// (public) true iff nth bit is set +function bnTestBit(n) { + var j = Math.floor(n / this.DB) + if (j >= this.t) return (this.s != 0) + return ((this[j] & (1 << (n % this.DB))) != 0) +} -/***/ }), -/* 223 */ -/***/ (function(module, exports) { +// (protected) this op (1<<n) +function bnpChangeBit(n, op) { + var r = BigInteger.ONE.shiftLeft(n) + this.bitwiseTo(r, op, r) + return r +} -/** - * lodash 3.0.8 (Custom Build) <https://lodash.com/> - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation <http://dojofoundation.org/> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license <https://lodash.com/license> - */ +// (public) this | (1<<n) +function bnSetBit(n) { + return this.changeBit(n, op_or) +} -/** `Object#toString` result references. */ -var funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; +// (public) this & ~(1<<n) +function bnClearBit(n) { + return this.changeBit(n, op_andnot) +} -/** Used for built-in method references. */ -var objectProto = Object.prototype; +// (public) this ^ (1<<n) +function bnFlipBit(n) { + return this.changeBit(n, op_xor) +} -/** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; +// (protected) r = this + a +function bnpAddTo(a, r) { + var self = this -/** - * Checks if `value` is classified as a `Function` object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false - */ -function isFunction(value) { - // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 8 which returns 'object' for typed array constructors, and - // PhantomJS 1.9 which returns 'function' for `NodeList` instances. - var tag = isObject(value) ? objectToString.call(value) : ''; - return tag == funcTag || tag == genTag; + var i = 0, + c = 0, + m = Math.min(a.t, self.t) + while (i < m) { + c += self[i] + a[i] + r[i++] = c & self.DM + c >>= self.DB + } + if (a.t < self.t) { + c += a.s + while (i < self.t) { + c += self[i] + r[i++] = c & self.DM + c >>= self.DB + } + c += self.s + } else { + c += self.s + while (i < a.t) { + c += a[i] + r[i++] = c & self.DM + c >>= self.DB + } + c += a.s + } + r.s = (c < 0) ? -1 : 0 + if (c > 0) r[i++] = c + else if (c < -1) r[i++] = self.DV + c + r.t = i + r.clamp() } -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); +// (public) this + a +function bnAdd(a) { + var r = new BigInteger() + this.addTo(a, r) + return r } -module.exports = isFunction; - - -/***/ }), -/* 224 */ -/***/ (function(module, exports, __webpack_require__) { +// (public) this - a +function bnSubtract(a) { + var r = new BigInteger() + this.subTo(a, r) + return r +} -var require;var require;/*! tether 1.3.4 */ -(function(f){if(true){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Tether = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ -'use strict'; +// (public) this * a +function bnMultiply(a) { + var r = new BigInteger() + this.multiplyTo(a, r) + return r +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +// (public) this^2 +function bnSquare() { + var r = new BigInteger() + this.squareTo(r) + return r +} -var _utils = require('./utils'); +// (public) this / a +function bnDivide(a) { + var r = new BigInteger() + this.divRemTo(a, r, null) + return r +} -var _utils2 = _interopRequireDefault(_utils); +// (public) this % a +function bnRemainder(a) { + var r = new BigInteger() + this.divRemTo(a, null, r) + return r +} -var _TetherBase$Utils = _utils2['default'].Utils; -var getBounds = _TetherBase$Utils.getBounds; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; +// (public) [this/a,this%a] +function bnDivideAndRemainder(a) { + var q = new BigInteger(), + r = new BigInteger() + this.divRemTo(a, q, r) + return new Array(q, r) +} -_utils2['default'].modules.push({ - position: function position(_ref) { - var _this = this; +// (protected) this *= n, this >= 0, 1 < n < DV +function bnpDMultiply(n) { + this[this.t] = this.am(0, n - 1, this, 0, 0, this.t) + ++this.t + this.clamp() +} - var top = _ref.top; - var left = _ref.left; +// (protected) this += n << w words, this >= 0 +function bnpDAddOffset(n, w) { + if (n == 0) return + while (this.t <= w) this[this.t++] = 0 + this[w] += n + while (this[w] >= this.DV) { + this[w] -= this.DV + if (++w >= this.t) this[this.t++] = 0 + ++this[w] + } +} - var _cache = this.cache('element-bounds', function () { - return getBounds(_this.element); - }); +// A "null" reducer +function NullExp() {} - var height = _cache.height; - var width = _cache.width; +function nNop(x) { + return x +} - var targetPos = this.getTargetBounds(); +function nMulTo(x, y, r) { + x.multiplyTo(y, r) +} - var bottom = top + height; - var right = left + width; +function nSqrTo(x, r) { + x.squareTo(r) +} - var abutted = []; - if (top <= targetPos.bottom && bottom >= targetPos.top) { - ['left', 'right'].forEach(function (side) { - var targetPosSide = targetPos[side]; - if (targetPosSide === left || targetPosSide === right) { - abutted.push(side); - } - }); - } +NullExp.prototype.convert = nNop +NullExp.prototype.revert = nNop +NullExp.prototype.mulTo = nMulTo +NullExp.prototype.sqrTo = nSqrTo - if (left <= targetPos.right && right >= targetPos.left) { - ['top', 'bottom'].forEach(function (side) { - var targetPosSide = targetPos[side]; - if (targetPosSide === top || targetPosSide === bottom) { - abutted.push(side); - } - }); - } +// (public) this^e +function bnPow(e) { + return this.exp(e, new NullExp()) +} - var allClasses = []; - var addClasses = []; +// (protected) r = lower n words of "this * a", a.t <= n +// "this" should be the larger one if appropriate. +function bnpMultiplyLowerTo(a, n, r) { + var i = Math.min(this.t + a.t, n) + r.s = 0; // assumes a,this >= 0 + r.t = i + while (i > 0) r[--i] = 0 + var j + for (j = r.t - this.t; i < j; ++i) r[i + this.t] = this.am(0, a[i], r, i, 0, this.t) + for (j = Math.min(a.t, n); i < j; ++i) this.am(0, a[i], r, i, 0, n - i) + r.clamp() +} - var sides = ['left', 'top', 'right', 'bottom']; - allClasses.push(this.getClass('abutted')); - sides.forEach(function (side) { - allClasses.push(_this.getClass('abutted') + '-' + side); - }); +// (protected) r = "this * a" without lower n words, n > 0 +// "this" should be the larger one if appropriate. +function bnpMultiplyUpperTo(a, n, r) { + --n + var i = r.t = this.t + a.t - n + r.s = 0; // assumes a,this >= 0 + while (--i >= 0) r[i] = 0 + for (i = Math.max(n - this.t, 0); i < a.t; ++i) + r[this.t + i - n] = this.am(n - i, a[i], r, 0, 0, this.t + i - n) + r.clamp() + r.drShiftTo(1, r) +} - if (abutted.length) { - addClasses.push(this.getClass('abutted')); - } +// Barrett modular reduction +function Barrett(m) { + // setup Barrett + this.r2 = new BigInteger() + this.q3 = new BigInteger() + BigInteger.ONE.dlShiftTo(2 * m.t, this.r2) + this.mu = this.r2.divide(m) + this.m = m +} - abutted.forEach(function (side) { - addClasses.push(_this.getClass('abutted') + '-' + side); - }); +function barrettConvert(x) { + if (x.s < 0 || x.t > 2 * this.m.t) return x.mod(this.m) + else if (x.compareTo(this.m) < 0) return x + else { + var r = new BigInteger() + x.copyTo(r) + this.reduce(r) + return r + } +} - defer(function () { - if (!(_this.options.addTargetClasses === false)) { - updateClasses(_this.target, addClasses, allClasses); - } - updateClasses(_this.element, addClasses, allClasses); - }); +function barrettRevert(x) { + return x +} - return true; +// x = x mod m (HAC 14.42) +function barrettReduce(x) { + var self = this + x.drShiftTo(self.m.t - 1, self.r2) + if (x.t > self.m.t + 1) { + x.t = self.m.t + 1 + x.clamp() } -}); - -},{"./utils":5}],2:[function(require,module,exports){ -'use strict'; + self.mu.multiplyUpperTo(self.r2, self.m.t + 1, self.q3) + self.m.multiplyLowerTo(self.q3, self.m.t + 1, self.r2) + while (x.compareTo(self.r2) < 0) x.dAddOffset(1, self.m.t + 1) + x.subTo(self.r2, x) + while (x.compareTo(self.m) >= 0) x.subTo(self.m, x) +} -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +// r = x^2 mod m; x != r +function barrettSqrTo(x, r) { + x.squareTo(r) + this.reduce(r) +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +// r = x*y mod m; x,y != r +function barrettMulTo(x, y, r) { + x.multiplyTo(y, r) + this.reduce(r) +} -var _utils = require('./utils'); +Barrett.prototype.convert = barrettConvert +Barrett.prototype.revert = barrettRevert +Barrett.prototype.reduce = barrettReduce +Barrett.prototype.mulTo = barrettMulTo +Barrett.prototype.sqrTo = barrettSqrTo -var _utils2 = _interopRequireDefault(_utils); +// (public) this^e % m (HAC 14.85) +function bnModPow(e, m) { + var i = e.bitLength(), + k, r = nbv(1), + z + if (i <= 0) return r + else if (i < 18) k = 1 + else if (i < 48) k = 3 + else if (i < 144) k = 4 + else if (i < 768) k = 5 + else k = 6 + if (i < 8) + z = new Classic(m) + else if (m.isEven()) + z = new Barrett(m) + else + z = new Montgomery(m) -var _TetherBase$Utils = _utils2['default'].Utils; -var getBounds = _TetherBase$Utils.getBounds; -var extend = _TetherBase$Utils.extend; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; + // precomputation + var g = new Array(), + n = 3, + k1 = k - 1, + km = (1 << k) - 1 + g[1] = z.convert(this) + if (k > 1) { + var g2 = new BigInteger() + z.sqrTo(g[1], g2) + while (n <= km) { + g[n] = new BigInteger() + z.mulTo(g2, g[n - 2], g[n]) + n += 2 + } + } -var BOUNDS_FORMAT = ['left', 'top', 'right', 'bottom']; + var j = e.t - 1, + w, is1 = true, + r2 = new BigInteger(), + t + i = nbits(e[j]) - 1 + while (j >= 0) { + if (i >= k1) w = (e[j] >> (i - k1)) & km + else { + w = (e[j] & ((1 << (i + 1)) - 1)) << (k1 - i) + if (j > 0) w |= e[j - 1] >> (this.DB + i - k1) + } -function getBoundingRect(tether, to) { - if (to === 'scrollParent') { - to = tether.scrollParents[0]; - } else if (to === 'window') { - to = [pageXOffset, pageYOffset, innerWidth + pageXOffset, innerHeight + pageYOffset]; - } + n = k + while ((w & 1) == 0) { + w >>= 1 + --n + } + if ((i -= n) < 0) { + i += this.DB + --j + } + if (is1) { // ret == 1, don't bother squaring or multiplying it + g[w].copyTo(r) + is1 = false + } else { + while (n > 1) { + z.sqrTo(r, r2) + z.sqrTo(r2, r) + n -= 2 + } + if (n > 0) z.sqrTo(r, r2) + else { + t = r + r = r2 + r2 = t + } + z.mulTo(r2, g[w], r) + } - if (to === document) { - to = to.documentElement; + while (j >= 0 && (e[j] & (1 << i)) == 0) { + z.sqrTo(r, r2) + t = r + r = r2 + r2 = t + if (--i < 0) { + i = this.DB - 1 + --j + } + } } + return z.revert(r) +} - if (typeof to.nodeType !== 'undefined') { - (function () { - var node = to; - var size = getBounds(to); - var pos = size; - var style = getComputedStyle(to); - - to = [pos.left, pos.top, size.width + pos.left, size.height + pos.top]; +// (public) gcd(this,a) (HAC 14.54) +function bnGCD(a) { + var x = (this.s < 0) ? this.negate() : this.clone() + var y = (a.s < 0) ? a.negate() : a.clone() + if (x.compareTo(y) < 0) { + var t = x + x = y + y = t + } + var i = x.getLowestSetBit(), + g = y.getLowestSetBit() + if (g < 0) return x + if (i < g) g = i + if (g > 0) { + x.rShiftTo(g, x) + y.rShiftTo(g, y) + } + while (x.signum() > 0) { + if ((i = x.getLowestSetBit()) > 0) x.rShiftTo(i, x) + if ((i = y.getLowestSetBit()) > 0) y.rShiftTo(i, y) + if (x.compareTo(y) >= 0) { + x.subTo(y, x) + x.rShiftTo(1, x) + } else { + y.subTo(x, y) + y.rShiftTo(1, y) + } + } + if (g > 0) y.lShiftTo(g, y) + return y +} - // Account any parent Frames scroll offset - if (node.ownerDocument !== document) { - var win = node.ownerDocument.defaultView; - to[0] += win.pageXOffset; - to[1] += win.pageYOffset; - to[2] += win.pageXOffset; - to[3] += win.pageYOffset; - } +// (protected) this % n, n < 2^26 +function bnpModInt(n) { + if (n <= 0) return 0 + var d = this.DV % n, + r = (this.s < 0) ? n - 1 : 0 + if (this.t > 0) + if (d == 0) r = this[0] % n + else + for (var i = this.t - 1; i >= 0; --i) r = (d * r + this[i]) % n + return r +} - BOUNDS_FORMAT.forEach(function (side, i) { - side = side[0].toUpperCase() + side.substr(1); - if (side === 'Top' || side === 'Left') { - to[i] += parseFloat(style['border' + side + 'Width']); - } else { - to[i] -= parseFloat(style['border' + side + 'Width']); +// (public) 1/this % m (HAC 14.61) +function bnModInverse(m) { + var ac = m.isEven() + if (this.signum() === 0) throw new Error('division by zero') + if ((this.isEven() && ac) || m.signum() == 0) return BigInteger.ZERO + var u = m.clone(), + v = this.clone() + var a = nbv(1), + b = nbv(0), + c = nbv(0), + d = nbv(1) + while (u.signum() != 0) { + while (u.isEven()) { + u.rShiftTo(1, u) + if (ac) { + if (!a.isEven() || !b.isEven()) { + a.addTo(this, a) + b.subTo(m, b) } - }); - })(); + a.rShiftTo(1, a) + } else if (!b.isEven()) b.subTo(m, b) + b.rShiftTo(1, b) + } + while (v.isEven()) { + v.rShiftTo(1, v) + if (ac) { + if (!c.isEven() || !d.isEven()) { + c.addTo(this, c) + d.subTo(m, d) + } + c.rShiftTo(1, c) + } else if (!d.isEven()) d.subTo(m, d) + d.rShiftTo(1, d) + } + if (u.compareTo(v) >= 0) { + u.subTo(v, u) + if (ac) a.subTo(c, a) + b.subTo(d, b) + } else { + v.subTo(u, v) + if (ac) c.subTo(a, c) + d.subTo(b, d) + } } - - return to; + if (v.compareTo(BigInteger.ONE) != 0) return BigInteger.ZERO + while (d.compareTo(m) >= 0) d.subTo(m, d) + while (d.signum() < 0) d.addTo(m, d) + return d } -_utils2['default'].modules.push({ - position: function position(_ref) { - var _this = this; +var lowprimes = [ + 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, + 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, + 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, + 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307, 311, 313, 317, + 331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409, 419, + 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, + 509, 521, 523, 541, 547, 557, 563, 569, 571, 577, 587, 593, 599, 601, 607, + 613, 617, 619, 631, 641, 643, 647, 653, 659, 661, 673, 677, 683, 691, 701, + 709, 719, 727, 733, 739, 743, 751, 757, 761, 769, 773, 787, 797, 809, 811, + 821, 823, 827, 829, 839, 853, 857, 859, 863, 877, 881, 883, 887, 907, 911, + 919, 929, 937, 941, 947, 953, 967, 971, 977, 983, 991, 997 +] - var top = _ref.top; - var left = _ref.left; - var targetAttachment = _ref.targetAttachment; +var lplim = (1 << 26) / lowprimes[lowprimes.length - 1] - if (!this.options.constraints) { - return true; - } +// (public) test primality with certainty >= 1-.5^t +function bnIsProbablePrime(t) { + var i, x = this.abs() + if (x.t == 1 && x[0] <= lowprimes[lowprimes.length - 1]) { + for (i = 0; i < lowprimes.length; ++i) + if (x[0] == lowprimes[i]) return true + return false + } + if (x.isEven()) return false + i = 1 + while (i < lowprimes.length) { + var m = lowprimes[i], + j = i + 1 + while (j < lowprimes.length && m < lplim) m *= lowprimes[j++] + m = x.modInt(m) + while (i < j) if (m % lowprimes[i++] == 0) return false + } + return x.millerRabin(t) +} - var _cache = this.cache('element-bounds', function () { - return getBounds(_this.element); - }); +// (protected) true if probably prime (HAC 4.24, Miller-Rabin) +function bnpMillerRabin(t) { + var n1 = this.subtract(BigInteger.ONE) + var k = n1.getLowestSetBit() + if (k <= 0) return false + var r = n1.shiftRight(k) + t = (t + 1) >> 1 + if (t > lowprimes.length) t = lowprimes.length + var a = new BigInteger(null) + var j, bases = [] + for (var i = 0; i < t; ++i) { + for (;;) { + j = lowprimes[Math.floor(Math.random() * lowprimes.length)] + if (bases.indexOf(j) == -1) break + } + bases.push(j) + a.fromInt(j) + var y = a.modPow(r, this) + if (y.compareTo(BigInteger.ONE) != 0 && y.compareTo(n1) != 0) { + var j = 1 + while (j++ < k && y.compareTo(n1) != 0) { + y = y.modPowInt(2, this) + if (y.compareTo(BigInteger.ONE) == 0) return false + } + if (y.compareTo(n1) != 0) return false + } + } + return true +} - var height = _cache.height; - var width = _cache.width; +// protected +proto.chunkSize = bnpChunkSize +proto.toRadix = bnpToRadix +proto.fromRadix = bnpFromRadix +proto.fromNumber = bnpFromNumber +proto.bitwiseTo = bnpBitwiseTo +proto.changeBit = bnpChangeBit +proto.addTo = bnpAddTo +proto.dMultiply = bnpDMultiply +proto.dAddOffset = bnpDAddOffset +proto.multiplyLowerTo = bnpMultiplyLowerTo +proto.multiplyUpperTo = bnpMultiplyUpperTo +proto.modInt = bnpModInt +proto.millerRabin = bnpMillerRabin - if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { - var _lastSize = this.lastSize; +// public +proto.clone = bnClone +proto.intValue = bnIntValue +proto.byteValue = bnByteValue +proto.shortValue = bnShortValue +proto.signum = bnSigNum +proto.toByteArray = bnToByteArray +proto.equals = bnEquals +proto.min = bnMin +proto.max = bnMax +proto.and = bnAnd +proto.or = bnOr +proto.xor = bnXor +proto.andNot = bnAndNot +proto.not = bnNot +proto.shiftLeft = bnShiftLeft +proto.shiftRight = bnShiftRight +proto.getLowestSetBit = bnGetLowestSetBit +proto.bitCount = bnBitCount +proto.testBit = bnTestBit +proto.setBit = bnSetBit +proto.clearBit = bnClearBit +proto.flipBit = bnFlipBit +proto.add = bnAdd +proto.subtract = bnSubtract +proto.multiply = bnMultiply +proto.divide = bnDivide +proto.remainder = bnRemainder +proto.divideAndRemainder = bnDivideAndRemainder +proto.modPow = bnModPow +proto.modInverse = bnModInverse +proto.pow = bnPow +proto.gcd = bnGCD +proto.isProbablePrime = bnIsProbablePrime - // Handle the item getting hidden as a result of our positioning without glitching - // the classes in and out - width = _lastSize.width; - height = _lastSize.height; - } +// JSBN-specific extension +proto.square = bnSquare - var targetSize = this.cache('target-bounds', function () { - return _this.getTargetBounds(); - }); +// constants +BigInteger.ZERO = nbv(0) +BigInteger.ONE = nbv(1) +BigInteger.valueOf = nbv - var targetHeight = targetSize.height; - var targetWidth = targetSize.width; +module.exports = BigInteger - var allClasses = [this.getClass('pinned'), this.getClass('out-of-bounds')]; - this.options.constraints.forEach(function (constraint) { - var outOfBoundsClass = constraint.outOfBoundsClass; - var pinnedClass = constraint.pinnedClass; +/***/ }), +/* 176 */ +/***/ (function(module, exports) { - if (outOfBoundsClass) { - allClasses.push(outOfBoundsClass); - } - if (pinnedClass) { - allClasses.push(pinnedClass); - } - }); +module.exports = { + "sha224WithRSAEncryption": { + "sign": "rsa", + "hash": "sha224", + "id": "302d300d06096086480165030402040500041c" + }, + "RSA-SHA224": { + "sign": "ecdsa/rsa", + "hash": "sha224", + "id": "302d300d06096086480165030402040500041c" + }, + "sha256WithRSAEncryption": { + "sign": "rsa", + "hash": "sha256", + "id": "3031300d060960864801650304020105000420" + }, + "RSA-SHA256": { + "sign": "ecdsa/rsa", + "hash": "sha256", + "id": "3031300d060960864801650304020105000420" + }, + "sha384WithRSAEncryption": { + "sign": "rsa", + "hash": "sha384", + "id": "3041300d060960864801650304020205000430" + }, + "RSA-SHA384": { + "sign": "ecdsa/rsa", + "hash": "sha384", + "id": "3041300d060960864801650304020205000430" + }, + "sha512WithRSAEncryption": { + "sign": "rsa", + "hash": "sha512", + "id": "3051300d060960864801650304020305000440" + }, + "RSA-SHA512": { + "sign": "ecdsa/rsa", + "hash": "sha512", + "id": "3051300d060960864801650304020305000440" + }, + "RSA-SHA1": { + "sign": "rsa", + "hash": "sha1", + "id": "3021300906052b0e03021a05000414" + }, + "ecdsa-with-SHA1": { + "sign": "ecdsa", + "hash": "sha1", + "id": "" + }, + "sha256": { + "sign": "ecdsa", + "hash": "sha256", + "id": "" + }, + "sha224": { + "sign": "ecdsa", + "hash": "sha224", + "id": "" + }, + "sha384": { + "sign": "ecdsa", + "hash": "sha384", + "id": "" + }, + "sha512": { + "sign": "ecdsa", + "hash": "sha512", + "id": "" + }, + "DSA-SHA": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA-SHA1": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA": { + "sign": "dsa", + "hash": "sha1", + "id": "" + }, + "DSA-WITH-SHA224": { + "sign": "dsa", + "hash": "sha224", + "id": "" + }, + "DSA-SHA224": { + "sign": "dsa", + "hash": "sha224", + "id": "" + }, + "DSA-WITH-SHA256": { + "sign": "dsa", + "hash": "sha256", + "id": "" + }, + "DSA-SHA256": { + "sign": "dsa", + "hash": "sha256", + "id": "" + }, + "DSA-WITH-SHA384": { + "sign": "dsa", + "hash": "sha384", + "id": "" + }, + "DSA-SHA384": { + "sign": "dsa", + "hash": "sha384", + "id": "" + }, + "DSA-WITH-SHA512": { + "sign": "dsa", + "hash": "sha512", + "id": "" + }, + "DSA-SHA512": { + "sign": "dsa", + "hash": "sha512", + "id": "" + }, + "DSA-RIPEMD160": { + "sign": "dsa", + "hash": "rmd160", + "id": "" + }, + "ripemd160WithRSA": { + "sign": "rsa", + "hash": "rmd160", + "id": "3021300906052b2403020105000414" + }, + "RSA-RIPEMD160": { + "sign": "rsa", + "hash": "rmd160", + "id": "3021300906052b2403020105000414" + }, + "md5WithRSAEncryption": { + "sign": "rsa", + "hash": "md5", + "id": "3020300c06082a864886f70d020505000410" + }, + "RSA-MD5": { + "sign": "rsa", + "hash": "md5", + "id": "3020300c06082a864886f70d020505000410" + } +}; - allClasses.forEach(function (cls) { - ['left', 'top', 'right', 'bottom'].forEach(function (side) { - allClasses.push(cls + '-' + side); - }); - }); +/***/ }), +/* 177 */ +/***/ (function(module, exports, __webpack_require__) { - var addClasses = []; - var tAttachment = extend({}, targetAttachment); - var eAttachment = extend({}, this.attachment); +exports.pbkdf2 = __webpack_require__(422) - this.options.constraints.forEach(function (constraint) { - var to = constraint.to; - var attachment = constraint.attachment; - var pin = constraint.pin; +exports.pbkdf2Sync = __webpack_require__(180) - if (typeof attachment === 'undefined') { - attachment = ''; - } - var changeAttachX = undefined, - changeAttachY = undefined; - if (attachment.indexOf(' ') >= 0) { - var _attachment$split = attachment.split(' '); +/***/ }), +/* 178 */ +/***/ (function(module, exports) { - var _attachment$split2 = _slicedToArray(_attachment$split, 2); +var MAX_ALLOC = Math.pow(2, 30) - 1 // default in iojs +module.exports = function (iterations, keylen) { + if (typeof iterations !== 'number') { + throw new TypeError('Iterations not a number') + } - changeAttachY = _attachment$split2[0]; - changeAttachX = _attachment$split2[1]; - } else { - changeAttachX = changeAttachY = attachment; - } + if (iterations < 0) { + throw new TypeError('Bad iterations') + } - var bounds = getBoundingRect(_this, to); + if (typeof keylen !== 'number') { + throw new TypeError('Key length not a number') + } - if (changeAttachY === 'target' || changeAttachY === 'both') { - if (top < bounds[1] && tAttachment.top === 'top') { - top += targetHeight; - tAttachment.top = 'bottom'; - } + if (keylen < 0 || keylen > MAX_ALLOC || keylen !== keylen) { /* eslint no-self-compare: 0 */ + throw new TypeError('Bad key length') + } +} - if (top + height > bounds[3] && tAttachment.top === 'bottom') { - top -= targetHeight; - tAttachment.top = 'top'; - } - } - if (changeAttachY === 'together') { - if (tAttachment.top === 'top') { - if (eAttachment.top === 'bottom' && top < bounds[1]) { - top += targetHeight; - tAttachment.top = 'bottom'; +/***/ }), +/* 179 */ +/***/ (function(module, exports, __webpack_require__) { - top += height; - eAttachment.top = 'top'; - } else if (eAttachment.top === 'top' && top + height > bounds[3] && top - (height - targetHeight) >= bounds[1]) { - top -= height - targetHeight; - tAttachment.top = 'bottom'; +/* WEBPACK VAR INJECTION */(function(process) {var defaultEncoding +/* istanbul ignore next */ +if (process.browser) { + defaultEncoding = 'utf-8' +} else { + var pVersionMajor = parseInt(process.version.split('.')[0].slice(1), 10) - eAttachment.top = 'bottom'; - } - } + defaultEncoding = pVersionMajor >= 6 ? 'utf-8' : 'binary' +} +module.exports = defaultEncoding - if (tAttachment.top === 'bottom') { - if (eAttachment.top === 'top' && top + height > bounds[3]) { - top -= targetHeight; - tAttachment.top = 'top'; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - top -= height; - eAttachment.top = 'bottom'; - } else if (eAttachment.top === 'bottom' && top < bounds[1] && top + (height * 2 - targetHeight) <= bounds[3]) { - top += height - targetHeight; - tAttachment.top = 'top'; +/***/ }), +/* 180 */ +/***/ (function(module, exports, __webpack_require__) { - eAttachment.top = 'top'; - } - } +var md5 = __webpack_require__(63) +var rmd160 = __webpack_require__(97) +var sha = __webpack_require__(103) - if (tAttachment.top === 'middle') { - if (top + height > bounds[3] && eAttachment.top === 'top') { - top -= height; - eAttachment.top = 'bottom'; - } else if (top < bounds[1] && eAttachment.top === 'bottom') { - top += height; - eAttachment.top = 'top'; - } - } - } +var checkParameters = __webpack_require__(178) +var defaultEncoding = __webpack_require__(179) +var Buffer = __webpack_require__(7).Buffer +var ZEROS = Buffer.alloc(128) +var sizes = { + md5: 16, + sha1: 20, + sha224: 28, + sha256: 32, + sha384: 48, + sha512: 64, + rmd160: 20, + ripemd160: 20 +} +function Hmac (alg, key, saltLen) { + var hash = getDigest(alg) + var blocksize = (alg === 'sha512' || alg === 'sha384') ? 128 : 64 - if (changeAttachX === 'target' || changeAttachX === 'both') { - if (left < bounds[0] && tAttachment.left === 'left') { - left += targetWidth; - tAttachment.left = 'right'; - } + if (key.length > blocksize) { + key = hash(key) + } else if (key.length < blocksize) { + key = Buffer.concat([key, ZEROS], blocksize) + } - if (left + width > bounds[2] && tAttachment.left === 'right') { - left -= targetWidth; - tAttachment.left = 'left'; - } - } + var ipad = Buffer.allocUnsafe(blocksize + sizes[alg]) + var opad = Buffer.allocUnsafe(blocksize + sizes[alg]) + for (var i = 0; i < blocksize; i++) { + ipad[i] = key[i] ^ 0x36 + opad[i] = key[i] ^ 0x5C + } - if (changeAttachX === 'together') { - if (left < bounds[0] && tAttachment.left === 'left') { - if (eAttachment.left === 'right') { - left += targetWidth; - tAttachment.left = 'right'; + var ipad1 = Buffer.allocUnsafe(blocksize + saltLen + 4) + ipad.copy(ipad1, 0, 0, blocksize) + this.ipad1 = ipad1 + this.ipad2 = ipad + this.opad = opad + this.alg = alg + this.blocksize = blocksize + this.hash = hash + this.size = sizes[alg] +} - left += width; - eAttachment.left = 'left'; - } else if (eAttachment.left === 'left') { - left += targetWidth; - tAttachment.left = 'right'; +Hmac.prototype.run = function (data, ipad) { + data.copy(ipad, this.blocksize) + var h = this.hash(ipad) + h.copy(this.opad, this.blocksize) + return this.hash(this.opad) +} - left -= width; - eAttachment.left = 'right'; - } - } else if (left + width > bounds[2] && tAttachment.left === 'right') { - if (eAttachment.left === 'left') { - left -= targetWidth; - tAttachment.left = 'left'; +function getDigest (alg) { + if (alg === 'rmd160' || alg === 'ripemd160') return rmd160 + if (alg === 'md5') return md5 + return shaFunc - left -= width; - eAttachment.left = 'right'; - } else if (eAttachment.left === 'right') { - left -= targetWidth; - tAttachment.left = 'left'; + function shaFunc (data) { + return sha(alg).update(data).digest() + } +} - left += width; - eAttachment.left = 'left'; - } - } else if (tAttachment.left === 'center') { - if (left + width > bounds[2] && eAttachment.left === 'left') { - left -= width; - eAttachment.left = 'right'; - } else if (left < bounds[0] && eAttachment.left === 'right') { - left += width; - eAttachment.left = 'left'; - } - } - } +module.exports = function (password, salt, iterations, keylen, digest) { + if (!Buffer.isBuffer(password)) password = Buffer.from(password, defaultEncoding) + if (!Buffer.isBuffer(salt)) salt = Buffer.from(salt, defaultEncoding) - if (changeAttachY === 'element' || changeAttachY === 'both') { - if (top < bounds[1] && eAttachment.top === 'bottom') { - top += height; - eAttachment.top = 'top'; - } + checkParameters(iterations, keylen) - if (top + height > bounds[3] && eAttachment.top === 'top') { - top -= height; - eAttachment.top = 'bottom'; - } - } + digest = digest || 'sha1' - if (changeAttachX === 'element' || changeAttachX === 'both') { - if (left < bounds[0]) { - if (eAttachment.left === 'right') { - left += width; - eAttachment.left = 'left'; - } else if (eAttachment.left === 'center') { - left += width / 2; - eAttachment.left = 'left'; - } - } + var hmac = new Hmac(digest, password, salt.length) - if (left + width > bounds[2]) { - if (eAttachment.left === 'left') { - left -= width; - eAttachment.left = 'right'; - } else if (eAttachment.left === 'center') { - left -= width / 2; - eAttachment.left = 'right'; - } - } - } + var DK = Buffer.allocUnsafe(keylen) + var block1 = Buffer.allocUnsafe(salt.length + 4) + salt.copy(block1, 0, 0, salt.length) - if (typeof pin === 'string') { - pin = pin.split(',').map(function (p) { - return p.trim(); - }); - } else if (pin === true) { - pin = ['top', 'left', 'right', 'bottom']; - } + var U, j, destPos, len - pin = pin || []; + var hLen = hmac.size + var T = Buffer.allocUnsafe(hLen) + var l = Math.ceil(keylen / hLen) + var r = keylen - (l - 1) * hLen - var pinned = []; - var oob = []; + for (var i = 1; i <= l; i++) { + block1.writeUInt32BE(i, salt.length) + U = hmac.run(block1, hmac.ipad1) - if (top < bounds[1]) { - if (pin.indexOf('top') >= 0) { - top = bounds[1]; - pinned.push('top'); - } else { - oob.push('top'); - } - } + U.copy(T, 0, 0, hLen) - if (top + height > bounds[3]) { - if (pin.indexOf('bottom') >= 0) { - top = bounds[3] - height; - pinned.push('bottom'); - } else { - oob.push('bottom'); - } - } + for (j = 1; j < iterations; j++) { + U = hmac.run(U, hmac.ipad2) + for (var k = 0; k < hLen; k++) T[k] ^= U[k] + } - if (left < bounds[0]) { - if (pin.indexOf('left') >= 0) { - left = bounds[0]; - pinned.push('left'); - } else { - oob.push('left'); - } - } + destPos = (i - 1) * hLen + len = (i === l ? r : hLen) + T.copy(DK, destPos, 0, len) + } - if (left + width > bounds[2]) { - if (pin.indexOf('right') >= 0) { - left = bounds[2] - width; - pinned.push('right'); - } else { - oob.push('right'); - } - } + return DK +} - if (pinned.length) { - (function () { - var pinnedClass = undefined; - if (typeof _this.options.pinnedClass !== 'undefined') { - pinnedClass = _this.options.pinnedClass; - } else { - pinnedClass = _this.getClass('pinned'); - } - addClasses.push(pinnedClass); - pinned.forEach(function (side) { - addClasses.push(pinnedClass + '-' + side); - }); - })(); - } +/***/ }), +/* 181 */ +/***/ (function(module, exports, __webpack_require__) { - if (oob.length) { - (function () { - var oobClass = undefined; - if (typeof _this.options.outOfBoundsClass !== 'undefined') { - oobClass = _this.options.outOfBoundsClass; - } else { - oobClass = _this.getClass('out-of-bounds'); - } +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) - addClasses.push(oobClass); - oob.forEach(function (side) { - addClasses.push(oobClass + '-' + side); - }); - })(); - } +inherits(StreamCipher, Transform) +module.exports = StreamCipher +function StreamCipher (mode, key, iv, decrypt) { + if (!(this instanceof StreamCipher)) { + return new StreamCipher(mode, key, iv) + } + Transform.call(this) + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + this._cache = new Buffer('') + this._secCache = new Buffer('') + this._decrypt = decrypt + iv.copy(this._prev) + this._mode = mode +} +StreamCipher.prototype._update = function (chunk) { + return this._mode.encrypt(this, chunk, this._decrypt) +} +StreamCipher.prototype._final = function () { + this._cipher.scrub() +} - if (pinned.indexOf('left') >= 0 || pinned.indexOf('right') >= 0) { - eAttachment.left = tAttachment.left = false; - } - if (pinned.indexOf('top') >= 0 || pinned.indexOf('bottom') >= 0) { - eAttachment.top = tAttachment.top = false; - } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - if (tAttachment.top !== targetAttachment.top || tAttachment.left !== targetAttachment.left || eAttachment.top !== _this.attachment.top || eAttachment.left !== _this.attachment.left) { - _this.updateAttachClasses(eAttachment, tAttachment); - _this.trigger('update', { - attachment: eAttachment, - targetAttachment: tAttachment - }); - } - }); +/***/ }), +/* 182 */ +/***/ (function(module, exports, __webpack_require__) { - defer(function () { - if (!(_this.options.addTargetClasses === false)) { - updateClasses(_this.target, addClasses, allClasses); - } - updateClasses(_this.element, addClasses, allClasses); - }); +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var GHASH = __webpack_require__(425) +var xor = __webpack_require__(51) +inherits(StreamCipher, Transform) +module.exports = StreamCipher - return { top: top, left: left }; +function StreamCipher (mode, key, iv, decrypt) { + if (!(this instanceof StreamCipher)) { + return new StreamCipher(mode, key, iv) } -}); + Transform.call(this) + this._finID = Buffer.concat([iv, new Buffer([0, 0, 0, 1])]) + iv = Buffer.concat([iv, new Buffer([0, 0, 0, 2])]) + this._cipher = new aes.AES(key) + this._prev = new Buffer(iv.length) + this._cache = new Buffer('') + this._secCache = new Buffer('') + this._decrypt = decrypt + this._alen = 0 + this._len = 0 + iv.copy(this._prev) + this._mode = mode + var h = new Buffer(4) + h.fill(0) + this._ghash = new GHASH(this._cipher.encryptBlock(h)) + this._authTag = null + this._called = false +} +StreamCipher.prototype._update = function (chunk) { + if (!this._called && this._alen) { + var rump = 16 - (this._alen % 16) + if (rump < 16) { + rump = new Buffer(rump) + rump.fill(0) + this._ghash.update(rump) + } + } + this._called = true + var out = this._mode.encrypt(this, chunk) + if (this._decrypt) { + this._ghash.update(chunk) + } else { + this._ghash.update(out) + } + this._len += chunk.length + return out +} +StreamCipher.prototype._final = function () { + if (this._decrypt && !this._authTag) { + throw new Error('Unsupported state or unable to authenticate data') + } + var tag = xor(this._ghash.final(this._alen * 8, this._len * 8), this._cipher.encryptBlock(this._finID)) + if (this._decrypt) { + if (xorTest(tag, this._authTag)) { + throw new Error('Unsupported state or unable to authenticate data') + } + } else { + this._authTag = tag + } + this._cipher.scrub() +} +StreamCipher.prototype.getAuthTag = function getAuthTag () { + if (!this._decrypt && Buffer.isBuffer(this._authTag)) { + return this._authTag + } else { + throw new Error('Attempting to get auth tag in unsupported state') + } +} +StreamCipher.prototype.setAuthTag = function setAuthTag (tag) { + if (this._decrypt) { + this._authTag = tag + } else { + throw new Error('Attempting to set auth tag in unsupported state') + } +} +StreamCipher.prototype.setAAD = function setAAD (buf) { + if (!this._called) { + this._ghash.update(buf) + this._alen += buf.length + } else { + throw new Error('Attempting to set AAD in unsupported state') + } +} +function xorTest (a, b) { + var out = 0 + if (a.length !== b.length) { + out++ + } + var len = Math.min(a.length, b.length) + var i = -1 + while (++i < len) { + out += (a[i] ^ b[i]) + } + return out +} -},{"./utils":5}],3:[function(require,module,exports){ -'use strict'; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +/***/ }), +/* 183 */ +/***/ (function(module, exports) { -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +exports.encrypt = function (self, block) { + return self._cipher.encryptBlock(block) +} +exports.decrypt = function (self, block) { + return self._cipher.decryptBlock(block) +} -var _utils = require('./utils'); -var _utils2 = _interopRequireDefault(_utils); +/***/ }), +/* 184 */ +/***/ (function(module, exports, __webpack_require__) { -_utils2['default'].modules.push({ - position: function position(_ref) { - var top = _ref.top; - var left = _ref.left; +var xor = __webpack_require__(51) - if (!this.options.shift) { - return; - } +exports.encrypt = function (self, block) { + var data = xor(block, self._prev) - var shift = this.options.shift; - if (typeof this.options.shift === 'function') { - shift = this.options.shift.call(this, { top: top, left: left }); - } + self._prev = self._cipher.encryptBlock(data) + return self._prev +} - var shiftTop = undefined, - shiftLeft = undefined; - if (typeof shift === 'string') { - shift = shift.split(' '); - shift[1] = shift[1] || shift[0]; +exports.decrypt = function (self, block) { + var pad = self._prev - var _shift = shift; + self._prev = block + var out = self._cipher.decryptBlock(block) - var _shift2 = _slicedToArray(_shift, 2); + return xor(out, pad) +} - shiftTop = _shift2[0]; - shiftLeft = _shift2[1]; - shiftTop = parseFloat(shiftTop, 10); - shiftLeft = parseFloat(shiftLeft, 10); - } else { - shiftTop = shift.top; - shiftLeft = shift.left; - } +/***/ }), +/* 185 */ +/***/ (function(module, exports, __webpack_require__) { - top += shiftTop; - left += shiftLeft; +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) - return { top: top, left: left }; - } -}); +exports.encrypt = function (self, data, decrypt) { + var out = new Buffer('') + var len -},{"./utils":5}],4:[function(require,module,exports){ -/* globals performance */ + while (data.length) { + if (self._cache.length === 0) { + self._cache = self._cipher.encryptBlock(self._prev) + self._prev = new Buffer('') + } -'use strict'; + if (self._cache.length <= data.length) { + len = self._cache.length + out = Buffer.concat([out, encryptStart(self, data.slice(0, len), decrypt)]) + data = data.slice(len) + } else { + out = Buffer.concat([out, encryptStart(self, data, decrypt)]) + break + } + } -Object.defineProperty(exports, '__esModule', { - value: true -}); + return out +} +function encryptStart (self, data, decrypt) { + var len = data.length + var out = xor(data, self._cache) + self._cache = self._cache.slice(len) + self._prev = Buffer.concat([self._prev, decrypt ? data : out]) + return out +} -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); +/***/ }), +/* 186 */ +/***/ (function(module, exports, __webpack_require__) { -var _get = function get(_x6, _x7, _x8) { var _again = true; _function: while (_again) { var object = _x6, property = _x7, receiver = _x8; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x6 = parent; _x7 = property; _x8 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; +/* WEBPACK VAR INJECTION */(function(Buffer) {function encryptByte (self, byteParam, decrypt) { + var pad = self._cipher.encryptBlock(self._prev) + var out = pad[0] ^ byteParam + self._prev = Buffer.concat([self._prev.slice(1), new Buffer([decrypt ? byteParam : out])]) + return out +} +exports.encrypt = function (self, chunk, decrypt) { + var len = chunk.length + var out = new Buffer(len) + var i = -1 + while (++i < len) { + out[i] = encryptByte(self, chunk[i], decrypt) + } + return out +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } +/***/ }), +/* 187 */ +/***/ (function(module, exports, __webpack_require__) { -function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +/* WEBPACK VAR INJECTION */(function(Buffer) {function encryptByte (self, byteParam, decrypt) { + var pad + var i = -1 + var len = 8 + var out = 0 + var bit, value + while (++i < len) { + pad = self._cipher.encryptBlock(self._prev) + bit = (byteParam & (1 << (7 - i))) ? 0x80 : 0 + value = pad[0] ^ bit + out += ((value & 0x80) >> (i % 8)) + self._prev = shiftIn(self._prev, decrypt ? bit : value) + } + return out +} +exports.encrypt = function (self, chunk, decrypt) { + var len = chunk.length + var out = new Buffer(len) + var i = -1 + while (++i < len) { + out[i] = encryptByte(self, chunk[i], decrypt) + } + return out +} +function shiftIn (buffer, value) { + var len = buffer.length + var i = -1 + var out = new Buffer(buffer.length) + buffer = Buffer.concat([buffer, new Buffer([value])]) + while (++i < len) { + out[i] = buffer[i] << 1 | buffer[i + 1] >> (7) + } + return out +} -var _utils = require('./utils'); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) -var _utils2 = _interopRequireDefault(_utils); +/***/ }), +/* 188 */ +/***/ (function(module, exports, __webpack_require__) { -require('./constraint'); +/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(51) -require('./abutment'); +function getBlock (self) { + self._prev = self._cipher.encryptBlock(self._prev) + return self._prev +} -require('./shift'); +exports.encrypt = function (self, chunk) { + while (self._cache.length < chunk.length) { + self._cache = Buffer.concat([self._cache, getBlock(self)]) + } -var _TetherBase$Utils = _utils2['default'].Utils; -var getScrollParents = _TetherBase$Utils.getScrollParents; -var getBounds = _TetherBase$Utils.getBounds; -var getOffsetParent = _TetherBase$Utils.getOffsetParent; -var extend = _TetherBase$Utils.extend; -var addClass = _TetherBase$Utils.addClass; -var removeClass = _TetherBase$Utils.removeClass; -var updateClasses = _TetherBase$Utils.updateClasses; -var defer = _TetherBase$Utils.defer; -var flush = _TetherBase$Utils.flush; -var getScrollBarSize = _TetherBase$Utils.getScrollBarSize; -var removeUtilElements = _TetherBase$Utils.removeUtilElements; -var Evented = _TetherBase$Utils.Evented; + var pad = self._cache.slice(0, chunk.length) + self._cache = self._cache.slice(chunk.length) + return xor(chunk, pad) +} -function within(a, b) { - var diff = arguments.length <= 2 || arguments[2] === undefined ? 1 : arguments[2]; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - return a + diff >= b && b >= a - diff; -} +/***/ }), +/* 189 */ +/***/ (function(module, exports, __webpack_require__) { -var transformKey = (function () { - if (typeof document === 'undefined') { - return ''; - } - var el = document.createElement('div'); +var randomBytes = __webpack_require__(43); +module.exports = findPrime; +findPrime.simpleSieve = simpleSieve; +findPrime.fermatTest = fermatTest; +var BN = __webpack_require__(11); +var TWENTYFOUR = new BN(24); +var MillerRabin = __webpack_require__(190); +var millerRabin = new MillerRabin(); +var ONE = new BN(1); +var TWO = new BN(2); +var FIVE = new BN(5); +var SIXTEEN = new BN(16); +var EIGHT = new BN(8); +var TEN = new BN(10); +var THREE = new BN(3); +var SEVEN = new BN(7); +var ELEVEN = new BN(11); +var FOUR = new BN(4); +var TWELVE = new BN(12); +var primes = null; - var transforms = ['transform', 'WebkitTransform', 'OTransform', 'MozTransform', 'msTransform']; - for (var i = 0; i < transforms.length; ++i) { - var key = transforms[i]; - if (el.style[key] !== undefined) { - return key; - } - } -})(); +function _getPrimes() { + if (primes !== null) + return primes; -var tethers = []; + var limit = 0x100000; + var res = []; + res[0] = 2; + for (var i = 1, k = 3; k < limit; k += 2) { + var sqrt = Math.ceil(Math.sqrt(k)); + for (var j = 0; j < i && res[j] <= sqrt; j++) + if (k % res[j] === 0) + break; -var position = function position() { - tethers.forEach(function (tether) { - tether.position(false); - }); - flush(); -}; + if (i !== j && res[j] <= sqrt) + continue; -function now() { - if (typeof performance !== 'undefined' && typeof performance.now !== 'undefined') { - return performance.now(); + res[i++] = k; } - return +new Date(); + primes = res; + return res; } -(function () { - var lastCall = null; - var lastDuration = null; - var pendingTimeout = null; - - var tick = function tick() { - if (typeof lastDuration !== 'undefined' && lastDuration > 16) { - // We voluntarily throttle ourselves if we can't manage 60fps - lastDuration = Math.min(lastDuration - 16, 250); +function simpleSieve(p) { + var primes = _getPrimes(); - // Just in case this is the last event, remember to position just once more - pendingTimeout = setTimeout(tick, 250); - return; + for (var i = 0; i < primes.length; i++) + if (p.modn(primes[i]) === 0) { + if (p.cmpn(primes[i]) === 0) { + return true; + } else { + return false; + } } - if (typeof lastCall !== 'undefined' && now() - lastCall < 10) { - // Some browsers call events a little too frequently, refuse to run more than is reasonable - return; - } + return true; +} - if (pendingTimeout != null) { - clearTimeout(pendingTimeout); - pendingTimeout = null; +function fermatTest(p) { + var red = BN.mont(p); + return TWO.toRed(red).redPow(p.subn(1)).fromRed().cmpn(1) === 0; +} + +function findPrime(bits, gen) { + if (bits < 16) { + // this is what openssl does + if (gen === 2 || gen === 5) { + return new BN([0x8c, 0x7b]); + } else { + return new BN([0x8c, 0x27]); } + } + gen = new BN(gen); - lastCall = now(); - position(); - lastDuration = now() - lastCall; - }; + var num, n2; - if (typeof window !== 'undefined' && typeof window.addEventListener !== 'undefined') { - ['resize', 'scroll', 'touchmove'].forEach(function (event) { - window.addEventListener(event, tick); - }); + while (true) { + num = new BN(randomBytes(Math.ceil(bits / 8))); + while (num.bitLength() > bits) { + num.ishrn(1); + } + if (num.isEven()) { + num.iadd(ONE); + } + if (!num.testn(1)) { + num.iadd(TWO); + } + if (!gen.cmp(TWO)) { + while (num.mod(TWENTYFOUR).cmp(ELEVEN)) { + num.iadd(FOUR); + } + } else if (!gen.cmp(FIVE)) { + while (num.mod(TEN).cmp(THREE)) { + num.iadd(FOUR); + } + } + n2 = num.shrn(1); + if (simpleSieve(n2) && simpleSieve(num) && + fermatTest(n2) && fermatTest(num) && + millerRabin.test(n2) && millerRabin.test(num)) { + return num; + } } -})(); -var MIRROR_LR = { - center: 'center', - left: 'right', - right: 'left' -}; +} -var MIRROR_TB = { - middle: 'middle', - top: 'bottom', - bottom: 'top' -}; -var OFFSET_MAP = { - top: 0, - left: 0, - middle: '50%', - center: '50%', - bottom: '100%', - right: '100%' +/***/ }), +/* 190 */ +/***/ (function(module, exports, __webpack_require__) { + +var bn = __webpack_require__(11); +var brorand = __webpack_require__(171); + +function MillerRabin(rand) { + this.rand = rand || new brorand.Rand(); +} +module.exports = MillerRabin; + +MillerRabin.create = function create(rand) { + return new MillerRabin(rand); }; -var autoToFixedAttachment = function autoToFixedAttachment(attachment, relativeToAttachment) { - var left = attachment.left; - var top = attachment.top; +MillerRabin.prototype._rand = function _rand(n) { + var len = n.bitLength(); + var buf = this.rand.generate(Math.ceil(len / 8)); - if (left === 'auto') { - left = MIRROR_LR[relativeToAttachment.left]; - } + // Set low bits + buf[0] |= 3; - if (top === 'auto') { - top = MIRROR_TB[relativeToAttachment.top]; - } + // Mask high bits + var mask = len & 0x7; + if (mask !== 0) + buf[buf.length - 1] >>= 7 - mask; - return { left: left, top: top }; -}; + return new bn(buf); +} -var attachmentToOffset = function attachmentToOffset(attachment) { - var left = attachment.left; - var top = attachment.top; +MillerRabin.prototype.test = function test(n, k, cb) { + var len = n.bitLength(); + var red = bn.mont(n); + var rone = new bn(1).toRed(red); - if (typeof OFFSET_MAP[attachment.left] !== 'undefined') { - left = OFFSET_MAP[attachment.left]; - } + if (!k) + k = Math.max(1, (len / 48) | 0); - if (typeof OFFSET_MAP[attachment.top] !== 'undefined') { - top = OFFSET_MAP[attachment.top]; - } + // Find d and s, (n - 1) = (2 ^ s) * d; + var n1 = n.subn(1); + var n2 = n1.subn(1); + for (var s = 0; !n1.testn(s); s++) {} + var d = n.shrn(s); - return { left: left, top: top }; -}; + var rn1 = n1.toRed(red); -function addOffset() { - var out = { top: 0, left: 0 }; + var prime = true; + for (; k > 0; k--) { + var a = this._rand(n2); + if (cb) + cb(a); - for (var _len = arguments.length, offsets = Array(_len), _key = 0; _key < _len; _key++) { - offsets[_key] = arguments[_key]; - } + var x = a.toRed(red).redPow(d); + if (x.cmp(rone) === 0 || x.cmp(rn1) === 0) + continue; - offsets.forEach(function (_ref) { - var top = _ref.top; - var left = _ref.left; + for (var i = 1; i < s; i++) { + x = x.redSqr(); - if (typeof top === 'string') { - top = parseFloat(top, 10); - } - if (typeof left === 'string') { - left = parseFloat(left, 10); + if (x.cmp(rone) === 0) + return false; + if (x.cmp(rn1) === 0) + break; } - out.top += top; - out.left += left; - }); + if (i === s) + return false; + } - return out; -} + return prime; +}; -function offsetToPx(offset, size) { - if (typeof offset.left === 'string' && offset.left.indexOf('%') !== -1) { - offset.left = parseFloat(offset.left, 10) / 100 * size.width; - } - if (typeof offset.top === 'string' && offset.top.indexOf('%') !== -1) { - offset.top = parseFloat(offset.top, 10) / 100 * size.height; - } +MillerRabin.prototype.getDivisor = function getDivisor(n, k) { + var len = n.bitLength(); + var red = bn.mont(n); + var rone = new bn(1).toRed(red); - return offset; -} + if (!k) + k = Math.max(1, (len / 48) | 0); -var parseOffset = function parseOffset(value) { - var _value$split = value.split(' '); + // Find d and s, (n - 1) = (2 ^ s) * d; + var n1 = n.subn(1); + var n2 = n1.subn(1); + for (var s = 0; !n1.testn(s); s++) {} + var d = n.shrn(s); - var _value$split2 = _slicedToArray(_value$split, 2); + var rn1 = n1.toRed(red); - var top = _value$split2[0]; - var left = _value$split2[1]; + for (; k > 0; k--) { + var a = this._rand(n2); - return { top: top, left: left }; -}; -var parseAttachment = parseOffset; + var g = n.gcd(a); + if (g.cmpn(1) !== 0) + return g; -var TetherClass = (function (_Evented) { - _inherits(TetherClass, _Evented); + var x = a.toRed(red).redPow(d); + if (x.cmp(rone) === 0 || x.cmp(rn1) === 0) + continue; - function TetherClass(options) { - var _this = this; + for (var i = 1; i < s; i++) { + x = x.redSqr(); - _classCallCheck(this, TetherClass); + if (x.cmp(rone) === 0) + return x.fromRed().subn(1).gcd(n); + if (x.cmp(rn1) === 0) + break; + } - _get(Object.getPrototypeOf(TetherClass.prototype), 'constructor', this).call(this); - this.position = this.position.bind(this); + if (i === s) { + x = x.redSqr(); + return x.fromRed().subn(1).gcd(n); + } + } - tethers.push(this); + return false; +}; - this.history = []; - this.setOptions(options, false); +/***/ }), +/* 191 */ +/***/ (function(module, exports, __webpack_require__) { - _utils2['default'].modules.forEach(function (module) { - if (typeof module.initialize !== 'undefined') { - module.initialize.call(_this); - } - }); +var inherits = __webpack_require__(4); +var Reporter = __webpack_require__(53).Reporter; +var Buffer = __webpack_require__(1).Buffer; - this.position(); +function DecoderBuffer(base, options) { + Reporter.call(this, options); + if (!Buffer.isBuffer(base)) { + this.error('Input not Buffer'); + return; } - _createClass(TetherClass, [{ - key: 'getClass', - value: function getClass() { - var key = arguments.length <= 0 || arguments[0] === undefined ? '' : arguments[0]; - var classes = this.options.classes; + this.base = base; + this.offset = 0; + this.length = base.length; +} +inherits(DecoderBuffer, Reporter); +exports.DecoderBuffer = DecoderBuffer; - if (typeof classes !== 'undefined' && classes[key]) { - return this.options.classes[key]; - } else if (this.options.classPrefix) { - return this.options.classPrefix + '-' + key; - } else { - return key; - } - } - }, { - key: 'setOptions', - value: function setOptions(options) { - var _this2 = this; +DecoderBuffer.prototype.save = function save() { + return { offset: this.offset, reporter: Reporter.prototype.save.call(this) }; +}; - var pos = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1]; +DecoderBuffer.prototype.restore = function restore(save) { + // Return skipped data + var res = new DecoderBuffer(this.base); + res.offset = save.offset; + res.length = this.offset; - var defaults = { - offset: '0 0', - targetOffset: '0 0', - targetAttachment: 'auto auto', - classPrefix: 'tether' - }; + this.offset = save.offset; + Reporter.prototype.restore.call(this, save.reporter); - this.options = extend(defaults, options); + return res; +}; - var _options = this.options; - var element = _options.element; - var target = _options.target; - var targetModifier = _options.targetModifier; +DecoderBuffer.prototype.isEmpty = function isEmpty() { + return this.offset === this.length; +}; - this.element = element; - this.target = target; - this.targetModifier = targetModifier; +DecoderBuffer.prototype.readUInt8 = function readUInt8(fail) { + if (this.offset + 1 <= this.length) + return this.base.readUInt8(this.offset++, true); + else + return this.error(fail || 'DecoderBuffer overrun'); +} - if (this.target === 'viewport') { - this.target = document.body; - this.targetModifier = 'visible'; - } else if (this.target === 'scroll-handle') { - this.target = document.body; - this.targetModifier = 'scroll-handle'; - } - - ['element', 'target'].forEach(function (key) { - if (typeof _this2[key] === 'undefined') { - throw new Error('Tether Error: Both element and target must be defined'); - } - - if (typeof _this2[key].jquery !== 'undefined') { - _this2[key] = _this2[key][0]; - } else if (typeof _this2[key] === 'string') { - _this2[key] = document.querySelector(_this2[key]); - } - }); - - addClass(this.element, this.getClass('element')); - if (!(this.options.addTargetClasses === false)) { - addClass(this.target, this.getClass('target')); - } - - if (!this.options.attachment) { - throw new Error('Tether Error: You must provide an attachment'); - } - - this.targetAttachment = parseAttachment(this.options.targetAttachment); - this.attachment = parseAttachment(this.options.attachment); - this.offset = parseOffset(this.options.offset); - this.targetOffset = parseOffset(this.options.targetOffset); +DecoderBuffer.prototype.skip = function skip(bytes, fail) { + if (!(this.offset + bytes <= this.length)) + return this.error(fail || 'DecoderBuffer overrun'); - if (typeof this.scrollParents !== 'undefined') { - this.disable(); - } + var res = new DecoderBuffer(this.base); - if (this.targetModifier === 'scroll-handle') { - this.scrollParents = [this.target]; - } else { - this.scrollParents = getScrollParents(this.target); - } + // Share reporter state + res._reporterState = this._reporterState; - if (!(this.options.enabled === false)) { - this.enable(pos); - } - } - }, { - key: 'getTargetBounds', - value: function getTargetBounds() { - if (typeof this.targetModifier !== 'undefined') { - if (this.targetModifier === 'visible') { - if (this.target === document.body) { - return { top: pageYOffset, left: pageXOffset, height: innerHeight, width: innerWidth }; - } else { - var bounds = getBounds(this.target); + res.offset = this.offset; + res.length = this.offset + bytes; + this.offset += bytes; + return res; +} - var out = { - height: bounds.height, - width: bounds.width, - top: bounds.top, - left: bounds.left - }; +DecoderBuffer.prototype.raw = function raw(save) { + return this.base.slice(save ? save.offset : this.offset, this.length); +} - out.height = Math.min(out.height, bounds.height - (pageYOffset - bounds.top)); - out.height = Math.min(out.height, bounds.height - (bounds.top + bounds.height - (pageYOffset + innerHeight))); - out.height = Math.min(innerHeight, out.height); - out.height -= 2; +function EncoderBuffer(value, reporter) { + if (Array.isArray(value)) { + this.length = 0; + this.value = value.map(function(item) { + if (!(item instanceof EncoderBuffer)) + item = new EncoderBuffer(item, reporter); + this.length += item.length; + return item; + }, this); + } else if (typeof value === 'number') { + if (!(0 <= value && value <= 0xff)) + return reporter.error('non-byte EncoderBuffer value'); + this.value = value; + this.length = 1; + } else if (typeof value === 'string') { + this.value = value; + this.length = Buffer.byteLength(value); + } else if (Buffer.isBuffer(value)) { + this.value = value; + this.length = value.length; + } else { + return reporter.error('Unsupported type: ' + typeof value); + } +} +exports.EncoderBuffer = EncoderBuffer; - out.width = Math.min(out.width, bounds.width - (pageXOffset - bounds.left)); - out.width = Math.min(out.width, bounds.width - (bounds.left + bounds.width - (pageXOffset + innerWidth))); - out.width = Math.min(innerWidth, out.width); - out.width -= 2; +EncoderBuffer.prototype.join = function join(out, offset) { + if (!out) + out = new Buffer(this.length); + if (!offset) + offset = 0; - if (out.top < pageYOffset) { - out.top = pageYOffset; - } - if (out.left < pageXOffset) { - out.left = pageXOffset; - } + if (this.length === 0) + return out; - return out; - } - } else if (this.targetModifier === 'scroll-handle') { - var bounds = undefined; - var target = this.target; - if (target === document.body) { - target = document.documentElement; + if (Array.isArray(this.value)) { + this.value.forEach(function(item) { + item.join(out, offset); + offset += item.length; + }); + } else { + if (typeof this.value === 'number') + out[offset] = this.value; + else if (typeof this.value === 'string') + out.write(this.value, offset); + else if (Buffer.isBuffer(this.value)) + this.value.copy(out, offset); + offset += this.length; + } - bounds = { - left: pageXOffset, - top: pageYOffset, - height: innerHeight, - width: innerWidth - }; - } else { - bounds = getBounds(target); - } + return out; +}; - var style = getComputedStyle(target); - var hasBottomScroll = target.scrollWidth > target.clientWidth || [style.overflow, style.overflowX].indexOf('scroll') >= 0 || this.target !== document.body; +/***/ }), +/* 192 */ +/***/ (function(module, exports, __webpack_require__) { - var scrollBottom = 0; - if (hasBottomScroll) { - scrollBottom = 15; - } +var constants = exports; - var height = bounds.height - parseFloat(style.borderTopWidth) - parseFloat(style.borderBottomWidth) - scrollBottom; +// Helper +constants._reverse = function reverse(map) { + var res = {}; - var out = { - width: 15, - height: height * 0.975 * (height / target.scrollHeight), - left: bounds.left + bounds.width - parseFloat(style.borderLeftWidth) - 15 - }; + Object.keys(map).forEach(function(key) { + // Convert key to integer if it is stringified + if ((key | 0) == key) + key = key | 0; - var fitAdj = 0; - if (height < 408 && this.target === document.body) { - fitAdj = -0.00011 * Math.pow(height, 2) - 0.00727 * height + 22.58; - } + var value = map[key]; + res[value] = key; + }); - if (this.target !== document.body) { - out.height = Math.max(out.height, 24); - } + return res; +}; - var scrollPercentage = this.target.scrollTop / (target.scrollHeight - height); - out.top = scrollPercentage * (height - out.height - fitAdj) + bounds.top + parseFloat(style.borderTopWidth); +constants.der = __webpack_require__(445); - if (this.target === document.body) { - out.height = Math.max(out.height, 24); - } - return out; - } - } else { - return getBounds(this.target); - } - } - }, { - key: 'clearCache', - value: function clearCache() { - this._cache = {}; - } - }, { - key: 'cache', - value: function cache(k, getter) { - // More than one module will often need the same DOM info, so - // we keep a cache which is cleared on each position call - if (typeof this._cache === 'undefined') { - this._cache = {}; - } +/***/ }), +/* 193 */ +/***/ (function(module, exports, __webpack_require__) { - if (typeof this._cache[k] === 'undefined') { - this._cache[k] = getter.call(this); - } +var inherits = __webpack_require__(4); - return this._cache[k]; - } - }, { - key: 'enable', - value: function enable() { - var _this3 = this; +var asn1 = __webpack_require__(52); +var base = asn1.base; +var bignum = asn1.bignum; - var pos = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; +// Import DER constants +var der = asn1.constants.der; - if (!(this.options.addTargetClasses === false)) { - addClass(this.target, this.getClass('enabled')); - } - addClass(this.element, this.getClass('enabled')); - this.enabled = true; +function DERDecoder(entity) { + this.enc = 'der'; + this.name = entity.name; + this.entity = entity; - this.scrollParents.forEach(function (parent) { - if (parent !== _this3.target.ownerDocument) { - parent.addEventListener('scroll', _this3.position); - } - }); + // Construct base tree + this.tree = new DERNode(); + this.tree._init(entity.body); +}; +module.exports = DERDecoder; - if (pos) { - this.position(); - } - } - }, { - key: 'disable', - value: function disable() { - var _this4 = this; +DERDecoder.prototype.decode = function decode(data, options) { + if (!(data instanceof base.DecoderBuffer)) + data = new base.DecoderBuffer(data, options); - removeClass(this.target, this.getClass('enabled')); - removeClass(this.element, this.getClass('enabled')); - this.enabled = false; + return this.tree._decode(data, options); +}; - if (typeof this.scrollParents !== 'undefined') { - this.scrollParents.forEach(function (parent) { - parent.removeEventListener('scroll', _this4.position); - }); - } - } - }, { - key: 'destroy', - value: function destroy() { - var _this5 = this; +// Tree methods - this.disable(); +function DERNode(parent) { + base.Node.call(this, 'der', parent); +} +inherits(DERNode, base.Node); - tethers.forEach(function (tether, i) { - if (tether === _this5) { - tethers.splice(i, 1); - } - }); +DERNode.prototype._peekTag = function peekTag(buffer, tag, any) { + if (buffer.isEmpty()) + return false; - // Remove any elements we were using for convenience from the DOM - if (tethers.length === 0) { - removeUtilElements(); - } - } - }, { - key: 'updateAttachClasses', - value: function updateAttachClasses(elementAttach, targetAttach) { - var _this6 = this; + var state = buffer.save(); + var decodedTag = derDecodeTag(buffer, 'Failed to peek tag: "' + tag + '"'); + if (buffer.isError(decodedTag)) + return decodedTag; - elementAttach = elementAttach || this.attachment; - targetAttach = targetAttach || this.targetAttachment; - var sides = ['left', 'top', 'bottom', 'right', 'middle', 'center']; + buffer.restore(state); - if (typeof this._addAttachClasses !== 'undefined' && this._addAttachClasses.length) { - // updateAttachClasses can be called more than once in a position call, so - // we need to clean up after ourselves such that when the last defer gets - // ran it doesn't add any extra classes from previous calls. - this._addAttachClasses.splice(0, this._addAttachClasses.length); - } + return decodedTag.tag === tag || decodedTag.tagStr === tag || + (decodedTag.tagStr + 'of') === tag || any; +}; - if (typeof this._addAttachClasses === 'undefined') { - this._addAttachClasses = []; - } - var add = this._addAttachClasses; +DERNode.prototype._decodeTag = function decodeTag(buffer, tag, any) { + var decodedTag = derDecodeTag(buffer, + 'Failed to decode tag of "' + tag + '"'); + if (buffer.isError(decodedTag)) + return decodedTag; - if (elementAttach.top) { - add.push(this.getClass('element-attached') + '-' + elementAttach.top); - } - if (elementAttach.left) { - add.push(this.getClass('element-attached') + '-' + elementAttach.left); - } - if (targetAttach.top) { - add.push(this.getClass('target-attached') + '-' + targetAttach.top); - } - if (targetAttach.left) { - add.push(this.getClass('target-attached') + '-' + targetAttach.left); - } + var len = derDecodeLen(buffer, + decodedTag.primitive, + 'Failed to get length of "' + tag + '"'); - var all = []; - sides.forEach(function (side) { - all.push(_this6.getClass('element-attached') + '-' + side); - all.push(_this6.getClass('target-attached') + '-' + side); - }); + // Failure + if (buffer.isError(len)) + return len; - defer(function () { - if (!(typeof _this6._addAttachClasses !== 'undefined')) { - return; - } + if (!any && + decodedTag.tag !== tag && + decodedTag.tagStr !== tag && + decodedTag.tagStr + 'of' !== tag) { + return buffer.error('Failed to match tag: "' + tag + '"'); + } - updateClasses(_this6.element, _this6._addAttachClasses, all); - if (!(_this6.options.addTargetClasses === false)) { - updateClasses(_this6.target, _this6._addAttachClasses, all); - } + if (decodedTag.primitive || len !== null) + return buffer.skip(len, 'Failed to match body of: "' + tag + '"'); - delete _this6._addAttachClasses; - }); - } - }, { - key: 'position', - value: function position() { - var _this7 = this; + // Indefinite length... find END tag + var state = buffer.save(); + var res = this._skipUntilEnd( + buffer, + 'Failed to skip indefinite length body: "' + this.tag + '"'); + if (buffer.isError(res)) + return res; - var flushChanges = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; + len = buffer.offset - state.offset; + buffer.restore(state); + return buffer.skip(len, 'Failed to match body of: "' + tag + '"'); +}; - // flushChanges commits the changes immediately, leave true unless you are positioning multiple - // tethers (in which case call Tether.Utils.flush yourself when you're done) +DERNode.prototype._skipUntilEnd = function skipUntilEnd(buffer, fail) { + while (true) { + var tag = derDecodeTag(buffer, fail); + if (buffer.isError(tag)) + return tag; + var len = derDecodeLen(buffer, tag.primitive, fail); + if (buffer.isError(len)) + return len; - if (!this.enabled) { - return; - } + var res; + if (tag.primitive || len !== null) + res = buffer.skip(len) + else + res = this._skipUntilEnd(buffer, fail); - this.clearCache(); + // Failure + if (buffer.isError(res)) + return res; - // Turn 'auto' attachments into the appropriate corner or edge - var targetAttachment = autoToFixedAttachment(this.targetAttachment, this.attachment); + if (tag.tagStr === 'end') + break; + } +}; - this.updateAttachClasses(this.attachment, targetAttachment); +DERNode.prototype._decodeList = function decodeList(buffer, tag, decoder, + options) { + var result = []; + while (!buffer.isEmpty()) { + var possibleEnd = this._peekTag(buffer, 'end'); + if (buffer.isError(possibleEnd)) + return possibleEnd; - var elementPos = this.cache('element-bounds', function () { - return getBounds(_this7.element); - }); + var res = decoder.decode(buffer, 'der', options); + if (buffer.isError(res) && possibleEnd) + break; + result.push(res); + } + return result; +}; - var width = elementPos.width; - var height = elementPos.height; +DERNode.prototype._decodeStr = function decodeStr(buffer, tag) { + if (tag === 'bitstr') { + var unused = buffer.readUInt8(); + if (buffer.isError(unused)) + return unused; + return { unused: unused, data: buffer.raw() }; + } else if (tag === 'bmpstr') { + var raw = buffer.raw(); + if (raw.length % 2 === 1) + return buffer.error('Decoding of string type: bmpstr length mismatch'); - if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { - var _lastSize = this.lastSize; + var str = ''; + for (var i = 0; i < raw.length / 2; i++) { + str += String.fromCharCode(raw.readUInt16BE(i * 2)); + } + return str; + } else if (tag === 'numstr') { + var numstr = buffer.raw().toString('ascii'); + if (!this._isNumstr(numstr)) { + return buffer.error('Decoding of string type: ' + + 'numstr unsupported characters'); + } + return numstr; + } else if (tag === 'octstr') { + return buffer.raw(); + } else if (tag === 'objDesc') { + return buffer.raw(); + } else if (tag === 'printstr') { + var printstr = buffer.raw().toString('ascii'); + if (!this._isPrintstr(printstr)) { + return buffer.error('Decoding of string type: ' + + 'printstr unsupported characters'); + } + return printstr; + } else if (/str$/.test(tag)) { + return buffer.raw().toString(); + } else { + return buffer.error('Decoding of string type: ' + tag + ' unsupported'); + } +}; - // We cache the height and width to make it possible to position elements that are - // getting hidden. - width = _lastSize.width; - height = _lastSize.height; - } else { - this.lastSize = { width: width, height: height }; - } +DERNode.prototype._decodeObjid = function decodeObjid(buffer, values, relative) { + var result; + var identifiers = []; + var ident = 0; + while (!buffer.isEmpty()) { + var subident = buffer.readUInt8(); + ident <<= 7; + ident |= subident & 0x7f; + if ((subident & 0x80) === 0) { + identifiers.push(ident); + ident = 0; + } + } + if (subident & 0x80) + identifiers.push(ident); - var targetPos = this.cache('target-bounds', function () { - return _this7.getTargetBounds(); - }); - var targetSize = targetPos; + var first = (identifiers[0] / 40) | 0; + var second = identifiers[0] % 40; - // Get an actual px offset from the attachment - var offset = offsetToPx(attachmentToOffset(this.attachment), { width: width, height: height }); - var targetOffset = offsetToPx(attachmentToOffset(targetAttachment), targetSize); + if (relative) + result = identifiers; + else + result = [first, second].concat(identifiers.slice(1)); - var manualOffset = offsetToPx(this.offset, { width: width, height: height }); - var manualTargetOffset = offsetToPx(this.targetOffset, targetSize); + if (values) { + var tmp = values[result.join(' ')]; + if (tmp === undefined) + tmp = values[result.join('.')]; + if (tmp !== undefined) + result = tmp; + } - // Add the manually provided offset - offset = addOffset(offset, manualOffset); - targetOffset = addOffset(targetOffset, manualTargetOffset); + return result; +}; - // It's now our goal to make (element position + offset) == (target position + target offset) - var left = targetPos.left + targetOffset.left - offset.left; - var top = targetPos.top + targetOffset.top - offset.top; - - for (var i = 0; i < _utils2['default'].modules.length; ++i) { - var _module2 = _utils2['default'].modules[i]; - var ret = _module2.position.call(this, { - left: left, - top: top, - targetAttachment: targetAttachment, - targetPos: targetPos, - elementPos: elementPos, - offset: offset, - targetOffset: targetOffset, - manualOffset: manualOffset, - manualTargetOffset: manualTargetOffset, - scrollbarSize: scrollbarSize, - attachment: this.attachment - }); - - if (ret === false) { - return false; - } else if (typeof ret === 'undefined' || typeof ret !== 'object') { - continue; - } else { - top = ret.top; - left = ret.left; - } - } - - // We describe the position three different ways to give the optimizer - // a chance to decide the best possible way to position the element - // with the fewest repaints. - var next = { - // It's position relative to the page (absolute positioning when - // the element is a child of the body) - page: { - top: top, - left: left - }, - - // It's position relative to the viewport (fixed positioning) - viewport: { - top: top - pageYOffset, - bottom: pageYOffset - top - height + innerHeight, - left: left - pageXOffset, - right: pageXOffset - left - width + innerWidth - } - }; - - var doc = this.target.ownerDocument; - var win = doc.defaultView; +DERNode.prototype._decodeTime = function decodeTime(buffer, tag) { + var str = buffer.raw().toString(); + if (tag === 'gentime') { + var year = str.slice(0, 4) | 0; + var mon = str.slice(4, 6) | 0; + var day = str.slice(6, 8) | 0; + var hour = str.slice(8, 10) | 0; + var min = str.slice(10, 12) | 0; + var sec = str.slice(12, 14) | 0; + } else if (tag === 'utctime') { + var year = str.slice(0, 2) | 0; + var mon = str.slice(2, 4) | 0; + var day = str.slice(4, 6) | 0; + var hour = str.slice(6, 8) | 0; + var min = str.slice(8, 10) | 0; + var sec = str.slice(10, 12) | 0; + if (year < 70) + year = 2000 + year; + else + year = 1900 + year; + } else { + return buffer.error('Decoding ' + tag + ' time is not supported yet'); + } - var scrollbarSize = undefined; - if (doc.body.scrollWidth > win.innerWidth) { - scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); - next.viewport.bottom -= scrollbarSize.height; - } + return Date.UTC(year, mon - 1, day, hour, min, sec, 0); +}; - if (doc.body.scrollHeight > win.innerHeight) { - scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); - next.viewport.right -= scrollbarSize.width; - } +DERNode.prototype._decodeNull = function decodeNull(buffer) { + return null; +}; - if (['', 'static'].indexOf(doc.body.style.position) === -1 || ['', 'static'].indexOf(doc.body.parentElement.style.position) === -1) { - // Absolute positioning in the body will be relative to the page, not the 'initial containing block' - next.page.bottom = doc.body.scrollHeight - top - height; - next.page.right = doc.body.scrollWidth - left - width; - } +DERNode.prototype._decodeBool = function decodeBool(buffer) { + var res = buffer.readUInt8(); + if (buffer.isError(res)) + return res; + else + return res !== 0; +}; - if (typeof this.options.optimizations !== 'undefined' && this.options.optimizations.moveElement !== false && !(typeof this.targetModifier !== 'undefined')) { - (function () { - var offsetParent = _this7.cache('target-offsetparent', function () { - return getOffsetParent(_this7.target); - }); - var offsetPosition = _this7.cache('target-offsetparent-bounds', function () { - return getBounds(offsetParent); - }); - var offsetParentStyle = getComputedStyle(offsetParent); - var offsetParentSize = offsetPosition; +DERNode.prototype._decodeInt = function decodeInt(buffer, values) { + // Bigint, return as it is (assume big endian) + var raw = buffer.raw(); + var res = new bignum(raw); - var offsetBorder = {}; - ['Top', 'Left', 'Bottom', 'Right'].forEach(function (side) { - offsetBorder[side.toLowerCase()] = parseFloat(offsetParentStyle['border' + side + 'Width']); - }); + if (values) + res = values[res.toString(10)] || res; - offsetPosition.right = doc.body.scrollWidth - offsetPosition.left - offsetParentSize.width + offsetBorder.right; - offsetPosition.bottom = doc.body.scrollHeight - offsetPosition.top - offsetParentSize.height + offsetBorder.bottom; + return res; +}; - if (next.page.top >= offsetPosition.top + offsetBorder.top && next.page.bottom >= offsetPosition.bottom) { - if (next.page.left >= offsetPosition.left + offsetBorder.left && next.page.right >= offsetPosition.right) { - // We're within the visible part of the target's scroll parent - var scrollTop = offsetParent.scrollTop; - var scrollLeft = offsetParent.scrollLeft; +DERNode.prototype._use = function use(entity, obj) { + if (typeof entity === 'function') + entity = entity(obj); + return entity._getDecoder('der').tree; +}; - // It's position relative to the target's offset parent (absolute positioning when - // the element is moved to be a child of the target's offset parent). - next.offset = { - top: next.page.top - offsetPosition.top + scrollTop - offsetBorder.top, - left: next.page.left - offsetPosition.left + scrollLeft - offsetBorder.left - }; - } - } - })(); - } +// Utility methods - // We could also travel up the DOM and try each containing context, rather than only - // looking at the body, but we're gonna get diminishing returns. +function derDecodeTag(buf, fail) { + var tag = buf.readUInt8(fail); + if (buf.isError(tag)) + return tag; - this.move(next); + var cls = der.tagClass[tag >> 6]; + var primitive = (tag & 0x20) === 0; - this.history.unshift(next); + // Multi-octet tag - load + if ((tag & 0x1f) === 0x1f) { + var oct = tag; + tag = 0; + while ((oct & 0x80) === 0x80) { + oct = buf.readUInt8(fail); + if (buf.isError(oct)) + return oct; - if (this.history.length > 3) { - this.history.pop(); - } + tag <<= 7; + tag |= oct & 0x7f; + } + } else { + tag &= 0x1f; + } + var tagStr = der.tag[tag]; - if (flushChanges) { - flush(); - } + return { + cls: cls, + primitive: primitive, + tag: tag, + tagStr: tagStr + }; +} - return true; - } +function derDecodeLen(buf, primitive, fail) { + var len = buf.readUInt8(fail); + if (buf.isError(len)) + return len; - // THE ISSUE - }, { - key: 'move', - value: function move(pos) { - var _this8 = this; + // Indefinite form + if (!primitive && len === 0x80) + return null; - if (!(typeof this.element.parentNode !== 'undefined')) { - return; - } + // Definite form + if ((len & 0x80) === 0) { + // Short form + return len; + } - var same = {}; + // Long form + var num = len & 0x7f; + if (num > 4) + return buf.error('length octect is too long'); - for (var type in pos) { - same[type] = {}; + len = 0; + for (var i = 0; i < num; i++) { + len <<= 8; + var j = buf.readUInt8(fail); + if (buf.isError(j)) + return j; + len |= j; + } - for (var key in pos[type]) { - var found = false; + return len; +} - for (var i = 0; i < this.history.length; ++i) { - var point = this.history[i]; - if (typeof point[type] !== 'undefined' && !within(point[type][key], pos[type][key])) { - found = true; - break; - } - } - if (!found) { - same[type][key] = true; - } - } - } +/***/ }), +/* 194 */ +/***/ (function(module, exports, __webpack_require__) { - var css = { top: '', left: '', right: '', bottom: '' }; +var inherits = __webpack_require__(4); +var Buffer = __webpack_require__(1).Buffer; - var transcribe = function transcribe(_same, _pos) { - var hasOptimizations = typeof _this8.options.optimizations !== 'undefined'; - var gpu = hasOptimizations ? _this8.options.optimizations.gpu : null; - if (gpu !== false) { - var yPos = undefined, - xPos = undefined; - if (_same.top) { - css.top = 0; - yPos = _pos.top; - } else { - css.bottom = 0; - yPos = -_pos.bottom; - } +var asn1 = __webpack_require__(52); +var base = asn1.base; - if (_same.left) { - css.left = 0; - xPos = _pos.left; - } else { - css.right = 0; - xPos = -_pos.right; - } +// Import DER constants +var der = asn1.constants.der; - css[transformKey] = 'translateX(' + Math.round(xPos) + 'px) translateY(' + Math.round(yPos) + 'px)'; +function DEREncoder(entity) { + this.enc = 'der'; + this.name = entity.name; + this.entity = entity; - if (transformKey !== 'msTransform') { - // The Z transform will keep this in the GPU (faster, and prevents artifacts), - // but IE9 doesn't support 3d transforms and will choke. - css[transformKey] += " translateZ(0)"; - } - } else { - if (_same.top) { - css.top = _pos.top + 'px'; - } else { - css.bottom = _pos.bottom + 'px'; - } + // Construct base tree + this.tree = new DERNode(); + this.tree._init(entity.body); +}; +module.exports = DEREncoder; - if (_same.left) { - css.left = _pos.left + 'px'; - } else { - css.right = _pos.right + 'px'; - } - } - }; +DEREncoder.prototype.encode = function encode(data, reporter) { + return this.tree._encode(data, reporter).join(); +}; - var moved = false; - if ((same.page.top || same.page.bottom) && (same.page.left || same.page.right)) { - css.position = 'absolute'; - transcribe(same.page, pos.page); - } else if ((same.viewport.top || same.viewport.bottom) && (same.viewport.left || same.viewport.right)) { - css.position = 'fixed'; - transcribe(same.viewport, pos.viewport); - } else if (typeof same.offset !== 'undefined' && same.offset.top && same.offset.left) { - (function () { - css.position = 'absolute'; - var offsetParent = _this8.cache('target-offsetparent', function () { - return getOffsetParent(_this8.target); - }); +// Tree methods - if (getOffsetParent(_this8.element) !== offsetParent) { - defer(function () { - _this8.element.parentNode.removeChild(_this8.element); - offsetParent.appendChild(_this8.element); - }); - } +function DERNode(parent) { + base.Node.call(this, 'der', parent); +} +inherits(DERNode, base.Node); - transcribe(same.offset, pos.offset); - moved = true; - })(); - } else { - css.position = 'absolute'; - transcribe({ top: true, left: true }, pos.page); - } +DERNode.prototype._encodeComposite = function encodeComposite(tag, + primitive, + cls, + content) { + var encodedTag = encodeTag(tag, primitive, cls, this.reporter); - if (!moved) { - var offsetParentIsBody = true; - var currentNode = this.element.parentNode; - while (currentNode && currentNode.nodeType === 1 && currentNode.tagName !== 'BODY') { - if (getComputedStyle(currentNode).position !== 'static') { - offsetParentIsBody = false; - break; - } + // Short form + if (content.length < 0x80) { + var header = new Buffer(2); + header[0] = encodedTag; + header[1] = content.length; + return this._createEncoderBuffer([ header, content ]); + } - currentNode = currentNode.parentNode; - } + // Long form + // Count octets required to store length + var lenOctets = 1; + for (var i = content.length; i >= 0x100; i >>= 8) + lenOctets++; - if (!offsetParentIsBody) { - this.element.parentNode.removeChild(this.element); - this.element.ownerDocument.body.appendChild(this.element); - } - } + var header = new Buffer(1 + 1 + lenOctets); + header[0] = encodedTag; + header[1] = 0x80 | lenOctets; - // Any css change will trigger a repaint, so let's avoid one if nothing changed - var writeCSS = {}; - var write = false; - for (var key in css) { - var val = css[key]; - var elVal = this.element.style[key]; + for (var i = 1 + lenOctets, j = content.length; j > 0; i--, j >>= 8) + header[i] = j & 0xff; - if (elVal !== val) { - write = true; - writeCSS[key] = val; - } - } + return this._createEncoderBuffer([ header, content ]); +}; - if (write) { - defer(function () { - extend(_this8.element.style, writeCSS); - _this8.trigger('repositioned'); - }); - } +DERNode.prototype._encodeStr = function encodeStr(str, tag) { + if (tag === 'bitstr') { + return this._createEncoderBuffer([ str.unused | 0, str.data ]); + } else if (tag === 'bmpstr') { + var buf = new Buffer(str.length * 2); + for (var i = 0; i < str.length; i++) { + buf.writeUInt16BE(str.charCodeAt(i), i * 2); } - }]); + return this._createEncoderBuffer(buf); + } else if (tag === 'numstr') { + if (!this._isNumstr(str)) { + return this.reporter.error('Encoding of string type: numstr supports ' + + 'only digits and space'); + } + return this._createEncoderBuffer(str); + } else if (tag === 'printstr') { + if (!this._isPrintstr(str)) { + return this.reporter.error('Encoding of string type: printstr supports ' + + 'only latin upper and lower case letters, ' + + 'digits, space, apostrophe, left and rigth ' + + 'parenthesis, plus sign, comma, hyphen, ' + + 'dot, slash, colon, equal sign, ' + + 'question mark'); + } + return this._createEncoderBuffer(str); + } else if (/str$/.test(tag)) { + return this._createEncoderBuffer(str); + } else if (tag === 'objDesc') { + return this._createEncoderBuffer(str); + } else { + return this.reporter.error('Encoding of string type: ' + tag + + ' unsupported'); + } +}; - return TetherClass; -})(Evented); +DERNode.prototype._encodeObjid = function encodeObjid(id, values, relative) { + if (typeof id === 'string') { + if (!values) + return this.reporter.error('string objid given, but no values map found'); + if (!values.hasOwnProperty(id)) + return this.reporter.error('objid not found in values map'); + id = values[id].split(/[\s\.]+/g); + for (var i = 0; i < id.length; i++) + id[i] |= 0; + } else if (Array.isArray(id)) { + id = id.slice(); + for (var i = 0; i < id.length; i++) + id[i] |= 0; + } -TetherClass.modules = []; + if (!Array.isArray(id)) { + return this.reporter.error('objid() should be either array or string, ' + + 'got: ' + JSON.stringify(id)); + } -_utils2['default'].position = position; + if (!relative) { + if (id[1] >= 40) + return this.reporter.error('Second objid identifier OOB'); + id.splice(0, 2, id[0] * 40 + id[1]); + } -var Tether = extend(TetherClass, _utils2['default']); + // Count number of octets + var size = 0; + for (var i = 0; i < id.length; i++) { + var ident = id[i]; + for (size++; ident >= 0x80; ident >>= 7) + size++; + } -exports['default'] = Tether; -module.exports = exports['default']; + var objid = new Buffer(size); + var offset = objid.length - 1; + for (var i = id.length - 1; i >= 0; i--) { + var ident = id[i]; + objid[offset--] = ident & 0x7f; + while ((ident >>= 7) > 0) + objid[offset--] = 0x80 | (ident & 0x7f); + } -},{"./abutment":1,"./constraint":2,"./shift":3,"./utils":5}],5:[function(require,module,exports){ -'use strict'; + return this._createEncoderBuffer(objid); +}; -Object.defineProperty(exports, '__esModule', { - value: true -}); +function two(num) { + if (num < 10) + return '0' + num; + else + return num; +} -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); +DERNode.prototype._encodeTime = function encodeTime(time, tag) { + var str; + var date = new Date(time); -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } + if (tag === 'gentime') { + str = [ + two(date.getFullYear()), + two(date.getUTCMonth() + 1), + two(date.getUTCDate()), + two(date.getUTCHours()), + two(date.getUTCMinutes()), + two(date.getUTCSeconds()), + 'Z' + ].join(''); + } else if (tag === 'utctime') { + str = [ + two(date.getFullYear() % 100), + two(date.getUTCMonth() + 1), + two(date.getUTCDate()), + two(date.getUTCHours()), + two(date.getUTCMinutes()), + two(date.getUTCSeconds()), + 'Z' + ].join(''); + } else { + this.reporter.error('Encoding ' + tag + ' time is not supported yet'); + } -var TetherBase = { modules: [] }; + return this._encodeStr(str, 'octstr'); +}; -var zeroElement = null; +DERNode.prototype._encodeNull = function encodeNull() { + return this._createEncoderBuffer(''); +}; -// Same as native getBoundingClientRect, except it takes into account parent <frame> offsets -// if the element lies within a nested document (<frame> or <iframe>-like). -function getActualBoundingClientRect(node) { - var boundingRect = node.getBoundingClientRect(); - - // The original object returned by getBoundingClientRect is immutable, so we clone it - // We can't use extend because the properties are not considered part of the object by hasOwnProperty in IE9 - var rect = {}; - for (var k in boundingRect) { - rect[k] = boundingRect[k]; +DERNode.prototype._encodeInt = function encodeInt(num, values) { + if (typeof num === 'string') { + if (!values) + return this.reporter.error('String int or enum given, but no values map'); + if (!values.hasOwnProperty(num)) { + return this.reporter.error('Values map doesn\'t contain: ' + + JSON.stringify(num)); + } + num = values[num]; } - if (node.ownerDocument !== document) { - var _frameElement = node.ownerDocument.defaultView.frameElement; - if (_frameElement) { - var frameRect = getActualBoundingClientRect(_frameElement); - rect.top += frameRect.top; - rect.bottom += frameRect.top; - rect.left += frameRect.left; - rect.right += frameRect.left; + // Bignum, assume big endian + if (typeof num !== 'number' && !Buffer.isBuffer(num)) { + var numArray = num.toArray(); + if (!num.sign && numArray[0] & 0x80) { + numArray.unshift(0); } + num = new Buffer(numArray); } - return rect; -} - -function getScrollParents(el) { - // In firefox if the el is inside an iframe with display: none; window.getComputedStyle() will return null; - // https://bugzilla.mozilla.org/show_bug.cgi?id=548397 - var computedStyle = getComputedStyle(el) || {}; - var position = computedStyle.position; - var parents = []; + if (Buffer.isBuffer(num)) { + var size = num.length; + if (num.length === 0) + size++; - if (position === 'fixed') { - return [el]; + var out = new Buffer(size); + num.copy(out); + if (num.length === 0) + out[0] = 0 + return this._createEncoderBuffer(out); } - var parent = el; - while ((parent = parent.parentNode) && parent && parent.nodeType === 1) { - var style = undefined; - try { - style = getComputedStyle(parent); - } catch (err) {} + if (num < 0x80) + return this._createEncoderBuffer(num); - if (typeof style === 'undefined' || style === null) { - parents.push(parent); - return parents; - } + if (num < 0x100) + return this._createEncoderBuffer([0, num]); - var _style = style; - var overflow = _style.overflow; - var overflowX = _style.overflowX; - var overflowY = _style.overflowY; + var size = 1; + for (var i = num; i >= 0x100; i >>= 8) + size++; - if (/(auto|scroll)/.test(overflow + overflowY + overflowX)) { - if (position !== 'absolute' || ['relative', 'absolute', 'fixed'].indexOf(style.position) >= 0) { - parents.push(parent); - } - } + var out = new Array(size); + for (var i = out.length - 1; i >= 0; i--) { + out[i] = num & 0xff; + num >>= 8; + } + if(out[0] & 0x80) { + out.unshift(0); } - parents.push(el.ownerDocument.body); + return this._createEncoderBuffer(new Buffer(out)); +}; - // If the node is within a frame, account for the parent window scroll - if (el.ownerDocument !== document) { - parents.push(el.ownerDocument.defaultView); - } +DERNode.prototype._encodeBool = function encodeBool(value) { + return this._createEncoderBuffer(value ? 0xff : 0); +}; - return parents; -} +DERNode.prototype._use = function use(entity, obj) { + if (typeof entity === 'function') + entity = entity(obj); + return entity._getEncoder('der').tree; +}; -var uniqueId = (function () { - var id = 0; - return function () { - return ++id; - }; -})(); +DERNode.prototype._skipDefault = function skipDefault(dataBuffer, reporter, parent) { + var state = this._baseState; + var i; + if (state['default'] === null) + return false; -var zeroPosCache = {}; -var getOrigin = function getOrigin() { - // getBoundingClientRect is unfortunately too accurate. It introduces a pixel or two of - // jitter as the user scrolls that messes with our ability to detect if two positions - // are equivilant or not. We place an element at the top left of the page that will - // get the same jitter, so we can cancel the two out. - var node = zeroElement; - if (!node) { - node = document.createElement('div'); - node.setAttribute('data-tether-id', uniqueId()); - extend(node.style, { - top: 0, - left: 0, - position: 'absolute' - }); + var data = dataBuffer.join(); + if (state.defaultBuffer === undefined) + state.defaultBuffer = this._encodeValue(state['default'], reporter, parent).join(); - document.body.appendChild(node); + if (data.length !== state.defaultBuffer.length) + return false; - zeroElement = node; - } + for (i=0; i < data.length; i++) + if (data[i] !== state.defaultBuffer[i]) + return false; - var id = node.getAttribute('data-tether-id'); - if (typeof zeroPosCache[id] === 'undefined') { - zeroPosCache[id] = getActualBoundingClientRect(node); + return true; +}; - // Clear the cache when this position call is done - defer(function () { - delete zeroPosCache[id]; - }); - } +// Utility methods - return zeroPosCache[id]; +function encodeTag(tag, primitive, cls, reporter) { + var res; + + if (tag === 'seqof') + tag = 'seq'; + else if (tag === 'setof') + tag = 'set'; + + if (der.tagByName.hasOwnProperty(tag)) + res = der.tagByName[tag]; + else if (typeof tag === 'number' && (tag | 0) === tag) + res = tag; + else + return reporter.error('Unknown tag: ' + tag); + + if (res >= 0x1f) + return reporter.error('Multi-octet tag encoding unsupported'); + + if (!primitive) + res |= 0x20; + + res |= (der.tagClassByName[cls || 'universal'] << 6); + + return res; +} + + +/***/ }), +/* 195 */ +/***/ (function(module, exports) { + +module.exports = { + "1.3.132.0.10": "secp256k1", + "1.3.132.0.33": "p224", + "1.2.840.10045.3.1.1": "p192", + "1.2.840.10045.3.1.7": "p256", + "1.3.132.0.34": "p384", + "1.3.132.0.35": "p521" }; -function removeUtilElements() { - if (zeroElement) { - document.body.removeChild(zeroElement); +/***/ }), +/* 196 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(Buffer) {var createHash = __webpack_require__(27); +module.exports = function (seed, len) { + var t = new Buffer(''); + var i = 0, c; + while (t.length < len) { + c = i2ops(i++); + t = Buffer.concat([t, createHash('sha1').update(seed).update(c).digest()]); } - zeroElement = null; + return t.slice(0, len); }; -function getBounds(el) { - var doc = undefined; - if (el === document) { - doc = document; - el = document.documentElement; - } else { - doc = el.ownerDocument; +function i2ops(c) { + var out = new Buffer(4); + out.writeUInt32BE(c,0); + return out; +} +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) + +/***/ }), +/* 197 */ +/***/ (function(module, exports) { + +module.exports = function xor(a, b) { + var len = a.length; + var i = -1; + while (++i < len) { + a[i] ^= b[i]; } + return a +}; - var docEl = doc.documentElement; +/***/ }), +/* 198 */ +/***/ (function(module, exports, __webpack_require__) { - var box = getActualBoundingClientRect(el); +/* WEBPACK VAR INJECTION */(function(Buffer) {var bn = __webpack_require__(11); +function withPublic(paddedMsg, key) { + return new Buffer(paddedMsg + .toRed(bn.mont(key.modulus)) + .redPow(new bn(key.publicExponent)) + .fromRed() + .toArray()); +} - var origin = getOrigin(); +module.exports = withPublic; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - box.top -= origin.top; - box.left -= origin.left; +/***/ }), +/* 199 */ +/***/ (function(module, exports, __webpack_require__) { - if (typeof box.width === 'undefined') { - box.width = document.body.scrollWidth - box.left - box.right; +/* WEBPACK VAR INJECTION */(function(Buffer) { + +// https://github.com/bitcoinjs/bitcoinjs-lib/issues/14 +function numToBytes(num, bytes) { + if (bytes == 0) return [];else return [num % 256].concat(numToBytes(Math.floor(num / 256), bytes - 1)); +} + +function numToVarInt(num) { + var b; + if (num < 253) b = [num];else if (num < 65536) b = [253].concat(numToBytes(num, 2));else if (num < 4294967296) b = [254].concat(numToBytes(num, 4));else b = [253].concat(numToBytes(num, 8)); + return Buffer.from(b).toString('hex'); +} + +// https://github.com/feross/buffer/blob/master/index.js#L1127 +function verifuint(value, max) { + if (typeof value !== 'number') { + throw new Error('cannot write a non-number as a number'); } - if (typeof box.height === 'undefined') { - box.height = document.body.scrollHeight - box.top - box.bottom; + if (value < 0) { + throw new Error('specified a negative value for writing an unsigned value'); + } + if (value > max) throw new Error('RangeError: value out of range'); + if (Math.floor(value) !== value) { + throw new Error('value has a fractional component'); } +} - box.top = box.top - docEl.clientTop; - box.left = box.left - docEl.clientLeft; - box.right = doc.body.clientWidth - box.width - box.left; - box.bottom = doc.body.clientHeight - box.height - box.top; +function readUInt64LE(buffer, offset) { + var a = buffer.readUInt32LE(offset); + var b = buffer.readUInt32LE(offset + 4); + b *= 0x100000000; - return box; + verifuint(b + a, 0x001fffffffffffff); + + return b + a; } -function getOffsetParent(el) { - return el.offsetParent || document.documentElement; +function writeUInt64LE(buffer, value, offset) { + verifuint(value, 0x001fffffffffffff); + + buffer.writeInt32LE(value & -1, offset); + buffer.writeUInt32LE(Math.floor(value / 0x100000000), offset + 4); + return offset + 8; } -function getScrollBarSize() { - var inner = document.createElement('div'); - inner.style.width = '100%'; - inner.style.height = '200px'; +/* + * Given a hex string, get the length of it in bytes + * ** NOT string.length, but convert it into bytes + * and return the length of that in bytes in hex + * @param {String} hexStr + * return {String} Length of hexStr in bytes + */ +function getStringBufferLength(hexStr) { + const _tmpBuf = Buffer.from(hexStr, 'hex').length; + return Buffer.from([_tmpBuf]).toString('hex'); +} - var outer = document.createElement('div'); - extend(outer.style, { - position: 'absolute', - top: 0, - left: 0, - pointerEvents: 'none', - visibility: 'hidden', - width: '200px', - height: '150px', - overflow: 'hidden' - }); +module.exports = { + readUInt64LE: readUInt64LE, + writeUInt64LE: writeUInt64LE, + getStringBufferLength: getStringBufferLength, + numToVarInt: numToVarInt, + numToBytes: numToBytes +}; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - outer.appendChild(inner); +/***/ }), +/* 200 */ +/***/ (function(module, exports, __webpack_require__) { - document.body.appendChild(outer); +module.exports = { + Block: __webpack_require__(465), + ECPair: __webpack_require__(113), + ECSignature: __webpack_require__(115), + HDNode: __webpack_require__(493), + Transaction: __webpack_require__(112), + TransactionBuilder: __webpack_require__(494), - var widthContained = inner.offsetWidth; - outer.style.overflow = 'scroll'; - var widthScroll = inner.offsetWidth; + address: __webpack_require__(114), + bufferutils: __webpack_require__(206), // TODO: remove in 4.0.0 + crypto: __webpack_require__(44), + networks: __webpack_require__(54), + opcodes: __webpack_require__(16), + script: __webpack_require__(14) +} - if (widthContained === widthScroll) { - widthScroll = outer.clientWidth; - } - document.body.removeChild(outer); +/***/ }), +/* 201 */ +/***/ (function(module, exports, __webpack_require__) { - var width = widthContained - widthScroll; +var inherits = __webpack_require__(4) +var native = __webpack_require__(111) - return { width: width, height: width }; -} +function TfTypeError (type, value, valueTypeName) { + this.__error = Error.call(this) + this.__type = type + this.__value = value + this.__valueTypeName = valueTypeName -function extend() { - var out = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0]; + var message + Object.defineProperty(this, 'message', { + enumerable: true, + get: function () { + if (message) return message - var args = []; + valueTypeName = valueTypeName || getValueTypeName(value) + message = tfErrorString(type, value, valueTypeName) - Array.prototype.push.apply(args, arguments); + return message + } + }) +} - args.slice(1).forEach(function (obj) { - if (obj) { - for (var key in obj) { - if (({}).hasOwnProperty.call(obj, key)) { - out[key] = obj[key]; - } +function TfPropertyTypeError (type, property, label, value, error, valueTypeName) { + this.__error = error || Error.call(this) + this.__label = label + this.__property = property + this.__type = type + this.__value = value + this.__valueTypeName = valueTypeName + + var message + Object.defineProperty(this, 'message', { + enumerable: true, + get: function () { + if (message) return message + if (type) { + valueTypeName = valueTypeName || getValueTypeName(value) + message = tfPropertyErrorString(type, label, property, value, valueTypeName) + } else { + message = 'Unexpected property "' + property + '"' } + + return message } - }); + }) +} - return out; +// inherit from Error, assign stack +[TfTypeError, TfPropertyTypeError].forEach(function (tfErrorType) { + inherits(tfErrorType, Error) + Object.defineProperty(tfErrorType, 'stack', { + get: function () { return this.__error.stack } + }) +}) + +function tfCustomError (expected, actual) { + return new TfTypeError(expected, {}, actual) } -function removeClass(el, name) { - if (typeof el.classList !== 'undefined') { - name.split(' ').forEach(function (cls) { - if (cls.trim()) { - el.classList.remove(cls); - } - }); - } else { - var regex = new RegExp('(^| )' + name.split(' ').join('|') + '( |$)', 'gi'); - var className = getClassName(el).replace(regex, ' '); - setClassName(el, className); +function tfSubError (e, property, label) { + // sub child? + if (e instanceof TfPropertyTypeError) { + property = property + '.' + e.__property + label = e.__label + + return new TfPropertyTypeError( + e.__type, property, label, e.__value, e.__error, e.__valueTypeName + ) } -} -function addClass(el, name) { - if (typeof el.classList !== 'undefined') { - name.split(' ').forEach(function (cls) { - if (cls.trim()) { - el.classList.add(cls); - } - }); - } else { - removeClass(el, name); - var cls = getClassName(el) + (' ' + name); - setClassName(el, cls); + // child? + if (e instanceof TfTypeError) { + return new TfPropertyTypeError( + e.__type, property, label, e.__value, e.__error, e.__valueTypeName + ) } + + return e } -function hasClass(el, name) { - if (typeof el.classList !== 'undefined') { - return el.classList.contains(name); - } - var className = getClassName(el); - return new RegExp('(^| )' + name + '( |$)', 'gi').test(className); +function getTypeName (fn) { + return fn.name || fn.toString().match(/function (.*?)\s*\(/)[1] } -function getClassName(el) { - // Can't use just SVGAnimatedString here since nodes within a Frame in IE have - // completely separately SVGAnimatedString base classes - if (el.className instanceof el.ownerDocument.defaultView.SVGAnimatedString) { - return el.className.baseVal; - } - return el.className; +function getValueTypeName (value) { + return native.Nil(value) ? '' : getTypeName(value.constructor) } -function setClassName(el, className) { - el.setAttribute('class', className); +function getValue (value) { + if (native.Function(value)) return '' + if (native.String(value)) return JSON.stringify(value) + if (value && native.Object(value)) return '' + return value } -function updateClasses(el, add, all) { - // Of the set of 'all' classes, we need the 'add' classes, and only the - // 'add' classes to be set. - all.forEach(function (cls) { - if (add.indexOf(cls) === -1 && hasClass(el, cls)) { - removeClass(el, cls); - } - }); +function tfJSON (type) { + if (native.Function(type)) return type.toJSON ? type.toJSON() : getTypeName(type) + if (native.Array(type)) return 'Array' + if (type && native.Object(type)) return 'Object' - add.forEach(function (cls) { - if (!hasClass(el, cls)) { - addClass(el, cls); - } - }); + return type !== undefined ? type : '' } -var deferred = []; +function tfErrorString (type, value, valueTypeName) { + var valueJson = getValue(value) -var defer = function defer(fn) { - deferred.push(fn); -}; + return 'Expected ' + tfJSON(type) + ', got' + + (valueTypeName !== '' ? ' ' + valueTypeName : '') + + (valueJson !== '' ? ' ' + valueJson : '') +} -var flush = function flush() { - var fn = undefined; - while (fn = deferred.pop()) { - fn(); - } -}; +function tfPropertyErrorString (type, label, name, value, valueTypeName) { + var description = '" of type ' + if (label === 'key') description = '" with key type ' -var Evented = (function () { - function Evented() { - _classCallCheck(this, Evented); - } + return tfErrorString('property "' + tfJSON(name) + description + tfJSON(type), value, valueTypeName) +} - _createClass(Evented, [{ - key: 'on', - value: function on(event, handler, ctx) { - var once = arguments.length <= 3 || arguments[3] === undefined ? false : arguments[3]; +module.exports = { + TfTypeError: TfTypeError, + TfPropertyTypeError: TfPropertyTypeError, + tfCustomError: tfCustomError, + tfSubError: tfSubError, + tfJSON: tfJSON, + getValueTypeName: getValueTypeName +} - if (typeof this.bindings === 'undefined') { - this.bindings = {}; - } - if (typeof this.bindings[event] === 'undefined') { - this.bindings[event] = []; - } - this.bindings[event].push({ handler: handler, ctx: ctx, once: once }); - } - }, { - key: 'once', - value: function once(event, handler, ctx) { - this.on(event, handler, ctx, true); - } - }, { - key: 'off', - value: function off(event, handler) { - if (typeof this.bindings === 'undefined' || typeof this.bindings[event] === 'undefined') { - return; - } - if (typeof handler === 'undefined') { - delete this.bindings[event]; - } else { - var i = 0; - while (i < this.bindings[event].length) { - if (this.bindings[event][i].handler === handler) { - this.bindings[event].splice(i, 1); - } else { - ++i; - } - } - } - } - }, { - key: 'trigger', - value: function trigger(event) { - if (typeof this.bindings !== 'undefined' && this.bindings[event]) { - var i = 0; +/***/ }), +/* 202 */ +/***/ (function(module, exports, __webpack_require__) { - for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { - args[_key - 1] = arguments[_key]; - } +var OPS = __webpack_require__(16) - while (i < this.bindings[event].length) { - var _bindings$event$i = this.bindings[event][i]; - var handler = _bindings$event$i.handler; - var ctx = _bindings$event$i.ctx; - var once = _bindings$event$i.once; +function encodingLength (i) { + return i < OPS.OP_PUSHDATA1 ? 1 + : i <= 0xff ? 2 + : i <= 0xffff ? 3 + : 5 +} - var context = ctx; - if (typeof context === 'undefined') { - context = this; - } +function encode (buffer, number, offset) { + var size = encodingLength(number) - handler.apply(context, args); + // ~6 bit + if (size === 1) { + buffer.writeUInt8(number, offset) - if (once) { - this.bindings[event].splice(i, 1); - } else { - ++i; - } - } - } - } - }]); + // 8 bit + } else if (size === 2) { + buffer.writeUInt8(OPS.OP_PUSHDATA1, offset) + buffer.writeUInt8(number, offset + 1) - return Evented; -})(); + // 16 bit + } else if (size === 3) { + buffer.writeUInt8(OPS.OP_PUSHDATA2, offset) + buffer.writeUInt16LE(number, offset + 1) -TetherBase.Utils = { - getActualBoundingClientRect: getActualBoundingClientRect, - getScrollParents: getScrollParents, - getBounds: getBounds, - getOffsetParent: getOffsetParent, - extend: extend, - addClass: addClass, - removeClass: removeClass, - hasClass: hasClass, - updateClasses: updateClasses, - defer: defer, - flush: flush, - uniqueId: uniqueId, - Evented: Evented, - getScrollBarSize: getScrollBarSize, - removeUtilElements: removeUtilElements -}; + // 32 bit + } else { + buffer.writeUInt8(OPS.OP_PUSHDATA4, offset) + buffer.writeUInt32LE(number, offset + 1) + } -exports['default'] = TetherBase; -module.exports = exports['default']; + return size +} -},{}]},{},[4])(4) -}); +function decode (buffer, offset) { + var opcode = buffer.readUInt8(offset) + var number, size -/***/ }), -/* 225 */ -/***/ (function(module, exports) { + // ~6 bit + if (opcode < OPS.OP_PUSHDATA1) { + number = opcode + size = 1 -/** - * lodash (Custom Build) <https://lodash.com/> - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors <https://jquery.org/> - * Released under MIT license <https://lodash.com/license> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */ + // 8 bit + } else if (opcode === OPS.OP_PUSHDATA1) { + if (offset + 2 > buffer.length) return null + number = buffer.readUInt8(offset + 1) + size = 2 -/** Used as references for various `Number` constants. */ -var NAN = 0 / 0; + // 16 bit + } else if (opcode === OPS.OP_PUSHDATA2) { + if (offset + 3 > buffer.length) return null + number = buffer.readUInt16LE(offset + 1) + size = 3 -/** `Object#toString` result references. */ -var symbolTag = '[object Symbol]'; + // 32 bit + } else { + if (offset + 5 > buffer.length) return null + if (opcode !== OPS.OP_PUSHDATA4) throw new Error('Unexpected opcode') -/** Used to match leading and trailing whitespace. */ -var reTrim = /^\s+|\s+$/g; + number = buffer.readUInt32LE(offset + 1) + size = 5 + } -/** Used to detect bad signed hexadecimal string values. */ -var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; + return { + opcode: opcode, + number: number, + size: size + } +} -/** Used to detect binary string values. */ -var reIsBinary = /^0b[01]+$/i; +module.exports = { + encodingLength: encodingLength, + encode: encode, + decode: decode +} -/** Used to detect octal string values. */ -var reIsOctal = /^0o[0-7]+$/i; -/** Built-in method references without a dependency on `root`. */ -var freeParseInt = parseInt; +/***/ }), +/* 203 */ +/***/ (function(module, exports, __webpack_require__) { -/** Used for built-in method references. */ -var objectProto = Object.prototype; +var Buffer = __webpack_require__(7).Buffer -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; +function decode (buffer, maxLength, minimal) { + maxLength = maxLength || 4 + minimal = minimal === undefined ? true : minimal -/** - * Checks if `value` is the - * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) - * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} + var length = buffer.length + if (length === 0) return 0 + if (length > maxLength) throw new TypeError('Script number overflow') + if (minimal) { + if ((buffer[length - 1] & 0x7f) === 0) { + if (length <= 1 || (buffer[length - 2] & 0x80) === 0) throw new Error('Non-minimally encoded script number') + } + } -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; + // 40-bit + if (length === 5) { + var a = buffer.readUInt32LE(0) + var b = buffer.readUInt8(4) + + if (b & 0x80) return -(((b & ~0x80) * 0x100000000) + a) + return (b * 0x100000000) + a + } + + var result = 0 + + // 32-bit / 24-bit / 16-bit / 8-bit + for (var i = 0; i < length; ++i) { + result |= buffer[i] << (8 * i) + } + + if (buffer[length - 1] & 0x80) return -(result & ~(0x80 << (8 * (length - 1)))) + return result } -/** - * Checks if `value` is classified as a `Symbol` primitive or object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. - * @example - * - * _.isSymbol(Symbol.iterator); - * // => true - * - * _.isSymbol('abc'); - * // => false - */ -function isSymbol(value) { - return typeof value == 'symbol' || - (isObjectLike(value) && objectToString.call(value) == symbolTag); +function scriptNumSize (i) { + return i > 0x7fffffff ? 5 + : i > 0x7fffff ? 4 + : i > 0x7fff ? 3 + : i > 0x7f ? 2 + : i > 0x00 ? 1 + : 0 } -/** - * Converts `value` to a number. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to process. - * @returns {number} Returns the number. - * @example - * - * _.toNumber(3.2); - * // => 3.2 - * - * _.toNumber(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toNumber(Infinity); - * // => Infinity - * - * _.toNumber('3.2'); - * // => 3.2 - */ -function toNumber(value) { - if (typeof value == 'number') { - return value; - } - if (isSymbol(value)) { - return NAN; - } - if (isObject(value)) { - var other = typeof value.valueOf == 'function' ? value.valueOf() : value; - value = isObject(other) ? (other + '') : other; +function encode (number) { + var value = Math.abs(number) + var size = scriptNumSize(value) + var buffer = Buffer.allocUnsafe(size) + var negative = number < 0 + + for (var i = 0; i < size; ++i) { + buffer.writeUInt8(value & 0xff, i) + value >>= 8 } - if (typeof value != 'string') { - return value === 0 ? value : +value; + + if (buffer[size - 1] & 0x80) { + buffer.writeUInt8(negative ? 0x80 : 0x00, size - 1) + } else if (negative) { + buffer[size - 1] |= 0x80 } - value = value.replace(reTrim, ''); - var isBinary = reIsBinary.test(value); - return (isBinary || reIsOctal.test(value)) - ? freeParseInt(value.slice(2), isBinary ? 2 : 8) - : (reIsBadHex.test(value) ? NAN : +value); + + return buffer } -module.exports = toNumber; +module.exports = { + decode: decode, + encode: encode +} /***/ }), -/* 226 */ +/* 204 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +// {signature} {pubKey} +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) -var _CSSTransitionGroup = __webpack_require__(227); +function check (script) { + var chunks = bscript.decompile(script) -var _CSSTransitionGroup2 = _interopRequireDefault(_CSSTransitionGroup); + return chunks.length === 2 && + bscript.isCanonicalSignature(chunks[0]) && + bscript.isCanonicalPubKey(chunks[1]) +} +check.toJSON = function () { return 'pubKeyHash input' } -var _TransitionGroup = __webpack_require__(106); +function encodeStack (signature, pubKey) { + typeforce({ + signature: types.Buffer, pubKey: types.Buffer + }, { + signature: signature, pubKey: pubKey + }) -var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); + return [signature, pubKey] +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function encode (signature, pubKey) { + return bscript.compile(encodeStack(signature, pubKey)) +} + +function decodeStack (stack) { + typeforce(check, stack) + + return { + signature: stack[0], + pubKey: stack[1] + } +} + +function decode (buffer) { + var stack = bscript.decompile(buffer) + return decodeStack(stack) +} module.exports = { - TransitionGroup: _TransitionGroup2.default, - CSSTransitionGroup: _CSSTransitionGroup2.default -}; + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} + /***/ }), -/* 227 */ +/* 205 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +// <scriptSig> {serialized scriptPubKey script} -exports.__esModule = true; +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +function check (script, allowIncomplete) { + var chunks = bscript.decompile(script) + if (chunks.length < 1) return false -var _react = __webpack_require__(4); + var lastChunk = chunks[chunks.length - 1] + if (!Buffer.isBuffer(lastChunk)) return false -var _react2 = _interopRequireDefault(_react); + var scriptSigChunks = bscript.decompile(bscript.compile(chunks.slice(0, -1))) + var redeemScriptChunks = bscript.decompile(lastChunk) -var _propTypes = __webpack_require__(9); + // is redeemScript a valid script? + if (redeemScriptChunks.length === 0) return false -var _propTypes2 = _interopRequireDefault(_propTypes); + // is redeemScriptSig push only? + if (!bscript.isPushOnly(scriptSigChunks)) return false -var _TransitionGroup = __webpack_require__(106); + var inputType = bscript.classifyInput(scriptSigChunks, allowIncomplete) + var outputType = bscript.classifyOutput(redeemScriptChunks) + if (chunks.length === 1) { + return outputType === bscript.types.P2WSH || outputType === bscript.types.P2WPKH + } + return inputType === outputType +} +check.toJSON = function () { return 'scriptHash input' } -var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); +function encodeStack (redeemScriptStack, redeemScript) { + var serializedScriptPubKey = bscript.compile(redeemScript) -var _CSSTransitionGroupChild = __webpack_require__(231); + return [].concat(redeemScriptStack, serializedScriptPubKey) +} -var _CSSTransitionGroupChild2 = _interopRequireDefault(_CSSTransitionGroupChild); +function encode (redeemScriptSig, redeemScript) { + var redeemScriptStack = bscript.decompile(redeemScriptSig) -var _PropTypes = __webpack_require__(108); + return bscript.compile(encodeStack(redeemScriptStack, redeemScript)) +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function decodeStack (stack) { + typeforce(check, stack) -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + return { + redeemScriptStack: stack.slice(0, -1), + redeemScript: stack[stack.length - 1] + } +} -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +function decode (buffer) { + var stack = bscript.decompile(buffer) + var result = decodeStack(stack) + result.redeemScriptSig = bscript.compile(result.redeemScriptStack) + delete result.redeemScriptStack + return result +} -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +module.exports = { + check: check, + decode: decode, + decodeStack: decodeStack, + encode: encode, + encodeStack: encodeStack +} -var propTypes = { - transitionName: _PropTypes.nameShape.isRequired, - transitionAppear: _propTypes2.default.bool, - transitionEnter: _propTypes2.default.bool, - transitionLeave: _propTypes2.default.bool, - transitionAppearTimeout: (0, _PropTypes.transitionTimeout)('Appear'), - transitionEnterTimeout: (0, _PropTypes.transitionTimeout)('Enter'), - transitionLeaveTimeout: (0, _PropTypes.transitionTimeout)('Leave') -}; +/***/ }), +/* 206 */ +/***/ (function(module, exports, __webpack_require__) { -var defaultProps = { - transitionAppear: false, - transitionEnter: true, - transitionLeave: true -}; +var pushdata = __webpack_require__(202) +var varuint = __webpack_require__(73) -var CSSTransitionGroup = function (_React$Component) { - _inherits(CSSTransitionGroup, _React$Component); +// https://github.com/feross/buffer/blob/master/index.js#L1127 +function verifuint (value, max) { + if (typeof value !== 'number') throw new Error('cannot write a non-number as a number') + if (value < 0) throw new Error('specified a negative value for writing an unsigned value') + if (value > max) throw new Error('RangeError: value out of range') + if (Math.floor(value) !== value) throw new Error('value has a fractional component') +} - function CSSTransitionGroup() { - var _temp, _this, _ret; +function readUInt64LE (buffer, offset) { + var a = buffer.readUInt32LE(offset) + var b = buffer.readUInt32LE(offset + 4) + b *= 0x100000000 - _classCallCheck(this, CSSTransitionGroup); + verifuint(b + a, 0x001fffffffffffff) - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this._wrapChild = function (child) { - return _react2.default.createElement(_CSSTransitionGroupChild2.default, { - name: _this.props.transitionName, - appear: _this.props.transitionAppear, - enter: _this.props.transitionEnter, - leave: _this.props.transitionLeave, - appearTimeout: _this.props.transitionAppearTimeout, - enterTimeout: _this.props.transitionEnterTimeout, - leaveTimeout: _this.props.transitionLeaveTimeout - }, child); - }, _temp), _possibleConstructorReturn(_this, _ret); - } - - // We need to provide this childFactory so that - // ReactCSSTransitionGroupChild can receive updates to name, enter, and - // leave while it is leaving. - - - CSSTransitionGroup.prototype.render = function render() { - return _react2.default.createElement(_TransitionGroup2.default, _extends({}, this.props, { childFactory: this._wrapChild })); - }; - - return CSSTransitionGroup; -}(_react2.default.Component); + return b + a +} -CSSTransitionGroup.displayName = 'CSSTransitionGroup'; +function writeUInt64LE (buffer, value, offset) { + verifuint(value, 0x001fffffffffffff) + buffer.writeInt32LE(value & -1, offset) + buffer.writeUInt32LE(Math.floor(value / 0x100000000), offset + 4) + return offset + 8 +} -CSSTransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; -CSSTransitionGroup.defaultProps = defaultProps; +// TODO: remove in 4.0.0? +function readVarInt (buffer, offset) { + var result = varuint.decode(buffer, offset) -exports.default = CSSTransitionGroup; -module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + return { + number: result, + size: varuint.decode.bytes + } +} -/***/ }), -/* 228 */ -/***/ (function(module, exports) { +// TODO: remove in 4.0.0? +function writeVarInt (buffer, number, offset) { + varuint.encode(number, buffer, offset) + return varuint.encode.bytes +} - -module.exports = function chain(){ - var len = arguments.length - var args = []; - - for (var i = 0; i < len; i++) - args[i] = arguments[i] - - args = args.filter(function(fn){ return fn != null }) - - if (args.length === 0) return undefined - if (args.length === 1) return args[0] - - return args.reduce(function(current, next){ - return function chainedFunction() { - current.apply(this, arguments); - next.apply(this, arguments); - }; - }) -} +module.exports = { + pushDataSize: pushdata.encodingLength, + readPushDataInt: pushdata.decode, + readUInt64LE: readUInt64LE, + readVarInt: readVarInt, + varIntBuffer: varuint.encode, + varIntSize: varuint.encodingLength, + writePushDataInt: pushdata.encode, + writeUInt64LE: writeUInt64LE, + writeVarInt: writeVarInt +} /***/ }), -/* 229 */ +/* 207 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) {/** - * Copyright 2014-2015, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ - +/* WEBPACK VAR INJECTION */(function(Buffer) {var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(30) +var THREE = BigInteger.valueOf(3) -/** - * Similar to invariant but only logs a warning if the condition is not met. - * This can be used to log issues in development environments in critical - * paths. Removing the logging code for production environments will keep the - * same logic and follow the same code paths. - */ +function Point (curve, x, y, z) { + assert.notStrictEqual(z, undefined, 'Missing Z coordinate') -var warning = function() {}; + this.curve = curve + this.x = x + this.y = y + this.z = z + this._zInv = null -if (process.env.NODE_ENV !== 'production') { - warning = function(condition, format, args) { - var len = arguments.length; - args = new Array(len > 2 ? len - 2 : 0); - for (var key = 2; key < len; key++) { - args[key - 2] = arguments[key]; - } - if (format === undefined) { - throw new Error( - '`warning(condition, format, ...args)` requires a warning ' + - 'message argument' - ); - } + this.compressed = true +} - if (format.length < 10 || (/^[s\W]*$/).test(format)) { - throw new Error( - 'The warning format should be able to uniquely identify this ' + - 'warning. Please, use a more descriptive format than: ' + format - ); +Object.defineProperty(Point.prototype, 'zInv', { + get: function () { + if (this._zInv === null) { + this._zInv = this.z.modInverse(this.curve.p) } - if (!condition) { - var argIndex = 0; - var message = 'Warning: ' + - format.replace(/%s/g, function() { - return args[argIndex++]; - }); - if (typeof console !== 'undefined') { - console.error(message); - } - try { - // This error was thrown as a convenience so that you can use this stack - // to find the callsite that caused this warning to fire. - throw new Error(message); - } catch(x) {} - } - }; -} + return this._zInv + } +}) -module.exports = warning; +Object.defineProperty(Point.prototype, 'affineX', { + get: function () { + return this.x.multiply(this.zInv).mod(this.curve.p) + } +}) -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +Object.defineProperty(Point.prototype, 'affineY', { + get: function () { + return this.y.multiply(this.zInv).mod(this.curve.p) + } +}) -/***/ }), -/* 230 */ -/***/ (function(module, exports, __webpack_require__) { +Point.fromAffine = function (curve, x, y) { + return new Point(curve, x, y, BigInteger.ONE) +} -"use strict"; +Point.prototype.equals = function (other) { + if (other === this) return true + if (this.curve.isInfinity(this)) return this.curve.isInfinity(other) + if (this.curve.isInfinity(other)) return this.curve.isInfinity(this) + // u = Y2 * Z1 - Y1 * Z2 + var u = other.y.multiply(this.z).subtract(this.y.multiply(other.z)).mod(this.curve.p) -exports.__esModule = true; -exports.getChildMapping = getChildMapping; -exports.mergeChildMappings = mergeChildMappings; + if (u.signum() !== 0) return false -var _react = __webpack_require__(4); + // v = X2 * Z1 - X1 * Z2 + var v = other.x.multiply(this.z).subtract(this.x.multiply(other.z)).mod(this.curve.p) -/** - * Given `this.props.children`, return an object mapping key to child. - * - * @param {*} children `this.props.children` - * @return {object} Mapping of key to child - */ -function getChildMapping(children) { - if (!children) { - return children; - } - var result = {}; - _react.Children.map(children, function (child) { - return child; - }).forEach(function (child) { - result[child.key] = child; - }); - return result; + return v.signum() === 0 } -/** - * When you're adding or removing children some may be added or removed in the - * same render pass. We want to show *both* since we want to simultaneously - * animate elements in and out. This function takes a previous set of keys - * and a new set of keys and merges them with its best guess of the correct - * ordering. In the future we may expose some of the utilities in - * ReactMultiChild to make this easy, but for now React itself does not - * directly have this concept of the union of prevChildren and nextChildren - * so we implement it here. - * - * @param {object} prev prev children as returned from - * `ReactTransitionChildMapping.getChildMapping()`. - * @param {object} next next children as returned from - * `ReactTransitionChildMapping.getChildMapping()`. - * @return {object} a key set that contains all keys in `prev` and all keys - * in `next` in a reasonable order. - */ -function mergeChildMappings(prev, next) { - prev = prev || {}; - next = next || {}; +Point.prototype.negate = function () { + var y = this.curve.p.subtract(this.y) - function getValueForKey(key) { - if (next.hasOwnProperty(key)) { - return next[key]; - } + return new Point(this.curve, this.x, y, this.z) +} - return prev[key]; - } +Point.prototype.add = function (b) { + if (this.curve.isInfinity(this)) return b + if (this.curve.isInfinity(b)) return this - // For each key of `next`, the list of keys to insert before that key in - // the combined list - var nextKeysPending = {}; + var x1 = this.x + var y1 = this.y + var x2 = b.x + var y2 = b.y - var pendingKeys = []; - for (var prevKey in prev) { - if (next.hasOwnProperty(prevKey)) { - if (pendingKeys.length) { - nextKeysPending[prevKey] = pendingKeys; - pendingKeys = []; - } - } else { - pendingKeys.push(prevKey); - } - } + // u = Y2 * Z1 - Y1 * Z2 + var u = y2.multiply(this.z).subtract(y1.multiply(b.z)).mod(this.curve.p) + // v = X2 * Z1 - X1 * Z2 + var v = x2.multiply(this.z).subtract(x1.multiply(b.z)).mod(this.curve.p) - var i = void 0; - var childMapping = {}; - for (var nextKey in next) { - if (nextKeysPending.hasOwnProperty(nextKey)) { - for (i = 0; i < nextKeysPending[nextKey].length; i++) { - var pendingNextKey = nextKeysPending[nextKey][i]; - childMapping[nextKeysPending[nextKey][i]] = getValueForKey(pendingNextKey); - } + if (v.signum() === 0) { + if (u.signum() === 0) { + return this.twice() // this == b, so double } - childMapping[nextKey] = getValueForKey(nextKey); - } - // Finally, add the keys which didn't appear before any key in `next` - for (i = 0; i < pendingKeys.length; i++) { - childMapping[pendingKeys[i]] = getValueForKey(pendingKeys[i]); + return this.curve.infinity // this = -b, so infinity } - return childMapping; + var v2 = v.square() + var v3 = v2.multiply(v) + var x1v2 = x1.multiply(v2) + var zu2 = u.square().multiply(this.z) + + // x3 = v * (z2 * (z1 * u^2 - 2 * x1 * v^2) - v^3) + var x3 = zu2.subtract(x1v2.shiftLeft(1)).multiply(b.z).subtract(v3).multiply(v).mod(this.curve.p) + // y3 = z2 * (3 * x1 * u * v^2 - y1 * v^3 - z1 * u^3) + u * v^3 + var y3 = x1v2.multiply(THREE).multiply(u).subtract(y1.multiply(v3)).subtract(zu2.multiply(u)).multiply(b.z).add(u.multiply(v3)).mod(this.curve.p) + // z3 = v^3 * z1 * z2 + var z3 = v3.multiply(this.z).multiply(b.z).mod(this.curve.p) + + return new Point(this.curve, x3, y3, z3) } -/***/ }), -/* 231 */ -/***/ (function(module, exports, __webpack_require__) { +Point.prototype.twice = function () { + if (this.curve.isInfinity(this)) return this + if (this.y.signum() === 0) return this.curve.infinity -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { + var x1 = this.x + var y1 = this.y -exports.__esModule = true; + var y1z1 = y1.multiply(this.z).mod(this.curve.p) + var y1sqz1 = y1z1.multiply(y1).mod(this.curve.p) + var a = this.curve.a -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + // w = 3 * x1^2 + a * z1^2 + var w = x1.square().multiply(THREE) -var _addClass = __webpack_require__(232); + if (a.signum() !== 0) { + w = w.add(this.z.square().multiply(a)) + } -var _addClass2 = _interopRequireDefault(_addClass); + w = w.mod(this.curve.p) + // x3 = 2 * y1 * z1 * (w^2 - 8 * x1 * y1^2 * z1) + var x3 = w.square().subtract(x1.shiftLeft(3).multiply(y1sqz1)).shiftLeft(1).multiply(y1z1).mod(this.curve.p) + // y3 = 4 * y1^2 * z1 * (3 * w * x1 - 2 * y1^2 * z1) - w^3 + var y3 = w.multiply(THREE).multiply(x1).subtract(y1sqz1.shiftLeft(1)).shiftLeft(2).multiply(y1sqz1).subtract(w.pow(3)).mod(this.curve.p) + // z3 = 8 * (y1 * z1)^3 + var z3 = y1z1.pow(3).shiftLeft(3).mod(this.curve.p) -var _removeClass = __webpack_require__(234); + return new Point(this.curve, x3, y3, z3) +} -var _removeClass2 = _interopRequireDefault(_removeClass); +// Simple NAF (Non-Adjacent Form) multiplication algorithm +// TODO: modularize the multiplication algorithm +Point.prototype.multiply = function (k) { + if (this.curve.isInfinity(this)) return this + if (k.signum() === 0) return this.curve.infinity -var _requestAnimationFrame = __webpack_require__(235); + var e = k + var h = e.multiply(THREE) -var _requestAnimationFrame2 = _interopRequireDefault(_requestAnimationFrame); + var neg = this.negate() + var R = this -var _properties = __webpack_require__(236); + for (var i = h.bitLength() - 2; i > 0; --i) { + var hBit = h.testBit(i) + var eBit = e.testBit(i) -var _react = __webpack_require__(4); + R = R.twice() -var _react2 = _interopRequireDefault(_react); + if (hBit !== eBit) { + R = R.add(hBit ? this : neg) + } + } -var _propTypes = __webpack_require__(9); + return R +} -var _propTypes2 = _interopRequireDefault(_propTypes); +// Compute this*j + x*k (simultaneous multiplication) +Point.prototype.multiplyTwo = function (j, x, k) { + var i = Math.max(j.bitLength(), k.bitLength()) - 1 + var R = this.curve.infinity + var both = this.add(x) -var _reactDom = __webpack_require__(28); + while (i >= 0) { + var jBit = j.testBit(i) + var kBit = k.testBit(i) -var _PropTypes = __webpack_require__(108); + R = R.twice() -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + if (jBit) { + if (kBit) { + R = R.add(both) + } else { + R = R.add(this) + } + } else if (kBit) { + R = R.add(x) + } + --i + } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + return R +} -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +Point.prototype.getEncoded = function (compressed) { + if (compressed == null) compressed = this.compressed + if (this.curve.isInfinity(this)) return new Buffer('00', 'hex') // Infinity point encoded is simply '00' -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + var x = this.affineX + var y = this.affineY + var byteLength = this.curve.pLength + var buffer -var events = []; -if (_properties.transitionEnd) events.push(_properties.transitionEnd); -if (_properties.animationEnd) events.push(_properties.animationEnd); + // 0x02/0x03 | X + if (compressed) { + buffer = new Buffer(1 + byteLength) + buffer.writeUInt8(y.isEven() ? 0x02 : 0x03, 0) -function addEndListener(node, listener) { - if (events.length) { - events.forEach(function (e) { - return node.addEventListener(e, listener, false); - }); + // 0x04 | X | Y } else { - setTimeout(listener, 0); - } + buffer = new Buffer(1 + byteLength + byteLength) + buffer.writeUInt8(0x04, 0) - return function () { - if (!events.length) return; - events.forEach(function (e) { - return node.removeEventListener(e, listener, false); - }); - }; -} + y.toBuffer(byteLength).copy(buffer, 1 + byteLength) + } -var propTypes = { - children: _propTypes2.default.node, - name: _PropTypes.nameShape.isRequired, + x.toBuffer(byteLength).copy(buffer, 1) - // Once we require timeouts to be specified, we can remove the - // boolean flags (appear etc.) and just accept a number - // or a bool for the timeout flags (appearTimeout etc.) - appear: _propTypes2.default.bool, - enter: _propTypes2.default.bool, - leave: _propTypes2.default.bool, - appearTimeout: _propTypes2.default.number, - enterTimeout: _propTypes2.default.number, - leaveTimeout: _propTypes2.default.number -}; + return buffer +} -var CSSTransitionGroupChild = function (_React$Component) { - _inherits(CSSTransitionGroupChild, _React$Component); +Point.decodeFrom = function (curve, buffer) { + var type = buffer.readUInt8(0) + var compressed = (type !== 4) - function CSSTransitionGroupChild() { - var _temp, _this, _ret; + var byteLength = Math.floor((curve.p.bitLength() + 7) / 8) + var x = BigInteger.fromBuffer(buffer.slice(1, 1 + byteLength)) - _classCallCheck(this, CSSTransitionGroupChild); + var Q + if (compressed) { + assert.equal(buffer.length, byteLength + 1, 'Invalid sequence length') + assert(type === 0x02 || type === 0x03, 'Invalid sequence tag') - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } + var isOdd = (type === 0x03) + Q = curve.pointFromX(isOdd, x) + } else { + assert.equal(buffer.length, 1 + byteLength + byteLength, 'Invalid sequence length') - return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.componentWillAppear = function (done) { - if (_this.props.appear) { - _this.transition('appear', done, _this.props.appearTimeout); - } else { - done(); - } - }, _this.componentWillEnter = function (done) { - if (_this.props.enter) { - _this.transition('enter', done, _this.props.enterTimeout); - } else { - done(); - } - }, _this.componentWillLeave = function (done) { - if (_this.props.leave) { - _this.transition('leave', done, _this.props.leaveTimeout); - } else { - done(); - } - }, _temp), _possibleConstructorReturn(_this, _ret); + var y = BigInteger.fromBuffer(buffer.slice(1 + byteLength)) + Q = Point.fromAffine(curve, x, y) } - CSSTransitionGroupChild.prototype.componentWillMount = function componentWillMount() { - this.classNameAndNodeQueue = []; - this.transitionTimeouts = []; - }; + Q.compressed = compressed + return Q +} - CSSTransitionGroupChild.prototype.componentWillUnmount = function componentWillUnmount() { - this.unmounted = true; +Point.prototype.toString = function () { + if (this.curve.isInfinity(this)) return '(INFINITY)' - if (this.timeout) { - clearTimeout(this.timeout); - } - this.transitionTimeouts.forEach(function (timeout) { - clearTimeout(timeout); - }); + return '(' + this.affineX.toString() + ',' + this.affineY.toString() + ')' +} - this.classNameAndNodeQueue.length = 0; - }; +module.exports = Point - CSSTransitionGroupChild.prototype.transition = function transition(animationType, finishCallback, timeout) { - var node = (0, _reactDom.findDOMNode)(this); +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) - if (!node) { - if (finishCallback) { - finishCallback(); - } - return; - } +/***/ }), +/* 208 */ +/***/ (function(module, exports, __webpack_require__) { - var className = this.props.name[animationType] || this.props.name + '-' + animationType; - var activeClassName = this.props.name[animationType + 'Active'] || className + '-active'; - var timer = null; - var removeListeners = void 0; +var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(30) - (0, _addClass2.default)(node, className); +var Point = __webpack_require__(207) - // Need to do this to actually trigger a transition. - this.queueClassAndNode(activeClassName, node); +function Curve (p, a, b, Gx, Gy, n, h) { + this.p = p + this.a = a + this.b = b + this.G = Point.fromAffine(this, Gx, Gy) + this.n = n + this.h = h - // Clean-up the animation after the specified delay - var finish = function finish(e) { - if (e && e.target !== node) { - return; - } + this.infinity = new Point(this, null, null, BigInteger.ZERO) - clearTimeout(timer); - if (removeListeners) removeListeners(); + // result caching + this.pOverFour = p.add(BigInteger.ONE).shiftRight(2) - (0, _removeClass2.default)(node, className); - (0, _removeClass2.default)(node, activeClassName); + // determine size of p in bytes + this.pLength = Math.floor((this.p.bitLength() + 7) / 8) +} - if (removeListeners) removeListeners(); +Curve.prototype.pointFromX = function (isOdd, x) { + var alpha = x.pow(3).add(this.a.multiply(x)).add(this.b).mod(this.p) + var beta = alpha.modPow(this.pOverFour, this.p) // XXX: not compatible with all curves - // Usually this optional callback is used for informing an owner of - // a leave animation and telling it to remove the child. - if (finishCallback) { - finishCallback(); - } - }; + var y = beta + if (beta.isEven() ^ !isOdd) { + y = this.p.subtract(y) // -y % p + } - if (timeout) { - timer = setTimeout(finish, timeout); - this.transitionTimeouts.push(timer); - } else if (_properties.transitionEnd) { - removeListeners = addEndListener(node, finish); - } - }; + return Point.fromAffine(this, x, y) +} - CSSTransitionGroupChild.prototype.queueClassAndNode = function queueClassAndNode(className, node) { - var _this2 = this; +Curve.prototype.isInfinity = function (Q) { + if (Q === this.infinity) return true - this.classNameAndNodeQueue.push({ - className: className, - node: node - }); + return Q.z.signum() === 0 && Q.y.signum() !== 0 +} - if (!this.rafHandle) { - this.rafHandle = (0, _requestAnimationFrame2.default)(function () { - return _this2.flushClassNameAndNodeQueue(); - }); - } - }; +Curve.prototype.isOnCurve = function (Q) { + if (this.isInfinity(Q)) return true - CSSTransitionGroupChild.prototype.flushClassNameAndNodeQueue = function flushClassNameAndNodeQueue() { - if (!this.unmounted) { - this.classNameAndNodeQueue.forEach(function (obj) { - // This is for to force a repaint, - // which is necessary in order to transition styles when adding a class name. - /* eslint-disable no-unused-expressions */ - obj.node.scrollTop; - /* eslint-enable no-unused-expressions */ - (0, _addClass2.default)(obj.node, obj.className); - }); - } - this.classNameAndNodeQueue.length = 0; - this.rafHandle = null; - }; + var x = Q.affineX + var y = Q.affineY + var a = this.a + var b = this.b + var p = this.p - CSSTransitionGroupChild.prototype.render = function render() { - var props = _extends({}, this.props); - delete props.name; - delete props.appear; - delete props.enter; - delete props.leave; - delete props.appearTimeout; - delete props.enterTimeout; - delete props.leaveTimeout; - delete props.children; - return _react2.default.cloneElement(_react2.default.Children.only(this.props.children), props); - }; + // Check that xQ and yQ are integers in the interval [0, p - 1] + if (x.signum() < 0 || x.compareTo(p) >= 0) return false + if (y.signum() < 0 || y.compareTo(p) >= 0) return false - return CSSTransitionGroupChild; -}(_react2.default.Component); + // and check that y^2 = x^3 + ax + b (mod p) + var lhs = y.square().mod(p) + var rhs = x.pow(3).add(a.multiply(x)).add(b).mod(p) + return lhs.equals(rhs) +} -CSSTransitionGroupChild.displayName = 'CSSTransitionGroupChild'; +/** + * Validate an elliptic curve point. + * + * See SEC 1, section 3.2.2.1: Elliptic Curve Public Key Validation Primitive + */ +Curve.prototype.validate = function (Q) { + // Check Q != O + assert(!this.isInfinity(Q), 'Point is at infinity') + assert(this.isOnCurve(Q), 'Point is not on the curve') + // Check nQ = O (where Q is a scalar multiple of G) + var nQ = Q.multiply(this.n) + assert(this.isInfinity(nQ), 'Point is not a scalar multiple of G') -CSSTransitionGroupChild.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; + return true +} + +module.exports = Curve -exports.default = CSSTransitionGroupChild; -module.exports = exports['default']; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 232 */ -/***/ (function(module, exports, __webpack_require__) { +/* 209 */ +/***/ (function(module, exports) { -"use strict"; +// https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki#account-discovery +module.exports = function discovery (chain, gapLimit, queryCb, done) { + var gap = 0 + var checked = 0 + + function cycle () { + var batch = [chain.get()] + checked++ + while (batch.length < gapLimit) { + chain.next() + batch.push(chain.get()) -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.default = addClass; + checked++ + } -var _hasClass = __webpack_require__(233); + queryCb(batch, function (err, results) { + if (err) return done(err) -var _hasClass2 = _interopRequireDefault(_hasClass); + results.forEach(function (isUsed) { + if (isUsed) { + gap = 0 + } else { + gap += 1 + } + }) -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + if (gap >= gapLimit) { + var used = checked - gap -function addClass(element, className) { - if (element.classList) element.classList.add(className);else if (!(0, _hasClass2.default)(element)) element.className = element.className + ' ' + className; + return done(undefined, used, checked) + } else { + chain.next() + } + + cycle() + }) + } + + cycle() } -module.exports = exports['default']; -/***/ }), -/* 233 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; +/***/ }), +/* 210 */ +/***/ (function(module, exports) { +function Chain (parent, k) { + k = k || 0 + this.__parent = parent -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.default = hasClass; -function hasClass(element, className) { - if (element.classList) return !!className && element.classList.contains(className);else return (" " + element.className + " ").indexOf(" " + className + " ") !== -1; + this.addresses = [] + this.k = k + this.map = {} } -module.exports = exports["default"]; -/***/ }), -/* 234 */ -/***/ (function(module, exports, __webpack_require__) { +Chain.prototype.__initialize = function () { + var address = this.__parent.derive(this.k).getAddress() + this.map[address] = this.k + this.addresses.push(address) +} -"use strict"; +Chain.prototype.clone = function () { + var chain = new Chain(this.__parent, this.k) + for (var k in this.addresses) chain.addresses[k] = this.addresses[k] + for (k in this.map) chain.map[k] = this.map[k] -module.exports = function removeClass(element, className) { - if (element.classList) element.classList.remove(className);else element.className = element.className.replace(new RegExp('(^|\\s)' + className + '(?:\\s|$)', 'g'), '$1').replace(/\s+/g, ' ').replace(/^\s*|\s*$/g, ''); -}; + return chain +} -/***/ }), -/* 235 */ -/***/ (function(module, exports, __webpack_require__) { +Chain.prototype.derive = function (address, parent) { + var k = this.map[address] + if (k === undefined) return -"use strict"; + parent = parent || this.__parent + return parent.derive(k) +} +Chain.prototype.find = function (address) { + return this.map[address] +} -Object.defineProperty(exports, "__esModule", { - value: true -}); +Chain.prototype.get = function () { + if (this.addresses.length === 0) this.__initialize() -var _inDOM = __webpack_require__(107); + return this.addresses[this.addresses.length - 1] +} -var _inDOM2 = _interopRequireDefault(_inDOM); +Chain.prototype.getAll = function () { + if (this.addresses.length === 0) this.__initialize() -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + return this.addresses +} -var vendors = ['', 'webkit', 'moz', 'o', 'ms']; -var cancel = 'clearTimeout'; -var raf = fallback; -var compatRaf = void 0; +Chain.prototype.getParent = function () { + return this.__parent +} -var getKey = function getKey(vendor, k) { - return vendor + (!vendor ? k : k[0].toUpperCase() + k.substr(1)) + 'AnimationFrame'; -}; +Chain.prototype.next = function () { + if (this.addresses.length === 0) this.__initialize() + var address = this.__parent.derive(this.k + 1).getAddress() -if (_inDOM2.default) { - vendors.some(function (vendor) { - var rafKey = getKey(vendor, 'request'); + this.k += 1 + this.map[address] = this.k + this.addresses.push(address) - if (rafKey in window) { - cancel = getKey(vendor, 'cancel'); - return raf = function raf(cb) { - return window[rafKey](cb); - }; - } - }); + return address } -/* https://github.com/component/raf */ -var prev = new Date().getTime(); -function fallback(fn) { - var curr = new Date().getTime(), - ms = Math.max(0, 16 - (curr - prev)), - req = setTimeout(fn, ms); +Chain.prototype.pop = function () { + var address = this.addresses.pop() + delete this.map[address] + this.k -= 1 - prev = curr; - return req; + return address } -compatRaf = function compatRaf(cb) { - return raf(cb); -}; -compatRaf.cancel = function (id) { - window[cancel] && typeof window[cancel] === 'function' && window[cancel](id); -}; -exports.default = compatRaf; -module.exports = exports['default']; +module.exports = Chain + /***/ }), -/* 236 */ +/* 211 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +// style-loader: Adds some css to the DOM by adding a <style> tag +// load the styles +var content = __webpack_require__(212); +if(typeof content === 'string') content = [[module.i, content, '']]; +// Prepare cssTransformation +var transform; -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.animationEnd = exports.animationDelay = exports.animationTiming = exports.animationDuration = exports.animationName = exports.transitionEnd = exports.transitionDuration = exports.transitionDelay = exports.transitionTiming = exports.transitionProperty = exports.transform = undefined; +var options = {} +options.transform = transform +// add the styles to the DOM +var update = __webpack_require__(118)(content, options); +if(content.locals) module.exports = content.locals; +// Hot Module Replacement +if(false) { + // When the styles change, update the <style> tags + if(!content.locals) { + module.hot.accept("!!../../../css-loader/index.js!./bootstrap.css", function() { + var newContent = require("!!../../../css-loader/index.js!./bootstrap.css"); + if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; + update(newContent); + }); + } + // When the module is disposed, remove the <style> tags + module.hot.dispose(function() { update(); }); +} -var _inDOM = __webpack_require__(107); +/***/ }), +/* 212 */ +/***/ (function(module, exports, __webpack_require__) { -var _inDOM2 = _interopRequireDefault(_inDOM); +exports = module.exports = __webpack_require__(117)(undefined); +// imports -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -var transform = 'transform'; -var prefix = void 0, - transitionEnd = void 0, - animationEnd = void 0; -var transitionProperty = void 0, - transitionDuration = void 0, - transitionTiming = void 0, - transitionDelay = void 0; -var animationName = void 0, - animationDuration = void 0, - animationTiming = void 0, - animationDelay = void 0; +// module +exports.push([module.i, "/*!\n * Bootstrap v4.0.0-alpha.6 (https://getbootstrap.com)\n * Copyright 2011-2017 The Bootstrap Authors\n * Copyright 2011-2017 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n */\n/*! normalize.css v5.0.0 | MIT License | github.com/necolas/normalize.css */\nhtml {\n font-family: sans-serif;\n line-height: 1.15;\n -ms-text-size-adjust: 100%;\n -webkit-text-size-adjust: 100%;\n}\n\nbody {\n margin: 0;\n}\n\narticle,\naside,\nfooter,\nheader,\nnav,\nsection {\n display: block;\n}\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\nfigcaption,\nfigure,\nmain {\n display: block;\n}\n\nfigure {\n margin: 1em 40px;\n}\n\nhr {\n -webkit-box-sizing: content-box;\n box-sizing: content-box;\n height: 0;\n overflow: visible;\n}\n\npre {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\na {\n background-color: transparent;\n -webkit-text-decoration-skip: objects;\n}\n\na:active,\na:hover {\n outline-width: 0;\n}\n\nabbr[title] {\n border-bottom: none;\n text-decoration: underline;\n text-decoration: underline dotted;\n}\n\nb,\nstrong {\n font-weight: inherit;\n}\n\nb,\nstrong {\n font-weight: bolder;\n}\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\ndfn {\n font-style: italic;\n}\n\nmark {\n background-color: #ff0;\n color: #000;\n}\n\nsmall {\n font-size: 80%;\n}\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\naudio,\nvideo {\n display: inline-block;\n}\n\naudio:not([controls]) {\n display: none;\n height: 0;\n}\n\nimg {\n border-style: none;\n}\n\nsvg:not(:root) {\n overflow: hidden;\n}\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: sans-serif;\n font-size: 100%;\n line-height: 1.15;\n margin: 0;\n}\n\nbutton,\ninput {\n overflow: visible;\n}\n\nbutton,\nselect {\n text-transform: none;\n}\n\nbutton,\nhtml [type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\nfieldset {\n border: 1px solid #c0c0c0;\n margin: 0 2px;\n padding: 0.35em 0.625em 0.75em;\n}\n\nlegend {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: inherit;\n display: table;\n max-width: 100%;\n padding: 0;\n white-space: normal;\n}\n\nprogress {\n display: inline-block;\n vertical-align: baseline;\n}\n\ntextarea {\n overflow: auto;\n}\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n padding: 0;\n}\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n[type=\"search\"] {\n -webkit-appearance: textfield;\n outline-offset: -2px;\n}\n\n[type=\"search\"]::-webkit-search-cancel-button,\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n::-webkit-file-upload-button {\n -webkit-appearance: button;\n font: inherit;\n}\n\ndetails,\nmenu {\n display: block;\n}\n\nsummary {\n display: list-item;\n}\n\ncanvas {\n display: inline-block;\n}\n\ntemplate {\n display: none;\n}\n\n[hidden] {\n display: none;\n}\n\n@media print {\n *,\n *::before,\n *::after,\n p::first-letter,\n div::first-letter,\n blockquote::first-letter,\n li::first-letter,\n p::first-line,\n div::first-line,\n blockquote::first-line,\n li::first-line {\n text-shadow: none !important;\n -webkit-box-shadow: none !important;\n box-shadow: none !important;\n }\n a,\n a:visited {\n text-decoration: underline;\n }\n abbr[title]::after {\n content: \" (\" attr(title) \")\";\n }\n pre {\n white-space: pre-wrap !important;\n }\n pre,\n blockquote {\n border: 1px solid #999;\n page-break-inside: avoid;\n }\n thead {\n display: table-header-group;\n }\n tr,\n img {\n page-break-inside: avoid;\n }\n p,\n h2,\n h3 {\n orphans: 3;\n widows: 3;\n }\n h2,\n h3 {\n page-break-after: avoid;\n }\n .navbar {\n display: none;\n }\n .badge {\n border: 1px solid #000;\n }\n .table {\n border-collapse: collapse !important;\n }\n .table td,\n .table th {\n background-color: #fff !important;\n }\n .table-bordered th,\n .table-bordered td {\n border: 1px solid #ddd !important;\n }\n}\n\nhtml {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n}\n\n*,\n*::before,\n*::after {\n -webkit-box-sizing: inherit;\n box-sizing: inherit;\n}\n\n@-ms-viewport {\n width: device-width;\n}\n\nhtml {\n -ms-overflow-style: scrollbar;\n -webkit-tap-highlight-color: transparent;\n}\n\nbody {\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.5;\n color: #292b2c;\n background-color: #fff;\n}\n\n[tabindex=\"-1\"]:focus {\n outline: none !important;\n}\n\nh1, h2, h3, h4, h5, h6 {\n margin-top: 0;\n margin-bottom: .5rem;\n}\n\np {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nabbr[title],\nabbr[data-original-title] {\n cursor: help;\n}\n\naddress {\n margin-bottom: 1rem;\n font-style: normal;\n line-height: inherit;\n}\n\nol,\nul,\ndl {\n margin-top: 0;\n margin-bottom: 1rem;\n}\n\nol ol,\nul ul,\nol ul,\nul ol {\n margin-bottom: 0;\n}\n\ndt {\n font-weight: bold;\n}\n\ndd {\n margin-bottom: .5rem;\n margin-left: 0;\n}\n\nblockquote {\n margin: 0 0 1rem;\n}\n\na {\n color: #0275d8;\n text-decoration: none;\n}\n\na:focus, a:hover {\n color: #014c8c;\n text-decoration: underline;\n}\n\na:not([href]):not([tabindex]) {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus, a:not([href]):not([tabindex]):hover {\n color: inherit;\n text-decoration: none;\n}\n\na:not([href]):not([tabindex]):focus {\n outline: 0;\n}\n\npre {\n margin-top: 0;\n margin-bottom: 1rem;\n overflow: auto;\n}\n\nfigure {\n margin: 0 0 1rem;\n}\n\nimg {\n vertical-align: middle;\n}\n\n[role=\"button\"] {\n cursor: pointer;\n}\n\na,\narea,\nbutton,\n[role=\"button\"],\ninput,\nlabel,\nselect,\nsummary,\ntextarea {\n -ms-touch-action: manipulation;\n touch-action: manipulation;\n}\n\ntable {\n border-collapse: collapse;\n background-color: transparent;\n}\n\ncaption {\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n color: #636c72;\n text-align: left;\n caption-side: bottom;\n}\n\nth {\n text-align: left;\n}\n\nlabel {\n display: inline-block;\n margin-bottom: .5rem;\n}\n\nbutton:focus {\n outline: 1px dotted;\n outline: 5px auto -webkit-focus-ring-color;\n}\n\ninput,\nbutton,\nselect,\ntextarea {\n line-height: inherit;\n}\n\ninput[type=\"radio\"]:disabled,\ninput[type=\"checkbox\"]:disabled {\n cursor: not-allowed;\n}\n\ninput[type=\"date\"],\ninput[type=\"time\"],\ninput[type=\"datetime-local\"],\ninput[type=\"month\"] {\n -webkit-appearance: listbox;\n}\n\ntextarea {\n resize: vertical;\n}\n\nfieldset {\n min-width: 0;\n padding: 0;\n margin: 0;\n border: 0;\n}\n\nlegend {\n display: block;\n width: 100%;\n padding: 0;\n margin-bottom: .5rem;\n font-size: 1.5rem;\n line-height: inherit;\n}\n\ninput[type=\"search\"] {\n -webkit-appearance: none;\n}\n\noutput {\n display: inline-block;\n}\n\n[hidden] {\n display: none !important;\n}\n\nh1, h2, h3, h4, h5, h6,\n.h1, .h2, .h3, .h4, .h5, .h6 {\n margin-bottom: 0.5rem;\n font-family: inherit;\n font-weight: 500;\n line-height: 1.1;\n color: inherit;\n}\n\nh1, .h1 {\n font-size: 2.5rem;\n}\n\nh2, .h2 {\n font-size: 2rem;\n}\n\nh3, .h3 {\n font-size: 1.75rem;\n}\n\nh4, .h4 {\n font-size: 1.5rem;\n}\n\nh5, .h5 {\n font-size: 1.25rem;\n}\n\nh6, .h6 {\n font-size: 1rem;\n}\n\n.lead {\n font-size: 1.25rem;\n font-weight: 300;\n}\n\n.display-1 {\n font-size: 6rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-2 {\n font-size: 5.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-3 {\n font-size: 4.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\n.display-4 {\n font-size: 3.5rem;\n font-weight: 300;\n line-height: 1.1;\n}\n\nhr {\n margin-top: 1rem;\n margin-bottom: 1rem;\n border: 0;\n border-top: 1px solid rgba(0, 0, 0, 0.1);\n}\n\nsmall,\n.small {\n font-size: 80%;\n font-weight: normal;\n}\n\nmark,\n.mark {\n padding: 0.2em;\n background-color: #fcf8e3;\n}\n\n.list-unstyled {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline {\n padding-left: 0;\n list-style: none;\n}\n\n.list-inline-item {\n display: inline-block;\n}\n\n.list-inline-item:not(:last-child) {\n margin-right: 5px;\n}\n\n.initialism {\n font-size: 90%;\n text-transform: uppercase;\n}\n\n.blockquote {\n padding: 0.5rem 1rem;\n margin-bottom: 1rem;\n font-size: 1.25rem;\n border-left: 0.25rem solid #eceeef;\n}\n\n.blockquote-footer {\n display: block;\n font-size: 80%;\n color: #636c72;\n}\n\n.blockquote-footer::before {\n content: \"\\2014 \\A0\";\n}\n\n.blockquote-reverse {\n padding-right: 1rem;\n padding-left: 0;\n text-align: right;\n border-right: 0.25rem solid #eceeef;\n border-left: 0;\n}\n\n.blockquote-reverse .blockquote-footer::before {\n content: \"\";\n}\n\n.blockquote-reverse .blockquote-footer::after {\n content: \"\\A0 \\2014\";\n}\n\n.img-fluid {\n max-width: 100%;\n height: auto;\n}\n\n.img-thumbnail {\n padding: 0.25rem;\n background-color: #fff;\n border: 1px solid #ddd;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n max-width: 100%;\n height: auto;\n}\n\n.figure {\n display: inline-block;\n}\n\n.figure-img {\n margin-bottom: 0.5rem;\n line-height: 1;\n}\n\n.figure-caption {\n font-size: 90%;\n color: #636c72;\n}\n\ncode,\nkbd,\npre,\nsamp {\n font-family: Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;\n}\n\ncode {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #bd4147;\n background-color: #f7f7f9;\n border-radius: 0.25rem;\n}\n\na > code {\n padding: 0;\n color: inherit;\n background-color: inherit;\n}\n\nkbd {\n padding: 0.2rem 0.4rem;\n font-size: 90%;\n color: #fff;\n background-color: #292b2c;\n border-radius: 0.2rem;\n}\n\nkbd kbd {\n padding: 0;\n font-size: 100%;\n font-weight: bold;\n}\n\npre {\n display: block;\n margin-top: 0;\n margin-bottom: 1rem;\n font-size: 90%;\n color: #292b2c;\n}\n\npre code {\n padding: 0;\n font-size: inherit;\n color: inherit;\n background-color: transparent;\n border-radius: 0;\n}\n\n.pre-scrollable {\n max-height: 340px;\n overflow-y: scroll;\n}\n\n.container {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .container {\n width: 540px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 768px) {\n .container {\n width: 720px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 992px) {\n .container {\n width: 960px;\n max-width: 100%;\n }\n}\n\n@media (min-width: 1200px) {\n .container {\n width: 1140px;\n max-width: 100%;\n }\n}\n\n.container-fluid {\n position: relative;\n margin-left: auto;\n margin-right: auto;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .container-fluid {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.row {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: wrap;\n -ms-flex-wrap: wrap;\n flex-wrap: wrap;\n margin-right: -15px;\n margin-left: -15px;\n}\n\n@media (min-width: 576px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 768px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 992px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n@media (min-width: 1200px) {\n .row {\n margin-right: -15px;\n margin-left: -15px;\n }\n}\n\n.no-gutters {\n margin-right: 0;\n margin-left: 0;\n}\n\n.no-gutters > .col,\n.no-gutters > [class*=\"col-\"] {\n padding-right: 0;\n padding-left: 0;\n}\n\n.col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n position: relative;\n width: 100%;\n min-height: 1px;\n padding-right: 15px;\n padding-left: 15px;\n}\n\n@media (min-width: 576px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 768px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 992px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n@media (min-width: 1200px) {\n .col-1, .col-2, .col-3, .col-4, .col-5, .col-6, .col-7, .col-8, .col-9, .col-10, .col-11, .col-12, .col, .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm, .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12, .col-md, .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg, .col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12, .col-xl {\n padding-right: 15px;\n padding-left: 15px;\n }\n}\n\n.col {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n}\n\n.col-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n}\n\n.col-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n}\n\n.col-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n}\n\n.col-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n}\n\n.col-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n}\n\n.col-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n}\n\n.col-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n}\n\n.col-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n}\n\n.col-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n}\n\n.col-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n}\n\n.col-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n}\n\n.col-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n}\n\n.col-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n}\n\n.pull-0 {\n right: auto;\n}\n\n.pull-1 {\n right: 8.333333%;\n}\n\n.pull-2 {\n right: 16.666667%;\n}\n\n.pull-3 {\n right: 25%;\n}\n\n.pull-4 {\n right: 33.333333%;\n}\n\n.pull-5 {\n right: 41.666667%;\n}\n\n.pull-6 {\n right: 50%;\n}\n\n.pull-7 {\n right: 58.333333%;\n}\n\n.pull-8 {\n right: 66.666667%;\n}\n\n.pull-9 {\n right: 75%;\n}\n\n.pull-10 {\n right: 83.333333%;\n}\n\n.pull-11 {\n right: 91.666667%;\n}\n\n.pull-12 {\n right: 100%;\n}\n\n.push-0 {\n left: auto;\n}\n\n.push-1 {\n left: 8.333333%;\n}\n\n.push-2 {\n left: 16.666667%;\n}\n\n.push-3 {\n left: 25%;\n}\n\n.push-4 {\n left: 33.333333%;\n}\n\n.push-5 {\n left: 41.666667%;\n}\n\n.push-6 {\n left: 50%;\n}\n\n.push-7 {\n left: 58.333333%;\n}\n\n.push-8 {\n left: 66.666667%;\n}\n\n.push-9 {\n left: 75%;\n}\n\n.push-10 {\n left: 83.333333%;\n}\n\n.push-11 {\n left: 91.666667%;\n}\n\n.push-12 {\n left: 100%;\n}\n\n.offset-1 {\n margin-left: 8.333333%;\n}\n\n.offset-2 {\n margin-left: 16.666667%;\n}\n\n.offset-3 {\n margin-left: 25%;\n}\n\n.offset-4 {\n margin-left: 33.333333%;\n}\n\n.offset-5 {\n margin-left: 41.666667%;\n}\n\n.offset-6 {\n margin-left: 50%;\n}\n\n.offset-7 {\n margin-left: 58.333333%;\n}\n\n.offset-8 {\n margin-left: 66.666667%;\n}\n\n.offset-9 {\n margin-left: 75%;\n}\n\n.offset-10 {\n margin-left: 83.333333%;\n}\n\n.offset-11 {\n margin-left: 91.666667%;\n}\n\n@media (min-width: 576px) {\n .col-sm {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-sm-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-sm-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-sm-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-sm-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-sm-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-sm-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-sm-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-sm-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-sm-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-sm-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-sm-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-sm-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-sm-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-sm-0 {\n right: auto;\n }\n .pull-sm-1 {\n right: 8.333333%;\n }\n .pull-sm-2 {\n right: 16.666667%;\n }\n .pull-sm-3 {\n right: 25%;\n }\n .pull-sm-4 {\n right: 33.333333%;\n }\n .pull-sm-5 {\n right: 41.666667%;\n }\n .pull-sm-6 {\n right: 50%;\n }\n .pull-sm-7 {\n right: 58.333333%;\n }\n .pull-sm-8 {\n right: 66.666667%;\n }\n .pull-sm-9 {\n right: 75%;\n }\n .pull-sm-10 {\n right: 83.333333%;\n }\n .pull-sm-11 {\n right: 91.666667%;\n }\n .pull-sm-12 {\n right: 100%;\n }\n .push-sm-0 {\n left: auto;\n }\n .push-sm-1 {\n left: 8.333333%;\n }\n .push-sm-2 {\n left: 16.666667%;\n }\n .push-sm-3 {\n left: 25%;\n }\n .push-sm-4 {\n left: 33.333333%;\n }\n .push-sm-5 {\n left: 41.666667%;\n }\n .push-sm-6 {\n left: 50%;\n }\n .push-sm-7 {\n left: 58.333333%;\n }\n .push-sm-8 {\n left: 66.666667%;\n }\n .push-sm-9 {\n left: 75%;\n }\n .push-sm-10 {\n left: 83.333333%;\n }\n .push-sm-11 {\n left: 91.666667%;\n }\n .push-sm-12 {\n left: 100%;\n }\n .offset-sm-0 {\n margin-left: 0%;\n }\n .offset-sm-1 {\n margin-left: 8.333333%;\n }\n .offset-sm-2 {\n margin-left: 16.666667%;\n }\n .offset-sm-3 {\n margin-left: 25%;\n }\n .offset-sm-4 {\n margin-left: 33.333333%;\n }\n .offset-sm-5 {\n margin-left: 41.666667%;\n }\n .offset-sm-6 {\n margin-left: 50%;\n }\n .offset-sm-7 {\n margin-left: 58.333333%;\n }\n .offset-sm-8 {\n margin-left: 66.666667%;\n }\n .offset-sm-9 {\n margin-left: 75%;\n }\n .offset-sm-10 {\n margin-left: 83.333333%;\n }\n .offset-sm-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 768px) {\n .col-md {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-md-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-md-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-md-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-md-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-md-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-md-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-md-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-md-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-md-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-md-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-md-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-md-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-md-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-md-0 {\n right: auto;\n }\n .pull-md-1 {\n right: 8.333333%;\n }\n .pull-md-2 {\n right: 16.666667%;\n }\n .pull-md-3 {\n right: 25%;\n }\n .pull-md-4 {\n right: 33.333333%;\n }\n .pull-md-5 {\n right: 41.666667%;\n }\n .pull-md-6 {\n right: 50%;\n }\n .pull-md-7 {\n right: 58.333333%;\n }\n .pull-md-8 {\n right: 66.666667%;\n }\n .pull-md-9 {\n right: 75%;\n }\n .pull-md-10 {\n right: 83.333333%;\n }\n .pull-md-11 {\n right: 91.666667%;\n }\n .pull-md-12 {\n right: 100%;\n }\n .push-md-0 {\n left: auto;\n }\n .push-md-1 {\n left: 8.333333%;\n }\n .push-md-2 {\n left: 16.666667%;\n }\n .push-md-3 {\n left: 25%;\n }\n .push-md-4 {\n left: 33.333333%;\n }\n .push-md-5 {\n left: 41.666667%;\n }\n .push-md-6 {\n left: 50%;\n }\n .push-md-7 {\n left: 58.333333%;\n }\n .push-md-8 {\n left: 66.666667%;\n }\n .push-md-9 {\n left: 75%;\n }\n .push-md-10 {\n left: 83.333333%;\n }\n .push-md-11 {\n left: 91.666667%;\n }\n .push-md-12 {\n left: 100%;\n }\n .offset-md-0 {\n margin-left: 0%;\n }\n .offset-md-1 {\n margin-left: 8.333333%;\n }\n .offset-md-2 {\n margin-left: 16.666667%;\n }\n .offset-md-3 {\n margin-left: 25%;\n }\n .offset-md-4 {\n margin-left: 33.333333%;\n }\n .offset-md-5 {\n margin-left: 41.666667%;\n }\n .offset-md-6 {\n margin-left: 50%;\n }\n .offset-md-7 {\n margin-left: 58.333333%;\n }\n .offset-md-8 {\n margin-left: 66.666667%;\n }\n .offset-md-9 {\n margin-left: 75%;\n }\n .offset-md-10 {\n margin-left: 83.333333%;\n }\n .offset-md-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 992px) {\n .col-lg {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-lg-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-lg-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-lg-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-lg-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-lg-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-lg-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-lg-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-lg-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-lg-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-lg-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-lg-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-lg-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-lg-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-lg-0 {\n right: auto;\n }\n .pull-lg-1 {\n right: 8.333333%;\n }\n .pull-lg-2 {\n right: 16.666667%;\n }\n .pull-lg-3 {\n right: 25%;\n }\n .pull-lg-4 {\n right: 33.333333%;\n }\n .pull-lg-5 {\n right: 41.666667%;\n }\n .pull-lg-6 {\n right: 50%;\n }\n .pull-lg-7 {\n right: 58.333333%;\n }\n .pull-lg-8 {\n right: 66.666667%;\n }\n .pull-lg-9 {\n right: 75%;\n }\n .pull-lg-10 {\n right: 83.333333%;\n }\n .pull-lg-11 {\n right: 91.666667%;\n }\n .pull-lg-12 {\n right: 100%;\n }\n .push-lg-0 {\n left: auto;\n }\n .push-lg-1 {\n left: 8.333333%;\n }\n .push-lg-2 {\n left: 16.666667%;\n }\n .push-lg-3 {\n left: 25%;\n }\n .push-lg-4 {\n left: 33.333333%;\n }\n .push-lg-5 {\n left: 41.666667%;\n }\n .push-lg-6 {\n left: 50%;\n }\n .push-lg-7 {\n left: 58.333333%;\n }\n .push-lg-8 {\n left: 66.666667%;\n }\n .push-lg-9 {\n left: 75%;\n }\n .push-lg-10 {\n left: 83.333333%;\n }\n .push-lg-11 {\n left: 91.666667%;\n }\n .push-lg-12 {\n left: 100%;\n }\n .offset-lg-0 {\n margin-left: 0%;\n }\n .offset-lg-1 {\n margin-left: 8.333333%;\n }\n .offset-lg-2 {\n margin-left: 16.666667%;\n }\n .offset-lg-3 {\n margin-left: 25%;\n }\n .offset-lg-4 {\n margin-left: 33.333333%;\n }\n .offset-lg-5 {\n margin-left: 41.666667%;\n }\n .offset-lg-6 {\n margin-left: 50%;\n }\n .offset-lg-7 {\n margin-left: 58.333333%;\n }\n .offset-lg-8 {\n margin-left: 66.666667%;\n }\n .offset-lg-9 {\n margin-left: 75%;\n }\n .offset-lg-10 {\n margin-left: 83.333333%;\n }\n .offset-lg-11 {\n margin-left: 91.666667%;\n }\n}\n\n@media (min-width: 1200px) {\n .col-xl {\n -webkit-flex-basis: 0;\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n -webkit-box-flex: 1;\n -webkit-flex-grow: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n max-width: 100%;\n }\n .col-xl-auto {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n width: auto;\n }\n .col-xl-1 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 8.333333%;\n -ms-flex: 0 0 8.333333%;\n flex: 0 0 8.333333%;\n max-width: 8.333333%;\n }\n .col-xl-2 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 16.666667%;\n -ms-flex: 0 0 16.666667%;\n flex: 0 0 16.666667%;\n max-width: 16.666667%;\n }\n .col-xl-3 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 25%;\n -ms-flex: 0 0 25%;\n flex: 0 0 25%;\n max-width: 25%;\n }\n .col-xl-4 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 33.333333%;\n -ms-flex: 0 0 33.333333%;\n flex: 0 0 33.333333%;\n max-width: 33.333333%;\n }\n .col-xl-5 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 41.666667%;\n -ms-flex: 0 0 41.666667%;\n flex: 0 0 41.666667%;\n max-width: 41.666667%;\n }\n .col-xl-6 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 50%;\n -ms-flex: 0 0 50%;\n flex: 0 0 50%;\n max-width: 50%;\n }\n .col-xl-7 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 58.333333%;\n -ms-flex: 0 0 58.333333%;\n flex: 0 0 58.333333%;\n max-width: 58.333333%;\n }\n .col-xl-8 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 66.666667%;\n -ms-flex: 0 0 66.666667%;\n flex: 0 0 66.666667%;\n max-width: 66.666667%;\n }\n .col-xl-9 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 75%;\n -ms-flex: 0 0 75%;\n flex: 0 0 75%;\n max-width: 75%;\n }\n .col-xl-10 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 83.333333%;\n -ms-flex: 0 0 83.333333%;\n flex: 0 0 83.333333%;\n max-width: 83.333333%;\n }\n .col-xl-11 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 91.666667%;\n -ms-flex: 0 0 91.666667%;\n flex: 0 0 91.666667%;\n max-width: 91.666667%;\n }\n .col-xl-12 {\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 100%;\n -ms-flex: 0 0 100%;\n flex: 0 0 100%;\n max-width: 100%;\n }\n .pull-xl-0 {\n right: auto;\n }\n .pull-xl-1 {\n right: 8.333333%;\n }\n .pull-xl-2 {\n right: 16.666667%;\n }\n .pull-xl-3 {\n right: 25%;\n }\n .pull-xl-4 {\n right: 33.333333%;\n }\n .pull-xl-5 {\n right: 41.666667%;\n }\n .pull-xl-6 {\n right: 50%;\n }\n .pull-xl-7 {\n right: 58.333333%;\n }\n .pull-xl-8 {\n right: 66.666667%;\n }\n .pull-xl-9 {\n right: 75%;\n }\n .pull-xl-10 {\n right: 83.333333%;\n }\n .pull-xl-11 {\n right: 91.666667%;\n }\n .pull-xl-12 {\n right: 100%;\n }\n .push-xl-0 {\n left: auto;\n }\n .push-xl-1 {\n left: 8.333333%;\n }\n .push-xl-2 {\n left: 16.666667%;\n }\n .push-xl-3 {\n left: 25%;\n }\n .push-xl-4 {\n left: 33.333333%;\n }\n .push-xl-5 {\n left: 41.666667%;\n }\n .push-xl-6 {\n left: 50%;\n }\n .push-xl-7 {\n left: 58.333333%;\n }\n .push-xl-8 {\n left: 66.666667%;\n }\n .push-xl-9 {\n left: 75%;\n }\n .push-xl-10 {\n left: 83.333333%;\n }\n .push-xl-11 {\n left: 91.666667%;\n }\n .push-xl-12 {\n left: 100%;\n }\n .offset-xl-0 {\n margin-left: 0%;\n }\n .offset-xl-1 {\n margin-left: 8.333333%;\n }\n .offset-xl-2 {\n margin-left: 16.666667%;\n }\n .offset-xl-3 {\n margin-left: 25%;\n }\n .offset-xl-4 {\n margin-left: 33.333333%;\n }\n .offset-xl-5 {\n margin-left: 41.666667%;\n }\n .offset-xl-6 {\n margin-left: 50%;\n }\n .offset-xl-7 {\n margin-left: 58.333333%;\n }\n .offset-xl-8 {\n margin-left: 66.666667%;\n }\n .offset-xl-9 {\n margin-left: 75%;\n }\n .offset-xl-10 {\n margin-left: 83.333333%;\n }\n .offset-xl-11 {\n margin-left: 91.666667%;\n }\n}\n\n.table {\n width: 100%;\n max-width: 100%;\n margin-bottom: 1rem;\n}\n\n.table th,\n.table td {\n padding: 0.75rem;\n vertical-align: top;\n border-top: 1px solid #eceeef;\n}\n\n.table thead th {\n vertical-align: bottom;\n border-bottom: 2px solid #eceeef;\n}\n\n.table tbody + tbody {\n border-top: 2px solid #eceeef;\n}\n\n.table .table {\n background-color: #fff;\n}\n\n.table-sm th,\n.table-sm td {\n padding: 0.3rem;\n}\n\n.table-bordered {\n border: 1px solid #eceeef;\n}\n\n.table-bordered th,\n.table-bordered td {\n border: 1px solid #eceeef;\n}\n\n.table-bordered thead th,\n.table-bordered thead td {\n border-bottom-width: 2px;\n}\n\n.table-striped tbody tr:nth-of-type(odd) {\n background-color: rgba(0, 0, 0, 0.05);\n}\n\n.table-hover tbody tr:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-active,\n.table-active > th,\n.table-active > td {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-hover .table-active:hover > td,\n.table-hover .table-active:hover > th {\n background-color: rgba(0, 0, 0, 0.075);\n}\n\n.table-success,\n.table-success > th,\n.table-success > td {\n background-color: #dff0d8;\n}\n\n.table-hover .table-success:hover {\n background-color: #d0e9c6;\n}\n\n.table-hover .table-success:hover > td,\n.table-hover .table-success:hover > th {\n background-color: #d0e9c6;\n}\n\n.table-info,\n.table-info > th,\n.table-info > td {\n background-color: #d9edf7;\n}\n\n.table-hover .table-info:hover {\n background-color: #c4e3f3;\n}\n\n.table-hover .table-info:hover > td,\n.table-hover .table-info:hover > th {\n background-color: #c4e3f3;\n}\n\n.table-warning,\n.table-warning > th,\n.table-warning > td {\n background-color: #fcf8e3;\n}\n\n.table-hover .table-warning:hover {\n background-color: #faf2cc;\n}\n\n.table-hover .table-warning:hover > td,\n.table-hover .table-warning:hover > th {\n background-color: #faf2cc;\n}\n\n.table-danger,\n.table-danger > th,\n.table-danger > td {\n background-color: #f2dede;\n}\n\n.table-hover .table-danger:hover {\n background-color: #ebcccc;\n}\n\n.table-hover .table-danger:hover > td,\n.table-hover .table-danger:hover > th {\n background-color: #ebcccc;\n}\n\n.thead-inverse th {\n color: #fff;\n background-color: #292b2c;\n}\n\n.thead-default th {\n color: #464a4c;\n background-color: #eceeef;\n}\n\n.table-inverse {\n color: #fff;\n background-color: #292b2c;\n}\n\n.table-inverse th,\n.table-inverse td,\n.table-inverse thead th {\n border-color: #fff;\n}\n\n.table-inverse.table-bordered {\n border: 0;\n}\n\n.table-responsive {\n display: block;\n width: 100%;\n overflow-x: auto;\n -ms-overflow-style: -ms-autohiding-scrollbar;\n}\n\n.table-responsive.table-bordered {\n border: 0;\n}\n\n.form-control {\n display: block;\n width: 100%;\n padding: 0.5rem 0.75rem;\n font-size: 1rem;\n line-height: 1.25;\n color: #464a4c;\n background-color: #fff;\n background-image: none;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -webkit-transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n -o-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;\n transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s, -webkit-box-shadow ease-in-out 0.15s;\n}\n\n.form-control::-ms-expand {\n background-color: transparent;\n border: 0;\n}\n\n.form-control:focus {\n color: #464a4c;\n background-color: #fff;\n border-color: #5cb3fd;\n outline: none;\n}\n\n.form-control::-webkit-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::-moz-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:-ms-input-placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control::placeholder {\n color: #636c72;\n opacity: 1;\n}\n\n.form-control:disabled, .form-control[readonly] {\n background-color: #eceeef;\n opacity: 1;\n}\n\n.form-control:disabled {\n cursor: not-allowed;\n}\n\nselect.form-control:not([size]):not([multiple]) {\n height: calc(2.25rem + 2px);\n}\n\nselect.form-control:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.form-control-file,\n.form-control-range {\n display: block;\n}\n\n.col-form-label {\n padding-top: calc(0.5rem - 1px * 2);\n padding-bottom: calc(0.5rem - 1px * 2);\n margin-bottom: 0;\n}\n\n.col-form-label-lg {\n padding-top: calc(0.75rem - 1px * 2);\n padding-bottom: calc(0.75rem - 1px * 2);\n font-size: 1.25rem;\n}\n\n.col-form-label-sm {\n padding-top: calc(0.25rem - 1px * 2);\n padding-bottom: calc(0.25rem - 1px * 2);\n font-size: 0.875rem;\n}\n\n.col-form-legend {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n font-size: 1rem;\n}\n\n.form-control-static {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n margin-bottom: 0;\n line-height: 1.25;\n border: solid transparent;\n border-width: 1px 0;\n}\n\n.form-control-static.form-control-sm, .input-group-sm > .form-control-static.form-control,\n.input-group-sm > .form-control-static.input-group-addon,\n.input-group-sm > .input-group-btn > .form-control-static.btn, .form-control-static.form-control-lg, .input-group-lg > .form-control-static.form-control,\n.input-group-lg > .form-control-static.input-group-addon,\n.input-group-lg > .input-group-btn > .form-control-static.btn {\n padding-right: 0;\n padding-left: 0;\n}\n\n.form-control-sm, .input-group-sm > .form-control,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\nselect.form-control-sm:not([size]):not([multiple]), .input-group-sm > select.form-control:not([size]):not([multiple]),\n.input-group-sm > select.input-group-addon:not([size]):not([multiple]),\n.input-group-sm > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 1.8125rem;\n}\n\n.form-control-lg, .input-group-lg > .form-control,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\nselect.form-control-lg:not([size]):not([multiple]), .input-group-lg > select.form-control:not([size]):not([multiple]),\n.input-group-lg > select.input-group-addon:not([size]):not([multiple]),\n.input-group-lg > .input-group-btn > select.btn:not([size]):not([multiple]) {\n height: 3.166667rem;\n}\n\n.form-group {\n margin-bottom: 1rem;\n}\n\n.form-text {\n display: block;\n margin-top: 0.25rem;\n}\n\n.form-check {\n position: relative;\n display: block;\n margin-bottom: 0.5rem;\n}\n\n.form-check.disabled .form-check-label {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.form-check-label {\n padding-left: 1.25rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.form-check-input {\n position: absolute;\n margin-top: 0.25rem;\n margin-left: -1.25rem;\n}\n\n.form-check-input:only-child {\n position: static;\n}\n\n.form-check-inline {\n display: inline-block;\n}\n\n.form-check-inline .form-check-label {\n vertical-align: middle;\n}\n\n.form-check-inline + .form-check-inline {\n margin-left: 0.75rem;\n}\n\n.form-control-feedback {\n margin-top: 0.25rem;\n}\n\n.form-control-success,\n.form-control-warning,\n.form-control-danger {\n padding-right: 2.25rem;\n background-repeat: no-repeat;\n background-position: center right 0.5625rem;\n -webkit-background-size: 1.125rem 1.125rem;\n background-size: 1.125rem 1.125rem;\n}\n\n.has-success .form-control-feedback,\n.has-success .form-control-label,\n.has-success .col-form-label,\n.has-success .form-check-label,\n.has-success .custom-control {\n color: #5cb85c;\n}\n\n.has-success .form-control {\n border-color: #5cb85c;\n}\n\n.has-success .input-group-addon {\n color: #5cb85c;\n border-color: #5cb85c;\n background-color: #eaf6ea;\n}\n\n.has-success .form-control-success {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%235cb85c' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3E%3C/svg%3E\");\n}\n\n.has-warning .form-control-feedback,\n.has-warning .form-control-label,\n.has-warning .col-form-label,\n.has-warning .form-check-label,\n.has-warning .custom-control {\n color: #f0ad4e;\n}\n\n.has-warning .form-control {\n border-color: #f0ad4e;\n}\n\n.has-warning .input-group-addon {\n color: #f0ad4e;\n border-color: #f0ad4e;\n background-color: white;\n}\n\n.has-warning .form-control-warning {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23f0ad4e' d='M4.4 5.324h-.8v-2.46h.8zm0 1.42h-.8V5.89h.8zM3.76.63L.04 7.075c-.115.2.016.425.26.426h7.397c.242 0 .372-.226.258-.426C6.726 4.924 5.47 2.79 4.253.63c-.113-.174-.39-.174-.494 0z'/%3E%3C/svg%3E\");\n}\n\n.has-danger .form-control-feedback,\n.has-danger .form-control-label,\n.has-danger .col-form-label,\n.has-danger .form-check-label,\n.has-danger .custom-control {\n color: #d9534f;\n}\n\n.has-danger .form-control {\n border-color: #d9534f;\n}\n\n.has-danger .input-group-addon {\n color: #d9534f;\n border-color: #d9534f;\n background-color: #fdf7f7;\n}\n\n.has-danger .form-control-danger {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23d9534f' viewBox='-2 -2 7 7'%3E%3Cpath stroke='%23d9534f' d='M0 0l3 3m0-3L0 3'/%3E%3Ccircle r='.5'/%3E%3Ccircle cx='3' r='.5'/%3E%3Ccircle cy='3' r='.5'/%3E%3Ccircle cx='3' cy='3' r='.5'/%3E%3C/svg%3E\");\n}\n\n.form-inline {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.form-inline .form-check {\n width: 100%;\n}\n\n@media (min-width: 576px) {\n .form-inline label {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n margin-bottom: 0;\n }\n .form-inline .form-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 0;\n -webkit-flex: 0 0 auto;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n margin-bottom: 0;\n }\n .form-inline .form-control {\n display: inline-block;\n width: auto;\n vertical-align: middle;\n }\n .form-inline .form-control-static {\n display: inline-block;\n }\n .form-inline .input-group {\n width: auto;\n }\n .form-inline .form-control-label {\n margin-bottom: 0;\n vertical-align: middle;\n }\n .form-inline .form-check {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: auto;\n margin-top: 0;\n margin-bottom: 0;\n }\n .form-inline .form-check-label {\n padding-left: 0;\n }\n .form-inline .form-check-input {\n position: relative;\n margin-top: 0;\n margin-right: 0.25rem;\n margin-left: 0;\n }\n .form-inline .custom-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n }\n .form-inline .custom-control-indicator {\n position: static;\n display: inline-block;\n margin-right: 0.25rem;\n vertical-align: text-bottom;\n }\n .form-inline .has-feedback .form-control-feedback {\n top: 0;\n }\n}\n\n.btn {\n display: inline-block;\n font-weight: normal;\n line-height: 1.25;\n text-align: center;\n white-space: nowrap;\n vertical-align: middle;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n border: 1px solid transparent;\n padding: 0.5rem 1rem;\n font-size: 1rem;\n border-radius: 0.25rem;\n -webkit-transition: all 0.2s ease-in-out;\n -o-transition: all 0.2s ease-in-out;\n transition: all 0.2s ease-in-out;\n}\n\n.btn:focus, .btn:hover {\n text-decoration: none;\n}\n\n.btn:focus, .btn.focus {\n outline: 0;\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.25);\n}\n\n.btn.disabled, .btn:disabled {\n cursor: not-allowed;\n opacity: .65;\n}\n\n.btn:active, .btn.active {\n background-image: none;\n}\n\na.btn.disabled,\nfieldset[disabled] a.btn {\n pointer-events: none;\n}\n\n.btn-primary {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:hover {\n color: #fff;\n background-color: #025aa5;\n border-color: #01549b;\n}\n\n.btn-primary:focus, .btn-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-primary.disabled, .btn-primary:disabled {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-primary:active, .btn-primary.active,\n.show > .btn-primary.dropdown-toggle {\n color: #fff;\n background-color: #025aa5;\n background-image: none;\n border-color: #01549b;\n}\n\n.btn-secondary {\n color: #292b2c;\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:hover {\n color: #292b2c;\n background-color: #e6e6e6;\n border-color: #adadad;\n}\n\n.btn-secondary:focus, .btn-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-secondary.disabled, .btn-secondary:disabled {\n background-color: #fff;\n border-color: #ccc;\n}\n\n.btn-secondary:active, .btn-secondary.active,\n.show > .btn-secondary.dropdown-toggle {\n color: #292b2c;\n background-color: #e6e6e6;\n background-image: none;\n border-color: #adadad;\n}\n\n.btn-info {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:hover {\n color: #fff;\n background-color: #31b0d5;\n border-color: #2aabd2;\n}\n\n.btn-info:focus, .btn-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-info.disabled, .btn-info:disabled {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-info:active, .btn-info.active,\n.show > .btn-info.dropdown-toggle {\n color: #fff;\n background-color: #31b0d5;\n background-image: none;\n border-color: #2aabd2;\n}\n\n.btn-success {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:hover {\n color: #fff;\n background-color: #449d44;\n border-color: #419641;\n}\n\n.btn-success:focus, .btn-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-success.disabled, .btn-success:disabled {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-success:active, .btn-success.active,\n.show > .btn-success.dropdown-toggle {\n color: #fff;\n background-color: #449d44;\n background-image: none;\n border-color: #419641;\n}\n\n.btn-warning {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:hover {\n color: #fff;\n background-color: #ec971f;\n border-color: #eb9316;\n}\n\n.btn-warning:focus, .btn-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-warning.disabled, .btn-warning:disabled {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-warning:active, .btn-warning.active,\n.show > .btn-warning.dropdown-toggle {\n color: #fff;\n background-color: #ec971f;\n background-image: none;\n border-color: #eb9316;\n}\n\n.btn-danger {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:hover {\n color: #fff;\n background-color: #c9302c;\n border-color: #c12e2a;\n}\n\n.btn-danger:focus, .btn-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-danger.disabled, .btn-danger:disabled {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-danger:active, .btn-danger.active,\n.show > .btn-danger.dropdown-toggle {\n color: #fff;\n background-color: #c9302c;\n background-image: none;\n border-color: #c12e2a;\n}\n\n.btn-outline-primary {\n color: #0275d8;\n background-image: none;\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:hover {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-primary:focus, .btn-outline-primary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n box-shadow: 0 0 0 2px rgba(2, 117, 216, 0.5);\n}\n\n.btn-outline-primary.disabled, .btn-outline-primary:disabled {\n color: #0275d8;\n background-color: transparent;\n}\n\n.btn-outline-primary:active, .btn-outline-primary.active,\n.show > .btn-outline-primary.dropdown-toggle {\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.btn-outline-secondary {\n color: #ccc;\n background-image: none;\n background-color: transparent;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:hover {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-secondary:focus, .btn-outline-secondary.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n box-shadow: 0 0 0 2px rgba(204, 204, 204, 0.5);\n}\n\n.btn-outline-secondary.disabled, .btn-outline-secondary:disabled {\n color: #ccc;\n background-color: transparent;\n}\n\n.btn-outline-secondary:active, .btn-outline-secondary.active,\n.show > .btn-outline-secondary.dropdown-toggle {\n color: #fff;\n background-color: #ccc;\n border-color: #ccc;\n}\n\n.btn-outline-info {\n color: #5bc0de;\n background-image: none;\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:hover {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-info:focus, .btn-outline-info.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n box-shadow: 0 0 0 2px rgba(91, 192, 222, 0.5);\n}\n\n.btn-outline-info.disabled, .btn-outline-info:disabled {\n color: #5bc0de;\n background-color: transparent;\n}\n\n.btn-outline-info:active, .btn-outline-info.active,\n.show > .btn-outline-info.dropdown-toggle {\n color: #fff;\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.btn-outline-success {\n color: #5cb85c;\n background-image: none;\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:hover {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-success:focus, .btn-outline-success.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5);\n}\n\n.btn-outline-success.disabled, .btn-outline-success:disabled {\n color: #5cb85c;\n background-color: transparent;\n}\n\n.btn-outline-success:active, .btn-outline-success.active,\n.show > .btn-outline-success.dropdown-toggle {\n color: #fff;\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.btn-outline-warning {\n color: #f0ad4e;\n background-image: none;\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:hover {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-warning:focus, .btn-outline-warning.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.5);\n}\n\n.btn-outline-warning.disabled, .btn-outline-warning:disabled {\n color: #f0ad4e;\n background-color: transparent;\n}\n\n.btn-outline-warning:active, .btn-outline-warning.active,\n.show > .btn-outline-warning.dropdown-toggle {\n color: #fff;\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.btn-outline-danger {\n color: #d9534f;\n background-image: none;\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:hover {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-outline-danger:focus, .btn-outline-danger.focus {\n -webkit-box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.5);\n}\n\n.btn-outline-danger.disabled, .btn-outline-danger:disabled {\n color: #d9534f;\n background-color: transparent;\n}\n\n.btn-outline-danger:active, .btn-outline-danger.active,\n.show > .btn-outline-danger.dropdown-toggle {\n color: #fff;\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.btn-link {\n font-weight: normal;\n color: #0275d8;\n border-radius: 0;\n}\n\n.btn-link, .btn-link:active, .btn-link.active, .btn-link:disabled {\n background-color: transparent;\n}\n\n.btn-link, .btn-link:focus, .btn-link:active {\n border-color: transparent;\n}\n\n.btn-link:hover {\n border-color: transparent;\n}\n\n.btn-link:focus, .btn-link:hover {\n color: #014c8c;\n text-decoration: underline;\n background-color: transparent;\n}\n\n.btn-link:disabled {\n color: #636c72;\n}\n\n.btn-link:disabled:focus, .btn-link:disabled:hover {\n text-decoration: none;\n}\n\n.btn-lg, .btn-group-lg > .btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.btn-sm, .btn-group-sm > .btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.btn-block {\n display: block;\n width: 100%;\n}\n\n.btn-block + .btn-block {\n margin-top: 0.5rem;\n}\n\ninput[type=\"submit\"].btn-block,\ninput[type=\"reset\"].btn-block,\ninput[type=\"button\"].btn-block {\n width: 100%;\n}\n\n.fade {\n opacity: 0;\n -webkit-transition: opacity 0.15s linear;\n -o-transition: opacity 0.15s linear;\n transition: opacity 0.15s linear;\n}\n\n.fade.show {\n opacity: 1;\n}\n\n.collapse {\n display: none;\n}\n\n.collapse.show {\n display: block;\n}\n\ntr.collapse.show {\n display: table-row;\n}\n\ntbody.collapse.show {\n display: table-row-group;\n}\n\n.collapsing {\n position: relative;\n height: 0;\n overflow: hidden;\n -webkit-transition: height 0.35s ease;\n -o-transition: height 0.35s ease;\n transition: height 0.35s ease;\n}\n\n.dropup,\n.dropdown {\n position: relative;\n}\n\n.dropdown-toggle::after {\n display: inline-block;\n width: 0;\n height: 0;\n margin-left: 0.3em;\n vertical-align: middle;\n content: \"\";\n border-top: 0.3em solid;\n border-right: 0.3em solid transparent;\n border-left: 0.3em solid transparent;\n}\n\n.dropdown-toggle:focus {\n outline: 0;\n}\n\n.dropup .dropdown-toggle::after {\n border-top: 0;\n border-bottom: 0.3em solid;\n}\n\n.dropdown-menu {\n position: absolute;\n top: 100%;\n left: 0;\n z-index: 1000;\n display: none;\n float: left;\n min-width: 10rem;\n padding: 0.5rem 0;\n margin: 0.125rem 0 0;\n font-size: 1rem;\n color: #292b2c;\n text-align: left;\n list-style: none;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.dropdown-divider {\n height: 1px;\n margin: 0.5rem 0;\n overflow: hidden;\n background-color: #eceeef;\n}\n\n.dropdown-item {\n display: block;\n width: 100%;\n padding: 3px 1.5rem;\n clear: both;\n font-weight: normal;\n color: #292b2c;\n text-align: inherit;\n white-space: nowrap;\n background: none;\n border: 0;\n}\n\n.dropdown-item:focus, .dropdown-item:hover {\n color: #1d1e1f;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.dropdown-item.active, .dropdown-item:active {\n color: #fff;\n text-decoration: none;\n background-color: #0275d8;\n}\n\n.dropdown-item.disabled, .dropdown-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: transparent;\n}\n\n.show > .dropdown-menu {\n display: block;\n}\n\n.show > a {\n outline: 0;\n}\n\n.dropdown-menu-right {\n right: 0;\n left: auto;\n}\n\n.dropdown-menu-left {\n right: auto;\n left: 0;\n}\n\n.dropdown-header {\n display: block;\n padding: 0.5rem 1.5rem;\n margin-bottom: 0;\n font-size: 0.875rem;\n color: #636c72;\n white-space: nowrap;\n}\n\n.dropdown-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 990;\n}\n\n.dropup .dropdown-menu {\n top: auto;\n bottom: 100%;\n margin-bottom: 0.125rem;\n}\n\n.btn-group,\n.btn-group-vertical {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n vertical-align: middle;\n}\n\n.btn-group > .btn,\n.btn-group-vertical > .btn {\n position: relative;\n -webkit-box-flex: 0;\n -webkit-flex: 0 1 auto;\n -ms-flex: 0 1 auto;\n flex: 0 1 auto;\n}\n\n.btn-group > .btn:hover,\n.btn-group-vertical > .btn:hover {\n z-index: 2;\n}\n\n.btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active,\n.btn-group-vertical > .btn:focus,\n.btn-group-vertical > .btn:active,\n.btn-group-vertical > .btn.active {\n z-index: 2;\n}\n\n.btn-group .btn + .btn,\n.btn-group .btn + .btn-group,\n.btn-group .btn-group + .btn,\n.btn-group .btn-group + .btn-group,\n.btn-group-vertical .btn + .btn,\n.btn-group-vertical .btn + .btn-group,\n.btn-group-vertical .btn-group + .btn,\n.btn-group-vertical .btn-group + .btn-group {\n margin-left: -1px;\n}\n\n.btn-toolbar {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: start;\n -webkit-justify-content: flex-start;\n -ms-flex-pack: start;\n justify-content: flex-start;\n}\n\n.btn-toolbar .input-group {\n width: auto;\n}\n\n.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {\n border-radius: 0;\n}\n\n.btn-group > .btn:first-child {\n margin-left: 0;\n}\n\n.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn:last-child:not(:first-child),\n.btn-group > .dropdown-toggle:not(:first-child) {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group > .btn-group {\n float: left;\n}\n\n.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group .dropdown-toggle:active,\n.btn-group.open .dropdown-toggle {\n outline: 0;\n}\n\n.btn + .dropdown-toggle-split {\n padding-right: 0.75rem;\n padding-left: 0.75rem;\n}\n\n.btn + .dropdown-toggle-split::after {\n margin-left: 0;\n}\n\n.btn-sm + .dropdown-toggle-split, .btn-group-sm > .btn + .dropdown-toggle-split {\n padding-right: 0.375rem;\n padding-left: 0.375rem;\n}\n\n.btn-lg + .dropdown-toggle-split, .btn-group-lg > .btn + .dropdown-toggle-split {\n padding-right: 1.125rem;\n padding-left: 1.125rem;\n}\n\n.btn-group-vertical {\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.btn-group-vertical .btn,\n.btn-group-vertical .btn-group {\n width: 100%;\n}\n\n.btn-group-vertical > .btn + .btn,\n.btn-group-vertical > .btn + .btn-group,\n.btn-group-vertical > .btn-group + .btn,\n.btn-group-vertical > .btn-group + .btn-group {\n margin-top: -1px;\n margin-left: 0;\n}\n\n.btn-group-vertical > .btn:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn:first-child:not(:last-child) {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn:last-child:not(:first-child) {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,\n.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n[data-toggle=\"buttons\"] > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn input[type=\"checkbox\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn-group > .btn input[type=\"checkbox\"] {\n position: absolute;\n clip: rect(0, 0, 0, 0);\n pointer-events: none;\n}\n\n.input-group {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n width: 100%;\n}\n\n.input-group .form-control {\n position: relative;\n z-index: 2;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n width: 1%;\n margin-bottom: 0;\n}\n\n.input-group .form-control:focus, .input-group .form-control:active, .input-group .form-control:hover {\n z-index: 3;\n}\n\n.input-group-addon,\n.input-group-btn,\n.input-group .form-control {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.input-group-addon:not(:first-child):not(:last-child),\n.input-group-btn:not(:first-child):not(:last-child),\n.input-group .form-control:not(:first-child):not(:last-child) {\n border-radius: 0;\n}\n\n.input-group-addon,\n.input-group-btn {\n white-space: nowrap;\n vertical-align: middle;\n}\n\n.input-group-addon {\n padding: 0.5rem 0.75rem;\n margin-bottom: 0;\n font-size: 1rem;\n font-weight: normal;\n line-height: 1.25;\n color: #464a4c;\n text-align: center;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.input-group-addon.form-control-sm,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .input-group-addon.btn {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n border-radius: 0.2rem;\n}\n\n.input-group-addon.form-control-lg,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .input-group-addon.btn {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n border-radius: 0.3rem;\n}\n\n.input-group-addon input[type=\"radio\"],\n.input-group-addon input[type=\"checkbox\"] {\n margin-top: 0;\n}\n\n.input-group .form-control:not(:last-child),\n.input-group-addon:not(:last-child),\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group > .btn,\n.input-group-btn:not(:last-child) > .dropdown-toggle,\n.input-group-btn:not(:first-child) > .btn:not(:last-child):not(.dropdown-toggle),\n.input-group-btn:not(:first-child) > .btn-group:not(:last-child) > .btn {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n}\n\n.input-group-addon:not(:last-child) {\n border-right: 0;\n}\n\n.input-group .form-control:not(:first-child),\n.input-group-addon:not(:first-child),\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group > .btn,\n.input-group-btn:not(:first-child) > .dropdown-toggle,\n.input-group-btn:not(:last-child) > .btn:not(:first-child),\n.input-group-btn:not(:last-child) > .btn-group:not(:first-child) > .btn {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n}\n\n.form-control + .input-group-addon:not(:first-child) {\n border-left: 0;\n}\n\n.input-group-btn {\n position: relative;\n font-size: 0;\n white-space: nowrap;\n}\n\n.input-group-btn > .btn {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.input-group-btn > .btn + .btn {\n margin-left: -1px;\n}\n\n.input-group-btn > .btn:focus, .input-group-btn > .btn:active, .input-group-btn > .btn:hover {\n z-index: 3;\n}\n\n.input-group-btn:not(:last-child) > .btn,\n.input-group-btn:not(:last-child) > .btn-group {\n margin-right: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn,\n.input-group-btn:not(:first-child) > .btn-group {\n z-index: 2;\n margin-left: -1px;\n}\n\n.input-group-btn:not(:first-child) > .btn:focus, .input-group-btn:not(:first-child) > .btn:active, .input-group-btn:not(:first-child) > .btn:hover,\n.input-group-btn:not(:first-child) > .btn-group:focus,\n.input-group-btn:not(:first-child) > .btn-group:active,\n.input-group-btn:not(:first-child) > .btn-group:hover {\n z-index: 3;\n}\n\n.custom-control {\n position: relative;\n display: -webkit-inline-box;\n display: -webkit-inline-flex;\n display: -ms-inline-flexbox;\n display: inline-flex;\n min-height: 1.5rem;\n padding-left: 1.5rem;\n margin-right: 1rem;\n cursor: pointer;\n}\n\n.custom-control-input {\n position: absolute;\n z-index: -1;\n opacity: 0;\n}\n\n.custom-control-input:checked ~ .custom-control-indicator {\n color: #fff;\n background-color: #0275d8;\n}\n\n.custom-control-input:focus ~ .custom-control-indicator {\n -webkit-box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n box-shadow: 0 0 0 1px #fff, 0 0 0 3px #0275d8;\n}\n\n.custom-control-input:active ~ .custom-control-indicator {\n color: #fff;\n background-color: #8fcafe;\n}\n\n.custom-control-input:disabled ~ .custom-control-indicator {\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-control-input:disabled ~ .custom-control-description {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.custom-control-indicator {\n position: absolute;\n top: 0.25rem;\n left: 0;\n display: block;\n width: 1rem;\n height: 1rem;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #ddd;\n background-repeat: no-repeat;\n background-position: center center;\n -webkit-background-size: 50% 50%;\n background-size: 50% 50%;\n}\n\n.custom-checkbox .custom-control-indicator {\n border-radius: 0.25rem;\n}\n\n.custom-checkbox .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26 2.974 7.25 8 2.193z'/%3E%3C/svg%3E\");\n}\n\n.custom-checkbox .custom-control-input:indeterminate ~ .custom-control-indicator {\n background-color: #0275d8;\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 4'%3E%3Cpath stroke='%23fff' d='M0 2h4'/%3E%3C/svg%3E\");\n}\n\n.custom-radio .custom-control-indicator {\n border-radius: 50%;\n}\n\n.custom-radio .custom-control-input:checked ~ .custom-control-indicator {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3E%3Ccircle r='3' fill='%23fff'/%3E%3C/svg%3E\");\n}\n\n.custom-controls-stacked {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n\n.custom-controls-stacked .custom-control {\n margin-bottom: 0.25rem;\n}\n\n.custom-controls-stacked .custom-control + .custom-control {\n margin-left: 0;\n}\n\n.custom-select {\n display: inline-block;\n max-width: 100%;\n height: calc(2.25rem + 2px);\n padding: 0.375rem 1.75rem 0.375rem 0.75rem;\n line-height: 1.25;\n color: #464a4c;\n vertical-align: middle;\n background: #fff url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23333' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E\") no-repeat right 0.75rem center;\n -webkit-background-size: 8px 10px;\n background-size: 8px 10px;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n -moz-appearance: none;\n -webkit-appearance: none;\n}\n\n.custom-select:focus {\n border-color: #5cb3fd;\n outline: none;\n}\n\n.custom-select:focus::-ms-value {\n color: #464a4c;\n background-color: #fff;\n}\n\n.custom-select:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #eceeef;\n}\n\n.custom-select::-ms-expand {\n opacity: 0;\n}\n\n.custom-select-sm {\n padding-top: 0.375rem;\n padding-bottom: 0.375rem;\n font-size: 75%;\n}\n\n.custom-file {\n position: relative;\n display: inline-block;\n max-width: 100%;\n height: 2.5rem;\n margin-bottom: 0;\n cursor: pointer;\n}\n\n.custom-file-input {\n min-width: 14rem;\n max-width: 100%;\n height: 2.5rem;\n margin: 0;\n filter: alpha(opacity=0);\n opacity: 0;\n}\n\n.custom-file-control {\n position: absolute;\n top: 0;\n right: 0;\n left: 0;\n z-index: 5;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0.25rem;\n}\n\n.custom-file-control:lang(en)::after {\n content: \"Choose file...\";\n}\n\n.custom-file-control::before {\n position: absolute;\n top: -1px;\n right: -1px;\n bottom: -1px;\n z-index: 6;\n display: block;\n height: 2.5rem;\n padding: 0.5rem 1rem;\n line-height: 1.5;\n color: #464a4c;\n background-color: #eceeef;\n border: 1px solid rgba(0, 0, 0, 0.15);\n border-radius: 0 0.25rem 0.25rem 0;\n}\n\n.custom-file-control:lang(en)::before {\n content: \"Browse\";\n}\n\n.nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.nav-link {\n display: block;\n padding: 0.5em 1em;\n}\n\n.nav-link:focus, .nav-link:hover {\n text-decoration: none;\n}\n\n.nav-link.disabled {\n color: #636c72;\n cursor: not-allowed;\n}\n\n.nav-tabs {\n border-bottom: 1px solid #ddd;\n}\n\n.nav-tabs .nav-item {\n margin-bottom: -1px;\n}\n\n.nav-tabs .nav-link {\n border: 1px solid transparent;\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.nav-tabs .nav-link:focus, .nav-tabs .nav-link:hover {\n border-color: #eceeef #eceeef #ddd;\n}\n\n.nav-tabs .nav-link.disabled {\n color: #636c72;\n background-color: transparent;\n border-color: transparent;\n}\n\n.nav-tabs .nav-link.active,\n.nav-tabs .nav-item.show .nav-link {\n color: #464a4c;\n background-color: #fff;\n border-color: #ddd #ddd #fff;\n}\n\n.nav-tabs .dropdown-menu {\n margin-top: -1px;\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.nav-pills .nav-link {\n border-radius: 0.25rem;\n}\n\n.nav-pills .nav-link.active,\n.nav-pills .nav-item.show .nav-link {\n color: #fff;\n cursor: default;\n background-color: #0275d8;\n}\n\n.nav-fill .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n text-align: center;\n}\n\n.nav-justified .nav-item {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 100%;\n -ms-flex: 1 1 100%;\n flex: 1 1 100%;\n text-align: center;\n}\n\n.tab-content > .tab-pane {\n display: none;\n}\n\n.tab-content > .active {\n display: block;\n}\n\n.navbar {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding: 0.5rem 1rem;\n}\n\n.navbar-brand {\n display: inline-block;\n padding-top: .25rem;\n padding-bottom: .25rem;\n margin-right: 1rem;\n font-size: 1.25rem;\n line-height: inherit;\n white-space: nowrap;\n}\n\n.navbar-brand:focus, .navbar-brand:hover {\n text-decoration: none;\n}\n\n.navbar-nav {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n list-style: none;\n}\n\n.navbar-nav .nav-link {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-text {\n display: inline-block;\n padding-top: .425rem;\n padding-bottom: .425rem;\n}\n\n.navbar-toggler {\n -webkit-align-self: flex-start;\n -ms-flex-item-align: start;\n align-self: flex-start;\n padding: 0.25rem 0.75rem;\n font-size: 1.25rem;\n line-height: 1;\n background: transparent;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.navbar-toggler:focus, .navbar-toggler:hover {\n text-decoration: none;\n}\n\n.navbar-toggler-icon {\n display: inline-block;\n width: 1.5em;\n height: 1.5em;\n vertical-align: middle;\n content: \"\";\n background: no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.navbar-toggler-left {\n position: absolute;\n left: 1rem;\n}\n\n.navbar-toggler-right {\n position: absolute;\n right: 1rem;\n}\n\n@media (max-width: 575px) {\n .navbar-toggleable .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 576px) {\n .navbar-toggleable {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 767px) {\n .navbar-toggleable-sm .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-sm > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 768px) {\n .navbar-toggleable-sm {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-sm .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-sm > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-sm .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-sm .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 991px) {\n .navbar-toggleable-md .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-md > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 992px) {\n .navbar-toggleable-md {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-md .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-md > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-md .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-md .navbar-toggler {\n display: none;\n }\n}\n\n@media (max-width: 1199px) {\n .navbar-toggleable-lg .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n }\n .navbar-toggleable-lg > .container {\n padding-right: 0;\n padding-left: 0;\n }\n}\n\n@media (min-width: 1200px) {\n .navbar-toggleable-lg {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n }\n .navbar-toggleable-lg .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n }\n .navbar-toggleable-lg > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n }\n .navbar-toggleable-lg .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n }\n .navbar-toggleable-lg .navbar-toggler {\n display: none;\n }\n}\n\n.navbar-toggleable-xl {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-nav .dropdown-menu {\n position: static;\n float: none;\n}\n\n.navbar-toggleable-xl > .container {\n padding-right: 0;\n padding-left: 0;\n}\n\n.navbar-toggleable-xl .navbar-nav {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n\n.navbar-toggleable-xl .navbar-nav .nav-link {\n padding-right: .5rem;\n padding-left: .5rem;\n}\n\n.navbar-toggleable-xl > .container {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-wrap: nowrap;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n.navbar-toggleable-xl .navbar-collapse {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n width: 100%;\n}\n\n.navbar-toggleable-xl .navbar-toggler {\n display: none;\n}\n\n.navbar-light .navbar-brand,\n.navbar-light .navbar-toggler {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-brand:focus, .navbar-light .navbar-brand:hover,\n.navbar-light .navbar-toggler:focus,\n.navbar-light .navbar-toggler:hover {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-nav .nav-link {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-light .navbar-nav .nav-link:focus, .navbar-light .navbar-nav .nav-link:hover {\n color: rgba(0, 0, 0, 0.7);\n}\n\n.navbar-light .navbar-nav .nav-link.disabled {\n color: rgba(0, 0, 0, 0.3);\n}\n\n.navbar-light .navbar-nav .open > .nav-link,\n.navbar-light .navbar-nav .active > .nav-link,\n.navbar-light .navbar-nav .nav-link.open,\n.navbar-light .navbar-nav .nav-link.active {\n color: rgba(0, 0, 0, 0.9);\n}\n\n.navbar-light .navbar-toggler {\n border-color: rgba(0, 0, 0, 0.1);\n}\n\n.navbar-light .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(0, 0, 0, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-light .navbar-text {\n color: rgba(0, 0, 0, 0.5);\n}\n\n.navbar-inverse .navbar-brand,\n.navbar-inverse .navbar-toggler {\n color: white;\n}\n\n.navbar-inverse .navbar-brand:focus, .navbar-inverse .navbar-brand:hover,\n.navbar-inverse .navbar-toggler:focus,\n.navbar-inverse .navbar-toggler:hover {\n color: white;\n}\n\n.navbar-inverse .navbar-nav .nav-link {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.navbar-inverse .navbar-nav .nav-link:focus, .navbar-inverse .navbar-nav .nav-link:hover {\n color: rgba(255, 255, 255, 0.75);\n}\n\n.navbar-inverse .navbar-nav .nav-link.disabled {\n color: rgba(255, 255, 255, 0.25);\n}\n\n.navbar-inverse .navbar-nav .open > .nav-link,\n.navbar-inverse .navbar-nav .active > .nav-link,\n.navbar-inverse .navbar-nav .nav-link.open,\n.navbar-inverse .navbar-nav .nav-link.active {\n color: white;\n}\n\n.navbar-inverse .navbar-toggler {\n border-color: rgba(255, 255, 255, 0.1);\n}\n\n.navbar-inverse .navbar-toggler-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255, 255, 255, 0.5)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E\");\n}\n\n.navbar-inverse .navbar-text {\n color: rgba(255, 255, 255, 0.5);\n}\n\n.card {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n border-radius: 0.25rem;\n}\n\n.card-block {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 1.25rem;\n}\n\n.card-title {\n margin-bottom: 0.75rem;\n}\n\n.card-subtitle {\n margin-top: -0.375rem;\n margin-bottom: 0;\n}\n\n.card-text:last-child {\n margin-bottom: 0;\n}\n\n.card-link:hover {\n text-decoration: none;\n}\n\n.card-link + .card-link {\n margin-left: 1.25rem;\n}\n\n.card > .list-group:first-child .list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.card > .list-group:last-child .list-group-item:last-child {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.card-header {\n padding: 0.75rem 1.25rem;\n margin-bottom: 0;\n background-color: #f7f7f9;\n border-bottom: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-header:first-child {\n border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;\n}\n\n.card-footer {\n padding: 0.75rem 1.25rem;\n background-color: #f7f7f9;\n border-top: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.card-footer:last-child {\n border-radius: 0 0 calc(0.25rem - 1px) calc(0.25rem - 1px);\n}\n\n.card-header-tabs {\n margin-right: -0.625rem;\n margin-bottom: -0.75rem;\n margin-left: -0.625rem;\n border-bottom: 0;\n}\n\n.card-header-pills {\n margin-right: -0.625rem;\n margin-left: -0.625rem;\n}\n\n.card-primary {\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.card-primary .card-header,\n.card-primary .card-footer {\n background-color: transparent;\n}\n\n.card-success {\n background-color: #5cb85c;\n border-color: #5cb85c;\n}\n\n.card-success .card-header,\n.card-success .card-footer {\n background-color: transparent;\n}\n\n.card-info {\n background-color: #5bc0de;\n border-color: #5bc0de;\n}\n\n.card-info .card-header,\n.card-info .card-footer {\n background-color: transparent;\n}\n\n.card-warning {\n background-color: #f0ad4e;\n border-color: #f0ad4e;\n}\n\n.card-warning .card-header,\n.card-warning .card-footer {\n background-color: transparent;\n}\n\n.card-danger {\n background-color: #d9534f;\n border-color: #d9534f;\n}\n\n.card-danger .card-header,\n.card-danger .card-footer {\n background-color: transparent;\n}\n\n.card-outline-primary {\n background-color: transparent;\n border-color: #0275d8;\n}\n\n.card-outline-secondary {\n background-color: transparent;\n border-color: #ccc;\n}\n\n.card-outline-info {\n background-color: transparent;\n border-color: #5bc0de;\n}\n\n.card-outline-success {\n background-color: transparent;\n border-color: #5cb85c;\n}\n\n.card-outline-warning {\n background-color: transparent;\n border-color: #f0ad4e;\n}\n\n.card-outline-danger {\n background-color: transparent;\n border-color: #d9534f;\n}\n\n.card-inverse {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer {\n background-color: transparent;\n border-color: rgba(255, 255, 255, 0.2);\n}\n\n.card-inverse .card-header,\n.card-inverse .card-footer,\n.card-inverse .card-title,\n.card-inverse .card-blockquote {\n color: #fff;\n}\n\n.card-inverse .card-link,\n.card-inverse .card-text,\n.card-inverse .card-subtitle,\n.card-inverse .card-blockquote .blockquote-footer {\n color: rgba(255, 255, 255, 0.65);\n}\n\n.card-inverse .card-link:focus, .card-inverse .card-link:hover {\n color: #fff;\n}\n\n.card-blockquote {\n padding: 0;\n margin-bottom: 0;\n border-left: 0;\n}\n\n.card-img {\n border-radius: calc(0.25rem - 1px);\n}\n\n.card-img-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n padding: 1.25rem;\n}\n\n.card-img-top {\n border-top-right-radius: calc(0.25rem - 1px);\n border-top-left-radius: calc(0.25rem - 1px);\n}\n\n.card-img-bottom {\n border-bottom-right-radius: calc(0.25rem - 1px);\n border-bottom-left-radius: calc(0.25rem - 1px);\n}\n\n@media (min-width: 576px) {\n .card-deck {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-deck .card {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n }\n .card-deck .card:not(:first-child) {\n margin-left: 15px;\n }\n .card-deck .card:not(:last-child) {\n margin-right: 15px;\n }\n}\n\n@media (min-width: 576px) {\n .card-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n }\n .card-group .card {\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 0%;\n -ms-flex: 1 0 0%;\n flex: 1 0 0%;\n }\n .card-group .card + .card {\n margin-left: 0;\n border-left: 0;\n }\n .card-group .card:first-child {\n border-bottom-right-radius: 0;\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-top {\n border-top-right-radius: 0;\n }\n .card-group .card:first-child .card-img-bottom {\n border-bottom-right-radius: 0;\n }\n .card-group .card:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-top {\n border-top-left-radius: 0;\n }\n .card-group .card:last-child .card-img-bottom {\n border-bottom-left-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) {\n border-radius: 0;\n }\n .card-group .card:not(:first-child):not(:last-child) .card-img-top,\n .card-group .card:not(:first-child):not(:last-child) .card-img-bottom {\n border-radius: 0;\n }\n}\n\n@media (min-width: 576px) {\n .card-columns {\n -webkit-column-count: 3;\n -moz-column-count: 3;\n column-count: 3;\n -webkit-column-gap: 1.25rem;\n -moz-column-gap: 1.25rem;\n column-gap: 1.25rem;\n }\n .card-columns .card {\n display: inline-block;\n width: 100%;\n margin-bottom: 0.75rem;\n }\n}\n\n.breadcrumb {\n padding: 0.75rem 1rem;\n margin-bottom: 1rem;\n list-style: none;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.breadcrumb::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.breadcrumb-item {\n float: left;\n}\n\n.breadcrumb-item + .breadcrumb-item::before {\n display: inline-block;\n padding-right: 0.5rem;\n padding-left: 0.5rem;\n color: #636c72;\n content: \"/\";\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: underline;\n}\n\n.breadcrumb-item + .breadcrumb-item:hover::before {\n text-decoration: none;\n}\n\n.breadcrumb-item.active {\n color: #636c72;\n}\n\n.pagination {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n padding-left: 0;\n list-style: none;\n border-radius: 0.25rem;\n}\n\n.page-item:first-child .page-link {\n margin-left: 0;\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.page-item:last-child .page-link {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.page-item.active .page-link {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.page-item.disabled .page-link {\n color: #636c72;\n pointer-events: none;\n cursor: not-allowed;\n background-color: #fff;\n border-color: #ddd;\n}\n\n.page-link {\n position: relative;\n display: block;\n padding: 0.5rem 0.75rem;\n margin-left: -1px;\n line-height: 1.25;\n color: #0275d8;\n background-color: #fff;\n border: 1px solid #ddd;\n}\n\n.page-link:focus, .page-link:hover {\n color: #014c8c;\n text-decoration: none;\n background-color: #eceeef;\n border-color: #ddd;\n}\n\n.pagination-lg .page-link {\n padding: 0.75rem 1.5rem;\n font-size: 1.25rem;\n}\n\n.pagination-lg .page-item:first-child .page-link {\n border-bottom-left-radius: 0.3rem;\n border-top-left-radius: 0.3rem;\n}\n\n.pagination-lg .page-item:last-child .page-link {\n border-bottom-right-radius: 0.3rem;\n border-top-right-radius: 0.3rem;\n}\n\n.pagination-sm .page-link {\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n}\n\n.pagination-sm .page-item:first-child .page-link {\n border-bottom-left-radius: 0.2rem;\n border-top-left-radius: 0.2rem;\n}\n\n.pagination-sm .page-item:last-child .page-link {\n border-bottom-right-radius: 0.2rem;\n border-top-right-radius: 0.2rem;\n}\n\n.badge {\n display: inline-block;\n padding: 0.25em 0.4em;\n font-size: 75%;\n font-weight: bold;\n line-height: 1;\n color: #fff;\n text-align: center;\n white-space: nowrap;\n vertical-align: baseline;\n border-radius: 0.25rem;\n}\n\n.badge:empty {\n display: none;\n}\n\n.btn .badge {\n position: relative;\n top: -1px;\n}\n\na.badge:focus, a.badge:hover {\n color: #fff;\n text-decoration: none;\n cursor: pointer;\n}\n\n.badge-pill {\n padding-right: 0.6em;\n padding-left: 0.6em;\n border-radius: 10rem;\n}\n\n.badge-default {\n background-color: #636c72;\n}\n\n.badge-default[href]:focus, .badge-default[href]:hover {\n background-color: #4b5257;\n}\n\n.badge-primary {\n background-color: #0275d8;\n}\n\n.badge-primary[href]:focus, .badge-primary[href]:hover {\n background-color: #025aa5;\n}\n\n.badge-success {\n background-color: #5cb85c;\n}\n\n.badge-success[href]:focus, .badge-success[href]:hover {\n background-color: #449d44;\n}\n\n.badge-info {\n background-color: #5bc0de;\n}\n\n.badge-info[href]:focus, .badge-info[href]:hover {\n background-color: #31b0d5;\n}\n\n.badge-warning {\n background-color: #f0ad4e;\n}\n\n.badge-warning[href]:focus, .badge-warning[href]:hover {\n background-color: #ec971f;\n}\n\n.badge-danger {\n background-color: #d9534f;\n}\n\n.badge-danger[href]:focus, .badge-danger[href]:hover {\n background-color: #c9302c;\n}\n\n.jumbotron {\n padding: 2rem 1rem;\n margin-bottom: 2rem;\n background-color: #eceeef;\n border-radius: 0.3rem;\n}\n\n@media (min-width: 576px) {\n .jumbotron {\n padding: 4rem 2rem;\n }\n}\n\n.jumbotron-hr {\n border-top-color: #d0d5d8;\n}\n\n.jumbotron-fluid {\n padding-right: 0;\n padding-left: 0;\n border-radius: 0;\n}\n\n.alert {\n padding: 0.75rem 1.25rem;\n margin-bottom: 1rem;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n}\n\n.alert-heading {\n color: inherit;\n}\n\n.alert-link {\n font-weight: bold;\n}\n\n.alert-dismissible .close {\n position: relative;\n top: -0.75rem;\n right: -1.25rem;\n padding: 0.75rem 1.25rem;\n color: inherit;\n}\n\n.alert-success {\n background-color: #dff0d8;\n border-color: #d0e9c6;\n color: #3c763d;\n}\n\n.alert-success hr {\n border-top-color: #c1e2b3;\n}\n\n.alert-success .alert-link {\n color: #2b542c;\n}\n\n.alert-info {\n background-color: #d9edf7;\n border-color: #bcdff1;\n color: #31708f;\n}\n\n.alert-info hr {\n border-top-color: #a6d5ec;\n}\n\n.alert-info .alert-link {\n color: #245269;\n}\n\n.alert-warning {\n background-color: #fcf8e3;\n border-color: #faf2cc;\n color: #8a6d3b;\n}\n\n.alert-warning hr {\n border-top-color: #f7ecb5;\n}\n\n.alert-warning .alert-link {\n color: #66512c;\n}\n\n.alert-danger {\n background-color: #f2dede;\n border-color: #ebcccc;\n color: #a94442;\n}\n\n.alert-danger hr {\n border-top-color: #e4b9b9;\n}\n\n.alert-danger .alert-link {\n color: #843534;\n}\n\n@-webkit-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@-o-keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n@keyframes progress-bar-stripes {\n from {\n background-position: 1rem 0;\n }\n to {\n background-position: 0 0;\n }\n}\n\n.progress {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n overflow: hidden;\n font-size: 0.75rem;\n line-height: 1rem;\n text-align: center;\n background-color: #eceeef;\n border-radius: 0.25rem;\n}\n\n.progress-bar {\n height: 1rem;\n color: #fff;\n background-color: #0275d8;\n}\n\n.progress-bar-striped {\n background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);\n -webkit-background-size: 1rem 1rem;\n background-size: 1rem 1rem;\n}\n\n.progress-bar-animated {\n -webkit-animation: progress-bar-stripes 1s linear infinite;\n -o-animation: progress-bar-stripes 1s linear infinite;\n animation: progress-bar-stripes 1s linear infinite;\n}\n\n.media {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: start;\n -webkit-align-items: flex-start;\n -ms-flex-align: start;\n align-items: flex-start;\n}\n\n.media-body {\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 0%;\n -ms-flex: 1 1 0%;\n flex: 1 1 0%;\n}\n\n.list-group {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n padding-left: 0;\n margin-bottom: 0;\n}\n\n.list-group-item-action {\n width: 100%;\n color: #464a4c;\n text-align: inherit;\n}\n\n.list-group-item-action .list-group-item-heading {\n color: #292b2c;\n}\n\n.list-group-item-action:focus, .list-group-item-action:hover {\n color: #464a4c;\n text-decoration: none;\n background-color: #f7f7f9;\n}\n\n.list-group-item-action:active {\n color: #292b2c;\n background-color: #eceeef;\n}\n\n.list-group-item {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-flex-flow: row wrap;\n -ms-flex-flow: row wrap;\n flex-flow: row wrap;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n padding: 0.75rem 1.25rem;\n margin-bottom: -1px;\n background-color: #fff;\n border: 1px solid rgba(0, 0, 0, 0.125);\n}\n\n.list-group-item:first-child {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.list-group-item:last-child {\n margin-bottom: 0;\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.list-group-item:focus, .list-group-item:hover {\n text-decoration: none;\n}\n\n.list-group-item.disabled, .list-group-item:disabled {\n color: #636c72;\n cursor: not-allowed;\n background-color: #fff;\n}\n\n.list-group-item.disabled .list-group-item-heading, .list-group-item:disabled .list-group-item-heading {\n color: inherit;\n}\n\n.list-group-item.disabled .list-group-item-text, .list-group-item:disabled .list-group-item-text {\n color: #636c72;\n}\n\n.list-group-item.active {\n z-index: 2;\n color: #fff;\n background-color: #0275d8;\n border-color: #0275d8;\n}\n\n.list-group-item.active .list-group-item-heading,\n.list-group-item.active .list-group-item-heading > small,\n.list-group-item.active .list-group-item-heading > .small {\n color: inherit;\n}\n\n.list-group-item.active .list-group-item-text {\n color: #daeeff;\n}\n\n.list-group-flush .list-group-item {\n border-right: 0;\n border-left: 0;\n border-radius: 0;\n}\n\n.list-group-flush:first-child .list-group-item:first-child {\n border-top: 0;\n}\n\n.list-group-flush:last-child .list-group-item:last-child {\n border-bottom: 0;\n}\n\n.list-group-item-success {\n color: #3c763d;\n background-color: #dff0d8;\n}\n\na.list-group-item-success,\nbutton.list-group-item-success {\n color: #3c763d;\n}\n\na.list-group-item-success .list-group-item-heading,\nbutton.list-group-item-success .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-success:focus, a.list-group-item-success:hover,\nbutton.list-group-item-success:focus,\nbutton.list-group-item-success:hover {\n color: #3c763d;\n background-color: #d0e9c6;\n}\n\na.list-group-item-success.active,\nbutton.list-group-item-success.active {\n color: #fff;\n background-color: #3c763d;\n border-color: #3c763d;\n}\n\n.list-group-item-info {\n color: #31708f;\n background-color: #d9edf7;\n}\n\na.list-group-item-info,\nbutton.list-group-item-info {\n color: #31708f;\n}\n\na.list-group-item-info .list-group-item-heading,\nbutton.list-group-item-info .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-info:focus, a.list-group-item-info:hover,\nbutton.list-group-item-info:focus,\nbutton.list-group-item-info:hover {\n color: #31708f;\n background-color: #c4e3f3;\n}\n\na.list-group-item-info.active,\nbutton.list-group-item-info.active {\n color: #fff;\n background-color: #31708f;\n border-color: #31708f;\n}\n\n.list-group-item-warning {\n color: #8a6d3b;\n background-color: #fcf8e3;\n}\n\na.list-group-item-warning,\nbutton.list-group-item-warning {\n color: #8a6d3b;\n}\n\na.list-group-item-warning .list-group-item-heading,\nbutton.list-group-item-warning .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-warning:focus, a.list-group-item-warning:hover,\nbutton.list-group-item-warning:focus,\nbutton.list-group-item-warning:hover {\n color: #8a6d3b;\n background-color: #faf2cc;\n}\n\na.list-group-item-warning.active,\nbutton.list-group-item-warning.active {\n color: #fff;\n background-color: #8a6d3b;\n border-color: #8a6d3b;\n}\n\n.list-group-item-danger {\n color: #a94442;\n background-color: #f2dede;\n}\n\na.list-group-item-danger,\nbutton.list-group-item-danger {\n color: #a94442;\n}\n\na.list-group-item-danger .list-group-item-heading,\nbutton.list-group-item-danger .list-group-item-heading {\n color: inherit;\n}\n\na.list-group-item-danger:focus, a.list-group-item-danger:hover,\nbutton.list-group-item-danger:focus,\nbutton.list-group-item-danger:hover {\n color: #a94442;\n background-color: #ebcccc;\n}\n\na.list-group-item-danger.active,\nbutton.list-group-item-danger.active {\n color: #fff;\n background-color: #a94442;\n border-color: #a94442;\n}\n\n.embed-responsive {\n position: relative;\n display: block;\n width: 100%;\n padding: 0;\n overflow: hidden;\n}\n\n.embed-responsive::before {\n display: block;\n content: \"\";\n}\n\n.embed-responsive .embed-responsive-item,\n.embed-responsive iframe,\n.embed-responsive embed,\n.embed-responsive object,\n.embed-responsive video {\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 100%;\n border: 0;\n}\n\n.embed-responsive-21by9::before {\n padding-top: 42.857143%;\n}\n\n.embed-responsive-16by9::before {\n padding-top: 56.25%;\n}\n\n.embed-responsive-4by3::before {\n padding-top: 75%;\n}\n\n.embed-responsive-1by1::before {\n padding-top: 100%;\n}\n\n.close {\n float: right;\n font-size: 1.5rem;\n font-weight: bold;\n line-height: 1;\n color: #000;\n text-shadow: 0 1px 0 #fff;\n opacity: .5;\n}\n\n.close:focus, .close:hover {\n color: #000;\n text-decoration: none;\n cursor: pointer;\n opacity: .75;\n}\n\nbutton.close {\n padding: 0;\n cursor: pointer;\n background: transparent;\n border: 0;\n -webkit-appearance: none;\n}\n\n.modal-open {\n overflow: hidden;\n}\n\n.modal {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1050;\n display: none;\n overflow: hidden;\n outline: 0;\n}\n\n.modal.fade .modal-dialog {\n -webkit-transition: -webkit-transform 0.3s ease-out;\n transition: -webkit-transform 0.3s ease-out;\n -o-transition: -o-transform 0.3s ease-out;\n transition: transform 0.3s ease-out;\n transition: transform 0.3s ease-out, -webkit-transform 0.3s ease-out, -o-transform 0.3s ease-out;\n -webkit-transform: translate(0, -25%);\n -o-transform: translate(0, -25%);\n transform: translate(0, -25%);\n}\n\n.modal.show .modal-dialog {\n -webkit-transform: translate(0, 0);\n -o-transform: translate(0, 0);\n transform: translate(0, 0);\n}\n\n.modal-open .modal {\n overflow-x: hidden;\n overflow-y: auto;\n}\n\n.modal-dialog {\n position: relative;\n width: auto;\n margin: 10px;\n}\n\n.modal-content {\n position: relative;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -ms-flex-direction: column;\n flex-direction: column;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n outline: 0;\n}\n\n.modal-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1040;\n background-color: #000;\n}\n\n.modal-backdrop.fade {\n opacity: 0;\n}\n\n.modal-backdrop.show {\n opacity: 0.5;\n}\n\n.modal-header {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n -webkit-justify-content: space-between;\n -ms-flex-pack: justify;\n justify-content: space-between;\n padding: 15px;\n border-bottom: 1px solid #eceeef;\n}\n\n.modal-title {\n margin-bottom: 0;\n line-height: 1.5;\n}\n\n.modal-body {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 1 auto;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n padding: 15px;\n}\n\n.modal-footer {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: end;\n -webkit-justify-content: flex-end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n padding: 15px;\n border-top: 1px solid #eceeef;\n}\n\n.modal-footer > :not(:first-child) {\n margin-left: .25rem;\n}\n\n.modal-footer > :not(:last-child) {\n margin-right: .25rem;\n}\n\n.modal-scrollbar-measure {\n position: absolute;\n top: -9999px;\n width: 50px;\n height: 50px;\n overflow: scroll;\n}\n\n@media (min-width: 576px) {\n .modal-dialog {\n max-width: 500px;\n margin: 30px auto;\n }\n .modal-sm {\n max-width: 300px;\n }\n}\n\n@media (min-width: 992px) {\n .modal-lg {\n max-width: 800px;\n }\n}\n\n.tooltip {\n position: absolute;\n z-index: 1070;\n display: block;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n opacity: 0;\n}\n\n.tooltip.show {\n opacity: 0.9;\n}\n\n.tooltip.tooltip-top, .tooltip.bs-tether-element-attached-bottom {\n padding: 5px 0;\n margin-top: -3px;\n}\n\n.tooltip.tooltip-top .tooltip-inner::before, .tooltip.bs-tether-element-attached-bottom .tooltip-inner::before {\n bottom: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 5px 5px 0;\n border-top-color: #000;\n}\n\n.tooltip.tooltip-right, .tooltip.bs-tether-element-attached-left {\n padding: 0 5px;\n margin-left: 3px;\n}\n\n.tooltip.tooltip-right .tooltip-inner::before, .tooltip.bs-tether-element-attached-left .tooltip-inner::before {\n top: 50%;\n left: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 5px 5px 0;\n border-right-color: #000;\n}\n\n.tooltip.tooltip-bottom, .tooltip.bs-tether-element-attached-top {\n padding: 5px 0;\n margin-top: 3px;\n}\n\n.tooltip.tooltip-bottom .tooltip-inner::before, .tooltip.bs-tether-element-attached-top .tooltip-inner::before {\n top: 0;\n left: 50%;\n margin-left: -5px;\n content: \"\";\n border-width: 0 5px 5px;\n border-bottom-color: #000;\n}\n\n.tooltip.tooltip-left, .tooltip.bs-tether-element-attached-right {\n padding: 0 5px;\n margin-left: -3px;\n}\n\n.tooltip.tooltip-left .tooltip-inner::before, .tooltip.bs-tether-element-attached-right .tooltip-inner::before {\n top: 50%;\n right: 0;\n margin-top: -5px;\n content: \"\";\n border-width: 5px 0 5px 5px;\n border-left-color: #000;\n}\n\n.tooltip-inner {\n max-width: 200px;\n padding: 3px 8px;\n color: #fff;\n text-align: center;\n background-color: #000;\n border-radius: 0.25rem;\n}\n\n.tooltip-inner::before {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1060;\n display: block;\n max-width: 276px;\n padding: 1px;\n font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n line-break: auto;\n line-height: 1.5;\n text-align: left;\n text-align: start;\n text-decoration: none;\n text-shadow: none;\n text-transform: none;\n white-space: normal;\n word-break: normal;\n word-spacing: normal;\n font-size: 0.875rem;\n word-wrap: break-word;\n background-color: #fff;\n -webkit-background-clip: padding-box;\n background-clip: padding-box;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: 0.3rem;\n}\n\n.popover.popover-top, .popover.bs-tether-element-attached-bottom {\n margin-top: -10px;\n}\n\n.popover.popover-top::before, .popover.popover-top::after, .popover.bs-tether-element-attached-bottom::before, .popover.bs-tether-element-attached-bottom::after {\n left: 50%;\n border-bottom-width: 0;\n}\n\n.popover.popover-top::before, .popover.bs-tether-element-attached-bottom::before {\n bottom: -11px;\n margin-left: -11px;\n border-top-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-top::after, .popover.bs-tether-element-attached-bottom::after {\n bottom: -10px;\n margin-left: -10px;\n border-top-color: #fff;\n}\n\n.popover.popover-right, .popover.bs-tether-element-attached-left {\n margin-left: 10px;\n}\n\n.popover.popover-right::before, .popover.popover-right::after, .popover.bs-tether-element-attached-left::before, .popover.bs-tether-element-attached-left::after {\n top: 50%;\n border-left-width: 0;\n}\n\n.popover.popover-right::before, .popover.bs-tether-element-attached-left::before {\n left: -11px;\n margin-top: -11px;\n border-right-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-right::after, .popover.bs-tether-element-attached-left::after {\n left: -10px;\n margin-top: -10px;\n border-right-color: #fff;\n}\n\n.popover.popover-bottom, .popover.bs-tether-element-attached-top {\n margin-top: 10px;\n}\n\n.popover.popover-bottom::before, .popover.popover-bottom::after, .popover.bs-tether-element-attached-top::before, .popover.bs-tether-element-attached-top::after {\n left: 50%;\n border-top-width: 0;\n}\n\n.popover.popover-bottom::before, .popover.bs-tether-element-attached-top::before {\n top: -11px;\n margin-left: -11px;\n border-bottom-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-bottom::after, .popover.bs-tether-element-attached-top::after {\n top: -10px;\n margin-left: -10px;\n border-bottom-color: #f7f7f7;\n}\n\n.popover.popover-bottom .popover-title::before, .popover.bs-tether-element-attached-top .popover-title::before {\n position: absolute;\n top: 0;\n left: 50%;\n display: block;\n width: 20px;\n margin-left: -10px;\n content: \"\";\n border-bottom: 1px solid #f7f7f7;\n}\n\n.popover.popover-left, .popover.bs-tether-element-attached-right {\n margin-left: -10px;\n}\n\n.popover.popover-left::before, .popover.popover-left::after, .popover.bs-tether-element-attached-right::before, .popover.bs-tether-element-attached-right::after {\n top: 50%;\n border-right-width: 0;\n}\n\n.popover.popover-left::before, .popover.bs-tether-element-attached-right::before {\n right: -11px;\n margin-top: -11px;\n border-left-color: rgba(0, 0, 0, 0.25);\n}\n\n.popover.popover-left::after, .popover.bs-tether-element-attached-right::after {\n right: -10px;\n margin-top: -10px;\n border-left-color: #fff;\n}\n\n.popover-title {\n padding: 8px 14px;\n margin-bottom: 0;\n font-size: 1rem;\n background-color: #f7f7f7;\n border-bottom: 1px solid #ebebeb;\n border-top-right-radius: calc(0.3rem - 1px);\n border-top-left-radius: calc(0.3rem - 1px);\n}\n\n.popover-title:empty {\n display: none;\n}\n\n.popover-content {\n padding: 9px 14px;\n}\n\n.popover::before,\n.popover::after {\n position: absolute;\n display: block;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n\n.popover::before {\n content: \"\";\n border-width: 11px;\n}\n\n.popover::after {\n content: \"\";\n border-width: 10px;\n}\n\n.carousel {\n position: relative;\n}\n\n.carousel-inner {\n position: relative;\n width: 100%;\n overflow: hidden;\n}\n\n.carousel-item {\n position: relative;\n display: none;\n width: 100%;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item {\n -webkit-transition: -webkit-transform 0.6s ease-in-out;\n transition: -webkit-transform 0.6s ease-in-out;\n -o-transition: -o-transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out;\n transition: transform 0.6s ease-in-out, -webkit-transform 0.6s ease-in-out, -o-transform 0.6s ease-in-out;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-perspective: 1000px;\n perspective: 1000px;\n }\n}\n\n.carousel-item.active,\n.carousel-item-next,\n.carousel-item-prev {\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n}\n\n.carousel-item-next,\n.carousel-item-prev {\n position: absolute;\n top: 0;\n}\n\n@media (-webkit-transform-3d) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n@supports ((-webkit-transform: translate3d(0, 0, 0)) or (transform: translate3d(0, 0, 0))) {\n .carousel-item-next.carousel-item-left,\n .carousel-item-prev.carousel-item-right {\n -webkit-transform: translate3d(0, 0, 0);\n transform: translate3d(0, 0, 0);\n }\n .carousel-item-next,\n .active.carousel-item-right {\n -webkit-transform: translate3d(100%, 0, 0);\n transform: translate3d(100%, 0, 0);\n }\n .carousel-item-prev,\n .active.carousel-item-left {\n -webkit-transform: translate3d(-100%, 0, 0);\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n.carousel-control-prev,\n.carousel-control-next {\n position: absolute;\n top: 0;\n bottom: 0;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n width: 15%;\n color: #fff;\n text-align: center;\n opacity: 0.5;\n}\n\n.carousel-control-prev:focus, .carousel-control-prev:hover,\n.carousel-control-next:focus,\n.carousel-control-next:hover {\n color: #fff;\n text-decoration: none;\n outline: 0;\n opacity: .9;\n}\n\n.carousel-control-prev {\n left: 0;\n}\n\n.carousel-control-next {\n right: 0;\n}\n\n.carousel-control-prev-icon,\n.carousel-control-next-icon {\n display: inline-block;\n width: 20px;\n height: 20px;\n background: transparent no-repeat center center;\n -webkit-background-size: 100% 100%;\n background-size: 100% 100%;\n}\n\n.carousel-control-prev-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M4 0l-4 4 4 4 1.5-1.5-2.5-2.5 2.5-2.5-1.5-1.5z'/%3E%3C/svg%3E\");\n}\n\n.carousel-control-next-icon {\n background-image: url(\"data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23fff' viewBox='0 0 8 8'%3E%3Cpath d='M1.5 0l-1.5 1.5 2.5 2.5-2.5 2.5 1.5 1.5 4-4-4-4z'/%3E%3C/svg%3E\");\n}\n\n.carousel-indicators {\n position: absolute;\n right: 0;\n bottom: 10px;\n left: 0;\n z-index: 15;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -webkit-justify-content: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding-left: 0;\n margin-right: 15%;\n margin-left: 15%;\n list-style: none;\n}\n\n.carousel-indicators li {\n position: relative;\n -webkit-box-flex: 1;\n -webkit-flex: 1 0 auto;\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n max-width: 30px;\n height: 3px;\n margin-right: 3px;\n margin-left: 3px;\n text-indent: -999px;\n cursor: pointer;\n background-color: rgba(255, 255, 255, 0.5);\n}\n\n.carousel-indicators li::before {\n position: absolute;\n top: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators li::after {\n position: absolute;\n bottom: -10px;\n left: 0;\n display: inline-block;\n width: 100%;\n height: 10px;\n content: \"\";\n}\n\n.carousel-indicators .active {\n background-color: #fff;\n}\n\n.carousel-caption {\n position: absolute;\n right: 15%;\n bottom: 20px;\n left: 15%;\n z-index: 10;\n padding-top: 20px;\n padding-bottom: 20px;\n color: #fff;\n text-align: center;\n}\n\n.align-baseline {\n vertical-align: baseline !important;\n}\n\n.align-top {\n vertical-align: top !important;\n}\n\n.align-middle {\n vertical-align: middle !important;\n}\n\n.align-bottom {\n vertical-align: bottom !important;\n}\n\n.align-text-bottom {\n vertical-align: text-bottom !important;\n}\n\n.align-text-top {\n vertical-align: text-top !important;\n}\n\n.bg-faded {\n background-color: #f7f7f7;\n}\n\n.bg-primary {\n background-color: #0275d8 !important;\n}\n\na.bg-primary:focus, a.bg-primary:hover {\n background-color: #025aa5 !important;\n}\n\n.bg-success {\n background-color: #5cb85c !important;\n}\n\na.bg-success:focus, a.bg-success:hover {\n background-color: #449d44 !important;\n}\n\n.bg-info {\n background-color: #5bc0de !important;\n}\n\na.bg-info:focus, a.bg-info:hover {\n background-color: #31b0d5 !important;\n}\n\n.bg-warning {\n background-color: #f0ad4e !important;\n}\n\na.bg-warning:focus, a.bg-warning:hover {\n background-color: #ec971f !important;\n}\n\n.bg-danger {\n background-color: #d9534f !important;\n}\n\na.bg-danger:focus, a.bg-danger:hover {\n background-color: #c9302c !important;\n}\n\n.bg-inverse {\n background-color: #292b2c !important;\n}\n\na.bg-inverse:focus, a.bg-inverse:hover {\n background-color: #101112 !important;\n}\n\n.border-0 {\n border: 0 !important;\n}\n\n.border-top-0 {\n border-top: 0 !important;\n}\n\n.border-right-0 {\n border-right: 0 !important;\n}\n\n.border-bottom-0 {\n border-bottom: 0 !important;\n}\n\n.border-left-0 {\n border-left: 0 !important;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.rounded-top {\n border-top-right-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-right {\n border-bottom-right-radius: 0.25rem;\n border-top-right-radius: 0.25rem;\n}\n\n.rounded-bottom {\n border-bottom-right-radius: 0.25rem;\n border-bottom-left-radius: 0.25rem;\n}\n\n.rounded-left {\n border-bottom-left-radius: 0.25rem;\n border-top-left-radius: 0.25rem;\n}\n\n.rounded-circle {\n border-radius: 50%;\n}\n\n.rounded-0 {\n border-radius: 0;\n}\n\n.clearfix::after {\n display: block;\n content: \"\";\n clear: both;\n}\n\n.d-none {\n display: none !important;\n}\n\n.d-inline {\n display: inline !important;\n}\n\n.d-inline-block {\n display: inline-block !important;\n}\n\n.d-block {\n display: block !important;\n}\n\n.d-table {\n display: table !important;\n}\n\n.d-table-cell {\n display: table-cell !important;\n}\n\n.d-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n}\n\n.d-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n}\n\n@media (min-width: 576px) {\n .d-sm-none {\n display: none !important;\n }\n .d-sm-inline {\n display: inline !important;\n }\n .d-sm-inline-block {\n display: inline-block !important;\n }\n .d-sm-block {\n display: block !important;\n }\n .d-sm-table {\n display: table !important;\n }\n .d-sm-table-cell {\n display: table-cell !important;\n }\n .d-sm-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-sm-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 768px) {\n .d-md-none {\n display: none !important;\n }\n .d-md-inline {\n display: inline !important;\n }\n .d-md-inline-block {\n display: inline-block !important;\n }\n .d-md-block {\n display: block !important;\n }\n .d-md-table {\n display: table !important;\n }\n .d-md-table-cell {\n display: table-cell !important;\n }\n .d-md-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-md-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 992px) {\n .d-lg-none {\n display: none !important;\n }\n .d-lg-inline {\n display: inline !important;\n }\n .d-lg-inline-block {\n display: inline-block !important;\n }\n .d-lg-block {\n display: block !important;\n }\n .d-lg-table {\n display: table !important;\n }\n .d-lg-table-cell {\n display: table-cell !important;\n }\n .d-lg-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-lg-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n@media (min-width: 1200px) {\n .d-xl-none {\n display: none !important;\n }\n .d-xl-inline {\n display: inline !important;\n }\n .d-xl-inline-block {\n display: inline-block !important;\n }\n .d-xl-block {\n display: block !important;\n }\n .d-xl-table {\n display: table !important;\n }\n .d-xl-table-cell {\n display: table-cell !important;\n }\n .d-xl-flex {\n display: -webkit-box !important;\n display: -webkit-flex !important;\n display: -ms-flexbox !important;\n display: flex !important;\n }\n .d-xl-inline-flex {\n display: -webkit-inline-box !important;\n display: -webkit-inline-flex !important;\n display: -ms-inline-flexbox !important;\n display: inline-flex !important;\n }\n}\n\n.flex-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n}\n\n.flex-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n}\n\n.flex-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n}\n\n.flex-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n}\n\n.flex-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n}\n\n.flex-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n}\n\n.flex-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n}\n\n.flex-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n}\n\n.flex-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n}\n\n.flex-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n}\n\n.justify-content-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n}\n\n.justify-content-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n}\n\n.justify-content-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n}\n\n.justify-content-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n}\n\n.justify-content-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n}\n\n.align-items-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n}\n\n.align-items-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n}\n\n.align-items-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n}\n\n.align-items-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n}\n\n.align-items-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n}\n\n.align-content-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n}\n\n.align-content-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n}\n\n.align-content-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n}\n\n.align-content-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n}\n\n.align-content-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n}\n\n.align-content-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n}\n\n.align-self-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n}\n\n.align-self-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n}\n\n.align-self-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n}\n\n.align-self-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n}\n\n.align-self-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n}\n\n.align-self-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n}\n\n@media (min-width: 576px) {\n .flex-sm-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-sm-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-sm-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-sm-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-sm-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-sm-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-sm-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-sm-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-sm-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-sm-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-sm-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-sm-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-sm-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-sm-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-sm-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-sm-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-sm-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-sm-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-sm-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-sm-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-sm-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-sm-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-sm-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-sm-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-sm-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-sm-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-sm-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-sm-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-sm-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-sm-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-sm-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-sm-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 768px) {\n .flex-md-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-md-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-md-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-md-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-md-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-md-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-md-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-md-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-md-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-md-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-md-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-md-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-md-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-md-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-md-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-md-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-md-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-md-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-md-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-md-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-md-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-md-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-md-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-md-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-md-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-md-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-md-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-md-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-md-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-md-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-md-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-md-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 992px) {\n .flex-lg-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-lg-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-lg-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-lg-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-lg-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-lg-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-lg-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-lg-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-lg-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-lg-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-lg-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-lg-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-lg-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-lg-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-lg-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-lg-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-lg-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-lg-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-lg-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-lg-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-lg-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-lg-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-lg-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-lg-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-lg-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-lg-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-lg-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-lg-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-lg-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-lg-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-lg-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-lg-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n@media (min-width: 1200px) {\n .flex-xl-first {\n -webkit-box-ordinal-group: 0;\n -webkit-order: -1;\n -ms-flex-order: -1;\n order: -1;\n }\n .flex-xl-last {\n -webkit-box-ordinal-group: 2;\n -webkit-order: 1;\n -ms-flex-order: 1;\n order: 1;\n }\n .flex-xl-unordered {\n -webkit-box-ordinal-group: 1;\n -webkit-order: 0;\n -ms-flex-order: 0;\n order: 0;\n }\n .flex-xl-row {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: row !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n }\n .flex-xl-column {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -webkit-flex-direction: column !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n }\n .flex-xl-row-reverse {\n -webkit-box-orient: horizontal !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: row-reverse !important;\n -ms-flex-direction: row-reverse !important;\n flex-direction: row-reverse !important;\n }\n .flex-xl-column-reverse {\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: reverse !important;\n -webkit-flex-direction: column-reverse !important;\n -ms-flex-direction: column-reverse !important;\n flex-direction: column-reverse !important;\n }\n .flex-xl-wrap {\n -webkit-flex-wrap: wrap !important;\n -ms-flex-wrap: wrap !important;\n flex-wrap: wrap !important;\n }\n .flex-xl-nowrap {\n -webkit-flex-wrap: nowrap !important;\n -ms-flex-wrap: nowrap !important;\n flex-wrap: nowrap !important;\n }\n .flex-xl-wrap-reverse {\n -webkit-flex-wrap: wrap-reverse !important;\n -ms-flex-wrap: wrap-reverse !important;\n flex-wrap: wrap-reverse !important;\n }\n .justify-content-xl-start {\n -webkit-box-pack: start !important;\n -webkit-justify-content: flex-start !important;\n -ms-flex-pack: start !important;\n justify-content: flex-start !important;\n }\n .justify-content-xl-end {\n -webkit-box-pack: end !important;\n -webkit-justify-content: flex-end !important;\n -ms-flex-pack: end !important;\n justify-content: flex-end !important;\n }\n .justify-content-xl-center {\n -webkit-box-pack: center !important;\n -webkit-justify-content: center !important;\n -ms-flex-pack: center !important;\n justify-content: center !important;\n }\n .justify-content-xl-between {\n -webkit-box-pack: justify !important;\n -webkit-justify-content: space-between !important;\n -ms-flex-pack: justify !important;\n justify-content: space-between !important;\n }\n .justify-content-xl-around {\n -webkit-justify-content: space-around !important;\n -ms-flex-pack: distribute !important;\n justify-content: space-around !important;\n }\n .align-items-xl-start {\n -webkit-box-align: start !important;\n -webkit-align-items: flex-start !important;\n -ms-flex-align: start !important;\n align-items: flex-start !important;\n }\n .align-items-xl-end {\n -webkit-box-align: end !important;\n -webkit-align-items: flex-end !important;\n -ms-flex-align: end !important;\n align-items: flex-end !important;\n }\n .align-items-xl-center {\n -webkit-box-align: center !important;\n -webkit-align-items: center !important;\n -ms-flex-align: center !important;\n align-items: center !important;\n }\n .align-items-xl-baseline {\n -webkit-box-align: baseline !important;\n -webkit-align-items: baseline !important;\n -ms-flex-align: baseline !important;\n align-items: baseline !important;\n }\n .align-items-xl-stretch {\n -webkit-box-align: stretch !important;\n -webkit-align-items: stretch !important;\n -ms-flex-align: stretch !important;\n align-items: stretch !important;\n }\n .align-content-xl-start {\n -webkit-align-content: flex-start !important;\n -ms-flex-line-pack: start !important;\n align-content: flex-start !important;\n }\n .align-content-xl-end {\n -webkit-align-content: flex-end !important;\n -ms-flex-line-pack: end !important;\n align-content: flex-end !important;\n }\n .align-content-xl-center {\n -webkit-align-content: center !important;\n -ms-flex-line-pack: center !important;\n align-content: center !important;\n }\n .align-content-xl-between {\n -webkit-align-content: space-between !important;\n -ms-flex-line-pack: justify !important;\n align-content: space-between !important;\n }\n .align-content-xl-around {\n -webkit-align-content: space-around !important;\n -ms-flex-line-pack: distribute !important;\n align-content: space-around !important;\n }\n .align-content-xl-stretch {\n -webkit-align-content: stretch !important;\n -ms-flex-line-pack: stretch !important;\n align-content: stretch !important;\n }\n .align-self-xl-auto {\n -webkit-align-self: auto !important;\n -ms-flex-item-align: auto !important;\n -ms-grid-row-align: auto !important;\n align-self: auto !important;\n }\n .align-self-xl-start {\n -webkit-align-self: flex-start !important;\n -ms-flex-item-align: start !important;\n align-self: flex-start !important;\n }\n .align-self-xl-end {\n -webkit-align-self: flex-end !important;\n -ms-flex-item-align: end !important;\n align-self: flex-end !important;\n }\n .align-self-xl-center {\n -webkit-align-self: center !important;\n -ms-flex-item-align: center !important;\n -ms-grid-row-align: center !important;\n align-self: center !important;\n }\n .align-self-xl-baseline {\n -webkit-align-self: baseline !important;\n -ms-flex-item-align: baseline !important;\n align-self: baseline !important;\n }\n .align-self-xl-stretch {\n -webkit-align-self: stretch !important;\n -ms-flex-item-align: stretch !important;\n -ms-grid-row-align: stretch !important;\n align-self: stretch !important;\n }\n}\n\n.float-left {\n float: left !important;\n}\n\n.float-right {\n float: right !important;\n}\n\n.float-none {\n float: none !important;\n}\n\n@media (min-width: 576px) {\n .float-sm-left {\n float: left !important;\n }\n .float-sm-right {\n float: right !important;\n }\n .float-sm-none {\n float: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .float-md-left {\n float: left !important;\n }\n .float-md-right {\n float: right !important;\n }\n .float-md-none {\n float: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .float-lg-left {\n float: left !important;\n }\n .float-lg-right {\n float: right !important;\n }\n .float-lg-none {\n float: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .float-xl-left {\n float: left !important;\n }\n .float-xl-right {\n float: right !important;\n }\n .float-xl-none {\n float: none !important;\n }\n}\n\n.fixed-top {\n position: fixed;\n top: 0;\n right: 0;\n left: 0;\n z-index: 1030;\n}\n\n.fixed-bottom {\n position: fixed;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1030;\n}\n\n.sticky-top {\n position: -webkit-sticky;\n position: sticky;\n top: 0;\n z-index: 1030;\n}\n\n.sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n border: 0;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n position: static;\n width: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n clip: auto;\n}\n\n.w-25 {\n width: 25% !important;\n}\n\n.w-50 {\n width: 50% !important;\n}\n\n.w-75 {\n width: 75% !important;\n}\n\n.w-100 {\n width: 100% !important;\n}\n\n.h-25 {\n height: 25% !important;\n}\n\n.h-50 {\n height: 50% !important;\n}\n\n.h-75 {\n height: 75% !important;\n}\n\n.h-100 {\n height: 100% !important;\n}\n\n.mw-100 {\n max-width: 100% !important;\n}\n\n.mh-100 {\n max-height: 100% !important;\n}\n\n.m-0 {\n margin: 0 0 !important;\n}\n\n.mt-0 {\n margin-top: 0 !important;\n}\n\n.mr-0 {\n margin-right: 0 !important;\n}\n\n.mb-0 {\n margin-bottom: 0 !important;\n}\n\n.ml-0 {\n margin-left: 0 !important;\n}\n\n.mx-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n}\n\n.my-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n}\n\n.m-1 {\n margin: 0.25rem 0.25rem !important;\n}\n\n.mt-1 {\n margin-top: 0.25rem !important;\n}\n\n.mr-1 {\n margin-right: 0.25rem !important;\n}\n\n.mb-1 {\n margin-bottom: 0.25rem !important;\n}\n\n.ml-1 {\n margin-left: 0.25rem !important;\n}\n\n.mx-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n}\n\n.my-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n}\n\n.m-2 {\n margin: 0.5rem 0.5rem !important;\n}\n\n.mt-2 {\n margin-top: 0.5rem !important;\n}\n\n.mr-2 {\n margin-right: 0.5rem !important;\n}\n\n.mb-2 {\n margin-bottom: 0.5rem !important;\n}\n\n.ml-2 {\n margin-left: 0.5rem !important;\n}\n\n.mx-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n}\n\n.my-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n}\n\n.m-3 {\n margin: 1rem 1rem !important;\n}\n\n.mt-3 {\n margin-top: 1rem !important;\n}\n\n.mr-3 {\n margin-right: 1rem !important;\n}\n\n.mb-3 {\n margin-bottom: 1rem !important;\n}\n\n.ml-3 {\n margin-left: 1rem !important;\n}\n\n.mx-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n}\n\n.my-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n}\n\n.m-4 {\n margin: 1.5rem 1.5rem !important;\n}\n\n.mt-4 {\n margin-top: 1.5rem !important;\n}\n\n.mr-4 {\n margin-right: 1.5rem !important;\n}\n\n.mb-4 {\n margin-bottom: 1.5rem !important;\n}\n\n.ml-4 {\n margin-left: 1.5rem !important;\n}\n\n.mx-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n}\n\n.my-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n}\n\n.m-5 {\n margin: 3rem 3rem !important;\n}\n\n.mt-5 {\n margin-top: 3rem !important;\n}\n\n.mr-5 {\n margin-right: 3rem !important;\n}\n\n.mb-5 {\n margin-bottom: 3rem !important;\n}\n\n.ml-5 {\n margin-left: 3rem !important;\n}\n\n.mx-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n}\n\n.my-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n}\n\n.p-0 {\n padding: 0 0 !important;\n}\n\n.pt-0 {\n padding-top: 0 !important;\n}\n\n.pr-0 {\n padding-right: 0 !important;\n}\n\n.pb-0 {\n padding-bottom: 0 !important;\n}\n\n.pl-0 {\n padding-left: 0 !important;\n}\n\n.px-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n}\n\n.py-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n}\n\n.p-1 {\n padding: 0.25rem 0.25rem !important;\n}\n\n.pt-1 {\n padding-top: 0.25rem !important;\n}\n\n.pr-1 {\n padding-right: 0.25rem !important;\n}\n\n.pb-1 {\n padding-bottom: 0.25rem !important;\n}\n\n.pl-1 {\n padding-left: 0.25rem !important;\n}\n\n.px-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n}\n\n.py-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n}\n\n.p-2 {\n padding: 0.5rem 0.5rem !important;\n}\n\n.pt-2 {\n padding-top: 0.5rem !important;\n}\n\n.pr-2 {\n padding-right: 0.5rem !important;\n}\n\n.pb-2 {\n padding-bottom: 0.5rem !important;\n}\n\n.pl-2 {\n padding-left: 0.5rem !important;\n}\n\n.px-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n}\n\n.py-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n}\n\n.p-3 {\n padding: 1rem 1rem !important;\n}\n\n.pt-3 {\n padding-top: 1rem !important;\n}\n\n.pr-3 {\n padding-right: 1rem !important;\n}\n\n.pb-3 {\n padding-bottom: 1rem !important;\n}\n\n.pl-3 {\n padding-left: 1rem !important;\n}\n\n.px-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n}\n\n.py-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n}\n\n.p-4 {\n padding: 1.5rem 1.5rem !important;\n}\n\n.pt-4 {\n padding-top: 1.5rem !important;\n}\n\n.pr-4 {\n padding-right: 1.5rem !important;\n}\n\n.pb-4 {\n padding-bottom: 1.5rem !important;\n}\n\n.pl-4 {\n padding-left: 1.5rem !important;\n}\n\n.px-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n}\n\n.py-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n}\n\n.p-5 {\n padding: 3rem 3rem !important;\n}\n\n.pt-5 {\n padding-top: 3rem !important;\n}\n\n.pr-5 {\n padding-right: 3rem !important;\n}\n\n.pb-5 {\n padding-bottom: 3rem !important;\n}\n\n.pl-5 {\n padding-left: 3rem !important;\n}\n\n.px-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n}\n\n.py-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n}\n\n.m-auto {\n margin: auto !important;\n}\n\n.mt-auto {\n margin-top: auto !important;\n}\n\n.mr-auto {\n margin-right: auto !important;\n}\n\n.mb-auto {\n margin-bottom: auto !important;\n}\n\n.ml-auto {\n margin-left: auto !important;\n}\n\n.mx-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n}\n\n.my-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n}\n\n@media (min-width: 576px) {\n .m-sm-0 {\n margin: 0 0 !important;\n }\n .mt-sm-0 {\n margin-top: 0 !important;\n }\n .mr-sm-0 {\n margin-right: 0 !important;\n }\n .mb-sm-0 {\n margin-bottom: 0 !important;\n }\n .ml-sm-0 {\n margin-left: 0 !important;\n }\n .mx-sm-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-sm-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-sm-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-sm-1 {\n margin-top: 0.25rem !important;\n }\n .mr-sm-1 {\n margin-right: 0.25rem !important;\n }\n .mb-sm-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-sm-1 {\n margin-left: 0.25rem !important;\n }\n .mx-sm-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-sm-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-sm-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-sm-2 {\n margin-top: 0.5rem !important;\n }\n .mr-sm-2 {\n margin-right: 0.5rem !important;\n }\n .mb-sm-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-sm-2 {\n margin-left: 0.5rem !important;\n }\n .mx-sm-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-sm-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-sm-3 {\n margin: 1rem 1rem !important;\n }\n .mt-sm-3 {\n margin-top: 1rem !important;\n }\n .mr-sm-3 {\n margin-right: 1rem !important;\n }\n .mb-sm-3 {\n margin-bottom: 1rem !important;\n }\n .ml-sm-3 {\n margin-left: 1rem !important;\n }\n .mx-sm-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-sm-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-sm-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-sm-4 {\n margin-top: 1.5rem !important;\n }\n .mr-sm-4 {\n margin-right: 1.5rem !important;\n }\n .mb-sm-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-sm-4 {\n margin-left: 1.5rem !important;\n }\n .mx-sm-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-sm-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-sm-5 {\n margin: 3rem 3rem !important;\n }\n .mt-sm-5 {\n margin-top: 3rem !important;\n }\n .mr-sm-5 {\n margin-right: 3rem !important;\n }\n .mb-sm-5 {\n margin-bottom: 3rem !important;\n }\n .ml-sm-5 {\n margin-left: 3rem !important;\n }\n .mx-sm-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-sm-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-sm-0 {\n padding: 0 0 !important;\n }\n .pt-sm-0 {\n padding-top: 0 !important;\n }\n .pr-sm-0 {\n padding-right: 0 !important;\n }\n .pb-sm-0 {\n padding-bottom: 0 !important;\n }\n .pl-sm-0 {\n padding-left: 0 !important;\n }\n .px-sm-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-sm-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-sm-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-sm-1 {\n padding-top: 0.25rem !important;\n }\n .pr-sm-1 {\n padding-right: 0.25rem !important;\n }\n .pb-sm-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-sm-1 {\n padding-left: 0.25rem !important;\n }\n .px-sm-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-sm-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-sm-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-sm-2 {\n padding-top: 0.5rem !important;\n }\n .pr-sm-2 {\n padding-right: 0.5rem !important;\n }\n .pb-sm-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-sm-2 {\n padding-left: 0.5rem !important;\n }\n .px-sm-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-sm-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-sm-3 {\n padding: 1rem 1rem !important;\n }\n .pt-sm-3 {\n padding-top: 1rem !important;\n }\n .pr-sm-3 {\n padding-right: 1rem !important;\n }\n .pb-sm-3 {\n padding-bottom: 1rem !important;\n }\n .pl-sm-3 {\n padding-left: 1rem !important;\n }\n .px-sm-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-sm-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-sm-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-sm-4 {\n padding-top: 1.5rem !important;\n }\n .pr-sm-4 {\n padding-right: 1.5rem !important;\n }\n .pb-sm-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-sm-4 {\n padding-left: 1.5rem !important;\n }\n .px-sm-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-sm-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-sm-5 {\n padding: 3rem 3rem !important;\n }\n .pt-sm-5 {\n padding-top: 3rem !important;\n }\n .pr-sm-5 {\n padding-right: 3rem !important;\n }\n .pb-sm-5 {\n padding-bottom: 3rem !important;\n }\n .pl-sm-5 {\n padding-left: 3rem !important;\n }\n .px-sm-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-sm-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-sm-auto {\n margin: auto !important;\n }\n .mt-sm-auto {\n margin-top: auto !important;\n }\n .mr-sm-auto {\n margin-right: auto !important;\n }\n .mb-sm-auto {\n margin-bottom: auto !important;\n }\n .ml-sm-auto {\n margin-left: auto !important;\n }\n .mx-sm-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-sm-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 768px) {\n .m-md-0 {\n margin: 0 0 !important;\n }\n .mt-md-0 {\n margin-top: 0 !important;\n }\n .mr-md-0 {\n margin-right: 0 !important;\n }\n .mb-md-0 {\n margin-bottom: 0 !important;\n }\n .ml-md-0 {\n margin-left: 0 !important;\n }\n .mx-md-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-md-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-md-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-md-1 {\n margin-top: 0.25rem !important;\n }\n .mr-md-1 {\n margin-right: 0.25rem !important;\n }\n .mb-md-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-md-1 {\n margin-left: 0.25rem !important;\n }\n .mx-md-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-md-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-md-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-md-2 {\n margin-top: 0.5rem !important;\n }\n .mr-md-2 {\n margin-right: 0.5rem !important;\n }\n .mb-md-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-md-2 {\n margin-left: 0.5rem !important;\n }\n .mx-md-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-md-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-md-3 {\n margin: 1rem 1rem !important;\n }\n .mt-md-3 {\n margin-top: 1rem !important;\n }\n .mr-md-3 {\n margin-right: 1rem !important;\n }\n .mb-md-3 {\n margin-bottom: 1rem !important;\n }\n .ml-md-3 {\n margin-left: 1rem !important;\n }\n .mx-md-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-md-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-md-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-md-4 {\n margin-top: 1.5rem !important;\n }\n .mr-md-4 {\n margin-right: 1.5rem !important;\n }\n .mb-md-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-md-4 {\n margin-left: 1.5rem !important;\n }\n .mx-md-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-md-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-md-5 {\n margin: 3rem 3rem !important;\n }\n .mt-md-5 {\n margin-top: 3rem !important;\n }\n .mr-md-5 {\n margin-right: 3rem !important;\n }\n .mb-md-5 {\n margin-bottom: 3rem !important;\n }\n .ml-md-5 {\n margin-left: 3rem !important;\n }\n .mx-md-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-md-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-md-0 {\n padding: 0 0 !important;\n }\n .pt-md-0 {\n padding-top: 0 !important;\n }\n .pr-md-0 {\n padding-right: 0 !important;\n }\n .pb-md-0 {\n padding-bottom: 0 !important;\n }\n .pl-md-0 {\n padding-left: 0 !important;\n }\n .px-md-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-md-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-md-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-md-1 {\n padding-top: 0.25rem !important;\n }\n .pr-md-1 {\n padding-right: 0.25rem !important;\n }\n .pb-md-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-md-1 {\n padding-left: 0.25rem !important;\n }\n .px-md-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-md-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-md-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-md-2 {\n padding-top: 0.5rem !important;\n }\n .pr-md-2 {\n padding-right: 0.5rem !important;\n }\n .pb-md-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-md-2 {\n padding-left: 0.5rem !important;\n }\n .px-md-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-md-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-md-3 {\n padding: 1rem 1rem !important;\n }\n .pt-md-3 {\n padding-top: 1rem !important;\n }\n .pr-md-3 {\n padding-right: 1rem !important;\n }\n .pb-md-3 {\n padding-bottom: 1rem !important;\n }\n .pl-md-3 {\n padding-left: 1rem !important;\n }\n .px-md-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-md-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-md-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-md-4 {\n padding-top: 1.5rem !important;\n }\n .pr-md-4 {\n padding-right: 1.5rem !important;\n }\n .pb-md-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-md-4 {\n padding-left: 1.5rem !important;\n }\n .px-md-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-md-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-md-5 {\n padding: 3rem 3rem !important;\n }\n .pt-md-5 {\n padding-top: 3rem !important;\n }\n .pr-md-5 {\n padding-right: 3rem !important;\n }\n .pb-md-5 {\n padding-bottom: 3rem !important;\n }\n .pl-md-5 {\n padding-left: 3rem !important;\n }\n .px-md-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-md-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-md-auto {\n margin: auto !important;\n }\n .mt-md-auto {\n margin-top: auto !important;\n }\n .mr-md-auto {\n margin-right: auto !important;\n }\n .mb-md-auto {\n margin-bottom: auto !important;\n }\n .ml-md-auto {\n margin-left: auto !important;\n }\n .mx-md-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-md-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 992px) {\n .m-lg-0 {\n margin: 0 0 !important;\n }\n .mt-lg-0 {\n margin-top: 0 !important;\n }\n .mr-lg-0 {\n margin-right: 0 !important;\n }\n .mb-lg-0 {\n margin-bottom: 0 !important;\n }\n .ml-lg-0 {\n margin-left: 0 !important;\n }\n .mx-lg-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-lg-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-lg-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-lg-1 {\n margin-top: 0.25rem !important;\n }\n .mr-lg-1 {\n margin-right: 0.25rem !important;\n }\n .mb-lg-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-lg-1 {\n margin-left: 0.25rem !important;\n }\n .mx-lg-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-lg-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-lg-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-lg-2 {\n margin-top: 0.5rem !important;\n }\n .mr-lg-2 {\n margin-right: 0.5rem !important;\n }\n .mb-lg-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-lg-2 {\n margin-left: 0.5rem !important;\n }\n .mx-lg-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-lg-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-lg-3 {\n margin: 1rem 1rem !important;\n }\n .mt-lg-3 {\n margin-top: 1rem !important;\n }\n .mr-lg-3 {\n margin-right: 1rem !important;\n }\n .mb-lg-3 {\n margin-bottom: 1rem !important;\n }\n .ml-lg-3 {\n margin-left: 1rem !important;\n }\n .mx-lg-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-lg-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-lg-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-lg-4 {\n margin-top: 1.5rem !important;\n }\n .mr-lg-4 {\n margin-right: 1.5rem !important;\n }\n .mb-lg-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-lg-4 {\n margin-left: 1.5rem !important;\n }\n .mx-lg-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-lg-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-lg-5 {\n margin: 3rem 3rem !important;\n }\n .mt-lg-5 {\n margin-top: 3rem !important;\n }\n .mr-lg-5 {\n margin-right: 3rem !important;\n }\n .mb-lg-5 {\n margin-bottom: 3rem !important;\n }\n .ml-lg-5 {\n margin-left: 3rem !important;\n }\n .mx-lg-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-lg-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-lg-0 {\n padding: 0 0 !important;\n }\n .pt-lg-0 {\n padding-top: 0 !important;\n }\n .pr-lg-0 {\n padding-right: 0 !important;\n }\n .pb-lg-0 {\n padding-bottom: 0 !important;\n }\n .pl-lg-0 {\n padding-left: 0 !important;\n }\n .px-lg-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-lg-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-lg-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-lg-1 {\n padding-top: 0.25rem !important;\n }\n .pr-lg-1 {\n padding-right: 0.25rem !important;\n }\n .pb-lg-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-lg-1 {\n padding-left: 0.25rem !important;\n }\n .px-lg-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-lg-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-lg-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-lg-2 {\n padding-top: 0.5rem !important;\n }\n .pr-lg-2 {\n padding-right: 0.5rem !important;\n }\n .pb-lg-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-lg-2 {\n padding-left: 0.5rem !important;\n }\n .px-lg-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-lg-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-lg-3 {\n padding: 1rem 1rem !important;\n }\n .pt-lg-3 {\n padding-top: 1rem !important;\n }\n .pr-lg-3 {\n padding-right: 1rem !important;\n }\n .pb-lg-3 {\n padding-bottom: 1rem !important;\n }\n .pl-lg-3 {\n padding-left: 1rem !important;\n }\n .px-lg-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-lg-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-lg-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-lg-4 {\n padding-top: 1.5rem !important;\n }\n .pr-lg-4 {\n padding-right: 1.5rem !important;\n }\n .pb-lg-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-lg-4 {\n padding-left: 1.5rem !important;\n }\n .px-lg-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-lg-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-lg-5 {\n padding: 3rem 3rem !important;\n }\n .pt-lg-5 {\n padding-top: 3rem !important;\n }\n .pr-lg-5 {\n padding-right: 3rem !important;\n }\n .pb-lg-5 {\n padding-bottom: 3rem !important;\n }\n .pl-lg-5 {\n padding-left: 3rem !important;\n }\n .px-lg-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-lg-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-lg-auto {\n margin: auto !important;\n }\n .mt-lg-auto {\n margin-top: auto !important;\n }\n .mr-lg-auto {\n margin-right: auto !important;\n }\n .mb-lg-auto {\n margin-bottom: auto !important;\n }\n .ml-lg-auto {\n margin-left: auto !important;\n }\n .mx-lg-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-lg-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n@media (min-width: 1200px) {\n .m-xl-0 {\n margin: 0 0 !important;\n }\n .mt-xl-0 {\n margin-top: 0 !important;\n }\n .mr-xl-0 {\n margin-right: 0 !important;\n }\n .mb-xl-0 {\n margin-bottom: 0 !important;\n }\n .ml-xl-0 {\n margin-left: 0 !important;\n }\n .mx-xl-0 {\n margin-right: 0 !important;\n margin-left: 0 !important;\n }\n .my-xl-0 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n .m-xl-1 {\n margin: 0.25rem 0.25rem !important;\n }\n .mt-xl-1 {\n margin-top: 0.25rem !important;\n }\n .mr-xl-1 {\n margin-right: 0.25rem !important;\n }\n .mb-xl-1 {\n margin-bottom: 0.25rem !important;\n }\n .ml-xl-1 {\n margin-left: 0.25rem !important;\n }\n .mx-xl-1 {\n margin-right: 0.25rem !important;\n margin-left: 0.25rem !important;\n }\n .my-xl-1 {\n margin-top: 0.25rem !important;\n margin-bottom: 0.25rem !important;\n }\n .m-xl-2 {\n margin: 0.5rem 0.5rem !important;\n }\n .mt-xl-2 {\n margin-top: 0.5rem !important;\n }\n .mr-xl-2 {\n margin-right: 0.5rem !important;\n }\n .mb-xl-2 {\n margin-bottom: 0.5rem !important;\n }\n .ml-xl-2 {\n margin-left: 0.5rem !important;\n }\n .mx-xl-2 {\n margin-right: 0.5rem !important;\n margin-left: 0.5rem !important;\n }\n .my-xl-2 {\n margin-top: 0.5rem !important;\n margin-bottom: 0.5rem !important;\n }\n .m-xl-3 {\n margin: 1rem 1rem !important;\n }\n .mt-xl-3 {\n margin-top: 1rem !important;\n }\n .mr-xl-3 {\n margin-right: 1rem !important;\n }\n .mb-xl-3 {\n margin-bottom: 1rem !important;\n }\n .ml-xl-3 {\n margin-left: 1rem !important;\n }\n .mx-xl-3 {\n margin-right: 1rem !important;\n margin-left: 1rem !important;\n }\n .my-xl-3 {\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n .m-xl-4 {\n margin: 1.5rem 1.5rem !important;\n }\n .mt-xl-4 {\n margin-top: 1.5rem !important;\n }\n .mr-xl-4 {\n margin-right: 1.5rem !important;\n }\n .mb-xl-4 {\n margin-bottom: 1.5rem !important;\n }\n .ml-xl-4 {\n margin-left: 1.5rem !important;\n }\n .mx-xl-4 {\n margin-right: 1.5rem !important;\n margin-left: 1.5rem !important;\n }\n .my-xl-4 {\n margin-top: 1.5rem !important;\n margin-bottom: 1.5rem !important;\n }\n .m-xl-5 {\n margin: 3rem 3rem !important;\n }\n .mt-xl-5 {\n margin-top: 3rem !important;\n }\n .mr-xl-5 {\n margin-right: 3rem !important;\n }\n .mb-xl-5 {\n margin-bottom: 3rem !important;\n }\n .ml-xl-5 {\n margin-left: 3rem !important;\n }\n .mx-xl-5 {\n margin-right: 3rem !important;\n margin-left: 3rem !important;\n }\n .my-xl-5 {\n margin-top: 3rem !important;\n margin-bottom: 3rem !important;\n }\n .p-xl-0 {\n padding: 0 0 !important;\n }\n .pt-xl-0 {\n padding-top: 0 !important;\n }\n .pr-xl-0 {\n padding-right: 0 !important;\n }\n .pb-xl-0 {\n padding-bottom: 0 !important;\n }\n .pl-xl-0 {\n padding-left: 0 !important;\n }\n .px-xl-0 {\n padding-right: 0 !important;\n padding-left: 0 !important;\n }\n .py-xl-0 {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n .p-xl-1 {\n padding: 0.25rem 0.25rem !important;\n }\n .pt-xl-1 {\n padding-top: 0.25rem !important;\n }\n .pr-xl-1 {\n padding-right: 0.25rem !important;\n }\n .pb-xl-1 {\n padding-bottom: 0.25rem !important;\n }\n .pl-xl-1 {\n padding-left: 0.25rem !important;\n }\n .px-xl-1 {\n padding-right: 0.25rem !important;\n padding-left: 0.25rem !important;\n }\n .py-xl-1 {\n padding-top: 0.25rem !important;\n padding-bottom: 0.25rem !important;\n }\n .p-xl-2 {\n padding: 0.5rem 0.5rem !important;\n }\n .pt-xl-2 {\n padding-top: 0.5rem !important;\n }\n .pr-xl-2 {\n padding-right: 0.5rem !important;\n }\n .pb-xl-2 {\n padding-bottom: 0.5rem !important;\n }\n .pl-xl-2 {\n padding-left: 0.5rem !important;\n }\n .px-xl-2 {\n padding-right: 0.5rem !important;\n padding-left: 0.5rem !important;\n }\n .py-xl-2 {\n padding-top: 0.5rem !important;\n padding-bottom: 0.5rem !important;\n }\n .p-xl-3 {\n padding: 1rem 1rem !important;\n }\n .pt-xl-3 {\n padding-top: 1rem !important;\n }\n .pr-xl-3 {\n padding-right: 1rem !important;\n }\n .pb-xl-3 {\n padding-bottom: 1rem !important;\n }\n .pl-xl-3 {\n padding-left: 1rem !important;\n }\n .px-xl-3 {\n padding-right: 1rem !important;\n padding-left: 1rem !important;\n }\n .py-xl-3 {\n padding-top: 1rem !important;\n padding-bottom: 1rem !important;\n }\n .p-xl-4 {\n padding: 1.5rem 1.5rem !important;\n }\n .pt-xl-4 {\n padding-top: 1.5rem !important;\n }\n .pr-xl-4 {\n padding-right: 1.5rem !important;\n }\n .pb-xl-4 {\n padding-bottom: 1.5rem !important;\n }\n .pl-xl-4 {\n padding-left: 1.5rem !important;\n }\n .px-xl-4 {\n padding-right: 1.5rem !important;\n padding-left: 1.5rem !important;\n }\n .py-xl-4 {\n padding-top: 1.5rem !important;\n padding-bottom: 1.5rem !important;\n }\n .p-xl-5 {\n padding: 3rem 3rem !important;\n }\n .pt-xl-5 {\n padding-top: 3rem !important;\n }\n .pr-xl-5 {\n padding-right: 3rem !important;\n }\n .pb-xl-5 {\n padding-bottom: 3rem !important;\n }\n .pl-xl-5 {\n padding-left: 3rem !important;\n }\n .px-xl-5 {\n padding-right: 3rem !important;\n padding-left: 3rem !important;\n }\n .py-xl-5 {\n padding-top: 3rem !important;\n padding-bottom: 3rem !important;\n }\n .m-xl-auto {\n margin: auto !important;\n }\n .mt-xl-auto {\n margin-top: auto !important;\n }\n .mr-xl-auto {\n margin-right: auto !important;\n }\n .mb-xl-auto {\n margin-bottom: auto !important;\n }\n .ml-xl-auto {\n margin-left: auto !important;\n }\n .mx-xl-auto {\n margin-right: auto !important;\n margin-left: auto !important;\n }\n .my-xl-auto {\n margin-top: auto !important;\n margin-bottom: auto !important;\n }\n}\n\n.text-justify {\n text-align: justify !important;\n}\n\n.text-nowrap {\n white-space: nowrap !important;\n}\n\n.text-truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.text-left {\n text-align: left !important;\n}\n\n.text-right {\n text-align: right !important;\n}\n\n.text-center {\n text-align: center !important;\n}\n\n@media (min-width: 576px) {\n .text-sm-left {\n text-align: left !important;\n }\n .text-sm-right {\n text-align: right !important;\n }\n .text-sm-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 768px) {\n .text-md-left {\n text-align: left !important;\n }\n .text-md-right {\n text-align: right !important;\n }\n .text-md-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 992px) {\n .text-lg-left {\n text-align: left !important;\n }\n .text-lg-right {\n text-align: right !important;\n }\n .text-lg-center {\n text-align: center !important;\n }\n}\n\n@media (min-width: 1200px) {\n .text-xl-left {\n text-align: left !important;\n }\n .text-xl-right {\n text-align: right !important;\n }\n .text-xl-center {\n text-align: center !important;\n }\n}\n\n.text-lowercase {\n text-transform: lowercase !important;\n}\n\n.text-uppercase {\n text-transform: uppercase !important;\n}\n\n.text-capitalize {\n text-transform: capitalize !important;\n}\n\n.font-weight-normal {\n font-weight: normal;\n}\n\n.font-weight-bold {\n font-weight: bold;\n}\n\n.font-italic {\n font-style: italic;\n}\n\n.text-white {\n color: #fff !important;\n}\n\n.text-muted {\n color: #636c72 !important;\n}\n\na.text-muted:focus, a.text-muted:hover {\n color: #4b5257 !important;\n}\n\n.text-primary {\n color: #0275d8 !important;\n}\n\na.text-primary:focus, a.text-primary:hover {\n color: #025aa5 !important;\n}\n\n.text-success {\n color: #5cb85c !important;\n}\n\na.text-success:focus, a.text-success:hover {\n color: #449d44 !important;\n}\n\n.text-info {\n color: #5bc0de !important;\n}\n\na.text-info:focus, a.text-info:hover {\n color: #31b0d5 !important;\n}\n\n.text-warning {\n color: #f0ad4e !important;\n}\n\na.text-warning:focus, a.text-warning:hover {\n color: #ec971f !important;\n}\n\n.text-danger {\n color: #d9534f !important;\n}\n\na.text-danger:focus, a.text-danger:hover {\n color: #c9302c !important;\n}\n\n.text-gray-dark {\n color: #292b2c !important;\n}\n\na.text-gray-dark:focus, a.text-gray-dark:hover {\n color: #101112 !important;\n}\n\n.text-hide {\n font: 0/0 a;\n color: transparent;\n text-shadow: none;\n background-color: transparent;\n border: 0;\n}\n\n.invisible {\n visibility: hidden !important;\n}\n\n.hidden-xs-up {\n display: none !important;\n}\n\n@media (max-width: 575px) {\n .hidden-xs-down {\n display: none !important;\n }\n}\n\n@media (min-width: 576px) {\n .hidden-sm-up {\n display: none !important;\n }\n}\n\n@media (max-width: 767px) {\n .hidden-sm-down {\n display: none !important;\n }\n}\n\n@media (min-width: 768px) {\n .hidden-md-up {\n display: none !important;\n }\n}\n\n@media (max-width: 991px) {\n .hidden-md-down {\n display: none !important;\n }\n}\n\n@media (min-width: 992px) {\n .hidden-lg-up {\n display: none !important;\n }\n}\n\n@media (max-width: 1199px) {\n .hidden-lg-down {\n display: none !important;\n }\n}\n\n@media (min-width: 1200px) {\n .hidden-xl-up {\n display: none !important;\n }\n}\n\n.hidden-xl-down {\n display: none !important;\n}\n\n.visible-print-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-block {\n display: block !important;\n }\n}\n\n.visible-print-inline {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline {\n display: inline !important;\n }\n}\n\n.visible-print-inline-block {\n display: none !important;\n}\n\n@media print {\n .visible-print-inline-block {\n display: inline-block !important;\n }\n}\n\n@media print {\n .hidden-print {\n display: none !important;\n }\n}", ""]); -if (_inDOM2.default) { - var _getTransitionPropert = getTransitionProperties(); +// exports - prefix = _getTransitionPropert.prefix; - exports.transitionEnd = transitionEnd = _getTransitionPropert.transitionEnd; - exports.animationEnd = animationEnd = _getTransitionPropert.animationEnd; +/***/ }), +/* 213 */ +/***/ (function(module, exports) { - exports.transform = transform = prefix + '-' + transform; - exports.transitionProperty = transitionProperty = prefix + '-transition-property'; - exports.transitionDuration = transitionDuration = prefix + '-transition-duration'; - exports.transitionDelay = transitionDelay = prefix + '-transition-delay'; - exports.transitionTiming = transitionTiming = prefix + '-transition-timing-function'; - exports.animationName = animationName = prefix + '-animation-name'; - exports.animationDuration = animationDuration = prefix + '-animation-duration'; - exports.animationTiming = animationTiming = prefix + '-animation-delay'; - exports.animationDelay = animationDelay = prefix + '-animation-timing-function'; -} +/** + * When source maps are enabled, `style-loader` uses a link element with a data-uri to + * embed the css on the page. This breaks all relative urls because now they are relative to a + * bundle instead of the current page. + * + * One solution is to only use full urls, but that may be impossible. + * + * Instead, this function "fixes" the relative urls to be absolute according to the current page location. + * + * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command. + * + */ -exports.transform = transform; -exports.transitionProperty = transitionProperty; -exports.transitionTiming = transitionTiming; -exports.transitionDelay = transitionDelay; -exports.transitionDuration = transitionDuration; -exports.transitionEnd = transitionEnd; -exports.animationName = animationName; -exports.animationDuration = animationDuration; -exports.animationTiming = animationTiming; -exports.animationDelay = animationDelay; -exports.animationEnd = animationEnd; -exports.default = { - transform: transform, - end: transitionEnd, - property: transitionProperty, - timing: transitionTiming, - delay: transitionDelay, - duration: transitionDuration -}; +module.exports = function (css) { + // get current location + var location = typeof window !== "undefined" && window.location; + + if (!location) { + throw new Error("fixUrls requires window.location"); + } + // blank or null? + if (!css || typeof css !== "string") { + return css; + } -function getTransitionProperties() { - var style = document.createElement('div').style; + var baseUrl = location.protocol + "//" + location.host; + var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/"); - var vendorMap = { - O: function O(e) { - return 'o' + e.toLowerCase(); - }, - Moz: function Moz(e) { - return e.toLowerCase(); - }, - Webkit: function Webkit(e) { - return 'webkit' + e; - }, - ms: function ms(e) { - return 'MS' + e; - } - }; + // convert each url(...) + /* + This regular expression is just a way to recursively match brackets within + a string. - var vendors = Object.keys(vendorMap); + /url\s*\( = Match on the word "url" with any whitespace after it and then a parens + ( = Start a capturing group + (?: = Start a non-capturing group + [^)(] = Match anything that isn't a parentheses + | = OR + \( = Match a start parentheses + (?: = Start another non-capturing groups + [^)(]+ = Match anything that isn't a parentheses + | = OR + \( = Match a start parentheses + [^)(]* = Match anything that isn't a parentheses + \) = Match a end parentheses + ) = End Group + *\) = Match anything and then a close parens + ) = Close non-capturing group + * = Match anything + ) = Close capturing group + \) = Match a close parens - var transitionEnd = void 0, - animationEnd = void 0; - var prefix = ''; + /gi = Get all matches, not the first. Be case insensitive. + */ + var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) { + // strip quotes (if they exist) + var unquotedOrigUrl = origUrl + .trim() + .replace(/^"(.*)"$/, function(o, $1){ return $1; }) + .replace(/^'(.*)'$/, function(o, $1){ return $1; }); - for (var i = 0; i < vendors.length; i++) { - var vendor = vendors[i]; + // already a full url? no change + if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(unquotedOrigUrl)) { + return fullMatch; + } - if (vendor + 'TransitionProperty' in style) { - prefix = '-' + vendor.toLowerCase(); - transitionEnd = vendorMap[vendor]('TransitionEnd'); - animationEnd = vendorMap[vendor]('AnimationEnd'); - break; - } - } + // convert the url to a full url + var newUrl; - if (!transitionEnd && 'transitionProperty' in style) transitionEnd = 'transitionend'; + if (unquotedOrigUrl.indexOf("//") === 0) { + //TODO: should we add protocol? + newUrl = unquotedOrigUrl; + } else if (unquotedOrigUrl.indexOf("/") === 0) { + // path should be relative to the base url + newUrl = baseUrl + unquotedOrigUrl; // already starts with '/' + } else { + // path should be relative to current directory + newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './' + } - if (!animationEnd && 'animationName' in style) animationEnd = 'animationend'; + // send back the fixed url(...) + return "url(" + JSON.stringify(newUrl) + ")"; + }); - style = null; + // send back the fixed css + return fixedCss; +}; - return { animationEnd: animationEnd, transitionEnd: transitionEnd, prefix: prefix }; -} /***/ }), -/* 237 */ +/* 214 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. +// style-loader: Adds some css to the DOM by adding a <style> tag -// NOTE: These type checking functions intentionally don't use `instanceof` -// because it is fragile and can be easily faked with `Object.create()`. +// load the styles +var content = __webpack_require__(215); +if(typeof content === 'string') content = [[module.i, content, '']]; +// Prepare cssTransformation +var transform; -function isArray(arg) { - if (Array.isArray) { - return Array.isArray(arg); - } - return objectToString(arg) === '[object Array]'; -} -exports.isArray = isArray; - -function isBoolean(arg) { - return typeof arg === 'boolean'; +var options = {} +options.transform = transform +// add the styles to the DOM +var update = __webpack_require__(118)(content, options); +if(content.locals) module.exports = content.locals; +// Hot Module Replacement +if(false) { + // When the styles change, update the <style> tags + if(!content.locals) { + module.hot.accept("!!../css-loader/index.js!./react-table.css", function() { + var newContent = require("!!../css-loader/index.js!./react-table.css"); + if(typeof newContent === 'string') newContent = [[module.id, newContent, '']]; + update(newContent); + }); + } + // When the module is disposed, remove the <style> tags + module.hot.dispose(function() { update(); }); } -exports.isBoolean = isBoolean; -function isNull(arg) { - return arg === null; -} -exports.isNull = isNull; +/***/ }), +/* 215 */ +/***/ (function(module, exports, __webpack_require__) { -function isNullOrUndefined(arg) { - return arg == null; -} -exports.isNullOrUndefined = isNullOrUndefined; +exports = module.exports = __webpack_require__(117)(undefined); +// imports -function isNumber(arg) { - return typeof arg === 'number'; -} -exports.isNumber = isNumber; -function isString(arg) { - return typeof arg === 'string'; +// module +exports.push([module.i, ".ReactTable{position:relative;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;border:1px solid rgba(0,0,0,0.1);}.ReactTable *{box-sizing:border-box}.ReactTable .rt-table{-webkit-box-flex:1;-ms-flex:1;flex:1;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;width:100%;border-collapse:collapse;overflow:auto}.ReactTable .rt-thead{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;}.ReactTable .rt-thead.-headerGroups{background:rgba(0,0,0,0.03);border-bottom:1px solid rgba(0,0,0,0.05)}.ReactTable .rt-thead.-filters{border-bottom:1px solid rgba(0,0,0,0.05);}.ReactTable .rt-thead.-filters .rt-th{border-right:1px solid rgba(0,0,0,0.02)}.ReactTable .rt-thead.-header{box-shadow:0 2px 15px 0 rgba(0,0,0,0.15)}.ReactTable .rt-thead .rt-tr{text-align:center}.ReactTable .rt-thead .rt-th,.ReactTable .rt-thead .rt-td{padding:5px 5px;line-height:normal;position:relative;border-right:1px solid rgba(0,0,0,0.05);-webkit-transition:box-shadow .3s cubic-bezier(.175,.885,.32,1.275);transition:box-shadow .3s cubic-bezier(.175,.885,.32,1.275);box-shadow:inset 0 0 0 0 transparent;}.ReactTable .rt-thead .rt-th.-sort-asc,.ReactTable .rt-thead .rt-td.-sort-asc{box-shadow:inset 0 3px 0 0 rgba(0,0,0,0.6)}.ReactTable .rt-thead .rt-th.-sort-desc,.ReactTable .rt-thead .rt-td.-sort-desc{box-shadow:inset 0 -3px 0 0 rgba(0,0,0,0.6)}.ReactTable .rt-thead .rt-th.-cursor-pointer,.ReactTable .rt-thead .rt-td.-cursor-pointer{cursor:pointer}.ReactTable .rt-thead .rt-th:last-child,.ReactTable .rt-thead .rt-td:last-child{border-right:0}.ReactTable .rt-thead .rt-resizable-header{overflow:visible;}.ReactTable .rt-thead .rt-resizable-header:last-child{overflow:hidden}.ReactTable .rt-thead .rt-resizable-header-content{overflow:hidden;text-overflow:ellipsis}.ReactTable .rt-thead .rt-header-pivot{border-right-color:#f7f7f7}.ReactTable .rt-thead .rt-header-pivot:after,.ReactTable .rt-thead .rt-header-pivot:before{left:100%;top:50%;border:solid transparent;content:\" \";height:0;width:0;position:absolute;pointer-events:none}.ReactTable .rt-thead .rt-header-pivot:after{border-color:rgba(255,255,255,0);border-left-color:#fff;border-width:8px;margin-top:-8px}.ReactTable .rt-thead .rt-header-pivot:before{border-color:rgba(102,102,102,0);border-left-color:#f7f7f7;border-width:10px;margin-top:-10px}.ReactTable .rt-tbody{-webkit-box-flex:99999;-ms-flex:99999 1 auto;flex:99999 1 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;overflow:auto;}.ReactTable .rt-tbody .rt-tr-group{border-bottom:solid 1px rgba(0,0,0,0.05);}.ReactTable .rt-tbody .rt-tr-group:last-child{border-bottom:0}.ReactTable .rt-tbody .rt-td{border-right:1px solid rgba(0,0,0,0.02);}.ReactTable .rt-tbody .rt-td:last-child{border-right:0}.ReactTable .rt-tbody .rt-expandable{cursor:pointer}.ReactTable .rt-tr-group{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch}.ReactTable .rt-tr{-webkit-box-flex:1;-ms-flex:1 0 auto;flex:1 0 auto;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.ReactTable .rt-th,.ReactTable .rt-td{-webkit-box-flex:1;-ms-flex:1 0 0px;flex:1 0 0;white-space:nowrap;text-overflow:ellipsis;padding:7px 5px;overflow:hidden;-webkit-transition:.3s ease;transition:.3s ease;-webkit-transition-property:width,min-width,padding,opacity;transition-property:width,min-width,padding,opacity;}.ReactTable .rt-th.-hidden,.ReactTable .rt-td.-hidden{width:0 !important;min-width:0 !important;padding:0 !important;border:0 !important;opacity:0 !important}.ReactTable .rt-expander{display:inline-block;position:relative;margin:0;color:transparent;margin:0 10px;}.ReactTable .rt-expander:after{content:'';position:absolute;width:0;height:0;top:50%;left:50%;-webkit-transform:translate(-50%,-50%) rotate(-90deg);transform:translate(-50%,-50%) rotate(-90deg);border-left:5.04px solid transparent;border-right:5.04px solid transparent;border-top:7px solid rgba(0,0,0,0.8);-webkit-transition:all .3s cubic-bezier(.175,.885,.32,1.275);transition:all .3s cubic-bezier(.175,.885,.32,1.275);cursor:pointer}.ReactTable .rt-expander.-open:after{-webkit-transform:translate(-50%,-50%) rotate(0);transform:translate(-50%,-50%) rotate(0)}.ReactTable .rt-resizer{display:inline-block;position:absolute;width:36px;top:0;bottom:0;right:-18px;cursor:col-resize;z-index:10}.ReactTable .rt-tfoot{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;box-shadow:0 0 15px 0 rgba(0,0,0,0.15);}.ReactTable .rt-tfoot .rt-td{border-right:1px solid rgba(0,0,0,0.05);}.ReactTable .rt-tfoot .rt-td:last-child{border-right:0}.ReactTable.-striped .rt-tr.-odd{background:rgba(0,0,0,0.03)}.ReactTable.-highlight .rt-tbody .rt-tr:not(.-padRow):hover{background:rgba(0,0,0,0.05)}.ReactTable .-pagination{z-index:1;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;-ms-flex-wrap:wrap;flex-wrap:wrap;padding:3px;box-shadow:0 0 15px 0 rgba(0,0,0,0.1);border-top:2px solid rgba(0,0,0,0.1);}.ReactTable .-pagination .-btn{-webkit-appearance:none;-moz-appearance:none;appearance:none;display:block;width:100%;height:100%;border:0;border-radius:3px;padding:6px;font-size:1em;color:rgba(0,0,0,0.6);background:rgba(0,0,0,0.1);-webkit-transition:all .1s ease;transition:all .1s ease;cursor:pointer;outline:none;}.ReactTable .-pagination .-btn[disabled]{opacity:.5;cursor:default}.ReactTable .-pagination .-btn:not([disabled]):hover{background:rgba(0,0,0,0.3);color:#fff}.ReactTable .-pagination .-previous,.ReactTable .-pagination .-next{-webkit-box-flex:1;-ms-flex:1;flex:1;text-align:center}.ReactTable .-pagination .-center{-webkit-box-flex:1.5;-ms-flex:1.5;flex:1.5;text-align:center;margin-bottom:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-ms-flex-pack:distribute;justify-content:space-around}.ReactTable .-pagination .-pageInfo{display:inline-block;margin:3px 10px;white-space:nowrap}.ReactTable .-pagination .-pageJump{display:inline-block;}.ReactTable .-pagination .-pageJump input{width:70px;text-align:center}.ReactTable .-pagination .-pageSizeOptions{margin:3px 10px}.ReactTable .rt-noData{display:block;position:absolute;left:50%;top:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);background:rgba(255,255,255,0.8);-webkit-transition:all .3s ease;transition:all .3s ease;z-index:1;pointer-events:none;padding:20px;color:rgba(0,0,0,0.5)}.ReactTable .-loading{display:block;position:absolute;left:0;right:0;top:0;bottom:0;background:rgba(255,255,255,0.8);-webkit-transition:all .3s ease;transition:all .3s ease;z-index:-1;opacity:0;pointer-events:none;}.ReactTable .-loading > div{position:absolute;display:block;text-align:center;width:100%;top:50%;left:0;font-size:15px;color:rgba(0,0,0,0.6);-webkit-transform:translateY(-52%);transform:translateY(-52%);-webkit-transition:all .3s cubic-bezier(.25,.46,.45,.94);transition:all .3s cubic-bezier(.25,.46,.45,.94)}.ReactTable .-loading.-active{opacity:1;z-index:2;pointer-events:all;}.ReactTable .-loading.-active > div{-webkit-transform:translateY(50%);transform:translateY(50%)}.ReactTable input,.ReactTable select{border:1px solid rgba(0,0,0,0.1);background:#fff;padding:5px 7px;font-size:inherit;border-radius:3px;font-weight:normal;outline:none}.ReactTable .rt-resizing .rt-th,.ReactTable .rt-resizing .rt-td{-webkit-transition:none !important;transition:none !important;cursor:col-resize;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}", ""]); + +// exports + + +/***/ }), +/* 216 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var PooledClass = __webpack_require__(217); +var ReactElement = __webpack_require__(31); + +var emptyFunction = __webpack_require__(18); +var traverseAllChildren = __webpack_require__(218); + +var twoArgumentPooler = PooledClass.twoArgumentPooler; +var fourArgumentPooler = PooledClass.fourArgumentPooler; + +var userProvidedKeyEscapeRegex = /\/+/g; +function escapeUserProvidedKey(text) { + return ('' + text).replace(userProvidedKeyEscapeRegex, '$&/'); } -exports.isString = isString; -function isSymbol(arg) { - return typeof arg === 'symbol'; +/** + * PooledClass representing the bookkeeping associated with performing a child + * traversal. Allows avoiding binding callbacks. + * + * @constructor ForEachBookKeeping + * @param {!function} forEachFunction Function to perform traversal with. + * @param {?*} forEachContext Context to perform context with. + */ +function ForEachBookKeeping(forEachFunction, forEachContext) { + this.func = forEachFunction; + this.context = forEachContext; + this.count = 0; } -exports.isSymbol = isSymbol; +ForEachBookKeeping.prototype.destructor = function () { + this.func = null; + this.context = null; + this.count = 0; +}; +PooledClass.addPoolingTo(ForEachBookKeeping, twoArgumentPooler); -function isUndefined(arg) { - return arg === void 0; +function forEachSingleChild(bookKeeping, child, name) { + var func = bookKeeping.func, + context = bookKeeping.context; + + func.call(context, child, bookKeeping.count++); } -exports.isUndefined = isUndefined; -function isRegExp(re) { - return objectToString(re) === '[object RegExp]'; +/** + * Iterates through children that are typically specified as `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.foreach + * + * The provided forEachFunc(child, index) will be called for each + * leaf child. + * + * @param {?*} children Children tree container. + * @param {function(*, int)} forEachFunc + * @param {*} forEachContext Context for forEachContext. + */ +function forEachChildren(children, forEachFunc, forEachContext) { + if (children == null) { + return children; + } + var traverseContext = ForEachBookKeeping.getPooled(forEachFunc, forEachContext); + traverseAllChildren(children, forEachSingleChild, traverseContext); + ForEachBookKeeping.release(traverseContext); } -exports.isRegExp = isRegExp; -function isObject(arg) { - return typeof arg === 'object' && arg !== null; +/** + * PooledClass representing the bookkeeping associated with performing a child + * mapping. Allows avoiding binding callbacks. + * + * @constructor MapBookKeeping + * @param {!*} mapResult Object containing the ordered map of results. + * @param {!function} mapFunction Function to perform mapping with. + * @param {?*} mapContext Context to perform mapping with. + */ +function MapBookKeeping(mapResult, keyPrefix, mapFunction, mapContext) { + this.result = mapResult; + this.keyPrefix = keyPrefix; + this.func = mapFunction; + this.context = mapContext; + this.count = 0; } -exports.isObject = isObject; +MapBookKeeping.prototype.destructor = function () { + this.result = null; + this.keyPrefix = null; + this.func = null; + this.context = null; + this.count = 0; +}; +PooledClass.addPoolingTo(MapBookKeeping, fourArgumentPooler); -function isDate(d) { - return objectToString(d) === '[object Date]'; +function mapSingleChildIntoContext(bookKeeping, child, childKey) { + var result = bookKeeping.result, + keyPrefix = bookKeeping.keyPrefix, + func = bookKeeping.func, + context = bookKeeping.context; + + + var mappedChild = func.call(context, child, bookKeeping.count++); + if (Array.isArray(mappedChild)) { + mapIntoWithKeyPrefixInternal(mappedChild, result, childKey, emptyFunction.thatReturnsArgument); + } else if (mappedChild != null) { + if (ReactElement.isValidElement(mappedChild)) { + mappedChild = ReactElement.cloneAndReplaceKey(mappedChild, + // Keep both the (mapped) and old keys if they differ, just as + // traverseAllChildren used to do for objects as children + keyPrefix + (mappedChild.key && (!child || child.key !== mappedChild.key) ? escapeUserProvidedKey(mappedChild.key) + '/' : '') + childKey); + } + result.push(mappedChild); + } } -exports.isDate = isDate; -function isError(e) { - return (objectToString(e) === '[object Error]' || e instanceof Error); +function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) { + var escapedPrefix = ''; + if (prefix != null) { + escapedPrefix = escapeUserProvidedKey(prefix) + '/'; + } + var traverseContext = MapBookKeeping.getPooled(array, escapedPrefix, func, context); + traverseAllChildren(children, mapSingleChildIntoContext, traverseContext); + MapBookKeeping.release(traverseContext); } -exports.isError = isError; -function isFunction(arg) { - return typeof arg === 'function'; +/** + * Maps children that are typically specified as `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.map + * + * The provided mapFunction(child, key, index) will be called for each + * leaf child. + * + * @param {?*} children Children tree container. + * @param {function(*, int)} func The map function. + * @param {*} context Context for mapFunction. + * @return {object} Object containing the ordered map of results. + */ +function mapChildren(children, func, context) { + if (children == null) { + return children; + } + var result = []; + mapIntoWithKeyPrefixInternal(children, result, null, func, context); + return result; } -exports.isFunction = isFunction; -function isPrimitive(arg) { - return arg === null || - typeof arg === 'boolean' || - typeof arg === 'number' || - typeof arg === 'string' || - typeof arg === 'symbol' || // ES6 symbol - typeof arg === 'undefined'; +function forEachSingleChildDummy(traverseContext, child, name) { + return null; } -exports.isPrimitive = isPrimitive; -exports.isBuffer = Buffer.isBuffer; +/** + * Count the number of children that are typically specified as + * `props.children`. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.count + * + * @param {?*} children Children tree container. + * @return {number} The number of children. + */ +function countChildren(children, context) { + return traverseAllChildren(children, forEachSingleChildDummy, null); +} -function objectToString(o) { - return Object.prototype.toString.call(o); +/** + * Flatten a children object (typically specified as `props.children`) and + * return an array with appropriately re-keyed children. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.toarray + */ +function toArray(children) { + var result = []; + mapIntoWithKeyPrefixInternal(children, result, null, emptyFunction.thatReturnsArgument); + return result; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +var ReactChildren = { + forEach: forEachChildren, + map: mapChildren, + mapIntoWithKeyPrefixInternal: mapIntoWithKeyPrefixInternal, + count: countChildren, + toArray: toArray +}; + +module.exports = ReactChildren; /***/ }), -/* 238 */ +/* 217 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var utils = __webpack_require__(69); -var assert = __webpack_require__(47); - -function BlockHash() { - this.pending = null; - this.pendingTotal = 0; - this.blockSize = this.constructor.blockSize; - this.outSize = this.constructor.outSize; - this.hmacStrength = this.constructor.hmacStrength; - this.padLength = this.constructor.padLength / 8; - this.endian = 'big'; - - this._delta8 = this.blockSize / 8; - this._delta32 = this.blockSize / 32; -} -exports.BlockHash = BlockHash; - -BlockHash.prototype.update = function update(msg, enc) { - // Convert message to array, pad it, and join into 32bit blocks - msg = utils.toArray(msg, enc); - if (!this.pending) - this.pending = msg; - else - this.pending = this.pending.concat(msg); - this.pendingTotal += msg.length; - // Enough data, try updating - if (this.pending.length >= this._delta8) { - msg = this.pending; +var _prodInvariant = __webpack_require__(37); - // Process pending data in blocks - var r = msg.length % this._delta8; - this.pending = msg.slice(msg.length - r, msg.length); - if (this.pending.length === 0) - this.pending = null; +var invariant = __webpack_require__(2); - msg = utils.join32(msg, 0, msg.length - r, this.endian); - for (var i = 0; i < msg.length; i += this._delta32) - this._update(msg, i, i + this._delta32); +/** + * Static poolers. Several custom versions for each potential number of + * arguments. A completely generic pooler is easy to implement, but would + * require accessing the `arguments` object. In each of these, `this` refers to + * the Class itself, not an instance. If any others are needed, simply add them + * here, or in their own files. + */ +var oneArgumentPooler = function (copyFieldsFrom) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, copyFieldsFrom); + return instance; + } else { + return new Klass(copyFieldsFrom); } - - return this; }; -BlockHash.prototype.digest = function digest(enc) { - this.update(this._pad()); - assert(this.pending === null); - - return this._digest(enc); +var twoArgumentPooler = function (a1, a2) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2); + return instance; + } else { + return new Klass(a1, a2); + } }; -BlockHash.prototype._pad = function pad() { - var len = this.pendingTotal; - var bytes = this._delta8; - var k = bytes - ((len + this.padLength) % bytes); - var res = new Array(k + this.padLength); - res[0] = 0x80; - for (var i = 1; i < k; i++) - res[i] = 0; - - // Append length - len <<= 3; - if (this.endian === 'big') { - for (var t = 8; t < this.padLength; t++) - res[i++] = 0; - - res[i++] = 0; - res[i++] = 0; - res[i++] = 0; - res[i++] = 0; - res[i++] = (len >>> 24) & 0xff; - res[i++] = (len >>> 16) & 0xff; - res[i++] = (len >>> 8) & 0xff; - res[i++] = len & 0xff; +var threeArgumentPooler = function (a1, a2, a3) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3); + return instance; } else { - res[i++] = len & 0xff; - res[i++] = (len >>> 8) & 0xff; - res[i++] = (len >>> 16) & 0xff; - res[i++] = (len >>> 24) & 0xff; - res[i++] = 0; - res[i++] = 0; - res[i++] = 0; - res[i++] = 0; - - for (t = 8; t < this.padLength; t++) - res[i++] = 0; + return new Klass(a1, a2, a3); } - - return res; }; +var fourArgumentPooler = function (a1, a2, a3, a4) { + var Klass = this; + if (Klass.instancePool.length) { + var instance = Klass.instancePool.pop(); + Klass.call(instance, a1, a2, a3, a4); + return instance; + } else { + return new Klass(a1, a2, a3, a4); + } +}; -/***/ }), -/* 239 */ -/***/ (function(module, exports, __webpack_require__) { +var standardReleaser = function (instance) { + var Klass = this; + !(instance instanceof Klass) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Trying to release an instance into a pool of a different type.') : _prodInvariant('25') : void 0; + instance.destructor(); + if (Klass.instancePool.length < Klass.poolSize) { + Klass.instancePool.push(instance); + } +}; -/* WEBPACK VAR INJECTION */(function(Buffer) {module.exports = function xor (a, b) { - var length = Math.min(a.length, b.length) - var buffer = new Buffer(length) +var DEFAULT_POOL_SIZE = 10; +var DEFAULT_POOLER = oneArgumentPooler; - for (var i = 0; i < length; ++i) { - buffer[i] = a[i] ^ b[i] +/** + * Augments `CopyConstructor` to be a poolable class, augmenting only the class + * itself (statically) not adding any prototypical fields. Any CopyConstructor + * you give this may have a `poolSize` property, and will look for a + * prototypical `destructor` on instances. + * + * @param {Function} CopyConstructor Constructor that can be used to reset. + * @param {Function} pooler Customizable pooler. + */ +var addPoolingTo = function (CopyConstructor, pooler) { + // Casting as any so that flow ignores the actual implementation and trusts + // it to match the type we declared + var NewKlass = CopyConstructor; + NewKlass.instancePool = []; + NewKlass.getPooled = pooler || DEFAULT_POOLER; + if (!NewKlass.poolSize) { + NewKlass.poolSize = DEFAULT_POOL_SIZE; } + NewKlass.release = standardReleaser; + return NewKlass; +}; - return buffer -} +var PooledClass = { + addPoolingTo: addPoolingTo, + oneArgumentPooler: oneArgumentPooler, + twoArgumentPooler: twoArgumentPooler, + threeArgumentPooler: threeArgumentPooler, + fourArgumentPooler: fourArgumentPooler +}; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +module.exports = PooledClass; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 240 */ +/* 218 */ /***/ (function(module, exports, __webpack_require__) { -var asn1 = exports; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -asn1.bignum = __webpack_require__(23); -asn1.define = __webpack_require__(500).define; -asn1.base = __webpack_require__(241); -asn1.constants = __webpack_require__(338); -asn1.decoders = __webpack_require__(506); -asn1.encoders = __webpack_require__(508); +var _prodInvariant = __webpack_require__(37); -/***/ }), -/* 241 */ -/***/ (function(module, exports, __webpack_require__) { +var ReactCurrentOwner = __webpack_require__(22); +var REACT_ELEMENT_TYPE = __webpack_require__(121); -var base = exports; +var getIteratorFn = __webpack_require__(122); +var invariant = __webpack_require__(2); +var KeyEscapeUtils = __webpack_require__(219); +var warning = __webpack_require__(3); -base.Reporter = __webpack_require__(503).Reporter; -base.DecoderBuffer = __webpack_require__(337).DecoderBuffer; -base.EncoderBuffer = __webpack_require__(337).EncoderBuffer; -base.Node = __webpack_require__(504); +var SEPARATOR = '.'; +var SUBSEPARATOR = ':'; +/** + * This is inlined from ReactElement since this file is shared between + * isomorphic and renderers. We could extract this to a + * + */ -/***/ }), -/* 242 */ -/***/ (function(module, exports) { +/** + * TODO: Test that a single child and an array with one item have the same key + * pattern. + */ -// https://en.bitcoin.it/wiki/List_of_address_prefixes -// Dogecoin BIP32 is a proposed standard: https://bitcointalk.org/index.php?topic=409731 +var didWarnAboutMaps = false; -module.exports = { - bitcoin: { - messagePrefix: '\x18Bitcoin Signed Message:\n', - bip32: { - public: 0x0488b21e, - private: 0x0488ade4 - }, - pubKeyHash: 0x00, - scriptHash: 0x05, - wif: 0x80 - }, - testnet: { - messagePrefix: '\x18Bitcoin Signed Message:\n', - bip32: { - public: 0x043587cf, - private: 0x04358394 - }, - pubKeyHash: 0x6f, - scriptHash: 0xc4, - wif: 0xef - }, - litecoin: { - messagePrefix: '\x19Litecoin Signed Message:\n', - bip32: { - public: 0x019da462, - private: 0x019d9cfe - }, - pubKeyHash: 0x30, - scriptHash: 0x32, - wif: 0xb0 +/** + * Generate a key string that identifies a component within a set. + * + * @param {*} component A component that could contain a manual key. + * @param {number} index Index that is used if a manual key is not provided. + * @return {string} + */ +function getComponentKey(component, index) { + // Do some typechecking here since we call this blindly. We want to ensure + // that we don't block potential future ES APIs. + if (component && typeof component === 'object' && component.key != null) { + // Explicit key + return KeyEscapeUtils.escape(component.key); } + // Implicit key determined by the index in the set + return index.toString(36); } +/** + * @param {?*} children Children tree container. + * @param {!string} nameSoFar Name of the key path so far. + * @param {!function} callback Callback to invoke with each child found. + * @param {?*} traverseContext Used to pass information throughout the traversal + * process. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { + var type = typeof children; -/***/ }), -/* 243 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _reactstrap = __webpack_require__(66); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var footer = { - backgroundColor: '#f5f5f5' -}; - -var longP = { - wordWrap: 'break-word' -}; - -var ZFooter = function (_React$Component) { - _inherits(ZFooter, _React$Component); - - function ZFooter(props) { - _classCallCheck(this, ZFooter); - - return _possibleConstructorReturn(this, (ZFooter.__proto__ || Object.getPrototypeOf(ZFooter)).call(this, props)); + if (type === 'undefined' || type === 'boolean') { + // All of the above are perceived as null. + children = null; } - _createClass(ZFooter, [{ - key: 'render', - value: function render() { - return _react2.default.createElement( - 'div', - { style: footer }, - _react2.default.createElement('br', null), - _react2.default.createElement( - _reactstrap.Container, - null, - _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - { md: '8' }, - _react2.default.createElement( - 'p', - null, - 'MAKE SURE YOU ARE ON ', - _react2.default.createElement( - 'b', - null, - 'MYZENWALLET.IO' - ) - ), - _react2.default.createElement( - 'p', - null, - 'Keys are validated client-side and do not leave your browser or network. You are responsible for keeping your own keys safe!!!' - ), - _react2.default.createElement( - 'p', - null, - 'Suggestions? Email me: kendricktan0814 at gmail.com or find me on slack @ kendricktan.' - ), - _react2.default.createElement( - 'p', - { style: longP }, - 'Donations are always welcome!', - _react2.default.createElement('br', null), - _react2.default.createElement( - 'b', - null, - 'BTC' - ), - ': 14VmTd7Npm27SmJgrg1eUrSPgFEHcMXVGR', - _react2.default.createElement('br', null), - _react2.default.createElement( - 'b', - null, - 'ETH' - ), - ': 0x19Ed10db2960B9B21283FdFDe464e7bF3a87D05D', - _react2.default.createElement('br', null), - _react2.default.createElement( - 'b', - null, - 'ZEN' - ), - ': znSDvF9nA5VCdse5HbEKmsoNbjCbsEA3VAH' - ) - ), - _react2.default.createElement( - _reactstrap.Col, - { md: '4' }, - _react2.default.createElement( - 'a', - { href: 'https://zensystem.io/' }, - 'website' - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - 'a', - { href: 'https://blog.zensystem.io/' }, - 'blog' - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - 'a', - { href: 'https://forum.zensystem.io/' }, - 'forum' - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - 'a', - { href: 'https://github.com/ZencashOfficial' }, - 'github' - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - 'a', - { href: 'https://slackinvite.zensystem.io/' }, - 'slack' - ), - _react2.default.createElement('br', null) - ) - ) - ) - ); - } - }]); - - return ZFooter; -}(_react2.default.Component); - -exports.default = ZFooter; - -/***/ }), -/* 244 */ -/***/ (function(module, exports) { - -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. - -function EventEmitter() { - this._events = this._events || {}; - this._maxListeners = this._maxListeners || undefined; -} -module.exports = EventEmitter; - -// Backwards-compat with node 0.10.x -EventEmitter.EventEmitter = EventEmitter; - -EventEmitter.prototype._events = undefined; -EventEmitter.prototype._maxListeners = undefined; - -// By default EventEmitters will print a warning if more than 10 listeners are -// added to it. This is a useful default which helps finding memory leaks. -EventEmitter.defaultMaxListeners = 10; - -// Obviously not all Emitters should be limited to 10. This function allows -// that to be increased. Set to zero for unlimited. -EventEmitter.prototype.setMaxListeners = function(n) { - if (!isNumber(n) || n < 0 || isNaN(n)) - throw TypeError('n must be a positive number'); - this._maxListeners = n; - return this; -}; - -EventEmitter.prototype.emit = function(type) { - var er, handler, len, args, i, listeners; + if (children === null || type === 'string' || type === 'number' || + // The following is inlined from ReactElement. This means we can optimize + // some checks. React Fiber also inlines this logic for similar purposes. + type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE) { + callback(traverseContext, children, + // If it's the only child, treat the name as if it was wrapped in an array + // so that it's consistent if the number of children grows. + nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); + return 1; + } - if (!this._events) - this._events = {}; + var child; + var nextName; + var subtreeCount = 0; // Count of children found in the current subtree. + var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; - // If there is no 'error' event listener then throw. - if (type === 'error') { - if (!this._events.error || - (isObject(this._events.error) && !this._events.error.length)) { - er = arguments[1]; - if (er instanceof Error) { - throw er; // Unhandled 'error' event + if (Array.isArray(children)) { + for (var i = 0; i < children.length; i++) { + child = children[i]; + nextName = nextNamePrefix + getComponentKey(child, i); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } else { + var iteratorFn = getIteratorFn(children); + if (iteratorFn) { + var iterator = iteratorFn.call(children); + var step; + if (iteratorFn !== children.entries) { + var ii = 0; + while (!(step = iterator.next()).done) { + child = step.value; + nextName = nextNamePrefix + getComponentKey(child, ii++); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } } else { - // At least give some kind of context to the user - var err = new Error('Uncaught, unspecified "error" event. (' + er + ')'); - err.context = er; - throw err; + if (process.env.NODE_ENV !== 'production') { + var mapsAsChildrenAddendum = ''; + if (ReactCurrentOwner.current) { + var mapsAsChildrenOwnerName = ReactCurrentOwner.current.getName(); + if (mapsAsChildrenOwnerName) { + mapsAsChildrenAddendum = ' Check the render method of `' + mapsAsChildrenOwnerName + '`.'; + } + } + process.env.NODE_ENV !== 'production' ? warning(didWarnAboutMaps, 'Using Maps as children is not yet fully supported. It is an ' + 'experimental feature that might be removed. Convert it to a ' + 'sequence / iterable of keyed ReactElements instead.%s', mapsAsChildrenAddendum) : void 0; + didWarnAboutMaps = true; + } + // Iterator will provide entry [k,v] tuples rather than values. + while (!(step = iterator.next()).done) { + var entry = step.value; + if (entry) { + child = entry[1]; + nextName = nextNamePrefix + KeyEscapeUtils.escape(entry[0]) + SUBSEPARATOR + getComponentKey(child, 0); + subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); + } + } + } + } else if (type === 'object') { + var addendum = ''; + if (process.env.NODE_ENV !== 'production') { + addendum = ' If you meant to render a collection of children, use an array ' + 'instead or wrap the object using createFragment(object) from the ' + 'React add-ons.'; + if (children._isReactElement) { + addendum = " It looks like you're using an element created by a different " + 'version of React. Make sure to use only one copy of React.'; + } + if (ReactCurrentOwner.current) { + var name = ReactCurrentOwner.current.getName(); + if (name) { + addendum += ' Check the render method of `' + name + '`.'; + } + } } + var childrenString = String(children); + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : _prodInvariant('31', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum) : void 0; } } - handler = this._events[type]; - - if (isUndefined(handler)) - return false; + return subtreeCount; +} - if (isFunction(handler)) { - switch (arguments.length) { - // fast cases - case 1: - handler.call(this); - break; - case 2: - handler.call(this, arguments[1]); - break; - case 3: - handler.call(this, arguments[1], arguments[2]); - break; - // slower - default: - args = Array.prototype.slice.call(arguments, 1); - handler.apply(this, args); - } - } else if (isObject(handler)) { - args = Array.prototype.slice.call(arguments, 1); - listeners = handler.slice(); - len = listeners.length; - for (i = 0; i < len; i++) - listeners[i].apply(this, args); +/** + * Traverses children that are typically specified as `props.children`, but + * might also be specified through attributes: + * + * - `traverseAllChildren(this.props.children, ...)` + * - `traverseAllChildren(this.props.leftPanelChildren, ...)` + * + * The `traverseContext` is an optional argument that is passed through the + * entire traversal. It can be used to store accumulations or anything else that + * the callback might find relevant. + * + * @param {?*} children Children tree object. + * @param {!function} callback To invoke upon traversing each child. + * @param {?*} traverseContext Context for traversal. + * @return {!number} The number of children in this subtree. + */ +function traverseAllChildren(children, callback, traverseContext) { + if (children == null) { + return 0; } - return true; -}; - -EventEmitter.prototype.addListener = function(type, listener) { - var m; - - if (!isFunction(listener)) - throw TypeError('listener must be a function'); - - if (!this._events) - this._events = {}; - - // To avoid recursion in the case that type === "newListener"! Before - // adding it to the listeners, first emit "newListener". - if (this._events.newListener) - this.emit('newListener', type, - isFunction(listener.listener) ? - listener.listener : listener); + return traverseAllChildrenImpl(children, '', callback, traverseContext); +} - if (!this._events[type]) - // Optimize the case of one listener. Don't need the extra array object. - this._events[type] = listener; - else if (isObject(this._events[type])) - // If we've already got an array, just append. - this._events[type].push(listener); - else - // Adding the second element, need to change to array. - this._events[type] = [this._events[type], listener]; +module.exports = traverseAllChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - // Check for listener leak - if (isObject(this._events[type]) && !this._events[type].warned) { - if (!isUndefined(this._maxListeners)) { - m = this._maxListeners; - } else { - m = EventEmitter.defaultMaxListeners; - } +/***/ }), +/* 219 */ +/***/ (function(module, exports, __webpack_require__) { - if (m && m > 0 && this._events[type].length > m) { - this._events[type].warned = true; - console.error('(node) warning: possible EventEmitter memory ' + - 'leak detected. %d listeners added. ' + - 'Use emitter.setMaxListeners() to increase limit.', - this._events[type].length); - if (typeof console.trace === 'function') { - // not supported in IE 10 - console.trace(); - } - } - } +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - return this; -}; -EventEmitter.prototype.on = EventEmitter.prototype.addListener; -EventEmitter.prototype.once = function(type, listener) { - if (!isFunction(listener)) - throw TypeError('listener must be a function'); +/** + * Escape and wrap key so it is safe to use as a reactid + * + * @param {string} key to be escaped. + * @return {string} the escaped key. + */ - var fired = false; +function escape(key) { + var escapeRegex = /[=:]/g; + var escaperLookup = { + '=': '=0', + ':': '=2' + }; + var escapedString = ('' + key).replace(escapeRegex, function (match) { + return escaperLookup[match]; + }); - function g() { - this.removeListener(type, g); + return '$' + escapedString; +} - if (!fired) { - fired = true; - listener.apply(this, arguments); - } - } +/** + * Unescape and unwrap key for human-readable display + * + * @param {string} key to unescape. + * @return {string} the unescaped key. + */ +function unescape(key) { + var unescapeRegex = /(=0|=2)/g; + var unescaperLookup = { + '=0': '=', + '=2': ':' + }; + var keySubstring = key[0] === '.' && key[1] === '$' ? key.substring(2) : key.substring(1); - g.listener = listener; - this.on(type, g); + return ('' + keySubstring).replace(unescapeRegex, function (match) { + return unescaperLookup[match]; + }); +} - return this; +var KeyEscapeUtils = { + escape: escape, + unescape: unescape }; -// emits a 'removeListener' event iff the listener was removed -EventEmitter.prototype.removeListener = function(type, listener) { - var list, position, length, i; - - if (!isFunction(listener)) - throw TypeError('listener must be a function'); - - if (!this._events || !this._events[type]) - return this; +module.exports = KeyEscapeUtils; - list = this._events[type]; - length = list.length; - position = -1; +/***/ }), +/* 220 */ +/***/ (function(module, exports, __webpack_require__) { - if (list === listener || - (isFunction(list.listener) && list.listener === listener)) { - delete this._events[type]; - if (this._events.removeListener) - this.emit('removeListener', type, listener); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - } else if (isObject(list)) { - for (i = length; i-- > 0;) { - if (list[i] === listener || - (list[i].listener && list[i].listener === listener)) { - position = i; - break; - } - } - if (position < 0) - return this; - if (list.length === 1) { - list.length = 0; - delete this._events[type]; - } else { - list.splice(position, 1); - } +var ReactElement = __webpack_require__(31); - if (this._events.removeListener) - this.emit('removeListener', type, listener); - } +/** + * Create a factory that creates HTML tag elements. + * + * @private + */ +var createDOMFactory = ReactElement.createFactory; +if (process.env.NODE_ENV !== 'production') { + var ReactElementValidator = __webpack_require__(123); + createDOMFactory = ReactElementValidator.createFactory; +} - return this; -}; - -EventEmitter.prototype.removeAllListeners = function(type) { - var key, listeners; +/** + * Creates a mapping from supported HTML tags to `ReactDOMComponent` classes. + * + * @public + */ +var ReactDOMFactories = { + a: createDOMFactory('a'), + abbr: createDOMFactory('abbr'), + address: createDOMFactory('address'), + area: createDOMFactory('area'), + article: createDOMFactory('article'), + aside: createDOMFactory('aside'), + audio: createDOMFactory('audio'), + b: createDOMFactory('b'), + base: createDOMFactory('base'), + bdi: createDOMFactory('bdi'), + bdo: createDOMFactory('bdo'), + big: createDOMFactory('big'), + blockquote: createDOMFactory('blockquote'), + body: createDOMFactory('body'), + br: createDOMFactory('br'), + button: createDOMFactory('button'), + canvas: createDOMFactory('canvas'), + caption: createDOMFactory('caption'), + cite: createDOMFactory('cite'), + code: createDOMFactory('code'), + col: createDOMFactory('col'), + colgroup: createDOMFactory('colgroup'), + data: createDOMFactory('data'), + datalist: createDOMFactory('datalist'), + dd: createDOMFactory('dd'), + del: createDOMFactory('del'), + details: createDOMFactory('details'), + dfn: createDOMFactory('dfn'), + dialog: createDOMFactory('dialog'), + div: createDOMFactory('div'), + dl: createDOMFactory('dl'), + dt: createDOMFactory('dt'), + em: createDOMFactory('em'), + embed: createDOMFactory('embed'), + fieldset: createDOMFactory('fieldset'), + figcaption: createDOMFactory('figcaption'), + figure: createDOMFactory('figure'), + footer: createDOMFactory('footer'), + form: createDOMFactory('form'), + h1: createDOMFactory('h1'), + h2: createDOMFactory('h2'), + h3: createDOMFactory('h3'), + h4: createDOMFactory('h4'), + h5: createDOMFactory('h5'), + h6: createDOMFactory('h6'), + head: createDOMFactory('head'), + header: createDOMFactory('header'), + hgroup: createDOMFactory('hgroup'), + hr: createDOMFactory('hr'), + html: createDOMFactory('html'), + i: createDOMFactory('i'), + iframe: createDOMFactory('iframe'), + img: createDOMFactory('img'), + input: createDOMFactory('input'), + ins: createDOMFactory('ins'), + kbd: createDOMFactory('kbd'), + keygen: createDOMFactory('keygen'), + label: createDOMFactory('label'), + legend: createDOMFactory('legend'), + li: createDOMFactory('li'), + link: createDOMFactory('link'), + main: createDOMFactory('main'), + map: createDOMFactory('map'), + mark: createDOMFactory('mark'), + menu: createDOMFactory('menu'), + menuitem: createDOMFactory('menuitem'), + meta: createDOMFactory('meta'), + meter: createDOMFactory('meter'), + nav: createDOMFactory('nav'), + noscript: createDOMFactory('noscript'), + object: createDOMFactory('object'), + ol: createDOMFactory('ol'), + optgroup: createDOMFactory('optgroup'), + option: createDOMFactory('option'), + output: createDOMFactory('output'), + p: createDOMFactory('p'), + param: createDOMFactory('param'), + picture: createDOMFactory('picture'), + pre: createDOMFactory('pre'), + progress: createDOMFactory('progress'), + q: createDOMFactory('q'), + rp: createDOMFactory('rp'), + rt: createDOMFactory('rt'), + ruby: createDOMFactory('ruby'), + s: createDOMFactory('s'), + samp: createDOMFactory('samp'), + script: createDOMFactory('script'), + section: createDOMFactory('section'), + select: createDOMFactory('select'), + small: createDOMFactory('small'), + source: createDOMFactory('source'), + span: createDOMFactory('span'), + strong: createDOMFactory('strong'), + style: createDOMFactory('style'), + sub: createDOMFactory('sub'), + summary: createDOMFactory('summary'), + sup: createDOMFactory('sup'), + table: createDOMFactory('table'), + tbody: createDOMFactory('tbody'), + td: createDOMFactory('td'), + textarea: createDOMFactory('textarea'), + tfoot: createDOMFactory('tfoot'), + th: createDOMFactory('th'), + thead: createDOMFactory('thead'), + time: createDOMFactory('time'), + title: createDOMFactory('title'), + tr: createDOMFactory('tr'), + track: createDOMFactory('track'), + u: createDOMFactory('u'), + ul: createDOMFactory('ul'), + 'var': createDOMFactory('var'), + video: createDOMFactory('video'), + wbr: createDOMFactory('wbr'), - if (!this._events) - return this; + // SVG + circle: createDOMFactory('circle'), + clipPath: createDOMFactory('clipPath'), + defs: createDOMFactory('defs'), + ellipse: createDOMFactory('ellipse'), + g: createDOMFactory('g'), + image: createDOMFactory('image'), + line: createDOMFactory('line'), + linearGradient: createDOMFactory('linearGradient'), + mask: createDOMFactory('mask'), + path: createDOMFactory('path'), + pattern: createDOMFactory('pattern'), + polygon: createDOMFactory('polygon'), + polyline: createDOMFactory('polyline'), + radialGradient: createDOMFactory('radialGradient'), + rect: createDOMFactory('rect'), + stop: createDOMFactory('stop'), + svg: createDOMFactory('svg'), + text: createDOMFactory('text'), + tspan: createDOMFactory('tspan') +}; - // not listening for removeListener, no need to emit - if (!this._events.removeListener) { - if (arguments.length === 0) - this._events = {}; - else if (this._events[type]) - delete this._events[type]; - return this; - } +module.exports = ReactDOMFactories; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - // emit removeListener for all listeners on all events - if (arguments.length === 0) { - for (key in this._events) { - if (key === 'removeListener') continue; - this.removeAllListeners(key); - } - this.removeAllListeners('removeListener'); - this._events = {}; - return this; - } +/***/ }), +/* 221 */ +/***/ (function(module, exports, __webpack_require__) { - listeners = this._events[type]; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if (isFunction(listeners)) { - this.removeListener(type, listeners); - } else if (listeners) { - // LIFO order - while (listeners.length) - this.removeListener(type, listeners[listeners.length - 1]); - } - delete this._events[type]; - return this; -}; -EventEmitter.prototype.listeners = function(type) { - var ret; - if (!this._events || !this._events[type]) - ret = []; - else if (isFunction(this._events[type])) - ret = [this._events[type]]; - else - ret = this._events[type].slice(); - return ret; -}; +var _prodInvariant = __webpack_require__(37); -EventEmitter.prototype.listenerCount = function(type) { - if (this._events) { - var evlistener = this._events[type]; +var ReactPropTypeLocationNames = __webpack_require__(222); +var ReactPropTypesSecret = __webpack_require__(223); - if (isFunction(evlistener)) - return 1; - else if (evlistener) - return evlistener.length; - } - return 0; -}; +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); -EventEmitter.listenerCount = function(emitter, type) { - return emitter.listenerCount(type); -}; +var ReactComponentTreeHook; -function isFunction(arg) { - return typeof arg === 'function'; +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); } -function isNumber(arg) { - return typeof arg === 'number'; -} +var loggedTypeFailures = {}; -function isObject(arg) { - return typeof arg === 'object' && arg !== null; -} +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?object} element The React element that is being type-checked + * @param {?number} debugID The React component instance that is being type-checked + * @private + */ +function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; -function isUndefined(arg) { - return arg === void 0; + var componentStackInfo = ''; + + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (debugID !== null) { + componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); + } else if (element !== null) { + componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); + } + } + + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; + } + } + } } +module.exports = checkReactTypeSpec; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 245 */ +/* 222 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; - -/* - * A JavaScript implementation of the RSA Data Security, Inc. MD5 Message - * Digest Algorithm, as defined in RFC 1321. - * Version 2.1 Copyright (C) Paul Johnston 1999 - 2002. - * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet - * Distributed under the BSD License - * See http://pajhome.org.uk/crypt/md5 for more info. +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * */ -var makeHash = __webpack_require__(425) - -/* - * Calculate the MD5 of an array of little-endian words, and a bit length - */ -function core_md5 (x, len) { - /* append padding */ - x[len >> 5] |= 0x80 << ((len) % 32) - x[(((len + 64) >>> 9) << 4) + 14] = len - var a = 1732584193 - var b = -271733879 - var c = -1732584194 - var d = 271733878 - for (var i = 0; i < x.length; i += 16) { - var olda = a - var oldb = b - var oldc = c - var oldd = d +var ReactPropTypeLocationNames = {}; - a = md5_ff(a, b, c, d, x[i + 0], 7, -680876936) - d = md5_ff(d, a, b, c, x[i + 1], 12, -389564586) - c = md5_ff(c, d, a, b, x[i + 2], 17, 606105819) - b = md5_ff(b, c, d, a, x[i + 3], 22, -1044525330) - a = md5_ff(a, b, c, d, x[i + 4], 7, -176418897) - d = md5_ff(d, a, b, c, x[i + 5], 12, 1200080426) - c = md5_ff(c, d, a, b, x[i + 6], 17, -1473231341) - b = md5_ff(b, c, d, a, x[i + 7], 22, -45705983) - a = md5_ff(a, b, c, d, x[i + 8], 7, 1770035416) - d = md5_ff(d, a, b, c, x[i + 9], 12, -1958414417) - c = md5_ff(c, d, a, b, x[i + 10], 17, -42063) - b = md5_ff(b, c, d, a, x[i + 11], 22, -1990404162) - a = md5_ff(a, b, c, d, x[i + 12], 7, 1804603682) - d = md5_ff(d, a, b, c, x[i + 13], 12, -40341101) - c = md5_ff(c, d, a, b, x[i + 14], 17, -1502002290) - b = md5_ff(b, c, d, a, x[i + 15], 22, 1236535329) +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} - a = md5_gg(a, b, c, d, x[i + 1], 5, -165796510) - d = md5_gg(d, a, b, c, x[i + 6], 9, -1069501632) - c = md5_gg(c, d, a, b, x[i + 11], 14, 643717713) - b = md5_gg(b, c, d, a, x[i + 0], 20, -373897302) - a = md5_gg(a, b, c, d, x[i + 5], 5, -701558691) - d = md5_gg(d, a, b, c, x[i + 10], 9, 38016083) - c = md5_gg(c, d, a, b, x[i + 15], 14, -660478335) - b = md5_gg(b, c, d, a, x[i + 4], 20, -405537848) - a = md5_gg(a, b, c, d, x[i + 9], 5, 568446438) - d = md5_gg(d, a, b, c, x[i + 14], 9, -1019803690) - c = md5_gg(c, d, a, b, x[i + 3], 14, -187363961) - b = md5_gg(b, c, d, a, x[i + 8], 20, 1163531501) - a = md5_gg(a, b, c, d, x[i + 13], 5, -1444681467) - d = md5_gg(d, a, b, c, x[i + 2], 9, -51403784) - c = md5_gg(c, d, a, b, x[i + 7], 14, 1735328473) - b = md5_gg(b, c, d, a, x[i + 12], 20, -1926607734) +module.exports = ReactPropTypeLocationNames; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - a = md5_hh(a, b, c, d, x[i + 5], 4, -378558) - d = md5_hh(d, a, b, c, x[i + 8], 11, -2022574463) - c = md5_hh(c, d, a, b, x[i + 11], 16, 1839030562) - b = md5_hh(b, c, d, a, x[i + 14], 23, -35309556) - a = md5_hh(a, b, c, d, x[i + 1], 4, -1530992060) - d = md5_hh(d, a, b, c, x[i + 4], 11, 1272893353) - c = md5_hh(c, d, a, b, x[i + 7], 16, -155497632) - b = md5_hh(b, c, d, a, x[i + 10], 23, -1094730640) - a = md5_hh(a, b, c, d, x[i + 13], 4, 681279174) - d = md5_hh(d, a, b, c, x[i + 0], 11, -358537222) - c = md5_hh(c, d, a, b, x[i + 3], 16, -722521979) - b = md5_hh(b, c, d, a, x[i + 6], 23, 76029189) - a = md5_hh(a, b, c, d, x[i + 9], 4, -640364487) - d = md5_hh(d, a, b, c, x[i + 12], 11, -421815835) - c = md5_hh(c, d, a, b, x[i + 15], 16, 530742520) - b = md5_hh(b, c, d, a, x[i + 2], 23, -995338651) +/***/ }), +/* 223 */ +/***/ (function(module, exports, __webpack_require__) { - a = md5_ii(a, b, c, d, x[i + 0], 6, -198630844) - d = md5_ii(d, a, b, c, x[i + 7], 10, 1126891415) - c = md5_ii(c, d, a, b, x[i + 14], 15, -1416354905) - b = md5_ii(b, c, d, a, x[i + 5], 21, -57434055) - a = md5_ii(a, b, c, d, x[i + 12], 6, 1700485571) - d = md5_ii(d, a, b, c, x[i + 3], 10, -1894986606) - c = md5_ii(c, d, a, b, x[i + 10], 15, -1051523) - b = md5_ii(b, c, d, a, x[i + 1], 21, -2054922799) - a = md5_ii(a, b, c, d, x[i + 8], 6, 1873313359) - d = md5_ii(d, a, b, c, x[i + 15], 10, -30611744) - c = md5_ii(c, d, a, b, x[i + 6], 15, -1560198380) - b = md5_ii(b, c, d, a, x[i + 13], 21, 1309151649) - a = md5_ii(a, b, c, d, x[i + 4], 6, -145523070) - d = md5_ii(d, a, b, c, x[i + 11], 10, -1120210379) - c = md5_ii(c, d, a, b, x[i + 2], 15, 718787259) - b = md5_ii(b, c, d, a, x[i + 9], 21, -343485551) +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - a = safe_add(a, olda) - b = safe_add(b, oldb) - c = safe_add(c, oldc) - d = safe_add(d, oldd) - } - return [a, b, c, d] -} -/* - * These functions implement the four basic operations the algorithm uses. - */ -function md5_cmn (q, a, b, x, s, t) { - return safe_add(bit_rol(safe_add(safe_add(a, q), safe_add(x, t)), s), b) -} +var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; -function md5_ff (a, b, c, d, x, s, t) { - return md5_cmn((b & c) | ((~b) & d), a, b, x, s, t) -} +module.exports = ReactPropTypesSecret; -function md5_gg (a, b, c, d, x, s, t) { - return md5_cmn((b & d) | (c & (~d)), a, b, x, s, t) -} +/***/ }), +/* 224 */ +/***/ (function(module, exports, __webpack_require__) { -function md5_hh (a, b, c, d, x, s, t) { - return md5_cmn(b ^ c ^ d, a, b, x, s, t) -} +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -function md5_ii (a, b, c, d, x, s, t) { - return md5_cmn(c ^ (b | (~d)), a, b, x, s, t) -} -/* - * Add integers, wrapping at 2^32. This uses 16-bit operations internally - * to work around bugs in some JS interpreters. - */ -function safe_add (x, y) { - var lsw = (x & 0xFFFF) + (y & 0xFFFF) - var msw = (x >> 16) + (y >> 16) + (lsw >> 16) - return (msw << 16) | (lsw & 0xFFFF) -} -/* - * Bitwise rotate a 32-bit number to the left. - */ -function bit_rol (num, cnt) { - return (num << cnt) | (num >>> (32 - cnt)) -} +var _require = __webpack_require__(31), + isValidElement = _require.isValidElement; -module.exports = function md5 (buf) { - return makeHash(buf, core_md5) -} +var factory = __webpack_require__(124); +module.exports = factory(isValidElement); /***/ }), -/* 246 */ +/* 225 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ -if (!process.version || - process.version.indexOf('v0.') === 0 || - process.version.indexOf('v1.') === 0 && process.version.indexOf('v1.8.') !== 0) { - module.exports = nextTick; -} else { - module.exports = process.nextTick; + + +if (process.env.NODE_ENV !== 'production') { + var invariant = __webpack_require__(2); + var warning = __webpack_require__(3); + var ReactPropTypesSecret = __webpack_require__(75); + var loggedTypeFailures = {}; } -function nextTick(fn, arg1, arg2, arg3) { - if (typeof fn !== 'function') { - throw new TypeError('"callback" argument must be a function'); - } - var len = arguments.length; - var args, i; - switch (len) { - case 0: - case 1: - return process.nextTick(fn); - case 2: - return process.nextTick(function afterTickOne() { - fn.call(null, arg1); - }); - case 3: - return process.nextTick(function afterTickTwo() { - fn.call(null, arg1, arg2); - }); - case 4: - return process.nextTick(function afterTickThree() { - fn.call(null, arg1, arg2, arg3); - }); - default: - args = new Array(len - 1); - i = 0; - while (i < args.length) { - args[i++] = arguments[i]; +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?Function} getStack Returns the component stack. + * @private + */ +function checkPropTypes(typeSpecs, values, location, componentName, getStack) { + if (process.env.NODE_ENV !== 'production') { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + invariant(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', componentName || 'React class', location, typeSpecName); + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error); + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; + + var stack = getStack ? getStack() : ''; + + warning(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : ''); + } + } } - return process.nextTick(function afterTick() { - fn.apply(null, args); - }); } } +module.exports = checkPropTypes; + /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 247 */ +/* 226 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var curve = exports; - -curve.base = __webpack_require__(448); -curve.short = __webpack_require__(449); -curve.mont = __webpack_require__(450); -curve.edwards = __webpack_require__(451); - - -/***/ }), -/* 248 */ -/***/ (function(module, exports) { - -/* -config.js - Configuration for ZENCash Coin -*/ -module.exports = { - mainnet: { - messagePrefix: 'ZENCash main net', - bip32: { - public: '0488b21e', - private: '0488ade4' - }, - pubKeyHash: '2089', - scriptHash: '2096', - zcPaymentAddressHash: '169a', // Private z-address - zcSpendingKeyHash: 'ab36', // Spending key - wif: '80' - }, - testnet: { - wif: 'ef', - pubKeyHash: '2098' - } -}; +module.exports = '15.6.1'; /***/ }), -/* 249 */ +/* 227 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var inherits = __webpack_require__(11) -var Legacy = __webpack_require__(480) -var Base = __webpack_require__(109) -var Buffer = __webpack_require__(18).Buffer -var md5 = __webpack_require__(245) -var RIPEMD160 = __webpack_require__(260) - -var sha = __webpack_require__(265) - -var ZEROS = Buffer.alloc(128) -function Hmac (alg, key) { - Base.call(this, 'digest') - if (typeof key === 'string') { - key = Buffer.from(key) - } - var blocksize = (alg === 'sha512' || alg === 'sha384') ? 128 : 64 +var _require = __webpack_require__(119), + Component = _require.Component; - this._alg = alg - this._key = key - if (key.length > blocksize) { - var hash = alg === 'rmd160' ? new RIPEMD160() : sha(alg) - key = hash.update(key).digest() - } else if (key.length < blocksize) { - key = Buffer.concat([key, ZEROS], blocksize) - } +var _require2 = __webpack_require__(31), + isValidElement = _require2.isValidElement; - var ipad = this._ipad = Buffer.allocUnsafe(blocksize) - var opad = this._opad = Buffer.allocUnsafe(blocksize) +var ReactNoopUpdateQueue = __webpack_require__(120); +var factory = __webpack_require__(228); - for (var i = 0; i < blocksize; i++) { - ipad[i] = key[i] ^ 0x36 - opad[i] = key[i] ^ 0x5C - } - this._hash = alg === 'rmd160' ? new RIPEMD160() : sha(alg) - this._hash.update(ipad) -} +module.exports = factory(Component, isValidElement, ReactNoopUpdateQueue); -inherits(Hmac, Base) +/***/ }), +/* 228 */ +/***/ (function(module, exports, __webpack_require__) { -Hmac.prototype._update = function (data) { - this._hash.update(data) -} +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -Hmac.prototype._final = function () { - var h = this._hash.digest() - var hash = this._alg === 'rmd160' ? new RIPEMD160() : sha(this._alg) - return hash.update(this._opad).update(h).digest() -} -module.exports = function createHmac (alg, key) { - alg = alg.toLowerCase() - if (alg === 'rmd160' || alg === 'ripemd160') { - return new Hmac('rmd160', key) - } - if (alg === 'md5') { - return new Legacy(md5, key) - } - return new Hmac(alg, key) -} +var _assign = __webpack_require__(8); -/***/ }), -/* 250 */ -/***/ (function(module, exports, __webpack_require__) { +var emptyObject = __webpack_require__(56); +var _invariant = __webpack_require__(2); -/* WEBPACK VAR INJECTION */(function(Buffer) {var md5 = __webpack_require__(245) -module.exports = EVP_BytesToKey -function EVP_BytesToKey (password, salt, keyLen, ivLen) { - if (!Buffer.isBuffer(password)) { - password = new Buffer(password, 'binary') - } - if (salt && !Buffer.isBuffer(salt)) { - salt = new Buffer(salt, 'binary') - } - keyLen = keyLen / 8 - ivLen = ivLen || 0 - var ki = 0 - var ii = 0 - var key = new Buffer(keyLen) - var iv = new Buffer(ivLen) - var addmd = 0 - var md_buf - var i - var bufs = [] - while (true) { - if (addmd++ > 0) { - bufs.push(md_buf) - } - bufs.push(password) - if (salt) { - bufs.push(salt) - } - md_buf = md5(Buffer.concat(bufs)) - bufs = [] - i = 0 - if (keyLen > 0) { - while (true) { - if (keyLen === 0) { - break - } - if (i === md_buf.length) { - break - } - key[ki++] = md_buf[i] - keyLen-- - i++ - } - } - if (ivLen > 0 && i !== md_buf.length) { - while (true) { - if (ivLen === 0) { - break - } - if (i === md_buf.length) { - break - } - iv[ii++] = md_buf[i] - ivLen-- - i++ - } - } - if (keyLen === 0 && ivLen === 0) { - break - } - } - for (i = 0; i < md_buf.length; i++) { - md_buf[i] = 0 - } - return { - key: key, - iv: iv - } +if (process.env.NODE_ENV !== 'production') { + var warning = __webpack_require__(3); } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +var MIXINS_KEY = 'mixins'; -/***/ }), -/* 251 */ -/***/ (function(module, exports, __webpack_require__) { +// Helper function to allow the creation of anonymous functions which do not +// have .name set to the name of the variable being assigned to. +function identity(fn) { + return fn; +} -/* WEBPACK VAR INJECTION */(function(Buffer) {// based on the aes implimentation in triple sec -// https://github.com/keybase/triplesec +var ReactPropTypeLocationNames; +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} else { + ReactPropTypeLocationNames = {}; +} -// which is in turn based on the one from crypto-js -// https://code.google.com/p/crypto-js/ +function factory(ReactComponent, isValidElement, ReactNoopUpdateQueue) { + /** + * Policies that describe methods in `ReactClassInterface`. + */ -var uint_max = Math.pow(2, 32) -function fixup_uint32 (x) { - var ret, x_pos - ret = x > uint_max || x < 0 ? (x_pos = Math.abs(x) % uint_max, x < 0 ? uint_max - x_pos : x_pos) : x - return ret -} -function scrub_vec (v) { - for (var i = 0; i < v.length; v++) { - v[i] = 0 - } - return false -} + var injectedMixins = []; -function Global () { - this.SBOX = [] - this.INV_SBOX = [] - this.SUB_MIX = [[], [], [], []] - this.INV_SUB_MIX = [[], [], [], []] - this.init() - this.RCON = [0x00, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x1b, 0x36] -} + /** + * Composite components are higher-level components that compose other composite + * or host components. + * + * To create a new type of `ReactClass`, pass a specification of + * your new class to `React.createClass`. The only requirement of your class + * specification is that you implement a `render` method. + * + * var MyComponent = React.createClass({ + * render: function() { + * return <div>Hello World</div>; + * } + * }); + * + * The class specification supports a specific protocol of methods that have + * special meaning (e.g. `render`). See `ReactClassInterface` for + * more the comprehensive protocol. Any other properties and methods in the + * class specification will be available on the prototype. + * + * @interface ReactClassInterface + * @internal + */ + var ReactClassInterface = { + /** + * An array of Mixin objects to include when defining your component. + * + * @type {array} + * @optional + */ + mixins: 'DEFINE_MANY', -Global.prototype.init = function () { - var d, i, sx, t, x, x2, x4, x8, xi, _i - d = (function () { - var _i, _results - _results = [] - for (i = _i = 0; _i < 256; i = ++_i) { - if (i < 128) { - _results.push(i << 1) - } else { - _results.push((i << 1) ^ 0x11b) - } - } - return _results - })() - x = 0 - xi = 0 - for (i = _i = 0; _i < 256; i = ++_i) { - sx = xi ^ (xi << 1) ^ (xi << 2) ^ (xi << 3) ^ (xi << 4) - sx = (sx >>> 8) ^ (sx & 0xff) ^ 0x63 - this.SBOX[x] = sx - this.INV_SBOX[sx] = x - x2 = d[x] - x4 = d[x2] - x8 = d[x4] - t = (d[sx] * 0x101) ^ (sx * 0x1010100) - this.SUB_MIX[0][x] = (t << 24) | (t >>> 8) - this.SUB_MIX[1][x] = (t << 16) | (t >>> 16) - this.SUB_MIX[2][x] = (t << 8) | (t >>> 24) - this.SUB_MIX[3][x] = t - t = (x8 * 0x1010101) ^ (x4 * 0x10001) ^ (x2 * 0x101) ^ (x * 0x1010100) - this.INV_SUB_MIX[0][sx] = (t << 24) | (t >>> 8) - this.INV_SUB_MIX[1][sx] = (t << 16) | (t >>> 16) - this.INV_SUB_MIX[2][sx] = (t << 8) | (t >>> 24) - this.INV_SUB_MIX[3][sx] = t - if (x === 0) { - x = xi = 1 - } else { - x = x2 ^ d[d[d[x8 ^ x2]]] - xi ^= d[d[xi]] - } - } - return true -} + /** + * An object containing properties and methods that should be defined on + * the component's constructor instead of its prototype (static methods). + * + * @type {object} + * @optional + */ + statics: 'DEFINE_MANY', -var G = new Global() + /** + * Definition of prop types for this component. + * + * @type {object} + * @optional + */ + propTypes: 'DEFINE_MANY', -AES.blockSize = 4 * 4 + /** + * Definition of context types for this component. + * + * @type {object} + * @optional + */ + contextTypes: 'DEFINE_MANY', -AES.prototype.blockSize = AES.blockSize + /** + * Definition of context types this component sets for its children. + * + * @type {object} + * @optional + */ + childContextTypes: 'DEFINE_MANY', -AES.keySize = 256 / 8 + // ==== Definition methods ==== -AES.prototype.keySize = AES.keySize + /** + * Invoked when the component is mounted. Values in the mapping will be set on + * `this.props` if that prop is not specified (i.e. using an `in` check). + * + * This method is invoked before `getInitialState` and therefore cannot rely + * on `this.state` or use `this.setState`. + * + * @return {object} + * @optional + */ + getDefaultProps: 'DEFINE_MANY_MERGED', -function bufferToArray (buf) { - var len = buf.length / 4 - var out = new Array(len) - var i = -1 - while (++i < len) { - out[i] = buf.readUInt32BE(i * 4) - } - return out -} -function AES (key) { - this._key = bufferToArray(key) - this._doReset() -} + /** + * Invoked once before the component is mounted. The return value will be used + * as the initial value of `this.state`. + * + * getInitialState: function() { + * return { + * isOn: false, + * fooBaz: new BazFoo() + * } + * } + * + * @return {object} + * @optional + */ + getInitialState: 'DEFINE_MANY_MERGED', -AES.prototype._doReset = function () { - var invKsRow, keySize, keyWords, ksRow, ksRows, t - keyWords = this._key - keySize = keyWords.length - this._nRounds = keySize + 6 - ksRows = (this._nRounds + 1) * 4 - this._keySchedule = [] - for (ksRow = 0; ksRow < ksRows; ksRow++) { - this._keySchedule[ksRow] = ksRow < keySize ? keyWords[ksRow] : (t = this._keySchedule[ksRow - 1], (ksRow % keySize) === 0 ? (t = (t << 8) | (t >>> 24), t = (G.SBOX[t >>> 24] << 24) | (G.SBOX[(t >>> 16) & 0xff] << 16) | (G.SBOX[(t >>> 8) & 0xff] << 8) | G.SBOX[t & 0xff], t ^= G.RCON[(ksRow / keySize) | 0] << 24) : keySize > 6 && ksRow % keySize === 4 ? t = (G.SBOX[t >>> 24] << 24) | (G.SBOX[(t >>> 16) & 0xff] << 16) | (G.SBOX[(t >>> 8) & 0xff] << 8) | G.SBOX[t & 0xff] : void 0, this._keySchedule[ksRow - keySize] ^ t) - } - this._invKeySchedule = [] - for (invKsRow = 0; invKsRow < ksRows; invKsRow++) { - ksRow = ksRows - invKsRow - t = this._keySchedule[ksRow - (invKsRow % 4 ? 0 : 4)] - this._invKeySchedule[invKsRow] = invKsRow < 4 || ksRow <= 4 ? t : G.INV_SUB_MIX[0][G.SBOX[t >>> 24]] ^ G.INV_SUB_MIX[1][G.SBOX[(t >>> 16) & 0xff]] ^ G.INV_SUB_MIX[2][G.SBOX[(t >>> 8) & 0xff]] ^ G.INV_SUB_MIX[3][G.SBOX[t & 0xff]] - } - return true -} + /** + * @return {object} + * @optional + */ + getChildContext: 'DEFINE_MANY_MERGED', -AES.prototype.encryptBlock = function (M) { - M = bufferToArray(new Buffer(M)) - var out = this._doCryptBlock(M, this._keySchedule, G.SUB_MIX, G.SBOX) - var buf = new Buffer(16) - buf.writeUInt32BE(out[0], 0) - buf.writeUInt32BE(out[1], 4) - buf.writeUInt32BE(out[2], 8) - buf.writeUInt32BE(out[3], 12) - return buf -} + /** + * Uses props from `this.props` and state from `this.state` to render the + * structure of the component. + * + * No guarantees are made about when or how often this method is invoked, so + * it must not have side effects. + * + * render: function() { + * var name = this.props.name; + * return <div>Hello, {name}!</div>; + * } + * + * @return {ReactComponent} + * @required + */ + render: 'DEFINE_ONCE', -AES.prototype.decryptBlock = function (M) { - M = bufferToArray(new Buffer(M)) - var temp = [M[3], M[1]] - M[1] = temp[0] - M[3] = temp[1] - var out = this._doCryptBlock(M, this._invKeySchedule, G.INV_SUB_MIX, G.INV_SBOX) - var buf = new Buffer(16) - buf.writeUInt32BE(out[0], 0) - buf.writeUInt32BE(out[3], 4) - buf.writeUInt32BE(out[2], 8) - buf.writeUInt32BE(out[1], 12) - return buf -} + // ==== Delegate methods ==== -AES.prototype.scrub = function () { - scrub_vec(this._keySchedule) - scrub_vec(this._invKeySchedule) - scrub_vec(this._key) -} + /** + * Invoked when the component is initially created and about to be mounted. + * This may have side effects, but any external subscriptions or data created + * by this method must be cleaned up in `componentWillUnmount`. + * + * @optional + */ + componentWillMount: 'DEFINE_MANY', -AES.prototype._doCryptBlock = function (M, keySchedule, SUB_MIX, SBOX) { - var ksRow, s0, s1, s2, s3, t0, t1, t2, t3 + /** + * Invoked when the component has been mounted and has a DOM representation. + * However, there is no guarantee that the DOM node is in the document. + * + * Use this as an opportunity to operate on the DOM when the component has + * been mounted (initialized and rendered) for the first time. + * + * @param {DOMElement} rootNode DOM element representing the component. + * @optional + */ + componentDidMount: 'DEFINE_MANY', - s0 = M[0] ^ keySchedule[0] - s1 = M[1] ^ keySchedule[1] - s2 = M[2] ^ keySchedule[2] - s3 = M[3] ^ keySchedule[3] - ksRow = 4 - for (var round = 1; round < this._nRounds; round++) { - t0 = SUB_MIX[0][s0 >>> 24] ^ SUB_MIX[1][(s1 >>> 16) & 0xff] ^ SUB_MIX[2][(s2 >>> 8) & 0xff] ^ SUB_MIX[3][s3 & 0xff] ^ keySchedule[ksRow++] - t1 = SUB_MIX[0][s1 >>> 24] ^ SUB_MIX[1][(s2 >>> 16) & 0xff] ^ SUB_MIX[2][(s3 >>> 8) & 0xff] ^ SUB_MIX[3][s0 & 0xff] ^ keySchedule[ksRow++] - t2 = SUB_MIX[0][s2 >>> 24] ^ SUB_MIX[1][(s3 >>> 16) & 0xff] ^ SUB_MIX[2][(s0 >>> 8) & 0xff] ^ SUB_MIX[3][s1 & 0xff] ^ keySchedule[ksRow++] - t3 = SUB_MIX[0][s3 >>> 24] ^ SUB_MIX[1][(s0 >>> 16) & 0xff] ^ SUB_MIX[2][(s1 >>> 8) & 0xff] ^ SUB_MIX[3][s2 & 0xff] ^ keySchedule[ksRow++] - s0 = t0 - s1 = t1 - s2 = t2 - s3 = t3 - } - t0 = ((SBOX[s0 >>> 24] << 24) | (SBOX[(s1 >>> 16) & 0xff] << 16) | (SBOX[(s2 >>> 8) & 0xff] << 8) | SBOX[s3 & 0xff]) ^ keySchedule[ksRow++] - t1 = ((SBOX[s1 >>> 24] << 24) | (SBOX[(s2 >>> 16) & 0xff] << 16) | (SBOX[(s3 >>> 8) & 0xff] << 8) | SBOX[s0 & 0xff]) ^ keySchedule[ksRow++] - t2 = ((SBOX[s2 >>> 24] << 24) | (SBOX[(s3 >>> 16) & 0xff] << 16) | (SBOX[(s0 >>> 8) & 0xff] << 8) | SBOX[s1 & 0xff]) ^ keySchedule[ksRow++] - t3 = ((SBOX[s3 >>> 24] << 24) | (SBOX[(s0 >>> 16) & 0xff] << 16) | (SBOX[(s1 >>> 8) & 0xff] << 8) | SBOX[s2 & 0xff]) ^ keySchedule[ksRow++] - return [ - fixup_uint32(t0), - fixup_uint32(t1), - fixup_uint32(t2), - fixup_uint32(t3) - ] -} + /** + * Invoked before the component receives new props. + * + * Use this as an opportunity to react to a prop transition by updating the + * state using `this.setState`. Current props are accessed via `this.props`. + * + * componentWillReceiveProps: function(nextProps, nextContext) { + * this.setState({ + * likesIncreasing: nextProps.likeCount > this.props.likeCount + * }); + * } + * + * NOTE: There is no equivalent `componentWillReceiveState`. An incoming prop + * transition may cause a state change, but the opposite is not true. If you + * need it, you are probably looking for `componentWillUpdate`. + * + * @param {object} nextProps + * @optional + */ + componentWillReceiveProps: 'DEFINE_MANY', -exports.AES = AES + /** + * Invoked while deciding if the component should be updated as a result of + * receiving new props, state and/or context. + * + * Use this as an opportunity to `return false` when you're certain that the + * transition to the new props/state/context will not require a component + * update. + * + * shouldComponentUpdate: function(nextProps, nextState, nextContext) { + * return !equal(nextProps, this.props) || + * !equal(nextState, this.state) || + * !equal(nextContext, this.context); + * } + * + * @param {object} nextProps + * @param {?object} nextState + * @param {?object} nextContext + * @return {boolean} True if the component should update. + * @optional + */ + shouldComponentUpdate: 'DEFINE_ONCE', -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + /** + * Invoked when the component is about to update due to a transition from + * `this.props`, `this.state` and `this.context` to `nextProps`, `nextState` + * and `nextContext`. + * + * Use this as an opportunity to perform preparation before an update occurs. + * + * NOTE: You **cannot** use `this.setState()` in this method. + * + * @param {object} nextProps + * @param {?object} nextState + * @param {?object} nextContext + * @param {ReactReconcileTransaction} transaction + * @optional + */ + componentWillUpdate: 'DEFINE_MANY', -/***/ }), -/* 252 */ -/***/ (function(module, exports) { + /** + * Invoked when the component's DOM representation has been updated. + * + * Use this as an opportunity to operate on the DOM when the component has + * been updated. + * + * @param {object} prevProps + * @param {?object} prevState + * @param {?object} prevContext + * @param {DOMElement} rootNode DOM element representing the component. + * @optional + */ + componentDidUpdate: 'DEFINE_MANY', -exports['aes-128-ecb'] = { - cipher: 'AES', - key: 128, - iv: 0, - mode: 'ECB', - type: 'block' -} -exports['aes-192-ecb'] = { - cipher: 'AES', - key: 192, - iv: 0, - mode: 'ECB', - type: 'block' -} -exports['aes-256-ecb'] = { - cipher: 'AES', - key: 256, - iv: 0, - mode: 'ECB', - type: 'block' -} -exports['aes-128-cbc'] = { - cipher: 'AES', - key: 128, - iv: 16, - mode: 'CBC', - type: 'block' -} -exports['aes-192-cbc'] = { - cipher: 'AES', - key: 192, - iv: 16, - mode: 'CBC', - type: 'block' -} -exports['aes-256-cbc'] = { - cipher: 'AES', - key: 256, - iv: 16, - mode: 'CBC', - type: 'block' -} -exports['aes128'] = exports['aes-128-cbc'] -exports['aes192'] = exports['aes-192-cbc'] -exports['aes256'] = exports['aes-256-cbc'] -exports['aes-128-cfb'] = { - cipher: 'AES', - key: 128, - iv: 16, - mode: 'CFB', - type: 'stream' -} -exports['aes-192-cfb'] = { - cipher: 'AES', - key: 192, - iv: 16, - mode: 'CFB', - type: 'stream' -} -exports['aes-256-cfb'] = { - cipher: 'AES', - key: 256, - iv: 16, - mode: 'CFB', - type: 'stream' -} -exports['aes-128-cfb8'] = { - cipher: 'AES', - key: 128, - iv: 16, - mode: 'CFB8', - type: 'stream' -} -exports['aes-192-cfb8'] = { - cipher: 'AES', - key: 192, - iv: 16, - mode: 'CFB8', - type: 'stream' -} -exports['aes-256-cfb8'] = { - cipher: 'AES', - key: 256, - iv: 16, - mode: 'CFB8', - type: 'stream' -} -exports['aes-128-cfb1'] = { - cipher: 'AES', - key: 128, - iv: 16, - mode: 'CFB1', - type: 'stream' -} -exports['aes-192-cfb1'] = { - cipher: 'AES', - key: 192, - iv: 16, - mode: 'CFB1', - type: 'stream' -} -exports['aes-256-cfb1'] = { - cipher: 'AES', - key: 256, - iv: 16, - mode: 'CFB1', - type: 'stream' -} -exports['aes-128-ofb'] = { - cipher: 'AES', - key: 128, - iv: 16, - mode: 'OFB', - type: 'stream' -} -exports['aes-192-ofb'] = { - cipher: 'AES', - key: 192, - iv: 16, - mode: 'OFB', - type: 'stream' -} -exports['aes-256-ofb'] = { - cipher: 'AES', - key: 256, - iv: 16, - mode: 'OFB', - type: 'stream' -} -exports['aes-128-ctr'] = { - cipher: 'AES', - key: 128, - iv: 16, - mode: 'CTR', - type: 'stream' -} -exports['aes-192-ctr'] = { - cipher: 'AES', - key: 192, - iv: 16, - mode: 'CTR', - type: 'stream' -} -exports['aes-256-ctr'] = { - cipher: 'AES', - key: 256, - iv: 16, - mode: 'CTR', - type: 'stream' -} -exports['aes-128-gcm'] = { - cipher: 'AES', - key: 128, - iv: 12, - mode: 'GCM', - type: 'auth' -} -exports['aes-192-gcm'] = { - cipher: 'AES', - key: 192, - iv: 12, - mode: 'GCM', - type: 'auth' -} -exports['aes-256-gcm'] = { - cipher: 'AES', - key: 256, - iv: 12, - mode: 'GCM', - type: 'auth' -} + /** + * Invoked when the component is about to be removed from its parent and have + * its DOM representation destroyed. + * + * Use this as an opportunity to deallocate any external resources. + * + * NOTE: There is no `componentDidUnmount` since your component will have been + * destroyed by that point. + * + * @optional + */ + componentWillUnmount: 'DEFINE_MANY', + // ==== Advanced methods ==== -/***/ }), -/* 253 */ -/***/ (function(module, exports, __webpack_require__) { + /** + * Updates the component's currently mounted DOM representation. + * + * By default, this implements React's rendering and reconciliation algorithm. + * Sophisticated clients may wish to override this. + * + * @param {ReactReconcileTransaction} transaction + * @internal + * @overridable + */ + updateComponent: 'OVERRIDE_BASE' + }; -/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(239) + /** + * Mapping from class specification keys to special processing functions. + * + * Although these are declared like instance properties in the specification + * when defining classes using `React.createClass`, they are actually static + * and are accessible on the constructor instead of the prototype. Despite + * being static, they must be defined outside of the "statics" key under + * which all other static methods are defined. + */ + var RESERVED_SPEC_KEYS = { + displayName: function(Constructor, displayName) { + Constructor.displayName = displayName; + }, + mixins: function(Constructor, mixins) { + if (mixins) { + for (var i = 0; i < mixins.length; i++) { + mixSpecIntoComponent(Constructor, mixins[i]); + } + } + }, + childContextTypes: function(Constructor, childContextTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, childContextTypes, 'childContext'); + } + Constructor.childContextTypes = _assign( + {}, + Constructor.childContextTypes, + childContextTypes + ); + }, + contextTypes: function(Constructor, contextTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, contextTypes, 'context'); + } + Constructor.contextTypes = _assign( + {}, + Constructor.contextTypes, + contextTypes + ); + }, + /** + * Special case getDefaultProps which should move into statics but requires + * automatic merging. + */ + getDefaultProps: function(Constructor, getDefaultProps) { + if (Constructor.getDefaultProps) { + Constructor.getDefaultProps = createMergedResultFunction( + Constructor.getDefaultProps, + getDefaultProps + ); + } else { + Constructor.getDefaultProps = getDefaultProps; + } + }, + propTypes: function(Constructor, propTypes) { + if (process.env.NODE_ENV !== 'production') { + validateTypeDef(Constructor, propTypes, 'prop'); + } + Constructor.propTypes = _assign({}, Constructor.propTypes, propTypes); + }, + statics: function(Constructor, statics) { + mixStaticSpecIntoComponent(Constructor, statics); + }, + autobind: function() {} + }; -function incr32 (iv) { - var len = iv.length - var item - while (len--) { - item = iv.readUInt8(len) - if (item === 255) { - iv.writeUInt8(0, len) - } else { - item++ - iv.writeUInt8(item, len) - break + function validateTypeDef(Constructor, typeDef, location) { + for (var propName in typeDef) { + if (typeDef.hasOwnProperty(propName)) { + // use a warning instead of an _invariant so components + // don't show up in prod but only in __DEV__ + if (process.env.NODE_ENV !== 'production') { + warning( + typeof typeDef[propName] === 'function', + '%s: %s type `%s` is invalid; it must be a function, usually from ' + + 'React.PropTypes.', + Constructor.displayName || 'ReactClass', + ReactPropTypeLocationNames[location], + propName + ); + } + } } } -} -function getBlock (self) { - var out = self._cipher.encryptBlock(self._prev) - incr32(self._prev) - return out -} + function validateMethodOverride(isAlreadyDefined, name) { + var specPolicy = ReactClassInterface.hasOwnProperty(name) + ? ReactClassInterface[name] + : null; -exports.encrypt = function (self, chunk) { - while (self._cache.length < chunk.length) { - self._cache = Buffer.concat([self._cache, getBlock(self)]) + // Disallow overriding of base class methods unless explicitly allowed. + if (ReactClassMixin.hasOwnProperty(name)) { + _invariant( + specPolicy === 'OVERRIDE_BASE', + 'ReactClassInterface: You are attempting to override ' + + '`%s` from your class specification. Ensure that your method names ' + + 'do not overlap with React methods.', + name + ); + } + + // Disallow defining methods more than once unless explicitly allowed. + if (isAlreadyDefined) { + _invariant( + specPolicy === 'DEFINE_MANY' || specPolicy === 'DEFINE_MANY_MERGED', + 'ReactClassInterface: You are attempting to define ' + + '`%s` on your component more than once. This conflict may be due ' + + 'to a mixin.', + name + ); + } } - var pad = self._cache.slice(0, chunk.length) - self._cache = self._cache.slice(chunk.length) - return xor(chunk, pad) -} -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + /** + * Mixin helper which handles policy validation and reserved + * specification keys when building React classes. + */ + function mixSpecIntoComponent(Constructor, spec) { + if (!spec) { + if (process.env.NODE_ENV !== 'production') { + var typeofSpec = typeof spec; + var isMixinValid = typeofSpec === 'object' && spec !== null; -/***/ }), -/* 254 */ -/***/ (function(module, exports, __webpack_require__) { + if (process.env.NODE_ENV !== 'production') { + warning( + isMixinValid, + "%s: You're attempting to include a mixin that is either null " + + 'or not an object. Check the mixins included by the component, ' + + 'as well as any mixins they include themselves. ' + + 'Expected object but got %s.', + Constructor.displayName || 'ReactClass', + spec === null ? null : typeofSpec + ); + } + } -/* WEBPACK VAR INJECTION */(function(Buffer) {var asn1 = __webpack_require__(499) -var aesid = __webpack_require__(511) -var fixProc = __webpack_require__(512) -var ciphers = __webpack_require__(270) -var compat = __webpack_require__(323) -module.exports = parseKeys + return; + } -function parseKeys (buffer) { - var password - if (typeof buffer === 'object' && !Buffer.isBuffer(buffer)) { - password = buffer.passphrase - buffer = buffer.key - } - if (typeof buffer === 'string') { - buffer = new Buffer(buffer) - } + _invariant( + typeof spec !== 'function', + "ReactClass: You're attempting to " + + 'use a component class or function as a mixin. Instead, just use a ' + + 'regular object.' + ); + _invariant( + !isValidElement(spec), + "ReactClass: You're attempting to " + + 'use a component as a mixin. Instead, just use a regular object.' + ); - var stripped = fixProc(buffer, password) + var proto = Constructor.prototype; + var autoBindPairs = proto.__reactAutoBindPairs; - var type = stripped.tag - var data = stripped.data - var subtype, ndata - switch (type) { - case 'CERTIFICATE': - ndata = asn1.certificate.decode(data, 'der').tbsCertificate.subjectPublicKeyInfo - // falls through - case 'PUBLIC KEY': - if (!ndata) { - ndata = asn1.PublicKey.decode(data, 'der') + // By handling mixins before any other properties, we ensure the same + // chaining order is applied to methods with DEFINE_MANY policy, whether + // mixins are listed before or after these methods in the spec. + if (spec.hasOwnProperty(MIXINS_KEY)) { + RESERVED_SPEC_KEYS.mixins(Constructor, spec.mixins); + } + + for (var name in spec) { + if (!spec.hasOwnProperty(name)) { + continue; } - subtype = ndata.algorithm.algorithm.join('.') - switch (subtype) { - case '1.2.840.113549.1.1.1': - return asn1.RSAPublicKey.decode(ndata.subjectPublicKey.data, 'der') - case '1.2.840.10045.2.1': - ndata.subjectPrivateKey = ndata.subjectPublicKey - return { - type: 'ec', - data: ndata - } - case '1.2.840.10040.4.1': - ndata.algorithm.params.pub_key = asn1.DSAparam.decode(ndata.subjectPublicKey.data, 'der') - return { - type: 'dsa', - data: ndata.algorithm.params - } - default: throw new Error('unknown key id ' + subtype) - } - throw new Error('unknown key type ' + type) - case 'ENCRYPTED PRIVATE KEY': - data = asn1.EncryptedPrivateKey.decode(data, 'der') - data = decrypt(data, password) - // falls through - case 'PRIVATE KEY': - ndata = asn1.PrivateKey.decode(data, 'der') - subtype = ndata.algorithm.algorithm.join('.') - switch (subtype) { - case '1.2.840.113549.1.1.1': - return asn1.RSAPrivateKey.decode(ndata.subjectPrivateKey, 'der') - case '1.2.840.10045.2.1': - return { - curve: ndata.algorithm.curve, - privateKey: asn1.ECPrivateKey.decode(ndata.subjectPrivateKey, 'der').privateKey - } - case '1.2.840.10040.4.1': - ndata.algorithm.params.priv_key = asn1.DSAparam.decode(ndata.subjectPrivateKey, 'der') - return { - type: 'dsa', - params: ndata.algorithm.params - } - default: throw new Error('unknown key id ' + subtype) - } - throw new Error('unknown key type ' + type) - case 'RSA PUBLIC KEY': - return asn1.RSAPublicKey.decode(data, 'der') - case 'RSA PRIVATE KEY': - return asn1.RSAPrivateKey.decode(data, 'der') - case 'DSA PRIVATE KEY': - return { - type: 'dsa', - params: asn1.DSAPrivateKey.decode(data, 'der') - } - case 'EC PRIVATE KEY': - data = asn1.ECPrivateKey.decode(data, 'der') - return { - curve: data.parameters.value, - privateKey: data.privateKey - } - default: throw new Error('unknown key type ' + type) - } -} -parseKeys.signature = asn1.signature -function decrypt (data, password) { - var salt = data.algorithm.decrypt.kde.kdeparams.salt - var iters = parseInt(data.algorithm.decrypt.kde.kdeparams.iters.toString(), 10) - var algo = aesid[data.algorithm.decrypt.cipher.algo.join('.')] - var iv = data.algorithm.decrypt.cipher.iv - var cipherText = data.subjectPrivateKey - var keylen = parseInt(algo.split('-')[1], 10) / 8 - var key = compat.pbkdf2Sync(password, salt, iters, keylen) - var cipher = ciphers.createDecipheriv(algo, key, iv) - var out = [] - out.push(cipher.update(cipherText)) - out.push(cipher.final()) - return Buffer.concat(out) -} - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) - -/***/ }), -/* 255 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(Buffer) { + if (name === MIXINS_KEY) { + // We have already handled mixins in a special case above. + continue; + } -// Number.MAX_SAFE_INTEGER -var MAX_SAFE_INTEGER = 9007199254740991 + var property = spec[name]; + var isAlreadyDefined = proto.hasOwnProperty(name); + validateMethodOverride(isAlreadyDefined, name); -function checkUInt53 (n) { - if (n < 0 || n > MAX_SAFE_INTEGER || n % 1 !== 0) throw new RangeError('value out of range') -} + if (RESERVED_SPEC_KEYS.hasOwnProperty(name)) { + RESERVED_SPEC_KEYS[name](Constructor, property); + } else { + // Setup methods on prototype: + // The following member methods should not be automatically bound: + // 1. Expected ReactClass methods (in the "interface"). + // 2. Overridden methods (that were mixed in). + var isReactClassMethod = ReactClassInterface.hasOwnProperty(name); + var isFunction = typeof property === 'function'; + var shouldAutoBind = + isFunction && + !isReactClassMethod && + !isAlreadyDefined && + spec.autobind !== false; -function encode (number, buffer, offset) { - checkUInt53(number) + if (shouldAutoBind) { + autoBindPairs.push(name, property); + proto[name] = property; + } else { + if (isAlreadyDefined) { + var specPolicy = ReactClassInterface[name]; - if (!buffer) buffer = new Buffer(encodingLength(number)) - if (!Buffer.isBuffer(buffer)) throw new TypeError('buffer must be a Buffer instance') - if (!offset) offset = 0 + // These cases should already be caught by validateMethodOverride. + _invariant( + isReactClassMethod && + (specPolicy === 'DEFINE_MANY_MERGED' || + specPolicy === 'DEFINE_MANY'), + 'ReactClass: Unexpected spec policy %s for key %s ' + + 'when mixing in component specs.', + specPolicy, + name + ); - // 8 bit - if (number < 0xfd) { - buffer.writeUInt8(number, offset) - encode.bytes = 1 + // For methods which are defined more than once, call the existing + // methods before calling the new property, merging if appropriate. + if (specPolicy === 'DEFINE_MANY_MERGED') { + proto[name] = createMergedResultFunction(proto[name], property); + } else if (specPolicy === 'DEFINE_MANY') { + proto[name] = createChainedFunction(proto[name], property); + } + } else { + proto[name] = property; + if (process.env.NODE_ENV !== 'production') { + // Add verbose displayName to the function, which helps when looking + // at profiling tools. + if (typeof property === 'function' && spec.displayName) { + proto[name].displayName = spec.displayName + '_' + name; + } + } + } + } + } + } + } - // 16 bit - } else if (number <= 0xffff) { - buffer.writeUInt8(0xfd, offset) - buffer.writeUInt16LE(number, offset + 1) - encode.bytes = 3 + function mixStaticSpecIntoComponent(Constructor, statics) { + if (!statics) { + return; + } + for (var name in statics) { + var property = statics[name]; + if (!statics.hasOwnProperty(name)) { + continue; + } - // 32 bit - } else if (number <= 0xffffffff) { - buffer.writeUInt8(0xfe, offset) - buffer.writeUInt32LE(number, offset + 1) - encode.bytes = 5 + var isReserved = name in RESERVED_SPEC_KEYS; + _invariant( + !isReserved, + 'ReactClass: You are attempting to define a reserved ' + + 'property, `%s`, that shouldn\'t be on the "statics" key. Define it ' + + 'as an instance property instead; it will still be accessible on the ' + + 'constructor.', + name + ); - // 64 bit - } else { - buffer.writeUInt8(0xff, offset) - buffer.writeUInt32LE(number >>> 0, offset + 1) - buffer.writeUInt32LE((number / 0x100000000) | 0, offset + 5) - encode.bytes = 9 + var isInherited = name in Constructor; + _invariant( + !isInherited, + 'ReactClass: You are attempting to define ' + + '`%s` on your component more than once. This conflict may be ' + + 'due to a mixin.', + name + ); + Constructor[name] = property; + } } - return buffer -} - -function decode (buffer, offset) { - if (!Buffer.isBuffer(buffer)) throw new TypeError('buffer must be a Buffer instance') - if (!offset) offset = 0 - - var first = buffer.readUInt8(offset) + /** + * Merge two objects, but throw if both contain the same key. + * + * @param {object} one The first object, which is mutated. + * @param {object} two The second object + * @return {object} one after it has been mutated to contain everything in two. + */ + function mergeIntoWithNoDuplicateKeys(one, two) { + _invariant( + one && two && typeof one === 'object' && typeof two === 'object', + 'mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.' + ); - // 8 bit - if (first < 0xfd) { - decode.bytes = 1 - return first + for (var key in two) { + if (two.hasOwnProperty(key)) { + _invariant( + one[key] === undefined, + 'mergeIntoWithNoDuplicateKeys(): ' + + 'Tried to merge two objects with the same key: `%s`. This conflict ' + + 'may be due to a mixin; in particular, this may be caused by two ' + + 'getInitialState() or getDefaultProps() methods returning objects ' + + 'with clashing keys.', + key + ); + one[key] = two[key]; + } + } + return one; + } - // 16 bit - } else if (first === 0xfd) { - decode.bytes = 3 - return buffer.readUInt16LE(offset + 1) + /** + * Creates a function that invokes two functions and merges their return values. + * + * @param {function} one Function to invoke first. + * @param {function} two Function to invoke second. + * @return {function} Function that invokes the two argument functions. + * @private + */ + function createMergedResultFunction(one, two) { + return function mergedResult() { + var a = one.apply(this, arguments); + var b = two.apply(this, arguments); + if (a == null) { + return b; + } else if (b == null) { + return a; + } + var c = {}; + mergeIntoWithNoDuplicateKeys(c, a); + mergeIntoWithNoDuplicateKeys(c, b); + return c; + }; + } - // 32 bit - } else if (first === 0xfe) { - decode.bytes = 5 - return buffer.readUInt32LE(offset + 1) + /** + * Creates a function that invokes two functions and ignores their return vales. + * + * @param {function} one Function to invoke first. + * @param {function} two Function to invoke second. + * @return {function} Function that invokes the two argument functions. + * @private + */ + function createChainedFunction(one, two) { + return function chainedFunction() { + one.apply(this, arguments); + two.apply(this, arguments); + }; + } - // 64 bit - } else { - decode.bytes = 9 - var lo = buffer.readUInt32LE(offset + 1) - var hi = buffer.readUInt32LE(offset + 5) - var number = hi * 0x0100000000 + lo - checkUInt53(number) + /** + * Binds a method to the component. + * + * @param {object} component Component whose method is going to be bound. + * @param {function} method Method to be bound. + * @return {function} The bound method. + */ + function bindAutoBindMethod(component, method) { + var boundMethod = method.bind(component); + if (process.env.NODE_ENV !== 'production') { + boundMethod.__reactBoundContext = component; + boundMethod.__reactBoundMethod = method; + boundMethod.__reactBoundArguments = null; + var componentName = component.constructor.displayName; + var _bind = boundMethod.bind; + boundMethod.bind = function(newThis) { + for ( + var _len = arguments.length, + args = Array(_len > 1 ? _len - 1 : 0), + _key = 1; + _key < _len; + _key++ + ) { + args[_key - 1] = arguments[_key]; + } - return number + // User is trying to bind() an autobound method; we effectively will + // ignore the value of "this" that the user is trying to use, so + // let's warn. + if (newThis !== component && newThis !== null) { + if (process.env.NODE_ENV !== 'production') { + warning( + false, + 'bind(): React component methods may only be bound to the ' + + 'component instance. See %s', + componentName + ); + } + } else if (!args.length) { + if (process.env.NODE_ENV !== 'production') { + warning( + false, + 'bind(): You are binding a component method to the component. ' + + 'React does this for you automatically in a high-performance ' + + 'way, so you can safely remove this call. See %s', + componentName + ); + } + return boundMethod; + } + var reboundMethod = _bind.apply(boundMethod, arguments); + reboundMethod.__reactBoundContext = component; + reboundMethod.__reactBoundMethod = method; + reboundMethod.__reactBoundArguments = args; + return reboundMethod; + }; + } + return boundMethod; } -} - -function encodingLength (number) { - checkUInt53(number) - return ( - number < 0xfd ? 1 - : number <= 0xffff ? 3 - : number <= 0xffffffff ? 5 - : 9 - ) -} + /** + * Binds all auto-bound methods in a component. + * + * @param {object} component Component whose method is going to be bound. + */ + function bindAutoBindMethods(component) { + var pairs = component.__reactAutoBindPairs; + for (var i = 0; i < pairs.length; i += 2) { + var autoBindKey = pairs[i]; + var method = pairs[i + 1]; + component[autoBindKey] = bindAutoBindMethod(component, method); + } + } -module.exports = { encode: encode, decode: decode, encodingLength: encodingLength } + var IsMountedPreMixin = { + componentDidMount: function() { + this.__isMounted = true; + } + }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + var IsMountedPostMixin = { + componentWillUnmount: function() { + this.__isMounted = false; + } + }; -/***/ }), -/* 256 */ -/***/ (function(module, exports, __webpack_require__) { + /** + * Add more to the ReactClass base class. These are all legacy features and + * therefore not already part of the modern ReactComponent. + */ + var ReactClassMixin = { + /** + * TODO: This will be deprecated because state should always keep a consistent + * type signature and the only use case for this, is to avoid that. + */ + replaceState: function(newState, callback) { + this.updater.enqueueReplaceState(this, newState, callback); + }, -var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (global, factory) { - if (true) { - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), - __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? - (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else if (typeof exports !== "undefined") { - factory(exports); - } else { - var mod = { - exports: {} - }; - factory(mod.exports); - global.sAlertTools = mod.exports; + /** + * Checks whether or not this composite component is mounted. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ + isMounted: function() { + if (process.env.NODE_ENV !== 'production') { + warning( + this.__didWarnIsMounted, + '%s: isMounted is deprecated. Instead, make sure to clean up ' + + 'subscriptions and pending requests in componentWillUnmount to ' + + 'prevent memory leaks.', + (this.constructor && this.constructor.displayName) || + this.name || + 'Component' + ); + this.__didWarnIsMounted = true; + } + return !!this.__isMounted; } -})(this, function (exports) { - 'use strict'; - - Object.defineProperty(exports, "__esModule", { - value: true - }); + }; - var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { - return typeof obj; - } : function (obj) { - return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; - }; + var ReactClassComponent = function() {}; + _assign( + ReactClassComponent.prototype, + ReactComponent.prototype, + ReactClassMixin + ); - var actualGlobalConfig = void 0; + /** + * Creates a composite component class given a class specification. + * See https://facebook.github.io/react/docs/top-level-api.html#react.createclass + * + * @param {object} spec Class specification (which must define `render`). + * @return {function} Component constructor function. + * @public + */ + function createClass(spec) { + // To keep our warnings more understandable, we'll use a little hack here to + // ensure that Constructor.name !== 'Constructor'. This makes sure we don't + // unnecessarily identify a class without displayName as 'Constructor'. + var Constructor = identity(function(props, context, updater) { + // This constructor gets overridden by mocks. The argument is used + // by mocks to assert on what gets mounted. - var sAlertTools = { - randomId: function randomId() { - return Math.random().toString(36).split('.')[1]; - }, - returnFirstDefined: function returnFirstDefined() { - var value = void 0; - var i = void 0; + if (process.env.NODE_ENV !== 'production') { + warning( + this instanceof Constructor, + 'Something is calling a React component directly. Use a factory or ' + + 'JSX instead. See: https://fb.me/react-legacyfactory' + ); + } - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } + // Wire up auto-binding + if (this.__reactAutoBindPairs.length) { + bindAutoBindMethods(this); + } - for (i = 0; i < args.length; i++) { - if (typeof args[i] !== 'undefined') { - value = args[i]; - break; - } - } - return value; - }, - styleToObj: function styleToObj(input) { - var result = {}, - i = void 0, - entry = void 0, - attributes = input && input.split(';').filter(Boolean); - - for (i = 0; i < attributes.length; i++) { - entry = attributes[i].split(':'); - result[entry.splice(0, 1)[0].trim()] = entry.join(':').trim(); - } - return result; - }, - setGlobalConfig: function setGlobalConfig(config) { - if ((typeof config === 'undefined' ? 'undefined' : _typeof(config)) === 'object') { - actualGlobalConfig = config; - } - }, - getGlobalConfig: function getGlobalConfig() { - return actualGlobalConfig; - } - }; + this.props = props; + this.context = context; + this.refs = emptyObject; + this.updater = updater || ReactNoopUpdateQueue; - exports.default = sAlertTools; -}); + this.state = null; -/***/ }), -/* 257 */ -/***/ (function(module, exports, __webpack_require__) { + // ReactClasses doesn't have constructors. Instead, they use the + // getInitialState and componentWillMount methods for initialization. -var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (global, factory) { - if (true) { - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), - __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? - (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else if (typeof exports !== "undefined") { - factory(exports); - } else { - var mod = { - exports: {} - }; - factory(mod.exports); - global.sAlertStore = mod.exports; - } -})(this, function (exports) { - 'use strict'; + var initialState = this.getInitialState ? this.getInitialState() : null; + if (process.env.NODE_ENV !== 'production') { + // We allow auto-mocks to proceed as if they're returning null. + if ( + initialState === undefined && + this.getInitialState._isMockFunction + ) { + // This is probably bad practice. Consider warning here and + // deprecating this convenience. + initialState = null; + } + } + _invariant( + typeof initialState === 'object' && !Array.isArray(initialState), + '%s.getInitialState(): must return an object or null', + Constructor.displayName || 'ReactCompositeComponent' + ); - Object.defineProperty(exports, "__esModule", { - value: true + this.state = initialState; }); + Constructor.prototype = new ReactClassComponent(); + Constructor.prototype.constructor = Constructor; + Constructor.prototype.__reactAutoBindPairs = []; - function _toConsumableArray(arr) { - if (Array.isArray(arr)) { - for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { - arr2[i] = arr[i]; - } - - return arr2; - } else { - return Array.from(arr); - } - } + injectedMixins.forEach(mixSpecIntoComponent.bind(null, Constructor)); - // custom simple store based on a awesome Redux library https://github.com/rackt/redux + mixSpecIntoComponent(Constructor, IsMountedPreMixin); + mixSpecIntoComponent(Constructor, spec); + mixSpecIntoComponent(Constructor, IsMountedPostMixin); - var createSAlertStore = function createSAlertStore(reducer) { - var state = void 0; - var listeners = []; - var getState = function getState() { - return state; - }; - var dispatch = function dispatch(action) { - state = reducer(state, action); - listeners.forEach(function (listener) { - return listener(); - }); - }; - var subscribe = function subscribe(listener) { - listeners.push(listener); - return function () { - listeners = listeners.filter(function (l) { - return l !== listener; - }); - }; - }; - dispatch({}); - return { - getState: getState, dispatch: dispatch, subscribe: subscribe - }; - }; + // Initialize the defaultProps property after all mixins have been merged. + if (Constructor.getDefaultProps) { + Constructor.defaultProps = Constructor.getDefaultProps(); + } - var insert = function insert(state, action) { - return [].concat(_toConsumableArray(state), [action.data]); - }; + if (process.env.NODE_ENV !== 'production') { + // This is a tag to indicate that the use of these method names is ok, + // since it's used with createClass. If it's not, then it's likely a + // mistake so we'll warn you to use the static property, property + // initializer or constructor respectively. + if (Constructor.getDefaultProps) { + Constructor.getDefaultProps.isReactClassApproved = {}; + } + if (Constructor.prototype.getInitialState) { + Constructor.prototype.getInitialState.isReactClassApproved = {}; + } + } - var remove = function remove(state, action) { - var elemToRemoveArray = state.slice().filter(function (item) { - return item.id === action.data.id; - }); - if (Array.isArray(elemToRemoveArray)) { - var elemToRemoveIndex = state.indexOf(elemToRemoveArray[0]); - return [].concat(_toConsumableArray(state.slice(0, elemToRemoveIndex)), _toConsumableArray(state.slice(elemToRemoveIndex + 1))); - } - return state; - }; + _invariant( + Constructor.prototype.render, + 'createClass(...): Class specification must implement a `render` method.' + ); - var alertsReducer = function alertsReducer() { - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : []; - var action = arguments[1]; - - switch (action.type) { - case 'INSERT': - return insert(state, action); - case 'REMOVE': - return remove(state, action); - case 'REMOVEALL': - return []; - default: - return state; - } - }; + if (process.env.NODE_ENV !== 'production') { + warning( + !Constructor.prototype.componentShouldUpdate, + '%s has a method called ' + + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + + 'The name is phrased as a question because the function is ' + + 'expected to return a value.', + spec.displayName || 'A component' + ); + warning( + !Constructor.prototype.componentWillRecieveProps, + '%s has a method called ' + + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', + spec.displayName || 'A component' + ); + } + + // Reduce time spent doing lookups by setting these on the prototype. + for (var methodName in ReactClassInterface) { + if (!Constructor.prototype[methodName]) { + Constructor.prototype[methodName] = null; + } + } + + return Constructor; + } - var sAlertStore = createSAlertStore(alertsReducer); + return createClass; +} - exports.default = sAlertStore; -}); +module.exports = factory; + +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 258 */ +/* 229 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(process) { +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var utils = __webpack_require__(46); -var normalizeHeaderName = __webpack_require__(404); -var DEFAULT_CONTENT_TYPE = { - 'Content-Type': 'application/x-www-form-urlencoded' -}; +var _prodInvariant = __webpack_require__(37); -function setContentTypeIfUnset(headers, value) { - if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) { - headers['Content-Type'] = value; - } -} +var ReactElement = __webpack_require__(31); -function getDefaultAdapter() { - var adapter; - if (typeof XMLHttpRequest !== 'undefined') { - // For browsers use XHR adapter - adapter = __webpack_require__(302); - } else if (typeof process !== 'undefined') { - // For node use HTTP adapter - adapter = __webpack_require__(302); - } - return adapter; +var invariant = __webpack_require__(2); + +/** + * Returns the first child in a collection of children and verifies that there + * is only one child in the collection. + * + * See https://facebook.github.io/react/docs/top-level-api.html#react.children.only + * + * The current implementation of this function assumes that a single child gets + * passed without a wrapper, but the purpose of this helper function is to + * abstract away the particular structure of children. + * + * @param {?object} children Child collection structure. + * @return {ReactElement} The first and only `ReactElement` contained in the + * structure. + */ +function onlyChild(children) { + !ReactElement.isValidElement(children) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'React.Children.only expected to receive a single React element child.') : _prodInvariant('143') : void 0; + return children; } -var defaults = { - adapter: getDefaultAdapter(), +module.exports = onlyChild; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - transformRequest: [function transformRequest(data, headers) { - normalizeHeaderName(headers, 'Content-Type'); - if (utils.isFormData(data) || - utils.isArrayBuffer(data) || - utils.isBuffer(data) || - utils.isStream(data) || - utils.isFile(data) || - utils.isBlob(data) - ) { - return data; - } - if (utils.isArrayBufferView(data)) { - return data.buffer; - } - if (utils.isURLSearchParams(data)) { - setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8'); - return data.toString(); - } - if (utils.isObject(data)) { - setContentTypeIfUnset(headers, 'application/json;charset=utf-8'); - return JSON.stringify(data); - } - return data; - }], +/***/ }), +/* 230 */ +/***/ (function(module, exports, __webpack_require__) { - transformResponse: [function transformResponse(data) { - /*eslint no-param-reassign:0*/ - if (typeof data === 'string') { - try { - data = JSON.parse(data); - } catch (e) { /* Ignore */ } - } - return data; - }], +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - timeout: 0, +/* globals __REACT_DEVTOOLS_GLOBAL_HOOK__*/ - xsrfCookieName: 'XSRF-TOKEN', - xsrfHeaderName: 'X-XSRF-TOKEN', - maxContentLength: -1, - validateStatus: function validateStatus(status) { - return status >= 200 && status < 300; - } -}; +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDefaultInjection = __webpack_require__(231); +var ReactMount = __webpack_require__(149); +var ReactReconciler = __webpack_require__(38); +var ReactUpdates = __webpack_require__(23); +var ReactVersion = __webpack_require__(309); -defaults.headers = { - common: { - 'Accept': 'application/json, text/plain, */*' - } -}; +var findDOMNode = __webpack_require__(310); +var getHostComponentFromComposite = __webpack_require__(150); +var renderSubtreeIntoContainer = __webpack_require__(311); +var warning = __webpack_require__(3); -utils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) { - defaults.headers[method] = {}; -}); +ReactDefaultInjection.inject(); -utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { - defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE); -}); +var ReactDOM = { + findDOMNode: findDOMNode, + render: ReactMount.render, + unmountComponentAtNode: ReactMount.unmountComponentAtNode, + version: ReactVersion, -module.exports = defaults; + /* eslint-disable camelcase */ + unstable_batchedUpdates: ReactUpdates.batchedUpdates, + unstable_renderSubtreeIntoContainer: renderSubtreeIntoContainer + /* eslint-enable camelcase */ +}; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) +// Inject the runtime into a devtools global hook regardless of browser. +// Allows for debugging when the hook is injected on the page. +if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject === 'function') { + __REACT_DEVTOOLS_GLOBAL_HOOK__.inject({ + ComponentTree: { + getClosestInstanceFromNode: ReactDOMComponentTree.getClosestInstanceFromNode, + getNodeFromInstance: function (inst) { + // inst is an internal instance (but could be a composite) + if (inst._renderedComponent) { + inst = getHostComponentFromComposite(inst); + } + if (inst) { + return ReactDOMComponentTree.getNodeFromInstance(inst); + } else { + return null; + } + } + }, + Mount: ReactMount, + Reconciler: ReactReconciler + }); +} -/***/ }), -/* 259 */ -/***/ (function(module, exports, __webpack_require__) { +if (process.env.NODE_ENV !== 'production') { + var ExecutionEnvironment = __webpack_require__(13); + if (ExecutionEnvironment.canUseDOM && window.top === window.self) { + // First check if devtools is not installed + if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined') { + // If we're in Chrome or Firefox, provide a download link if not installed. + if (navigator.userAgent.indexOf('Chrome') > -1 && navigator.userAgent.indexOf('Edge') === -1 || navigator.userAgent.indexOf('Firefox') > -1) { + // Firefox does not have the issue with devtools loaded over file:// + var showFileUrlMessage = window.location.protocol.indexOf('http') === -1 && navigator.userAgent.indexOf('Firefox') === -1; + console.debug('Download the React DevTools ' + (showFileUrlMessage ? 'and use an HTTP server (instead of a file: URL) ' : '') + 'for a better development experience: ' + 'https://fb.me/react-devtools'); + } + } -/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(111); -var secp256k1 = __webpack_require__(314); -var bigi = __webpack_require__(110); -var zcrypto = __webpack_require__(269); -var zconfig = __webpack_require__(248); + var testFunc = function testFn() {}; + process.env.NODE_ENV !== 'production' ? warning((testFunc.name || testFunc.toString()).indexOf('testFn') !== -1, "It looks like you're using a minified copy of the development build " + 'of React. When deploying React apps to production, make sure to use ' + 'the production build which skips development warnings and is faster. ' + 'See https://fb.me/react-minification for more details.') : void 0; -/* - * Makes a private key - * @param {String} phrase (Password phrase) - * @return {Sting} Private key - */ -function mkPrivKey(phrase) { - return zcrypto.sha256(Buffer.from(phrase, 'utf-8')); -} + // If we're in IE8, check to see if we are in compatibility mode and provide + // information on preventing compatibility mode + var ieCompatibilityMode = document.documentMode && document.documentMode < 8; -/* - * Converts a private key to WIF format - * @param {String} privKey (private key) - * @param {boolean} toCompressed (Convert to WIF compressed key or nah) - * @param {string} wif (wif hashing bytes (default: 0x80)) - * @return {Sting} WIF format (uncompressed) - */ -function privKeyToWIF(privKey, toCompressed, wif) { - toCompressed = toCompressed || false; - wif = wif || zconfig.mainnet.wif; + process.env.NODE_ENV !== 'production' ? warning(!ieCompatibilityMode, 'Internet Explorer is running in compatibility mode; please add the ' + 'following tag to your HTML to prevent this from happening: ' + '<meta http-equiv="X-UA-Compatible" content="IE=edge" />') : void 0; - if (toCompressed) privKey = privKey + '01'; + var expectedFeatures = [ + // shims + Array.isArray, Array.prototype.every, Array.prototype.forEach, Array.prototype.indexOf, Array.prototype.map, Date.now, Function.prototype.bind, Object.keys, String.prototype.trim]; - return bs58check.encode(Buffer.from(wif + privKey, 'hex')); + for (var i = 0; i < expectedFeatures.length; i++) { + if (!expectedFeatures[i]) { + process.env.NODE_ENV !== 'production' ? warning(false, 'One or more ES5 shims expected by React are not available: ' + 'https://fb.me/react-warning-polyfills') : void 0; + break; + } + } + } } -/* - * Returns private key's public Key - * @param {String} privKey (private key) - * @param {boolean} toCompressed (Convert to public key compressed key or nah) - * @return {Sting} Public Key (default: uncompressed) - */ -function privKeyToPubKey(privKey, toCompressed) { - toCompressed = toCompressed || false; +if (process.env.NODE_ENV !== 'production') { + var ReactInstrumentation = __webpack_require__(19); + var ReactDOMUnknownPropertyHook = __webpack_require__(312); + var ReactDOMNullInputValuePropHook = __webpack_require__(313); + var ReactDOMInvalidARIAHook = __webpack_require__(314); - const pkBuffer = Buffer.from(privKey, 'hex'); - var publicKey = secp256k1.publicKeyCreate(pkBuffer, toCompressed); - return publicKey.toString('hex'); + ReactInstrumentation.debugTool.addHook(ReactDOMUnknownPropertyHook); + ReactInstrumentation.debugTool.addHook(ReactDOMNullInputValuePropHook); + ReactInstrumentation.debugTool.addHook(ReactDOMInvalidARIAHook); } -/* - * Given a WIF format pk, convert it back to the original pk - * @param {String} privKey (private key) - * @return {Sting} Public Key (uncompressed) +module.exports = ReactDOM; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 231 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * */ -function WIFToPrivKey(wifPk) { - var og = bs58check.decode(wifPk, 'hex').toString('hex'); - og = og.substr(2, og.length); // remove WIF format ('80') - // remove the '01' at the end to 'compress it' during WIF conversion - if (og.length > 64) { - og = og.substr(0, 64); + + +var ARIADOMPropertyConfig = __webpack_require__(232); +var BeforeInputEventPlugin = __webpack_require__(233); +var ChangeEventPlugin = __webpack_require__(237); +var DefaultEventPluginOrder = __webpack_require__(245); +var EnterLeaveEventPlugin = __webpack_require__(246); +var HTMLDOMPropertyConfig = __webpack_require__(247); +var ReactComponentBrowserEnvironment = __webpack_require__(248); +var ReactDOMComponent = __webpack_require__(254); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMEmptyComponent = __webpack_require__(280); +var ReactDOMTreeTraversal = __webpack_require__(281); +var ReactDOMTextComponent = __webpack_require__(282); +var ReactDefaultBatchingStrategy = __webpack_require__(283); +var ReactEventListener = __webpack_require__(284); +var ReactInjection = __webpack_require__(286); +var ReactReconcileTransaction = __webpack_require__(287); +var SVGDOMPropertyConfig = __webpack_require__(293); +var SelectEventPlugin = __webpack_require__(294); +var SimpleEventPlugin = __webpack_require__(295); + +var alreadyInjected = false; + +function inject() { + if (alreadyInjected) { + // TODO: This is currently true because these injections are shared between + // the client and the server package. They should be built independently + // and not share any injection state. Then this problem will be solved. + return; } + alreadyInjected = true; - return og; -} + ReactInjection.EventEmitter.injectReactEventListener(ReactEventListener); -/* - * Converts public key to zencash address - * @param {String} pubKey (public key) - * @param {String} pubKeyHash (public key hash (optional, else use defaul)) - * @return {Sting} zencash address - */ -function pubKeyToAddr(pubKey, pubKeyHash) { - pubKeyHash = pubKeyHash || zconfig.mainnet.pubKeyHash; + /** + * Inject modules for resolving DOM hierarchy and plugin ordering. + */ + ReactInjection.EventPluginHub.injectEventPluginOrder(DefaultEventPluginOrder); + ReactInjection.EventPluginUtils.injectComponentTree(ReactDOMComponentTree); + ReactInjection.EventPluginUtils.injectTreeTraversal(ReactDOMTreeTraversal); - const hash160 = zcrypto.hash160(Buffer.from(pubKey, 'hex')); - return bs58check.encode(Buffer.from(pubKeyHash + hash160, 'hex')).toString('hex'); + /** + * Some important event plugins included by default (without having to require + * them). + */ + ReactInjection.EventPluginHub.injectEventPluginsByName({ + SimpleEventPlugin: SimpleEventPlugin, + EnterLeaveEventPlugin: EnterLeaveEventPlugin, + ChangeEventPlugin: ChangeEventPlugin, + SelectEventPlugin: SelectEventPlugin, + BeforeInputEventPlugin: BeforeInputEventPlugin + }); + + ReactInjection.HostComponent.injectGenericComponentClass(ReactDOMComponent); + + ReactInjection.HostComponent.injectTextComponentClass(ReactDOMTextComponent); + + ReactInjection.DOMProperty.injectDOMPropertyConfig(ARIADOMPropertyConfig); + ReactInjection.DOMProperty.injectDOMPropertyConfig(HTMLDOMPropertyConfig); + ReactInjection.DOMProperty.injectDOMPropertyConfig(SVGDOMPropertyConfig); + + ReactInjection.EmptyComponent.injectEmptyComponentFactory(function (instantiate) { + return new ReactDOMEmptyComponent(instantiate); + }); + + ReactInjection.Updates.injectReconcileTransaction(ReactReconcileTransaction); + ReactInjection.Updates.injectBatchingStrategy(ReactDefaultBatchingStrategy); + + ReactInjection.Component.injectEnvironment(ReactComponentBrowserEnvironment); } module.exports = { - mkPrivKey: mkPrivKey, - privKeyToWIF: privKeyToWIF, - privKeyToPubKey: privKeyToPubKey, - pubKeyToAddr: pubKeyToAddr, - WIFToPrivKey: WIFToPrivKey + inject: inject }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) /***/ }), -/* 260 */ +/* 232 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(Buffer) { -var inherits = __webpack_require__(11) -var HashBase = __webpack_require__(426) +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -function RIPEMD160 () { - HashBase.call(this, 64) - // state - this._a = 0x67452301 - this._b = 0xefcdab89 - this._c = 0x98badcfe - this._d = 0x10325476 - this._e = 0xc3d2e1f0 -} -inherits(RIPEMD160, HashBase) +var ARIADOMPropertyConfig = { + Properties: { + // Global States and Properties + 'aria-current': 0, // state + 'aria-details': 0, + 'aria-disabled': 0, // state + 'aria-hidden': 0, // state + 'aria-invalid': 0, // state + 'aria-keyshortcuts': 0, + 'aria-label': 0, + 'aria-roledescription': 0, + // Widget Attributes + 'aria-autocomplete': 0, + 'aria-checked': 0, + 'aria-expanded': 0, + 'aria-haspopup': 0, + 'aria-level': 0, + 'aria-modal': 0, + 'aria-multiline': 0, + 'aria-multiselectable': 0, + 'aria-orientation': 0, + 'aria-placeholder': 0, + 'aria-pressed': 0, + 'aria-readonly': 0, + 'aria-required': 0, + 'aria-selected': 0, + 'aria-sort': 0, + 'aria-valuemax': 0, + 'aria-valuemin': 0, + 'aria-valuenow': 0, + 'aria-valuetext': 0, + // Live Region Attributes + 'aria-atomic': 0, + 'aria-busy': 0, + 'aria-live': 0, + 'aria-relevant': 0, + // Drag-and-Drop Attributes + 'aria-dropeffect': 0, + 'aria-grabbed': 0, + // Relationship Attributes + 'aria-activedescendant': 0, + 'aria-colcount': 0, + 'aria-colindex': 0, + 'aria-colspan': 0, + 'aria-controls': 0, + 'aria-describedby': 0, + 'aria-errormessage': 0, + 'aria-flowto': 0, + 'aria-labelledby': 0, + 'aria-owns': 0, + 'aria-posinset': 0, + 'aria-rowcount': 0, + 'aria-rowindex': 0, + 'aria-rowspan': 0, + 'aria-setsize': 0 + }, + DOMAttributeNames: {}, + DOMPropertyNames: {} +}; -RIPEMD160.prototype._update = function () { - var m = new Array(16) - for (var i = 0; i < 16; ++i) m[i] = this._block.readInt32LE(i * 4) +module.exports = ARIADOMPropertyConfig; - var al = this._a - var bl = this._b - var cl = this._c - var dl = this._d - var el = this._e +/***/ }), +/* 233 */ +/***/ (function(module, exports, __webpack_require__) { - // Mj = 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 - // K = 0x00000000 - // Sj = 11, 14, 15, 12, 5, 8, 7, 9, 11, 13, 14, 15, 6, 7, 9, 8 - al = fn1(al, bl, cl, dl, el, m[0], 0x00000000, 11); cl = rotl(cl, 10) - el = fn1(el, al, bl, cl, dl, m[1], 0x00000000, 14); bl = rotl(bl, 10) - dl = fn1(dl, el, al, bl, cl, m[2], 0x00000000, 15); al = rotl(al, 10) - cl = fn1(cl, dl, el, al, bl, m[3], 0x00000000, 12); el = rotl(el, 10) - bl = fn1(bl, cl, dl, el, al, m[4], 0x00000000, 5); dl = rotl(dl, 10) - al = fn1(al, bl, cl, dl, el, m[5], 0x00000000, 8); cl = rotl(cl, 10) - el = fn1(el, al, bl, cl, dl, m[6], 0x00000000, 7); bl = rotl(bl, 10) - dl = fn1(dl, el, al, bl, cl, m[7], 0x00000000, 9); al = rotl(al, 10) - cl = fn1(cl, dl, el, al, bl, m[8], 0x00000000, 11); el = rotl(el, 10) - bl = fn1(bl, cl, dl, el, al, m[9], 0x00000000, 13); dl = rotl(dl, 10) - al = fn1(al, bl, cl, dl, el, m[10], 0x00000000, 14); cl = rotl(cl, 10) - el = fn1(el, al, bl, cl, dl, m[11], 0x00000000, 15); bl = rotl(bl, 10) - dl = fn1(dl, el, al, bl, cl, m[12], 0x00000000, 6); al = rotl(al, 10) - cl = fn1(cl, dl, el, al, bl, m[13], 0x00000000, 7); el = rotl(el, 10) - bl = fn1(bl, cl, dl, el, al, m[14], 0x00000000, 9); dl = rotl(dl, 10) - al = fn1(al, bl, cl, dl, el, m[15], 0x00000000, 8); cl = rotl(cl, 10) +"use strict"; +/** + * Copyright 2013-present Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // Mj = 7, 4, 13, 1, 10, 6, 15, 3, 12, 0, 9, 5, 2, 14, 11, 8 - // K = 0x5a827999 - // Sj = 7, 6, 8, 13, 11, 9, 7, 15, 7, 12, 15, 9, 11, 7, 13, 12 - el = fn2(el, al, bl, cl, dl, m[7], 0x5a827999, 7); bl = rotl(bl, 10) - dl = fn2(dl, el, al, bl, cl, m[4], 0x5a827999, 6); al = rotl(al, 10) - cl = fn2(cl, dl, el, al, bl, m[13], 0x5a827999, 8); el = rotl(el, 10) - bl = fn2(bl, cl, dl, el, al, m[1], 0x5a827999, 13); dl = rotl(dl, 10) - al = fn2(al, bl, cl, dl, el, m[10], 0x5a827999, 11); cl = rotl(cl, 10) - el = fn2(el, al, bl, cl, dl, m[6], 0x5a827999, 9); bl = rotl(bl, 10) - dl = fn2(dl, el, al, bl, cl, m[15], 0x5a827999, 7); al = rotl(al, 10) - cl = fn2(cl, dl, el, al, bl, m[3], 0x5a827999, 15); el = rotl(el, 10) - bl = fn2(bl, cl, dl, el, al, m[12], 0x5a827999, 7); dl = rotl(dl, 10) - al = fn2(al, bl, cl, dl, el, m[0], 0x5a827999, 12); cl = rotl(cl, 10) - el = fn2(el, al, bl, cl, dl, m[9], 0x5a827999, 15); bl = rotl(bl, 10) - dl = fn2(dl, el, al, bl, cl, m[5], 0x5a827999, 9); al = rotl(al, 10) - cl = fn2(cl, dl, el, al, bl, m[2], 0x5a827999, 11); el = rotl(el, 10) - bl = fn2(bl, cl, dl, el, al, m[14], 0x5a827999, 7); dl = rotl(dl, 10) - al = fn2(al, bl, cl, dl, el, m[11], 0x5a827999, 13); cl = rotl(cl, 10) - el = fn2(el, al, bl, cl, dl, m[8], 0x5a827999, 12); bl = rotl(bl, 10) - - // Mj = 3, 10, 14, 4, 9, 15, 8, 1, 2, 7, 0, 6, 13, 11, 5, 12 - // K = 0x6ed9eba1 - // Sj = 11, 13, 6, 7, 14, 9, 13, 15, 14, 8, 13, 6, 5, 12, 7, 5 - dl = fn3(dl, el, al, bl, cl, m[3], 0x6ed9eba1, 11); al = rotl(al, 10) - cl = fn3(cl, dl, el, al, bl, m[10], 0x6ed9eba1, 13); el = rotl(el, 10) - bl = fn3(bl, cl, dl, el, al, m[14], 0x6ed9eba1, 6); dl = rotl(dl, 10) - al = fn3(al, bl, cl, dl, el, m[4], 0x6ed9eba1, 7); cl = rotl(cl, 10) - el = fn3(el, al, bl, cl, dl, m[9], 0x6ed9eba1, 14); bl = rotl(bl, 10) - dl = fn3(dl, el, al, bl, cl, m[15], 0x6ed9eba1, 9); al = rotl(al, 10) - cl = fn3(cl, dl, el, al, bl, m[8], 0x6ed9eba1, 13); el = rotl(el, 10) - bl = fn3(bl, cl, dl, el, al, m[1], 0x6ed9eba1, 15); dl = rotl(dl, 10) - al = fn3(al, bl, cl, dl, el, m[2], 0x6ed9eba1, 14); cl = rotl(cl, 10) - el = fn3(el, al, bl, cl, dl, m[7], 0x6ed9eba1, 8); bl = rotl(bl, 10) - dl = fn3(dl, el, al, bl, cl, m[0], 0x6ed9eba1, 13); al = rotl(al, 10) - cl = fn3(cl, dl, el, al, bl, m[6], 0x6ed9eba1, 6); el = rotl(el, 10) - bl = fn3(bl, cl, dl, el, al, m[13], 0x6ed9eba1, 5); dl = rotl(dl, 10) - al = fn3(al, bl, cl, dl, el, m[11], 0x6ed9eba1, 12); cl = rotl(cl, 10) - el = fn3(el, al, bl, cl, dl, m[5], 0x6ed9eba1, 7); bl = rotl(bl, 10) - dl = fn3(dl, el, al, bl, cl, m[12], 0x6ed9eba1, 5); al = rotl(al, 10) - - // Mj = 1, 9, 11, 10, 0, 8, 12, 4, 13, 3, 7, 15, 14, 5, 6, 2 - // K = 0x8f1bbcdc - // Sj = 11, 12, 14, 15, 14, 15, 9, 8, 9, 14, 5, 6, 8, 6, 5, 12 - cl = fn4(cl, dl, el, al, bl, m[1], 0x8f1bbcdc, 11); el = rotl(el, 10) - bl = fn4(bl, cl, dl, el, al, m[9], 0x8f1bbcdc, 12); dl = rotl(dl, 10) - al = fn4(al, bl, cl, dl, el, m[11], 0x8f1bbcdc, 14); cl = rotl(cl, 10) - el = fn4(el, al, bl, cl, dl, m[10], 0x8f1bbcdc, 15); bl = rotl(bl, 10) - dl = fn4(dl, el, al, bl, cl, m[0], 0x8f1bbcdc, 14); al = rotl(al, 10) - cl = fn4(cl, dl, el, al, bl, m[8], 0x8f1bbcdc, 15); el = rotl(el, 10) - bl = fn4(bl, cl, dl, el, al, m[12], 0x8f1bbcdc, 9); dl = rotl(dl, 10) - al = fn4(al, bl, cl, dl, el, m[4], 0x8f1bbcdc, 8); cl = rotl(cl, 10) - el = fn4(el, al, bl, cl, dl, m[13], 0x8f1bbcdc, 9); bl = rotl(bl, 10) - dl = fn4(dl, el, al, bl, cl, m[3], 0x8f1bbcdc, 14); al = rotl(al, 10) - cl = fn4(cl, dl, el, al, bl, m[7], 0x8f1bbcdc, 5); el = rotl(el, 10) - bl = fn4(bl, cl, dl, el, al, m[15], 0x8f1bbcdc, 6); dl = rotl(dl, 10) - al = fn4(al, bl, cl, dl, el, m[14], 0x8f1bbcdc, 8); cl = rotl(cl, 10) - el = fn4(el, al, bl, cl, dl, m[5], 0x8f1bbcdc, 6); bl = rotl(bl, 10) - dl = fn4(dl, el, al, bl, cl, m[6], 0x8f1bbcdc, 5); al = rotl(al, 10) - cl = fn4(cl, dl, el, al, bl, m[2], 0x8f1bbcdc, 12); el = rotl(el, 10) - // Mj = 4, 0, 5, 9, 7, 12, 2, 10, 14, 1, 3, 8, 11, 6, 15, 13 - // K = 0xa953fd4e - // Sj = 9, 15, 5, 11, 6, 8, 13, 12, 5, 12, 13, 14, 11, 8, 5, 6 - bl = fn5(bl, cl, dl, el, al, m[4], 0xa953fd4e, 9); dl = rotl(dl, 10) - al = fn5(al, bl, cl, dl, el, m[0], 0xa953fd4e, 15); cl = rotl(cl, 10) - el = fn5(el, al, bl, cl, dl, m[5], 0xa953fd4e, 5); bl = rotl(bl, 10) - dl = fn5(dl, el, al, bl, cl, m[9], 0xa953fd4e, 11); al = rotl(al, 10) - cl = fn5(cl, dl, el, al, bl, m[7], 0xa953fd4e, 6); el = rotl(el, 10) - bl = fn5(bl, cl, dl, el, al, m[12], 0xa953fd4e, 8); dl = rotl(dl, 10) - al = fn5(al, bl, cl, dl, el, m[2], 0xa953fd4e, 13); cl = rotl(cl, 10) - el = fn5(el, al, bl, cl, dl, m[10], 0xa953fd4e, 12); bl = rotl(bl, 10) - dl = fn5(dl, el, al, bl, cl, m[14], 0xa953fd4e, 5); al = rotl(al, 10) - cl = fn5(cl, dl, el, al, bl, m[1], 0xa953fd4e, 12); el = rotl(el, 10) - bl = fn5(bl, cl, dl, el, al, m[3], 0xa953fd4e, 13); dl = rotl(dl, 10) - al = fn5(al, bl, cl, dl, el, m[8], 0xa953fd4e, 14); cl = rotl(cl, 10) - el = fn5(el, al, bl, cl, dl, m[11], 0xa953fd4e, 11); bl = rotl(bl, 10) - dl = fn5(dl, el, al, bl, cl, m[6], 0xa953fd4e, 8); al = rotl(al, 10) - cl = fn5(cl, dl, el, al, bl, m[15], 0xa953fd4e, 5); el = rotl(el, 10) - bl = fn5(bl, cl, dl, el, al, m[13], 0xa953fd4e, 6); dl = rotl(dl, 10) - var ar = this._a - var br = this._b - var cr = this._c - var dr = this._d - var er = this._e +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var FallbackCompositionState = __webpack_require__(234); +var SyntheticCompositionEvent = __webpack_require__(235); +var SyntheticInputEvent = __webpack_require__(236); - // M'j = 5, 14, 7, 0, 9, 2, 11, 4, 13, 6, 15, 8, 1, 10, 3, 12 - // K' = 0x50a28be6 - // S'j = 8, 9, 9, 11, 13, 15, 15, 5, 7, 7, 8, 11, 14, 14, 12, 6 - ar = fn5(ar, br, cr, dr, er, m[5], 0x50a28be6, 8); cr = rotl(cr, 10) - er = fn5(er, ar, br, cr, dr, m[14], 0x50a28be6, 9); br = rotl(br, 10) - dr = fn5(dr, er, ar, br, cr, m[7], 0x50a28be6, 9); ar = rotl(ar, 10) - cr = fn5(cr, dr, er, ar, br, m[0], 0x50a28be6, 11); er = rotl(er, 10) - br = fn5(br, cr, dr, er, ar, m[9], 0x50a28be6, 13); dr = rotl(dr, 10) - ar = fn5(ar, br, cr, dr, er, m[2], 0x50a28be6, 15); cr = rotl(cr, 10) - er = fn5(er, ar, br, cr, dr, m[11], 0x50a28be6, 15); br = rotl(br, 10) - dr = fn5(dr, er, ar, br, cr, m[4], 0x50a28be6, 5); ar = rotl(ar, 10) - cr = fn5(cr, dr, er, ar, br, m[13], 0x50a28be6, 7); er = rotl(er, 10) - br = fn5(br, cr, dr, er, ar, m[6], 0x50a28be6, 7); dr = rotl(dr, 10) - ar = fn5(ar, br, cr, dr, er, m[15], 0x50a28be6, 8); cr = rotl(cr, 10) - er = fn5(er, ar, br, cr, dr, m[8], 0x50a28be6, 11); br = rotl(br, 10) - dr = fn5(dr, er, ar, br, cr, m[1], 0x50a28be6, 14); ar = rotl(ar, 10) - cr = fn5(cr, dr, er, ar, br, m[10], 0x50a28be6, 14); er = rotl(er, 10) - br = fn5(br, cr, dr, er, ar, m[3], 0x50a28be6, 12); dr = rotl(dr, 10) - ar = fn5(ar, br, cr, dr, er, m[12], 0x50a28be6, 6); cr = rotl(cr, 10) +var END_KEYCODES = [9, 13, 27, 32]; // Tab, Return, Esc, Space +var START_KEYCODE = 229; - // M'j = 6, 11, 3, 7, 0, 13, 5, 10, 14, 15, 8, 12, 4, 9, 1, 2 - // K' = 0x5c4dd124 - // S'j = 9, 13, 15, 7, 12, 8, 9, 11, 7, 7, 12, 7, 6, 15, 13, 11 - er = fn4(er, ar, br, cr, dr, m[6], 0x5c4dd124, 9); br = rotl(br, 10) - dr = fn4(dr, er, ar, br, cr, m[11], 0x5c4dd124, 13); ar = rotl(ar, 10) - cr = fn4(cr, dr, er, ar, br, m[3], 0x5c4dd124, 15); er = rotl(er, 10) - br = fn4(br, cr, dr, er, ar, m[7], 0x5c4dd124, 7); dr = rotl(dr, 10) - ar = fn4(ar, br, cr, dr, er, m[0], 0x5c4dd124, 12); cr = rotl(cr, 10) - er = fn4(er, ar, br, cr, dr, m[13], 0x5c4dd124, 8); br = rotl(br, 10) - dr = fn4(dr, er, ar, br, cr, m[5], 0x5c4dd124, 9); ar = rotl(ar, 10) - cr = fn4(cr, dr, er, ar, br, m[10], 0x5c4dd124, 11); er = rotl(er, 10) - br = fn4(br, cr, dr, er, ar, m[14], 0x5c4dd124, 7); dr = rotl(dr, 10) - ar = fn4(ar, br, cr, dr, er, m[15], 0x5c4dd124, 7); cr = rotl(cr, 10) - er = fn4(er, ar, br, cr, dr, m[8], 0x5c4dd124, 12); br = rotl(br, 10) - dr = fn4(dr, er, ar, br, cr, m[12], 0x5c4dd124, 7); ar = rotl(ar, 10) - cr = fn4(cr, dr, er, ar, br, m[4], 0x5c4dd124, 6); er = rotl(er, 10) - br = fn4(br, cr, dr, er, ar, m[9], 0x5c4dd124, 15); dr = rotl(dr, 10) - ar = fn4(ar, br, cr, dr, er, m[1], 0x5c4dd124, 13); cr = rotl(cr, 10) - er = fn4(er, ar, br, cr, dr, m[2], 0x5c4dd124, 11); br = rotl(br, 10) +var canUseCompositionEvent = ExecutionEnvironment.canUseDOM && 'CompositionEvent' in window; - // M'j = 15, 5, 1, 3, 7, 14, 6, 9, 11, 8, 12, 2, 10, 0, 4, 13 - // K' = 0x6d703ef3 - // S'j = 9, 7, 15, 11, 8, 6, 6, 14, 12, 13, 5, 14, 13, 13, 7, 5 - dr = fn3(dr, er, ar, br, cr, m[15], 0x6d703ef3, 9); ar = rotl(ar, 10) - cr = fn3(cr, dr, er, ar, br, m[5], 0x6d703ef3, 7); er = rotl(er, 10) - br = fn3(br, cr, dr, er, ar, m[1], 0x6d703ef3, 15); dr = rotl(dr, 10) - ar = fn3(ar, br, cr, dr, er, m[3], 0x6d703ef3, 11); cr = rotl(cr, 10) - er = fn3(er, ar, br, cr, dr, m[7], 0x6d703ef3, 8); br = rotl(br, 10) - dr = fn3(dr, er, ar, br, cr, m[14], 0x6d703ef3, 6); ar = rotl(ar, 10) - cr = fn3(cr, dr, er, ar, br, m[6], 0x6d703ef3, 6); er = rotl(er, 10) - br = fn3(br, cr, dr, er, ar, m[9], 0x6d703ef3, 14); dr = rotl(dr, 10) - ar = fn3(ar, br, cr, dr, er, m[11], 0x6d703ef3, 12); cr = rotl(cr, 10) - er = fn3(er, ar, br, cr, dr, m[8], 0x6d703ef3, 13); br = rotl(br, 10) - dr = fn3(dr, er, ar, br, cr, m[12], 0x6d703ef3, 5); ar = rotl(ar, 10) - cr = fn3(cr, dr, er, ar, br, m[2], 0x6d703ef3, 14); er = rotl(er, 10) - br = fn3(br, cr, dr, er, ar, m[10], 0x6d703ef3, 13); dr = rotl(dr, 10) - ar = fn3(ar, br, cr, dr, er, m[0], 0x6d703ef3, 13); cr = rotl(cr, 10) - er = fn3(er, ar, br, cr, dr, m[4], 0x6d703ef3, 7); br = rotl(br, 10) - dr = fn3(dr, er, ar, br, cr, m[13], 0x6d703ef3, 5); ar = rotl(ar, 10) +var documentMode = null; +if (ExecutionEnvironment.canUseDOM && 'documentMode' in document) { + documentMode = document.documentMode; +} - // M'j = 8, 6, 4, 1, 3, 11, 15, 0, 5, 12, 2, 13, 9, 7, 10, 14 - // K' = 0x7a6d76e9 - // S'j = 15, 5, 8, 11, 14, 14, 6, 14, 6, 9, 12, 9, 12, 5, 15, 8 - cr = fn2(cr, dr, er, ar, br, m[8], 0x7a6d76e9, 15); er = rotl(er, 10) - br = fn2(br, cr, dr, er, ar, m[6], 0x7a6d76e9, 5); dr = rotl(dr, 10) - ar = fn2(ar, br, cr, dr, er, m[4], 0x7a6d76e9, 8); cr = rotl(cr, 10) - er = fn2(er, ar, br, cr, dr, m[1], 0x7a6d76e9, 11); br = rotl(br, 10) - dr = fn2(dr, er, ar, br, cr, m[3], 0x7a6d76e9, 14); ar = rotl(ar, 10) - cr = fn2(cr, dr, er, ar, br, m[11], 0x7a6d76e9, 14); er = rotl(er, 10) - br = fn2(br, cr, dr, er, ar, m[15], 0x7a6d76e9, 6); dr = rotl(dr, 10) - ar = fn2(ar, br, cr, dr, er, m[0], 0x7a6d76e9, 14); cr = rotl(cr, 10) - er = fn2(er, ar, br, cr, dr, m[5], 0x7a6d76e9, 6); br = rotl(br, 10) - dr = fn2(dr, er, ar, br, cr, m[12], 0x7a6d76e9, 9); ar = rotl(ar, 10) - cr = fn2(cr, dr, er, ar, br, m[2], 0x7a6d76e9, 12); er = rotl(er, 10) - br = fn2(br, cr, dr, er, ar, m[13], 0x7a6d76e9, 9); dr = rotl(dr, 10) - ar = fn2(ar, br, cr, dr, er, m[9], 0x7a6d76e9, 12); cr = rotl(cr, 10) - er = fn2(er, ar, br, cr, dr, m[7], 0x7a6d76e9, 5); br = rotl(br, 10) - dr = fn2(dr, er, ar, br, cr, m[10], 0x7a6d76e9, 15); ar = rotl(ar, 10) - cr = fn2(cr, dr, er, ar, br, m[14], 0x7a6d76e9, 8); er = rotl(er, 10) +// Webkit offers a very useful `textInput` event that can be used to +// directly represent `beforeInput`. The IE `textinput` event is not as +// useful, so we don't use it. +var canUseTextInputEvent = ExecutionEnvironment.canUseDOM && 'TextEvent' in window && !documentMode && !isPresto(); - // M'j = 12, 15, 10, 4, 1, 5, 8, 7, 6, 2, 13, 14, 0, 3, 9, 11 - // K' = 0x00000000 - // S'j = 8, 5, 12, 9, 12, 5, 14, 6, 8, 13, 6, 5, 15, 13, 11, 11 - br = fn1(br, cr, dr, er, ar, m[12], 0x00000000, 8); dr = rotl(dr, 10) - ar = fn1(ar, br, cr, dr, er, m[15], 0x00000000, 5); cr = rotl(cr, 10) - er = fn1(er, ar, br, cr, dr, m[10], 0x00000000, 12); br = rotl(br, 10) - dr = fn1(dr, er, ar, br, cr, m[4], 0x00000000, 9); ar = rotl(ar, 10) - cr = fn1(cr, dr, er, ar, br, m[1], 0x00000000, 12); er = rotl(er, 10) - br = fn1(br, cr, dr, er, ar, m[5], 0x00000000, 5); dr = rotl(dr, 10) - ar = fn1(ar, br, cr, dr, er, m[8], 0x00000000, 14); cr = rotl(cr, 10) - er = fn1(er, ar, br, cr, dr, m[7], 0x00000000, 6); br = rotl(br, 10) - dr = fn1(dr, er, ar, br, cr, m[6], 0x00000000, 8); ar = rotl(ar, 10) - cr = fn1(cr, dr, er, ar, br, m[2], 0x00000000, 13); er = rotl(er, 10) - br = fn1(br, cr, dr, er, ar, m[13], 0x00000000, 6); dr = rotl(dr, 10) - ar = fn1(ar, br, cr, dr, er, m[14], 0x00000000, 5); cr = rotl(cr, 10) - er = fn1(er, ar, br, cr, dr, m[0], 0x00000000, 15); br = rotl(br, 10) - dr = fn1(dr, er, ar, br, cr, m[3], 0x00000000, 13); ar = rotl(ar, 10) - cr = fn1(cr, dr, er, ar, br, m[9], 0x00000000, 11); er = rotl(er, 10) - br = fn1(br, cr, dr, er, ar, m[11], 0x00000000, 11); dr = rotl(dr, 10) +// In IE9+, we have access to composition events, but the data supplied +// by the native compositionend event may be incorrect. Japanese ideographic +// spaces, for instance (\u3000) are not recorded correctly. +var useFallbackCompositionData = ExecutionEnvironment.canUseDOM && (!canUseCompositionEvent || documentMode && documentMode > 8 && documentMode <= 11); - // change state - var t = (this._b + cl + dr) | 0 - this._b = (this._c + dl + er) | 0 - this._c = (this._d + el + ar) | 0 - this._d = (this._e + al + br) | 0 - this._e = (this._a + bl + cr) | 0 - this._a = t +/** + * Opera <= 12 includes TextEvent in window, but does not fire + * text input events. Rely on keypress instead. + */ +function isPresto() { + var opera = window.opera; + return typeof opera === 'object' && typeof opera.version === 'function' && parseInt(opera.version(), 10) <= 12; } -RIPEMD160.prototype._digest = function () { - // create padding and handle blocks - this._block[this._blockOffset++] = 0x80 - if (this._blockOffset > 56) { - this._block.fill(0, this._blockOffset, 64) - this._update() - this._blockOffset = 0 - } - - this._block.fill(0, this._blockOffset, 56) - this._block.writeUInt32LE(this._length[0], 56) - this._block.writeUInt32LE(this._length[1], 60) - this._update() +var SPACEBAR_CODE = 32; +var SPACEBAR_CHAR = String.fromCharCode(SPACEBAR_CODE); - // produce result - var buffer = new Buffer(20) - buffer.writeInt32LE(this._a, 0) - buffer.writeInt32LE(this._b, 4) - buffer.writeInt32LE(this._c, 8) - buffer.writeInt32LE(this._d, 12) - buffer.writeInt32LE(this._e, 16) - return buffer -} +// Events and their corresponding property names. +var eventTypes = { + beforeInput: { + phasedRegistrationNames: { + bubbled: 'onBeforeInput', + captured: 'onBeforeInputCapture' + }, + dependencies: ['topCompositionEnd', 'topKeyPress', 'topTextInput', 'topPaste'] + }, + compositionEnd: { + phasedRegistrationNames: { + bubbled: 'onCompositionEnd', + captured: 'onCompositionEndCapture' + }, + dependencies: ['topBlur', 'topCompositionEnd', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + }, + compositionStart: { + phasedRegistrationNames: { + bubbled: 'onCompositionStart', + captured: 'onCompositionStartCapture' + }, + dependencies: ['topBlur', 'topCompositionStart', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + }, + compositionUpdate: { + phasedRegistrationNames: { + bubbled: 'onCompositionUpdate', + captured: 'onCompositionUpdateCapture' + }, + dependencies: ['topBlur', 'topCompositionUpdate', 'topKeyDown', 'topKeyPress', 'topKeyUp', 'topMouseDown'] + } +}; -function rotl (x, n) { - return (x << n) | (x >>> (32 - n)) -} +// Track whether we've ever handled a keypress on the space key. +var hasSpaceKeypress = false; -function fn1 (a, b, c, d, e, m, k, s) { - return (rotl((a + (b ^ c ^ d) + m + k) | 0, s) + e) | 0 +/** + * Return whether a native keypress event is assumed to be a command. + * This is required because Firefox fires `keypress` events for key commands + * (cut, copy, select-all, etc.) even though no character is inserted. + */ +function isKeypressCommand(nativeEvent) { + return (nativeEvent.ctrlKey || nativeEvent.altKey || nativeEvent.metaKey) && + // ctrlKey && altKey is equivalent to AltGr, and is not a command. + !(nativeEvent.ctrlKey && nativeEvent.altKey); } -function fn2 (a, b, c, d, e, m, k, s) { - return (rotl((a + ((b & c) | ((~b) & d)) + m + k) | 0, s) + e) | 0 +/** + * Translate native top level events into event types. + * + * @param {string} topLevelType + * @return {object} + */ +function getCompositionEventType(topLevelType) { + switch (topLevelType) { + case 'topCompositionStart': + return eventTypes.compositionStart; + case 'topCompositionEnd': + return eventTypes.compositionEnd; + case 'topCompositionUpdate': + return eventTypes.compositionUpdate; + } } -function fn3 (a, b, c, d, e, m, k, s) { - return (rotl((a + ((b | (~c)) ^ d) + m + k) | 0, s) + e) | 0 +/** + * Does our fallback best-guess model think this event signifies that + * composition has begun? + * + * @param {string} topLevelType + * @param {object} nativeEvent + * @return {boolean} + */ +function isFallbackCompositionStart(topLevelType, nativeEvent) { + return topLevelType === 'topKeyDown' && nativeEvent.keyCode === START_KEYCODE; } -function fn4 (a, b, c, d, e, m, k, s) { - return (rotl((a + ((b & d) | (c & (~d))) + m + k) | 0, s) + e) | 0 +/** + * Does our fallback mode think that this event is the end of composition? + * + * @param {string} topLevelType + * @param {object} nativeEvent + * @return {boolean} + */ +function isFallbackCompositionEnd(topLevelType, nativeEvent) { + switch (topLevelType) { + case 'topKeyUp': + // Command keys insert or clear IME input. + return END_KEYCODES.indexOf(nativeEvent.keyCode) !== -1; + case 'topKeyDown': + // Expect IME keyCode on each keydown. If we get any other + // code we must have exited earlier. + return nativeEvent.keyCode !== START_KEYCODE; + case 'topKeyPress': + case 'topMouseDown': + case 'topBlur': + // Events are not possible without cancelling IME. + return true; + default: + return false; + } } -function fn5 (a, b, c, d, e, m, k, s) { - return (rotl((a + (b ^ (c | (~d))) + m + k) | 0, s) + e) | 0 +/** + * Google Input Tools provides composition data via a CustomEvent, + * with the `data` property populated in the `detail` object. If this + * is available on the event object, use it. If not, this is a plain + * composition event and we have nothing special to extract. + * + * @param {object} nativeEvent + * @return {?string} + */ +function getDataFromCustomEvent(nativeEvent) { + var detail = nativeEvent.detail; + if (typeof detail === 'object' && 'data' in detail) { + return detail.data; + } + return null; } -module.exports = RIPEMD160 - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) - -/***/ }), -/* 261 */ -/***/ (function(module, exports, __webpack_require__) { - -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. - -module.exports = Stream; - -var EE = __webpack_require__(244).EventEmitter; -var inherits = __webpack_require__(11); - -inherits(Stream, EE); -Stream.Readable = __webpack_require__(262); -Stream.Writable = __webpack_require__(432); -Stream.Duplex = __webpack_require__(433); -Stream.Transform = __webpack_require__(434); -Stream.PassThrough = __webpack_require__(435); - -// Backwards-compat with node 0.4.x -Stream.Stream = Stream; - - +// Track the current IME composition fallback object, if any. +var currentComposition = null; -// old-style streams. Note that the pipe method (the only relevant -// part of this class) is overridden in the Readable class. +/** + * @return {?object} A SyntheticCompositionEvent. + */ +function extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var eventType; + var fallbackData; -function Stream() { - EE.call(this); -} + if (canUseCompositionEvent) { + eventType = getCompositionEventType(topLevelType); + } else if (!currentComposition) { + if (isFallbackCompositionStart(topLevelType, nativeEvent)) { + eventType = eventTypes.compositionStart; + } + } else if (isFallbackCompositionEnd(topLevelType, nativeEvent)) { + eventType = eventTypes.compositionEnd; + } -Stream.prototype.pipe = function(dest, options) { - var source = this; + if (!eventType) { + return null; + } - function ondata(chunk) { - if (dest.writable) { - if (false === dest.write(chunk) && source.pause) { - source.pause(); + if (useFallbackCompositionData) { + // The current composition is stored statically and must not be + // overwritten while composition continues. + if (!currentComposition && eventType === eventTypes.compositionStart) { + currentComposition = FallbackCompositionState.getPooled(nativeEventTarget); + } else if (eventType === eventTypes.compositionEnd) { + if (currentComposition) { + fallbackData = currentComposition.getData(); } } } - source.on('data', ondata); + var event = SyntheticCompositionEvent.getPooled(eventType, targetInst, nativeEvent, nativeEventTarget); - function ondrain() { - if (source.readable && source.resume) { - source.resume(); + if (fallbackData) { + // Inject data generated from fallback path into the synthetic event. + // This matches the property of native CompositionEventInterface. + event.data = fallbackData; + } else { + var customData = getDataFromCustomEvent(nativeEvent); + if (customData !== null) { + event.data = customData; } } - dest.on('drain', ondrain); + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} - // If the 'end' option is not supplied, dest.end() will be called when - // source gets the 'end' or 'close' events. Only dest.end() once. - if (!dest._isStdio && (!options || options.end !== false)) { - source.on('end', onend); - source.on('close', onclose); - } +/** + * @param {string} topLevelType Record from `EventConstants`. + * @param {object} nativeEvent Native browser event. + * @return {?string} The string corresponding to this `beforeInput` event. + */ +function getNativeBeforeInputChars(topLevelType, nativeEvent) { + switch (topLevelType) { + case 'topCompositionEnd': + return getDataFromCustomEvent(nativeEvent); + case 'topKeyPress': + /** + * If native `textInput` events are available, our goal is to make + * use of them. However, there is a special case: the spacebar key. + * In Webkit, preventing default on a spacebar `textInput` event + * cancels character insertion, but it *also* causes the browser + * to fall back to its default spacebar behavior of scrolling the + * page. + * + * Tracking at: + * https://code.google.com/p/chromium/issues/detail?id=355103 + * + * To avoid this issue, use the keypress event as if no `textInput` + * event is available. + */ + var which = nativeEvent.which; + if (which !== SPACEBAR_CODE) { + return null; + } - var didOnEnd = false; - function onend() { - if (didOnEnd) return; - didOnEnd = true; + hasSpaceKeypress = true; + return SPACEBAR_CHAR; - dest.end(); - } + case 'topTextInput': + // Record the characters to be added to the DOM. + var chars = nativeEvent.data; + // If it's a spacebar character, assume that we have already handled + // it at the keypress level and bail immediately. Android Chrome + // doesn't give us keycodes, so we need to blacklist it. + if (chars === SPACEBAR_CHAR && hasSpaceKeypress) { + return null; + } - function onclose() { - if (didOnEnd) return; - didOnEnd = true; + return chars; - if (typeof dest.destroy === 'function') dest.destroy(); + default: + // For other native event types, do nothing. + return null; } +} - // don't leave dangling pipes when there are errors. - function onerror(er) { - cleanup(); - if (EE.listenerCount(this, 'error') === 0) { - throw er; // Unhandled stream error in pipe. +/** + * For browsers that do not provide the `textInput` event, extract the + * appropriate string to use for SyntheticInputEvent. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {object} nativeEvent Native browser event. + * @return {?string} The fallback string for this `beforeInput` event. + */ +function getFallbackBeforeInputChars(topLevelType, nativeEvent) { + // If we are currently composing (IME) and using a fallback to do so, + // try to extract the composed characters from the fallback object. + // If composition event is available, we extract a string only at + // compositionevent, otherwise extract it at fallback events. + if (currentComposition) { + if (topLevelType === 'topCompositionEnd' || !canUseCompositionEvent && isFallbackCompositionEnd(topLevelType, nativeEvent)) { + var chars = currentComposition.getData(); + FallbackCompositionState.release(currentComposition); + currentComposition = null; + return chars; } + return null; } - source.on('error', onerror); - dest.on('error', onerror); - - // remove all the event listeners that were added. - function cleanup() { - source.removeListener('data', ondata); - dest.removeListener('drain', ondrain); - - source.removeListener('end', onend); - source.removeListener('close', onclose); + switch (topLevelType) { + case 'topPaste': + // If a paste event occurs after a keypress, throw out the input + // chars. Paste events should not lead to BeforeInput events. + return null; + case 'topKeyPress': + /** + * As of v27, Firefox may fire keypress events even when no character + * will be inserted. A few possibilities: + * + * - `which` is `0`. Arrow keys, Esc key, etc. + * + * - `which` is the pressed key code, but no char is available. + * Ex: 'AltGr + d` in Polish. There is no modified character for + * this key combination and no character is inserted into the + * document, but FF fires the keypress for char code `100` anyway. + * No `input` event will occur. + * + * - `which` is the pressed key code, but a command combination is + * being used. Ex: `Cmd+C`. No character is inserted, and no + * `input` event will occur. + */ + if (nativeEvent.which && !isKeypressCommand(nativeEvent)) { + return String.fromCharCode(nativeEvent.which); + } + return null; + case 'topCompositionEnd': + return useFallbackCompositionData ? null : nativeEvent.data; + default: + return null; + } +} - source.removeListener('error', onerror); - dest.removeListener('error', onerror); +/** + * Extract a SyntheticInputEvent for `beforeInput`, based on either native + * `textInput` or fallback behavior. + * + * @return {?object} A SyntheticInputEvent. + */ +function extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var chars; - source.removeListener('end', cleanup); - source.removeListener('close', cleanup); + if (canUseTextInputEvent) { + chars = getNativeBeforeInputChars(topLevelType, nativeEvent); + } else { + chars = getFallbackBeforeInputChars(topLevelType, nativeEvent); + } - dest.removeListener('close', cleanup); + // If no characters are being inserted, no BeforeInput event should + // be fired. + if (!chars) { + return null; } - source.on('end', cleanup); - source.on('close', cleanup); + var event = SyntheticInputEvent.getPooled(eventTypes.beforeInput, targetInst, nativeEvent, nativeEventTarget); - dest.on('close', cleanup); + event.data = chars; + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} - dest.emit('pipe', source); +/** + * Create an `onBeforeInput` event to match + * http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105/#events-inputevents. + * + * This event plugin is based on the native `textInput` event + * available in Chrome, Safari, Opera, and IE. This event fires after + * `onKeyPress` and `onCompositionEnd`, but before `onInput`. + * + * `beforeInput` is spec'd but not implemented in any browsers, and + * the `input` event does not provide any useful information about what has + * actually been added, contrary to the spec. Thus, `textInput` is the best + * available event to identify the characters that have actually been inserted + * into the target node. + * + * This plugin is also responsible for emitting `composition` events, thus + * allowing us to share composition fallback code for both `beforeInput` and + * `composition` event types. + */ +var BeforeInputEventPlugin = { + eventTypes: eventTypes, - // Allow for unix-like usage: A.pipe(B).pipe(C) - return dest; + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + return [extractCompositionEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget), extractBeforeInputEvent(topLevelType, targetInst, nativeEvent, nativeEventTarget)]; + } }; +module.exports = BeforeInputEventPlugin; /***/ }), -/* 262 */ +/* 234 */ /***/ (function(module, exports, __webpack_require__) { -exports = module.exports = __webpack_require__(307); -exports.Stream = exports; -exports.Readable = exports; -exports.Writable = __webpack_require__(263); -exports.Duplex = __webpack_require__(112); -exports.Transform = __webpack_require__(311); -exports.PassThrough = __webpack_require__(431); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -/***/ }), -/* 263 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* WEBPACK VAR INJECTION */(function(process, setImmediate, global) {// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. +var _assign = __webpack_require__(8); -// A bit simpler than readable streams. -// Implement an async ._write(chunk, encoding, cb), and it'll handle all -// the drain event emission and buffering. +var PooledClass = __webpack_require__(32); +var getTextContentAccessor = __webpack_require__(129); +/** + * This helper class stores information about text content of a target node, + * allowing comparison of content before and after a given event. + * + * Identify the node where selection currently begins, then observe + * both its text content and its current position in the DOM. Since the + * browser may natively replace the target node during composition, we can + * use its position to find its replacement. + * + * @param {DOMEventTarget} root + */ +function FallbackCompositionState(root) { + this._root = root; + this._startText = this.getText(); + this._fallbackText = null; +} -/*<replacement>*/ +_assign(FallbackCompositionState.prototype, { + destructor: function () { + this._root = null; + this._startText = null; + this._fallbackText = null; + }, -var processNextTick = __webpack_require__(246); -/*</replacement>*/ + /** + * Get current text of input. + * + * @return {string} + */ + getText: function () { + if ('value' in this._root) { + return this._root.value; + } + return this._root[getTextContentAccessor()]; + }, -module.exports = Writable; + /** + * Determine the differing substring between the initially stored + * text content and the current content. + * + * @return {string} + */ + getData: function () { + if (this._fallbackText) { + return this._fallbackText; + } -/* <replacement> */ -function WriteReq(chunk, encoding, cb) { - this.chunk = chunk; - this.encoding = encoding; - this.callback = cb; - this.next = null; -} + var start; + var startValue = this._startText; + var startLength = startValue.length; + var end; + var endValue = this.getText(); + var endLength = endValue.length; -// It seems a linked list but it is not -// there will be only 2 of these for each stream -function CorkedRequest(state) { - var _this = this; + for (start = 0; start < startLength; start++) { + if (startValue[start] !== endValue[start]) { + break; + } + } - this.next = null; - this.entry = null; - this.finish = function () { - onCorkedFinish(_this, state); - }; -} -/* </replacement> */ + var minEnd = startLength - start; + for (end = 1; end <= minEnd; end++) { + if (startValue[startLength - end] !== endValue[endLength - end]) { + break; + } + } -/*<replacement>*/ -var asyncWrite = !process.browser && ['v0.10', 'v0.9.'].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : processNextTick; -/*</replacement>*/ + var sliceTail = end > 1 ? 1 - end : undefined; + this._fallbackText = endValue.slice(start, sliceTail); + return this._fallbackText; + } +}); -/*<replacement>*/ -var Duplex; -/*</replacement>*/ +PooledClass.addPoolingTo(FallbackCompositionState); -Writable.WritableState = WritableState; +module.exports = FallbackCompositionState; -/*<replacement>*/ -var util = __webpack_require__(237); -util.inherits = __webpack_require__(11); -/*</replacement>*/ +/***/ }), +/* 235 */ +/***/ (function(module, exports, __webpack_require__) { -/*<replacement>*/ -var internalUtil = { - deprecate: __webpack_require__(430) -}; -/*</replacement>*/ +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -/*<replacement>*/ -var Stream = __webpack_require__(308); -/*</replacement>*/ -/*<replacement>*/ -var Buffer = __webpack_require__(18).Buffer; -var OurUint8Array = global.Uint8Array || function () {}; -function _uint8ArrayToBuffer(chunk) { - return Buffer.from(chunk); -} -function _isUint8Array(obj) { - return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; -} -/*</replacement>*/ -var destroyImpl = __webpack_require__(309); +var SyntheticEvent = __webpack_require__(26); -util.inherits(Writable, Stream); +/** + * @interface Event + * @see http://www.w3.org/TR/DOM-Level-3-Events/#events-compositionevents + */ +var CompositionEventInterface = { + data: null +}; -function nop() {} +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticCompositionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} -function WritableState(options, stream) { - Duplex = Duplex || __webpack_require__(112); +SyntheticEvent.augmentClass(SyntheticCompositionEvent, CompositionEventInterface); - options = options || {}; +module.exports = SyntheticCompositionEvent; - // object stream flag to indicate whether or not this stream - // contains buffers or objects. - this.objectMode = !!options.objectMode; +/***/ }), +/* 236 */ +/***/ (function(module, exports, __webpack_require__) { - if (stream instanceof Duplex) this.objectMode = this.objectMode || !!options.writableObjectMode; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // the point at which write() starts returning false - // Note: 0 is a valid value, means that we always return false if - // the entire buffer is not flushed immediately on write() - var hwm = options.highWaterMark; - var defaultHwm = this.objectMode ? 16 : 16 * 1024; - this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm; - // cast to ints. - this.highWaterMark = Math.floor(this.highWaterMark); - // if _final has been called - this.finalCalled = false; +var SyntheticEvent = __webpack_require__(26); - // drain event flag. - this.needDrain = false; - // at the start of calling end() - this.ending = false; - // when end() has been called, and returned - this.ended = false; - // when 'finish' is emitted - this.finished = false; +/** + * @interface Event + * @see http://www.w3.org/TR/2013/WD-DOM-Level-3-Events-20131105 + * /#events-inputevents + */ +var InputEventInterface = { + data: null +}; - // has it been destroyed - this.destroyed = false; +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticInputEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} - // should we decode strings into buffers before passing to _write? - // this is here so that some node-core streams can optimize string - // handling at a lower level. - var noDecode = options.decodeStrings === false; - this.decodeStrings = !noDecode; +SyntheticEvent.augmentClass(SyntheticInputEvent, InputEventInterface); - // Crypto is kind of old and crusty. Historically, its default string - // encoding is 'binary' so we have to make this configurable. - // Everything else in the universe uses 'utf8', though. - this.defaultEncoding = options.defaultEncoding || 'utf8'; +module.exports = SyntheticInputEvent; - // not an actual buffer we keep track of, but a measurement - // of how much we're waiting to get pushed to some underlying - // socket or file. - this.length = 0; +/***/ }), +/* 237 */ +/***/ (function(module, exports, __webpack_require__) { - // a flag to see when we're in the middle of a write. - this.writing = false; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // when true all writes will be buffered until .uncork() call - this.corked = 0; - // a flag to be able to tell if the onwrite cb is called immediately, - // or on a later tick. We set this to true at first, because any - // actions that shouldn't happen until "later" should generally also - // not happen before the first write call. - this.sync = true; - // a flag to know if we're processing previously buffered items, which - // may call the _write() callback in the same tick, so that we don't - // end up in an overlapped onwrite situation. - this.bufferProcessing = false; +var EventPluginHub = __webpack_require__(46); +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); +var SyntheticEvent = __webpack_require__(26); - // the callback that's passed to _write(chunk,cb) - this.onwrite = function (er) { - onwrite(stream, er); - }; +var inputValueTracking = __webpack_require__(132); +var getEventTarget = __webpack_require__(79); +var isEventSupported = __webpack_require__(80); +var isTextInputElement = __webpack_require__(133); - // the callback that the user supplies to write(chunk,encoding,cb) - this.writecb = null; +var eventTypes = { + change: { + phasedRegistrationNames: { + bubbled: 'onChange', + captured: 'onChangeCapture' + }, + dependencies: ['topBlur', 'topChange', 'topClick', 'topFocus', 'topInput', 'topKeyDown', 'topKeyUp', 'topSelectionChange'] + } +}; - // the amount that is being written when _write is called. - this.writelen = 0; +function createAndAccumulateChangeEvent(inst, nativeEvent, target) { + var event = SyntheticEvent.getPooled(eventTypes.change, inst, nativeEvent, target); + event.type = 'change'; + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; +} +/** + * For IE shims + */ +var activeElement = null; +var activeElementInst = null; - this.bufferedRequest = null; - this.lastBufferedRequest = null; +/** + * SECTION: handle `change` event + */ +function shouldUseChangeEvent(elem) { + var nodeName = elem.nodeName && elem.nodeName.toLowerCase(); + return nodeName === 'select' || nodeName === 'input' && elem.type === 'file'; +} - // number of pending user-supplied write callbacks - // this must be 0 before 'finish' can be emitted - this.pendingcb = 0; +var doesChangeEventBubble = false; +if (ExecutionEnvironment.canUseDOM) { + // See `handleChange` comment below + doesChangeEventBubble = isEventSupported('change') && (!document.documentMode || document.documentMode > 8); +} - // emit prefinish if the only thing we're waiting for is _write cbs - // This is relevant for synchronous Transform streams - this.prefinished = false; +function manualDispatchChangeEvent(nativeEvent) { + var event = createAndAccumulateChangeEvent(activeElementInst, nativeEvent, getEventTarget(nativeEvent)); - // True if the error was already emitted and should not be thrown again - this.errorEmitted = false; + // If change and propertychange bubbled, we'd just bind to it like all the + // other events and have it go through ReactBrowserEventEmitter. Since it + // doesn't, we manually listen for the events and so we have to enqueue and + // process the abstract event manually. + // + // Batching is necessary here in order to ensure that all event handlers run + // before the next rerender (including event handlers attached to ancestor + // elements instead of directly on the input). Without this, controlled + // components don't work properly in conjunction with event bubbling because + // the component is rerendered and the value reverted before all the event + // handlers can run. See https://github.com/facebook/react/issues/708. + ReactUpdates.batchedUpdates(runEventInBatch, event); +} - // count buffered requests - this.bufferedRequestCount = 0; +function runEventInBatch(event) { + EventPluginHub.enqueueEvents(event); + EventPluginHub.processEventQueue(false); +} - // allocate the first CorkedRequest, there is always - // one allocated and free to use, and we maintain at most two - this.corkedRequestsFree = new CorkedRequest(this); +function startWatchingForChangeEventIE8(target, targetInst) { + activeElement = target; + activeElementInst = targetInst; + activeElement.attachEvent('onchange', manualDispatchChangeEvent); } -WritableState.prototype.getBuffer = function getBuffer() { - var current = this.bufferedRequest; - var out = []; - while (current) { - out.push(current); - current = current.next; +function stopWatchingForChangeEventIE8() { + if (!activeElement) { + return; } - return out; -}; - -(function () { - try { - Object.defineProperty(WritableState.prototype, 'buffer', { - get: internalUtil.deprecate(function () { - return this.getBuffer(); - }, '_writableState.buffer is deprecated. Use _writableState.getBuffer ' + 'instead.', 'DEP0003') - }); - } catch (_) {} -})(); + activeElement.detachEvent('onchange', manualDispatchChangeEvent); + activeElement = null; + activeElementInst = null; +} -// Test _writableState for inheritance to account for Duplex streams, -// whose prototype chain only points to Readable. -var realHasInstance; -if (typeof Symbol === 'function' && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] === 'function') { - realHasInstance = Function.prototype[Symbol.hasInstance]; - Object.defineProperty(Writable, Symbol.hasInstance, { - value: function (object) { - if (realHasInstance.call(this, object)) return true; +function getInstIfValueChanged(targetInst, nativeEvent) { + var updated = inputValueTracking.updateValueIfChanged(targetInst); + var simulated = nativeEvent.simulated === true && ChangeEventPlugin._allowSimulatedPassThrough; - return object && object._writableState instanceof WritableState; - } - }); -} else { - realHasInstance = function (object) { - return object instanceof this; - }; + if (updated || simulated) { + return targetInst; + } } -function Writable(options) { - Duplex = Duplex || __webpack_require__(112); +function getTargetInstForChangeEvent(topLevelType, targetInst) { + if (topLevelType === 'topChange') { + return targetInst; + } +} - // Writable ctor is applied to Duplexes, too. - // `realHasInstance` is necessary because using plain `instanceof` - // would return false, as no `_writableState` property is attached. - - // Trying to use the custom `instanceof` for Writable here will also break the - // Node.js LazyTransform implementation, which has a non-trivial getter for - // `_writableState` that would lead to infinite recursion. - if (!realHasInstance.call(Writable, this) && !(this instanceof Duplex)) { - return new Writable(options); +function handleEventsForChangeEventIE8(topLevelType, target, targetInst) { + if (topLevelType === 'topFocus') { + // stopWatching() should be a noop here but we call it just in case we + // missed a blur event somehow. + stopWatchingForChangeEventIE8(); + startWatchingForChangeEventIE8(target, targetInst); + } else if (topLevelType === 'topBlur') { + stopWatchingForChangeEventIE8(); } +} - this._writableState = new WritableState(options, this); - - // legacy. - this.writable = true; - - if (options) { - if (typeof options.write === 'function') this._write = options.write; +/** + * SECTION: handle `input` event + */ +var isInputEventSupported = false; +if (ExecutionEnvironment.canUseDOM) { + // IE9 claims to support the input event but fails to trigger it when + // deleting text, so we ignore its input events. - if (typeof options.writev === 'function') this._writev = options.writev; + isInputEventSupported = isEventSupported('input') && (!('documentMode' in document) || document.documentMode > 9); +} - if (typeof options.destroy === 'function') this._destroy = options.destroy; +/** + * (For IE <=9) Starts tracking propertychange events on the passed-in element + * and override the value property so that we can distinguish user events from + * value changes in JS. + */ +function startWatchingForValueChange(target, targetInst) { + activeElement = target; + activeElementInst = targetInst; + activeElement.attachEvent('onpropertychange', handlePropertyChange); +} - if (typeof options.final === 'function') this._final = options.final; +/** + * (For IE <=9) Removes the event listeners from the currently-tracked element, + * if any exists. + */ +function stopWatchingForValueChange() { + if (!activeElement) { + return; } + activeElement.detachEvent('onpropertychange', handlePropertyChange); - Stream.call(this); + activeElement = null; + activeElementInst = null; } -// Otherwise people can pipe Writable streams, which is just wrong. -Writable.prototype.pipe = function () { - this.emit('error', new Error('Cannot pipe, not readable')); -}; - -function writeAfterEnd(stream, cb) { - var er = new Error('write after end'); - // TODO: defer error events consistently everywhere, not just the cb - stream.emit('error', er); - processNextTick(cb, er); +/** + * (For IE <=9) Handles a propertychange event, sending a `change` event if + * the value of the active element has changed. + */ +function handlePropertyChange(nativeEvent) { + if (nativeEvent.propertyName !== 'value') { + return; + } + if (getInstIfValueChanged(activeElementInst, nativeEvent)) { + manualDispatchChangeEvent(nativeEvent); + } } -// Checks that a user-supplied chunk is valid, especially for the particular -// mode the stream is in. Currently this means that `null` is never accepted -// and undefined/non-string values are only allowed in object mode. -function validChunk(stream, state, chunk, cb) { - var valid = true; - var er = false; - - if (chunk === null) { - er = new TypeError('May not write null values to stream'); - } else if (typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { - er = new TypeError('Invalid non-string/buffer chunk'); +function handleEventsForInputEventPolyfill(topLevelType, target, targetInst) { + if (topLevelType === 'topFocus') { + // In IE8, we can capture almost all .value changes by adding a + // propertychange handler and looking for events with propertyName + // equal to 'value' + // In IE9, propertychange fires for most input events but is buggy and + // doesn't fire when text is deleted, but conveniently, selectionchange + // appears to fire in all of the remaining cases so we catch those and + // forward the event if the value has changed + // In either case, we don't want to call the event handler if the value + // is changed from JS so we redefine a setter for `.value` that updates + // our activeElementValue variable, allowing us to ignore those changes + // + // stopWatching() should be a noop here but we call it just in case we + // missed a blur event somehow. + stopWatchingForValueChange(); + startWatchingForValueChange(target, targetInst); + } else if (topLevelType === 'topBlur') { + stopWatchingForValueChange(); } - if (er) { - stream.emit('error', er); - processNextTick(cb, er); - valid = false; +} + +// For IE8 and IE9. +function getTargetInstForInputEventPolyfill(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topSelectionChange' || topLevelType === 'topKeyUp' || topLevelType === 'topKeyDown') { + // On the selectionchange event, the target is just document which isn't + // helpful for us so just check activeElement instead. + // + // 99% of the time, keydown and keyup aren't necessary. IE8 fails to fire + // propertychange on the first input event after setting `value` from a + // script and fires only keydown, keypress, keyup. Catching keyup usually + // gets it and catching keydown lets us fire an event for the first + // keystroke if user does a key repeat (it'll be a little delayed: right + // before the second keystroke). Other input methods (e.g., paste) seem to + // fire selectionchange normally. + return getInstIfValueChanged(activeElementInst, nativeEvent); } - return valid; } -Writable.prototype.write = function (chunk, encoding, cb) { - var state = this._writableState; - var ret = false; - var isBuf = _isUint8Array(chunk) && !state.objectMode; +/** + * SECTION: handle `click` event + */ +function shouldUseClickEvent(elem) { + // Use the `click` event to detect changes to checkbox and radio inputs. + // This approach works across all browsers, whereas `change` does not fire + // until `blur` in IE8. + var nodeName = elem.nodeName; + return nodeName && nodeName.toLowerCase() === 'input' && (elem.type === 'checkbox' || elem.type === 'radio'); +} - if (isBuf && !Buffer.isBuffer(chunk)) { - chunk = _uint8ArrayToBuffer(chunk); +function getTargetInstForClickEvent(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topClick') { + return getInstIfValueChanged(targetInst, nativeEvent); } +} - if (typeof encoding === 'function') { - cb = encoding; - encoding = null; +function getTargetInstForInputOrChangeEvent(topLevelType, targetInst, nativeEvent) { + if (topLevelType === 'topInput' || topLevelType === 'topChange') { + return getInstIfValueChanged(targetInst, nativeEvent); } +} - if (isBuf) encoding = 'buffer';else if (!encoding) encoding = state.defaultEncoding; +function handleControlledInputBlur(inst, node) { + // TODO: In IE, inst is occasionally null. Why? + if (inst == null) { + return; + } - if (typeof cb !== 'function') cb = nop; + // Fiber and ReactDOM keep wrapper state in separate places + var state = inst._wrapperState || node._wrapperState; - if (state.ended) writeAfterEnd(this, cb);else if (isBuf || validChunk(this, state, chunk, cb)) { - state.pendingcb++; - ret = writeOrBuffer(this, state, isBuf, chunk, encoding, cb); + if (!state || !state.controlled || node.type !== 'number') { + return; } - return ret; -}; - -Writable.prototype.cork = function () { - var state = this._writableState; + // If controlled, assign the value attribute to the current value on blur + var value = '' + node.value; + if (node.getAttribute('value') !== value) { + node.setAttribute('value', value); + } +} - state.corked++; -}; +/** + * This plugin creates an `onChange` event that normalizes change events + * across form elements. This event fires at a time when it's possible to + * change the element's value without seeing a flicker. + * + * Supported elements are: + * - input (see `isTextInputElement`) + * - textarea + * - select + */ +var ChangeEventPlugin = { + eventTypes: eventTypes, -Writable.prototype.uncork = function () { - var state = this._writableState; + _allowSimulatedPassThrough: true, + _isInputEventSupported: isInputEventSupported, - if (state.corked) { - state.corked--; + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; - if (!state.writing && !state.corked && !state.finished && !state.bufferProcessing && state.bufferedRequest) clearBuffer(this, state); - } -}; + var getTargetInstFunc, handleEventFunc; + if (shouldUseChangeEvent(targetNode)) { + if (doesChangeEventBubble) { + getTargetInstFunc = getTargetInstForChangeEvent; + } else { + handleEventFunc = handleEventsForChangeEventIE8; + } + } else if (isTextInputElement(targetNode)) { + if (isInputEventSupported) { + getTargetInstFunc = getTargetInstForInputOrChangeEvent; + } else { + getTargetInstFunc = getTargetInstForInputEventPolyfill; + handleEventFunc = handleEventsForInputEventPolyfill; + } + } else if (shouldUseClickEvent(targetNode)) { + getTargetInstFunc = getTargetInstForClickEvent; + } -Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) { - // node::ParseEncoding() requires lower case. - if (typeof encoding === 'string') encoding = encoding.toLowerCase(); - if (!(['hex', 'utf8', 'utf-8', 'ascii', 'binary', 'base64', 'ucs2', 'ucs-2', 'utf16le', 'utf-16le', 'raw'].indexOf((encoding + '').toLowerCase()) > -1)) throw new TypeError('Unknown encoding: ' + encoding); - this._writableState.defaultEncoding = encoding; - return this; -}; + if (getTargetInstFunc) { + var inst = getTargetInstFunc(topLevelType, targetInst, nativeEvent); + if (inst) { + var event = createAndAccumulateChangeEvent(inst, nativeEvent, nativeEventTarget); + return event; + } + } -function decodeChunk(state, chunk, encoding) { - if (!state.objectMode && state.decodeStrings !== false && typeof chunk === 'string') { - chunk = Buffer.from(chunk, encoding); - } - return chunk; -} + if (handleEventFunc) { + handleEventFunc(topLevelType, targetNode, targetInst); + } -// if we're already writing something, then just put this -// in the queue, and wait our turn. Otherwise, call _write -// If we return false, then we need a drain event, so set that flag. -function writeOrBuffer(stream, state, isBuf, chunk, encoding, cb) { - if (!isBuf) { - var newChunk = decodeChunk(state, chunk, encoding); - if (chunk !== newChunk) { - isBuf = true; - encoding = 'buffer'; - chunk = newChunk; + // When blurring, set the value attribute for number inputs + if (topLevelType === 'topBlur') { + handleControlledInputBlur(targetInst, targetNode); } } - var len = state.objectMode ? 1 : chunk.length; +}; - state.length += len; +module.exports = ChangeEventPlugin; - var ret = state.length < state.highWaterMark; - // we must ensure that previous needDrain will not be reset to false. - if (!ret) state.needDrain = true; +/***/ }), +/* 238 */ +/***/ (function(module, exports, __webpack_require__) { - if (state.writing || state.corked) { - var last = state.lastBufferedRequest; - state.lastBufferedRequest = { - chunk: chunk, - encoding: encoding, - isBuf: isBuf, - callback: cb, - next: null - }; - if (last) { - last.next = state.lastBufferedRequest; - } else { - state.bufferedRequest = state.lastBufferedRequest; - } - state.bufferedRequestCount += 1; - } else { - doWrite(stream, state, false, len, chunk, encoding, cb); - } +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - return ret; -} -function doWrite(stream, state, writev, len, chunk, encoding, cb) { - state.writelen = len; - state.writecb = cb; - state.writing = true; - state.sync = true; - if (writev) stream._writev(chunk, state.onwrite);else stream._write(chunk, encoding, state.onwrite); - state.sync = false; -} -function onwriteError(stream, state, sync, er, cb) { - --state.pendingcb; +var ReactOwner = __webpack_require__(239); - if (sync) { - // defer the callback if we are being called synchronously - // to avoid piling up things on the stack - processNextTick(cb, er); - // this can emit finish, and it will always happen - // after error - processNextTick(finishMaybe, stream, state); - stream._writableState.errorEmitted = true; - stream.emit('error', er); +var ReactRef = {}; + +function attachRef(ref, component, owner) { + if (typeof ref === 'function') { + ref(component.getPublicInstance()); } else { - // the caller expect this to happen before if - // it is async - cb(er); - stream._writableState.errorEmitted = true; - stream.emit('error', er); - // this can emit finish, but finish must - // always follow error - finishMaybe(stream, state); + // Legacy ref + ReactOwner.addComponentAsRefTo(component, ref, owner); } } -function onwriteStateUpdate(state) { - state.writing = false; - state.writecb = null; - state.length -= state.writelen; - state.writelen = 0; +function detachRef(ref, component, owner) { + if (typeof ref === 'function') { + ref(null); + } else { + // Legacy ref + ReactOwner.removeComponentAsRefFrom(component, ref, owner); + } } -function onwrite(stream, er) { - var state = stream._writableState; - var sync = state.sync; - var cb = state.writecb; +ReactRef.attachRefs = function (instance, element) { + if (element === null || typeof element !== 'object') { + return; + } + var ref = element.ref; + if (ref != null) { + attachRef(ref, instance, element._owner); + } +}; - onwriteStateUpdate(state); +ReactRef.shouldUpdateRefs = function (prevElement, nextElement) { + // If either the owner or a `ref` has changed, make sure the newest owner + // has stored a reference to `this`, and the previous owner (if different) + // has forgotten the reference to `this`. We use the element instead + // of the public this.props because the post processing cannot determine + // a ref. The ref conceptually lives on the element. - if (er) onwriteError(stream, state, sync, er, cb);else { - // Check if we're actually ready to finish, but don't emit yet - var finished = needFinish(state); + // TODO: Should this even be possible? The owner cannot change because + // it's forbidden by shouldUpdateReactComponent. The ref can change + // if you swap the keys of but not the refs. Reconsider where this check + // is made. It probably belongs where the key checking and + // instantiateReactComponent is done. - if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) { - clearBuffer(stream, state); - } + var prevRef = null; + var prevOwner = null; + if (prevElement !== null && typeof prevElement === 'object') { + prevRef = prevElement.ref; + prevOwner = prevElement._owner; + } - if (sync) { - /*<replacement>*/ - asyncWrite(afterWrite, stream, state, finished, cb); - /*</replacement>*/ - } else { - afterWrite(stream, state, finished, cb); - } + var nextRef = null; + var nextOwner = null; + if (nextElement !== null && typeof nextElement === 'object') { + nextRef = nextElement.ref; + nextOwner = nextElement._owner; } -} -function afterWrite(stream, state, finished, cb) { - if (!finished) onwriteDrain(stream, state); - state.pendingcb--; - cb(); - finishMaybe(stream, state); -} + return prevRef !== nextRef || + // If owner changes but we have an unchanged function ref, don't update refs + typeof nextRef === 'string' && nextOwner !== prevOwner; +}; -// Must force callback to be called on nextTick, so that we don't -// emit 'drain' before the write() consumer gets the 'false' return -// value, and has a chance to attach a 'drain' listener. -function onwriteDrain(stream, state) { - if (state.length === 0 && state.needDrain) { - state.needDrain = false; - stream.emit('drain'); +ReactRef.detachRefs = function (instance, element) { + if (element === null || typeof element !== 'object') { + return; } -} + var ref = element.ref; + if (ref != null) { + detachRef(ref, instance, element._owner); + } +}; -// if there's something in the buffer waiting, then process it -function clearBuffer(stream, state) { - state.bufferProcessing = true; - var entry = state.bufferedRequest; +module.exports = ReactRef; - if (stream._writev && entry && entry.next) { - // Fast case, write everything using _writev() - var l = state.bufferedRequestCount; - var buffer = new Array(l); - var holder = state.corkedRequestsFree; - holder.entry = entry; +/***/ }), +/* 239 */ +/***/ (function(module, exports, __webpack_require__) { - var count = 0; - var allBuffers = true; - while (entry) { - buffer[count] = entry; - if (!entry.isBuf) allBuffers = false; - entry = entry.next; - count += 1; - } - buffer.allBuffers = allBuffers; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - doWrite(stream, state, true, state.length, buffer, '', holder.finish); - // doWrite is almost always async, defer these to save a bit of time - // as the hot path ends with doWrite - state.pendingcb++; - state.lastBufferedRequest = null; - if (holder.next) { - state.corkedRequestsFree = holder.next; - holder.next = null; - } else { - state.corkedRequestsFree = new CorkedRequest(state); - } - } else { - // Slow case, write chunks one-by-one - while (entry) { - var chunk = entry.chunk; - var encoding = entry.encoding; - var cb = entry.callback; - var len = state.objectMode ? 1 : chunk.length; - doWrite(stream, state, false, len, chunk, encoding, cb); - entry = entry.next; - // if we didn't call the onwrite immediately, then - // it means that we need to wait until it does. - // also, that means that the chunk and cb are currently - // being processed, so move the buffer counter past them. - if (state.writing) { - break; - } - } +var _prodInvariant = __webpack_require__(5); - if (entry === null) state.lastBufferedRequest = null; - } +var invariant = __webpack_require__(2); - state.bufferedRequestCount = 0; - state.bufferedRequest = entry; - state.bufferProcessing = false; +/** + * @param {?object} object + * @return {boolean} True if `object` is a valid owner. + * @final + */ +function isValidOwner(object) { + return !!(object && typeof object.attachRef === 'function' && typeof object.detachRef === 'function'); } -Writable.prototype._write = function (chunk, encoding, cb) { - cb(new Error('_write() is not implemented')); -}; - -Writable.prototype._writev = null; - -Writable.prototype.end = function (chunk, encoding, cb) { - var state = this._writableState; - - if (typeof chunk === 'function') { - cb = chunk; - chunk = null; - encoding = null; - } else if (typeof encoding === 'function') { - cb = encoding; - encoding = null; +/** + * ReactOwners are capable of storing references to owned components. + * + * All components are capable of //being// referenced by owner components, but + * only ReactOwner components are capable of //referencing// owned components. + * The named reference is known as a "ref". + * + * Refs are available when mounted and updated during reconciliation. + * + * var MyComponent = React.createClass({ + * render: function() { + * return ( + * <div onClick={this.handleClick}> + * <CustomComponent ref="custom" /> + * </div> + * ); + * }, + * handleClick: function() { + * this.refs.custom.handleClick(); + * }, + * componentDidMount: function() { + * this.refs.custom.initialize(); + * } + * }); + * + * Refs should rarely be used. When refs are used, they should only be done to + * control data that is not handled by React's data flow. + * + * @class ReactOwner + */ +var ReactOwner = { + /** + * Adds a component by ref to an owner component. + * + * @param {ReactComponent} component Component to reference. + * @param {string} ref Name by which to refer to the component. + * @param {ReactOwner} owner Component on which to record the ref. + * @final + * @internal + */ + addComponentAsRefTo: function (component, ref, owner) { + !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('119') : void 0; + owner.attachRef(ref, component); + }, + + /** + * Removes a component by ref from an owner component. + * + * @param {ReactComponent} component Component to dereference. + * @param {string} ref Name of the ref to remove. + * @param {ReactOwner} owner Component on which the ref is recorded. + * @final + * @internal + */ + removeComponentAsRefFrom: function (component, ref, owner) { + !isValidOwner(owner) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'removeComponentAsRefFrom(...): Only a ReactOwner can have refs. You might be removing a ref to a component that was not created inside a component\'s `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).') : _prodInvariant('120') : void 0; + var ownerPublicInstance = owner.getPublicInstance(); + // Check that `component`'s owner is still alive and that `component` is still the current ref + // because we do not want to detach the ref if another component stole it. + if (ownerPublicInstance && ownerPublicInstance.refs[ref] === component.getPublicInstance()) { + owner.detachRef(ref); + } } +}; - if (chunk !== null && chunk !== undefined) this.write(chunk, encoding); +module.exports = ReactOwner; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - // .end() fully uncorks - if (state.corked) { - state.corked = 1; - this.uncork(); - } +/***/ }), +/* 240 */ +/***/ (function(module, exports, __webpack_require__) { - // ignore unnecessary end() calls. - if (!state.ending && !state.finished) endWritable(this, state, cb); -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -function needFinish(state) { - return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing; -} -function callFinal(stream, state) { - stream._final(function (err) { - state.pendingcb--; - if (err) { - stream.emit('error', err); - } - state.prefinished = true; - stream.emit('prefinish'); - finishMaybe(stream, state); - }); -} -function prefinish(stream, state) { - if (!state.prefinished && !state.finalCalled) { - if (typeof stream._final === 'function') { - state.pendingcb++; - state.finalCalled = true; - processNextTick(callFinal, stream, state); - } else { - state.prefinished = true; - stream.emit('prefinish'); - } + + +var ReactInvalidSetStateWarningHook = __webpack_require__(241); +var ReactHostOperationHistoryHook = __webpack_require__(242); +var ReactComponentTreeHook = __webpack_require__(17); +var ExecutionEnvironment = __webpack_require__(13); + +var performanceNow = __webpack_require__(243); +var warning = __webpack_require__(3); + +var hooks = []; +var didHookThrowForEvent = {}; + +function callHook(event, fn, context, arg1, arg2, arg3, arg4, arg5) { + try { + fn.call(context, arg1, arg2, arg3, arg4, arg5); + } catch (e) { + process.env.NODE_ENV !== 'production' ? warning(didHookThrowForEvent[event], 'Exception thrown by hook while handling %s: %s', event, e + '\n' + e.stack) : void 0; + didHookThrowForEvent[event] = true; } } -function finishMaybe(stream, state) { - var need = needFinish(state); - if (need) { - prefinish(stream, state); - if (state.pendingcb === 0) { - state.finished = true; - stream.emit('finish'); +function emitEvent(event, arg1, arg2, arg3, arg4, arg5) { + for (var i = 0; i < hooks.length; i++) { + var hook = hooks[i]; + var fn = hook[event]; + if (fn) { + callHook(event, fn, hook, arg1, arg2, arg3, arg4, arg5); } } - return need; } -function endWritable(stream, state, cb) { - state.ending = true; - finishMaybe(stream, state); - if (cb) { - if (state.finished) processNextTick(cb);else stream.once('finish', cb); - } - state.ended = true; - stream.writable = false; +var isProfiling = false; +var flushHistory = []; +var lifeCycleTimerStack = []; +var currentFlushNesting = 0; +var currentFlushMeasurements = []; +var currentFlushStartTime = 0; +var currentTimerDebugID = null; +var currentTimerStartTime = 0; +var currentTimerNestedFlushDuration = 0; +var currentTimerType = null; + +var lifeCycleTimerHasWarned = false; + +function clearHistory() { + ReactComponentTreeHook.purgeUnmountedComponents(); + ReactHostOperationHistoryHook.clearHistory(); } -function onCorkedFinish(corkReq, state, err) { - var entry = corkReq.entry; - corkReq.entry = null; - while (entry) { - var cb = entry.callback; - state.pendingcb--; - cb(err); - entry = entry.next; - } - if (state.corkedRequestsFree) { - state.corkedRequestsFree.next = corkReq; - } else { - state.corkedRequestsFree = corkReq; - } +function getTreeSnapshot(registeredIDs) { + return registeredIDs.reduce(function (tree, id) { + var ownerID = ReactComponentTreeHook.getOwnerID(id); + var parentID = ReactComponentTreeHook.getParentID(id); + tree[id] = { + displayName: ReactComponentTreeHook.getDisplayName(id), + text: ReactComponentTreeHook.getText(id), + updateCount: ReactComponentTreeHook.getUpdateCount(id), + childIDs: ReactComponentTreeHook.getChildIDs(id), + // Text nodes don't have owners but this is close enough. + ownerID: ownerID || parentID && ReactComponentTreeHook.getOwnerID(parentID) || 0, + parentID: parentID + }; + return tree; + }, {}); } -Object.defineProperty(Writable.prototype, 'destroyed', { - get: function () { - if (this._writableState === undefined) { - return false; - } - return this._writableState.destroyed; - }, - set: function (value) { - // we ignore the value if the stream - // has not been initialized yet - if (!this._writableState) { - return; - } +function resetMeasurements() { + var previousStartTime = currentFlushStartTime; + var previousMeasurements = currentFlushMeasurements; + var previousOperations = ReactHostOperationHistoryHook.getHistory(); - // backward compatibility, the user is explicitly - // managing destroyed - this._writableState.destroyed = value; + if (currentFlushNesting === 0) { + currentFlushStartTime = 0; + currentFlushMeasurements = []; + clearHistory(); + return; } -}); - -Writable.prototype.destroy = destroyImpl.destroy; -Writable.prototype._undestroy = destroyImpl.undestroy; -Writable.prototype._destroy = function (err, cb) { - this.end(); - cb(err); -}; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0), __webpack_require__(310).setImmediate, __webpack_require__(67))) - -/***/ }), -/* 264 */ -/***/ (function(module, exports, __webpack_require__) { - -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. -var Buffer = __webpack_require__(7).Buffer; + if (previousMeasurements.length || previousOperations.length) { + var registeredIDs = ReactComponentTreeHook.getRegisteredIDs(); + flushHistory.push({ + duration: performanceNow() - previousStartTime, + measurements: previousMeasurements || [], + operations: previousOperations || [], + treeSnapshot: getTreeSnapshot(registeredIDs) + }); + } -var isBufferEncoding = Buffer.isEncoding - || function(encoding) { - switch (encoding && encoding.toLowerCase()) { - case 'hex': case 'utf8': case 'utf-8': case 'ascii': case 'binary': case 'base64': case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': case 'raw': return true; - default: return false; - } - } + clearHistory(); + currentFlushStartTime = performanceNow(); + currentFlushMeasurements = []; +} +function checkDebugID(debugID) { + var allowRoot = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; -function assertEncoding(encoding) { - if (encoding && !isBufferEncoding(encoding)) { - throw new Error('Unknown encoding: ' + encoding); + if (allowRoot && debugID === 0) { + return; + } + if (!debugID) { + process.env.NODE_ENV !== 'production' ? warning(false, 'ReactDebugTool: debugID may not be empty.') : void 0; } } -// StringDecoder provides an interface for efficiently splitting a series of -// buffers into a series of JS strings without breaking apart multi-byte -// characters. CESU-8 is handled as part of the UTF-8 encoding. -// -// @TODO Handling all encodings inside a single object makes it very difficult -// to reason about this code, so it should be split up in the future. -// @TODO There should be a utf8-strict encoding that rejects invalid UTF-8 code -// points as used by CESU-8. -var StringDecoder = exports.StringDecoder = function(encoding) { - this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, ''); - assertEncoding(encoding); - switch (this.encoding) { - case 'utf8': - // CESU-8 represents each of Surrogate Pair by 3-bytes - this.surrogateSize = 3; - break; - case 'ucs2': - case 'utf16le': - // UTF-16 represents each of Surrogate Pair by 2-bytes - this.surrogateSize = 2; - this.detectIncompleteChar = utf16DetectIncompleteChar; - break; - case 'base64': - // Base-64 stores 3 bytes in 4 chars, and pads the remainder. - this.surrogateSize = 3; - this.detectIncompleteChar = base64DetectIncompleteChar; - break; - default: - this.write = passThroughWrite; - return; +function beginLifeCycleTimer(debugID, timerType) { + if (currentFlushNesting === 0) { + return; } + if (currentTimerType && !lifeCycleTimerHasWarned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'Did not expect %s timer to start while %s timer is still in ' + 'progress for %s instance.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; + lifeCycleTimerHasWarned = true; + } + currentTimerStartTime = performanceNow(); + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = debugID; + currentTimerType = timerType; +} - // Enough space to store all bytes of a single character. UTF-8 needs 4 - // bytes, but CESU-8 may require up to 6 (3 bytes per surrogate). - this.charBuffer = new Buffer(6); - // Number of bytes received for the current incomplete multi-byte character. - this.charReceived = 0; - // Number of bytes expected for the current incomplete multi-byte character. - this.charLength = 0; -}; - - -// write decodes the given buffer and returns it as JS string that is -// guaranteed to not contain any partial multi-byte characters. Any partial -// character found at the end of the buffer is buffered up, and will be -// returned when calling write again with the remaining bytes. -// -// Note: Converting a Buffer containing an orphan surrogate to a String -// currently works, but converting a String to a Buffer (via `new Buffer`, or -// Buffer#write) will replace incomplete surrogates with the unicode -// replacement character. See https://codereview.chromium.org/121173009/ . -StringDecoder.prototype.write = function(buffer) { - var charStr = ''; - // if our last write ended with an incomplete multibyte character - while (this.charLength) { - // determine how many remaining bytes this buffer has to offer for this char - var available = (buffer.length >= this.charLength - this.charReceived) ? - this.charLength - this.charReceived : - buffer.length; +function endLifeCycleTimer(debugID, timerType) { + if (currentFlushNesting === 0) { + return; + } + if (currentTimerType !== timerType && !lifeCycleTimerHasWarned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'There is an internal error in the React performance measurement code. ' + 'We did not expect %s timer to stop while %s timer is still in ' + 'progress for %s instance. Please report this as a bug in React.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0; + lifeCycleTimerHasWarned = true; + } + if (isProfiling) { + currentFlushMeasurements.push({ + timerType: timerType, + instanceID: debugID, + duration: performanceNow() - currentTimerStartTime - currentTimerNestedFlushDuration + }); + } + currentTimerStartTime = 0; + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = null; + currentTimerType = null; +} - // add the new bytes to the char buffer - buffer.copy(this.charBuffer, this.charReceived, 0, available); - this.charReceived += available; +function pauseCurrentLifeCycleTimer() { + var currentTimer = { + startTime: currentTimerStartTime, + nestedFlushStartTime: performanceNow(), + debugID: currentTimerDebugID, + timerType: currentTimerType + }; + lifeCycleTimerStack.push(currentTimer); + currentTimerStartTime = 0; + currentTimerNestedFlushDuration = 0; + currentTimerDebugID = null; + currentTimerType = null; +} - if (this.charReceived < this.charLength) { - // still not enough chars in this buffer? wait for more ... - return ''; - } +function resumeCurrentLifeCycleTimer() { + var _lifeCycleTimerStack$ = lifeCycleTimerStack.pop(), + startTime = _lifeCycleTimerStack$.startTime, + nestedFlushStartTime = _lifeCycleTimerStack$.nestedFlushStartTime, + debugID = _lifeCycleTimerStack$.debugID, + timerType = _lifeCycleTimerStack$.timerType; - // remove bytes belonging to the current character from the buffer - buffer = buffer.slice(available, buffer.length); + var nestedFlushDuration = performanceNow() - nestedFlushStartTime; + currentTimerStartTime = startTime; + currentTimerNestedFlushDuration += nestedFlushDuration; + currentTimerDebugID = debugID; + currentTimerType = timerType; +} - // get the character that was split - charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding); +var lastMarkTimeStamp = 0; +var canUsePerformanceMeasure = typeof performance !== 'undefined' && typeof performance.mark === 'function' && typeof performance.clearMarks === 'function' && typeof performance.measure === 'function' && typeof performance.clearMeasures === 'function'; - // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character - var charCode = charStr.charCodeAt(charStr.length - 1); - if (charCode >= 0xD800 && charCode <= 0xDBFF) { - this.charLength += this.surrogateSize; - charStr = ''; - continue; - } - this.charReceived = this.charLength = 0; +function shouldMark(debugID) { + if (!isProfiling || !canUsePerformanceMeasure) { + return false; + } + var element = ReactComponentTreeHook.getElement(debugID); + if (element == null || typeof element !== 'object') { + return false; + } + var isHostElement = typeof element.type === 'string'; + if (isHostElement) { + return false; + } + return true; +} - // if there are no more bytes in this buffer, just emit our char - if (buffer.length === 0) { - return charStr; - } - break; +function markBegin(debugID, markType) { + if (!shouldMark(debugID)) { + return; } - // determine and set charLength / charReceived - this.detectIncompleteChar(buffer); + var markName = debugID + '::' + markType; + lastMarkTimeStamp = performanceNow(); + performance.mark(markName); +} - var end = buffer.length; - if (this.charLength) { - // buffer the incomplete character bytes we got - buffer.copy(this.charBuffer, 0, buffer.length - this.charReceived, end); - end -= this.charReceived; +function markEnd(debugID, markType) { + if (!shouldMark(debugID)) { + return; } - charStr += buffer.toString(this.encoding, 0, end); + var markName = debugID + '::' + markType; + var displayName = ReactComponentTreeHook.getDisplayName(debugID) || 'Unknown'; - var end = charStr.length - 1; - var charCode = charStr.charCodeAt(end); - // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character - if (charCode >= 0xD800 && charCode <= 0xDBFF) { - var size = this.surrogateSize; - this.charLength += size; - this.charReceived += size; - this.charBuffer.copy(this.charBuffer, size, 0, size); - buffer.copy(this.charBuffer, 0, 0, size); - return charStr.substring(0, end); + // Chrome has an issue of dropping markers recorded too fast: + // https://bugs.chromium.org/p/chromium/issues/detail?id=640652 + // To work around this, we will not report very small measurements. + // I determined the magic number by tweaking it back and forth. + // 0.05ms was enough to prevent the issue, but I set it to 0.1ms to be safe. + // When the bug is fixed, we can `measure()` unconditionally if we want to. + var timeStamp = performanceNow(); + if (timeStamp - lastMarkTimeStamp > 0.1) { + var measurementName = displayName + ' [' + markType + ']'; + performance.measure(measurementName, markName); } - // or just emit the charStr - return charStr; -}; + performance.clearMarks(markName); + if (measurementName) { + performance.clearMeasures(measurementName); + } +} -// detectIncompleteChar determines if there is an incomplete UTF-8 character at -// the end of the given buffer. If so, it sets this.charLength to the byte -// length that character, and sets this.charReceived to the number of bytes -// that are available for this character. -StringDecoder.prototype.detectIncompleteChar = function(buffer) { - // determine how many bytes we have to check at the end of this buffer - var i = (buffer.length >= 3) ? 3 : buffer.length; +var ReactDebugTool = { + addHook: function (hook) { + hooks.push(hook); + }, + removeHook: function (hook) { + for (var i = 0; i < hooks.length; i++) { + if (hooks[i] === hook) { + hooks.splice(i, 1); + i--; + } + } + }, + isProfiling: function () { + return isProfiling; + }, + beginProfiling: function () { + if (isProfiling) { + return; + } - // Figure out if one of the last i bytes of our buffer announces an - // incomplete char. - for (; i > 0; i--) { - var c = buffer[buffer.length - i]; - - // See http://en.wikipedia.org/wiki/UTF-8#Description - - // 110XXXXX - if (i == 1 && c >> 5 == 0x06) { - this.charLength = 2; - break; - } - - // 1110XXXX - if (i <= 2 && c >> 4 == 0x0E) { - this.charLength = 3; - break; - } - - // 11110XXX - if (i <= 3 && c >> 3 == 0x1E) { - this.charLength = 4; - break; + isProfiling = true; + flushHistory.length = 0; + resetMeasurements(); + ReactDebugTool.addHook(ReactHostOperationHistoryHook); + }, + endProfiling: function () { + if (!isProfiling) { + return; } - } - this.charReceived = i; -}; -StringDecoder.prototype.end = function(buffer) { - var res = ''; - if (buffer && buffer.length) - res = this.write(buffer); - - if (this.charReceived) { - var cr = this.charReceived; - var buf = this.charBuffer; - var enc = this.encoding; - res += buf.slice(0, cr).toString(enc); + isProfiling = false; + resetMeasurements(); + ReactDebugTool.removeHook(ReactHostOperationHistoryHook); + }, + getFlushHistory: function () { + return flushHistory; + }, + onBeginFlush: function () { + currentFlushNesting++; + resetMeasurements(); + pauseCurrentLifeCycleTimer(); + emitEvent('onBeginFlush'); + }, + onEndFlush: function () { + resetMeasurements(); + currentFlushNesting--; + resumeCurrentLifeCycleTimer(); + emitEvent('onEndFlush'); + }, + onBeginLifeCycleTimer: function (debugID, timerType) { + checkDebugID(debugID); + emitEvent('onBeginLifeCycleTimer', debugID, timerType); + markBegin(debugID, timerType); + beginLifeCycleTimer(debugID, timerType); + }, + onEndLifeCycleTimer: function (debugID, timerType) { + checkDebugID(debugID); + endLifeCycleTimer(debugID, timerType); + markEnd(debugID, timerType); + emitEvent('onEndLifeCycleTimer', debugID, timerType); + }, + onBeginProcessingChildContext: function () { + emitEvent('onBeginProcessingChildContext'); + }, + onEndProcessingChildContext: function () { + emitEvent('onEndProcessingChildContext'); + }, + onHostOperation: function (operation) { + checkDebugID(operation.instanceID); + emitEvent('onHostOperation', operation); + }, + onSetState: function () { + emitEvent('onSetState'); + }, + onSetChildren: function (debugID, childDebugIDs) { + checkDebugID(debugID); + childDebugIDs.forEach(checkDebugID); + emitEvent('onSetChildren', debugID, childDebugIDs); + }, + onBeforeMountComponent: function (debugID, element, parentDebugID) { + checkDebugID(debugID); + checkDebugID(parentDebugID, true); + emitEvent('onBeforeMountComponent', debugID, element, parentDebugID); + markBegin(debugID, 'mount'); + }, + onMountComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'mount'); + emitEvent('onMountComponent', debugID); + }, + onBeforeUpdateComponent: function (debugID, element) { + checkDebugID(debugID); + emitEvent('onBeforeUpdateComponent', debugID, element); + markBegin(debugID, 'update'); + }, + onUpdateComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'update'); + emitEvent('onUpdateComponent', debugID); + }, + onBeforeUnmountComponent: function (debugID) { + checkDebugID(debugID); + emitEvent('onBeforeUnmountComponent', debugID); + markBegin(debugID, 'unmount'); + }, + onUnmountComponent: function (debugID) { + checkDebugID(debugID); + markEnd(debugID, 'unmount'); + emitEvent('onUnmountComponent', debugID); + }, + onTestEvent: function () { + emitEvent('onTestEvent'); } - - return res; }; -function passThroughWrite(buffer) { - return buffer.toString(this.encoding); -} - -function utf16DetectIncompleteChar(buffer) { - this.charReceived = buffer.length % 2; - this.charLength = this.charReceived ? 2 : 0; -} +// TODO remove these when RN/www gets updated +ReactDebugTool.addDevtool = ReactDebugTool.addHook; +ReactDebugTool.removeDevtool = ReactDebugTool.removeHook; -function base64DetectIncompleteChar(buffer) { - this.charReceived = buffer.length % 3; - this.charLength = this.charReceived ? 3 : 0; +ReactDebugTool.addHook(ReactInvalidSetStateWarningHook); +ReactDebugTool.addHook(ReactComponentTreeHook); +var url = ExecutionEnvironment.canUseDOM && window.location.href || ''; +if (/[?&]react_perf\b/.test(url)) { + ReactDebugTool.beginProfiling(); } +module.exports = ReactDebugTool; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 265 */ +/* 241 */ /***/ (function(module, exports, __webpack_require__) { -var exports = module.exports = function SHA (algorithm) { - algorithm = algorithm.toLowerCase() +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - var Algorithm = exports[algorithm] - if (!Algorithm) throw new Error(algorithm + ' is not supported (we accept pull requests)') - return new Algorithm() + +var warning = __webpack_require__(3); + +if (process.env.NODE_ENV !== 'production') { + var processingChildContext = false; + + var warnInvalidSetState = function () { + process.env.NODE_ENV !== 'production' ? warning(!processingChildContext, 'setState(...): Cannot call setState() inside getChildContext()') : void 0; + }; } -exports.sha = __webpack_require__(436) -exports.sha1 = __webpack_require__(437) -exports.sha224 = __webpack_require__(438) -exports.sha256 = __webpack_require__(312) -exports.sha384 = __webpack_require__(439) -exports.sha512 = __webpack_require__(313) +var ReactInvalidSetStateWarningHook = { + onBeginProcessingChildContext: function () { + processingChildContext = true; + }, + onEndProcessingChildContext: function () { + processingChildContext = false; + }, + onSetState: function () { + warnInvalidSetState(); + } +}; +module.exports = ReactInvalidSetStateWarningHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 266 */ +/* 242 */ /***/ (function(module, exports, __webpack_require__) { -// Reference https://github.com/bitcoin/bips/blob/master/bip-0066.mediawiki -// Format: 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S] -// NOTE: SIGHASH byte ignored AND restricted, truncate before use +"use strict"; +/** + * Copyright 2016-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var Buffer = __webpack_require__(18).Buffer -function check (buffer) { - if (buffer.length < 8) return false - if (buffer.length > 72) return false - if (buffer[0] !== 0x30) return false - if (buffer[1] !== buffer.length - 2) return false - if (buffer[2] !== 0x02) return false - var lenR = buffer[3] - if (lenR === 0) return false - if (5 + lenR >= buffer.length) return false - if (buffer[4 + lenR] !== 0x02) return false +var history = []; - var lenS = buffer[5 + lenR] - if (lenS === 0) return false - if ((6 + lenR + lenS) !== buffer.length) return false +var ReactHostOperationHistoryHook = { + onHostOperation: function (operation) { + history.push(operation); + }, + clearHistory: function () { + if (ReactHostOperationHistoryHook._preventClearing) { + // Should only be used for tests. + return; + } - if (buffer[4] & 0x80) return false - if (lenR > 1 && (buffer[4] === 0x00) && !(buffer[5] & 0x80)) return false + history = []; + }, + getHistory: function () { + return history; + } +}; - if (buffer[lenR + 6] & 0x80) return false - if (lenS > 1 && (buffer[lenR + 6] === 0x00) && !(buffer[lenR + 7] & 0x80)) return false - return true -} +module.exports = ReactHostOperationHistoryHook; -function decode (buffer) { - if (buffer.length < 8) throw new Error('DER sequence length is too short') - if (buffer.length > 72) throw new Error('DER sequence length is too long') - if (buffer[0] !== 0x30) throw new Error('Expected DER sequence') - if (buffer[1] !== buffer.length - 2) throw new Error('DER sequence length is invalid') - if (buffer[2] !== 0x02) throw new Error('Expected DER integer') +/***/ }), +/* 243 */ +/***/ (function(module, exports, __webpack_require__) { - var lenR = buffer[3] - if (lenR === 0) throw new Error('R length is zero') - if (5 + lenR >= buffer.length) throw new Error('R length is too long') - if (buffer[4 + lenR] !== 0x02) throw new Error('Expected DER integer (2)') +"use strict"; - var lenS = buffer[5 + lenR] - if (lenS === 0) throw new Error('S length is zero') - if ((6 + lenR + lenS) !== buffer.length) throw new Error('S length is invalid') - if (buffer[4] & 0x80) throw new Error('R value is negative') - if (lenR > 1 && (buffer[4] === 0x00) && !(buffer[5] & 0x80)) throw new Error('R value excessively padded') +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ - if (buffer[lenR + 6] & 0x80) throw new Error('S value is negative') - if (lenS > 1 && (buffer[lenR + 6] === 0x00) && !(buffer[lenR + 7] & 0x80)) throw new Error('S value excessively padded') +var performance = __webpack_require__(244); - // non-BIP66 - extract R, S values - return { - r: buffer.slice(4, 4 + lenR), - s: buffer.slice(6 + lenR) - } +var performanceNow; + +/** + * Detect if we can use `window.performance.now()` and gracefully fallback to + * `Date.now()` if it doesn't exist. We need to support Firefox < 15 for now + * because of Facebook's testing infrastructure. + */ +if (performance.now) { + performanceNow = function performanceNow() { + return performance.now(); + }; +} else { + performanceNow = function performanceNow() { + return Date.now(); + }; } -/* - * Expects r and s to be positive DER integers. - * - * The DER format uses the most significant bit as a sign bit (& 0x80). - * If the significant bit is set AND the integer is positive, a 0x00 is prepended. +module.exports = performanceNow; + +/***/ }), +/* 244 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. * - * Examples: + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. * - * 0 => 0x00 - * 1 => 0x01 - * -1 => 0xff - * 127 => 0x7f - * -127 => 0x81 - * 128 => 0x0080 - * -128 => 0x80 - * 255 => 0x00ff - * -255 => 0xff01 - * 16300 => 0x3fac - * -16300 => 0xc054 - * 62300 => 0x00f35c - * -62300 => 0xff0ca4 -*/ -function encode (r, s) { - var lenR = r.length - var lenS = s.length - if (lenR === 0) throw new Error('R length is zero') - if (lenS === 0) throw new Error('S length is zero') - if (lenR > 33) throw new Error('R length is too long') - if (lenS > 33) throw new Error('S length is too long') - if (r[0] & 0x80) throw new Error('R value is negative') - if (s[0] & 0x80) throw new Error('S value is negative') - if (lenR > 1 && (r[0] === 0x00) && !(r[1] & 0x80)) throw new Error('R value excessively padded') - if (lenS > 1 && (s[0] === 0x00) && !(s[1] & 0x80)) throw new Error('S value excessively padded') + * @typechecks + */ - var signature = Buffer.allocUnsafe(6 + lenR + lenS) - // 0x30 [total-length] 0x02 [R-length] [R] 0x02 [S-length] [S] - signature[0] = 0x30 - signature[1] = signature.length - 2 - signature[2] = 0x02 - signature[3] = r.length - r.copy(signature, 4) - signature[4 + lenR] = 0x02 - signature[5 + lenR] = s.length - s.copy(signature, 6 + lenR) - return signature -} +var ExecutionEnvironment = __webpack_require__(13); -module.exports = { - check: check, - decode: decode, - encode: encode +var performance; + +if (ExecutionEnvironment.canUseDOM) { + performance = window.performance || window.msPerformance || window.webkitPerformance; } +module.exports = performance || {}; /***/ }), -/* 267 */ +/* 245 */ /***/ (function(module, exports, __webpack_require__) { -var hash = exports; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -hash.utils = __webpack_require__(69); -hash.common = __webpack_require__(238); -hash.sha = __webpack_require__(453); -hash.ripemd = __webpack_require__(457); -hash.hmac = __webpack_require__(458); -// Proxy hash functions to the main object -hash.sha1 = hash.sha.sha1; -hash.sha256 = hash.sha.sha256; -hash.sha224 = hash.sha.sha224; -hash.sha384 = hash.sha.sha384; -hash.sha512 = hash.sha.sha512; -hash.ripemd160 = hash.ripemd.ripemd160; +/** + * Module that is injectable into `EventPluginHub`, that specifies a + * deterministic ordering of `EventPlugin`s. A convenient way to reason about + * plugins, without having to package every one of them. This is better than + * having plugins be ordered in the same order that they are injected because + * that ordering would be influenced by the packaging order. + * `ResponderEventPlugin` must occur before `SimpleEventPlugin` so that + * preventing default on events is convenient in `SimpleEventPlugin` handlers. + */ + +var DefaultEventPluginOrder = ['ResponderEventPlugin', 'SimpleEventPlugin', 'TapEventPlugin', 'EnterLeaveEventPlugin', 'ChangeEventPlugin', 'SelectEventPlugin', 'BeforeInputEventPlugin']; + +module.exports = DefaultEventPluginOrder; /***/ }), -/* 268 */ +/* 246 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(global) { - -// compare and isBuffer taken from https://github.com/feross/buffer/blob/680e9e5e488f22aac27599a57dc844a6315928dd/index.js -// original notice: - -/*! - * The buffer module from node.js, for the browser. +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. * - * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> - * @license MIT */ -function compare(a, b) { - if (a === b) { - return 0; + + + +var EventPropagators = __webpack_require__(45); +var ReactDOMComponentTree = __webpack_require__(10); +var SyntheticMouseEvent = __webpack_require__(59); + +var eventTypes = { + mouseEnter: { + registrationName: 'onMouseEnter', + dependencies: ['topMouseOut', 'topMouseOver'] + }, + mouseLeave: { + registrationName: 'onMouseLeave', + dependencies: ['topMouseOut', 'topMouseOver'] } +}; - var x = a.length; - var y = b.length; +var EnterLeaveEventPlugin = { + eventTypes: eventTypes, - for (var i = 0, len = Math.min(x, y); i < len; ++i) { - if (a[i] !== b[i]) { - x = a[i]; - y = b[i]; - break; + /** + * For almost every interaction we care about, there will be both a top-level + * `mouseover` and `mouseout` event that occurs. Only use `mouseout` so that + * we do not extract duplicate events. However, moving the mouse into the + * browser from outside will not fire a `mouseout` event. In this case, we use + * the `mouseover` top-level event. + */ + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + if (topLevelType === 'topMouseOver' && (nativeEvent.relatedTarget || nativeEvent.fromElement)) { + return null; + } + if (topLevelType !== 'topMouseOut' && topLevelType !== 'topMouseOver') { + // Must not be a mouse in or mouse out - ignoring. + return null; } - } - if (x < y) { - return -1; - } - if (y < x) { - return 1; - } - return 0; -} -function isBuffer(b) { - if (global.Buffer && typeof global.Buffer.isBuffer === 'function') { - return global.Buffer.isBuffer(b); + var win; + if (nativeEventTarget.window === nativeEventTarget) { + // `nativeEventTarget` is probably a window object. + win = nativeEventTarget; + } else { + // TODO: Figure out why `ownerDocument` is sometimes undefined in IE8. + var doc = nativeEventTarget.ownerDocument; + if (doc) { + win = doc.defaultView || doc.parentWindow; + } else { + win = window; + } + } + + var from; + var to; + if (topLevelType === 'topMouseOut') { + from = targetInst; + var related = nativeEvent.relatedTarget || nativeEvent.toElement; + to = related ? ReactDOMComponentTree.getClosestInstanceFromNode(related) : null; + } else { + // Moving to a node from outside the window. + from = null; + to = targetInst; + } + + if (from === to) { + // Nothing pertains to our managed components. + return null; + } + + var fromNode = from == null ? win : ReactDOMComponentTree.getNodeFromInstance(from); + var toNode = to == null ? win : ReactDOMComponentTree.getNodeFromInstance(to); + + var leave = SyntheticMouseEvent.getPooled(eventTypes.mouseLeave, from, nativeEvent, nativeEventTarget); + leave.type = 'mouseleave'; + leave.target = fromNode; + leave.relatedTarget = toNode; + + var enter = SyntheticMouseEvent.getPooled(eventTypes.mouseEnter, to, nativeEvent, nativeEventTarget); + enter.type = 'mouseenter'; + enter.target = toNode; + enter.relatedTarget = fromNode; + + EventPropagators.accumulateEnterLeaveDispatches(leave, enter, from, to); + + return [leave, enter]; } - return !!(b != null && b._isBuffer); -} +}; -// based on node assert, original notice: +module.exports = EnterLeaveEventPlugin; -// http://wiki.commonjs.org/wiki/Unit_Testing/1.0 -// -// THIS IS NOT TESTED NOR LIKELY TO WORK OUTSIDE V8! -// -// Originally from narwhal.js (http://narwhaljs.org) -// Copyright (c) 2009 Thomas Robinson <280north.com> -// -// Permission is hereby granted, free of charge, to any person obtaining a copy -// of this software and associated documentation files (the 'Software'), to -// deal in the Software without restriction, including without limitation the -// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -// sell copies of the Software, and to permit persons to whom the Software is -// furnished to do so, subject to the following conditions: -// -// The above copyright notice and this permission notice shall be included in -// all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -// AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN -// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +/***/ }), +/* 247 */ +/***/ (function(module, exports, __webpack_require__) { -var util = __webpack_require__(469); -var hasOwn = Object.prototype.hasOwnProperty; -var pSlice = Array.prototype.slice; -var functionsHaveNames = (function () { - return function foo() {}.name === 'foo'; -}()); -function pToString (obj) { - return Object.prototype.toString.call(obj); -} -function isView(arrbuf) { - if (isBuffer(arrbuf)) { - return false; - } - if (typeof global.ArrayBuffer !== 'function') { - return false; - } - if (typeof ArrayBuffer.isView === 'function') { - return ArrayBuffer.isView(arrbuf); - } - if (!arrbuf) { - return false; - } - if (arrbuf instanceof DataView) { - return true; - } - if (arrbuf.buffer && arrbuf.buffer instanceof ArrayBuffer) { - return true; - } - return false; -} -// 1. The assert module provides functions that throw -// AssertionError's when particular conditions are not met. The -// assert module must conform to the following interface. +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var assert = module.exports = ok; -// 2. The AssertionError is defined in assert. -// new assert.AssertionError({ message: message, -// actual: actual, -// expected: expected }) -var regex = /\s*function\s+([^\(\s]*)\s*/; -// based on https://github.com/ljharb/function.prototype.name/blob/adeeeec8bfcc6068b187d7d9fb3d5bb1d3a30899/implementation.js -function getName(func) { - if (!util.isFunction(func)) { - return; - } - if (functionsHaveNames) { - return func.name; - } - var str = func.toString(); - var match = str.match(regex); - return match && match[1]; -} -assert.AssertionError = function AssertionError(options) { - this.name = 'AssertionError'; - this.actual = options.actual; - this.expected = options.expected; - this.operator = options.operator; - if (options.message) { - this.message = options.message; - this.generatedMessage = false; - } else { - this.message = getMessage(this); - this.generatedMessage = true; - } - var stackStartFunction = options.stackStartFunction || fail; - if (Error.captureStackTrace) { - Error.captureStackTrace(this, stackStartFunction); - } else { - // non v8 browsers so we can have a stacktrace - var err = new Error(); - if (err.stack) { - var out = err.stack; +var DOMProperty = __webpack_require__(28); - // try to strip useless frames - var fn_name = getName(stackStartFunction); - var idx = out.indexOf('\n' + fn_name); - if (idx >= 0) { - // once we have located the function frame - // we need to strip out everything before it (and its line) - var next_line = out.indexOf('\n', idx + 1); - out = out.substring(next_line + 1); +var MUST_USE_PROPERTY = DOMProperty.injection.MUST_USE_PROPERTY; +var HAS_BOOLEAN_VALUE = DOMProperty.injection.HAS_BOOLEAN_VALUE; +var HAS_NUMERIC_VALUE = DOMProperty.injection.HAS_NUMERIC_VALUE; +var HAS_POSITIVE_NUMERIC_VALUE = DOMProperty.injection.HAS_POSITIVE_NUMERIC_VALUE; +var HAS_OVERLOADED_BOOLEAN_VALUE = DOMProperty.injection.HAS_OVERLOADED_BOOLEAN_VALUE; + +var HTMLDOMPropertyConfig = { + isCustomAttribute: RegExp.prototype.test.bind(new RegExp('^(data|aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$')), + Properties: { + /** + * Standard Properties + */ + accept: 0, + acceptCharset: 0, + accessKey: 0, + action: 0, + allowFullScreen: HAS_BOOLEAN_VALUE, + allowTransparency: 0, + alt: 0, + // specifies target context for links with `preload` type + as: 0, + async: HAS_BOOLEAN_VALUE, + autoComplete: 0, + // autoFocus is polyfilled/normalized by AutoFocusUtils + // autoFocus: HAS_BOOLEAN_VALUE, + autoPlay: HAS_BOOLEAN_VALUE, + capture: HAS_BOOLEAN_VALUE, + cellPadding: 0, + cellSpacing: 0, + charSet: 0, + challenge: 0, + checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + cite: 0, + classID: 0, + className: 0, + cols: HAS_POSITIVE_NUMERIC_VALUE, + colSpan: 0, + content: 0, + contentEditable: 0, + contextMenu: 0, + controls: HAS_BOOLEAN_VALUE, + coords: 0, + crossOrigin: 0, + data: 0, // For `<object />` acts as `src`. + dateTime: 0, + 'default': HAS_BOOLEAN_VALUE, + defer: HAS_BOOLEAN_VALUE, + dir: 0, + disabled: HAS_BOOLEAN_VALUE, + download: HAS_OVERLOADED_BOOLEAN_VALUE, + draggable: 0, + encType: 0, + form: 0, + formAction: 0, + formEncType: 0, + formMethod: 0, + formNoValidate: HAS_BOOLEAN_VALUE, + formTarget: 0, + frameBorder: 0, + headers: 0, + height: 0, + hidden: HAS_BOOLEAN_VALUE, + high: 0, + href: 0, + hrefLang: 0, + htmlFor: 0, + httpEquiv: 0, + icon: 0, + id: 0, + inputMode: 0, + integrity: 0, + is: 0, + keyParams: 0, + keyType: 0, + kind: 0, + label: 0, + lang: 0, + list: 0, + loop: HAS_BOOLEAN_VALUE, + low: 0, + manifest: 0, + marginHeight: 0, + marginWidth: 0, + max: 0, + maxLength: 0, + media: 0, + mediaGroup: 0, + method: 0, + min: 0, + minLength: 0, + // Caution; `option.selected` is not updated if `select.multiple` is + // disabled with `removeAttribute`. + multiple: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + muted: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + name: 0, + nonce: 0, + noValidate: HAS_BOOLEAN_VALUE, + open: HAS_BOOLEAN_VALUE, + optimum: 0, + pattern: 0, + placeholder: 0, + playsInline: HAS_BOOLEAN_VALUE, + poster: 0, + preload: 0, + profile: 0, + radioGroup: 0, + readOnly: HAS_BOOLEAN_VALUE, + referrerPolicy: 0, + rel: 0, + required: HAS_BOOLEAN_VALUE, + reversed: HAS_BOOLEAN_VALUE, + role: 0, + rows: HAS_POSITIVE_NUMERIC_VALUE, + rowSpan: HAS_NUMERIC_VALUE, + sandbox: 0, + scope: 0, + scoped: HAS_BOOLEAN_VALUE, + scrolling: 0, + seamless: HAS_BOOLEAN_VALUE, + selected: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, + shape: 0, + size: HAS_POSITIVE_NUMERIC_VALUE, + sizes: 0, + span: HAS_POSITIVE_NUMERIC_VALUE, + spellCheck: 0, + src: 0, + srcDoc: 0, + srcLang: 0, + srcSet: 0, + start: HAS_NUMERIC_VALUE, + step: 0, + style: 0, + summary: 0, + tabIndex: 0, + target: 0, + title: 0, + // Setting .type throws on non-<input> tags + type: 0, + useMap: 0, + value: 0, + width: 0, + wmode: 0, + wrap: 0, + + /** + * RDFa Properties + */ + about: 0, + datatype: 0, + inlist: 0, + prefix: 0, + // property is also supported for OpenGraph in meta tags. + property: 0, + resource: 0, + 'typeof': 0, + vocab: 0, + + /** + * Non-standard Properties + */ + // autoCapitalize and autoCorrect are supported in Mobile Safari for + // keyboard hints. + autoCapitalize: 0, + autoCorrect: 0, + // autoSave allows WebKit/Blink to persist values of input fields on page reloads + autoSave: 0, + // color is for Safari mask-icon link + color: 0, + // itemProp, itemScope, itemType are for + // Microdata support. See http://schema.org/docs/gs.html + itemProp: 0, + itemScope: HAS_BOOLEAN_VALUE, + itemType: 0, + // itemID and itemRef are for Microdata support as well but + // only specified in the WHATWG spec document. See + // https://html.spec.whatwg.org/multipage/microdata.html#microdata-dom-api + itemID: 0, + itemRef: 0, + // results show looking glass icon and recent searches on input + // search fields in WebKit/Blink + results: 0, + // IE-only attribute that specifies security restrictions on an iframe + // as an alternative to the sandbox attribute on IE<10 + security: 0, + // IE-only attribute that controls focus behavior + unselectable: 0 + }, + DOMAttributeNames: { + acceptCharset: 'accept-charset', + className: 'class', + htmlFor: 'for', + httpEquiv: 'http-equiv' + }, + DOMPropertyNames: {}, + DOMMutationMethods: { + value: function (node, value) { + if (value == null) { + return node.removeAttribute('value'); } - this.stack = out; + // Number inputs get special treatment due to some edge cases in + // Chrome. Let everything else assign the value attribute as normal. + // https://github.com/facebook/react/issues/7253#issuecomment-236074326 + if (node.type !== 'number' || node.hasAttribute('value') === false) { + node.setAttribute('value', '' + value); + } else if (node.validity && !node.validity.badInput && node.ownerDocument.activeElement !== node) { + // Don't assign an attribute if validation reports bad + // input. Chrome will clear the value. Additionally, don't + // operate on inputs that have focus, otherwise Chrome might + // strip off trailing decimal places and cause the user's + // cursor position to jump to the beginning of the input. + // + // In ReactDOMInput, we have an onBlur event that will trigger + // this function again when focus is lost. + node.setAttribute('value', '' + value); + } } } }; -// assert.AssertionError instanceof Error -util.inherits(assert.AssertionError, Error); +module.exports = HTMLDOMPropertyConfig; -function truncate(s, n) { - if (typeof s === 'string') { - return s.length < n ? s : s.slice(0, n); - } else { - return s; - } -} -function inspect(something) { - if (functionsHaveNames || !util.isFunction(something)) { - return util.inspect(something); - } - var rawname = getName(something); - var name = rawname ? ': ' + rawname : ''; - return '[Function' + name + ']'; -} -function getMessage(self) { - return truncate(inspect(self.actual), 128) + ' ' + - self.operator + ' ' + - truncate(inspect(self.expected), 128); -} +/***/ }), +/* 248 */ +/***/ (function(module, exports, __webpack_require__) { -// At present only the three keys mentioned above are used and -// understood by the spec. Implementations or sub modules can pass -// other keys to the AssertionError's constructor - they will be -// ignored. +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -// 3. All of the following functions must throw an AssertionError -// when a corresponding condition is not met, with a message that -// may be undefined if not provided. All assertion methods provide -// both the actual and expected values to the assertion error for -// display purposes. -function fail(actual, expected, message, operator, stackStartFunction) { - throw new assert.AssertionError({ - message: message, - actual: actual, - expected: expected, - operator: operator, - stackStartFunction: stackStartFunction - }); -} -// EXTENSION! allows for well behaved errors defined elsewhere. -assert.fail = fail; +var DOMChildrenOperations = __webpack_require__(82); +var ReactDOMIDOperations = __webpack_require__(253); -// 4. Pure assertion tests whether a value is truthy, as determined -// by !!guard. -// assert.ok(guard, message_opt); -// This statement is equivalent to assert.equal(true, !!guard, -// message_opt);. To test strictly for the value true, use -// assert.strictEqual(true, guard, message_opt);. +/** + * Abstracts away all functionality of the reconciler that requires knowledge of + * the browser context. TODO: These callers should be refactored to avoid the + * need for this injection. + */ +var ReactComponentBrowserEnvironment = { + processChildrenUpdates: ReactDOMIDOperations.dangerouslyProcessChildrenUpdates, -function ok(value, message) { - if (!value) fail(value, true, message, '==', assert.ok); -} -assert.ok = ok; + replaceNodeWithMarkup: DOMChildrenOperations.dangerouslyReplaceNodeWithMarkup +}; -// 5. The equality assertion tests shallow, coercive equality with -// ==. -// assert.equal(actual, expected, message_opt); +module.exports = ReactComponentBrowserEnvironment; -assert.equal = function equal(actual, expected, message) { - if (actual != expected) fail(actual, expected, message, '==', assert.equal); -}; +/***/ }), +/* 249 */ +/***/ (function(module, exports, __webpack_require__) { -// 6. The non-equality assertion tests for whether two objects are not equal -// with != assert.notEqual(actual, expected, message_opt); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -assert.notEqual = function notEqual(actual, expected, message) { - if (actual == expected) { - fail(actual, expected, message, '!=', assert.notEqual); - } -}; -// 7. The equivalence assertion tests a deep equality relation. -// assert.deepEqual(actual, expected, message_opt); -assert.deepEqual = function deepEqual(actual, expected, message) { - if (!_deepEqual(actual, expected, false)) { - fail(actual, expected, message, 'deepEqual', assert.deepEqual); - } -}; +var _prodInvariant = __webpack_require__(5); -assert.deepStrictEqual = function deepStrictEqual(actual, expected, message) { - if (!_deepEqual(actual, expected, true)) { - fail(actual, expected, message, 'deepStrictEqual', assert.deepStrictEqual); +var DOMLazyTree = __webpack_require__(39); +var ExecutionEnvironment = __webpack_require__(13); + +var createNodesFromMarkup = __webpack_require__(250); +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); + +var Danger = { + /** + * Replaces a node with a string of markup at its current position within its + * parent. The markup must render into a single root node. + * + * @param {DOMElement} oldChild Child node to replace. + * @param {string} markup Markup to render in place of the child node. + * @internal + */ + dangerouslyReplaceNodeWithMarkup: function (oldChild, markup) { + !ExecutionEnvironment.canUseDOM ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot render markup in a worker thread. Make sure `window` and `document` are available globally before requiring React when unit testing or use ReactDOMServer.renderToString() for server rendering.') : _prodInvariant('56') : void 0; + !markup ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Missing markup.') : _prodInvariant('57') : void 0; + !(oldChild.nodeName !== 'HTML') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'dangerouslyReplaceNodeWithMarkup(...): Cannot replace markup of the <html> node. This is because browser quirks make this unreliable and/or slow. If you want to render to the root you must use server rendering. See ReactDOMServer.renderToString().') : _prodInvariant('58') : void 0; + + if (typeof markup === 'string') { + var newChild = createNodesFromMarkup(markup, emptyFunction)[0]; + oldChild.parentNode.replaceChild(newChild, oldChild); + } else { + DOMLazyTree.replaceChildWithTree(oldChild, markup); + } } }; -function _deepEqual(actual, expected, strict, memos) { - // 7.1. All identical values are equivalent, as determined by ===. - if (actual === expected) { - return true; - } else if (isBuffer(actual) && isBuffer(expected)) { - return compare(actual, expected) === 0; +module.exports = Danger; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - // 7.2. If the expected value is a Date object, the actual value is - // equivalent if it is also a Date object that refers to the same time. - } else if (util.isDate(actual) && util.isDate(expected)) { - return actual.getTime() === expected.getTime(); +/***/ }), +/* 250 */ +/***/ (function(module, exports, __webpack_require__) { - // 7.3 If the expected value is a RegExp object, the actual value is - // equivalent if it is also a RegExp object with the same source and - // properties (`global`, `multiline`, `lastIndex`, `ignoreCase`). - } else if (util.isRegExp(actual) && util.isRegExp(expected)) { - return actual.source === expected.source && - actual.global === expected.global && - actual.multiline === expected.multiline && - actual.lastIndex === expected.lastIndex && - actual.ignoreCase === expected.ignoreCase; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { - // 7.4. Other pairs that do not both pass typeof value == 'object', - // equivalence is determined by ==. - } else if ((actual === null || typeof actual !== 'object') && - (expected === null || typeof expected !== 'object')) { - return strict ? actual === expected : actual == expected; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ - // If both values are instances of typed arrays, wrap their underlying - // ArrayBuffers in a Buffer each to increase performance - // This optimization requires the arrays to have the same type as checked by - // Object.prototype.toString (aka pToString). Never perform binary - // comparisons for Float*Arrays, though, since e.g. +0 === -0 but their - // bit patterns are not identical. - } else if (isView(actual) && isView(expected) && - pToString(actual) === pToString(expected) && - !(actual instanceof Float32Array || - actual instanceof Float64Array)) { - return compare(new Uint8Array(actual.buffer), - new Uint8Array(expected.buffer)) === 0; +/*eslint-disable fb-www/unsafe-html*/ - // 7.5 For all other Object pairs, including Array objects, equivalence is - // determined by having the same number of owned properties (as verified - // with Object.prototype.hasOwnProperty.call), the same set of keys - // (although not necessarily the same order), equivalent values for every - // corresponding key, and an identical 'prototype' property. Note: this - // accounts for both named and indexed properties on Arrays. - } else if (isBuffer(actual) !== isBuffer(expected)) { - return false; - } else { - memos = memos || {actual: [], expected: []}; +var ExecutionEnvironment = __webpack_require__(13); - var actualIndex = memos.actual.indexOf(actual); - if (actualIndex !== -1) { - if (actualIndex === memos.expected.indexOf(expected)) { - return true; - } - } +var createArrayFromMixed = __webpack_require__(251); +var getMarkupWrap = __webpack_require__(252); +var invariant = __webpack_require__(2); - memos.actual.push(actual); - memos.expected.push(expected); +/** + * Dummy container used to render all markup. + */ +var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; - return objEquiv(actual, expected, strict, memos); - } -} +/** + * Pattern used by `getNodeName`. + */ +var nodeNamePattern = /^\s*<(\w+)/; -function isArguments(object) { - return Object.prototype.toString.call(object) == '[object Arguments]'; +/** + * Extracts the `nodeName` of the first element in a string of markup. + * + * @param {string} markup String of markup. + * @return {?string} Node name of the supplied markup. + */ +function getNodeName(markup) { + var nodeNameMatch = markup.match(nodeNamePattern); + return nodeNameMatch && nodeNameMatch[1].toLowerCase(); } -function objEquiv(a, b, strict, actualVisitedObjects) { - if (a === null || a === undefined || b === null || b === undefined) - return false; - // if one is a primitive, the other must be same - if (util.isPrimitive(a) || util.isPrimitive(b)) - return a === b; - if (strict && Object.getPrototypeOf(a) !== Object.getPrototypeOf(b)) - return false; - var aIsArgs = isArguments(a); - var bIsArgs = isArguments(b); - if ((aIsArgs && !bIsArgs) || (!aIsArgs && bIsArgs)) - return false; - if (aIsArgs) { - a = pSlice.call(a); - b = pSlice.call(b); - return _deepEqual(a, b, strict); +/** + * Creates an array containing the nodes rendered from the supplied markup. The + * optionally supplied `handleScript` function will be invoked once for each + * <script> element that is rendered. If no `handleScript` function is supplied, + * an exception is thrown if any <script> elements are rendered. + * + * @param {string} markup A string of valid HTML markup. + * @param {?function} handleScript Invoked once for each rendered <script>. + * @return {array<DOMElement|DOMTextNode>} An array of rendered nodes. + */ +function createNodesFromMarkup(markup, handleScript) { + var node = dummyNode; + !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup dummy not initialized') : invariant(false) : void 0; + var nodeName = getNodeName(markup); + + var wrap = nodeName && getMarkupWrap(nodeName); + if (wrap) { + node.innerHTML = wrap[1] + markup + wrap[2]; + + var wrapDepth = wrap[0]; + while (wrapDepth--) { + node = node.lastChild; + } + } else { + node.innerHTML = markup; } - var ka = objectKeys(a); - var kb = objectKeys(b); - var key, i; - // having the same number of owned properties (keys incorporates - // hasOwnProperty) - if (ka.length !== kb.length) - return false; - //the same set of keys (although not necessarily the same order), - ka.sort(); - kb.sort(); - //~~~cheap key test - for (i = ka.length - 1; i >= 0; i--) { - if (ka[i] !== kb[i]) - return false; + + var scripts = node.getElementsByTagName('script'); + if (scripts.length) { + !handleScript ? process.env.NODE_ENV !== 'production' ? invariant(false, 'createNodesFromMarkup(...): Unexpected <script> element rendered.') : invariant(false) : void 0; + createArrayFromMixed(scripts).forEach(handleScript); } - //equivalent values for every corresponding key, and - //~~~possibly expensive deep test - for (i = ka.length - 1; i >= 0; i--) { - key = ka[i]; - if (!_deepEqual(a[key], b[key], strict, actualVisitedObjects)) - return false; + + var nodes = Array.from(node.childNodes); + while (node.lastChild) { + node.removeChild(node.lastChild); } - return true; + return nodes; } -// 8. The non-equivalence assertion tests for any deep inequality. -// assert.notDeepEqual(actual, expected, message_opt); +module.exports = createNodesFromMarkup; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -assert.notDeepEqual = function notDeepEqual(actual, expected, message) { - if (_deepEqual(actual, expected, false)) { - fail(actual, expected, message, 'notDeepEqual', assert.notDeepEqual); - } -}; +/***/ }), +/* 251 */ +/***/ (function(module, exports, __webpack_require__) { -assert.notDeepStrictEqual = notDeepStrictEqual; -function notDeepStrictEqual(actual, expected, message) { - if (_deepEqual(actual, expected, true)) { - fail(actual, expected, message, 'notDeepStrictEqual', notDeepStrictEqual); - } -} +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ -// 9. The strict equality assertion tests strict equality, as determined by ===. -// assert.strictEqual(actual, expected, message_opt); +var invariant = __webpack_require__(2); -assert.strictEqual = function strictEqual(actual, expected, message) { - if (actual !== expected) { - fail(actual, expected, message, '===', assert.strictEqual); - } -}; +/** + * Convert array-like objects to arrays. + * + * This API assumes the caller knows the contents of the data type. For less + * well defined inputs use createArrayFromMixed. + * + * @param {object|function|filelist} obj + * @return {array} + */ +function toArray(obj) { + var length = obj.length; -// 10. The strict non-equality assertion tests for strict inequality, as -// determined by !==. assert.notStrictEqual(actual, expected, message_opt); + // Some browsers builtin objects can report typeof 'function' (e.g. NodeList + // in old versions of Safari). + !(!Array.isArray(obj) && (typeof obj === 'object' || typeof obj === 'function')) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Array-like object expected') : invariant(false) : void 0; -assert.notStrictEqual = function notStrictEqual(actual, expected, message) { - if (actual === expected) { - fail(actual, expected, message, '!==', assert.notStrictEqual); - } -}; + !(typeof length === 'number') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object needs a length property') : invariant(false) : void 0; -function expectedException(actual, expected) { - if (!actual || !expected) { - return false; - } + !(length === 0 || length - 1 in obj) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object should have keys for indices') : invariant(false) : void 0; - if (Object.prototype.toString.call(expected) == '[object RegExp]') { - return expected.test(actual); - } + !(typeof obj.callee !== 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'toArray: Object can\'t be `arguments`. Use rest params ' + '(function(...args) {}) or Array.from() instead.') : invariant(false) : void 0; - try { - if (actual instanceof expected) { - return true; + // Old IE doesn't give collections access to hasOwnProperty. Assume inputs + // without method will throw during the slice call and skip straight to the + // fallback. + if (obj.hasOwnProperty) { + try { + return Array.prototype.slice.call(obj); + } catch (e) { + // IE < 9 does not support Array#slice on collections objects } - } catch (e) { - // Ignore. The instanceof check doesn't work for arrow functions. } - if (Error.isPrototypeOf(expected)) { - return false; + // Fall back to copying key by key. This assumes all keys have a value, + // so will not preserve sparsely populated inputs. + var ret = Array(length); + for (var ii = 0; ii < length; ii++) { + ret[ii] = obj[ii]; } + return ret; +} - return expected.call({}, actual) === true; +/** + * Perform a heuristic test to determine if an object is "array-like". + * + * A monk asked Joshu, a Zen master, "Has a dog Buddha nature?" + * Joshu replied: "Mu." + * + * This function determines if its argument has "array nature": it returns + * true if the argument is an actual array, an `arguments' object, or an + * HTMLCollection (e.g. node.childNodes or node.getElementsByTagName()). + * + * It will return false for other array-like objects like Filelist. + * + * @param {*} obj + * @return {boolean} + */ +function hasArrayNature(obj) { + return ( + // not null/false + !!obj && ( + // arrays are objects, NodeLists are functions in Safari + typeof obj == 'object' || typeof obj == 'function') && + // quacks like an array + 'length' in obj && + // not window + !('setInterval' in obj) && + // no DOM node should be considered an array-like + // a 'select' element has 'length' and 'item' properties on IE8 + typeof obj.nodeType != 'number' && ( + // a real array + Array.isArray(obj) || + // arguments + 'callee' in obj || + // HTMLCollection/NodeList + 'item' in obj) + ); } -function _tryBlock(block) { - var error; - try { - block(); - } catch (e) { - error = e; +/** + * Ensure that the argument is an array by wrapping it in an array if it is not. + * Creates a copy of the argument if it is already an array. + * + * This is mostly useful idiomatically: + * + * var createArrayFromMixed = require('createArrayFromMixed'); + * + * function takesOneOrMoreThings(things) { + * things = createArrayFromMixed(things); + * ... + * } + * + * This allows you to treat `things' as an array, but accept scalars in the API. + * + * If you need to convert an array-like object, like `arguments`, into an array + * use toArray instead. + * + * @param {*} obj + * @return {array} + */ +function createArrayFromMixed(obj) { + if (!hasArrayNature(obj)) { + return [obj]; + } else if (Array.isArray(obj)) { + return obj.slice(); + } else { + return toArray(obj); } - return error; } -function _throws(shouldThrow, block, expected, message) { - var actual; +module.exports = createArrayFromMixed; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - if (typeof block !== 'function') { - throw new TypeError('"block" argument must be a function'); - } +/***/ }), +/* 252 */ +/***/ (function(module, exports, __webpack_require__) { - if (typeof expected === 'string') { - message = expected; - expected = null; - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) { - actual = _tryBlock(block); +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - message = (expected && expected.name ? ' (' + expected.name + ').' : '.') + - (message ? ' ' + message : '.'); +/*eslint-disable fb-www/unsafe-html */ - if (shouldThrow && !actual) { - fail(actual, expected, 'Missing expected exception' + message); - } +var ExecutionEnvironment = __webpack_require__(13); - var userProvidedMessage = typeof message === 'string'; - var isUnwantedException = !shouldThrow && util.isError(actual); - var isUnexpectedException = !shouldThrow && actual && !expected; +var invariant = __webpack_require__(2); - if ((isUnwantedException && - userProvidedMessage && - expectedException(actual, expected)) || - isUnexpectedException) { - fail(actual, expected, 'Got unwanted exception' + message); - } +/** + * Dummy container used to detect which wraps are necessary. + */ +var dummyNode = ExecutionEnvironment.canUseDOM ? document.createElement('div') : null; - if ((shouldThrow && actual && expected && - !expectedException(actual, expected)) || (!shouldThrow && actual)) { - throw actual; - } -} +/** + * Some browsers cannot use `innerHTML` to render certain elements standalone, + * so we wrap them, render the wrapped nodes, then extract the desired node. + * + * In IE8, certain elements cannot render alone, so wrap all elements ('*'). + */ -// 11. Expected to throw an error: -// assert.throws(block, Error_opt, message_opt); +var shouldWrap = {}; -assert.throws = function(block, /*optional*/error, /*optional*/message) { - _throws(true, block, error, message); -}; +var selectWrap = [1, '<select multiple="true">', '</select>']; +var tableWrap = [1, '<table>', '</table>']; +var trWrap = [3, '<table><tbody><tr>', '</tr></tbody></table>']; -// EXTENSION! This is annoying to write outside this module. -assert.doesNotThrow = function(block, /*optional*/error, /*optional*/message) { - _throws(false, block, error, message); +var svgWrap = [1, '<svg xmlns="http://www.w3.org/2000/svg">', '</svg>']; + +var markupWrap = { + '*': [1, '?<div>', '</div>'], + + 'area': [1, '<map>', '</map>'], + 'col': [2, '<table><tbody></tbody><colgroup>', '</colgroup></table>'], + 'legend': [1, '<fieldset>', '</fieldset>'], + 'param': [1, '<object>', '</object>'], + 'tr': [2, '<table><tbody>', '</tbody></table>'], + + 'optgroup': selectWrap, + 'option': selectWrap, + + 'caption': tableWrap, + 'colgroup': tableWrap, + 'tbody': tableWrap, + 'tfoot': tableWrap, + 'thead': tableWrap, + + 'td': trWrap, + 'th': trWrap }; -assert.ifError = function(err) { if (err) throw err; }; +// Initialize the SVG elements since we know they'll always need to be wrapped +// consistently. If they are created inside a <div> they will be initialized in +// the wrong namespace (and will not display). +var svgElements = ['circle', 'clipPath', 'defs', 'ellipse', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'text', 'tspan']; +svgElements.forEach(function (nodeName) { + markupWrap[nodeName] = svgWrap; + shouldWrap[nodeName] = true; +}); -var objectKeys = Object.keys || function (obj) { - var keys = []; - for (var key in obj) { - if (hasOwn.call(obj, key)) keys.push(key); +/** + * Gets the markup wrap configuration for the supplied `nodeName`. + * + * NOTE: This lazily detects which wraps are necessary for the current browser. + * + * @param {string} nodeName Lowercase `nodeName`. + * @return {?array} Markup wrap configuration, if applicable. + */ +function getMarkupWrap(nodeName) { + !!!dummyNode ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Markup wrapping node not initialized') : invariant(false) : void 0; + if (!markupWrap.hasOwnProperty(nodeName)) { + nodeName = '*'; } - return keys; -}; + if (!shouldWrap.hasOwnProperty(nodeName)) { + if (nodeName === '*') { + dummyNode.innerHTML = '<link />'; + } else { + dummyNode.innerHTML = '<' + nodeName + '></' + nodeName + '>'; + } + shouldWrap[nodeName] = !dummyNode.firstChild; + } + return shouldWrap[nodeName] ? markupWrap[nodeName] : null; +} -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(67))) +module.exports = getMarkupWrap; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 269 */ +/* 253 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {/* - * Obtained from https://github.com/bitcoinjs/bitcoinjs-lib/blob/master/src/crypto.js - * 2017/07/25: No ripemd160 in SJCL, so resorted to this +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * */ -var createHash = __webpack_require__(71); - -function ripemd160(buffer) { - return createHash('rmd160').update(buffer).digest('hex'); -} - -function sha1(buffer) { - return createHash('sha1').update(buffer).digest('hex'); -} - -function sha256(buffer) { - return createHash('sha256').update(buffer).digest('hex'); -} -function sha256x2(buffer) { - return sha256(Buffer.from(sha256(buffer), 'hex')); -} -function hash160(buffer) { - const sha = sha256(buffer); - const hash160 = ripemd160(Buffer.from(sha, 'hex')); - return hash160; -} +var DOMChildrenOperations = __webpack_require__(82); +var ReactDOMComponentTree = __webpack_require__(10); -module.exports = { - hash160: hash160, - ripemd160: ripemd160, - sha1: sha1, - sha256: sha256, - sha256x2: sha256x2 +/** + * Operations used to process updates to DOM nodes. + */ +var ReactDOMIDOperations = { + /** + * Updates a component's children by processing a series of updates. + * + * @param {array<object>} updates List of update configurations. + * @internal + */ + dangerouslyProcessChildrenUpdates: function (parentInst, updates) { + var node = ReactDOMComponentTree.getNodeFromInstance(parentInst); + DOMChildrenOperations.processUpdates(node, updates); + } }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + +module.exports = ReactDOMIDOperations; /***/ }), -/* 270 */ +/* 254 */ /***/ (function(module, exports, __webpack_require__) { -var ciphers = __webpack_require__(484) -exports.createCipher = exports.Cipher = ciphers.createCipher -exports.createCipheriv = exports.Cipheriv = ciphers.createCipheriv -var deciphers = __webpack_require__(486) -exports.createDecipher = exports.Decipher = deciphers.createDecipher -exports.createDecipheriv = exports.Decipheriv = deciphers.createDecipheriv -var modes = __webpack_require__(252) -function getCiphers () { - return Object.keys(modes) -} -exports.listCiphers = exports.getCiphers = getCiphers +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ +/* global hasOwnProperty:true */ -/***/ }), -/* 271 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var AutoFocusUtils = __webpack_require__(255); +var CSSPropertyOperations = __webpack_require__(256); +var DOMLazyTree = __webpack_require__(39); +var DOMNamespaces = __webpack_require__(83); +var DOMProperty = __webpack_require__(28); +var DOMPropertyOperations = __webpack_require__(138); +var EventPluginHub = __webpack_require__(46); +var EventPluginRegistry = __webpack_require__(57); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactDOMComponentFlags = __webpack_require__(126); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMInput = __webpack_require__(266); +var ReactDOMOption = __webpack_require__(267); +var ReactDOMSelect = __webpack_require__(140); +var ReactDOMTextarea = __webpack_require__(268); +var ReactInstrumentation = __webpack_require__(19); +var ReactMultiChild = __webpack_require__(269); +var ReactServerRenderingTransaction = __webpack_require__(278); + +var emptyFunction = __webpack_require__(18); +var escapeTextContentForBrowser = __webpack_require__(61); +var invariant = __webpack_require__(2); +var isEventSupported = __webpack_require__(80); +var shallowEqual = __webpack_require__(87); +var inputValueTracking = __webpack_require__(132); +var validateDOMNesting = __webpack_require__(91); +var warning = __webpack_require__(3); -exports.utils = __webpack_require__(488); -exports.Cipher = __webpack_require__(489); -exports.DES = __webpack_require__(490); -exports.CBC = __webpack_require__(491); -exports.EDE = __webpack_require__(492); +var Flags = ReactDOMComponentFlags; +var deleteListener = EventPluginHub.deleteListener; +var getNode = ReactDOMComponentTree.getNodeFromInstance; +var listenTo = ReactBrowserEventEmitter.listenTo; +var registrationNameModules = EventPluginRegistry.registrationNameModules; +// For quickly matching children type, to test if can be treated as content. +var CONTENT_TYPES = { string: true, number: true }; -/***/ }), -/* 272 */ -/***/ (function(module, exports, __webpack_require__) { +var STYLE = 'style'; +var HTML = '__html'; +var RESERVED_PROPS = { + children: null, + dangerouslySetInnerHTML: null, + suppressContentEditableWarning: null +}; -/* WEBPACK VAR INJECTION */(function(Buffer) {var bn = __webpack_require__(23); -var randomBytes = __webpack_require__(115); -module.exports = crt; -function blind(priv) { - var r = getr(priv); - var blinder = r.toRed(bn.mont(priv.modulus)) - .redPow(new bn(priv.publicExponent)).fromRed(); - return { - blinder: blinder, - unblinder:r.invm(priv.modulus) - }; -} -function crt(msg, priv) { - var blinds = blind(priv); - var len = priv.modulus.byteLength(); - var mod = bn.mont(priv.modulus); - var blinded = new bn(msg).mul(blinds.blinder).umod(priv.modulus); - var c1 = blinded.toRed(bn.mont(priv.prime1)); - var c2 = blinded.toRed(bn.mont(priv.prime2)); - var qinv = priv.coefficient; - var p = priv.prime1; - var q = priv.prime2; - var m1 = c1.redPow(priv.exponent1); - var m2 = c2.redPow(priv.exponent2); - m1 = m1.fromRed(); - m2 = m2.fromRed(); - var h = m1.isub(m2).imul(qinv).umod(p); - h.imul(q); - m2.iadd(h); - return new Buffer(m2.imul(blinds.unblinder).umod(priv.modulus).toArray(false, len)); -} -crt.getr = getr; -function getr(priv) { - var len = priv.modulus.byteLength(); - var r = new bn(randomBytes(len)); - while (r.cmp(priv.modulus) >= 0 || !r.umod(priv.prime1) || !r.umod(priv.prime2)) { - r = new bn(randomBytes(len)); - } - return r; -} - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) - -/***/ }), -/* 273 */ -/***/ (function(module, exports) { - -var types = { - Array: function (value) { return value !== null && value !== undefined && value.constructor === Array }, - Boolean: function (value) { return typeof value === 'boolean' }, - Function: function (value) { return typeof value === 'function' }, - Nil: function (value) { return value === undefined || value === null }, - Number: function (value) { return typeof value === 'number' }, - Object: function (value) { return typeof value === 'object' }, - String: function (value) { return typeof value === 'string' }, - '': function () { return true } -} - -// TODO: deprecate -types.Null = types.Nil - -for (var typeName in types) { - types[typeName].toJSON = function (t) { - return t - }.bind(null, typeName) -} - -module.exports = types - - -/***/ }), -/* 274 */ -/***/ (function(module, exports, __webpack_require__) { - -var Buffer = __webpack_require__(18).Buffer -var bcrypto = __webpack_require__(116) -var bscript = __webpack_require__(35) -var bufferutils = __webpack_require__(352) -var opcodes = __webpack_require__(37) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) -var varuint = __webpack_require__(255) - -function varSliceSize (someScript) { - var length = someScript.length - - return varuint.encodingLength(length) + length -} - -function vectorSize (someVector) { - var length = someVector.length - - return varuint.encodingLength(length) + someVector.reduce(function (sum, witness) { - return sum + varSliceSize(witness) - }, 0) -} - -function Transaction () { - this.version = 1 - this.locktime = 0 - this.ins = [] - this.outs = [] -} - -Transaction.DEFAULT_SEQUENCE = 0xffffffff -Transaction.SIGHASH_ALL = 0x01 -Transaction.SIGHASH_NONE = 0x02 -Transaction.SIGHASH_SINGLE = 0x03 -Transaction.SIGHASH_ANYONECANPAY = 0x80 -Transaction.ADVANCED_TRANSACTION_MARKER = 0x00 -Transaction.ADVANCED_TRANSACTION_FLAG = 0x01 +// Node type for document fragments (Node.DOCUMENT_FRAGMENT_NODE). +var DOC_FRAGMENT_TYPE = 11; -var EMPTY_SCRIPT = Buffer.allocUnsafe(0) -var EMPTY_WITNESS = [] -var ZERO = Buffer.from('0000000000000000000000000000000000000000000000000000000000000000', 'hex') -var ONE = Buffer.from('0000000000000000000000000000000000000000000000000000000000000001', 'hex') -var VALUE_UINT64_MAX = Buffer.from('ffffffffffffffff', 'hex') -var BLANK_OUTPUT = { - script: EMPTY_SCRIPT, - valueBuffer: VALUE_UINT64_MAX +function getDeclarationErrorAddendum(internalInstance) { + if (internalInstance) { + var owner = internalInstance._currentElement._owner || null; + if (owner) { + var name = owner.getName(); + if (name) { + return ' This DOM node was rendered by `' + name + '`.'; + } + } + } + return ''; } -Transaction.fromBuffer = function (buffer, __noStrict) { - var offset = 0 - function readSlice (n) { - offset += n - return buffer.slice(offset - n, offset) +function friendlyStringify(obj) { + if (typeof obj === 'object') { + if (Array.isArray(obj)) { + return '[' + obj.map(friendlyStringify).join(', ') + ']'; + } else { + var pairs = []; + for (var key in obj) { + if (Object.prototype.hasOwnProperty.call(obj, key)) { + var keyEscaped = /^[a-z$_][\w$_]*$/i.test(key) ? key : JSON.stringify(key); + pairs.push(keyEscaped + ': ' + friendlyStringify(obj[key])); + } + } + return '{' + pairs.join(', ') + '}'; + } + } else if (typeof obj === 'string') { + return JSON.stringify(obj); + } else if (typeof obj === 'function') { + return '[function object]'; } + // Differs from JSON.stringify in that undefined because undefined and that + // inf and nan don't become null + return String(obj); +} - function readUInt32 () { - var i = buffer.readUInt32LE(offset) - offset += 4 - return i - } +var styleMutationWarning = {}; - function readInt32 () { - var i = buffer.readInt32LE(offset) - offset += 4 - return i +function checkAndWarnForMutatedStyle(style1, style2, component) { + if (style1 == null || style2 == null) { + return; } - - function readUInt64 () { - var i = bufferutils.readUInt64LE(buffer, offset) - offset += 8 - return i + if (shallowEqual(style1, style2)) { + return; } - function readVarInt () { - var vi = varuint.decode(buffer, offset) - offset += varuint.decode.bytes - return vi + var componentName = component._tag; + var owner = component._currentElement._owner; + var ownerName; + if (owner) { + ownerName = owner.getName(); } - function readVarSlice () { - return readSlice(readVarInt()) - } + var hash = ownerName + '|' + componentName; - function readVector () { - var count = readVarInt() - var vector = [] - for (var i = 0; i < count; i++) vector.push(readVarSlice()) - return vector + if (styleMutationWarning.hasOwnProperty(hash)) { + return; } - var tx = new Transaction() - tx.version = readInt32() + styleMutationWarning[hash] = true; - var marker = buffer.readUInt8(offset) - var flag = buffer.readUInt8(offset + 1) + process.env.NODE_ENV !== 'production' ? warning(false, '`%s` was passed a style object that has previously been mutated. ' + 'Mutating `style` is deprecated. Consider cloning it beforehand. Check ' + 'the `render` %s. Previous style: %s. Mutated style: %s.', componentName, owner ? 'of `' + ownerName + '`' : 'using <' + componentName + '>', friendlyStringify(style1), friendlyStringify(style2)) : void 0; +} - var hasWitnesses = false - if (marker === Transaction.ADVANCED_TRANSACTION_MARKER && - flag === Transaction.ADVANCED_TRANSACTION_FLAG) { - offset += 2 - hasWitnesses = true +/** + * @param {object} component + * @param {?object} props + */ +function assertValidProps(component, props) { + if (!props) { + return; } - - var vinLen = readVarInt() - for (var i = 0; i < vinLen; ++i) { - tx.ins.push({ - hash: readSlice(32), - index: readUInt32(), - script: readVarSlice(), - sequence: readUInt32(), - witness: EMPTY_WITNESS - }) + // Note the use of `==` which checks for null or undefined. + if (voidElementTags[component._tag]) { + !(props.children == null && props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.%s', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : _prodInvariant('137', component._tag, component._currentElement._owner ? ' Check the render method of ' + component._currentElement._owner.getName() + '.' : '') : void 0; } - - var voutLen = readVarInt() - for (i = 0; i < voutLen; ++i) { - tx.outs.push({ - value: readUInt64(), - script: readVarSlice() - }) + if (props.dangerouslySetInnerHTML != null) { + !(props.children == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Can only set one of `children` or `props.dangerouslySetInnerHTML`.') : _prodInvariant('60') : void 0; + !(typeof props.dangerouslySetInnerHTML === 'object' && HTML in props.dangerouslySetInnerHTML) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.') : _prodInvariant('61') : void 0; } - - if (hasWitnesses) { - for (i = 0; i < vinLen; ++i) { - tx.ins[i].witness = readVector() - } - - // was this pointless? - if (!tx.hasWitnesses()) throw new Error('Transaction has superfluous witness data') + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(props.innerHTML == null, 'Directly setting property `innerHTML` is not permitted. ' + 'For more information, lookup documentation on `dangerouslySetInnerHTML`.') : void 0; + process.env.NODE_ENV !== 'production' ? warning(props.suppressContentEditableWarning || !props.contentEditable || props.children == null, 'A component is `contentEditable` and contains `children` managed by ' + 'React. It is now your responsibility to guarantee that none of ' + 'those nodes are unexpectedly modified or duplicated. This is ' + 'probably not intentional.') : void 0; + process.env.NODE_ENV !== 'production' ? warning(props.onFocusIn == null && props.onFocusOut == null, 'React uses onFocus and onBlur instead of onFocusIn and onFocusOut. ' + 'All React events are normalized to bubble, so onFocusIn and onFocusOut ' + 'are not needed/supported by React.') : void 0; } + !(props.style == null || typeof props.style === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, 'The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + \'em\'}} when using JSX.%s', getDeclarationErrorAddendum(component)) : _prodInvariant('62', getDeclarationErrorAddendum(component)) : void 0; +} - tx.locktime = readUInt32() - - if (__noStrict) return tx - if (offset !== buffer.length) throw new Error('Transaction has unexpected data') +function enqueuePutListener(inst, registrationName, listener, transaction) { + if (transaction instanceof ReactServerRenderingTransaction) { + return; + } + if (process.env.NODE_ENV !== 'production') { + // IE8 has no API for event capturing and the `onScroll` event doesn't + // bubble. + process.env.NODE_ENV !== 'production' ? warning(registrationName !== 'onScroll' || isEventSupported('scroll', true), "This browser doesn't support the `onScroll` event") : void 0; + } + var containerInfo = inst._hostContainerInfo; + var isDocumentFragment = containerInfo._node && containerInfo._node.nodeType === DOC_FRAGMENT_TYPE; + var doc = isDocumentFragment ? containerInfo._node : containerInfo._ownerDocument; + listenTo(registrationName, doc); + transaction.getReactMountReady().enqueue(putListener, { + inst: inst, + registrationName: registrationName, + listener: listener + }); +} - return tx +function putListener() { + var listenerToPut = this; + EventPluginHub.putListener(listenerToPut.inst, listenerToPut.registrationName, listenerToPut.listener); } -Transaction.fromHex = function (hex) { - return Transaction.fromBuffer(Buffer.from(hex, 'hex')) +function inputPostMount() { + var inst = this; + ReactDOMInput.postMountWrapper(inst); } -Transaction.isCoinbaseHash = function (buffer) { - typeforce(types.Hash256bit, buffer) - for (var i = 0; i < 32; ++i) { - if (buffer[i] !== 0) return false - } - return true +function textareaPostMount() { + var inst = this; + ReactDOMTextarea.postMountWrapper(inst); } -Transaction.prototype.isCoinbase = function () { - return this.ins.length === 1 && Transaction.isCoinbaseHash(this.ins[0].hash) +function optionPostMount() { + var inst = this; + ReactDOMOption.postMountWrapper(inst); } -Transaction.prototype.addInput = function (hash, index, sequence, scriptSig) { - typeforce(types.tuple( - types.Hash256bit, - types.UInt32, - types.maybe(types.UInt32), - types.maybe(types.Buffer) - ), arguments) +var setAndValidateContentChildDev = emptyFunction; +if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev = function (content) { + var hasExistingContent = this._contentDebugID != null; + var debugID = this._debugID; + // This ID represents the inlined child that has no backing instance: + var contentDebugID = -debugID; - if (types.Null(sequence)) { - sequence = Transaction.DEFAULT_SEQUENCE - } + if (content == null) { + if (hasExistingContent) { + ReactInstrumentation.debugTool.onUnmountComponent(this._contentDebugID); + } + this._contentDebugID = null; + return; + } - // Add the input and return the input's index - return (this.ins.push({ - hash: hash, - index: index, - script: scriptSig || EMPTY_SCRIPT, - sequence: sequence, - witness: EMPTY_WITNESS - }) - 1) + validateDOMNesting(null, String(content), this, this._ancestorInfo); + this._contentDebugID = contentDebugID; + if (hasExistingContent) { + ReactInstrumentation.debugTool.onBeforeUpdateComponent(contentDebugID, content); + ReactInstrumentation.debugTool.onUpdateComponent(contentDebugID); + } else { + ReactInstrumentation.debugTool.onBeforeMountComponent(contentDebugID, content, debugID); + ReactInstrumentation.debugTool.onMountComponent(contentDebugID); + ReactInstrumentation.debugTool.onSetChildren(debugID, [contentDebugID]); + } + }; } -Transaction.prototype.addOutput = function (scriptPubKey, value) { - typeforce(types.tuple(types.Buffer, types.Satoshi), arguments) +// There are so many media events, it makes sense to just +// maintain a list rather than create a `trapBubbledEvent` for each +var mediaEvents = { + topAbort: 'abort', + topCanPlay: 'canplay', + topCanPlayThrough: 'canplaythrough', + topDurationChange: 'durationchange', + topEmptied: 'emptied', + topEncrypted: 'encrypted', + topEnded: 'ended', + topError: 'error', + topLoadedData: 'loadeddata', + topLoadedMetadata: 'loadedmetadata', + topLoadStart: 'loadstart', + topPause: 'pause', + topPlay: 'play', + topPlaying: 'playing', + topProgress: 'progress', + topRateChange: 'ratechange', + topSeeked: 'seeked', + topSeeking: 'seeking', + topStalled: 'stalled', + topSuspend: 'suspend', + topTimeUpdate: 'timeupdate', + topVolumeChange: 'volumechange', + topWaiting: 'waiting' +}; - // Add the output and return the output's index - return (this.outs.push({ - script: scriptPubKey, - value: value - }) - 1) +function trackInputValue() { + inputValueTracking.track(this); } -Transaction.prototype.hasWitnesses = function () { - return this.ins.some(function (x) { - return x.witness.length !== 0 - }) -} +function trapBubbledEventsLocal() { + var inst = this; + // If a component renders to null or if another component fatals and causes + // the state of the tree to be corrupted, `node` here can be null. + !inst._rootNodeID ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Must be mounted to trap events') : _prodInvariant('63') : void 0; + var node = getNode(inst); + !node ? process.env.NODE_ENV !== 'production' ? invariant(false, 'trapBubbledEvent(...): Requires node to be rendered.') : _prodInvariant('64') : void 0; -Transaction.prototype.weight = function () { - var base = this.__byteLength(false) - var total = this.__byteLength(true) - return base * 3 + total + switch (inst._tag) { + case 'iframe': + case 'object': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; + break; + case 'video': + case 'audio': + inst._wrapperState.listeners = []; + // Create listener for each media event + for (var event in mediaEvents) { + if (mediaEvents.hasOwnProperty(event)) { + inst._wrapperState.listeners.push(ReactBrowserEventEmitter.trapBubbledEvent(event, mediaEvents[event], node)); + } + } + break; + case 'source': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node)]; + break; + case 'img': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topError', 'error', node), ReactBrowserEventEmitter.trapBubbledEvent('topLoad', 'load', node)]; + break; + case 'form': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topReset', 'reset', node), ReactBrowserEventEmitter.trapBubbledEvent('topSubmit', 'submit', node)]; + break; + case 'input': + case 'select': + case 'textarea': + inst._wrapperState.listeners = [ReactBrowserEventEmitter.trapBubbledEvent('topInvalid', 'invalid', node)]; + break; + } } -Transaction.prototype.virtualSize = function () { - return Math.ceil(this.weight() / 4) +function postUpdateSelectWrapper() { + ReactDOMSelect.postUpdateWrapper(this); } -Transaction.prototype.byteLength = function () { - return this.__byteLength(true) -} +// For HTML, certain tags should omit their close tag. We keep a whitelist for +// those special-case tags. -Transaction.prototype.__byteLength = function (__allowWitness) { - var hasWitnesses = __allowWitness && this.hasWitnesses() +var omittedCloseTags = { + area: true, + base: true, + br: true, + col: true, + embed: true, + hr: true, + img: true, + input: true, + keygen: true, + link: true, + meta: true, + param: true, + source: true, + track: true, + wbr: true + // NOTE: menuitem's close tag should be omitted, but that causes problems. +}; - return ( - (hasWitnesses ? 10 : 8) + - varuint.encodingLength(this.ins.length) + - varuint.encodingLength(this.outs.length) + - this.ins.reduce(function (sum, input) { return sum + 40 + varSliceSize(input.script) }, 0) + - this.outs.reduce(function (sum, output) { return sum + 8 + varSliceSize(output.script) }, 0) + - (hasWitnesses ? this.ins.reduce(function (sum, input) { return sum + vectorSize(input.witness) }, 0) : 0) - ) -} +var newlineEatingTags = { + listing: true, + pre: true, + textarea: true +}; -Transaction.prototype.clone = function () { - var newTx = new Transaction() - newTx.version = this.version - newTx.locktime = this.locktime +// For HTML, certain tags cannot have children. This has the same purpose as +// `omittedCloseTags` except that `menuitem` should still have its closing tag. - newTx.ins = this.ins.map(function (txIn) { - return { - hash: txIn.hash, - index: txIn.index, - script: txIn.script, - sequence: txIn.sequence, - witness: txIn.witness - } - }) +var voidElementTags = _assign({ + menuitem: true +}, omittedCloseTags); - newTx.outs = this.outs.map(function (txOut) { - return { - script: txOut.script, - value: txOut.value - } - }) +// We accept any tag to be rendered but since this gets injected into arbitrary +// HTML, we want to make sure that it's a safe tag. +// http://www.w3.org/TR/REC-xml/#NT-Name - return newTx +var VALID_TAG_REGEX = /^[a-zA-Z][a-zA-Z:_\.\-\d]*$/; // Simplified subset +var validatedTagCache = {}; +var hasOwnProperty = {}.hasOwnProperty; + +function validateDangerousTag(tag) { + if (!hasOwnProperty.call(validatedTagCache, tag)) { + !VALID_TAG_REGEX.test(tag) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Invalid tag: %s', tag) : _prodInvariant('65', tag) : void 0; + validatedTagCache[tag] = true; + } +} + +function isCustomComponent(tagName, props) { + return tagName.indexOf('-') >= 0 || props.is != null; } +var globalIdCounter = 1; + /** - * Hash transaction for signing a specific input. + * Creates a new React class that is idempotent and capable of containing other + * React components. It accepts event listeners and DOM properties that are + * valid according to `DOMProperty`. * - * Bitcoin uses a different hash for each signed transaction input. - * This method copies the transaction, makes the necessary changes based on the - * hashType, and then hashes the result. - * This hash can then be used to sign the provided transaction input. + * - Event listeners: `onClick`, `onMouseDown`, etc. + * - DOM properties: `className`, `name`, `title`, etc. + * + * The `style` property functions differently from the DOM API. It accepts an + * object mapping of style properties to values. + * + * @constructor ReactDOMComponent + * @extends ReactMultiChild */ -Transaction.prototype.hashForSignature = function (inIndex, prevOutScript, hashType) { - typeforce(types.tuple(types.UInt32, types.Buffer, /* types.UInt8 */ types.Number), arguments) - - // https://github.com/bitcoin/bitcoin/blob/master/src/test/sighash_tests.cpp#L29 - if (inIndex >= this.ins.length) return ONE - - // ignore OP_CODESEPARATOR - var ourScript = bscript.compile(bscript.decompile(prevOutScript).filter(function (x) { - return x !== opcodes.OP_CODESEPARATOR - })) - - var txTmp = this.clone() - - // SIGHASH_NONE: ignore all outputs? (wildcard payee) - if ((hashType & 0x1f) === Transaction.SIGHASH_NONE) { - txTmp.outs = [] - - // ignore sequence numbers (except at inIndex) - txTmp.ins.forEach(function (input, i) { - if (i === inIndex) return - - input.sequence = 0 - }) - - // SIGHASH_SINGLE: ignore all outputs, except at the same index? - } else if ((hashType & 0x1f) === Transaction.SIGHASH_SINGLE) { - // https://github.com/bitcoin/bitcoin/blob/master/src/test/sighash_tests.cpp#L60 - if (inIndex >= this.outs.length) return ONE - - // truncate outputs after - txTmp.outs.length = inIndex + 1 - - // "blank" outputs before - for (var i = 0; i < inIndex; i++) { - txTmp.outs[i] = BLANK_OUTPUT - } - - // ignore sequence numbers (except at inIndex) - txTmp.ins.forEach(function (input, y) { - if (y === inIndex) return - - input.sequence = 0 - }) - } - - // SIGHASH_ANYONECANPAY: ignore inputs entirely? - if (hashType & Transaction.SIGHASH_ANYONECANPAY) { - txTmp.ins = [txTmp.ins[inIndex]] - txTmp.ins[0].script = ourScript - - // SIGHASH_ALL: only ignore input scripts - } else { - // "blank" others input scripts - txTmp.ins.forEach(function (input) { input.script = EMPTY_SCRIPT }) - txTmp.ins[inIndex].script = ourScript +function ReactDOMComponent(element) { + var tag = element.type; + validateDangerousTag(tag); + this._currentElement = element; + this._tag = tag.toLowerCase(); + this._namespaceURI = null; + this._renderedChildren = null; + this._previousStyle = null; + this._previousStyleCopy = null; + this._hostNode = null; + this._hostParent = null; + this._rootNodeID = 0; + this._domID = 0; + this._hostContainerInfo = null; + this._wrapperState = null; + this._topLevelWrapper = null; + this._flags = 0; + if (process.env.NODE_ENV !== 'production') { + this._ancestorInfo = null; + setAndValidateContentChildDev.call(this, null); } - - // serialize and hash - var buffer = Buffer.allocUnsafe(txTmp.__byteLength(false) + 4) - buffer.writeInt32LE(hashType, buffer.length - 4) - txTmp.__toBuffer(buffer, 0, false) - - return bcrypto.hash256(buffer) } -Transaction.prototype.hashForWitnessV0 = function (inIndex, prevOutScript, value, hashType) { - typeforce(types.tuple(types.UInt32, types.Buffer, types.Satoshi, types.UInt32), arguments) +ReactDOMComponent.displayName = 'ReactDOMComponent'; - var tbuffer, toffset - function writeSlice (slice) { toffset += slice.copy(tbuffer, toffset) } - function writeUInt32 (i) { toffset = tbuffer.writeUInt32LE(i, toffset) } - function writeUInt64 (i) { toffset = bufferutils.writeUInt64LE(tbuffer, i, toffset) } - function writeVarInt (i) { - varuint.encode(i, tbuffer, toffset) - toffset += varuint.encode.bytes - } - function writeVarSlice (slice) { writeVarInt(slice.length); writeSlice(slice) } +ReactDOMComponent.Mixin = { + /** + * Generates root tag markup then recurses. This method has side effects and + * is not idempotent. + * + * @internal + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?ReactDOMComponent} the parent component instance + * @param {?object} info about the host container + * @param {object} context + * @return {string} The computed markup. + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + this._rootNodeID = globalIdCounter++; + this._domID = hostContainerInfo._idCounter++; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; - var hashOutputs = ZERO - var hashPrevouts = ZERO - var hashSequence = ZERO + var props = this._currentElement.props; - if (!(hashType & Transaction.SIGHASH_ANYONECANPAY)) { - tbuffer = Buffer.allocUnsafe(36 * this.ins.length) - toffset = 0 + switch (this._tag) { + case 'audio': + case 'form': + case 'iframe': + case 'img': + case 'link': + case 'object': + case 'source': + case 'video': + this._wrapperState = { + listeners: null + }; + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'input': + ReactDOMInput.mountWrapper(this, props, hostParent); + props = ReactDOMInput.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trackInputValue, this); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'option': + ReactDOMOption.mountWrapper(this, props, hostParent); + props = ReactDOMOption.getHostProps(this, props); + break; + case 'select': + ReactDOMSelect.mountWrapper(this, props, hostParent); + props = ReactDOMSelect.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + case 'textarea': + ReactDOMTextarea.mountWrapper(this, props, hostParent); + props = ReactDOMTextarea.getHostProps(this, props); + transaction.getReactMountReady().enqueue(trackInputValue, this); + transaction.getReactMountReady().enqueue(trapBubbledEventsLocal, this); + break; + } - this.ins.forEach(function (txIn) { - writeSlice(txIn.hash) - writeUInt32(txIn.index) - }) + assertValidProps(this, props); - hashPrevouts = bcrypto.hash256(tbuffer) - } + // We create tags in the namespace of their parent container, except HTML + // tags get no namespace. + var namespaceURI; + var parentTag; + if (hostParent != null) { + namespaceURI = hostParent._namespaceURI; + parentTag = hostParent._tag; + } else if (hostContainerInfo._tag) { + namespaceURI = hostContainerInfo._namespaceURI; + parentTag = hostContainerInfo._tag; + } + if (namespaceURI == null || namespaceURI === DOMNamespaces.svg && parentTag === 'foreignobject') { + namespaceURI = DOMNamespaces.html; + } + if (namespaceURI === DOMNamespaces.html) { + if (this._tag === 'svg') { + namespaceURI = DOMNamespaces.svg; + } else if (this._tag === 'math') { + namespaceURI = DOMNamespaces.mathml; + } + } + this._namespaceURI = namespaceURI; - if (!(hashType & Transaction.SIGHASH_ANYONECANPAY) && - (hashType & 0x1f) !== Transaction.SIGHASH_SINGLE && - (hashType & 0x1f) !== Transaction.SIGHASH_NONE) { - tbuffer = Buffer.allocUnsafe(4 * this.ins.length) - toffset = 0 + if (process.env.NODE_ENV !== 'production') { + var parentInfo; + if (hostParent != null) { + parentInfo = hostParent._ancestorInfo; + } else if (hostContainerInfo._tag) { + parentInfo = hostContainerInfo._ancestorInfo; + } + if (parentInfo) { + // parentInfo should always be present except for the top-level + // component when server rendering + validateDOMNesting(this._tag, null, this, parentInfo); + } + this._ancestorInfo = validateDOMNesting.updatedAncestorInfo(parentInfo, this._tag, this); + } - this.ins.forEach(function (txIn) { - writeUInt32(txIn.sequence) - }) + var mountImage; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var el; + if (namespaceURI === DOMNamespaces.html) { + if (this._tag === 'script') { + // Create the script via .innerHTML so its "parser-inserted" flag is + // set to true and it does not execute + var div = ownerDocument.createElement('div'); + var type = this._currentElement.type; + div.innerHTML = '<' + type + '></' + type + '>'; + el = div.removeChild(div.firstChild); + } else if (props.is) { + el = ownerDocument.createElement(this._currentElement.type, props.is); + } else { + // Separate else branch instead of using `props.is || undefined` above becuase of a Firefox bug. + // See discussion in https://github.com/facebook/react/pull/6896 + // and discussion in https://bugzilla.mozilla.org/show_bug.cgi?id=1276240 + el = ownerDocument.createElement(this._currentElement.type); + } + } else { + el = ownerDocument.createElementNS(namespaceURI, this._currentElement.type); + } + ReactDOMComponentTree.precacheNode(this, el); + this._flags |= Flags.hasCachedChildNodes; + if (!this._hostParent) { + DOMPropertyOperations.setAttributeForRoot(el); + } + this._updateDOMProperties(null, props, transaction); + var lazyTree = DOMLazyTree(el); + this._createInitialChildren(transaction, props, context, lazyTree); + mountImage = lazyTree; + } else { + var tagOpen = this._createOpenTagMarkupAndPutListeners(transaction, props); + var tagContent = this._createContentMarkup(transaction, props, context); + if (!tagContent && omittedCloseTags[this._tag]) { + mountImage = tagOpen + '/>'; + } else { + mountImage = tagOpen + '>' + tagContent + '</' + this._currentElement.type + '>'; + } + } - hashSequence = bcrypto.hash256(tbuffer) - } + switch (this._tag) { + case 'input': + transaction.getReactMountReady().enqueue(inputPostMount, this); + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'textarea': + transaction.getReactMountReady().enqueue(textareaPostMount, this); + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'select': + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'button': + if (props.autoFocus) { + transaction.getReactMountReady().enqueue(AutoFocusUtils.focusDOMComponent, this); + } + break; + case 'option': + transaction.getReactMountReady().enqueue(optionPostMount, this); + break; + } - if ((hashType & 0x1f) !== Transaction.SIGHASH_SINGLE && - (hashType & 0x1f) !== Transaction.SIGHASH_NONE) { - var txOutsSize = this.outs.reduce(function (sum, output) { - return sum + 8 + varSliceSize(output.script) - }, 0) + return mountImage; + }, - tbuffer = Buffer.allocUnsafe(txOutsSize) - toffset = 0 + /** + * Creates markup for the open tag and all attributes. + * + * This method has side effects because events get registered. + * + * Iterating over object properties is faster than iterating over arrays. + * @see http://jsperf.com/obj-vs-arr-iteration + * + * @private + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} props + * @return {string} Markup of opening tag. + */ + _createOpenTagMarkupAndPutListeners: function (transaction, props) { + var ret = '<' + this._currentElement.type; - this.outs.forEach(function (out) { - writeUInt64(out.value) - writeVarSlice(out.script) - }) + for (var propKey in props) { + if (!props.hasOwnProperty(propKey)) { + continue; + } + var propValue = props[propKey]; + if (propValue == null) { + continue; + } + if (registrationNameModules.hasOwnProperty(propKey)) { + if (propValue) { + enqueuePutListener(this, propKey, propValue, transaction); + } + } else { + if (propKey === STYLE) { + if (propValue) { + if (process.env.NODE_ENV !== 'production') { + // See `_updateDOMProperties`. style block + this._previousStyle = propValue; + } + propValue = this._previousStyleCopy = _assign({}, props.style); + } + propValue = CSSPropertyOperations.createMarkupForStyles(propValue, this); + } + var markup = null; + if (this._tag != null && isCustomComponent(this._tag, props)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + markup = DOMPropertyOperations.createMarkupForCustomAttribute(propKey, propValue); + } + } else { + markup = DOMPropertyOperations.createMarkupForProperty(propKey, propValue); + } + if (markup) { + ret += ' ' + markup; + } + } + } - hashOutputs = bcrypto.hash256(tbuffer) - } else if ((hashType & 0x1f) === Transaction.SIGHASH_SINGLE && inIndex < this.outs.length) { - var output = this.outs[inIndex] + // For static pages, no need to put React ID and checksum. Saves lots of + // bytes. + if (transaction.renderToStaticMarkup) { + return ret; + } - tbuffer = Buffer.allocUnsafe(8 + varSliceSize(output.script)) - toffset = 0 - writeUInt64(output.value) - writeVarSlice(output.script) + if (!this._hostParent) { + ret += ' ' + DOMPropertyOperations.createMarkupForRoot(); + } + ret += ' ' + DOMPropertyOperations.createMarkupForID(this._domID); + return ret; + }, - hashOutputs = bcrypto.hash256(tbuffer) - } + /** + * Creates markup for the content between the tags. + * + * @private + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} props + * @param {object} context + * @return {string} Content markup. + */ + _createContentMarkup: function (transaction, props, context) { + var ret = ''; - tbuffer = Buffer.allocUnsafe(156 + varSliceSize(prevOutScript)) - toffset = 0 + // Intentional use of != to avoid catching zero/false. + var innerHTML = props.dangerouslySetInnerHTML; + if (innerHTML != null) { + if (innerHTML.__html != null) { + ret = innerHTML.__html; + } + } else { + var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; + var childrenToUse = contentToUse != null ? null : props.children; + if (contentToUse != null) { + // TODO: Validate that text is allowed as a child of this node + ret = escapeTextContentForBrowser(contentToUse); + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, contentToUse); + } + } else if (childrenToUse != null) { + var mountImages = this.mountChildren(childrenToUse, transaction, context); + ret = mountImages.join(''); + } + } + if (newlineEatingTags[this._tag] && ret.charAt(0) === '\n') { + // text/html ignores the first character in these tags if it's a newline + // Prefer to break application/xml over text/html (for now) by adding + // a newline specifically to get eaten by the parser. (Alternately for + // textareas, replacing "^\n" with "\r\n" doesn't get eaten, and the first + // \r is normalized out by HTMLTextAreaElement#value.) + // See: <http://www.w3.org/TR/html-polyglot/#newlines-in-textarea-and-pre> + // See: <http://www.w3.org/TR/html5/syntax.html#element-restrictions> + // See: <http://www.w3.org/TR/html5/syntax.html#newlines> + // See: Parsing of "textarea" "listing" and "pre" elements + // from <http://www.w3.org/TR/html5/syntax.html#parsing-main-inbody> + return '\n' + ret; + } else { + return ret; + } + }, - var input = this.ins[inIndex] - writeUInt32(this.version) - writeSlice(hashPrevouts) - writeSlice(hashSequence) - writeSlice(input.hash) - writeUInt32(input.index) - writeVarSlice(prevOutScript) - writeUInt64(value) - writeUInt32(input.sequence) - writeSlice(hashOutputs) - writeUInt32(this.locktime) - writeUInt32(hashType) - return bcrypto.hash256(tbuffer) -} + _createInitialChildren: function (transaction, props, context, lazyTree) { + // Intentional use of != to avoid catching zero/false. + var innerHTML = props.dangerouslySetInnerHTML; + if (innerHTML != null) { + if (innerHTML.__html != null) { + DOMLazyTree.queueHTML(lazyTree, innerHTML.__html); + } + } else { + var contentToUse = CONTENT_TYPES[typeof props.children] ? props.children : null; + var childrenToUse = contentToUse != null ? null : props.children; + // TODO: Validate that text is allowed as a child of this node + if (contentToUse != null) { + // Avoid setting textContent when the text is empty. In IE11 setting + // textContent on a text area will cause the placeholder to not + // show within the textarea until it has been focused and blurred again. + // https://github.com/facebook/react/issues/6731#issuecomment-254874553 + if (contentToUse !== '') { + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, contentToUse); + } + DOMLazyTree.queueText(lazyTree, contentToUse); + } + } else if (childrenToUse != null) { + var mountImages = this.mountChildren(childrenToUse, transaction, context); + for (var i = 0; i < mountImages.length; i++) { + DOMLazyTree.queueChild(lazyTree, mountImages[i]); + } + } + } + }, -Transaction.prototype.getHash = function () { - return bcrypto.hash256(this.__toBuffer(undefined, undefined, false)) -} + /** + * Receives a next element and updates the component. + * + * @internal + * @param {ReactElement} nextElement + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {object} context + */ + receiveComponent: function (nextElement, transaction, context) { + var prevElement = this._currentElement; + this._currentElement = nextElement; + this.updateComponent(transaction, prevElement, nextElement, context); + }, -Transaction.prototype.getId = function () { - // transaction hash's are displayed in reverse order - return this.getHash().reverse().toString('hex') -} + /** + * Updates a DOM component after it has already been allocated and + * attached to the DOM. Reconciles the root DOM node, then recurses. + * + * @param {ReactReconcileTransaction} transaction + * @param {ReactElement} prevElement + * @param {ReactElement} nextElement + * @internal + * @overridable + */ + updateComponent: function (transaction, prevElement, nextElement, context) { + var lastProps = prevElement.props; + var nextProps = this._currentElement.props; -Transaction.prototype.toBuffer = function (buffer, initialOffset) { - return this.__toBuffer(buffer, initialOffset, true) -} + switch (this._tag) { + case 'input': + lastProps = ReactDOMInput.getHostProps(this, lastProps); + nextProps = ReactDOMInput.getHostProps(this, nextProps); + break; + case 'option': + lastProps = ReactDOMOption.getHostProps(this, lastProps); + nextProps = ReactDOMOption.getHostProps(this, nextProps); + break; + case 'select': + lastProps = ReactDOMSelect.getHostProps(this, lastProps); + nextProps = ReactDOMSelect.getHostProps(this, nextProps); + break; + case 'textarea': + lastProps = ReactDOMTextarea.getHostProps(this, lastProps); + nextProps = ReactDOMTextarea.getHostProps(this, nextProps); + break; + } -Transaction.prototype.__toBuffer = function (buffer, initialOffset, __allowWitness) { - if (!buffer) buffer = Buffer.allocUnsafe(this.__byteLength(__allowWitness)) + assertValidProps(this, nextProps); + this._updateDOMProperties(lastProps, nextProps, transaction); + this._updateDOMChildren(lastProps, nextProps, transaction, context); - var offset = initialOffset || 0 - function writeSlice (slice) { offset += slice.copy(buffer, offset) } - function writeUInt8 (i) { offset = buffer.writeUInt8(i, offset) } - function writeUInt32 (i) { offset = buffer.writeUInt32LE(i, offset) } - function writeInt32 (i) { offset = buffer.writeInt32LE(i, offset) } - function writeUInt64 (i) { offset = bufferutils.writeUInt64LE(buffer, i, offset) } - function writeVarInt (i) { - varuint.encode(i, buffer, offset) - offset += varuint.encode.bytes - } - function writeVarSlice (slice) { writeVarInt(slice.length); writeSlice(slice) } - function writeVector (vector) { writeVarInt(vector.length); vector.forEach(writeVarSlice) } - - writeInt32(this.version) - - var hasWitnesses = __allowWitness && this.hasWitnesses() - - if (hasWitnesses) { - writeUInt8(Transaction.ADVANCED_TRANSACTION_MARKER) - writeUInt8(Transaction.ADVANCED_TRANSACTION_FLAG) - } - - writeVarInt(this.ins.length) - - this.ins.forEach(function (txIn) { - writeSlice(txIn.hash) - writeUInt32(txIn.index) - writeVarSlice(txIn.script) - writeUInt32(txIn.sequence) - }) - - writeVarInt(this.outs.length) - this.outs.forEach(function (txOut) { - if (!txOut.valueBuffer) { - writeUInt64(txOut.value) - } else { - writeSlice(txOut.valueBuffer) + switch (this._tag) { + case 'input': + // Update the wrapper around inputs *after* updating props. This has to + // happen after `_updateDOMProperties`. Otherwise HTML5 input validations + // raise warnings and prevent the new value from being assigned. + ReactDOMInput.updateWrapper(this); + break; + case 'textarea': + ReactDOMTextarea.updateWrapper(this); + break; + case 'select': + // <select> value update needs to occur after <option> children + // reconciliation + transaction.getReactMountReady().enqueue(postUpdateSelectWrapper, this); + break; } + }, - writeVarSlice(txOut.script) - }) - - if (hasWitnesses) { - this.ins.forEach(function (input) { - writeVector(input.witness) - }) - } - - writeUInt32(this.locktime) - - // avoid slicing unless necessary - if (initialOffset !== undefined) return buffer.slice(initialOffset, offset) - return buffer -} - -Transaction.prototype.toHex = function () { - return this.toBuffer().toString('hex') -} - -Transaction.prototype.setInputScript = function (index, scriptSig) { - typeforce(types.tuple(types.Number, types.Buffer), arguments) - - this.ins[index].script = scriptSig -} - -Transaction.prototype.setWitness = function (index, witness) { - typeforce(types.tuple(types.Number, [types.Buffer]), arguments) - - this.ins[index].witness = witness -} - -module.exports = Transaction - - -/***/ }), -/* 275 */ -/***/ (function(module, exports, __webpack_require__) { - -var baddress = __webpack_require__(276) -var bcrypto = __webpack_require__(116) -var ecdsa = __webpack_require__(549) -var randomBytes = __webpack_require__(115) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) -var wif = __webpack_require__(552) - -var NETWORKS = __webpack_require__(242) -var BigInteger = __webpack_require__(110) - -var ecurve = __webpack_require__(278) -var secp256k1 = ecdsa.__curve - -function ECPair (d, Q, options) { - if (options) { - typeforce({ - compressed: types.maybe(types.Boolean), - network: types.maybe(types.Network) - }, options) - } - - options = options || {} - - if (d) { - if (d.signum() <= 0) throw new Error('Private key must be greater than 0') - if (d.compareTo(secp256k1.n) >= 0) throw new Error('Private key must be less than the curve order') - if (Q) throw new TypeError('Unexpected publicKey parameter') - - this.d = d - } else { - typeforce(types.ECPoint, Q) - - this.__Q = Q - } - - this.compressed = options.compressed === undefined ? true : options.compressed - this.network = options.network || NETWORKS.bitcoin -} - -Object.defineProperty(ECPair.prototype, 'Q', { - get: function () { - if (!this.__Q && this.d) { - this.__Q = secp256k1.G.multiply(this.d) + /** + * Reconciles the properties by detecting differences in property values and + * updating the DOM as necessary. This function is probably the single most + * critical path for performance optimization. + * + * TODO: Benchmark whether checking for changed values in memory actually + * improves performance (especially statically positioned elements). + * TODO: Benchmark the effects of putting this at the top since 99% of props + * do not change for a given reconciliation. + * TODO: Benchmark areas that can be improved with caching. + * + * @private + * @param {object} lastProps + * @param {object} nextProps + * @param {?DOMElement} node + */ + _updateDOMProperties: function (lastProps, nextProps, transaction) { + var propKey; + var styleName; + var styleUpdates; + for (propKey in lastProps) { + if (nextProps.hasOwnProperty(propKey) || !lastProps.hasOwnProperty(propKey) || lastProps[propKey] == null) { + continue; + } + if (propKey === STYLE) { + var lastStyle = this._previousStyleCopy; + for (styleName in lastStyle) { + if (lastStyle.hasOwnProperty(styleName)) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = ''; + } + } + this._previousStyleCopy = null; + } else if (registrationNameModules.hasOwnProperty(propKey)) { + if (lastProps[propKey]) { + // Only call deleteListener if there was a listener previously or + // else willDeleteListener gets called when there wasn't actually a + // listener (e.g., onClick={null}) + deleteListener(this, propKey); + } + } else if (isCustomComponent(this._tag, lastProps)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + DOMPropertyOperations.deleteValueForAttribute(getNode(this), propKey); + } + } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { + DOMPropertyOperations.deleteValueForProperty(getNode(this), propKey); + } } - - return this.__Q - } -}) - -ECPair.fromPublicKeyBuffer = function (buffer, network) { - var Q = ecurve.Point.decodeFrom(secp256k1, buffer) - - return new ECPair(null, Q, { - compressed: Q.compressed, - network: network - }) -} - -ECPair.fromWIF = function (string, network) { - var decoded = wif.decode(string) - var version = decoded.version - - // list of networks? - if (types.Array(network)) { - network = network.filter(function (x) { - return version === x.wif - }).pop() - - if (!network) throw new Error('Unknown network version') - - // otherwise, assume a network object (or default to bitcoin) - } else { - network = network || NETWORKS.bitcoin - - if (version !== network.wif) throw new Error('Invalid network version') - } - - var d = BigInteger.fromBuffer(decoded.privateKey) - - return new ECPair(d, null, { - compressed: decoded.compressed, - network: network - }) -} - -ECPair.makeRandom = function (options) { - options = options || {} - - var rng = options.rng || randomBytes - - var d - do { - var buffer = rng(32) - typeforce(types.Buffer256bit, buffer) - - d = BigInteger.fromBuffer(buffer) - } while (d.signum() <= 0 || d.compareTo(secp256k1.n) >= 0) - - return new ECPair(d, null, options) -} - -ECPair.prototype.getAddress = function () { - return baddress.toBase58Check(bcrypto.hash160(this.getPublicKeyBuffer()), this.getNetwork().pubKeyHash) -} - -ECPair.prototype.getNetwork = function () { - return this.network -} - -ECPair.prototype.getPublicKeyBuffer = function () { - return this.Q.getEncoded(this.compressed) -} - -ECPair.prototype.sign = function (hash) { - if (!this.d) throw new Error('Missing private key') - - return ecdsa.sign(hash, this.d) -} - -ECPair.prototype.toWIF = function () { - if (!this.d) throw new Error('Missing private key') - - return wif.encode(this.network.wif, this.d.toBuffer(32), this.compressed) -} - -ECPair.prototype.verify = function (hash, signature) { - return ecdsa.verify(hash, signature, this.Q) -} - -module.exports = ECPair - - -/***/ }), -/* 276 */ -/***/ (function(module, exports, __webpack_require__) { - -var Buffer = __webpack_require__(18).Buffer -var bs58check = __webpack_require__(111) -var bscript = __webpack_require__(35) -var networks = __webpack_require__(242) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) - -function fromBase58Check (address) { - var payload = bs58check.decode(address) - if (payload.length < 21) throw new TypeError(address + ' is too short') - if (payload.length > 21) throw new TypeError(address + ' is too long') - - var version = payload.readUInt8(0) - var hash = payload.slice(1) - - return { hash: hash, version: version } -} - -function toBase58Check (hash, version) { - typeforce(types.tuple(types.Hash160bit, types.UInt8), arguments) - - var payload = Buffer.allocUnsafe(21) - payload.writeUInt8(version, 0) - hash.copy(payload, 1) - - return bs58check.encode(payload) -} - -function fromOutputScript (outputScript, network) { - network = network || networks.bitcoin - - if (bscript.pubKeyHash.output.check(outputScript)) return toBase58Check(bscript.compile(outputScript).slice(3, 23), network.pubKeyHash) - if (bscript.scriptHash.output.check(outputScript)) return toBase58Check(bscript.compile(outputScript).slice(2, 22), network.scriptHash) - - throw new Error(bscript.toASM(outputScript) + ' has no matching Address') -} - -function toOutputScript (address, network) { - network = network || networks.bitcoin - - var decode = fromBase58Check(address) - if (decode.version === network.pubKeyHash) return bscript.pubKeyHash.output.encode(decode.hash) - if (decode.version === network.scriptHash) return bscript.scriptHash.output.encode(decode.hash) - - throw new Error(address + ' has no matching Script') -} - -module.exports = { - fromBase58Check: fromBase58Check, - fromOutputScript: fromOutputScript, - toBase58Check: toBase58Check, - toOutputScript: toOutputScript -} - - -/***/ }), -/* 277 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(Buffer) {var bip66 = __webpack_require__(266) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) - -var BigInteger = __webpack_require__(110) - -function ECSignature (r, s) { - typeforce(types.tuple(types.BigInt, types.BigInt), arguments) - - this.r = r - this.s = s -} - -ECSignature.parseCompact = function (buffer) { - if (buffer.length !== 65) throw new Error('Invalid signature length') - - var flagByte = buffer.readUInt8(0) - 27 - if (flagByte !== (flagByte & 7)) throw new Error('Invalid signature parameter') - - var compressed = !!(flagByte & 4) - var recoveryParam = flagByte & 3 - - var r = BigInteger.fromBuffer(buffer.slice(1, 33)) - var s = BigInteger.fromBuffer(buffer.slice(33)) - - return { - compressed: compressed, - i: recoveryParam, - signature: new ECSignature(r, s) - } -} - -ECSignature.fromDER = function (buffer) { - var decode = bip66.decode(buffer) - var r = BigInteger.fromDERInteger(decode.r) - var s = BigInteger.fromDERInteger(decode.s) - - return new ECSignature(r, s) -} - -// BIP62: 1 byte hashType flag (only 0x01, 0x02, 0x03, 0x81, 0x82 and 0x83 are allowed) -ECSignature.parseScriptSignature = function (buffer) { - var hashType = buffer.readUInt8(buffer.length - 1) - var hashTypeMod = hashType & ~0x80 - - if (hashTypeMod <= 0x00 || hashTypeMod >= 0x04) throw new Error('Invalid hashType ' + hashType) - - return { - signature: ECSignature.fromDER(buffer.slice(0, -1)), - hashType: hashType - } -} - -ECSignature.prototype.toCompact = function (i, compressed) { - if (compressed) { - i += 4 - } - - i += 27 - - var buffer = Buffer.alloc(65) - buffer.writeUInt8(i, 0) - this.r.toBuffer(32).copy(buffer, 1) - this.s.toBuffer(32).copy(buffer, 33) - - return buffer -} - -ECSignature.prototype.toDER = function () { - var r = Buffer.from(this.r.toDERInteger()) - var s = Buffer.from(this.s.toDERInteger()) - - return bip66.encode(r, s) -} - -ECSignature.prototype.toScriptSignature = function (hashType) { - var hashTypeMod = hashType & ~0x80 - if (hashTypeMod <= 0 || hashTypeMod >= 4) throw new Error('Invalid hashType ' + hashType) - - var hashTypeBuffer = Buffer.alloc(1) - hashTypeBuffer.writeUInt8(hashType, 0) - - return Buffer.concat([this.toDER(), hashTypeBuffer]) -} - -module.exports = ECSignature - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) - -/***/ }), -/* 278 */ -/***/ (function(module, exports, __webpack_require__) { - -var Point = __webpack_require__(353) -var Curve = __webpack_require__(354) - -var getCurveByName = __webpack_require__(550) - -module.exports = { - Curve: Curve, - Point: Point, - getCurveByName: getCurveByName -} - - -/***/ }), -/* 279 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _reactIconBase = __webpack_require__(70); - -var _reactIconBase2 = _interopRequireDefault(_reactIconBase); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -var MdSettings = function MdSettings(props) { - return _react2.default.createElement( - _reactIconBase2.default, - _extends({ viewBox: '0 0 40 40' }, props), - _react2.default.createElement( - 'g', - null, - _react2.default.createElement('path', { d: 'm20 25.9c3.2 0 5.9-2.7 5.9-5.9s-2.7-5.9-5.9-5.9-5.9 2.7-5.9 5.9 2.7 5.9 5.9 5.9z m12.4-4.3l3.5 2.8c0.4 0.2 0.4 0.7 0.2 1.1l-3.4 5.8c-0.2 0.3-0.6 0.4-1 0.3l-4.1-1.7c-0.9 0.7-1.8 1.3-2.8 1.7l-0.7 4.3c0 0.4-0.4 0.7-0.7 0.7h-6.8c-0.4 0-0.7-0.3-0.7-0.7l-0.7-4.3c-1-0.4-1.9-1-2.8-1.7l-4.1 1.7c-0.4 0.1-0.8 0-1-0.3l-3.4-5.8c-0.2-0.4-0.2-0.9 0.2-1.1l3.5-2.8c-0.1-0.5-0.1-1.1-0.1-1.6s0-1.1 0.1-1.6l-3.5-2.8c-0.4-0.2-0.4-0.7-0.2-1.1l3.4-5.7c0.2-0.4 0.6-0.5 1-0.4l4.1 1.7c0.9-0.6 1.8-1.3 2.8-1.7l0.7-4.3c0-0.4 0.3-0.7 0.7-0.7h6.8c0.3 0 0.7 0.3 0.7 0.7l0.7 4.3c1 0.4 1.9 1 2.8 1.7l4.1-1.7c0.4-0.1 0.8 0 1 0.4l3.4 5.7c0.2 0.4 0.2 0.9-0.2 1.1l-3.5 2.8c0.1 0.5 0.1 1.1 0.1 1.6s0 1.1-0.1 1.6z' }) - ) - ); -}; - -exports.default = MdSettings; -module.exports = exports['default']; - -/***/ }), -/* 280 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _reactIconBase = __webpack_require__(70); - -var _reactIconBase2 = _interopRequireDefault(_reactIconBase); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -var FaUnlockAlt = function FaUnlockAlt(props) { - return _react2.default.createElement( - _reactIconBase2.default, - _extends({ viewBox: '0 0 40 40' }, props), - _react2.default.createElement( - 'g', - null, - _react2.default.createElement('path', { d: 'm30.6 17.1q0.9 0 1.5 0.7t0.6 1.5v12.8q0 0.9-0.6 1.6t-1.5 0.6h-21.5q-0.8 0-1.5-0.6t-0.6-1.6v-12.8q0-0.9 0.6-1.5t1.5-0.7h0.8v-7.1q0-4.1 2.9-7.1t7.1-2.9 7 2.9 3 7.1q0 0.6-0.5 1t-1 0.4h-1.4q-0.6 0-1-0.4t-0.4-1q0-2.4-1.7-4t-4-1.7-4.1 1.7-1.7 4v7.1h16.5z' }) - ) - ); -}; - -exports.default = FaUnlockAlt; -module.exports = exports['default']; - -/***/ }), -/* 281 */ -/***/ (function(module, exports) { - -var toString = {}.toString; - -module.exports = Array.isArray || function (arr) { - return toString.call(arr) == '[object Array]'; -}; - - -/***/ }), -/* 282 */ -/***/ (function(module, exports, __webpack_require__) { - -module.exports = __webpack_require__(363); - -/***/ }), -/* 283 */ -/***/ (function(module, exports, __webpack_require__) { - -var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (global, factory) { - if (true) { - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports, __webpack_require__(4), __webpack_require__(28), __webpack_require__(9), __webpack_require__(256), __webpack_require__(257), __webpack_require__(364)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), - __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? - (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else if (typeof exports !== "undefined") { - factory(exports, require('react'), require('react-dom'), require('prop-types'), require('./s-alert-parts/s-alert-tools'), require('./s-alert-parts/s-alert-store'), require('./SAlertContentTmpl')); - } else { - var mod = { - exports: {} - }; - factory(mod.exports, global.react, global.reactDom, global.propTypes, global.sAlertTools, global.sAlertStore, global.SAlertContentTmpl); - global.SAlertContent = mod.exports; - } -})(this, function (exports, _react, _reactDom, _propTypes, _sAlertTools, _sAlertStore, _SAlertContentTmpl) { - 'use strict'; - - Object.defineProperty(exports, "__esModule", { - value: true - }); - - var _react2 = _interopRequireDefault(_react); - - var _reactDom2 = _interopRequireDefault(_reactDom); - - var _propTypes2 = _interopRequireDefault(_propTypes); - - var _sAlertTools2 = _interopRequireDefault(_sAlertTools); - - var _sAlertStore2 = _interopRequireDefault(_sAlertStore); - - var _SAlertContentTmpl2 = _interopRequireDefault(_SAlertContentTmpl); - - function _interopRequireDefault(obj) { - return obj && obj.__esModule ? obj : { - default: obj - }; - } - - var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { - return typeof obj; - } : function (obj) { - return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; - }; - - function _classCallCheck(instance, Constructor) { - if (!(instance instanceof Constructor)) { - throw new TypeError("Cannot call a class as a function"); - } - } - - var _createClass = function () { - function defineProperties(target, props) { - for (var i = 0; i < props.length; i++) { - var descriptor = props[i]; - descriptor.enumerable = descriptor.enumerable || false; - descriptor.configurable = true; - if ("value" in descriptor) descriptor.writable = true; - Object.defineProperty(target, descriptor.key, descriptor); - } - } - - return function (Constructor, protoProps, staticProps) { - if (protoProps) defineProperties(Constructor.prototype, protoProps); - if (staticProps) defineProperties(Constructor, staticProps); - return Constructor; - }; - }(); - - function _possibleConstructorReturn(self, call) { - if (!self) { - throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); - } - - return call && (typeof call === "object" || typeof call === "function") ? call : self; - } - - function _inherits(subClass, superClass) { - if (typeof superClass !== "function" && superClass !== null) { - throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); - } - - subClass.prototype = Object.create(superClass && superClass.prototype, { - constructor: { - value: subClass, - enumerable: false, - writable: true, - configurable: true - } - }); - if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; - } - - var SAlertContent = function (_React$Component) { - _inherits(SAlertContent, _React$Component); - - function SAlertContent(props) { - _classCallCheck(this, SAlertContent); - - return _possibleConstructorReturn(this, (SAlertContent.__proto__ || Object.getPrototypeOf(SAlertContent)).call(this, props)); - } - - _createClass(SAlertContent, [{ - key: 'handleCloseAlert', - value: function handleCloseAlert() { - var closingTimeout = void 0; - var alertId = this.props.id; - var currentAlertElem = _reactDom2.default.findDOMNode(this); - var animationClose = function animationClose() { - currentAlertElem.style.display = 'none'; - _sAlertStore2.default.dispatch({ type: 'REMOVE', data: { id: alertId } }); - clearTimeout(closingTimeout); - }; - if (document.hidden || document.webkitHidden || !currentAlertElem.classList.contains('s-alert-is-effect')) { - _sAlertStore2.default.dispatch({ type: 'REMOVE', data: { id: alertId } }); - } else { - currentAlertElem.classList.remove('s-alert-show'); - closingTimeout = setTimeout(function () { - currentAlertElem.classList.add('s-alert-hide'); - }, 100); - currentAlertElem.removeEventListener('webkitAnimationEnd', animationClose, false); - currentAlertElem.removeEventListener('animationend', animationClose, false); - currentAlertElem.addEventListener('webkitAnimationEnd', animationClose, false); - currentAlertElem.addEventListener('animationend', animationClose, false); - } - // stop audio when closing - this.alertAudio && this.alertAudio.load(); - } - }, { - key: 'componentWillMount', - value: function componentWillMount() { - var beep = this.props.beep; - var condition = this.props.condition; - if (beep && typeof beep === 'string') { - this.alertAudio = new Audio(beep); - this.alertAudio.load(); - this.alertAudio.play(); - } - if (beep && (typeof beep === 'undefined' ? 'undefined' : _typeof(beep)) === 'object' && condition === 'info') { - this.alertAudio = new Audio(beep.info); - this.alertAudio.load(); - this.alertAudio.play(); - } - if (beep && (typeof beep === 'undefined' ? 'undefined' : _typeof(beep)) === 'object' && condition === 'error') { - this.alertAudio = new Audio(beep.error); - this.alertAudio.load(); - this.alertAudio.play(); - } - if (beep && (typeof beep === 'undefined' ? 'undefined' : _typeof(beep)) === 'object' && condition === 'success') { - this.alertAudio = new Audio(beep.success); - this.alertAudio.load(); - this.alertAudio.play(); - } - if (beep && (typeof beep === 'undefined' ? 'undefined' : _typeof(beep)) === 'object' && condition === 'warning') { - this.alertAudio = new Audio(beep.warning); - this.alertAudio.load(); - this.alertAudio.play(); - } - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - var _this2 = this; - - if (typeof this.props.timeout === 'number') { - this.closeTimer = setTimeout(function () { - _this2.handleCloseAlert(); - }, this.props.timeout); - } - if (this.props.onShow) { - this.props.onShow(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - if (this.closeTimer) { - clearTimeout(this.closeTimer); - } - if (this.props.onClose) { - this.props.onClose(); - } - } - }, { - key: 'render', - value: function render() { - var classNames = 's-alert-box s-alert-' + this.props.condition + ' s-alert-' + this.props.position + ' ' + (this.props.effect ? 's-alert-is-effect s-alert-effect-' + this.props.effect : '') + ' s-alert-show'; - var message = this.props.html ? _react2.default.createElement('span', { dangerouslySetInnerHTML: { __html: this.props.message } }) : this.props.message; - var styles = this.props.boxPosition ? _sAlertTools2.default.styleToObj(this.props.boxPosition) : {}; - var id = this.props.id; - var handleClose = this.handleCloseAlert.bind(this); - var contentTemplate = this.props.contentTemplate || _SAlertContentTmpl2.default; - var customFields = this.props.customFields || {}; - - return _react2.default.createElement(contentTemplate, { classNames: classNames, id: id, styles: styles, message: message, handleClose: handleClose, customFields: customFields }); - } - }]); - - return SAlertContent; - }(_react2.default.Component); - - SAlertContent.propTypes = { - condition: _propTypes2.default.string.isRequired, - message: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.node]), - position: _propTypes2.default.string.isRequired, - boxPosition: _propTypes2.default.string, - id: _propTypes2.default.string.isRequired, - effect: _propTypes2.default.string, - beep: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.object, _propTypes2.default.bool]), - timeout: _propTypes2.default.oneOfType([_propTypes2.default.oneOf(['none']), _propTypes2.default.number]), - html: _propTypes2.default.bool, - onClose: _propTypes2.default.func, - onShow: _propTypes2.default.func, - customFields: _propTypes2.default.object, - contentTemplate: _propTypes2.default.func - }; - - exports.default = SAlertContent; -}); - -/***/ }), -/* 284 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _classnames = __webpack_require__(29); - -var _classnames2 = _interopRequireDefault(_classnames); - -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); - -var _util = __webpack_require__(68); - -var _util2 = _interopRequireDefault(_util); - -var _Date = __webpack_require__(366); - -var _Date2 = _interopRequireDefault(_Date); - -var _Text = __webpack_require__(367); - -var _Text2 = _interopRequireDefault(_Text); - -var _Regex = __webpack_require__(368); - -var _Regex2 = _interopRequireDefault(_Regex); - -var _Select = __webpack_require__(369); - -var _Select2 = _interopRequireDefault(_Select); - -var _Number = __webpack_require__(370); - -var _Number2 = _interopRequireDefault(_Number); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } /* eslint default-case: 0 */ -/* eslint guard-for-in: 0 */ - - -var TableHeaderColumn = function (_Component) { - _inherits(TableHeaderColumn, _Component); - - function TableHeaderColumn(props) { - _classCallCheck(this, TableHeaderColumn); - - var _this = _possibleConstructorReturn(this, (TableHeaderColumn.__proto__ || Object.getPrototypeOf(TableHeaderColumn)).call(this, props)); - - _this.handleColumnClick = function () { - return _this.__handleColumnClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; - - _this.handleFilter = _this.handleFilter.bind(_this); - return _this; - } - - _createClass(TableHeaderColumn, [{ - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - if (nextProps.reset) { - this.cleanFiltered(); - } - } - }, { - key: '__handleColumnClick__REACT_HOT_LOADER__', - value: function __handleColumnClick__REACT_HOT_LOADER__() { - if (this.props.isOnlyHead || !this.props.dataSort) return; - var order = this.props.sort; - - if (!order && this.props.defaultASC) order = _Const2.default.SORT_ASC;else order = this.props.sort === _Const2.default.SORT_DESC ? _Const2.default.SORT_ASC : _Const2.default.SORT_DESC; - this.props.onSort(order, this.props.dataField); - } - }, { - key: 'handleFilter', - value: function handleFilter(value, type) { - var filter = this.props.filter; - - filter.emitter.handleFilter(this.props.dataField, value, type, filter); - } - }, { - key: 'getFilters', - value: function getFilters() { - var _props = this.props, - headerText = _props.headerText, - children = _props.children; - - switch (this.props.filter.type) { - case _Const2.default.FILTER_TYPE.TEXT: - { - return _react2.default.createElement(_Text2.default, _extends({ ref: 'textFilter' }, this.props.filter, { - columnName: headerText || children, filterHandler: this.handleFilter })); - } - case _Const2.default.FILTER_TYPE.REGEX: - { - return _react2.default.createElement(_Regex2.default, _extends({ ref: 'regexFilter' }, this.props.filter, { - columnName: headerText || children, filterHandler: this.handleFilter })); - } - case _Const2.default.FILTER_TYPE.SELECT: - { - return _react2.default.createElement(_Select2.default, _extends({ ref: 'selectFilter' }, this.props.filter, { - columnName: headerText || children, filterHandler: this.handleFilter })); - } - case _Const2.default.FILTER_TYPE.NUMBER: - { - return _react2.default.createElement(_Number2.default, _extends({ ref: 'numberFilter' }, this.props.filter, { - columnName: headerText || children, filterHandler: this.handleFilter })); - } - case _Const2.default.FILTER_TYPE.DATE: - { - return _react2.default.createElement(_Date2.default, _extends({ ref: 'dateFilter' }, this.props.filter, { - columnName: headerText || children, filterHandler: this.handleFilter })); - } - case _Const2.default.FILTER_TYPE.CUSTOM: - { - var elm = this.props.filter.getElement(this.handleFilter, this.props.filter.customFilterParameters); - - return _react2.default.cloneElement(elm, { ref: 'customFilter' }); - } - } - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - this.refs['header-col'].setAttribute('data-field', this.props.dataField); - } - }, { - key: 'renderDefaultCaret', - value: function renderDefaultCaret(dataSort, isBootstrap4) { - if (!dataSort) return null; - if (isBootstrap4) { - return _react2.default.createElement('span', { className: 'order fa fa-sort', - style: { margin: '10px 0 10px 5px', color: '#ccc' } }); - } else { - return _react2.default.createElement( - 'span', - { className: 'order' }, - _react2.default.createElement( - 'span', - { className: 'dropdown' }, - _react2.default.createElement('span', { className: 'caret', style: { margin: '10px 0 10px 5px', color: '#ccc' } }) - ), - _react2.default.createElement( - 'span', - { className: 'dropup' }, - _react2.default.createElement('span', { className: 'caret', style: { margin: '10px 0', color: '#ccc' } }) - ) - ); - } - } - }, { - key: 'render', - value: function render() { - var defaultCaret = void 0; - var sortCaret = void 0; - var _props2 = this.props, - headerText = _props2.headerText, - dataAlign = _props2.dataAlign, - dataField = _props2.dataField, - headerAlign = _props2.headerAlign, - headerTitle = _props2.headerTitle, - hidden = _props2.hidden, - sort = _props2.sort, - dataSort = _props2.dataSort, - sortIndicator = _props2.sortIndicator, - children = _props2.children, - caretRender = _props2.caretRender, - className = _props2.className, - isOnlyHead = _props2.isOnlyHead, - version = _props2.version, - style = _props2.thStyle; - - var thStyle = _extends({ - textAlign: headerAlign || dataAlign, - display: hidden ? 'none' : null - }, style); - var isBootstrap4 = _util2.default.isBootstrap4(version); - if (!isOnlyHead) { - if (sortIndicator) { - defaultCaret = this.renderDefaultCaret(dataSort, isBootstrap4); - } - sortCaret = sort ? _util2.default.renderReactSortCaret(sort, isBootstrap4) : defaultCaret; - if (caretRender) { - sortCaret = caretRender(sort, dataField); - } - } - - var classes = (0, _classnames2.default)(_util2.default.isFunction(className) ? className() : className, !isOnlyHead && dataSort ? 'sort-column' : ''); - - var attr = {}; - if (headerTitle) { - if (typeof children === 'string' && !headerText) { - attr.title = children; - } else { - attr.title = headerText; - } - } - return _react2.default.createElement( - 'th', - _extends({ ref: 'header-col', - className: classes, - style: thStyle, - onClick: this.handleColumnClick, - rowSpan: this.props.rowSpan, - colSpan: this.props.colSpan, - 'data-is-only-head': this.props.isOnlyHead - }, attr), - children, - sortCaret, - _react2.default.createElement( - 'div', - { onClick: function onClick(e) { - return e.stopPropagation(); - } }, - this.props.filter && !isOnlyHead ? this.getFilters() : null - ) - ); - } - }, { - key: 'cleanFiltered', - value: function cleanFiltered() { - if (!this.props.filter) return; - - switch (this.props.filter.type) { - case _Const2.default.FILTER_TYPE.TEXT: - { - this.refs.textFilter.cleanFiltered(); - break; - } - case _Const2.default.FILTER_TYPE.REGEX: - { - this.refs.regexFilter.cleanFiltered(); - break; - } - case _Const2.default.FILTER_TYPE.SELECT: - { - this.refs.selectFilter.cleanFiltered(); - break; - } - case _Const2.default.FILTER_TYPE.NUMBER: - { - this.refs.numberFilter.cleanFiltered(); - break; - } - case _Const2.default.FILTER_TYPE.DATE: - { - this.refs.dateFilter.cleanFiltered(); - break; - } - case _Const2.default.FILTER_TYPE.CUSTOM: - { - this.refs.customFilter.cleanFiltered(); - break; - } - } - } - }, { - key: 'applyFilter', - value: function applyFilter(val) { - if (!this.props.filter) return; - switch (this.props.filter.type) { - case _Const2.default.FILTER_TYPE.TEXT: - { - this.refs.textFilter.applyFilter(val); - break; - } - case _Const2.default.FILTER_TYPE.REGEX: - { - this.refs.regexFilter.applyFilter(val); - break; - } - case _Const2.default.FILTER_TYPE.SELECT: - { - this.refs.selectFilter.applyFilter(val); - break; - } - case _Const2.default.FILTER_TYPE.NUMBER: - { - this.refs.numberFilter.applyFilter(val); - break; - } - case _Const2.default.FILTER_TYPE.DATE: - { - this.refs.dateFilter.applyFilter(val); - break; - } - } - } - }]); - - return TableHeaderColumn; -}(_react.Component); - -var filterTypeArray = []; -for (var key in _Const2.default.FILTER_TYPE) { - filterTypeArray.push(_Const2.default.FILTER_TYPE[key]); -} - -TableHeaderColumn.propTypes = { - dataField: _propTypes2.default.string, - dataAlign: _propTypes2.default.string, - headerAlign: _propTypes2.default.string, - headerTitle: _propTypes2.default.bool, - headerText: _propTypes2.default.string, - dataSort: _propTypes2.default.bool, - onSort: _propTypes2.default.func, - dataFormat: _propTypes2.default.func, - csvFormat: _propTypes2.default.func, - csvHeader: _propTypes2.default.string, - isKey: _propTypes2.default.bool, - editable: _propTypes2.default.any, - hidden: _propTypes2.default.bool, - hiddenOnInsert: _propTypes2.default.bool, - searchable: _propTypes2.default.bool, - className: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.func]), - width: _propTypes2.default.string, - sortFunc: _propTypes2.default.func, - sortFuncExtraData: _propTypes2.default.any, - columnClassName: _propTypes2.default.any, - editColumnClassName: _propTypes2.default.any, - invalidEditColumnClassName: _propTypes2.default.any, - columnTitle: _propTypes2.default.bool, - filterFormatted: _propTypes2.default.bool, - filterValue: _propTypes2.default.func, - sort: _propTypes2.default.string, - caretRender: _propTypes2.default.func, - formatExtraData: _propTypes2.default.any, - csvFormatExtraData: _propTypes2.default.any, - filter: _propTypes2.default.shape({ - type: _propTypes2.default.oneOf(filterTypeArray), - delay: _propTypes2.default.number, - options: _propTypes2.default.oneOfType([_propTypes2.default.object, // for SelectFilter - _propTypes2.default.arrayOf(_propTypes2.default.number) // for NumberFilter - ]), - numberComparators: _propTypes2.default.arrayOf(_propTypes2.default.string), - emitter: _propTypes2.default.object, - placeholder: _propTypes2.default.string, - getElement: _propTypes2.default.func, - customFilterParameters: _propTypes2.default.object, - condition: _propTypes2.default.oneOf([_Const2.default.FILTER_COND_EQ, _Const2.default.FILTER_COND_LIKE]) - }), - sortIndicator: _propTypes2.default.bool, - export: _propTypes2.default.bool, - expandable: _propTypes2.default.bool, - tdAttr: _propTypes2.default.object, - editTdAttr: _propTypes2.default.object, - tdStyle: _propTypes2.default.object, - thStyle: _propTypes2.default.object, - keyValidator: _propTypes2.default.bool, - defaultASC: _propTypes2.default.bool -}; - -TableHeaderColumn.defaultProps = { - dataAlign: 'left', - headerAlign: undefined, - headerTitle: true, - dataSort: false, - dataFormat: undefined, - csvFormat: undefined, - csvHeader: undefined, - isKey: false, - editable: true, - onSort: undefined, - hidden: false, - hiddenOnInsert: false, - searchable: true, - className: '', - columnTitle: false, - width: null, - sortFunc: undefined, - columnClassName: '', - editColumnClassName: '', - invalidEditColumnClassName: '', - filterFormatted: false, - filterValue: undefined, - sort: undefined, - formatExtraData: undefined, - sortFuncExtraData: undefined, - filter: undefined, - sortIndicator: true, - expandable: true, - tdAttr: undefined, - editTdAttr: undefined, - tdStyle: undefined, - thStyle: undefined, - keyValidator: false, - defaultASC: false -}; - -var _default = TableHeaderColumn; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(TableHeaderColumn, 'TableHeaderColumn', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableHeaderColumn.js'); - - __REACT_HOT_LOADER__.register(filterTypeArray, 'filterTypeArray', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableHeaderColumn.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableHeaderColumn.js'); -}(); - -; - -/***/ }), -/* 285 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _util = __webpack_require__(68); - -var _util2 = _interopRequireDefault(_util); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -var editor = function editor(editable, attr, format, editorClass, defaultValue, ignoreEditable, row) { - if (editable === true || editable === false && ignoreEditable || typeof editable === 'string') { - // simple declare - var type = editable ? 'text' : editable; - return _react2.default.createElement('input', _extends({}, attr, { type: type, defaultValue: defaultValue, - className: (editorClass || '') + ' form-control editor edit-text' })); - } else if (!editable) { - var _type = editable ? 'text' : editable; - return _react2.default.createElement('input', _extends({}, attr, { type: _type, defaultValue: defaultValue, - disabled: 'disabled', - className: (editorClass || '') + ' form-control editor edit-text' })); - } else if (editable && (editable.type === undefined || editable.type === null || editable.type.trim() === '')) { - var _type2 = editable ? 'text' : editable; - return _react2.default.createElement('input', _extends({}, attr, { type: _type2, defaultValue: defaultValue, - className: (editorClass || '') + ' form-control editor edit-text' })); - } else if (editable.type) { - // standard declare - // put style if exist - editable.style && (attr.style = editable.style); - // put class if exist - attr.className = (editorClass || '') + ' form-control editor edit-' + editable.type + (editable.className ? ' ' + editable.className : ''); - - if (editable.type === 'select') { - // process select input - var options = []; - var values = editable.options.values; - var _editable$options = editable.options, - textKey = _editable$options.textKey, - valueKey = _editable$options.valueKey; - - if (_util2.default.isFunction(values)) { - values = values(row); - } - if (Array.isArray(values)) { - // only can use arrray data for options - var text = void 0; - var value = void 0; - options = values.map(function (option, i) { - if ((typeof option === 'undefined' ? 'undefined' : _typeof(option)) === 'object') { - text = textKey ? option[textKey] : option.text; - value = valueKey ? option[valueKey] : option.value; - } else { - text = format ? format(option) : option; - value = option; - } - return _react2.default.createElement( - 'option', - { key: 'option' + i, value: value }, - text - ); - }); - } - return _react2.default.createElement( - 'select', - _extends({}, attr, { defaultValue: defaultValue }), - options - ); - } else if (editable.type === 'textarea') { - // process textarea input - // put other if exist - editable.cols && (attr.cols = editable.cols); - editable.rows && (attr.rows = editable.rows); - var saveBtn = void 0; - var keyUpHandler = attr.onKeyDown; - if (keyUpHandler) { - attr.onKeyDown = function (e) { - if (e.keyCode !== 13) { - // not Pressed ENTER - keyUpHandler(e); - } - }; - saveBtn = _react2.default.createElement( - 'button', - { - className: 'btn btn-info btn-xs textarea-save-btn', - onClick: keyUpHandler }, - 'save' - ); - } - return _react2.default.createElement( - 'div', - null, - _react2.default.createElement('textarea', _extends({}, attr, { defaultValue: defaultValue })), - saveBtn - ); - } else if (editable.type === 'checkbox') { - var _values = 'true:false'; - if (editable.options && editable.options.values) { - // values = editable.options.values.split(':'); - _values = editable.options.values; - } - attr.className = attr.className.replace('form-control', ''); - attr.className += ' checkbox pull-right'; - - var checked = defaultValue && defaultValue.toString() === _values.split(':')[0] ? true : false; - - return _react2.default.createElement('input', _extends({}, attr, { type: 'checkbox', - value: _values, defaultChecked: checked })); - } else if (editable.type === 'datetime') { - return _react2.default.createElement('input', _extends({}, attr, { type: 'datetime-local', defaultValue: defaultValue })); - } else { - // process other input type. as password,url,email... - return _react2.default.createElement('input', _extends({}, attr, { type: editable.type, defaultValue: defaultValue })); - } - } - // default return for other case of editable - return _react2.default.createElement('input', _extends({}, attr, { type: 'text', - className: (editorClass || '') + ' form-control editor edit-text' })); -}; - -var _default = editor; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(editor, 'editor', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/Editor.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/Editor.js'); -}(); - -; - -/***/ }), -/* 286 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.notice = undefined; - -var _reactSAlert = __webpack_require__(282); - -var _reactSAlert2 = _interopRequireDefault(_reactSAlert); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -var notice = function notice(type, msg, title) { - var titleHTML = title ? '<h4><strong>' + title + '</strong></h4>' : ''; - - var bodyHTML = '\n ' + titleHTML + '\n <div>\n <span class=\'fa fa-exclamation-triangle glyphicon glyphicon-alert\'></span> \n <span>' + msg + '</span>\n </div>\n '; - - _reactSAlert2.default.error(bodyHTML, { - position: 'top-right', - timeout: 3000, - html: true, - effect: 'scale' - }); -}; - -exports.notice = notice; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(notice, 'notice', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/Notification.js'); -}(); - -; - -/***/ }), -/* 287 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var sizePerPageDefaultClass = 'react-bs-table-sizePerPage-dropdown'; - -var SizePerPageDropDown = function (_Component) { - _inherits(SizePerPageDropDown, _Component); - - function SizePerPageDropDown() { - _classCallCheck(this, SizePerPageDropDown); - - return _possibleConstructorReturn(this, (SizePerPageDropDown.__proto__ || Object.getPrototypeOf(SizePerPageDropDown)).apply(this, arguments)); - } - - _createClass(SizePerPageDropDown, [{ - key: 'render', - value: function render() { - var _props = this.props, - open = _props.open, - hidden = _props.hidden, - onClick = _props.onClick, - options = _props.options, - className = _props.className, - variation = _props.variation, - btnContextual = _props.btnContextual, - currSizePerPage = _props.currSizePerPage; - - - var openClass = open ? 'open show' : ''; - var dropDownStyle = { visibility: hidden ? 'hidden' : 'visible' }; - - return _react2.default.createElement( - 'span', - { style: dropDownStyle, - className: variation + ' ' + openClass + ' ' + className + ' ' + sizePerPageDefaultClass }, - _react2.default.createElement( - 'button', - { className: 'btn ' + btnContextual + ' dropdown-toggle', - id: 'pageDropDown', 'data-toggle': 'dropdown', - 'aria-expanded': open, - onClick: onClick }, - currSizePerPage, - _react2.default.createElement( - 'span', - null, - ' ', - _react2.default.createElement('span', { className: 'caret' }) - ) - ), - _react2.default.createElement( - 'ul', - { className: 'dropdown-menu', role: 'menu', 'aria-labelledby': 'pageDropDown' }, - options - ) - ); - } - }]); - - return SizePerPageDropDown; -}(_react.Component); - -SizePerPageDropDown.propTypes = { - open: _propTypes2.default.bool, - hidden: _propTypes2.default.bool, - btnContextual: _propTypes2.default.string, - currSizePerPage: _propTypes2.default.string, - options: _propTypes2.default.array, - variation: _propTypes2.default.oneOf(['dropdown', 'dropup']), - className: _propTypes2.default.string, - onClick: _propTypes2.default.func -}; -SizePerPageDropDown.defaultProps = { - open: false, - hidden: false, - btnContextual: 'btn-default btn-secondary', - variation: 'dropdown', - className: '' -}; - -var _default = SizePerPageDropDown; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(sizePerPageDefaultClass, 'sizePerPageDefaultClass', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/pagination/SizePerPageDropDown.js'); - - __REACT_HOT_LOADER__.register(SizePerPageDropDown, 'SizePerPageDropDown', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/pagination/SizePerPageDropDown.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/pagination/SizePerPageDropDown.js'); -}(); - -; - -/***/ }), -/* 288 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -/** - * Copyright 2015-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - */ - -(function(f) { - if (true) { - module.exports = f(__webpack_require__(4)); - /* global define */ - } else if (typeof define === 'function' && define.amd) { - define(['react'], f); - } else { - var g; - if (typeof window !== 'undefined') { - g = window; - } else if (typeof global !== 'undefined') { - g = global; - } else if (typeof self !== 'undefined') { - g = self; - } else { - g = this; - } - - if (typeof g.React === 'undefined') { - throw Error('React module should be required before ReactDOMFactories'); - } - - g.ReactDOMFactories = f(g.React); - } -})(function(React) { - /** - * Create a factory that creates HTML tag elements. - */ - function createDOMFactory(type) { - var factory = React.createElement.bind(null, type); - // Expose the type on the factory and the prototype so that it can be - // easily accessed on elements. E.g. `<Foo />.type === Foo`. - // This should not be named `constructor` since this may not be the function - // that created the element, and it may not even be a constructor. - factory.type = type; - return factory; - }; + for (propKey in nextProps) { + var nextProp = nextProps[propKey]; + var lastProp = propKey === STYLE ? this._previousStyleCopy : lastProps != null ? lastProps[propKey] : undefined; + if (!nextProps.hasOwnProperty(propKey) || nextProp === lastProp || nextProp == null && lastProp == null) { + continue; + } + if (propKey === STYLE) { + if (nextProp) { + if (process.env.NODE_ENV !== 'production') { + checkAndWarnForMutatedStyle(this._previousStyleCopy, this._previousStyle, this); + this._previousStyle = nextProp; + } + nextProp = this._previousStyleCopy = _assign({}, nextProp); + } else { + this._previousStyleCopy = null; + } + if (lastProp) { + // Unset styles on `lastProp` but not on `nextProp`. + for (styleName in lastProp) { + if (lastProp.hasOwnProperty(styleName) && (!nextProp || !nextProp.hasOwnProperty(styleName))) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = ''; + } + } + // Update styles that changed since `lastProp`. + for (styleName in nextProp) { + if (nextProp.hasOwnProperty(styleName) && lastProp[styleName] !== nextProp[styleName]) { + styleUpdates = styleUpdates || {}; + styleUpdates[styleName] = nextProp[styleName]; + } + } + } else { + // Relies on `updateStylesByID` not mutating `styleUpdates`. + styleUpdates = nextProp; + } + } else if (registrationNameModules.hasOwnProperty(propKey)) { + if (nextProp) { + enqueuePutListener(this, propKey, nextProp, transaction); + } else if (lastProp) { + deleteListener(this, propKey); + } + } else if (isCustomComponent(this._tag, nextProps)) { + if (!RESERVED_PROPS.hasOwnProperty(propKey)) { + DOMPropertyOperations.setValueForAttribute(getNode(this), propKey, nextProp); + } + } else if (DOMProperty.properties[propKey] || DOMProperty.isCustomAttribute(propKey)) { + var node = getNode(this); + // If we're updating to null or undefined, we should remove the property + // from the DOM node instead of inadvertently setting to a string. This + // brings us in line with the same behavior we have on initial render. + if (nextProp != null) { + DOMPropertyOperations.setValueForProperty(node, propKey, nextProp); + } else { + DOMPropertyOperations.deleteValueForProperty(node, propKey); + } + } + } + if (styleUpdates) { + CSSPropertyOperations.setValueForStyles(getNode(this), styleUpdates, this); + } + }, /** - * Creates a mapping from supported HTML tags to `ReactDOMComponent` classes. + * Reconciles the children with the various properties that affect the + * children content. + * + * @param {object} lastProps + * @param {object} nextProps + * @param {ReactReconcileTransaction} transaction + * @param {object} context */ - var ReactDOMFactories = { - a: createDOMFactory('a'), - abbr: createDOMFactory('abbr'), - address: createDOMFactory('address'), - area: createDOMFactory('area'), - article: createDOMFactory('article'), - aside: createDOMFactory('aside'), - audio: createDOMFactory('audio'), - b: createDOMFactory('b'), - base: createDOMFactory('base'), - bdi: createDOMFactory('bdi'), - bdo: createDOMFactory('bdo'), - big: createDOMFactory('big'), - blockquote: createDOMFactory('blockquote'), - body: createDOMFactory('body'), - br: createDOMFactory('br'), - button: createDOMFactory('button'), - canvas: createDOMFactory('canvas'), - caption: createDOMFactory('caption'), - cite: createDOMFactory('cite'), - code: createDOMFactory('code'), - col: createDOMFactory('col'), - colgroup: createDOMFactory('colgroup'), - data: createDOMFactory('data'), - datalist: createDOMFactory('datalist'), - dd: createDOMFactory('dd'), - del: createDOMFactory('del'), - details: createDOMFactory('details'), - dfn: createDOMFactory('dfn'), - dialog: createDOMFactory('dialog'), - div: createDOMFactory('div'), - dl: createDOMFactory('dl'), - dt: createDOMFactory('dt'), - em: createDOMFactory('em'), - embed: createDOMFactory('embed'), - fieldset: createDOMFactory('fieldset'), - figcaption: createDOMFactory('figcaption'), - figure: createDOMFactory('figure'), - footer: createDOMFactory('footer'), - form: createDOMFactory('form'), - h1: createDOMFactory('h1'), - h2: createDOMFactory('h2'), - h3: createDOMFactory('h3'), - h4: createDOMFactory('h4'), - h5: createDOMFactory('h5'), - h6: createDOMFactory('h6'), - head: createDOMFactory('head'), - header: createDOMFactory('header'), - hgroup: createDOMFactory('hgroup'), - hr: createDOMFactory('hr'), - html: createDOMFactory('html'), - i: createDOMFactory('i'), - iframe: createDOMFactory('iframe'), - img: createDOMFactory('img'), - input: createDOMFactory('input'), - ins: createDOMFactory('ins'), - kbd: createDOMFactory('kbd'), - keygen: createDOMFactory('keygen'), - label: createDOMFactory('label'), - legend: createDOMFactory('legend'), - li: createDOMFactory('li'), - link: createDOMFactory('link'), - main: createDOMFactory('main'), - map: createDOMFactory('map'), - mark: createDOMFactory('mark'), - menu: createDOMFactory('menu'), - menuitem: createDOMFactory('menuitem'), - meta: createDOMFactory('meta'), - meter: createDOMFactory('meter'), - nav: createDOMFactory('nav'), - noscript: createDOMFactory('noscript'), - object: createDOMFactory('object'), - ol: createDOMFactory('ol'), - optgroup: createDOMFactory('optgroup'), - option: createDOMFactory('option'), - output: createDOMFactory('output'), - p: createDOMFactory('p'), - param: createDOMFactory('param'), - picture: createDOMFactory('picture'), - pre: createDOMFactory('pre'), - progress: createDOMFactory('progress'), - q: createDOMFactory('q'), - rp: createDOMFactory('rp'), - rt: createDOMFactory('rt'), - ruby: createDOMFactory('ruby'), - s: createDOMFactory('s'), - samp: createDOMFactory('samp'), - script: createDOMFactory('script'), - section: createDOMFactory('section'), - select: createDOMFactory('select'), - small: createDOMFactory('small'), - source: createDOMFactory('source'), - span: createDOMFactory('span'), - strong: createDOMFactory('strong'), - style: createDOMFactory('style'), - sub: createDOMFactory('sub'), - summary: createDOMFactory('summary'), - sup: createDOMFactory('sup'), - table: createDOMFactory('table'), - tbody: createDOMFactory('tbody'), - td: createDOMFactory('td'), - textarea: createDOMFactory('textarea'), - tfoot: createDOMFactory('tfoot'), - th: createDOMFactory('th'), - thead: createDOMFactory('thead'), - time: createDOMFactory('time'), - title: createDOMFactory('title'), - tr: createDOMFactory('tr'), - track: createDOMFactory('track'), - u: createDOMFactory('u'), - ul: createDOMFactory('ul'), - var: createDOMFactory('var'), - video: createDOMFactory('video'), - wbr: createDOMFactory('wbr'), - - // SVG - circle: createDOMFactory('circle'), - clipPath: createDOMFactory('clipPath'), - defs: createDOMFactory('defs'), - ellipse: createDOMFactory('ellipse'), - g: createDOMFactory('g'), - image: createDOMFactory('image'), - line: createDOMFactory('line'), - linearGradient: createDOMFactory('linearGradient'), - mask: createDOMFactory('mask'), - path: createDOMFactory('path'), - pattern: createDOMFactory('pattern'), - polygon: createDOMFactory('polygon'), - polyline: createDOMFactory('polyline'), - radialGradient: createDOMFactory('radialGradient'), - rect: createDOMFactory('rect'), - stop: createDOMFactory('stop'), - svg: createDOMFactory('svg'), - text: createDOMFactory('text'), - tspan: createDOMFactory('tspan'), - }; - - // due to wrapper and conditionals at the top, this will either become - // `module.exports ReactDOMFactories` if that is available, - // otherwise it will be defined via `define(['react'], ReactDOMFactories)` - // if that is available, - // otherwise it will be defined as global variable. - return ReactDOMFactories; -}); - - - -/***/ }), -/* 289 */ -/***/ (function(module, exports) { - -/*! - * Adapted from jQuery UI core - * - * http://jqueryui.com - * - * Copyright 2014 jQuery Foundation and other contributors - * Released under the MIT license. - * http://jquery.org/license - * - * http://api.jqueryui.com/category/ui-core/ - */ - -function focusable(element, isTabIndexNotNaN) { - var nodeName = element.nodeName.toLowerCase(); - return (/input|select|textarea|button|object/.test(nodeName) ? - !element.disabled : - "a" === nodeName ? - element.href || isTabIndexNotNaN : - isTabIndexNotNaN) && visible(element); -} - -function hidden(el) { - return (el.offsetWidth <= 0 && el.offsetHeight <= 0) || - el.style.display === 'none'; -} - -function visible(element) { - while (element) { - if (element === document.body) break; - if (hidden(element)) return false; - element = element.parentNode; - } - return true; -} - -function tabbable(element) { - var tabIndex = element.getAttribute('tabindex'); - if (tabIndex === null) tabIndex = undefined; - var isTabIndexNaN = isNaN(tabIndex); - return (isTabIndexNaN || tabIndex >= 0) && focusable(element, !isTabIndexNaN); -} - -function findTabbableDescendants(element) { - return [].slice.call(element.querySelectorAll('*'), 0).filter(function(el) { - return tabbable(el); - }); -} - -module.exports = findTabbableDescendants; - - - -/***/ }), -/* 290 */ -/***/ (function(module, exports) { - -/** - * lodash (Custom Build) <https://lodash.com/> - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors <https://jquery.org/> - * Released under MIT license <https://lodash.com/license> - * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */ - -/** Used as references for various `Number` constants. */ -var MAX_SAFE_INTEGER = 9007199254740991; - -/** `Object#toString` result references. */ -var argsTag = '[object Arguments]', - funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; - -/** Used to detect unsigned integer values. */ -var reIsUint = /^(?:0|[1-9]\d*)$/; - -/** - * A faster alternative to `Function#apply`, this function invokes `func` - * with the `this` binding of `thisArg` and the arguments of `args`. - * - * @private - * @param {Function} func The function to invoke. - * @param {*} thisArg The `this` binding of `func`. - * @param {Array} args The arguments to invoke `func` with. - * @returns {*} Returns the result of `func`. - */ -function apply(func, thisArg, args) { - switch (args.length) { - case 0: return func.call(thisArg); - case 1: return func.call(thisArg, args[0]); - case 2: return func.call(thisArg, args[0], args[1]); - case 3: return func.call(thisArg, args[0], args[1], args[2]); - } - return func.apply(thisArg, args); -} - -/** - * The base implementation of `_.times` without support for iteratee shorthands - * or max array length checks. - * - * @private - * @param {number} n The number of times to invoke `iteratee`. - * @param {Function} iteratee The function invoked per iteration. - * @returns {Array} Returns the array of results. - */ -function baseTimes(n, iteratee) { - var index = -1, - result = Array(n); - - while (++index < n) { - result[index] = iteratee(index); - } - return result; -} - -/** - * Creates a unary function that invokes `func` with its argument transformed. - * - * @private - * @param {Function} func The function to wrap. - * @param {Function} transform The argument transform. - * @returns {Function} Returns the new function. - */ -function overArg(func, transform) { - return function(arg) { - return func(transform(arg)); - }; -} - -/** Used for built-in method references. */ -var objectProto = Object.prototype; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; - -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; - -/** Built-in value references. */ -var propertyIsEnumerable = objectProto.propertyIsEnumerable; - -/* Built-in method references for those with the same name as other `lodash` methods. */ -var nativeKeys = overArg(Object.keys, Object), - nativeMax = Math.max; - -/** Detect if properties shadowing those on `Object.prototype` are non-enumerable. */ -var nonEnumShadows = !propertyIsEnumerable.call({ 'valueOf': 1 }, 'valueOf'); - -/** - * Creates an array of the enumerable property names of the array-like `value`. - * - * @private - * @param {*} value The value to query. - * @param {boolean} inherited Specify returning inherited property names. - * @returns {Array} Returns the array of property names. - */ -function arrayLikeKeys(value, inherited) { - // Safari 8.1 makes `arguments.callee` enumerable in strict mode. - // Safari 9 makes `arguments.length` enumerable in strict mode. - var result = (isArray(value) || isArguments(value)) - ? baseTimes(value.length, String) - : []; - - var length = result.length, - skipIndexes = !!length; - - for (var key in value) { - if ((inherited || hasOwnProperty.call(value, key)) && - !(skipIndexes && (key == 'length' || isIndex(key, length)))) { - result.push(key); - } - } - return result; -} - -/** - * Assigns `value` to `key` of `object` if the existing value is not equivalent - * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) - * for equality comparisons. - * - * @private - * @param {Object} object The object to modify. - * @param {string} key The key of the property to assign. - * @param {*} value The value to assign. - */ -function assignValue(object, key, value) { - var objValue = object[key]; - if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) || - (value === undefined && !(key in object))) { - object[key] = value; - } -} - -/** - * The base implementation of `_.keys` which doesn't treat sparse arrays as dense. - * - * @private - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - */ -function baseKeys(object) { - if (!isPrototype(object)) { - return nativeKeys(object); - } - var result = []; - for (var key in Object(object)) { - if (hasOwnProperty.call(object, key) && key != 'constructor') { - result.push(key); - } - } - return result; -} - -/** - * The base implementation of `_.rest` which doesn't validate or coerce arguments. - * - * @private - * @param {Function} func The function to apply a rest parameter to. - * @param {number} [start=func.length-1] The start position of the rest parameter. - * @returns {Function} Returns the new function. - */ -function baseRest(func, start) { - start = nativeMax(start === undefined ? (func.length - 1) : start, 0); - return function() { - var args = arguments, - index = -1, - length = nativeMax(args.length - start, 0), - array = Array(length); - - while (++index < length) { - array[index] = args[start + index]; - } - index = -1; - var otherArgs = Array(start + 1); - while (++index < start) { - otherArgs[index] = args[index]; - } - otherArgs[start] = array; - return apply(func, this, otherArgs); - }; -} - -/** - * Copies properties of `source` to `object`. - * - * @private - * @param {Object} source The object to copy properties from. - * @param {Array} props The property identifiers to copy. - * @param {Object} [object={}] The object to copy properties to. - * @param {Function} [customizer] The function to customize copied values. - * @returns {Object} Returns `object`. - */ -function copyObject(source, props, object, customizer) { - object || (object = {}); - - var index = -1, - length = props.length; - - while (++index < length) { - var key = props[index]; - - var newValue = customizer - ? customizer(object[key], source[key], key, object, source) - : undefined; - - assignValue(object, key, newValue === undefined ? source[key] : newValue); - } - return object; -} - -/** - * Creates a function like `_.assign`. - * - * @private - * @param {Function} assigner The function to assign values. - * @returns {Function} Returns the new assigner function. - */ -function createAssigner(assigner) { - return baseRest(function(object, sources) { - var index = -1, - length = sources.length, - customizer = length > 1 ? sources[length - 1] : undefined, - guard = length > 2 ? sources[2] : undefined; - - customizer = (assigner.length > 3 && typeof customizer == 'function') - ? (length--, customizer) - : undefined; - - if (guard && isIterateeCall(sources[0], sources[1], guard)) { - customizer = length < 3 ? undefined : customizer; - length = 1; - } - object = Object(object); - while (++index < length) { - var source = sources[index]; - if (source) { - assigner(object, source, index, customizer); - } - } - return object; - }); -} - -/** - * Checks if `value` is a valid array-like index. - * - * @private - * @param {*} value The value to check. - * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. - * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. - */ -function isIndex(value, length) { - length = length == null ? MAX_SAFE_INTEGER : length; - return !!length && - (typeof value == 'number' || reIsUint.test(value)) && - (value > -1 && value % 1 == 0 && value < length); -} - -/** - * Checks if the given arguments are from an iteratee call. - * - * @private - * @param {*} value The potential iteratee value argument. - * @param {*} index The potential iteratee index or key argument. - * @param {*} object The potential iteratee object argument. - * @returns {boolean} Returns `true` if the arguments are from an iteratee call, - * else `false`. - */ -function isIterateeCall(value, index, object) { - if (!isObject(object)) { - return false; - } - var type = typeof index; - if (type == 'number' - ? (isArrayLike(object) && isIndex(index, object.length)) - : (type == 'string' && index in object) - ) { - return eq(object[index], value); - } - return false; -} - -/** - * Checks if `value` is likely a prototype object. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a prototype, else `false`. - */ -function isPrototype(value) { - var Ctor = value && value.constructor, - proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto; - - return value === proto; -} - -/** - * Performs a - * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) - * comparison between two values to determine if they are equivalent. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to compare. - * @param {*} other The other value to compare. - * @returns {boolean} Returns `true` if the values are equivalent, else `false`. - * @example - * - * var object = { 'a': 1 }; - * var other = { 'a': 1 }; - * - * _.eq(object, object); - * // => true - * - * _.eq(object, other); - * // => false - * - * _.eq('a', 'a'); - * // => true - * - * _.eq('a', Object('a')); - * // => false - * - * _.eq(NaN, NaN); - * // => true - */ -function eq(value, other) { - return value === other || (value !== value && other !== other); -} - -/** - * Checks if `value` is likely an `arguments` object. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an `arguments` object, - * else `false`. - * @example - * - * _.isArguments(function() { return arguments; }()); - * // => true - * - * _.isArguments([1, 2, 3]); - * // => false - */ -function isArguments(value) { - // Safari 8.1 makes `arguments.callee` enumerable in strict mode. - return isArrayLikeObject(value) && hasOwnProperty.call(value, 'callee') && - (!propertyIsEnumerable.call(value, 'callee') || objectToString.call(value) == argsTag); -} - -/** - * Checks if `value` is classified as an `Array` object. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an array, else `false`. - * @example - * - * _.isArray([1, 2, 3]); - * // => true - * - * _.isArray(document.body.children); - * // => false - * - * _.isArray('abc'); - * // => false - * - * _.isArray(_.noop); - * // => false - */ -var isArray = Array.isArray; - -/** - * Checks if `value` is array-like. A value is considered array-like if it's - * not a function and has a `value.length` that's an integer greater than or - * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is array-like, else `false`. - * @example - * - * _.isArrayLike([1, 2, 3]); - * // => true - * - * _.isArrayLike(document.body.children); - * // => true - * - * _.isArrayLike('abc'); - * // => true - * - * _.isArrayLike(_.noop); - * // => false - */ -function isArrayLike(value) { - return value != null && isLength(value.length) && !isFunction(value); -} - -/** - * This method is like `_.isArrayLike` except that it also checks if `value` - * is an object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an array-like object, - * else `false`. - * @example - * - * _.isArrayLikeObject([1, 2, 3]); - * // => true - * - * _.isArrayLikeObject(document.body.children); - * // => true - * - * _.isArrayLikeObject('abc'); - * // => false - * - * _.isArrayLikeObject(_.noop); - * // => false - */ -function isArrayLikeObject(value) { - return isObjectLike(value) && isArrayLike(value); -} - -/** - * Checks if `value` is classified as a `Function` object. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a function, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false - */ -function isFunction(value) { - // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 8-9 which returns 'object' for typed array and other constructors. - var tag = isObject(value) ? objectToString.call(value) : ''; - return tag == funcTag || tag == genTag; -} - -/** - * Checks if `value` is a valid array-like length. - * - * **Note:** This method is loosely based on - * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength). - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. - * @example - * - * _.isLength(3); - * // => true - * - * _.isLength(Number.MIN_VALUE); - * // => false - * - * _.isLength(Infinity); - * // => false - * - * _.isLength('3'); - * // => false - */ -function isLength(value) { - return typeof value == 'number' && - value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; -} - -/** - * Checks if `value` is the - * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) - * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} - -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; -} - -/** - * Assigns own enumerable string keyed properties of source objects to the - * destination object. Source objects are applied from left to right. - * Subsequent sources overwrite property assignments of previous sources. - * - * **Note:** This method mutates `object` and is loosely based on - * [`Object.assign`](https://mdn.io/Object/assign). - * - * @static - * @memberOf _ - * @since 0.10.0 - * @category Object - * @param {Object} object The destination object. - * @param {...Object} [sources] The source objects. - * @returns {Object} Returns `object`. - * @see _.assignIn - * @example - * - * function Foo() { - * this.a = 1; - * } - * - * function Bar() { - * this.c = 3; - * } - * - * Foo.prototype.b = 2; - * Bar.prototype.d = 4; - * - * _.assign({ 'a': 0 }, new Foo, new Bar); - * // => { 'a': 1, 'c': 3 } - */ -var assign = createAssigner(function(object, source) { - if (nonEnumShadows || isPrototype(source) || isArrayLike(source)) { - copyObject(source, keys(source), object); - return; - } - for (var key in source) { - if (hasOwnProperty.call(source, key)) { - assignValue(object, key, source[key]); - } - } -}); - -/** - * Creates an array of the own enumerable property names of `object`. - * - * **Note:** Non-object values are coerced to objects. See the - * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) - * for more details. - * - * @static - * @since 0.1.0 - * @memberOf _ - * @category Object - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - * @example - * - * function Foo() { - * this.a = 1; - * this.b = 2; - * } - * - * Foo.prototype.c = 3; - * - * _.keys(new Foo); - * // => ['a', 'b'] (iteration order is not guaranteed) - * - * _.keys('hi'); - * // => ['0', '1'] - */ -function keys(object) { - return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object); -} - -module.exports = assign; - - -/***/ }), -/* 291 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/** - * Copyright 2013-present, Facebook, Inc. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. An additional grant - * of patent rights can be found in the PATENTS file in the same directory. - * - */ - - - -var React = __webpack_require__(4); -var factory = __webpack_require__(113); - -if (typeof React === 'undefined') { - throw Error( - 'create-react-class could not find the React object. If you are using script tags, ' + - 'make sure that React is being loaded before create-react-class.' - ); -} - -// Hack to grab NoopUpdateQueue from isomorphic React -var ReactNoopUpdateQueue = new React.Component().updater; - -module.exports = factory( - React.Component, - React.isValidElement, - ReactNoopUpdateQueue -); - - -/***/ }), -/* 292 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _util = __webpack_require__(68); - -var _util2 = _interopRequireDefault(_util); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var InsertModalHeader = function (_Component) { - _inherits(InsertModalHeader, _Component); - - function InsertModalHeader() { - var _ref; - - var _temp, _this, _ret; - - _classCallCheck(this, InsertModalHeader); - - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = InsertModalHeader.__proto__ || Object.getPrototypeOf(InsertModalHeader)).call.apply(_ref, [this].concat(args))), _this), _this.handleCloseBtnClick = function () { - var _this2; - - return (_this2 = _this).__handleCloseBtnClick__REACT_HOT_LOADER__.apply(_this2, arguments); - }, _temp), _possibleConstructorReturn(_this, _ret); - } - - _createClass(InsertModalHeader, [{ - key: '__handleCloseBtnClick__REACT_HOT_LOADER__', - value: function __handleCloseBtnClick__REACT_HOT_LOADER__(e) { - var _props = this.props, - onModalClose = _props.onModalClose, - beforeClose = _props.beforeClose; - - beforeClose && beforeClose(e); - onModalClose(); - } - }, { - key: 'renderContent', - value: function renderContent(closeBtn) { - var _props2 = this.props, - version = _props2.version, - titleText = _props2.title; - - var title = _react2.default.createElement( - 'h4', - { key: 'title', className: 'modal-title' }, - titleText - ); - if (_util2.default.isBootstrap4(version)) { - return [title, closeBtn]; - } else { - return _react2.default.createElement( - 'span', - null, - closeBtn, - title - ); - } - } - }, { - key: 'render', - value: function render() { - var _props3 = this.props, - hideClose = _props3.hideClose, - className = _props3.className, - children = _props3.children; - - - var closeBtn = hideClose ? null : _react2.default.createElement( - 'button', - { type: 'button', - className: 'close', onClick: this.handleCloseBtnClick }, - _react2.default.createElement( - 'span', - { 'aria-hidden': 'true' }, - '\xD7' - ), - _react2.default.createElement( - 'span', - { className: 'sr-only' }, - 'Close' - ) - ); - - var content = children || this.renderContent(closeBtn); - - return _react2.default.createElement( - 'div', - { className: 'modal-header ' + className }, - content - ); - } - }]); - - return InsertModalHeader; -}(_react.Component); - -InsertModalHeader.propTypes = { - version: _propTypes2.default.string, - className: _propTypes2.default.string, - title: _propTypes2.default.string, - onModalClose: _propTypes2.default.func, - hideClose: _propTypes2.default.bool, - beforeClose: _propTypes2.default.func -}; -InsertModalHeader.defaultProps = { - version: '3', - className: '', - title: 'Add Row', - onModalClose: undefined, - hideClose: false, - beforeClose: undefined -}; - -var _default = InsertModalHeader; -exports.default = _default; -; - -var _temp2 = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(InsertModalHeader, 'InsertModalHeader', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModalHeader.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModalHeader.js'); -}(); - -; - -/***/ }), -/* 293 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var InsertModalFooter = function (_Component) { - _inherits(InsertModalFooter, _Component); - - function InsertModalFooter() { - var _ref; - - var _temp, _this, _ret; - - _classCallCheck(this, InsertModalFooter); - - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - - return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = InsertModalFooter.__proto__ || Object.getPrototypeOf(InsertModalFooter)).call.apply(_ref, [this].concat(args))), _this), _this.handleCloseBtnClick = function () { - var _this2; - - return (_this2 = _this).__handleCloseBtnClick__REACT_HOT_LOADER__.apply(_this2, arguments); - }, _this.handleSaveBtnClick = function () { - var _this3; - - return (_this3 = _this).__handleSaveBtnClick__REACT_HOT_LOADER__.apply(_this3, arguments); - }, _temp), _possibleConstructorReturn(_this, _ret); - } - - _createClass(InsertModalFooter, [{ - key: '__handleCloseBtnClick__REACT_HOT_LOADER__', - value: function __handleCloseBtnClick__REACT_HOT_LOADER__(e) { - var _props = this.props, - beforeClose = _props.beforeClose, - onModalClose = _props.onModalClose; - - beforeClose && beforeClose(e); - onModalClose(); - } - }, { - key: '__handleSaveBtnClick__REACT_HOT_LOADER__', - value: function __handleSaveBtnClick__REACT_HOT_LOADER__(e) { - var _props2 = this.props, - beforeSave = _props2.beforeSave, - onSave = _props2.onSave; - - beforeSave && beforeSave(e); - onSave(); - } - }, { - key: 'render', - value: function render() { - var _props3 = this.props, - className = _props3.className, - saveBtnText = _props3.saveBtnText, - closeBtnText = _props3.closeBtnText, - closeBtnContextual = _props3.closeBtnContextual, - saveBtnContextual = _props3.saveBtnContextual, - closeBtnClass = _props3.closeBtnClass, - saveBtnClass = _props3.saveBtnClass, - children = _props3.children; - - - var content = children || [_react2.default.createElement( - 'button', - { - key: 'closeBtn', - type: 'button', - className: 'btn ' + closeBtnContextual + ' ' + closeBtnClass, - onClick: this.handleCloseBtnClick }, - closeBtnText - ), _react2.default.createElement( - 'button', - { - key: 'saveBtn', - type: 'button', - className: 'btn ' + saveBtnContextual + ' ' + saveBtnClass, - onClick: this.handleSaveBtnClick }, - saveBtnText - )]; - - return _react2.default.createElement( - 'div', - { className: 'modal-footer ' + className }, - content - ); - } - }]); - - return InsertModalFooter; -}(_react.Component); - -InsertModalFooter.propTypes = { - className: _propTypes2.default.string, - saveBtnText: _propTypes2.default.string, - closeBtnText: _propTypes2.default.string, - closeBtnContextual: _propTypes2.default.string, - saveBtnContextual: _propTypes2.default.string, - closeBtnClass: _propTypes2.default.string, - saveBtnClass: _propTypes2.default.string, - beforeClose: _propTypes2.default.func, - beforeSave: _propTypes2.default.func, - onSave: _propTypes2.default.func, - onModalClose: _propTypes2.default.func -}; -InsertModalFooter.defaultProps = { - className: '', - saveBtnText: _Const2.default.SAVE_BTN_TEXT, - closeBtnText: _Const2.default.CLOSE_BTN_TEXT, - closeBtnContextual: 'btn-default btn-secondary', - saveBtnContextual: 'btn-primary', - closeBtnClass: '', - saveBtnClass: '', - beforeClose: undefined, - beforeSave: undefined -}; - -var _default = InsertModalFooter; -exports.default = _default; -; - -var _temp2 = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(InsertModalFooter, 'InsertModalFooter', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModalFooter.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModalFooter.js'); -}(); - -; - -/***/ }), -/* 294 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _Editor = __webpack_require__(285); - -var _Editor2 = _interopRequireDefault(_Editor); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } /* eslint react/display-name: 0 */ - - -var InsertModalBody = function (_Component) { - _inherits(InsertModalBody, _Component); - - function InsertModalBody() { - _classCallCheck(this, InsertModalBody); - - return _possibleConstructorReturn(this, (InsertModalBody.__proto__ || Object.getPrototypeOf(InsertModalBody)).apply(this, arguments)); - } - - _createClass(InsertModalBody, [{ - key: 'getFieldValue', - value: function getFieldValue() { - var _this2 = this; - - var newRow = {}; - this.props.columns.forEach(function (column, i) { - var inputVal = void 0; - if (column.autoValue) { - // when you want same auto generate value and not allow edit, example ID field - var time = new Date().getTime(); - inputVal = typeof column.autoValue === 'function' ? column.autoValue() : 'autovalue-' + time; - } else if (column.hiddenOnInsert || !column.field) { - inputVal = ''; - } else { - var dom = _this2.refs[column.field + i]; - inputVal = dom.value; - - if (column.editable && column.editable.type === 'checkbox') { - var values = inputVal.split(':'); - inputVal = dom.checked ? values[0] : values[1]; - } else if (column.customInsertEditor) { - inputVal = inputVal || dom.getFieldValue(); - } - } - newRow[column.field] = inputVal; - }, this); - return newRow; - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - columns = _props.columns, - validateState = _props.validateState, - ignoreEditable = _props.ignoreEditable; - - return _react2.default.createElement( - 'div', - { className: 'modal-body' }, - columns.map(function (column, i) { - var editable = column.editable, - format = column.format, - field = column.field, - name = column.name, - autoValue = column.autoValue, - hiddenOnInsert = column.hiddenOnInsert, - customInsertEditor = column.customInsertEditor; - - var attr = { - ref: field + i, - placeholder: editable.placeholder ? editable.placeholder : name - }; - var fieldElement = void 0; - var defaultValue = editable.defaultValue || undefined; - if (customInsertEditor) { - var getElement = customInsertEditor.getElement; - - fieldElement = getElement(column, attr, 'form-control', ignoreEditable, defaultValue); - } - - // fieldElement = false, means to use default editor when enable custom editor - // Becasuse some users want to have default editor based on some condition. - if (!customInsertEditor || fieldElement === false) { - fieldElement = (0, _Editor2.default)(editable, attr, format, '', defaultValue, ignoreEditable); - } - - if (autoValue || hiddenOnInsert || !column.field) { - // when you want same auto generate value - // and not allow edit, for example ID field - return null; - } - var error = validateState[field] ? _react2.default.createElement( - 'span', - { className: 'help-block bg-danger' }, - validateState[field] - ) : null; - return _react2.default.createElement( - 'div', - { className: 'form-group', key: field }, - _react2.default.createElement( - 'label', - null, - name - ), - fieldElement, - error - ); - }) - ); - } - }]); - - return InsertModalBody; -}(_react.Component); - -InsertModalBody.propTypes = { - columns: _propTypes2.default.array, - validateState: _propTypes2.default.object, - ignoreEditable: _propTypes2.default.bool -}; - -InsertModalBody.defaultProps = { - validateState: {}, - ignoreEditable: false -}; - -var _default = InsertModalBody; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(InsertModalBody, 'InsertModalBody', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModalBody.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModalBody.js'); -}(); - -; - -/***/ }), -/* 295 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var insertBtnDefaultClass = 'react-bs-table-add-btn'; - -var InsertButton = function (_Component) { - _inherits(InsertButton, _Component); - - function InsertButton() { - _classCallCheck(this, InsertButton); - - return _possibleConstructorReturn(this, (InsertButton.__proto__ || Object.getPrototypeOf(InsertButton)).apply(this, arguments)); - } - - _createClass(InsertButton, [{ - key: 'render', - value: function render() { - var _props = this.props, - btnContextual = _props.btnContextual, - className = _props.className, - onClick = _props.onClick, - btnGlyphicon = _props.btnGlyphicon, - btnText = _props.btnText, - children = _props.children, - rest = _objectWithoutProperties(_props, ['btnContextual', 'className', 'onClick', 'btnGlyphicon', 'btnText', 'children']); - - var content = children || _react2.default.createElement( - 'span', - null, - _react2.default.createElement('i', { className: 'fa glyphicon ' + btnGlyphicon }), - ' ', - btnText - ); - return _react2.default.createElement( - 'button', - _extends({ type: 'button', - className: 'btn ' + btnContextual + ' ' + insertBtnDefaultClass + ' ' + className, - onClick: onClick - }, rest), - content - ); - } - }]); - - return InsertButton; -}(_react.Component); - -InsertButton.propTypes = { - btnText: _propTypes2.default.string, - btnContextual: _propTypes2.default.string, - className: _propTypes2.default.string, - onClick: _propTypes2.default.func, - btnGlyphicon: _propTypes2.default.string -}; -InsertButton.defaultProps = { - btnText: _Const2.default.INSERT_BTN_TEXT, - btnContextual: 'btn-info', - className: '', - onClick: undefined, - btnGlyphicon: 'glyphicon-plus fa-plus' -}; - -var _default = InsertButton; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(insertBtnDefaultClass, 'insertBtnDefaultClass', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertButton.js'); - - __REACT_HOT_LOADER__.register(InsertButton, 'InsertButton', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertButton.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertButton.js'); -}(); - -; - -/***/ }), -/* 296 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var deleteBtnDefaultClass = 'react-bs-table-del-btn'; - -var DeleteButton = function (_Component) { - _inherits(DeleteButton, _Component); - - function DeleteButton() { - _classCallCheck(this, DeleteButton); - - return _possibleConstructorReturn(this, (DeleteButton.__proto__ || Object.getPrototypeOf(DeleteButton)).apply(this, arguments)); - } - - _createClass(DeleteButton, [{ - key: 'render', - value: function render() { - var _props = this.props, - btnContextual = _props.btnContextual, - className = _props.className, - onClick = _props.onClick, - btnGlyphicon = _props.btnGlyphicon, - btnText = _props.btnText, - children = _props.children, - rest = _objectWithoutProperties(_props, ['btnContextual', 'className', 'onClick', 'btnGlyphicon', 'btnText', 'children']); - - var content = children || _react2.default.createElement( - 'span', - null, - _react2.default.createElement('i', { className: 'fa glyphicon ' + btnGlyphicon }), - ' ', - btnText - ); - return _react2.default.createElement( - 'button', - _extends({ type: 'button', - className: 'btn ' + btnContextual + ' ' + deleteBtnDefaultClass + ' ' + className, - onClick: onClick - }, rest), - content - ); - } - }]); - - return DeleteButton; -}(_react.Component); - -DeleteButton.propTypes = { - btnText: _propTypes2.default.string, - btnContextual: _propTypes2.default.string, - className: _propTypes2.default.string, - onClick: _propTypes2.default.func, - btnGlyphicon: _propTypes2.default.string -}; -DeleteButton.defaultProps = { - btnText: _Const2.default.DELETE_BTN_TEXT, - btnContextual: 'btn-warning', - className: '', - onClick: undefined, - btnGlyphicon: 'glyphicon-trash fa-trash' -}; - -var _default = DeleteButton; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(deleteBtnDefaultClass, 'deleteBtnDefaultClass', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/DeleteButton.js'); - - __REACT_HOT_LOADER__.register(DeleteButton, 'DeleteButton', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/DeleteButton.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/DeleteButton.js'); -}(); - -; - -/***/ }), -/* 297 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var exportCsvBtnDefaultClass = 'react-bs-table-csv-btn'; - -var ExportCSVButton = function (_Component) { - _inherits(ExportCSVButton, _Component); - - function ExportCSVButton() { - _classCallCheck(this, ExportCSVButton); - - return _possibleConstructorReturn(this, (ExportCSVButton.__proto__ || Object.getPrototypeOf(ExportCSVButton)).apply(this, arguments)); - } - - _createClass(ExportCSVButton, [{ - key: 'render', - value: function render() { - var _props = this.props, - btnContextual = _props.btnContextual, - className = _props.className, - onClick = _props.onClick, - btnGlyphicon = _props.btnGlyphicon, - btnText = _props.btnText, - children = _props.children, - rest = _objectWithoutProperties(_props, ['btnContextual', 'className', 'onClick', 'btnGlyphicon', 'btnText', 'children']); - - var content = children || _react2.default.createElement( - 'span', - null, - _react2.default.createElement('i', { className: 'fa glyphicon ' + btnGlyphicon }), - ' ', - btnText - ); - return _react2.default.createElement( - 'button', - _extends({ type: 'button', - className: 'btn ' + btnContextual + ' ' + exportCsvBtnDefaultClass + ' ' + className + ' hidden-print', - onClick: onClick - }, rest), - content - ); - } - }]); - - return ExportCSVButton; -}(_react.Component); - -ExportCSVButton.propTypes = { - btnText: _propTypes2.default.string, - btnContextual: _propTypes2.default.string, - className: _propTypes2.default.string, - onClick: _propTypes2.default.func, - btnGlyphicon: _propTypes2.default.string -}; -ExportCSVButton.defaultProps = { - btnText: _Const2.default.EXPORT_CSV_TEXT, - btnContextual: 'btn-success', - className: '', - onClick: undefined, - btnGlyphicon: 'glyphicon-export fa-download' -}; - -var _default = ExportCSVButton; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(exportCsvBtnDefaultClass, 'exportCsvBtnDefaultClass', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ExportCSVButton.js'); - - __REACT_HOT_LOADER__.register(ExportCSVButton, 'ExportCSVButton', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ExportCSVButton.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ExportCSVButton.js'); -}(); - -; - -/***/ }), -/* 298 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var showSelectedOnlyBtnDefaultClass = 'react-bs-table-show-sel-only-btn'; - -var ShowSelectedOnlyButton = function (_Component) { - _inherits(ShowSelectedOnlyButton, _Component); - - function ShowSelectedOnlyButton() { - _classCallCheck(this, ShowSelectedOnlyButton); - - return _possibleConstructorReturn(this, (ShowSelectedOnlyButton.__proto__ || Object.getPrototypeOf(ShowSelectedOnlyButton)).apply(this, arguments)); - } - - _createClass(ShowSelectedOnlyButton, [{ - key: 'render', - value: function render() { - var _props = this.props, - btnContextual = _props.btnContextual, - className = _props.className, - onClick = _props.onClick, - toggle = _props.toggle, - showAllText = _props.showAllText, - showOnlySelectText = _props.showOnlySelectText, - children = _props.children, - rest = _objectWithoutProperties(_props, ['btnContextual', 'className', 'onClick', 'toggle', 'showAllText', 'showOnlySelectText', 'children']); - - var content = children || _react2.default.createElement( - 'span', - null, - toggle ? showAllText : showOnlySelectText - ); - return _react2.default.createElement( - 'button', - _extends({ type: 'button', - 'aria-pressed': 'false', - 'data-toggle': 'button', - className: 'btn ' + btnContextual + ' ' + showSelectedOnlyBtnDefaultClass + ' ' + className, - onClick: onClick - }, rest), - content - ); - } - }]); - - return ShowSelectedOnlyButton; -}(_react.Component); - -ShowSelectedOnlyButton.propTypes = { - showAllText: _propTypes2.default.string, - showOnlySelectText: _propTypes2.default.string, - toggle: _propTypes2.default.bool, - btnContextual: _propTypes2.default.string, - className: _propTypes2.default.string, - onClick: _propTypes2.default.func -}; -ShowSelectedOnlyButton.defaultProps = { - showAllText: _Const2.default.SHOW_ALL, - showOnlySelectText: _Const2.default.SHOW_ONLY_SELECT, - toggle: false, - btnContextual: 'btn-primary', - className: '', - onClick: undefined -}; - -var _default = ShowSelectedOnlyButton; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(showSelectedOnlyBtnDefaultClass, 'showSelectedOnlyBtnDefaultClass', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ShowSelectedOnlyButton.js'); - - __REACT_HOT_LOADER__.register(ShowSelectedOnlyButton, 'ShowSelectedOnlyButton', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ShowSelectedOnlyButton.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ShowSelectedOnlyButton.js'); -}(); - -; - -/***/ }), -/* 299 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _reactDom = __webpack_require__(28); - -var _reactDom2 = _interopRequireDefault(_reactDom); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var SearchField = function (_Component) { - _inherits(SearchField, _Component); - - function SearchField() { - _classCallCheck(this, SearchField); - - return _possibleConstructorReturn(this, (SearchField.__proto__ || Object.getPrototypeOf(SearchField)).apply(this, arguments)); - } - - _createClass(SearchField, [{ - key: 'getValue', - value: function getValue() { - return _reactDom2.default.findDOMNode(this).value; - } - }, { - key: 'setValue', - value: function setValue(value) { - _reactDom2.default.findDOMNode(this).value = value; - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - defaultValue = _props.defaultValue, - placeholder = _props.placeholder, - onKeyUp = _props.onKeyUp, - rest = _objectWithoutProperties(_props, ['className', 'defaultValue', 'placeholder', 'onKeyUp']); - - return _react2.default.createElement('input', _extends({ - className: 'form-control ' + className, - type: 'text', - defaultValue: defaultValue, - placeholder: placeholder || SearchField.defaultProps.placeholder, - onKeyUp: onKeyUp, - style: { zIndex: 0 } - }, rest)); - } - }]); - - return SearchField; -}(_react.Component); - -SearchField.propTypes = { - className: _propTypes2.default.string, - defaultValue: _propTypes2.default.string, - placeholder: _propTypes2.default.string, - onKeyUp: _propTypes2.default.func -}; -SearchField.defaultProps = { - className: '', - defaultValue: '', - placeholder: 'Search', - onKeyUp: undefined -}; - -var _default = SearchField; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(SearchField, 'SearchField', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/SearchField.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/SearchField.js'); -}(); - -; - -/***/ }), -/* 300 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var clearBtnDefaultClass = 'react-bs-table-search-clear-btn'; - -var ClearSearchButton = function (_Component) { - _inherits(ClearSearchButton, _Component); - - function ClearSearchButton() { - _classCallCheck(this, ClearSearchButton); - - return _possibleConstructorReturn(this, (ClearSearchButton.__proto__ || Object.getPrototypeOf(ClearSearchButton)).apply(this, arguments)); - } - - _createClass(ClearSearchButton, [{ - key: 'render', - value: function render() { - var _props = this.props, - btnContextual = _props.btnContextual, - className = _props.className, - onClick = _props.onClick, - btnText = _props.btnText, - children = _props.children, - rest = _objectWithoutProperties(_props, ['btnContextual', 'className', 'onClick', 'btnText', 'children']); - - var content = children || _react2.default.createElement( - 'span', - null, - btnText - ); - return _react2.default.createElement( - 'button', - _extends({ ref: 'btn', - className: 'btn ' + btnContextual + ' ' + className + ' ' + clearBtnDefaultClass, - type: 'button', - onClick: onClick - }, rest), - content - ); - } - }]); - - return ClearSearchButton; -}(_react.Component); - -ClearSearchButton.propTypes = { - btnContextual: _propTypes2.default.string, - className: _propTypes2.default.string, - btnText: _propTypes2.default.string, - onClick: _propTypes2.default.func -}; -ClearSearchButton.defaultProps = { - btnContextual: 'btn-default btn-secondary', - className: '', - btnText: 'Clear', - onClick: undefined -}; - -var _default = ClearSearchButton; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(clearBtnDefaultClass, 'clearBtnDefaultClass', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ClearSearchButton.js'); - - __REACT_HOT_LOADER__.register(ClearSearchButton, 'ClearSearchButton', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ClearSearchButton.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ClearSearchButton.js'); -}(); - -; - -/***/ }), -/* 301 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = function bind(fn, thisArg) { - return function wrap() { - var args = new Array(arguments.length); - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i]; - } - return fn.apply(thisArg, args); - }; -}; - - -/***/ }), -/* 302 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(process) { - -var utils = __webpack_require__(46); -var settle = __webpack_require__(405); -var buildURL = __webpack_require__(407); -var parseHeaders = __webpack_require__(408); -var isURLSameOrigin = __webpack_require__(409); -var createError = __webpack_require__(303); -var btoa = (typeof window !== 'undefined' && window.btoa && window.btoa.bind(window)) || __webpack_require__(410); - -module.exports = function xhrAdapter(config) { - return new Promise(function dispatchXhrRequest(resolve, reject) { - var requestData = config.data; - var requestHeaders = config.headers; - - if (utils.isFormData(requestData)) { - delete requestHeaders['Content-Type']; // Let the browser set it - } - - var request = new XMLHttpRequest(); - var loadEvent = 'onreadystatechange'; - var xDomain = false; - - // For IE 8/9 CORS support - // Only supports POST and GET calls and doesn't returns the response headers. - // DON'T do this for testing b/c XMLHttpRequest is mocked, not XDomainRequest. - if (process.env.NODE_ENV !== 'test' && - typeof window !== 'undefined' && - window.XDomainRequest && !('withCredentials' in request) && - !isURLSameOrigin(config.url)) { - request = new window.XDomainRequest(); - loadEvent = 'onload'; - xDomain = true; - request.onprogress = function handleProgress() {}; - request.ontimeout = function handleTimeout() {}; - } - - // HTTP basic authentication - if (config.auth) { - var username = config.auth.username || ''; - var password = config.auth.password || ''; - requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password); - } - - request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true); - - // Set the request timeout in MS - request.timeout = config.timeout; - - // Listen for ready state - request[loadEvent] = function handleLoad() { - if (!request || (request.readyState !== 4 && !xDomain)) { - return; - } - - // The request errored out and we didn't get a response, this will be - // handled by onerror instead - // With one exception: request that using file: protocol, most browsers - // will return status as 0 even though it's a successful request - if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) { - return; - } - - // Prepare the response - var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null; - var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response; - var response = { - data: responseData, - // IE sends 1223 instead of 204 (https://github.com/mzabriskie/axios/issues/201) - status: request.status === 1223 ? 204 : request.status, - statusText: request.status === 1223 ? 'No Content' : request.statusText, - headers: responseHeaders, - config: config, - request: request - }; - - settle(resolve, reject, response); - - // Clean up request - request = null; - }; - - // Handle low level network errors - request.onerror = function handleError() { - // Real errors are hidden from us by the browser - // onerror should only fire if it's a network error - reject(createError('Network Error', config, null, request)); - - // Clean up request - request = null; - }; - - // Handle timeout - request.ontimeout = function handleTimeout() { - reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED', - request)); - - // Clean up request - request = null; - }; - - // Add xsrf header - // This is only done if running in a standard browser environment. - // Specifically not if we're in a web worker, or react-native. - if (utils.isStandardBrowserEnv()) { - var cookies = __webpack_require__(411); - - // Add xsrf header - var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ? - cookies.read(config.xsrfCookieName) : - undefined; - - if (xsrfValue) { - requestHeaders[config.xsrfHeaderName] = xsrfValue; - } - } - - // Add headers to the request - if ('setRequestHeader' in request) { - utils.forEach(requestHeaders, function setRequestHeader(val, key) { - if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') { - // Remove Content-Type if data is undefined - delete requestHeaders[key]; - } else { - // Otherwise add header to the request - request.setRequestHeader(key, val); - } - }); - } - - // Add withCredentials to request if needed - if (config.withCredentials) { - request.withCredentials = true; - } - - // Add responseType to request if needed - if (config.responseType) { - try { - request.responseType = config.responseType; - } catch (e) { - // Expected DOMException thrown by browsers not compatible XMLHttpRequest Level 2. - // But, this can be suppressed for 'json' type as it can be parsed by default 'transformResponse' function. - if (config.responseType !== 'json') { - throw e; - } - } - } - - // Handle progress if needed - if (typeof config.onDownloadProgress === 'function') { - request.addEventListener('progress', config.onDownloadProgress); - } - - // Not all browsers support upload events - if (typeof config.onUploadProgress === 'function' && request.upload) { - request.upload.addEventListener('progress', config.onUploadProgress); - } - - if (config.cancelToken) { - // Handle cancellation - config.cancelToken.promise.then(function onCanceled(cancel) { - if (!request) { - return; - } - - request.abort(); - reject(cancel); - // Clean up request - request = null; - }); - } - - if (requestData === undefined) { - requestData = null; - } - - // Send the request - request.send(requestData); - }); -}; - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 303 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var enhanceError = __webpack_require__(406); - -/** - * Create an Error with the specified message, config, error code, request and response. - * - * @param {string} message The error message. - * @param {Object} config The config. - * @param {string} [code] The error code (for example, 'ECONNABORTED'). - * @param {Object} [request] The request. - * @param {Object} [response] The response. - * @returns {Error} The created error. - */ -module.exports = function createError(message, config, code, request, response) { - var error = new Error(message); - return enhanceError(error, config, code, request, response); -}; - - -/***/ }), -/* 304 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -module.exports = function isCancel(value) { - return !!(value && value.__CANCEL__); -}; - - -/***/ }), -/* 305 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -/** - * A `Cancel` is an object that is thrown when an operation is canceled. - * - * @class - * @param {string=} message The message. - */ -function Cancel(message) { - this.message = message; -} - -Cancel.prototype.toString = function toString() { - return 'Cancel' + (this.message ? ': ' + this.message : ''); -}; - -Cancel.prototype.__CANCEL__ = true; - -module.exports = Cancel; - - -/***/ }), -/* 306 */ -/***/ (function(module, exports, __webpack_require__) { - -module.exports = { - address: __webpack_require__(259), - config: __webpack_require__(248), - zaddress: __webpack_require__(472), - crypto: __webpack_require__(269), - transaction: __webpack_require__(518) -}; - -/***/ }), -/* 307 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -/* WEBPACK VAR INJECTION */(function(global, process) {// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. - - - -/*<replacement>*/ - -var processNextTick = __webpack_require__(246); -/*</replacement>*/ - -module.exports = Readable; - -/*<replacement>*/ -var isArray = __webpack_require__(281); -/*</replacement>*/ - -/*<replacement>*/ -var Duplex; -/*</replacement>*/ - -Readable.ReadableState = ReadableState; - -/*<replacement>*/ -var EE = __webpack_require__(244).EventEmitter; - -var EElistenerCount = function (emitter, type) { - return emitter.listeners(type).length; -}; -/*</replacement>*/ - -/*<replacement>*/ -var Stream = __webpack_require__(308); -/*</replacement>*/ - -// TODO(bmeurer): Change this back to const once hole checks are -// properly optimized away early in Ignition+TurboFan. -/*<replacement>*/ -var Buffer = __webpack_require__(18).Buffer; -var OurUint8Array = global.Uint8Array || function () {}; -function _uint8ArrayToBuffer(chunk) { - return Buffer.from(chunk); -} -function _isUint8Array(obj) { - return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; -} -/*</replacement>*/ - -/*<replacement>*/ -var util = __webpack_require__(237); -util.inherits = __webpack_require__(11); -/*</replacement>*/ - -/*<replacement>*/ -var debugUtil = __webpack_require__(427); -var debug = void 0; -if (debugUtil && debugUtil.debuglog) { - debug = debugUtil.debuglog('stream'); -} else { - debug = function () {}; -} -/*</replacement>*/ - -var BufferList = __webpack_require__(428); -var destroyImpl = __webpack_require__(309); -var StringDecoder; - -util.inherits(Readable, Stream); - -var kProxyEvents = ['error', 'close', 'destroy', 'pause', 'resume']; - -function prependListener(emitter, event, fn) { - // Sadly this is not cacheable as some libraries bundle their own - // event emitter implementation with them. - if (typeof emitter.prependListener === 'function') { - return emitter.prependListener(event, fn); - } else { - // This is a hack to make sure that our error handler is attached before any - // userland ones. NEVER DO THIS. This is here only because this code needs - // to continue to work with older versions of Node.js that do not include - // the prependListener() method. The goal is to eventually remove this hack. - if (!emitter._events || !emitter._events[event]) emitter.on(event, fn);else if (isArray(emitter._events[event])) emitter._events[event].unshift(fn);else emitter._events[event] = [fn, emitter._events[event]]; - } -} - -function ReadableState(options, stream) { - Duplex = Duplex || __webpack_require__(112); - - options = options || {}; - - // object stream flag. Used to make read(n) ignore n and to - // make all the buffer merging and length checks go away - this.objectMode = !!options.objectMode; - - if (stream instanceof Duplex) this.objectMode = this.objectMode || !!options.readableObjectMode; - - // the point at which it stops calling _read() to fill the buffer - // Note: 0 is a valid value, means "don't call _read preemptively ever" - var hwm = options.highWaterMark; - var defaultHwm = this.objectMode ? 16 : 16 * 1024; - this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm; - - // cast to ints. - this.highWaterMark = Math.floor(this.highWaterMark); - - // A linked list is used to store data chunks instead of an array because the - // linked list can remove elements from the beginning faster than - // array.shift() - this.buffer = new BufferList(); - this.length = 0; - this.pipes = null; - this.pipesCount = 0; - this.flowing = null; - this.ended = false; - this.endEmitted = false; - this.reading = false; - - // a flag to be able to tell if the event 'readable'/'data' is emitted - // immediately, or on a later tick. We set this to true at first, because - // any actions that shouldn't happen until "later" should generally also - // not happen before the first read call. - this.sync = true; - - // whenever we return null, then we set a flag to say - // that we're awaiting a 'readable' event emission. - this.needReadable = false; - this.emittedReadable = false; - this.readableListening = false; - this.resumeScheduled = false; - - // has it been destroyed - this.destroyed = false; - - // Crypto is kind of old and crusty. Historically, its default string - // encoding is 'binary' so we have to make this configurable. - // Everything else in the universe uses 'utf8', though. - this.defaultEncoding = options.defaultEncoding || 'utf8'; - - // the number of writers that are awaiting a drain event in .pipe()s - this.awaitDrain = 0; - - // if true, a maybeReadMore has been scheduled - this.readingMore = false; - - this.decoder = null; - this.encoding = null; - if (options.encoding) { - if (!StringDecoder) StringDecoder = __webpack_require__(264).StringDecoder; - this.decoder = new StringDecoder(options.encoding); - this.encoding = options.encoding; - } -} - -function Readable(options) { - Duplex = Duplex || __webpack_require__(112); - - if (!(this instanceof Readable)) return new Readable(options); - - this._readableState = new ReadableState(options, this); - - // legacy - this.readable = true; - - if (options) { - if (typeof options.read === 'function') this._read = options.read; - - if (typeof options.destroy === 'function') this._destroy = options.destroy; - } - - Stream.call(this); -} - -Object.defineProperty(Readable.prototype, 'destroyed', { - get: function () { - if (this._readableState === undefined) { - return false; - } - return this._readableState.destroyed; - }, - set: function (value) { - // we ignore the value if the stream - // has not been initialized yet - if (!this._readableState) { - return; - } - - // backward compatibility, the user is explicitly - // managing destroyed - this._readableState.destroyed = value; - } -}); - -Readable.prototype.destroy = destroyImpl.destroy; -Readable.prototype._undestroy = destroyImpl.undestroy; -Readable.prototype._destroy = function (err, cb) { - this.push(null); - cb(err); -}; - -// Manually shove something into the read() buffer. -// This returns true if the highWaterMark has not been hit yet, -// similar to how Writable.write() returns true if you should -// write() some more. -Readable.prototype.push = function (chunk, encoding) { - var state = this._readableState; - var skipChunkCheck; - - if (!state.objectMode) { - if (typeof chunk === 'string') { - encoding = encoding || state.defaultEncoding; - if (encoding !== state.encoding) { - chunk = Buffer.from(chunk, encoding); - encoding = ''; - } - skipChunkCheck = true; - } - } else { - skipChunkCheck = true; - } - - return readableAddChunk(this, chunk, encoding, false, skipChunkCheck); -}; - -// Unshift should *always* be something directly out of read() -Readable.prototype.unshift = function (chunk) { - return readableAddChunk(this, chunk, null, true, false); -}; - -function readableAddChunk(stream, chunk, encoding, addToFront, skipChunkCheck) { - var state = stream._readableState; - if (chunk === null) { - state.reading = false; - onEofChunk(stream, state); - } else { - var er; - if (!skipChunkCheck) er = chunkInvalid(state, chunk); - if (er) { - stream.emit('error', er); - } else if (state.objectMode || chunk && chunk.length > 0) { - if (typeof chunk !== 'string' && !state.objectMode && Object.getPrototypeOf(chunk) !== Buffer.prototype) { - chunk = _uint8ArrayToBuffer(chunk); - } - - if (addToFront) { - if (state.endEmitted) stream.emit('error', new Error('stream.unshift() after end event'));else addChunk(stream, state, chunk, true); - } else if (state.ended) { - stream.emit('error', new Error('stream.push() after EOF')); - } else { - state.reading = false; - if (state.decoder && !encoding) { - chunk = state.decoder.write(chunk); - if (state.objectMode || chunk.length !== 0) addChunk(stream, state, chunk, false);else maybeReadMore(stream, state); - } else { - addChunk(stream, state, chunk, false); - } - } - } else if (!addToFront) { - state.reading = false; - } - } - - return needMoreData(state); -} - -function addChunk(stream, state, chunk, addToFront) { - if (state.flowing && state.length === 0 && !state.sync) { - stream.emit('data', chunk); - stream.read(0); - } else { - // update the buffer info. - state.length += state.objectMode ? 1 : chunk.length; - if (addToFront) state.buffer.unshift(chunk);else state.buffer.push(chunk); - - if (state.needReadable) emitReadable(stream); - } - maybeReadMore(stream, state); -} - -function chunkInvalid(state, chunk) { - var er; - if (!_isUint8Array(chunk) && typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { - er = new TypeError('Invalid non-string/buffer chunk'); - } - return er; -} - -// if it's past the high water mark, we can push in some more. -// Also, if we have no data yet, we can stand some -// more bytes. This is to work around cases where hwm=0, -// such as the repl. Also, if the push() triggered a -// readable event, and the user called read(largeNumber) such that -// needReadable was set, then we ought to push more, so that another -// 'readable' event will be triggered. -function needMoreData(state) { - return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0); -} - -Readable.prototype.isPaused = function () { - return this._readableState.flowing === false; -}; - -// backwards compatibility. -Readable.prototype.setEncoding = function (enc) { - if (!StringDecoder) StringDecoder = __webpack_require__(264).StringDecoder; - this._readableState.decoder = new StringDecoder(enc); - this._readableState.encoding = enc; - return this; -}; - -// Don't raise the hwm > 8MB -var MAX_HWM = 0x800000; -function computeNewHighWaterMark(n) { - if (n >= MAX_HWM) { - n = MAX_HWM; - } else { - // Get the next highest power of 2 to prevent increasing hwm excessively in - // tiny amounts - n--; - n |= n >>> 1; - n |= n >>> 2; - n |= n >>> 4; - n |= n >>> 8; - n |= n >>> 16; - n++; - } - return n; -} - -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function howMuchToRead(n, state) { - if (n <= 0 || state.length === 0 && state.ended) return 0; - if (state.objectMode) return 1; - if (n !== n) { - // Only flow one buffer at a time - if (state.flowing && state.length) return state.buffer.head.data.length;else return state.length; - } - // If we're asking for more than the current hwm, then raise the hwm. - if (n > state.highWaterMark) state.highWaterMark = computeNewHighWaterMark(n); - if (n <= state.length) return n; - // Don't have enough - if (!state.ended) { - state.needReadable = true; - return 0; - } - return state.length; -} - -// you can override either this method, or the async _read(n) below. -Readable.prototype.read = function (n) { - debug('read', n); - n = parseInt(n, 10); - var state = this._readableState; - var nOrig = n; - - if (n !== 0) state.emittedReadable = false; - - // if we're doing read(0) to trigger a readable event, but we - // already have a bunch of data in the buffer, then just trigger - // the 'readable' event and move on. - if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) { - debug('read: emitReadable', state.length, state.ended); - if (state.length === 0 && state.ended) endReadable(this);else emitReadable(this); - return null; - } - - n = howMuchToRead(n, state); - - // if we've ended, and we're now clear, then finish it up. - if (n === 0 && state.ended) { - if (state.length === 0) endReadable(this); - return null; - } - - // All the actual chunk generation logic needs to be - // *below* the call to _read. The reason is that in certain - // synthetic stream cases, such as passthrough streams, _read - // may be a completely synchronous operation which may change - // the state of the read buffer, providing enough data when - // before there was *not* enough. - // - // So, the steps are: - // 1. Figure out what the state of things will be after we do - // a read from the buffer. - // - // 2. If that resulting state will trigger a _read, then call _read. - // Note that this may be asynchronous, or synchronous. Yes, it is - // deeply ugly to write APIs this way, but that still doesn't mean - // that the Readable class should behave improperly, as streams are - // designed to be sync/async agnostic. - // Take note if the _read call is sync or async (ie, if the read call - // has returned yet), so that we know whether or not it's safe to emit - // 'readable' etc. - // - // 3. Actually pull the requested chunks out of the buffer and return. - - // if we need a readable event, then we need to do some reading. - var doRead = state.needReadable; - debug('need readable', doRead); - - // if we currently have less than the highWaterMark, then also read some - if (state.length === 0 || state.length - n < state.highWaterMark) { - doRead = true; - debug('length less than watermark', doRead); - } - - // however, if we've ended, then there's no point, and if we're already - // reading, then it's unnecessary. - if (state.ended || state.reading) { - doRead = false; - debug('reading or ended', doRead); - } else if (doRead) { - debug('do read'); - state.reading = true; - state.sync = true; - // if the length is currently zero, then we *need* a readable event. - if (state.length === 0) state.needReadable = true; - // call internal read method - this._read(state.highWaterMark); - state.sync = false; - // If _read pushed data synchronously, then `reading` will be false, - // and we need to re-evaluate how much data we can return to the user. - if (!state.reading) n = howMuchToRead(nOrig, state); - } - - var ret; - if (n > 0) ret = fromList(n, state);else ret = null; - - if (ret === null) { - state.needReadable = true; - n = 0; - } else { - state.length -= n; - } - - if (state.length === 0) { - // If we have nothing in the buffer, then we want to know - // as soon as we *do* get something into the buffer. - if (!state.ended) state.needReadable = true; - - // If we tried to read() past the EOF, then emit end on the next tick. - if (nOrig !== n && state.ended) endReadable(this); - } - - if (ret !== null) this.emit('data', ret); - - return ret; -}; - -function onEofChunk(stream, state) { - if (state.ended) return; - if (state.decoder) { - var chunk = state.decoder.end(); - if (chunk && chunk.length) { - state.buffer.push(chunk); - state.length += state.objectMode ? 1 : chunk.length; - } - } - state.ended = true; - - // emit 'readable' now to make sure it gets picked up. - emitReadable(stream); -} - -// Don't emit readable right away in sync mode, because this can trigger -// another read() call => stack overflow. This way, it might trigger -// a nextTick recursion warning, but that's not so bad. -function emitReadable(stream) { - var state = stream._readableState; - state.needReadable = false; - if (!state.emittedReadable) { - debug('emitReadable', state.flowing); - state.emittedReadable = true; - if (state.sync) processNextTick(emitReadable_, stream);else emitReadable_(stream); - } -} - -function emitReadable_(stream) { - debug('emit readable'); - stream.emit('readable'); - flow(stream); -} - -// at this point, the user has presumably seen the 'readable' event, -// and called read() to consume some data. that may have triggered -// in turn another _read(n) call, in which case reading = true if -// it's in progress. -// However, if we're not ended, or reading, and the length < hwm, -// then go ahead and try to read some more preemptively. -function maybeReadMore(stream, state) { - if (!state.readingMore) { - state.readingMore = true; - processNextTick(maybeReadMore_, stream, state); - } -} - -function maybeReadMore_(stream, state) { - var len = state.length; - while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) { - debug('maybeReadMore read 0'); - stream.read(0); - if (len === state.length) - // didn't get any data, stop spinning. - break;else len = state.length; - } - state.readingMore = false; -} - -// abstract method. to be overridden in specific implementation classes. -// call cb(er, data) where data is <= n in length. -// for virtual (non-string, non-buffer) streams, "length" is somewhat -// arbitrary, and perhaps not very meaningful. -Readable.prototype._read = function (n) { - this.emit('error', new Error('_read() is not implemented')); -}; - -Readable.prototype.pipe = function (dest, pipeOpts) { - var src = this; - var state = this._readableState; - - switch (state.pipesCount) { - case 0: - state.pipes = dest; - break; - case 1: - state.pipes = [state.pipes, dest]; - break; - default: - state.pipes.push(dest); - break; - } - state.pipesCount += 1; - debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts); - - var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr; - - var endFn = doEnd ? onend : unpipe; - if (state.endEmitted) processNextTick(endFn);else src.once('end', endFn); - - dest.on('unpipe', onunpipe); - function onunpipe(readable, unpipeInfo) { - debug('onunpipe'); - if (readable === src) { - if (unpipeInfo && unpipeInfo.hasUnpiped === false) { - unpipeInfo.hasUnpiped = true; - cleanup(); - } - } - } - - function onend() { - debug('onend'); - dest.end(); - } - - // when the dest drains, it reduces the awaitDrain counter - // on the source. This would be more elegant with a .once() - // handler in flow(), but adding and removing repeatedly is - // too slow. - var ondrain = pipeOnDrain(src); - dest.on('drain', ondrain); - - var cleanedUp = false; - function cleanup() { - debug('cleanup'); - // cleanup event handlers once the pipe is broken - dest.removeListener('close', onclose); - dest.removeListener('finish', onfinish); - dest.removeListener('drain', ondrain); - dest.removeListener('error', onerror); - dest.removeListener('unpipe', onunpipe); - src.removeListener('end', onend); - src.removeListener('end', unpipe); - src.removeListener('data', ondata); - - cleanedUp = true; - - // if the reader is waiting for a drain event from this - // specific writer, then it would cause it to never start - // flowing again. - // So, if this is awaiting a drain, then we just call it now. - // If we don't know, then assume that we are waiting for one. - if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain)) ondrain(); - } - - // If the user pushes more data while we're writing to dest then we'll end up - // in ondata again. However, we only want to increase awaitDrain once because - // dest will only emit one 'drain' event for the multiple writes. - // => Introduce a guard on increasing awaitDrain. - var increasedAwaitDrain = false; - src.on('data', ondata); - function ondata(chunk) { - debug('ondata'); - increasedAwaitDrain = false; - var ret = dest.write(chunk); - if (false === ret && !increasedAwaitDrain) { - // If the user unpiped during `dest.write()`, it is possible - // to get stuck in a permanently paused state if that write - // also returned false. - // => Check whether `dest` is still a piping destination. - if ((state.pipesCount === 1 && state.pipes === dest || state.pipesCount > 1 && indexOf(state.pipes, dest) !== -1) && !cleanedUp) { - debug('false write response, pause', src._readableState.awaitDrain); - src._readableState.awaitDrain++; - increasedAwaitDrain = true; - } - src.pause(); - } - } - - // if the dest has an error, then stop piping into it. - // however, don't suppress the throwing behavior for this. - function onerror(er) { - debug('onerror', er); - unpipe(); - dest.removeListener('error', onerror); - if (EElistenerCount(dest, 'error') === 0) dest.emit('error', er); - } - - // Make sure our error handler is attached before userland ones. - prependListener(dest, 'error', onerror); - - // Both close and finish should trigger unpipe, but only once. - function onclose() { - dest.removeListener('finish', onfinish); - unpipe(); - } - dest.once('close', onclose); - function onfinish() { - debug('onfinish'); - dest.removeListener('close', onclose); - unpipe(); - } - dest.once('finish', onfinish); - - function unpipe() { - debug('unpipe'); - src.unpipe(dest); - } - - // tell the dest that it's being piped to - dest.emit('pipe', src); - - // start the flow if it hasn't been started already. - if (!state.flowing) { - debug('pipe resume'); - src.resume(); - } - - return dest; -}; - -function pipeOnDrain(src) { - return function () { - var state = src._readableState; - debug('pipeOnDrain', state.awaitDrain); - if (state.awaitDrain) state.awaitDrain--; - if (state.awaitDrain === 0 && EElistenerCount(src, 'data')) { - state.flowing = true; - flow(src); - } - }; -} - -Readable.prototype.unpipe = function (dest) { - var state = this._readableState; - var unpipeInfo = { hasUnpiped: false }; - - // if we're not piping anywhere, then do nothing. - if (state.pipesCount === 0) return this; - - // just one destination. most common case. - if (state.pipesCount === 1) { - // passed in one, but it's not the right one. - if (dest && dest !== state.pipes) return this; - - if (!dest) dest = state.pipes; - - // got a match. - state.pipes = null; - state.pipesCount = 0; - state.flowing = false; - if (dest) dest.emit('unpipe', this, unpipeInfo); - return this; - } - - // slow case. multiple pipe destinations. - - if (!dest) { - // remove all. - var dests = state.pipes; - var len = state.pipesCount; - state.pipes = null; - state.pipesCount = 0; - state.flowing = false; - - for (var i = 0; i < len; i++) { - dests[i].emit('unpipe', this, unpipeInfo); - }return this; - } - - // try to find the right one. - var index = indexOf(state.pipes, dest); - if (index === -1) return this; - - state.pipes.splice(index, 1); - state.pipesCount -= 1; - if (state.pipesCount === 1) state.pipes = state.pipes[0]; - - dest.emit('unpipe', this, unpipeInfo); - - return this; -}; - -// set up data events if they are asked for -// Ensure readable listeners eventually get something -Readable.prototype.on = function (ev, fn) { - var res = Stream.prototype.on.call(this, ev, fn); - - if (ev === 'data') { - // Start flowing on next tick if stream isn't explicitly paused - if (this._readableState.flowing !== false) this.resume(); - } else if (ev === 'readable') { - var state = this._readableState; - if (!state.endEmitted && !state.readableListening) { - state.readableListening = state.needReadable = true; - state.emittedReadable = false; - if (!state.reading) { - processNextTick(nReadingNextTick, this); - } else if (state.length) { - emitReadable(this); - } - } - } - - return res; -}; -Readable.prototype.addListener = Readable.prototype.on; - -function nReadingNextTick(self) { - debug('readable nexttick read 0'); - self.read(0); -} - -// pause() and resume() are remnants of the legacy readable stream API -// If the user uses them, then switch into old mode. -Readable.prototype.resume = function () { - var state = this._readableState; - if (!state.flowing) { - debug('resume'); - state.flowing = true; - resume(this, state); - } - return this; -}; - -function resume(stream, state) { - if (!state.resumeScheduled) { - state.resumeScheduled = true; - processNextTick(resume_, stream, state); - } -} - -function resume_(stream, state) { - if (!state.reading) { - debug('resume read 0'); - stream.read(0); - } - - state.resumeScheduled = false; - state.awaitDrain = 0; - stream.emit('resume'); - flow(stream); - if (state.flowing && !state.reading) stream.read(0); -} - -Readable.prototype.pause = function () { - debug('call pause flowing=%j', this._readableState.flowing); - if (false !== this._readableState.flowing) { - debug('pause'); - this._readableState.flowing = false; - this.emit('pause'); - } - return this; -}; - -function flow(stream) { - var state = stream._readableState; - debug('flow', state.flowing); - while (state.flowing && stream.read() !== null) {} -} - -// wrap an old-style stream as the async data source. -// This is *not* part of the readable stream interface. -// It is an ugly unfortunate mess of history. -Readable.prototype.wrap = function (stream) { - var state = this._readableState; - var paused = false; - - var self = this; - stream.on('end', function () { - debug('wrapped end'); - if (state.decoder && !state.ended) { - var chunk = state.decoder.end(); - if (chunk && chunk.length) self.push(chunk); - } - - self.push(null); - }); - - stream.on('data', function (chunk) { - debug('wrapped data'); - if (state.decoder) chunk = state.decoder.write(chunk); - - // don't skip over falsy values in objectMode - if (state.objectMode && (chunk === null || chunk === undefined)) return;else if (!state.objectMode && (!chunk || !chunk.length)) return; - - var ret = self.push(chunk); - if (!ret) { - paused = true; - stream.pause(); - } - }); - - // proxy all the other methods. - // important when wrapping filters and duplexes. - for (var i in stream) { - if (this[i] === undefined && typeof stream[i] === 'function') { - this[i] = function (method) { - return function () { - return stream[method].apply(stream, arguments); - }; - }(i); - } - } - - // proxy certain important events. - for (var n = 0; n < kProxyEvents.length; n++) { - stream.on(kProxyEvents[n], self.emit.bind(self, kProxyEvents[n])); - } - - // when we try to consume some more bytes, simply unpause the - // underlying stream. - self._read = function (n) { - debug('wrapped _read', n); - if (paused) { - paused = false; - stream.resume(); - } - }; - - return self; -}; - -// exposed for testing purposes only. -Readable._fromList = fromList; - -// Pluck off n bytes from an array of buffers. -// Length is the combined lengths of all the buffers in the list. -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function fromList(n, state) { - // nothing buffered - if (state.length === 0) return null; - - var ret; - if (state.objectMode) ret = state.buffer.shift();else if (!n || n >= state.length) { - // read it all, truncate the list - if (state.decoder) ret = state.buffer.join('');else if (state.buffer.length === 1) ret = state.buffer.head.data;else ret = state.buffer.concat(state.length); - state.buffer.clear(); - } else { - // read part of list - ret = fromListPartial(n, state.buffer, state.decoder); - } - - return ret; -} - -// Extracts only enough buffered data to satisfy the amount requested. -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function fromListPartial(n, list, hasStrings) { - var ret; - if (n < list.head.data.length) { - // slice is the same for buffers and strings - ret = list.head.data.slice(0, n); - list.head.data = list.head.data.slice(n); - } else if (n === list.head.data.length) { - // first chunk is a perfect match - ret = list.shift(); - } else { - // result spans more than one buffer - ret = hasStrings ? copyFromBufferString(n, list) : copyFromBuffer(n, list); - } - return ret; -} - -// Copies a specified amount of characters from the list of buffered data -// chunks. -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function copyFromBufferString(n, list) { - var p = list.head; - var c = 1; - var ret = p.data; - n -= ret.length; - while (p = p.next) { - var str = p.data; - var nb = n > str.length ? str.length : n; - if (nb === str.length) ret += str;else ret += str.slice(0, n); - n -= nb; - if (n === 0) { - if (nb === str.length) { - ++c; - if (p.next) list.head = p.next;else list.head = list.tail = null; - } else { - list.head = p; - p.data = str.slice(nb); - } - break; - } - ++c; - } - list.length -= c; - return ret; -} - -// Copies a specified amount of bytes from the list of buffered data chunks. -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function copyFromBuffer(n, list) { - var ret = Buffer.allocUnsafe(n); - var p = list.head; - var c = 1; - p.data.copy(ret); - n -= p.data.length; - while (p = p.next) { - var buf = p.data; - var nb = n > buf.length ? buf.length : n; - buf.copy(ret, ret.length - n, 0, nb); - n -= nb; - if (n === 0) { - if (nb === buf.length) { - ++c; - if (p.next) list.head = p.next;else list.head = list.tail = null; - } else { - list.head = p; - p.data = buf.slice(nb); - } - break; - } - ++c; - } - list.length -= c; - return ret; -} - -function endReadable(stream) { - var state = stream._readableState; - - // If we get here before consuming all the bytes, then that is a - // bug in node. Should never happen. - if (state.length > 0) throw new Error('"endReadable()" called on non-empty stream'); - - if (!state.endEmitted) { - state.ended = true; - processNextTick(endReadableNT, state, stream); - } -} - -function endReadableNT(state, stream) { - // Check that we didn't get one last unshift. - if (!state.endEmitted && state.length === 0) { - state.endEmitted = true; - stream.readable = false; - stream.emit('end'); - } -} - -function forEach(xs, f) { - for (var i = 0, l = xs.length; i < l; i++) { - f(xs[i], i); - } -} - -function indexOf(xs, x) { - for (var i = 0, l = xs.length; i < l; i++) { - if (xs[i] === x) return i; - } - return -1; -} -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(67), __webpack_require__(0))) - -/***/ }), -/* 308 */ -/***/ (function(module, exports, __webpack_require__) { - -module.exports = __webpack_require__(244).EventEmitter; - - -/***/ }), -/* 309 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -/*<replacement>*/ - -var processNextTick = __webpack_require__(246); -/*</replacement>*/ - -// undocumented cb() API, needed for core, not for public API -function destroy(err, cb) { - var _this = this; - - var readableDestroyed = this._readableState && this._readableState.destroyed; - var writableDestroyed = this._writableState && this._writableState.destroyed; - - if (readableDestroyed || writableDestroyed) { - if (cb) { - cb(err); - } else if (err && (!this._writableState || !this._writableState.errorEmitted)) { - processNextTick(emitErrorNT, this, err); - } - return; - } - - // we set destroyed to true before firing error callbacks in order - // to make it re-entrance safe in case destroy() is called within callbacks - - if (this._readableState) { - this._readableState.destroyed = true; - } - - // if this is a duplex stream mark the writable part as destroyed as well - if (this._writableState) { - this._writableState.destroyed = true; - } - - this._destroy(err || null, function (err) { - if (!cb && err) { - processNextTick(emitErrorNT, _this, err); - if (_this._writableState) { - _this._writableState.errorEmitted = true; - } - } else if (cb) { - cb(err); - } - }); -} - -function undestroy() { - if (this._readableState) { - this._readableState.destroyed = false; - this._readableState.reading = false; - this._readableState.ended = false; - this._readableState.endEmitted = false; - } - - if (this._writableState) { - this._writableState.destroyed = false; - this._writableState.ended = false; - this._writableState.ending = false; - this._writableState.finished = false; - this._writableState.errorEmitted = false; - } -} - -function emitErrorNT(self, err) { - self.emit('error', err); -} - -module.exports = { - destroy: destroy, - undestroy: undestroy -}; - -/***/ }), -/* 310 */ -/***/ (function(module, exports, __webpack_require__) { - -var apply = Function.prototype.apply; - -// DOM APIs, for completeness - -exports.setTimeout = function() { - return new Timeout(apply.call(setTimeout, window, arguments), clearTimeout); -}; -exports.setInterval = function() { - return new Timeout(apply.call(setInterval, window, arguments), clearInterval); -}; -exports.clearTimeout = -exports.clearInterval = function(timeout) { - if (timeout) { - timeout.close(); - } -}; - -function Timeout(id, clearFn) { - this._id = id; - this._clearFn = clearFn; -} -Timeout.prototype.unref = Timeout.prototype.ref = function() {}; -Timeout.prototype.close = function() { - this._clearFn.call(window, this._id); -}; - -// Does not start the time, just sets up the members needed. -exports.enroll = function(item, msecs) { - clearTimeout(item._idleTimeoutId); - item._idleTimeout = msecs; -}; - -exports.unenroll = function(item) { - clearTimeout(item._idleTimeoutId); - item._idleTimeout = -1; -}; - -exports._unrefActive = exports.active = function(item) { - clearTimeout(item._idleTimeoutId); - - var msecs = item._idleTimeout; - if (msecs >= 0) { - item._idleTimeoutId = setTimeout(function onTimeout() { - if (item._onTimeout) - item._onTimeout(); - }, msecs); - } -}; - -// setimmediate attaches itself to the global object -__webpack_require__(429); -exports.setImmediate = setImmediate; -exports.clearImmediate = clearImmediate; - - -/***/ }), -/* 311 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. - -// a transform stream is a readable/writable stream where you do -// something with the data. Sometimes it's called a "filter", -// but that's not a great name for it, since that implies a thing where -// some bits pass through, and others are simply ignored. (That would -// be a valid example of a transform, of course.) -// -// While the output is causally related to the input, it's not a -// necessarily symmetric or synchronous transformation. For example, -// a zlib stream might take multiple plain-text writes(), and then -// emit a single compressed chunk some time in the future. -// -// Here's how this works: -// -// The Transform stream has all the aspects of the readable and writable -// stream classes. When you write(chunk), that calls _write(chunk,cb) -// internally, and returns false if there's a lot of pending writes -// buffered up. When you call read(), that calls _read(n) until -// there's enough pending readable data buffered up. -// -// In a transform stream, the written data is placed in a buffer. When -// _read(n) is called, it transforms the queued up data, calling the -// buffered _write cb's as it consumes chunks. If consuming a single -// written chunk would result in multiple output chunks, then the first -// outputted bit calls the readcb, and subsequent chunks just go into -// the read buffer, and will cause it to emit 'readable' if necessary. -// -// This way, back-pressure is actually determined by the reading side, -// since _read has to be called to start processing a new chunk. However, -// a pathological inflate type of transform can cause excessive buffering -// here. For example, imagine a stream where every byte of input is -// interpreted as an integer from 0-255, and then results in that many -// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in -// 1kb of data being output. In this case, you could write a very small -// amount of input, and end up with a very large amount of output. In -// such a pathological inflating mechanism, there'd be no way to tell -// the system to stop doing the transform. A single 4MB write could -// cause the system to run out of memory. -// -// However, even in such a pathological case, only a single written chunk -// would be consumed, and then the rest would wait (un-transformed) until -// the results of the previous transformed chunk were consumed. - - - -module.exports = Transform; - -var Duplex = __webpack_require__(112); - -/*<replacement>*/ -var util = __webpack_require__(237); -util.inherits = __webpack_require__(11); -/*</replacement>*/ - -util.inherits(Transform, Duplex); - -function TransformState(stream) { - this.afterTransform = function (er, data) { - return afterTransform(stream, er, data); - }; - - this.needTransform = false; - this.transforming = false; - this.writecb = null; - this.writechunk = null; - this.writeencoding = null; -} - -function afterTransform(stream, er, data) { - var ts = stream._transformState; - ts.transforming = false; - - var cb = ts.writecb; - - if (!cb) { - return stream.emit('error', new Error('write callback called multiple times')); - } - - ts.writechunk = null; - ts.writecb = null; - - if (data !== null && data !== undefined) stream.push(data); - - cb(er); - - var rs = stream._readableState; - rs.reading = false; - if (rs.needReadable || rs.length < rs.highWaterMark) { - stream._read(rs.highWaterMark); - } -} - -function Transform(options) { - if (!(this instanceof Transform)) return new Transform(options); - - Duplex.call(this, options); - - this._transformState = new TransformState(this); - - var stream = this; - - // start out asking for a readable event once data is transformed. - this._readableState.needReadable = true; - - // we have implemented the _read method, and done the other things - // that Readable wants before the first _read call, so unset the - // sync guard flag. - this._readableState.sync = false; - - if (options) { - if (typeof options.transform === 'function') this._transform = options.transform; - - if (typeof options.flush === 'function') this._flush = options.flush; - } - - // When the writable side finishes, then flush out anything remaining. - this.once('prefinish', function () { - if (typeof this._flush === 'function') this._flush(function (er, data) { - done(stream, er, data); - });else done(stream); - }); -} - -Transform.prototype.push = function (chunk, encoding) { - this._transformState.needTransform = false; - return Duplex.prototype.push.call(this, chunk, encoding); -}; - -// This is the part where you do stuff! -// override this function in implementation classes. -// 'chunk' is an input chunk. -// -// Call `push(newChunk)` to pass along transformed output -// to the readable side. You may call 'push' zero or more times. -// -// Call `cb(err)` when you are done with this chunk. If you pass -// an error, then that'll put the hurt on the whole operation. If you -// never call cb(), then you'll never get another chunk. -Transform.prototype._transform = function (chunk, encoding, cb) { - throw new Error('_transform() is not implemented'); -}; - -Transform.prototype._write = function (chunk, encoding, cb) { - var ts = this._transformState; - ts.writecb = cb; - ts.writechunk = chunk; - ts.writeencoding = encoding; - if (!ts.transforming) { - var rs = this._readableState; - if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark) this._read(rs.highWaterMark); - } -}; - -// Doesn't matter what the args are here. -// _transform does all the work. -// That we got here means that the readable side wants more data. -Transform.prototype._read = function (n) { - var ts = this._transformState; - - if (ts.writechunk !== null && ts.writecb && !ts.transforming) { - ts.transforming = true; - this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); - } else { - // mark that we need a transform, so that any data that comes in - // will get processed, now that we've asked for it. - ts.needTransform = true; - } -}; - -Transform.prototype._destroy = function (err, cb) { - var _this = this; - - Duplex.prototype._destroy.call(this, err, function (err2) { - cb(err2); - _this.emit('close'); - }); -}; - -function done(stream, er, data) { - if (er) return stream.emit('error', er); - - if (data !== null && data !== undefined) stream.push(data); - - // if there's nothing in the write buffer, then that means - // that nothing more will ever be provided - var ws = stream._writableState; - var ts = stream._transformState; - - if (ws.length) throw new Error('Calling transform done when ws.length != 0'); - - if (ts.transforming) throw new Error('Calling transform done when still transforming'); - - return stream.push(null); -} - -/***/ }), -/* 312 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(Buffer) {/** - * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined - * in FIPS 180-2 - * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009. - * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet - * - */ - -var inherits = __webpack_require__(11) -var Hash = __webpack_require__(114) - -var K = [ - 0x428A2F98, 0x71374491, 0xB5C0FBCF, 0xE9B5DBA5, - 0x3956C25B, 0x59F111F1, 0x923F82A4, 0xAB1C5ED5, - 0xD807AA98, 0x12835B01, 0x243185BE, 0x550C7DC3, - 0x72BE5D74, 0x80DEB1FE, 0x9BDC06A7, 0xC19BF174, - 0xE49B69C1, 0xEFBE4786, 0x0FC19DC6, 0x240CA1CC, - 0x2DE92C6F, 0x4A7484AA, 0x5CB0A9DC, 0x76F988DA, - 0x983E5152, 0xA831C66D, 0xB00327C8, 0xBF597FC7, - 0xC6E00BF3, 0xD5A79147, 0x06CA6351, 0x14292967, - 0x27B70A85, 0x2E1B2138, 0x4D2C6DFC, 0x53380D13, - 0x650A7354, 0x766A0ABB, 0x81C2C92E, 0x92722C85, - 0xA2BFE8A1, 0xA81A664B, 0xC24B8B70, 0xC76C51A3, - 0xD192E819, 0xD6990624, 0xF40E3585, 0x106AA070, - 0x19A4C116, 0x1E376C08, 0x2748774C, 0x34B0BCB5, - 0x391C0CB3, 0x4ED8AA4A, 0x5B9CCA4F, 0x682E6FF3, - 0x748F82EE, 0x78A5636F, 0x84C87814, 0x8CC70208, - 0x90BEFFFA, 0xA4506CEB, 0xBEF9A3F7, 0xC67178F2 -] - -var W = new Array(64) - -function Sha256 () { - this.init() - - this._w = W // new Array(64) - - Hash.call(this, 64, 56) -} - -inherits(Sha256, Hash) - -Sha256.prototype.init = function () { - this._a = 0x6a09e667 - this._b = 0xbb67ae85 - this._c = 0x3c6ef372 - this._d = 0xa54ff53a - this._e = 0x510e527f - this._f = 0x9b05688c - this._g = 0x1f83d9ab - this._h = 0x5be0cd19 - - return this -} - -function ch (x, y, z) { - return z ^ (x & (y ^ z)) -} - -function maj (x, y, z) { - return (x & y) | (z & (x | y)) -} - -function sigma0 (x) { - return (x >>> 2 | x << 30) ^ (x >>> 13 | x << 19) ^ (x >>> 22 | x << 10) -} - -function sigma1 (x) { - return (x >>> 6 | x << 26) ^ (x >>> 11 | x << 21) ^ (x >>> 25 | x << 7) -} - -function gamma0 (x) { - return (x >>> 7 | x << 25) ^ (x >>> 18 | x << 14) ^ (x >>> 3) -} - -function gamma1 (x) { - return (x >>> 17 | x << 15) ^ (x >>> 19 | x << 13) ^ (x >>> 10) -} - -Sha256.prototype._update = function (M) { - var W = this._w - - var a = this._a | 0 - var b = this._b | 0 - var c = this._c | 0 - var d = this._d | 0 - var e = this._e | 0 - var f = this._f | 0 - var g = this._g | 0 - var h = this._h | 0 - - for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4) - for (; i < 64; ++i) W[i] = (gamma1(W[i - 2]) + W[i - 7] + gamma0(W[i - 15]) + W[i - 16]) | 0 - - for (var j = 0; j < 64; ++j) { - var T1 = (h + sigma1(e) + ch(e, f, g) + K[j] + W[j]) | 0 - var T2 = (sigma0(a) + maj(a, b, c)) | 0 - - h = g - g = f - f = e - e = (d + T1) | 0 - d = c - c = b - b = a - a = (T1 + T2) | 0 - } - - this._a = (a + this._a) | 0 - this._b = (b + this._b) | 0 - this._c = (c + this._c) | 0 - this._d = (d + this._d) | 0 - this._e = (e + this._e) | 0 - this._f = (f + this._f) | 0 - this._g = (g + this._g) | 0 - this._h = (h + this._h) | 0 -} - -Sha256.prototype._hash = function () { - var H = new Buffer(32) - - H.writeInt32BE(this._a, 0) - H.writeInt32BE(this._b, 4) - H.writeInt32BE(this._c, 8) - H.writeInt32BE(this._d, 12) - H.writeInt32BE(this._e, 16) - H.writeInt32BE(this._f, 20) - H.writeInt32BE(this._g, 24) - H.writeInt32BE(this._h, 28) - - return H -} - -module.exports = Sha256 - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) - -/***/ }), -/* 313 */ -/***/ (function(module, exports, __webpack_require__) { - -/* WEBPACK VAR INJECTION */(function(Buffer) {var inherits = __webpack_require__(11) -var Hash = __webpack_require__(114) - -var K = [ - 0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd, - 0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc, - 0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019, - 0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118, - 0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe, - 0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2, - 0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1, - 0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694, - 0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3, - 0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65, - 0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483, - 0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5, - 0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210, - 0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4, - 0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725, - 0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70, - 0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926, - 0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df, - 0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8, - 0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b, - 0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001, - 0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30, - 0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910, - 0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8, - 0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53, - 0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8, - 0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb, - 0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3, - 0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60, - 0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec, - 0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9, - 0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b, - 0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207, - 0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178, - 0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6, - 0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b, - 0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493, - 0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c, - 0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a, - 0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817 -] - -var W = new Array(160) - -function Sha512 () { - this.init() - this._w = W - - Hash.call(this, 128, 112) -} - -inherits(Sha512, Hash) - -Sha512.prototype.init = function () { - this._ah = 0x6a09e667 - this._bh = 0xbb67ae85 - this._ch = 0x3c6ef372 - this._dh = 0xa54ff53a - this._eh = 0x510e527f - this._fh = 0x9b05688c - this._gh = 0x1f83d9ab - this._hh = 0x5be0cd19 - - this._al = 0xf3bcc908 - this._bl = 0x84caa73b - this._cl = 0xfe94f82b - this._dl = 0x5f1d36f1 - this._el = 0xade682d1 - this._fl = 0x2b3e6c1f - this._gl = 0xfb41bd6b - this._hl = 0x137e2179 - - return this -} - -function Ch (x, y, z) { - return z ^ (x & (y ^ z)) -} - -function maj (x, y, z) { - return (x & y) | (z & (x | y)) -} - -function sigma0 (x, xl) { - return (x >>> 28 | xl << 4) ^ (xl >>> 2 | x << 30) ^ (xl >>> 7 | x << 25) -} - -function sigma1 (x, xl) { - return (x >>> 14 | xl << 18) ^ (x >>> 18 | xl << 14) ^ (xl >>> 9 | x << 23) -} - -function Gamma0 (x, xl) { - return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7) -} - -function Gamma0l (x, xl) { - return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7 | xl << 25) -} - -function Gamma1 (x, xl) { - return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6) -} - -function Gamma1l (x, xl) { - return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6 | xl << 26) -} - -function getCarry (a, b) { - return (a >>> 0) < (b >>> 0) ? 1 : 0 -} - -Sha512.prototype._update = function (M) { - var W = this._w - - var ah = this._ah | 0 - var bh = this._bh | 0 - var ch = this._ch | 0 - var dh = this._dh | 0 - var eh = this._eh | 0 - var fh = this._fh | 0 - var gh = this._gh | 0 - var hh = this._hh | 0 - - var al = this._al | 0 - var bl = this._bl | 0 - var cl = this._cl | 0 - var dl = this._dl | 0 - var el = this._el | 0 - var fl = this._fl | 0 - var gl = this._gl | 0 - var hl = this._hl | 0 - - for (var i = 0; i < 32; i += 2) { - W[i] = M.readInt32BE(i * 4) - W[i + 1] = M.readInt32BE(i * 4 + 4) - } - for (; i < 160; i += 2) { - var xh = W[i - 15 * 2] - var xl = W[i - 15 * 2 + 1] - var gamma0 = Gamma0(xh, xl) - var gamma0l = Gamma0l(xl, xh) - - xh = W[i - 2 * 2] - xl = W[i - 2 * 2 + 1] - var gamma1 = Gamma1(xh, xl) - var gamma1l = Gamma1l(xl, xh) - - // W[i] = gamma0 + W[i - 7] + gamma1 + W[i - 16] - var Wi7h = W[i - 7 * 2] - var Wi7l = W[i - 7 * 2 + 1] - - var Wi16h = W[i - 16 * 2] - var Wi16l = W[i - 16 * 2 + 1] - - var Wil = (gamma0l + Wi7l) | 0 - var Wih = (gamma0 + Wi7h + getCarry(Wil, gamma0l)) | 0 - Wil = (Wil + gamma1l) | 0 - Wih = (Wih + gamma1 + getCarry(Wil, gamma1l)) | 0 - Wil = (Wil + Wi16l) | 0 - Wih = (Wih + Wi16h + getCarry(Wil, Wi16l)) | 0 - - W[i] = Wih - W[i + 1] = Wil - } - - for (var j = 0; j < 160; j += 2) { - Wih = W[j] - Wil = W[j + 1] - - var majh = maj(ah, bh, ch) - var majl = maj(al, bl, cl) - - var sigma0h = sigma0(ah, al) - var sigma0l = sigma0(al, ah) - var sigma1h = sigma1(eh, el) - var sigma1l = sigma1(el, eh) - - // t1 = h + sigma1 + ch + K[j] + W[j] - var Kih = K[j] - var Kil = K[j + 1] - - var chh = Ch(eh, fh, gh) - var chl = Ch(el, fl, gl) - - var t1l = (hl + sigma1l) | 0 - var t1h = (hh + sigma1h + getCarry(t1l, hl)) | 0 - t1l = (t1l + chl) | 0 - t1h = (t1h + chh + getCarry(t1l, chl)) | 0 - t1l = (t1l + Kil) | 0 - t1h = (t1h + Kih + getCarry(t1l, Kil)) | 0 - t1l = (t1l + Wil) | 0 - t1h = (t1h + Wih + getCarry(t1l, Wil)) | 0 - - // t2 = sigma0 + maj - var t2l = (sigma0l + majl) | 0 - var t2h = (sigma0h + majh + getCarry(t2l, sigma0l)) | 0 - - hh = gh - hl = gl - gh = fh - gl = fl - fh = eh - fl = el - el = (dl + t1l) | 0 - eh = (dh + t1h + getCarry(el, dl)) | 0 - dh = ch - dl = cl - ch = bh - cl = bl - bh = ah - bl = al - al = (t1l + t2l) | 0 - ah = (t1h + t2h + getCarry(al, t1l)) | 0 - } - - this._al = (this._al + al) | 0 - this._bl = (this._bl + bl) | 0 - this._cl = (this._cl + cl) | 0 - this._dl = (this._dl + dl) | 0 - this._el = (this._el + el) | 0 - this._fl = (this._fl + fl) | 0 - this._gl = (this._gl + gl) | 0 - this._hl = (this._hl + hl) | 0 - - this._ah = (this._ah + ah + getCarry(this._al, al)) | 0 - this._bh = (this._bh + bh + getCarry(this._bl, bl)) | 0 - this._ch = (this._ch + ch + getCarry(this._cl, cl)) | 0 - this._dh = (this._dh + dh + getCarry(this._dl, dl)) | 0 - this._eh = (this._eh + eh + getCarry(this._el, el)) | 0 - this._fh = (this._fh + fh + getCarry(this._fl, fl)) | 0 - this._gh = (this._gh + gh + getCarry(this._gl, gl)) | 0 - this._hh = (this._hh + hh + getCarry(this._hl, hl)) | 0 -} - -Sha512.prototype._hash = function () { - var H = new Buffer(64) - - function writeInt64BE (h, l, offset) { - H.writeInt32BE(h, offset) - H.writeInt32BE(l, offset + 4) - } - - writeInt64BE(this._ah, this._al, 0) - writeInt64BE(this._bh, this._bl, 8) - writeInt64BE(this._ch, this._cl, 16) - writeInt64BE(this._dh, this._dl, 24) - writeInt64BE(this._eh, this._el, 32) - writeInt64BE(this._fh, this._fl, 40) - writeInt64BE(this._gh, this._gl, 48) - writeInt64BE(this._hh, this._hl, 56) - - return H -} - -module.exports = Sha512 - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) - -/***/ }), -/* 314 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - -module.exports = __webpack_require__(440)(__webpack_require__(443)) - - -/***/ }), -/* 315 */ -/***/ (function(module, exports) { - -module.exports = { - "COMPRESSED_TYPE_INVALID": "compressed should be a boolean", - "EC_PRIVATE_KEY_TYPE_INVALID": "private key should be a Buffer", - "EC_PRIVATE_KEY_LENGTH_INVALID": "private key length is invalid", - "EC_PRIVATE_KEY_TWEAK_ADD_FAIL": "tweak out of range or resulting private key is invalid", - "EC_PRIVATE_KEY_TWEAK_MUL_FAIL": "tweak out of range", - "EC_PRIVATE_KEY_EXPORT_DER_FAIL": "couldn't export to DER format", - "EC_PRIVATE_KEY_IMPORT_DER_FAIL": "couldn't import from DER format", - "EC_PUBLIC_KEYS_TYPE_INVALID": "public keys should be an Array", - "EC_PUBLIC_KEYS_LENGTH_INVALID": "public keys Array should have at least 1 element", - "EC_PUBLIC_KEY_TYPE_INVALID": "public key should be a Buffer", - "EC_PUBLIC_KEY_LENGTH_INVALID": "public key length is invalid", - "EC_PUBLIC_KEY_PARSE_FAIL": "the public key could not be parsed or is invalid", - "EC_PUBLIC_KEY_CREATE_FAIL": "private was invalid, try again", - "EC_PUBLIC_KEY_TWEAK_ADD_FAIL": "tweak out of range or resulting public key is invalid", - "EC_PUBLIC_KEY_TWEAK_MUL_FAIL": "tweak out of range", - "EC_PUBLIC_KEY_COMBINE_FAIL": "the sum of the public keys is not valid", - "ECDH_FAIL": "scalar was invalid (zero or overflow)", - "ECDSA_SIGNATURE_TYPE_INVALID": "signature should be a Buffer", - "ECDSA_SIGNATURE_LENGTH_INVALID": "signature length is invalid", - "ECDSA_SIGNATURE_PARSE_FAIL": "couldn't parse signature", - "ECDSA_SIGNATURE_PARSE_DER_FAIL": "couldn't parse DER signature", - "ECDSA_SIGNATURE_SERIALIZE_DER_FAIL": "couldn't serialize signature to DER format", - "ECDSA_SIGN_FAIL": "nonce generation function failed or private key is invalid", - "ECDSA_RECOVER_FAIL": "couldn't recover public key from signature", - "MSG32_TYPE_INVALID": "message should be a Buffer", - "MSG32_LENGTH_INVALID": "message length is invalid", - "OPTIONS_TYPE_INVALID": "options should be an Object", - "OPTIONS_DATA_TYPE_INVALID": "options.data should be a Buffer", - "OPTIONS_DATA_LENGTH_INVALID": "options.data length is invalid", - "OPTIONS_NONCEFN_TYPE_INVALID": "options.noncefn should be a Function", - "RECOVERY_ID_TYPE_INVALID": "recovery should be a Number", - "RECOVERY_ID_VALUE_INVALID": "recovery should have value between -1 and 4", - "TWEAK_TYPE_INVALID": "tweak should be a Buffer", - "TWEAK_LENGTH_INVALID": "tweak length is invalid" -}; - -/***/ }), -/* 316 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var utils = exports; - -function toArray(msg, enc) { - if (Array.isArray(msg)) - return msg.slice(); - if (!msg) - return []; - var res = []; - if (typeof msg !== 'string') { - for (var i = 0; i < msg.length; i++) - res[i] = msg[i] | 0; - return res; - } - if (enc === 'hex') { - msg = msg.replace(/[^a-z0-9]+/ig, ''); - if (msg.length % 2 !== 0) - msg = '0' + msg; - for (var i = 0; i < msg.length; i += 2) - res.push(parseInt(msg[i] + msg[i + 1], 16)); - } else { - for (var i = 0; i < msg.length; i++) { - var c = msg.charCodeAt(i); - var hi = c >> 8; - var lo = c & 0xff; - if (hi) - res.push(hi, lo); - else - res.push(lo); - } - } - return res; -} -utils.toArray = toArray; - -function zero2(word) { - if (word.length === 1) - return '0' + word; - else - return word; -} -utils.zero2 = zero2; - -function toHex(msg) { - var res = ''; - for (var i = 0; i < msg.length; i++) - res += zero2(msg[i].toString(16)); - return res; -} -utils.toHex = toHex; - -utils.encode = function encode(arr, enc) { - if (enc === 'hex') - return toHex(arr); - else - return arr; -}; - + _updateDOMChildren: function (lastProps, nextProps, transaction, context) { + var lastContent = CONTENT_TYPES[typeof lastProps.children] ? lastProps.children : null; + var nextContent = CONTENT_TYPES[typeof nextProps.children] ? nextProps.children : null; -/***/ }), -/* 317 */ -/***/ (function(module, exports, __webpack_require__) { + var lastHtml = lastProps.dangerouslySetInnerHTML && lastProps.dangerouslySetInnerHTML.__html; + var nextHtml = nextProps.dangerouslySetInnerHTML && nextProps.dangerouslySetInnerHTML.__html; -var r; + // Note the use of `!=` which checks for null or undefined. + var lastChildren = lastContent != null ? null : lastProps.children; + var nextChildren = nextContent != null ? null : nextProps.children; -module.exports = function rand(len) { - if (!r) - r = new Rand(null); + // If we're switching from children to content/html or vice versa, remove + // the old content + var lastHasContentOrHtml = lastContent != null || lastHtml != null; + var nextHasContentOrHtml = nextContent != null || nextHtml != null; + if (lastChildren != null && nextChildren == null) { + this.updateChildren(null, transaction, context); + } else if (lastHasContentOrHtml && !nextHasContentOrHtml) { + this.updateTextContent(''); + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); + } + } - return r.generate(len); -}; + if (nextContent != null) { + if (lastContent !== nextContent) { + this.updateTextContent('' + nextContent); + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, nextContent); + } + } + } else if (nextHtml != null) { + if (lastHtml !== nextHtml) { + this.updateMarkup('' + nextHtml); + } + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onSetChildren(this._debugID, []); + } + } else if (nextChildren != null) { + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, null); + } -function Rand(rand) { - this.rand = rand; -} -module.exports.Rand = Rand; + this.updateChildren(nextChildren, transaction, context); + } + }, -Rand.prototype.generate = function generate(len) { - return this._rand(len); -}; + getHostNode: function () { + return getNode(this); + }, -// Emulate crypto API using randy -Rand.prototype._rand = function _rand(n) { - if (this.rand.getBytes) - return this.rand.getBytes(n); + /** + * Destroys all event registrations for this instance. Does not remove from + * the DOM. That must be done by the parent. + * + * @internal + */ + unmountComponent: function (safely) { + switch (this._tag) { + case 'audio': + case 'form': + case 'iframe': + case 'img': + case 'link': + case 'object': + case 'source': + case 'video': + var listeners = this._wrapperState.listeners; + if (listeners) { + for (var i = 0; i < listeners.length; i++) { + listeners[i].remove(); + } + } + break; + case 'input': + case 'textarea': + inputValueTracking.stopTracking(this); + break; + case 'html': + case 'head': + case 'body': + /** + * Components like <html> <head> and <body> can't be removed or added + * easily in a cross-browser way, however it's valuable to be able to + * take advantage of React's reconciliation for styling and <title> + * management. So we just document it and throw in dangerous cases. + */ + true ? process.env.NODE_ENV !== 'production' ? invariant(false, '<%s> tried to unmount. Because of cross-browser quirks it is impossible to unmount some top-level components (eg <html>, <head>, and <body>) reliably and efficiently. To fix this, have a single top-level component that never unmounts render these elements.', this._tag) : _prodInvariant('66', this._tag) : void 0; + break; + } - var res = new Uint8Array(n); - for (var i = 0; i < res.length; i++) - res[i] = this.rand.getByte(); - return res; -}; + this.unmountChildren(safely); + ReactDOMComponentTree.uncacheNode(this); + EventPluginHub.deleteAllListeners(this); + this._rootNodeID = 0; + this._domID = 0; + this._wrapperState = null; -if (typeof self === 'object') { - if (self.crypto && self.crypto.getRandomValues) { - // Modern browsers - Rand.prototype._rand = function _rand(n) { - var arr = new Uint8Array(n); - self.crypto.getRandomValues(arr); - return arr; - }; - } else if (self.msCrypto && self.msCrypto.getRandomValues) { - // IE - Rand.prototype._rand = function _rand(n) { - var arr = new Uint8Array(n); - self.msCrypto.getRandomValues(arr); - return arr; - }; + if (process.env.NODE_ENV !== 'production') { + setAndValidateContentChildDev.call(this, null); + } + }, - // Safari's WebWorkers do not have `crypto` - } else if (typeof window === 'object') { - // Old junk - Rand.prototype._rand = function() { - throw new Error('Not implemented yet'); - }; + getPublicInstance: function () { + return getNode(this); } -} else { - // Node.js or Web worker with no crypto support - try { - var crypto = __webpack_require__(447); - if (typeof crypto.randomBytes !== 'function') - throw new Error('Not supported'); +}; - Rand.prototype._rand = function _rand(n) { - return crypto.randomBytes(n); - }; - } catch (e) { - } -} +_assign(ReactDOMComponent.prototype, ReactDOMComponent.Mixin, ReactMultiChild.Mixin); +module.exports = ReactDOMComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 318 */ +/* 255 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var utils = __webpack_require__(69); -var rotr32 = utils.rotr32; - -function ft_1(s, x, y, z) { - if (s === 0) - return ch32(x, y, z); - if (s === 1 || s === 3) - return p32(x, y, z); - if (s === 2) - return maj32(x, y, z); -} -exports.ft_1 = ft_1; - -function ch32(x, y, z) { - return (x & y) ^ ((~x) & z); -} -exports.ch32 = ch32; - -function maj32(x, y, z) { - return (x & y) ^ (x & z) ^ (y & z); -} -exports.maj32 = maj32; - -function p32(x, y, z) { - return x ^ y ^ z; -} -exports.p32 = p32; - -function s0_256(x) { - return rotr32(x, 2) ^ rotr32(x, 13) ^ rotr32(x, 22); -} -exports.s0_256 = s0_256; -function s1_256(x) { - return rotr32(x, 6) ^ rotr32(x, 11) ^ rotr32(x, 25); -} -exports.s1_256 = s1_256; +var ReactDOMComponentTree = __webpack_require__(10); -function g0_256(x) { - return rotr32(x, 7) ^ rotr32(x, 18) ^ (x >>> 3); -} -exports.g0_256 = g0_256; +var focusNode = __webpack_require__(136); -function g1_256(x) { - return rotr32(x, 17) ^ rotr32(x, 19) ^ (x >>> 10); -} -exports.g1_256 = g1_256; +var AutoFocusUtils = { + focusDOMComponent: function () { + focusNode(ReactDOMComponentTree.getNodeFromInstance(this)); + } +}; +module.exports = AutoFocusUtils; /***/ }), -/* 319 */ +/* 256 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var utils = __webpack_require__(69); -var common = __webpack_require__(238); -var shaCommon = __webpack_require__(318); -var assert = __webpack_require__(47); - -var sum32 = utils.sum32; -var sum32_4 = utils.sum32_4; -var sum32_5 = utils.sum32_5; -var ch32 = shaCommon.ch32; -var maj32 = shaCommon.maj32; -var s0_256 = shaCommon.s0_256; -var s1_256 = shaCommon.s1_256; -var g0_256 = shaCommon.g0_256; -var g1_256 = shaCommon.g1_256; -var BlockHash = common.BlockHash; +var CSSProperty = __webpack_require__(137); +var ExecutionEnvironment = __webpack_require__(13); +var ReactInstrumentation = __webpack_require__(19); -var sha256_K = [ - 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, - 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5, - 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, - 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174, - 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, - 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da, - 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, - 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967, - 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, - 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85, - 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, - 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070, - 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, - 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3, - 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, - 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2 -]; +var camelizeStyleName = __webpack_require__(257); +var dangerousStyleValue = __webpack_require__(259); +var hyphenateStyleName = __webpack_require__(260); +var memoizeStringOnly = __webpack_require__(262); +var warning = __webpack_require__(3); -function SHA256() { - if (!(this instanceof SHA256)) - return new SHA256(); +var processStyleName = memoizeStringOnly(function (styleName) { + return hyphenateStyleName(styleName); +}); - BlockHash.call(this); - this.h = [ - 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, - 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19 - ]; - this.k = sha256_K; - this.W = new Array(64); +var hasShorthandPropertyBug = false; +var styleFloatAccessor = 'cssFloat'; +if (ExecutionEnvironment.canUseDOM) { + var tempStyle = document.createElement('div').style; + try { + // IE8 throws "Invalid argument." if resetting shorthand style properties. + tempStyle.font = ''; + } catch (e) { + hasShorthandPropertyBug = true; + } + // IE8 only supports accessing cssFloat (standard) as styleFloat + if (document.documentElement.style.cssFloat === undefined) { + styleFloatAccessor = 'styleFloat'; + } } -utils.inherits(SHA256, BlockHash); -module.exports = SHA256; - -SHA256.blockSize = 512; -SHA256.outSize = 256; -SHA256.hmacStrength = 192; -SHA256.padLength = 64; - -SHA256.prototype._update = function _update(msg, start) { - var W = this.W; - - for (var i = 0; i < 16; i++) - W[i] = msg[start + i]; - for (; i < W.length; i++) - W[i] = sum32_4(g1_256(W[i - 2]), W[i - 7], g0_256(W[i - 15]), W[i - 16]); - var a = this.h[0]; - var b = this.h[1]; - var c = this.h[2]; - var d = this.h[3]; - var e = this.h[4]; - var f = this.h[5]; - var g = this.h[6]; - var h = this.h[7]; +if (process.env.NODE_ENV !== 'production') { + // 'msTransform' is correct, but the other prefixes should be capitalized + var badVendoredStyleNamePattern = /^(?:webkit|moz|o)[A-Z]/; - assert(this.k.length === W.length); - for (i = 0; i < W.length; i++) { - var T1 = sum32_5(h, s1_256(e), ch32(e, f, g), this.k[i], W[i]); - var T2 = sum32(s0_256(a), maj32(a, b, c)); - h = g; - g = f; - f = e; - e = sum32(d, T1); - d = c; - c = b; - b = a; - a = sum32(T1, T2); - } + // style values shouldn't contain a semicolon + var badStyleValueWithSemicolonPattern = /;\s*$/; - this.h[0] = sum32(this.h[0], a); - this.h[1] = sum32(this.h[1], b); - this.h[2] = sum32(this.h[2], c); - this.h[3] = sum32(this.h[3], d); - this.h[4] = sum32(this.h[4], e); - this.h[5] = sum32(this.h[5], f); - this.h[6] = sum32(this.h[6], g); - this.h[7] = sum32(this.h[7], h); -}; + var warnedStyleNames = {}; + var warnedStyleValues = {}; + var warnedForNaNValue = false; -SHA256.prototype._digest = function digest(enc) { - if (enc === 'hex') - return utils.toHex32(this.h, 'big'); - else - return utils.split32(this.h, 'big'); -}; + var warnHyphenatedStyleName = function (name, owner) { + if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { + return; + } + warnedStyleNames[name] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported style property %s. Did you mean %s?%s', name, camelizeStyleName(name), checkRenderMessage(owner)) : void 0; + }; -/***/ }), -/* 320 */ -/***/ (function(module, exports, __webpack_require__) { + var warnBadVendoredStyleName = function (name, owner) { + if (warnedStyleNames.hasOwnProperty(name) && warnedStyleNames[name]) { + return; + } -"use strict"; + warnedStyleNames[name] = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Unsupported vendor-prefixed style property %s. Did you mean %s?%s', name, name.charAt(0).toUpperCase() + name.slice(1), checkRenderMessage(owner)) : void 0; + }; + var warnStyleValueWithSemicolon = function (name, value, owner) { + if (warnedStyleValues.hasOwnProperty(value) && warnedStyleValues[value]) { + return; + } -var utils = __webpack_require__(69); -var common = __webpack_require__(238); -var assert = __webpack_require__(47); + warnedStyleValues[value] = true; + process.env.NODE_ENV !== 'production' ? warning(false, "Style property values shouldn't contain a semicolon.%s " + 'Try "%s: %s" instead.', checkRenderMessage(owner), name, value.replace(badStyleValueWithSemicolonPattern, '')) : void 0; + }; -var rotr64_hi = utils.rotr64_hi; -var rotr64_lo = utils.rotr64_lo; -var shr64_hi = utils.shr64_hi; -var shr64_lo = utils.shr64_lo; -var sum64 = utils.sum64; -var sum64_hi = utils.sum64_hi; -var sum64_lo = utils.sum64_lo; -var sum64_4_hi = utils.sum64_4_hi; -var sum64_4_lo = utils.sum64_4_lo; -var sum64_5_hi = utils.sum64_5_hi; -var sum64_5_lo = utils.sum64_5_lo; + var warnStyleValueIsNaN = function (name, value, owner) { + if (warnedForNaNValue) { + return; + } -var BlockHash = common.BlockHash; + warnedForNaNValue = true; + process.env.NODE_ENV !== 'production' ? warning(false, '`NaN` is an invalid value for the `%s` css style property.%s', name, checkRenderMessage(owner)) : void 0; + }; -var sha512_K = [ - 0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd, - 0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc, - 0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019, - 0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118, - 0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe, - 0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2, - 0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1, - 0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694, - 0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3, - 0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65, - 0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483, - 0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5, - 0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210, - 0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4, - 0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725, - 0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70, - 0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926, - 0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df, - 0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8, - 0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b, - 0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001, - 0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30, - 0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910, - 0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8, - 0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53, - 0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8, - 0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb, - 0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3, - 0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60, - 0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec, - 0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9, - 0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b, - 0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207, - 0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178, - 0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6, - 0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b, - 0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493, - 0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c, - 0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a, - 0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817 -]; + var checkRenderMessage = function (owner) { + if (owner) { + var name = owner.getName(); + if (name) { + return ' Check the render method of `' + name + '`.'; + } + } + return ''; + }; -function SHA512() { - if (!(this instanceof SHA512)) - return new SHA512(); + /** + * @param {string} name + * @param {*} value + * @param {ReactDOMComponent} component + */ + var warnValidStyle = function (name, value, component) { + var owner; + if (component) { + owner = component._currentElement._owner; + } + if (name.indexOf('-') > -1) { + warnHyphenatedStyleName(name, owner); + } else if (badVendoredStyleNamePattern.test(name)) { + warnBadVendoredStyleName(name, owner); + } else if (badStyleValueWithSemicolonPattern.test(value)) { + warnStyleValueWithSemicolon(name, value, owner); + } - BlockHash.call(this); - this.h = [ - 0x6a09e667, 0xf3bcc908, - 0xbb67ae85, 0x84caa73b, - 0x3c6ef372, 0xfe94f82b, - 0xa54ff53a, 0x5f1d36f1, - 0x510e527f, 0xade682d1, - 0x9b05688c, 0x2b3e6c1f, - 0x1f83d9ab, 0xfb41bd6b, - 0x5be0cd19, 0x137e2179 ]; - this.k = sha512_K; - this.W = new Array(160); + if (typeof value === 'number' && isNaN(value)) { + warnStyleValueIsNaN(name, value, owner); + } + }; } -utils.inherits(SHA512, BlockHash); -module.exports = SHA512; - -SHA512.blockSize = 1024; -SHA512.outSize = 512; -SHA512.hmacStrength = 192; -SHA512.padLength = 128; -SHA512.prototype._prepareBlock = function _prepareBlock(msg, start) { - var W = this.W; +/** + * Operations for dealing with CSS properties. + */ +var CSSPropertyOperations = { + /** + * Serializes a mapping of style properties for use as inline styles: + * + * > createMarkupForStyles({width: '200px', height: 0}) + * "width:200px;height:0;" + * + * Undefined values are ignored so that declarative programming is easier. + * The result should be HTML-escaped before insertion into the DOM. + * + * @param {object} styles + * @param {ReactDOMComponent} component + * @return {?string} + */ + createMarkupForStyles: function (styles, component) { + var serialized = ''; + for (var styleName in styles) { + if (!styles.hasOwnProperty(styleName)) { + continue; + } + var isCustomProperty = styleName.indexOf('--') === 0; + var styleValue = styles[styleName]; + if (process.env.NODE_ENV !== 'production') { + if (!isCustomProperty) { + warnValidStyle(styleName, styleValue, component); + } + } + if (styleValue != null) { + serialized += processStyleName(styleName) + ':'; + serialized += dangerousStyleValue(styleName, styleValue, component, isCustomProperty) + ';'; + } + } + return serialized || null; + }, - // 32 x 32bit words - for (var i = 0; i < 32; i++) - W[i] = msg[start + i]; - for (; i < W.length; i += 2) { - var c0_hi = g1_512_hi(W[i - 4], W[i - 3]); // i - 2 - var c0_lo = g1_512_lo(W[i - 4], W[i - 3]); - var c1_hi = W[i - 14]; // i - 7 - var c1_lo = W[i - 13]; - var c2_hi = g0_512_hi(W[i - 30], W[i - 29]); // i - 15 - var c2_lo = g0_512_lo(W[i - 30], W[i - 29]); - var c3_hi = W[i - 32]; // i - 16 - var c3_lo = W[i - 31]; + /** + * Sets the value for multiple styles on a node. If a value is specified as + * '' (empty string), the corresponding style property will be unset. + * + * @param {DOMElement} node + * @param {object} styles + * @param {ReactDOMComponent} component + */ + setValueForStyles: function (node, styles, component) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onHostOperation({ + instanceID: component._debugID, + type: 'update styles', + payload: styles + }); + } - W[i] = sum64_4_hi( - c0_hi, c0_lo, - c1_hi, c1_lo, - c2_hi, c2_lo, - c3_hi, c3_lo); - W[i + 1] = sum64_4_lo( - c0_hi, c0_lo, - c1_hi, c1_lo, - c2_hi, c2_lo, - c3_hi, c3_lo); + var style = node.style; + for (var styleName in styles) { + if (!styles.hasOwnProperty(styleName)) { + continue; + } + var isCustomProperty = styleName.indexOf('--') === 0; + if (process.env.NODE_ENV !== 'production') { + if (!isCustomProperty) { + warnValidStyle(styleName, styles[styleName], component); + } + } + var styleValue = dangerousStyleValue(styleName, styles[styleName], component, isCustomProperty); + if (styleName === 'float' || styleName === 'cssFloat') { + styleName = styleFloatAccessor; + } + if (isCustomProperty) { + style.setProperty(styleName, styleValue); + } else if (styleValue) { + style[styleName] = styleValue; + } else { + var expansion = hasShorthandPropertyBug && CSSProperty.shorthandPropertyExpansions[styleName]; + if (expansion) { + // Shorthand property that IE8 won't like unsetting, so unset each + // component to placate it + for (var individualStyleName in expansion) { + style[individualStyleName] = ''; + } + } else { + style[styleName] = ''; + } + } + } } }; -SHA512.prototype._update = function _update(msg, start) { - this._prepareBlock(msg, start); - - var W = this.W; - - var ah = this.h[0]; - var al = this.h[1]; - var bh = this.h[2]; - var bl = this.h[3]; - var ch = this.h[4]; - var cl = this.h[5]; - var dh = this.h[6]; - var dl = this.h[7]; - var eh = this.h[8]; - var el = this.h[9]; - var fh = this.h[10]; - var fl = this.h[11]; - var gh = this.h[12]; - var gl = this.h[13]; - var hh = this.h[14]; - var hl = this.h[15]; - - assert(this.k.length === W.length); - for (var i = 0; i < W.length; i += 2) { - var c0_hi = hh; - var c0_lo = hl; - var c1_hi = s1_512_hi(eh, el); - var c1_lo = s1_512_lo(eh, el); - var c2_hi = ch64_hi(eh, el, fh, fl, gh, gl); - var c2_lo = ch64_lo(eh, el, fh, fl, gh, gl); - var c3_hi = this.k[i]; - var c3_lo = this.k[i + 1]; - var c4_hi = W[i]; - var c4_lo = W[i + 1]; +module.exports = CSSPropertyOperations; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var T1_hi = sum64_5_hi( - c0_hi, c0_lo, - c1_hi, c1_lo, - c2_hi, c2_lo, - c3_hi, c3_lo, - c4_hi, c4_lo); - var T1_lo = sum64_5_lo( - c0_hi, c0_lo, - c1_hi, c1_lo, - c2_hi, c2_lo, - c3_hi, c3_lo, - c4_hi, c4_lo); +/***/ }), +/* 257 */ +/***/ (function(module, exports, __webpack_require__) { - c0_hi = s0_512_hi(ah, al); - c0_lo = s0_512_lo(ah, al); - c1_hi = maj64_hi(ah, al, bh, bl, ch, cl); - c1_lo = maj64_lo(ah, al, bh, bl, ch, cl); +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ - var T2_hi = sum64_hi(c0_hi, c0_lo, c1_hi, c1_lo); - var T2_lo = sum64_lo(c0_hi, c0_lo, c1_hi, c1_lo); - hh = gh; - hl = gl; - gh = fh; - gl = fl; +var camelize = __webpack_require__(258); - fh = eh; - fl = el; +var msPattern = /^-ms-/; - eh = sum64_hi(dh, dl, T1_hi, T1_lo); - el = sum64_lo(dl, dl, T1_hi, T1_lo); +/** + * Camelcases a hyphenated CSS property name, for example: + * + * > camelizeStyleName('background-color') + * < "backgroundColor" + * > camelizeStyleName('-moz-transition') + * < "MozTransition" + * > camelizeStyleName('-ms-transition') + * < "msTransition" + * + * As Andi Smith suggests + * (http://www.andismith.com/blog/2012/02/modernizr-prefixed/), an `-ms` prefix + * is converted to lowercase `ms`. + * + * @param {string} string + * @return {string} + */ +function camelizeStyleName(string) { + return camelize(string.replace(msPattern, 'ms-')); +} - dh = ch; - dl = cl; +module.exports = camelizeStyleName; - ch = bh; - cl = bl; +/***/ }), +/* 258 */ +/***/ (function(module, exports, __webpack_require__) { - bh = ah; - bl = al; +"use strict"; - ah = sum64_hi(T1_hi, T1_lo, T2_hi, T2_lo); - al = sum64_lo(T1_hi, T1_lo, T2_hi, T2_lo); - } - sum64(this.h, 0, ah, al); - sum64(this.h, 2, bh, bl); - sum64(this.h, 4, ch, cl); - sum64(this.h, 6, dh, dl); - sum64(this.h, 8, eh, el); - sum64(this.h, 10, fh, fl); - sum64(this.h, 12, gh, gl); - sum64(this.h, 14, hh, hl); -}; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ -SHA512.prototype._digest = function digest(enc) { - if (enc === 'hex') - return utils.toHex32(this.h, 'big'); - else - return utils.split32(this.h, 'big'); -}; +var _hyphenPattern = /-(.)/g; -function ch64_hi(xh, xl, yh, yl, zh) { - var r = (xh & yh) ^ ((~xh) & zh); - if (r < 0) - r += 0x100000000; - return r; +/** + * Camelcases a hyphenated string, for example: + * + * > camelize('background-color') + * < "backgroundColor" + * + * @param {string} string + * @return {string} + */ +function camelize(string) { + return string.replace(_hyphenPattern, function (_, character) { + return character.toUpperCase(); + }); } -function ch64_lo(xh, xl, yh, yl, zh, zl) { - var r = (xl & yl) ^ ((~xl) & zl); - if (r < 0) - r += 0x100000000; - return r; -} +module.exports = camelize; -function maj64_hi(xh, xl, yh, yl, zh) { - var r = (xh & yh) ^ (xh & zh) ^ (yh & zh); - if (r < 0) - r += 0x100000000; - return r; -} +/***/ }), +/* 259 */ +/***/ (function(module, exports, __webpack_require__) { -function maj64_lo(xh, xl, yh, yl, zh, zl) { - var r = (xl & yl) ^ (xl & zl) ^ (yl & zl); - if (r < 0) - r += 0x100000000; - return r; -} +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -function s0_512_hi(xh, xl) { - var c0_hi = rotr64_hi(xh, xl, 28); - var c1_hi = rotr64_hi(xl, xh, 2); // 34 - var c2_hi = rotr64_hi(xl, xh, 7); // 39 - var r = c0_hi ^ c1_hi ^ c2_hi; - if (r < 0) - r += 0x100000000; - return r; -} -function s0_512_lo(xh, xl) { - var c0_lo = rotr64_lo(xh, xl, 28); - var c1_lo = rotr64_lo(xl, xh, 2); // 34 - var c2_lo = rotr64_lo(xl, xh, 7); // 39 +var CSSProperty = __webpack_require__(137); +var warning = __webpack_require__(3); - var r = c0_lo ^ c1_lo ^ c2_lo; - if (r < 0) - r += 0x100000000; - return r; -} +var isUnitlessNumber = CSSProperty.isUnitlessNumber; +var styleWarnings = {}; -function s1_512_hi(xh, xl) { - var c0_hi = rotr64_hi(xh, xl, 14); - var c1_hi = rotr64_hi(xh, xl, 18); - var c2_hi = rotr64_hi(xl, xh, 9); // 41 +/** + * Convert a value into the proper css writable value. The style name `name` + * should be logical (no hyphens), as specified + * in `CSSProperty.isUnitlessNumber`. + * + * @param {string} name CSS property name such as `topMargin`. + * @param {*} value CSS property value such as `10px`. + * @param {ReactDOMComponent} component + * @return {string} Normalized style value with dimensions applied. + */ +function dangerousStyleValue(name, value, component, isCustomProperty) { + // Note that we've removed escapeTextForBrowser() calls here since the + // whole string will be escaped when the attribute is injected into + // the markup. If you provide unsafe user data here they can inject + // arbitrary CSS which may be problematic (I couldn't repro this): + // https://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet + // http://www.thespanner.co.uk/2007/11/26/ultimate-xss-css-injection/ + // This is not an XSS hole but instead a potential CSS injection issue + // which has lead to a greater discussion about how we're going to + // trust URLs moving forward. See #2115901 - var r = c0_hi ^ c1_hi ^ c2_hi; - if (r < 0) - r += 0x100000000; - return r; -} + var isEmpty = value == null || typeof value === 'boolean' || value === ''; + if (isEmpty) { + return ''; + } -function s1_512_lo(xh, xl) { - var c0_lo = rotr64_lo(xh, xl, 14); - var c1_lo = rotr64_lo(xh, xl, 18); - var c2_lo = rotr64_lo(xl, xh, 9); // 41 + var isNonNumeric = isNaN(value); + if (isCustomProperty || isNonNumeric || value === 0 || isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name]) { + return '' + value; // cast to string + } - var r = c0_lo ^ c1_lo ^ c2_lo; - if (r < 0) - r += 0x100000000; - return r; + if (typeof value === 'string') { + if (process.env.NODE_ENV !== 'production') { + // Allow '0' to pass through without warning. 0 is already special and + // doesn't require units, so we don't need to warn about it. + if (component && value !== '0') { + var owner = component._currentElement._owner; + var ownerName = owner ? owner.getName() : null; + if (ownerName && !styleWarnings[ownerName]) { + styleWarnings[ownerName] = {}; + } + var warned = false; + if (ownerName) { + var warnings = styleWarnings[ownerName]; + warned = warnings[name]; + if (!warned) { + warnings[name] = true; + } + } + if (!warned) { + process.env.NODE_ENV !== 'production' ? warning(false, 'a `%s` tag (owner: `%s`) was passed a numeric string value ' + 'for CSS property `%s` (value: `%s`) which will be treated ' + 'as a unitless number in a future version of React.', component._currentElement.type, ownerName || 'unknown', name, value) : void 0; + } + } + } + value = value.trim(); + } + return value + 'px'; } -function g0_512_hi(xh, xl) { - var c0_hi = rotr64_hi(xh, xl, 1); - var c1_hi = rotr64_hi(xh, xl, 8); - var c2_hi = shr64_hi(xh, xl, 7); +module.exports = dangerousStyleValue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var r = c0_hi ^ c1_hi ^ c2_hi; - if (r < 0) - r += 0x100000000; - return r; -} +/***/ }), +/* 260 */ +/***/ (function(module, exports, __webpack_require__) { -function g0_512_lo(xh, xl) { - var c0_lo = rotr64_lo(xh, xl, 1); - var c1_lo = rotr64_lo(xh, xl, 8); - var c2_lo = shr64_lo(xh, xl, 7); +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ - var r = c0_lo ^ c1_lo ^ c2_lo; - if (r < 0) - r += 0x100000000; - return r; -} -function g1_512_hi(xh, xl) { - var c0_hi = rotr64_hi(xh, xl, 19); - var c1_hi = rotr64_hi(xl, xh, 29); // 61 - var c2_hi = shr64_hi(xh, xl, 6); - var r = c0_hi ^ c1_hi ^ c2_hi; - if (r < 0) - r += 0x100000000; - return r; -} +var hyphenate = __webpack_require__(261); -function g1_512_lo(xh, xl) { - var c0_lo = rotr64_lo(xh, xl, 19); - var c1_lo = rotr64_lo(xl, xh, 29); // 61 - var c2_lo = shr64_lo(xh, xl, 6); +var msPattern = /^ms-/; - var r = c0_lo ^ c1_lo ^ c2_lo; - if (r < 0) - r += 0x100000000; - return r; +/** + * Hyphenates a camelcased CSS property name, for example: + * + * > hyphenateStyleName('backgroundColor') + * < "background-color" + * > hyphenateStyleName('MozTransition') + * < "-moz-transition" + * > hyphenateStyleName('msTransition') + * < "-ms-transition" + * + * As Modernizr suggests (http://modernizr.com/docs/#prefixed), an `ms` prefix + * is converted to `-ms-`. + * + * @param {string} string + * @return {string} + */ +function hyphenateStyleName(string) { + return hyphenate(string).replace(msPattern, '-ms-'); } +module.exports = hyphenateStyleName; /***/ }), -/* 321 */ +/* 261 */ /***/ (function(module, exports, __webpack_require__) { -// (public) Constructor -function BigInteger(a, b, c) { - if (!(this instanceof BigInteger)) - return new BigInteger(a, b, c) - - if (a != null) { - if ("number" == typeof a) this.fromNumber(a, b, c) - else if (b == null && "string" != typeof a) this.fromString(a, 256) - else this.fromString(a, b) - } -} - -var proto = BigInteger.prototype +"use strict"; -// duck-typed isBigInteger -proto.__bigi = __webpack_require__(467).version -BigInteger.isBigInteger = function (obj, check_ver) { - return obj && obj.__bigi && (!check_ver || obj.__bigi === proto.__bigi) -} -// Bits per digit -var dbits +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ -// am: Compute w_j += (x*this_i), propagate carries, -// c is initial carry, returns final carry. -// c < 3*dvalue, x < 2*dvalue, this_i < dvalue -// We need to select the fastest one that works in this environment. +var _uppercasePattern = /([A-Z])/g; -// am1: use a single mult and divide to get the high bits, -// max digit bits should be 26 because -// max internal value = 2*dvalue^2-2*dvalue (< 2^53) -function am1(i, x, w, j, c, n) { - while (--n >= 0) { - var v = x * this[i++] + w[j] + c - c = Math.floor(v / 0x4000000) - w[j++] = v & 0x3ffffff - } - return c -} -// am2 avoids a big mult-and-extract completely. -// Max digit bits should be <= 30 because we do bitwise ops -// on values up to 2*hdvalue^2-hdvalue-1 (< 2^31) -function am2(i, x, w, j, c, n) { - var xl = x & 0x7fff, - xh = x >> 15 - while (--n >= 0) { - var l = this[i] & 0x7fff - var h = this[i++] >> 15 - var m = xh * l + h * xl - l = xl * l + ((m & 0x7fff) << 15) + w[j] + (c & 0x3fffffff) - c = (l >>> 30) + (m >>> 15) + xh * h + (c >>> 30) - w[j++] = l & 0x3fffffff - } - return c -} -// Alternately, set max digit bits to 28 since some -// browsers slow down when dealing with 32-bit numbers. -function am3(i, x, w, j, c, n) { - var xl = x & 0x3fff, - xh = x >> 14 - while (--n >= 0) { - var l = this[i] & 0x3fff - var h = this[i++] >> 14 - var m = xh * l + h * xl - l = xl * l + ((m & 0x3fff) << 14) + w[j] + c - c = (l >> 28) + (m >> 14) + xh * h - w[j++] = l & 0xfffffff - } - return c +/** + * Hyphenates a camelcased string, for example: + * + * > hyphenate('backgroundColor') + * < "background-color" + * + * For CSS style names, use `hyphenateStyleName` instead which works properly + * with all vendor prefixes, including `ms`. + * + * @param {string} string + * @return {string} + */ +function hyphenate(string) { + return string.replace(_uppercasePattern, '-$1').toLowerCase(); } -// wtf? -BigInteger.prototype.am = am1 -dbits = 26 +module.exports = hyphenate; -BigInteger.prototype.DB = dbits -BigInteger.prototype.DM = ((1 << dbits) - 1) -var DV = BigInteger.prototype.DV = (1 << dbits) +/***/ }), +/* 262 */ +/***/ (function(module, exports, __webpack_require__) { -var BI_FP = 52 -BigInteger.prototype.FV = Math.pow(2, BI_FP) -BigInteger.prototype.F1 = BI_FP - dbits -BigInteger.prototype.F2 = 2 * dbits - BI_FP +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + * @typechecks static-only + */ -// Digit conversions -var BI_RM = "0123456789abcdefghijklmnopqrstuvwxyz" -var BI_RC = new Array() -var rr, vv -rr = "0".charCodeAt(0) -for (vv = 0; vv <= 9; ++vv) BI_RC[rr++] = vv -rr = "a".charCodeAt(0) -for (vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv -rr = "A".charCodeAt(0) -for (vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv -function int2char(n) { - return BI_RM.charAt(n) -} -function intAt(s, i) { - var c = BI_RC[s.charCodeAt(i)] - return (c == null) ? -1 : c -} +/** + * Memoizes the return value of a function that accepts one string argument. + */ -// (protected) copy this to r -function bnpCopyTo(r) { - for (var i = this.t - 1; i >= 0; --i) r[i] = this[i] - r.t = this.t - r.s = this.s +function memoizeStringOnly(callback) { + var cache = {}; + return function (string) { + if (!cache.hasOwnProperty(string)) { + cache[string] = callback.call(this, string); + } + return cache[string]; + }; } -// (protected) set from integer value x, -DV <= x < DV -function bnpFromInt(x) { - this.t = 1 - this.s = (x < 0) ? -1 : 0 - if (x > 0) this[0] = x - else if (x < -1) this[0] = x + DV - else this.t = 0 -} +module.exports = memoizeStringOnly; -// return bigint initialized to value -function nbv(i) { - var r = new BigInteger() - r.fromInt(i) - return r -} +/***/ }), +/* 263 */ +/***/ (function(module, exports, __webpack_require__) { -// (protected) set from string and radix -function bnpFromString(s, b) { - var self = this +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var k - if (b == 16) k = 4 - else if (b == 8) k = 3 - else if (b == 256) k = 8; // byte array - else if (b == 2) k = 1 - else if (b == 32) k = 5 - else if (b == 4) k = 2 - else { - self.fromRadix(s, b) - return - } - self.t = 0 - self.s = 0 - var i = s.length, - mi = false, - sh = 0 - while (--i >= 0) { - var x = (k == 8) ? s[i] & 0xff : intAt(s, i) - if (x < 0) { - if (s.charAt(i) == "-") mi = true - continue - } - mi = false - if (sh == 0) - self[self.t++] = x - else if (sh + k > self.DB) { - self[self.t - 1] |= (x & ((1 << (self.DB - sh)) - 1)) << sh - self[self.t++] = (x >> (self.DB - sh)) - } else - self[self.t - 1] |= x << sh - sh += k - if (sh >= self.DB) sh -= self.DB - } - if (k == 8 && (s[0] & 0x80) != 0) { - self.s = -1 - if (sh > 0) self[self.t - 1] |= ((1 << (self.DB - sh)) - 1) << sh - } - self.clamp() - if (mi) BigInteger.ZERO.subTo(self, self) -} -// (protected) clamp off excess high words -function bnpClamp() { - var c = this.s & this.DM - while (this.t > 0 && this[this.t - 1] == c)--this.t -} -// (public) return string representation in given radix -function bnToString(b) { - var self = this - if (self.s < 0) return "-" + self.negate() - .toString(b) - var k - if (b == 16) k = 4 - else if (b == 8) k = 3 - else if (b == 2) k = 1 - else if (b == 32) k = 5 - else if (b == 4) k = 2 - else return self.toRadix(b) - var km = (1 << k) - 1, - d, m = false, - r = "", - i = self.t - var p = self.DB - (i * self.DB) % k - if (i-- > 0) { - if (p < self.DB && (d = self[i] >> p) > 0) { - m = true - r = int2char(d) - } - while (i >= 0) { - if (p < k) { - d = (self[i] & ((1 << p) - 1)) << (k - p) - d |= self[--i] >> (p += self.DB - k) - } else { - d = (self[i] >> (p -= k)) & km - if (p <= 0) { - p += self.DB - --i - } - } - if (d > 0) m = true - if (m) r += int2char(d) - } - } - return m ? r : "0" -} +var escapeTextContentForBrowser = __webpack_require__(61); -// (public) -this -function bnNegate() { - var r = new BigInteger() - BigInteger.ZERO.subTo(this, r) - return r +/** + * Escapes attribute value to prevent scripting attacks. + * + * @param {*} value Value to escape. + * @return {string} An escaped string. + */ +function quoteAttributeValueForBrowser(value) { + return '"' + escapeTextContentForBrowser(value) + '"'; } -// (public) |this| -function bnAbs() { - return (this.s < 0) ? this.negate() : this -} +module.exports = quoteAttributeValueForBrowser; -// (public) return + if this > a, - if this < a, 0 if equal -function bnCompareTo(a) { - var r = this.s - a.s - if (r != 0) return r - var i = this.t - r = i - a.t - if (r != 0) return (this.s < 0) ? -r : r - while (--i >= 0) - if ((r = this[i] - a[i]) != 0) return r - return 0 -} +/***/ }), +/* 264 */ +/***/ (function(module, exports, __webpack_require__) { -// returns bit length of the integer x -function nbits(x) { - var r = 1, - t - if ((t = x >>> 16) != 0) { - x = t - r += 16 - } - if ((t = x >> 8) != 0) { - x = t - r += 8 - } - if ((t = x >> 4) != 0) { - x = t - r += 4 - } - if ((t = x >> 2) != 0) { - x = t - r += 2 - } - if ((t = x >> 1) != 0) { - x = t - r += 1 - } - return r -} +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -// (public) return the number of bits in "this" -function bnBitLength() { - if (this.t <= 0) return 0 - return this.DB * (this.t - 1) + nbits(this[this.t - 1] ^ (this.s & this.DM)) -} -// (public) return the number of bytes in "this" -function bnByteLength() { - return this.bitLength() >> 3 -} -// (protected) r = this << n*DB -function bnpDLShiftTo(n, r) { - var i - for (i = this.t - 1; i >= 0; --i) r[i + n] = this[i] - for (i = n - 1; i >= 0; --i) r[i] = 0 - r.t = this.t + n - r.s = this.s -} +var EventPluginHub = __webpack_require__(46); -// (protected) r = this >> n*DB -function bnpDRShiftTo(n, r) { - for (var i = n; i < this.t; ++i) r[i - n] = this[i] - r.t = Math.max(this.t - n, 0) - r.s = this.s +function runEventQueueInBatch(events) { + EventPluginHub.enqueueEvents(events); + EventPluginHub.processEventQueue(false); } -// (protected) r = this << n -function bnpLShiftTo(n, r) { - var self = this - var bs = n % self.DB - var cbs = self.DB - bs - var bm = (1 << cbs) - 1 - var ds = Math.floor(n / self.DB), - c = (self.s << bs) & self.DM, - i - for (i = self.t - 1; i >= 0; --i) { - r[i + ds + 1] = (self[i] >> cbs) | c - c = (self[i] & bm) << bs +var ReactEventEmitterMixin = { + /** + * Streams a fired top-level event to `EventPluginHub` where plugins have the + * opportunity to create `ReactEvent`s to be dispatched. + */ + handleTopLevel: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var events = EventPluginHub.extractEvents(topLevelType, targetInst, nativeEvent, nativeEventTarget); + runEventQueueInBatch(events); } - for (i = ds - 1; i >= 0; --i) r[i] = 0 - r[ds] = c - r.t = self.t + ds + 1 - r.s = self.s - r.clamp() -} +}; -// (protected) r = this >> n -function bnpRShiftTo(n, r) { - var self = this - r.s = self.s - var ds = Math.floor(n / self.DB) - if (ds >= self.t) { - r.t = 0 - return - } - var bs = n % self.DB - var cbs = self.DB - bs - var bm = (1 << bs) - 1 - r[0] = self[ds] >> bs - for (var i = ds + 1; i < self.t; ++i) { - r[i - ds - 1] |= (self[i] & bm) << cbs - r[i - ds] = self[i] >> bs - } - if (bs > 0) r[self.t - ds - 1] |= (self.s & bm) << cbs - r.t = self.t - ds - r.clamp() -} +module.exports = ReactEventEmitterMixin; -// (protected) r = this - a -function bnpSubTo(a, r) { - var self = this - var i = 0, - c = 0, - m = Math.min(a.t, self.t) - while (i < m) { - c += self[i] - a[i] - r[i++] = c & self.DM - c >>= self.DB - } - if (a.t < self.t) { - c -= a.s - while (i < self.t) { - c += self[i] - r[i++] = c & self.DM - c >>= self.DB - } - c += self.s - } else { - c += self.s - while (i < a.t) { - c -= a[i] - r[i++] = c & self.DM - c >>= self.DB - } - c -= a.s - } - r.s = (c < 0) ? -1 : 0 - if (c < -1) r[i++] = self.DV + c - else if (c > 0) r[i++] = c - r.t = i - r.clamp() -} +/***/ }), +/* 265 */ +/***/ (function(module, exports, __webpack_require__) { -// (protected) r = this * a, r != this,a (HAC 14.12) -// "this" should be the larger one if appropriate. -function bnpMultiplyTo(a, r) { - var x = this.abs(), - y = a.abs() - var i = x.t - r.t = i + y.t - while (--i >= 0) r[i] = 0 - for (i = 0; i < y.t; ++i) r[i + x.t] = x.am(0, y[i], r, i, 0, x.t) - r.s = 0 - r.clamp() - if (this.s != a.s) BigInteger.ZERO.subTo(r, r) -} +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -// (protected) r = this^2, r != this (HAC 14.16) -function bnpSquareTo(r) { - var x = this.abs() - var i = r.t = 2 * x.t - while (--i >= 0) r[i] = 0 - for (i = 0; i < x.t - 1; ++i) { - var c = x.am(i, x[i], r, 2 * i, 0, 1) - if ((r[i + x.t] += x.am(i + 1, 2 * x[i], r, 2 * i + 1, c, x.t - i - 1)) >= x.DV) { - r[i + x.t] -= x.DV - r[i + x.t + 1] = 1 - } - } - if (r.t > 0) r[r.t - 1] += x.am(i, x[i], r, 2 * i, 0, 1) - r.s = 0 - r.clamp() + + +var ExecutionEnvironment = __webpack_require__(13); + +/** + * Generate a mapping of standard vendor prefixes using the defined style property and event name. + * + * @param {string} styleProp + * @param {string} eventName + * @returns {object} + */ +function makePrefixMap(styleProp, eventName) { + var prefixes = {}; + + prefixes[styleProp.toLowerCase()] = eventName.toLowerCase(); + prefixes['Webkit' + styleProp] = 'webkit' + eventName; + prefixes['Moz' + styleProp] = 'moz' + eventName; + prefixes['ms' + styleProp] = 'MS' + eventName; + prefixes['O' + styleProp] = 'o' + eventName.toLowerCase(); + + return prefixes; } -// (protected) divide this by m, quotient and remainder to q, r (HAC 14.20) -// r != q, this != m. q or r may be null. -function bnpDivRemTo(m, q, r) { - var self = this - var pm = m.abs() - if (pm.t <= 0) return - var pt = self.abs() - if (pt.t < pm.t) { - if (q != null) q.fromInt(0) - if (r != null) self.copyTo(r) - return - } - if (r == null) r = new BigInteger() - var y = new BigInteger(), - ts = self.s, - ms = m.s - var nsh = self.DB - nbits(pm[pm.t - 1]); // normalize modulus - if (nsh > 0) { - pm.lShiftTo(nsh, y) - pt.lShiftTo(nsh, r) - } else { - pm.copyTo(y) - pt.copyTo(r) +/** + * A list of event names to a configurable list of vendor prefixes. + */ +var vendorPrefixes = { + animationend: makePrefixMap('Animation', 'AnimationEnd'), + animationiteration: makePrefixMap('Animation', 'AnimationIteration'), + animationstart: makePrefixMap('Animation', 'AnimationStart'), + transitionend: makePrefixMap('Transition', 'TransitionEnd') +}; + +/** + * Event names that have already been detected and prefixed (if applicable). + */ +var prefixedEventNames = {}; + +/** + * Element to check for prefixes on. + */ +var style = {}; + +/** + * Bootstrap if a DOM exists. + */ +if (ExecutionEnvironment.canUseDOM) { + style = document.createElement('div').style; + + // On some platforms, in particular some releases of Android 4.x, + // the un-prefixed "animation" and "transition" properties are defined on the + // style object but the events that fire will still be prefixed, so we need + // to check if the un-prefixed events are usable, and if not remove them from the map. + if (!('AnimationEvent' in window)) { + delete vendorPrefixes.animationend.animation; + delete vendorPrefixes.animationiteration.animation; + delete vendorPrefixes.animationstart.animation; } - var ys = y.t - var y0 = y[ys - 1] - if (y0 == 0) return - var yt = y0 * (1 << self.F1) + ((ys > 1) ? y[ys - 2] >> self.F2 : 0) - var d1 = self.FV / yt, - d2 = (1 << self.F1) / yt, - e = 1 << self.F2 - var i = r.t, - j = i - ys, - t = (q == null) ? new BigInteger() : q - y.dlShiftTo(j, t) - if (r.compareTo(t) >= 0) { - r[r.t++] = 1 - r.subTo(t, r) + + // Same as above + if (!('TransitionEvent' in window)) { + delete vendorPrefixes.transitionend.transition; } - BigInteger.ONE.dlShiftTo(ys, t) - t.subTo(y, y); // "negative" y so we can replace sub with am later - while (y.t < ys) y[y.t++] = 0 - while (--j >= 0) { - // Estimate quotient digit - var qd = (r[--i] == y0) ? self.DM : Math.floor(r[i] * d1 + (r[i - 1] + e) * d2) - if ((r[i] += y.am(0, qd, r, j, 0, ys)) < qd) { // Try it out - y.dlShiftTo(j, t) - r.subTo(t, r) - while (r[i] < --qd) r.subTo(t, r) - } +} + +/** + * Attempts to determine the correct vendor prefixed event name. + * + * @param {string} eventName + * @returns {string} + */ +function getVendorPrefixedEventName(eventName) { + if (prefixedEventNames[eventName]) { + return prefixedEventNames[eventName]; + } else if (!vendorPrefixes[eventName]) { + return eventName; } - if (q != null) { - r.drShiftTo(ys, q) - if (ts != ms) BigInteger.ZERO.subTo(q, q) + + var prefixMap = vendorPrefixes[eventName]; + + for (var styleProp in prefixMap) { + if (prefixMap.hasOwnProperty(styleProp) && styleProp in style) { + return prefixedEventNames[eventName] = prefixMap[styleProp]; + } } - r.t = ys - r.clamp() - if (nsh > 0) r.rShiftTo(nsh, r); // Denormalize remainder - if (ts < 0) BigInteger.ZERO.subTo(r, r) -} -// (public) this mod a -function bnMod(a) { - var r = new BigInteger() - this.abs() - .divRemTo(a, null, r) - if (this.s < 0 && r.compareTo(BigInteger.ZERO) > 0) a.subTo(r, r) - return r + return ''; } -// Modular reduction using "classic" algorithm -function Classic(m) { - this.m = m -} +module.exports = getVendorPrefixedEventName; -function cConvert(x) { - if (x.s < 0 || x.compareTo(this.m) >= 0) return x.mod(this.m) - else return x -} +/***/ }), +/* 266 */ +/***/ (function(module, exports, __webpack_require__) { -function cRevert(x) { - return x -} +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -function cReduce(x) { - x.divRemTo(this.m, null, x) -} -function cMulTo(x, y, r) { - x.multiplyTo(y, r) - this.reduce(r) -} -function cSqrTo(x, r) { - x.squareTo(r) - this.reduce(r) -} +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); -Classic.prototype.convert = cConvert -Classic.prototype.revert = cRevert -Classic.prototype.reduce = cReduce -Classic.prototype.mulTo = cMulTo -Classic.prototype.sqrTo = cSqrTo +var DOMPropertyOperations = __webpack_require__(138); +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); -// (protected) return "-1/this % 2^DB"; useful for Mont. reduction -// justification: -// xy == 1 (mod m) -// xy = 1+km -// xy(2-xy) = (1+km)(1-km) -// x[y(2-xy)] = 1-k^2m^2 -// x[y(2-xy)] == 1 (mod m^2) -// if y is 1/x mod m, then y(2-xy) is 1/x mod m^2 -// should reduce x and y(2-xy) by m^2 at each step to keep size bounded. -// JS multiply "overflows" differently from C/C++, so care is needed here. -function bnpInvDigit() { - if (this.t < 1) return 0 - var x = this[0] - if ((x & 1) == 0) return 0 - var y = x & 3; // y == 1/x mod 2^2 - y = (y * (2 - (x & 0xf) * y)) & 0xf; // y == 1/x mod 2^4 - y = (y * (2 - (x & 0xff) * y)) & 0xff; // y == 1/x mod 2^8 - y = (y * (2 - (((x & 0xffff) * y) & 0xffff))) & 0xffff; // y == 1/x mod 2^16 - // last step - calculate inverse mod DV directly - // assumes 16 < DB <= 32 and assumes ability to handle 48-bit ints - y = (y * (2 - x * y % this.DV)) % this.DV; // y == 1/x mod 2^dbits - // we really want the negative inverse, and -DV < y < DV - return (y > 0) ? this.DV - y : -y -} +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); -// Montgomery reduction -function Montgomery(m) { - this.m = m - this.mp = m.invDigit() - this.mpl = this.mp & 0x7fff - this.mph = this.mp >> 15 - this.um = (1 << (m.DB - 15)) - 1 - this.mt2 = 2 * m.t -} +var didWarnValueLink = false; +var didWarnCheckedLink = false; +var didWarnValueDefaultValue = false; +var didWarnCheckedDefaultChecked = false; +var didWarnControlledToUncontrolled = false; +var didWarnUncontrolledToControlled = false; -// xR mod m -function montConvert(x) { - var r = new BigInteger() - x.abs() - .dlShiftTo(this.m.t, r) - r.divRemTo(this.m, null, r) - if (x.s < 0 && r.compareTo(BigInteger.ZERO) > 0) this.m.subTo(r, r) - return r +function forceUpdateIfMounted() { + if (this._rootNodeID) { + // DOM component is still mounted; update + ReactDOMInput.updateWrapper(this); + } } -// x/R mod m -function montRevert(x) { - var r = new BigInteger() - x.copyTo(r) - this.reduce(r) - return r +function isControlled(props) { + var usesChecked = props.type === 'checkbox' || props.type === 'radio'; + return usesChecked ? props.checked != null : props.value != null; } -// x = x/R mod m (HAC 14.32) -function montReduce(x) { - while (x.t <= this.mt2) // pad x so am has enough room later - x[x.t++] = 0 - for (var i = 0; i < this.m.t; ++i) { - // faster way of calculating u0 = x[i]*mp mod DV - var j = x[i] & 0x7fff - var u0 = (j * this.mpl + (((j * this.mph + (x[i] >> 15) * this.mpl) & this.um) << 15)) & x.DM - // use am to combine the multiply-shift-add into one call - j = i + this.m.t - x[j] += this.m.am(0, u0, x, i, 0, this.m.t) - // propagate carry - while (x[j] >= x.DV) { - x[j] -= x.DV - x[++j]++ +/** + * Implements an <input> host component that allows setting these optional + * props: `checked`, `value`, `defaultChecked`, and `defaultValue`. + * + * If `checked` or `value` are not supplied (or null/undefined), user actions + * that affect the checked state or value will trigger updates to the element. + * + * If they are supplied (and not null/undefined), the rendered element will not + * trigger updates to the element. Instead, the props must change in order for + * the rendered element to be updated. + * + * The rendered element will be initialized as unchecked (or `defaultChecked`) + * with an empty value (or `defaultValue`). + * + * @see http://www.w3.org/TR/2012/WD-html5-20121025/the-input-element.html + */ +var ReactDOMInput = { + getHostProps: function (inst, props) { + var value = LinkedValueUtils.getValue(props); + var checked = LinkedValueUtils.getChecked(props); + + var hostProps = _assign({ + // Make sure we set .type before any other properties (setting .value + // before .type means .value is lost in IE11 and below) + type: undefined, + // Make sure we set .step before .value (setting .value before .step + // means .value is rounded on mount, based upon step precision) + step: undefined, + // Make sure we set .min & .max before .value (to ensure proper order + // in corner cases such as min or max deriving from value, e.g. Issue #7170) + min: undefined, + max: undefined + }, props, { + defaultChecked: undefined, + defaultValue: undefined, + value: value != null ? value : inst._wrapperState.initialValue, + checked: checked != null ? checked : inst._wrapperState.initialChecked, + onChange: inst._wrapperState.onChange + }); + + return hostProps; + }, + + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + LinkedValueUtils.checkPropTypes('input', props, inst._currentElement._owner); + + var owner = inst._currentElement._owner; + + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + if (props.checkedLink !== undefined && !didWarnCheckedLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`checkedLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnCheckedLink = true; + } + if (props.checked !== undefined && props.defaultChecked !== undefined && !didWarnCheckedDefaultChecked) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both checked and defaultChecked props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnCheckedDefaultChecked = true; + } + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s contains an input of type %s with both value and defaultValue props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnValueDefaultValue = true; + } } - } - x.clamp() - x.drShiftTo(this.m.t, x) - if (x.compareTo(this.m) >= 0) x.subTo(this.m, x) -} -// r = "x^2/R mod m"; x != r -function montSqrTo(x, r) { - x.squareTo(r) - this.reduce(r) -} + var defaultValue = props.defaultValue; + inst._wrapperState = { + initialChecked: props.checked != null ? props.checked : props.defaultChecked, + initialValue: props.value != null ? props.value : defaultValue, + listeners: null, + onChange: _handleChange.bind(inst), + controlled: isControlled(props) + }; + }, -// r = "xy/R mod m"; x,y != r -function montMulTo(x, y, r) { - x.multiplyTo(y, r) - this.reduce(r) -} + updateWrapper: function (inst) { + var props = inst._currentElement.props; -Montgomery.prototype.convert = montConvert -Montgomery.prototype.revert = montRevert -Montgomery.prototype.reduce = montReduce -Montgomery.prototype.mulTo = montMulTo -Montgomery.prototype.sqrTo = montSqrTo + if (process.env.NODE_ENV !== 'production') { + var controlled = isControlled(props); + var owner = inst._currentElement._owner; -// (protected) true iff this is even -function bnpIsEven() { - return ((this.t > 0) ? (this[0] & 1) : this.s) == 0 -} + if (!inst._wrapperState.controlled && controlled && !didWarnUncontrolledToControlled) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing an uncontrolled input of type %s to be controlled. ' + 'Input elements should not switch from uncontrolled to controlled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnUncontrolledToControlled = true; + } + if (inst._wrapperState.controlled && !controlled && !didWarnControlledToUncontrolled) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s is changing a controlled input of type %s to be uncontrolled. ' + 'Input elements should not switch from controlled to uncontrolled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0; + didWarnControlledToUncontrolled = true; + } + } -// (protected) this^e, e < 2^32, doing sqr and mul with "r" (HAC 14.79) -function bnpExp(e, z) { - if (e > 0xffffffff || e < 1) return BigInteger.ONE - var r = new BigInteger(), - r2 = new BigInteger(), - g = z.convert(this), - i = nbits(e) - 1 - g.copyTo(r) - while (--i >= 0) { - z.sqrTo(r, r2) - if ((e & (1 << i)) > 0) z.mulTo(r2, g, r) - else { - var t = r - r = r2 - r2 = t + // TODO: Shouldn't this be getChecked(props)? + var checked = props.checked; + if (checked != null) { + DOMPropertyOperations.setValueForProperty(ReactDOMComponentTree.getNodeFromInstance(inst), 'checked', checked || false); } - } - return z.revert(r) -} -// (public) this^e % m, 0 <= e < 2^32 -function bnModPowInt(e, m) { - var z - if (e < 256 || m.isEven()) z = new Classic(m) - else z = new Montgomery(m) - return this.exp(e, z) -} + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var value = LinkedValueUtils.getValue(props); + if (value != null) { + if (value === 0 && node.value === '') { + node.value = '0'; + // Note: IE9 reports a number inputs as 'text', so check props instead. + } else if (props.type === 'number') { + // Simulate `input.valueAsNumber`. IE9 does not support it + var valueAsNumber = parseFloat(node.value, 10) || 0; -// protected -proto.copyTo = bnpCopyTo -proto.fromInt = bnpFromInt -proto.fromString = bnpFromString -proto.clamp = bnpClamp -proto.dlShiftTo = bnpDLShiftTo -proto.drShiftTo = bnpDRShiftTo -proto.lShiftTo = bnpLShiftTo -proto.rShiftTo = bnpRShiftTo -proto.subTo = bnpSubTo -proto.multiplyTo = bnpMultiplyTo -proto.squareTo = bnpSquareTo -proto.divRemTo = bnpDivRemTo -proto.invDigit = bnpInvDigit -proto.isEven = bnpIsEven -proto.exp = bnpExp + if ( + // eslint-disable-next-line + value != valueAsNumber || + // eslint-disable-next-line + value == valueAsNumber && node.value != value) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + node.value = '' + value; + } + } else if (node.value !== '' + value) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + node.value = '' + value; + } + } else { + if (props.value == null && props.defaultValue != null) { + // In Chrome, assigning defaultValue to certain input types triggers input validation. + // For number inputs, the display value loses trailing decimal points. For email inputs, + // Chrome raises "The specified value <x> is not a valid email address". + // + // Here we check to see if the defaultValue has actually changed, avoiding these problems + // when the user is inputting text + // + // https://github.com/facebook/react/issues/7253 + if (node.defaultValue !== '' + props.defaultValue) { + node.defaultValue = '' + props.defaultValue; + } + } + if (props.checked == null && props.defaultChecked != null) { + node.defaultChecked = !!props.defaultChecked; + } + } + }, -// public -proto.toString = bnToString -proto.negate = bnNegate -proto.abs = bnAbs -proto.compareTo = bnCompareTo -proto.bitLength = bnBitLength -proto.byteLength = bnByteLength -proto.mod = bnMod -proto.modPowInt = bnModPowInt + postMountWrapper: function (inst) { + var props = inst._currentElement.props; -// (public) -function bnClone() { - var r = new BigInteger() - this.copyTo(r) - return r -} + // This is in postMount because we need access to the DOM node, which is not + // available until after the component has mounted. + var node = ReactDOMComponentTree.getNodeFromInstance(inst); -// (public) return value as integer -function bnIntValue() { - if (this.s < 0) { - if (this.t == 1) return this[0] - this.DV - else if (this.t == 0) return -1 - } else if (this.t == 1) return this[0] - else if (this.t == 0) return 0 - // assumes 16 < DB < 32 - return ((this[1] & ((1 << (32 - this.DB)) - 1)) << this.DB) | this[0] -} + // Detach value from defaultValue. We won't do anything if we're working on + // submit or reset inputs as those values & defaultValues are linked. They + // are not resetable nodes so this operation doesn't matter and actually + // removes browser-default values (eg "Submit Query") when no value is + // provided. -// (public) return value as byte -function bnByteValue() { - return (this.t == 0) ? this.s : (this[0] << 24) >> 24 -} + switch (props.type) { + case 'submit': + case 'reset': + break; + case 'color': + case 'date': + case 'datetime': + case 'datetime-local': + case 'month': + case 'time': + case 'week': + // This fixes the no-show issue on iOS Safari and Android Chrome: + // https://github.com/facebook/react/issues/7233 + node.value = ''; + node.value = node.defaultValue; + break; + default: + node.value = node.value; + break; + } -// (public) return value as short (assumes DB>=16) -function bnShortValue() { - return (this.t == 0) ? this.s : (this[0] << 16) >> 16 -} + // Normally, we'd just do `node.checked = node.checked` upon initial mount, less this bug + // this is needed to work around a chrome bug where setting defaultChecked + // will sometimes influence the value of checked (even after detachment). + // Reference: https://bugs.chromium.org/p/chromium/issues/detail?id=608416 + // We need to temporarily unset name to avoid disrupting radio button groups. + var name = node.name; + if (name !== '') { + node.name = ''; + } + node.defaultChecked = !node.defaultChecked; + node.defaultChecked = !node.defaultChecked; + if (name !== '') { + node.name = name; + } + } +}; -// (protected) return x s.t. r^x < DV -function bnpChunkSize(r) { - return Math.floor(Math.LN2 * this.DB / Math.log(r)) -} +function _handleChange(event) { + var props = this._currentElement.props; -// (public) 0 if this == 0, 1 if this > 0 -function bnSigNum() { - if (this.s < 0) return -1 - else if (this.t <= 0 || (this.t == 1 && this[0] <= 0)) return 0 - else return 1 -} + var returnValue = LinkedValueUtils.executeOnChange(props, event); -// (protected) convert to radix string -function bnpToRadix(b) { - if (b == null) b = 10 - if (this.signum() == 0 || b < 2 || b > 36) return "0" - var cs = this.chunkSize(b) - var a = Math.pow(b, cs) - var d = nbv(a), - y = new BigInteger(), - z = new BigInteger(), - r = "" - this.divRemTo(d, y, z) - while (y.signum() > 0) { - r = (a + z.intValue()) - .toString(b) - .substr(1) + r - y.divRemTo(d, y, z) + // Here we use asap to wait until all updates have propagated, which + // is important when using controlled components within layers: + // https://github.com/facebook/react/issues/1698 + ReactUpdates.asap(forceUpdateIfMounted, this); + + var name = props.name; + if (props.type === 'radio' && name != null) { + var rootNode = ReactDOMComponentTree.getNodeFromInstance(this); + var queryRoot = rootNode; + + while (queryRoot.parentNode) { + queryRoot = queryRoot.parentNode; + } + + // If `rootNode.form` was non-null, then we could try `form.elements`, + // but that sometimes behaves strangely in IE8. We could also try using + // `form.getElementsByName`, but that will only return direct children + // and won't include inputs that use the HTML5 `form=` attribute. Since + // the input might not even be in a form, let's just use the global + // `querySelectorAll` to ensure we don't miss anything. + var group = queryRoot.querySelectorAll('input[name=' + JSON.stringify('' + name) + '][type="radio"]'); + + for (var i = 0; i < group.length; i++) { + var otherNode = group[i]; + if (otherNode === rootNode || otherNode.form !== rootNode.form) { + continue; + } + // This will throw if radio buttons rendered by different copies of React + // and the same name are rendered into the same form (same as #1939). + // That's probably okay; we don't support it just as we don't support + // mixing React radio buttons with non-React ones. + var otherInstance = ReactDOMComponentTree.getInstanceFromNode(otherNode); + !otherInstance ? process.env.NODE_ENV !== 'production' ? invariant(false, 'ReactDOMInput: Mixing React and non-React radio inputs with the same `name` is not supported.') : _prodInvariant('90') : void 0; + // If this is a controlled radio button group, forcing the input that + // was previously checked to update will cause it to be come re-checked + // as appropriate. + ReactUpdates.asap(forceUpdateIfMounted, otherInstance); + } } - return z.intValue() - .toString(b) + r + + return returnValue; } -// (protected) convert from radix string -function bnpFromRadix(s, b) { - var self = this - self.fromInt(0) - if (b == null) b = 10 - var cs = self.chunkSize(b) - var d = Math.pow(b, cs), - mi = false, - j = 0, - w = 0 - for (var i = 0; i < s.length; ++i) { - var x = intAt(s, i) - if (x < 0) { - if (s.charAt(i) == "-" && self.signum() == 0) mi = true - continue +module.exports = ReactDOMInput; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 267 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _assign = __webpack_require__(8); + +var React = __webpack_require__(36); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactDOMSelect = __webpack_require__(140); + +var warning = __webpack_require__(3); +var didWarnInvalidOptionChildren = false; + +function flattenChildren(children) { + var content = ''; + + // Flatten children and warn if they aren't strings or numbers; + // invalid types are ignored. + React.Children.forEach(children, function (child) { + if (child == null) { + return; } - w = b * w + x - if (++j >= cs) { - self.dMultiply(d) - self.dAddOffset(w, 0) - j = 0 - w = 0 + if (typeof child === 'string' || typeof child === 'number') { + content += child; + } else if (!didWarnInvalidOptionChildren) { + didWarnInvalidOptionChildren = true; + process.env.NODE_ENV !== 'production' ? warning(false, 'Only strings and numbers are supported as <option> children.') : void 0; } - } - if (j > 0) { - self.dMultiply(Math.pow(b, j)) - self.dAddOffset(w, 0) - } - if (mi) BigInteger.ZERO.subTo(self, self) + }); + + return content; } -// (protected) alternate constructor -function bnpFromNumber(a, b, c) { - var self = this - if ("number" == typeof b) { - // new BigInteger(int,int,RNG) - if (a < 2) self.fromInt(1) - else { - self.fromNumber(a, c) - if (!self.testBit(a - 1)) // force MSB set - self.bitwiseTo(BigInteger.ONE.shiftLeft(a - 1), op_or, self) - if (self.isEven()) self.dAddOffset(1, 0); // force odd - while (!self.isProbablePrime(b)) { - self.dAddOffset(2, 0) - if (self.bitLength() > a) self.subTo(BigInteger.ONE.shiftLeft(a - 1), self) +/** + * Implements an <option> host component that warns when `selected` is set. + */ +var ReactDOMOption = { + mountWrapper: function (inst, props, hostParent) { + // TODO (yungsters): Remove support for `selected` in <option>. + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(props.selected == null, 'Use the `defaultValue` or `value` props on <select> instead of ' + 'setting `selected` on <option>.') : void 0; + } + + // Look up whether this option is 'selected' + var selectValue = null; + if (hostParent != null) { + var selectParent = hostParent; + + if (selectParent._tag === 'optgroup') { + selectParent = selectParent._hostParent; + } + + if (selectParent != null && selectParent._tag === 'select') { + selectValue = ReactDOMSelect.getSelectValueContext(selectParent); } } - } else { - // new BigInteger(int,RNG) - var x = new Array(), - t = a & 7 - x.length = (a >> 3) + 1 - b.nextBytes(x) - if (t > 0) x[0] &= ((1 << t) - 1) - else x[0] = 0 - self.fromString(x, 256) - } -} -// (public) convert to bigendian byte array -function bnToByteArray() { - var self = this - var i = self.t, - r = new Array() - r[0] = self.s - var p = self.DB - (i * self.DB) % 8, - d, k = 0 - if (i-- > 0) { - if (p < self.DB && (d = self[i] >> p) != (self.s & self.DM) >> p) - r[k++] = d | (self.s << (self.DB - p)) - while (i >= 0) { - if (p < 8) { - d = (self[i] & ((1 << p) - 1)) << (8 - p) - d |= self[--i] >> (p += self.DB - 8) + // If the value is null (e.g., no specified value or after initial mount) + // or missing (e.g., for <datalist>), we don't change props.selected + var selected = null; + if (selectValue != null) { + var value; + if (props.value != null) { + value = props.value + ''; } else { - d = (self[i] >> (p -= 8)) & 0xff - if (p <= 0) { - p += self.DB - --i + value = flattenChildren(props.children); + } + selected = false; + if (Array.isArray(selectValue)) { + // multiple + for (var i = 0; i < selectValue.length; i++) { + if ('' + selectValue[i] === value) { + selected = true; + break; + } } + } else { + selected = '' + selectValue === value; } - if ((d & 0x80) != 0) d |= -256 - if (k === 0 && (self.s & 0x80) != (d & 0x80))++k - if (k > 0 || d != self.s) r[k++] = d } - } - return r -} -function bnEquals(a) { - return (this.compareTo(a) == 0) -} + inst._wrapperState = { selected: selected }; + }, -function bnMin(a) { - return (this.compareTo(a) < 0) ? this : a -} + postMountWrapper: function (inst) { + // value="" should make a value attribute (#6219) + var props = inst._currentElement.props; + if (props.value != null) { + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + node.setAttribute('value', props.value); + } + }, -function bnMax(a) { - return (this.compareTo(a) > 0) ? this : a -} + getHostProps: function (inst, props) { + var hostProps = _assign({ selected: undefined, children: undefined }, props); -// (protected) r = this op a (bitwise) -function bnpBitwiseTo(a, op, r) { - var self = this - var i, f, m = Math.min(a.t, self.t) - for (i = 0; i < m; ++i) r[i] = op(self[i], a[i]) - if (a.t < self.t) { - f = a.s & self.DM - for (i = m; i < self.t; ++i) r[i] = op(self[i], f) - r.t = self.t - } else { - f = self.s & self.DM - for (i = m; i < a.t; ++i) r[i] = op(f, a[i]) - r.t = a.t - } - r.s = op(self.s, a.s) - r.clamp() -} + // Read state only from initial mount because <select> updates value + // manually; we need the initial state only for server rendering + if (inst._wrapperState.selected != null) { + hostProps.selected = inst._wrapperState.selected; + } -// (public) this & a -function op_and(x, y) { - return x & y -} + var content = flattenChildren(props.children); -function bnAnd(a) { - var r = new BigInteger() - this.bitwiseTo(a, op_and, r) - return r -} + if (content) { + hostProps.children = content; + } -// (public) this | a -function op_or(x, y) { - return x | y -} + return hostProps; + } +}; -function bnOr(a) { - var r = new BigInteger() - this.bitwiseTo(a, op_or, r) - return r -} +module.exports = ReactDOMOption; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -// (public) this ^ a -function op_xor(x, y) { - return x ^ y -} +/***/ }), +/* 268 */ +/***/ (function(module, exports, __webpack_require__) { -function bnXor(a) { - var r = new BigInteger() - this.bitwiseTo(a, op_xor, r) - return r -} +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -// (public) this & ~a -function op_andnot(x, y) { - return x & ~y -} -function bnAndNot(a) { - var r = new BigInteger() - this.bitwiseTo(a, op_andnot, r) - return r -} -// (public) ~this -function bnNot() { - var r = new BigInteger() - for (var i = 0; i < this.t; ++i) r[i] = this.DM & ~this[i] - r.t = this.t - r.s = ~this.s - return r -} +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); -// (public) this << n -function bnShiftLeft(n) { - var r = new BigInteger() - if (n < 0) this.rShiftTo(-n, r) - else this.lShiftTo(n, r) - return r -} +var LinkedValueUtils = __webpack_require__(85); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); -// (public) this >> n -function bnShiftRight(n) { - var r = new BigInteger() - if (n < 0) this.lShiftTo(-n, r) - else this.rShiftTo(n, r) - return r -} +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); -// return index of lowest 1-bit in x, x < 2^31 -function lbit(x) { - if (x == 0) return -1 - var r = 0 - if ((x & 0xffff) == 0) { - x >>= 16 - r += 16 - } - if ((x & 0xff) == 0) { - x >>= 8 - r += 8 - } - if ((x & 0xf) == 0) { - x >>= 4 - r += 4 - } - if ((x & 3) == 0) { - x >>= 2 - r += 2 +var didWarnValueLink = false; +var didWarnValDefaultVal = false; + +function forceUpdateIfMounted() { + if (this._rootNodeID) { + // DOM component is still mounted; update + ReactDOMTextarea.updateWrapper(this); } - if ((x & 1) == 0)++r - return r } -// (public) returns index of lowest 1-bit (or -1 if none) -function bnGetLowestSetBit() { - for (var i = 0; i < this.t; ++i) - if (this[i] != 0) return i * this.DB + lbit(this[i]) - if (this.s < 0) return this.t * this.DB - return -1 -} +/** + * Implements a <textarea> host component that allows setting `value`, and + * `defaultValue`. This differs from the traditional DOM API because value is + * usually set as PCDATA children. + * + * If `value` is not supplied (or null/undefined), user actions that affect the + * value will trigger updates to the element. + * + * If `value` is supplied (and not null/undefined), the rendered element will + * not trigger updates to the element. Instead, the `value` prop must change in + * order for the rendered element to be updated. + * + * The rendered element will be initialized with an empty value, the prop + * `defaultValue` if specified, or the children content (deprecated). + */ +var ReactDOMTextarea = { + getHostProps: function (inst, props) { + !(props.dangerouslySetInnerHTML == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, '`dangerouslySetInnerHTML` does not make sense on <textarea>.') : _prodInvariant('91') : void 0; -// return number of 1 bits in x -function cbit(x) { - var r = 0 - while (x != 0) { - x &= x - 1 - ++r - } - return r -} + // Always set children to the same thing. In IE9, the selection range will + // get reset if `textContent` is mutated. We could add a check in setTextContent + // to only set the value if/when the value differs from the node value (which would + // completely solve this IE9 bug), but Sebastian+Ben seemed to like this solution. + // The value can be a boolean or object so that's why it's forced to be a string. + var hostProps = _assign({}, props, { + value: undefined, + defaultValue: undefined, + children: '' + inst._wrapperState.initialValue, + onChange: inst._wrapperState.onChange + }); -// (public) return number of set bits -function bnBitCount() { - var r = 0, - x = this.s & this.DM - for (var i = 0; i < this.t; ++i) r += cbit(this[i] ^ x) - return r -} + return hostProps; + }, -// (public) true iff nth bit is set -function bnTestBit(n) { - var j = Math.floor(n / this.DB) - if (j >= this.t) return (this.s != 0) - return ((this[j] & (1 << (n % this.DB))) != 0) -} + mountWrapper: function (inst, props) { + if (process.env.NODE_ENV !== 'production') { + LinkedValueUtils.checkPropTypes('textarea', props, inst._currentElement._owner); + if (props.valueLink !== undefined && !didWarnValueLink) { + process.env.NODE_ENV !== 'production' ? warning(false, '`valueLink` prop on `textarea` is deprecated; set `value` and `onChange` instead.') : void 0; + didWarnValueLink = true; + } + if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValDefaultVal) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Textarea elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0; + didWarnValDefaultVal = true; + } + } -// (protected) this op (1<<n) -function bnpChangeBit(n, op) { - var r = BigInteger.ONE.shiftLeft(n) - this.bitwiseTo(r, op, r) - return r -} + var value = LinkedValueUtils.getValue(props); + var initialValue = value; -// (public) this | (1<<n) -function bnSetBit(n) { - return this.changeBit(n, op_or) -} + // Only bother fetching default value if we're going to use it + if (value == null) { + var defaultValue = props.defaultValue; + // TODO (yungsters): Remove support for children content in <textarea>. + var children = props.children; + if (children != null) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(false, 'Use the `defaultValue` or `value` props instead of setting ' + 'children on <textarea>.') : void 0; + } + !(defaultValue == null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'If you supply `defaultValue` on a <textarea>, do not pass children.') : _prodInvariant('92') : void 0; + if (Array.isArray(children)) { + !(children.length <= 1) ? process.env.NODE_ENV !== 'production' ? invariant(false, '<textarea> can only have at most one child.') : _prodInvariant('93') : void 0; + children = children[0]; + } -// (public) this & ~(1<<n) -function bnClearBit(n) { - return this.changeBit(n, op_andnot) -} + defaultValue = '' + children; + } + if (defaultValue == null) { + defaultValue = ''; + } + initialValue = defaultValue; + } -// (public) this ^ (1<<n) -function bnFlipBit(n) { - return this.changeBit(n, op_xor) -} + inst._wrapperState = { + initialValue: '' + initialValue, + listeners: null, + onChange: _handleChange.bind(inst) + }; + }, -// (protected) r = this + a -function bnpAddTo(a, r) { - var self = this + updateWrapper: function (inst) { + var props = inst._currentElement.props; - var i = 0, - c = 0, - m = Math.min(a.t, self.t) - while (i < m) { - c += self[i] + a[i] - r[i++] = c & self.DM - c >>= self.DB - } - if (a.t < self.t) { - c += a.s - while (i < self.t) { - c += self[i] - r[i++] = c & self.DM - c >>= self.DB + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var value = LinkedValueUtils.getValue(props); + if (value != null) { + // Cast `value` to a string to ensure the value is set correctly. While + // browsers typically do this as necessary, jsdom doesn't. + var newValue = '' + value; + + // To avoid side effects (such as losing text selection), only set value if changed + if (newValue !== node.value) { + node.value = newValue; + } + if (props.defaultValue == null) { + node.defaultValue = newValue; + } } - c += self.s - } else { - c += self.s - while (i < a.t) { - c += a[i] - r[i++] = c & self.DM - c >>= self.DB + if (props.defaultValue != null) { + node.defaultValue = props.defaultValue; + } + }, + + postMountWrapper: function (inst) { + // This is in postMount because we need access to the DOM node, which is not + // available until after the component has mounted. + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + var textContent = node.textContent; + + // Only set node.value if textContent is equal to the expected + // initial value. In IE10/IE11 there is a bug where the placeholder attribute + // will populate textContent as well. + // https://developer.microsoft.com/microsoft-edge/platform/issues/101525/ + if (textContent === inst._wrapperState.initialValue) { + node.value = textContent; } - c += a.s } - r.s = (c < 0) ? -1 : 0 - if (c > 0) r[i++] = c - else if (c < -1) r[i++] = self.DV + c - r.t = i - r.clamp() -} +}; -// (public) this + a -function bnAdd(a) { - var r = new BigInteger() - this.addTo(a, r) - return r +function _handleChange(event) { + var props = this._currentElement.props; + var returnValue = LinkedValueUtils.executeOnChange(props, event); + ReactUpdates.asap(forceUpdateIfMounted, this); + return returnValue; } -// (public) this - a -function bnSubtract(a) { - var r = new BigInteger() - this.subTo(a, r) - return r +module.exports = ReactDOMTextarea; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + +/***/ }), +/* 269 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + + + +var _prodInvariant = __webpack_require__(5); + +var ReactComponentEnvironment = __webpack_require__(86); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); + +var ReactCurrentOwner = __webpack_require__(22); +var ReactReconciler = __webpack_require__(38); +var ReactChildReconciler = __webpack_require__(270); + +var emptyFunction = __webpack_require__(18); +var flattenChildren = __webpack_require__(277); +var invariant = __webpack_require__(2); + +/** + * Make an update for markup to be rendered and inserted at a supplied index. + * + * @param {string} markup Markup that renders into an element. + * @param {number} toIndex Destination index. + * @private + */ +function makeInsertMarkup(markup, afterNode, toIndex) { + // NOTE: Null values reduce hidden classes. + return { + type: 'INSERT_MARKUP', + content: markup, + fromIndex: null, + fromNode: null, + toIndex: toIndex, + afterNode: afterNode + }; } -// (public) this * a -function bnMultiply(a) { - var r = new BigInteger() - this.multiplyTo(a, r) - return r +/** + * Make an update for moving an existing element to another index. + * + * @param {number} fromIndex Source index of the existing element. + * @param {number} toIndex Destination index of the element. + * @private + */ +function makeMove(child, afterNode, toIndex) { + // NOTE: Null values reduce hidden classes. + return { + type: 'MOVE_EXISTING', + content: null, + fromIndex: child._mountIndex, + fromNode: ReactReconciler.getHostNode(child), + toIndex: toIndex, + afterNode: afterNode + }; } -// (public) this^2 -function bnSquare() { - var r = new BigInteger() - this.squareTo(r) - return r +/** + * Make an update for removing an element at an index. + * + * @param {number} fromIndex Index of the element to remove. + * @private + */ +function makeRemove(child, node) { + // NOTE: Null values reduce hidden classes. + return { + type: 'REMOVE_NODE', + content: null, + fromIndex: child._mountIndex, + fromNode: node, + toIndex: null, + afterNode: null + }; } -// (public) this / a -function bnDivide(a) { - var r = new BigInteger() - this.divRemTo(a, r, null) - return r +/** + * Make an update for setting the markup of a node. + * + * @param {string} markup Markup that renders into an element. + * @private + */ +function makeSetMarkup(markup) { + // NOTE: Null values reduce hidden classes. + return { + type: 'SET_MARKUP', + content: markup, + fromIndex: null, + fromNode: null, + toIndex: null, + afterNode: null + }; } -// (public) this % a -function bnRemainder(a) { - var r = new BigInteger() - this.divRemTo(a, null, r) - return r +/** + * Make an update for setting the text content. + * + * @param {string} textContent Text content to set. + * @private + */ +function makeTextContent(textContent) { + // NOTE: Null values reduce hidden classes. + return { + type: 'TEXT_CONTENT', + content: textContent, + fromIndex: null, + fromNode: null, + toIndex: null, + afterNode: null + }; } -// (public) [this/a,this%a] -function bnDivideAndRemainder(a) { - var q = new BigInteger(), - r = new BigInteger() - this.divRemTo(a, q, r) - return new Array(q, r) +/** + * Push an update, if any, onto the queue. Creates a new queue if none is + * passed and always returns the queue. Mutative. + */ +function enqueue(queue, update) { + if (update) { + queue = queue || []; + queue.push(update); + } + return queue; } -// (protected) this *= n, this >= 0, 1 < n < DV -function bnpDMultiply(n) { - this[this.t] = this.am(0, n - 1, this, 0, 0, this.t) - ++this.t - this.clamp() +/** + * Processes any enqueued updates. + * + * @private + */ +function processQueue(inst, updateQueue) { + ReactComponentEnvironment.processChildrenUpdates(inst, updateQueue); } -// (protected) this += n << w words, this >= 0 -function bnpDAddOffset(n, w) { - if (n == 0) return - while (this.t <= w) this[this.t++] = 0 - this[w] += n - while (this[w] >= this.DV) { - this[w] -= this.DV - if (++w >= this.t) this[this.t++] = 0 - ++this[w] - } +var setChildrenForInstrumentation = emptyFunction; +if (process.env.NODE_ENV !== 'production') { + var getDebugID = function (inst) { + if (!inst._debugID) { + // Check for ART-like instances. TODO: This is silly/gross. + var internal; + if (internal = ReactInstanceMap.get(inst)) { + inst = internal; + } + } + return inst._debugID; + }; + setChildrenForInstrumentation = function (children) { + var debugID = getDebugID(this); + // TODO: React Native empty components are also multichild. + // This means they still get into this method but don't have _debugID. + if (debugID !== 0) { + ReactInstrumentation.debugTool.onSetChildren(debugID, children ? Object.keys(children).map(function (key) { + return children[key]._debugID; + }) : []); + } + }; } -// A "null" reducer -function NullExp() {} +/** + * ReactMultiChild are capable of reconciling multiple children. + * + * @class ReactMultiChild + * @internal + */ +var ReactMultiChild = { + /** + * Provides common functionality for components that must reconcile multiple + * children. This is used by `ReactDOMComponent` to mount, update, and + * unmount child components. + * + * @lends {ReactMultiChild.prototype} + */ + Mixin: { + _reconcilerInstantiateChildren: function (nestedChildren, transaction, context) { + if (process.env.NODE_ENV !== 'production') { + var selfDebugID = getDebugID(this); + if (this._currentElement) { + try { + ReactCurrentOwner.current = this._currentElement._owner; + return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context, selfDebugID); + } finally { + ReactCurrentOwner.current = null; + } + } + } + return ReactChildReconciler.instantiateChildren(nestedChildren, transaction, context); + }, -function nNop(x) { - return x -} + _reconcilerUpdateChildren: function (prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context) { + var nextChildren; + var selfDebugID = 0; + if (process.env.NODE_ENV !== 'production') { + selfDebugID = getDebugID(this); + if (this._currentElement) { + try { + ReactCurrentOwner.current = this._currentElement._owner; + nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); + } finally { + ReactCurrentOwner.current = null; + } + ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); + return nextChildren; + } + } + nextChildren = flattenChildren(nextNestedChildrenElements, selfDebugID); + ReactChildReconciler.updateChildren(prevChildren, nextChildren, mountImages, removedNodes, transaction, this, this._hostContainerInfo, context, selfDebugID); + return nextChildren; + }, -function nMulTo(x, y, r) { - x.multiplyTo(y, r) -} + /** + * Generates a "mount image" for each of the supplied children. In the case + * of `ReactDOMComponent`, a mount image is a string of markup. + * + * @param {?object} nestedChildren Nested child maps. + * @return {array} An array of mounted representations. + * @internal + */ + mountChildren: function (nestedChildren, transaction, context) { + var children = this._reconcilerInstantiateChildren(nestedChildren, transaction, context); + this._renderedChildren = children; -function nSqrTo(x, r) { - x.squareTo(r) -} + var mountImages = []; + var index = 0; + for (var name in children) { + if (children.hasOwnProperty(name)) { + var child = children[name]; + var selfDebugID = 0; + if (process.env.NODE_ENV !== 'production') { + selfDebugID = getDebugID(this); + } + var mountImage = ReactReconciler.mountComponent(child, transaction, this, this._hostContainerInfo, context, selfDebugID); + child._mountIndex = index++; + mountImages.push(mountImage); + } + } -NullExp.prototype.convert = nNop -NullExp.prototype.revert = nNop -NullExp.prototype.mulTo = nMulTo -NullExp.prototype.sqrTo = nSqrTo + if (process.env.NODE_ENV !== 'production') { + setChildrenForInstrumentation.call(this, children); + } -// (public) this^e -function bnPow(e) { - return this.exp(e, new NullExp()) -} + return mountImages; + }, -// (protected) r = lower n words of "this * a", a.t <= n -// "this" should be the larger one if appropriate. -function bnpMultiplyLowerTo(a, n, r) { - var i = Math.min(this.t + a.t, n) - r.s = 0; // assumes a,this >= 0 - r.t = i - while (i > 0) r[--i] = 0 - var j - for (j = r.t - this.t; i < j; ++i) r[i + this.t] = this.am(0, a[i], r, i, 0, this.t) - for (j = Math.min(a.t, n); i < j; ++i) this.am(0, a[i], r, i, 0, n - i) - r.clamp() -} + /** + * Replaces any rendered children with a text content string. + * + * @param {string} nextContent String of content. + * @internal + */ + updateTextContent: function (nextContent) { + var prevChildren = this._renderedChildren; + // Remove any rendered children. + ReactChildReconciler.unmountChildren(prevChildren, false); + for (var name in prevChildren) { + if (prevChildren.hasOwnProperty(name)) { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; + } + } + // Set new text content. + var updates = [makeTextContent(nextContent)]; + processQueue(this, updates); + }, -// (protected) r = "this * a" without lower n words, n > 0 -// "this" should be the larger one if appropriate. -function bnpMultiplyUpperTo(a, n, r) { - --n - var i = r.t = this.t + a.t - n - r.s = 0; // assumes a,this >= 0 - while (--i >= 0) r[i] = 0 - for (i = Math.max(n - this.t, 0); i < a.t; ++i) - r[this.t + i - n] = this.am(n - i, a[i], r, 0, 0, this.t + i - n) - r.clamp() - r.drShiftTo(1, r) -} + /** + * Replaces any rendered children with a markup string. + * + * @param {string} nextMarkup String of markup. + * @internal + */ + updateMarkup: function (nextMarkup) { + var prevChildren = this._renderedChildren; + // Remove any rendered children. + ReactChildReconciler.unmountChildren(prevChildren, false); + for (var name in prevChildren) { + if (prevChildren.hasOwnProperty(name)) { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'updateTextContent called on non-empty component.') : _prodInvariant('118') : void 0; + } + } + var updates = [makeSetMarkup(nextMarkup)]; + processQueue(this, updates); + }, -// Barrett modular reduction -function Barrett(m) { - // setup Barrett - this.r2 = new BigInteger() - this.q3 = new BigInteger() - BigInteger.ONE.dlShiftTo(2 * m.t, this.r2) - this.mu = this.r2.divide(m) - this.m = m -} + /** + * Updates the rendered children with new children. + * + * @param {?object} nextNestedChildrenElements Nested child element maps. + * @param {ReactReconcileTransaction} transaction + * @internal + */ + updateChildren: function (nextNestedChildrenElements, transaction, context) { + // Hook used by React ART + this._updateChildren(nextNestedChildrenElements, transaction, context); + }, -function barrettConvert(x) { - if (x.s < 0 || x.t > 2 * this.m.t) return x.mod(this.m) - else if (x.compareTo(this.m) < 0) return x - else { - var r = new BigInteger() - x.copyTo(r) - this.reduce(r) - return r - } -} + /** + * @param {?object} nextNestedChildrenElements Nested child element maps. + * @param {ReactReconcileTransaction} transaction + * @final + * @protected + */ + _updateChildren: function (nextNestedChildrenElements, transaction, context) { + var prevChildren = this._renderedChildren; + var removedNodes = {}; + var mountImages = []; + var nextChildren = this._reconcilerUpdateChildren(prevChildren, nextNestedChildrenElements, mountImages, removedNodes, transaction, context); + if (!nextChildren && !prevChildren) { + return; + } + var updates = null; + var name; + // `nextIndex` will increment for each child in `nextChildren`, but + // `lastIndex` will be the last index visited in `prevChildren`. + var nextIndex = 0; + var lastIndex = 0; + // `nextMountIndex` will increment for each newly mounted child. + var nextMountIndex = 0; + var lastPlacedNode = null; + for (name in nextChildren) { + if (!nextChildren.hasOwnProperty(name)) { + continue; + } + var prevChild = prevChildren && prevChildren[name]; + var nextChild = nextChildren[name]; + if (prevChild === nextChild) { + updates = enqueue(updates, this.moveChild(prevChild, lastPlacedNode, nextIndex, lastIndex)); + lastIndex = Math.max(prevChild._mountIndex, lastIndex); + prevChild._mountIndex = nextIndex; + } else { + if (prevChild) { + // Update `lastIndex` before `_mountIndex` gets unset by unmounting. + lastIndex = Math.max(prevChild._mountIndex, lastIndex); + // The `removedNodes` loop below will actually remove the child. + } + // The child must be instantiated before it's mounted. + updates = enqueue(updates, this._mountChildAtIndex(nextChild, mountImages[nextMountIndex], lastPlacedNode, nextIndex, transaction, context)); + nextMountIndex++; + } + nextIndex++; + lastPlacedNode = ReactReconciler.getHostNode(nextChild); + } + // Remove children that are no longer present. + for (name in removedNodes) { + if (removedNodes.hasOwnProperty(name)) { + updates = enqueue(updates, this._unmountChild(prevChildren[name], removedNodes[name])); + } + } + if (updates) { + processQueue(this, updates); + } + this._renderedChildren = nextChildren; -function barrettRevert(x) { - return x -} + if (process.env.NODE_ENV !== 'production') { + setChildrenForInstrumentation.call(this, nextChildren); + } + }, -// x = x mod m (HAC 14.42) -function barrettReduce(x) { - var self = this - x.drShiftTo(self.m.t - 1, self.r2) - if (x.t > self.m.t + 1) { - x.t = self.m.t + 1 - x.clamp() - } - self.mu.multiplyUpperTo(self.r2, self.m.t + 1, self.q3) - self.m.multiplyLowerTo(self.q3, self.m.t + 1, self.r2) - while (x.compareTo(self.r2) < 0) x.dAddOffset(1, self.m.t + 1) - x.subTo(self.r2, x) - while (x.compareTo(self.m) >= 0) x.subTo(self.m, x) -} + /** + * Unmounts all rendered children. This should be used to clean up children + * when this component is unmounted. It does not actually perform any + * backend operations. + * + * @internal + */ + unmountChildren: function (safely) { + var renderedChildren = this._renderedChildren; + ReactChildReconciler.unmountChildren(renderedChildren, safely); + this._renderedChildren = null; + }, -// r = x^2 mod m; x != r -function barrettSqrTo(x, r) { - x.squareTo(r) - this.reduce(r) -} + /** + * Moves a child component to the supplied index. + * + * @param {ReactComponent} child Component to move. + * @param {number} toIndex Destination index of the element. + * @param {number} lastIndex Last index visited of the siblings of `child`. + * @protected + */ + moveChild: function (child, afterNode, toIndex, lastIndex) { + // If the index of `child` is less than `lastIndex`, then it needs to + // be moved. Otherwise, we do not need to move it because a child will be + // inserted or moved before `child`. + if (child._mountIndex < lastIndex) { + return makeMove(child, afterNode, toIndex); + } + }, -// r = x*y mod m; x,y != r -function barrettMulTo(x, y, r) { - x.multiplyTo(y, r) - this.reduce(r) -} + /** + * Creates a child component. + * + * @param {ReactComponent} child Component to create. + * @param {string} mountImage Markup to insert. + * @protected + */ + createChild: function (child, afterNode, mountImage) { + return makeInsertMarkup(mountImage, afterNode, child._mountIndex); + }, -Barrett.prototype.convert = barrettConvert -Barrett.prototype.revert = barrettRevert -Barrett.prototype.reduce = barrettReduce -Barrett.prototype.mulTo = barrettMulTo -Barrett.prototype.sqrTo = barrettSqrTo + /** + * Removes a child component. + * + * @param {ReactComponent} child Child to remove. + * @protected + */ + removeChild: function (child, node) { + return makeRemove(child, node); + }, -// (public) this^e % m (HAC 14.85) -function bnModPow(e, m) { - var i = e.bitLength(), - k, r = nbv(1), - z - if (i <= 0) return r - else if (i < 18) k = 1 - else if (i < 48) k = 3 - else if (i < 144) k = 4 - else if (i < 768) k = 5 - else k = 6 - if (i < 8) - z = new Classic(m) - else if (m.isEven()) - z = new Barrett(m) - else - z = new Montgomery(m) + /** + * Mounts a child with the supplied name. + * + * NOTE: This is part of `updateChildren` and is here for readability. + * + * @param {ReactComponent} child Component to mount. + * @param {string} name Name of the child. + * @param {number} index Index at which to insert the child. + * @param {ReactReconcileTransaction} transaction + * @private + */ + _mountChildAtIndex: function (child, mountImage, afterNode, index, transaction, context) { + child._mountIndex = index; + return this.createChild(child, afterNode, mountImage); + }, - // precomputation - var g = new Array(), - n = 3, - k1 = k - 1, - km = (1 << k) - 1 - g[1] = z.convert(this) - if (k > 1) { - var g2 = new BigInteger() - z.sqrTo(g[1], g2) - while (n <= km) { - g[n] = new BigInteger() - z.mulTo(g2, g[n - 2], g[n]) - n += 2 + /** + * Unmounts a rendered child. + * + * NOTE: This is part of `updateChildren` and is here for readability. + * + * @param {ReactComponent} child Component to unmount. + * @private + */ + _unmountChild: function (child, node) { + var update = this.removeChild(child, node); + child._mountIndex = null; + return update; } } +}; - var j = e.t - 1, - w, is1 = true, - r2 = new BigInteger(), - t - i = nbits(e[j]) - 1 - while (j >= 0) { - if (i >= k1) w = (e[j] >> (i - k1)) & km - else { - w = (e[j] & ((1 << (i + 1)) - 1)) << (k1 - i) - if (j > 0) w |= e[j - 1] >> (this.DB + i - k1) - } +module.exports = ReactMultiChild; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - n = k - while ((w & 1) == 0) { - w >>= 1 - --n - } - if ((i -= n) < 0) { - i += this.DB - --j - } - if (is1) { // ret == 1, don't bother squaring or multiplying it - g[w].copyTo(r) - is1 = false - } else { - while (n > 1) { - z.sqrTo(r, r2) - z.sqrTo(r2, r) - n -= 2 - } - if (n > 0) z.sqrTo(r, r2) - else { - t = r - r = r2 - r2 = t - } - z.mulTo(r2, g[w], r) - } +/***/ }), +/* 270 */ +/***/ (function(module, exports, __webpack_require__) { - while (j >= 0 && (e[j] & (1 << i)) == 0) { - z.sqrTo(r, r2) - t = r - r = r2 - r2 = t - if (--i < 0) { - i = this.DB - 1 - --j - } - } - } - return z.revert(r) -} +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -// (public) gcd(this,a) (HAC 14.54) -function bnGCD(a) { - var x = (this.s < 0) ? this.negate() : this.clone() - var y = (a.s < 0) ? a.negate() : a.clone() - if (x.compareTo(y) < 0) { - var t = x - x = y - y = t - } - var i = x.getLowestSetBit(), - g = y.getLowestSetBit() - if (g < 0) return x - if (i < g) g = i - if (g > 0) { - x.rShiftTo(g, x) - y.rShiftTo(g, y) - } - while (x.signum() > 0) { - if ((i = x.getLowestSetBit()) > 0) x.rShiftTo(i, x) - if ((i = y.getLowestSetBit()) > 0) y.rShiftTo(i, y) - if (x.compareTo(y) >= 0) { - x.subTo(y, x) - x.rShiftTo(1, x) - } else { - y.subTo(x, y) - y.rShiftTo(1, y) - } - } - if (g > 0) y.lShiftTo(g, y) - return y -} -// (protected) this % n, n < 2^26 -function bnpModInt(n) { - if (n <= 0) return 0 - var d = this.DV % n, - r = (this.s < 0) ? n - 1 : 0 - if (this.t > 0) - if (d == 0) r = this[0] % n - else - for (var i = this.t - 1; i >= 0; --i) r = (d * r + this[i]) % n - return r -} -// (public) 1/this % m (HAC 14.61) -function bnModInverse(m) { - var ac = m.isEven() - if (this.signum() === 0) throw new Error('division by zero') - if ((this.isEven() && ac) || m.signum() == 0) return BigInteger.ZERO - var u = m.clone(), - v = this.clone() - var a = nbv(1), - b = nbv(0), - c = nbv(0), - d = nbv(1) - while (u.signum() != 0) { - while (u.isEven()) { - u.rShiftTo(1, u) - if (ac) { - if (!a.isEven() || !b.isEven()) { - a.addTo(this, a) - b.subTo(m, b) - } - a.rShiftTo(1, a) - } else if (!b.isEven()) b.subTo(m, b) - b.rShiftTo(1, b) - } - while (v.isEven()) { - v.rShiftTo(1, v) - if (ac) { - if (!c.isEven() || !d.isEven()) { - c.addTo(this, c) - d.subTo(m, d) - } - c.rShiftTo(1, c) - } else if (!d.isEven()) d.subTo(m, d) - d.rShiftTo(1, d) - } - if (u.compareTo(v) >= 0) { - u.subTo(v, u) - if (ac) a.subTo(c, a) - b.subTo(d, b) - } else { - v.subTo(u, v) - if (ac) c.subTo(a, c) - d.subTo(b, d) - } - } - if (v.compareTo(BigInteger.ONE) != 0) return BigInteger.ZERO - while (d.compareTo(m) >= 0) d.subTo(m, d) - while (d.signum() < 0) d.addTo(m, d) - return d -} +var ReactReconciler = __webpack_require__(38); -var lowprimes = [ - 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, - 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, - 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, - 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307, 311, 313, 317, - 331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409, 419, - 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, - 509, 521, 523, 541, 547, 557, 563, 569, 571, 577, 587, 593, 599, 601, 607, - 613, 617, 619, 631, 641, 643, 647, 653, 659, 661, 673, 677, 683, 691, 701, - 709, 719, 727, 733, 739, 743, 751, 757, 761, 769, 773, 787, 797, 809, 811, - 821, 823, 827, 829, 839, 853, 857, 859, 863, 877, 881, 883, 887, 907, 911, - 919, 929, 937, 941, 947, 953, 967, 971, 977, 983, 991, 997 -] +var instantiateReactComponent = __webpack_require__(141); +var KeyEscapeUtils = __webpack_require__(89); +var shouldUpdateReactComponent = __webpack_require__(88); +var traverseAllChildren = __webpack_require__(145); +var warning = __webpack_require__(3); -var lplim = (1 << 26) / lowprimes[lowprimes.length - 1] +var ReactComponentTreeHook; -// (public) test primality with certainty >= 1-.5^t -function bnIsProbablePrime(t) { - var i, x = this.abs() - if (x.t == 1 && x[0] <= lowprimes[lowprimes.length - 1]) { - for (i = 0; i < lowprimes.length; ++i) - if (x[0] == lowprimes[i]) return true - return false - } - if (x.isEven()) return false - i = 1 - while (i < lowprimes.length) { - var m = lowprimes[i], - j = i + 1 - while (j < lowprimes.length && m < lplim) m *= lowprimes[j++] - m = x.modInt(m) - while (i < j) if (m % lowprimes[i++] == 0) return false - } - return x.millerRabin(t) +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); } -// (protected) true if probably prime (HAC 4.24, Miller-Rabin) -function bnpMillerRabin(t) { - var n1 = this.subtract(BigInteger.ONE) - var k = n1.getLowestSetBit() - if (k <= 0) return false - var r = n1.shiftRight(k) - t = (t + 1) >> 1 - if (t > lowprimes.length) t = lowprimes.length - var a = new BigInteger(null) - var j, bases = [] - for (var i = 0; i < t; ++i) { - for (;;) { - j = lowprimes[Math.floor(Math.random() * lowprimes.length)] - if (bases.indexOf(j) == -1) break +function instantiateChild(childInstances, child, name, selfDebugID) { + // We found a component instance. + var keyUnique = childInstances[name] === undefined; + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); } - bases.push(j) - a.fromInt(j) - var y = a.modPow(r, this) - if (y.compareTo(BigInteger.ONE) != 0 && y.compareTo(n1) != 0) { - var j = 1 - while (j++ < k && y.compareTo(n1) != 0) { - y = y.modPowInt(2, this) - if (y.compareTo(BigInteger.ONE) == 0) return false - } - if (y.compareTo(n1) != 0) return false + if (!keyUnique) { + process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; } } - return true + if (child != null && keyUnique) { + childInstances[name] = instantiateReactComponent(child, true); + } } -// protected -proto.chunkSize = bnpChunkSize -proto.toRadix = bnpToRadix -proto.fromRadix = bnpFromRadix -proto.fromNumber = bnpFromNumber -proto.bitwiseTo = bnpBitwiseTo -proto.changeBit = bnpChangeBit -proto.addTo = bnpAddTo -proto.dMultiply = bnpDMultiply -proto.dAddOffset = bnpDAddOffset -proto.multiplyLowerTo = bnpMultiplyLowerTo -proto.multiplyUpperTo = bnpMultiplyUpperTo -proto.modInt = bnpModInt -proto.millerRabin = bnpMillerRabin - -// public -proto.clone = bnClone -proto.intValue = bnIntValue -proto.byteValue = bnByteValue -proto.shortValue = bnShortValue -proto.signum = bnSigNum -proto.toByteArray = bnToByteArray -proto.equals = bnEquals -proto.min = bnMin -proto.max = bnMax -proto.and = bnAnd -proto.or = bnOr -proto.xor = bnXor -proto.andNot = bnAndNot -proto.not = bnNot -proto.shiftLeft = bnShiftLeft -proto.shiftRight = bnShiftRight -proto.getLowestSetBit = bnGetLowestSetBit -proto.bitCount = bnBitCount -proto.testBit = bnTestBit -proto.setBit = bnSetBit -proto.clearBit = bnClearBit -proto.flipBit = bnFlipBit -proto.add = bnAdd -proto.subtract = bnSubtract -proto.multiply = bnMultiply -proto.divide = bnDivide -proto.remainder = bnRemainder -proto.divideAndRemainder = bnDivideAndRemainder -proto.modPow = bnModPow -proto.modInverse = bnModInverse -proto.pow = bnPow -proto.gcd = bnGCD -proto.isProbablePrime = bnIsProbablePrime - -// JSBN-specific extension -proto.square = bnSquare - -// constants -BigInteger.ZERO = nbv(0) -BigInteger.ONE = nbv(1) -BigInteger.valueOf = nbv - -module.exports = BigInteger - +/** + * ReactChildReconciler provides helpers for initializing or updating a set of + * children. Its output is suitable for passing it onto ReactMultiChild which + * does diffed reordering and insertion. + */ +var ReactChildReconciler = { + /** + * Generates a "mount image" for each of the supplied children. In the case + * of `ReactDOMComponent`, a mount image is a string of markup. + * + * @param {?object} nestedChildNodes Nested child maps. + * @return {?object} A set of child instances. + * @internal + */ + instantiateChildren: function (nestedChildNodes, transaction, context, selfDebugID) // 0 in production and for roots + { + if (nestedChildNodes == null) { + return null; + } + var childInstances = {}; -/***/ }), -/* 322 */ -/***/ (function(module, exports) { + if (process.env.NODE_ENV !== 'production') { + traverseAllChildren(nestedChildNodes, function (childInsts, child, name) { + return instantiateChild(childInsts, child, name, selfDebugID); + }, childInstances); + } else { + traverseAllChildren(nestedChildNodes, instantiateChild, childInstances); + } + return childInstances; + }, -module.exports = { - "sha224WithRSAEncryption": { - "sign": "rsa", - "hash": "sha224", - "id": "302d300d06096086480165030402040500041c" - }, - "RSA-SHA224": { - "sign": "ecdsa/rsa", - "hash": "sha224", - "id": "302d300d06096086480165030402040500041c" - }, - "sha256WithRSAEncryption": { - "sign": "rsa", - "hash": "sha256", - "id": "3031300d060960864801650304020105000420" - }, - "RSA-SHA256": { - "sign": "ecdsa/rsa", - "hash": "sha256", - "id": "3031300d060960864801650304020105000420" - }, - "sha384WithRSAEncryption": { - "sign": "rsa", - "hash": "sha384", - "id": "3041300d060960864801650304020205000430" - }, - "RSA-SHA384": { - "sign": "ecdsa/rsa", - "hash": "sha384", - "id": "3041300d060960864801650304020205000430" - }, - "sha512WithRSAEncryption": { - "sign": "rsa", - "hash": "sha512", - "id": "3051300d060960864801650304020305000440" - }, - "RSA-SHA512": { - "sign": "ecdsa/rsa", - "hash": "sha512", - "id": "3051300d060960864801650304020305000440" - }, - "RSA-SHA1": { - "sign": "rsa", - "hash": "sha1", - "id": "3021300906052b0e03021a05000414" - }, - "ecdsa-with-SHA1": { - "sign": "ecdsa", - "hash": "sha1", - "id": "" - }, - "sha256": { - "sign": "ecdsa", - "hash": "sha256", - "id": "" - }, - "sha224": { - "sign": "ecdsa", - "hash": "sha224", - "id": "" - }, - "sha384": { - "sign": "ecdsa", - "hash": "sha384", - "id": "" - }, - "sha512": { - "sign": "ecdsa", - "hash": "sha512", - "id": "" - }, - "DSA-SHA": { - "sign": "dsa", - "hash": "sha1", - "id": "" - }, - "DSA-SHA1": { - "sign": "dsa", - "hash": "sha1", - "id": "" - }, - "DSA": { - "sign": "dsa", - "hash": "sha1", - "id": "" - }, - "DSA-WITH-SHA224": { - "sign": "dsa", - "hash": "sha224", - "id": "" - }, - "DSA-SHA224": { - "sign": "dsa", - "hash": "sha224", - "id": "" - }, - "DSA-WITH-SHA256": { - "sign": "dsa", - "hash": "sha256", - "id": "" - }, - "DSA-SHA256": { - "sign": "dsa", - "hash": "sha256", - "id": "" - }, - "DSA-WITH-SHA384": { - "sign": "dsa", - "hash": "sha384", - "id": "" - }, - "DSA-SHA384": { - "sign": "dsa", - "hash": "sha384", - "id": "" - }, - "DSA-WITH-SHA512": { - "sign": "dsa", - "hash": "sha512", - "id": "" - }, - "DSA-SHA512": { - "sign": "dsa", - "hash": "sha512", - "id": "" - }, - "DSA-RIPEMD160": { - "sign": "dsa", - "hash": "rmd160", - "id": "" - }, - "ripemd160WithRSA": { - "sign": "rsa", - "hash": "rmd160", - "id": "3021300906052b2403020105000414" - }, - "RSA-RIPEMD160": { - "sign": "rsa", - "hash": "rmd160", - "id": "3021300906052b2403020105000414" - }, - "md5WithRSAEncryption": { - "sign": "rsa", - "hash": "md5", - "id": "3020300c06082a864886f70d020505000410" - }, - "RSA-MD5": { - "sign": "rsa", - "hash": "md5", - "id": "3020300c06082a864886f70d020505000410" - } + /** + * Updates the rendered children and returns a new set of children. + * + * @param {?object} prevChildren Previously initialized set of children. + * @param {?object} nextChildren Flat child element maps. + * @param {ReactReconcileTransaction} transaction + * @param {object} context + * @return {?object} A new set of child instances. + * @internal + */ + updateChildren: function (prevChildren, nextChildren, mountImages, removedNodes, transaction, hostParent, hostContainerInfo, context, selfDebugID) // 0 in production and for roots + { + // We currently don't have a way to track moves here but if we use iterators + // instead of for..in we can zip the iterators and check if an item has + // moved. + // TODO: If nothing has changed, return the prevChildren object so that we + // can quickly bailout if nothing has changed. + if (!nextChildren && !prevChildren) { + return; + } + var name; + var prevChild; + for (name in nextChildren) { + if (!nextChildren.hasOwnProperty(name)) { + continue; + } + prevChild = prevChildren && prevChildren[name]; + var prevElement = prevChild && prevChild._currentElement; + var nextElement = nextChildren[name]; + if (prevChild != null && shouldUpdateReactComponent(prevElement, nextElement)) { + ReactReconciler.receiveComponent(prevChild, nextElement, transaction, context); + nextChildren[name] = prevChild; + } else { + if (prevChild) { + removedNodes[name] = ReactReconciler.getHostNode(prevChild); + ReactReconciler.unmountComponent(prevChild, false); + } + // The child must be instantiated before it's mounted. + var nextChildInstance = instantiateReactComponent(nextElement, true); + nextChildren[name] = nextChildInstance; + // Creating mount image now ensures refs are resolved in right order + // (see https://github.com/facebook/react/pull/7101 for explanation). + var nextChildMountImage = ReactReconciler.mountComponent(nextChildInstance, transaction, hostParent, hostContainerInfo, context, selfDebugID); + mountImages.push(nextChildMountImage); + } + } + // Unmount children that are no longer present. + for (name in prevChildren) { + if (prevChildren.hasOwnProperty(name) && !(nextChildren && nextChildren.hasOwnProperty(name))) { + prevChild = prevChildren[name]; + removedNodes[name] = ReactReconciler.getHostNode(prevChild); + ReactReconciler.unmountComponent(prevChild, false); + } + } + }, + + /** + * Unmounts all rendered children. This should be used to clean up children + * when this component is unmounted. + * + * @param {?object} renderedChildren Previously initialized set of children. + * @internal + */ + unmountChildren: function (renderedChildren, safely) { + for (var name in renderedChildren) { + if (renderedChildren.hasOwnProperty(name)) { + var renderedChild = renderedChildren[name]; + ReactReconciler.unmountComponent(renderedChild, safely); + } + } + } }; +module.exports = ReactChildReconciler; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + /***/ }), -/* 323 */ +/* 271 */ /***/ (function(module, exports, __webpack_require__) { +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + -exports.pbkdf2 = __webpack_require__(482) -exports.pbkdf2Sync = __webpack_require__(326) +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); +var React = __webpack_require__(36); +var ReactComponentEnvironment = __webpack_require__(86); +var ReactCurrentOwner = __webpack_require__(22); +var ReactErrorUtils = __webpack_require__(78); +var ReactInstanceMap = __webpack_require__(48); +var ReactInstrumentation = __webpack_require__(19); +var ReactNodeTypes = __webpack_require__(142); +var ReactReconciler = __webpack_require__(38); -/***/ }), -/* 324 */ -/***/ (function(module, exports) { +if (process.env.NODE_ENV !== 'production') { + var checkReactTypeSpec = __webpack_require__(272); +} -var MAX_ALLOC = Math.pow(2, 30) - 1 // default in iojs -module.exports = function (iterations, keylen) { - if (typeof iterations !== 'number') { - throw new TypeError('Iterations not a number') - } +var emptyObject = __webpack_require__(56); +var invariant = __webpack_require__(2); +var shallowEqual = __webpack_require__(87); +var shouldUpdateReactComponent = __webpack_require__(88); +var warning = __webpack_require__(3); - if (iterations < 0) { - throw new TypeError('Bad iterations') +var CompositeTypes = { + ImpureClass: 0, + PureClass: 1, + StatelessFunctional: 2 +}; + +function StatelessComponent(Component) {} +StatelessComponent.prototype.render = function () { + var Component = ReactInstanceMap.get(this)._currentElement.type; + var element = Component(this.props, this.context, this.updater); + warnIfInvalidElement(Component, element); + return element; +}; + +function warnIfInvalidElement(Component, element) { + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(element === null || element === false || React.isValidElement(element), '%s(...): A valid React element (or null) must be returned. You may have ' + 'returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!Component.childContextTypes, '%s(...): childContextTypes cannot be defined on a functional component.', Component.displayName || Component.name || 'Component') : void 0; } +} - if (typeof keylen !== 'number') { - throw new TypeError('Key length not a number') +function shouldConstruct(Component) { + return !!(Component.prototype && Component.prototype.isReactComponent); +} + +function isPureComponent(Component) { + return !!(Component.prototype && Component.prototype.isPureReactComponent); +} + +// Separated into a function to contain deoptimizations caused by try/finally. +function measureLifeCyclePerf(fn, debugID, timerType) { + if (debugID === 0) { + // Top-level wrappers (see ReactMount) and empty components (see + // ReactDOMEmptyComponent) are invisible to hooks and devtools. + // Both are implementation details that should go away in the future. + return fn(); } - if (keylen < 0 || keylen > MAX_ALLOC || keylen !== keylen) { /* eslint no-self-compare: 0 */ - throw new TypeError('Bad key length') + ReactInstrumentation.debugTool.onBeginLifeCycleTimer(debugID, timerType); + try { + return fn(); + } finally { + ReactInstrumentation.debugTool.onEndLifeCycleTimer(debugID, timerType); } } +/** + * ------------------ The Life-Cycle of a Composite Component ------------------ + * + * - constructor: Initialization of state. The instance is now retained. + * - componentWillMount + * - render + * - [children's constructors] + * - [children's componentWillMount and render] + * - [children's componentDidMount] + * - componentDidMount + * + * Update Phases: + * - componentWillReceiveProps (only called if parent updated) + * - shouldComponentUpdate + * - componentWillUpdate + * - render + * - [children's constructors or receive props phases] + * - componentDidUpdate + * + * - componentWillUnmount + * - [children's componentWillUnmount] + * - [children destroyed] + * - (destroyed): The instance is now blank, released by React and ready for GC. + * + * ----------------------------------------------------------------------------- + */ -/***/ }), -/* 325 */ -/***/ (function(module, exports, __webpack_require__) { +/** + * An incrementing ID assigned to each component when it is mounted. This is + * used to enforce the order in which `ReactUpdates` updates dirty components. + * + * @private + */ +var nextMountID = 1; -/* WEBPACK VAR INJECTION */(function(process) {var defaultEncoding -/* istanbul ignore next */ -if (process.browser) { - defaultEncoding = 'utf-8' -} else { - var pVersionMajor = parseInt(process.version.split('.')[0].slice(1), 10) +/** + * @lends {ReactCompositeComponent.prototype} + */ +var ReactCompositeComponent = { + /** + * Base constructor for all composite component. + * + * @param {ReactElement} element + * @final + * @internal + */ + construct: function (element) { + this._currentElement = element; + this._rootNodeID = 0; + this._compositeType = null; + this._instance = null; + this._hostParent = null; + this._hostContainerInfo = null; - defaultEncoding = pVersionMajor >= 6 ? 'utf-8' : 'binary' -} -module.exports = defaultEncoding + // See ReactUpdateQueue + this._updateBatchNumber = null; + this._pendingElement = null; + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) + this._renderedNodeType = null; + this._renderedComponent = null; + this._context = null; + this._mountOrder = 0; + this._topLevelWrapper = null; -/***/ }), -/* 326 */ -/***/ (function(module, exports, __webpack_require__) { + // See ReactUpdates and ReactUpdateQueue. + this._pendingCallbacks = null; -var md5 = __webpack_require__(245) -var rmd160 = __webpack_require__(260) -var sha = __webpack_require__(265) + // ComponentWillUnmount shall only be called once + this._calledComponentWillUnmount = false; -var checkParameters = __webpack_require__(324) -var defaultEncoding = __webpack_require__(325) -var Buffer = __webpack_require__(18).Buffer -var ZEROS = Buffer.alloc(128) -var sizes = { - md5: 16, - sha1: 20, - sha224: 28, - sha256: 32, - sha384: 48, - sha512: 64, - rmd160: 20, - ripemd160: 20 -} -function Hmac (alg, key, saltLen) { - var hash = getDigest(alg) - var blocksize = (alg === 'sha512' || alg === 'sha384') ? 128 : 64 + if (process.env.NODE_ENV !== 'production') { + this._warnedAboutRefsInRender = false; + } + }, - if (key.length > blocksize) { - key = hash(key) - } else if (key.length < blocksize) { - key = Buffer.concat([key, ZEROS], blocksize) - } + /** + * Initializes the component, renders markup, and registers event listeners. + * + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @param {?object} hostParent + * @param {?object} hostContainerInfo + * @param {?object} context + * @return {?string} Rendered markup to be inserted into the DOM. + * @final + * @internal + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + var _this = this; - var ipad = Buffer.allocUnsafe(blocksize + sizes[alg]) - var opad = Buffer.allocUnsafe(blocksize + sizes[alg]) - for (var i = 0; i < blocksize; i++) { - ipad[i] = key[i] ^ 0x36 - opad[i] = key[i] ^ 0x5C - } + this._context = context; + this._mountOrder = nextMountID++; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; - var ipad1 = Buffer.allocUnsafe(blocksize + saltLen + 4) - ipad.copy(ipad1, 0, 0, blocksize) - this.ipad1 = ipad1 - this.ipad2 = ipad - this.opad = opad - this.alg = alg - this.blocksize = blocksize - this.hash = hash - this.size = sizes[alg] -} + var publicProps = this._currentElement.props; + var publicContext = this._processContext(context); -Hmac.prototype.run = function (data, ipad) { - data.copy(ipad, this.blocksize) - var h = this.hash(ipad) - h.copy(this.opad, this.blocksize) - return this.hash(this.opad) -} + var Component = this._currentElement.type; -function getDigest (alg) { - if (alg === 'rmd160' || alg === 'ripemd160') return rmd160 - if (alg === 'md5') return md5 - return shaFunc + var updateQueue = transaction.getUpdateQueue(); - function shaFunc (data) { - return sha(alg).update(data).digest() - } -} + // Initialize the public class + var doConstruct = shouldConstruct(Component); + var inst = this._constructComponent(doConstruct, publicProps, publicContext, updateQueue); + var renderedElement; -module.exports = function (password, salt, iterations, keylen, digest) { - if (!Buffer.isBuffer(password)) password = Buffer.from(password, defaultEncoding) - if (!Buffer.isBuffer(salt)) salt = Buffer.from(salt, defaultEncoding) + // Support functional components + if (!doConstruct && (inst == null || inst.render == null)) { + renderedElement = inst; + warnIfInvalidElement(Component, renderedElement); + !(inst === null || inst === false || React.isValidElement(inst)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s(...): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', Component.displayName || Component.name || 'Component') : _prodInvariant('105', Component.displayName || Component.name || 'Component') : void 0; + inst = new StatelessComponent(Component); + this._compositeType = CompositeTypes.StatelessFunctional; + } else { + if (isPureComponent(Component)) { + this._compositeType = CompositeTypes.PureClass; + } else { + this._compositeType = CompositeTypes.ImpureClass; + } + } - checkParameters(iterations, keylen) + if (process.env.NODE_ENV !== 'production') { + // This will throw later in _renderValidatedComponent, but add an early + // warning now to help debugging + if (inst.render == null) { + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): No `render` method found on the returned component ' + 'instance: you may have forgotten to define `render`.', Component.displayName || Component.name || 'Component') : void 0; + } - digest = digest || 'sha1' + var propsMutated = inst.props !== publicProps; + var componentName = Component.displayName || Component.name || 'Component'; - var hmac = new Hmac(digest, password, salt.length) + process.env.NODE_ENV !== 'production' ? warning(inst.props === undefined || !propsMutated, '%s(...): When calling super() in `%s`, make sure to pass ' + "up the same props that your component's constructor was passed.", componentName, componentName) : void 0; + } - var DK = Buffer.allocUnsafe(keylen) - var block1 = Buffer.allocUnsafe(salt.length + 4) - salt.copy(block1, 0, 0, salt.length) + // These should be set up in the constructor, but as a convenience for + // simpler class abstractions, we set them up after the fact. + inst.props = publicProps; + inst.context = publicContext; + inst.refs = emptyObject; + inst.updater = updateQueue; - var U, j, destPos, len + this._instance = inst; - var hLen = hmac.size - var T = Buffer.allocUnsafe(hLen) - var l = Math.ceil(keylen / hLen) - var r = keylen - (l - 1) * hLen + // Store a reference from the instance back to the internal representation + ReactInstanceMap.set(inst, this); - for (var i = 1; i <= l; i++) { - block1.writeUInt32BE(i, salt.length) - U = hmac.run(block1, hmac.ipad1) + if (process.env.NODE_ENV !== 'production') { + // Since plain JS classes are defined without any special initialization + // logic, we can not catch common errors early. Therefore, we have to + // catch them here, at initialization time, instead. + process.env.NODE_ENV !== 'production' ? warning(!inst.getInitialState || inst.getInitialState.isReactClassApproved || inst.state, 'getInitialState was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Did you mean to define a state property instead?', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.getDefaultProps || inst.getDefaultProps.isReactClassApproved, 'getDefaultProps was defined on %s, a plain JavaScript class. ' + 'This is only supported for classes created using React.createClass. ' + 'Use a static property to define defaultProps instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.propTypes, 'propTypes was defined as an instance property on %s. Use a static ' + 'property to define propTypes instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(!inst.contextTypes, 'contextTypes was defined as an instance property on %s. Use a ' + 'static property to define contextTypes instead.', this.getName() || 'a component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentShouldUpdate !== 'function', '%s has a method called ' + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + 'The name is phrased as a question because the function is ' + 'expected to return a value.', this.getName() || 'A component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentDidUnmount !== 'function', '%s has a method called ' + 'componentDidUnmount(). But there is no such lifecycle method. ' + 'Did you mean componentWillUnmount()?', this.getName() || 'A component') : void 0; + process.env.NODE_ENV !== 'production' ? warning(typeof inst.componentWillRecieveProps !== 'function', '%s has a method called ' + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', this.getName() || 'A component') : void 0; + } - U.copy(T, 0, 0, hLen) + var initialState = inst.state; + if (initialState === undefined) { + inst.state = initialState = null; + } + !(typeof initialState === 'object' && !Array.isArray(initialState)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.state: must be set to an object or null', this.getName() || 'ReactCompositeComponent') : _prodInvariant('106', this.getName() || 'ReactCompositeComponent') : void 0; - for (j = 1; j < iterations; j++) { - U = hmac.run(U, hmac.ipad2) - for (var k = 0; k < hLen; k++) T[k] ^= U[k] + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; + + var markup; + if (inst.unstable_handleError) { + markup = this.performInitialMountWithErrorHandling(renderedElement, hostParent, hostContainerInfo, transaction, context); + } else { + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); } - destPos = (i - 1) * hLen - len = (i === l ? r : hLen) - T.copy(DK, destPos, 0, len) - } + if (inst.componentDidMount) { + if (process.env.NODE_ENV !== 'production') { + transaction.getReactMountReady().enqueue(function () { + measureLifeCyclePerf(function () { + return inst.componentDidMount(); + }, _this._debugID, 'componentDidMount'); + }); + } else { + transaction.getReactMountReady().enqueue(inst.componentDidMount, inst); + } + } - return DK -} + return markup; + }, + _constructComponent: function (doConstruct, publicProps, publicContext, updateQueue) { + if (process.env.NODE_ENV !== 'production') { + ReactCurrentOwner.current = this; + try { + return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); + } finally { + ReactCurrentOwner.current = null; + } + } else { + return this._constructComponentWithoutOwner(doConstruct, publicProps, publicContext, updateQueue); + } + }, -/***/ }), -/* 327 */ -/***/ (function(module, exports, __webpack_require__) { + _constructComponentWithoutOwner: function (doConstruct, publicProps, publicContext, updateQueue) { + var Component = this._currentElement.type; -/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(251) -var Transform = __webpack_require__(109) -var inherits = __webpack_require__(11) + if (doConstruct) { + if (process.env.NODE_ENV !== 'production') { + return measureLifeCyclePerf(function () { + return new Component(publicProps, publicContext, updateQueue); + }, this._debugID, 'ctor'); + } else { + return new Component(publicProps, publicContext, updateQueue); + } + } -inherits(StreamCipher, Transform) -module.exports = StreamCipher -function StreamCipher (mode, key, iv, decrypt) { - if (!(this instanceof StreamCipher)) { - return new StreamCipher(mode, key, iv) - } - Transform.call(this) - this._cipher = new aes.AES(key) - this._prev = new Buffer(iv.length) - this._cache = new Buffer('') - this._secCache = new Buffer('') - this._decrypt = decrypt - iv.copy(this._prev) - this._mode = mode -} -StreamCipher.prototype._update = function (chunk) { - return this._mode.encrypt(this, chunk, this._decrypt) -} -StreamCipher.prototype._final = function () { - this._cipher.scrub() -} + // This can still be an instance in case of factory components + // but we'll count this as time spent rendering as the more common case. + if (process.env.NODE_ENV !== 'production') { + return measureLifeCyclePerf(function () { + return Component(publicProps, publicContext, updateQueue); + }, this._debugID, 'render'); + } else { + return Component(publicProps, publicContext, updateQueue); + } + }, -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + performInitialMountWithErrorHandling: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { + var markup; + var checkpoint = transaction.checkpoint(); + try { + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); + } catch (e) { + // Roll back to checkpoint, handle error (which may add items to the transaction), and take a new checkpoint + transaction.rollback(checkpoint); + this._instance.unstable_handleError(e); + if (this._pendingStateQueue) { + this._instance.state = this._processPendingState(this._instance.props, this._instance.context); + } + checkpoint = transaction.checkpoint(); -/***/ }), -/* 328 */ -/***/ (function(module, exports, __webpack_require__) { + this._renderedComponent.unmountComponent(true); + transaction.rollback(checkpoint); -/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(251) -var Transform = __webpack_require__(109) -var inherits = __webpack_require__(11) -var GHASH = __webpack_require__(485) -var xor = __webpack_require__(239) -inherits(StreamCipher, Transform) -module.exports = StreamCipher + // Try again - we've informed the component about the error, so they can render an error message this time. + // If this throws again, the error will bubble up (and can be caught by a higher error boundary). + markup = this.performInitialMount(renderedElement, hostParent, hostContainerInfo, transaction, context); + } + return markup; + }, -function StreamCipher (mode, key, iv, decrypt) { - if (!(this instanceof StreamCipher)) { - return new StreamCipher(mode, key, iv) - } - Transform.call(this) - this._finID = Buffer.concat([iv, new Buffer([0, 0, 0, 1])]) - iv = Buffer.concat([iv, new Buffer([0, 0, 0, 2])]) - this._cipher = new aes.AES(key) - this._prev = new Buffer(iv.length) - this._cache = new Buffer('') - this._secCache = new Buffer('') - this._decrypt = decrypt - this._alen = 0 - this._len = 0 - iv.copy(this._prev) - this._mode = mode - var h = new Buffer(4) - h.fill(0) - this._ghash = new GHASH(this._cipher.encryptBlock(h)) - this._authTag = null - this._called = false -} -StreamCipher.prototype._update = function (chunk) { - if (!this._called && this._alen) { - var rump = 16 - (this._alen % 16) - if (rump < 16) { - rump = new Buffer(rump) - rump.fill(0) - this._ghash.update(rump) + performInitialMount: function (renderedElement, hostParent, hostContainerInfo, transaction, context) { + var inst = this._instance; + + var debugID = 0; + if (process.env.NODE_ENV !== 'production') { + debugID = this._debugID; } - } - this._called = true - var out = this._mode.encrypt(this, chunk) - if (this._decrypt) { - this._ghash.update(chunk) - } else { - this._ghash.update(out) - } - this._len += chunk.length - return out -} -StreamCipher.prototype._final = function () { - if (this._decrypt && !this._authTag) { - throw new Error('Unsupported state or unable to authenticate data') - } - var tag = xor(this._ghash.final(this._alen * 8, this._len * 8), this._cipher.encryptBlock(this._finID)) - if (this._decrypt) { - if (xorTest(tag, this._authTag)) { - throw new Error('Unsupported state or unable to authenticate data') + + if (inst.componentWillMount) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillMount(); + }, debugID, 'componentWillMount'); + } else { + inst.componentWillMount(); + } + // When mounting, calls to `setState` by `componentWillMount` will set + // `this._pendingStateQueue` without triggering a re-render. + if (this._pendingStateQueue) { + inst.state = this._processPendingState(inst.props, inst.context); + } } - } else { - this._authTag = tag - } - this._cipher.scrub() -} -StreamCipher.prototype.getAuthTag = function getAuthTag () { - if (!this._decrypt && Buffer.isBuffer(this._authTag)) { - return this._authTag - } else { - throw new Error('Attempting to get auth tag in unsupported state') - } -} -StreamCipher.prototype.setAuthTag = function setAuthTag (tag) { - if (this._decrypt) { - this._authTag = tag - } else { - throw new Error('Attempting to set auth tag in unsupported state') - } -} -StreamCipher.prototype.setAAD = function setAAD (buf) { - if (!this._called) { - this._ghash.update(buf) - this._alen += buf.length - } else { - throw new Error('Attempting to set AAD in unsupported state') - } -} -function xorTest (a, b) { - var out = 0 - if (a.length !== b.length) { - out++ - } - var len = Math.min(a.length, b.length) - var i = -1 - while (++i < len) { - out += (a[i] ^ b[i]) - } - return out -} -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + // If not a stateless component, we now render + if (renderedElement === undefined) { + renderedElement = this._renderValidatedComponent(); + } -/***/ }), -/* 329 */ -/***/ (function(module, exports) { + var nodeType = ReactNodeTypes.getType(renderedElement); + this._renderedNodeType = nodeType; + var child = this._instantiateReactComponent(renderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ + ); + this._renderedComponent = child; -exports.encrypt = function (self, block) { - return self._cipher.encryptBlock(block) -} -exports.decrypt = function (self, block) { - return self._cipher.decryptBlock(block) -} + var markup = ReactReconciler.mountComponent(child, transaction, hostParent, hostContainerInfo, this._processChildContext(context), debugID); + if (process.env.NODE_ENV !== 'production') { + if (debugID !== 0) { + var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; + ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); + } + } -/***/ }), -/* 330 */ -/***/ (function(module, exports, __webpack_require__) { + return markup; + }, -var xor = __webpack_require__(239) + getHostNode: function () { + return ReactReconciler.getHostNode(this._renderedComponent); + }, -exports.encrypt = function (self, block) { - var data = xor(block, self._prev) + /** + * Releases any resources allocated by `mountComponent`. + * + * @final + * @internal + */ + unmountComponent: function (safely) { + if (!this._renderedComponent) { + return; + } - self._prev = self._cipher.encryptBlock(data) - return self._prev -} + var inst = this._instance; -exports.decrypt = function (self, block) { - var pad = self._prev + if (inst.componentWillUnmount && !inst._calledComponentWillUnmount) { + inst._calledComponentWillUnmount = true; - self._prev = block - var out = self._cipher.decryptBlock(block) + if (safely) { + var name = this.getName() + '.componentWillUnmount()'; + ReactErrorUtils.invokeGuardedCallback(name, inst.componentWillUnmount.bind(inst)); + } else { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillUnmount(); + }, this._debugID, 'componentWillUnmount'); + } else { + inst.componentWillUnmount(); + } + } + } - return xor(out, pad) -} + if (this._renderedComponent) { + ReactReconciler.unmountComponent(this._renderedComponent, safely); + this._renderedNodeType = null; + this._renderedComponent = null; + this._instance = null; + } + // Reset pending fields + // Even if this component is scheduled for another update in ReactUpdates, + // it would still be ignored because these fields are reset. + this._pendingStateQueue = null; + this._pendingReplaceState = false; + this._pendingForceUpdate = false; + this._pendingCallbacks = null; + this._pendingElement = null; -/***/ }), -/* 331 */ -/***/ (function(module, exports, __webpack_require__) { + // These fields do not really need to be reset since this object is no + // longer accessible. + this._context = null; + this._rootNodeID = 0; + this._topLevelWrapper = null; -/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(239) + // Delete the reference from the instance to this internal representation + // which allow the internals to be properly cleaned up even if the user + // leaks a reference to the public instance. + ReactInstanceMap.remove(inst); -exports.encrypt = function (self, data, decrypt) { - var out = new Buffer('') - var len + // Some existing components rely on inst.props even after they've been + // destroyed (in event handlers). + // TODO: inst.props = null; + // TODO: inst.state = null; + // TODO: inst.context = null; + }, - while (data.length) { - if (self._cache.length === 0) { - self._cache = self._cipher.encryptBlock(self._prev) - self._prev = new Buffer('') + /** + * Filters the context object to only contain keys specified in + * `contextTypes` + * + * @param {object} context + * @return {?object} + * @private + */ + _maskContext: function (context) { + var Component = this._currentElement.type; + var contextTypes = Component.contextTypes; + if (!contextTypes) { + return emptyObject; + } + var maskedContext = {}; + for (var contextName in contextTypes) { + maskedContext[contextName] = context[contextName]; } + return maskedContext; + }, - if (self._cache.length <= data.length) { - len = self._cache.length - out = Buffer.concat([out, encryptStart(self, data.slice(0, len), decrypt)]) - data = data.slice(len) - } else { - out = Buffer.concat([out, encryptStart(self, data, decrypt)]) - break + /** + * Filters the context object to only contain keys specified in + * `contextTypes`, and asserts that they are valid. + * + * @param {object} context + * @return {?object} + * @private + */ + _processContext: function (context) { + var maskedContext = this._maskContext(context); + if (process.env.NODE_ENV !== 'production') { + var Component = this._currentElement.type; + if (Component.contextTypes) { + this._checkContextTypes(Component.contextTypes, maskedContext, 'context'); + } } - } + return maskedContext; + }, - return out -} -function encryptStart (self, data, decrypt) { - var len = data.length - var out = xor(data, self._cache) - self._cache = self._cache.slice(len) - self._prev = Buffer.concat([self._prev, decrypt ? data : out]) - return out -} + /** + * @param {object} currentContext + * @return {object} + * @private + */ + _processChildContext: function (currentContext) { + var Component = this._currentElement.type; + var inst = this._instance; + var childContext; + + if (inst.getChildContext) { + if (process.env.NODE_ENV !== 'production') { + ReactInstrumentation.debugTool.onBeginProcessingChildContext(); + try { + childContext = inst.getChildContext(); + } finally { + ReactInstrumentation.debugTool.onEndProcessingChildContext(); + } + } else { + childContext = inst.getChildContext(); + } + } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + if (childContext) { + !(typeof Component.childContextTypes === 'object') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().', this.getName() || 'ReactCompositeComponent') : _prodInvariant('107', this.getName() || 'ReactCompositeComponent') : void 0; + if (process.env.NODE_ENV !== 'production') { + this._checkContextTypes(Component.childContextTypes, childContext, 'child context'); + } + for (var name in childContext) { + !(name in Component.childContextTypes) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.getChildContext(): key "%s" is not defined in childContextTypes.', this.getName() || 'ReactCompositeComponent', name) : _prodInvariant('108', this.getName() || 'ReactCompositeComponent', name) : void 0; + } + return _assign({}, currentContext, childContext); + } + return currentContext; + }, -/***/ }), -/* 332 */ -/***/ (function(module, exports, __webpack_require__) { + /** + * Assert that the context types are valid + * + * @param {object} typeSpecs Map of context field to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @private + */ + _checkContextTypes: function (typeSpecs, values, location) { + if (process.env.NODE_ENV !== 'production') { + checkReactTypeSpec(typeSpecs, values, location, this.getName(), null, this._debugID); + } + }, -/* WEBPACK VAR INJECTION */(function(Buffer) {function encryptByte (self, byteParam, decrypt) { - var pad = self._cipher.encryptBlock(self._prev) - var out = pad[0] ^ byteParam - self._prev = Buffer.concat([self._prev.slice(1), new Buffer([decrypt ? byteParam : out])]) - return out -} -exports.encrypt = function (self, chunk, decrypt) { - var len = chunk.length - var out = new Buffer(len) - var i = -1 - while (++i < len) { - out[i] = encryptByte(self, chunk[i], decrypt) - } - return out -} + receiveComponent: function (nextElement, transaction, nextContext) { + var prevElement = this._currentElement; + var prevContext = this._context; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + this._pendingElement = null; -/***/ }), -/* 333 */ -/***/ (function(module, exports, __webpack_require__) { + this.updateComponent(transaction, prevElement, nextElement, prevContext, nextContext); + }, -/* WEBPACK VAR INJECTION */(function(Buffer) {function encryptByte (self, byteParam, decrypt) { - var pad - var i = -1 - var len = 8 - var out = 0 - var bit, value - while (++i < len) { - pad = self._cipher.encryptBlock(self._prev) - bit = (byteParam & (1 << (7 - i))) ? 0x80 : 0 - value = pad[0] ^ bit - out += ((value & 0x80) >> (i % 8)) - self._prev = shiftIn(self._prev, decrypt ? bit : value) - } - return out -} -exports.encrypt = function (self, chunk, decrypt) { - var len = chunk.length - var out = new Buffer(len) - var i = -1 - while (++i < len) { - out[i] = encryptByte(self, chunk[i], decrypt) - } - return out -} -function shiftIn (buffer, value) { - var len = buffer.length - var i = -1 - var out = new Buffer(buffer.length) - buffer = Buffer.concat([buffer, new Buffer([value])]) - while (++i < len) { - out[i] = buffer[i] << 1 | buffer[i + 1] >> (7) - } - return out -} + /** + * If any of `_pendingElement`, `_pendingStateQueue`, or `_pendingForceUpdate` + * is set, update the component. + * + * @param {ReactReconcileTransaction} transaction + * @internal + */ + performUpdateIfNecessary: function (transaction) { + if (this._pendingElement != null) { + ReactReconciler.receiveComponent(this, this._pendingElement, transaction, this._context); + } else if (this._pendingStateQueue !== null || this._pendingForceUpdate) { + this.updateComponent(transaction, this._currentElement, this._currentElement, this._context, this._context); + } else { + this._updateBatchNumber = null; + } + }, -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + /** + * Perform an update to a mounted component. The componentWillReceiveProps and + * shouldComponentUpdate methods are called, then (assuming the update isn't + * skipped) the remaining update lifecycle methods are called and the DOM + * representation is updated. + * + * By default, this implements React's rendering and reconciliation algorithm. + * Sophisticated clients may wish to override this. + * + * @param {ReactReconcileTransaction} transaction + * @param {ReactElement} prevParentElement + * @param {ReactElement} nextParentElement + * @internal + * @overridable + */ + updateComponent: function (transaction, prevParentElement, nextParentElement, prevUnmaskedContext, nextUnmaskedContext) { + var inst = this._instance; + !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Attempted to update component `%s` that has already been unmounted (or failed to mount).', this.getName() || 'ReactCompositeComponent') : _prodInvariant('136', this.getName() || 'ReactCompositeComponent') : void 0; -/***/ }), -/* 334 */ -/***/ (function(module, exports, __webpack_require__) { + var willReceive = false; + var nextContext; -/* WEBPACK VAR INJECTION */(function(Buffer) {var xor = __webpack_require__(239) + // Determine if the context has changed or not + if (this._context === nextUnmaskedContext) { + nextContext = inst.context; + } else { + nextContext = this._processContext(nextUnmaskedContext); + willReceive = true; + } -function getBlock (self) { - self._prev = self._cipher.encryptBlock(self._prev) - return self._prev -} + var prevProps = prevParentElement.props; + var nextProps = nextParentElement.props; -exports.encrypt = function (self, chunk) { - while (self._cache.length < chunk.length) { - self._cache = Buffer.concat([self._cache, getBlock(self)]) - } + // Not a simple state update but a props update + if (prevParentElement !== nextParentElement) { + willReceive = true; + } - var pad = self._cache.slice(0, chunk.length) - self._cache = self._cache.slice(chunk.length) - return xor(chunk, pad) -} + // An update here will schedule an update but immediately set + // _pendingStateQueue which will ensure that any state updates gets + // immediately reconciled instead of waiting for the next batch. + if (willReceive && inst.componentWillReceiveProps) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillReceiveProps(nextProps, nextContext); + }, this._debugID, 'componentWillReceiveProps'); + } else { + inst.componentWillReceiveProps(nextProps, nextContext); + } + } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) + var nextState = this._processPendingState(nextProps, nextContext); + var shouldUpdate = true; -/***/ }), -/* 335 */ -/***/ (function(module, exports, __webpack_require__) { + if (!this._pendingForceUpdate) { + if (inst.shouldComponentUpdate) { + if (process.env.NODE_ENV !== 'production') { + shouldUpdate = measureLifeCyclePerf(function () { + return inst.shouldComponentUpdate(nextProps, nextState, nextContext); + }, this._debugID, 'shouldComponentUpdate'); + } else { + shouldUpdate = inst.shouldComponentUpdate(nextProps, nextState, nextContext); + } + } else { + if (this._compositeType === CompositeTypes.PureClass) { + shouldUpdate = !shallowEqual(prevProps, nextProps) || !shallowEqual(inst.state, nextState); + } + } + } -var randomBytes = __webpack_require__(115); -module.exports = findPrime; -findPrime.simpleSieve = simpleSieve; -findPrime.fermatTest = fermatTest; -var BN = __webpack_require__(23); -var TWENTYFOUR = new BN(24); -var MillerRabin = __webpack_require__(336); -var millerRabin = new MillerRabin(); -var ONE = new BN(1); -var TWO = new BN(2); -var FIVE = new BN(5); -var SIXTEEN = new BN(16); -var EIGHT = new BN(8); -var TEN = new BN(10); -var THREE = new BN(3); -var SEVEN = new BN(7); -var ELEVEN = new BN(11); -var FOUR = new BN(4); -var TWELVE = new BN(12); -var primes = null; + if (process.env.NODE_ENV !== 'production') { + process.env.NODE_ENV !== 'production' ? warning(shouldUpdate !== undefined, '%s.shouldComponentUpdate(): Returned undefined instead of a ' + 'boolean value. Make sure to return true or false.', this.getName() || 'ReactCompositeComponent') : void 0; + } -function _getPrimes() { - if (primes !== null) - return primes; + this._updateBatchNumber = null; + if (shouldUpdate) { + this._pendingForceUpdate = false; + // Will set `this.props`, `this.state` and `this.context`. + this._performComponentUpdate(nextParentElement, nextProps, nextState, nextContext, transaction, nextUnmaskedContext); + } else { + // If it's determined that a component should not update, we still want + // to set props and state but we shortcut the rest of the update. + this._currentElement = nextParentElement; + this._context = nextUnmaskedContext; + inst.props = nextProps; + inst.state = nextState; + inst.context = nextContext; + } + }, - var limit = 0x100000; - var res = []; - res[0] = 2; - for (var i = 1, k = 3; k < limit; k += 2) { - var sqrt = Math.ceil(Math.sqrt(k)); - for (var j = 0; j < i && res[j] <= sqrt; j++) - if (k % res[j] === 0) - break; + _processPendingState: function (props, context) { + var inst = this._instance; + var queue = this._pendingStateQueue; + var replace = this._pendingReplaceState; + this._pendingReplaceState = false; + this._pendingStateQueue = null; - if (i !== j && res[j] <= sqrt) - continue; + if (!queue) { + return inst.state; + } + + if (replace && queue.length === 1) { + return queue[0]; + } + + var nextState = _assign({}, replace ? queue[0] : inst.state); + for (var i = replace ? 1 : 0; i < queue.length; i++) { + var partial = queue[i]; + _assign(nextState, typeof partial === 'function' ? partial.call(inst, nextState, props, context) : partial); + } + + return nextState; + }, + + /** + * Merges new props and state, notifies delegate methods of update and + * performs update. + * + * @param {ReactElement} nextElement Next element + * @param {object} nextProps Next public object to set as properties. + * @param {?object} nextState Next object to set as state. + * @param {?object} nextContext Next public object to set as context. + * @param {ReactReconcileTransaction} transaction + * @param {?object} unmaskedContext + * @private + */ + _performComponentUpdate: function (nextElement, nextProps, nextState, nextContext, transaction, unmaskedContext) { + var _this2 = this; - res[i++] = k; - } - primes = res; - return res; -} + var inst = this._instance; -function simpleSieve(p) { - var primes = _getPrimes(); + var hasComponentDidUpdate = Boolean(inst.componentDidUpdate); + var prevProps; + var prevState; + var prevContext; + if (hasComponentDidUpdate) { + prevProps = inst.props; + prevState = inst.state; + prevContext = inst.context; + } - for (var i = 0; i < primes.length; i++) - if (p.modn(primes[i]) === 0) { - if (p.cmpn(primes[i]) === 0) { - return true; + if (inst.componentWillUpdate) { + if (process.env.NODE_ENV !== 'production') { + measureLifeCyclePerf(function () { + return inst.componentWillUpdate(nextProps, nextState, nextContext); + }, this._debugID, 'componentWillUpdate'); } else { - return false; + inst.componentWillUpdate(nextProps, nextState, nextContext); } } - return true; -} - -function fermatTest(p) { - var red = BN.mont(p); - return TWO.toRed(red).redPow(p.subn(1)).fromRed().cmpn(1) === 0; -} - -function findPrime(bits, gen) { - if (bits < 16) { - // this is what openssl does - if (gen === 2 || gen === 5) { - return new BN([0x8c, 0x7b]); - } else { - return new BN([0x8c, 0x27]); - } - } - gen = new BN(gen); + this._currentElement = nextElement; + this._context = unmaskedContext; + inst.props = nextProps; + inst.state = nextState; + inst.context = nextContext; - var num, n2; + this._updateRenderedComponent(transaction, unmaskedContext); - while (true) { - num = new BN(randomBytes(Math.ceil(bits / 8))); - while (num.bitLength() > bits) { - num.ishrn(1); - } - if (num.isEven()) { - num.iadd(ONE); - } - if (!num.testn(1)) { - num.iadd(TWO); - } - if (!gen.cmp(TWO)) { - while (num.mod(TWENTYFOUR).cmp(ELEVEN)) { - num.iadd(FOUR); - } - } else if (!gen.cmp(FIVE)) { - while (num.mod(TEN).cmp(THREE)) { - num.iadd(FOUR); + if (hasComponentDidUpdate) { + if (process.env.NODE_ENV !== 'production') { + transaction.getReactMountReady().enqueue(function () { + measureLifeCyclePerf(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), _this2._debugID, 'componentDidUpdate'); + }); + } else { + transaction.getReactMountReady().enqueue(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), inst); } } - n2 = num.shrn(1); - if (simpleSieve(n2) && simpleSieve(num) && - fermatTest(n2) && fermatTest(num) && - millerRabin.test(n2) && millerRabin.test(num)) { - return num; - } - } + }, -} + /** + * Call the component's `render` method and update the DOM accordingly. + * + * @param {ReactReconcileTransaction} transaction + * @internal + */ + _updateRenderedComponent: function (transaction, context) { + var prevComponentInstance = this._renderedComponent; + var prevRenderedElement = prevComponentInstance._currentElement; + var nextRenderedElement = this._renderValidatedComponent(); + var debugID = 0; + if (process.env.NODE_ENV !== 'production') { + debugID = this._debugID; + } -/***/ }), -/* 336 */ -/***/ (function(module, exports, __webpack_require__) { + if (shouldUpdateReactComponent(prevRenderedElement, nextRenderedElement)) { + ReactReconciler.receiveComponent(prevComponentInstance, nextRenderedElement, transaction, this._processChildContext(context)); + } else { + var oldHostNode = ReactReconciler.getHostNode(prevComponentInstance); + ReactReconciler.unmountComponent(prevComponentInstance, false); -var bn = __webpack_require__(23); -var brorand = __webpack_require__(317); + var nodeType = ReactNodeTypes.getType(nextRenderedElement); + this._renderedNodeType = nodeType; + var child = this._instantiateReactComponent(nextRenderedElement, nodeType !== ReactNodeTypes.EMPTY /* shouldHaveDebugID */ + ); + this._renderedComponent = child; -function MillerRabin(rand) { - this.rand = rand || new brorand.Rand(); -} -module.exports = MillerRabin; + var nextMarkup = ReactReconciler.mountComponent(child, transaction, this._hostParent, this._hostContainerInfo, this._processChildContext(context), debugID); -MillerRabin.create = function create(rand) { - return new MillerRabin(rand); -}; + if (process.env.NODE_ENV !== 'production') { + if (debugID !== 0) { + var childDebugIDs = child._debugID !== 0 ? [child._debugID] : []; + ReactInstrumentation.debugTool.onSetChildren(debugID, childDebugIDs); + } + } -MillerRabin.prototype._rand = function _rand(n) { - var len = n.bitLength(); - var buf = this.rand.generate(Math.ceil(len / 8)); + this._replaceNodeWithMarkup(oldHostNode, nextMarkup, prevComponentInstance); + } + }, - // Set low bits - buf[0] |= 3; + /** + * Overridden in shallow rendering. + * + * @protected + */ + _replaceNodeWithMarkup: function (oldHostNode, nextMarkup, prevInstance) { + ReactComponentEnvironment.replaceNodeWithMarkup(oldHostNode, nextMarkup, prevInstance); + }, - // Mask high bits - var mask = len & 0x7; - if (mask !== 0) - buf[buf.length - 1] >>= 7 - mask; + /** + * @protected + */ + _renderValidatedComponentWithoutOwnerOrContext: function () { + var inst = this._instance; + var renderedElement; - return new bn(buf); -} + if (process.env.NODE_ENV !== 'production') { + renderedElement = measureLifeCyclePerf(function () { + return inst.render(); + }, this._debugID, 'render'); + } else { + renderedElement = inst.render(); + } -MillerRabin.prototype.test = function test(n, k, cb) { - var len = n.bitLength(); - var red = bn.mont(n); - var rone = new bn(1).toRed(red); + if (process.env.NODE_ENV !== 'production') { + // We allow auto-mocks to proceed as if they're returning null. + if (renderedElement === undefined && inst.render._isMockFunction) { + // This is probably bad practice. Consider warning here and + // deprecating this convenience. + renderedElement = null; + } + } - if (!k) - k = Math.max(1, (len / 48) | 0); + return renderedElement; + }, - // Find d and s, (n - 1) = (2 ^ s) * d; - var n1 = n.subn(1); - var n2 = n1.subn(1); - for (var s = 0; !n1.testn(s); s++) {} - var d = n.shrn(s); + /** + * @private + */ + _renderValidatedComponent: function () { + var renderedElement; + if (process.env.NODE_ENV !== 'production' || this._compositeType !== CompositeTypes.StatelessFunctional) { + ReactCurrentOwner.current = this; + try { + renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); + } finally { + ReactCurrentOwner.current = null; + } + } else { + renderedElement = this._renderValidatedComponentWithoutOwnerOrContext(); + } + !( + // TODO: An `isValidNode` function would probably be more appropriate + renderedElement === null || renderedElement === false || React.isValidElement(renderedElement)) ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s.render(): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.', this.getName() || 'ReactCompositeComponent') : _prodInvariant('109', this.getName() || 'ReactCompositeComponent') : void 0; - var rn1 = n1.toRed(red); + return renderedElement; + }, - var prime = true; - for (; k > 0; k--) { - var a = this._rand(n2); - if (cb) - cb(a); + /** + * Lazily allocates the refs object and stores `component` as `ref`. + * + * @param {string} ref Reference name. + * @param {component} component Component to store as `ref`. + * @final + * @private + */ + attachRef: function (ref, component) { + var inst = this.getPublicInstance(); + !(inst != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Stateless function components cannot have refs.') : _prodInvariant('110') : void 0; + var publicComponentInstance = component.getPublicInstance(); + if (process.env.NODE_ENV !== 'production') { + var componentName = component && component.getName ? component.getName() : 'a component'; + process.env.NODE_ENV !== 'production' ? warning(publicComponentInstance != null || component._compositeType !== CompositeTypes.StatelessFunctional, 'Stateless function components cannot be given refs ' + '(See ref "%s" in %s created by %s). ' + 'Attempts to access this ref will fail.', ref, componentName, this.getName()) : void 0; + } + var refs = inst.refs === emptyObject ? inst.refs = {} : inst.refs; + refs[ref] = publicComponentInstance; + }, - var x = a.toRed(red).redPow(d); - if (x.cmp(rone) === 0 || x.cmp(rn1) === 0) - continue; + /** + * Detaches a reference name. + * + * @param {string} ref Name to dereference. + * @final + * @private + */ + detachRef: function (ref) { + var refs = this.getPublicInstance().refs; + delete refs[ref]; + }, - for (var i = 1; i < s; i++) { - x = x.redSqr(); + /** + * Get a text description of the component that can be used to identify it + * in error messages. + * @return {string} The name or null. + * @internal + */ + getName: function () { + var type = this._currentElement.type; + var constructor = this._instance && this._instance.constructor; + return type.displayName || constructor && constructor.displayName || type.name || constructor && constructor.name || null; + }, - if (x.cmp(rone) === 0) - return false; - if (x.cmp(rn1) === 0) - break; + /** + * Get the publicly accessible representation of this component - i.e. what + * is exposed by refs and returned by render. Can be null for stateless + * components. + * + * @return {ReactComponent} the public component instance. + * @internal + */ + getPublicInstance: function () { + var inst = this._instance; + if (this._compositeType === CompositeTypes.StatelessFunctional) { + return null; } + return inst; + }, - if (i === s) - return false; - } - - return prime; + // Stub + _instantiateReactComponent: null }; -MillerRabin.prototype.getDivisor = function getDivisor(n, k) { - var len = n.bitLength(); - var red = bn.mont(n); - var rone = new bn(1).toRed(red); +module.exports = ReactCompositeComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - if (!k) - k = Math.max(1, (len / 48) | 0); +/***/ }), +/* 272 */ +/***/ (function(module, exports, __webpack_require__) { - // Find d and s, (n - 1) = (2 ^ s) * d; - var n1 = n.subn(1); - var n2 = n1.subn(1); - for (var s = 0; !n1.testn(s); s++) {} - var d = n.shrn(s); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var rn1 = n1.toRed(red); - for (; k > 0; k--) { - var a = this._rand(n2); - var g = n.gcd(a); - if (g.cmpn(1) !== 0) - return g; +var _prodInvariant = __webpack_require__(5); - var x = a.toRed(red).redPow(d); - if (x.cmp(rone) === 0 || x.cmp(rn1) === 0) - continue; +var ReactPropTypeLocationNames = __webpack_require__(273); +var ReactPropTypesSecret = __webpack_require__(139); - for (var i = 1; i < s; i++) { - x = x.redSqr(); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); - if (x.cmp(rone) === 0) - return x.fromRed().subn(1).gcd(n); - if (x.cmp(rn1) === 0) - break; - } +var ReactComponentTreeHook; - if (i === s) { - x = x.redSqr(); - return x.fromRed().subn(1).gcd(n); - } - } +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} - return false; -}; +var loggedTypeFailures = {}; +/** + * Assert that the values match with the type specs. + * Error messages are memorized and will only be shown once. + * + * @param {object} typeSpecs Map of name to a ReactPropType + * @param {object} values Runtime values that need to be type-checked + * @param {string} location e.g. "prop", "context", "child context" + * @param {string} componentName Name of the component for error messages. + * @param {?object} element The React element that is being type-checked + * @param {?number} debugID The React component instance that is being type-checked + * @private + */ +function checkReactTypeSpec(typeSpecs, values, location, componentName, element, debugID) { + for (var typeSpecName in typeSpecs) { + if (typeSpecs.hasOwnProperty(typeSpecName)) { + var error; + // Prop type validation may throw. In case they do, we don't want to + // fail the render phase where it didn't fail before. So we log it. + // After these have been cleaned up, we'll let them throw. + try { + // This is intentionally an invariant that gets caught. It's the same + // behavior as without this statement except with a better message. + !(typeof typeSpecs[typeSpecName] === 'function') ? process.env.NODE_ENV !== 'production' ? invariant(false, '%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : _prodInvariant('84', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName) : void 0; + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); + } catch (ex) { + error = ex; + } + process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', ReactPropTypeLocationNames[location], typeSpecName, typeof error) : void 0; + if (error instanceof Error && !(error.message in loggedTypeFailures)) { + // Only monitor this failure once because there tends to be a lot of the + // same error. + loggedTypeFailures[error.message] = true; -/***/ }), -/* 337 */ -/***/ (function(module, exports, __webpack_require__) { + var componentStackInfo = ''; -var inherits = __webpack_require__(11); -var Reporter = __webpack_require__(241).Reporter; -var Buffer = __webpack_require__(7).Buffer; + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (debugID !== null) { + componentStackInfo = ReactComponentTreeHook.getStackAddendumByID(debugID); + } else if (element !== null) { + componentStackInfo = ReactComponentTreeHook.getCurrentStackAddendum(element); + } + } -function DecoderBuffer(base, options) { - Reporter.call(this, options); - if (!Buffer.isBuffer(base)) { - this.error('Input not Buffer'); - return; + process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, componentStackInfo) : void 0; + } + } } - - this.base = base; - this.offset = 0; - this.length = base.length; } -inherits(DecoderBuffer, Reporter); -exports.DecoderBuffer = DecoderBuffer; - -DecoderBuffer.prototype.save = function save() { - return { offset: this.offset, reporter: Reporter.prototype.save.call(this) }; -}; -DecoderBuffer.prototype.restore = function restore(save) { - // Return skipped data - var res = new DecoderBuffer(this.base); - res.offset = save.offset; - res.length = this.offset; +module.exports = checkReactTypeSpec; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - this.offset = save.offset; - Reporter.prototype.restore.call(this, save.reporter); +/***/ }), +/* 273 */ +/***/ (function(module, exports, __webpack_require__) { - return res; -}; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -DecoderBuffer.prototype.isEmpty = function isEmpty() { - return this.offset === this.length; -}; -DecoderBuffer.prototype.readUInt8 = function readUInt8(fail) { - if (this.offset + 1 <= this.length) - return this.base.readUInt8(this.offset++, true); - else - return this.error(fail || 'DecoderBuffer overrun'); -} -DecoderBuffer.prototype.skip = function skip(bytes, fail) { - if (!(this.offset + bytes <= this.length)) - return this.error(fail || 'DecoderBuffer overrun'); +var ReactPropTypeLocationNames = {}; - var res = new DecoderBuffer(this.base); +if (process.env.NODE_ENV !== 'production') { + ReactPropTypeLocationNames = { + prop: 'prop', + context: 'context', + childContext: 'child context' + }; +} - // Share reporter state - res._reporterState = this._reporterState; +module.exports = ReactPropTypeLocationNames; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - res.offset = this.offset; - res.length = this.offset + bytes; - this.offset += bytes; - return res; -} +/***/ }), +/* 274 */ +/***/ (function(module, exports, __webpack_require__) { -DecoderBuffer.prototype.raw = function raw(save) { - return this.base.slice(save ? save.offset : this.offset, this.length); -} +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -function EncoderBuffer(value, reporter) { - if (Array.isArray(value)) { - this.length = 0; - this.value = value.map(function(item) { - if (!(item instanceof EncoderBuffer)) - item = new EncoderBuffer(item, reporter); - this.length += item.length; - return item; - }, this); - } else if (typeof value === 'number') { - if (!(0 <= value && value <= 0xff)) - return reporter.error('non-byte EncoderBuffer value'); - this.value = value; - this.length = 1; - } else if (typeof value === 'string') { - this.value = value; - this.length = Buffer.byteLength(value); - } else if (Buffer.isBuffer(value)) { - this.value = value; - this.length = value.length; - } else { - return reporter.error('Unsupported type: ' + typeof value); - } + + +var nextDebugID = 1; + +function getNextDebugID() { + return nextDebugID++; } -exports.EncoderBuffer = EncoderBuffer; -EncoderBuffer.prototype.join = function join(out, offset) { - if (!out) - out = new Buffer(this.length); - if (!offset) - offset = 0; +module.exports = getNextDebugID; - if (this.length === 0) - return out; +/***/ }), +/* 275 */ +/***/ (function(module, exports, __webpack_require__) { - if (Array.isArray(this.value)) { - this.value.forEach(function(item) { - item.join(out, offset); - offset += item.length; - }); - } else { - if (typeof this.value === 'number') - out[offset] = this.value; - else if (typeof this.value === 'string') - out.write(this.value, offset); - else if (Buffer.isBuffer(this.value)) - this.value.copy(out, offset); - offset += this.length; - } +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - return out; -}; +// The Symbol used to tag the ReactElement type. If there is no native Symbol +// nor polyfill, then a plain number is used for performance. + +var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; + +module.exports = REACT_ELEMENT_TYPE; + /***/ }), -/* 338 */ +/* 276 */ /***/ (function(module, exports, __webpack_require__) { -var constants = exports; +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -// Helper -constants._reverse = function reverse(map) { - var res = {}; - Object.keys(map).forEach(function(key) { - // Convert key to integer if it is stringified - if ((key | 0) == key) - key = key | 0; - var value = map[key]; - res[value] = key; - }); +/* global Symbol */ - return res; -}; +var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; +var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. -constants.der = __webpack_require__(505); +/** + * Returns the iterator method function contained on the iterable object. + * + * Be sure to invoke the function with the iterable as context: + * + * var iteratorFn = getIteratorFn(myIterable); + * if (iteratorFn) { + * var iterator = iteratorFn.call(myIterable); + * ... + * } + * + * @param {?object} maybeIterable + * @return {?function} + */ +function getIteratorFn(maybeIterable) { + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); + if (typeof iteratorFn === 'function') { + return iteratorFn; + } +} +module.exports = getIteratorFn; /***/ }), -/* 339 */ +/* 277 */ /***/ (function(module, exports, __webpack_require__) { -var inherits = __webpack_require__(11); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ -var asn1 = __webpack_require__(240); -var base = asn1.base; -var bignum = asn1.bignum; -// Import DER constants -var der = asn1.constants.der; -function DERDecoder(entity) { - this.enc = 'der'; - this.name = entity.name; - this.entity = entity; +var KeyEscapeUtils = __webpack_require__(89); +var traverseAllChildren = __webpack_require__(145); +var warning = __webpack_require__(3); - // Construct base tree - this.tree = new DERNode(); - this.tree._init(entity.body); -}; -module.exports = DERDecoder; +var ReactComponentTreeHook; -DERDecoder.prototype.decode = function decode(data, options) { - if (!(data instanceof base.DecoderBuffer)) - data = new base.DecoderBuffer(data, options); +if (typeof process !== 'undefined' && process.env && process.env.NODE_ENV === 'test') { + // Temporary hack. + // Inline requires don't work well with Jest: + // https://github.com/facebook/react/issues/7240 + // Remove the inline requires when we don't need them anymore: + // https://github.com/facebook/react/pull/7178 + ReactComponentTreeHook = __webpack_require__(17); +} - return this.tree._decode(data, options); -}; +/** + * @param {function} traverseContext Context passed through traversal. + * @param {?ReactComponent} child React child component. + * @param {!string} name String name of key path to child. + * @param {number=} selfDebugID Optional debugID of the current internal instance. + */ +function flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID) { + // We found a component instance. + if (traverseContext && typeof traverseContext === 'object') { + var result = traverseContext; + var keyUnique = result[name] === undefined; + if (process.env.NODE_ENV !== 'production') { + if (!ReactComponentTreeHook) { + ReactComponentTreeHook = __webpack_require__(17); + } + if (!keyUnique) { + process.env.NODE_ENV !== 'production' ? warning(false, 'flattenChildren(...): Encountered two children with the same key, ' + '`%s`. Child keys must be unique; when two children share a key, only ' + 'the first child will be used.%s', KeyEscapeUtils.unescape(name), ReactComponentTreeHook.getStackAddendumByID(selfDebugID)) : void 0; + } + } + if (keyUnique && child != null) { + result[name] = child; + } + } +} -// Tree methods +/** + * Flattens children that are typically specified as `props.children`. Any null + * children will not be included in the resulting object. + * @return {!object} flattened children keyed by name. + */ +function flattenChildren(children, selfDebugID) { + if (children == null) { + return children; + } + var result = {}; -function DERNode(parent) { - base.Node.call(this, 'der', parent); + if (process.env.NODE_ENV !== 'production') { + traverseAllChildren(children, function (traverseContext, child, name) { + return flattenSingleChildIntoContext(traverseContext, child, name, selfDebugID); + }, result); + } else { + traverseAllChildren(children, flattenSingleChildIntoContext, result); + } + return result; } -inherits(DERNode, base.Node); -DERNode.prototype._peekTag = function peekTag(buffer, tag, any) { - if (buffer.isEmpty()) - return false; +module.exports = flattenChildren; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var state = buffer.save(); - var decodedTag = derDecodeTag(buffer, 'Failed to peek tag: "' + tag + '"'); - if (buffer.isError(decodedTag)) - return decodedTag; +/***/ }), +/* 278 */ +/***/ (function(module, exports, __webpack_require__) { - buffer.restore(state); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - return decodedTag.tag === tag || decodedTag.tagStr === tag || - (decodedTag.tagStr + 'of') === tag || any; + + +var _assign = __webpack_require__(8); + +var PooledClass = __webpack_require__(32); +var Transaction = __webpack_require__(58); +var ReactInstrumentation = __webpack_require__(19); +var ReactServerUpdateQueue = __webpack_require__(279); + +/** + * Executed within the scope of the `Transaction` instance. Consider these as + * being member methods, but with an implied ordering while being isolated from + * each other. + */ +var TRANSACTION_WRAPPERS = []; + +if (process.env.NODE_ENV !== 'production') { + TRANSACTION_WRAPPERS.push({ + initialize: ReactInstrumentation.debugTool.onBeginFlush, + close: ReactInstrumentation.debugTool.onEndFlush + }); +} + +var noopCallbackQueue = { + enqueue: function () {} }; -DERNode.prototype._decodeTag = function decodeTag(buffer, tag, any) { - var decodedTag = derDecodeTag(buffer, - 'Failed to decode tag of "' + tag + '"'); - if (buffer.isError(decodedTag)) - return decodedTag; +/** + * @class ReactServerRenderingTransaction + * @param {boolean} renderToStaticMarkup + */ +function ReactServerRenderingTransaction(renderToStaticMarkup) { + this.reinitializeTransaction(); + this.renderToStaticMarkup = renderToStaticMarkup; + this.useCreateElement = false; + this.updateQueue = new ReactServerUpdateQueue(this); +} - var len = derDecodeLen(buffer, - decodedTag.primitive, - 'Failed to get length of "' + tag + '"'); +var Mixin = { + /** + * @see Transaction + * @abstract + * @final + * @return {array} Empty list of operation wrap procedures. + */ + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, - // Failure - if (buffer.isError(len)) - return len; + /** + * @return {object} The queue to collect `onDOMReady` callbacks with. + */ + getReactMountReady: function () { + return noopCallbackQueue; + }, - if (!any && - decodedTag.tag !== tag && - decodedTag.tagStr !== tag && - decodedTag.tagStr + 'of' !== tag) { - return buffer.error('Failed to match tag: "' + tag + '"'); - } + /** + * @return {object} The queue to collect React async events. + */ + getUpdateQueue: function () { + return this.updateQueue; + }, - if (decodedTag.primitive || len !== null) - return buffer.skip(len, 'Failed to match body of: "' + tag + '"'); + /** + * `PooledClass` looks for this, and will invoke this before allowing this + * instance to be reused. + */ + destructor: function () {}, - // Indefinite length... find END tag - var state = buffer.save(); - var res = this._skipUntilEnd( - buffer, - 'Failed to skip indefinite length body: "' + this.tag + '"'); - if (buffer.isError(res)) - return res; + checkpoint: function () {}, - len = buffer.offset - state.offset; - buffer.restore(state); - return buffer.skip(len, 'Failed to match body of: "' + tag + '"'); + rollback: function () {} }; -DERNode.prototype._skipUntilEnd = function skipUntilEnd(buffer, fail) { - while (true) { - var tag = derDecodeTag(buffer, fail); - if (buffer.isError(tag)) - return tag; - var len = derDecodeLen(buffer, tag.primitive, fail); - if (buffer.isError(len)) - return len; +_assign(ReactServerRenderingTransaction.prototype, Transaction, Mixin); - var res; - if (tag.primitive || len !== null) - res = buffer.skip(len) - else - res = this._skipUntilEnd(buffer, fail); +PooledClass.addPoolingTo(ReactServerRenderingTransaction); - // Failure - if (buffer.isError(res)) - return res; +module.exports = ReactServerRenderingTransaction; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - if (tag.tagStr === 'end') - break; - } -}; +/***/ }), +/* 279 */ +/***/ (function(module, exports, __webpack_require__) { -DERNode.prototype._decodeList = function decodeList(buffer, tag, decoder, - options) { - var result = []; - while (!buffer.isEmpty()) { - var possibleEnd = this._peekTag(buffer, 'end'); - if (buffer.isError(possibleEnd)) - return possibleEnd; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - var res = decoder.decode(buffer, 'der', options); - if (buffer.isError(res) && possibleEnd) - break; - result.push(res); - } - return result; -}; -DERNode.prototype._decodeStr = function decodeStr(buffer, tag) { - if (tag === 'bitstr') { - var unused = buffer.readUInt8(); - if (buffer.isError(unused)) - return unused; - return { unused: unused, data: buffer.raw() }; - } else if (tag === 'bmpstr') { - var raw = buffer.raw(); - if (raw.length % 2 === 1) - return buffer.error('Decoding of string type: bmpstr length mismatch'); - var str = ''; - for (var i = 0; i < raw.length / 2; i++) { - str += String.fromCharCode(raw.readUInt16BE(i * 2)); - } - return str; - } else if (tag === 'numstr') { - var numstr = buffer.raw().toString('ascii'); - if (!this._isNumstr(numstr)) { - return buffer.error('Decoding of string type: ' + - 'numstr unsupported characters'); - } - return numstr; - } else if (tag === 'octstr') { - return buffer.raw(); - } else if (tag === 'objDesc') { - return buffer.raw(); - } else if (tag === 'printstr') { - var printstr = buffer.raw().toString('ascii'); - if (!this._isPrintstr(printstr)) { - return buffer.error('Decoding of string type: ' + - 'printstr unsupported characters'); - } - return printstr; - } else if (/str$/.test(tag)) { - return buffer.raw().toString(); - } else { - return buffer.error('Decoding of string type: ' + tag + ' unsupported'); - } -}; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -DERNode.prototype._decodeObjid = function decodeObjid(buffer, values, relative) { - var result; - var identifiers = []; - var ident = 0; - while (!buffer.isEmpty()) { - var subident = buffer.readUInt8(); - ident <<= 7; - ident |= subident & 0x7f; - if ((subident & 0x80) === 0) { - identifiers.push(ident); - ident = 0; - } +var ReactUpdateQueue = __webpack_require__(90); + +var warning = __webpack_require__(3); + +function warnNoop(publicInstance, callerName) { + if (process.env.NODE_ENV !== 'production') { + var constructor = publicInstance.constructor; + process.env.NODE_ENV !== 'production' ? warning(false, '%s(...): Can only update a mounting component. ' + 'This usually means you called %s() outside componentWillMount() on the server. ' + 'This is a no-op. Please check the code for the %s component.', callerName, callerName, constructor && (constructor.displayName || constructor.name) || 'ReactClass') : void 0; } - if (subident & 0x80) - identifiers.push(ident); +} - var first = (identifiers[0] / 40) | 0; - var second = identifiers[0] % 40; +/** + * This is the update queue used for server rendering. + * It delegates to ReactUpdateQueue while server rendering is in progress and + * switches to ReactNoopUpdateQueue after the transaction has completed. + * @class ReactServerUpdateQueue + * @param {Transaction} transaction + */ - if (relative) - result = identifiers; - else - result = [first, second].concat(identifiers.slice(1)); +var ReactServerUpdateQueue = function () { + function ReactServerUpdateQueue(transaction) { + _classCallCheck(this, ReactServerUpdateQueue); - if (values) { - var tmp = values[result.join(' ')]; - if (tmp === undefined) - tmp = values[result.join('.')]; - if (tmp !== undefined) - result = tmp; + this.transaction = transaction; } - return result; -}; + /** + * Checks whether or not this composite component is mounted. + * @param {ReactClass} publicInstance The instance we want to test. + * @return {boolean} True if mounted, false otherwise. + * @protected + * @final + */ -DERNode.prototype._decodeTime = function decodeTime(buffer, tag) { - var str = buffer.raw().toString(); - if (tag === 'gentime') { - var year = str.slice(0, 4) | 0; - var mon = str.slice(4, 6) | 0; - var day = str.slice(6, 8) | 0; - var hour = str.slice(8, 10) | 0; - var min = str.slice(10, 12) | 0; - var sec = str.slice(12, 14) | 0; - } else if (tag === 'utctime') { - var year = str.slice(0, 2) | 0; - var mon = str.slice(2, 4) | 0; - var day = str.slice(4, 6) | 0; - var hour = str.slice(6, 8) | 0; - var min = str.slice(8, 10) | 0; - var sec = str.slice(10, 12) | 0; - if (year < 70) - year = 2000 + year; - else - year = 1900 + year; - } else { - return buffer.error('Decoding ' + tag + ' time is not supported yet'); - } - return Date.UTC(year, mon - 1, day, hour, min, sec, 0); -}; + ReactServerUpdateQueue.prototype.isMounted = function isMounted(publicInstance) { + return false; + }; -DERNode.prototype._decodeNull = function decodeNull(buffer) { - return null; -}; + /** + * Enqueue a callback that will be executed after all the pending updates + * have processed. + * + * @param {ReactClass} publicInstance The instance to use as `this` context. + * @param {?function} callback Called after state is updated. + * @internal + */ -DERNode.prototype._decodeBool = function decodeBool(buffer) { - var res = buffer.readUInt8(); - if (buffer.isError(res)) - return res; - else - return res !== 0; -}; -DERNode.prototype._decodeInt = function decodeInt(buffer, values) { - // Bigint, return as it is (assume big endian) - var raw = buffer.raw(); - var res = new bignum(raw); + ReactServerUpdateQueue.prototype.enqueueCallback = function enqueueCallback(publicInstance, callback, callerName) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueCallback(publicInstance, callback, callerName); + } + }; + + /** + * Forces an update. This should only be invoked when it is known with + * certainty that we are **not** in a DOM transaction. + * + * You may want to call this when you know that some deeper aspect of the + * component's state has changed but `setState` was not called. + * + * This will not invoke `shouldComponentUpdate`, but it will invoke + * `componentWillUpdate` and `componentDidUpdate`. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @internal + */ - if (values) - res = values[res.toString(10)] || res; - return res; -}; + ReactServerUpdateQueue.prototype.enqueueForceUpdate = function enqueueForceUpdate(publicInstance) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueForceUpdate(publicInstance); + } else { + warnNoop(publicInstance, 'forceUpdate'); + } + }; -DERNode.prototype._use = function use(entity, obj) { - if (typeof entity === 'function') - entity = entity(obj); - return entity._getDecoder('der').tree; -}; + /** + * Replaces all of the state. Always use this or `setState` to mutate state. + * You should treat `this.state` as immutable. + * + * There is no guarantee that `this.state` will be immediately updated, so + * accessing `this.state` after calling this method may return the old value. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object|function} completeState Next state. + * @internal + */ -// Utility methods -function derDecodeTag(buf, fail) { - var tag = buf.readUInt8(fail); - if (buf.isError(tag)) - return tag; + ReactServerUpdateQueue.prototype.enqueueReplaceState = function enqueueReplaceState(publicInstance, completeState) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueReplaceState(publicInstance, completeState); + } else { + warnNoop(publicInstance, 'replaceState'); + } + }; - var cls = der.tagClass[tag >> 6]; - var primitive = (tag & 0x20) === 0; + /** + * Sets a subset of the state. This only exists because _pendingState is + * internal. This provides a merging strategy that is not available to deep + * properties which is confusing. TODO: Expose pendingState or don't use it + * during the merge. + * + * @param {ReactClass} publicInstance The instance that should rerender. + * @param {object|function} partialState Next partial state to be merged with state. + * @internal + */ - // Multi-octet tag - load - if ((tag & 0x1f) === 0x1f) { - var oct = tag; - tag = 0; - while ((oct & 0x80) === 0x80) { - oct = buf.readUInt8(fail); - if (buf.isError(oct)) - return oct; - tag <<= 7; - tag |= oct & 0x7f; + ReactServerUpdateQueue.prototype.enqueueSetState = function enqueueSetState(publicInstance, partialState) { + if (this.transaction.isInTransaction()) { + ReactUpdateQueue.enqueueSetState(publicInstance, partialState); + } else { + warnNoop(publicInstance, 'setState'); } - } else { - tag &= 0x1f; - } - var tagStr = der.tag[tag]; - - return { - cls: cls, - primitive: primitive, - tag: tag, - tagStr: tagStr }; -} -function derDecodeLen(buf, primitive, fail) { - var len = buf.readUInt8(fail); - if (buf.isError(len)) - return len; + return ReactServerUpdateQueue; +}(); - // Indefinite form - if (!primitive && len === 0x80) - return null; +module.exports = ReactServerUpdateQueue; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - // Definite form - if ((len & 0x80) === 0) { - // Short form - return len; - } +/***/ }), +/* 280 */ +/***/ (function(module, exports, __webpack_require__) { - // Long form - var num = len & 0x7f; - if (num > 4) - return buf.error('length octect is too long'); +"use strict"; +/** + * Copyright 2014-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - len = 0; - for (var i = 0; i < num; i++) { - len <<= 8; - var j = buf.readUInt8(fail); - if (buf.isError(j)) - return j; - len |= j; - } - return len; -} +var _assign = __webpack_require__(8); -/***/ }), -/* 340 */ -/***/ (function(module, exports, __webpack_require__) { +var DOMLazyTree = __webpack_require__(39); +var ReactDOMComponentTree = __webpack_require__(10); -var inherits = __webpack_require__(11); -var Buffer = __webpack_require__(7).Buffer; +var ReactDOMEmptyComponent = function (instantiate) { + // ReactCompositeComponent uses this: + this._currentElement = null; + // ReactDOMComponentTree uses these: + this._hostNode = null; + this._hostParent = null; + this._hostContainerInfo = null; + this._domID = 0; +}; +_assign(ReactDOMEmptyComponent.prototype, { + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + var domID = hostContainerInfo._idCounter++; + this._domID = domID; + this._hostParent = hostParent; + this._hostContainerInfo = hostContainerInfo; -var asn1 = __webpack_require__(240); -var base = asn1.base; + var nodeValue = ' react-empty: ' + this._domID + ' '; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var node = ownerDocument.createComment(nodeValue); + ReactDOMComponentTree.precacheNode(this, node); + return DOMLazyTree(node); + } else { + if (transaction.renderToStaticMarkup) { + // Normally we'd insert a comment node, but since this is a situation + // where React won't take over (static pages), we can simply return + // nothing. + return ''; + } + return '<!--' + nodeValue + '-->'; + } + }, + receiveComponent: function () {}, + getHostNode: function () { + return ReactDOMComponentTree.getNodeFromInstance(this); + }, + unmountComponent: function () { + ReactDOMComponentTree.uncacheNode(this); + } +}); -// Import DER constants -var der = asn1.constants.der; +module.exports = ReactDOMEmptyComponent; -function DEREncoder(entity) { - this.enc = 'der'; - this.name = entity.name; - this.entity = entity; +/***/ }), +/* 281 */ +/***/ (function(module, exports, __webpack_require__) { - // Construct base tree - this.tree = new DERNode(); - this.tree._init(entity.body); -}; -module.exports = DEREncoder; +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2015-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -DEREncoder.prototype.encode = function encode(data, reporter) { - return this.tree._encode(data, reporter).join(); -}; -// Tree methods -function DERNode(parent) { - base.Node.call(this, 'der', parent); -} -inherits(DERNode, base.Node); +var _prodInvariant = __webpack_require__(5); -DERNode.prototype._encodeComposite = function encodeComposite(tag, - primitive, - cls, - content) { - var encodedTag = encodeTag(tag, primitive, cls, this.reporter); +var invariant = __webpack_require__(2); - // Short form - if (content.length < 0x80) { - var header = new Buffer(2); - header[0] = encodedTag; - header[1] = content.length; - return this._createEncoderBuffer([ header, content ]); +/** + * Return the lowest common ancestor of A and B, or null if they are in + * different trees. + */ +function getLowestCommonAncestor(instA, instB) { + !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; + !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0; + + var depthA = 0; + for (var tempA = instA; tempA; tempA = tempA._hostParent) { + depthA++; + } + var depthB = 0; + for (var tempB = instB; tempB; tempB = tempB._hostParent) { + depthB++; } - // Long form - // Count octets required to store length - var lenOctets = 1; - for (var i = content.length; i >= 0x100; i >>= 8) - lenOctets++; + // If A is deeper, crawl up. + while (depthA - depthB > 0) { + instA = instA._hostParent; + depthA--; + } - var header = new Buffer(1 + 1 + lenOctets); - header[0] = encodedTag; - header[1] = 0x80 | lenOctets; + // If B is deeper, crawl up. + while (depthB - depthA > 0) { + instB = instB._hostParent; + depthB--; + } - for (var i = 1 + lenOctets, j = content.length; j > 0; i--, j >>= 8) - header[i] = j & 0xff; + // Walk in lockstep until we find a match. + var depth = depthA; + while (depth--) { + if (instA === instB) { + return instA; + } + instA = instA._hostParent; + instB = instB._hostParent; + } + return null; +} - return this._createEncoderBuffer([ header, content ]); -}; +/** + * Return if A is an ancestor of B. + */ +function isAncestor(instA, instB) { + !('_hostNode' in instA) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; + !('_hostNode' in instB) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'isAncestor: Invalid argument.') : _prodInvariant('35') : void 0; -DERNode.prototype._encodeStr = function encodeStr(str, tag) { - if (tag === 'bitstr') { - return this._createEncoderBuffer([ str.unused | 0, str.data ]); - } else if (tag === 'bmpstr') { - var buf = new Buffer(str.length * 2); - for (var i = 0; i < str.length; i++) { - buf.writeUInt16BE(str.charCodeAt(i), i * 2); - } - return this._createEncoderBuffer(buf); - } else if (tag === 'numstr') { - if (!this._isNumstr(str)) { - return this.reporter.error('Encoding of string type: numstr supports ' + - 'only digits and space'); - } - return this._createEncoderBuffer(str); - } else if (tag === 'printstr') { - if (!this._isPrintstr(str)) { - return this.reporter.error('Encoding of string type: printstr supports ' + - 'only latin upper and lower case letters, ' + - 'digits, space, apostrophe, left and rigth ' + - 'parenthesis, plus sign, comma, hyphen, ' + - 'dot, slash, colon, equal sign, ' + - 'question mark'); + while (instB) { + if (instB === instA) { + return true; } - return this._createEncoderBuffer(str); - } else if (/str$/.test(tag)) { - return this._createEncoderBuffer(str); - } else if (tag === 'objDesc') { - return this._createEncoderBuffer(str); - } else { - return this.reporter.error('Encoding of string type: ' + tag + - ' unsupported'); + instB = instB._hostParent; } -}; + return false; +} -DERNode.prototype._encodeObjid = function encodeObjid(id, values, relative) { - if (typeof id === 'string') { - if (!values) - return this.reporter.error('string objid given, but no values map found'); - if (!values.hasOwnProperty(id)) - return this.reporter.error('objid not found in values map'); - id = values[id].split(/[\s\.]+/g); - for (var i = 0; i < id.length; i++) - id[i] |= 0; - } else if (Array.isArray(id)) { - id = id.slice(); - for (var i = 0; i < id.length; i++) - id[i] |= 0; - } +/** + * Return the parent instance of the passed-in instance. + */ +function getParentInstance(inst) { + !('_hostNode' in inst) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'getParentInstance: Invalid argument.') : _prodInvariant('36') : void 0; - if (!Array.isArray(id)) { - return this.reporter.error('objid() should be either array or string, ' + - 'got: ' + JSON.stringify(id)); - } + return inst._hostParent; +} - if (!relative) { - if (id[1] >= 40) - return this.reporter.error('Second objid identifier OOB'); - id.splice(0, 2, id[0] * 40 + id[1]); +/** + * Simulates the traversal of a two-phase, capture/bubble event dispatch. + */ +function traverseTwoPhase(inst, fn, arg) { + var path = []; + while (inst) { + path.push(inst); + inst = inst._hostParent; } - - // Count number of octets - var size = 0; - for (var i = 0; i < id.length; i++) { - var ident = id[i]; - for (size++; ident >= 0x80; ident >>= 7) - size++; + var i; + for (i = path.length; i-- > 0;) { + fn(path[i], 'captured', arg); } + for (i = 0; i < path.length; i++) { + fn(path[i], 'bubbled', arg); + } +} - var objid = new Buffer(size); - var offset = objid.length - 1; - for (var i = id.length - 1; i >= 0; i--) { - var ident = id[i]; - objid[offset--] = ident & 0x7f; - while ((ident >>= 7) > 0) - objid[offset--] = 0x80 | (ident & 0x7f); +/** + * Traverses the ID hierarchy and invokes the supplied `cb` on any IDs that + * should would receive a `mouseEnter` or `mouseLeave` event. + * + * Does not invoke the callback on the nearest common ancestor because nothing + * "entered" or "left" that element. + */ +function traverseEnterLeave(from, to, fn, argFrom, argTo) { + var common = from && to ? getLowestCommonAncestor(from, to) : null; + var pathFrom = []; + while (from && from !== common) { + pathFrom.push(from); + from = from._hostParent; + } + var pathTo = []; + while (to && to !== common) { + pathTo.push(to); + to = to._hostParent; + } + var i; + for (i = 0; i < pathFrom.length; i++) { + fn(pathFrom[i], 'bubbled', argFrom); + } + for (i = pathTo.length; i-- > 0;) { + fn(pathTo[i], 'captured', argTo); } +} - return this._createEncoderBuffer(objid); +module.exports = { + isAncestor: isAncestor, + getLowestCommonAncestor: getLowestCommonAncestor, + getParentInstance: getParentInstance, + traverseTwoPhase: traverseTwoPhase, + traverseEnterLeave: traverseEnterLeave }; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -function two(num) { - if (num < 10) - return '0' + num; - else - return num; -} +/***/ }), +/* 282 */ +/***/ (function(module, exports, __webpack_require__) { -DERNode.prototype._encodeTime = function encodeTime(time, tag) { - var str; - var date = new Date(time); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if (tag === 'gentime') { - str = [ - two(date.getFullYear()), - two(date.getUTCMonth() + 1), - two(date.getUTCDate()), - two(date.getUTCHours()), - two(date.getUTCMinutes()), - two(date.getUTCSeconds()), - 'Z' - ].join(''); - } else if (tag === 'utctime') { - str = [ - two(date.getFullYear() % 100), - two(date.getUTCMonth() + 1), - two(date.getUTCDate()), - two(date.getUTCHours()), - two(date.getUTCMinutes()), - two(date.getUTCSeconds()), - 'Z' - ].join(''); - } else { - this.reporter.error('Encoding ' + tag + ' time is not supported yet'); - } - return this._encodeStr(str, 'octstr'); -}; -DERNode.prototype._encodeNull = function encodeNull() { - return this._createEncoderBuffer(''); -}; +var _prodInvariant = __webpack_require__(5), + _assign = __webpack_require__(8); + +var DOMChildrenOperations = __webpack_require__(82); +var DOMLazyTree = __webpack_require__(39); +var ReactDOMComponentTree = __webpack_require__(10); + +var escapeTextContentForBrowser = __webpack_require__(61); +var invariant = __webpack_require__(2); +var validateDOMNesting = __webpack_require__(91); + +/** + * Text nodes violate a couple assumptions that React makes about components: + * + * - When mounting text into the DOM, adjacent text nodes are merged. + * - Text nodes cannot be assigned a React root ID. + * + * This component is used to wrap strings between comment nodes so that they + * can undergo the same reconciliation that is applied to elements. + * + * TODO: Investigate representing React components in the DOM with text nodes. + * + * @class ReactDOMTextComponent + * @extends ReactComponent + * @internal + */ +var ReactDOMTextComponent = function (text) { + // TODO: This is really a ReactText (ReactNode), not a ReactElement + this._currentElement = text; + this._stringText = '' + text; + // ReactDOMComponentTree uses these: + this._hostNode = null; + this._hostParent = null; + + // Properties + this._domID = 0; + this._mountIndex = 0; + this._closingComment = null; + this._commentNodes = null; +}; + +_assign(ReactDOMTextComponent.prototype, { + /** + * Creates the markup for this text node. This node is not intended to have + * any features besides containing text content. + * + * @param {ReactReconcileTransaction|ReactServerRenderingTransaction} transaction + * @return {string} Markup for this text node. + * @internal + */ + mountComponent: function (transaction, hostParent, hostContainerInfo, context) { + if (process.env.NODE_ENV !== 'production') { + var parentInfo; + if (hostParent != null) { + parentInfo = hostParent._ancestorInfo; + } else if (hostContainerInfo != null) { + parentInfo = hostContainerInfo._ancestorInfo; + } + if (parentInfo) { + // parentInfo should always be present except for the top-level + // component when server rendering + validateDOMNesting(null, this._stringText, this, parentInfo); + } + } + + var domID = hostContainerInfo._idCounter++; + var openingValue = ' react-text: ' + domID + ' '; + var closingValue = ' /react-text '; + this._domID = domID; + this._hostParent = hostParent; + if (transaction.useCreateElement) { + var ownerDocument = hostContainerInfo._ownerDocument; + var openingComment = ownerDocument.createComment(openingValue); + var closingComment = ownerDocument.createComment(closingValue); + var lazyTree = DOMLazyTree(ownerDocument.createDocumentFragment()); + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(openingComment)); + if (this._stringText) { + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(ownerDocument.createTextNode(this._stringText))); + } + DOMLazyTree.queueChild(lazyTree, DOMLazyTree(closingComment)); + ReactDOMComponentTree.precacheNode(this, openingComment); + this._closingComment = closingComment; + return lazyTree; + } else { + var escapedText = escapeTextContentForBrowser(this._stringText); + + if (transaction.renderToStaticMarkup) { + // Normally we'd wrap this between comment nodes for the reasons stated + // above, but since this is a situation where React won't take over + // (static pages), we can simply return the text as it is. + return escapedText; + } + + return '<!--' + openingValue + '-->' + escapedText + '<!--' + closingValue + '-->'; + } + }, -DERNode.prototype._encodeInt = function encodeInt(num, values) { - if (typeof num === 'string') { - if (!values) - return this.reporter.error('String int or enum given, but no values map'); - if (!values.hasOwnProperty(num)) { - return this.reporter.error('Values map doesn\'t contain: ' + - JSON.stringify(num)); + /** + * Updates this component by updating the text content. + * + * @param {ReactText} nextText The next text content + * @param {ReactReconcileTransaction} transaction + * @internal + */ + receiveComponent: function (nextText, transaction) { + if (nextText !== this._currentElement) { + this._currentElement = nextText; + var nextStringText = '' + nextText; + if (nextStringText !== this._stringText) { + // TODO: Save this as pending props and use performUpdateIfNecessary + // and/or updateComponent to do the actual update for consistency with + // other component types? + this._stringText = nextStringText; + var commentNodes = this.getHostNode(); + DOMChildrenOperations.replaceDelimitedText(commentNodes[0], commentNodes[1], nextStringText); + } } - num = values[num]; - } + }, - // Bignum, assume big endian - if (typeof num !== 'number' && !Buffer.isBuffer(num)) { - var numArray = num.toArray(); - if (!num.sign && numArray[0] & 0x80) { - numArray.unshift(0); + getHostNode: function () { + var hostNode = this._commentNodes; + if (hostNode) { + return hostNode; } - num = new Buffer(numArray); + if (!this._closingComment) { + var openingComment = ReactDOMComponentTree.getNodeFromInstance(this); + var node = openingComment.nextSibling; + while (true) { + !(node != null) ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Missing closing comment for text component %s', this._domID) : _prodInvariant('67', this._domID) : void 0; + if (node.nodeType === 8 && node.nodeValue === ' /react-text ') { + this._closingComment = node; + break; + } + node = node.nextSibling; + } + } + hostNode = [this._hostNode, this._closingComment]; + this._commentNodes = hostNode; + return hostNode; + }, + + unmountComponent: function () { + this._closingComment = null; + this._commentNodes = null; + ReactDOMComponentTree.uncacheNode(this); } +}); - if (Buffer.isBuffer(num)) { - var size = num.length; - if (num.length === 0) - size++; +module.exports = ReactDOMTextComponent; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var out = new Buffer(size); - num.copy(out); - if (num.length === 0) - out[0] = 0 - return this._createEncoderBuffer(out); - } +/***/ }), +/* 283 */ +/***/ (function(module, exports, __webpack_require__) { - if (num < 0x80) - return this._createEncoderBuffer(num); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - if (num < 0x100) - return this._createEncoderBuffer([0, num]); - var size = 1; - for (var i = num; i >= 0x100; i >>= 8) - size++; - var out = new Array(size); - for (var i = out.length - 1; i >= 0; i--) { - out[i] = num & 0xff; - num >>= 8; - } - if(out[0] & 0x80) { - out.unshift(0); - } +var _assign = __webpack_require__(8); - return this._createEncoderBuffer(new Buffer(out)); -}; +var ReactUpdates = __webpack_require__(23); +var Transaction = __webpack_require__(58); -DERNode.prototype._encodeBool = function encodeBool(value) { - return this._createEncoderBuffer(value ? 0xff : 0); -}; +var emptyFunction = __webpack_require__(18); -DERNode.prototype._use = function use(entity, obj) { - if (typeof entity === 'function') - entity = entity(obj); - return entity._getEncoder('der').tree; +var RESET_BATCHED_UPDATES = { + initialize: emptyFunction, + close: function () { + ReactDefaultBatchingStrategy.isBatchingUpdates = false; + } }; -DERNode.prototype._skipDefault = function skipDefault(dataBuffer, reporter, parent) { - var state = this._baseState; - var i; - if (state['default'] === null) - return false; +var FLUSH_BATCHED_UPDATES = { + initialize: emptyFunction, + close: ReactUpdates.flushBatchedUpdates.bind(ReactUpdates) +}; - var data = dataBuffer.join(); - if (state.defaultBuffer === undefined) - state.defaultBuffer = this._encodeValue(state['default'], reporter, parent).join(); +var TRANSACTION_WRAPPERS = [FLUSH_BATCHED_UPDATES, RESET_BATCHED_UPDATES]; - if (data.length !== state.defaultBuffer.length) - return false; +function ReactDefaultBatchingStrategyTransaction() { + this.reinitializeTransaction(); +} - for (i=0; i < data.length; i++) - if (data[i] !== state.defaultBuffer[i]) - return false; +_assign(ReactDefaultBatchingStrategyTransaction.prototype, Transaction, { + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + } +}); - return true; -}; +var transaction = new ReactDefaultBatchingStrategyTransaction(); -// Utility methods +var ReactDefaultBatchingStrategy = { + isBatchingUpdates: false, -function encodeTag(tag, primitive, cls, reporter) { - var res; + /** + * Call the provided function in a context within which calls to `setState` + * and friends are batched such that components aren't updated unnecessarily. + */ + batchedUpdates: function (callback, a, b, c, d, e) { + var alreadyBatchingUpdates = ReactDefaultBatchingStrategy.isBatchingUpdates; - if (tag === 'seqof') - tag = 'seq'; - else if (tag === 'setof') - tag = 'set'; + ReactDefaultBatchingStrategy.isBatchingUpdates = true; - if (der.tagByName.hasOwnProperty(tag)) - res = der.tagByName[tag]; - else if (typeof tag === 'number' && (tag | 0) === tag) - res = tag; - else - return reporter.error('Unknown tag: ' + tag); + // The code is written this way to avoid extra allocations + if (alreadyBatchingUpdates) { + return callback(a, b, c, d, e); + } else { + return transaction.perform(callback, null, a, b, c, d, e); + } + } +}; - if (res >= 0x1f) - return reporter.error('Multi-octet tag encoding unsupported'); +module.exports = ReactDefaultBatchingStrategy; - if (!primitive) - res |= 0x20; +/***/ }), +/* 284 */ +/***/ (function(module, exports, __webpack_require__) { - res |= (der.tagClassByName[cls || 'universal'] << 6); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - return res; -} -/***/ }), -/* 341 */ -/***/ (function(module, exports) { +var _assign = __webpack_require__(8); -module.exports = { - "1.3.132.0.10": "secp256k1", - "1.3.132.0.33": "p224", - "1.2.840.10045.3.1.1": "p192", - "1.2.840.10045.3.1.7": "p256", - "1.3.132.0.34": "p384", - "1.3.132.0.35": "p521" -}; +var EventListener = __webpack_require__(146); +var ExecutionEnvironment = __webpack_require__(13); +var PooledClass = __webpack_require__(32); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactUpdates = __webpack_require__(23); -/***/ }), -/* 342 */ -/***/ (function(module, exports, __webpack_require__) { +var getEventTarget = __webpack_require__(79); +var getUnboundedScrollPosition = __webpack_require__(285); -/* WEBPACK VAR INJECTION */(function(Buffer) {var createHash = __webpack_require__(71); -module.exports = function (seed, len) { - var t = new Buffer(''); - var i = 0, c; - while (t.length < len) { - c = i2ops(i++); - t = Buffer.concat([t, createHash('sha1').update(seed).update(c).digest()]); +/** + * Find the deepest React component completely containing the root of the + * passed-in instance (for use when entire React trees are nested within each + * other). If React trees are not nested, returns null. + */ +function findParent(inst) { + // TODO: It may be a good idea to cache this to prevent unnecessary DOM + // traversal, but caching is difficult to do correctly without using a + // mutation observer to listen for all DOM changes. + while (inst._hostParent) { + inst = inst._hostParent; } - return t.slice(0, len); -}; + var rootNode = ReactDOMComponentTree.getNodeFromInstance(inst); + var container = rootNode.parentNode; + return ReactDOMComponentTree.getClosestInstanceFromNode(container); +} -function i2ops(c) { - var out = new Buffer(4); - out.writeUInt32BE(c,0); - return out; +// Used to store ancestor hierarchy in top level callback +function TopLevelCallbackBookKeeping(topLevelType, nativeEvent) { + this.topLevelType = topLevelType; + this.nativeEvent = nativeEvent; + this.ancestors = []; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +_assign(TopLevelCallbackBookKeeping.prototype, { + destructor: function () { + this.topLevelType = null; + this.nativeEvent = null; + this.ancestors.length = 0; + } +}); +PooledClass.addPoolingTo(TopLevelCallbackBookKeeping, PooledClass.twoArgumentPooler); -/***/ }), -/* 343 */ -/***/ (function(module, exports) { +function handleTopLevelImpl(bookKeeping) { + var nativeEventTarget = getEventTarget(bookKeeping.nativeEvent); + var targetInst = ReactDOMComponentTree.getClosestInstanceFromNode(nativeEventTarget); -module.exports = function xor(a, b) { - var len = a.length; - var i = -1; - while (++i < len) { - a[i] ^= b[i]; - } - return a -}; + // Loop through the hierarchy, in case there's any nested components. + // It's important that we build the array of ancestors before calling any + // event handlers, because event handlers can modify the DOM, leading to + // inconsistencies with ReactMount's node cache. See #1105. + var ancestor = targetInst; + do { + bookKeeping.ancestors.push(ancestor); + ancestor = ancestor && findParent(ancestor); + } while (ancestor); -/***/ }), -/* 344 */ -/***/ (function(module, exports, __webpack_require__) { + for (var i = 0; i < bookKeeping.ancestors.length; i++) { + targetInst = bookKeeping.ancestors[i]; + ReactEventListener._handleTopLevel(bookKeeping.topLevelType, targetInst, bookKeeping.nativeEvent, getEventTarget(bookKeeping.nativeEvent)); + } +} -/* WEBPACK VAR INJECTION */(function(Buffer) {var bn = __webpack_require__(23); -function withPublic(paddedMsg, key) { - return new Buffer(paddedMsg - .toRed(bn.mont(key.modulus)) - .redPow(new bn(key.publicExponent)) - .fromRed() - .toArray()); +function scrollValueMonitor(cb) { + var scrollPosition = getUnboundedScrollPosition(window); + cb(scrollPosition); } -module.exports = withPublic; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +var ReactEventListener = { + _enabled: true, + _handleTopLevel: null, -/***/ }), -/* 345 */ -/***/ (function(module, exports, __webpack_require__) { + WINDOW_HANDLE: ExecutionEnvironment.canUseDOM ? window : null, -/* WEBPACK VAR INJECTION */(function(Buffer) { + setHandleTopLevel: function (handleTopLevel) { + ReactEventListener._handleTopLevel = handleTopLevel; + }, -// https://github.com/bitcoinjs/bitcoinjs-lib/issues/14 -function numToBytes(num, bytes) { - if (bytes == 0) return [];else return [num % 256].concat(numToBytes(Math.floor(num / 256), bytes - 1)); -} + setEnabled: function (enabled) { + ReactEventListener._enabled = !!enabled; + }, -function numToVarInt(num) { - var b; - if (num < 253) b = [num];else if (num < 65536) b = [253].concat(numToBytes(num, 2));else if (num < 4294967296) b = [254].concat(numToBytes(num, 4));else b = [253].concat(numToBytes(num, 8)); - return Buffer.from(b).toString('hex'); -} + isEnabled: function () { + return ReactEventListener._enabled; + }, -// https://github.com/feross/buffer/blob/master/index.js#L1127 -function verifuint(value, max) { - if (typeof value !== 'number') { - throw new Error('cannot write a non-number as a number'); - } - if (value < 0) { - throw new Error('specified a negative value for writing an unsigned value'); - } - if (value > max) throw new Error('RangeError: value out of range'); - if (Math.floor(value) !== value) { - throw new Error('value has a fractional component'); - } -} + /** + * Traps top-level events by using event bubbling. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {string} handlerBaseName Event name (e.g. "click"). + * @param {object} element Element on which to attach listener. + * @return {?object} An object with a remove function which will forcefully + * remove the listener. + * @internal + */ + trapBubbledEvent: function (topLevelType, handlerBaseName, element) { + if (!element) { + return null; + } + return EventListener.listen(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); + }, -function readUInt64LE(buffer, offset) { - var a = buffer.readUInt32LE(offset); - var b = buffer.readUInt32LE(offset + 4); - b *= 0x100000000; + /** + * Traps a top-level event by using event capturing. + * + * @param {string} topLevelType Record from `EventConstants`. + * @param {string} handlerBaseName Event name (e.g. "click"). + * @param {object} element Element on which to attach listener. + * @return {?object} An object with a remove function which will forcefully + * remove the listener. + * @internal + */ + trapCapturedEvent: function (topLevelType, handlerBaseName, element) { + if (!element) { + return null; + } + return EventListener.capture(element, handlerBaseName, ReactEventListener.dispatchEvent.bind(null, topLevelType)); + }, - verifuint(b + a, 0x001fffffffffffff); + monitorScrollValue: function (refresh) { + var callback = scrollValueMonitor.bind(null, refresh); + EventListener.listen(window, 'scroll', callback); + }, - return b + a; -} + dispatchEvent: function (topLevelType, nativeEvent) { + if (!ReactEventListener._enabled) { + return; + } -function writeUInt64LE(buffer, value, offset) { - verifuint(value, 0x001fffffffffffff); + var bookKeeping = TopLevelCallbackBookKeeping.getPooled(topLevelType, nativeEvent); + try { + // Event queue being processed in the same cycle allows + // `preventDefault`. + ReactUpdates.batchedUpdates(handleTopLevelImpl, bookKeeping); + } finally { + TopLevelCallbackBookKeeping.release(bookKeeping); + } + } +}; - buffer.writeInt32LE(value & -1, offset); - buffer.writeUInt32LE(Math.floor(value / 0x100000000), offset + 4); - return offset + 8; -} +module.exports = ReactEventListener; -/* - * Given a hex string, get the length of it in bytes - * ** NOT string.length, but convert it into bytes - * and return the length of that in bytes in hex - * @param {String} hexStr - * return {String} Length of hexStr in bytes +/***/ }), +/* 285 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks */ -function getStringBufferLength(hexStr) { - const _tmpBuf = Buffer.from(hexStr, 'hex').length; - return Buffer.from([_tmpBuf]).toString('hex'); -} -module.exports = { - readUInt64LE: readUInt64LE, - writeUInt64LE: writeUInt64LE, - getStringBufferLength: getStringBufferLength, - numToVarInt: numToVarInt, - numToBytes: numToBytes -}; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) -/***/ }), -/* 346 */ -/***/ (function(module, exports, __webpack_require__) { -module.exports = { - Block: __webpack_require__(525), - ECPair: __webpack_require__(275), - ECSignature: __webpack_require__(277), - HDNode: __webpack_require__(553), - Transaction: __webpack_require__(274), - TransactionBuilder: __webpack_require__(554), +/** + * Gets the scroll position of the supplied element or window. + * + * The return values are unbounded, unlike `getScrollPosition`. This means they + * may be negative or exceed the element boundaries (which is possible using + * inertial scrolling). + * + * @param {DOMWindow|DOMElement} scrollable + * @return {object} Map with `x` and `y` keys. + */ - address: __webpack_require__(276), - bufferutils: __webpack_require__(352), // TODO: remove in 4.0.0 - crypto: __webpack_require__(116), - networks: __webpack_require__(242), - opcodes: __webpack_require__(37), - script: __webpack_require__(35) +function getUnboundedScrollPosition(scrollable) { + if (scrollable.Window && scrollable instanceof scrollable.Window) { + return { + x: scrollable.pageXOffset || scrollable.document.documentElement.scrollLeft, + y: scrollable.pageYOffset || scrollable.document.documentElement.scrollTop + }; + } + return { + x: scrollable.scrollLeft, + y: scrollable.scrollTop + }; } +module.exports = getUnboundedScrollPosition; /***/ }), -/* 347 */ +/* 286 */ /***/ (function(module, exports, __webpack_require__) { -var inherits = __webpack_require__(11) -var native = __webpack_require__(273) +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ + -function TfTypeError (type, value, valueTypeName) { - this.__error = Error.call(this) - this.__type = type - this.__value = value - this.__valueTypeName = valueTypeName - var message - Object.defineProperty(this, 'message', { - enumerable: true, - get: function () { - if (message) return message +var DOMProperty = __webpack_require__(28); +var EventPluginHub = __webpack_require__(46); +var EventPluginUtils = __webpack_require__(77); +var ReactComponentEnvironment = __webpack_require__(86); +var ReactEmptyComponent = __webpack_require__(143); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactHostComponent = __webpack_require__(144); +var ReactUpdates = __webpack_require__(23); - valueTypeName = valueTypeName || getValueTypeName(value) - message = tfErrorString(type, value, valueTypeName) +var ReactInjection = { + Component: ReactComponentEnvironment.injection, + DOMProperty: DOMProperty.injection, + EmptyComponent: ReactEmptyComponent.injection, + EventPluginHub: EventPluginHub.injection, + EventPluginUtils: EventPluginUtils.injection, + EventEmitter: ReactBrowserEventEmitter.injection, + HostComponent: ReactHostComponent.injection, + Updates: ReactUpdates.injection +}; - return message - } - }) -} +module.exports = ReactInjection; + +/***/ }), +/* 287 */ +/***/ (function(module, exports, __webpack_require__) { -function TfPropertyTypeError (type, property, label, value, error, valueTypeName) { - this.__error = error || Error.call(this) - this.__label = label - this.__property = property - this.__type = type - this.__value = value - this.__valueTypeName = valueTypeName +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var message - Object.defineProperty(this, 'message', { - enumerable: true, - get: function () { - if (message) return message - if (type) { - valueTypeName = valueTypeName || getValueTypeName(value) - message = tfPropertyErrorString(type, label, property, value, valueTypeName) - } else { - message = 'Unexpected property "' + property + '"' - } - return message - } - }) -} -// inherit from Error, assign stack -[TfTypeError, TfPropertyTypeError].forEach(function (tfErrorType) { - inherits(tfErrorType, Error) - Object.defineProperty(tfErrorType, 'stack', { - get: function () { return this.__error.stack } - }) -}) +var _assign = __webpack_require__(8); -function tfCustomError (expected, actual) { - return new TfTypeError(expected, {}, actual) -} +var CallbackQueue = __webpack_require__(130); +var PooledClass = __webpack_require__(32); +var ReactBrowserEventEmitter = __webpack_require__(62); +var ReactInputSelection = __webpack_require__(147); +var ReactInstrumentation = __webpack_require__(19); +var Transaction = __webpack_require__(58); +var ReactUpdateQueue = __webpack_require__(90); -function tfSubError (e, property, label) { - // sub child? - if (e instanceof TfPropertyTypeError) { - property = property + '.' + e.__property - label = e.__label +/** + * Ensures that, when possible, the selection range (currently selected text + * input) is not disturbed by performing the transaction. + */ +var SELECTION_RESTORATION = { + /** + * @return {Selection} Selection information. + */ + initialize: ReactInputSelection.getSelectionInformation, + /** + * @param {Selection} sel Selection information returned from `initialize`. + */ + close: ReactInputSelection.restoreSelection +}; - return new TfPropertyTypeError( - e.__type, property, label, e.__value, e.__error, e.__valueTypeName - ) +/** + * Suppresses events (blur/focus) that could be inadvertently dispatched due to + * high level DOM manipulations (like temporarily removing a text input from the + * DOM). + */ +var EVENT_SUPPRESSION = { + /** + * @return {boolean} The enabled status of `ReactBrowserEventEmitter` before + * the reconciliation. + */ + initialize: function () { + var currentlyEnabled = ReactBrowserEventEmitter.isEnabled(); + ReactBrowserEventEmitter.setEnabled(false); + return currentlyEnabled; + }, + + /** + * @param {boolean} previouslyEnabled Enabled status of + * `ReactBrowserEventEmitter` before the reconciliation occurred. `close` + * restores the previous value. + */ + close: function (previouslyEnabled) { + ReactBrowserEventEmitter.setEnabled(previouslyEnabled); } +}; - // child? - if (e instanceof TfTypeError) { - return new TfPropertyTypeError( - e.__type, property, label, e.__value, e.__error, e.__valueTypeName - ) +/** + * Provides a queue for collecting `componentDidMount` and + * `componentDidUpdate` callbacks during the transaction. + */ +var ON_DOM_READY_QUEUEING = { + /** + * Initializes the internal `onDOMReady` queue. + */ + initialize: function () { + this.reactMountReady.reset(); + }, + + /** + * After DOM is flushed, invoke all registered `onDOMReady` callbacks. + */ + close: function () { + this.reactMountReady.notifyAll(); } +}; - return e -} +/** + * Executed within the scope of the `Transaction` instance. Consider these as + * being member methods, but with an implied ordering while being isolated from + * each other. + */ +var TRANSACTION_WRAPPERS = [SELECTION_RESTORATION, EVENT_SUPPRESSION, ON_DOM_READY_QUEUEING]; -function getTypeName (fn) { - return fn.name || fn.toString().match(/function (.*?)\s*\(/)[1] +if (process.env.NODE_ENV !== 'production') { + TRANSACTION_WRAPPERS.push({ + initialize: ReactInstrumentation.debugTool.onBeginFlush, + close: ReactInstrumentation.debugTool.onEndFlush + }); } -function getValueTypeName (value) { - return native.Nil(value) ? '' : getTypeName(value.constructor) +/** + * Currently: + * - The order that these are listed in the transaction is critical: + * - Suppresses events. + * - Restores selection range. + * + * Future: + * - Restore document/overflow scroll positions that were unintentionally + * modified via DOM insertions above the top viewport boundary. + * - Implement/integrate with customized constraint based layout system and keep + * track of which dimensions must be remeasured. + * + * @class ReactReconcileTransaction + */ +function ReactReconcileTransaction(useCreateElement) { + this.reinitializeTransaction(); + // Only server-side rendering really needs this option (see + // `ReactServerRendering`), but server-side uses + // `ReactServerRenderingTransaction` instead. This option is here so that it's + // accessible and defaults to false when `ReactDOMComponent` and + // `ReactDOMTextComponent` checks it in `mountComponent`.` + this.renderToStaticMarkup = false; + this.reactMountReady = CallbackQueue.getPooled(null); + this.useCreateElement = useCreateElement; } -function getValue (value) { - if (native.Function(value)) return '' - if (native.String(value)) return JSON.stringify(value) - if (value && native.Object(value)) return '' - return value -} +var Mixin = { + /** + * @see Transaction + * @abstract + * @final + * @return {array<object>} List of operation wrap procedures. + * TODO: convert to array<TransactionWrapper> + */ + getTransactionWrappers: function () { + return TRANSACTION_WRAPPERS; + }, -function tfJSON (type) { - if (native.Function(type)) return type.toJSON ? type.toJSON() : getTypeName(type) - if (native.Array(type)) return 'Array' - if (type && native.Object(type)) return 'Object' + /** + * @return {object} The queue to collect `onDOMReady` callbacks with. + */ + getReactMountReady: function () { + return this.reactMountReady; + }, - return type !== undefined ? type : '' -} + /** + * @return {object} The queue to collect React async events. + */ + getUpdateQueue: function () { + return ReactUpdateQueue; + }, -function tfErrorString (type, value, valueTypeName) { - var valueJson = getValue(value) + /** + * Save current transaction state -- if the return value from this method is + * passed to `rollback`, the transaction will be reset to that state. + */ + checkpoint: function () { + // reactMountReady is the our only stateful wrapper + return this.reactMountReady.checkpoint(); + }, - return 'Expected ' + tfJSON(type) + ', got' + - (valueTypeName !== '' ? ' ' + valueTypeName : '') + - (valueJson !== '' ? ' ' + valueJson : '') -} + rollback: function (checkpoint) { + this.reactMountReady.rollback(checkpoint); + }, -function tfPropertyErrorString (type, label, name, value, valueTypeName) { - var description = '" of type ' - if (label === 'key') description = '" with key type ' + /** + * `PooledClass` looks for this, and will invoke this before allowing this + * instance to be reused. + */ + destructor: function () { + CallbackQueue.release(this.reactMountReady); + this.reactMountReady = null; + } +}; - return tfErrorString('property "' + tfJSON(name) + description + tfJSON(type), value, valueTypeName) -} +_assign(ReactReconcileTransaction.prototype, Transaction, Mixin); -module.exports = { - TfTypeError: TfTypeError, - TfPropertyTypeError: TfPropertyTypeError, - tfCustomError: tfCustomError, - tfSubError: tfSubError, - tfJSON: tfJSON, - getValueTypeName: getValueTypeName -} +PooledClass.addPoolingTo(ReactReconcileTransaction); +module.exports = ReactReconcileTransaction; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 348 */ +/* 288 */ /***/ (function(module, exports, __webpack_require__) { -var OPS = __webpack_require__(37) - -function encodingLength (i) { - return i < OPS.OP_PUSHDATA1 ? 1 - : i <= 0xff ? 2 - : i <= 0xffff ? 3 - : 5 -} - -function encode (buffer, number, offset) { - var size = encodingLength(number) +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // ~6 bit - if (size === 1) { - buffer.writeUInt8(number, offset) - // 8 bit - } else if (size === 2) { - buffer.writeUInt8(OPS.OP_PUSHDATA1, offset) - buffer.writeUInt8(number, offset + 1) - // 16 bit - } else if (size === 3) { - buffer.writeUInt8(OPS.OP_PUSHDATA2, offset) - buffer.writeUInt16LE(number, offset + 1) +var ExecutionEnvironment = __webpack_require__(13); - // 32 bit - } else { - buffer.writeUInt8(OPS.OP_PUSHDATA4, offset) - buffer.writeUInt32LE(number, offset + 1) - } +var getNodeForCharacterOffset = __webpack_require__(289); +var getTextContentAccessor = __webpack_require__(129); - return size +/** + * While `isCollapsed` is available on the Selection object and `collapsed` + * is available on the Range object, IE11 sometimes gets them wrong. + * If the anchor/focus nodes and offsets are the same, the range is collapsed. + */ +function isCollapsed(anchorNode, anchorOffset, focusNode, focusOffset) { + return anchorNode === focusNode && anchorOffset === focusOffset; } -function decode (buffer, offset) { - var opcode = buffer.readUInt8(offset) - var number, size +/** + * Get the appropriate anchor and focus node/offset pairs for IE. + * + * The catch here is that IE's selection API doesn't provide information + * about whether the selection is forward or backward, so we have to + * behave as though it's always forward. + * + * IE text differs from modern selection in that it behaves as though + * block elements end with a new line. This means character offsets will + * differ between the two APIs. + * + * @param {DOMElement} node + * @return {object} + */ +function getIEOffsets(node) { + var selection = document.selection; + var selectedRange = selection.createRange(); + var selectedLength = selectedRange.text.length; - // ~6 bit - if (opcode < OPS.OP_PUSHDATA1) { - number = opcode - size = 1 + // Duplicate selection so we can move range without breaking user selection. + var fromStart = selectedRange.duplicate(); + fromStart.moveToElementText(node); + fromStart.setEndPoint('EndToStart', selectedRange); - // 8 bit - } else if (opcode === OPS.OP_PUSHDATA1) { - if (offset + 2 > buffer.length) return null - number = buffer.readUInt8(offset + 1) - size = 2 + var startOffset = fromStart.text.length; + var endOffset = startOffset + selectedLength; - // 16 bit - } else if (opcode === OPS.OP_PUSHDATA2) { - if (offset + 3 > buffer.length) return null - number = buffer.readUInt16LE(offset + 1) - size = 3 + return { + start: startOffset, + end: endOffset + }; +} - // 32 bit - } else { - if (offset + 5 > buffer.length) return null - if (opcode !== OPS.OP_PUSHDATA4) throw new Error('Unexpected opcode') +/** + * @param {DOMElement} node + * @return {?object} + */ +function getModernOffsets(node) { + var selection = window.getSelection && window.getSelection(); - number = buffer.readUInt32LE(offset + 1) - size = 5 + if (!selection || selection.rangeCount === 0) { + return null; } - return { - opcode: opcode, - number: number, - size: size - } -} + var anchorNode = selection.anchorNode; + var anchorOffset = selection.anchorOffset; + var focusNode = selection.focusNode; + var focusOffset = selection.focusOffset; -module.exports = { - encodingLength: encodingLength, - encode: encode, - decode: decode -} + var currentRange = selection.getRangeAt(0); + // In Firefox, range.startContainer and range.endContainer can be "anonymous + // divs", e.g. the up/down buttons on an <input type="number">. Anonymous + // divs do not seem to expose properties, triggering a "Permission denied + // error" if any of its properties are accessed. The only seemingly possible + // way to avoid erroring is to access a property that typically works for + // non-anonymous divs and catch any error that may otherwise arise. See + // https://bugzilla.mozilla.org/show_bug.cgi?id=208427 + try { + /* eslint-disable no-unused-expressions */ + currentRange.startContainer.nodeType; + currentRange.endContainer.nodeType; + /* eslint-enable no-unused-expressions */ + } catch (e) { + return null; + } -/***/ }), -/* 349 */ -/***/ (function(module, exports, __webpack_require__) { + // If the node and offset values are the same, the selection is collapsed. + // `Selection.isCollapsed` is available natively, but IE sometimes gets + // this value wrong. + var isSelectionCollapsed = isCollapsed(selection.anchorNode, selection.anchorOffset, selection.focusNode, selection.focusOffset); -var Buffer = __webpack_require__(18).Buffer + var rangeLength = isSelectionCollapsed ? 0 : currentRange.toString().length; -function decode (buffer, maxLength, minimal) { - maxLength = maxLength || 4 - minimal = minimal === undefined ? true : minimal + var tempRange = currentRange.cloneRange(); + tempRange.selectNodeContents(node); + tempRange.setEnd(currentRange.startContainer, currentRange.startOffset); - var length = buffer.length - if (length === 0) return 0 - if (length > maxLength) throw new TypeError('Script number overflow') - if (minimal) { - if ((buffer[length - 1] & 0x7f) === 0) { - if (length <= 1 || (buffer[length - 2] & 0x80) === 0) throw new Error('Non-minimally encoded script number') - } - } + var isTempRangeCollapsed = isCollapsed(tempRange.startContainer, tempRange.startOffset, tempRange.endContainer, tempRange.endOffset); - // 40-bit - if (length === 5) { - var a = buffer.readUInt32LE(0) - var b = buffer.readUInt8(4) + var start = isTempRangeCollapsed ? 0 : tempRange.toString().length; + var end = start + rangeLength; - if (b & 0x80) return -(((b & ~0x80) * 0x100000000) + a) - return (b * 0x100000000) + a - } + // Detect whether the selection is backward. + var detectionRange = document.createRange(); + detectionRange.setStart(anchorNode, anchorOffset); + detectionRange.setEnd(focusNode, focusOffset); + var isBackward = detectionRange.collapsed; - var result = 0 + return { + start: isBackward ? end : start, + end: isBackward ? start : end + }; +} - // 32-bit / 24-bit / 16-bit / 8-bit - for (var i = 0; i < length; ++i) { - result |= buffer[i] << (8 * i) +/** + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ +function setIEOffsets(node, offsets) { + var range = document.selection.createRange().duplicate(); + var start, end; + + if (offsets.end === undefined) { + start = offsets.start; + end = start; + } else if (offsets.start > offsets.end) { + start = offsets.end; + end = offsets.start; + } else { + start = offsets.start; + end = offsets.end; } - if (buffer[length - 1] & 0x80) return -(result & ~(0x80 << (8 * (length - 1)))) - return result + range.moveToElementText(node); + range.moveStart('character', start); + range.setEndPoint('EndToStart', range); + range.moveEnd('character', end - start); + range.select(); } -function scriptNumSize (i) { - return i > 0x7fffffff ? 5 - : i > 0x7fffff ? 4 - : i > 0x7fff ? 3 - : i > 0x7f ? 2 - : i > 0x00 ? 1 - : 0 -} +/** + * In modern non-IE browsers, we can support both forward and backward + * selections. + * + * Note: IE10+ supports the Selection object, but it does not support + * the `extend` method, which means that even in modern IE, it's not possible + * to programmatically create a backward selection. Thus, for all IE + * versions, we use the old IE API to create our selections. + * + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ +function setModernOffsets(node, offsets) { + if (!window.getSelection) { + return; + } -function encode (number) { - var value = Math.abs(number) - var size = scriptNumSize(value) - var buffer = Buffer.allocUnsafe(size) - var negative = number < 0 + var selection = window.getSelection(); + var length = node[getTextContentAccessor()].length; + var start = Math.min(offsets.start, length); + var end = offsets.end === undefined ? start : Math.min(offsets.end, length); - for (var i = 0; i < size; ++i) { - buffer.writeUInt8(value & 0xff, i) - value >>= 8 + // IE 11 uses modern selection, but doesn't support the extend method. + // Flip backward selections, so we can set with a single range. + if (!selection.extend && start > end) { + var temp = end; + end = start; + start = temp; } - if (buffer[size - 1] & 0x80) { - buffer.writeUInt8(negative ? 0x80 : 0x00, size - 1) - } else if (negative) { - buffer[size - 1] |= 0x80 - } + var startMarker = getNodeForCharacterOffset(node, start); + var endMarker = getNodeForCharacterOffset(node, end); - return buffer -} + if (startMarker && endMarker) { + var range = document.createRange(); + range.setStart(startMarker.node, startMarker.offset); + selection.removeAllRanges(); -module.exports = { - decode: decode, - encode: encode + if (start > end) { + selection.addRange(range); + selection.extend(endMarker.node, endMarker.offset); + } else { + range.setEnd(endMarker.node, endMarker.offset); + selection.addRange(range); + } + } } +var useIEOffsets = ExecutionEnvironment.canUseDOM && 'selection' in document && !('getSelection' in window); + +var ReactDOMSelection = { + /** + * @param {DOMElement} node + */ + getOffsets: useIEOffsets ? getIEOffsets : getModernOffsets, + + /** + * @param {DOMElement|DOMTextNode} node + * @param {object} offsets + */ + setOffsets: useIEOffsets ? setIEOffsets : setModernOffsets +}; + +module.exports = ReactDOMSelection; /***/ }), -/* 350 */ +/* 289 */ /***/ (function(module, exports, __webpack_require__) { -// {signature} {pubKey} - -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -function check (script) { - var chunks = bscript.decompile(script) - return chunks.length === 2 && - bscript.isCanonicalSignature(chunks[0]) && - bscript.isCanonicalPubKey(chunks[1]) -} -check.toJSON = function () { return 'pubKeyHash input' } -function encodeStack (signature, pubKey) { - typeforce({ - signature: types.Buffer, pubKey: types.Buffer - }, { - signature: signature, pubKey: pubKey - }) +/** + * Given any node return the first leaf node without children. + * + * @param {DOMElement|DOMTextNode} node + * @return {DOMElement|DOMTextNode} + */ - return [signature, pubKey] +function getLeafNode(node) { + while (node && node.firstChild) { + node = node.firstChild; + } + return node; } -function encode (signature, pubKey) { - return bscript.compile(encodeStack(signature, pubKey)) +/** + * Get the next sibling within a container. This will walk up the + * DOM if a node's siblings have been exhausted. + * + * @param {DOMElement|DOMTextNode} node + * @return {?DOMElement|DOMTextNode} + */ +function getSiblingNode(node) { + while (node) { + if (node.nextSibling) { + return node.nextSibling; + } + node = node.parentNode; + } } -function decodeStack (stack) { - typeforce(check, stack) +/** + * Get object describing the nodes which contain characters at offset. + * + * @param {DOMElement|DOMTextNode} root + * @param {number} offset + * @return {?object} + */ +function getNodeForCharacterOffset(root, offset) { + var node = getLeafNode(root); + var nodeStart = 0; + var nodeEnd = 0; - return { - signature: stack[0], - pubKey: stack[1] - } -} + while (node) { + if (node.nodeType === 3) { + nodeEnd = nodeStart + node.textContent.length; -function decode (buffer) { - var stack = bscript.decompile(buffer) - return decodeStack(stack) -} + if (nodeStart <= offset && nodeEnd >= offset) { + return { + node: node, + offset: offset - nodeStart + }; + } -module.exports = { - check: check, - decode: decode, - decodeStack: decodeStack, - encode: encode, - encodeStack: encodeStack + nodeStart = nodeEnd; + } + + node = getLeafNode(getSiblingNode(node)); + } } +module.exports = getNodeForCharacterOffset; /***/ }), -/* 351 */ +/* 290 */ /***/ (function(module, exports, __webpack_require__) { -// <scriptSig> {serialized scriptPubKey script} - -var Buffer = __webpack_require__(18).Buffer -var bscript = __webpack_require__(35) -var typeforce = __webpack_require__(21) - -function check (script, allowIncomplete) { - var chunks = bscript.decompile(script) - if (chunks.length < 1) return false +"use strict"; - var lastChunk = chunks[chunks.length - 1] - if (!Buffer.isBuffer(lastChunk)) return false - var scriptSigChunks = bscript.decompile(bscript.compile(chunks.slice(0, -1))) - var redeemScriptChunks = bscript.decompile(lastChunk) +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - // is redeemScript a valid script? - if (redeemScriptChunks.length === 0) return false +var isTextNode = __webpack_require__(291); - // is redeemScriptSig push only? - if (!bscript.isPushOnly(scriptSigChunks)) return false +/*eslint-disable no-bitwise */ - var inputType = bscript.classifyInput(scriptSigChunks, allowIncomplete) - var outputType = bscript.classifyOutput(redeemScriptChunks) - if (chunks.length === 1) { - return outputType === bscript.types.P2WSH || outputType === bscript.types.P2WPKH +/** + * Checks if a given DOM node contains or is another DOM node. + */ +function containsNode(outerNode, innerNode) { + if (!outerNode || !innerNode) { + return false; + } else if (outerNode === innerNode) { + return true; + } else if (isTextNode(outerNode)) { + return false; + } else if (isTextNode(innerNode)) { + return containsNode(outerNode, innerNode.parentNode); + } else if ('contains' in outerNode) { + return outerNode.contains(innerNode); + } else if (outerNode.compareDocumentPosition) { + return !!(outerNode.compareDocumentPosition(innerNode) & 16); + } else { + return false; } - return inputType === outputType } -check.toJSON = function () { return 'scriptHash input' } - -function encodeStack (redeemScriptStack, redeemScript) { - var serializedScriptPubKey = bscript.compile(redeemScript) - return [].concat(redeemScriptStack, serializedScriptPubKey) -} +module.exports = containsNode; -function encode (redeemScriptSig, redeemScript) { - var redeemScriptStack = bscript.decompile(redeemScriptSig) +/***/ }), +/* 291 */ +/***/ (function(module, exports, __webpack_require__) { - return bscript.compile(encodeStack(redeemScriptStack, redeemScript)) -} +"use strict"; -function decodeStack (stack) { - typeforce(check, stack) - return { - redeemScriptStack: stack.slice(0, -1), - redeemScript: stack[stack.length - 1] - } -} +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ -function decode (buffer) { - var stack = bscript.decompile(buffer) - var result = decodeStack(stack) - result.redeemScriptSig = bscript.compile(result.redeemScriptStack) - delete result.redeemScriptStack - return result -} +var isNode = __webpack_require__(292); -module.exports = { - check: check, - decode: decode, - decodeStack: decodeStack, - encode: encode, - encodeStack: encodeStack +/** + * @param {*} object The object to check. + * @return {boolean} Whether or not the object is a DOM text node. + */ +function isTextNode(object) { + return isNode(object) && object.nodeType == 3; } +module.exports = isTextNode; /***/ }), -/* 352 */ +/* 292 */ /***/ (function(module, exports, __webpack_require__) { -var pushdata = __webpack_require__(348) -var varuint = __webpack_require__(255) +"use strict"; -// https://github.com/feross/buffer/blob/master/index.js#L1127 -function verifuint (value, max) { - if (typeof value !== 'number') throw new Error('cannot write a non-number as a number') - if (value < 0) throw new Error('specified a negative value for writing an unsigned value') - if (value > max) throw new Error('RangeError: value out of range') - if (Math.floor(value) !== value) throw new Error('value has a fractional component') + +/** + * Copyright (c) 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * @typechecks + */ + +/** + * @param {*} object The object to check. + * @return {boolean} Whether or not the object is a DOM node. + */ +function isNode(object) { + var doc = object ? object.ownerDocument || object : document; + var defaultView = doc.defaultView || window; + return !!(object && (typeof defaultView.Node === 'function' ? object instanceof defaultView.Node : typeof object === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string')); } -function readUInt64LE (buffer, offset) { - var a = buffer.readUInt32LE(offset) - var b = buffer.readUInt32LE(offset + 4) - b *= 0x100000000 +module.exports = isNode; - verifuint(b + a, 0x001fffffffffffff) +/***/ }), +/* 293 */ +/***/ (function(module, exports, __webpack_require__) { - return b + a -} +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -function writeUInt64LE (buffer, value, offset) { - verifuint(value, 0x001fffffffffffff) - buffer.writeInt32LE(value & -1, offset) - buffer.writeUInt32LE(Math.floor(value / 0x100000000), offset + 4) - return offset + 8 -} -// TODO: remove in 4.0.0? -function readVarInt (buffer, offset) { - var result = varuint.decode(buffer, offset) +var NS = { + xlink: 'http://www.w3.org/1999/xlink', + xml: 'http://www.w3.org/XML/1998/namespace' +}; + +// We use attributes for everything SVG so let's avoid some duplication and run +// code instead. +// The following are all specified in the HTML config already so we exclude here. +// - class (as className) +// - color +// - height +// - id +// - lang +// - max +// - media +// - method +// - min +// - name +// - style +// - target +// - type +// - width +var ATTRS = { + accentHeight: 'accent-height', + accumulate: 0, + additive: 0, + alignmentBaseline: 'alignment-baseline', + allowReorder: 'allowReorder', + alphabetic: 0, + amplitude: 0, + arabicForm: 'arabic-form', + ascent: 0, + attributeName: 'attributeName', + attributeType: 'attributeType', + autoReverse: 'autoReverse', + azimuth: 0, + baseFrequency: 'baseFrequency', + baseProfile: 'baseProfile', + baselineShift: 'baseline-shift', + bbox: 0, + begin: 0, + bias: 0, + by: 0, + calcMode: 'calcMode', + capHeight: 'cap-height', + clip: 0, + clipPath: 'clip-path', + clipRule: 'clip-rule', + clipPathUnits: 'clipPathUnits', + colorInterpolation: 'color-interpolation', + colorInterpolationFilters: 'color-interpolation-filters', + colorProfile: 'color-profile', + colorRendering: 'color-rendering', + contentScriptType: 'contentScriptType', + contentStyleType: 'contentStyleType', + cursor: 0, + cx: 0, + cy: 0, + d: 0, + decelerate: 0, + descent: 0, + diffuseConstant: 'diffuseConstant', + direction: 0, + display: 0, + divisor: 0, + dominantBaseline: 'dominant-baseline', + dur: 0, + dx: 0, + dy: 0, + edgeMode: 'edgeMode', + elevation: 0, + enableBackground: 'enable-background', + end: 0, + exponent: 0, + externalResourcesRequired: 'externalResourcesRequired', + fill: 0, + fillOpacity: 'fill-opacity', + fillRule: 'fill-rule', + filter: 0, + filterRes: 'filterRes', + filterUnits: 'filterUnits', + floodColor: 'flood-color', + floodOpacity: 'flood-opacity', + focusable: 0, + fontFamily: 'font-family', + fontSize: 'font-size', + fontSizeAdjust: 'font-size-adjust', + fontStretch: 'font-stretch', + fontStyle: 'font-style', + fontVariant: 'font-variant', + fontWeight: 'font-weight', + format: 0, + from: 0, + fx: 0, + fy: 0, + g1: 0, + g2: 0, + glyphName: 'glyph-name', + glyphOrientationHorizontal: 'glyph-orientation-horizontal', + glyphOrientationVertical: 'glyph-orientation-vertical', + glyphRef: 'glyphRef', + gradientTransform: 'gradientTransform', + gradientUnits: 'gradientUnits', + hanging: 0, + horizAdvX: 'horiz-adv-x', + horizOriginX: 'horiz-origin-x', + ideographic: 0, + imageRendering: 'image-rendering', + 'in': 0, + in2: 0, + intercept: 0, + k: 0, + k1: 0, + k2: 0, + k3: 0, + k4: 0, + kernelMatrix: 'kernelMatrix', + kernelUnitLength: 'kernelUnitLength', + kerning: 0, + keyPoints: 'keyPoints', + keySplines: 'keySplines', + keyTimes: 'keyTimes', + lengthAdjust: 'lengthAdjust', + letterSpacing: 'letter-spacing', + lightingColor: 'lighting-color', + limitingConeAngle: 'limitingConeAngle', + local: 0, + markerEnd: 'marker-end', + markerMid: 'marker-mid', + markerStart: 'marker-start', + markerHeight: 'markerHeight', + markerUnits: 'markerUnits', + markerWidth: 'markerWidth', + mask: 0, + maskContentUnits: 'maskContentUnits', + maskUnits: 'maskUnits', + mathematical: 0, + mode: 0, + numOctaves: 'numOctaves', + offset: 0, + opacity: 0, + operator: 0, + order: 0, + orient: 0, + orientation: 0, + origin: 0, + overflow: 0, + overlinePosition: 'overline-position', + overlineThickness: 'overline-thickness', + paintOrder: 'paint-order', + panose1: 'panose-1', + pathLength: 'pathLength', + patternContentUnits: 'patternContentUnits', + patternTransform: 'patternTransform', + patternUnits: 'patternUnits', + pointerEvents: 'pointer-events', + points: 0, + pointsAtX: 'pointsAtX', + pointsAtY: 'pointsAtY', + pointsAtZ: 'pointsAtZ', + preserveAlpha: 'preserveAlpha', + preserveAspectRatio: 'preserveAspectRatio', + primitiveUnits: 'primitiveUnits', + r: 0, + radius: 0, + refX: 'refX', + refY: 'refY', + renderingIntent: 'rendering-intent', + repeatCount: 'repeatCount', + repeatDur: 'repeatDur', + requiredExtensions: 'requiredExtensions', + requiredFeatures: 'requiredFeatures', + restart: 0, + result: 0, + rotate: 0, + rx: 0, + ry: 0, + scale: 0, + seed: 0, + shapeRendering: 'shape-rendering', + slope: 0, + spacing: 0, + specularConstant: 'specularConstant', + specularExponent: 'specularExponent', + speed: 0, + spreadMethod: 'spreadMethod', + startOffset: 'startOffset', + stdDeviation: 'stdDeviation', + stemh: 0, + stemv: 0, + stitchTiles: 'stitchTiles', + stopColor: 'stop-color', + stopOpacity: 'stop-opacity', + strikethroughPosition: 'strikethrough-position', + strikethroughThickness: 'strikethrough-thickness', + string: 0, + stroke: 0, + strokeDasharray: 'stroke-dasharray', + strokeDashoffset: 'stroke-dashoffset', + strokeLinecap: 'stroke-linecap', + strokeLinejoin: 'stroke-linejoin', + strokeMiterlimit: 'stroke-miterlimit', + strokeOpacity: 'stroke-opacity', + strokeWidth: 'stroke-width', + surfaceScale: 'surfaceScale', + systemLanguage: 'systemLanguage', + tableValues: 'tableValues', + targetX: 'targetX', + targetY: 'targetY', + textAnchor: 'text-anchor', + textDecoration: 'text-decoration', + textRendering: 'text-rendering', + textLength: 'textLength', + to: 0, + transform: 0, + u1: 0, + u2: 0, + underlinePosition: 'underline-position', + underlineThickness: 'underline-thickness', + unicode: 0, + unicodeBidi: 'unicode-bidi', + unicodeRange: 'unicode-range', + unitsPerEm: 'units-per-em', + vAlphabetic: 'v-alphabetic', + vHanging: 'v-hanging', + vIdeographic: 'v-ideographic', + vMathematical: 'v-mathematical', + values: 0, + vectorEffect: 'vector-effect', + version: 0, + vertAdvY: 'vert-adv-y', + vertOriginX: 'vert-origin-x', + vertOriginY: 'vert-origin-y', + viewBox: 'viewBox', + viewTarget: 'viewTarget', + visibility: 0, + widths: 0, + wordSpacing: 'word-spacing', + writingMode: 'writing-mode', + x: 0, + xHeight: 'x-height', + x1: 0, + x2: 0, + xChannelSelector: 'xChannelSelector', + xlinkActuate: 'xlink:actuate', + xlinkArcrole: 'xlink:arcrole', + xlinkHref: 'xlink:href', + xlinkRole: 'xlink:role', + xlinkShow: 'xlink:show', + xlinkTitle: 'xlink:title', + xlinkType: 'xlink:type', + xmlBase: 'xml:base', + xmlns: 0, + xmlnsXlink: 'xmlns:xlink', + xmlLang: 'xml:lang', + xmlSpace: 'xml:space', + y: 0, + y1: 0, + y2: 0, + yChannelSelector: 'yChannelSelector', + z: 0, + zoomAndPan: 'zoomAndPan' +}; + +var SVGDOMPropertyConfig = { + Properties: {}, + DOMAttributeNamespaces: { + xlinkActuate: NS.xlink, + xlinkArcrole: NS.xlink, + xlinkHref: NS.xlink, + xlinkRole: NS.xlink, + xlinkShow: NS.xlink, + xlinkTitle: NS.xlink, + xlinkType: NS.xlink, + xmlBase: NS.xml, + xmlLang: NS.xml, + xmlSpace: NS.xml + }, + DOMAttributeNames: {} +}; - return { - number: result, - size: varuint.decode.bytes +Object.keys(ATTRS).forEach(function (key) { + SVGDOMPropertyConfig.Properties[key] = 0; + if (ATTRS[key]) { + SVGDOMPropertyConfig.DOMAttributeNames[key] = ATTRS[key]; } -} - -// TODO: remove in 4.0.0? -function writeVarInt (buffer, number, offset) { - varuint.encode(number, buffer, offset) - return varuint.encode.bytes -} - -module.exports = { - pushDataSize: pushdata.encodingLength, - readPushDataInt: pushdata.decode, - readUInt64LE: readUInt64LE, - readVarInt: readVarInt, - varIntBuffer: varuint.encode, - varIntSize: varuint.encodingLength, - writePushDataInt: pushdata.encode, - writeUInt64LE: writeUInt64LE, - writeVarInt: writeVarInt -} +}); +module.exports = SVGDOMPropertyConfig; /***/ }), -/* 353 */ +/* 294 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var assert = __webpack_require__(268) -var BigInteger = __webpack_require__(110) +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var THREE = BigInteger.valueOf(3) -function Point (curve, x, y, z) { - assert.notStrictEqual(z, undefined, 'Missing Z coordinate') - this.curve = curve - this.x = x - this.y = y - this.z = z - this._zInv = null +var EventPropagators = __webpack_require__(45); +var ExecutionEnvironment = __webpack_require__(13); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInputSelection = __webpack_require__(147); +var SyntheticEvent = __webpack_require__(26); - this.compressed = true -} +var getActiveElement = __webpack_require__(148); +var isTextInputElement = __webpack_require__(133); +var shallowEqual = __webpack_require__(87); -Object.defineProperty(Point.prototype, 'zInv', { - get: function () { - if (this._zInv === null) { - this._zInv = this.z.modInverse(this.curve.p) - } +var skipSelectionChangeEvent = ExecutionEnvironment.canUseDOM && 'documentMode' in document && document.documentMode <= 11; - return this._zInv +var eventTypes = { + select: { + phasedRegistrationNames: { + bubbled: 'onSelect', + captured: 'onSelectCapture' + }, + dependencies: ['topBlur', 'topContextMenu', 'topFocus', 'topKeyDown', 'topKeyUp', 'topMouseDown', 'topMouseUp', 'topSelectionChange'] } -}) +}; -Object.defineProperty(Point.prototype, 'affineX', { - get: function () { - return this.x.multiply(this.zInv).mod(this.curve.p) - } -}) +var activeElement = null; +var activeElementInst = null; +var lastSelection = null; +var mouseDown = false; -Object.defineProperty(Point.prototype, 'affineY', { - get: function () { - return this.y.multiply(this.zInv).mod(this.curve.p) - } -}) +// Track whether a listener exists for this plugin. If none exist, we do +// not extract events. See #3639. +var hasListener = false; -Point.fromAffine = function (curve, x, y) { - return new Point(curve, x, y, BigInteger.ONE) +/** + * Get an object which is a unique representation of the current selection. + * + * The return value will not be consistent across nodes or browsers, but + * two identical selections on the same node will return identical objects. + * + * @param {DOMElement} node + * @return {object} + */ +function getSelection(node) { + if ('selectionStart' in node && ReactInputSelection.hasSelectionCapabilities(node)) { + return { + start: node.selectionStart, + end: node.selectionEnd + }; + } else if (window.getSelection) { + var selection = window.getSelection(); + return { + anchorNode: selection.anchorNode, + anchorOffset: selection.anchorOffset, + focusNode: selection.focusNode, + focusOffset: selection.focusOffset + }; + } else if (document.selection) { + var range = document.selection.createRange(); + return { + parentElement: range.parentElement(), + text: range.text, + top: range.boundingTop, + left: range.boundingLeft + }; + } } -Point.prototype.equals = function (other) { - if (other === this) return true - if (this.curve.isInfinity(this)) return this.curve.isInfinity(other) - if (this.curve.isInfinity(other)) return this.curve.isInfinity(this) +/** + * Poll selection to see whether it's changed. + * + * @param {object} nativeEvent + * @return {?SyntheticEvent} + */ +function constructSelectEvent(nativeEvent, nativeEventTarget) { + // Ensure we have the right element, and that the user is not dragging a + // selection (this matches native `select` event behavior). In HTML5, select + // fires only on input and textarea thus if there's no focused element we + // won't dispatch. + if (mouseDown || activeElement == null || activeElement !== getActiveElement()) { + return null; + } - // u = Y2 * Z1 - Y1 * Z2 - var u = other.y.multiply(this.z).subtract(this.y.multiply(other.z)).mod(this.curve.p) + // Only fire when selection has actually changed. + var currentSelection = getSelection(activeElement); + if (!lastSelection || !shallowEqual(lastSelection, currentSelection)) { + lastSelection = currentSelection; - if (u.signum() !== 0) return false + var syntheticEvent = SyntheticEvent.getPooled(eventTypes.select, activeElementInst, nativeEvent, nativeEventTarget); - // v = X2 * Z1 - X1 * Z2 - var v = other.x.multiply(this.z).subtract(this.x.multiply(other.z)).mod(this.curve.p) + syntheticEvent.type = 'select'; + syntheticEvent.target = activeElement; - return v.signum() === 0 -} + EventPropagators.accumulateTwoPhaseDispatches(syntheticEvent); -Point.prototype.negate = function () { - var y = this.curve.p.subtract(this.y) + return syntheticEvent; + } - return new Point(this.curve, this.x, y, this.z) + return null; } -Point.prototype.add = function (b) { - if (this.curve.isInfinity(this)) return b - if (this.curve.isInfinity(b)) return this - - var x1 = this.x - var y1 = this.y - var x2 = b.x - var y2 = b.y - - // u = Y2 * Z1 - Y1 * Z2 - var u = y2.multiply(this.z).subtract(y1.multiply(b.z)).mod(this.curve.p) - // v = X2 * Z1 - X1 * Z2 - var v = x2.multiply(this.z).subtract(x1.multiply(b.z)).mod(this.curve.p) +/** + * This plugin creates an `onSelect` event that normalizes select events + * across form elements. + * + * Supported elements are: + * - input (see `isTextInputElement`) + * - textarea + * - contentEditable + * + * This differs from native browser implementations in the following ways: + * - Fires on contentEditable fields as well as inputs. + * - Fires for collapsed selection. + * - Fires after user input. + */ +var SelectEventPlugin = { + eventTypes: eventTypes, - if (v.signum() === 0) { - if (u.signum() === 0) { - return this.twice() // this == b, so double + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + if (!hasListener) { + return null; } - return this.curve.infinity // this = -b, so infinity - } - - var v2 = v.square() - var v3 = v2.multiply(v) - var x1v2 = x1.multiply(v2) - var zu2 = u.square().multiply(this.z) - - // x3 = v * (z2 * (z1 * u^2 - 2 * x1 * v^2) - v^3) - var x3 = zu2.subtract(x1v2.shiftLeft(1)).multiply(b.z).subtract(v3).multiply(v).mod(this.curve.p) - // y3 = z2 * (3 * x1 * u * v^2 - y1 * v^3 - z1 * u^3) + u * v^3 - var y3 = x1v2.multiply(THREE).multiply(u).subtract(y1.multiply(v3)).subtract(zu2.multiply(u)).multiply(b.z).add(u.multiply(v3)).mod(this.curve.p) - // z3 = v^3 * z1 * z2 - var z3 = v3.multiply(this.z).multiply(b.z).mod(this.curve.p) + var targetNode = targetInst ? ReactDOMComponentTree.getNodeFromInstance(targetInst) : window; - return new Point(this.curve, x3, y3, z3) -} + switch (topLevelType) { + // Track the input node that has focus. + case 'topFocus': + if (isTextInputElement(targetNode) || targetNode.contentEditable === 'true') { + activeElement = targetNode; + activeElementInst = targetInst; + lastSelection = null; + } + break; + case 'topBlur': + activeElement = null; + activeElementInst = null; + lastSelection = null; + break; + // Don't fire the event while the user is dragging. This matches the + // semantics of the native select event. + case 'topMouseDown': + mouseDown = true; + break; + case 'topContextMenu': + case 'topMouseUp': + mouseDown = false; + return constructSelectEvent(nativeEvent, nativeEventTarget); + // Chrome and IE fire non-standard event when selection is changed (and + // sometimes when it hasn't). IE's event fires out of order with respect + // to key and input events on deletion, so we discard it. + // + // Firefox doesn't support selectionchange, so check selection status + // after each key entry. The selection changes after keydown and before + // keyup, but we check on keydown as well in the case of holding down a + // key, when multiple keydown events are fired but only one keyup is. + // This is also our approach for IE handling, for the reason above. + case 'topSelectionChange': + if (skipSelectionChangeEvent) { + break; + } + // falls through + case 'topKeyDown': + case 'topKeyUp': + return constructSelectEvent(nativeEvent, nativeEventTarget); + } -Point.prototype.twice = function () { - if (this.curve.isInfinity(this)) return this - if (this.y.signum() === 0) return this.curve.infinity + return null; + }, - var x1 = this.x - var y1 = this.y + didPutListener: function (inst, registrationName, listener) { + if (registrationName === 'onSelect') { + hasListener = true; + } + } +}; - var y1z1 = y1.multiply(this.z).mod(this.curve.p) - var y1sqz1 = y1z1.multiply(y1).mod(this.curve.p) - var a = this.curve.a +module.exports = SelectEventPlugin; - // w = 3 * x1^2 + a * z1^2 - var w = x1.square().multiply(THREE) +/***/ }), +/* 295 */ +/***/ (function(module, exports, __webpack_require__) { - if (a.signum() !== 0) { - w = w.add(this.z.square().multiply(a)) - } +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - w = w.mod(this.curve.p) - // x3 = 2 * y1 * z1 * (w^2 - 8 * x1 * y1^2 * z1) - var x3 = w.square().subtract(x1.shiftLeft(3).multiply(y1sqz1)).shiftLeft(1).multiply(y1z1).mod(this.curve.p) - // y3 = 4 * y1^2 * z1 * (3 * w * x1 - 2 * y1^2 * z1) - w^3 - var y3 = w.multiply(THREE).multiply(x1).subtract(y1sqz1.shiftLeft(1)).shiftLeft(2).multiply(y1sqz1).subtract(w.pow(3)).mod(this.curve.p) - // z3 = 8 * (y1 * z1)^3 - var z3 = y1z1.pow(3).shiftLeft(3).mod(this.curve.p) - return new Point(this.curve, x3, y3, z3) -} -// Simple NAF (Non-Adjacent Form) multiplication algorithm -// TODO: modularize the multiplication algorithm -Point.prototype.multiply = function (k) { - if (this.curve.isInfinity(this)) return this - if (k.signum() === 0) return this.curve.infinity +var _prodInvariant = __webpack_require__(5); - var e = k - var h = e.multiply(THREE) +var EventListener = __webpack_require__(146); +var EventPropagators = __webpack_require__(45); +var ReactDOMComponentTree = __webpack_require__(10); +var SyntheticAnimationEvent = __webpack_require__(296); +var SyntheticClipboardEvent = __webpack_require__(297); +var SyntheticEvent = __webpack_require__(26); +var SyntheticFocusEvent = __webpack_require__(298); +var SyntheticKeyboardEvent = __webpack_require__(299); +var SyntheticMouseEvent = __webpack_require__(59); +var SyntheticDragEvent = __webpack_require__(301); +var SyntheticTouchEvent = __webpack_require__(302); +var SyntheticTransitionEvent = __webpack_require__(303); +var SyntheticUIEvent = __webpack_require__(47); +var SyntheticWheelEvent = __webpack_require__(304); - var neg = this.negate() - var R = this +var emptyFunction = __webpack_require__(18); +var getEventCharCode = __webpack_require__(92); +var invariant = __webpack_require__(2); - for (var i = h.bitLength() - 2; i > 0; --i) { - var hBit = h.testBit(i) - var eBit = e.testBit(i) +/** + * Turns + * ['abort', ...] + * into + * eventTypes = { + * 'abort': { + * phasedRegistrationNames: { + * bubbled: 'onAbort', + * captured: 'onAbortCapture', + * }, + * dependencies: ['topAbort'], + * }, + * ... + * }; + * topLevelEventsToDispatchConfig = { + * 'topAbort': { sameConfig } + * }; + */ +var eventTypes = {}; +var topLevelEventsToDispatchConfig = {}; +['abort', 'animationEnd', 'animationIteration', 'animationStart', 'blur', 'canPlay', 'canPlayThrough', 'click', 'contextMenu', 'copy', 'cut', 'doubleClick', 'drag', 'dragEnd', 'dragEnter', 'dragExit', 'dragLeave', 'dragOver', 'dragStart', 'drop', 'durationChange', 'emptied', 'encrypted', 'ended', 'error', 'focus', 'input', 'invalid', 'keyDown', 'keyPress', 'keyUp', 'load', 'loadedData', 'loadedMetadata', 'loadStart', 'mouseDown', 'mouseMove', 'mouseOut', 'mouseOver', 'mouseUp', 'paste', 'pause', 'play', 'playing', 'progress', 'rateChange', 'reset', 'scroll', 'seeked', 'seeking', 'stalled', 'submit', 'suspend', 'timeUpdate', 'touchCancel', 'touchEnd', 'touchMove', 'touchStart', 'transitionEnd', 'volumeChange', 'waiting', 'wheel'].forEach(function (event) { + var capitalizedEvent = event[0].toUpperCase() + event.slice(1); + var onEvent = 'on' + capitalizedEvent; + var topEvent = 'top' + capitalizedEvent; - R = R.twice() + var type = { + phasedRegistrationNames: { + bubbled: onEvent, + captured: onEvent + 'Capture' + }, + dependencies: [topEvent] + }; + eventTypes[event] = type; + topLevelEventsToDispatchConfig[topEvent] = type; +}); - if (hBit !== eBit) { - R = R.add(hBit ? this : neg) - } - } +var onClickListeners = {}; - return R +function getDictionaryKey(inst) { + // Prevents V8 performance issue: + // https://github.com/facebook/react/pull/7232 + return '.' + inst._rootNodeID; } -// Compute this*j + x*k (simultaneous multiplication) -Point.prototype.multiplyTwo = function (j, x, k) { - var i = Math.max(j.bitLength(), k.bitLength()) - 1 - var R = this.curve.infinity - var both = this.add(x) +function isInteractive(tag) { + return tag === 'button' || tag === 'input' || tag === 'select' || tag === 'textarea'; +} - while (i >= 0) { - var jBit = j.testBit(i) - var kBit = k.testBit(i) +var SimpleEventPlugin = { + eventTypes: eventTypes, - R = R.twice() + extractEvents: function (topLevelType, targetInst, nativeEvent, nativeEventTarget) { + var dispatchConfig = topLevelEventsToDispatchConfig[topLevelType]; + if (!dispatchConfig) { + return null; + } + var EventConstructor; + switch (topLevelType) { + case 'topAbort': + case 'topCanPlay': + case 'topCanPlayThrough': + case 'topDurationChange': + case 'topEmptied': + case 'topEncrypted': + case 'topEnded': + case 'topError': + case 'topInput': + case 'topInvalid': + case 'topLoad': + case 'topLoadedData': + case 'topLoadedMetadata': + case 'topLoadStart': + case 'topPause': + case 'topPlay': + case 'topPlaying': + case 'topProgress': + case 'topRateChange': + case 'topReset': + case 'topSeeked': + case 'topSeeking': + case 'topStalled': + case 'topSubmit': + case 'topSuspend': + case 'topTimeUpdate': + case 'topVolumeChange': + case 'topWaiting': + // HTML Events + // @see http://www.w3.org/TR/html5/index.html#events-0 + EventConstructor = SyntheticEvent; + break; + case 'topKeyPress': + // Firefox creates a keypress event for function keys too. This removes + // the unwanted keypress events. Enter is however both printable and + // non-printable. One would expect Tab to be as well (but it isn't). + if (getEventCharCode(nativeEvent) === 0) { + return null; + } + /* falls through */ + case 'topKeyDown': + case 'topKeyUp': + EventConstructor = SyntheticKeyboardEvent; + break; + case 'topBlur': + case 'topFocus': + EventConstructor = SyntheticFocusEvent; + break; + case 'topClick': + // Firefox creates a click event on right mouse clicks. This removes the + // unwanted click events. + if (nativeEvent.button === 2) { + return null; + } + /* falls through */ + case 'topDoubleClick': + case 'topMouseDown': + case 'topMouseMove': + case 'topMouseUp': + // TODO: Disabled elements should not respond to mouse events + /* falls through */ + case 'topMouseOut': + case 'topMouseOver': + case 'topContextMenu': + EventConstructor = SyntheticMouseEvent; + break; + case 'topDrag': + case 'topDragEnd': + case 'topDragEnter': + case 'topDragExit': + case 'topDragLeave': + case 'topDragOver': + case 'topDragStart': + case 'topDrop': + EventConstructor = SyntheticDragEvent; + break; + case 'topTouchCancel': + case 'topTouchEnd': + case 'topTouchMove': + case 'topTouchStart': + EventConstructor = SyntheticTouchEvent; + break; + case 'topAnimationEnd': + case 'topAnimationIteration': + case 'topAnimationStart': + EventConstructor = SyntheticAnimationEvent; + break; + case 'topTransitionEnd': + EventConstructor = SyntheticTransitionEvent; + break; + case 'topScroll': + EventConstructor = SyntheticUIEvent; + break; + case 'topWheel': + EventConstructor = SyntheticWheelEvent; + break; + case 'topCopy': + case 'topCut': + case 'topPaste': + EventConstructor = SyntheticClipboardEvent; + break; + } + !EventConstructor ? process.env.NODE_ENV !== 'production' ? invariant(false, 'SimpleEventPlugin: Unhandled event type, `%s`.', topLevelType) : _prodInvariant('86', topLevelType) : void 0; + var event = EventConstructor.getPooled(dispatchConfig, targetInst, nativeEvent, nativeEventTarget); + EventPropagators.accumulateTwoPhaseDispatches(event); + return event; + }, - if (jBit) { - if (kBit) { - R = R.add(both) - } else { - R = R.add(this) + didPutListener: function (inst, registrationName, listener) { + // Mobile Safari does not fire properly bubble click events on + // non-interactive elements, which means delegated click listeners do not + // fire. The workaround for this bug involves attaching an empty click + // listener on the target node. + // http://www.quirksmode.org/blog/archives/2010/09/click_event_del.html + if (registrationName === 'onClick' && !isInteractive(inst._tag)) { + var key = getDictionaryKey(inst); + var node = ReactDOMComponentTree.getNodeFromInstance(inst); + if (!onClickListeners[key]) { + onClickListeners[key] = EventListener.listen(node, 'click', emptyFunction); } - } else if (kBit) { - R = R.add(x) } - --i - } - - return R -} - -Point.prototype.getEncoded = function (compressed) { - if (compressed == null) compressed = this.compressed - if (this.curve.isInfinity(this)) return new Buffer('00', 'hex') // Infinity point encoded is simply '00' - - var x = this.affineX - var y = this.affineY - var byteLength = this.curve.pLength - var buffer - - // 0x02/0x03 | X - if (compressed) { - buffer = new Buffer(1 + byteLength) - buffer.writeUInt8(y.isEven() ? 0x02 : 0x03, 0) - - // 0x04 | X | Y - } else { - buffer = new Buffer(1 + byteLength + byteLength) - buffer.writeUInt8(0x04, 0) + }, - y.toBuffer(byteLength).copy(buffer, 1 + byteLength) + willDeleteListener: function (inst, registrationName) { + if (registrationName === 'onClick' && !isInteractive(inst._tag)) { + var key = getDictionaryKey(inst); + onClickListeners[key].remove(); + delete onClickListeners[key]; + } } +}; - x.toBuffer(byteLength).copy(buffer, 1) - - return buffer -} - -Point.decodeFrom = function (curve, buffer) { - var type = buffer.readUInt8(0) - var compressed = (type !== 4) +module.exports = SimpleEventPlugin; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - var byteLength = Math.floor((curve.p.bitLength() + 7) / 8) - var x = BigInteger.fromBuffer(buffer.slice(1, 1 + byteLength)) +/***/ }), +/* 296 */ +/***/ (function(module, exports, __webpack_require__) { - var Q - if (compressed) { - assert.equal(buffer.length, byteLength + 1, 'Invalid sequence length') - assert(type === 0x02 || type === 0x03, 'Invalid sequence tag') +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var isOdd = (type === 0x03) - Q = curve.pointFromX(isOdd, x) - } else { - assert.equal(buffer.length, 1 + byteLength + byteLength, 'Invalid sequence length') - var y = BigInteger.fromBuffer(buffer.slice(1 + byteLength)) - Q = Point.fromAffine(curve, x, y) - } - Q.compressed = compressed - return Q -} +var SyntheticEvent = __webpack_require__(26); -Point.prototype.toString = function () { - if (this.curve.isInfinity(this)) return '(INFINITY)' +/** + * @interface Event + * @see http://www.w3.org/TR/css3-animations/#AnimationEvent-interface + * @see https://developer.mozilla.org/en-US/docs/Web/API/AnimationEvent + */ +var AnimationEventInterface = { + animationName: null, + elapsedTime: null, + pseudoElement: null +}; - return '(' + this.affineX.toString() + ',' + this.affineY.toString() + ')' +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticAnimationEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); } -module.exports = Point +SyntheticEvent.augmentClass(SyntheticAnimationEvent, AnimationEventInterface); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +module.exports = SyntheticAnimationEvent; /***/ }), -/* 354 */ +/* 297 */ /***/ (function(module, exports, __webpack_require__) { -var assert = __webpack_require__(268) -var BigInteger = __webpack_require__(110) - -var Point = __webpack_require__(353) - -function Curve (p, a, b, Gx, Gy, n, h) { - this.p = p - this.a = a - this.b = b - this.G = Point.fromAffine(this, Gx, Gy) - this.n = n - this.h = h - - this.infinity = new Point(this, null, null, BigInteger.ZERO) +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // result caching - this.pOverFour = p.add(BigInteger.ONE).shiftRight(2) - // determine size of p in bytes - this.pLength = Math.floor((this.p.bitLength() + 7) / 8) -} -Curve.prototype.pointFromX = function (isOdd, x) { - var alpha = x.pow(3).add(this.a.multiply(x)).add(this.b).mod(this.p) - var beta = alpha.modPow(this.pOverFour, this.p) // XXX: not compatible with all curves +var SyntheticEvent = __webpack_require__(26); - var y = beta - if (beta.isEven() ^ !isOdd) { - y = this.p.subtract(y) // -y % p +/** + * @interface Event + * @see http://www.w3.org/TR/clipboard-apis/ + */ +var ClipboardEventInterface = { + clipboardData: function (event) { + return 'clipboardData' in event ? event.clipboardData : window.clipboardData; } +}; - return Point.fromAffine(this, x, y) +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticClipboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); } -Curve.prototype.isInfinity = function (Q) { - if (Q === this.infinity) return true +SyntheticEvent.augmentClass(SyntheticClipboardEvent, ClipboardEventInterface); - return Q.z.signum() === 0 && Q.y.signum() !== 0 -} +module.exports = SyntheticClipboardEvent; -Curve.prototype.isOnCurve = function (Q) { - if (this.isInfinity(Q)) return true +/***/ }), +/* 298 */ +/***/ (function(module, exports, __webpack_require__) { - var x = Q.affineX - var y = Q.affineY - var a = this.a - var b = this.b - var p = this.p +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // Check that xQ and yQ are integers in the interval [0, p - 1] - if (x.signum() < 0 || x.compareTo(p) >= 0) return false - if (y.signum() < 0 || y.compareTo(p) >= 0) return false - // and check that y^2 = x^3 + ax + b (mod p) - var lhs = y.square().mod(p) - var rhs = x.pow(3).add(a.multiply(x)).add(b).mod(p) - return lhs.equals(rhs) -} + +var SyntheticUIEvent = __webpack_require__(47); /** - * Validate an elliptic curve point. - * - * See SEC 1, section 3.2.2.1: Elliptic Curve Public Key Validation Primitive + * @interface FocusEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ */ -Curve.prototype.validate = function (Q) { - // Check Q != O - assert(!this.isInfinity(Q), 'Point is at infinity') - assert(this.isOnCurve(Q), 'Point is not on the curve') - - // Check nQ = O (where Q is a scalar multiple of G) - var nQ = Q.multiply(this.n) - assert(this.isInfinity(nQ), 'Point is not a scalar multiple of G') +var FocusEventInterface = { + relatedTarget: null +}; - return true +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticFocusEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); } -module.exports = Curve +SyntheticUIEvent.augmentClass(SyntheticFocusEvent, FocusEventInterface); +module.exports = SyntheticFocusEvent; /***/ }), -/* 355 */ -/***/ (function(module, exports) { - -// https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki#account-discovery -module.exports = function discovery (chain, gapLimit, queryCb, done) { - var gap = 0 - var checked = 0 +/* 299 */ +/***/ (function(module, exports, __webpack_require__) { - function cycle () { - var batch = [chain.get()] - checked++ +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - while (batch.length < gapLimit) { - chain.next() - batch.push(chain.get()) - checked++ - } - queryCb(batch, function (err, results) { - if (err) return done(err) +var SyntheticUIEvent = __webpack_require__(47); - results.forEach(function (isUsed) { - if (isUsed) { - gap = 0 - } else { - gap += 1 - } - }) +var getEventCharCode = __webpack_require__(92); +var getEventKey = __webpack_require__(300); +var getEventModifierState = __webpack_require__(81); - if (gap >= gapLimit) { - var used = checked - gap +/** + * @interface KeyboardEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var KeyboardEventInterface = { + key: getEventKey, + location: null, + ctrlKey: null, + shiftKey: null, + altKey: null, + metaKey: null, + repeat: null, + locale: null, + getModifierState: getEventModifierState, + // Legacy Interface + charCode: function (event) { + // `charCode` is the result of a KeyPress event and represents the value of + // the actual printable character. - return done(undefined, used, checked) - } else { - chain.next() - } + // KeyPress is deprecated, but its replacement is not yet final and not + // implemented in any major browser. Only KeyPress has charCode. + if (event.type === 'keypress') { + return getEventCharCode(event); + } + return 0; + }, + keyCode: function (event) { + // `keyCode` is the result of a KeyDown/Up event and represents the value of + // physical keyboard key. - cycle() - }) + // The actual meaning of the value depends on the users' keyboard layout + // which cannot be detected. Assuming that it is a US keyboard layout + // provides a surprisingly accurate mapping for US and European users. + // Due to this, it is left to the user to implement at this time. + if (event.type === 'keydown' || event.type === 'keyup') { + return event.keyCode; + } + return 0; + }, + which: function (event) { + // `which` is an alias for either `keyCode` or `charCode` depending on the + // type of the event. + if (event.type === 'keypress') { + return getEventCharCode(event); + } + if (event.type === 'keydown' || event.type === 'keyup') { + return event.keyCode; + } + return 0; } +}; - cycle() -} - - -/***/ }), -/* 356 */ -/***/ (function(module, exports) { - -function Chain (parent, k) { - k = k || 0 - this.__parent = parent - - this.addresses = [] - this.k = k - this.map = {} -} - -Chain.prototype.__initialize = function () { - var address = this.__parent.derive(this.k).getAddress() - this.map[address] = this.k - this.addresses.push(address) +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticKeyboardEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); } -Chain.prototype.clone = function () { - var chain = new Chain(this.__parent, this.k) - - for (var k in this.addresses) chain.addresses[k] = this.addresses[k] - for (k in this.map) chain.map[k] = this.map[k] +SyntheticUIEvent.augmentClass(SyntheticKeyboardEvent, KeyboardEventInterface); - return chain -} +module.exports = SyntheticKeyboardEvent; -Chain.prototype.derive = function (address, parent) { - var k = this.map[address] - if (k === undefined) return +/***/ }), +/* 300 */ +/***/ (function(module, exports, __webpack_require__) { - parent = parent || this.__parent - return parent.derive(k) -} +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -Chain.prototype.find = function (address) { - return this.map[address] -} -Chain.prototype.get = function () { - if (this.addresses.length === 0) this.__initialize() - return this.addresses[this.addresses.length - 1] -} +var getEventCharCode = __webpack_require__(92); -Chain.prototype.getAll = function () { - if (this.addresses.length === 0) this.__initialize() +/** + * Normalization of deprecated HTML5 `key` values + * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names + */ +var normalizeKey = { + Esc: 'Escape', + Spacebar: ' ', + Left: 'ArrowLeft', + Up: 'ArrowUp', + Right: 'ArrowRight', + Down: 'ArrowDown', + Del: 'Delete', + Win: 'OS', + Menu: 'ContextMenu', + Apps: 'ContextMenu', + Scroll: 'ScrollLock', + MozPrintableKey: 'Unidentified' +}; - return this.addresses -} +/** + * Translation from legacy `keyCode` to HTML5 `key` + * Only special keys supported, all others depend on keyboard layout or browser + * @see https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent#Key_names + */ +var translateToKey = { + 8: 'Backspace', + 9: 'Tab', + 12: 'Clear', + 13: 'Enter', + 16: 'Shift', + 17: 'Control', + 18: 'Alt', + 19: 'Pause', + 20: 'CapsLock', + 27: 'Escape', + 32: ' ', + 33: 'PageUp', + 34: 'PageDown', + 35: 'End', + 36: 'Home', + 37: 'ArrowLeft', + 38: 'ArrowUp', + 39: 'ArrowRight', + 40: 'ArrowDown', + 45: 'Insert', + 46: 'Delete', + 112: 'F1', + 113: 'F2', + 114: 'F3', + 115: 'F4', + 116: 'F5', + 117: 'F6', + 118: 'F7', + 119: 'F8', + 120: 'F9', + 121: 'F10', + 122: 'F11', + 123: 'F12', + 144: 'NumLock', + 145: 'ScrollLock', + 224: 'Meta' +}; -Chain.prototype.getParent = function () { - return this.__parent -} +/** + * @param {object} nativeEvent Native browser event. + * @return {string} Normalized `key` property. + */ +function getEventKey(nativeEvent) { + if (nativeEvent.key) { + // Normalize inconsistent values reported by browsers due to + // implementations of a working draft specification. -Chain.prototype.next = function () { - if (this.addresses.length === 0) this.__initialize() - var address = this.__parent.derive(this.k + 1).getAddress() + // FireFox implements `key` but returns `MozPrintableKey` for all + // printable characters (normalized to `Unidentified`), ignore it. + var key = normalizeKey[nativeEvent.key] || nativeEvent.key; + if (key !== 'Unidentified') { + return key; + } + } - this.k += 1 - this.map[address] = this.k - this.addresses.push(address) + // Browser does not implement `key`, polyfill as much of it as we can. + if (nativeEvent.type === 'keypress') { + var charCode = getEventCharCode(nativeEvent); - return address + // The enter-key is technically both printable and non-printable and can + // thus be captured by `keypress`, no other non-printable key should. + return charCode === 13 ? 'Enter' : String.fromCharCode(charCode); + } + if (nativeEvent.type === 'keydown' || nativeEvent.type === 'keyup') { + // While user keyboard layout determines the actual meaning of each + // `keyCode` value, almost all function keys have a universal value. + return translateToKey[nativeEvent.keyCode] || 'Unidentified'; + } + return ''; } -Chain.prototype.pop = function () { - var address = this.addresses.pop() - delete this.map[address] - this.k -= 1 - - return address -} +module.exports = getEventKey; -module.exports = Chain +/***/ }), +/* 301 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -/***/ }), -/* 357 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; +var SyntheticMouseEvent = __webpack_require__(59); -__webpack_require__(117); +/** + * @interface DragEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var DragEventInterface = { + dataTransfer: null +}; -__webpack_require__(120); +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticDragEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} -var _react = __webpack_require__(4); +SyntheticMouseEvent.augmentClass(SyntheticDragEvent, DragEventInterface); -var _react2 = _interopRequireDefault(_react); +module.exports = SyntheticDragEvent; -var _reactDom = __webpack_require__(28); +/***/ }), +/* 302 */ +/***/ (function(module, exports, __webpack_require__) { -var _reactDom2 = _interopRequireDefault(_reactDom); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var _navbar = __webpack_require__(220); -var _navbar2 = _interopRequireDefault(_navbar); -var _wallet = __webpack_require__(358); +var SyntheticUIEvent = __webpack_require__(47); -var _wallet2 = _interopRequireDefault(_wallet); +var getEventModifierState = __webpack_require__(81); -var _footer = __webpack_require__(243); +/** + * @interface TouchEvent + * @see http://www.w3.org/TR/touch-events/ + */ +var TouchEventInterface = { + touches: null, + targetTouches: null, + changedTouches: null, + altKey: null, + metaKey: null, + ctrlKey: null, + shiftKey: null, + getModifierState: getEventModifierState +}; -var _footer2 = _interopRequireDefault(_footer); +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticUIEvent} + */ +function SyntheticTouchEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticUIEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +SyntheticUIEvent.augmentClass(SyntheticTouchEvent, TouchEventInterface); -_reactDom2.default.render(_react2.default.createElement(_navbar2.default, null), document.getElementById('navbar')); -_reactDom2.default.render(_react2.default.createElement(_wallet2.default, null), document.getElementById('wallet')); -_reactDom2.default.render(_react2.default.createElement(_footer2.default, null), document.getElementById('footer')); +module.exports = SyntheticTouchEvent; /***/ }), -/* 358 */ +/* 303 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* WEBPACK VAR INJECTION */(function(Buffer) { - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _reactstrap = __webpack_require__(66); +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var _reactBootstrapTable = __webpack_require__(361); -var _axios = __webpack_require__(400); -var _axios2 = _interopRequireDefault(_axios); +var SyntheticEvent = __webpack_require__(26); -var _react = __webpack_require__(4); +/** + * @interface Event + * @see http://www.w3.org/TR/2009/WD-css3-transitions-20090320/#transition-events- + * @see https://developer.mozilla.org/en-US/docs/Web/API/TransitionEvent + */ +var TransitionEventInterface = { + propertyName: null, + elapsedTime: null, + pseudoElement: null +}; -var _react2 = _interopRequireDefault(_react); +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticEvent} + */ +function SyntheticTransitionEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} -var _classnames = __webpack_require__(29); +SyntheticEvent.augmentClass(SyntheticTransitionEvent, TransitionEventInterface); -var _classnames2 = _interopRequireDefault(_classnames); +module.exports = SyntheticTransitionEvent; -var _reactCopyToClipboard = __webpack_require__(419); +/***/ }), +/* 304 */ +/***/ (function(module, exports, __webpack_require__) { -var _reactCopyToClipboard2 = _interopRequireDefault(_reactCopyToClipboard); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var _zencashjs = __webpack_require__(306); -var _zencashjs2 = _interopRequireDefault(_zencashjs); -var _utils = __webpack_require__(522); +var SyntheticMouseEvent = __webpack_require__(59); -var _utils2 = _interopRequireDefault(_utils); +/** + * @interface WheelEvent + * @see http://www.w3.org/TR/DOM-Level-3-Events/ + */ +var WheelEventInterface = { + deltaX: function (event) { + return 'deltaX' in event ? event.deltaX : // Fallback to `wheelDeltaX` for Webkit and normalize (right is positive). + 'wheelDeltaX' in event ? -event.wheelDeltaX : 0; + }, + deltaY: function (event) { + return 'deltaY' in event ? event.deltaY : // Fallback to `wheelDeltaY` for Webkit and normalize (down is positive). + 'wheelDeltaY' in event ? -event.wheelDeltaY : // Fallback to `wheelDelta` for IE<9 and normalize (down is positive). + 'wheelDelta' in event ? -event.wheelDelta : 0; + }, + deltaZ: null, -var _hdwallet = __webpack_require__(524); + // Browsers without "deltaMode" is reporting in raw wheel delta where one + // notch on the scroll is always +/- 120, roughly equivalent to pixels. + // A good approximation of DOM_DELTA_LINE (1) is 5% of viewport size or + // ~40 pixels, for DOM_DELTA_SCREEN (2) it is 87.5% of viewport size. + deltaMode: null +}; -var _hdwallet2 = _interopRequireDefault(_hdwallet); +/** + * @param {object} dispatchConfig Configuration used to dispatch this event. + * @param {string} dispatchMarker Marker identifying the event target. + * @param {object} nativeEvent Native browser event. + * @extends {SyntheticMouseEvent} + */ +function SyntheticWheelEvent(dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget) { + return SyntheticMouseEvent.call(this, dispatchConfig, dispatchMarker, nativeEvent, nativeEventTarget); +} -var _refresh = __webpack_require__(557); +SyntheticMouseEvent.augmentClass(SyntheticWheelEvent, WheelEventInterface); -var _refresh2 = _interopRequireDefault(_refresh); +module.exports = SyntheticWheelEvent; -var _contentCopy = __webpack_require__(558); +/***/ }), +/* 305 */ +/***/ (function(module, exports, __webpack_require__) { -var _contentCopy2 = _interopRequireDefault(_contentCopy); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var _settings2 = __webpack_require__(279); -var _settings3 = _interopRequireDefault(_settings2); -var _repeat = __webpack_require__(559); +var validateDOMNesting = __webpack_require__(91); -var _repeat2 = _interopRequireDefault(_repeat); +var DOC_NODE_TYPE = 9; -var _unlockAlt = __webpack_require__(280); +function ReactDOMContainerInfo(topLevelWrapper, node) { + var info = { + _topLevelWrapper: topLevelWrapper, + _idCounter: 1, + _ownerDocument: node ? node.nodeType === DOC_NODE_TYPE ? node : node.ownerDocument : null, + _node: node, + _tag: node ? node.nodeName.toLowerCase() : null, + _namespaceURI: node ? node.namespaceURI : null + }; + if (process.env.NODE_ENV !== 'production') { + info._ancestorInfo = node ? validateDOMNesting.updatedAncestorInfo(null, info._tag, null) : null; + } + return info; +} -var _unlockAlt2 = _interopRequireDefault(_unlockAlt); +module.exports = ReactDOMContainerInfo; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) -var _eyeSlash = __webpack_require__(560); +/***/ }), +/* 306 */ +/***/ (function(module, exports, __webpack_require__) { -var _eyeSlash2 = _interopRequireDefault(_eyeSlash); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var _eye = __webpack_require__(561); -var _eye2 = _interopRequireDefault(_eye); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var ReactDOMFeatureFlags = { + useCreateElement: true, + useFiber: false +}; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +module.exports = ReactDOMFeatureFlags; -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +/***/ }), +/* 307 */ +/***/ (function(module, exports, __webpack_require__) { -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -// Throttled GET request to prevent unusable lag -var throttledAxiosGet = _utils2.default.promiseDebounce(_axios2.default.get, 1000, 5); -// Unlock wallet enum -var UNLOCK_WALLET_TYPE = { - IMPORT_WALLET: 0, - HD_WALLET: 1, - PASTE_PRIV_KEY: 2 - // Components -}; -var ToolTipButton = function (_React$Component) { - _inherits(ToolTipButton, _React$Component); +var adler32 = __webpack_require__(308); - function ToolTipButton(props) { - _classCallCheck(this, ToolTipButton); +var TAG_END = /\/?>/; +var COMMENT_START = /^<\!\-\-/; - var _this = _possibleConstructorReturn(this, (ToolTipButton.__proto__ || Object.getPrototypeOf(ToolTipButton)).call(this, props)); +var ReactMarkupChecksum = { + CHECKSUM_ATTR_NAME: 'data-react-checksum', - _this.toggle = _this.toggle.bind(_this); - _this.state = { - tooltipOpen: false - }; - return _this; - } + /** + * @param {string} markup Markup string + * @return {string} Markup string with checksum attribute attached + */ + addChecksumToMarkup: function (markup) { + var checksum = adler32(markup); - _createClass(ToolTipButton, [{ - key: 'toggle', - value: function toggle() { - this.setState({ - tooltipOpen: !this.state.tooltipOpen - }); - } - }, { - key: 'render', - value: function render() { - return _react2.default.createElement( - 'span', - null, - _react2.default.createElement( - _reactstrap.Button, - { disabled: this.props.disabled, onClick: this.props.onClick, className: 'mr-1', color: 'secondary', id: 'Tooltip-' + this.props.id }, - this.props.buttonText - ), - _react2.default.createElement( - _reactstrap.Tooltip, - { placement: 'top', isOpen: this.state.tooltipOpen, target: 'Tooltip-' + this.props.id, toggle: this.toggle }, - this.props.tooltipText - ) - ); + // Add checksum (handle both parent tags, comments and self-closing tags) + if (COMMENT_START.test(markup)) { + return markup; + } else { + return markup.replace(TAG_END, ' ' + ReactMarkupChecksum.CHECKSUM_ATTR_NAME + '="' + checksum + '"$&'); } - }]); - - return ToolTipButton; -}(_react2.default.Component); - -var ZWalletGenerator = function (_React$Component2) { - _inherits(ZWalletGenerator, _React$Component2); - - function ZWalletGenerator(props) { - _classCallCheck(this, ZWalletGenerator); - - var _this2 = _possibleConstructorReturn(this, (ZWalletGenerator.__proto__ || Object.getPrototypeOf(ZWalletGenerator)).call(this, props)); + }, - _this2.handlePasswordPhrase = _this2.handlePasswordPhrase.bind(_this2); - _this2.state = { - passwordPhrase: '', - privateKey: '' - }; - return _this2; + /** + * @param {string} markup to use + * @param {DOMElement} element root React element + * @returns {boolean} whether or not the markup is the same + */ + canReuseMarkup: function (markup, element) { + var existingChecksum = element.getAttribute(ReactMarkupChecksum.CHECKSUM_ATTR_NAME); + existingChecksum = existingChecksum && parseInt(existingChecksum, 10); + var markupChecksum = adler32(markup); + return markupChecksum === existingChecksum; } +}; - _createClass(ZWalletGenerator, [{ - key: 'handlePasswordPhrase', - value: function handlePasswordPhrase(e) { - // What wif format do we use? - var wifHash = this.props.settings.useTestNet ? _zencashjs2.default.config.testnet.wif : _zencashjs2.default.config.mainnet.wif; - - var pk = _zencashjs2.default.address.mkPrivKey(e.target.value); - var pkwif = _zencashjs2.default.address.privKeyToWIF(pk, true, wifHash); - - if (e.target.value === '') { - pkwif = ''; - } - - this.setState({ - privateKey: pkwif - }); - } - }, { - key: 'render', - value: function render() { - return _react2.default.createElement( - 'div', - null, - _react2.default.createElement( - 'h3', - { className: 'display-6' }, - 'Generate New Address' - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement(_reactstrap.Input, { onChange: this.handlePasswordPhrase, placeholder: 'Password phrase. Do NOT forget to save this! Use >15 words to be safe.' }) - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement(_reactstrap.Input, { value: this.state.privateKey, placeholder: 'Private key generated from password phrase' }), - _react2.default.createElement( - _reactstrap.InputGroupButton, - null, - _react2.default.createElement( - _reactCopyToClipboard2.default, - { text: this.state.privateKey }, - _react2.default.createElement( - _reactstrap.Button, - null, - _react2.default.createElement(_contentCopy2.default, null) - ) - ) - ) - ) - ); - } - }]); - - return ZWalletGenerator; -}(_react2.default.Component); +module.exports = ReactMarkupChecksum; -var ZWalletUnlockKey = function (_React$Component3) { - _inherits(ZWalletUnlockKey, _React$Component3); +/***/ }), +/* 308 */ +/***/ (function(module, exports, __webpack_require__) { - function ZWalletUnlockKey(props) { - _classCallCheck(this, ZWalletUnlockKey); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + * + */ - var _this3 = _possibleConstructorReturn(this, (ZWalletUnlockKey.__proto__ || Object.getPrototypeOf(ZWalletUnlockKey)).call(this, props)); - _this3.unlockHDWallet = _this3.unlockHDWallet.bind(_this3); - _this3.loadWalletDat = _this3.loadWalletDat.bind(_this3); - _this3.toggleShowPassword = _this3.toggleShowPassword.bind(_this3); - _this3.unlockPrivateKeys = _this3.unlockPrivateKeys.bind(_this3); - _this3.state = { - showPassword: false, - secretPhrase: '', - invalidPrivateKey: false, - secretPhraseTooShort: false, +var MOD = 65521; - // Style for input button - inputFileStyle: { - WebkitAppearance: 'button', - cursor: 'pointer' - } - }; - return _this3; +// adler32 is not cryptographically strong, and is only used to sanity check that +// markup generated on the server matches the markup generated on the client. +// This implementation (a modified version of the SheetJS version) has been optimized +// for our use case, at the expense of conforming to the adler32 specification +// for non-ascii inputs. +function adler32(data) { + var a = 1; + var b = 0; + var i = 0; + var l = data.length; + var m = l & ~0x3; + while (i < m) { + var n = Math.min(i + 4096, m); + for (; i < n; i += 4) { + b += (a += data.charCodeAt(i)) + (a += data.charCodeAt(i + 1)) + (a += data.charCodeAt(i + 2)) + (a += data.charCodeAt(i + 3)); + } + a %= MOD; + b %= MOD; } + for (; i < l; i++) { + b += a += data.charCodeAt(i); + } + a %= MOD; + b %= MOD; + return a | b << 16; +} - _createClass(ZWalletUnlockKey, [{ - key: 'toggleShowPassword', - value: function toggleShowPassword() { - this.setState({ - showPassword: !this.state.showPassword - }); - } - }, { - key: 'unlockPrivateKeys', - value: function unlockPrivateKeys() { - // Success = return 0 - var success = this.props.handleUnlockPrivateKeys() === 0; +module.exports = adler32; - if (!success) { - this.setState({ - invalidPrivateKey: true - }); - } - } - }, { - key: 'unlockHDWallet', - value: function unlockHDWallet() { - try { - // Generate private keys from secret phrase - var pk = _hdwallet2.default.phraseToHDWallet(this.state.secretPhrase); +/***/ }), +/* 309 */ +/***/ (function(module, exports, __webpack_require__) { - this.setState({ - secretPhraseTooShort: false - }); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // Set private key and unlock them (we know it'll work so no need to validate) - this.props.setPrivateKeys(pk, true); - } catch (err) { - this.setState({ - secretPhraseTooShort: true - }); - } - } - }, { - key: 'loadWalletDat', - value: function loadWalletDat(e) { - var _this4 = this; - var reader = new FileReader(); - var file = e.target.files[0]; - // Read file callback function - reader.onloadend = function () { - // Get reader results in bytes - var dataHexStr = reader.result; +module.exports = '15.6.1'; - // Retrieve private keys from wallet.dat - // Source: https://gist.github.com/moocowmoo/a715c80399bb202a65955771c465530c - var re = /\x30\x81\xD3\x02\x01\x01\x04\x20(.{32})/gm; - var privateKeys = dataHexStr.match(re); - privateKeys = privateKeys.map(function (x) { - x = x.replace('\x30\x81\xD3\x02\x01\x01\x04\x20', ''); - x = Buffer.from(x, 'latin1').toString('hex'); - return x; - }); +/***/ }), +/* 310 */ +/***/ (function(module, exports, __webpack_require__) { - // Set private key - _this4.props.setPrivateKeys(privateKeys); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // Unlock private key - var success = _this4.props.handleUnlockPrivateKeys() === 0; - if (!success) { - _this4.setState({ - invalidPrivateKey: true - }); - } - }; - // Read file - reader.readAsBinaryString(file); - } - }, { - key: 'render', - value: function render() { - var _this5 = this; +var _prodInvariant = __webpack_require__(5); - if (this.props.unlockType == UNLOCK_WALLET_TYPE.IMPORT_WALLET) { - return _react2.default.createElement( - _reactstrap.Form, - null, - _react2.default.createElement( - _reactstrap.FormGroup, - { row: true }, - _react2.default.createElement( - _reactstrap.Col, - null, - this.state.invalidPrivateKey ? _react2.default.createElement( - _reactstrap.Alert, - { color: 'danger' }, - _react2.default.createElement( - 'strong', - null, - 'Error.' - ), - '\xA0Keys in files are corrupted' - ) : '', - _react2.default.createElement( - _reactstrap.Label, - { 'for': 'walletDatFile', className: 'btn btn-block btn-secondary', style: this.state.inputFileStyle }, - 'Select wallet.dat file', - _react2.default.createElement(_reactstrap.Input, { - style: { display: 'none' }, - type: 'file', - name: 'file', - id: 'walletDatFile', - onChange: this.loadWalletDat - }) - ), - _react2.default.createElement( - _reactstrap.FormText, - { color: 'muted' }, - 'For Windows, it should be in %APPDATA%/zen', - _react2.default.createElement('br', null), - 'For Mac/Linux, it should be in ~/.zen' - ) - ) - ) - ); - } else if (this.props.unlockType == UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY) { - return _react2.default.createElement( - 'div', - null, - this.state.invalidPrivateKey ? _react2.default.createElement( - _reactstrap.Alert, - { color: 'danger' }, - _react2.default.createElement( - 'strong', - null, - 'Error.' - ), - '\xA0Invalid private key' - ) : '', - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement( - _reactstrap.InputGroupButton, - null, - _react2.default.createElement(ToolTipButton, { id: 4, - onClick: this.toggleShowPassword, - buttonText: this.state.showPassword ? _react2.default.createElement(_eye2.default, null) : _react2.default.createElement(_eyeSlash2.default, null), - tooltipText: this.state.showPassword ? 'show password' : 'hide password' - }) - ), - _react2.default.createElement(_reactstrap.Input, { - type: this.state.showPassword ? "text" : "password", - onChange: function onChange(e) { - return _this5.props.setPrivateKeys([e.target.value]); - } // Set it in a list so we can map over it later - , placeholder: 'Private key' - }), - _react2.default.createElement( - _reactstrap.InputGroupButton, - null, - _react2.default.createElement(ToolTipButton, { onClick: this.unlockPrivateKeys, id: 3, buttonText: _react2.default.createElement(_unlockAlt2.default, null), tooltipText: 'unlock' }) - ) - ) - ); - } else if (this.props.unlockType == UNLOCK_WALLET_TYPE.HD_WALLET) { - return _react2.default.createElement( - 'div', - null, - _react2.default.createElement( - _reactstrap.Alert, - { color: 'warning' }, - _react2.default.createElement( - 'strong', - null, - 'Warning.' - ), - '\xA0Make sure you have saved your secret phrase somewhere.' - ), - this.state.secretPhraseTooShort ? _react2.default.createElement( - _reactstrap.Alert, - { color: 'danger' }, - _react2.default.createElement( - 'strong', - null, - 'Error.' - ), - '\xA0Secret phrase too short' - ) : '', - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement( - _reactstrap.InputGroupButton, - null, - _react2.default.createElement(ToolTipButton, { id: 7, - onClick: this.toggleShowPassword, - buttonText: this.state.showPassword ? _react2.default.createElement(_eye2.default, null) : _react2.default.createElement(_eyeSlash2.default, null), - tooltipText: this.state.showPassword ? 'show phrase' : 'hide phrase' - }) - ), - _react2.default.createElement(_reactstrap.Input, { - type: this.state.showPassword ? "text" : "password", - maxLength: '64', - onChange: function onChange(e) { - return _this5.setState({ secretPhrase: e.target.value }); - }, - placeholder: 'Secret phrase. e.g. cash cow money heros cardboard money bag late green' - }), - _react2.default.createElement( - _reactstrap.InputGroupButton, - null, - _react2.default.createElement(ToolTipButton, { onClick: this.unlockHDWallet, id: 8, buttonText: _react2.default.createElement(_unlockAlt2.default, null), tooltipText: 'unlock HD wallet' }) - ) - ) - ); - } - } - }]); +var ReactCurrentOwner = __webpack_require__(22); +var ReactDOMComponentTree = __webpack_require__(10); +var ReactInstanceMap = __webpack_require__(48); - return ZWalletUnlockKey; -}(_react2.default.Component); +var getHostComponentFromComposite = __webpack_require__(150); +var invariant = __webpack_require__(2); +var warning = __webpack_require__(3); -var ZWalletSettings = function (_React$Component4) { - _inherits(ZWalletSettings, _React$Component4); +/** + * Returns the DOM node rendered by this element. + * + * See https://facebook.github.io/react/docs/top-level-api.html#reactdom.finddomnode + * + * @param {ReactComponent|DOMElement} componentOrElement + * @return {?DOMElement} The root node of this element. + */ +function findDOMNode(componentOrElement) { + if (process.env.NODE_ENV !== 'production') { + var owner = ReactCurrentOwner.current; + if (owner !== null) { + process.env.NODE_ENV !== 'production' ? warning(owner._warnedAboutRefsInRender, '%s is accessing findDOMNode inside its render(). ' + 'render() should be a pure function of props and state. It should ' + 'never access something that requires stale data from the previous ' + 'render, such as refs. Move this logic to componentDidMount and ' + 'componentDidUpdate instead.', owner.getName() || 'A component') : void 0; + owner._warnedAboutRefsInRender = true; + } + } + if (componentOrElement == null) { + return null; + } + if (componentOrElement.nodeType === 1) { + return componentOrElement; + } - function ZWalletSettings() { - _classCallCheck(this, ZWalletSettings); + var inst = ReactInstanceMap.get(componentOrElement); + if (inst) { + inst = getHostComponentFromComposite(inst); + return inst ? ReactDOMComponentTree.getNodeFromInstance(inst) : null; + } - return _possibleConstructorReturn(this, (ZWalletSettings.__proto__ || Object.getPrototypeOf(ZWalletSettings)).apply(this, arguments)); + if (typeof componentOrElement.render === 'function') { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'findDOMNode was called on an unmounted component.') : _prodInvariant('44') : void 0; + } else { + true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element appears to be neither ReactComponent nor DOMNode (keys: %s)', Object.keys(componentOrElement)) : _prodInvariant('45', Object.keys(componentOrElement)) : void 0; } +} - _createClass(ZWalletSettings, [{ - key: 'render', - value: function render() { - var _this7 = this; +module.exports = findDOMNode; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - return _react2.default.createElement( - _reactstrap.Modal, - { isOpen: this.props.settings.showSettings, toggle: this.props.toggleModalSettings }, - _react2.default.createElement( - _reactstrap.ModalHeader, - { toggle: this.props.toggleShowSettings }, - 'ZenCash Wallet Settings' - ), - _react2.default.createElement( - _reactstrap.ModalBody, - null, - _react2.default.createElement(ZWalletSelectUnlockType, { - setUnlockType: this.props.setUnlockType, - unlockType: this.props.settings.unlockType - }) - ), - _react2.default.createElement( - _reactstrap.ModalBody, - null, - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement( - _reactstrap.InputGroupAddon, - null, - 'Insight API' - ), - _react2.default.createElement(_reactstrap.Input, { - value: this.props.settings.insightAPI, - onChange: function onChange(e) { - return _this7.props.setInsightAPI(e.target.value); - } - }) - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - { sm: '6' }, - _react2.default.createElement( - _reactstrap.Label, - { check: true }, - _react2.default.createElement(_reactstrap.Input, { - disabled: !(this.props.publicAddresses === null), - defaultChecked: this.props.settings.compressPubKey, type: 'checkbox', - onChange: this.props.toggleCompressPubKey - }), - ' ', - 'Compress Public Key' - ) - ), - _react2.default.createElement( - _reactstrap.Col, - { sm: '6' }, - _react2.default.createElement( - _reactstrap.Label, - { check: true }, - _react2.default.createElement(_reactstrap.Input, { - defaultChecked: this.props.settings.showWalletGen, type: 'checkbox', - onChange: this.props.toggleShowWalletGen - }), - ' ', - 'Show Address Generator' - ) - ) - ) - ), - _react2.default.createElement( - _reactstrap.ModalFooter, - null, - _react2.default.createElement( - _reactstrap.Label, - null, - _react2.default.createElement(_reactstrap.Input, { - disabled: !(this.props.publicAddresses === null), - defaultChecked: this.props.settings.useTestNet, type: 'checkbox', - onChange: this.props.toggleUseTestNet - }), - ' ', - 'testnet' - ) - ) - ); - } - }]); +/***/ }), +/* 311 */ +/***/ (function(module, exports, __webpack_require__) { - return ZWalletSettings; -}(_react2.default.Component); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ -var ZAddressInfo = function (_React$Component5) { - _inherits(ZAddressInfo, _React$Component5); - function ZAddressInfo(props) { - _classCallCheck(this, ZAddressInfo); - var _this8 = _possibleConstructorReturn(this, (ZAddressInfo.__proto__ || Object.getPrototypeOf(ZAddressInfo)).call(this, props)); +var ReactMount = __webpack_require__(149); - _this8.updateAddressInfo = _this8.updateAddressInfo.bind(_this8); - _this8.updateAddressesInfo = _this8.updateAddressesInfo.bind(_this8); +module.exports = ReactMount.renderSubtreeIntoContainer; - _this8.state = { - retrieveAddressError: false - }; - return _this8; - } +/***/ }), +/* 312 */ +/***/ (function(module, exports, __webpack_require__) { - // Updates all address info +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - _createClass(ZAddressInfo, [{ - key: 'updateAddressesInfo', - value: function updateAddressesInfo() { - // The key is the address - // Value is the private key - Object.keys(this.props.publicAddresses).forEach(function (key) { - if (key !== undefined) { - this.updateAddressInfo(key); - } - }.bind(this)); - } - // Updates a address info +var DOMProperty = __webpack_require__(28); +var EventPluginRegistry = __webpack_require__(57); +var ReactComponentTreeHook = __webpack_require__(17); - }, { - key: 'updateAddressInfo', - value: function updateAddressInfo(address) { - // GET request to URL - var info_url = _utils2.default.urlAppend(this.props.settings.insightAPI, 'addr/'); - info_url = _utils2.default.urlAppend(info_url, address + '?noTxList=1'); +var warning = __webpack_require__(3); - throttledAxiosGet(info_url).then(function (response) { - var data = response.data; +if (process.env.NODE_ENV !== 'production') { + var reactProps = { + children: true, + dangerouslySetInnerHTML: true, + key: true, + ref: true, - this.props.setPublicAddressesKeyValue(address, 'confirmedBalance', data.balance); - this.props.setPublicAddressesKeyValue(address, 'unconfirmedBalance', data.unconfirmedBalance); - this.setState({ - retrieveAddressError: false - }); - }.bind(this)).catch(function (error) { - this.setState({ - retrieveAddressError: true - }); - }.bind(this)); - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - // Run immediately - this.updateAddressesInfo(); + autoFocus: true, + defaultValue: true, + valueLink: true, + defaultChecked: true, + checkedLink: true, + innerHTML: true, + suppressContentEditableWarning: true, + onFocusIn: true, + onFocusOut: true + }; + var warnedProperties = {}; - // Update every 30 seconds - this.interval = setInterval(this.updateAddressesInfo, 300000); + var validateProperty = function (tagName, name, debugID) { + if (DOMProperty.properties.hasOwnProperty(name) || DOMProperty.isCustomAttribute(name)) { + return true; } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - clearInterval(this.interval); + if (reactProps.hasOwnProperty(name) && reactProps[name] || warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { + return true; } - }, { - key: 'render', - value: function render() { - // Key is the address - var addresses = []; - var totalConfirmed = 0.0; - var totalUnconfirmed = 0.0; - Object.keys(this.props.publicAddresses).forEach(function (key) { - if (key !== undefined) { - // Add to address - addresses.push({ - address: { - address: key, - transactionURL: this.props.publicAddresses[key].transactionURL - }, - privateKeyWIF: this.props.publicAddresses[key].privateKeyWIF, - confirmedBalance: this.props.publicAddresses[key].confirmedBalance, - unconfirmedBalance: this.props.publicAddresses[key].unconfirmedBalance - }); - - var c_confirmed = Number(this.props.publicAddresses[key].confirmedBalance); - var c_unconfirmed = Number(this.props.publicAddresses[key].unconfirmedBalance); - if (!isNaN(c_confirmed)) { - totalConfirmed += c_confirmed; - } - - if (!isNaN(c_unconfirmed)) { - totalUnconfirmed += c_unconfirmed; - } - } - }.bind(this)); - - // <tr> - // <th scope="row"><a href={this.props.publicAddresses[key].transactionURL}>{key}</a></th> - // <td> - // <CopyToClipboard text={this.props.publicAddresses[key].privateKeyWIF}> - // <ToolTipButton id={key} buttonText={<MDCopy/>} tooltipText={'copy wif private key'}/> - // </CopyToClipboard> - // </td> - // <td>{this.props.publicAddresses[key].confirmedBalance}</td> - // <td>{this.props.publicAddresses[key].unconfirmedBalance}</td> - // </tr> + if (EventPluginRegistry.registrationNameModules.hasOwnProperty(name)) { + return true; + } + warnedProperties[name] = true; + var lowerCasedName = name.toLowerCase(); - // Functions to format data in table - function tableAddressFormatter(cell, row) { - return '<a href="' + cell.transactionURL + '">' + cell.address + '</a>'; - } + // data-* attributes should be lowercase; suggest the lowercase version + var standardName = DOMProperty.isCustomAttribute(lowerCasedName) ? lowerCasedName : DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; - function tableWIFFormatter(cell, row) { - return _react2.default.createElement( - _reactCopyToClipboard2.default, - { text: cell }, - _react2.default.createElement(ToolTipButton, { id: cell, buttonText: _react2.default.createElement(_contentCopy2.default, null), tooltipText: 'copy wif private key' }) - ); - } + var registrationName = EventPluginRegistry.possibleRegistrationNames.hasOwnProperty(lowerCasedName) ? EventPluginRegistry.possibleRegistrationNames[lowerCasedName] : null; - return _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - null, - _react2.default.createElement( - _reactstrap.Card, - null, - _react2.default.createElement( - _reactstrap.CardBlock, - null, - this.state.retrieveAddressError ? _react2.default.createElement( - _reactstrap.Alert, - { color: 'danger' }, - 'Error connecting to the Insight API. Double check the Insight API supplied in settings.' - ) : _react2.default.createElement( - _reactstrap.Alert, - { color: 'warning' }, - 'The balance displayed here is dependent on the insight node.', - _react2.default.createElement('br', null), - 'Automatically updates every 5 minutes.' - ), - _react2.default.createElement(ToolTipButton, { onClick: this.updateAddressesInfo, id: 5, buttonText: _react2.default.createElement(_refresh2.default, null), tooltipText: 'manually refresh balance' }) - ) - ), - _react2.default.createElement( - _reactstrap.Card, - null, - _react2.default.createElement( - _reactstrap.CardBlock, - null, - _react2.default.createElement( - _reactBootstrapTable.BootstrapTable, - { data: [{ totalConfirmed: totalConfirmed, totalUnconfirmed: totalUnconfirmed }], striped: true, hover: true }, - _react2.default.createElement( - _reactBootstrapTable.TableHeaderColumn, - { isKey: true, dataField: 'totalConfirmed' }, - 'Total Confirmed' - ), - _react2.default.createElement( - _reactBootstrapTable.TableHeaderColumn, - { dataField: 'totalUnconfirmed' }, - 'Total Unconfirmed' - ) - ) - ) - ), - _react2.default.createElement( - _reactstrap.Card, - null, - _react2.default.createElement( - _reactstrap.CardBlock, - null, - _react2.default.createElement( - _reactBootstrapTable.BootstrapTable, - { data: addresses, striped: true, hover: true }, - _react2.default.createElement( - _reactBootstrapTable.TableHeaderColumn, - { isKey: true, dataField: 'address', dataFormat: tableAddressFormatter, width: '60%' }, - 'Address' - ), - _react2.default.createElement( - _reactBootstrapTable.TableHeaderColumn, - { dataField: 'privateKeyWIF', dataFormat: tableWIFFormatter }, - 'WIF' - ), - _react2.default.createElement( - _reactBootstrapTable.TableHeaderColumn, - { dataField: 'confirmedBalance' }, - 'Confirmed' - ), - _react2.default.createElement( - _reactBootstrapTable.TableHeaderColumn, - { dataField: 'unconfirmedBalance' }, - 'Unconfirmed' - ) - ) - ) - ) - ) - ); + if (standardName != null) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown DOM property %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + return true; + } else if (registrationName != null) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown event handler property %s. Did you mean `%s`?%s', name, registrationName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + return true; + } else { + // We were unable to guess which prop the user intended. + // It is likely that the user was just blindly spreading/forwarding props + // Components should be careful to only render valid props/attributes. + // Warning will be invoked in warnUnknownProperties to allow grouping. + return false; } - }]); - - return ZAddressInfo; -}(_react2.default.Component); + }; +} -var ZSendZEN = function (_React$Component6) { - _inherits(ZSendZEN, _React$Component6); +var warnUnknownProperties = function (debugID, element) { + var unknownProps = []; + for (var key in element.props) { + var isValid = validateProperty(element.type, key, debugID); + if (!isValid) { + unknownProps.push(key); + } + } - function ZSendZEN(props) { - _classCallCheck(this, ZSendZEN); + var unknownPropString = unknownProps.map(function (prop) { + return '`' + prop + '`'; + }).join(', '); - var _this9 = _possibleConstructorReturn(this, (ZSendZEN.__proto__ || Object.getPrototypeOf(ZSendZEN)).call(this, props)); + if (unknownProps.length === 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown prop %s on <%s> tag. Remove this prop from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } else if (unknownProps.length > 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown props %s on <%s> tag. Remove these props from the element. ' + 'For details, see https://fb.me/react-unknown-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } +}; - _this9.setProgressValue = _this9.setProgressValue.bind(_this9); - _this9.setSendErrorMessage = _this9.setSendErrorMessage.bind(_this9); - _this9.handleUpdateSelectedAddress = _this9.handleUpdateSelectedAddress.bind(_this9); - _this9.handleUpdateRecipientAddress = _this9.handleUpdateRecipientAddress.bind(_this9); - _this9.handleUpdateAmount = _this9.handleUpdateAmount.bind(_this9); - _this9.handleCheckChanged = _this9.handleCheckChanged.bind(_this9); - _this9.handleUpdateFee = _this9.handleUpdateFee.bind(_this9); - _this9.handleSendZEN = _this9.handleSendZEN.bind(_this9); +function handleElement(debugID, element) { + if (element == null || typeof element.type !== 'string') { + return; + } + if (element.type.indexOf('-') >= 0 || element.props.is) { + return; + } + warnUnknownProperties(debugID, element); +} - _this9.state = { - selectedAddress: '', // which address did we select - recipientAddress: '', - fee: '', - amount: '', - sentTxid: '', // Whats the send txid - sendProgress: 0, // Progress bar, 100 to indicate complete - sendErrorMessage: '', - confirmSend: false - }; - return _this9; +var ReactDOMUnknownPropertyHook = { + onBeforeMountComponent: function (debugID, element) { + handleElement(debugID, element); + }, + onBeforeUpdateComponent: function (debugID, element) { + handleElement(debugID, element); } +}; - _createClass(ZSendZEN, [{ - key: 'handleUpdateSelectedAddress', - value: function handleUpdateSelectedAddress(e) { - this.setState({ - selectedAddress: e.target.value - }); - } - }, { - key: 'handleUpdateRecipientAddress', - value: function handleUpdateRecipientAddress(e) { - this.setState({ - recipientAddress: e.target.value - }); - } - }, { - key: 'handleUpdateFee', - value: function handleUpdateFee(e) { - this.setState({ - fee: e.target.value - }); - } - }, { - key: 'handleUpdateAmount', - value: function handleUpdateAmount(e) { - this.setState({ - amount: e.target.value - }); - } - }, { - key: 'handleCheckChanged', - value: function handleCheckChanged(e) { - this.setState({ - confirmSend: e.target.checked - }); - } - }, { - key: 'setProgressValue', - value: function setProgressValue(v) { - this.setState({ - sendProgress: v - }); - } - }, { - key: 'setSendErrorMessage', - value: function setSendErrorMessage(msg) { - this.setState({ - sendErrorMessage: msg - }); - } - }, { - key: 'handleSendZEN', - value: function handleSendZEN() { - var value = this.state.amount; - var fee = this.state.fee; - var recipientAddress = this.state.recipientAddress; - var senderAddress = this.state.selectedAddress; +module.exports = ReactDOMUnknownPropertyHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - // Convert how much we wanna send - // to satoshis - var satoshisToSend = Math.round(value * 100000000); - var satoshisfeesToSend = Math.round(fee * 100000000); +/***/ }), +/* 313 */ +/***/ (function(module, exports, __webpack_require__) { - // Reset zen send progress and error message - this.setProgressValue(1); - this.setSendErrorMessage(''); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - // Error strings - var errString = ''; - // Validation - if (senderAddress === '') { - errString += '`From Address` field can\'t be empty.;'; - } - if (recipientAddress.length !== 35) { - errString += 'Invalid address. Only transparent addresses are supported at this point in time.;'; - } +var ReactComponentTreeHook = __webpack_require__(17); - if (typeof parseInt(value) !== 'number' || value === '') { - errString += 'Invalid amount.;'; - } +var warning = __webpack_require__(3); - // Can't send 0 satoshis - if (satoshisToSend <= 0) { - errString += 'Amount must be greater than 0.;'; - } +var didWarnValueNull = false; - if (typeof parseInt(fee) !== 'number' || fee === '') { - errString += 'Invalid fee.;'; - } +function handleElement(debugID, element) { + if (element == null) { + return; + } + if (element.type !== 'input' && element.type !== 'textarea' && element.type !== 'select') { + return; + } + if (element.props != null && element.props.value === null && !didWarnValueNull) { + process.env.NODE_ENV !== 'production' ? warning(false, '`value` prop on `%s` should not be null. ' + 'Consider using the empty string to clear the component or `undefined` ' + 'for uncontrolled components.%s', element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; - if (errString !== '') { - this.setSendErrorMessage(errString); - this.setProgressValue(0); - return; - } + didWarnValueNull = true; + } +} - // Private key - var senderPrivateKey = this.props.publicAddresses[senderAddress].privateKey; +var ReactDOMNullInputValuePropHook = { + onBeforeMountComponent: function (debugID, element) { + handleElement(debugID, element); + }, + onBeforeUpdateComponent: function (debugID, element) { + handleElement(debugID, element); + } +}; - // Get previous transactions - var prevTxURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'addr/') + senderAddress + '/utxo'; - var infoURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'status?q=getInfo'); - var sendRawTxURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'tx/send'); +module.exports = ReactDOMNullInputValuePropHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - // Building our transaction TXOBJ - // How many satoshis do we have so far - var satoshisSoFar = 0; - var history = []; - var recipients = [{ address: recipientAddress, satoshis: satoshisToSend }]; +/***/ }), +/* 314 */ +/***/ (function(module, exports, __webpack_require__) { - // Get transactions and info - _axios2.default.get(prevTxURL).then(function (tx_resp) { - this.setProgressValue(25); +"use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ - var tx_data = tx_resp.data; - _axios2.default.get(infoURL).then(function (info_resp) { - this.setProgressValue(50); - var info_data = info_resp.data; - var blockHeight = info_data.info.blocks - 300; - var blockHashURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'block-index/') + blockHeight; +var DOMProperty = __webpack_require__(28); +var ReactComponentTreeHook = __webpack_require__(17); - // Get block hash - _axios2.default.get(blockHashURL).then(function (response_bhash) { - this.setProgressValue(75); +var warning = __webpack_require__(3); - var blockHash = response_bhash.data.blockHash; +var warnedProperties = {}; +var rARIA = new RegExp('^(aria)-[' + DOMProperty.ATTRIBUTE_NAME_CHAR + ']*$'); - // Iterate through each utxo - // append it to history - for (var i = 0; i < tx_data.length; i++) { - if (tx_data[i].confirmations == 0) { - continue; - } +function validateProperty(tagName, name, debugID) { + if (warnedProperties.hasOwnProperty(name) && warnedProperties[name]) { + return true; + } - history = history.concat({ - txid: tx_data[i].txid, - vout: tx_data[i].vout, - scriptPubKey: tx_data[i].scriptPubKey - }); + if (rARIA.test(name)) { + var lowerCasedName = name.toLowerCase(); + var standardName = DOMProperty.getPossibleStandardName.hasOwnProperty(lowerCasedName) ? DOMProperty.getPossibleStandardName[lowerCasedName] : null; - // How many satoshis do we have so far - satoshisSoFar = satoshisSoFar + tx_data[i].satoshis; - if (satoshisSoFar >= satoshisToSend + satoshisfeesToSend) { - break; - } - } + // If this is an aria-* attribute, but is not listed in the known DOM + // DOM properties, then it is an invalid aria-* attribute. + if (standardName == null) { + warnedProperties[name] = true; + return false; + } + // aria-* attributes should be lowercase; suggest the lowercase version. + if (name !== standardName) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Unknown ARIA attribute %s. Did you mean %s?%s', name, standardName, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + warnedProperties[name] = true; + return true; + } + } - // If we don't have enough address - // fail and tell user - if (satoshisSoFar < satoshisToSend + satoshisfeesToSend) { - this.setSendErrorMessage('Not enough confirmed ZEN in account to perform transaction'); - this.setProgressValue(0); - } + return true; +} - // If we don't have exact amount - // Refund remaining to current address - if (satoshisSoFar !== satoshisToSend + satoshisfeesToSend) { - var refundSatoshis = satoshisSoFar - satoshisToSend - satoshisfeesToSend; - recipients = recipients.concat({ address: senderAddress, satoshis: refundSatoshis }); - } +function warnInvalidARIAProps(debugID, element) { + var invalidProps = []; - // Create transaction - var txObj = _zencashjs2.default.transaction.createRawTx(history, recipients, blockHeight, blockHash); + for (var key in element.props) { + var isValid = validateProperty(element.type, key, debugID); + if (!isValid) { + invalidProps.push(key); + } + } - // Sign each history transcation - for (var i = 0; i < history.length; i++) { - txObj = _zencashjs2.default.transaction.signTx(txObj, i, senderPrivateKey, this.props.settings.compressPubKey); - } + var unknownPropString = invalidProps.map(function (prop) { + return '`' + prop + '`'; + }).join(', '); - // Convert it to hex string - var txHexString = _zencashjs2.default.transaction.serializeTx(txObj); + if (invalidProps.length === 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria prop %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } else if (invalidProps.length > 1) { + process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid aria props %s on <%s> tag. ' + 'For details, see https://fb.me/invalid-aria-prop%s', unknownPropString, element.type, ReactComponentTreeHook.getStackAddendumByID(debugID)) : void 0; + } +} - _axios2.default.post(sendRawTxURL, { rawtx: txHexString }).then(function (sendtx_resp) { - this.setState({ - sendProgress: 100, - sentTxid: sendtx_resp.data.txid - }); - }.bind(this)).catch(function (error) { - this.setSendErrorMessage(error + ''); - this.setProgressValue(0); - return; - }.bind(this)); - }.bind(this)); - }.bind(this)); - }.bind(this)).catch(function (error) { - this.setSendErrorMessage(error); - this.setProgressValue(0); - return; - }.bind(this)); +function handleElement(debugID, element) { + if (element == null || typeof element.type !== 'string') { + return; + } + if (element.type.indexOf('-') >= 0 || element.props.is) { + return; + } + + warnInvalidARIAProps(debugID, element); +} + +var ReactDOMInvalidARIAHook = { + onBeforeMountComponent: function (debugID, element) { + if (process.env.NODE_ENV !== 'production') { + handleElement(debugID, element); } - }, { - key: 'render', - value: function render() { - // If send was successful - var zenTxLink; - if (this.state.sendProgress === 100) { - var zentx = _utils2.default.urlAppend(this.props.settings.explorerURL, 'tx/') + this.state.sentTxid; - zenTxLink = _react2.default.createElement( - _reactstrap.Alert, - { color: 'success' }, - _react2.default.createElement( - 'strong', - null, - 'ZEN successfully sent!' - ), - ' ', - _react2.default.createElement( - 'a', - { href: zentx }, - 'Click here to view your transaction' - ) - ); - } + }, + onBeforeUpdateComponent: function (debugID, element) { + if (process.env.NODE_ENV !== 'production') { + handleElement(debugID, element); + } + } +}; - // Else show error why - else if (this.state.sendErrorMessage !== '') { - zenTxLink = this.state.sendErrorMessage.split(';').map(function (s) { - if (s !== '') { - return _react2.default.createElement( - _reactstrap.Alert, - { color: 'danger' }, - _react2.default.createElement( - 'strong', - null, - 'Error.' - ), - ' ', - s - ); - } - }); - } +module.exports = ReactDOMInvalidARIAHook; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - // Send addresses - // Key is the address btw - var sendAddresses = []; - Object.keys(this.props.publicAddresses).forEach(function (key) { - if (key !== undefined) { - sendAddresses.push(_react2.default.createElement( - 'option', - { value: key }, - '[', - this.props.publicAddresses[key].confirmedBalance, - '] - ', - key - )); - } - }.bind(this)); +/***/ }), +/* 315 */ +/***/ (function(module, exports, __webpack_require__) { - return _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - null, - _react2.default.createElement( - _reactstrap.Card, - null, - _react2.default.createElement( - _reactstrap.CardBlock, - null, - _react2.default.createElement( - _reactstrap.Alert, - { color: 'danger' }, - 'ALWAYS VALIDATE YOUR DESINATION ADDRESS BY SENDING SMALL AMOUNTS OF ZEN FIRST' - ), - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement( - _reactstrap.InputGroupAddon, - null, - 'From Address' - ), - _react2.default.createElement( - _reactstrap.Input, - { type: 'select', onChange: this.handleUpdateSelectedAddress }, - _react2.default.createElement('option', { value: '' }), - sendAddresses - ) - ), - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement( - _reactstrap.InputGroupAddon, - null, - 'To Address' - ), - _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateRecipientAddress, placeholder: 'e.g znSDvF9nA5VCdse5HbEKmsoNbjCbsEA3VAH' }) - ), - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement( - _reactstrap.InputGroupAddon, - null, - 'Amount' - ), - _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateAmount, placeholder: 'e.g 42' }) - ), - _react2.default.createElement( - _reactstrap.InputGroup, - null, - _react2.default.createElement( - _reactstrap.InputGroupAddon, - null, - 'Fee' - ), - _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateFee, placeholder: 'e.g 0.001' }) - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - _reactstrap.FormGroup, - { check: true }, - _react2.default.createElement( - _reactstrap.Label, - { check: true }, - _react2.default.createElement(_reactstrap.Input, { onChange: this.handleCheckChanged, type: 'checkbox' }), - ' ', - 'Yes, I would like to send these ZEN' - ) - ), - _react2.default.createElement('br', null), - _react2.default.createElement( - _reactstrap.Button, - { - color: 'warning', className: 'btn-block', - disabled: !this.state.confirmSend || this.state.sendProgress > 0 && this.state.sendProgress < 100, - onClick: this.handleSendZEN - }, - 'Send' - ) - ), - _react2.default.createElement( - _reactstrap.CardFooter, - null, - zenTxLink, - _react2.default.createElement(_reactstrap.Progress, { value: this.state.sendProgress }) - ) - ) - ) - ); - } - }]); +"use strict"; - return ZSendZEN; -}(_react2.default.Component); -var ZWalletSelectUnlockType = function (_React$Component7) { - _inherits(ZWalletSelectUnlockType, _React$Component7); +Object.defineProperty(exports, "__esModule", { + value: true +}); - function ZWalletSelectUnlockType(props) { - _classCallCheck(this, ZWalletSelectUnlockType); +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - var _this10 = _possibleConstructorReturn(this, (ZWalletSelectUnlockType.__proto__ || Object.getPrototypeOf(ZWalletSelectUnlockType)).call(this, props)); +var _react = __webpack_require__(6); - _this10.state = { cSelected: _this10.props.unlockType }; - return _this10; - } +var _react2 = _interopRequireDefault(_react); - _createClass(ZWalletSelectUnlockType, [{ - key: 'onRadioBtnClick', - value: function onRadioBtnClick(s) { - this.setState({ - cSelected: s - }); +var _reactstrap = __webpack_require__(93); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - this.props.setUnlockType(s); - } - }, { - key: 'render', - value: function render() { - var _this11 = this; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - return _react2.default.createElement( - 'div', - { style: { textAlign: 'center' } }, - _react2.default.createElement( - _reactstrap.ButtonGroup, - { vertical: true }, - _react2.default.createElement( - _reactstrap.Button, - { color: 'secondary', onClick: function onClick() { - return _this11.onRadioBtnClick(UNLOCK_WALLET_TYPE.HD_WALLET); - }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.HD_WALLET }, - 'Enter secret phrase' - ), - _react2.default.createElement( - _reactstrap.Button, - { color: 'secondary', onClick: function onClick() { - return _this11.onRadioBtnClick(UNLOCK_WALLET_TYPE.IMPORT_WALLET); - }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.IMPORT_WALLET }, - 'Load wallet.dat' - ), - _react2.default.createElement( - _reactstrap.Button, - { color: 'secondary', onClick: function onClick() { - return _this11.onRadioBtnClick(UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY); - }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY }, - 'Paste private key' - ) - ) - ); - } - }]); +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - return ZWalletSelectUnlockType; -}(_react2.default.Component); +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -var ZWalletTabs = function (_React$Component8) { - _inherits(ZWalletTabs, _React$Component8); +var ZNavbar = function (_React$Component) { + _inherits(ZNavbar, _React$Component); - function ZWalletTabs(props) { - _classCallCheck(this, ZWalletTabs); + function ZNavbar(props) { + _classCallCheck(this, ZNavbar); - var _this12 = _possibleConstructorReturn(this, (ZWalletTabs.__proto__ || Object.getPrototypeOf(ZWalletTabs)).call(this, props)); + var _this = _possibleConstructorReturn(this, (ZNavbar.__proto__ || Object.getPrototypeOf(ZNavbar)).call(this, props)); - _this12.toggleTabs = _this12.toggleTabs.bind(_this12); - _this12.state = { - activeTab: '1' + _this.toggleNavbar = _this.toggleNavbar.bind(_this); + _this.state = { + isOpen: false }; - return _this12; + return _this; } - _createClass(ZWalletTabs, [{ - key: 'toggleTabs', - value: function toggleTabs(tab) { - if (this.state.activeTab !== tab) { - this.setState({ - activeTab: tab - }); - } + _createClass(ZNavbar, [{ + key: 'toggleNavbar', + value: function toggleNavbar() { + this.setState({ + isOpen: !this.state.isOpen + }); } }, { key: 'render', value: function render() { - var _this13 = this; - return _react2.default.createElement( - 'div', - null, + _reactstrap.Navbar, + { color: 'faded', light: true, toggleable: true }, + _react2.default.createElement(_reactstrap.NavbarToggler, { right: true, onClick: this.toggleNavbar }), _react2.default.createElement( - _reactstrap.Nav, - { tabs: true }, + _reactstrap.NavbarBrand, + { href: '/' }, + _react2.default.createElement('img', { src: '/favicon.ico', height: 42 }), + '\xA0myzenwallet.io' + ), + _react2.default.createElement( + _reactstrap.Collapse, + { isOpen: this.state.isOpen, navbar: true }, _react2.default.createElement( - _reactstrap.NavItem, - null, + _reactstrap.Nav, + { className: 'ml-auto', navbar: true }, _react2.default.createElement( - _reactstrap.NavLink, - { - className: (0, _classnames2.default)({ active: this.state.activeTab === '1' }), - onClick: function onClick() { - _this13.toggleTabs('1'); - } - }, - 'Info' - ) - ), - _react2.default.createElement( - _reactstrap.NavItem, - null, + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: 'http://getzen.cash' }, + 'FREE ZEN' + ) + ), _react2.default.createElement( - _reactstrap.NavLink, - { - className: (0, _classnames2.default)({ active: this.state.activeTab === '2' }), - onClick: function onClick() { - _this13.toggleTabs('2'); - } - }, - 'Send ZEN' + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: '/faq.html' }, + 'FAQ' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { href: '/guide.html' }, + 'GETTING STARTED' + ) ) ) - ), - _react2.default.createElement( - _reactstrap.TabContent, - { activeTab: this.state.activeTab }, - _react2.default.createElement( - _reactstrap.TabPane, - { tabId: '1' }, - _react2.default.createElement(ZAddressInfo, { - publicAddresses: this.props.publicAddresses, - settings: this.props.settings, - setPublicAddressesKeyValue: this.props.setPublicAddressesKeyValue - }) - ), - _react2.default.createElement( - _reactstrap.TabPane, - { tabId: '2' }, - _react2.default.createElement(ZSendZEN, { - settings: this.props.settings, - publicAddresses: this.props.publicAddresses - }) - ) ) ); } }]); - return ZWalletTabs; + return ZNavbar; }(_react2.default.Component); -var ZWallet = function (_React$Component9) { - _inherits(ZWallet, _React$Component9); - - function ZWallet(props) { - _classCallCheck(this, ZWallet); - - var _this14 = _possibleConstructorReturn(this, (ZWallet.__proto__ || Object.getPrototypeOf(ZWallet)).call(this, props)); - - _this14.resetKeys = _this14.resetKeys.bind(_this14); - _this14.handleUnlockPrivateKeys = _this14.handleUnlockPrivateKeys.bind(_this14); - _this14.setPrivateKeys = _this14.setPrivateKeys.bind(_this14); - _this14.setInsightAPI = _this14.setInsightAPI.bind(_this14); - _this14.setUnlockType = _this14.setUnlockType.bind(_this14); - _this14.setPublicAddressesKeyValue = _this14.setPublicAddressesKeyValue.bind(_this14); - _this14.toggleUseTestNet = _this14.toggleUseTestNet.bind(_this14); - _this14.toggleCompressPubKey = _this14.toggleCompressPubKey.bind(_this14); - _this14.toggleShowSettings = _this14.toggleShowSettings.bind(_this14); - _this14.toggleShowWalletGen = _this14.toggleShowWalletGen.bind(_this14); - - _this14.state = { - privateKeys: '', - publicAddresses: null, // Public address will be {address: {privateKey: '', transactionURL: '', privateKeyWIF: ''} - settings: { - showSettings: false, - showWalletGen: false, - compressPubKey: true, - insightAPI: 'https://explorer.zensystem.io/insight-api-zen/', - explorerURL: 'https://explorer.zensystem.io/', - useTestNet: false, - unlockType: UNLOCK_WALLET_TYPE.HD_WALLET - } - }; - return _this14; - } - - _createClass(ZWallet, [{ - key: 'handleUnlockPrivateKeys', - value: function handleUnlockPrivateKeys() { - if (this.state.privateKeys.length === 0) { - return -2; - } - - try { - var _privKeyToAddr = function _privKeyToAddr(pk, compressPubKey, useTestNet) { - // If not 64 length, probs WIF format - if (pk.length !== 64) { - pk = _zencashjs2.default.address.WIFToPrivKey(pk); - } +exports.default = ZNavbar; - // Convert public key to public address - var pubKey = _zencashjs2.default.address.privKeyToPubKey(pk, compressPubKey); +/***/ }), +/* 316 */ +/***/ (function(module, exports, __webpack_require__) { - // Testnet or nah - var pubKeyHash = useTestNet ? _zencashjs2.default.config.testnet.pubKeyHash : _zencashjs2.default.config.mainnet.pubKeyHash; - var publicAddr = _zencashjs2.default.address.pubKeyToAddr(pubKey, pubKeyHash); +"use strict"; +/** + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ - return publicAddr; - }; - var publicAddresses = {}; - for (var i = 0; i < this.state.privateKeys.length; i++) { - var pubKeyHash = this.state.settings.useTestNet ? _zencashjs2.default.config.testnet.wif : _zencashjs2.default.config.mainnet.wif; +var emptyFunction = __webpack_require__(18); +var invariant = __webpack_require__(2); +var ReactPropTypesSecret = __webpack_require__(75); - var c_pk_wif; - var c_pk = this.state.privateKeys[i]; +module.exports = function() { + function shim(props, propName, componentName, location, propFullName, secret) { + if (secret === ReactPropTypesSecret) { + // It is still safe when called from React. + return; + } + invariant( + false, + 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' + + 'Use PropTypes.checkPropTypes() to call them. ' + + 'Read more at http://fb.me/use-check-prop-types' + ); + }; + shim.isRequired = shim; + function getShim() { + return shim; + }; + // Important! + // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`. + var ReactPropTypes = { + array: shim, + bool: shim, + func: shim, + number: shim, + object: shim, + string: shim, + symbol: shim, - // If not 64 length, probs WIF format - if (c_pk.length !== 64) { - c_pk_wif = c_pk; - c_pk = _zencashjs2.default.address.WIFToPrivKey(c_pk); - } else { - c_pk_wif = _zencashjs2.default.address.privKeyToWIF(c_pk); - } + any: shim, + arrayOf: getShim, + element: shim, + instanceOf: getShim, + node: shim, + objectOf: getShim, + oneOf: getShim, + oneOfType: getShim, + shape: getShim + }; - var c_pk_wif = _zencashjs2.default.address.privKeyToWIF(c_pk, true, pubKeyHash); - var c_addr = _privKeyToAddr(c_pk, this.state.settings.compressPubKey, this.state.settings.useTestNet); + ReactPropTypes.checkPropTypes = emptyFunction; + ReactPropTypes.PropTypes = ReactPropTypes; - publicAddresses[c_addr] = { - privateKey: c_pk, - privateKeyWIF: c_pk_wif, - transactionURL: _utils2.default.urlAppend(this.state.settings.explorerURL, 'address/') + c_addr, - confirmedBalance: 'loading...', - unconfirmedBalance: 'loading...' - }; - } + return ReactPropTypes; +}; - // Set public address - this.setPublicAddresses(publicAddresses); - // Return success - return 0; - } catch (err) { - this.setPublicAddresses(null); - return -1; - } - } - }, { - key: 'resetKeys', - value: function resetKeys() { - this.setState({ - privateKeys: '', - publicAddresses: null - }); - } +/***/ }), +/* 317 */ +/***/ (function(module, exports) { - // Only used for bip32 gen wallet because - // of the async nature +/** + * lodash 3.0.2 (Custom Build) <https://lodash.com/> + * Build: `lodash modern modularize exports="npm" -o ./` + * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license <https://lodash.com/license> + */ - }, { - key: 'setPrivateKeys', - value: function setPrivateKeys(pk, handleUnlockingKeys) { - if (handleUnlockingKeys === undefined) { - handleUnlockingKeys = false; - } - this.setState({ - privateKeys: pk - }, handleUnlockingKeys ? this.handleUnlockPrivateKeys : undefined); - } - }, { - key: 'setPublicAddresses', - value: function setPublicAddresses(pa) { - this.setState({ - publicAddresses: pa - }); - } - }, { - key: 'setPublicAddressesKeyValue', - value: function setPublicAddressesKeyValue(address, key, value) { - var newPublicAddresses = this.state.publicAddresses; - newPublicAddresses[address][key] = value; +/** + * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. + * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(1); + * // => false + */ +function isObject(value) { + // Avoid a V8 JIT bug in Chrome 19-20. + // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} - this.setState({ - publicAddresses: newPublicAddresses - }); - } - }, { - key: 'setInsightAPI', - value: function setInsightAPI(uri) { - var _settings = this.state.settings; - _settings.insightAPI = uri; +module.exports = isObject; - this.setState({ - _settings: _settings - }); - } - }, { - key: 'setUnlockType', - value: function setUnlockType(t) { - var _settings = this.state.settings; - _settings.unlockType = t; - this.setState({ - _settings: _settings - }); - } - }, { - key: 'toggleCompressPubKey', - value: function toggleCompressPubKey(b) { - var _settings = this.state.settings; - _settings.compressPubKey = !_settings.compressPubKey; +/***/ }), +/* 318 */ +/***/ (function(module, exports) { - this.setState({ - _settings: _settings - }); - } - }, { - key: 'toggleUseTestNet', - value: function toggleUseTestNet() { - var _settings = this.state.settings; - _settings.useTestNet = !_settings.useTestNet; +/** + * lodash 3.0.8 (Custom Build) <https://lodash.com/> + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation <http://dojofoundation.org/> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license <https://lodash.com/license> + */ - if (_settings.useTestNet) { - _settings.insightAPI = 'http://aayanl.tech:8081/insight-api-zen/'; - _settings.explorerURL = 'http://aayanl.tech:8081/'; - } else { - _settings.insightAPI = 'https://explorer.zensystem.io/insight-api-zen/'; - _settings.explorerURL = 'https://explorer.zensystem.io/insight/'; - } +/** `Object#toString` result references. */ +var funcTag = '[object Function]', + genTag = '[object GeneratorFunction]'; - this.setState({ - settings: _settings - }); - } - }, { - key: 'toggleShowSettings', - value: function toggleShowSettings() { - var _settings = this.state.settings; - _settings.showSettings = !_settings.showSettings; +/** Used for built-in method references. */ +var objectProto = Object.prototype; - this.setState({ - settings: _settings - }); - } - }, { - key: 'toggleShowWalletGen', - value: function toggleShowWalletGen() { - var _settings = this.state.settings; - _settings.showWalletGen = !_settings.showWalletGen; +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; - this.setState({ - settings: _settings - }); - } - }, { - key: 'render', - value: function render() { - return _react2.default.createElement( - _reactstrap.Container, - null, - _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - null, - _react2.default.createElement( - 'h1', - { className: 'display-6' }, - 'ZenCash Wallet\xA0', - _react2.default.createElement(ToolTipButton, { onClick: this.toggleShowSettings, id: 1, buttonText: _react2.default.createElement(_settings3.default, null), tooltipText: 'settings' }), - '\xA0', - _react2.default.createElement(ToolTipButton, { disabled: this.state.publicAddresses === null, onClick: this.resetKeys, id: 2, buttonText: _react2.default.createElement(_repeat2.default, null), tooltipText: 'reset wallet' }) - ), - _react2.default.createElement(ZWalletSettings, { - setUnlockType: this.setUnlockType, - toggleShowSettings: this.toggleShowSettings, - toggleCompressPubKey: this.toggleCompressPubKey, - toggleShowWalletGen: this.toggleShowWalletGen, - toggleUseTestNet: this.toggleUseTestNet, - setInsightAPI: this.setInsightAPI, - settings: this.state.settings, - publicAddresses: this.state.publicAddresses - }), - _react2.default.createElement('br', null) - ) - ), - _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - null, - this.state.publicAddresses === null ? _react2.default.createElement(ZWalletUnlockKey, { - handleUnlockPrivateKeys: this.handleUnlockPrivateKeys, - setPrivateKeys: this.setPrivateKeys, - unlockType: this.state.settings.unlockType - }) : _react2.default.createElement(ZWalletTabs, { - publicAddresses: this.state.publicAddresses, - settings: this.state.settings, - setPublicAddressesKeyValue: this.setPublicAddressesKeyValue, - privateKeys: this.state.privateKeys - }) - ) - ), - _react2.default.createElement( - _reactstrap.Row, - null, - _react2.default.createElement( - _reactstrap.Col, - null, - this.state.settings.showWalletGen ? _react2.default.createElement( - 'div', - null, - _react2.default.createElement('br', null), - _react2.default.createElement('hr', null), - _react2.default.createElement(ZWalletGenerator, { settings: this.state.settings }) - ) : null - ) - ) - ); - } - }]); +/** + * Checks if `value` is classified as a `Function` object. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isFunction(_); + * // => true + * + * _.isFunction(/abc/); + * // => false + */ +function isFunction(value) { + // The use of `Object#toString` avoids issues with the `typeof` operator + // in Safari 8 which returns 'object' for typed array constructors, and + // PhantomJS 1.9 which returns 'function' for `NodeList` instances. + var tag = isObject(value) ? objectToString.call(value) : ''; + return tag == funcTag || tag == genTag; +} - return ZWallet; -}(_react2.default.Component); +/** + * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. + * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +module.exports = isFunction; -exports.default = ZWallet; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) /***/ }), -/* 359 */ +/* 319 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; - - -exports.byteLength = byteLength -exports.toByteArray = toByteArray -exports.fromByteArray = fromByteArray +var require;var require;/*! tether 1.3.4 */ +(function(f){if(true){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Tether = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ +'use strict'; -var lookup = [] -var revLookup = [] -var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } -var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' -for (var i = 0, len = code.length; i < len; ++i) { - lookup[i] = code[i] - revLookup[code.charCodeAt(i)] = i -} +var _utils = require('./utils'); -revLookup['-'.charCodeAt(0)] = 62 -revLookup['_'.charCodeAt(0)] = 63 +var _utils2 = _interopRequireDefault(_utils); -function placeHoldersCount (b64) { - var len = b64.length - if (len % 4 > 0) { - throw new Error('Invalid string. Length must be a multiple of 4') - } +var _TetherBase$Utils = _utils2['default'].Utils; +var getBounds = _TetherBase$Utils.getBounds; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; - // the number of equal signs (place holders) - // if there are two placeholders, than the two characters before it - // represent one byte - // if there is only one, then the three characters before it represent 2 bytes - // this is just a cheap hack to not do indexOf twice - return b64[len - 2] === '=' ? 2 : b64[len - 1] === '=' ? 1 : 0 -} +_utils2['default'].modules.push({ + position: function position(_ref) { + var _this = this; -function byteLength (b64) { - // base64 is 4/3 + up to two characters of the original data - return (b64.length * 3 / 4) - placeHoldersCount(b64) -} + var top = _ref.top; + var left = _ref.left; -function toByteArray (b64) { - var i, l, tmp, placeHolders, arr - var len = b64.length - placeHolders = placeHoldersCount(b64) + var _cache = this.cache('element-bounds', function () { + return getBounds(_this.element); + }); - arr = new Arr((len * 3 / 4) - placeHolders) + var height = _cache.height; + var width = _cache.width; - // if there are placeholders, only get up to the last complete 4 chars - l = placeHolders > 0 ? len - 4 : len + var targetPos = this.getTargetBounds(); - var L = 0 + var bottom = top + height; + var right = left + width; - for (i = 0; i < l; i += 4) { - tmp = (revLookup[b64.charCodeAt(i)] << 18) | (revLookup[b64.charCodeAt(i + 1)] << 12) | (revLookup[b64.charCodeAt(i + 2)] << 6) | revLookup[b64.charCodeAt(i + 3)] - arr[L++] = (tmp >> 16) & 0xFF - arr[L++] = (tmp >> 8) & 0xFF - arr[L++] = tmp & 0xFF - } + var abutted = []; + if (top <= targetPos.bottom && bottom >= targetPos.top) { + ['left', 'right'].forEach(function (side) { + var targetPosSide = targetPos[side]; + if (targetPosSide === left || targetPosSide === right) { + abutted.push(side); + } + }); + } - if (placeHolders === 2) { - tmp = (revLookup[b64.charCodeAt(i)] << 2) | (revLookup[b64.charCodeAt(i + 1)] >> 4) - arr[L++] = tmp & 0xFF - } else if (placeHolders === 1) { - tmp = (revLookup[b64.charCodeAt(i)] << 10) | (revLookup[b64.charCodeAt(i + 1)] << 4) | (revLookup[b64.charCodeAt(i + 2)] >> 2) - arr[L++] = (tmp >> 8) & 0xFF - arr[L++] = tmp & 0xFF - } + if (left <= targetPos.right && right >= targetPos.left) { + ['top', 'bottom'].forEach(function (side) { + var targetPosSide = targetPos[side]; + if (targetPosSide === top || targetPosSide === bottom) { + abutted.push(side); + } + }); + } - return arr -} + var allClasses = []; + var addClasses = []; -function tripletToBase64 (num) { - return lookup[num >> 18 & 0x3F] + lookup[num >> 12 & 0x3F] + lookup[num >> 6 & 0x3F] + lookup[num & 0x3F] -} + var sides = ['left', 'top', 'right', 'bottom']; + allClasses.push(this.getClass('abutted')); + sides.forEach(function (side) { + allClasses.push(_this.getClass('abutted') + '-' + side); + }); -function encodeChunk (uint8, start, end) { - var tmp - var output = [] - for (var i = start; i < end; i += 3) { - tmp = (uint8[i] << 16) + (uint8[i + 1] << 8) + (uint8[i + 2]) - output.push(tripletToBase64(tmp)) - } - return output.join('') -} + if (abutted.length) { + addClasses.push(this.getClass('abutted')); + } -function fromByteArray (uint8) { - var tmp - var len = uint8.length - var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes - var output = '' - var parts = [] - var maxChunkLength = 16383 // must be multiple of 3 + abutted.forEach(function (side) { + addClasses.push(_this.getClass('abutted') + '-' + side); + }); - // go through the array every three bytes, we'll deal with trailing stuff later - for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) { - parts.push(encodeChunk(uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength))) - } + defer(function () { + if (!(_this.options.addTargetClasses === false)) { + updateClasses(_this.target, addClasses, allClasses); + } + updateClasses(_this.element, addClasses, allClasses); + }); - // pad the end with zeros, but make sure to not forget the extra bytes - if (extraBytes === 1) { - tmp = uint8[len - 1] - output += lookup[tmp >> 2] - output += lookup[(tmp << 4) & 0x3F] - output += '==' - } else if (extraBytes === 2) { - tmp = (uint8[len - 2] << 8) + (uint8[len - 1]) - output += lookup[tmp >> 10] - output += lookup[(tmp >> 4) & 0x3F] - output += lookup[(tmp << 2) & 0x3F] - output += '=' + return true; } +}); - parts.push(output) +},{"./utils":5}],2:[function(require,module,exports){ +'use strict'; - return parts.join('') -} +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } -/***/ }), -/* 360 */ -/***/ (function(module, exports) { +var _utils = require('./utils'); -exports.read = function (buffer, offset, isLE, mLen, nBytes) { - var e, m - var eLen = nBytes * 8 - mLen - 1 - var eMax = (1 << eLen) - 1 - var eBias = eMax >> 1 - var nBits = -7 - var i = isLE ? (nBytes - 1) : 0 - var d = isLE ? -1 : 1 - var s = buffer[offset + i] +var _utils2 = _interopRequireDefault(_utils); - i += d +var _TetherBase$Utils = _utils2['default'].Utils; +var getBounds = _TetherBase$Utils.getBounds; +var extend = _TetherBase$Utils.extend; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; - e = s & ((1 << (-nBits)) - 1) - s >>= (-nBits) - nBits += eLen - for (; nBits > 0; e = e * 256 + buffer[offset + i], i += d, nBits -= 8) {} +var BOUNDS_FORMAT = ['left', 'top', 'right', 'bottom']; - m = e & ((1 << (-nBits)) - 1) - e >>= (-nBits) - nBits += mLen - for (; nBits > 0; m = m * 256 + buffer[offset + i], i += d, nBits -= 8) {} +function getBoundingRect(tether, to) { + if (to === 'scrollParent') { + to = tether.scrollParents[0]; + } else if (to === 'window') { + to = [pageXOffset, pageYOffset, innerWidth + pageXOffset, innerHeight + pageYOffset]; + } - if (e === 0) { - e = 1 - eBias - } else if (e === eMax) { - return m ? NaN : ((s ? -1 : 1) * Infinity) - } else { - m = m + Math.pow(2, mLen) - e = e - eBias + if (to === document) { + to = to.documentElement; } - return (s ? -1 : 1) * m * Math.pow(2, e - mLen) -} -exports.write = function (buffer, value, offset, isLE, mLen, nBytes) { - var e, m, c - var eLen = nBytes * 8 - mLen - 1 - var eMax = (1 << eLen) - 1 - var eBias = eMax >> 1 - var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0) - var i = isLE ? 0 : (nBytes - 1) - var d = isLE ? 1 : -1 - var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0 + if (typeof to.nodeType !== 'undefined') { + (function () { + var node = to; + var size = getBounds(to); + var pos = size; + var style = getComputedStyle(to); - value = Math.abs(value) + to = [pos.left, pos.top, size.width + pos.left, size.height + pos.top]; - if (isNaN(value) || value === Infinity) { - m = isNaN(value) ? 1 : 0 - e = eMax - } else { - e = Math.floor(Math.log(value) / Math.LN2) - if (value * (c = Math.pow(2, -e)) < 1) { - e-- - c *= 2 - } - if (e + eBias >= 1) { - value += rt / c - } else { - value += rt * Math.pow(2, 1 - eBias) - } - if (value * c >= 2) { - e++ - c /= 2 - } + // Account any parent Frames scroll offset + if (node.ownerDocument !== document) { + var win = node.ownerDocument.defaultView; + to[0] += win.pageXOffset; + to[1] += win.pageYOffset; + to[2] += win.pageXOffset; + to[3] += win.pageYOffset; + } - if (e + eBias >= eMax) { - m = 0 - e = eMax - } else if (e + eBias >= 1) { - m = (value * c - 1) * Math.pow(2, mLen) - e = e + eBias - } else { - m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen) - e = 0 - } + BOUNDS_FORMAT.forEach(function (side, i) { + side = side[0].toUpperCase() + side.substr(1); + if (side === 'Top' || side === 'Left') { + to[i] += parseFloat(style['border' + side + 'Width']); + } else { + to[i] -= parseFloat(style['border' + side + 'Width']); + } + }); + })(); } - for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {} - - e = (e << mLen) | m - eLen += mLen - for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {} - - buffer[offset + i - d] |= s * 128 + return to; } +_utils2['default'].modules.push({ + position: function position(_ref) { + var _this = this; -/***/ }), -/* 361 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.SizePerPageDropDown = exports.ButtonGroup = exports.SearchField = exports.ClearSearchButton = exports.ExportCSVButton = exports.ShowSelectedOnlyButton = exports.DeleteButton = exports.InsertButton = exports.InsertModalFooter = exports.InsertModalBody = exports.InsertModalHeader = exports.TableHeaderColumn = exports.BootstrapTable = undefined; - -var _BootstrapTable = __webpack_require__(362); - -var _BootstrapTable2 = _interopRequireDefault(_BootstrapTable); + var top = _ref.top; + var left = _ref.left; + var targetAttachment = _ref.targetAttachment; -var _TableHeaderColumn = __webpack_require__(284); + if (!this.options.constraints) { + return true; + } -var _TableHeaderColumn2 = _interopRequireDefault(_TableHeaderColumn); + var _cache = this.cache('element-bounds', function () { + return getBounds(_this.element); + }); -var _InsertModalHeader = __webpack_require__(292); + var height = _cache.height; + var width = _cache.width; -var _InsertModalHeader2 = _interopRequireDefault(_InsertModalHeader); + if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { + var _lastSize = this.lastSize; -var _InsertModalBody = __webpack_require__(294); + // Handle the item getting hidden as a result of our positioning without glitching + // the classes in and out + width = _lastSize.width; + height = _lastSize.height; + } -var _InsertModalBody2 = _interopRequireDefault(_InsertModalBody); + var targetSize = this.cache('target-bounds', function () { + return _this.getTargetBounds(); + }); -var _InsertModalFooter = __webpack_require__(293); + var targetHeight = targetSize.height; + var targetWidth = targetSize.width; -var _InsertModalFooter2 = _interopRequireDefault(_InsertModalFooter); + var allClasses = [this.getClass('pinned'), this.getClass('out-of-bounds')]; -var _InsertButton = __webpack_require__(295); + this.options.constraints.forEach(function (constraint) { + var outOfBoundsClass = constraint.outOfBoundsClass; + var pinnedClass = constraint.pinnedClass; -var _InsertButton2 = _interopRequireDefault(_InsertButton); + if (outOfBoundsClass) { + allClasses.push(outOfBoundsClass); + } + if (pinnedClass) { + allClasses.push(pinnedClass); + } + }); -var _DeleteButton = __webpack_require__(296); + allClasses.forEach(function (cls) { + ['left', 'top', 'right', 'bottom'].forEach(function (side) { + allClasses.push(cls + '-' + side); + }); + }); -var _DeleteButton2 = _interopRequireDefault(_DeleteButton); + var addClasses = []; -var _ExportCSVButton = __webpack_require__(297); + var tAttachment = extend({}, targetAttachment); + var eAttachment = extend({}, this.attachment); -var _ExportCSVButton2 = _interopRequireDefault(_ExportCSVButton); + this.options.constraints.forEach(function (constraint) { + var to = constraint.to; + var attachment = constraint.attachment; + var pin = constraint.pin; -var _ShowSelectedOnlyButton = __webpack_require__(298); + if (typeof attachment === 'undefined') { + attachment = ''; + } -var _ShowSelectedOnlyButton2 = _interopRequireDefault(_ShowSelectedOnlyButton); + var changeAttachX = undefined, + changeAttachY = undefined; + if (attachment.indexOf(' ') >= 0) { + var _attachment$split = attachment.split(' '); -var _ClearSearchButton = __webpack_require__(300); + var _attachment$split2 = _slicedToArray(_attachment$split, 2); -var _ClearSearchButton2 = _interopRequireDefault(_ClearSearchButton); + changeAttachY = _attachment$split2[0]; + changeAttachX = _attachment$split2[1]; + } else { + changeAttachX = changeAttachY = attachment; + } -var _SearchField = __webpack_require__(299); + var bounds = getBoundingRect(_this, to); -var _SearchField2 = _interopRequireDefault(_SearchField); + if (changeAttachY === 'target' || changeAttachY === 'both') { + if (top < bounds[1] && tAttachment.top === 'top') { + top += targetHeight; + tAttachment.top = 'bottom'; + } -var _ButtonGroup = __webpack_require__(399); + if (top + height > bounds[3] && tAttachment.top === 'bottom') { + top -= targetHeight; + tAttachment.top = 'top'; + } + } -var _ButtonGroup2 = _interopRequireDefault(_ButtonGroup); + if (changeAttachY === 'together') { + if (tAttachment.top === 'top') { + if (eAttachment.top === 'bottom' && top < bounds[1]) { + top += targetHeight; + tAttachment.top = 'bottom'; -var _SizePerPageDropDown = __webpack_require__(287); + top += height; + eAttachment.top = 'top'; + } else if (eAttachment.top === 'top' && top + height > bounds[3] && top - (height - targetHeight) >= bounds[1]) { + top -= height - targetHeight; + tAttachment.top = 'bottom'; -var _SizePerPageDropDown2 = _interopRequireDefault(_SizePerPageDropDown); + eAttachment.top = 'bottom'; + } + } -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + if (tAttachment.top === 'bottom') { + if (eAttachment.top === 'top' && top + height > bounds[3]) { + top -= targetHeight; + tAttachment.top = 'top'; -if (typeof window !== 'undefined') { - window.BootstrapTable = _BootstrapTable2.default; - window.TableHeaderColumn = _TableHeaderColumn2.default; - window.InsertModalHeader = _InsertModalHeader2.default; - window.InsertModalBody = _InsertModalBody2.default; - window.InsertModalFooter = _InsertModalFooter2.default; - window.InsertButton = _InsertButton2.default; - window.DeleteButton = _DeleteButton2.default; - window.ShowSelectedOnlyButton = _ShowSelectedOnlyButton2.default; - window.ExportCSVButton = _ExportCSVButton2.default; - window.ClearSearchButton = _ClearSearchButton2.default; - window.SearchField = _SearchField2.default; - window.ButtonGroup = _ButtonGroup2.default; - window.SizePerPageDropDown = _SizePerPageDropDown2.default; -} -exports.BootstrapTable = _BootstrapTable2.default; -exports.TableHeaderColumn = _TableHeaderColumn2.default; -exports.InsertModalHeader = _InsertModalHeader2.default; -exports.InsertModalBody = _InsertModalBody2.default; -exports.InsertModalFooter = _InsertModalFooter2.default; -exports.InsertButton = _InsertButton2.default; -exports.DeleteButton = _DeleteButton2.default; -exports.ShowSelectedOnlyButton = _ShowSelectedOnlyButton2.default; -exports.ExportCSVButton = _ExportCSVButton2.default; -exports.ClearSearchButton = _ClearSearchButton2.default; -exports.SearchField = _SearchField2.default; -exports.ButtonGroup = _ButtonGroup2.default; -exports.SizePerPageDropDown = _SizePerPageDropDown2.default; -; + top -= height; + eAttachment.top = 'bottom'; + } else if (eAttachment.top === 'bottom' && top < bounds[1] && top + (height * 2 - targetHeight) <= bounds[3]) { + top += height - targetHeight; + tAttachment.top = 'top'; -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } -}(); + eAttachment.top = 'top'; + } + } -; + if (tAttachment.top === 'middle') { + if (top + height > bounds[3] && eAttachment.top === 'top') { + top -= height; + eAttachment.top = 'bottom'; + } else if (top < bounds[1] && eAttachment.top === 'bottom') { + top += height; + eAttachment.top = 'top'; + } + } + } -/***/ }), -/* 362 */ -/***/ (function(module, exports, __webpack_require__) { + if (changeAttachX === 'target' || changeAttachX === 'both') { + if (left < bounds[0] && tAttachment.left === 'left') { + left += targetWidth; + tAttachment.left = 'right'; + } -"use strict"; + if (left + width > bounds[2] && tAttachment.left === 'right') { + left -= targetWidth; + tAttachment.left = 'left'; + } + } + if (changeAttachX === 'together') { + if (left < bounds[0] && tAttachment.left === 'left') { + if (eAttachment.left === 'right') { + left += targetWidth; + tAttachment.left = 'right'; -Object.defineProperty(exports, "__esModule", { - value: true -}); + left += width; + eAttachment.left = 'left'; + } else if (eAttachment.left === 'left') { + left += targetWidth; + tAttachment.left = 'right'; -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; + left -= width; + eAttachment.left = 'right'; + } + } else if (left + width > bounds[2] && tAttachment.left === 'right') { + if (eAttachment.left === 'left') { + left -= targetWidth; + tAttachment.left = 'left'; -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + left -= width; + eAttachment.left = 'right'; + } else if (eAttachment.left === 'right') { + left -= targetWidth; + tAttachment.left = 'left'; -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + left += width; + eAttachment.left = 'left'; + } + } else if (tAttachment.left === 'center') { + if (left + width > bounds[2] && eAttachment.left === 'left') { + left -= width; + eAttachment.left = 'right'; + } else if (left < bounds[0] && eAttachment.left === 'right') { + left += width; + eAttachment.left = 'left'; + } + } + } -var _react = __webpack_require__(4); + if (changeAttachY === 'element' || changeAttachY === 'both') { + if (top < bounds[1] && eAttachment.top === 'bottom') { + top += height; + eAttachment.top = 'top'; + } -var _react2 = _interopRequireDefault(_react); + if (top + height > bounds[3] && eAttachment.top === 'top') { + top -= height; + eAttachment.top = 'bottom'; + } + } -var _propTypes = __webpack_require__(9); + if (changeAttachX === 'element' || changeAttachX === 'both') { + if (left < bounds[0]) { + if (eAttachment.left === 'right') { + left += width; + eAttachment.left = 'left'; + } else if (eAttachment.left === 'center') { + left += width / 2; + eAttachment.left = 'left'; + } + } -var _propTypes2 = _interopRequireDefault(_propTypes); + if (left + width > bounds[2]) { + if (eAttachment.left === 'left') { + left -= width; + eAttachment.left = 'right'; + } else if (eAttachment.left === 'center') { + left -= width / 2; + eAttachment.left = 'right'; + } + } + } -var _classnames = __webpack_require__(29); + if (typeof pin === 'string') { + pin = pin.split(',').map(function (p) { + return p.trim(); + }); + } else if (pin === true) { + pin = ['top', 'left', 'right', 'bottom']; + } -var _classnames2 = _interopRequireDefault(_classnames); + pin = pin || []; -var _reactSAlert = __webpack_require__(282); + var pinned = []; + var oob = []; -var _reactSAlert2 = _interopRequireDefault(_reactSAlert); + if (top < bounds[1]) { + if (pin.indexOf('top') >= 0) { + top = bounds[1]; + pinned.push('top'); + } else { + oob.push('top'); + } + } -var _Const = __webpack_require__(22); + if (top + height > bounds[3]) { + if (pin.indexOf('bottom') >= 0) { + top = bounds[3] - height; + pinned.push('bottom'); + } else { + oob.push('bottom'); + } + } -var _Const2 = _interopRequireDefault(_Const); + if (left < bounds[0]) { + if (pin.indexOf('left') >= 0) { + left = bounds[0]; + pinned.push('left'); + } else { + oob.push('left'); + } + } -var _TableHeaderColumn = __webpack_require__(284); + if (left + width > bounds[2]) { + if (pin.indexOf('right') >= 0) { + left = bounds[2] - width; + pinned.push('right'); + } else { + oob.push('right'); + } + } -var _TableHeaderColumn2 = _interopRequireDefault(_TableHeaderColumn); + if (pinned.length) { + (function () { + var pinnedClass = undefined; + if (typeof _this.options.pinnedClass !== 'undefined') { + pinnedClass = _this.options.pinnedClass; + } else { + pinnedClass = _this.getClass('pinned'); + } -var _TableHeader = __webpack_require__(371); + addClasses.push(pinnedClass); + pinned.forEach(function (side) { + addClasses.push(pinnedClass + '-' + side); + }); + })(); + } -var _TableHeader2 = _interopRequireDefault(_TableHeader); + if (oob.length) { + (function () { + var oobClass = undefined; + if (typeof _this.options.outOfBoundsClass !== 'undefined') { + oobClass = _this.options.outOfBoundsClass; + } else { + oobClass = _this.getClass('out-of-bounds'); + } -var _TableBody = __webpack_require__(374); + addClasses.push(oobClass); + oob.forEach(function (side) { + addClasses.push(oobClass + '-' + side); + }); + })(); + } -var _TableBody2 = _interopRequireDefault(_TableBody); + if (pinned.indexOf('left') >= 0 || pinned.indexOf('right') >= 0) { + eAttachment.left = tAttachment.left = false; + } + if (pinned.indexOf('top') >= 0 || pinned.indexOf('bottom') >= 0) { + eAttachment.top = tAttachment.top = false; + } -var _PaginationList = __webpack_require__(379); + if (tAttachment.top !== targetAttachment.top || tAttachment.left !== targetAttachment.left || eAttachment.top !== _this.attachment.top || eAttachment.left !== _this.attachment.left) { + _this.updateAttachClasses(eAttachment, tAttachment); + _this.trigger('update', { + attachment: eAttachment, + targetAttachment: tAttachment + }); + } + }); -var _PaginationList2 = _interopRequireDefault(_PaginationList); + defer(function () { + if (!(_this.options.addTargetClasses === false)) { + updateClasses(_this.target, addClasses, allClasses); + } + updateClasses(_this.element, addClasses, allClasses); + }); -var _ToolBar = __webpack_require__(381); + return { top: top, left: left }; + } +}); -var _ToolBar2 = _interopRequireDefault(_ToolBar); +},{"./utils":5}],3:[function(require,module,exports){ +'use strict'; -var _TableFilter = __webpack_require__(392); +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); -var _TableFilter2 = _interopRequireDefault(_TableFilter); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } -var _TableDataStore = __webpack_require__(393); +var _utils = require('./utils'); -var _util = __webpack_require__(68); +var _utils2 = _interopRequireDefault(_utils); -var _util2 = _interopRequireDefault(_util); +_utils2['default'].modules.push({ + position: function position(_ref) { + var top = _ref.top; + var left = _ref.left; -var _csv_export_util = __webpack_require__(394); + if (!this.options.shift) { + return; + } -var _csv_export_util2 = _interopRequireDefault(_csv_export_util); + var shift = this.options.shift; + if (typeof this.options.shift === 'function') { + shift = this.options.shift.call(this, { top: top, left: left }); + } -var _Filter = __webpack_require__(398); + var shiftTop = undefined, + shiftLeft = undefined; + if (typeof shift === 'string') { + shift = shift.split(' '); + shift[1] = shift[1] || shift[0]; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + var _shift = shift; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + var _shift2 = _slicedToArray(_shift, 2); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + shiftTop = _shift2[0]; + shiftLeft = _shift2[1]; -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } /* eslint no-alert: 0 */ -/* eslint max-len: 0 */ + shiftTop = parseFloat(shiftTop, 10); + shiftLeft = parseFloat(shiftLeft, 10); + } else { + shiftTop = shift.top; + shiftLeft = shift.left; + } + top += shiftTop; + left += shiftLeft; -var BootstrapTable = function (_Component) { - _inherits(BootstrapTable, _Component); + return { top: top, left: left }; + } +}); - function BootstrapTable(props) { - _classCallCheck(this, BootstrapTable); +},{"./utils":5}],4:[function(require,module,exports){ +/* globals performance */ - var _this = _possibleConstructorReturn(this, (BootstrapTable.__proto__ || Object.getPrototypeOf(BootstrapTable)).call(this, props)); +'use strict'; - _this.handleSort = function () { - return _this.__handleSort__REACT_HOT_LOADER__.apply(_this, arguments); - }; +Object.defineProperty(exports, '__esModule', { + value: true +}); - _this.handleExpandRow = function () { - return _this.__handleExpandRow__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); - _this.handlePaginationData = function () { - return _this.__handlePaginationData__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); - _this.handleMouseLeave = function () { - return _this.__handleMouseLeave__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var _get = function get(_x6, _x7, _x8) { var _again = true; _function: while (_again) { var object = _x6, property = _x7, receiver = _x8; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x6 = parent; _x7 = property; _x8 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } }; - _this.handleMouseEnter = function () { - return _this.__handleMouseEnter__REACT_HOT_LOADER__.apply(_this, arguments); - }; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } - _this.handleRowMouseOut = function () { - return _this.__handleRowMouseOut__REACT_HOT_LOADER__.apply(_this, arguments); - }; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } - _this.handleRowMouseOver = function () { - return _this.__handleRowMouseOver__REACT_HOT_LOADER__.apply(_this, arguments); - }; +function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - _this.handleNavigateCell = function () { - return _this.__handleNavigateCell__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var _utils = require('./utils'); - _this.handleRowClick = function () { - return _this.__handleRowClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var _utils2 = _interopRequireDefault(_utils); - _this.handleRowDoubleClick = function () { - return _this.__handleRowDoubleClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; +require('./constraint'); - _this.handleSelectAllRow = function () { - return _this.__handleSelectAllRow__REACT_HOT_LOADER__.apply(_this, arguments); - }; +require('./abutment'); - _this.handleShowOnlySelected = function () { - return _this.__handleShowOnlySelected__REACT_HOT_LOADER__.apply(_this, arguments); - }; +require('./shift'); - _this.handleSelectRow = function () { - return _this.__handleSelectRow__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var _TetherBase$Utils = _utils2['default'].Utils; +var getScrollParents = _TetherBase$Utils.getScrollParents; +var getBounds = _TetherBase$Utils.getBounds; +var getOffsetParent = _TetherBase$Utils.getOffsetParent; +var extend = _TetherBase$Utils.extend; +var addClass = _TetherBase$Utils.addClass; +var removeClass = _TetherBase$Utils.removeClass; +var updateClasses = _TetherBase$Utils.updateClasses; +var defer = _TetherBase$Utils.defer; +var flush = _TetherBase$Utils.flush; +var getScrollBarSize = _TetherBase$Utils.getScrollBarSize; +var removeUtilElements = _TetherBase$Utils.removeUtilElements; +var Evented = _TetherBase$Utils.Evented; - _this.handleEditCell = function () { - return _this.__handleEditCell__REACT_HOT_LOADER__.apply(_this, arguments); - }; +function within(a, b) { + var diff = arguments.length <= 2 || arguments[2] === undefined ? 1 : arguments[2]; - _this.handleAddRow = function () { - return _this.__handleAddRow__REACT_HOT_LOADER__.apply(_this, arguments); - }; + return a + diff >= b && b >= a - diff; +} - _this.getPageByRowKey = function () { - return _this.__getPageByRowKey__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var transformKey = (function () { + if (typeof document === 'undefined') { + return ''; + } + var el = document.createElement('div'); - _this.handleDropRow = function () { - return _this.__handleDropRow__REACT_HOT_LOADER__.apply(_this, arguments); - }; + var transforms = ['transform', 'WebkitTransform', 'OTransform', 'MozTransform', 'msTransform']; + for (var i = 0; i < transforms.length; ++i) { + var key = transforms[i]; + if (el.style[key] !== undefined) { + return key; + } + } +})(); - _this.handleFilterData = function () { - return _this.__handleFilterData__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var tethers = []; - _this.handleExportCSV = function () { - return _this.__handleExportCSV__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var position = function position() { + tethers.forEach(function (tether) { + tether.position(false); + }); + flush(); +}; - _this.handleSearch = function () { - return _this.__handleSearch__REACT_HOT_LOADER__.apply(_this, arguments); - }; +function now() { + if (typeof performance !== 'undefined' && typeof performance.now !== 'undefined') { + return performance.now(); + } + return +new Date(); +} - _this._scrollTop = function () { - return _this.___scrollTop__REACT_HOT_LOADER__.apply(_this, arguments); - }; +(function () { + var lastCall = null; + var lastDuration = null; + var pendingTimeout = null; - _this._scrollHeader = function () { - return _this.___scrollHeader__REACT_HOT_LOADER__.apply(_this, arguments); - }; + var tick = function tick() { + if (typeof lastDuration !== 'undefined' && lastDuration > 16) { + // We voluntarily throttle ourselves if we can't manage 60fps + lastDuration = Math.min(lastDuration - 16, 250); - _this.isIE = false; - if (_util2.default.canUseDOM()) { - _this.isIE = document.documentMode; + // Just in case this is the last event, remember to position just once more + pendingTimeout = setTimeout(tick, 250); + return; } - _this.store = new _TableDataStore.TableDataStore(_this.props.data ? _this.props.data.slice() : []); - _this.isVerticalScroll = false; - _this.initTable(_this.props); - if (_this.props.selectRow && _this.props.selectRow.selected) { - var copy = _this.props.selectRow.selected.slice(); - _this.store.setSelectedRowKey(copy); + if (typeof lastCall !== 'undefined' && now() - lastCall < 10) { + // Some browsers call events a little too frequently, refuse to run more than is reasonable + return; } - var currPage = _Const2.default.PAGE_START_INDEX; - if (typeof _this.props.options.page !== 'undefined') { - currPage = _this.props.options.page; - } else if (typeof _this.props.options.pageStartIndex !== 'undefined') { - currPage = _this.props.options.pageStartIndex; + + if (pendingTimeout != null) { + clearTimeout(pendingTimeout); + pendingTimeout = null; } - _this._adjustHeaderWidth = _this._adjustHeaderWidth.bind(_this); - _this._adjustHeight = _this._adjustHeight.bind(_this); - _this._adjustTable = _this._adjustTable.bind(_this); + lastCall = now(); + position(); + lastDuration = now() - lastCall; + }; - _this.state = { - data: _this.getTableData(), - currPage: currPage, - expanding: _this.props.options.expanding || [], - sizePerPage: _this.props.options.sizePerPage || _Const2.default.SIZE_PER_PAGE_LIST[0], - selectedRowKeys: _this.store.getSelectedRowKeys(), - reset: false, - x: _this.props.keyBoardNav ? 0 : -1, - y: _this.props.keyBoardNav ? 0 : -1 - }; - return _this; + if (typeof window !== 'undefined' && typeof window.addEventListener !== 'undefined') { + ['resize', 'scroll', 'touchmove'].forEach(function (event) { + window.addEventListener(event, tick); + }); } +})(); - _createClass(BootstrapTable, [{ - key: 'initTable', - value: function initTable(props) { - var _this2 = this; - - var keyField = props.keyField; - - - var isKeyFieldDefined = typeof keyField === 'string' && keyField.length; - _react2.default.Children.forEach(props.children, function (column) { - if (column === null || column === undefined) { - // Skip null and undefined value - return; - } - if (column.props.isKey) { - if (keyField) { - throw new Error('Error. Multiple key column be detected in TableHeaderColumn.'); - } - keyField = column.props.dataField; - } - if (column.props.filter) { - // a column contains a filter - if (!_this2.filter) { - // first time create the filter on the BootstrapTable - _this2.filter = new _Filter.Filter(); - } - // pass the filter to column with filter - column.props.filter.emitter = _this2.filter; - } - }); - - if (this.filter) { - this.filter.removeAllListeners('onFilterChange'); - this.filter.on('onFilterChange', function (currentFilter) { - _this2.handleFilterData(currentFilter); - }); - } +var MIRROR_LR = { + center: 'center', + left: 'right', + right: 'left' +}; - this.colInfos = this.getColumnsDescription(props).reduce(function (prev, curr) { - prev[curr.name] = curr; - return prev; - }, {}); +var MIRROR_TB = { + middle: 'middle', + top: 'bottom', + bottom: 'top' +}; - if (!isKeyFieldDefined && !keyField) { - throw new Error('Error. No any key column defined in TableHeaderColumn.\n Use \'isKey={true}\' to specify a unique column after version 0.5.4.'); - } +var OFFSET_MAP = { + top: 0, + left: 0, + middle: '50%', + center: '50%', + bottom: '100%', + right: '100%' +}; - this.store.setProps({ - isPagination: props.pagination, - keyField: keyField, - colInfos: this.colInfos, - multiColumnSearch: props.multiColumnSearch, - strictSearch: props.strictSearch, - multiColumnSort: props.multiColumnSort, - remote: this.props.remote - }); - } - }, { - key: 'getTableData', - value: function getTableData() { - var result = []; - var _props = this.props, - options = _props.options, - pagination = _props.pagination; +var autoToFixedAttachment = function autoToFixedAttachment(attachment, relativeToAttachment) { + var left = attachment.left; + var top = attachment.top; - var sortName = options.defaultSortName || options.sortName; - var sortOrder = options.defaultSortOrder || options.sortOrder; - var searchText = options.defaultSearch; + if (left === 'auto') { + left = MIRROR_LR[relativeToAttachment.left]; + } - if (sortName && sortOrder) { - this.store.setSortInfo(sortOrder, sortName); - if (!this.allowRemote(_Const2.default.REMOTE_SORT)) { - this.store.sort(); - } - } + if (top === 'auto') { + top = MIRROR_TB[relativeToAttachment.top]; + } - if (searchText) { - this.store.search(searchText); - } + return { left: left, top: top }; +}; - if (pagination) { - var page = void 0; - var sizePerPage = void 0; - if (this.store.isChangedPage()) { - sizePerPage = this.state.sizePerPage; - page = this.state.currPage; - } else { - sizePerPage = options.sizePerPage || _Const2.default.SIZE_PER_PAGE_LIST[0]; - page = options.page || 1; - } - result = this.store.page(page, sizePerPage).get(); - } else { - result = this.store.get(); - } - return result; - } - }, { - key: 'getColumnsDescription', - value: function getColumnsDescription(_ref) { - var _this3 = this; +var attachmentToOffset = function attachmentToOffset(attachment) { + var left = attachment.left; + var top = attachment.top; - var children = _ref.children; + if (typeof OFFSET_MAP[attachment.left] !== 'undefined') { + left = OFFSET_MAP[attachment.left]; + } - var rowCount = 0; - _react2.default.Children.forEach(children, function (column) { - if (column === null || column === undefined) { - // Skip null and undefined value - return; - } + if (typeof OFFSET_MAP[attachment.top] !== 'undefined') { + top = OFFSET_MAP[attachment.top]; + } - if (Number(column.props.row) > rowCount) { - rowCount = Number(column.props.row); - } - }); - return _react2.default.Children.map(children, function (column, i) { - if (column === null || column === undefined) { - // Return null for empty objects - return null; - } + return { left: left, top: top }; +}; - var rowIndex = column.props.row ? Number(column.props.row) : 0; - var rowSpan = column.props.rowSpan ? Number(column.props.rowSpan) : 1; - if (rowSpan + rowIndex === rowCount + 1) { - var columnDescription = _this3.getColumnDescription(column); +function addOffset() { + var out = { top: 0, left: 0 }; - columnDescription.index = i; - return columnDescription; - } - }); - } - }, { - key: 'getColumnDescription', - value: function getColumnDescription(column) { - var columnDescription = { - name: column.props.dataField, - align: column.props.dataAlign, - sort: column.props.dataSort, - format: column.props.dataFormat, - formatExtraData: column.props.formatExtraData, - filterFormatted: column.props.filterFormatted, - filterValue: column.props.filterValue, - editable: column.props.editable, - customEditor: column.props.customEditor, - hidden: column.props.hidden, - hiddenOnInsert: column.props.hiddenOnInsert, - searchable: column.props.searchable, - className: column.props.columnClassName, - editClassName: column.props.editColumnClassName, - invalidEditColumnClassName: column.props.invalidEditColumnClassName, - columnTitle: column.props.columnTitle, - width: column.props.width, - text: column.props.headerText || column.props.children, - sortFunc: column.props.sortFunc, - sortFuncExtraData: column.props.sortFuncExtraData, - export: column.props.export, - expandable: column.props.expandable, - attrs: column.props.tdAttr, - editAttrs: column.props.editTdAttr, - style: column.props.tdStyle - }; + for (var _len = arguments.length, offsets = Array(_len), _key = 0; _key < _len; _key++) { + offsets[_key] = arguments[_key]; + } - if (column.type.name !== _TableHeaderColumn2.default.name && _react2.default.isValidElement(column.props.children)) { - columnDescription = _extends({}, columnDescription, this.getColumnDescription(_react2.default.Children.only(column.props.children))); - } + offsets.forEach(function (_ref) { + var top = _ref.top; + var left = _ref.left; - return columnDescription; + if (typeof top === 'string') { + top = parseFloat(top, 10); } - }, { - key: 'reset', - value: function reset() { - var _this4 = this; - - var pageStartIndex = this.props.options.pageStartIndex; - - this.store.clean(); - this.setState(function () { - return { - data: _this4.getTableData(), - currPage: _util2.default.getFirstPage(pageStartIndex), - expanding: [], - sizePerPage: _Const2.default.SIZE_PER_PAGE_LIST[0], - selectedRowKeys: _this4.store.getSelectedRowKeys(), - reset: true - }; - }); + if (typeof left === 'string') { + left = parseFloat(left, 10); } - }, { - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - this.initTable(nextProps); - var options = nextProps.options, - selectRow = nextProps.selectRow; - var replace = nextProps.replace; - - replace = replace || this.props.replace; - if (!nextProps.data) { - return; - } - this.store.setData(nextProps.data.slice()); + out.top += top; + out.left += left; + }); - if (!replace) { - // from #481 - var page = this.state.currPage; - if (this.props.options.page !== options.page) { - page = options.page; - } - // from #481 - var sizePerPage = this.state.sizePerPage; - if (this.props.options.sizePerPage !== options.sizePerPage) { - sizePerPage = options.sizePerPage; - } + return out; +} - if (this.isRemoteDataSource()) { - var data = nextProps.data.slice(); - if (nextProps.pagination && !this.allowRemote(_Const2.default.REMOTE_PAGE)) { - data = this.store.page(page, sizePerPage).get(); - } - this.setState(function () { - return { - data: data, - currPage: page, - sizePerPage: sizePerPage, - reset: false - }; - }); - } else { - // #125 - // remove !options.page for #709 - if (page > Math.ceil(nextProps.data.length / sizePerPage)) { - page = 1; - } - var sortList = this.store.getSortInfo(); - var sortField = options.sortName; - var sortOrder = options.sortOrder; - if (sortField && sortOrder) { - this.store.setSortInfo(sortOrder, sortField); - this.store.sort(); - } else if (sortList.length > 0) { - this.store.sort(); - } - var _data = this.store.page(page, sizePerPage).get(); - this.setState(function () { - return { - data: _data, - currPage: page, - sizePerPage: sizePerPage, - reset: false - }; - }); +function offsetToPx(offset, size) { + if (typeof offset.left === 'string' && offset.left.indexOf('%') !== -1) { + offset.left = parseFloat(offset.left, 10) / 100 * size.width; + } + if (typeof offset.top === 'string' && offset.top.indexOf('%') !== -1) { + offset.top = parseFloat(offset.top, 10) / 100 * size.height; + } - if (this.store.isSearching && options.afterSearch) { - options.afterSearch(this.store.searchText, this.store.getDataIgnoringPagination()); - } + return offset; +} - if (this.store.isFiltering && options.afterColumnFilter) { - options.afterColumnFilter(this.store.filterObj, this.store.getDataIgnoringPagination()); - } - } +var parseOffset = function parseOffset(value) { + var _value$split = value.split(' '); - // If setting the expanded rows is being handled externally - // then overwrite the current expanded rows. - if (this.props.options.expanding !== options.expanding) { - this.setState(function () { - return { - expanding: options.expanding || [] - }; - }); - } + var _value$split2 = _slicedToArray(_value$split, 2); - if (selectRow && selectRow.selected) { - // set default select rows to store. - var copy = selectRow.selected.slice(); - this.store.setSelectedRowKey(copy); - this.setState(function () { - return { - selectedRowKeys: copy, - reset: false - }; - }); - } - } else { - this.reset(); - } - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - this._adjustTable(); - window.addEventListener('resize', this._adjustTable); - this.refs.body.refs.container.addEventListener('scroll', this._scrollHeader); - if (this.props.scrollTop) { - this._scrollTop(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - window.removeEventListener('resize', this._adjustTable); - if (this.refs && this.refs.body && this.refs.body.refs) { - this.refs.body.refs.container.removeEventListener('scroll', this._scrollHeader); - } - if (this.filter) { - this.filter.removeAllListeners('onFilterChange'); - } - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate() { - this._adjustTable(); - if (this.props.options.afterTableComplete) { - this.props.options.afterTableComplete(); - } - } + var top = _value$split2[0]; + var left = _value$split2[1]; - /** - * Returns true if in the current configuration, - * the datagrid should load its data remotely. - * - * @param {Object} [props] Optional. If not given, this.props will be used - * @return {Boolean} - */ + return { top: top, left: left }; +}; +var parseAttachment = parseOffset; - }, { - key: 'isRemoteDataSource', - value: function isRemoteDataSource(props) { - var _ref2 = props || this.props, - remote = _ref2.remote; +var TetherClass = (function (_Evented) { + _inherits(TetherClass, _Evented); - return remote === true || _util2.default.isFunction(remote); - } + function TetherClass(options) { + var _this = this; - /** - * Returns true if this action can be handled remote store - * From #990, Sometimes, we need some actions as remote, some actions are handled by default - * so function will tell you the target action is can be handled as remote or not. - * @param {String} [action] Required. - * @param {Object} [props] Optional. If not given, this.props will be used - * @return {Boolean} - */ + _classCallCheck(this, TetherClass); - }, { - key: 'allowRemote', - value: function allowRemote(action, props) { - var _ref3 = props || this.props, - remote = _ref3.remote; - - if (typeof remote === 'function') { - var remoteObj = remote(_Const2.default.REMOTE); - return remoteObj[action]; - } else { - return remote; - } - } - }, { - key: 'render', - value: function render() { - var style = { - height: this.props.height, - maxHeight: this.props.maxHeight - }; + _get(Object.getPrototypeOf(TetherClass.prototype), 'constructor', this).call(this); + this.position = this.position.bind(this); - var columns = this.getColumnsDescription(this.props); - var sortList = this.store.getSortInfo(); - var pagination = this.renderPagination(); - var toolBar = this.renderToolBar(); - var tableFilter = this.renderTableFilter(columns); - var isSelectAll = this.isSelectAll(); - var expandColumnOptions = this.props.expandColumnOptions; - if (typeof expandColumnOptions.expandColumnBeforeSelectColumn === 'undefined') { - expandColumnOptions.expandColumnBeforeSelectColumn = true; - } - var colGroups = _util2.default.renderColGroup(columns, this.props.selectRow, expandColumnOptions, this.props.version); - var sortIndicator = this.props.options.sortIndicator; - if (typeof this.props.options.sortIndicator === 'undefined') sortIndicator = true; - var _props$options$pagina = this.props.options.paginationPosition, - paginationPosition = _props$options$pagina === undefined ? _Const2.default.PAGINATION_POS_BOTTOM : _props$options$pagina; - - var showPaginationOnTop = paginationPosition !== _Const2.default.PAGINATION_POS_BOTTOM; - var showPaginationOnBottom = paginationPosition !== _Const2.default.PAGINATION_POS_TOP; - var selectRow = _extends({}, this.props.selectRow); - if (this.props.cellEdit && this.props.cellEdit.mode !== _Const2.default.CELL_EDIT_NONE) { - selectRow.clickToSelect = false; - } + tethers.push(this); - return _react2.default.createElement( - 'div', - { className: (0, _classnames2.default)('react-bs-table-container', this.props.className, this.props.containerClass), - style: this.props.containerStyle }, - toolBar, - showPaginationOnTop ? pagination : null, - _react2.default.createElement( - 'div', - { ref: 'table', - className: (0, _classnames2.default)('react-bs-table', { 'react-bs-table-bordered': this.props.bordered }, this.props.tableContainerClass), - style: _extends({}, style, this.props.tableStyle), - onMouseEnter: this.handleMouseEnter, - onMouseLeave: this.handleMouseLeave }, - _react2.default.createElement( - _TableHeader2.default, - { - ref: 'header', - version: this.props.version, - colGroups: colGroups, - headerContainerClass: this.props.headerContainerClass, - tableHeaderClass: this.props.tableHeaderClass, - style: this.props.headerStyle, - rowSelectType: this.props.selectRow.mode, - customComponent: this.props.selectRow.customComponent, - hideSelectColumn: this.props.selectRow.hideSelectColumn, - sortList: sortList, - sortIndicator: sortIndicator, - onSort: this.handleSort, - onSelectAllRow: this.handleSelectAllRow, - bordered: this.props.bordered, - condensed: this.props.condensed, - isFiltered: this.filter ? true : false, - isSelectAll: isSelectAll, - reset: this.state.reset, - expandColumnVisible: expandColumnOptions.expandColumnVisible, - expandColumnComponent: expandColumnOptions.expandColumnComponent, - expandColumnBeforeSelectColumn: expandColumnOptions.expandColumnBeforeSelectColumn }, - this.props.children - ), - _react2.default.createElement(_TableBody2.default, { ref: 'body', - bodyContainerClass: this.props.bodyContainerClass, - tableBodyClass: this.props.tableBodyClass, - style: _extends({}, style, this.props.bodyStyle), - data: this.state.data, - version: this.props.version, - expandComponent: this.props.expandComponent, - expandableRow: this.props.expandableRow, - expandRowBgColor: this.props.options.expandRowBgColor, - expandBy: this.props.options.expandBy || _Const2.default.EXPAND_BY_ROW, - expandBodyClass: this.props.options.expandBodyClass, - expandParentClass: this.props.options.expandParentClass, - columns: columns, - trClassName: this.props.trClassName, - trStyle: this.props.trStyle, - striped: this.props.striped, - bordered: this.props.bordered, - hover: this.props.hover, - keyField: this.store.getKeyField(), - condensed: this.props.condensed, - selectRow: selectRow, - expandColumnOptions: this.props.expandColumnOptions, - cellEdit: this.props.cellEdit, - selectedRowKeys: this.state.selectedRowKeys, - onRowClick: this.handleRowClick, - onRowDoubleClick: this.handleRowDoubleClick, - onRowMouseOver: this.handleRowMouseOver, - onRowMouseOut: this.handleRowMouseOut, - onSelectRow: this.handleSelectRow, - noDataText: this.props.options.noDataText, - withoutNoDataText: this.props.options.withoutNoDataText, - expanding: this.state.expanding, - onExpand: this.handleExpandRow, - onlyOneExpanding: this.props.options.onlyOneExpanding, - beforeShowError: this.props.options.beforeShowError, - keyBoardNav: this.props.keyBoardNav, - onNavigateCell: this.handleNavigateCell, - x: this.state.x, - y: this.state.y, - withoutTabIndex: this.props.withoutTabIndex, - onEditCell: this.handleEditCell }) - ), - tableFilter, - showPaginationOnBottom ? pagination : null, - _react2.default.createElement(_reactSAlert2.default, { stack: { limit: 3 } }) - ); - } - }, { - key: 'isSelectAll', - value: function isSelectAll() { - if (this.store.isEmpty()) return false; - var _props$selectRow = this.props.selectRow, - unselectable = _props$selectRow.unselectable, - onlyUnselectVisible = _props$selectRow.onlyUnselectVisible; - - var keyField = this.store.getKeyField(); - var allRowKeys = onlyUnselectVisible ? this.store.get().map(function (r) { - return r[keyField]; - }) : this.store.getAllRowkey(); - var defaultSelectRowKeys = this.store.getSelectedRowKeys(); - - if (onlyUnselectVisible) { - defaultSelectRowKeys = defaultSelectRowKeys.filter(function (x) { - return x !== allRowKeys; - }); - } + this.history = []; - if (defaultSelectRowKeys.length === 0) return false; - var match = 0; - var noFound = 0; - var unSelectableCnt = 0; - defaultSelectRowKeys.forEach(function (selected) { - if (allRowKeys.indexOf(selected) !== -1) match++;else noFound++; - if (unselectable && unselectable.indexOf(selected) !== -1) unSelectableCnt++; - }); + this.setOptions(options, false); - if (noFound === defaultSelectRowKeys.length) return false; - if (match === allRowKeys.length) { - return true; - } else { - if (unselectable && match <= unSelectableCnt && unSelectableCnt === unselectable.length) return false;else return 'indeterminate'; - } - // return (match === allRowKeys.length) ? true : 'indeterminate'; - } - }, { - key: 'cleanSelected', - value: function cleanSelected() { - this.store.setSelectedRowKey([]); - this.setState(function () { - return { - selectedRowKeys: [], - reset: false - }; - }); - } - }, { - key: 'cleanSort', - value: function cleanSort() { - this.store.cleanSortInfo(); - this.setState(function () { - return { - reset: false - }; - }); - } - }, { - key: '__handleSort__REACT_HOT_LOADER__', - value: function __handleSort__REACT_HOT_LOADER__(order, sortField) { - if (this.props.options.onSortChange) { - this.props.options.onSortChange(sortField, order, this.props); - } - this.store.setSortInfo(order, sortField); - if (this.allowRemote(_Const2.default.REMOTE_SORT)) { - return; + _utils2['default'].modules.forEach(function (module) { + if (typeof module.initialize !== 'undefined') { + module.initialize.call(_this); } + }); - var result = this.store.sort().get(); - this.setState(function () { - return { - data: result, - reset: false - }; - }); - } - }, { - key: '__handleExpandRow__REACT_HOT_LOADER__', - value: function __handleExpandRow__REACT_HOT_LOADER__(expanding, rowKey, isRowExpanding) { - var _this5 = this; + this.position(); + } - var onExpand = this.props.options.onExpand; + _createClass(TetherClass, [{ + key: 'getClass', + value: function getClass() { + var key = arguments.length <= 0 || arguments[0] === undefined ? '' : arguments[0]; + var classes = this.options.classes; - if (onExpand) { - onExpand(rowKey, !isRowExpanding); + if (typeof classes !== 'undefined' && classes[key]) { + return this.options.classes[key]; + } else if (this.options.classPrefix) { + return this.options.classPrefix + '-' + key; + } else { + return key; } - this.setState(function () { - return { expanding: expanding, reset: false }; - }, function () { - _this5._adjustHeaderWidth(); - }); } }, { - key: '__handlePaginationData__REACT_HOT_LOADER__', - value: function __handlePaginationData__REACT_HOT_LOADER__(page, sizePerPage) { - var _props$options = this.props.options, - onPageChange = _props$options.onPageChange, - pageStartIndex = _props$options.pageStartIndex; + key: 'setOptions', + value: function setOptions(options) { + var _this2 = this; - var emptyTable = this.store.isEmpty(); - if (onPageChange) { - onPageChange(page, sizePerPage); - } + var pos = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1]; - var state = { - sizePerPage: sizePerPage, - reset: false + var defaults = { + offset: '0 0', + targetOffset: '0 0', + targetAttachment: 'auto auto', + classPrefix: 'tether' }; - if (!emptyTable) state.currPage = page; - this.setState(function () { - return state; - }); - if (this.allowRemote(_Const2.default.REMOTE_PAGE) || emptyTable) { - return; - } + this.options = extend(defaults, options); - var result = this.store.page(_util2.default.getNormalizedPage(pageStartIndex, page), sizePerPage).get(); - this.setState(function () { - return { data: result, reset: false }; - }); - } - }, { - key: '__handleMouseLeave__REACT_HOT_LOADER__', - value: function __handleMouseLeave__REACT_HOT_LOADER__() { - if (this.props.options.onMouseLeave) { - this.props.options.onMouseLeave(); - } - } - }, { - key: '__handleMouseEnter__REACT_HOT_LOADER__', - value: function __handleMouseEnter__REACT_HOT_LOADER__() { - if (this.props.options.onMouseEnter) { - this.props.options.onMouseEnter(); - } - } - }, { - key: '__handleRowMouseOut__REACT_HOT_LOADER__', - value: function __handleRowMouseOut__REACT_HOT_LOADER__(row, event) { - if (this.props.options.onRowMouseOut) { - this.props.options.onRowMouseOut(row, event); - } - } - }, { - key: '__handleRowMouseOver__REACT_HOT_LOADER__', - value: function __handleRowMouseOver__REACT_HOT_LOADER__(row, event) { - if (this.props.options.onRowMouseOver) { - this.props.options.onRowMouseOver(row, event); + var _options = this.options; + var element = _options.element; + var target = _options.target; + var targetModifier = _options.targetModifier; + + this.element = element; + this.target = target; + this.targetModifier = targetModifier; + + if (this.target === 'viewport') { + this.target = document.body; + this.targetModifier = 'visible'; + } else if (this.target === 'scroll-handle') { + this.target = document.body; + this.targetModifier = 'scroll-handle'; } - } - }, { - key: '__handleNavigateCell__REACT_HOT_LOADER__', - value: function __handleNavigateCell__REACT_HOT_LOADER__(_ref4) { - var offSetX = _ref4.x, - offSetY = _ref4.y, - lastEditCell = _ref4.lastEditCell; - var pagination = this.props.pagination; - var _state = this.state, - x = _state.x, - y = _state.y, - currPage = _state.currPage; - - x += offSetX; - y += offSetY; - - var columns = this.store.getColInfos(); - var visibleRowSize = this.state.data.length; - var visibleColumnSize = Object.keys(columns).filter(function (k) { - return !columns[k].hidden; - }).length; - - if (y >= visibleRowSize) { - currPage++; - var lastPage = pagination ? this.refs.pagination.getLastPage() : -1; - if (currPage <= lastPage) { - this.handlePaginationData(currPage, this.state.sizePerPage); - } else { - return; - } - y = 0; - } else if (y < 0) { - currPage--; - if (currPage > 0) { - this.handlePaginationData(currPage, this.state.sizePerPage); - } else { - return; - } - y = visibleRowSize - 1; - } else if (x >= visibleColumnSize) { - if (y + 1 === visibleRowSize) { - currPage++; - var _lastPage = pagination ? this.refs.pagination.getLastPage() : -1; - if (currPage <= _lastPage) { - this.handlePaginationData(currPage, this.state.sizePerPage); - } else { - return; - } - y = 0; - } else { - y++; + + ['element', 'target'].forEach(function (key) { + if (typeof _this2[key] === 'undefined') { + throw new Error('Tether Error: Both element and target must be defined'); } - x = lastEditCell ? 1 : 0; - } else if (x < 0) { - x = visibleColumnSize - 1; - if (y === 0) { - currPage--; - if (currPage > 0) { - this.handlePaginationData(currPage, this.state.sizePerPage); - } else { - return; - } - y = this.state.sizePerPage - 1; - } else { - y--; + + if (typeof _this2[key].jquery !== 'undefined') { + _this2[key] = _this2[key][0]; + } else if (typeof _this2[key] === 'string') { + _this2[key] = document.querySelector(_this2[key]); } - } - this.setState(function () { - return { - x: x, y: y, currPage: currPage, reset: false - }; }); - } - }, { - key: '__handleRowClick__REACT_HOT_LOADER__', - value: function __handleRowClick__REACT_HOT_LOADER__(row, rowIndex, columnIndex) { - var _props2 = this.props, - options = _props2.options, - keyBoardNav = _props2.keyBoardNav; - - if (options.onRowClick) { - options.onRowClick(row, columnIndex, rowIndex); - } - if (keyBoardNav) { - var _ref5 = (typeof keyBoardNav === 'undefined' ? 'undefined' : _typeof(keyBoardNav)) === 'object' ? keyBoardNav : {}, - clickToNav = _ref5.clickToNav; - - clickToNav = clickToNav === false ? clickToNav : true; - if (clickToNav) { - this.setState(function () { - return { - x: columnIndex, - y: rowIndex, - reset: false - }; - }); - } - } - } - }, { - key: '__handleRowDoubleClick__REACT_HOT_LOADER__', - value: function __handleRowDoubleClick__REACT_HOT_LOADER__(row) { - if (this.props.options.onRowDoubleClick) { - this.props.options.onRowDoubleClick(row); - } - } - }, { - key: '__handleSelectAllRow__REACT_HOT_LOADER__', - value: function __handleSelectAllRow__REACT_HOT_LOADER__(e) { - var isSelected = e.currentTarget.checked; - var keyField = this.store.getKeyField(); - var _props$selectRow2 = this.props.selectRow, - onSelectAll = _props$selectRow2.onSelectAll, - unselectable = _props$selectRow2.unselectable, - selected = _props$selectRow2.selected, - onlyUnselectVisible = _props$selectRow2.onlyUnselectVisible; - - var selectedRowKeys = onlyUnselectVisible ? this.state.selectedRowKeys : []; - var result = true; - var rows = this.store.get(); - - // onlyUnselectVisible default is false, #1276 - if (!isSelected && !onlyUnselectVisible) { - rows = this.store.getRowByKey(this.state.selectedRowKeys); - } - - if (unselectable && unselectable.length > 0) { - if (isSelected) { - rows = rows.filter(function (r) { - return unselectable.indexOf(r[keyField]) === -1 || selected && selected.indexOf(r[keyField]) !== -1; - }); - } else { - rows = rows.filter(function (r) { - return unselectable.indexOf(r[keyField]) === -1; - }); - } + + addClass(this.element, this.getClass('element')); + if (!(this.options.addTargetClasses === false)) { + addClass(this.target, this.getClass('target')); } - if (onSelectAll) { - result = this.props.selectRow.onSelectAll(isSelected, rows); + if (!this.options.attachment) { + throw new Error('Tether Error: You must provide an attachment'); } - if (typeof result == 'undefined' || result !== false) { - if (isSelected) { - if (Array.isArray(result)) { - selectedRowKeys = result; - } else { - var currentRowKeys = rows.map(function (r) { - return r[keyField]; - }); - // onlyUnselectVisible default is false, #1276 - if (onlyUnselectVisible) { - selectedRowKeys = selectedRowKeys.concat(currentRowKeys); - } else { - selectedRowKeys = currentRowKeys; - } - } - } else { - if (unselectable && selected) { - selectedRowKeys = selected.filter(function (r) { - return unselectable.indexOf(r) > -1; - }); - } else if (onlyUnselectVisible) { - var _currentRowKeys = rows.map(function (r) { - return r[keyField]; - }); - selectedRowKeys = selectedRowKeys.filter(function (k) { - return _currentRowKeys.indexOf(k) === -1; - }); - } - } + this.targetAttachment = parseAttachment(this.options.targetAttachment); + this.attachment = parseAttachment(this.options.attachment); + this.offset = parseOffset(this.options.offset); + this.targetOffset = parseOffset(this.options.targetOffset); - this.store.setSelectedRowKey(selectedRowKeys); - this.setState(function () { - return { selectedRowKeys: selectedRowKeys, reset: false }; - }); - } - } - }, { - key: '__handleShowOnlySelected__REACT_HOT_LOADER__', - value: function __handleShowOnlySelected__REACT_HOT_LOADER__() { - this.store.ignoreNonSelected(); - var pageStartIndex = this.props.options.pageStartIndex; - - var result = void 0; - if (this.props.pagination) { - result = this.store.page(_util2.default.getNormalizedPage(pageStartIndex), this.state.sizePerPage).get(); - } else { - result = this.store.get(); + if (typeof this.scrollParents !== 'undefined') { + this.disable(); } - this.setState(function () { - return { - data: result, - reset: false, - currPage: _util2.default.getFirstPage(pageStartIndex) - }; - }); - } - }, { - key: '__handleSelectRow__REACT_HOT_LOADER__', - value: function __handleSelectRow__REACT_HOT_LOADER__(row, isSelected, e, rowIndex) { - var result = true; - var currSelected = this.store.getSelectedRowKeys(); - var rowKey = row[this.store.getKeyField()]; - var selectRow = this.props.selectRow; - if (selectRow.onSelect) { - result = selectRow.onSelect(row, isSelected, e, rowIndex); + if (this.targetModifier === 'scroll-handle') { + this.scrollParents = [this.target]; + } else { + this.scrollParents = getScrollParents(this.target); } - if (typeof result === 'undefined' || result !== false) { - if (selectRow.mode === _Const2.default.ROW_SELECT_SINGLE) { - currSelected = isSelected ? [rowKey] : []; - } else { - if (isSelected) { - currSelected.push(rowKey); - } else { - currSelected = currSelected.filter(function (key) { - return rowKey !== key; - }); - } - } - - this.store.setSelectedRowKey(currSelected); - this.setState(function () { - return { - selectedRowKeys: currSelected, - reset: false - }; - }); + if (!(this.options.enabled === false)) { + this.enable(pos); } } }, { - key: '__handleEditCell__REACT_HOT_LOADER__', - value: function __handleEditCell__REACT_HOT_LOADER__(newVal, rowIndex, colIndex) { - var _this6 = this; + key: 'getTargetBounds', + value: function getTargetBounds() { + if (typeof this.targetModifier !== 'undefined') { + if (this.targetModifier === 'visible') { + if (this.target === document.body) { + return { top: pageYOffset, left: pageXOffset, height: innerHeight, width: innerWidth }; + } else { + var bounds = getBounds(this.target); - var beforeSaveCell = this.props.cellEdit.beforeSaveCell; + var out = { + height: bounds.height, + width: bounds.width, + top: bounds.top, + left: bounds.left + }; - var columns = this.getColumnsDescription(this.props); - var fieldName = columns[colIndex].name; + out.height = Math.min(out.height, bounds.height - (pageYOffset - bounds.top)); + out.height = Math.min(out.height, bounds.height - (bounds.top + bounds.height - (pageYOffset + innerHeight))); + out.height = Math.min(innerHeight, out.height); + out.height -= 2; - var invalid = function invalid() { - _this6.setState(function () { - return { - data: _this6.store.get(), - reset: false - }; - }); - return; - }; + out.width = Math.min(out.width, bounds.width - (pageXOffset - bounds.left)); + out.width = Math.min(out.width, bounds.width - (bounds.left + bounds.width - (pageXOffset + innerWidth))); + out.width = Math.min(innerWidth, out.width); + out.width -= 2; - if (beforeSaveCell) { - var beforeSaveCellCB = function beforeSaveCellCB(result) { - _this6.refs.body.cancelEditCell(); - if (result || result === undefined) { - _this6.editCell(newVal, rowIndex, colIndex); - } else { - invalid(); + if (out.top < pageYOffset) { + out.top = pageYOffset; + } + if (out.left < pageXOffset) { + out.left = pageXOffset; + } + + return out; } - }; - var isValid = beforeSaveCell(this.state.data[rowIndex], fieldName, newVal, beforeSaveCellCB); - if (isValid === false && typeof isValid !== 'undefined') { - return invalid(); - } else if (isValid === _Const2.default.AWAIT_BEFORE_CELL_EDIT) { - /* eslint consistent-return: 0 */ - return isValid; - } - } - this.editCell(newVal, rowIndex, colIndex); - } - }, { - key: 'editCell', - value: function editCell(newVal, rowIndex, colIndex) { - var onCellEdit = this.props.options.onCellEdit; - var afterSaveCell = this.props.cellEdit.afterSaveCell; + } else if (this.targetModifier === 'scroll-handle') { + var bounds = undefined; + var target = this.target; + if (target === document.body) { + target = document.documentElement; - var columns = this.getColumnsDescription(this.props); - var fieldName = columns[colIndex].name; - if (onCellEdit) { - newVal = onCellEdit(this.state.data[rowIndex], fieldName, newVal); - } + bounds = { + left: pageXOffset, + top: pageYOffset, + height: innerHeight, + width: innerWidth + }; + } else { + bounds = getBounds(target); + } - if (this.allowRemote(_Const2.default.REMOTE_CELL_EDIT)) { - if (afterSaveCell) { - afterSaveCell(this.state.data[rowIndex], fieldName, newVal); - } - return; - } + var style = getComputedStyle(target); - var result = this.store.edit(newVal, rowIndex, fieldName).get(); - this.setState(function () { - return { - data: result, - reset: false - }; - }); + var hasBottomScroll = target.scrollWidth > target.clientWidth || [style.overflow, style.overflowX].indexOf('scroll') >= 0 || this.target !== document.body; - if (afterSaveCell) { - afterSaveCell(this.state.data[rowIndex], fieldName, newVal); - } - } - }, { - key: 'handleAddRowAtBegin', - value: function handleAddRowAtBegin(newObj) { - try { - this.store.addAtBegin(newObj); - } catch (e) { - return e; - } - this._handleAfterAddingRow(newObj, true); - } - }, { - key: '__handleAddRow__REACT_HOT_LOADER__', - value: function __handleAddRow__REACT_HOT_LOADER__(newObj) { - var _this7 = this; + var scrollBottom = 0; + if (hasBottomScroll) { + scrollBottom = 15; + } - var isAsync = false; - var onAddRow = this.props.options.onAddRow; + var height = bounds.height - parseFloat(style.borderTopWidth) - parseFloat(style.borderBottomWidth) - scrollBottom; + var out = { + width: 15, + height: height * 0.975 * (height / target.scrollHeight), + left: bounds.left + bounds.width - parseFloat(style.borderLeftWidth) - 15 + }; - var afterHandleAddRow = function afterHandleAddRow(errMsg) { - if (isAsync) { - _this7.refs.toolbar.afterHandleSaveBtnClick(errMsg); - } else { - return errMsg; - } - }; + var fitAdj = 0; + if (height < 408 && this.target === document.body) { + fitAdj = -0.00011 * Math.pow(height, 2) - 0.00727 * height + 22.58; + } - var afterAddRowCB = function afterAddRowCB(errMsg) { - if (typeof errMsg !== 'undefined' && errMsg !== '') return afterHandleAddRow(errMsg); - if (_this7.allowRemote(_Const2.default.REMOTE_INSERT_ROW)) { - if (_this7.props.options.afterInsertRow) { - _this7.props.options.afterInsertRow(newObj); + if (this.target !== document.body) { + out.height = Math.max(out.height, 24); } - return afterHandleAddRow(); - } - try { - _this7.store.add(newObj); - } catch (e) { - return afterHandleAddRow(e.message); - } - _this7._handleAfterAddingRow(newObj, false); - return afterHandleAddRow(); - }; + var scrollPercentage = this.target.scrollTop / (target.scrollHeight - height); + out.top = scrollPercentage * (height - out.height - fitAdj) + bounds.top + parseFloat(style.borderTopWidth); - if (onAddRow) { - var colInfos = this.store.getColInfos(); - var errMsg = onAddRow(newObj, colInfos, afterAddRowCB); + if (this.target === document.body) { + out.height = Math.max(out.height, 24); + } - if (errMsg !== '' && errMsg !== false) { - return errMsg; - } else if (typeof errMsg === 'undefined') { - return afterAddRowCB(); - } else { - isAsync = true; - return !isAsync; + return out; } } else { - return afterAddRowCB(); + return getBounds(this.target); } } }, { - key: 'getSizePerPage', - value: function getSizePerPage() { - return this.state.sizePerPage; - } - }, { - key: 'getCurrentPage', - value: function getCurrentPage() { - return this.state.currPage; - } - }, { - key: 'getTableDataIgnorePaging', - value: function getTableDataIgnorePaging() { - return this.store.getCurrentDisplayData(); + key: 'clearCache', + value: function clearCache() { + this._cache = {}; } }, { - key: '__getPageByRowKey__REACT_HOT_LOADER__', - value: function __getPageByRowKey__REACT_HOT_LOADER__(rowKey) { - var sizePerPage = this.state.sizePerPage; - - var currentData = this.store.getCurrentDisplayData(); - var keyField = this.store.getKeyField(); - var result = currentData.findIndex(function (x) { - return x[keyField] === rowKey; - }); - if (result > -1) { - return parseInt(result / sizePerPage, 10) + 1; - } else { - return result; + key: 'cache', + value: function cache(k, getter) { + // More than one module will often need the same DOM info, so + // we keep a cache which is cleared on each position call + if (typeof this._cache === 'undefined') { + this._cache = {}; } - } - }, { - key: '__handleDropRow__REACT_HOT_LOADER__', - value: function __handleDropRow__REACT_HOT_LOADER__(rowKeys) { - var _this8 = this; - var dropRowKeys = rowKeys ? rowKeys : this.store.getSelectedRowKeys(); - // add confirm before the delete action if that option is set. - if (dropRowKeys && dropRowKeys.length > 0) { - if (this.props.options.handleConfirmDeleteRow) { - this.props.options.handleConfirmDeleteRow(function () { - _this8.deleteRow(dropRowKeys); - }, dropRowKeys); - } else if (confirm('Are you sure you want to delete?')) { - this.deleteRow(dropRowKeys); - } + if (typeof this._cache[k] === 'undefined') { + this._cache[k] = getter.call(this); } + + return this._cache[k]; } }, { - key: 'deleteRow', - value: function deleteRow(dropRowKeys) { - var _this9 = this; - - var dropRow = this.store.getRowByKey(dropRowKeys); - var _props$options2 = this.props.options, - onDeleteRow = _props$options2.onDeleteRow, - afterDeleteRow = _props$options2.afterDeleteRow; + key: 'enable', + value: function enable() { + var _this3 = this; + var pos = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; - if (onDeleteRow) { - onDeleteRow(dropRowKeys, dropRow); + if (!(this.options.addTargetClasses === false)) { + addClass(this.target, this.getClass('enabled')); } + addClass(this.element, this.getClass('enabled')); + this.enabled = true; - this.store.setSelectedRowKey([]); // clear selected row key + this.scrollParents.forEach(function (parent) { + if (parent !== _this3.target.ownerDocument) { + parent.addEventListener('scroll', _this3.position); + } + }); - if (this.allowRemote(_Const2.default.REMOTE_DROP_ROW) && afterDeleteRow) { - afterDeleteRow(dropRowKeys, dropRow); - return; + if (pos) { + this.position(); } + } + }, { + key: 'disable', + value: function disable() { + var _this4 = this; - this.store.remove(dropRowKeys); // remove selected Row - var result = void 0; - if (this.props.pagination) { - var sizePerPage = this.state.sizePerPage; - - var currLastPage = Math.ceil(this.store.getDataNum() / sizePerPage); - var currPage = this.state.currPage; + removeClass(this.target, this.getClass('enabled')); + removeClass(this.element, this.getClass('enabled')); + this.enabled = false; - if (currPage > currLastPage) currPage = currLastPage; - result = this.store.page(_util2.default.getNormalizedPage(currPage), sizePerPage).get(); - this.setState(function () { - return { - data: result, - selectedRowKeys: _this9.store.getSelectedRowKeys(), - currPage: currPage, - reset: false - }; - }); - } else { - result = this.store.get(); - this.setState(function () { - return { - data: result, - reset: false, - selectedRowKeys: _this9.store.getSelectedRowKeys() - }; + if (typeof this.scrollParents !== 'undefined') { + this.scrollParents.forEach(function (parent) { + parent.removeEventListener('scroll', _this4.position); }); } - if (afterDeleteRow) { - afterDeleteRow(dropRowKeys, dropRow); - } } }, { - key: '__handleFilterData__REACT_HOT_LOADER__', - value: function __handleFilterData__REACT_HOT_LOADER__(filterObj) { - var _props$options3 = this.props.options, - onFilterChange = _props$options3.onFilterChange, - pageStartIndex = _props$options3.pageStartIndex; - - if (onFilterChange) { - var colInfos = this.store.getColInfos(); - onFilterChange(filterObj, colInfos); - } + key: 'destroy', + value: function destroy() { + var _this5 = this; - this.setState(function () { - return { - currPage: _util2.default.getFirstPage(pageStartIndex), - reset: false - }; - }); + this.disable(); - if (this.allowRemote(_Const2.default.REMOTE_FILTER)) { - if (this.props.options.afterColumnFilter) { - this.props.options.afterColumnFilter(filterObj, this.store.getDataIgnoringPagination()); + tethers.forEach(function (tether, i) { + if (tether === _this5) { + tethers.splice(i, 1); } - return; - } - - this.store.filter(filterObj); - - var sortList = this.store.getSortInfo(); - - if (sortList.length > 0) { - this.store.sort(); - } - - var result = void 0; - - if (this.props.pagination) { - var sizePerPage = this.state.sizePerPage; + }); - result = this.store.page(_util2.default.getNormalizedPage(pageStartIndex), sizePerPage).get(); - } else { - result = this.store.get(); - } - if (this.props.options.afterColumnFilter) { - this.props.options.afterColumnFilter(filterObj, this.store.getDataIgnoringPagination()); + // Remove any elements we were using for convenience from the DOM + if (tethers.length === 0) { + removeUtilElements(); } - this.setState(function () { - return { - data: result, - reset: false - }; - }); } }, { - key: '__handleExportCSV__REACT_HOT_LOADER__', - value: function __handleExportCSV__REACT_HOT_LOADER__() { - var result = {}; - - var csvFileName = this.props.csvFileName; - var _props$options4 = this.props.options, - onExportToCSV = _props$options4.onExportToCSV, - exportCSVSeparator = _props$options4.exportCSVSeparator, - noAutoBOM = _props$options4.noAutoBOM, - excludeCSVHeader = _props$options4.excludeCSVHeader; - - if (onExportToCSV) { - result = onExportToCSV(); - } else { - result = this.store.getDataIgnoringPagination(); - } - var separator = exportCSVSeparator || _Const2.default.DEFAULT_CSV_SEPARATOR; - var keys = []; - this.props.children.filter(function (_) { - return _ != null; - }).map(function (column) { - if (column.props.export === true || typeof column.props.export === 'undefined' && column.props.hidden === false) { - keys.push({ - field: column.props.dataField, - format: column.props.csvFormat, - extraData: column.props.csvFormatExtraData, - header: column.props.csvHeader || column.props.dataField, - row: Number(column.props.row) || 0, - rowSpan: Number(column.props.rowSpan) || 1, - colSpan: Number(column.props.colSpan) || 1 - }); - } - }); + key: 'updateAttachClasses', + value: function updateAttachClasses(elementAttach, targetAttach) { + var _this6 = this; - if (_util2.default.isFunction(csvFileName)) { - csvFileName = csvFileName(); - } + elementAttach = elementAttach || this.attachment; + targetAttach = targetAttach || this.targetAttachment; + var sides = ['left', 'top', 'bottom', 'right', 'middle', 'center']; - (0, _csv_export_util2.default)(result, keys, csvFileName, separator, noAutoBOM, excludeCSVHeader); - } - }, { - key: '__handleSearch__REACT_HOT_LOADER__', - value: function __handleSearch__REACT_HOT_LOADER__(searchText) { - // Set search field if this function being called outside - // but it's not necessary if calling fron inside. - if (this.refs.toolbar) { - this.refs.toolbar.setSearchInput(searchText); + if (typeof this._addAttachClasses !== 'undefined' && this._addAttachClasses.length) { + // updateAttachClasses can be called more than once in a position call, so + // we need to clean up after ourselves such that when the last defer gets + // ran it doesn't add any extra classes from previous calls. + this._addAttachClasses.splice(0, this._addAttachClasses.length); } - var _props$options5 = this.props.options, - onSearchChange = _props$options5.onSearchChange, - pageStartIndex = _props$options5.pageStartIndex; - if (onSearchChange) { - var colInfos = this.store.getColInfos(); - onSearchChange(searchText, colInfos, this.props.multiColumnSearch); + if (typeof this._addAttachClasses === 'undefined') { + this._addAttachClasses = []; } + var add = this._addAttachClasses; - this.setState(function () { - return { - currPage: _util2.default.getFirstPage(pageStartIndex), - reset: false - }; - }); - - if (this.allowRemote(_Const2.default.REMOTE_SEARCH)) { - if (this.props.options.afterSearch) { - this.props.options.afterSearch(searchText, this.store.getDataIgnoringPagination()); - } - return; + if (elementAttach.top) { + add.push(this.getClass('element-attached') + '-' + elementAttach.top); } - - this.store.search(searchText); - - var sortList = this.store.getSortInfo(); - - if (sortList.length > 0) { - this.store.sort(); + if (elementAttach.left) { + add.push(this.getClass('element-attached') + '-' + elementAttach.left); } - - var result = void 0; - if (this.props.pagination) { - var sizePerPage = this.state.sizePerPage; - - result = this.store.page(_util2.default.getNormalizedPage(pageStartIndex), sizePerPage).get(); - } else { - result = this.store.get(); + if (targetAttach.top) { + add.push(this.getClass('target-attached') + '-' + targetAttach.top); } - if (this.props.options.afterSearch) { - this.props.options.afterSearch(searchText, this.store.getDataIgnoringPagination()); + if (targetAttach.left) { + add.push(this.getClass('target-attached') + '-' + targetAttach.left); } - this.setState(function () { - return { - data: result, - reset: false - }; + + var all = []; + sides.forEach(function (side) { + all.push(_this6.getClass('element-attached') + '-' + side); + all.push(_this6.getClass('target-attached') + '-' + side); }); - } - }, { - key: 'renderPagination', - value: function renderPagination() { - if (this.props.pagination) { - var dataSize = void 0; - if (this.allowRemote(_Const2.default.REMOTE_PAGE)) { - dataSize = this.props.fetchInfo.dataTotalSize; - } else { - dataSize = this.store.getDataNum(); - } - var options = this.props.options; - var withFirstAndLast = options.withFirstAndLast === undefined ? true : options.withFirstAndLast; - if (Math.ceil(dataSize / this.state.sizePerPage) <= 1 && this.props.ignoreSinglePage) return null; - return _react2.default.createElement( - 'div', - { className: 'react-bs-table-pagination' }, - _react2.default.createElement(_PaginationList2.default, { - ref: 'pagination', - withFirstAndLast: withFirstAndLast, - alwaysShowAllBtns: options.alwaysShowAllBtns, - currPage: this.state.currPage, - changePage: this.handlePaginationData, - sizePerPage: this.state.sizePerPage, - sizePerPageList: options.sizePerPageList || _Const2.default.SIZE_PER_PAGE_LIST, - pageStartIndex: options.pageStartIndex, - paginationShowsTotal: options.paginationShowsTotal, - paginationSize: options.paginationSize || _Const2.default.PAGINATION_SIZE, - dataSize: dataSize, - onSizePerPageList: options.onSizePerPageList, - prePage: options.prePage || _Const2.default.PRE_PAGE, - nextPage: options.nextPage || _Const2.default.NEXT_PAGE, - firstPage: options.firstPage || _Const2.default.FIRST_PAGE, - lastPage: options.lastPage || _Const2.default.LAST_PAGE, - prePageTitle: options.prePageTitle || _Const2.default.PRE_PAGE_TITLE, - nextPageTitle: options.nextPageTitle || _Const2.default.NEXT_PAGE_TITLE, - firstPageTitle: options.firstPageTitle || _Const2.default.FIRST_PAGE_TITLE, - lastPageTitle: options.lastPageTitle || _Const2.default.LAST_PAGE_TITLE, - hideSizePerPage: options.hideSizePerPage, - sizePerPageDropDown: options.sizePerPageDropDown, - hidePageListOnlyOnePage: options.hidePageListOnlyOnePage, - paginationPanel: options.paginationPanel, - keepSizePerPageState: options.keepSizePerPageState, - open: false }) - ); - } - return null; - } - }, { - key: 'renderToolBar', - value: function renderToolBar() { - var _props3 = this.props, - exportCSV = _props3.exportCSV, - selectRow = _props3.selectRow, - insertRow = _props3.insertRow, - deleteRow = _props3.deleteRow, - search = _props3.search, - children = _props3.children, - keyField = _props3.keyField; - - var enableShowOnlySelected = selectRow && selectRow.showOnlySelected; - var print = typeof this.props.options.printToolBar === 'undefined' ? true : this.props.options.printToolBar; - if (enableShowOnlySelected || insertRow || deleteRow || search || exportCSV || this.props.options.searchPanel || this.props.options.btnGroup || this.props.options.toolBar) { - var columns = void 0; - if (Array.isArray(children)) { - columns = children.filter(function (_) { - return _ != null; - }).map(function (column, r) { - if (!column) return; - var props = column.props; - - var isKey = props.isKey || keyField === props.dataField; - return { - isKey: isKey, - name: props.headerText || props.children, - field: props.dataField, - hiddenOnInsert: props.hiddenOnInsert, - keyValidator: props.keyValidator, - customInsertEditor: props.customInsertEditor, - // when you want same auto generate value and not allow edit, example ID field - autoValue: props.autoValue || false, - // for create editor, no params for column.editable() indicate that editor for new row - editable: props.editable && _util2.default.isFunction(props.editable === 'function') ? props.editable() : props.editable, - format: props.dataFormat ? function (value) { - return props.dataFormat(value, null, props.formatExtraData, r).replace(/<.*?>/g, ''); - } : false - }; - }); - } else { - columns = [{ - name: children.props.headerText || children.props.children, - field: children.props.dataField, - editable: children.props.editable, - customInsertEditor: children.props.customInsertEditor, - hiddenOnInsert: children.props.hiddenOnInsert, - keyValidator: children.props.keyValidator - }]; + defer(function () { + if (!(typeof _this6._addAttachClasses !== 'undefined')) { + return; } - return _react2.default.createElement( - 'div', - { className: 'react-bs-table-tool-bar ' + (print ? '' : 'hidden-print') }, - _react2.default.createElement(_ToolBar2.default, { - ref: 'toolbar', - version: this.props.version, - defaultSearch: this.props.options.defaultSearch, - clearSearch: this.props.options.clearSearch, - searchPosition: this.props.options.searchPosition, - searchDelayTime: this.props.options.searchDelayTime, - enableInsert: insertRow, - enableDelete: deleteRow, - enableSearch: search, - enableExportCSV: exportCSV, - enableShowOnlySelected: enableShowOnlySelected, - columns: columns, - searchPlaceholder: this.props.searchPlaceholder, - exportCSVText: this.props.options.exportCSVText, - insertText: this.props.options.insertText, - deleteText: this.props.options.deleteText, - saveText: this.props.options.saveText, - closeText: this.props.options.closeText, - ignoreEditable: this.props.options.ignoreEditable, - onAddRow: this.handleAddRow, - onDropRow: this.handleDropRow, - onSearch: this.handleSearch, - onExportCSV: this.handleExportCSV, - onShowOnlySelected: this.handleShowOnlySelected, - insertModalHeader: this.props.options.insertModalHeader, - insertModalFooter: this.props.options.insertModalFooter, - insertModalBody: this.props.options.insertModalBody, - insertModal: this.props.options.insertModal, - insertBtn: this.props.options.insertBtn, - deleteBtn: this.props.options.deleteBtn, - showSelectedOnlyBtn: this.props.options.showSelectedOnlyBtn, - exportCSVBtn: this.props.options.exportCSVBtn, - clearSearchBtn: this.props.options.clearSearchBtn, - searchField: this.props.options.searchField, - searchPanel: this.props.options.searchPanel, - btnGroup: this.props.options.btnGroup, - toolBar: this.props.options.toolBar, - reset: this.state.reset, - isValidKey: this.store.isValidKey, - insertFailIndicator: this.props.options.insertFailIndicator || _Const2.default.INSERT_FAIL_INDICATOR }) - ); - } else { - return null; - } - } - }, { - key: 'renderTableFilter', - value: function renderTableFilter(columns) { - if (this.props.columnFilter) { - return _react2.default.createElement(_TableFilter2.default, { columns: columns, - rowSelectType: this.props.selectRow.mode, - onFilter: this.handleFilterData }); - } else { - return null; - } - } - }, { - key: '___scrollTop__REACT_HOT_LOADER__', - value: function ___scrollTop__REACT_HOT_LOADER__() { - var scrollTop = this.props.scrollTop; - if (scrollTop === _Const2.default.SCROLL_TOP) { - this.refs.body.refs.container.scrollTop = 0; - } else if (scrollTop === _Const2.default.SCROLL_BOTTOM) { - this.refs.body.refs.container.scrollTop = this.refs.body.refs.container.scrollHeight; - } else if (typeof scrollTop === 'number' && !isNaN(scrollTop)) { - this.refs.body.refs.container.scrollTop = scrollTop; - } - } - }, { - key: '___scrollHeader__REACT_HOT_LOADER__', - value: function ___scrollHeader__REACT_HOT_LOADER__(e) { - this.refs.header.refs.container.scrollLeft = e.currentTarget.scrollLeft; - } - }, { - key: '_adjustTable', - value: function _adjustTable() { - this._adjustHeight(); - if (!this.props.printable) { - this._adjustHeaderWidth(); - } - } - }, { - key: '_adjustHeaderWidth', - value: function _adjustHeaderWidth() { - var header = this.refs.header.getHeaderColGrouop(); - var tbody = this.refs.body.refs.tbody; - var bodyHeader = this.refs.body.getHeaderColGrouop(); - var firstRow = tbody.childNodes[0]; - var isScroll = tbody.parentNode.getBoundingClientRect().height > tbody.parentNode.parentNode.getBoundingClientRect().height; - - var scrollBarWidth = isScroll ? _util2.default.getScrollBarWidth() : 0; - if (firstRow && this.store.getDataNum()) { - if (isScroll || this.isVerticalScroll !== isScroll) { - var cells = firstRow.childNodes; - for (var i = 0; i < cells.length; i++) { - var cell = cells[i]; - var computedStyle = window.getComputedStyle(cell); - var width = parseFloat(computedStyle.width.replace('px', '')); - if (this.isIE) { - var paddingLeftWidth = parseFloat(computedStyle.paddingLeft.replace('px', '')); - var paddingRightWidth = parseFloat(computedStyle.paddingRight.replace('px', '')); - var borderRightWidth = parseFloat(computedStyle.borderRightWidth.replace('px', '')); - var borderLeftWidth = parseFloat(computedStyle.borderLeftWidth.replace('px', '')); - width = width + paddingLeftWidth + paddingRightWidth + borderRightWidth + borderLeftWidth; - } - var lastPadding = cells.length - 1 === i ? scrollBarWidth : 0; - if (width <= 0) { - width = 120; - cell.width = width + lastPadding + 'px'; - } - var result = width + lastPadding + 'px'; - header[i].style.width = result; - header[i].style.minWidth = result; - if (cells.length - 1 === i) { - bodyHeader[i].style.width = width + 'px'; - bodyHeader[i].style.minWidth = width + 'px'; - } else { - bodyHeader[i].style.width = result; - bodyHeader[i].style.minWidth = result; - } - } - } - } else { - for (var _i in bodyHeader) { - if (bodyHeader.hasOwnProperty(_i)) { - var child = bodyHeader[_i]; - if (child.style) { - if (child.style.width) { - header[_i].style.width = child.style.width; - } - if (child.style.minWidth) { - header[_i].style.minWidth = child.style.minWidth; - } - } - } + updateClasses(_this6.element, _this6._addAttachClasses, all); + if (!(_this6.options.addTargetClasses === false)) { + updateClasses(_this6.target, _this6._addAttachClasses, all); } - } - this.isVerticalScroll = isScroll; - } - }, { - key: '_adjustHeight', - value: function _adjustHeight() { - var height = this.props.height; - var maxHeight = this.props.maxHeight; - - if (typeof height === 'number' && !isNaN(height) || height.indexOf('%') === -1) { - this.refs.body.refs.container.style.height = parseFloat(height, 10) - this.refs.header.refs.container.offsetHeight + 'px'; - } - if (maxHeight) { - maxHeight = typeof maxHeight === 'number' ? maxHeight : parseInt(maxHeight.replace('px', ''), 10); - this.refs.body.refs.container.style.maxHeight = maxHeight - this.refs.header.refs.container.offsetHeight + 'px'; - } + delete _this6._addAttachClasses; + }); } }, { - key: '_handleAfterAddingRow', - value: function _handleAfterAddingRow(newObj, atTheBeginning) { - var result = void 0; - if (this.props.pagination) { - // if pagination is enabled and inserting row at the end, - // change page to the last page - // otherwise, change it to the first page - var sizePerPage = this.state.sizePerPage; - - - if (atTheBeginning) { - var pageStartIndex = this.props.options.pageStartIndex; - - result = this.store.page(_util2.default.getNormalizedPage(pageStartIndex), sizePerPage).get(); - this.setState(function () { - return { - data: result, - currPage: _util2.default.getFirstPage(pageStartIndex), - reset: false - }; - }); - } else { - var currLastPage = Math.ceil(this.store.getDataNum() / sizePerPage); - result = this.store.page(currLastPage, sizePerPage).get(); - this.setState(function () { - return { - data: result, - currPage: currLastPage, - reset: false - }; - }); - } - } else { - result = this.store.get(); - this.setState(function () { - return { - data: result, - reset: false - }; - }); - } + key: 'position', + value: function position() { + var _this7 = this; - if (this.props.options.afterInsertRow) { - this.props.options.afterInsertRow(newObj); - } - } - }]); + var flushChanges = arguments.length <= 0 || arguments[0] === undefined ? true : arguments[0]; - return BootstrapTable; -}(_react.Component); + // flushChanges commits the changes immediately, leave true unless you are positioning multiple + // tethers (in which case call Tether.Utils.flush yourself when you're done) -BootstrapTable.propTypes = { - keyField: _propTypes2.default.string, - height: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.number]), - maxHeight: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.number]), - data: _propTypes2.default.oneOfType([_propTypes2.default.array, _propTypes2.default.object]), - version: _propTypes2.default.string, // bootstrap version - remote: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.func]), // remote data, default is false - replace: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.func]), - scrollTop: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.number]), - striped: _propTypes2.default.bool, - bordered: _propTypes2.default.bool, - hover: _propTypes2.default.bool, - condensed: _propTypes2.default.bool, - pagination: _propTypes2.default.bool, - printable: _propTypes2.default.bool, - withoutTabIndex: _propTypes2.default.bool, - keyBoardNav: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.object]), - searchPlaceholder: _propTypes2.default.string, - selectRow: _propTypes2.default.shape({ - mode: _propTypes2.default.oneOf([_Const2.default.ROW_SELECT_NONE, _Const2.default.ROW_SELECT_SINGLE, _Const2.default.ROW_SELECT_MULTI]), - customComponent: _propTypes2.default.func, - bgColor: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.func]), - selected: _propTypes2.default.array, - onSelect: _propTypes2.default.func, - onSelectAll: _propTypes2.default.func, - clickToSelect: _propTypes2.default.bool, - hideSelectColumn: _propTypes2.default.bool, - clickToSelectAndEditCell: _propTypes2.default.bool, - clickToExpand: _propTypes2.default.bool, - showOnlySelected: _propTypes2.default.bool, - unselectable: _propTypes2.default.array, - columnWidth: _propTypes2.default.oneOfType([_propTypes2.default.number, _propTypes2.default.string]), - onlyUnselectVisible: _propTypes2.default.bool - }), - cellEdit: _propTypes2.default.shape({ - mode: _propTypes2.default.string, - blurToSave: _propTypes2.default.bool, - beforeSaveCell: _propTypes2.default.func, - afterSaveCell: _propTypes2.default.func, - nonEditableRows: _propTypes2.default.func - }), - insertRow: _propTypes2.default.bool, - deleteRow: _propTypes2.default.bool, - search: _propTypes2.default.bool, - multiColumnSearch: _propTypes2.default.bool, - strictSearch: _propTypes2.default.bool, - columnFilter: _propTypes2.default.bool, - trClassName: _propTypes2.default.any, - trStyle: _propTypes2.default.any, - tableStyle: _propTypes2.default.object, - containerStyle: _propTypes2.default.object, - headerStyle: _propTypes2.default.object, - bodyStyle: _propTypes2.default.object, - containerClass: _propTypes2.default.string, - tableContainerClass: _propTypes2.default.string, - headerContainerClass: _propTypes2.default.string, - bodyContainerClass: _propTypes2.default.string, - tableHeaderClass: _propTypes2.default.string, - tableBodyClass: _propTypes2.default.string, - options: _propTypes2.default.shape({ - clearSearch: _propTypes2.default.bool, - sortName: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.array]), - sortOrder: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.array]), - defaultSortName: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.array]), - defaultSortOrder: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.array]), - sortIndicator: _propTypes2.default.bool, - afterTableComplete: _propTypes2.default.func, - afterDeleteRow: _propTypes2.default.func, - afterInsertRow: _propTypes2.default.func, - afterSearch: _propTypes2.default.func, - afterColumnFilter: _propTypes2.default.func, - onRowClick: _propTypes2.default.func, - onRowDoubleClick: _propTypes2.default.func, - page: _propTypes2.default.number, - pageStartIndex: _propTypes2.default.number, - paginationShowsTotal: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.func]), - sizePerPageList: _propTypes2.default.array, - sizePerPage: _propTypes2.default.number, - paginationSize: _propTypes2.default.number, - paginationPosition: _propTypes2.default.oneOf([_Const2.default.PAGINATION_POS_TOP, _Const2.default.PAGINATION_POS_BOTTOM, _Const2.default.PAGINATION_POS_BOTH]), - hideSizePerPage: _propTypes2.default.bool, - hidePageListOnlyOnePage: _propTypes2.default.bool, - alwaysShowAllBtns: _propTypes2.default.bool, - withFirstAndLast: _propTypes2.default.bool, - keepSizePerPageState: _propTypes2.default.bool, - onSortChange: _propTypes2.default.func, - onPageChange: _propTypes2.default.func, - onSizePerPageList: _propTypes2.default.func, - onFilterChange: _propTypes2.default.func, - onSearchChange: _propTypes2.default.func, - onAddRow: _propTypes2.default.func, - onExportToCSV: _propTypes2.default.func, - onCellEdit: _propTypes2.default.func, - noDataText: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.object]), - withoutNoDataText: _propTypes2.default.bool, - handleConfirmDeleteRow: _propTypes2.default.func, - prePage: _propTypes2.default.any, - nextPage: _propTypes2.default.any, - firstPage: _propTypes2.default.any, - lastPage: _propTypes2.default.any, - prePageTitle: _propTypes2.default.string, - nextPageTitle: _propTypes2.default.string, - firstPageTitle: _propTypes2.default.string, - lastPageTitle: _propTypes2.default.string, - searchDelayTime: _propTypes2.default.number, - excludeCSVHeader: _propTypes2.default.bool, - exportCSVText: _propTypes2.default.string, - exportCSVSeparator: _propTypes2.default.string, - insertText: _propTypes2.default.string, - deleteText: _propTypes2.default.string, - saveText: _propTypes2.default.string, - closeText: _propTypes2.default.string, - ignoreEditable: _propTypes2.default.bool, - defaultSearch: _propTypes2.default.string, - insertModalHeader: _propTypes2.default.func, - insertModalBody: _propTypes2.default.func, - insertModalFooter: _propTypes2.default.func, - insertModal: _propTypes2.default.func, - insertBtn: _propTypes2.default.func, - deleteBtn: _propTypes2.default.func, - showSelectedOnlyBtn: _propTypes2.default.func, - exportCSVBtn: _propTypes2.default.func, - clearSearchBtn: _propTypes2.default.func, - searchField: _propTypes2.default.func, - searchPanel: _propTypes2.default.func, - btnGroup: _propTypes2.default.func, - toolBar: _propTypes2.default.func, - sizePerPageDropDown: _propTypes2.default.func, - paginationPanel: _propTypes2.default.func, - searchPosition: _propTypes2.default.string, - expandRowBgColor: _propTypes2.default.string, - expandBy: _propTypes2.default.string, - expanding: _propTypes2.default.array, - onExpand: _propTypes2.default.func, - onlyOneExpanding: _propTypes2.default.bool, - expandBodyClass: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.func]), - expandParentClass: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.func]), - beforeShowError: _propTypes2.default.func, - printToolBar: _propTypes2.default.bool, - insertFailIndicator: _propTypes2.default.string, - noAutoBOM: _propTypes2.default.bool - }), - fetchInfo: _propTypes2.default.shape({ - dataTotalSize: _propTypes2.default.number - }), - exportCSV: _propTypes2.default.bool, - csvFileName: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.func]), - ignoreSinglePage: _propTypes2.default.bool, - expandableRow: _propTypes2.default.func, - expandComponent: _propTypes2.default.func, - expandColumnOptions: _propTypes2.default.shape({ - columnWidth: _propTypes2.default.oneOfType([_propTypes2.default.number, _propTypes2.default.string]), - expandColumnVisible: _propTypes2.default.bool, - expandColumnComponent: _propTypes2.default.func, - expandColumnBeforeSelectColumn: _propTypes2.default.bool - }) -}; -BootstrapTable.defaultProps = { - version: '3', - replace: false, - scrollTop: undefined, - expandComponent: undefined, - expandableRow: undefined, - expandColumnOptions: { - expandColumnVisible: false, - expandColumnComponent: undefined, - expandColumnBeforeSelectColumn: true - }, - height: '100%', - maxHeight: undefined, - striped: false, - bordered: true, - hover: false, - condensed: false, - pagination: false, - printable: false, - withoutTabIndex: false, - keyBoardNav: false, - searchPlaceholder: undefined, - selectRow: { - mode: _Const2.default.ROW_SELECT_NONE, - bgColor: _Const2.default.ROW_SELECT_BG_COLOR, - selected: [], - onSelect: undefined, - onSelectAll: undefined, - clickToSelect: false, - hideSelectColumn: false, - clickToSelectAndEditCell: false, - clickToExpand: false, - showOnlySelected: false, - unselectable: [], - customComponent: undefined, - onlyUnselectVisible: false - }, - cellEdit: { - mode: _Const2.default.CELL_EDIT_NONE, - blurToSave: false, - beforeSaveCell: undefined, - afterSaveCell: undefined, - nonEditableRows: undefined - }, - insertRow: false, - deleteRow: false, - search: false, - multiColumnSearch: false, - strictSearch: undefined, - multiColumnSort: 1, - columnFilter: false, - trClassName: '', - trStyle: undefined, - tableStyle: undefined, - containerStyle: undefined, - headerStyle: undefined, - bodyStyle: undefined, - containerClass: null, - tableContainerClass: null, - headerContainerClass: null, - bodyContainerClass: null, - tableHeaderClass: null, - tableBodyClass: null, - options: { - clearSearch: false, - sortName: undefined, - sortOrder: undefined, - defaultSortName: undefined, - defaultSortOrder: undefined, - sortIndicator: true, - afterTableComplete: undefined, - afterDeleteRow: undefined, - afterInsertRow: undefined, - afterSearch: undefined, - afterColumnFilter: undefined, - onRowClick: undefined, - onRowDoubleClick: undefined, - onMouseLeave: undefined, - onMouseEnter: undefined, - onRowMouseOut: undefined, - onRowMouseOver: undefined, - page: undefined, - paginationShowsTotal: false, - sizePerPageList: _Const2.default.SIZE_PER_PAGE_LIST, - sizePerPage: undefined, - paginationSize: _Const2.default.PAGINATION_SIZE, - paginationPosition: _Const2.default.PAGINATION_POS_BOTTOM, - hideSizePerPage: false, - hidePageListOnlyOnePage: false, - alwaysShowAllBtns: false, - withFirstAndLast: true, - keepSizePerPageState: false, - onSizePerPageList: undefined, - noDataText: undefined, - withoutNoDataText: false, - handleConfirmDeleteRow: undefined, - prePage: _Const2.default.PRE_PAGE, - nextPage: _Const2.default.NEXT_PAGE, - firstPage: _Const2.default.FIRST_PAGE, - lastPage: _Const2.default.LAST_PAGE, - prePageTitle: _Const2.default.PRE_PAGE_TITLE, - nextPageTitle: _Const2.default.NEXT_PAGE_TITLE, - firstPageTitle: _Const2.default.FIRST_PAGE_TITLE, - lastPageTitle: _Const2.default.LAST_PAGE_TITLE, - pageStartIndex: 1, - searchDelayTime: undefined, - excludeCSVHeader: false, - exportCSVText: _Const2.default.EXPORT_CSV_TEXT, - exportCSVSeparator: _Const2.default.DEFAULT_CSV_SEPARATOR, - insertText: _Const2.default.INSERT_BTN_TEXT, - deleteText: _Const2.default.DELETE_BTN_TEXT, - saveText: _Const2.default.SAVE_BTN_TEXT, - closeText: _Const2.default.CLOSE_BTN_TEXT, - ignoreEditable: false, - defaultSearch: '', - insertModalHeader: undefined, - insertModalBody: undefined, - insertModalFooter: undefined, - insertModal: undefined, - insertBtn: undefined, - deleteBtn: undefined, - showSelectedOnlyBtn: undefined, - exportCSVBtn: undefined, - clearSearchBtn: undefined, - searchField: undefined, - searchPanel: undefined, - btnGroup: undefined, - toolBar: undefined, - sizePerPageDropDown: undefined, - paginationPanel: undefined, - searchPosition: 'right', - expandRowBgColor: undefined, - expandBy: _Const2.default.EXPAND_BY_ROW, - expanding: [], - onExpand: undefined, - onlyOneExpanding: false, - expandBodyClass: null, - expandParentClass: null, - beforeShowError: undefined, - printToolBar: true, - insertFailIndicator: _Const2.default.INSERT_FAIL_INDICATOR, - noAutoBOM: true - }, - fetchInfo: { - dataTotalSize: 0 - }, - exportCSV: false, - csvFileName: 'spreadsheet.csv', - ignoreSinglePage: false -}; + if (!this.enabled) { + return; + } -var _default = BootstrapTable; -exports.default = _default; -; + this.clearCache(); -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } + // Turn 'auto' attachments into the appropriate corner or edge + var targetAttachment = autoToFixedAttachment(this.targetAttachment, this.attachment); - __REACT_HOT_LOADER__.register(BootstrapTable, 'BootstrapTable', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/BootstrapTable.js'); + this.updateAttachClasses(this.attachment, targetAttachment); - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/BootstrapTable.js'); -}(); + var elementPos = this.cache('element-bounds', function () { + return getBounds(_this7.element); + }); -; + var width = elementPos.width; + var height = elementPos.height; -/***/ }), -/* 363 */ -/***/ (function(module, exports, __webpack_require__) { + if (width === 0 && height === 0 && typeof this.lastSize !== 'undefined') { + var _lastSize = this.lastSize; -var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (global, factory) { - if (true) { - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports, __webpack_require__(4), __webpack_require__(283), __webpack_require__(9), __webpack_require__(257), __webpack_require__(256), __webpack_require__(365)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), - __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? - (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else if (typeof exports !== "undefined") { - factory(exports, require('react'), require('./SAlertContent'), require('prop-types'), require('./s-alert-parts/s-alert-store'), require('./s-alert-parts/s-alert-tools'), require('./s-alert-parts/s-alert-data-prep')); - } else { - var mod = { - exports: {} - }; - factory(mod.exports, global.react, global.SAlertContent, global.propTypes, global.sAlertStore, global.sAlertTools, global.sAlertDataPrep); - global.SAlert = mod.exports; - } -})(this, function (exports, _react, _SAlertContent, _propTypes, _sAlertStore, _sAlertTools, _sAlertDataPrep) { - 'use strict'; + // We cache the height and width to make it possible to position elements that are + // getting hidden. + width = _lastSize.width; + height = _lastSize.height; + } else { + this.lastSize = { width: width, height: height }; + } - Object.defineProperty(exports, "__esModule", { - value: true - }); + var targetPos = this.cache('target-bounds', function () { + return _this7.getTargetBounds(); + }); + var targetSize = targetPos; - var _react2 = _interopRequireDefault(_react); + // Get an actual px offset from the attachment + var offset = offsetToPx(attachmentToOffset(this.attachment), { width: width, height: height }); + var targetOffset = offsetToPx(attachmentToOffset(targetAttachment), targetSize); - var _SAlertContent2 = _interopRequireDefault(_SAlertContent); + var manualOffset = offsetToPx(this.offset, { width: width, height: height }); + var manualTargetOffset = offsetToPx(this.targetOffset, targetSize); - var _propTypes2 = _interopRequireDefault(_propTypes); + // Add the manually provided offset + offset = addOffset(offset, manualOffset); + targetOffset = addOffset(targetOffset, manualTargetOffset); - var _sAlertStore2 = _interopRequireDefault(_sAlertStore); + // It's now our goal to make (element position + offset) == (target position + target offset) + var left = targetPos.left + targetOffset.left - offset.left; + var top = targetPos.top + targetOffset.top - offset.top; - var _sAlertTools2 = _interopRequireDefault(_sAlertTools); + for (var i = 0; i < _utils2['default'].modules.length; ++i) { + var _module2 = _utils2['default'].modules[i]; + var ret = _module2.position.call(this, { + left: left, + top: top, + targetAttachment: targetAttachment, + targetPos: targetPos, + elementPos: elementPos, + offset: offset, + targetOffset: targetOffset, + manualOffset: manualOffset, + manualTargetOffset: manualTargetOffset, + scrollbarSize: scrollbarSize, + attachment: this.attachment + }); - var _sAlertDataPrep2 = _interopRequireDefault(_sAlertDataPrep); + if (ret === false) { + return false; + } else if (typeof ret === 'undefined' || typeof ret !== 'object') { + continue; + } else { + top = ret.top; + left = ret.left; + } + } - function _interopRequireDefault(obj) { - return obj && obj.__esModule ? obj : { - default: obj - }; - } + // We describe the position three different ways to give the optimizer + // a chance to decide the best possible way to position the element + // with the fewest repaints. + var next = { + // It's position relative to the page (absolute positioning when + // the element is a child of the body) + page: { + top: top, + left: left + }, - function _classCallCheck(instance, Constructor) { - if (!(instance instanceof Constructor)) { - throw new TypeError("Cannot call a class as a function"); + // It's position relative to the viewport (fixed positioning) + viewport: { + top: top - pageYOffset, + bottom: pageYOffset - top - height + innerHeight, + left: left - pageXOffset, + right: pageXOffset - left - width + innerWidth } - } + }; - var _createClass = function () { - function defineProperties(target, props) { - for (var i = 0; i < props.length; i++) { - var descriptor = props[i]; - descriptor.enumerable = descriptor.enumerable || false; - descriptor.configurable = true; - if ("value" in descriptor) descriptor.writable = true; - Object.defineProperty(target, descriptor.key, descriptor); - } - } + var doc = this.target.ownerDocument; + var win = doc.defaultView; - return function (Constructor, protoProps, staticProps) { - if (protoProps) defineProperties(Constructor.prototype, protoProps); - if (staticProps) defineProperties(Constructor, staticProps); - return Constructor; - }; - }(); + var scrollbarSize = undefined; + if (doc.body.scrollWidth > win.innerWidth) { + scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); + next.viewport.bottom -= scrollbarSize.height; + } - function _possibleConstructorReturn(self, call) { - if (!self) { - throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); - } + if (doc.body.scrollHeight > win.innerHeight) { + scrollbarSize = this.cache('scrollbar-size', getScrollBarSize); + next.viewport.right -= scrollbarSize.width; + } - return call && (typeof call === "object" || typeof call === "function") ? call : self; - } + if (['', 'static'].indexOf(doc.body.style.position) === -1 || ['', 'static'].indexOf(doc.body.parentElement.style.position) === -1) { + // Absolute positioning in the body will be relative to the page, not the 'initial containing block' + next.page.bottom = doc.body.scrollHeight - top - height; + next.page.right = doc.body.scrollWidth - left - width; + } - function _inherits(subClass, superClass) { - if (typeof superClass !== "function" && superClass !== null) { - throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); - } + if (typeof this.options.optimizations !== 'undefined' && this.options.optimizations.moveElement !== false && !(typeof this.targetModifier !== 'undefined')) { + (function () { + var offsetParent = _this7.cache('target-offsetparent', function () { + return getOffsetParent(_this7.target); + }); + var offsetPosition = _this7.cache('target-offsetparent-bounds', function () { + return getBounds(offsetParent); + }); + var offsetParentStyle = getComputedStyle(offsetParent); + var offsetParentSize = offsetPosition; - subClass.prototype = Object.create(superClass && superClass.prototype, { - constructor: { - value: subClass, - enumerable: false, - writable: true, - configurable: true - } - }); - if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; - } + var offsetBorder = {}; + ['Top', 'Left', 'Bottom', 'Right'].forEach(function (side) { + offsetBorder[side.toLowerCase()] = parseFloat(offsetParentStyle['border' + side + 'Width']); + }); - var insertFunc = function insertFunc(msg, data, condition) { - var id = _sAlertTools2.default.randomId(); - _sAlertStore2.default.dispatch({ - type: 'INSERT', - data: Object.assign({}, data, { - id: id, - condition: condition, - message: msg - }) - }); - return id; - }; + offsetPosition.right = doc.body.scrollWidth - offsetPosition.left - offsetParentSize.width + offsetBorder.right; + offsetPosition.bottom = doc.body.scrollHeight - offsetPosition.top - offsetParentSize.height + offsetBorder.bottom; - var SAlert = function (_React$Component) { - _inherits(SAlert, _React$Component); + if (next.page.top >= offsetPosition.top + offsetBorder.top && next.page.bottom >= offsetPosition.bottom) { + if (next.page.left >= offsetPosition.left + offsetBorder.left && next.page.right >= offsetPosition.right) { + // We're within the visible part of the target's scroll parent + var scrollTop = offsetParent.scrollTop; + var scrollLeft = offsetParent.scrollLeft; - function SAlert(props) { - _classCallCheck(this, SAlert); + // It's position relative to the target's offset parent (absolute positioning when + // the element is moved to be a child of the target's offset parent). + next.offset = { + top: next.page.top - offsetPosition.top + scrollTop - offsetBorder.top, + left: next.page.left - offsetPosition.left + scrollLeft - offsetBorder.left + }; + } + } + })(); + } - var _this = _possibleConstructorReturn(this, (SAlert.__proto__ || Object.getPrototypeOf(SAlert)).call(this, props)); + // We could also travel up the DOM and try each containing context, rather than only + // looking at the body, but we're gonna get diminishing returns. - _this.state = { - dataRight: [], - dataLeft: [], - dataTop: [], - dataBottom: [] - }; - return _this; - } + this.move(next); - _createClass(SAlert, [{ - key: 'componentDidMount', - value: function componentDidMount() { - var _this2 = this; - - var storeStateLeft = void 0; - var storeStateRight = void 0; - var storeStateTop = void 0; - var storeStateBottom = void 0; - - var addToStoreRight = function addToStoreRight() { - var length = void 0; - storeStateRight = (0, _sAlertDataPrep2.default)('right') || []; - length = storeStateRight.length; - if (_this2.props.stack && _this2.props.stack.limit && length > _this2.props.stack.limit) { - var id = storeStateRight[0].id; - _sAlertStore2.default.dispatch({ type: 'REMOVE', data: { id: id } }); - storeStateRight = (0, _sAlertDataPrep2.default)('right') || []; - } - _this2.setState({ dataRight: storeStateRight }); - }; - this.unsubStoreRight = _sAlertStore2.default.subscribe(addToStoreRight); - - var addToStoreLeft = function addToStoreLeft() { - var length = void 0; - storeStateLeft = (0, _sAlertDataPrep2.default)('left') || []; - length = storeStateLeft.length; - if (_this2.props.stack && _this2.props.stack.limit && length > _this2.props.stack.limit) { - var id = storeStateLeft[0].id; - _sAlertStore2.default.dispatch({ type: 'REMOVE', data: { id: id } }); - storeStateLeft = (0, _sAlertDataPrep2.default)('left') || []; - } - _this2.setState({ dataLeft: storeStateLeft }); - }; - this.unsubStoreLeft = _sAlertStore2.default.subscribe(addToStoreLeft); - - var addToStoreTop = function addToStoreTop() { - var length = void 0; - storeStateTop = (0, _sAlertDataPrep2.default)('full-top') || []; - length = storeStateTop.length; - if (_this2.props.stack && _this2.props.stack.limit && length > _this2.props.stack.limit) { - var id = storeStateTop[0].id; - _sAlertStore2.default.dispatch({ type: 'REMOVE', data: { id: id } }); - storeStateTop = (0, _sAlertDataPrep2.default)('full-top') || []; - } - _this2.setState({ dataTop: storeStateTop }); - }; - this.unsubStoreTop = _sAlertStore2.default.subscribe(addToStoreTop); - - var addToStoreBottom = function addToStoreBottom() { - var length = void 0; - storeStateBottom = (0, _sAlertDataPrep2.default)('full-bottom') || []; - length = storeStateBottom.length; - if (_this2.props.stack && _this2.props.stack.limit && length > _this2.props.stack.limit) { - var id = storeStateBottom[0].id; - _sAlertStore2.default.dispatch({ type: 'REMOVE', data: { id: id } }); - storeStateBottom = (0, _sAlertDataPrep2.default)('full-bottom') || []; - } - _this2.setState({ dataBottom: storeStateBottom }); - }; - this.unsubStoreBottom = _sAlertStore2.default.subscribe(addToStoreBottom); - - // set up global config from global SAlert props - // only stuff needed for getAlertData - var globalConfig = { - contentTemplate: this.props.contentTemplate, - offset: this.props.offset, - message: this.props.message, - stack: this.props.stack, - html: this.props.html, - customFields: this.props.customFields, - position: this.props.position || 'top-right' - }; - _sAlertTools2.default.setGlobalConfig(globalConfig); - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.unsubStoreTop(); - this.unsubStoreBottom(); - this.unsubStoreLeft(); - this.unsubStoreRight(); - } - }, { - key: 'render', - value: function render() { - var _this3 = this; - - var mapFunc = function mapFunc(alert, index) { - var customKey = 'alert-key-' + alert.id + '-' + alert.position; - var id = alert.id; - var condition = _sAlertTools2.default.returnFirstDefined(alert.condition, 'info'); - var message = _sAlertTools2.default.returnFirstDefined(alert.message, _this3.props.message, ''); - var position = _sAlertTools2.default.returnFirstDefined(alert.position, _this3.props.position, 'top-right'); - var offset = _sAlertTools2.default.returnFirstDefined(alert.offset, _this3.props.offset, 0); - var effect = _sAlertTools2.default.returnFirstDefined(alert.effect, _this3.props.effect); - var boxPosition = alert.boxPosition; - var beep = _sAlertTools2.default.returnFirstDefined(alert.beep, _this3.props.beep, false); - var timeout = _sAlertTools2.default.returnFirstDefined(alert.timeout, _this3.props.timeout, 5000); - var html = _sAlertTools2.default.returnFirstDefined(alert.html, _this3.props.html); - var onClose = _sAlertTools2.default.returnFirstDefined(alert.onClose, _this3.props.onClose); - var onShow = _sAlertTools2.default.returnFirstDefined(alert.onShow, _this3.props.onShow); - var customFields = _sAlertTools2.default.returnFirstDefined(alert.customFields, _this3.props.customFields); - var contentTemplate = _this3.props.contentTemplate; - return _react2.default.createElement(_SAlertContent2.default, { - key: customKey, - id: id, - customFields: customFields, - condition: condition, - message: message, - position: position, - effect: effect, - boxPosition: boxPosition, - beep: beep, - timeout: timeout, - html: html, - onClose: onClose, - onShow: onShow, - contentTemplate: contentTemplate }); - }; - var sAlertElemsRight = this.state.dataRight.map(mapFunc); - var sAlertElemsLeft = this.state.dataLeft.map(mapFunc); - var sAlertElemsTop = this.state.dataTop.map(mapFunc); - var sAlertElemsBottom = this.state.dataBottom.map(mapFunc); - return _react2.default.createElement( - 'div', - { className: 's-alert-wrapper' }, - sAlertElemsRight, - sAlertElemsLeft, - sAlertElemsTop, - sAlertElemsBottom - ); - } - }], [{ - key: 'info', - value: function info(msg, data) { - return insertFunc(msg, data, 'info'); - } - }, { - key: 'error', - value: function error(msg, data) { - return insertFunc(msg, data, 'error'); - } - }, { - key: 'warning', - value: function warning(msg, data) { - return insertFunc(msg, data, 'warning'); - } - }, { - key: 'success', - value: function success(msg, data) { - return insertFunc(msg, data, 'success'); - } - }, { - key: 'close', - value: function close(id) { - _sAlertStore2.default.dispatch({ type: 'REMOVE', data: { id: id } }); - } - }, { - key: 'closeAll', - value: function closeAll() { - _sAlertStore2.default.dispatch({ type: 'REMOVEALL' }); - } - }]); - - return SAlert; - }(_react2.default.Component); - - SAlert.propTypes = { - message: _propTypes2.default.string, - position: _propTypes2.default.string, - offset: _propTypes2.default.number, - stack: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.object]), - effect: _propTypes2.default.string, - beep: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.object, _propTypes2.default.bool]), - timeout: _propTypes2.default.oneOfType([_propTypes2.default.oneOf(['none']), _propTypes2.default.number]), - html: _propTypes2.default.bool, - onClose: _propTypes2.default.func, - onShow: _propTypes2.default.func, - customFields: _propTypes2.default.object, - contentTemplate: _propTypes2.default.func - }; + this.history.unshift(next); - exports.default = SAlert; -}); + if (this.history.length > 3) { + this.history.pop(); + } -/***/ }), -/* 364 */ -/***/ (function(module, exports, __webpack_require__) { + if (flushChanges) { + flush(); + } -var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (global, factory) { - if (true) { - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports, __webpack_require__(4), __webpack_require__(9)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), - __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? - (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else if (typeof exports !== "undefined") { - factory(exports, require('react'), require('prop-types')); - } else { - var mod = { - exports: {} - }; - factory(mod.exports, global.react, global.propTypes); - global.SAlertContentTmpl = mod.exports; + return true; } -})(this, function (exports, _react, _propTypes) { - 'use strict'; - Object.defineProperty(exports, "__esModule", { - value: true - }); + // THE ISSUE + }, { + key: 'move', + value: function move(pos) { + var _this8 = this; - var _react2 = _interopRequireDefault(_react); + if (!(typeof this.element.parentNode !== 'undefined')) { + return; + } - var _propTypes2 = _interopRequireDefault(_propTypes); + var same = {}; - function _interopRequireDefault(obj) { - return obj && obj.__esModule ? obj : { - default: obj - }; - } + for (var type in pos) { + same[type] = {}; - function _classCallCheck(instance, Constructor) { - if (!(instance instanceof Constructor)) { - throw new TypeError("Cannot call a class as a function"); - } - } + for (var key in pos[type]) { + var found = false; - var _createClass = function () { - function defineProperties(target, props) { - for (var i = 0; i < props.length; i++) { - var descriptor = props[i]; - descriptor.enumerable = descriptor.enumerable || false; - descriptor.configurable = true; - if ("value" in descriptor) descriptor.writable = true; - Object.defineProperty(target, descriptor.key, descriptor); + for (var i = 0; i < this.history.length; ++i) { + var point = this.history[i]; + if (typeof point[type] !== 'undefined' && !within(point[type][key], pos[type][key])) { + found = true; + break; } - } - - return function (Constructor, protoProps, staticProps) { - if (protoProps) defineProperties(Constructor.prototype, protoProps); - if (staticProps) defineProperties(Constructor, staticProps); - return Constructor; - }; - }(); + } - function _possibleConstructorReturn(self, call) { - if (!self) { - throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); + if (!found) { + same[type][key] = true; + } } + } - return call && (typeof call === "object" || typeof call === "function") ? call : self; - } + var css = { top: '', left: '', right: '', bottom: '' }; - function _inherits(subClass, superClass) { - if (typeof superClass !== "function" && superClass !== null) { - throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); - } + var transcribe = function transcribe(_same, _pos) { + var hasOptimizations = typeof _this8.options.optimizations !== 'undefined'; + var gpu = hasOptimizations ? _this8.options.optimizations.gpu : null; + if (gpu !== false) { + var yPos = undefined, + xPos = undefined; + if (_same.top) { + css.top = 0; + yPos = _pos.top; + } else { + css.bottom = 0; + yPos = -_pos.bottom; + } - subClass.prototype = Object.create(superClass && superClass.prototype, { - constructor: { - value: subClass, - enumerable: false, - writable: true, - configurable: true - } - }); - if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; - } + if (_same.left) { + css.left = 0; + xPos = _pos.left; + } else { + css.right = 0; + xPos = -_pos.right; + } - var SAlertContentTmpl = function (_React$Component) { - _inherits(SAlertContentTmpl, _React$Component); + css[transformKey] = 'translateX(' + Math.round(xPos) + 'px) translateY(' + Math.round(yPos) + 'px)'; - function SAlertContentTmpl(props) { - _classCallCheck(this, SAlertContentTmpl); + if (transformKey !== 'msTransform') { + // The Z transform will keep this in the GPU (faster, and prevents artifacts), + // but IE9 doesn't support 3d transforms and will choke. + css[transformKey] += " translateZ(0)"; + } + } else { + if (_same.top) { + css.top = _pos.top + 'px'; + } else { + css.bottom = _pos.bottom + 'px'; + } - return _possibleConstructorReturn(this, (SAlertContentTmpl.__proto__ || Object.getPrototypeOf(SAlertContentTmpl)).call(this, props)); + if (_same.left) { + css.left = _pos.left + 'px'; + } else { + css.right = _pos.right + 'px'; + } } + }; - _createClass(SAlertContentTmpl, [{ - key: 'render', - value: function render() { - return _react2.default.createElement( - 'div', - { className: this.props.classNames, id: this.props.id, style: this.props.styles }, - _react2.default.createElement( - 'div', - { className: 's-alert-box-inner' }, - this.props.message - ), - _react2.default.createElement('span', { className: 's-alert-close', onClick: this.props.handleClose }) - ); - } - }]); - - return SAlertContentTmpl; - }(_react2.default.Component); - - SAlertContentTmpl.propTypes = { - id: _propTypes2.default.string.isRequired, - classNames: _propTypes2.default.string.isRequired, - styles: _propTypes2.default.object.isRequired, - message: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.object]).isRequired, - handleClose: _propTypes2.default.func.isRequired, - customFields: _propTypes2.default.object - }; - - exports.default = SAlertContentTmpl; -}); - -/***/ }), -/* 365 */ -/***/ (function(module, exports, __webpack_require__) { + var moved = false; + if ((same.page.top || same.page.bottom) && (same.page.left || same.page.right)) { + css.position = 'absolute'; + transcribe(same.page, pos.page); + } else if ((same.viewport.top || same.viewport.bottom) && (same.viewport.left || same.viewport.right)) { + css.position = 'fixed'; + transcribe(same.viewport, pos.viewport); + } else if (typeof same.offset !== 'undefined' && same.offset.top && same.offset.left) { + (function () { + css.position = 'absolute'; + var offsetParent = _this8.cache('target-offsetparent', function () { + return getOffsetParent(_this8.target); + }); -var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (global, factory) { - if (true) { - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports, __webpack_require__(4), __webpack_require__(28), __webpack_require__(283), __webpack_require__(257), __webpack_require__(256)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), - __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? - (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else if (typeof exports !== "undefined") { - factory(exports, require('react'), require('react-dom'), require('../SAlertContent'), require('./s-alert-store'), require('./s-alert-tools')); - } else { - var mod = { - exports: {} - }; - factory(mod.exports, global.react, global.reactDom, global.SAlertContent, global.sAlertStore, global.sAlertTools); - global.sAlertDataPrep = mod.exports; - } -})(this, function (exports, _react, _reactDom, _SAlertContent, _sAlertStore, _sAlertTools) { - 'use strict'; + if (getOffsetParent(_this8.element) !== offsetParent) { + defer(function () { + _this8.element.parentNode.removeChild(_this8.element); + offsetParent.appendChild(_this8.element); + }); + } - Object.defineProperty(exports, "__esModule", { - value: true - }); + transcribe(same.offset, pos.offset); + moved = true; + })(); + } else { + css.position = 'absolute'; + transcribe({ top: true, left: true }, pos.page); + } - var _react2 = _interopRequireDefault(_react); + if (!moved) { + var offsetParentIsBody = true; + var currentNode = this.element.parentNode; + while (currentNode && currentNode.nodeType === 1 && currentNode.tagName !== 'BODY') { + if (getComputedStyle(currentNode).position !== 'static') { + offsetParentIsBody = false; + break; + } - var _reactDom2 = _interopRequireDefault(_reactDom); + currentNode = currentNode.parentNode; + } - var _SAlertContent2 = _interopRequireDefault(_SAlertContent); + if (!offsetParentIsBody) { + this.element.parentNode.removeChild(this.element); + this.element.ownerDocument.body.appendChild(this.element); + } + } - var _sAlertStore2 = _interopRequireDefault(_sAlertStore); + // Any css change will trigger a repaint, so let's avoid one if nothing changed + var writeCSS = {}; + var write = false; + for (var key in css) { + var val = css[key]; + var elVal = this.element.style[key]; - var _sAlertTools2 = _interopRequireDefault(_sAlertTools); + if (elVal !== val) { + write = true; + writeCSS[key] = val; + } + } - function _interopRequireDefault(obj) { - return obj && obj.__esModule ? obj : { - default: obj - }; + if (write) { + defer(function () { + extend(_this8.element.style, writeCSS); + _this8.trigger('repositioned'); + }); + } } + }]); - var getAlertData = function getAlertData(sAlertPosition) { - var positionTop = 0; - var positionBottom = 0; - var padding = 0; - var alerts = {}; - var style = void 0; - var docElement = void 0; - var sAlertBoxHeight = void 0; - var positionTypeTop = void 0; - var positionTypeBottom = void 0; - var checkFirst = function checkFirst(type, objId) { - var collectionOfType = sAlertCollection.filter(function (obj) { - return obj.position === type || sAlertGlobalConfig.position === type; - }); - return collectionOfType && collectionOfType[0].id === objId; - }; - var positionFunc = function positionFunc(position, positionType, alert, docElement, sAlertBoxHeight, reactComponent) { - padding = aStack.spacing || parseInt(getComputedStyle(_reactDom2.default.findDOMNode(reactComponent))[positionType]); - if (checkFirst(aPosition, alert.id) && aOffset) { - position = 0; - position = position + parseInt(aOffset); - } - if (checkFirst(aPosition, alert.id) && aStack.spacing) { - position = position; - } else { - position = position + parseInt(padding); - } - style = positionType + ': ' + position + 'px;'; - position = position + sAlertBoxHeight; - return position; - }; - - var sAlertGlobalConfig = _sAlertTools2.default.getGlobalConfig(); - var aStack = void 0; - var aContentTemplate = void 0; - var aOffset = void 0; - var aMessage = void 0; - var aHtml = void 0; - var aCustomFields = void 0; - var aPosition = void 0; - - var query = {}; - if (sAlertPosition === 'left') { - query = function query(item) { - return item.position === 'top-left' || item.position === 'bottom-left' || !item.position && (sAlertGlobalConfig.position === 'top-left' || sAlertGlobalConfig.position === 'bottom-left'); - }; - } - if (sAlertPosition === 'right') { - query = function query(item) { - return item.position === 'top-right' || item.position === 'bottom-right' || !item.position && (sAlertGlobalConfig.position === 'top-right' || sAlertGlobalConfig.position === 'bottom-right'); - }; - } - if (sAlertPosition === 'full-top') { - query = function query(item) { - return item.position === 'top' || !item.position && sAlertGlobalConfig.position === 'top'; - }; - } - if (sAlertPosition === 'full-bottom') { - query = function query(item) { - return item.position === 'bottom' || !item.position && sAlertGlobalConfig.position === 'bottom'; - }; - } - - var currentState = _sAlertStore2.default.getState(); - var sAlertCollection = currentState.slice().filter(query); - - return sAlertCollection.map(function (alert) { - aStack = sAlertGlobalConfig.stack; - aContentTemplate = sAlertGlobalConfig.contentTemplate; - aOffset = _sAlertTools2.default.returnFirstDefined(alert.offset, sAlertGlobalConfig.offset); - aMessage = _sAlertTools2.default.returnFirstDefined(alert.message, sAlertGlobalConfig.message); - aHtml = _sAlertTools2.default.returnFirstDefined(alert.html, sAlertGlobalConfig.html); - aCustomFields = _sAlertTools2.default.returnFirstDefined(alert.customFields, sAlertGlobalConfig.customFields); - aPosition = _sAlertTools2.default.returnFirstDefined(alert.position, sAlertGlobalConfig.position); - positionTypeTop = aPosition && /top/g.test(aPosition); - positionTypeBottom = aPosition && /bottom/g.test(aPosition); - if (aStack) { - // checking alert box height - needed to calculate position - docElement = document.createElement('div'); - docElement.classList.add('s-alert-box-height'); - - // mock element, needed for positions calculations - var reactElement = _react2.default.createElement(_SAlertContent2.default, { - key: _sAlertTools2.default.randomId(), - id: _sAlertTools2.default.randomId(), - condition: alert.condition, - message: aMessage, - position: aPosition, - effect: alert.effect, - boxPosition: alert.boxPosition, - beep: false, - timeout: 'none', - html: aHtml, - contentTemplate: aContentTemplate, - customFields: aCustomFields - }); - var reactComponent = _reactDom2.default.render(reactElement, docElement); + return TetherClass; +})(Evented); - document.body.appendChild(docElement); - sAlertBoxHeight = parseInt(getComputedStyle(_reactDom2.default.findDOMNode(reactComponent))['height']); - if (positionTypeTop) { - positionTop = positionFunc(positionTop, 'top', alert, docElement, sAlertBoxHeight, reactComponent); - } - if (positionTypeBottom) { - positionBottom = positionFunc(positionBottom, 'bottom', alert, docElement, sAlertBoxHeight, reactComponent); - } - var sAlertComputedStyle = getComputedStyle(_reactDom2.default.findDOMNode(reactComponent)); - if (sAlertPosition === 'left') { - style = style + 'left: ' + (aStack.spacing || parseInt(sAlertComputedStyle.left)) + 'px;'; - } - if (sAlertPosition === 'right') { - style = style + 'right: ' + (aStack.spacing || parseInt(sAlertComputedStyle.right)) + 'px;'; - } - alerts = Object.assign({}, alert, { boxPosition: style }); - _reactDom2.default.unmountComponentAtNode(docElement); - docElement.parentNode.removeChild(docElement); - } else if (aOffset && positionTypeTop) { - alerts = Object.assign({}, alert, { boxPosition: 'top: ' + parseInt(aOffset) + 'px;' }); - } else if (aOffset && positionTypeBottom) { - alerts = Object.assign({}, alert, { boxPosition: 'bottom: ' + parseInt(aOffset) + 'px;' }); - } else { - alerts = alert; - } - return alerts; - }); - }; +TetherClass.modules = []; - exports.default = getAlertData; -}); +_utils2['default'].position = position; -/***/ }), -/* 366 */ -/***/ (function(module, exports, __webpack_require__) { +var Tether = extend(TetherClass, _utils2['default']); -"use strict"; +exports['default'] = Tether; +module.exports = exports['default']; +},{"./abutment":1,"./constraint":2,"./shift":3,"./utils":5}],5:[function(require,module,exports){ +'use strict'; -Object.defineProperty(exports, "__esModule", { +Object.defineProperty(exports, '__esModule', { value: true }); -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); +var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +var TetherBase = { modules: [] }; -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +var zeroElement = null; -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } /* eslint quotes: 0 */ -/* eslint max-len: 0 */ +// Same as native getBoundingClientRect, except it takes into account parent <frame> offsets +// if the element lies within a nested document (<frame> or <iframe>-like). +function getActualBoundingClientRect(node) { + var boundingRect = node.getBoundingClientRect(); + // The original object returned by getBoundingClientRect is immutable, so we clone it + // We can't use extend because the properties are not considered part of the object by hasOwnProperty in IE9 + var rect = {}; + for (var k in boundingRect) { + rect[k] = boundingRect[k]; + } -var legalComparators = ['=', '>', '>=', '<', '<=', '!=']; + if (node.ownerDocument !== document) { + var _frameElement = node.ownerDocument.defaultView.frameElement; + if (_frameElement) { + var frameRect = getActualBoundingClientRect(_frameElement); + rect.top += frameRect.top; + rect.bottom += frameRect.top; + rect.left += frameRect.left; + rect.right += frameRect.left; + } + } -function dateParser(d) { - return d.getFullYear() + '-' + ("0" + (d.getMonth() + 1)).slice(-2) + '-' + ("0" + d.getDate()).slice(-2); + return rect; } -var DateFilter = function (_Component) { - _inherits(DateFilter, _Component); - - function DateFilter(props) { - _classCallCheck(this, DateFilter); - - var _this = _possibleConstructorReturn(this, (DateFilter.__proto__ || Object.getPrototypeOf(DateFilter)).call(this, props)); +function getScrollParents(el) { + // In firefox if the el is inside an iframe with display: none; window.getComputedStyle() will return null; + // https://bugzilla.mozilla.org/show_bug.cgi?id=548397 + var computedStyle = getComputedStyle(el) || {}; + var position = computedStyle.position; + var parents = []; - _this.dateComparators = _this.props.dateComparators || legalComparators; - _this.filter = _this.filter.bind(_this); - _this.onChangeComparator = _this.onChangeComparator.bind(_this); - return _this; + if (position === 'fixed') { + return [el]; } - _createClass(DateFilter, [{ - key: 'setDefaultDate', - value: function setDefaultDate() { - var defaultDate = ''; - var defaultValue = this.props.defaultValue; - - if (defaultValue && defaultValue.date) { - // Set the appropriate format for the input type=date, i.e. "YYYY-MM-DD" - defaultDate = dateParser(new Date(defaultValue.date)); - } - return defaultDate; - } - }, { - key: 'onChangeComparator', - value: function onChangeComparator(event) { - var date = this.refs.inputDate.value; - var comparator = event.target.value; - if (date === '') { - return; - } - date = new Date(date); - this.props.filterHandler({ date: date, comparator: comparator }, _Const2.default.FILTER_TYPE.DATE); - } - }, { - key: 'getComparatorOptions', - value: function getComparatorOptions() { - var optionTags = []; - optionTags.push(_react2.default.createElement('option', { key: '-1' })); - for (var i = 0; i < this.dateComparators.length; i++) { - optionTags.push(_react2.default.createElement( - 'option', - { key: i, value: this.dateComparators[i] }, - this.dateComparators[i] - )); - } - return optionTags; - } - }, { - key: 'filter', - value: function filter(event) { - var comparator = this.refs.dateFilterComparator.value; - var dateValue = event.target.value; - if (dateValue) { - this.props.filterHandler({ date: new Date(dateValue), comparator: comparator }, _Const2.default.FILTER_TYPE.DATE); - } else { - this.props.filterHandler(null, _Const2.default.FILTER_TYPE.DATE); - } - } - }, { - key: 'cleanFiltered', - value: function cleanFiltered() { - var value = this.setDefaultDate(); - var comparator = this.props.defaultValue ? this.props.defaultValue.comparator : ''; - this.setState(function () { - return { isPlaceholderSelected: value === '' }; - }); - this.refs.dateFilterComparator.value = comparator; - this.refs.inputDate.value = value; - this.props.filterHandler({ date: new Date(value), comparator: comparator }, _Const2.default.FILTER_TYPE.DATE); - } - }, { - key: 'applyFilter', - value: function applyFilter(filterDateObj) { - var date = filterDateObj.date, - comparator = filterDateObj.comparator; - - this.setState(function () { - return { isPlaceholderSelected: date === '' }; - }); - this.refs.dateFilterComparator.value = comparator; - this.refs.inputDate.value = dateParser(date); - this.props.filterHandler({ date: date, comparator: comparator }, _Const2.default.FILTER_TYPE.DATE); - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - var comparator = this.refs.dateFilterComparator.value; - var dateValue = this.refs.inputDate.value; - if (comparator && dateValue) { - this.props.filterHandler({ date: new Date(dateValue), comparator: comparator }, _Const2.default.FILTER_TYPE.DATE); - } - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - defaultValue = _props.defaultValue, - _props$style = _props.style, - date = _props$style.date, - comparator = _props$style.comparator; + var parent = el; + while ((parent = parent.parentNode) && parent && parent.nodeType === 1) { + var style = undefined; + try { + style = getComputedStyle(parent); + } catch (err) {} - return _react2.default.createElement( - 'div', - { className: 'filter date-filter' }, - _react2.default.createElement( - 'select', - { ref: 'dateFilterComparator', - style: comparator, - className: 'date-filter-comparator form-control', - onChange: this.onChangeComparator, - defaultValue: defaultValue ? defaultValue.comparator : '' }, - this.getComparatorOptions() - ), - _react2.default.createElement('input', { ref: 'inputDate', - className: 'filter date-filter-input form-control', - style: date, - type: 'date', - onChange: this.filter, - defaultValue: this.setDefaultDate() }) - ); + if (typeof style === 'undefined' || style === null) { + parents.push(parent); + return parents; } - }]); - return DateFilter; -}(_react.Component); + var _style = style; + var overflow = _style.overflow; + var overflowX = _style.overflowX; + var overflowY = _style.overflowY; -DateFilter.propTypes = { - filterHandler: _propTypes2.default.func.isRequired, - defaultValue: _propTypes2.default.shape({ - date: _propTypes2.default.object, - comparator: _propTypes2.default.oneOf(legalComparators) - }), - style: _propTypes2.default.shape({ - date: _propTypes2.default.oneOfType([_propTypes2.default.object]), - comparator: _propTypes2.default.oneOfType([_propTypes2.default.object]) - }), - /* eslint consistent-return: 0 */ - dateComparators: function dateComparators(props, propName) { - if (!props[propName]) { - return; - } - for (var i = 0; i < props[propName].length; i++) { - var comparatorIsValid = false; - for (var j = 0; j < legalComparators.length; j++) { - if (legalComparators[j] === props[propName][i]) { - comparatorIsValid = true; - break; - } - } - if (!comparatorIsValid) { - return new Error('Date comparator provided is not supported.\n Use only ' + legalComparators); + if (/(auto|scroll)/.test(overflow + overflowY + overflowX)) { + if (position !== 'absolute' || ['relative', 'absolute', 'fixed'].indexOf(style.position) >= 0) { + parents.push(parent); } } - }, - columnName: _propTypes2.default.string -}; - -DateFilter.defaultProps = { - style: { - date: null, - comparator: null } -}; -var _default = DateFilter; -exports.default = _default; -; + parents.push(el.ownerDocument.body); -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; + // If the node is within a frame, account for the parent window scroll + if (el.ownerDocument !== document) { + parents.push(el.ownerDocument.defaultView); } - __REACT_HOT_LOADER__.register(legalComparators, 'legalComparators', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Date.js'); - - __REACT_HOT_LOADER__.register(dateParser, 'dateParser', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Date.js'); - - __REACT_HOT_LOADER__.register(DateFilter, 'DateFilter', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Date.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Date.js'); -}(); - -; - -/***/ }), -/* 367 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + return parents; +} -var _react = __webpack_require__(4); +var uniqueId = (function () { + var id = 0; + return function () { + return ++id; + }; +})(); -var _react2 = _interopRequireDefault(_react); +var zeroPosCache = {}; +var getOrigin = function getOrigin() { + // getBoundingClientRect is unfortunately too accurate. It introduces a pixel or two of + // jitter as the user scrolls that messes with our ability to detect if two positions + // are equivilant or not. We place an element at the top left of the page that will + // get the same jitter, so we can cancel the two out. + var node = zeroElement; + if (!node) { + node = document.createElement('div'); + node.setAttribute('data-tether-id', uniqueId()); + extend(node.style, { + top: 0, + left: 0, + position: 'absolute' + }); -var _propTypes = __webpack_require__(9); + document.body.appendChild(node); -var _propTypes2 = _interopRequireDefault(_propTypes); + zeroElement = node; + } -var _Const = __webpack_require__(22); + var id = node.getAttribute('data-tether-id'); + if (typeof zeroPosCache[id] === 'undefined') { + zeroPosCache[id] = getActualBoundingClientRect(node); -var _Const2 = _interopRequireDefault(_Const); + // Clear the cache when this position call is done + defer(function () { + delete zeroPosCache[id]; + }); + } -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + return zeroPosCache[id]; +}; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +function removeUtilElements() { + if (zeroElement) { + document.body.removeChild(zeroElement); + } + zeroElement = null; +}; -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +function getBounds(el) { + var doc = undefined; + if (el === document) { + doc = document; + el = document.documentElement; + } else { + doc = el.ownerDocument; + } -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + var docEl = doc.documentElement; -var TextFilter = function (_Component) { - _inherits(TextFilter, _Component); + var box = getActualBoundingClientRect(el); - function TextFilter(props) { - _classCallCheck(this, TextFilter); + var origin = getOrigin(); - var _this = _possibleConstructorReturn(this, (TextFilter.__proto__ || Object.getPrototypeOf(TextFilter)).call(this, props)); + box.top -= origin.top; + box.left -= origin.left; - _this.filter = _this.filter.bind(_this); - _this.timeout = null; - _this.state = { - value: _this.props.defaultValue || '' - }; - return _this; + if (typeof box.width === 'undefined') { + box.width = document.body.scrollWidth - box.left - box.right; + } + if (typeof box.height === 'undefined') { + box.height = document.body.scrollHeight - box.top - box.bottom; } - _createClass(TextFilter, [{ - key: 'filter', - value: function filter(event) { - var _this2 = this; - - if (this.timeout) { - clearTimeout(this.timeout); - } - var filterValue = event.target.value; - this.setState(function () { - return { value: filterValue }; - }); - this.timeout = setTimeout(function () { - _this2.props.filterHandler(filterValue, _Const2.default.FILTER_TYPE.TEXT); - }, this.props.delay); - } - }, { - key: 'cleanFiltered', - value: function cleanFiltered() { - var value = this.props.defaultValue ? this.props.defaultValue : ''; - this.setState(function () { - return { value: value }; - }); - this.props.filterHandler(value, _Const2.default.FILTER_TYPE.TEXT); - } - }, { - key: 'applyFilter', - value: function applyFilter(filterText) { - this.setState(function () { - return { value: filterText }; - }); - this.props.filterHandler(filterText, _Const2.default.FILTER_TYPE.TEXT); - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - var defaultValue = this.refs.inputText.value; - if (defaultValue) { - this.props.filterHandler(defaultValue, _Const2.default.FILTER_TYPE.TEXT); - } - } - }, { - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - if (nextProps.defaultValue !== this.props.defaultValue) { - this.applyFilter(nextProps.defaultValue || ''); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - clearTimeout(this.timeout); - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - placeholder = _props.placeholder, - columnName = _props.columnName, - style = _props.style; - - return _react2.default.createElement('input', { ref: 'inputText', - className: 'filter text-filter form-control', - type: 'text', - style: style, - onChange: this.filter, - placeholder: placeholder || 'Enter ' + columnName + '...', - value: this.state.value }); - } - }]); + box.top = box.top - docEl.clientTop; + box.left = box.left - docEl.clientLeft; + box.right = doc.body.clientWidth - box.width - box.left; + box.bottom = doc.body.clientHeight - box.height - box.top; - return TextFilter; -}(_react.Component); + return box; +} -TextFilter.propTypes = { - filterHandler: _propTypes2.default.func.isRequired, - defaultValue: _propTypes2.default.string, - delay: _propTypes2.default.number, - placeholder: _propTypes2.default.string, - columnName: _propTypes2.default.string, - style: _propTypes2.default.oneOfType([_propTypes2.default.object]) -}; +function getOffsetParent(el) { + return el.offsetParent || document.documentElement; +} -TextFilter.defaultProps = { - delay: _Const2.default.FILTER_DELAY -}; +function getScrollBarSize() { + var inner = document.createElement('div'); + inner.style.width = '100%'; + inner.style.height = '200px'; -var _default = TextFilter; -exports.default = _default; -; + var outer = document.createElement('div'); + extend(outer.style, { + position: 'absolute', + top: 0, + left: 0, + pointerEvents: 'none', + visibility: 'hidden', + width: '200px', + height: '150px', + overflow: 'hidden' + }); -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } + outer.appendChild(inner); - __REACT_HOT_LOADER__.register(TextFilter, 'TextFilter', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Text.js'); + document.body.appendChild(outer); - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Text.js'); -}(); + var widthContained = inner.offsetWidth; + outer.style.overflow = 'scroll'; + var widthScroll = inner.offsetWidth; -; + if (widthContained === widthScroll) { + widthScroll = outer.clientWidth; + } -/***/ }), -/* 368 */ -/***/ (function(module, exports, __webpack_require__) { + document.body.removeChild(outer); -"use strict"; + var width = widthContained - widthScroll; + return { width: width, height: width }; +} -Object.defineProperty(exports, "__esModule", { - value: true -}); +function extend() { + var out = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0]; -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + var args = []; -var _react = __webpack_require__(4); + Array.prototype.push.apply(args, arguments); -var _react2 = _interopRequireDefault(_react); + args.slice(1).forEach(function (obj) { + if (obj) { + for (var key in obj) { + if (({}).hasOwnProperty.call(obj, key)) { + out[key] = obj[key]; + } + } + } + }); -var _propTypes = __webpack_require__(9); + return out; +} -var _propTypes2 = _interopRequireDefault(_propTypes); +function removeClass(el, name) { + if (typeof el.classList !== 'undefined') { + name.split(' ').forEach(function (cls) { + if (cls.trim()) { + el.classList.remove(cls); + } + }); + } else { + var regex = new RegExp('(^| )' + name.split(' ').join('|') + '( |$)', 'gi'); + var className = getClassName(el).replace(regex, ' '); + setClassName(el, className); + } +} -var _Const = __webpack_require__(22); +function addClass(el, name) { + if (typeof el.classList !== 'undefined') { + name.split(' ').forEach(function (cls) { + if (cls.trim()) { + el.classList.add(cls); + } + }); + } else { + removeClass(el, name); + var cls = getClassName(el) + (' ' + name); + setClassName(el, cls); + } +} -var _Const2 = _interopRequireDefault(_Const); +function hasClass(el, name) { + if (typeof el.classList !== 'undefined') { + return el.classList.contains(name); + } + var className = getClassName(el); + return new RegExp('(^| )' + name + '( |$)', 'gi').test(className); +} -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function getClassName(el) { + // Can't use just SVGAnimatedString here since nodes within a Frame in IE have + // completely separately SVGAnimatedString base classes + if (el.className instanceof el.ownerDocument.defaultView.SVGAnimatedString) { + return el.className.baseVal; + } + return el.className; +} -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +function setClassName(el, className) { + el.setAttribute('class', className); +} -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +function updateClasses(el, add, all) { + // Of the set of 'all' classes, we need the 'add' classes, and only the + // 'add' classes to be set. + all.forEach(function (cls) { + if (add.indexOf(cls) === -1 && hasClass(el, cls)) { + removeClass(el, cls); + } + }); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + add.forEach(function (cls) { + if (!hasClass(el, cls)) { + addClass(el, cls); + } + }); +} -var RegexFilter = function (_Component) { - _inherits(RegexFilter, _Component); +var deferred = []; - function RegexFilter(props) { - _classCallCheck(this, RegexFilter); +var defer = function defer(fn) { + deferred.push(fn); +}; - var _this = _possibleConstructorReturn(this, (RegexFilter.__proto__ || Object.getPrototypeOf(RegexFilter)).call(this, props)); +var flush = function flush() { + var fn = undefined; + while (fn = deferred.pop()) { + fn(); + } +}; - _this.filter = _this.filter.bind(_this); - _this.timeout = null; - return _this; +var Evented = (function () { + function Evented() { + _classCallCheck(this, Evented); } - _createClass(RegexFilter, [{ - key: 'filter', - value: function filter(event) { - var _this2 = this; + _createClass(Evented, [{ + key: 'on', + value: function on(event, handler, ctx) { + var once = arguments.length <= 3 || arguments[3] === undefined ? false : arguments[3]; - if (this.timeout) { - clearTimeout(this.timeout); + if (typeof this.bindings === 'undefined') { + this.bindings = {}; } - var filterValue = event.target.value; - this.timeout = setTimeout(function () { - _this2.props.filterHandler(filterValue, _Const2.default.FILTER_TYPE.REGEX); - }, this.props.delay); - } - }, { - key: 'cleanFiltered', - value: function cleanFiltered() { - var value = this.props.defaultValue ? this.props.defaultValue : ''; - this.refs.inputText.value = value; - this.props.filterHandler(value, _Const2.default.FILTER_TYPE.TEXT); - } - }, { - key: 'applyFilter', - value: function applyFilter(filterRegx) { - this.refs.inputText.value = filterRegx; - this.props.filterHandler(filterRegx, _Const2.default.FILTER_TYPE.REGEX); - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - var value = this.refs.inputText.value; - if (value) { - this.props.filterHandler(value, _Const2.default.FILTER_TYPE.REGEX); + if (typeof this.bindings[event] === 'undefined') { + this.bindings[event] = []; } + this.bindings[event].push({ handler: handler, ctx: ctx, once: once }); } }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - clearTimeout(this.timeout); + key: 'once', + value: function once(event, handler, ctx) { + this.on(event, handler, ctx, true); } }, { - key: 'render', - value: function render() { - var _props = this.props, - defaultValue = _props.defaultValue, - placeholder = _props.placeholder, - columnName = _props.columnName, - style = _props.style; + key: 'off', + value: function off(event, handler) { + if (typeof this.bindings === 'undefined' || typeof this.bindings[event] === 'undefined') { + return; + } - return _react2.default.createElement('input', { ref: 'inputText', - className: 'filter text-filter form-control', - type: 'text', - style: style, - onChange: this.filter, - placeholder: placeholder || 'Enter Regex for ' + columnName + '...', - defaultValue: defaultValue ? defaultValue : '' }); + if (typeof handler === 'undefined') { + delete this.bindings[event]; + } else { + var i = 0; + while (i < this.bindings[event].length) { + if (this.bindings[event][i].handler === handler) { + this.bindings[event].splice(i, 1); + } else { + ++i; + } + } + } } - }]); - - return RegexFilter; -}(_react.Component); - -RegexFilter.propTypes = { - filterHandler: _propTypes2.default.func.isRequired, - defaultValue: _propTypes2.default.string, - delay: _propTypes2.default.number, - placeholder: _propTypes2.default.string, - columnName: _propTypes2.default.string, - style: _propTypes2.default.oneOfType([_propTypes2.default.object]) -}; - -RegexFilter.defaultProps = { - delay: _Const2.default.FILTER_DELAY -}; + }, { + key: 'trigger', + value: function trigger(event) { + if (typeof this.bindings !== 'undefined' && this.bindings[event]) { + var i = 0; -var _default = RegexFilter; -exports.default = _default; -; + for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } + while (i < this.bindings[event].length) { + var _bindings$event$i = this.bindings[event][i]; + var handler = _bindings$event$i.handler; + var ctx = _bindings$event$i.ctx; + var once = _bindings$event$i.once; - __REACT_HOT_LOADER__.register(RegexFilter, 'RegexFilter', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Regex.js'); + var context = ctx; + if (typeof context === 'undefined') { + context = this; + } - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Regex.js'); -}(); + handler.apply(context, args); -; + if (once) { + this.bindings[event].splice(i, 1); + } else { + ++i; + } + } + } + } + }]); -/***/ }), -/* 369 */ -/***/ (function(module, exports, __webpack_require__) { + return Evented; +})(); -"use strict"; +TetherBase.Utils = { + getActualBoundingClientRect: getActualBoundingClientRect, + getScrollParents: getScrollParents, + getBounds: getBounds, + getOffsetParent: getOffsetParent, + extend: extend, + addClass: addClass, + removeClass: removeClass, + hasClass: hasClass, + updateClasses: updateClasses, + defer: defer, + flush: flush, + uniqueId: uniqueId, + Evented: Evented, + getScrollBarSize: getScrollBarSize, + removeUtilElements: removeUtilElements +}; +exports['default'] = TetherBase; +module.exports = exports['default']; -Object.defineProperty(exports, "__esModule", { - value: true +},{}]},{},[4])(4) }); -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); +/***/ }), +/* 320 */ +/***/ (function(module, exports) { -var _propTypes = __webpack_require__(9); +/** + * lodash (Custom Build) <https://lodash.com/> + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors <https://jquery.org/> + * Released under MIT license <https://lodash.com/license> + * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ -var _propTypes2 = _interopRequireDefault(_propTypes); +/** Used as references for various `Number` constants. */ +var NAN = 0 / 0; -var _classnames = __webpack_require__(29); +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; -var _classnames2 = _interopRequireDefault(_classnames); +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; -var _Const = __webpack_require__(22); +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; -var _Const2 = _interopRequireDefault(_Const); +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +/** Used for built-in method references. */ +var objectProto = Object.prototype; -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; -function optionsEquals(options1, options2) { - var keys = Object.keys(options1); - for (var k in keys) { - if (options1[k] !== options2[k]) { - return false; - } - } - return Object.keys(options1).length === Object.keys(options2).length; +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); } -var SelectFilter = function (_Component) { - _inherits(SelectFilter, _Component); - - function SelectFilter(props) { - _classCallCheck(this, SelectFilter); - - var _this = _possibleConstructorReturn(this, (SelectFilter.__proto__ || Object.getPrototypeOf(SelectFilter)).call(this, props)); - - _this.filter = _this.filter.bind(_this); - _this.state = { - isPlaceholderSelected: _this.props.defaultValue === undefined || !_this.props.options.hasOwnProperty(_this.props.defaultValue) - }; - return _this; - } - - _createClass(SelectFilter, [{ - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - var isPlaceholderSelected = nextProps.defaultValue === undefined || !nextProps.options.hasOwnProperty(nextProps.defaultValue); - this.setState(function () { - return { - isPlaceholderSelected: isPlaceholderSelected - }; - }); - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate(prevProps) { - var needFilter = false; - if (this.props.defaultValue !== prevProps.defaultValue) { - needFilter = true; - } else if (!optionsEquals(this.props.options, prevProps.options)) { - needFilter = true; - } - if (needFilter) { - var value = this.refs.selectInput.value; - if (value) { - this.props.filterHandler(value, _Const2.default.FILTER_TYPE.SELECT); - } - } - } - }, { - key: 'filter', - value: function filter(event) { - var value = event.target.value; - - this.setState(function () { - return { isPlaceholderSelected: value === '' }; - }); - this.props.filterHandler(value, _Const2.default.FILTER_TYPE.SELECT); - } - }, { - key: 'cleanFiltered', - value: function cleanFiltered() { - var value = this.props.defaultValue !== undefined ? this.props.defaultValue : ''; - this.setState(function () { - return { isPlaceholderSelected: value === '' }; - }); - this.refs.selectInput.value = value; - this.props.filterHandler(value, _Const2.default.FILTER_TYPE.SELECT); - } - }, { - key: 'applyFilter', - value: function applyFilter(filterOption) { - filterOption = filterOption + ''; - this.setState(function () { - return { isPlaceholderSelected: filterOption === '' }; - }); - this.refs.selectInput.value = filterOption; - this.props.filterHandler(filterOption, _Const2.default.FILTER_TYPE.SELECT); - } - }, { - key: 'getOptions', - value: function getOptions() { - var optionTags = []; - var _props = this.props, - options = _props.options, - placeholder = _props.placeholder, - columnName = _props.columnName, - selectText = _props.selectText, - withoutEmptyOption = _props.withoutEmptyOption; - - var selectTextValue = selectText !== undefined ? selectText : 'Select'; - if (!withoutEmptyOption) { - optionTags.push(_react2.default.createElement( - 'option', - { key: '-1', value: '' }, - placeholder || selectTextValue + ' ' + columnName + '...' - )); - } - Object.keys(options).map(function (key) { - optionTags.push(_react2.default.createElement( - 'option', - { key: key, value: key }, - options[key] + '' - )); - }); - return optionTags; - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - var value = this.refs.selectInput.value; - if (value) { - this.props.filterHandler(value, _Const2.default.FILTER_TYPE.SELECT); - } - } - }, { - key: 'render', - value: function render() { - var selectClass = (0, _classnames2.default)('filter', 'select-filter', 'form-control', { 'placeholder-selected': this.state.isPlaceholderSelected }); - - return _react2.default.createElement( - 'select', - { ref: 'selectInput', - style: this.props.style, - className: selectClass, - onChange: this.filter, - defaultValue: this.props.defaultValue !== undefined ? this.props.defaultValue : '' }, - this.getOptions() - ); - } - }]); - - return SelectFilter; -}(_react.Component); - -SelectFilter.propTypes = { - filterHandler: _propTypes2.default.func.isRequired, - options: _propTypes2.default.object.isRequired, - placeholder: _propTypes2.default.string, - columnName: _propTypes2.default.string, - style: _propTypes2.default.oneOfType([_propTypes2.default.object]) -}; +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} -var _default = SelectFilter; -exports.default = _default; -; +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); +} - __REACT_HOT_LOADER__.register(optionsEquals, 'optionsEquals', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Select.js'); - - __REACT_HOT_LOADER__.register(SelectFilter, 'SelectFilter', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Select.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Select.js'); -}(); +module.exports = toNumber; -; /***/ }), -/* 370 */ +/* 321 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _classnames = __webpack_require__(29); +var _CSSTransitionGroup = __webpack_require__(322); -var _classnames2 = _interopRequireDefault(_classnames); +var _CSSTransitionGroup2 = _interopRequireDefault(_CSSTransitionGroup); -var _Const = __webpack_require__(22); +var _TransitionGroup = __webpack_require__(151); -var _Const2 = _interopRequireDefault(_Const); +var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var legalComparators = ['=', '>', '>=', '<', '<=', '!=']; - -var NumberFilter = function (_Component) { - _inherits(NumberFilter, _Component); - - function NumberFilter(props) { - _classCallCheck(this, NumberFilter); - - var _this = _possibleConstructorReturn(this, (NumberFilter.__proto__ || Object.getPrototypeOf(NumberFilter)).call(this, props)); - - _this.numberComparators = _this.props.numberComparators || legalComparators; - _this.timeout = null; - _this.state = { - isPlaceholderSelected: _this.props.defaultValue === undefined || _this.props.defaultValue.number === undefined || _this.props.options && _this.props.options.indexOf(_this.props.defaultValue.number) === -1 - }; - _this.onChangeNumber = _this.onChangeNumber.bind(_this); - _this.onChangeNumberSet = _this.onChangeNumberSet.bind(_this); - _this.onChangeComparator = _this.onChangeComparator.bind(_this); - return _this; - } - - _createClass(NumberFilter, [{ - key: 'onChangeNumber', - value: function onChangeNumber(event) { - var _this2 = this; - - var comparator = this.refs.numberFilterComparator.value; - if (comparator === '') { - return; - } - if (this.timeout) { - clearTimeout(this.timeout); - } - var filterValue = event.target.value; - this.timeout = setTimeout(function () { - _this2.props.filterHandler({ number: filterValue, comparator: comparator }, _Const2.default.FILTER_TYPE.NUMBER); - }, this.props.delay); - } - }, { - key: 'onChangeNumberSet', - value: function onChangeNumberSet(event) { - var comparator = this.refs.numberFilterComparator.value; - var value = event.target.value; - - this.setState(function () { - return { isPlaceholderSelected: value === '' }; - }); - if (comparator === '') { - return; - } - this.props.filterHandler({ number: value, comparator: comparator }, _Const2.default.FILTER_TYPE.NUMBER); - } - }, { - key: 'onChangeComparator', - value: function onChangeComparator(event) { - var value = this.refs.numberFilter.value; - var comparator = event.target.value; - if (value === '') { - return; - } - this.props.filterHandler({ number: value, comparator: comparator }, _Const2.default.FILTER_TYPE.NUMBER); - } - }, { - key: 'cleanFiltered', - value: function cleanFiltered() { - var value = this.props.defaultValue ? this.props.defaultValue.number : ''; - var comparator = this.props.defaultValue ? this.props.defaultValue.comparator : ''; - this.setState(function () { - return { isPlaceholderSelected: value === '' }; - }); - this.refs.numberFilterComparator.value = comparator; - this.refs.numberFilter.value = value; - this.props.filterHandler({ number: value, comparator: comparator }, _Const2.default.FILTER_TYPE.NUMBER); - } - }, { - key: 'applyFilter', - value: function applyFilter(filterObj) { - var number = filterObj.number, - comparator = filterObj.comparator; - - this.setState(function () { - return { isPlaceholderSelected: number === '' }; - }); - this.refs.numberFilterComparator.value = comparator; - this.refs.numberFilter.value = number; - this.props.filterHandler({ number: number, comparator: comparator }, _Const2.default.FILTER_TYPE.NUMBER); - } - }, { - key: 'getComparatorOptions', - value: function getComparatorOptions() { - var optionTags = []; - var withoutEmptyComparatorOption = this.props.withoutEmptyComparatorOption; - - if (!withoutEmptyComparatorOption) { - optionTags.push(_react2.default.createElement('option', { key: '-1' })); - } - for (var i = 0; i < this.numberComparators.length; i++) { - optionTags.push(_react2.default.createElement( - 'option', - { key: i, value: this.numberComparators[i] }, - this.numberComparators[i] - )); - } - return optionTags; - } - }, { - key: 'getNumberOptions', - value: function getNumberOptions() { - var optionTags = []; - var _props = this.props, - options = _props.options, - withoutEmptyNumberOption = _props.withoutEmptyNumberOption; - - if (!withoutEmptyNumberOption) { - optionTags.push(_react2.default.createElement( - 'option', - { key: '-1', value: '' }, - this.props.placeholder || 'Select ' + this.props.columnName + '...' - )); - } - for (var i = 0; i < options.length; i++) { - optionTags.push(_react2.default.createElement( - 'option', - { key: i, value: options[i] }, - options[i] - )); - } - return optionTags; - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - var comparator = this.refs.numberFilterComparator.value; - var number = this.refs.numberFilter.value; - if (comparator && number) { - this.props.filterHandler({ number: number, comparator: comparator }, _Const2.default.FILTER_TYPE.NUMBER); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - clearTimeout(this.timeout); - } - }, { - key: 'render', - value: function render() { - var selectClass = (0, _classnames2.default)('select-filter', 'number-filter-input', 'form-control', { 'placeholder-selected': this.state.isPlaceholderSelected }); - - return _react2.default.createElement( - 'div', - { className: 'filter number-filter' }, - _react2.default.createElement( - 'select', - { ref: 'numberFilterComparator', - style: this.props.style.comparator, - className: 'number-filter-comparator form-control', - onChange: this.onChangeComparator, - defaultValue: this.props.defaultValue ? this.props.defaultValue.comparator : '' }, - this.getComparatorOptions() - ), - this.props.options ? _react2.default.createElement( - 'select', - { ref: 'numberFilter', - className: selectClass, - onChange: this.onChangeNumberSet, - defaultValue: this.props.defaultValue ? this.props.defaultValue.number : '' }, - this.getNumberOptions() - ) : _react2.default.createElement('input', { ref: 'numberFilter', - type: 'number', - style: this.props.style.number, - className: 'number-filter-input form-control', - placeholder: this.props.placeholder || 'Enter ' + this.props.columnName + '...', - onChange: this.onChangeNumber, - defaultValue: this.props.defaultValue ? this.props.defaultValue.number : '' }) - ); - } - }]); - - return NumberFilter; -}(_react.Component); - -NumberFilter.propTypes = { - filterHandler: _propTypes2.default.func.isRequired, - options: _propTypes2.default.arrayOf(_propTypes2.default.number), - defaultValue: _propTypes2.default.shape({ - number: _propTypes2.default.number, - comparator: _propTypes2.default.oneOf(legalComparators) - }), - style: _propTypes2.default.shape({ - number: _propTypes2.default.oneOfType([_propTypes2.default.object]), - comparator: _propTypes2.default.oneOfType([_propTypes2.default.object]) - }), - delay: _propTypes2.default.number, - /* eslint consistent-return: 0 */ - numberComparators: function numberComparators(props, propName) { - if (!props[propName]) { - return; - } - for (var i = 0; i < props[propName].length; i++) { - var comparatorIsValid = false; - for (var j = 0; j < legalComparators.length; j++) { - if (legalComparators[j] === props[propName][i]) { - comparatorIsValid = true; - break; - } - } - if (!comparatorIsValid) { - return new Error('Number comparator provided is not supported.\n Use only ' + legalComparators); - } - } - }, - placeholder: _propTypes2.default.string, - columnName: _propTypes2.default.string, - withoutEmptyComparatorOption: _propTypes2.default.bool, - withoutEmptyNumberOption: _propTypes2.default.bool -}; - -NumberFilter.defaultProps = { - delay: _Const2.default.FILTER_DELAY, - withoutEmptyComparatorOption: false, - withoutEmptyNumberOption: false, - style: { - number: null, - comparator: null - } +module.exports = { + TransitionGroup: _TransitionGroup2.default, + CSSTransitionGroup: _CSSTransitionGroup2.default }; -var _default = NumberFilter; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(legalComparators, 'legalComparators', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Number.js'); - - __REACT_HOT_LOADER__.register(NumberFilter, 'NumberFilter', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Number.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filters/Number.js'); -}(); - -; - /***/ }), -/* 371 */ +/* 322 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/* WEBPACK VAR INJECTION */(function(process) { +exports.__esModule = true; -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _propTypes = __webpack_require__(9); +var _propTypes = __webpack_require__(40); var _propTypes2 = _interopRequireDefault(_propTypes); -var _reactDom = __webpack_require__(28); - -var _reactDom2 = _interopRequireDefault(_reactDom); - -var _Const = __webpack_require__(22); +var _TransitionGroup = __webpack_require__(151); -var _Const2 = _interopRequireDefault(_Const); - -var _classnames = __webpack_require__(29); - -var _classnames2 = _interopRequireDefault(_classnames); - -var _SelectRowHeaderColumn = __webpack_require__(372); +var _TransitionGroup2 = _interopRequireDefault(_TransitionGroup); -var _SelectRowHeaderColumn2 = _interopRequireDefault(_SelectRowHeaderColumn); +var _CSSTransitionGroupChild = __webpack_require__(326); -var _ExpandRowHeaderColumn = __webpack_require__(373); +var _CSSTransitionGroupChild2 = _interopRequireDefault(_CSSTransitionGroupChild); -var _ExpandRowHeaderColumn2 = _interopRequireDefault(_ExpandRowHeaderColumn); +var _PropTypes = __webpack_require__(153); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } } - function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -var Checkbox = function (_Component) { - _inherits(Checkbox, _Component); - - function Checkbox() { - _classCallCheck(this, Checkbox); - - return _possibleConstructorReturn(this, (Checkbox.__proto__ || Object.getPrototypeOf(Checkbox)).apply(this, arguments)); - } - - _createClass(Checkbox, [{ - key: 'componentDidMount', - value: function componentDidMount() { - this.update(this.props.checked); - } - }, { - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(props) { - this.update(props.checked); - } - }, { - key: 'update', - value: function update(checked) { - _reactDom2.default.findDOMNode(this).indeterminate = checked === 'indeterminate'; - } - }, { - key: 'render', - value: function render() { - return _react2.default.createElement('input', { className: 'react-bs-select-all', - type: 'checkbox', - checked: this.props.checked, - onChange: this.props.onChange }); - } - }]); - - return Checkbox; -}(_react.Component); +var propTypes = { + transitionName: _PropTypes.nameShape.isRequired, -function getSortOrder(sortList, field, enableSort) { - if (!enableSort) return undefined; - var result = sortList.filter(function (sortObj) { - return sortObj.sortField === field; - }); - if (result.length > 0) { - return result[0].order; - } else { - return undefined; - } -} + transitionAppear: _propTypes2.default.bool, + transitionEnter: _propTypes2.default.bool, + transitionLeave: _propTypes2.default.bool, + transitionAppearTimeout: (0, _PropTypes.transitionTimeout)('Appear'), + transitionEnterTimeout: (0, _PropTypes.transitionTimeout)('Enter'), + transitionLeaveTimeout: (0, _PropTypes.transitionTimeout)('Leave') +}; -var TableHeader = function (_Component2) { - _inherits(TableHeader, _Component2); +var defaultProps = { + transitionAppear: false, + transitionEnter: true, + transitionLeave: true +}; - function TableHeader() { - var _ref; +var CSSTransitionGroup = function (_React$Component) { + _inherits(CSSTransitionGroup, _React$Component); - var _temp, _this2, _ret; + function CSSTransitionGroup() { + var _temp, _this, _ret; - _classCallCheck(this, TableHeader); + _classCallCheck(this, CSSTransitionGroup); for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { args[_key] = arguments[_key]; } - return _ret = (_temp = (_this2 = _possibleConstructorReturn(this, (_ref = TableHeader.__proto__ || Object.getPrototypeOf(TableHeader)).call.apply(_ref, [this].concat(args))), _this2), _this2.getHeaderColGrouop = function () { - var _this3; - - return (_this3 = _this2).__getHeaderColGrouop__REACT_HOT_LOADER__.apply(_this3, arguments); - }, _temp), _possibleConstructorReturn(_this2, _ret); + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this._wrapChild = function (child) { + return _react2.default.createElement(_CSSTransitionGroupChild2.default, { + name: _this.props.transitionName, + appear: _this.props.transitionAppear, + enter: _this.props.transitionEnter, + leave: _this.props.transitionLeave, + appearTimeout: _this.props.transitionAppearTimeout, + enterTimeout: _this.props.transitionEnterTimeout, + leaveTimeout: _this.props.transitionLeaveTimeout + }, child); + }, _temp), _possibleConstructorReturn(_this, _ret); } - _createClass(TableHeader, [{ - key: 'render', - value: function render() { - var containerClasses = (0, _classnames2.default)('react-bs-container-header', 'table-header-wrapper', this.props.headerContainerClass); - var tableClasses = (0, _classnames2.default)('table', 'table-hover', { - 'table-bordered': this.props.bordered, - 'table-condensed': this.props.condensed - }, this.props.tableHeaderClass); - - var rowCount = Math.max.apply(Math, _toConsumableArray(_react2.default.Children.map(this.props.children, function (elm) { - return elm && elm.props.row ? Number(elm.props.row) : 0; - }))); - - var rows = []; - var rowKey = 0; - - rows[0] = []; - rows[0].push([this.props.expandColumnVisible && this.props.expandColumnBeforeSelectColumn && _react2.default.createElement(_ExpandRowHeaderColumn2.default, { rowCount: rowCount + 1 })], [this.renderSelectRowHeader(rowCount + 1, rowKey++)], [this.props.expandColumnVisible && !this.props.expandColumnBeforeSelectColumn && _react2.default.createElement(_ExpandRowHeaderColumn2.default, { rowCount: rowCount + 1 })]); - var _props = this.props, - sortIndicator = _props.sortIndicator, - sortList = _props.sortList, - onSort = _props.onSort, - reset = _props.reset, - version = _props.version; - - - _react2.default.Children.forEach(this.props.children, function (elm) { - if (elm === null || elm === undefined) { - // Skip null or undefined elements. - return; - } - var _elm$props = elm.props, - dataField = _elm$props.dataField, - dataSort = _elm$props.dataSort; - - var sort = getSortOrder(sortList, dataField, dataSort); - var rowIndex = elm.props.row ? Number(elm.props.row) : 0; - var rowSpan = elm.props.rowSpan ? Number(elm.props.rowSpan) : 1; - if (rows[rowIndex] === undefined) { - rows[rowIndex] = []; - } - if (rowSpan + rowIndex === rowCount + 1) { - rows[rowIndex].push(_react2.default.cloneElement(elm, { reset: reset, key: rowKey++, onSort: onSort, sort: sort, sortIndicator: sortIndicator, isOnlyHead: false, version: version })); - } else { - rows[rowIndex].push(_react2.default.cloneElement(elm, { key: rowKey++, isOnlyHead: true, version: version })); - } - }); + // We need to provide this childFactory so that + // ReactCSSTransitionGroupChild can receive updates to name, enter, and + // leave while it is leaving. - var trs = rows.map(function (row, indexRow) { - return _react2.default.createElement( - 'tr', - { key: indexRow }, - row - ); - }); - return _react2.default.createElement( - 'div', - { ref: 'container', className: containerClasses, style: this.props.style }, - _react2.default.createElement( - 'table', - { className: tableClasses }, - _react2.default.cloneElement(this.props.colGroups, { ref: 'headerGrp' }), - _react2.default.createElement( - 'thead', - { ref: 'header' }, - trs - ) - ) - ); - } - }, { - key: '__getHeaderColGrouop__REACT_HOT_LOADER__', - value: function __getHeaderColGrouop__REACT_HOT_LOADER__() { - return this.refs.headerGrp.childNodes; - } - }, { - key: 'renderSelectRowHeader', - value: function renderSelectRowHeader(rowCount, rowKey) { - if (this.props.hideSelectColumn) { - return null; - } else if (this.props.customComponent) { - var CustomComponent = this.props.customComponent; - return _react2.default.createElement( - _SelectRowHeaderColumn2.default, - { key: rowKey, rowCount: rowCount }, - _react2.default.createElement(CustomComponent, { type: 'checkbox', checked: this.props.isSelectAll, - indeterminate: this.props.isSelectAll === 'indeterminate', disabled: false, - onChange: this.props.onSelectAllRow, rowIndex: 'Header' }) - ); - } else if (this.props.rowSelectType === _Const2.default.ROW_SELECT_SINGLE) { - return _react2.default.createElement(_SelectRowHeaderColumn2.default, { key: rowKey, rowCount: rowCount }); - } else if (this.props.rowSelectType === _Const2.default.ROW_SELECT_MULTI) { - return _react2.default.createElement( - _SelectRowHeaderColumn2.default, - { key: rowKey, rowCount: rowCount }, - _react2.default.createElement(Checkbox, { - onChange: this.props.onSelectAllRow, - checked: this.props.isSelectAll }) - ); - } else { - return null; - } - } - }]); + CSSTransitionGroup.prototype.render = function render() { + return _react2.default.createElement(_TransitionGroup2.default, _extends({}, this.props, { childFactory: this._wrapChild })); + }; - return TableHeader; -}(_react.Component); + return CSSTransitionGroup; +}(_react2.default.Component); -TableHeader.propTypes = { - headerContainerClass: _propTypes2.default.string, - tableHeaderClass: _propTypes2.default.string, - style: _propTypes2.default.object, - rowSelectType: _propTypes2.default.string, - onSort: _propTypes2.default.func, - onSelectAllRow: _propTypes2.default.func, - sortList: _propTypes2.default.array, - hideSelectColumn: _propTypes2.default.bool, - bordered: _propTypes2.default.bool, - condensed: _propTypes2.default.bool, - isFiltered: _propTypes2.default.bool, - isSelectAll: _propTypes2.default.oneOf([true, 'indeterminate', false]), - sortIndicator: _propTypes2.default.bool, - customComponent: _propTypes2.default.func, - colGroups: _propTypes2.default.element, - reset: _propTypes2.default.bool, - expandColumnVisible: _propTypes2.default.bool, - expandColumnComponent: _propTypes2.default.func, - expandColumnBeforeSelectColumn: _propTypes2.default.bool, - version: _propTypes2.default.string -}; - -var _default = TableHeader; -exports.default = _default; -; +CSSTransitionGroup.displayName = 'CSSTransitionGroup'; -var _temp2 = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - __REACT_HOT_LOADER__.register(Checkbox, 'Checkbox', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableHeader.js'); +CSSTransitionGroup.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; +CSSTransitionGroup.defaultProps = defaultProps; - __REACT_HOT_LOADER__.register(getSortOrder, 'getSortOrder', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableHeader.js'); +exports.default = CSSTransitionGroup; +module.exports = exports['default']; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - __REACT_HOT_LOADER__.register(TableHeader, 'TableHeader', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableHeader.js'); +/***/ }), +/* 323 */ +/***/ (function(module, exports) { - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableHeader.js'); -}(); + +module.exports = function chain(){ + var len = arguments.length + var args = []; + + for (var i = 0; i < len; i++) + args[i] = arguments[i] + + args = args.filter(function(fn){ return fn != null }) + + if (args.length === 0) return undefined + if (args.length === 1) return args[0] + + return args.reduce(function(current, next){ + return function chainedFunction() { + current.apply(this, arguments); + next.apply(this, arguments); + }; + }) +} -; /***/ }), -/* 372 */ +/* 324 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/* WEBPACK VAR INJECTION */(function(process) {/** + * Copyright 2014-2015, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + */ -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - -var SelectRowHeaderColumn = function (_Component) { - _inherits(SelectRowHeaderColumn, _Component); - function SelectRowHeaderColumn() { - _classCallCheck(this, SelectRowHeaderColumn); +/** + * Similar to invariant but only logs a warning if the condition is not met. + * This can be used to log issues in development environments in critical + * paths. Removing the logging code for production environments will keep the + * same logic and follow the same code paths. + */ - return _possibleConstructorReturn(this, (SelectRowHeaderColumn.__proto__ || Object.getPrototypeOf(SelectRowHeaderColumn)).apply(this, arguments)); - } +var warning = function() {}; - _createClass(SelectRowHeaderColumn, [{ - key: 'render', - value: function render() { - return _react2.default.createElement( - 'th', - { rowSpan: this.props.rowCount, style: { textAlign: 'center' }, - 'data-is-only-head': false }, - this.props.children +if (process.env.NODE_ENV !== 'production') { + warning = function(condition, format, args) { + var len = arguments.length; + args = new Array(len > 2 ? len - 2 : 0); + for (var key = 2; key < len; key++) { + args[key - 2] = arguments[key]; + } + if (format === undefined) { + throw new Error( + '`warning(condition, format, ...args)` requires a warning ' + + 'message argument' ); } - }]); - - return SelectRowHeaderColumn; -}(_react.Component); -SelectRowHeaderColumn.propTypes = { - children: _propTypes2.default.node, - rowCount: _propTypes2.default.number -}; -var _default = SelectRowHeaderColumn; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } + if (format.length < 10 || (/^[s\W]*$/).test(format)) { + throw new Error( + 'The warning format should be able to uniquely identify this ' + + 'warning. Please, use a more descriptive format than: ' + format + ); + } - __REACT_HOT_LOADER__.register(SelectRowHeaderColumn, 'SelectRowHeaderColumn', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/SelectRowHeaderColumn.js'); + if (!condition) { + var argIndex = 0; + var message = 'Warning: ' + + format.replace(/%s/g, function() { + return args[argIndex++]; + }); + if (typeof console !== 'undefined') { + console.error(message); + } + try { + // This error was thrown as a convenience so that you can use this stack + // to find the callsite that caused this warning to fire. + throw new Error(message); + } catch(x) {} + } + }; +} - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/SelectRowHeaderColumn.js'); -}(); +module.exports = warning; -; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 373 */ +/* 325 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +exports.__esModule = true; +exports.getChildMapping = getChildMapping; +exports.mergeChildMappings = mergeChildMappings; -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +var _react = __webpack_require__(6); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +/** + * Given `this.props.children`, return an object mapping key to child. + * + * @param {*} children `this.props.children` + * @return {object} Mapping of key to child + */ +function getChildMapping(children) { + if (!children) { + return children; + } + var result = {}; + _react.Children.map(children, function (child) { + return child; + }).forEach(function (child) { + result[child.key] = child; + }); + return result; +} -var ExpandRowHeaderColumn = function (_Component) { - _inherits(ExpandRowHeaderColumn, _Component); +/** + * When you're adding or removing children some may be added or removed in the + * same render pass. We want to show *both* since we want to simultaneously + * animate elements in and out. This function takes a previous set of keys + * and a new set of keys and merges them with its best guess of the correct + * ordering. In the future we may expose some of the utilities in + * ReactMultiChild to make this easy, but for now React itself does not + * directly have this concept of the union of prevChildren and nextChildren + * so we implement it here. + * + * @param {object} prev prev children as returned from + * `ReactTransitionChildMapping.getChildMapping()`. + * @param {object} next next children as returned from + * `ReactTransitionChildMapping.getChildMapping()`. + * @return {object} a key set that contains all keys in `prev` and all keys + * in `next` in a reasonable order. + */ +function mergeChildMappings(prev, next) { + prev = prev || {}; + next = next || {}; - function ExpandRowHeaderColumn() { - _classCallCheck(this, ExpandRowHeaderColumn); + function getValueForKey(key) { + if (next.hasOwnProperty(key)) { + return next[key]; + } - return _possibleConstructorReturn(this, (ExpandRowHeaderColumn.__proto__ || Object.getPrototypeOf(ExpandRowHeaderColumn)).apply(this, arguments)); + return prev[key]; } - _createClass(ExpandRowHeaderColumn, [{ - key: 'render', - value: function render() { - return _react2.default.createElement( - 'th', - { rowSpan: this.props.rowCount, style: { textAlign: 'center' }, - className: 'react-bs-table-expand-cell', - 'data-is-only-head': false }, - this.props.children - ); - } - }]); - - return ExpandRowHeaderColumn; -}(_react.Component); + // For each key of `next`, the list of keys to insert before that key in + // the combined list + var nextKeysPending = {}; -ExpandRowHeaderColumn.propTypes = { - children: _propTypes2.default.node, - rowCount: _propTypes2.default.number -}; -var _default = ExpandRowHeaderColumn; -exports.default = _default; -; + var pendingKeys = []; + for (var prevKey in prev) { + if (next.hasOwnProperty(prevKey)) { + if (pendingKeys.length) { + nextKeysPending[prevKey] = pendingKeys; + pendingKeys = []; + } + } else { + pendingKeys.push(prevKey); + } + } -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; + var i = void 0; + var childMapping = {}; + for (var nextKey in next) { + if (nextKeysPending.hasOwnProperty(nextKey)) { + for (i = 0; i < nextKeysPending[nextKey].length; i++) { + var pendingNextKey = nextKeysPending[nextKey][i]; + childMapping[nextKeysPending[nextKey][i]] = getValueForKey(pendingNextKey); + } + } + childMapping[nextKey] = getValueForKey(nextKey); } - __REACT_HOT_LOADER__.register(ExpandRowHeaderColumn, 'ExpandRowHeaderColumn', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/ExpandRowHeaderColumn.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/ExpandRowHeaderColumn.js'); -}(); + // Finally, add the keys which didn't appear before any key in `next` + for (i = 0; i < pendingKeys.length; i++) { + childMapping[pendingKeys[i]] = getValueForKey(pendingKeys[i]); + } -; + return childMapping; +} /***/ }), -/* 374 */ +/* 326 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; +/* WEBPACK VAR INJECTION */(function(process) { - -Object.defineProperty(exports, "__esModule", { - value: true -}); +exports.__esModule = true; var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _util = __webpack_require__(68); - -var _util2 = _interopRequireDefault(_util); +var _addClass = __webpack_require__(327); -var _Const = __webpack_require__(22); +var _addClass2 = _interopRequireDefault(_addClass); -var _Const2 = _interopRequireDefault(_Const); +var _removeClass = __webpack_require__(329); -var _TableRow = __webpack_require__(375); +var _removeClass2 = _interopRequireDefault(_removeClass); -var _TableRow2 = _interopRequireDefault(_TableRow); +var _requestAnimationFrame = __webpack_require__(330); -var _TableColumn = __webpack_require__(376); +var _requestAnimationFrame2 = _interopRequireDefault(_requestAnimationFrame); -var _TableColumn2 = _interopRequireDefault(_TableColumn); +var _properties = __webpack_require__(331); -var _TableEditColumn = __webpack_require__(377); +var _react = __webpack_require__(6); -var _TableEditColumn2 = _interopRequireDefault(_TableEditColumn); +var _react2 = _interopRequireDefault(_react); -var _classnames = __webpack_require__(29); +var _propTypes = __webpack_require__(40); -var _classnames2 = _interopRequireDefault(_classnames); +var _propTypes2 = _interopRequireDefault(_propTypes); -var _ExpandComponent = __webpack_require__(378); +var _reactDom = __webpack_require__(76); -var _ExpandComponent2 = _interopRequireDefault(_ExpandComponent); +var _PropTypes = __webpack_require__(153); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -59397,650 +49369,199 @@ function _possibleConstructorReturn(self, call) { if (!self) { throw new Referen function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -var TableBody = function (_Component) { - _inherits(TableBody, _Component); - - function TableBody(props) { - _classCallCheck(this, TableBody); - - var _this = _possibleConstructorReturn(this, (TableBody.__proto__ || Object.getPrototypeOf(TableBody)).call(this, props)); - - _this.handleCellKeyDown = function () { - return _this.__handleCellKeyDown__REACT_HOT_LOADER__.apply(_this, arguments); - }; - - _this.handleRowMouseOut = function () { - return _this.__handleRowMouseOut__REACT_HOT_LOADER__.apply(_this, arguments); - }; - - _this.handleRowMouseOver = function () { - return _this.__handleRowMouseOver__REACT_HOT_LOADER__.apply(_this, arguments); - }; - - _this.handleRowClick = function () { - return _this.__handleRowClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; - - _this.handleRowDoubleClick = function () { - return _this.__handleRowDoubleClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; - - _this.handleSelectRow = function () { - return _this.__handleSelectRow__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var events = []; +if (_properties.transitionEnd) events.push(_properties.transitionEnd); +if (_properties.animationEnd) events.push(_properties.animationEnd); - _this.handleSelectRowColumChange = function () { - return _this.__handleSelectRowColumChange__REACT_HOT_LOADER__.apply(_this, arguments); - }; +function addEndListener(node, listener) { + if (events.length) { + events.forEach(function (e) { + return node.addEventListener(e, listener, false); + }); + } else { + setTimeout(listener, 0); + } - _this.handleClickCell = function () { - return _this.__handleClickCell__REACT_HOT_LOADER__.apply(_this, arguments); - }; + return function () { + if (!events.length) return; + events.forEach(function (e) { + return node.removeEventListener(e, listener, false); + }); + }; +} - _this.handleEditCell = function () { - return _this.__handleEditCell__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var propTypes = { + children: _propTypes2.default.node, + name: _PropTypes.nameShape.isRequired, - _this.nextEditableCell = function () { - return _this.__nextEditableCell__REACT_HOT_LOADER__.apply(_this, arguments); - }; + // Once we require timeouts to be specified, we can remove the + // boolean flags (appear etc.) and just accept a number + // or a bool for the timeout flags (appearTimeout etc.) + appear: _propTypes2.default.bool, + enter: _propTypes2.default.bool, + leave: _propTypes2.default.bool, + appearTimeout: _propTypes2.default.number, + enterTimeout: _propTypes2.default.number, + leaveTimeout: _propTypes2.default.number +}; - _this.handleCompleteEditCell = function () { - return _this.__handleCompleteEditCell__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var CSSTransitionGroupChild = function (_React$Component) { + _inherits(CSSTransitionGroupChild, _React$Component); - _this.cancelEditCell = function () { - return _this.__cancelEditCell__REACT_HOT_LOADER__.apply(_this, arguments); - }; + function CSSTransitionGroupChild() { + var _temp, _this, _ret; - _this.handleClickonSelectColumn = function () { - return _this.__handleClickonSelectColumn__REACT_HOT_LOADER__.apply(_this, arguments); - }; + _classCallCheck(this, CSSTransitionGroupChild); - _this.getHeaderColGrouop = function () { - return _this.__getHeaderColGrouop__REACT_HOT_LOADER__.apply(_this, arguments); - }; + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } - _this.state = { - currEditCell: null - }; - return _this; + return _ret = (_temp = (_this = _possibleConstructorReturn(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.componentWillAppear = function (done) { + if (_this.props.appear) { + _this.transition('appear', done, _this.props.appearTimeout); + } else { + done(); + } + }, _this.componentWillEnter = function (done) { + if (_this.props.enter) { + _this.transition('enter', done, _this.props.enterTimeout); + } else { + done(); + } + }, _this.componentWillLeave = function (done) { + if (_this.props.leave) { + _this.transition('leave', done, _this.props.leaveTimeout); + } else { + done(); + } + }, _temp), _possibleConstructorReturn(_this, _ret); } - _createClass(TableBody, [{ - key: 'render', - value: function render() { - var _props = this.props, - cellEdit = _props.cellEdit, - beforeShowError = _props.beforeShowError, - x = _props.x, - y = _props.y, - keyBoardNav = _props.keyBoardNav, - trStyle = _props.trStyle, - version = _props.version; - - var tableClasses = (0, _classnames2.default)('table', { - 'table-striped': this.props.striped, - 'table-bordered': this.props.bordered, - 'table-hover': this.props.hover, - 'table-condensed': this.props.condensed - }, this.props.tableBodyClass); - - var noneditableRows = cellEdit.nonEditableRows && cellEdit.nonEditableRows() || []; - var unselectable = this.props.selectRow.unselectable || []; - var isSelectRowDefined = this._isSelectRowDefined(); - var tableHeader = _util2.default.renderColGroup(this.props.columns, this.props.selectRow, this.props.expandColumnOptions, version); - var inputType = this.props.selectRow.mode === _Const2.default.ROW_SELECT_SINGLE ? 'radio' : 'checkbox'; - var CustomComponent = this.props.selectRow.customComponent; - var enableKeyBoardNav = keyBoardNav === true || (typeof keyBoardNav === 'undefined' ? 'undefined' : _typeof(keyBoardNav)) === 'object'; - var customEditAndNavStyle = (typeof keyBoardNav === 'undefined' ? 'undefined' : _typeof(keyBoardNav)) === 'object' ? keyBoardNav.customStyleOnEditCell : null; - var customNavStyle = (typeof keyBoardNav === 'undefined' ? 'undefined' : _typeof(keyBoardNav)) === 'object' ? keyBoardNav.customStyle : null; - var ExpandColumnCustomComponent = this.props.expandColumnOptions.expandColumnComponent; - var expandColSpan = this.props.columns.filter(function (col) { - return col && !col.hidden; - }).length; - if (isSelectRowDefined && !this.props.selectRow.hideSelectColumn) { - expandColSpan += 1; - } - var tabIndex = 1; - if (this.props.expandColumnOptions.expandColumnVisible) { - expandColSpan += 1; - } - - var tableRows = this.props.data.map(function (data, r) { - var tableColumns = this.props.columns.filter(function (_) { - return _ != null; - }).map(function (column, i) { - var fieldValue = data[column.name]; - var isFocusCell = r === y && i === x; - if (column.name !== this.props.keyField && // Key field can't be edit - column.editable && // column is editable? default is true, user can set it false - column.editable.readOnly !== true && this.state.currEditCell !== null && this.state.currEditCell.rid === r && this.state.currEditCell.cid === i && noneditableRows.indexOf(data[this.props.keyField]) === -1) { - var editable = column.editable; - var format = column.format ? function (value) { - return column.format(value, data, column.formatExtraData, r).replace(/<.*?>/g, ''); - } : false; - if (_util2.default.isFunction(column.editable)) { - editable = column.editable(fieldValue, data, r, i); - } - - return _react2.default.createElement(_TableEditColumn2.default, { - completeEdit: this.handleCompleteEditCell - // add by bluespring for column editor customize - , editable: editable, - attrs: column.editAttrs, - customEditor: column.customEditor, - format: column.format ? format : false, - key: i, - blurToSave: cellEdit.blurToSave, - onTab: this.handleEditCell, - rowIndex: r, - colIndex: i, - row: data, - fieldValue: fieldValue, - className: column.editClassName, - invalidColumnClassName: column.invalidEditColumnClassName, - beforeShowError: beforeShowError, - isFocus: isFocusCell, - customStyleWithNav: customEditAndNavStyle }); - } else { - // add by bluespring for className customize - var columnChild = fieldValue && fieldValue.toString(); - var columnTitle = null; - var tdClassName = column.className; - if (_util2.default.isFunction(column.className)) { - tdClassName = column.className(fieldValue, data, r, i); - } + CSSTransitionGroupChild.prototype.componentWillMount = function componentWillMount() { + this.classNameAndNodeQueue = []; + this.transitionTimeouts = []; + }; - if (typeof column.format !== 'undefined') { - var formattedValue = column.format(fieldValue, data, column.formatExtraData, r); - if (!_react2.default.isValidElement(formattedValue)) { - columnChild = _react2.default.createElement('div', { dangerouslySetInnerHTML: { __html: formattedValue } }); - } else { - columnChild = formattedValue; - columnTitle = column.columnTitle && formattedValue ? formattedValue.toString() : null; - } - } else { - columnTitle = column.columnTitle && fieldValue ? fieldValue.toString() : null; - } - return _react2.default.createElement( - _TableColumn2.default, - { key: i, - rIndex: r, - dataAlign: column.align, - className: tdClassName, - columnTitle: columnTitle, - cellEdit: cellEdit, - hidden: column.hidden, - onEdit: this.handleEditCell, - width: column.width, - onClick: this.handleClickCell, - attrs: column.attrs, - style: column.style, - tabIndex: tabIndex++ + '', - isFocus: isFocusCell, - keyBoardNav: enableKeyBoardNav, - onKeyDown: this.handleCellKeyDown, - customNavStyle: customNavStyle, - row: data, - withoutTabIndex: this.props.withoutTabIndex }, - columnChild - ); - } - }, this); - var key = data[this.props.keyField]; - var disable = unselectable.indexOf(key) !== -1; - var selected = this.props.selectedRowKeys.indexOf(key) !== -1; - var selectRowColumn = isSelectRowDefined && !this.props.selectRow.hideSelectColumn ? this.renderSelectRowColumn(selected, inputType, disable, CustomComponent, r, data) : null; - var expandedRowColumn = this.renderExpandRowColumn(this.props.expandableRow && this.props.expandableRow(data), this.props.expanding.indexOf(key) > -1, ExpandColumnCustomComponent, r); - var haveExpandContent = this.props.expandableRow && this.props.expandableRow(data); - var isExpanding = haveExpandContent && this.props.expanding.indexOf(key) > -1; - - // add by bluespring for className customize - var trClassName = this.props.trClassName; - if (_util2.default.isFunction(this.props.trClassName)) { - trClassName = this.props.trClassName(data, r); - } - if (isExpanding && this.props.expandParentClass) { - trClassName += _util2.default.isFunction(this.props.expandParentClass) ? this.props.expandParentClass(data, r) : this.props.expandParentClass; - } - var result = [_react2.default.createElement( - _TableRow2.default, - { isSelected: selected, key: key, className: trClassName, - index: r, - row: data, - selectRow: isSelectRowDefined ? this.props.selectRow : undefined, - enableCellEdit: cellEdit.mode !== _Const2.default.CELL_EDIT_NONE, - onRowClick: this.handleRowClick, - onRowDoubleClick: this.handleRowDoubleClick, - onRowMouseOver: this.handleRowMouseOver, - onRowMouseOut: this.handleRowMouseOut, - onSelectRow: this.handleSelectRow, - onExpandRow: this.handleClickCell, - unselectableRow: disable, - style: trStyle }, - this.props.expandColumnOptions.expandColumnVisible && this.props.expandColumnOptions.expandColumnBeforeSelectColumn && expandedRowColumn, - selectRowColumn, - this.props.expandColumnOptions.expandColumnVisible && !this.props.expandColumnOptions.expandColumnBeforeSelectColumn && expandedRowColumn, - tableColumns - )]; - - if (haveExpandContent) { - var expandBodyClass = _util2.default.isFunction(this.props.expandBodyClass) ? this.props.expandBodyClass(data, r, isExpanding) : this.props.expandBodyClass; - result.push(_react2.default.createElement( - _ExpandComponent2.default, - { - key: key + '-expand', - row: data, - className: expandBodyClass, - bgColor: this.props.expandRowBgColor || this.props.selectRow.bgColor || undefined, - hidden: !isExpanding, - colSpan: expandColSpan, - width: "100%" }, - this.props.expandComponent(data) - )); - } - return result; - }, this); - - if (tableRows.length === 0 && !this.props.withoutNoDataText) { - var colSpan = this.props.columns.filter(function (c) { - return !c.hidden; - }).length + (isSelectRowDefined && !this.props.selectRow.hideSelectColumn ? 1 : 0) + (this.props.expandColumnOptions.expandColumnVisible ? 1 : 0); - tableRows = [_react2.default.createElement( - _TableRow2.default, - { key: '##table-empty##', style: trStyle }, - _react2.default.createElement( - 'td', - { 'data-toggle': 'collapse', - colSpan: colSpan, - className: 'react-bs-table-no-data' }, - this.props.noDataText || _Const2.default.NO_DATA_TEXT - ) - )]; - } + CSSTransitionGroupChild.prototype.componentWillUnmount = function componentWillUnmount() { + this.unmounted = true; - return _react2.default.createElement( - 'div', - { ref: 'container', - className: (0, _classnames2.default)('react-bs-container-body', this.props.bodyContainerClass), - style: this.props.style }, - _react2.default.createElement( - 'table', - { className: tableClasses }, - _react2.default.cloneElement(tableHeader, { ref: 'header' }), - _react2.default.createElement( - 'tbody', - { ref: 'tbody' }, - tableRows - ) - ) - ); + if (this.timeout) { + clearTimeout(this.timeout); } - }, { - key: '__handleCellKeyDown__REACT_HOT_LOADER__', - value: function __handleCellKeyDown__REACT_HOT_LOADER__(e, lastEditCell) { - e.preventDefault(); - var _props2 = this.props, - keyBoardNav = _props2.keyBoardNav, - onNavigateCell = _props2.onNavigateCell, - cellEdit = _props2.cellEdit; - - var offset = void 0; - if (e.keyCode === 37) { - offset = { x: -1, y: 0 }; - } else if (e.keyCode === 38) { - offset = { x: 0, y: -1 }; - } else if (e.keyCode === 39 || e.keyCode === 9) { - offset = { x: 1, y: 0 }; - if (e.keyCode === 9 && lastEditCell) { - offset = _extends({}, offset, { - lastEditCell: lastEditCell - }); - } - } else if (e.keyCode === 40) { - offset = { x: 0, y: 1 }; - } else if (e.keyCode === 13) { - var enterToEdit = (typeof keyBoardNav === 'undefined' ? 'undefined' : _typeof(keyBoardNav)) === 'object' ? keyBoardNav.enterToEdit : false; - var enterToExpand = (typeof keyBoardNav === 'undefined' ? 'undefined' : _typeof(keyBoardNav)) === 'object' ? keyBoardNav.enterToExpand : false; - - if (cellEdit && enterToEdit) { - this.handleEditCell(e.target.parentElement.rowIndex + 1, e.currentTarget.cellIndex, '', e); - } + this.transitionTimeouts.forEach(function (timeout) { + clearTimeout(timeout); + }); - if (enterToExpand) { - this.handleClickCell(this.props.y + 1, this.props.x); - } - } - if (offset && keyBoardNav) { - onNavigateCell(offset); - } - } - }, { - key: '__handleRowMouseOut__REACT_HOT_LOADER__', - value: function __handleRowMouseOut__REACT_HOT_LOADER__(rowIndex, event) { - var targetRow = this.props.data[rowIndex]; - this.props.onRowMouseOut(targetRow, event); - } - }, { - key: '__handleRowMouseOver__REACT_HOT_LOADER__', - value: function __handleRowMouseOver__REACT_HOT_LOADER__(rowIndex, event) { - var targetRow = this.props.data[rowIndex]; - this.props.onRowMouseOver(targetRow, event); - } - }, { - key: '__handleRowClick__REACT_HOT_LOADER__', - value: function __handleRowClick__REACT_HOT_LOADER__(rowIndex, cellIndex) { - var onRowClick = this.props.onRowClick; + this.classNameAndNodeQueue.length = 0; + }; - if (this._isSelectRowDefined()) cellIndex--; - if (this._isExpandColumnVisible()) cellIndex--; - onRowClick(this.props.data[rowIndex - 1], rowIndex - 1, cellIndex); - } - }, { - key: '__handleRowDoubleClick__REACT_HOT_LOADER__', - value: function __handleRowDoubleClick__REACT_HOT_LOADER__(rowIndex) { - var onRowDoubleClick = this.props.onRowDoubleClick; + CSSTransitionGroupChild.prototype.transition = function transition(animationType, finishCallback, timeout) { + var node = (0, _reactDom.findDOMNode)(this); - var targetRow = this.props.data[rowIndex]; - onRowDoubleClick(targetRow); - } - }, { - key: '__handleSelectRow__REACT_HOT_LOADER__', - value: function __handleSelectRow__REACT_HOT_LOADER__(rowIndex, isSelected, e) { - var selectedRow = void 0; - var _props3 = this.props, - data = _props3.data, - onSelectRow = _props3.onSelectRow; - - data.forEach(function (row, i) { - if (i === rowIndex - 1) { - selectedRow = row; - return false; - } - }); - onSelectRow(selectedRow, isSelected, e, rowIndex - 1); - } - }, { - key: '__handleSelectRowColumChange__REACT_HOT_LOADER__', - value: function __handleSelectRowColumChange__REACT_HOT_LOADER__(e, rowIndex) { - if (!this.props.selectRow.clickToSelect || !this.props.selectRow.clickToSelectAndEditCell) { - this.handleSelectRow(rowIndex + 1, e.currentTarget.checked, e); - } - } - }, { - key: '__handleClickCell__REACT_HOT_LOADER__', - value: function __handleClickCell__REACT_HOT_LOADER__(rowIndex) { - var columnIndex = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : -1; - var _props4 = this.props, - columns = _props4.columns, - keyField = _props4.keyField, - expandBy = _props4.expandBy, - expandableRow = _props4.expandableRow, - _props4$selectRow = _props4.selectRow, - clickToExpand = _props4$selectRow.clickToExpand, - hideSelectColumn = _props4$selectRow.hideSelectColumn, - onlyOneExpanding = _props4.onlyOneExpanding; - - var selectRowAndExpand = this._isSelectRowDefined() && !clickToExpand ? false : true; - columnIndex = this._isSelectRowDefined() && !hideSelectColumn ? columnIndex - 1 : columnIndex; - columnIndex = this._isExpandColumnVisible() ? columnIndex - 1 : columnIndex; - if (expandableRow && selectRowAndExpand && (expandBy === _Const2.default.EXPAND_BY_ROW || - /* Below will allow expanding trigger by clicking on selection column - if configure as expanding by column */ - expandBy === _Const2.default.EXPAND_BY_COL && columnIndex < 0 || expandBy === _Const2.default.EXPAND_BY_COL && columns[columnIndex].expandable)) { - var expanding = this.props.expanding; - var rowKey = this.props.data[rowIndex - 1][keyField]; - var isRowExpanding = expanding.indexOf(rowKey) > -1; - - if (isRowExpanding) { - // collapse - expanding = expanding.filter(function (k) { - return k !== rowKey; - }); - } else { - // expand - if (onlyOneExpanding) expanding = [rowKey];else expanding.push(rowKey); - } - this.props.onExpand(expanding, rowKey, isRowExpanding); + if (!node) { + if (finishCallback) { + finishCallback(); } + return; } - }, { - key: '__handleEditCell__REACT_HOT_LOADER__', - value: function __handleEditCell__REACT_HOT_LOADER__(rowIndex, columnIndex, action, e) { - var selectRow = this.props.selectRow; - - var defineSelectRow = this._isSelectRowDefined(); - var expandColumnVisible = this._isExpandColumnVisible(); - if (defineSelectRow) { - columnIndex--; - if (selectRow.hideSelectColumn) columnIndex++; - } - if (expandColumnVisible) { - columnIndex--; - } - rowIndex--; - - if (action === 'tab') { - if (defineSelectRow && !selectRow.hideSelectColumn) columnIndex++; - if (expandColumnVisible) columnIndex++; - this.handleCompleteEditCell(e.target.value, rowIndex, columnIndex - 1); - if (columnIndex >= this.props.columns.length) { - this.handleCellKeyDown(e, true); - } else { - this.handleCellKeyDown(e); - } - var _nextEditableCell = this.nextEditableCell(rowIndex, columnIndex), - nextRIndex = _nextEditableCell.nextRIndex, - nextCIndex = _nextEditableCell.nextCIndex; + var className = this.props.name[animationType] || this.props.name + '-' + animationType; + var activeClassName = this.props.name[animationType + 'Active'] || className + '-active'; + var timer = null; + var removeListeners = void 0; - rowIndex = nextRIndex; - columnIndex = nextCIndex; - } + (0, _addClass2.default)(node, className); - var stateObj = { - currEditCell: { - rid: rowIndex, - cid: columnIndex - } - }; + // Need to do this to actually trigger a transition. + this.queueClassAndNode(activeClassName, node); - if (this.props.selectRow.clickToSelectAndEditCell && this.props.cellEdit.mode !== _Const2.default.CELL_EDIT_DBCLICK) { - var selected = this.props.selectedRowKeys.indexOf(this.props.data[rowIndex][this.props.keyField]) !== -1; - this.handleSelectRow(rowIndex + 1, !selected, e); - } - this.setState(function () { - return stateObj; - }); - } - }, { - key: '__nextEditableCell__REACT_HOT_LOADER__', - value: function __nextEditableCell__REACT_HOT_LOADER__(rIndex, cIndex) { - var keyField = this.props.keyField; - - var nextRIndex = rIndex; - var nextCIndex = cIndex; - var row = void 0; - var column = void 0; - do { - if (nextCIndex >= this.props.columns.length) { - nextRIndex++; - nextCIndex = 0; - } - row = this.props.data[nextRIndex]; - column = this.props.columns[nextCIndex]; - if (!row) break; - var editable = column.editable; - if (_util2.default.isFunction(column.editable)) { - editable = column.editable(column, row, nextRIndex, nextCIndex); - } - if (editable && editable.readOnly !== true && !column.hidden && keyField !== column.name) { - break; - } else { - nextCIndex++; - } - } while (row); - return { nextRIndex: nextRIndex, nextCIndex: nextCIndex }; - } - }, { - key: '__handleCompleteEditCell__REACT_HOT_LOADER__', - value: function __handleCompleteEditCell__REACT_HOT_LOADER__(newVal, rowIndex, columnIndex) { - if (newVal !== null) { - var result = this.props.onEditCell(newVal, rowIndex, columnIndex); - if (result !== _Const2.default.AWAIT_BEFORE_CELL_EDIT) { - this.setState(function () { - return { currEditCell: null }; - }); - } - } else { - this.setState(function () { - return { currEditCell: null }; - }); - } - } - }, { - key: '__cancelEditCell__REACT_HOT_LOADER__', - value: function __cancelEditCell__REACT_HOT_LOADER__() { - this.setState(function () { - return { currEditCell: null }; - }); - } - }, { - key: '__handleClickonSelectColumn__REACT_HOT_LOADER__', - value: function __handleClickonSelectColumn__REACT_HOT_LOADER__(e, isSelect, rowIndex, row) { - e.stopPropagation(); - if (e.target.tagName === 'TD' && (this.props.selectRow.clickToSelect || this.props.selectRow.clickToSelectAndEditCell)) { - var unselectable = this.props.selectRow.unselectable || []; - if (unselectable.indexOf(row[this.props.keyField]) === -1) { - this.handleSelectRow(rowIndex + 1, isSelect, e); - this.handleClickCell(rowIndex + 1); - } + // Clean-up the animation after the specified delay + var finish = function finish(e) { + if (e && e.target !== node) { + return; } - } - }, { - key: 'renderSelectRowColumn', - value: function renderSelectRowColumn(selected, inputType, disabled) { - var CustomComponent = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null; - var _this2 = this; - - var rowIndex = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : null; - var row = arguments[5]; + clearTimeout(timer); + if (removeListeners) removeListeners(); - return _react2.default.createElement( - 'td', - { onClick: function onClick(e) { - _this2.handleClickonSelectColumn(e, !selected, rowIndex, row); - }, style: { textAlign: 'center' } }, - CustomComponent ? _react2.default.createElement(CustomComponent, { type: inputType, checked: selected, disabled: disabled, - rowIndex: rowIndex, - onChange: function onChange(e) { - return _this2.handleSelectRowColumChange(e, rowIndex); - } }) : _react2.default.createElement('input', { type: inputType, checked: selected, disabled: disabled, - onChange: function onChange(e) { - return _this2.handleSelectRowColumChange(e, rowIndex); - } }) - ); - } - }, { - key: 'renderExpandRowColumn', - value: function renderExpandRowColumn(isExpandableRow, isExpanded, CustomComponent) { - var _this3 = this; + (0, _removeClass2.default)(node, className); + (0, _removeClass2.default)(node, activeClassName); - var rowIndex = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null; + if (removeListeners) removeListeners(); - var content = null; - if (CustomComponent) { - content = _react2.default.createElement(CustomComponent, { isExpandableRow: isExpandableRow, isExpanded: isExpanded }); - } else if (isExpandableRow) { - content = isExpanded ? _react2.default.createElement('span', { className: 'fa fa-minus glyphicon glyphicon-minus' }) : _react2.default.createElement('span', { className: 'fa fa-plus glyphicon glyphicon-plus' }); - } else { - content = ' '; + // Usually this optional callback is used for informing an owner of + // a leave animation and telling it to remove the child. + if (finishCallback) { + finishCallback(); } + }; - return _react2.default.createElement( - 'td', - { - className: 'react-bs-table-expand-cell', - onClick: function onClick() { - return _this3.handleClickCell(rowIndex + 1); - } }, - content - ); - } - }, { - key: '_isSelectRowDefined', - value: function _isSelectRowDefined() { - return this.props.selectRow.mode === _Const2.default.ROW_SELECT_SINGLE || this.props.selectRow.mode === _Const2.default.ROW_SELECT_MULTI; + if (timeout) { + timer = setTimeout(finish, timeout); + this.transitionTimeouts.push(timer); + } else if (_properties.transitionEnd) { + removeListeners = addEndListener(node, finish); } - }, { - key: '_isExpandColumnVisible', - value: function _isExpandColumnVisible() { - return this.props.expandColumnOptions.expandColumnVisible; + }; + + CSSTransitionGroupChild.prototype.queueClassAndNode = function queueClassAndNode(className, node) { + var _this2 = this; + + this.classNameAndNodeQueue.push({ + className: className, + node: node + }); + + if (!this.rafHandle) { + this.rafHandle = (0, _requestAnimationFrame2.default)(function () { + return _this2.flushClassNameAndNodeQueue(); + }); } - }, { - key: '__getHeaderColGrouop__REACT_HOT_LOADER__', - value: function __getHeaderColGrouop__REACT_HOT_LOADER__() { - return this.refs.header.childNodes; + }; + + CSSTransitionGroupChild.prototype.flushClassNameAndNodeQueue = function flushClassNameAndNodeQueue() { + if (!this.unmounted) { + this.classNameAndNodeQueue.forEach(function (obj) { + // This is for to force a repaint, + // which is necessary in order to transition styles when adding a class name. + /* eslint-disable no-unused-expressions */ + obj.node.scrollTop; + /* eslint-enable no-unused-expressions */ + (0, _addClass2.default)(obj.node, obj.className); + }); } - }]); + this.classNameAndNodeQueue.length = 0; + this.rafHandle = null; + }; - return TableBody; -}(_react.Component); + CSSTransitionGroupChild.prototype.render = function render() { + var props = _extends({}, this.props); + delete props.name; + delete props.appear; + delete props.enter; + delete props.leave; + delete props.appearTimeout; + delete props.enterTimeout; + delete props.leaveTimeout; + delete props.children; + return _react2.default.cloneElement(_react2.default.Children.only(this.props.children), props); + }; -TableBody.propTypes = { - version: _propTypes2.default.string, - data: _propTypes2.default.array, - columns: _propTypes2.default.array, - striped: _propTypes2.default.bool, - bordered: _propTypes2.default.bool, - hover: _propTypes2.default.bool, - condensed: _propTypes2.default.bool, - keyField: _propTypes2.default.string, - selectedRowKeys: _propTypes2.default.array, - onRowClick: _propTypes2.default.func, - onRowDoubleClick: _propTypes2.default.func, - onSelectRow: _propTypes2.default.func, - noDataText: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.object]), - withoutNoDataText: _propTypes2.default.bool, - style: _propTypes2.default.object, - tableBodyClass: _propTypes2.default.string, - bodyContainerClass: _propTypes2.default.string, - expandableRow: _propTypes2.default.func, - expandComponent: _propTypes2.default.func, - expandRowBgColor: _propTypes2.default.string, - expandBy: _propTypes2.default.string, - expanding: _propTypes2.default.array, - onExpand: _propTypes2.default.func, - expandBodyClass: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.func]), - expandParentClass: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.func]), - onlyOneExpanding: _propTypes2.default.bool, - beforeShowError: _propTypes2.default.func, - keyBoardNav: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.object]), - x: _propTypes2.default.number, - y: _propTypes2.default.number, - onNavigateCell: _propTypes2.default.func, - withoutTabIndex: _propTypes2.default.bool -}; -var _default = TableBody; -exports.default = _default; -; + return CSSTransitionGroupChild; +}(_react2.default.Component); -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } +CSSTransitionGroupChild.displayName = 'CSSTransitionGroupChild'; - __REACT_HOT_LOADER__.register(TableBody, 'TableBody', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableBody.js'); - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableBody.js'); -}(); +CSSTransitionGroupChild.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {}; -; +exports.default = CSSTransitionGroupChild; +module.exports = exports['default']; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 375 */ +/* 327 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -60049,228 +49570,107 @@ var _temp = function () { Object.defineProperty(exports, "__esModule", { value: true }); +exports.default = addClass; -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _classnames = __webpack_require__(29); - -var _classnames2 = _interopRequireDefault(_classnames); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _util = __webpack_require__(68); +var _hasClass = __webpack_require__(328); -var _util2 = _interopRequireDefault(_util); +var _hasClass2 = _interopRequireDefault(_hasClass); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +function addClass(element, className) { + if (element.classList) element.classList.add(className);else if (!(0, _hasClass2.default)(element)) element.className = element.className + ' ' + className; +} +module.exports = exports['default']; -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +/***/ }), +/* 328 */ +/***/ (function(module, exports, __webpack_require__) { -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } /* eslint no-nested-ternary: 0 */ +"use strict"; -var TableRow = function (_Component) { - _inherits(TableRow, _Component); +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.default = hasClass; +function hasClass(element, className) { + if (element.classList) return !!className && element.classList.contains(className);else return (" " + element.className + " ").indexOf(" " + className + " ") !== -1; +} +module.exports = exports["default"]; - function TableRow(props) { - _classCallCheck(this, TableRow); +/***/ }), +/* 329 */ +/***/ (function(module, exports, __webpack_require__) { - var _this = _possibleConstructorReturn(this, (TableRow.__proto__ || Object.getPrototypeOf(TableRow)).call(this, props)); +"use strict"; - _this.rowClick = function () { - return _this.__rowClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; - _this.expandRow = function () { - return _this.__expandRow__REACT_HOT_LOADER__.apply(_this, arguments); - }; +module.exports = function removeClass(element, className) { + if (element.classList) element.classList.remove(className);else element.className = element.className.replace(new RegExp('(^|\\s)' + className + '(?:\\s|$)', 'g'), '$1').replace(/\s+/g, ' ').replace(/^\s*|\s*$/g, ''); +}; - _this.rowDoubleClick = function () { - return _this.__rowDoubleClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; +/***/ }), +/* 330 */ +/***/ (function(module, exports, __webpack_require__) { - _this.rowMouseOut = function () { - return _this.__rowMouseOut__REACT_HOT_LOADER__.apply(_this, arguments); - }; +"use strict"; - _this.rowMouseOver = function () { - return _this.__rowMouseOver__REACT_HOT_LOADER__.apply(_this, arguments); - }; - _this.clickNum = 0; - return _this; - } +Object.defineProperty(exports, "__esModule", { + value: true +}); - _createClass(TableRow, [{ - key: '__rowClick__REACT_HOT_LOADER__', - value: function __rowClick__REACT_HOT_LOADER__(e) { - var _this2 = this; +var _inDOM = __webpack_require__(152); - var rowIndex = this.props.index + 1; - var cellIndex = e.target.cellIndex; - if (this.props.onRowClick) this.props.onRowClick(rowIndex, cellIndex); - var _props = this.props, - selectRow = _props.selectRow, - unselectableRow = _props.unselectableRow, - isSelected = _props.isSelected, - onSelectRow = _props.onSelectRow, - onExpandRow = _props.onExpandRow; - - if (selectRow) { - if (selectRow.clickToSelect && !unselectableRow) { - onSelectRow(rowIndex, !isSelected, e); - } else if (selectRow.clickToSelectAndEditCell && !unselectableRow) { - this.clickNum++; - /** if clickToSelectAndEditCell is enabled, - * there should be a delay to prevent a selection changed when - * user dblick to edit cell on same row but different cell - **/ - setTimeout(function () { - if (_this2.clickNum === 1) { - onSelectRow(rowIndex, !isSelected, e); - onExpandRow(rowIndex, cellIndex); - } - _this2.clickNum = 0; - }, 200); - } else { - this.expandRow(rowIndex, cellIndex); - } - } - } - }, { - key: '__expandRow__REACT_HOT_LOADER__', - value: function __expandRow__REACT_HOT_LOADER__(rowIndex, cellIndex) { - var _this3 = this; +var _inDOM2 = _interopRequireDefault(_inDOM); - this.clickNum++; - setTimeout(function () { - if (_this3.clickNum === 1) { - _this3.props.onExpandRow(rowIndex, cellIndex); - } - _this3.clickNum = 0; - }, 200); - } - }, { - key: '__rowDoubleClick__REACT_HOT_LOADER__', - value: function __rowDoubleClick__REACT_HOT_LOADER__(e) { - if (e.target.tagName !== 'INPUT' && e.target.tagName !== 'SELECT' && e.target.tagName !== 'TEXTAREA') { - if (this.props.onRowDoubleClick) { - this.props.onRowDoubleClick(this.props.index); - } - } - } - }, { - key: '__rowMouseOut__REACT_HOT_LOADER__', - value: function __rowMouseOut__REACT_HOT_LOADER__(e) { - var rowIndex = this.props.index; - if (this.props.onRowMouseOut) { - this.props.onRowMouseOut(rowIndex, e); - } - } - }, { - key: '__rowMouseOver__REACT_HOT_LOADER__', - value: function __rowMouseOver__REACT_HOT_LOADER__(e) { - var rowIndex = this.props.index; - if (this.props.onRowMouseOver) { - this.props.onRowMouseOver(rowIndex, e); - } - } - }, { - key: 'render', - value: function render() { - this.clickNum = 0; - var _props2 = this.props, - selectRow = _props2.selectRow, - row = _props2.row, - isSelected = _props2.isSelected, - className = _props2.className, - index = _props2.index; - var style = this.props.style; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - var backgroundColor = null; - var selectRowClass = null; +var vendors = ['', 'webkit', 'moz', 'o', 'ms']; +var cancel = 'clearTimeout'; +var raf = fallback; +var compatRaf = void 0; - if (selectRow) { - backgroundColor = _util2.default.isFunction(selectRow.bgColor) ? selectRow.bgColor(row, isSelected) : isSelected ? selectRow.bgColor : null; +var getKey = function getKey(vendor, k) { + return vendor + (!vendor ? k : k[0].toUpperCase() + k.substr(1)) + 'AnimationFrame'; +}; - selectRowClass = _util2.default.isFunction(selectRow.className) ? selectRow.className(row, isSelected) : isSelected ? selectRow.className : null; - } +if (_inDOM2.default) { + vendors.some(function (vendor) { + var rafKey = getKey(vendor, 'request'); - if (_util2.default.isFunction(style)) { - style = style(row, index); - } else { - style = _extends({}, style) || {}; - } - // the bgcolor of row selection always overwrite the bgcolor defined by global. - if (style && backgroundColor && isSelected) { - style.backgroundColor = backgroundColor; - } - var trCss = { - style: _extends({}, style), - className: (0, _classnames2.default)(selectRowClass, className) + if (rafKey in window) { + cancel = getKey(vendor, 'cancel'); + return raf = function raf(cb) { + return window[rafKey](cb); }; - - return _react2.default.createElement( - 'tr', - _extends({}, trCss, { - onMouseOver: this.rowMouseOver, - onMouseOut: this.rowMouseOut, - onClick: this.rowClick, - onDoubleClick: this.rowDoubleClick }), - this.props.children - ); } - }]); - - return TableRow; -}(_react.Component); - -TableRow.propTypes = { - index: _propTypes2.default.number, - row: _propTypes2.default.any, - style: _propTypes2.default.any, - isSelected: _propTypes2.default.bool, - enableCellEdit: _propTypes2.default.bool, - onRowClick: _propTypes2.default.func, - onRowDoubleClick: _propTypes2.default.func, - onSelectRow: _propTypes2.default.func, - onExpandRow: _propTypes2.default.func, - onRowMouseOut: _propTypes2.default.func, - onRowMouseOver: _propTypes2.default.func, - unselectableRow: _propTypes2.default.bool -}; -TableRow.defaultProps = { - onRowClick: undefined, - onRowDoubleClick: undefined -}; -var _default = TableRow; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } + }); +} - __REACT_HOT_LOADER__.register(TableRow, 'TableRow', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableRow.js'); +/* https://github.com/component/raf */ +var prev = new Date().getTime(); +function fallback(fn) { + var curr = new Date().getTime(), + ms = Math.max(0, 16 - (curr - prev)), + req = setTimeout(fn, ms); - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableRow.js'); -}(); + prev = curr; + return req; +} -; +compatRaf = function compatRaf(cb) { + return raf(cb); +}; +compatRaf.cancel = function (id) { + window[cancel] && typeof window[cancel] === 'function' && window[cancel](id); +}; +exports.default = compatRaf; +module.exports = exports['default']; /***/ }), -/* 376 */ +/* 331 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -60279,302 +49679,194 @@ var _temp = function () { Object.defineProperty(exports, "__esModule", { value: true }); +exports.animationEnd = exports.animationDelay = exports.animationTiming = exports.animationDuration = exports.animationName = exports.transitionEnd = exports.transitionDuration = exports.transitionDelay = exports.transitionTiming = exports.transitionProperty = exports.transform = undefined; -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; +var _inDOM = __webpack_require__(152); -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +var _inDOM2 = _interopRequireDefault(_inDOM); -var _react = __webpack_require__(4); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -var _react2 = _interopRequireDefault(_react); +var transform = 'transform'; +var prefix = void 0, + transitionEnd = void 0, + animationEnd = void 0; +var transitionProperty = void 0, + transitionDuration = void 0, + transitionTiming = void 0, + transitionDelay = void 0; +var animationName = void 0, + animationDuration = void 0, + animationTiming = void 0, + animationDelay = void 0; -var _propTypes = __webpack_require__(9); +if (_inDOM2.default) { + var _getTransitionPropert = getTransitionProperties(); -var _propTypes2 = _interopRequireDefault(_propTypes); + prefix = _getTransitionPropert.prefix; + exports.transitionEnd = transitionEnd = _getTransitionPropert.transitionEnd; + exports.animationEnd = animationEnd = _getTransitionPropert.animationEnd; -var _reactDom = __webpack_require__(28); -var _reactDom2 = _interopRequireDefault(_reactDom); + exports.transform = transform = prefix + '-' + transform; + exports.transitionProperty = transitionProperty = prefix + '-transition-property'; + exports.transitionDuration = transitionDuration = prefix + '-transition-duration'; + exports.transitionDelay = transitionDelay = prefix + '-transition-delay'; + exports.transitionTiming = transitionTiming = prefix + '-transition-timing-function'; -var _Const = __webpack_require__(22); + exports.animationName = animationName = prefix + '-animation-name'; + exports.animationDuration = animationDuration = prefix + '-animation-duration'; + exports.animationTiming = animationTiming = prefix + '-animation-delay'; + exports.animationDelay = animationDelay = prefix + '-animation-timing-function'; +} -var _Const2 = _interopRequireDefault(_Const); +exports.transform = transform; +exports.transitionProperty = transitionProperty; +exports.transitionTiming = transitionTiming; +exports.transitionDelay = transitionDelay; +exports.transitionDuration = transitionDuration; +exports.transitionEnd = transitionEnd; +exports.animationName = animationName; +exports.animationDuration = animationDuration; +exports.animationTiming = animationTiming; +exports.animationDelay = animationDelay; +exports.animationEnd = animationEnd; +exports.default = { + transform: transform, + end: transitionEnd, + property: transitionProperty, + timing: transitionTiming, + delay: transitionDelay, + duration: transitionDuration +}; -var _util = __webpack_require__(68); -var _util2 = _interopRequireDefault(_util); +function getTransitionProperties() { + var style = document.createElement('div').style; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + var vendorMap = { + O: function O(e) { + return 'o' + e.toLowerCase(); + }, + Moz: function Moz(e) { + return e.toLowerCase(); + }, + Webkit: function Webkit(e) { + return 'webkit' + e; + }, + ms: function ms(e) { + return 'MS' + e; + } + }; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + var vendors = Object.keys(vendorMap); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + var transitionEnd = void 0, + animationEnd = void 0; + var prefix = ''; -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + for (var i = 0; i < vendors.length; i++) { + var vendor = vendors[i]; -var TableColumn = function (_Component) { - _inherits(TableColumn, _Component); + if (vendor + 'TransitionProperty' in style) { + prefix = '-' + vendor.toLowerCase(); + transitionEnd = vendorMap[vendor]('TransitionEnd'); + animationEnd = vendorMap[vendor]('AnimationEnd'); + break; + } + } - function TableColumn(props) { - _classCallCheck(this, TableColumn); + if (!transitionEnd && 'transitionProperty' in style) transitionEnd = 'transitionend'; - var _this = _possibleConstructorReturn(this, (TableColumn.__proto__ || Object.getPrototypeOf(TableColumn)).call(this, props)); + if (!animationEnd && 'animationName' in style) animationEnd = 'animationend'; - _this.handleCellEdit = function () { - return _this.__handleCellEdit__REACT_HOT_LOADER__.apply(_this, arguments); - }; + style = null; - _this.handleCellClick = function () { - return _this.__handleCellClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; + return { animationEnd: animationEnd, transitionEnd: transitionEnd, prefix: prefix }; +} - _this.handleKeyDown = function () { - return _this.__handleKeyDown__REACT_HOT_LOADER__.apply(_this, arguments); - }; +/***/ }), +/* 332 */ +/***/ (function(module, exports, __webpack_require__) { - return _this; - } - /* eslint no-unused-vars: [0, { "args": "after-used" }] */ +"use strict"; +/* WEBPACK VAR INJECTION */(function(Buffer) { +Object.defineProperty(exports, "__esModule", { + value: true +}); - _createClass(TableColumn, [{ - key: 'shouldComponentUpdate', - value: function shouldComponentUpdate(nextProps, nextState) { - var children = this.props.children; +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - var shouldUpdated = this.props.width !== nextProps.width || this.props.className !== nextProps.className || this.props.hidden !== nextProps.hidden || this.props.dataAlign !== nextProps.dataAlign || this.props.isFocus !== nextProps.isFocus || (typeof children === 'undefined' ? 'undefined' : _typeof(children)) !== _typeof(nextProps.children) || ('' + this.props.onEdit).toString() !== ('' + nextProps.onEdit).toString(); +var _reactstrap = __webpack_require__(93); - if (shouldUpdated) { - return shouldUpdated; - } +var _axios = __webpack_require__(335); - if ((typeof children === 'undefined' ? 'undefined' : _typeof(children)) === 'object' && children !== null && children.props !== null) { - if (children.props.type === 'checkbox' || children.props.type === 'radio') { - shouldUpdated = shouldUpdated || children.props.type !== nextProps.children.props.type || children.props.checked !== nextProps.children.props.checked || children.props.disabled !== nextProps.children.props.disabled; - } else { - shouldUpdated = true; - } - } else { - shouldUpdated = shouldUpdated || children !== nextProps.children; - } +var _axios2 = _interopRequireDefault(_axios); - if (shouldUpdated) { - return shouldUpdated; - } +var _react = __webpack_require__(6); - if (!(this.props.cellEdit && nextProps.cellEdit)) { - return false; - } else { - return shouldUpdated || this.props.cellEdit.mode !== nextProps.cellEdit.mode; - } - } - }, { - key: 'componentDidMount', - value: function componentDidMount() { - var dom = _reactDom2.default.findDOMNode(this); - if (this.props.isFocus) { - dom.focus(); - } else { - dom.blur(); - } - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate() { - var dom = _reactDom2.default.findDOMNode(this); - if (this.props.isFocus) { - dom.focus(); - } else { - dom.blur(); - } - } - }, { - key: '__handleCellEdit__REACT_HOT_LOADER__', - value: function __handleCellEdit__REACT_HOT_LOADER__(e) { - if (this.props.cellEdit.mode === _Const2.default.CELL_EDIT_DBCLICK) { - if (document.selection && document.selection.empty) { - document.selection.empty(); - } else if (window.getSelection) { - var sel = window.getSelection(); - sel.removeAllRanges(); - } - } - this.props.onEdit(this.props.rIndex + 1, e.currentTarget.cellIndex, e); - if (this.props.cellEdit.mode !== _Const2.default.CELL_EDIT_DBCLICK) { - this.props.onClick(this.props.rIndex + 1, e.currentTarget.cellIndex, e); - } - } - }, { - key: '__handleCellClick__REACT_HOT_LOADER__', - value: function __handleCellClick__REACT_HOT_LOADER__(e) { - var _props = this.props, - onClick = _props.onClick, - rIndex = _props.rIndex; +var _react2 = _interopRequireDefault(_react); - if (onClick) { - onClick(rIndex + 1, e.currentTarget.cellIndex, e); - } - } - }, { - key: '__handleKeyDown__REACT_HOT_LOADER__', - value: function __handleKeyDown__REACT_HOT_LOADER__(e) { - if (this.props.keyBoardNav) { - this.props.onKeyDown(e); - } - } - }, { - key: 'render', - value: function render() { - var _props2 = this.props, - children = _props2.children, - columnTitle = _props2.columnTitle, - dataAlign = _props2.dataAlign, - hidden = _props2.hidden, - cellEdit = _props2.cellEdit, - attrs = _props2.attrs, - style = _props2.style, - isFocus = _props2.isFocus, - keyBoardNav = _props2.keyBoardNav, - tabIndex = _props2.tabIndex, - customNavStyle = _props2.customNavStyle, - withoutTabIndex = _props2.withoutTabIndex, - row = _props2.row; - var className = this.props.className; - - - var tdStyle = _extends({ - textAlign: dataAlign, - display: hidden ? 'none' : null - }, style); - - var opts = {}; - - if (cellEdit) { - if (cellEdit.mode === _Const2.default.CELL_EDIT_CLICK) { - opts.onClick = this.handleCellEdit; - } else if (cellEdit.mode === _Const2.default.CELL_EDIT_DBCLICK) { - opts.onDoubleClick = this.handleCellEdit; - } else { - opts.onClick = this.handleCellClick; - } - } +var _classnames = __webpack_require__(41); - if (keyBoardNav && isFocus) { - opts.onKeyDown = this.handleKeyDown; - } +var _classnames2 = _interopRequireDefault(_classnames); - if (isFocus) { - if (customNavStyle) { - var cusmtStyle = _util2.default.isFunction(customNavStyle) ? customNavStyle(children, row) : customNavStyle; - tdStyle = _extends({}, tdStyle, cusmtStyle); - } else { - className = className + ' default-focus-cell'; - } - } +var _reactCopyToClipboard = __webpack_require__(354); - var attr = {}; - if (!withoutTabIndex) attr.tabIndex = tabIndex; - return _react2.default.createElement( - 'td', - _extends({}, attr, { style: tdStyle, - title: columnTitle, - className: className - }, opts, attrs), - typeof children === 'boolean' ? children.toString() : children - ); - } - }]); +var _reactCopyToClipboard2 = _interopRequireDefault(_reactCopyToClipboard); - return TableColumn; -}(_react.Component); +var _reactTable = __webpack_require__(358); -TableColumn.propTypes = { - rIndex: _propTypes2.default.number, - dataAlign: _propTypes2.default.string, - hidden: _propTypes2.default.bool, - className: _propTypes2.default.string, - columnTitle: _propTypes2.default.string, - children: _propTypes2.default.node, - onClick: _propTypes2.default.func, - attrs: _propTypes2.default.object, - style: _propTypes2.default.object, - isFocus: _propTypes2.default.bool, - onKeyDown: _propTypes2.default.func, - tabIndex: _propTypes2.default.string, - withoutTabIndex: _propTypes2.default.bool, - keyBoardNav: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.object]), - customNavStyle: _propTypes2.default.oneOfType([_propTypes2.default.func, _propTypes2.default.object]), - row: _propTypes2.default.any /* only used on custom styling for navigation */ -}; - -TableColumn.defaultProps = { - dataAlign: 'left', - withoutTabIndex: false, - hidden: false, - className: '', - isFocus: false, - keyBoardNav: false -}; -var _default = TableColumn; -exports.default = _default; -; +var _reactTable2 = _interopRequireDefault(_reactTable); -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } +var _zencashjs = __webpack_require__(160); - __REACT_HOT_LOADER__.register(TableColumn, 'TableColumn', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableColumn.js'); +var _zencashjs2 = _interopRequireDefault(_zencashjs); - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableColumn.js'); -}(); +var _utils = __webpack_require__(462); -; +var _utils2 = _interopRequireDefault(_utils); -/***/ }), -/* 377 */ -/***/ (function(module, exports, __webpack_require__) { +var _hdwallet = __webpack_require__(464); -"use strict"; +var _hdwallet2 = _interopRequireDefault(_hdwallet); +var _fileSaver = __webpack_require__(497); -Object.defineProperty(exports, "__esModule", { - value: true -}); +var _fileSaver2 = _interopRequireDefault(_fileSaver); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +var _refresh = __webpack_require__(500); -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; +var _refresh2 = _interopRequireDefault(_refresh); -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +var _contentCopy = __webpack_require__(501); -var _react = __webpack_require__(4); +var _contentCopy2 = _interopRequireDefault(_contentCopy); -var _react2 = _interopRequireDefault(_react); +var _settings2 = __webpack_require__(502); -var _propTypes = __webpack_require__(9); +var _settings3 = _interopRequireDefault(_settings2); -var _propTypes2 = _interopRequireDefault(_propTypes); +var _repeat = __webpack_require__(503); -var _reactDom = __webpack_require__(28); +var _repeat2 = _interopRequireDefault(_repeat); -var _reactDom2 = _interopRequireDefault(_reactDom); +var _unlockAlt = __webpack_require__(504); -var _Editor = __webpack_require__(285); +var _unlockAlt2 = _interopRequireDefault(_unlockAlt); -var _Editor2 = _interopRequireDefault(_Editor); +var _eyeSlash = __webpack_require__(505); -var _Notification = __webpack_require__(286); +var _eyeSlash2 = _interopRequireDefault(_eyeSlash); -var _classnames = __webpack_require__(29); +var _eye = __webpack_require__(506); -var _classnames2 = _interopRequireDefault(_classnames); +var _eye2 = _interopRequireDefault(_eye); -var _util = __webpack_require__(68); +var _package = __webpack_require__(507); -var _util2 = _interopRequireDefault(_util); +var _package2 = _interopRequireDefault(_package); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -60584,3959 +49876,2924 @@ function _possibleConstructorReturn(self, call) { if (!self) { throw new Referen function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -var TableEditColumn = function (_Component) { - _inherits(TableEditColumn, _Component); - - function TableEditColumn(props) { - _classCallCheck(this, TableEditColumn); +// Throttled GET request to prevent unusable lag +var throttledAxiosGet = _utils2.default.promiseDebounce(_axios2.default.get, 1000, 5); - var _this = _possibleConstructorReturn(this, (TableEditColumn.__proto__ || Object.getPrototypeOf(TableEditColumn)).call(this, props)); +// Unlock wallet enum +var UNLOCK_WALLET_TYPE = { + IMPORT_WALLET: 0, + HD_WALLET: 1, + PASTE_PRIV_KEY: 2 - _this.handleKeyPress = function () { - return _this.__handleKeyPress__REACT_HOT_LOADER__.apply(_this, arguments); - }; + // Components +}; +var ToolTipButton = function (_React$Component) { + _inherits(ToolTipButton, _React$Component); - _this.handleBlur = function () { - return _this.__handleBlur__REACT_HOT_LOADER__.apply(_this, arguments); - }; + function ToolTipButton(props) { + _classCallCheck(this, ToolTipButton); - _this.handleCustomUpdate = function () { - return _this.__handleCustomUpdate__REACT_HOT_LOADER__.apply(_this, arguments); - }; + var _this = _possibleConstructorReturn(this, (ToolTipButton.__proto__ || Object.getPrototypeOf(ToolTipButton)).call(this, props)); - _this.notifyToastr = function () { - return _this.__notifyToastr__REACT_HOT_LOADER__.apply(_this, arguments); + _this.toggle = _this.toggle.bind(_this); + _this.state = { + tooltipOpen: false }; + return _this; + } - _this.handleClick = function () { - return _this.__handleClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; + _createClass(ToolTipButton, [{ + key: 'toggle', + value: function toggle() { + this.setState({ + tooltipOpen: !this.state.tooltipOpen + }); + } + }, { + key: 'render', + value: function render() { + return _react2.default.createElement( + 'span', + null, + _react2.default.createElement( + _reactstrap.Button, + { disabled: this.props.disabled, onClick: this.props.onClick, className: 'mr-1', color: 'secondary', id: 'Tooltip-' + this.props.id }, + this.props.buttonText + ), + _react2.default.createElement( + _reactstrap.Tooltip, + { placement: 'top', isOpen: this.state.tooltipOpen, target: 'Tooltip-' + this.props.id, toggle: this.toggle }, + this.props.tooltipText + ) + ); + } + }]); - _this.getInputRef = function () { - return _this.__getInputRef__REACT_HOT_LOADER__.apply(_this, arguments); - }; + return ToolTipButton; +}(_react2.default.Component); - _this.getHandleKeyPress = function () { - return _this.__getHandleKeyPress__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var ZWalletGenerator = function (_React$Component2) { + _inherits(ZWalletGenerator, _React$Component2); - _this.getHandleBlur = function () { - return _this.__getHandleBlur__REACT_HOT_LOADER__.apply(_this, arguments); - }; + function ZWalletGenerator(props) { + _classCallCheck(this, ZWalletGenerator); - _this.timeouteClear = 0; - var _this$props = _this.props, - fieldValue = _this$props.fieldValue, - row = _this$props.row, - className = _this$props.className; + var _this2 = _possibleConstructorReturn(this, (ZWalletGenerator.__proto__ || Object.getPrototypeOf(ZWalletGenerator)).call(this, props)); - _this.focusInEditor = _this.focusInEditor.bind(_this); - _this.state = { - shakeEditor: false, - className: _util2.default.isFunction(className) ? className(fieldValue, row) : className + _this2.handlePasswordPhrase = _this2.handlePasswordPhrase.bind(_this2); + _this2.state = { + passwordPhrase: '', + privateKey: '' }; - return _this; + return _this2; } - _createClass(TableEditColumn, [{ - key: 'valueShortCircuit', - value: function valueShortCircuit(value) { - return value === null || typeof value === 'undefined' ? '' : value; - } - }, { - key: '__handleKeyPress__REACT_HOT_LOADER__', - value: function __handleKeyPress__REACT_HOT_LOADER__(e) { - if (e.keyCode === 13 || e.keyCode === 9) { - // Pressed ENTER or TAB - var value = e.currentTarget.type === 'checkbox' ? this._getCheckBoxValue(e) : e.currentTarget.value; + _createClass(ZWalletGenerator, [{ + key: 'handlePasswordPhrase', + value: function handlePasswordPhrase(e) { + // What wif format do we use? + var wifHash = this.props.settings.useTestNet ? _zencashjs2.default.config.testnet.wif : _zencashjs2.default.config.mainnet.wif; - if (e.keyCode === 9 && this.props.blurToSave || !this.validator(value)) { - return; - } + var pk = _zencashjs2.default.address.mkPrivKey(e.target.value); + var pkwif = _zencashjs2.default.address.privKeyToWIF(pk, true, wifHash); - if (e.keyCode === 13) { - this.props.completeEdit(value, this.props.rowIndex, this.props.colIndex); - } else { - this.props.onTab(this.props.rowIndex + 1, this.props.colIndex + 1, 'tab', e); - e.preventDefault(); - } - } else if (e.keyCode === 27) { - this.props.completeEdit(null, this.props.rowIndex, this.props.colIndex); - } else if (e.type === 'click' && !this.props.blurToSave) { - // textarea click save button - var _value = e.target.parentElement.firstChild.value; - if (!this.validator(_value)) { - return; - } - this.props.completeEdit(_value, this.props.rowIndex, this.props.colIndex); + if (e.target.value === '') { + pkwif = ''; } + + this.setState({ + privateKey: pkwif + }); } }, { - key: '__handleBlur__REACT_HOT_LOADER__', - value: function __handleBlur__REACT_HOT_LOADER__(e) { - e.stopPropagation(); - if (this.props.blurToSave) { - var value = e.currentTarget.type === 'checkbox' ? this._getCheckBoxValue(e) : e.currentTarget.value; - if (!this.validator(value)) { - return false; - } - this.props.completeEdit(value, this.props.rowIndex, this.props.colIndex); - } + key: 'render', + value: function render() { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + 'h3', + { className: 'display-6' }, + 'Generate New Address' + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement(_reactstrap.Input, { onChange: this.handlePasswordPhrase, placeholder: 'Password phrase. Do NOT forget to save this! Use >15 words to be safe.' }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement(_reactstrap.Input, { value: this.state.privateKey, placeholder: 'Private key generated from password phrase' }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement( + _reactCopyToClipboard2.default, + { text: this.state.privateKey }, + _react2.default.createElement( + _reactstrap.Button, + null, + _react2.default.createElement(_contentCopy2.default, null) + ) + ) + ) + ) + ); } - }, { - key: '__handleCustomUpdate__REACT_HOT_LOADER__', + }]); + return ZWalletGenerator; +}(_react2.default.Component); - // modified by iuculanop - // BEGIN - value: function __handleCustomUpdate__REACT_HOT_LOADER__(value) { - if (!this.validator(value)) { - return; - } - this.props.completeEdit(value, this.props.rowIndex, this.props.colIndex); - } - }, { - key: 'validator', - value: function validator(value) { - var ts = this; - var valid = true; - if (ts.props.editable.validator) { - var checkVal = ts.props.editable.validator(value, this.props.row); - var responseType = typeof checkVal === 'undefined' ? 'undefined' : _typeof(checkVal); - if (responseType !== 'object' && checkVal !== true) { - valid = false; - this.notifyToastr('error', checkVal, ''); - } else if (responseType === 'object' && checkVal.isValid !== true) { - valid = false; - this.notifyToastr(checkVal.notification.type, checkVal.notification.msg, checkVal.notification.title); - } - if (!valid) { - // animate input - ts.clearTimeout(); - var _props = this.props, - invalidColumnClassName = _props.invalidColumnClassName, - row = _props.row; - - var className = _util2.default.isFunction(invalidColumnClassName) ? invalidColumnClassName(value, row) : invalidColumnClassName; - ts.setState({ shakeEditor: true, className: className }); - ts.timeouteClear = setTimeout(function () { - ts.setState({ shakeEditor: false }); - }, 300); - this.focusInEditor(); - return valid; - } - } - return valid; - } - // END +var ZWalletUnlockKey = function (_React$Component3) { + _inherits(ZWalletUnlockKey, _React$Component3); - }, { - key: '__notifyToastr__REACT_HOT_LOADER__', - value: function __notifyToastr__REACT_HOT_LOADER__(type, message, title) { - var toastr = true; - var beforeShowError = this.props.beforeShowError; + function ZWalletUnlockKey(props) { + _classCallCheck(this, ZWalletUnlockKey); - if (beforeShowError) { - toastr = beforeShowError(type, message, title); - } - if (toastr) { - (0, _Notification.notice)(type, message, title); - } - } - }, { - key: 'clearTimeout', - value: function (_clearTimeout) { - function clearTimeout() { - return _clearTimeout.apply(this, arguments); - } + var _this3 = _possibleConstructorReturn(this, (ZWalletUnlockKey.__proto__ || Object.getPrototypeOf(ZWalletUnlockKey)).call(this, props)); - clearTimeout.toString = function () { - return _clearTimeout.toString(); - }; + _this3.unlockHDWallet = _this3.unlockHDWallet.bind(_this3); + _this3.loadWalletDat = _this3.loadWalletDat.bind(_this3); + _this3.toggleShowPassword = _this3.toggleShowPassword.bind(_this3); + _this3.unlockPrivateKeys = _this3.unlockPrivateKeys.bind(_this3); - return clearTimeout; - }(function () { - if (this.timeouteClear !== 0) { - clearTimeout(this.timeouteClear); - this.timeouteClear = 0; - } - }) - }, { - key: 'componentDidMount', - value: function componentDidMount() { - this.focusInEditor(); - var dom = _reactDom2.default.findDOMNode(this); - if (this.props.isFocus) { - dom.focus(); - } else { - dom.blur(); - } - } - }, { - key: 'componentDidUpdate', - value: function componentDidUpdate() { - var dom = _reactDom2.default.findDOMNode(this); - if (this.props.isFocus) { - dom.focus(); - } else { - dom.blur(); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.clearTimeout(); - } - }, { - key: 'focusInEditor', - value: function focusInEditor() { - if (this.inputRef && _util2.default.isFunction(this.inputRef.focus)) { - this.inputRef.focus(); + _this3.state = { + showPassword: false, + secretPhrase: '', + invalidPrivateKey: false, + secretPhraseTooShort: false, + + // Style for input button + inputFileStyle: { + WebkitAppearance: 'button', + cursor: 'pointer' } + }; + return _this3; + } + + _createClass(ZWalletUnlockKey, [{ + key: 'toggleShowPassword', + value: function toggleShowPassword() { + this.setState({ + showPassword: !this.state.showPassword + }); } }, { - key: '__handleClick__REACT_HOT_LOADER__', - value: function __handleClick__REACT_HOT_LOADER__(e) { - if (e.target.tagName !== 'TD') { - e.stopPropagation(); + key: 'unlockPrivateKeys', + value: function unlockPrivateKeys() { + // Success = return 0 + var success = this.props.handleUnlockPrivateKeys() === 0; + + if (!success) { + this.setState({ + invalidPrivateKey: true + }); } } }, { - key: '__getInputRef__REACT_HOT_LOADER__', - value: function __getInputRef__REACT_HOT_LOADER__(userRef) { - var _this2 = this; + key: 'unlockHDWallet', + value: function unlockHDWallet() { + try { + // Generate private keys from secret phrase + var pk = _hdwallet2.default.phraseToHDWallet(this.state.secretPhrase); - return function (ref) { - _this2.inputRef = ref; - if (_util2.default.isFunction(userRef)) { - userRef(ref); - } else if (typeof userRef === 'string') { - throw new Error('Ref must be a function'); - } - }; - } - }, { - key: '__getHandleKeyPress__REACT_HOT_LOADER__', - value: function __getHandleKeyPress__REACT_HOT_LOADER__(customHandler) { - var _this3 = this; + this.setState({ + secretPhraseTooShort: false + }); - return function (e) { - _this3.handleKeyPress(e); - if (_util2.default.isFunction(customHandler)) { - customHandler(e); - } - }; + // Set private key and unlock them (we know it'll work so no need to validate) + this.props.setPrivateKeys(pk, true); + } catch (err) { + this.setState({ + secretPhraseTooShort: true + }); + } } }, { - key: '__getHandleBlur__REACT_HOT_LOADER__', - value: function __getHandleBlur__REACT_HOT_LOADER__(customHandler) { + key: 'loadWalletDat', + value: function loadWalletDat(e) { var _this4 = this; - return function (e) { - _this4.handleBlur(e); - if (_util2.default.isFunction(customHandler)) { - customHandler(e); + var reader = new FileReader(); + var file = e.target.files[0]; + + // Read file callback function + reader.onloadend = function () { + // Get reader results in bytes + var dataHexStr = reader.result; + + // Retrieve private keys from wallet.dat + // Source: https://gist.github.com/moocowmoo/a715c80399bb202a65955771c465530c + var re = /\x30\x81\xD3\x02\x01\x01\x04\x20(.{32})/gm; + var privateKeys = dataHexStr.match(re); + privateKeys = privateKeys.map(function (x) { + x = x.replace('\x30\x81\xD3\x02\x01\x01\x04\x20', ''); + x = Buffer.from(x, 'latin1').toString('hex'); + return x; + }); + + // Set private key + _this4.props.setPrivateKeys(privateKeys); + + // Unlock private key + var success = _this4.props.handleUnlockPrivateKeys() === 0; + + if (!success) { + _this4.setState({ + invalidPrivateKey: true + }); } }; + + // Read file + reader.readAsBinaryString(file); } }, { key: 'render', value: function render() { - var _props2 = this.props, - editable = _props2.editable, - format = _props2.format, - customEditor = _props2.customEditor, - isFocus = _props2.isFocus, - customStyleWithNav = _props2.customStyleWithNav, - row = _props2.row, - attrs = _props2.attrs; - var shakeEditor = this.state.shakeEditor; - - var attr = _extends({}, editable.attrs, { - ref: this.getInputRef(editable.attrs && editable.attrs.ref), - onKeyDown: this.getHandleKeyPress(editable.attrs && editable.attrs.onKeyDown), - onBlur: this.getHandleBlur(editable.attrs && editable.attrs.onBlur) - }); - var style = { position: 'relative' }; - var fieldValue = this.props.fieldValue; - var className = this.state.className; - - - if (editable.placeholder) { - attr.placeholder = editable.placeholder; - /* eslint-disable no-console */ - console.warn('Setting editable.placeholder is deprecated. Use editable.attrs to set input attributes'); - /* eslint-enable no-console */ - } - - var editorClass = (0, _classnames2.default)({ 'animated': shakeEditor, 'shake': shakeEditor }); - fieldValue = fieldValue === 0 ? '0' : fieldValue; - var cellEditor = void 0; - if (customEditor) { - var customEditorProps = _extends({ - row: row - }, attr, { - defaultValue: this.valueShortCircuit(fieldValue) - }, customEditor.customEditorParameters); - cellEditor = customEditor.getElement(this.handleCustomUpdate, customEditorProps); - } else { - cellEditor = (0, _Editor2.default)(editable, attr, format, editorClass, this.valueShortCircuit(fieldValue), null, row); - } + var _this5 = this; - if (isFocus) { - if (customStyleWithNav) { - var customStyle = _util2.default.isFunction(customStyleWithNav) ? customStyleWithNav(fieldValue, row) : customStyleWithNav; - style = _extends({}, style, customStyle); - } else { - className = className + ' default-focus-cell'; - } + if (this.props.unlockType == UNLOCK_WALLET_TYPE.IMPORT_WALLET) { + return _react2.default.createElement( + _reactstrap.Form, + null, + _react2.default.createElement( + _reactstrap.FormGroup, + { row: true }, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.invalidPrivateKey ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Keys in files are corrupted' + ) : '', + _react2.default.createElement( + _reactstrap.Label, + { 'for': 'walletDatFile', className: 'btn btn-block btn-secondary', style: this.state.inputFileStyle }, + 'Select wallet.dat file', + _react2.default.createElement(_reactstrap.Input, { + style: { display: 'none' }, + type: 'file', + name: 'file', + id: 'walletDatFile', + onChange: this.loadWalletDat + }) + ), + _react2.default.createElement( + _reactstrap.FormText, + { color: 'muted' }, + 'For Windows, it should be in %APPDATA%/zen', + _react2.default.createElement('br', null), + 'For Mac/Linux, it should be in ~/.zen' + ) + ) + ) + ); + } else if (this.props.unlockType == UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY) { + return _react2.default.createElement( + 'div', + null, + this.state.invalidPrivateKey ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Invalid private key' + ) : '', + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { id: 4, + onClick: this.toggleShowPassword, + buttonText: this.state.showPassword ? _react2.default.createElement(_eye2.default, null) : _react2.default.createElement(_eyeSlash2.default, null), + tooltipText: this.state.showPassword ? 'show password' : 'hide password' + }) + ), + _react2.default.createElement(_reactstrap.Input, { + type: this.state.showPassword ? "text" : "password", + onChange: function onChange(e) { + return _this5.props.setPrivateKeys([e.target.value]); + } // Set it in a list so we can map over it later + , placeholder: 'Private key' + }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { onClick: this.unlockPrivateKeys, id: 3, buttonText: _react2.default.createElement(_unlockAlt2.default, null), tooltipText: 'unlock' }) + ) + ) + ); + } else if (this.props.unlockType == UNLOCK_WALLET_TYPE.HD_WALLET) { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + _reactstrap.Alert, + { color: 'warning' }, + _react2.default.createElement( + 'strong', + null, + 'Warning.' + ), + '\xA0Make sure you have saved your secret phrase somewhere.' + ), + this.state.secretPhraseTooShort ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + '\xA0Secret phrase too short' + ) : '', + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { id: 7, + onClick: this.toggleShowPassword, + buttonText: this.state.showPassword ? _react2.default.createElement(_eye2.default, null) : _react2.default.createElement(_eyeSlash2.default, null), + tooltipText: this.state.showPassword ? 'show phrase' : 'hide phrase' + }) + ), + _react2.default.createElement(_reactstrap.Input, { + type: this.state.showPassword ? "text" : "password", + maxLength: '64', + onChange: function onChange(e) { + return _this5.setState({ secretPhrase: e.target.value }); + }, + placeholder: 'Secret phrase. e.g. cash cow money heros cardboard money bag late green' + }), + _react2.default.createElement( + _reactstrap.InputGroupButton, + null, + _react2.default.createElement(ToolTipButton, { onClick: this.unlockHDWallet, id: 8, buttonText: _react2.default.createElement(_unlockAlt2.default, null), tooltipText: 'unlock HD wallet' }) + ) + ) + ); } - - return _react2.default.createElement( - 'td', - _extends({ ref: 'td' - }, attrs, { - style: style, - className: className, - onClick: this.handleClick }), - cellEditor - ); - } - }, { - key: '_getCheckBoxValue', - value: function _getCheckBoxValue(e) { - var value = ''; - var values = e.currentTarget.value.split(':'); - value = e.currentTarget.checked ? values[0] : values[1]; - return value; } }]); - return TableEditColumn; -}(_react.Component); - -TableEditColumn.propTypes = { - completeEdit: _propTypes2.default.func, - rowIndex: _propTypes2.default.number, - colIndex: _propTypes2.default.number, - blurToSave: _propTypes2.default.bool, - editable: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.object]), - format: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.func]), - row: _propTypes2.default.any, - fieldValue: _propTypes2.default.oneOfType([_propTypes2.default.string, _propTypes2.default.bool, _propTypes2.default.number, _propTypes2.default.array, _propTypes2.default.object]), - className: _propTypes2.default.any, - beforeShowError: _propTypes2.default.func, - isFocus: _propTypes2.default.bool, - attrs: _propTypes2.default.object, - customStyleWithNav: _propTypes2.default.oneOfType([_propTypes2.default.func, _propTypes2.default.object]) -}; - -var _default = TableEditColumn; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(TableEditColumn, 'TableEditColumn', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableEditColumn.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableEditColumn.js'); -}(); - -; - -/***/ }), -/* 378 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _classnames = __webpack_require__(29); - -var _classnames2 = _interopRequireDefault(_classnames); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } /* eslint max-len: 0 */ -/* eslint no-nested-ternary: 0 */ - + return ZWalletUnlockKey; +}(_react2.default.Component); -var ExpandComponent = function (_Component) { - _inherits(ExpandComponent, _Component); +var ZWalletSettings = function (_React$Component4) { + _inherits(ZWalletSettings, _React$Component4); - function ExpandComponent() { - _classCallCheck(this, ExpandComponent); + function ZWalletSettings() { + _classCallCheck(this, ZWalletSettings); - return _possibleConstructorReturn(this, (ExpandComponent.__proto__ || Object.getPrototypeOf(ExpandComponent)).apply(this, arguments)); + return _possibleConstructorReturn(this, (ZWalletSettings.__proto__ || Object.getPrototypeOf(ZWalletSettings)).apply(this, arguments)); } - _createClass(ExpandComponent, [{ + _createClass(ZWalletSettings, [{ key: 'render', value: function render() { - var className = this.props.className; + var _this7 = this; - var trCss = { - style: { - backgroundColor: this.props.bgColor - }, - className: (0, _classnames2.default)(className) - }; return _react2.default.createElement( - 'tr', - _extends({ hidden: this.props.hidden, width: this.props.width }, trCss), + _reactstrap.Modal, + { isOpen: this.props.settings.showSettings, toggle: this.props.toggleModalSettings }, _react2.default.createElement( - 'td', - { colSpan: this.props.colSpan }, - this.props.children + _reactstrap.ModalHeader, + { toggle: this.props.toggleShowSettings }, + 'ZenCash Wallet Settings' + ), + _react2.default.createElement( + _reactstrap.ModalBody, + null, + _react2.default.createElement(ZWalletSelectUnlockType, { + setUnlockType: this.props.setUnlockType, + unlockType: this.props.settings.unlockType + }) + ), + _react2.default.createElement( + _reactstrap.ModalBody, + null, + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Insight API' + ), + _react2.default.createElement(_reactstrap.Input, { + value: this.props.settings.insightAPI, + onChange: function onChange(e) { + return _this7.props.setInsightAPI(e.target.value); + } + }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + { sm: '6' }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { + disabled: !(this.props.publicAddresses === null), + defaultChecked: this.props.settings.compressPubKey, type: 'checkbox', + onChange: this.props.toggleCompressPubKey + }), + ' ', + 'Compress Public Key' + ) + ), + _react2.default.createElement( + _reactstrap.Col, + { sm: '6' }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { + defaultChecked: this.props.settings.showWalletGen, type: 'checkbox', + onChange: this.props.toggleShowWalletGen + }), + ' ', + 'Show Address Generator' + ) + ) + ) + ), + _react2.default.createElement( + _reactstrap.ModalFooter, + null, + _react2.default.createElement( + _reactstrap.Label, + null, + _react2.default.createElement(_reactstrap.Input, { + disabled: !(this.props.publicAddresses === null), + defaultChecked: this.props.settings.useTestNet, type: 'checkbox', + onChange: this.props.toggleUseTestNet + }), + ' ', + 'testnet' + ) ) ); } }]); - return ExpandComponent; -}(_react.Component); - -var _default = ExpandComponent; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(ExpandComponent, 'ExpandComponent', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/ExpandComponent.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/ExpandComponent.js'); -}(); - -; - -/***/ }), -/* 379 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _classnames = __webpack_require__(29); - -var _classnames2 = _interopRequireDefault(_classnames); - -var _PageButton = __webpack_require__(380); - -var _PageButton2 = _interopRequireDefault(_PageButton); - -var _SizePerPageDropDown = __webpack_require__(287); - -var _SizePerPageDropDown2 = _interopRequireDefault(_SizePerPageDropDown); - -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); - -var _util = __webpack_require__(68); + return ZWalletSettings; +}(_react2.default.Component); -var _util2 = _interopRequireDefault(_util); +var ZAddressInfo = function (_React$Component5) { + _inherits(ZAddressInfo, _React$Component5); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + function ZAddressInfo(props) { + _classCallCheck(this, ZAddressInfo); -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + var _this8 = _possibleConstructorReturn(this, (ZAddressInfo.__proto__ || Object.getPrototypeOf(ZAddressInfo)).call(this, props)); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + _this8.updateAddressInfo = _this8.updateAddressInfo.bind(_this8); + _this8.updateAddressesInfo = _this8.updateAddressesInfo.bind(_this8); + _this8.getAddressBlockExplorerURL = _this8.getAddressBlockExplorerURL.bind(_this8); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + _this8.state = { + retrieveAddressError: false + }; + return _this8; + } -var PaginationList = function (_Component) { - _inherits(PaginationList, _Component); + // Updates all address info - function PaginationList(props) { - _classCallCheck(this, PaginationList); - var _this = _possibleConstructorReturn(this, (PaginationList.__proto__ || Object.getPrototypeOf(PaginationList)).call(this, props)); + _createClass(ZAddressInfo, [{ + key: 'updateAddressesInfo', + value: function updateAddressesInfo() { + // The key is the address + // Value is the private key + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + this.updateAddressInfo(key); + } + }.bind(this)); + } - _this.changePage = function () { - return _this.__changePage__REACT_HOT_LOADER__.apply(_this, arguments); - }; + // Gets the blockchain explorer URL for an address - _this.changeSizePerPage = function () { - return _this.__changeSizePerPage__REACT_HOT_LOADER__.apply(_this, arguments); - }; + }, { + key: 'getAddressBlockExplorerURL', + value: function getAddressBlockExplorerURL(address) { + return _utils2.default.urlAppend(this.props.settings.explorerURL, 'address/') + address; + } - _this.toggleDropDown = function () { - return _this.__toggleDropDown__REACT_HOT_LOADER__.apply(_this, arguments); - }; + // Updates a address info - _this.state = { - open: _this.props.open - }; - return _this; - } + }, { + key: 'updateAddressInfo', + value: function updateAddressInfo(address) { + // GET request to URL + var info_url = _utils2.default.urlAppend(this.props.settings.insightAPI, 'addr/'); + info_url = _utils2.default.urlAppend(info_url, address + '?noTxList=1'); - _createClass(PaginationList, [{ - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps() { - var keepSizePerPageState = this.props.keepSizePerPageState; + throttledAxiosGet(info_url).then(function (response) { + var data = response.data; - if (!keepSizePerPageState) { - this.setState(function () { - return { open: false }; + this.props.setPublicAddressesKeyValue(address, 'confirmedBalance', data.balance); + this.props.setPublicAddressesKeyValue(address, 'unconfirmedBalance', data.unconfirmedBalance); + this.setState({ + retrieveAddressError: false }); - } - } - }, { - key: '__changePage__REACT_HOT_LOADER__', - value: function __changePage__REACT_HOT_LOADER__(page) { - var _props = this.props, - pageStartIndex = _props.pageStartIndex, - prePage = _props.prePage, - currPage = _props.currPage, - nextPage = _props.nextPage, - lastPage = _props.lastPage, - firstPage = _props.firstPage, - sizePerPage = _props.sizePerPage, - keepSizePerPageState = _props.keepSizePerPageState; - - - if (page === prePage) { - page = currPage - 1 < pageStartIndex ? pageStartIndex : currPage - 1; - } else if (page === nextPage) { - page = currPage + 1 > this.lastPage ? this.lastPage : currPage + 1; - } else if (page === lastPage) { - page = this.lastPage; - } else if (page === firstPage) { - page = pageStartIndex; - } else { - page = parseInt(page, 10); - } - - if (keepSizePerPageState) { - this.setState(function () { - return { open: false }; + }.bind(this)).catch(function (error) { + this.setState({ + retrieveAddressError: true }); - } - - if (page !== currPage) { - this.props.changePage(page, sizePerPage); - } + }.bind(this)); } }, { - key: '__changeSizePerPage__REACT_HOT_LOADER__', - value: function __changeSizePerPage__REACT_HOT_LOADER__(pageNum) { - var selectSize = typeof pageNum === 'string' ? parseInt(pageNum, 10) : pageNum; - var currPage = this.props.currPage; - - if (selectSize !== this.props.sizePerPage) { - this.totalPages = Math.ceil(this.props.dataSize / selectSize); - this.lastPage = this.props.pageStartIndex + this.totalPages - 1; - if (currPage > this.lastPage) currPage = this.lastPage; - this.props.changePage(currPage, selectSize); - if (this.props.onSizePerPageList) { - this.props.onSizePerPageList(selectSize); - } - } + key: 'componentDidMount', + value: function componentDidMount() { + // Run immediately + this.updateAddressesInfo(); - this.setState(function () { - return { open: false }; - }); + // Update every 30 seconds + this.interval = setInterval(this.updateAddressesInfo, 300000); } }, { - key: '__toggleDropDown__REACT_HOT_LOADER__', - value: function __toggleDropDown__REACT_HOT_LOADER__() { - var _this2 = this; - - this.setState(function () { - return { - open: !_this2.state.open - }; - }); + key: 'componentWillUnmount', + value: function componentWillUnmount() { + clearInterval(this.interval); } }, { key: 'render', value: function render() { - var _props2 = this.props, - currPage = _props2.currPage, - dataSize = _props2.dataSize, - sizePerPage = _props2.sizePerPage, - sizePerPageList = _props2.sizePerPageList, - paginationShowsTotal = _props2.paginationShowsTotal, - pageStartIndex = _props2.pageStartIndex, - paginationPanel = _props2.paginationPanel, - hidePageListOnlyOnePage = _props2.hidePageListOnlyOnePage; - - this.totalPages = Math.ceil(dataSize / sizePerPage); - this.lastPage = this.props.pageStartIndex + this.totalPages - 1; - var pageBtns = this.makePage(_util2.default.isFunction(paginationPanel)); - var dropdown = this.makeDropDown(); - - var offset = Math.abs(_Const2.default.PAGE_START_INDEX - pageStartIndex); - var start = (currPage - pageStartIndex) * sizePerPage; - start = dataSize === 0 ? 0 : start + 1; - var to = Math.min(sizePerPage * (currPage + offset) - 1, dataSize); - if (to >= dataSize) to--; - var total = paginationShowsTotal ? _react2.default.createElement( - 'span', - null, - 'Showing rows ', - start, - ' to\xA0', - to + 1, - ' of\xA0', - dataSize - ) : null; - - if (_util2.default.isFunction(paginationShowsTotal)) { - total = paginationShowsTotal(start, to + 1, dataSize); - } - - var content = paginationPanel && paginationPanel({ - currPage: currPage, - sizePerPage: sizePerPage, - sizePerPageList: sizePerPageList, - pageStartIndex: pageStartIndex, - changePage: this.changePage, - toggleDropDown: this.toggleDropDown, - changeSizePerPage: this.changeSizePerPage, - components: { - totalText: total, - sizePerPageDropdown: dropdown, - pageList: pageBtns - } - }); + var _this9 = this; - var hidePageList = hidePageListOnlyOnePage && this.totalPages === 1 ? 'none' : 'block'; - return _react2.default.createElement( - 'div', - { className: 'row', style: { marginTop: 15 } }, - content || [_react2.default.createElement( - 'div', - { key: 'paging-left', className: 'col-md-6 col-xs-6 col-sm-6 col-lg-6' }, - total, - sizePerPageList.length > 1 ? dropdown : null - ), _react2.default.createElement( - 'div', - { key: 'paging-right', style: { display: hidePageList }, - className: 'col-md-6 col-xs-6 col-sm-6 col-lg-6' }, - pageBtns - )] - ); - } - }, { - key: 'makeDropDown', - value: function makeDropDown() { - var _this3 = this; + // Key is the address + var addresses = []; + var totalConfirmed = 0.0; + var totalUnconfirmed = 0.0; + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + // Add to address + addresses.push({ + address: key, + privateKeyWIF: this.props.publicAddresses[key].privateKeyWIF, + confirmedBalance: this.props.publicAddresses[key].confirmedBalance, + unconfirmedBalance: this.props.publicAddresses[key].unconfirmedBalance + }); - var dropdown = void 0; - var dropdownProps = void 0; - var sizePerPageText = ''; - var _props3 = this.props, - sizePerPageDropDown = _props3.sizePerPageDropDown, - hideSizePerPage = _props3.hideSizePerPage, - sizePerPage = _props3.sizePerPage, - sizePerPageList = _props3.sizePerPageList; - - if (sizePerPageDropDown) { - dropdown = sizePerPageDropDown({ - open: this.state.open, - hideSizePerPage: hideSizePerPage, - currSizePerPage: String(sizePerPage), - sizePerPageList: sizePerPageList, - toggleDropDown: this.toggleDropDown, - changeSizePerPage: this.changeSizePerPage - }); - if (dropdown.type.name === _SizePerPageDropDown2.default.name) { - dropdownProps = dropdown.props; - } else { - return dropdown; + var c_confirmed = Number(this.props.publicAddresses[key].confirmedBalance); + var c_unconfirmed = Number(this.props.publicAddresses[key].unconfirmedBalance); + if (!isNaN(c_confirmed)) { + totalConfirmed += c_confirmed; + } + + if (!isNaN(c_unconfirmed)) { + totalUnconfirmed += c_unconfirmed; + } } - } + }.bind(this)); - if (dropdownProps || !dropdown) { - var sizePerPageOptions = sizePerPageList.map(function (_sizePerPage) { - var pageText = _sizePerPage.text || _sizePerPage; - var pageNum = _sizePerPage.value || _sizePerPage; - if (sizePerPage === pageNum) sizePerPageText = pageText; + var addressColumns = [{ + Header: 'Address', + accessor: 'address', + resizable: true, + Cell: function Cell(props) { return _react2.default.createElement( - 'li', - { key: pageText, role: 'presentation', className: 'dropdown-item' }, - _react2.default.createElement( - 'a', - { role: 'menuitem', - tabIndex: '-1', href: '#', - 'data-page': pageNum, - onClick: function onClick(e) { - e.preventDefault(); - _this3.changeSizePerPage(pageNum); - } }, - pageText - ) + 'a', + { href: _this9.getAddressBlockExplorerURL(props.value) }, + props.value + ); + } + }, { + Header: 'Confirmed', + accessor: 'confirmedBalance', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value ); - }); - dropdown = _react2.default.createElement(_SizePerPageDropDown2.default, _extends({ - open: this.state.open, - hidden: hideSizePerPage, - currSizePerPage: String(sizePerPageText), - options: sizePerPageOptions, - onClick: this.toggleDropDown - }, dropdownProps)); - } - return dropdown; - } - }, { - key: 'makePage', - value: function makePage() { - var _this4 = this; - - var isCustomPagingPanel = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false; - - var pages = this.getPages(); - var isStart = function isStart(page, _ref) { - var currPage = _ref.currPage, - pageStartIndex = _ref.pageStartIndex, - firstPage = _ref.firstPage, - prePage = _ref.prePage; - return currPage === pageStartIndex && (page === firstPage || page === prePage); - }; - var isEnd = function isEnd(page, _ref2) { - var currPage = _ref2.currPage, - nextPage = _ref2.nextPage, - lastPage = _ref2.lastPage; - return currPage === _this4.lastPage && (page === nextPage || page === lastPage); - }; - var pageBtns = pages.filter(function (page) { - if (this.props.alwaysShowAllBtns) { - return true; } - return isStart(page, this.props) || isEnd(page, this.props) ? false : true; - }, this).map(function (page) { - var isActive = page === this.props.currPage; - var isDisabled = isStart(page, this.props) || isEnd(page, this.props) ? true : false; - var title = page + ''; - - if (page === this.props.nextPage) { - title = this.props.nextPageTitle; - } else if (page === this.props.prePage) { - title = this.props.prePageTitle; - } else if (page === this.props.firstPage) { - title = this.props.firstPageTitle; - } else if (page === this.props.lastPage) { - title = this.props.lastPageTitle; + }, { + Header: 'Unconfirmed', + accessor: 'unconfirmedBalance', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); } + }]; - return _react2.default.createElement( - _PageButton2.default, - { key: page, - title: title, - changePage: this.changePage, - active: isActive, - disable: isDisabled }, - page - ); - }, this); - var classname = (0, _classnames2.default)(isCustomPagingPanel ? null : 'react-bootstrap-table-page-btns-ul', 'pagination'); return _react2.default.createElement( - 'ul', - { className: classname }, - pageBtns - ); - } - }, { - key: 'getLastPage', - value: function getLastPage() { - return this.lastPage; - } - }, { - key: 'getPages', - value: function getPages() { - var pages = void 0; - var endPage = this.totalPages; - if (endPage <= 0) return []; - var startPage = Math.max(this.props.currPage - Math.floor(this.props.paginationSize / 2), this.props.pageStartIndex); - endPage = startPage + this.props.paginationSize - 1; - - if (endPage > this.lastPage) { - endPage = this.lastPage; - startPage = endPage - this.props.paginationSize + 1; - } - - if (startPage !== this.props.pageStartIndex && this.totalPages > this.props.paginationSize && this.props.withFirstAndLast) { - pages = [this.props.firstPage, this.props.prePage]; - } else if (this.totalPages > 1 || this.props.alwaysShowAllBtns) { - pages = [this.props.prePage]; - } else { - pages = []; - } + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + this.state.retrieveAddressError ? _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + 'Error connecting to the Insight API. Double check the Insight API supplied in settings.' + ) : _react2.default.createElement( + _reactstrap.Alert, + { color: 'warning' }, + 'The balance displayed here is dependent on the insight node.', + _react2.default.createElement('br', null), + 'Automatically updates every 5 minutes. Alternatively, you can ', + _react2.default.createElement( + 'a', + { href: '#', onClick: function onClick() { + return _this9.updateAddressesInfo(); + } }, + 'forcefully refresh' + ), + ' them.' + ) + ) + ), + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement(_reactTable2.default, { + columns: [{ + Header: 'Total Confirmed', + accessor: 'totalConfirmed', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }, { + Header: 'Total Unconfirmed', + accessor: 'totalUnconfirmed', + Cell: function Cell(props) { + return _react2.default.createElement( + 'span', + { className: 'number' }, + props.value + ); + } + }], - for (var i = startPage; i <= endPage; i++) { - if (i >= this.props.pageStartIndex) pages.push(i); - } + data: [{ + totalConfirmed: totalConfirmed, + totalUnconfirmed: totalUnconfirmed + }], - if (endPage <= this.lastPage && pages.length > 1) { - pages.push(this.props.nextPage); - } - if (endPage !== this.lastPage && this.props.withFirstAndLast) { - pages.push(this.props.lastPage); - } + showPagination: false, - return pages; + minRows: 1 + }) + ) + ), + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement(_reactTable2.default, { + data: addresses, columns: addressColumns, + minRows: addresses.length > 20 ? 20 : addresses.length, + showPagination: addresses.length > 20 + }) + ) + ) + ) + ); } }]); - return PaginationList; -}(_react.Component); - -PaginationList.propTypes = { - currPage: _propTypes2.default.number, - sizePerPage: _propTypes2.default.number, - dataSize: _propTypes2.default.number, - changePage: _propTypes2.default.func, - sizePerPageList: _propTypes2.default.array, - paginationShowsTotal: _propTypes2.default.oneOfType([_propTypes2.default.bool, _propTypes2.default.func]), - paginationSize: _propTypes2.default.number, - onSizePerPageList: _propTypes2.default.func, - prePage: _propTypes2.default.string, - pageStartIndex: _propTypes2.default.number, - hideSizePerPage: _propTypes2.default.bool, - alwaysShowAllBtns: _propTypes2.default.bool, - withFirstAndLast: _propTypes2.default.bool, - sizePerPageDropDown: _propTypes2.default.func, - paginationPanel: _propTypes2.default.func, - prePageTitle: _propTypes2.default.string, - nextPageTitle: _propTypes2.default.string, - firstPageTitle: _propTypes2.default.string, - lastPageTitle: _propTypes2.default.string, - hidePageListOnlyOnePage: _propTypes2.default.bool, - keepSizePerPageState: _propTypes2.default.bool -}; - -PaginationList.defaultProps = { - sizePerPage: _Const2.default.SIZE_PER_PAGE, - pageStartIndex: _Const2.default.PAGE_START_INDEX -}; - -var _default = PaginationList; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(PaginationList, 'PaginationList', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/pagination/PaginationList.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/pagination/PaginationList.js'); -}(); - -; - -/***/ }), -/* 380 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -var _classnames = __webpack_require__(29); - -var _classnames2 = _interopRequireDefault(_classnames); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + return ZAddressInfo; +}(_react2.default.Component); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +var ZSendZEN = function (_React$Component6) { + _inherits(ZSendZEN, _React$Component6); -var PageButton = function (_Component) { - _inherits(PageButton, _Component); + function ZSendZEN(props) { + _classCallCheck(this, ZSendZEN); - function PageButton(props) { - _classCallCheck(this, PageButton); + var _this10 = _possibleConstructorReturn(this, (ZSendZEN.__proto__ || Object.getPrototypeOf(ZSendZEN)).call(this, props)); - var _this = _possibleConstructorReturn(this, (PageButton.__proto__ || Object.getPrototypeOf(PageButton)).call(this, props)); + _this10.setProgressValue = _this10.setProgressValue.bind(_this10); + _this10.setSendErrorMessage = _this10.setSendErrorMessage.bind(_this10); + _this10.handleUpdateSelectedAddress = _this10.handleUpdateSelectedAddress.bind(_this10); + _this10.handleUpdateRecipientAddress = _this10.handleUpdateRecipientAddress.bind(_this10); + _this10.handleUpdateAmount = _this10.handleUpdateAmount.bind(_this10); + _this10.handleCheckChanged = _this10.handleCheckChanged.bind(_this10); + _this10.handleUpdateFee = _this10.handleUpdateFee.bind(_this10); + _this10.handleSendZEN = _this10.handleSendZEN.bind(_this10); - _this.pageBtnClick = function () { - return _this.__pageBtnClick__REACT_HOT_LOADER__.apply(_this, arguments); + _this10.state = { + selectedAddress: '', // which address did we select + recipientAddress: '', + fee: '', + amount: '', + sentTxid: '', // Whats the send txid + sendProgress: 0, // Progress bar, 100 to indicate complete + sendErrorMessage: '', + confirmSend: false }; - - return _this; + return _this10; } - _createClass(PageButton, [{ - key: '__pageBtnClick__REACT_HOT_LOADER__', - value: function __pageBtnClick__REACT_HOT_LOADER__(e) { - e.preventDefault(); - this.props.changePage(e.currentTarget.textContent); + _createClass(ZSendZEN, [{ + key: 'handleUpdateSelectedAddress', + value: function handleUpdateSelectedAddress(e) { + this.setState({ + selectedAddress: e.target.value + }); } }, { - key: 'render', - value: function render() { - var classes = (0, _classnames2.default)({ - 'active': this.props.active, - 'disabled': this.props.disable, - 'hidden': this.props.hidden, - 'page-item': true + key: 'handleUpdateRecipientAddress', + value: function handleUpdateRecipientAddress(e) { + this.setState({ + recipientAddress: e.target.value + }); + } + }, { + key: 'handleUpdateFee', + value: function handleUpdateFee(e) { + this.setState({ + fee: e.target.value + }); + } + }, { + key: 'handleUpdateAmount', + value: function handleUpdateAmount(e) { + this.setState({ + amount: e.target.value + }); + } + }, { + key: 'handleCheckChanged', + value: function handleCheckChanged(e) { + this.setState({ + confirmSend: e.target.checked + }); + } + }, { + key: 'setProgressValue', + value: function setProgressValue(v) { + this.setState({ + sendProgress: v + }); + } + }, { + key: 'setSendErrorMessage', + value: function setSendErrorMessage(msg) { + this.setState({ + sendErrorMessage: msg }); - return _react2.default.createElement( - 'li', - { className: classes, title: this.props.title }, - _react2.default.createElement( - 'a', - { href: '#', onClick: this.pageBtnClick, className: 'page-link' }, - this.props.children - ) - ); } - }]); - - return PageButton; -}(_react.Component); - -PageButton.propTypes = { - title: _propTypes2.default.string, - changePage: _propTypes2.default.func, - active: _propTypes2.default.bool, - disable: _propTypes2.default.bool, - hidden: _propTypes2.default.bool, - children: _propTypes2.default.node -}; - -var _default = PageButton; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(PageButton, 'PageButton', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/pagination/PageButton.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/pagination/PageButton.js'); -}(); - -; - -/***/ }), -/* 381 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - + }, { + key: 'handleSendZEN', + value: function handleSendZEN() { + var value = this.state.amount; + var fee = this.state.fee; + var recipientAddress = this.state.recipientAddress; + var senderAddress = this.state.selectedAddress; -Object.defineProperty(exports, "__esModule", { - value: true -}); + // Convert how much we wanna send + // to satoshis + var satoshisToSend = Math.round(value * 100000000); + var satoshisfeesToSend = Math.round(fee * 100000000); -var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); + // Reset zen send progress and error message + this.setProgressValue(1); + this.setSendErrorMessage(''); -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; + // Error strings + var errString = ''; -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + // Validation + if (senderAddress === '') { + errString += '`From Address` field can\'t be empty.;'; + } -var _react = __webpack_require__(4); + if (recipientAddress.length !== 35) { + errString += 'Invalid address. Only transparent addresses are supported at this point in time.;'; + } -var _react2 = _interopRequireDefault(_react); + if (typeof parseInt(value) !== 'number' || value === '') { + errString += 'Invalid amount.;'; + } -var _propTypes = __webpack_require__(9); + // Can't send 0 satoshis + if (satoshisToSend <= 0) { + errString += 'Amount must be greater than 0.;'; + } -var _propTypes2 = _interopRequireDefault(_propTypes); + if (typeof parseInt(fee) !== 'number' || fee === '') { + errString += 'Invalid fee.;'; + } -var _reactModal = __webpack_require__(382); + if (errString !== '') { + this.setSendErrorMessage(errString); + this.setProgressValue(0); + return; + } -var _reactModal2 = _interopRequireDefault(_reactModal); + // Private key + var senderPrivateKey = this.props.publicAddresses[senderAddress].privateKey; -var _Const = __webpack_require__(22); + // Get previous transactions + var prevTxURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'addr/') + senderAddress + '/utxo'; + var infoURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'status?q=getInfo'); + var sendRawTxURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'tx/send'); -var _Const2 = _interopRequireDefault(_Const); + // Building our transaction TXOBJ + // How many satoshis do we have so far + var satoshisSoFar = 0; + var history = []; + var recipients = [{ address: recipientAddress, satoshis: satoshisToSend }]; -var _Notification = __webpack_require__(286); + // Get transactions and info + _axios2.default.get(prevTxURL).then(function (tx_resp) { + this.setProgressValue(25); -var _InsertModal = __webpack_require__(391); + var tx_data = tx_resp.data; -var _InsertModal2 = _interopRequireDefault(_InsertModal); + _axios2.default.get(infoURL).then(function (info_resp) { + this.setProgressValue(50); + var info_data = info_resp.data; -var _InsertButton = __webpack_require__(295); + var blockHeight = info_data.info.blocks - 300; + var blockHashURL = _utils2.default.urlAppend(this.props.settings.insightAPI, 'block-index/') + blockHeight; -var _InsertButton2 = _interopRequireDefault(_InsertButton); + // Get block hash + _axios2.default.get(blockHashURL).then(function (response_bhash) { + this.setProgressValue(75); -var _DeleteButton = __webpack_require__(296); + var blockHash = response_bhash.data.blockHash; -var _DeleteButton2 = _interopRequireDefault(_DeleteButton); + // Iterate through each utxo + // append it to history + for (var i = 0; i < tx_data.length; i++) { + if (tx_data[i].confirmations == 0) { + continue; + } -var _ExportCSVButton = __webpack_require__(297); + history = history.concat({ + txid: tx_data[i].txid, + vout: tx_data[i].vout, + scriptPubKey: tx_data[i].scriptPubKey + }); -var _ExportCSVButton2 = _interopRequireDefault(_ExportCSVButton); + // How many satoshis do we have so far + satoshisSoFar = satoshisSoFar + tx_data[i].satoshis; + if (satoshisSoFar >= satoshisToSend + satoshisfeesToSend) { + break; + } + } -var _ShowSelectedOnlyButton = __webpack_require__(298); + // If we don't have enough address + // fail and tell user + if (satoshisSoFar < satoshisToSend + satoshisfeesToSend) { + this.setSendErrorMessage('Not enough confirmed ZEN in account to perform transaction'); + this.setProgressValue(0); + } -var _ShowSelectedOnlyButton2 = _interopRequireDefault(_ShowSelectedOnlyButton); + // If we don't have exact amount + // Refund remaining to current address + if (satoshisSoFar !== satoshisToSend + satoshisfeesToSend) { + var refundSatoshis = satoshisSoFar - satoshisToSend - satoshisfeesToSend; + recipients = recipients.concat({ address: senderAddress, satoshis: refundSatoshis }); + } -var _SearchField = __webpack_require__(299); + // Create transaction + var txObj = _zencashjs2.default.transaction.createRawTx(history, recipients, blockHeight, blockHash); -var _SearchField2 = _interopRequireDefault(_SearchField); + // Sign each history transcation + for (var i = 0; i < history.length; i++) { + txObj = _zencashjs2.default.transaction.signTx(txObj, i, senderPrivateKey, this.props.settings.compressPubKey); + } -var _ClearSearchButton = __webpack_require__(300); + // Convert it to hex string + var txHexString = _zencashjs2.default.transaction.serializeTx(txObj); -var _ClearSearchButton2 = _interopRequireDefault(_ClearSearchButton); + _axios2.default.post(sendRawTxURL, { rawtx: txHexString }).then(function (sendtx_resp) { + this.setState({ + sendProgress: 100, + sentTxid: sendtx_resp.data.txid + }); + }.bind(this)).catch(function (error) { + this.setSendErrorMessage(error + ''); + this.setProgressValue(0); + return; + }.bind(this)); + }.bind(this)); + }.bind(this)); + }.bind(this)).catch(function (error) { + this.setSendErrorMessage(error); + this.setProgressValue(0); + return; + }.bind(this)); + } + }, { + key: 'render', + value: function render() { + // If send was successful + var zenTxLink; + if (this.state.sendProgress === 100) { + var zentx = _utils2.default.urlAppend(this.props.settings.explorerURL, 'tx/') + this.state.sentTxid; + zenTxLink = _react2.default.createElement( + _reactstrap.Alert, + { color: 'success' }, + _react2.default.createElement( + 'strong', + null, + 'ZEN successfully sent!' + ), + ' ', + _react2.default.createElement( + 'a', + { href: zentx }, + 'Click here to view your transaction' + ) + ); + } -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + // Else show error why + else if (this.state.sendErrorMessage !== '') { + zenTxLink = this.state.sendErrorMessage.split(';').map(function (s) { + if (s !== '') { + return _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + _react2.default.createElement( + 'strong', + null, + 'Error.' + ), + ' ', + s + ); + } + }); + } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + // Send addresses + // Key is the address btw + var sendAddresses = []; + Object.keys(this.props.publicAddresses).forEach(function (key) { + if (key !== undefined) { + sendAddresses.push(_react2.default.createElement( + 'option', + { value: key }, + '[', + this.props.publicAddresses[key].confirmedBalance, + '] - ', + key + )); + } + }.bind(this)); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + return _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement( + _reactstrap.Alert, + { color: 'danger' }, + 'ALWAYS VALIDATE YOUR DESINATION ADDRESS BY SENDING SMALL AMOUNTS OF ZEN FIRST' + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'From Address' + ), + _react2.default.createElement( + _reactstrap.Input, + { type: 'select', onChange: this.handleUpdateSelectedAddress }, + _react2.default.createElement('option', { value: '' }), + sendAddresses + ) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'To Address' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateRecipientAddress, placeholder: 'e.g znSDvF9nA5VCdse5HbEKmsoNbjCbsEA3VAH' }) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Amount' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateAmount, placeholder: 'e.g 42' }) + ), + _react2.default.createElement( + _reactstrap.InputGroup, + null, + _react2.default.createElement( + _reactstrap.InputGroupAddon, + null, + 'Fee' + ), + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleUpdateFee, placeholder: 'e.g 0.001' }) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.FormGroup, + { check: true }, + _react2.default.createElement( + _reactstrap.Label, + { check: true }, + _react2.default.createElement(_reactstrap.Input, { onChange: this.handleCheckChanged, type: 'checkbox' }), + ' ', + 'Yes, I would like to send these ZEN' + ) + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.Button, + { + color: 'warning', className: 'btn-block', + disabled: !this.state.confirmSend || this.state.sendProgress > 0 && this.state.sendProgress < 100, + onClick: this.handleSendZEN + }, + 'Send' + ) + ), + _react2.default.createElement( + _reactstrap.CardFooter, + null, + zenTxLink, + _react2.default.createElement(_reactstrap.Progress, { value: this.state.sendProgress }) + ) + ) + ) + ); + } + }]); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } /* eslint no-console: 0 */ + return ZSendZEN; +}(_react2.default.Component); -// import classSet from 'classnames'; +var ZWalletSelectUnlockType = function (_React$Component7) { + _inherits(ZWalletSelectUnlockType, _React$Component7); -// import editor from '../Editor'; + function ZWalletSelectUnlockType(props) { + _classCallCheck(this, ZWalletSelectUnlockType); + var _this11 = _possibleConstructorReturn(this, (ZWalletSelectUnlockType.__proto__ || Object.getPrototypeOf(ZWalletSelectUnlockType)).call(this, props)); -var ToolBar = function (_Component) { - _inherits(ToolBar, _Component); + _this11.state = { cSelected: _this11.props.unlockType }; + return _this11; + } - function ToolBar(props) { - var _arguments = arguments; + _createClass(ZWalletSelectUnlockType, [{ + key: 'onRadioBtnClick', + value: function onRadioBtnClick(s) { + this.setState({ + cSelected: s + }); - _classCallCheck(this, ToolBar); + this.props.setUnlockType(s); + } + }, { + key: 'render', + value: function render() { + var _this12 = this; - var _this = _possibleConstructorReturn(this, (ToolBar.__proto__ || Object.getPrototypeOf(ToolBar)).call(this, props)); + return _react2.default.createElement( + 'div', + { style: { textAlign: 'center' } }, + _react2.default.createElement( + _reactstrap.ButtonGroup, + { vertical: true }, + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.HD_WALLET); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.HD_WALLET }, + 'Enter secret phrase' + ), + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.IMPORT_WALLET); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.IMPORT_WALLET }, + 'Load wallet.dat' + ), + _react2.default.createElement( + _reactstrap.Button, + { color: 'secondary', onClick: function onClick() { + return _this12.onRadioBtnClick(UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY); + }, active: this.state.cSelected === UNLOCK_WALLET_TYPE.PASTE_PRIV_KEY }, + 'Paste private key' + ) + ) + ); + } + }]); - _this.displayCommonMessage = function () { - return _this.__displayCommonMessage__REACT_HOT_LOADER__.apply(_this, arguments); - }; + return ZWalletSelectUnlockType; +}(_react2.default.Component); - _this.handleSaveBtnClick = function () { - return _this.__handleSaveBtnClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; +var ZWalletTabs = function (_React$Component8) { + _inherits(ZWalletTabs, _React$Component8); - _this.afterHandleSaveBtnClick = function () { - return _this.__afterHandleSaveBtnClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; + function ZWalletTabs(props) { + _classCallCheck(this, ZWalletTabs); - _this.handleModalClose = function () { - return _this.__handleModalClose__REACT_HOT_LOADER__.apply(_this, arguments); - }; + var _this13 = _possibleConstructorReturn(this, (ZWalletTabs.__proto__ || Object.getPrototypeOf(ZWalletTabs)).call(this, props)); - _this.handleModalOpen = function () { - return _this.__handleModalOpen__REACT_HOT_LOADER__.apply(_this, arguments); + _this13.toggleTabs = _this13.toggleTabs.bind(_this13); + _this13.savePrivateKeys = _this13.savePrivateKeys.bind(_this13); + _this13.state = { + activeTab: '1' }; + return _this13; + } - _this.handleShowOnlyToggle = function () { - return _this.__handleShowOnlyToggle__REACT_HOT_LOADER__.apply(_this, arguments); - }; + _createClass(ZWalletTabs, [{ + key: 'toggleTabs', + value: function toggleTabs(tab) { + if (this.state.activeTab !== tab) { + this.setState({ + activeTab: tab + }); + } + } + }, { + key: 'savePrivateKeys', + value: function savePrivateKeys() { + // ISO 8601 + var now = new Date(); + now = now.toISOString().split('.')[0] + 'Z'; - _this.handleDropRowBtnClick = function () { - return _this.__handleDropRowBtnClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; + var fileStr = '# Wallet dump created by myzenwallet ' + _package2.default.version + '\n'; + fileStr += '# Created on ' + now + '\n\n\n'; - _this.handleDebounce = function (func, wait, immediate) { - var timeout = void 0; + Object.keys(this.props.publicAddresses).forEach(function (key) { + fileStr += this.props.publicAddresses[key].privateKeyWIF; + fileStr += ' ' + now + ' ' + 'label=' + ' ' + '# addr=' + key; + fileStr += '\n'; + }.bind(this)); - return function () { - var later = function later() { - timeout = null; + var pkBlob = new Blob([fileStr], { type: 'text/plain;charset=utf-8' }); + _fileSaver2.default.saveAs(pkBlob, now + '_myzenwallet_private_keys.txt'); + } + }, { + key: 'render', + value: function render() { + var _this14 = this; - if (!immediate) { - func.apply(_this, _arguments); - } - }; + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement( + _reactstrap.Nav, + { tabs: true }, + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '1' }), + onClick: function onClick() { + _this14.toggleTabs('1'); + } + }, + 'Info' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '2' }), + onClick: function onClick() { + _this14.toggleTabs('2'); + } + }, + 'Send ZEN' + ) + ), + _react2.default.createElement( + _reactstrap.NavItem, + null, + _react2.default.createElement( + _reactstrap.NavLink, + { + className: (0, _classnames2.default)({ active: this.state.activeTab === '3' }), + onClick: function onClick() { + _this14.toggleTabs('3'); + } + }, + 'Export' + ) + ) + ), + _react2.default.createElement( + _reactstrap.TabContent, + { activeTab: this.state.activeTab }, + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '1' }, + _react2.default.createElement(ZAddressInfo, { + publicAddresses: this.props.publicAddresses, + settings: this.props.settings, + setPublicAddressesKeyValue: this.props.setPublicAddressesKeyValue + }) + ), + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '2' }, + _react2.default.createElement(ZSendZEN, { + settings: this.props.settings, + publicAddresses: this.props.publicAddresses + }) + ), + _react2.default.createElement( + _reactstrap.TabPane, + { tabId: '3' }, + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + _reactstrap.Card, + null, + _react2.default.createElement( + _reactstrap.CardBlock, + null, + _react2.default.createElement( + _reactstrap.Button, + { + color: 'secondary', className: 'btn-block', + onClick: this.savePrivateKeys + }, + 'Download Private Keys' + ) + ) + ) + ) + ) + ) + ) + ); + } + }]); - var callNow = immediate && !timeout; + return ZWalletTabs; +}(_react2.default.Component); - clearTimeout(timeout); +var ZWallet = function (_React$Component9) { + _inherits(ZWallet, _React$Component9); - timeout = setTimeout(later, wait || 0); + function ZWallet(props) { + _classCallCheck(this, ZWallet); - if (callNow) { - func.appy(_this, _arguments); - } - }; - }; + var _this15 = _possibleConstructorReturn(this, (ZWallet.__proto__ || Object.getPrototypeOf(ZWallet)).call(this, props)); - _this.handleKeyUp = function () { - return _this.__handleKeyUp__REACT_HOT_LOADER__.apply(_this, arguments); - }; + _this15.resetKeys = _this15.resetKeys.bind(_this15); + _this15.handleUnlockPrivateKeys = _this15.handleUnlockPrivateKeys.bind(_this15); + _this15.setPrivateKeys = _this15.setPrivateKeys.bind(_this15); + _this15.setInsightAPI = _this15.setInsightAPI.bind(_this15); + _this15.setUnlockType = _this15.setUnlockType.bind(_this15); + _this15.setPublicAddressesKeyValue = _this15.setPublicAddressesKeyValue.bind(_this15); + _this15.toggleUseTestNet = _this15.toggleUseTestNet.bind(_this15); + _this15.toggleCompressPubKey = _this15.toggleCompressPubKey.bind(_this15); + _this15.toggleShowSettings = _this15.toggleShowSettings.bind(_this15); + _this15.toggleShowWalletGen = _this15.toggleShowWalletGen.bind(_this15); - _this.handleExportCSV = function () { - return _this.__handleExportCSV__REACT_HOT_LOADER__.apply(_this, arguments); + _this15.state = { + privateKeys: '', + publicAddresses: null, // Public address will be {address: {privateKey: '', transactionURL: '', privateKeyWIF: ''} + settings: { + showSettings: false, + showWalletGen: false, + compressPubKey: true, + insightAPI: 'https://explorer.zensystem.io/insight-api-zen/', + explorerURL: 'https://explorer.zensystem.io/', + useTestNet: false, + unlockType: UNLOCK_WALLET_TYPE.HD_WALLET + } }; + return _this15; + } - _this.handleClearBtnClick = function () { - return _this.__handleClearBtnClick__REACT_HOT_LOADER__.apply(_this, arguments); - }; + _createClass(ZWallet, [{ + key: 'handleUnlockPrivateKeys', + value: function handleUnlockPrivateKeys() { + if (this.state.privateKeys.length === 0) { + return -2; + } - _this.timeouteClear = 0; - _this.modalClassName; - _this.state = { - isInsertModalOpen: false, - validateState: null, - shakeEditor: false, - showSelected: false - }; - return _this; - } + try { + var _privKeyToAddr = function _privKeyToAddr(pk, compressPubKey, useTestNet) { + // If not 64 length, probs WIF format + if (pk.length !== 64) { + pk = _zencashjs2.default.address.WIFToPrivKey(pk); + } - _createClass(ToolBar, [{ - key: 'componentWillMount', - value: function componentWillMount() { - var _this2 = this; + // Convert public key to public address + var pubKey = _zencashjs2.default.address.privKeyToPubKey(pk, compressPubKey); - var delay = this.props.searchDelayTime ? this.props.searchDelayTime : 0; - this.debounceCallback = this.handleDebounce(function () { - var seachInput = _this2.refs.seachInput; + // Testnet or nah + var pubKeyHash = useTestNet ? _zencashjs2.default.config.testnet.pubKeyHash : _zencashjs2.default.config.mainnet.pubKeyHash; + var publicAddr = _zencashjs2.default.address.pubKeyToAddr(pubKey, pubKeyHash); - seachInput && _this2.props.onSearch(seachInput.getValue()); - }, delay); - } - }, { - key: 'componentWillReceiveProps', - value: function componentWillReceiveProps(nextProps) { - if (nextProps.reset) { - this.setSearchInput(''); - } - } - }, { - key: 'componentWillUnmount', - value: function componentWillUnmount() { - this.clearTimeout(); - } - }, { - key: 'setSearchInput', - value: function setSearchInput(text) { - var seachInput = this.refs.seachInput; + return publicAddr; + }; - if (seachInput && seachInput.value !== text) { - seachInput.value = text; - } - } - }, { - key: 'clearTimeout', - value: function (_clearTimeout) { - function clearTimeout() { - return _clearTimeout.apply(this, arguments); - } + var publicAddresses = {}; - clearTimeout.toString = function () { - return _clearTimeout.toString(); - }; + for (var i = 0; i < this.state.privateKeys.length; i++) { + var pubKeyHash = this.state.settings.useTestNet ? _zencashjs2.default.config.testnet.wif : _zencashjs2.default.config.mainnet.wif; - return clearTimeout; - }(function () { - if (this.timeouteClear) { - clearTimeout(this.timeouteClear); - this.timeouteClear = 0; - } - }) - }, { - key: '__displayCommonMessage__REACT_HOT_LOADER__', - value: function __displayCommonMessage__REACT_HOT_LOADER__() { - (0, _Notification.notice)('error', this.props.insertFailIndicator, ''); - } - }, { - key: 'validateNewRow', - value: function validateNewRow(newRow) { - var _this3 = this; + var c_pk_wif; + var c_pk = this.state.privateKeys[i]; - var validateState = {}; - var isValid = true; - var tempMsg = void 0; - var responseType = void 0; - - this.props.columns.forEach(function (column) { - if (column.isKey && column.keyValidator) { - // key validator for checking exist key - tempMsg = _this3.props.isValidKey(newRow[column.field]); - if (tempMsg) { - _this3.displayCommonMessage(); - isValid = false; - validateState[column.field] = tempMsg; - } - } else if (column.editable && column.editable.validator) { - // process validate - tempMsg = column.editable.validator(newRow[column.field], newRow); - responseType = typeof tempMsg === 'undefined' ? 'undefined' : _typeof(tempMsg); - if (responseType !== 'object' && tempMsg !== true) { - _this3.displayCommonMessage(); - isValid = false; - validateState[column.field] = tempMsg; - } else if (responseType === 'object' && tempMsg.isValid !== true) { - (0, _Notification.notice)(tempMsg.notification.type, tempMsg.notification.msg, tempMsg.notification.title); - isValid = false; - validateState[column.field] = tempMsg.notification.msg; + // If not 64 length, probs WIF format + if (c_pk.length !== 64) { + c_pk_wif = c_pk; + c_pk = _zencashjs2.default.address.WIFToPrivKey(c_pk); + } else { + c_pk_wif = _zencashjs2.default.address.privKeyToWIF(c_pk); } + + var c_pk_wif = _zencashjs2.default.address.privKeyToWIF(c_pk, true, pubKeyHash); + var c_addr = _privKeyToAddr(c_pk, this.state.settings.compressPubKey, this.state.settings.useTestNet); + + publicAddresses[c_addr] = { + privateKey: c_pk, + privateKeyWIF: c_pk_wif, + confirmedBalance: 'loading...', + unconfirmedBalance: 'loading...' + }; } - }); - if (isValid) { - return true; - } else { - this.clearTimeout(); - // show error in form and shake it - this.setState(function () { - return { validateState: validateState, shakeEditor: true }; - }); - this.timeouteClear = setTimeout(function () { - _this3.setState(function () { - return { shakeEditor: false }; - }); - }, 300); - return null; + // Set public address + this.setPublicAddresses(publicAddresses); + + // Return success + return 0; + } catch (err) { + this.setPublicAddresses(null); + return -1; } } }, { - key: '__handleSaveBtnClick__REACT_HOT_LOADER__', - value: function __handleSaveBtnClick__REACT_HOT_LOADER__(newRow) { - if (!this.validateNewRow(newRow)) { - // validation fail - return; - } - var msg = this.props.onAddRow(newRow); - if (msg !== false) { - this.afterHandleSaveBtnClick(msg); - } + key: 'resetKeys', + value: function resetKeys() { + this.setState({ + privateKeys: '', + publicAddresses: null + }); } - }, { - key: '__afterHandleSaveBtnClick__REACT_HOT_LOADER__', - value: function __afterHandleSaveBtnClick__REACT_HOT_LOADER__(msg) { - var _this4 = this; - if (msg) { - (0, _Notification.notice)('error', msg, ''); - this.clearTimeout(); - // shake form and hack prevent modal hide - this.setState(function () { - return { - shakeEditor: true, - validateState: 'this is hack for prevent bootstrap modal hide' - }; - }); - // clear animate class - this.timeouteClear = setTimeout(function () { - _this4.setState(function () { - return { shakeEditor: false }; - }); - }, 300); - } else { - // reset state and hide modal hide - this.setState(function () { - return { - validateState: null, - shakeEditor: false, - isInsertModalOpen: false - }; - }); + // Only used for bip32 gen wallet because + // of the async nature + + }, { + key: 'setPrivateKeys', + value: function setPrivateKeys(pk, handleUnlockingKeys) { + if (handleUnlockingKeys === undefined) { + handleUnlockingKeys = false; } + this.setState({ + privateKeys: pk + }, handleUnlockingKeys ? this.handleUnlockPrivateKeys : undefined); } }, { - key: '__handleModalClose__REACT_HOT_LOADER__', - value: function __handleModalClose__REACT_HOT_LOADER__() { - this.setState(function () { - return { isInsertModalOpen: false }; + key: 'setPublicAddresses', + value: function setPublicAddresses(pa) { + this.setState({ + publicAddresses: pa }); } }, { - key: '__handleModalOpen__REACT_HOT_LOADER__', - value: function __handleModalOpen__REACT_HOT_LOADER__() { - this.setState(function () { - return { isInsertModalOpen: true }; + key: 'setPublicAddressesKeyValue', + value: function setPublicAddressesKeyValue(address, key, value) { + var newPublicAddresses = this.state.publicAddresses; + newPublicAddresses[address][key] = value; + + this.setState({ + publicAddresses: newPublicAddresses }); } }, { - key: '__handleShowOnlyToggle__REACT_HOT_LOADER__', - value: function __handleShowOnlyToggle__REACT_HOT_LOADER__() { - var _this5 = this; + key: 'setInsightAPI', + value: function setInsightAPI(uri) { + var _settings = this.state.settings; + _settings.insightAPI = uri; - this.setState(function () { - return { - showSelected: !_this5.state.showSelected - }; + this.setState({ + _settings: _settings }); - this.props.onShowOnlySelected(); - } - }, { - key: '__handleDropRowBtnClick__REACT_HOT_LOADER__', - value: function __handleDropRowBtnClick__REACT_HOT_LOADER__() { - this.props.onDropRow(); } }, { - key: 'handleCloseBtn', - value: function handleCloseBtn() { - this.refs.warning.style.display = 'none'; - } - }, { - key: '__handleKeyUp__REACT_HOT_LOADER__', - value: function __handleKeyUp__REACT_HOT_LOADER__(event) { - event.persist(); - this.debounceCallback(event); - } - }, { - key: '__handleExportCSV__REACT_HOT_LOADER__', - value: function __handleExportCSV__REACT_HOT_LOADER__() { - this.props.onExportCSV(); + key: 'setUnlockType', + value: function setUnlockType(t) { + var _settings = this.state.settings; + _settings.unlockType = t; + + this.setState({ + _settings: _settings + }); } }, { - key: '__handleClearBtnClick__REACT_HOT_LOADER__', - value: function __handleClearBtnClick__REACT_HOT_LOADER__() { - var seachInput = this.refs.seachInput; + key: 'toggleCompressPubKey', + value: function toggleCompressPubKey(b) { + var _settings = this.state.settings; + _settings.compressPubKey = !_settings.compressPubKey; - seachInput && seachInput.setValue(''); - this.props.onSearch(''); + this.setState({ + _settings: _settings + }); } }, { - key: 'render', - value: function render() { - this.modalClassName = 'bs-table-modal-sm' + ToolBar.modalSeq++; - var toolbar = null; - var btnGroup = null; - var insertBtn = null; - var deleteBtn = null; - var exportCSVBtn = null; - var showSelectedOnlyBtn = null; - - if (this.props.enableInsert) { - if (this.props.insertBtn) { - insertBtn = this.renderCustomBtn(this.props.insertBtn, [this.handleModalOpen], _InsertButton2.default.name, 'onClick', this.handleModalOpen); - } else { - insertBtn = _react2.default.createElement(_InsertButton2.default, { btnText: this.props.insertText, - onClick: this.handleModalOpen }); - } - } - - if (this.props.enableDelete) { - if (this.props.deleteBtn) { - deleteBtn = this.renderCustomBtn(this.props.deleteBtn, [this.handleDropRowBtnClick], _DeleteButton2.default.name, 'onClick', this.handleDropRowBtnClick); - } else { - deleteBtn = _react2.default.createElement(_DeleteButton2.default, { btnText: this.props.deleteText, - onClick: this.handleDropRowBtnClick }); - } - } - - if (this.props.enableShowOnlySelected) { - if (this.props.showSelectedOnlyBtn) { - showSelectedOnlyBtn = this.renderCustomBtn(this.props.showSelectedOnlyBtn, [this.handleShowOnlyToggle, this.state.showSelected], _ShowSelectedOnlyButton2.default.name, 'onClick', this.handleShowOnlyToggle); - } else { - showSelectedOnlyBtn = _react2.default.createElement(_ShowSelectedOnlyButton2.default, { toggle: this.state.showSelected, - onClick: this.handleShowOnlyToggle }); - } - } - - if (this.props.enableExportCSV) { - if (this.props.exportCSVBtn) { - exportCSVBtn = this.renderCustomBtn(this.props.exportCSVBtn, [this.handleExportCSV], _ExportCSVButton2.default.name, 'onClick', this.handleExportCSV); - } else { - exportCSVBtn = _react2.default.createElement(_ExportCSVButton2.default, { btnText: this.props.exportCSVText, - onClick: this.handleExportCSV }); - } - } - - if (this.props.btnGroup) { - btnGroup = this.props.btnGroup({ - exportCSVBtn: exportCSVBtn, - insertBtn: insertBtn, - deleteBtn: deleteBtn, - showSelectedOnlyBtn: showSelectedOnlyBtn - }); - } else { - btnGroup = _react2.default.createElement( - 'div', - { className: 'btn-group btn-group-sm', role: 'group' }, - exportCSVBtn, - insertBtn, - deleteBtn, - showSelectedOnlyBtn - ); - } + key: 'toggleUseTestNet', + value: function toggleUseTestNet() { + var _settings = this.state.settings; + _settings.useTestNet = !_settings.useTestNet; - var _renderSearchPanel = this.renderSearchPanel(), - _renderSearchPanel2 = _slicedToArray(_renderSearchPanel, 3), - searchPanel = _renderSearchPanel2[0], - searchField = _renderSearchPanel2[1], - clearBtn = _renderSearchPanel2[2]; - - var modal = this.props.enableInsert ? this.renderInsertRowModal() : null; - - if (this.props.toolBar) { - toolbar = this.props.toolBar({ - components: { - exportCSVBtn: exportCSVBtn, - insertBtn: insertBtn, - deleteBtn: deleteBtn, - showSelectedOnlyBtn: showSelectedOnlyBtn, - searchPanel: searchPanel, - btnGroup: btnGroup, - searchField: searchField, - clearBtn: clearBtn - }, - event: { - openInsertModal: this.handleModalOpen, - closeInsertModal: this.handleModalClose, - dropRow: this.handleDropRowBtnClick, - showOnlyToogle: this.handleShowOnlyToggle, - exportCSV: this.handleExportCSV, - search: this.props.onSearch - } - }); + if (_settings.useTestNet) { + _settings.insightAPI = 'http://aayanl.tech:8081/insight-api-zen/'; + _settings.explorerURL = 'http://aayanl.tech:8081/'; } else { - toolbar = [_react2.default.createElement( - 'div', - { key: 'toolbar-left', className: 'col-xs-6 col-sm-6 col-md-6 col-lg-8' }, - this.props.searchPosition === 'left' ? searchPanel : btnGroup - ), _react2.default.createElement( - 'div', - { key: 'toolbar-right', className: 'col-xs-6 col-sm-6 col-md-6 col-lg-4' }, - this.props.searchPosition === 'left' ? btnGroup : searchPanel - )]; + _settings.insightAPI = 'https://explorer.zensystem.io/insight-api-zen/'; + _settings.explorerURL = 'https://explorer.zensystem.io/insight/'; } - return _react2.default.createElement( - 'div', - { className: 'row' }, - toolbar, - modal - ); + this.setState({ + settings: _settings + }); } }, { - key: 'renderSearchPanel', - value: function renderSearchPanel() { - if (this.props.enableSearch) { - var classNames = 'form-group form-group-sm react-bs-table-search-form'; - var clearBtn = null; - var searchField = null; - var searchPanel = null; - if (this.props.clearSearch) { - if (this.props.clearSearchBtn) { - clearBtn = this.renderCustomBtn(this.props.clearSearchBtn, [this.handleClearBtnClick], _ClearSearchButton2.default.name, 'onClick', this.handleClearBtnClick); /* eslint max-len: 0*/ - } else { - clearBtn = _react2.default.createElement(_ClearSearchButton2.default, { onClick: this.handleClearBtnClick }); - } - classNames += ' input-group input-group-sm'; - } + key: 'toggleShowSettings', + value: function toggleShowSettings() { + var _settings = this.state.settings; + _settings.showSettings = !_settings.showSettings; - if (this.props.searchField) { - searchField = this.props.searchField({ - search: this.handleKeyUp, - defaultValue: this.props.defaultSearch, - placeholder: this.props.searchPlaceholder - }); - if (searchField.type.name === _SearchField2.default.name) { - searchField = _react2.default.cloneElement(searchField, { - ref: 'seachInput', - onKeyUp: this.handleKeyUp - }); - } else { - searchField = _react2.default.cloneElement(searchField, { - ref: 'seachInput' - }); - } - } else { - searchField = _react2.default.createElement(_SearchField2.default, { ref: 'seachInput', - defaultValue: this.props.defaultSearch, - placeholder: this.props.searchPlaceholder, - onKeyUp: this.handleKeyUp }); - } - if (this.props.searchPanel) { - searchPanel = this.props.searchPanel({ - searchField: searchField, clearBtn: clearBtn, - search: this.props.onSearch, - defaultValue: this.props.defaultSearch, - placeholder: this.props.searchPlaceholder, - clearBtnClick: this.handleClearBtnClick - }); - } else { - searchPanel = _react2.default.createElement( - 'div', - { className: classNames }, - searchField, - _react2.default.createElement( - 'span', - { className: 'input-group-btn' }, - clearBtn - ) - ); - } - return [searchPanel, searchField, clearBtn]; - } else { - return []; - } + this.setState({ + settings: _settings + }); } }, { - key: 'renderInsertRowModal', - value: function renderInsertRowModal() { - var validateState = this.state.validateState || {}; - var _props = this.props, - version = _props.version, - columns = _props.columns, - ignoreEditable = _props.ignoreEditable, - insertModalHeader = _props.insertModalHeader, - insertModalBody = _props.insertModalBody, - insertModalFooter = _props.insertModalFooter, - insertModal = _props.insertModal; - - - var modal = void 0; - modal = insertModal && insertModal(this.handleModalClose, this.handleSaveBtnClick, columns, validateState, ignoreEditable); - - if (!modal) { - modal = _react2.default.createElement(_InsertModal2.default, { - version: version, - columns: columns, - validateState: validateState, - ignoreEditable: ignoreEditable, - onModalClose: this.handleModalClose, - onSave: this.handleSaveBtnClick, - headerComponent: insertModalHeader, - bodyComponent: insertModalBody, - footerComponent: insertModalFooter }); - } + key: 'toggleShowWalletGen', + value: function toggleShowWalletGen() { + var _settings = this.state.settings; + _settings.showWalletGen = !_settings.showWalletGen; - return _react2.default.createElement( - _reactModal2.default, - { className: 'react-bs-insert-modal modal-dialog', - isOpen: this.state.isInsertModalOpen, - onRequestClose: this.handleModalClose, - contentLabel: 'Modal' }, - modal - ); + this.setState({ + settings: _settings + }); } }, { - key: 'renderCustomBtn', - value: function renderCustomBtn(cb, params, componentName, eventName, event) { - var element = cb.apply(null, params); - if (element.type.name === componentName && !element.props[eventName]) { - var props = {}; - props[eventName] = event; - element = _react2.default.cloneElement(element, props); - } - return element; + key: 'render', + value: function render() { + return _react2.default.createElement( + _reactstrap.Container, + null, + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + _react2.default.createElement( + 'h1', + { className: 'display-6' }, + 'ZenCash Wallet\xA0', + _react2.default.createElement(ToolTipButton, { onClick: this.toggleShowSettings, id: 1, buttonText: _react2.default.createElement(_settings3.default, null), tooltipText: 'settings' }), + '\xA0', + _react2.default.createElement(ToolTipButton, { disabled: this.state.publicAddresses === null, onClick: this.resetKeys, id: 2, buttonText: _react2.default.createElement(_repeat2.default, null), tooltipText: 'reset wallet' }) + ), + _react2.default.createElement(ZWalletSettings, { + setUnlockType: this.setUnlockType, + toggleShowSettings: this.toggleShowSettings, + toggleCompressPubKey: this.toggleCompressPubKey, + toggleShowWalletGen: this.toggleShowWalletGen, + toggleUseTestNet: this.toggleUseTestNet, + setInsightAPI: this.setInsightAPI, + settings: this.state.settings, + publicAddresses: this.state.publicAddresses + }), + _react2.default.createElement('br', null) + ) + ), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.publicAddresses === null ? _react2.default.createElement(ZWalletUnlockKey, { + handleUnlockPrivateKeys: this.handleUnlockPrivateKeys, + setPrivateKeys: this.setPrivateKeys, + unlockType: this.state.settings.unlockType + }) : _react2.default.createElement(ZWalletTabs, { + publicAddresses: this.state.publicAddresses, + settings: this.state.settings, + setPublicAddressesKeyValue: this.setPublicAddressesKeyValue, + privateKeys: this.state.privateKeys + }) + ) + ), + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + null, + this.state.settings.showWalletGen ? _react2.default.createElement( + 'div', + null, + _react2.default.createElement('br', null), + _react2.default.createElement('hr', null), + _react2.default.createElement(ZWalletGenerator, { settings: this.state.settings }) + ) : null + ) + ) + ); } }]); - return ToolBar; -}(_react.Component); - -ToolBar.modalSeq = 0; - - -ToolBar.propTypes = { - version: _propTypes2.default.string, - onAddRow: _propTypes2.default.func, - onDropRow: _propTypes2.default.func, - onShowOnlySelected: _propTypes2.default.func, - enableInsert: _propTypes2.default.bool, - enableDelete: _propTypes2.default.bool, - enableSearch: _propTypes2.default.bool, - enableShowOnlySelected: _propTypes2.default.bool, - columns: _propTypes2.default.array, - searchPlaceholder: _propTypes2.default.string, - exportCSVText: _propTypes2.default.string, - insertText: _propTypes2.default.string, - deleteText: _propTypes2.default.string, - saveText: _propTypes2.default.string, - closeText: _propTypes2.default.string, - clearSearch: _propTypes2.default.bool, - ignoreEditable: _propTypes2.default.bool, - defaultSearch: _propTypes2.default.string, - insertModalHeader: _propTypes2.default.func, - insertModalBody: _propTypes2.default.func, - insertModalFooter: _propTypes2.default.func, - insertModal: _propTypes2.default.func, - insertBtn: _propTypes2.default.func, - deleteBtn: _propTypes2.default.func, - showSelectedOnlyBtn: _propTypes2.default.func, - exportCSVBtn: _propTypes2.default.func, - clearSearchBtn: _propTypes2.default.func, - searchField: _propTypes2.default.func, - searchPanel: _propTypes2.default.func, - btnGroup: _propTypes2.default.func, - toolBar: _propTypes2.default.func, - searchPosition: _propTypes2.default.string, - reset: _propTypes2.default.bool, - isValidKey: _propTypes2.default.func, - insertFailIndicator: _propTypes2.default.string -}; - -ToolBar.defaultProps = { - reset: false, - enableInsert: false, - enableDelete: false, - enableSearch: false, - enableShowOnlySelected: false, - clearSearch: false, - ignoreEditable: false, - exportCSVText: _Const2.default.EXPORT_CSV_TEXT, - insertText: _Const2.default.INSERT_BTN_TEXT, - deleteText: _Const2.default.DELETE_BTN_TEXT, - saveText: _Const2.default.SAVE_BTN_TEXT, - closeText: _Const2.default.CLOSE_BTN_TEXT -}; - -var _default = ToolBar; -exports.default = _default; -; - -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - - __REACT_HOT_LOADER__.register(ToolBar, 'ToolBar', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ToolBar.js'); - - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ToolBar.js'); -}(); + return ZWallet; +}(_react2.default.Component); -; +exports.default = ZWallet; +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 382 */ +/* 333 */ /***/ (function(module, exports, __webpack_require__) { -module.exports = __webpack_require__(383); - - +"use strict"; -/***/ }), -/* 383 */ -/***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(process) {var React = __webpack_require__(4); -var ReactDOM = __webpack_require__(28); -var DOMFactories = __webpack_require__(288); -var PropTypes = __webpack_require__(9); -var ExecutionEnvironment = __webpack_require__(384); -var ModalPortal = React.createFactory(__webpack_require__(385)); -var ariaAppHider = __webpack_require__(388); -var refCount = __webpack_require__(389); -var elementClass = __webpack_require__(390); -var renderSubtreeIntoContainer = __webpack_require__(28).unstable_renderSubtreeIntoContainer; -var Assign = __webpack_require__(290); -var createReactClass = __webpack_require__(291); +exports.byteLength = byteLength +exports.toByteArray = toByteArray +exports.fromByteArray = fromByteArray -var SafeHTMLElement = ExecutionEnvironment.canUseDOM ? window.HTMLElement : {}; -var AppElement = ExecutionEnvironment.canUseDOM ? document.body : {appendChild: function() {}}; +var lookup = [] +var revLookup = [] +var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array -function getParentElement(parentSelector) { - return parentSelector(); +var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' +for (var i = 0, len = code.length; i < len; ++i) { + lookup[i] = code[i] + revLookup[code.charCodeAt(i)] = i } -var Modal = createReactClass({ - - displayName: 'Modal', - statics: { - setAppElement: function(element) { - AppElement = ariaAppHider.setElement(element); - }, - injectCSS: function() { - "production" !== process.env.NODE_ENV - && console.warn('React-Modal: injectCSS has been deprecated ' + - 'and no longer has any effect. It will be removed in a later version'); - } - }, - - propTypes: { - isOpen: PropTypes.bool.isRequired, - style: PropTypes.shape({ - content: PropTypes.object, - overlay: PropTypes.object - }), - portalClassName: PropTypes.string, - bodyOpenClassName: PropTypes.string, - appElement: PropTypes.instanceOf(SafeHTMLElement), - onAfterOpen: PropTypes.func, - onRequestClose: PropTypes.func, - closeTimeoutMS: PropTypes.number, - ariaHideApp: PropTypes.bool, - shouldCloseOnOverlayClick: PropTypes.bool, - parentSelector: PropTypes.func, - role: PropTypes.string, - contentLabel: PropTypes.string.isRequired - }, - - getDefaultProps: function () { - return { - isOpen: false, - portalClassName: 'ReactModalPortal', - bodyOpenClassName: 'ReactModal__Body--open', - ariaHideApp: true, - closeTimeoutMS: 0, - shouldCloseOnOverlayClick: true, - parentSelector: function () { return document.body; } - }; - }, - - componentDidMount: function() { - this.node = document.createElement('div'); - this.node.className = this.props.portalClassName; - - if (this.props.isOpen) refCount.add(this); - - var parent = getParentElement(this.props.parentSelector); - parent.appendChild(this.node); - this.renderPortal(this.props); - }, - - componentWillUpdate: function(newProps) { - if(newProps.portalClassName !== this.props.portalClassName) { - this.node.className = newProps.portalClassName; - } - }, - - componentWillReceiveProps: function(newProps) { - if (newProps.isOpen) refCount.add(this); - if (!newProps.isOpen) refCount.remove(this); - var currentParent = getParentElement(this.props.parentSelector); - var newParent = getParentElement(newProps.parentSelector); - - if(newParent !== currentParent) { - currentParent.removeChild(this.node); - newParent.appendChild(this.node); - } - - this.renderPortal(newProps); - }, - - componentWillUnmount: function() { - if (!this.node) return; - - refCount.remove(this); - - if (this.props.ariaHideApp) { - ariaAppHider.show(this.props.appElement); - } - - var state = this.portal.state; - var now = Date.now(); - var closesAt = state.isOpen && this.props.closeTimeoutMS - && (state.closesAt - || now + this.props.closeTimeoutMS); - - if (closesAt) { - if (!state.beforeClose) { - this.portal.closeWithTimeout(); - } - - var that = this; - setTimeout(function() { that.removePortal(); }, closesAt - now); - } else { - this.removePortal(); - } - }, - - removePortal: function() { - ReactDOM.unmountComponentAtNode(this.node); - var parent = getParentElement(this.props.parentSelector); - parent.removeChild(this.node); - - if (refCount.count() === 0) { - elementClass(document.body).remove(this.props.bodyOpenClassName); - } - }, - - renderPortal: function(props) { - if (props.isOpen || refCount.count() > 0) { - elementClass(document.body).add(this.props.bodyOpenClassName); - } else { - elementClass(document.body).remove(this.props.bodyOpenClassName); - } - - if (props.ariaHideApp) { - ariaAppHider.toggle(props.isOpen, props.appElement); - } - - this.portal = renderSubtreeIntoContainer(this, ModalPortal(Assign({}, props, {defaultStyles: Modal.defaultStyles})), this.node); - }, +revLookup['-'.charCodeAt(0)] = 62 +revLookup['_'.charCodeAt(0)] = 63 - render: function () { - return DOMFactories.noscript(); +function placeHoldersCount (b64) { + var len = b64.length + if (len % 4 > 0) { + throw new Error('Invalid string. Length must be a multiple of 4') } -}); -Modal.defaultStyles = { - overlay: { - position : 'fixed', - top : 0, - left : 0, - right : 0, - bottom : 0, - backgroundColor : 'rgba(255, 255, 255, 0.75)' - }, - content: { - position : 'absolute', - top : '40px', - left : '40px', - right : '40px', - bottom : '40px', - border : '1px solid #ccc', - background : '#fff', - overflow : 'auto', - WebkitOverflowScrolling : 'touch', - borderRadius : '4px', - outline : 'none', - padding : '20px' - } + // the number of equal signs (place holders) + // if there are two placeholders, than the two characters before it + // represent one byte + // if there is only one, then the three characters before it represent 2 bytes + // this is just a cheap hack to not do indexOf twice + return b64[len - 2] === '=' ? 2 : b64[len - 1] === '=' ? 1 : 0 } -module.exports = Modal - -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) - -/***/ }), -/* 384 */ -/***/ (function(module, exports, __webpack_require__) { - -var __WEBPACK_AMD_DEFINE_RESULT__;/*! - Copyright (c) 2015 Jed Watson. - Based on code that is Copyright 2013-2015, Facebook, Inc. - All rights reserved. -*/ - -(function () { - 'use strict'; - - var canUseDOM = !!( - typeof window !== 'undefined' && - window.document && - window.document.createElement - ); - - var ExecutionEnvironment = { - - canUseDOM: canUseDOM, - - canUseWorkers: typeof Worker !== 'undefined', - - canUseEventListeners: - canUseDOM && !!(window.addEventListener || window.attachEvent), - - canUseViewport: canUseDOM && !!window.screen - - }; - - if (true) { - !(__WEBPACK_AMD_DEFINE_RESULT__ = function () { - return ExecutionEnvironment; - }.call(exports, __webpack_require__, exports, module), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else if (typeof module !== 'undefined' && module.exports) { - module.exports = ExecutionEnvironment; - } else { - window.ExecutionEnvironment = ExecutionEnvironment; - } - -}()); - - -/***/ }), -/* 385 */ -/***/ (function(module, exports, __webpack_require__) { - -var React = __webpack_require__(4); -var DOMFactories = __webpack_require__(288); -var focusManager = __webpack_require__(386); -var scopeTab = __webpack_require__(387); -var Assign = __webpack_require__(290); -var createReactClass = __webpack_require__(291); - -var div = DOMFactories.div; - -// so that our CSS is statically analyzable -var CLASS_NAMES = { - overlay: 'ReactModal__Overlay', - content: 'ReactModal__Content' -}; - -var ModalPortal = module.exports = createReactClass({ - - displayName: 'ModalPortal', - shouldClose: null, - - getDefaultProps: function() { - return { - style: { - overlay: {}, - content: {} - } - }; - }, - - getInitialState: function() { - return { - afterOpen: false, - beforeClose: false - }; - }, - - componentDidMount: function() { - // Focus needs to be set when mounting and already open - if (this.props.isOpen) { - this.setFocusAfterRender(true); - this.open(); - } - }, - - componentWillUnmount: function() { - clearTimeout(this.closeTimer); - }, - - componentWillReceiveProps: function(newProps) { - // Focus only needs to be set once when the modal is being opened - if (!this.props.isOpen && newProps.isOpen) { - this.setFocusAfterRender(true); - this.open(); - } else if (this.props.isOpen && !newProps.isOpen) { - this.close(); - } - }, - - componentDidUpdate: function () { - if (this.focusAfterRender) { - this.focusContent(); - this.setFocusAfterRender(false); - } - }, - - setFocusAfterRender: function (focus) { - this.focusAfterRender = focus; - }, - - afterClose: function () { - focusManager.returnFocus(); - focusManager.teardownScopedFocus(); - }, - - open: function () { - if (this.state.afterOpen && this.state.beforeClose) { - clearTimeout(this.closeTimer); - this.setState({ beforeClose: false }); - } else { - focusManager.setupScopedFocus(this.node); - focusManager.markForFocusLater(); - this.setState({isOpen: true}, function() { - this.setState({afterOpen: true}); +function byteLength (b64) { + // base64 is 4/3 + up to two characters of the original data + return (b64.length * 3 / 4) - placeHoldersCount(b64) +} - if (this.props.isOpen && this.props.onAfterOpen) { - this.props.onAfterOpen(); - } - }.bind(this)); - } - }, +function toByteArray (b64) { + var i, l, tmp, placeHolders, arr + var len = b64.length + placeHolders = placeHoldersCount(b64) - close: function() { - if (this.props.closeTimeoutMS > 0) - this.closeWithTimeout(); - else - this.closeWithoutTimeout(); - }, + arr = new Arr((len * 3 / 4) - placeHolders) - focusContent: function() { - // Don't steal focus from inner elements - if (!this.contentHasFocus()) { - this.refs.content.focus(); - } - }, + // if there are placeholders, only get up to the last complete 4 chars + l = placeHolders > 0 ? len - 4 : len - closeWithTimeout: function() { - var closesAt = Date.now() + this.props.closeTimeoutMS; - this.setState({beforeClose: true, closesAt: closesAt}, function() { - this.closeTimer = setTimeout(this.closeWithoutTimeout, this.state.closesAt - Date.now()); - }.bind(this)); - }, + var L = 0 - closeWithoutTimeout: function() { - this.setState({ - beforeClose: false, - isOpen: false, - afterOpen: false, - closesAt: null - }, this.afterClose); - }, + for (i = 0; i < l; i += 4) { + tmp = (revLookup[b64.charCodeAt(i)] << 18) | (revLookup[b64.charCodeAt(i + 1)] << 12) | (revLookup[b64.charCodeAt(i + 2)] << 6) | revLookup[b64.charCodeAt(i + 3)] + arr[L++] = (tmp >> 16) & 0xFF + arr[L++] = (tmp >> 8) & 0xFF + arr[L++] = tmp & 0xFF + } - handleKeyDown: function(event) { - if (event.keyCode == 9 /*tab*/) scopeTab(this.refs.content, event); - if (event.keyCode == 27 /*esc*/) { - event.preventDefault(); - this.requestClose(event); - } - }, + if (placeHolders === 2) { + tmp = (revLookup[b64.charCodeAt(i)] << 2) | (revLookup[b64.charCodeAt(i + 1)] >> 4) + arr[L++] = tmp & 0xFF + } else if (placeHolders === 1) { + tmp = (revLookup[b64.charCodeAt(i)] << 10) | (revLookup[b64.charCodeAt(i + 1)] << 4) | (revLookup[b64.charCodeAt(i + 2)] >> 2) + arr[L++] = (tmp >> 8) & 0xFF + arr[L++] = tmp & 0xFF + } - handleOverlayOnClick: function (event) { - if (this.shouldClose === null) { - this.shouldClose = true; - } + return arr +} - if (this.shouldClose && this.props.shouldCloseOnOverlayClick) { - if (this.ownerHandlesClose()) - this.requestClose(event); - else - this.focusContent(); - } - this.shouldClose = null; - }, +function tripletToBase64 (num) { + return lookup[num >> 18 & 0x3F] + lookup[num >> 12 & 0x3F] + lookup[num >> 6 & 0x3F] + lookup[num & 0x3F] +} - handleContentOnClick: function () { - this.shouldClose = false; - }, +function encodeChunk (uint8, start, end) { + var tmp + var output = [] + for (var i = start; i < end; i += 3) { + tmp = (uint8[i] << 16) + (uint8[i + 1] << 8) + (uint8[i + 2]) + output.push(tripletToBase64(tmp)) + } + return output.join('') +} - requestClose: function(event) { - if (this.ownerHandlesClose()) - this.props.onRequestClose(event); - }, +function fromByteArray (uint8) { + var tmp + var len = uint8.length + var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes + var output = '' + var parts = [] + var maxChunkLength = 16383 // must be multiple of 3 - ownerHandlesClose: function() { - return this.props.onRequestClose; - }, + // go through the array every three bytes, we'll deal with trailing stuff later + for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) { + parts.push(encodeChunk(uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength))) + } - shouldBeClosed: function() { - return !this.state.isOpen && !this.state.beforeClose; - }, + // pad the end with zeros, but make sure to not forget the extra bytes + if (extraBytes === 1) { + tmp = uint8[len - 1] + output += lookup[tmp >> 2] + output += lookup[(tmp << 4) & 0x3F] + output += '==' + } else if (extraBytes === 2) { + tmp = (uint8[len - 2] << 8) + (uint8[len - 1]) + output += lookup[tmp >> 10] + output += lookup[(tmp >> 4) & 0x3F] + output += lookup[(tmp << 2) & 0x3F] + output += '=' + } - contentHasFocus: function() { - return document.activeElement === this.refs.content || this.refs.content.contains(document.activeElement); - }, + parts.push(output) - buildClassName: function(which, additional) { - var classNames = (typeof additional === 'object') ? additional : { - base: CLASS_NAMES[which], - afterOpen: CLASS_NAMES[which] + "--after-open", - beforeClose: CLASS_NAMES[which] + "--before-close" - }; - var className = classNames.base; - if (this.state.afterOpen) { className += " " + classNames.afterOpen; } - if (this.state.beforeClose) { className += " " + classNames.beforeClose; } - return (typeof additional === 'string' && additional) ? [className, additional].join(" ") : className; - }, + return parts.join('') +} - render: function() { - var contentStyles = (this.props.className) ? {} : this.props.defaultStyles.content; - var overlayStyles = (this.props.overlayClassName) ? {} : this.props.defaultStyles.overlay; - return this.shouldBeClosed() ? div() : ( - div({ - ref: "overlay", - className: this.buildClassName('overlay', this.props.overlayClassName), - style: Assign({}, overlayStyles, this.props.style.overlay || {}), - onClick: this.handleOverlayOnClick - }, - div({ - ref: "content", - style: Assign({}, contentStyles, this.props.style.content || {}), - className: this.buildClassName('content', this.props.className), - tabIndex: "-1", - onKeyDown: this.handleKeyDown, - onClick: this.handleContentOnClick, - role: this.props.role, - "aria-label": this.props.contentLabel - }, - this.props.children - ) - ) - ); - } -}); +/***/ }), +/* 334 */ +/***/ (function(module, exports) { +exports.read = function (buffer, offset, isLE, mLen, nBytes) { + var e, m + var eLen = nBytes * 8 - mLen - 1 + var eMax = (1 << eLen) - 1 + var eBias = eMax >> 1 + var nBits = -7 + var i = isLE ? (nBytes - 1) : 0 + var d = isLE ? -1 : 1 + var s = buffer[offset + i] -/***/ }), -/* 386 */ -/***/ (function(module, exports, __webpack_require__) { + i += d -var findTabbable = __webpack_require__(289); -var focusLaterElements = []; -var modalElement = null; -var needToFocus = false; + e = s & ((1 << (-nBits)) - 1) + s >>= (-nBits) + nBits += eLen + for (; nBits > 0; e = e * 256 + buffer[offset + i], i += d, nBits -= 8) {} -function handleBlur(event) { - needToFocus = true; -} + m = e & ((1 << (-nBits)) - 1) + e >>= (-nBits) + nBits += mLen + for (; nBits > 0; m = m * 256 + buffer[offset + i], i += d, nBits -= 8) {} -function handleFocus(event) { - if (needToFocus) { - needToFocus = false; - if (!modalElement) { - return; - } - // need to see how jQuery shims document.on('focusin') so we don't need the - // setTimeout, firefox doesn't support focusin, if it did, we could focus - // the element outside of a setTimeout. Side-effect of this implementation - // is that the document.body gets focus, and then we focus our element right - // after, seems fine. - setTimeout(function() { - if (modalElement.contains(document.activeElement)) - return; - var el = (findTabbable(modalElement)[0] || modalElement); - el.focus(); - }, 0); + if (e === 0) { + e = 1 - eBias + } else if (e === eMax) { + return m ? NaN : ((s ? -1 : 1) * Infinity) + } else { + m = m + Math.pow(2, mLen) + e = e - eBias } + return (s ? -1 : 1) * m * Math.pow(2, e - mLen) } -exports.markForFocusLater = function() { - focusLaterElements.push(document.activeElement); -}; - -exports.returnFocus = function() { - var toFocus = null; - try { - toFocus = focusLaterElements.pop(); - toFocus.focus(); - return; - } - catch (e) { - console.warn('You tried to return focus to '+toFocus+' but it is not in the DOM anymore'); - } -}; +exports.write = function (buffer, value, offset, isLE, mLen, nBytes) { + var e, m, c + var eLen = nBytes * 8 - mLen - 1 + var eMax = (1 << eLen) - 1 + var eBias = eMax >> 1 + var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0) + var i = isLE ? 0 : (nBytes - 1) + var d = isLE ? 1 : -1 + var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0 -exports.setupScopedFocus = function(element) { - modalElement = element; + value = Math.abs(value) - if (window.addEventListener) { - window.addEventListener('blur', handleBlur, false); - document.addEventListener('focus', handleFocus, true); + if (isNaN(value) || value === Infinity) { + m = isNaN(value) ? 1 : 0 + e = eMax } else { - window.attachEvent('onBlur', handleBlur); - document.attachEvent('onFocus', handleFocus); + e = Math.floor(Math.log(value) / Math.LN2) + if (value * (c = Math.pow(2, -e)) < 1) { + e-- + c *= 2 + } + if (e + eBias >= 1) { + value += rt / c + } else { + value += rt * Math.pow(2, 1 - eBias) + } + if (value * c >= 2) { + e++ + c /= 2 + } + + if (e + eBias >= eMax) { + m = 0 + e = eMax + } else if (e + eBias >= 1) { + m = (value * c - 1) * Math.pow(2, mLen) + e = e + eBias + } else { + m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen) + e = 0 + } } -}; -exports.teardownScopedFocus = function() { - modalElement = null; + for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {} - if (window.addEventListener) { - window.removeEventListener('blur', handleBlur); - document.removeEventListener('focus', handleFocus); - } else { - window.detachEvent('onBlur', handleBlur); - document.detachEvent('onFocus', handleFocus); - } -}; + e = (e << mLen) | m + eLen += mLen + for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {} + + buffer[offset + i - d] |= s * 128 +} /***/ }), -/* 387 */ +/* 335 */ /***/ (function(module, exports, __webpack_require__) { -var findTabbable = __webpack_require__(289); - -module.exports = function(node, event) { - var tabbable = findTabbable(node); - if (!tabbable.length) { - event.preventDefault(); - return; - } - var finalTabbable = tabbable[event.shiftKey ? 0 : tabbable.length - 1]; - var leavingFinalTabbable = ( - finalTabbable === document.activeElement || - // handle immediate shift+tab after opening with mouse - node === document.activeElement - ); - if (!leavingFinalTabbable) return; - event.preventDefault(); - var target = tabbable[event.shiftKey ? tabbable.length - 1 : 0]; - target.focus(); -}; - +module.exports = __webpack_require__(336); /***/ }), -/* 388 */ -/***/ (function(module, exports) { +/* 336 */ +/***/ (function(module, exports, __webpack_require__) { -var _element = typeof document !== 'undefined' ? document.body : null; +"use strict"; -function setElement(element) { - if (typeof element === 'string') { - var el = document.querySelectorAll(element); - element = 'length' in el ? el[0] : el; - } - _element = element || _element; - return _element; -} -function hide(appElement) { - validateElement(appElement); - (appElement || _element).setAttribute('aria-hidden', 'true'); -} +var utils = __webpack_require__(20); +var bind = __webpack_require__(155); +var Axios = __webpack_require__(338); +var defaults = __webpack_require__(94); -function show(appElement) { - validateElement(appElement); - (appElement || _element).removeAttribute('aria-hidden'); -} +/** + * Create an instance of Axios + * + * @param {Object} defaultConfig The default config for the instance + * @return {Axios} A new instance of Axios + */ +function createInstance(defaultConfig) { + var context = new Axios(defaultConfig); + var instance = bind(Axios.prototype.request, context); -function toggle(shouldHide, appElement) { - if (shouldHide) - hide(appElement); - else - show(appElement); -} + // Copy axios.prototype to instance + utils.extend(instance, Axios.prototype, context); -function validateElement(appElement) { - if (!appElement && !_element) - throw new Error('react-modal: You must set an element with `Modal.setAppElement(el)` to make this accessible'); -} + // Copy context to instance + utils.extend(instance, context); -function resetForTesting() { - _element = document.body; + return instance; } -exports.toggle = toggle; -exports.setElement = setElement; -exports.show = show; -exports.hide = hide; -exports.resetForTesting = resetForTesting; - - -/***/ }), -/* 389 */ -/***/ (function(module, exports) { +// Create the default instance to be exported +var axios = createInstance(defaults); -var modals = []; +// Expose Axios class to allow class inheritance +axios.Axios = Axios; -module.exports = { - add: function (element) { - if (modals.indexOf(element) === -1) { - modals.push(element); - } - }, - remove: function (element) { - var index = modals.indexOf(element); - if (index === -1) { - return; - } - modals.splice(index, 1); - }, - count: function () { - return modals.length; - } +// Factory for creating new instances +axios.create = function create(instanceConfig) { + return createInstance(utils.merge(defaults, instanceConfig)); }; +// Expose Cancel & CancelToken +axios.Cancel = __webpack_require__(159); +axios.CancelToken = __webpack_require__(352); +axios.isCancel = __webpack_require__(158); -/***/ }), -/* 390 */ -/***/ (function(module, exports) { - -module.exports = function(opts) { - return new ElementClass(opts) -} +// Expose all/spread +axios.all = function all(promises) { + return Promise.all(promises); +}; +axios.spread = __webpack_require__(353); -function indexOf(arr, prop) { - if (arr.indexOf) return arr.indexOf(prop) - for (var i = 0, len = arr.length; i < len; i++) - if (arr[i] === prop) return i - return -1 -} +module.exports = axios; -function ElementClass(opts) { - if (!(this instanceof ElementClass)) return new ElementClass(opts) - var self = this - if (!opts) opts = {} +// Allow use of default import syntax in TypeScript +module.exports.default = axios; - // similar doing instanceof HTMLElement but works in IE8 - if (opts.nodeType) opts = {el: opts} - this.opts = opts - this.el = opts.el || document.body - if (typeof this.el !== 'object') this.el = document.querySelector(this.el) -} +/***/ }), +/* 337 */ +/***/ (function(module, exports) { -ElementClass.prototype.add = function(className) { - var el = this.el - if (!el) return - if (el.className === "") return el.className = className - var classes = el.className.split(' ') - if (indexOf(classes, className) > -1) return classes - classes.push(className) - el.className = classes.join(' ') - return classes -} +/*! + * Determine if an object is a Buffer + * + * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> + * @license MIT + */ -ElementClass.prototype.remove = function(className) { - var el = this.el - if (!el) return - if (el.className === "") return - var classes = el.className.split(' ') - var idx = indexOf(classes, className) - if (idx > -1) classes.splice(idx, 1) - el.className = classes.join(' ') - return classes +// The _isBuffer check is for Safari 5-7 support, because it's missing +// Object.prototype.constructor. Remove this eventually +module.exports = function (obj) { + return obj != null && (isBuffer(obj) || isSlowBuffer(obj) || !!obj._isBuffer) } -ElementClass.prototype.has = function(className) { - var el = this.el - if (!el) return - var classes = el.className.split(' ') - return indexOf(classes, className) > -1 +function isBuffer (obj) { + return !!obj.constructor && typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj) } -ElementClass.prototype.toggle = function(className) { - var el = this.el - if (!el) return - if (this.has(className)) this.remove(className) - else this.add(className) +// For Node v0.10 support. Remove this eventually. +function isSlowBuffer (obj) { + return typeof obj.readFloatLE === 'function' && typeof obj.slice === 'function' && isBuffer(obj.slice(0, 0)) } /***/ }), -/* 391 */ +/* 338 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); +var defaults = __webpack_require__(94); +var utils = __webpack_require__(20); +var InterceptorManager = __webpack_require__(347); +var dispatchRequest = __webpack_require__(348); +var isAbsoluteURL = __webpack_require__(350); +var combineURLs = __webpack_require__(351); -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; +/** + * Create a new instance of Axios + * + * @param {Object} instanceConfig The default config for the instance + */ +function Axios(instanceConfig) { + this.defaults = instanceConfig; + this.interceptors = { + request: new InterceptorManager(), + response: new InterceptorManager() + }; +} -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +/** + * Dispatch a request + * + * @param {Object} config The config specific for this request (merged with this.defaults) + */ +Axios.prototype.request = function request(config) { + /*eslint no-param-reassign:0*/ + // Allow for axios('example/url'[, config]) a la fetch API + if (typeof config === 'string') { + config = utils.merge({ + url: arguments[0] + }, arguments[1]); + } -var _react = __webpack_require__(4); + config = utils.merge(defaults, this.defaults, { method: 'get' }, config); + config.method = config.method.toLowerCase(); -var _react2 = _interopRequireDefault(_react); + // Support baseURL config + if (config.baseURL && !isAbsoluteURL(config.url)) { + config.url = combineURLs(config.baseURL, config.url); + } -var _propTypes = __webpack_require__(9); + // Hook up interceptors middleware + var chain = [dispatchRequest, undefined]; + var promise = Promise.resolve(config); -var _propTypes2 = _interopRequireDefault(_propTypes); + this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) { + chain.unshift(interceptor.fulfilled, interceptor.rejected); + }); -var _InsertModalHeader = __webpack_require__(292); + this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) { + chain.push(interceptor.fulfilled, interceptor.rejected); + }); -var _InsertModalHeader2 = _interopRequireDefault(_InsertModalHeader); + while (chain.length) { + promise = promise.then(chain.shift(), chain.shift()); + } -var _InsertModalFooter = __webpack_require__(293); + return promise; +}; -var _InsertModalFooter2 = _interopRequireDefault(_InsertModalFooter); +// Provide aliases for supported request methods +utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url + })); + }; +}); -var _InsertModalBody = __webpack_require__(294); +utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { + /*eslint func-names:0*/ + Axios.prototype[method] = function(url, data, config) { + return this.request(utils.merge(config || {}, { + method: method, + url: url, + data: data + })); + }; +}); -var _InsertModalBody2 = _interopRequireDefault(_InsertModalBody); +module.exports = Axios; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +/***/ }), +/* 339 */ +/***/ (function(module, exports, __webpack_require__) { -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +"use strict"; -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } /* eslint no-console: 0 */ -var defaultModalClassName = 'react-bs-table-insert-modal'; +var utils = __webpack_require__(20); -var InsertModal = function (_Component) { - _inherits(InsertModal, _Component); +module.exports = function normalizeHeaderName(headers, normalizedName) { + utils.forEach(headers, function processHeader(value, name) { + if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) { + headers[normalizedName] = value; + delete headers[name]; + } + }); +}; - function InsertModal() { - var _ref; - var _temp, _this, _ret; +/***/ }), +/* 340 */ +/***/ (function(module, exports, __webpack_require__) { - _classCallCheck(this, InsertModal); +"use strict"; - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; - } - return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = InsertModal.__proto__ || Object.getPrototypeOf(InsertModal)).call.apply(_ref, [this].concat(args))), _this), _this.handleSave = function () { - var _this2; +var createError = __webpack_require__(157); - return (_this2 = _this).__handleSave__REACT_HOT_LOADER__.apply(_this2, arguments); - }, _temp), _possibleConstructorReturn(_this, _ret); +/** + * Resolve or reject a Promise based on response status. + * + * @param {Function} resolve A function that resolves the promise. + * @param {Function} reject A function that rejects the promise. + * @param {object} response The response. + */ +module.exports = function settle(resolve, reject, response) { + var validateStatus = response.config.validateStatus; + // Note: status is not exposed by XDomainRequest + if (!response.status || !validateStatus || validateStatus(response.status)) { + resolve(response); + } else { + reject(createError( + 'Request failed with status code ' + response.status, + response.config, + null, + response.request, + response + )); } +}; - _createClass(InsertModal, [{ - key: '__handleSave__REACT_HOT_LOADER__', - value: function __handleSave__REACT_HOT_LOADER__() { - var bodyRefs = this.refs.body; - if (bodyRefs.getFieldValue) { - this.props.onSave(bodyRefs.getFieldValue()); - } else { - console.error('Custom InsertModalBody should implement getFieldValue function\n and should return an object presented as the new row that user input.'); - } - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - headerComponent = _props.headerComponent, - footerComponent = _props.footerComponent, - bodyComponent = _props.bodyComponent; - var _props2 = this.props, - columns = _props2.columns, - validateState = _props2.validateState, - ignoreEditable = _props2.ignoreEditable, - onModalClose = _props2.onModalClose; - var bodyAttr = { columns: columns, validateState: validateState, ignoreEditable: ignoreEditable }; +/***/ }), +/* 341 */ +/***/ (function(module, exports, __webpack_require__) { - bodyComponent = bodyComponent && bodyComponent(columns, validateState, ignoreEditable); +"use strict"; - headerComponent = headerComponent && headerComponent(onModalClose, this.handleSave); - footerComponent = footerComponent && footerComponent(onModalClose, this.handleSave); +/** + * Update an Error with the specified config, error code, and response. + * + * @param {Error} error The error to update. + * @param {Object} config The config. + * @param {string} [code] The error code (for example, 'ECONNABORTED'). + * @param {Object} [request] The request. + * @param {Object} [response] The response. + * @returns {Error} The error. + */ +module.exports = function enhanceError(error, config, code, request, response) { + error.config = config; + if (code) { + error.code = code; + } + error.request = request; + error.response = response; + return error; +}; - if (bodyComponent) { - bodyComponent = _react2.default.cloneElement(bodyComponent, { ref: 'body' }); - } - if (headerComponent && headerComponent.type.name === _InsertModalHeader2.default.name) { - var eventProps = {}; - if (!headerComponent.props.onModalClose) eventProps.onModalClose = onModalClose; - if (!headerComponent.props.onSave) eventProps.onSave = this.handleSave; - if (Object.keys(eventProps).length > 0) { - headerComponent = _react2.default.cloneElement(headerComponent, eventProps); - } - } else if (headerComponent && headerComponent.type.name !== _InsertModalHeader2.default.name) { - var className = headerComponent.props.className; +/***/ }), +/* 342 */ +/***/ (function(module, exports, __webpack_require__) { - if (typeof className === 'undefined' || className.indexOf('modal-header') === -1) { - headerComponent = _react2.default.createElement( - 'div', - { className: 'modal-header' }, - headerComponent - ); - } - } +"use strict"; - if (footerComponent && footerComponent.type.name === _InsertModalFooter2.default.name) { - var _eventProps = {}; - if (!footerComponent.props.onModalClose) _eventProps.onModalClose = onModalClose; - if (!footerComponent.props.onSave) _eventProps.onSave = this.handleSave; - if (Object.keys(_eventProps).length > 0) { - footerComponent = _react2.default.cloneElement(footerComponent, _eventProps); - } - } else if (footerComponent && footerComponent.type.name !== _InsertModalFooter2.default.name) { - var _className = footerComponent.props.className; - if (typeof _className === 'undefined' || _className.indexOf('modal-footer') === -1) { - footerComponent = _react2.default.createElement( - 'div', - { className: 'modal-footer' }, - footerComponent - ); - } - } +var utils = __webpack_require__(20); - return _react2.default.createElement( - 'div', - { className: 'modal-content ' + defaultModalClassName }, - headerComponent || _react2.default.createElement(_InsertModalHeader2.default, { - version: this.props.version, - className: 'react-bs-table-inser-modal-header', - onModalClose: onModalClose }), - bodyComponent || _react2.default.createElement(_InsertModalBody2.default, _extends({ ref: 'body' }, bodyAttr)), - footerComponent || _react2.default.createElement(_InsertModalFooter2.default, { - className: 'react-bs-table-inser-modal-footer', - onModalClose: onModalClose, - onSave: this.handleSave }) - ); - } - }]); +function encode(val) { + return encodeURIComponent(val). + replace(/%40/gi, '@'). + replace(/%3A/gi, ':'). + replace(/%24/g, '$'). + replace(/%2C/gi, ','). + replace(/%20/g, '+'). + replace(/%5B/gi, '['). + replace(/%5D/gi, ']'); +} - return InsertModal; -}(_react.Component); +/** + * Build a URL by appending params to the end + * + * @param {string} url The base of the url (e.g., http://www.google.com) + * @param {object} [params] The params to be appended + * @returns {string} The formatted url + */ +module.exports = function buildURL(url, params, paramsSerializer) { + /*eslint no-param-reassign:0*/ + if (!params) { + return url; + } -var _default = InsertModal; -exports.default = _default; + var serializedParams; + if (paramsSerializer) { + serializedParams = paramsSerializer(params); + } else if (utils.isURLSearchParams(params)) { + serializedParams = params.toString(); + } else { + var parts = []; -InsertModal.propTypes = { - version: _propTypes2.default.string.isRequired, - columns: _propTypes2.default.array.isRequired, - validateState: _propTypes2.default.object.isRequired, - ignoreEditable: _propTypes2.default.bool, - headerComponent: _propTypes2.default.func, - bodyComponent: _propTypes2.default.func, - footerComponent: _propTypes2.default.func, - onModalClose: _propTypes2.default.func, - onSave: _propTypes2.default.func -}; + utils.forEach(params, function serialize(val, key) { + if (val === null || typeof val === 'undefined') { + return; + } -InsertModal.defaultProps = {}; -; + if (utils.isArray(val)) { + key = key + '[]'; + } -var _temp2 = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } + if (!utils.isArray(val)) { + val = [val]; + } - __REACT_HOT_LOADER__.register(defaultModalClassName, 'defaultModalClassName', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModal.js'); + utils.forEach(val, function parseValue(v) { + if (utils.isDate(v)) { + v = v.toISOString(); + } else if (utils.isObject(v)) { + v = JSON.stringify(v); + } + parts.push(encode(key) + '=' + encode(v)); + }); + }); - __REACT_HOT_LOADER__.register(InsertModal, 'InsertModal', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModal.js'); + serializedParams = parts.join('&'); + } - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/InsertModal.js'); -}(); + if (serializedParams) { + url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams; + } + + return url; +}; -; /***/ }), -/* 392 */ +/* 343 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); - -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); - -var _react2 = _interopRequireDefault(_react); - -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); +var utils = __webpack_require__(20); -var _Const = __webpack_require__(22); - -var _Const2 = _interopRequireDefault(_Const); - -var _classnames = __webpack_require__(29); - -var _classnames2 = _interopRequireDefault(_classnames); +/** + * Parse headers into an object + * + * ``` + * Date: Wed, 27 Aug 2014 08:58:49 GMT + * Content-Type: application/json + * Connection: keep-alive + * Transfer-Encoding: chunked + * ``` + * + * @param {String} headers Headers needing to be parsed + * @returns {Object} Headers parsed into an object + */ +module.exports = function parseHeaders(headers) { + var parsed = {}; + var key; + var val; + var i; -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + if (!headers) { return parsed; } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + utils.forEach(headers.split('\n'), function parser(line) { + i = line.indexOf(':'); + key = utils.trim(line.substr(0, i)).toLowerCase(); + val = utils.trim(line.substr(i + 1)); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + if (key) { + parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val; + } + }); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + return parsed; +}; -var TableFilter = function (_Component) { - _inherits(TableFilter, _Component); - function TableFilter(props) { - _classCallCheck(this, TableFilter); +/***/ }), +/* 344 */ +/***/ (function(module, exports, __webpack_require__) { - var _this = _possibleConstructorReturn(this, (TableFilter.__proto__ || Object.getPrototypeOf(TableFilter)).call(this, props)); +"use strict"; - _this.handleKeyUp = function () { - return _this.__handleKeyUp__REACT_HOT_LOADER__.apply(_this, arguments); - }; - _this.filterObj = {}; - return _this; - } +var utils = __webpack_require__(20); - _createClass(TableFilter, [{ - key: '__handleKeyUp__REACT_HOT_LOADER__', - value: function __handleKeyUp__REACT_HOT_LOADER__(e) { - var _e$currentTarget = e.currentTarget, - value = _e$currentTarget.value, - name = _e$currentTarget.name; +module.exports = ( + utils.isStandardBrowserEnv() ? - if (value.trim() === '') { - delete this.filterObj[name]; - } else { - this.filterObj[name] = value; - } - this.props.onFilter(this.filterObj); - } - }, { - key: 'render', - value: function render() { - var _props = this.props, - striped = _props.striped, - condensed = _props.condensed, - rowSelectType = _props.rowSelectType, - columns = _props.columns; - - var tableClasses = (0, _classnames2.default)('table', { - 'table-striped': striped, - 'table-condensed': condensed - }); - var selectRowHeader = null; + // Standard browser envs have full support of the APIs needed to test + // whether the request URL is of the same origin as current location. + (function standardBrowserEnv() { + var msie = /(msie|trident)/i.test(navigator.userAgent); + var urlParsingNode = document.createElement('a'); + var originURL; - if (rowSelectType === _Const2.default.ROW_SELECT_SINGLE || rowSelectType === _Const2.default.ROW_SELECT_MULTI) { - var style = { - width: 35, - paddingLeft: 0, - paddingRight: 0 - }; - selectRowHeader = _react2.default.createElement( - 'th', - { style: style, key: -1 }, - 'Filter' - ); - } + /** + * Parse a URL to discover it's components + * + * @param {String} url The URL to be parsed + * @returns {Object} + */ + function resolveURL(url) { + var href = url; - var filterField = columns.map(function (column) { - var hidden = column.hidden, - width = column.width, - name = column.name; + if (msie) { + // IE needs attribute set twice to normalize properties + urlParsingNode.setAttribute('href', href); + href = urlParsingNode.href; + } - var thStyle = { - display: hidden ? 'none' : null, - width: width - }; - return _react2.default.createElement( - 'th', - { key: name, style: thStyle }, - _react2.default.createElement( - 'div', - { className: 'th-inner table-header-column' }, - _react2.default.createElement('input', { size: '10', type: 'text', - placeholder: name, name: name, onKeyUp: this.handleKeyUp }) - ) - ); - }, this); + urlParsingNode.setAttribute('href', href); - return _react2.default.createElement( - 'table', - { className: tableClasses, style: { marginTop: 5 } }, - _react2.default.createElement( - 'thead', - null, - _react2.default.createElement( - 'tr', - { style: { borderBottomStyle: 'hidden' } }, - selectRowHeader, - filterField - ) - ) - ); + // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils + return { + href: urlParsingNode.href, + protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '', + host: urlParsingNode.host, + search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '', + hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '', + hostname: urlParsingNode.hostname, + port: urlParsingNode.port, + pathname: (urlParsingNode.pathname.charAt(0) === '/') ? + urlParsingNode.pathname : + '/' + urlParsingNode.pathname + }; } - }]); - - return TableFilter; -}(_react.Component); - -TableFilter.propTypes = { - columns: _propTypes2.default.array, - rowSelectType: _propTypes2.default.string, - onFilter: _propTypes2.default.func -}; -var _default = TableFilter; -exports.default = _default; -; -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } + originURL = resolveURL(window.location.href); - __REACT_HOT_LOADER__.register(TableFilter, 'TableFilter', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableFilter.js'); + /** + * Determine if a URL shares the same origin as the current location + * + * @param {String} requestURL The URL to test + * @returns {boolean} True if URL shares the same origin, otherwise false + */ + return function isURLSameOrigin(requestURL) { + var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL; + return (parsed.protocol === originURL.protocol && + parsed.host === originURL.host); + }; + })() : - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/TableFilter.js'); -}(); + // Non standard browser envs (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return function isURLSameOrigin() { + return true; + }; + })() +); -; /***/ }), -/* 393 */ +/* 345 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.TableDataStore = undefined; +// btoa polyfill for IE<10 courtesy https://github.com/davidchambers/Base64.js -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; +var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='; -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); /* eslint no-nested-ternary: 0 */ -/* eslint guard-for-in: 0 */ -/* eslint no-console: 0 */ -/* eslint eqeqeq: 0 */ -/* eslint one-var: 0 */ +function E() { + this.message = 'String contains an invalid character'; +} +E.prototype = new Error; +E.prototype.code = 5; +E.prototype.name = 'InvalidCharacterError'; +function btoa(input) { + var str = String(input); + var output = ''; + for ( + // initialize result and counter + var block, charCode, idx = 0, map = chars; + // if the next str index does not exist: + // change the mapping table to "=" + // check if d has no fractional digits + str.charAt(idx | 0) || (map = '=', idx % 1); + // "8 - idx % 1 * 8" generates the sequence 2, 4, 6, 8 + output += map.charAt(63 & block >> 8 - idx % 1 * 8) + ) { + charCode = str.charCodeAt(idx += 3 / 4); + if (charCode > 0xFF) { + throw new E(); + } + block = block << 8 | charCode; + } + return output; +} -var _Const = __webpack_require__(22); +module.exports = btoa; -var _Const2 = _interopRequireDefault(_Const); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +/***/ }), +/* 346 */ +/***/ (function(module, exports, __webpack_require__) { -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +"use strict"; -var TableDataStore = function () { - function TableDataStore(data) { - var _this = this; - _classCallCheck(this, TableDataStore); +var utils = __webpack_require__(20); - this.isValidKey = function () { - return _this.__isValidKey__REACT_HOT_LOADER__.apply(_this, arguments); - }; +module.exports = ( + utils.isStandardBrowserEnv() ? - this.data = data; - this.filteredData = null; - this.isOnFilter = false; - this.filterObj = null; - this.searchText = null; - this.sortList = []; - this.pageObj = {}; - this.selected = []; - this.showOnlySelected = false; - } - - _createClass(TableDataStore, [{ - key: 'setProps', - value: function setProps(props) { - this.keyField = props.keyField; - this.enablePagination = props.isPagination; - this.colInfos = props.colInfos; - this.remote = props.remote; - this.multiColumnSearch = props.multiColumnSearch; - // default behaviour if strictSearch prop is not provided: !multiColumnSearch - this.strictSearch = typeof props.strictSearch === 'undefined' ? !props.multiColumnSearch : props.strictSearch; - this.multiColumnSort = props.multiColumnSort; - } - }, { - key: 'clean', - value: function clean() { - this.filteredData = null; - this.isOnFilter = false; - this.filterObj = null; - this.searchText = null; - this.sortList = []; - this.pageObj = {}; - this.selected = []; - } - }, { - key: 'isSearching', - value: function isSearching() { - return this.searchText !== null; - } - }, { - key: 'isFiltering', - value: function isFiltering() { - return this.filterObj !== null; - } - }, { - key: 'setData', - value: function setData(data) { - this.data = data; - if (this.remote) { - return; - } + // Standard browser envs support document.cookie + (function standardBrowserEnv() { + return { + write: function write(name, value, expires, path, domain, secure) { + var cookie = []; + cookie.push(name + '=' + encodeURIComponent(value)); - this._refresh(true); - } - }, { - key: 'getColInfos', - value: function getColInfos() { - return this.colInfos; - } - }, { - key: 'getSortInfo', - value: function getSortInfo() { - return this.sortList; - } - }, { - key: 'setSortInfo', - value: function setSortInfo(order, sortField) { - if ((typeof order === 'undefined' ? 'undefined' : _typeof(order)) !== (typeof sortField === 'undefined' ? 'undefined' : _typeof(sortField))) { - throw new Error('The type of sort field and order should be both with String or Array'); - } - if (Array.isArray(order) && Array.isArray(sortField)) { - if (order.length !== sortField.length) { - throw new Error('The length of sort fields and orders should be equivalent'); + if (utils.isNumber(expires)) { + cookie.push('expires=' + new Date(expires).toGMTString()); } - order = order.slice().reverse(); - this.sortList = sortField.slice().reverse().map(function (field, i) { - return { - order: order[i], - sortField: field - }; - }); - this.sortList = this.sortList.slice(0, this.multiColumnSort); - } else { - var sortObj = { - order: order, - sortField: sortField - }; - if (this.multiColumnSort > 1) { - var i = this.sortList.length - 1; - var sortFieldInHistory = false; - - for (; i >= 0; i--) { - if (this.sortList[i].sortField === sortField) { - sortFieldInHistory = true; - break; - } - } + if (utils.isString(path)) { + cookie.push('path=' + path); + } - if (sortFieldInHistory) { - if (i > 0) { - this.sortList = this.sortList.slice(0, i); - } else { - this.sortList = this.sortList.slice(1); - } - } + if (utils.isString(domain)) { + cookie.push('domain=' + domain); + } - this.sortList.unshift(sortObj); - this.sortList = this.sortList.slice(0, this.multiColumnSort); - } else { - this.sortList = [sortObj]; + if (secure === true) { + cookie.push('secure'); } - } - } - }, { - key: 'cleanSortInfo', - value: function cleanSortInfo() { - this.sortList = []; - } - }, { - key: 'setSelectedRowKey', - value: function setSelectedRowKey(selectedRowKeys) { - this.selected = selectedRowKeys; - } - }, { - key: 'getRowByKey', - value: function getRowByKey(keys) { - var _this2 = this; - // Bad Performance #1164 - // return keys.map(key => { - // const result = this.data.filter(d => d[this.keyField] === key); - // if (result.length !== 0) return result[0]; - // }); - var result = []; - if (!keys || keys.length === 0) { - return result; - } + document.cookie = cookie.join('; '); + }, - var _loop = function _loop(i) { - var d = _this2.data[i]; - if (keys.indexOf(d[_this2.keyField]) > -1) { - keys = keys.filter(function (k) { - return k !== d[_this2.keyField]; - }); - result.push(d); - } - }; + read: function read(name) { + var match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)')); + return (match ? decodeURIComponent(match[3]) : null); + }, - for (var i = 0; i < this.data.length; i++) { - _loop(i); - } - return result; - } - }, { - key: 'getSelectedRowKeys', - value: function getSelectedRowKeys() { - return this.selected; - } - }, { - key: 'getCurrentDisplayData', - value: function getCurrentDisplayData() { - if (this.isOnFilter) return this.filteredData;else return this.data; - } - }, { - key: '_refresh', - value: function _refresh(skipSorting) { - if (this.isOnFilter) { - if (this.filterObj !== null) this.filter(this.filterObj); - if (this.searchText !== null) this.search(this.searchText); - } - if (!skipSorting && this.sortList.length > 0) { - this.sort(); + remove: function remove(name) { + this.write(name, '', Date.now() - 86400000); } - } - }, { - key: 'ignoreNonSelected', - value: function ignoreNonSelected() { - var _this3 = this; + }; + })() : - this.showOnlySelected = !this.showOnlySelected; - if (this.showOnlySelected) { - this.isOnFilter = true; - this.filteredData = this.data.filter(function (row) { - var result = _this3.selected.find(function (x) { - return row[_this3.keyField] === x; - }); - return typeof result !== 'undefined' ? true : false; - }); - } else { - this.isOnFilter = false; - } - } - }, { - key: 'sort', - value: function sort() { - var currentDisplayData = this.getCurrentDisplayData(); + // Non standard browser env (web workers, react-native) lack needed support. + (function nonStandardBrowserEnv() { + return { + write: function write() {}, + read: function read() { return null; }, + remove: function remove() {} + }; + })() +); - currentDisplayData = this._sort(currentDisplayData); - return this; - } - }, { - key: 'page', - value: function page(_page, sizePerPage) { - this.pageObj.end = _page * sizePerPage - 1; - this.pageObj.start = this.pageObj.end - (sizePerPage - 1); - return this; - } - }, { - key: 'edit', - value: function edit(newVal, rowIndex, fieldName) { - var currentDisplayData = this.getCurrentDisplayData(); - var rowKeyCache = void 0; - if (!this.enablePagination) { - currentDisplayData[rowIndex][fieldName] = newVal; - rowKeyCache = currentDisplayData[rowIndex][this.keyField]; - } else { - currentDisplayData[this.pageObj.start + rowIndex][fieldName] = newVal; - rowKeyCache = currentDisplayData[this.pageObj.start + rowIndex][this.keyField]; - } - if (this.isOnFilter) { - this.data.forEach(function (row) { - if (row[this.keyField] === rowKeyCache) { - row[fieldName] = newVal; - } - }, this); - if (this.filterObj !== null) this.filter(this.filterObj); - if (this.searchText !== null) this.search(this.searchText); - } - return this; - } - }, { - key: 'addAtBegin', - value: function addAtBegin(newObj) { - if (!newObj[this.keyField] || newObj[this.keyField].toString() === '') { - throw new Error(this.keyField + ' can\'t be empty value.'); - } - var currentDisplayData = this.getCurrentDisplayData(); - currentDisplayData.forEach(function (row) { - if (row[this.keyField].toString() === newObj[this.keyField].toString()) { - throw new Error(this.keyField + ' ' + newObj[this.keyField] + ' already exists'); - } - }, this); - currentDisplayData.unshift(newObj); - if (this.isOnFilter) { - this.data.unshift(newObj); - } - this._refresh(false); - } - }, { - key: 'add', - value: function add(newObj) { - var e = this.isValidKey(newObj[this.keyField]); - if (e) throw new Error(e); +/***/ }), +/* 347 */ +/***/ (function(module, exports, __webpack_require__) { - var currentDisplayData = this.getCurrentDisplayData(); - currentDisplayData.push(newObj); - if (this.isOnFilter) { - this.data.push(newObj); - } - this._refresh(false); - } - }, { - key: '__isValidKey__REACT_HOT_LOADER__', - value: function __isValidKey__REACT_HOT_LOADER__(key) { - var _this4 = this; +"use strict"; - if (key === null || key === undefined || key.toString() === '') { - return this.keyField + ' can\'t be empty value.'; - } - var currentDisplayData = this.getCurrentDisplayData(); - var exist = currentDisplayData.find(function (row) { - return row[_this4.keyField].toString() === key.toString(); - }); - if (exist) return this.keyField + ' ' + key + ' already exists'; - } - }, { - key: 'remove', - value: function remove(rowKey) { - var _this5 = this; - var currentDisplayData = this.getCurrentDisplayData(); - var result = currentDisplayData.filter(function (row) { - return rowKey.indexOf(row[_this5.keyField]) === -1; - }); +var utils = __webpack_require__(20); - if (this.isOnFilter) { - this.data = this.data.filter(function (row) { - return rowKey.indexOf(row[_this5.keyField]) === -1; - }); - this.filteredData = result; - } else { - this.data = result; - } - } - }, { - key: 'filter', - value: function filter(filterObj) { - if (Object.keys(filterObj).length === 0) { - this.filteredData = null; - this.isOnFilter = false; - this.filterObj = null; - if (this.searchText) this._search(this.data); - } else { - var source = this.data; - this.filterObj = filterObj; - if (this.searchText) { - this._search(source); - source = this.filteredData; - } - this._filter(source); - } - } - }, { - key: 'filterNumber', - value: function filterNumber(targetVal, filterVal, comparator) { - var valid = true; - switch (comparator) { - case '=': - { - if (targetVal != filterVal) { - valid = false; - } - break; - } - case '>': - { - if (targetVal <= filterVal) { - valid = false; - } - break; - } - case '>=': - { - if (targetVal < filterVal) { - valid = false; - } - break; - } - case '<': - { - if (targetVal >= filterVal) { - valid = false; - } - break; - } - case '<=': - { - if (targetVal > filterVal) { - valid = false; - } - break; - } - case '!=': - { - if (targetVal == filterVal) { - valid = false; - } - break; - } - default: - { - console.error('Number comparator provided is not supported'); - break; - } - } - return valid; +function InterceptorManager() { + this.handlers = []; +} + +/** + * Add a new interceptor to the stack + * + * @param {Function} fulfilled The function to handle `then` for a `Promise` + * @param {Function} rejected The function to handle `reject` for a `Promise` + * + * @return {Number} An ID used to remove interceptor later + */ +InterceptorManager.prototype.use = function use(fulfilled, rejected) { + this.handlers.push({ + fulfilled: fulfilled, + rejected: rejected + }); + return this.handlers.length - 1; +}; + +/** + * Remove an interceptor from the stack + * + * @param {Number} id The ID that was returned by `use` + */ +InterceptorManager.prototype.eject = function eject(id) { + if (this.handlers[id]) { + this.handlers[id] = null; + } +}; + +/** + * Iterate over all the registered interceptors + * + * This method is particularly useful for skipping over any + * interceptors that may have become `null` calling `eject`. + * + * @param {Function} fn The function to call for each interceptor + */ +InterceptorManager.prototype.forEach = function forEach(fn) { + utils.forEach(this.handlers, function forEachHandler(h) { + if (h !== null) { + fn(h); } - }, { - key: 'filterDate', - value: function filterDate(targetVal, filterVal, comparator) { - if (!targetVal) return false; + }); +}; - var filterDate = filterVal.getDate(); - var filterMonth = filterVal.getMonth(); - var filterYear = filterVal.getFullYear(); +module.exports = InterceptorManager; - if ((typeof targetVal === 'undefined' ? 'undefined' : _typeof(targetVal)) !== 'object') { - targetVal = new Date(targetVal); - } - var targetDate = targetVal.getDate(); - var targetMonth = targetVal.getMonth(); - var targetYear = targetVal.getFullYear(); +/***/ }), +/* 348 */ +/***/ (function(module, exports, __webpack_require__) { - var valid = true; - switch (comparator) { - case '=': - { - if (filterDate !== targetDate || filterMonth !== targetMonth || filterYear !== targetYear) { - valid = false; - } - break; - } - case '>': - { - if (targetVal <= filterVal) { - valid = false; - } - break; - } - case '>=': - { - if (targetYear < filterYear) { - valid = false; - } else if (targetYear === filterYear && targetMonth < filterMonth) { - valid = false; - } else if (targetYear === filterYear && targetMonth === filterMonth && targetDate < filterDate) { - valid = false; - } - break; - } - case '<': - { - if (targetVal >= filterVal) { - valid = false; - } - break; - } - case '<=': - { - if (targetYear > filterYear) { - valid = false; - } else if (targetYear === filterYear && targetMonth > filterMonth) { - valid = false; - } else if (targetYear === filterYear && targetMonth === filterMonth && targetDate > filterDate) { - valid = false; - } - break; - } - case '!=': - { - if (filterDate === targetDate && filterMonth === targetMonth && filterYear === targetYear) { - valid = false; - } - break; - } - default: - { - console.error('Date comparator provided is not supported'); - break; - } - } - return valid; - } - }, { - key: 'filterRegex', - value: function filterRegex(targetVal, filterVal) { - try { - return new RegExp(filterVal, 'i').test(targetVal); - } catch (e) { - return true; - } - } - }, { - key: 'filterCustom', - value: function filterCustom(targetVal, filterVal, callbackInfo, cond) { - if (callbackInfo !== null && (typeof callbackInfo === 'undefined' ? 'undefined' : _typeof(callbackInfo)) === 'object') { - return callbackInfo.callback(targetVal, callbackInfo.callbackParameters); - } +"use strict"; - return this.filterText(targetVal, filterVal, cond); - } - }, { - key: 'filterText', - value: function filterText(targetVal, filterVal) { - var cond = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : _Const2.default.FILTER_COND_LIKE; - - targetVal = targetVal.toString(); - filterVal = filterVal.toString(); - if (cond === _Const2.default.FILTER_COND_EQ) { - return targetVal === filterVal; - } else { - targetVal = targetVal.toLowerCase(); - filterVal = filterVal.toLowerCase(); - return !(targetVal.indexOf(filterVal) === -1); - } - } - /* General search function - * It will search for the text if the input includes that text; - */ +var utils = __webpack_require__(20); +var transformData = __webpack_require__(349); +var isCancel = __webpack_require__(158); +var defaults = __webpack_require__(94); - }, { - key: 'search', - value: function search(searchText) { - if (searchText.trim() === '') { - this.filteredData = null; - this.isOnFilter = false; - this.searchText = null; - if (this.filterObj) this._filter(this.data); - } else { - var source = this.data; - this.searchText = searchText; - if (this.filterObj) { - this._filter(source); - source = this.filteredData; - } - this._search(source); - } - } - }, { - key: '_filter', - value: function _filter(source) { - var _this6 = this; +/** + * Throws a `Cancel` if cancellation has been requested. + */ +function throwIfCancellationRequested(config) { + if (config.cancelToken) { + config.cancelToken.throwIfRequested(); + } +} - var filterObj = this.filterObj; - this.filteredData = source.filter(function (row, r) { - var valid = true; - var filterVal = void 0; - for (var key in filterObj) { - var targetVal = row[key]; - if (targetVal === null || targetVal === undefined) { - targetVal = ''; - } +/** + * Dispatch a request to the server using the configured adapter. + * + * @param {object} config The config that is to be used for the request + * @returns {Promise} The Promise to be fulfilled + */ +module.exports = function dispatchRequest(config) { + throwIfCancellationRequested(config); - switch (filterObj[key].type) { - case _Const2.default.FILTER_TYPE.NUMBER: - { - filterVal = filterObj[key].value.number; - break; - } - case _Const2.default.FILTER_TYPE.CUSTOM: - { - filterVal = _typeof(filterObj[key].value) === 'object' ? undefined : typeof filterObj[key].value === 'string' ? filterObj[key].value.toLowerCase() : filterObj[key].value; - break; - } - case _Const2.default.FILTER_TYPE.DATE: - { - filterVal = filterObj[key].value.date; - break; - } - case _Const2.default.FILTER_TYPE.REGEX: - { - filterVal = filterObj[key].value; - break; - } - default: - { - filterVal = filterObj[key].value; - if (filterVal === undefined) { - // Support old filter - filterVal = filterObj[key]; - } - break; - } - } - var format = void 0, - filterFormatted = void 0, - formatExtraData = void 0, - filterValue = void 0; - if (_this6.colInfos[key]) { - format = _this6.colInfos[key].format; - filterFormatted = _this6.colInfos[key].filterFormatted; - formatExtraData = _this6.colInfos[key].formatExtraData; - filterValue = _this6.colInfos[key].filterValue; - if (filterFormatted && format) { - targetVal = format(row[key], row, formatExtraData, r); - } else if (filterValue) { - targetVal = filterValue(row[key], row); - } - } + // Ensure headers exist + config.headers = config.headers || {}; - switch (filterObj[key].type) { - case _Const2.default.FILTER_TYPE.NUMBER: - { - valid = _this6.filterNumber(targetVal, filterVal, filterObj[key].value.comparator); - break; - } - case _Const2.default.FILTER_TYPE.DATE: - { - valid = _this6.filterDate(targetVal, filterVal, filterObj[key].value.comparator); - break; - } - case _Const2.default.FILTER_TYPE.REGEX: - { - valid = _this6.filterRegex(targetVal, filterVal); - break; - } - case _Const2.default.FILTER_TYPE.CUSTOM: - { - var cond = filterObj[key].props ? filterObj[key].props.cond : _Const2.default.FILTER_COND_LIKE; - valid = _this6.filterCustom(targetVal, filterVal, filterObj[key].value, cond); - break; - } - default: - { - if (filterObj[key].type === _Const2.default.FILTER_TYPE.SELECT && filterFormatted && filterFormatted && format) { - filterVal = format(filterVal, row, formatExtraData, r); - } - var _cond = filterObj[key].props ? filterObj[key].props.cond : _Const2.default.FILTER_COND_LIKE; - valid = _this6.filterText(targetVal, filterVal, _cond); - break; - } - } - if (!valid) { - break; - } - } - return valid; - }); - this.isOnFilter = true; - } - - /* - * Four different sort modes, all case insensitive: - * (1) strictSearch && !multiColumnSearch - * search text must be contained as provided in a single column - * (2) strictSearch && multiColumnSearch - * conjunction (AND combination) of whitespace separated terms over multiple columns - * (3) !strictSearch && !multiColumnSearch - * conjunction (AND combination) of whitespace separated terms in a single column - * (4) !strictSearch && multiColumnSearch - * any of the whitespace separated terms must be contained in any column - */ + // Transform request data + config.data = transformData( + config.data, + config.headers, + config.transformRequest + ); - }, { - key: '_search', - value: function _search(source) { - var _this7 = this; + // Flatten headers + config.headers = utils.merge( + config.headers.common || {}, + config.headers[config.method] || {}, + config.headers || {} + ); - var searchTextArray = void 0; - if (this.multiColumnSearch || !this.strictSearch) { - // ignore leading and trailing whitespaces - searchTextArray = this.searchText.trim().toLowerCase().split(/\s+/); - } else { - searchTextArray = [this.searchText.toLowerCase()]; - } - var searchTermCount = searchTextArray.length; - var multipleTerms = searchTermCount > 1; - var nonStrictMultiCol = multipleTerms && !this.strictSearch && this.multiColumnSearch; - var nonStrictSingleCol = multipleTerms && !this.strictSearch && !this.multiColumnSearch; - this.filteredData = source.filter(function (row, r) { - var keys = Object.keys(row); - // only clone array if necessary - var searchTerms = multipleTerms ? searchTextArray.slice() : searchTextArray; - // for loops are ugly, but performance matters here. - // And you cant break from a forEach. - // http://jsperf.com/for-vs-foreach/66 - for (var i = 0, keysLength = keys.length; i < keysLength; i++) { - var key = keys[i]; - var colInfo = _this7.colInfos[key]; - if (colInfo && colInfo.searchable) { - var format = colInfo.format, - filterFormatted = colInfo.filterFormatted, - filterValue = colInfo.filterValue, - formatExtraData = colInfo.formatExtraData; - - var targetVal = void 0; - if (filterFormatted && format) { - targetVal = format(row[key], row, formatExtraData, r); - } else if (filterValue) { - targetVal = filterValue(row[key], row); - } else { - targetVal = row[key]; - } - if (targetVal !== null && typeof targetVal !== 'undefined') { - targetVal = targetVal.toString().toLowerCase(); - if (nonStrictSingleCol && searchTermCount > searchTerms.length) { - // reset search terms for single column search - searchTerms = searchTextArray.slice(); - } - for (var j = searchTerms.length - 1; j > -1; j--) { - if (targetVal.indexOf(searchTerms[j]) !== -1) { - if (nonStrictMultiCol || searchTerms.length === 1) { - // match found: the last or only one - return true; - } - // match found: but there are more search terms to check for - searchTerms.splice(j, 1); - } else if (!_this7.multiColumnSearch) { - // one of the search terms was not found in this column - break; - } - } - } - } - } - return false; - }); - this.isOnFilter = true; + utils.forEach( + ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], + function cleanHeaderConfig(method) { + delete config.headers[method]; } - }, { - key: '_sort', - value: function _sort(arr) { - var _this8 = this; + ); - if (this.sortList.length === 0 || typeof this.sortList[0] === 'undefined') { - return arr; - } + var adapter = config.adapter || defaults.adapter; - arr.sort(function (a, b) { - var result = 0; + return adapter(config).then(function onAdapterResolution(response) { + throwIfCancellationRequested(config); - for (var i = 0; i < _this8.sortList.length; i++) { - var sortDetails = _this8.sortList[i]; - var isDesc = sortDetails.order.toLowerCase() === _Const2.default.SORT_DESC; + // Transform response data + response.data = transformData( + response.data, + response.headers, + config.transformResponse + ); - var _colInfos$sortDetails = _this8.colInfos[sortDetails.sortField], - sortFunc = _colInfos$sortDetails.sortFunc, - sortFuncExtraData = _colInfos$sortDetails.sortFuncExtraData; + return response; + }, function onAdapterRejection(reason) { + if (!isCancel(reason)) { + throwIfCancellationRequested(config); + // Transform response data + if (reason && reason.response) { + reason.response.data = transformData( + reason.response.data, + reason.response.headers, + config.transformResponse + ); + } + } - if (sortFunc) { - result = sortFunc(a, b, sortDetails.order, sortDetails.sortField, sortFuncExtraData); - } else { - var valueA = a[sortDetails.sortField] === null ? '' : a[sortDetails.sortField]; - var valueB = b[sortDetails.sortField] === null ? '' : b[sortDetails.sortField]; - if (isDesc) { - if (typeof valueB === 'string') { - result = valueB.localeCompare(valueA); - } else { - result = valueA > valueB ? -1 : valueA < valueB ? 1 : 0; - } - } else { - if (typeof valueA === 'string') { - result = valueA.localeCompare(valueB); - } else { - result = valueA < valueB ? -1 : valueA > valueB ? 1 : 0; - } - } - } + return Promise.reject(reason); + }); +}; - if (result !== 0) { - return result; - } - } - return result; - }); +/***/ }), +/* 349 */ +/***/ (function(module, exports, __webpack_require__) { - return arr; - } - }, { - key: 'getDataIgnoringPagination', - value: function getDataIgnoringPagination() { - return this.getCurrentDisplayData(); - } - }, { - key: 'get', - value: function get() { - var _data = this.getCurrentDisplayData(); +"use strict"; - if (_data.length === 0) return _data; - var remote = typeof this.remote === 'function' ? this.remote(_Const2.default.REMOTE)[_Const2.default.REMOTE_PAGE] : this.remote; +var utils = __webpack_require__(20); - if (remote || !this.enablePagination) { - return _data; - } else { - var result = []; - for (var i = this.pageObj.start; i <= this.pageObj.end; i++) { - result.push(_data[i]); - if (i + 1 === _data.length) break; - } - return result; - } - } - }, { - key: 'getKeyField', - value: function getKeyField() { - return this.keyField; - } - }, { - key: 'getDataNum', - value: function getDataNum() { - return this.getCurrentDisplayData().length; - } - }, { - key: 'isChangedPage', - value: function isChangedPage() { - return this.pageObj.start && this.pageObj.end ? true : false; - } - }, { - key: 'isEmpty', - value: function isEmpty() { - return this.data.length === 0 || this.data === null || this.data === undefined; - } - }, { - key: 'getAllRowkey', - value: function getAllRowkey() { - var _this9 = this; +/** + * Transform the data for a request or a response + * + * @param {Object|String} data The data to be transformed + * @param {Array} headers The headers for the request or response + * @param {Array|Function} fns A single function or Array of functions + * @returns {*} The resulting transformed data + */ +module.exports = function transformData(data, headers, fns) { + /*eslint no-param-reassign:0*/ + utils.forEach(fns, function transform(fn) { + data = fn(data, headers); + }); - return this.data.map(function (row) { - return row[_this9.keyField]; - }); - } - }]); + return data; +}; - return TableDataStore; -}(); -exports.TableDataStore = TableDataStore; -; +/***/ }), +/* 350 */ +/***/ (function(module, exports, __webpack_require__) { -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } +"use strict"; - __REACT_HOT_LOADER__.register(TableDataStore, 'TableDataStore', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/store/TableDataStore.js'); -}(); -; +/** + * Determines whether the specified URL is absolute + * + * @param {string} url The URL to test + * @returns {boolean} True if the specified URL is absolute, otherwise false + */ +module.exports = function isAbsoluteURL(url) { + // A URL is considered absolute if it begins with "<scheme>://" or "//" (protocol-relative URL). + // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed + // by any combination of letters, digits, plus, period, or hyphen. + return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url); +}; + /***/ }), -/* 394 */ +/* 351 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); +/** + * Creates a new URL by combining the specified URLs + * + * @param {string} baseURL The base URL + * @param {string} relativeURL The relative URL + * @returns {string} The combined URL + */ +module.exports = function combineURLs(baseURL, relativeURL) { + return relativeURL + ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '') + : baseURL; +}; -var _util = __webpack_require__(68); -var _util2 = _interopRequireDefault(_util); +/***/ }), +/* 352 */ +/***/ (function(module, exports, __webpack_require__) { -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +"use strict"; -if (_util2.default.canUseDOM()) { - var filesaver = __webpack_require__(395); - var saveAs = filesaver.saveAs; -} /* eslint block-scoped-var: 0 */ -/* eslint vars-on-top: 0 */ -/* eslint no-var: 0 */ -/* eslint no-unused-vars: 0 */ +var Cancel = __webpack_require__(159); -function toString(data, keys, separator, excludeCSVHeader) { - var dataString = ''; - if (data.length === 0) return dataString; +/** + * A `CancelToken` is an object that can be used to request cancellation of an operation. + * + * @class + * @param {Function} executor The executor function. + */ +function CancelToken(executor) { + if (typeof executor !== 'function') { + throw new TypeError('executor must be a function.'); + } - var headCells = []; - var rowCount = 0; - keys.forEach(function (key) { - if (key.row > rowCount) { - rowCount = key.row; - } - // rowCount += (key.rowSpan + key.colSpan - 1); - for (var index = 0; index < key.colSpan; index++) { - headCells.push(key); - } + var resolvePromise; + this.promise = new Promise(function promiseExecutor(resolve) { + resolvePromise = resolve; }); - var firstRow = excludeCSVHeader ? 1 : 0; + var token = this; + executor(function cancel(message) { + if (token.reason) { + // Cancellation has already been requested + return; + } - var _loop = function _loop(i) { - dataString += headCells.map(function (x) { - if (x.row + (x.rowSpan - 1) === i) { - return x.header; - } - if (x.row === i && x.rowSpan > 1) { - return ''; - } - }).filter(function (key) { - return typeof key !== 'undefined'; - }).join(separator) + '\n'; - }; + token.reason = new Cancel(message); + resolvePromise(token.reason); + }); +} - for (var i = firstRow; i <= rowCount; i++) { - _loop(i); +/** + * Throws a `Cancel` if cancellation has been requested. + */ +CancelToken.prototype.throwIfRequested = function throwIfRequested() { + if (this.reason) { + throw this.reason; } +}; - keys = keys.filter(function (key) { - return key.field !== undefined; +/** + * Returns an object that contains a new `CancelToken` and a function that, when called, + * cancels the `CancelToken`. + */ +CancelToken.source = function source() { + var cancel; + var token = new CancelToken(function executor(c) { + cancel = c; }); + return { + token: token, + cancel: cancel + }; +}; - data.map(function (row) { - keys.map(function (col, i) { - var field = col.field, - format = col.format, - extraData = col.extraData; +module.exports = CancelToken; - var value = typeof format !== 'undefined' ? format(row[field], row, extraData) : row[field]; - var cell = typeof value !== 'undefined' ? '"' + value + '"' : ''; - dataString += cell; - if (i + 1 < keys.length) dataString += separator; - }); - dataString += '\n'; - }); +/***/ }), +/* 353 */ +/***/ (function(module, exports, __webpack_require__) { - return dataString; -} +"use strict"; -var exportCSV = function exportCSV(data, keys, filename, separator, noAutoBOM, excludeCSVHeader) { - var dataString = toString(data, keys, separator, excludeCSVHeader); - if (typeof window !== 'undefined') { - noAutoBOM = noAutoBOM === undefined ? true : noAutoBOM; - saveAs(new Blob([dataString], { type: 'text/plain;charset=utf-8' }), filename, noAutoBOM); - } -}; -var _default = exportCSV; -exports.default = _default; -; +/** + * Syntactic sugar for invoking a function and expanding an array for arguments. + * + * Common use case would be to use `Function.prototype.apply`. + * + * ```js + * function f(x, y, z) {} + * var args = [1, 2, 3]; + * f.apply(null, args); + * ``` + * + * With `spread` this example can be re-written. + * + * ```js + * spread(function(x, y, z) {})([1, 2, 3]); + * ``` + * + * @param {Function} callback + * @returns {Function} + */ +module.exports = function spread(callback) { + return function wrap(arr) { + return callback.apply(null, arr); + }; +}; -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } - __REACT_HOT_LOADER__.register(saveAs, 'saveAs', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/csv_export_util.js'); +/***/ }), +/* 354 */ +/***/ (function(module, exports, __webpack_require__) { - __REACT_HOT_LOADER__.register(toString, 'toString', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/csv_export_util.js'); +"use strict"; - __REACT_HOT_LOADER__.register(exportCSV, 'exportCSV', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/csv_export_util.js'); - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/csv_export_util.js'); -}(); +var _require = __webpack_require__(355), + CopyToClipboard = _require.CopyToClipboard; -; +module.exports = CopyToClipboard; /***/ }), -/* 395 */ +/* 355 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var __WEBPACK_AMD_DEFINE_RESULT__; -/* FileSaver.js - * A saveAs() FileSaver implementation. - * 1.3.2 - * 2016-06-16 18:25:19 - * - * By Eli Grey, http://eligrey.com - * License: MIT - * See https://github.com/eligrey/FileSaver.js/blob/master/LICENSE.md - */ -/*global self */ -/*jslint bitwise: true, indent: 4, laxbreak: true, laxcomma: true, smarttabs: true, plusplus: true */ +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.CopyToClipboard = undefined; -/*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */ +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var saveAs = saveAs || function (view) { - "use strict"; - // IE <10 is explicitly unsupported +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - if (typeof view === "undefined" || typeof navigator !== "undefined" && /MSIE [1-9]\./.test(navigator.userAgent)) { - return; - } - var doc = view.document - // only get URL when necessary in case Blob.js hasn't overridden it yet - , - get_URL = function get_URL() { - return view.URL || view.webkitURL || view; - }, - save_link = doc.createElementNS("http://www.w3.org/1999/xhtml", "a"), - can_use_save_link = "download" in save_link, - click = function click(node) { - var event = new MouseEvent("click"); - node.dispatchEvent(event); - }, - is_safari = /constructor/i.test(view.HTMLElement) || view.safari, - is_chrome_ios = /CriOS\/[\d]+/.test(navigator.userAgent), - throw_outside = function throw_outside(ex) { - (view.setImmediate || view.setTimeout)(function () { - throw ex; - }, 0); - }, - force_saveable_type = "application/octet-stream" - // the Blob API is fundamentally broken as there is no "downloadfinished" event to subscribe to - , - arbitrary_revoke_timeout = 1000 * 40 // in ms - , - revoke = function revoke(file) { - var revoker = function revoker() { - if (typeof file === "string") { - // file is an object URL - get_URL().revokeObjectURL(file); - } else { - // file is a File - file.remove(); - } - }; - setTimeout(revoker, arbitrary_revoke_timeout); - }, - dispatch = function dispatch(filesaver, event_types, event) { - event_types = [].concat(event_types); - var i = event_types.length; - while (i--) { - var listener = filesaver["on" + event_types[i]]; - if (typeof listener === "function") { - try { - listener.call(filesaver, event || filesaver); - } catch (ex) { - throw_outside(ex); - } - } - } - }, - auto_bom = function auto_bom(blob) { - // prepend BOM for UTF-8 XML and text/* types (including HTML) - // note: your browser will automatically convert UTF-16 U+FEFF to EF BB BF - if (/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(blob.type)) { - return new Blob([String.fromCharCode(0xFEFF), blob], { type: blob.type }); - } - return blob; - }, - FileSaver = function FileSaver(blob, name, no_auto_bom) { - if (!no_auto_bom) { - blob = auto_bom(blob); - } - // First try a.download, then web filesystem, then object URLs - var filesaver = this, - type = blob.type, - force = type === force_saveable_type, - object_url, - dispatch_all = function dispatch_all() { - dispatch(filesaver, "writestart progress write writeend".split(" ")); - } - // on any filesys errors revert to saving with object URLs - , - fs_error = function fs_error() { - if ((is_chrome_ios || force && is_safari) && view.FileReader) { - // Safari doesn't allow downloading of blob urls - var reader = new FileReader(); - reader.onloadend = function () { - var url = is_chrome_ios ? reader.result : reader.result.replace(/^data:[^;]*;/, 'data:attachment/file;'); - var popup = view.open(url, '_blank'); - if (!popup) view.location.href = url; - url = undefined; // release reference before dispatching - filesaver.readyState = filesaver.DONE; - dispatch_all(); - }; - reader.readAsDataURL(blob); - filesaver.readyState = filesaver.INIT; - return; - } - // don't create more object URLs than needed - if (!object_url) { - object_url = get_URL().createObjectURL(blob); - } - if (force) { - view.location.href = object_url; - } else { - var opened = view.open(object_url, "_blank"); - if (!opened) { - // Apple does not allow window.open, see https://developer.apple.com/library/safari/documentation/Tools/Conceptual/SafariExtensionGuide/WorkingwithWindowsandTabs/WorkingwithWindowsandTabs.html - view.location.href = object_url; - } - } - filesaver.readyState = filesaver.DONE; - dispatch_all(); - revoke(object_url); - }; - filesaver.readyState = filesaver.INIT; - - if (can_use_save_link) { - object_url = get_URL().createObjectURL(blob); - setTimeout(function () { - save_link.href = object_url; - save_link.download = name; - click(save_link); - dispatch_all(); - revoke(object_url); - filesaver.readyState = filesaver.DONE; - }); - return; - } +var _react = __webpack_require__(6); - fs_error(); - }, - FS_proto = FileSaver.prototype, - saveAs = function saveAs(blob, name, no_auto_bom) { - return new FileSaver(blob, name || blob.name || "download", no_auto_bom); - }; - // IE 10+ (native saveAs) - if (typeof navigator !== "undefined" && navigator.msSaveOrOpenBlob) { - return function (blob, name, no_auto_bom) { - name = name || blob.name || "download"; +var _react2 = _interopRequireDefault(_react); - if (!no_auto_bom) { - blob = auto_bom(blob); - } - return navigator.msSaveOrOpenBlob(blob, name); - }; - } +var _copyToClipboard = __webpack_require__(356); - FS_proto.abort = function () {}; - FS_proto.readyState = FS_proto.INIT = 0; - FS_proto.WRITING = 1; - FS_proto.DONE = 2; +var _copyToClipboard2 = _interopRequireDefault(_copyToClipboard); - FS_proto.error = FS_proto.onwritestart = FS_proto.onprogress = FS_proto.onwrite = FS_proto.onabort = FS_proto.onerror = FS_proto.onwriteend = null; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - return saveAs; -}(typeof self !== "undefined" && self || typeof window !== "undefined" && window || undefined.content); -// `self` is undefined in Firefox for Android content script context -// while `this` is nsIContentFrameMessageManager -// with an attribute `content` that corresponds to the window +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } -if (typeof module !== "undefined" && module.exports) { - module.exports.saveAs = saveAs; -} else if ("function" !== "undefined" && __webpack_require__(396) !== null && __webpack_require__(397) !== null) { - !(__WEBPACK_AMD_DEFINE_RESULT__ = function () { - return saveAs; - }.call(exports, __webpack_require__, exports, module), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); -} -; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - __REACT_HOT_LOADER__.register(saveAs, "saveAs", "/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/filesaver.js"); -}(); +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -; +var CopyToClipboard = exports.CopyToClipboard = function (_React$PureComponent) { + _inherits(CopyToClipboard, _React$PureComponent); -/***/ }), -/* 396 */ -/***/ (function(module, exports) { + function CopyToClipboard() { + var _ref; -module.exports = function() { - throw new Error("define cannot be used indirect"); -}; + var _temp, _this, _ret; + _classCallCheck(this, CopyToClipboard); -/***/ }), -/* 397 */ -/***/ (function(module, exports) { + for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } -/* WEBPACK VAR INJECTION */(function(__webpack_amd_options__) {/* globals __webpack_amd_options__ */ -module.exports = __webpack_amd_options__; + return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = CopyToClipboard.__proto__ || Object.getPrototypeOf(CopyToClipboard)).call.apply(_ref, [this].concat(args))), _this), _this.onClick = function (event) { + var _this$props = _this.props, + text = _this$props.text, + onCopy = _this$props.onCopy, + children = _this$props.children, + options = _this$props.options; -/* WEBPACK VAR INJECTION */}.call(exports, {})) -/***/ }), -/* 398 */ -/***/ (function(module, exports, __webpack_require__) { + var elem = _react2.default.Children.only(children); -"use strict"; + var result = (0, _copyToClipboard2.default)(text, options); + if (onCopy) { + onCopy(text, result); + } -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.Filter = undefined; + // Bypass onClick if it was present + if (elem && elem.props && typeof elem.props.onClick === 'function') { + elem.props.onClick(event); + } + }, _temp), _possibleConstructorReturn(_this, _ret); + } -var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; + _createClass(CopyToClipboard, [{ + key: 'render', + value: function render() { + var _props = this.props, + _text = _props.text, + _onCopy = _props.onCopy, + _options = _props.options, + children = _props.children, + props = _objectWithoutProperties(_props, ['text', 'onCopy', 'options', 'children']); -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + var elem = _react2.default.Children.only(children); -var _Const = __webpack_require__(22); + return _react2.default.cloneElement(elem, _extends({}, props, { onClick: this.onClick })); + } + }]); -var _Const2 = _interopRequireDefault(_Const); + return CopyToClipboard; +}(_react2.default.PureComponent); -var _events = __webpack_require__(244); +/***/ }), +/* 356 */ +/***/ (function(module, exports, __webpack_require__) { -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +"use strict"; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +var deselectCurrent = __webpack_require__(357); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +var defaultMessage = 'Copy to clipboard: #{key}, Enter'; -var Filter = exports.Filter = function (_EventEmitter) { - _inherits(Filter, _EventEmitter); +function format(message) { + var copyKey = (/mac os x/i.test(navigator.userAgent) ? '⌘' : 'Ctrl') + '+C'; + return message.replace(/#{\s*key\s*}/g, copyKey); +} - function Filter(data) { - _classCallCheck(this, Filter); +function copy(text, options) { + var debug, message, reselectPrevious, range, selection, mark, success = false; + if (!options) { options = {}; } + debug = options.debug || false; + try { + reselectPrevious = deselectCurrent(); - var _this = _possibleConstructorReturn(this, (Filter.__proto__ || Object.getPrototypeOf(Filter)).call(this, data)); + range = document.createRange(); + selection = document.getSelection(); - _this.currentFilter = {}; - return _this; - } + mark = document.createElement('span'); + mark.textContent = text; + // reset user styles for span element + mark.style.all = 'unset'; + // prevents scrolling to the end of the page + mark.style.position = 'fixed'; + mark.style.top = 0; + mark.style.clip = 'rect(0, 0, 0, 0)'; + // used to preserve spaces and line breaks + mark.style.whiteSpace = 'pre'; + // do not inherit user-select (it may be `none`) + mark.style.webkitUserSelect = 'text'; + mark.style.MozUserSelect = 'text'; + mark.style.msUserSelect = 'text'; + mark.style.userSelect = 'text'; - _createClass(Filter, [{ - key: 'handleFilter', - value: function handleFilter(dataField, value, type, filterObj) { - var filterType = type || _Const2.default.FILTER_TYPE.CUSTOM; + document.body.appendChild(mark); - var props = { - cond: filterObj.condition // Only for select and text filter - }; + range.selectNode(mark); + selection.addRange(range); - if (value !== null && (typeof value === 'undefined' ? 'undefined' : _typeof(value)) === 'object') { - // value of the filter is an object - var hasValue = true; - for (var prop in value) { - if (!value[prop] || value[prop] === '') { - hasValue = false; - break; - } - } - // if one of the object properties is undefined or empty, we remove the filter - if (hasValue) { - this.currentFilter[dataField] = { value: value, type: filterType, props: props }; - } else { - delete this.currentFilter[dataField]; - } - } else if (!value || value.trim() === '') { - delete this.currentFilter[dataField]; + var successful = document.execCommand('copy'); + if (!successful) { + throw new Error('copy command was unsuccessful'); + } + success = true; + } catch (err) { + debug && console.error('unable to copy using execCommand: ', err); + debug && console.warn('trying IE specific stuff'); + try { + window.clipboardData.setData('text', text); + success = true; + } catch (err) { + debug && console.error('unable to copy using clipboardData: ', err); + debug && console.error('falling back to prompt'); + message = format('message' in options ? options.message : defaultMessage); + window.prompt(message, text); + } + } finally { + if (selection) { + if (typeof selection.removeRange == 'function') { + selection.removeRange(range); } else { - this.currentFilter[dataField] = { value: value.trim(), type: filterType, props: props }; + selection.removeAllRanges(); } - this.emit('onFilterChange', this.currentFilter); } - }]); - return Filter; -}(_events.EventEmitter); + if (mark) { + document.body.removeChild(mark); + } + reselectPrevious(); + } + + return success; +} + +module.exports = copy; -; -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; +/***/ }), +/* 357 */ +/***/ (function(module, exports) { + + +module.exports = function () { + var selection = document.getSelection(); + if (!selection.rangeCount) { + return function () {}; } + var active = document.activeElement; - __REACT_HOT_LOADER__.register(Filter, 'Filter', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/Filter.js'); -}(); + var ranges = []; + for (var i = 0; i < selection.rangeCount; i++) { + ranges.push(selection.getRangeAt(i)); + } + + switch (active.tagName.toUpperCase()) { // .toUpperCase handles XHTML + case 'INPUT': + case 'TEXTAREA': + active.blur(); + break; + + default: + active = null; + break; + } + + selection.removeAllRanges(); + return function () { + selection.type === 'Caret' && + selection.removeAllRanges(); + + if (!selection.rangeCount) { + ranges.forEach(function(range) { + selection.addRange(range); + }); + } + + active && + active.focus(); + }; +}; -; /***/ }), -/* 399 */ +/* 358 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -64545,971 +52802,1730 @@ var _temp = function () { Object.defineProperty(exports, "__esModule", { value: true }); +exports.ReactTableDefaults = undefined; + +var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _propTypes = __webpack_require__(9); - -var _propTypes2 = _interopRequireDefault(_propTypes); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } +var _classnames = __webpack_require__(41); -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +var _classnames2 = _interopRequireDefault(_classnames); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +var _utils = __webpack_require__(95); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +var _utils2 = _interopRequireDefault(_utils); -var ButtonGroup = function (_Component) { - _inherits(ButtonGroup, _Component); +var _lifecycle = __webpack_require__(359); - function ButtonGroup() { - _classCallCheck(this, ButtonGroup); +var _lifecycle2 = _interopRequireDefault(_lifecycle); - return _possibleConstructorReturn(this, (ButtonGroup.__proto__ || Object.getPrototypeOf(ButtonGroup)).apply(this, arguments)); - } +var _methods = __webpack_require__(360); - _createClass(ButtonGroup, [{ - key: 'render', - value: function render() { - var _props = this.props, - className = _props.className, - sizeClass = _props.sizeClass, - children = _props.children, - rest = _objectWithoutProperties(_props, ['className', 'sizeClass', 'children']); +var _methods2 = _interopRequireDefault(_methods); - return _react2.default.createElement( - 'div', - _extends({ className: 'btn-group ' + sizeClass + ' ' + className, role: 'group' }, rest), - children - ); - } - }]); +var _defaultProps = __webpack_require__(361); - return ButtonGroup; -}(_react.Component); +var _defaultProps2 = _interopRequireDefault(_defaultProps); -ButtonGroup.propTypes = { - sizeClass: _propTypes2.default.string, - className: _propTypes2.default.string -}; -ButtonGroup.defaultProps = { - sizeClass: 'btn-group-sm', - className: '' -}; +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -var _default = ButtonGroup; -exports.default = _default; -; +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -var _temp = function () { - if (typeof __REACT_HOT_LOADER__ === 'undefined') { - return; - } +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - __REACT_HOT_LOADER__.register(ButtonGroup, 'ButtonGroup', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ButtonGroup.js'); +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +// - __REACT_HOT_LOADER__.register(_default, 'default', '/Users/allen/Node/react-bootstrap-table-new/react-bootstrap-table/src/toolbar/ButtonGroup.js'); -}(); -; +var ReactTableDefaults = exports.ReactTableDefaults = _defaultProps2.default; -/***/ }), -/* 400 */ -/***/ (function(module, exports, __webpack_require__) { +var ReactTable = function (_Methods) { + _inherits(ReactTable, _Methods); -module.exports = __webpack_require__(401); + function ReactTable(props) { + _classCallCheck(this, ReactTable); -/***/ }), -/* 401 */ -/***/ (function(module, exports, __webpack_require__) { + var _this = _possibleConstructorReturn(this, (ReactTable.__proto__ || Object.getPrototypeOf(ReactTable)).call(this)); -"use strict"; + _this.getResolvedState = _this.getResolvedState.bind(_this); + _this.getDataModel = _this.getDataModel.bind(_this); + _this.getSortedData = _this.getSortedData.bind(_this); + _this.fireFetchData = _this.fireFetchData.bind(_this); + _this.getPropOrState = _this.getPropOrState.bind(_this); + _this.getStateOrProp = _this.getStateOrProp.bind(_this); + _this.filterData = _this.filterData.bind(_this); + _this.sortData = _this.sortData.bind(_this); + _this.getMinRows = _this.getMinRows.bind(_this); + _this.onPageChange = _this.onPageChange.bind(_this); + _this.onPageSizeChange = _this.onPageSizeChange.bind(_this); + _this.sortColumn = _this.sortColumn.bind(_this); + _this.filterColumn = _this.filterColumn.bind(_this); + _this.resizeColumnStart = _this.resizeColumnStart.bind(_this); + _this.resizeColumnEnd = _this.resizeColumnEnd.bind(_this); + _this.resizeColumnMoving = _this.resizeColumnMoving.bind(_this); + _this.state = { + page: 0, + pageSize: props.defaultPageSize, + sorted: props.defaultSorted, + expanded: props.defaultExpanded, + filtered: props.defaultFiltered, + resized: props.defaultResized, + currentlyResizing: false, + skipNextSort: false + }; + return _this; + } -var utils = __webpack_require__(46); -var bind = __webpack_require__(301); -var Axios = __webpack_require__(403); -var defaults = __webpack_require__(258); + _createClass(ReactTable, [{ + key: 'render', + value: function render() { + var _this2 = this; -/** - * Create an instance of Axios - * - * @param {Object} defaultConfig The default config for the instance - * @return {Axios} A new instance of Axios - */ -function createInstance(defaultConfig) { - var context = new Axios(defaultConfig); - var instance = bind(Axios.prototype.request, context); + var resolvedState = this.getResolvedState(); + var children = resolvedState.children, + className = resolvedState.className, + style = resolvedState.style, + getProps = resolvedState.getProps, + getTableProps = resolvedState.getTableProps, + getTheadGroupProps = resolvedState.getTheadGroupProps, + getTheadGroupTrProps = resolvedState.getTheadGroupTrProps, + getTheadGroupThProps = resolvedState.getTheadGroupThProps, + getTheadProps = resolvedState.getTheadProps, + getTheadTrProps = resolvedState.getTheadTrProps, + getTheadThProps = resolvedState.getTheadThProps, + getTheadFilterProps = resolvedState.getTheadFilterProps, + getTheadFilterTrProps = resolvedState.getTheadFilterTrProps, + getTheadFilterThProps = resolvedState.getTheadFilterThProps, + getTbodyProps = resolvedState.getTbodyProps, + getTrGroupProps = resolvedState.getTrGroupProps, + getTrProps = resolvedState.getTrProps, + getTdProps = resolvedState.getTdProps, + getTfootProps = resolvedState.getTfootProps, + getTfootTrProps = resolvedState.getTfootTrProps, + getTfootTdProps = resolvedState.getTfootTdProps, + getPaginationProps = resolvedState.getPaginationProps, + getLoadingProps = resolvedState.getLoadingProps, + getNoDataProps = resolvedState.getNoDataProps, + getResizerProps = resolvedState.getResizerProps, + showPagination = resolvedState.showPagination, + showPaginationTop = resolvedState.showPaginationTop, + showPaginationBottom = resolvedState.showPaginationBottom, + manual = resolvedState.manual, + loadingText = resolvedState.loadingText, + noDataText = resolvedState.noDataText, + sortable = resolvedState.sortable, + resizable = resolvedState.resizable, + filterable = resolvedState.filterable, + pivotIDKey = resolvedState.pivotIDKey, + pivotValKey = resolvedState.pivotValKey, + pivotBy = resolvedState.pivotBy, + subRowsKey = resolvedState.subRowsKey, + aggregatedKey = resolvedState.aggregatedKey, + originalKey = resolvedState.originalKey, + indexKey = resolvedState.indexKey, + groupedByPivotKey = resolvedState.groupedByPivotKey, + loading = resolvedState.loading, + pageSize = resolvedState.pageSize, + page = resolvedState.page, + sorted = resolvedState.sorted, + filtered = resolvedState.filtered, + resized = resolvedState.resized, + expanded = resolvedState.expanded, + pages = resolvedState.pages, + onExpandedChange = resolvedState.onExpandedChange, + TableComponent = resolvedState.TableComponent, + TheadComponent = resolvedState.TheadComponent, + TbodyComponent = resolvedState.TbodyComponent, + TrGroupComponent = resolvedState.TrGroupComponent, + TrComponent = resolvedState.TrComponent, + ThComponent = resolvedState.ThComponent, + TdComponent = resolvedState.TdComponent, + TfootComponent = resolvedState.TfootComponent, + PaginationComponent = resolvedState.PaginationComponent, + LoadingComponent = resolvedState.LoadingComponent, + SubComponent = resolvedState.SubComponent, + NoDataComponent = resolvedState.NoDataComponent, + ResizerComponent = resolvedState.ResizerComponent, + ExpanderComponent = resolvedState.ExpanderComponent, + PivotValueComponent = resolvedState.PivotValueComponent, + PivotComponent = resolvedState.PivotComponent, + AggregatedComponent = resolvedState.AggregatedComponent, + FilterComponent = resolvedState.FilterComponent, + PadRowComponent = resolvedState.PadRowComponent, + resolvedData = resolvedState.resolvedData, + allVisibleColumns = resolvedState.allVisibleColumns, + headerGroups = resolvedState.headerGroups, + hasHeaderGroups = resolvedState.hasHeaderGroups, + sortedData = resolvedState.sortedData, + currentlyResizing = resolvedState.currentlyResizing; + + // Pagination + + var startRow = pageSize * page; + var endRow = startRow + pageSize; + var pageRows = manual ? resolvedData : sortedData.slice(startRow, endRow); + var minRows = this.getMinRows(); + var padRows = _utils2.default.range(Math.max(minRows - pageRows.length, 0)); + + var hasColumnFooter = allVisibleColumns.some(function (d) { + return d.Footer; + }); + var hasFilters = filterable || allVisibleColumns.some(function (d) { + return d.filterable; + }); - // Copy axios.prototype to instance - utils.extend(instance, Axios.prototype, context); + var recurseRowsViewIndex = function recurseRowsViewIndex(rows) { + var path = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : []; + var index = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : -1; - // Copy context to instance - utils.extend(instance, context); + return [rows.map(function (row, i) { + index++; + var rowWithViewIndex = _extends({}, row, { + _viewIndex: index + }); + var newPath = path.concat([i]); + if (rowWithViewIndex[subRowsKey] && _utils2.default.get(expanded, newPath)) { + ; + var _recurseRowsViewIndex = recurseRowsViewIndex(rowWithViewIndex[subRowsKey], newPath, index); - return instance; -} + var _recurseRowsViewIndex2 = _slicedToArray(_recurseRowsViewIndex, 2); -// Create the default instance to be exported -var axios = createInstance(defaults); + rowWithViewIndex[subRowsKey] = _recurseRowsViewIndex2[0]; + index = _recurseRowsViewIndex2[1]; + } + return rowWithViewIndex; + }), index]; + }; + var _recurseRowsViewIndex3 = recurseRowsViewIndex(pageRows); -// Expose Axios class to allow class inheritance -axios.Axios = Axios; + var _recurseRowsViewIndex4 = _slicedToArray(_recurseRowsViewIndex3, 1); -// Factory for creating new instances -axios.create = function create(instanceConfig) { - return createInstance(utils.merge(defaults, instanceConfig)); -}; + pageRows = _recurseRowsViewIndex4[0]; -// Expose Cancel & CancelToken -axios.Cancel = __webpack_require__(305); -axios.CancelToken = __webpack_require__(417); -axios.isCancel = __webpack_require__(304); -// Expose all/spread -axios.all = function all(promises) { - return Promise.all(promises); -}; -axios.spread = __webpack_require__(418); + var canPrevious = page > 0; + var canNext = page + 1 < pages; -module.exports = axios; + var rowMinWidth = _utils2.default.sum(allVisibleColumns.map(function (d) { + var resizedColumn = resized.find(function (x) { + return x.id === d.id; + }) || {}; + return _utils2.default.getFirstDefined(resizedColumn.value, d.width, d.minWidth); + })); -// Allow use of default import syntax in TypeScript -module.exports.default = axios; + var rowIndex = -1; + + var finalState = _extends({}, resolvedState, { + startRow: startRow, + endRow: endRow, + pageRows: pageRows, + minRows: minRows, + padRows: padRows, + hasColumnFooter: hasColumnFooter, + canPrevious: canPrevious, + canNext: canNext, + rowMinWidth: rowMinWidth + }); + // Visual Components -/***/ }), -/* 402 */ -/***/ (function(module, exports) { + var makeHeaderGroups = function makeHeaderGroups() { + var theadGroupProps = _utils2.default.splitProps(getTheadGroupProps(finalState, undefined, undefined, _this2)); + var theadGroupTrProps = _utils2.default.splitProps(getTheadGroupTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-headerGroups', theadGroupProps.className), + style: _extends({}, theadGroupProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadGroupProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadGroupTrProps.className, + style: theadGroupTrProps.style + }, theadGroupTrProps.rest), + headerGroups.map(makeHeaderGroup) + ) + ); + }; -/*! - * Determine if an object is a Buffer - * - * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org> - * @license MIT - */ + var makeHeaderGroup = function makeHeaderGroup(column, i) { + var resizedValue = function resizedValue(col) { + return (resized.find(function (x) { + return x.id === col.id; + }) || {}).value; + }; + var flex = _utils2.default.sum(column.columns.map(function (col) { + return col.width || resizedValue(col) ? 0 : col.minWidth; + })); + var width = _utils2.default.sum(column.columns.map(function (col) { + return _utils2.default.getFirstDefined(resizedValue(col), col.width, col.minWidth); + })); + var maxWidth = _utils2.default.sum(column.columns.map(function (col) { + return _utils2.default.getFirstDefined(resizedValue(col), col.width, col.maxWidth); + })); -// The _isBuffer check is for Safari 5-7 support, because it's missing -// Object.prototype.constructor. Remove this eventually -module.exports = function (obj) { - return obj != null && (isBuffer(obj) || isSlowBuffer(obj) || !!obj._isBuffer) -} + var theadGroupThProps = _utils2.default.splitProps(getTheadGroupThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); -function isBuffer (obj) { - return !!obj.constructor && typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj) -} + var classes = [column.headerClassName, theadGroupThProps.className, columnHeaderProps.className]; -// For Node v0.10 support. Remove this eventually. -function isSlowBuffer (obj) { - return typeof obj.readFloatLE === 'function' && typeof obj.slice === 'function' && isBuffer(obj.slice(0, 0)) -} + var styles = _extends({}, column.headerStyle, theadGroupThProps.style, columnHeaderProps.style); + var rest = _extends({}, theadGroupThProps.rest, columnHeaderProps.rest); -/***/ }), -/* 403 */ -/***/ (function(module, exports, __webpack_require__) { + var flexStyles = { + flex: flex + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }; -"use strict"; + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes), + style: _extends({}, styles, flexStyles) + }, rest), + _utils2.default.normalizeComponent(column.Header, { + data: sortedData, + column: column + }) + ); + }; + var makeHeaders = function makeHeaders() { + var theadProps = _utils2.default.splitProps(getTheadProps(finalState, undefined, undefined, _this2)); + var theadTrProps = _utils2.default.splitProps(getTheadTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-header', theadProps.className), + style: _extends({}, theadProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadTrProps.className, + style: theadTrProps.style + }, theadTrProps.rest), + allVisibleColumns.map(makeHeader) + ) + ); + }; -var defaults = __webpack_require__(258); -var utils = __webpack_require__(46); -var InterceptorManager = __webpack_require__(412); -var dispatchRequest = __webpack_require__(413); -var isAbsoluteURL = __webpack_require__(415); -var combineURLs = __webpack_require__(416); + var makeHeader = function makeHeader(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var sort = sorted.find(function (d) { + return d.id === column.id; + }); + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var theadThProps = _utils2.default.splitProps(getTheadThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); -/** - * Create a new instance of Axios - * - * @param {Object} instanceConfig The default config for the instance - */ -function Axios(instanceConfig) { - this.defaults = instanceConfig; - this.interceptors = { - request: new InterceptorManager(), - response: new InterceptorManager() - }; -} + var classes = [column.headerClassName, theadThProps.className, columnHeaderProps.className]; -/** - * Dispatch a request - * - * @param {Object} config The config specific for this request (merged with this.defaults) - */ -Axios.prototype.request = function request(config) { - /*eslint no-param-reassign:0*/ - // Allow for axios('example/url'[, config]) a la fetch API - if (typeof config === 'string') { - config = utils.merge({ - url: arguments[0] - }, arguments[1]); - } + var styles = _extends({}, column.headerStyle, theadThProps.style, columnHeaderProps.style); - config = utils.merge(defaults, this.defaults, { method: 'get' }, config); - config.method = config.method.toLowerCase(); + var rest = _extends({}, theadThProps.rest, columnHeaderProps.rest); - // Support baseURL config - if (config.baseURL && !isAbsoluteURL(config.url)) { - config.url = combineURLs(config.baseURL, config.url); - } + var isResizable = _utils2.default.getFirstDefined(column.resizable, resizable, false); + var resizer = isResizable ? _react2.default.createElement(ResizerComponent, _extends({ + onMouseDown: function onMouseDown(e) { + return _this2.resizeColumnStart(e, column, false); + }, + onTouchStart: function onTouchStart(e) { + return _this2.resizeColumnStart(e, column, true); + } + }, resizerProps)) : null; - // Hook up interceptors middleware - var chain = [dispatchRequest, undefined]; - var promise = Promise.resolve(config); + var isSortable = _utils2.default.getFirstDefined(column.sortable, sortable, false); - this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) { - chain.unshift(interceptor.fulfilled, interceptor.rejected); - }); + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, 'rt-resizable-header', sort ? sort.desc ? '-sort-desc' : '-sort-asc' : '', isSortable && '-cursor-pointer', !show && '-hidden', pivotBy && pivotBy.slice(0, -1).includes(column.id) && 'rt-header-pivot'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }), + toggleSort: function toggleSort(e) { + isSortable && _this2.sortColumn(column, e.shiftKey); + } + }, rest), + _react2.default.createElement( + 'div', + { className: 'rt-resizable-header-content' }, + _utils2.default.normalizeComponent(column.Header, { + data: sortedData, + column: column + }) + ), + resizer + ); + }; - this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) { - chain.push(interceptor.fulfilled, interceptor.rejected); - }); + var makeFilters = function makeFilters() { + var theadFilterProps = _utils2.default.splitProps(getTheadFilterProps(finalState, undefined, undefined, _this2)); + var theadFilterTrProps = _utils2.default.splitProps(getTheadFilterTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TheadComponent, + _extends({ + className: (0, _classnames2.default)('-filters', theadFilterProps.className), + style: _extends({}, theadFilterProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, theadFilterProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: theadFilterTrProps.className, + style: theadFilterTrProps.style + }, theadFilterTrProps.rest), + allVisibleColumns.map(makeFilter) + ) + ); + }; - while (chain.length) { - promise = promise.then(chain.shift(), chain.shift()); - } + var makeFilter = function makeFilter(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var theadFilterThProps = _utils2.default.splitProps(getTheadFilterThProps(finalState, undefined, column, _this2)); + var columnHeaderProps = _utils2.default.splitProps(column.getHeaderProps(finalState, undefined, column, _this2)); - return promise; -}; + var classes = [column.headerClassName, theadFilterThProps.className, columnHeaderProps.className]; -// Provide aliases for supported request methods -utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) { - /*eslint func-names:0*/ - Axios.prototype[method] = function(url, config) { - return this.request(utils.merge(config || {}, { - method: method, - url: url - })); - }; -}); + var styles = _extends({}, column.headerStyle, theadFilterThProps.style, columnHeaderProps.style); -utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) { - /*eslint func-names:0*/ - Axios.prototype[method] = function(url, data, config) { - return this.request(utils.merge(config || {}, { - method: method, - url: url, - data: data - })); - }; -}); + var rest = _extends({}, theadFilterThProps.rest, columnHeaderProps.rest); -module.exports = Axios; + var filter = filtered.find(function (filter) { + return filter.id === column.id; + }); + var ResolvedFilterComponent = column.Filter || FilterComponent; -/***/ }), -/* 404 */ -/***/ (function(module, exports, __webpack_require__) { + var isFilterable = _utils2.default.getFirstDefined(column.filterable, filterable, false); -"use strict"; + return _react2.default.createElement( + ThComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, rest), + isFilterable ? _utils2.default.normalizeComponent(ResolvedFilterComponent, { + column: column, + filter: filter, + onChange: function onChange(value) { + return _this2.filterColumn(column, value); + } + }, _defaultProps2.default.column.Filter) : null + ); + }; + var makePageRow = function makePageRow(row, i) { + var path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : []; + + var rowInfo = { + original: row[originalKey], + row: row, + index: row[indexKey], + viewIndex: ++rowIndex, + level: path.length, + nestingPath: path.concat([i]), + aggregated: row[aggregatedKey], + groupedByPivot: row[groupedByPivotKey], + subRows: row[subRowsKey] + }; + var isExpanded = _utils2.default.get(expanded, rowInfo.nestingPath); + var trGroupProps = getTrGroupProps(finalState, rowInfo, undefined, _this2); + var trProps = _utils2.default.splitProps(getTrProps(finalState, rowInfo, undefined, _this2)); + return _react2.default.createElement( + TrGroupComponent, + _extends({ key: rowInfo.nestingPath.join('_') }, trGroupProps), + _react2.default.createElement( + TrComponent, + _extends({ + className: (0, _classnames2.default)(trProps.className, row._viewIndex % 2 ? '-even' : '-odd'), + style: trProps.style + }, trProps.rest), + allVisibleColumns.map(function (column, i2) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tdProps = _utils2.default.splitProps(getTdProps(finalState, rowInfo, column, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, rowInfo, column, _this2)); + + var classes = [tdProps.className, column.className, columnProps.className]; + + var styles = _extends({}, tdProps.style, column.style, columnProps.style); + + var cellInfo = _extends({}, rowInfo, { + isExpanded: isExpanded, + column: _extends({}, column), + value: rowInfo.row[column.id], + pivoted: column.pivoted, + expander: column.expander, + resized: resized, + show: show, + width: width, + maxWidth: maxWidth, + tdProps: tdProps, + columnProps: columnProps, + classes: classes, + styles: styles + }); -var utils = __webpack_require__(46); + var value = cellInfo.value; -module.exports = function normalizeHeaderName(headers, normalizedName) { - utils.forEach(headers, function processHeader(value, name) { - if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) { - headers[normalizedName] = value; - delete headers[name]; - } - }); -}; + var useOnExpanderClick = void 0; + var isBranch = void 0; + var isPreview = void 0; + var onExpanderClick = function onExpanderClick(e) { + var newExpanded = _utils2.default.clone(expanded); + if (isExpanded) { + newExpanded = _utils2.default.set(newExpanded, cellInfo.nestingPath, false); + } else { + newExpanded = _utils2.default.set(newExpanded, cellInfo.nestingPath, {}); + } -/***/ }), -/* 405 */ -/***/ (function(module, exports, __webpack_require__) { + return _this2.setStateWithData({ + expanded: newExpanded + }, function () { + onExpandedChange && onExpandedChange(newExpanded, cellInfo.nestingPath, e); + }); + }; -"use strict"; + // Default to a standard cell + var resolvedCell = _utils2.default.normalizeComponent(column.Cell, cellInfo, value); + // Resolve Renderers + var ResolvedAggregatedComponent = column.Aggregated || (!column.aggregate ? AggregatedComponent : column.Cell); + var ResolvedExpanderComponent = column.Expander || ExpanderComponent; + var ResolvedPivotValueComponent = column.PivotValue || PivotValueComponent; + var DefaultResolvedPivotComponent = PivotComponent || function (props) { + return _react2.default.createElement( + 'div', + null, + _react2.default.createElement(ResolvedExpanderComponent, props), + _react2.default.createElement(ResolvedPivotValueComponent, props) + ); + }; + var ResolvedPivotComponent = column.Pivot || DefaultResolvedPivotComponent; + + // Is this cell expandable? + if (cellInfo.pivoted || cellInfo.expander) { + // Make it expandable by defualt + cellInfo.expandable = true; + useOnExpanderClick = true; + // If pivoted, has no subRows, and does not have a subComponent, do not make expandable + if (cellInfo.pivoted && !cellInfo.subRows && !SubComponent) { + cellInfo.expandable = false; + } + } -var createError = __webpack_require__(303); + if (cellInfo.pivoted) { + // Is this column a branch? + isBranch = rowInfo.row[pivotIDKey] === column.id && cellInfo.subRows; + // Should this column be blank? + isPreview = pivotBy.indexOf(column.id) > pivotBy.indexOf(rowInfo.row[pivotIDKey]) && cellInfo.subRows; + // Pivot Cell Render Override + if (isBranch) { + // isPivot + resolvedCell = _utils2.default.normalizeComponent(ResolvedPivotComponent, _extends({}, cellInfo, { + value: row[pivotValKey] + }), row[pivotValKey]); + } else if (isPreview) { + // Show the pivot preview + resolvedCell = _utils2.default.normalizeComponent(ResolvedAggregatedComponent, cellInfo, value); + } else { + resolvedCell = null; + } + } else if (cellInfo.aggregated) { + resolvedCell = _utils2.default.normalizeComponent(ResolvedAggregatedComponent, cellInfo, value); + } -/** - * Resolve or reject a Promise based on response status. - * - * @param {Function} resolve A function that resolves the promise. - * @param {Function} reject A function that rejects the promise. - * @param {object} response The response. - */ -module.exports = function settle(resolve, reject, response) { - var validateStatus = response.config.validateStatus; - // Note: status is not exposed by XDomainRequest - if (!response.status || !validateStatus || validateStatus(response.status)) { - resolve(response); - } else { - reject(createError( - 'Request failed with status code ' + response.status, - response.config, - null, - response.request, - response - )); - } -}; + if (cellInfo.expander) { + resolvedCell = _utils2.default.normalizeComponent(ResolvedExpanderComponent, cellInfo, row[pivotValKey]); + if (pivotBy) { + if (cellInfo.groupedByPivot) { + resolvedCell = null; + } + if (!cellInfo.subRows && !SubComponent) { + resolvedCell = null; + } + } + } + var resolvedOnExpanderClick = useOnExpanderClick ? onExpanderClick : function () {}; -/***/ }), -/* 406 */ -/***/ (function(module, exports, __webpack_require__) { + // If there are multiple onClick events, make sure they don't override eachother. This should maybe be expanded to handle all function attributes + var interactionProps = { + onClick: resolvedOnExpanderClick + }; -"use strict"; + if (tdProps.rest.onClick) { + interactionProps.onClick = function (e) { + tdProps.rest.onClick(e, function () { + return resolvedOnExpanderClick(e); + }); + }; + } + if (columnProps.rest.onClick) { + interactionProps.onClick = function (e) { + columnProps.rest.onClick(e, function () { + return resolvedOnExpanderClick(e); + }); + }; + } -/** - * Update an Error with the specified config, error code, and response. - * - * @param {Error} error The error to update. - * @param {Object} config The config. - * @param {string} [code] The error code (for example, 'ECONNABORTED'). - * @param {Object} [request] The request. - * @param {Object} [response] The response. - * @returns {Error} The error. - */ -module.exports = function enhanceError(error, config, code, request, response) { - error.config = config; - if (code) { - error.code = code; - } - error.request = request; - error.response = response; - return error; -}; + // Return the cell + return _react2.default.createElement( + TdComponent, + _extends({ + key: i2 + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden', cellInfo.expandable && 'rt-expandable', (isBranch || isPreview) && 'rt-pivot'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, tdProps.rest, columnProps.rest, interactionProps), + resolvedCell + ); + }) + ), + rowInfo.subRows && isExpanded && rowInfo.subRows.map(function (d, i) { + return makePageRow(d, i, rowInfo.nestingPath); + }), + SubComponent && !rowInfo.subRows && isExpanded && SubComponent(rowInfo) + ); + }; + var makePadRow = function makePadRow(row, i) { + var trGroupProps = getTrGroupProps(finalState, undefined, undefined, _this2); + var trProps = _utils2.default.splitProps(getTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TrGroupComponent, + _extends({ key: i }, trGroupProps), + _react2.default.createElement( + TrComponent, + { + className: (0, _classnames2.default)('-padRow', (pageRows.length + i) % 2 ? '-even' : '-odd', trProps.className), + style: trProps.style || {} + }, + allVisibleColumns.map(makePadColumn) + ) + ); + }; -/***/ }), -/* 407 */ -/***/ (function(module, exports, __webpack_require__) { + var makePadColumn = function makePadColumn(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var flex = width; + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tdProps = _utils2.default.splitProps(getTdProps(finalState, undefined, column, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, undefined, column, _this2)); -"use strict"; + var classes = [tdProps.className, column.className, columnProps.className]; + var styles = _extends({}, tdProps.style, column.style, columnProps.style); -var utils = __webpack_require__(46); + return _react2.default.createElement( + TdComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden'), + style: _extends({}, styles, { + flex: flex + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, tdProps.rest), + _utils2.default.normalizeComponent(PadRowComponent) + ); + }; -function encode(val) { - return encodeURIComponent(val). - replace(/%40/gi, '@'). - replace(/%3A/gi, ':'). - replace(/%24/g, '$'). - replace(/%2C/gi, ','). - replace(/%20/g, '+'). - replace(/%5B/gi, '['). - replace(/%5D/gi, ']'); -} + var makeColumnFooters = function makeColumnFooters() { + var tFootProps = getTfootProps(finalState, undefined, undefined, _this2); + var tFootTrProps = _utils2.default.splitProps(getTfootTrProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement( + TfootComponent, + _extends({ + className: tFootProps.className, + style: _extends({}, tFootProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, tFootProps.rest), + _react2.default.createElement( + TrComponent, + _extends({ + className: (0, _classnames2.default)(tFootTrProps.className), + style: tFootTrProps.style + }, tFootTrProps.rest), + allVisibleColumns.map(makeColumnFooter) + ) + ); + }; -/** - * Build a URL by appending params to the end - * - * @param {string} url The base of the url (e.g., http://www.google.com) - * @param {object} [params] The params to be appended - * @returns {string} The formatted url - */ -module.exports = function buildURL(url, params, paramsSerializer) { - /*eslint no-param-reassign:0*/ - if (!params) { - return url; - } + var makeColumnFooter = function makeColumnFooter(column, i) { + var resizedCol = resized.find(function (x) { + return x.id === column.id; + }) || {}; + var show = typeof column.show === 'function' ? column.show() : column.show; + var width = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.minWidth); + var maxWidth = _utils2.default.getFirstDefined(resizedCol.value, column.width, column.maxWidth); + var tFootTdProps = _utils2.default.splitProps(getTfootTdProps(finalState, undefined, undefined, _this2)); + var columnProps = _utils2.default.splitProps(column.getProps(finalState, undefined, column, _this2)); + var columnFooterProps = _utils2.default.splitProps(column.getFooterProps(finalState, undefined, column, _this2)); - var serializedParams; - if (paramsSerializer) { - serializedParams = paramsSerializer(params); - } else if (utils.isURLSearchParams(params)) { - serializedParams = params.toString(); - } else { - var parts = []; + var classes = [tFootTdProps.className, column.className, columnProps.className, columnFooterProps.className]; - utils.forEach(params, function serialize(val, key) { - if (val === null || typeof val === 'undefined') { - return; - } + var styles = _extends({}, tFootTdProps.style, column.style, columnProps.style, columnFooterProps.style); - if (utils.isArray(val)) { - key = key + '[]'; - } + return _react2.default.createElement( + TdComponent, + _extends({ + key: i + '-' + column.id, + className: (0, _classnames2.default)(classes, !show && 'hidden'), + style: _extends({}, styles, { + flex: width + ' 0 auto', + width: _utils2.default.asPx(width), + maxWidth: _utils2.default.asPx(maxWidth) + }) + }, columnProps.rest, tFootTdProps.rest, columnFooterProps.rest), + _utils2.default.normalizeComponent(column.Footer, { + data: sortedData, + column: column + }) + ); + }; - if (!utils.isArray(val)) { - val = [val]; - } + var makePagination = function makePagination() { + var paginationProps = _utils2.default.splitProps(getPaginationProps(finalState, undefined, undefined, _this2)); + return _react2.default.createElement(PaginationComponent, _extends({}, resolvedState, { + pages: pages, + canPrevious: canPrevious, + canNext: canNext, + onPageChange: _this2.onPageChange, + onPageSizeChange: _this2.onPageSizeChange, + className: paginationProps.className, + style: paginationProps.style + }, paginationProps.rest)); + }; - utils.forEach(val, function parseValue(v) { - if (utils.isDate(v)) { - v = v.toISOString(); - } else if (utils.isObject(v)) { - v = JSON.stringify(v); - } - parts.push(encode(key) + '=' + encode(v)); - }); - }); + var rootProps = _utils2.default.splitProps(getProps(finalState, undefined, undefined, this)); + var tableProps = _utils2.default.splitProps(getTableProps(finalState, undefined, undefined, this)); + var tBodyProps = _utils2.default.splitProps(getTbodyProps(finalState, undefined, undefined, this)); + var loadingProps = getLoadingProps(finalState, undefined, undefined, this); + var noDataProps = getNoDataProps(finalState, undefined, undefined, this); + var resizerProps = getResizerProps(finalState, undefined, undefined, this); - serializedParams = parts.join('&'); - } + var makeTable = function makeTable() { + var pagination = makePagination(); + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)('ReactTable', className, rootProps.className), + style: _extends({}, style, rootProps.style) + }, rootProps.rest), + showPagination && showPaginationTop ? _react2.default.createElement( + 'div', + { className: 'pagination-top' }, + pagination + ) : null, + _react2.default.createElement( + TableComponent, + _extends({ + className: (0, _classnames2.default)(tableProps.className, currentlyResizing ? 'rt-resizing' : ''), + style: tableProps.style + }, tableProps.rest), + hasHeaderGroups ? makeHeaderGroups() : null, + makeHeaders(), + hasFilters ? makeFilters() : null, + _react2.default.createElement( + TbodyComponent, + _extends({ + className: (0, _classnames2.default)(tBodyProps.className), + style: _extends({}, tBodyProps.style, { + minWidth: rowMinWidth + 'px' + }) + }, tBodyProps.rest), + pageRows.map(function (d, i) { + return makePageRow(d, i); + }), + padRows.map(makePadRow) + ), + hasColumnFooter ? makeColumnFooters() : null + ), + showPagination && showPaginationBottom ? _react2.default.createElement( + 'div', + { className: 'pagination-bottom' }, + pagination + ) : null, + !pageRows.length && _react2.default.createElement( + NoDataComponent, + noDataProps, + _utils2.default.normalizeComponent(noDataText) + ), + _react2.default.createElement(LoadingComponent, _extends({ + loading: loading, + loadingText: loadingText + }, loadingProps)) + ); + }; - if (serializedParams) { - url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams; - } + // childProps are optionally passed to a function-as-a-child + return children ? children(finalState, makeTable, this) : makeTable(); + } + }]); - return url; -}; + return ReactTable; +}((0, _methods2.default)((0, _lifecycle2.default)(_react.Component))); +ReactTable.defaultProps = _defaultProps2.default; +exports.default = ReactTable; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC5qcyJdLCJuYW1lcyI6WyJSZWFjdFRhYmxlRGVmYXVsdHMiLCJSZWFjdFRhYmxlIiwicHJvcHMiLCJnZXRSZXNvbHZlZFN0YXRlIiwiYmluZCIsImdldERhdGFNb2RlbCIsImdldFNvcnRlZERhdGEiLCJmaXJlRmV0Y2hEYXRhIiwiZ2V0UHJvcE9yU3RhdGUiLCJnZXRTdGF0ZU9yUHJvcCIsImZpbHRlckRhdGEiLCJzb3J0RGF0YSIsImdldE1pblJvd3MiLCJvblBhZ2VDaGFuZ2UiLCJvblBhZ2VTaXplQ2hhbmdlIiwic29ydENvbHVtbiIsImZpbHRlckNvbHVtbiIsInJlc2l6ZUNvbHVtblN0YXJ0IiwicmVzaXplQ29sdW1uRW5kIiwicmVzaXplQ29sdW1uTW92aW5nIiwic3RhdGUiLCJwYWdlIiwicGFnZVNpemUiLCJkZWZhdWx0UGFnZVNpemUiLCJzb3J0ZWQiLCJkZWZhdWx0U29ydGVkIiwiZXhwYW5kZWQiLCJkZWZhdWx0RXhwYW5kZWQiLCJmaWx0ZXJlZCIsImRlZmF1bHRGaWx0ZXJlZCIsInJlc2l6ZWQiLCJkZWZhdWx0UmVzaXplZCIsImN1cnJlbnRseVJlc2l6aW5nIiwic2tpcE5leHRTb3J0IiwicmVzb2x2ZWRTdGF0ZSIsImNoaWxkcmVuIiwiY2xhc3NOYW1lIiwic3R5bGUiLCJnZXRQcm9wcyIsImdldFRhYmxlUHJvcHMiLCJnZXRUaGVhZEdyb3VwUHJvcHMiLCJnZXRUaGVhZEdyb3VwVHJQcm9wcyIsImdldFRoZWFkR3JvdXBUaFByb3BzIiwiZ2V0VGhlYWRQcm9wcyIsImdldFRoZWFkVHJQcm9wcyIsImdldFRoZWFkVGhQcm9wcyIsImdldFRoZWFkRmlsdGVyUHJvcHMiLCJnZXRUaGVhZEZpbHRlclRyUHJvcHMiLCJnZXRUaGVhZEZpbHRlclRoUHJvcHMiLCJnZXRUYm9keVByb3BzIiwiZ2V0VHJHcm91cFByb3BzIiwiZ2V0VHJQcm9wcyIsImdldFRkUHJvcHMiLCJnZXRUZm9vdFByb3BzIiwiZ2V0VGZvb3RUclByb3BzIiwiZ2V0VGZvb3RUZFByb3BzIiwiZ2V0UGFnaW5hdGlvblByb3BzIiwiZ2V0TG9hZGluZ1Byb3BzIiwiZ2V0Tm9EYXRhUHJvcHMiLCJnZXRSZXNpemVyUHJvcHMiLCJzaG93UGFnaW5hdGlvbiIsInNob3dQYWdpbmF0aW9uVG9wIiwic2hvd1BhZ2luYXRpb25Cb3R0b20iLCJtYW51YWwiLCJsb2FkaW5nVGV4dCIsIm5vRGF0YVRleHQiLCJzb3J0YWJsZSIsInJlc2l6YWJsZSIsImZpbHRlcmFibGUiLCJwaXZvdElES2V5IiwicGl2b3RWYWxLZXkiLCJwaXZvdEJ5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJsb2FkaW5nIiwicGFnZXMiLCJvbkV4cGFuZGVkQ2hhbmdlIiwiVGFibGVDb21wb25lbnQiLCJUaGVhZENvbXBvbmVudCIsIlRib2R5Q29tcG9uZW50IiwiVHJHcm91cENvbXBvbmVudCIsIlRyQ29tcG9uZW50IiwiVGhDb21wb25lbnQiLCJUZENvbXBvbmVudCIsIlRmb290Q29tcG9uZW50IiwiUGFnaW5hdGlvbkNvbXBvbmVudCIsIkxvYWRpbmdDb21wb25lbnQiLCJTdWJDb21wb25lbnQiLCJOb0RhdGFDb21wb25lbnQiLCJSZXNpemVyQ29tcG9uZW50IiwiRXhwYW5kZXJDb21wb25lbnQiLCJQaXZvdFZhbHVlQ29tcG9uZW50IiwiUGl2b3RDb21wb25lbnQiLCJBZ2dyZWdhdGVkQ29tcG9uZW50IiwiRmlsdGVyQ29tcG9uZW50IiwiUGFkUm93Q29tcG9uZW50IiwicmVzb2x2ZWREYXRhIiwiYWxsVmlzaWJsZUNvbHVtbnMiLCJoZWFkZXJHcm91cHMiLCJoYXNIZWFkZXJHcm91cHMiLCJzb3J0ZWREYXRhIiwic3RhcnRSb3ciLCJlbmRSb3ciLCJwYWdlUm93cyIsInNsaWNlIiwibWluUm93cyIsInBhZFJvd3MiLCJyYW5nZSIsIk1hdGgiLCJtYXgiLCJsZW5ndGgiLCJoYXNDb2x1bW5Gb290ZXIiLCJzb21lIiwiZCIsIkZvb3RlciIsImhhc0ZpbHRlcnMiLCJyZWN1cnNlUm93c1ZpZXdJbmRleCIsInJvd3MiLCJwYXRoIiwiaW5kZXgiLCJtYXAiLCJyb3ciLCJpIiwicm93V2l0aFZpZXdJbmRleCIsIl92aWV3SW5kZXgiLCJuZXdQYXRoIiwiY29uY2F0IiwiZ2V0IiwiY2FuUHJldmlvdXMiLCJjYW5OZXh0Iiwicm93TWluV2lkdGgiLCJzdW0iLCJyZXNpemVkQ29sdW1uIiwiZmluZCIsIngiLCJpZCIsImdldEZpcnN0RGVmaW5lZCIsInZhbHVlIiwid2lkdGgiLCJtaW5XaWR0aCIsInJvd0luZGV4IiwiZmluYWxTdGF0ZSIsIm1ha2VIZWFkZXJHcm91cHMiLCJ0aGVhZEdyb3VwUHJvcHMiLCJzcGxpdFByb3BzIiwidW5kZWZpbmVkIiwidGhlYWRHcm91cFRyUHJvcHMiLCJyZXN0IiwibWFrZUhlYWRlckdyb3VwIiwiY29sdW1uIiwicmVzaXplZFZhbHVlIiwiY29sIiwiZmxleCIsImNvbHVtbnMiLCJtYXhXaWR0aCIsInRoZWFkR3JvdXBUaFByb3BzIiwiY29sdW1uSGVhZGVyUHJvcHMiLCJnZXRIZWFkZXJQcm9wcyIsImNsYXNzZXMiLCJoZWFkZXJDbGFzc05hbWUiLCJzdHlsZXMiLCJoZWFkZXJTdHlsZSIsImZsZXhTdHlsZXMiLCJhc1B4Iiwibm9ybWFsaXplQ29tcG9uZW50IiwiSGVhZGVyIiwiZGF0YSIsIm1ha2VIZWFkZXJzIiwidGhlYWRQcm9wcyIsInRoZWFkVHJQcm9wcyIsIm1ha2VIZWFkZXIiLCJyZXNpemVkQ29sIiwic29ydCIsInNob3ciLCJ0aGVhZFRoUHJvcHMiLCJpc1Jlc2l6YWJsZSIsInJlc2l6ZXIiLCJlIiwicmVzaXplclByb3BzIiwiaXNTb3J0YWJsZSIsImRlc2MiLCJpbmNsdWRlcyIsInNoaWZ0S2V5IiwibWFrZUZpbHRlcnMiLCJ0aGVhZEZpbHRlclByb3BzIiwidGhlYWRGaWx0ZXJUclByb3BzIiwibWFrZUZpbHRlciIsInRoZWFkRmlsdGVyVGhQcm9wcyIsImZpbHRlciIsIlJlc29sdmVkRmlsdGVyQ29tcG9uZW50IiwiRmlsdGVyIiwiaXNGaWx0ZXJhYmxlIiwib25DaGFuZ2UiLCJtYWtlUGFnZVJvdyIsInJvd0luZm8iLCJvcmlnaW5hbCIsInZpZXdJbmRleCIsImxldmVsIiwibmVzdGluZ1BhdGgiLCJhZ2dyZWdhdGVkIiwiZ3JvdXBlZEJ5UGl2b3QiLCJzdWJSb3dzIiwiaXNFeHBhbmRlZCIsInRyR3JvdXBQcm9wcyIsInRyUHJvcHMiLCJqb2luIiwiaTIiLCJ0ZFByb3BzIiwiY29sdW1uUHJvcHMiLCJjZWxsSW5mbyIsInBpdm90ZWQiLCJleHBhbmRlciIsInVzZU9uRXhwYW5kZXJDbGljayIsImlzQnJhbmNoIiwiaXNQcmV2aWV3Iiwib25FeHBhbmRlckNsaWNrIiwibmV3RXhwYW5kZWQiLCJjbG9uZSIsInNldCIsInNldFN0YXRlV2l0aERhdGEiLCJyZXNvbHZlZENlbGwiLCJDZWxsIiwiUmVzb2x2ZWRBZ2dyZWdhdGVkQ29tcG9uZW50IiwiQWdncmVnYXRlZCIsImFnZ3JlZ2F0ZSIsIlJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQiLCJFeHBhbmRlciIsIlJlc29sdmVkUGl2b3RWYWx1ZUNvbXBvbmVudCIsIlBpdm90VmFsdWUiLCJEZWZhdWx0UmVzb2x2ZWRQaXZvdENvbXBvbmVudCIsIlJlc29sdmVkUGl2b3RDb21wb25lbnQiLCJQaXZvdCIsImV4cGFuZGFibGUiLCJpbmRleE9mIiwicmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2siLCJpbnRlcmFjdGlvblByb3BzIiwib25DbGljayIsIm1ha2VQYWRSb3ciLCJtYWtlUGFkQ29sdW1uIiwibWFrZUNvbHVtbkZvb3RlcnMiLCJ0Rm9vdFByb3BzIiwidEZvb3RUclByb3BzIiwibWFrZUNvbHVtbkZvb3RlciIsInRGb290VGRQcm9wcyIsImNvbHVtbkZvb3RlclByb3BzIiwiZ2V0Rm9vdGVyUHJvcHMiLCJtYWtlUGFnaW5hdGlvbiIsInBhZ2luYXRpb25Qcm9wcyIsInJvb3RQcm9wcyIsInRhYmxlUHJvcHMiLCJ0Qm9keVByb3BzIiwibG9hZGluZ1Byb3BzIiwibm9EYXRhUHJvcHMiLCJtYWtlVGFibGUiLCJwYWdpbmF0aW9uIiwiZGVmYXVsdFByb3BzIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7O0FBQUE7Ozs7QUFDQTs7OztBQUVBOzs7O0FBQ0E7Ozs7QUFDQTs7OztBQUNBOzs7Ozs7Ozs7OztBQUpBOzs7QUFNTyxJQUFNQSx3RUFBTjs7SUFFY0MsVTs7O0FBR25CLHNCQUFhQyxLQUFiLEVBQW9CO0FBQUE7O0FBQUE7O0FBR2xCLFVBQUtDLGdCQUFMLEdBQXdCLE1BQUtBLGdCQUFMLENBQXNCQyxJQUF0QixPQUF4QjtBQUNBLFVBQUtDLFlBQUwsR0FBb0IsTUFBS0EsWUFBTCxDQUFrQkQsSUFBbEIsT0FBcEI7QUFDQSxVQUFLRSxhQUFMLEdBQXFCLE1BQUtBLGFBQUwsQ0FBbUJGLElBQW5CLE9BQXJCO0FBQ0EsVUFBS0csYUFBTCxHQUFxQixNQUFLQSxhQUFMLENBQW1CSCxJQUFuQixPQUFyQjtBQUNBLFVBQUtJLGNBQUwsR0FBc0IsTUFBS0EsY0FBTCxDQUFvQkosSUFBcEIsT0FBdEI7QUFDQSxVQUFLSyxjQUFMLEdBQXNCLE1BQUtBLGNBQUwsQ0FBb0JMLElBQXBCLE9BQXRCO0FBQ0EsVUFBS00sVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCTixJQUFoQixPQUFsQjtBQUNBLFVBQUtPLFFBQUwsR0FBZ0IsTUFBS0EsUUFBTCxDQUFjUCxJQUFkLE9BQWhCO0FBQ0EsVUFBS1EsVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCUixJQUFoQixPQUFsQjtBQUNBLFVBQUtTLFlBQUwsR0FBb0IsTUFBS0EsWUFBTCxDQUFrQlQsSUFBbEIsT0FBcEI7QUFDQSxVQUFLVSxnQkFBTCxHQUF3QixNQUFLQSxnQkFBTCxDQUFzQlYsSUFBdEIsT0FBeEI7QUFDQSxVQUFLVyxVQUFMLEdBQWtCLE1BQUtBLFVBQUwsQ0FBZ0JYLElBQWhCLE9BQWxCO0FBQ0EsVUFBS1ksWUFBTCxHQUFvQixNQUFLQSxZQUFMLENBQWtCWixJQUFsQixPQUFwQjtBQUNBLFVBQUthLGlCQUFMLEdBQXlCLE1BQUtBLGlCQUFMLENBQXVCYixJQUF2QixPQUF6QjtBQUNBLFVBQUtjLGVBQUwsR0FBdUIsTUFBS0EsZUFBTCxDQUFxQmQsSUFBckIsT0FBdkI7QUFDQSxVQUFLZSxrQkFBTCxHQUEwQixNQUFLQSxrQkFBTCxDQUF3QmYsSUFBeEIsT0FBMUI7O0FBRUEsVUFBS2dCLEtBQUwsR0FBYTtBQUNYQyxZQUFNLENBREs7QUFFWEMsZ0JBQVVwQixNQUFNcUIsZUFGTDtBQUdYQyxjQUFRdEIsTUFBTXVCLGFBSEg7QUFJWEMsZ0JBQVV4QixNQUFNeUIsZUFKTDtBQUtYQyxnQkFBVTFCLE1BQU0yQixlQUxMO0FBTVhDLGVBQVM1QixNQUFNNkIsY0FOSjtBQU9YQyx5QkFBbUIsS0FQUjtBQVFYQyxvQkFBYztBQVJILEtBQWI7QUFwQmtCO0FBOEJuQjs7Ozs2QkFFUztBQUFBOztBQUNSLFVBQU1DLGdCQUFnQixLQUFLL0IsZ0JBQUwsRUFBdEI7QUFEUSxVQUdOZ0MsUUFITSxHQW9GSkQsYUFwRkksQ0FHTkMsUUFITTtBQUFBLFVBSU5DLFNBSk0sR0FvRkpGLGFBcEZJLENBSU5FLFNBSk07QUFBQSxVQUtOQyxLQUxNLEdBb0ZKSCxhQXBGSSxDQUtORyxLQUxNO0FBQUEsVUFNTkMsUUFOTSxHQW9GSkosYUFwRkksQ0FNTkksUUFOTTtBQUFBLFVBT05DLGFBUE0sR0FvRkpMLGFBcEZJLENBT05LLGFBUE07QUFBQSxVQVFOQyxrQkFSTSxHQW9GSk4sYUFwRkksQ0FRTk0sa0JBUk07QUFBQSxVQVNOQyxvQkFUTSxHQW9GSlAsYUFwRkksQ0FTTk8sb0JBVE07QUFBQSxVQVVOQyxvQkFWTSxHQW9GSlIsYUFwRkksQ0FVTlEsb0JBVk07QUFBQSxVQVdOQyxhQVhNLEdBb0ZKVCxhQXBGSSxDQVdOUyxhQVhNO0FBQUEsVUFZTkMsZUFaTSxHQW9GSlYsYUFwRkksQ0FZTlUsZUFaTTtBQUFBLFVBYU5DLGVBYk0sR0FvRkpYLGFBcEZJLENBYU5XLGVBYk07QUFBQSxVQWNOQyxtQkFkTSxHQW9GSlosYUFwRkksQ0FjTlksbUJBZE07QUFBQSxVQWVOQyxxQkFmTSxHQW9GSmIsYUFwRkksQ0FlTmEscUJBZk07QUFBQSxVQWdCTkMscUJBaEJNLEdBb0ZKZCxhQXBGSSxDQWdCTmMscUJBaEJNO0FBQUEsVUFpQk5DLGFBakJNLEdBb0ZKZixhQXBGSSxDQWlCTmUsYUFqQk07QUFBQSxVQWtCTkMsZUFsQk0sR0FvRkpoQixhQXBGSSxDQWtCTmdCLGVBbEJNO0FBQUEsVUFtQk5DLFVBbkJNLEdBb0ZKakIsYUFwRkksQ0FtQk5pQixVQW5CTTtBQUFBLFVBb0JOQyxVQXBCTSxHQW9GSmxCLGFBcEZJLENBb0JOa0IsVUFwQk07QUFBQSxVQXFCTkMsYUFyQk0sR0FvRkpuQixhQXBGSSxDQXFCTm1CLGFBckJNO0FBQUEsVUFzQk5DLGVBdEJNLEdBb0ZKcEIsYUFwRkksQ0FzQk5vQixlQXRCTTtBQUFBLFVBdUJOQyxlQXZCTSxHQW9GSnJCLGFBcEZJLENBdUJOcUIsZUF2Qk07QUFBQSxVQXdCTkMsa0JBeEJNLEdBb0ZKdEIsYUFwRkksQ0F3Qk5zQixrQkF4Qk07QUFBQSxVQXlCTkMsZUF6Qk0sR0FvRkp2QixhQXBGSSxDQXlCTnVCLGVBekJNO0FBQUEsVUEwQk5DLGNBMUJNLEdBb0ZKeEIsYUFwRkksQ0EwQk53QixjQTFCTTtBQUFBLFVBMkJOQyxlQTNCTSxHQW9GSnpCLGFBcEZJLENBMkJOeUIsZUEzQk07QUFBQSxVQTRCTkMsY0E1Qk0sR0FvRkoxQixhQXBGSSxDQTRCTjBCLGNBNUJNO0FBQUEsVUE2Qk5DLGlCQTdCTSxHQW9GSjNCLGFBcEZJLENBNkJOMkIsaUJBN0JNO0FBQUEsVUE4Qk5DLG9CQTlCTSxHQW9GSjVCLGFBcEZJLENBOEJONEIsb0JBOUJNO0FBQUEsVUErQk5DLE1BL0JNLEdBb0ZKN0IsYUFwRkksQ0ErQk42QixNQS9CTTtBQUFBLFVBZ0NOQyxXQWhDTSxHQW9GSjlCLGFBcEZJLENBZ0NOOEIsV0FoQ007QUFBQSxVQWlDTkMsVUFqQ00sR0FvRkovQixhQXBGSSxDQWlDTitCLFVBakNNO0FBQUEsVUFrQ05DLFFBbENNLEdBb0ZKaEMsYUFwRkksQ0FrQ05nQyxRQWxDTTtBQUFBLFVBbUNOQyxTQW5DTSxHQW9GSmpDLGFBcEZJLENBbUNOaUMsU0FuQ007QUFBQSxVQW9DTkMsVUFwQ00sR0FvRkpsQyxhQXBGSSxDQW9DTmtDLFVBcENNO0FBQUEsVUFzQ05DLFVBdENNLEdBb0ZKbkMsYUFwRkksQ0FzQ05tQyxVQXRDTTtBQUFBLFVBdUNOQyxXQXZDTSxHQW9GSnBDLGFBcEZJLENBdUNOb0MsV0F2Q007QUFBQSxVQXdDTkMsT0F4Q00sR0FvRkpyQyxhQXBGSSxDQXdDTnFDLE9BeENNO0FBQUEsVUF5Q05DLFVBekNNLEdBb0ZKdEMsYUFwRkksQ0F5Q05zQyxVQXpDTTtBQUFBLFVBMENOQyxhQTFDTSxHQW9GSnZDLGFBcEZJLENBMENOdUMsYUExQ007QUFBQSxVQTJDTkMsV0EzQ00sR0FvRkp4QyxhQXBGSSxDQTJDTndDLFdBM0NNO0FBQUEsVUE0Q05DLFFBNUNNLEdBb0ZKekMsYUFwRkksQ0E0Q055QyxRQTVDTTtBQUFBLFVBNkNOQyxpQkE3Q00sR0FvRkoxQyxhQXBGSSxDQTZDTjBDLGlCQTdDTTtBQUFBLFVBK0NOQyxPQS9DTSxHQW9GSjNDLGFBcEZJLENBK0NOMkMsT0EvQ007QUFBQSxVQWdETnZELFFBaERNLEdBb0ZKWSxhQXBGSSxDQWdETlosUUFoRE07QUFBQSxVQWlETkQsSUFqRE0sR0FvRkphLGFBcEZJLENBaUROYixJQWpETTtBQUFBLFVBa0RORyxNQWxETSxHQW9GSlUsYUFwRkksQ0FrRE5WLE1BbERNO0FBQUEsVUFtRE5JLFFBbkRNLEdBb0ZKTSxhQXBGSSxDQW1ETk4sUUFuRE07QUFBQSxVQW9ETkUsT0FwRE0sR0FvRkpJLGFBcEZJLENBb0ROSixPQXBETTtBQUFBLFVBcUROSixRQXJETSxHQW9GSlEsYUFwRkksQ0FxRE5SLFFBckRNO0FBQUEsVUFzRE5vRCxLQXRETSxHQW9GSjVDLGFBcEZJLENBc0RONEMsS0F0RE07QUFBQSxVQXVETkMsZ0JBdkRNLEdBb0ZKN0MsYUFwRkksQ0F1RE42QyxnQkF2RE07QUFBQSxVQXlETkMsY0F6RE0sR0FvRko5QyxhQXBGSSxDQXlETjhDLGNBekRNO0FBQUEsVUEwRE5DLGNBMURNLEdBb0ZKL0MsYUFwRkksQ0EwRE4rQyxjQTFETTtBQUFBLFVBMkROQyxjQTNETSxHQW9GSmhELGFBcEZJLENBMkROZ0QsY0EzRE07QUFBQSxVQTRETkMsZ0JBNURNLEdBb0ZKakQsYUFwRkksQ0E0RE5pRCxnQkE1RE07QUFBQSxVQTZETkMsV0E3RE0sR0FvRkpsRCxhQXBGSSxDQTZETmtELFdBN0RNO0FBQUEsVUE4RE5DLFdBOURNLEdBb0ZKbkQsYUFwRkksQ0E4RE5tRCxXQTlETTtBQUFBLFVBK0ROQyxXQS9ETSxHQW9GSnBELGFBcEZJLENBK0ROb0QsV0EvRE07QUFBQSxVQWdFTkMsY0FoRU0sR0FvRkpyRCxhQXBGSSxDQWdFTnFELGNBaEVNO0FBQUEsVUFpRU5DLG1CQWpFTSxHQW9GSnRELGFBcEZJLENBaUVOc0QsbUJBakVNO0FBQUEsVUFrRU5DLGdCQWxFTSxHQW9GSnZELGFBcEZJLENBa0VOdUQsZ0JBbEVNO0FBQUEsVUFtRU5DLFlBbkVNLEdBb0ZKeEQsYUFwRkksQ0FtRU53RCxZQW5FTTtBQUFBLFVBb0VOQyxlQXBFTSxHQW9GSnpELGFBcEZJLENBb0VOeUQsZUFwRU07QUFBQSxVQXFFTkMsZ0JBckVNLEdBb0ZKMUQsYUFwRkksQ0FxRU4wRCxnQkFyRU07QUFBQSxVQXNFTkMsaUJBdEVNLEdBb0ZKM0QsYUFwRkksQ0FzRU4yRCxpQkF0RU07QUFBQSxVQXVFTkMsbUJBdkVNLEdBb0ZKNUQsYUFwRkksQ0F1RU40RCxtQkF2RU07QUFBQSxVQXdFTkMsY0F4RU0sR0FvRko3RCxhQXBGSSxDQXdFTjZELGNBeEVNO0FBQUEsVUF5RU5DLG1CQXpFTSxHQW9GSjlELGFBcEZJLENBeUVOOEQsbUJBekVNO0FBQUEsVUEwRU5DLGVBMUVNLEdBb0ZKL0QsYUFwRkksQ0EwRU4rRCxlQTFFTTtBQUFBLFVBMkVOQyxlQTNFTSxHQW9GSmhFLGFBcEZJLENBMkVOZ0UsZUEzRU07QUFBQSxVQTZFTkMsWUE3RU0sR0FvRkpqRSxhQXBGSSxDQTZFTmlFLFlBN0VNO0FBQUEsVUE4RU5DLGlCQTlFTSxHQW9GSmxFLGFBcEZJLENBOEVOa0UsaUJBOUVNO0FBQUEsVUErRU5DLFlBL0VNLEdBb0ZKbkUsYUFwRkksQ0ErRU5tRSxZQS9FTTtBQUFBLFVBZ0ZOQyxlQWhGTSxHQW9GSnBFLGFBcEZJLENBZ0ZOb0UsZUFoRk07QUFBQSxVQWtGTkMsVUFsRk0sR0FvRkpyRSxhQXBGSSxDQWtGTnFFLFVBbEZNO0FBQUEsVUFtRk52RSxpQkFuRk0sR0FvRkpFLGFBcEZJLENBbUZORixpQkFuRk07O0FBc0ZSOztBQUNBLFVBQU13RSxXQUFXbEYsV0FBV0QsSUFBNUI7QUFDQSxVQUFNb0YsU0FBU0QsV0FBV2xGLFFBQTFCO0FBQ0EsVUFBSW9GLFdBQVczQyxTQUFTb0MsWUFBVCxHQUF3QkksV0FBV0ksS0FBWCxDQUFpQkgsUUFBakIsRUFBMkJDLE1BQTNCLENBQXZDO0FBQ0EsVUFBTUcsVUFBVSxLQUFLaEcsVUFBTCxFQUFoQjtBQUNBLFVBQU1pRyxVQUFVLGdCQUFFQyxLQUFGLENBQVFDLEtBQUtDLEdBQUwsQ0FBU0osVUFBVUYsU0FBU08sTUFBNUIsRUFBb0MsQ0FBcEMsQ0FBUixDQUFoQjs7QUFFQSxVQUFNQyxrQkFBa0JkLGtCQUFrQmUsSUFBbEIsQ0FBdUI7QUFBQSxlQUFLQyxFQUFFQyxNQUFQO0FBQUEsT0FBdkIsQ0FBeEI7QUFDQSxVQUFNQyxhQUFhbEQsY0FBY2dDLGtCQUFrQmUsSUFBbEIsQ0FBdUI7QUFBQSxlQUFLQyxFQUFFaEQsVUFBUDtBQUFBLE9BQXZCLENBQWpDOztBQUVBLFVBQU1tRCx1QkFBdUIsU0FBdkJBLG9CQUF1QixDQUFDQyxJQUFELEVBQWlDO0FBQUEsWUFBMUJDLElBQTBCLHVFQUFuQixFQUFtQjtBQUFBLFlBQWZDLEtBQWUsdUVBQVAsQ0FBQyxDQUFNOztBQUM1RCxlQUFPLENBQ0xGLEtBQUtHLEdBQUwsQ0FBUyxVQUFDQyxHQUFELEVBQU1DLENBQU4sRUFBWTtBQUNuQkg7QUFDQSxjQUFNSSxnQ0FDREYsR0FEQztBQUVKRyx3QkFBWUw7QUFGUixZQUFOO0FBSUEsY0FBTU0sVUFBVVAsS0FBS1EsTUFBTCxDQUFZLENBQUNKLENBQUQsQ0FBWixDQUFoQjtBQUNBLGNBQUlDLGlCQUFpQnRELFVBQWpCLEtBQWdDLGdCQUFFMEQsR0FBRixDQUFNeEcsUUFBTixFQUFnQnNHLE9BQWhCLENBQXBDLEVBQThEO0FBQzVEO0FBRDRELHdDQUNuQlQscUJBQ3ZDTyxpQkFBaUJ0RCxVQUFqQixDQUR1QyxFQUV2Q3dELE9BRnVDLEVBR3ZDTixLQUh1QyxDQURtQjs7QUFBQTs7QUFDMURJLDZCQUFpQnRELFVBQWpCLENBRDBEO0FBQzVCa0QsaUJBRDRCO0FBTTdEO0FBQ0QsaUJBQU9JLGdCQUFQO0FBQ0QsU0FmRCxDQURLLEVBaUJMSixLQWpCSyxDQUFQO0FBbUJELE9BcEJEO0FBaEdRLG1DQXFITUgscUJBQXFCYixRQUFyQixDQXJITjs7QUFBQTs7QUFxSE5BLGNBckhNOzs7QUF1SFIsVUFBTXlCLGNBQWM5RyxPQUFPLENBQTNCO0FBQ0EsVUFBTStHLFVBQVUvRyxPQUFPLENBQVAsR0FBV3lELEtBQTNCOztBQUVBLFVBQU11RCxjQUFjLGdCQUFFQyxHQUFGLENBQ2xCbEMsa0JBQWtCdUIsR0FBbEIsQ0FBc0IsYUFBSztBQUN6QixZQUFNWSxnQkFBZ0J6RyxRQUFRMEcsSUFBUixDQUFhO0FBQUEsaUJBQUtDLEVBQUVDLEVBQUYsS0FBU3RCLEVBQUVzQixFQUFoQjtBQUFBLFNBQWIsS0FBb0MsRUFBMUQ7QUFDQSxlQUFPLGdCQUFFQyxlQUFGLENBQWtCSixjQUFjSyxLQUFoQyxFQUF1Q3hCLEVBQUV5QixLQUF6QyxFQUFnRHpCLEVBQUUwQixRQUFsRCxDQUFQO0FBQ0QsT0FIRCxDQURrQixDQUFwQjs7QUFPQSxVQUFJQyxXQUFXLENBQUMsQ0FBaEI7O0FBRUEsVUFBTUMsMEJBQ0Q5RyxhQURDO0FBRUpzRSwwQkFGSTtBQUdKQyxzQkFISTtBQUlKQywwQkFKSTtBQUtKRSx3QkFMSTtBQU1KQyx3QkFOSTtBQU9KSyx3Q0FQSTtBQVFKaUIsZ0NBUkk7QUFTSkMsd0JBVEk7QUFVSkM7QUFWSSxRQUFOOztBQWFBOztBQUVBLFVBQU1ZLG1CQUFtQixTQUFuQkEsZ0JBQW1CLEdBQU07QUFDN0IsWUFBTUMsa0JBQWtCLGdCQUFFQyxVQUFGLENBQ3RCM0csbUJBQW1Cd0csVUFBbkIsRUFBK0JJLFNBQS9CLEVBQTBDQSxTQUExQyxTQURzQixDQUF4QjtBQUdBLFlBQU1DLG9CQUFvQixnQkFBRUYsVUFBRixDQUN4QjFHLHFCQUFxQnVHLFVBQXJCLEVBQWlDSSxTQUFqQyxFQUE0Q0EsU0FBNUMsU0FEd0IsQ0FBMUI7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXLDBCQUFXLGVBQVgsRUFBNEJGLGdCQUFnQjlHLFNBQTVDLENBRGI7QUFFRSxnQ0FDSzhHLGdCQUFnQjdHLEtBRHJCO0FBRUV5Ryx3QkFBYVQsV0FBYjtBQUZGO0FBRkYsYUFNTWEsZ0JBQWdCSSxJQU50QjtBQVFFO0FBQUMsdUJBQUQ7QUFBQTtBQUNFLHlCQUFXRCxrQkFBa0JqSCxTQUQvQjtBQUVFLHFCQUFPaUgsa0JBQWtCaEg7QUFGM0IsZUFHTWdILGtCQUFrQkMsSUFIeEI7QUFLR2pELHlCQUFhc0IsR0FBYixDQUFpQjRCLGVBQWpCO0FBTEg7QUFSRixTQURGO0FBa0JELE9BekJEOztBQTJCQSxVQUFNQSxrQkFBa0IsU0FBbEJBLGVBQWtCLENBQUNDLE1BQUQsRUFBUzNCLENBQVQsRUFBZTtBQUNyQyxZQUFNNEIsZUFBZSxTQUFmQSxZQUFlO0FBQUEsaUJBQ25CLENBQUMzSCxRQUFRMEcsSUFBUixDQUFhO0FBQUEsbUJBQUtDLEVBQUVDLEVBQUYsS0FBU2dCLElBQUloQixFQUFsQjtBQUFBLFdBQWIsS0FBc0MsRUFBdkMsRUFBMkNFLEtBRHhCO0FBQUEsU0FBckI7QUFFQSxZQUFNZSxPQUFPLGdCQUFFckIsR0FBRixDQUNYa0IsT0FBT0ksT0FBUCxDQUFlakMsR0FBZixDQUNFO0FBQUEsaUJBQVErQixJQUFJYixLQUFKLElBQWFZLGFBQWFDLEdBQWIsQ0FBYixHQUFpQyxDQUFqQyxHQUFxQ0EsSUFBSVosUUFBakQ7QUFBQSxTQURGLENBRFcsQ0FBYjtBQUtBLFlBQU1ELFFBQVEsZ0JBQUVQLEdBQUYsQ0FDWmtCLE9BQU9JLE9BQVAsQ0FBZWpDLEdBQWYsQ0FBbUI7QUFBQSxpQkFDakIsZ0JBQUVnQixlQUFGLENBQWtCYyxhQUFhQyxHQUFiLENBQWxCLEVBQXFDQSxJQUFJYixLQUF6QyxFQUFnRGEsSUFBSVosUUFBcEQsQ0FEaUI7QUFBQSxTQUFuQixDQURZLENBQWQ7QUFLQSxZQUFNZSxXQUFXLGdCQUFFdkIsR0FBRixDQUNma0IsT0FBT0ksT0FBUCxDQUFlakMsR0FBZixDQUFtQjtBQUFBLGlCQUNqQixnQkFBRWdCLGVBQUYsQ0FBa0JjLGFBQWFDLEdBQWIsQ0FBbEIsRUFBcUNBLElBQUliLEtBQXpDLEVBQWdEYSxJQUFJRyxRQUFwRCxDQURpQjtBQUFBLFNBQW5CLENBRGUsQ0FBakI7O0FBTUEsWUFBTUMsb0JBQW9CLGdCQUFFWCxVQUFGLENBQ3hCekcscUJBQXFCc0csVUFBckIsRUFBaUNJLFNBQWpDLEVBQTRDSSxNQUE1QyxTQUR3QixDQUExQjtBQUdBLFlBQU1PLG9CQUFvQixnQkFBRVosVUFBRixDQUN4QkssT0FBT1EsY0FBUCxDQUFzQmhCLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0ksTUFBN0MsU0FEd0IsQ0FBMUI7O0FBSUEsWUFBTVMsVUFBVSxDQUNkVCxPQUFPVSxlQURPLEVBRWRKLGtCQUFrQjFILFNBRkosRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRUROLGtCQUFrQnpILEtBRmpCLEVBR0QwSCxrQkFBa0IxSCxLQUhqQixDQUFOOztBQU1BLFlBQU1pSCxvQkFDRFEsa0JBQWtCUixJQURqQixFQUVEUyxrQkFBa0JULElBRmpCLENBQU47O0FBS0EsWUFBTWUsYUFBYTtBQUNqQlYsZ0JBQVNBLElBQVQsWUFEaUI7QUFFakJkLGlCQUFPLGdCQUFFeUIsSUFBRixDQUFPekIsS0FBUCxDQUZVO0FBR2pCZ0Isb0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUhPLFNBQW5COztBQU1BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUtoQyxJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLENBRmI7QUFHRSxnQ0FDS0UsTUFETCxFQUVLRSxVQUZMO0FBSEYsYUFPTWYsSUFQTjtBQVNHLDBCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9nQixNQUE1QixFQUFvQztBQUNuQ0Msa0JBQU1sRSxVQUQ2QjtBQUVuQ2lELG9CQUFRQTtBQUYyQixXQUFwQztBQVRILFNBREY7QUFnQkQsT0FqRUQ7O0FBbUVBLFVBQU1rQixjQUFjLFNBQWRBLFdBQWMsR0FBTTtBQUN4QixZQUFNQyxhQUFhLGdCQUFFeEIsVUFBRixDQUNqQnhHLGNBQWNxRyxVQUFkLEVBQTBCSSxTQUExQixFQUFxQ0EsU0FBckMsU0FEaUIsQ0FBbkI7QUFHQSxZQUFNd0IsZUFBZSxnQkFBRXpCLFVBQUYsQ0FDbkJ2RyxnQkFBZ0JvRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNBLFNBQXZDLFNBRG1CLENBQXJCO0FBR0EsZUFDRTtBQUFDLHdCQUFEO0FBQUE7QUFDRSx1QkFBVywwQkFBVyxTQUFYLEVBQXNCdUIsV0FBV3ZJLFNBQWpDLENBRGI7QUFFRSxnQ0FDS3VJLFdBQVd0SSxLQURoQjtBQUVFeUcsd0JBQWFULFdBQWI7QUFGRjtBQUZGLGFBTU1zQyxXQUFXckIsSUFOakI7QUFRRTtBQUFDLHVCQUFEO0FBQUE7QUFDRSx5QkFBV3NCLGFBQWF4SSxTQUQxQjtBQUVFLHFCQUFPd0ksYUFBYXZJO0FBRnRCLGVBR011SSxhQUFhdEIsSUFIbkI7QUFLR2xELDhCQUFrQnVCLEdBQWxCLENBQXNCa0QsVUFBdEI7QUFMSDtBQVJGLFNBREY7QUFrQkQsT0F6QkQ7O0FBMkJBLFVBQU1BLGFBQWEsU0FBYkEsVUFBYSxDQUFDckIsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ2hDLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1xQyxPQUFPdkosT0FBT2dILElBQVAsQ0FBWTtBQUFBLGlCQUFLcEIsRUFBRXNCLEVBQUYsS0FBU2MsT0FBT2QsRUFBckI7QUFBQSxTQUFaLENBQWI7QUFDQSxZQUFNc0MsT0FDSixPQUFPeEIsT0FBT3dCLElBQWQsS0FBdUIsVUFBdkIsR0FBb0N4QixPQUFPd0IsSUFBUCxFQUFwQyxHQUFvRHhCLE9BQU93QixJQUQ3RDtBQUVBLFlBQU1uQyxRQUFRLGdCQUFFRixlQUFGLENBQ1ptQyxXQUFXbEMsS0FEQyxFQUVaWSxPQUFPWCxLQUZLLEVBR1pXLE9BQU9WLFFBSEssQ0FBZDtBQUtBLFlBQU1lLFdBQVcsZ0JBQUVsQixlQUFGLENBQ2ZtQyxXQUFXbEMsS0FESSxFQUVmWSxPQUFPWCxLQUZRLEVBR2ZXLE9BQU9LLFFBSFEsQ0FBakI7QUFLQSxZQUFNb0IsZUFBZSxnQkFBRTlCLFVBQUYsQ0FDbkJ0RyxnQkFBZ0JtRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNJLE1BQXZDLFNBRG1CLENBQXJCO0FBR0EsWUFBTU8sb0JBQW9CLGdCQUFFWixVQUFGLENBQ3hCSyxPQUFPUSxjQUFQLENBQXNCaEIsVUFBdEIsRUFBa0NJLFNBQWxDLEVBQTZDSSxNQUE3QyxTQUR3QixDQUExQjs7QUFJQSxZQUFNUyxVQUFVLENBQ2RULE9BQU9VLGVBRE8sRUFFZGUsYUFBYTdJLFNBRkMsRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRURhLGFBQWE1SSxLQUZaLEVBR0QwSCxrQkFBa0IxSCxLQUhqQixDQUFOOztBQU1BLFlBQU1pSCxvQkFDRDJCLGFBQWEzQixJQURaLEVBRURTLGtCQUFrQlQsSUFGakIsQ0FBTjs7QUFLQSxZQUFNNEIsY0FBYyxnQkFBRXZDLGVBQUYsQ0FBa0JhLE9BQU9yRixTQUF6QixFQUFvQ0EsU0FBcEMsRUFBK0MsS0FBL0MsQ0FBcEI7QUFDQSxZQUFNZ0gsVUFBVUQsY0FDWCw4QkFBQyxnQkFBRDtBQUNELHVCQUFhO0FBQUEsbUJBQUssT0FBS2pLLGlCQUFMLENBQXVCbUssQ0FBdkIsRUFBMEI1QixNQUExQixFQUFrQyxLQUFsQyxDQUFMO0FBQUEsV0FEWjtBQUVELHdCQUFjO0FBQUEsbUJBQUssT0FBS3ZJLGlCQUFMLENBQXVCbUssQ0FBdkIsRUFBMEI1QixNQUExQixFQUFrQyxJQUFsQyxDQUFMO0FBQUE7QUFGYixXQUdHNkIsWUFISCxFQURXLEdBTVosSUFOSjs7QUFRQSxZQUFNQyxhQUFhLGdCQUFFM0MsZUFBRixDQUFrQmEsT0FBT3RGLFFBQXpCLEVBQW1DQSxRQUFuQyxFQUE2QyxLQUE3QyxDQUFuQjs7QUFFQSxlQUNFO0FBQUMscUJBQUQ7QUFBQTtBQUNFLGlCQUFLMkQsSUFBSSxHQUFKLEdBQVUyQixPQUFPZCxFQUR4QjtBQUVFLHVCQUFXLDBCQUNUdUIsT0FEUyxFQUVULHFCQUZTLEVBR1RjLE9BQVFBLEtBQUtRLElBQUwsR0FBWSxZQUFaLEdBQTJCLFdBQW5DLEdBQWtELEVBSHpDLEVBSVRELGNBQWMsaUJBSkwsRUFLVCxDQUFDTixJQUFELElBQVMsU0FMQSxFQU1UekcsV0FDRUEsUUFBUW9DLEtBQVIsQ0FBYyxDQUFkLEVBQWlCLENBQUMsQ0FBbEIsRUFBcUI2RSxRQUFyQixDQUE4QmhDLE9BQU9kLEVBQXJDLENBREYsSUFFRSxpQkFSTyxDQUZiO0FBWUUsZ0NBQ0t5QixNQURMO0FBRUVSLG9CQUFTZCxLQUFULFlBRkY7QUFHRUEscUJBQU8sZ0JBQUV5QixJQUFGLENBQU96QixLQUFQLENBSFQ7QUFJRWdCLHdCQUFVLGdCQUFFUyxJQUFGLENBQU9ULFFBQVA7QUFKWixjQVpGO0FBa0JFLHdCQUFZLHVCQUFLO0FBQ2Z5Qiw0QkFBYyxPQUFLdkssVUFBTCxDQUFnQnlJLE1BQWhCLEVBQXdCNEIsRUFBRUssUUFBMUIsQ0FBZDtBQUNEO0FBcEJILGFBcUJNbkMsSUFyQk47QUF1QkU7QUFBQTtBQUFBLGNBQUssV0FBVSw2QkFBZjtBQUNHLDRCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9nQixNQUE1QixFQUFvQztBQUNuQ0Msb0JBQU1sRSxVQUQ2QjtBQUVuQ2lELHNCQUFRQTtBQUYyQixhQUFwQztBQURILFdBdkJGO0FBNkJHMkI7QUE3QkgsU0FERjtBQWlDRCxPQW5GRDs7QUFxRkEsVUFBTU8sY0FBYyxTQUFkQSxXQUFjLEdBQU07QUFDeEIsWUFBTUMsbUJBQW1CLGdCQUFFeEMsVUFBRixDQUN2QnJHLG9CQUFvQmtHLFVBQXBCLEVBQWdDSSxTQUFoQyxFQUEyQ0EsU0FBM0MsU0FEdUIsQ0FBekI7QUFHQSxZQUFNd0MscUJBQXFCLGdCQUFFekMsVUFBRixDQUN6QnBHLHNCQUFzQmlHLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0EsU0FBN0MsU0FEeUIsQ0FBM0I7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXLDBCQUFXLFVBQVgsRUFBdUJ1QyxpQkFBaUJ2SixTQUF4QyxDQURiO0FBRUUsZ0NBQ0t1SixpQkFBaUJ0SixLQUR0QjtBQUVFeUcsd0JBQWFULFdBQWI7QUFGRjtBQUZGLGFBTU1zRCxpQkFBaUJyQyxJQU52QjtBQVFFO0FBQUMsdUJBQUQ7QUFBQTtBQUNFLHlCQUFXc0MsbUJBQW1CeEosU0FEaEM7QUFFRSxxQkFBT3dKLG1CQUFtQnZKO0FBRjVCLGVBR011SixtQkFBbUJ0QyxJQUh6QjtBQUtHbEQsOEJBQWtCdUIsR0FBbEIsQ0FBc0JrRSxVQUF0QjtBQUxIO0FBUkYsU0FERjtBQWtCRCxPQXpCRDs7QUEyQkEsVUFBTUEsYUFBYSxTQUFiQSxVQUFhLENBQUNyQyxNQUFELEVBQVMzQixDQUFULEVBQWU7QUFDaEMsWUFBTWlELGFBQWFoSixRQUFRMEcsSUFBUixDQUFhO0FBQUEsaUJBQUtDLEVBQUVDLEVBQUYsS0FBU2MsT0FBT2QsRUFBckI7QUFBQSxTQUFiLEtBQXlDLEVBQTVEO0FBQ0EsWUFBTUcsUUFBUSxnQkFBRUYsZUFBRixDQUNabUMsV0FBV2xDLEtBREMsRUFFWlksT0FBT1gsS0FGSyxFQUdaVyxPQUFPVixRQUhLLENBQWQ7QUFLQSxZQUFNZSxXQUFXLGdCQUFFbEIsZUFBRixDQUNmbUMsV0FBV2xDLEtBREksRUFFZlksT0FBT1gsS0FGUSxFQUdmVyxPQUFPSyxRQUhRLENBQWpCO0FBS0EsWUFBTWlDLHFCQUFxQixnQkFBRTNDLFVBQUYsQ0FDekJuRyxzQkFBc0JnRyxVQUF0QixFQUFrQ0ksU0FBbEMsRUFBNkNJLE1BQTdDLFNBRHlCLENBQTNCO0FBR0EsWUFBTU8sb0JBQW9CLGdCQUFFWixVQUFGLENBQ3hCSyxPQUFPUSxjQUFQLENBQXNCaEIsVUFBdEIsRUFBa0NJLFNBQWxDLEVBQTZDSSxNQUE3QyxTQUR3QixDQUExQjs7QUFJQSxZQUFNUyxVQUFVLENBQ2RULE9BQU9VLGVBRE8sRUFFZDRCLG1CQUFtQjFKLFNBRkwsRUFHZDJILGtCQUFrQjNILFNBSEosQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEWCxPQUFPWSxXQUROLEVBRUQwQixtQkFBbUJ6SixLQUZsQixFQUdEMEgsa0JBQWtCMUgsS0FIakIsQ0FBTjs7QUFNQSxZQUFNaUgsb0JBQ0R3QyxtQkFBbUJ4QyxJQURsQixFQUVEUyxrQkFBa0JULElBRmpCLENBQU47O0FBS0EsWUFBTXlDLFNBQVNuSyxTQUFTNEcsSUFBVCxDQUFjO0FBQUEsaUJBQVV1RCxPQUFPckQsRUFBUCxLQUFjYyxPQUFPZCxFQUEvQjtBQUFBLFNBQWQsQ0FBZjs7QUFFQSxZQUFNc0QsMEJBQTBCeEMsT0FBT3lDLE1BQVAsSUFBaUJoRyxlQUFqRDs7QUFFQSxZQUFNaUcsZUFBZSxnQkFBRXZELGVBQUYsQ0FDbkJhLE9BQU9wRixVQURZLEVBRW5CQSxVQUZtQixFQUduQixLQUhtQixDQUFyQjs7QUFNQSxlQUNFO0FBQUMscUJBQUQ7QUFBQTtBQUNFLGlCQUFLeUQsSUFBSSxHQUFKLEdBQVUyQixPQUFPZCxFQUR4QjtBQUVFLHVCQUFXLDBCQUFXdUIsT0FBWCxDQUZiO0FBR0UsZ0NBQ0tFLE1BREw7QUFFRVIsb0JBQVNkLEtBQVQsWUFGRjtBQUdFQSxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTVAsSUFUTjtBQVdHNEMseUJBQ0csZ0JBQUUzQixrQkFBRixDQUNBeUIsdUJBREEsRUFFQTtBQUNFeEMsMEJBREY7QUFFRXVDLDBCQUZGO0FBR0VJLHNCQUFVO0FBQUEscUJBQVMsT0FBS25MLFlBQUwsQ0FBa0J3SSxNQUFsQixFQUEwQlosS0FBMUIsQ0FBVDtBQUFBO0FBSFosV0FGQSxFQU9BLHVCQUFhWSxNQUFiLENBQW9CeUMsTUFQcEIsQ0FESCxHQVVHO0FBckJOLFNBREY7QUF5QkQsT0F2RUQ7O0FBeUVBLFVBQU1HLGNBQWMsU0FBZEEsV0FBYyxDQUFDeEUsR0FBRCxFQUFNQyxDQUFOLEVBQXVCO0FBQUEsWUFBZEosSUFBYyx1RUFBUCxFQUFPOztBQUN6QyxZQUFNNEUsVUFBVTtBQUNkQyxvQkFBVTFFLElBQUlsRCxXQUFKLENBREk7QUFFZGtELGVBQUtBLEdBRlM7QUFHZEYsaUJBQU9FLElBQUlqRCxRQUFKLENBSE87QUFJZDRILHFCQUFXLEVBQUV4RCxRQUpDO0FBS2R5RCxpQkFBTy9FLEtBQUtSLE1BTEU7QUFNZHdGLHVCQUFhaEYsS0FBS1EsTUFBTCxDQUFZLENBQUNKLENBQUQsQ0FBWixDQU5DO0FBT2Q2RSxzQkFBWTlFLElBQUluRCxhQUFKLENBUEU7QUFRZGtJLDBCQUFnQi9FLElBQUloRCxpQkFBSixDQVJGO0FBU2RnSSxtQkFBU2hGLElBQUlwRCxVQUFKO0FBVEssU0FBaEI7QUFXQSxZQUFNcUksYUFBYSxnQkFBRTNFLEdBQUYsQ0FBTXhHLFFBQU4sRUFBZ0IySyxRQUFRSSxXQUF4QixDQUFuQjtBQUNBLFlBQU1LLGVBQWU1SixnQkFBZ0I4RixVQUFoQixFQUE0QnFELE9BQTVCLEVBQXFDakQsU0FBckMsU0FBckI7QUFDQSxZQUFNMkQsVUFBVSxnQkFBRTVELFVBQUYsQ0FDZGhHLFdBQVc2RixVQUFYLEVBQXVCcUQsT0FBdkIsRUFBZ0NqRCxTQUFoQyxTQURjLENBQWhCO0FBR0EsZUFDRTtBQUFDLDBCQUFEO0FBQUEscUJBQWtCLEtBQUtpRCxRQUFRSSxXQUFSLENBQW9CTyxJQUFwQixDQUF5QixHQUF6QixDQUF2QixJQUEwREYsWUFBMUQ7QUFDRTtBQUFDLHVCQUFEO0FBQUE7QUFDRSx5QkFBVywwQkFDVEMsUUFBUTNLLFNBREMsRUFFVHdGLElBQUlHLFVBQUosR0FBaUIsQ0FBakIsR0FBcUIsT0FBckIsR0FBK0IsTUFGdEIsQ0FEYjtBQUtFLHFCQUFPZ0YsUUFBUTFLO0FBTGpCLGVBTU0wSyxRQUFRekQsSUFOZDtBQVFHbEQsOEJBQWtCdUIsR0FBbEIsQ0FBc0IsVUFBQzZCLE1BQUQsRUFBU3lELEVBQVQsRUFBZ0I7QUFDckMsa0JBQU1uQyxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLHVCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsZUFBYixLQUF5QyxFQUE1RDtBQUNBLGtCQUFNc0MsT0FDSixPQUFPeEIsT0FBT3dCLElBQWQsS0FBdUIsVUFBdkIsR0FBb0N4QixPQUFPd0IsSUFBUCxFQUFwQyxHQUFvRHhCLE9BQU93QixJQUQ3RDtBQUVBLGtCQUFNbkMsUUFBUSxnQkFBRUYsZUFBRixDQUNabUMsV0FBV2xDLEtBREMsRUFFWlksT0FBT1gsS0FGSyxFQUdaVyxPQUFPVixRQUhLLENBQWQ7QUFLQSxrQkFBTWUsV0FBVyxnQkFBRWxCLGVBQUYsQ0FDZm1DLFdBQVdsQyxLQURJLEVBRWZZLE9BQU9YLEtBRlEsRUFHZlcsT0FBT0ssUUFIUSxDQUFqQjtBQUtBLGtCQUFNcUQsVUFBVSxnQkFBRS9ELFVBQUYsQ0FDZC9GLFdBQVc0RixVQUFYLEVBQXVCcUQsT0FBdkIsRUFBZ0M3QyxNQUFoQyxTQURjLENBQWhCO0FBR0Esa0JBQU0yRCxjQUFjLGdCQUFFaEUsVUFBRixDQUNsQkssT0FBT2xILFFBQVAsQ0FBZ0IwRyxVQUFoQixFQUE0QnFELE9BQTVCLEVBQXFDN0MsTUFBckMsU0FEa0IsQ0FBcEI7O0FBSUEsa0JBQU1TLFVBQVUsQ0FDZGlELFFBQVE5SyxTQURNLEVBRWRvSCxPQUFPcEgsU0FGTyxFQUdkK0ssWUFBWS9LLFNBSEUsQ0FBaEI7O0FBTUEsa0JBQU0rSCxzQkFDRCtDLFFBQVE3SyxLQURQLEVBRURtSCxPQUFPbkgsS0FGTixFQUdEOEssWUFBWTlLLEtBSFgsQ0FBTjs7QUFNQSxrQkFBTStLLHdCQUNEZixPQURDO0FBRUpRLHNDQUZJO0FBR0pyRCxxQ0FBYUEsTUFBYixDQUhJO0FBSUpaLHVCQUFPeUQsUUFBUXpFLEdBQVIsQ0FBWTRCLE9BQU9kLEVBQW5CLENBSkg7QUFLSjJFLHlCQUFTN0QsT0FBTzZELE9BTFo7QUFNSkMsMEJBQVU5RCxPQUFPOEQsUUFOYjtBQU9KeEwsZ0NBUEk7QUFRSmtKLDBCQVJJO0FBU0puQyw0QkFUSTtBQVVKZ0Isa0NBVkk7QUFXSnFELGdDQVhJO0FBWUpDLHdDQVpJO0FBYUpsRCxnQ0FiSTtBQWNKRTtBQWRJLGdCQUFOOztBQWlCQSxrQkFBTXZCLFFBQVF3RSxTQUFTeEUsS0FBdkI7O0FBRUEsa0JBQUkyRSwyQkFBSjtBQUNBLGtCQUFJQyxpQkFBSjtBQUNBLGtCQUFJQyxrQkFBSjs7QUFFQSxrQkFBTUMsa0JBQWtCLFNBQWxCQSxlQUFrQixJQUFLO0FBQzNCLG9CQUFJQyxjQUFjLGdCQUFFQyxLQUFGLENBQVFsTSxRQUFSLENBQWxCO0FBQ0Esb0JBQUltTCxVQUFKLEVBQWdCO0FBQ2RjLGdDQUFjLGdCQUFFRSxHQUFGLENBQU1GLFdBQU4sRUFBbUJQLFNBQVNYLFdBQTVCLEVBQXlDLEtBQXpDLENBQWQ7QUFDRCxpQkFGRCxNQUVPO0FBQ0xrQixnQ0FBYyxnQkFBRUUsR0FBRixDQUFNRixXQUFOLEVBQW1CUCxTQUFTWCxXQUE1QixFQUF5QyxFQUF6QyxDQUFkO0FBQ0Q7O0FBRUQsdUJBQU8sT0FBS3FCLGdCQUFMLENBQ0w7QUFDRXBNLDRCQUFVaU07QUFEWixpQkFESyxFQUlMLFlBQU07QUFDSjVJLHNDQUNFQSxpQkFBaUI0SSxXQUFqQixFQUE4QlAsU0FBU1gsV0FBdkMsRUFBb0RyQixDQUFwRCxDQURGO0FBRUQsaUJBUEksQ0FBUDtBQVNELGVBakJEOztBQW1CQTtBQUNBLGtCQUFJMkMsZUFBZSxnQkFBRXhELGtCQUFGLENBQ2pCZixPQUFPd0UsSUFEVSxFQUVqQlosUUFGaUIsRUFHakJ4RSxLQUhpQixDQUFuQjs7QUFNQTtBQUNBLGtCQUFNcUYsOEJBQ0p6RSxPQUFPMEUsVUFBUCxLQUNDLENBQUMxRSxPQUFPMkUsU0FBUixHQUFvQm5JLG1CQUFwQixHQUEwQ3dELE9BQU93RSxJQURsRCxDQURGO0FBR0Esa0JBQU1JLDRCQUNKNUUsT0FBTzZFLFFBQVAsSUFBbUJ4SSxpQkFEckI7QUFFQSxrQkFBTXlJLDhCQUNKOUUsT0FBTytFLFVBQVAsSUFBcUJ6SSxtQkFEdkI7QUFFQSxrQkFBTTBJLGdDQUNKekksa0JBQ0M7QUFBQSx1QkFDQztBQUFBO0FBQUE7QUFDRSxnREFBQyx5QkFBRCxFQUErQjdGLEtBQS9CLENBREY7QUFFRSxnREFBQywyQkFBRCxFQUFpQ0EsS0FBakM7QUFGRixpQkFERDtBQUFBLGVBRkg7QUFPQSxrQkFBTXVPLHlCQUNKakYsT0FBT2tGLEtBQVAsSUFBZ0JGLDZCQURsQjs7QUFHQTtBQUNBLGtCQUFJcEIsU0FBU0MsT0FBVCxJQUFvQkQsU0FBU0UsUUFBakMsRUFBMkM7QUFDekM7QUFDQUYseUJBQVN1QixVQUFULEdBQXNCLElBQXRCO0FBQ0FwQixxQ0FBcUIsSUFBckI7QUFDQTtBQUNBLG9CQUFJSCxTQUFTQyxPQUFULElBQW9CLENBQUNELFNBQVNSLE9BQTlCLElBQXlDLENBQUNsSCxZQUE5QyxFQUE0RDtBQUMxRDBILDJCQUFTdUIsVUFBVCxHQUFzQixLQUF0QjtBQUNEO0FBQ0Y7O0FBRUQsa0JBQUl2QixTQUFTQyxPQUFiLEVBQXNCO0FBQ3BCO0FBQ0FHLDJCQUNFbkIsUUFBUXpFLEdBQVIsQ0FBWXZELFVBQVosTUFBNEJtRixPQUFPZCxFQUFuQyxJQUF5QzBFLFNBQVNSLE9BRHBEO0FBRUE7QUFDQWEsNEJBQ0VsSixRQUFRcUssT0FBUixDQUFnQnBGLE9BQU9kLEVBQXZCLElBQ0VuRSxRQUFRcUssT0FBUixDQUFnQnZDLFFBQVF6RSxHQUFSLENBQVl2RCxVQUFaLENBQWhCLENBREYsSUFDOEMrSSxTQUFTUixPQUZ6RDtBQUdBO0FBQ0Esb0JBQUlZLFFBQUosRUFBYztBQUNaO0FBQ0FPLGlDQUFlLGdCQUFFeEQsa0JBQUYsQ0FDYmtFLHNCQURhLGVBR1JyQixRQUhRO0FBSVh4RSwyQkFBT2hCLElBQUl0RCxXQUFKO0FBSkksc0JBTWJzRCxJQUFJdEQsV0FBSixDQU5hLENBQWY7QUFRRCxpQkFWRCxNQVVPLElBQUltSixTQUFKLEVBQWU7QUFDcEI7QUFDQU0saUNBQWUsZ0JBQUV4RCxrQkFBRixDQUNiMEQsMkJBRGEsRUFFYmIsUUFGYSxFQUdieEUsS0FIYSxDQUFmO0FBS0QsaUJBUE0sTUFPQTtBQUNMbUYsaUNBQWUsSUFBZjtBQUNEO0FBQ0YsZUE3QkQsTUE2Qk8sSUFBSVgsU0FBU1YsVUFBYixFQUF5QjtBQUM5QnFCLCtCQUFlLGdCQUFFeEQsa0JBQUYsQ0FDYjBELDJCQURhLEVBRWJiLFFBRmEsRUFHYnhFLEtBSGEsQ0FBZjtBQUtEOztBQUVELGtCQUFJd0UsU0FBU0UsUUFBYixFQUF1QjtBQUNyQlMsK0JBQWUsZ0JBQUV4RCxrQkFBRixDQUNiNkQseUJBRGEsRUFFYmhCLFFBRmEsRUFHYnhGLElBQUl0RCxXQUFKLENBSGEsQ0FBZjtBQUtBLG9CQUFJQyxPQUFKLEVBQWE7QUFDWCxzQkFBSTZJLFNBQVNULGNBQWIsRUFBNkI7QUFDM0JvQixtQ0FBZSxJQUFmO0FBQ0Q7QUFDRCxzQkFBSSxDQUFDWCxTQUFTUixPQUFWLElBQXFCLENBQUNsSCxZQUExQixFQUF3QztBQUN0Q3FJLG1DQUFlLElBQWY7QUFDRDtBQUNGO0FBQ0Y7O0FBRUQsa0JBQU1jLDBCQUEwQnRCLHFCQUM1QkcsZUFENEIsR0FFNUIsWUFBTSxDQUFFLENBRlo7O0FBSUE7QUFDQSxrQkFBTW9CLG1CQUFtQjtBQUN2QkMseUJBQVNGO0FBRGMsZUFBekI7O0FBSUEsa0JBQUkzQixRQUFRNUQsSUFBUixDQUFheUYsT0FBakIsRUFBMEI7QUFDeEJELGlDQUFpQkMsT0FBakIsR0FBMkIsYUFBSztBQUM5QjdCLDBCQUFRNUQsSUFBUixDQUFheUYsT0FBYixDQUFxQjNELENBQXJCLEVBQXdCO0FBQUEsMkJBQU15RCx3QkFBd0J6RCxDQUF4QixDQUFOO0FBQUEsbUJBQXhCO0FBQ0QsaUJBRkQ7QUFHRDs7QUFFRCxrQkFBSStCLFlBQVk3RCxJQUFaLENBQWlCeUYsT0FBckIsRUFBOEI7QUFDNUJELGlDQUFpQkMsT0FBakIsR0FBMkIsYUFBSztBQUM5QjVCLDhCQUFZN0QsSUFBWixDQUFpQnlGLE9BQWpCLENBQXlCM0QsQ0FBekIsRUFBNEI7QUFBQSwyQkFBTXlELHdCQUF3QnpELENBQXhCLENBQU47QUFBQSxtQkFBNUI7QUFDRCxpQkFGRDtBQUdEOztBQUVEO0FBQ0EscUJBQ0U7QUFBQywyQkFBRDtBQUFBO0FBQ0UsdUJBQUs2QixLQUFLLEdBQUwsR0FBV3pELE9BQU9kLEVBRHpCO0FBRUUsNkJBQVcsMEJBQ1R1QixPQURTLEVBRVQsQ0FBQ2UsSUFBRCxJQUFTLFFBRkEsRUFHVG9DLFNBQVN1QixVQUFULElBQXVCLGVBSGQsRUFJVCxDQUFDbkIsWUFBWUMsU0FBYixLQUEyQixVQUpsQixDQUZiO0FBUUUsc0NBQ0t0RCxNQURMO0FBRUVSLDBCQUFTZCxLQUFULFlBRkY7QUFHRUEsMkJBQU8sZ0JBQUV5QixJQUFGLENBQU96QixLQUFQLENBSFQ7QUFJRWdCLDhCQUFVLGdCQUFFUyxJQUFGLENBQU9ULFFBQVA7QUFKWjtBQVJGLG1CQWNNcUQsUUFBUTVELElBZGQsRUFlTTZELFlBQVk3RCxJQWZsQixFQWdCTXdGLGdCQWhCTjtBQWtCR2Y7QUFsQkgsZUFERjtBQXNCRCxhQWhOQTtBQVJILFdBREY7QUEyTkcxQixrQkFBUU8sT0FBUixJQUNDQyxVQURELElBRUNSLFFBQVFPLE9BQVIsQ0FBZ0JqRixHQUFoQixDQUFvQixVQUFDUCxDQUFELEVBQUlTLENBQUo7QUFBQSxtQkFDbEJ1RSxZQUFZaEYsQ0FBWixFQUFlUyxDQUFmLEVBQWtCd0UsUUFBUUksV0FBMUIsQ0FEa0I7QUFBQSxXQUFwQixDQTdOSjtBQWdPRy9HLDBCQUNDLENBQUMyRyxRQUFRTyxPQURWLElBRUNDLFVBRkQsSUFHQ25ILGFBQWEyRyxPQUFiO0FBbk9KLFNBREY7QUF1T0QsT0F4UEQ7O0FBMFBBLFVBQU0yQyxhQUFhLFNBQWJBLFVBQWEsQ0FBQ3BILEdBQUQsRUFBTUMsQ0FBTixFQUFZO0FBQzdCLFlBQU1pRixlQUFlNUosZ0JBQ25COEYsVUFEbUIsRUFFbkJJLFNBRm1CLEVBR25CQSxTQUhtQixTQUFyQjtBQU1BLFlBQU0yRCxVQUFVLGdCQUFFNUQsVUFBRixDQUNkaEcsV0FBVzZGLFVBQVgsRUFBdUJJLFNBQXZCLEVBQWtDQSxTQUFsQyxTQURjLENBQWhCO0FBR0EsZUFDRTtBQUFDLDBCQUFEO0FBQUEscUJBQWtCLEtBQUt2QixDQUF2QixJQUE4QmlGLFlBQTlCO0FBQ0U7QUFBQyx1QkFBRDtBQUFBO0FBQ0UseUJBQVcsMEJBQ1QsU0FEUyxFQUVULENBQUNwRyxTQUFTTyxNQUFULEdBQWtCWSxDQUFuQixJQUF3QixDQUF4QixHQUE0QixPQUE1QixHQUFzQyxNQUY3QixFQUdUa0YsUUFBUTNLLFNBSEMsQ0FEYjtBQU1FLHFCQUFPMkssUUFBUTFLLEtBQVIsSUFBaUI7QUFOMUI7QUFRRytELDhCQUFrQnVCLEdBQWxCLENBQXNCc0gsYUFBdEI7QUFSSDtBQURGLFNBREY7QUFjRCxPQXhCRDs7QUEwQkEsVUFBTUEsZ0JBQWdCLFNBQWhCQSxhQUFnQixDQUFDekYsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ25DLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1zQyxPQUNKLE9BQU94QixPQUFPd0IsSUFBZCxLQUF1QixVQUF2QixHQUFvQ3hCLE9BQU93QixJQUFQLEVBQXBDLEdBQW9EeEIsT0FBT3dCLElBRDdEO0FBRUEsWUFBSW5DLFFBQVEsZ0JBQUVGLGVBQUYsQ0FDVm1DLFdBQVdsQyxLQURELEVBRVZZLE9BQU9YLEtBRkcsRUFHVlcsT0FBT1YsUUFIRyxDQUFaO0FBS0EsWUFBSWEsT0FBT2QsS0FBWDtBQUNBLFlBQUlnQixXQUFXLGdCQUFFbEIsZUFBRixDQUNibUMsV0FBV2xDLEtBREUsRUFFYlksT0FBT1gsS0FGTSxFQUdiVyxPQUFPSyxRQUhNLENBQWY7QUFLQSxZQUFNcUQsVUFBVSxnQkFBRS9ELFVBQUYsQ0FDZC9GLFdBQVc0RixVQUFYLEVBQXVCSSxTQUF2QixFQUFrQ0ksTUFBbEMsU0FEYyxDQUFoQjtBQUdBLFlBQU0yRCxjQUFjLGdCQUFFaEUsVUFBRixDQUNsQkssT0FBT2xILFFBQVAsQ0FBZ0IwRyxVQUFoQixFQUE0QkksU0FBNUIsRUFBdUNJLE1BQXZDLFNBRGtCLENBQXBCOztBQUlBLFlBQU1TLFVBQVUsQ0FDZGlELFFBQVE5SyxTQURNLEVBRWRvSCxPQUFPcEgsU0FGTyxFQUdkK0ssWUFBWS9LLFNBSEUsQ0FBaEI7O0FBTUEsWUFBTStILHNCQUNEK0MsUUFBUTdLLEtBRFAsRUFFRG1ILE9BQU9uSCxLQUZOLEVBR0Q4SyxZQUFZOUssS0FIWCxDQUFOOztBQU1BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUt3RixJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLEVBQW9CLENBQUNlLElBQUQsSUFBUyxRQUE3QixDQUZiO0FBR0UsZ0NBQ0tiLE1BREw7QUFFRVIsb0JBQVNBLElBQVQsWUFGRjtBQUdFZCxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTXFELFFBQVE1RCxJQVRkO0FBV0csMEJBQUVpQixrQkFBRixDQUFxQnJFLGVBQXJCO0FBWEgsU0FERjtBQWVELE9BakREOztBQW1EQSxVQUFNZ0osb0JBQW9CLFNBQXBCQSxpQkFBb0IsR0FBTTtBQUM5QixZQUFNQyxhQUFhOUwsY0FBYzJGLFVBQWQsRUFBMEJJLFNBQTFCLEVBQXFDQSxTQUFyQyxTQUFuQjtBQUNBLFlBQU1nRyxlQUFlLGdCQUFFakcsVUFBRixDQUNuQjdGLGdCQUFnQjBGLFVBQWhCLEVBQTRCSSxTQUE1QixFQUF1Q0EsU0FBdkMsU0FEbUIsQ0FBckI7QUFHQSxlQUNFO0FBQUMsd0JBQUQ7QUFBQTtBQUNFLHVCQUFXK0YsV0FBVy9NLFNBRHhCO0FBRUUsZ0NBQ0srTSxXQUFXOU0sS0FEaEI7QUFFRXlHLHdCQUFhVCxXQUFiO0FBRkY7QUFGRixhQU1NOEcsV0FBVzdGLElBTmpCO0FBUUU7QUFBQyx1QkFBRDtBQUFBO0FBQ0UseUJBQVcsMEJBQVc4RixhQUFhaE4sU0FBeEIsQ0FEYjtBQUVFLHFCQUFPZ04sYUFBYS9NO0FBRnRCLGVBR00rTSxhQUFhOUYsSUFIbkI7QUFLR2xELDhCQUFrQnVCLEdBQWxCLENBQXNCMEgsZ0JBQXRCO0FBTEg7QUFSRixTQURGO0FBa0JELE9BdkJEOztBQXlCQSxVQUFNQSxtQkFBbUIsU0FBbkJBLGdCQUFtQixDQUFDN0YsTUFBRCxFQUFTM0IsQ0FBVCxFQUFlO0FBQ3RDLFlBQU1pRCxhQUFhaEosUUFBUTBHLElBQVIsQ0FBYTtBQUFBLGlCQUFLQyxFQUFFQyxFQUFGLEtBQVNjLE9BQU9kLEVBQXJCO0FBQUEsU0FBYixLQUF5QyxFQUE1RDtBQUNBLFlBQU1zQyxPQUNKLE9BQU94QixPQUFPd0IsSUFBZCxLQUF1QixVQUF2QixHQUFvQ3hCLE9BQU93QixJQUFQLEVBQXBDLEdBQW9EeEIsT0FBT3dCLElBRDdEO0FBRUEsWUFBTW5DLFFBQVEsZ0JBQUVGLGVBQUYsQ0FDWm1DLFdBQVdsQyxLQURDLEVBRVpZLE9BQU9YLEtBRkssRUFHWlcsT0FBT1YsUUFISyxDQUFkO0FBS0EsWUFBTWUsV0FBVyxnQkFBRWxCLGVBQUYsQ0FDZm1DLFdBQVdsQyxLQURJLEVBRWZZLE9BQU9YLEtBRlEsRUFHZlcsT0FBT0ssUUFIUSxDQUFqQjtBQUtBLFlBQU15RixlQUFlLGdCQUFFbkcsVUFBRixDQUNuQjVGLGdCQUFnQnlGLFVBQWhCLEVBQTRCSSxTQUE1QixFQUF1Q0EsU0FBdkMsU0FEbUIsQ0FBckI7QUFHQSxZQUFNK0QsY0FBYyxnQkFBRWhFLFVBQUYsQ0FDbEJLLE9BQU9sSCxRQUFQLENBQWdCMEcsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDSSxNQUF2QyxTQURrQixDQUFwQjtBQUdBLFlBQU0rRixvQkFBb0IsZ0JBQUVwRyxVQUFGLENBQ3hCSyxPQUFPZ0csY0FBUCxDQUFzQnhHLFVBQXRCLEVBQWtDSSxTQUFsQyxFQUE2Q0ksTUFBN0MsU0FEd0IsQ0FBMUI7O0FBSUEsWUFBTVMsVUFBVSxDQUNkcUYsYUFBYWxOLFNBREMsRUFFZG9ILE9BQU9wSCxTQUZPLEVBR2QrSyxZQUFZL0ssU0FIRSxFQUlkbU4sa0JBQWtCbk4sU0FKSixDQUFoQjs7QUFPQSxZQUFNK0gsc0JBQ0RtRixhQUFhak4sS0FEWixFQUVEbUgsT0FBT25ILEtBRk4sRUFHRDhLLFlBQVk5SyxLQUhYLEVBSURrTixrQkFBa0JsTixLQUpqQixDQUFOOztBQU9BLGVBQ0U7QUFBQyxxQkFBRDtBQUFBO0FBQ0UsaUJBQUt3RixJQUFJLEdBQUosR0FBVTJCLE9BQU9kLEVBRHhCO0FBRUUsdUJBQVcsMEJBQVd1QixPQUFYLEVBQW9CLENBQUNlLElBQUQsSUFBUyxRQUE3QixDQUZiO0FBR0UsZ0NBQ0tiLE1BREw7QUFFRVIsb0JBQVNkLEtBQVQsWUFGRjtBQUdFQSxxQkFBTyxnQkFBRXlCLElBQUYsQ0FBT3pCLEtBQVAsQ0FIVDtBQUlFZ0Isd0JBQVUsZ0JBQUVTLElBQUYsQ0FBT1QsUUFBUDtBQUpaO0FBSEYsYUFTTXNELFlBQVk3RCxJQVRsQixFQVVNZ0csYUFBYWhHLElBVm5CLEVBV01pRyxrQkFBa0JqRyxJQVh4QjtBQWFHLDBCQUFFaUIsa0JBQUYsQ0FBcUJmLE9BQU9uQyxNQUE1QixFQUFvQztBQUNuQ29ELGtCQUFNbEUsVUFENkI7QUFFbkNpRCxvQkFBUUE7QUFGMkIsV0FBcEM7QUFiSCxTQURGO0FBb0JELE9BMUREOztBQTREQSxVQUFNaUcsaUJBQWlCLFNBQWpCQSxjQUFpQixHQUFNO0FBQzNCLFlBQU1DLGtCQUFrQixnQkFBRXZHLFVBQUYsQ0FDdEIzRixtQkFBbUJ3RixVQUFuQixFQUErQkksU0FBL0IsRUFBMENBLFNBQTFDLFNBRHNCLENBQXhCO0FBR0EsZUFDRSw4QkFBQyxtQkFBRCxlQUNNbEgsYUFETjtBQUVFLGlCQUFPNEMsS0FGVDtBQUdFLHVCQUFhcUQsV0FIZjtBQUlFLG1CQUFTQyxPQUpYO0FBS0Usd0JBQWMsT0FBS3ZILFlBTHJCO0FBTUUsNEJBQWtCLE9BQUtDLGdCQU56QjtBQU9FLHFCQUFXNE8sZ0JBQWdCdE4sU0FQN0I7QUFRRSxpQkFBT3NOLGdCQUFnQnJOO0FBUnpCLFdBU01xTixnQkFBZ0JwRyxJQVR0QixFQURGO0FBYUQsT0FqQkQ7O0FBbUJBLFVBQU1xRyxZQUFZLGdCQUFFeEcsVUFBRixDQUNoQjdHLFNBQVMwRyxVQUFULEVBQXFCSSxTQUFyQixFQUFnQ0EsU0FBaEMsRUFBMkMsSUFBM0MsQ0FEZ0IsQ0FBbEI7QUFHQSxVQUFNd0csYUFBYSxnQkFBRXpHLFVBQUYsQ0FDakI1RyxjQUFjeUcsVUFBZCxFQUEwQkksU0FBMUIsRUFBcUNBLFNBQXJDLEVBQWdELElBQWhELENBRGlCLENBQW5CO0FBR0EsVUFBTXlHLGFBQWEsZ0JBQUUxRyxVQUFGLENBQ2pCbEcsY0FBYytGLFVBQWQsRUFBMEJJLFNBQTFCLEVBQXFDQSxTQUFyQyxFQUFnRCxJQUFoRCxDQURpQixDQUFuQjtBQUdBLFVBQU0wRyxlQUFlck0sZ0JBQWdCdUYsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDQSxTQUF2QyxFQUFrRCxJQUFsRCxDQUFyQjtBQUNBLFVBQU0yRyxjQUFjck0sZUFBZXNGLFVBQWYsRUFBMkJJLFNBQTNCLEVBQXNDQSxTQUF0QyxFQUFpRCxJQUFqRCxDQUFwQjtBQUNBLFVBQU1pQyxlQUFlMUgsZ0JBQWdCcUYsVUFBaEIsRUFBNEJJLFNBQTVCLEVBQXVDQSxTQUF2QyxFQUFrRCxJQUFsRCxDQUFyQjs7QUFFQSxVQUFNNEcsWUFBWSxTQUFaQSxTQUFZLEdBQU07QUFDdEIsWUFBTUMsYUFBYVIsZ0JBQW5CO0FBQ0EsZUFDRTtBQUFBO0FBQUE7QUFDRSx1QkFBVywwQkFBVyxZQUFYLEVBQXlCck4sU0FBekIsRUFBb0N1TixVQUFVdk4sU0FBOUMsQ0FEYjtBQUVFLGdDQUNLQyxLQURMLEVBRUtzTixVQUFVdE4sS0FGZjtBQUZGLGFBTU1zTixVQUFVckcsSUFOaEI7QUFRRzFGLDRCQUFrQkMsaUJBQWxCLEdBQ0c7QUFBQTtBQUFBLGNBQUssV0FBVSxnQkFBZjtBQUNDb007QUFERCxXQURILEdBSUcsSUFaTjtBQWFFO0FBQUMsMEJBQUQ7QUFBQTtBQUNFLHlCQUFXLDBCQUNUTCxXQUFXeE4sU0FERixFQUVUSixvQkFBb0IsYUFBcEIsR0FBb0MsRUFGM0IsQ0FEYjtBQUtFLHFCQUFPNE4sV0FBV3ZOO0FBTHBCLGVBTU11TixXQUFXdEcsSUFOakI7QUFRR2hELDhCQUFrQjJDLGtCQUFsQixHQUF1QyxJQVIxQztBQVNHeUIseUJBVEg7QUFVR3BELHlCQUFhb0UsYUFBYixHQUE2QixJQVZoQztBQVdFO0FBQUMsNEJBQUQ7QUFBQTtBQUNFLDJCQUFXLDBCQUFXbUUsV0FBV3pOLFNBQXRCLENBRGI7QUFFRSxvQ0FDS3lOLFdBQVd4TixLQURoQjtBQUVFeUcsNEJBQWFULFdBQWI7QUFGRjtBQUZGLGlCQU1Nd0gsV0FBV3ZHLElBTmpCO0FBUUc1Qyx1QkFBU2lCLEdBQVQsQ0FBYSxVQUFDUCxDQUFELEVBQUlTLENBQUo7QUFBQSx1QkFBVXVFLFlBQVloRixDQUFaLEVBQWVTLENBQWYsQ0FBVjtBQUFBLGVBQWIsQ0FSSDtBQVNHaEIsc0JBQVFjLEdBQVIsQ0FBWXFILFVBQVo7QUFUSCxhQVhGO0FBc0JHOUgsOEJBQWtCZ0ksbUJBQWxCLEdBQXdDO0FBdEIzQyxXQWJGO0FBcUNHdEwsNEJBQWtCRSxvQkFBbEIsR0FDRztBQUFBO0FBQUEsY0FBSyxXQUFVLG1CQUFmO0FBQ0NtTTtBQURELFdBREgsR0FJRyxJQXpDTjtBQTBDRyxXQUFDdkosU0FBU08sTUFBVixJQUNDO0FBQUMsMkJBQUQ7QUFBcUI4SSx1QkFBckI7QUFDRyw0QkFBRXhGLGtCQUFGLENBQXFCdEcsVUFBckI7QUFESCxXQTNDSjtBQThDRSx3Q0FBQyxnQkFBRDtBQUNFLHFCQUFTWSxPQURYO0FBRUUseUJBQWFiO0FBRmYsYUFHTThMLFlBSE47QUE5Q0YsU0FERjtBQXNERCxPQXhERDs7QUEwREE7QUFDQSxhQUFPM04sV0FBV0EsU0FBUzZHLFVBQVQsRUFBcUJnSCxTQUFyQixFQUFnQyxJQUFoQyxDQUFYLEdBQW1EQSxXQUExRDtBQUNEOzs7O0VBLzlCcUMsdUJBQVEsMENBQVIsQzs7QUFBbkIvUCxVLENBQ1ppUSxZO2tCQURZalEsVSIsImZpbGUiOiJpbmRleC5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBSZWFjdCwgeyBDb21wb25lbnQgfSBmcm9tICdyZWFjdCdcbmltcG9ydCBjbGFzc25hbWVzIGZyb20gJ2NsYXNzbmFtZXMnXG4vL1xuaW1wb3J0IF8gZnJvbSAnLi91dGlscydcbmltcG9ydCBMaWZlY3ljbGUgZnJvbSAnLi9saWZlY3ljbGUnXG5pbXBvcnQgTWV0aG9kcyBmcm9tICcuL21ldGhvZHMnXG5pbXBvcnQgZGVmYXVsdFByb3BzIGZyb20gJy4vZGVmYXVsdFByb3BzJ1xuXG5leHBvcnQgY29uc3QgUmVhY3RUYWJsZURlZmF1bHRzID0gZGVmYXVsdFByb3BzXG5cbmV4cG9ydCBkZWZhdWx0IGNsYXNzIFJlYWN0VGFibGUgZXh0ZW5kcyBNZXRob2RzKExpZmVjeWNsZShDb21wb25lbnQpKSB7XG4gIHN0YXRpYyBkZWZhdWx0UHJvcHMgPSBkZWZhdWx0UHJvcHNcblxuICBjb25zdHJ1Y3RvciAocHJvcHMpIHtcbiAgICBzdXBlcigpXG5cbiAgICB0aGlzLmdldFJlc29sdmVkU3RhdGUgPSB0aGlzLmdldFJlc29sdmVkU3RhdGUuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0RGF0YU1vZGVsID0gdGhpcy5nZXREYXRhTW9kZWwuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0U29ydGVkRGF0YSA9IHRoaXMuZ2V0U29ydGVkRGF0YS5iaW5kKHRoaXMpXG4gICAgdGhpcy5maXJlRmV0Y2hEYXRhID0gdGhpcy5maXJlRmV0Y2hEYXRhLmJpbmQodGhpcylcbiAgICB0aGlzLmdldFByb3BPclN0YXRlID0gdGhpcy5nZXRQcm9wT3JTdGF0ZS5iaW5kKHRoaXMpXG4gICAgdGhpcy5nZXRTdGF0ZU9yUHJvcCA9IHRoaXMuZ2V0U3RhdGVPclByb3AuYmluZCh0aGlzKVxuICAgIHRoaXMuZmlsdGVyRGF0YSA9IHRoaXMuZmlsdGVyRGF0YS5iaW5kKHRoaXMpXG4gICAgdGhpcy5zb3J0RGF0YSA9IHRoaXMuc29ydERhdGEuYmluZCh0aGlzKVxuICAgIHRoaXMuZ2V0TWluUm93cyA9IHRoaXMuZ2V0TWluUm93cy5iaW5kKHRoaXMpXG4gICAgdGhpcy5vblBhZ2VDaGFuZ2UgPSB0aGlzLm9uUGFnZUNoYW5nZS5iaW5kKHRoaXMpXG4gICAgdGhpcy5vblBhZ2VTaXplQ2hhbmdlID0gdGhpcy5vblBhZ2VTaXplQ2hhbmdlLmJpbmQodGhpcylcbiAgICB0aGlzLnNvcnRDb2x1bW4gPSB0aGlzLnNvcnRDb2x1bW4uYmluZCh0aGlzKVxuICAgIHRoaXMuZmlsdGVyQ29sdW1uID0gdGhpcy5maWx0ZXJDb2x1bW4uYmluZCh0aGlzKVxuICAgIHRoaXMucmVzaXplQ29sdW1uU3RhcnQgPSB0aGlzLnJlc2l6ZUNvbHVtblN0YXJ0LmJpbmQodGhpcylcbiAgICB0aGlzLnJlc2l6ZUNvbHVtbkVuZCA9IHRoaXMucmVzaXplQ29sdW1uRW5kLmJpbmQodGhpcylcbiAgICB0aGlzLnJlc2l6ZUNvbHVtbk1vdmluZyA9IHRoaXMucmVzaXplQ29sdW1uTW92aW5nLmJpbmQodGhpcylcblxuICAgIHRoaXMuc3RhdGUgPSB7XG4gICAgICBwYWdlOiAwLFxuICAgICAgcGFnZVNpemU6IHByb3BzLmRlZmF1bHRQYWdlU2l6ZSxcbiAgICAgIHNvcnRlZDogcHJvcHMuZGVmYXVsdFNvcnRlZCxcbiAgICAgIGV4cGFuZGVkOiBwcm9wcy5kZWZhdWx0RXhwYW5kZWQsXG4gICAgICBmaWx0ZXJlZDogcHJvcHMuZGVmYXVsdEZpbHRlcmVkLFxuICAgICAgcmVzaXplZDogcHJvcHMuZGVmYXVsdFJlc2l6ZWQsXG4gICAgICBjdXJyZW50bHlSZXNpemluZzogZmFsc2UsXG4gICAgICBza2lwTmV4dFNvcnQ6IGZhbHNlLFxuICAgIH1cbiAgfVxuXG4gIHJlbmRlciAoKSB7XG4gICAgY29uc3QgcmVzb2x2ZWRTdGF0ZSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpXG4gICAgY29uc3Qge1xuICAgICAgY2hpbGRyZW4sXG4gICAgICBjbGFzc05hbWUsXG4gICAgICBzdHlsZSxcbiAgICAgIGdldFByb3BzLFxuICAgICAgZ2V0VGFibGVQcm9wcyxcbiAgICAgIGdldFRoZWFkR3JvdXBQcm9wcyxcbiAgICAgIGdldFRoZWFkR3JvdXBUclByb3BzLFxuICAgICAgZ2V0VGhlYWRHcm91cFRoUHJvcHMsXG4gICAgICBnZXRUaGVhZFByb3BzLFxuICAgICAgZ2V0VGhlYWRUclByb3BzLFxuICAgICAgZ2V0VGhlYWRUaFByb3BzLFxuICAgICAgZ2V0VGhlYWRGaWx0ZXJQcm9wcyxcbiAgICAgIGdldFRoZWFkRmlsdGVyVHJQcm9wcyxcbiAgICAgIGdldFRoZWFkRmlsdGVyVGhQcm9wcyxcbiAgICAgIGdldFRib2R5UHJvcHMsXG4gICAgICBnZXRUckdyb3VwUHJvcHMsXG4gICAgICBnZXRUclByb3BzLFxuICAgICAgZ2V0VGRQcm9wcyxcbiAgICAgIGdldFRmb290UHJvcHMsXG4gICAgICBnZXRUZm9vdFRyUHJvcHMsXG4gICAgICBnZXRUZm9vdFRkUHJvcHMsXG4gICAgICBnZXRQYWdpbmF0aW9uUHJvcHMsXG4gICAgICBnZXRMb2FkaW5nUHJvcHMsXG4gICAgICBnZXROb0RhdGFQcm9wcyxcbiAgICAgIGdldFJlc2l6ZXJQcm9wcyxcbiAgICAgIHNob3dQYWdpbmF0aW9uLFxuICAgICAgc2hvd1BhZ2luYXRpb25Ub3AsXG4gICAgICBzaG93UGFnaW5hdGlvbkJvdHRvbSxcbiAgICAgIG1hbnVhbCxcbiAgICAgIGxvYWRpbmdUZXh0LFxuICAgICAgbm9EYXRhVGV4dCxcbiAgICAgIHNvcnRhYmxlLFxuICAgICAgcmVzaXphYmxlLFxuICAgICAgZmlsdGVyYWJsZSxcbiAgICAgIC8vIFBpdm90aW5nIFN0YXRlXG4gICAgICBwaXZvdElES2V5LFxuICAgICAgcGl2b3RWYWxLZXksXG4gICAgICBwaXZvdEJ5LFxuICAgICAgc3ViUm93c0tleSxcbiAgICAgIGFnZ3JlZ2F0ZWRLZXksXG4gICAgICBvcmlnaW5hbEtleSxcbiAgICAgIGluZGV4S2V5LFxuICAgICAgZ3JvdXBlZEJ5UGl2b3RLZXksXG4gICAgICAvLyBTdGF0ZVxuICAgICAgbG9hZGluZyxcbiAgICAgIHBhZ2VTaXplLFxuICAgICAgcGFnZSxcbiAgICAgIHNvcnRlZCxcbiAgICAgIGZpbHRlcmVkLFxuICAgICAgcmVzaXplZCxcbiAgICAgIGV4cGFuZGVkLFxuICAgICAgcGFnZXMsXG4gICAgICBvbkV4cGFuZGVkQ2hhbmdlLFxuICAgICAgLy8gQ29tcG9uZW50c1xuICAgICAgVGFibGVDb21wb25lbnQsXG4gICAgICBUaGVhZENvbXBvbmVudCxcbiAgICAgIFRib2R5Q29tcG9uZW50LFxuICAgICAgVHJHcm91cENvbXBvbmVudCxcbiAgICAgIFRyQ29tcG9uZW50LFxuICAgICAgVGhDb21wb25lbnQsXG4gICAgICBUZENvbXBvbmVudCxcbiAgICAgIFRmb290Q29tcG9uZW50LFxuICAgICAgUGFnaW5hdGlvbkNvbXBvbmVudCxcbiAgICAgIExvYWRpbmdDb21wb25lbnQsXG4gICAgICBTdWJDb21wb25lbnQsXG4gICAgICBOb0RhdGFDb21wb25lbnQsXG4gICAgICBSZXNpemVyQ29tcG9uZW50LFxuICAgICAgRXhwYW5kZXJDb21wb25lbnQsXG4gICAgICBQaXZvdFZhbHVlQ29tcG9uZW50LFxuICAgICAgUGl2b3RDb21wb25lbnQsXG4gICAgICBBZ2dyZWdhdGVkQ29tcG9uZW50LFxuICAgICAgRmlsdGVyQ29tcG9uZW50LFxuICAgICAgUGFkUm93Q29tcG9uZW50LFxuICAgICAgLy8gRGF0YSBtb2RlbFxuICAgICAgcmVzb2x2ZWREYXRhLFxuICAgICAgYWxsVmlzaWJsZUNvbHVtbnMsXG4gICAgICBoZWFkZXJHcm91cHMsXG4gICAgICBoYXNIZWFkZXJHcm91cHMsXG4gICAgICAvLyBTb3J0ZWQgRGF0YVxuICAgICAgc29ydGVkRGF0YSxcbiAgICAgIGN1cnJlbnRseVJlc2l6aW5nLFxuICAgIH0gPSByZXNvbHZlZFN0YXRlXG5cbiAgICAvLyBQYWdpbmF0aW9uXG4gICAgY29uc3Qgc3RhcnRSb3cgPSBwYWdlU2l6ZSAqIHBhZ2VcbiAgICBjb25zdCBlbmRSb3cgPSBzdGFydFJvdyArIHBhZ2VTaXplXG4gICAgbGV0IHBhZ2VSb3dzID0gbWFudWFsID8gcmVzb2x2ZWREYXRhIDogc29ydGVkRGF0YS5zbGljZShzdGFydFJvdywgZW5kUm93KVxuICAgIGNvbnN0IG1pblJvd3MgPSB0aGlzLmdldE1pblJvd3MoKVxuICAgIGNvbnN0IHBhZFJvd3MgPSBfLnJhbmdlKE1hdGgubWF4KG1pblJvd3MgLSBwYWdlUm93cy5sZW5ndGgsIDApKVxuXG4gICAgY29uc3QgaGFzQ29sdW1uRm9vdGVyID0gYWxsVmlzaWJsZUNvbHVtbnMuc29tZShkID0+IGQuRm9vdGVyKVxuICAgIGNvbnN0IGhhc0ZpbHRlcnMgPSBmaWx0ZXJhYmxlIHx8IGFsbFZpc2libGVDb2x1bW5zLnNvbWUoZCA9PiBkLmZpbHRlcmFibGUpXG5cbiAgICBjb25zdCByZWN1cnNlUm93c1ZpZXdJbmRleCA9IChyb3dzLCBwYXRoID0gW10sIGluZGV4ID0gLTEpID0+IHtcbiAgICAgIHJldHVybiBbXG4gICAgICAgIHJvd3MubWFwKChyb3csIGkpID0+IHtcbiAgICAgICAgICBpbmRleCsrXG4gICAgICAgICAgY29uc3Qgcm93V2l0aFZpZXdJbmRleCA9IHtcbiAgICAgICAgICAgIC4uLnJvdyxcbiAgICAgICAgICAgIF92aWV3SW5kZXg6IGluZGV4LFxuICAgICAgICAgIH1cbiAgICAgICAgICBjb25zdCBuZXdQYXRoID0gcGF0aC5jb25jYXQoW2ldKVxuICAgICAgICAgIGlmIChyb3dXaXRoVmlld0luZGV4W3N1YlJvd3NLZXldICYmIF8uZ2V0KGV4cGFuZGVkLCBuZXdQYXRoKSkge1xuICAgICAgICAgICAgO1tyb3dXaXRoVmlld0luZGV4W3N1YlJvd3NLZXldLCBpbmRleF0gPSByZWN1cnNlUm93c1ZpZXdJbmRleChcbiAgICAgICAgICAgICAgcm93V2l0aFZpZXdJbmRleFtzdWJSb3dzS2V5XSxcbiAgICAgICAgICAgICAgbmV3UGF0aCxcbiAgICAgICAgICAgICAgaW5kZXhcbiAgICAgICAgICAgIClcbiAgICAgICAgICB9XG4gICAgICAgICAgcmV0dXJuIHJvd1dpdGhWaWV3SW5kZXhcbiAgICAgICAgfSksXG4gICAgICAgIGluZGV4LFxuICAgICAgXVxuICAgIH1cbiAgICA7W3BhZ2VSb3dzXSA9IHJlY3Vyc2VSb3dzVmlld0luZGV4KHBhZ2VSb3dzKVxuXG4gICAgY29uc3QgY2FuUHJldmlvdXMgPSBwYWdlID4gMFxuICAgIGNvbnN0IGNhbk5leHQgPSBwYWdlICsgMSA8IHBhZ2VzXG5cbiAgICBjb25zdCByb3dNaW5XaWR0aCA9IF8uc3VtKFxuICAgICAgYWxsVmlzaWJsZUNvbHVtbnMubWFwKGQgPT4ge1xuICAgICAgICBjb25zdCByZXNpemVkQ29sdW1uID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gZC5pZCkgfHwge31cbiAgICAgICAgcmV0dXJuIF8uZ2V0Rmlyc3REZWZpbmVkKHJlc2l6ZWRDb2x1bW4udmFsdWUsIGQud2lkdGgsIGQubWluV2lkdGgpXG4gICAgICB9KVxuICAgIClcblxuICAgIGxldCByb3dJbmRleCA9IC0xXG5cbiAgICBjb25zdCBmaW5hbFN0YXRlID0ge1xuICAgICAgLi4ucmVzb2x2ZWRTdGF0ZSxcbiAgICAgIHN0YXJ0Um93LFxuICAgICAgZW5kUm93LFxuICAgICAgcGFnZVJvd3MsXG4gICAgICBtaW5Sb3dzLFxuICAgICAgcGFkUm93cyxcbiAgICAgIGhhc0NvbHVtbkZvb3RlcixcbiAgICAgIGNhblByZXZpb3VzLFxuICAgICAgY2FuTmV4dCxcbiAgICAgIHJvd01pbldpZHRoLFxuICAgIH1cblxuICAgIC8vIFZpc3VhbCBDb21wb25lbnRzXG5cbiAgICBjb25zdCBtYWtlSGVhZGVyR3JvdXBzID0gKCkgPT4ge1xuICAgICAgY29uc3QgdGhlYWRHcm91cFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEdyb3VwUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCB0aGVhZEdyb3VwVHJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VGhlYWRHcm91cFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1oZWFkZXJHcm91cHMnLCB0aGVhZEdyb3VwUHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4udGhlYWRHcm91cFByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50aGVhZEdyb3VwUHJvcHMucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXt0aGVhZEdyb3VwVHJQcm9wcy5jbGFzc05hbWV9XG4gICAgICAgICAgICBzdHlsZT17dGhlYWRHcm91cFRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGhlYWRHcm91cFRyUHJvcHMucmVzdH1cbiAgICAgICAgICA+XG4gICAgICAgICAgICB7aGVhZGVyR3JvdXBzLm1hcChtYWtlSGVhZGVyR3JvdXApfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgIDwvVGhlYWRDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlckdyb3VwID0gKGNvbHVtbiwgaSkgPT4ge1xuICAgICAgY29uc3QgcmVzaXplZFZhbHVlID0gY29sID0+XG4gICAgICAgIChyZXNpemVkLmZpbmQoeCA9PiB4LmlkID09PSBjb2wuaWQpIHx8IHt9KS52YWx1ZVxuICAgICAgY29uc3QgZmxleCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoXG4gICAgICAgICAgY29sID0+IChjb2wud2lkdGggfHwgcmVzaXplZFZhbHVlKGNvbCkgPyAwIDogY29sLm1pbldpZHRoKVxuICAgICAgICApXG4gICAgICApXG4gICAgICBjb25zdCB3aWR0aCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoY29sID0+XG4gICAgICAgICAgXy5nZXRGaXJzdERlZmluZWQocmVzaXplZFZhbHVlKGNvbCksIGNvbC53aWR0aCwgY29sLm1pbldpZHRoKVxuICAgICAgICApXG4gICAgICApXG4gICAgICBjb25zdCBtYXhXaWR0aCA9IF8uc3VtKFxuICAgICAgICBjb2x1bW4uY29sdW1ucy5tYXAoY29sID0+XG4gICAgICAgICAgXy5nZXRGaXJzdERlZmluZWQocmVzaXplZFZhbHVlKGNvbCksIGNvbC53aWR0aCwgY29sLm1heFdpZHRoKVxuICAgICAgICApXG4gICAgICApXG5cbiAgICAgIGNvbnN0IHRoZWFkR3JvdXBUaFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEdyb3VwVGhQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtbkhlYWRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0SGVhZGVyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG5cbiAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgIGNvbHVtbi5oZWFkZXJDbGFzc05hbWUsXG4gICAgICAgIHRoZWFkR3JvdXBUaFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uSGVhZGVyUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLmNvbHVtbi5oZWFkZXJTdHlsZSxcbiAgICAgICAgLi4udGhlYWRHcm91cFRoUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbkhlYWRlclByb3BzLnN0eWxlLFxuICAgICAgfVxuXG4gICAgICBjb25zdCByZXN0ID0ge1xuICAgICAgICAuLi50aGVhZEdyb3VwVGhQcm9wcy5yZXN0LFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5yZXN0LFxuICAgICAgfVxuXG4gICAgICBjb25zdCBmbGV4U3R5bGVzID0ge1xuICAgICAgICBmbGV4OiBgJHtmbGV4fSAwIGF1dG9gLFxuICAgICAgICB3aWR0aDogXy5hc1B4KHdpZHRoKSxcbiAgICAgICAgbWF4V2lkdGg6IF8uYXNQeChtYXhXaWR0aCksXG4gICAgICB9XG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUaENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3Nlcyl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIC4uLmZsZXhTdHlsZXMsXG4gICAgICAgICAgfX1cbiAgICAgICAgICB7Li4ucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIHtfLm5vcm1hbGl6ZUNvbXBvbmVudChjb2x1bW4uSGVhZGVyLCB7XG4gICAgICAgICAgICBkYXRhOiBzb3J0ZWREYXRhLFxuICAgICAgICAgICAgY29sdW1uOiBjb2x1bW4sXG4gICAgICAgICAgfSl9XG4gICAgICAgIDwvVGhDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlcnMgPSAoKSA9PiB7XG4gICAgICBjb25zdCB0aGVhZFByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgdGhlYWRUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1oZWFkZXInLCB0aGVhZFByb3BzLmNsYXNzTmFtZSl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnRoZWFkUHJvcHMuc3R5bGUsXG4gICAgICAgICAgICBtaW5XaWR0aDogYCR7cm93TWluV2lkdGh9cHhgLFxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLnRoZWFkUHJvcHMucmVzdH1cbiAgICAgICAgPlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXt0aGVhZFRyUHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgICAgc3R5bGU9e3RoZWFkVHJQcm9wcy5zdHlsZX1cbiAgICAgICAgICAgIHsuLi50aGVhZFRyUHJvcHMucmVzdH1cbiAgICAgICAgICA+XG4gICAgICAgICAgICB7YWxsVmlzaWJsZUNvbHVtbnMubWFwKG1ha2VIZWFkZXIpfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgIDwvVGhlYWRDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUhlYWRlciA9IChjb2x1bW4sIGkpID0+IHtcbiAgICAgIGNvbnN0IHJlc2l6ZWRDb2wgPSByZXNpemVkLmZpbmQoeCA9PiB4LmlkID09PSBjb2x1bW4uaWQpIHx8IHt9XG4gICAgICBjb25zdCBzb3J0ID0gc29ydGVkLmZpbmQoZCA9PiBkLmlkID09PSBjb2x1bW4uaWQpXG4gICAgICBjb25zdCBzaG93ID1cbiAgICAgICAgdHlwZW9mIGNvbHVtbi5zaG93ID09PSAnZnVuY3Rpb24nID8gY29sdW1uLnNob3coKSA6IGNvbHVtbi5zaG93XG4gICAgICBjb25zdCB3aWR0aCA9IF8uZ2V0Rmlyc3REZWZpbmVkKFxuICAgICAgICByZXNpemVkQ29sLnZhbHVlLFxuICAgICAgICBjb2x1bW4ud2lkdGgsXG4gICAgICAgIGNvbHVtbi5taW5XaWR0aFxuICAgICAgKVxuICAgICAgY29uc3QgbWF4V2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWF4V2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IHRoZWFkVGhQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VGhlYWRUaFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgY29sdW1uSGVhZGVyUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGNvbHVtbi5nZXRIZWFkZXJQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcblxuICAgICAgY29uc3QgY2xhc3NlcyA9IFtcbiAgICAgICAgY29sdW1uLmhlYWRlckNsYXNzTmFtZSxcbiAgICAgICAgdGhlYWRUaFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uSGVhZGVyUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLmNvbHVtbi5oZWFkZXJTdHlsZSxcbiAgICAgICAgLi4udGhlYWRUaFByb3BzLnN0eWxlLFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5zdHlsZSxcbiAgICAgIH1cblxuICAgICAgY29uc3QgcmVzdCA9IHtcbiAgICAgICAgLi4udGhlYWRUaFByb3BzLnJlc3QsXG4gICAgICAgIC4uLmNvbHVtbkhlYWRlclByb3BzLnJlc3QsXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IGlzUmVzaXphYmxlID0gXy5nZXRGaXJzdERlZmluZWQoY29sdW1uLnJlc2l6YWJsZSwgcmVzaXphYmxlLCBmYWxzZSlcbiAgICAgIGNvbnN0IHJlc2l6ZXIgPSBpc1Jlc2l6YWJsZVxuICAgICAgICA/ICg8UmVzaXplckNvbXBvbmVudFxuICAgICAgICAgIG9uTW91c2VEb3duPXtlID0+IHRoaXMucmVzaXplQ29sdW1uU3RhcnQoZSwgY29sdW1uLCBmYWxzZSl9XG4gICAgICAgICAgb25Ub3VjaFN0YXJ0PXtlID0+IHRoaXMucmVzaXplQ29sdW1uU3RhcnQoZSwgY29sdW1uLCB0cnVlKX1cbiAgICAgICAgICB7Li4ucmVzaXplclByb3BzfVxuICAgICAgICAvPilcbiAgICAgICAgOiBudWxsXG5cbiAgICAgIGNvbnN0IGlzU29ydGFibGUgPSBfLmdldEZpcnN0RGVmaW5lZChjb2x1bW4uc29ydGFibGUsIHNvcnRhYmxlLCBmYWxzZSlcblxuICAgICAgcmV0dXJuIChcbiAgICAgICAgPFRoQ29tcG9uZW50XG4gICAgICAgICAga2V5PXtpICsgJy0nICsgY29sdW1uLmlkfVxuICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgIGNsYXNzZXMsXG4gICAgICAgICAgICAncnQtcmVzaXphYmxlLWhlYWRlcicsXG4gICAgICAgICAgICBzb3J0ID8gKHNvcnQuZGVzYyA/ICctc29ydC1kZXNjJyA6ICctc29ydC1hc2MnKSA6ICcnLFxuICAgICAgICAgICAgaXNTb3J0YWJsZSAmJiAnLWN1cnNvci1wb2ludGVyJyxcbiAgICAgICAgICAgICFzaG93ICYmICctaGlkZGVuJyxcbiAgICAgICAgICAgIHBpdm90QnkgJiZcbiAgICAgICAgICAgICAgcGl2b3RCeS5zbGljZSgwLCAtMSkuaW5jbHVkZXMoY29sdW1uLmlkKSAmJlxuICAgICAgICAgICAgICAncnQtaGVhZGVyLXBpdm90J1xuICAgICAgICAgICl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIGZsZXg6IGAke3dpZHRofSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHRvZ2dsZVNvcnQ9e2UgPT4ge1xuICAgICAgICAgICAgaXNTb3J0YWJsZSAmJiB0aGlzLnNvcnRDb2x1bW4oY29sdW1uLCBlLnNoaWZ0S2V5KVxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8ZGl2IGNsYXNzTmFtZT0ncnQtcmVzaXphYmxlLWhlYWRlci1jb250ZW50Jz5cbiAgICAgICAgICAgIHtfLm5vcm1hbGl6ZUNvbXBvbmVudChjb2x1bW4uSGVhZGVyLCB7XG4gICAgICAgICAgICAgIGRhdGE6IHNvcnRlZERhdGEsXG4gICAgICAgICAgICAgIGNvbHVtbjogY29sdW1uLFxuICAgICAgICAgICAgfSl9XG4gICAgICAgICAgPC9kaXY+XG4gICAgICAgICAge3Jlc2l6ZXJ9XG4gICAgICAgIDwvVGhDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZUZpbHRlcnMgPSAoKSA9PiB7XG4gICAgICBjb25zdCB0aGVhZEZpbHRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEZpbHRlclByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgY29uc3QgdGhlYWRGaWx0ZXJUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUaGVhZEZpbHRlclRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGhlYWRDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoJy1maWx0ZXJzJywgdGhlYWRGaWx0ZXJQcm9wcy5jbGFzc05hbWUpfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi50aGVhZEZpbHRlclByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50aGVhZEZpbHRlclByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17dGhlYWRGaWx0ZXJUclByb3BzLmNsYXNzTmFtZX1cbiAgICAgICAgICAgIHN0eWxlPXt0aGVhZEZpbHRlclRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGhlYWRGaWx0ZXJUclByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcChtYWtlRmlsdGVyKX1cbiAgICAgICAgICA8L1RyQ29tcG9uZW50PlxuICAgICAgICA8L1RoZWFkQ29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VGaWx0ZXIgPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IG1heFdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1heFdpZHRoXG4gICAgICApXG4gICAgICBjb25zdCB0aGVhZEZpbHRlclRoUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRoZWFkRmlsdGVyVGhQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIGNvbHVtbiwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtbkhlYWRlclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0SGVhZGVyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG5cbiAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgIGNvbHVtbi5oZWFkZXJDbGFzc05hbWUsXG4gICAgICAgIHRoZWFkRmlsdGVyVGhQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgIGNvbHVtbkhlYWRlclByb3BzLmNsYXNzTmFtZSxcbiAgICAgIF1cblxuICAgICAgY29uc3Qgc3R5bGVzID0ge1xuICAgICAgICAuLi5jb2x1bW4uaGVhZGVyU3R5bGUsXG4gICAgICAgIC4uLnRoZWFkRmlsdGVyVGhQcm9wcy5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uSGVhZGVyUHJvcHMuc3R5bGUsXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IHJlc3QgPSB7XG4gICAgICAgIC4uLnRoZWFkRmlsdGVyVGhQcm9wcy5yZXN0LFxuICAgICAgICAuLi5jb2x1bW5IZWFkZXJQcm9wcy5yZXN0LFxuICAgICAgfVxuXG4gICAgICBjb25zdCBmaWx0ZXIgPSBmaWx0ZXJlZC5maW5kKGZpbHRlciA9PiBmaWx0ZXIuaWQgPT09IGNvbHVtbi5pZClcblxuICAgICAgY29uc3QgUmVzb2x2ZWRGaWx0ZXJDb21wb25lbnQgPSBjb2x1bW4uRmlsdGVyIHx8IEZpbHRlckNvbXBvbmVudFxuXG4gICAgICBjb25zdCBpc0ZpbHRlcmFibGUgPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgY29sdW1uLmZpbHRlcmFibGUsXG4gICAgICAgIGZpbHRlcmFibGUsXG4gICAgICAgIGZhbHNlXG4gICAgICApXG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUaENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3Nlcyl9XG4gICAgICAgICAgc3R5bGU9e3tcbiAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgIGZsZXg6IGAke3dpZHRofSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi5yZXN0fVxuICAgICAgICA+XG4gICAgICAgICAge2lzRmlsdGVyYWJsZVxuICAgICAgICAgICAgPyBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgUmVzb2x2ZWRGaWx0ZXJDb21wb25lbnQsXG4gICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICBjb2x1bW4sXG4gICAgICAgICAgICAgICAgZmlsdGVyLFxuICAgICAgICAgICAgICAgIG9uQ2hhbmdlOiB2YWx1ZSA9PiB0aGlzLmZpbHRlckNvbHVtbihjb2x1bW4sIHZhbHVlKSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgZGVmYXVsdFByb3BzLmNvbHVtbi5GaWx0ZXJcbiAgICAgICAgICAgIClcbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgPC9UaENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlUGFnZVJvdyA9IChyb3csIGksIHBhdGggPSBbXSkgPT4ge1xuICAgICAgY29uc3Qgcm93SW5mbyA9IHtcbiAgICAgICAgb3JpZ2luYWw6IHJvd1tvcmlnaW5hbEtleV0sXG4gICAgICAgIHJvdzogcm93LFxuICAgICAgICBpbmRleDogcm93W2luZGV4S2V5XSxcbiAgICAgICAgdmlld0luZGV4OiArK3Jvd0luZGV4LFxuICAgICAgICBsZXZlbDogcGF0aC5sZW5ndGgsXG4gICAgICAgIG5lc3RpbmdQYXRoOiBwYXRoLmNvbmNhdChbaV0pLFxuICAgICAgICBhZ2dyZWdhdGVkOiByb3dbYWdncmVnYXRlZEtleV0sXG4gICAgICAgIGdyb3VwZWRCeVBpdm90OiByb3dbZ3JvdXBlZEJ5UGl2b3RLZXldLFxuICAgICAgICBzdWJSb3dzOiByb3dbc3ViUm93c0tleV0sXG4gICAgICB9XG4gICAgICBjb25zdCBpc0V4cGFuZGVkID0gXy5nZXQoZXhwYW5kZWQsIHJvd0luZm8ubmVzdGluZ1BhdGgpXG4gICAgICBjb25zdCB0ckdyb3VwUHJvcHMgPSBnZXRUckdyb3VwUHJvcHMoZmluYWxTdGF0ZSwgcm93SW5mbywgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgY29uc3QgdHJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0VHJQcm9wcyhmaW5hbFN0YXRlLCByb3dJbmZvLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VHJHcm91cENvbXBvbmVudCBrZXk9e3Jvd0luZm8ubmVzdGluZ1BhdGguam9pbignXycpfSB7Li4udHJHcm91cFByb3BzfT5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgICAgdHJQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIHJvdy5fdmlld0luZGV4ICUgMiA/ICctZXZlbicgOiAnLW9kZCdcbiAgICAgICAgICAgICl9XG4gICAgICAgICAgICBzdHlsZT17dHJQcm9wcy5zdHlsZX1cbiAgICAgICAgICAgIHsuLi50clByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcCgoY29sdW1uLCBpMikgPT4ge1xuICAgICAgICAgICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgICAgICAgICBjb25zdCBzaG93ID1cbiAgICAgICAgICAgICAgICB0eXBlb2YgY29sdW1uLnNob3cgPT09ICdmdW5jdGlvbicgPyBjb2x1bW4uc2hvdygpIDogY29sdW1uLnNob3dcbiAgICAgICAgICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgICAgICAgICByZXNpemVkQ29sLnZhbHVlLFxuICAgICAgICAgICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgICAgICAgICAgKVxuICAgICAgICAgICAgICBjb25zdCBtYXhXaWR0aCA9IF8uZ2V0Rmlyc3REZWZpbmVkKFxuICAgICAgICAgICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgICAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICAgICAgICAgIGNvbHVtbi5tYXhXaWR0aFxuICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIGNvbnN0IHRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgICAgICAgICAgZ2V0VGRQcm9wcyhmaW5hbFN0YXRlLCByb3dJbmZvLCBjb2x1bW4sIHRoaXMpXG4gICAgICAgICAgICAgIClcbiAgICAgICAgICAgICAgY29uc3QgY29sdW1uUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgICAgICAgICAgY29sdW1uLmdldFByb3BzKGZpbmFsU3RhdGUsIHJvd0luZm8sIGNvbHVtbiwgdGhpcylcbiAgICAgICAgICAgICAgKVxuXG4gICAgICAgICAgICAgIGNvbnN0IGNsYXNzZXMgPSBbXG4gICAgICAgICAgICAgICAgdGRQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgICAgY29sdW1uLmNsYXNzTmFtZSxcbiAgICAgICAgICAgICAgICBjb2x1bW5Qcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIF1cblxuICAgICAgICAgICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgICAgICAgICAgLi4udGRQcm9wcy5zdHlsZSxcbiAgICAgICAgICAgICAgICAuLi5jb2x1bW4uc3R5bGUsXG4gICAgICAgICAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBjb25zdCBjZWxsSW5mbyA9IHtcbiAgICAgICAgICAgICAgICAuLi5yb3dJbmZvLFxuICAgICAgICAgICAgICAgIGlzRXhwYW5kZWQsXG4gICAgICAgICAgICAgICAgY29sdW1uOiB7IC4uLmNvbHVtbiB9LFxuICAgICAgICAgICAgICAgIHZhbHVlOiByb3dJbmZvLnJvd1tjb2x1bW4uaWRdLFxuICAgICAgICAgICAgICAgIHBpdm90ZWQ6IGNvbHVtbi5waXZvdGVkLFxuICAgICAgICAgICAgICAgIGV4cGFuZGVyOiBjb2x1bW4uZXhwYW5kZXIsXG4gICAgICAgICAgICAgICAgcmVzaXplZCxcbiAgICAgICAgICAgICAgICBzaG93LFxuICAgICAgICAgICAgICAgIHdpZHRoLFxuICAgICAgICAgICAgICAgIG1heFdpZHRoLFxuICAgICAgICAgICAgICAgIHRkUHJvcHMsXG4gICAgICAgICAgICAgICAgY29sdW1uUHJvcHMsXG4gICAgICAgICAgICAgICAgY2xhc3NlcyxcbiAgICAgICAgICAgICAgICBzdHlsZXMsXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBjb25zdCB2YWx1ZSA9IGNlbGxJbmZvLnZhbHVlXG5cbiAgICAgICAgICAgICAgbGV0IHVzZU9uRXhwYW5kZXJDbGlja1xuICAgICAgICAgICAgICBsZXQgaXNCcmFuY2hcbiAgICAgICAgICAgICAgbGV0IGlzUHJldmlld1xuXG4gICAgICAgICAgICAgIGNvbnN0IG9uRXhwYW5kZXJDbGljayA9IGUgPT4ge1xuICAgICAgICAgICAgICAgIGxldCBuZXdFeHBhbmRlZCA9IF8uY2xvbmUoZXhwYW5kZWQpXG4gICAgICAgICAgICAgICAgaWYgKGlzRXhwYW5kZWQpIHtcbiAgICAgICAgICAgICAgICAgIG5ld0V4cGFuZGVkID0gXy5zZXQobmV3RXhwYW5kZWQsIGNlbGxJbmZvLm5lc3RpbmdQYXRoLCBmYWxzZSlcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgbmV3RXhwYW5kZWQgPSBfLnNldChuZXdFeHBhbmRlZCwgY2VsbEluZm8ubmVzdGluZ1BhdGgsIHt9KVxuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLnNldFN0YXRlV2l0aERhdGEoXG4gICAgICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgICAgIGV4cGFuZGVkOiBuZXdFeHBhbmRlZCxcbiAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICAoKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIG9uRXhwYW5kZWRDaGFuZ2UgJiZcbiAgICAgICAgICAgICAgICAgICAgICBvbkV4cGFuZGVkQ2hhbmdlKG5ld0V4cGFuZGVkLCBjZWxsSW5mby5uZXN0aW5nUGF0aCwgZSlcbiAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAvLyBEZWZhdWx0IHRvIGEgc3RhbmRhcmQgY2VsbFxuICAgICAgICAgICAgICBsZXQgcmVzb2x2ZWRDZWxsID0gXy5ub3JtYWxpemVDb21wb25lbnQoXG4gICAgICAgICAgICAgICAgY29sdW1uLkNlbGwsXG4gICAgICAgICAgICAgICAgY2VsbEluZm8sXG4gICAgICAgICAgICAgICAgdmFsdWVcbiAgICAgICAgICAgICAgKVxuXG4gICAgICAgICAgICAgIC8vIFJlc29sdmUgUmVuZGVyZXJzXG4gICAgICAgICAgICAgIGNvbnN0IFJlc29sdmVkQWdncmVnYXRlZENvbXBvbmVudCA9XG4gICAgICAgICAgICAgICAgY29sdW1uLkFnZ3JlZ2F0ZWQgfHxcbiAgICAgICAgICAgICAgICAoIWNvbHVtbi5hZ2dyZWdhdGUgPyBBZ2dyZWdhdGVkQ29tcG9uZW50IDogY29sdW1uLkNlbGwpXG4gICAgICAgICAgICAgIGNvbnN0IFJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIGNvbHVtbi5FeHBhbmRlciB8fCBFeHBhbmRlckNvbXBvbmVudFxuICAgICAgICAgICAgICBjb25zdCBSZXNvbHZlZFBpdm90VmFsdWVDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIGNvbHVtbi5QaXZvdFZhbHVlIHx8IFBpdm90VmFsdWVDb21wb25lbnRcbiAgICAgICAgICAgICAgY29uc3QgRGVmYXVsdFJlc29sdmVkUGl2b3RDb21wb25lbnQgPVxuICAgICAgICAgICAgICAgIFBpdm90Q29tcG9uZW50IHx8XG4gICAgICAgICAgICAgICAgKHByb3BzID0+XG4gICAgICAgICAgICAgICAgICA8ZGl2PlxuICAgICAgICAgICAgICAgICAgICA8UmVzb2x2ZWRFeHBhbmRlckNvbXBvbmVudCB7Li4ucHJvcHN9IC8+XG4gICAgICAgICAgICAgICAgICAgIDxSZXNvbHZlZFBpdm90VmFsdWVDb21wb25lbnQgey4uLnByb3BzfSAvPlxuICAgICAgICAgICAgICAgICAgPC9kaXY+KVxuICAgICAgICAgICAgICBjb25zdCBSZXNvbHZlZFBpdm90Q29tcG9uZW50ID1cbiAgICAgICAgICAgICAgICBjb2x1bW4uUGl2b3QgfHwgRGVmYXVsdFJlc29sdmVkUGl2b3RDb21wb25lbnRcblxuICAgICAgICAgICAgICAvLyBJcyB0aGlzIGNlbGwgZXhwYW5kYWJsZT9cbiAgICAgICAgICAgICAgaWYgKGNlbGxJbmZvLnBpdm90ZWQgfHwgY2VsbEluZm8uZXhwYW5kZXIpIHtcbiAgICAgICAgICAgICAgICAvLyBNYWtlIGl0IGV4cGFuZGFibGUgYnkgZGVmdWFsdFxuICAgICAgICAgICAgICAgIGNlbGxJbmZvLmV4cGFuZGFibGUgPSB0cnVlXG4gICAgICAgICAgICAgICAgdXNlT25FeHBhbmRlckNsaWNrID0gdHJ1ZVxuICAgICAgICAgICAgICAgIC8vIElmIHBpdm90ZWQsIGhhcyBubyBzdWJSb3dzLCBhbmQgZG9lcyBub3QgaGF2ZSBhIHN1YkNvbXBvbmVudCwgZG8gbm90IG1ha2UgZXhwYW5kYWJsZVxuICAgICAgICAgICAgICAgIGlmIChjZWxsSW5mby5waXZvdGVkICYmICFjZWxsSW5mby5zdWJSb3dzICYmICFTdWJDb21wb25lbnQpIHtcbiAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLmV4cGFuZGFibGUgPSBmYWxzZVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgIGlmIChjZWxsSW5mby5waXZvdGVkKSB7XG4gICAgICAgICAgICAgICAgLy8gSXMgdGhpcyBjb2x1bW4gYSBicmFuY2g/XG4gICAgICAgICAgICAgICAgaXNCcmFuY2ggPVxuICAgICAgICAgICAgICAgICAgcm93SW5mby5yb3dbcGl2b3RJREtleV0gPT09IGNvbHVtbi5pZCAmJiBjZWxsSW5mby5zdWJSb3dzXG4gICAgICAgICAgICAgICAgLy8gU2hvdWxkIHRoaXMgY29sdW1uIGJlIGJsYW5rP1xuICAgICAgICAgICAgICAgIGlzUHJldmlldyA9XG4gICAgICAgICAgICAgICAgICBwaXZvdEJ5LmluZGV4T2YoY29sdW1uLmlkKSA+XG4gICAgICAgICAgICAgICAgICAgIHBpdm90QnkuaW5kZXhPZihyb3dJbmZvLnJvd1twaXZvdElES2V5XSkgJiYgY2VsbEluZm8uc3ViUm93c1xuICAgICAgICAgICAgICAgIC8vIFBpdm90IENlbGwgUmVuZGVyIE92ZXJyaWRlXG4gICAgICAgICAgICAgICAgaWYgKGlzQnJhbmNoKSB7XG4gICAgICAgICAgICAgICAgICAvLyBpc1Bpdm90XG4gICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgICAgUmVzb2x2ZWRQaXZvdENvbXBvbmVudCxcbiAgICAgICAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICAgICAgIC4uLmNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgICAgIHZhbHVlOiByb3dbcGl2b3RWYWxLZXldLFxuICAgICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgICAgICByb3dbcGl2b3RWYWxLZXldXG4gICAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChpc1ByZXZpZXcpIHtcbiAgICAgICAgICAgICAgICAgIC8vIFNob3cgdGhlIHBpdm90IHByZXZpZXdcbiAgICAgICAgICAgICAgICAgIHJlc29sdmVkQ2VsbCA9IF8ubm9ybWFsaXplQ29tcG9uZW50KFxuICAgICAgICAgICAgICAgICAgICBSZXNvbHZlZEFnZ3JlZ2F0ZWRDb21wb25lbnQsXG4gICAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgICB2YWx1ZVxuICAgICAgICAgICAgICAgICAgKVxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICB9IGVsc2UgaWYgKGNlbGxJbmZvLmFnZ3JlZ2F0ZWQpIHtcbiAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgIFJlc29sdmVkQWdncmVnYXRlZENvbXBvbmVudCxcbiAgICAgICAgICAgICAgICAgIGNlbGxJbmZvLFxuICAgICAgICAgICAgICAgICAgdmFsdWVcbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBpZiAoY2VsbEluZm8uZXhwYW5kZXIpIHtcbiAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBfLm5vcm1hbGl6ZUNvbXBvbmVudChcbiAgICAgICAgICAgICAgICAgIFJlc29sdmVkRXhwYW5kZXJDb21wb25lbnQsXG4gICAgICAgICAgICAgICAgICBjZWxsSW5mbyxcbiAgICAgICAgICAgICAgICAgIHJvd1twaXZvdFZhbEtleV1cbiAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgICAgaWYgKHBpdm90QnkpIHtcbiAgICAgICAgICAgICAgICAgIGlmIChjZWxsSW5mby5ncm91cGVkQnlQaXZvdCkge1xuICAgICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICBpZiAoIWNlbGxJbmZvLnN1YlJvd3MgJiYgIVN1YkNvbXBvbmVudCkge1xuICAgICAgICAgICAgICAgICAgICByZXNvbHZlZENlbGwgPSBudWxsXG4gICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgY29uc3QgcmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2sgPSB1c2VPbkV4cGFuZGVyQ2xpY2tcbiAgICAgICAgICAgICAgICA/IG9uRXhwYW5kZXJDbGlja1xuICAgICAgICAgICAgICAgIDogKCkgPT4ge31cblxuICAgICAgICAgICAgICAvLyBJZiB0aGVyZSBhcmUgbXVsdGlwbGUgb25DbGljayBldmVudHMsIG1ha2Ugc3VyZSB0aGV5IGRvbid0IG92ZXJyaWRlIGVhY2hvdGhlci4gVGhpcyBzaG91bGQgbWF5YmUgYmUgZXhwYW5kZWQgdG8gaGFuZGxlIGFsbCBmdW5jdGlvbiBhdHRyaWJ1dGVzXG4gICAgICAgICAgICAgIGNvbnN0IGludGVyYWN0aW9uUHJvcHMgPSB7XG4gICAgICAgICAgICAgICAgb25DbGljazogcmVzb2x2ZWRPbkV4cGFuZGVyQ2xpY2ssXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBpZiAodGRQcm9wcy5yZXN0Lm9uQ2xpY2spIHtcbiAgICAgICAgICAgICAgICBpbnRlcmFjdGlvblByb3BzLm9uQ2xpY2sgPSBlID0+IHtcbiAgICAgICAgICAgICAgICAgIHRkUHJvcHMucmVzdC5vbkNsaWNrKGUsICgpID0+IHJlc29sdmVkT25FeHBhbmRlckNsaWNrKGUpKVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgIGlmIChjb2x1bW5Qcm9wcy5yZXN0Lm9uQ2xpY2spIHtcbiAgICAgICAgICAgICAgICBpbnRlcmFjdGlvblByb3BzLm9uQ2xpY2sgPSBlID0+IHtcbiAgICAgICAgICAgICAgICAgIGNvbHVtblByb3BzLnJlc3Qub25DbGljayhlLCAoKSA9PiByZXNvbHZlZE9uRXhwYW5kZXJDbGljayhlKSlcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAvLyBSZXR1cm4gdGhlIGNlbGxcbiAgICAgICAgICAgICAgcmV0dXJuIChcbiAgICAgICAgICAgICAgICA8VGRDb21wb25lbnRcbiAgICAgICAgICAgICAgICAgIGtleT17aTIgKyAnLScgKyBjb2x1bW4uaWR9XG4gICAgICAgICAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoXG4gICAgICAgICAgICAgICAgICAgIGNsYXNzZXMsXG4gICAgICAgICAgICAgICAgICAgICFzaG93ICYmICdoaWRkZW4nLFxuICAgICAgICAgICAgICAgICAgICBjZWxsSW5mby5leHBhbmRhYmxlICYmICdydC1leHBhbmRhYmxlJyxcbiAgICAgICAgICAgICAgICAgICAgKGlzQnJhbmNoIHx8IGlzUHJldmlldykgJiYgJ3J0LXBpdm90J1xuICAgICAgICAgICAgICAgICAgKX1cbiAgICAgICAgICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAgICAgICAgIC4uLnN0eWxlcyxcbiAgICAgICAgICAgICAgICAgICAgZmxleDogYCR7d2lkdGh9IDAgYXV0b2AsXG4gICAgICAgICAgICAgICAgICAgIHdpZHRoOiBfLmFzUHgod2lkdGgpLFxuICAgICAgICAgICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICAgICAgICAgIH19XG4gICAgICAgICAgICAgICAgICB7Li4udGRQcm9wcy5yZXN0fVxuICAgICAgICAgICAgICAgICAgey4uLmNvbHVtblByb3BzLnJlc3R9XG4gICAgICAgICAgICAgICAgICB7Li4uaW50ZXJhY3Rpb25Qcm9wc31cbiAgICAgICAgICAgICAgICA+XG4gICAgICAgICAgICAgICAgICB7cmVzb2x2ZWRDZWxsfVxuICAgICAgICAgICAgICAgIDwvVGRDb21wb25lbnQ+XG4gICAgICAgICAgICAgIClcbiAgICAgICAgICAgIH0pfVxuICAgICAgICAgIDwvVHJDb21wb25lbnQ+XG4gICAgICAgICAge3Jvd0luZm8uc3ViUm93cyAmJlxuICAgICAgICAgICAgaXNFeHBhbmRlZCAmJlxuICAgICAgICAgICAgcm93SW5mby5zdWJSb3dzLm1hcCgoZCwgaSkgPT5cbiAgICAgICAgICAgICAgbWFrZVBhZ2VSb3coZCwgaSwgcm93SW5mby5uZXN0aW5nUGF0aClcbiAgICAgICAgICAgICl9XG4gICAgICAgICAge1N1YkNvbXBvbmVudCAmJlxuICAgICAgICAgICAgIXJvd0luZm8uc3ViUm93cyAmJlxuICAgICAgICAgICAgaXNFeHBhbmRlZCAmJlxuICAgICAgICAgICAgU3ViQ29tcG9uZW50KHJvd0luZm8pfVxuICAgICAgICA8L1RyR3JvdXBDb21wb25lbnQ+XG4gICAgICApXG4gICAgfVxuXG4gICAgY29uc3QgbWFrZVBhZFJvdyA9IChyb3csIGkpID0+IHtcbiAgICAgIGNvbnN0IHRyR3JvdXBQcm9wcyA9IGdldFRyR3JvdXBQcm9wcyhcbiAgICAgICAgZmluYWxTdGF0ZSxcbiAgICAgICAgdW5kZWZpbmVkLFxuICAgICAgICB1bmRlZmluZWQsXG4gICAgICAgIHRoaXNcbiAgICAgIClcbiAgICAgIGNvbnN0IHRyUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VHJHcm91cENvbXBvbmVudCBrZXk9e2l9IHsuLi50ckdyb3VwUHJvcHN9PlxuICAgICAgICAgIDxUckNvbXBvbmVudFxuICAgICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKFxuICAgICAgICAgICAgICAnLXBhZFJvdycsXG4gICAgICAgICAgICAgIChwYWdlUm93cy5sZW5ndGggKyBpKSAlIDIgPyAnLWV2ZW4nIDogJy1vZGQnLFxuICAgICAgICAgICAgICB0clByb3BzLmNsYXNzTmFtZVxuICAgICAgICAgICAgKX1cbiAgICAgICAgICAgIHN0eWxlPXt0clByb3BzLnN0eWxlIHx8IHt9fVxuICAgICAgICAgID5cbiAgICAgICAgICAgIHthbGxWaXNpYmxlQ29sdW1ucy5tYXAobWFrZVBhZENvbHVtbil9XG4gICAgICAgICAgPC9UckNvbXBvbmVudD5cbiAgICAgICAgPC9Uckdyb3VwQ29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VQYWRDb2x1bW4gPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgc2hvdyA9XG4gICAgICAgIHR5cGVvZiBjb2x1bW4uc2hvdyA9PT0gJ2Z1bmN0aW9uJyA/IGNvbHVtbi5zaG93KCkgOiBjb2x1bW4uc2hvd1xuICAgICAgbGV0IHdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1pbldpZHRoXG4gICAgICApXG4gICAgICBsZXQgZmxleCA9IHdpZHRoXG4gICAgICBsZXQgbWF4V2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWF4V2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IHRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRkUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCBjb2x1bW5Qcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgY29sdW1uLmdldFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuXG4gICAgICBjb25zdCBjbGFzc2VzID0gW1xuICAgICAgICB0ZFByb3BzLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uLmNsYXNzTmFtZSxcbiAgICAgICAgY29sdW1uUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgXVxuXG4gICAgICBjb25zdCBzdHlsZXMgPSB7XG4gICAgICAgIC4uLnRkUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbi5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICB9XG5cbiAgICAgIHJldHVybiAoXG4gICAgICAgIDxUZENvbXBvbmVudFxuICAgICAgICAgIGtleT17aSArICctJyArIGNvbHVtbi5pZH1cbiAgICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NlcywgIXNob3cgJiYgJ2hpZGRlbicpfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi5zdHlsZXMsXG4gICAgICAgICAgICBmbGV4OiBgJHtmbGV4fSAwIGF1dG9gLFxuICAgICAgICAgICAgd2lkdGg6IF8uYXNQeCh3aWR0aCksXG4gICAgICAgICAgICBtYXhXaWR0aDogXy5hc1B4KG1heFdpZHRoKSxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50ZFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICB7Xy5ub3JtYWxpemVDb21wb25lbnQoUGFkUm93Q29tcG9uZW50KX1cbiAgICAgICAgPC9UZENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlQ29sdW1uRm9vdGVycyA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHRGb290UHJvcHMgPSBnZXRUZm9vdFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgY29uc3QgdEZvb3RUclByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBnZXRUZm9vdFRyUHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgICApXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGZvb3RDb21wb25lbnRcbiAgICAgICAgICBjbGFzc05hbWU9e3RGb290UHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAuLi50Rm9vdFByb3BzLnN0eWxlLFxuICAgICAgICAgICAgbWluV2lkdGg6IGAke3Jvd01pbldpZHRofXB4YCxcbiAgICAgICAgICB9fVxuICAgICAgICAgIHsuLi50Rm9vdFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICA8VHJDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyh0Rm9vdFRyUHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICAgIHN0eWxlPXt0Rm9vdFRyUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udEZvb3RUclByb3BzLnJlc3R9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge2FsbFZpc2libGVDb2x1bW5zLm1hcChtYWtlQ29sdW1uRm9vdGVyKX1cbiAgICAgICAgICA8L1RyQ29tcG9uZW50PlxuICAgICAgICA8L1Rmb290Q29tcG9uZW50PlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IG1ha2VDb2x1bW5Gb290ZXIgPSAoY29sdW1uLCBpKSA9PiB7XG4gICAgICBjb25zdCByZXNpemVkQ29sID0gcmVzaXplZC5maW5kKHggPT4geC5pZCA9PT0gY29sdW1uLmlkKSB8fCB7fVxuICAgICAgY29uc3Qgc2hvdyA9XG4gICAgICAgIHR5cGVvZiBjb2x1bW4uc2hvdyA9PT0gJ2Z1bmN0aW9uJyA/IGNvbHVtbi5zaG93KCkgOiBjb2x1bW4uc2hvd1xuICAgICAgY29uc3Qgd2lkdGggPSBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgcmVzaXplZENvbC52YWx1ZSxcbiAgICAgICAgY29sdW1uLndpZHRoLFxuICAgICAgICBjb2x1bW4ubWluV2lkdGhcbiAgICAgIClcbiAgICAgIGNvbnN0IG1heFdpZHRoID0gXy5nZXRGaXJzdERlZmluZWQoXG4gICAgICAgIHJlc2l6ZWRDb2wudmFsdWUsXG4gICAgICAgIGNvbHVtbi53aWR0aCxcbiAgICAgICAgY29sdW1uLm1heFdpZHRoXG4gICAgICApXG4gICAgICBjb25zdCB0Rm9vdFRkUHJvcHMgPSBfLnNwbGl0UHJvcHMoXG4gICAgICAgIGdldFRmb290VGRQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICAgIClcbiAgICAgIGNvbnN0IGNvbHVtblByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgICBjb2x1bW4uZ2V0UHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCBjb2x1bW4sIHRoaXMpXG4gICAgICApXG4gICAgICBjb25zdCBjb2x1bW5Gb290ZXJQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgY29sdW1uLmdldEZvb3RlclByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgY29sdW1uLCB0aGlzKVxuICAgICAgKVxuXG4gICAgICBjb25zdCBjbGFzc2VzID0gW1xuICAgICAgICB0Rm9vdFRkUHJvcHMuY2xhc3NOYW1lLFxuICAgICAgICBjb2x1bW4uY2xhc3NOYW1lLFxuICAgICAgICBjb2x1bW5Qcm9wcy5jbGFzc05hbWUsXG4gICAgICAgIGNvbHVtbkZvb3RlclByb3BzLmNsYXNzTmFtZSxcbiAgICAgIF1cblxuICAgICAgY29uc3Qgc3R5bGVzID0ge1xuICAgICAgICAuLi50Rm9vdFRkUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbi5zdHlsZSxcbiAgICAgICAgLi4uY29sdW1uUHJvcHMuc3R5bGUsXG4gICAgICAgIC4uLmNvbHVtbkZvb3RlclByb3BzLnN0eWxlLFxuICAgICAgfVxuXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8VGRDb21wb25lbnRcbiAgICAgICAgICBrZXk9e2kgKyAnLScgKyBjb2x1bW4uaWR9XG4gICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKGNsYXNzZXMsICFzaG93ICYmICdoaWRkZW4nKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4uc3R5bGVzLFxuICAgICAgICAgICAgZmxleDogYCR7d2lkdGh9IDAgYXV0b2AsXG4gICAgICAgICAgICB3aWR0aDogXy5hc1B4KHdpZHRoKSxcbiAgICAgICAgICAgIG1heFdpZHRoOiBfLmFzUHgobWF4V2lkdGgpLFxuICAgICAgICAgIH19XG4gICAgICAgICAgey4uLmNvbHVtblByb3BzLnJlc3R9XG4gICAgICAgICAgey4uLnRGb290VGRQcm9wcy5yZXN0fVxuICAgICAgICAgIHsuLi5jb2x1bW5Gb290ZXJQcm9wcy5yZXN0fVxuICAgICAgICA+XG4gICAgICAgICAge18ubm9ybWFsaXplQ29tcG9uZW50KGNvbHVtbi5Gb290ZXIsIHtcbiAgICAgICAgICAgIGRhdGE6IHNvcnRlZERhdGEsXG4gICAgICAgICAgICBjb2x1bW46IGNvbHVtbixcbiAgICAgICAgICB9KX1cbiAgICAgICAgPC9UZENvbXBvbmVudD5cbiAgICAgIClcbiAgICB9XG5cbiAgICBjb25zdCBtYWtlUGFnaW5hdGlvbiA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHBhZ2luYXRpb25Qcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgICAgZ2V0UGFnaW5hdGlvblByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgICAgKVxuICAgICAgcmV0dXJuIChcbiAgICAgICAgPFBhZ2luYXRpb25Db21wb25lbnRcbiAgICAgICAgICB7Li4ucmVzb2x2ZWRTdGF0ZX1cbiAgICAgICAgICBwYWdlcz17cGFnZXN9XG4gICAgICAgICAgY2FuUHJldmlvdXM9e2NhblByZXZpb3VzfVxuICAgICAgICAgIGNhbk5leHQ9e2Nhbk5leHR9XG4gICAgICAgICAgb25QYWdlQ2hhbmdlPXt0aGlzLm9uUGFnZUNoYW5nZX1cbiAgICAgICAgICBvblBhZ2VTaXplQ2hhbmdlPXt0aGlzLm9uUGFnZVNpemVDaGFuZ2V9XG4gICAgICAgICAgY2xhc3NOYW1lPXtwYWdpbmF0aW9uUHJvcHMuY2xhc3NOYW1lfVxuICAgICAgICAgIHN0eWxlPXtwYWdpbmF0aW9uUHJvcHMuc3R5bGV9XG4gICAgICAgICAgey4uLnBhZ2luYXRpb25Qcm9wcy5yZXN0fVxuICAgICAgICAvPlxuICAgICAgKVxuICAgIH1cblxuICAgIGNvbnN0IHJvb3RQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgIGdldFByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgIClcbiAgICBjb25zdCB0YWJsZVByb3BzID0gXy5zcGxpdFByb3BzKFxuICAgICAgZ2V0VGFibGVQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICApXG4gICAgY29uc3QgdEJvZHlQcm9wcyA9IF8uc3BsaXRQcm9wcyhcbiAgICAgIGdldFRib2R5UHJvcHMoZmluYWxTdGF0ZSwgdW5kZWZpbmVkLCB1bmRlZmluZWQsIHRoaXMpXG4gICAgKVxuICAgIGNvbnN0IGxvYWRpbmdQcm9wcyA9IGdldExvYWRpbmdQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcbiAgICBjb25zdCBub0RhdGFQcm9wcyA9IGdldE5vRGF0YVByb3BzKGZpbmFsU3RhdGUsIHVuZGVmaW5lZCwgdW5kZWZpbmVkLCB0aGlzKVxuICAgIGNvbnN0IHJlc2l6ZXJQcm9wcyA9IGdldFJlc2l6ZXJQcm9wcyhmaW5hbFN0YXRlLCB1bmRlZmluZWQsIHVuZGVmaW5lZCwgdGhpcylcblxuICAgIGNvbnN0IG1ha2VUYWJsZSA9ICgpID0+IHtcbiAgICAgIGNvbnN0IHBhZ2luYXRpb24gPSBtYWtlUGFnaW5hdGlvbigpXG4gICAgICByZXR1cm4gKFxuICAgICAgICA8ZGl2XG4gICAgICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCdSZWFjdFRhYmxlJywgY2xhc3NOYW1lLCByb290UHJvcHMuY2xhc3NOYW1lKX1cbiAgICAgICAgICBzdHlsZT17e1xuICAgICAgICAgICAgLi4uc3R5bGUsXG4gICAgICAgICAgICAuLi5yb290UHJvcHMuc3R5bGUsXG4gICAgICAgICAgfX1cbiAgICAgICAgICB7Li4ucm9vdFByb3BzLnJlc3R9XG4gICAgICAgID5cbiAgICAgICAgICB7c2hvd1BhZ2luYXRpb24gJiYgc2hvd1BhZ2luYXRpb25Ub3BcbiAgICAgICAgICAgID8gPGRpdiBjbGFzc05hbWU9J3BhZ2luYXRpb24tdG9wJz5cbiAgICAgICAgICAgICAge3BhZ2luYXRpb259XG4gICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgICA8VGFibGVDb21wb25lbnRcbiAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyhcbiAgICAgICAgICAgICAgdGFibGVQcm9wcy5jbGFzc05hbWUsXG4gICAgICAgICAgICAgIGN1cnJlbnRseVJlc2l6aW5nID8gJ3J0LXJlc2l6aW5nJyA6ICcnXG4gICAgICAgICAgICApfVxuICAgICAgICAgICAgc3R5bGU9e3RhYmxlUHJvcHMuc3R5bGV9XG4gICAgICAgICAgICB7Li4udGFibGVQcm9wcy5yZXN0fVxuICAgICAgICAgID5cbiAgICAgICAgICAgIHtoYXNIZWFkZXJHcm91cHMgPyBtYWtlSGVhZGVyR3JvdXBzKCkgOiBudWxsfVxuICAgICAgICAgICAge21ha2VIZWFkZXJzKCl9XG4gICAgICAgICAgICB7aGFzRmlsdGVycyA/IG1ha2VGaWx0ZXJzKCkgOiBudWxsfVxuICAgICAgICAgICAgPFRib2R5Q29tcG9uZW50XG4gICAgICAgICAgICAgIGNsYXNzTmFtZT17Y2xhc3NuYW1lcyh0Qm9keVByb3BzLmNsYXNzTmFtZSl9XG4gICAgICAgICAgICAgIHN0eWxlPXt7XG4gICAgICAgICAgICAgICAgLi4udEJvZHlQcm9wcy5zdHlsZSxcbiAgICAgICAgICAgICAgICBtaW5XaWR0aDogYCR7cm93TWluV2lkdGh9cHhgLFxuICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICB7Li4udEJvZHlQcm9wcy5yZXN0fVxuICAgICAgICAgICAgPlxuICAgICAgICAgICAgICB7cGFnZVJvd3MubWFwKChkLCBpKSA9PiBtYWtlUGFnZVJvdyhkLCBpKSl9XG4gICAgICAgICAgICAgIHtwYWRSb3dzLm1hcChtYWtlUGFkUm93KX1cbiAgICAgICAgICAgIDwvVGJvZHlDb21wb25lbnQ+XG4gICAgICAgICAgICB7aGFzQ29sdW1uRm9vdGVyID8gbWFrZUNvbHVtbkZvb3RlcnMoKSA6IG51bGx9XG4gICAgICAgICAgPC9UYWJsZUNvbXBvbmVudD5cbiAgICAgICAgICB7c2hvd1BhZ2luYXRpb24gJiYgc2hvd1BhZ2luYXRpb25Cb3R0b21cbiAgICAgICAgICAgID8gPGRpdiBjbGFzc05hbWU9J3BhZ2luYXRpb24tYm90dG9tJz5cbiAgICAgICAgICAgICAge3BhZ2luYXRpb259XG4gICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgIDogbnVsbH1cbiAgICAgICAgICB7IXBhZ2VSb3dzLmxlbmd0aCAmJlxuICAgICAgICAgICAgPE5vRGF0YUNvbXBvbmVudCB7Li4ubm9EYXRhUHJvcHN9PlxuICAgICAgICAgICAgICB7Xy5ub3JtYWxpemVDb21wb25lbnQobm9EYXRhVGV4dCl9XG4gICAgICAgICAgICA8L05vRGF0YUNvbXBvbmVudD59XG4gICAgICAgICAgPExvYWRpbmdDb21wb25lbnRcbiAgICAgICAgICAgIGxvYWRpbmc9e2xvYWRpbmd9XG4gICAgICAgICAgICBsb2FkaW5nVGV4dD17bG9hZGluZ1RleHR9XG4gICAgICAgICAgICB7Li4ubG9hZGluZ1Byb3BzfVxuICAgICAgICAgIC8+XG4gICAgICAgIDwvZGl2PlxuICAgICAgKVxuICAgIH1cblxuICAgIC8vIGNoaWxkUHJvcHMgYXJlIG9wdGlvbmFsbHkgcGFzc2VkIHRvIGEgZnVuY3Rpb24tYXMtYS1jaGlsZFxuICAgIHJldHVybiBjaGlsZHJlbiA/IGNoaWxkcmVuKGZpbmFsU3RhdGUsIG1ha2VUYWJsZSwgdGhpcykgOiBtYWtlVGFibGUoKVxuICB9XG59XG4iXX0= /***/ }), -/* 408 */ +/* 359 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var utils = __webpack_require__(46); +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -/** - * Parse headers into an object - * - * ``` - * Date: Wed, 27 Aug 2014 08:58:49 GMT - * Content-Type: application/json - * Connection: keep-alive - * Transfer-Encoding: chunked - * ``` - * - * @param {String} headers Headers needing to be parsed - * @returns {Object} Headers parsed into an object - */ -module.exports = function parseHeaders(headers) { - var parsed = {}; - var key; - var val; - var i; +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - if (!headers) { return parsed; } +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } - utils.forEach(headers.split('\n'), function parser(line) { - i = line.indexOf(':'); - key = utils.trim(line.substr(0, i)).toLowerCase(); - val = utils.trim(line.substr(i + 1)); +exports.default = function (Base) { + return function (_Base) { + _inherits(_class, _Base); - if (key) { - parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val; + function _class() { + _classCallCheck(this, _class); + + return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments)); } - }); - return parsed; -}; + _createClass(_class, [{ + key: 'componentWillMount', + value: function componentWillMount() { + this.setStateWithData(this.getDataModel(this.getResolvedState())); + } + }, { + key: 'componentDidMount', + value: function componentDidMount() { + this.fireFetchData(); + } + }, { + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps, nextState) { + var oldState = this.getResolvedState(); + var newState = this.getResolvedState(nextProps, nextState); + + // Do a deep compare of new and old `defaultOption` and + // if they are different reset `option = defaultOption` + var defaultableOptions = ['sorted', 'filtered', 'resized', 'expanded']; + defaultableOptions.forEach(function (x) { + var defaultName = 'default' + (x.charAt(0).toUpperCase() + x.slice(1)); + if (JSON.stringify(oldState[defaultName]) !== JSON.stringify(newState[defaultName])) { + newState[x] = newState[defaultName]; + } + }); + // If they change these table options, we need to reset defaults + // or else we could get into a state where the user has changed the UI + // and then disabled the ability to change it back. + // e.g. If `filterable` has changed, set `filtered = defaultFiltered` + var resettableOptions = ['sortable', 'filterable', 'resizable']; + resettableOptions.forEach(function (x) { + if (oldState[x] !== newState[x]) { + var baseName = x.replace('able', ''); + var optionName = baseName + 'ed'; + var defaultName = 'default' + (optionName.charAt(0).toUpperCase() + optionName.slice(1)); + newState[optionName] = newState[defaultName]; + } + }); -/***/ }), -/* 409 */ -/***/ (function(module, exports, __webpack_require__) { + // Props that trigger a data update + if (oldState.data !== newState.data || oldState.columns !== newState.columns || oldState.pivotBy !== newState.pivotBy || oldState.sorted !== newState.sorted || oldState.filtered !== newState.filtered) { + this.setStateWithData(this.getDataModel(newState)); + } + } + }, { + key: 'setStateWithData', + value: function setStateWithData(newState, cb) { + var _this2 = this; -"use strict"; + var oldState = this.getResolvedState(); + var newResolvedState = this.getResolvedState({}, newState); + var freezeWhenExpanded = newResolvedState.freezeWhenExpanded; + // Default to unfrozen state -var utils = __webpack_require__(46); + newResolvedState.frozen = false; -module.exports = ( - utils.isStandardBrowserEnv() ? + // If freezeWhenExpanded is set, check for frozen conditions + if (freezeWhenExpanded) { + // if any rows are expanded, freeze the existing data and sorting + var keys = Object.keys(newResolvedState.expanded); + for (var i = 0; i < keys.length; i++) { + if (newResolvedState.expanded[keys[i]]) { + newResolvedState.frozen = true; + break; + } + } + } - // Standard browser envs have full support of the APIs needed to test - // whether the request URL is of the same origin as current location. - (function standardBrowserEnv() { - var msie = /(msie|trident)/i.test(navigator.userAgent); - var urlParsingNode = document.createElement('a'); - var originURL; + // If the data isn't frozen and either the data or + // sorting model has changed, update the data + if (oldState.frozen && !newResolvedState.frozen || oldState.sorted !== newResolvedState.sorted || oldState.filtered !== newResolvedState.filtered || oldState.showFilters !== newResolvedState.showFilters || !newResolvedState.frozen && oldState.resolvedData !== newResolvedState.resolvedData) { + // Handle collapseOnsortedChange & collapseOnDataChange + if (oldState.sorted !== newResolvedState.sorted && this.props.collapseOnSortingChange || oldState.filtered !== newResolvedState.filtered || oldState.showFilters !== newResolvedState.showFilters || oldState.sortedData && !newResolvedState.frozen && oldState.resolvedData !== newResolvedState.resolvedData && this.props.collapseOnDataChange) { + newResolvedState.expanded = {}; + } - /** - * Parse a URL to discover it's components - * - * @param {String} url The URL to be parsed - * @returns {Object} - */ - function resolveURL(url) { - var href = url; + Object.assign(newResolvedState, this.getSortedData(newResolvedState)); + } - if (msie) { - // IE needs attribute set twice to normalize properties - urlParsingNode.setAttribute('href', href); - href = urlParsingNode.href; + // Set page to 0 if filters change + if (oldState.filtered !== newResolvedState.filtered) { + newResolvedState.page = 0; + } + + // Calculate pageSize all the time + if (newResolvedState.sortedData) { + newResolvedState.pages = newResolvedState.manual ? newResolvedState.pages : Math.ceil(newResolvedState.sortedData.length / newResolvedState.pageSize); + newResolvedState.page = Math.max(newResolvedState.page >= newResolvedState.pages ? newResolvedState.pages - 1 : newResolvedState.page, 0); + } + + return this.setState(newResolvedState, function () { + cb && cb(); + if (oldState.page !== newResolvedState.page || oldState.pageSize !== newResolvedState.pageSize || oldState.sorted !== newResolvedState.sorted || oldState.filtered !== newResolvedState.filtered) { + _this2.fireFetchData(); + } + }); } + }]); - urlParsingNode.setAttribute('href', href); + return _class; + }(Base); +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9saWZlY3ljbGUuanMiXSwibmFtZXMiOlsic2V0U3RhdGVXaXRoRGF0YSIsImdldERhdGFNb2RlbCIsImdldFJlc29sdmVkU3RhdGUiLCJmaXJlRmV0Y2hEYXRhIiwibmV4dFByb3BzIiwibmV4dFN0YXRlIiwib2xkU3RhdGUiLCJuZXdTdGF0ZSIsImRlZmF1bHRhYmxlT3B0aW9ucyIsImZvckVhY2giLCJkZWZhdWx0TmFtZSIsIngiLCJjaGFyQXQiLCJ0b1VwcGVyQ2FzZSIsInNsaWNlIiwiSlNPTiIsInN0cmluZ2lmeSIsInJlc2V0dGFibGVPcHRpb25zIiwiYmFzZU5hbWUiLCJyZXBsYWNlIiwib3B0aW9uTmFtZSIsImRhdGEiLCJjb2x1bW5zIiwicGl2b3RCeSIsInNvcnRlZCIsImZpbHRlcmVkIiwiY2IiLCJuZXdSZXNvbHZlZFN0YXRlIiwiZnJlZXplV2hlbkV4cGFuZGVkIiwiZnJvemVuIiwia2V5cyIsIk9iamVjdCIsImV4cGFuZGVkIiwiaSIsImxlbmd0aCIsInNob3dGaWx0ZXJzIiwicmVzb2x2ZWREYXRhIiwicHJvcHMiLCJjb2xsYXBzZU9uU29ydGluZ0NoYW5nZSIsInNvcnRlZERhdGEiLCJjb2xsYXBzZU9uRGF0YUNoYW5nZSIsImFzc2lnbiIsImdldFNvcnRlZERhdGEiLCJwYWdlIiwicGFnZXMiLCJtYW51YWwiLCJNYXRoIiwiY2VpbCIsInBhZ2VTaXplIiwibWF4Iiwic2V0U3RhdGUiLCJCYXNlIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7OztrQkFBZTtBQUFBO0FBQUE7O0FBQUE7QUFBQTs7QUFBQTtBQUFBOztBQUFBO0FBQUE7QUFBQSwyQ0FFVztBQUNwQixhQUFLQSxnQkFBTCxDQUFzQixLQUFLQyxZQUFMLENBQWtCLEtBQUtDLGdCQUFMLEVBQWxCLENBQXRCO0FBQ0Q7QUFKVTtBQUFBO0FBQUEsMENBTVU7QUFDbkIsYUFBS0MsYUFBTDtBQUNEO0FBUlU7QUFBQTtBQUFBLGdEQVVnQkMsU0FWaEIsRUFVMkJDLFNBVjNCLEVBVXNDO0FBQy9DLFlBQU1DLFdBQVcsS0FBS0osZ0JBQUwsRUFBakI7QUFDQSxZQUFNSyxXQUFXLEtBQUtMLGdCQUFMLENBQXNCRSxTQUF0QixFQUFpQ0MsU0FBakMsQ0FBakI7O0FBRUE7QUFDQTtBQUNBLFlBQU1HLHFCQUFxQixDQUFDLFFBQUQsRUFBVyxVQUFYLEVBQXVCLFNBQXZCLEVBQWtDLFVBQWxDLENBQTNCO0FBQ0FBLDJCQUFtQkMsT0FBbkIsQ0FBMkIsYUFBSztBQUM5QixjQUFNQywyQkFBd0JDLEVBQUVDLE1BQUYsQ0FBUyxDQUFULEVBQVlDLFdBQVosS0FBNEJGLEVBQUVHLEtBQUYsQ0FBUSxDQUFSLENBQXBELENBQU47QUFDQSxjQUNFQyxLQUFLQyxTQUFMLENBQWVWLFNBQVNJLFdBQVQsQ0FBZixNQUNBSyxLQUFLQyxTQUFMLENBQWVULFNBQVNHLFdBQVQsQ0FBZixDQUZGLEVBR0U7QUFDQUgscUJBQVNJLENBQVQsSUFBY0osU0FBU0csV0FBVCxDQUFkO0FBQ0Q7QUFDRixTQVJEOztBQVVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsWUFBTU8sb0JBQW9CLENBQUMsVUFBRCxFQUFhLFlBQWIsRUFBMkIsV0FBM0IsQ0FBMUI7QUFDQUEsMEJBQWtCUixPQUFsQixDQUEwQixhQUFLO0FBQzdCLGNBQUlILFNBQVNLLENBQVQsTUFBZ0JKLFNBQVNJLENBQVQsQ0FBcEIsRUFBaUM7QUFDL0IsZ0JBQU1PLFdBQVdQLEVBQUVRLE9BQUYsQ0FBVSxNQUFWLEVBQWtCLEVBQWxCLENBQWpCO0FBQ0EsZ0JBQU1DLGFBQWdCRixRQUFoQixPQUFOO0FBQ0EsZ0JBQU1SLDJCQUF3QlUsV0FBV1IsTUFBWCxDQUFrQixDQUFsQixFQUFxQkMsV0FBckIsS0FDNUJPLFdBQVdOLEtBQVgsQ0FBaUIsQ0FBakIsQ0FESSxDQUFOO0FBRUFQLHFCQUFTYSxVQUFULElBQXVCYixTQUFTRyxXQUFULENBQXZCO0FBQ0Q7QUFDRixTQVJEOztBQVVBO0FBQ0EsWUFDRUosU0FBU2UsSUFBVCxLQUFrQmQsU0FBU2MsSUFBM0IsSUFDQWYsU0FBU2dCLE9BQVQsS0FBcUJmLFNBQVNlLE9BRDlCLElBRUFoQixTQUFTaUIsT0FBVCxLQUFxQmhCLFNBQVNnQixPQUY5QixJQUdBakIsU0FBU2tCLE1BQVQsS0FBb0JqQixTQUFTaUIsTUFIN0IsSUFJQWxCLFNBQVNtQixRQUFULEtBQXNCbEIsU0FBU2tCLFFBTGpDLEVBTUU7QUFDQSxlQUFLekIsZ0JBQUwsQ0FBc0IsS0FBS0MsWUFBTCxDQUFrQk0sUUFBbEIsQ0FBdEI7QUFDRDtBQUNGO0FBcERVO0FBQUE7QUFBQSx1Q0FzRE9BLFFBdERQLEVBc0RpQm1CLEVBdERqQixFQXNEcUI7QUFBQTs7QUFDOUIsWUFBTXBCLFdBQVcsS0FBS0osZ0JBQUwsRUFBakI7QUFDQSxZQUFNeUIsbUJBQW1CLEtBQUt6QixnQkFBTCxDQUFzQixFQUF0QixFQUEwQkssUUFBMUIsQ0FBekI7QUFGOEIsWUFHdEJxQixrQkFIc0IsR0FHQ0QsZ0JBSEQsQ0FHdEJDLGtCQUhzQjs7QUFLOUI7O0FBQ0FELHlCQUFpQkUsTUFBakIsR0FBMEIsS0FBMUI7O0FBRUE7QUFDQSxZQUFJRCxrQkFBSixFQUF3QjtBQUN0QjtBQUNBLGNBQU1FLE9BQU9DLE9BQU9ELElBQVAsQ0FBWUgsaUJBQWlCSyxRQUE3QixDQUFiO0FBQ0EsZUFBSyxJQUFJQyxJQUFJLENBQWIsRUFBZ0JBLElBQUlILEtBQUtJLE1BQXpCLEVBQWlDRCxHQUFqQyxFQUFzQztBQUNwQyxnQkFBSU4saUJBQWlCSyxRQUFqQixDQUEwQkYsS0FBS0csQ0FBTCxDQUExQixDQUFKLEVBQXdDO0FBQ3RDTiwrQkFBaUJFLE1BQWpCLEdBQTBCLElBQTFCO0FBQ0E7QUFDRDtBQUNGO0FBQ0Y7O0FBRUQ7QUFDQTtBQUNBLFlBQ0d2QixTQUFTdUIsTUFBVCxJQUFtQixDQUFDRixpQkFBaUJFLE1BQXRDLElBQ0F2QixTQUFTa0IsTUFBVCxLQUFvQkcsaUJBQWlCSCxNQURyQyxJQUVBbEIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFGdkMsSUFHQW5CLFNBQVM2QixXQUFULEtBQXlCUixpQkFBaUJRLFdBSDFDLElBSUMsQ0FBQ1IsaUJBQWlCRSxNQUFsQixJQUNDdkIsU0FBUzhCLFlBQVQsS0FBMEJULGlCQUFpQlMsWUFOL0MsRUFPRTtBQUNBO0FBQ0EsY0FDRzlCLFNBQVNrQixNQUFULEtBQW9CRyxpQkFBaUJILE1BQXJDLElBQ0MsS0FBS2EsS0FBTCxDQUFXQyx1QkFEYixJQUVBaEMsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFGdkMsSUFHQW5CLFNBQVM2QixXQUFULEtBQXlCUixpQkFBaUJRLFdBSDFDLElBSUM3QixTQUFTaUMsVUFBVCxJQUNDLENBQUNaLGlCQUFpQkUsTUFEbkIsSUFFQ3ZCLFNBQVM4QixZQUFULEtBQTBCVCxpQkFBaUJTLFlBRjVDLElBR0MsS0FBS0MsS0FBTCxDQUFXRyxvQkFSZixFQVNFO0FBQ0FiLDZCQUFpQkssUUFBakIsR0FBNEIsRUFBNUI7QUFDRDs7QUFFREQsaUJBQU9VLE1BQVAsQ0FBY2QsZ0JBQWQsRUFBZ0MsS0FBS2UsYUFBTCxDQUFtQmYsZ0JBQW5CLENBQWhDO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJckIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFBM0MsRUFBcUQ7QUFDbkRFLDJCQUFpQmdCLElBQWpCLEdBQXdCLENBQXhCO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJaEIsaUJBQWlCWSxVQUFyQixFQUFpQztBQUMvQlosMkJBQWlCaUIsS0FBakIsR0FBeUJqQixpQkFBaUJrQixNQUFqQixHQUNyQmxCLGlCQUFpQmlCLEtBREksR0FFckJFLEtBQUtDLElBQUwsQ0FDQXBCLGlCQUFpQlksVUFBakIsQ0FBNEJMLE1BQTVCLEdBQXFDUCxpQkFBaUJxQixRQUR0RCxDQUZKO0FBS0FyQiwyQkFBaUJnQixJQUFqQixHQUF3QkcsS0FBS0csR0FBTCxDQUN0QnRCLGlCQUFpQmdCLElBQWpCLElBQXlCaEIsaUJBQWlCaUIsS0FBMUMsR0FDSWpCLGlCQUFpQmlCLEtBQWpCLEdBQXlCLENBRDdCLEdBRUlqQixpQkFBaUJnQixJQUhDLEVBSXRCLENBSnNCLENBQXhCO0FBTUQ7O0FBRUQsZUFBTyxLQUFLTyxRQUFMLENBQWN2QixnQkFBZCxFQUFnQyxZQUFNO0FBQzNDRCxnQkFBTUEsSUFBTjtBQUNBLGNBQ0VwQixTQUFTcUMsSUFBVCxLQUFrQmhCLGlCQUFpQmdCLElBQW5DLElBQ0FyQyxTQUFTMEMsUUFBVCxLQUFzQnJCLGlCQUFpQnFCLFFBRHZDLElBRUExQyxTQUFTa0IsTUFBVCxLQUFvQkcsaUJBQWlCSCxNQUZyQyxJQUdBbEIsU0FBU21CLFFBQVQsS0FBc0JFLGlCQUFpQkYsUUFKekMsRUFLRTtBQUNBLG1CQUFLdEIsYUFBTDtBQUNEO0FBQ0YsU0FWTSxDQUFQO0FBV0Q7QUFwSVU7O0FBQUE7QUFBQSxJQUNDZ0QsSUFERDtBQUFBLEMiLCJmaWxlIjoibGlmZWN5Y2xlLmpzIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0IGRlZmF1bHQgQmFzZSA9PlxuICBjbGFzcyBleHRlbmRzIEJhc2Uge1xuICAgIGNvbXBvbmVudFdpbGxNb3VudCAoKSB7XG4gICAgICB0aGlzLnNldFN0YXRlV2l0aERhdGEodGhpcy5nZXREYXRhTW9kZWwodGhpcy5nZXRSZXNvbHZlZFN0YXRlKCkpKVxuICAgIH1cblxuICAgIGNvbXBvbmVudERpZE1vdW50ICgpIHtcbiAgICAgIHRoaXMuZmlyZUZldGNoRGF0YSgpXG4gICAgfVxuXG4gICAgY29tcG9uZW50V2lsbFJlY2VpdmVQcm9wcyAobmV4dFByb3BzLCBuZXh0U3RhdGUpIHtcbiAgICAgIGNvbnN0IG9sZFN0YXRlID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKClcbiAgICAgIGNvbnN0IG5ld1N0YXRlID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKG5leHRQcm9wcywgbmV4dFN0YXRlKVxuXG4gICAgICAvLyBEbyBhIGRlZXAgY29tcGFyZSBvZiBuZXcgYW5kIG9sZCBgZGVmYXVsdE9wdGlvbmAgYW5kXG4gICAgICAvLyBpZiB0aGV5IGFyZSBkaWZmZXJlbnQgcmVzZXQgYG9wdGlvbiA9IGRlZmF1bHRPcHRpb25gXG4gICAgICBjb25zdCBkZWZhdWx0YWJsZU9wdGlvbnMgPSBbJ3NvcnRlZCcsICdmaWx0ZXJlZCcsICdyZXNpemVkJywgJ2V4cGFuZGVkJ11cbiAgICAgIGRlZmF1bHRhYmxlT3B0aW9ucy5mb3JFYWNoKHggPT4ge1xuICAgICAgICBjb25zdCBkZWZhdWx0TmFtZSA9IGBkZWZhdWx0JHt4LmNoYXJBdCgwKS50b1VwcGVyQ2FzZSgpICsgeC5zbGljZSgxKX1gXG4gICAgICAgIGlmIChcbiAgICAgICAgICBKU09OLnN0cmluZ2lmeShvbGRTdGF0ZVtkZWZhdWx0TmFtZV0pICE9PVxuICAgICAgICAgIEpTT04uc3RyaW5naWZ5KG5ld1N0YXRlW2RlZmF1bHROYW1lXSlcbiAgICAgICAgKSB7XG4gICAgICAgICAgbmV3U3RhdGVbeF0gPSBuZXdTdGF0ZVtkZWZhdWx0TmFtZV1cbiAgICAgICAgfVxuICAgICAgfSlcblxuICAgICAgLy8gSWYgdGhleSBjaGFuZ2UgdGhlc2UgdGFibGUgb3B0aW9ucywgd2UgbmVlZCB0byByZXNldCBkZWZhdWx0c1xuICAgICAgLy8gb3IgZWxzZSB3ZSBjb3VsZCBnZXQgaW50byBhIHN0YXRlIHdoZXJlIHRoZSB1c2VyIGhhcyBjaGFuZ2VkIHRoZSBVSVxuICAgICAgLy8gYW5kIHRoZW4gZGlzYWJsZWQgdGhlIGFiaWxpdHkgdG8gY2hhbmdlIGl0IGJhY2suXG4gICAgICAvLyBlLmcuIElmIGBmaWx0ZXJhYmxlYCBoYXMgY2hhbmdlZCwgc2V0IGBmaWx0ZXJlZCA9IGRlZmF1bHRGaWx0ZXJlZGBcbiAgICAgIGNvbnN0IHJlc2V0dGFibGVPcHRpb25zID0gWydzb3J0YWJsZScsICdmaWx0ZXJhYmxlJywgJ3Jlc2l6YWJsZSddXG4gICAgICByZXNldHRhYmxlT3B0aW9ucy5mb3JFYWNoKHggPT4ge1xuICAgICAgICBpZiAob2xkU3RhdGVbeF0gIT09IG5ld1N0YXRlW3hdKSB7XG4gICAgICAgICAgY29uc3QgYmFzZU5hbWUgPSB4LnJlcGxhY2UoJ2FibGUnLCAnJylcbiAgICAgICAgICBjb25zdCBvcHRpb25OYW1lID0gYCR7YmFzZU5hbWV9ZWRgXG4gICAgICAgICAgY29uc3QgZGVmYXVsdE5hbWUgPSBgZGVmYXVsdCR7b3B0aW9uTmFtZS5jaGFyQXQoMCkudG9VcHBlckNhc2UoKSArXG4gICAgICAgICAgICBvcHRpb25OYW1lLnNsaWNlKDEpfWBcbiAgICAgICAgICBuZXdTdGF0ZVtvcHRpb25OYW1lXSA9IG5ld1N0YXRlW2RlZmF1bHROYW1lXVxuICAgICAgICB9XG4gICAgICB9KVxuXG4gICAgICAvLyBQcm9wcyB0aGF0IHRyaWdnZXIgYSBkYXRhIHVwZGF0ZVxuICAgICAgaWYgKFxuICAgICAgICBvbGRTdGF0ZS5kYXRhICE9PSBuZXdTdGF0ZS5kYXRhIHx8XG4gICAgICAgIG9sZFN0YXRlLmNvbHVtbnMgIT09IG5ld1N0YXRlLmNvbHVtbnMgfHxcbiAgICAgICAgb2xkU3RhdGUucGl2b3RCeSAhPT0gbmV3U3RhdGUucGl2b3RCeSB8fFxuICAgICAgICBvbGRTdGF0ZS5zb3J0ZWQgIT09IG5ld1N0YXRlLnNvcnRlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3U3RhdGUuZmlsdGVyZWRcbiAgICAgICkge1xuICAgICAgICB0aGlzLnNldFN0YXRlV2l0aERhdGEodGhpcy5nZXREYXRhTW9kZWwobmV3U3RhdGUpKVxuICAgICAgfVxuICAgIH1cblxuICAgIHNldFN0YXRlV2l0aERhdGEgKG5ld1N0YXRlLCBjYikge1xuICAgICAgY29uc3Qgb2xkU3RhdGUgPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuICAgICAgY29uc3QgbmV3UmVzb2x2ZWRTdGF0ZSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSh7fSwgbmV3U3RhdGUpXG4gICAgICBjb25zdCB7IGZyZWV6ZVdoZW5FeHBhbmRlZCB9ID0gbmV3UmVzb2x2ZWRTdGF0ZVxuXG4gICAgICAvLyBEZWZhdWx0IHRvIHVuZnJvemVuIHN0YXRlXG4gICAgICBuZXdSZXNvbHZlZFN0YXRlLmZyb3plbiA9IGZhbHNlXG5cbiAgICAgIC8vIElmIGZyZWV6ZVdoZW5FeHBhbmRlZCBpcyBzZXQsIGNoZWNrIGZvciBmcm96ZW4gY29uZGl0aW9uc1xuICAgICAgaWYgKGZyZWV6ZVdoZW5FeHBhbmRlZCkge1xuICAgICAgICAvLyBpZiBhbnkgcm93cyBhcmUgZXhwYW5kZWQsIGZyZWV6ZSB0aGUgZXhpc3RpbmcgZGF0YSBhbmQgc29ydGluZ1xuICAgICAgICBjb25zdCBrZXlzID0gT2JqZWN0LmtleXMobmV3UmVzb2x2ZWRTdGF0ZS5leHBhbmRlZClcbiAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBrZXlzLmxlbmd0aDsgaSsrKSB7XG4gICAgICAgICAgaWYgKG5ld1Jlc29sdmVkU3RhdGUuZXhwYW5kZWRba2V5c1tpXV0pIHtcbiAgICAgICAgICAgIG5ld1Jlc29sdmVkU3RhdGUuZnJvemVuID0gdHJ1ZVxuICAgICAgICAgICAgYnJlYWtcbiAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICAgIH1cblxuICAgICAgLy8gSWYgdGhlIGRhdGEgaXNuJ3QgZnJvemVuIGFuZCBlaXRoZXIgdGhlIGRhdGEgb3JcbiAgICAgIC8vIHNvcnRpbmcgbW9kZWwgaGFzIGNoYW5nZWQsIHVwZGF0ZSB0aGUgZGF0YVxuICAgICAgaWYgKFxuICAgICAgICAob2xkU3RhdGUuZnJvemVuICYmICFuZXdSZXNvbHZlZFN0YXRlLmZyb3plbikgfHxcbiAgICAgICAgb2xkU3RhdGUuc29ydGVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNvcnRlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5maWx0ZXJlZCB8fFxuICAgICAgICBvbGRTdGF0ZS5zaG93RmlsdGVycyAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5zaG93RmlsdGVycyB8fFxuICAgICAgICAoIW5ld1Jlc29sdmVkU3RhdGUuZnJvemVuICYmXG4gICAgICAgICAgb2xkU3RhdGUucmVzb2x2ZWREYXRhICE9PSBuZXdSZXNvbHZlZFN0YXRlLnJlc29sdmVkRGF0YSlcbiAgICAgICkge1xuICAgICAgICAvLyBIYW5kbGUgY29sbGFwc2VPbnNvcnRlZENoYW5nZSAmIGNvbGxhcHNlT25EYXRhQ2hhbmdlXG4gICAgICAgIGlmIChcbiAgICAgICAgICAob2xkU3RhdGUuc29ydGVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNvcnRlZCAmJlxuICAgICAgICAgICAgdGhpcy5wcm9wcy5jb2xsYXBzZU9uU29ydGluZ0NoYW5nZSkgfHxcbiAgICAgICAgICBvbGRTdGF0ZS5maWx0ZXJlZCAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5maWx0ZXJlZCB8fFxuICAgICAgICAgIG9sZFN0YXRlLnNob3dGaWx0ZXJzICE9PSBuZXdSZXNvbHZlZFN0YXRlLnNob3dGaWx0ZXJzIHx8XG4gICAgICAgICAgKG9sZFN0YXRlLnNvcnRlZERhdGEgJiZcbiAgICAgICAgICAgICFuZXdSZXNvbHZlZFN0YXRlLmZyb3plbiAmJlxuICAgICAgICAgICAgb2xkU3RhdGUucmVzb2x2ZWREYXRhICE9PSBuZXdSZXNvbHZlZFN0YXRlLnJlc29sdmVkRGF0YSAmJlxuICAgICAgICAgICAgdGhpcy5wcm9wcy5jb2xsYXBzZU9uRGF0YUNoYW5nZSlcbiAgICAgICAgKSB7XG4gICAgICAgICAgbmV3UmVzb2x2ZWRTdGF0ZS5leHBhbmRlZCA9IHt9XG4gICAgICAgIH1cblxuICAgICAgICBPYmplY3QuYXNzaWduKG5ld1Jlc29sdmVkU3RhdGUsIHRoaXMuZ2V0U29ydGVkRGF0YShuZXdSZXNvbHZlZFN0YXRlKSlcbiAgICAgIH1cblxuICAgICAgLy8gU2V0IHBhZ2UgdG8gMCBpZiBmaWx0ZXJzIGNoYW5nZVxuICAgICAgaWYgKG9sZFN0YXRlLmZpbHRlcmVkICE9PSBuZXdSZXNvbHZlZFN0YXRlLmZpbHRlcmVkKSB7XG4gICAgICAgIG5ld1Jlc29sdmVkU3RhdGUucGFnZSA9IDBcbiAgICAgIH1cblxuICAgICAgLy8gQ2FsY3VsYXRlIHBhZ2VTaXplIGFsbCB0aGUgdGltZVxuICAgICAgaWYgKG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkRGF0YSkge1xuICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VzID0gbmV3UmVzb2x2ZWRTdGF0ZS5tYW51YWxcbiAgICAgICAgICA/IG5ld1Jlc29sdmVkU3RhdGUucGFnZXNcbiAgICAgICAgICA6IE1hdGguY2VpbChcbiAgICAgICAgICAgIG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkRGF0YS5sZW5ndGggLyBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VTaXplXG4gICAgICAgICAgKVxuICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UgPSBNYXRoLm1heChcbiAgICAgICAgICBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UgPj0gbmV3UmVzb2x2ZWRTdGF0ZS5wYWdlc1xuICAgICAgICAgICAgPyBuZXdSZXNvbHZlZFN0YXRlLnBhZ2VzIC0gMVxuICAgICAgICAgICAgOiBuZXdSZXNvbHZlZFN0YXRlLnBhZ2UsXG4gICAgICAgICAgMFxuICAgICAgICApXG4gICAgICB9XG5cbiAgICAgIHJldHVybiB0aGlzLnNldFN0YXRlKG5ld1Jlc29sdmVkU3RhdGUsICgpID0+IHtcbiAgICAgICAgY2IgJiYgY2IoKVxuICAgICAgICBpZiAoXG4gICAgICAgICAgb2xkU3RhdGUucGFnZSAhPT0gbmV3UmVzb2x2ZWRTdGF0ZS5wYWdlIHx8XG4gICAgICAgICAgb2xkU3RhdGUucGFnZVNpemUgIT09IG5ld1Jlc29sdmVkU3RhdGUucGFnZVNpemUgfHxcbiAgICAgICAgICBvbGRTdGF0ZS5zb3J0ZWQgIT09IG5ld1Jlc29sdmVkU3RhdGUuc29ydGVkIHx8XG4gICAgICAgICAgb2xkU3RhdGUuZmlsdGVyZWQgIT09IG5ld1Jlc29sdmVkU3RhdGUuZmlsdGVyZWRcbiAgICAgICAgKSB7XG4gICAgICAgICAgdGhpcy5maXJlRmV0Y2hEYXRhKClcbiAgICAgICAgfVxuICAgICAgfSlcbiAgICB9XG4gIH1cbiJdfQ== - // urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils - return { - href: urlParsingNode.href, - protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '', - host: urlParsingNode.host, - search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '', - hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '', - hostname: urlParsingNode.hostname, - port: urlParsingNode.port, - pathname: (urlParsingNode.pathname.charAt(0) === '/') ? - urlParsingNode.pathname : - '/' + urlParsingNode.pathname - }; - } +/***/ }), +/* 360 */ +/***/ (function(module, exports, __webpack_require__) { - originURL = resolveURL(window.location.href); +"use strict"; - /** - * Determine if a URL shares the same origin as the current location - * - * @param {String} requestURL The URL to test - * @returns {boolean} True if URL shares the same origin, otherwise false - */ - return function isURLSameOrigin(requestURL) { - var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL; - return (parsed.protocol === originURL.protocol && - parsed.host === originURL.host); - }; - })() : - // Non standard browser envs (web workers, react-native) lack needed support. - (function nonStandardBrowserEnv() { - return function isURLSameOrigin() { - return true; - }; - })() -); +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); +var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; -/***/ }), -/* 410 */ -/***/ (function(module, exports, __webpack_require__) { +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -"use strict"; +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); +var _react = __webpack_require__(6); -// btoa polyfill for IE<10 courtesy https://github.com/davidchambers/Base64.js +var _react2 = _interopRequireDefault(_react); -var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='; +var _utils = __webpack_require__(95); -function E() { - this.message = 'String contains an invalid character'; -} -E.prototype = new Error; -E.prototype.code = 5; -E.prototype.name = 'InvalidCharacterError'; +var _utils2 = _interopRequireDefault(_utils); -function btoa(input) { - var str = String(input); - var output = ''; - for ( - // initialize result and counter - var block, charCode, idx = 0, map = chars; - // if the next str index does not exist: - // change the mapping table to "=" - // check if d has no fractional digits - str.charAt(idx | 0) || (map = '=', idx % 1); - // "8 - idx % 1 * 8" generates the sequence 2, 4, 6, 8 - output += map.charAt(63 & block >> 8 - idx % 1 * 8) - ) { - charCode = str.charCodeAt(idx += 3 / 4); - if (charCode > 0xFF) { - throw new E(); - } - block = block << 8 | charCode; - } - return output; -} +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -module.exports = btoa; +function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } +function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } } -/***/ }), -/* 411 */ -/***/ (function(module, exports, __webpack_require__) { +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -"use strict"; +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -var utils = __webpack_require__(46); +exports.default = function (Base) { + return function (_Base) { + _inherits(_class, _Base); -module.exports = ( - utils.isStandardBrowserEnv() ? + function _class() { + _classCallCheck(this, _class); - // Standard browser envs support document.cookie - (function standardBrowserEnv() { - return { - write: function write(name, value, expires, path, domain, secure) { - var cookie = []; - cookie.push(name + '=' + encodeURIComponent(value)); + return _possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).apply(this, arguments)); + } - if (utils.isNumber(expires)) { - cookie.push('expires=' + new Date(expires).toGMTString()); - } + _createClass(_class, [{ + key: 'getResolvedState', + value: function getResolvedState(props, state) { + var resolvedState = _extends({}, _utils2.default.compactObject(this.state), _utils2.default.compactObject(this.props), _utils2.default.compactObject(state), _utils2.default.compactObject(props)); + return resolvedState; + } + }, { + key: 'getDataModel', + value: function getDataModel(newState) { + var _this2 = this; + + var columns = newState.columns, + _newState$pivotBy = newState.pivotBy, + pivotBy = _newState$pivotBy === undefined ? [] : _newState$pivotBy, + data = newState.data, + pivotIDKey = newState.pivotIDKey, + pivotValKey = newState.pivotValKey, + subRowsKey = newState.subRowsKey, + aggregatedKey = newState.aggregatedKey, + nestingLevelKey = newState.nestingLevelKey, + originalKey = newState.originalKey, + indexKey = newState.indexKey, + groupedByPivotKey = newState.groupedByPivotKey, + SubComponent = newState.SubComponent; + + // Determine Header Groups + + var hasHeaderGroups = false; + columns.forEach(function (column) { + if (column.columns) { + hasHeaderGroups = true; + } + }); - if (utils.isString(path)) { - cookie.push('path=' + path); - } + var columnsWithExpander = [].concat(_toConsumableArray(columns)); - if (utils.isString(domain)) { - cookie.push('domain=' + domain); + var expanderColumn = columns.find(function (col) { + return col.expander || col.columns && col.columns.some(function (col2) { + return col2.expander; + }); + }); + // The actual expander might be in the columns field of a group column + if (expanderColumn && !expanderColumn.expander) { + expanderColumn = expanderColumn.columns.find(function (col) { + return col.expander; + }); } - if (secure === true) { - cookie.push('secure'); + // If we have SubComponent's we need to make sure we have an expander column + if (SubComponent && !expanderColumn) { + expanderColumn = { expander: true }; + columnsWithExpander = [expanderColumn].concat(_toConsumableArray(columnsWithExpander)); } - document.cookie = cookie.join('; '); - }, + var makeDecoratedColumn = function makeDecoratedColumn(column, parentColumn) { + var dcol = void 0; + if (column.expander) { + dcol = _extends({}, _this2.props.column, _this2.props.expanderDefaults, column); + } else { + dcol = _extends({}, _this2.props.column, column); + } - read: function read(name) { - var match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)')); - return (match ? decodeURIComponent(match[3]) : null); - }, + // Ensure minWidth is not greater than maxWidth if set + if (dcol.maxWidth < dcol.minWidth) { + dcol.minWidth = dcol.maxWidth; + } - remove: function remove(name) { - this.write(name, '', Date.now() - 86400000); - } - }; - })() : + if (parentColumn) { + dcol.parentColumn = parentColumn; + } - // Non standard browser env (web workers, react-native) lack needed support. - (function nonStandardBrowserEnv() { - return { - write: function write() {}, - read: function read() { return null; }, - remove: function remove() {} - }; - })() -); + // First check for string accessor + if (typeof dcol.accessor === 'string') { + var _ret = function () { + dcol.id = dcol.id || dcol.accessor; + var accessorString = dcol.accessor; + dcol.accessor = function (row) { + return _utils2.default.get(row, accessorString); + }; + return { + v: dcol + }; + }(); + if ((typeof _ret === 'undefined' ? 'undefined' : _typeof(_ret)) === "object") return _ret.v; + } -/***/ }), -/* 412 */ -/***/ (function(module, exports, __webpack_require__) { + // Fall back to functional accessor (but require an ID) + if (dcol.accessor && !dcol.id) { + console.warn(dcol); + throw new Error('A column id is required if using a non-string accessor for column above.'); + } -"use strict"; + // Fall back to an undefined accessor + if (!dcol.accessor) { + dcol.accessor = function (d) { + return undefined; + }; + } + return dcol; + }; -var utils = __webpack_require__(46); + // Decorate the columns + var decorateAndAddToAll = function decorateAndAddToAll(column, parentColumn) { + var decoratedColumn = makeDecoratedColumn(column, parentColumn); + allDecoratedColumns.push(decoratedColumn); + return decoratedColumn; + }; + var allDecoratedColumns = []; + var decoratedColumns = columnsWithExpander.map(function (column, i) { + if (column.columns) { + return _extends({}, column, { + columns: column.columns.map(function (d) { + return decorateAndAddToAll(d, column); + }) + }); + } else { + return decorateAndAddToAll(column); + } + }); -function InterceptorManager() { - this.handlers = []; -} + // Build the visible columns, headers and flat column list + var visibleColumns = decoratedColumns.slice(); + var allVisibleColumns = []; -/** - * Add a new interceptor to the stack - * - * @param {Function} fulfilled The function to handle `then` for a `Promise` - * @param {Function} rejected The function to handle `reject` for a `Promise` - * - * @return {Number} An ID used to remove interceptor later - */ -InterceptorManager.prototype.use = function use(fulfilled, rejected) { - this.handlers.push({ - fulfilled: fulfilled, - rejected: rejected - }); - return this.handlers.length - 1; -}; + visibleColumns = visibleColumns.map(function (column, i) { + if (column.columns) { + var visibleSubColumns = column.columns.filter(function (d) { + return pivotBy.indexOf(d.id) > -1 ? false : _utils2.default.getFirstDefined(d.show, true); + }); + return _extends({}, column, { + columns: visibleSubColumns + }); + } + return column; + }); -/** - * Remove an interceptor from the stack - * - * @param {Number} id The ID that was returned by `use` - */ -InterceptorManager.prototype.eject = function eject(id) { - if (this.handlers[id]) { - this.handlers[id] = null; - } -}; + visibleColumns = visibleColumns.filter(function (column) { + return column.columns ? column.columns.length : pivotBy.indexOf(column.id) > -1 ? false : _utils2.default.getFirstDefined(column.show, true); + }); -/** - * Iterate over all the registered interceptors - * - * This method is particularly useful for skipping over any - * interceptors that may have become `null` calling `eject`. - * - * @param {Function} fn The function to call for each interceptor - */ -InterceptorManager.prototype.forEach = function forEach(fn) { - utils.forEach(this.handlers, function forEachHandler(h) { - if (h !== null) { - fn(h); - } - }); -}; + // Find any custom pivot location + var pivotIndex = visibleColumns.findIndex(function (col) { + return col.pivot; + }); -module.exports = InterceptorManager; + // Handle Pivot Columns + if (pivotBy.length) { + (function () { + // Retrieve the pivot columns in the correct pivot order + var pivotColumns = []; + pivotBy.forEach(function (pivotID) { + var found = allDecoratedColumns.find(function (d) { + return d.id === pivotID; + }); + if (found) { + pivotColumns.push(found); + } + }); + var PivotParentColumn = pivotColumns.reduce(function (prev, current) { + return prev && prev === current.parentColumn && current.parentColumn; + }, pivotColumns[0].parentColumn); -/***/ }), -/* 413 */ -/***/ (function(module, exports, __webpack_require__) { + var PivotGroupHeader = hasHeaderGroups && PivotParentColumn.Header; + PivotGroupHeader = PivotGroupHeader || function () { + return _react2.default.createElement( + 'strong', + null, + 'Pivoted' + ); + }; -"use strict"; + var pivotColumnGroup = { + Header: PivotGroupHeader, + columns: pivotColumns.map(function (col) { + return _extends({}, _this2.props.pivotDefaults, col, { + pivoted: true + }); + }) + }; + // Place the pivotColumns back into the visibleColumns + if (pivotIndex >= 0) { + pivotColumnGroup = _extends({}, visibleColumns[pivotIndex], pivotColumnGroup); + visibleColumns.splice(pivotIndex, 1, pivotColumnGroup); + } else { + visibleColumns.unshift(pivotColumnGroup); + } + })(); + } -var utils = __webpack_require__(46); -var transformData = __webpack_require__(414); -var isCancel = __webpack_require__(304); -var defaults = __webpack_require__(258); + // Build Header Groups + var headerGroups = []; + var currentSpan = []; -/** - * Throws a `Cancel` if cancellation has been requested. - */ -function throwIfCancellationRequested(config) { - if (config.cancelToken) { - config.cancelToken.throwIfRequested(); - } -} + // A convenience function to add a header and reset the currentSpan + var addHeader = function addHeader(columns, column) { + headerGroups.push(_extends({}, _this2.props.column, column, { + columns: columns + })); + currentSpan = []; + }; -/** - * Dispatch a request to the server using the configured adapter. - * - * @param {object} config The config that is to be used for the request - * @returns {Promise} The Promise to be fulfilled - */ -module.exports = function dispatchRequest(config) { - throwIfCancellationRequested(config); + // Build flast list of allVisibleColumns and HeaderGroups + visibleColumns.forEach(function (column, i) { + if (column.columns) { + allVisibleColumns = allVisibleColumns.concat(column.columns); + if (currentSpan.length > 0) { + addHeader(currentSpan); + } + addHeader(column.columns, column); + return; + } + allVisibleColumns.push(column); + currentSpan.push(column); + }); + if (hasHeaderGroups && currentSpan.length > 0) { + addHeader(currentSpan); + } - // Ensure headers exist - config.headers = config.headers || {}; + // Access the data + var accessRow = function accessRow(d, i) { + var _row; - // Transform request data - config.data = transformData( - config.data, - config.headers, - config.transformRequest - ); + var level = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0; - // Flatten headers - config.headers = utils.merge( - config.headers.common || {}, - config.headers[config.method] || {}, - config.headers || {} - ); + var row = (_row = {}, _defineProperty(_row, originalKey, d), _defineProperty(_row, indexKey, i), _defineProperty(_row, subRowsKey, d[subRowsKey]), _defineProperty(_row, nestingLevelKey, level), _row); + allDecoratedColumns.forEach(function (column) { + if (column.expander) return; + row[column.id] = column.accessor(d); + }); + if (row[subRowsKey]) { + row[subRowsKey] = row[subRowsKey].map(function (d, i) { + return accessRow(d, i, level + 1); + }); + } + return row; + }; + var resolvedData = data.map(function (d, i) { + return accessRow(d, i); + }); - utils.forEach( - ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], - function cleanHeaderConfig(method) { - delete config.headers[method]; - } - ); + // If pivoting, recursively group the data + var aggregate = function aggregate(rows) { + var aggregationValues = {}; + aggregatingColumns.forEach(function (column) { + var values = rows.map(function (d) { + return d[column.id]; + }); + aggregationValues[column.id] = column.aggregate(values, rows); + }); + return aggregationValues; + }; - var adapter = config.adapter || defaults.adapter; + // TODO: Make it possible to fabricate nested rows without pivoting + var aggregatingColumns = allVisibleColumns.filter(function (d) { + return !d.expander && d.aggregate; + }); + if (pivotBy.length) { + (function () { + var groupRecursively = function groupRecursively(rows, keys) { + var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0; + + // This is the last level, just return the rows + if (i === keys.length) { + return rows; + } + // Group the rows together for this level + var groupedRows = Object.entries(_utils2.default.groupBy(rows, keys[i])).map(function (_ref) { + var _ref3; - return adapter(config).then(function onAdapterResolution(response) { - throwIfCancellationRequested(config); + var _ref2 = _slicedToArray(_ref, 2), + key = _ref2[0], + value = _ref2[1]; - // Transform response data - response.data = transformData( - response.data, - response.headers, - config.transformResponse - ); + return _ref3 = {}, _defineProperty(_ref3, pivotIDKey, keys[i]), _defineProperty(_ref3, pivotValKey, key), _defineProperty(_ref3, keys[i], key), _defineProperty(_ref3, subRowsKey, value), _defineProperty(_ref3, nestingLevelKey, i), _defineProperty(_ref3, groupedByPivotKey, true), _ref3; + }); + // Recurse into the subRows + groupedRows = groupedRows.map(function (rowGroup) { + var _extends2; - return response; - }, function onAdapterRejection(reason) { - if (!isCancel(reason)) { - throwIfCancellationRequested(config); + var subRows = groupRecursively(rowGroup[subRowsKey], keys, i + 1); + return _extends({}, rowGroup, (_extends2 = {}, _defineProperty(_extends2, subRowsKey, subRows), _defineProperty(_extends2, aggregatedKey, true), _extends2), aggregate(subRows)); + }); + return groupedRows; + }; + resolvedData = groupRecursively(resolvedData, pivotBy); + })(); + } - // Transform response data - if (reason && reason.response) { - reason.response.data = transformData( - reason.response.data, - reason.response.headers, - config.transformResponse - ); + return _extends({}, newState, { + resolvedData: resolvedData, + allVisibleColumns: allVisibleColumns, + headerGroups: headerGroups, + allDecoratedColumns: allDecoratedColumns, + hasHeaderGroups: hasHeaderGroups + }); } - } + }, { + key: 'getSortedData', + value: function getSortedData(resolvedState) { + var manual = resolvedState.manual, + sorted = resolvedState.sorted, + filtered = resolvedState.filtered, + defaultFilterMethod = resolvedState.defaultFilterMethod, + resolvedData = resolvedState.resolvedData, + allVisibleColumns = resolvedState.allVisibleColumns, + allDecoratedColumns = resolvedState.allDecoratedColumns; + + + var sortMethodsByColumnID = {}; + + allDecoratedColumns.filter(function (col) { + return col.sortMethod; + }).forEach(function (col) { + sortMethodsByColumnID[col.id] = col.sortMethod; + }); - return Promise.reject(reason); - }); -}; + // Resolve the data from either manual data or sorted data + return { + sortedData: manual ? resolvedData : this.sortData(this.filterData(resolvedData, filtered, defaultFilterMethod, allVisibleColumns), sorted, sortMethodsByColumnID) + }; + } + }, { + key: 'fireFetchData', + value: function fireFetchData() { + this.props.onFetchData(this.getResolvedState(), this); + } + }, { + key: 'getPropOrState', + value: function getPropOrState(key) { + return _utils2.default.getFirstDefined(this.props[key], this.state[key]); + } + }, { + key: 'getStateOrProp', + value: function getStateOrProp(key) { + return _utils2.default.getFirstDefined(this.state[key], this.props[key]); + } + }, { + key: 'filterData', + value: function filterData(data, filtered, defaultFilterMethod, allVisibleColumns) { + var _this3 = this; + var filteredData = data; -/***/ }), -/* 414 */ -/***/ (function(module, exports, __webpack_require__) { + if (filtered.length) { + filteredData = filtered.reduce(function (filteredSoFar, nextFilter) { + var column = allVisibleColumns.find(function (x) { + return x.id === nextFilter.id; + }); -"use strict"; + // Don't filter hidden columns or columns that have had their filters disabled + if (!column || column.filterable === false) { + return filteredSoFar; + } + var filterMethod = column.filterMethod || defaultFilterMethod; -var utils = __webpack_require__(46); + // If 'filterAll' is set to true, pass the entire dataset to the filter method + if (column.filterAll) { + return filterMethod(nextFilter, filteredSoFar, column); + } else { + return filteredSoFar.filter(function (row) { + return filterMethod(nextFilter, row, column); + }); + } + }, filteredData); -/** - * Transform the data for a request or a response - * - * @param {Object|String} data The data to be transformed - * @param {Array} headers The headers for the request or response - * @param {Array|Function} fns A single function or Array of functions - * @returns {*} The resulting transformed data - */ -module.exports = function transformData(data, headers, fns) { - /*eslint no-param-reassign:0*/ - utils.forEach(fns, function transform(fn) { - data = fn(data, headers); - }); + // Apply the filter to the subrows if we are pivoting, and then + // filter any rows without subcolumns because it would be strange to show + filteredData = filteredData.map(function (row) { + if (!row[_this3.props.subRowsKey]) { + return row; + } + return _extends({}, row, _defineProperty({}, _this3.props.subRowsKey, _this3.filterData(row[_this3.props.subRowsKey], filtered, defaultFilterMethod, allVisibleColumns))); + }).filter(function (row) { + if (!row[_this3.props.subRowsKey]) { + return true; + } + return row[_this3.props.subRowsKey].length > 0; + }); + } - return data; -}; + return filteredData; + } + }, { + key: 'sortData', + value: function sortData(data, sorted) { + var _this4 = this; + var sortMethodsByColumnID = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {}; -/***/ }), -/* 415 */ -/***/ (function(module, exports, __webpack_require__) { + if (!sorted.length) { + return data; + } -"use strict"; + var sortedData = (this.props.orderByMethod || _utils2.default.orderBy)(data, sorted.map(function (sort) { + // Support custom sorting methods for each column + if (sortMethodsByColumnID[sort.id]) { + return function (a, b) { + return sortMethodsByColumnID[sort.id](a[sort.id], b[sort.id]); + }; + } + return function (a, b) { + return _this4.props.defaultSortMethod(a[sort.id], b[sort.id]); + }; + }), sorted.map(function (d) { + return !d.desc; + }), this.props.indexKey); + sortedData.forEach(function (row) { + if (!row[_this4.props.subRowsKey]) { + return; + } + row[_this4.props.subRowsKey] = _this4.sortData(row[_this4.props.subRowsKey], sorted, sortMethodsByColumnID); + }); -/** - * Determines whether the specified URL is absolute - * - * @param {string} url The URL to test - * @returns {boolean} True if the specified URL is absolute, otherwise false - */ -module.exports = function isAbsoluteURL(url) { - // A URL is considered absolute if it begins with "<scheme>://" or "//" (protocol-relative URL). - // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed - // by any combination of letters, digits, plus, period, or hyphen. - return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url); -}; + return sortedData; + } + }, { + key: 'getMinRows', + value: function getMinRows() { + return _utils2.default.getFirstDefined(this.props.minRows, this.getStateOrProp('pageSize')); + } + // User actions -/***/ }), -/* 416 */ -/***/ (function(module, exports, __webpack_require__) { + }, { + key: 'onPageChange', + value: function onPageChange(page) { + var _props = this.props, + onPageChange = _props.onPageChange, + collapseOnPageChange = _props.collapseOnPageChange; -"use strict"; + var newState = { page: page }; + if (collapseOnPageChange) { + newState.expanded = {}; + } + this.setStateWithData(newState, function () { + onPageChange && onPageChange(page); + }); + } + }, { + key: 'onPageSizeChange', + value: function onPageSizeChange(newPageSize) { + var onPageSizeChange = this.props.onPageSizeChange; -/** - * Creates a new URL by combining the specified URLs - * - * @param {string} baseURL The base URL - * @param {string} relativeURL The relative URL - * @returns {string} The combined URL - */ -module.exports = function combineURLs(baseURL, relativeURL) { - return relativeURL - ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '') - : baseURL; -}; + var _getResolvedState = this.getResolvedState(), + pageSize = _getResolvedState.pageSize, + page = _getResolvedState.page; + // Normalize the page to display -/***/ }), -/* 417 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; + var currentRow = pageSize * page; + var newPage = Math.floor(currentRow / newPageSize); + this.setStateWithData({ + pageSize: newPageSize, + page: newPage + }, function () { + onPageSizeChange && onPageSizeChange(newPageSize, newPage); + }); + } + }, { + key: 'sortColumn', + value: function sortColumn(column, additive) { + var _getResolvedState2 = this.getResolvedState(), + sorted = _getResolvedState2.sorted, + skipNextSort = _getResolvedState2.skipNextSort, + defaultSortDesc = _getResolvedState2.defaultSortDesc; + + var firstSortDirection = column.hasOwnProperty('defaultSortDesc') ? column.defaultSortDesc : defaultSortDesc; + var secondSortDirection = !firstSortDirection; + + // we can't stop event propagation from the column resize move handlers + // attached to the document because of react's synthetic events + // so we have to prevent the sort function from actually sorting + // if we click on the column resize element within a header. + if (skipNextSort) { + this.setStateWithData({ + skipNextSort: false + }); + return; + } -var Cancel = __webpack_require__(305); + var onSortedChange = this.props.onSortedChange; -/** - * A `CancelToken` is an object that can be used to request cancellation of an operation. - * - * @class - * @param {Function} executor The executor function. - */ -function CancelToken(executor) { - if (typeof executor !== 'function') { - throw new TypeError('executor must be a function.'); - } - var resolvePromise; - this.promise = new Promise(function promiseExecutor(resolve) { - resolvePromise = resolve; - }); + var newSorted = _utils2.default.clone(sorted || []).map(function (d) { + d.desc = _utils2.default.isSortingDesc(d); + return d; + }); + if (!_utils2.default.isArray(column)) { + // Single-Sort + var existingIndex = newSorted.findIndex(function (d) { + return d.id === column.id; + }); + if (existingIndex > -1) { + var existing = newSorted[existingIndex]; + if (existing.desc === secondSortDirection) { + if (additive) { + newSorted.splice(existingIndex, 1); + } else { + existing.desc = firstSortDirection; + newSorted = [existing]; + } + } else { + existing.desc = secondSortDirection; + if (!additive) { + newSorted = [existing]; + } + } + } else { + if (additive) { + newSorted.push({ + id: column.id, + desc: firstSortDirection + }); + } else { + newSorted = [{ + id: column.id, + desc: firstSortDirection + }]; + } + } + } else { + (function () { + // Multi-Sort + var existingIndex = newSorted.findIndex(function (d) { + return d.id === column[0].id; + }); + // Existing Sorted Column + if (existingIndex > -1) { + var _existing = newSorted[existingIndex]; + if (_existing.desc === secondSortDirection) { + if (additive) { + newSorted.splice(existingIndex, column.length); + } else { + column.forEach(function (d, i) { + newSorted[existingIndex + i].desc = firstSortDirection; + }); + } + } else { + column.forEach(function (d, i) { + newSorted[existingIndex + i].desc = secondSortDirection; + }); + } + if (!additive) { + newSorted = newSorted.slice(existingIndex, column.length); + } + } else { + // New Sort Column + if (additive) { + newSorted = newSorted.concat(column.map(function (d) { + return { + id: d.id, + desc: firstSortDirection + }; + })); + } else { + newSorted = column.map(function (d) { + return { + id: d.id, + desc: firstSortDirection + }; + }); + } + } + })(); + } - var token = this; - executor(function cancel(message) { - if (token.reason) { - // Cancellation has already been requested - return; - } + this.setStateWithData({ + page: !sorted.length && newSorted.length || !additive ? 0 : this.state.page, + sorted: newSorted + }, function () { + onSortedChange && onSortedChange(newSorted, column, additive); + }); + } + }, { + key: 'filterColumn', + value: function filterColumn(column, value) { + var _getResolvedState3 = this.getResolvedState(), + filtered = _getResolvedState3.filtered; - token.reason = new Cancel(message); - resolvePromise(token.reason); - }); -} + var onFilteredChange = this.props.onFilteredChange; -/** - * Throws a `Cancel` if cancellation has been requested. - */ -CancelToken.prototype.throwIfRequested = function throwIfRequested() { - if (this.reason) { - throw this.reason; - } -}; + // Remove old filter first if it exists -/** - * Returns an object that contains a new `CancelToken` and a function that, when called, - * cancels the `CancelToken`. - */ -CancelToken.source = function source() { - var cancel; - var token = new CancelToken(function executor(c) { - cancel = c; - }); - return { - token: token, - cancel: cancel - }; -}; + var newFiltering = (filtered || []).filter(function (x) { + if (x.id !== column.id) { + return true; + } + }); -module.exports = CancelToken; + if (value !== '') { + newFiltering.push({ + id: column.id, + value: value + }); + } + + this.setStateWithData({ + filtered: newFiltering + }, function () { + onFilteredChange && onFilteredChange(newFiltering, column, value); + }); + } + }, { + key: 'resizeColumnStart', + value: function resizeColumnStart(event, column, isTouch) { + var _this5 = this; + event.stopPropagation(); + var parentWidth = event.target.parentElement.getBoundingClientRect().width; -/***/ }), -/* 418 */ -/***/ (function(module, exports, __webpack_require__) { + var pageX = void 0; + if (isTouch) { + pageX = event.changedTouches[0].pageX; + } else { + pageX = event.pageX; + } -"use strict"; + this.trapEvents = true; + this.setStateWithData({ + currentlyResizing: { + id: column.id, + startX: pageX, + parentWidth: parentWidth + } + }, function () { + if (isTouch) { + document.addEventListener('touchmove', _this5.resizeColumnMoving); + document.addEventListener('touchcancel', _this5.resizeColumnEnd); + document.addEventListener('touchend', _this5.resizeColumnEnd); + } else { + document.addEventListener('mousemove', _this5.resizeColumnMoving); + document.addEventListener('mouseup', _this5.resizeColumnEnd); + document.addEventListener('mouseleave', _this5.resizeColumnEnd); + } + }); + } + }, { + key: 'resizeColumnMoving', + value: function resizeColumnMoving(event) { + event.stopPropagation(); + var onResizedChange = this.props.onResizedChange; + var _getResolvedState4 = this.getResolvedState(), + resized = _getResolvedState4.resized, + currentlyResizing = _getResolvedState4.currentlyResizing; -/** - * Syntactic sugar for invoking a function and expanding an array for arguments. - * - * Common use case would be to use `Function.prototype.apply`. - * - * ```js - * function f(x, y, z) {} - * var args = [1, 2, 3]; - * f.apply(null, args); - * ``` - * - * With `spread` this example can be re-written. - * - * ```js - * spread(function(x, y, z) {})([1, 2, 3]); - * ``` - * - * @param {Function} callback - * @returns {Function} - */ -module.exports = function spread(callback) { - return function wrap(arr) { - return callback.apply(null, arr); - }; -}; + // Delete old value -/***/ }), -/* 419 */ -/***/ (function(module, exports, __webpack_require__) { + var newResized = resized.filter(function (x) { + return x.id !== currentlyResizing.id; + }); -"use strict"; + var pageX = void 0; + + if (event.type === 'touchmove') { + pageX = event.changedTouches[0].pageX; + } else if (event.type === 'mousemove') { + pageX = event.pageX; + } + // Set the min size to 10 to account for margin and border or else the group headers don't line up correctly + var newWidth = Math.max(currentlyResizing.parentWidth + pageX - currentlyResizing.startX, 11); -var _require = __webpack_require__(420), - CopyToClipboard = _require.CopyToClipboard; + newResized.push({ + id: currentlyResizing.id, + value: newWidth + }); -module.exports = CopyToClipboard; + this.setStateWithData({ + resized: newResized + }, function () { + onResizedChange && onResizedChange(newResized, event); + }); + } + }, { + key: 'resizeColumnEnd', + value: function resizeColumnEnd(event) { + event.stopPropagation(); + var isTouch = event.type === 'touchend' || event.type === 'touchcancel'; + + if (isTouch) { + document.removeEventListener('touchmove', this.resizeColumnMoving); + document.removeEventListener('touchcancel', this.resizeColumnEnd); + document.removeEventListener('touchend', this.resizeColumnEnd); + } + + // If its a touch event clear the mouse one's as well because sometimes + // the mouseDown event gets called as well, but the mouseUp event doesn't + document.removeEventListener('mousemove', this.resizeColumnMoving); + document.removeEventListener('mouseup', this.resizeColumnEnd); + document.removeEventListener('mouseleave', this.resizeColumnEnd); + + // The touch events don't propagate up to the sorting's onMouseDown event so + // no need to prevent it from happening or else the first click after a touch + // event resize will not sort the column. + if (!isTouch) { + this.setStateWithData({ + skipNextSort: true, + currentlyResizing: false + }); + } + } + }]); + + return _class; + }(Base); +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9tZXRob2RzLmpzIl0sIm5hbWVzIjpbInByb3BzIiwic3RhdGUiLCJyZXNvbHZlZFN0YXRlIiwiY29tcGFjdE9iamVjdCIsIm5ld1N0YXRlIiwiY29sdW1ucyIsInBpdm90QnkiLCJkYXRhIiwicGl2b3RJREtleSIsInBpdm90VmFsS2V5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJuZXN0aW5nTGV2ZWxLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJTdWJDb21wb25lbnQiLCJoYXNIZWFkZXJHcm91cHMiLCJmb3JFYWNoIiwiY29sdW1uIiwiY29sdW1uc1dpdGhFeHBhbmRlciIsImV4cGFuZGVyQ29sdW1uIiwiZmluZCIsImNvbCIsImV4cGFuZGVyIiwic29tZSIsImNvbDIiLCJtYWtlRGVjb3JhdGVkQ29sdW1uIiwicGFyZW50Q29sdW1uIiwiZGNvbCIsImV4cGFuZGVyRGVmYXVsdHMiLCJtYXhXaWR0aCIsIm1pbldpZHRoIiwiYWNjZXNzb3IiLCJpZCIsImFjY2Vzc29yU3RyaW5nIiwiZ2V0Iiwicm93IiwiY29uc29sZSIsIndhcm4iLCJFcnJvciIsInVuZGVmaW5lZCIsImRlY29yYXRlQW5kQWRkVG9BbGwiLCJkZWNvcmF0ZWRDb2x1bW4iLCJhbGxEZWNvcmF0ZWRDb2x1bW5zIiwicHVzaCIsImRlY29yYXRlZENvbHVtbnMiLCJtYXAiLCJpIiwiZCIsInZpc2libGVDb2x1bW5zIiwic2xpY2UiLCJhbGxWaXNpYmxlQ29sdW1ucyIsInZpc2libGVTdWJDb2x1bW5zIiwiZmlsdGVyIiwiaW5kZXhPZiIsImdldEZpcnN0RGVmaW5lZCIsInNob3ciLCJsZW5ndGgiLCJwaXZvdEluZGV4IiwiZmluZEluZGV4IiwicGl2b3QiLCJwaXZvdENvbHVtbnMiLCJmb3VuZCIsInBpdm90SUQiLCJQaXZvdFBhcmVudENvbHVtbiIsInJlZHVjZSIsInByZXYiLCJjdXJyZW50IiwiUGl2b3RHcm91cEhlYWRlciIsIkhlYWRlciIsInBpdm90Q29sdW1uR3JvdXAiLCJwaXZvdERlZmF1bHRzIiwicGl2b3RlZCIsInNwbGljZSIsInVuc2hpZnQiLCJoZWFkZXJHcm91cHMiLCJjdXJyZW50U3BhbiIsImFkZEhlYWRlciIsImNvbmNhdCIsImFjY2Vzc1JvdyIsImxldmVsIiwicmVzb2x2ZWREYXRhIiwiYWdncmVnYXRlIiwiYWdncmVnYXRpb25WYWx1ZXMiLCJhZ2dyZWdhdGluZ0NvbHVtbnMiLCJ2YWx1ZXMiLCJyb3dzIiwiZ3JvdXBSZWN1cnNpdmVseSIsImtleXMiLCJncm91cGVkUm93cyIsIk9iamVjdCIsImVudHJpZXMiLCJncm91cEJ5Iiwia2V5IiwidmFsdWUiLCJzdWJSb3dzIiwicm93R3JvdXAiLCJtYW51YWwiLCJzb3J0ZWQiLCJmaWx0ZXJlZCIsImRlZmF1bHRGaWx0ZXJNZXRob2QiLCJzb3J0TWV0aG9kc0J5Q29sdW1uSUQiLCJzb3J0TWV0aG9kIiwic29ydGVkRGF0YSIsInNvcnREYXRhIiwiZmlsdGVyRGF0YSIsIm9uRmV0Y2hEYXRhIiwiZ2V0UmVzb2x2ZWRTdGF0ZSIsImZpbHRlcmVkRGF0YSIsImZpbHRlcmVkU29GYXIiLCJuZXh0RmlsdGVyIiwieCIsImZpbHRlcmFibGUiLCJmaWx0ZXJNZXRob2QiLCJmaWx0ZXJBbGwiLCJvcmRlckJ5TWV0aG9kIiwib3JkZXJCeSIsInNvcnQiLCJhIiwiYiIsImRlZmF1bHRTb3J0TWV0aG9kIiwiZGVzYyIsIm1pblJvd3MiLCJnZXRTdGF0ZU9yUHJvcCIsInBhZ2UiLCJvblBhZ2VDaGFuZ2UiLCJjb2xsYXBzZU9uUGFnZUNoYW5nZSIsImV4cGFuZGVkIiwic2V0U3RhdGVXaXRoRGF0YSIsIm5ld1BhZ2VTaXplIiwib25QYWdlU2l6ZUNoYW5nZSIsInBhZ2VTaXplIiwiY3VycmVudFJvdyIsIm5ld1BhZ2UiLCJNYXRoIiwiZmxvb3IiLCJhZGRpdGl2ZSIsInNraXBOZXh0U29ydCIsImRlZmF1bHRTb3J0RGVzYyIsImZpcnN0U29ydERpcmVjdGlvbiIsImhhc093blByb3BlcnR5Iiwic2Vjb25kU29ydERpcmVjdGlvbiIsIm9uU29ydGVkQ2hhbmdlIiwibmV3U29ydGVkIiwiY2xvbmUiLCJpc1NvcnRpbmdEZXNjIiwiaXNBcnJheSIsImV4aXN0aW5nSW5kZXgiLCJleGlzdGluZyIsIm9uRmlsdGVyZWRDaGFuZ2UiLCJuZXdGaWx0ZXJpbmciLCJldmVudCIsImlzVG91Y2giLCJzdG9wUHJvcGFnYXRpb24iLCJwYXJlbnRXaWR0aCIsInRhcmdldCIsInBhcmVudEVsZW1lbnQiLCJnZXRCb3VuZGluZ0NsaWVudFJlY3QiLCJ3aWR0aCIsInBhZ2VYIiwiY2hhbmdlZFRvdWNoZXMiLCJ0cmFwRXZlbnRzIiwiY3VycmVudGx5UmVzaXppbmciLCJzdGFydFgiLCJkb2N1bWVudCIsImFkZEV2ZW50TGlzdGVuZXIiLCJyZXNpemVDb2x1bW5Nb3ZpbmciLCJyZXNpemVDb2x1bW5FbmQiLCJvblJlc2l6ZWRDaGFuZ2UiLCJyZXNpemVkIiwibmV3UmVzaXplZCIsInR5cGUiLCJuZXdXaWR0aCIsIm1heCIsInJlbW92ZUV2ZW50TGlzdGVuZXIiLCJCYXNlIl0sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7OztBQUFBOzs7O0FBQ0E7Ozs7Ozs7Ozs7Ozs7Ozs7a0JBRWU7QUFBQTtBQUFBOztBQUFBO0FBQUE7O0FBQUE7QUFBQTs7QUFBQTtBQUFBO0FBQUEsdUNBRU9BLEtBRlAsRUFFY0MsS0FGZCxFQUVxQjtBQUM5QixZQUFNQyw2QkFDRCxnQkFBRUMsYUFBRixDQUFnQixLQUFLRixLQUFyQixDQURDLEVBRUQsZ0JBQUVFLGFBQUYsQ0FBZ0IsS0FBS0gsS0FBckIsQ0FGQyxFQUdELGdCQUFFRyxhQUFGLENBQWdCRixLQUFoQixDQUhDLEVBSUQsZ0JBQUVFLGFBQUYsQ0FBZ0JILEtBQWhCLENBSkMsQ0FBTjtBQU1BLGVBQU9FLGFBQVA7QUFDRDtBQVZVO0FBQUE7QUFBQSxtQ0FZR0UsUUFaSCxFQVlhO0FBQUE7O0FBQUEsWUFFcEJDLE9BRm9CLEdBY2xCRCxRQWRrQixDQUVwQkMsT0FGb0I7QUFBQSxnQ0FjbEJELFFBZGtCLENBR3BCRSxPQUhvQjtBQUFBLFlBR3BCQSxPQUhvQixxQ0FHVixFQUhVO0FBQUEsWUFJcEJDLElBSm9CLEdBY2xCSCxRQWRrQixDQUlwQkcsSUFKb0I7QUFBQSxZQUtwQkMsVUFMb0IsR0FjbEJKLFFBZGtCLENBS3BCSSxVQUxvQjtBQUFBLFlBTXBCQyxXQU5vQixHQWNsQkwsUUFka0IsQ0FNcEJLLFdBTm9CO0FBQUEsWUFPcEJDLFVBUG9CLEdBY2xCTixRQWRrQixDQU9wQk0sVUFQb0I7QUFBQSxZQVFwQkMsYUFSb0IsR0FjbEJQLFFBZGtCLENBUXBCTyxhQVJvQjtBQUFBLFlBU3BCQyxlQVRvQixHQWNsQlIsUUFka0IsQ0FTcEJRLGVBVG9CO0FBQUEsWUFVcEJDLFdBVm9CLEdBY2xCVCxRQWRrQixDQVVwQlMsV0FWb0I7QUFBQSxZQVdwQkMsUUFYb0IsR0FjbEJWLFFBZGtCLENBV3BCVSxRQVhvQjtBQUFBLFlBWXBCQyxpQkFab0IsR0FjbEJYLFFBZGtCLENBWXBCVyxpQkFab0I7QUFBQSxZQWFwQkMsWUFib0IsR0FjbEJaLFFBZGtCLENBYXBCWSxZQWJvQjs7QUFnQnRCOztBQUNBLFlBQUlDLGtCQUFrQixLQUF0QjtBQUNBWixnQkFBUWEsT0FBUixDQUFnQixrQkFBVTtBQUN4QixjQUFJQyxPQUFPZCxPQUFYLEVBQW9CO0FBQ2xCWSw4QkFBa0IsSUFBbEI7QUFDRDtBQUNGLFNBSkQ7O0FBTUEsWUFBSUcsbURBQTBCZixPQUExQixFQUFKOztBQUVBLFlBQUlnQixpQkFBaUJoQixRQUFRaUIsSUFBUixDQUNuQjtBQUFBLGlCQUNFQyxJQUFJQyxRQUFKLElBQ0NELElBQUlsQixPQUFKLElBQWVrQixJQUFJbEIsT0FBSixDQUFZb0IsSUFBWixDQUFpQjtBQUFBLG1CQUFRQyxLQUFLRixRQUFiO0FBQUEsV0FBakIsQ0FGbEI7QUFBQSxTQURtQixDQUFyQjtBQUtBO0FBQ0EsWUFBSUgsa0JBQWtCLENBQUNBLGVBQWVHLFFBQXRDLEVBQWdEO0FBQzlDSCwyQkFBaUJBLGVBQWVoQixPQUFmLENBQXVCaUIsSUFBdkIsQ0FBNEI7QUFBQSxtQkFBT0MsSUFBSUMsUUFBWDtBQUFBLFdBQTVCLENBQWpCO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFJUixnQkFBZ0IsQ0FBQ0ssY0FBckIsRUFBcUM7QUFDbkNBLDJCQUFpQixFQUFFRyxVQUFVLElBQVosRUFBakI7QUFDQUosaUNBQXVCQyxjQUF2Qiw0QkFBMENELG1CQUExQztBQUNEOztBQUVELFlBQU1PLHNCQUFzQixTQUF0QkEsbUJBQXNCLENBQUNSLE1BQUQsRUFBU1MsWUFBVCxFQUEwQjtBQUNwRCxjQUFJQyxhQUFKO0FBQ0EsY0FBSVYsT0FBT0ssUUFBWCxFQUFxQjtBQUNuQkssZ0NBQ0ssT0FBSzdCLEtBQUwsQ0FBV21CLE1BRGhCLEVBRUssT0FBS25CLEtBQUwsQ0FBVzhCLGdCQUZoQixFQUdLWCxNQUhMO0FBS0QsV0FORCxNQU1PO0FBQ0xVLGdDQUNLLE9BQUs3QixLQUFMLENBQVdtQixNQURoQixFQUVLQSxNQUZMO0FBSUQ7O0FBRUQ7QUFDQSxjQUFJVSxLQUFLRSxRQUFMLEdBQWdCRixLQUFLRyxRQUF6QixFQUFtQztBQUNqQ0gsaUJBQUtHLFFBQUwsR0FBZ0JILEtBQUtFLFFBQXJCO0FBQ0Q7O0FBRUQsY0FBSUgsWUFBSixFQUFrQjtBQUNoQkMsaUJBQUtELFlBQUwsR0FBb0JBLFlBQXBCO0FBQ0Q7O0FBRUQ7QUFDQSxjQUFJLE9BQU9DLEtBQUtJLFFBQVosS0FBeUIsUUFBN0IsRUFBdUM7QUFBQTtBQUNyQ0osbUJBQUtLLEVBQUwsR0FBVUwsS0FBS0ssRUFBTCxJQUFXTCxLQUFLSSxRQUExQjtBQUNBLGtCQUFNRSxpQkFBaUJOLEtBQUtJLFFBQTVCO0FBQ0FKLG1CQUFLSSxRQUFMLEdBQWdCO0FBQUEsdUJBQU8sZ0JBQUVHLEdBQUYsQ0FBTUMsR0FBTixFQUFXRixjQUFYLENBQVA7QUFBQSxlQUFoQjtBQUNBO0FBQUEsbUJBQU9OO0FBQVA7QUFKcUM7O0FBQUE7QUFLdEM7O0FBRUQ7QUFDQSxjQUFJQSxLQUFLSSxRQUFMLElBQWlCLENBQUNKLEtBQUtLLEVBQTNCLEVBQStCO0FBQzdCSSxvQkFBUUMsSUFBUixDQUFhVixJQUFiO0FBQ0Esa0JBQU0sSUFBSVcsS0FBSixDQUNKLDBFQURJLENBQU47QUFHRDs7QUFFRDtBQUNBLGNBQUksQ0FBQ1gsS0FBS0ksUUFBVixFQUFvQjtBQUNsQkosaUJBQUtJLFFBQUwsR0FBZ0I7QUFBQSxxQkFBS1EsU0FBTDtBQUFBLGFBQWhCO0FBQ0Q7O0FBRUQsaUJBQU9aLElBQVA7QUFDRCxTQTlDRDs7QUFnREE7QUFDQSxZQUFNYSxzQkFBc0IsU0FBdEJBLG1CQUFzQixDQUFDdkIsTUFBRCxFQUFTUyxZQUFULEVBQTBCO0FBQ3BELGNBQU1lLGtCQUFrQmhCLG9CQUFvQlIsTUFBcEIsRUFBNEJTLFlBQTVCLENBQXhCO0FBQ0FnQiw4QkFBb0JDLElBQXBCLENBQXlCRixlQUF6QjtBQUNBLGlCQUFPQSxlQUFQO0FBQ0QsU0FKRDtBQUtBLFlBQU1DLHNCQUFzQixFQUE1QjtBQUNBLFlBQU1FLG1CQUFtQjFCLG9CQUFvQjJCLEdBQXBCLENBQXdCLFVBQUM1QixNQUFELEVBQVM2QixDQUFULEVBQWU7QUFDOUQsY0FBSTdCLE9BQU9kLE9BQVgsRUFBb0I7QUFDbEIsZ0NBQ0tjLE1BREw7QUFFRWQsdUJBQVNjLE9BQU9kLE9BQVAsQ0FBZTBDLEdBQWYsQ0FBbUI7QUFBQSx1QkFBS0wsb0JBQW9CTyxDQUFwQixFQUF1QjlCLE1BQXZCLENBQUw7QUFBQSxlQUFuQjtBQUZYO0FBSUQsV0FMRCxNQUtPO0FBQ0wsbUJBQU91QixvQkFBb0J2QixNQUFwQixDQUFQO0FBQ0Q7QUFDRixTQVR3QixDQUF6Qjs7QUFXQTtBQUNBLFlBQUkrQixpQkFBaUJKLGlCQUFpQkssS0FBakIsRUFBckI7QUFDQSxZQUFJQyxvQkFBb0IsRUFBeEI7O0FBRUFGLHlCQUFpQkEsZUFBZUgsR0FBZixDQUFtQixVQUFDNUIsTUFBRCxFQUFTNkIsQ0FBVCxFQUFlO0FBQ2pELGNBQUk3QixPQUFPZCxPQUFYLEVBQW9CO0FBQ2xCLGdCQUFNZ0Qsb0JBQW9CbEMsT0FBT2QsT0FBUCxDQUFlaUQsTUFBZixDQUN4QjtBQUFBLHFCQUNFaEQsUUFBUWlELE9BQVIsQ0FBZ0JOLEVBQUVmLEVBQWxCLElBQXdCLENBQUMsQ0FBekIsR0FDSSxLQURKLEdBRUksZ0JBQUVzQixlQUFGLENBQWtCUCxFQUFFUSxJQUFwQixFQUEwQixJQUExQixDQUhOO0FBQUEsYUFEd0IsQ0FBMUI7QUFNQSxnQ0FDS3RDLE1BREw7QUFFRWQsdUJBQVNnRDtBQUZYO0FBSUQ7QUFDRCxpQkFBT2xDLE1BQVA7QUFDRCxTQWRnQixDQUFqQjs7QUFnQkErQix5QkFBaUJBLGVBQWVJLE1BQWYsQ0FBc0Isa0JBQVU7QUFDL0MsaUJBQU9uQyxPQUFPZCxPQUFQLEdBQ0hjLE9BQU9kLE9BQVAsQ0FBZXFELE1BRFosR0FFSHBELFFBQVFpRCxPQUFSLENBQWdCcEMsT0FBT2UsRUFBdkIsSUFBNkIsQ0FBQyxDQUE5QixHQUNFLEtBREYsR0FFRSxnQkFBRXNCLGVBQUYsQ0FBa0JyQyxPQUFPc0MsSUFBekIsRUFBK0IsSUFBL0IsQ0FKTjtBQUtELFNBTmdCLENBQWpCOztBQVFBO0FBQ0EsWUFBTUUsYUFBYVQsZUFBZVUsU0FBZixDQUF5QjtBQUFBLGlCQUFPckMsSUFBSXNDLEtBQVg7QUFBQSxTQUF6QixDQUFuQjs7QUFFQTtBQUNBLFlBQUl2RCxRQUFRb0QsTUFBWixFQUFvQjtBQUFBO0FBQ2xCO0FBQ0EsZ0JBQU1JLGVBQWUsRUFBckI7QUFDQXhELG9CQUFRWSxPQUFSLENBQWdCLG1CQUFXO0FBQ3pCLGtCQUFNNkMsUUFBUW5CLG9CQUFvQnRCLElBQXBCLENBQXlCO0FBQUEsdUJBQUsyQixFQUFFZixFQUFGLEtBQVM4QixPQUFkO0FBQUEsZUFBekIsQ0FBZDtBQUNBLGtCQUFJRCxLQUFKLEVBQVc7QUFDVEQsNkJBQWFqQixJQUFiLENBQWtCa0IsS0FBbEI7QUFDRDtBQUNGLGFBTEQ7O0FBT0EsZ0JBQUlFLG9CQUFvQkgsYUFBYUksTUFBYixDQUN0QixVQUFDQyxJQUFELEVBQU9DLE9BQVA7QUFBQSxxQkFDRUQsUUFBUUEsU0FBU0MsUUFBUXhDLFlBQXpCLElBQXlDd0MsUUFBUXhDLFlBRG5EO0FBQUEsYUFEc0IsRUFHdEJrQyxhQUFhLENBQWIsRUFBZ0JsQyxZQUhNLENBQXhCOztBQU1BLGdCQUFJeUMsbUJBQW1CcEQsbUJBQW1CZ0Qsa0JBQWtCSyxNQUE1RDtBQUNBRCwrQkFBbUJBLG9CQUFxQjtBQUFBLHFCQUFNO0FBQUE7QUFBQTtBQUFBO0FBQUEsZUFBTjtBQUFBLGFBQXhDOztBQUVBLGdCQUFJRSxtQkFBbUI7QUFDckJELHNCQUFRRCxnQkFEYTtBQUVyQmhFLHVCQUFTeUQsYUFBYWYsR0FBYixDQUFpQjtBQUFBLG9DQUNyQixPQUFLL0MsS0FBTCxDQUFXd0UsYUFEVSxFQUVyQmpELEdBRnFCO0FBR3hCa0QsMkJBQVM7QUFIZTtBQUFBLGVBQWpCO0FBRlksYUFBdkI7O0FBU0E7QUFDQSxnQkFBSWQsY0FBYyxDQUFsQixFQUFxQjtBQUNuQlksOENBQ0tyQixlQUFlUyxVQUFmLENBREwsRUFFS1ksZ0JBRkw7QUFJQXJCLDZCQUFld0IsTUFBZixDQUFzQmYsVUFBdEIsRUFBa0MsQ0FBbEMsRUFBcUNZLGdCQUFyQztBQUNELGFBTkQsTUFNTztBQUNMckIsNkJBQWV5QixPQUFmLENBQXVCSixnQkFBdkI7QUFDRDtBQXJDaUI7QUFzQ25COztBQUVEO0FBQ0EsWUFBTUssZUFBZSxFQUFyQjtBQUNBLFlBQUlDLGNBQWMsRUFBbEI7O0FBRUE7QUFDQSxZQUFNQyxZQUFZLFNBQVpBLFNBQVksQ0FBQ3pFLE9BQUQsRUFBVWMsTUFBVixFQUFxQjtBQUNyQ3lELHVCQUFhL0IsSUFBYixjQUNLLE9BQUs3QyxLQUFMLENBQVdtQixNQURoQixFQUVLQSxNQUZMO0FBR0VkLHFCQUFTQTtBQUhYO0FBS0F3RSx3QkFBYyxFQUFkO0FBQ0QsU0FQRDs7QUFTQTtBQUNBM0IsdUJBQWVoQyxPQUFmLENBQXVCLFVBQUNDLE1BQUQsRUFBUzZCLENBQVQsRUFBZTtBQUNwQyxjQUFJN0IsT0FBT2QsT0FBWCxFQUFvQjtBQUNsQitDLGdDQUFvQkEsa0JBQWtCMkIsTUFBbEIsQ0FBeUI1RCxPQUFPZCxPQUFoQyxDQUFwQjtBQUNBLGdCQUFJd0UsWUFBWW5CLE1BQVosR0FBcUIsQ0FBekIsRUFBNEI7QUFDMUJvQix3QkFBVUQsV0FBVjtBQUNEO0FBQ0RDLHNCQUFVM0QsT0FBT2QsT0FBakIsRUFBMEJjLE1BQTFCO0FBQ0E7QUFDRDtBQUNEaUMsNEJBQWtCUCxJQUFsQixDQUF1QjFCLE1BQXZCO0FBQ0EwRCxzQkFBWWhDLElBQVosQ0FBaUIxQixNQUFqQjtBQUNELFNBWEQ7QUFZQSxZQUFJRixtQkFBbUI0RCxZQUFZbkIsTUFBWixHQUFxQixDQUE1QyxFQUErQztBQUM3Q29CLG9CQUFVRCxXQUFWO0FBQ0Q7O0FBRUQ7QUFDQSxZQUFNRyxZQUFZLFNBQVpBLFNBQVksQ0FBQy9CLENBQUQsRUFBSUQsQ0FBSixFQUFxQjtBQUFBOztBQUFBLGNBQWRpQyxLQUFjLHVFQUFOLENBQU07O0FBQ3JDLGNBQU01Qyx3Q0FDSHhCLFdBREcsRUFDV29DLENBRFgseUJBRUhuQyxRQUZHLEVBRVFrQyxDQUZSLHlCQUdIdEMsVUFIRyxFQUdVdUMsRUFBRXZDLFVBQUYsQ0FIVix5QkFJSEUsZUFKRyxFQUllcUUsS0FKZixRQUFOO0FBTUFyQyw4QkFBb0IxQixPQUFwQixDQUE0QixrQkFBVTtBQUNwQyxnQkFBSUMsT0FBT0ssUUFBWCxFQUFxQjtBQUNyQmEsZ0JBQUlsQixPQUFPZSxFQUFYLElBQWlCZixPQUFPYyxRQUFQLENBQWdCZ0IsQ0FBaEIsQ0FBakI7QUFDRCxXQUhEO0FBSUEsY0FBSVosSUFBSTNCLFVBQUosQ0FBSixFQUFxQjtBQUNuQjJCLGdCQUFJM0IsVUFBSixJQUFrQjJCLElBQUkzQixVQUFKLEVBQWdCcUMsR0FBaEIsQ0FBb0IsVUFBQ0UsQ0FBRCxFQUFJRCxDQUFKO0FBQUEscUJBQ3BDZ0MsVUFBVS9CLENBQVYsRUFBYUQsQ0FBYixFQUFnQmlDLFFBQVEsQ0FBeEIsQ0FEb0M7QUFBQSxhQUFwQixDQUFsQjtBQUdEO0FBQ0QsaUJBQU81QyxHQUFQO0FBQ0QsU0FqQkQ7QUFrQkEsWUFBSTZDLGVBQWUzRSxLQUFLd0MsR0FBTCxDQUFTLFVBQUNFLENBQUQsRUFBSUQsQ0FBSjtBQUFBLGlCQUFVZ0MsVUFBVS9CLENBQVYsRUFBYUQsQ0FBYixDQUFWO0FBQUEsU0FBVCxDQUFuQjs7QUFFQTtBQUNBLFlBQU1tQyxZQUFZLFNBQVpBLFNBQVksT0FBUTtBQUN4QixjQUFNQyxvQkFBb0IsRUFBMUI7QUFDQUMsNkJBQW1CbkUsT0FBbkIsQ0FBMkIsa0JBQVU7QUFDbkMsZ0JBQU1vRSxTQUFTQyxLQUFLeEMsR0FBTCxDQUFTO0FBQUEscUJBQUtFLEVBQUU5QixPQUFPZSxFQUFULENBQUw7QUFBQSxhQUFULENBQWY7QUFDQWtELDhCQUFrQmpFLE9BQU9lLEVBQXpCLElBQStCZixPQUFPZ0UsU0FBUCxDQUFpQkcsTUFBakIsRUFBeUJDLElBQXpCLENBQS9CO0FBQ0QsV0FIRDtBQUlBLGlCQUFPSCxpQkFBUDtBQUNELFNBUEQ7O0FBU0E7QUFDQSxZQUFNQyxxQkFBcUJqQyxrQkFBa0JFLE1BQWxCLENBQ3pCO0FBQUEsaUJBQUssQ0FBQ0wsRUFBRXpCLFFBQUgsSUFBZXlCLEVBQUVrQyxTQUF0QjtBQUFBLFNBRHlCLENBQTNCO0FBR0EsWUFBSTdFLFFBQVFvRCxNQUFaLEVBQW9CO0FBQUE7QUFDbEIsZ0JBQU04QixtQkFBbUIsU0FBbkJBLGdCQUFtQixDQUFDRCxJQUFELEVBQU9FLElBQVAsRUFBdUI7QUFBQSxrQkFBVnpDLENBQVUsdUVBQU4sQ0FBTTs7QUFDOUM7QUFDQSxrQkFBSUEsTUFBTXlDLEtBQUsvQixNQUFmLEVBQXVCO0FBQ3JCLHVCQUFPNkIsSUFBUDtBQUNEO0FBQ0Q7QUFDQSxrQkFBSUcsY0FBY0MsT0FBT0MsT0FBUCxDQUNoQixnQkFBRUMsT0FBRixDQUFVTixJQUFWLEVBQWdCRSxLQUFLekMsQ0FBTCxDQUFoQixDQURnQixFQUVoQkQsR0FGZ0IsQ0FFWixnQkFBa0I7QUFBQTs7QUFBQTtBQUFBLG9CQUFoQitDLEdBQWdCO0FBQUEsb0JBQVhDLEtBQVc7O0FBQ3RCLDBEQUNHdkYsVUFESCxFQUNnQmlGLEtBQUt6QyxDQUFMLENBRGhCLDBCQUVHdkMsV0FGSCxFQUVpQnFGLEdBRmpCLDBCQUdHTCxLQUFLekMsQ0FBTCxDQUhILEVBR2E4QyxHQUhiLDBCQUlHcEYsVUFKSCxFQUlnQnFGLEtBSmhCLDBCQUtHbkYsZUFMSCxFQUtxQm9DLENBTHJCLDBCQU1HakMsaUJBTkgsRUFNdUIsSUFOdkI7QUFRRCxlQVhpQixDQUFsQjtBQVlBO0FBQ0EyRSw0QkFBY0EsWUFBWTNDLEdBQVosQ0FBZ0Isb0JBQVk7QUFBQTs7QUFDeEMsb0JBQUlpRCxVQUFVUixpQkFBaUJTLFNBQVN2RixVQUFULENBQWpCLEVBQXVDK0UsSUFBdkMsRUFBNkN6QyxJQUFJLENBQWpELENBQWQ7QUFDQSxvQ0FDS2lELFFBREwsOENBRUd2RixVQUZILEVBRWdCc0YsT0FGaEIsOEJBR0dyRixhQUhILEVBR21CLElBSG5CLGVBSUt3RSxVQUFVYSxPQUFWLENBSkw7QUFNRCxlQVJhLENBQWQ7QUFTQSxxQkFBT04sV0FBUDtBQUNELGFBN0JEO0FBOEJBUiwyQkFBZU0saUJBQWlCTixZQUFqQixFQUErQjVFLE9BQS9CLENBQWY7QUEvQmtCO0FBZ0NuQjs7QUFFRCw0QkFDS0YsUUFETDtBQUVFOEUsb0NBRkY7QUFHRTlCLDhDQUhGO0FBSUV3QixvQ0FKRjtBQUtFaEMsa0RBTEY7QUFNRTNCO0FBTkY7QUFRRDtBQTVTVTtBQUFBO0FBQUEsb0NBOFNJZixhQTlTSixFQThTbUI7QUFBQSxZQUUxQmdHLE1BRjBCLEdBU3hCaEcsYUFUd0IsQ0FFMUJnRyxNQUYwQjtBQUFBLFlBRzFCQyxNQUgwQixHQVN4QmpHLGFBVHdCLENBRzFCaUcsTUFIMEI7QUFBQSxZQUkxQkMsUUFKMEIsR0FTeEJsRyxhQVR3QixDQUkxQmtHLFFBSjBCO0FBQUEsWUFLMUJDLG1CQUwwQixHQVN4Qm5HLGFBVHdCLENBSzFCbUcsbUJBTDBCO0FBQUEsWUFNMUJuQixZQU4wQixHQVN4QmhGLGFBVHdCLENBTTFCZ0YsWUFOMEI7QUFBQSxZQU8xQjlCLGlCQVAwQixHQVN4QmxELGFBVHdCLENBTzFCa0QsaUJBUDBCO0FBQUEsWUFRMUJSLG1CQVIwQixHQVN4QjFDLGFBVHdCLENBUTFCMEMsbUJBUjBCOzs7QUFXNUIsWUFBTTBELHdCQUF3QixFQUE5Qjs7QUFFQTFELDRCQUFvQlUsTUFBcEIsQ0FBMkI7QUFBQSxpQkFBTy9CLElBQUlnRixVQUFYO0FBQUEsU0FBM0IsRUFBa0RyRixPQUFsRCxDQUEwRCxlQUFPO0FBQy9Eb0YsZ0NBQXNCL0UsSUFBSVcsRUFBMUIsSUFBZ0NYLElBQUlnRixVQUFwQztBQUNELFNBRkQ7O0FBSUE7QUFDQSxlQUFPO0FBQ0xDLHNCQUFZTixTQUNSaEIsWUFEUSxHQUVSLEtBQUt1QixRQUFMLENBQ0EsS0FBS0MsVUFBTCxDQUNFeEIsWUFERixFQUVFa0IsUUFGRixFQUdFQyxtQkFIRixFQUlFakQsaUJBSkYsQ0FEQSxFQU9BK0MsTUFQQSxFQVFBRyxxQkFSQTtBQUhDLFNBQVA7QUFjRDtBQTlVVTtBQUFBO0FBQUEsc0NBZ1ZNO0FBQ2YsYUFBS3RHLEtBQUwsQ0FBVzJHLFdBQVgsQ0FBdUIsS0FBS0MsZ0JBQUwsRUFBdkIsRUFBZ0QsSUFBaEQ7QUFDRDtBQWxWVTtBQUFBO0FBQUEscUNBb1ZLZCxHQXBWTCxFQW9WVTtBQUNuQixlQUFPLGdCQUFFdEMsZUFBRixDQUFrQixLQUFLeEQsS0FBTCxDQUFXOEYsR0FBWCxDQUFsQixFQUFtQyxLQUFLN0YsS0FBTCxDQUFXNkYsR0FBWCxDQUFuQyxDQUFQO0FBQ0Q7QUF0VlU7QUFBQTtBQUFBLHFDQXdWS0EsR0F4VkwsRUF3VlU7QUFDbkIsZUFBTyxnQkFBRXRDLGVBQUYsQ0FBa0IsS0FBS3ZELEtBQUwsQ0FBVzZGLEdBQVgsQ0FBbEIsRUFBbUMsS0FBSzlGLEtBQUwsQ0FBVzhGLEdBQVgsQ0FBbkMsQ0FBUDtBQUNEO0FBMVZVO0FBQUE7QUFBQSxpQ0E0VkN2RixJQTVWRCxFQTRWTzZGLFFBNVZQLEVBNFZpQkMsbUJBNVZqQixFQTRWc0NqRCxpQkE1VnRDLEVBNFZ5RDtBQUFBOztBQUNsRSxZQUFJeUQsZUFBZXRHLElBQW5COztBQUVBLFlBQUk2RixTQUFTMUMsTUFBYixFQUFxQjtBQUNuQm1ELHlCQUFlVCxTQUFTbEMsTUFBVCxDQUFnQixVQUFDNEMsYUFBRCxFQUFnQkMsVUFBaEIsRUFBK0I7QUFDNUQsZ0JBQU01RixTQUFTaUMsa0JBQWtCOUIsSUFBbEIsQ0FBdUI7QUFBQSxxQkFBSzBGLEVBQUU5RSxFQUFGLEtBQVM2RSxXQUFXN0UsRUFBekI7QUFBQSxhQUF2QixDQUFmOztBQUVBO0FBQ0EsZ0JBQUksQ0FBQ2YsTUFBRCxJQUFXQSxPQUFPOEYsVUFBUCxLQUFzQixLQUFyQyxFQUE0QztBQUMxQyxxQkFBT0gsYUFBUDtBQUNEOztBQUVELGdCQUFNSSxlQUFlL0YsT0FBTytGLFlBQVAsSUFBdUJiLG1CQUE1Qzs7QUFFQTtBQUNBLGdCQUFJbEYsT0FBT2dHLFNBQVgsRUFBc0I7QUFDcEIscUJBQU9ELGFBQWFILFVBQWIsRUFBeUJELGFBQXpCLEVBQXdDM0YsTUFBeEMsQ0FBUDtBQUNELGFBRkQsTUFFTztBQUNMLHFCQUFPMkYsY0FBY3hELE1BQWQsQ0FBcUIsZUFBTztBQUNqQyx1QkFBTzRELGFBQWFILFVBQWIsRUFBeUIxRSxHQUF6QixFQUE4QmxCLE1BQTlCLENBQVA7QUFDRCxlQUZNLENBQVA7QUFHRDtBQUNGLFdBbEJjLEVBa0JaMEYsWUFsQlksQ0FBZjs7QUFvQkE7QUFDQTtBQUNBQSx5QkFBZUEsYUFDWjlELEdBRFksQ0FDUixlQUFPO0FBQ1YsZ0JBQUksQ0FBQ1YsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBQUwsRUFBaUM7QUFDL0IscUJBQU8yQixHQUFQO0FBQ0Q7QUFDRCxnQ0FDS0EsR0FETCxzQkFFRyxPQUFLckMsS0FBTCxDQUFXVSxVQUZkLEVBRTJCLE9BQUtnRyxVQUFMLENBQ3ZCckUsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBRHVCLEVBRXZCMEYsUUFGdUIsRUFHdkJDLG1CQUh1QixFQUl2QmpELGlCQUp1QixDQUYzQjtBQVNELFdBZFksRUFlWkUsTUFmWSxDQWVMLGVBQU87QUFDYixnQkFBSSxDQUFDakIsSUFBSSxPQUFLckMsS0FBTCxDQUFXVSxVQUFmLENBQUwsRUFBaUM7QUFDL0IscUJBQU8sSUFBUDtBQUNEO0FBQ0QsbUJBQU8yQixJQUFJLE9BQUtyQyxLQUFMLENBQVdVLFVBQWYsRUFBMkJnRCxNQUEzQixHQUFvQyxDQUEzQztBQUNELFdBcEJZLENBQWY7QUFxQkQ7O0FBRUQsZUFBT21ELFlBQVA7QUFDRDtBQTlZVTtBQUFBO0FBQUEsK0JBZ1pEdEcsSUFoWkMsRUFnWks0RixNQWhaTCxFQWdaeUM7QUFBQTs7QUFBQSxZQUE1QkcscUJBQTRCLHVFQUFKLEVBQUk7O0FBQ2xELFlBQUksQ0FBQ0gsT0FBT3pDLE1BQVosRUFBb0I7QUFDbEIsaUJBQU9uRCxJQUFQO0FBQ0Q7O0FBRUQsWUFBTWlHLGFBQWEsQ0FBQyxLQUFLeEcsS0FBTCxDQUFXb0gsYUFBWCxJQUE0QixnQkFBRUMsT0FBL0IsRUFDakI5RyxJQURpQixFQUVqQjRGLE9BQU9wRCxHQUFQLENBQVcsZ0JBQVE7QUFDakI7QUFDQSxjQUFJdUQsc0JBQXNCZ0IsS0FBS3BGLEVBQTNCLENBQUosRUFBb0M7QUFDbEMsbUJBQU8sVUFBQ3FGLENBQUQsRUFBSUMsQ0FBSixFQUFVO0FBQ2YscUJBQU9sQixzQkFBc0JnQixLQUFLcEYsRUFBM0IsRUFBK0JxRixFQUFFRCxLQUFLcEYsRUFBUCxDQUEvQixFQUEyQ3NGLEVBQUVGLEtBQUtwRixFQUFQLENBQTNDLENBQVA7QUFDRCxhQUZEO0FBR0Q7QUFDRCxpQkFBTyxVQUFDcUYsQ0FBRCxFQUFJQyxDQUFKLEVBQVU7QUFDZixtQkFBTyxPQUFLeEgsS0FBTCxDQUFXeUgsaUJBQVgsQ0FBNkJGLEVBQUVELEtBQUtwRixFQUFQLENBQTdCLEVBQXlDc0YsRUFBRUYsS0FBS3BGLEVBQVAsQ0FBekMsQ0FBUDtBQUNELFdBRkQ7QUFHRCxTQVZELENBRmlCLEVBYWpCaUUsT0FBT3BELEdBQVAsQ0FBVztBQUFBLGlCQUFLLENBQUNFLEVBQUV5RSxJQUFSO0FBQUEsU0FBWCxDQWJpQixFQWNqQixLQUFLMUgsS0FBTCxDQUFXYyxRQWRNLENBQW5COztBQWlCQTBGLG1CQUFXdEYsT0FBWCxDQUFtQixlQUFPO0FBQ3hCLGNBQUksQ0FBQ21CLElBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixDQUFMLEVBQWlDO0FBQy9CO0FBQ0Q7QUFDRDJCLGNBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixJQUE2QixPQUFLK0YsUUFBTCxDQUMzQnBFLElBQUksT0FBS3JDLEtBQUwsQ0FBV1UsVUFBZixDQUQyQixFQUUzQnlGLE1BRjJCLEVBRzNCRyxxQkFIMkIsQ0FBN0I7QUFLRCxTQVREOztBQVdBLGVBQU9FLFVBQVA7QUFDRDtBQWxiVTtBQUFBO0FBQUEsbUNBb2JHO0FBQ1osZUFBTyxnQkFBRWhELGVBQUYsQ0FDTCxLQUFLeEQsS0FBTCxDQUFXMkgsT0FETixFQUVMLEtBQUtDLGNBQUwsQ0FBb0IsVUFBcEIsQ0FGSyxDQUFQO0FBSUQ7O0FBRUQ7O0FBM2JXO0FBQUE7QUFBQSxtQ0E0YkdDLElBNWJILEVBNGJTO0FBQUEscUJBQzZCLEtBQUs3SCxLQURsQztBQUFBLFlBQ1Y4SCxZQURVLFVBQ1ZBLFlBRFU7QUFBQSxZQUNJQyxvQkFESixVQUNJQSxvQkFESjs7O0FBR2xCLFlBQU0zSCxXQUFXLEVBQUV5SCxVQUFGLEVBQWpCO0FBQ0EsWUFBSUUsb0JBQUosRUFBMEI7QUFDeEIzSCxtQkFBUzRILFFBQVQsR0FBb0IsRUFBcEI7QUFDRDtBQUNELGFBQUtDLGdCQUFMLENBQXNCN0gsUUFBdEIsRUFBZ0MsWUFBTTtBQUNwQzBILDBCQUFnQkEsYUFBYUQsSUFBYixDQUFoQjtBQUNELFNBRkQ7QUFHRDtBQXRjVTtBQUFBO0FBQUEsdUNBd2NPSyxXQXhjUCxFQXdjb0I7QUFBQSxZQUNyQkMsZ0JBRHFCLEdBQ0EsS0FBS25JLEtBREwsQ0FDckJtSSxnQkFEcUI7O0FBQUEsZ0NBRUYsS0FBS3ZCLGdCQUFMLEVBRkU7QUFBQSxZQUVyQndCLFFBRnFCLHFCQUVyQkEsUUFGcUI7QUFBQSxZQUVYUCxJQUZXLHFCQUVYQSxJQUZXOztBQUk3Qjs7O0FBQ0EsWUFBTVEsYUFBYUQsV0FBV1AsSUFBOUI7QUFDQSxZQUFNUyxVQUFVQyxLQUFLQyxLQUFMLENBQVdILGFBQWFILFdBQXhCLENBQWhCOztBQUVBLGFBQUtELGdCQUFMLENBQ0U7QUFDRUcsb0JBQVVGLFdBRFo7QUFFRUwsZ0JBQU1TO0FBRlIsU0FERixFQUtFLFlBQU07QUFDSkgsOEJBQW9CQSxpQkFBaUJELFdBQWpCLEVBQThCSSxPQUE5QixDQUFwQjtBQUNELFNBUEg7QUFTRDtBQXpkVTtBQUFBO0FBQUEsaUNBMmRDbkgsTUEzZEQsRUEyZFNzSCxRQTNkVCxFQTJkbUI7QUFBQSxpQ0FDc0IsS0FBSzdCLGdCQUFMLEVBRHRCO0FBQUEsWUFDcEJULE1BRG9CLHNCQUNwQkEsTUFEb0I7QUFBQSxZQUNadUMsWUFEWSxzQkFDWkEsWUFEWTtBQUFBLFlBQ0VDLGVBREYsc0JBQ0VBLGVBREY7O0FBRzVCLFlBQU1DLHFCQUFxQnpILE9BQU8wSCxjQUFQLENBQXNCLGlCQUF0QixJQUN2QjFILE9BQU93SCxlQURnQixHQUV2QkEsZUFGSjtBQUdBLFlBQU1HLHNCQUFzQixDQUFDRixrQkFBN0I7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7QUFDQSxZQUFJRixZQUFKLEVBQWtCO0FBQ2hCLGVBQUtULGdCQUFMLENBQXNCO0FBQ3BCUywwQkFBYztBQURNLFdBQXRCO0FBR0E7QUFDRDs7QUFqQjJCLFlBbUJwQkssY0FuQm9CLEdBbUJELEtBQUsvSSxLQW5CSixDQW1CcEIrSSxjQW5Cb0I7OztBQXFCNUIsWUFBSUMsWUFBWSxnQkFBRUMsS0FBRixDQUFROUMsVUFBVSxFQUFsQixFQUFzQnBELEdBQXRCLENBQTBCLGFBQUs7QUFDN0NFLFlBQUV5RSxJQUFGLEdBQVMsZ0JBQUV3QixhQUFGLENBQWdCakcsQ0FBaEIsQ0FBVDtBQUNBLGlCQUFPQSxDQUFQO0FBQ0QsU0FIZSxDQUFoQjtBQUlBLFlBQUksQ0FBQyxnQkFBRWtHLE9BQUYsQ0FBVWhJLE1BQVYsQ0FBTCxFQUF3QjtBQUN0QjtBQUNBLGNBQU1pSSxnQkFBZ0JKLFVBQVVwRixTQUFWLENBQW9CO0FBQUEsbUJBQUtYLEVBQUVmLEVBQUYsS0FBU2YsT0FBT2UsRUFBckI7QUFBQSxXQUFwQixDQUF0QjtBQUNBLGNBQUlrSCxnQkFBZ0IsQ0FBQyxDQUFyQixFQUF3QjtBQUN0QixnQkFBTUMsV0FBV0wsVUFBVUksYUFBVixDQUFqQjtBQUNBLGdCQUFJQyxTQUFTM0IsSUFBVCxLQUFrQm9CLG1CQUF0QixFQUEyQztBQUN6QyxrQkFBSUwsUUFBSixFQUFjO0FBQ1pPLDBCQUFVdEUsTUFBVixDQUFpQjBFLGFBQWpCLEVBQWdDLENBQWhDO0FBQ0QsZUFGRCxNQUVPO0FBQ0xDLHlCQUFTM0IsSUFBVCxHQUFnQmtCLGtCQUFoQjtBQUNBSSw0QkFBWSxDQUFDSyxRQUFELENBQVo7QUFDRDtBQUNGLGFBUEQsTUFPTztBQUNMQSx1QkFBUzNCLElBQVQsR0FBZ0JvQixtQkFBaEI7QUFDQSxrQkFBSSxDQUFDTCxRQUFMLEVBQWU7QUFDYk8sNEJBQVksQ0FBQ0ssUUFBRCxDQUFaO0FBQ0Q7QUFDRjtBQUNGLFdBZkQsTUFlTztBQUNMLGdCQUFJWixRQUFKLEVBQWM7QUFDWk8sd0JBQVVuRyxJQUFWLENBQWU7QUFDYlgsb0JBQUlmLE9BQU9lLEVBREU7QUFFYndGLHNCQUFNa0I7QUFGTyxlQUFmO0FBSUQsYUFMRCxNQUtPO0FBQ0xJLDBCQUFZLENBQ1Y7QUFDRTlHLG9CQUFJZixPQUFPZSxFQURiO0FBRUV3RixzQkFBTWtCO0FBRlIsZUFEVSxDQUFaO0FBTUQ7QUFDRjtBQUNGLFNBakNELE1BaUNPO0FBQUE7QUFDTDtBQUNBLGdCQUFNUSxnQkFBZ0JKLFVBQVVwRixTQUFWLENBQW9CO0FBQUEscUJBQUtYLEVBQUVmLEVBQUYsS0FBU2YsT0FBTyxDQUFQLEVBQVVlLEVBQXhCO0FBQUEsYUFBcEIsQ0FBdEI7QUFDQTtBQUNBLGdCQUFJa0gsZ0JBQWdCLENBQUMsQ0FBckIsRUFBd0I7QUFDdEIsa0JBQU1DLFlBQVdMLFVBQVVJLGFBQVYsQ0FBakI7QUFDQSxrQkFBSUMsVUFBUzNCLElBQVQsS0FBa0JvQixtQkFBdEIsRUFBMkM7QUFDekMsb0JBQUlMLFFBQUosRUFBYztBQUNaTyw0QkFBVXRFLE1BQVYsQ0FBaUIwRSxhQUFqQixFQUFnQ2pJLE9BQU91QyxNQUF2QztBQUNELGlCQUZELE1BRU87QUFDTHZDLHlCQUFPRCxPQUFQLENBQWUsVUFBQytCLENBQUQsRUFBSUQsQ0FBSixFQUFVO0FBQ3ZCZ0csOEJBQVVJLGdCQUFnQnBHLENBQTFCLEVBQTZCMEUsSUFBN0IsR0FBb0NrQixrQkFBcEM7QUFDRCxtQkFGRDtBQUdEO0FBQ0YsZUFSRCxNQVFPO0FBQ0x6SCx1QkFBT0QsT0FBUCxDQUFlLFVBQUMrQixDQUFELEVBQUlELENBQUosRUFBVTtBQUN2QmdHLDRCQUFVSSxnQkFBZ0JwRyxDQUExQixFQUE2QjBFLElBQTdCLEdBQW9Db0IsbUJBQXBDO0FBQ0QsaUJBRkQ7QUFHRDtBQUNELGtCQUFJLENBQUNMLFFBQUwsRUFBZTtBQUNiTyw0QkFBWUEsVUFBVTdGLEtBQVYsQ0FBZ0JpRyxhQUFoQixFQUErQmpJLE9BQU91QyxNQUF0QyxDQUFaO0FBQ0Q7QUFDRixhQWxCRCxNQWtCTztBQUNMO0FBQ0Esa0JBQUkrRSxRQUFKLEVBQWM7QUFDWk8sNEJBQVlBLFVBQVVqRSxNQUFWLENBQ1Y1RCxPQUFPNEIsR0FBUCxDQUFXO0FBQUEseUJBQU07QUFDZmIsd0JBQUllLEVBQUVmLEVBRFM7QUFFZndGLDBCQUFNa0I7QUFGUyxtQkFBTjtBQUFBLGlCQUFYLENBRFUsQ0FBWjtBQU1ELGVBUEQsTUFPTztBQUNMSSw0QkFBWTdILE9BQU80QixHQUFQLENBQVc7QUFBQSx5QkFBTTtBQUMzQmIsd0JBQUllLEVBQUVmLEVBRHFCO0FBRTNCd0YsMEJBQU1rQjtBQUZxQixtQkFBTjtBQUFBLGlCQUFYLENBQVo7QUFJRDtBQUNGO0FBckNJO0FBc0NOOztBQUVELGFBQUtYLGdCQUFMLENBQ0U7QUFDRUosZ0JBQ0csQ0FBQzFCLE9BQU96QyxNQUFSLElBQWtCc0YsVUFBVXRGLE1BQTdCLElBQXdDLENBQUMrRSxRQUF6QyxHQUNJLENBREosR0FFSSxLQUFLeEksS0FBTCxDQUFXNEgsSUFKbkI7QUFLRTFCLGtCQUFRNkM7QUFMVixTQURGLEVBUUUsWUFBTTtBQUNKRCw0QkFBa0JBLGVBQWVDLFNBQWYsRUFBMEI3SCxNQUExQixFQUFrQ3NILFFBQWxDLENBQWxCO0FBQ0QsU0FWSDtBQVlEO0FBemtCVTtBQUFBO0FBQUEsbUNBMmtCR3RILE1BM2tCSCxFQTJrQlc0RSxLQTNrQlgsRUEya0JrQjtBQUFBLGlDQUNOLEtBQUthLGdCQUFMLEVBRE07QUFBQSxZQUNuQlIsUUFEbUIsc0JBQ25CQSxRQURtQjs7QUFBQSxZQUVuQmtELGdCQUZtQixHQUVFLEtBQUt0SixLQUZQLENBRW5Cc0osZ0JBRm1COztBQUkzQjs7QUFDQSxZQUFNQyxlQUFlLENBQUNuRCxZQUFZLEVBQWIsRUFBaUI5QyxNQUFqQixDQUF3QixhQUFLO0FBQ2hELGNBQUkwRCxFQUFFOUUsRUFBRixLQUFTZixPQUFPZSxFQUFwQixFQUF3QjtBQUN0QixtQkFBTyxJQUFQO0FBQ0Q7QUFDRixTQUpvQixDQUFyQjs7QUFNQSxZQUFJNkQsVUFBVSxFQUFkLEVBQWtCO0FBQ2hCd0QsdUJBQWExRyxJQUFiLENBQWtCO0FBQ2hCWCxnQkFBSWYsT0FBT2UsRUFESztBQUVoQjZELG1CQUFPQTtBQUZTLFdBQWxCO0FBSUQ7O0FBRUQsYUFBS2tDLGdCQUFMLENBQ0U7QUFDRTdCLG9CQUFVbUQ7QUFEWixTQURGLEVBSUUsWUFBTTtBQUNKRCw4QkFBb0JBLGlCQUFpQkMsWUFBakIsRUFBK0JwSSxNQUEvQixFQUF1QzRFLEtBQXZDLENBQXBCO0FBQ0QsU0FOSDtBQVFEO0FBcm1CVTtBQUFBO0FBQUEsd0NBdW1CUXlELEtBdm1CUixFQXVtQmVySSxNQXZtQmYsRUF1bUJ1QnNJLE9Bdm1CdkIsRUF1bUJnQztBQUFBOztBQUN6Q0QsY0FBTUUsZUFBTjtBQUNBLFlBQU1DLGNBQWNILE1BQU1JLE1BQU4sQ0FBYUMsYUFBYixDQUEyQkMscUJBQTNCLEdBQ2pCQyxLQURIOztBQUdBLFlBQUlDLGNBQUo7QUFDQSxZQUFJUCxPQUFKLEVBQWE7QUFDWE8sa0JBQVFSLE1BQU1TLGNBQU4sQ0FBcUIsQ0FBckIsRUFBd0JELEtBQWhDO0FBQ0QsU0FGRCxNQUVPO0FBQ0xBLGtCQUFRUixNQUFNUSxLQUFkO0FBQ0Q7O0FBRUQsYUFBS0UsVUFBTCxHQUFrQixJQUFsQjtBQUNBLGFBQUtqQyxnQkFBTCxDQUNFO0FBQ0VrQyw2QkFBbUI7QUFDakJqSSxnQkFBSWYsT0FBT2UsRUFETTtBQUVqQmtJLG9CQUFRSixLQUZTO0FBR2pCTCx5QkFBYUE7QUFISTtBQURyQixTQURGLEVBUUUsWUFBTTtBQUNKLGNBQUlGLE9BQUosRUFBYTtBQUNYWSxxQkFBU0MsZ0JBQVQsQ0FBMEIsV0FBMUIsRUFBdUMsT0FBS0Msa0JBQTVDO0FBQ0FGLHFCQUFTQyxnQkFBVCxDQUEwQixhQUExQixFQUF5QyxPQUFLRSxlQUE5QztBQUNBSCxxQkFBU0MsZ0JBQVQsQ0FBMEIsVUFBMUIsRUFBc0MsT0FBS0UsZUFBM0M7QUFDRCxXQUpELE1BSU87QUFDTEgscUJBQVNDLGdCQUFULENBQTBCLFdBQTFCLEVBQXVDLE9BQUtDLGtCQUE1QztBQUNBRixxQkFBU0MsZ0JBQVQsQ0FBMEIsU0FBMUIsRUFBcUMsT0FBS0UsZUFBMUM7QUFDQUgscUJBQVNDLGdCQUFULENBQTBCLFlBQTFCLEVBQXdDLE9BQUtFLGVBQTdDO0FBQ0Q7QUFDRixTQWxCSDtBQW9CRDtBQXhvQlU7QUFBQTtBQUFBLHlDQTBvQlNoQixLQTFvQlQsRUEwb0JnQjtBQUN6QkEsY0FBTUUsZUFBTjtBQUR5QixZQUVqQmUsZUFGaUIsR0FFRyxLQUFLekssS0FGUixDQUVqQnlLLGVBRmlCOztBQUFBLGlDQUdjLEtBQUs3RCxnQkFBTCxFQUhkO0FBQUEsWUFHakI4RCxPQUhpQixzQkFHakJBLE9BSGlCO0FBQUEsWUFHUlAsaUJBSFEsc0JBR1JBLGlCQUhROztBQUt6Qjs7O0FBQ0EsWUFBTVEsYUFBYUQsUUFBUXBILE1BQVIsQ0FBZTtBQUFBLGlCQUFLMEQsRUFBRTlFLEVBQUYsS0FBU2lJLGtCQUFrQmpJLEVBQWhDO0FBQUEsU0FBZixDQUFuQjs7QUFFQSxZQUFJOEgsY0FBSjs7QUFFQSxZQUFJUixNQUFNb0IsSUFBTixLQUFlLFdBQW5CLEVBQWdDO0FBQzlCWixrQkFBUVIsTUFBTVMsY0FBTixDQUFxQixDQUFyQixFQUF3QkQsS0FBaEM7QUFDRCxTQUZELE1BRU8sSUFBSVIsTUFBTW9CLElBQU4sS0FBZSxXQUFuQixFQUFnQztBQUNyQ1osa0JBQVFSLE1BQU1RLEtBQWQ7QUFDRDs7QUFFRDtBQUNBLFlBQU1hLFdBQVd0QyxLQUFLdUMsR0FBTCxDQUNmWCxrQkFBa0JSLFdBQWxCLEdBQWdDSyxLQUFoQyxHQUF3Q0csa0JBQWtCQyxNQUQzQyxFQUVmLEVBRmUsQ0FBakI7O0FBS0FPLG1CQUFXOUgsSUFBWCxDQUFnQjtBQUNkWCxjQUFJaUksa0JBQWtCakksRUFEUjtBQUVkNkQsaUJBQU84RTtBQUZPLFNBQWhCOztBQUtBLGFBQUs1QyxnQkFBTCxDQUNFO0FBQ0V5QyxtQkFBU0M7QUFEWCxTQURGLEVBSUUsWUFBTTtBQUNKRiw2QkFBbUJBLGdCQUFnQkUsVUFBaEIsRUFBNEJuQixLQUE1QixDQUFuQjtBQUNELFNBTkg7QUFRRDtBQTdxQlU7QUFBQTtBQUFBLHNDQStxQk1BLEtBL3FCTixFQStxQmE7QUFDdEJBLGNBQU1FLGVBQU47QUFDQSxZQUFJRCxVQUFVRCxNQUFNb0IsSUFBTixLQUFlLFVBQWYsSUFBNkJwQixNQUFNb0IsSUFBTixLQUFlLGFBQTFEOztBQUVBLFlBQUluQixPQUFKLEVBQWE7QUFDWFksbUJBQVNVLG1CQUFULENBQTZCLFdBQTdCLEVBQTBDLEtBQUtSLGtCQUEvQztBQUNBRixtQkFBU1UsbUJBQVQsQ0FBNkIsYUFBN0IsRUFBNEMsS0FBS1AsZUFBakQ7QUFDQUgsbUJBQVNVLG1CQUFULENBQTZCLFVBQTdCLEVBQXlDLEtBQUtQLGVBQTlDO0FBQ0Q7O0FBRUQ7QUFDQTtBQUNBSCxpQkFBU1UsbUJBQVQsQ0FBNkIsV0FBN0IsRUFBMEMsS0FBS1Isa0JBQS9DO0FBQ0FGLGlCQUFTVSxtQkFBVCxDQUE2QixTQUE3QixFQUF3QyxLQUFLUCxlQUE3QztBQUNBSCxpQkFBU1UsbUJBQVQsQ0FBNkIsWUFBN0IsRUFBMkMsS0FBS1AsZUFBaEQ7O0FBRUE7QUFDQTtBQUNBO0FBQ0EsWUFBSSxDQUFDZixPQUFMLEVBQWM7QUFDWixlQUFLeEIsZ0JBQUwsQ0FBc0I7QUFDcEJTLDBCQUFjLElBRE07QUFFcEJ5QiwrQkFBbUI7QUFGQyxXQUF0QjtBQUlEO0FBQ0Y7QUF4c0JVOztBQUFBO0FBQUEsSUFDQ2EsSUFERDtBQUFBLEMiLCJmaWxlIjoibWV0aG9kcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBSZWFjdCBmcm9tICdyZWFjdCdcbmltcG9ydCBfIGZyb20gJy4vdXRpbHMnXG5cbmV4cG9ydCBkZWZhdWx0IEJhc2UgPT5cbiAgY2xhc3MgZXh0ZW5kcyBCYXNlIHtcbiAgICBnZXRSZXNvbHZlZFN0YXRlIChwcm9wcywgc3RhdGUpIHtcbiAgICAgIGNvbnN0IHJlc29sdmVkU3RhdGUgPSB7XG4gICAgICAgIC4uLl8uY29tcGFjdE9iamVjdCh0aGlzLnN0YXRlKSxcbiAgICAgICAgLi4uXy5jb21wYWN0T2JqZWN0KHRoaXMucHJvcHMpLFxuICAgICAgICAuLi5fLmNvbXBhY3RPYmplY3Qoc3RhdGUpLFxuICAgICAgICAuLi5fLmNvbXBhY3RPYmplY3QocHJvcHMpLFxuICAgICAgfVxuICAgICAgcmV0dXJuIHJlc29sdmVkU3RhdGVcbiAgICB9XG5cbiAgICBnZXREYXRhTW9kZWwgKG5ld1N0YXRlKSB7XG4gICAgICBjb25zdCB7XG4gICAgICAgIGNvbHVtbnMsXG4gICAgICAgIHBpdm90QnkgPSBbXSxcbiAgICAgICAgZGF0YSxcbiAgICAgICAgcGl2b3RJREtleSxcbiAgICAgICAgcGl2b3RWYWxLZXksXG4gICAgICAgIHN1YlJvd3NLZXksXG4gICAgICAgIGFnZ3JlZ2F0ZWRLZXksXG4gICAgICAgIG5lc3RpbmdMZXZlbEtleSxcbiAgICAgICAgb3JpZ2luYWxLZXksXG4gICAgICAgIGluZGV4S2V5LFxuICAgICAgICBncm91cGVkQnlQaXZvdEtleSxcbiAgICAgICAgU3ViQ29tcG9uZW50LFxuICAgICAgfSA9IG5ld1N0YXRlXG5cbiAgICAgIC8vIERldGVybWluZSBIZWFkZXIgR3JvdXBzXG4gICAgICBsZXQgaGFzSGVhZGVyR3JvdXBzID0gZmFsc2VcbiAgICAgIGNvbHVtbnMuZm9yRWFjaChjb2x1bW4gPT4ge1xuICAgICAgICBpZiAoY29sdW1uLmNvbHVtbnMpIHtcbiAgICAgICAgICBoYXNIZWFkZXJHcm91cHMgPSB0cnVlXG4gICAgICAgIH1cbiAgICAgIH0pXG5cbiAgICAgIGxldCBjb2x1bW5zV2l0aEV4cGFuZGVyID0gWy4uLmNvbHVtbnNdXG5cbiAgICAgIGxldCBleHBhbmRlckNvbHVtbiA9IGNvbHVtbnMuZmluZChcbiAgICAgICAgY29sID0+XG4gICAgICAgICAgY29sLmV4cGFuZGVyIHx8XG4gICAgICAgICAgKGNvbC5jb2x1bW5zICYmIGNvbC5jb2x1bW5zLnNvbWUoY29sMiA9PiBjb2wyLmV4cGFuZGVyKSlcbiAgICAgIClcbiAgICAgIC8vIFRoZSBhY3R1YWwgZXhwYW5kZXIgbWlnaHQgYmUgaW4gdGhlIGNvbHVtbnMgZmllbGQgb2YgYSBncm91cCBjb2x1bW5cbiAgICAgIGlmIChleHBhbmRlckNvbHVtbiAmJiAhZXhwYW5kZXJDb2x1bW4uZXhwYW5kZXIpIHtcbiAgICAgICAgZXhwYW5kZXJDb2x1bW4gPSBleHBhbmRlckNvbHVtbi5jb2x1bW5zLmZpbmQoY29sID0+IGNvbC5leHBhbmRlcilcbiAgICAgIH1cblxuICAgICAgLy8gSWYgd2UgaGF2ZSBTdWJDb21wb25lbnQncyB3ZSBuZWVkIHRvIG1ha2Ugc3VyZSB3ZSBoYXZlIGFuIGV4cGFuZGVyIGNvbHVtblxuICAgICAgaWYgKFN1YkNvbXBvbmVudCAmJiAhZXhwYW5kZXJDb2x1bW4pIHtcbiAgICAgICAgZXhwYW5kZXJDb2x1bW4gPSB7IGV4cGFuZGVyOiB0cnVlIH1cbiAgICAgICAgY29sdW1uc1dpdGhFeHBhbmRlciA9IFtleHBhbmRlckNvbHVtbiwgLi4uY29sdW1uc1dpdGhFeHBhbmRlcl1cbiAgICAgIH1cblxuICAgICAgY29uc3QgbWFrZURlY29yYXRlZENvbHVtbiA9IChjb2x1bW4sIHBhcmVudENvbHVtbikgPT4ge1xuICAgICAgICBsZXQgZGNvbFxuICAgICAgICBpZiAoY29sdW1uLmV4cGFuZGVyKSB7XG4gICAgICAgICAgZGNvbCA9IHtcbiAgICAgICAgICAgIC4uLnRoaXMucHJvcHMuY29sdW1uLFxuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5leHBhbmRlckRlZmF1bHRzLFxuICAgICAgICAgICAgLi4uY29sdW1uLFxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBkY29sID0ge1xuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5jb2x1bW4sXG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgfVxuICAgICAgICB9XG5cbiAgICAgICAgLy8gRW5zdXJlIG1pbldpZHRoIGlzIG5vdCBncmVhdGVyIHRoYW4gbWF4V2lkdGggaWYgc2V0XG4gICAgICAgIGlmIChkY29sLm1heFdpZHRoIDwgZGNvbC5taW5XaWR0aCkge1xuICAgICAgICAgIGRjb2wubWluV2lkdGggPSBkY29sLm1heFdpZHRoXG4gICAgICAgIH1cblxuICAgICAgICBpZiAocGFyZW50Q29sdW1uKSB7XG4gICAgICAgICAgZGNvbC5wYXJlbnRDb2x1bW4gPSBwYXJlbnRDb2x1bW5cbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZpcnN0IGNoZWNrIGZvciBzdHJpbmcgYWNjZXNzb3JcbiAgICAgICAgaWYgKHR5cGVvZiBkY29sLmFjY2Vzc29yID09PSAnc3RyaW5nJykge1xuICAgICAgICAgIGRjb2wuaWQgPSBkY29sLmlkIHx8IGRjb2wuYWNjZXNzb3JcbiAgICAgICAgICBjb25zdCBhY2Nlc3NvclN0cmluZyA9IGRjb2wuYWNjZXNzb3JcbiAgICAgICAgICBkY29sLmFjY2Vzc29yID0gcm93ID0+IF8uZ2V0KHJvdywgYWNjZXNzb3JTdHJpbmcpXG4gICAgICAgICAgcmV0dXJuIGRjb2xcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZhbGwgYmFjayB0byBmdW5jdGlvbmFsIGFjY2Vzc29yIChidXQgcmVxdWlyZSBhbiBJRClcbiAgICAgICAgaWYgKGRjb2wuYWNjZXNzb3IgJiYgIWRjb2wuaWQpIHtcbiAgICAgICAgICBjb25zb2xlLndhcm4oZGNvbClcbiAgICAgICAgICB0aHJvdyBuZXcgRXJyb3IoXG4gICAgICAgICAgICAnQSBjb2x1bW4gaWQgaXMgcmVxdWlyZWQgaWYgdXNpbmcgYSBub24tc3RyaW5nIGFjY2Vzc29yIGZvciBjb2x1bW4gYWJvdmUuJ1xuICAgICAgICAgIClcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIEZhbGwgYmFjayB0byBhbiB1bmRlZmluZWQgYWNjZXNzb3JcbiAgICAgICAgaWYgKCFkY29sLmFjY2Vzc29yKSB7XG4gICAgICAgICAgZGNvbC5hY2Nlc3NvciA9IGQgPT4gdW5kZWZpbmVkXG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gZGNvbFxuICAgICAgfVxuXG4gICAgICAvLyBEZWNvcmF0ZSB0aGUgY29sdW1uc1xuICAgICAgY29uc3QgZGVjb3JhdGVBbmRBZGRUb0FsbCA9IChjb2x1bW4sIHBhcmVudENvbHVtbikgPT4ge1xuICAgICAgICBjb25zdCBkZWNvcmF0ZWRDb2x1bW4gPSBtYWtlRGVjb3JhdGVkQ29sdW1uKGNvbHVtbiwgcGFyZW50Q29sdW1uKVxuICAgICAgICBhbGxEZWNvcmF0ZWRDb2x1bW5zLnB1c2goZGVjb3JhdGVkQ29sdW1uKVxuICAgICAgICByZXR1cm4gZGVjb3JhdGVkQ29sdW1uXG4gICAgICB9XG4gICAgICBjb25zdCBhbGxEZWNvcmF0ZWRDb2x1bW5zID0gW11cbiAgICAgIGNvbnN0IGRlY29yYXRlZENvbHVtbnMgPSBjb2x1bW5zV2l0aEV4cGFuZGVyLm1hcCgoY29sdW1uLCBpKSA9PiB7XG4gICAgICAgIGlmIChjb2x1bW4uY29sdW1ucykge1xuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgICBjb2x1bW5zOiBjb2x1bW4uY29sdW1ucy5tYXAoZCA9PiBkZWNvcmF0ZUFuZEFkZFRvQWxsKGQsIGNvbHVtbikpLFxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICByZXR1cm4gZGVjb3JhdGVBbmRBZGRUb0FsbChjb2x1bW4pXG4gICAgICAgIH1cbiAgICAgIH0pXG5cbiAgICAgIC8vIEJ1aWxkIHRoZSB2aXNpYmxlIGNvbHVtbnMsIGhlYWRlcnMgYW5kIGZsYXQgY29sdW1uIGxpc3RcbiAgICAgIGxldCB2aXNpYmxlQ29sdW1ucyA9IGRlY29yYXRlZENvbHVtbnMuc2xpY2UoKVxuICAgICAgbGV0IGFsbFZpc2libGVDb2x1bW5zID0gW11cblxuICAgICAgdmlzaWJsZUNvbHVtbnMgPSB2aXNpYmxlQ29sdW1ucy5tYXAoKGNvbHVtbiwgaSkgPT4ge1xuICAgICAgICBpZiAoY29sdW1uLmNvbHVtbnMpIHtcbiAgICAgICAgICBjb25zdCB2aXNpYmxlU3ViQ29sdW1ucyA9IGNvbHVtbi5jb2x1bW5zLmZpbHRlcihcbiAgICAgICAgICAgIGQgPT5cbiAgICAgICAgICAgICAgcGl2b3RCeS5pbmRleE9mKGQuaWQpID4gLTFcbiAgICAgICAgICAgICAgICA/IGZhbHNlXG4gICAgICAgICAgICAgICAgOiBfLmdldEZpcnN0RGVmaW5lZChkLnNob3csIHRydWUpXG4gICAgICAgICAgKVxuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAuLi5jb2x1bW4sXG4gICAgICAgICAgICBjb2x1bW5zOiB2aXNpYmxlU3ViQ29sdW1ucyxcbiAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGNvbHVtblxuICAgICAgfSlcblxuICAgICAgdmlzaWJsZUNvbHVtbnMgPSB2aXNpYmxlQ29sdW1ucy5maWx0ZXIoY29sdW1uID0+IHtcbiAgICAgICAgcmV0dXJuIGNvbHVtbi5jb2x1bW5zXG4gICAgICAgICAgPyBjb2x1bW4uY29sdW1ucy5sZW5ndGhcbiAgICAgICAgICA6IHBpdm90QnkuaW5kZXhPZihjb2x1bW4uaWQpID4gLTFcbiAgICAgICAgICAgID8gZmFsc2VcbiAgICAgICAgICAgIDogXy5nZXRGaXJzdERlZmluZWQoY29sdW1uLnNob3csIHRydWUpXG4gICAgICB9KVxuXG4gICAgICAvLyBGaW5kIGFueSBjdXN0b20gcGl2b3QgbG9jYXRpb25cbiAgICAgIGNvbnN0IHBpdm90SW5kZXggPSB2aXNpYmxlQ29sdW1ucy5maW5kSW5kZXgoY29sID0+IGNvbC5waXZvdClcblxuICAgICAgLy8gSGFuZGxlIFBpdm90IENvbHVtbnNcbiAgICAgIGlmIChwaXZvdEJ5Lmxlbmd0aCkge1xuICAgICAgICAvLyBSZXRyaWV2ZSB0aGUgcGl2b3QgY29sdW1ucyBpbiB0aGUgY29ycmVjdCBwaXZvdCBvcmRlclxuICAgICAgICBjb25zdCBwaXZvdENvbHVtbnMgPSBbXVxuICAgICAgICBwaXZvdEJ5LmZvckVhY2gocGl2b3RJRCA9PiB7XG4gICAgICAgICAgY29uc3QgZm91bmQgPSBhbGxEZWNvcmF0ZWRDb2x1bW5zLmZpbmQoZCA9PiBkLmlkID09PSBwaXZvdElEKVxuICAgICAgICAgIGlmIChmb3VuZCkge1xuICAgICAgICAgICAgcGl2b3RDb2x1bW5zLnB1c2goZm91bmQpXG4gICAgICAgICAgfVxuICAgICAgICB9KVxuXG4gICAgICAgIGxldCBQaXZvdFBhcmVudENvbHVtbiA9IHBpdm90Q29sdW1ucy5yZWR1Y2UoXG4gICAgICAgICAgKHByZXYsIGN1cnJlbnQpID0+XG4gICAgICAgICAgICBwcmV2ICYmIHByZXYgPT09IGN1cnJlbnQucGFyZW50Q29sdW1uICYmIGN1cnJlbnQucGFyZW50Q29sdW1uLFxuICAgICAgICAgIHBpdm90Q29sdW1uc1swXS5wYXJlbnRDb2x1bW5cbiAgICAgICAgKVxuXG4gICAgICAgIGxldCBQaXZvdEdyb3VwSGVhZGVyID0gaGFzSGVhZGVyR3JvdXBzICYmIFBpdm90UGFyZW50Q29sdW1uLkhlYWRlclxuICAgICAgICBQaXZvdEdyb3VwSGVhZGVyID0gUGl2b3RHcm91cEhlYWRlciB8fCAoKCkgPT4gPHN0cm9uZz5QaXZvdGVkPC9zdHJvbmc+KVxuXG4gICAgICAgIGxldCBwaXZvdENvbHVtbkdyb3VwID0ge1xuICAgICAgICAgIEhlYWRlcjogUGl2b3RHcm91cEhlYWRlcixcbiAgICAgICAgICBjb2x1bW5zOiBwaXZvdENvbHVtbnMubWFwKGNvbCA9PiAoe1xuICAgICAgICAgICAgLi4udGhpcy5wcm9wcy5waXZvdERlZmF1bHRzLFxuICAgICAgICAgICAgLi4uY29sLFxuICAgICAgICAgICAgcGl2b3RlZDogdHJ1ZSxcbiAgICAgICAgICB9KSksXG4gICAgICAgIH1cblxuICAgICAgICAvLyBQbGFjZSB0aGUgcGl2b3RDb2x1bW5zIGJhY2sgaW50byB0aGUgdmlzaWJsZUNvbHVtbnNcbiAgICAgICAgaWYgKHBpdm90SW5kZXggPj0gMCkge1xuICAgICAgICAgIHBpdm90Q29sdW1uR3JvdXAgPSB7XG4gICAgICAgICAgICAuLi52aXNpYmxlQ29sdW1uc1twaXZvdEluZGV4XSxcbiAgICAgICAgICAgIC4uLnBpdm90Q29sdW1uR3JvdXAsXG4gICAgICAgICAgfVxuICAgICAgICAgIHZpc2libGVDb2x1bW5zLnNwbGljZShwaXZvdEluZGV4LCAxLCBwaXZvdENvbHVtbkdyb3VwKVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgIHZpc2libGVDb2x1bW5zLnVuc2hpZnQocGl2b3RDb2x1bW5Hcm91cClcbiAgICAgICAgfVxuICAgICAgfVxuXG4gICAgICAvLyBCdWlsZCBIZWFkZXIgR3JvdXBzXG4gICAgICBjb25zdCBoZWFkZXJHcm91cHMgPSBbXVxuICAgICAgbGV0IGN1cnJlbnRTcGFuID0gW11cblxuICAgICAgLy8gQSBjb252ZW5pZW5jZSBmdW5jdGlvbiB0byBhZGQgYSBoZWFkZXIgYW5kIHJlc2V0IHRoZSBjdXJyZW50U3BhblxuICAgICAgY29uc3QgYWRkSGVhZGVyID0gKGNvbHVtbnMsIGNvbHVtbikgPT4ge1xuICAgICAgICBoZWFkZXJHcm91cHMucHVzaCh7XG4gICAgICAgICAgLi4udGhpcy5wcm9wcy5jb2x1bW4sXG4gICAgICAgICAgLi4uY29sdW1uLFxuICAgICAgICAgIGNvbHVtbnM6IGNvbHVtbnMsXG4gICAgICAgIH0pXG4gICAgICAgIGN1cnJlbnRTcGFuID0gW11cbiAgICAgIH1cblxuICAgICAgLy8gQnVpbGQgZmxhc3QgbGlzdCBvZiBhbGxWaXNpYmxlQ29sdW1ucyBhbmQgSGVhZGVyR3JvdXBzXG4gICAgICB2aXNpYmxlQ29sdW1ucy5mb3JFYWNoKChjb2x1bW4sIGkpID0+IHtcbiAgICAgICAgaWYgKGNvbHVtbi5jb2x1bW5zKSB7XG4gICAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMgPSBhbGxWaXNpYmxlQ29sdW1ucy5jb25jYXQoY29sdW1uLmNvbHVtbnMpXG4gICAgICAgICAgaWYgKGN1cnJlbnRTcGFuLmxlbmd0aCA+IDApIHtcbiAgICAgICAgICAgIGFkZEhlYWRlcihjdXJyZW50U3BhbilcbiAgICAgICAgICB9XG4gICAgICAgICAgYWRkSGVhZGVyKGNvbHVtbi5jb2x1bW5zLCBjb2x1bW4pXG4gICAgICAgICAgcmV0dXJuXG4gICAgICAgIH1cbiAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMucHVzaChjb2x1bW4pXG4gICAgICAgIGN1cnJlbnRTcGFuLnB1c2goY29sdW1uKVxuICAgICAgfSlcbiAgICAgIGlmIChoYXNIZWFkZXJHcm91cHMgJiYgY3VycmVudFNwYW4ubGVuZ3RoID4gMCkge1xuICAgICAgICBhZGRIZWFkZXIoY3VycmVudFNwYW4pXG4gICAgICB9XG5cbiAgICAgIC8vIEFjY2VzcyB0aGUgZGF0YVxuICAgICAgY29uc3QgYWNjZXNzUm93ID0gKGQsIGksIGxldmVsID0gMCkgPT4ge1xuICAgICAgICBjb25zdCByb3cgPSB7XG4gICAgICAgICAgW29yaWdpbmFsS2V5XTogZCxcbiAgICAgICAgICBbaW5kZXhLZXldOiBpLFxuICAgICAgICAgIFtzdWJSb3dzS2V5XTogZFtzdWJSb3dzS2V5XSxcbiAgICAgICAgICBbbmVzdGluZ0xldmVsS2V5XTogbGV2ZWwsXG4gICAgICAgIH1cbiAgICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucy5mb3JFYWNoKGNvbHVtbiA9PiB7XG4gICAgICAgICAgaWYgKGNvbHVtbi5leHBhbmRlcikgcmV0dXJuXG4gICAgICAgICAgcm93W2NvbHVtbi5pZF0gPSBjb2x1bW4uYWNjZXNzb3IoZClcbiAgICAgICAgfSlcbiAgICAgICAgaWYgKHJvd1tzdWJSb3dzS2V5XSkge1xuICAgICAgICAgIHJvd1tzdWJSb3dzS2V5XSA9IHJvd1tzdWJSb3dzS2V5XS5tYXAoKGQsIGkpID0+XG4gICAgICAgICAgICBhY2Nlc3NSb3coZCwgaSwgbGV2ZWwgKyAxKVxuICAgICAgICAgIClcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gcm93XG4gICAgICB9XG4gICAgICBsZXQgcmVzb2x2ZWREYXRhID0gZGF0YS5tYXAoKGQsIGkpID0+IGFjY2Vzc1JvdyhkLCBpKSlcblxuICAgICAgLy8gSWYgcGl2b3RpbmcsIHJlY3Vyc2l2ZWx5IGdyb3VwIHRoZSBkYXRhXG4gICAgICBjb25zdCBhZ2dyZWdhdGUgPSByb3dzID0+IHtcbiAgICAgICAgY29uc3QgYWdncmVnYXRpb25WYWx1ZXMgPSB7fVxuICAgICAgICBhZ2dyZWdhdGluZ0NvbHVtbnMuZm9yRWFjaChjb2x1bW4gPT4ge1xuICAgICAgICAgIGNvbnN0IHZhbHVlcyA9IHJvd3MubWFwKGQgPT4gZFtjb2x1bW4uaWRdKVxuICAgICAgICAgIGFnZ3JlZ2F0aW9uVmFsdWVzW2NvbHVtbi5pZF0gPSBjb2x1bW4uYWdncmVnYXRlKHZhbHVlcywgcm93cylcbiAgICAgICAgfSlcbiAgICAgICAgcmV0dXJuIGFnZ3JlZ2F0aW9uVmFsdWVzXG4gICAgICB9XG5cbiAgICAgIC8vIFRPRE86IE1ha2UgaXQgcG9zc2libGUgdG8gZmFicmljYXRlIG5lc3RlZCByb3dzIHdpdGhvdXQgcGl2b3RpbmdcbiAgICAgIGNvbnN0IGFnZ3JlZ2F0aW5nQ29sdW1ucyA9IGFsbFZpc2libGVDb2x1bW5zLmZpbHRlcihcbiAgICAgICAgZCA9PiAhZC5leHBhbmRlciAmJiBkLmFnZ3JlZ2F0ZVxuICAgICAgKVxuICAgICAgaWYgKHBpdm90QnkubGVuZ3RoKSB7XG4gICAgICAgIGNvbnN0IGdyb3VwUmVjdXJzaXZlbHkgPSAocm93cywga2V5cywgaSA9IDApID0+IHtcbiAgICAgICAgICAvLyBUaGlzIGlzIHRoZSBsYXN0IGxldmVsLCBqdXN0IHJldHVybiB0aGUgcm93c1xuICAgICAgICAgIGlmIChpID09PSBrZXlzLmxlbmd0aCkge1xuICAgICAgICAgICAgcmV0dXJuIHJvd3NcbiAgICAgICAgICB9XG4gICAgICAgICAgLy8gR3JvdXAgdGhlIHJvd3MgdG9nZXRoZXIgZm9yIHRoaXMgbGV2ZWxcbiAgICAgICAgICBsZXQgZ3JvdXBlZFJvd3MgPSBPYmplY3QuZW50cmllcyhcbiAgICAgICAgICAgIF8uZ3JvdXBCeShyb3dzLCBrZXlzW2ldKVxuICAgICAgICAgICkubWFwKChba2V5LCB2YWx1ZV0pID0+IHtcbiAgICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAgIFtwaXZvdElES2V5XToga2V5c1tpXSxcbiAgICAgICAgICAgICAgW3Bpdm90VmFsS2V5XToga2V5LFxuICAgICAgICAgICAgICBba2V5c1tpXV06IGtleSxcbiAgICAgICAgICAgICAgW3N1YlJvd3NLZXldOiB2YWx1ZSxcbiAgICAgICAgICAgICAgW25lc3RpbmdMZXZlbEtleV06IGksXG4gICAgICAgICAgICAgIFtncm91cGVkQnlQaXZvdEtleV06IHRydWUsXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcbiAgICAgICAgICAvLyBSZWN1cnNlIGludG8gdGhlIHN1YlJvd3NcbiAgICAgICAgICBncm91cGVkUm93cyA9IGdyb3VwZWRSb3dzLm1hcChyb3dHcm91cCA9PiB7XG4gICAgICAgICAgICBsZXQgc3ViUm93cyA9IGdyb3VwUmVjdXJzaXZlbHkocm93R3JvdXBbc3ViUm93c0tleV0sIGtleXMsIGkgKyAxKVxuICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgLi4ucm93R3JvdXAsXG4gICAgICAgICAgICAgIFtzdWJSb3dzS2V5XTogc3ViUm93cyxcbiAgICAgICAgICAgICAgW2FnZ3JlZ2F0ZWRLZXldOiB0cnVlLFxuICAgICAgICAgICAgICAuLi5hZ2dyZWdhdGUoc3ViUm93cyksXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcbiAgICAgICAgICByZXR1cm4gZ3JvdXBlZFJvd3NcbiAgICAgICAgfVxuICAgICAgICByZXNvbHZlZERhdGEgPSBncm91cFJlY3Vyc2l2ZWx5KHJlc29sdmVkRGF0YSwgcGl2b3RCeSlcbiAgICAgIH1cblxuICAgICAgcmV0dXJuIHtcbiAgICAgICAgLi4ubmV3U3RhdGUsXG4gICAgICAgIHJlc29sdmVkRGF0YSxcbiAgICAgICAgYWxsVmlzaWJsZUNvbHVtbnMsXG4gICAgICAgIGhlYWRlckdyb3VwcyxcbiAgICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucyxcbiAgICAgICAgaGFzSGVhZGVyR3JvdXBzLFxuICAgICAgfVxuICAgIH1cblxuICAgIGdldFNvcnRlZERhdGEgKHJlc29sdmVkU3RhdGUpIHtcbiAgICAgIGNvbnN0IHtcbiAgICAgICAgbWFudWFsLFxuICAgICAgICBzb3J0ZWQsXG4gICAgICAgIGZpbHRlcmVkLFxuICAgICAgICBkZWZhdWx0RmlsdGVyTWV0aG9kLFxuICAgICAgICByZXNvbHZlZERhdGEsXG4gICAgICAgIGFsbFZpc2libGVDb2x1bW5zLFxuICAgICAgICBhbGxEZWNvcmF0ZWRDb2x1bW5zLFxuICAgICAgfSA9IHJlc29sdmVkU3RhdGVcblxuICAgICAgY29uc3Qgc29ydE1ldGhvZHNCeUNvbHVtbklEID0ge31cblxuICAgICAgYWxsRGVjb3JhdGVkQ29sdW1ucy5maWx0ZXIoY29sID0+IGNvbC5zb3J0TWV0aG9kKS5mb3JFYWNoKGNvbCA9PiB7XG4gICAgICAgIHNvcnRNZXRob2RzQnlDb2x1bW5JRFtjb2wuaWRdID0gY29sLnNvcnRNZXRob2RcbiAgICAgIH0pXG5cbiAgICAgIC8vIFJlc29sdmUgdGhlIGRhdGEgZnJvbSBlaXRoZXIgbWFudWFsIGRhdGEgb3Igc29ydGVkIGRhdGFcbiAgICAgIHJldHVybiB7XG4gICAgICAgIHNvcnRlZERhdGE6IG1hbnVhbFxuICAgICAgICAgID8gcmVzb2x2ZWREYXRhXG4gICAgICAgICAgOiB0aGlzLnNvcnREYXRhKFxuICAgICAgICAgICAgdGhpcy5maWx0ZXJEYXRhKFxuICAgICAgICAgICAgICByZXNvbHZlZERhdGEsXG4gICAgICAgICAgICAgIGZpbHRlcmVkLFxuICAgICAgICAgICAgICBkZWZhdWx0RmlsdGVyTWV0aG9kLFxuICAgICAgICAgICAgICBhbGxWaXNpYmxlQ29sdW1uc1xuICAgICAgICAgICAgKSxcbiAgICAgICAgICAgIHNvcnRlZCxcbiAgICAgICAgICAgIHNvcnRNZXRob2RzQnlDb2x1bW5JRFxuICAgICAgICAgICksXG4gICAgICB9XG4gICAgfVxuXG4gICAgZmlyZUZldGNoRGF0YSAoKSB7XG4gICAgICB0aGlzLnByb3BzLm9uRmV0Y2hEYXRhKHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpLCB0aGlzKVxuICAgIH1cblxuICAgIGdldFByb3BPclN0YXRlIChrZXkpIHtcbiAgICAgIHJldHVybiBfLmdldEZpcnN0RGVmaW5lZCh0aGlzLnByb3BzW2tleV0sIHRoaXMuc3RhdGVba2V5XSlcbiAgICB9XG5cbiAgICBnZXRTdGF0ZU9yUHJvcCAoa2V5KSB7XG4gICAgICByZXR1cm4gXy5nZXRGaXJzdERlZmluZWQodGhpcy5zdGF0ZVtrZXldLCB0aGlzLnByb3BzW2tleV0pXG4gICAgfVxuXG4gICAgZmlsdGVyRGF0YSAoZGF0YSwgZmlsdGVyZWQsIGRlZmF1bHRGaWx0ZXJNZXRob2QsIGFsbFZpc2libGVDb2x1bW5zKSB7XG4gICAgICBsZXQgZmlsdGVyZWREYXRhID0gZGF0YVxuXG4gICAgICBpZiAoZmlsdGVyZWQubGVuZ3RoKSB7XG4gICAgICAgIGZpbHRlcmVkRGF0YSA9IGZpbHRlcmVkLnJlZHVjZSgoZmlsdGVyZWRTb0ZhciwgbmV4dEZpbHRlcikgPT4ge1xuICAgICAgICAgIGNvbnN0IGNvbHVtbiA9IGFsbFZpc2libGVDb2x1bW5zLmZpbmQoeCA9PiB4LmlkID09PSBuZXh0RmlsdGVyLmlkKVxuXG4gICAgICAgICAgLy8gRG9uJ3QgZmlsdGVyIGhpZGRlbiBjb2x1bW5zIG9yIGNvbHVtbnMgdGhhdCBoYXZlIGhhZCB0aGVpciBmaWx0ZXJzIGRpc2FibGVkXG4gICAgICAgICAgaWYgKCFjb2x1bW4gfHwgY29sdW1uLmZpbHRlcmFibGUgPT09IGZhbHNlKSB7XG4gICAgICAgICAgICByZXR1cm4gZmlsdGVyZWRTb0ZhclxuICAgICAgICAgIH1cblxuICAgICAgICAgIGNvbnN0IGZpbHRlck1ldGhvZCA9IGNvbHVtbi5maWx0ZXJNZXRob2QgfHwgZGVmYXVsdEZpbHRlck1ldGhvZFxuXG4gICAgICAgICAgLy8gSWYgJ2ZpbHRlckFsbCcgaXMgc2V0IHRvIHRydWUsIHBhc3MgdGhlIGVudGlyZSBkYXRhc2V0IHRvIHRoZSBmaWx0ZXIgbWV0aG9kXG4gICAgICAgICAgaWYgKGNvbHVtbi5maWx0ZXJBbGwpIHtcbiAgICAgICAgICAgIHJldHVybiBmaWx0ZXJNZXRob2QobmV4dEZpbHRlciwgZmlsdGVyZWRTb0ZhciwgY29sdW1uKVxuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICByZXR1cm4gZmlsdGVyZWRTb0Zhci5maWx0ZXIocm93ID0+IHtcbiAgICAgICAgICAgICAgcmV0dXJuIGZpbHRlck1ldGhvZChuZXh0RmlsdGVyLCByb3csIGNvbHVtbilcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICB9LCBmaWx0ZXJlZERhdGEpXG5cbiAgICAgICAgLy8gQXBwbHkgdGhlIGZpbHRlciB0byB0aGUgc3Vicm93cyBpZiB3ZSBhcmUgcGl2b3RpbmcsIGFuZCB0aGVuXG4gICAgICAgIC8vIGZpbHRlciBhbnkgcm93cyB3aXRob3V0IHN1YmNvbHVtbnMgYmVjYXVzZSBpdCB3b3VsZCBiZSBzdHJhbmdlIHRvIHNob3dcbiAgICAgICAgZmlsdGVyZWREYXRhID0gZmlsdGVyZWREYXRhXG4gICAgICAgICAgLm1hcChyb3cgPT4ge1xuICAgICAgICAgICAgaWYgKCFyb3dbdGhpcy5wcm9wcy5zdWJSb3dzS2V5XSkge1xuICAgICAgICAgICAgICByZXR1cm4gcm93XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICAuLi5yb3csXG4gICAgICAgICAgICAgIFt0aGlzLnByb3BzLnN1YlJvd3NLZXldOiB0aGlzLmZpbHRlckRhdGEoXG4gICAgICAgICAgICAgICAgcm93W3RoaXMucHJvcHMuc3ViUm93c0tleV0sXG4gICAgICAgICAgICAgICAgZmlsdGVyZWQsXG4gICAgICAgICAgICAgICAgZGVmYXVsdEZpbHRlck1ldGhvZCxcbiAgICAgICAgICAgICAgICBhbGxWaXNpYmxlQ29sdW1uc1xuICAgICAgICAgICAgICApLFxuICAgICAgICAgICAgfVxuICAgICAgICAgIH0pXG4gICAgICAgICAgLmZpbHRlcihyb3cgPT4ge1xuICAgICAgICAgICAgaWYgKCFyb3dbdGhpcy5wcm9wcy5zdWJSb3dzS2V5XSkge1xuICAgICAgICAgICAgICByZXR1cm4gdHJ1ZVxuICAgICAgICAgICAgfVxuICAgICAgICAgICAgcmV0dXJuIHJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldLmxlbmd0aCA+IDBcbiAgICAgICAgICB9KVxuICAgICAgfVxuXG4gICAgICByZXR1cm4gZmlsdGVyZWREYXRhXG4gICAgfVxuXG4gICAgc29ydERhdGEgKGRhdGEsIHNvcnRlZCwgc29ydE1ldGhvZHNCeUNvbHVtbklEID0ge30pIHtcbiAgICAgIGlmICghc29ydGVkLmxlbmd0aCkge1xuICAgICAgICByZXR1cm4gZGF0YVxuICAgICAgfVxuXG4gICAgICBjb25zdCBzb3J0ZWREYXRhID0gKHRoaXMucHJvcHMub3JkZXJCeU1ldGhvZCB8fCBfLm9yZGVyQnkpKFxuICAgICAgICBkYXRhLFxuICAgICAgICBzb3J0ZWQubWFwKHNvcnQgPT4ge1xuICAgICAgICAgIC8vIFN1cHBvcnQgY3VzdG9tIHNvcnRpbmcgbWV0aG9kcyBmb3IgZWFjaCBjb2x1bW5cbiAgICAgICAgICBpZiAoc29ydE1ldGhvZHNCeUNvbHVtbklEW3NvcnQuaWRdKSB7XG4gICAgICAgICAgICByZXR1cm4gKGEsIGIpID0+IHtcbiAgICAgICAgICAgICAgcmV0dXJuIHNvcnRNZXRob2RzQnlDb2x1bW5JRFtzb3J0LmlkXShhW3NvcnQuaWRdLCBiW3NvcnQuaWRdKVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH1cbiAgICAgICAgICByZXR1cm4gKGEsIGIpID0+IHtcbiAgICAgICAgICAgIHJldHVybiB0aGlzLnByb3BzLmRlZmF1bHRTb3J0TWV0aG9kKGFbc29ydC5pZF0sIGJbc29ydC5pZF0pXG4gICAgICAgICAgfVxuICAgICAgICB9KSxcbiAgICAgICAgc29ydGVkLm1hcChkID0+ICFkLmRlc2MpLFxuICAgICAgICB0aGlzLnByb3BzLmluZGV4S2V5XG4gICAgICApXG5cbiAgICAgIHNvcnRlZERhdGEuZm9yRWFjaChyb3cgPT4ge1xuICAgICAgICBpZiAoIXJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldKSB7XG4gICAgICAgICAgcmV0dXJuXG4gICAgICAgIH1cbiAgICAgICAgcm93W3RoaXMucHJvcHMuc3ViUm93c0tleV0gPSB0aGlzLnNvcnREYXRhKFxuICAgICAgICAgIHJvd1t0aGlzLnByb3BzLnN1YlJvd3NLZXldLFxuICAgICAgICAgIHNvcnRlZCxcbiAgICAgICAgICBzb3J0TWV0aG9kc0J5Q29sdW1uSURcbiAgICAgICAgKVxuICAgICAgfSlcblxuICAgICAgcmV0dXJuIHNvcnRlZERhdGFcbiAgICB9XG5cbiAgICBnZXRNaW5Sb3dzICgpIHtcbiAgICAgIHJldHVybiBfLmdldEZpcnN0RGVmaW5lZChcbiAgICAgICAgdGhpcy5wcm9wcy5taW5Sb3dzLFxuICAgICAgICB0aGlzLmdldFN0YXRlT3JQcm9wKCdwYWdlU2l6ZScpXG4gICAgICApXG4gICAgfVxuXG4gICAgLy8gVXNlciBhY3Rpb25zXG4gICAgb25QYWdlQ2hhbmdlIChwYWdlKSB7XG4gICAgICBjb25zdCB7IG9uUGFnZUNoYW5nZSwgY29sbGFwc2VPblBhZ2VDaGFuZ2UgfSA9IHRoaXMucHJvcHNcblxuICAgICAgY29uc3QgbmV3U3RhdGUgPSB7IHBhZ2UgfVxuICAgICAgaWYgKGNvbGxhcHNlT25QYWdlQ2hhbmdlKSB7XG4gICAgICAgIG5ld1N0YXRlLmV4cGFuZGVkID0ge31cbiAgICAgIH1cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShuZXdTdGF0ZSwgKCkgPT4ge1xuICAgICAgICBvblBhZ2VDaGFuZ2UgJiYgb25QYWdlQ2hhbmdlKHBhZ2UpXG4gICAgICB9KVxuICAgIH1cblxuICAgIG9uUGFnZVNpemVDaGFuZ2UgKG5ld1BhZ2VTaXplKSB7XG4gICAgICBjb25zdCB7IG9uUGFnZVNpemVDaGFuZ2UgfSA9IHRoaXMucHJvcHNcbiAgICAgIGNvbnN0IHsgcGFnZVNpemUsIHBhZ2UgfSA9IHRoaXMuZ2V0UmVzb2x2ZWRTdGF0ZSgpXG5cbiAgICAgIC8vIE5vcm1hbGl6ZSB0aGUgcGFnZSB0byBkaXNwbGF5XG4gICAgICBjb25zdCBjdXJyZW50Um93ID0gcGFnZVNpemUgKiBwYWdlXG4gICAgICBjb25zdCBuZXdQYWdlID0gTWF0aC5mbG9vcihjdXJyZW50Um93IC8gbmV3UGFnZVNpemUpXG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHBhZ2VTaXplOiBuZXdQYWdlU2l6ZSxcbiAgICAgICAgICBwYWdlOiBuZXdQYWdlLFxuICAgICAgICB9LFxuICAgICAgICAoKSA9PiB7XG4gICAgICAgICAgb25QYWdlU2l6ZUNoYW5nZSAmJiBvblBhZ2VTaXplQ2hhbmdlKG5ld1BhZ2VTaXplLCBuZXdQYWdlKVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgc29ydENvbHVtbiAoY29sdW1uLCBhZGRpdGl2ZSkge1xuICAgICAgY29uc3QgeyBzb3J0ZWQsIHNraXBOZXh0U29ydCwgZGVmYXVsdFNvcnREZXNjIH0gPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuXG4gICAgICBjb25zdCBmaXJzdFNvcnREaXJlY3Rpb24gPSBjb2x1bW4uaGFzT3duUHJvcGVydHkoJ2RlZmF1bHRTb3J0RGVzYycpXG4gICAgICAgID8gY29sdW1uLmRlZmF1bHRTb3J0RGVzY1xuICAgICAgICA6IGRlZmF1bHRTb3J0RGVzY1xuICAgICAgY29uc3Qgc2Vjb25kU29ydERpcmVjdGlvbiA9ICFmaXJzdFNvcnREaXJlY3Rpb25cblxuICAgICAgLy8gd2UgY2FuJ3Qgc3RvcCBldmVudCBwcm9wYWdhdGlvbiBmcm9tIHRoZSBjb2x1bW4gcmVzaXplIG1vdmUgaGFuZGxlcnNcbiAgICAgIC8vIGF0dGFjaGVkIHRvIHRoZSBkb2N1bWVudCBiZWNhdXNlIG9mIHJlYWN0J3Mgc3ludGhldGljIGV2ZW50c1xuICAgICAgLy8gc28gd2UgaGF2ZSB0byBwcmV2ZW50IHRoZSBzb3J0IGZ1bmN0aW9uIGZyb20gYWN0dWFsbHkgc29ydGluZ1xuICAgICAgLy8gaWYgd2UgY2xpY2sgb24gdGhlIGNvbHVtbiByZXNpemUgZWxlbWVudCB3aXRoaW4gYSBoZWFkZXIuXG4gICAgICBpZiAoc2tpcE5leHRTb3J0KSB7XG4gICAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YSh7XG4gICAgICAgICAgc2tpcE5leHRTb3J0OiBmYWxzZSxcbiAgICAgICAgfSlcbiAgICAgICAgcmV0dXJuXG4gICAgICB9XG5cbiAgICAgIGNvbnN0IHsgb25Tb3J0ZWRDaGFuZ2UgfSA9IHRoaXMucHJvcHNcblxuICAgICAgbGV0IG5ld1NvcnRlZCA9IF8uY2xvbmUoc29ydGVkIHx8IFtdKS5tYXAoZCA9PiB7XG4gICAgICAgIGQuZGVzYyA9IF8uaXNTb3J0aW5nRGVzYyhkKVxuICAgICAgICByZXR1cm4gZFxuICAgICAgfSlcbiAgICAgIGlmICghXy5pc0FycmF5KGNvbHVtbikpIHtcbiAgICAgICAgLy8gU2luZ2xlLVNvcnRcbiAgICAgICAgY29uc3QgZXhpc3RpbmdJbmRleCA9IG5ld1NvcnRlZC5maW5kSW5kZXgoZCA9PiBkLmlkID09PSBjb2x1bW4uaWQpXG4gICAgICAgIGlmIChleGlzdGluZ0luZGV4ID4gLTEpIHtcbiAgICAgICAgICBjb25zdCBleGlzdGluZyA9IG5ld1NvcnRlZFtleGlzdGluZ0luZGV4XVxuICAgICAgICAgIGlmIChleGlzdGluZy5kZXNjID09PSBzZWNvbmRTb3J0RGlyZWN0aW9uKSB7XG4gICAgICAgICAgICBpZiAoYWRkaXRpdmUpIHtcbiAgICAgICAgICAgICAgbmV3U29ydGVkLnNwbGljZShleGlzdGluZ0luZGV4LCAxKVxuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgZXhpc3RpbmcuZGVzYyA9IGZpcnN0U29ydERpcmVjdGlvblxuICAgICAgICAgICAgICBuZXdTb3J0ZWQgPSBbZXhpc3RpbmddXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGV4aXN0aW5nLmRlc2MgPSBzZWNvbmRTb3J0RGlyZWN0aW9uXG4gICAgICAgICAgICBpZiAoIWFkZGl0aXZlKSB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZCA9IFtleGlzdGluZ11cbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgaWYgKGFkZGl0aXZlKSB7XG4gICAgICAgICAgICBuZXdTb3J0ZWQucHVzaCh7XG4gICAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICAgIGRlc2M6IGZpcnN0U29ydERpcmVjdGlvbixcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IFtcbiAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICAgICAgZGVzYzogZmlyc3RTb3J0RGlyZWN0aW9uLFxuICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgXVxuICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgfSBlbHNlIHtcbiAgICAgICAgLy8gTXVsdGktU29ydFxuICAgICAgICBjb25zdCBleGlzdGluZ0luZGV4ID0gbmV3U29ydGVkLmZpbmRJbmRleChkID0+IGQuaWQgPT09IGNvbHVtblswXS5pZClcbiAgICAgICAgLy8gRXhpc3RpbmcgU29ydGVkIENvbHVtblxuICAgICAgICBpZiAoZXhpc3RpbmdJbmRleCA+IC0xKSB7XG4gICAgICAgICAgY29uc3QgZXhpc3RpbmcgPSBuZXdTb3J0ZWRbZXhpc3RpbmdJbmRleF1cbiAgICAgICAgICBpZiAoZXhpc3RpbmcuZGVzYyA9PT0gc2Vjb25kU29ydERpcmVjdGlvbikge1xuICAgICAgICAgICAgaWYgKGFkZGl0aXZlKSB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZC5zcGxpY2UoZXhpc3RpbmdJbmRleCwgY29sdW1uLmxlbmd0aClcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIGNvbHVtbi5mb3JFYWNoKChkLCBpKSA9PiB7XG4gICAgICAgICAgICAgICAgbmV3U29ydGVkW2V4aXN0aW5nSW5kZXggKyBpXS5kZXNjID0gZmlyc3RTb3J0RGlyZWN0aW9uXG4gICAgICAgICAgICAgIH0pXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIGNvbHVtbi5mb3JFYWNoKChkLCBpKSA9PiB7XG4gICAgICAgICAgICAgIG5ld1NvcnRlZFtleGlzdGluZ0luZGV4ICsgaV0uZGVzYyA9IHNlY29uZFNvcnREaXJlY3Rpb25cbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICAgIGlmICghYWRkaXRpdmUpIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IG5ld1NvcnRlZC5zbGljZShleGlzdGluZ0luZGV4LCBjb2x1bW4ubGVuZ3RoKVxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAvLyBOZXcgU29ydCBDb2x1bW5cbiAgICAgICAgICBpZiAoYWRkaXRpdmUpIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IG5ld1NvcnRlZC5jb25jYXQoXG4gICAgICAgICAgICAgIGNvbHVtbi5tYXAoZCA9PiAoe1xuICAgICAgICAgICAgICAgIGlkOiBkLmlkLFxuICAgICAgICAgICAgICAgIGRlc2M6IGZpcnN0U29ydERpcmVjdGlvbixcbiAgICAgICAgICAgICAgfSkpXG4gICAgICAgICAgICApXG4gICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIG5ld1NvcnRlZCA9IGNvbHVtbi5tYXAoZCA9PiAoe1xuICAgICAgICAgICAgICBpZDogZC5pZCxcbiAgICAgICAgICAgICAgZGVzYzogZmlyc3RTb3J0RGlyZWN0aW9uLFxuICAgICAgICAgICAgfSkpXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICB9XG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHBhZ2U6XG4gICAgICAgICAgICAoIXNvcnRlZC5sZW5ndGggJiYgbmV3U29ydGVkLmxlbmd0aCkgfHwgIWFkZGl0aXZlXG4gICAgICAgICAgICAgID8gMFxuICAgICAgICAgICAgICA6IHRoaXMuc3RhdGUucGFnZSxcbiAgICAgICAgICBzb3J0ZWQ6IG5ld1NvcnRlZCxcbiAgICAgICAgfSxcbiAgICAgICAgKCkgPT4ge1xuICAgICAgICAgIG9uU29ydGVkQ2hhbmdlICYmIG9uU29ydGVkQ2hhbmdlKG5ld1NvcnRlZCwgY29sdW1uLCBhZGRpdGl2ZSlcbiAgICAgICAgfVxuICAgICAgKVxuICAgIH1cblxuICAgIGZpbHRlckNvbHVtbiAoY29sdW1uLCB2YWx1ZSkge1xuICAgICAgY29uc3QgeyBmaWx0ZXJlZCB9ID0gdGhpcy5nZXRSZXNvbHZlZFN0YXRlKClcbiAgICAgIGNvbnN0IHsgb25GaWx0ZXJlZENoYW5nZSB9ID0gdGhpcy5wcm9wc1xuXG4gICAgICAvLyBSZW1vdmUgb2xkIGZpbHRlciBmaXJzdCBpZiBpdCBleGlzdHNcbiAgICAgIGNvbnN0IG5ld0ZpbHRlcmluZyA9IChmaWx0ZXJlZCB8fCBbXSkuZmlsdGVyKHggPT4ge1xuICAgICAgICBpZiAoeC5pZCAhPT0gY29sdW1uLmlkKSB7XG4gICAgICAgICAgcmV0dXJuIHRydWVcbiAgICAgICAgfVxuICAgICAgfSlcblxuICAgICAgaWYgKHZhbHVlICE9PSAnJykge1xuICAgICAgICBuZXdGaWx0ZXJpbmcucHVzaCh7XG4gICAgICAgICAgaWQ6IGNvbHVtbi5pZCxcbiAgICAgICAgICB2YWx1ZTogdmFsdWUsXG4gICAgICAgIH0pXG4gICAgICB9XG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIGZpbHRlcmVkOiBuZXdGaWx0ZXJpbmcsXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBvbkZpbHRlcmVkQ2hhbmdlICYmIG9uRmlsdGVyZWRDaGFuZ2UobmV3RmlsdGVyaW5nLCBjb2x1bW4sIHZhbHVlKVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uU3RhcnQgKGV2ZW50LCBjb2x1bW4sIGlzVG91Y2gpIHtcbiAgICAgIGV2ZW50LnN0b3BQcm9wYWdhdGlvbigpXG4gICAgICBjb25zdCBwYXJlbnRXaWR0aCA9IGV2ZW50LnRhcmdldC5wYXJlbnRFbGVtZW50LmdldEJvdW5kaW5nQ2xpZW50UmVjdCgpXG4gICAgICAgIC53aWR0aFxuXG4gICAgICBsZXQgcGFnZVhcbiAgICAgIGlmIChpc1RvdWNoKSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQuY2hhbmdlZFRvdWNoZXNbMF0ucGFnZVhcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQucGFnZVhcbiAgICAgIH1cblxuICAgICAgdGhpcy50cmFwRXZlbnRzID0gdHJ1ZVxuICAgICAgdGhpcy5zZXRTdGF0ZVdpdGhEYXRhKFxuICAgICAgICB7XG4gICAgICAgICAgY3VycmVudGx5UmVzaXppbmc6IHtcbiAgICAgICAgICAgIGlkOiBjb2x1bW4uaWQsXG4gICAgICAgICAgICBzdGFydFg6IHBhZ2VYLFxuICAgICAgICAgICAgcGFyZW50V2lkdGg6IHBhcmVudFdpZHRoLFxuICAgICAgICAgIH0sXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBpZiAoaXNUb3VjaCkge1xuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcigndG91Y2htb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCd0b3VjaGNhbmNlbCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcigndG91Y2hlbmQnLCB0aGlzLnJlc2l6ZUNvbHVtbkVuZClcbiAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgZG9jdW1lbnQuYWRkRXZlbnRMaXN0ZW5lcignbW91c2Vtb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCdtb3VzZXVwJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICAgICAgICBkb2N1bWVudC5hZGRFdmVudExpc3RlbmVyKCdtb3VzZWxlYXZlJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uTW92aW5nIChldmVudCkge1xuICAgICAgZXZlbnQuc3RvcFByb3BhZ2F0aW9uKClcbiAgICAgIGNvbnN0IHsgb25SZXNpemVkQ2hhbmdlIH0gPSB0aGlzLnByb3BzXG4gICAgICBjb25zdCB7IHJlc2l6ZWQsIGN1cnJlbnRseVJlc2l6aW5nIH0gPSB0aGlzLmdldFJlc29sdmVkU3RhdGUoKVxuXG4gICAgICAvLyBEZWxldGUgb2xkIHZhbHVlXG4gICAgICBjb25zdCBuZXdSZXNpemVkID0gcmVzaXplZC5maWx0ZXIoeCA9PiB4LmlkICE9PSBjdXJyZW50bHlSZXNpemluZy5pZClcblxuICAgICAgbGV0IHBhZ2VYXG5cbiAgICAgIGlmIChldmVudC50eXBlID09PSAndG91Y2htb3ZlJykge1xuICAgICAgICBwYWdlWCA9IGV2ZW50LmNoYW5nZWRUb3VjaGVzWzBdLnBhZ2VYXG4gICAgICB9IGVsc2UgaWYgKGV2ZW50LnR5cGUgPT09ICdtb3VzZW1vdmUnKSB7XG4gICAgICAgIHBhZ2VYID0gZXZlbnQucGFnZVhcbiAgICAgIH1cblxuICAgICAgLy8gU2V0IHRoZSBtaW4gc2l6ZSB0byAxMCB0byBhY2NvdW50IGZvciBtYXJnaW4gYW5kIGJvcmRlciBvciBlbHNlIHRoZSBncm91cCBoZWFkZXJzIGRvbid0IGxpbmUgdXAgY29ycmVjdGx5XG4gICAgICBjb25zdCBuZXdXaWR0aCA9IE1hdGgubWF4KFxuICAgICAgICBjdXJyZW50bHlSZXNpemluZy5wYXJlbnRXaWR0aCArIHBhZ2VYIC0gY3VycmVudGx5UmVzaXppbmcuc3RhcnRYLFxuICAgICAgICAxMVxuICAgICAgKVxuXG4gICAgICBuZXdSZXNpemVkLnB1c2goe1xuICAgICAgICBpZDogY3VycmVudGx5UmVzaXppbmcuaWQsXG4gICAgICAgIHZhbHVlOiBuZXdXaWR0aCxcbiAgICAgIH0pXG5cbiAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YShcbiAgICAgICAge1xuICAgICAgICAgIHJlc2l6ZWQ6IG5ld1Jlc2l6ZWQsXG4gICAgICAgIH0sXG4gICAgICAgICgpID0+IHtcbiAgICAgICAgICBvblJlc2l6ZWRDaGFuZ2UgJiYgb25SZXNpemVkQ2hhbmdlKG5ld1Jlc2l6ZWQsIGV2ZW50KVxuICAgICAgICB9XG4gICAgICApXG4gICAgfVxuXG4gICAgcmVzaXplQ29sdW1uRW5kIChldmVudCkge1xuICAgICAgZXZlbnQuc3RvcFByb3BhZ2F0aW9uKClcbiAgICAgIGxldCBpc1RvdWNoID0gZXZlbnQudHlwZSA9PT0gJ3RvdWNoZW5kJyB8fCBldmVudC50eXBlID09PSAndG91Y2hjYW5jZWwnXG5cbiAgICAgIGlmIChpc1RvdWNoKSB7XG4gICAgICAgIGRvY3VtZW50LnJlbW92ZUV2ZW50TGlzdGVuZXIoJ3RvdWNobW92ZScsIHRoaXMucmVzaXplQ29sdW1uTW92aW5nKVxuICAgICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCd0b3VjaGNhbmNlbCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCd0b3VjaGVuZCcsIHRoaXMucmVzaXplQ29sdW1uRW5kKVxuICAgICAgfVxuXG4gICAgICAvLyBJZiBpdHMgYSB0b3VjaCBldmVudCBjbGVhciB0aGUgbW91c2Ugb25lJ3MgYXMgd2VsbCBiZWNhdXNlIHNvbWV0aW1lc1xuICAgICAgLy8gdGhlIG1vdXNlRG93biBldmVudCBnZXRzIGNhbGxlZCBhcyB3ZWxsLCBidXQgdGhlIG1vdXNlVXAgZXZlbnQgZG9lc24ndFxuICAgICAgZG9jdW1lbnQucmVtb3ZlRXZlbnRMaXN0ZW5lcignbW91c2Vtb3ZlJywgdGhpcy5yZXNpemVDb2x1bW5Nb3ZpbmcpXG4gICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCdtb3VzZXVwJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG4gICAgICBkb2N1bWVudC5yZW1vdmVFdmVudExpc3RlbmVyKCdtb3VzZWxlYXZlJywgdGhpcy5yZXNpemVDb2x1bW5FbmQpXG5cbiAgICAgIC8vIFRoZSB0b3VjaCBldmVudHMgZG9uJ3QgcHJvcGFnYXRlIHVwIHRvIHRoZSBzb3J0aW5nJ3Mgb25Nb3VzZURvd24gZXZlbnQgc29cbiAgICAgIC8vIG5vIG5lZWQgdG8gcHJldmVudCBpdCBmcm9tIGhhcHBlbmluZyBvciBlbHNlIHRoZSBmaXJzdCBjbGljayBhZnRlciBhIHRvdWNoXG4gICAgICAvLyBldmVudCByZXNpemUgd2lsbCBub3Qgc29ydCB0aGUgY29sdW1uLlxuICAgICAgaWYgKCFpc1RvdWNoKSB7XG4gICAgICAgIHRoaXMuc2V0U3RhdGVXaXRoRGF0YSh7XG4gICAgICAgICAgc2tpcE5leHRTb3J0OiB0cnVlLFxuICAgICAgICAgIGN1cnJlbnRseVJlc2l6aW5nOiBmYWxzZSxcbiAgICAgICAgfSlcbiAgICAgIH1cbiAgICB9XG4gIH1cbiJdfQ== /***/ }), -/* 420 */ +/* 361 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -65518,228 +54534,547 @@ module.exports = CopyToClipboard; Object.defineProperty(exports, "__esModule", { value: true }); -exports.CopyToClipboard = undefined; var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); - -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _copyToClipboard = __webpack_require__(421); - -var _copyToClipboard2 = _interopRequireDefault(_copyToClipboard); +var _classnames = __webpack_require__(41); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var _classnames2 = _interopRequireDefault(_classnames); -function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } +var _utils = __webpack_require__(95); -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +var _utils2 = _interopRequireDefault(_utils); -function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } +var _pagination = __webpack_require__(362); -function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } +var _pagination2 = _interopRequireDefault(_pagination); -var CopyToClipboard = exports.CopyToClipboard = function (_React$PureComponent) { - _inherits(CopyToClipboard, _React$PureComponent); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - function CopyToClipboard() { - var _ref; +function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } +// - var _temp, _this, _ret; - _classCallCheck(this, CopyToClipboard); +var emptyObj = function emptyObj() { + return {}; +}; - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { - args[_key] = arguments[_key]; +exports.default = { + // General + data: [], + loading: false, + showPagination: true, + showPaginationTop: false, + showPaginationBottom: true, + showPageSizeOptions: true, + pageSizeOptions: [5, 10, 20, 25, 50, 100], + defaultPageSize: 20, + showPageJump: true, + collapseOnSortingChange: true, + collapseOnPageChange: true, + collapseOnDataChange: true, + freezeWhenExpanded: false, + sortable: true, + resizable: true, + filterable: false, + defaultSortDesc: false, + defaultSorted: [], + defaultFiltered: [], + defaultResized: [], + defaultExpanded: {}, + defaultFilterMethod: function defaultFilterMethod(filter, row, column) { + var id = filter.pivotId || filter.id; + return row[id] !== undefined ? String(row[id]).startsWith(filter.value) : true; + }, + defaultSortMethod: function defaultSortMethod(a, b) { + // force null and undefined to the bottom + a = a === null || a === undefined ? '' : a; + b = b === null || b === undefined ? '' : b; + // force any string values to lowercase + a = typeof a === 'string' ? a.toLowerCase() : a; + b = typeof b === 'string' ? b.toLowerCase() : b; + // Return either 1 or -1 to indicate a sort priority + if (a > b) { + return 1; } + if (a < b) { + return -1; + } + // returning 0, undefined or any falsey value will use subsequent sorts or the index as a tiebreaker + return 0; + }, - return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = CopyToClipboard.__proto__ || Object.getPrototypeOf(CopyToClipboard)).call.apply(_ref, [this].concat(args))), _this), _this.onClick = function (event) { - var _this$props = _this.props, - text = _this$props.text, - onCopy = _this$props.onCopy, - children = _this$props.children, - options = _this$props.options; - + // Controlled State Props + // page: undefined, + // pageSize: undefined, + // sorted: [], + // filtered: [], + // resized: [], + // expanded: {}, + + // Controlled State Callbacks + onPageChange: undefined, + onPageSizeChange: undefined, + onSortedChange: undefined, + onFilteredChange: undefined, + onResizedChange: undefined, + onExpandedChange: undefined, + + // Pivoting + pivotBy: undefined, + + // Key Constants + pivotValKey: '_pivotVal', + pivotIDKey: '_pivotID', + subRowsKey: '_subRows', + aggregatedKey: '_aggregated', + nestingLevelKey: '_nestingLevel', + originalKey: '_original', + indexKey: '_index', + groupedByPivotKey: '_groupedByPivot', + + // Server-side Callbacks + onFetchData: function onFetchData() { + return null; + }, - var elem = _react2.default.Children.only(children); + // Classes + className: '', + style: {}, + + // Component decorators + getProps: emptyObj, + getTableProps: emptyObj, + getTheadGroupProps: emptyObj, + getTheadGroupTrProps: emptyObj, + getTheadGroupThProps: emptyObj, + getTheadProps: emptyObj, + getTheadTrProps: emptyObj, + getTheadThProps: emptyObj, + getTheadFilterProps: emptyObj, + getTheadFilterTrProps: emptyObj, + getTheadFilterThProps: emptyObj, + getTbodyProps: emptyObj, + getTrGroupProps: emptyObj, + getTrProps: emptyObj, + getTdProps: emptyObj, + getTfootProps: emptyObj, + getTfootTrProps: emptyObj, + getTfootTdProps: emptyObj, + getPaginationProps: emptyObj, + getLoadingProps: emptyObj, + getNoDataProps: emptyObj, + getResizerProps: emptyObj, + + // Global Column Defaults + column: { + // Renderers + Cell: undefined, + Header: undefined, + Footer: undefined, + Aggregated: undefined, + Pivot: undefined, + PivotValue: undefined, + Expander: undefined, + Filter: undefined, + // All Columns + sortable: undefined, // use table default + resizable: undefined, // use table default + filterable: undefined, // use table default + show: true, + minWidth: 100, + // Cells only + className: '', + style: {}, + getProps: emptyObj, + // Pivot only + aggregate: undefined, + // Headers only + headerClassName: '', + headerStyle: {}, + getHeaderProps: emptyObj, + // Footers only + footerClassName: '', + footerStyle: {}, + getFooterProps: emptyObj, + filterMethod: undefined, + filterAll: false, + sortMethod: undefined + }, - var result = (0, _copyToClipboard2.default)(text, options); + // Global Expander Column Defaults + expanderDefaults: { + sortable: false, + resizable: false, + filterable: false, + width: 35 + }, - if (onCopy) { - onCopy(text, result); - } + pivotDefaults: { + // extend the defaults for pivoted columns here + }, - // Bypass onClick if it was present - if (elem && elem.props && typeof elem.props.onClick === 'function') { - elem.props.onClick(event); - } - }, _temp), _possibleConstructorReturn(_this, _ret); - } + // Text + previousText: 'Previous', + nextText: 'Next', + loadingText: 'Loading...', + noDataText: 'No rows found', + pageText: 'Page', + ofText: 'of', + rowsText: 'rows', - _createClass(CopyToClipboard, [{ - key: 'render', - value: function render() { - var _props = this.props, - _text = _props.text, - _onCopy = _props.onCopy, - _options = _props.options, - children = _props.children, - props = _objectWithoutProperties(_props, ['text', 'onCopy', 'options', 'children']); + // Components + TableComponent: _utils2.default.makeTemplateComponent('rt-table', 'Table'), + TheadComponent: _utils2.default.makeTemplateComponent('rt-thead', 'Thead'), + TbodyComponent: _utils2.default.makeTemplateComponent('rt-tbody', 'Tbody'), + TrGroupComponent: _utils2.default.makeTemplateComponent('rt-tr-group', 'TrGroup'), + TrComponent: _utils2.default.makeTemplateComponent('rt-tr', 'Tr'), + ThComponent: function ThComponent(_ref) { + var toggleSort = _ref.toggleSort, + className = _ref.className, + children = _ref.children, + rest = _objectWithoutProperties(_ref, ['toggleSort', 'className', 'children']); - var elem = _react2.default.Children.only(children); + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)(className, 'rt-th'), + onClick: function onClick(e) { + toggleSort && toggleSort(e); + } + }, rest), + children + ); + }, + TdComponent: _utils2.default.makeTemplateComponent('rt-td', 'Td'), + TfootComponent: _utils2.default.makeTemplateComponent('rt-tfoot', 'Tfoot'), + FilterComponent: function FilterComponent(_ref2) { + var filter = _ref2.filter, + _onChange = _ref2.onChange; + return _react2.default.createElement('input', { + type: 'text', + style: { + width: '100%' + }, + value: filter ? filter.value : '', + onChange: function onChange(event) { + return _onChange(event.target.value); + } + }); + }, + ExpanderComponent: function ExpanderComponent(_ref3) { + var isExpanded = _ref3.isExpanded; + return _react2.default.createElement( + 'div', + { className: (0, _classnames2.default)('rt-expander', isExpanded && '-open') }, + '\u2022' + ); + }, + PivotValueComponent: function PivotValueComponent(_ref4) { + var subRows = _ref4.subRows, + value = _ref4.value; + return _react2.default.createElement( + 'span', + null, + value, + ' ', + subRows && '(' + subRows.length + ')' + ); + }, + AggregatedComponent: function AggregatedComponent(_ref5) { + var subRows = _ref5.subRows, + column = _ref5.column; - return _react2.default.cloneElement(elem, _extends({}, props, { onClick: this.onClick })); - } - }]); + var previewValues = subRows.filter(function (d) { + return typeof d[column.id] !== 'undefined'; + }).map(function (row, i) { + return _react2.default.createElement( + 'span', + { key: i }, + row[column.id], + i < subRows.length - 1 ? ', ' : '' + ); + }); + return _react2.default.createElement( + 'span', + null, + previewValues + ); + }, + PivotComponent: undefined, // this is a computed default generated using + // the ExpanderComponent and PivotValueComponent at run-time in methods.js + PaginationComponent: _pagination2.default, + PreviousComponent: undefined, + NextComponent: undefined, + LoadingComponent: function LoadingComponent(_ref6) { + var className = _ref6.className, + loading = _ref6.loading, + loadingText = _ref6.loadingText, + rest = _objectWithoutProperties(_ref6, ['className', 'loading', 'loadingText']); - return CopyToClipboard; -}(_react2.default.PureComponent); + return _react2.default.createElement( + 'div', + _extends({ + className: (0, _classnames2.default)('-loading', { '-active': loading }, className) + }, rest), + _react2.default.createElement( + 'div', + { className: '-loading-inner' }, + loadingText + ) + ); + }, + NoDataComponent: _utils2.default.makeTemplateComponent('rt-noData', 'NoData'), + ResizerComponent: _utils2.default.makeTemplateComponent('rt-resizer', 'Resizer'), + PadRowComponent: function PadRowComponent() { + return _react2.default.createElement( + 'span', + null, + '\xA0' + ); + } +}; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9kZWZhdWx0UHJvcHMuanMiXSwibmFtZXMiOlsiZW1wdHlPYmoiLCJkYXRhIiwibG9hZGluZyIsInNob3dQYWdpbmF0aW9uIiwic2hvd1BhZ2luYXRpb25Ub3AiLCJzaG93UGFnaW5hdGlvbkJvdHRvbSIsInNob3dQYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZU9wdGlvbnMiLCJkZWZhdWx0UGFnZVNpemUiLCJzaG93UGFnZUp1bXAiLCJjb2xsYXBzZU9uU29ydGluZ0NoYW5nZSIsImNvbGxhcHNlT25QYWdlQ2hhbmdlIiwiY29sbGFwc2VPbkRhdGFDaGFuZ2UiLCJmcmVlemVXaGVuRXhwYW5kZWQiLCJzb3J0YWJsZSIsInJlc2l6YWJsZSIsImZpbHRlcmFibGUiLCJkZWZhdWx0U29ydERlc2MiLCJkZWZhdWx0U29ydGVkIiwiZGVmYXVsdEZpbHRlcmVkIiwiZGVmYXVsdFJlc2l6ZWQiLCJkZWZhdWx0RXhwYW5kZWQiLCJkZWZhdWx0RmlsdGVyTWV0aG9kIiwiZmlsdGVyIiwicm93IiwiY29sdW1uIiwiaWQiLCJwaXZvdElkIiwidW5kZWZpbmVkIiwiU3RyaW5nIiwic3RhcnRzV2l0aCIsInZhbHVlIiwiZGVmYXVsdFNvcnRNZXRob2QiLCJhIiwiYiIsInRvTG93ZXJDYXNlIiwib25QYWdlQ2hhbmdlIiwib25QYWdlU2l6ZUNoYW5nZSIsIm9uU29ydGVkQ2hhbmdlIiwib25GaWx0ZXJlZENoYW5nZSIsIm9uUmVzaXplZENoYW5nZSIsIm9uRXhwYW5kZWRDaGFuZ2UiLCJwaXZvdEJ5IiwicGl2b3RWYWxLZXkiLCJwaXZvdElES2V5Iiwic3ViUm93c0tleSIsImFnZ3JlZ2F0ZWRLZXkiLCJuZXN0aW5nTGV2ZWxLZXkiLCJvcmlnaW5hbEtleSIsImluZGV4S2V5IiwiZ3JvdXBlZEJ5UGl2b3RLZXkiLCJvbkZldGNoRGF0YSIsImNsYXNzTmFtZSIsInN0eWxlIiwiZ2V0UHJvcHMiLCJnZXRUYWJsZVByb3BzIiwiZ2V0VGhlYWRHcm91cFByb3BzIiwiZ2V0VGhlYWRHcm91cFRyUHJvcHMiLCJnZXRUaGVhZEdyb3VwVGhQcm9wcyIsImdldFRoZWFkUHJvcHMiLCJnZXRUaGVhZFRyUHJvcHMiLCJnZXRUaGVhZFRoUHJvcHMiLCJnZXRUaGVhZEZpbHRlclByb3BzIiwiZ2V0VGhlYWRGaWx0ZXJUclByb3BzIiwiZ2V0VGhlYWRGaWx0ZXJUaFByb3BzIiwiZ2V0VGJvZHlQcm9wcyIsImdldFRyR3JvdXBQcm9wcyIsImdldFRyUHJvcHMiLCJnZXRUZFByb3BzIiwiZ2V0VGZvb3RQcm9wcyIsImdldFRmb290VHJQcm9wcyIsImdldFRmb290VGRQcm9wcyIsImdldFBhZ2luYXRpb25Qcm9wcyIsImdldExvYWRpbmdQcm9wcyIsImdldE5vRGF0YVByb3BzIiwiZ2V0UmVzaXplclByb3BzIiwiQ2VsbCIsIkhlYWRlciIsIkZvb3RlciIsIkFnZ3JlZ2F0ZWQiLCJQaXZvdCIsIlBpdm90VmFsdWUiLCJFeHBhbmRlciIsIkZpbHRlciIsInNob3ciLCJtaW5XaWR0aCIsImFnZ3JlZ2F0ZSIsImhlYWRlckNsYXNzTmFtZSIsImhlYWRlclN0eWxlIiwiZ2V0SGVhZGVyUHJvcHMiLCJmb290ZXJDbGFzc05hbWUiLCJmb290ZXJTdHlsZSIsImdldEZvb3RlclByb3BzIiwiZmlsdGVyTWV0aG9kIiwiZmlsdGVyQWxsIiwic29ydE1ldGhvZCIsImV4cGFuZGVyRGVmYXVsdHMiLCJ3aWR0aCIsInBpdm90RGVmYXVsdHMiLCJwcmV2aW91c1RleHQiLCJuZXh0VGV4dCIsImxvYWRpbmdUZXh0Iiwibm9EYXRhVGV4dCIsInBhZ2VUZXh0Iiwib2ZUZXh0Iiwicm93c1RleHQiLCJUYWJsZUNvbXBvbmVudCIsIm1ha2VUZW1wbGF0ZUNvbXBvbmVudCIsIlRoZWFkQ29tcG9uZW50IiwiVGJvZHlDb21wb25lbnQiLCJUckdyb3VwQ29tcG9uZW50IiwiVHJDb21wb25lbnQiLCJUaENvbXBvbmVudCIsInRvZ2dsZVNvcnQiLCJjaGlsZHJlbiIsInJlc3QiLCJlIiwiVGRDb21wb25lbnQiLCJUZm9vdENvbXBvbmVudCIsIkZpbHRlckNvbXBvbmVudCIsIm9uQ2hhbmdlIiwiZXZlbnQiLCJ0YXJnZXQiLCJFeHBhbmRlckNvbXBvbmVudCIsImlzRXhwYW5kZWQiLCJQaXZvdFZhbHVlQ29tcG9uZW50Iiwic3ViUm93cyIsImxlbmd0aCIsIkFnZ3JlZ2F0ZWRDb21wb25lbnQiLCJwcmV2aWV3VmFsdWVzIiwiZCIsIm1hcCIsImkiLCJQaXZvdENvbXBvbmVudCIsIlBhZ2luYXRpb25Db21wb25lbnQiLCJQcmV2aW91c0NvbXBvbmVudCIsIk5leHRDb21wb25lbnQiLCJMb2FkaW5nQ29tcG9uZW50IiwiTm9EYXRhQ29tcG9uZW50IiwiUmVzaXplckNvbXBvbmVudCIsIlBhZFJvd0NvbXBvbmVudCJdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7O0FBRUE7Ozs7QUFDQTs7Ozs7OztBQUZBOzs7QUFJQSxJQUFNQSxXQUFXLFNBQVhBLFFBQVc7QUFBQSxTQUFPLEVBQVA7QUFBQSxDQUFqQjs7a0JBRWU7QUFDYjtBQUNBQyxRQUFNLEVBRk87QUFHYkMsV0FBUyxLQUhJO0FBSWJDLGtCQUFnQixJQUpIO0FBS2JDLHFCQUFtQixLQUxOO0FBTWJDLHdCQUFzQixJQU5UO0FBT2JDLHVCQUFxQixJQVBSO0FBUWJDLG1CQUFpQixDQUFDLENBQUQsRUFBSSxFQUFKLEVBQVEsRUFBUixFQUFZLEVBQVosRUFBZ0IsRUFBaEIsRUFBb0IsR0FBcEIsQ0FSSjtBQVNiQyxtQkFBaUIsRUFUSjtBQVViQyxnQkFBYyxJQVZEO0FBV2JDLDJCQUF5QixJQVhaO0FBWWJDLHdCQUFzQixJQVpUO0FBYWJDLHdCQUFzQixJQWJUO0FBY2JDLHNCQUFvQixLQWRQO0FBZWJDLFlBQVUsSUFmRztBQWdCYkMsYUFBVyxJQWhCRTtBQWlCYkMsY0FBWSxLQWpCQztBQWtCYkMsbUJBQWlCLEtBbEJKO0FBbUJiQyxpQkFBZSxFQW5CRjtBQW9CYkMsbUJBQWlCLEVBcEJKO0FBcUJiQyxrQkFBZ0IsRUFyQkg7QUFzQmJDLG1CQUFpQixFQXRCSjtBQXVCYkMsdUJBQXFCLDZCQUFDQyxNQUFELEVBQVNDLEdBQVQsRUFBY0MsTUFBZCxFQUF5QjtBQUM1QyxRQUFNQyxLQUFLSCxPQUFPSSxPQUFQLElBQWtCSixPQUFPRyxFQUFwQztBQUNBLFdBQU9GLElBQUlFLEVBQUosTUFBWUUsU0FBWixHQUNIQyxPQUFPTCxJQUFJRSxFQUFKLENBQVAsRUFBZ0JJLFVBQWhCLENBQTJCUCxPQUFPUSxLQUFsQyxDQURHLEdBRUgsSUFGSjtBQUdELEdBNUJZO0FBNkJiQyxxQkFBbUIsMkJBQUNDLENBQUQsRUFBSUMsQ0FBSixFQUFVO0FBQzNCO0FBQ0FELFFBQUlBLE1BQU0sSUFBTixJQUFjQSxNQUFNTCxTQUFwQixHQUFnQyxFQUFoQyxHQUFxQ0ssQ0FBekM7QUFDQUMsUUFBSUEsTUFBTSxJQUFOLElBQWNBLE1BQU1OLFNBQXBCLEdBQWdDLEVBQWhDLEdBQXFDTSxDQUF6QztBQUNBO0FBQ0FELFFBQUksT0FBT0EsQ0FBUCxLQUFhLFFBQWIsR0FBd0JBLEVBQUVFLFdBQUYsRUFBeEIsR0FBMENGLENBQTlDO0FBQ0FDLFFBQUksT0FBT0EsQ0FBUCxLQUFhLFFBQWIsR0FBd0JBLEVBQUVDLFdBQUYsRUFBeEIsR0FBMENELENBQTlDO0FBQ0E7QUFDQSxRQUFJRCxJQUFJQyxDQUFSLEVBQVc7QUFDVCxhQUFPLENBQVA7QUFDRDtBQUNELFFBQUlELElBQUlDLENBQVIsRUFBVztBQUNULGFBQU8sQ0FBQyxDQUFSO0FBQ0Q7QUFDRDtBQUNBLFdBQU8sQ0FBUDtBQUNELEdBN0NZOztBQStDYjtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBRSxnQkFBY1IsU0F4REQ7QUF5RGJTLG9CQUFrQlQsU0F6REw7QUEwRGJVLGtCQUFnQlYsU0ExREg7QUEyRGJXLG9CQUFrQlgsU0EzREw7QUE0RGJZLG1CQUFpQlosU0E1REo7QUE2RGJhLG9CQUFrQmIsU0E3REw7O0FBK0RiO0FBQ0FjLFdBQVNkLFNBaEVJOztBQWtFYjtBQUNBZSxlQUFhLFdBbkVBO0FBb0ViQyxjQUFZLFVBcEVDO0FBcUViQyxjQUFZLFVBckVDO0FBc0ViQyxpQkFBZSxhQXRFRjtBQXVFYkMsbUJBQWlCLGVBdkVKO0FBd0ViQyxlQUFhLFdBeEVBO0FBeUViQyxZQUFVLFFBekVHO0FBMEViQyxxQkFBbUIsaUJBMUVOOztBQTRFYjtBQUNBQyxlQUFhO0FBQUEsV0FBTSxJQUFOO0FBQUEsR0E3RUE7O0FBK0ViO0FBQ0FDLGFBQVcsRUFoRkU7QUFpRmJDLFNBQU8sRUFqRk07O0FBbUZiO0FBQ0FDLFlBQVV0RCxRQXBGRztBQXFGYnVELGlCQUFldkQsUUFyRkY7QUFzRmJ3RCxzQkFBb0J4RCxRQXRGUDtBQXVGYnlELHdCQUFzQnpELFFBdkZUO0FBd0ZiMEQsd0JBQXNCMUQsUUF4RlQ7QUF5RmIyRCxpQkFBZTNELFFBekZGO0FBMEZiNEQsbUJBQWlCNUQsUUExRko7QUEyRmI2RCxtQkFBaUI3RCxRQTNGSjtBQTRGYjhELHVCQUFxQjlELFFBNUZSO0FBNkZiK0QseUJBQXVCL0QsUUE3RlY7QUE4RmJnRSx5QkFBdUJoRSxRQTlGVjtBQStGYmlFLGlCQUFlakUsUUEvRkY7QUFnR2JrRSxtQkFBaUJsRSxRQWhHSjtBQWlHYm1FLGNBQVluRSxRQWpHQztBQWtHYm9FLGNBQVlwRSxRQWxHQztBQW1HYnFFLGlCQUFlckUsUUFuR0Y7QUFvR2JzRSxtQkFBaUJ0RSxRQXBHSjtBQXFHYnVFLG1CQUFpQnZFLFFBckdKO0FBc0did0Usc0JBQW9CeEUsUUF0R1A7QUF1R2J5RSxtQkFBaUJ6RSxRQXZHSjtBQXdHYjBFLGtCQUFnQjFFLFFBeEdIO0FBeUdiMkUsbUJBQWlCM0UsUUF6R0o7O0FBMkdiO0FBQ0F5QixVQUFRO0FBQ047QUFDQW1ELFVBQU1oRCxTQUZBO0FBR05pRCxZQUFRakQsU0FIRjtBQUlOa0QsWUFBUWxELFNBSkY7QUFLTm1ELGdCQUFZbkQsU0FMTjtBQU1Ob0QsV0FBT3BELFNBTkQ7QUFPTnFELGdCQUFZckQsU0FQTjtBQVFOc0QsY0FBVXRELFNBUko7QUFTTnVELFlBQVF2RCxTQVRGO0FBVU47QUFDQWQsY0FBVWMsU0FYSixFQVdlO0FBQ3JCYixlQUFXYSxTQVpMLEVBWWdCO0FBQ3RCWixnQkFBWVksU0FiTixFQWFpQjtBQUN2QndELFVBQU0sSUFkQTtBQWVOQyxjQUFVLEdBZko7QUFnQk47QUFDQWpDLGVBQVcsRUFqQkw7QUFrQk5DLFdBQU8sRUFsQkQ7QUFtQk5DLGNBQVV0RCxRQW5CSjtBQW9CTjtBQUNBc0YsZUFBVzFELFNBckJMO0FBc0JOO0FBQ0EyRCxxQkFBaUIsRUF2Qlg7QUF3Qk5DLGlCQUFhLEVBeEJQO0FBeUJOQyxvQkFBZ0J6RixRQXpCVjtBQTBCTjtBQUNBMEYscUJBQWlCLEVBM0JYO0FBNEJOQyxpQkFBYSxFQTVCUDtBQTZCTkMsb0JBQWdCNUYsUUE3QlY7QUE4Qk42RixrQkFBY2pFLFNBOUJSO0FBK0JOa0UsZUFBVyxLQS9CTDtBQWdDTkMsZ0JBQVluRTtBQWhDTixHQTVHSzs7QUErSWI7QUFDQW9FLG9CQUFrQjtBQUNoQmxGLGNBQVUsS0FETTtBQUVoQkMsZUFBVyxLQUZLO0FBR2hCQyxnQkFBWSxLQUhJO0FBSWhCaUYsV0FBTztBQUpTLEdBaEpMOztBQXVKYkMsaUJBQWU7QUFDYjtBQURhLEdBdkpGOztBQTJKYjtBQUNBQyxnQkFBYyxVQTVKRDtBQTZKYkMsWUFBVSxNQTdKRztBQThKYkMsZUFBYSxZQTlKQTtBQStKYkMsY0FBWSxlQS9KQztBQWdLYkMsWUFBVSxNQWhLRztBQWlLYkMsVUFBUSxJQWpLSztBQWtLYkMsWUFBVSxNQWxLRzs7QUFvS2I7QUFDQUMsa0JBQWdCLGdCQUFFQyxxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXJLSDtBQXNLYkMsa0JBQWdCLGdCQUFFRCxxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXRLSDtBQXVLYkUsa0JBQWdCLGdCQUFFRixxQkFBRixDQUF3QixVQUF4QixFQUFvQyxPQUFwQyxDQXZLSDtBQXdLYkcsb0JBQWtCLGdCQUFFSCxxQkFBRixDQUF3QixhQUF4QixFQUF1QyxTQUF2QyxDQXhLTDtBQXlLYkksZUFBYSxnQkFBRUoscUJBQUYsQ0FBd0IsT0FBeEIsRUFBaUMsSUFBakMsQ0F6S0E7QUEwS2JLLGVBQWEsMkJBQWtEO0FBQUEsUUFBL0NDLFVBQStDLFFBQS9DQSxVQUErQztBQUFBLFFBQW5DN0QsU0FBbUMsUUFBbkNBLFNBQW1DO0FBQUEsUUFBeEI4RCxRQUF3QixRQUF4QkEsUUFBd0I7QUFBQSxRQUFYQyxJQUFXOztBQUM3RCxXQUNFO0FBQUE7QUFBQTtBQUNFLG1CQUFXLDBCQUFXL0QsU0FBWCxFQUFzQixPQUF0QixDQURiO0FBRUUsaUJBQVMsb0JBQUs7QUFDWjZELHdCQUFjQSxXQUFXRyxDQUFYLENBQWQ7QUFDRDtBQUpILFNBS01ELElBTE47QUFPR0Q7QUFQSCxLQURGO0FBV0QsR0F0TFk7QUF1TGJHLGVBQWEsZ0JBQUVWLHFCQUFGLENBQXdCLE9BQXhCLEVBQWlDLElBQWpDLENBdkxBO0FBd0xiVyxrQkFBZ0IsZ0JBQUVYLHFCQUFGLENBQXdCLFVBQXhCLEVBQW9DLE9BQXBDLENBeExIO0FBeUxiWSxtQkFBaUI7QUFBQSxRQUFHaEcsTUFBSCxTQUFHQSxNQUFIO0FBQUEsUUFBV2lHLFNBQVgsU0FBV0EsUUFBWDtBQUFBLFdBQ2Y7QUFDRSxZQUFLLE1BRFA7QUFFRSxhQUFPO0FBQ0x2QixlQUFPO0FBREYsT0FGVDtBQUtFLGFBQU8xRSxTQUFTQSxPQUFPUSxLQUFoQixHQUF3QixFQUxqQztBQU1FLGdCQUFVO0FBQUEsZUFBU3lGLFVBQVNDLE1BQU1DLE1BQU4sQ0FBYTNGLEtBQXRCLENBQVQ7QUFBQTtBQU5aLE1BRGU7QUFBQSxHQXpMSjtBQWtNYjRGLHFCQUFtQjtBQUFBLFFBQUdDLFVBQUgsU0FBR0EsVUFBSDtBQUFBLFdBQ2pCO0FBQUE7QUFBQSxRQUFLLFdBQVcsMEJBQVcsYUFBWCxFQUEwQkEsY0FBYyxPQUF4QyxDQUFoQjtBQUFBO0FBQUEsS0FEaUI7QUFBQSxHQWxNTjtBQXNNYkMsdUJBQXFCO0FBQUEsUUFBR0MsT0FBSCxTQUFHQSxPQUFIO0FBQUEsUUFBWS9GLEtBQVosU0FBWUEsS0FBWjtBQUFBLFdBQ25CO0FBQUE7QUFBQTtBQUNHQSxXQURIO0FBQUE7QUFDVytGLHVCQUFlQSxRQUFRQyxNQUF2QjtBQURYLEtBRG1CO0FBQUEsR0F0TVI7QUEwTWJDLHVCQUFxQixvQ0FBeUI7QUFBQSxRQUF0QkYsT0FBc0IsU0FBdEJBLE9BQXNCO0FBQUEsUUFBYnJHLE1BQWEsU0FBYkEsTUFBYTs7QUFDNUMsUUFBTXdHLGdCQUFnQkgsUUFDbkJ2RyxNQURtQixDQUNaO0FBQUEsYUFBSyxPQUFPMkcsRUFBRXpHLE9BQU9DLEVBQVQsQ0FBUCxLQUF3QixXQUE3QjtBQUFBLEtBRFksRUFFbkJ5RyxHQUZtQixDQUVmLFVBQUMzRyxHQUFELEVBQU00RyxDQUFOO0FBQUEsYUFDSDtBQUFBO0FBQUEsVUFBTSxLQUFLQSxDQUFYO0FBQ0c1RyxZQUFJQyxPQUFPQyxFQUFYLENBREg7QUFFRzBHLFlBQUlOLFFBQVFDLE1BQVIsR0FBaUIsQ0FBckIsR0FBeUIsSUFBekIsR0FBZ0M7QUFGbkMsT0FERztBQUFBLEtBRmUsQ0FBdEI7QUFRQSxXQUNFO0FBQUE7QUFBQTtBQUNHRTtBQURILEtBREY7QUFLRCxHQXhOWTtBQXlOYkksa0JBQWdCekcsU0F6TkgsRUF5TmM7QUFDM0I7QUFDQTBHLDJDQTNOYTtBQTROYkMscUJBQW1CM0csU0E1Tk47QUE2TmI0RyxpQkFBZTVHLFNBN05GO0FBOE5iNkcsb0JBQWtCO0FBQUEsUUFBR3JGLFNBQUgsU0FBR0EsU0FBSDtBQUFBLFFBQWNsRCxPQUFkLFNBQWNBLE9BQWQ7QUFBQSxRQUF1Qm1HLFdBQXZCLFNBQXVCQSxXQUF2QjtBQUFBLFFBQXVDYyxJQUF2Qzs7QUFBQSxXQUNoQjtBQUFBO0FBQUE7QUFDRSxtQkFBVywwQkFBVyxVQUFYLEVBQXVCLEVBQUUsV0FBV2pILE9BQWIsRUFBdkIsRUFBK0NrRCxTQUEvQztBQURiLFNBRU0rRCxJQUZOO0FBSUU7QUFBQTtBQUFBLFVBQUssV0FBVSxnQkFBZjtBQUNHZDtBQURIO0FBSkYsS0FEZ0I7QUFBQSxHQTlOTDtBQXVPYnFDLG1CQUFpQixnQkFBRS9CLHFCQUFGLENBQXdCLFdBQXhCLEVBQXFDLFFBQXJDLENBdk9KO0FBd09iZ0Msb0JBQWtCLGdCQUFFaEMscUJBQUYsQ0FBd0IsWUFBeEIsRUFBc0MsU0FBdEMsQ0F4T0w7QUF5T2JpQyxtQkFBaUI7QUFBQSxXQUFNO0FBQUE7QUFBQTtBQUFBO0FBQUEsS0FBTjtBQUFBO0FBek9KLEMiLCJmaWxlIjoiZGVmYXVsdFByb3BzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IFJlYWN0IGZyb20gJ3JlYWN0J1xuaW1wb3J0IGNsYXNzbmFtZXMgZnJvbSAnY2xhc3NuYW1lcydcbi8vXG5pbXBvcnQgXyBmcm9tICcuL3V0aWxzJ1xuaW1wb3J0IFBhZ2luYXRpb24gZnJvbSAnLi9wYWdpbmF0aW9uJ1xuXG5jb25zdCBlbXB0eU9iaiA9ICgpID0+ICh7fSlcblxuZXhwb3J0IGRlZmF1bHQge1xuICAvLyBHZW5lcmFsXG4gIGRhdGE6IFtdLFxuICBsb2FkaW5nOiBmYWxzZSxcbiAgc2hvd1BhZ2luYXRpb246IHRydWUsXG4gIHNob3dQYWdpbmF0aW9uVG9wOiBmYWxzZSxcbiAgc2hvd1BhZ2luYXRpb25Cb3R0b206IHRydWUsXG4gIHNob3dQYWdlU2l6ZU9wdGlvbnM6IHRydWUsXG4gIHBhZ2VTaXplT3B0aW9uczogWzUsIDEwLCAyMCwgMjUsIDUwLCAxMDBdLFxuICBkZWZhdWx0UGFnZVNpemU6IDIwLFxuICBzaG93UGFnZUp1bXA6IHRydWUsXG4gIGNvbGxhcHNlT25Tb3J0aW5nQ2hhbmdlOiB0cnVlLFxuICBjb2xsYXBzZU9uUGFnZUNoYW5nZTogdHJ1ZSxcbiAgY29sbGFwc2VPbkRhdGFDaGFuZ2U6IHRydWUsXG4gIGZyZWV6ZVdoZW5FeHBhbmRlZDogZmFsc2UsXG4gIHNvcnRhYmxlOiB0cnVlLFxuICByZXNpemFibGU6IHRydWUsXG4gIGZpbHRlcmFibGU6IGZhbHNlLFxuICBkZWZhdWx0U29ydERlc2M6IGZhbHNlLFxuICBkZWZhdWx0U29ydGVkOiBbXSxcbiAgZGVmYXVsdEZpbHRlcmVkOiBbXSxcbiAgZGVmYXVsdFJlc2l6ZWQ6IFtdLFxuICBkZWZhdWx0RXhwYW5kZWQ6IHt9LFxuICBkZWZhdWx0RmlsdGVyTWV0aG9kOiAoZmlsdGVyLCByb3csIGNvbHVtbikgPT4ge1xuICAgIGNvbnN0IGlkID0gZmlsdGVyLnBpdm90SWQgfHwgZmlsdGVyLmlkXG4gICAgcmV0dXJuIHJvd1tpZF0gIT09IHVuZGVmaW5lZFxuICAgICAgPyBTdHJpbmcocm93W2lkXSkuc3RhcnRzV2l0aChmaWx0ZXIudmFsdWUpXG4gICAgICA6IHRydWVcbiAgfSxcbiAgZGVmYXVsdFNvcnRNZXRob2Q6IChhLCBiKSA9PiB7XG4gICAgLy8gZm9yY2UgbnVsbCBhbmQgdW5kZWZpbmVkIHRvIHRoZSBib3R0b21cbiAgICBhID0gYSA9PT0gbnVsbCB8fCBhID09PSB1bmRlZmluZWQgPyAnJyA6IGFcbiAgICBiID0gYiA9PT0gbnVsbCB8fCBiID09PSB1bmRlZmluZWQgPyAnJyA6IGJcbiAgICAvLyBmb3JjZSBhbnkgc3RyaW5nIHZhbHVlcyB0byBsb3dlcmNhc2VcbiAgICBhID0gdHlwZW9mIGEgPT09ICdzdHJpbmcnID8gYS50b0xvd2VyQ2FzZSgpIDogYVxuICAgIGIgPSB0eXBlb2YgYiA9PT0gJ3N0cmluZycgPyBiLnRvTG93ZXJDYXNlKCkgOiBiXG4gICAgLy8gUmV0dXJuIGVpdGhlciAxIG9yIC0xIHRvIGluZGljYXRlIGEgc29ydCBwcmlvcml0eVxuICAgIGlmIChhID4gYikge1xuICAgICAgcmV0dXJuIDFcbiAgICB9XG4gICAgaWYgKGEgPCBiKSB7XG4gICAgICByZXR1cm4gLTFcbiAgICB9XG4gICAgLy8gcmV0dXJuaW5nIDAsIHVuZGVmaW5lZCBvciBhbnkgZmFsc2V5IHZhbHVlIHdpbGwgdXNlIHN1YnNlcXVlbnQgc29ydHMgb3IgdGhlIGluZGV4IGFzIGEgdGllYnJlYWtlclxuICAgIHJldHVybiAwXG4gIH0sXG5cbiAgLy8gQ29udHJvbGxlZCBTdGF0ZSBQcm9wc1xuICAvLyBwYWdlOiB1bmRlZmluZWQsXG4gIC8vIHBhZ2VTaXplOiB1bmRlZmluZWQsXG4gIC8vIHNvcnRlZDogW10sXG4gIC8vIGZpbHRlcmVkOiBbXSxcbiAgLy8gcmVzaXplZDogW10sXG4gIC8vIGV4cGFuZGVkOiB7fSxcblxuICAvLyBDb250cm9sbGVkIFN0YXRlIENhbGxiYWNrc1xuICBvblBhZ2VDaGFuZ2U6IHVuZGVmaW5lZCxcbiAgb25QYWdlU2l6ZUNoYW5nZTogdW5kZWZpbmVkLFxuICBvblNvcnRlZENoYW5nZTogdW5kZWZpbmVkLFxuICBvbkZpbHRlcmVkQ2hhbmdlOiB1bmRlZmluZWQsXG4gIG9uUmVzaXplZENoYW5nZTogdW5kZWZpbmVkLFxuICBvbkV4cGFuZGVkQ2hhbmdlOiB1bmRlZmluZWQsXG5cbiAgLy8gUGl2b3RpbmdcbiAgcGl2b3RCeTogdW5kZWZpbmVkLFxuXG4gIC8vIEtleSBDb25zdGFudHNcbiAgcGl2b3RWYWxLZXk6ICdfcGl2b3RWYWwnLFxuICBwaXZvdElES2V5OiAnX3Bpdm90SUQnLFxuICBzdWJSb3dzS2V5OiAnX3N1YlJvd3MnLFxuICBhZ2dyZWdhdGVkS2V5OiAnX2FnZ3JlZ2F0ZWQnLFxuICBuZXN0aW5nTGV2ZWxLZXk6ICdfbmVzdGluZ0xldmVsJyxcbiAgb3JpZ2luYWxLZXk6ICdfb3JpZ2luYWwnLFxuICBpbmRleEtleTogJ19pbmRleCcsXG4gIGdyb3VwZWRCeVBpdm90S2V5OiAnX2dyb3VwZWRCeVBpdm90JyxcblxuICAvLyBTZXJ2ZXItc2lkZSBDYWxsYmFja3NcbiAgb25GZXRjaERhdGE6ICgpID0+IG51bGwsXG5cbiAgLy8gQ2xhc3Nlc1xuICBjbGFzc05hbWU6ICcnLFxuICBzdHlsZToge30sXG5cbiAgLy8gQ29tcG9uZW50IGRlY29yYXRvcnNcbiAgZ2V0UHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUYWJsZVByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRHcm91cFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRHcm91cFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZEdyb3VwVGhQcm9wczogZW1wdHlPYmosXG4gIGdldFRoZWFkUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZFRoUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUaGVhZEZpbHRlclByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRGaWx0ZXJUclByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGhlYWRGaWx0ZXJUaFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGJvZHlQcm9wczogZW1wdHlPYmosXG4gIGdldFRyR3JvdXBQcm9wczogZW1wdHlPYmosXG4gIGdldFRyUHJvcHM6IGVtcHR5T2JqLFxuICBnZXRUZFByb3BzOiBlbXB0eU9iaixcbiAgZ2V0VGZvb3RQcm9wczogZW1wdHlPYmosXG4gIGdldFRmb290VHJQcm9wczogZW1wdHlPYmosXG4gIGdldFRmb290VGRQcm9wczogZW1wdHlPYmosXG4gIGdldFBhZ2luYXRpb25Qcm9wczogZW1wdHlPYmosXG4gIGdldExvYWRpbmdQcm9wczogZW1wdHlPYmosXG4gIGdldE5vRGF0YVByb3BzOiBlbXB0eU9iaixcbiAgZ2V0UmVzaXplclByb3BzOiBlbXB0eU9iaixcblxuICAvLyBHbG9iYWwgQ29sdW1uIERlZmF1bHRzXG4gIGNvbHVtbjoge1xuICAgIC8vIFJlbmRlcmVyc1xuICAgIENlbGw6IHVuZGVmaW5lZCxcbiAgICBIZWFkZXI6IHVuZGVmaW5lZCxcbiAgICBGb290ZXI6IHVuZGVmaW5lZCxcbiAgICBBZ2dyZWdhdGVkOiB1bmRlZmluZWQsXG4gICAgUGl2b3Q6IHVuZGVmaW5lZCxcbiAgICBQaXZvdFZhbHVlOiB1bmRlZmluZWQsXG4gICAgRXhwYW5kZXI6IHVuZGVmaW5lZCxcbiAgICBGaWx0ZXI6IHVuZGVmaW5lZCxcbiAgICAvLyBBbGwgQ29sdW1uc1xuICAgIHNvcnRhYmxlOiB1bmRlZmluZWQsIC8vIHVzZSB0YWJsZSBkZWZhdWx0XG4gICAgcmVzaXphYmxlOiB1bmRlZmluZWQsIC8vIHVzZSB0YWJsZSBkZWZhdWx0XG4gICAgZmlsdGVyYWJsZTogdW5kZWZpbmVkLCAvLyB1c2UgdGFibGUgZGVmYXVsdFxuICAgIHNob3c6IHRydWUsXG4gICAgbWluV2lkdGg6IDEwMCxcbiAgICAvLyBDZWxscyBvbmx5XG4gICAgY2xhc3NOYW1lOiAnJyxcbiAgICBzdHlsZToge30sXG4gICAgZ2V0UHJvcHM6IGVtcHR5T2JqLFxuICAgIC8vIFBpdm90IG9ubHlcbiAgICBhZ2dyZWdhdGU6IHVuZGVmaW5lZCxcbiAgICAvLyBIZWFkZXJzIG9ubHlcbiAgICBoZWFkZXJDbGFzc05hbWU6ICcnLFxuICAgIGhlYWRlclN0eWxlOiB7fSxcbiAgICBnZXRIZWFkZXJQcm9wczogZW1wdHlPYmosXG4gICAgLy8gRm9vdGVycyBvbmx5XG4gICAgZm9vdGVyQ2xhc3NOYW1lOiAnJyxcbiAgICBmb290ZXJTdHlsZToge30sXG4gICAgZ2V0Rm9vdGVyUHJvcHM6IGVtcHR5T2JqLFxuICAgIGZpbHRlck1ldGhvZDogdW5kZWZpbmVkLFxuICAgIGZpbHRlckFsbDogZmFsc2UsXG4gICAgc29ydE1ldGhvZDogdW5kZWZpbmVkLFxuICB9LFxuXG4gIC8vIEdsb2JhbCBFeHBhbmRlciBDb2x1bW4gRGVmYXVsdHNcbiAgZXhwYW5kZXJEZWZhdWx0czoge1xuICAgIHNvcnRhYmxlOiBmYWxzZSxcbiAgICByZXNpemFibGU6IGZhbHNlLFxuICAgIGZpbHRlcmFibGU6IGZhbHNlLFxuICAgIHdpZHRoOiAzNSxcbiAgfSxcblxuICBwaXZvdERlZmF1bHRzOiB7XG4gICAgLy8gZXh0ZW5kIHRoZSBkZWZhdWx0cyBmb3IgcGl2b3RlZCBjb2x1bW5zIGhlcmVcbiAgfSxcblxuICAvLyBUZXh0XG4gIHByZXZpb3VzVGV4dDogJ1ByZXZpb3VzJyxcbiAgbmV4dFRleHQ6ICdOZXh0JyxcbiAgbG9hZGluZ1RleHQ6ICdMb2FkaW5nLi4uJyxcbiAgbm9EYXRhVGV4dDogJ05vIHJvd3MgZm91bmQnLFxuICBwYWdlVGV4dDogJ1BhZ2UnLFxuICBvZlRleHQ6ICdvZicsXG4gIHJvd3NUZXh0OiAncm93cycsXG5cbiAgLy8gQ29tcG9uZW50c1xuICBUYWJsZUNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXRhYmxlJywgJ1RhYmxlJyksXG4gIFRoZWFkQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdGhlYWQnLCAnVGhlYWQnKSxcbiAgVGJvZHlDb21wb25lbnQ6IF8ubWFrZVRlbXBsYXRlQ29tcG9uZW50KCdydC10Ym9keScsICdUYm9keScpLFxuICBUckdyb3VwQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdHItZ3JvdXAnLCAnVHJHcm91cCcpLFxuICBUckNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXRyJywgJ1RyJyksXG4gIFRoQ29tcG9uZW50OiAoeyB0b2dnbGVTb3J0LCBjbGFzc05hbWUsIGNoaWxkcmVuLCAuLi5yZXN0IH0pID0+IHtcbiAgICByZXR1cm4gKFxuICAgICAgPGRpdlxuICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NOYW1lLCAncnQtdGgnKX1cbiAgICAgICAgb25DbGljaz17ZSA9PiB7XG4gICAgICAgICAgdG9nZ2xlU29ydCAmJiB0b2dnbGVTb3J0KGUpXG4gICAgICAgIH19XG4gICAgICAgIHsuLi5yZXN0fVxuICAgICAgPlxuICAgICAgICB7Y2hpbGRyZW59XG4gICAgICA8L2Rpdj5cbiAgICApXG4gIH0sXG4gIFRkQ29tcG9uZW50OiBfLm1ha2VUZW1wbGF0ZUNvbXBvbmVudCgncnQtdGQnLCAnVGQnKSxcbiAgVGZvb3RDb21wb25lbnQ6IF8ubWFrZVRlbXBsYXRlQ29tcG9uZW50KCdydC10Zm9vdCcsICdUZm9vdCcpLFxuICBGaWx0ZXJDb21wb25lbnQ6ICh7IGZpbHRlciwgb25DaGFuZ2UgfSkgPT5cbiAgICA8aW5wdXRcbiAgICAgIHR5cGU9J3RleHQnXG4gICAgICBzdHlsZT17e1xuICAgICAgICB3aWR0aDogJzEwMCUnLFxuICAgICAgfX1cbiAgICAgIHZhbHVlPXtmaWx0ZXIgPyBmaWx0ZXIudmFsdWUgOiAnJ31cbiAgICAgIG9uQ2hhbmdlPXtldmVudCA9PiBvbkNoYW5nZShldmVudC50YXJnZXQudmFsdWUpfVxuICAgIC8+LFxuICBFeHBhbmRlckNvbXBvbmVudDogKHsgaXNFeHBhbmRlZCB9KSA9PlxuICAgIDxkaXYgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCdydC1leHBhbmRlcicsIGlzRXhwYW5kZWQgJiYgJy1vcGVuJyl9PlxuICAgICAgJmJ1bGw7XG4gICAgPC9kaXY+LFxuICBQaXZvdFZhbHVlQ29tcG9uZW50OiAoeyBzdWJSb3dzLCB2YWx1ZSB9KSA9PlxuICAgIDxzcGFuPlxuICAgICAge3ZhbHVlfSB7c3ViUm93cyAmJiBgKCR7c3ViUm93cy5sZW5ndGh9KWB9XG4gICAgPC9zcGFuPixcbiAgQWdncmVnYXRlZENvbXBvbmVudDogKHsgc3ViUm93cywgY29sdW1uIH0pID0+IHtcbiAgICBjb25zdCBwcmV2aWV3VmFsdWVzID0gc3ViUm93c1xuICAgICAgLmZpbHRlcihkID0+IHR5cGVvZiBkW2NvbHVtbi5pZF0gIT09ICd1bmRlZmluZWQnKVxuICAgICAgLm1hcCgocm93LCBpKSA9PlxuICAgICAgICA8c3BhbiBrZXk9e2l9PlxuICAgICAgICAgIHtyb3dbY29sdW1uLmlkXX1cbiAgICAgICAgICB7aSA8IHN1YlJvd3MubGVuZ3RoIC0gMSA/ICcsICcgOiAnJ31cbiAgICAgICAgPC9zcGFuPlxuICAgICAgKVxuICAgIHJldHVybiAoXG4gICAgICA8c3Bhbj5cbiAgICAgICAge3ByZXZpZXdWYWx1ZXN9XG4gICAgICA8L3NwYW4+XG4gICAgKVxuICB9LFxuICBQaXZvdENvbXBvbmVudDogdW5kZWZpbmVkLCAvLyB0aGlzIGlzIGEgY29tcHV0ZWQgZGVmYXVsdCBnZW5lcmF0ZWQgdXNpbmdcbiAgLy8gdGhlIEV4cGFuZGVyQ29tcG9uZW50IGFuZCBQaXZvdFZhbHVlQ29tcG9uZW50IGF0IHJ1bi10aW1lIGluIG1ldGhvZHMuanNcbiAgUGFnaW5hdGlvbkNvbXBvbmVudDogUGFnaW5hdGlvbixcbiAgUHJldmlvdXNDb21wb25lbnQ6IHVuZGVmaW5lZCxcbiAgTmV4dENvbXBvbmVudDogdW5kZWZpbmVkLFxuICBMb2FkaW5nQ29tcG9uZW50OiAoeyBjbGFzc05hbWUsIGxvYWRpbmcsIGxvYWRpbmdUZXh0LCAuLi5yZXN0IH0pID0+XG4gICAgPGRpdlxuICAgICAgY2xhc3NOYW1lPXtjbGFzc25hbWVzKCctbG9hZGluZycsIHsgJy1hY3RpdmUnOiBsb2FkaW5nIH0sIGNsYXNzTmFtZSl9XG4gICAgICB7Li4ucmVzdH1cbiAgICA+XG4gICAgICA8ZGl2IGNsYXNzTmFtZT0nLWxvYWRpbmctaW5uZXInPlxuICAgICAgICB7bG9hZGluZ1RleHR9XG4gICAgICA8L2Rpdj5cbiAgICA8L2Rpdj4sXG4gIE5vRGF0YUNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LW5vRGF0YScsICdOb0RhdGEnKSxcbiAgUmVzaXplckNvbXBvbmVudDogXy5tYWtlVGVtcGxhdGVDb21wb25lbnQoJ3J0LXJlc2l6ZXInLCAnUmVzaXplcicpLFxuICBQYWRSb3dDb21wb25lbnQ6ICgpID0+IDxzcGFuPiZuYnNwOzwvc3Bhbj4sXG59XG4iXX0= /***/ }), -/* 421 */ +/* 362 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var deselectCurrent = __webpack_require__(422); +Object.defineProperty(exports, "__esModule", { + value: true +}); -var defaultMessage = 'Copy to clipboard: #{key}, Enter'; +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); -function format(message) { - var copyKey = (/mac os x/i.test(navigator.userAgent) ? '⌘' : 'Ctrl') + '+C'; - return message.replace(/#{\s*key\s*}/g, copyKey); -} +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -function copy(text, options) { - var debug, message, reselectPrevious, range, selection, mark, success = false; - if (!options) { options = {}; } - debug = options.debug || false; - try { - reselectPrevious = deselectCurrent(); +var _react = __webpack_require__(6); - range = document.createRange(); - selection = document.getSelection(); +var _react2 = _interopRequireDefault(_react); - mark = document.createElement('span'); - mark.textContent = text; - // reset user styles for span element - mark.style.all = 'unset'; - // prevents scrolling to the end of the page - mark.style.position = 'fixed'; - mark.style.top = 0; - mark.style.clip = 'rect(0, 0, 0, 0)'; - // used to preserve spaces and line breaks - mark.style.whiteSpace = 'pre'; - // do not inherit user-select (it may be `none`) - mark.style.webkitUserSelect = 'text'; - mark.style.MozUserSelect = 'text'; - mark.style.msUserSelect = 'text'; - mark.style.userSelect = 'text'; +var _classnames = __webpack_require__(41); - document.body.appendChild(mark); +var _classnames2 = _interopRequireDefault(_classnames); - range.selectNode(mark); - selection.addRange(range); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - var successful = document.execCommand('copy'); - if (!successful) { - throw new Error('copy command was unsuccessful'); - } - success = true; - } catch (err) { - debug && console.error('unable to copy using execCommand: ', err); - debug && console.warn('trying IE specific stuff'); - try { - window.clipboardData.setData('text', text); - success = true; - } catch (err) { - debug && console.error('unable to copy using clipboardData: ', err); - debug && console.error('falling back to prompt'); - message = format('message' in options ? options.message : defaultMessage); - window.prompt(message, text); - } - } finally { - if (selection) { - if (typeof selection.removeRange == 'function') { - selection.removeRange(range); - } else { - selection.removeAllRanges(); - } - } +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - if (mark) { - document.body.removeChild(mark); - } - reselectPrevious(); - } +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } - return success; -} +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } -module.exports = copy; +// +// import _ from './utils' +var defaultButton = function defaultButton(props) { + return _react2.default.createElement( + 'button', + _extends({ type: 'button' }, props, { className: '-btn' }), + props.children + ); +}; -/***/ }), -/* 422 */ -/***/ (function(module, exports) { +var ReactTablePagination = function (_Component) { + _inherits(ReactTablePagination, _Component); + function ReactTablePagination(props) { + _classCallCheck(this, ReactTablePagination); -module.exports = function () { - var selection = document.getSelection(); - if (!selection.rangeCount) { - return function () {}; - } - var active = document.activeElement; + var _this = _possibleConstructorReturn(this, (ReactTablePagination.__proto__ || Object.getPrototypeOf(ReactTablePagination)).call(this)); - var ranges = []; - for (var i = 0; i < selection.rangeCount; i++) { - ranges.push(selection.getRangeAt(i)); + _this.getSafePage = _this.getSafePage.bind(_this); + _this.changePage = _this.changePage.bind(_this); + _this.applyPage = _this.applyPage.bind(_this); + + _this.state = { + page: props.page + }; + return _this; } - switch (active.tagName.toUpperCase()) { // .toUpperCase handles XHTML - case 'INPUT': - case 'TEXTAREA': - active.blur(); - break; + _createClass(ReactTablePagination, [{ + key: 'componentWillReceiveProps', + value: function componentWillReceiveProps(nextProps) { + this.setState({ page: nextProps.page }); + } + }, { + key: 'getSafePage', + value: function getSafePage(page) { + if (isNaN(page)) { + page = this.props.page; + } + return Math.min(Math.max(page, 0), this.props.pages - 1); + } + }, { + key: 'changePage', + value: function changePage(page) { + page = this.getSafePage(page); + this.setState({ page: page }); + if (this.props.page !== page) { + this.props.onPageChange(page); + } + } + }, { + key: 'applyPage', + value: function applyPage(e) { + e && e.preventDefault(); + var page = this.state.page; + this.changePage(page === '' ? this.props.page : page); + } + }, { + key: 'render', + value: function render() { + var _this2 = this; - default: - active = null; - break; - } + var _props = this.props, + pages = _props.pages, + page = _props.page, + showPageSizeOptions = _props.showPageSizeOptions, + pageSizeOptions = _props.pageSizeOptions, + pageSize = _props.pageSize, + showPageJump = _props.showPageJump, + canPrevious = _props.canPrevious, + canNext = _props.canNext, + onPageSizeChange = _props.onPageSizeChange, + className = _props.className, + _props$PreviousCompon = _props.PreviousComponent, + PreviousComponent = _props$PreviousCompon === undefined ? defaultButton : _props$PreviousCompon, + _props$NextComponent = _props.NextComponent, + NextComponent = _props$NextComponent === undefined ? defaultButton : _props$NextComponent; - selection.removeAllRanges(); - return function () { - selection.type === 'Caret' && - selection.removeAllRanges(); - if (!selection.rangeCount) { - ranges.forEach(function(range) { - selection.addRange(range); - }); + return _react2.default.createElement( + 'div', + { + className: (0, _classnames2.default)(className, '-pagination'), + style: this.props.paginationStyle + }, + _react2.default.createElement( + 'div', + { className: '-previous' }, + _react2.default.createElement( + PreviousComponent, + { + onClick: function onClick(e) { + if (!canPrevious) return; + _this2.changePage(page - 1); + }, + disabled: !canPrevious + }, + this.props.previousText + ) + ), + _react2.default.createElement( + 'div', + { className: '-center' }, + _react2.default.createElement( + 'span', + { className: '-pageInfo' }, + this.props.pageText, + ' ', + showPageJump ? _react2.default.createElement( + 'div', + { className: '-pageJump' }, + _react2.default.createElement('input', { + type: this.state.page === '' ? 'text' : 'number', + onChange: function onChange(e) { + var val = e.target.value; + var page = val - 1; + if (val === '') { + return _this2.setState({ page: val }); + } + _this2.setState({ page: _this2.getSafePage(page) }); + }, + value: this.state.page === '' ? '' : this.state.page + 1, + onBlur: this.applyPage, + onKeyPress: function onKeyPress(e) { + if (e.which === 13 || e.keyCode === 13) { + _this2.applyPage(); + } + } + }) + ) : _react2.default.createElement( + 'span', + { className: '-currentPage' }, + page + 1 + ), + ' ', + this.props.ofText, + ' ', + _react2.default.createElement( + 'span', + { className: '-totalPages' }, + pages || 1 + ) + ), + showPageSizeOptions && _react2.default.createElement( + 'span', + { className: 'select-wrap -pageSizeOptions' }, + _react2.default.createElement( + 'select', + { + onChange: function onChange(e) { + return onPageSizeChange(Number(e.target.value)); + }, + value: pageSize + }, + pageSizeOptions.map(function (option, i) { + return _react2.default.createElement( + 'option', + { key: i, value: option }, + option, + ' ', + _this2.props.rowsText + ); + }) + ) + ) + ), + _react2.default.createElement( + 'div', + { className: '-next' }, + _react2.default.createElement( + NextComponent, + { + onClick: function onClick(e) { + if (!canNext) return; + _this2.changePage(page + 1); + }, + disabled: !canNext + }, + this.props.nextText + ) + ) + ); } + }]); - active && - active.focus(); - }; -}; + return ReactTablePagination; +}(_react.Component); +exports.default = ReactTablePagination; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9wYWdpbmF0aW9uLmpzIl0sIm5hbWVzIjpbImRlZmF1bHRCdXR0b24iLCJwcm9wcyIsImNoaWxkcmVuIiwiUmVhY3RUYWJsZVBhZ2luYXRpb24iLCJnZXRTYWZlUGFnZSIsImJpbmQiLCJjaGFuZ2VQYWdlIiwiYXBwbHlQYWdlIiwic3RhdGUiLCJwYWdlIiwibmV4dFByb3BzIiwic2V0U3RhdGUiLCJpc05hTiIsIk1hdGgiLCJtaW4iLCJtYXgiLCJwYWdlcyIsIm9uUGFnZUNoYW5nZSIsImUiLCJwcmV2ZW50RGVmYXVsdCIsInNob3dQYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZU9wdGlvbnMiLCJwYWdlU2l6ZSIsInNob3dQYWdlSnVtcCIsImNhblByZXZpb3VzIiwiY2FuTmV4dCIsIm9uUGFnZVNpemVDaGFuZ2UiLCJjbGFzc05hbWUiLCJQcmV2aW91c0NvbXBvbmVudCIsIk5leHRDb21wb25lbnQiLCJwYWdpbmF0aW9uU3R5bGUiLCJwcmV2aW91c1RleHQiLCJwYWdlVGV4dCIsInZhbCIsInRhcmdldCIsInZhbHVlIiwid2hpY2giLCJrZXlDb2RlIiwib2ZUZXh0IiwiTnVtYmVyIiwibWFwIiwib3B0aW9uIiwiaSIsInJvd3NUZXh0IiwibmV4dFRleHQiXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7QUFBQTs7OztBQUNBOzs7Ozs7Ozs7Ozs7QUFDQTtBQUNBOztBQUVBLElBQU1BLGdCQUFnQixTQUFoQkEsYUFBZ0I7QUFBQSxTQUNwQjtBQUFBO0FBQUEsZUFBUSxNQUFLLFFBQWIsSUFBMEJDLEtBQTFCLElBQWlDLFdBQVUsTUFBM0M7QUFDR0EsVUFBTUM7QUFEVCxHQURvQjtBQUFBLENBQXRCOztJQUtxQkMsb0I7OztBQUNuQixnQ0FBYUYsS0FBYixFQUFvQjtBQUFBOztBQUFBOztBQUdsQixVQUFLRyxXQUFMLEdBQW1CLE1BQUtBLFdBQUwsQ0FBaUJDLElBQWpCLE9BQW5CO0FBQ0EsVUFBS0MsVUFBTCxHQUFrQixNQUFLQSxVQUFMLENBQWdCRCxJQUFoQixPQUFsQjtBQUNBLFVBQUtFLFNBQUwsR0FBaUIsTUFBS0EsU0FBTCxDQUFlRixJQUFmLE9BQWpCOztBQUVBLFVBQUtHLEtBQUwsR0FBYTtBQUNYQyxZQUFNUixNQUFNUTtBQURELEtBQWI7QUFQa0I7QUFVbkI7Ozs7OENBRTBCQyxTLEVBQVc7QUFDcEMsV0FBS0MsUUFBTCxDQUFjLEVBQUVGLE1BQU1DLFVBQVVELElBQWxCLEVBQWQ7QUFDRDs7O2dDQUVZQSxJLEVBQU07QUFDakIsVUFBSUcsTUFBTUgsSUFBTixDQUFKLEVBQWlCO0FBQ2ZBLGVBQU8sS0FBS1IsS0FBTCxDQUFXUSxJQUFsQjtBQUNEO0FBQ0QsYUFBT0ksS0FBS0MsR0FBTCxDQUFTRCxLQUFLRSxHQUFMLENBQVNOLElBQVQsRUFBZSxDQUFmLENBQVQsRUFBNEIsS0FBS1IsS0FBTCxDQUFXZSxLQUFYLEdBQW1CLENBQS9DLENBQVA7QUFDRDs7OytCQUVXUCxJLEVBQU07QUFDaEJBLGFBQU8sS0FBS0wsV0FBTCxDQUFpQkssSUFBakIsQ0FBUDtBQUNBLFdBQUtFLFFBQUwsQ0FBYyxFQUFFRixVQUFGLEVBQWQ7QUFDQSxVQUFJLEtBQUtSLEtBQUwsQ0FBV1EsSUFBWCxLQUFvQkEsSUFBeEIsRUFBOEI7QUFDNUIsYUFBS1IsS0FBTCxDQUFXZ0IsWUFBWCxDQUF3QlIsSUFBeEI7QUFDRDtBQUNGOzs7OEJBRVVTLEMsRUFBRztBQUNaQSxXQUFLQSxFQUFFQyxjQUFGLEVBQUw7QUFDQSxVQUFNVixPQUFPLEtBQUtELEtBQUwsQ0FBV0MsSUFBeEI7QUFDQSxXQUFLSCxVQUFMLENBQWdCRyxTQUFTLEVBQVQsR0FBYyxLQUFLUixLQUFMLENBQVdRLElBQXpCLEdBQWdDQSxJQUFoRDtBQUNEOzs7NkJBRVM7QUFBQTs7QUFBQSxtQkFnQkosS0FBS1IsS0FoQkQ7QUFBQSxVQUdOZSxLQUhNLFVBR05BLEtBSE07QUFBQSxVQUtOUCxJQUxNLFVBS05BLElBTE07QUFBQSxVQU1OVyxtQkFOTSxVQU1OQSxtQkFOTTtBQUFBLFVBT05DLGVBUE0sVUFPTkEsZUFQTTtBQUFBLFVBUU5DLFFBUk0sVUFRTkEsUUFSTTtBQUFBLFVBU05DLFlBVE0sVUFTTkEsWUFUTTtBQUFBLFVBVU5DLFdBVk0sVUFVTkEsV0FWTTtBQUFBLFVBV05DLE9BWE0sVUFXTkEsT0FYTTtBQUFBLFVBWU5DLGdCQVpNLFVBWU5BLGdCQVpNO0FBQUEsVUFhTkMsU0FiTSxVQWFOQSxTQWJNO0FBQUEseUNBY05DLGlCQWRNO0FBQUEsVUFjTkEsaUJBZE0seUNBY2M1QixhQWRkO0FBQUEsd0NBZU42QixhQWZNO0FBQUEsVUFlTkEsYUFmTSx3Q0FlVTdCLGFBZlY7OztBQWtCUixhQUNFO0FBQUE7QUFBQTtBQUNFLHFCQUFXLDBCQUFXMkIsU0FBWCxFQUFzQixhQUF0QixDQURiO0FBRUUsaUJBQU8sS0FBSzFCLEtBQUwsQ0FBVzZCO0FBRnBCO0FBSUU7QUFBQTtBQUFBLFlBQUssV0FBVSxXQUFmO0FBQ0U7QUFBQyw2QkFBRDtBQUFBO0FBQ0UsdUJBQVMsb0JBQUs7QUFDWixvQkFBSSxDQUFDTixXQUFMLEVBQWtCO0FBQ2xCLHVCQUFLbEIsVUFBTCxDQUFnQkcsT0FBTyxDQUF2QjtBQUNELGVBSkg7QUFLRSx3QkFBVSxDQUFDZTtBQUxiO0FBT0csaUJBQUt2QixLQUFMLENBQVc4QjtBQVBkO0FBREYsU0FKRjtBQWVFO0FBQUE7QUFBQSxZQUFLLFdBQVUsU0FBZjtBQUNFO0FBQUE7QUFBQSxjQUFNLFdBQVUsV0FBaEI7QUFDRyxpQkFBSzlCLEtBQUwsQ0FBVytCLFFBRGQ7QUFDd0IsZUFEeEI7QUFFR1QsMkJBQ0c7QUFBQTtBQUFBLGdCQUFLLFdBQVUsV0FBZjtBQUNBO0FBQ0Usc0JBQU0sS0FBS2YsS0FBTCxDQUFXQyxJQUFYLEtBQW9CLEVBQXBCLEdBQXlCLE1BQXpCLEdBQWtDLFFBRDFDO0FBRUUsMEJBQVUscUJBQUs7QUFDYixzQkFBTXdCLE1BQU1mLEVBQUVnQixNQUFGLENBQVNDLEtBQXJCO0FBQ0Esc0JBQU0xQixPQUFPd0IsTUFBTSxDQUFuQjtBQUNBLHNCQUFJQSxRQUFRLEVBQVosRUFBZ0I7QUFDZCwyQkFBTyxPQUFLdEIsUUFBTCxDQUFjLEVBQUVGLE1BQU13QixHQUFSLEVBQWQsQ0FBUDtBQUNEO0FBQ0QseUJBQUt0QixRQUFMLENBQWMsRUFBRUYsTUFBTSxPQUFLTCxXQUFMLENBQWlCSyxJQUFqQixDQUFSLEVBQWQ7QUFDRCxpQkFUSDtBQVVFLHVCQUFPLEtBQUtELEtBQUwsQ0FBV0MsSUFBWCxLQUFvQixFQUFwQixHQUF5QixFQUF6QixHQUE4QixLQUFLRCxLQUFMLENBQVdDLElBQVgsR0FBa0IsQ0FWekQ7QUFXRSx3QkFBUSxLQUFLRixTQVhmO0FBWUUsNEJBQVksdUJBQUs7QUFDZixzQkFBSVcsRUFBRWtCLEtBQUYsS0FBWSxFQUFaLElBQWtCbEIsRUFBRW1CLE9BQUYsS0FBYyxFQUFwQyxFQUF3QztBQUN0QywyQkFBSzlCLFNBQUw7QUFDRDtBQUNGO0FBaEJIO0FBREEsYUFESCxHQXFCRztBQUFBO0FBQUEsZ0JBQU0sV0FBVSxjQUFoQjtBQUNDRSxxQkFBTztBQURSLGFBdkJOO0FBeUJhLGVBekJiO0FBMEJHLGlCQUFLUixLQUFMLENBQVdxQyxNQTFCZDtBQTBCc0IsZUExQnRCO0FBMkJFO0FBQUE7QUFBQSxnQkFBTSxXQUFVLGFBQWhCO0FBQStCdEIsdUJBQVM7QUFBeEM7QUEzQkYsV0FERjtBQThCR0ksaUNBQ0M7QUFBQTtBQUFBLGNBQU0sV0FBVSw4QkFBaEI7QUFDRTtBQUFBO0FBQUE7QUFDRSwwQkFBVTtBQUFBLHlCQUFLTSxpQkFBaUJhLE9BQU9yQixFQUFFZ0IsTUFBRixDQUFTQyxLQUFoQixDQUFqQixDQUFMO0FBQUEsaUJBRFo7QUFFRSx1QkFBT2I7QUFGVDtBQUlHRCw4QkFBZ0JtQixHQUFoQixDQUFvQixVQUFDQyxNQUFELEVBQVNDLENBQVQsRUFBZTtBQUNsQyx1QkFDRTtBQUFBO0FBQUEsb0JBQVEsS0FBS0EsQ0FBYixFQUFnQixPQUFPRCxNQUF2QjtBQUNHQSx3QkFESDtBQUFBO0FBQ1kseUJBQUt4QyxLQUFMLENBQVcwQztBQUR2QixpQkFERjtBQUtELGVBTkE7QUFKSDtBQURGO0FBL0JKLFNBZkY7QUE2REU7QUFBQTtBQUFBLFlBQUssV0FBVSxPQUFmO0FBQ0U7QUFBQyx5QkFBRDtBQUFBO0FBQ0UsdUJBQVMsb0JBQUs7QUFDWixvQkFBSSxDQUFDbEIsT0FBTCxFQUFjO0FBQ2QsdUJBQUtuQixVQUFMLENBQWdCRyxPQUFPLENBQXZCO0FBQ0QsZUFKSDtBQUtFLHdCQUFVLENBQUNnQjtBQUxiO0FBT0csaUJBQUt4QixLQUFMLENBQVcyQztBQVBkO0FBREY7QUE3REYsT0FERjtBQTJFRDs7Ozs7O2tCQW5Ja0J6QyxvQiIsImZpbGUiOiJwYWdpbmF0aW9uLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IFJlYWN0LCB7IENvbXBvbmVudCB9IGZyb20gJ3JlYWN0J1xuaW1wb3J0IGNsYXNzbmFtZXMgZnJvbSAnY2xhc3NuYW1lcydcbi8vXG4vLyBpbXBvcnQgXyBmcm9tICcuL3V0aWxzJ1xuXG5jb25zdCBkZWZhdWx0QnV0dG9uID0gcHJvcHMgPT5cbiAgPGJ1dHRvbiB0eXBlPSdidXR0b24nIHsuLi5wcm9wc30gY2xhc3NOYW1lPSctYnRuJz5cbiAgICB7cHJvcHMuY2hpbGRyZW59XG4gIDwvYnV0dG9uPlxuXG5leHBvcnQgZGVmYXVsdCBjbGFzcyBSZWFjdFRhYmxlUGFnaW5hdGlvbiBleHRlbmRzIENvbXBvbmVudCB7XG4gIGNvbnN0cnVjdG9yIChwcm9wcykge1xuICAgIHN1cGVyKClcblxuICAgIHRoaXMuZ2V0U2FmZVBhZ2UgPSB0aGlzLmdldFNhZmVQYWdlLmJpbmQodGhpcylcbiAgICB0aGlzLmNoYW5nZVBhZ2UgPSB0aGlzLmNoYW5nZVBhZ2UuYmluZCh0aGlzKVxuICAgIHRoaXMuYXBwbHlQYWdlID0gdGhpcy5hcHBseVBhZ2UuYmluZCh0aGlzKVxuXG4gICAgdGhpcy5zdGF0ZSA9IHtcbiAgICAgIHBhZ2U6IHByb3BzLnBhZ2UsXG4gICAgfVxuICB9XG5cbiAgY29tcG9uZW50V2lsbFJlY2VpdmVQcm9wcyAobmV4dFByb3BzKSB7XG4gICAgdGhpcy5zZXRTdGF0ZSh7IHBhZ2U6IG5leHRQcm9wcy5wYWdlIH0pXG4gIH1cblxuICBnZXRTYWZlUGFnZSAocGFnZSkge1xuICAgIGlmIChpc05hTihwYWdlKSkge1xuICAgICAgcGFnZSA9IHRoaXMucHJvcHMucGFnZVxuICAgIH1cbiAgICByZXR1cm4gTWF0aC5taW4oTWF0aC5tYXgocGFnZSwgMCksIHRoaXMucHJvcHMucGFnZXMgLSAxKVxuICB9XG5cbiAgY2hhbmdlUGFnZSAocGFnZSkge1xuICAgIHBhZ2UgPSB0aGlzLmdldFNhZmVQYWdlKHBhZ2UpXG4gICAgdGhpcy5zZXRTdGF0ZSh7IHBhZ2UgfSlcbiAgICBpZiAodGhpcy5wcm9wcy5wYWdlICE9PSBwYWdlKSB7XG4gICAgICB0aGlzLnByb3BzLm9uUGFnZUNoYW5nZShwYWdlKVxuICAgIH1cbiAgfVxuXG4gIGFwcGx5UGFnZSAoZSkge1xuICAgIGUgJiYgZS5wcmV2ZW50RGVmYXVsdCgpXG4gICAgY29uc3QgcGFnZSA9IHRoaXMuc3RhdGUucGFnZVxuICAgIHRoaXMuY2hhbmdlUGFnZShwYWdlID09PSAnJyA/IHRoaXMucHJvcHMucGFnZSA6IHBhZ2UpXG4gIH1cblxuICByZW5kZXIgKCkge1xuICAgIGNvbnN0IHtcbiAgICAgIC8vIENvbXB1dGVkXG4gICAgICBwYWdlcyxcbiAgICAgIC8vIFByb3BzXG4gICAgICBwYWdlLFxuICAgICAgc2hvd1BhZ2VTaXplT3B0aW9ucyxcbiAgICAgIHBhZ2VTaXplT3B0aW9ucyxcbiAgICAgIHBhZ2VTaXplLFxuICAgICAgc2hvd1BhZ2VKdW1wLFxuICAgICAgY2FuUHJldmlvdXMsXG4gICAgICBjYW5OZXh0LFxuICAgICAgb25QYWdlU2l6ZUNoYW5nZSxcbiAgICAgIGNsYXNzTmFtZSxcbiAgICAgIFByZXZpb3VzQ29tcG9uZW50ID0gZGVmYXVsdEJ1dHRvbixcbiAgICAgIE5leHRDb21wb25lbnQgPSBkZWZhdWx0QnV0dG9uLFxuICAgIH0gPSB0aGlzLnByb3BzXG5cbiAgICByZXR1cm4gKFxuICAgICAgPGRpdlxuICAgICAgICBjbGFzc05hbWU9e2NsYXNzbmFtZXMoY2xhc3NOYW1lLCAnLXBhZ2luYXRpb24nKX1cbiAgICAgICAgc3R5bGU9e3RoaXMucHJvcHMucGFnaW5hdGlvblN0eWxlfVxuICAgICAgPlxuICAgICAgICA8ZGl2IGNsYXNzTmFtZT0nLXByZXZpb3VzJz5cbiAgICAgICAgICA8UHJldmlvdXNDb21wb25lbnRcbiAgICAgICAgICAgIG9uQ2xpY2s9e2UgPT4ge1xuICAgICAgICAgICAgICBpZiAoIWNhblByZXZpb3VzKSByZXR1cm5cbiAgICAgICAgICAgICAgdGhpcy5jaGFuZ2VQYWdlKHBhZ2UgLSAxKVxuICAgICAgICAgICAgfX1cbiAgICAgICAgICAgIGRpc2FibGVkPXshY2FuUHJldmlvdXN9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge3RoaXMucHJvcHMucHJldmlvdXNUZXh0fVxuICAgICAgICAgIDwvUHJldmlvdXNDb21wb25lbnQ+XG4gICAgICAgIDwvZGl2PlxuICAgICAgICA8ZGl2IGNsYXNzTmFtZT0nLWNlbnRlcic+XG4gICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSctcGFnZUluZm8nPlxuICAgICAgICAgICAge3RoaXMucHJvcHMucGFnZVRleHR9eycgJ31cbiAgICAgICAgICAgIHtzaG93UGFnZUp1bXBcbiAgICAgICAgICAgICAgPyA8ZGl2IGNsYXNzTmFtZT0nLXBhZ2VKdW1wJz5cbiAgICAgICAgICAgICAgICA8aW5wdXRcbiAgICAgICAgICAgICAgICAgIHR5cGU9e3RoaXMuc3RhdGUucGFnZSA9PT0gJycgPyAndGV4dCcgOiAnbnVtYmVyJ31cbiAgICAgICAgICAgICAgICAgIG9uQ2hhbmdlPXtlID0+IHtcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgdmFsID0gZS50YXJnZXQudmFsdWVcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgcGFnZSA9IHZhbCAtIDFcbiAgICAgICAgICAgICAgICAgICAgaWYgKHZhbCA9PT0gJycpIHtcbiAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdGhpcy5zZXRTdGF0ZSh7IHBhZ2U6IHZhbCB9KVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuc2V0U3RhdGUoeyBwYWdlOiB0aGlzLmdldFNhZmVQYWdlKHBhZ2UpIH0pXG4gICAgICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICAgICAgdmFsdWU9e3RoaXMuc3RhdGUucGFnZSA9PT0gJycgPyAnJyA6IHRoaXMuc3RhdGUucGFnZSArIDF9XG4gICAgICAgICAgICAgICAgICBvbkJsdXI9e3RoaXMuYXBwbHlQYWdlfVxuICAgICAgICAgICAgICAgICAgb25LZXlQcmVzcz17ZSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChlLndoaWNoID09PSAxMyB8fCBlLmtleUNvZGUgPT09IDEzKSB7XG4gICAgICAgICAgICAgICAgICAgICAgdGhpcy5hcHBseVBhZ2UoKVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICB9fVxuICAgICAgICAgICAgICAgIC8+XG4gICAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgICAgICA6IDxzcGFuIGNsYXNzTmFtZT0nLWN1cnJlbnRQYWdlJz5cbiAgICAgICAgICAgICAgICB7cGFnZSArIDF9XG4gICAgICAgICAgICAgIDwvc3Bhbj59eycgJ31cbiAgICAgICAgICAgIHt0aGlzLnByb3BzLm9mVGV4dH17JyAnfVxuICAgICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSctdG90YWxQYWdlcyc+e3BhZ2VzIHx8IDF9PC9zcGFuPlxuICAgICAgICAgIDwvc3Bhbj5cbiAgICAgICAgICB7c2hvd1BhZ2VTaXplT3B0aW9ucyAmJlxuICAgICAgICAgICAgPHNwYW4gY2xhc3NOYW1lPSdzZWxlY3Qtd3JhcCAtcGFnZVNpemVPcHRpb25zJz5cbiAgICAgICAgICAgICAgPHNlbGVjdFxuICAgICAgICAgICAgICAgIG9uQ2hhbmdlPXtlID0+IG9uUGFnZVNpemVDaGFuZ2UoTnVtYmVyKGUudGFyZ2V0LnZhbHVlKSl9XG4gICAgICAgICAgICAgICAgdmFsdWU9e3BhZ2VTaXplfVxuICAgICAgICAgICAgICA+XG4gICAgICAgICAgICAgICAge3BhZ2VTaXplT3B0aW9ucy5tYXAoKG9wdGlvbiwgaSkgPT4ge1xuICAgICAgICAgICAgICAgICAgcmV0dXJuIChcbiAgICAgICAgICAgICAgICAgICAgPG9wdGlvbiBrZXk9e2l9IHZhbHVlPXtvcHRpb259PlxuICAgICAgICAgICAgICAgICAgICAgIHtvcHRpb259IHt0aGlzLnByb3BzLnJvd3NUZXh0fVxuICAgICAgICAgICAgICAgICAgICA8L29wdGlvbj5cbiAgICAgICAgICAgICAgICAgIClcbiAgICAgICAgICAgICAgICB9KX1cbiAgICAgICAgICAgICAgPC9zZWxlY3Q+XG4gICAgICAgICAgICA8L3NwYW4+fVxuICAgICAgICA8L2Rpdj5cbiAgICAgICAgPGRpdiBjbGFzc05hbWU9Jy1uZXh0Jz5cbiAgICAgICAgICA8TmV4dENvbXBvbmVudFxuICAgICAgICAgICAgb25DbGljaz17ZSA9PiB7XG4gICAgICAgICAgICAgIGlmICghY2FuTmV4dCkgcmV0dXJuXG4gICAgICAgICAgICAgIHRoaXMuY2hhbmdlUGFnZShwYWdlICsgMSlcbiAgICAgICAgICAgIH19XG4gICAgICAgICAgICBkaXNhYmxlZD17IWNhbk5leHR9XG4gICAgICAgICAgPlxuICAgICAgICAgICAge3RoaXMucHJvcHMubmV4dFRleHR9XG4gICAgICAgICAgPC9OZXh0Q29tcG9uZW50PlxuICAgICAgICA8L2Rpdj5cbiAgICAgIDwvZGl2PlxuICAgIClcbiAgfVxufVxuIl19 /***/ }), -/* 423 */ +/* 363 */ /***/ (function(module, exports, __webpack_require__) { -var basex = __webpack_require__(424) +var basex = __webpack_require__(364) var ALPHABET = '123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz' module.exports = basex(ALPHABET) /***/ }), -/* 424 */ +/* 364 */ /***/ (function(module, exports, __webpack_require__) { // base-x encoding @@ -65750,7 +55085,7 @@ module.exports = basex(ALPHABET) // Merged Buffer refactorings from base58-native by Stephen Pair // Copyright (c) 2013 BitPay Inc -var Buffer = __webpack_require__(18).Buffer +var Buffer = __webpack_require__(7).Buffer module.exports = function base (ALPHABET) { var ALPHABET_MAP = {} @@ -65836,7 +55171,7 @@ module.exports = function base (ALPHABET) { /***/ }), -/* 425 */ +/* 365 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -65871,16 +55206,16 @@ module.exports = function hash (buf, fn) { return buf } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 426 */ +/* 366 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(Buffer) { -var Transform = __webpack_require__(261).Transform -var inherits = __webpack_require__(11) +var Transform = __webpack_require__(98).Transform +var inherits = __webpack_require__(4) function HashBase (blockSize) { Transform.call(this) @@ -65962,16 +55297,16 @@ HashBase.prototype._digest = function () { module.exports = HashBase -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 427 */ +/* 367 */ /***/ (function(module, exports) { /* (ignored) */ /***/ }), -/* 428 */ +/* 368 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -65981,7 +55316,7 @@ module.exports = HashBase function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -var Buffer = __webpack_require__(18).Buffer; +var Buffer = __webpack_require__(7).Buffer; /*</replacement>*/ function copyBuffer(src, target, offset) { @@ -66051,7 +55386,7 @@ module.exports = function () { }(); /***/ }), -/* 429 */ +/* 369 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(global, process) {(function (global, undefined) { @@ -66241,10 +55576,10 @@ module.exports = function () { attachTo.clearImmediate = clearImmediate; }(typeof self === "undefined" ? typeof global === "undefined" ? this : global : self)); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(67), __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) /***/ }), -/* 430 */ +/* 370 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(global) { @@ -66315,10 +55650,10 @@ function config (name) { return String(val).toLowerCase() === 'true'; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(67))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24))) /***/ }), -/* 431 */ +/* 371 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -66351,11 +55686,11 @@ function config (name) { module.exports = PassThrough; -var Transform = __webpack_require__(311); +var Transform = __webpack_require__(165); /*<replacement>*/ -var util = __webpack_require__(237); -util.inherits = __webpack_require__(11); +var util = __webpack_require__(49); +util.inherits = __webpack_require__(4); /*</replacement>*/ util.inherits(PassThrough, Transform); @@ -66371,35 +55706,35 @@ PassThrough.prototype._transform = function (chunk, encoding, cb) { }; /***/ }), -/* 432 */ +/* 372 */ /***/ (function(module, exports, __webpack_require__) { -module.exports = __webpack_require__(263); +module.exports = __webpack_require__(101); /***/ }), -/* 433 */ +/* 373 */ /***/ (function(module, exports, __webpack_require__) { -module.exports = __webpack_require__(112); +module.exports = __webpack_require__(34); /***/ }), -/* 434 */ +/* 374 */ /***/ (function(module, exports, __webpack_require__) { -module.exports = __webpack_require__(262).Transform +module.exports = __webpack_require__(100).Transform /***/ }), -/* 435 */ +/* 375 */ /***/ (function(module, exports, __webpack_require__) { -module.exports = __webpack_require__(262).PassThrough +module.exports = __webpack_require__(100).PassThrough /***/ }), -/* 436 */ +/* 376 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {/* @@ -66410,8 +55745,8 @@ module.exports = __webpack_require__(262).PassThrough * operation was added. */ -var inherits = __webpack_require__(11) -var Hash = __webpack_require__(114) +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) var K = [ 0x5a827999, 0x6ed9eba1, 0x8f1bbcdc | 0, 0xca62c1d6 | 0 @@ -66496,10 +55831,10 @@ Sha.prototype._hash = function () { module.exports = Sha -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 437 */ +/* 377 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {/* @@ -66511,8 +55846,8 @@ module.exports = Sha * See http://pajhome.org.uk/crypt/md5 for details. */ -var inherits = __webpack_require__(11) -var Hash = __webpack_require__(114) +var inherits = __webpack_require__(4) +var Hash = __webpack_require__(42) var K = [ 0x5a827999, 0x6ed9eba1, 0x8f1bbcdc | 0, 0xca62c1d6 | 0 @@ -66601,10 +55936,10 @@ Sha1.prototype._hash = function () { module.exports = Sha1 -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 438 */ +/* 378 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {/** @@ -66615,9 +55950,9 @@ module.exports = Sha1 * */ -var inherits = __webpack_require__(11) -var Sha256 = __webpack_require__(312) -var Hash = __webpack_require__(114) +var inherits = __webpack_require__(4) +var Sha256 = __webpack_require__(166) +var Hash = __webpack_require__(42) var W = new Array(64) @@ -66660,15 +55995,15 @@ Sha224.prototype._hash = function () { module.exports = Sha224 -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 439 */ +/* 379 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var inherits = __webpack_require__(11) -var SHA512 = __webpack_require__(313) -var Hash = __webpack_require__(114) +/* WEBPACK VAR INJECTION */(function(Buffer) {var inherits = __webpack_require__(4) +var SHA512 = __webpack_require__(167) +var Hash = __webpack_require__(42) var W = new Array(160) @@ -66723,17 +56058,17 @@ Sha384.prototype._hash = function () { module.exports = Sha384 -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 440 */ +/* 380 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var assert = __webpack_require__(441) -var der = __webpack_require__(442) -var messages = __webpack_require__(315) +var assert = __webpack_require__(381) +var der = __webpack_require__(382) +var messages = __webpack_require__(169) function initCompressedValue (value, defaultValue) { if (value === undefined) return defaultValue @@ -66964,7 +56299,7 @@ module.exports = function (secp256k1) { /***/ }), -/* 441 */ +/* 381 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -67013,16 +56348,16 @@ exports.isNumberInInterval = function (number, x, y, message) { if (number <= x || number >= y) throw RangeError(message) } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 442 */ +/* 382 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var Buffer = __webpack_require__(18).Buffer -var bip66 = __webpack_require__(266) +var Buffer = __webpack_require__(7).Buffer +var bip66 = __webpack_require__(104) var EC_PRIVKEY_EXPORT_DER_COMPRESSED = Buffer.from([ // begin @@ -67221,17 +56556,17 @@ exports.signatureImportLax = function (sig) { /***/ }), -/* 443 */ +/* 383 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var Buffer = __webpack_require__(18).Buffer -var createHash = __webpack_require__(71) -var BN = __webpack_require__(23) -var EC = __webpack_require__(36).ec +var Buffer = __webpack_require__(7).Buffer +var createHash = __webpack_require__(27) +var BN = __webpack_require__(11) +var EC = __webpack_require__(15).ec -var messages = __webpack_require__(315) +var messages = __webpack_require__(169) var ec = new EC('secp256k1') var ecparams = ec.curve @@ -67476,7 +56811,7 @@ exports.ecdhUnsafe = function (publicKey, privateKey, compressed) { /***/ }), -/* 444 */ +/* 384 */ /***/ (function(module, exports) { module.exports = function(module) { @@ -67504,7 +56839,7 @@ module.exports = function(module) { /***/ }), -/* 445 */ +/* 385 */ /***/ (function(module, exports) { module.exports = { @@ -67567,16 +56902,16 @@ module.exports = { }; /***/ }), -/* 446 */ +/* 386 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; var utils = exports; -var BN = __webpack_require__(23); -var minAssert = __webpack_require__(47); -var minUtils = __webpack_require__(316); +var BN = __webpack_require__(11); +var minAssert = __webpack_require__(21); +var minUtils = __webpack_require__(170); utils.assert = minAssert; utils.toArray = minUtils.toArray; @@ -67694,20 +57029,20 @@ utils.intFromLE = intFromLE; /***/ }), -/* 447 */ +/* 387 */ /***/ (function(module, exports) { /* (ignored) */ /***/ }), -/* 448 */ +/* 388 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var BN = __webpack_require__(23); -var elliptic = __webpack_require__(36); +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); var utils = elliptic.utils; var getNAF = utils.getNAF; var getJSF = utils.getJSF; @@ -68082,16 +57417,16 @@ BasePoint.prototype.dblp = function dblp(k) { /***/ }), -/* 449 */ +/* 389 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var curve = __webpack_require__(247); -var elliptic = __webpack_require__(36); -var BN = __webpack_require__(23); -var inherits = __webpack_require__(11); +var curve = __webpack_require__(65); +var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); var Base = curve.base; var assert = elliptic.utils.assert; @@ -69027,18 +58362,18 @@ JPoint.prototype.isInfinity = function isInfinity() { /***/ }), -/* 450 */ +/* 390 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var curve = __webpack_require__(247); -var BN = __webpack_require__(23); -var inherits = __webpack_require__(11); +var curve = __webpack_require__(65); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); var Base = curve.base; -var elliptic = __webpack_require__(36); +var elliptic = __webpack_require__(15); var utils = elliptic.utils; function MontCurve(conf) { @@ -69214,16 +58549,16 @@ Point.prototype.getX = function getX() { /***/ }), -/* 451 */ +/* 391 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var curve = __webpack_require__(247); -var elliptic = __webpack_require__(36); -var BN = __webpack_require__(23); -var inherits = __webpack_require__(11); +var curve = __webpack_require__(65); +var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); +var inherits = __webpack_require__(4); var Base = curve.base; var assert = elliptic.utils.assert; @@ -69654,7 +58989,7 @@ Point.prototype.mixedAdd = Point.prototype.add; /***/ }), -/* 452 */ +/* 392 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -69662,8 +58997,8 @@ Point.prototype.mixedAdd = Point.prototype.add; var curves = exports; -var hash = __webpack_require__(267); -var elliptic = __webpack_require__(36); +var hash = __webpack_require__(105); +var elliptic = __webpack_require__(15); var assert = elliptic.utils.assert; @@ -69827,7 +59162,7 @@ defineCurve('ed25519', { var pre; try { - pre = __webpack_require__(459); + pre = __webpack_require__(399); } catch (e) { pre = undefined; } @@ -69866,29 +59201,29 @@ defineCurve('secp256k1', { /***/ }), -/* 453 */ +/* 393 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -exports.sha1 = __webpack_require__(454); -exports.sha224 = __webpack_require__(455); -exports.sha256 = __webpack_require__(319); -exports.sha384 = __webpack_require__(456); -exports.sha512 = __webpack_require__(320); +exports.sha1 = __webpack_require__(394); +exports.sha224 = __webpack_require__(395); +exports.sha256 = __webpack_require__(173); +exports.sha384 = __webpack_require__(396); +exports.sha512 = __webpack_require__(174); /***/ }), -/* 454 */ +/* 394 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var utils = __webpack_require__(69); -var common = __webpack_require__(238); -var shaCommon = __webpack_require__(318); +var utils = __webpack_require__(25); +var common = __webpack_require__(50); +var shaCommon = __webpack_require__(172); var rotl32 = utils.rotl32; var sum32 = utils.sum32; @@ -69961,14 +59296,14 @@ SHA1.prototype._digest = function digest(enc) { /***/ }), -/* 455 */ +/* 395 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var utils = __webpack_require__(69); -var SHA256 = __webpack_require__(319); +var utils = __webpack_require__(25); +var SHA256 = __webpack_require__(173); function SHA224() { if (!(this instanceof SHA224)) @@ -69998,15 +59333,15 @@ SHA224.prototype._digest = function digest(enc) { /***/ }), -/* 456 */ +/* 396 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var utils = __webpack_require__(69); +var utils = __webpack_require__(25); -var SHA512 = __webpack_require__(320); +var SHA512 = __webpack_require__(174); function SHA384() { if (!(this instanceof SHA384)) @@ -70040,14 +59375,14 @@ SHA384.prototype._digest = function digest(enc) { /***/ }), -/* 457 */ +/* 397 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var utils = __webpack_require__(69); -var common = __webpack_require__(238); +var utils = __webpack_require__(25); +var common = __webpack_require__(50); var rotl32 = utils.rotl32; var sum32 = utils.sum32; @@ -70193,14 +59528,14 @@ var sh = [ /***/ }), -/* 458 */ +/* 398 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var utils = __webpack_require__(69); -var assert = __webpack_require__(47); +var utils = __webpack_require__(25); +var assert = __webpack_require__(21); function Hmac(hash, key, enc) { if (!(this instanceof Hmac)) @@ -70247,7 +59582,7 @@ Hmac.prototype.digest = function digest(enc) { /***/ }), -/* 459 */ +/* 399 */ /***/ (function(module, exports) { module.exports = { @@ -71033,20 +60368,20 @@ module.exports = { /***/ }), -/* 460 */ +/* 400 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var BN = __webpack_require__(23); -var HmacDRBG = __webpack_require__(461); -var elliptic = __webpack_require__(36); +var BN = __webpack_require__(11); +var HmacDRBG = __webpack_require__(401); +var elliptic = __webpack_require__(15); var utils = elliptic.utils; var assert = utils.assert; -var KeyPair = __webpack_require__(462); -var Signature = __webpack_require__(463); +var KeyPair = __webpack_require__(402); +var Signature = __webpack_require__(403); function EC(options) { if (!(this instanceof EC)) @@ -71280,15 +60615,15 @@ EC.prototype.getKeyRecoveryParam = function(e, signature, Q, enc) { /***/ }), -/* 461 */ +/* 401 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var hash = __webpack_require__(267); -var utils = __webpack_require__(316); -var assert = __webpack_require__(47); +var hash = __webpack_require__(105); +var utils = __webpack_require__(170); +var assert = __webpack_require__(21); function HmacDRBG(options) { if (!(this instanceof HmacDRBG)) @@ -71400,14 +60735,14 @@ HmacDRBG.prototype.generate = function generate(len, enc, add, addEnc) { /***/ }), -/* 462 */ +/* 402 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var BN = __webpack_require__(23); -var elliptic = __webpack_require__(36); +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); var utils = elliptic.utils; var assert = utils.assert; @@ -71526,15 +60861,15 @@ KeyPair.prototype.inspect = function inspect() { /***/ }), -/* 463 */ +/* 403 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var BN = __webpack_require__(23); +var BN = __webpack_require__(11); -var elliptic = __webpack_require__(36); +var elliptic = __webpack_require__(15); var utils = elliptic.utils; var assert = utils.assert; @@ -71668,19 +61003,19 @@ Signature.prototype.toDER = function toDER(enc) { /***/ }), -/* 464 */ +/* 404 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var hash = __webpack_require__(267); -var elliptic = __webpack_require__(36); +var hash = __webpack_require__(105); +var elliptic = __webpack_require__(15); var utils = elliptic.utils; var assert = utils.assert; var parseBytes = utils.parseBytes; -var KeyPair = __webpack_require__(465); -var Signature = __webpack_require__(466); +var KeyPair = __webpack_require__(405); +var Signature = __webpack_require__(406); function EDDSA(curve) { assert(curve === 'ed25519', 'only tested with ed25519 so far'); @@ -71793,13 +61128,13 @@ EDDSA.prototype.isPoint = function isPoint(val) { /***/ }), -/* 465 */ +/* 405 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var elliptic = __webpack_require__(36); +var elliptic = __webpack_require__(15); var utils = elliptic.utils; var assert = utils.assert; var parseBytes = utils.parseBytes; @@ -71896,14 +61231,14 @@ module.exports = KeyPair; /***/ }), -/* 466 */ +/* 406 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var BN = __webpack_require__(23); -var elliptic = __webpack_require__(36); +var BN = __webpack_require__(11); +var elliptic = __webpack_require__(15); var utils = elliptic.utils; var assert = utils.assert; var cachedProperty = utils.cachedProperty; @@ -71969,7 +61304,7 @@ module.exports = Signature; /***/ }), -/* 467 */ +/* 407 */ /***/ (function(module, exports) { module.exports = { @@ -72029,12 +61364,12 @@ module.exports = { }; /***/ }), -/* 468 */ +/* 408 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {// FIXME: Kind of a weird way to throw exceptions, consider removing -var assert = __webpack_require__(268) -var BigInteger = __webpack_require__(321) +var assert = __webpack_require__(106) +var BigInteger = __webpack_require__(175) /** * Turns a byte array into a big integer. @@ -72124,10 +61459,10 @@ BigInteger.prototype.toHex = function(size) { return this.toBuffer(size).toString('hex') } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 469 */ +/* 409 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(global, process) {// Copyright Joyent, Inc. and other Node contributors. @@ -72655,7 +61990,7 @@ function isPrimitive(arg) { } exports.isPrimitive = isPrimitive; -exports.isBuffer = __webpack_require__(470); +exports.isBuffer = __webpack_require__(410); function objectToString(o) { return Object.prototype.toString.call(o); @@ -72699,7 +62034,7 @@ exports.log = function() { * prototype. * @param {function} superCtor Constructor function to inherit prototype from. */ -exports.inherits = __webpack_require__(471); +exports.inherits = __webpack_require__(411); exports._extend = function(origin, add) { // Don't do anything if add isn't an object @@ -72717,10 +62052,10 @@ function hasOwnProperty(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(67), __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) /***/ }), -/* 470 */ +/* 410 */ /***/ (function(module, exports) { module.exports = function isBuffer(arg) { @@ -72731,7 +62066,7 @@ module.exports = function isBuffer(arg) { } /***/ }), -/* 471 */ +/* 411 */ /***/ (function(module, exports) { if (typeof Object.create === 'function') { @@ -72760,14 +62095,14 @@ if (typeof Object.create === 'function') { /***/ }), -/* 472 */ +/* 412 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var prf = __webpack_require__(473); -var address = __webpack_require__(259); -var bs58check = __webpack_require__(111); -var sodium = __webpack_require__(475); -var zconfig = __webpack_require__(248); +/* WEBPACK VAR INJECTION */(function(Buffer) {var prf = __webpack_require__(413); +var address = __webpack_require__(96); +var bs58check = __webpack_require__(33); +var sodium = __webpack_require__(415); +var zconfig = __webpack_require__(66); /* * Creates a Z secret key (a_sk) @@ -72840,13 +62175,13 @@ module.exports = { zSecretKeyToSpendingKey: zSecretKeyToSpendingKey, mkZAddress: mkZAddress }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 473 */ +/* 413 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var SHA256Compress = __webpack_require__(474); +/* WEBPACK VAR INJECTION */(function(Buffer) {var SHA256Compress = __webpack_require__(414); function prf(a, b, c, d, x, y) { @@ -72906,10 +62241,10 @@ module.exports = { PRF_pk: prfPk, PRF_rho: prfRho }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 474 */ +/* 414 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {/** @@ -73023,10 +62358,10 @@ Sha256Compress.prototype.hash = function () { }; module.exports = Sha256Compress; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 475 */ +/* 415 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(process) {var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (root, factory) { @@ -73034,7 +62369,7 @@ module.exports = Sha256Compress; process.stderr = process.stdout = { write: function() { } }; } if (true) { - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports, __webpack_require__(476)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), + !(__WEBPACK_AMD_DEFINE_ARRAY__ = [exports, __webpack_require__(416)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); @@ -77591,7 +66926,7 @@ module.exports = Sha256Compress; /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 476 */ +/* 416 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(process) {var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (root, factory) { @@ -77608,7 +66943,7 @@ module.exports = Sha256Compress; } })(this, (function (exports) { var Module = exports; -var Module;if(!Module)Module=(typeof Module!=="undefined"?Module:null)||{};var moduleOverrides={};for(var key in Module){if(Module.hasOwnProperty(key)){moduleOverrides[key]=Module[key]}}var ENVIRONMENT_IS_WEB=false;var ENVIRONMENT_IS_WORKER=false;var ENVIRONMENT_IS_NODE=false;var ENVIRONMENT_IS_SHELL=false;if(Module["ENVIRONMENT"]){if(Module["ENVIRONMENT"]==="WEB"){ENVIRONMENT_IS_WEB=true}else if(Module["ENVIRONMENT"]==="WORKER"){ENVIRONMENT_IS_WORKER=true}else if(Module["ENVIRONMENT"]==="NODE"){ENVIRONMENT_IS_NODE=true}else if(Module["ENVIRONMENT"]==="SHELL"){ENVIRONMENT_IS_SHELL=true}else{throw new Error("The provided Module['ENVIRONMENT'] value is not valid. It must be one of: WEB|WORKER|NODE|SHELL.")}}else{ENVIRONMENT_IS_WEB=typeof window==="object";ENVIRONMENT_IS_WORKER=typeof importScripts==="function";ENVIRONMENT_IS_NODE=typeof process==="object"&&"function"==="function"&&!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_WORKER;ENVIRONMENT_IS_SHELL=!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_NODE&&!ENVIRONMENT_IS_WORKER}if(ENVIRONMENT_IS_NODE){if(!Module["print"])Module["print"]=console.log;if(!Module["printErr"])Module["printErr"]=console.warn;var nodeFS;var nodePath;Module["read"]=function shell_read(filename,binary){if(!nodeFS)nodeFS=__webpack_require__(477);if(!nodePath)nodePath=__webpack_require__(478);filename=nodePath["normalize"](filename);var ret=nodeFS["readFileSync"](filename);return binary?ret:ret.toString()};Module["readBinary"]=function readBinary(filename){var ret=Module["read"](filename,true);if(!ret.buffer){ret=new Uint8Array(ret)}assert(ret.buffer);return ret};Module["load"]=function load(f){globalEval(read(f))};if(!Module["thisProgram"]){if(process["argv"].length>1){Module["thisProgram"]=process["argv"][1].replace(/\\/g,"/")}else{Module["thisProgram"]="unknown-program"}}Module["arguments"]=process["argv"].slice(2);if(true){module["exports"]=Module}process["on"]("uncaughtException",(function(ex){if(!(ex instanceof ExitStatus)){throw ex}}));Module["inspect"]=(function(){return"[Emscripten Module object]"})}else if(ENVIRONMENT_IS_SHELL){if(!Module["print"])Module["print"]=print;if(typeof printErr!="undefined")Module["printErr"]=printErr;if(typeof read!="undefined"){Module["read"]=read}else{Module["read"]=function shell_read(){throw"no read() available"}}Module["readBinary"]=function readBinary(f){if(typeof readbuffer==="function"){return new Uint8Array(readbuffer(f))}var data=read(f,"binary");assert(typeof data==="object");return data};if(typeof scriptArgs!="undefined"){Module["arguments"]=scriptArgs}else if(typeof arguments!="undefined"){Module["arguments"]=arguments}if(typeof quit==="function"){Module["quit"]=(function(status,toThrow){quit(status)})}}else if(ENVIRONMENT_IS_WEB||ENVIRONMENT_IS_WORKER){Module["read"]=function shell_read(url){var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.send(null);return xhr.responseText};if(ENVIRONMENT_IS_WORKER){Module["readBinary"]=function readBinary(url){var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.responseType="arraybuffer";xhr.send(null);return xhr.response}}Module["readAsync"]=function readAsync(url,onload,onerror){var xhr=new XMLHttpRequest;xhr.open("GET",url,true);xhr.responseType="arraybuffer";xhr.onload=function xhr_onload(){if(xhr.status==200||xhr.status==0&&xhr.response){onload(xhr.response)}else{onerror()}};xhr.onerror=onerror;xhr.send(null)};if(typeof arguments!="undefined"){Module["arguments"]=arguments}if(typeof console!=="undefined"){if(!Module["print"])Module["print"]=function shell_print(x){console.log(x)};if(!Module["printErr"])Module["printErr"]=function shell_printErr(x){console.warn(x)}}else{var TRY_USE_DUMP=false;if(!Module["print"])Module["print"]=TRY_USE_DUMP&&typeof dump!=="undefined"?(function(x){dump(x)}):(function(x){})}if(ENVIRONMENT_IS_WORKER){Module["load"]=importScripts}if(typeof Module["setWindowTitle"]==="undefined"){Module["setWindowTitle"]=(function(title){document.title=title})}}else{throw"Unknown runtime environment. Where are we?"}function globalEval(x){abort("NO_DYNAMIC_EXECUTION=1 was set, cannot eval")}if(!Module["load"]&&Module["read"]){Module["load"]=function load(f){globalEval(Module["read"](f))}}if(!Module["print"]){Module["print"]=(function(){})}if(!Module["printErr"]){Module["printErr"]=Module["print"]}if(!Module["arguments"]){Module["arguments"]=[]}if(!Module["thisProgram"]){Module["thisProgram"]="./this.program"}if(!Module["quit"]){Module["quit"]=(function(status,toThrow){throw toThrow})}Module.print=Module["print"];Module.printErr=Module["printErr"];Module["preRun"]=[];Module["postRun"]=[];for(var key in moduleOverrides){if(moduleOverrides.hasOwnProperty(key)){Module[key]=moduleOverrides[key]}}moduleOverrides=undefined;var Runtime={setTempRet0:(function(value){tempRet0=value;return value}),getTempRet0:(function(){return tempRet0}),stackSave:(function(){return STACKTOP}),stackRestore:(function(stackTop){STACKTOP=stackTop}),getNativeTypeSize:(function(type){switch(type){case"i1":case"i8":return 1;case"i16":return 2;case"i32":return 4;case"i64":return 8;case"float":return 4;case"double":return 8;default:{if(type[type.length-1]==="*"){return Runtime.QUANTUM_SIZE}else if(type[0]==="i"){var bits=parseInt(type.substr(1));assert(bits%8===0);return bits/8}else{return 0}}}}),getNativeFieldSize:(function(type){return Math.max(Runtime.getNativeTypeSize(type),Runtime.QUANTUM_SIZE)}),STACK_ALIGN:16,prepVararg:(function(ptr,type){if(type==="double"||type==="i64"){if(ptr&7){assert((ptr&7)===4);ptr+=4}}else{assert((ptr&3)===0)}return ptr}),getAlignSize:(function(type,size,vararg){if(!vararg&&(type=="i64"||type=="double"))return 8;if(!type)return Math.min(size,8);return Math.min(size||(type?Runtime.getNativeFieldSize(type):0),Runtime.QUANTUM_SIZE)}),dynCall:(function(sig,ptr,args){if(args&&args.length){return Module["dynCall_"+sig].apply(null,[ptr].concat(args))}else{return Module["dynCall_"+sig].call(null,ptr)}}),functionPointers:[null,null,null,null,null,null,null,null],addFunction:(function(func){for(var i=0;i<Runtime.functionPointers.length;i++){if(!Runtime.functionPointers[i]){Runtime.functionPointers[i]=func;return 1*(1+i)}}throw"Finished up all reserved function pointers. Use a higher value for RESERVED_FUNCTION_POINTERS."}),removeFunction:(function(index){Runtime.functionPointers[(index-1)/1]=null}),warnOnce:(function(text){if(!Runtime.warnOnce.shown)Runtime.warnOnce.shown={};if(!Runtime.warnOnce.shown[text]){Runtime.warnOnce.shown[text]=1;Module.printErr(text)}}),funcWrappers:{},getFuncWrapper:(function(func,sig){assert(sig);if(!Runtime.funcWrappers[sig]){Runtime.funcWrappers[sig]={}}var sigCache=Runtime.funcWrappers[sig];if(!sigCache[func]){if(sig.length===1){sigCache[func]=function dynCall_wrapper(){return Runtime.dynCall(sig,func)}}else if(sig.length===2){sigCache[func]=function dynCall_wrapper(arg){return Runtime.dynCall(sig,func,[arg])}}else{sigCache[func]=function dynCall_wrapper(){return Runtime.dynCall(sig,func,Array.prototype.slice.call(arguments))}}}return sigCache[func]}),getCompilerSetting:(function(name){throw"You must build with -s RETAIN_COMPILER_SETTINGS=1 for Runtime.getCompilerSetting or emscripten_get_compiler_setting to work"}),stackAlloc:(function(size){var ret=STACKTOP;STACKTOP=STACKTOP+size|0;STACKTOP=STACKTOP+15&-16;return ret}),staticAlloc:(function(size){var ret=STATICTOP;STATICTOP=STATICTOP+size|0;STATICTOP=STATICTOP+15&-16;return ret}),dynamicAlloc:(function(size){var ret=HEAP32[DYNAMICTOP_PTR>>2];var end=(ret+size+15|0)&-16;HEAP32[DYNAMICTOP_PTR>>2]=end;if(end>=TOTAL_MEMORY){var success=enlargeMemory();if(!success){HEAP32[DYNAMICTOP_PTR>>2]=ret;return 0}}return ret}),alignMemory:(function(size,quantum){var ret=size=Math.ceil(size/(quantum?quantum:16))*(quantum?quantum:16);return ret}),makeBigInt:(function(low,high,unsigned){var ret=unsigned?+(low>>>0)+ +(high>>>0)*+4294967296:+(low>>>0)+ +(high|0)*+4294967296;return ret}),GLOBAL_BASE:8,QUANTUM_SIZE:4,__dummy__:0};Module["Runtime"]=Runtime;var ABORT=0;var EXITSTATUS=0;function assert(condition,text){if(!condition){abort("Assertion failed: "+text)}}function getCFunc(ident){var func=Module["_"+ident];if(!func){abort("NO_DYNAMIC_EXECUTION=1 was set, cannot eval")}assert(func,"Cannot call unknown function "+ident+" (perhaps LLVM optimizations or closure removed it?)");return func}var cwrap,ccall;((function(){var JSfuncs={"stackSave":(function(){Runtime.stackSave()}),"stackRestore":(function(){Runtime.stackRestore()}),"arrayToC":(function(arr){var ret=Runtime.stackAlloc(arr.length);writeArrayToMemory(arr,ret);return ret}),"stringToC":(function(str){var ret=0;if(str!==null&&str!==undefined&&str!==0){var len=(str.length<<2)+1;ret=Runtime.stackAlloc(len);stringToUTF8(str,ret,len)}return ret})};var toC={"string":JSfuncs["stringToC"],"array":JSfuncs["arrayToC"]};ccall=function ccallFunc(ident,returnType,argTypes,args,opts){var func=getCFunc(ident);var cArgs=[];var stack=0;if(args){for(var i=0;i<args.length;i++){var converter=toC[argTypes[i]];if(converter){if(stack===0)stack=Runtime.stackSave();cArgs[i]=converter(args[i])}else{cArgs[i]=args[i]}}}var ret=func.apply(null,cArgs);if(returnType==="string")ret=Pointer_stringify(ret);if(stack!==0){if(opts&&opts.async){EmterpreterAsync.asyncFinalizers.push((function(){Runtime.stackRestore(stack)}));return}Runtime.stackRestore(stack)}return ret};cwrap=function cwrap(ident,returnType,argTypes){return(function(){return ccall(ident,returnType,argTypes,arguments)})}}))();Module["ccall"]=ccall;Module["cwrap"]=cwrap;function setValue(ptr,value,type,noSafe){type=type||"i8";if(type.charAt(type.length-1)==="*")type="i32";switch(type){case"i1":HEAP8[ptr>>0]=value;break;case"i8":HEAP8[ptr>>0]=value;break;case"i16":HEAP16[ptr>>1]=value;break;case"i32":HEAP32[ptr>>2]=value;break;case"i64":tempI64=[value>>>0,(tempDouble=value,+Math_abs(tempDouble)>=+1?tempDouble>+0?(Math_min(+Math_floor(tempDouble/+4294967296),+4294967295)|0)>>>0:~~+Math_ceil((tempDouble- +(~~tempDouble>>>0))/+4294967296)>>>0:0)],HEAP32[ptr>>2]=tempI64[0],HEAP32[ptr+4>>2]=tempI64[1];break;case"float":HEAPF32[ptr>>2]=value;break;case"double":HEAPF64[ptr>>3]=value;break;default:abort("invalid type for setValue: "+type)}}Module["setValue"]=setValue;function getValue(ptr,type,noSafe){type=type||"i8";if(type.charAt(type.length-1)==="*")type="i32";switch(type){case"i1":return HEAP8[ptr>>0];case"i8":return HEAP8[ptr>>0];case"i16":return HEAP16[ptr>>1];case"i32":return HEAP32[ptr>>2];case"i64":return HEAP32[ptr>>2];case"float":return HEAPF32[ptr>>2];case"double":return HEAPF64[ptr>>3];default:abort("invalid type for setValue: "+type)}return null}Module["getValue"]=getValue;var ALLOC_NORMAL=0;var ALLOC_STACK=1;var ALLOC_STATIC=2;var ALLOC_DYNAMIC=3;var ALLOC_NONE=4;Module["ALLOC_NORMAL"]=ALLOC_NORMAL;Module["ALLOC_STACK"]=ALLOC_STACK;Module["ALLOC_STATIC"]=ALLOC_STATIC;Module["ALLOC_DYNAMIC"]=ALLOC_DYNAMIC;Module["ALLOC_NONE"]=ALLOC_NONE;function allocate(slab,types,allocator,ptr){var zeroinit,size;if(typeof slab==="number"){zeroinit=true;size=slab}else{zeroinit=false;size=slab.length}var singleType=typeof types==="string"?types:null;var ret;if(allocator==ALLOC_NONE){ret=ptr}else{ret=[typeof _malloc==="function"?_malloc:Runtime.staticAlloc,Runtime.stackAlloc,Runtime.staticAlloc,Runtime.dynamicAlloc][allocator===undefined?ALLOC_STATIC:allocator](Math.max(size,singleType?1:types.length))}if(zeroinit){var ptr=ret,stop;assert((ret&3)==0);stop=ret+(size&~3);for(;ptr<stop;ptr+=4){HEAP32[ptr>>2]=0}stop=ret+size;while(ptr<stop){HEAP8[ptr++>>0]=0}return ret}if(singleType==="i8"){if(slab.subarray||slab.slice){HEAPU8.set(slab,ret)}else{HEAPU8.set(new Uint8Array(slab),ret)}return ret}var i=0,type,typeSize,previousType;while(i<size){var curr=slab[i];if(typeof curr==="function"){curr=Runtime.getFunctionIndex(curr)}type=singleType||types[i];if(type===0){i++;continue}if(type=="i64")type="i32";setValue(ret+i,curr,type);if(previousType!==type){typeSize=Runtime.getNativeTypeSize(type);previousType=type}i+=typeSize}return ret}Module["allocate"]=allocate;function getMemory(size){if(!staticSealed)return Runtime.staticAlloc(size);if(!runtimeInitialized)return Runtime.dynamicAlloc(size);return _malloc(size)}Module["getMemory"]=getMemory;function Pointer_stringify(ptr,length){if(length===0||!ptr)return"";var hasUtf=0;var t;var i=0;while(1){t=HEAPU8[ptr+i>>0];hasUtf|=t;if(t==0&&!length)break;i++;if(length&&i==length)break}if(!length)length=i;var ret="";if(hasUtf<128){var MAX_CHUNK=1024;var curr;while(length>0){curr=String.fromCharCode.apply(String,HEAPU8.subarray(ptr,ptr+Math.min(length,MAX_CHUNK)));ret=ret?ret+curr:curr;ptr+=MAX_CHUNK;length-=MAX_CHUNK}return ret}return Module["UTF8ToString"](ptr)}Module["Pointer_stringify"]=Pointer_stringify;function AsciiToString(ptr){var str="";while(1){var ch=HEAP8[ptr++>>0];if(!ch)return str;str+=String.fromCharCode(ch)}}Module["AsciiToString"]=AsciiToString;function stringToAscii(str,outPtr){return writeAsciiToMemory(str,outPtr,false)}Module["stringToAscii"]=stringToAscii;var UTF8Decoder=typeof TextDecoder!=="undefined"?new TextDecoder("utf8"):undefined;function UTF8ArrayToString(u8Array,idx){var endPtr=idx;while(u8Array[endPtr])++endPtr;if(endPtr-idx>16&&u8Array.subarray&&UTF8Decoder){return UTF8Decoder.decode(u8Array.subarray(idx,endPtr))}else{var u0,u1,u2,u3,u4,u5;var str="";while(1){u0=u8Array[idx++];if(!u0)return str;if(!(u0&128)){str+=String.fromCharCode(u0);continue}u1=u8Array[idx++]&63;if((u0&224)==192){str+=String.fromCharCode((u0&31)<<6|u1);continue}u2=u8Array[idx++]&63;if((u0&240)==224){u0=(u0&15)<<12|u1<<6|u2}else{u3=u8Array[idx++]&63;if((u0&248)==240){u0=(u0&7)<<18|u1<<12|u2<<6|u3}else{u4=u8Array[idx++]&63;if((u0&252)==248){u0=(u0&3)<<24|u1<<18|u2<<12|u3<<6|u4}else{u5=u8Array[idx++]&63;u0=(u0&1)<<30|u1<<24|u2<<18|u3<<12|u4<<6|u5}}}if(u0<65536){str+=String.fromCharCode(u0)}else{var ch=u0-65536;str+=String.fromCharCode(55296|ch>>10,56320|ch&1023)}}}}Module["UTF8ArrayToString"]=UTF8ArrayToString;function UTF8ToString(ptr){return UTF8ArrayToString(HEAPU8,ptr)}Module["UTF8ToString"]=UTF8ToString;function stringToUTF8Array(str,outU8Array,outIdx,maxBytesToWrite){if(!(maxBytesToWrite>0))return 0;var startIdx=outIdx;var endIdx=outIdx+maxBytesToWrite-1;for(var i=0;i<str.length;++i){var u=str.charCodeAt(i);if(u>=55296&&u<=57343)u=65536+((u&1023)<<10)|str.charCodeAt(++i)&1023;if(u<=127){if(outIdx>=endIdx)break;outU8Array[outIdx++]=u}else if(u<=2047){if(outIdx+1>=endIdx)break;outU8Array[outIdx++]=192|u>>6;outU8Array[outIdx++]=128|u&63}else if(u<=65535){if(outIdx+2>=endIdx)break;outU8Array[outIdx++]=224|u>>12;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else if(u<=2097151){if(outIdx+3>=endIdx)break;outU8Array[outIdx++]=240|u>>18;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else if(u<=67108863){if(outIdx+4>=endIdx)break;outU8Array[outIdx++]=248|u>>24;outU8Array[outIdx++]=128|u>>18&63;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else{if(outIdx+5>=endIdx)break;outU8Array[outIdx++]=252|u>>30;outU8Array[outIdx++]=128|u>>24&63;outU8Array[outIdx++]=128|u>>18&63;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}}outU8Array[outIdx]=0;return outIdx-startIdx}Module["stringToUTF8Array"]=stringToUTF8Array;function stringToUTF8(str,outPtr,maxBytesToWrite){return stringToUTF8Array(str,HEAPU8,outPtr,maxBytesToWrite)}Module["stringToUTF8"]=stringToUTF8;function lengthBytesUTF8(str){var len=0;for(var i=0;i<str.length;++i){var u=str.charCodeAt(i);if(u>=55296&&u<=57343)u=65536+((u&1023)<<10)|str.charCodeAt(++i)&1023;if(u<=127){++len}else if(u<=2047){len+=2}else if(u<=65535){len+=3}else if(u<=2097151){len+=4}else if(u<=67108863){len+=5}else{len+=6}}return len}Module["lengthBytesUTF8"]=lengthBytesUTF8;var UTF16Decoder=typeof TextDecoder!=="undefined"?new TextDecoder("utf-16le"):undefined;function demangle(func){var __cxa_demangle_func=Module["___cxa_demangle"]||Module["__cxa_demangle"];if(__cxa_demangle_func){try{var s=func.substr(1);var len=lengthBytesUTF8(s)+1;var buf=_malloc(len);stringToUTF8(s,buf,len);var status=_malloc(4);var ret=__cxa_demangle_func(buf,0,0,status);if(getValue(status,"i32")===0&&ret){return Pointer_stringify(ret)}}catch(e){}finally{if(buf)_free(buf);if(status)_free(status);if(ret)_free(ret)}return func}Runtime.warnOnce("warning: build with -s DEMANGLE_SUPPORT=1 to link in libcxxabi demangling");return func}function demangleAll(text){var regex=/__Z[\w\d_]+/g;return text.replace(regex,(function(x){var y=demangle(x);return x===y?x:x+" ["+y+"]"}))}function jsStackTrace(){var err=new Error;if(!err.stack){try{throw new Error(0)}catch(e){err=e}if(!err.stack){return"(no stack trace available)"}}return err.stack.toString()}function stackTrace(){var js=jsStackTrace();if(Module["extraStackTrace"])js+="\n"+Module["extraStackTrace"]();return demangleAll(js)}Module["stackTrace"]=stackTrace;var PAGE_SIZE=16384;var HEAP,buffer,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64;function updateGlobalBufferViews(){Module["HEAP8"]=HEAP8=new Int8Array(buffer);Module["HEAP16"]=HEAP16=new Int16Array(buffer);Module["HEAP32"]=HEAP32=new Int32Array(buffer);Module["HEAPU8"]=HEAPU8=new Uint8Array(buffer);Module["HEAPU16"]=HEAPU16=new Uint16Array(buffer);Module["HEAPU32"]=HEAPU32=new Uint32Array(buffer);Module["HEAPF32"]=HEAPF32=new Float32Array(buffer);Module["HEAPF64"]=HEAPF64=new Float64Array(buffer)}var STATIC_BASE,STATICTOP,staticSealed;var STACK_BASE,STACKTOP,STACK_MAX;var DYNAMIC_BASE,DYNAMICTOP_PTR;STATIC_BASE=STATICTOP=STACK_BASE=STACKTOP=STACK_MAX=DYNAMIC_BASE=DYNAMICTOP_PTR=0;staticSealed=false;function abortOnCannotGrowMemory(){abort("Cannot enlarge memory arrays. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value "+TOTAL_MEMORY+", (2) compile with -s ALLOW_MEMORY_GROWTH=1 which allows increasing the size at runtime but prevents some optimizations, (3) set Module.TOTAL_MEMORY to a higher value before the program runs, or (4) if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 ")}function enlargeMemory(){abortOnCannotGrowMemory()}var TOTAL_STACK=Module["TOTAL_STACK"]||5242880;var TOTAL_MEMORY=Module["TOTAL_MEMORY"]||67108864;if(TOTAL_MEMORY<TOTAL_STACK)Module.printErr("TOTAL_MEMORY should be larger than TOTAL_STACK, was "+TOTAL_MEMORY+"! (TOTAL_STACK="+TOTAL_STACK+")");if(Module["buffer"]){buffer=Module["buffer"]}else{{buffer=new ArrayBuffer(TOTAL_MEMORY)}}updateGlobalBufferViews();function getTotalMemory(){return TOTAL_MEMORY}HEAP32[0]=1668509029;HEAP16[1]=25459;if(HEAPU8[2]!==115||HEAPU8[3]!==99)throw"Runtime error: expected the system to be little-endian!";Module["HEAP"]=HEAP;Module["buffer"]=buffer;Module["HEAP8"]=HEAP8;Module["HEAP16"]=HEAP16;Module["HEAP32"]=HEAP32;Module["HEAPU8"]=HEAPU8;Module["HEAPU16"]=HEAPU16;Module["HEAPU32"]=HEAPU32;Module["HEAPF32"]=HEAPF32;Module["HEAPF64"]=HEAPF64;function callRuntimeCallbacks(callbacks){while(callbacks.length>0){var callback=callbacks.shift();if(typeof callback=="function"){callback();continue}var func=callback.func;if(typeof func==="number"){if(callback.arg===undefined){Module["dynCall_v"](func)}else{Module["dynCall_vi"](func,callback.arg)}}else{func(callback.arg===undefined?null:callback.arg)}}}var __ATPRERUN__=[];var __ATINIT__=[];var __ATMAIN__=[];var __ATEXIT__=[];var __ATPOSTRUN__=[];var runtimeInitialized=false;var runtimeExited=false;function preRun(){if(Module["preRun"]){if(typeof Module["preRun"]=="function")Module["preRun"]=[Module["preRun"]];while(Module["preRun"].length){addOnPreRun(Module["preRun"].shift())}}callRuntimeCallbacks(__ATPRERUN__)}function ensureInitRuntime(){if(runtimeInitialized)return;runtimeInitialized=true;callRuntimeCallbacks(__ATINIT__)}function preMain(){callRuntimeCallbacks(__ATMAIN__)}function exitRuntime(){callRuntimeCallbacks(__ATEXIT__);runtimeExited=true}function postRun(){if(Module["postRun"]){if(typeof Module["postRun"]=="function")Module["postRun"]=[Module["postRun"]];while(Module["postRun"].length){addOnPostRun(Module["postRun"].shift())}}callRuntimeCallbacks(__ATPOSTRUN__)}function addOnPreRun(cb){__ATPRERUN__.unshift(cb)}Module["addOnPreRun"]=addOnPreRun;function addOnInit(cb){__ATINIT__.unshift(cb)}Module["addOnInit"]=addOnInit;function addOnPreMain(cb){__ATMAIN__.unshift(cb)}Module["addOnPreMain"]=addOnPreMain;function addOnExit(cb){__ATEXIT__.unshift(cb)}Module["addOnExit"]=addOnExit;function addOnPostRun(cb){__ATPOSTRUN__.unshift(cb)}Module["addOnPostRun"]=addOnPostRun;function intArrayFromString(stringy,dontAddNull,length){var len=length>0?length:lengthBytesUTF8(stringy)+1;var u8array=new Array(len);var numBytesWritten=stringToUTF8Array(stringy,u8array,0,u8array.length);if(dontAddNull)u8array.length=numBytesWritten;return u8array}Module["intArrayFromString"]=intArrayFromString;function intArrayToString(array){var ret=[];for(var i=0;i<array.length;i++){var chr=array[i];if(chr>255){chr&=255}ret.push(String.fromCharCode(chr))}return ret.join("")}Module["intArrayToString"]=intArrayToString;function writeStringToMemory(string,buffer,dontAddNull){Runtime.warnOnce("writeStringToMemory is deprecated and should not be called! Use stringToUTF8() instead!");var lastChar,end;if(dontAddNull){end=buffer+lengthBytesUTF8(string);lastChar=HEAP8[end]}stringToUTF8(string,buffer,Infinity);if(dontAddNull)HEAP8[end]=lastChar}Module["writeStringToMemory"]=writeStringToMemory;function writeArrayToMemory(array,buffer){HEAP8.set(array,buffer)}Module["writeArrayToMemory"]=writeArrayToMemory;function writeAsciiToMemory(str,buffer,dontAddNull){for(var i=0;i<str.length;++i){HEAP8[buffer++>>0]=str.charCodeAt(i)}if(!dontAddNull)HEAP8[buffer>>0]=0}Module["writeAsciiToMemory"]=writeAsciiToMemory;if(!Math["imul"]||Math["imul"](4294967295,5)!==-5)Math["imul"]=function imul(a,b){var ah=a>>>16;var al=a&65535;var bh=b>>>16;var bl=b&65535;return al*bl+(ah*bl+al*bh<<16)|0};Math.imul=Math["imul"];if(!Math["clz32"])Math["clz32"]=(function(x){x=x>>>0;for(var i=0;i<32;i++){if(x&1<<31-i)return i}return 32});Math.clz32=Math["clz32"];if(!Math["trunc"])Math["trunc"]=(function(x){return x<0?Math.ceil(x):Math.floor(x)});Math.trunc=Math["trunc"];var Math_abs=Math.abs;var Math_cos=Math.cos;var Math_sin=Math.sin;var Math_tan=Math.tan;var Math_acos=Math.acos;var Math_asin=Math.asin;var Math_atan=Math.atan;var Math_atan2=Math.atan2;var Math_exp=Math.exp;var Math_log=Math.log;var Math_sqrt=Math.sqrt;var Math_ceil=Math.ceil;var Math_floor=Math.floor;var Math_pow=Math.pow;var Math_imul=Math.imul;var Math_fround=Math.fround;var Math_round=Math.round;var Math_min=Math.min;var Math_clz32=Math.clz32;var Math_trunc=Math.trunc;var runDependencies=0;var runDependencyWatcher=null;var dependenciesFulfilled=null;function addRunDependency(id){runDependencies++;if(Module["monitorRunDependencies"]){Module["monitorRunDependencies"](runDependencies)}}Module["addRunDependency"]=addRunDependency;function removeRunDependency(id){runDependencies--;if(Module["monitorRunDependencies"]){Module["monitorRunDependencies"](runDependencies)}if(runDependencies==0){if(runDependencyWatcher!==null){clearInterval(runDependencyWatcher);runDependencyWatcher=null}if(dependenciesFulfilled){var callback=dependenciesFulfilled;dependenciesFulfilled=null;callback()}}}Module["removeRunDependency"]=removeRunDependency;Module["preloadedImages"]={};Module["preloadedAudios"]={};var ASM_CONSTS=[(function(){{return Module.getRandomValue()}}),(function(){{if(Module.getRandomValue===undefined){try{var window_="object"===typeof window?window:self,crypto_=typeof window_.crypto!=="undefined"?window_.crypto:window_.msCrypto,randomValuesStandard=(function(){var buf=new Uint32Array(1);crypto_.getRandomValues(buf);return buf[0]>>>0});randomValuesStandard();Module.getRandomValue=randomValuesStandard}catch(e){try{var crypto=__webpack_require__(479),randomValueNodeJS=(function(){var buf=crypto.randomBytes(4);return(buf[0]<<24|buf[1]<<16|buf[2]<<8|buf[3])>>>0});randomValueNodeJS();Module.getRandomValue=randomValueNodeJS}catch(e){throw"No secure random number generator found"}}}}})];function _emscripten_asm_const_i(code){return ASM_CONSTS[code]()}function _emscripten_asm_const_v(code){return ASM_CONSTS[code]()}STATIC_BASE=Runtime.GLOBAL_BASE;STATICTOP=STATIC_BASE+36e3;__ATINIT__.push();allocate([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,38,232,149,143,194,178,39,176,69,195,244,137,242,239,152,240,213,223,172,5,211,198,51,57,177,56,2,136,109,83,252,5,199,23,106,112,61,77,216,79,186,60,11,118,13,16,103,15,42,32,83,250,44,57,204,198,78,199,253,119,146,172,3,122,19,232,149,143,194,178,39,176,69,195,244,137,242,239,152,240,213,223,172,5,211,198,51,57,177,56,2,136,109,83,252,133,180,23,106,112,61,77,216,79,186,60,11,118,13,16,103,15,42,32,83,250,44,57,204,198,78,199,253,119,146,172,3,250,236,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,237,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,238,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,217,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,218,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,219,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,8,201,188,243,103,230,9,106,59,167,202,132,133,174,103,187,43,248,148,254,114,243,110,60,241,54,29,95,58,245,79,165,209,130,230,173,127,82,14,81,31,108,62,43,140,104,5,155,107,189,65,251,171,217,131,31,121,33,126,19,25,205,224,91,34,174,40,215,152,47,138,66,205,101,239,35,145,68,55,113,47,59,77,236,207,251,192,181,188,219,137,129,165,219,181,233,56,181,72,243,91,194,86,57,25,208,5,182,241,17,241,89,155,79,25,175,164,130,63,146,24,129,109,218,213,94,28,171,66,2,3,163,152,170,7,216,190,111,112,69,1,91,131,18,140,178,228,78,190,133,49,36,226,180,255,213,195,125,12,85,111,137,123,242,116,93,190,114,177,150,22,59,254,177,222,128,53,18,199,37,167,6,220,155,148,38,105,207,116,241,155,193,210,74,241,158,193,105,155,228,227,37,79,56,134,71,190,239,181,213,140,139,198,157,193,15,101,156,172,119,204,161,12,36,117,2,43,89,111,44,233,45,131,228,166,110,170,132,116,74,212,251,65,189,220,169,176,92,181,83,17,131,218,136,249,118,171,223,102,238,82,81,62,152,16,50,180,45,109,198,49,168,63,33,251,152,200,39,3,176,228,14,239,190,199,127,89,191,194,143,168,61,243,11,224,198,37,167,10,147,71,145,167,213,111,130,3,224,81,99,202,6,112,110,14,10,103,41,41,20,252,47,210,70,133,10,183,39,38,201,38,92,56,33,27,46,237,42,196,90,252,109,44,77,223,179,149,157,19,13,56,83,222,99,175,139,84,115,10,101,168,178,119,60,187,10,106,118,230,174,237,71,46,201,194,129,59,53,130,20,133,44,114,146,100,3,241,76,161,232,191,162,1,48,66,188,75,102,26,168,145,151,248,208,112,139,75,194,48,190,84,6,163,81,108,199,24,82,239,214,25,232,146,209,16,169,101,85,36,6,153,214,42,32,113,87,133,53,14,244,184,209,187,50,112,160,106,16,200,208,210,184,22,193,164,25,83,171,65,81,8,108,55,30,153,235,142,223,76,119,72,39,168,72,155,225,181,188,176,52,99,90,201,197,179,12,28,57,203,138,65,227,74,170,216,78,115,227,99,119,79,202,156,91,163,184,178,214,243,111,46,104,252,178,239,93,238,130,143,116,96,47,23,67,111,99,165,120,114,171,240,161,20,120,200,132,236,57,100,26,8,2,199,140,40,30,99,35,250,255,190,144,233,189,130,222,235,108,80,164,21,121,198,178,247,163,249,190,43,83,114,227,242,120,113,198,156,97,38,234,206,62,39,202,7,194,192,33,199,184,134,209,30,235,224,205,214,125,218,234,120,209,110,238,127,79,125,245,186,111,23,114,170,103,240,6,166,152,200,162,197,125,99,10,174,13,249,190,4,152,63,17,27,71,28,19,53,11,113,27,132,125,4,35,245,119,219,40,147,36,199,64,123,171,202,50,188,190,201,21,10,190,158,60,76,13,16,156,196,103,29,67,182,66,62,203,190,212,197,76,42,126,101,252,156,41,127,89,236,250,214,58,171,111,203,95,23,88,71,74,140,25,68,108,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,51,51,51,51,51,51,51,51,51,51,51,51,51,51,51,51,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,182,120,89,255,133,114,211,0,189,110,21,255,15,10,106,0,41,192,1,0,152,232,121,255,188,60,160,255,153,113,206,255,0,183,226,254,180,13,72,255,176,160,14,254,211,201,134,255,158,24,143,0,127,105,53,0,96,12,189,0,167,215,251,255,159,76,128,254,106,101,225,255,30,252,4,0,146,12,174,0,89,241,178,254,10,229,166,255,123,221,42,254,30,20,212,0,82,128,3,0,48,209,243,0,119,121,64,255,50,227,156,255,0,110,197,1,103,27,144,0,133,59,140,1,189,241,36,255,248,37,195,1,96,220,55,0,183,76,62,255,195,66,61,0,50,76,164,1,225,164,76,255,76,61,163,255,117,62,31,0,81,145,64,255,118,65,14,0,162,115,214,255,6,138,46,0,124,230,244,255,10,138,143,0,52,26,194,0,184,244,76,0,129,143,41,1,190,244,19,255,123,170,122,255,98,129,68,0,121,213,147,0,86,101,30,255,161,103,155,0,140,89,67,255,239,229,190,1,67,11,181,0,198,240,137,254,238,69,188,255,67,151,238,0,19,42,108,255,229,85,113,1,50,68,135,255,17,106,9,0,50,103,1,255,80,1,168,1,35,152,30,255,16,168,185,1,56,89,232,255,101,210,252,0,41,250,71,0,204,170,79,255,14,46,239,255,80,77,239,0,189,214,75,255,17,141,249,0,38,80,76,255,190,85,117,0,86,228,170,0,156,216,208,1,195,207,164,255,150,66,76,255,175,225,16,255,141,80,98,1,76,219,242,0,198,162,114,0,46,218,152,0,155,43,241,254,155,160,104,255,51,187,165,0,2,17,175,0,66,84,160,1,247,58,30,0,35,65,53,254,69,236,191,0,45,134,245,1,163,123,221,0,32,110,20,255,52,23,165,0,186,214,71,0,233,176,96,0,242,239,54,1,57,89,138,0,83,0,84,255,136,160,100,0,92,142,120,254,104,124,190,0,181,177,62,255,250,41,85,0,152,130,42,1,96,252,246,0,151,151,63,254,239,133,62,0,32,56,156,0,45,167,189,255,142,133,179,1,131,86,211,0,187,179,150,254,250,170,14,255,210,163,78,0,37,52,151,0,99,77,26,0,238,156,213,255,213,192,209,1,73,46,84,0,20,65,41,1,54,206,79,0,201,131,146,254,170,111,24,255,177,33,50,254,171,38,203,255,78,247,116,0,209,221,153,0,133,128,178,1,58,44,25,0,201,39,59,1,189,19,252,0,49,229,210,1,117,187,117,0,181,179,184,1,0,114,219,0,48,94,147,0,245,41,56,0,125,13,204,254,244,173,119,0,44,221,32,254,84,234,20,0,249,160,198,1,236,126,234,255,47,99,168,254,170,226,153,255,102,179,216,0,226,141,122,255,122,66,153,254,182,245,134,0,227,228,25,1,214,57,235,255,216,173,56,255,181,231,210,0,119,128,157,255,129,95,136,255,110,126,51,0,2,169,183,255,7,130,98,254,69,176,94,255,116,4,227,1,217,242,145,255,202,173,31,1,105,1,39,255,46,175,69,0,228,47,58,255,215,224,69,254,207,56,69,255,16,254,139,255,23,207,212,255,202,20,126,255,95,213,96,255,9,176,33,0,200,5,207,255,241,42,128,254,35,33,192,255,248,229,196,1,129,17,120,0,251,103,151,255,7,52,112,255,140,56,66,255,40,226,245,255,217,70,37,254,172,214,9,255,72,67,134,1,146,192,214,255,44,38,112,0,68,184,75,255,206,90,251,0,149,235,141,0,181,170,58,0,116,244,239,0,92,157,2,0,102,173,98,0,233,137,96,1,127,49,203,0,5,155,148,0,23,148,9,255,211,122,12,0,34,134,26,255,219,204,136,0,134,8,41,255,224,83,43,254,85,25,247,0,109,127,0,254,169,136,48,0,238,119,219,255,231,173,213,0,206,18,254,254,8,186,7,255,126,9,7,1,111,42,72,0,111,52,236,254,96,63,141,0,147,191,127,254,205,78,192,255,14,106,237,1,187,219,76,0,175,243,187,254,105,89,173,0,85,25,89,1,162,243,148,0,2,118,209,254,33,158,9,0,139,163,46,255,93,70,40,0,108,42,142,254,111,252,142,255,155,223,144,0,51,229,167,255,73,252,155,255,94,116,12,255,152,160,218,255,156,238,37,255,179,234,207,255,197,0,179,255,154,164,141,0,225,196,104,0,10,35,25,254,209,212,242,255,97,253,222,254,184,101,229,0,222,18,127,1,164,136,135,255,30,207,140,254,146,97,243,0,129,192,26,254,201,84,33,255,111,10,78,255,147,81,178,255,4,4,24,0,161,238,215,255,6,141,33,0,53,215,14,255,41,181,208,255,231,139,157,0,179,203,221,255,255,185,113,0,189,226,172,255,113,66,214,255,202,62,45,255,102,64,8,255,78,174,16,254,133,117,68,255,133,59,140,1,189,241,36,255,248,37,195,1,96,220,55,0,183,76,62,255,195,66,61,0,50,76,164,1,225,164,76,255,76,61,163,255,117,62,31,0,81,145,64,255,118,65,14,0,162,115,214,255,6,138,46,0,124,230,244,255,10,138,143,0,52,26,194,0,184,244,76,0,129,143,41,1,190,244,19,255,123,170,122,255,98,129,68,0,121,213,147,0,86,101,30,255,161,103,155,0,140,89,67,255,239,229,190,1,67,11,181,0,198,240,137,254,238,69,188,255,234,113,60,255,37,255,57,255,69,178,182,254,128,208,179,0,118,26,125,254,3,7,214,255,241,50,77,255,85,203,197,255,211,135,250,255,25,48,100,255,187,213,180,254,17,88,105,0,83,209,158,1,5,115,98,0,4,174,60,254,171,55,110,255,217,181,17,255,20,188,170,0,146,156,102,254,87,214,174,255,114,122,155,1,233,44,170,0,127,8,239,1,214,236,234,0,175,5,219,0,49,106,61,255,6,66,208,255,2,106,110,255,81,234,19,255,215,107,192,255,67,151,238,0,19,42,108,255,229,85,113,1,50,68,135,255,17,106,9,0,50,103,1,255,80,1,168,1,35,152,30,255,16,168,185,1,56,89,232,255,101,210,252,0,41,250,71,0,204,170,79,255,14,46,239,255,80,77,239,0,189,214,75,255,17,141,249,0,38,80,76,255,190,85,117,0,86,228,170,0,156,216,208,1,195,207,164,255,150,66,76,255,175,225,16,255,141,80,98,1,76,219,242,0,198,162,114,0,46,218,152,0,155,43,241,254,155,160,104,255,178,9,252,254,100,110,212,0,14,5,167,0,233,239,163,255,28,151,157,1,101,146,10,255,254,158,70,254,71,249,228,0,88,30,50,0,68,58,160,255,191,24,104,1,129,66,129,255,192,50,85,255,8,179,138,255,38,250,201,0,115,80,160,0,131,230,113,0,125,88,147,0,90,68,199,0,253,76,158,0,28,255,118,0,113,250,254,0,66,75,46,0,230,218,43,0,229,120,186,1,148,68,43,0,136,124,238,1,187,107,197,255,84,53,246,255,51,116,254,255,51,187,165,0,2,17,175,0,66,84,160,1,247,58,30,0,35,65,53,254,69,236,191,0,45,134,245,1,163,123,221,0,32,110,20,255,52,23,165,0,186,214,71,0,233,176,96,0,242,239,54,1,57,89,138,0,83,0,84,255,136,160,100,0,92,142,120,254,104,124,190,0,181,177,62,255,250,41,85,0,152,130,42,1,96,252,246,0,151,151,63,254,239,133,62,0,32,56,156,0,45,167,189,255,142,133,179,1,131,86,211,0,187,179,150,254,250,170,14,255,68,113,21,255,222,186,59,255,66,7,241,1,69,6,72,0,86,156,108,254,55,167,89,0,109,52,219,254,13,176,23,255,196,44,106,255,239,149,71,255,164,140,125,255,159,173,1,0,51,41,231,0,145,62,33,0,138,111,93,1,185,83,69,0,144,115,46,0,97,151,16,255,24,228,26,0,49,217,226,0,113,75,234,254,193,153,12,255,182,48,96,255,14,13,26,0,128,195,249,254,69,193,59,0,132,37,81,254,125,106,60,0,214,240,169,1,164,227,66,0,210,163,78,0,37,52,151,0,99,77,26,0,238,156,213,255,213,192,209,1,73,46,84,0,20,65,41,1,54,206,79,0,201,131,146,254,170,111,24,255,177,33,50,254,171,38,203,255,78,247,116,0,209,221,153,0,133,128,178,1,58,44,25,0,201,39,59,1,189,19,252,0,49,229,210,1,117,187,117,0,181,179,184,1,0,114,219,0,48,94,147,0,245,41,56,0,125,13,204,254,244,173,119,0,44,221,32,254,84,234,20,0,249,160,198,1,236,126,234,255,143,62,221,0,129,89,214,255,55,139,5,254,68,20,191,255,14,204,178,1,35,195,217,0,47,51,206,1,38,246,165,0,206,27,6,254,158,87,36,0,217,52,146,255,125,123,215,255,85,60,31,255,171,13,7,0,218,245,88,254,252,35,60,0,55,214,160,255,133,101,56,0,224,32,19,254,147,64,234,0,26,145,162,1,114,118,125,0,248,252,250,0,101,94,196,255,198,141,226,254,51,42,182,0,135,12,9,254,109,172,210,255,197,236,194,1,241,65,154,0,48,156,47,255,153,67,55,255,218,165,34,254,74,180,179,0,218,66,71,1,88,122,99,0,212,181,219,255,92,42,231,255,239,0,154,0,245,77,183,255,94,81,170,1,18,213,216,0,171,93,71,0,52,94,248,0,18,151,161,254,197,209,66,255,174,244,15,254,162,48,183,0,49,61,240,254,182,93,195,0,199,228,6,1,200,5,17,255,137,45,237,255,108,148,4,0,90,79,237,255,39,63,77,255,53,82,207,1,142,22,118,255,101,232,18,1,92,26,67,0,5,200,88,255,33,168,138,255,149,225,72,0,2,209,27,255,44,245,168,1,220,237,17,255,30,211,105,254,141,238,221,0,128,80,245,254,111,254,14,0,222,95,190,1,223,9,241,0,146,76,212,255,108,205,104,255,63,117,153,0,144,69,48,0,35,228,111,0,192,33,193,255,112,214,190,254,115,152,151,0,23,102,88,0,51,74,248,0,226,199,143,254,204,162,101,255,208,97,189,1,245,104,18,0,230,246,30,255,23,148,69,0,110,88,52,254,226,181,89,255,208,47,90,254,114,161,80,255,33,116,248,0,179,152,87,255,69,144,177,1,88,238,26,255,58,32,113,1,1,77,69,0,59,121,52,255,152,238,83,0,52,8,193,0,231,39,233,255,199,34,138,0,222,68,173,0,91,57,242,254,220,210,127,255,192,7,246,254,151,35,187,0,195,236,165,0,111,93,206,0,212,247,133,1,154,133,209,255,155,231,10,0,64,78,38,0,122,249,100,1,30,19,97,255,62,91,249,1,248,133,77,0,197,63,168,254,116,10,82,0,184,236,113,254,212,203,194,255,61,100,252,254,36,5,202,255,119,91,153,255,129,79,29,0,103,103,171,254,237,215,111,255,216,53,69,0,239,240,23,0,194,149,221,255,38,225,222,0,232,255,180,254,118,82,133,255,57,209,177,1,139,232,133,0,158,176,46,254,194,115,46,0,88,247,229,1,28,103,191,0,221,222,175,254,149,235,44,0,151,228,25,254,218,105,103,0,142,85,210,0,149,129,190,255,213,65,94,254,117,134,224,255,82,198,117,0,157,221,220,0,163,101,36,0,197,114,37,0,104,172,166,254,11,182,0,0,81,72,188,255,97,188,16,255,69,6,10,0,199,147,145,255,8,9,115,1,65,214,175,255,217,173,209,0,80,127,166,0,247,229,4,254,167,183,124,255,90,28,204,254,175,59,240,255,11,41,248,1,108,40,51,255,144,177,195,254,150,250,126,0,138,91,65,1,120,60,222,255,245,193,239,0,29,214,189,255,128,2,25,0,80,154,162,0,77,220,107,1,234,205,74,255,54,166,103,255,116,72,9,0,228,94,47,255,30,200,25,255,35,214,89,255,61,176,140,255,83,226,163,255,75,130,172,0,128,38,17,0,95,137,152,255,215,124,159,1,79,93,0,0,148,82,157,254,195,130,251,255,40,202,76,255,251,126,224,0,157,99,62,254,207,7,225,255,96,68,195,0,140,186,157,255,131,19,231,255,42,128,254,0,52,219,61,254,102,203,72,0,141,7,11,255,186,164,213,0,31,122,119,0,133,242,145,0,208,252,232,255,91,213,182,255,143,4,250,254,249,215,74,0,165,30,111,1,171,9,223,0,229,123,34,1,92,130,26,255,77,155,45,1,195,139,28,255,59,224,78,0,136,17,247,0,108,121,32,0,79,250,189,255,96,227,252,254,38,241,62,0,62,174,125,255,155,111,93,255,10,230,206,1,97,197,40,255,0,49,57,254,65,250,13,0,18,251,150,255,220,109,210,255,5,174,166,254,44,129,189,0,235,35,147,255,37,247,141,255,72,141,4,255,103,107,255,0,247,90,4,0,53,44,42,0,2,30,240,0,4,59,63,0,88,78,36,0,113,167,180,0,190,71,193,255,199,158,164,255,58,8,172,0,77,33,12,0,65,63,3,0,153,77,33,255,172,254,102,1,228,221,4,255,87,30,254,1,146,41,86,255,138,204,239,254,108,141,17,255,187,242,135,0,210,208,127,0,68,45,14,254,73,96,62,0,81,60,24,255,170,6,36,255,3,249,26,0,35,213,109,0,22,129,54,255,21,35,225,255,234,61,56,255,58,217,6,0,143,124,88,0,236,126,66,0,209,38,183,255,34,238,6,255,174,145,102,0,95,22,211,0,196,15,153,254,46,84,232,255,117,34,146,1,231,250,74,255,27,134,100,1,92,187,195,255,170,198,112,0,120,28,42,0,209,70,67,0,29,81,31,0,29,168,100,1,169,173,160,0,107,35,117,0,62,96,59,255,81,12,69,1,135,239,190,255,220,252,18,0,163,220,58,255,137,137,188,255,83,102,109,0,96,6,76,0,234,222,210,255,185,174,205,1,60,158,213,255,13,241,214,0,172,129,140,0,93,104,242,0,192,156,251,0,43,117,30,0,225,81,158,0,127,232,218,0,226,28,203,0,233,27,151,255,117,43,5,255,242,14,47,255,33,20,6,0,137,251,44,254,27,31,245,255,183,214,125,254,40,121,149,0,186,158,213,255,89,8,227,0,69,88,0,254,203,135,225,0,201,174,203,0,147,71,184,0,18,121,41,254,94,5,78,0,224,214,240,254,36,5,180,0,251,135,231,1,163,138,212,0,210,249,116,254,88,129,187,0,19,8,49,254,62,14,144,255,159,76,211,0,214,51,82,0,109,117,228,254,103,223,203,255,75,252,15,1,154,71,220,255,23,13,91,1,141,168,96,255,181,182,133,0,250,51,55,0,234,234,212,254,175,63,158,0,39,240,52,1,158,189,36,255,213,40,85,1,32,180,247,255,19,102,26,1,84,24,97,255,69,21,222,0,148,139,122,255,220,213,235,1,232,203,255,0,121,57,147,0,227,7,154,0,53,22,147,1,72,1,225,0,82,134,48,254,83,60,157,255,145,72,169,0,34,103,239,0,198,233,47,0,116,19,4,255,184,106,9,255,183,129,83,0,36,176,230,1,34,103,72,0,219,162,134,0,245,42,158,0,32,149,96,254,165,44,144,0,202,239,72,254,215,150,5,0,42,66,36,1,132,215,175,0,86,174,86,255,26,197,156,255,49,232,135,254,103,182,82,0,253,128,176,1,153,178,122,0,245,250,10,0,236,24,178,0,137,106,132,0,40,29,41,0,50,30,152,255,124,105,38,0,230,191,75,0,143,43,170,0,44,131,20,255,44,13,23,255,237,255,155,1,159,109,100,255,112,181,24,255,104,220,108,0,55,211,131,0,99,12,213,255,152,151,145,255,238,5,159,0,97,155,8,0,33,108,81,0,1,3,103,0,62,109,34,255,250,155,180,0,32,71,195,255,38,70,145,1,159,95,245,0,69,229,101,1,136,28,240,0,79,224,25,0,78,110,121,255,248,168,124,0,187,128,247,0,2,147,235,254,79,11,132,0,70,58,12,1,181,8,163,255,79,137,133,255,37,170,11,255,141,243,85,255,176,231,215,255,204,150,164,255,239,215,39,255,46,87,156,254,8,163,88,255,172,34,232,0,66,44,102,255,27,54,41,254,236,99,87,255,41,123,169,1,52,114,43,0,117,134,40,0,155,134,26,0,231,207,91,254,35,132,38,255,19,102,125,254,36,227,133,255,118,3,113,255,29,13,124,0,152,96,74,1,88,146,206,255,167,191,220,254,162,18,88,255,182,100,23,0,31,117,52,0,81,46,106,1,12,2,7,0,69,80,201,1,209,246,172,0,12,48,141,1,224,211,88,0,116,226,159,0,122,98,130,0,65,236,234,1,225,226,9,255,207,226,123,1,89,214,59,0,112,135,88,1,90,244,203,255,49,11,38,1,129,108,186,0,89,112,15,1,101,46,204,255,127,204,45,254,79,255,221,255,51,73,18,255,127,42,101,255,241,21,202,0,160,227,7,0,105,50,236,0,79,52,197,255,104,202,208,1,180,15,16,0,101,197,78,255,98,77,203,0,41,185,241,1,35,193,124,0,35,155,23,255,207,53,192,0,11,125,163,1,249,158,185,255,4,131,48,0,21,93,111,255,61,121,231,1,69,200,36,255,185,48,185,255,111,238,21,255,39,50,25,255,99,215,163,255,87,212,30,255,164,147,5,255,128,6,35,1,108,223,110,255,194,76,178,0,74,101,180,0,243,47,48,0,174,25,43,255,82,173,253,1,54,114,192,255,40,55,91,0,215,108,176,255,11,56,7,0,224,233,76,0,209,98,202,254,242,25,125,0,44,193,93,254,203,8,177,0,135,176,19,0,112,71,213,255,206,59,176,1,4,67,26,0,14,143,213,254,42,55,208,255,60,67,120,0,193,21,163,0,99,164,115,0,10,20,118,0,156,212,222,254,160,7,217,255,114,245,76,1,117,59,123,0,176,194,86,254,213,15,176,0,78,206,207,254,213,129,59,0,233,251,22,1,96,55,152,255,236,255,15,255,197,89,84,255,93,149,133,0,174,160,113,0,234,99,169,255,152,116,88,0,144,164,83,255,95,29,198,255,34,47,15,255,99,120,134,255,5,236,193,0,249,247,126,255,147,187,30,0,50,230,117,255,108,217,219,255,163,81,166,255,72,25,169,254,155,121,79,255,28,155,89,254,7,126,17,0,147,65,33,1,47,234,253,0,26,51,18,0,105,83,199,255,163,196,230,0,113,248,164,0,226,254,218,0,189,209,203,255,164,247,222,254,255,35,165,0,4,188,243,1,127,179,71,0,37,237,254,255,100,186,240,0,5,57,71,254,103,72,73,255,244,18,81,254,229,210,132,255,238,6,180,255,11,229,174,255,227,221,192,1,17,49,28,0,163,215,196,254,9,118,4,255,51,240,71,0,113,129,109,255,76,240,231,0,188,177,127,0,125,71,44,1,26,175,243,0,94,169,25,254,27,230,29,0,15,139,119,1,168,170,186,255,172,197,76,255,252,75,188,0,137,124,196,0,72,22,96,255,45,151,249,1,220,145,100,0,64,192,159,255,120,239,226,0,129,178,146,0,0,192,125,0,235,138,234,0,183,157,146,0,83,199,192,255,184,172,72,255,73,225,128,0,77,6,250,255,186,65,67,0,104,246,207,0,188,32,138,255,218,24,242,0,67,138,81,254,237,129,121,255,20,207,150,1,41,199,16,255,6,20,128,0,159,118,5,0,181,16,143,255,220,38,15,0,23,64,147,254,73,26,13,0,87,228,57,1,204,124,128,0,43,24,223,0,219,99,199,0,22,75,20,255,19,27,126,0,157,62,215,0,110,29,230,0,179,167,255,1,54,252,190,0,221,204,182,254,179,158,65,255,81,157,3,0,194,218,159,0,170,223,0,0,224,11,32,255,38,197,98,0,168,164,37,0,23,88,7,1,164,186,110,0,96,36,134,0,234,242,229,0,250,121,19,0,242,254,112,255,3,47,94,1,9,239,6,255,81,134,153,254,214,253,168,255,67,124,224,0,245,95,74,0,28,30,44,254,1,109,220,255,178,89,89,0,252,36,76,0,24,198,46,255,76,77,111,0,134,234,136,255,39,94,29,0,185,72,234,255,70,68,135,255,231,102,7,254,77,231,140,0,167,47,58,1,148,97,118,255,16,27,225,1,166,206,143,255,110,178,214,255,180,131,162,0,143,141,225,1,13,218,78,255,114,153,33,1,98,104,204,0,175,114,117,1,167,206,75,0,202,196,83,1,58,64,67,0,138,47,111,1,196,247,128,255,137,224,224,254,158,112,207,0,154,100,255,1,134,37,107,0,198,128,79,255,127,209,155,255,163,254,185,254,60,14,243,0,31,219,112,254,29,217,65,0,200,13,116,254,123,60,196,255,224,59,184,254,242,89,196,0,123,16,75,254,149,16,206,0,69,254,48,1,231,116,223,255,209,160,65,1,200,80,98,0,37,194,184,254,148,63,34,0,139,240,65,255,217,144,132,255,56,38,45,254,199,120,210,0,108,177,166,255,160,222,4,0,220,126,119,254,165,107,160,255,82,220,248,1,241,175,136,0,144,141,23,255,169,138,84,0,160,137,78,255,226,118,80,255,52,27,132,255,63,96,139,255,152,250,39,0,188,155,15,0,232,51,150,254,40,15,232,255,240,229,9,255,137,175,27,255,75,73,97,1,218,212,11,0,135,5,162,1,107,185,213,0,2,249,107,255,40,242,70,0,219,200,25,0,25,157,13,0,67,82,80,255,196,249,23,255,145,20,149,0,50,72,146,0,94,76,148,1,24,251,65,0,31,192,23,0,184,212,201,255,123,233,162,1,247,173,72,0,162,87,219,254,126,134,89,0,159,11,12,254,166,105,29,0,73,27,228,1,113,120,183,255,66,163,109,1,212,143,11,255,159,231,168,1,255,128,90,0,57,14,58,254,89,52,10,255,253,8,163,1,0,145,210,255,10,129,85,1,46,181,27,0,103,136,160,254,126,188,209,255,34,35,111,0,215,219,24,255,212,11,214,254,101,5,118,0,232,197,133,255,223,167,109,255,237,80,86,255,70,139,94,0,158,193,191,1,155,15,51,255,15,190,115,0,78,135,207,255,249,10,27,1,181,125,233,0,95,172,13,254,170,213,161,255,39,236,138,255,95,93,87,255,190,128,95,0,125,15,206,0,166,150,159,0,227,15,158,255,206,158,120,255,42,141,128,0,101,178,120,1,156,109,131,0,218,14,44,254,247,168,206,255,212,112,28,0,112,17,228,255,90,16,37,1,197,222,108,0,254,207,83,255,9,90,243,255,243,244,172,0,26,88,115,255,205,116,122,0,191,230,193,0,180,100,11,1,217,37,96,255,154,78,156,0,235,234,31,255,206,178,178,255,149,192,251,0,182,250,135,0,246,22,105,0,124,193,109,255,2,210,149,255,169,17,170,0,0,96,110,255,117,9,8,1,50,123,40,255,193,189,99,0,34,227,160,0,48,80,70,254,211,51,236,0,45,122,245,254,44,174,8,0,173,37,233,255,158,65,171,0,122,69,215,255,90,80,2,255,131,106,96,254,227,114,135,0,205,49,119,254,176,62,64,255,82,51,17,255,241,20,243,255,130,13,8,254,128,217,243,255,162,27,1,254,90,118,241,0,246,198,246,255,55,16,118,255,200,159,157,0,163,17,1,0,140,107,121,0,85,161,118,255,38,0,149,0,156,47,238,0,9,166,166,1,75,98,181,255,50,74,25,0,66,15,47,0,139,225,159,0,76,3,142,255,14,238,184,0,11,207,53,255,183,192,186,1,171,32,174,255,191,76,221,1,247,170,219,0,25,172,50,254,217,9,233,0,203,126,68,255,183,92,48,0,127,167,183,1,65,49,254,0,16,63,127,1,254,21,170,255,59,224,127,254,22,48,63,255,27,78,130,254,40,195,29,0,250,132,112,254,35,203,144,0,104,169,168,0,207,253,30,255,104,40,38,254,94,228,88,0,206,16,128,255,212,55,122,255,223,22,234,0,223,197,127,0,253,181,181,1,145,102,118,0,236,153,36,255,212,217,72,255,20,38,24,254,138,62,62,0,152,140,4,0,230,220,99,255,1,21,212,255,148,201,231,0,244,123,9,254,0,171,210,0,51,58,37,255,1,255,14,255,244,183,145,254,0,242,166,0,22,74,132,0,121,216,41,0,95,195,114,254,133,24,151,255,156,226,231,255,247,5,77,255,246,148,115,254,225,92,81,255,222,80,246,254,170,123,89,255,74,199,141,0,29,20,8,255,138,136,70,255,93,75,92,0,221,147,49,254,52,126,226,0,229,124,23,0,46,9,181,0,205,64,52,1,131,254,28,0,151,158,212,0,131,64,78,0,206,25,171,0,0,230,139,0,191,253,110,254,103,247,167,0,64,40,40,1,42,165,241,255,59,75,228,254,124,243,189,255,196,92,178,255,130,140,86,255,141,89,56,1,147,198,5,255,203,248,158,254,144,162,141,0,11,172,226,0,130,42,21,255,1,167,143,255,144,36,36,255,48,88,164,254,168,170,220,0,98,71,214,0,91,208,79,0,159,76,201,1,166,42,214,255,69,255,0,255,6,128,125,255,190,1,140,0,146,83,218,255,215,238,72,1,122,127,53,0,189,116,165,255,84,8,66,255,214,3,208,255,213,110,133,0,195,168,44,1,158,231,69,0,162,64,200,254,91,58,104,0,182,58,187,254,249,228,136,0,203,134,76,254,99,221,233,0,75,254,214,254,80,69,154,0,64,152,248,254,236,136,202,255,157,105,153,254,149,175,20,0,22,35,19,255,124,121,233,0,186,250,198,254,132,229,139,0,137,80,174,255,165,125,68,0,144,202,148,254,235,239,248,0,135,184,118,0,101,94,17,255,122,72,70,254,69,130,146,0,127,222,248,1,69,127,118,255,30,82,215,254,188,74,19,255,229,167,194,254,117,25,66,255,65,234,56,254,213,22,156,0,151,59,93,254,45,28,27,255,186,126,164,255,32,6,239,0,127,114,99,1,219,52,2,255,99,96,166,254,62,190,126,255,108,222,168,1,75,226,174,0,230,226,199,0,60,117,218,255,252,248,20,1,214,188,204,0,31,194,134,254,123,69,192,255,169,173,36,254,55,98,91,0,223,42,102,254,137,1,102,0,157,90,25,0,239,122,64,255,252,6,233,0,7,54,20,255,82,116,174,0,135,37,54,255,15,186,125,0,227,112,175,255,100,180,225,255,42,237,244,255,244,173,226,254,248,18,33,0,171,99,150,255,74,235,50,255,117,82,32,254,106,168,237,0,207,109,208,1,228,9,186,0,135,60,169,254,179,92,143,0,244,170,104,255,235,45,124,255,70,99,186,0,117,137,183,0,224,31,215,0,40,9,100,0,26,16,95,1,68,217,87,0,8,151,20,255,26,100,58,255,176,165,203,1,52,118,70,0,7,32,254,254,244,254,245,255,167,144,194,255,125,113,23,255,176,121,181,0,136,84,209,0,138,6,30,255,89,48,28,0,33,155,14,255,25,240,154,0,141,205,109,1,70,115,62,255,20,40,107,254,138,154,199,255,94,223,226,255,157,171,38,0,163,177,25,254,45,118,3,255,14,222,23,1,209,190,81,255,118,123,232,1,13,213,101,255,123,55,123,254,27,246,165,0,50,99,76,255,140,214,32,255,97,65,67,255,24,12,28,0,174,86,78,1,64,247,96,0,160,135,67,0,66,55,243,255,147,204,96,255,26,6,33,255,98,51,83,1,153,213,208,255,2,184,54,255,25,218,11,0,49,67,246,254,18,149,72,255,13,25,72,0,42,79,214,0,42,4,38,1,27,139,144,255,149,187,23,0,18,164,132,0,245,84,184,254,120,198,104,255,126,218,96,0,56,117,234,255,13,29,214,254,68,47,10,255,167,154,132,254,152,38,198,0,66,178,89,255,200,46,171,255,13,99,83,255,210,187,253,255,170,45,42,1,138,209,124,0,214,162,141,0,12,230,156,0,102,36,112,254,3,147,67,0,52,215,123,255,233,171,54,255,98,137,62,0,247,218,39,255,231,218,236,0,247,191,127,0,195,146,84,0,165,176,92,255,19,212,94,255,17,74,227,0,88,40,153,1,198,147,1,255,206,67,245,254,240,3,218,255,61,141,213,255,97,183,106,0,195,232,235,254,95,86,154,0,209,48,205,254,118,209,241,255,240,120,223,1,213,29,159,0,163,127,147,255,13,218,93,0,85,24,68,254,70,20,80,255,189,5,140,1,82,97,254,255,99,99,191,255,132,84,133,255,107,218,116,255,112,122,46,0,105,17,32,0,194,160,63,255,68,222,39,1,216,253,92,0,177,105,205,255,149,201,195,0,42,225,11,255,40,162,115,0,9,7,81,0,165,218,219,0,180,22,0,254,29,146,252,255,146,207,225,1,180,135,96,0,31,163,112,0,177,11,219,255,133,12,193,254,43,78,50,0,65,113,121,1,59,217,6,255,110,94,24,1,112,172,111,0,7,15,96,0,36,85,123,0,71,150,21,255,208,73,188,0,192,11,167,1,213,245,34,0,9,230,92,0,162,142,39,255,215,90,27,0,98,97,89,0,94,79,211,0,90,157,240,0,95,220,126,1,102,176,226,0,36,30,224,254,35,31,127,0,231,232,115,1,85,83,130,0,210,73,245,255,47,143,114,255,68,65,197,0,59,72,62,255,183,133,173,254,93,121,118,255,59,177,81,255,234,69,173,255,205,128,177,0,220,244,51,0,26,244,209,1,73,222,77,255,163,8,96,254,150,149,211,0,158,254,203,1,54,127,139,0,161,224,59,0,4,109,22,255,222,42,45,255,208,146,102,255,236,142,187,0,50,205,245,255,10,74,89,254,48,79,142,0,222,76,130,255,30,166,63,0,236,12,13,255,49,184,244,0,187,113,102,0,218,101,253,0,153,57,182,254,32,150,42,0,25,198,146,1,237,241,56,0,140,68,5,0,91,164,172,255,78,145,186,254,67,52,205,0,219,207,129,1,109,115,17,0,54,143,58,1,21,248,120,255,179,255,30,0,193,236,66,255,1,255,7,255,253,192,48,255,19,69,217,1,3,214,0,255,64,101,146,1,223,125,35,255,235,73,179,255,249,167,226,0,225,175,10,1,97,162,58,0,106,112,171,1,84,172,5,255,133,140,178,255,134,245,142,0,97,90,125,255,186,203,185,255,223,77,23,255,192,92,106,0,15,198,115,255,217,152,248,0,171,178,120,255,228,134,53,0,176,54,193,1,250,251,53,0,213,10,100,1,34,199,106,0,151,31,244,254,172,224,87,255,14,237,23,255,253,85,26,255,127,39,116,255,172,104,100,0,251,14,70,255,212,208,138,255,253,211,250,0,176,49,165,0,15,76,123,255,37,218,160,255,92,135,16,1,10,126,114,255,70,5,224,255,247,249,141,0,68,20,60,1,241,210,189,255,195,217,187,1,151,3,113,0,151,92,174,0,231,62,178,255,219,183,225,0,23,23,33,255,205,181,80,0,57,184,248,255,67,180,1,255,90,123,93,255,39,0,162,255,96,248,52,255,84,66,140,0,34,127,228,255,194,138,7,1,166,110,188,0,21,17,155,1,154,190,198,255,214,80,59,255,18,7,143,0,72,29,226,1,199,217,249,0,232,161,71,1,149,190,201,0,217,175,95,254,113,147,67,255,138,143,199,255,127,204,1,0,29,182,83,1,206,230,155,255,186,204,60,0,10,125,85,255,232,96,25,255,255,89,247,255,213,254,175,1,232,193,81,0,28,43,156,254,12,69,8,0,147,24,248,0,18,198,49,0,134,60,35,0,118,246,18,255,49,88,254,254,228,21,186,255,182,65,112,1,219,22,1,255,22,126,52,255,189,53,49,255,112,25,143,0,38,127,55,255,226,101,163,254,208,133,61,255,137,69,174,1,190,118,145,255,60,98,219,255,217,13,245,255,250,136,10,0,84,254,226,0,201,31,125,1,240,51,251,255,31,131,130,255,2,138,50,255,215,215,177,1,223,12,238,255,252,149,56,255,124,91,68,255,72,126,170,254,119,255,100,0,130,135,232,255,14,79,178,0,250,131,197,0,138,198,208,0,121,216,139,254,119,18,36,255,29,193,122,0,16,42,45,255,213,240,235,1,230,190,169,255,198,35,228,254,110,173,72,0,214,221,241,255,56,148,135,0,192,117,78,254,141,93,207,255,143,65,149,0,21,18,98,255,95,44,244,1,106,191,77,0,254,85,8,254,214,110,176,255,73,173,19,254,160,196,199,255,237,90,144,0,193,172,113,255,200,155,136,254,228,90,221,0,137,49,74,1,164,221,215,255,209,189,5,255,105,236,55,255,42,31,129,1,193,255,236,0,46,217,60,0,138,88,187,255,226,82,236,255,81,69,151,255,142,190,16,1,13,134,8,0,127,122,48,255,81,64,156,0,171,243,139,0,237,35,246,0,122,143,193,254,212,122,146,0,95,41,255,1,87,132,77,0,4,212,31,0,17,31,78,0,39,45,173,254,24,142,217,255,95,9,6,255,227,83,6,0,98,59,130,254,62,30,33,0,8,115,211,1,162,97,128,255,7,184,23,254,116,28,168,255,248,138,151,255,98,244,240,0,186,118,130,0,114,248,235,255,105,173,200,1,160,124,71,255,94,36,164,1,175,65,146,255,238,241,170,254,202,198,197,0,228,71,138,254,45,246,109,255,194,52,158,0,133,187,176,0,83,252,154,254,89,189,221,255,170,73,252,0,148,58,125,0,36,68,51,254,42,69,177,255,168,76,86,255,38,100,204,255,38,53,35,0,175,19,97,0,225,238,253,255,81,81,135,0,210,27,255,254,235,73,107,0,8,207,115,0,82,127,136,0,84,99,21,254,207,19,136,0,100,164,101,0,80,208,77,255,132,207,237,255,15,3,15,255,33,166,110,0,156,95,85,255,37,185,111,1,150,106,35,255,166,151,76,0,114,87,135,255,159,194,64,0,12,122,31,255,232,7,101,254,173,119,98,0,154,71,220,254,191,57,53,255,168,232,160,255,224,32,99,255,218,156,165,0,151,153,163,0,217,13,148,1,197,113,89,0,149,28,161,254,207,23,30,0,105,132,227,255,54,230,94,255,133,173,204,255,92,183,157,255,88,144,252,254,102,33,90,0,159,97,3,0,181,218,155,255,240,114,119,0,106,214,53,255,165,190,115,1,152,91,225,255,88,106,44,255,208,61,113,0,151,52,124,0,191,27,156,255,110,54,236,1,14,30,166,255,39,127,207,1,229,199,28,0,188,228,188,254,100,157,235,0,246,218,183,1,107,22,193,255,206,160,95,0,76,239,147,0,207,161,117,0,51,166,2,255,52,117,10,254,73,56,227,255,152,193,225,0,132,94,136,255,101,191,209,0,32,107,229,255,198,43,180,1,100,210,118,0,114,67,153,255,23,88,26,255,89,154,92,1,220,120,140,255,144,114,207,255,252,115,250,255,34,206,72,0,138,133,127,255,8,178,124,1,87,75,97,0,15,229,92,254,240,67,131,255,118,123,227,254,146,120,104,255,145,213,255,1,129,187,70,255,219,119,54,0,1,19,173,0,45,150,148,1,248,83,72,0,203,233,169,1,142,107,56,0,247,249,38,1,45,242,80,255,30,233,103,0,96,82,70,0,23,201,111,0,81,39,30,255,161,183,78,255,194,234,33,255,68,227,140,254,216,206,116,0,70,27,235,255,104,144,79,0,164,230,93,254,214,135,156,0,154,187,242,254,188,20,131,255,36,109,174,0,159,112,241,0,5,110,149,1,36,165,218,0,166,29,19,1,178,46,73,0,93,43,32,254,248,189,237,0,102,155,141,0,201,93,195,255,241,139,253,255,15,111,98,255,108,65,163,254,155,79,190,255,73,174,193,254,246,40,48,255,107,88,11,254,202,97,85,255,253,204,18,255,113,242,66,0,110,160,194,254,208,18,186,0,81,21,60,0,188,104,167,255,124,166,97,254,210,133,142,0,56,242,137,254,41,111,130,0,111,151,58,1,111,213,141,255,183,172,241,255,38,6,196,255,185,7,123,255,46,11,246,0,245,105,119,1,15,2,161,255,8,206,45,255,18,202,74,255,83,124,115,1,212,141,157,0,83,8,209,254,139,15,232,255,172,54,173,254,50,247,132,0,214,189,213,0,144,184,105,0,223,254,248,0,255,147,240,255,23,188,72,0,7,51,54,0,188,25,180,254,220,180,0,255,83,160,20,0,163,189,243,255,58,209,194,255,87,73,60,0,106,24,49,0,245,249,220,0,22,173,167,0,118,11,195,255,19,126,237,0,110,159,37,255,59,82,47,0,180,187,86,0,188,148,208,1,100,37,133,255,7,112,193,0,129,188,156,255,84,106,129,255,133,225,202,0,14,236,111,255,40,20,101,0,172,172,49,254,51,54,74,255,251,185,184,255,93,155,224,255,180,249,224,1,230,178,146,0,72,57,54,254,178,62,184,0,119,205,72,0,185,239,253,255,61,15,218,0,196,67,56,255,234,32,171,1,46,219,228,0,208,108,234,255,20,63,232,255,165,53,199,1,133,228,5,255,52,205,107,0,74,238,140,255,150,156,219,254,239,172,178,255,251,189,223,254,32,142,211,255,218,15,138,1,241,196,80,0,28,36,98,254,22,234,199,0,61,237,220,255,246,57,37,0,142,17,142,255,157,62,26,0,43,238,95,254,3,217,6,255,213,25,240,1,39,220,174,255,154,205,48,254,19,13,192,255,244,34,54,254,140,16,155,0,240,181,5,254,155,193,60,0,166,128,4,255,36,145,56,255,150,240,219,0,120,51,145,0,82,153,42,1,140,236,146,0,107,92,248,1,189,10,3,0,63,136,242,0,211,39,24,0,19,202,161,1,173,27,186,255,210,204,239,254,41,209,162,255,182,254,159,255,172,116,52,0,195,103,222,254,205,69,59,0,53,22,41,1,218,48,194,0,80,210,242,0,210,188,207,0,187,161,161,254,216,17,1,0,136,225,113,0,250,184,63,0,223,30,98,254,77,168,162,0,59,53,175,0,19,201,10,255,139,224,194,0,147,193,154,255,212,189,12,254,1,200,174,255,50,133,113,1,94,179,90,0,173,182,135,0,94,177,113,0,43,89,215,255,136,252,106,255,123,134,83,254,5,245,66,255,82,49,39,1,220,2,224,0,97,129,177,0,77,59,89,0,61,29,155,1,203,171,220,255,92,78,139,0,145,33,181,255,169,24,141,1,55,150,179,0,139,60,80,255,218,39,97,0,2,147,107,255,60,248,72,0,173,230,47,1,6,83,182,255,16,105,162,254,137,212,81,255,180,184,134,1,39,222,164,255,221,105,251,1,239,112,125,0,63,7,97,0,63,104,227,255,148,58,12,0,90,60,224,255,84,212,252,0,79,215,168,0,248,221,199,1,115,121,1,0,36,172,120,0,32,162,187,255,57,107,49,255,147,42,21,0,106,198,43,1,57,74,87,0,126,203,81,255,129,135,195,0,140,31,177,0,221,139,194,0,3,222,215,0,131,68,231,0,177,86,178,254,124,151,180,0,184,124,38,1,70,163,17,0,249,251,181,1,42,55,227,0,226,161,44,0,23,236,110,0,51,149,142,1,93,5,236,0,218,183,106,254,67,24,77,0,40,245,209,255,222,121,153,0,165,57,30,0,83,125,60,0,70,38,82,1,229,6,188,0,109,222,157,255,55,118,63,255,205,151,186,0,227,33,149,255,254,176,246,1,227,177,227,0,34,106,163,254,176,43,79,0,106,95,78,1,185,241,122,255,185,14,61,0,36,1,202,0,13,178,162,255,247,11,132,0,161,230,92,1,65,1,185,255,212,50,165,1,141,146,64,255,158,242,218,0,21,164,125,0,213,139,122,1,67,71,87,0,203,158,178,1,151,92,43,0,152,111,5,255,39,3,239,255,217,255,250,255,176,63,71,255,74,245,77,1,250,174,18,255,34,49,227,255,246,46,251,255,154,35,48,1,125,157,61,255,106,36,78,255,97,236,153,0,136,187,120,255,113,134,171,255,19,213,217,254,216,94,209,255,252,5,61,0,94,3,202,0,3,26,183,255,64,191,43,255,30,23,21,0,129,141,77,255,102,120,7,1,194,76,140,0,188,175,52,255,17,81,148,0,232,86,55,1,225,48,172,0,134,42,42,255,238,50,47,0,169,18,254,0,20,147,87,255,14,195,239,255,69,247,23,0,238,229,128,255,177,49,112,0,168,98,251,255,121,71,248,0,243,8,145,254,246,227,153,255,219,169,177,254,251,139,165,255,12,163,185,255,164,40,171,255,153,159,27,254,243,109,91,255,222,24,112,1,18,214,231,0,107,157,181,254,195,147,0,255,194,99,104,255,89,140,190,255,177,66,126,254,106,185,66],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE);allocate([49,218,31,0,252,174,158,0,188,79,230,1,238,41,224,0,212,234,8,1,136,11,181,0,166,117,83,255,68,195,94,0,46,132,201,0,240,152,88,0,164,57,69,254,160,224,42,255,59,215,67,255,119,195,141,255,36,180,121,254,207,47,8,255,174,210,223,0,101,197,68,255,255,82,141,1,250,137,233,0,97,86,133,1,16,80,69,0,132,131,159,0,116,93,100,0,45,141,139,0,152,172,157,255,90,43,91,0,71,153,46,0,39,16,112,255,217,136,97,255,220,198,25,254,177,53,49,0,222,88,134,255,128,15,60,0,207,192,169,255,192,116,209,255,106,78,211,1,200,213,183,255,7,12,122,254,222,203,60,255,33,110,199,254,251,106,117,0,228,225,4,1,120,58,7,255,221,193,84,254,112,133,27,0,189,200,201,255,139,135,150,0,234,55,176,255,61,50,65,0,152,108,169,255,220,85,1,255,112,135,227,0,162,26,186,0,207,96,185,254,244,136,107,0,93,153,50,1,198,97,151,0,110,11,86,255,143,117,174,255,115,212,200,0,5,202,183,0,237,164,10,254,185,239,62,0,236,120,18,254,98,123,99,255,168,201,194,254,46,234,214,0,191,133,49,255,99,169,119,0,190,187,35,1,115,21,45,255,249,131,72,0,112,6,123,255,214,49,181,254,166,233,34,0,92,197,102,254,253,228,205,255,3,59,201,1,42,98,46,0,219,37,35,255,169,195,38,0,94,124,193,1,156,43,223,0,95,72,133,254,120,206,191,0,122,197,239,255,177,187,79,255,254,46,2,1,250,167,190,0,84,129,19,0,203,113,166,255,249,31,189,254,72,157,202,255,208,71,73,255,207,24,72,0,10,16,18,1,210,81,76,255,88,208,192,255,126,243,107,255,238,141,120,255,199,121,234,255,137,12,59,255,36,220,123,255,148,179,60,254,240,12,29,0,66,0,97,1,36,30,38,255,115,1,93,255,96,103,231,255,197,158,59,1,192,164,240,0,202,202,57,255,24,174,48,0,89,77,155,1,42,76,215,0,244,151,233,0,23,48,81,0,239,127,52,254,227,130,37,255,248,116,93,1,124,132,118,0,173,254,192,1,6,235,83,255,110,175,231,1,251,28,182,0,129,249,93,254,84,184,128,0,76,181,62,0,175,128,186,0,100,53,136,254,109,29,226,0,221,233,58,1,20,99,74,0,0,22,160,0,134,13,21,0,9,52,55,255,17,89,140,0,175,34,59,0,84,165,119,255,224,226,234,255,7,72,166,255,123,115,255,1,18,214,246,0,250,7,71,1,217,220,185,0,212,35,76,255,38,125,175,0,189,97,210,0,114,238,44,255,41,188,169,254,45,186,154,0,81,92,22,0,132,160,193,0,121,208,98,255,13,81,44,255,203,156,82,0,71,58,21,255,208,114,191,254,50,38,147,0,154,216,195,0,101,25,18,0,60,250,215,255,233,132,235,255,103,175,142,1,16,14,92,0,141,31,110,254,238,241,45,255,153,217,239,1,97,168,47,255,249,85,16,1,28,175,62,255,57,254,54,0,222,231,126,0,166,45,117,254,18,189,96,255,228,76,50,0,200,244,94,0,198,152,120,1,68,34,69,255,12,65,160,254,101,19,90,0,167,197,120,255,68,54,185,255,41,218,188,0,113,168,48,0,88,105,189,1,26,82,32,255,185,93,164,1,228,240,237,255,66,182,53,0,171,197,92,255,107,9,233,1,199,120,144,255,78,49,10,255,109,170,105,255,90,4,31,255,28,244,113,255,74,58,11,0,62,220,246,255,121,154,200,254,144,210,178,255,126,57,129,1,43,250,14,255,101,111,28,1,47,86,241,255,61,70,150,255,53,73,5,255,30,26,158,0,209,26,86,0,138,237,74,0,164,95,188,0,142,60,29,254,162,116,248,255,187,175,160,0,151,18,16,0,209,111,65,254,203,134,39,255,88,108,49,255,131,26,71,255,221,27,215,254,104,105,93,255,31,236,31,254,135,0,211,255,143,127,110,1,212,73,229,0,233,67,167,254,195,1,208,255,132,17,221,255,51,217,90,0,67,235,50,255,223,210,143,0,179,53,130,1,233,106,198,0,217,173,220,255,112,229,24,255,175,154,93,254,71,203,246,255,48,66,133,255,3,136,230,255,23,221,113,254,235,111,213,0,170,120,95,254,251,221,2,0,45,130,158,254,105,94,217,255,242,52,180,254,213,68,45,255,104,38,28,0,244,158,76,0,161,200,96,255,207,53,13,255,187,67,148,0,170,54,248,0,119,162,178,255,83,20,11,0,42,42,192,1,146,159,163,255,183,232,111,0,77,229,21,255,71,53,143,0,27,76,34,0,246,136,47,255,219,39,182,255,92,224,201,1,19,142,14,255,69,182,241,255,163,118,245,0,9,109,106,1,170,181,247,255,78,47,238,255,84,210,176,255,213,107,139,0,39,38,11,0,72,21,150,0,72,130,69,0,205,77,155,254,142,133,21,0,71,111,172,254,226,42,59,255,179,0,215,1,33,128,241,0,234,252,13,1,184,79,8,0,110,30,73,255,246,141,189,0,170,207,218,1,74,154,69,255,138,246,49,255,155,32,100,0,125,74,105,255,90,85,61,255,35,229,177,255,62,125,193,255,153,86,188,1,73,120,212,0,209,123,246,254,135,209,38,255,151,58,44,1,92,69,214,255,14,12,88,255,252,153,166,255,253,207,112,255,60,78,83,255,227,124,110,0,180,96,252,255,53,117,33,254,164,220,82,255,41,1,27,255,38,164,166,255,164,99,169,254,61,144,70,255,192,166,18,0,107,250,66,0,197,65,50,0,1,179,18,255,255,104,1,255,43,153,35,255,80,111,168,0,110,175,168,0,41,105,45,255,219,14,205,255,164,233,140,254,43,1,118,0,233,67,195,0,178,82,159,255,138,87,122,255,212,238,90,255,144,35,124,254,25,140,164,0,251,215,44,254,133,70,107,255,101,227,80,254,92,169,55,0,215,42,49,0,114,180,85,255,33,232,27,1,172,213,25,0,62,176,123,254,32,133,24,255,225,191,62,0,93,70,153,0,181,42,104,1,22,191,224,255,200,200,140,255,249,234,37,0,149,57,141,0,195,56,208,255,254,130,70,255,32,173,240,255,29,220,199,0,110,100,115,255,132,229,249,0,228,233,223,255,37,216,209,254,178,177,209,255,183,45,165,254,224,97,114,0,137,97,168,255,225,222,172,0,165,13,49,1,210,235,204,255,252,4,28,254,70,160,151,0,232,190,52,254,83,248,93,255,62,215,77,1,175,175,179,255,160,50,66,0,121,48,208,0,63,169,209,255,0,210,200,0,224,187,44,1,73,162,82,0,9,176,143,255,19,76,193,255,29,59,167,1,24,43,154,0,28,190,190,0,141,188,129,0,232,235,203,255,234,0,109,255,54,65,159,0,60,88,232,255,121,253,150,254,252,233,131,255,198,110,41,1,83,77,71,255,200,22,59,254,106,253,242,255,21,12,207,255,237,66,189,0,90,198,202,1,225,172,127,0,53,22,202,0,56,230,132,0,1,86,183,0,109,190,42,0,243,68,174,1,109,228,154,0,200,177,122,1,35,160,183,255,177,48,85,255,90,218,169,255,248,152,78,0,202,254,110,0,6,52,43,0,142,98,65,255,63,145,22,0,70,106,93,0,232,138,107,1,110,179,61,255,211,129,218,1,242,209,92,0,35,90,217,1,182,143,106,255,116,101,217,255,114,250,221,255,173,204,6,0,60,150,163,0,73,172,44,255,239,110,80,255,237,76,153,254,161,140,249,0,149,232,229,0,133,31,40,255,174,164,119,0,113,51,214,0,129,228,2,254,64,34,243,0,107,227,244,255,174,106,200,255,84,153,70,1,50,35,16,0,250,74,216,254,236,189,66,255,153,249,13,0,230,178,4,255,221,41,238,0,118,227,121,255,94,87,140,254,254,119,92,0,73,239,246,254,117,87,128,0,19,211,145,255,177,46,252,0,229,91,246,1,69,128,247,255,202,77,54,1,8,11,9,255,153,96,166,0,217,214,173,255,134,192,2,1,0,207,0,0,189,174,107,1,140,134,100,0,158,193,243,1,182,102,171,0,235,154,51,0,142,5,123,255,60,168,89,1,217,14,92,255,19,214,5,1,211,167,254,0,44,6,202,254,120,18,236,255,15,113,184,255,184,223,139,0,40,177,119,254,182,123,90,255,176,165,176,0,247,77,194,0,27,234,120,0,231,0,214,255,59,39,30,0,125,99,145,255,150,68,68,1,141,222,248,0,153,123,210,255,110,127,152,255,229,33,214,1,135,221,197,0,137,97,2,0,12,143,204,255,81,41,188,0,115,79,130,255,94,3,132,0,152,175,187,255,124,141,10,255,126,192,179,255,11,103,198,0,149,6,45,0,219,85,187,1,230,18,178,255,72,182,152,0,3,198,184,255,128,112,224,1,97,161,230,0,254,99,38,255,58,159,197,0,151,66,219,0,59,69,143,255,185,112,249,0,119,136,47,255,123,130,132,0,168,71,95,255,113,176,40,1,232,185,173,0,207,93,117,1,68,157,108,255,102,5,147,254,49,97,33,0,89,65,111,254,247,30,163,255,124,217,221,1,102,250,216,0,198,174,75,254,57,55,18,0,227,5,236,1,229,213,173,0,201,109,218,1,49,233,239,0,30,55,158,1,25,178,106,0,155,111,188,1,94,126,140,0,215,31,238,1,77,240,16,0,213,242,25,1,38,71,168,0,205,186,93,254,49,211,140,255,219,0,180,255,134,118,165,0,160,147,134,255,110,186,35,255,198,243,42,0,243,146,119,0,134,235,163,1,4,241,135,255,193,46,193,254,103,180,79,255,225,4,184,254,242,118,130,0,146,135,176,1,234,111,30,0,69,66,213,254,41,96,123,0,121,94,42,255,178,191,195,255,46,130,42,0,117,84,8,255,233,49,214,254,238,122,109,0,6,71,89,1,236,211,123,0,244,13,48,254,119,148,14,0,114,28,86,255,75,237,25,255,145,229,16,254,129,100,53,255,134,150,120,254,168,157,50,0,23,72,104,255,224,49,14,0,255,123,22,255,151,185,151,255,170,80,184,1,134,182,20,0,41,100,101,1,153,33,16,0,76,154,111,1,86,206,234,255,192,160,164,254,165,123,93,255,1,216,164,254,67,17,175,255,169,11,59,255,158,41,61,255,73,188,14,255,195,6,137,255,22,147,29,255,20,103,3,255,246,130,227,255,122,40,128,0,226,47,24,254,35,36,32,0,152,186,183,255,69,202,20,0,195,133,195,0,222,51,247,0,169,171,94,1,183,0,160,255,64,205,18,1,156,83,15,255,197,58,249,254,251,89,110,255,50,10,88,254,51,43,216,0,98,242,198,1,245,151,113,0,171,236,194,1,197,31,199,255,229,81,38,1,41,59,20,0,253,104,230,0,152,93,14,255,246,242,146,254,214,169,240,255,240,102,108,254,160,167,236,0,154,218,188,0,150,233,202,255,27,19,250,1,2,71,133,255,175,12,63,1,145,183,198,0,104,120,115,255,130,251,247,0,17,212,167,255,62,123,132,255,247,100,189,0,155,223,152,0,143,197,33,0,155,59,44,255,150,93,240,1,127,3,87,255,95,71,207,1,167,85,1,255,188,152,116,255,10,23,23,0,137,195,93,1,54,98,97,0,240,0,168,255,148,188,127,0,134,107,151,0,76,253,171,0,90,132,192,0,146,22,54,0,224,66,54,254,230,186,229,255,39,182,196,0,148,251,130,255,65,131,108,254,128,1,160,0,169,49,167,254,199,254,148,255,251,6,131,0,187,254,129,255,85,82,62,0,178,23,58,255,254,132,5,0,164,213,39,0,134,252,146,254,37,53,81,255,155,134,82,0,205,167,238,255,94,45,180,255,132,40,161,0,254,111,112,1,54,75,217,0,179,230,221,1,235,94,191,255,23,243,48,1,202,145,203,255,39,118,42,255,117,141,253,0,254,0,222,0,43,251,50,0,54,169,234,1,80,68,208,0,148,203,243,254,145,7,135,0,6,254,0,0,252,185,127,0,98,8,129,255,38,35,72,255,211,36,220,1,40,26,89,0,168,64,197,254,3,222,239,255,2,83,215,254,180,159,105,0,58,115,194,0,186,116,106,255,229,247,219,255,129,118,193,0,202,174,183,1,166,161,72,0,201,107,147,254,237,136,74,0,233,230,106,1,105,111,168,0,64,224,30,1,1,229,3,0,102,151,175,255,194,238,228,255,254,250,212,0,187,237,121,0,67,251,96,1,197,30,11,0,183,95,204,0,205,89,138,0,64,221,37,1,255,223,30,255,178,48,211,255,241,200,90,255,167,209,96,255,57,130,221,0,46,114,200,255,61,184,66,0,55,182,24,254,110,182,33,0,171,190,232,255,114,94,31,0,18,221,8,0,47,231,254,0,255,112,83,0,118,15,215,255,173,25,40,254,192,193,31,255,238,21,146,255,171,193,118,255,101,234,53,254,131,212,112,0,89,192,107,1,8,208,27,0,181,217,15,255,231,149,232,0,140,236,126,0,144,9,199,255,12,79,181,254,147,182,202,255,19,109,182,255,49,212,225,0,74,163,203,0,175,233,148,0,26,112,51,0,193,193,9,255,15,135,249,0,150,227,130,0,204,0,219,1,24,242,205,0,238,208,117,255,22,244,112,0,26,229,34,0,37,80,188,255,38,45,206,254,240,90,225,255,29,3,47,255,42,224,76,0,186,243,167,0,32,132,15,255,5,51,125,0,139,135,24,0,6,241,219,0,172,229,133,255,246,214,50,0,231,11,207,255,191,126,83,1,180,163,170,255,245,56,24,1,178,164,211,255,3,16,202,1,98,57,118,255,141,131,89,254,33,51,24,0,243,149,91,255,253,52,14,0,35,169,67,254,49,30,88,255,179,27,36,255,165,140,183,0,58,189,151,0,88,31,0,0,75,169,66,0,66,101,199,255,24,216,199,1,121,196,26,255,14,79,203,254,240,226,81,255,94,28,10,255,83,193,240,255,204,193,131,255,94,15,86,0,218,40,157,0,51,193,209,0,0,242,177,0,102,185,247,0,158,109,116,0,38,135,91,0,223,175,149,0,220,66,1,255,86,60,232,0,25,96,37,255,225,122,162,1,215,187,168,255,158,157,46,0,56,171,162,0,232,240,101,1,122,22,9,0,51,9,21,255,53,25,238,255,217,30,232,254,125,169,148,0,13,232,102,0,148,9,37,0,165,97,141,1,228,131,41,0,222,15,243,255,254,18,17,0,6,60,237,1,106,3,113,0,59,132,189,0,92,112,30,0,105,208,213,0,48,84,179,255,187,121,231,254,27,216,109,255,162,221,107,254,73,239,195,255,250,31,57,255,149,135,89,255,185,23,115,1,3,163,157,255,18,112,250,0,25,57,187,255,161,96,164,0,47,16,243,0,12,141,251,254,67,234,184,255,41,18,161,0,175,6,96,255,160,172,52,254,24,176,183,255,198,193,85,1,124,121,137,255,151,50,114,255,220,203,60,255,207,239,5,1,0,38,107,255,55,238,94,254,70,152,94,0,213,220,77,1,120,17,69,255,85,164,190,255,203,234,81,0,38,49,37,254,61,144,124,0,137,78,49,254,168,247,48,0,95,164,252,0,105,169,135,0,253,228,134,0,64,166,75,0,81,73,20,255,207,210,10,0,234,106,150,255,94,34,90,255,254,159,57,254,220,133,99,0,139,147,180,254,24,23,185,0,41,57,30,255,189,97,76,0,65,187,223,255,224,172,37,255,34,62,95,1,231,144,240,0,77,106,126,254,64,152,91,0,29,98,155,0,226,251,53,255,234,211,5,255,144,203,222,255,164,176,221,254,5,231,24,0,179,122,205,0,36,1,134,255,125,70,151,254,97,228,252,0,172,129,23,254,48,90,209,255,150,224,82,1,84,134,30,0,241,196,46,0,103,113,234,255,46,101,121,254,40,124,250,255,135,45,242,254,9,249,168,255,140,108,131,255,143,163,171,0,50,173,199,255,88,222,142,255,200,95,158,0,142,192,163,255,7,117,135,0,111,124,22,0,236,12,65,254,68,38,65,255,227,174,254,0,244,245,38,0,240,50,208,255,161,63,250,0,60,209,239,0,122,35,19,0,14,33,230,254,2,159,113,0,106,20,127,255,228,205,96,0,137,210,174,254,180,212,144,255,89,98,154,1,34,88,139,0,167,162,112,1,65,110,197,0,241,37,169,0,66,56,131,255,10,201,83,254,133,253,187,255,177,112,45,254,196,251,0,0,196,250,151,255,238,232,214,255,150,209,205,0,28,240,118,0,71,76,83,1,236,99,91,0,42,250,131,1,96,18,64,255,118,222,35,0,113,214,203,255,122,119,184,255,66,19,36,0,204,64,249,0,146,89,139,0,134,62,135,1,104,233,101,0,188,84,26,0,49,249,129,0,208,214,75,255,207,130,77,255,115,175,235,0,171,2,137,255,175,145,186,1,55,245,135,255,154,86,181,1,100,58,246,255,109,199,60,255,82,204,134,255,215,49,230,1,140,229,192,255,222,193,251,255,81,136,15,255,179,149,162,255,23,39,29,255,7,95,75,254,191,81,222,0,241,81,90,255,107,49,201,255,244,211,157,0,222,140,149,255,65,219,56,254,189,246,90,255,178,59,157,1,48,219,52,0,98,34,215,0,28,17,187,255,175,169,24,0,92,79,161,255,236,200,194,1,147,143,234,0,229,225,7,1,197,168,14,0,235,51,53,1,253,120,174,0,197,6,168,255,202,117,171,0,163,21,206,0,114,85,90,255,15,41,10,255,194,19,99,0,65,55,216,254,162,146,116,0,50,206,212,255,64,146,29,255,158,158,131,1,100,165,130,255,172,23,129,255,125,53,9,255,15,193,18,1,26,49,11,255,181,174,201,1,135,201,14,255,100,19,149,0,219,98,79,0,42,99,143,254,96,0,48,255,197,249,83,254,104,149,79,255,235,110,136,254,82,128,44,255,65,41,36,254,88,211,10,0,187,121,187,0,98,134,199,0,171,188,179,254,210,11,238,255,66,123,130,254,52,234,61,0,48,113,23,254,6,86,120,255,119,178,245,0,87,129,201,0,242,141,209,0,202,114,85,0,148,22,161,0,103,195,48,0,25,49,171,255,138,67,130,0,182,73,122,254,148,24,130,0,211,229,154,0,32,155,158,0,84,105,61,0,177,194,9,255,166,89,86,1,54,83,187,0,249,40,117,255,109,3,215,255,53,146,44,1,63,47,179,0,194,216,3,254,14,84,136,0,136,177,13,255,72,243,186,255,117,17,125,255,211,58,211,255,93,79,223,0,90,88,245,255,139,209,111,255,70,222,47,0,10,246,79,255,198,217,178,0,227,225,11,1,78,126,179,255,62,43,126,0,103,148,35,0,129,8,165,254,245,240,148,0,61,51,142,0,81,208,134,0,15,137,115,255,211,119,236,255,159,245,248,255,2,134,136,255,230,139,58,1,160,164,254,0,114,85,141,255,49,166,182,255,144,70,84,1,85,182,7,0,46,53,93,0,9,166,161,255,55,162,178,255,45,184,188,0,146,28,44,254,169,90,49,0,120,178,241,1,14,123,127,255,7,241,199,1,189,66,50,255,198,143,101,254,189,243,135,255,141,24,24,254,75,97,87,0,118,251,154,1,237,54,156,0,171,146,207,255,131,196,246,255,136,64,113,1,151,232,57,0,240,218,115,0,49,61,27,255,64,129,73,1,252,169,27,255,40,132,10,1,90,201,193,255,252,121,240,1,186,206,41,0,43,198,97,0,145,100,183,0,204,216,80,254,172,150,65,0,249,229,196,254,104,123,73,255,77,104,96,254,130,180,8,0,104,123,57,0,220,202,229,255,102,249,211,0,86,14,232,255,182,78,209,0,239,225,164,0,106,13,32,255,120,73,17,255,134,67,233,0,83,254,181,0,183,236,112,1,48,64,131,255,241,216,243,255,65,193,226,0,206,241,100,254,100,134,166,255,237,202,197,0,55,13,81,0,32,124,102,255,40,228,177,0,118,181,31,1,231,160,134,255,119,187,202,0,0,142,60,255,128,38,189,255,166,201,150,0,207,120,26,1,54,184,172,0,12,242,204,254,133,66,230,0,34,38,31,1,184,112,80,0,32,51,165,254,191,243,55,0,58,73,146,254,155,167,205,255,100,104,152,255,197,254,207,255,173,19,247,0,238,10,202,0,239,151,242,0,94,59,39,255,240,29,102,255,10,92,154,255,229,84,219,255,161,129,80,0,208,90,204,1,240,219,174,255,158,102,145,1,53,178,76,255,52,108,168,1,83,222,107,0,211,36,109,0,118,58,56,0,8,29,22,0,237,160,199,0,170,209,157,0,137,71,47,0,143,86,32,0,198,242,2,0,212,48,136,1,92,172,186,0,230,151,105,1,96,191,229,0,138,80,191,254,240,216,130,255,98,43,6,254,168,196,49,0,253,18,91,1,144,73,121,0,61,146,39,1,63,104,24,255,184,165,112,254,126,235,98,0,80,213,98,255,123,60,87,255,82,140,245,1,223,120,173,255,15,198,134,1,206,60,239,0,231,234,92,255,33,238,19,255,165,113,142,1,176,119,38,0,160,43,166,254,239,91,105,0,107,61,194,1,25,4,68,0,15,139,51,0,164,132,106,255,34,116,46,254,168,95,197,0,137,212,23,0,72,156,58,0,137,112,69,254,150,105,154,255,236,201,157,0,23,212,154,255,136,82,227,254,226,59,221,255,95,149,192,0,81,118,52,255,33,43,215,1,14,147,75,255,89,156,121,254,14,18,79,0,147,208,139,1,151,218,62,255,156,88,8,1,210,184,98,255,20,175,123,255,102,83,229,0,220,65,116,1,150,250,4,255,92,142,220,255,34,247,66,255,204,225,179,254,151,81,151,0,71,40,236,255,138,63,62,0,6,79,240,255,183,185,181,0,118,50,27,0,63,227,192,0,123,99,58,1,50,224,155,255,17,225,223,254,220,224,77,255,14,44,123,1,141,128,175,0,248,212,200,0,150,59,183,255,147,97,29,0,150,204,181,0,253,37,71,0,145,85,119,0,154,200,186,0,2,128,249,255,83,24,124,0,14,87,143,0,168,51,245,1,124,151,231,255,208,240,197,1,124,190,185,0,48,58,246,0,20,233,232,0,125,18,98,255,13,254,31,255,245,177,130,255,108,142,35,0,171,125,242,254,140,12,34,255,165,161,162,0,206,205,101,0,247,25,34,1,100,145,57,0,39,70,57,0,118,204,203,255,242,0,162,0,165,244,30,0,198,116,226,0,128,111,153,255,140,54,182,1,60,122,15,255,155,58,57,1,54,50,198,0,171,211,29,255,107,138,167,255,173,107,199,255,109,161,193,0,89,72,242,255,206,115,89,255,250,254,142,254,177,202,94,255,81,89,50,0,7,105,66,255,25,254,255,254,203,64,23,255,79,222,108,255,39,249,75,0,241,124,50,0,239,152,133,0,221,241,105,0,147,151,98,0,213,161,121,254,242,49,137,0,233,37,249,254,42,183,27,0,184,119,230,255,217,32,163,255,208,251,228,1,137,62,131,255,79,64,9,254,94,48,113,0,17,138,50,254,193,255,22,0,247,18,197,1,67,55,104,0,16,205,95,255,48,37,66,0,55,156,63,1,64,82,74,255,200,53,71,254,239,67,125,0,26,224,222,0,223,137,93,255,30,224,202,255,9,220,132,0,198,38,235,1,102,141,86,0,60,43,81,1,136,28,26,0,233,36,8,254,207,242,148,0,164,162,63,0,51,46,224,255,114,48,79,255,9,175,226,0,222,3,193,255,47,160,232,255,255,93,105,254,14,42,230,0,26,138,82,1,208,43,244,0,27,39,38,255,98,208,127,255,64,149,182,255,5,250,209,0,187,60,28,254,49,25,218,255,169,116,205,255,119,18,120,0,156,116,147,255,132,53,109,255,13,10,202,0,110,83,167,0,157,219,137,255,6,3,130,255,50,167,30,255,60,159,47,255,129,128,157,254,94,3,189,0,3,166,68,0,83,223,215,0,150,90,194,1,15,168,65,0,227,83,51,255,205,171,66,255,54,187,60,1,152,102,45,255,119,154,225,0,240,247,136,0,100,197,178,255,139,71,223,255,204,82,16,1,41,206,42,255,156,192,221,255,216,123,244,255,218,218,185,255,187,186,239,255,252,172,160,255,195,52,22,0,144,174,181,254,187,100,115,255,211,78,176,255,27,7,193,0,147,213,104,255,90,201,10,255,80,123,66,1,22,33,186,0,1,7,99,254,30,206,10,0,229,234,5,0,53,30,210,0,138,8,220,254,71,55,167,0,72,225,86,1,118,190,188,0,254,193,101,1,171,249,172,255,94,158,183,254,93,2,108,255,176,93,76,255,73,99,79,255,74,64,129,254,246,46,65,0,99,241,127,254,246,151,102,255,44,53,208,254,59,102,234,0,154,175,164,255,88,242,32,0,111,38,1,0,255,182,190,255,115,176,15,254,169,60,129,0,122,237,241,0,90,76,63,0,62,74,120,255,122,195,110,0,119,4,178,0,222,242,210,0,130,33,46,254,156,40,41,0,167,146,112,1,49,163,111,255,121,176,235,0,76,207,14,255,3,25,198,1,41,235,213,0,85,36,214,1,49,92,109,255,200,24,30,254,168,236,195,0,145,39,124,1,236,195,149,0,90,36,184,255,67,85,170,255,38,35,26,254,131,124,68,255,239,155,35,255,54,201,164,0,196,22,117,255,49,15,205,0,24,224,29,1,126,113,144,0,117,21,182,0,203,159,141,0,223,135,77,0,176,230,176,255,190,229,215,255,99,37,181,255,51,21,138,255,25,189,89,255,49,48,165,254,152,45,247,0,170,108,222,0,80,202,5,0,27,69,103,254,204,22,129,255,180,252,62,254,210,1,91,255,146,110,254,255,219,162,28,0,223,252,213,1,59,8,33,0,206,16,244,0,129,211,48,0,107,160,208,0,112,59,209,0,109,77,216,254,34,21,185,255,246,99,56,255,179,139,19,255,185,29,50,255,84,89,19,0,74,250,98,255,225,42,200,255,192,217,205,255,210,16,167,0,99,132,95,1,43,230,57,0,254,11,203,255,99,188,63,255,119,193,251,254,80,105,54,0,232,181,189,1,183,69,112,255,208,171,165,255,47,109,180,255,123,83,165,0,146,162,52,255,154,11,4,255,151,227,90,255,146,137,97,254,61,233,41,255,94,42,55,255,108,164,236,0,152,68,254,0,10,140,131,255,10,106,79,254,243,158,137,0,67,178,66,254,177,123,198,255,15,62,34,0,197,88,42,255,149,95,177,255,152,0,198,255,149,254,113,255,225,90,163,255,125,217,247,0,18,17,224,0,128,66,120,254,192,25,9,255,50,221,205,0,49,212,70,0,233,255,164,0,2,209,9,0,221,52,219,254,172,224,244,255,94,56,206,1,242,179,2,255,31,91,164,1,230,46,138,255,189,230,220,0,57,47,61,255,111,11,157,0,177,91,152,0,28,230,98,0,97,87,126,0,198,89,145,255,167,79,107,0,249,77,160,1,29,233,230,255,150,21,86,254,60,11,193,0,151,37,36,254,185,150,243,255,228,212,83,1,172,151,180,0,201,169,155,0,244,60,234,0,142,235,4,1,67,218,60,0,192,113,75,1,116,243,207,255,65,172,155,0,81,30,156,255,80,72,33,254,18,231,109,255,142,107,21,254,125,26,132,255,176,16,59,255,150,201,58,0,206,169,201,0,208,121,226,0,40,172,14,255,150,61,94,255,56,57,156,255,141,60,145,255,45,108,149,255,238,145,155,255,209,85,31,254,192,12,210,0,99,98,93,254,152,16,151,0,225,185,220,0,141,235,44,255,160,172,21,254,71,26,31,255,13,64,93,254,28,56,198,0,177,62,248,1,182,8,241,0,166,101,148,255,78,81,133,255,129,222,215,1,188,169,129,255,232,7,97,0,49,112,60,255,217,229,251,0,119,108,138,0,39,19,123,254,131,49,235,0,132,84,145,0,130,230,148,255,25,74,187,0,5,245,54,255,185,219,241,1,18,194,228,255,241,202,102,0,105,113,202,0,155,235,79,0,21,9,178,255,156,1,239,0,200,148,61,0,115,247,210,255,49,221,135,0,58,189,8,1,35,46,9,0,81,65,5,255,52,158,185,255,125,116,46,255,74,140,13,255,210,92,172,254,147,23,71,0,217,224,253,254,115,108,180,255,145,58,48,254,219,177,24,255,156,255,60,1,154,147,242,0,253,134,87,0,53,75,229,0,48,195,222,255,31,175,50,255,156,210,120,255,208,35,222,255,18,248,179,1,2,10,101,255,157,194,248,255,158,204,101,255,104,254,197,255,79,62,4,0,178,172,101,1,96,146,251,255,65,10,156,0,2,137,165,255,116,4,231,0,242,215,1,0,19,35,29,255,43,161,79,0,59,149,246,1,251,66,176,0,200,33,3,255,80,110,142,255,195,161,17,1,228,56,66,255,123,47,145,254,132,4,164,0,67,174,172,0,25,253,114,0,87,97,87,1,250,220,84,0,96,91,200,255,37,125,59,0,19,65,118,0,161,52,241,255,237,172,6,255,176,191,255,255,1,65,130,254,223,190,230,0,101,253,231,255,146,35,109,0,250,29,77,1,49,0,19,0,123,90,155,1,22,86,32,255,218,213,65,0,111,93,127,0,60,93,169,255,8,127,182,0,17,186,14,254,253,137,246,255,213,25,48,254,76,238,0,255,248,92,70,255,99,224,139,0,184,9,255,1,7,164,208,0,205,131,198,1,87,214,199,0,130,214,95,0,221,149,222,0,23,38,171,254,197,110,213,0,43,115,140,254,215,177,118,0,96,52,66,1,117,158,237,0,14,64,182,255,46,63,174,255,158,95,190,255,225,205,177,255,43,5,142,255,172,99,212,255,244,187,147,0,29,51,153,255,228,116,24,254,30,101,207,0,19,246,150,255,134,231,5,0,125,134,226,1,77,65,98,0,236,130,33,255,5,110,62,0,69,108,127,255,7,113,22,0,145,20,83,254,194,161,231,255,131,181,60,0,217,209,177,255,229,148,212,254,3,131,184,0,117,177,187,1,28,14,31,255,176,102,80,0,50,84,151,255,125,31,54,255,21,157,133,255,19,179,139,1,224,232,26,0,34,117,170,255,167,252,171,255,73,141,206,254,129,250,35,0,72,79,236,1,220,229,20,255,41,202,173,255,99,76,238,255,198,22,224,255,108,198,195,255,36,141,96,1,236,158,59,255,106,100,87,0,110,226,2,0,227,234,222,0,154,93,119,255,74,112,164,255,67,91,2,255,21,145,33,255,102,214,137,255,175,230,103,254,163,246,166,0,93,247,116,254,167,224,28,255,220,2,57,1,171,206,84,0,123,228,17,255,27,120,119,0,119,11,147,1,180,47,225,255,104,200,185,254,165,2,114,0,77,78,212,0,45,154,177,255,24,196,121,254,82,157,182,0,90,16,190,1,12,147,197,0,95,239,152,255,11,235,71,0,86,146,119,255,172,134,214,0,60,131,196,0,161,225,129,0,31,130,120,254,95,200,51,0,105,231,210,255,58,9,148,255,43,168,221,255,124,237,142,0,198,211,50,254,46,245,103,0,164,248,84,0,152,70,208,255,180,117,177,0,70,79,185,0,243,74,32,0,149,156,207,0,197,196,161,1,245,53,239,0,15,93,246,254,139,240,49,255,196,88,36,255,162,38,123,0,128,200,157,1,174,76,103,255,173,169,34,254,216,1,171,255,114,51,17,0,136,228,194,0,110,150,56,254,106,246,159,0,19,184,79,255,150,77,240,255,155,80,162,0,0,53,169,255,29,151,86,0,68,94,16,0,92,7,110,254,98,117,149,255,249,77,230,255,253,10,140,0,214,124,92,254,35,118,235,0,89,48,57,1,22,53,166,0,184,144,61,255,179,255,194,0,214,248,61,254,59,110,246,0,121,21,81,254,166,3,228,0,106,64,26,255,69,232,134,255,242,220,53,254,46,220,85,0,113,149,247,255,97,179,103,255,190,127,11,0,135,209,182,0,95,52,129,1,170,144,206,255,122,200,204,255,168,100,146,0,60,144,149,254,70,60,40,0,122,52,177,255,246,211,101,255,174,237,8,0,7,51,120,0,19,31,173,0,126,239,156,255,143,189,203,0,196,128,88,255,233,133,226,255,30,125,173,255,201,108,50,0,123,100,59,255,254,163,3,1,221,148,181,255,214,136,57,254,222,180,137,255,207,88,54,255,28,33,251,255,67,214,52,1,210,208,100,0,81,170,94,0,145,40,53,0,224,111,231,254,35,28,244,255,226,199,195,254,238,17,230,0,217,217,164,254,169,157,221,0,218,46,162,1,199,207,163,255,108,115,162,1,14,96,187,255,118,60,76,0,184,159,152,0,209,231,71,254,42,164,186,255,186,153,51,254,221,171,182,255,162,142,173,0,235,47,193,0,7,139,16,1,95,164,64,255,16,221,166,0,219,197,16,0,132,29,44,255,100,69,117,255,60,235,88,254,40,81,173,0,71,190,61,255,187,88,157,0,231,11,23,0,237,117,164,0,225,168,223,255,154,114,116,255,163,152,242,1,24,32,170,0,125,98,113,254,168,19,76,0,17,157,220,254,155,52,5,0,19,111,161,255,71,90,252,255,173,110,240,0,10,198,121,255,253,255,240,255,66,123,210,0,221,194,215,254,121,163,17,255,225,7,99,0,190,49,182,0,115,9,133,1,232,26,138,255,213,68,132,0,44,119,122,255,179,98,51,0,149,90,106,0,71,50,230,255,10,153,118,255,177,70,25,0,165,87,205,0,55,138,234,0,238,30,97,0,113,155,207,0,98,153,127,0,34,107,219,254,117,114,172,255,76,180,255,254,242,57,179,255,221,34,172,254,56,162,49,255,83,3,255,255,113,221,189,255,188,25,228,254,16,88,89,255,71,28,198,254,22,17,149,255,243,121,254,255,107,202,99,255,9,206,14,1,220,47,153,0,107,137,39,1,97,49,194,255,149,51,197,254,186,58,11,255,107,43,232,1,200,6,14,255,181,133,65,254,221,228,171,255,123,62,231,1,227,234,179,255,34,189,212,254,244,187,249,0,190,13,80,1,130,89,1,0,223,133,173,0,9,222,198,255,66,127,74,0,167,216,93,255,155,168,198,1,66,145,0,0,68,102,46,1,172,90,154,0,216,128,75,255,160,40,51,0,158,17,27,1,124,240,49,0,236,202,176,255,151,124,192,255,38,193,190,0,95,182,61,0,163,147,124,255,255,165,51,255,28,40,17,254,215,96,78,0,86,145,218,254,31,36,202,255,86,9,5,0,111,41,200,255,237,108,97,0,57,62,44,0,117,184,15,1,45,241,116,0,152,1,220,255,157,165,188,0,250,15,131,1,60,44,125,255,65,220,251,255,75,50,184,0,53,90,128,255,231,80,194,255,136,129,127,1,21,18,187,255,45,58,161,255,71,147,34,0,174,249,11,254,35,141,29,0,239,68,177,255,115,110,58,0,238,190,177,1,87,245,166,255,190,49,247,255,146,83,184,255,173,14,39,255,146,215,104,0,142,223,120,0,149,200,155,255,212,207,145,1,16,181,217,0,173,32,87,255,255,35,181,0,119,223,161,1,200,223,94,255,70,6,186,255,192,67,85,255,50,169,152,0,144,26,123,255,56,243,179,254,20,68,136,0,39,140,188,254,253,208,5,255,200,115,135,1,43,172,229,255,156,104,187,0,151,251,167,0,52,135,23,0,151,153,72,0,147,197,107,254,148,158,5,255,238,143,206,0,126,153,137,255,88,152,197,254,7,68,167,0,252,159,165,255,239,78,54,255,24,63,55,255,38,222,94,0,237,183,12,255,206,204,210,0,19,39,246,254,30,74,231,0,135,108,29,1,179,115,0,0,117,118,116,1,132,6,252,255,145,129,161,1,105,67,141,0,82,37,226,255,238,226,228,255,204,214,129,254,162,123,100,255,185,121,234,0,45,108,231,0,66,8,56,255,132,136,128,0,172,224,66,254,175,157,188,0,230,223,226,254,242,219,69,0,184,14,119,1,82,162,56,0,114,123,20,0,162,103,85,255,49,239,99,254,156,135,215,0,111,255,167,254,39,196,214,0,144,38,79,1,249,168,125,0,155,97,156,255,23,52,219,255,150,22,144,0,44,149,165,255,40,127,183,0,196,77,233,255,118,129,210,255,170,135,230,255,214,119,198,0,233,240,35,0,253,52,7,255,117,102,48,255,21,204,154,255,179,136,177,255,23,2,3,1,149,130,89,255,252,17,159,1,70,60,26,0,144,107,17,0,180,190,60,255,56,182,59,255,110,71,54,255,198,18,129,255,149,224,87,255,223,21,152,255,138,22,182,255,250,156,205,0,236,45,208,255,79,148,242,1,101,70,209,0,103,78,174,0,101,144,172,255,152,136,237,1,191,194,136,0,113,80,125,1,152,4,141,0,155,150,53,255,196,116,245,0,239,114,73,254,19,82,17,255,124,125,234,255,40,52,191,0,42,210,158,255,155,132,165,0,178,5,42,1,64,92,40,255,36,85,77,255,178,228,118,0,137,66,96,254,115,226,66,0,110,240,69,254,151,111,80,0,167,174,236,255,227,108,107,255,188,242,65,255,183,81,255,0,57,206,181,255,47,34,181,255,213,240,158,1,71,75,95,0,156,40,24,255,102,210,81,0,171,199,228,255,154,34,41,0,227,175,75,0,21,239,195,0,138,229,95,1,76,192,49,0,117,123,87,1,227,225,130,0,125,62,63,255,2,198,171,0,254,36,13,254,145,186,206,0,148,255,244,255,35,0,166,0,30,150,219,1,92,228,212,0,92,198,60,254,62,133,200,255,201,41,59,0,125,238,109,255,180,163,238,1,140,122,82,0,9,22,88,255,197,157,47,255,153,94,57,0,88,30,182,0,84,161,85,0,178,146,124,0,166,166,7,255,21,208,223,0,156,182,242,0,155,121,185,0,83,156,174,254,154,16,118,255,186,83,232,1,223,58,121,255,29,23,88,0,35,125,127,255,170,5,149,254,164,12,130,255,155,196,29,0,161,96,136,0,7,35,29,1,162,37,251,0,3,46,242,255,0,217,188,0,57,174,226,1,206,233,2,0,57,187,136,254,123,189,9,255,201,117,127,255,186,36,204,0,231,25,216,0,80,78,105,0,19,134,129,255,148,203,68,0,141,81,125,254,248,165,200,255,214,144,135,0,151,55,166,255,38,235,91,0,21,46,154,0,223,254,150,255,35,153,180,255,125,176,29,1,43,98,30,255,216,122,230,255,233,160,12,0,57,185,12,254,240,113,7,255,5,9,16,254,26,91,108,0,109,198,203,0,8,147,40,0,129,134,228,255,124,186,40,255,114,98,132,254,166,132,23,0,99,69,44,0,9,242,238,255,184,53,59,0,132,129,102,255,52,32,243,254,147,223,200,255,123,83,179,254,135,144,201,255,141,37,56,1,151,60,227,255,90,73,156,1,203,172,187,0,80,151,47,255,94,137,231,255,36,191,59,255,225,209,181,255,74,215,213,254,6,118,179,255,153,54,193,1,50,0,231,0,104,157,72,1,140,227,154,255,182,226,16,254,96,225,92,255,115,20,170,254,6,250,78,0,248,75,173,255,53,89,6,255,0,180,118,0,72,173,1,0,64,8,206,1,174,133,223,0,185,62,133,255,214,11,98,0,197,31,208,0,171,167,244,255,22,231,181,1,150,218,185,0,247,169,97,1,165,139,247,255,47,120,149,1,103,248,51,0,60,69,28,254,25,179,196,0,124,7,218,254,58,107,81,0,184,233,156,255,252,74,36,0,118,188,67,0,141,95,53,255,222,94,165,254,46,61,53,0,206,59,115,255,47,236,250,255,74,5,32,1,129,154,238,255,106,32,226,0,121,187,61,255,3,166,241,254,67,170,172,255,29,216,178,255,23,201,252,0,253,110,243,0,200,125,57,0,109,192,96,255,52,115,238,0,38,121,243,255,201,56,33,0,194,118,130,0,75,96,25,255,170,30,230,254,39,63,253,0,36,45,250,255,251,1,239,0,160,212,92,1,45,209,237,0,243,33,87,254,237,84,201,255,212,18,157,254,212,99,127,255,217,98,16,254,139,172,239,0,168,201,130,255,143,193,169,255,238,151,193,1,215,104,41,0,239,61,165,254,2,3,242,0,22,203,177,254,177,204,22,0,149,129,213,254,31,11,41,255,0,159,121,254,160,25,114,255,162,80,200,0,157,151,11,0,154,134,78,1,216,54,252,0,48,103,133,0,105,220,197,0,253,168,77,254,53,179,23,0,24,121,240,1,255,46,96,255,107,60,135,254,98,205,249,255,63,249,119,255,120,59,211,255,114,180,55,254,91,85,237,0,149,212,77,1,56,73,49,0,86,198,150,0,93,209,160,0,69,205,182,255,244,90,43,0,20,36,176,0,122,116,221,0,51,167,39,1,231,1,63,255,13,197,134,0,3,209,34,255,135,59,202,0,167,100,78,0,47,223,76,0,185,60,62,0,178,166,123,1,132,12,161,255,61,174,43,0,195,69,144,0,127,47,191,1,34,44,78,0,57,234,52,1,255,22,40,255,246,94,146,0,83,228,128,0,60,78,224,255,0,96,210,255,153,175,236,0,159,21,73,0,180,115,196,254,131,225,106,0,255,167,134,0,159,8,112,255,120,68,194,255,176,196,198,255,118,48,168,255,93,169,1,0,112,200,102,1,74,24,254,0,19,141,4,254,142,62,63,0,131,179,187,255,77,156,155,255,119,86,164,0,170,208,146,255,208,133,154,255,148,155,58,255,162,120,232,254,252,213,155,0,241,13,42,0,94,50,131,0,179,170,112,0,140,83,151,255,55,119,84,1,140,35,239,255,153,45,67,1,236,175,39,0,54,151,103,255,158,42,65,255,196,239,135,254,86,53,203,0,149,97,47,254,216,35,17,255,70,3,70,1,103,36,90,255,40,26,173,0,184,48,13,0,163,219,217,255,81,6,1,255,221,170,108,254,233,208,93,0,100,201,249,254,86,36,35,255,209,154,30,1,227,201,251,255,2,189,167,254,100,57,3,0,13,128,41,0,197,100,75,0,150,204,235,255,145,174,59,0,120,248,149,255,85,55,225,0,114,210,53,254,199,204,119,0,14,247,74,1,63,251,129,0,67,104,151,1,135,130,80,0,79,89,55,255,117,230,157,255,25,96,143,0,213,145,5,0,69,241,120,1,149,243,95,255,114,42,20,0,131,72,2,0,154,53,20,255,73,62,109,0,196,102,152,0,41,12,204,255,122,38,11,1,250,10,145,0,207,125,148,0,246,244,222,255,41,32,85,1,112,213,126,0,162,249,86,1,71,198,127,255,81,9,21,1,98,39,4,255,204,71,45,1,75,111,137,0,234,59,231,0,32,48,95,255,204,31,114,1,29,196,181,255,51,241,167,254,93,109,142,0,104,144,45,0,235,12,181,255,52,112,164,0,76,254,202,255,174,14,162,0,61,235,147,255,43,64,185,254,233,125,217,0,243,88,167,254,74,49,8,0,156,204,66,0,124,214,123,0,38,221,118,1,146,112,236,0,114,98,177,0,151,89,199,0,87,197,112,0,185,149,161,0,44,96,165,0,248,179,20,255,188,219,216,254,40,62,13,0,243,142,141,0,229,227,206,255,172,202,35,255,117,176,225,255,82,110,38,1,42,245,14,255,20,83,97,0,49,171,10,0,242,119,120,0,25,232,61,0,212,240,147,255,4,115,56,255,145,17,239,254,202,17,251,255,249,18,245,255,99,117,239,0,184,4,179,255,246,237,51,255,37,239,137,255,166,112,166,255,81,188,33,255,185,250,142,255,54,187,173,0,208,112,201,0,246,43,228,1,104,184,88,255,212,52,196,255,51,117,108,255,254,117,155,0,46,91,15,255,87,14,144,255,87,227,204,0,83,26,83,1,159,76,227,0,159,27,213,1,24,151,108,0,117,144,179,254,137,209,82,0,38,159,10,0,115,133,201,0,223,182,156,1,110,196,93,255,57,60,233,0,5,167,105,255,154,197,164,0,96,34,186,255,147,133,37,1,220,99,190,0,1,167,84,255,20,145,171,0,194,197,251,254,95,78,133,255,252,248,243,255,225,93,131,255,187,134,196,255,216,153,170,0,20,118,158,254,140,1,118,0,86,158,15,1,45,211,41,255,147,1,100,254,113,116,76,255,211,127,108,1,103,15,48,0,193,16,102,1,69,51,95,255,107,128,157,0,137,171,233,0,90,124,144,1,106,161,182,0,175,76,236,1,200,141,172,255,163,58,104,0,233,180,52,255,240,253,14,255,162,113,254,255,38,239,138,254,52,46,166,0,241,101,33,254,131,186,156,0,111,208,62,255,124,94,160,255,31,172,254,0,112,174,56,255,188,99,27,255,67,138,251,0,125,58,128,1,156,152,174,255,178,12,247,255,252,84,158,0,82,197,14,254,172,200,83,255,37,39,46,1,106,207,167,0,24,189,34,0,131,178,144,0,206,213,4,0,161,226,210,0,72,51,105,255,97,45,187,255,78,184,223,255,176,29,251,0,79,160,86,255,116,37,178,0,82,77,213,1,82,84,141,255,226,101,212,1,175,88,199,255,245,94,247,1,172,118,109,255,166,185,190,0,131,181,120,0,87,254,93,255,134,240,73,255,32,245,143,255,139,162,103,255,179,98,18,254,217,204,112,0,147,223,120,255,53,10,243,0,166,140,150,0,125,80,200,255,14,109,219,255,91,218,1,255,252,252,47,254,109,156,116,255,115,49,127,1,204,87,211,255,148,202,217,255,26,85,249,255,14,245,134,1,76,89,169,255,242,45,230,0,59,98,172,255,114,73,132,254,78,155,49,255,158,126,84,0,49,175,43,255,16,182,84,255,157,103,35,0,104,193,109,255,67,221,154],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+10240);allocate([201,172,1,254,8,162,88,0,165,1,29,255,125,155,229,255,30,154,220,1,103,239,92,0,220,1,109,255,202,198,1,0,94,2,142,1,36,54,44,0,235,226,158,255,170,251,214,255,185,77,9,0,97,74,242,0,219,163,149,255,240,35,118,255,223,114,88,254,192,199,3,0,106,37,24,255,201,161,118,255,97,89,99,1,224,58,103,255,101,199,147,254,222,60,99,0,234,25,59,1,52,135,27,0,102,3,91,254,168,216,235,0,229,232,136,0,104,60,129,0,46,168,238,0,39,191,67,0,75,163,47,0,143,97,98,255,56,216,168,1,168,233,252,255,35,111,22,255,92,84,43,0,26,200,87,1,91,253,152,0,202,56,70,0,142,8,77,0,80,10,175,1,252,199,76,0,22,110,82,255,129,1,194,0,11,128,61,1,87,14,145,255,253,222,190,1,15,72,174,0,85,163,86,254,58,99,44,255,45,24,188,254,26,205,15,0,19,229,210,254,248,67,195,0,99,71,184,0,154,199,37,255,151,243,121,255,38,51,75,255,201,85,130,254,44,65,250,0,57,147,243,254,146,43,59,255,89,28,53,0,33,84,24,255,179,51,18,254,189,70,83,0,11,156,179,1,98,134,119,0,158,111,111,0,119,154,73,255,200,63,140,254,45,13,13,255,154,192,2,254,81,72,42,0,46,160,185,254,44,112,6,0,146,215,149,1,26,176,104,0,68,28,87,1,236,50,153,255,179,128,250,254,206,193,191,255,166,92,137,254,53,40,239,0,210,1,204,254,168,173,35,0,141,243,45,1,36,50,109,255,15,242,194,255,227,159,122,255,176,175,202,254,70,57,72,0,40,223,56,0,208,162,58,255,183,98,93,0,15,111,12,0,30,8,76,255,132,127,246,255,45,242,103,0,69,181,15,255,10,209,30,0,3,179,121,0,241,232,218,1,123,199,88,255,2,210,202,1,188,130,81,255,94,101,208,1,103,36,45,0,76,193,24,1,95,26,241,255,165,162,187,0,36,114,140,0,202,66,5,255,37,56,147,0,152,11,243,1,127,85,232,255,250,135,212,1,185,177,113,0,90,220,75,255,69,248,146,0,50,111,50,0,92,22,80,0,244,36,115,254,163,100,82,255,25,193,6,1,127,61,36,0,253,67,30,254,65,236,170,255,161,17,215,254,63,175,140,0,55,127,4,0,79,112,233,0,109,160,40,0,143,83,7,255,65,26,238,255,217,169,140,255,78,94,189,255,0,147,190,255,147,71,186,254,106,77,127,255,233,157,233,1,135,87,237,255,208,13,236,1,155,109,36,255,180,100,218,0,180,163,18,0,190,110,9,1,17,63,123,255,179,136,180,255,165,123,123,255,144,188,81,254,71,240,108,255,25,112,11,255,227,218,51,255,167,50,234,255,114,79,108,255,31,19,115,255,183,240,99,0,227,87,143,255,72,217,248,255,102,169,95,1,129,149,149,0,238,133,12,1,227,204,35,0,208,115,26,1,102,8,234,0,112,88,143,1,144,249,14,0,240,158,172,254,100,112,119,0,194,141,153,254,40,56,83,255,121,176,46,0,42,53,76,255,158,191,154,0,91,209,92,0,173,13,16,1,5,72,226,255,204,254,149,0,80,184,207,0,100,9,122,254,118,101,171,255,252,203,0,254,160,207,54,0,56,72,249,1,56,140,13,255,10,64,107,254,91,101,52,255,225,181,248,1,139,255,132,0,230,145,17,0,233,56,23,0,119,1,241,255,213,169,151,255,99,99,9,254,185,15,191,255,173,103,109,1,174,13,251,255,178,88,7,254,27,59,68,255,10,33,2,255,248,97,59,0,26,30,146,1,176,147,10,0,95,121,207,1,188,88,24,0,185,94,254,254,115,55,201,0,24,50,70,0,120,53,6,0,142,66,146,0,228,226,249,255,104,192,222,1,173,68,219,0,162,184,36,255,143,102,137,255,157,11,23,0,125,45,98,0,235,93,225,254,56,112,160,255,70,116,243,1,153,249,55,255,129,39,17,1,241,80,244,0,87,69,21,1,94,228,73,255,78,66,65,255,194,227,231,0,61,146,87,255,173,155,23,255,112,116,219,254,216,38,11,255,131,186,133,0,94,212,187,0,100,47,91,0,204,254,175,255,222,18,215,254,173,68,108,255,227,228,79,255,38,221,213,0,163,227,150,254,31,190,18,0,160,179,11,1,10,90,94,255,220,174,88,0,163,211,229,255,199,136,52,0,130,95,221,255,140,188,231,254,139,113,128,255,117,171,236,254,49,220,20,255,59,20,171,255,228,109,188,0,20,225,32,254,195,16,174,0,227,254,136,1,135,39,105,0,150,77,206,255,210,238,226,0,55,212,132,254,239,57,124,0,170,194,93,255,249,16,247,255,24,151,62,255,10,151,10,0,79,139,178,255,120,242,202,0,26,219,213,0,62,125,35,255,144,2,108,255,230,33,83,255,81,45,216,1,224,62,17,0,214,217,125,0,98,153,153,255,179,176,106,254,131,93,138,255,109,62,36,255,178,121,32,255,120,252,70,0,220,248,37,0,204,88,103,1,128,220,251,255,236,227,7,1,106,49,198,255,60,56,107,0,99,114,238,0,220,204,94,1,73,187,1,0,89,154,34,0,78,217,165,255,14,195,249,255,9,230,253,255,205,135,245,0,26,252,7,255,84,205,27,1,134,2,112,0,37,158,32,0,231,91,237,255,191,170,204,255,152,7,222,0,109,192,49,0,193,166,146,255,232,19,181,255,105,142,52,255,103,16,27,1,253,200,165,0,195,217,4,255,52,189,144,255,123,155,160,254,87,130,54,255,78,120,61,255,14,56,41,0,25,41,125,255,87,168,245,0,214,165,70,0,212,169,6,255,219,211,194,254,72,93,164,255,197,33,103,255,43,142,141,0,131,225,172,0,244,105,28,0,68,68,225,0,136,84,13,255,130,57,40,254,139,77,56,0,84,150,53,0,54,95,157,0,144,13,177,254,95,115,186,0,117,23,118,255,244,166,241,255,11,186,135,0,178,106,203,255,97,218,93,0,43,253,45,0,164,152,4,0,139,118,239,0,96,1,24,254,235,153,211,255,168,110,20,255,50,239,176,0,114,41,232,0,193,250,53,0,254,160,111,254,136,122,41,255,97,108,67,0,215,152,23,255,140,209,212,0,42,189,163,0,202,42,50,255,106,106,189,255,190,68,217,255,233,58,117,0,229,220,243,1,197,3,4,0,37,120,54,254,4,156,134,255,36,61,171,254,165,136,100,255,212,232,14,0,90,174,10,0,216,198,65,255,12,3,64,0,116,113,115,255,248,103,8,0,231,125,18,255,160,28,197,0,30,184,35,1,223,73,249,255,123,20,46,254,135,56,37,255,173,13,229,1,119,161,34,255,245,61,73,0,205,125,112,0,137,104,134,0,217,246,30,255,237,142,143,0,65,159,102,255,108,164,190,0,219,117,173,255,34,37,120,254,200,69,80,0,31,124,218,254,74,27,160,255,186,154,199,255,71,199,252,0,104,81,159,1,17,200,39,0,211,61,192,1,26,238,91,0,148,217,12,0,59,91,213,255,11,81,183,255,129,230,122,255,114,203,145,1,119,180,66,255,72,138,180,0,224,149,106,0,119,82,104,255,208,140,43,0,98,9,182,255,205,101,134,255,18,101,38,0,95,197,166,255,203,241,147,0,62,208,145,255,133,246,251,0,2,169,14,0,13,247,184,0,142,7,254,0,36,200,23,255,88,205,223,0,91,129,52,255,21,186,30,0,143,228,210,1,247,234,248,255,230,69,31,254,176,186,135,255,238,205,52,1,139,79,43,0,17,176,217,254,32,243,67,0,242,111,233,0,44,35,9,255,227,114,81,1,4,71,12,255,38,105,191,0,7,117,50,255,81,79,16,0,63,68,65,255,157,36,110,255,77,241,3,255,226,45,251,1,142,25,206,0,120,123,209,1,28,254,238,255,5,128,126,255,91,222,215,255,162,15,191,0,86,240,73,0,135,185,81,254,44,241,163,0,212,219,210,255,112,162,155,0,207,101,118,0,168,72,56,255,196,5,52,0,72,172,242,255,126,22,157,255,146,96,59,255,162,121,152,254,140,16,95,0,195,254,200,254,82,150,162,0,119,43,145,254,204,172,78,255,166,224,159,0,104,19,237,255,245,126,208,255,226,59,213,0,117,217,197,0,152,72,237,0,220,31,23,254,14,90,231,255,188,212,64,1,60,101,246,255,85,24,86,0,1,177,109,0,146,83,32,1,75,182,192,0,119,241,224,0,185,237,27,255,184,101,82,1,235,37,77,255,253,134,19,0,232,246,122,0,60,106,179,0,195,11,12,0,109,66,235,1,125,113,59,0,61,40,164,0,175,104,240,0,2,47,187,255,50,12,141,0,194,139,181,255,135,250,104,0,97,92,222,255,217,149,201,255,203,241,118,255,79,151,67,0,122,142,218,255,149,245,239,0,138,42,200,254,80,37,97,255,124,112,167,255,36,138,87,255,130,29,147,255,241,87,78,255,204,97,19,1,177,209,22,255,247,227,127,254,99,119,83,255,212,25,198,1,16,179,179,0,145,77,172,254,89,153,14,255,218,189,167,0,107,233,59,255,35,33,243,254,44,112,112,255,161,127,79,1,204,175,10,0,40,21,138,254,104,116,228,0,199,95,137,255,133,190,168,255,146,165,234,1,183,99,39,0,183,220,54,254,255,222,133,0,162,219,121,254,63,239,6,0,225,102,54,255,251,18,246,0,4,34,129,1,135,36,131,0,206,50,59,1,15,97,183,0,171,216,135,255,101,152,43,255,150,251,91,0,38,145,95,0,34,204,38,254,178,140,83,255,25,129,243,255,76,144,37,0,106,36,26,254,118,144,172,255,68,186,229,255,107,161,213,255,46,163,68,255,149,170,253,0,187,17,15,0,218,160,165,255,171,35,246,1,96,13,19,0,165,203,117,0,214,107,192,255,244,123,177,1,100,3,104,0,178,242,97,255,251,76,130,255,211,77,42,1,250,79,70,255,63,244,80,1,105,101,246,0,61,136,58,1,238,91,213,0,14,59,98,255,167,84,77,0,17,132,46,254,57,175,197,255,185,62,184,0,76,64,207,0,172,175,208,254,175,74,37,0,138,27,211,254,148,125,194,0,10,89,81,0,168,203,101,255,43,213,209,1,235,245,54,0,30,35,226,255,9,126,70,0,226,125,94,254,156,117,20,255,57,248,112,1,230,48,64,255,164,92,166,1,224,214,230,255,36,120,143,0,55,8,43,255,251,1,245,1,106,98,165,0,74,107,106,254,53,4,54,255,90,178,150,1,3,120,123,255,244,5,89,1,114,250,61,255,254,153,82,1,77,15,17,0,57,238,90,1,95,223,230,0,236,52,47,254,103,148,164,255,121,207,36,1,18,16,185,255,75,20,74,0,187,11,101,0,46,48,129,255,22,239,210,255,77,236,129,255,111,77,204,255,61,72,97,255,199,217,251,255,42,215,204,0,133,145,201,255,57,230,146,1,235,100,198,0,146,73,35,254,108,198,20,255,182,79,210,255,82,103,136,0,246,108,176,0,34,17,60,255,19,74,114,254,168,170,78,255,157,239,20,255,149,41,168,0,58,121,28,0,79,179,134,255,231,121,135,255,174,209,98,255,243,122,190,0,171,166,205,0,212,116,48,0,29,108,66,255,162,222,182,1,14,119,21,0,213,39,249,255,254,223,228,255,183,165,198,0,133,190,48,0,124,208,109,255,119,175,85,255,9,209,121,1,48,171,189,255,195,71,134,1,136,219,51,255,182,91,141,254,49,159,72,0,35,118,245,255,112,186,227,255,59,137,31,0,137,44,163,0,114,103,60,254,8,213,150,0,162,10,113,255,194,104,72,0,220,131,116,255,178,79,92,0,203,250,213,254,93,193,189,255,130,255,34,254,212,188,151,0,136,17,20,255,20,101,83,255,212,206,166,0,229,238,73,255,151,74,3,255,168,87,215,0,155,188,133,255,166,129,73,0,240,79,133,255,178,211,81,255,203,72,163,254,193,168,165,0,14,164,199,254,30,255,204,0,65,72,91,1,166,74,102,255,200,42,0,255,194,113,227,255,66,23,208,0,229,216,100,255,24,239,26,0,10,233,62,255,123,10,178,1,26,36,174,255,119,219,199,1,45,163,190,0,16,168,42,0,166,57,198,255,28,26,26,0,126,165,231,0,251,108,100,255,61,229,121,255,58,118,138,0,76,207,17,0,13,34,112,254,89,16,168,0,37,208,105,255,35,201,215,255,40,106,101,254,6,239,114,0,40,103,226,254,246,127,110,255,63,167,58,0,132,240,142,0,5,158,88,255,129,73,158,255,94,89,146,0,230,54,146,0,8,45,173,0,79,169,1,0,115,186,247,0,84,64,131,0,67,224,253,255,207,189,64,0,154,28,81,1,45,184,54,255,87,212,224,255,0,96,73,255,129,33,235,1,52,66,80,255,251,174,155,255,4,179,37,0,234,164,93,254,93,175,253,0,198,69,87,255,224,106,46,0,99,29,210,0,62,188,114,255,44,234,8,0,169,175,247,255,23,109,137,255,229,182,39,0,192,165,94,254,245,101,217,0,191,88,96,0,196,94,99,255,106,238,11,254,53,126,243,0,94,1,101,255,46,147,2,0,201,124,124,255,141,12,218,0,13,166,157,1,48,251,237,255,155,250,124,255,106,148,146,255,182,13,202,0,28,61,167,0,217,152,8,254,220,130,45,255,200,230,255,1,55,65,87,255,93,191,97,254,114,251,14,0,32,105,92,1,26,207,141,0,24,207,13,254,21,50,48,255,186,148,116,255,211,43,225,0,37,34,162,254,164,210,42,255,68,23,96,255,182,214,8,255,245,117,137,255,66,195,50,0,75,12,83,254,80,140,164,0,9,165,36,1,228,110,227,0,241,17,90,1,25,52,212,0,6,223,12,255,139,243,57,0,12,113,75,1,246,183,191,255,213,191,69,255,230,15,142,0,1,195,196,255,138,171,47,255,64,63,106,1,16,169,214,255,207,174,56,1,88,73,133,255,182,133,140,0,177,14,25,255,147,184,53,255,10,227,161,255,120,216,244,255,73,77,233,0,157,238,139,1,59,65,233,0,70,251,216,1,41,184,153,255,32,203,112,0,146,147,253,0,87,101,109,1,44,82,133,255,244,150,53,255,94,152,232,255,59,93,39,255,88,147,220,255,78,81,13,1,32,47,252,255,160,19,114,255,93,107,39,255,118,16,211,1,185,119,209,255,227,219,127,254,88,105,236,255,162,110,23,255,36,166,110,255,91,236,221,255,66,234,116,0,111,19,244,254,10,233,26,0,32,183,6,254,2,191,242,0,218,156,53,254,41,60,70,255,168,236,111,0,121,185,126,255,238,142,207,255,55,126,52,0,220,129,208,254,80,204,164,255,67,23,144,254,218,40,108,255,127,202,164,0,203,33,3,255,2,158,0,0,37,96,188,255,192,49,74,0,109,4,0,0,111,167,10,254,91,218,135,255,203,66,173,255,150,194,226,0,201,253,6,255,174,102,121,0,205,191,110,0,53,194,4,0,81,40,45,254,35,102,143,255,12,108,198,255,16,27,232,255,252,71,186,1,176,110,114,0,142,3,117,1,113,77,142,0,19,156,197,1,92,47,252,0,53,232,22,1,54,18,235,0,46,35,189,255,236,212,129,0,2,96,208,254,200,238,199,255,59,175,164,255,146,43,231,0,194,217,52,255,3,223,12,0,138,54,178,254,85,235,207,0,232,207,34,0,49,52,50,255,166,113,89,255,10,45,216,255,62,173,28,0,111,165,246,0,118,115,91,255,128,84,60,0,167,144,203,0,87,13,243,0,22,30,228,1,177,113,146,255,129,170,230,254,252,153,129,255,145,225,43,0,70,231,5,255,122,105,126,254,86,246,148,255,110,37,154,254,209,3,91,0,68,145,62,0,228,16,165,255,55,221,249,254,178,210,91,0,83,146,226,254,69,146,186,0,93,210,104,254,16,25,173,0,231,186,38,0,189,122,140,255,251,13,112,255,105,110,93,0,251,72,170,0,192,23,223,255,24,3,202,1,225,93,228,0,153,147,199,254,109,170,22,0,248,101,246,255,178,124,12,255,178,254,102,254,55,4,65,0,125,214,180,0,183,96,147,0,45,117,23,254,132,191,249,0,143,176,203,254,136,183,54,255,146,234,177,0,146,101,86,255,44,123,143,1,33,209,152,0,192,90,41,254,83,15,125,255,213,172,82,0,215,169,144,0,16,13,34,0,32,209,100,255,84,18,249,1,197,17,236,255,217,186,230,0,49,160,176,255,111,118,97,255,237,104,235,0,79,59,92,254,69,249,11,255,35,172,74,1,19,118,68,0,222,124,165,255,180,66,35,255,86,174,246,0,43,74,111,255,126,144,86,255,228,234,91,0,242,213,24,254,69,44,235,255,220,180,35,0,8,248,7,255,102,47,92,255,240,205,102,255,113,230,171,1,31,185,201,255,194,246,70,255,122,17,187,0,134,70,199,255,149,3,150,255,117,63,103,0,65,104,123,255,212,54,19,1,6,141,88,0,83,134,243,255,136,53,103,0,169,27,180,0,177,49,24,0,111,54,167,0,195,61,215,255,31,1,108,1,60,42,70,0,185,3,162,255,194,149,40,255,246,127,38,254,190,119,38,255,61,119,8,1,96,161,219,255,42,203,221,1,177,242,164,255,245,159,10,0,116,196,0,0,5,93,205,254,128,127,179,0,125,237,246,255,149,162,217,255,87,37,20,254,140,238,192,0,9,9,193,0,97,1,226,0,29,38,10,0,0,136,63,255,229,72,210,254,38,134,92,255,78,218,208,1,104,36,84,255,12,5,193,255,242,175,61,255,191,169,46,1,179,147,147,255,113,190,139,254,125,172,31,0,3,75,252,254,215,36,15,0,193,27,24,1,255,69,149,255,110,129,118,0,203,93,249,0,138,137,64,254,38,70,6,0,153,116,222,0,161,74,123,0,193,99,79,255,118,59,94,255,61,12,43,1,146,177,157,0,46,147,191,0,16,255,38,0,11,51,31,1,60,58,98,255,111,194,77,1,154,91,244,0,140,40,144,1,173,10,251,0,203,209,50,254,108,130,78,0,228,180,90,0,174,7,250,0,31,174,60,0,41,171,30,0,116,99,82,255,118,193,139,255,187,173,198,254,218,111,56,0,185,123,216,0,249,158,52,0,52,180,93,255,201,9,91,255,56,45,166,254,132,155,203,255,58,232,110,0,52,211,89,255,253,0,162,1,9,87,183,0,145,136,44,1,94,122,245,0,85,188,171,1,147,92,198,0,0,8,104,0,30,95,174,0,221,230,52,1,247,247,235,255,137,174,53,255,35,21,204,255,71,227,214,1,232,82,194,0,11,48,227,255,170,73,184,255,198,251,252,254,44,112,34,0,131,101,131,255,72,168,187,0,132,135,125,255,138,104,97,255,238,184,168,255,243,104,84,255,135,216,226,255,139,144,237,0,188,137,150,1,80,56,140,255,86,169,167,255,194,78,25,255,220,17,180,255,17,13,193,0,117,137,212,255,141,224,151,0,49,244,175,0,193,99,175,255,19,99,154,1,255,65,62,255,156,210,55,255,242,244,3,255,250,14,149,0,158,88,217,255,157,207,134,254,251,232,28,0,46,156,251,255,171,56,184,255,239,51,234,0,142,138,131,255,25,254,243,1,10,201,194,0,63,97,75,0,210,239,162,0,192,200,31,1,117,214,243,0,24,71,222,254,54,40,232,255,76,183,111,254,144,14,87,255,214,79,136,255,216,196,212,0,132,27,140,254,131,5,253,0,124,108,19,255,28,215,75,0,76,222,55,254,233,182,63,0,68,171,191,254,52,111,222,255,10,105,77,255,80,170,235,0,143,24,88,255,45,231,121,0,148,129,224,1,61,246,84,0,253,46,219,255,239,76,33,0,49,148,18,254,230,37,69,0,67,134,22,254,142,155,94,0,31,157,211,254,213,42,30,255,4,228,247,254,252,176,13,255,39,0,31,254,241,244,255,255,170,45,10,254,253,222,249,0,222,114,132,0,255,47,6,255,180,163,179,1,84,94,151,255,89,209,82,254,229,52,169,255,213,236,0,1,214,56,228,255,135,119,151,255,112,201,193,0,83,160,53,254,6,151,66,0,18,162,17,0,233,97,91,0,131,5,78,1,181,120,53,255,117,95,63,255,237,117,185,0,191,126,136,255,144,119,233,0,183,57,97,1,47,201,187,255,167,165,119,1,45,100,126,0,21,98,6,254,145,150,95,255,120,54,152,0,209,98,104,0,143,111,30,254,184,148,249,0,235,216,46,0,248,202,148,255,57,95,22,0,242,225,163,0,233,247,232,255,71,171,19,255,103,244,49,255,84,103,93,255,68,121,244,1,82,224,13,0,41,79,43,255,249,206,167,255,215,52,21,254,192,32,22,255,247,111,60,0,101,74,38,255,22,91,84,254,29,28,13,255,198,231,215,254,244,154,200,0,223,137,237,0,211,132,14,0,95,64,206,255,17,62,247,255,233,131,121,1,93,23,77,0,205,204,52,254,81,189,136,0,180,219,138,1,143,18,94,0,204,43,140,254,188,175,219,0,111,98,143,255,151,63,162,255,211,50,71,254,19,146,53,0,146,45,83,254,178,82,238,255,16,133,84,255,226,198,93,255,201,97,20,255,120,118,35,255,114,50,231,255,162,229,156,255,211,26,12,0,114,39,115,255,206,212,134,0,197,217,160,255,116,129,94,254,199,215,219,255,75,223,249,1,253,116,181,255,232,215,104,255,228,130,246,255,185,117,86,0,14,5,8,0,239,29,61,1,237,87,133,255,125,146,137,254,204,168,223,0,46,168,245,0,154,105,22,0,220,212,161,255,107,69,24,255,137,218,181,255,241,84,198,255,130,122,211,255,141,8,153,255,190,177,118,0,96,89,178,0,255,16,48,254,122,96,105,255,117,54,232,255,34,126,105,255,204,67,166,0,232,52,138,255,211,147,12,0,25,54,7,0,44,15,215,254,51,236,45,0,190,68,129,1,106,147,225,0,28,93,45,254,236,141,15,255,17,61,161,0,220,115,192,0,236,145,24,254,111,168,169,0,224,58,63,255,127,164,188,0,82,234,75,1,224,158,134,0,209,68,110,1,217,166,217,0,70,225,166,1,187,193,143,255,16,7,88,255,10,205,140,0,117,192,156,1,17,56,38,0,27,124,108,1,171,215,55,255,95,253,212,0,155,135,168,255,246,178,153,254,154,68,74,0,232,61,96,254,105,132,59,0,33,76,199,1,189,176,130,255,9,104,25,254,75,198,102,255,233,1,112,0,108,220,20,255,114,230,70,0,140,194,133,255,57,158,164,254,146,6,80,255,169,196,97,1,85,183,130,0,70,158,222,1,59,237,234,255,96,25,26,255,232,175,97,255,11,121,248,254,88,35,194,0,219,180,252,254,74,8,227,0,195,227,73,1,184,110,161,255,49,233,164,1,128,53,47,0,82,14,121,255,193,190,58,0,48,174,117,255,132,23,32,0,40,10,134,1,22,51,25,255,240,11,176,255,110,57,146,0,117,143,239,1,157,101,118,255,54,84,76,0,205,184,18,255,47,4,72,255,78,112,85,255,193,50,66,1,93,16,52,255,8,105,134,0,12,109,72,255,58,156,251,0,144,35,204,0,44,160,117,254,50,107,194,0,1,68,165,255,111,110,162,0,158,83,40,254,76,214,234,0,58,216,205,255,171,96,147,255,40,227,114,1,176,227,241,0,70,249,183,1,136,84,139,255,60,122,247,254,143,9,117,255,177,174,137,254,73,247,143,0,236,185,126,255,62,25,247,255,45,64,56,255,161,244,6,0,34,57,56,1,105,202,83,0,128,147,208,0,6,103,10,255,74,138,65,255,97,80,100,255,214,174,33,255,50,134,74,255,110,151,130,254,111,84,172,0,84,199,75,254,248,59,112,255,8,216,178,1,9,183,95,0,238,27,8,254,170,205,220,0,195,229,135,0,98,76,237,255,226,91,26,1,82,219,39,255,225,190,199,1,217,200,121,255,81,179,8,255,140,65,206,0,178,207,87,254,250,252,46,255,104,89,110,1,253,189,158,255,144,214,158,255,160,245,54,255,53,183,92,1,21,200,194,255,146,33,113,1,209,1,255,0,235,106,43,255,167,52,232,0,157,229,221,0,51,30,25,0,250,221,27,1,65,147,87,255,79,123,196,0,65,196,223,255,76,44,17,1,85,241,68,0,202,183,249,255,65,212,212,255,9,33,154,1,71,59,80,0,175,194,59,255,141,72,9,0,100,160,244,0,230,208,56,0,59,25,75,254,80,194,194,0,18,3,200,254,160,159,115,0,132,143,247,1,111,93,57,255,58,237,11,1,134,222,135,255,122,163,108,1,123,43,190,255,251,189,206,254,80,182,72,255,208,246,224,1,17,60,9,0,161,207,38,0,141,109,91,0,216,15,211,255,136,78,110,0,98,163,104,255,21,80,121,255,173,178,183,1,127,143,4,0,104,60,82,254,214,16,13,255,96,238,33,1,158,148,230,255,127,129,62,255,51,255,210,255,62,141,236,254,157,55,224,255,114,39,244,0,192,188,250,255,228,76,53,0,98,84,81,255,173,203,61,254,147,50,55,255,204,235,191,0,52,197,244,0,88,43,211,254,27,191,119,0,188,231,154,0,66,81,161,0,92,193,160,1,250,227,120,0,123,55,226,0,184,17,72,0,133,168,10,254,22,135,156,255,41,25,103,255,48,202,58,0,186,149,81,255,188,134,239,0,235,181,189,254,217,139,188,255,74,48,82,0,46,218,229,0,189,253,251,0,50,229,12,255,211,141,191,1,128,244,25,255,169,231,122,254,86,47,189,255,132,183,23,255,37,178,150,255,51,137,253,0,200,78,31,0,22,105,50,0,130,60,0,0,132,163,91,254,23,231,187,0,192,79,239,0,157,102,164,255,192,82,20,1,24,181,103,255,240,9,234,0,1,123,164,255,133,233,0,255,202,242,242,0,60,186,245,0,241,16,199,255,224,116,158,254,191,125,91,255,224,86,207,0,121,37,231,255,227,9,198,255,15,153,239,255,121,232,217,254,75,112,82,0,95,12,57,254,51,214,105,255,148,220,97,1,199,98,36,0,156,209,12,254,10,212,52,0,217,180,55,254,212,170,232,255,216,20,84,255,157,250,135,0,157,99,127,254,1,206,41,0,149,36,70,1,54,196,201,255,87,116,0,254,235,171,150,0,27,163,234,0,202,135,180,0,208,95,0,254,123,156,93,0,183,62,75,0,137,235,182,0,204,225,255,255,214,139,210,255,2,115,8,255,29,12,111,0,52,156,1,0,253,21,251,255,37,165,31,254,12,130,211,0,106,18,53,254,42,99,154,0,14,217,61,254,216,11,92,255,200,197,112,254,147,38,199,0,36,252,120,254,107,169,77,0,1,123,159,255,207,75,102,0,163,175,196,0,44,1,240,0,120,186,176,254,13,98,76,255,237,124,241,255,232,146,188,255,200,96,224,0,204,31,41,0,208,200,13,0,21,225,96,255,175,156,196,0,247,208,126,0,62,184,244,254,2,171,81,0,85,115,158,0,54,64,45,255,19,138,114,0,135,71,205,0,227,47,147,1,218,231,66,0,253,209,28,0,244,15,173,255,6,15,118,254,16,150,208,255,185,22,50,255,86,112,207,255,75,113,215,1,63,146,43,255,4,225,19,254,227,23,62,255,14,255,214,254,45,8,205,255,87,197,151,254,210,82,215,255,245,248,247,255,128,248,70,0,225,247,87,0,90,120,70,0,213,245,92,0,13,133,226,0,47,181,5,1,92,163,105,255,6,30,133,254,232,178,61,255,230,149,24,255,18,49,158,0,228,100,61,254,116,243,251,255,77,75,92,1,81,219,147,255,76,163,254,254,141,213,246,0,232,37,152,254,97,44,100,0,201,37,50,1,212,244,57,0,174,171,183,255,249,74,112,0,166,156,30,0,222,221,97,255,243,93,73,254,251,101,100,255,216,217,93,255,254,138,187,255,142,190,52,255,59,203,177,255,200,94,52,0,115,114,158,255,165,152,104,1,126,99,226,255,118,157,244,1,107,200,16,0,193,90,229,0,121,6,88,0,156,32,93,254,125,241,211,255,14,237,157,255,165,154,21,255,184,224,22,255,250,24,152,255,113,77,31,0,247,171,23,255,237,177,204,255,52,137,145,255,194,182,114,0,224,234,149,0,10,111,103,1,201,129,4,0,238,142,78,0,52,6,40,255,110,213,165,254,60,207,253,0,62,215,69,0,96,97,0,255,49,45,202,0,120,121,22,255,235,139,48,1,198,45,34,255,182,50,27,1,131,210,91,255,46,54,128,0,175,123,105,255,198,141,78,254,67,244,239,255,245,54,103,254,78,38,242,255,2,92,249,254,251,174,87,255,139,63,144,0,24,108,27,255,34,102,18,1,34,22,152,0,66,229,118,254,50,143,99,0,144,169,149,1,118,30,152,0,178,8,121,1,8,159,18,0,90,101,230,255,129,29,119,0,68,36,11,1,232,183,55,0,23,255,96,255,161,41,193,255,63,139,222,0,15,179,243,0,255,100,15,255,82,53,135,0,137,57,149,1,99,240,170,255,22,230,228,254,49,180,82,255,61,82,43,0,110,245,217,0,199,125,61,0,46,253,52,0,141,197,219,0,211,159,193,0,55,121,105,254,183,20,129,0,169,119,170,255,203,178,139,255,135,40,182,255,172,13,202,255,65,178,148,0,8,207,43,0,122,53,127,1,74,161,48,0,227,214,128,254,86,11,243,255,100,86,7,1,245,68,134,255,61,43,21,1,152,84,94,255,190,60,250,254,239,118,232,255,214,136,37,1,113,76,107,255,93,104,100,1,144,206,23,255,110,150,154,1,228,103,185,0,218,49,50,254,135,77,139,255,185,1,78,0,0,161,148,255,97,29,233,255,207,148,149,255,160,168,0,0,91,128,171,255,6,28,19,254,11,111,247,0,39,187,150,255,138,232,149,0,117,62,68,255,63,216,188,255,235,234,32,254,29,57,160,255,25,12,241,1,169,60,191,0,32,131,141,255,237,159,123,255,94,197,94,254,116,254,3,255,92,179,97,254,121,97,92,255,170,112,14,0,21,149,248,0,248,227,3,0,80,96,109,0,75,192,74,1,12,90,226,255,161,106,68,1,208,114,127,255,114,42,255,254,74,26,74,255,247,179,150,254,121,140,60,0,147,70,200,255,214,40,161,255,161,188,201,255,141,65,135,255,242,115,252,0,62,47,202,0,180,149,255,254,130,55,237,0,165,17,186,255,10,169,194,0,156,109,218,255,112,140,123,255,104,128,223,254,177,142,108,255,121,37,219,255,128,77,18,255,111,108,23,1,91,192,75,0,174,245,22,255,4,236,62,255,43,64,153,1,227,173,254,0,237,122,132,1,127,89,186,255,142,82,128,254,252,84,174,0,90,179,177,1,243,214,87,255,103,60,162,255,208,130,14,255,11,130,139,0,206,129,219,255,94,217,157,255,239,230,230,255,116,115,159,254,164,107,95,0,51,218,2,1,216,125,198,255,140,202,128,254,11,95,68,255,55,9,93,254,174,153,6,255,204,172,96,0,69,160,110,0,213,38,49,254,27,80,213,0,118,125,114,0,70,70,67,255,15,142,73,255,131,122,185,255,243,20,50,254,130,237,40,0,210,159,140,1,197,151,65,255,84,153,66,0,195,126,90,0,16,238,236,1,118,187,102,255,3,24,133,255,187,69,230,0,56,197,92,1,213,69,94,255,80,138,229,1,206,7,230,0,222,111,230,1,91,233,119,255,9,89,7,1,2,98,1,0,148,74,133,255,51,246,180,255,228,177,112,1,58,189,108,255,194,203,237,254,21,209,195,0,147,10,35,1,86,157,226,0,31,163,139,254,56,7,75,255,62,90,116,0,181,60,169,0,138,162,212,254,81,167,31,0,205,90,112,255,33,112,227,0,83,151,117,1,177,224,73,255,174,144,217,255,230,204,79,255,22,77,232,255,114,78,234,0,224,57,126,254,9,49,141,0,242,147,165,1,104,182,140,255,167,132,12,1,123,68,127,0,225,87,39,1,251,108,8,0,198,193,143,1,121,135,207,255,172,22,70,0,50,68,116,255,101,175,40,255,248,105,233,0,166,203,7,0,110,197,218,0,215,254,26,254,168,226,253,0,31,143,96,0,11,103,41,0,183,129,203,254,100,247,74,255,213,126,132,0,210,147,44,0,199,234,27,1,148,47,181,0,155,91,158,1,54,105,175,255,2,78,145,254,102,154,95,0,128,207,127,254,52,124,236,255,130,84,71,0,221,243,211,0,152,170,207,0,222,106,199,0,183,84,94,254,92,200,56,255,138,182,115,1,142,96,146,0,133,136,228,0,97,18,150,0,55,251,66,0,140,102,4,0,202,103,151,0,30,19,248,255,51,184,207,0,202,198,89,0,55,197,225,254,169,95,249,255,66,65,68,255,188,234,126,0,166,223,100,1,112,239,244,0,144,23,194,0,58,39,182,0,244,44,24,254,175,68,179,255,152,118,154,1,176,162,130,0,217,114,204,254,173,126,78,255,33,222,30,255,36,2,91,255,2,143,243,0,9,235,215,0,3,171,151,1,24,215,245,255,168,47,164,254,241,146,207,0,69,129,180,0,68,243,113,0,144,53,72,254,251,45,14,0,23,110,168,0,68,68,79,255,110,70,95,254,174,91,144,255,33,206,95,255,137,41,7,255,19,187,153,254,35,255,112,255,9,145,185,254,50,157,37,0,11,112,49,1,102,8,190,255,234,243,169,1,60,85,23,0,74,39,189,0,116,49,239,0,173,213,210,0,46,161,108,255,159,150,37,0,196,120,185,255,34,98,6,255,153,195,62,255,97,230,71,255,102,61,76,0,26,212,236,255,164,97,16,0,198,59,146,0,163,23,196,0,56,24,61,0,181,98,193,0,251,147,229,255,98,189,24,255,46,54,206,255,234,82,246,0,183,103,38,1,109,62,204,0,10,240,224,0,146,22,117,255,142,154,120,0,69,212,35,0,208,99,118,1,121,255,3,255,72,6,194,0,117,17,197,255,125,15,23,0,154,79,153,0,214,94,197,255,185,55,147,255,62,254,78,254,127,82,153,0,110,102,63,255,108,82,161,255,105,187,212,1,80,138,39,0,60,255,93,255,72,12,186,0,210,251,31,1,190,167,144,255,228,44,19,254,128,67,232,0,214,249,107,254,136,145,86,255,132,46,176,0,189,187,227,255,208,22,140,0,217,211,116,0,50,81,186,254,139,250,31,0,30,64,198,1,135,155,100,0,160,206,23,254,187,162,211,255,16,188,63,0,254,208,49,0,85,84,191,0,241,192,242,255,153,126,145,1,234,162,162,255,230,97,216,1,64,135,126,0,190,148,223,1,52,0,43,255,28,39,189,1,64,136,238,0,175,196,185,0,98,226,213,255,127,159,244,1,226,175,60,0,160,233,142,1,180,243,207,255,69,152,89,1,31,101,21,0,144,25,164,254,139,191,209,0,91,25,121,0,32,147,5,0,39,186,123,255,63,115,230,255,93,167,198,255,143,213,220,255,179,156,19,255,25,66,122,0,214,160,217,255,2,45,62,255,106,79,146,254,51,137,99,255,87,100,231,255,175,145,232,255,101,184,1,255,174,9,125,0,82,37,161,1,36,114,141,255,48,222,142,255,245,186,154,0,5,174,221,254,63,114,155,255,135,55,160,1,80,31,135,0,126,250,179,1,236,218,45,0,20,28,145,1,16,147,73,0,249,189,132,1,17,189,192,255,223,142,198,255,72,20,15,255,250,53,237,254,15,11,18,0,27,211,113,254,213,107,56,255,174,147,146,255,96,126,48,0,23,193,109,1,37,162,94,0,199,157,249,254,24,128,187,255,205,49,178,254,93,164,42,255,43,119,235,1,88,183,237,255,218,210,1,255,107,254,42,0,230,10,99,255,162,0,226,0,219,237,91,0,129,178,203,0,208,50,95,254,206,208,95,255,247,191,89,254,110,234,79,255,165,61,243,0,20,122,112,255,246,246,185,254,103,4,123,0,233,99,230,1,219,91,252,255,199,222,22,255,179,245,233,255,211,241,234,0,111,250,192,255,85,84,136,0,101,58,50,255,131,173,156,254,119,45,51,255,118,233,16,254,242,90,214,0,94,159,219,1,3,3,234,255,98,76,92,254,80,54,230,0,5,228,231,254,53,24,223,255,113,56,118,1,20,132,1,255,171,210,236,0,56,241,158,255,186,115,19,255,8,229,174,0,48,44,0,1,114,114,166,255,6,73,226,255,205,89,244,0,137,227,75,1,248,173,56,0,74,120,246,254,119,3,11,255,81,120,198,255,136,122,98,255,146,241,221,1,109,194,78,255,223,241,70,1,214,200,169,255,97,190,47,255,47,103,174,255,99,92,72,254,118,233,180,255,193,35,233,254,26,229,32,255,222,252,198,0,204,43,71,255,199,84,172,0,134,102,190,0,111,238,97,254,230,40,230,0,227,205,64,254,200,12,225,0,166,25,222,0,113,69,51,255,143,159,24,0,167,184,74,0,29,224,116,254,158,208,233,0,193,116,126,255,212,11,133,255,22,58,140,1,204,36,51,255,232,30,43,0,235,70,181,255,64,56,146,254,169,18,84,255,226,1,13,255,200,50,176,255,52,213,245,254,168,209,97,0,191,71,55,0,34,78,156,0,232,144,58,1,185,74,189,0,186,142,149,254,64,69,127,255,161,203,147,255,176,151,191,0,136,231,203,254,163,182,137,0,161,126,251,254,233,32,66,0,68,207,66,0,30,28,37,0,93,114,96,1,254,92,247,255,44,171,69,0,202,119,11,255,188,118,50,1,255,83,136,255,71,82,26,0,70,227,2,0,32,235,121,1,181,41,154,0,71,134,229,254,202,255,36,0,41,152,5,0,154,63,73,255,34,182,124,0,121,221,150,255,26,204,213,1,41,172,87,0,90,157,146,255,109,130,20,0,71,107,200,255,243,102,189,0,1,195,145,254,46,88,117,0,8,206,227,0,191,110,253,255,109,128,20,254,134,85,51,255,137,177,112,1,216,34,22,255,131,16,208,255,121,149,170,0,114,19,23,1,166,80,31,255,113,240,122,0,232,179,250,0,68,110,180,254,210,170,119,0,223,108,164,255,207,79,233,255,27,229,226,254,209,98,81,255,79,68,7,0,131,185,100,0,170,29,162,255,17,162,107,255,57,21,11,1,100,200,181,255,127,65,166,1,165,134,204,0,104,167,168,0,1,164,79,0,146,135,59,1,70,50,128,255,102,119,13,254,227,6,135,0,162,142,179,255,160,100,222,0,27,224,219,1,158,93,195,255,234,141,137,0,16,24,125,255,238,206,47,255,97,17,98,255,116,110,12,255,96,115,77,0,91,227,232,255,248,254,79,255,92,229,6,254,88,198,139,0,206,75,129,0,250,77,206,255,141,244,123,1,138,69,220,0,32,151,6,1,131,167,22,255,237,68,167,254,199,189,150,0,163,171,138,255,51,188,6,255,95,29,137,254,148,226,179,0,181,107,208,255,134,31,82,255,151,101,45,255,129,202,225,0,224,72,147,0,48,138,151,255,195,64,206,254,237,218,158,0,106,29,137,254,253,189,233,255,103,15,17,255,194,97,255,0,178,45,169,254,198,225,155,0,39,48,117,255,135,106,115,0,97,38,181,0,150,47,65,255,83,130,229,254,246,38,129,0,92,239,154,254,91,99,127,0,161,111,33,255,238,217,242,255,131,185,195,255,213,191,158,255,41,150,218,0,132,169,131,0,89,84,252,1,171,70,128,255,163,248,203,254,1,50,180,255,124,76,85,1,251,111,80,0,99,66,239,255,154,237,182,255,221,126,133,254,74,204,99,255,65,147,119,255,99,56,167,255,79,248,149,255,116,155,228,255,237,43,14,254,69,137,11,255,22,250,241,1,91,122,143,255,205,249,243,0,212,26,60,255,48,182,176,1,48,23,191,255,203,121,152,254,45,74,213,255,62,90,18,254,245,163,230,255,185,106,116,255,83,35,159,0,12,33,2,255,80,34,62,0,16,87,174,255,173,101,85,0,202,36,81,254,160,69,204,255,64,225,187,0,58,206,94,0,86,144,47,0,229,86,245,0,63,145,190,1,37,5,39,0,109,251,26,0,137,147,234,0,162,121,145,255,144,116,206,255,197,232,185,255,183,190,140,255,73,12,254,255,139,20,242,255,170,90,239,255,97,66,187,255,245,181,135,254,222,136,52,0,245,5,51,254,203,47,78,0,152,101,216,0,73,23,125,0,254,96,33,1,235,210,73,255,43,209,88,1,7,129,109,0,122,104,228,254,170,242,203,0,242,204,135,255,202,28,233,255,65,6,127,0,159,144,71,0,100,140,95,0,78,150,13,0,251,107,118,1,182,58,125,255,1,38,108,255,141,189,209,255,8,155,125,1,113,163,91,255,121,79,190,255,134,239,108,255,76,47,248,0,163,228,239,0,17,111,10,0,88,149,75,255,215,235,239,0,167,159,24,255,47,151,108,255,107,209,188,0,233,231,99,254,28,202,148,255,174,35,138,255,110,24,68,255,2,69,181,0,107,102,82,0,102,237,7,0,92,36,237,255,221,162,83,1,55,202,6,255,135,234,135,255,24,250,222,0,65,94,168,254,245,248,210,255,167,108,201,254,255,161,111,0,205,8,254,0,136,13,116,0,100,176,132,255,43,215,126,255,177,133,130,255,158,79,148,0,67,224,37,1,12,206,21,255,62,34,110,1,237,104,175,255,80,132,111,255,142,174,72,0,84,229,180,254,105,179,140,0,64,248,15,255,233,138,16,0,245,67,123,254,218,121,212,255,63,95,218,1,213,133,137,255,143,182,82,255,48,28,11,0,244,114,141,1,209,175,76,255,157,181,150,255,186,229,3,255,164,157,111,1,231,189,139,0,119,202,190,255,218,106,64,255,68,235,63,254,96,26,172,255,187,47,11,1,215,18,251,255,81,84,89,0,68,58,128,0,94,113,5,1,92,129,208,255,97,15,83,254,9,28,188,0,239,9,164,0,60,205,152,0,192,163,98,255,184,18,60,0,217,182,139,0,109,59,120,255,4,192,251,0,169,210,240,255,37,172,92,254,148,211,245,255,179,65,52,0,253,13,115,0,185,174,206,1,114,188,149,255,237,90,173,0,43,199,192,255,88,108,113,0,52,35,76,0,66,25,148,255,221,4,7,255,151,241,114,255,190,209,232,0,98,50,199,0,151,150,213,255,18,74,36,1,53,40,7,0,19,135,65,255,26,172,69,0,174,237,85,0,99,95,41,0,3,56,16,0,39,160,177,255,200,106,218,254,185,68,84,255,91,186,61,254,67,143,141,255,13,244,166,255,99,114,198,0,199,110,163,255,193,18,186,0,124,239,246,1,110,68,22,0,2,235,46,1,212,60,107,0,105,42,105,1,14,230,152,0,7,5,131,0,141,104,154,255,213,3,6,0,131,228,162,255,179,100,28,1,231,123,85,255,206,14,223,1,253,96,230,0,38,152,149,1,98,137,122,0,214,205,3,255,226,152,179,255,6,133,137,0,158,69,140,255,113,162,154,255,180,243,172,255,27,189,115,255,143,46,220,255,213,134,225,255,126,29,69,0,188,43,137,1,242,70,9,0,90,204,255,255,231,170,147,0,23,56,19,254,56,125,157,255,48,179,218,255,79,182,253,255,38,212,191,1,41,235,124,0,96,151,28,0,135,148,190,0,205,249,39,254,52,96,136,255,212,44,136,255,67,209,131,255,252,130,23,255,219,128,20,255,198,129,118,0,108,101,11,0,178,5,146,1,62,7,100,255,181,236,94,254,28,26,164,0,76,22,112,255,120,102,79,0,202,192,229,1,200,176,215,0,41,64,244,255,206,184,78,0,167,45,63,1,160,35,0,255,59,12,142,255,204,9,144,255,219,94,229,1,122,27,112,0,189,105,109,255,64,208,74,255,251,127,55,1,2,226,198,0,44,76,209,0,151,152,77,255,210,23,46,1,201,171,69,255,44,211,231,0,190,37,224,255,245,196,62,255,169,181,222,255,34,211,17,0,119,241,197,255,229,35,152,1,21,69,40,255,178,226,161,0,148,179,193,0,219,194,254,1,40,206,51,255,231,92,250,1,67,153,170,0,21,148,241,0,170,69,82,255,121,18,231,255,92,114,3,0,184,62,230,0,225,201,87,255,146,96,162,255,181,242,220,0,173,187,221,1,226,62,170,255,56,126,217,1,117,13,227,255,179,44,239,0,157,141,155,255,144,221,83,0,235,209,208,0,42,17,165,1,251,81,133,0,124,245,201,254,97,211,24,255,83,214,166,0,154,36,9,255,248,47,127,0,90,219,140,255,161,217,38,254,212,147,63,255,66,84,148,1,207,3,1,0,230,134,89,1,127,78,122,255,224,155,1,255,82,136,74,0,178,156,208,255,186,25,49,255,222,3,210,1,229,150,190,255,85,162,52,255,41,84,141,255,73,123,84,254,93,17,150,0,119,19,28,1,32,22,215,255,28,23,204,255,142,241,52,255,228,52,125,0,29,76,207,0,215,167,250,254,175,164,230,0,55,207,105,1,109,187,245,255,161,44,220,1,41,101,128,255,167,16,94,0,93,214,107,255,118,72,0,254,80,61,234,255,121,175,125,0,139,169,251,0,97,39,147,254,250,196,49,255,165,179,110,254,223,70,187,255,22,142,125,1,154,179,138,255,118,176,42,1,10,174,153,0,156,92,102,0,168,13,161,255,143,16,32,0,250,197,180,255,203,163,44,1,87,32,36,0,161,153,20,255,123,252,15,0,25,227,80,0,60,88,142,0,17,22,201,1,154,205,77,255,39,63,47,0,8,122,141,0,128,23,182,254,204,39,19,255],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+20480);allocate([4,112,29,255,23,36,140,255,210,234,116,254,53,50,63,255,121,171,104,255,160,219,94,0,87,82,14,254,231,42,5,0,165,139,127,254,86,78,38,0,130,60,66,254,203,30,45,255,46,196,122,1,249,53,162,255,136,143,103,254,215,210,114,0,231,7,160,254,169,152,42,255,111,45,246,0,142,131,135,255,131,71,204,255,36,226,11,0,0,28,242,255,225,138,213,255,247,46,216,254,245,3,183,0,108,252,74,1,206,26,48,255,205,54,246,255,211,198,36,255,121,35,50,0,52,216,202,255,38,139,129,254,242,73,148,0,67,231,141,255,42,47,204,0,78,116,25,1,4,225,191,255,6,147,228,0,58,88,177,0,122,165,229,255,252,83,201,255,224,167,96,1,177,184,158,255,242,105,179,1,248,198,240,0,133,66,203,1,254,36,47,0,45,24,115,255,119,62,254,0,196,225,186,254,123,141,172,0,26,85,41,255,226,111,183,0,213,231,151,0,4,59,7,255,238,138,148,0,66,147,33,255,31,246,141,255,209,141,116,255,104,112,31,0,88,161,172,0,83,215,230,254,47,111,151,0,45,38,52,1,132,45,204,0,138,128,109,254,233,117,134,255,243,190,173,254,241,236,240,0,82,127,236,254,40,223,161,255,110,182,225,255,123,174,239,0,135,242,145,1,51,209,154,0,150,3,115,254,217,164,252,255,55,156,69,1,84,94,255,255,232,73,45,1,20,19,212,255,96,197,59,254,96,251,33,0,38,199,73,1,64,172,247,255,117,116,56,255,228,17,18,0,62,138,103,1,246,229,164,255,244,118,201,254,86,32,159,255,109,34,137,1,85,211,186,0,10,193,193,254,122,194,177,0,122,238,102,255,162,218,171,0,108,217,161,1,158,170,34,0,176,47,155,1,181,228,11,255,8,156,0,0,16,75,93,0,206,98,255,1,58,154,35,0,12,243,184,254,67,117,66,255,230,229,123,0,201,42,110,0,134,228,178,254,186,108,118,255,58,19,154,255,82,169,62,255,114,143,115,1,239,196,50,255,173,48,193,255,147,2,84,255,150,134,147,254,95,232,73,0,109,227,52,254,191,137,10,0,40,204,30,254,76,52,97,255,164,235,126,0,254,124,188,0,74,182,21,1,121,29,35,255,241,30,7,254,85,218,214,255,7,84,150,254,81,27,117,255,160,159,152,254,66,24,221,255,227,10,60,1,141,135,102,0,208,189,150,1,117,179,92,0,132,22,136,255,120,199,28,0,21,129,79,254,182,9,65,0,218,163,169,0,246,147,198,255,107,38,144,1,78,175,205,255,214,5,250,254,47,88,29,255,164,47,204,255,43,55,6,255,131,134,207,254,116,100,214,0,96,140,75,1,106,220,144,0,195,32,28,1,172,81,5,255,199,179,52,255,37,84,203,0,170,112,174,0,11,4,91,0,69,244,27,1,117,131,92,0,33,152,175,255,140,153,107,255,251,135,43,254,87,138,4,255,198,234,147,254,121,152,84,255,205,101,155,1,157,9,25,0,72,106,17,254,108,153,0,255,189,229,186,0,193,8,176,255,174,149,209,0,238,130,29,0,233,214,126,1,61,226,102,0,57,163,4,1,198,111,51,255,45,79,78,1,115,210,10,255,218,9,25,255,158,139,198,255,211,82,187,254,80,133,83,0,157,129,230,1,243,133,134,255,40,136,16,0,77,107,79,255,183,85,92,1,177,204,202,0,163,71,147,255,152,69,190,0,172,51,188,1,250,210,172,255,211,242,113,1,89,89,26,255,64,66,111,254,116,152,42,0,161,39,27,255,54,80,254,0,106,209,115,1,103,124,97,0,221,230,98,255,31,231,6,0,178,192,120,254,15,217,203,255,124,158,79,0,112,145,247,0,92,250,48,1,163,181,193,255,37,47,142,254,144,189,165,255,46,146,240,0,6,75,128,0,41,157,200,254,87,121,213,0,1,113,236,0,5,45,250,0,144,12,82,0,31,108,231,0,225,239,119,255,167,7,189,255,187,228,132,255,110,189,34,0,94,44,204,1,162,52,197,0,78,188,241,254,57,20,141,0,244,146,47,1,206,100,51,0,125,107,148,254,27,195,77,0,152,253,90,1,7,143,144,255,51,37,31,0,34,119,38,255,7,197,118,0,153,188,211,0,151,20,116,254,245,65,52,255,180,253,110,1,47,177,209,0,161,99,17,255,118,222,202,0,125,179,252,1,123,54,126,255,145,57,191,0,55,186,121,0,10,243,138,0,205,211,229,255,125,156,241,254,148,156,185,255,227,19,188,255,124,41,32,255,31,34,206,254,17,57,83,0,204,22,37,255,42,96,98,0,119,102,184,1,3,190,28,0,110,82,218,255,200,204,192,255,201,145,118,0,117,204,146,0,132,32,98,1,192,194,121,0,106,161,248,1,237,88,124,0,23,212,26,0,205,171,90,255,248,48,216,1,141,37,230,255,124,203,0,254,158,168,30,255,214,248,21,0,112,187,7,255,75,133,239,255,74,227,243,255,250,147,70,0,214,120,162,0,167,9,179,255,22,158,18,0,218,77,209,1,97,109,81,255,244,33,179,255,57,52,57,255,65,172,210,255,249,71,209,255,142,169,238,0,158,189,153,255,174,254,103,254,98,33,14,0,141,76,230,255,113,139,52,255,15,58,212,0,168,215,201,255,248,204,215,1,223,68,160,255,57,154,183,254,47,231,121,0,106,166,137,0,81,136,138,0,165,43,51,0,231,139,61,0,57,95,59,254,118,98,25,255,151,63,236,1,94,190,250,255,169,185,114,1,5,250,58,255,75,105,97,1,215,223,134,0,113,99,163,1,128,62,112,0,99,106,147,0,163,195,10,0,33,205,182,0,214,14,174,255,129,38,231,255,53,182,223,0,98,42,159,255,247,13,40,0,188,210,177,1,6,21,0,255,255,61,148,254,137,45,129,255,89,26,116,254,126,38,114,0,251,50,242,254,121,134,128,255,204,249,167,254,165,235,215,0,202,177,243,0,133,141,62,0,240,130,190,1,110,175,255,0,0,20,146,1,37,210,121,255,7,39,130,0,142,250,84,255,141,200,207,0,9,95,104,255,11,244,174,0,134,232,126,0,167,1,123,254,16,193,149,255,232,233,239,1,213,70,112,255,252,116,160,254,242,222,220,255,205,85,227,0,7,185,58,0,118,247,63,1,116,77,177,255,62,245,200,254,63,18,37,255,107,53,232,254,50,221,211,0,162,219,7,254,2,94,43,0,182,62,182,254,160,78,200,255,135,140,170,0,235,184,228,0,175,53,138,254,80,58,77,255,152,201,2,1,63,196,34,0,5,30,184,0,171,176,154,0,121,59,206,0,38,99,39,0,172,80,77,254,0,134,151,0,186,33,241,254,94,253,223,255,44,114,252,0,108,126,57,255,201,40,13,255,39,229,27,255,39,239,23,1,151,121,51,255,153,150,248,0,10,234,174,255,118,246,4,254,200,245,38,0,69,161,242,1,16,178,150,0,113,56,130,0,171,31,105,0,26,88,108,255,49,42,106,0,251,169,66,0,69,93,149,0,20,57,254,0,164,25,111,0,90,188,90,255,204,4,197,0,40,213,50,1,212,96,132,255,88,138,180,254,228,146,124,255,184,246,247,0,65,117,86,255,253,102,210,254,254,121,36,0,137,115,3,255,60,24,216,0,134,18,29,0,59,226,97,0,176,142,71,0,7,209,161,0,189,84,51,254,155,250,72,0,213,84,235,255,45,222,224,0,238,148,143,255,170,42,53,255,78,167,117,0,186,0,40,255,125,177,103,255,69,225,66,0,227,7,88,1,75,172,6,0,169,45,227,1,16,36,70,255,50,2,9,255,139,193,22,0,143,183,231,254,218,69,50,0,236,56,161,1,213,131,42,0,138,145,44,254,136,229,40,255,49,63,35,255,61,145,245,255,101,192,2,254,232,167,113,0,152,104,38,1,121,185,218,0,121,139,211,254,119,240,35,0,65,189,217,254,187,179,162,255,160,187,230,0,62,248,14,255,60,78,97,0,255,247,163,255,225,59,91,255,107,71,58,255,241,47,33,1,50,117,236,0,219,177,63,254,244,90,179,0,35,194,215,255,189,67,50,255,23,135,129,0,104,189,37,255,185,57,194,0,35,62,231,255,220,248,108,0,12,231,178,0,143,80,91,1,131,93,101,255,144,39,2,1,255,250,178,0,5,17,236,254,139,32,46,0,204,188,38,254,245,115,52,255,191,113,73,254,191,108,69,255,22,69,245,1,23,203,178,0,170,99,170,0,65,248,111,0,37,108,153,255,64,37,69,0,0,88,62,254,89,148,144,255,191,68,224,1,241,39,53,0,41,203,237,255,145,126,194,255,221,42,253,255,25,99,151,0,97,253,223,1,74,115,49,255,6,175,72,255,59,176,203,0,124,183,249,1,228,228,99,0,129,12,207,254,168,192,195,255,204,176,16,254,152,234,171,0,77,37,85,255,33,120,135,255,142,194,227,1,31,214,58,0,213,187,125,255,232,46,60,255,190,116,42,254,151,178,19,255,51,62,237,254,204,236,193,0,194,232,60,0,172,34,157,255,189,16,184,254,103,3,95,255,141,233,36,254,41,25,11,255,21,195,166,0,118,245,45,0,67,213,149,255,159,12,18,255,187,164,227,1,160,25,5,0,12,78,195,1,43,197,225,0,48,142,41,254,196,155,60,255,223,199,18,1,145,136,156,0,252,117,169,254,145,226,238,0,239,23,107,0,109,181,188,255,230,112,49,254,73,170,237,255,231,183,227,255,80,220,20,0,194,107,127,1,127,205,101,0,46,52,197,1,210,171,36,255,88,3,90,255,56,151,141,0,96,187,255,255,42,78,200,0,254,70,70,1,244,125,168,0,204,68,138,1,124,215,70,0,102,66,200,254,17,52,228,0,117,220,143,254,203,248,123,0,56,18,174,255,186,151,164,255,51,232,208,1,160,228,43,255,249,29,25,1,68,190,63,0,103,230,9,106,133,174,103,187,114,243,110,60,58,245,79,165,127,82,14,81,140,104,5,155,171,217,131,31,25,205,224,91,152,47,138,66,145,68,55,113,207,251,192,181,165,219,181,233,91,194,86,57,241,17,241,89,164,130,63,146,213,94,28,171,152,170,7,216,1,91,131,18,190,133,49,36,195,125,12,85,116,93,190,114,254,177,222,128,167,6,220,155,116,241,155,193,193,105,155,228,134,71,190,239,198,157,193,15,204,161,12,36,111,44,233,45,170,132,116,74,220,169,176,92,218,136,249,118,82,81,62,152,109,198,49,168,200,39,3,176,199,127,89,191,243,11,224,198,71,145,167,213,81,99,202,6,103,41,41,20,133,10,183,39,56,33,27,46,252,109,44,77,19,13,56,83,84,115,10,101,187,10,106,118,46,201,194,129,133,44,114,146,161,232,191,162,75,102,26,168,112,139,75,194,163,81,108,199,25,232,146,209,36,6,153,214,133,53,14,244,112,160,106,16,22,193,164,25,8,108,55,30,76,119,72,39,181,188,176,52,179,12,28,57,74,170,216,78,79,202,156,91,243,111,46,104,238,130,143,116,111,99,165,120,20,120,200,132,8,2,199,140,250,255,190,144,235,108,80,164,247,163,249,190,242,120,113,198,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,48,138,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,104,109,97,99,115,104,97,53,49,50,50,53,54,0,99,117,114,118,101,50,53,53,49,57,120,115,97,108,115,97,50,48,112,111,108,121,49,51,48,53,0,83,45,62,98,117,102,108,101,110,32,60,61,32,66,76,65,75,69,50,66,95,66,76,79,67,75,66,89,84,69,83,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,47,98,108,97,107,101,50,98,47,114,101,102,47,98,108,97,107,101,50,98,45,114,101,102,46,99,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,95,102,105,110,97,108,0,111,117,116,108,101,110,32,60,61,32,85,73,78,84,56,95,77,65,88,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,47,98,108,97,107,101,50,98,47,114,101,102,47,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,46,99,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,0,107,101,121,108,101,110,32,60,61,32,85,73,78,84,56,95,77,65,88,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,115,97,108,116,95,112,101,114,115,111,110,97,108,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,105,110,105,116,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,105,110,105,116,95,115,97,108,116,95,112,101,114,115,111,110,97,108,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,102,105,110,97,108,0,115,104,97,53,49,50,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,98,108,97,107,101,50,98,0,120,50,53,53,49,57,98,108,97,107,101,50,98,0,112,111,108,121,49,51,48,53,0,36,97,114,103,111,110,50,105,0,36,118,61,0,36,109,61,0,44,116,61,0,44,112,61,0,36,97,114,103,111,110,50,105,36,118,61,0,36,97,114,103,111,110,50,105,36,0,97,114,103,111,110,50,105,0,46,47,48,49,50,51,52,53,54,55,56,57,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,0,36,55,36,0,99,117,114,118,101,50,53,53,49,57,0,120,115,97,108,115,97,50,48,112,111,108,121,49,51,48,53,0,115,105,112,104,97,115,104,50,52,0,101,100,50,53,53,49,57,0,237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,83,105,103,69,100,50,53,53,49,57,32,110,111,32,69,100,50,53,53,49,57,32,99,111,108,108,105,115,105,111,110,115,1,0,120,115,97,108,115,97,50,48,0,106,115,0,123,32,114,101,116,117,114,110,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,40,41,59,32,125,0,123,32,105,102,32,40,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,61,61,32,117,110,100,101,102,105,110,101,100,41,32,123,32,116,114,121,32,123,32,118,97,114,32,119,105,110,100,111,119,95,32,61,32,34,111,98,106,101,99,116,34,32,61,61,61,32,116,121,112,101,111,102,32,119,105,110,100,111,119,32,63,32,119,105,110,100,111,119,32,58,32,115,101,108,102,44,32,99,114,121,112,116,111,95,32,61,32,116,121,112,101,111,102,32,119,105,110,100,111,119,95,46,99,114,121,112,116,111,32,33,61,61,32,34,117,110,100,101,102,105,110,101,100,34,32,63,32,119,105,110,100,111,119,95,46,99,114,121,112,116,111,32,58,32,119,105,110,100,111,119,95,46,109,115,67,114,121,112,116,111,44,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,32,61,32,102,117,110,99,116,105,111,110,40,41,32,123,32,118,97,114,32,98,117,102,32,61,32,110,101,119,32,85,105,110,116,51,50,65,114,114,97,121,40,49,41,59,32,99,114,121,112,116,111,95,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,115,40,98,117,102,41,59,32,114,101,116,117,114,110,32,98,117,102,91,48,93,32,62,62,62,32,48,59,32,125,59,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,40,41,59,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,59,32,125,32,99,97,116,99,104,32,40,101,41,32,123,32,116,114,121,32,123,32,118,97,114,32,99,114,121,112,116,111,32,61,32,114,101,113,117,105,114,101,40,39,99,114,121,112,116,111,39,41,44,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,32,61,32,102,117,110,99,116,105,111,110,40,41,32,123,32,118,97,114,32,98,117,102,32,61,32,99,114,121,112,116,111,46,114,97,110,100,111,109,66,121,116,101,115,40,52,41,59,32,114,101,116,117,114,110,32,40,98,117,102,91,48,93,32,60,60,32,50,52,32,124,32,98,117,102,91,49,93,32,60,60,32,49,54,32,124,32,98,117,102,91,50,93,32,60,60,32,56,32,124,32,98,117,102,91,51,93,41,32,62,62,62,32,48,59,32,125,59,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,40,41,59,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,59,32,125,32,99,97,116,99,104,32,40,101,41,32,123,32,116,104,114,111,119,32,39,78,111,32,115,101,99,117,114,101,32,114,97,110,100,111,109,32,110,117,109,98,101,114,32,103,101,110,101,114,97,116,111,114,32,102,111,117,110,100,39,59,32,125,32,125,32,125,32,125,0,76,105,98,115,111,100,105,117,109,68,82,71,98,117,102,95,108,101,110,32,60,61,32,83,73,90,69,95,77,65,88,0,114,97,110,100,111,109,98,121,116,101,115,47,114,97,110,100,111,109,98,121,116,101,115,46,99,0,114,97,110,100,111,109,98,121,116,101,115,0,49,46,48,46,49,50,0,0,0,0,12,0,0,0,0,0,0,0,4,0,0,0,8,15,11,7,3,14,10,6,2,13,9,5,1,12,8,4,0,3,3,3,3,7,7,7,7,11,11,11,11,15,15,15,15,3,2,1,0,7,6,5,4,11,10,9,8,15,14,13,12,12,8,4,0,13,9,5,1,14,10,6,2,15,11,7,3,1,2,3,0,6,7,4,5,11,8,9,10,12,13,14,15,15,10,5,0,14,9,4,3,13,8,7,2,12,11,6,1],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+30720);var tempDoublePtr=STATICTOP;STATICTOP+=16;Module["_bitshift64Ashr"]=_bitshift64Ashr;Module["_i64Subtract"]=_i64Subtract;Module["_i64Add"]=_i64Add;Module["_memset"]=_memset;Module["_bitshift64Lshr"]=_bitshift64Lshr;Module["_bitshift64Shl"]=_bitshift64Shl;function _abort(){Module["abort"]()}function ___assert_fail(condition,filename,line,func){ABORT=true;throw"Assertion failed: "+Pointer_stringify(condition)+", at: "+[filename?Pointer_stringify(filename):"unknown filename",line,func?Pointer_stringify(func):"unknown function"]+" at "+stackTrace()}function _emscripten_memcpy_big(dest,src,num){HEAPU8.set(HEAPU8.subarray(src,src+num),dest);return dest}Module["_memcpy"]=_memcpy;var cttz_i8=allocate([8,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,7,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0],"i8",ALLOC_STATIC);Module["_llvm_cttz_i32"]=_llvm_cttz_i32;Module["___udivmoddi4"]=___udivmoddi4;Module["___udivdi3"]=___udivdi3;Module["___muldsi3"]=___muldsi3;Module["___muldi3"]=___muldi3;function ___setErrNo(value){if(Module["___errno_location"])HEAP32[Module["___errno_location"]()>>2]=value;return value}var ERRNO_CODES={EPERM:1,ENOENT:2,ESRCH:3,EINTR:4,EIO:5,ENXIO:6,E2BIG:7,ENOEXEC:8,EBADF:9,ECHILD:10,EAGAIN:11,EWOULDBLOCK:11,ENOMEM:12,EACCES:13,EFAULT:14,ENOTBLK:15,EBUSY:16,EEXIST:17,EXDEV:18,ENODEV:19,ENOTDIR:20,EISDIR:21,EINVAL:22,ENFILE:23,EMFILE:24,ENOTTY:25,ETXTBSY:26,EFBIG:27,ENOSPC:28,ESPIPE:29,EROFS:30,EMLINK:31,EPIPE:32,EDOM:33,ERANGE:34,ENOMSG:42,EIDRM:43,ECHRNG:44,EL2NSYNC:45,EL3HLT:46,EL3RST:47,ELNRNG:48,EUNATCH:49,ENOCSI:50,EL2HLT:51,EDEADLK:35,ENOLCK:37,EBADE:52,EBADR:53,EXFULL:54,ENOANO:55,EBADRQC:56,EBADSLT:57,EDEADLOCK:35,EBFONT:59,ENOSTR:60,ENODATA:61,ETIME:62,ENOSR:63,ENONET:64,ENOPKG:65,EREMOTE:66,ENOLINK:67,EADV:68,ESRMNT:69,ECOMM:70,EPROTO:71,EMULTIHOP:72,EDOTDOT:73,EBADMSG:74,ENOTUNIQ:76,EBADFD:77,EREMCHG:78,ELIBACC:79,ELIBBAD:80,ELIBSCN:81,ELIBMAX:82,ELIBEXEC:83,ENOSYS:38,ENOTEMPTY:39,ENAMETOOLONG:36,ELOOP:40,EOPNOTSUPP:95,EPFNOSUPPORT:96,ECONNRESET:104,ENOBUFS:105,EAFNOSUPPORT:97,EPROTOTYPE:91,ENOTSOCK:88,ENOPROTOOPT:92,ESHUTDOWN:108,ECONNREFUSED:111,EADDRINUSE:98,ECONNABORTED:103,ENETUNREACH:101,ENETDOWN:100,ETIMEDOUT:110,EHOSTDOWN:112,EHOSTUNREACH:113,EINPROGRESS:115,EALREADY:114,EDESTADDRREQ:89,EMSGSIZE:90,EPROTONOSUPPORT:93,ESOCKTNOSUPPORT:94,EADDRNOTAVAIL:99,ENETRESET:102,EISCONN:106,ENOTCONN:107,ETOOMANYREFS:109,EUSERS:87,EDQUOT:122,ESTALE:116,ENOTSUP:95,ENOMEDIUM:123,EILSEQ:84,EOVERFLOW:75,ECANCELED:125,ENOTRECOVERABLE:131,EOWNERDEAD:130,ESTRPIPE:86};function _sysconf(name){switch(name){case 30:return PAGE_SIZE;case 85:var maxHeapSize=2*1024*1024*1024-16777216;maxHeapSize=HEAPU8.length;return maxHeapSize/PAGE_SIZE;case 132:case 133:case 12:case 137:case 138:case 15:case 235:case 16:case 17:case 18:case 19:case 20:case 149:case 13:case 10:case 236:case 153:case 9:case 21:case 22:case 159:case 154:case 14:case 77:case 78:case 139:case 80:case 81:case 82:case 68:case 67:case 164:case 11:case 29:case 47:case 48:case 95:case 52:case 51:case 46:return 200809;case 79:return 0;case 27:case 246:case 127:case 128:case 23:case 24:case 160:case 161:case 181:case 182:case 242:case 183:case 184:case 243:case 244:case 245:case 165:case 178:case 179:case 49:case 50:case 168:case 169:case 175:case 170:case 171:case 172:case 97:case 76:case 32:case 173:case 35:return-1;case 176:case 177:case 7:case 155:case 8:case 157:case 125:case 126:case 92:case 93:case 129:case 130:case 131:case 94:case 91:return 1;case 74:case 60:case 69:case 70:case 4:return 1024;case 31:case 42:case 72:return 32;case 87:case 26:case 33:return 2147483647;case 34:case 1:return 47839;case 38:case 36:return 99;case 43:case 37:return 2048;case 0:return 2097152;case 3:return 65536;case 28:return 32768;case 44:return 32767;case 75:return 16384;case 39:return 1e3;case 89:return 700;case 71:return 256;case 40:return 255;case 2:return 100;case 180:return 64;case 25:return 20;case 5:return 16;case 6:return 6;case 73:return 4;case 84:{if(typeof navigator==="object")return navigator["hardwareConcurrency"]||1;return 1}}___setErrNo(ERRNO_CODES.EINVAL);return-1}Module["_sbrk"]=_sbrk;Module["_memmove"]=_memmove;Module["___uremdi3"]=___uremdi3;DYNAMICTOP_PTR=allocate(1,"i32",ALLOC_STATIC);STACK_BASE=STACKTOP=Runtime.alignMemory(STATICTOP);STACK_MAX=STACK_BASE+TOTAL_STACK;DYNAMIC_BASE=Runtime.alignMemory(STACK_MAX);HEAP32[DYNAMICTOP_PTR>>2]=DYNAMIC_BASE;staticSealed=true;Module.asmGlobalArg={"Math":Math,"Int8Array":Int8Array,"Int16Array":Int16Array,"Int32Array":Int32Array,"Uint8Array":Uint8Array,"Uint16Array":Uint16Array,"Uint32Array":Uint32Array,"Float32Array":Float32Array,"Float64Array":Float64Array,"NaN":NaN,"Infinity":Infinity};Module.asmLibraryArg={"abort":abort,"assert":assert,"enlargeMemory":enlargeMemory,"getTotalMemory":getTotalMemory,"abortOnCannotGrowMemory":abortOnCannotGrowMemory,"_emscripten_asm_const_i":_emscripten_asm_const_i,"_sysconf":_sysconf,"_abort":_abort,"___setErrNo":___setErrNo,"_emscripten_memcpy_big":_emscripten_memcpy_big,"_emscripten_asm_const_v":_emscripten_asm_const_v,"___assert_fail":___assert_fail,"DYNAMICTOP_PTR":DYNAMICTOP_PTR,"tempDoublePtr":tempDoublePtr,"ABORT":ABORT,"STACKTOP":STACKTOP,"STACK_MAX":STACK_MAX,"cttz_i8":cttz_i8};// EMSCRIPTEN_START_ASM +var Module;if(!Module)Module=(typeof Module!=="undefined"?Module:null)||{};var moduleOverrides={};for(var key in Module){if(Module.hasOwnProperty(key)){moduleOverrides[key]=Module[key]}}var ENVIRONMENT_IS_WEB=false;var ENVIRONMENT_IS_WORKER=false;var ENVIRONMENT_IS_NODE=false;var ENVIRONMENT_IS_SHELL=false;if(Module["ENVIRONMENT"]){if(Module["ENVIRONMENT"]==="WEB"){ENVIRONMENT_IS_WEB=true}else if(Module["ENVIRONMENT"]==="WORKER"){ENVIRONMENT_IS_WORKER=true}else if(Module["ENVIRONMENT"]==="NODE"){ENVIRONMENT_IS_NODE=true}else if(Module["ENVIRONMENT"]==="SHELL"){ENVIRONMENT_IS_SHELL=true}else{throw new Error("The provided Module['ENVIRONMENT'] value is not valid. It must be one of: WEB|WORKER|NODE|SHELL.")}}else{ENVIRONMENT_IS_WEB=typeof window==="object";ENVIRONMENT_IS_WORKER=typeof importScripts==="function";ENVIRONMENT_IS_NODE=typeof process==="object"&&"function"==="function"&&!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_WORKER;ENVIRONMENT_IS_SHELL=!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_NODE&&!ENVIRONMENT_IS_WORKER}if(ENVIRONMENT_IS_NODE){if(!Module["print"])Module["print"]=console.log;if(!Module["printErr"])Module["printErr"]=console.warn;var nodeFS;var nodePath;Module["read"]=function shell_read(filename,binary){if(!nodeFS)nodeFS=__webpack_require__(417);if(!nodePath)nodePath=__webpack_require__(418);filename=nodePath["normalize"](filename);var ret=nodeFS["readFileSync"](filename);return binary?ret:ret.toString()};Module["readBinary"]=function readBinary(filename){var ret=Module["read"](filename,true);if(!ret.buffer){ret=new Uint8Array(ret)}assert(ret.buffer);return ret};Module["load"]=function load(f){globalEval(read(f))};if(!Module["thisProgram"]){if(process["argv"].length>1){Module["thisProgram"]=process["argv"][1].replace(/\\/g,"/")}else{Module["thisProgram"]="unknown-program"}}Module["arguments"]=process["argv"].slice(2);if(true){module["exports"]=Module}process["on"]("uncaughtException",(function(ex){if(!(ex instanceof ExitStatus)){throw ex}}));Module["inspect"]=(function(){return"[Emscripten Module object]"})}else if(ENVIRONMENT_IS_SHELL){if(!Module["print"])Module["print"]=print;if(typeof printErr!="undefined")Module["printErr"]=printErr;if(typeof read!="undefined"){Module["read"]=read}else{Module["read"]=function shell_read(){throw"no read() available"}}Module["readBinary"]=function readBinary(f){if(typeof readbuffer==="function"){return new Uint8Array(readbuffer(f))}var data=read(f,"binary");assert(typeof data==="object");return data};if(typeof scriptArgs!="undefined"){Module["arguments"]=scriptArgs}else if(typeof arguments!="undefined"){Module["arguments"]=arguments}if(typeof quit==="function"){Module["quit"]=(function(status,toThrow){quit(status)})}}else if(ENVIRONMENT_IS_WEB||ENVIRONMENT_IS_WORKER){Module["read"]=function shell_read(url){var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.send(null);return xhr.responseText};if(ENVIRONMENT_IS_WORKER){Module["readBinary"]=function readBinary(url){var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.responseType="arraybuffer";xhr.send(null);return xhr.response}}Module["readAsync"]=function readAsync(url,onload,onerror){var xhr=new XMLHttpRequest;xhr.open("GET",url,true);xhr.responseType="arraybuffer";xhr.onload=function xhr_onload(){if(xhr.status==200||xhr.status==0&&xhr.response){onload(xhr.response)}else{onerror()}};xhr.onerror=onerror;xhr.send(null)};if(typeof arguments!="undefined"){Module["arguments"]=arguments}if(typeof console!=="undefined"){if(!Module["print"])Module["print"]=function shell_print(x){console.log(x)};if(!Module["printErr"])Module["printErr"]=function shell_printErr(x){console.warn(x)}}else{var TRY_USE_DUMP=false;if(!Module["print"])Module["print"]=TRY_USE_DUMP&&typeof dump!=="undefined"?(function(x){dump(x)}):(function(x){})}if(ENVIRONMENT_IS_WORKER){Module["load"]=importScripts}if(typeof Module["setWindowTitle"]==="undefined"){Module["setWindowTitle"]=(function(title){document.title=title})}}else{throw"Unknown runtime environment. Where are we?"}function globalEval(x){abort("NO_DYNAMIC_EXECUTION=1 was set, cannot eval")}if(!Module["load"]&&Module["read"]){Module["load"]=function load(f){globalEval(Module["read"](f))}}if(!Module["print"]){Module["print"]=(function(){})}if(!Module["printErr"]){Module["printErr"]=Module["print"]}if(!Module["arguments"]){Module["arguments"]=[]}if(!Module["thisProgram"]){Module["thisProgram"]="./this.program"}if(!Module["quit"]){Module["quit"]=(function(status,toThrow){throw toThrow})}Module.print=Module["print"];Module.printErr=Module["printErr"];Module["preRun"]=[];Module["postRun"]=[];for(var key in moduleOverrides){if(moduleOverrides.hasOwnProperty(key)){Module[key]=moduleOverrides[key]}}moduleOverrides=undefined;var Runtime={setTempRet0:(function(value){tempRet0=value;return value}),getTempRet0:(function(){return tempRet0}),stackSave:(function(){return STACKTOP}),stackRestore:(function(stackTop){STACKTOP=stackTop}),getNativeTypeSize:(function(type){switch(type){case"i1":case"i8":return 1;case"i16":return 2;case"i32":return 4;case"i64":return 8;case"float":return 4;case"double":return 8;default:{if(type[type.length-1]==="*"){return Runtime.QUANTUM_SIZE}else if(type[0]==="i"){var bits=parseInt(type.substr(1));assert(bits%8===0);return bits/8}else{return 0}}}}),getNativeFieldSize:(function(type){return Math.max(Runtime.getNativeTypeSize(type),Runtime.QUANTUM_SIZE)}),STACK_ALIGN:16,prepVararg:(function(ptr,type){if(type==="double"||type==="i64"){if(ptr&7){assert((ptr&7)===4);ptr+=4}}else{assert((ptr&3)===0)}return ptr}),getAlignSize:(function(type,size,vararg){if(!vararg&&(type=="i64"||type=="double"))return 8;if(!type)return Math.min(size,8);return Math.min(size||(type?Runtime.getNativeFieldSize(type):0),Runtime.QUANTUM_SIZE)}),dynCall:(function(sig,ptr,args){if(args&&args.length){return Module["dynCall_"+sig].apply(null,[ptr].concat(args))}else{return Module["dynCall_"+sig].call(null,ptr)}}),functionPointers:[null,null,null,null,null,null,null,null],addFunction:(function(func){for(var i=0;i<Runtime.functionPointers.length;i++){if(!Runtime.functionPointers[i]){Runtime.functionPointers[i]=func;return 1*(1+i)}}throw"Finished up all reserved function pointers. Use a higher value for RESERVED_FUNCTION_POINTERS."}),removeFunction:(function(index){Runtime.functionPointers[(index-1)/1]=null}),warnOnce:(function(text){if(!Runtime.warnOnce.shown)Runtime.warnOnce.shown={};if(!Runtime.warnOnce.shown[text]){Runtime.warnOnce.shown[text]=1;Module.printErr(text)}}),funcWrappers:{},getFuncWrapper:(function(func,sig){assert(sig);if(!Runtime.funcWrappers[sig]){Runtime.funcWrappers[sig]={}}var sigCache=Runtime.funcWrappers[sig];if(!sigCache[func]){if(sig.length===1){sigCache[func]=function dynCall_wrapper(){return Runtime.dynCall(sig,func)}}else if(sig.length===2){sigCache[func]=function dynCall_wrapper(arg){return Runtime.dynCall(sig,func,[arg])}}else{sigCache[func]=function dynCall_wrapper(){return Runtime.dynCall(sig,func,Array.prototype.slice.call(arguments))}}}return sigCache[func]}),getCompilerSetting:(function(name){throw"You must build with -s RETAIN_COMPILER_SETTINGS=1 for Runtime.getCompilerSetting or emscripten_get_compiler_setting to work"}),stackAlloc:(function(size){var ret=STACKTOP;STACKTOP=STACKTOP+size|0;STACKTOP=STACKTOP+15&-16;return ret}),staticAlloc:(function(size){var ret=STATICTOP;STATICTOP=STATICTOP+size|0;STATICTOP=STATICTOP+15&-16;return ret}),dynamicAlloc:(function(size){var ret=HEAP32[DYNAMICTOP_PTR>>2];var end=(ret+size+15|0)&-16;HEAP32[DYNAMICTOP_PTR>>2]=end;if(end>=TOTAL_MEMORY){var success=enlargeMemory();if(!success){HEAP32[DYNAMICTOP_PTR>>2]=ret;return 0}}return ret}),alignMemory:(function(size,quantum){var ret=size=Math.ceil(size/(quantum?quantum:16))*(quantum?quantum:16);return ret}),makeBigInt:(function(low,high,unsigned){var ret=unsigned?+(low>>>0)+ +(high>>>0)*+4294967296:+(low>>>0)+ +(high|0)*+4294967296;return ret}),GLOBAL_BASE:8,QUANTUM_SIZE:4,__dummy__:0};Module["Runtime"]=Runtime;var ABORT=0;var EXITSTATUS=0;function assert(condition,text){if(!condition){abort("Assertion failed: "+text)}}function getCFunc(ident){var func=Module["_"+ident];if(!func){abort("NO_DYNAMIC_EXECUTION=1 was set, cannot eval")}assert(func,"Cannot call unknown function "+ident+" (perhaps LLVM optimizations or closure removed it?)");return func}var cwrap,ccall;((function(){var JSfuncs={"stackSave":(function(){Runtime.stackSave()}),"stackRestore":(function(){Runtime.stackRestore()}),"arrayToC":(function(arr){var ret=Runtime.stackAlloc(arr.length);writeArrayToMemory(arr,ret);return ret}),"stringToC":(function(str){var ret=0;if(str!==null&&str!==undefined&&str!==0){var len=(str.length<<2)+1;ret=Runtime.stackAlloc(len);stringToUTF8(str,ret,len)}return ret})};var toC={"string":JSfuncs["stringToC"],"array":JSfuncs["arrayToC"]};ccall=function ccallFunc(ident,returnType,argTypes,args,opts){var func=getCFunc(ident);var cArgs=[];var stack=0;if(args){for(var i=0;i<args.length;i++){var converter=toC[argTypes[i]];if(converter){if(stack===0)stack=Runtime.stackSave();cArgs[i]=converter(args[i])}else{cArgs[i]=args[i]}}}var ret=func.apply(null,cArgs);if(returnType==="string")ret=Pointer_stringify(ret);if(stack!==0){if(opts&&opts.async){EmterpreterAsync.asyncFinalizers.push((function(){Runtime.stackRestore(stack)}));return}Runtime.stackRestore(stack)}return ret};cwrap=function cwrap(ident,returnType,argTypes){return(function(){return ccall(ident,returnType,argTypes,arguments)})}}))();Module["ccall"]=ccall;Module["cwrap"]=cwrap;function setValue(ptr,value,type,noSafe){type=type||"i8";if(type.charAt(type.length-1)==="*")type="i32";switch(type){case"i1":HEAP8[ptr>>0]=value;break;case"i8":HEAP8[ptr>>0]=value;break;case"i16":HEAP16[ptr>>1]=value;break;case"i32":HEAP32[ptr>>2]=value;break;case"i64":tempI64=[value>>>0,(tempDouble=value,+Math_abs(tempDouble)>=+1?tempDouble>+0?(Math_min(+Math_floor(tempDouble/+4294967296),+4294967295)|0)>>>0:~~+Math_ceil((tempDouble- +(~~tempDouble>>>0))/+4294967296)>>>0:0)],HEAP32[ptr>>2]=tempI64[0],HEAP32[ptr+4>>2]=tempI64[1];break;case"float":HEAPF32[ptr>>2]=value;break;case"double":HEAPF64[ptr>>3]=value;break;default:abort("invalid type for setValue: "+type)}}Module["setValue"]=setValue;function getValue(ptr,type,noSafe){type=type||"i8";if(type.charAt(type.length-1)==="*")type="i32";switch(type){case"i1":return HEAP8[ptr>>0];case"i8":return HEAP8[ptr>>0];case"i16":return HEAP16[ptr>>1];case"i32":return HEAP32[ptr>>2];case"i64":return HEAP32[ptr>>2];case"float":return HEAPF32[ptr>>2];case"double":return HEAPF64[ptr>>3];default:abort("invalid type for setValue: "+type)}return null}Module["getValue"]=getValue;var ALLOC_NORMAL=0;var ALLOC_STACK=1;var ALLOC_STATIC=2;var ALLOC_DYNAMIC=3;var ALLOC_NONE=4;Module["ALLOC_NORMAL"]=ALLOC_NORMAL;Module["ALLOC_STACK"]=ALLOC_STACK;Module["ALLOC_STATIC"]=ALLOC_STATIC;Module["ALLOC_DYNAMIC"]=ALLOC_DYNAMIC;Module["ALLOC_NONE"]=ALLOC_NONE;function allocate(slab,types,allocator,ptr){var zeroinit,size;if(typeof slab==="number"){zeroinit=true;size=slab}else{zeroinit=false;size=slab.length}var singleType=typeof types==="string"?types:null;var ret;if(allocator==ALLOC_NONE){ret=ptr}else{ret=[typeof _malloc==="function"?_malloc:Runtime.staticAlloc,Runtime.stackAlloc,Runtime.staticAlloc,Runtime.dynamicAlloc][allocator===undefined?ALLOC_STATIC:allocator](Math.max(size,singleType?1:types.length))}if(zeroinit){var ptr=ret,stop;assert((ret&3)==0);stop=ret+(size&~3);for(;ptr<stop;ptr+=4){HEAP32[ptr>>2]=0}stop=ret+size;while(ptr<stop){HEAP8[ptr++>>0]=0}return ret}if(singleType==="i8"){if(slab.subarray||slab.slice){HEAPU8.set(slab,ret)}else{HEAPU8.set(new Uint8Array(slab),ret)}return ret}var i=0,type,typeSize,previousType;while(i<size){var curr=slab[i];if(typeof curr==="function"){curr=Runtime.getFunctionIndex(curr)}type=singleType||types[i];if(type===0){i++;continue}if(type=="i64")type="i32";setValue(ret+i,curr,type);if(previousType!==type){typeSize=Runtime.getNativeTypeSize(type);previousType=type}i+=typeSize}return ret}Module["allocate"]=allocate;function getMemory(size){if(!staticSealed)return Runtime.staticAlloc(size);if(!runtimeInitialized)return Runtime.dynamicAlloc(size);return _malloc(size)}Module["getMemory"]=getMemory;function Pointer_stringify(ptr,length){if(length===0||!ptr)return"";var hasUtf=0;var t;var i=0;while(1){t=HEAPU8[ptr+i>>0];hasUtf|=t;if(t==0&&!length)break;i++;if(length&&i==length)break}if(!length)length=i;var ret="";if(hasUtf<128){var MAX_CHUNK=1024;var curr;while(length>0){curr=String.fromCharCode.apply(String,HEAPU8.subarray(ptr,ptr+Math.min(length,MAX_CHUNK)));ret=ret?ret+curr:curr;ptr+=MAX_CHUNK;length-=MAX_CHUNK}return ret}return Module["UTF8ToString"](ptr)}Module["Pointer_stringify"]=Pointer_stringify;function AsciiToString(ptr){var str="";while(1){var ch=HEAP8[ptr++>>0];if(!ch)return str;str+=String.fromCharCode(ch)}}Module["AsciiToString"]=AsciiToString;function stringToAscii(str,outPtr){return writeAsciiToMemory(str,outPtr,false)}Module["stringToAscii"]=stringToAscii;var UTF8Decoder=typeof TextDecoder!=="undefined"?new TextDecoder("utf8"):undefined;function UTF8ArrayToString(u8Array,idx){var endPtr=idx;while(u8Array[endPtr])++endPtr;if(endPtr-idx>16&&u8Array.subarray&&UTF8Decoder){return UTF8Decoder.decode(u8Array.subarray(idx,endPtr))}else{var u0,u1,u2,u3,u4,u5;var str="";while(1){u0=u8Array[idx++];if(!u0)return str;if(!(u0&128)){str+=String.fromCharCode(u0);continue}u1=u8Array[idx++]&63;if((u0&224)==192){str+=String.fromCharCode((u0&31)<<6|u1);continue}u2=u8Array[idx++]&63;if((u0&240)==224){u0=(u0&15)<<12|u1<<6|u2}else{u3=u8Array[idx++]&63;if((u0&248)==240){u0=(u0&7)<<18|u1<<12|u2<<6|u3}else{u4=u8Array[idx++]&63;if((u0&252)==248){u0=(u0&3)<<24|u1<<18|u2<<12|u3<<6|u4}else{u5=u8Array[idx++]&63;u0=(u0&1)<<30|u1<<24|u2<<18|u3<<12|u4<<6|u5}}}if(u0<65536){str+=String.fromCharCode(u0)}else{var ch=u0-65536;str+=String.fromCharCode(55296|ch>>10,56320|ch&1023)}}}}Module["UTF8ArrayToString"]=UTF8ArrayToString;function UTF8ToString(ptr){return UTF8ArrayToString(HEAPU8,ptr)}Module["UTF8ToString"]=UTF8ToString;function stringToUTF8Array(str,outU8Array,outIdx,maxBytesToWrite){if(!(maxBytesToWrite>0))return 0;var startIdx=outIdx;var endIdx=outIdx+maxBytesToWrite-1;for(var i=0;i<str.length;++i){var u=str.charCodeAt(i);if(u>=55296&&u<=57343)u=65536+((u&1023)<<10)|str.charCodeAt(++i)&1023;if(u<=127){if(outIdx>=endIdx)break;outU8Array[outIdx++]=u}else if(u<=2047){if(outIdx+1>=endIdx)break;outU8Array[outIdx++]=192|u>>6;outU8Array[outIdx++]=128|u&63}else if(u<=65535){if(outIdx+2>=endIdx)break;outU8Array[outIdx++]=224|u>>12;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else if(u<=2097151){if(outIdx+3>=endIdx)break;outU8Array[outIdx++]=240|u>>18;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else if(u<=67108863){if(outIdx+4>=endIdx)break;outU8Array[outIdx++]=248|u>>24;outU8Array[outIdx++]=128|u>>18&63;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}else{if(outIdx+5>=endIdx)break;outU8Array[outIdx++]=252|u>>30;outU8Array[outIdx++]=128|u>>24&63;outU8Array[outIdx++]=128|u>>18&63;outU8Array[outIdx++]=128|u>>12&63;outU8Array[outIdx++]=128|u>>6&63;outU8Array[outIdx++]=128|u&63}}outU8Array[outIdx]=0;return outIdx-startIdx}Module["stringToUTF8Array"]=stringToUTF8Array;function stringToUTF8(str,outPtr,maxBytesToWrite){return stringToUTF8Array(str,HEAPU8,outPtr,maxBytesToWrite)}Module["stringToUTF8"]=stringToUTF8;function lengthBytesUTF8(str){var len=0;for(var i=0;i<str.length;++i){var u=str.charCodeAt(i);if(u>=55296&&u<=57343)u=65536+((u&1023)<<10)|str.charCodeAt(++i)&1023;if(u<=127){++len}else if(u<=2047){len+=2}else if(u<=65535){len+=3}else if(u<=2097151){len+=4}else if(u<=67108863){len+=5}else{len+=6}}return len}Module["lengthBytesUTF8"]=lengthBytesUTF8;var UTF16Decoder=typeof TextDecoder!=="undefined"?new TextDecoder("utf-16le"):undefined;function demangle(func){var __cxa_demangle_func=Module["___cxa_demangle"]||Module["__cxa_demangle"];if(__cxa_demangle_func){try{var s=func.substr(1);var len=lengthBytesUTF8(s)+1;var buf=_malloc(len);stringToUTF8(s,buf,len);var status=_malloc(4);var ret=__cxa_demangle_func(buf,0,0,status);if(getValue(status,"i32")===0&&ret){return Pointer_stringify(ret)}}catch(e){}finally{if(buf)_free(buf);if(status)_free(status);if(ret)_free(ret)}return func}Runtime.warnOnce("warning: build with -s DEMANGLE_SUPPORT=1 to link in libcxxabi demangling");return func}function demangleAll(text){var regex=/__Z[\w\d_]+/g;return text.replace(regex,(function(x){var y=demangle(x);return x===y?x:x+" ["+y+"]"}))}function jsStackTrace(){var err=new Error;if(!err.stack){try{throw new Error(0)}catch(e){err=e}if(!err.stack){return"(no stack trace available)"}}return err.stack.toString()}function stackTrace(){var js=jsStackTrace();if(Module["extraStackTrace"])js+="\n"+Module["extraStackTrace"]();return demangleAll(js)}Module["stackTrace"]=stackTrace;var PAGE_SIZE=16384;var HEAP,buffer,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64;function updateGlobalBufferViews(){Module["HEAP8"]=HEAP8=new Int8Array(buffer);Module["HEAP16"]=HEAP16=new Int16Array(buffer);Module["HEAP32"]=HEAP32=new Int32Array(buffer);Module["HEAPU8"]=HEAPU8=new Uint8Array(buffer);Module["HEAPU16"]=HEAPU16=new Uint16Array(buffer);Module["HEAPU32"]=HEAPU32=new Uint32Array(buffer);Module["HEAPF32"]=HEAPF32=new Float32Array(buffer);Module["HEAPF64"]=HEAPF64=new Float64Array(buffer)}var STATIC_BASE,STATICTOP,staticSealed;var STACK_BASE,STACKTOP,STACK_MAX;var DYNAMIC_BASE,DYNAMICTOP_PTR;STATIC_BASE=STATICTOP=STACK_BASE=STACKTOP=STACK_MAX=DYNAMIC_BASE=DYNAMICTOP_PTR=0;staticSealed=false;function abortOnCannotGrowMemory(){abort("Cannot enlarge memory arrays. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value "+TOTAL_MEMORY+", (2) compile with -s ALLOW_MEMORY_GROWTH=1 which allows increasing the size at runtime but prevents some optimizations, (3) set Module.TOTAL_MEMORY to a higher value before the program runs, or (4) if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 ")}function enlargeMemory(){abortOnCannotGrowMemory()}var TOTAL_STACK=Module["TOTAL_STACK"]||5242880;var TOTAL_MEMORY=Module["TOTAL_MEMORY"]||67108864;if(TOTAL_MEMORY<TOTAL_STACK)Module.printErr("TOTAL_MEMORY should be larger than TOTAL_STACK, was "+TOTAL_MEMORY+"! (TOTAL_STACK="+TOTAL_STACK+")");if(Module["buffer"]){buffer=Module["buffer"]}else{{buffer=new ArrayBuffer(TOTAL_MEMORY)}}updateGlobalBufferViews();function getTotalMemory(){return TOTAL_MEMORY}HEAP32[0]=1668509029;HEAP16[1]=25459;if(HEAPU8[2]!==115||HEAPU8[3]!==99)throw"Runtime error: expected the system to be little-endian!";Module["HEAP"]=HEAP;Module["buffer"]=buffer;Module["HEAP8"]=HEAP8;Module["HEAP16"]=HEAP16;Module["HEAP32"]=HEAP32;Module["HEAPU8"]=HEAPU8;Module["HEAPU16"]=HEAPU16;Module["HEAPU32"]=HEAPU32;Module["HEAPF32"]=HEAPF32;Module["HEAPF64"]=HEAPF64;function callRuntimeCallbacks(callbacks){while(callbacks.length>0){var callback=callbacks.shift();if(typeof callback=="function"){callback();continue}var func=callback.func;if(typeof func==="number"){if(callback.arg===undefined){Module["dynCall_v"](func)}else{Module["dynCall_vi"](func,callback.arg)}}else{func(callback.arg===undefined?null:callback.arg)}}}var __ATPRERUN__=[];var __ATINIT__=[];var __ATMAIN__=[];var __ATEXIT__=[];var __ATPOSTRUN__=[];var runtimeInitialized=false;var runtimeExited=false;function preRun(){if(Module["preRun"]){if(typeof Module["preRun"]=="function")Module["preRun"]=[Module["preRun"]];while(Module["preRun"].length){addOnPreRun(Module["preRun"].shift())}}callRuntimeCallbacks(__ATPRERUN__)}function ensureInitRuntime(){if(runtimeInitialized)return;runtimeInitialized=true;callRuntimeCallbacks(__ATINIT__)}function preMain(){callRuntimeCallbacks(__ATMAIN__)}function exitRuntime(){callRuntimeCallbacks(__ATEXIT__);runtimeExited=true}function postRun(){if(Module["postRun"]){if(typeof Module["postRun"]=="function")Module["postRun"]=[Module["postRun"]];while(Module["postRun"].length){addOnPostRun(Module["postRun"].shift())}}callRuntimeCallbacks(__ATPOSTRUN__)}function addOnPreRun(cb){__ATPRERUN__.unshift(cb)}Module["addOnPreRun"]=addOnPreRun;function addOnInit(cb){__ATINIT__.unshift(cb)}Module["addOnInit"]=addOnInit;function addOnPreMain(cb){__ATMAIN__.unshift(cb)}Module["addOnPreMain"]=addOnPreMain;function addOnExit(cb){__ATEXIT__.unshift(cb)}Module["addOnExit"]=addOnExit;function addOnPostRun(cb){__ATPOSTRUN__.unshift(cb)}Module["addOnPostRun"]=addOnPostRun;function intArrayFromString(stringy,dontAddNull,length){var len=length>0?length:lengthBytesUTF8(stringy)+1;var u8array=new Array(len);var numBytesWritten=stringToUTF8Array(stringy,u8array,0,u8array.length);if(dontAddNull)u8array.length=numBytesWritten;return u8array}Module["intArrayFromString"]=intArrayFromString;function intArrayToString(array){var ret=[];for(var i=0;i<array.length;i++){var chr=array[i];if(chr>255){chr&=255}ret.push(String.fromCharCode(chr))}return ret.join("")}Module["intArrayToString"]=intArrayToString;function writeStringToMemory(string,buffer,dontAddNull){Runtime.warnOnce("writeStringToMemory is deprecated and should not be called! Use stringToUTF8() instead!");var lastChar,end;if(dontAddNull){end=buffer+lengthBytesUTF8(string);lastChar=HEAP8[end]}stringToUTF8(string,buffer,Infinity);if(dontAddNull)HEAP8[end]=lastChar}Module["writeStringToMemory"]=writeStringToMemory;function writeArrayToMemory(array,buffer){HEAP8.set(array,buffer)}Module["writeArrayToMemory"]=writeArrayToMemory;function writeAsciiToMemory(str,buffer,dontAddNull){for(var i=0;i<str.length;++i){HEAP8[buffer++>>0]=str.charCodeAt(i)}if(!dontAddNull)HEAP8[buffer>>0]=0}Module["writeAsciiToMemory"]=writeAsciiToMemory;if(!Math["imul"]||Math["imul"](4294967295,5)!==-5)Math["imul"]=function imul(a,b){var ah=a>>>16;var al=a&65535;var bh=b>>>16;var bl=b&65535;return al*bl+(ah*bl+al*bh<<16)|0};Math.imul=Math["imul"];if(!Math["clz32"])Math["clz32"]=(function(x){x=x>>>0;for(var i=0;i<32;i++){if(x&1<<31-i)return i}return 32});Math.clz32=Math["clz32"];if(!Math["trunc"])Math["trunc"]=(function(x){return x<0?Math.ceil(x):Math.floor(x)});Math.trunc=Math["trunc"];var Math_abs=Math.abs;var Math_cos=Math.cos;var Math_sin=Math.sin;var Math_tan=Math.tan;var Math_acos=Math.acos;var Math_asin=Math.asin;var Math_atan=Math.atan;var Math_atan2=Math.atan2;var Math_exp=Math.exp;var Math_log=Math.log;var Math_sqrt=Math.sqrt;var Math_ceil=Math.ceil;var Math_floor=Math.floor;var Math_pow=Math.pow;var Math_imul=Math.imul;var Math_fround=Math.fround;var Math_round=Math.round;var Math_min=Math.min;var Math_clz32=Math.clz32;var Math_trunc=Math.trunc;var runDependencies=0;var runDependencyWatcher=null;var dependenciesFulfilled=null;function addRunDependency(id){runDependencies++;if(Module["monitorRunDependencies"]){Module["monitorRunDependencies"](runDependencies)}}Module["addRunDependency"]=addRunDependency;function removeRunDependency(id){runDependencies--;if(Module["monitorRunDependencies"]){Module["monitorRunDependencies"](runDependencies)}if(runDependencies==0){if(runDependencyWatcher!==null){clearInterval(runDependencyWatcher);runDependencyWatcher=null}if(dependenciesFulfilled){var callback=dependenciesFulfilled;dependenciesFulfilled=null;callback()}}}Module["removeRunDependency"]=removeRunDependency;Module["preloadedImages"]={};Module["preloadedAudios"]={};var ASM_CONSTS=[(function(){{return Module.getRandomValue()}}),(function(){{if(Module.getRandomValue===undefined){try{var window_="object"===typeof window?window:self,crypto_=typeof window_.crypto!=="undefined"?window_.crypto:window_.msCrypto,randomValuesStandard=(function(){var buf=new Uint32Array(1);crypto_.getRandomValues(buf);return buf[0]>>>0});randomValuesStandard();Module.getRandomValue=randomValuesStandard}catch(e){try{var crypto=__webpack_require__(419),randomValueNodeJS=(function(){var buf=crypto.randomBytes(4);return(buf[0]<<24|buf[1]<<16|buf[2]<<8|buf[3])>>>0});randomValueNodeJS();Module.getRandomValue=randomValueNodeJS}catch(e){throw"No secure random number generator found"}}}}})];function _emscripten_asm_const_i(code){return ASM_CONSTS[code]()}function _emscripten_asm_const_v(code){return ASM_CONSTS[code]()}STATIC_BASE=Runtime.GLOBAL_BASE;STATICTOP=STATIC_BASE+36e3;__ATINIT__.push();allocate([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,38,232,149,143,194,178,39,176,69,195,244,137,242,239,152,240,213,223,172,5,211,198,51,57,177,56,2,136,109,83,252,5,199,23,106,112,61,77,216,79,186,60,11,118,13,16,103,15,42,32,83,250,44,57,204,198,78,199,253,119,146,172,3,122,19,232,149,143,194,178,39,176,69,195,244,137,242,239,152,240,213,223,172,5,211,198,51,57,177,56,2,136,109,83,252,133,180,23,106,112,61,77,216,79,186,60,11,118,13,16,103,15,42,32,83,250,44,57,204,198,78,199,253,119,146,172,3,250,236,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,237,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,238,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,127,217,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,218,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,219,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,8,201,188,243,103,230,9,106,59,167,202,132,133,174,103,187,43,248,148,254,114,243,110,60,241,54,29,95,58,245,79,165,209,130,230,173,127,82,14,81,31,108,62,43,140,104,5,155,107,189,65,251,171,217,131,31,121,33,126,19,25,205,224,91,34,174,40,215,152,47,138,66,205,101,239,35,145,68,55,113,47,59,77,236,207,251,192,181,188,219,137,129,165,219,181,233,56,181,72,243,91,194,86,57,25,208,5,182,241,17,241,89,155,79,25,175,164,130,63,146,24,129,109,218,213,94,28,171,66,2,3,163,152,170,7,216,190,111,112,69,1,91,131,18,140,178,228,78,190,133,49,36,226,180,255,213,195,125,12,85,111,137,123,242,116,93,190,114,177,150,22,59,254,177,222,128,53,18,199,37,167,6,220,155,148,38,105,207,116,241,155,193,210,74,241,158,193,105,155,228,227,37,79,56,134,71,190,239,181,213,140,139,198,157,193,15,101,156,172,119,204,161,12,36,117,2,43,89,111,44,233,45,131,228,166,110,170,132,116,74,212,251,65,189,220,169,176,92,181,83,17,131,218,136,249,118,171,223,102,238,82,81,62,152,16,50,180,45,109,198,49,168,63,33,251,152,200,39,3,176,228,14,239,190,199,127,89,191,194,143,168,61,243,11,224,198,37,167,10,147,71,145,167,213,111,130,3,224,81,99,202,6,112,110,14,10,103,41,41,20,252,47,210,70,133,10,183,39,38,201,38,92,56,33,27,46,237,42,196,90,252,109,44,77,223,179,149,157,19,13,56,83,222,99,175,139,84,115,10,101,168,178,119,60,187,10,106,118,230,174,237,71,46,201,194,129,59,53,130,20,133,44,114,146,100,3,241,76,161,232,191,162,1,48,66,188,75,102,26,168,145,151,248,208,112,139,75,194,48,190,84,6,163,81,108,199,24,82,239,214,25,232,146,209,16,169,101,85,36,6,153,214,42,32,113,87,133,53,14,244,184,209,187,50,112,160,106,16,200,208,210,184,22,193,164,25,83,171,65,81,8,108,55,30,153,235,142,223,76,119,72,39,168,72,155,225,181,188,176,52,99,90,201,197,179,12,28,57,203,138,65,227,74,170,216,78,115,227,99,119,79,202,156,91,163,184,178,214,243,111,46,104,252,178,239,93,238,130,143,116,96,47,23,67,111,99,165,120,114,171,240,161,20,120,200,132,236,57,100,26,8,2,199,140,40,30,99,35,250,255,190,144,233,189,130,222,235,108,80,164,21,121,198,178,247,163,249,190,43,83,114,227,242,120,113,198,156,97,38,234,206,62,39,202,7,194,192,33,199,184,134,209,30,235,224,205,214,125,218,234,120,209,110,238,127,79,125,245,186,111,23,114,170,103,240,6,166,152,200,162,197,125,99,10,174,13,249,190,4,152,63,17,27,71,28,19,53,11,113,27,132,125,4,35,245,119,219,40,147,36,199,64,123,171,202,50,188,190,201,21,10,190,158,60,76,13,16,156,196,103,29,67,182,66,62,203,190,212,197,76,42,126,101,252,156,41,127,89,236,250,214,58,171,111,203,95,23,88,71,74,140,25,68,108,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,51,51,51,51,51,51,51,51,51,51,51,51,51,51,51,51,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,182,120,89,255,133,114,211,0,189,110,21,255,15,10,106,0,41,192,1,0,152,232,121,255,188,60,160,255,153,113,206,255,0,183,226,254,180,13,72,255,176,160,14,254,211,201,134,255,158,24,143,0,127,105,53,0,96,12,189,0,167,215,251,255,159,76,128,254,106,101,225,255,30,252,4,0,146,12,174,0,89,241,178,254,10,229,166,255,123,221,42,254,30,20,212,0,82,128,3,0,48,209,243,0,119,121,64,255,50,227,156,255,0,110,197,1,103,27,144,0,133,59,140,1,189,241,36,255,248,37,195,1,96,220,55,0,183,76,62,255,195,66,61,0,50,76,164,1,225,164,76,255,76,61,163,255,117,62,31,0,81,145,64,255,118,65,14,0,162,115,214,255,6,138,46,0,124,230,244,255,10,138,143,0,52,26,194,0,184,244,76,0,129,143,41,1,190,244,19,255,123,170,122,255,98,129,68,0,121,213,147,0,86,101,30,255,161,103,155,0,140,89,67,255,239,229,190,1,67,11,181,0,198,240,137,254,238,69,188,255,67,151,238,0,19,42,108,255,229,85,113,1,50,68,135,255,17,106,9,0,50,103,1,255,80,1,168,1,35,152,30,255,16,168,185,1,56,89,232,255,101,210,252,0,41,250,71,0,204,170,79,255,14,46,239,255,80,77,239,0,189,214,75,255,17,141,249,0,38,80,76,255,190,85,117,0,86,228,170,0,156,216,208,1,195,207,164,255,150,66,76,255,175,225,16,255,141,80,98,1,76,219,242,0,198,162,114,0,46,218,152,0,155,43,241,254,155,160,104,255,51,187,165,0,2,17,175,0,66,84,160,1,247,58,30,0,35,65,53,254,69,236,191,0,45,134,245,1,163,123,221,0,32,110,20,255,52,23,165,0,186,214,71,0,233,176,96,0,242,239,54,1,57,89,138,0,83,0,84,255,136,160,100,0,92,142,120,254,104,124,190,0,181,177,62,255,250,41,85,0,152,130,42,1,96,252,246,0,151,151,63,254,239,133,62,0,32,56,156,0,45,167,189,255,142,133,179,1,131,86,211,0,187,179,150,254,250,170,14,255,210,163,78,0,37,52,151,0,99,77,26,0,238,156,213,255,213,192,209,1,73,46,84,0,20,65,41,1,54,206,79,0,201,131,146,254,170,111,24,255,177,33,50,254,171,38,203,255,78,247,116,0,209,221,153,0,133,128,178,1,58,44,25,0,201,39,59,1,189,19,252,0,49,229,210,1,117,187,117,0,181,179,184,1,0,114,219,0,48,94,147,0,245,41,56,0,125,13,204,254,244,173,119,0,44,221,32,254,84,234,20,0,249,160,198,1,236,126,234,255,47,99,168,254,170,226,153,255,102,179,216,0,226,141,122,255,122,66,153,254,182,245,134,0,227,228,25,1,214,57,235,255,216,173,56,255,181,231,210,0,119,128,157,255,129,95,136,255,110,126,51,0,2,169,183,255,7,130,98,254,69,176,94,255,116,4,227,1,217,242,145,255,202,173,31,1,105,1,39,255,46,175,69,0,228,47,58,255,215,224,69,254,207,56,69,255,16,254,139,255,23,207,212,255,202,20,126,255,95,213,96,255,9,176,33,0,200,5,207,255,241,42,128,254,35,33,192,255,248,229,196,1,129,17,120,0,251,103,151,255,7,52,112,255,140,56,66,255,40,226,245,255,217,70,37,254,172,214,9,255,72,67,134,1,146,192,214,255,44,38,112,0,68,184,75,255,206,90,251,0,149,235,141,0,181,170,58,0,116,244,239,0,92,157,2,0,102,173,98,0,233,137,96,1,127,49,203,0,5,155,148,0,23,148,9,255,211,122,12,0,34,134,26,255,219,204,136,0,134,8,41,255,224,83,43,254,85,25,247,0,109,127,0,254,169,136,48,0,238,119,219,255,231,173,213,0,206,18,254,254,8,186,7,255,126,9,7,1,111,42,72,0,111,52,236,254,96,63,141,0,147,191,127,254,205,78,192,255,14,106,237,1,187,219,76,0,175,243,187,254,105,89,173,0,85,25,89,1,162,243,148,0,2,118,209,254,33,158,9,0,139,163,46,255,93,70,40,0,108,42,142,254,111,252,142,255,155,223,144,0,51,229,167,255,73,252,155,255,94,116,12,255,152,160,218,255,156,238,37,255,179,234,207,255,197,0,179,255,154,164,141,0,225,196,104,0,10,35,25,254,209,212,242,255,97,253,222,254,184,101,229,0,222,18,127,1,164,136,135,255,30,207,140,254,146,97,243,0,129,192,26,254,201,84,33,255,111,10,78,255,147,81,178,255,4,4,24,0,161,238,215,255,6,141,33,0,53,215,14,255,41,181,208,255,231,139,157,0,179,203,221,255,255,185,113,0,189,226,172,255,113,66,214,255,202,62,45,255,102,64,8,255,78,174,16,254,133,117,68,255,133,59,140,1,189,241,36,255,248,37,195,1,96,220,55,0,183,76,62,255,195,66,61,0,50,76,164,1,225,164,76,255,76,61,163,255,117,62,31,0,81,145,64,255,118,65,14,0,162,115,214,255,6,138,46,0,124,230,244,255,10,138,143,0,52,26,194,0,184,244,76,0,129,143,41,1,190,244,19,255,123,170,122,255,98,129,68,0,121,213,147,0,86,101,30,255,161,103,155,0,140,89,67,255,239,229,190,1,67,11,181,0,198,240,137,254,238,69,188,255,234,113,60,255,37,255,57,255,69,178,182,254,128,208,179,0,118,26,125,254,3,7,214,255,241,50,77,255,85,203,197,255,211,135,250,255,25,48,100,255,187,213,180,254,17,88,105,0,83,209,158,1,5,115,98,0,4,174,60,254,171,55,110,255,217,181,17,255,20,188,170,0,146,156,102,254,87,214,174,255,114,122,155,1,233,44,170,0,127,8,239,1,214,236,234,0,175,5,219,0,49,106,61,255,6,66,208,255,2,106,110,255,81,234,19,255,215,107,192,255,67,151,238,0,19,42,108,255,229,85,113,1,50,68,135,255,17,106,9,0,50,103,1,255,80,1,168,1,35,152,30,255,16,168,185,1,56,89,232,255,101,210,252,0,41,250,71,0,204,170,79,255,14,46,239,255,80,77,239,0,189,214,75,255,17,141,249,0,38,80,76,255,190,85,117,0,86,228,170,0,156,216,208,1,195,207,164,255,150,66,76,255,175,225,16,255,141,80,98,1,76,219,242,0,198,162,114,0,46,218,152,0,155,43,241,254,155,160,104,255,178,9,252,254,100,110,212,0,14,5,167,0,233,239,163,255,28,151,157,1,101,146,10,255,254,158,70,254,71,249,228,0,88,30,50,0,68,58,160,255,191,24,104,1,129,66,129,255,192,50,85,255,8,179,138,255,38,250,201,0,115,80,160,0,131,230,113,0,125,88,147,0,90,68,199,0,253,76,158,0,28,255,118,0,113,250,254,0,66,75,46,0,230,218,43,0,229,120,186,1,148,68,43,0,136,124,238,1,187,107,197,255,84,53,246,255,51,116,254,255,51,187,165,0,2,17,175,0,66,84,160,1,247,58,30,0,35,65,53,254,69,236,191,0,45,134,245,1,163,123,221,0,32,110,20,255,52,23,165,0,186,214,71,0,233,176,96,0,242,239,54,1,57,89,138,0,83,0,84,255,136,160,100,0,92,142,120,254,104,124,190,0,181,177,62,255,250,41,85,0,152,130,42,1,96,252,246,0,151,151,63,254,239,133,62,0,32,56,156,0,45,167,189,255,142,133,179,1,131,86,211,0,187,179,150,254,250,170,14,255,68,113,21,255,222,186,59,255,66,7,241,1,69,6,72,0,86,156,108,254,55,167,89,0,109,52,219,254,13,176,23,255,196,44,106,255,239,149,71,255,164,140,125,255,159,173,1,0,51,41,231,0,145,62,33,0,138,111,93,1,185,83,69,0,144,115,46,0,97,151,16,255,24,228,26,0,49,217,226,0,113,75,234,254,193,153,12,255,182,48,96,255,14,13,26,0,128,195,249,254,69,193,59,0,132,37,81,254,125,106,60,0,214,240,169,1,164,227,66,0,210,163,78,0,37,52,151,0,99,77,26,0,238,156,213,255,213,192,209,1,73,46,84,0,20,65,41,1,54,206,79,0,201,131,146,254,170,111,24,255,177,33,50,254,171,38,203,255,78,247,116,0,209,221,153,0,133,128,178,1,58,44,25,0,201,39,59,1,189,19,252,0,49,229,210,1,117,187,117,0,181,179,184,1,0,114,219,0,48,94,147,0,245,41,56,0,125,13,204,254,244,173,119,0,44,221,32,254,84,234,20,0,249,160,198,1,236,126,234,255,143,62,221,0,129,89,214,255,55,139,5,254,68,20,191,255,14,204,178,1,35,195,217,0,47,51,206,1,38,246,165,0,206,27,6,254,158,87,36,0,217,52,146,255,125,123,215,255,85,60,31,255,171,13,7,0,218,245,88,254,252,35,60,0,55,214,160,255,133,101,56,0,224,32,19,254,147,64,234,0,26,145,162,1,114,118,125,0,248,252,250,0,101,94,196,255,198,141,226,254,51,42,182,0,135,12,9,254,109,172,210,255,197,236,194,1,241,65,154,0,48,156,47,255,153,67,55,255,218,165,34,254,74,180,179,0,218,66,71,1,88,122,99,0,212,181,219,255,92,42,231,255,239,0,154,0,245,77,183,255,94,81,170,1,18,213,216,0,171,93,71,0,52,94,248,0,18,151,161,254,197,209,66,255,174,244,15,254,162,48,183,0,49,61,240,254,182,93,195,0,199,228,6,1,200,5,17,255,137,45,237,255,108,148,4,0,90,79,237,255,39,63,77,255,53,82,207,1,142,22,118,255,101,232,18,1,92,26,67,0,5,200,88,255,33,168,138,255,149,225,72,0,2,209,27,255,44,245,168,1,220,237,17,255,30,211,105,254,141,238,221,0,128,80,245,254,111,254,14,0,222,95,190,1,223,9,241,0,146,76,212,255,108,205,104,255,63,117,153,0,144,69,48,0,35,228,111,0,192,33,193,255,112,214,190,254,115,152,151,0,23,102,88,0,51,74,248,0,226,199,143,254,204,162,101,255,208,97,189,1,245,104,18,0,230,246,30,255,23,148,69,0,110,88,52,254,226,181,89,255,208,47,90,254,114,161,80,255,33,116,248,0,179,152,87,255,69,144,177,1,88,238,26,255,58,32,113,1,1,77,69,0,59,121,52,255,152,238,83,0,52,8,193,0,231,39,233,255,199,34,138,0,222,68,173,0,91,57,242,254,220,210,127,255,192,7,246,254,151,35,187,0,195,236,165,0,111,93,206,0,212,247,133,1,154,133,209,255,155,231,10,0,64,78,38,0,122,249,100,1,30,19,97,255,62,91,249,1,248,133,77,0,197,63,168,254,116,10,82,0,184,236,113,254,212,203,194,255,61,100,252,254,36,5,202,255,119,91,153,255,129,79,29,0,103,103,171,254,237,215,111,255,216,53,69,0,239,240,23,0,194,149,221,255,38,225,222,0,232,255,180,254,118,82,133,255,57,209,177,1,139,232,133,0,158,176,46,254,194,115,46,0,88,247,229,1,28,103,191,0,221,222,175,254,149,235,44,0,151,228,25,254,218,105,103,0,142,85,210,0,149,129,190,255,213,65,94,254,117,134,224,255,82,198,117,0,157,221,220,0,163,101,36,0,197,114,37,0,104,172,166,254,11,182,0,0,81,72,188,255,97,188,16,255,69,6,10,0,199,147,145,255,8,9,115,1,65,214,175,255,217,173,209,0,80,127,166,0,247,229,4,254,167,183,124,255,90,28,204,254,175,59,240,255,11,41,248,1,108,40,51,255,144,177,195,254,150,250,126,0,138,91,65,1,120,60,222,255,245,193,239,0,29,214,189,255,128,2,25,0,80,154,162,0,77,220,107,1,234,205,74,255,54,166,103,255,116,72,9,0,228,94,47,255,30,200,25,255,35,214,89,255,61,176,140,255,83,226,163,255,75,130,172,0,128,38,17,0,95,137,152,255,215,124,159,1,79,93,0,0,148,82,157,254,195,130,251,255,40,202,76,255,251,126,224,0,157,99,62,254,207,7,225,255,96,68,195,0,140,186,157,255,131,19,231,255,42,128,254,0,52,219,61,254,102,203,72,0,141,7,11,255,186,164,213,0,31,122,119,0,133,242,145,0,208,252,232,255,91,213,182,255,143,4,250,254,249,215,74,0,165,30,111,1,171,9,223,0,229,123,34,1,92,130,26,255,77,155,45,1,195,139,28,255,59,224,78,0,136,17,247,0,108,121,32,0,79,250,189,255,96,227,252,254,38,241,62,0,62,174,125,255,155,111,93,255,10,230,206,1,97,197,40,255,0,49,57,254,65,250,13,0,18,251,150,255,220,109,210,255,5,174,166,254,44,129,189,0,235,35,147,255,37,247,141,255,72,141,4,255,103,107,255,0,247,90,4,0,53,44,42,0,2,30,240,0,4,59,63,0,88,78,36,0,113,167,180,0,190,71,193,255,199,158,164,255,58,8,172,0,77,33,12,0,65,63,3,0,153,77,33,255,172,254,102,1,228,221,4,255,87,30,254,1,146,41,86,255,138,204,239,254,108,141,17,255,187,242,135,0,210,208,127,0,68,45,14,254,73,96,62,0,81,60,24,255,170,6,36,255,3,249,26,0,35,213,109,0,22,129,54,255,21,35,225,255,234,61,56,255,58,217,6,0,143,124,88,0,236,126,66,0,209,38,183,255,34,238,6,255,174,145,102,0,95,22,211,0,196,15,153,254,46,84,232,255,117,34,146,1,231,250,74,255,27,134,100,1,92,187,195,255,170,198,112,0,120,28,42,0,209,70,67,0,29,81,31,0,29,168,100,1,169,173,160,0,107,35,117,0,62,96,59,255,81,12,69,1,135,239,190,255,220,252,18,0,163,220,58,255,137,137,188,255,83,102,109,0,96,6,76,0,234,222,210,255,185,174,205,1,60,158,213,255,13,241,214,0,172,129,140,0,93,104,242,0,192,156,251,0,43,117,30,0,225,81,158,0,127,232,218,0,226,28,203,0,233,27,151,255,117,43,5,255,242,14,47,255,33,20,6,0,137,251,44,254,27,31,245,255,183,214,125,254,40,121,149,0,186,158,213,255,89,8,227,0,69,88,0,254,203,135,225,0,201,174,203,0,147,71,184,0,18,121,41,254,94,5,78,0,224,214,240,254,36,5,180,0,251,135,231,1,163,138,212,0,210,249,116,254,88,129,187,0,19,8,49,254,62,14,144,255,159,76,211,0,214,51,82,0,109,117,228,254,103,223,203,255,75,252,15,1,154,71,220,255,23,13,91,1,141,168,96,255,181,182,133,0,250,51,55,0,234,234,212,254,175,63,158,0,39,240,52,1,158,189,36,255,213,40,85,1,32,180,247,255,19,102,26,1,84,24,97,255,69,21,222,0,148,139,122,255,220,213,235,1,232,203,255,0,121,57,147,0,227,7,154,0,53,22,147,1,72,1,225,0,82,134,48,254,83,60,157,255,145,72,169,0,34,103,239,0,198,233,47,0,116,19,4,255,184,106,9,255,183,129,83,0,36,176,230,1,34,103,72,0,219,162,134,0,245,42,158,0,32,149,96,254,165,44,144,0,202,239,72,254,215,150,5,0,42,66,36,1,132,215,175,0,86,174,86,255,26,197,156,255,49,232,135,254,103,182,82,0,253,128,176,1,153,178,122,0,245,250,10,0,236,24,178,0,137,106,132,0,40,29,41,0,50,30,152,255,124,105,38,0,230,191,75,0,143,43,170,0,44,131,20,255,44,13,23,255,237,255,155,1,159,109,100,255,112,181,24,255,104,220,108,0,55,211,131,0,99,12,213,255,152,151,145,255,238,5,159,0,97,155,8,0,33,108,81,0,1,3,103,0,62,109,34,255,250,155,180,0,32,71,195,255,38,70,145,1,159,95,245,0,69,229,101,1,136,28,240,0,79,224,25,0,78,110,121,255,248,168,124,0,187,128,247,0,2,147,235,254,79,11,132,0,70,58,12,1,181,8,163,255,79,137,133,255,37,170,11,255,141,243,85,255,176,231,215,255,204,150,164,255,239,215,39,255,46,87,156,254,8,163,88,255,172,34,232,0,66,44,102,255,27,54,41,254,236,99,87,255,41,123,169,1,52,114,43,0,117,134,40,0,155,134,26,0,231,207,91,254,35,132,38,255,19,102,125,254,36,227,133,255,118,3,113,255,29,13,124,0,152,96,74,1,88,146,206,255,167,191,220,254,162,18,88,255,182,100,23,0,31,117,52,0,81,46,106,1,12,2,7,0,69,80,201,1,209,246,172,0,12,48,141,1,224,211,88,0,116,226,159,0,122,98,130,0,65,236,234,1,225,226,9,255,207,226,123,1,89,214,59,0,112,135,88,1,90,244,203,255,49,11,38,1,129,108,186,0,89,112,15,1,101,46,204,255,127,204,45,254,79,255,221,255,51,73,18,255,127,42,101,255,241,21,202,0,160,227,7,0,105,50,236,0,79,52,197,255,104,202,208,1,180,15,16,0,101,197,78,255,98,77,203,0,41,185,241,1,35,193,124,0,35,155,23,255,207,53,192,0,11,125,163,1,249,158,185,255,4,131,48,0,21,93,111,255,61,121,231,1,69,200,36,255,185,48,185,255,111,238,21,255,39,50,25,255,99,215,163,255,87,212,30,255,164,147,5,255,128,6,35,1,108,223,110,255,194,76,178,0,74,101,180,0,243,47,48,0,174,25,43,255,82,173,253,1,54,114,192,255,40,55,91,0,215,108,176,255,11,56,7,0,224,233,76,0,209,98,202,254,242,25,125,0,44,193,93,254,203,8,177,0,135,176,19,0,112,71,213,255,206,59,176,1,4,67,26,0,14,143,213,254,42,55,208,255,60,67,120,0,193,21,163,0,99,164,115,0,10,20,118,0,156,212,222,254,160,7,217,255,114,245,76,1,117,59,123,0,176,194,86,254,213,15,176,0,78,206,207,254,213,129,59,0,233,251,22,1,96,55,152,255,236,255,15,255,197,89,84,255,93,149,133,0,174,160,113,0,234,99,169,255,152,116,88,0,144,164,83,255,95,29,198,255,34,47,15,255,99,120,134,255,5,236,193,0,249,247,126,255,147,187,30,0,50,230,117,255,108,217,219,255,163,81,166,255,72,25,169,254,155,121,79,255,28,155,89,254,7,126,17,0,147,65,33,1,47,234,253,0,26,51,18,0,105,83,199,255,163,196,230,0,113,248,164,0,226,254,218,0,189,209,203,255,164,247,222,254,255,35,165,0,4,188,243,1,127,179,71,0,37,237,254,255,100,186,240,0,5,57,71,254,103,72,73,255,244,18,81,254,229,210,132,255,238,6,180,255,11,229,174,255,227,221,192,1,17,49,28,0,163,215,196,254,9,118,4,255,51,240,71,0,113,129,109,255,76,240,231,0,188,177,127,0,125,71,44,1,26,175,243,0,94,169,25,254,27,230,29,0,15,139,119,1,168,170,186,255,172,197,76,255,252,75,188,0,137,124,196,0,72,22,96,255,45,151,249,1,220,145,100,0,64,192,159,255,120,239,226,0,129,178,146,0,0,192,125,0,235,138,234,0,183,157,146,0,83,199,192,255,184,172,72,255,73,225,128,0,77,6,250,255,186,65,67,0,104,246,207,0,188,32,138,255,218,24,242,0,67,138,81,254,237,129,121,255,20,207,150,1,41,199,16,255,6,20,128,0,159,118,5,0,181,16,143,255,220,38,15,0,23,64,147,254,73,26,13,0,87,228,57,1,204,124,128,0,43,24,223,0,219,99,199,0,22,75,20,255,19,27,126,0,157,62,215,0,110,29,230,0,179,167,255,1,54,252,190,0,221,204,182,254,179,158,65,255,81,157,3,0,194,218,159,0,170,223,0,0,224,11,32,255,38,197,98,0,168,164,37,0,23,88,7,1,164,186,110,0,96,36,134,0,234,242,229,0,250,121,19,0,242,254,112,255,3,47,94,1,9,239,6,255,81,134,153,254,214,253,168,255,67,124,224,0,245,95,74,0,28,30,44,254,1,109,220,255,178,89,89,0,252,36,76,0,24,198,46,255,76,77,111,0,134,234,136,255,39,94,29,0,185,72,234,255,70,68,135,255,231,102,7,254,77,231,140,0,167,47,58,1,148,97,118,255,16,27,225,1,166,206,143,255,110,178,214,255,180,131,162,0,143,141,225,1,13,218,78,255,114,153,33,1,98,104,204,0,175,114,117,1,167,206,75,0,202,196,83,1,58,64,67,0,138,47,111,1,196,247,128,255,137,224,224,254,158,112,207,0,154,100,255,1,134,37,107,0,198,128,79,255,127,209,155,255,163,254,185,254,60,14,243,0,31,219,112,254,29,217,65,0,200,13,116,254,123,60,196,255,224,59,184,254,242,89,196,0,123,16,75,254,149,16,206,0,69,254,48,1,231,116,223,255,209,160,65,1,200,80,98,0,37,194,184,254,148,63,34,0,139,240,65,255,217,144,132,255,56,38,45,254,199,120,210,0,108,177,166,255,160,222,4,0,220,126,119,254,165,107,160,255,82,220,248,1,241,175,136,0,144,141,23,255,169,138,84,0,160,137,78,255,226,118,80,255,52,27,132,255,63,96,139,255,152,250,39,0,188,155,15,0,232,51,150,254,40,15,232,255,240,229,9,255,137,175,27,255,75,73,97,1,218,212,11,0,135,5,162,1,107,185,213,0,2,249,107,255,40,242,70,0,219,200,25,0,25,157,13,0,67,82,80,255,196,249,23,255,145,20,149,0,50,72,146,0,94,76,148,1,24,251,65,0,31,192,23,0,184,212,201,255,123,233,162,1,247,173,72,0,162,87,219,254,126,134,89,0,159,11,12,254,166,105,29,0,73,27,228,1,113,120,183,255,66,163,109,1,212,143,11,255,159,231,168,1,255,128,90,0,57,14,58,254,89,52,10,255,253,8,163,1,0,145,210,255,10,129,85,1,46,181,27,0,103,136,160,254,126,188,209,255,34,35,111,0,215,219,24,255,212,11,214,254,101,5,118,0,232,197,133,255,223,167,109,255,237,80,86,255,70,139,94,0,158,193,191,1,155,15,51,255,15,190,115,0,78,135,207,255,249,10,27,1,181,125,233,0,95,172,13,254,170,213,161,255,39,236,138,255,95,93,87,255,190,128,95,0,125,15,206,0,166,150,159,0,227,15,158,255,206,158,120,255,42,141,128,0,101,178,120,1,156,109,131,0,218,14,44,254,247,168,206,255,212,112,28,0,112,17,228,255,90,16,37,1,197,222,108,0,254,207,83,255,9,90,243,255,243,244,172,0,26,88,115,255,205,116,122,0,191,230,193,0,180,100,11,1,217,37,96,255,154,78,156,0,235,234,31,255,206,178,178,255,149,192,251,0,182,250,135,0,246,22,105,0,124,193,109,255,2,210,149,255,169,17,170,0,0,96,110,255,117,9,8,1,50,123,40,255,193,189,99,0,34,227,160,0,48,80,70,254,211,51,236,0,45,122,245,254,44,174,8,0,173,37,233,255,158,65,171,0,122,69,215,255,90,80,2,255,131,106,96,254,227,114,135,0,205,49,119,254,176,62,64,255,82,51,17,255,241,20,243,255,130,13,8,254,128,217,243,255,162,27,1,254,90,118,241,0,246,198,246,255,55,16,118,255,200,159,157,0,163,17,1,0,140,107,121,0,85,161,118,255,38,0,149,0,156,47,238,0,9,166,166,1,75,98,181,255,50,74,25,0,66,15,47,0,139,225,159,0,76,3,142,255,14,238,184,0,11,207,53,255,183,192,186,1,171,32,174,255,191,76,221,1,247,170,219,0,25,172,50,254,217,9,233,0,203,126,68,255,183,92,48,0,127,167,183,1,65,49,254,0,16,63,127,1,254,21,170,255,59,224,127,254,22,48,63,255,27,78,130,254,40,195,29,0,250,132,112,254,35,203,144,0,104,169,168,0,207,253,30,255,104,40,38,254,94,228,88,0,206,16,128,255,212,55,122,255,223,22,234,0,223,197,127,0,253,181,181,1,145,102,118,0,236,153,36,255,212,217,72,255,20,38,24,254,138,62,62,0,152,140,4,0,230,220,99,255,1,21,212,255,148,201,231,0,244,123,9,254,0,171,210,0,51,58,37,255,1,255,14,255,244,183,145,254,0,242,166,0,22,74,132,0,121,216,41,0,95,195,114,254,133,24,151,255,156,226,231,255,247,5,77,255,246,148,115,254,225,92,81,255,222,80,246,254,170,123,89,255,74,199,141,0,29,20,8,255,138,136,70,255,93,75,92,0,221,147,49,254,52,126,226,0,229,124,23,0,46,9,181,0,205,64,52,1,131,254,28,0,151,158,212,0,131,64,78,0,206,25,171,0,0,230,139,0,191,253,110,254,103,247,167,0,64,40,40,1,42,165,241,255,59,75,228,254,124,243,189,255,196,92,178,255,130,140,86,255,141,89,56,1,147,198,5,255,203,248,158,254,144,162,141,0,11,172,226,0,130,42,21,255,1,167,143,255,144,36,36,255,48,88,164,254,168,170,220,0,98,71,214,0,91,208,79,0,159,76,201,1,166,42,214,255,69,255,0,255,6,128,125,255,190,1,140,0,146,83,218,255,215,238,72,1,122,127,53,0,189,116,165,255,84,8,66,255,214,3,208,255,213,110,133,0,195,168,44,1,158,231,69,0,162,64,200,254,91,58,104,0,182,58,187,254,249,228,136,0,203,134,76,254,99,221,233,0,75,254,214,254,80,69,154,0,64,152,248,254,236,136,202,255,157,105,153,254,149,175,20,0,22,35,19,255,124,121,233,0,186,250,198,254,132,229,139,0,137,80,174,255,165,125,68,0,144,202,148,254,235,239,248,0,135,184,118,0,101,94,17,255,122,72,70,254,69,130,146,0,127,222,248,1,69,127,118,255,30,82,215,254,188,74,19,255,229,167,194,254,117,25,66,255,65,234,56,254,213,22,156,0,151,59,93,254,45,28,27,255,186,126,164,255,32,6,239,0,127,114,99,1,219,52,2,255,99,96,166,254,62,190,126,255,108,222,168,1,75,226,174,0,230,226,199,0,60,117,218,255,252,248,20,1,214,188,204,0,31,194,134,254,123,69,192,255,169,173,36,254,55,98,91,0,223,42,102,254,137,1,102,0,157,90,25,0,239,122,64,255,252,6,233,0,7,54,20,255,82,116,174,0,135,37,54,255,15,186,125,0,227,112,175,255,100,180,225,255,42,237,244,255,244,173,226,254,248,18,33,0,171,99,150,255,74,235,50,255,117,82,32,254,106,168,237,0,207,109,208,1,228,9,186,0,135,60,169,254,179,92,143,0,244,170,104,255,235,45,124,255,70,99,186,0,117,137,183,0,224,31,215,0,40,9,100,0,26,16,95,1,68,217,87,0,8,151,20,255,26,100,58,255,176,165,203,1,52,118,70,0,7,32,254,254,244,254,245,255,167,144,194,255,125,113,23,255,176,121,181,0,136,84,209,0,138,6,30,255,89,48,28,0,33,155,14,255,25,240,154,0,141,205,109,1,70,115,62,255,20,40,107,254,138,154,199,255,94,223,226,255,157,171,38,0,163,177,25,254,45,118,3,255,14,222,23,1,209,190,81,255,118,123,232,1,13,213,101,255,123,55,123,254,27,246,165,0,50,99,76,255,140,214,32,255,97,65,67,255,24,12,28,0,174,86,78,1,64,247,96,0,160,135,67,0,66,55,243,255,147,204,96,255,26,6,33,255,98,51,83,1,153,213,208,255,2,184,54,255,25,218,11,0,49,67,246,254,18,149,72,255,13,25,72,0,42,79,214,0,42,4,38,1,27,139,144,255,149,187,23,0,18,164,132,0,245,84,184,254,120,198,104,255,126,218,96,0,56,117,234,255,13,29,214,254,68,47,10,255,167,154,132,254,152,38,198,0,66,178,89,255,200,46,171,255,13,99,83,255,210,187,253,255,170,45,42,1,138,209,124,0,214,162,141,0,12,230,156,0,102,36,112,254,3,147,67,0,52,215,123,255,233,171,54,255,98,137,62,0,247,218,39,255,231,218,236,0,247,191,127,0,195,146,84,0,165,176,92,255,19,212,94,255,17,74,227,0,88,40,153,1,198,147,1,255,206,67,245,254,240,3,218,255,61,141,213,255,97,183,106,0,195,232,235,254,95,86,154,0,209,48,205,254,118,209,241,255,240,120,223,1,213,29,159,0,163,127,147,255,13,218,93,0,85,24,68,254,70,20,80,255,189,5,140,1,82,97,254,255,99,99,191,255,132,84,133,255,107,218,116,255,112,122,46,0,105,17,32,0,194,160,63,255,68,222,39,1,216,253,92,0,177,105,205,255,149,201,195,0,42,225,11,255,40,162,115,0,9,7,81,0,165,218,219,0,180,22,0,254,29,146,252,255,146,207,225,1,180,135,96,0,31,163,112,0,177,11,219,255,133,12,193,254,43,78,50,0,65,113,121,1,59,217,6,255,110,94,24,1,112,172,111,0,7,15,96,0,36,85,123,0,71,150,21,255,208,73,188,0,192,11,167,1,213,245,34,0,9,230,92,0,162,142,39,255,215,90,27,0,98,97,89,0,94,79,211,0,90,157,240,0,95,220,126,1,102,176,226,0,36,30,224,254,35,31,127,0,231,232,115,1,85,83,130,0,210,73,245,255,47,143,114,255,68,65,197,0,59,72,62,255,183,133,173,254,93,121,118,255,59,177,81,255,234,69,173,255,205,128,177,0,220,244,51,0,26,244,209,1,73,222,77,255,163,8,96,254,150,149,211,0,158,254,203,1,54,127,139,0,161,224,59,0,4,109,22,255,222,42,45,255,208,146,102,255,236,142,187,0,50,205,245,255,10,74,89,254,48,79,142,0,222,76,130,255,30,166,63,0,236,12,13,255,49,184,244,0,187,113,102,0,218,101,253,0,153,57,182,254,32,150,42,0,25,198,146,1,237,241,56,0,140,68,5,0,91,164,172,255,78,145,186,254,67,52,205,0,219,207,129,1,109,115,17,0,54,143,58,1,21,248,120,255,179,255,30,0,193,236,66,255,1,255,7,255,253,192,48,255,19,69,217,1,3,214,0,255,64,101,146,1,223,125,35,255,235,73,179,255,249,167,226,0,225,175,10,1,97,162,58,0,106,112,171,1,84,172,5,255,133,140,178,255,134,245,142,0,97,90,125,255,186,203,185,255,223,77,23,255,192,92,106,0,15,198,115,255,217,152,248,0,171,178,120,255,228,134,53,0,176,54,193,1,250,251,53,0,213,10,100,1,34,199,106,0,151,31,244,254,172,224,87,255,14,237,23,255,253,85,26,255,127,39,116,255,172,104,100,0,251,14,70,255,212,208,138,255,253,211,250,0,176,49,165,0,15,76,123,255,37,218,160,255,92,135,16,1,10,126,114,255,70,5,224,255,247,249,141,0,68,20,60,1,241,210,189,255,195,217,187,1,151,3,113,0,151,92,174,0,231,62,178,255,219,183,225,0,23,23,33,255,205,181,80,0,57,184,248,255,67,180,1,255,90,123,93,255,39,0,162,255,96,248,52,255,84,66,140,0,34,127,228,255,194,138,7,1,166,110,188,0,21,17,155,1,154,190,198,255,214,80,59,255,18,7,143,0,72,29,226,1,199,217,249,0,232,161,71,1,149,190,201,0,217,175,95,254,113,147,67,255,138,143,199,255,127,204,1,0,29,182,83,1,206,230,155,255,186,204,60,0,10,125,85,255,232,96,25,255,255,89,247,255,213,254,175,1,232,193,81,0,28,43,156,254,12,69,8,0,147,24,248,0,18,198,49,0,134,60,35,0,118,246,18,255,49,88,254,254,228,21,186,255,182,65,112,1,219,22,1,255,22,126,52,255,189,53,49,255,112,25,143,0,38,127,55,255,226,101,163,254,208,133,61,255,137,69,174,1,190,118,145,255,60,98,219,255,217,13,245,255,250,136,10,0,84,254,226,0,201,31,125,1,240,51,251,255,31,131,130,255,2,138,50,255,215,215,177,1,223,12,238,255,252,149,56,255,124,91,68,255,72,126,170,254,119,255,100,0,130,135,232,255,14,79,178,0,250,131,197,0,138,198,208,0,121,216,139,254,119,18,36,255,29,193,122,0,16,42,45,255,213,240,235,1,230,190,169,255,198,35,228,254,110,173,72,0,214,221,241,255,56,148,135,0,192,117,78,254,141,93,207,255,143,65,149,0,21,18,98,255,95,44,244,1,106,191,77,0,254,85,8,254,214,110,176,255,73,173,19,254,160,196,199,255,237,90,144,0,193,172,113,255,200,155,136,254,228,90,221,0,137,49,74,1,164,221,215,255,209,189,5,255,105,236,55,255,42,31,129,1,193,255,236,0,46,217,60,0,138,88,187,255,226,82,236,255,81,69,151,255,142,190,16,1,13,134,8,0,127,122,48,255,81,64,156,0,171,243,139,0,237,35,246,0,122,143,193,254,212,122,146,0,95,41,255,1,87,132,77,0,4,212,31,0,17,31,78,0,39,45,173,254,24,142,217,255,95,9,6,255,227,83,6,0,98,59,130,254,62,30,33,0,8,115,211,1,162,97,128,255,7,184,23,254,116,28,168,255,248,138,151,255,98,244,240,0,186,118,130,0,114,248,235,255,105,173,200,1,160,124,71,255,94,36,164,1,175,65,146,255,238,241,170,254,202,198,197,0,228,71,138,254,45,246,109,255,194,52,158,0,133,187,176,0,83,252,154,254,89,189,221,255,170,73,252,0,148,58,125,0,36,68,51,254,42,69,177,255,168,76,86,255,38,100,204,255,38,53,35,0,175,19,97,0,225,238,253,255,81,81,135,0,210,27,255,254,235,73,107,0,8,207,115,0,82,127,136,0,84,99,21,254,207,19,136,0,100,164,101,0,80,208,77,255,132,207,237,255,15,3,15,255,33,166,110,0,156,95,85,255,37,185,111,1,150,106,35,255,166,151,76,0,114,87,135,255,159,194,64,0,12,122,31,255,232,7,101,254,173,119,98,0,154,71,220,254,191,57,53,255,168,232,160,255,224,32,99,255,218,156,165,0,151,153,163,0,217,13,148,1,197,113,89,0,149,28,161,254,207,23,30,0,105,132,227,255,54,230,94,255,133,173,204,255,92,183,157,255,88,144,252,254,102,33,90,0,159,97,3,0,181,218,155,255,240,114,119,0,106,214,53,255,165,190,115,1,152,91,225,255,88,106,44,255,208,61,113,0,151,52,124,0,191,27,156,255,110,54,236,1,14,30,166,255,39,127,207,1,229,199,28,0,188,228,188,254,100,157,235,0,246,218,183,1,107,22,193,255,206,160,95,0,76,239,147,0,207,161,117,0,51,166,2,255,52,117,10,254,73,56,227,255,152,193,225,0,132,94,136,255,101,191,209,0,32,107,229,255,198,43,180,1,100,210,118,0,114,67,153,255,23,88,26,255,89,154,92,1,220,120,140,255,144,114,207,255,252,115,250,255,34,206,72,0,138,133,127,255,8,178,124,1,87,75,97,0,15,229,92,254,240,67,131,255,118,123,227,254,146,120,104,255,145,213,255,1,129,187,70,255,219,119,54,0,1,19,173,0,45,150,148,1,248,83,72,0,203,233,169,1,142,107,56,0,247,249,38,1,45,242,80,255,30,233,103,0,96,82,70,0,23,201,111,0,81,39,30,255,161,183,78,255,194,234,33,255,68,227,140,254,216,206,116,0,70,27,235,255,104,144,79,0,164,230,93,254,214,135,156,0,154,187,242,254,188,20,131,255,36,109,174,0,159,112,241,0,5,110,149,1,36,165,218,0,166,29,19,1,178,46,73,0,93,43,32,254,248,189,237,0,102,155,141,0,201,93,195,255,241,139,253,255,15,111,98,255,108,65,163,254,155,79,190,255,73,174,193,254,246,40,48,255,107,88,11,254,202,97,85,255,253,204,18,255,113,242,66,0,110,160,194,254,208,18,186,0,81,21,60,0,188,104,167,255,124,166,97,254,210,133,142,0,56,242,137,254,41,111,130,0,111,151,58,1,111,213,141,255,183,172,241,255,38,6,196,255,185,7,123,255,46,11,246,0,245,105,119,1,15,2,161,255,8,206,45,255,18,202,74,255,83,124,115,1,212,141,157,0,83,8,209,254,139,15,232,255,172,54,173,254,50,247,132,0,214,189,213,0,144,184,105,0,223,254,248,0,255,147,240,255,23,188,72,0,7,51,54,0,188,25,180,254,220,180,0,255,83,160,20,0,163,189,243,255,58,209,194,255,87,73,60,0,106,24,49,0,245,249,220,0,22,173,167,0,118,11,195,255,19,126,237,0,110,159,37,255,59,82,47,0,180,187,86,0,188,148,208,1,100,37,133,255,7,112,193,0,129,188,156,255,84,106,129,255,133,225,202,0,14,236,111,255,40,20,101,0,172,172,49,254,51,54,74,255,251,185,184,255,93,155,224,255,180,249,224,1,230,178,146,0,72,57,54,254,178,62,184,0,119,205,72,0,185,239,253,255,61,15,218,0,196,67,56,255,234,32,171,1,46,219,228,0,208,108,234,255,20,63,232,255,165,53,199,1,133,228,5,255,52,205,107,0,74,238,140,255,150,156,219,254,239,172,178,255,251,189,223,254,32,142,211,255,218,15,138,1,241,196,80,0,28,36,98,254,22,234,199,0,61,237,220,255,246,57,37,0,142,17,142,255,157,62,26,0,43,238,95,254,3,217,6,255,213,25,240,1,39,220,174,255,154,205,48,254,19,13,192,255,244,34,54,254,140,16,155,0,240,181,5,254,155,193,60,0,166,128,4,255,36,145,56,255,150,240,219,0,120,51,145,0,82,153,42,1,140,236,146,0,107,92,248,1,189,10,3,0,63,136,242,0,211,39,24,0,19,202,161,1,173,27,186,255,210,204,239,254,41,209,162,255,182,254,159,255,172,116,52,0,195,103,222,254,205,69,59,0,53,22,41,1,218,48,194,0,80,210,242,0,210,188,207,0,187,161,161,254,216,17,1,0,136,225,113,0,250,184,63,0,223,30,98,254,77,168,162,0,59,53,175,0,19,201,10,255,139,224,194,0,147,193,154,255,212,189,12,254,1,200,174,255,50,133,113,1,94,179,90,0,173,182,135,0,94,177,113,0,43,89,215,255,136,252,106,255,123,134,83,254,5,245,66,255,82,49,39,1,220,2,224,0,97,129,177,0,77,59,89,0,61,29,155,1,203,171,220,255,92,78,139,0,145,33,181,255,169,24,141,1,55,150,179,0,139,60,80,255,218,39,97,0,2,147,107,255,60,248,72,0,173,230,47,1,6,83,182,255,16,105,162,254,137,212,81,255,180,184,134,1,39,222,164,255,221,105,251,1,239,112,125,0,63,7,97,0,63,104,227,255,148,58,12,0,90,60,224,255,84,212,252,0,79,215,168,0,248,221,199,1,115,121,1,0,36,172,120,0,32,162,187,255,57,107,49,255,147,42,21,0,106,198,43,1,57,74,87,0,126,203,81,255,129,135,195,0,140,31,177,0,221,139,194,0,3,222,215,0,131,68,231,0,177,86,178,254,124,151,180,0,184,124,38,1,70,163,17,0,249,251,181,1,42,55,227,0,226,161,44,0,23,236,110,0,51,149,142,1,93,5,236,0,218,183,106,254,67,24,77,0,40,245,209,255,222,121,153,0,165,57,30,0,83,125,60,0,70,38,82,1,229,6,188,0,109,222,157,255,55,118,63,255,205,151,186,0,227,33,149,255,254,176,246,1,227,177,227,0,34,106,163,254,176,43,79,0,106,95,78,1,185,241,122,255,185,14,61,0,36,1,202,0,13,178,162,255,247,11,132,0,161,230,92,1,65,1,185,255,212,50,165,1,141,146,64,255,158,242,218,0,21,164,125,0,213,139,122,1,67,71,87,0,203,158,178,1,151,92,43,0,152,111,5,255,39,3,239,255,217,255,250,255,176,63,71,255,74,245,77,1,250,174,18,255,34,49,227,255,246,46,251,255,154,35,48,1,125,157,61,255,106,36,78,255,97,236,153,0,136,187,120,255,113,134,171,255,19,213,217,254,216,94,209,255,252,5,61,0,94,3,202,0,3,26,183,255,64,191,43,255,30,23,21,0,129,141,77,255,102,120,7,1,194,76,140,0,188,175,52,255,17,81,148,0,232,86,55,1,225,48,172,0,134,42,42,255,238,50,47,0,169,18,254,0,20,147,87,255,14,195,239,255,69,247,23,0,238,229,128,255,177,49,112,0,168,98,251,255,121,71,248,0,243,8,145,254,246,227,153,255,219,169,177,254,251,139,165,255,12,163,185,255,164,40,171,255,153,159,27,254,243,109,91,255,222,24,112,1,18,214,231,0,107,157,181,254,195,147,0,255,194,99,104,255,89,140,190,255,177,66,126,254,106,185,66],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE);allocate([49,218,31,0,252,174,158,0,188,79,230,1,238,41,224,0,212,234,8,1,136,11,181,0,166,117,83,255,68,195,94,0,46,132,201,0,240,152,88,0,164,57,69,254,160,224,42,255,59,215,67,255,119,195,141,255,36,180,121,254,207,47,8,255,174,210,223,0,101,197,68,255,255,82,141,1,250,137,233,0,97,86,133,1,16,80,69,0,132,131,159,0,116,93,100,0,45,141,139,0,152,172,157,255,90,43,91,0,71,153,46,0,39,16,112,255,217,136,97,255,220,198,25,254,177,53,49,0,222,88,134,255,128,15,60,0,207,192,169,255,192,116,209,255,106,78,211,1,200,213,183,255,7,12,122,254,222,203,60,255,33,110,199,254,251,106,117,0,228,225,4,1,120,58,7,255,221,193,84,254,112,133,27,0,189,200,201,255,139,135,150,0,234,55,176,255,61,50,65,0,152,108,169,255,220,85,1,255,112,135,227,0,162,26,186,0,207,96,185,254,244,136,107,0,93,153,50,1,198,97,151,0,110,11,86,255,143,117,174,255,115,212,200,0,5,202,183,0,237,164,10,254,185,239,62,0,236,120,18,254,98,123,99,255,168,201,194,254,46,234,214,0,191,133,49,255,99,169,119,0,190,187,35,1,115,21,45,255,249,131,72,0,112,6,123,255,214,49,181,254,166,233,34,0,92,197,102,254,253,228,205,255,3,59,201,1,42,98,46,0,219,37,35,255,169,195,38,0,94,124,193,1,156,43,223,0,95,72,133,254,120,206,191,0,122,197,239,255,177,187,79,255,254,46,2,1,250,167,190,0,84,129,19,0,203,113,166,255,249,31,189,254,72,157,202,255,208,71,73,255,207,24,72,0,10,16,18,1,210,81,76,255,88,208,192,255,126,243,107,255,238,141,120,255,199,121,234,255,137,12,59,255,36,220,123,255,148,179,60,254,240,12,29,0,66,0,97,1,36,30,38,255,115,1,93,255,96,103,231,255,197,158,59,1,192,164,240,0,202,202,57,255,24,174,48,0,89,77,155,1,42,76,215,0,244,151,233,0,23,48,81,0,239,127,52,254,227,130,37,255,248,116,93,1,124,132,118,0,173,254,192,1,6,235,83,255,110,175,231,1,251,28,182,0,129,249,93,254,84,184,128,0,76,181,62,0,175,128,186,0,100,53,136,254,109,29,226,0,221,233,58,1,20,99,74,0,0,22,160,0,134,13,21,0,9,52,55,255,17,89,140,0,175,34,59,0,84,165,119,255,224,226,234,255,7,72,166,255,123,115,255,1,18,214,246,0,250,7,71,1,217,220,185,0,212,35,76,255,38,125,175,0,189,97,210,0,114,238,44,255,41,188,169,254,45,186,154,0,81,92,22,0,132,160,193,0,121,208,98,255,13,81,44,255,203,156,82,0,71,58,21,255,208,114,191,254,50,38,147,0,154,216,195,0,101,25,18,0,60,250,215,255,233,132,235,255,103,175,142,1,16,14,92,0,141,31,110,254,238,241,45,255,153,217,239,1,97,168,47,255,249,85,16,1,28,175,62,255,57,254,54,0,222,231,126,0,166,45,117,254,18,189,96,255,228,76,50,0,200,244,94,0,198,152,120,1,68,34,69,255,12,65,160,254,101,19,90,0,167,197,120,255,68,54,185,255,41,218,188,0,113,168,48,0,88,105,189,1,26,82,32,255,185,93,164,1,228,240,237,255,66,182,53,0,171,197,92,255,107,9,233,1,199,120,144,255,78,49,10,255,109,170,105,255,90,4,31,255,28,244,113,255,74,58,11,0,62,220,246,255,121,154,200,254,144,210,178,255,126,57,129,1,43,250,14,255,101,111,28,1,47,86,241,255,61,70,150,255,53,73,5,255,30,26,158,0,209,26,86,0,138,237,74,0,164,95,188,0,142,60,29,254,162,116,248,255,187,175,160,0,151,18,16,0,209,111,65,254,203,134,39,255,88,108,49,255,131,26,71,255,221,27,215,254,104,105,93,255,31,236,31,254,135,0,211,255,143,127,110,1,212,73,229,0,233,67,167,254,195,1,208,255,132,17,221,255,51,217,90,0,67,235,50,255,223,210,143,0,179,53,130,1,233,106,198,0,217,173,220,255,112,229,24,255,175,154,93,254,71,203,246,255,48,66,133,255,3,136,230,255,23,221,113,254,235,111,213,0,170,120,95,254,251,221,2,0,45,130,158,254,105,94,217,255,242,52,180,254,213,68,45,255,104,38,28,0,244,158,76,0,161,200,96,255,207,53,13,255,187,67,148,0,170,54,248,0,119,162,178,255,83,20,11,0,42,42,192,1,146,159,163,255,183,232,111,0,77,229,21,255,71,53,143,0,27,76,34,0,246,136,47,255,219,39,182,255,92,224,201,1,19,142,14,255,69,182,241,255,163,118,245,0,9,109,106,1,170,181,247,255,78,47,238,255,84,210,176,255,213,107,139,0,39,38,11,0,72,21,150,0,72,130,69,0,205,77,155,254,142,133,21,0,71,111,172,254,226,42,59,255,179,0,215,1,33,128,241,0,234,252,13,1,184,79,8,0,110,30,73,255,246,141,189,0,170,207,218,1,74,154,69,255,138,246,49,255,155,32,100,0,125,74,105,255,90,85,61,255,35,229,177,255,62,125,193,255,153,86,188,1,73,120,212,0,209,123,246,254,135,209,38,255,151,58,44,1,92,69,214,255,14,12,88,255,252,153,166,255,253,207,112,255,60,78,83,255,227,124,110,0,180,96,252,255,53,117,33,254,164,220,82,255,41,1,27,255,38,164,166,255,164,99,169,254,61,144,70,255,192,166,18,0,107,250,66,0,197,65,50,0,1,179,18,255,255,104,1,255,43,153,35,255,80,111,168,0,110,175,168,0,41,105,45,255,219,14,205,255,164,233,140,254,43,1,118,0,233,67,195,0,178,82,159,255,138,87,122,255,212,238,90,255,144,35,124,254,25,140,164,0,251,215,44,254,133,70,107,255,101,227,80,254,92,169,55,0,215,42,49,0,114,180,85,255,33,232,27,1,172,213,25,0,62,176,123,254,32,133,24,255,225,191,62,0,93,70,153,0,181,42,104,1,22,191,224,255,200,200,140,255,249,234,37,0,149,57,141,0,195,56,208,255,254,130,70,255,32,173,240,255,29,220,199,0,110,100,115,255,132,229,249,0,228,233,223,255,37,216,209,254,178,177,209,255,183,45,165,254,224,97,114,0,137,97,168,255,225,222,172,0,165,13,49,1,210,235,204,255,252,4,28,254,70,160,151,0,232,190,52,254,83,248,93,255,62,215,77,1,175,175,179,255,160,50,66,0,121,48,208,0,63,169,209,255,0,210,200,0,224,187,44,1,73,162,82,0,9,176,143,255,19,76,193,255,29,59,167,1,24,43,154,0,28,190,190,0,141,188,129,0,232,235,203,255,234,0,109,255,54,65,159,0,60,88,232,255,121,253,150,254,252,233,131,255,198,110,41,1,83,77,71,255,200,22,59,254,106,253,242,255,21,12,207,255,237,66,189,0,90,198,202,1,225,172,127,0,53,22,202,0,56,230,132,0,1,86,183,0,109,190,42,0,243,68,174,1,109,228,154,0,200,177,122,1,35,160,183,255,177,48,85,255,90,218,169,255,248,152,78,0,202,254,110,0,6,52,43,0,142,98,65,255,63,145,22,0,70,106,93,0,232,138,107,1,110,179,61,255,211,129,218,1,242,209,92,0,35,90,217,1,182,143,106,255,116,101,217,255,114,250,221,255,173,204,6,0,60,150,163,0,73,172,44,255,239,110,80,255,237,76,153,254,161,140,249,0,149,232,229,0,133,31,40,255,174,164,119,0,113,51,214,0,129,228,2,254,64,34,243,0,107,227,244,255,174,106,200,255,84,153,70,1,50,35,16,0,250,74,216,254,236,189,66,255,153,249,13,0,230,178,4,255,221,41,238,0,118,227,121,255,94,87,140,254,254,119,92,0,73,239,246,254,117,87,128,0,19,211,145,255,177,46,252,0,229,91,246,1,69,128,247,255,202,77,54,1,8,11,9,255,153,96,166,0,217,214,173,255,134,192,2,1,0,207,0,0,189,174,107,1,140,134,100,0,158,193,243,1,182,102,171,0,235,154,51,0,142,5,123,255,60,168,89,1,217,14,92,255,19,214,5,1,211,167,254,0,44,6,202,254,120,18,236,255,15,113,184,255,184,223,139,0,40,177,119,254,182,123,90,255,176,165,176,0,247,77,194,0,27,234,120,0,231,0,214,255,59,39,30,0,125,99,145,255,150,68,68,1,141,222,248,0,153,123,210,255,110,127,152,255,229,33,214,1,135,221,197,0,137,97,2,0,12,143,204,255,81,41,188,0,115,79,130,255,94,3,132,0,152,175,187,255,124,141,10,255,126,192,179,255,11,103,198,0,149,6,45,0,219,85,187,1,230,18,178,255,72,182,152,0,3,198,184,255,128,112,224,1,97,161,230,0,254,99,38,255,58,159,197,0,151,66,219,0,59,69,143,255,185,112,249,0,119,136,47,255,123,130,132,0,168,71,95,255,113,176,40,1,232,185,173,0,207,93,117,1,68,157,108,255,102,5,147,254,49,97,33,0,89,65,111,254,247,30,163,255,124,217,221,1,102,250,216,0,198,174,75,254,57,55,18,0,227,5,236,1,229,213,173,0,201,109,218,1,49,233,239,0,30,55,158,1,25,178,106,0,155,111,188,1,94,126,140,0,215,31,238,1,77,240,16,0,213,242,25,1,38,71,168,0,205,186,93,254,49,211,140,255,219,0,180,255,134,118,165,0,160,147,134,255,110,186,35,255,198,243,42,0,243,146,119,0,134,235,163,1,4,241,135,255,193,46,193,254,103,180,79,255,225,4,184,254,242,118,130,0,146,135,176,1,234,111,30,0,69,66,213,254,41,96,123,0,121,94,42,255,178,191,195,255,46,130,42,0,117,84,8,255,233,49,214,254,238,122,109,0,6,71,89,1,236,211,123,0,244,13,48,254,119,148,14,0,114,28,86,255,75,237,25,255,145,229,16,254,129,100,53,255,134,150,120,254,168,157,50,0,23,72,104,255,224,49,14,0,255,123,22,255,151,185,151,255,170,80,184,1,134,182,20,0,41,100,101,1,153,33,16,0,76,154,111,1,86,206,234,255,192,160,164,254,165,123,93,255,1,216,164,254,67,17,175,255,169,11,59,255,158,41,61,255,73,188,14,255,195,6,137,255,22,147,29,255,20,103,3,255,246,130,227,255,122,40,128,0,226,47,24,254,35,36,32,0,152,186,183,255,69,202,20,0,195,133,195,0,222,51,247,0,169,171,94,1,183,0,160,255,64,205,18,1,156,83,15,255,197,58,249,254,251,89,110,255,50,10,88,254,51,43,216,0,98,242,198,1,245,151,113,0,171,236,194,1,197,31,199,255,229,81,38,1,41,59,20,0,253,104,230,0,152,93,14,255,246,242,146,254,214,169,240,255,240,102,108,254,160,167,236,0,154,218,188,0,150,233,202,255,27,19,250,1,2,71,133,255,175,12,63,1,145,183,198,0,104,120,115,255,130,251,247,0,17,212,167,255,62,123,132,255,247,100,189,0,155,223,152,0,143,197,33,0,155,59,44,255,150,93,240,1,127,3,87,255,95,71,207,1,167,85,1,255,188,152,116,255,10,23,23,0,137,195,93,1,54,98,97,0,240,0,168,255,148,188,127,0,134,107,151,0,76,253,171,0,90,132,192,0,146,22,54,0,224,66,54,254,230,186,229,255,39,182,196,0,148,251,130,255,65,131,108,254,128,1,160,0,169,49,167,254,199,254,148,255,251,6,131,0,187,254,129,255,85,82,62,0,178,23,58,255,254,132,5,0,164,213,39,0,134,252,146,254,37,53,81,255,155,134,82,0,205,167,238,255,94,45,180,255,132,40,161,0,254,111,112,1,54,75,217,0,179,230,221,1,235,94,191,255,23,243,48,1,202,145,203,255,39,118,42,255,117,141,253,0,254,0,222,0,43,251,50,0,54,169,234,1,80,68,208,0,148,203,243,254,145,7,135,0,6,254,0,0,252,185,127,0,98,8,129,255,38,35,72,255,211,36,220,1,40,26,89,0,168,64,197,254,3,222,239,255,2,83,215,254,180,159,105,0,58,115,194,0,186,116,106,255,229,247,219,255,129,118,193,0,202,174,183,1,166,161,72,0,201,107,147,254,237,136,74,0,233,230,106,1,105,111,168,0,64,224,30,1,1,229,3,0,102,151,175,255,194,238,228,255,254,250,212,0,187,237,121,0,67,251,96,1,197,30,11,0,183,95,204,0,205,89,138,0,64,221,37,1,255,223,30,255,178,48,211,255,241,200,90,255,167,209,96,255,57,130,221,0,46,114,200,255,61,184,66,0,55,182,24,254,110,182,33,0,171,190,232,255,114,94,31,0,18,221,8,0,47,231,254,0,255,112,83,0,118,15,215,255,173,25,40,254,192,193,31,255,238,21,146,255,171,193,118,255,101,234,53,254,131,212,112,0,89,192,107,1,8,208,27,0,181,217,15,255,231,149,232,0,140,236,126,0,144,9,199,255,12,79,181,254,147,182,202,255,19,109,182,255,49,212,225,0,74,163,203,0,175,233,148,0,26,112,51,0,193,193,9,255,15,135,249,0,150,227,130,0,204,0,219,1,24,242,205,0,238,208,117,255,22,244,112,0,26,229,34,0,37,80,188,255,38,45,206,254,240,90,225,255,29,3,47,255,42,224,76,0,186,243,167,0,32,132,15,255,5,51,125,0,139,135,24,0,6,241,219,0,172,229,133,255,246,214,50,0,231,11,207,255,191,126,83,1,180,163,170,255,245,56,24,1,178,164,211,255,3,16,202,1,98,57,118,255,141,131,89,254,33,51,24,0,243,149,91,255,253,52,14,0,35,169,67,254,49,30,88,255,179,27,36,255,165,140,183,0,58,189,151,0,88,31,0,0,75,169,66,0,66,101,199,255,24,216,199,1,121,196,26,255,14,79,203,254,240,226,81,255,94,28,10,255,83,193,240,255,204,193,131,255,94,15,86,0,218,40,157,0,51,193,209,0,0,242,177,0,102,185,247,0,158,109,116,0,38,135,91,0,223,175,149,0,220,66,1,255,86,60,232,0,25,96,37,255,225,122,162,1,215,187,168,255,158,157,46,0,56,171,162,0,232,240,101,1,122,22,9,0,51,9,21,255,53,25,238,255,217,30,232,254,125,169,148,0,13,232,102,0,148,9,37,0,165,97,141,1,228,131,41,0,222,15,243,255,254,18,17,0,6,60,237,1,106,3,113,0,59,132,189,0,92,112,30,0,105,208,213,0,48,84,179,255,187,121,231,254,27,216,109,255,162,221,107,254,73,239,195,255,250,31,57,255,149,135,89,255,185,23,115,1,3,163,157,255,18,112,250,0,25,57,187,255,161,96,164,0,47,16,243,0,12,141,251,254,67,234,184,255,41,18,161,0,175,6,96,255,160,172,52,254,24,176,183,255,198,193,85,1,124,121,137,255,151,50,114,255,220,203,60,255,207,239,5,1,0,38,107,255,55,238,94,254,70,152,94,0,213,220,77,1,120,17,69,255,85,164,190,255,203,234,81,0,38,49,37,254,61,144,124,0,137,78,49,254,168,247,48,0,95,164,252,0,105,169,135,0,253,228,134,0,64,166,75,0,81,73,20,255,207,210,10,0,234,106,150,255,94,34,90,255,254,159,57,254,220,133,99,0,139,147,180,254,24,23,185,0,41,57,30,255,189,97,76,0,65,187,223,255,224,172,37,255,34,62,95,1,231,144,240,0,77,106,126,254,64,152,91,0,29,98,155,0,226,251,53,255,234,211,5,255,144,203,222,255,164,176,221,254,5,231,24,0,179,122,205,0,36,1,134,255,125,70,151,254,97,228,252,0,172,129,23,254,48,90,209,255,150,224,82,1,84,134,30,0,241,196,46,0,103,113,234,255,46,101,121,254,40,124,250,255,135,45,242,254,9,249,168,255,140,108,131,255,143,163,171,0,50,173,199,255,88,222,142,255,200,95,158,0,142,192,163,255,7,117,135,0,111,124,22,0,236,12,65,254,68,38,65,255,227,174,254,0,244,245,38,0,240,50,208,255,161,63,250,0,60,209,239,0,122,35,19,0,14,33,230,254,2,159,113,0,106,20,127,255,228,205,96,0,137,210,174,254,180,212,144,255,89,98,154,1,34,88,139,0,167,162,112,1,65,110,197,0,241,37,169,0,66,56,131,255,10,201,83,254,133,253,187,255,177,112,45,254,196,251,0,0,196,250,151,255,238,232,214,255,150,209,205,0,28,240,118,0,71,76,83,1,236,99,91,0,42,250,131,1,96,18,64,255,118,222,35,0,113,214,203,255,122,119,184,255,66,19,36,0,204,64,249,0,146,89,139,0,134,62,135,1,104,233,101,0,188,84,26,0,49,249,129,0,208,214,75,255,207,130,77,255,115,175,235,0,171,2,137,255,175,145,186,1,55,245,135,255,154,86,181,1,100,58,246,255,109,199,60,255,82,204,134,255,215,49,230,1,140,229,192,255,222,193,251,255,81,136,15,255,179,149,162,255,23,39,29,255,7,95,75,254,191,81,222,0,241,81,90,255,107,49,201,255,244,211,157,0,222,140,149,255,65,219,56,254,189,246,90,255,178,59,157,1,48,219,52,0,98,34,215,0,28,17,187,255,175,169,24,0,92,79,161,255,236,200,194,1,147,143,234,0,229,225,7,1,197,168,14,0,235,51,53,1,253,120,174,0,197,6,168,255,202,117,171,0,163,21,206,0,114,85,90,255,15,41,10,255,194,19,99,0,65,55,216,254,162,146,116,0,50,206,212,255,64,146,29,255,158,158,131,1,100,165,130,255,172,23,129,255,125,53,9,255,15,193,18,1,26,49,11,255,181,174,201,1,135,201,14,255,100,19,149,0,219,98,79,0,42,99,143,254,96,0,48,255,197,249,83,254,104,149,79,255,235,110,136,254,82,128,44,255,65,41,36,254,88,211,10,0,187,121,187,0,98,134,199,0,171,188,179,254,210,11,238,255,66,123,130,254,52,234,61,0,48,113,23,254,6,86,120,255,119,178,245,0,87,129,201,0,242,141,209,0,202,114,85,0,148,22,161,0,103,195,48,0,25,49,171,255,138,67,130,0,182,73,122,254,148,24,130,0,211,229,154,0,32,155,158,0,84,105,61,0,177,194,9,255,166,89,86,1,54,83,187,0,249,40,117,255,109,3,215,255,53,146,44,1,63,47,179,0,194,216,3,254,14,84,136,0,136,177,13,255,72,243,186,255,117,17,125,255,211,58,211,255,93,79,223,0,90,88,245,255,139,209,111,255,70,222,47,0,10,246,79,255,198,217,178,0,227,225,11,1,78,126,179,255,62,43,126,0,103,148,35,0,129,8,165,254,245,240,148,0,61,51,142,0,81,208,134,0,15,137,115,255,211,119,236,255,159,245,248,255,2,134,136,255,230,139,58,1,160,164,254,0,114,85,141,255,49,166,182,255,144,70,84,1,85,182,7,0,46,53,93,0,9,166,161,255,55,162,178,255,45,184,188,0,146,28,44,254,169,90,49,0,120,178,241,1,14,123,127,255,7,241,199,1,189,66,50,255,198,143,101,254,189,243,135,255,141,24,24,254,75,97,87,0,118,251,154,1,237,54,156,0,171,146,207,255,131,196,246,255,136,64,113,1,151,232,57,0,240,218,115,0,49,61,27,255,64,129,73,1,252,169,27,255,40,132,10,1,90,201,193,255,252,121,240,1,186,206,41,0,43,198,97,0,145,100,183,0,204,216,80,254,172,150,65,0,249,229,196,254,104,123,73,255,77,104,96,254,130,180,8,0,104,123,57,0,220,202,229,255,102,249,211,0,86,14,232,255,182,78,209,0,239,225,164,0,106,13,32,255,120,73,17,255,134,67,233,0,83,254,181,0,183,236,112,1,48,64,131,255,241,216,243,255,65,193,226,0,206,241,100,254,100,134,166,255,237,202,197,0,55,13,81,0,32,124,102,255,40,228,177,0,118,181,31,1,231,160,134,255,119,187,202,0,0,142,60,255,128,38,189,255,166,201,150,0,207,120,26,1,54,184,172,0,12,242,204,254,133,66,230,0,34,38,31,1,184,112,80,0,32,51,165,254,191,243,55,0,58,73,146,254,155,167,205,255,100,104,152,255,197,254,207,255,173,19,247,0,238,10,202,0,239,151,242,0,94,59,39,255,240,29,102,255,10,92,154,255,229,84,219,255,161,129,80,0,208,90,204,1,240,219,174,255,158,102,145,1,53,178,76,255,52,108,168,1,83,222,107,0,211,36,109,0,118,58,56,0,8,29,22,0,237,160,199,0,170,209,157,0,137,71,47,0,143,86,32,0,198,242,2,0,212,48,136,1,92,172,186,0,230,151,105,1,96,191,229,0,138,80,191,254,240,216,130,255,98,43,6,254,168,196,49,0,253,18,91,1,144,73,121,0,61,146,39,1,63,104,24,255,184,165,112,254,126,235,98,0,80,213,98,255,123,60,87,255,82,140,245,1,223,120,173,255,15,198,134,1,206,60,239,0,231,234,92,255,33,238,19,255,165,113,142,1,176,119,38,0,160,43,166,254,239,91,105,0,107,61,194,1,25,4,68,0,15,139,51,0,164,132,106,255,34,116,46,254,168,95,197,0,137,212,23,0,72,156,58,0,137,112,69,254,150,105,154,255,236,201,157,0,23,212,154,255,136,82,227,254,226,59,221,255,95,149,192,0,81,118,52,255,33,43,215,1,14,147,75,255,89,156,121,254,14,18,79,0,147,208,139,1,151,218,62,255,156,88,8,1,210,184,98,255,20,175,123,255,102,83,229,0,220,65,116,1,150,250,4,255,92,142,220,255,34,247,66,255,204,225,179,254,151,81,151,0,71,40,236,255,138,63,62,0,6,79,240,255,183,185,181,0,118,50,27,0,63,227,192,0,123,99,58,1,50,224,155,255,17,225,223,254,220,224,77,255,14,44,123,1,141,128,175,0,248,212,200,0,150,59,183,255,147,97,29,0,150,204,181,0,253,37,71,0,145,85,119,0,154,200,186,0,2,128,249,255,83,24,124,0,14,87,143,0,168,51,245,1,124,151,231,255,208,240,197,1,124,190,185,0,48,58,246,0,20,233,232,0,125,18,98,255,13,254,31,255,245,177,130,255,108,142,35,0,171,125,242,254,140,12,34,255,165,161,162,0,206,205,101,0,247,25,34,1,100,145,57,0,39,70,57,0,118,204,203,255,242,0,162,0,165,244,30,0,198,116,226,0,128,111,153,255,140,54,182,1,60,122,15,255,155,58,57,1,54,50,198,0,171,211,29,255,107,138,167,255,173,107,199,255,109,161,193,0,89,72,242,255,206,115,89,255,250,254,142,254,177,202,94,255,81,89,50,0,7,105,66,255,25,254,255,254,203,64,23,255,79,222,108,255,39,249,75,0,241,124,50,0,239,152,133,0,221,241,105,0,147,151,98,0,213,161,121,254,242,49,137,0,233,37,249,254,42,183,27,0,184,119,230,255,217,32,163,255,208,251,228,1,137,62,131,255,79,64,9,254,94,48,113,0,17,138,50,254,193,255,22,0,247,18,197,1,67,55,104,0,16,205,95,255,48,37,66,0,55,156,63,1,64,82,74,255,200,53,71,254,239,67,125,0,26,224,222,0,223,137,93,255,30,224,202,255,9,220,132,0,198,38,235,1,102,141,86,0,60,43,81,1,136,28,26,0,233,36,8,254,207,242,148,0,164,162,63,0,51,46,224,255,114,48,79,255,9,175,226,0,222,3,193,255,47,160,232,255,255,93,105,254,14,42,230,0,26,138,82,1,208,43,244,0,27,39,38,255,98,208,127,255,64,149,182,255,5,250,209,0,187,60,28,254,49,25,218,255,169,116,205,255,119,18,120,0,156,116,147,255,132,53,109,255,13,10,202,0,110,83,167,0,157,219,137,255,6,3,130,255,50,167,30,255,60,159,47,255,129,128,157,254,94,3,189,0,3,166,68,0,83,223,215,0,150,90,194,1,15,168,65,0,227,83,51,255,205,171,66,255,54,187,60,1,152,102,45,255,119,154,225,0,240,247,136,0,100,197,178,255,139,71,223,255,204,82,16,1,41,206,42,255,156,192,221,255,216,123,244,255,218,218,185,255,187,186,239,255,252,172,160,255,195,52,22,0,144,174,181,254,187,100,115,255,211,78,176,255,27,7,193,0,147,213,104,255,90,201,10,255,80,123,66,1,22,33,186,0,1,7,99,254,30,206,10,0,229,234,5,0,53,30,210,0,138,8,220,254,71,55,167,0,72,225,86,1,118,190,188,0,254,193,101,1,171,249,172,255,94,158,183,254,93,2,108,255,176,93,76,255,73,99,79,255,74,64,129,254,246,46,65,0,99,241,127,254,246,151,102,255,44,53,208,254,59,102,234,0,154,175,164,255,88,242,32,0,111,38,1,0,255,182,190,255,115,176,15,254,169,60,129,0,122,237,241,0,90,76,63,0,62,74,120,255,122,195,110,0,119,4,178,0,222,242,210,0,130,33,46,254,156,40,41,0,167,146,112,1,49,163,111,255,121,176,235,0,76,207,14,255,3,25,198,1,41,235,213,0,85,36,214,1,49,92,109,255,200,24,30,254,168,236,195,0,145,39,124,1,236,195,149,0,90,36,184,255,67,85,170,255,38,35,26,254,131,124,68,255,239,155,35,255,54,201,164,0,196,22,117,255,49,15,205,0,24,224,29,1,126,113,144,0,117,21,182,0,203,159,141,0,223,135,77,0,176,230,176,255,190,229,215,255,99,37,181,255,51,21,138,255,25,189,89,255,49,48,165,254,152,45,247,0,170,108,222,0,80,202,5,0,27,69,103,254,204,22,129,255,180,252,62,254,210,1,91,255,146,110,254,255,219,162,28,0,223,252,213,1,59,8,33,0,206,16,244,0,129,211,48,0,107,160,208,0,112,59,209,0,109,77,216,254,34,21,185,255,246,99,56,255,179,139,19,255,185,29,50,255,84,89,19,0,74,250,98,255,225,42,200,255,192,217,205,255,210,16,167,0,99,132,95,1,43,230,57,0,254,11,203,255,99,188,63,255,119,193,251,254,80,105,54,0,232,181,189,1,183,69,112,255,208,171,165,255,47,109,180,255,123,83,165,0,146,162,52,255,154,11,4,255,151,227,90,255,146,137,97,254,61,233,41,255,94,42,55,255,108,164,236,0,152,68,254,0,10,140,131,255,10,106,79,254,243,158,137,0,67,178,66,254,177,123,198,255,15,62,34,0,197,88,42,255,149,95,177,255,152,0,198,255,149,254,113,255,225,90,163,255,125,217,247,0,18,17,224,0,128,66,120,254,192,25,9,255,50,221,205,0,49,212,70,0,233,255,164,0,2,209,9,0,221,52,219,254,172,224,244,255,94,56,206,1,242,179,2,255,31,91,164,1,230,46,138,255,189,230,220,0,57,47,61,255,111,11,157,0,177,91,152,0,28,230,98,0,97,87,126,0,198,89,145,255,167,79,107,0,249,77,160,1,29,233,230,255,150,21,86,254,60,11,193,0,151,37,36,254,185,150,243,255,228,212,83,1,172,151,180,0,201,169,155,0,244,60,234,0,142,235,4,1,67,218,60,0,192,113,75,1,116,243,207,255,65,172,155,0,81,30,156,255,80,72,33,254,18,231,109,255,142,107,21,254,125,26,132,255,176,16,59,255,150,201,58,0,206,169,201,0,208,121,226,0,40,172,14,255,150,61,94,255,56,57,156,255,141,60,145,255,45,108,149,255,238,145,155,255,209,85,31,254,192,12,210,0,99,98,93,254,152,16,151,0,225,185,220,0,141,235,44,255,160,172,21,254,71,26,31,255,13,64,93,254,28,56,198,0,177,62,248,1,182,8,241,0,166,101,148,255,78,81,133,255,129,222,215,1,188,169,129,255,232,7,97,0,49,112,60,255,217,229,251,0,119,108,138,0,39,19,123,254,131,49,235,0,132,84,145,0,130,230,148,255,25,74,187,0,5,245,54,255,185,219,241,1,18,194,228,255,241,202,102,0,105,113,202,0,155,235,79,0,21,9,178,255,156,1,239,0,200,148,61,0,115,247,210,255,49,221,135,0,58,189,8,1,35,46,9,0,81,65,5,255,52,158,185,255,125,116,46,255,74,140,13,255,210,92,172,254,147,23,71,0,217,224,253,254,115,108,180,255,145,58,48,254,219,177,24,255,156,255,60,1,154,147,242,0,253,134,87,0,53,75,229,0,48,195,222,255,31,175,50,255,156,210,120,255,208,35,222,255,18,248,179,1,2,10,101,255,157,194,248,255,158,204,101,255,104,254,197,255,79,62,4,0,178,172,101,1,96,146,251,255,65,10,156,0,2,137,165,255,116,4,231,0,242,215,1,0,19,35,29,255,43,161,79,0,59,149,246,1,251,66,176,0,200,33,3,255,80,110,142,255,195,161,17,1,228,56,66,255,123,47,145,254,132,4,164,0,67,174,172,0,25,253,114,0,87,97,87,1,250,220,84,0,96,91,200,255,37,125,59,0,19,65,118,0,161,52,241,255,237,172,6,255,176,191,255,255,1,65,130,254,223,190,230,0,101,253,231,255,146,35,109,0,250,29,77,1,49,0,19,0,123,90,155,1,22,86,32,255,218,213,65,0,111,93,127,0,60,93,169,255,8,127,182,0,17,186,14,254,253,137,246,255,213,25,48,254,76,238,0,255,248,92,70,255,99,224,139,0,184,9,255,1,7,164,208,0,205,131,198,1,87,214,199,0,130,214,95,0,221,149,222,0,23,38,171,254,197,110,213,0,43,115,140,254,215,177,118,0,96,52,66,1,117,158,237,0,14,64,182,255,46,63,174,255,158,95,190,255,225,205,177,255,43,5,142,255,172,99,212,255,244,187,147,0,29,51,153,255,228,116,24,254,30,101,207,0,19,246,150,255,134,231,5,0,125,134,226,1,77,65,98,0,236,130,33,255,5,110,62,0,69,108,127,255,7,113,22,0,145,20,83,254,194,161,231,255,131,181,60,0,217,209,177,255,229,148,212,254,3,131,184,0,117,177,187,1,28,14,31,255,176,102,80,0,50,84,151,255,125,31,54,255,21,157,133,255,19,179,139,1,224,232,26,0,34,117,170,255,167,252,171,255,73,141,206,254,129,250,35,0,72,79,236,1,220,229,20,255,41,202,173,255,99,76,238,255,198,22,224,255,108,198,195,255,36,141,96,1,236,158,59,255,106,100,87,0,110,226,2,0,227,234,222,0,154,93,119,255,74,112,164,255,67,91,2,255,21,145,33,255,102,214,137,255,175,230,103,254,163,246,166,0,93,247,116,254,167,224,28,255,220,2,57,1,171,206,84,0,123,228,17,255,27,120,119,0,119,11,147,1,180,47,225,255,104,200,185,254,165,2,114,0,77,78,212,0,45,154,177,255,24,196,121,254,82,157,182,0,90,16,190,1,12,147,197,0,95,239,152,255,11,235,71,0,86,146,119,255,172,134,214,0,60,131,196,0,161,225,129,0,31,130,120,254,95,200,51,0,105,231,210,255,58,9,148,255,43,168,221,255,124,237,142,0,198,211,50,254,46,245,103,0,164,248,84,0,152,70,208,255,180,117,177,0,70,79,185,0,243,74,32,0,149,156,207,0,197,196,161,1,245,53,239,0,15,93,246,254,139,240,49,255,196,88,36,255,162,38,123,0,128,200,157,1,174,76,103,255,173,169,34,254,216,1,171,255,114,51,17,0,136,228,194,0,110,150,56,254,106,246,159,0,19,184,79,255,150,77,240,255,155,80,162,0,0,53,169,255,29,151,86,0,68,94,16,0,92,7,110,254,98,117,149,255,249,77,230,255,253,10,140,0,214,124,92,254,35,118,235,0,89,48,57,1,22,53,166,0,184,144,61,255,179,255,194,0,214,248,61,254,59,110,246,0,121,21,81,254,166,3,228,0,106,64,26,255,69,232,134,255,242,220,53,254,46,220,85,0,113,149,247,255,97,179,103,255,190,127,11,0,135,209,182,0,95,52,129,1,170,144,206,255,122,200,204,255,168,100,146,0,60,144,149,254,70,60,40,0,122,52,177,255,246,211,101,255,174,237,8,0,7,51,120,0,19,31,173,0,126,239,156,255,143,189,203,0,196,128,88,255,233,133,226,255,30,125,173,255,201,108,50,0,123,100,59,255,254,163,3,1,221,148,181,255,214,136,57,254,222,180,137,255,207,88,54,255,28,33,251,255,67,214,52,1,210,208,100,0,81,170,94,0,145,40,53,0,224,111,231,254,35,28,244,255,226,199,195,254,238,17,230,0,217,217,164,254,169,157,221,0,218,46,162,1,199,207,163,255,108,115,162,1,14,96,187,255,118,60,76,0,184,159,152,0,209,231,71,254,42,164,186,255,186,153,51,254,221,171,182,255,162,142,173,0,235,47,193,0,7,139,16,1,95,164,64,255,16,221,166,0,219,197,16,0,132,29,44,255,100,69,117,255,60,235,88,254,40,81,173,0,71,190,61,255,187,88,157,0,231,11,23,0,237,117,164,0,225,168,223,255,154,114,116,255,163,152,242,1,24,32,170,0,125,98,113,254,168,19,76,0,17,157,220,254,155,52,5,0,19,111,161,255,71,90,252,255,173,110,240,0,10,198,121,255,253,255,240,255,66,123,210,0,221,194,215,254,121,163,17,255,225,7,99,0,190,49,182,0,115,9,133,1,232,26,138,255,213,68,132,0,44,119,122,255,179,98,51,0,149,90,106,0,71,50,230,255,10,153,118,255,177,70,25,0,165,87,205,0,55,138,234,0,238,30,97,0,113,155,207,0,98,153,127,0,34,107,219,254,117,114,172,255,76,180,255,254,242,57,179,255,221,34,172,254,56,162,49,255,83,3,255,255,113,221,189,255,188,25,228,254,16,88,89,255,71,28,198,254,22,17,149,255,243,121,254,255,107,202,99,255,9,206,14,1,220,47,153,0,107,137,39,1,97,49,194,255,149,51,197,254,186,58,11,255,107,43,232,1,200,6,14,255,181,133,65,254,221,228,171,255,123,62,231,1,227,234,179,255,34,189,212,254,244,187,249,0,190,13,80,1,130,89,1,0,223,133,173,0,9,222,198,255,66,127,74,0,167,216,93,255,155,168,198,1,66,145,0,0,68,102,46,1,172,90,154,0,216,128,75,255,160,40,51,0,158,17,27,1,124,240,49,0,236,202,176,255,151,124,192,255,38,193,190,0,95,182,61,0,163,147,124,255,255,165,51,255,28,40,17,254,215,96,78,0,86,145,218,254,31,36,202,255,86,9,5,0,111,41,200,255,237,108,97,0,57,62,44,0,117,184,15,1,45,241,116,0,152,1,220,255,157,165,188,0,250,15,131,1,60,44,125,255,65,220,251,255,75,50,184,0,53,90,128,255,231,80,194,255,136,129,127,1,21,18,187,255,45,58,161,255,71,147,34,0,174,249,11,254,35,141,29,0,239,68,177,255,115,110,58,0,238,190,177,1,87,245,166,255,190,49,247,255,146,83,184,255,173,14,39,255,146,215,104,0,142,223,120,0,149,200,155,255,212,207,145,1,16,181,217,0,173,32,87,255,255,35,181,0,119,223,161,1,200,223,94,255,70,6,186,255,192,67,85,255,50,169,152,0,144,26,123,255,56,243,179,254,20,68,136,0,39,140,188,254,253,208,5,255,200,115,135,1,43,172,229,255,156,104,187,0,151,251,167,0,52,135,23,0,151,153,72,0,147,197,107,254,148,158,5,255,238,143,206,0,126,153,137,255,88,152,197,254,7,68,167,0,252,159,165,255,239,78,54,255,24,63,55,255,38,222,94,0,237,183,12,255,206,204,210,0,19,39,246,254,30,74,231,0,135,108,29,1,179,115,0,0,117,118,116,1,132,6,252,255,145,129,161,1,105,67,141,0,82,37,226,255,238,226,228,255,204,214,129,254,162,123,100,255,185,121,234,0,45,108,231,0,66,8,56,255,132,136,128,0,172,224,66,254,175,157,188,0,230,223,226,254,242,219,69,0,184,14,119,1,82,162,56,0,114,123,20,0,162,103,85,255,49,239,99,254,156,135,215,0,111,255,167,254,39,196,214,0,144,38,79,1,249,168,125,0,155,97,156,255,23,52,219,255,150,22,144,0,44,149,165,255,40,127,183,0,196,77,233,255,118,129,210,255,170,135,230,255,214,119,198,0,233,240,35,0,253,52,7,255,117,102,48,255,21,204,154,255,179,136,177,255,23,2,3,1,149,130,89,255,252,17,159,1,70,60,26,0,144,107,17,0,180,190,60,255,56,182,59,255,110,71,54,255,198,18,129,255,149,224,87,255,223,21,152,255,138,22,182,255,250,156,205,0,236,45,208,255,79,148,242,1,101,70,209,0,103,78,174,0,101,144,172,255,152,136,237,1,191,194,136,0,113,80,125,1,152,4,141,0,155,150,53,255,196,116,245,0,239,114,73,254,19,82,17,255,124,125,234,255,40,52,191,0,42,210,158,255,155,132,165,0,178,5,42,1,64,92,40,255,36,85,77,255,178,228,118,0,137,66,96,254,115,226,66,0,110,240,69,254,151,111,80,0,167,174,236,255,227,108,107,255,188,242,65,255,183,81,255,0,57,206,181,255,47,34,181,255,213,240,158,1,71,75,95,0,156,40,24,255,102,210,81,0,171,199,228,255,154,34,41,0,227,175,75,0,21,239,195,0,138,229,95,1,76,192,49,0,117,123,87,1,227,225,130,0,125,62,63,255,2,198,171,0,254,36,13,254,145,186,206,0,148,255,244,255,35,0,166,0,30,150,219,1,92,228,212,0,92,198,60,254,62,133,200,255,201,41,59,0,125,238,109,255,180,163,238,1,140,122,82,0,9,22,88,255,197,157,47,255,153,94,57,0,88,30,182,0,84,161,85,0,178,146,124,0,166,166,7,255,21,208,223,0,156,182,242,0,155,121,185,0,83,156,174,254,154,16,118,255,186,83,232,1,223,58,121,255,29,23,88,0,35,125,127,255,170,5,149,254,164,12,130,255,155,196,29,0,161,96,136,0,7,35,29,1,162,37,251,0,3,46,242,255,0,217,188,0,57,174,226,1,206,233,2,0,57,187,136,254,123,189,9,255,201,117,127,255,186,36,204,0,231,25,216,0,80,78,105,0,19,134,129,255,148,203,68,0,141,81,125,254,248,165,200,255,214,144,135,0,151,55,166,255,38,235,91,0,21,46,154,0,223,254,150,255,35,153,180,255,125,176,29,1,43,98,30,255,216,122,230,255,233,160,12,0,57,185,12,254,240,113,7,255,5,9,16,254,26,91,108,0,109,198,203,0,8,147,40,0,129,134,228,255,124,186,40,255,114,98,132,254,166,132,23,0,99,69,44,0,9,242,238,255,184,53,59,0,132,129,102,255,52,32,243,254,147,223,200,255,123,83,179,254,135,144,201,255,141,37,56,1,151,60,227,255,90,73,156,1,203,172,187,0,80,151,47,255,94,137,231,255,36,191,59,255,225,209,181,255,74,215,213,254,6,118,179,255,153,54,193,1,50,0,231,0,104,157,72,1,140,227,154,255,182,226,16,254,96,225,92,255,115,20,170,254,6,250,78,0,248,75,173,255,53,89,6,255,0,180,118,0,72,173,1,0,64,8,206,1,174,133,223,0,185,62,133,255,214,11,98,0,197,31,208,0,171,167,244,255,22,231,181,1,150,218,185,0,247,169,97,1,165,139,247,255,47,120,149,1,103,248,51,0,60,69,28,254,25,179,196,0,124,7,218,254,58,107,81,0,184,233,156,255,252,74,36,0,118,188,67,0,141,95,53,255,222,94,165,254,46,61,53,0,206,59,115,255,47,236,250,255,74,5,32,1,129,154,238,255,106,32,226,0,121,187,61,255,3,166,241,254,67,170,172,255,29,216,178,255,23,201,252,0,253,110,243,0,200,125,57,0,109,192,96,255,52,115,238,0,38,121,243,255,201,56,33,0,194,118,130,0,75,96,25,255,170,30,230,254,39,63,253,0,36,45,250,255,251,1,239,0,160,212,92,1,45,209,237,0,243,33,87,254,237,84,201,255,212,18,157,254,212,99,127,255,217,98,16,254,139,172,239,0,168,201,130,255,143,193,169,255,238,151,193,1,215,104,41,0,239,61,165,254,2,3,242,0,22,203,177,254,177,204,22,0,149,129,213,254,31,11,41,255,0,159,121,254,160,25,114,255,162,80,200,0,157,151,11,0,154,134,78,1,216,54,252,0,48,103,133,0,105,220,197,0,253,168,77,254,53,179,23,0,24,121,240,1,255,46,96,255,107,60,135,254,98,205,249,255,63,249,119,255,120,59,211,255,114,180,55,254,91,85,237,0,149,212,77,1,56,73,49,0,86,198,150,0,93,209,160,0,69,205,182,255,244,90,43,0,20,36,176,0,122,116,221,0,51,167,39,1,231,1,63,255,13,197,134,0,3,209,34,255,135,59,202,0,167,100,78,0,47,223,76,0,185,60,62,0,178,166,123,1,132,12,161,255,61,174,43,0,195,69,144,0,127,47,191,1,34,44,78,0,57,234,52,1,255,22,40,255,246,94,146,0,83,228,128,0,60,78,224,255,0,96,210,255,153,175,236,0,159,21,73,0,180,115,196,254,131,225,106,0,255,167,134,0,159,8,112,255,120,68,194,255,176,196,198,255,118,48,168,255,93,169,1,0,112,200,102,1,74,24,254,0,19,141,4,254,142,62,63,0,131,179,187,255,77,156,155,255,119,86,164,0,170,208,146,255,208,133,154,255,148,155,58,255,162,120,232,254,252,213,155,0,241,13,42,0,94,50,131,0,179,170,112,0,140,83,151,255,55,119,84,1,140,35,239,255,153,45,67,1,236,175,39,0,54,151,103,255,158,42,65,255,196,239,135,254,86,53,203,0,149,97,47,254,216,35,17,255,70,3,70,1,103,36,90,255,40,26,173,0,184,48,13,0,163,219,217,255,81,6,1,255,221,170,108,254,233,208,93,0,100,201,249,254,86,36,35,255,209,154,30,1,227,201,251,255,2,189,167,254,100,57,3,0,13,128,41,0,197,100,75,0,150,204,235,255,145,174,59,0,120,248,149,255,85,55,225,0,114,210,53,254,199,204,119,0,14,247,74,1,63,251,129,0,67,104,151,1,135,130,80,0,79,89,55,255,117,230,157,255,25,96,143,0,213,145,5,0,69,241,120,1,149,243,95,255,114,42,20,0,131,72,2,0,154,53,20,255,73,62,109,0,196,102,152,0,41,12,204,255,122,38,11,1,250,10,145,0,207,125,148,0,246,244,222,255,41,32,85,1,112,213,126,0,162,249,86,1,71,198,127,255,81,9,21,1,98,39,4,255,204,71,45,1,75,111,137,0,234,59,231,0,32,48,95,255,204,31,114,1,29,196,181,255,51,241,167,254,93,109,142,0,104,144,45,0,235,12,181,255,52,112,164,0,76,254,202,255,174,14,162,0,61,235,147,255,43,64,185,254,233,125,217,0,243,88,167,254,74,49,8,0,156,204,66,0,124,214,123,0,38,221,118,1,146,112,236,0,114,98,177,0,151,89,199,0,87,197,112,0,185,149,161,0,44,96,165,0,248,179,20,255,188,219,216,254,40,62,13,0,243,142,141,0,229,227,206,255,172,202,35,255,117,176,225,255,82,110,38,1,42,245,14,255,20,83,97,0,49,171,10,0,242,119,120,0,25,232,61,0,212,240,147,255,4,115,56,255,145,17,239,254,202,17,251,255,249,18,245,255,99,117,239,0,184,4,179,255,246,237,51,255,37,239,137,255,166,112,166,255,81,188,33,255,185,250,142,255,54,187,173,0,208,112,201,0,246,43,228,1,104,184,88,255,212,52,196,255,51,117,108,255,254,117,155,0,46,91,15,255,87,14,144,255,87,227,204,0,83,26,83,1,159,76,227,0,159,27,213,1,24,151,108,0,117,144,179,254,137,209,82,0,38,159,10,0,115,133,201,0,223,182,156,1,110,196,93,255,57,60,233,0,5,167,105,255,154,197,164,0,96,34,186,255,147,133,37,1,220,99,190,0,1,167,84,255,20,145,171,0,194,197,251,254,95,78,133,255,252,248,243,255,225,93,131,255,187,134,196,255,216,153,170,0,20,118,158,254,140,1,118,0,86,158,15,1,45,211,41,255,147,1,100,254,113,116,76,255,211,127,108,1,103,15,48,0,193,16,102,1,69,51,95,255,107,128,157,0,137,171,233,0,90,124,144,1,106,161,182,0,175,76,236,1,200,141,172,255,163,58,104,0,233,180,52,255,240,253,14,255,162,113,254,255,38,239,138,254,52,46,166,0,241,101,33,254,131,186,156,0,111,208,62,255,124,94,160,255,31,172,254,0,112,174,56,255,188,99,27,255,67,138,251,0,125,58,128,1,156,152,174,255,178,12,247,255,252,84,158,0,82,197,14,254,172,200,83,255,37,39,46,1,106,207,167,0,24,189,34,0,131,178,144,0,206,213,4,0,161,226,210,0,72,51,105,255,97,45,187,255,78,184,223,255,176,29,251,0,79,160,86,255,116,37,178,0,82,77,213,1,82,84,141,255,226,101,212,1,175,88,199,255,245,94,247,1,172,118,109,255,166,185,190,0,131,181,120,0,87,254,93,255,134,240,73,255,32,245,143,255,139,162,103,255,179,98,18,254,217,204,112,0,147,223,120,255,53,10,243,0,166,140,150,0,125,80,200,255,14,109,219,255,91,218,1,255,252,252,47,254,109,156,116,255,115,49,127,1,204,87,211,255,148,202,217,255,26,85,249,255,14,245,134,1,76,89,169,255,242,45,230,0,59,98,172,255,114,73,132,254,78,155,49,255,158,126,84,0,49,175,43,255,16,182,84,255,157,103,35,0,104,193,109,255,67,221,154],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+10240);allocate([201,172,1,254,8,162,88,0,165,1,29,255,125,155,229,255,30,154,220,1,103,239,92,0,220,1,109,255,202,198,1,0,94,2,142,1,36,54,44,0,235,226,158,255,170,251,214,255,185,77,9,0,97,74,242,0,219,163,149,255,240,35,118,255,223,114,88,254,192,199,3,0,106,37,24,255,201,161,118,255,97,89,99,1,224,58,103,255,101,199,147,254,222,60,99,0,234,25,59,1,52,135,27,0,102,3,91,254,168,216,235,0,229,232,136,0,104,60,129,0,46,168,238,0,39,191,67,0,75,163,47,0,143,97,98,255,56,216,168,1,168,233,252,255,35,111,22,255,92,84,43,0,26,200,87,1,91,253,152,0,202,56,70,0,142,8,77,0,80,10,175,1,252,199,76,0,22,110,82,255,129,1,194,0,11,128,61,1,87,14,145,255,253,222,190,1,15,72,174,0,85,163,86,254,58,99,44,255,45,24,188,254,26,205,15,0,19,229,210,254,248,67,195,0,99,71,184,0,154,199,37,255,151,243,121,255,38,51,75,255,201,85,130,254,44,65,250,0,57,147,243,254,146,43,59,255,89,28,53,0,33,84,24,255,179,51,18,254,189,70,83,0,11,156,179,1,98,134,119,0,158,111,111,0,119,154,73,255,200,63,140,254,45,13,13,255,154,192,2,254,81,72,42,0,46,160,185,254,44,112,6,0,146,215,149,1,26,176,104,0,68,28,87,1,236,50,153,255,179,128,250,254,206,193,191,255,166,92,137,254,53,40,239,0,210,1,204,254,168,173,35,0,141,243,45,1,36,50,109,255,15,242,194,255,227,159,122,255,176,175,202,254,70,57,72,0,40,223,56,0,208,162,58,255,183,98,93,0,15,111,12,0,30,8,76,255,132,127,246,255,45,242,103,0,69,181,15,255,10,209,30,0,3,179,121,0,241,232,218,1,123,199,88,255,2,210,202,1,188,130,81,255,94,101,208,1,103,36,45,0,76,193,24,1,95,26,241,255,165,162,187,0,36,114,140,0,202,66,5,255,37,56,147,0,152,11,243,1,127,85,232,255,250,135,212,1,185,177,113,0,90,220,75,255,69,248,146,0,50,111,50,0,92,22,80,0,244,36,115,254,163,100,82,255,25,193,6,1,127,61,36,0,253,67,30,254,65,236,170,255,161,17,215,254,63,175,140,0,55,127,4,0,79,112,233,0,109,160,40,0,143,83,7,255,65,26,238,255,217,169,140,255,78,94,189,255,0,147,190,255,147,71,186,254,106,77,127,255,233,157,233,1,135,87,237,255,208,13,236,1,155,109,36,255,180,100,218,0,180,163,18,0,190,110,9,1,17,63,123,255,179,136,180,255,165,123,123,255,144,188,81,254,71,240,108,255,25,112,11,255,227,218,51,255,167,50,234,255,114,79,108,255,31,19,115,255,183,240,99,0,227,87,143,255,72,217,248,255,102,169,95,1,129,149,149,0,238,133,12,1,227,204,35,0,208,115,26,1,102,8,234,0,112,88,143,1,144,249,14,0,240,158,172,254,100,112,119,0,194,141,153,254,40,56,83,255,121,176,46,0,42,53,76,255,158,191,154,0,91,209,92,0,173,13,16,1,5,72,226,255,204,254,149,0,80,184,207,0,100,9,122,254,118,101,171,255,252,203,0,254,160,207,54,0,56,72,249,1,56,140,13,255,10,64,107,254,91,101,52,255,225,181,248,1,139,255,132,0,230,145,17,0,233,56,23,0,119,1,241,255,213,169,151,255,99,99,9,254,185,15,191,255,173,103,109,1,174,13,251,255,178,88,7,254,27,59,68,255,10,33,2,255,248,97,59,0,26,30,146,1,176,147,10,0,95,121,207,1,188,88,24,0,185,94,254,254,115,55,201,0,24,50,70,0,120,53,6,0,142,66,146,0,228,226,249,255,104,192,222,1,173,68,219,0,162,184,36,255,143,102,137,255,157,11,23,0,125,45,98,0,235,93,225,254,56,112,160,255,70,116,243,1,153,249,55,255,129,39,17,1,241,80,244,0,87,69,21,1,94,228,73,255,78,66,65,255,194,227,231,0,61,146,87,255,173,155,23,255,112,116,219,254,216,38,11,255,131,186,133,0,94,212,187,0,100,47,91,0,204,254,175,255,222,18,215,254,173,68,108,255,227,228,79,255,38,221,213,0,163,227,150,254,31,190,18,0,160,179,11,1,10,90,94,255,220,174,88,0,163,211,229,255,199,136,52,0,130,95,221,255,140,188,231,254,139,113,128,255,117,171,236,254,49,220,20,255,59,20,171,255,228,109,188,0,20,225,32,254,195,16,174,0,227,254,136,1,135,39,105,0,150,77,206,255,210,238,226,0,55,212,132,254,239,57,124,0,170,194,93,255,249,16,247,255,24,151,62,255,10,151,10,0,79,139,178,255,120,242,202,0,26,219,213,0,62,125,35,255,144,2,108,255,230,33,83,255,81,45,216,1,224,62,17,0,214,217,125,0,98,153,153,255,179,176,106,254,131,93,138,255,109,62,36,255,178,121,32,255,120,252,70,0,220,248,37,0,204,88,103,1,128,220,251,255,236,227,7,1,106,49,198,255,60,56,107,0,99,114,238,0,220,204,94,1,73,187,1,0,89,154,34,0,78,217,165,255,14,195,249,255,9,230,253,255,205,135,245,0,26,252,7,255,84,205,27,1,134,2,112,0,37,158,32,0,231,91,237,255,191,170,204,255,152,7,222,0,109,192,49,0,193,166,146,255,232,19,181,255,105,142,52,255,103,16,27,1,253,200,165,0,195,217,4,255,52,189,144,255,123,155,160,254,87,130,54,255,78,120,61,255,14,56,41,0,25,41,125,255,87,168,245,0,214,165,70,0,212,169,6,255,219,211,194,254,72,93,164,255,197,33,103,255,43,142,141,0,131,225,172,0,244,105,28,0,68,68,225,0,136,84,13,255,130,57,40,254,139,77,56,0,84,150,53,0,54,95,157,0,144,13,177,254,95,115,186,0,117,23,118,255,244,166,241,255,11,186,135,0,178,106,203,255,97,218,93,0,43,253,45,0,164,152,4,0,139,118,239,0,96,1,24,254,235,153,211,255,168,110,20,255,50,239,176,0,114,41,232,0,193,250,53,0,254,160,111,254,136,122,41,255,97,108,67,0,215,152,23,255,140,209,212,0,42,189,163,0,202,42,50,255,106,106,189,255,190,68,217,255,233,58,117,0,229,220,243,1,197,3,4,0,37,120,54,254,4,156,134,255,36,61,171,254,165,136,100,255,212,232,14,0,90,174,10,0,216,198,65,255,12,3,64,0,116,113,115,255,248,103,8,0,231,125,18,255,160,28,197,0,30,184,35,1,223,73,249,255,123,20,46,254,135,56,37,255,173,13,229,1,119,161,34,255,245,61,73,0,205,125,112,0,137,104,134,0,217,246,30,255,237,142,143,0,65,159,102,255,108,164,190,0,219,117,173,255,34,37,120,254,200,69,80,0,31,124,218,254,74,27,160,255,186,154,199,255,71,199,252,0,104,81,159,1,17,200,39,0,211,61,192,1,26,238,91,0,148,217,12,0,59,91,213,255,11,81,183,255,129,230,122,255,114,203,145,1,119,180,66,255,72,138,180,0,224,149,106,0,119,82,104,255,208,140,43,0,98,9,182,255,205,101,134,255,18,101,38,0,95,197,166,255,203,241,147,0,62,208,145,255,133,246,251,0,2,169,14,0,13,247,184,0,142,7,254,0,36,200,23,255,88,205,223,0,91,129,52,255,21,186,30,0,143,228,210,1,247,234,248,255,230,69,31,254,176,186,135,255,238,205,52,1,139,79,43,0,17,176,217,254,32,243,67,0,242,111,233,0,44,35,9,255,227,114,81,1,4,71,12,255,38,105,191,0,7,117,50,255,81,79,16,0,63,68,65,255,157,36,110,255,77,241,3,255,226,45,251,1,142,25,206,0,120,123,209,1,28,254,238,255,5,128,126,255,91,222,215,255,162,15,191,0,86,240,73,0,135,185,81,254,44,241,163,0,212,219,210,255,112,162,155,0,207,101,118,0,168,72,56,255,196,5,52,0,72,172,242,255,126,22,157,255,146,96,59,255,162,121,152,254,140,16,95,0,195,254,200,254,82,150,162,0,119,43,145,254,204,172,78,255,166,224,159,0,104,19,237,255,245,126,208,255,226,59,213,0,117,217,197,0,152,72,237,0,220,31,23,254,14,90,231,255,188,212,64,1,60,101,246,255,85,24,86,0,1,177,109,0,146,83,32,1,75,182,192,0,119,241,224,0,185,237,27,255,184,101,82,1,235,37,77,255,253,134,19,0,232,246,122,0,60,106,179,0,195,11,12,0,109,66,235,1,125,113,59,0,61,40,164,0,175,104,240,0,2,47,187,255,50,12,141,0,194,139,181,255,135,250,104,0,97,92,222,255,217,149,201,255,203,241,118,255,79,151,67,0,122,142,218,255,149,245,239,0,138,42,200,254,80,37,97,255,124,112,167,255,36,138,87,255,130,29,147,255,241,87,78,255,204,97,19,1,177,209,22,255,247,227,127,254,99,119,83,255,212,25,198,1,16,179,179,0,145,77,172,254,89,153,14,255,218,189,167,0,107,233,59,255,35,33,243,254,44,112,112,255,161,127,79,1,204,175,10,0,40,21,138,254,104,116,228,0,199,95,137,255,133,190,168,255,146,165,234,1,183,99,39,0,183,220,54,254,255,222,133,0,162,219,121,254,63,239,6,0,225,102,54,255,251,18,246,0,4,34,129,1,135,36,131,0,206,50,59,1,15,97,183,0,171,216,135,255,101,152,43,255,150,251,91,0,38,145,95,0,34,204,38,254,178,140,83,255,25,129,243,255,76,144,37,0,106,36,26,254,118,144,172,255,68,186,229,255,107,161,213,255,46,163,68,255,149,170,253,0,187,17,15,0,218,160,165,255,171,35,246,1,96,13,19,0,165,203,117,0,214,107,192,255,244,123,177,1,100,3,104,0,178,242,97,255,251,76,130,255,211,77,42,1,250,79,70,255,63,244,80,1,105,101,246,0,61,136,58,1,238,91,213,0,14,59,98,255,167,84,77,0,17,132,46,254,57,175,197,255,185,62,184,0,76,64,207,0,172,175,208,254,175,74,37,0,138,27,211,254,148,125,194,0,10,89,81,0,168,203,101,255,43,213,209,1,235,245,54,0,30,35,226,255,9,126,70,0,226,125,94,254,156,117,20,255,57,248,112,1,230,48,64,255,164,92,166,1,224,214,230,255,36,120,143,0,55,8,43,255,251,1,245,1,106,98,165,0,74,107,106,254,53,4,54,255,90,178,150,1,3,120,123,255,244,5,89,1,114,250,61,255,254,153,82,1,77,15,17,0,57,238,90,1,95,223,230,0,236,52,47,254,103,148,164,255,121,207,36,1,18,16,185,255,75,20,74,0,187,11,101,0,46,48,129,255,22,239,210,255,77,236,129,255,111,77,204,255,61,72,97,255,199,217,251,255,42,215,204,0,133,145,201,255,57,230,146,1,235,100,198,0,146,73,35,254,108,198,20,255,182,79,210,255,82,103,136,0,246,108,176,0,34,17,60,255,19,74,114,254,168,170,78,255,157,239,20,255,149,41,168,0,58,121,28,0,79,179,134,255,231,121,135,255,174,209,98,255,243,122,190,0,171,166,205,0,212,116,48,0,29,108,66,255,162,222,182,1,14,119,21,0,213,39,249,255,254,223,228,255,183,165,198,0,133,190,48,0,124,208,109,255,119,175,85,255,9,209,121,1,48,171,189,255,195,71,134,1,136,219,51,255,182,91,141,254,49,159,72,0,35,118,245,255,112,186,227,255,59,137,31,0,137,44,163,0,114,103,60,254,8,213,150,0,162,10,113,255,194,104,72,0,220,131,116,255,178,79,92,0,203,250,213,254,93,193,189,255,130,255,34,254,212,188,151,0,136,17,20,255,20,101,83,255,212,206,166,0,229,238,73,255,151,74,3,255,168,87,215,0,155,188,133,255,166,129,73,0,240,79,133,255,178,211,81,255,203,72,163,254,193,168,165,0,14,164,199,254,30,255,204,0,65,72,91,1,166,74,102,255,200,42,0,255,194,113,227,255,66,23,208,0,229,216,100,255,24,239,26,0,10,233,62,255,123,10,178,1,26,36,174,255,119,219,199,1,45,163,190,0,16,168,42,0,166,57,198,255,28,26,26,0,126,165,231,0,251,108,100,255,61,229,121,255,58,118,138,0,76,207,17,0,13,34,112,254,89,16,168,0,37,208,105,255,35,201,215,255,40,106,101,254,6,239,114,0,40,103,226,254,246,127,110,255,63,167,58,0,132,240,142,0,5,158,88,255,129,73,158,255,94,89,146,0,230,54,146,0,8,45,173,0,79,169,1,0,115,186,247,0,84,64,131,0,67,224,253,255,207,189,64,0,154,28,81,1,45,184,54,255,87,212,224,255,0,96,73,255,129,33,235,1,52,66,80,255,251,174,155,255,4,179,37,0,234,164,93,254,93,175,253,0,198,69,87,255,224,106,46,0,99,29,210,0,62,188,114,255,44,234,8,0,169,175,247,255,23,109,137,255,229,182,39,0,192,165,94,254,245,101,217,0,191,88,96,0,196,94,99,255,106,238,11,254,53,126,243,0,94,1,101,255,46,147,2,0,201,124,124,255,141,12,218,0,13,166,157,1,48,251,237,255,155,250,124,255,106,148,146,255,182,13,202,0,28,61,167,0,217,152,8,254,220,130,45,255,200,230,255,1,55,65,87,255,93,191,97,254,114,251,14,0,32,105,92,1,26,207,141,0,24,207,13,254,21,50,48,255,186,148,116,255,211,43,225,0,37,34,162,254,164,210,42,255,68,23,96,255,182,214,8,255,245,117,137,255,66,195,50,0,75,12,83,254,80,140,164,0,9,165,36,1,228,110,227,0,241,17,90,1,25,52,212,0,6,223,12,255,139,243,57,0,12,113,75,1,246,183,191,255,213,191,69,255,230,15,142,0,1,195,196,255,138,171,47,255,64,63,106,1,16,169,214,255,207,174,56,1,88,73,133,255,182,133,140,0,177,14,25,255,147,184,53,255,10,227,161,255,120,216,244,255,73,77,233,0,157,238,139,1,59,65,233,0,70,251,216,1,41,184,153,255,32,203,112,0,146,147,253,0,87,101,109,1,44,82,133,255,244,150,53,255,94,152,232,255,59,93,39,255,88,147,220,255,78,81,13,1,32,47,252,255,160,19,114,255,93,107,39,255,118,16,211,1,185,119,209,255,227,219,127,254,88,105,236,255,162,110,23,255,36,166,110,255,91,236,221,255,66,234,116,0,111,19,244,254,10,233,26,0,32,183,6,254,2,191,242,0,218,156,53,254,41,60,70,255,168,236,111,0,121,185,126,255,238,142,207,255,55,126,52,0,220,129,208,254,80,204,164,255,67,23,144,254,218,40,108,255,127,202,164,0,203,33,3,255,2,158,0,0,37,96,188,255,192,49,74,0,109,4,0,0,111,167,10,254,91,218,135,255,203,66,173,255,150,194,226,0,201,253,6,255,174,102,121,0,205,191,110,0,53,194,4,0,81,40,45,254,35,102,143,255,12,108,198,255,16,27,232,255,252,71,186,1,176,110,114,0,142,3,117,1,113,77,142,0,19,156,197,1,92,47,252,0,53,232,22,1,54,18,235,0,46,35,189,255,236,212,129,0,2,96,208,254,200,238,199,255,59,175,164,255,146,43,231,0,194,217,52,255,3,223,12,0,138,54,178,254,85,235,207,0,232,207,34,0,49,52,50,255,166,113,89,255,10,45,216,255,62,173,28,0,111,165,246,0,118,115,91,255,128,84,60,0,167,144,203,0,87,13,243,0,22,30,228,1,177,113,146,255,129,170,230,254,252,153,129,255,145,225,43,0,70,231,5,255,122,105,126,254,86,246,148,255,110,37,154,254,209,3,91,0,68,145,62,0,228,16,165,255,55,221,249,254,178,210,91,0,83,146,226,254,69,146,186,0,93,210,104,254,16,25,173,0,231,186,38,0,189,122,140,255,251,13,112,255,105,110,93,0,251,72,170,0,192,23,223,255,24,3,202,1,225,93,228,0,153,147,199,254,109,170,22,0,248,101,246,255,178,124,12,255,178,254,102,254,55,4,65,0,125,214,180,0,183,96,147,0,45,117,23,254,132,191,249,0,143,176,203,254,136,183,54,255,146,234,177,0,146,101,86,255,44,123,143,1,33,209,152,0,192,90,41,254,83,15,125,255,213,172,82,0,215,169,144,0,16,13,34,0,32,209,100,255,84,18,249,1,197,17,236,255,217,186,230,0,49,160,176,255,111,118,97,255,237,104,235,0,79,59,92,254,69,249,11,255,35,172,74,1,19,118,68,0,222,124,165,255,180,66,35,255,86,174,246,0,43,74,111,255,126,144,86,255,228,234,91,0,242,213,24,254,69,44,235,255,220,180,35,0,8,248,7,255,102,47,92,255,240,205,102,255,113,230,171,1,31,185,201,255,194,246,70,255,122,17,187,0,134,70,199,255,149,3,150,255,117,63,103,0,65,104,123,255,212,54,19,1,6,141,88,0,83,134,243,255,136,53,103,0,169,27,180,0,177,49,24,0,111,54,167,0,195,61,215,255,31,1,108,1,60,42,70,0,185,3,162,255,194,149,40,255,246,127,38,254,190,119,38,255,61,119,8,1,96,161,219,255,42,203,221,1,177,242,164,255,245,159,10,0,116,196,0,0,5,93,205,254,128,127,179,0,125,237,246,255,149,162,217,255,87,37,20,254,140,238,192,0,9,9,193,0,97,1,226,0,29,38,10,0,0,136,63,255,229,72,210,254,38,134,92,255,78,218,208,1,104,36,84,255,12,5,193,255,242,175,61,255,191,169,46,1,179,147,147,255,113,190,139,254,125,172,31,0,3,75,252,254,215,36,15,0,193,27,24,1,255,69,149,255,110,129,118,0,203,93,249,0,138,137,64,254,38,70,6,0,153,116,222,0,161,74,123,0,193,99,79,255,118,59,94,255,61,12,43,1,146,177,157,0,46,147,191,0,16,255,38,0,11,51,31,1,60,58,98,255,111,194,77,1,154,91,244,0,140,40,144,1,173,10,251,0,203,209,50,254,108,130,78,0,228,180,90,0,174,7,250,0,31,174,60,0,41,171,30,0,116,99,82,255,118,193,139,255,187,173,198,254,218,111,56,0,185,123,216,0,249,158,52,0,52,180,93,255,201,9,91,255,56,45,166,254,132,155,203,255,58,232,110,0,52,211,89,255,253,0,162,1,9,87,183,0,145,136,44,1,94,122,245,0,85,188,171,1,147,92,198,0,0,8,104,0,30,95,174,0,221,230,52,1,247,247,235,255,137,174,53,255,35,21,204,255,71,227,214,1,232,82,194,0,11,48,227,255,170,73,184,255,198,251,252,254,44,112,34,0,131,101,131,255,72,168,187,0,132,135,125,255,138,104,97,255,238,184,168,255,243,104,84,255,135,216,226,255,139,144,237,0,188,137,150,1,80,56,140,255,86,169,167,255,194,78,25,255,220,17,180,255,17,13,193,0,117,137,212,255,141,224,151,0,49,244,175,0,193,99,175,255,19,99,154,1,255,65,62,255,156,210,55,255,242,244,3,255,250,14,149,0,158,88,217,255,157,207,134,254,251,232,28,0,46,156,251,255,171,56,184,255,239,51,234,0,142,138,131,255,25,254,243,1,10,201,194,0,63,97,75,0,210,239,162,0,192,200,31,1,117,214,243,0,24,71,222,254,54,40,232,255,76,183,111,254,144,14,87,255,214,79,136,255,216,196,212,0,132,27,140,254,131,5,253,0,124,108,19,255,28,215,75,0,76,222,55,254,233,182,63,0,68,171,191,254,52,111,222,255,10,105,77,255,80,170,235,0,143,24,88,255,45,231,121,0,148,129,224,1,61,246,84,0,253,46,219,255,239,76,33,0,49,148,18,254,230,37,69,0,67,134,22,254,142,155,94,0,31,157,211,254,213,42,30,255,4,228,247,254,252,176,13,255,39,0,31,254,241,244,255,255,170,45,10,254,253,222,249,0,222,114,132,0,255,47,6,255,180,163,179,1,84,94,151,255,89,209,82,254,229,52,169,255,213,236,0,1,214,56,228,255,135,119,151,255,112,201,193,0,83,160,53,254,6,151,66,0,18,162,17,0,233,97,91,0,131,5,78,1,181,120,53,255,117,95,63,255,237,117,185,0,191,126,136,255,144,119,233,0,183,57,97,1,47,201,187,255,167,165,119,1,45,100,126,0,21,98,6,254,145,150,95,255,120,54,152,0,209,98,104,0,143,111,30,254,184,148,249,0,235,216,46,0,248,202,148,255,57,95,22,0,242,225,163,0,233,247,232,255,71,171,19,255,103,244,49,255,84,103,93,255,68,121,244,1,82,224,13,0,41,79,43,255,249,206,167,255,215,52,21,254,192,32,22,255,247,111,60,0,101,74,38,255,22,91,84,254,29,28,13,255,198,231,215,254,244,154,200,0,223,137,237,0,211,132,14,0,95,64,206,255,17,62,247,255,233,131,121,1,93,23,77,0,205,204,52,254,81,189,136,0,180,219,138,1,143,18,94,0,204,43,140,254,188,175,219,0,111,98,143,255,151,63,162,255,211,50,71,254,19,146,53,0,146,45,83,254,178,82,238,255,16,133,84,255,226,198,93,255,201,97,20,255,120,118,35,255,114,50,231,255,162,229,156,255,211,26,12,0,114,39,115,255,206,212,134,0,197,217,160,255,116,129,94,254,199,215,219,255,75,223,249,1,253,116,181,255,232,215,104,255,228,130,246,255,185,117,86,0,14,5,8,0,239,29,61,1,237,87,133,255,125,146,137,254,204,168,223,0,46,168,245,0,154,105,22,0,220,212,161,255,107,69,24,255,137,218,181,255,241,84,198,255,130,122,211,255,141,8,153,255,190,177,118,0,96,89,178,0,255,16,48,254,122,96,105,255,117,54,232,255,34,126,105,255,204,67,166,0,232,52,138,255,211,147,12,0,25,54,7,0,44,15,215,254,51,236,45,0,190,68,129,1,106,147,225,0,28,93,45,254,236,141,15,255,17,61,161,0,220,115,192,0,236,145,24,254,111,168,169,0,224,58,63,255,127,164,188,0,82,234,75,1,224,158,134,0,209,68,110,1,217,166,217,0,70,225,166,1,187,193,143,255,16,7,88,255,10,205,140,0,117,192,156,1,17,56,38,0,27,124,108,1,171,215,55,255,95,253,212,0,155,135,168,255,246,178,153,254,154,68,74,0,232,61,96,254,105,132,59,0,33,76,199,1,189,176,130,255,9,104,25,254,75,198,102,255,233,1,112,0,108,220,20,255,114,230,70,0,140,194,133,255,57,158,164,254,146,6,80,255,169,196,97,1,85,183,130,0,70,158,222,1,59,237,234,255,96,25,26,255,232,175,97,255,11,121,248,254,88,35,194,0,219,180,252,254,74,8,227,0,195,227,73,1,184,110,161,255,49,233,164,1,128,53,47,0,82,14,121,255,193,190,58,0,48,174,117,255,132,23,32,0,40,10,134,1,22,51,25,255,240,11,176,255,110,57,146,0,117,143,239,1,157,101,118,255,54,84,76,0,205,184,18,255,47,4,72,255,78,112,85,255,193,50,66,1,93,16,52,255,8,105,134,0,12,109,72,255,58,156,251,0,144,35,204,0,44,160,117,254,50,107,194,0,1,68,165,255,111,110,162,0,158,83,40,254,76,214,234,0,58,216,205,255,171,96,147,255,40,227,114,1,176,227,241,0,70,249,183,1,136,84,139,255,60,122,247,254,143,9,117,255,177,174,137,254,73,247,143,0,236,185,126,255,62,25,247,255,45,64,56,255,161,244,6,0,34,57,56,1,105,202,83,0,128,147,208,0,6,103,10,255,74,138,65,255,97,80,100,255,214,174,33,255,50,134,74,255,110,151,130,254,111,84,172,0,84,199,75,254,248,59,112,255,8,216,178,1,9,183,95,0,238,27,8,254,170,205,220,0,195,229,135,0,98,76,237,255,226,91,26,1,82,219,39,255,225,190,199,1,217,200,121,255,81,179,8,255,140,65,206,0,178,207,87,254,250,252,46,255,104,89,110,1,253,189,158,255,144,214,158,255,160,245,54,255,53,183,92,1,21,200,194,255,146,33,113,1,209,1,255,0,235,106,43,255,167,52,232,0,157,229,221,0,51,30,25,0,250,221,27,1,65,147,87,255,79,123,196,0,65,196,223,255,76,44,17,1,85,241,68,0,202,183,249,255,65,212,212,255,9,33,154,1,71,59,80,0,175,194,59,255,141,72,9,0,100,160,244,0,230,208,56,0,59,25,75,254,80,194,194,0,18,3,200,254,160,159,115,0,132,143,247,1,111,93,57,255,58,237,11,1,134,222,135,255,122,163,108,1,123,43,190,255,251,189,206,254,80,182,72,255,208,246,224,1,17,60,9,0,161,207,38,0,141,109,91,0,216,15,211,255,136,78,110,0,98,163,104,255,21,80,121,255,173,178,183,1,127,143,4,0,104,60,82,254,214,16,13,255,96,238,33,1,158,148,230,255,127,129,62,255,51,255,210,255,62,141,236,254,157,55,224,255,114,39,244,0,192,188,250,255,228,76,53,0,98,84,81,255,173,203,61,254,147,50,55,255,204,235,191,0,52,197,244,0,88,43,211,254,27,191,119,0,188,231,154,0,66,81,161,0,92,193,160,1,250,227,120,0,123,55,226,0,184,17,72,0,133,168,10,254,22,135,156,255,41,25,103,255,48,202,58,0,186,149,81,255,188,134,239,0,235,181,189,254,217,139,188,255,74,48,82,0,46,218,229,0,189,253,251,0,50,229,12,255,211,141,191,1,128,244,25,255,169,231,122,254,86,47,189,255,132,183,23,255,37,178,150,255,51,137,253,0,200,78,31,0,22,105,50,0,130,60,0,0,132,163,91,254,23,231,187,0,192,79,239,0,157,102,164,255,192,82,20,1,24,181,103,255,240,9,234,0,1,123,164,255,133,233,0,255,202,242,242,0,60,186,245,0,241,16,199,255,224,116,158,254,191,125,91,255,224,86,207,0,121,37,231,255,227,9,198,255,15,153,239,255,121,232,217,254,75,112,82,0,95,12,57,254,51,214,105,255,148,220,97,1,199,98,36,0,156,209,12,254,10,212,52,0,217,180,55,254,212,170,232,255,216,20,84,255,157,250,135,0,157,99,127,254,1,206,41,0,149,36,70,1,54,196,201,255,87,116,0,254,235,171,150,0,27,163,234,0,202,135,180,0,208,95,0,254,123,156,93,0,183,62,75,0,137,235,182,0,204,225,255,255,214,139,210,255,2,115,8,255,29,12,111,0,52,156,1,0,253,21,251,255,37,165,31,254,12,130,211,0,106,18,53,254,42,99,154,0,14,217,61,254,216,11,92,255,200,197,112,254,147,38,199,0,36,252,120,254,107,169,77,0,1,123,159,255,207,75,102,0,163,175,196,0,44,1,240,0,120,186,176,254,13,98,76,255,237,124,241,255,232,146,188,255,200,96,224,0,204,31,41,0,208,200,13,0,21,225,96,255,175,156,196,0,247,208,126,0,62,184,244,254,2,171,81,0,85,115,158,0,54,64,45,255,19,138,114,0,135,71,205,0,227,47,147,1,218,231,66,0,253,209,28,0,244,15,173,255,6,15,118,254,16,150,208,255,185,22,50,255,86,112,207,255,75,113,215,1,63,146,43,255,4,225,19,254,227,23,62,255,14,255,214,254,45,8,205,255,87,197,151,254,210,82,215,255,245,248,247,255,128,248,70,0,225,247,87,0,90,120,70,0,213,245,92,0,13,133,226,0,47,181,5,1,92,163,105,255,6,30,133,254,232,178,61,255,230,149,24,255,18,49,158,0,228,100,61,254,116,243,251,255,77,75,92,1,81,219,147,255,76,163,254,254,141,213,246,0,232,37,152,254,97,44,100,0,201,37,50,1,212,244,57,0,174,171,183,255,249,74,112,0,166,156,30,0,222,221,97,255,243,93,73,254,251,101,100,255,216,217,93,255,254,138,187,255,142,190,52,255,59,203,177,255,200,94,52,0,115,114,158,255,165,152,104,1,126,99,226,255,118,157,244,1,107,200,16,0,193,90,229,0,121,6,88,0,156,32,93,254,125,241,211,255,14,237,157,255,165,154,21,255,184,224,22,255,250,24,152,255,113,77,31,0,247,171,23,255,237,177,204,255,52,137,145,255,194,182,114,0,224,234,149,0,10,111,103,1,201,129,4,0,238,142,78,0,52,6,40,255,110,213,165,254,60,207,253,0,62,215,69,0,96,97,0,255,49,45,202,0,120,121,22,255,235,139,48,1,198,45,34,255,182,50,27,1,131,210,91,255,46,54,128,0,175,123,105,255,198,141,78,254,67,244,239,255,245,54,103,254,78,38,242,255,2,92,249,254,251,174,87,255,139,63,144,0,24,108,27,255,34,102,18,1,34,22,152,0,66,229,118,254,50,143,99,0,144,169,149,1,118,30,152,0,178,8,121,1,8,159,18,0,90,101,230,255,129,29,119,0,68,36,11,1,232,183,55,0,23,255,96,255,161,41,193,255,63,139,222,0,15,179,243,0,255,100,15,255,82,53,135,0,137,57,149,1,99,240,170,255,22,230,228,254,49,180,82,255,61,82,43,0,110,245,217,0,199,125,61,0,46,253,52,0,141,197,219,0,211,159,193,0,55,121,105,254,183,20,129,0,169,119,170,255,203,178,139,255,135,40,182,255,172,13,202,255,65,178,148,0,8,207,43,0,122,53,127,1,74,161,48,0,227,214,128,254,86,11,243,255,100,86,7,1,245,68,134,255,61,43,21,1,152,84,94,255,190,60,250,254,239,118,232,255,214,136,37,1,113,76,107,255,93,104,100,1,144,206,23,255,110,150,154,1,228,103,185,0,218,49,50,254,135,77,139,255,185,1,78,0,0,161,148,255,97,29,233,255,207,148,149,255,160,168,0,0,91,128,171,255,6,28,19,254,11,111,247,0,39,187,150,255,138,232,149,0,117,62,68,255,63,216,188,255,235,234,32,254,29,57,160,255,25,12,241,1,169,60,191,0,32,131,141,255,237,159,123,255,94,197,94,254,116,254,3,255,92,179,97,254,121,97,92,255,170,112,14,0,21,149,248,0,248,227,3,0,80,96,109,0,75,192,74,1,12,90,226,255,161,106,68,1,208,114,127,255,114,42,255,254,74,26,74,255,247,179,150,254,121,140,60,0,147,70,200,255,214,40,161,255,161,188,201,255,141,65,135,255,242,115,252,0,62,47,202,0,180,149,255,254,130,55,237,0,165,17,186,255,10,169,194,0,156,109,218,255,112,140,123,255,104,128,223,254,177,142,108,255,121,37,219,255,128,77,18,255,111,108,23,1,91,192,75,0,174,245,22,255,4,236,62,255,43,64,153,1,227,173,254,0,237,122,132,1,127,89,186,255,142,82,128,254,252,84,174,0,90,179,177,1,243,214,87,255,103,60,162,255,208,130,14,255,11,130,139,0,206,129,219,255,94,217,157,255,239,230,230,255,116,115,159,254,164,107,95,0,51,218,2,1,216,125,198,255,140,202,128,254,11,95,68,255,55,9,93,254,174,153,6,255,204,172,96,0,69,160,110,0,213,38,49,254,27,80,213,0,118,125,114,0,70,70,67,255,15,142,73,255,131,122,185,255,243,20,50,254,130,237,40,0,210,159,140,1,197,151,65,255,84,153,66,0,195,126,90,0,16,238,236,1,118,187,102,255,3,24,133,255,187,69,230,0,56,197,92,1,213,69,94,255,80,138,229,1,206,7,230,0,222,111,230,1,91,233,119,255,9,89,7,1,2,98,1,0,148,74,133,255,51,246,180,255,228,177,112,1,58,189,108,255,194,203,237,254,21,209,195,0,147,10,35,1,86,157,226,0,31,163,139,254,56,7,75,255,62,90,116,0,181,60,169,0,138,162,212,254,81,167,31,0,205,90,112,255,33,112,227,0,83,151,117,1,177,224,73,255,174,144,217,255,230,204,79,255,22,77,232,255,114,78,234,0,224,57,126,254,9,49,141,0,242,147,165,1,104,182,140,255,167,132,12,1,123,68,127,0,225,87,39,1,251,108,8,0,198,193,143,1,121,135,207,255,172,22,70,0,50,68,116,255,101,175,40,255,248,105,233,0,166,203,7,0,110,197,218,0,215,254,26,254,168,226,253,0,31,143,96,0,11,103,41,0,183,129,203,254,100,247,74,255,213,126,132,0,210,147,44,0,199,234,27,1,148,47,181,0,155,91,158,1,54,105,175,255,2,78,145,254,102,154,95,0,128,207,127,254,52,124,236,255,130,84,71,0,221,243,211,0,152,170,207,0,222,106,199,0,183,84,94,254,92,200,56,255,138,182,115,1,142,96,146,0,133,136,228,0,97,18,150,0,55,251,66,0,140,102,4,0,202,103,151,0,30,19,248,255,51,184,207,0,202,198,89,0,55,197,225,254,169,95,249,255,66,65,68,255,188,234,126,0,166,223,100,1,112,239,244,0,144,23,194,0,58,39,182,0,244,44,24,254,175,68,179,255,152,118,154,1,176,162,130,0,217,114,204,254,173,126,78,255,33,222,30,255,36,2,91,255,2,143,243,0,9,235,215,0,3,171,151,1,24,215,245,255,168,47,164,254,241,146,207,0,69,129,180,0,68,243,113,0,144,53,72,254,251,45,14,0,23,110,168,0,68,68,79,255,110,70,95,254,174,91,144,255,33,206,95,255,137,41,7,255,19,187,153,254,35,255,112,255,9,145,185,254,50,157,37,0,11,112,49,1,102,8,190,255,234,243,169,1,60,85,23,0,74,39,189,0,116,49,239,0,173,213,210,0,46,161,108,255,159,150,37,0,196,120,185,255,34,98,6,255,153,195,62,255,97,230,71,255,102,61,76,0,26,212,236,255,164,97,16,0,198,59,146,0,163,23,196,0,56,24,61,0,181,98,193,0,251,147,229,255,98,189,24,255,46,54,206,255,234,82,246,0,183,103,38,1,109,62,204,0,10,240,224,0,146,22,117,255,142,154,120,0,69,212,35,0,208,99,118,1,121,255,3,255,72,6,194,0,117,17,197,255,125,15,23,0,154,79,153,0,214,94,197,255,185,55,147,255,62,254,78,254,127,82,153,0,110,102,63,255,108,82,161,255,105,187,212,1,80,138,39,0,60,255,93,255,72,12,186,0,210,251,31,1,190,167,144,255,228,44,19,254,128,67,232,0,214,249,107,254,136,145,86,255,132,46,176,0,189,187,227,255,208,22,140,0,217,211,116,0,50,81,186,254,139,250,31,0,30,64,198,1,135,155,100,0,160,206,23,254,187,162,211,255,16,188,63,0,254,208,49,0,85,84,191,0,241,192,242,255,153,126,145,1,234,162,162,255,230,97,216,1,64,135,126,0,190,148,223,1,52,0,43,255,28,39,189,1,64,136,238,0,175,196,185,0,98,226,213,255,127,159,244,1,226,175,60,0,160,233,142,1,180,243,207,255,69,152,89,1,31,101,21,0,144,25,164,254,139,191,209,0,91,25,121,0,32,147,5,0,39,186,123,255,63,115,230,255,93,167,198,255,143,213,220,255,179,156,19,255,25,66,122,0,214,160,217,255,2,45,62,255,106,79,146,254,51,137,99,255,87,100,231,255,175,145,232,255,101,184,1,255,174,9,125,0,82,37,161,1,36,114,141,255,48,222,142,255,245,186,154,0,5,174,221,254,63,114,155,255,135,55,160,1,80,31,135,0,126,250,179,1,236,218,45,0,20,28,145,1,16,147,73,0,249,189,132,1,17,189,192,255,223,142,198,255,72,20,15,255,250,53,237,254,15,11,18,0,27,211,113,254,213,107,56,255,174,147,146,255,96,126,48,0,23,193,109,1,37,162,94,0,199,157,249,254,24,128,187,255,205,49,178,254,93,164,42,255,43,119,235,1,88,183,237,255,218,210,1,255,107,254,42,0,230,10,99,255,162,0,226,0,219,237,91,0,129,178,203,0,208,50,95,254,206,208,95,255,247,191,89,254,110,234,79,255,165,61,243,0,20,122,112,255,246,246,185,254,103,4,123,0,233,99,230,1,219,91,252,255,199,222,22,255,179,245,233,255,211,241,234,0,111,250,192,255,85,84,136,0,101,58,50,255,131,173,156,254,119,45,51,255,118,233,16,254,242,90,214,0,94,159,219,1,3,3,234,255,98,76,92,254,80,54,230,0,5,228,231,254,53,24,223,255,113,56,118,1,20,132,1,255,171,210,236,0,56,241,158,255,186,115,19,255,8,229,174,0,48,44,0,1,114,114,166,255,6,73,226,255,205,89,244,0,137,227,75,1,248,173,56,0,74,120,246,254,119,3,11,255,81,120,198,255,136,122,98,255,146,241,221,1,109,194,78,255,223,241,70,1,214,200,169,255,97,190,47,255,47,103,174,255,99,92,72,254,118,233,180,255,193,35,233,254,26,229,32,255,222,252,198,0,204,43,71,255,199,84,172,0,134,102,190,0,111,238,97,254,230,40,230,0,227,205,64,254,200,12,225,0,166,25,222,0,113,69,51,255,143,159,24,0,167,184,74,0,29,224,116,254,158,208,233,0,193,116,126,255,212,11,133,255,22,58,140,1,204,36,51,255,232,30,43,0,235,70,181,255,64,56,146,254,169,18,84,255,226,1,13,255,200,50,176,255,52,213,245,254,168,209,97,0,191,71,55,0,34,78,156,0,232,144,58,1,185,74,189,0,186,142,149,254,64,69,127,255,161,203,147,255,176,151,191,0,136,231,203,254,163,182,137,0,161,126,251,254,233,32,66,0,68,207,66,0,30,28,37,0,93,114,96,1,254,92,247,255,44,171,69,0,202,119,11,255,188,118,50,1,255,83,136,255,71,82,26,0,70,227,2,0,32,235,121,1,181,41,154,0,71,134,229,254,202,255,36,0,41,152,5,0,154,63,73,255,34,182,124,0,121,221,150,255,26,204,213,1,41,172,87,0,90,157,146,255,109,130,20,0,71,107,200,255,243,102,189,0,1,195,145,254,46,88,117,0,8,206,227,0,191,110,253,255,109,128,20,254,134,85,51,255,137,177,112,1,216,34,22,255,131,16,208,255,121,149,170,0,114,19,23,1,166,80,31,255,113,240,122,0,232,179,250,0,68,110,180,254,210,170,119,0,223,108,164,255,207,79,233,255,27,229,226,254,209,98,81,255,79,68,7,0,131,185,100,0,170,29,162,255,17,162,107,255,57,21,11,1,100,200,181,255,127,65,166,1,165,134,204,0,104,167,168,0,1,164,79,0,146,135,59,1,70,50,128,255,102,119,13,254,227,6,135,0,162,142,179,255,160,100,222,0,27,224,219,1,158,93,195,255,234,141,137,0,16,24,125,255,238,206,47,255,97,17,98,255,116,110,12,255,96,115,77,0,91,227,232,255,248,254,79,255,92,229,6,254,88,198,139,0,206,75,129,0,250,77,206,255,141,244,123,1,138,69,220,0,32,151,6,1,131,167,22,255,237,68,167,254,199,189,150,0,163,171,138,255,51,188,6,255,95,29,137,254,148,226,179,0,181,107,208,255,134,31,82,255,151,101,45,255,129,202,225,0,224,72,147,0,48,138,151,255,195,64,206,254,237,218,158,0,106,29,137,254,253,189,233,255,103,15,17,255,194,97,255,0,178,45,169,254,198,225,155,0,39,48,117,255,135,106,115,0,97,38,181,0,150,47,65,255,83,130,229,254,246,38,129,0,92,239,154,254,91,99,127,0,161,111,33,255,238,217,242,255,131,185,195,255,213,191,158,255,41,150,218,0,132,169,131,0,89,84,252,1,171,70,128,255,163,248,203,254,1,50,180,255,124,76,85,1,251,111,80,0,99,66,239,255,154,237,182,255,221,126,133,254,74,204,99,255,65,147,119,255,99,56,167,255,79,248,149,255,116,155,228,255,237,43,14,254,69,137,11,255,22,250,241,1,91,122,143,255,205,249,243,0,212,26,60,255,48,182,176,1,48,23,191,255,203,121,152,254,45,74,213,255,62,90,18,254,245,163,230,255,185,106,116,255,83,35,159,0,12,33,2,255,80,34,62,0,16,87,174,255,173,101,85,0,202,36,81,254,160,69,204,255,64,225,187,0,58,206,94,0,86,144,47,0,229,86,245,0,63,145,190,1,37,5,39,0,109,251,26,0,137,147,234,0,162,121,145,255,144,116,206,255,197,232,185,255,183,190,140,255,73,12,254,255,139,20,242,255,170,90,239,255,97,66,187,255,245,181,135,254,222,136,52,0,245,5,51,254,203,47,78,0,152,101,216,0,73,23,125,0,254,96,33,1,235,210,73,255,43,209,88,1,7,129,109,0,122,104,228,254,170,242,203,0,242,204,135,255,202,28,233,255,65,6,127,0,159,144,71,0,100,140,95,0,78,150,13,0,251,107,118,1,182,58,125,255,1,38,108,255,141,189,209,255,8,155,125,1,113,163,91,255,121,79,190,255,134,239,108,255,76,47,248,0,163,228,239,0,17,111,10,0,88,149,75,255,215,235,239,0,167,159,24,255,47,151,108,255,107,209,188,0,233,231,99,254,28,202,148,255,174,35,138,255,110,24,68,255,2,69,181,0,107,102,82,0,102,237,7,0,92,36,237,255,221,162,83,1,55,202,6,255,135,234,135,255,24,250,222,0,65,94,168,254,245,248,210,255,167,108,201,254,255,161,111,0,205,8,254,0,136,13,116,0,100,176,132,255,43,215,126,255,177,133,130,255,158,79,148,0,67,224,37,1,12,206,21,255,62,34,110,1,237,104,175,255,80,132,111,255,142,174,72,0,84,229,180,254,105,179,140,0,64,248,15,255,233,138,16,0,245,67,123,254,218,121,212,255,63,95,218,1,213,133,137,255,143,182,82,255,48,28,11,0,244,114,141,1,209,175,76,255,157,181,150,255,186,229,3,255,164,157,111,1,231,189,139,0,119,202,190,255,218,106,64,255,68,235,63,254,96,26,172,255,187,47,11,1,215,18,251,255,81,84,89,0,68,58,128,0,94,113,5,1,92,129,208,255,97,15,83,254,9,28,188,0,239,9,164,0,60,205,152,0,192,163,98,255,184,18,60,0,217,182,139,0,109,59,120,255,4,192,251,0,169,210,240,255,37,172,92,254,148,211,245,255,179,65,52,0,253,13,115,0,185,174,206,1,114,188,149,255,237,90,173,0,43,199,192,255,88,108,113,0,52,35,76,0,66,25,148,255,221,4,7,255,151,241,114,255,190,209,232,0,98,50,199,0,151,150,213,255,18,74,36,1,53,40,7,0,19,135,65,255,26,172,69,0,174,237,85,0,99,95,41,0,3,56,16,0,39,160,177,255,200,106,218,254,185,68,84,255,91,186,61,254,67,143,141,255,13,244,166,255,99,114,198,0,199,110,163,255,193,18,186,0,124,239,246,1,110,68,22,0,2,235,46,1,212,60,107,0,105,42,105,1,14,230,152,0,7,5,131,0,141,104,154,255,213,3,6,0,131,228,162,255,179,100,28,1,231,123,85,255,206,14,223,1,253,96,230,0,38,152,149,1,98,137,122,0,214,205,3,255,226,152,179,255,6,133,137,0,158,69,140,255,113,162,154,255,180,243,172,255,27,189,115,255,143,46,220,255,213,134,225,255,126,29,69,0,188,43,137,1,242,70,9,0,90,204,255,255,231,170,147,0,23,56,19,254,56,125,157,255,48,179,218,255,79,182,253,255,38,212,191,1,41,235,124,0,96,151,28,0,135,148,190,0,205,249,39,254,52,96,136,255,212,44,136,255,67,209,131,255,252,130,23,255,219,128,20,255,198,129,118,0,108,101,11,0,178,5,146,1,62,7,100,255,181,236,94,254,28,26,164,0,76,22,112,255,120,102,79,0,202,192,229,1,200,176,215,0,41,64,244,255,206,184,78,0,167,45,63,1,160,35,0,255,59,12,142,255,204,9,144,255,219,94,229,1,122,27,112,0,189,105,109,255,64,208,74,255,251,127,55,1,2,226,198,0,44,76,209,0,151,152,77,255,210,23,46,1,201,171,69,255,44,211,231,0,190,37,224,255,245,196,62,255,169,181,222,255,34,211,17,0,119,241,197,255,229,35,152,1,21,69,40,255,178,226,161,0,148,179,193,0,219,194,254,1,40,206,51,255,231,92,250,1,67,153,170,0,21,148,241,0,170,69,82,255,121,18,231,255,92,114,3,0,184,62,230,0,225,201,87,255,146,96,162,255,181,242,220,0,173,187,221,1,226,62,170,255,56,126,217,1,117,13,227,255,179,44,239,0,157,141,155,255,144,221,83,0,235,209,208,0,42,17,165,1,251,81,133,0,124,245,201,254,97,211,24,255,83,214,166,0,154,36,9,255,248,47,127,0,90,219,140,255,161,217,38,254,212,147,63,255,66,84,148,1,207,3,1,0,230,134,89,1,127,78,122,255,224,155,1,255,82,136,74,0,178,156,208,255,186,25,49,255,222,3,210,1,229,150,190,255,85,162,52,255,41,84,141,255,73,123,84,254,93,17,150,0,119,19,28,1,32,22,215,255,28,23,204,255,142,241,52,255,228,52,125,0,29,76,207,0,215,167,250,254,175,164,230,0,55,207,105,1,109,187,245,255,161,44,220,1,41,101,128,255,167,16,94,0,93,214,107,255,118,72,0,254,80,61,234,255,121,175,125,0,139,169,251,0,97,39,147,254,250,196,49,255,165,179,110,254,223,70,187,255,22,142,125,1,154,179,138,255,118,176,42,1,10,174,153,0,156,92,102,0,168,13,161,255,143,16,32,0,250,197,180,255,203,163,44,1,87,32,36,0,161,153,20,255,123,252,15,0,25,227,80,0,60,88,142,0,17,22,201,1,154,205,77,255,39,63,47,0,8,122,141,0,128,23,182,254,204,39,19,255],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+20480);allocate([4,112,29,255,23,36,140,255,210,234,116,254,53,50,63,255,121,171,104,255,160,219,94,0,87,82,14,254,231,42,5,0,165,139,127,254,86,78,38,0,130,60,66,254,203,30,45,255,46,196,122,1,249,53,162,255,136,143,103,254,215,210,114,0,231,7,160,254,169,152,42,255,111,45,246,0,142,131,135,255,131,71,204,255,36,226,11,0,0,28,242,255,225,138,213,255,247,46,216,254,245,3,183,0,108,252,74,1,206,26,48,255,205,54,246,255,211,198,36,255,121,35,50,0,52,216,202,255,38,139,129,254,242,73,148,0,67,231,141,255,42,47,204,0,78,116,25,1,4,225,191,255,6,147,228,0,58,88,177,0,122,165,229,255,252,83,201,255,224,167,96,1,177,184,158,255,242,105,179,1,248,198,240,0,133,66,203,1,254,36,47,0,45,24,115,255,119,62,254,0,196,225,186,254,123,141,172,0,26,85,41,255,226,111,183,0,213,231,151,0,4,59,7,255,238,138,148,0,66,147,33,255,31,246,141,255,209,141,116,255,104,112,31,0,88,161,172,0,83,215,230,254,47,111,151,0,45,38,52,1,132,45,204,0,138,128,109,254,233,117,134,255,243,190,173,254,241,236,240,0,82,127,236,254,40,223,161,255,110,182,225,255,123,174,239,0,135,242,145,1,51,209,154,0,150,3,115,254,217,164,252,255,55,156,69,1,84,94,255,255,232,73,45,1,20,19,212,255,96,197,59,254,96,251,33,0,38,199,73,1,64,172,247,255,117,116,56,255,228,17,18,0,62,138,103,1,246,229,164,255,244,118,201,254,86,32,159,255,109,34,137,1,85,211,186,0,10,193,193,254,122,194,177,0,122,238,102,255,162,218,171,0,108,217,161,1,158,170,34,0,176,47,155,1,181,228,11,255,8,156,0,0,16,75,93,0,206,98,255,1,58,154,35,0,12,243,184,254,67,117,66,255,230,229,123,0,201,42,110,0,134,228,178,254,186,108,118,255,58,19,154,255,82,169,62,255,114,143,115,1,239,196,50,255,173,48,193,255,147,2,84,255,150,134,147,254,95,232,73,0,109,227,52,254,191,137,10,0,40,204,30,254,76,52,97,255,164,235,126,0,254,124,188,0,74,182,21,1,121,29,35,255,241,30,7,254,85,218,214,255,7,84,150,254,81,27,117,255,160,159,152,254,66,24,221,255,227,10,60,1,141,135,102,0,208,189,150,1,117,179,92,0,132,22,136,255,120,199,28,0,21,129,79,254,182,9,65,0,218,163,169,0,246,147,198,255,107,38,144,1,78,175,205,255,214,5,250,254,47,88,29,255,164,47,204,255,43,55,6,255,131,134,207,254,116,100,214,0,96,140,75,1,106,220,144,0,195,32,28,1,172,81,5,255,199,179,52,255,37,84,203,0,170,112,174,0,11,4,91,0,69,244,27,1,117,131,92,0,33,152,175,255,140,153,107,255,251,135,43,254,87,138,4,255,198,234,147,254,121,152,84,255,205,101,155,1,157,9,25,0,72,106,17,254,108,153,0,255,189,229,186,0,193,8,176,255,174,149,209,0,238,130,29,0,233,214,126,1,61,226,102,0,57,163,4,1,198,111,51,255,45,79,78,1,115,210,10,255,218,9,25,255,158,139,198,255,211,82,187,254,80,133,83,0,157,129,230,1,243,133,134,255,40,136,16,0,77,107,79,255,183,85,92,1,177,204,202,0,163,71,147,255,152,69,190,0,172,51,188,1,250,210,172,255,211,242,113,1,89,89,26,255,64,66,111,254,116,152,42,0,161,39,27,255,54,80,254,0,106,209,115,1,103,124,97,0,221,230,98,255,31,231,6,0,178,192,120,254,15,217,203,255,124,158,79,0,112,145,247,0,92,250,48,1,163,181,193,255,37,47,142,254,144,189,165,255,46,146,240,0,6,75,128,0,41,157,200,254,87,121,213,0,1,113,236,0,5,45,250,0,144,12,82,0,31,108,231,0,225,239,119,255,167,7,189,255,187,228,132,255,110,189,34,0,94,44,204,1,162,52,197,0,78,188,241,254,57,20,141,0,244,146,47,1,206,100,51,0,125,107,148,254,27,195,77,0,152,253,90,1,7,143,144,255,51,37,31,0,34,119,38,255,7,197,118,0,153,188,211,0,151,20,116,254,245,65,52,255,180,253,110,1,47,177,209,0,161,99,17,255,118,222,202,0,125,179,252,1,123,54,126,255,145,57,191,0,55,186,121,0,10,243,138,0,205,211,229,255,125,156,241,254,148,156,185,255,227,19,188,255,124,41,32,255,31,34,206,254,17,57,83,0,204,22,37,255,42,96,98,0,119,102,184,1,3,190,28,0,110,82,218,255,200,204,192,255,201,145,118,0,117,204,146,0,132,32,98,1,192,194,121,0,106,161,248,1,237,88,124,0,23,212,26,0,205,171,90,255,248,48,216,1,141,37,230,255,124,203,0,254,158,168,30,255,214,248,21,0,112,187,7,255,75,133,239,255,74,227,243,255,250,147,70,0,214,120,162,0,167,9,179,255,22,158,18,0,218,77,209,1,97,109,81,255,244,33,179,255,57,52,57,255,65,172,210,255,249,71,209,255,142,169,238,0,158,189,153,255,174,254,103,254,98,33,14,0,141,76,230,255,113,139,52,255,15,58,212,0,168,215,201,255,248,204,215,1,223,68,160,255,57,154,183,254,47,231,121,0,106,166,137,0,81,136,138,0,165,43,51,0,231,139,61,0,57,95,59,254,118,98,25,255,151,63,236,1,94,190,250,255,169,185,114,1,5,250,58,255,75,105,97,1,215,223,134,0,113,99,163,1,128,62,112,0,99,106,147,0,163,195,10,0,33,205,182,0,214,14,174,255,129,38,231,255,53,182,223,0,98,42,159,255,247,13,40,0,188,210,177,1,6,21,0,255,255,61,148,254,137,45,129,255,89,26,116,254,126,38,114,0,251,50,242,254,121,134,128,255,204,249,167,254,165,235,215,0,202,177,243,0,133,141,62,0,240,130,190,1,110,175,255,0,0,20,146,1,37,210,121,255,7,39,130,0,142,250,84,255,141,200,207,0,9,95,104,255,11,244,174,0,134,232,126,0,167,1,123,254,16,193,149,255,232,233,239,1,213,70,112,255,252,116,160,254,242,222,220,255,205,85,227,0,7,185,58,0,118,247,63,1,116,77,177,255,62,245,200,254,63,18,37,255,107,53,232,254,50,221,211,0,162,219,7,254,2,94,43,0,182,62,182,254,160,78,200,255,135,140,170,0,235,184,228,0,175,53,138,254,80,58,77,255,152,201,2,1,63,196,34,0,5,30,184,0,171,176,154,0,121,59,206,0,38,99,39,0,172,80,77,254,0,134,151,0,186,33,241,254,94,253,223,255,44,114,252,0,108,126,57,255,201,40,13,255,39,229,27,255,39,239,23,1,151,121,51,255,153,150,248,0,10,234,174,255,118,246,4,254,200,245,38,0,69,161,242,1,16,178,150,0,113,56,130,0,171,31,105,0,26,88,108,255,49,42,106,0,251,169,66,0,69,93,149,0,20,57,254,0,164,25,111,0,90,188,90,255,204,4,197,0,40,213,50,1,212,96,132,255,88,138,180,254,228,146,124,255,184,246,247,0,65,117,86,255,253,102,210,254,254,121,36,0,137,115,3,255,60,24,216,0,134,18,29,0,59,226,97,0,176,142,71,0,7,209,161,0,189,84,51,254,155,250,72,0,213,84,235,255,45,222,224,0,238,148,143,255,170,42,53,255,78,167,117,0,186,0,40,255,125,177,103,255,69,225,66,0,227,7,88,1,75,172,6,0,169,45,227,1,16,36,70,255,50,2,9,255,139,193,22,0,143,183,231,254,218,69,50,0,236,56,161,1,213,131,42,0,138,145,44,254,136,229,40,255,49,63,35,255,61,145,245,255,101,192,2,254,232,167,113,0,152,104,38,1,121,185,218,0,121,139,211,254,119,240,35,0,65,189,217,254,187,179,162,255,160,187,230,0,62,248,14,255,60,78,97,0,255,247,163,255,225,59,91,255,107,71,58,255,241,47,33,1,50,117,236,0,219,177,63,254,244,90,179,0,35,194,215,255,189,67,50,255,23,135,129,0,104,189,37,255,185,57,194,0,35,62,231,255,220,248,108,0,12,231,178,0,143,80,91,1,131,93,101,255,144,39,2,1,255,250,178,0,5,17,236,254,139,32,46,0,204,188,38,254,245,115,52,255,191,113,73,254,191,108,69,255,22,69,245,1,23,203,178,0,170,99,170,0,65,248,111,0,37,108,153,255,64,37,69,0,0,88,62,254,89,148,144,255,191,68,224,1,241,39,53,0,41,203,237,255,145,126,194,255,221,42,253,255,25,99,151,0,97,253,223,1,74,115,49,255,6,175,72,255,59,176,203,0,124,183,249,1,228,228,99,0,129,12,207,254,168,192,195,255,204,176,16,254,152,234,171,0,77,37,85,255,33,120,135,255,142,194,227,1,31,214,58,0,213,187,125,255,232,46,60,255,190,116,42,254,151,178,19,255,51,62,237,254,204,236,193,0,194,232,60,0,172,34,157,255,189,16,184,254,103,3,95,255,141,233,36,254,41,25,11,255,21,195,166,0,118,245,45,0,67,213,149,255,159,12,18,255,187,164,227,1,160,25,5,0,12,78,195,1,43,197,225,0,48,142,41,254,196,155,60,255,223,199,18,1,145,136,156,0,252,117,169,254,145,226,238,0,239,23,107,0,109,181,188,255,230,112,49,254,73,170,237,255,231,183,227,255,80,220,20,0,194,107,127,1,127,205,101,0,46,52,197,1,210,171,36,255,88,3,90,255,56,151,141,0,96,187,255,255,42,78,200,0,254,70,70,1,244,125,168,0,204,68,138,1,124,215,70,0,102,66,200,254,17,52,228,0,117,220,143,254,203,248,123,0,56,18,174,255,186,151,164,255,51,232,208,1,160,228,43,255,249,29,25,1,68,190,63,0,103,230,9,106,133,174,103,187,114,243,110,60,58,245,79,165,127,82,14,81,140,104,5,155,171,217,131,31,25,205,224,91,152,47,138,66,145,68,55,113,207,251,192,181,165,219,181,233,91,194,86,57,241,17,241,89,164,130,63,146,213,94,28,171,152,170,7,216,1,91,131,18,190,133,49,36,195,125,12,85,116,93,190,114,254,177,222,128,167,6,220,155,116,241,155,193,193,105,155,228,134,71,190,239,198,157,193,15,204,161,12,36,111,44,233,45,170,132,116,74,220,169,176,92,218,136,249,118,82,81,62,152,109,198,49,168,200,39,3,176,199,127,89,191,243,11,224,198,71,145,167,213,81,99,202,6,103,41,41,20,133,10,183,39,56,33,27,46,252,109,44,77,19,13,56,83,84,115,10,101,187,10,106,118,46,201,194,129,133,44,114,146,161,232,191,162,75,102,26,168,112,139,75,194,163,81,108,199,25,232,146,209,36,6,153,214,133,53,14,244,112,160,106,16,22,193,164,25,8,108,55,30,76,119,72,39,181,188,176,52,179,12,28,57,74,170,216,78,79,202,156,91,243,111,46,104,238,130,143,116,111,99,165,120,20,120,200,132,8,2,199,140,250,255,190,144,235,108,80,164,247,163,249,190,242,120,113,198,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,48,138,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,104,109,97,99,115,104,97,53,49,50,50,53,54,0,99,117,114,118,101,50,53,53,49,57,120,115,97,108,115,97,50,48,112,111,108,121,49,51,48,53,0,83,45,62,98,117,102,108,101,110,32,60,61,32,66,76,65,75,69,50,66,95,66,76,79,67,75,66,89,84,69,83,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,47,98,108,97,107,101,50,98,47,114,101,102,47,98,108,97,107,101,50,98,45,114,101,102,46,99,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,95,102,105,110,97,108,0,111,117,116,108,101,110,32,60,61,32,85,73,78,84,56,95,77,65,88,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,47,98,108,97,107,101,50,98,47,114,101,102,47,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,46,99,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,0,107,101,121,108,101,110,32,60,61,32,85,73,78,84,56,95,77,65,88,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,115,97,108,116,95,112,101,114,115,111,110,97,108,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,105,110,105,116,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,105,110,105,116,95,115,97,108,116,95,112,101,114,115,111,110,97,108,0,99,114,121,112,116,111,95,103,101,110,101,114,105,99,104,97,115,104,95,98,108,97,107,101,50,98,95,102,105,110,97,108,0,115,104,97,53,49,50,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,98,108,97,107,101,50,98,0,120,50,53,53,49,57,98,108,97,107,101,50,98,0,112,111,108,121,49,51,48,53,0,36,97,114,103,111,110,50,105,0,36,118,61,0,36,109,61,0,44,116,61,0,44,112,61,0,36,97,114,103,111,110,50,105,36,118,61,0,36,97,114,103,111,110,50,105,36,0,97,114,103,111,110,50,105,0,46,47,48,49,50,51,52,53,54,55,56,57,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,0,36,55,36,0,99,117,114,118,101,50,53,53,49,57,0,120,115,97,108,115,97,50,48,112,111,108,121,49,51,48,53,0,115,105,112,104,97,115,104,50,52,0,101,100,50,53,53,49,57,0,237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,83,105,103,69,100,50,53,53,49,57,32,110,111,32,69,100,50,53,53,49,57,32,99,111,108,108,105,115,105,111,110,115,1,0,120,115,97,108,115,97,50,48,0,106,115,0,123,32,114,101,116,117,114,110,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,40,41,59,32,125,0,123,32,105,102,32,40,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,61,61,32,117,110,100,101,102,105,110,101,100,41,32,123,32,116,114,121,32,123,32,118,97,114,32,119,105,110,100,111,119,95,32,61,32,34,111,98,106,101,99,116,34,32,61,61,61,32,116,121,112,101,111,102,32,119,105,110,100,111,119,32,63,32,119,105,110,100,111,119,32,58,32,115,101,108,102,44,32,99,114,121,112,116,111,95,32,61,32,116,121,112,101,111,102,32,119,105,110,100,111,119,95,46,99,114,121,112,116,111,32,33,61,61,32,34,117,110,100,101,102,105,110,101,100,34,32,63,32,119,105,110,100,111,119,95,46,99,114,121,112,116,111,32,58,32,119,105,110,100,111,119,95,46,109,115,67,114,121,112,116,111,44,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,32,61,32,102,117,110,99,116,105,111,110,40,41,32,123,32,118,97,114,32,98,117,102,32,61,32,110,101,119,32,85,105,110,116,51,50,65,114,114,97,121,40,49,41,59,32,99,114,121,112,116,111,95,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,115,40,98,117,102,41,59,32,114,101,116,117,114,110,32,98,117,102,91,48,93,32,62,62,62,32,48,59,32,125,59,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,40,41,59,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,32,114,97,110,100,111,109,86,97,108,117,101,115,83,116,97,110,100,97,114,100,59,32,125,32,99,97,116,99,104,32,40,101,41,32,123,32,116,114,121,32,123,32,118,97,114,32,99,114,121,112,116,111,32,61,32,114,101,113,117,105,114,101,40,39,99,114,121,112,116,111,39,41,44,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,32,61,32,102,117,110,99,116,105,111,110,40,41,32,123,32,118,97,114,32,98,117,102,32,61,32,99,114,121,112,116,111,46,114,97,110,100,111,109,66,121,116,101,115,40,52,41,59,32,114,101,116,117,114,110,32,40,98,117,102,91,48,93,32,60,60,32,50,52,32,124,32,98,117,102,91,49,93,32,60,60,32,49,54,32,124,32,98,117,102,91,50,93,32,60,60,32,56,32,124,32,98,117,102,91,51,93,41,32,62,62,62,32,48,59,32,125,59,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,40,41,59,32,77,111,100,117,108,101,46,103,101,116,82,97,110,100,111,109,86,97,108,117,101,32,61,32,114,97,110,100,111,109,86,97,108,117,101,78,111,100,101,74,83,59,32,125,32,99,97,116,99,104,32,40,101,41,32,123,32,116,104,114,111,119,32,39,78,111,32,115,101,99,117,114,101,32,114,97,110,100,111,109,32,110,117,109,98,101,114,32,103,101,110,101,114,97,116,111,114,32,102,111,117,110,100,39,59,32,125,32,125,32,125,32,125,0,76,105,98,115,111,100,105,117,109,68,82,71,98,117,102,95,108,101,110,32,60,61,32,83,73,90,69,95,77,65,88,0,114,97,110,100,111,109,98,121,116,101,115,47,114,97,110,100,111,109,98,121,116,101,115,46,99,0,114,97,110,100,111,109,98,121,116,101,115,0,49,46,48,46,49,50,0,0,0,0,12,0,0,0,0,0,0,0,4,0,0,0,8,15,11,7,3,14,10,6,2,13,9,5,1,12,8,4,0,3,3,3,3,7,7,7,7,11,11,11,11,15,15,15,15,3,2,1,0,7,6,5,4,11,10,9,8,15,14,13,12,12,8,4,0,13,9,5,1,14,10,6,2,15,11,7,3,1,2,3,0,6,7,4,5,11,8,9,10,12,13,14,15,15,10,5,0,14,9,4,3,13,8,7,2,12,11,6,1],"i8",ALLOC_NONE,Runtime.GLOBAL_BASE+30720);var tempDoublePtr=STATICTOP;STATICTOP+=16;Module["_bitshift64Ashr"]=_bitshift64Ashr;Module["_i64Subtract"]=_i64Subtract;Module["_i64Add"]=_i64Add;Module["_memset"]=_memset;Module["_bitshift64Lshr"]=_bitshift64Lshr;Module["_bitshift64Shl"]=_bitshift64Shl;function _abort(){Module["abort"]()}function ___assert_fail(condition,filename,line,func){ABORT=true;throw"Assertion failed: "+Pointer_stringify(condition)+", at: "+[filename?Pointer_stringify(filename):"unknown filename",line,func?Pointer_stringify(func):"unknown function"]+" at "+stackTrace()}function _emscripten_memcpy_big(dest,src,num){HEAPU8.set(HEAPU8.subarray(src,src+num),dest);return dest}Module["_memcpy"]=_memcpy;var cttz_i8=allocate([8,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,7,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0],"i8",ALLOC_STATIC);Module["_llvm_cttz_i32"]=_llvm_cttz_i32;Module["___udivmoddi4"]=___udivmoddi4;Module["___udivdi3"]=___udivdi3;Module["___muldsi3"]=___muldsi3;Module["___muldi3"]=___muldi3;function ___setErrNo(value){if(Module["___errno_location"])HEAP32[Module["___errno_location"]()>>2]=value;return value}var ERRNO_CODES={EPERM:1,ENOENT:2,ESRCH:3,EINTR:4,EIO:5,ENXIO:6,E2BIG:7,ENOEXEC:8,EBADF:9,ECHILD:10,EAGAIN:11,EWOULDBLOCK:11,ENOMEM:12,EACCES:13,EFAULT:14,ENOTBLK:15,EBUSY:16,EEXIST:17,EXDEV:18,ENODEV:19,ENOTDIR:20,EISDIR:21,EINVAL:22,ENFILE:23,EMFILE:24,ENOTTY:25,ETXTBSY:26,EFBIG:27,ENOSPC:28,ESPIPE:29,EROFS:30,EMLINK:31,EPIPE:32,EDOM:33,ERANGE:34,ENOMSG:42,EIDRM:43,ECHRNG:44,EL2NSYNC:45,EL3HLT:46,EL3RST:47,ELNRNG:48,EUNATCH:49,ENOCSI:50,EL2HLT:51,EDEADLK:35,ENOLCK:37,EBADE:52,EBADR:53,EXFULL:54,ENOANO:55,EBADRQC:56,EBADSLT:57,EDEADLOCK:35,EBFONT:59,ENOSTR:60,ENODATA:61,ETIME:62,ENOSR:63,ENONET:64,ENOPKG:65,EREMOTE:66,ENOLINK:67,EADV:68,ESRMNT:69,ECOMM:70,EPROTO:71,EMULTIHOP:72,EDOTDOT:73,EBADMSG:74,ENOTUNIQ:76,EBADFD:77,EREMCHG:78,ELIBACC:79,ELIBBAD:80,ELIBSCN:81,ELIBMAX:82,ELIBEXEC:83,ENOSYS:38,ENOTEMPTY:39,ENAMETOOLONG:36,ELOOP:40,EOPNOTSUPP:95,EPFNOSUPPORT:96,ECONNRESET:104,ENOBUFS:105,EAFNOSUPPORT:97,EPROTOTYPE:91,ENOTSOCK:88,ENOPROTOOPT:92,ESHUTDOWN:108,ECONNREFUSED:111,EADDRINUSE:98,ECONNABORTED:103,ENETUNREACH:101,ENETDOWN:100,ETIMEDOUT:110,EHOSTDOWN:112,EHOSTUNREACH:113,EINPROGRESS:115,EALREADY:114,EDESTADDRREQ:89,EMSGSIZE:90,EPROTONOSUPPORT:93,ESOCKTNOSUPPORT:94,EADDRNOTAVAIL:99,ENETRESET:102,EISCONN:106,ENOTCONN:107,ETOOMANYREFS:109,EUSERS:87,EDQUOT:122,ESTALE:116,ENOTSUP:95,ENOMEDIUM:123,EILSEQ:84,EOVERFLOW:75,ECANCELED:125,ENOTRECOVERABLE:131,EOWNERDEAD:130,ESTRPIPE:86};function _sysconf(name){switch(name){case 30:return PAGE_SIZE;case 85:var maxHeapSize=2*1024*1024*1024-16777216;maxHeapSize=HEAPU8.length;return maxHeapSize/PAGE_SIZE;case 132:case 133:case 12:case 137:case 138:case 15:case 235:case 16:case 17:case 18:case 19:case 20:case 149:case 13:case 10:case 236:case 153:case 9:case 21:case 22:case 159:case 154:case 14:case 77:case 78:case 139:case 80:case 81:case 82:case 68:case 67:case 164:case 11:case 29:case 47:case 48:case 95:case 52:case 51:case 46:return 200809;case 79:return 0;case 27:case 246:case 127:case 128:case 23:case 24:case 160:case 161:case 181:case 182:case 242:case 183:case 184:case 243:case 244:case 245:case 165:case 178:case 179:case 49:case 50:case 168:case 169:case 175:case 170:case 171:case 172:case 97:case 76:case 32:case 173:case 35:return-1;case 176:case 177:case 7:case 155:case 8:case 157:case 125:case 126:case 92:case 93:case 129:case 130:case 131:case 94:case 91:return 1;case 74:case 60:case 69:case 70:case 4:return 1024;case 31:case 42:case 72:return 32;case 87:case 26:case 33:return 2147483647;case 34:case 1:return 47839;case 38:case 36:return 99;case 43:case 37:return 2048;case 0:return 2097152;case 3:return 65536;case 28:return 32768;case 44:return 32767;case 75:return 16384;case 39:return 1e3;case 89:return 700;case 71:return 256;case 40:return 255;case 2:return 100;case 180:return 64;case 25:return 20;case 5:return 16;case 6:return 6;case 73:return 4;case 84:{if(typeof navigator==="object")return navigator["hardwareConcurrency"]||1;return 1}}___setErrNo(ERRNO_CODES.EINVAL);return-1}Module["_sbrk"]=_sbrk;Module["_memmove"]=_memmove;Module["___uremdi3"]=___uremdi3;DYNAMICTOP_PTR=allocate(1,"i32",ALLOC_STATIC);STACK_BASE=STACKTOP=Runtime.alignMemory(STATICTOP);STACK_MAX=STACK_BASE+TOTAL_STACK;DYNAMIC_BASE=Runtime.alignMemory(STACK_MAX);HEAP32[DYNAMICTOP_PTR>>2]=DYNAMIC_BASE;staticSealed=true;Module.asmGlobalArg={"Math":Math,"Int8Array":Int8Array,"Int16Array":Int16Array,"Int32Array":Int32Array,"Uint8Array":Uint8Array,"Uint16Array":Uint16Array,"Uint32Array":Uint32Array,"Float32Array":Float32Array,"Float64Array":Float64Array,"NaN":NaN,"Infinity":Infinity};Module.asmLibraryArg={"abort":abort,"assert":assert,"enlargeMemory":enlargeMemory,"getTotalMemory":getTotalMemory,"abortOnCannotGrowMemory":abortOnCannotGrowMemory,"_emscripten_asm_const_i":_emscripten_asm_const_i,"_sysconf":_sysconf,"_abort":_abort,"___setErrNo":___setErrNo,"_emscripten_memcpy_big":_emscripten_memcpy_big,"_emscripten_asm_const_v":_emscripten_asm_const_v,"___assert_fail":___assert_fail,"DYNAMICTOP_PTR":DYNAMICTOP_PTR,"tempDoublePtr":tempDoublePtr,"ABORT":ABORT,"STACKTOP":STACKTOP,"STACK_MAX":STACK_MAX,"cttz_i8":cttz_i8};// EMSCRIPTEN_START_ASM var asm=(function(global,env,buffer) { "use asm";var a=new global.Int8Array(buffer);var b=new global.Int16Array(buffer);var c=new global.Int32Array(buffer);var d=new global.Uint8Array(buffer);var e=new global.Uint16Array(buffer);var f=new global.Uint32Array(buffer);var g=new global.Float32Array(buffer);var h=new global.Float64Array(buffer);var i=env.DYNAMICTOP_PTR|0;var j=env.tempDoublePtr|0;var k=env.ABORT|0;var l=env.STACKTOP|0;var m=env.STACK_MAX|0;var n=env.cttz_i8|0;var o=0;var p=0;var q=0;var r=0;var s=global.NaN,t=global.Infinity;var u=0,v=0,w=0,x=0,y=0.0;var z=0;var A=global.Math.floor;var B=global.Math.abs;var C=global.Math.sqrt;var D=global.Math.pow;var E=global.Math.cos;var F=global.Math.sin;var G=global.Math.tan;var H=global.Math.acos;var I=global.Math.asin;var J=global.Math.atan;var K=global.Math.atan2;var L=global.Math.exp;var M=global.Math.log;var N=global.Math.ceil;var O=global.Math.imul;var P=global.Math.min;var Q=global.Math.max;var R=global.Math.clz32;var S=env.abort;var T=env.assert;var U=env.enlargeMemory;var V=env.getTotalMemory;var W=env.abortOnCannotGrowMemory;var X=env._emscripten_asm_const_i;var Y=env._sysconf;var Z=env._abort;var _=env.___setErrNo;var $=env._emscripten_memcpy_big;var aa=env._emscripten_asm_const_v;var ba=env.___assert_fail;var ca=0.0; // EMSCRIPTEN_START_FUNCS @@ -77633,13 +66968,13 @@ return{_crypto_onetimeauth_poly1305_init:_g,_crypto_hash_sha512_init:me,_crypto_ /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 477 */ +/* 417 */ /***/ (function(module, exports) { /***/ }), -/* 478 */ +/* 418 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors. @@ -77870,28 +67205,28 @@ var substr = 'ab'.substr(-1) === 'b' /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0))) /***/ }), -/* 479 */ +/* 419 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -exports.randomBytes = exports.rng = exports.pseudoRandomBytes = exports.prng = __webpack_require__(115) -exports.createHash = exports.Hash = __webpack_require__(71) -exports.createHmac = exports.Hmac = __webpack_require__(249) +exports.randomBytes = exports.rng = exports.pseudoRandomBytes = exports.prng = __webpack_require__(43) +exports.createHash = exports.Hash = __webpack_require__(27) +exports.createHmac = exports.Hmac = __webpack_require__(67) -var algos = __webpack_require__(481) +var algos = __webpack_require__(421) var algoKeys = Object.keys(algos) var hashes = ['sha1', 'sha224', 'sha256', 'sha384', 'sha512', 'md5', 'rmd160'].concat(algoKeys) exports.getHashes = function () { return hashes } -var p = __webpack_require__(323) +var p = __webpack_require__(177) exports.pbkdf2 = p.pbkdf2 exports.pbkdf2Sync = p.pbkdf2Sync -var aes = __webpack_require__(483) +var aes = __webpack_require__(423) exports.Cipher = aes.Cipher exports.createCipher = aes.createCipher @@ -77904,7 +67239,7 @@ exports.createDecipheriv = aes.createDecipheriv exports.getCiphers = aes.getCiphers exports.listCiphers = aes.listCiphers -var dh = __webpack_require__(494) +var dh = __webpack_require__(434) exports.DiffieHellmanGroup = dh.DiffieHellmanGroup exports.createDiffieHellmanGroup = dh.createDiffieHellmanGroup @@ -77912,16 +67247,16 @@ exports.getDiffieHellman = dh.getDiffieHellman exports.createDiffieHellman = dh.createDiffieHellman exports.DiffieHellman = dh.DiffieHellman -var sign = __webpack_require__(497) +var sign = __webpack_require__(437) exports.createSign = sign.createSign exports.Sign = sign.Sign exports.createVerify = sign.createVerify exports.Verify = sign.Verify -exports.createECDH = __webpack_require__(514) +exports.createECDH = __webpack_require__(454) -var publicEncrypt = __webpack_require__(515) +var publicEncrypt = __webpack_require__(455) exports.publicEncrypt = publicEncrypt.publicEncrypt exports.privateEncrypt = publicEncrypt.privateEncrypt @@ -77969,15 +67304,15 @@ exports.constants = { /***/ }), -/* 480 */ +/* 420 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var inherits = __webpack_require__(11) -var Buffer = __webpack_require__(18).Buffer +var inherits = __webpack_require__(4) +var Buffer = __webpack_require__(7).Buffer -var Base = __webpack_require__(109) +var Base = __webpack_require__(29) var ZEROS = Buffer.alloc(128) var blocksize = 64 @@ -78022,20 +67357,20 @@ module.exports = Hmac /***/ }), -/* 481 */ +/* 421 */ /***/ (function(module, exports, __webpack_require__) { -module.exports = __webpack_require__(322) +module.exports = __webpack_require__(176) /***/ }), -/* 482 */ +/* 422 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(global, process) {var checkParameters = __webpack_require__(324) -var defaultEncoding = __webpack_require__(325) -var sync = __webpack_require__(326) -var Buffer = __webpack_require__(18).Buffer +/* WEBPACK VAR INJECTION */(function(global, process) {var checkParameters = __webpack_require__(178) +var defaultEncoding = __webpack_require__(179) +var sync = __webpack_require__(180) +var Buffer = __webpack_require__(7).Buffer var ZERO_BUF var subtle = global.crypto && global.crypto.subtle @@ -78131,17 +67466,17 @@ module.exports = function (password, salt, iterations, keylen, digest, callback) }), callback) } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(67), __webpack_require__(0))) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(24), __webpack_require__(0))) /***/ }), -/* 483 */ +/* 423 */ /***/ (function(module, exports, __webpack_require__) { -var ebtk = __webpack_require__(250) -var aes = __webpack_require__(270) -var DES = __webpack_require__(487) -var desModes = __webpack_require__(493) -var aesModes = __webpack_require__(252) +var ebtk = __webpack_require__(68) +var aes = __webpack_require__(108) +var DES = __webpack_require__(427) +var desModes = __webpack_require__(433) +var aesModes = __webpack_require__(70) function createCipher (suite, password) { var keyLen, ivLen suite = suite.toLowerCase() @@ -78213,16 +67548,16 @@ exports.listCiphers = exports.getCiphers = getCiphers /***/ }), -/* 484 */ +/* 424 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(251) -var Transform = __webpack_require__(109) -var inherits = __webpack_require__(11) -var modes = __webpack_require__(252) -var ebtk = __webpack_require__(250) -var StreamCipher = __webpack_require__(327) -var AuthCipher = __webpack_require__(328) +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var modes = __webpack_require__(70) +var ebtk = __webpack_require__(68) +var StreamCipher = __webpack_require__(181) +var AuthCipher = __webpack_require__(182) inherits(Cipher, Transform) function Cipher (mode, key, iv) { if (!(this instanceof Cipher)) { @@ -78293,14 +67628,14 @@ Splitter.prototype.flush = function () { return out } var modelist = { - ECB: __webpack_require__(329), - CBC: __webpack_require__(330), - CFB: __webpack_require__(331), - CFB8: __webpack_require__(332), - CFB1: __webpack_require__(333), - OFB: __webpack_require__(334), - CTR: __webpack_require__(253), - GCM: __webpack_require__(253) + ECB: __webpack_require__(183), + CBC: __webpack_require__(184), + CFB: __webpack_require__(185), + CFB8: __webpack_require__(186), + CFB1: __webpack_require__(187), + OFB: __webpack_require__(188), + CTR: __webpack_require__(71), + GCM: __webpack_require__(71) } function createCipheriv (suite, password, iv) { @@ -78339,10 +67674,10 @@ function createCipher (suite, password) { exports.createCipheriv = createCipheriv exports.createCipher = createCipher -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 485 */ +/* 425 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {var zeros = new Buffer(16) @@ -78444,19 +67779,19 @@ function xor (a, b) { ] } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 486 */ +/* 426 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(251) -var Transform = __webpack_require__(109) -var inherits = __webpack_require__(11) -var modes = __webpack_require__(252) -var StreamCipher = __webpack_require__(327) -var AuthCipher = __webpack_require__(328) -var ebtk = __webpack_require__(250) +/* WEBPACK VAR INJECTION */(function(Buffer) {var aes = __webpack_require__(69) +var Transform = __webpack_require__(29) +var inherits = __webpack_require__(4) +var modes = __webpack_require__(70) +var StreamCipher = __webpack_require__(181) +var AuthCipher = __webpack_require__(182) +var ebtk = __webpack_require__(68) inherits(Decipher, Transform) function Decipher (mode, key, iv) { @@ -78542,14 +67877,14 @@ function unpad (last) { } var modelist = { - ECB: __webpack_require__(329), - CBC: __webpack_require__(330), - CFB: __webpack_require__(331), - CFB8: __webpack_require__(332), - CFB1: __webpack_require__(333), - OFB: __webpack_require__(334), - CTR: __webpack_require__(253), - GCM: __webpack_require__(253) + ECB: __webpack_require__(183), + CBC: __webpack_require__(184), + CFB: __webpack_require__(185), + CFB8: __webpack_require__(186), + CFB1: __webpack_require__(187), + OFB: __webpack_require__(188), + CTR: __webpack_require__(71), + GCM: __webpack_require__(71) } function createDecipheriv (suite, password, iv) { @@ -78588,15 +67923,15 @@ function createDecipher (suite, password) { exports.createDecipher = createDecipher exports.createDecipheriv = createDecipheriv -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 487 */ +/* 427 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var CipherBase = __webpack_require__(109) -var des = __webpack_require__(271) -var inherits = __webpack_require__(11) +/* WEBPACK VAR INJECTION */(function(Buffer) {var CipherBase = __webpack_require__(29) +var des = __webpack_require__(109) +var inherits = __webpack_require__(4) var modes = { 'des-ede3-cbc': des.CBC.instantiate(des.EDE), @@ -78638,10 +67973,10 @@ DES.prototype._final = function () { return new Buffer(this._des.final()) } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 488 */ +/* 428 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -78904,13 +68239,13 @@ exports.padSplit = function padSplit(num, size, group) { /***/ }), -/* 489 */ +/* 429 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var assert = __webpack_require__(47); +var assert = __webpack_require__(21); function Cipher(options) { this.options = options; @@ -79052,16 +68387,16 @@ Cipher.prototype._finalDecrypt = function _finalDecrypt() { /***/ }), -/* 490 */ +/* 430 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var assert = __webpack_require__(47); -var inherits = __webpack_require__(11); +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); -var des = __webpack_require__(271); +var des = __webpack_require__(109); var utils = des.utils; var Cipher = des.Cipher; @@ -79202,14 +68537,14 @@ DES.prototype._decrypt = function _decrypt(state, lStart, rStart, out, off) { /***/ }), -/* 491 */ +/* 431 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var assert = __webpack_require__(47); -var inherits = __webpack_require__(11); +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); var proto = {}; @@ -79274,16 +68609,16 @@ proto._update = function _update(inp, inOff, out, outOff) { /***/ }), -/* 492 */ +/* 432 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var assert = __webpack_require__(47); -var inherits = __webpack_require__(11); +var assert = __webpack_require__(21); +var inherits = __webpack_require__(4); -var des = __webpack_require__(271); +var des = __webpack_require__(109); var Cipher = des.Cipher; var DES = des.DES; @@ -79336,7 +68671,7 @@ EDE.prototype._unpad = DES.prototype._unpad; /***/ }), -/* 493 */ +/* 433 */ /***/ (function(module, exports) { exports['des-ecb'] = { @@ -79366,13 +68701,13 @@ exports['des-ede'] = { /***/ }), -/* 494 */ +/* 434 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var generatePrime = __webpack_require__(335) -var primes = __webpack_require__(495) +/* WEBPACK VAR INJECTION */(function(Buffer) {var generatePrime = __webpack_require__(189) +var primes = __webpack_require__(435) -var DH = __webpack_require__(496) +var DH = __webpack_require__(436) function getDiffieHellman (mod) { var prime = new Buffer(primes[mod].prime, 'hex') @@ -79412,10 +68747,10 @@ function createDiffieHellman (prime, enc, generator, genc) { exports.DiffieHellmanGroup = exports.createDiffieHellmanGroup = exports.getDiffieHellman = getDiffieHellman exports.createDiffieHellman = exports.DiffieHellman = createDiffieHellman -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 495 */ +/* 435 */ /***/ (function(module, exports) { module.exports = { @@ -79454,19 +68789,19 @@ module.exports = { }; /***/ }), -/* 496 */ +/* 436 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var BN = __webpack_require__(23); -var MillerRabin = __webpack_require__(336); +/* WEBPACK VAR INJECTION */(function(Buffer) {var BN = __webpack_require__(11); +var MillerRabin = __webpack_require__(190); var millerRabin = new MillerRabin(); var TWENTYFOUR = new BN(24); var ELEVEN = new BN(11); var TEN = new BN(10); var THREE = new BN(3); var SEVEN = new BN(7); -var primes = __webpack_require__(335); -var randomBytes = __webpack_require__(115); +var primes = __webpack_require__(189); +var randomBytes = __webpack_require__(43); module.exports = DH; function setPublicKey(pub, enc) { @@ -79622,19 +68957,19 @@ function formatReturnValue(bn, enc) { } } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 497 */ +/* 437 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var createHash = __webpack_require__(71) -var stream = __webpack_require__(261) -var inherits = __webpack_require__(11) -var sign = __webpack_require__(498) -var verify = __webpack_require__(513) +/* WEBPACK VAR INJECTION */(function(Buffer) {var createHash = __webpack_require__(27) +var stream = __webpack_require__(98) +var inherits = __webpack_require__(4) +var sign = __webpack_require__(438) +var verify = __webpack_require__(453) -var algorithms = __webpack_require__(322) +var algorithms = __webpack_require__(176) Object.keys(algorithms).forEach(function (key) { algorithms[key].id = new Buffer(algorithms[key].id, 'hex') algorithms[key.toLowerCase()] = algorithms[key] @@ -79720,19 +69055,19 @@ module.exports = { createVerify: createVerify } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 498 */ +/* 438 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {// much of this based on https://github.com/indutny/self-signed/blob/gh-pages/lib/rsa.js -var createHmac = __webpack_require__(249) -var crt = __webpack_require__(272) -var EC = __webpack_require__(36).ec -var BN = __webpack_require__(23) -var parseKeys = __webpack_require__(254) -var curves = __webpack_require__(341) +var createHmac = __webpack_require__(67) +var crt = __webpack_require__(110) +var EC = __webpack_require__(15).ec +var BN = __webpack_require__(11) +var parseKeys = __webpack_require__(72) +var curves = __webpack_require__(195) function sign (hash, key, hashType, signType, tag) { var priv = parseKeys(key) @@ -79872,10 +69207,10 @@ module.exports = sign module.exports.getKey = getKey module.exports.makeKey = makeKey -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 499 */ +/* 439 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -79883,9 +69218,9 @@ module.exports.makeKey = makeKey // Fedor, you are amazing. -var asn1 = __webpack_require__(240) +var asn1 = __webpack_require__(52) -exports.certificate = __webpack_require__(510) +exports.certificate = __webpack_require__(450) var RSAPrivateKey = asn1.define('RSAPrivateKey', function () { this.seq().obj( @@ -80004,11 +69339,11 @@ exports.signature = asn1.define('signature', function () { /***/ }), -/* 500 */ +/* 440 */ /***/ (function(module, exports, __webpack_require__) { -var asn1 = __webpack_require__(240); -var inherits = __webpack_require__(11); +var asn1 = __webpack_require__(52); +var inherits = __webpack_require__(4); var api = exports; @@ -80027,7 +69362,7 @@ function Entity(name, body) { Entity.prototype._createNamed = function createNamed(base) { var named; try { - named = __webpack_require__(501).runInThisContext( + named = __webpack_require__(441).runInThisContext( '(function ' + this.name + '(entity) {\n' + ' this._initNamed(entity);\n' + '})' @@ -80071,10 +69406,10 @@ Entity.prototype.encode = function encode(data, enc, /* internal */ reporter) { /***/ }), -/* 501 */ +/* 441 */ /***/ (function(module, exports, __webpack_require__) { -var indexOf = __webpack_require__(502); +var indexOf = __webpack_require__(442); var Object_keys = function (obj) { if (Object.keys) return Object.keys(obj) @@ -80215,7 +69550,7 @@ exports.createContext = Script.createContext = function (context) { /***/ }), -/* 502 */ +/* 442 */ /***/ (function(module, exports) { @@ -80230,10 +69565,10 @@ module.exports = function(arr, obj){ }; /***/ }), -/* 503 */ +/* 443 */ /***/ (function(module, exports, __webpack_require__) { -var inherits = __webpack_require__(11); +var inherits = __webpack_require__(4); function Reporter(options) { this._reporterState = { @@ -80357,13 +69692,13 @@ ReporterError.prototype.rethrow = function rethrow(msg) { /***/ }), -/* 504 */ +/* 444 */ /***/ (function(module, exports, __webpack_require__) { -var Reporter = __webpack_require__(241).Reporter; -var EncoderBuffer = __webpack_require__(241).EncoderBuffer; -var DecoderBuffer = __webpack_require__(241).DecoderBuffer; -var assert = __webpack_require__(47); +var Reporter = __webpack_require__(53).Reporter; +var EncoderBuffer = __webpack_require__(53).EncoderBuffer; +var DecoderBuffer = __webpack_require__(53).DecoderBuffer; +var assert = __webpack_require__(21); // Supported tags var tags = [ @@ -80997,10 +70332,10 @@ Node.prototype._isPrintstr = function isPrintstr(str) { /***/ }), -/* 505 */ +/* 445 */ /***/ (function(module, exports, __webpack_require__) { -var constants = __webpack_require__(338); +var constants = __webpack_require__(192); exports.tagClass = { 0: 'universal', @@ -81045,23 +70380,23 @@ exports.tagByName = constants._reverse(exports.tag); /***/ }), -/* 506 */ +/* 446 */ /***/ (function(module, exports, __webpack_require__) { var decoders = exports; -decoders.der = __webpack_require__(339); -decoders.pem = __webpack_require__(507); +decoders.der = __webpack_require__(193); +decoders.pem = __webpack_require__(447); /***/ }), -/* 507 */ +/* 447 */ /***/ (function(module, exports, __webpack_require__) { -var inherits = __webpack_require__(11); -var Buffer = __webpack_require__(7).Buffer; +var inherits = __webpack_require__(4); +var Buffer = __webpack_require__(1).Buffer; -var DERDecoder = __webpack_require__(339); +var DERDecoder = __webpack_require__(193); function PEMDecoder(entity) { DERDecoder.call(this, entity); @@ -81110,22 +70445,22 @@ PEMDecoder.prototype.decode = function decode(data, options) { /***/ }), -/* 508 */ +/* 448 */ /***/ (function(module, exports, __webpack_require__) { var encoders = exports; -encoders.der = __webpack_require__(340); -encoders.pem = __webpack_require__(509); +encoders.der = __webpack_require__(194); +encoders.pem = __webpack_require__(449); /***/ }), -/* 509 */ +/* 449 */ /***/ (function(module, exports, __webpack_require__) { -var inherits = __webpack_require__(11); +var inherits = __webpack_require__(4); -var DEREncoder = __webpack_require__(340); +var DEREncoder = __webpack_require__(194); function PEMEncoder(entity) { DEREncoder.call(this, entity); @@ -81147,7 +70482,7 @@ PEMEncoder.prototype.encode = function encode(data, options) { /***/ }), -/* 510 */ +/* 450 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -81156,7 +70491,7 @@ PEMEncoder.prototype.encode = function encode(data, options) { -var asn = __webpack_require__(240) +var asn = __webpack_require__(52) var Time = asn.define('Time', function () { this.choice({ @@ -81242,7 +70577,7 @@ module.exports = X509Certificate /***/ }), -/* 511 */ +/* 451 */ /***/ (function(module, exports) { module.exports = { @@ -81261,15 +70596,15 @@ module.exports = { }; /***/ }), -/* 512 */ +/* 452 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {// adapted from https://github.com/apatil/pemstrip var findProc = /Proc-Type: 4,ENCRYPTED\n\r?DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)\n\r?\n\r?([0-9A-z\n\r\+\/\=]+)\n\r?/m var startRegex = /^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----\n/m var fullRegex = /^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----\n\r?([0-9A-z\n\r\+\/\=]+)\n\r?-----END \1-----$/m -var evp = __webpack_require__(250) -var ciphers = __webpack_require__(270) +var evp = __webpack_require__(68) +var ciphers = __webpack_require__(108) module.exports = function (okey, password) { var key = okey.toString() var match = key.match(findProc) @@ -81295,17 +70630,17 @@ module.exports = function (okey, password) { } } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 513 */ +/* 453 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {// much of this based on https://github.com/indutny/self-signed/blob/gh-pages/lib/rsa.js -var BN = __webpack_require__(23) -var EC = __webpack_require__(36).ec -var parseKeys = __webpack_require__(254) -var curves = __webpack_require__(341) +var BN = __webpack_require__(11) +var EC = __webpack_require__(15).ec +var parseKeys = __webpack_require__(72) +var curves = __webpack_require__(195) function verify (sig, hash, key, signType, tag) { var pub = parseKeys(key) @@ -81385,14 +70720,14 @@ function checkValue (b, q) { module.exports = verify -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 514 */ +/* 454 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var elliptic = __webpack_require__(36); -var BN = __webpack_require__(23); +/* WEBPACK VAR INJECTION */(function(Buffer) {var elliptic = __webpack_require__(15); +var BN = __webpack_require__(11); module.exports = function createECDH(curve) { return new ECDH(curve); @@ -81514,14 +70849,14 @@ function formatReturnValue(bn, enc, len) { } } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 515 */ +/* 455 */ /***/ (function(module, exports, __webpack_require__) { -exports.publicEncrypt = __webpack_require__(516); -exports.privateDecrypt = __webpack_require__(517); +exports.publicEncrypt = __webpack_require__(456); +exports.privateDecrypt = __webpack_require__(457); exports.privateEncrypt = function privateEncrypt(key, buf) { return exports.publicEncrypt(key, buf, true); @@ -81532,17 +70867,17 @@ exports.publicDecrypt = function publicDecrypt(key, buf) { }; /***/ }), -/* 516 */ +/* 456 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var parseKeys = __webpack_require__(254); -var randomBytes = __webpack_require__(115); -var createHash = __webpack_require__(71); -var mgf = __webpack_require__(342); -var xor = __webpack_require__(343); -var bn = __webpack_require__(23); -var withPublic = __webpack_require__(344); -var crt = __webpack_require__(272); +/* WEBPACK VAR INJECTION */(function(Buffer) {var parseKeys = __webpack_require__(72); +var randomBytes = __webpack_require__(43); +var createHash = __webpack_require__(27); +var mgf = __webpack_require__(196); +var xor = __webpack_require__(197); +var bn = __webpack_require__(11); +var withPublic = __webpack_require__(198); +var crt = __webpack_require__(110); var constants = { RSA_PKCS1_OAEP_PADDING: 4, @@ -81630,19 +70965,19 @@ function nonZero(len, crypto) { } return out; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 517 */ +/* 457 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var parseKeys = __webpack_require__(254); -var mgf = __webpack_require__(342); -var xor = __webpack_require__(343); -var bn = __webpack_require__(23); -var crt = __webpack_require__(272); -var createHash = __webpack_require__(71); -var withPublic = __webpack_require__(344); +/* WEBPACK VAR INJECTION */(function(Buffer) {var parseKeys = __webpack_require__(72); +var mgf = __webpack_require__(196); +var xor = __webpack_require__(197); +var bn = __webpack_require__(11); +var crt = __webpack_require__(110); +var createHash = __webpack_require__(27); +var withPublic = __webpack_require__(198); module.exports = function privateDecrypt(private_key, enc, reverse) { var padding; if (private_key.padding) { @@ -81744,23 +71079,23 @@ function compare(a, b){ } return dif; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 518 */ +/* 458 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(111); -var secp256k1 = __webpack_require__(314); -var int64buffer = __webpack_require__(519); -var varuint = __webpack_require__(255); -var zconfig = __webpack_require__(248); -var zbufferutils = __webpack_require__(345); -var zcrypto = __webpack_require__(269); -var zconstants = __webpack_require__(520); -var zaddress = __webpack_require__(259); -var zopcodes = __webpack_require__(521); -var zbufferutils = __webpack_require__(345); +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33); +var secp256k1 = __webpack_require__(168); +var int64buffer = __webpack_require__(459); +var varuint = __webpack_require__(73); +var zconfig = __webpack_require__(66); +var zbufferutils = __webpack_require__(199); +var zcrypto = __webpack_require__(107); +var zconstants = __webpack_require__(460); +var zaddress = __webpack_require__(96); +var zopcodes = __webpack_require__(461); +var zbufferutils = __webpack_require__(199); /* More info: https://github.com/ZencashOfficial/zen/blob/master/src/script/standard.cpp#L377 * Given an address, generates a pubkeyhash replay type script needed for the transaction @@ -82078,10 +71413,10 @@ module.exports = { deserializeTx: deserializeTx, signTx: signTx }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 519 */ +/* 459 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {// int64-buffer.js @@ -82378,10 +71713,10 @@ var Uint64BE, Int64BE, Uint64LE, Int64LE; }(typeof exports === 'object' && typeof exports.nodeName !== 'string' ? exports : (this || {})); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 520 */ +/* 460 */ /***/ (function(module, exports) { module.exports = { @@ -82395,7 +71730,7 @@ module.exports = { }; /***/ }), -/* 521 */ +/* 461 */ /***/ (function(module, exports) { @@ -82414,13 +71749,13 @@ module.exports = { }; /***/ }), -/* 522 */ +/* 462 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var _bluebird = __webpack_require__(523); +var _bluebird = __webpack_require__(463); var _bluebird2 = _interopRequireDefault(_bluebird); @@ -82463,7 +71798,7 @@ module.exports = { }; /***/ }), -/* 523 */ +/* 463 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(process, global, setImmediate) {/* @preserve @@ -88085,19 +77420,19 @@ module.exports = ret; },{"./es5":13}]},{},[4])(4) }); ;if (typeof window !== 'undefined' && window !== null) { window.P = window.Promise; } else if (typeof self !== 'undefined' && self !== null) { self.P = self.Promise; } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0), __webpack_require__(67), __webpack_require__(310).setImmediate)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0), __webpack_require__(24), __webpack_require__(164).setImmediate)) /***/ }), -/* 524 */ +/* 464 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(Buffer) { -var bitcoinjs = __webpack_require__(346); -var bip32utils = __webpack_require__(555); -var zencashjs = __webpack_require__(306); -var bs58check = __webpack_require__(111); +var bitcoinjs = __webpack_require__(200); +var bip32utils = __webpack_require__(495); +var zencashjs = __webpack_require__(160); +var bs58check = __webpack_require__(33); // Hierarchical Deterministic wallet function phraseToHDWallet(phraseStr) { @@ -88125,20 +77460,20 @@ function phraseToHDWallet(phraseStr) { module.exports = { phraseToHDWallet: phraseToHDWallet }; -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 525 */ +/* 465 */ /***/ (function(module, exports, __webpack_require__) { -var Buffer = __webpack_require__(18).Buffer -var bcrypto = __webpack_require__(116) -var fastMerkleRoot = __webpack_require__(526) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) -var varuint = __webpack_require__(255) +var Buffer = __webpack_require__(7).Buffer +var bcrypto = __webpack_require__(44) +var fastMerkleRoot = __webpack_require__(466) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var varuint = __webpack_require__(73) -var Transaction = __webpack_require__(274) +var Transaction = __webpack_require__(112) function Block () { this.version = 1 @@ -88311,7 +77646,7 @@ module.exports = Block /***/ }), -/* 526 */ +/* 466 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(Buffer) {// constant-space merkle root calculation algorithm @@ -88339,14 +77674,14 @@ module.exports = function fastRoot (values, digestFn) { return results[0] } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 527 */ +/* 467 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var NATIVE = __webpack_require__(273) -var ERRORS = __webpack_require__(347) +/* WEBPACK VAR INJECTION */(function(Buffer) {var NATIVE = __webpack_require__(111) +var ERRORS = __webpack_require__(201) function _Buffer (value) { return Buffer.isBuffer(value) @@ -88416,13 +77751,13 @@ for (var typeName in types) { module.exports = types -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 528 */ +/* 468 */ /***/ (function(module, exports, __webpack_require__) { -var OPS = __webpack_require__(37) +var OPS = __webpack_require__(16) var map = {} for (var op in OPS) { @@ -88434,18 +77769,18 @@ module.exports = map /***/ }), -/* 529 */ +/* 469 */ /***/ (function(module, exports, __webpack_require__) { -var decompile = __webpack_require__(35).decompile -var multisig = __webpack_require__(530) -var nullData = __webpack_require__(533) -var pubKey = __webpack_require__(534) -var pubKeyHash = __webpack_require__(537) -var scriptHash = __webpack_require__(539) -var witnessPubKeyHash = __webpack_require__(541) -var witnessScriptHash = __webpack_require__(544) -var witnessCommitment = __webpack_require__(547) +var decompile = __webpack_require__(14).decompile +var multisig = __webpack_require__(470) +var nullData = __webpack_require__(473) +var pubKey = __webpack_require__(474) +var pubKeyHash = __webpack_require__(477) +var scriptHash = __webpack_require__(479) +var witnessPubKeyHash = __webpack_require__(481) +var witnessScriptHash = __webpack_require__(484) +var witnessCommitment = __webpack_require__(487) var types = { MULTISIG: 'multisig', @@ -88514,25 +77849,25 @@ module.exports = { /***/ }), -/* 530 */ +/* 470 */ /***/ (function(module, exports, __webpack_require__) { module.exports = { - input: __webpack_require__(531), - output: __webpack_require__(532) + input: __webpack_require__(471), + output: __webpack_require__(472) } /***/ }), -/* 531 */ +/* 471 */ /***/ (function(module, exports, __webpack_require__) { // OP_0 [signatures ...] -var Buffer = __webpack_require__(18).Buffer -var bscript = __webpack_require__(35) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) function partialSignature (value) { return value === OPS.OP_0 || bscript.isCanonicalSignature(value) @@ -88595,15 +77930,15 @@ module.exports = { /***/ }), -/* 532 */ +/* 472 */ /***/ (function(module, exports, __webpack_require__) { // m [pubKeys ...] n OP_CHECKMULTISIG -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) var OP_INT_BASE = OPS.OP_RESERVED // OP_1 - 1 function check (script, allowIncomplete) { @@ -88665,15 +78000,15 @@ module.exports = { /***/ }), -/* 533 */ +/* 473 */ /***/ (function(module, exports, __webpack_require__) { // OP_RETURN {data} -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) function check (script) { var buffer = bscript.compile(script) @@ -88705,24 +78040,24 @@ module.exports = { /***/ }), -/* 534 */ +/* 474 */ /***/ (function(module, exports, __webpack_require__) { module.exports = { - input: __webpack_require__(535), - output: __webpack_require__(536) + input: __webpack_require__(475), + output: __webpack_require__(476) } /***/ }), -/* 535 */ +/* 475 */ /***/ (function(module, exports, __webpack_require__) { // {signature} -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) function check (script) { var chunks = bscript.decompile(script) @@ -88761,14 +78096,14 @@ module.exports = { /***/ }), -/* 536 */ +/* 476 */ /***/ (function(module, exports, __webpack_require__) { // {pubKey} OP_CHECKSIG -var bscript = __webpack_require__(35) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var bscript = __webpack_require__(14) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) function check (script) { var chunks = bscript.decompile(script) @@ -88800,25 +78135,25 @@ module.exports = { /***/ }), -/* 537 */ +/* 477 */ /***/ (function(module, exports, __webpack_require__) { module.exports = { - input: __webpack_require__(350), - output: __webpack_require__(538) + input: __webpack_require__(204), + output: __webpack_require__(478) } /***/ }), -/* 538 */ +/* 478 */ /***/ (function(module, exports, __webpack_require__) { // OP_DUP OP_HASH160 {pubKeyHash} OP_EQUALVERIFY OP_CHECKSIG -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) function check (script) { var buffer = bscript.compile(script) @@ -88858,25 +78193,25 @@ module.exports = { /***/ }), -/* 539 */ +/* 479 */ /***/ (function(module, exports, __webpack_require__) { module.exports = { - input: __webpack_require__(351), - output: __webpack_require__(540) + input: __webpack_require__(205), + output: __webpack_require__(480) } /***/ }), -/* 540 */ +/* 480 */ /***/ (function(module, exports, __webpack_require__) { // OP_HASH160 {scriptHash} OP_EQUAL -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) function check (script) { var buffer = bscript.compile(script) @@ -88908,22 +78243,22 @@ module.exports = { /***/ }), -/* 541 */ +/* 481 */ /***/ (function(module, exports, __webpack_require__) { module.exports = { - input: __webpack_require__(542), - output: __webpack_require__(543) + input: __webpack_require__(482), + output: __webpack_require__(483) } /***/ }), -/* 542 */ +/* 482 */ /***/ (function(module, exports, __webpack_require__) { // {signature} {pubKey} -var pkh = __webpack_require__(350) +var pkh = __webpack_require__(204) module.exports = { check: pkh.check, @@ -88933,15 +78268,15 @@ module.exports = { /***/ }), -/* 543 */ +/* 483 */ /***/ (function(module, exports, __webpack_require__) { // OP_0 {pubKeyHash} -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) function check (script) { var buffer = bscript.compile(script) @@ -88972,22 +78307,22 @@ module.exports = { /***/ }), -/* 544 */ +/* 484 */ /***/ (function(module, exports, __webpack_require__) { module.exports = { - input: __webpack_require__(545), - output: __webpack_require__(546) + input: __webpack_require__(485), + output: __webpack_require__(486) } /***/ }), -/* 545 */ +/* 485 */ /***/ (function(module, exports, __webpack_require__) { // {signature} {pubKey} -var p2sh = __webpack_require__(351) +var p2sh = __webpack_require__(205) module.exports = { check: p2sh.check, @@ -88997,15 +78332,15 @@ module.exports = { /***/ }), -/* 546 */ +/* 486 */ /***/ (function(module, exports, __webpack_require__) { // OP_0 {scriptHash} -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) function check (script) { var buffer = bscript.compile(script) @@ -89036,25 +78371,25 @@ module.exports = { /***/ }), -/* 547 */ +/* 487 */ /***/ (function(module, exports, __webpack_require__) { module.exports = { - output: __webpack_require__(548) + output: __webpack_require__(488) } /***/ }), -/* 548 */ +/* 488 */ /***/ (function(module, exports, __webpack_require__) { // OP_RETURN {aa21a9ed} {commitment} -var Buffer = __webpack_require__(18).Buffer -var bscript = __webpack_require__(35) -var types = __webpack_require__(30) -var typeforce = __webpack_require__(21) -var OPS = __webpack_require__(37) +var Buffer = __webpack_require__(7).Buffer +var bscript = __webpack_require__(14) +var types = __webpack_require__(12) +var typeforce = __webpack_require__(9) +var OPS = __webpack_require__(16) var HEADER = Buffer.from('aa21a9ed', 'hex') @@ -89093,21 +78428,21 @@ module.exports = { /***/ }), -/* 549 */ +/* 489 */ /***/ (function(module, exports, __webpack_require__) { -var Buffer = __webpack_require__(18).Buffer -var createHmac = __webpack_require__(249) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) +var Buffer = __webpack_require__(7).Buffer +var createHmac = __webpack_require__(67) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) -var BigInteger = __webpack_require__(110) -var ECSignature = __webpack_require__(277) +var BigInteger = __webpack_require__(30) +var ECSignature = __webpack_require__(115) var ZERO = Buffer.alloc(1, 0) var ONE = Buffer.alloc(1, 1) -var ecurve = __webpack_require__(278) +var ecurve = __webpack_require__(116) var secp256k1 = ecurve.getCurveByName('secp256k1') // https://tools.ietf.org/html/rfc6979#section-3.2 @@ -89260,13 +78595,13 @@ module.exports = { /***/ }), -/* 550 */ +/* 490 */ /***/ (function(module, exports, __webpack_require__) { -var BigInteger = __webpack_require__(110) +var BigInteger = __webpack_require__(30) -var curves = __webpack_require__(551) -var Curve = __webpack_require__(354) +var curves = __webpack_require__(491) +var Curve = __webpack_require__(208) function getCurveByName (name) { var curve = curves[name] @@ -89287,7 +78622,7 @@ module.exports = getCurveByName /***/ }), -/* 551 */ +/* 491 */ /***/ (function(module, exports) { module.exports = { @@ -89357,10 +78692,10 @@ module.exports = { }; /***/ }), -/* 552 */ +/* 492 */ /***/ (function(module, exports, __webpack_require__) { -/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(111) +/* WEBPACK VAR INJECTION */(function(Buffer) {var bs58check = __webpack_require__(33) function decodeRaw (buffer, version) { // check version only if defined @@ -89424,24 +78759,24 @@ module.exports = { encodeRaw: encodeRaw } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(7).Buffer)) +/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).Buffer)) /***/ }), -/* 553 */ +/* 493 */ /***/ (function(module, exports, __webpack_require__) { -var Buffer = __webpack_require__(18).Buffer -var base58check = __webpack_require__(111) -var bcrypto = __webpack_require__(116) -var createHmac = __webpack_require__(249) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) -var NETWORKS = __webpack_require__(242) +var Buffer = __webpack_require__(7).Buffer +var base58check = __webpack_require__(33) +var bcrypto = __webpack_require__(44) +var createHmac = __webpack_require__(67) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) +var NETWORKS = __webpack_require__(54) -var BigInteger = __webpack_require__(110) -var ECPair = __webpack_require__(275) +var BigInteger = __webpack_require__(30) +var ECPair = __webpack_require__(113) -var ecurve = __webpack_require__(278) +var ecurve = __webpack_require__(116) var curve = ecurve.getCurveByName('secp256k1') function HDNode (keyPair, chainCode) { @@ -89749,24 +79084,24 @@ module.exports = HDNode /***/ }), -/* 554 */ +/* 494 */ /***/ (function(module, exports, __webpack_require__) { -var Buffer = __webpack_require__(18).Buffer -var baddress = __webpack_require__(276) -var bcrypto = __webpack_require__(116) -var bscript = __webpack_require__(35) -var networks = __webpack_require__(242) -var ops = __webpack_require__(37) -var typeforce = __webpack_require__(21) -var types = __webpack_require__(30) +var Buffer = __webpack_require__(7).Buffer +var baddress = __webpack_require__(114) +var bcrypto = __webpack_require__(44) +var bscript = __webpack_require__(14) +var networks = __webpack_require__(54) +var ops = __webpack_require__(16) +var typeforce = __webpack_require__(9) +var types = __webpack_require__(12) var scriptTypes = bscript.types var SIGNABLE = [bscript.types.P2PKH, bscript.types.P2PK, bscript.types.MULTISIG] var P2SH = SIGNABLE.concat([bscript.types.P2WPKH, bscript.types.P2WSH]) -var ECPair = __webpack_require__(275) -var ECSignature = __webpack_require__(277) -var Transaction = __webpack_require__(274) +var ECPair = __webpack_require__(113) +var ECSignature = __webpack_require__(115) +var Transaction = __webpack_require__(112) function extractChunks (type, chunks, script) { var pubKeys = [] @@ -90499,24 +79834,24 @@ module.exports = TransactionBuilder /***/ }), -/* 555 */ +/* 495 */ /***/ (function(module, exports, __webpack_require__) { module.exports = { - Account: __webpack_require__(556), - Chain: __webpack_require__(356), - discovery: __webpack_require__(355) + Account: __webpack_require__(496), + Chain: __webpack_require__(210), + discovery: __webpack_require__(209) } /***/ }), -/* 556 */ +/* 496 */ /***/ (function(module, exports, __webpack_require__) { -var bitcoinjs = __webpack_require__(346) -var discovery = __webpack_require__(355) +var bitcoinjs = __webpack_require__(200) +var discovery = __webpack_require__(209) -var Chain = __webpack_require__(356) +var Chain = __webpack_require__(210) function Account (chains) { this.chains = chains @@ -90609,7 +79944,220 @@ module.exports = Account /***/ }), -/* 557 */ +/* 497 */ +/***/ (function(module, exports, __webpack_require__) { + +var __WEBPACK_AMD_DEFINE_RESULT__;/* FileSaver.js + * A saveAs() FileSaver implementation. + * 1.3.2 + * 2016-06-16 18:25:19 + * + * By Eli Grey, http://eligrey.com + * License: MIT + * See https://github.com/eligrey/FileSaver.js/blob/master/LICENSE.md + */ + +/*global self */ +/*jslint bitwise: true, indent: 4, laxbreak: true, laxcomma: true, smarttabs: true, plusplus: true */ + +/*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */ + +var saveAs = saveAs || (function(view) { + "use strict"; + // IE <10 is explicitly unsupported + if (typeof view === "undefined" || typeof navigator !== "undefined" && /MSIE [1-9]\./.test(navigator.userAgent)) { + return; + } + var + doc = view.document + // only get URL when necessary in case Blob.js hasn't overridden it yet + , get_URL = function() { + return view.URL || view.webkitURL || view; + } + , save_link = doc.createElementNS("http://www.w3.org/1999/xhtml", "a") + , can_use_save_link = "download" in save_link + , click = function(node) { + var event = new MouseEvent("click"); + node.dispatchEvent(event); + } + , is_safari = /constructor/i.test(view.HTMLElement) || view.safari + , is_chrome_ios =/CriOS\/[\d]+/.test(navigator.userAgent) + , throw_outside = function(ex) { + (view.setImmediate || view.setTimeout)(function() { + throw ex; + }, 0); + } + , force_saveable_type = "application/octet-stream" + // the Blob API is fundamentally broken as there is no "downloadfinished" event to subscribe to + , arbitrary_revoke_timeout = 1000 * 40 // in ms + , revoke = function(file) { + var revoker = function() { + if (typeof file === "string") { // file is an object URL + get_URL().revokeObjectURL(file); + } else { // file is a File + file.remove(); + } + }; + setTimeout(revoker, arbitrary_revoke_timeout); + } + , dispatch = function(filesaver, event_types, event) { + event_types = [].concat(event_types); + var i = event_types.length; + while (i--) { + var listener = filesaver["on" + event_types[i]]; + if (typeof listener === "function") { + try { + listener.call(filesaver, event || filesaver); + } catch (ex) { + throw_outside(ex); + } + } + } + } + , auto_bom = function(blob) { + // prepend BOM for UTF-8 XML and text/* types (including HTML) + // note: your browser will automatically convert UTF-16 U+FEFF to EF BB BF + if (/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(blob.type)) { + return new Blob([String.fromCharCode(0xFEFF), blob], {type: blob.type}); + } + return blob; + } + , FileSaver = function(blob, name, no_auto_bom) { + if (!no_auto_bom) { + blob = auto_bom(blob); + } + // First try a.download, then web filesystem, then object URLs + var + filesaver = this + , type = blob.type + , force = type === force_saveable_type + , object_url + , dispatch_all = function() { + dispatch(filesaver, "writestart progress write writeend".split(" ")); + } + // on any filesys errors revert to saving with object URLs + , fs_error = function() { + if ((is_chrome_ios || (force && is_safari)) && view.FileReader) { + // Safari doesn't allow downloading of blob urls + var reader = new FileReader(); + reader.onloadend = function() { + var url = is_chrome_ios ? reader.result : reader.result.replace(/^data:[^;]*;/, 'data:attachment/file;'); + var popup = view.open(url, '_blank'); + if(!popup) view.location.href = url; + url=undefined; // release reference before dispatching + filesaver.readyState = filesaver.DONE; + dispatch_all(); + }; + reader.readAsDataURL(blob); + filesaver.readyState = filesaver.INIT; + return; + } + // don't create more object URLs than needed + if (!object_url) { + object_url = get_URL().createObjectURL(blob); + } + if (force) { + view.location.href = object_url; + } else { + var opened = view.open(object_url, "_blank"); + if (!opened) { + // Apple does not allow window.open, see https://developer.apple.com/library/safari/documentation/Tools/Conceptual/SafariExtensionGuide/WorkingwithWindowsandTabs/WorkingwithWindowsandTabs.html + view.location.href = object_url; + } + } + filesaver.readyState = filesaver.DONE; + dispatch_all(); + revoke(object_url); + } + ; + filesaver.readyState = filesaver.INIT; + + if (can_use_save_link) { + object_url = get_URL().createObjectURL(blob); + setTimeout(function() { + save_link.href = object_url; + save_link.download = name; + click(save_link); + dispatch_all(); + revoke(object_url); + filesaver.readyState = filesaver.DONE; + }); + return; + } + + fs_error(); + } + , FS_proto = FileSaver.prototype + , saveAs = function(blob, name, no_auto_bom) { + return new FileSaver(blob, name || blob.name || "download", no_auto_bom); + } + ; + // IE 10+ (native saveAs) + if (typeof navigator !== "undefined" && navigator.msSaveOrOpenBlob) { + return function(blob, name, no_auto_bom) { + name = name || blob.name || "download"; + + if (!no_auto_bom) { + blob = auto_bom(blob); + } + return navigator.msSaveOrOpenBlob(blob, name); + }; + } + + FS_proto.abort = function(){}; + FS_proto.readyState = FS_proto.INIT = 0; + FS_proto.WRITING = 1; + FS_proto.DONE = 2; + + FS_proto.error = + FS_proto.onwritestart = + FS_proto.onprogress = + FS_proto.onwrite = + FS_proto.onabort = + FS_proto.onerror = + FS_proto.onwriteend = + null; + + return saveAs; +}( + typeof self !== "undefined" && self + || typeof window !== "undefined" && window + || this.content +)); +// `self` is undefined in Firefox for Android content script context +// while `this` is nsIContentFrameMessageManager +// with an attribute `content` that corresponds to the window + +if (typeof module !== "undefined" && module.exports) { + module.exports.saveAs = saveAs; +} else if (("function" !== "undefined" && __webpack_require__(498) !== null) && (__webpack_require__(499) !== null)) { + !(__WEBPACK_AMD_DEFINE_RESULT__ = function() { + return saveAs; + }.call(exports, __webpack_require__, exports, module), + __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); +} + + +/***/ }), +/* 498 */ +/***/ (function(module, exports) { + +module.exports = function() { + throw new Error("define cannot be used indirect"); +}; + + +/***/ }), +/* 499 */ +/***/ (function(module, exports) { + +/* WEBPACK VAR INJECTION */(function(__webpack_amd_options__) {/* globals __webpack_amd_options__ */ +module.exports = __webpack_amd_options__; + +/* WEBPACK VAR INJECTION */}.call(exports, {})) + +/***/ }), +/* 500 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -90621,11 +80169,11 @@ Object.defineProperty(exports, "__esModule", { var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactIconBase = __webpack_require__(70); +var _reactIconBase = __webpack_require__(35); var _reactIconBase2 = _interopRequireDefault(_reactIconBase); @@ -90647,7 +80195,7 @@ exports.default = MdRefresh; module.exports = exports['default']; /***/ }), -/* 558 */ +/* 501 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -90659,11 +80207,11 @@ Object.defineProperty(exports, "__esModule", { var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactIconBase = __webpack_require__(70); +var _reactIconBase = __webpack_require__(35); var _reactIconBase2 = _interopRequireDefault(_reactIconBase); @@ -90685,7 +80233,45 @@ exports.default = MdContentCopy; module.exports = exports['default']; /***/ }), -/* 559 */ +/* 502 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var MdSettings = function MdSettings(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm20 25.9c3.2 0 5.9-2.7 5.9-5.9s-2.7-5.9-5.9-5.9-5.9 2.7-5.9 5.9 2.7 5.9 5.9 5.9z m12.4-4.3l3.5 2.8c0.4 0.2 0.4 0.7 0.2 1.1l-3.4 5.8c-0.2 0.3-0.6 0.4-1 0.3l-4.1-1.7c-0.9 0.7-1.8 1.3-2.8 1.7l-0.7 4.3c0 0.4-0.4 0.7-0.7 0.7h-6.8c-0.4 0-0.7-0.3-0.7-0.7l-0.7-4.3c-1-0.4-1.9-1-2.8-1.7l-4.1 1.7c-0.4 0.1-0.8 0-1-0.3l-3.4-5.8c-0.2-0.4-0.2-0.9 0.2-1.1l3.5-2.8c-0.1-0.5-0.1-1.1-0.1-1.6s0-1.1 0.1-1.6l-3.5-2.8c-0.4-0.2-0.4-0.7-0.2-1.1l3.4-5.7c0.2-0.4 0.6-0.5 1-0.4l4.1 1.7c0.9-0.6 1.8-1.3 2.8-1.7l0.7-4.3c0-0.4 0.3-0.7 0.7-0.7h6.8c0.3 0 0.7 0.3 0.7 0.7l0.7 4.3c1 0.4 1.9 1 2.8 1.7l4.1-1.7c0.4-0.1 0.8 0 1 0.4l3.4 5.7c0.2 0.4 0.2 0.9-0.2 1.1l-3.5 2.8c0.1 0.5 0.1 1.1 0.1 1.6s0 1.1-0.1 1.6z' }) + ) + ); +}; + +exports.default = MdSettings; +module.exports = exports['default']; + +/***/ }), +/* 503 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -90697,11 +80283,11 @@ Object.defineProperty(exports, "__esModule", { var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactIconBase = __webpack_require__(70); +var _reactIconBase = __webpack_require__(35); var _reactIconBase2 = _interopRequireDefault(_reactIconBase); @@ -90723,7 +80309,45 @@ exports.default = FaRepeat; module.exports = exports['default']; /***/ }), -/* 560 */ +/* 504 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactIconBase = __webpack_require__(35); + +var _reactIconBase2 = _interopRequireDefault(_reactIconBase); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var FaUnlockAlt = function FaUnlockAlt(props) { + return _react2.default.createElement( + _reactIconBase2.default, + _extends({ viewBox: '0 0 40 40' }, props), + _react2.default.createElement( + 'g', + null, + _react2.default.createElement('path', { d: 'm30.6 17.1q0.9 0 1.5 0.7t0.6 1.5v12.8q0 0.9-0.6 1.6t-1.5 0.6h-21.5q-0.8 0-1.5-0.6t-0.6-1.6v-12.8q0-0.9 0.6-1.5t1.5-0.7h0.8v-7.1q0-4.1 2.9-7.1t7.1-2.9 7 2.9 3 7.1q0 0.6-0.5 1t-1 0.4h-1.4q-0.6 0-1-0.4t-0.4-1q0-2.4-1.7-4t-4-1.7-4.1 1.7-1.7 4v7.1h16.5z' }) + ) + ); +}; + +exports.default = FaUnlockAlt; +module.exports = exports['default']; + +/***/ }), +/* 505 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -90735,11 +80359,11 @@ Object.defineProperty(exports, "__esModule", { var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactIconBase = __webpack_require__(70); +var _reactIconBase = __webpack_require__(35); var _reactIconBase2 = _interopRequireDefault(_reactIconBase); @@ -90761,7 +80385,7 @@ exports.default = FaEyeSlash; module.exports = exports['default']; /***/ }), -/* 561 */ +/* 506 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -90773,11 +80397,11 @@ Object.defineProperty(exports, "__esModule", { var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; -var _react = __webpack_require__(4); +var _react = __webpack_require__(6); var _react2 = _interopRequireDefault(_react); -var _reactIconBase = __webpack_require__(70); +var _reactIconBase = __webpack_require__(35); var _reactIconBase2 = _interopRequireDefault(_reactIconBase); @@ -90798,5 +80422,251 @@ var FaEye = function FaEye(props) { exports.default = FaEye; module.exports = exports['default']; +/***/ }), +/* 507 */ +/***/ (function(module, exports) { + +module.exports = { + "name": "myzenwallet", + "version": "v2.0.0a", + "description": "Secure ZENCash wallet online", + "main": "index.js", + "repository": "https://github.com/kendricktan/myzenwallet.git", + "author": "Kendrick Tan <kendricktan0814@gmail.com>", + "license": "MIT", + "scripts": { + "start": "webpack-dev-server", + "watch": "webpack --watch" + }, + "dependencies": { + "axios": "^0.16.2", + "babel-preset-env": "^1.6.0", + "bip32-utils": "^0.10.0", + "bitcoinjs-lib": "^3.1.1", + "bluebird": "^3.5.0", + "bootstrap": "^4.0.0-alpha.6", + "bs58": "^4.0.1", + "bs58check": "^2.0.2", + "classnames": "^2.2.5", + "css-loader": "^0.28.4", + "file-loader": "^0.11.2", + "file-saver": "^1.3.3", + "fs": "^0.0.1-security", + "hash.js": "^1.1.3", + "html-webpack-plugin": "^2.29.0", + "path": "^0.12.7", + "react": "^15.6.1", + "react-addons-css-transition-group": "^15.6.0", + "react-addons-transition-group": "^15.6.0", + "react-bootstrap": "^0.31.1", + "react-copy-to-clipboard": "^5.0.0", + "react-dom": "^15.6.1", + "react-icons": "^2.2.5", + "react-table": "^6.5.3", + "reactstrap": "^4.8.0", + "style-loader": "^0.18.2", + "throttled-queue": "^1.0.4", + "webpack": "^3.3.0", + "webpack-dev-server": "^2.5.1", + "zencashjs": "^1.1.4-a" + }, + "devDependencies": { + "babel-core": "^6.25.0", + "babel-loader": "^7.1.1", + "babel-preset-es2015": "^6.24.1", + "babel-preset-react": "^6.24.1", + "css-loader": "^0.28.4" + } +}; + +/***/ }), +/* 508 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactstrap = __webpack_require__(93); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } + +function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } + +var footer = { + backgroundColor: '#f5f5f5' +}; + +var longP = { + wordWrap: 'break-word' +}; + +var ZFooter = function (_React$Component) { + _inherits(ZFooter, _React$Component); + + function ZFooter(props) { + _classCallCheck(this, ZFooter); + + return _possibleConstructorReturn(this, (ZFooter.__proto__ || Object.getPrototypeOf(ZFooter)).call(this, props)); + } + + _createClass(ZFooter, [{ + key: 'render', + value: function render() { + return _react2.default.createElement( + 'div', + { style: footer }, + _react2.default.createElement('br', null), + _react2.default.createElement( + _reactstrap.Container, + null, + _react2.default.createElement( + _reactstrap.Row, + null, + _react2.default.createElement( + _reactstrap.Col, + { md: '8' }, + _react2.default.createElement( + 'p', + null, + 'MAKE SURE YOU ARE ON ', + _react2.default.createElement( + 'b', + null, + 'MYZENWALLET.IO' + ) + ), + _react2.default.createElement( + 'p', + null, + 'Keys are validated client-side and do not leave your browser or network. You are responsible for keeping your own keys safe!!!' + ), + _react2.default.createElement( + 'p', + null, + 'Suggestions? Email me: kendricktan0814 at gmail.com or find me on slack @ kendricktan.' + ), + _react2.default.createElement( + 'p', + { style: longP }, + 'Donations are always welcome!', + _react2.default.createElement('br', null), + _react2.default.createElement( + 'b', + null, + 'BTC' + ), + ': 14VmTd7Npm27SmJgrg1eUrSPgFEHcMXVGR', + _react2.default.createElement('br', null), + _react2.default.createElement( + 'b', + null, + 'ETH' + ), + ': 0x19Ed10db2960B9B21283FdFDe464e7bF3a87D05D', + _react2.default.createElement('br', null), + _react2.default.createElement( + 'b', + null, + 'ZEN' + ), + ': znSDvF9nA5VCdse5HbEKmsoNbjCbsEA3VAH' + ) + ), + _react2.default.createElement( + _reactstrap.Col, + { md: '4' }, + _react2.default.createElement( + 'a', + { href: 'https://zensystem.io/' }, + 'website' + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + 'a', + { href: 'https://blog.zensystem.io/' }, + 'blog' + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + 'a', + { href: 'https://forum.zensystem.io/' }, + 'forum' + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + 'a', + { href: 'https://github.com/ZencashOfficial' }, + 'github' + ), + _react2.default.createElement('br', null), + _react2.default.createElement( + 'a', + { href: 'https://slackinvite.zensystem.io/' }, + 'slack' + ), + _react2.default.createElement('br', null) + ) + ) + ) + ); + } + }]); + + return ZFooter; +}(_react2.default.Component); + +exports.default = ZFooter; + +/***/ }), +/* 509 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +__webpack_require__(211); + +__webpack_require__(214); + +var _react = __webpack_require__(6); + +var _react2 = _interopRequireDefault(_react); + +var _reactDom = __webpack_require__(76); + +var _reactDom2 = _interopRequireDefault(_reactDom); + +var _navbar = __webpack_require__(315); + +var _navbar2 = _interopRequireDefault(_navbar); + +var _wallet = __webpack_require__(332); + +var _wallet2 = _interopRequireDefault(_wallet); + +var _footer = __webpack_require__(508); + +var _footer2 = _interopRequireDefault(_footer); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +_reactDom2.default.render(_react2.default.createElement(_navbar2.default, null), document.getElementById('navbar')); +_reactDom2.default.render(_react2.default.createElement(_wallet2.default, null), document.getElementById('wallet')); +_reactDom2.default.render(_react2.default.createElement(_footer2.default, null), document.getElementById('footer')); + /***/ }) /******/ ]); \ No newline at end of file diff --git a/package.json b/package.json index 77c31e7..75ae36e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "myzenwallet", - "version": "v1.0.0a", + "version": "v2.0.3a", "description": "Secure ZENCash wallet online", "main": "index.js", "repository": "https://github.com/kendricktan/myzenwallet.git", @@ -22,6 +22,7 @@ "classnames": "^2.2.5", "css-loader": "^0.28.4", "file-loader": "^0.11.2", + "file-saver": "^1.3.3", "fs": "^0.0.1-security", "hash.js": "^1.1.3", "html-webpack-plugin": "^2.29.0", @@ -30,10 +31,10 @@ "react-addons-css-transition-group": "^15.6.0", "react-addons-transition-group": "^15.6.0", "react-bootstrap": "^0.31.1", - "react-bootstrap-table": "^4.0.0", "react-copy-to-clipboard": "^5.0.0", "react-dom": "^15.6.1", "react-icons": "^2.2.5", + "react-table": "^6.5.3", "reactstrap": "^4.8.0", "style-loader": "^0.18.2", "throttled-queue": "^1.0.4", diff --git a/yarn.lock b/yarn.lock index e269ca2..63ef640 100644 --- a/yarn.lock +++ b/yarn.lock @@ -741,13 +741,6 @@ babel-runtime@^6.11.6, babel-runtime@^6.18.0, babel-runtime@^6.22.0: core-js "^2.4.0" regenerator-runtime "^0.10.0" -babel-runtime@^6.23.0: - version "6.25.0" - resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.25.0.tgz#33b98eaa5d482bb01a8d1aa6b437ad2b01aec41c" - dependencies: - core-js "^2.4.0" - regenerator-runtime "^0.10.0" - babel-template@^6.24.1, babel-template@^6.25.0: version "6.25.0" resolved "https://registry.yarnpkg.com/babel-template/-/babel-template-6.25.0.tgz#665241166b7c2aa4c619d71e192969552b10c071" @@ -1143,7 +1136,7 @@ clap@^1.0.9: dependencies: chalk "^1.1.3" -classnames@^2.1.2, classnames@^2.2.3, classnames@^2.2.5: +classnames@^2.2.3, classnames@^2.2.5: version "2.2.5" resolved "https://registry.yarnpkg.com/classnames/-/classnames-2.2.5.tgz#fb3801d453467649ef3603c7d61a02bd129bde6d" @@ -1344,7 +1337,7 @@ create-hmac@^1.1.0, create-hmac@^1.1.2, create-hmac@^1.1.3, create-hmac@^1.1.4, safe-buffer "^5.0.1" sha.js "^2.4.8" -create-react-class@^15.5.2, create-react-class@^15.6.0: +create-react-class@^15.6.0: version "15.6.0" resolved "https://registry.yarnpkg.com/create-react-class/-/create-react-class-15.6.0.tgz#ab448497c26566e1e29413e883207d57cfe7bed4" dependencies: @@ -1660,10 +1653,6 @@ electron-to-chromium@^1.2.7, electron-to-chromium@^1.3.15: version "1.3.16" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.16.tgz#d0e026735754770901ae301a21664cba45d92f7d" -element-class@^0.2.0: - version "0.2.2" - resolved "https://registry.yarnpkg.com/element-class/-/element-class-0.2.2.tgz#9d3bbd0767f9013ef8e1c8ebe722c1402a60050e" - elliptic@^6.0.0, elliptic@^6.2.3: version "6.4.0" resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.4.0.tgz#cac9af8762c85836187003c8dfe193e5e2eae5df" @@ -1840,10 +1829,6 @@ evp_bytestokey@^1.0.0: dependencies: create-hash "^1.1.1" -exenv@1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/exenv/-/exenv-1.2.0.tgz#3835f127abf075bfe082d0aed4484057c78e3c89" - expand-brackets@^0.1.4: version "0.1.5" resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-0.1.5.tgz#df07284e342a807cd733ac5af72411e581d1177b" @@ -1945,6 +1930,10 @@ file-loader@^0.11.2: dependencies: loader-utils "^1.0.2" +file-saver@^1.3.3: + version "1.3.3" + resolved "https://registry.yarnpkg.com/file-saver/-/file-saver-1.3.3.tgz#cdd4c44d3aa264eac2f68ec165bc791c34af1232" + filename-regex@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/filename-regex/-/filename-regex-2.0.1.tgz#c1c4b9bee3e09725ddb106b75c1e301fe2f18b26" @@ -2708,10 +2697,6 @@ locate-path@^2.0.0: p-locate "^2.0.0" path-exists "^3.0.0" -lodash.assign@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-4.2.0.tgz#0d99f3ccd7a6d261d19bdaeb9245005d285808e7" - lodash.camelcase@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/lodash.camelcase/-/lodash.camelcase-4.3.0.tgz#b28aa6288a2b9fc651035c7711f65ab6190331a6" @@ -3569,7 +3554,7 @@ prop-types@15.5.8: dependencies: fbjs "^0.8.9" -prop-types@^15.5.10, prop-types@^15.5.6, prop-types@^15.5.7, prop-types@^15.5.8: +prop-types@^15.5.10, prop-types@^15.5.6, prop-types@^15.5.8: version "15.5.10" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.5.10.tgz#2797dfc3126182e3a95e3dfbb2e893ddd7456154" dependencies: @@ -3687,15 +3672,6 @@ react-addons-transition-group@^15.6.0: dependencies: react-transition-group "^1.2.0" -react-bootstrap-table@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/react-bootstrap-table/-/react-bootstrap-table-4.0.0.tgz#7a52d3131e2ed125a9a18373353fb631558ce07d" - dependencies: - classnames "^2.1.2" - prop-types "^15.5.10" - react-modal "^1.4.0" - react-s-alert "^1.3.0" - react-bootstrap@^0.31.1: version "0.31.1" resolved "https://registry.yarnpkg.com/react-bootstrap/-/react-bootstrap-0.31.1.tgz#679c9f73ae77ff207867d536496207291f3a3ed7" @@ -3719,10 +3695,6 @@ react-copy-to-clipboard@^5.0.0: copy-to-clipboard "^3" prop-types "^15.5.8" -react-dom-factories@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/react-dom-factories/-/react-dom-factories-1.0.1.tgz#c50692ac5ff1adb39d86dfe6dbe3485dacf58455" - react-dom@^15.6.1: version "15.6.1" resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-15.6.1.tgz#2cb0ed4191038e53c209eb3a79a23e2a4cf99470" @@ -3744,17 +3716,6 @@ react-icons@^2.2.5: dependencies: react-icon-base "2.0.7" -react-modal@^1.4.0: - version "1.9.7" - resolved "https://registry.yarnpkg.com/react-modal/-/react-modal-1.9.7.tgz#07ef56790b953e3b98ef1e2989e347983c72871d" - dependencies: - create-react-class "^15.5.2" - element-class "^0.2.0" - exenv "1.2.0" - lodash.assign "^4.2.0" - prop-types "^15.5.7" - react-dom-factories "^1.0.0" - react-overlays@^0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/react-overlays/-/react-overlays-0.7.0.tgz#531898ff566c7e5c7226ead2863b8cf9fbb5a981" @@ -3771,11 +3732,11 @@ react-prop-types@^0.4.0: dependencies: warning "^3.0.0" -react-s-alert@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/react-s-alert/-/react-s-alert-1.3.0.tgz#d81224a474f15e89c35c0ea6c2a73f232a767128" +react-table@^6.5.3: + version "6.5.3" + resolved "https://registry.yarnpkg.com/react-table/-/react-table-6.5.3.tgz#fd84371b97bcabed8308b766faeeaf4264b155c8" dependencies: - babel-runtime "^6.23.0" + classnames "^2.2.5" react-transition-group@^1.2.0: version "1.2.0"